When generating ACCEPT_LICENSE for the ebuild environment, do not expand
authorZac Medico <zmedico@gentoo.org>
Tue, 5 May 2009 20:23:28 +0000 (20:23 -0000)
committerZac Medico <zmedico@gentoo.org>
Tue, 5 May 2009 20:23:28 +0000 (20:23 -0000)
*, since that would make it appear to the check_license() function as if
the user has accepted licenses which have not really been explicitly
accepted.

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

pym/portage/__init__.py

index 07adcd224290008b5862d4210bf31a780d51ec0f..93031b796648de58e9799e466de1571bf3e5ebf2 100644 (file)
@@ -2112,8 +2112,10 @@ class config(object):
                        except exception.InvalidDependString:
                                licenses = set()
                        licenses.discard('||')
-                       if '*' not in settings._accept_license:
-                               licenses.intersection_update(settings._accept_license)
+                       # Do not expand * here, since that would make it appear to the
+                       # check_license() function as if the user has accepted licenses
+                       # which have not really been explicitly accepted.
+                       licenses.intersection_update(settings._accept_license)
                        return ' '.join(sorted(licenses))
 
                def _restrict(self, use, settings):