summaryrefslogtreecommitdiff
path: root/buildtools/wafsamba/samba_autoconf.py
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2010-03-21 09:50:14 -0400
committerAndrew Tridgell <tridge@samba.org>2010-04-06 20:26:58 +1000
commitb282660d3981540c8c9b588c25fcd8537a567988 (patch)
treea0494d42c5125490be7757685ffe1f808aa308ca /buildtools/wafsamba/samba_autoconf.py
parentdc9010572c1d32a4e1c82afbee2a359c429cc9aa (diff)
downloadsamba-b282660d3981540c8c9b588c25fcd8537a567988.tar.gz
samba-b282660d3981540c8c9b588c25fcd8537a567988.tar.bz2
samba-b282660d3981540c8c9b588c25fcd8537a567988.zip
build: fixed issue with CC="ccache cc" on solaris
Diffstat (limited to 'buildtools/wafsamba/samba_autoconf.py')
-rw-r--r--buildtools/wafsamba/samba_autoconf.py10
1 files changed, 10 insertions, 0 deletions
diff --git a/buildtools/wafsamba/samba_autoconf.py b/buildtools/wafsamba/samba_autoconf.py
index e91409e0a4..1c1095ea47 100644
--- a/buildtools/wafsamba/samba_autoconf.py
+++ b/buildtools/wafsamba/samba_autoconf.py
@@ -418,3 +418,13 @@ def CHECK_RPATH_SUPPORT(conf):
execute=True,
msg='Checking for rpath support',
cflags='-Wl,-rpath=.')
+
+@conf
+def CHECK_CC_ENV(conf):
+ '''trim whitespaces from 'CC'.
+ The build farm sometimes puts a space at the start'''
+ if os.environ.get('CC'):
+ conf.env.CC = TO_LIST(os.environ.get('CC'))
+ if len(conf.env.CC) == 1:
+ # make for nicer logs if just a single command
+ conf.env.CC = conf.env.CC[0]