summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2010-11-21 23:04:43 +1100
committerAndrew Tridgell <tridge@samba.org>2010-11-21 23:10:14 +1100
commitfcdbd0613631b02b991214b2dccbb97eb571ac28 (patch)
treeea175268351a0d1fc9f50b70605f374ee2e21058
parent808edd02936879862df685775a12b1efba5947ea (diff)
downloadsamba-fcdbd0613631b02b991214b2dccbb97eb571ac28.tar.gz
samba-fcdbd0613631b02b991214b2dccbb97eb571ac28.tar.bz2
samba-fcdbd0613631b02b991214b2dccbb97eb571ac28.zip
waf: fixed the build with a space in the source directory
-rwxr-xr-xbuildtools/scripts/abi_gen.sh4
-rw-r--r--buildtools/wafsamba/samba_autoconf.py5
-rw-r--r--buildtools/wafsamba/samba_autoproto.py2
-rw-r--r--buildtools/wafsamba/samba_pidl.py2
-rw-r--r--buildtools/wafsamba/wafsamba.py2
5 files changed, 8 insertions, 7 deletions
diff --git a/buildtools/scripts/abi_gen.sh b/buildtools/scripts/abi_gen.sh
index 7b4cb12713..d563fb8533 100755
--- a/buildtools/scripts/abi_gen.sh
+++ b/buildtools/scripts/abi_gen.sh
@@ -10,11 +10,11 @@ cat <<EOF
set height 0
set width 0
EOF
-nm $SHAREDLIB | cut -d' ' -f2- | egrep '^[BDGTRVWS]' | grep -v @ | cut -c3- | sort | while read s; do
+nm "$SHAREDLIB" | cut -d' ' -f2- | egrep '^[BDGTRVWS]' | grep -v @ | cut -c3- | sort | while read s; do
echo "echo $s: "
echo p $s
done
) > $GDBSCRIPT
-gdb -batch -x $GDBSCRIPT $SHAREDLIB < /dev/null
+gdb -batch -x $GDBSCRIPT "$SHAREDLIB" < /dev/null
rm -f $GDBSCRIPT
diff --git a/buildtools/wafsamba/samba_autoconf.py b/buildtools/wafsamba/samba_autoconf.py
index e84a456287..03031a7c78 100644
--- a/buildtools/wafsamba/samba_autoconf.py
+++ b/buildtools/wafsamba/samba_autoconf.py
@@ -356,8 +356,10 @@ def CHECK_CODE(conf, code, define,
if msg is None:
msg="Checking for %s" % define
+ cflags = TO_LIST(cflags)
+
if local_include:
- cflags += ' -I%s' % conf.curdir
+ cflags.append('-I%s' % conf.curdir)
if not link:
type='nolink'
@@ -368,7 +370,6 @@ def CHECK_CODE(conf, code, define,
(ccflags, ldflags) = library_flags(conf, uselib)
- cflags = TO_LIST(cflags)
cflags.extend(ccflags)
if on_target:
diff --git a/buildtools/wafsamba/samba_autoproto.py b/buildtools/wafsamba/samba_autoproto.py
index bb6400cf05..2d8ea546ab 100644
--- a/buildtools/wafsamba/samba_autoproto.py
+++ b/buildtools/wafsamba/samba_autoproto.py
@@ -16,7 +16,7 @@ def SAMBA_AUTOPROTO(bld, header, source):
on_results=True,
ext_out='.c',
before ='cc',
- rule = '${PERL} ${SCRIPT}/mkproto.pl --srcdir=.. --builddir=. --public=/dev/null --private=${TGT} ${SRC}'
+ rule = '${PERL} "${SCRIPT}/mkproto.pl" --srcdir=.. --builddir=. --public=/dev/null --private="${TGT}" ${SRC}'
)
t.env.SCRIPT = os.path.join(bld.srcnode.abspath(), 'source4/script')
Build.BuildContext.SAMBA_AUTOPROTO = SAMBA_AUTOPROTO
diff --git a/buildtools/wafsamba/samba_pidl.py b/buildtools/wafsamba/samba_pidl.py
index 521222dc5c..902d4c6e01 100644
--- a/buildtools/wafsamba/samba_pidl.py
+++ b/buildtools/wafsamba/samba_pidl.py
@@ -58,7 +58,7 @@ def SAMBA_PIDL(bld, pname, source,
pidl_src_nodes = bld.pidl_files_cache
# the cd .. is needed because pidl currently is sensitive to the directory it is run in
- t = bld(rule='cd .. && ${PERL} ${PIDL} --quiet ${OPTIONS} --outputdir ${OUTPUTDIR} -- ${SRC[0].abspath(env)}',
+ t = bld(rule='cd .. && ${PERL} "${PIDL}" --quiet ${OPTIONS} --outputdir ${OUTPUTDIR} -- "${SRC[0].abspath(env)}"',
ext_out = '.c',
before = 'cc',
on_results = True,
diff --git a/buildtools/wafsamba/wafsamba.py b/buildtools/wafsamba/wafsamba.py
index dc25145de7..5d13fa1023 100644
--- a/buildtools/wafsamba/wafsamba.py
+++ b/buildtools/wafsamba/wafsamba.py
@@ -566,7 +566,7 @@ def ENABLE_TIMESTAMP_DEPENDENCIES(conf):
-t = Task.simple_task_type('copy_script', 'rm -f ${LINK_TARGET} && ln -s ${SRC[0].abspath(env)} ${LINK_TARGET}',
+t = Task.simple_task_type('copy_script', 'rm -f "${LINK_TARGET}" && ln -s "${SRC[0].abspath(env)}" ${LINK_TARGET}',
shell=True, color='PINK', ext_in='.bin')
t.quiet = True