]> code.ossystems Code Review - meta-freescale.git/commitdiff
fsl-eula-unpack.bbclass: Verify LICENSE contains Proprietary
authorTom Hochstein <tom.hochstein@nxp.com>
Tue, 3 Mar 2020 20:30:45 +0000 (14:30 -0600)
committerOtavio Salvador <otavio@ossystems.com.br>
Mon, 13 Apr 2020 22:18:30 +0000 (19:18 -0300)
All EULA packages are proprietary, so verify that the recipe LICENSE
contains Proprietary before fetching the package.

Signed-off-by: Tom Hochstein <tom.hochstein@nxp.com>
(cherry picked from commit b8b557ff8b667f74064f8badd490b6ece4945ff9)

classes/fsl-eula-unpack.bbclass

index 9b8f2af69e225df67c851b9663f35c5031035654..0e7ef9d6808151ad7b4d50e0f436be0b5cd54683 100644 (file)
@@ -10,6 +10,11 @@ LIC_FILES_CHKSUM_append = " file://${FSL_EULA_FILE};md5=ab61cab9599935bfe9f70040
 
 LIC_FILES_CHKSUM[vardepsexclude] += "FSL_EULA_FILE"
 
+do_fetch_prepend() {
+    if "Proprietary" not in d.getVar("LICENSE"):
+        bb.fatal("The recipe LICENSE should include Proprietary but is " + d.getVar("LICENSE") + ".")
+}
+
 python fsl_bin_do_unpack() {
     src_uri = (d.getVar('SRC_URI') or "").split()
     if len(src_uri) == 0: