summaryrefslogtreecommitdiffstats
path: root/cmake/Functions.cmake
diff options
context:
space:
mode:
authorMoss Heim <moss.heim@qt.io>2024-10-24 16:57:36 +0200
committerMoss Heim <moss.heim@qt.io>2025-02-09 09:09:33 +0100
commitc6b93f4f638ada62c5e9257964387d303efd7be6 (patch)
tree73ad248d9299810e07c12f81c68c478ff1e8876a /cmake/Functions.cmake
parent7feb1ff93040ad1e40e86fadf04c107aa9f4806c (diff)
CMake: Generate SBOM for Chromium dependencies
This commit adds CMake tooling for generating SBOM documents covering Chromium dependencies. It hooks into our existing add_ninja_command() calls, so any top-level target built in Chromium build trees (convert_dict, QtPdf, etc.) is covered. There is also a wrapper script for the newly written sbom.py in Chromium, like we have a wrapper for licenses.py. It is designed to be called once per Pdf / WebEngineCore, passing in all the gn-specific build targets for each module. This is in an experimental state, and bugs should be expected especially with multi-config and Windows builds. Task-number: QTBUG-131377 Pick-to: 6.9 Change-Id: I792a460b86e1b79d0b32838b7e1303bc8bc4e25b Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io> Reviewed-by: Michal Klocek <michal.klocek@qt.io>
Diffstat (limited to 'cmake/Functions.cmake')
-rw-r--r--cmake/Functions.cmake2
1 files changed, 2 insertions, 0 deletions
diff --git a/cmake/Functions.cmake b/cmake/Functions.cmake
index d309c6e49..30a5a77be 100644
--- a/cmake/Functions.cmake
+++ b/cmake/Functions.cmake
@@ -972,6 +972,8 @@ function(add_gn_build_artifacts_to_target)
MODULE ${arg_MODULE}
DEPENDS ${arg_DEPENDS}
)
+ qt_webengine_add_gn_target_to_sbom(${arg_NINJA_TARGET} ${arg_BUILDDIR}/${config}/${arch})
+ qt_webengine_add_gn_artifact_relationship_to_sbom(${arg_NINJA_TARGET} ${arg_CMAKE_TARGET})
add_dependencies(run_${arg_MODULE}_NinjaDone ${target})
set_target_properties(${arg_CMAKE_TARGET} PROPERTIES
LINK_DEPENDS ${arg_BUILDDIR}/${config}/${arch}/${arg_NINJA_STAMP}