summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRoss Burton <ross.burton@arm.com>2025-10-29 13:03:10 +0000
committerPaul Barker <paul@pbarker.dev>2026-06-10 14:35:20 +0100
commit48c16cfa282b64a49287c51ace206c436801e70e (patch)
treeea089552fb09c17f225dd649ecbbf7c0e9b1db1e
parent7133ff1bff5e9a7d2d5a1c48d0b1f4e119feb031 (diff)
downloadpoky-48c16cfa282b64a49287c51ace206c436801e70e.tar.gz
classes/base: prefer gnu-prefixed HOSTTOOLS
Ubuntu 25.10 has changed the default coreutils implementation from GNU coreutils to uutils/coreutils. Unfortunately this causes build problems: couldn't allocate absolute path for 'null'. tail: cannot open 'standard input' for reading: No such file or directory install: failed to chown '...': Invalid argument (os error 22) Clear build failures happen in 'install' and 'tail', but there may be further breakage. Luckily, Ubuntu also installs GNU coreutils with a binary prefix of 'gnu', so whilst these issues are root-caused and fixed in either pseudo or uutils we can prefer the gnu-prefixed binaries where they are present. [ YOCTO #16028 ] (From OE-Core rev: b797cc729f6e6951baa988e1c04bac9fb8183a1c) Signed-off-by: Ross Burton <ross.burton@arm.com> Signed-off-by: Mathieu Dubois-Briand <mathieu.dubois-briand@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit 16f2684ebeffa72b5d90525cf9102751b68c298e) Signed-off-by: Yoann Congal <yoann.congal@smile.fr> Signed-off-by: Paul Barker <paul@pbarker.dev>
-rw-r--r--meta/classes-global/base.bbclass6
1 files changed, 5 insertions, 1 deletions
diff --git a/meta/classes-global/base.bbclass b/meta/classes-global/base.bbclass
index ecf0fd711f..edf2149e6f 100644
--- a/meta/classes-global/base.bbclass
+++ b/meta/classes-global/base.bbclass
@@ -111,7 +111,11 @@ def setup_hosttools_dir(dest, toolsvar, d, fatal=True):
111 # clean up dead symlink 111 # clean up dead symlink
112 if os.path.islink(desttool): 112 if os.path.islink(desttool):
113 os.unlink(desttool) 113 os.unlink(desttool)
114 srctool = bb.utils.which(path, tool, executable=True) 114
115 # Prefer gnu-prefixed binaries, if available
116 srctool = (bb.utils.which(path, "gnu" + tool, executable=True) or
117 bb.utils.which(path, tool, executable=True))
118
115 # gcc/g++ may link to ccache on some hosts, e.g., 119 # gcc/g++ may link to ccache on some hosts, e.g.,
116 # /usr/local/bin/ccache/gcc -> /usr/bin/ccache, then which(gcc) 120 # /usr/local/bin/ccache/gcc -> /usr/bin/ccache, then which(gcc)
117 # would return /usr/local/bin/ccache/gcc, but what we need is 121 # would return /usr/local/bin/ccache/gcc, but what we need is