From 6e6b9c5928e175af42615542866fc9b3aef694e6 Mon Sep 17 00:00:00 2001 From: Zac Medico Date: Sun, 22 May 2011 16:48:42 -0700 Subject: _add_pkg_dep_string: handle satisfied virt_dep This fixes a problem with the asap LIBC_PACKAGE_ATOM test case for bug #303567. --- pym/_emerge/depgraph.py | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'pym/_emerge/depgraph.py') diff --git a/pym/_emerge/depgraph.py b/pym/_emerge/depgraph.py index caf150ac5..37fdeeda3 100644 --- a/pym/_emerge/depgraph.py +++ b/pym/_emerge/depgraph.py @@ -1571,6 +1571,20 @@ class depgraph(object): if not dep_priority.ignored or \ self._dynamic_config._traverse_ignored_deps: + + inst_pkgs = [inst_pkg for inst_pkg in vardb.match_pkgs(virt_dep.atom) + if not reinstall_atoms.findAtomForPackage(inst_pkg, + modified_use=self._pkg_use_enabled(inst_pkg))] + if inst_pkgs: + for inst_pkg in inst_pkgs: + if self._pkg_visibility_check(inst_pkg): + # highest visible + virt_dep.priority.satisfied = inst_pkg + break + if not virt_dep.priority.satisfied: + # none visible, so use highest + virt_dep.priority.satisfied = inst_pkgs[0] + if not self._add_pkg(virt_pkg, virt_dep): return 0 -- cgit v1.2.3-1-g7c22