diff options
Diffstat (limited to 'meta/classes')
-rw-r--r-- | meta/classes/base.bbclass | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/meta/classes/base.bbclass b/meta/classes/base.bbclass index e715ffa1b2..e6af673847 100644 --- a/meta/classes/base.bbclass +++ b/meta/classes/base.bbclass | |||
@@ -122,6 +122,10 @@ def setup_hosttools_dir(dest, toolsvar, d, fatal=True): | |||
122 | desttool = os.path.join(dest, tool) | 122 | desttool = os.path.join(dest, tool) |
123 | if not os.path.exists(desttool): | 123 | if not os.path.exists(desttool): |
124 | srctool = bb.utils.which(path, tool, executable=True) | 124 | srctool = bb.utils.which(path, tool, executable=True) |
125 | # gcc/g++ may link to ccache on some hosts, e.g., | ||
126 | # /usr/local/bin/ccache/gcc -> /usr/bin/ccache, then which(gcc) | ||
127 | # would return /usr/local/bin/ccache/gcc, but what we need is | ||
128 | # /usr/bin/gcc, this code can check and fix that. | ||
125 | if "ccache" in srctool: | 129 | if "ccache" in srctool: |
126 | srctool = bb.utils.which(path, tool, executable=True, direction=1) | 130 | srctool = bb.utils.which(path, tool, executable=True, direction=1) |
127 | if srctool: | 131 | if srctool: |