diff mbox series

bitbake.conf: Set PACKAGECONFIG vardepvalue

Message ID 20260311134208.3459009-1-richard.purdie@linuxfoundation.org
State Accepted, archived
Commit 7e75ec7a66c8c5f06c264784b0b6daaca37a9381
Headers show
Series bitbake.conf: Set PACKAGECONFIG vardepvalue | expand

Commit Message

Richard Purdie March 11, 2026, 1:42 p.m. UTC
For PACKAGECONFIG settings in recipes, we care about the end value, we don't
really care how it is constructed. bbappends to recipes can add things to
the default PACKAGECONFIG settings, for example being dependent on a DISTRO_FEATURE
or other variable. If the computed value doesn't change, the task hashes can remain
constant, allowing for better sstate reuse.

To do this, set a vardepvalue of the variable value itself, ignoring how
the actual value is calculated.

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

Patch

diff --git a/meta/conf/bitbake.conf b/meta/conf/bitbake.conf
index f21e8f8918b..5f632d9f8e7 100644
--- a/meta/conf/bitbake.conf
+++ b/meta/conf/bitbake.conf
@@ -931,6 +931,10 @@  SHELL[unexport] = "1"
 # Used by canadian-cross to handle string conversions on TARGET_ARCH where needed
 TRANSLATED_TARGET_ARCH ??= "${@d.getVar('TARGET_ARCH').replace("_", "-")}"
 
+# We only care about the computed configuration, not how it is constructed which may
+# vary with bbappends
+PACKAGECONFIG[vardepvalue] = "${PACKAGECONFIG}"
+
 # Set a default umask to use for tasks for determinism
 BB_DEFAULT_UMASK ??= "022"
 # The umask to use for shared files (e.g. DL_DIR and SSTATE_DIR)