From: Ross Burton <ross.burton@arm.com>
To: openembedded-core@lists.openembedded.org
Subject: [PATCH v2 2/7] sbom-cve-check-update-db: Fix unpack removing other databases
Date: Tue, 7 Apr 2026 22:02:21 +0100 [thread overview]
Message-ID: <20260407210226.2375631-2-ross.burton@arm.com> (raw)
In-Reply-To: <20260407210226.2375631-1-ross.burton@arm.com>
From: Benjamin Robin <benjamin.robin@bootlin.com>
Previously, `UNPACKDIR` was set to `${SBOM_CVE_CHECK_DEPLOY_DB_DIR}`,
which points to the `./databases/` directory and may contain multiple
databases. Since `do_unpack` cleans the `${UNPACKDIR}` directory,
`UNPACKDIR` must only contain a single database.
To address this, set `UNPACKDIR` to
`${SBOM_CVE_CHECK_DEPLOY_DB_DIR}/${SBOM_CVE_CHECK_DB_NAME}` and
configure `destsuffix` to an empty string. However, it is currently not
possible to set `BB_GIT_DEFAULT_DESTSUFFIX` to an empty string, so
`destsuffix` is configured through the SRC_URI instead.
Signed-off-by: Benjamin Robin <benjamin.robin@bootlin.com>
Tested-by: Antonin Godard <antonin.godard@bootlin.com>
---
.../sbom-cve-check/sbom-cve-check-update-cvelist-native.bb | 2 +-
.../sbom-cve-check/sbom-cve-check-update-db.inc | 3 +--
.../sbom-cve-check/sbom-cve-check-update-nvd-native.bb | 4 ++--
3 files changed, 4 insertions(+), 5 deletions(-)
diff --git a/meta/recipes-devtools/sbom-cve-check/sbom-cve-check-update-cvelist-native.bb b/meta/recipes-devtools/sbom-cve-check/sbom-cve-check-update-cvelist-native.bb
index ce204db6c5..3387122165 100644
--- a/meta/recipes-devtools/sbom-cve-check/sbom-cve-check-update-cvelist-native.bb
+++ b/meta/recipes-devtools/sbom-cve-check/sbom-cve-check-update-cvelist-native.bb
@@ -3,7 +3,7 @@ LICENSE = "MIT"
LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/MIT;md5=0835ade698e0bcf8506ecda2f7b4f302"
HOMEPAGE = "https://github.com/CVEProject/cvelistV5"
-SRC_URI = "git://github.com/CVEProject/cvelistV5.git;branch=main;protocol=https"
+SRC_URI = "git://github.com/CVEProject/cvelistV5.git;branch=main;protocol=https;destsuffix="
SBOM_CVE_CHECK_DB_NAME = "cvelist"
# 2026-03-19_baseline
diff --git a/meta/recipes-devtools/sbom-cve-check/sbom-cve-check-update-db.inc b/meta/recipes-devtools/sbom-cve-check/sbom-cve-check-update-db.inc
index a318e2c40e..7ada67363d 100644
--- a/meta/recipes-devtools/sbom-cve-check/sbom-cve-check-update-db.inc
+++ b/meta/recipes-devtools/sbom-cve-check/sbom-cve-check-update-db.inc
@@ -15,6 +15,5 @@ deltask do_install
deltask do_populate_sysroot
# Directly unpack the fetched CVE database to the deploy directory.
-UNPACKDIR = "${SBOM_CVE_CHECK_DEPLOY_DB_DIR}"
+UNPACKDIR = "${SBOM_CVE_CHECK_DEPLOY_DB_DIR}/${SBOM_CVE_CHECK_DB_NAME}"
S = "${UNPACKDIR}"
-BB_GIT_DEFAULT_DESTSUFFIX = "${SBOM_CVE_CHECK_DB_NAME}"
diff --git a/meta/recipes-devtools/sbom-cve-check/sbom-cve-check-update-nvd-native.bb b/meta/recipes-devtools/sbom-cve-check/sbom-cve-check-update-nvd-native.bb
index 30c7868b2a..c868ba09c1 100644
--- a/meta/recipes-devtools/sbom-cve-check/sbom-cve-check-update-nvd-native.bb
+++ b/meta/recipes-devtools/sbom-cve-check/sbom-cve-check-update-nvd-native.bb
@@ -1,9 +1,9 @@
SUMMARY = "Updates the NVD CVE database"
LICENSE = "cve-tou"
-LIC_FILES_CHKSUM = "file://${SBOM_CVE_CHECK_DB_NAME}/LICENSES/cve-tou.md;md5=bc5bbf146f01e20ece63d83c8916d8fb"
+LIC_FILES_CHKSUM = "file://LICENSES/cve-tou.md;md5=bc5bbf146f01e20ece63d83c8916d8fb"
HOMEPAGE = "https://github.com/fkie-cad/nvd-json-data-feeds"
-SRC_URI = "git://github.com/fkie-cad/nvd-json-data-feeds.git;branch=main;protocol=https"
+SRC_URI = "git://github.com/fkie-cad/nvd-json-data-feeds.git;branch=main;protocol=https;destsuffix="
SBOM_CVE_CHECK_DB_NAME = "nvd-fkie"
# v2026.03.19-010002
--
2.43.0
next prev parent reply other threads:[~2026-04-07 21:03 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-04-07 21:02 [PATCH v2 1/7] sbom-cve-check-update-db: Fix do_populate_lic failure Ross Burton
2026-04-07 21:02 ` Ross Burton [this message]
2026-04-13 7:01 ` [OE-core] [PATCH v2 2/7] sbom-cve-check-update-db: Fix unpack removing other databases Yu, Mingli
2026-04-07 21:02 ` [PATCH v2 3/7] sbom-cve-check-config.inc: move to meta/conf/ Ross Burton
2026-04-07 21:02 ` [PATCH v2 4/7] classes/sbom-cve-check: refactor do_sbom_cve_check Ross Burton
2026-04-07 21:02 ` [PATCH v2 5/7] classes/sbom-cve-check: extract the database dependencies to a variable Ross Burton
2026-04-07 21:02 ` [PATCH v2 6/7] classes/sbom-cve-check: extract common functionality to a -common.bbclass Ross Burton
2026-04-07 21:02 ` [PATCH v2 7/7] classes/sbom-cve-check-recipe: add recipe-scanning class Ross Burton
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=20260407210226.2375631-2-ross.burton@arm.com \
--to=ross.burton@arm.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