From 791bf5a43dabd8232e4f2e8ef9ded13a7d959400 Mon Sep 17 00:00:00 2001 From: Peter Kjellerstedt Date: Tue, 16 Sep 2025 23:19:33 +0200 Subject: bitbake: parse: Make include_all support empty variable expansions include and require support empty variable expansions, typically used with conditional expansions. However, include_all does not, and instead reports an error for the first path in BBPATH. Rewrite include_all so that its behavior matches include and require. (Bitbake rev: 010928ceac48b20e6ab530f8e256b72201b778ec) Signed-off-by: Peter Kjellerstedt Signed-off-by: Richard Purdie --- bitbake/lib/bb/parse/parse_py/ConfHandler.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'bitbake/lib/bb/parse/parse_py/ConfHandler.py') diff --git a/bitbake/lib/bb/parse/parse_py/ConfHandler.py b/bitbake/lib/bb/parse/parse_py/ConfHandler.py index 9ddbae123d..af3af2ccee 100644 --- a/bitbake/lib/bb/parse/parse_py/ConfHandler.py +++ b/bitbake/lib/bb/parse/parse_py/ConfHandler.py @@ -56,7 +56,7 @@ def init(data): def supports(fn, d): return fn[-5:] == ".conf" -def include(parentfn, fns, lineno, data, error_out): +def include(parentfn, fns, lineno, data, error_out, all=False): """ error_out: A string indicating the verb (e.g. "include", "inherit") to be used in a ParseError that will be raised if the file to be included could @@ -67,7 +67,11 @@ def include(parentfn, fns, lineno, data, error_out): # "include" or "require" accept zero to n space-separated file names to include. for fn in fns.split(): - include_single_file(parentfn, fn, lineno, data, error_out) + if all: + for path in data.getVar("BBPATH").split(":"): + include_single_file(parentfn, os.path.join(path, fn), lineno, data, error_out) + else: + include_single_file(parentfn, fn, lineno, data, error_out) def include_single_file(parentfn, fn, lineno, data, error_out): """ -- cgit v1.2.3-54-g00ecf