aboutsummaryrefslogtreecommitdiff
path: root/configure.in
diff options
context:
space:
mode:
authorIan Lance Taylor <ian@airs.com>1995-11-21 19:13:51 +0000
committerIan Lance Taylor <ian@airs.com>1995-11-21 19:13:51 +0000
commit7fc36fdab48317bb4467e5c338c6104f47e52e5c (patch)
treedb06d429dcac18c2df7f2c79acc4da010cf9153d /configure.in
parentfcc14c40532ff527c2cd0720deb128558b73bfa0 (diff)
downloadgdb-7fc36fdab48317bb4467e5c338c6104f47e52e5c.zip
gdb-7fc36fdab48317bb4467e5c338c6104f47e52e5c.tar.gz
gdb-7fc36fdab48317bb4467e5c338c6104f47e52e5c.tar.bz2
* configure.in: Strip --host and --target options from
CONFIG_ARGUMENTS, and always configure for --host only. Add --with-cross-host option when building with a cross-compiler. * configure: Canonicalize the arguments put into config.status by always using `=' for an option with an argument. Pass a presumed --host or --target explicitly.
Diffstat (limited to 'configure.in')
-rw-r--r--configure.in18
1 files changed, 15 insertions, 3 deletions
diff --git a/configure.in b/configure.in
index 10d9214..a50e49c 100644
--- a/configure.in
+++ b/configure.in
@@ -654,9 +654,21 @@ fi
# Record target_configdirs and the configure arguments in Makefile.
target_configdirs=`echo "${target_configdirs}" | sed -e 's/target-//g'`
targargs=`echo "${arguments}" | \
- sed -e 's/--*norecursion//' \
- -e 's/--*cache[a-z-]*=[^ ]*//' \
- -e 's/--*cache[a-z-]*[ ][ ]*[^ ]*//'`
+ sed -e 's/--norecursion//' \
+ -e 's/--cache[a-z-]*=[^ ]*//' \
+ -e 's/--ho[a-z-]*=[^ ]*//' \
+ -e 's/--ta[a-z-]*=[^ ]*//'`
+
+# Passing a --with-cross-host argument lets the target libraries know
+# whether they are being built with a cross-compiler or being built
+# native. However, it would be better to use other mechanisms to make the
+# sorts of decisions they want to make on this basis. Please consider
+# this option to be deprecated. FIXME.
+if [ x${is_cross_compiler} = xyes ]; then
+ targargs="--with-cross-host=${host_alias} $[targargs}"
+fi
+
+targargs="--host=${target_alias} ${targargs}"
sed -e "s:^TARGET_CONFIGDIRS[ ]*=.*$:TARGET_CONFIGDIRS = ${target_configdirs}:" \
-e "s%^CONFIG_ARGUMENTS[ ]*=.*$%CONFIG_ARGUMENTS = ${targargs}%" \
-e "s%^TARGET_SUBDIR[ ]*=.*$%TARGET_SUBDIR = ${target_subdir}%" \