summaryrefslogtreecommitdiffstats
path: root/configure.in
diff options
context:
space:
mode:
authorAlexandre Oliva <aoliva@redhat.com>2001-04-02 01:32:45 +0000
committerAlexandre Oliva <aoliva@redhat.com>2001-04-02 01:32:45 +0000
commit68b3c65aa1b7d3d4b1fcd953f9de3f2ce518cd09 (patch)
tree5664e4e0ff1d6936c57c7146960e4579cc386e26 /configure.in
parent1ba3935dfb61f418d81305d677475dbadfbdde3f (diff)
downloadcygnal-68b3c65aa1b7d3d4b1fcd953f9de3f2ce518cd09.tar.gz
cygnal-68b3c65aa1b7d3d4b1fcd953f9de3f2ce518cd09.tar.bz2
cygnal-68b3c65aa1b7d3d4b1fcd953f9de3f2ce518cd09.zip
* Makefile.in (CXX_FOR_TARGET_FOR_RECURSIVE_MAKE, RECURSE_FLAGS):
New macros. (bootstrap, cross): Use RECURSE_FLAGS. * configure.in: Subst CXX_FOR_TARGET_FOR_RECURSIVE_MAKE.
Diffstat (limited to 'configure.in')
-rw-r--r--configure.in11
1 files changed, 10 insertions, 1 deletions
diff --git a/configure.in b/configure.in
index 535747002..cc8f34f87 100644
--- a/configure.in
+++ b/configure.in
@@ -1384,7 +1384,15 @@ case $CXX_FOR_TARGET in
*' $(FLAGS_FOR_TARGET)') ;;
*) CXX_FOR_TARGET=$CXX_FOR_TARGET' $(FLAGS_FOR_TARGET)' ;;
esac
-qCXX_FOR_TARGET=`echo "$CXX_FOR_TARGET" | sed 's,&,\\\&,g'`
+qCXX_FOR_TARGET=`echo "$CXX_FOR_TARGET" | sed 's,[&%],\\\&,g'`
+
+# We want to defer the evaluation of `cmd`s and shell variables in
+# CXX_FOR_TARGET when recursing in the top-level Makefile, such as for
+# bootstrap. We'll enclose CXX_FOR_TARGET_FOR_RECURSIVE_MAKE in single
+# quotes, but we still have to duplicate `$'s so that shell variables
+# can be expanded by the nested make as shell variables, not as make
+# macros.
+qqCXX_FOR_TARGET=`echo "$qCXX_FOR_TARGET" | sed -e 's,[$][$],$$$$,g'`
targargs="--cache-file=../config.cache --host=${target_alias} --build=${build_alias} ${targargs}"
sed -e "s:^TARGET_CONFIGDIRS[ ]*=.*$:TARGET_CONFIGDIRS = ${target_configdirs}:" \
@@ -1393,6 +1401,7 @@ sed -e "s:^TARGET_CONFIGDIRS[ ]*=.*$:TARGET_CONFIGDIRS = ${target_configdirs}:"
-e "s%^CC_FOR_TARGET[ ]*=.*$%CC_FOR_TARGET = ${CC_FOR_TARGET}%" \
-e "s%^CHILL_FOR_TARGET[ ]*=.*$%CHILL_FOR_TARGET = ${CHILL_FOR_TARGET}%" \
-e "s%^CXX_FOR_TARGET[ ]*=.*$%CXX_FOR_TARGET = ${qCXX_FOR_TARGET}%" \
+ -e "s%^CXX_FOR_TARGET_FOR_RECURSIVE_MAKE[ ]*=.*$%CXX_FOR_TARGET_FOR_RECURSIVE_MAKE = ${qqCXX_FOR_TARGET}%" \
-e "s%^TARGET_SUBDIR[ ]*=.*$%TARGET_SUBDIR = ${target_subdir}%" \
-e "s%^gxx_include_dir[ ]*=.*$%gxx_include_dir=${gxx_include_dir}%" \
Makefile > Makefile.tem