From: Ross Burton Date: Thu, 30 Mar 2017 13:34:10 +0000 (+0100) Subject: base.bbclass: ensure HOSTTOOLS links point to executables X-Git-Tag: yocto-2.3~291 X-Git-Url: https://code.ossystems.io/gitweb?a=commitdiff_plain;h=7f40c934c3aeb1d34f95f30b281e25a17c428fce;p=openembedded-core.git base.bbclass: ensure HOSTTOOLS links point to executables Use the new executable argument to bb.utils.which() to ensure that the symlinks point to executable files and not for example directories with the right name which happened to be on $PATH. [ YOCTO #11256 ] Signed-off-by: Ross Burton Signed-off-by: Richard Purdie --- diff --git a/meta/classes/base.bbclass b/meta/classes/base.bbclass index cf8748a502..e29821f199 100644 --- a/meta/classes/base.bbclass +++ b/meta/classes/base.bbclass @@ -128,9 +128,9 @@ def setup_hosttools_dir(dest, toolsvar, d, fatal=True): for tool in tools: desttool = os.path.join(dest, tool) if not os.path.exists(desttool): - srctool = bb.utils.which(path, tool) + srctool = bb.utils.which(path, tool, executable=True) if "ccache" in srctool: - srctool = bb.utils.which(path, tool, direction=1) + srctool = bb.utils.which(path, tool, executable=True, direction=1) if srctool: os.symlink(srctool, desttool) else: