summaryrefslogtreecommitdiffstats
path: root/meta
diff options
context:
space:
mode:
authorRobert Yang <liezhi.yang@windriver.com>2018-12-12 14:59:59 +0800
committerRichard Purdie <richard.purdie@linuxfoundation.org>2018-12-15 17:10:52 +0000
commit2e8f8d7eb330570a01c77e90540eb5e886243dbc (patch)
treec6e68c9fa63c311d387dbaf696f4af530846efa5 /meta
parenta669023fe50113bf1b650916a91a9be0562c6c9e (diff)
downloadpoky-2e8f8d7eb330570a01c77e90540eb5e886243dbc.tar.gz
base.bbclass: Add comments for gcc links to ccache
(From OE-Core rev: ce6bf125aba7344d56368885605949e373b06393) Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta')
-rw-r--r--meta/classes/base.bbclass4
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: