summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2008-11-15 21:14:02 +0000
committerZac Medico <zmedico@gentoo.org>2008-11-15 21:14:02 +0000
commitd0a1b8bb01dece5fc18a6753ca9cda099b100deb (patch)
tree12daa8ae52a7a7f1be81286e48bbc621bc370b42
parentd60d70436800e2a4c93e6487f621daa8735e88cf (diff)
downloadportage-d0a1b8bb01dece5fc18a6753ca9cda099b100deb.tar.gz
portage-d0a1b8bb01dece5fc18a6753ca9cda099b100deb.tar.bz2
portage-d0a1b8bb01dece5fc18a6753ca9cda099b100deb.zip
Inside depgraph._add_pkg(), handle the case where multiple different
instances of the same version (typically one installed and another not yet installed) have been pulled into the graph due to a USE dependency. The "slot collision" display is not helpful in a case like this, so display it as an unsatisfied dependency. Thanks to Peter Volkov <pva@g.o> for reporting. svn path=/main/trunk/; revision=11954
-rw-r--r--pym/_emerge/__init__.py14
1 files changed, 14 insertions, 0 deletions
diff --git a/pym/_emerge/__init__.py b/pym/_emerge/__init__.py
index 71fa4378d..23ca11fb6 100644
--- a/pym/_emerge/__init__.py
+++ b/pym/_emerge/__init__.py
@@ -4589,6 +4589,20 @@ class depgraph(object):
priority=priority)
return 1
else:
+
+ if pkg.cpv == existing_node.cpv and \
+ dep.atom is not None and \
+ dep.atom.use:
+ # Multiple different instances of the same version
+ # (typically one installed and another not yet
+ # installed) have been pulled into the graph due
+ # to a USE dependency. The "slot collision" display
+ # is not helpful in a case like this, so display it
+ # as an unsatisfied dependency.
+ self._unsatisfied_deps_for_display.append(
+ ((dep.root, dep.atom), {"myparent":dep.parent}))
+ return 0
+
if pkg in self._slot_collision_nodes:
return 1
# A slot collision has occurred. Sometimes this coincides