[OE-core][PATCH v5 0/8] Add SPDX 3.0 support

Joshua Watt
2024-07-03T14:01:06Z

This patch series add support for SPDX 3.0 and sets it as the default.
Currently it is not possible to have SPDX 2.2 and SPDX 3.0 enabled at
the same time

v2: Added tests and addressed feedback
v3: Fixed several oe-selftest and build failures
v4: Fixed silly typo mistake in staging.bbclass
v5: Reworked to make SPDX 3 output reproducible by default. Variables
that introduce non-reproducible output are documented as such.

Joshua Watt (8):
classes-recipe/image: Add image file manifest
classes-recipe/baremetal-image: Add image file manifest
classes/create-spdx-3.0: Add classes
classes-global/staging: Exclude do_create_spdx from automatic sysroot
extension
classes-recipe/image_types: Add SPDX_IMAGE_PURPOSE to images
selftest: spdx: Add SPDX 3.0 test cases
classes-recipe: nospdx: Add class
Switch default spdx version to 3.0

meta/classes-global/staging.bbclass | 9 +-
meta/classes-recipe/baremetal-image.bbclass | 32 +-
meta/classes-recipe/image.bbclass | 58 +
meta/classes-recipe/image_types.bbclass | 2 +
meta/classes-recipe/image_types_wic.bbclass | 1 +
meta/classes-recipe/nospdx.bbclass | 13 +
meta/classes-recipe/packagegroup.bbclass | 2 +
meta/classes/create-spdx-3.0.bbclass | 1231 ++++
meta/classes/create-spdx-image-3.0.bbclass | 224 +
meta/classes/create-spdx.bbclass | 2 +-
meta/classes/spdx-common.bbclass | 6 +-
meta/lib/oe/sbom30.py | 1138 ++++
meta/lib/oe/spdx30.py | 5996 ++++++++++++++++++
meta/lib/oeqa/selftest/cases/spdx.py | 118 +-
meta/recipes-core/meta/build-sysroots.bb | 5 +-
meta/recipes-core/meta/meta-world-pkgdata.bb | 3 +-
16 files changed, 8819 insertions(+), 21 deletions(-)
create mode 100644 meta/classes-recipe/nospdx.bbclass
create mode 100644 meta/classes/create-spdx-3.0.bbclass
create mode 100644 meta/classes/create-spdx-image-3.0.bbclass
create mode 100644 meta/lib/oe/sbom30.py
create mode 100644 meta/lib/oe/spdx30.py

--
2.45.2