diff mbox series

[2/2] bitbake.conf: Handle empty BB_CURRENT_MC

Message ID 20250124173926.2369699-2-richard.purdie@linuxfoundation.org
State Accepted, archived
Commit ff469ab2e865063bbc529031bbfd76cba5040073
Headers show
Series [1/2] oeqa/sshcontrol: Handle empty reads | expand

Commit Message

Richard Purdie Jan. 24, 2025, 5:39 p.m. UTC
Bitbake is about to change the default value of this from "default" to "". The
original reason for this was to make this kind of include file usage easier.
Instead we were going to complicate bitbake code having to map one value into
the other.

Instead, stop using "default" and put a slightly horrible bit of code in bitbake.conf
as an alternative.

This means a "default.conf" in the multiconfig directory will stop working but this
was never something anyone was expected to use.

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
---
 meta/conf/bitbake.conf | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/meta/conf/bitbake.conf b/meta/conf/bitbake.conf
index 8878a54a5a8..19bd7ecc7bb 100644
--- a/meta/conf/bitbake.conf
+++ b/meta/conf/bitbake.conf
@@ -830,7 +830,7 @@  OE_FRAGMENTS_PREFIX ?= "conf/fragments"
 OE_FRAGMENTS_METADATA_VARS ?= "BB_CONF_FRAGMENT_SUMMARY BB_CONF_FRAGMENT_DESCRIPTION"
 addfragments ${OE_FRAGMENTS_PREFIX} OE_FRAGMENTS OE_FRAGMENTS_METADATA_VARS
 
-require conf/multiconfig/${BB_CURRENT_MC}.conf
+require ${@"conf/multiconfig/${BB_CURRENT_MC}.conf" if "${BB_CURRENT_MC}" != "" else ""}
 include conf/machine/${MACHINE}.conf
 include conf/machine-sdk/${SDKMACHINE}.conf
 require conf/cve-check-map.conf