summaryrefslogtreecommitdiffstats
path: root/package/Makefile
diff options
context:
space:
mode:
authorPetr Štetiar <ynezz@true.cz>2023-10-24 08:27:13 +0000
committerPetr Štetiar <ynezz@true.cz>2023-11-01 11:14:41 +0000
commitd604a07225c5c82b942cd3374cc113ad676a2519 (patch)
tree716b236d86df66ca729fd12bba72b3f2a462d336 /package/Makefile
parent649655f427932fe79b96a41f883c8054b1806191 (diff)
downloadopenwrt-d604a07225c5c82b942cd3374cc113ad676a2519.tar.gz
openwrt-d604a07225c5c82b942cd3374cc113ad676a2519.tar.bz2
openwrt-d604a07225c5c82b942cd3374cc113ad676a2519.zip
build: add CycloneDX SBOM JSON support
CycloneDX is an open source standard developed by the OWASP foundation. It supports a wide range of development ecosystems, a comprehensive set of use cases, and focuses on automation, ease of adoption, and progressive enhancement of SBOMs (Software Bill Of Materials) throughout build pipelines. So lets add support for CycloneDX SBOM for packages and images manifests. Signed-off-by: Petr Štetiar <ynezz@true.cz>
Diffstat (limited to 'package/Makefile')
-rw-r--r--package/Makefile8
1 files changed, 8 insertions, 0 deletions
diff --git a/package/Makefile b/package/Makefile
index 4b8df7f484..8e72d4ec72 100644
--- a/package/Makefile
+++ b/package/Makefile
@@ -106,6 +106,14 @@ ifdef CONFIG_SIGNED_PACKAGES
$(STAGING_DIR_HOST)/bin/usign -S -m Packages -s $(BUILD_KEY); \
); done
endif
+ifdef CONFIG_JSON_CYCLONEDX_SBOM
+ @echo Creating CycloneDX package SBOMs...
+ @for d in $(PACKAGE_SUBDIRS); do ( \
+ [ -d $$d ] && \
+ cd $$d || continue; \
+ $(SCRIPT_DIR)/package-metadata.pl pkgcyclonedxsbom Packages.manifest > Packages.bom.cdx.json || true; \
+ ); done
+endif
$(curdir)/flags-install:= -j1