All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2] insane.bbclass: Warn if ${COREBASE}/LICENSE is used
@ 2017-09-01 21:53 Saul Wold
  0 siblings, 0 replies; only message in thread
From: Saul Wold @ 2017-09-01 21:53 UTC (permalink / raw)
  To: openembedded-core, richard.purdie

The top level LICENSE file is not actually a license, it refers
other licenses that are used by Bitbake and Meta-data. Relying
on this file could cause problems for recipes when this file
changes, which it is about to.

(From OE-Core rev: a1948ab38c9cb7f0b16cce9dadc03ae6e2fe44ad)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
---
v2: Made one bb.warn instead of 2 and changed up comment

Available in poky-contrib/sgw/insane

 meta/classes/insane.bbclass | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/meta/classes/insane.bbclass b/meta/classes/insane.bbclass
index 3906ba7..aa304f1 100644
--- a/meta/classes/insane.bbclass
+++ b/meta/classes/insane.bbclass
@@ -589,7 +589,7 @@ python populate_lic_qa_checksum() {
         sane = package_qa_handle_error("license-checksum", pn + ": Recipe file fetches files and does not have license file information (LIC_FILES_CHKSUM)", d)
 
     srcdir = d.getVar('S')
-
+    corebase_licensefile = d.getVar('COREBASE') + "/LICENSE"
     for url in lic_files.split():
         try:
             (type, host, path, user, pswd, parm) = bb.fetch.decodeurl(url)
@@ -601,6 +601,9 @@ python populate_lic_qa_checksum() {
             package_qa_handle_error("license-checksum", pn + ": LIC_FILES_CHKSUM points to an invalid file: " + srclicfile, d)
             continue
 
+        if (srclicfile == corebase_licensefile):
+            bb.warn("${COREBASE}/LICENSE is not a valid license file, please use '${COMMON_LICENSE_DIR}/MIT' for a MIT License file in LIC_FILES_CHKSUM. This will become an error in the future")
+
         recipemd5 = parm.get('md5', '')
         beginline, endline = 0, 0
         if 'beginline' in parm:
-- 
2.7.5



^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2017-09-01 21:53 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-09-01 21:53 [PATCH v2] insane.bbclass: Warn if ${COREBASE}/LICENSE is used Saul Wold

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.