diff options
author | Zac Medico <zmedico@gentoo.org> | 2007-10-12 06:58:10 +0000 |
---|---|---|
committer | Zac Medico <zmedico@gentoo.org> | 2007-10-12 06:58:10 +0000 |
commit | ab145da5745dcd048f8317c5fe80326cfe14afaa (patch) | |
tree | 219c138e6a4fcd6e8623d2f326147672d965de34 /bin/emerge | |
parent | 50c2afc6ff46e58cbae193aac96736f845bc5552 (diff) | |
download | portage-ab145da5745dcd048f8317c5fe80326cfe14afaa.tar.gz portage-ab145da5745dcd048f8317c5fe80326cfe14afaa.tar.bz2 portage-ab145da5745dcd048f8317c5fe80326cfe14afaa.zip |
Bug #195370 - Prevent bogus upgrade display when a
new-style virtual is first installed and it replaces
an old-style virtual. (trunk r8039)
svn path=/main/branches/2.1.2/; revision=8070
Diffstat (limited to 'bin/emerge')
-rwxr-xr-x | bin/emerge | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/bin/emerge b/bin/emerge index af1042c8f..e93872291 100755 --- a/bin/emerge +++ b/bin/emerge @@ -2957,10 +2957,15 @@ class depgraph: counters.reinst += 1 elif vardb.match(portage.dep_getkey(pkg_key)): mynewslot = mydbapi.aux_get(pkg_key, ["SLOT"])[0] - myoldlist = self.trees[x[1]]["vartree"].dbapi.match( - portage.pkgsplit(x[2])[0]) - myinslotlist = [inst_pkg for inst_pkg in myoldlist - if mynewslot == vardb.aux_get(inst_pkg, ["SLOT"])[0]] + slot_atom = "%s:%s" % \ + (portage.cpv_getkey(pkg_key), mynewslot) + myinslotlist = vardb.match(slot_atom) + # If this is the first install of a new-style virtual, we + # need to filter out old-style virtual matches. + if myinslotlist and \ + portage.cpv_getkey(myinslotlist[0]) != \ + portage.cpv_getkey(pkg_key): + myinslotlist = None if myinslotlist: myoldbest=portage.best(myinslotlist) addl=" "+fetch |