]> 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>
Tue, 3 Mar 2020 21:24:53 +0000 (18:24 -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>
classes/fsl-eula-unpack.bbclass

index 7b62f08986e300e354a0227be03ccc330ea9c1cd..85099542a291e4eed23df95a383eb970d21b7972 100644 (file)
@@ -10,6 +10,11 @@ LIC_FILES_CHKSUM_append = " file://${FSL_EULA_FILE};md5=6c12031a11b81db21cdfe0be
 
 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: