summaryrefslogtreecommitdiff
path: root/configure.in
diff options
context:
space:
mode:
authorRoland McGrath <roland@gnu.org>2005-11-08 01:21:32 +0000
committerRoland McGrath <roland@gnu.org>2005-11-08 01:21:32 +0000
commit2ceaa76abd0414f8d935bdf3b7a6218dc20f2f4e (patch)
treeb901e42e4e4d03fdfbb80b72f6fc9ca323e28441 /configure.in
parent2182b1ea1796c09a90a996f01bbc48760a177b72 (diff)
downloadglibc-2ceaa76abd0414f8d935bdf3b7a6218dc20f2f4e.tar.gz
* configure.in: Grok --with-cpu=CPU option. If given, search for
sysdeps/.../machine/CPU subdirs, and give error if none are found. * configure: Regenerated. * config.make.in (with-cpu): New substituted variable. * Makeconfig (+cflags): Add -mcpu=$(with-cpu) if set.
Diffstat (limited to 'configure.in')
-rw-r--r--configure.in17
1 files changed, 16 insertions, 1 deletions
diff --git a/configure.in b/configure.in
index f283c3f7fe..ba7ca30b2f 100644
--- a/configure.in
+++ b/configure.in
@@ -332,6 +332,17 @@ case "$machine-$host_os" in
;;
esac
+submachine=
+AC_ARG_WITH([cpu],
+ AS_HELP_STRING([--with-cpu=CPU], [select code for CPU variant]),
+ [dnl
+ case "$withval" in
+ yes|'') AC_MSG_ERROR([--with-cpu requires an argument]) ;;
+ no) ;;
+ *) submachine="$withval" ;;
+ esac
+])
+
# An add-on can set this when it the tuple to disable the sanity check below.
libc_config_ok=no
@@ -551,7 +562,7 @@ done
# For sparc/sparc32, try sparc/sparc32 and then sparc.
mach=
-tail=$machine
+tail=$machine${submachine:+/$submachine}
while m=`echo $tail | sed 's@^\(.*\)/\([^/]*\)$@& \1@'`; test -n "$m"; do
set $m
# Prepend the machine's FPU directory unless --without-fp.
@@ -619,6 +630,10 @@ fi
if test -z "$machine_used" && test "$machine" != none; then
AC_MSG_ERROR(The $machine is not supported.)
fi
+if test -z "$submachine_used" && test -n "$submachine"; then
+ AC_MSG_ERROR(The $submachine subspecies of $host_cpu is not supported.)
+fi
+AC_SUBST(submachine)
# We have now validated the configuration.