Fix license_groups parsing to stack the lists, so license_groups from overlays
authorZac Medico <zmedico@gentoo.org>
Mon, 19 Oct 2009 19:44:16 +0000 (19:44 -0000)
committerZac Medico <zmedico@gentoo.org>
Mon, 19 Oct 2009 19:44:16 +0000 (19:44 -0000)
extend groups from the main tree instead of overwritting them. Thanks to
Vlastimil Babka <caster@g.o> for reporting.

svn path=/main/trunk/; revision=14696

pym/portage/__init__.py

index 82fb80edd07b40efe641059d3f5675ebd52d001b..ab777010be1b3275c5b86aaf15ff7ba4e5773686 100644 (file)
@@ -2132,9 +2132,11 @@ class config(object):
                                        self.pprovideddict[mycatpkg]=[x]
 
                        # parse licensegroups
+                       license_groups = self._license_groups
                        for x in locations:
-                               self._license_groups.update(
-                                       grabdict(os.path.join(x, "license_groups")))
+                               for k, v in grabdict(
+                                       os.path.join(x, "license_groups")).items():
+                                       license_groups.setdefault(k, []).extend(v)
 
                        # reasonable defaults; this is important as without USE_ORDER,
                        # USE will always be "" (nothing set)!