Use match-all-cpv-only in _show_unsatisfied_dep.
authorZac Medico <zmedico@gentoo.org>
Wed, 6 Oct 2010 04:01:08 +0000 (21:01 -0700)
committerZac Medico <zmedico@gentoo.org>
Wed, 6 Oct 2010 04:01:08 +0000 (21:01 -0700)
pym/_emerge/depgraph.py

index 28a7dd3b9c735cad5fd7a4a4803f5238e1fe90cc..4540004aeaf3506aecf2333b9426579cd16ea0dc 100644 (file)
@@ -2168,7 +2168,7 @@ class depgraph(object):
                                continue
                        match = db.match
                        if hasattr(db, "xmatch"):
-                               cpv_list = db.xmatch("match-all", atom.without_use)
+                               cpv_list = db.xmatch("match-all-cpv-only", atom.without_use)
                        else:
                                cpv_list = db.match(atom.without_use)
 
@@ -2192,16 +2192,12 @@ class depgraph(object):
                                                        repo = metadata.get('repository')
                                                pkg = self._pkg(cpv, pkg_type, root_config,
                                                        installed=installed, myrepo=repo)
+                                               if not atom_set.findAtomForPackage(pkg,
+                                                       modified_use=self._pkg_use_enabled(pkg)):
+                                                       continue
                                                # pkg.metadata contains calculated USE for ebuilds,
                                                # required later for getMissingLicenses.
                                                metadata = pkg.metadata
-                                               if pkg.cp != atom.cp:
-                                                       # A cpv can be returned from dbapi.match() as an
-                                                       # old-style virtual match even in cases when the
-                                                       # package does not actually PROVIDE the virtual.
-                                                       # Filter out any such false matches here.
-                                                       if not atom_set.findAtomForPackage(pkg, modified_use=self._pkg_use_enabled(pkg)):
-                                                               continue
                                                if pkg in self._dynamic_config._runtime_pkg_mask:
                                                        backtrack_reasons = \
                                                                self._dynamic_config._runtime_pkg_mask[pkg]