summaryrefslogtreecommitdiffstats
path: root/meta
diff options
context:
space:
mode:
Diffstat (limited to 'meta')
-rw-r--r--meta/classes-global/license.bbclass10
1 files changed, 8 insertions, 2 deletions
diff --git a/meta/classes-global/license.bbclass b/meta/classes-global/license.bbclass
index b2e0d3faba..d7c5d08a77 100644
--- a/meta/classes-global/license.bbclass
+++ b/meta/classes-global/license.bbclass
@@ -18,8 +18,14 @@ LICENSE_CREATE_PACKAGE ??= "0"
18LICENSE_PACKAGE_SUFFIX ??= "-lic" 18LICENSE_PACKAGE_SUFFIX ??= "-lic"
19LICENSE_FILES_DIRECTORY ??= "${datadir}/licenses/" 19LICENSE_FILES_DIRECTORY ??= "${datadir}/licenses/"
20 20
21LICENSE_DEPLOY_PATHCOMPONENT = "${SSTATE_PKGARCH}"
22LICENSE_DEPLOY_PATHCOMPONENT:class-cross = "native"
23LICENSE_DEPLOY_PATHCOMPONENT:class-native = "native"
24# Ensure the *value* of SSTATE_PKGARCH is captured as it is used in the output paths
25LICENSE_DEPLOY_PATHCOMPONENT[vardepvalue] += "${LICENSE_DEPLOY_PATHCOMPONENT}"
26
21addtask populate_lic after do_patch before do_build 27addtask populate_lic after do_patch before do_build
22do_populate_lic[dirs] = "${LICSSTATEDIR}/${PN}" 28do_populate_lic[dirs] = "${LICSSTATEDIR}/${LICENSE_DEPLOY_PATHCOMPONENT}/${PN}"
23do_populate_lic[cleandirs] = "${LICSSTATEDIR}" 29do_populate_lic[cleandirs] = "${LICSSTATEDIR}"
24 30
25python do_populate_lic() { 31python do_populate_lic() {
@@ -29,7 +35,7 @@ python do_populate_lic() {
29 lic_files_paths = find_license_files(d) 35 lic_files_paths = find_license_files(d)
30 36
31 # The base directory we wrangle licenses to 37 # The base directory we wrangle licenses to
32 destdir = os.path.join(d.getVar('LICSSTATEDIR'), d.getVar('SSTATE_PKGARCH'), d.getVar('PN')) 38 destdir = os.path.join(d.getVar('LICSSTATEDIR'), d.getVar('LICENSE_DEPLOY_PATHCOMPONENT'), d.getVar('PN'))
33 copy_license_files(lic_files_paths, destdir) 39 copy_license_files(lic_files_paths, destdir)
34 info = get_recipe_info(d) 40 info = get_recipe_info(d)
35 with open(os.path.join(destdir, "recipeinfo"), "w") as f: 41 with open(os.path.join(destdir, "recipeinfo"), "w") as f: