aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChris Laplante <chris.laplante@agilent.com>2021-06-02 12:20:38 -0400
committerRichard Purdie <richard.purdie@linuxfoundation.org>2021-06-06 23:17:30 +0100
commit1e7655c4f765ba7b4791c4cca048a69bf8d9c93d (patch)
tree5b2861ddd3c2b865fe7fec9a1fef194fb23e0295
parentc2c0f5126c7c784bfd7a08f127e161a58c6b5d12 (diff)
downloadbitbake-1e7655c4f765ba7b4791c4cca048a69bf8d9c93d.tar.gz
build: warn on setting noexec/nostamp/fakeroot flag to any value besides '1'
Currently setting those flags to even the empty string "" causes it to be set, which is contrary to the documentation. In a future version of BitBake, we'd like to change the behavior so that setting the flag to "" does not set it. This will allow conditionally setting noexec, using variable expansion or inline Python. I found no places in poky or meta-openembedded where this warning would trigger. [YOCTO #13808] Signed-off-by: Chris Laplante <chris.laplante@agilent.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--lib/bb/build.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/bb/build.py b/lib/bb/build.py
index b2715fc53..6ce8f1e6d 100644
--- a/lib/bb/build.py
+++ b/lib/bb/build.py
@@ -927,6 +927,11 @@ def add_tasks(tasklist, d):
task_deps[name] = {}
if name in flags:
deptask = d.expand(flags[name])
+ if name in ['noexec', 'fakeroot', 'nostamp']:
+ if deptask != '1':
+ bb.warn("In a future version of BitBake, setting the '{}' flag to something other than '1' "
+ "will result in the flag not being set. See YP bug #13808.".format(name))
+
task_deps[name][task] = deptask
getTask('mcdepends')
getTask('depends')