diff options
author | Saul Wold <Saul.Wold@windriver.com> | 2021-10-26 18:30:50 -0700 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2021-10-28 14:16:31 +0100 |
commit | 540182dd5bc40af06a370692845d2bb4f6736f5d (patch) | |
tree | 18e8e255a72d72206d1650045bf6f23423dbc9e9 | |
parent | 36c184344eb9db87f06ed42f3391ca7c8d83de19 (diff) | |
download | poky-540182dd5bc40af06a370692845d2bb4f6736f5d.tar.gz |
create-spdx: cross recipes are native also
Recipes that inherit cross should also be categorized as isNative
(From OE-Core rev: ee113e3894deb1cfb18622085a3fe0600e1ef01d)
Signed-off-by: Saul Wold <saul.wold@windriver.com>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r-- | meta/classes/create-spdx.bbclass | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/meta/classes/create-spdx.bbclass b/meta/classes/create-spdx.bbclass index aa9514121d..c35dbe1184 100644 --- a/meta/classes/create-spdx.bbclass +++ b/meta/classes/create-spdx.bbclass | |||
@@ -422,7 +422,7 @@ python do_create_spdx() { | |||
422 | recipe.name = d.getVar("PN") | 422 | recipe.name = d.getVar("PN") |
423 | recipe.versionInfo = d.getVar("PV") | 423 | recipe.versionInfo = d.getVar("PV") |
424 | recipe.SPDXID = oe.sbom.get_recipe_spdxid(d) | 424 | recipe.SPDXID = oe.sbom.get_recipe_spdxid(d) |
425 | if bb.data.inherits_class("native", d): | 425 | if bb.data.inherits_class("native", d) or bb.data.inherits_class("cross", d): |
426 | recipe.annotations.append(create_annotation(d, "isNative")) | 426 | recipe.annotations.append(create_annotation(d, "isNative")) |
427 | 427 | ||
428 | for s in d.getVar('SRC_URI').split(): | 428 | for s in d.getVar('SRC_URI').split(): |
@@ -614,7 +614,7 @@ python do_create_runtime_spdx() { | |||
614 | 614 | ||
615 | deploy_dir_spdx = Path(d.getVar("DEPLOY_DIR_SPDX")) | 615 | deploy_dir_spdx = Path(d.getVar("DEPLOY_DIR_SPDX")) |
616 | spdx_deploy = Path(d.getVar("SPDXRUNTIMEDEPLOY")) | 616 | spdx_deploy = Path(d.getVar("SPDXRUNTIMEDEPLOY")) |
617 | is_native = bb.data.inherits_class("native", d) | 617 | is_native = bb.data.inherits_class("native", d) or bb.data.inherits_class("cross", d) |
618 | 618 | ||
619 | creation_time = datetime.now(tz=timezone.utc).strftime("%Y-%m-%dT%H:%M:%SZ") | 619 | creation_time = datetime.now(tz=timezone.utc).strftime("%Y-%m-%dT%H:%M:%SZ") |
620 | 620 | ||