summaryrefslogtreecommitdiffstats
path: root/pym
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2011-09-24 13:58:16 -0700
committerZac Medico <zmedico@gentoo.org>2011-09-24 13:58:16 -0700
commit75907929be736e2d4cf088d8d9861f2666e59557 (patch)
treeef83dad5a0c00691596f2ecef7b695e5dcbe337f /pym
parent5e587e1db10e38f003462f8171bd4d838cc095be (diff)
downloadportage-75907929be736e2d4cf088d8d9861f2666e59557.tar.gz
portage-75907929be736e2d4cf088d8d9861f2666e59557.tar.bz2
portage-75907929be736e2d4cf088d8d9861f2666e59557.zip
portdbapi.xmatch: optimize minimum-visible
Also, make repoman cache IUSE, since that's required for _match_use to work effciently. This will eliminate lots of redundant aux_get calls for repoman, triggered by USE deps.
Diffstat (limited to 'pym')
-rw-r--r--pym/portage/dbapi/porttree.py14
1 files changed, 4 insertions, 10 deletions
diff --git a/pym/portage/dbapi/porttree.py b/pym/portage/dbapi/porttree.py
index 42e5ca168..782cecccc 100644
--- a/pym/portage/dbapi/porttree.py
+++ b/pym/portage/dbapi/porttree.py
@@ -957,16 +957,10 @@ class portdbapi(dbapi):
mydep.slot != metadata["SLOT"]:
continue
- if mydep.use is not None:
- mydep_with_repo = mydep
- if repo is not None and mydep.repo is None:
- mydep_with_repo = mydep.with_repo(repo)
- has_iuse = False
- for has_iuse in self._iter_match_use(
- mydep_with_repo, [cpv]):
- break
- if has_iuse is False:
- continue
+ if mydep.unevaluated_atom.use is not None and \
+ not self._match_use(mydep, cpv, metadata):
+ continue
+
myval = cpv
break
if myval: