[oe-commits] =?UTF-8?Q?An=C3=ADbal=20Lim=C3=B3n=20?=: license_class: Add explicity avoid of CLOSED license in validations

git at git.openembedded.org git at git.openembedded.org
Thu May 21 09:51:57 UTC 2015


Module: openembedded-core.git
Branch: master-next
Commit: f33651a46d12bb763a4e3c13438d084411406849
URL:    http://git.openembedded.org/?p=openembedded-core.git&a=commit;h=f33651a46d12bb763a4e3c13438d084411406849

Author: Aníbal Limón <anibal.limon at linux.intel.com>
Date:   Mon May 18 20:33:07 2015 +0000

license_class: Add explicity avoid of CLOSED license in validations

The CLOSED license isn't a generic license it is a set and can
be any closed source license.

[YOCTO #7752]

Signed-off-by: Aníbal Limón <anibal.limon at linux.intel.com>
Signed-off-by: Ross Burton <ross.burton at intel.com>

---

 meta/classes/license.bbclass | 10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)

diff --git a/meta/classes/license.bbclass b/meta/classes/license.bbclass
index 7972c79..756e7f0 100644
--- a/meta/classes/license.bbclass
+++ b/meta/classes/license.bbclass
@@ -80,6 +80,10 @@ python license_create_manifest() {
                 lic_file = os.path.join(d.getVar('LICENSE_DIRECTORY', True),
                                         pkg_dic[pkg]["PN"], "generic_%s" % 
                                         re.sub('\+', '', lic))
+                # add explicity avoid of CLOSED license because isn't generic
+                if lic == "CLOSED":
+                   continue
+
                 if not os.path.exists(lic_file):
                    bb.warn("The license listed %s was not in the "\ 
                             "licenses collected for recipe %s" 
@@ -278,8 +282,10 @@ def find_license_files(d):
                     lic_files_paths.append(("generic_" + license_type, path))
                     break
         else:
-            # And here is where we warn people that their licenses are lousy
-            bb.warn("%s: No generic license file exists for: %s in any provider" % (pn, license_type))
+            # Add explicity avoid of CLOSED license because this isn't generic
+            if license_type != 'CLOSED':
+                # And here is where we warn people that their licenses are lousy
+                bb.warn("%s: No generic license file exists for: %s in any provider" % (pn, license_type))
             pass
 
     if not generic_directory:



More information about the Openembedded-commits mailing list