X-Git-Url: https://git.saurik.com/apt.git/blobdiff_plain/a3f1a6ccd29480ae45e0a82871b05e009741d7fa..af7a92c35accda98b667ff41f62ea500fca95a7c:/apt-pkg/algorithms.cc diff --git a/apt-pkg/algorithms.cc b/apt-pkg/algorithms.cc index 9abb7a947..0fbce3c2a 100644 --- a/apt-pkg/algorithms.cc +++ b/apt-pkg/algorithms.cc @@ -374,6 +374,13 @@ bool pkgDistUpgrade(pkgDepCache &Cache) { pkgDepCache::ActionGroup group(Cache); + /* Upgrade all installed packages first without autoinst to help the resolver + in versioned or-groups to upgrade the old solver instead of installing + a new one (if the old solver is not the first one [anymore]) */ + for (pkgCache::PkgIterator I = Cache.PkgBegin(); I.end() == false; ++I) + if (I->CurrentVer != 0) + Cache.MarkInstall(I, false, 0, false); + /* Auto upgrade all installed packages, this provides the basis for the installation */ for (pkgCache::PkgIterator I = Cache.PkgBegin(); I.end() == false; I++)