]> git.ipfire.org Git - thirdparty/gcc.git/blame - libstdc++-v3/configure
passes.texi: Document predictive commoning.
[thirdparty/gcc.git] / libstdc++-v3 / configure
CommitLineData
b2dad0e3 1#! /bin/sh
b2dad0e3 2# Guess values for system-dependent variables and create Makefiles.
ec2075e9 3# Generated by GNU Autoconf 2.59 for package-unused version-unused.
b2dad0e3 4#
ec2075e9 5# Copyright (C) 2003 Free Software Foundation, Inc.
b2dad0e3
BK
6# This configure script is free software; the Free Software Foundation
7# gives unlimited permission to copy, distribute and modify it.
ff66d28f
PE
8## --------------------- ##
9## M4sh Initialization. ##
10## --------------------- ##
11
12# Be Bourne compatible
13if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
14 emulate sh
15 NULLCMD=:
16 # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
17 # is contrary to our usage. Disable this feature.
18 alias -g '${1+"$@"}'='"$@"'
19elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
20 set -o posix
21fi
ec2075e9 22DUALCASE=1; export DUALCASE # for MKS sh
ff66d28f
PE
23
24# Support unset when possible.
ec2075e9 25if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
ff66d28f
PE
26 as_unset=unset
27else
28 as_unset=false
29fi
30
31
32# Work around bugs in pre-3.0 UWIN ksh.
33$as_unset ENV MAIL MAILPATH
34PS1='$ '
35PS2='> '
36PS4='+ '
37
38# NLS nuisances.
39for as_var in \
40 LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
41 LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
42 LC_TELEPHONE LC_TIME
43do
ec2075e9 44 if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
ff66d28f
PE
45 eval $as_var=C; export $as_var
46 else
47 $as_unset $as_var
48 fi
49done
50
51# Required to use basename.
52if expr a : '\(a\)' >/dev/null 2>&1; then
53 as_expr=expr
54else
55 as_expr=false
56fi
57
58if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
59 as_basename=basename
60else
61 as_basename=false
62fi
63
64
65# Name of the executable.
66as_me=`$as_basename "$0" ||
67$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
68 X"$0" : 'X\(//\)$' \| \
69 X"$0" : 'X\(/\)$' \| \
70 . : '\(.\)' 2>/dev/null ||
71echo X/"$0" |
72 sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
73 /^X\/\(\/\/\)$/{ s//\1/; q; }
74 /^X\/\(\/\).*/{ s//\1/; q; }
75 s/.*/./; q'`
76
77
78# PATH needs CR, and LINENO needs CR and PATH.
79# Avoid depending upon Character Ranges.
80as_cr_letters='abcdefghijklmnopqrstuvwxyz'
81as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
82as_cr_Letters=$as_cr_letters$as_cr_LETTERS
83as_cr_digits='0123456789'
84as_cr_alnum=$as_cr_Letters$as_cr_digits
85
86# The user is always right.
87if test "${PATH_SEPARATOR+set}" != set; then
88 echo "#! /bin/sh" >conf$$.sh
89 echo "exit 0" >>conf$$.sh
90 chmod +x conf$$.sh
91 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
92 PATH_SEPARATOR=';'
93 else
94 PATH_SEPARATOR=:
95 fi
96 rm -f conf$$.sh
97fi
98
99
100 as_lineno_1=$LINENO
101 as_lineno_2=$LINENO
102 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
103 test "x$as_lineno_1" != "x$as_lineno_2" &&
104 test "x$as_lineno_3" = "x$as_lineno_2" || {
105 # Find who we are. Look in the path if we contain no path at all
106 # relative or not.
107 case $0 in
108 *[\\/]* ) as_myself=$0 ;;
109 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
110for as_dir in $PATH
111do
112 IFS=$as_save_IFS
113 test -z "$as_dir" && as_dir=.
114 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
115done
b2dad0e3 116
ff66d28f
PE
117 ;;
118 esac
119 # We did not find ourselves, most probably we were run as `sh COMMAND'
120 # in which case we are not to be found in the path.
121 if test "x$as_myself" = x; then
122 as_myself=$0
123 fi
124 if test ! -f "$as_myself"; then
125 { echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2
126 { (exit 1); exit 1; }; }
127 fi
128 case $CONFIG_SHELL in
129 '')
130 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
131for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
132do
133 IFS=$as_save_IFS
134 test -z "$as_dir" && as_dir=.
135 for as_base in sh bash ksh sh5; do
136 case $as_dir in
137 /*)
138 if ("$as_dir/$as_base" -c '
139 as_lineno_1=$LINENO
140 as_lineno_2=$LINENO
141 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
142 test "x$as_lineno_1" != "x$as_lineno_2" &&
143 test "x$as_lineno_3" = "x$as_lineno_2" ') 2>/dev/null; then
144 $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
145 $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
146 CONFIG_SHELL=$as_dir/$as_base
147 export CONFIG_SHELL
148 exec "$CONFIG_SHELL" "$0" ${1+"$@"}
149 fi;;
150 esac
151 done
152done
153;;
154 esac
155
156 # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
157 # uniformly replaced by the line number. The first 'sed' inserts a
158 # line-number line before each line; the second 'sed' does the real
159 # work. The second script uses 'N' to pair each line-number line
160 # with the numbered line, and appends trailing '-' during
161 # substitution so that $LINENO is not a special case at line end.
162 # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
163 # second 'sed' script. Blame Lee E. McMahon for sed's syntax. :-)
164 sed '=' <$as_myself |
165 sed '
166 N
167 s,$,-,
168 : loop
169 s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
170 t loop
171 s,-$,,
172 s,^['$as_cr_digits']*\n,,
173 ' >$as_me.lineno &&
174 chmod +x $as_me.lineno ||
175 { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
176 { (exit 1); exit 1; }; }
177
178 # Don't try to exec as it changes $[0], causing all sort of problems
179 # (the dirname of $[0] is not the place where we might find the
180 # original and so on. Autoconf is especially sensible to this).
181 . ./$as_me.lineno
182 # Exit status is that of the last command.
183 exit
184}
185
186
187case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
188 *c*,-n*) ECHO_N= ECHO_C='
189' ECHO_T=' ' ;;
190 *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
191 *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
192esac
193
194if expr a : '\(a\)' >/dev/null 2>&1; then
195 as_expr=expr
196else
197 as_expr=false
198fi
199
200rm -f conf$$ conf$$.exe conf$$.file
201echo >conf$$.file
202if ln -s conf$$.file conf$$ 2>/dev/null; then
203 # We could just check for DJGPP; but this test a) works b) is more generic
204 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
205 if test -f conf$$.exe; then
206 # Don't use ln at all; we don't have any links
207 as_ln_s='cp -p'
208 else
209 as_ln_s='ln -s'
210 fi
211elif ln conf$$.file conf$$ 2>/dev/null; then
212 as_ln_s=ln
213else
214 as_ln_s='cp -p'
215fi
216rm -f conf$$ conf$$.exe conf$$.file
217
218if mkdir -p . 2>/dev/null; then
219 as_mkdir_p=:
220else
ec2075e9 221 test -d ./-p && rmdir ./-p
ff66d28f
PE
222 as_mkdir_p=false
223fi
224
225as_executable_p="test -f"
226
227# Sed expression to map a string onto a valid CPP name.
ec2075e9 228as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
ff66d28f
PE
229
230# Sed expression to map a string onto a valid variable name.
ec2075e9 231as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
ff66d28f
PE
232
233
234# IFS
235# We need space, tab and new line, in precisely that order.
236as_nl='
237'
238IFS=" $as_nl"
239
240# CDPATH.
241$as_unset CDPATH
242
243
244# Name of the host.
245# hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
246# so uname gets run too.
247ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
248
249exec 6>&1
250
251#
252# Initializations.
253#
b2dad0e3 254ac_default_prefix=/usr/local
ff66d28f
PE
255ac_config_libobj_dir=.
256cross_compiling=no
257subdirs=
258MFLAGS=
259MAKEFLAGS=
260SHELL=${CONFIG_SHELL-/bin/sh}
261
262# Maximum number of lines to put in a shell here document.
263# This variable seems obsolete. It should probably be removed, and
264# only ac_max_sed_lines should be used.
265: ${ac_max_here_lines=38}
266
267# Identity of this package.
fbe057bb
PE
268PACKAGE_NAME='package-unused'
269PACKAGE_TARNAME='libstdc++'
ff66d28f 270PACKAGE_VERSION='version-unused'
fbe057bb 271PACKAGE_STRING='package-unused version-unused'
ff66d28f
PE
272PACKAGE_BUGREPORT=''
273
274ac_unique_file="src/ios.cc"
275# Factoring default headers for most tests.
276ac_includes_default="\
277#include <stdio.h>
278#if HAVE_SYS_TYPES_H
279# include <sys/types.h>
280#endif
281#if HAVE_SYS_STAT_H
282# include <sys/stat.h>
283#endif
284#if STDC_HEADERS
285# include <stdlib.h>
286# include <stddef.h>
287#else
288# if HAVE_STDLIB_H
289# include <stdlib.h>
290# endif
291#endif
292#if HAVE_STRING_H
293# if !STDC_HEADERS && HAVE_MEMORY_H
294# include <memory.h>
295# endif
296# include <string.h>
297#endif
298#if HAVE_STRINGS_H
299# include <strings.h>
300#endif
301#if HAVE_INTTYPES_H
302# include <inttypes.h>
303#else
304# if HAVE_STDINT_H
305# include <stdint.h>
306# endif
307#endif
308#if HAVE_UNISTD_H
309# include <unistd.h>
310#endif"
311
af13a7a6 312ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS libtool_VERSION multi_basedir build build_cpu build_vendor build_os host host_cpu host_vendor host_os target target_cpu target_vendor target_os INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA CYGPATH_W PACKAGE VERSION ACLOCAL AUTOCONF AUTOMAKE AUTOHEADER MAKEINFO install_sh STRIP ac_ct_STRIP INSTALL_STRIP_PROGRAM mkdir_p AWK SET_MAKE am__leading_dot AMTAR am__tar am__untar glibcxx_builddir glibcxx_srcdir toplevel_srcdir CC ac_ct_CC EXEEXT OBJEXT CXX ac_ct_CXX CFLAGS CXXFLAGS LN_S AS ac_ct_AS AR ac_ct_AR RANLIB ac_ct_RANLIB MAINTAINER_MODE_TRUE MAINTAINER_MODE_FALSE MAINT CPP CPPFLAGS EGREP LIBTOOL CXXCPP enable_shared enable_static GLIBCXX_HOSTED_TRUE GLIBCXX_HOSTED_FALSE GLIBCXX_BUILD_PCH_TRUE GLIBCXX_BUILD_PCH_FALSE glibcxx_PCHFLAGS CSTDIO_H BASIC_FILE_H BASIC_FILE_CC check_msgfmt glibcxx_MOFILES glibcxx_POFILES glibcxx_localedir USE_NLS CLOCALE_H CMESSAGES_H CCODECVT_CC CCOLLATE_CC CCTYPE_CC CMESSAGES_CC CMONEY_CC CNUMERIC_CC CTIME_H CTIME_CC CLOCALE_CC CLOCALE_INTERNAL_H ALLOCATOR_H ALLOCATOR_NAME C_INCLUDE_DIR GLIBCXX_C_HEADERS_C_TRUE GLIBCXX_C_HEADERS_C_FALSE GLIBCXX_C_HEADERS_C_STD_TRUE GLIBCXX_C_HEADERS_C_STD_FALSE GLIBCXX_C_HEADERS_C_GLOBAL_TRUE GLIBCXX_C_HEADERS_C_GLOBAL_FALSE GLIBCXX_C_HEADERS_COMPATIBILITY_TRUE GLIBCXX_C_HEADERS_COMPATIBILITY_FALSE GLIBCXX_C_HEADERS_EXTRA_TRUE GLIBCXX_C_HEADERS_EXTRA_FALSE DEBUG_FLAGS GLIBCXX_BUILD_DEBUG_TRUE GLIBCXX_BUILD_DEBUG_FALSE EXTRA_CXX_FLAGS glibcxx_thread_h WERROR SECTION_FLAGS SECTION_LDFLAGS OPT_LDFLAGS LIBMATHOBJS LIBICONV LTLIBICONV SYMVER_FILE port_specific_symbol_files ENABLE_SYMVERS_TRUE ENABLE_SYMVERS_FALSE ENABLE_SYMVERS_GNU_TRUE ENABLE_SYMVERS_GNU_FALSE ENABLE_SYMVERS_GNU_NAMESPACE_TRUE ENABLE_SYMVERS_GNU_NAMESPACE_FALSE ENABLE_SYMVERS_DARWIN_TRUE ENABLE_SYMVERS_DARWIN_FALSE ENABLE_VISIBILITY_TRUE ENABLE_VISIBILITY_FALSE GLIBCXX_LDBL_COMPAT_TRUE GLIBCXX_LDBL_COMPAT_FALSE baseline_dir ATOMICITY_SRCDIR ATOMIC_WORD_SRCDIR CPU_DEFINES_SRCDIR ABI_TWEAKS_SRCDIR OS_INC_SRCDIR glibcxx_prefixdir gxx_include_dir glibcxx_toolexecdir glibcxx_toolexeclibdir GLIBCXX_INCLUDES TOPLEVEL_INCLUDES OPTIMIZE_CXXFLAGS WARN_FLAGS LIBSUPCXX_PICFLAGS LIBOBJS LTLIBOBJS'
ff66d28f 313ac_subst_files=''
b2dad0e3
BK
314
315# Initialize some variables set by options.
ff66d28f
PE
316ac_init_help=
317ac_init_version=false
b2dad0e3
BK
318# The variables have the same names as the options, with
319# dashes changed to underlines.
ff66d28f 320cache_file=/dev/null
b2dad0e3 321exec_prefix=NONE
b2dad0e3 322no_create=
b2dad0e3
BK
323no_recursion=
324prefix=NONE
325program_prefix=NONE
326program_suffix=NONE
327program_transform_name=s,x,x,
328silent=
329site=
330srcdir=
b2dad0e3
BK
331verbose=
332x_includes=NONE
333x_libraries=NONE
ff66d28f
PE
334
335# Installation directory options.
336# These are left unexpanded so users can "make install exec_prefix=/foo"
337# and all the variables that are supposed to be based on exec_prefix
338# by default will actually change.
339# Use braces instead of parens because sh, perl, etc. also accept them.
b2dad0e3
BK
340bindir='${exec_prefix}/bin'
341sbindir='${exec_prefix}/sbin'
342libexecdir='${exec_prefix}/libexec'
343datadir='${prefix}/share'
344sysconfdir='${prefix}/etc'
345sharedstatedir='${prefix}/com'
346localstatedir='${prefix}/var'
347libdir='${exec_prefix}/lib'
348includedir='${prefix}/include'
349oldincludedir='/usr/include'
350infodir='${prefix}/info'
351mandir='${prefix}/man'
352
b2dad0e3
BK
353ac_prev=
354for ac_option
355do
b2dad0e3
BK
356 # If the previous option needs an argument, assign it.
357 if test -n "$ac_prev"; then
358 eval "$ac_prev=\$ac_option"
359 ac_prev=
360 continue
361 fi
362
ff66d28f 363 ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
b2dad0e3
BK
364
365 # Accept the important Cygnus configure options, so we can diagnose typos.
366
ff66d28f 367 case $ac_option in
b2dad0e3
BK
368
369 -bindir | --bindir | --bindi | --bind | --bin | --bi)
370 ac_prev=bindir ;;
371 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
ff66d28f 372 bindir=$ac_optarg ;;
b2dad0e3
BK
373
374 -build | --build | --buil | --bui | --bu)
ff66d28f 375 ac_prev=build_alias ;;
b2dad0e3 376 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
ff66d28f 377 build_alias=$ac_optarg ;;
b2dad0e3
BK
378
379 -cache-file | --cache-file | --cache-fil | --cache-fi \
380 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
381 ac_prev=cache_file ;;
382 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
383 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
ff66d28f
PE
384 cache_file=$ac_optarg ;;
385
386 --config-cache | -C)
387 cache_file=config.cache ;;
b2dad0e3
BK
388
389 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
390 ac_prev=datadir ;;
391 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
392 | --da=*)
ff66d28f 393 datadir=$ac_optarg ;;
b2dad0e3
BK
394
395 -disable-* | --disable-*)
ff66d28f 396 ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
b2dad0e3 397 # Reject names that are not valid shell variable names.
ff66d28f
PE
398 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
399 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
400 { (exit 1); exit 1; }; }
401 ac_feature=`echo $ac_feature | sed 's/-/_/g'`
402 eval "enable_$ac_feature=no" ;;
b2dad0e3
BK
403
404 -enable-* | --enable-*)
ff66d28f 405 ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
b2dad0e3 406 # Reject names that are not valid shell variable names.
ff66d28f
PE
407 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
408 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
409 { (exit 1); exit 1; }; }
410 ac_feature=`echo $ac_feature | sed 's/-/_/g'`
411 case $ac_option in
412 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
b2dad0e3
BK
413 *) ac_optarg=yes ;;
414 esac
ff66d28f 415 eval "enable_$ac_feature='$ac_optarg'" ;;
b2dad0e3
BK
416
417 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
418 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
419 | --exec | --exe | --ex)
420 ac_prev=exec_prefix ;;
421 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
422 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
423 | --exec=* | --exe=* | --ex=*)
ff66d28f 424 exec_prefix=$ac_optarg ;;
b2dad0e3
BK
425
426 -gas | --gas | --ga | --g)
427 # Obsolete; use --with-gas.
428 with_gas=yes ;;
429
ff66d28f
PE
430 -help | --help | --hel | --he | -h)
431 ac_init_help=long ;;
432 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
433 ac_init_help=recursive ;;
434 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
435 ac_init_help=short ;;
b2dad0e3
BK
436
437 -host | --host | --hos | --ho)
ff66d28f 438 ac_prev=host_alias ;;
b2dad0e3 439 -host=* | --host=* | --hos=* | --ho=*)
ff66d28f 440 host_alias=$ac_optarg ;;
b2dad0e3
BK
441
442 -includedir | --includedir | --includedi | --included | --include \
443 | --includ | --inclu | --incl | --inc)
444 ac_prev=includedir ;;
445 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
446 | --includ=* | --inclu=* | --incl=* | --inc=*)
ff66d28f 447 includedir=$ac_optarg ;;
b2dad0e3
BK
448
449 -infodir | --infodir | --infodi | --infod | --info | --inf)
450 ac_prev=infodir ;;
451 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
ff66d28f 452 infodir=$ac_optarg ;;
b2dad0e3
BK
453
454 -libdir | --libdir | --libdi | --libd)
455 ac_prev=libdir ;;
456 -libdir=* | --libdir=* | --libdi=* | --libd=*)
ff66d28f 457 libdir=$ac_optarg ;;
b2dad0e3
BK
458
459 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
460 | --libexe | --libex | --libe)
461 ac_prev=libexecdir ;;
462 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
463 | --libexe=* | --libex=* | --libe=*)
ff66d28f 464 libexecdir=$ac_optarg ;;
b2dad0e3
BK
465
466 -localstatedir | --localstatedir | --localstatedi | --localstated \
467 | --localstate | --localstat | --localsta | --localst \
468 | --locals | --local | --loca | --loc | --lo)
469 ac_prev=localstatedir ;;
470 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
471 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
472 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
ff66d28f 473 localstatedir=$ac_optarg ;;
b2dad0e3
BK
474
475 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
476 ac_prev=mandir ;;
477 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
ff66d28f 478 mandir=$ac_optarg ;;
b2dad0e3
BK
479
480 -nfp | --nfp | --nf)
481 # Obsolete; use --without-fp.
482 with_fp=no ;;
483
484 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
ff66d28f 485 | --no-cr | --no-c | -n)
b2dad0e3
BK
486 no_create=yes ;;
487
488 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
489 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
490 no_recursion=yes ;;
491
492 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
493 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
494 | --oldin | --oldi | --old | --ol | --o)
495 ac_prev=oldincludedir ;;
496 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
497 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
498 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
ff66d28f 499 oldincludedir=$ac_optarg ;;
b2dad0e3
BK
500
501 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
502 ac_prev=prefix ;;
503 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
ff66d28f 504 prefix=$ac_optarg ;;
b2dad0e3
BK
505
506 -program-prefix | --program-prefix | --program-prefi | --program-pref \
507 | --program-pre | --program-pr | --program-p)
508 ac_prev=program_prefix ;;
509 -program-prefix=* | --program-prefix=* | --program-prefi=* \
510 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
ff66d28f 511 program_prefix=$ac_optarg ;;
b2dad0e3
BK
512
513 -program-suffix | --program-suffix | --program-suffi | --program-suff \
514 | --program-suf | --program-su | --program-s)
515 ac_prev=program_suffix ;;
516 -program-suffix=* | --program-suffix=* | --program-suffi=* \
517 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
ff66d28f 518 program_suffix=$ac_optarg ;;
b2dad0e3
BK
519
520 -program-transform-name | --program-transform-name \
521 | --program-transform-nam | --program-transform-na \
522 | --program-transform-n | --program-transform- \
523 | --program-transform | --program-transfor \
524 | --program-transfo | --program-transf \
525 | --program-trans | --program-tran \
526 | --progr-tra | --program-tr | --program-t)
527 ac_prev=program_transform_name ;;
528 -program-transform-name=* | --program-transform-name=* \
529 | --program-transform-nam=* | --program-transform-na=* \
530 | --program-transform-n=* | --program-transform-=* \
531 | --program-transform=* | --program-transfor=* \
532 | --program-transfo=* | --program-transf=* \
533 | --program-trans=* | --program-tran=* \
534 | --progr-tra=* | --program-tr=* | --program-t=*)
ff66d28f 535 program_transform_name=$ac_optarg ;;
b2dad0e3
BK
536
537 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
538 | -silent | --silent | --silen | --sile | --sil)
539 silent=yes ;;
540
541 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
542 ac_prev=sbindir ;;
543 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
544 | --sbi=* | --sb=*)
ff66d28f 545 sbindir=$ac_optarg ;;
b2dad0e3
BK
546
547 -sharedstatedir | --sharedstatedir | --sharedstatedi \
548 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
549 | --sharedst | --shareds | --shared | --share | --shar \
550 | --sha | --sh)
551 ac_prev=sharedstatedir ;;
552 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
553 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
554 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
555 | --sha=* | --sh=*)
ff66d28f 556 sharedstatedir=$ac_optarg ;;
b2dad0e3
BK
557
558 -site | --site | --sit)
559 ac_prev=site ;;
560 -site=* | --site=* | --sit=*)
ff66d28f 561 site=$ac_optarg ;;
b2dad0e3
BK
562
563 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
564 ac_prev=srcdir ;;
565 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
ff66d28f 566 srcdir=$ac_optarg ;;
b2dad0e3
BK
567
568 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
569 | --syscon | --sysco | --sysc | --sys | --sy)
570 ac_prev=sysconfdir ;;
571 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
572 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
ff66d28f 573 sysconfdir=$ac_optarg ;;
b2dad0e3
BK
574
575 -target | --target | --targe | --targ | --tar | --ta | --t)
ff66d28f 576 ac_prev=target_alias ;;
b2dad0e3 577 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
ff66d28f 578 target_alias=$ac_optarg ;;
b2dad0e3
BK
579
580 -v | -verbose | --verbose | --verbos | --verbo | --verb)
581 verbose=yes ;;
582
ff66d28f
PE
583 -version | --version | --versio | --versi | --vers | -V)
584 ac_init_version=: ;;
b2dad0e3
BK
585
586 -with-* | --with-*)
ff66d28f 587 ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
b2dad0e3 588 # Reject names that are not valid shell variable names.
ff66d28f
PE
589 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
590 { echo "$as_me: error: invalid package name: $ac_package" >&2
591 { (exit 1); exit 1; }; }
b2dad0e3 592 ac_package=`echo $ac_package| sed 's/-/_/g'`
ff66d28f
PE
593 case $ac_option in
594 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
b2dad0e3
BK
595 *) ac_optarg=yes ;;
596 esac
ff66d28f 597 eval "with_$ac_package='$ac_optarg'" ;;
b2dad0e3
BK
598
599 -without-* | --without-*)
ff66d28f 600 ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
b2dad0e3 601 # Reject names that are not valid shell variable names.
ff66d28f
PE
602 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
603 { echo "$as_me: error: invalid package name: $ac_package" >&2
604 { (exit 1); exit 1; }; }
605 ac_package=`echo $ac_package | sed 's/-/_/g'`
606 eval "with_$ac_package=no" ;;
b2dad0e3
BK
607
608 --x)
609 # Obsolete; use --with-x.
610 with_x=yes ;;
611
612 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
613 | --x-incl | --x-inc | --x-in | --x-i)
614 ac_prev=x_includes ;;
615 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
616 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
ff66d28f 617 x_includes=$ac_optarg ;;
b2dad0e3
BK
618
619 -x-libraries | --x-libraries | --x-librarie | --x-librari \
620 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
621 ac_prev=x_libraries ;;
622 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
623 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
ff66d28f 624 x_libraries=$ac_optarg ;;
b2dad0e3 625
ff66d28f
PE
626 -*) { echo "$as_me: error: unrecognized option: $ac_option
627Try \`$0 --help' for more information." >&2
628 { (exit 1); exit 1; }; }
b2dad0e3
BK
629 ;;
630
ff66d28f
PE
631 *=*)
632 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
633 # Reject names that are not valid shell variable names.
634 expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
635 { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
636 { (exit 1); exit 1; }; }
637 ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
638 eval "$ac_envvar='$ac_optarg'"
639 export $ac_envvar ;;
640
b2dad0e3 641 *)
ff66d28f
PE
642 # FIXME: should be removed in autoconf 3.0.
643 echo "$as_me: WARNING: you should use --build, --host, --target" >&2
644 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
645 echo "$as_me: WARNING: invalid host type: $ac_option" >&2
646 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
b2dad0e3
BK
647 ;;
648
649 esac
650done
651
652if test -n "$ac_prev"; then
ff66d28f
PE
653 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
654 { echo "$as_me: error: missing argument to $ac_option" >&2
655 { (exit 1); exit 1; }; }
b2dad0e3 656fi
b2dad0e3 657
ff66d28f
PE
658# Be sure to have absolute paths.
659for ac_var in exec_prefix prefix
660do
661 eval ac_val=$`echo $ac_var`
662 case $ac_val in
663 [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
664 *) { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
665 { (exit 1); exit 1; }; };;
666 esac
667done
b2dad0e3 668
ff66d28f
PE
669# Be sure to have absolute paths.
670for ac_var in bindir sbindir libexecdir datadir sysconfdir sharedstatedir \
ec2075e9 671 localstatedir libdir includedir oldincludedir infodir mandir
b2dad0e3 672do
ff66d28f
PE
673 eval ac_val=$`echo $ac_var`
674 case $ac_val in
675 [\\/$]* | ?:[\\/]* ) ;;
676 *) { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
677 { (exit 1); exit 1; }; };;
b2dad0e3
BK
678 esac
679done
680
ff66d28f
PE
681# There might be people who depend on the old broken behavior: `$host'
682# used to hold the argument of --host etc.
683# FIXME: To remove some day.
684build=$build_alias
685host=$host_alias
686target=$target_alias
b2dad0e3 687
ff66d28f
PE
688# FIXME: To remove some day.
689if test "x$host_alias" != x; then
690 if test "x$build_alias" = x; then
691 cross_compiling=maybe
692 echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
693 If a cross compiler is detected then cross compile mode will be used." >&2
694 elif test "x$build_alias" != "x$host_alias"; then
695 cross_compiling=yes
696 fi
697fi
698
699ac_tool_prefix=
700test -n "$host_alias" && ac_tool_prefix=$host_alias-
701
702test "$silent" = yes && exec 6>/dev/null
b2dad0e3 703
b2dad0e3
BK
704
705# Find the source files, if location was not specified.
706if test -z "$srcdir"; then
707 ac_srcdir_defaulted=yes
708 # Try the directory containing this script, then its parent.
ff66d28f
PE
709 ac_confdir=`(dirname "$0") 2>/dev/null ||
710$as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
ec2075e9
BK
711 X"$0" : 'X\(//\)[^/]' \| \
712 X"$0" : 'X\(//\)$' \| \
713 X"$0" : 'X\(/\)' \| \
714 . : '\(.\)' 2>/dev/null ||
ff66d28f
PE
715echo X"$0" |
716 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
717 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
718 /^X\(\/\/\)$/{ s//\1/; q; }
719 /^X\(\/\).*/{ s//\1/; q; }
720 s/.*/./; q'`
b2dad0e3
BK
721 srcdir=$ac_confdir
722 if test ! -r $srcdir/$ac_unique_file; then
723 srcdir=..
724 fi
725else
726 ac_srcdir_defaulted=no
727fi
728if test ! -r $srcdir/$ac_unique_file; then
729 if test "$ac_srcdir_defaulted" = yes; then
ff66d28f
PE
730 { echo "$as_me: error: cannot find sources ($ac_unique_file) in $ac_confdir or .." >&2
731 { (exit 1); exit 1; }; }
b2dad0e3 732 else
ff66d28f
PE
733 { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
734 { (exit 1); exit 1; }; }
735 fi
736fi
737(cd $srcdir && test -r ./$ac_unique_file) 2>/dev/null ||
738 { echo "$as_me: error: sources are in $srcdir, but \`cd $srcdir' does not work" >&2
739 { (exit 1); exit 1; }; }
740srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
741ac_env_build_alias_set=${build_alias+set}
742ac_env_build_alias_value=$build_alias
743ac_cv_env_build_alias_set=${build_alias+set}
744ac_cv_env_build_alias_value=$build_alias
745ac_env_host_alias_set=${host_alias+set}
746ac_env_host_alias_value=$host_alias
747ac_cv_env_host_alias_set=${host_alias+set}
748ac_cv_env_host_alias_value=$host_alias
749ac_env_target_alias_set=${target_alias+set}
750ac_env_target_alias_value=$target_alias
751ac_cv_env_target_alias_set=${target_alias+set}
752ac_cv_env_target_alias_value=$target_alias
ff66d28f
PE
753ac_env_CPP_set=${CPP+set}
754ac_env_CPP_value=$CPP
755ac_cv_env_CPP_set=${CPP+set}
756ac_cv_env_CPP_value=$CPP
464aea98
JM
757ac_env_CPPFLAGS_set=${CPPFLAGS+set}
758ac_env_CPPFLAGS_value=$CPPFLAGS
759ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
760ac_cv_env_CPPFLAGS_value=$CPPFLAGS
761ac_env_CXXCPP_set=${CXXCPP+set}
762ac_env_CXXCPP_value=$CXXCPP
763ac_cv_env_CXXCPP_set=${CXXCPP+set}
764ac_cv_env_CXXCPP_value=$CXXCPP
ff66d28f
PE
765
766#
767# Report the --help message.
768#
769if test "$ac_init_help" = "long"; then
770 # Omit some internal or obsolete options to make the list less imposing.
771 # This message is too long to be a string in the A/UX 3.1 sh.
772 cat <<_ACEOF
fbe057bb 773\`configure' configures package-unused version-unused to adapt to many kinds of systems.
ff66d28f
PE
774
775Usage: $0 [OPTION]... [VAR=VALUE]...
776
777To assign environment variables (e.g., CC, CFLAGS...), specify them as
778VAR=VALUE. See below for descriptions of some of the useful variables.
779
780Defaults for the options are specified in brackets.
781
782Configuration:
783 -h, --help display this help and exit
784 --help=short display options specific to this package
785 --help=recursive display the short help of all the included packages
786 -V, --version display version information and exit
787 -q, --quiet, --silent do not print \`checking...' messages
788 --cache-file=FILE cache test results in FILE [disabled]
789 -C, --config-cache alias for \`--cache-file=config.cache'
790 -n, --no-create do not create output files
791 --srcdir=DIR find the sources in DIR [configure dir or \`..']
792
793_ACEOF
794
795 cat <<_ACEOF
796Installation directories:
797 --prefix=PREFIX install architecture-independent files in PREFIX
ec2075e9 798 [$ac_default_prefix]
ff66d28f 799 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
ec2075e9 800 [PREFIX]
ff66d28f
PE
801
802By default, \`make install' will install all the files in
803\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
804an installation prefix other than \`$ac_default_prefix' using \`--prefix',
805for instance \`--prefix=\$HOME'.
806
807For better control, use the options below.
808
809Fine tuning of the installation directories:
810 --bindir=DIR user executables [EPREFIX/bin]
811 --sbindir=DIR system admin executables [EPREFIX/sbin]
812 --libexecdir=DIR program executables [EPREFIX/libexec]
813 --datadir=DIR read-only architecture-independent data [PREFIX/share]
814 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
815 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
816 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
817 --libdir=DIR object code libraries [EPREFIX/lib]
818 --includedir=DIR C header files [PREFIX/include]
819 --oldincludedir=DIR C header files for non-gcc [/usr/include]
820 --infodir=DIR info documentation [PREFIX/info]
821 --mandir=DIR man documentation [PREFIX/man]
822_ACEOF
823
824 cat <<\_ACEOF
825
826Program names:
827 --program-prefix=PREFIX prepend PREFIX to installed program names
828 --program-suffix=SUFFIX append SUFFIX to installed program names
829 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
830
831System types:
832 --build=BUILD configure for building on BUILD [guessed]
833 --host=HOST cross-compile to build programs to run on HOST [BUILD]
834 --target=TARGET configure for building compilers for TARGET [HOST]
835_ACEOF
836fi
837
838if test -n "$ac_init_help"; then
839 case $ac_init_help in
fbe057bb 840 short | recursive ) echo "Configuration of package-unused version-unused:";;
ff66d28f
PE
841 esac
842 cat <<\_ACEOF
843
844Optional Features:
845 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
846 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
7eaf73d7
KC
847 --enable-multilib build many library versions (default)
848 --enable-maintainer-mode enable make rules and dependencies not useful
849 (and sometimes confusing) to the casual installer
ff66d28f
PE
850 --enable-shared=PKGS build shared libraries default=yes
851 --enable-static=PKGS build static libraries default=yes
852 --enable-fast-install=PKGS optimize for fast installation default=yes
853 --disable-libtool-lock avoid locking (might break parallel builds)
92eabea2
PE
854 --disable-hosted-libstdcxx
855 only build freestanding C++ runtime support
ff66d28f 856 --enable-sjlj-exceptions
517da0ce
MM
857 force use of builtin_setjmp for exceptions
858 [default=auto]
859 --enable-libstdcxx-pch build pre-compiled libstdc++ headers
860 [default=$is_hosted]
861 --enable-cstdio=PACKAGE use target-specific I/O package
862 [default=stdio]
ff66d28f 863 --enable-clocale[=MODEL]
517da0ce
MM
864 use MODEL for target locale package
865 [default=auto]
866 --enable-nls use Native Language Support (default)
8b0d6051
BK
867 --enable-libstdcxx-allocator=KIND
868 use KIND for target std::allocator base
869 [default=auto]
517da0ce
MM
870 --enable-cheaders=KIND construct "C" headers for g++
871 [default=$c_model]
347669a0
BK
872 --enable-long-long enable template specializations for 'long long'
873 [default=yes]
874 --enable-wchar_t enable template specializations for 'wchar_t'
517da0ce 875 [default=yes]
8a9b2875
PC
876 --enable-c99 turns on ISO/IEC 9899:1999 support
877 [default=yes]
517da0ce 878 --enable-concept-checks use Boost-derived template checks [default=no]
ff66d28f 879 --enable-libstdcxx-debug-flags=FLAGS
517da0ce
MM
880 pass compiler FLAGS when building debug library
881 [default="-g3 -O0"]
ff66d28f
PE
882 --enable-libstdcxx-debug
883 build extra debug library [default=no]
884 --enable-cxx-flags=FLAGS
517da0ce
MM
885 pass compiler FLAGS when building library
886 [default=]
1165dc50
PC
887 --enable-fully-dynamic-string
888 do not put empty strings in per-process static
889 memory [default=no]
2fb31455 890 --enable-tls Use thread-local storage [default=yes]
5f34ed87 891 --disable-rpath do not hardcode runtime library paths
517da0ce
MM
892 --enable-symvers=STYLE enables symbol versioning of the shared library
893 [default=yes]
98e615b4 894 --enable-visibility enables visibility safe usage [default=yes]
ff66d28f 895 --enable-version-specific-runtime-libs
517da0ce
MM
896 Specify that runtime libraries should be installed
897 in a compiler-specific directory
ff66d28f
PE
898
899Optional Packages:
900 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
901 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
902 --with-target-subdir=SUBDIR
903 configuring in a subdirectory
517da0ce
MM
904 --with-cross-host=HOST configuring with a cross compiler
905 --with-newlib assume newlib as a system C library
ff66d28f
PE
906 --with-gnu-ld assume the C compiler uses GNU ld default=no
907 --with-pic try to use only PIC/non-PIC objects default=use both
4ffe6e87
BK
908 --with-libiconv-prefix[=DIR] search for libiconv in DIR/include and DIR/lib
909 --without-libiconv-prefix don't search for libiconv in includedir and libdir
ff66d28f
PE
910 --with-gxx-include-dir=DIR
911 installation directory for include files
912
913Some influential environment variables:
517da0ce
MM
914 CC C compiler command
915 CFLAGS C compiler flags
916 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
917 nonstandard directory <lib dir>
918 CPPFLAGS C/C++ preprocessor flags, e.g. -I<include dir> if you have
919 headers in a nonstandard directory <include dir>
920 CXX C++ compiler command
921 CXXFLAGS C++ compiler flags
517da0ce 922 CPP C preprocessor
464aea98 923 CXXCPP C++ preprocessor
ff66d28f
PE
924
925Use these variables to override the choices made by `configure' or to help
926it to find libraries and programs with nonstandard names/locations.
927
928_ACEOF
929fi
930
931if test "$ac_init_help" = "recursive"; then
932 # If there are subdirs, report their specific --help.
933 ac_popdir=`pwd`
934 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
935 test -d $ac_dir || continue
936 ac_builddir=.
937
938if test "$ac_dir" != .; then
939 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
940 # A "../" for each directory in $ac_dir_suffix.
941 ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
942else
943 ac_dir_suffix= ac_top_builddir=
944fi
945
946case $srcdir in
947 .) # No --srcdir option. We are building in place.
948 ac_srcdir=.
949 if test -z "$ac_top_builddir"; then
950 ac_top_srcdir=.
951 else
952 ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
953 fi ;;
954 [\\/]* | ?:[\\/]* ) # Absolute path.
955 ac_srcdir=$srcdir$ac_dir_suffix;
956 ac_top_srcdir=$srcdir ;;
957 *) # Relative path.
958 ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
959 ac_top_srcdir=$ac_top_builddir$srcdir ;;
960esac
ec2075e9
BK
961
962# Do not use `cd foo && pwd` to compute absolute paths, because
963# the directories may not exist.
964case `pwd` in
965.) ac_abs_builddir="$ac_dir";;
966*)
967 case "$ac_dir" in
968 .) ac_abs_builddir=`pwd`;;
969 [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
970 *) ac_abs_builddir=`pwd`/"$ac_dir";;
971 esac;;
972esac
973case $ac_abs_builddir in
974.) ac_abs_top_builddir=${ac_top_builddir}.;;
975*)
976 case ${ac_top_builddir}. in
977 .) ac_abs_top_builddir=$ac_abs_builddir;;
978 [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
979 *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
980 esac;;
981esac
982case $ac_abs_builddir in
983.) ac_abs_srcdir=$ac_srcdir;;
984*)
985 case $ac_srcdir in
986 .) ac_abs_srcdir=$ac_abs_builddir;;
987 [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
988 *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
989 esac;;
990esac
991case $ac_abs_builddir in
992.) ac_abs_top_srcdir=$ac_top_srcdir;;
993*)
994 case $ac_top_srcdir in
995 .) ac_abs_top_srcdir=$ac_abs_builddir;;
996 [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
997 *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
998 esac;;
999esac
ff66d28f
PE
1000
1001 cd $ac_dir
1002 # Check for guested configure; otherwise get Cygnus style configure.
1003 if test -f $ac_srcdir/configure.gnu; then
1004 echo
1005 $SHELL $ac_srcdir/configure.gnu --help=recursive
1006 elif test -f $ac_srcdir/configure; then
1007 echo
1008 $SHELL $ac_srcdir/configure --help=recursive
1009 elif test -f $ac_srcdir/configure.ac ||
ec2075e9 1010 test -f $ac_srcdir/configure.in; then
ff66d28f
PE
1011 echo
1012 $ac_configure --help
1013 else
1014 echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1015 fi
5b043f08 1016 cd $ac_popdir
ff66d28f
PE
1017 done
1018fi
1019
1020test -n "$ac_init_help" && exit 0
1021if $ac_init_version; then
1022 cat <<\_ACEOF
fbe057bb 1023package-unused configure version-unused
ec2075e9 1024generated by GNU Autoconf 2.59
ff66d28f 1025
ec2075e9 1026Copyright (C) 2003 Free Software Foundation, Inc.
ff66d28f
PE
1027This configure script is free software; the Free Software Foundation
1028gives unlimited permission to copy, distribute and modify it.
1029_ACEOF
1030 exit 0
b2dad0e3 1031fi
ff66d28f
PE
1032exec 5>config.log
1033cat >&5 <<_ACEOF
1034This file contains any messages produced by compilers while
1035running configure, to aid debugging if configure makes a mistake.
1036
fbe057bb 1037It was created by package-unused $as_me version-unused, which was
ec2075e9 1038generated by GNU Autoconf 2.59. Invocation command line was
ff66d28f
PE
1039
1040 $ $0 $@
1041
1042_ACEOF
1043{
1044cat <<_ASUNAME
1045## --------- ##
1046## Platform. ##
1047## --------- ##
1048
1049hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1050uname -m = `(uname -m) 2>/dev/null || echo unknown`
1051uname -r = `(uname -r) 2>/dev/null || echo unknown`
1052uname -s = `(uname -s) 2>/dev/null || echo unknown`
1053uname -v = `(uname -v) 2>/dev/null || echo unknown`
1054
1055/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1056/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
1057
1058/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
1059/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
1060/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
1061hostinfo = `(hostinfo) 2>/dev/null || echo unknown`
1062/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
1063/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
1064/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
1065
1066_ASUNAME
1067
1068as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1069for as_dir in $PATH
1070do
1071 IFS=$as_save_IFS
1072 test -z "$as_dir" && as_dir=.
1073 echo "PATH: $as_dir"
1074done
1075
1076} >&5
1077
1078cat >&5 <<_ACEOF
1079
1080
1081## ----------- ##
1082## Core tests. ##
1083## ----------- ##
1084
1085_ACEOF
1086
1087
1088# Keep a trace of the command line.
1089# Strip out --no-create and --no-recursion so they do not pile up.
1090# Strip out --silent because we don't want to record it for future runs.
1091# Also quote any args containing shell meta-characters.
1092# Make two passes to allow for proper duplicate-argument suppression.
1093ac_configure_args=
1094ac_configure_args0=
1095ac_configure_args1=
1096ac_sep=
1097ac_must_keep_next=false
1098for ac_pass in 1 2
1099do
1100 for ac_arg
1101 do
1102 case $ac_arg in
1103 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1104 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1105 | -silent | --silent | --silen | --sile | --sil)
1106 continue ;;
1107 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1108 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1109 esac
1110 case $ac_pass in
1111 1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1112 2)
1113 ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1114 if test $ac_must_keep_next = true; then
ec2075e9 1115 ac_must_keep_next=false # Got value, back to normal.
ff66d28f 1116 else
ec2075e9
BK
1117 case $ac_arg in
1118 *=* | --config-cache | -C | -disable-* | --disable-* \
1119 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1120 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1121 | -with-* | --with-* | -without-* | --without-* | --x)
1122 case "$ac_configure_args0 " in
1123 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1124 esac
1125 ;;
1126 -* ) ac_must_keep_next=true ;;
1127 esac
ff66d28f
PE
1128 fi
1129 ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
1130 # Get rid of the leading space.
1131 ac_sep=" "
1132 ;;
1133 esac
1134 done
1135done
1136$as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1137$as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
1138
1139# When interrupted or exit'd, cleanup temporary files, and complete
1140# config.log. We remove comments because anyway the quotes in there
1141# would cause problems or look ugly.
1142# WARNING: Be sure not to use single quotes in there, as some shells,
1143# such as our DU 5.0 friend, will then `close' the trap.
1144trap 'exit_status=$?
1145 # Save into config.log some information that might help in debugging.
1146 {
1147 echo
1148
1149 cat <<\_ASBOX
1150## ---------------- ##
1151## Cache variables. ##
1152## ---------------- ##
1153_ASBOX
1154 echo
1155 # The following way of writing the cache mishandles newlines in values,
1156{
1157 (set) 2>&1 |
1158 case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
1159 *ac_space=\ *)
1160 sed -n \
ec2075e9
BK
1161 "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
1162 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
ff66d28f
PE
1163 ;;
1164 *)
1165 sed -n \
ec2075e9 1166 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
ff66d28f
PE
1167 ;;
1168 esac;
1169}
1170 echo
1171
1172 cat <<\_ASBOX
1173## ----------------- ##
1174## Output variables. ##
1175## ----------------- ##
1176_ASBOX
1177 echo
1178 for ac_var in $ac_subst_vars
1179 do
1180 eval ac_val=$`echo $ac_var`
1181 echo "$ac_var='"'"'$ac_val'"'"'"
1182 done | sort
1183 echo
1184
1185 if test -n "$ac_subst_files"; then
1186 cat <<\_ASBOX
1187## ------------- ##
1188## Output files. ##
1189## ------------- ##
1190_ASBOX
1191 echo
1192 for ac_var in $ac_subst_files
1193 do
1194 eval ac_val=$`echo $ac_var`
ec2075e9 1195 echo "$ac_var='"'"'$ac_val'"'"'"
ff66d28f
PE
1196 done | sort
1197 echo
1198 fi
1199
1200 if test -s confdefs.h; then
1201 cat <<\_ASBOX
1202## ----------- ##
1203## confdefs.h. ##
1204## ----------- ##
1205_ASBOX
1206 echo
1207 sed "/^$/d" confdefs.h | sort
1208 echo
1209 fi
1210 test "$ac_signal" != 0 &&
1211 echo "$as_me: caught signal $ac_signal"
1212 echo "$as_me: exit $exit_status"
1213 } >&5
ec2075e9 1214 rm -f core *.core &&
ff66d28f
PE
1215 rm -rf conftest* confdefs* conf$$* $ac_clean_files &&
1216 exit $exit_status
1217 ' 0
1218for ac_signal in 1 2 13 15; do
1219 trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1220done
1221ac_signal=0
1222
1223# confdefs.h avoids OS command line length limits that DEFS can exceed.
1224rm -rf conftest* confdefs.h
1225# AIX cpp loses on an empty file, so make sure it contains at least a newline.
1226echo >confdefs.h
1227
1228# Predefined preprocessor variables.
1229
1230cat >>confdefs.h <<_ACEOF
1231#define PACKAGE_NAME "$PACKAGE_NAME"
1232_ACEOF
1233
1234
1235cat >>confdefs.h <<_ACEOF
1236#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1237_ACEOF
1238
1239
1240cat >>confdefs.h <<_ACEOF
1241#define PACKAGE_VERSION "$PACKAGE_VERSION"
1242_ACEOF
1243
b2dad0e3 1244
ff66d28f
PE
1245cat >>confdefs.h <<_ACEOF
1246#define PACKAGE_STRING "$PACKAGE_STRING"
1247_ACEOF
1248
1249
1250cat >>confdefs.h <<_ACEOF
1251#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1252_ACEOF
1253
1254
1255# Let the site file select an alternate cache file if it wants to.
b2dad0e3 1256# Prefer explicitly selected file to automatically selected ones.
a0f27776
PE
1257if test -z "$CONFIG_SITE"; then
1258 if test "x$prefix" != xNONE; then
1259 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
1260 else
1261 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
b2dad0e3
BK
1262 fi
1263fi
1264for ac_site_file in $CONFIG_SITE; do
1265 if test -r "$ac_site_file"; then
ff66d28f
PE
1266 { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1267echo "$as_me: loading site script $ac_site_file" >&6;}
1268 sed 's/^/| /' "$ac_site_file" >&5
b2dad0e3
BK
1269 . "$ac_site_file"
1270 fi
1271done
1272
1273if test -r "$cache_file"; then
ff66d28f
PE
1274 # Some versions of bash will fail to source /dev/null (special
1275 # files actually), so we avoid doing that.
1276 if test -f "$cache_file"; then
1277 { echo "$as_me:$LINENO: loading cache $cache_file" >&5
1278echo "$as_me: loading cache $cache_file" >&6;}
1279 case $cache_file in
1280 [\\/]* | ?:[\\/]* ) . $cache_file;;
1281 *) . ./$cache_file;;
1282 esac
1283 fi
b2dad0e3 1284else
ff66d28f
PE
1285 { echo "$as_me:$LINENO: creating cache $cache_file" >&5
1286echo "$as_me: creating cache $cache_file" >&6;}
1287 >$cache_file
1288fi
1289
1290# Check that the precious variables saved in the cache have kept the same
1291# value.
1292ac_cache_corrupted=false
1293for ac_var in `(set) 2>&1 |
ec2075e9 1294 sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
ff66d28f
PE
1295 eval ac_old_set=\$ac_cv_env_${ac_var}_set
1296 eval ac_new_set=\$ac_env_${ac_var}_set
1297 eval ac_old_val="\$ac_cv_env_${ac_var}_value"
1298 eval ac_new_val="\$ac_env_${ac_var}_value"
1299 case $ac_old_set,$ac_new_set in
1300 set,)
1301 { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1302echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1303 ac_cache_corrupted=: ;;
1304 ,set)
1305 { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1306echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1307 ac_cache_corrupted=: ;;
1308 ,);;
1309 *)
1310 if test "x$ac_old_val" != "x$ac_new_val"; then
ec2075e9 1311 { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
ff66d28f 1312echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
ec2075e9 1313 { echo "$as_me:$LINENO: former value: $ac_old_val" >&5
ff66d28f 1314echo "$as_me: former value: $ac_old_val" >&2;}
ec2075e9 1315 { echo "$as_me:$LINENO: current value: $ac_new_val" >&5
ff66d28f 1316echo "$as_me: current value: $ac_new_val" >&2;}
ec2075e9 1317 ac_cache_corrupted=:
ff66d28f
PE
1318 fi;;
1319 esac
1320 # Pass precious variables to config.status.
1321 if test "$ac_new_set" = set; then
1322 case $ac_new_val in
1323 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1324 ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1325 *) ac_arg=$ac_var=$ac_new_val ;;
1326 esac
1327 case " $ac_configure_args " in
1328 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
1329 *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1330 esac
1331 fi
1332done
1333if $ac_cache_corrupted; then
1334 { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1335echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1336 { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1337echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1338 { (exit 1); exit 1; }; }
b2dad0e3
BK
1339fi
1340
1341ac_ext=c
b2dad0e3 1342ac_cpp='$CPP $CPPFLAGS'
ff66d28f
PE
1343ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1344ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1345ac_compiler_gnu=$ac_cv_c_compiler_gnu
b2dad0e3
BK
1346
1347
e2c20fae 1348
6706f116 1349
33590f13
BK
1350
1351
1352
aebb8c22 1353
aebb8c22 1354
ff66d28f
PE
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374 ac_config_headers="$ac_config_headers config.h"
1375
1376
1377# This works around the fact that libtool configuration may change LD
1378# for this particular configuration, but some shells, instead of
1379# keeping the changes in LD private, export them just because LD is
1380# exported. Only used at the end of this file.
1381### am handles this now? ORIGINAL_LD_FOR_MULTILIBS=$LD
1382
1383# For libtool versioning info, format is CURRENT:REVISION:AGE
c3f0f556 1384libtool_VERSION=6:9:0
ff66d28f
PE
1385
1386
1387# Find the rest of the source tree framework.
076e5443 1388# Default to --enable-multilib
ff66d28f
PE
1389# Check whether --enable-multilib or --disable-multilib was given.
1390if test "${enable_multilib+set}" = set; then
1391 enableval="$enable_multilib"
1392 case "$enableval" in
1393 yes) multilib=yes ;;
1394 no) multilib=no ;;
1395 *) { { echo "$as_me:$LINENO: error: bad value $enableval for multilib option" >&5
1396echo "$as_me: error: bad value $enableval for multilib option" >&2;}
1397 { (exit 1); exit 1; }; } ;;
1398 esac
1399else
1400 multilib=yes
1401fi;
1402
1403# We may get other options which we leave undocumented:
1404# --with-target-subdir, --with-multisrctop, --with-multisubdir
1405# See config-ml.in if you want the gory details.
1406
1407if test "$srcdir" = "."; then
1408 if test "$with_target_subdir" != "."; then
1409 multi_basedir="$srcdir/$with_multisrctop../.."
1410 else
1411 multi_basedir="$srcdir/$with_multisrctop.."
1412 fi
1413else
1414 multi_basedir="$srcdir/.."
1415fi
1416
1417
5b043f08
GK
1418# Even if the default multilib is not a cross compilation,
1419# it may be that some of the other multilibs are.
1420if test $cross_compiling = no && test $multilib = yes \
1421 && test "x${with_multisubdir}" != x ; then
1422 cross_compiling=maybe
1423fi
1424
ff66d28f
PE
1425 ac_config_commands="$ac_config_commands default-1"
1426
1427
076e5443
PB
1428# Gets build, host, target, *_vendor, *_cpu, *_os, etc.
1429#
1430# You will slowly go insane if you do not grok the following fact: when
1431# building v3 as part of the compiler, the top-level /target/ becomes the
1432# library's /host/. configure then causes --target to default to --host,
1433# exactly like any other package using autoconf. Therefore, 'target' and
1434# 'host' will always be the same. This makes sense both for native and
1435# cross compilers, just think about it for a little while. :-)
1436#
1437# Also, if v3 is being configured as part of a cross compiler, the top-level
1438# configure script will pass the "real" host as $with_cross_host.
1439#
1440# Do not delete or change the following two lines. For why, see
1441# http://gcc.gnu.org/ml/libstdc++/2003-07/msg00451.html
1442ac_aux_dir=
1443for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
ff66d28f
PE
1444 if test -f $ac_dir/install-sh; then
1445 ac_aux_dir=$ac_dir
1446 ac_install_sh="$ac_aux_dir/install-sh -c"
1447 break
1448 elif test -f $ac_dir/install.sh; then
1449 ac_aux_dir=$ac_dir
b2dad0e3
BK
1450 ac_install_sh="$ac_aux_dir/install.sh -c"
1451 break
ff66d28f
PE
1452 elif test -f $ac_dir/shtool; then
1453 ac_aux_dir=$ac_dir
1454 ac_install_sh="$ac_aux_dir/shtool install -c"
1455 break
b2dad0e3
BK
1456 fi
1457done
1458if test -z "$ac_aux_dir"; then
076e5443
PB
1459 { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
1460echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
ff66d28f 1461 { (exit 1); exit 1; }; }
b2dad0e3 1462fi
ff66d28f
PE
1463ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1464ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1465ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
1466
ff66d28f
PE
1467# Make sure we can run config.sub.
1468$ac_config_sub sun4 >/dev/null 2>&1 ||
1469 { { echo "$as_me:$LINENO: error: cannot run $ac_config_sub" >&5
1470echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1471 { (exit 1); exit 1; }; }
1472
1473echo "$as_me:$LINENO: checking build system type" >&5
1474echo $ECHO_N "checking build system type... $ECHO_C" >&6
1475if test "${ac_cv_build+set}" = set; then
1476 echo $ECHO_N "(cached) $ECHO_C" >&6
1477else
1478 ac_cv_build_alias=$build_alias
1479test -z "$ac_cv_build_alias" &&
1480 ac_cv_build_alias=`$ac_config_guess`
1481test -z "$ac_cv_build_alias" &&
1482 { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
1483echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1484 { (exit 1); exit 1; }; }
1485ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
1486 { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_build_alias failed" >&5
1487echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed" >&2;}
1488 { (exit 1); exit 1; }; }
1489
1490fi
1491echo "$as_me:$LINENO: result: $ac_cv_build" >&5
1492echo "${ECHO_T}$ac_cv_build" >&6
1493build=$ac_cv_build
1494build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1495build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1496build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1497
1498
1499echo "$as_me:$LINENO: checking host system type" >&5
1500echo $ECHO_N "checking host system type... $ECHO_C" >&6
1501if test "${ac_cv_host+set}" = set; then
1502 echo $ECHO_N "(cached) $ECHO_C" >&6
1503else
1504 ac_cv_host_alias=$host_alias
1505test -z "$ac_cv_host_alias" &&
1506 ac_cv_host_alias=$ac_cv_build_alias
1507ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
1508 { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_host_alias failed" >&5
1509echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1510 { (exit 1); exit 1; }; }
1511
1512fi
1513echo "$as_me:$LINENO: result: $ac_cv_host" >&5
1514echo "${ECHO_T}$ac_cv_host" >&6
1515host=$ac_cv_host
1516host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1517host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1518host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1519
1520
1521echo "$as_me:$LINENO: checking target system type" >&5
1522echo $ECHO_N "checking target system type... $ECHO_C" >&6
1523if test "${ac_cv_target+set}" = set; then
1524 echo $ECHO_N "(cached) $ECHO_C" >&6
1525else
1526 ac_cv_target_alias=$target_alias
1527test "x$ac_cv_target_alias" = "x" &&
1528 ac_cv_target_alias=$ac_cv_host_alias
1529ac_cv_target=`$ac_config_sub $ac_cv_target_alias` ||
1530 { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_target_alias failed" >&5
1531echo "$as_me: error: $ac_config_sub $ac_cv_target_alias failed" >&2;}
1532 { (exit 1); exit 1; }; }
1533
1534fi
1535echo "$as_me:$LINENO: result: $ac_cv_target" >&5
1536echo "${ECHO_T}$ac_cv_target" >&6
1537target=$ac_cv_target
1538target_cpu=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1539target_vendor=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1540target_os=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
b2dad0e3 1541
b2dad0e3
BK
1542
1543# The aliases save the names the user supplied, while $host etc.
1544# will get canonicalized.
ff66d28f
PE
1545test -n "$target_alias" &&
1546 test "$program_prefix$program_suffix$program_transform_name" = \
1547 NONENONEs,x,x, &&
1548 program_prefix=${target_alias}-
1549target_alias=${target_alias-$host_alias}
1550
1551# Handy for debugging:
1552#AC_MSG_NOTICE($build / $host / $target / $host_alias / $target_alias); sleep 5
1553
0df3f383
PE
1554if test "$build" != "$host"; then
1555 # We are being configured with some form of cross compiler.
1556 GLIBCXX_IS_NATIVE=false
0646b059
GK
1557 case "$host","$target" in
1558 # Darwin crosses can use the host system's libraries and headers,
1559 # because of the fat library support. Of course, it must be the
1560 # same version of Darwin on both sides. Allow the user to
1561 # just say --target=foo-darwin without a version number to mean
1562 # "the version on this system".
1563 *-*-darwin*,*-*-darwin*)
1564 hostos=`echo $host | sed 's/.*-darwin/darwin/'`
1565 targetos=`echo $target | sed 's/.*-darwin/darwin/'`
1566 if test $hostos = $targetos -o $targetos = darwin ; then
1567 GLIBCXX_IS_NATIVE=true
1568 fi
1569 ;;
1570
1571 *)
3a24bf5d 1572
0646b059
GK
1573 ;;
1574 esac
0df3f383
PE
1575else
1576 GLIBCXX_IS_NATIVE=true
1577fi
1578
ff66d28f
PE
1579# Sets up automake. Must come after AC_CANONICAL_SYSTEM. Each of the
1580# following is magically included in AUTOMAKE_OPTIONS in each Makefile.am.
1581# 1.x: minimum required version
1582# no-define: PACKAGE and VERSION will not be #define'd in config.h (a bunch
1583# of other PACKAGE_* variables will, however, and there's nothing
fbe057bb 1584# we can do about that; they come from AC_INIT).
ff66d28f
PE
1585# foreign: we don't follow the normal rules for GNU packages (no COPYING
1586# file in the top srcdir, etc, etc), so stop complaining.
1587# no-dependencies: turns off auto dependency generation (just for now)
2d52e9e3
PE
1588# -Wall: turns on all automake warnings...
1589# -Wno-portability: ...except this one, since GNU make is now required.
a60945f8 1590am__api_version="1.9"
ff66d28f
PE
1591# Find a good install program. We prefer a C program (faster),
1592# so one script is as good as another. But avoid the broken or
1593# incompatible versions:
1594# SysV /etc/install, /usr/sbin/install
1595# SunOS /usr/etc/install
1596# IRIX /sbin/install
1597# AIX /bin/install
1598# AmigaOS /C/install, which installs bootblocks on floppy discs
1599# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
1600# AFS /usr/afsws/bin/install, which mishandles nonexistent args
1601# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
ec2075e9 1602# OS/2's system install, which has a completely different semantic
ff66d28f
PE
1603# ./install, which can be erroneously created by make from ./install.sh.
1604echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
1605echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6
1606if test -z "$INSTALL"; then
1607if test "${ac_cv_path_install+set}" = set; then
1608 echo $ECHO_N "(cached) $ECHO_C" >&6
1609else
1610 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1611for as_dir in $PATH
1612do
1613 IFS=$as_save_IFS
1614 test -z "$as_dir" && as_dir=.
1615 # Account for people who put trailing slashes in PATH elements.
1616case $as_dir/ in
1617 ./ | .// | /cC/* | \
1618 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
ec2075e9 1619 ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \
ff66d28f
PE
1620 /usr/ucb/* ) ;;
1621 *)
1622 # OSF1 and SCO ODT 3.0 have their own names for install.
1623 # Don't use installbsd from OSF since it installs stuff as root
1624 # by default.
1625 for ac_prog in ginstall scoinst install; do
1626 for ac_exec_ext in '' $ac_executable_extensions; do
ec2075e9
BK
1627 if $as_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
1628 if test $ac_prog = install &&
1629 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
1630 # AIX install. It has an incompatible calling convention.
1631 :
1632 elif test $ac_prog = install &&
1633 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
1634 # program-specific install script used by HP pwplus--don't use.
1635 :
1636 else
1637 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
1638 break 3
1639 fi
1640 fi
ff66d28f
PE
1641 done
1642 done
1643 ;;
b2dad0e3 1644esac
ff66d28f 1645done
b2dad0e3
BK
1646
1647
b2dad0e3 1648fi
ff66d28f
PE
1649 if test "${ac_cv_path_install+set}" = set; then
1650 INSTALL=$ac_cv_path_install
1651 else
1652 # As a last resort, use the slow shell script. We don't cache a
1653 # path for INSTALL within a source directory, because that will
1654 # break other packages using the cache if that directory is
1655 # removed, or if the path is relative.
1656 INSTALL=$ac_install_sh
1657 fi
1658fi
1659echo "$as_me:$LINENO: result: $INSTALL" >&5
1660echo "${ECHO_T}$INSTALL" >&6
b2dad0e3 1661
ff66d28f
PE
1662# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
1663# It thinks the first close brace ends the variable substitution.
1664test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
b2dad0e3 1665
ff66d28f 1666test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
b2dad0e3 1667
ff66d28f 1668test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
b2dad0e3 1669
ff66d28f
PE
1670echo "$as_me:$LINENO: checking whether build environment is sane" >&5
1671echo $ECHO_N "checking whether build environment is sane... $ECHO_C" >&6
1672# Just in case
1673sleep 1
1674echo timestamp > conftest.file
1675# Do `set' in a subshell so we don't clobber the current shell's
1676# arguments. Must try -L first in case configure is actually a
1677# symlink; some systems play weird games with the mod time of symlinks
1678# (eg FreeBSD returns the mod time of the symlink's containing
1679# directory).
1680if (
1681 set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null`
1682 if test "$*" = "X"; then
1683 # -L didn't work.
1684 set X `ls -t $srcdir/configure conftest.file`
1685 fi
1686 rm -f conftest.file
1687 if test "$*" != "X $srcdir/configure conftest.file" \
1688 && test "$*" != "X conftest.file $srcdir/configure"; then
b2dad0e3 1689
ff66d28f
PE
1690 # If neither matched, then we have a broken ls. This can happen
1691 # if, for instance, CONFIG_SHELL is bash and it inherits a
1692 # broken ls alias from the environment. This has actually
1693 # happened. Such a system could not be considered "sane".
1694 { { echo "$as_me:$LINENO: error: ls -t appears to fail. Make sure there is not a broken
1695alias in your environment" >&5
1696echo "$as_me: error: ls -t appears to fail. Make sure there is not a broken
1697alias in your environment" >&2;}
1698 { (exit 1); exit 1; }; }
1699 fi
b2dad0e3 1700
ff66d28f
PE
1701 test "$2" = conftest.file
1702 )
1703then
1704 # Ok.
1705 :
33590f13 1706else
ff66d28f
PE
1707 { { echo "$as_me:$LINENO: error: newly created file is older than distributed files!
1708Check your system clock" >&5
1709echo "$as_me: error: newly created file is older than distributed files!
1710Check your system clock" >&2;}
1711 { (exit 1); exit 1; }; }
33590f13 1712fi
ff66d28f
PE
1713echo "$as_me:$LINENO: result: yes" >&5
1714echo "${ECHO_T}yes" >&6
1715test "$program_prefix" != NONE &&
1716 program_transform_name="s,^,$program_prefix,;$program_transform_name"
1717# Use a double $ so make ignores it.
1718test "$program_suffix" != NONE &&
1719 program_transform_name="s,\$,$program_suffix,;$program_transform_name"
1720# Double any \ or $. echo might interpret backslashes.
1721# By default was `s,x,x', remove it if useless.
1722cat <<\_ACEOF >conftest.sed
1723s/[\\$]/&&/g;s/;s,x,x,$//
1724_ACEOF
1725program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
1726rm conftest.sed
b2dad0e3 1727
ff66d28f
PE
1728# expand $ac_aux_dir to an absolute path
1729am_aux_dir=`cd $ac_aux_dir && pwd`
33590f13 1730
ff66d28f
PE
1731test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing"
1732# Use eval to expand $SHELL
1733if eval "$MISSING --run true"; then
1734 am_missing_run="$MISSING --run "
b2dad0e3 1735else
ff66d28f
PE
1736 am_missing_run=
1737 { echo "$as_me:$LINENO: WARNING: \`missing' script is too old or missing" >&5
1738echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
33590f13
BK
1739fi
1740
7eaf73d7 1741if mkdir -p --version . >/dev/null 2>&1 && test ! -d ./--version; then
a60945f8
PC
1742 # We used to keeping the `.' as first argument, in order to
1743 # allow $(mkdir_p) to be used without argument. As in
7eaf73d7 1744 # $(mkdir_p) $(somedir)
a60945f8
PC
1745 # where $(somedir) is conditionally defined. However this is wrong
1746 # for two reasons:
1747 # 1. if the package is installed by a user who cannot write `.'
1748 # make install will fail,
1749 # 2. the above comment should most certainly read
1750 # $(mkdir_p) $(DESTDIR)$(somedir)
1751 # so it does not work when $(somedir) is undefined and
1752 # $(DESTDIR) is not.
1753 # To support the latter case, we have to write
1754 # test -z "$(somedir)" || $(mkdir_p) $(DESTDIR)$(somedir),
1755 # so the `.' trick is pointless.
1756 mkdir_p='mkdir -p --'
7eaf73d7
KC
1757else
1758 # On NextStep and OpenStep, the `mkdir' command does not
1759 # recognize any option. It will interpret all options as
1760 # directories to create, and then abort because `.' already
1761 # exists.
1762 for d in ./-p ./--version;
1763 do
1764 test -d $d && rmdir $d
1765 done
1766 # $(mkinstalldirs) is defined by Automake if mkinstalldirs exists.
1767 if test -f "$ac_aux_dir/mkinstalldirs"; then
1768 mkdir_p='$(mkinstalldirs)'
1769 else
1770 mkdir_p='$(install_sh) -d'
1771 fi
1772fi
1773
ff66d28f 1774for ac_prog in gawk mawk nawk awk
c98b201b 1775do
ff66d28f 1776 # Extract the first word of "$ac_prog", so it can be a program name with args.
c98b201b 1777set dummy $ac_prog; ac_word=$2
ff66d28f
PE
1778echo "$as_me:$LINENO: checking for $ac_word" >&5
1779echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1780if test "${ac_cv_prog_AWK+set}" = set; then
1781 echo $ECHO_N "(cached) $ECHO_C" >&6
c98b201b
PE
1782else
1783 if test -n "$AWK"; then
1784 ac_cv_prog_AWK="$AWK" # Let the user override the test.
1785else
ff66d28f
PE
1786as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1787for as_dir in $PATH
1788do
1789 IFS=$as_save_IFS
1790 test -z "$as_dir" && as_dir=.
1791 for ac_exec_ext in '' $ac_executable_extensions; do
1792 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1793 ac_cv_prog_AWK="$ac_prog"
1794 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1795 break 2
1796 fi
1797done
1798done
1799
c98b201b
PE
1800fi
1801fi
ff66d28f 1802AWK=$ac_cv_prog_AWK
c98b201b 1803if test -n "$AWK"; then
ff66d28f
PE
1804 echo "$as_me:$LINENO: result: $AWK" >&5
1805echo "${ECHO_T}$AWK" >&6
c98b201b 1806else
ff66d28f
PE
1807 echo "$as_me:$LINENO: result: no" >&5
1808echo "${ECHO_T}no" >&6
c98b201b
PE
1809fi
1810
ff66d28f 1811 test -n "$AWK" && break
c98b201b
PE
1812done
1813
ff66d28f
PE
1814echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5
1815echo $ECHO_N "checking whether ${MAKE-make} sets \$(MAKE)... $ECHO_C" >&6
ec2075e9 1816set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,:./+-,___p_,'`
ff66d28f
PE
1817if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
1818 echo $ECHO_N "(cached) $ECHO_C" >&6
1819else
1820 cat >conftest.make <<\_ACEOF
1821all:
1822 @echo 'ac_maketemp="$(MAKE)"'
1823_ACEOF
1824# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1825eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
1826if test -n "$ac_maketemp"; then
1827 eval ac_cv_prog_make_${ac_make}_set=yes
33590f13 1828else
ff66d28f 1829 eval ac_cv_prog_make_${ac_make}_set=no
33590f13 1830fi
ff66d28f 1831rm -f conftest.make
33590f13 1832fi
ff66d28f
PE
1833if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
1834 echo "$as_me:$LINENO: result: yes" >&5
1835echo "${ECHO_T}yes" >&6
1836 SET_MAKE=
33590f13 1837else
ff66d28f
PE
1838 echo "$as_me:$LINENO: result: no" >&5
1839echo "${ECHO_T}no" >&6
1840 SET_MAKE="MAKE=${MAKE-make}"
33590f13
BK
1841fi
1842
ff66d28f
PE
1843rm -rf .tst 2>/dev/null
1844mkdir .tst 2>/dev/null
1845if test -d .tst; then
1846 am__leading_dot=.
1847else
1848 am__leading_dot=_
1849fi
1850rmdir .tst 2>/dev/null
33590f13 1851
7eaf73d7 1852# test to see if srcdir already configured
ff66d28f
PE
1853if test "`cd $srcdir && pwd`" != "`pwd`" &&
1854 test -f $srcdir/config.status; then
1855 { { echo "$as_me:$LINENO: error: source directory already configured; run \"make distclean\" there first" >&5
1856echo "$as_me: error: source directory already configured; run \"make distclean\" there first" >&2;}
1857 { (exit 1); exit 1; }; }
33590f13
BK
1858fi
1859
ff66d28f
PE
1860# test whether we have cygpath
1861if test -z "$CYGPATH_W"; then
1862 if (cygpath --version) >/dev/null 2>/dev/null; then
1863 CYGPATH_W='cygpath -w'
1864 else
1865 CYGPATH_W=echo
1866 fi
33590f13
BK
1867fi
1868
1869
ff66d28f 1870# Define the identity of the package.
fbe057bb 1871 PACKAGE='libstdc++'
ff66d28f 1872 VERSION='version-unused'
b731048b
BK
1873
1874
ff66d28f 1875# Some tools Automake needs.
33590f13 1876
ff66d28f 1877ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
33590f13 1878
33590f13 1879
ff66d28f 1880AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
33590f13 1881
ff66d28f
PE
1882
1883AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
1884
1885
1886AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
1887
1888
1889MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
1890
ff66d28f
PE
1891install_sh=${install_sh-"$am_aux_dir/install-sh"}
1892
1893# Installed binaries are usually stripped using `strip' when the user
1894# run `make install-strip'. However `strip' might not be the right
1895# tool to use in cross-compilation environments, therefore Automake
1896# will honor the `STRIP' environment variable to overrule this program.
1897if test "$cross_compiling" != no; then
1898 if test -n "$ac_tool_prefix"; then
1899 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
1900set dummy ${ac_tool_prefix}strip; ac_word=$2
1901echo "$as_me:$LINENO: checking for $ac_word" >&5
1902echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1903if test "${ac_cv_prog_STRIP+set}" = set; then
1904 echo $ECHO_N "(cached) $ECHO_C" >&6
33590f13 1905else
ff66d28f
PE
1906 if test -n "$STRIP"; then
1907 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
33590f13 1908else
ff66d28f
PE
1909as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1910for as_dir in $PATH
1911do
1912 IFS=$as_save_IFS
1913 test -z "$as_dir" && as_dir=.
1914 for ac_exec_ext in '' $ac_executable_extensions; do
1915 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1916 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
1917 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1918 break 2
1919 fi
1920done
1921done
1922
33590f13
BK
1923fi
1924fi
ff66d28f
PE
1925STRIP=$ac_cv_prog_STRIP
1926if test -n "$STRIP"; then
1927 echo "$as_me:$LINENO: result: $STRIP" >&5
1928echo "${ECHO_T}$STRIP" >&6
33590f13 1929else
ff66d28f
PE
1930 echo "$as_me:$LINENO: result: no" >&5
1931echo "${ECHO_T}no" >&6
33590f13
BK
1932fi
1933
ff66d28f
PE
1934fi
1935if test -z "$ac_cv_prog_STRIP"; then
1936 ac_ct_STRIP=$STRIP
1937 # Extract the first word of "strip", so it can be a program name with args.
1938set dummy strip; ac_word=$2
1939echo "$as_me:$LINENO: checking for $ac_word" >&5
1940echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1941if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
1942 echo $ECHO_N "(cached) $ECHO_C" >&6
33590f13 1943else
ff66d28f
PE
1944 if test -n "$ac_ct_STRIP"; then
1945 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
33590f13 1946else
ff66d28f
PE
1947as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1948for as_dir in $PATH
1949do
1950 IFS=$as_save_IFS
1951 test -z "$as_dir" && as_dir=.
1952 for ac_exec_ext in '' $ac_executable_extensions; do
1953 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1954 ac_cv_prog_ac_ct_STRIP="strip"
1955 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1956 break 2
b2dad0e3 1957 fi
ff66d28f
PE
1958done
1959done
1960
1961 test -z "$ac_cv_prog_ac_ct_STRIP" && ac_cv_prog_ac_ct_STRIP=":"
b2dad0e3
BK
1962fi
1963fi
ff66d28f
PE
1964ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
1965if test -n "$ac_ct_STRIP"; then
1966 echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
1967echo "${ECHO_T}$ac_ct_STRIP" >&6
b2dad0e3 1968else
ff66d28f
PE
1969 echo "$as_me:$LINENO: result: no" >&5
1970echo "${ECHO_T}no" >&6
b2dad0e3
BK
1971fi
1972
ff66d28f 1973 STRIP=$ac_ct_STRIP
b2dad0e3 1974else
ff66d28f 1975 STRIP="$ac_cv_prog_STRIP"
b2dad0e3 1976fi
ff66d28f 1977
b2dad0e3 1978fi
ff66d28f 1979INSTALL_STRIP_PROGRAM="\${SHELL} \$(install_sh) -c -s"
b2dad0e3 1980
ff66d28f
PE
1981# We need awk for the "check" target. The system "awk" is bad on
1982# some platforms.
a60945f8
PC
1983# Always define AMTAR for backward compatibility.
1984
1985AMTAR=${AMTAR-"${am_missing_run}tar"}
1986
1987am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'
1988
1989
b2dad0e3 1990
b2dad0e3 1991
b2dad0e3 1992
ff66d28f 1993
3a24bf5d
KC
1994
1995
1996
1997
ff66d28f
PE
1998# Runs configure.host, finds CC, CXX, and assorted other critical bits. Sets
1999# up critical shell variables.
2000
464aea98
JM
2001ac_ext=c
2002ac_cpp='$CPP $CPPFLAGS'
2003ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2004ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2005ac_compiler_gnu=$ac_cv_c_compiler_gnu
2006echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
2007echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
2008# On Suns, sometimes $CPP names a directory.
2009if test -n "$CPP" && test -d "$CPP"; then
2010 CPP=
2011fi
2012if test -z "$CPP"; then
2013 if test "${ac_cv_prog_CPP+set}" = set; then
2014 echo $ECHO_N "(cached) $ECHO_C" >&6
2015else
2016 # Double quotes because CPP needs to be expanded
2017 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
2018 do
2019 ac_preproc_ok=false
2020for ac_c_preproc_warn_flag in '' yes
2021do
2022 # Use a header file that comes with gcc, so configuring glibc
2023 # with a fresh cross-compiler works.
2024 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2025 # <limits.h> exists even on freestanding compilers.
2026 # On the NeXT, cc -E runs the code through the compiler's parser,
2027 # not just through cpp. "Syntax error" is here to catch this case.
2028 cat >conftest.$ac_ext <<_ACEOF
2029/* confdefs.h. */
2030_ACEOF
2031cat confdefs.h >>conftest.$ac_ext
2032cat >>conftest.$ac_ext <<_ACEOF
2033/* end confdefs.h. */
2034#ifdef __STDC__
2035# include <limits.h>
2036#else
2037# include <assert.h>
2038#endif
2039 Syntax error
2040_ACEOF
2041if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2042 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2043 ac_status=$?
2044 grep -v '^ *+' conftest.er1 >conftest.err
2045 rm -f conftest.er1
2046 cat conftest.err >&5
2047 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2048 (exit $ac_status); } >/dev/null; then
2049 if test -s conftest.err; then
2050 ac_cpp_err=$ac_c_preproc_warn_flag
2051 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
2052 else
2053 ac_cpp_err=
2054 fi
2055else
2056 ac_cpp_err=yes
2057fi
2058if test -z "$ac_cpp_err"; then
2059 :
2060else
2061 echo "$as_me: failed program was:" >&5
2062sed 's/^/| /' conftest.$ac_ext >&5
2063
2064 # Broken: fails on valid input.
2065continue
2066fi
2067rm -f conftest.err conftest.$ac_ext
2068
2069 # OK, works on sane cases. Now check whether non-existent headers
2070 # can be detected and how.
2071 cat >conftest.$ac_ext <<_ACEOF
2072/* confdefs.h. */
2073_ACEOF
2074cat confdefs.h >>conftest.$ac_ext
2075cat >>conftest.$ac_ext <<_ACEOF
2076/* end confdefs.h. */
2077#include <ac_nonexistent.h>
2078_ACEOF
2079if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2080 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2081 ac_status=$?
2082 grep -v '^ *+' conftest.er1 >conftest.err
2083 rm -f conftest.er1
2084 cat conftest.err >&5
2085 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2086 (exit $ac_status); } >/dev/null; then
2087 if test -s conftest.err; then
2088 ac_cpp_err=$ac_c_preproc_warn_flag
2089 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
2090 else
2091 ac_cpp_err=
2092 fi
2093else
2094 ac_cpp_err=yes
2095fi
2096if test -z "$ac_cpp_err"; then
2097 # Broken: success on invalid input.
2098continue
2099else
2100 echo "$as_me: failed program was:" >&5
2101sed 's/^/| /' conftest.$ac_ext >&5
2102
2103 # Passes both tests.
2104ac_preproc_ok=:
2105break
2106fi
2107rm -f conftest.err conftest.$ac_ext
2108
2109done
2110# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2111rm -f conftest.err conftest.$ac_ext
2112if $ac_preproc_ok; then
2113 break
2114fi
2115
2116 done
2117 ac_cv_prog_CPP=$CPP
2118
2119fi
2120 CPP=$ac_cv_prog_CPP
2121else
2122 ac_cv_prog_CPP=$CPP
2123fi
2124echo "$as_me:$LINENO: result: $CPP" >&5
2125echo "${ECHO_T}$CPP" >&6
2126ac_preproc_ok=false
2127for ac_c_preproc_warn_flag in '' yes
2128do
2129 # Use a header file that comes with gcc, so configuring glibc
2130 # with a fresh cross-compiler works.
2131 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2132 # <limits.h> exists even on freestanding compilers.
2133 # On the NeXT, cc -E runs the code through the compiler's parser,
2134 # not just through cpp. "Syntax error" is here to catch this case.
2135 cat >conftest.$ac_ext <<_ACEOF
2136/* confdefs.h. */
2137_ACEOF
2138cat confdefs.h >>conftest.$ac_ext
2139cat >>conftest.$ac_ext <<_ACEOF
2140/* end confdefs.h. */
2141#ifdef __STDC__
2142# include <limits.h>
2143#else
2144# include <assert.h>
2145#endif
2146 Syntax error
2147_ACEOF
2148if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2149 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2150 ac_status=$?
2151 grep -v '^ *+' conftest.er1 >conftest.err
2152 rm -f conftest.er1
2153 cat conftest.err >&5
2154 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2155 (exit $ac_status); } >/dev/null; then
2156 if test -s conftest.err; then
2157 ac_cpp_err=$ac_c_preproc_warn_flag
2158 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
2159 else
2160 ac_cpp_err=
2161 fi
2162else
2163 ac_cpp_err=yes
2164fi
2165if test -z "$ac_cpp_err"; then
2166 :
2167else
2168 echo "$as_me: failed program was:" >&5
2169sed 's/^/| /' conftest.$ac_ext >&5
2170
2171 # Broken: fails on valid input.
2172continue
2173fi
2174rm -f conftest.err conftest.$ac_ext
2175
2176 # OK, works on sane cases. Now check whether non-existent headers
2177 # can be detected and how.
2178 cat >conftest.$ac_ext <<_ACEOF
2179/* confdefs.h. */
2180_ACEOF
2181cat confdefs.h >>conftest.$ac_ext
2182cat >>conftest.$ac_ext <<_ACEOF
2183/* end confdefs.h. */
2184#include <ac_nonexistent.h>
2185_ACEOF
2186if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2187 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2188 ac_status=$?
2189 grep -v '^ *+' conftest.er1 >conftest.err
2190 rm -f conftest.er1
2191 cat conftest.err >&5
2192 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2193 (exit $ac_status); } >/dev/null; then
2194 if test -s conftest.err; then
2195 ac_cpp_err=$ac_c_preproc_warn_flag
2196 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
2197 else
2198 ac_cpp_err=
2199 fi
2200else
2201 ac_cpp_err=yes
2202fi
2203if test -z "$ac_cpp_err"; then
2204 # Broken: success on invalid input.
2205continue
2206else
2207 echo "$as_me: failed program was:" >&5
2208sed 's/^/| /' conftest.$ac_ext >&5
2209
2210 # Passes both tests.
2211ac_preproc_ok=:
2212break
2213fi
2214rm -f conftest.err conftest.$ac_ext
2215
2216done
2217# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2218rm -f conftest.err conftest.$ac_ext
2219if $ac_preproc_ok; then
2220 :
2221else
2222 { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
2223See \`config.log' for more details." >&5
2224echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
2225See \`config.log' for more details." >&2;}
2226 { (exit 1); exit 1; }; }
2227fi
2228
2229ac_ext=c
2230ac_cpp='$CPP $CPPFLAGS'
2231ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2232ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2233ac_compiler_gnu=$ac_cv_c_compiler_gnu
2234
2235
2236echo "$as_me:$LINENO: checking for egrep" >&5
2237echo $ECHO_N "checking for egrep... $ECHO_C" >&6
2238if test "${ac_cv_prog_egrep+set}" = set; then
2239 echo $ECHO_N "(cached) $ECHO_C" >&6
2240else
2241 if echo a | (grep -E '(a|b)') >/dev/null 2>&1
2242 then ac_cv_prog_egrep='grep -E'
2243 else ac_cv_prog_egrep='egrep'
2244 fi
2245fi
2246echo "$as_me:$LINENO: result: $ac_cv_prog_egrep" >&5
2247echo "${ECHO_T}$ac_cv_prog_egrep" >&6
2248 EGREP=$ac_cv_prog_egrep
2249
2250
2251
82ba99d5
PE
2252 # Keep these sync'd with the list in Makefile.am. The first provides an
2253 # expandable list at autoconf time; the second provides an expandable list
2254 # (i.e., shell variable) at configure time.
2255
2256 SUBDIRS='include libmath libsupc++ src po testsuite'
2257
ff66d28f
PE
2258 # These need to be absolute paths, yet at the same time need to
2259 # canonicalize only relative paths, because then amd will not unmount
2260 # drives. Thus the use of PWDCMD: set it to 'pawd' or 'amq -w' if using amd.
2261 glibcxx_builddir=`${PWDCMD-pwd}`
2262 case $srcdir in
2263 \\/$* | ?:\\/*) glibcxx_srcdir=${srcdir} ;;
2264 *) glibcxx_srcdir=`cd "$srcdir" && ${PWDCMD-pwd} || echo "$srcdir"` ;;
2265 esac
2266 toplevel_srcdir=${glibcxx_srcdir}/..
2267
2268
2269
2270
2271 # We use these options to decide which functions to include. They are
2272 # set from the top level.
2273
2274# Check whether --with-target-subdir or --without-target-subdir was given.
2275if test "${with_target_subdir+set}" = set; then
2276 withval="$with_target_subdir"
2277
2278fi;
2279
2280
2281# Check whether --with-cross-host or --without-cross-host was given.
2282if test "${with_cross_host+set}" = set; then
2283 withval="$with_cross_host"
2284
2285fi;
2286
2287
2288# Check whether --with-newlib or --without-newlib was given.
2289if test "${with_newlib+set}" = set; then
2290 withval="$with_newlib"
2291
2292fi;
2293
f6dda651
PE
2294 # We're almost certainly being configured before anything else which uses
2295 # C++, so all of our AC_PROG_* discoveries will be cached. It's vital that
2296 # we not cache the value of CXX that we "discover" here, because it's set
2297 # to something unique for us and libjava. Other target libraries need to
2298 # find CXX for themselves. We yank the rug out from under the normal AC_*
2299 # process by sneakily renaming the cache variable. This also lets us debug
2300 # the value of "our" CXX in postmortems.
2301 #
2302 # We must also force CXX to /not/ be a precious variable, otherwise the
2303 # wrong (non-multilib-adjusted) value will be used in multilibs. This
2304 # little trick also affects CPPFLAGS, CXXFLAGS, and LDFLAGS. And as a side
2305 # effect, CXXFLAGS is no longer automagically subst'd, so we have to do
2306 # that ourselves. Un-preciousing AC_PROG_CC also affects CC and CFLAGS.
2307 #
2308 # -fno-builtin must be present here so that a non-conflicting form of
2309 # std::exit can be guessed by AC_PROG_CXX, and used in later tests.
2310
2311
2312
2313
2314 save_CXXFLAGS="$CXXFLAGS"
2315 CXXFLAGS="$CXXFLAGS -fno-builtin"
ff66d28f
PE
2316 ac_ext=c
2317ac_cpp='$CPP $CPPFLAGS'
2318ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2319ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2320ac_compiler_gnu=$ac_cv_c_compiler_gnu
2321if test -n "$ac_tool_prefix"; then
2322 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
2323set dummy ${ac_tool_prefix}gcc; ac_word=$2
2324echo "$as_me:$LINENO: checking for $ac_word" >&5
2325echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2326if test "${ac_cv_prog_CC+set}" = set; then
2327 echo $ECHO_N "(cached) $ECHO_C" >&6
b2dad0e3 2328else
ff66d28f
PE
2329 if test -n "$CC"; then
2330 ac_cv_prog_CC="$CC" # Let the user override the test.
b2dad0e3 2331else
ff66d28f
PE
2332as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2333for as_dir in $PATH
2334do
2335 IFS=$as_save_IFS
2336 test -z "$as_dir" && as_dir=.
2337 for ac_exec_ext in '' $ac_executable_extensions; do
2338 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2339 ac_cv_prog_CC="${ac_tool_prefix}gcc"
2340 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2341 break 2
2342 fi
2343done
2344done
2345
b2dad0e3
BK
2346fi
2347fi
ff66d28f
PE
2348CC=$ac_cv_prog_CC
2349if test -n "$CC"; then
2350 echo "$as_me:$LINENO: result: $CC" >&5
2351echo "${ECHO_T}$CC" >&6
b2dad0e3 2352else
ff66d28f
PE
2353 echo "$as_me:$LINENO: result: no" >&5
2354echo "${ECHO_T}no" >&6
b2dad0e3
BK
2355fi
2356
ff66d28f
PE
2357fi
2358if test -z "$ac_cv_prog_CC"; then
2359 ac_ct_CC=$CC
2360 # Extract the first word of "gcc", so it can be a program name with args.
2361set dummy gcc; ac_word=$2
2362echo "$as_me:$LINENO: checking for $ac_word" >&5
2363echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2364if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2365 echo $ECHO_N "(cached) $ECHO_C" >&6
b2dad0e3 2366else
ff66d28f
PE
2367 if test -n "$ac_ct_CC"; then
2368 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
b2dad0e3 2369else
ff66d28f
PE
2370as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2371for as_dir in $PATH
2372do
2373 IFS=$as_save_IFS
2374 test -z "$as_dir" && as_dir=.
2375 for ac_exec_ext in '' $ac_executable_extensions; do
2376 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2377 ac_cv_prog_ac_ct_CC="gcc"
2378 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2379 break 2
2380 fi
2381done
2382done
2383
b2dad0e3
BK
2384fi
2385fi
ff66d28f
PE
2386ac_ct_CC=$ac_cv_prog_ac_ct_CC
2387if test -n "$ac_ct_CC"; then
2388 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
2389echo "${ECHO_T}$ac_ct_CC" >&6
b2dad0e3 2390else
ff66d28f
PE
2391 echo "$as_me:$LINENO: result: no" >&5
2392echo "${ECHO_T}no" >&6
b2dad0e3 2393fi
b2dad0e3 2394
ff66d28f
PE
2395 CC=$ac_ct_CC
2396else
2397 CC="$ac_cv_prog_CC"
b2dad0e3
BK
2398fi
2399
ff66d28f
PE
2400if test -z "$CC"; then
2401 if test -n "$ac_tool_prefix"; then
2402 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
2403set dummy ${ac_tool_prefix}cc; ac_word=$2
2404echo "$as_me:$LINENO: checking for $ac_word" >&5
2405echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2406if test "${ac_cv_prog_CC+set}" = set; then
2407 echo $ECHO_N "(cached) $ECHO_C" >&6
2408else
2409 if test -n "$CC"; then
2410 ac_cv_prog_CC="$CC" # Let the user override the test.
2411else
2412as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2413for as_dir in $PATH
2414do
2415 IFS=$as_save_IFS
2416 test -z "$as_dir" && as_dir=.
2417 for ac_exec_ext in '' $ac_executable_extensions; do
2418 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2419 ac_cv_prog_CC="${ac_tool_prefix}cc"
2420 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2421 break 2
b2dad0e3 2422 fi
ff66d28f
PE
2423done
2424done
93b85586 2425
ff66d28f
PE
2426fi
2427fi
2428CC=$ac_cv_prog_CC
2429if test -n "$CC"; then
2430 echo "$as_me:$LINENO: result: $CC" >&5
2431echo "${ECHO_T}$CC" >&6
974e336b 2432else
ff66d28f
PE
2433 echo "$as_me:$LINENO: result: no" >&5
2434echo "${ECHO_T}no" >&6
2435fi
974e336b 2436
974e336b 2437fi
ff66d28f
PE
2438if test -z "$ac_cv_prog_CC"; then
2439 ac_ct_CC=$CC
2440 # Extract the first word of "cc", so it can be a program name with args.
2441set dummy cc; ac_word=$2
2442echo "$as_me:$LINENO: checking for $ac_word" >&5
2443echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2444if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2445 echo $ECHO_N "(cached) $ECHO_C" >&6
2446else
2447 if test -n "$ac_ct_CC"; then
2448 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2449else
2450as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2451for as_dir in $PATH
2452do
2453 IFS=$as_save_IFS
2454 test -z "$as_dir" && as_dir=.
2455 for ac_exec_ext in '' $ac_executable_extensions; do
2456 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2457 ac_cv_prog_ac_ct_CC="cc"
2458 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2459 break 2
2460 fi
2461done
2462done
33590f13 2463
974e336b 2464fi
ff66d28f
PE
2465fi
2466ac_ct_CC=$ac_cv_prog_ac_ct_CC
2467if test -n "$ac_ct_CC"; then
2468 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
2469echo "${ECHO_T}$ac_ct_CC" >&6
33590f13 2470else
ff66d28f
PE
2471 echo "$as_me:$LINENO: result: no" >&5
2472echo "${ECHO_T}no" >&6
33590f13
BK
2473fi
2474
ff66d28f
PE
2475 CC=$ac_ct_CC
2476else
2477 CC="$ac_cv_prog_CC"
2478fi
33590f13 2479
ff66d28f
PE
2480fi
2481if test -z "$CC"; then
2482 # Extract the first word of "cc", so it can be a program name with args.
2483set dummy cc; ac_word=$2
2484echo "$as_me:$LINENO: checking for $ac_word" >&5
2485echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2486if test "${ac_cv_prog_CC+set}" = set; then
2487 echo $ECHO_N "(cached) $ECHO_C" >&6
b2dad0e3 2488else
ff66d28f
PE
2489 if test -n "$CC"; then
2490 ac_cv_prog_CC="$CC" # Let the user override the test.
b2dad0e3 2491else
ff66d28f
PE
2492 ac_prog_rejected=no
2493as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2494for as_dir in $PATH
2495do
2496 IFS=$as_save_IFS
2497 test -z "$as_dir" && as_dir=.
2498 for ac_exec_ext in '' $ac_executable_extensions; do
2499 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2500 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
2501 ac_prog_rejected=yes
2502 continue
2503 fi
2504 ac_cv_prog_CC="cc"
2505 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2506 break 2
2507 fi
2508done
2509done
2510
2511if test $ac_prog_rejected = yes; then
2512 # We found a bogon in the path, so make sure we never use it.
2513 set dummy $ac_cv_prog_CC
2514 shift
2515 if test $# != 0; then
2516 # We chose a different compiler from the bogus one.
2517 # However, it has the same basename, so the bogon will be chosen
2518 # first if we set CC to just the basename; use the full file name.
2519 shift
2520 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
2521 fi
b2dad0e3
BK
2522fi
2523fi
ff66d28f
PE
2524fi
2525CC=$ac_cv_prog_CC
2526if test -n "$CC"; then
2527 echo "$as_me:$LINENO: result: $CC" >&5
2528echo "${ECHO_T}$CC" >&6
b2dad0e3 2529else
ff66d28f
PE
2530 echo "$as_me:$LINENO: result: no" >&5
2531echo "${ECHO_T}no" >&6
b2dad0e3
BK
2532fi
2533
ff66d28f
PE
2534fi
2535if test -z "$CC"; then
2536 if test -n "$ac_tool_prefix"; then
2537 for ac_prog in cl
2538 do
2539 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
2540set dummy $ac_tool_prefix$ac_prog; ac_word=$2
2541echo "$as_me:$LINENO: checking for $ac_word" >&5
2542echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2543if test "${ac_cv_prog_CC+set}" = set; then
2544 echo $ECHO_N "(cached) $ECHO_C" >&6
b2dad0e3 2545else
ff66d28f
PE
2546 if test -n "$CC"; then
2547 ac_cv_prog_CC="$CC" # Let the user override the test.
b2dad0e3 2548else
ff66d28f
PE
2549as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2550for as_dir in $PATH
2551do
2552 IFS=$as_save_IFS
2553 test -z "$as_dir" && as_dir=.
2554 for ac_exec_ext in '' $ac_executable_extensions; do
2555 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2556 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
2557 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2558 break 2
2559 fi
2560done
2561done
2562
b2dad0e3
BK
2563fi
2564fi
ff66d28f
PE
2565CC=$ac_cv_prog_CC
2566if test -n "$CC"; then
2567 echo "$as_me:$LINENO: result: $CC" >&5
2568echo "${ECHO_T}$CC" >&6
b2dad0e3 2569else
ff66d28f
PE
2570 echo "$as_me:$LINENO: result: no" >&5
2571echo "${ECHO_T}no" >&6
b2dad0e3
BK
2572fi
2573
ff66d28f
PE
2574 test -n "$CC" && break
2575 done
2576fi
2577if test -z "$CC"; then
2578 ac_ct_CC=$CC
2579 for ac_prog in cl
2580do
2581 # Extract the first word of "$ac_prog", so it can be a program name with args.
2582set dummy $ac_prog; ac_word=$2
2583echo "$as_me:$LINENO: checking for $ac_word" >&5
2584echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2585if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2586 echo $ECHO_N "(cached) $ECHO_C" >&6
b2dad0e3 2587else
ff66d28f
PE
2588 if test -n "$ac_ct_CC"; then
2589 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
b2dad0e3 2590else
ff66d28f
PE
2591as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2592for as_dir in $PATH
2593do
2594 IFS=$as_save_IFS
2595 test -z "$as_dir" && as_dir=.
2596 for ac_exec_ext in '' $ac_executable_extensions; do
2597 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2598 ac_cv_prog_ac_ct_CC="$ac_prog"
2599 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2600 break 2
2601 fi
2602done
2603done
2604
b2dad0e3
BK
2605fi
2606fi
ff66d28f
PE
2607ac_ct_CC=$ac_cv_prog_ac_ct_CC
2608if test -n "$ac_ct_CC"; then
2609 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
2610echo "${ECHO_T}$ac_ct_CC" >&6
b2dad0e3 2611else
ff66d28f
PE
2612 echo "$as_me:$LINENO: result: no" >&5
2613echo "${ECHO_T}no" >&6
b2dad0e3
BK
2614fi
2615
ff66d28f
PE
2616 test -n "$ac_ct_CC" && break
2617done
b2dad0e3 2618
ff66d28f
PE
2619 CC=$ac_ct_CC
2620fi
2621
2622fi
2623
2624
2625test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
2626See \`config.log' for more details." >&5
2627echo "$as_me: error: no acceptable C compiler found in \$PATH
2628See \`config.log' for more details." >&2;}
2629 { (exit 1); exit 1; }; }
2630
2631# Provide some information about the compiler.
2632echo "$as_me:$LINENO:" \
2633 "checking for C compiler version" >&5
2634ac_compiler=`set X $ac_compile; echo $2`
2635{ (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
2636 (eval $ac_compiler --version </dev/null >&5) 2>&5
2637 ac_status=$?
2638 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2639 (exit $ac_status); }
2640{ (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
2641 (eval $ac_compiler -v </dev/null >&5) 2>&5
2642 ac_status=$?
2643 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2644 (exit $ac_status); }
2645{ (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
2646 (eval $ac_compiler -V </dev/null >&5) 2>&5
2647 ac_status=$?
2648 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2649 (exit $ac_status); }
2650
2651cat >conftest.$ac_ext <<_ACEOF
ff66d28f
PE
2652/* confdefs.h. */
2653_ACEOF
2654cat confdefs.h >>conftest.$ac_ext
2655cat >>conftest.$ac_ext <<_ACEOF
2656/* end confdefs.h. */
2657
3a24bf5d
KC
2658int
2659main ()
2660{
2661
2662 ;
2663 return 0;
2664}
2665_ACEOF
2666# FIXME: Cleanup?
2667if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
2668 (eval $ac_link) 2>&5
2669 ac_status=$?
2670 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2671 (exit $ac_status); }; then
2672 gcc_no_link=no
2673else
2674 gcc_no_link=yes
2675fi
2676
2677if test x$gcc_no_link = xyes; then
2678 # Setting cross_compile will disable run tests; it will
2679 # also disable AC_CHECK_FILE but that's generally
2680 # correct if we can't link.
2681 cross_compiling=yes
2682 EXEEXT=
2683else
2684 cat >conftest.$ac_ext <<_ACEOF
2685/* confdefs.h. */
2686_ACEOF
2687cat confdefs.h >>conftest.$ac_ext
2688cat >>conftest.$ac_ext <<_ACEOF
2689/* end confdefs.h. */
2690
ff66d28f
PE
2691int
2692main ()
2693{
2694
2695 ;
2696 return 0;
2697}
2698_ACEOF
2699ac_clean_files_save=$ac_clean_files
2700ac_clean_files="$ac_clean_files a.out a.exe b.out"
2701# Try to create an executable without -o first, disregard a.out.
2702# It will help us diagnose broken compilers, and finding out an intuition
2703# of exeext.
ec2075e9
BK
2704echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
2705echo $ECHO_N "checking for C compiler default output file name... $ECHO_C" >&6
ff66d28f
PE
2706ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
2707if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
2708 (eval $ac_link_default) 2>&5
2709 ac_status=$?
2710 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2711 (exit $ac_status); }; then
2712 # Find the output, starting from the most likely. This scheme is
2713# not robust to junk in `.', hence go to wildcards (a.*) only as a last
2714# resort.
2715
2716# Be careful to initialize this variable, since it used to be cached.
2717# Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
2718ac_cv_exeext=
2719# b.out is created by i960 compilers.
2720for ac_file in a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out
2721do
2722 test -f "$ac_file" || continue
2723 case $ac_file in
2724 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj )
ec2075e9 2725 ;;
ff66d28f 2726 conftest.$ac_ext )
ec2075e9
BK
2727 # This is the source file.
2728 ;;
ff66d28f 2729 [ab].out )
ec2075e9
BK
2730 # We found the default executable, but exeext='' is most
2731 # certainly right.
2732 break;;
ff66d28f 2733 *.* )
ec2075e9
BK
2734 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
2735 # FIXME: I believe we export ac_cv_exeext for Libtool,
2736 # but it would be cool to find out if it's true. Does anybody
2737 # maintain Libtool? --akim.
2738 export ac_cv_exeext
2739 break;;
ff66d28f 2740 * )
ec2075e9 2741 break;;
ff66d28f
PE
2742 esac
2743done
b2dad0e3 2744else
ff66d28f
PE
2745 echo "$as_me: failed program was:" >&5
2746sed 's/^/| /' conftest.$ac_ext >&5
2747
2748{ { echo "$as_me:$LINENO: error: C compiler cannot create executables
2749See \`config.log' for more details." >&5
2750echo "$as_me: error: C compiler cannot create executables
2751See \`config.log' for more details." >&2;}
2752 { (exit 77); exit 77; }; }
2753fi
2754
2755ac_exeext=$ac_cv_exeext
2756echo "$as_me:$LINENO: result: $ac_file" >&5
2757echo "${ECHO_T}$ac_file" >&6
2758
2759# Check the compiler produces executables we can run. If not, either
2760# the compiler is broken, or we cross compile.
2761echo "$as_me:$LINENO: checking whether the C compiler works" >&5
2762echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
2763# FIXME: These cross compiler hacks should be removed for Autoconf 3.0
2764# If not cross compiling, check that we can run a simple program.
2765if test "$cross_compiling" != yes; then
2766 if { ac_try='./$ac_file'
2767 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2768 (eval $ac_try) 2>&5
2769 ac_status=$?
2770 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2771 (exit $ac_status); }; }; then
2772 cross_compiling=no
2773 else
2774 if test "$cross_compiling" = maybe; then
2775 cross_compiling=yes
2776 else
2777 { { echo "$as_me:$LINENO: error: cannot run C compiled programs.
2778If you meant to cross compile, use \`--host'.
2779See \`config.log' for more details." >&5
2780echo "$as_me: error: cannot run C compiled programs.
2781If you meant to cross compile, use \`--host'.
2782See \`config.log' for more details." >&2;}
2783 { (exit 1); exit 1; }; }
b2dad0e3 2784 fi
ff66d28f 2785 fi
b2dad0e3 2786fi
ff66d28f
PE
2787echo "$as_me:$LINENO: result: yes" >&5
2788echo "${ECHO_T}yes" >&6
2789
2790rm -f a.out a.exe conftest$ac_cv_exeext b.out
2791ac_clean_files=$ac_clean_files_save
2792# Check the compiler produces executables we can run. If not, either
2793# the compiler is broken, or we cross compile.
2794echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
2795echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
2796echo "$as_me:$LINENO: result: $cross_compiling" >&5
2797echo "${ECHO_T}$cross_compiling" >&6
2798
2799echo "$as_me:$LINENO: checking for suffix of executables" >&5
2800echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6
2801if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
2802 (eval $ac_link) 2>&5
2803 ac_status=$?
2804 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2805 (exit $ac_status); }; then
2806 # If both `conftest.exe' and `conftest' are `present' (well, observable)
2807# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
2808# work properly (i.e., refer to `conftest.exe'), while it won't with
2809# `rm'.
2810for ac_file in conftest.exe conftest conftest.*; do
2811 test -f "$ac_file" || continue
2812 case $ac_file in
2813 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj ) ;;
2814 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
ec2075e9
BK
2815 export ac_cv_exeext
2816 break;;
ff66d28f
PE
2817 * ) break;;
2818 esac
2819done
b2dad0e3 2820else
ff66d28f
PE
2821 { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
2822See \`config.log' for more details." >&5
2823echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
2824See \`config.log' for more details." >&2;}
2825 { (exit 1); exit 1; }; }
b2dad0e3
BK
2826fi
2827
ff66d28f
PE
2828rm -f conftest$ac_cv_exeext
2829echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
2830echo "${ECHO_T}$ac_cv_exeext" >&6
2831
2832rm -f conftest.$ac_ext
2833EXEEXT=$ac_cv_exeext
2834ac_exeext=$EXEEXT
3a24bf5d 2835fi
ff66d28f
PE
2836echo "$as_me:$LINENO: checking for suffix of object files" >&5
2837echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6
2838if test "${ac_cv_objext+set}" = set; then
2839 echo $ECHO_N "(cached) $ECHO_C" >&6
2840else
2841 cat >conftest.$ac_ext <<_ACEOF
ff66d28f
PE
2842/* confdefs.h. */
2843_ACEOF
2844cat confdefs.h >>conftest.$ac_ext
2845cat >>conftest.$ac_ext <<_ACEOF
2846/* end confdefs.h. */
2847
2848int
2849main ()
2850{
2851
2852 ;
2853 return 0;
2854}
2855_ACEOF
2856rm -f conftest.o conftest.obj
2857if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2858 (eval $ac_compile) 2>&5
2859 ac_status=$?
2860 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2861 (exit $ac_status); }; then
2862 for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
2863 case $ac_file in
2864 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg ) ;;
2865 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
2866 break;;
2867 esac
2868done
b2dad0e3 2869else
ff66d28f
PE
2870 echo "$as_me: failed program was:" >&5
2871sed 's/^/| /' conftest.$ac_ext >&5
2872
2873{ { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
2874See \`config.log' for more details." >&5
2875echo "$as_me: error: cannot compute suffix of object files: cannot compile
2876See \`config.log' for more details." >&2;}
2877 { (exit 1); exit 1; }; }
46840bcd 2878fi
ff66d28f
PE
2879
2880rm -f conftest.$ac_cv_objext conftest.$ac_ext
46840bcd 2881fi
ff66d28f
PE
2882echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
2883echo "${ECHO_T}$ac_cv_objext" >&6
2884OBJEXT=$ac_cv_objext
2885ac_objext=$OBJEXT
2886echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
2887echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
2888if test "${ac_cv_c_compiler_gnu+set}" = set; then
2889 echo $ECHO_N "(cached) $ECHO_C" >&6
2890else
2891 cat >conftest.$ac_ext <<_ACEOF
ff66d28f
PE
2892/* confdefs.h. */
2893_ACEOF
2894cat confdefs.h >>conftest.$ac_ext
2895cat >>conftest.$ac_ext <<_ACEOF
2896/* end confdefs.h. */
46840bcd 2897
ff66d28f
PE
2898int
2899main ()
2900{
2901#ifndef __GNUC__
2902 choke me
2903#endif
2904
2905 ;
2906 return 0;
2907}
2908_ACEOF
2909rm -f conftest.$ac_objext
2910if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
ec2075e9 2911 (eval $ac_compile) 2>conftest.er1
ff66d28f 2912 ac_status=$?
ec2075e9
BK
2913 grep -v '^ *+' conftest.er1 >conftest.err
2914 rm -f conftest.er1
2915 cat conftest.err >&5
ff66d28f
PE
2916 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2917 (exit $ac_status); } &&
5b043f08
GK
2918 { ac_try='test -z "$ac_c_werror_flag"
2919 || test ! -s conftest.err'
ec2075e9
BK
2920 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2921 (eval $ac_try) 2>&5
2922 ac_status=$?
2923 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2924 (exit $ac_status); }; } &&
2925 { ac_try='test -s conftest.$ac_objext'
ff66d28f
PE
2926 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2927 (eval $ac_try) 2>&5
2928 ac_status=$?
2929 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2930 (exit $ac_status); }; }; then
2931 ac_compiler_gnu=yes
2932else
2933 echo "$as_me: failed program was:" >&5
2934sed 's/^/| /' conftest.$ac_ext >&5
2935
2936ac_compiler_gnu=no
2937fi
ec2075e9 2938rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ff66d28f
PE
2939ac_cv_c_compiler_gnu=$ac_compiler_gnu
2940
2941fi
2942echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
2943echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
2944GCC=`test $ac_compiler_gnu = yes && echo yes`
2945ac_test_CFLAGS=${CFLAGS+set}
2946ac_save_CFLAGS=$CFLAGS
2947CFLAGS="-g"
2948echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
2949echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
2950if test "${ac_cv_prog_cc_g+set}" = set; then
2951 echo $ECHO_N "(cached) $ECHO_C" >&6
2952else
2953 cat >conftest.$ac_ext <<_ACEOF
ff66d28f
PE
2954/* confdefs.h. */
2955_ACEOF
2956cat confdefs.h >>conftest.$ac_ext
2957cat >>conftest.$ac_ext <<_ACEOF
2958/* end confdefs.h. */
2959
2960int
2961main ()
2962{
2963
2964 ;
2965 return 0;
2966}
2967_ACEOF
2968rm -f conftest.$ac_objext
2969if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
ec2075e9 2970 (eval $ac_compile) 2>conftest.er1
ff66d28f 2971 ac_status=$?
ec2075e9
BK
2972 grep -v '^ *+' conftest.er1 >conftest.err
2973 rm -f conftest.er1
2974 cat conftest.err >&5
ff66d28f
PE
2975 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2976 (exit $ac_status); } &&
5b043f08
GK
2977 { ac_try='test -z "$ac_c_werror_flag"
2978 || test ! -s conftest.err'
ec2075e9
BK
2979 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2980 (eval $ac_try) 2>&5
2981 ac_status=$?
2982 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2983 (exit $ac_status); }; } &&
2984 { ac_try='test -s conftest.$ac_objext'
ff66d28f
PE
2985 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2986 (eval $ac_try) 2>&5
2987 ac_status=$?
2988 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2989 (exit $ac_status); }; }; then
2990 ac_cv_prog_cc_g=yes
b2dad0e3 2991else
ff66d28f
PE
2992 echo "$as_me: failed program was:" >&5
2993sed 's/^/| /' conftest.$ac_ext >&5
b2dad0e3 2994
ff66d28f 2995ac_cv_prog_cc_g=no
b2dad0e3 2996fi
ec2075e9 2997rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ff66d28f
PE
2998fi
2999echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
3000echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
3001if test "$ac_test_CFLAGS" = set; then
3002 CFLAGS=$ac_save_CFLAGS
3003elif test $ac_cv_prog_cc_g = yes; then
3004 if test "$GCC" = yes; then
3005 CFLAGS="-g -O2"
b2dad0e3 3006 else
ff66d28f 3007 CFLAGS="-g"
b2dad0e3 3008 fi
ff66d28f
PE
3009else
3010 if test "$GCC" = yes; then
3011 CFLAGS="-O2"
3012 else
3013 CFLAGS=
3014 fi
3015fi
3016echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
3017echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
3018if test "${ac_cv_prog_cc_stdc+set}" = set; then
3019 echo $ECHO_N "(cached) $ECHO_C" >&6
3020else
3021 ac_cv_prog_cc_stdc=no
3022ac_save_CC=$CC
3023cat >conftest.$ac_ext <<_ACEOF
ff66d28f
PE
3024/* confdefs.h. */
3025_ACEOF
3026cat confdefs.h >>conftest.$ac_ext
3027cat >>conftest.$ac_ext <<_ACEOF
3028/* end confdefs.h. */
3029#include <stdarg.h>
3030#include <stdio.h>
3031#include <sys/types.h>
3032#include <sys/stat.h>
3033/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
3034struct buf { int x; };
3035FILE * (*rcsopen) (struct buf *, struct stat *, int);
3036static char *e (p, i)
3037 char **p;
3038 int i;
3039{
3040 return p[i];
3041}
3042static char *f (char * (*g) (char **, int), char **p, ...)
3043{
3044 char *s;
3045 va_list v;
3046 va_start (v,p);
3047 s = g (p, va_arg (v,int));
3048 va_end (v);
3049 return s;
3050}
ec2075e9
BK
3051
3052/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
3053 function prototypes and stuff, but not '\xHH' hex character constants.
3054 These don't provoke an error unfortunately, instead are silently treated
3055 as 'x'. The following induces an error, until -std1 is added to get
3056 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
3057 array size at least. It's necessary to write '\x00'==0 to get something
3058 that's true only with -std1. */
3059int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3060
ff66d28f
PE
3061int test (int i, double x);
3062struct s1 {int (*f) (int a);};
3063struct s2 {int (*f) (double a);};
3064int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3065int argc;
3066char **argv;
3067int
3068main ()
3069{
3070return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
3071 ;
3072 return 0;
3073}
3074_ACEOF
3075# Don't try gcc -ansi; that turns off useful extensions and
3076# breaks some systems' header files.
3077# AIX -qlanglvl=ansi
3078# Ultrix and OSF/1 -std1
3079# HP-UX 10.20 and later -Ae
3080# HP-UX older versions -Aa -D_HPUX_SOURCE
3081# SVR4 -Xc -D__EXTENSIONS__
3082for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3083do
3084 CC="$ac_save_CC $ac_arg"
3085 rm -f conftest.$ac_objext
3086if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
ec2075e9 3087 (eval $ac_compile) 2>conftest.er1
ff66d28f 3088 ac_status=$?
ec2075e9
BK
3089 grep -v '^ *+' conftest.er1 >conftest.err
3090 rm -f conftest.er1
3091 cat conftest.err >&5
ff66d28f
PE
3092 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3093 (exit $ac_status); } &&
5b043f08
GK
3094 { ac_try='test -z "$ac_c_werror_flag"
3095 || test ! -s conftest.err'
ec2075e9
BK
3096 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3097 (eval $ac_try) 2>&5
3098 ac_status=$?
3099 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3100 (exit $ac_status); }; } &&
3101 { ac_try='test -s conftest.$ac_objext'
ff66d28f
PE
3102 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3103 (eval $ac_try) 2>&5
3104 ac_status=$?
3105 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3106 (exit $ac_status); }; }; then
3107 ac_cv_prog_cc_stdc=$ac_arg
3108break
3109else
3110 echo "$as_me: failed program was:" >&5
3111sed 's/^/| /' conftest.$ac_ext >&5
3112
b2dad0e3 3113fi
ec2075e9 3114rm -f conftest.err conftest.$ac_objext
ff66d28f
PE
3115done
3116rm -f conftest.$ac_ext conftest.$ac_objext
3117CC=$ac_save_CC
b2dad0e3 3118
ff66d28f 3119fi
b2dad0e3 3120
ff66d28f
PE
3121case "x$ac_cv_prog_cc_stdc" in
3122 x|xno)
3123 echo "$as_me:$LINENO: result: none needed" >&5
3124echo "${ECHO_T}none needed" >&6 ;;
3125 *)
3126 echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
3127echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
3128 CC="$CC $ac_cv_prog_cc_stdc" ;;
3129esac
b2dad0e3 3130
ff66d28f
PE
3131# Some people use a C++ compiler to compile C. Since we use `exit',
3132# in C++ we need to declare it. In case someone uses the same compiler
3133# for both compiling C and C++ we need to have the C++ compiler decide
3134# the declaration of exit, since it's the most demanding environment.
3135cat >conftest.$ac_ext <<_ACEOF
3136#ifndef __cplusplus
3137 choke me
3138#endif
3139_ACEOF
3140rm -f conftest.$ac_objext
3141if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
ec2075e9 3142 (eval $ac_compile) 2>conftest.er1
ff66d28f 3143 ac_status=$?
ec2075e9
BK
3144 grep -v '^ *+' conftest.er1 >conftest.err
3145 rm -f conftest.er1
3146 cat conftest.err >&5
ff66d28f
PE
3147 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3148 (exit $ac_status); } &&
5b043f08
GK
3149 { ac_try='test -z "$ac_c_werror_flag"
3150 || test ! -s conftest.err'
ec2075e9
BK
3151 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3152 (eval $ac_try) 2>&5
3153 ac_status=$?
3154 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3155 (exit $ac_status); }; } &&
3156 { ac_try='test -s conftest.$ac_objext'
ff66d28f
PE
3157 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3158 (eval $ac_try) 2>&5
3159 ac_status=$?
3160 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3161 (exit $ac_status); }; }; then
3162 for ac_declaration in \
ec2075e9 3163 '' \
ff66d28f
PE
3164 'extern "C" void std::exit (int) throw (); using std::exit;' \
3165 'extern "C" void std::exit (int); using std::exit;' \
3166 'extern "C" void exit (int) throw ();' \
3167 'extern "C" void exit (int);' \
3168 'void exit (int);'
3169do
3170 cat >conftest.$ac_ext <<_ACEOF
ff66d28f
PE
3171/* confdefs.h. */
3172_ACEOF
3173cat confdefs.h >>conftest.$ac_ext
3174cat >>conftest.$ac_ext <<_ACEOF
3175/* end confdefs.h. */
158960ba 3176$ac_declaration
ec2075e9 3177#include <stdlib.h>
ff66d28f
PE
3178int
3179main ()
3180{
3181exit (42);
3182 ;
3183 return 0;
3184}
3185_ACEOF
3186rm -f conftest.$ac_objext
3187if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
ec2075e9 3188 (eval $ac_compile) 2>conftest.er1
ff66d28f 3189 ac_status=$?
ec2075e9
BK
3190 grep -v '^ *+' conftest.er1 >conftest.err
3191 rm -f conftest.er1
3192 cat conftest.err >&5
ff66d28f
PE
3193 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3194 (exit $ac_status); } &&
5b043f08
GK
3195 { ac_try='test -z "$ac_c_werror_flag"
3196 || test ! -s conftest.err'
ec2075e9
BK
3197 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3198 (eval $ac_try) 2>&5
3199 ac_status=$?
3200 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3201 (exit $ac_status); }; } &&
3202 { ac_try='test -s conftest.$ac_objext'
ff66d28f
PE
3203 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3204 (eval $ac_try) 2>&5
3205 ac_status=$?
3206 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3207 (exit $ac_status); }; }; then
3208 :
3209else
3210 echo "$as_me: failed program was:" >&5
3211sed 's/^/| /' conftest.$ac_ext >&5
b2dad0e3 3212
ff66d28f
PE
3213continue
3214fi
ec2075e9 3215rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ff66d28f 3216 cat >conftest.$ac_ext <<_ACEOF
ff66d28f
PE
3217/* confdefs.h. */
3218_ACEOF
3219cat confdefs.h >>conftest.$ac_ext
3220cat >>conftest.$ac_ext <<_ACEOF
3221/* end confdefs.h. */
3222$ac_declaration
3223int
3224main ()
3225{
3226exit (42);
3227 ;
3228 return 0;
3229}
3230_ACEOF
3231rm -f conftest.$ac_objext
3232if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
ec2075e9 3233 (eval $ac_compile) 2>conftest.er1
ff66d28f 3234 ac_status=$?
ec2075e9
BK
3235 grep -v '^ *+' conftest.er1 >conftest.err
3236 rm -f conftest.er1
3237 cat conftest.err >&5
ff66d28f
PE
3238 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3239 (exit $ac_status); } &&
5b043f08
GK
3240 { ac_try='test -z "$ac_c_werror_flag"
3241 || test ! -s conftest.err'
ec2075e9
BK
3242 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3243 (eval $ac_try) 2>&5
3244 ac_status=$?
3245 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3246 (exit $ac_status); }; } &&
3247 { ac_try='test -s conftest.$ac_objext'
ff66d28f
PE
3248 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3249 (eval $ac_try) 2>&5
3250 ac_status=$?
3251 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3252 (exit $ac_status); }; }; then
3253 break
3254else
3255 echo "$as_me: failed program was:" >&5
3256sed 's/^/| /' conftest.$ac_ext >&5
3257
3258fi
ec2075e9 3259rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ff66d28f
PE
3260done
3261rm -f conftest*
3262if test -n "$ac_declaration"; then
3263 echo '#ifdef __cplusplus' >>confdefs.h
3264 echo $ac_declaration >>confdefs.h
3265 echo '#endif' >>confdefs.h
3266fi
b2dad0e3 3267
b2dad0e3 3268else
ff66d28f
PE
3269 echo "$as_me: failed program was:" >&5
3270sed 's/^/| /' conftest.$ac_ext >&5
3271
b2dad0e3 3272fi
ec2075e9 3273rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ff66d28f
PE
3274ac_ext=c
3275ac_cpp='$CPP $CPPFLAGS'
3276ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3277ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3278ac_compiler_gnu=$ac_cv_c_compiler_gnu
3279
ff66d28f
PE
3280 ac_ext=cc
3281ac_cpp='$CXXCPP $CPPFLAGS'
3282ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3283ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3284ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
3285if test -n "$ac_tool_prefix"; then
3286 for ac_prog in $CCC g++ c++ gpp aCC CC cxx cc++ cl FCC KCC RCC xlC_r xlC
3287 do
3288 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3289set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3290echo "$as_me:$LINENO: checking for $ac_word" >&5
3291echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3292if test "${glibcxx_cv_prog_CXX+set}" = set; then
3293 echo $ECHO_N "(cached) $ECHO_C" >&6
3294else
3295 if test -n "$CXX"; then
3296 glibcxx_cv_prog_CXX="$CXX" # Let the user override the test.
3297else
3298as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3299for as_dir in $PATH
3300do
3301 IFS=$as_save_IFS
3302 test -z "$as_dir" && as_dir=.
3303 for ac_exec_ext in '' $ac_executable_extensions; do
3304 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3305 glibcxx_cv_prog_CXX="$ac_tool_prefix$ac_prog"
3306 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3307 break 2
3308 fi
3309done
3310done
3311
3312fi
3313fi
3314CXX=$glibcxx_cv_prog_CXX
3315if test -n "$CXX"; then
3316 echo "$as_me:$LINENO: result: $CXX" >&5
3317echo "${ECHO_T}$CXX" >&6
b2dad0e3 3318else
ff66d28f
PE
3319 echo "$as_me:$LINENO: result: no" >&5
3320echo "${ECHO_T}no" >&6
b2dad0e3 3321fi
b2dad0e3 3322
ff66d28f
PE
3323 test -n "$CXX" && break
3324 done
3325fi
3326if test -z "$CXX"; then
3327 ac_ct_CXX=$CXX
3328 for ac_prog in $CCC g++ c++ gpp aCC CC cxx cc++ cl FCC KCC RCC xlC_r xlC
3329do
3330 # Extract the first word of "$ac_prog", so it can be a program name with args.
3331set dummy $ac_prog; ac_word=$2
3332echo "$as_me:$LINENO: checking for $ac_word" >&5
3333echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3334if test "${ac_cv_prog_ac_ct_CXX+set}" = set; then
3335 echo $ECHO_N "(cached) $ECHO_C" >&6
3336else
3337 if test -n "$ac_ct_CXX"; then
3338 ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
3339else
3340as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3341for as_dir in $PATH
3342do
3343 IFS=$as_save_IFS
3344 test -z "$as_dir" && as_dir=.
3345 for ac_exec_ext in '' $ac_executable_extensions; do
3346 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3347 ac_cv_prog_ac_ct_CXX="$ac_prog"
3348 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3349 break 2
b2dad0e3 3350 fi
ff66d28f
PE
3351done
3352done
3353
b2dad0e3 3354fi
ff66d28f
PE
3355fi
3356ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
3357if test -n "$ac_ct_CXX"; then
3358 echo "$as_me:$LINENO: result: $ac_ct_CXX" >&5
3359echo "${ECHO_T}$ac_ct_CXX" >&6
3360else
3361 echo "$as_me:$LINENO: result: no" >&5
3362echo "${ECHO_T}no" >&6
b2dad0e3
BK
3363fi
3364
ff66d28f
PE
3365 test -n "$ac_ct_CXX" && break
3366done
3367test -n "$ac_ct_CXX" || ac_ct_CXX="g++"
3368
3369 CXX=$ac_ct_CXX
3370fi
3371
3372
3373# Provide some information about the compiler.
3374echo "$as_me:$LINENO:" \
3375 "checking for C++ compiler version" >&5
3376ac_compiler=`set X $ac_compile; echo $2`
3377{ (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
3378 (eval $ac_compiler --version </dev/null >&5) 2>&5
3379 ac_status=$?
3380 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3381 (exit $ac_status); }
3382{ (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
3383 (eval $ac_compiler -v </dev/null >&5) 2>&5
3384 ac_status=$?
3385 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3386 (exit $ac_status); }
3387{ (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
3388 (eval $ac_compiler -V </dev/null >&5) 2>&5
3389 ac_status=$?
3390 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3391 (exit $ac_status); }
3392
3393echo "$as_me:$LINENO: checking whether we are using the GNU C++ compiler" >&5
3394echo $ECHO_N "checking whether we are using the GNU C++ compiler... $ECHO_C" >&6
3395if test "${ac_cv_cxx_compiler_gnu+set}" = set; then
3396 echo $ECHO_N "(cached) $ECHO_C" >&6
3397else
3398 cat >conftest.$ac_ext <<_ACEOF
ff66d28f
PE
3399/* confdefs.h. */
3400_ACEOF
3401cat confdefs.h >>conftest.$ac_ext
3402cat >>conftest.$ac_ext <<_ACEOF
3403/* end confdefs.h. */
3404
3405int
3406main ()
3407{
3408#ifndef __GNUC__
3409 choke me
3410#endif
3411
3412 ;
3413 return 0;
3414}
3415_ACEOF
3416rm -f conftest.$ac_objext
3417if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
ec2075e9 3418 (eval $ac_compile) 2>conftest.er1
ff66d28f 3419 ac_status=$?
ec2075e9
BK
3420 grep -v '^ *+' conftest.er1 >conftest.err
3421 rm -f conftest.er1
3422 cat conftest.err >&5
ff66d28f
PE
3423 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3424 (exit $ac_status); } &&
5b043f08
GK
3425 { ac_try='test -z "$ac_cxx_werror_flag"
3426 || test ! -s conftest.err'
ec2075e9
BK
3427 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3428 (eval $ac_try) 2>&5
3429 ac_status=$?
3430 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3431 (exit $ac_status); }; } &&
3432 { ac_try='test -s conftest.$ac_objext'
ff66d28f
PE
3433 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3434 (eval $ac_try) 2>&5
3435 ac_status=$?
3436 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3437 (exit $ac_status); }; }; then
3438 ac_compiler_gnu=yes
3439else
3440 echo "$as_me: failed program was:" >&5
3441sed 's/^/| /' conftest.$ac_ext >&5
3442
3443ac_compiler_gnu=no
3444fi
ec2075e9 3445rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ff66d28f
PE
3446ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
3447
3448fi
3449echo "$as_me:$LINENO: result: $ac_cv_cxx_compiler_gnu" >&5
3450echo "${ECHO_T}$ac_cv_cxx_compiler_gnu" >&6
3451GXX=`test $ac_compiler_gnu = yes && echo yes`
3452ac_test_CXXFLAGS=${CXXFLAGS+set}
3453ac_save_CXXFLAGS=$CXXFLAGS
3454CXXFLAGS="-g"
3455echo "$as_me:$LINENO: checking whether $CXX accepts -g" >&5
3456echo $ECHO_N "checking whether $CXX accepts -g... $ECHO_C" >&6
3457if test "${ac_cv_prog_cxx_g+set}" = set; then
3458 echo $ECHO_N "(cached) $ECHO_C" >&6
3459else
3460 cat >conftest.$ac_ext <<_ACEOF
ff66d28f
PE
3461/* confdefs.h. */
3462_ACEOF
3463cat confdefs.h >>conftest.$ac_ext
3464cat >>conftest.$ac_ext <<_ACEOF
3465/* end confdefs.h. */
3466
3467int
3468main ()
3469{
b2dad0e3 3470
ff66d28f
PE
3471 ;
3472 return 0;
3473}
3474_ACEOF
3475rm -f conftest.$ac_objext
3476if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
ec2075e9 3477 (eval $ac_compile) 2>conftest.er1
ff66d28f 3478 ac_status=$?
ec2075e9
BK
3479 grep -v '^ *+' conftest.er1 >conftest.err
3480 rm -f conftest.er1
3481 cat conftest.err >&5
ff66d28f
PE
3482 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3483 (exit $ac_status); } &&
5b043f08
GK
3484 { ac_try='test -z "$ac_cxx_werror_flag"
3485 || test ! -s conftest.err'
ec2075e9
BK
3486 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3487 (eval $ac_try) 2>&5
3488 ac_status=$?
3489 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3490 (exit $ac_status); }; } &&
3491 { ac_try='test -s conftest.$ac_objext'
ff66d28f
PE
3492 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3493 (eval $ac_try) 2>&5
3494 ac_status=$?
3495 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3496 (exit $ac_status); }; }; then
3497 ac_cv_prog_cxx_g=yes
3498else
3499 echo "$as_me: failed program was:" >&5
3500sed 's/^/| /' conftest.$ac_ext >&5
3501
3502ac_cv_prog_cxx_g=no
3503fi
ec2075e9 3504rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ff66d28f
PE
3505fi
3506echo "$as_me:$LINENO: result: $ac_cv_prog_cxx_g" >&5
3507echo "${ECHO_T}$ac_cv_prog_cxx_g" >&6
3508if test "$ac_test_CXXFLAGS" = set; then
3509 CXXFLAGS=$ac_save_CXXFLAGS
3510elif test $ac_cv_prog_cxx_g = yes; then
3511 if test "$GXX" = yes; then
3512 CXXFLAGS="-g -O2"
3513 else
3514 CXXFLAGS="-g"
3515 fi
3516else
3517 if test "$GXX" = yes; then
3518 CXXFLAGS="-O2"
3519 else
3520 CXXFLAGS=
5780a46b 3521 fi
ff66d28f
PE
3522fi
3523for ac_declaration in \
ec2075e9 3524 '' \
ff66d28f
PE
3525 'extern "C" void std::exit (int) throw (); using std::exit;' \
3526 'extern "C" void std::exit (int); using std::exit;' \
3527 'extern "C" void exit (int) throw ();' \
3528 'extern "C" void exit (int);' \
3529 'void exit (int);'
3530do
3531 cat >conftest.$ac_ext <<_ACEOF
ff66d28f
PE
3532/* confdefs.h. */
3533_ACEOF
3534cat confdefs.h >>conftest.$ac_ext
3535cat >>conftest.$ac_ext <<_ACEOF
3536/* end confdefs.h. */
158960ba 3537$ac_declaration
ec2075e9 3538#include <stdlib.h>
ff66d28f
PE
3539int
3540main ()
3541{
3542exit (42);
3543 ;
3544 return 0;
3545}
3546_ACEOF
3547rm -f conftest.$ac_objext
3548if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
ec2075e9 3549 (eval $ac_compile) 2>conftest.er1
ff66d28f 3550 ac_status=$?
ec2075e9
BK
3551 grep -v '^ *+' conftest.er1 >conftest.err
3552 rm -f conftest.er1
3553 cat conftest.err >&5
ff66d28f
PE
3554 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3555 (exit $ac_status); } &&
5b043f08
GK
3556 { ac_try='test -z "$ac_cxx_werror_flag"
3557 || test ! -s conftest.err'
ec2075e9
BK
3558 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3559 (eval $ac_try) 2>&5
3560 ac_status=$?
3561 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3562 (exit $ac_status); }; } &&
3563 { ac_try='test -s conftest.$ac_objext'
ff66d28f
PE
3564 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3565 (eval $ac_try) 2>&5
3566 ac_status=$?
3567 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3568 (exit $ac_status); }; }; then
3569 :
3570else
3571 echo "$as_me: failed program was:" >&5
3572sed 's/^/| /' conftest.$ac_ext >&5
b2dad0e3 3573
ff66d28f
PE
3574continue
3575fi
ec2075e9 3576rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ff66d28f 3577 cat >conftest.$ac_ext <<_ACEOF
ff66d28f
PE
3578/* confdefs.h. */
3579_ACEOF
3580cat confdefs.h >>conftest.$ac_ext
3581cat >>conftest.$ac_ext <<_ACEOF
3582/* end confdefs.h. */
3583$ac_declaration
3584int
3585main ()
3586{
3587exit (42);
3588 ;
3589 return 0;
3590}
3591_ACEOF
3592rm -f conftest.$ac_objext
3593if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
ec2075e9 3594 (eval $ac_compile) 2>conftest.er1
ff66d28f 3595 ac_status=$?
ec2075e9
BK
3596 grep -v '^ *+' conftest.er1 >conftest.err
3597 rm -f conftest.er1
3598 cat conftest.err >&5
ff66d28f
PE
3599 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3600 (exit $ac_status); } &&
5b043f08
GK
3601 { ac_try='test -z "$ac_cxx_werror_flag"
3602 || test ! -s conftest.err'
ec2075e9
BK
3603 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3604 (eval $ac_try) 2>&5
3605 ac_status=$?
3606 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3607 (exit $ac_status); }; } &&
3608 { ac_try='test -s conftest.$ac_objext'
ff66d28f
PE
3609 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3610 (eval $ac_try) 2>&5
3611 ac_status=$?
3612 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3613 (exit $ac_status); }; }; then
3614 break
3615else
3616 echo "$as_me: failed program was:" >&5
3617sed 's/^/| /' conftest.$ac_ext >&5
3618
3619fi
ec2075e9 3620rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ff66d28f
PE
3621done
3622rm -f conftest*
3623if test -n "$ac_declaration"; then
3624 echo '#ifdef __cplusplus' >>confdefs.h
3625 echo $ac_declaration >>confdefs.h
3626 echo '#endif' >>confdefs.h
3627fi
3840fa2a 3628
ff66d28f
PE
3629ac_ext=c
3630ac_cpp='$CPP $CPPFLAGS'
3631ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3632ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3633ac_compiler_gnu=$ac_cv_c_compiler_gnu
16da539b 3634
ff66d28f 3635 CXXFLAGS="$save_CXXFLAGS"
d0941a31
PE
3636
3637
33590f13 3638
f6dda651 3639
ff66d28f
PE
3640 # Will set LN_S to either 'ln -s', 'ln', or 'cp -p' (if linking isn't
3641 # available). Uncomment the next line to force a particular method.
3642 echo "$as_me:$LINENO: checking whether ln -s works" >&5
3643echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
3644LN_S=$as_ln_s
3645if test "$LN_S" = "ln -s"; then
3646 echo "$as_me:$LINENO: result: yes" >&5
3647echo "${ECHO_T}yes" >&6
2f235b6d 3648else
ff66d28f
PE
3649 echo "$as_me:$LINENO: result: no, using $LN_S" >&5
3650echo "${ECHO_T}no, using $LN_S" >&6
2f235b6d 3651fi
2f235b6d 3652
ff66d28f 3653 #LN_S='cp -p'
2f235b6d 3654
ff66d28f
PE
3655 if test -n "$ac_tool_prefix"; then
3656 # Extract the first word of "${ac_tool_prefix}as", so it can be a program name with args.
3657set dummy ${ac_tool_prefix}as; ac_word=$2
3658echo "$as_me:$LINENO: checking for $ac_word" >&5
3659echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3660if test "${ac_cv_prog_AS+set}" = set; then
3661 echo $ECHO_N "(cached) $ECHO_C" >&6
2f235b6d 3662else
ff66d28f
PE
3663 if test -n "$AS"; then
3664 ac_cv_prog_AS="$AS" # Let the user override the test.
2f235b6d 3665else
ff66d28f
PE
3666as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3667for as_dir in $PATH
3668do
3669 IFS=$as_save_IFS
3670 test -z "$as_dir" && as_dir=.
3671 for ac_exec_ext in '' $ac_executable_extensions; do
3672 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3673 ac_cv_prog_AS="${ac_tool_prefix}as"
3674 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3675 break 2
3676 fi
3677done
3678done
3679
2f235b6d 3680fi
2f235b6d 3681fi
ff66d28f
PE
3682AS=$ac_cv_prog_AS
3683if test -n "$AS"; then
3684 echo "$as_me:$LINENO: result: $AS" >&5
3685echo "${ECHO_T}$AS" >&6
2f235b6d 3686else
ff66d28f
PE
3687 echo "$as_me:$LINENO: result: no" >&5
3688echo "${ECHO_T}no" >&6
2f235b6d
PE
3689fi
3690
ff66d28f
PE
3691fi
3692if test -z "$ac_cv_prog_AS"; then
3693 ac_ct_AS=$AS
3694 # Extract the first word of "as", so it can be a program name with args.
3695set dummy as; ac_word=$2
3696echo "$as_me:$LINENO: checking for $ac_word" >&5
3697echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3698if test "${ac_cv_prog_ac_ct_AS+set}" = set; then
3699 echo $ECHO_N "(cached) $ECHO_C" >&6
3700else
3701 if test -n "$ac_ct_AS"; then
3702 ac_cv_prog_ac_ct_AS="$ac_ct_AS" # Let the user override the test.
3703else
3704as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3705for as_dir in $PATH
3706do
3707 IFS=$as_save_IFS
3708 test -z "$as_dir" && as_dir=.
3709 for ac_exec_ext in '' $ac_executable_extensions; do
3710 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3711 ac_cv_prog_ac_ct_AS="as"
3712 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3713 break 2
3714 fi
3715done
3716done
2f235b6d 3717
ff66d28f
PE
3718fi
3719fi
3720ac_ct_AS=$ac_cv_prog_ac_ct_AS
3721if test -n "$ac_ct_AS"; then
3722 echo "$as_me:$LINENO: result: $ac_ct_AS" >&5
3723echo "${ECHO_T}$ac_ct_AS" >&6
3724else
3725 echo "$as_me:$LINENO: result: no" >&5
3726echo "${ECHO_T}no" >&6
3727fi
2f235b6d 3728
ff66d28f
PE
3729 AS=$ac_ct_AS
3730else
3731 AS="$ac_cv_prog_AS"
2f235b6d 3732fi
2f235b6d 3733
ff66d28f
PE
3734 if test -n "$ac_tool_prefix"; then
3735 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
3736set dummy ${ac_tool_prefix}ar; ac_word=$2
3737echo "$as_me:$LINENO: checking for $ac_word" >&5
3738echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3739if test "${ac_cv_prog_AR+set}" = set; then
3740 echo $ECHO_N "(cached) $ECHO_C" >&6
3741else
3742 if test -n "$AR"; then
3743 ac_cv_prog_AR="$AR" # Let the user override the test.
3744else
3745as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3746for as_dir in $PATH
3747do
3748 IFS=$as_save_IFS
3749 test -z "$as_dir" && as_dir=.
3750 for ac_exec_ext in '' $ac_executable_extensions; do
3751 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3752 ac_cv_prog_AR="${ac_tool_prefix}ar"
3753 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3754 break 2
3755 fi
3756done
3757done
2f235b6d 3758
ff66d28f
PE
3759fi
3760fi
3761AR=$ac_cv_prog_AR
3762if test -n "$AR"; then
3763 echo "$as_me:$LINENO: result: $AR" >&5
3764echo "${ECHO_T}$AR" >&6
3765else
3766 echo "$as_me:$LINENO: result: no" >&5
3767echo "${ECHO_T}no" >&6
3768fi
2f235b6d 3769
ff66d28f
PE
3770fi
3771if test -z "$ac_cv_prog_AR"; then
3772 ac_ct_AR=$AR
3773 # Extract the first word of "ar", so it can be a program name with args.
3774set dummy ar; ac_word=$2
3775echo "$as_me:$LINENO: checking for $ac_word" >&5
3776echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3777if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
3778 echo $ECHO_N "(cached) $ECHO_C" >&6
3779else
3780 if test -n "$ac_ct_AR"; then
3781 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
3782else
3783as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3784for as_dir in $PATH
3785do
3786 IFS=$as_save_IFS
3787 test -z "$as_dir" && as_dir=.
3788 for ac_exec_ext in '' $ac_executable_extensions; do
3789 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3790 ac_cv_prog_ac_ct_AR="ar"
3791 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3792 break 2
3793 fi
3794done
3795done
2f235b6d 3796
ff66d28f
PE
3797fi
3798fi
3799ac_ct_AR=$ac_cv_prog_ac_ct_AR
3800if test -n "$ac_ct_AR"; then
3801 echo "$as_me:$LINENO: result: $ac_ct_AR" >&5
3802echo "${ECHO_T}$ac_ct_AR" >&6
2f235b6d 3803else
ff66d28f
PE
3804 echo "$as_me:$LINENO: result: no" >&5
3805echo "${ECHO_T}no" >&6
2f235b6d
PE
3806fi
3807
ff66d28f 3808 AR=$ac_ct_AR
2f235b6d 3809else
ff66d28f 3810 AR="$ac_cv_prog_AR"
2f235b6d
PE
3811fi
3812
ff66d28f
PE
3813 if test -n "$ac_tool_prefix"; then
3814 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
3815set dummy ${ac_tool_prefix}ranlib; ac_word=$2
3816echo "$as_me:$LINENO: checking for $ac_word" >&5
3817echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3818if test "${ac_cv_prog_RANLIB+set}" = set; then
3819 echo $ECHO_N "(cached) $ECHO_C" >&6
3820else
3821 if test -n "$RANLIB"; then
3822 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
3823else
3824as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3825for as_dir in $PATH
3826do
3827 IFS=$as_save_IFS
3828 test -z "$as_dir" && as_dir=.
3829 for ac_exec_ext in '' $ac_executable_extensions; do
3830 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3831 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
3832 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3833 break 2
3834 fi
3835done
3836done
3837
3838fi
3839fi
3840RANLIB=$ac_cv_prog_RANLIB
3841if test -n "$RANLIB"; then
3842 echo "$as_me:$LINENO: result: $RANLIB" >&5
3843echo "${ECHO_T}$RANLIB" >&6
2f235b6d 3844else
ff66d28f
PE
3845 echo "$as_me:$LINENO: result: no" >&5
3846echo "${ECHO_T}no" >&6
2f235b6d
PE
3847fi
3848
ff66d28f
PE
3849fi
3850if test -z "$ac_cv_prog_RANLIB"; then
3851 ac_ct_RANLIB=$RANLIB
3852 # Extract the first word of "ranlib", so it can be a program name with args.
3853set dummy ranlib; ac_word=$2
3854echo "$as_me:$LINENO: checking for $ac_word" >&5
3855echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3856if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
3857 echo $ECHO_N "(cached) $ECHO_C" >&6
3858else
3859 if test -n "$ac_ct_RANLIB"; then
3860 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
2f235b6d 3861else
ff66d28f
PE
3862as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3863for as_dir in $PATH
3864do
3865 IFS=$as_save_IFS
3866 test -z "$as_dir" && as_dir=.
3867 for ac_exec_ext in '' $ac_executable_extensions; do
3868 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3869 ac_cv_prog_ac_ct_RANLIB="ranlib"
3870 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3871 break 2
3872 fi
3873done
3874done
3875
3876 test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB="ranlib-not-found-in-path-error"
3877fi
3878fi
3879ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
3880if test -n "$ac_ct_RANLIB"; then
3881 echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
3882echo "${ECHO_T}$ac_ct_RANLIB" >&6
3883else
3884 echo "$as_me:$LINENO: result: no" >&5
3885echo "${ECHO_T}no" >&6
2f235b6d
PE
3886fi
3887
ff66d28f 3888 RANLIB=$ac_ct_RANLIB
2f235b6d 3889else
ff66d28f 3890 RANLIB="$ac_cv_prog_RANLIB"
2f235b6d
PE
3891fi
3892
3893
ff66d28f
PE
3894 echo "$as_me:$LINENO: checking whether to enable maintainer-specific portions of Makefiles" >&5
3895echo $ECHO_N "checking whether to enable maintainer-specific portions of Makefiles... $ECHO_C" >&6
3896 # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
3897if test "${enable_maintainer_mode+set}" = set; then
3898 enableval="$enable_maintainer_mode"
3899 USE_MAINTAINER_MODE=$enableval
3900else
3901 USE_MAINTAINER_MODE=no
3902fi;
3903 echo "$as_me:$LINENO: result: $USE_MAINTAINER_MODE" >&5
3904echo "${ECHO_T}$USE_MAINTAINER_MODE" >&6
2f235b6d
PE
3905
3906
ff66d28f
PE
3907if test $USE_MAINTAINER_MODE = yes; then
3908 MAINTAINER_MODE_TRUE=
3909 MAINTAINER_MODE_FALSE='#'
3910else
3911 MAINTAINER_MODE_TRUE='#'
3912 MAINTAINER_MODE_FALSE=
3913fi
3914
3915 MAINT=$MAINTAINER_MODE_TRUE
2f235b6d 3916
5780a46b 3917
f4c79fef 3918
92eabea2
PE
3919 # Set up safe default values for all subsequent AM_CONDITIONAL tests
3920 # which are themselves conditionally expanded.
3921 ## (Right now, this only matters for enable_wchar_t, but nothing prevents
3922 ## other macros from doing the same. This should be automated.) -pme
ff66d28f 3923 need_libmath=no
ff66d28f 3924
464aea98
JM
3925 # Check for uClibc since Linux platforms use different configuration
3926 # directories depending on the C library in use.
3927 cat >conftest.$ac_ext <<_ACEOF
3928/* confdefs.h. */
3929_ACEOF
3930cat confdefs.h >>conftest.$ac_ext
3931cat >>conftest.$ac_ext <<_ACEOF
3932/* end confdefs.h. */
3933
3934 #include <stdio.h>
3935 #if __UCLIBC__
3936 _using_uclibc
3937 #endif
3938
3939_ACEOF
3940if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3941 $EGREP "_using_uclibc" >/dev/null 2>&1; then
3942 uclibc=yes
3943else
3944 uclibc=no
3945fi
3946rm -f conftest*
3947
3948
ff66d28f
PE
3949 # Find platform-specific directories containing configuration info.
3950 # Also possibly modify flags used elsewhere, as needed by the platform.
3951
3952 . $glibcxx_srcdir/configure.host
3953 { echo "$as_me:$LINENO: CPU config directory is $cpu_include_dir" >&5
3954echo "$as_me: CPU config directory is $cpu_include_dir" >&6;}
3955 { echo "$as_me:$LINENO: OS config directory is $os_include_dir" >&5
3956echo "$as_me: OS config directory is $os_include_dir" >&6;}
3957
3958
3959
ff66d28f 3960
b2dad0e3
BK
3961# Check whether --enable-shared or --disable-shared was given.
3962if test "${enable_shared+set}" = set; then
3963 enableval="$enable_shared"
3964 p=${PACKAGE-default}
c21b6f87 3965case $enableval in
b2dad0e3
BK
3966yes) enable_shared=yes ;;
3967no) enable_shared=no ;;
3968*)
3969 enable_shared=no
3970 # Look at the argument we got. We use all the common list separators.
3971 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
3972 for pkg in $enableval; do
3973 if test "X$pkg" = "X$p"; then
3974 enable_shared=yes
3975 fi
3976 done
3977 IFS="$ac_save_ifs"
3978 ;;
3979esac
3980else
3981 enable_shared=yes
ff66d28f 3982fi;
b2dad0e3
BK
3983# Check whether --enable-static or --disable-static was given.
3984if test "${enable_static+set}" = set; then
3985 enableval="$enable_static"
3986 p=${PACKAGE-default}
c21b6f87 3987case $enableval in
b2dad0e3
BK
3988yes) enable_static=yes ;;
3989no) enable_static=no ;;
3990*)
3991 enable_static=no
3992 # Look at the argument we got. We use all the common list separators.
3993 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
3994 for pkg in $enableval; do
3995 if test "X$pkg" = "X$p"; then
3996 enable_static=yes
3997 fi
3998 done
3999 IFS="$ac_save_ifs"
4000 ;;
4001esac
4002else
4003 enable_static=yes
ff66d28f 4004fi;
b2dad0e3
BK
4005# Check whether --enable-fast-install or --disable-fast-install was given.
4006if test "${enable_fast_install+set}" = set; then
4007 enableval="$enable_fast_install"
4008 p=${PACKAGE-default}
c21b6f87 4009case $enableval in
b2dad0e3
BK
4010yes) enable_fast_install=yes ;;
4011no) enable_fast_install=no ;;
4012*)
4013 enable_fast_install=no
4014 # Look at the argument we got. We use all the common list separators.
4015 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
4016 for pkg in $enableval; do
4017 if test "X$pkg" = "X$p"; then
4018 enable_fast_install=yes
4019 fi
4020 done
4021 IFS="$ac_save_ifs"
4022 ;;
4023esac
4024else
4025 enable_fast_install=yes
ff66d28f 4026fi;
b2dad0e3 4027
b2dad0e3
BK
4028# Check whether --with-gnu-ld or --without-gnu-ld was given.
4029if test "${with_gnu_ld+set}" = set; then
4030 withval="$with_gnu_ld"
4031 test "$withval" = no || with_gnu_ld=yes
4032else
4033 with_gnu_ld=no
ff66d28f 4034fi;
b2dad0e3 4035ac_prog=ld
c21b6f87 4036if test "$GCC" = yes; then
b2dad0e3 4037 # Check if gcc -print-prog-name=ld gives a path.
ff66d28f
PE
4038 echo "$as_me:$LINENO: checking for ld used by GCC" >&5
4039echo $ECHO_N "checking for ld used by GCC... $ECHO_C" >&6
3df64633
AO
4040 case $host in
4041 *-*-mingw*)
4042 # gcc leaves a trailing carriage return which upsets mingw
4043 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
4044 *)
4045 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
4046 esac
c21b6f87 4047 case $ac_prog in
b2dad0e3 4048 # Accept absolute paths.
3840fa2a 4049 [\\/]* | [A-Za-z]:[\\/]*)
b2dad0e3
BK
4050 re_direlt='/[^/][^/]*/\.\./'
4051 # Canonicalize the path of ld
4052 ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
4053 while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
4054 ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
4055 done
4056 test -z "$LD" && LD="$ac_prog"
4057 ;;
4058 "")
4059 # If it fails, then pretend we aren't using GCC.
4060 ac_prog=ld
4061 ;;
4062 *)
4063 # If it is relative, then search for the first ld in PATH.
4064 with_gnu_ld=unknown
4065 ;;
4066 esac
4067elif test "$with_gnu_ld" = yes; then
ff66d28f
PE
4068 echo "$as_me:$LINENO: checking for GNU ld" >&5
4069echo $ECHO_N "checking for GNU ld... $ECHO_C" >&6
b2dad0e3 4070else
ff66d28f
PE
4071 echo "$as_me:$LINENO: checking for non-GNU ld" >&5
4072echo $ECHO_N "checking for non-GNU ld... $ECHO_C" >&6
b2dad0e3 4073fi
ff66d28f
PE
4074if test "${lt_cv_path_LD+set}" = set; then
4075 echo $ECHO_N "(cached) $ECHO_C" >&6
b2dad0e3
BK
4076else
4077 if test -z "$LD"; then
3840fa2a 4078 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
b2dad0e3
BK
4079 for ac_dir in $PATH; do
4080 test -z "$ac_dir" && ac_dir=.
3840fa2a 4081 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
c21b6f87 4082 lt_cv_path_LD="$ac_dir/$ac_prog"
b2dad0e3
BK
4083 # Check to see if the program is GNU ld. I'd rather use --version,
4084 # but apparently some GNU ld's only accept -v.
4085 # Break only if it was the GNU/non-GNU ld that we prefer.
c21b6f87 4086 if "$lt_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
b2dad0e3
BK
4087 test "$with_gnu_ld" != no && break
4088 else
4089 test "$with_gnu_ld" != yes && break
4090 fi
4091 fi
4092 done
4093 IFS="$ac_save_ifs"
4094else
c21b6f87 4095 lt_cv_path_LD="$LD" # Let the user override the test with a path.
b2dad0e3
BK
4096fi
4097fi
4098
c21b6f87 4099LD="$lt_cv_path_LD"
b2dad0e3 4100if test -n "$LD"; then
ff66d28f
PE
4101 echo "$as_me:$LINENO: result: $LD" >&5
4102echo "${ECHO_T}$LD" >&6
b2dad0e3 4103else
ff66d28f
PE
4104 echo "$as_me:$LINENO: result: no" >&5
4105echo "${ECHO_T}no" >&6
b2dad0e3 4106fi
ff66d28f
PE
4107test -z "$LD" && { { echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5
4108echo "$as_me: error: no acceptable ld found in \$PATH" >&2;}
4109 { (exit 1); exit 1; }; }
4110echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5
4111echo $ECHO_N "checking if the linker ($LD) is GNU ld... $ECHO_C" >&6
4112if test "${lt_cv_prog_gnu_ld+set}" = set; then
4113 echo $ECHO_N "(cached) $ECHO_C" >&6
b2dad0e3
BK
4114else
4115 # I'd rather use --version here, but apparently some GNU ld's only accept -v.
4116if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
c21b6f87 4117 lt_cv_prog_gnu_ld=yes
b2dad0e3 4118else
c21b6f87 4119 lt_cv_prog_gnu_ld=no
b2dad0e3
BK
4120fi
4121fi
ff66d28f
PE
4122echo "$as_me:$LINENO: result: $lt_cv_prog_gnu_ld" >&5
4123echo "${ECHO_T}$lt_cv_prog_gnu_ld" >&6
c21b6f87 4124with_gnu_ld=$lt_cv_prog_gnu_ld
3df64633 4125
b2dad0e3 4126
ff66d28f
PE
4127echo "$as_me:$LINENO: checking for $LD option to reload object files" >&5
4128echo $ECHO_N "checking for $LD option to reload object files... $ECHO_C" >&6
4129if test "${lt_cv_ld_reload_flag+set}" = set; then
4130 echo $ECHO_N "(cached) $ECHO_C" >&6
3df64633
AO
4131else
4132 lt_cv_ld_reload_flag='-r'
4133fi
ff66d28f
PE
4134echo "$as_me:$LINENO: result: $lt_cv_ld_reload_flag" >&5
4135echo "${ECHO_T}$lt_cv_ld_reload_flag" >&6
3df64633
AO
4136reload_flag=$lt_cv_ld_reload_flag
4137test -n "$reload_flag" && reload_flag=" $reload_flag"
b2dad0e3 4138
ff66d28f
PE
4139echo "$as_me:$LINENO: checking for BSD-compatible nm" >&5
4140echo $ECHO_N "checking for BSD-compatible nm... $ECHO_C" >&6
4141if test "${lt_cv_path_NM+set}" = set; then
4142 echo $ECHO_N "(cached) $ECHO_C" >&6
b2dad0e3
BK
4143else
4144 if test -n "$NM"; then
4145 # Let the user override the test.
c21b6f87 4146 lt_cv_path_NM="$NM"
b2dad0e3 4147else
3840fa2a 4148 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
b2dad0e3
BK
4149 for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do
4150 test -z "$ac_dir" && ac_dir=.
3df64633
AO
4151 tmp_nm=$ac_dir/${ac_tool_prefix}nm
4152 if test -f $tmp_nm || test -f $tmp_nm$ac_exeext ; then
b2dad0e3
BK
4153 # Check to see if the nm accepts a BSD-compat flag.
4154 # Adding the `sed 1q' prevents false positives on HP-UX, which says:
4155 # nm: unknown option "B" ignored
6d93bca4
AO
4156 # Tru64's nm complains that /dev/null is an invalid object file
4157 if ($tmp_nm -B /dev/null 2>&1 | sed '1q'; exit 0) | egrep '(/dev/null|Invalid file or object type)' >/dev/null; then
c21b6f87 4158 lt_cv_path_NM="$tmp_nm -B"
b2dad0e3 4159 break
3df64633 4160 elif ($tmp_nm -p /dev/null 2>&1 | sed '1q'; exit 0) | egrep /dev/null >/dev/null; then
c21b6f87 4161 lt_cv_path_NM="$tmp_nm -p"
b2dad0e3
BK
4162 break
4163 else
c21b6f87 4164 lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
b2dad0e3
BK
4165 continue # so that we can try to find one that supports BSD flags
4166 fi
4167 fi
4168 done
4169 IFS="$ac_save_ifs"
c21b6f87 4170 test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm
b2dad0e3
BK
4171fi
4172fi
4173
c21b6f87 4174NM="$lt_cv_path_NM"
ff66d28f
PE
4175echo "$as_me:$LINENO: result: $NM" >&5
4176echo "${ECHO_T}$NM" >&6
b2dad0e3 4177
ff66d28f
PE
4178echo "$as_me:$LINENO: checking how to recognise dependant libraries" >&5
4179echo $ECHO_N "checking how to recognise dependant libraries... $ECHO_C" >&6
4180if test "${lt_cv_deplibs_check_method+set}" = set; then
4181 echo $ECHO_N "(cached) $ECHO_C" >&6
3df64633 4182else
3dd7094e 4183 lt_cv_file_magic_cmd='$MAGIC_CMD'
3df64633
AO
4184lt_cv_file_magic_test_file=
4185lt_cv_deplibs_check_method='unknown'
4186# Need to set the preceding variable on all platforms that support
4187# interlibrary dependencies.
4188# 'none' -- dependencies not supported.
4189# `unknown' -- same as none, but documents that we really don't know.
4190# 'pass_all' -- all dependencies passed with no checks.
4191# 'test_compile' -- check by making test program.
4192# 'file_magic [regex]' -- check by looking for files in library path
4193# which responds to the $file_magic_cmd with a given egrep regex.
4194# If you have `file' or equivalent on your system and you're not sure
4195# whether `pass_all' will *always* work, you probably want this one.
4196
c21b6f87
PE
4197case $host_os in
4198aix*)
3df64633
AO
4199 lt_cv_deplibs_check_method=pass_all
4200 ;;
4201
4202beos*)
4203 lt_cv_deplibs_check_method=pass_all
4204 ;;
4205
4206bsdi4*)
c21b6f87
PE
4207 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
4208 lt_cv_file_magic_cmd='/usr/bin/file -L'
3df64633
AO
4209 lt_cv_file_magic_test_file=/shlib/libc.so
4210 ;;
4211
3dd7094e 4212cygwin* | mingw* |pw32*)
3df64633 4213 lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
3dd7094e 4214 lt_cv_file_magic_cmd='$OBJDUMP -f'
3df64633
AO
4215 ;;
4216
c21b6f87 4217darwin* | rhapsody*)
29d4adf4 4218 # this will be overwritten by pass_all, but leave it in just in case
c21b6f87 4219 lt_cv_deplibs_check_method='file_magic Mach-O dynamically linked shared library'
47e982b2
BK
4220 lt_cv_file_magic_cmd='/usr/bin/file -L'
4221 case "$host_os" in
4222 rhapsody* | darwin1.012)
4223 lt_cv_file_magic_test_file='/System/Library/Frameworks/System.framework/System'
4224 ;;
4225 *) # Darwin 1.3 on
4226 lt_cv_file_magic_test_file='/usr/lib/libSystem.dylib'
4227 ;;
4228 esac
29d4adf4 4229 lt_cv_deplibs_check_method=pass_all
c21b6f87
PE
4230 ;;
4231
dc7c62ae 4232freebsd* | kfreebsd*-gnu)
3df64633 4233 if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
c21b6f87 4234 case $host_cpu in
3df64633 4235 i*86 )
6d93bca4
AO
4236 # Not sure whether the presence of OpenBSD here was a mistake.
4237 # Let's accept both of them until this is cleared up.
c21b6f87
PE
4238 lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD)/i[3-9]86 (compact )?demand paged shared library'
4239 lt_cv_file_magic_cmd=/usr/bin/file
3df64633
AO
4240 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
4241 ;;
4242 esac
4243 else
4244 lt_cv_deplibs_check_method=pass_all
4245 fi
4246 ;;
4247
4248gnu*)
4249 lt_cv_deplibs_check_method=pass_all
4250 ;;
4251
c21b6f87 4252hpux10.20*|hpux11*)
38cca750
BK
4253 case $host_cpu in
4254 hppa*)
4255 lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9].[0-9]) shared library'
4256 lt_cv_file_magic_cmd=/usr/bin/file
4257 lt_cv_file_magic_test_file=/usr/lib/libc.sl
4258 ;;
4259 ia64*)
4260 lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64'
4261 lt_cv_file_magic_cmd=/usr/bin/file
4262 lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
4263 ;;
4264 esac
3df64633
AO
4265 ;;
4266
4267irix5* | irix6*)
c21b6f87 4268 case $host_os in
3df64633
AO
4269 irix5*)
4270 # this will be overridden with pass_all, but let us keep it just in case
4271 lt_cv_deplibs_check_method="file_magic ELF 32-bit MSB dynamic lib MIPS - version 1"
4272 ;;
4273 *)
c21b6f87 4274 case $LD in
3df64633
AO
4275 *-32|*"-32 ") libmagic=32-bit;;
4276 *-n32|*"-n32 ") libmagic=N32;;
4277 *-64|*"-64 ") libmagic=64-bit;;
4278 *) libmagic=never-match;;
4279 esac
4280 # this will be overridden with pass_all, but let us keep it just in case
c21b6f87
PE
4281 lt_cv_deplibs_check_method="file_magic ELF ${libmagic} MSB mips-[1234] dynamic lib MIPS - version 1"
4282 ;;
3df64633
AO
4283 esac
4284 lt_cv_file_magic_test_file=`echo /lib${libsuff}/libc.so*`
4285 lt_cv_deplibs_check_method=pass_all
4286 ;;
4287
4288# This must be Linux ELF.
6d93bca4 4289linux-gnu*)
2c92e90f 4290 lt_cv_deplibs_check_method=pass_all
3df64633
AO
4291 ;;
4292
dc7c62ae 4293netbsd* | knetbsd*-gnu)
c21b6f87 4294 if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
47e982b2 4295 lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$'
3df64633 4296 else
47e982b2 4297 lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so$'
3df64633 4298 fi
c21b6f87
PE
4299 ;;
4300
4301newsos6)
4302 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)'
4303 lt_cv_file_magic_cmd=/usr/bin/file
4304 lt_cv_file_magic_test_file=/usr/lib/libnls.so
3df64633
AO
4305 ;;
4306
4307osf3* | osf4* | osf5*)
4308 # this will be overridden with pass_all, but let us keep it just in case
4309 lt_cv_deplibs_check_method='file_magic COFF format alpha shared library'
4310 lt_cv_file_magic_test_file=/shlib/libc.so
4311 lt_cv_deplibs_check_method=pass_all
4312 ;;
4313
4314sco3.2v5*)
4315 lt_cv_deplibs_check_method=pass_all
4316 ;;
4317
4318solaris*)
4319 lt_cv_deplibs_check_method=pass_all
4320 lt_cv_file_magic_test_file=/lib/libc.so
4321 ;;
4322
bfa1e6b1
BK
4323sysv5uw[78]* | sysv4*uw2*)
4324 lt_cv_deplibs_check_method=pass_all
4325 ;;
4326
3df64633 4327sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
c21b6f87 4328 case $host_vendor in
3df64633
AO
4329 ncr)
4330 lt_cv_deplibs_check_method=pass_all
4331 ;;
4332 motorola)
c21b6f87
PE
4333 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib) M[0-9][0-9]* Version [0-9]'
4334 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
3df64633
AO
4335 ;;
4336 esac
4337 ;;
4338esac
4339
4340fi
ff66d28f
PE
4341echo "$as_me:$LINENO: result: $lt_cv_deplibs_check_method" >&5
4342echo "${ECHO_T}$lt_cv_deplibs_check_method" >&6
3df64633
AO
4343file_magic_cmd=$lt_cv_file_magic_cmd
4344deplibs_check_method=$lt_cv_deplibs_check_method
4345
3df64633 4346
ff66d28f 4347
3df64633
AO
4348
4349# Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers!
4350
6dab073b
MS
4351# find the maximum length of command line arguments
4352echo "$as_me:$LINENO: checking the maximum length of command line arguments" >&5
4353echo $ECHO_N "checking the maximum length of command line arguments... $ECHO_C" >&6
4354if test "${lt_cv_sys_max_cmd_len+set}" = set; then
4355 echo $ECHO_N "(cached) $ECHO_C" >&6
4356else
4357 i=0
4358 teststring="ABCD"
4359
4360 case $build_os in
4361 msdosdjgpp*)
4362 # On DJGPP, this test can blow up pretty badly due to problems in libc
4363 # (any single argument exceeding 2000 bytes causes a buffer overrun
4364 # during glob expansion). Even if it were fixed, the result of this
4365 # check would be larger than it should be.
4366 lt_cv_sys_max_cmd_len=12288; # 12K is about right
4367 ;;
4368
4369 cygwin* | mingw*)
4370 # On Win9x/ME, this test blows up -- it succeeds, but takes
4371 # about 5 minutes as the teststring grows exponentially.
4372 # Worse, since 9x/ME are not pre-emptively multitasking,
4373 # you end up with a "frozen" computer, even though with patience
4374 # the test eventually succeeds (with a max line length of 256k).
4375 # Instead, let's just punt: use the minimum linelength reported by
4376 # all of the supported platforms: 8192 (on NT/2K/XP).
4377 lt_cv_sys_max_cmd_len=8192;
4378 ;;
4379
4380 amigaos*)
4381 # On AmigaOS with pdksh, this test takes hours, literally.
4382 # So we just punt and use a minimum line length of 8192.
4383 lt_cv_sys_max_cmd_len=8192;
4384 ;;
4385
4386 netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
4387 # This has been around since 386BSD, at least. Likely further.
4388 if test -x /sbin/sysctl; then
4389 lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
4390 elif test -x /usr/sbin/sysctl; then
4391 lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
4392 else
4393 lt_cv_sys_max_cmd_len=65536 # usable default for *BSD
4394 fi
4395 # And add a safety zone
4396 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
4397 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
4398 ;;
4399 esac
4400
4401fi
4402
f4c767fd 4403if test -n "$lt_cv_sys_max_cmd_len" ; then
6dab073b
MS
4404 echo "$as_me:$LINENO: result: $lt_cv_sys_max_cmd_len" >&5
4405echo "${ECHO_T}$lt_cv_sys_max_cmd_len" >&6
4406else
4407 echo "$as_me:$LINENO: result: none" >&5
4408echo "${ECHO_T}none" >&6
4409fi
4410
4411
3df64633 4412# Only perform the check for file, if the check method requires it
c21b6f87 4413case $deplibs_check_method in
3df64633 4414file_magic*)
3dd7094e 4415 if test "$file_magic_cmd" = '$MAGIC_CMD'; then
ff66d28f
PE
4416 echo "$as_me:$LINENO: checking for ${ac_tool_prefix}file" >&5
4417echo $ECHO_N "checking for ${ac_tool_prefix}file... $ECHO_C" >&6
4418if test "${lt_cv_path_MAGIC_CMD+set}" = set; then
4419 echo $ECHO_N "(cached) $ECHO_C" >&6
3df64633 4420else
c21b6f87 4421 case $MAGIC_CMD in
3df64633 4422 /*)
3dd7094e 4423 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
3df64633
AO
4424 ;;
4425 ?:/*)
3dd7094e 4426 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a dos path.
3df64633
AO
4427 ;;
4428 *)
3dd7094e 4429 ac_save_MAGIC_CMD="$MAGIC_CMD"
3df64633
AO
4430 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4431 ac_dummy="/usr/bin:$PATH"
4432 for ac_dir in $ac_dummy; do
4433 test -z "$ac_dir" && ac_dir=.
4434 if test -f $ac_dir/${ac_tool_prefix}file; then
3dd7094e 4435 lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file"
3df64633 4436 if test -n "$file_magic_test_file"; then
c21b6f87 4437 case $deplibs_check_method in
3df64633
AO
4438 "file_magic "*)
4439 file_magic_regex="`expr \"$deplibs_check_method\" : \"file_magic \(.*\)\"`"
3dd7094e 4440 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
3df64633
AO
4441 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
4442 egrep "$file_magic_regex" > /dev/null; then
4443 :
4444 else
4445 cat <<EOF 1>&2
4446
4447*** Warning: the command libtool uses to detect shared libraries,
4448*** $file_magic_cmd, produces output that libtool cannot recognize.
4449*** The result is that libtool may fail to recognize shared libraries
4450*** as such. This will affect the creation of libtool libraries that
4451*** depend on shared libraries, but programs linked with such libtool
4452*** libraries will work regardless of this problem. Nevertheless, you
4453*** may want to report the problem to your system manager and/or to
4454*** bug-libtool@gnu.org
4455
4456EOF
4457 fi ;;
4458 esac
4459 fi
4460 break
4461 fi
4462 done
4463 IFS="$ac_save_ifs"
3dd7094e 4464 MAGIC_CMD="$ac_save_MAGIC_CMD"
3df64633
AO
4465 ;;
4466esac
4467fi
4468
3dd7094e
AO
4469MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
4470if test -n "$MAGIC_CMD"; then
ff66d28f
PE
4471 echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5
4472echo "${ECHO_T}$MAGIC_CMD" >&6
3df64633 4473else
ff66d28f
PE
4474 echo "$as_me:$LINENO: result: no" >&5
4475echo "${ECHO_T}no" >&6
3df64633
AO
4476fi
4477
3dd7094e 4478if test -z "$lt_cv_path_MAGIC_CMD"; then
3df64633 4479 if test -n "$ac_tool_prefix"; then
ff66d28f
PE
4480 echo "$as_me:$LINENO: checking for file" >&5
4481echo $ECHO_N "checking for file... $ECHO_C" >&6
4482if test "${lt_cv_path_MAGIC_CMD+set}" = set; then
4483 echo $ECHO_N "(cached) $ECHO_C" >&6
3df64633 4484else
c21b6f87 4485 case $MAGIC_CMD in
3df64633 4486 /*)
3dd7094e 4487 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
3df64633
AO
4488 ;;
4489 ?:/*)
3dd7094e 4490 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a dos path.
3df64633
AO
4491 ;;
4492 *)
3dd7094e 4493 ac_save_MAGIC_CMD="$MAGIC_CMD"
3df64633
AO
4494 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4495 ac_dummy="/usr/bin:$PATH"
4496 for ac_dir in $ac_dummy; do
4497 test -z "$ac_dir" && ac_dir=.
4498 if test -f $ac_dir/file; then
3dd7094e 4499 lt_cv_path_MAGIC_CMD="$ac_dir/file"
3df64633 4500 if test -n "$file_magic_test_file"; then
c21b6f87 4501 case $deplibs_check_method in
3df64633
AO
4502 "file_magic "*)
4503 file_magic_regex="`expr \"$deplibs_check_method\" : \"file_magic \(.*\)\"`"
3dd7094e 4504 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
3df64633
AO
4505 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
4506 egrep "$file_magic_regex" > /dev/null; then
4507 :
4508 else
4509 cat <<EOF 1>&2
4510
4511*** Warning: the command libtool uses to detect shared libraries,
4512*** $file_magic_cmd, produces output that libtool cannot recognize.
4513*** The result is that libtool may fail to recognize shared libraries
4514*** as such. This will affect the creation of libtool libraries that
4515*** depend on shared libraries, but programs linked with such libtool
4516*** libraries will work regardless of this problem. Nevertheless, you
4517*** may want to report the problem to your system manager and/or to
4518*** bug-libtool@gnu.org
4519
4520EOF
4521 fi ;;
4522 esac
4523 fi
4524 break
4525 fi
4526 done
4527 IFS="$ac_save_ifs"
3dd7094e 4528 MAGIC_CMD="$ac_save_MAGIC_CMD"
3df64633
AO
4529 ;;
4530esac
4531fi
4532
3dd7094e
AO
4533MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
4534if test -n "$MAGIC_CMD"; then
ff66d28f
PE
4535 echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5
4536echo "${ECHO_T}$MAGIC_CMD" >&6
3df64633 4537else
ff66d28f
PE
4538 echo "$as_me:$LINENO: result: no" >&5
4539echo "${ECHO_T}no" >&6
3df64633
AO
4540fi
4541
4542 else
3dd7094e 4543 MAGIC_CMD=:
3df64633
AO
4544 fi
4545fi
4546
4547 fi
4548 ;;
4549esac
4550
ff66d28f
PE
4551if test -n "$ac_tool_prefix"; then
4552 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
3df64633 4553set dummy ${ac_tool_prefix}ranlib; ac_word=$2
ff66d28f
PE
4554echo "$as_me:$LINENO: checking for $ac_word" >&5
4555echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4556if test "${ac_cv_prog_RANLIB+set}" = set; then
4557 echo $ECHO_N "(cached) $ECHO_C" >&6
3df64633
AO
4558else
4559 if test -n "$RANLIB"; then
4560 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
4561else
ff66d28f
PE
4562as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4563for as_dir in $PATH
4564do
4565 IFS=$as_save_IFS
4566 test -z "$as_dir" && as_dir=.
4567 for ac_exec_ext in '' $ac_executable_extensions; do
4568 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4569 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
4570 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4571 break 2
4572 fi
4573done
4574done
4575
3df64633
AO
4576fi
4577fi
ff66d28f 4578RANLIB=$ac_cv_prog_RANLIB
3df64633 4579if test -n "$RANLIB"; then
ff66d28f
PE
4580 echo "$as_me:$LINENO: result: $RANLIB" >&5
4581echo "${ECHO_T}$RANLIB" >&6
3df64633 4582else
ff66d28f
PE
4583 echo "$as_me:$LINENO: result: no" >&5
4584echo "${ECHO_T}no" >&6
3df64633
AO
4585fi
4586
ff66d28f 4587fi
3df64633 4588if test -z "$ac_cv_prog_RANLIB"; then
ff66d28f 4589 ac_ct_RANLIB=$RANLIB
3df64633
AO
4590 # Extract the first word of "ranlib", so it can be a program name with args.
4591set dummy ranlib; ac_word=$2
ff66d28f
PE
4592echo "$as_me:$LINENO: checking for $ac_word" >&5
4593echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4594if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
4595 echo $ECHO_N "(cached) $ECHO_C" >&6
3df64633 4596else
ff66d28f
PE
4597 if test -n "$ac_ct_RANLIB"; then
4598 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
3df64633 4599else
ff66d28f
PE
4600as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4601for as_dir in $PATH
4602do
4603 IFS=$as_save_IFS
4604 test -z "$as_dir" && as_dir=.
4605 for ac_exec_ext in '' $ac_executable_extensions; do
4606 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4607 ac_cv_prog_ac_ct_RANLIB="ranlib"
4608 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4609 break 2
4610 fi
4611done
4612done
4613
4614 test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
3df64633
AO
4615fi
4616fi
ff66d28f
PE
4617ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
4618if test -n "$ac_ct_RANLIB"; then
4619 echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
4620echo "${ECHO_T}$ac_ct_RANLIB" >&6
3df64633 4621else
ff66d28f
PE
4622 echo "$as_me:$LINENO: result: no" >&5
4623echo "${ECHO_T}no" >&6
3df64633
AO
4624fi
4625
ff66d28f 4626 RANLIB=$ac_ct_RANLIB
3df64633 4627else
ff66d28f 4628 RANLIB="$ac_cv_prog_RANLIB"
3df64633
AO
4629fi
4630
ff66d28f
PE
4631if test -n "$ac_tool_prefix"; then
4632 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
3df64633 4633set dummy ${ac_tool_prefix}strip; ac_word=$2
ff66d28f
PE
4634echo "$as_me:$LINENO: checking for $ac_word" >&5
4635echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4636if test "${ac_cv_prog_STRIP+set}" = set; then
4637 echo $ECHO_N "(cached) $ECHO_C" >&6
3df64633
AO
4638else
4639 if test -n "$STRIP"; then
4640 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
4641else
ff66d28f
PE
4642as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4643for as_dir in $PATH
4644do
4645 IFS=$as_save_IFS
4646 test -z "$as_dir" && as_dir=.
4647 for ac_exec_ext in '' $ac_executable_extensions; do
4648 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4649 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
4650 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4651 break 2
4652 fi
4653done
4654done
4655
3df64633
AO
4656fi
4657fi
ff66d28f 4658STRIP=$ac_cv_prog_STRIP
3df64633 4659if test -n "$STRIP"; then
ff66d28f
PE
4660 echo "$as_me:$LINENO: result: $STRIP" >&5
4661echo "${ECHO_T}$STRIP" >&6
3df64633 4662else
ff66d28f
PE
4663 echo "$as_me:$LINENO: result: no" >&5
4664echo "${ECHO_T}no" >&6
3df64633
AO
4665fi
4666
ff66d28f 4667fi
3df64633 4668if test -z "$ac_cv_prog_STRIP"; then
ff66d28f 4669 ac_ct_STRIP=$STRIP
3df64633
AO
4670 # Extract the first word of "strip", so it can be a program name with args.
4671set dummy strip; ac_word=$2
ff66d28f
PE
4672echo "$as_me:$LINENO: checking for $ac_word" >&5
4673echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4674if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
4675 echo $ECHO_N "(cached) $ECHO_C" >&6
3df64633 4676else
ff66d28f
PE
4677 if test -n "$ac_ct_STRIP"; then
4678 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
3df64633 4679else
ff66d28f
PE
4680as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4681for as_dir in $PATH
4682do
4683 IFS=$as_save_IFS
4684 test -z "$as_dir" && as_dir=.
4685 for ac_exec_ext in '' $ac_executable_extensions; do
4686 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4687 ac_cv_prog_ac_ct_STRIP="strip"
4688 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4689 break 2
4690 fi
4691done
4692done
4693
4694 test -z "$ac_cv_prog_ac_ct_STRIP" && ac_cv_prog_ac_ct_STRIP=":"
3df64633
AO
4695fi
4696fi
ff66d28f
PE
4697ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
4698if test -n "$ac_ct_STRIP"; then
4699 echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
4700echo "${ECHO_T}$ac_ct_STRIP" >&6
3df64633 4701else
ff66d28f
PE
4702 echo "$as_me:$LINENO: result: no" >&5
4703echo "${ECHO_T}no" >&6
3df64633
AO
4704fi
4705
ff66d28f 4706 STRIP=$ac_ct_STRIP
3df64633 4707else
ff66d28f 4708 STRIP="$ac_cv_prog_STRIP"
3df64633
AO
4709fi
4710
b2dad0e3 4711
b2dad0e3
BK
4712# Check for any special flags to pass to ltconfig.
4713libtool_flags="--cache-file=$cache_file"
4714test "$enable_shared" = no && libtool_flags="$libtool_flags --disable-shared"
4715test "$enable_static" = no && libtool_flags="$libtool_flags --disable-static"
4716test "$enable_fast_install" = no && libtool_flags="$libtool_flags --disable-fast-install"
c21b6f87
PE
4717test "$GCC" = yes && libtool_flags="$libtool_flags --with-gcc"
4718test "$lt_cv_prog_gnu_ld" = yes && libtool_flags="$libtool_flags --with-gnu-ld"
ff66d28f 4719
3840fa2a
BK
4720
4721# Check whether --enable-libtool-lock or --disable-libtool-lock was given.
4722if test "${enable_libtool_lock+set}" = set; then
4723 enableval="$enable_libtool_lock"
3840fa2a 4724
ff66d28f 4725fi;
3840fa2a
BK
4726test "x$enable_libtool_lock" = xno && libtool_flags="$libtool_flags --disable-lock"
4727test x"$silent" = xyes && libtool_flags="$libtool_flags --silent"
b2dad0e3 4728
ff66d28f 4729
3df64633
AO
4730# Check whether --with-pic or --without-pic was given.
4731if test "${with_pic+set}" = set; then
4732 withval="$with_pic"
4733 pic_mode="$withval"
4734else
4735 pic_mode=default
ff66d28f 4736fi;
3df64633
AO
4737test x"$pic_mode" = xyes && libtool_flags="$libtool_flags --prefer-pic"
4738test x"$pic_mode" = xno && libtool_flags="$libtool_flags --prefer-non-pic"
4739
b2dad0e3
BK
4740# Some flags need to be propagated to the compiler or linker for good
4741# libtool support.
c21b6f87 4742case $host in
b2dad0e3
BK
4743*-*-irix6*)
4744 # Find out which ABI we are using.
4ffe6e87 4745 echo '#line 4745 "configure"' > conftest.$ac_ext
ff66d28f
PE
4746 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4747 (eval $ac_compile) 2>&5
4748 ac_status=$?
4749 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4750 (exit $ac_status); }; then
3a15abf1
BK
4751 if test "$lt_cv_prog_gnu_ld" = yes; then
4752 case `/usr/bin/file conftest.$ac_objext` in
4753 *32-bit*)
4754 LD="${LD-ld} -melf32bsmip"
4755 ;;
4756 *N32*)
4757 LD="${LD-ld} -melf32bmipn32"
4758 ;;
4759 *64-bit*)
4760 LD="${LD-ld} -melf64bmip"
4761 ;;
4762 esac
4763 else
c21b6f87 4764 case `/usr/bin/file conftest.$ac_objext` in
b2dad0e3
BK
4765 *32-bit*)
4766 LD="${LD-ld} -32"
4767 ;;
4768 *N32*)
4769 LD="${LD-ld} -n32"
4770 ;;
4771 *64-bit*)
4772 LD="${LD-ld} -64"
4773 ;;
4774 esac
3a15abf1 4775 fi
b2dad0e3
BK
4776 fi
4777 rm -rf conftest*
4778 ;;
4779
38cca750
BK
4780ia64-*-hpux*)
4781 # Find out which ABI we are using.
4782 echo 'int i;' > conftest.$ac_ext
ff66d28f
PE
4783 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4784 (eval $ac_compile) 2>&5
4785 ac_status=$?
4786 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4787 (exit $ac_status); }; then
38cca750
BK
4788 case "`/usr/bin/file conftest.o`" in
4789 *ELF-32*)
4790 HPUX_IA64_MODE="32"
4791 ;;
4792 *ELF-64*)
4793 HPUX_IA64_MODE="64"
4794 ;;
4795 esac
4796 fi
4797 rm -rf conftest*
4798 ;;
4799
162c7cd9
SW
4800x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*|s390*-*linux*|sparc*-*linux*)
4801 # Find out which ABI we are using.
4802 echo 'int i;' > conftest.$ac_ext
ff66d28f
PE
4803 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4804 (eval $ac_compile) 2>&5
4805 ac_status=$?
4806 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4807 (exit $ac_status); }; then
162c7cd9
SW
4808 case "`/usr/bin/file conftest.o`" in
4809 *32-bit*)
4810 case $host in
4811 x86_64-*linux*)
4812 LD="${LD-ld} -m elf_i386"
4813 ;;
e517f636 4814 ppc64-*linux*|powerpc64-*linux*)
162c7cd9
SW
4815 LD="${LD-ld} -m elf32ppclinux"
4816 ;;
4817 s390x-*linux*)
4818 LD="${LD-ld} -m elf_s390"
4819 ;;
4820 sparc64-*linux*)
4821 LD="${LD-ld} -m elf32_sparc"
4822 ;;
4823 esac
4824 ;;
4825 *64-bit*)
4826 case $host in
4827 x86_64-*linux*)
4828 LD="${LD-ld} -m elf_x86_64"
4829 ;;
4830 ppc*-*linux*|powerpc*-*linux*)
4831 LD="${LD-ld} -m elf64ppc"
4832 ;;
4833 s390*-*linux*)
4834 LD="${LD-ld} -m elf64_s390"
4835 ;;
4836 sparc*-*linux*)
4837 LD="${LD-ld} -m elf64_sparc"
4838 ;;
4839 esac
4840 ;;
4841 esac
4842 fi
4843 rm -rf conftest*
4844 ;;
4845
b2dad0e3
BK
4846*-*-sco3.2v5*)
4847 # On SCO OpenServer 5, we need -belf to get full-featured binaries.
4848 SAVE_CFLAGS="$CFLAGS"
4849 CFLAGS="$CFLAGS -belf"
ff66d28f
PE
4850 echo "$as_me:$LINENO: checking whether the C compiler needs -belf" >&5
4851echo $ECHO_N "checking whether the C compiler needs -belf... $ECHO_C" >&6
4852if test "${lt_cv_cc_needs_belf+set}" = set; then
4853 echo $ECHO_N "(cached) $ECHO_C" >&6
b2dad0e3 4854else
ff66d28f
PE
4855
4856
3df64633 4857 ac_ext=c
3df64633 4858ac_cpp='$CPP $CPPFLAGS'
ff66d28f
PE
4859ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4860ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4861ac_compiler_gnu=$ac_cv_c_compiler_gnu
4862
3a24bf5d
KC
4863 if test x$gcc_no_link = xyes; then
4864 { { echo "$as_me:$LINENO: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&5
4865echo "$as_me: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&2;}
4866 { (exit 1); exit 1; }; }
4867fi
4868cat >conftest.$ac_ext <<_ACEOF
ff66d28f
PE
4869/* confdefs.h. */
4870_ACEOF
4871cat confdefs.h >>conftest.$ac_ext
4872cat >>conftest.$ac_ext <<_ACEOF
4873/* end confdefs.h. */
3df64633 4874
ff66d28f
PE
4875int
4876main ()
4877{
b2dad0e3 4878
ff66d28f
PE
4879 ;
4880 return 0;
4881}
4882_ACEOF
4883rm -f conftest.$ac_objext conftest$ac_exeext
4884if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
ec2075e9 4885 (eval $ac_link) 2>conftest.er1
ff66d28f 4886 ac_status=$?
ec2075e9
BK
4887 grep -v '^ *+' conftest.er1 >conftest.err
4888 rm -f conftest.er1
4889 cat conftest.err >&5
ff66d28f
PE
4890 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4891 (exit $ac_status); } &&
5b043f08
GK
4892 { ac_try='test -z "$ac_c_werror_flag"
4893 || test ! -s conftest.err'
ec2075e9
BK
4894 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4895 (eval $ac_try) 2>&5
4896 ac_status=$?
4897 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4898 (exit $ac_status); }; } &&
4899 { ac_try='test -s conftest$ac_exeext'
ff66d28f
PE
4900 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4901 (eval $ac_try) 2>&5
4902 ac_status=$?
4903 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4904 (exit $ac_status); }; }; then
b2dad0e3
BK
4905 lt_cv_cc_needs_belf=yes
4906else
ff66d28f
PE
4907 echo "$as_me: failed program was:" >&5
4908sed 's/^/| /' conftest.$ac_ext >&5
4909
4910lt_cv_cc_needs_belf=no
b2dad0e3 4911fi
ec2075e9
BK
4912rm -f conftest.err conftest.$ac_objext \
4913 conftest$ac_exeext conftest.$ac_ext
3df64633 4914 ac_ext=c
3df64633 4915ac_cpp='$CPP $CPPFLAGS'
ff66d28f
PE
4916ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4917ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4918ac_compiler_gnu=$ac_cv_c_compiler_gnu
3df64633 4919
b2dad0e3 4920fi
ff66d28f
PE
4921echo "$as_me:$LINENO: result: $lt_cv_cc_needs_belf" >&5
4922echo "${ECHO_T}$lt_cv_cc_needs_belf" >&6
b2dad0e3
BK
4923 if test x"$lt_cv_cc_needs_belf" != x"yes"; then
4924 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
4925 CFLAGS="$SAVE_CFLAGS"
4926 fi
4927 ;;
4928
4929
4930esac
4931
4932
4933# Save cache, so that ltconfig can load it
ff66d28f 4934cat >confcache <<\_ACEOF
b2dad0e3
BK
4935# This file is a shell script that caches the results of configure
4936# tests run on this system so they can be shared between configure
ff66d28f
PE
4937# scripts and configure runs, see configure's option --config-cache.
4938# It is not useful on other systems. If it contains results you don't
4939# want to keep, you may remove or edit it.
b2dad0e3 4940#
ff66d28f
PE
4941# config.status only pays attention to the cache file if you give it
4942# the --recheck option to rerun configure.
b2dad0e3 4943#
ff66d28f
PE
4944# `ac_cv_env_foo' variables (set or unset) will be overridden when
4945# loading this file, other *unset* `ac_cv_foo' will be assigned the
4946# following values.
4947
4948_ACEOF
4949
b2dad0e3
BK
4950# The following way of writing the cache mishandles newlines in values,
4951# but we know of no workaround that is simple, portable, and efficient.
4952# So, don't put newlines in cache variables' values.
4953# Ultrix sh set writes to stderr and can't be redirected directly,
4954# and sets the high bit in the cache file unless we assign to the vars.
ff66d28f
PE
4955{
4956 (set) 2>&1 |
4957 case `(ac_space=' '; set | grep ac_space) 2>&1` in
4958 *ac_space=\ *)
4959 # `set' does not quote correctly, so add quotes (double-quote
4960 # substitution turns \\\\ into \\, and sed turns \\ into \).
4961 sed -n \
ec2075e9
BK
4962 "s/'/'\\\\''/g;
4963 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
ff66d28f
PE
4964 ;;
4965 *)
4966 # `set' quotes correctly as required by POSIX, so do not add quotes.
4967 sed -n \
ec2075e9 4968 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
ff66d28f
PE
4969 ;;
4970 esac;
4971} |
4972 sed '
4973 t clear
4974 : clear
4975 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
4976 t end
4977 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
4978 : end' >>confcache
4979if diff $cache_file confcache >/dev/null 2>&1; then :; else
b2dad0e3 4980 if test -w $cache_file; then
ff66d28f
PE
4981 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
4982 cat confcache >$cache_file
b2dad0e3
BK
4983 else
4984 echo "not updating unwritable cache $cache_file"
4985 fi
4986fi
4987rm -f confcache
4988
b2dad0e3 4989# Actually configure libtool. ac_aux_dir is where install-sh is found.
3df64633 4990AR="$AR" LTCC="$CC" CC="$CC" CFLAGS="$CFLAGS" CPPFLAGS="$CPPFLAGS" \
3dd7094e 4991MAGIC_CMD="$MAGIC_CMD" LD="$LD" LDFLAGS="$LDFLAGS" LIBS="$LIBS" \
3df64633
AO
4992LN_S="$LN_S" NM="$NM" RANLIB="$RANLIB" STRIP="$STRIP" \
4993AS="$AS" DLLTOOL="$DLLTOOL" OBJDUMP="$OBJDUMP" \
4994objext="$OBJEXT" exeext="$EXEEXT" reload_flag="$reload_flag" \
4995deplibs_check_method="$deplibs_check_method" file_magic_cmd="$file_magic_cmd" \
b2dad0e3 4996${CONFIG_SHELL-/bin/sh} $ac_aux_dir/ltconfig --no-reexec \
3df64633 4997$libtool_flags --no-verify --build="$build" $ac_aux_dir/ltmain.sh $host \
ff66d28f
PE
4998|| { { echo "$as_me:$LINENO: error: libtool configure failed" >&5
4999echo "$as_me: error: libtool configure failed" >&2;}
5000 { (exit 1); exit 1; }; }
b2dad0e3
BK
5001
5002# Reload cache, that may have been modified by ltconfig
5003if test -r "$cache_file"; then
ff66d28f
PE
5004 # Some versions of bash will fail to source /dev/null (special
5005 # files actually), so we avoid doing that.
5006 if test -f "$cache_file"; then
5007 { echo "$as_me:$LINENO: loading cache $cache_file" >&5
5008echo "$as_me: loading cache $cache_file" >&6;}
5009 case $cache_file in
5010 [\\/]* | ?:[\\/]* ) . $cache_file;;
5011 *) . ./$cache_file;;
5012 esac
5013 fi
b2dad0e3 5014else
ff66d28f
PE
5015 { echo "$as_me:$LINENO: creating cache $cache_file" >&5
5016echo "$as_me: creating cache $cache_file" >&6;}
5017 >$cache_file
b2dad0e3
BK
5018fi
5019
5020
5021# This can be used to rebuild libtool when needed
3df64633 5022LIBTOOL_DEPS="$ac_aux_dir/ltconfig $ac_aux_dir/ltmain.sh $ac_aux_dir/ltcf-c.sh"
b2dad0e3
BK
5023
5024# Always use our own libtool.
5025LIBTOOL='$(SHELL) $(top_builddir)/libtool'
5026
5027# Redirect the config.log output again, so that the ltconfig log is not
5028# clobbered by the next message.
5029exec 5>>./config.log
5030
ff66d28f
PE
5031ac_ext=cc
5032ac_cpp='$CXXCPP $CPPFLAGS'
5033ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5034ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5035ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
5036echo "$as_me:$LINENO: checking how to run the C++ preprocessor" >&5
5037echo $ECHO_N "checking how to run the C++ preprocessor... $ECHO_C" >&6
5038if test -z "$CXXCPP"; then
5039 if test "${ac_cv_prog_CXXCPP+set}" = set; then
5040 echo $ECHO_N "(cached) $ECHO_C" >&6
5041else
5042 # Double quotes because CXXCPP needs to be expanded
5043 for CXXCPP in "$CXX -E" "/lib/cpp"
5044 do
5045 ac_preproc_ok=false
5046for ac_cxx_preproc_warn_flag in '' yes
5047do
5048 # Use a header file that comes with gcc, so configuring glibc
5049 # with a fresh cross-compiler works.
5050 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5051 # <limits.h> exists even on freestanding compilers.
5052 # On the NeXT, cc -E runs the code through the compiler's parser,
5053 # not just through cpp. "Syntax error" is here to catch this case.
5054 cat >conftest.$ac_ext <<_ACEOF
ff66d28f
PE
5055/* confdefs.h. */
5056_ACEOF
5057cat confdefs.h >>conftest.$ac_ext
5058cat >>conftest.$ac_ext <<_ACEOF
5059/* end confdefs.h. */
5060#ifdef __STDC__
5061# include <limits.h>
5062#else
5063# include <assert.h>
5064#endif
ec2075e9 5065 Syntax error
ff66d28f
PE
5066_ACEOF
5067if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
5068 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
5069 ac_status=$?
5070 grep -v '^ *+' conftest.er1 >conftest.err
5071 rm -f conftest.er1
5072 cat conftest.err >&5
5073 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5074 (exit $ac_status); } >/dev/null; then
5075 if test -s conftest.err; then
5076 ac_cpp_err=$ac_cxx_preproc_warn_flag
ec2075e9 5077 ac_cpp_err=$ac_cpp_err$ac_cxx_werror_flag
ff66d28f
PE
5078 else
5079 ac_cpp_err=
5080 fi
5081else
5082 ac_cpp_err=yes
5083fi
5084if test -z "$ac_cpp_err"; then
5085 :
5086else
5087 echo "$as_me: failed program was:" >&5
5088sed 's/^/| /' conftest.$ac_ext >&5
5089
5090 # Broken: fails on valid input.
5091continue
5092fi
5093rm -f conftest.err conftest.$ac_ext
5094
5095 # OK, works on sane cases. Now check whether non-existent headers
5096 # can be detected and how.
5097 cat >conftest.$ac_ext <<_ACEOF
ff66d28f
PE
5098/* confdefs.h. */
5099_ACEOF
5100cat confdefs.h >>conftest.$ac_ext
5101cat >>conftest.$ac_ext <<_ACEOF
5102/* end confdefs.h. */
5103#include <ac_nonexistent.h>
5104_ACEOF
5105if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
5106 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
5107 ac_status=$?
5108 grep -v '^ *+' conftest.er1 >conftest.err
5109 rm -f conftest.er1
5110 cat conftest.err >&5
5111 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5112 (exit $ac_status); } >/dev/null; then
5113 if test -s conftest.err; then
5114 ac_cpp_err=$ac_cxx_preproc_warn_flag
ec2075e9 5115 ac_cpp_err=$ac_cpp_err$ac_cxx_werror_flag
ff66d28f
PE
5116 else
5117 ac_cpp_err=
5118 fi
5119else
5120 ac_cpp_err=yes
5121fi
5122if test -z "$ac_cpp_err"; then
5123 # Broken: success on invalid input.
5124continue
5125else
5126 echo "$as_me: failed program was:" >&5
5127sed 's/^/| /' conftest.$ac_ext >&5
5128
5129 # Passes both tests.
5130ac_preproc_ok=:
5131break
5132fi
5133rm -f conftest.err conftest.$ac_ext
5134
5135done
5136# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5137rm -f conftest.err conftest.$ac_ext
5138if $ac_preproc_ok; then
5139 break
5140fi
5141
5142 done
5143 ac_cv_prog_CXXCPP=$CXXCPP
5144
5145fi
5146 CXXCPP=$ac_cv_prog_CXXCPP
5147else
5148 ac_cv_prog_CXXCPP=$CXXCPP
5149fi
5150echo "$as_me:$LINENO: result: $CXXCPP" >&5
5151echo "${ECHO_T}$CXXCPP" >&6
5152ac_preproc_ok=false
5153for ac_cxx_preproc_warn_flag in '' yes
5154do
5155 # Use a header file that comes with gcc, so configuring glibc
5156 # with a fresh cross-compiler works.
5157 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5158 # <limits.h> exists even on freestanding compilers.
5159 # On the NeXT, cc -E runs the code through the compiler's parser,
5160 # not just through cpp. "Syntax error" is here to catch this case.
5161 cat >conftest.$ac_ext <<_ACEOF
ff66d28f
PE
5162/* confdefs.h. */
5163_ACEOF
5164cat confdefs.h >>conftest.$ac_ext
5165cat >>conftest.$ac_ext <<_ACEOF
5166/* end confdefs.h. */
5167#ifdef __STDC__
5168# include <limits.h>
5169#else
5170# include <assert.h>
5171#endif
ec2075e9 5172 Syntax error
ff66d28f
PE
5173_ACEOF
5174if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
5175 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
5176 ac_status=$?
5177 grep -v '^ *+' conftest.er1 >conftest.err
5178 rm -f conftest.er1
5179 cat conftest.err >&5
5180 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5181 (exit $ac_status); } >/dev/null; then
5182 if test -s conftest.err; then
5183 ac_cpp_err=$ac_cxx_preproc_warn_flag
ec2075e9 5184 ac_cpp_err=$ac_cpp_err$ac_cxx_werror_flag
ff66d28f
PE
5185 else
5186 ac_cpp_err=
5187 fi
5188else
5189 ac_cpp_err=yes
5190fi
5191if test -z "$ac_cpp_err"; then
5192 :
5193else
5194 echo "$as_me: failed program was:" >&5
5195sed 's/^/| /' conftest.$ac_ext >&5
5196
5197 # Broken: fails on valid input.
5198continue
5199fi
5200rm -f conftest.err conftest.$ac_ext
5201
5202 # OK, works on sane cases. Now check whether non-existent headers
5203 # can be detected and how.
5204 cat >conftest.$ac_ext <<_ACEOF
ff66d28f
PE
5205/* confdefs.h. */
5206_ACEOF
5207cat confdefs.h >>conftest.$ac_ext
5208cat >>conftest.$ac_ext <<_ACEOF
5209/* end confdefs.h. */
5210#include <ac_nonexistent.h>
5211_ACEOF
5212if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
5213 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
5214 ac_status=$?
5215 grep -v '^ *+' conftest.er1 >conftest.err
5216 rm -f conftest.er1
5217 cat conftest.err >&5
5218 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5219 (exit $ac_status); } >/dev/null; then
5220 if test -s conftest.err; then
5221 ac_cpp_err=$ac_cxx_preproc_warn_flag
ec2075e9 5222 ac_cpp_err=$ac_cpp_err$ac_cxx_werror_flag
ff66d28f
PE
5223 else
5224 ac_cpp_err=
5225 fi
5226else
5227 ac_cpp_err=yes
5228fi
5229if test -z "$ac_cpp_err"; then
5230 # Broken: success on invalid input.
5231continue
5232else
5233 echo "$as_me: failed program was:" >&5
5234sed 's/^/| /' conftest.$ac_ext >&5
5235
5236 # Passes both tests.
5237ac_preproc_ok=:
5238break
5239fi
5240rm -f conftest.err conftest.$ac_ext
5241
5242done
5243# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5244rm -f conftest.err conftest.$ac_ext
5245if $ac_preproc_ok; then
5246 :
5247else
5248 { { echo "$as_me:$LINENO: error: C++ preprocessor \"$CXXCPP\" fails sanity check
5249See \`config.log' for more details." >&5
5250echo "$as_me: error: C++ preprocessor \"$CXXCPP\" fails sanity check
5251See \`config.log' for more details." >&2;}
5252 { (exit 1); exit 1; }; }
5253fi
5254
5255ac_ext=c
5256ac_cpp='$CPP $CPPFLAGS'
5257ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5258ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5259ac_compiler_gnu=$ac_cv_c_compiler_gnu
5260
3df64633
AO
5261
5262
3df64633
AO
5263LIBTOOL_DEPS=$LIBTOOL_DEPS" $ac_aux_dir/ltcf-cxx.sh"
5264lt_save_CC="$CC"
5265lt_save_CFLAGS="$CFLAGS"
5266AR="$AR" LTCC="$CC" CC="$CXX" CXX="$CXX" CFLAGS="$CXXFLAGS" CPPFLAGS="$CPPFLAGS" \
c21b6f87 5267MAGIC_CMD="$MAGIC_CMD" LD="$LD" LDFLAGS="$LDFLAGS" LIBS="$LIBS" \
3df64633
AO
5268LN_S="$LN_S" NM="$NM" RANLIB="$RANLIB" STRIP="$STRIP" \
5269AS="$AS" DLLTOOL="$DLLTOOL" OBJDUMP="$OBJDUMP" \
5270objext="$OBJEXT" exeext="$EXEEXT" reload_flag="$reload_flag" \
5271deplibs_check_method="$deplibs_check_method" \
5272file_magic_cmd="$file_magic_cmd" \
5273${CONFIG_SHELL-/bin/sh} $ac_aux_dir/ltconfig -o libtool $libtool_flags \
5274--build="$build" --add-tag=CXX $ac_aux_dir/ltcf-cxx.sh $host \
ff66d28f
PE
5275|| { { echo "$as_me:$LINENO: error: libtool tag configuration failed" >&5
5276echo "$as_me: error: libtool tag configuration failed" >&2;}
5277 { (exit 1); exit 1; }; }
3df64633
AO
5278CC="$lt_save_CC"
5279CFLAGS="$lt_save_CFLAGS"
5280
5281# Redirect the config.log output again, so that the ltconfig log is not
5282# clobbered by the next message.
5283exec 5>>./config.log
5284
3df64633 5285
34791641
PE
5286
5287
33590f13 5288
ff66d28f
PE
5289
5290
5291
ff66d28f 5292
5f34ed87
BK
5293# Possibly disable most of the library.
5294## TODO: Consider skipping unncessary tests altogether in this case, rather
5295## than just ignoring the results. Faster /and/ more correct, win win.
4ffe6e87 5296
5f34ed87
BK
5297 # Check whether --enable-hosted-libstdcxx or --disable-hosted-libstdcxx was given.
5298if test "${enable_hosted_libstdcxx+set}" = set; then
5299 enableval="$enable_hosted_libstdcxx"
4ffe6e87 5300
4ffe6e87 5301else
5f34ed87
BK
5302 case "$host" in
5303 arm*-*-symbianelf*)
5304 enable_hosted_libstdcxx=no
5305 ;;
5306 *)
5307 enable_hosted_libstdcxx=yes
5308 ;;
5309 esac
4ffe6e87 5310fi;
5f34ed87
BK
5311 if test "$enable_hosted_libstdcxx" = no; then
5312 { echo "$as_me:$LINENO: Only freestanding libraries will be built" >&5
5313echo "$as_me: Only freestanding libraries will be built" >&6;}
5314 is_hosted=no
5315 hosted_define=0
5316 enable_abi_check=no
5317 enable_libstdcxx_pch=no
4ffe6e87 5318 else
5f34ed87
BK
5319 is_hosted=yes
5320 hosted_define=1
4ffe6e87 5321 fi
5f34ed87
BK
5322
5323
5324cat >>confdefs.h <<_ACEOF
5325#define _GLIBCXX_HOSTED $hosted_define
5326_ACEOF
5327
5328
5329
5330# Check for compiler support that doesn't require linking.
5331
5332 echo "$as_me:$LINENO: checking for exception model to use" >&5
5333echo $ECHO_N "checking for exception model to use... $ECHO_C" >&6
5334
5335
5336 ac_ext=cc
5337ac_cpp='$CXXCPP $CPPFLAGS'
5338ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5339ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5340ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
5341
5342 # Check whether --enable-sjlj-exceptions or --disable-sjlj-exceptions was given.
5343if test "${enable_sjlj_exceptions+set}" = set; then
5344 enableval="$enable_sjlj_exceptions"
5345
5346 case "$enableval" in
5347 yes|no|auto) ;;
5348 *) { { echo "$as_me:$LINENO: error: Unknown argument to enable/disable sjlj-exceptions" >&5
5349echo "$as_me: error: Unknown argument to enable/disable sjlj-exceptions" >&2;}
5350 { (exit 1); exit 1; }; } ;;
5351 esac
5352
4ffe6e87 5353else
5f34ed87
BK
5354 enable_sjlj_exceptions=auto
5355fi;
5356
5357
5358 if test $enable_sjlj_exceptions = auto; then
5359 # Botheration. Now we've got to detect the exception model. Link tests
5360 # against libgcc.a are problematic since we've not been given proper -L
5361 # bits for single-tree newlib and libgloss.
5362 #
5363 # Fake what AC_TRY_COMPILE does. XXX Look at redoing this new-style.
5364 cat > conftest.$ac_ext << EOF
5365#line 5365 "configure"
5366struct S { ~S(); };
5367void bar();
5368void foo()
5369{
5370 S s;
5371 bar();
5372}
5373EOF
5374 old_CXXFLAGS="$CXXFLAGS"
5375 CXXFLAGS=-S
5376 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5377 (eval $ac_compile) 2>&5
5378 ac_status=$?
5379 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5380 (exit $ac_status); }; then
5381 if grep _Unwind_SjLj_Resume conftest.s >/dev/null 2>&1 ; then
5382 enable_sjlj_exceptions=yes
5383 elif grep _Unwind_Resume conftest.s >/dev/null 2>&1 ; then
5384 enable_sjlj_exceptions=no
5385 elif grep __cxa_end_cleanup conftest.s >/dev/null 2>&1 ; then
5386 enable_sjlj_exceptions=no
4ffe6e87
BK
5387 fi
5388 fi
5f34ed87
BK
5389 CXXFLAGS="$old_CXXFLAGS"
5390 rm -f conftest*
5391 fi
4ffe6e87 5392
5f34ed87
BK
5393 # This is a tad weird, for hysterical raisins. We have to map
5394 # enable/disable to two different models.
5395 case $enable_sjlj_exceptions in
5396 yes)
5397
5398cat >>confdefs.h <<\_ACEOF
5399#define _GLIBCXX_SJLJ_EXCEPTIONS 1
5400_ACEOF
5401
5402 ac_exception_model_name=sjlj
5403 ;;
5404 no)
5405 ac_exception_model_name="call frame"
5406 ;;
5407 *)
5408 { { echo "$as_me:$LINENO: error: unable to detect exception model" >&5
5409echo "$as_me: error: unable to detect exception model" >&2;}
4ffe6e87 5410 { (exit 1); exit 1; }; }
5f34ed87
BK
5411 ;;
5412 esac
5413 ac_ext=c
5414ac_cpp='$CPP $CPPFLAGS'
5415ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5416ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5417ac_compiler_gnu=$ac_cv_c_compiler_gnu
4ffe6e87 5418
5f34ed87
BK
5419 echo "$as_me:$LINENO: result: $ac_exception_model_name" >&5
5420echo "${ECHO_T}$ac_exception_model_name" >&6
4ffe6e87
BK
5421
5422
5f34ed87
BK
5423 # Check whether --enable-libstdcxx-pch or --disable-libstdcxx-pch was given.
5424if test "${enable_libstdcxx_pch+set}" = set; then
5425 enableval="$enable_libstdcxx_pch"
4ffe6e87 5426
5f34ed87
BK
5427 case "$enableval" in
5428 yes|no) ;;
5429 *) { { echo "$as_me:$LINENO: error: Argument to enable/disable libstdcxx-pch must be yes or no" >&5
5430echo "$as_me: error: Argument to enable/disable libstdcxx-pch must be yes or no" >&2;}
5431 { (exit 1); exit 1; }; } ;;
5432 esac
4ffe6e87 5433
4ffe6e87 5434else
5f34ed87 5435 enable_libstdcxx_pch=$is_hosted
4ffe6e87
BK
5436fi;
5437
5f34ed87
BK
5438 if test $enable_libstdcxx_pch = yes; then
5439 echo "$as_me:$LINENO: checking for compiler with PCH support" >&5
5440echo $ECHO_N "checking for compiler with PCH support... $ECHO_C" >&6
5441if test "${glibcxx_cv_prog_CXX_pch+set}" = set; then
5442 echo $ECHO_N "(cached) $ECHO_C" >&6
5443else
5444 ac_save_CXXFLAGS="$CXXFLAGS"
5445 CXXFLAGS="$CXXFLAGS -Werror -Winvalid-pch -Wno-deprecated"
4ffe6e87
BK
5446
5447
5f34ed87
BK
5448 ac_ext=cc
5449ac_cpp='$CXXCPP $CPPFLAGS'
5450ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5451ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5452ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
4ffe6e87 5453
5f34ed87
BK
5454 echo '#include <math.h>' > conftest.h
5455 if $CXX $CXXFLAGS $CPPFLAGS -x c++-header conftest.h \
5456 -o conftest.h.gch 1>&5 2>&1 &&
5457 echo '#error "pch failed"' > conftest.h &&
5458 echo '#include "conftest.h"' > conftest.cc &&
5459 $CXX -c $CXXFLAGS $CPPFLAGS conftest.cc 1>&5 2>&1 ;
5460 then
5461 glibcxx_cv_prog_CXX_pch=yes
5462 else
5463 glibcxx_cv_prog_CXX_pch=no
5464 fi
5465 rm -f conftest*
5466 CXXFLAGS=$ac_save_CXXFLAGS
5467 ac_ext=c
5468ac_cpp='$CPP $CPPFLAGS'
5469ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5470ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5471ac_compiler_gnu=$ac_cv_c_compiler_gnu
4ffe6e87
BK
5472
5473
5f34ed87
BK
5474fi
5475echo "$as_me:$LINENO: result: $glibcxx_cv_prog_CXX_pch" >&5
5476echo "${ECHO_T}$glibcxx_cv_prog_CXX_pch" >&6
5477 enable_libstdcxx_pch=$glibcxx_cv_prog_CXX_pch
5478 fi
4ffe6e87 5479
5f34ed87
BK
5480 echo "$as_me:$LINENO: checking for enabled PCH" >&5
5481echo $ECHO_N "checking for enabled PCH... $ECHO_C" >&6
5482 echo "$as_me:$LINENO: result: $enable_libstdcxx_pch" >&5
5483echo "${ECHO_T}$enable_libstdcxx_pch" >&6
4ffe6e87 5484
4ffe6e87 5485
5f34ed87
BK
5486 if test $enable_libstdcxx_pch = yes; then
5487 glibcxx_PCHFLAGS="-include bits/stdtr1c++.h"
5488 else
5489 glibcxx_PCHFLAGS=""
5490 fi
4ffe6e87 5491
4ffe6e87
BK
5492
5493
5f34ed87 5494# Enable all the variable C++ runtime options.
4ffe6e87 5495
5f34ed87
BK
5496 echo "$as_me:$LINENO: checking for underlying I/O to use" >&5
5497echo $ECHO_N "checking for underlying I/O to use... $ECHO_C" >&6
5498 # Check whether --enable-cstdio or --disable-cstdio was given.
5499if test "${enable_cstdio+set}" = set; then
5500 enableval="$enable_cstdio"
4ffe6e87 5501
5f34ed87
BK
5502 case "$enableval" in
5503 stdio) ;;
5504 *) { { echo "$as_me:$LINENO: error: Unknown argument to enable/disable cstdio" >&5
5505echo "$as_me: error: Unknown argument to enable/disable cstdio" >&2;}
5506 { (exit 1); exit 1; }; } ;;
5507 esac
4ffe6e87 5508
5f34ed87
BK
5509else
5510 enable_cstdio=stdio
5511fi;
4ffe6e87 5512
4ffe6e87 5513
5f34ed87
BK
5514 # Now that libio has been removed, you can have any color you want as long
5515 # as it's black. This is one big no-op until other packages are added, but
5516 # showing the framework never hurts.
5517 case ${enable_cstdio} in
5518 stdio)
5519 CSTDIO_H=config/io/c_io_stdio.h
5520 BASIC_FILE_H=config/io/basic_file_stdio.h
5521 BASIC_FILE_CC=config/io/basic_file_stdio.cc
5522 echo "$as_me:$LINENO: result: stdio" >&5
5523echo "${ECHO_T}stdio" >&6
5524 ;;
5525 esac
4ffe6e87 5526
4ffe6e87 5527
4ffe6e87 5528
4ffe6e87 5529
4ffe6e87 5530
5f34ed87
BK
5531echo "$as_me:$LINENO: checking for ANSI C header files" >&5
5532echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
5533if test "${ac_cv_header_stdc+set}" = set; then
4ffe6e87
BK
5534 echo $ECHO_N "(cached) $ECHO_C" >&6
5535else
5f34ed87 5536 cat >conftest.$ac_ext <<_ACEOF
4ffe6e87
BK
5537/* confdefs.h. */
5538_ACEOF
5539cat confdefs.h >>conftest.$ac_ext
5540cat >>conftest.$ac_ext <<_ACEOF
5541/* end confdefs.h. */
5542#include <stdlib.h>
5f34ed87
BK
5543#include <stdarg.h>
5544#include <string.h>
5545#include <float.h>
5546
4ffe6e87
BK
5547int
5548main ()
5549{
5f34ed87 5550
4ffe6e87
BK
5551 ;
5552 return 0;
5553}
5554_ACEOF
5f34ed87
BK
5555rm -f conftest.$ac_objext
5556if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5557 (eval $ac_compile) 2>conftest.er1
4ffe6e87
BK
5558 ac_status=$?
5559 grep -v '^ *+' conftest.er1 >conftest.err
5560 rm -f conftest.er1
5561 cat conftest.err >&5
5562 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5563 (exit $ac_status); } &&
5564 { ac_try='test -z "$ac_c_werror_flag"
5565 || test ! -s conftest.err'
5566 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5567 (eval $ac_try) 2>&5
5568 ac_status=$?
5569 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5570 (exit $ac_status); }; } &&
5f34ed87 5571 { ac_try='test -s conftest.$ac_objext'
4ffe6e87
BK
5572 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5573 (eval $ac_try) 2>&5
5574 ac_status=$?
5575 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5576 (exit $ac_status); }; }; then
5f34ed87 5577 ac_cv_header_stdc=yes
4ffe6e87
BK
5578else
5579 echo "$as_me: failed program was:" >&5
5580sed 's/^/| /' conftest.$ac_ext >&5
5581
5f34ed87 5582ac_cv_header_stdc=no
4ffe6e87 5583fi
5f34ed87
BK
5584rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
5585
5586if test $ac_cv_header_stdc = yes; then
5587 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
5588 cat >conftest.$ac_ext <<_ACEOF
5589/* confdefs.h. */
5590_ACEOF
5591cat confdefs.h >>conftest.$ac_ext
5592cat >>conftest.$ac_ext <<_ACEOF
5593/* end confdefs.h. */
5594#include <string.h>
5595
5596_ACEOF
5597if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5598 $EGREP "memchr" >/dev/null 2>&1; then
5599 :
5600else
5601 ac_cv_header_stdc=no
4ffe6e87 5602fi
5f34ed87
BK
5603rm -f conftest*
5604
5605fi
5606
5607if test $ac_cv_header_stdc = yes; then
5608 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
5609 cat >conftest.$ac_ext <<_ACEOF
4ffe6e87
BK
5610/* confdefs.h. */
5611_ACEOF
5612cat confdefs.h >>conftest.$ac_ext
5613cat >>conftest.$ac_ext <<_ACEOF
5614/* end confdefs.h. */
5615#include <stdlib.h>
5f34ed87
BK
5616
5617_ACEOF
5618if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5619 $EGREP "free" >/dev/null 2>&1; then
5620 :
5621else
5622 ac_cv_header_stdc=no
5623fi
5624rm -f conftest*
5625
5626fi
5627
5628if test $ac_cv_header_stdc = yes; then
5629 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
5630 if test "$cross_compiling" = yes; then
5631 :
5632else
5633 cat >conftest.$ac_ext <<_ACEOF
5634/* confdefs.h. */
5635_ACEOF
5636cat confdefs.h >>conftest.$ac_ext
5637cat >>conftest.$ac_ext <<_ACEOF
5638/* end confdefs.h. */
5639#include <ctype.h>
5640#if ((' ' & 0x0FF) == 0x020)
5641# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
5642# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
5643#else
5644# define ISLOWER(c) \
5645 (('a' <= (c) && (c) <= 'i') \
5646 || ('j' <= (c) && (c) <= 'r') \
5647 || ('s' <= (c) && (c) <= 'z'))
5648# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
5649#endif
5650
5651#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4ffe6e87
BK
5652int
5653main ()
5654{
5f34ed87
BK
5655 int i;
5656 for (i = 0; i < 256; i++)
5657 if (XOR (islower (i), ISLOWER (i))
5658 || toupper (i) != TOUPPER (i))
5659 exit(2);
5660 exit (0);
4ffe6e87
BK
5661}
5662_ACEOF
5f34ed87 5663rm -f conftest$ac_exeext
4ffe6e87 5664if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5f34ed87 5665 (eval $ac_link) 2>&5
4ffe6e87
BK
5666 ac_status=$?
5667 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5f34ed87 5668 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4ffe6e87
BK
5669 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5670 (eval $ac_try) 2>&5
5671 ac_status=$?
5672 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5673 (exit $ac_status); }; }; then
5f34ed87 5674 :
4ffe6e87 5675else
5f34ed87
BK
5676 echo "$as_me: program exited with status $ac_status" >&5
5677echo "$as_me: failed program was:" >&5
4ffe6e87
BK
5678sed 's/^/| /' conftest.$ac_ext >&5
5679
5f34ed87
BK
5680( exit $ac_status )
5681ac_cv_header_stdc=no
4ffe6e87 5682fi
5f34ed87 5683rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
4ffe6e87 5684fi
5f34ed87
BK
5685fi
5686fi
5687echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
5688echo "${ECHO_T}$ac_cv_header_stdc" >&6
5689if test $ac_cv_header_stdc = yes; then
4ffe6e87
BK
5690
5691cat >>confdefs.h <<\_ACEOF
5f34ed87 5692#define STDC_HEADERS 1
4ffe6e87
BK
5693_ACEOF
5694
5f34ed87
BK
5695fi
5696
5697# On IRIX 5.3, sys/types and inttypes.h are conflicting.
4ffe6e87
BK
5698
5699
5700
5f34ed87
BK
5701
5702
5703
5704
5705
5706
5707for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
5708 inttypes.h stdint.h unistd.h
5709do
5710as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
5711echo "$as_me:$LINENO: checking for $ac_header" >&5
5712echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5713if eval "test \"\${$as_ac_Header+set}\" = set"; then
4ffe6e87
BK
5714 echo $ECHO_N "(cached) $ECHO_C" >&6
5715else
5f34ed87 5716 cat >conftest.$ac_ext <<_ACEOF
4ffe6e87
BK
5717/* confdefs.h. */
5718_ACEOF
5719cat confdefs.h >>conftest.$ac_ext
5720cat >>conftest.$ac_ext <<_ACEOF
5721/* end confdefs.h. */
5f34ed87 5722$ac_includes_default
4ffe6e87 5723
5f34ed87 5724#include <$ac_header>
4ffe6e87
BK
5725_ACEOF
5726rm -f conftest.$ac_objext
5727if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5728 (eval $ac_compile) 2>conftest.er1
5729 ac_status=$?
5730 grep -v '^ *+' conftest.er1 >conftest.err
5731 rm -f conftest.er1
5732 cat conftest.err >&5
5733 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5734 (exit $ac_status); } &&
5735 { ac_try='test -z "$ac_c_werror_flag"
5736 || test ! -s conftest.err'
5737 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5738 (eval $ac_try) 2>&5
5739 ac_status=$?
5740 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5741 (exit $ac_status); }; } &&
5742 { ac_try='test -s conftest.$ac_objext'
5743 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5744 (eval $ac_try) 2>&5
5745 ac_status=$?
5746 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5747 (exit $ac_status); }; }; then
5f34ed87 5748 eval "$as_ac_Header=yes"
4ffe6e87
BK
5749else
5750 echo "$as_me: failed program was:" >&5
5751sed 's/^/| /' conftest.$ac_ext >&5
5752
5f34ed87 5753eval "$as_ac_Header=no"
4ffe6e87
BK
5754fi
5755rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
4ffe6e87 5756fi
5f34ed87
BK
5757echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
5758echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
5759if test `eval echo '${'$as_ac_Header'}'` = yes; then
5760 cat >>confdefs.h <<_ACEOF
5761#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
5762_ACEOF
4ffe6e87 5763
5f34ed87 5764fi
4ffe6e87 5765
5f34ed87 5766done
4ffe6e87 5767
4ffe6e87
BK
5768
5769
5f34ed87
BK
5770 echo "$as_me:$LINENO: checking for C locale to use" >&5
5771echo $ECHO_N "checking for C locale to use... $ECHO_C" >&6
5772 # Check whether --enable-clocale or --disable-clocale was given.
5773if test "${enable_clocale+set}" = set; then
5774 enableval="$enable_clocale"
92eabea2 5775
5f34ed87
BK
5776 case "$enableval" in
5777 generic|gnu|ieee_1003.1-2001|yes|no|auto) ;;
5778 *) { { echo "$as_me:$LINENO: error: Unknown argument to enable/disable clocale" >&5
5779echo "$as_me: error: Unknown argument to enable/disable clocale" >&2;}
5780 { (exit 1); exit 1; }; } ;;
5781 esac
92eabea2
PE
5782
5783else
5f34ed87 5784 enable_clocale=auto
92eabea2 5785fi;
92eabea2 5786
5780a46b 5787
5f34ed87
BK
5788 # If they didn't use this option switch, or if they specified --enable
5789 # with no specific model, we'll have to look for one. If they
5790 # specified --disable (???), do likewise.
5791 if test $enable_clocale = no || test $enable_clocale = yes; then
5792 enable_clocale=auto
5793 fi
249ed716 5794
5f34ed87
BK
5795 # Either a known package, or "auto"
5796 enable_clocale_flag=$enable_clocale
dd75251f 5797
ff66d28f
PE
5798 # Probe for locale support if no specific model is specified.
5799 # Default to "generic".
5800 if test $enable_clocale_flag = auto; then
7d3998a4
PE
5801 case ${target_os} in
5802 linux* | gnu* | kfreebsd*-gnu | knetbsd*-gnu)
ff66d28f 5803 cat >conftest.$ac_ext <<_ACEOF
ff66d28f
PE
5804/* confdefs.h. */
5805_ACEOF
5806cat confdefs.h >>conftest.$ac_ext
5807cat >>conftest.$ac_ext <<_ACEOF
5808/* end confdefs.h. */
56deb74c
BK
5809
5810 #include <features.h>
37bc6ca2 5811 #if __GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 2)
3d7c150e 5812 _GLIBCXX_ok
56deb74c 5813 #endif
ff66d28f
PE
5814
5815_ACEOF
56deb74c 5816if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
ff66d28f 5817 $EGREP "_GLIBCXX_ok" >/dev/null 2>&1; then
56deb74c
BK
5818 enable_clocale_flag=gnu
5819else
56deb74c
BK
5820 enable_clocale_flag=generic
5821fi
5822rm -f conftest*
5823
1451a492 5824
ff66d28f 5825 # Test for bugs early in glibc-2.2.x series
7d3998a4 5826 if test $enable_clocale_flag = gnu; then
ff66d28f 5827 if test "$cross_compiling" = yes; then
1451a492
BK
5828 enable_clocale_flag=generic
5829else
ff66d28f 5830 cat >conftest.$ac_ext <<_ACEOF
ff66d28f
PE
5831/* confdefs.h. */
5832_ACEOF
5833cat confdefs.h >>conftest.$ac_ext
5834cat >>conftest.$ac_ext <<_ACEOF
5835/* end confdefs.h. */
5836
5837 #define _GNU_SOURCE 1
5838 #include <locale.h>
5839 #include <string.h>
5840 #if __GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ > 2)
5841 extern __typeof(newlocale) __newlocale;
5842 extern __typeof(duplocale) __duplocale;
5843 extern __typeof(strcoll_l) __strcoll_l;
5844 #endif
5845 int main()
5846 {
5847