summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2011-09-30 10:04:11 -0700
committerZac Medico <zmedico@gentoo.org>2011-09-30 10:04:11 -0700
commitc2efbad8402a7e8904c7353a9930e87ea128b962 (patch)
treee095a4b87a8a4cf22fdbc80c89c2d56c4ef6511d
parentd1a3c0f5ab81d1dbf70c0b8e5322cfb2d11b8ce7 (diff)
downloadportage-c2efbad8402a7e8904c7353a9930e87ea128b962.tar.gz
portage-c2efbad8402a7e8904c7353a9930e87ea128b962.tar.bz2
portage-c2efbad8402a7e8904c7353a9930e87ea128b962.zip
depgraph: tweak virtual transition code
This fixes a false --binpkg-respect-use warning that's triggered by erroneous USE/IUSE comparison between the new-style virtual and an old-style virtual match.
-rw-r--r--pym/_emerge/depgraph.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/pym/_emerge/depgraph.py b/pym/_emerge/depgraph.py
index 9638ce9a7..ad0455112 100644
--- a/pym/_emerge/depgraph.py
+++ b/pym/_emerge/depgraph.py
@@ -3689,6 +3689,8 @@ class depgraph(object):
if not isinstance(atom, portage.dep.Atom):
atom = portage.dep.Atom(atom)
atom_cp = atom.cp
+ have_new_virt = atom_cp.startswith("virtual/") and \
+ self._have_new_virt(root, atom_cp)
atom_set = InternalPackageSet(initial_atoms=(atom,), allow_repo=True)
existing_node = None
myeb = None
@@ -3736,6 +3738,9 @@ class depgraph(object):
# USE configuration.
for pkg in self._iter_match_pkgs(root_config, pkg_type, atom.without_use,
onlydeps=onlydeps):
+ if pkg.cp != atom_cp and have_new_virt:
+ # pull in a new-style virtual instead
+ continue
if pkg in self._dynamic_config._runtime_pkg_mask:
# The package has been masked by the backtracking logic
continue
@@ -3954,11 +3959,6 @@ class depgraph(object):
if not e_pkg:
break
- if e_pkg.cp != atom_cp and \
- self._have_new_virt(root, atom_cp):
- # pull in a new-style virtual instead
- break
-
# Use PackageSet.findAtomForPackage()
# for PROVIDE support.
if atom_set.findAtomForPackage(e_pkg, modified_use=self._pkg_use_enabled(e_pkg)):