summaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorYoann Congal <yoann.congal@smile.fr>2025-09-26 16:53:05 +0200
committerRichard Purdie <richard.purdie@linuxfoundation.org>2025-10-01 10:52:54 +0100
commita9266fa9054753fc9d1f39f9f67d846bb298536b (patch)
treee5663663200e06f9dd69b514955aeb7dd989c115 /scripts
parenta41aed6295592e6afadc6ad461aaf309e41e6d66 (diff)
downloadpoky-a9266fa9054753fc9d1f39f9f67d846bb298536b.tar.gz
oe-setup-build: fix dash support
Being minimalist, dash does not support the (non-POSIX) feature of passing an argument while sourcing a script. Like in . <some path>/oe-init-build-env <build dir> With dash, one must instead use: cd <some path> set <build dir> # puts <build dir> in $1 . ./oe-init-build-env # can only be called from its directory in dash oe-setup-build generate a sourcable "init-build-env" script, this script must use the above snippet to be used in dash. (From OE-Core rev: 35c90011824845b40066b7747b256f1cd31b0dba) Signed-off-by: Yoann Congal <yoann.congal@smile.fr> Signed-off-by: Mathieu Dubois-Briand <mathieu.dubois-briand@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/oe-setup-build2
1 files changed, 1 insertions, 1 deletions
diff --git a/scripts/oe-setup-build b/scripts/oe-setup-build
index 49603d9fd1..edbcd48355 100755
--- a/scripts/oe-setup-build
+++ b/scripts/oe-setup-build
@@ -89,7 +89,7 @@ def setup_build_env(args):
89 builddir = args.b if args.b else template["buildpath"] 89 builddir = args.b if args.b else template["buildpath"]
90 no_shell = args.no_shell 90 no_shell = args.no_shell
91 coredir = os.path.abspath(os.path.join(os.path.dirname(os.path.realpath(__file__)), '..')) 91 coredir = os.path.abspath(os.path.join(os.path.dirname(os.path.realpath(__file__)), '..'))
92 cmd_base = ". {} {}".format(os.path.join(coredir, 'oe-init-build-env'), os.path.abspath(builddir)) 92 cmd_base = "cd {}\nset {}\n. ./oe-init-build-env\n".format(coredir, os.path.abspath(builddir))
93 93
94 initbuild = os.path.join(builddir, 'init-build-env') 94 initbuild = os.path.join(builddir, 'init-build-env')
95 if not os.path.exists(initbuild): 95 if not os.path.exists(initbuild):