Make the fix for bug #220341 better by checking all selected packages for
authorZac Medico <zmedico@gentoo.org>
Fri, 9 May 2008 02:15:10 +0000 (02:15 -0000)
committerZac Medico <zmedico@gentoo.org>
Fri, 9 May 2008 02:15:10 +0000 (02:15 -0000)
matching cpv rather than just the last one. (trunk r10256)

svn path=/main/branches/2.1.2/; revision=10257

bin/emerge

index 02bcffc10f5e2fe2f51d24481739d82b5900eb51..f0d0a647c5e887be55006b84537dde7cf08fccdb 100755 (executable)
@@ -3092,9 +3092,11 @@ class depgraph(object):
                                # Therefore, assume that such SLOT dependencies are already
                                # satisfied rather than forcing a rebuild.
                                if installed and not cpv_list and matched_packages \
-                                       and vardb.cpv_exists(matched_packages[-1].cpv) and \
-                                       portage_dep.dep_getslot(atom):
-                                       cpv_list = [matched_packages[-1].cpv]
+                                       and portage_dep.dep_getslot(atom):
+                                       for pkg in matched_packages:
+                                               if vardb.cpv_exists(pkg.cpv):
+                                                       cpv_list = [pkg.cpv]
+                                                       break
 
                                if not cpv_list:
                                        continue