diff options
| author | Kamel Bouhara (Schneider Electric) <kamel.bouhara@bootlin.com> | 2025-12-15 16:54:23 +0100 |
|---|---|---|
| committer | Steve Sakoman <steve@sakoman.com> | 2025-12-31 07:49:31 -0800 |
| commit | 707dce4f01527b23e775ec31282e94c3a74e71da (patch) | |
| tree | 7f68abc88ad47399689d7c9571dd504abf3da3ee /meta/classes | |
| parent | 6d222750d5c3254c200259a1ff6ac7c691a7cd7d (diff) | |
| download | poky-707dce4f01527b23e775ec31282e94c3a74e71da.tar.gz | |
spdx30_tasks: Add support for exporting PACKAGECONFIG to SPDX
Introduce the SPDX_INCLUDE_PACKAGECONFIG variable, which when enabled causes
PACKAGECONFIG features to be recorded in the SPDX document as build parameters.
Each feature is recorded as a DictionaryEntry with key PACKAGECONFIG:<feature>
and value enabled or disabled, depending on whether the feature is active in
the current build.
This makes the build-time configuration more transparent in SPDX output and
improves reproducibility tracking.
This makes the build-time configuration more transparent in SPDX output and
improves reproducibility tracking. In particular, it allows consumers of the
SBOM to identify enabled/disabled features that may affect security posture
or feature set.
Reviewed-by: Joshua Watt <JPEWhacker@gmail.com>
(From OE-Core rev: 5cfd0690f819379d9f97c86d2078c3e529efe385)
Signed-off-by: Kamel Bouhara (Schneider Electric) <kamel.bouhara@bootlin.com>
Signed-off-by: Mathieu Dubois-Briand <mathieu.dubois-briand@bootlin.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
(cherry picked from commit 7ec61ac40345a5c0ef1ce20513a4596989c91ef4)
Signed-off-by: Steve Sakoman <steve@sakoman.com>
Diffstat (limited to 'meta/classes')
| -rw-r--r-- | meta/classes/create-spdx-3.0.bbclass | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/meta/classes/create-spdx-3.0.bbclass b/meta/classes/create-spdx-3.0.bbclass index 15c31ba9a3..6125e8b547 100644 --- a/meta/classes/create-spdx-3.0.bbclass +++ b/meta/classes/create-spdx-3.0.bbclass | |||
| @@ -56,6 +56,11 @@ and each CONFIG_* value will be included in the Build.build_parameter list as Di | |||
| 56 | items. Set to '0' to disable exporting kernel configuration to improve performance or reduce \ | 56 | items. Set to '0' to disable exporting kernel configuration to improve performance or reduce \ |
| 57 | SPDX document size." | 57 | SPDX document size." |
| 58 | 58 | ||
| 59 | SPDX_INCLUDE_PACKAGECONFIG ??= "0" | ||
| 60 | SPDX_INCLUDE_PACKAGECONFIG[doc] = "If set to '1', each PACKAGECONFIG feature is recorded in the \ | ||
| 61 | build_Build object's build_parameter list as a DictionaryEntry with key \ | ||
| 62 | 'PACKAGECONFIG:<feature>' and value 'enabled' or 'disabled'" | ||
| 63 | |||
| 59 | SPDX_IMPORTS ??= "" | 64 | SPDX_IMPORTS ??= "" |
| 60 | SPDX_IMPORTS[doc] = "SPDX_IMPORTS is the base variable that describes how to \ | 65 | SPDX_IMPORTS[doc] = "SPDX_IMPORTS is the base variable that describes how to \ |
| 61 | reference external SPDX ids. Each import is defined as a key in this \ | 66 | reference external SPDX ids. Each import is defined as a key in this \ |
