summaryrefslogtreecommitdiff
path: root/libiberty
diff options
context:
space:
mode:
authorGeoffrey Keating <geoffk@geoffk.org>2007-06-07 18:43:51 +0000
committerGeoffrey Keating <geoffk@geoffk.org>2007-06-07 18:43:51 +0000
commit9a805c2788455545187ceb9661eff41760ec2040 (patch)
treee4eb5e28a923b47d4aeea3e98d250cfd0a2ae230 /libiberty
parent91207634aea8e38349b0c5310dba77a3b2af411c (diff)
downloadbinutils-redhat-9a805c2788455545187ceb9661eff41760ec2040.tar.gz
* configure.ac: Non-default multilibs can be cross compilations.
* configure: Regenerate
Diffstat (limited to 'libiberty')
-rw-r--r--libiberty/ChangeLog5
-rwxr-xr-xlibiberty/configure24
-rw-r--r--libiberty/configure.ac19
3 files changed, 48 insertions, 0 deletions
diff --git a/libiberty/ChangeLog b/libiberty/ChangeLog
index a4217845c7..233b175d5c 100644
--- a/libiberty/ChangeLog
+++ b/libiberty/ChangeLog
@@ -1,3 +1,8 @@
+2007-06-07 Geoffrey Keating <geoffk@apple.com>
+
+ * configure.ac: Non-default multilibs can be cross compilations.
+ * configure: Regenerate
+
2007-05-07 Nathan Froyd <froydnj@codesourcery.com>
* argv.c (writeargv): New function.
diff --git a/libiberty/configure b/libiberty/configure
index 56d039ea0c..c745d8ba34 100755
--- a/libiberty/configure
+++ b/libiberty/configure
@@ -847,6 +847,7 @@ Optional Features:
--enable-maintainer-mode
enable make rules and dependencies not useful
(and sometimes confusing) to the casual installer
+ --enable-multilib build many library versions (default)
--enable-install-libiberty Install headers for end users
Optional Packages:
@@ -1727,6 +1728,29 @@ else
fi
+# Add --enable-multilib to configure.
+# Default to --enable-multilib
+# Check whether --enable-multilib or --disable-multilib was given.
+if test "${enable_multilib+set}" = set; then
+ enableval="$enable_multilib"
+ case "$enableval" in
+ yes) multilib=yes ;;
+ no) multilib=no ;;
+ *) { { echo "$as_me:$LINENO: error: bad value $enableval for multilib option" >&5
+echo "$as_me: error: bad value $enableval for multilib option" >&2;}
+ { (exit 1); exit 1; }; } ;;
+ esac
+else
+ multilib=yes
+fi;
+
+# Even if the default multilib is not a cross compilation,
+# it may be that some of the other multilibs are.
+if test $cross_compiling = no && test $multilib = yes \
+ && test "x${with_multisubdir}" != x ; then
+ cross_compiling=maybe
+fi
+
ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
diff --git a/libiberty/configure.ac b/libiberty/configure.ac
index fe4633f869..cdc3cd38f6 100644
--- a/libiberty/configure.ac
+++ b/libiberty/configure.ac
@@ -109,6 +109,25 @@ dnl to call AC_CHECK_PROG.
AC_CHECK_TOOL(AR, ar)
AC_CHECK_TOOL(RANLIB, ranlib, :)
+dnl When switching to automake, replace the following with AM_ENABLE_MULTILIB.
+# Add --enable-multilib to configure.
+# Default to --enable-multilib
+AC_ARG_ENABLE(multilib,
+[ --enable-multilib build many library versions (default)],
+[case "$enableval" in
+ yes) multilib=yes ;;
+ no) multilib=no ;;
+ *) AC_MSG_ERROR([bad value $enableval for multilib option]) ;;
+ esac],
+ [multilib=yes])
+
+# Even if the default multilib is not a cross compilation,
+# it may be that some of the other multilibs are.
+if test $cross_compiling = no && test $multilib = yes \
+ && test "x${with_multisubdir}" != x ; then
+ cross_compiling=maybe
+fi
+
GCC_NO_EXECUTABLES
AC_PROG_CC
AC_PROG_CPP_WERROR