Don't conflict with pkgs that are in the depPool
When upgrading multiple packages that are already installed we should not conflict with already installed packages that are in the depPool. This is because the version in the depTree is going to replace the currently installed version of the package and may have different conflicts. If there is a conflict between stuff in the depPool these should be handled by the innerConflicts check anyway.
This commit is contained in:
1 file changed
+5
-1
+5
-1
@@ -33,7 +33,7 @@ func (dp *depPool) checkInnerConflict(name string, conflict string, conflicts ma
|
||||
|
||||
func (dp *depPool) checkForwardConflict(name string, conflict string, conflicts mapStringSet) {
|
||||
dp.LocalDb.PkgCache().ForEach(func(pkg alpm.Package) error {
|
||||
if pkg.Name() == name {
|
||||
if pkg.Name() == name || dp.hasPackage(pkg.Name()) {
|
||||
return nil
|
||||
}
|
||||
|
||||
@@ -111,6 +111,10 @@ func (dp *depPool) checkForwardConflicts(conflicts mapStringSet) {
|
||||
|
||||
func (dp *depPool) checkReverseConflicts(conflicts mapStringSet) {
|
||||
dp.LocalDb.PkgCache().ForEach(func(pkg alpm.Package) error {
|
||||
if dp.hasPackage(pkg.Name()) {
|
||||
return nil
|
||||
}
|
||||
|
||||
pkg.Conflicts().ForEach(func(conflict alpm.Depend) error {
|
||||
dp.checkReverseConflict(pkg.Name(), conflict.String(), conflicts)
|
||||
return nil
|
||||
|
||||
Reference in new issue
Block a user