From 3e664599fd54a8a37ce587022fcbce5ca26f2ed3 Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Sun, 14 Feb 2021 11:35:21 +0000 Subject: bitbake-worker/runqueue: Add support for BB_DEFAULT_UMASK Currently each task has to have a umask specified individually. This is leading to determinism issues since it is easy to miss specifying this for an extra task. Add support for specifing the default task umask globally which simplifies the problem. Signed-off-by: Richard Purdie --- bin/bitbake-worker | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'bin') diff --git a/bin/bitbake-worker b/bin/bitbake-worker index 6c3796751..7765b9368 100755 --- a/bin/bitbake-worker +++ b/bin/bitbake-worker @@ -150,11 +150,15 @@ def fork_off_task(cfg, data, databuilder, workerdata, fn, task, taskname, taskha taskdep = workerdata["taskdeps"][fn] if 'umask' in taskdep and taskname in taskdep['umask']: + umask = taskdep['umask'][taskname] + elif workerdata["umask"]: + umask = workerdata["umask"] + if umask: # umask might come in as a number or text string.. try: - umask = int(taskdep['umask'][taskname],8) + umask = int(umask, 8) except TypeError: - umask = taskdep['umask'][taskname] + pass dry_run = cfg.dry_run or dry_run_exec -- cgit 1.2.3-korg