summaryrefslogtreecommitdiffstats
path: root/meta/classes
diff options
context:
space:
mode:
authorVladimir Zapolskiy <vladimir_zapolskiy@mentor.com>2012-09-11 04:18:14 +0300
committerRichard Purdie <richard.purdie@linuxfoundation.org>2012-09-12 15:13:43 +0100
commit043df837a5a4f87936c1e24057785e914ef52cce (patch)
tree0536bab767db834f062b8b920143491f022de6c7 /meta/classes
parented4836d319350e69052821d6a71682ee4b686c4b (diff)
downloadpoky-043df837a5a4f87936c1e24057785e914ef52cce.tar.gz
classes/license: account LICENSE_${pkg} values in manifest
Trivial change, process LICENSE_${pkg} and LICENSE values. This fixes multiple cases, when license is not specified at all in license.manifest (From OE-Core rev: 8fd734e6f9159921d0d148c4d5c0fa37c882b21a) Signed-off-by: Vladimir Zapolskiy <vladimir_zapolskiy@mentor.com> Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes')
-rw-r--r--meta/classes/license.bbclass7
1 files changed, 6 insertions, 1 deletions
diff --git a/meta/classes/license.bbclass b/meta/classes/license.bbclass
index 8fb66be502..74a830686e 100644
--- a/meta/classes/license.bbclass
+++ b/meta/classes/license.bbclass
@@ -101,8 +101,13 @@ license_create_manifest() {
101 continue 101 continue
102 fi 102 fi
103 103
104 pkged_lic="$(sed -n '/^LICENSE: /{ s/^LICENSE: //; s/[+|&()*]/ /g; s/ */ /g; p }' ${filename})"
105 pkged_pv="$(sed -n 's/^PV: //p' ${filename})" 104 pkged_pv="$(sed -n 's/^PV: //p' ${filename})"
105 pkged_name="$(basename $(readlink ${filename}))"
106 pkged_lic="$(sed -n "/^LICENSE_${pkged_name}: /{ s/^LICENSE_${pkged_name}: //; s/[+|&()*]/ /g; s/ */ /g; p }" ${filename})"
107 if [ -z ${pkged_lic} ]; then
108 # fallback checking value of LICENSE
109 pkged_lic="$(sed -n "/^LICENSE: /{ s/^LICENSE: //; s/[+|&()*]/ /g; s/ */ /g; p }" ${filename})"
110 fi
106 111
107 echo "PACKAGE NAME:" ${pkg} >> ${LICENSE_MANIFEST} 112 echo "PACKAGE NAME:" ${pkg} >> ${LICENSE_MANIFEST}
108 echo "PACKAGE VERSION:" ${pkged_pv} >> ${LICENSE_MANIFEST} 113 echo "PACKAGE VERSION:" ${pkged_pv} >> ${LICENSE_MANIFEST}