From: Saul Wold <saul.wold@windriver.com>
To: openembedded-core@lists.openembedded.org,
bruce.ashfield@gmail.com, JPEWhacker@gmail.com
Cc: Saul Wold <saul.wold@windriver.com>
Subject: [RFC PATCH v2 1/3] create-spdx: Add kernel work-shared source
Date: Tue, 11 Jan 2022 15:58:38 -0800 [thread overview]
Message-ID: <20220111235840.81471-2-saul.wold@windriver.com> (raw)
In-Reply-To: <20220111235840.81471-1-saul.wold@windriver.com>
Since the kernel source is stored in work-shared, we need to add it
to the search path so the kernel and kernel-modules source code can
be found correctly.
Signed-off-by: Saul Wold <saul.wold@windriver.com>
---
meta/classes/create-spdx.bbclass | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/meta/classes/create-spdx.bbclass b/meta/classes/create-spdx.bbclass
index 0a4db80aba5..e1ff2bbb787 100644
--- a/meta/classes/create-spdx.bbclass
+++ b/meta/classes/create-spdx.bbclass
@@ -254,6 +254,7 @@ def add_package_sources_from_debug(d, package_doc, spdx_package, package, packag
Path(d.getVar('PKGD')),
Path(d.getVar('STAGING_DIR_TARGET')),
Path(d.getVar('STAGING_DIR_NATIVE')),
+ Path(d.getVar('STAGING_KERNEL_DIR')),
]
pkg_data = oe.packagedata.read_subpkgdata_extended(package, d)
@@ -275,7 +276,10 @@ def add_package_sources_from_debug(d, package_doc, spdx_package, package, packag
for debugsrc in file_data["debugsrc"]:
ref_id = "NOASSERTION"
for search in debug_search_paths:
- debugsrc_path = search / debugsrc.lstrip("/")
+ if debugsrc.startswith("/usr/src/kernel"):
+ debugsrc_path = search / debugsrc.replace('/usr/src/kernel/', '')
+ else:
+ debugsrc_path = search / debugsrc.lstrip("/")
if not debugsrc_path.exists():
continue
--
2.31.1
next prev parent reply other threads:[~2022-01-11 23:59 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-01-11 23:58 [RFC PATCH v2 0/3] Extend create-spdx to build kernel spdx info Saul Wold
2022-01-11 23:58 ` Saul Wold [this message]
2022-01-11 23:58 ` [RFC PATCH v2 2/3] package: Add support for kernel stripping Saul Wold
2022-01-12 14:21 ` Bruce Ashfield
2022-01-11 23:58 ` [RFC PATCH v2 3/3] kernel.bbclass: use common strip() Saul Wold
2022-01-12 14:30 ` Bruce Ashfield
2022-01-12 15:42 ` Saul Wold
2022-01-12 14:30 ` [RFC PATCH v2 0/3] Extend create-spdx to build kernel spdx info Bruce Ashfield
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20220111235840.81471-2-saul.wold@windriver.com \
--to=saul.wold@windriver.com \
--cc=JPEWhacker@gmail.com \
--cc=bruce.ashfield@gmail.com \
--cc=openembedded-core@lists.openembedded.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox