summaryrefslogtreecommitdiff
path: root/apt-pkg/orderlist.cc
diff options
context:
space:
mode:
authorMichael Vogt <michael.vogt@ubuntu.com>2007-06-09 00:19:51 +0200
committerMichael Vogt <michael.vogt@ubuntu.com>2007-06-09 00:19:51 +0200
commit408a4726131e9db26ff868623a5d216a26c45a50 (patch)
treea8b470ee8fd8d22e74e1245edb2b36400b9226dd /apt-pkg/orderlist.cc
parent1979e742ad5e2a0b6e547fbe3f4c4066b5a9bd2e (diff)
parent484dbb814fd2b787b2206ffe9504798dfd73ae6c (diff)
* huge merge to bring the apt debian-sid and ubuntu branches as close
as possible to apt--mvo again
Diffstat (limited to 'apt-pkg/orderlist.cc')
-rw-r--r--apt-pkg/orderlist.cc17
1 files changed, 16 insertions, 1 deletions
diff --git a/apt-pkg/orderlist.cc b/apt-pkg/orderlist.cc
index 8d3a97983..61d8d914e 100644
--- a/apt-pkg/orderlist.cc
+++ b/apt-pkg/orderlist.cc
@@ -491,11 +491,13 @@ bool pkgOrderList::VisitProvides(DepIterator D,bool Critical)
continue;
if (D->Type != pkgCache::Dep::Conflicts &&
+ D->Type != pkgCache::Dep::DpkgBreaks &&
D->Type != pkgCache::Dep::Obsoletes &&
Cache[Pkg].InstallVer != *I)
continue;
if ((D->Type == pkgCache::Dep::Conflicts ||
+ D->Type == pkgCache::Dep::DpkgBreaks ||
D->Type == pkgCache::Dep::Obsoletes) &&
(Version *)Pkg.CurrentVer() != *I)
continue;
@@ -630,6 +632,7 @@ bool pkgOrderList::DepUnPackCrit(DepIterator D)
/* Forward critical dependencies MUST be correct before the
package can be unpacked. */
if (D->Type != pkgCache::Dep::Conflicts &&
+ D->Type != pkgCache::Dep::DpkgBreaks &&
D->Type != pkgCache::Dep::Obsoletes &&
D->Type != pkgCache::Dep::PreDepends)
continue;
@@ -668,7 +671,7 @@ bool pkgOrderList::DepUnPackCrit(DepIterator D)
}
return true;
}
- /*}}}*/
+
// OrderList::DepUnPackPreD - Critical UnPacking ordering with depends /*{{{*/
// ---------------------------------------------------------------------
/* Critical PreDepends (also configure immediate and essential) strives to
@@ -803,9 +806,20 @@ bool pkgOrderList::DepUnPackDep(DepIterator D)
return false;
}
else
+ {
if (D->Type == pkgCache::Dep::Depends)
if (VisitProvides(D,false) == false)
return false;
+
+ if (D->Type == pkgCache::Dep::DpkgBreaks)
+ {
+ if (CheckDep(D) == true)
+ continue;
+
+ if (VisitNode(D.TargetPkg()) == false)
+ return false;
+ }
+ }
}
return true;
}
@@ -953,6 +967,7 @@ bool pkgOrderList::CheckDep(DepIterator D)
/* Conflicts requires that all versions are not present, depends
just needs one */
if (D->Type != pkgCache::Dep::Conflicts &&
+ D->Type != pkgCache::Dep::DpkgBreaks &&
D->Type != pkgCache::Dep::Obsoletes)
{
/* Try to find something that does not have the after flag set