diff options
author | Zac Medico <zmedico@gentoo.org> | 2009-06-30 22:49:24 +0000 |
---|---|---|
committer | Zac Medico <zmedico@gentoo.org> | 2009-06-30 22:49:24 +0000 |
commit | 3cd307d36e3fe71470eeca7f95cc6b288c16eb11 (patch) | |
tree | e8c1c76850da543d7c018d3ed123049810db1207 | |
parent | 50a000bb1805d4b1565271d16c4d4b2c36d32085 (diff) | |
download | portage-3cd307d36e3fe71470eeca7f95cc6b288c16eb11.tar.gz portage-3cd307d36e3fe71470eeca7f95cc6b288c16eb11.tar.bz2 portage-3cd307d36e3fe71470eeca7f95cc6b288c16eb11.zip |
Fix _expand_new_virtuals to expand old-style virtuals for package.provided
entries when there is no other choice.
svn path=/main/trunk/; revision=13748
-rw-r--r-- | pym/portage/__init__.py | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/pym/portage/__init__.py b/pym/portage/__init__.py index a187bf568..0d095149c 100644 --- a/pym/portage/__init__.py +++ b/pym/portage/__init__.py @@ -6886,6 +6886,7 @@ def _expand_new_virtuals(mysplit, edebug, mydbapi, mysettings, myroot="/", if kwargs["use_binaries"]: portdb = trees[myroot]["bintree"].dbapi myvirtuals = mysettings.getvirtuals() + pprovideddict = mysettings.pprovideddict myuse = kwargs["myuse"] for x in mysplit: if x == "||": @@ -7024,6 +7025,14 @@ def _expand_new_virtuals(mysplit, edebug, mydbapi, mysettings, myroot="/", portdb.aux_get(matches[-1], ['PROVIDE'])[0].split(): a.append(new_atom) + if not a and not isblocker and mychoices: + # Check for a virtual package.provided match. + for y in mychoices: + new_atom = portage.dep.Atom(x.replace(mykey, y, 1)) + if match_from_list(new_atom, + pprovideddict.get(new_atom.cp, [])): + a.append(new_atom) + if not a: newsplit.append(x) elif len(a) == 1: |