From 6708203296911800caf94bb94ce204d3a39af0bd Mon Sep 17 00:00:00 2001 From: Julian Andres Klode Date: Thu, 6 Jun 2024 11:19:04 +0200 Subject: solver3: Order obsolete choices last This has two aspects: 1. For a dependency A | B | C we order the obsolete packages last, that is, if A is obsolete, this gets reordered to B | C | A, such that we try to pick non-obsolete packages first to ease upgrade calculation. 2. When comparing two dependencies, we order dependencies into three groups: First we satisfy dependencies mentioning only non-installed (NEW) packages, then we satisfy "normal" dependencies, and finally we satisfy any dependencies mentioning obsolete packages. This means for example if you have obsolete libfoo1 and a new libfoo1t64, that we will see Depends: libfoo1t64 before any Depends: libfoo1 (which may expand to libfoo1 | libfoo1t64), so we effectively will have selected "replacement" packages this way already before getting to older packages where we would have to choose between the obsolete package and its replacement. --- test/integration/test-resolver-provider-exchange | 1 + 1 file changed, 1 insertion(+) (limited to 'test') diff --git a/test/integration/test-resolver-provider-exchange b/test/integration/test-resolver-provider-exchange index 45d936978..2874b88e4 100755 --- a/test/integration/test-resolver-provider-exchange +++ b/test/integration/test-resolver-provider-exchange @@ -8,6 +8,7 @@ allowremovemanual configarchitecture 'amd64' insertinstalledpackage 'fuse' 'all' '2' +insertpackage 'unstable' 'fuse' 'all' '2' insertpackage 'unstable' 'fuse3' 'all' '3' 'Conflicts: fuse Provides: fuse' -- cgit v1.2.3-70-g09d2