]> git.ipfire.org Git - thirdparty/gcc.git/blame - libstdc++-v3/configure
move inclusion of signal.h
[thirdparty/gcc.git] / libstdc++-v3 / configure
CommitLineData
b2dad0e3
BK
1#! /bin/sh
2
3# Guess values for system-dependent variables and create Makefiles.
4# Generated automatically using autoconf version 2.13
5# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
6#
7# This configure script is free software; the Free Software Foundation
8# gives unlimited permission to copy, distribute and modify it.
9
10# Defaults:
11ac_help=
12ac_default_prefix=/usr/local
13# Any additions from configure.in:
33590f13
BK
14ac_help="$ac_help
15 --enable-multilib build hella library versions (default)"
b2dad0e3
BK
16ac_help="$ac_help
17 --with-target-subdir=SUBDIR
d2caef2e 18 configuring in a subdirectory"
b2dad0e3
BK
19ac_help="$ac_help
20 --with-cross-host=HOST configuring with a cross compiler"
b2dad0e3
BK
21ac_help="$ac_help
22 --enable-maintainer-mode enable make rules and dependencies not useful
23 (and sometimes confusing) to the casual installer"
24ac_help="$ac_help
25 --enable-shared[=PKGS] build shared libraries [default=yes]"
26ac_help="$ac_help
27 --enable-static[=PKGS] build static libraries [default=yes]"
28ac_help="$ac_help
29 --enable-fast-install[=PKGS] optimize for fast installation [default=yes]"
30ac_help="$ac_help
31 --with-gnu-ld assume the C compiler uses GNU ld [default=no]"
32ac_help="$ac_help
3840fa2a 33 --disable-libtool-lock avoid locking (might break parallel builds)"
3df64633
AO
34ac_help="$ac_help
35 --with-pic try to use only PIC/non-PIC objects [default=use both]"
b2dad0e3
BK
36ac_help="$ac_help
37 --enable-debug extra debugging, turn off optimization [default=no]"
38ac_help="$ac_help
572051a2
PE
39 --enable-cstdio enable stdio for target io package.
40 --enable-cstdio=LIB use LIB target-speific io package. [default=stdio]
36e40658 41 "
0214010c 42ac_help="$ac_help
572051a2
PE
43 --enable-clocale enable model for target locale package.
44 --enable-clocale=MODEL use MODEL target-speific locale package. [default=generic]
0214010c 45 "
501e321e
BK
46ac_help="$ac_help
47 --enable-nls use Native Language Support (default)"
e26cb7ab
MM
48ac_help="$ac_help
49 --enable-c-mbchar enable multibyte (wide) characters [default=yes]"
b2dad0e3 50ac_help="$ac_help
4d16bdbb 51 --enable-c99 turns on 'ISO/IEC 9899:1999 support' [default=yes]"
7cda84dc
BK
52ac_help="$ac_help
53 --enable-long-long turns on 'long long' [default=yes]"
99246c90 54ac_help="$ac_help
572051a2 55 --enable-cheaders construct "C" header files for g++ [default=c_std]"
dcfa0bc8
PE
56ac_help="$ac_help
57 --enable-cxx-flags=FLAGS pass compiler FLAGS when building library;
32a4595e 58 [default=none]"
52a11cbf
RH
59ac_help="$ac_help
60 --enable-sjlj-exceptions force use of builtin_setjmp for exceptions"
263c6fa8
SE
61ac_help="$ac_help
62 --enable-libunwind-exceptions force use of libunwind for exceptions"
4d16bdbb
PE
63ac_help="$ac_help
64 --enable-concept-checks use Boost-derived template checks [default=no]"
530539d9 65ac_help="$ac_help
ab3bc736 66 --enable-symvers=style enables symbol versioning of the shared library [default=yes]"
1fd2f510 67ac_help="$ac_help
572051a2 68 --with-gxx-include-dir the installation directory for include files"
1fd2f510
BK
69ac_help="$ac_help
70 --enable-version-specific-runtime-libs Specify that runtime libraries should be installed in a compiler-specific directory "
b2dad0e3
BK
71
72# Initialize some variables set by options.
73# The variables have the same names as the options, with
74# dashes changed to underlines.
75build=NONE
76cache_file=./config.cache
77exec_prefix=NONE
78host=NONE
79no_create=
80nonopt=NONE
81no_recursion=
82prefix=NONE
83program_prefix=NONE
84program_suffix=NONE
85program_transform_name=s,x,x,
86silent=
87site=
88srcdir=
89target=NONE
90verbose=
91x_includes=NONE
92x_libraries=NONE
93bindir='${exec_prefix}/bin'
94sbindir='${exec_prefix}/sbin'
95libexecdir='${exec_prefix}/libexec'
96datadir='${prefix}/share'
97sysconfdir='${prefix}/etc'
98sharedstatedir='${prefix}/com'
99localstatedir='${prefix}/var'
100libdir='${exec_prefix}/lib'
101includedir='${prefix}/include'
102oldincludedir='/usr/include'
103infodir='${prefix}/info'
104mandir='${prefix}/man'
105
106# Initialize some other variables.
107subdirs=
108MFLAGS= MAKEFLAGS=
109SHELL=${CONFIG_SHELL-/bin/sh}
110# Maximum number of lines to put in a shell here document.
111ac_max_here_lines=12
112
113ac_prev=
114for ac_option
115do
116
117 # If the previous option needs an argument, assign it.
118 if test -n "$ac_prev"; then
119 eval "$ac_prev=\$ac_option"
120 ac_prev=
121 continue
122 fi
123
124 case "$ac_option" in
125 -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
126 *) ac_optarg= ;;
127 esac
128
129 # Accept the important Cygnus configure options, so we can diagnose typos.
130
131 case "$ac_option" in
132
133 -bindir | --bindir | --bindi | --bind | --bin | --bi)
134 ac_prev=bindir ;;
135 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
136 bindir="$ac_optarg" ;;
137
138 -build | --build | --buil | --bui | --bu)
139 ac_prev=build ;;
140 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
141 build="$ac_optarg" ;;
142
143 -cache-file | --cache-file | --cache-fil | --cache-fi \
144 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
145 ac_prev=cache_file ;;
146 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
147 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
148 cache_file="$ac_optarg" ;;
149
150 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
151 ac_prev=datadir ;;
152 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
153 | --da=*)
154 datadir="$ac_optarg" ;;
155
156 -disable-* | --disable-*)
157 ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
158 # Reject names that are not valid shell variable names.
159 if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
160 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
161 fi
162 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
163 eval "enable_${ac_feature}=no" ;;
164
165 -enable-* | --enable-*)
166 ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
167 # Reject names that are not valid shell variable names.
168 if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
169 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
170 fi
171 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
172 case "$ac_option" in
173 *=*) ;;
174 *) ac_optarg=yes ;;
175 esac
176 eval "enable_${ac_feature}='$ac_optarg'" ;;
177
178 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
179 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
180 | --exec | --exe | --ex)
181 ac_prev=exec_prefix ;;
182 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
183 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
184 | --exec=* | --exe=* | --ex=*)
185 exec_prefix="$ac_optarg" ;;
186
187 -gas | --gas | --ga | --g)
188 # Obsolete; use --with-gas.
189 with_gas=yes ;;
190
191 -help | --help | --hel | --he)
192 # Omit some internal or obsolete options to make the list less imposing.
193 # This message is too long to be a string in the A/UX 3.1 sh.
194 cat << EOF
195Usage: configure [options] [host]
196Options: [defaults in brackets after descriptions]
197Configuration:
198 --cache-file=FILE cache test results in FILE
199 --help print this message
200 --no-create do not create output files
201 --quiet, --silent do not print \`checking...' messages
202 --version print the version of autoconf that created configure
203Directory and file names:
204 --prefix=PREFIX install architecture-independent files in PREFIX
205 [$ac_default_prefix]
206 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
207 [same as prefix]
208 --bindir=DIR user executables in DIR [EPREFIX/bin]
209 --sbindir=DIR system admin executables in DIR [EPREFIX/sbin]
210 --libexecdir=DIR program executables in DIR [EPREFIX/libexec]
211 --datadir=DIR read-only architecture-independent data in DIR
212 [PREFIX/share]
213 --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc]
214 --sharedstatedir=DIR modifiable architecture-independent data in DIR
215 [PREFIX/com]
216 --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var]
217 --libdir=DIR object code libraries in DIR [EPREFIX/lib]
218 --includedir=DIR C header files in DIR [PREFIX/include]
219 --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include]
220 --infodir=DIR info documentation in DIR [PREFIX/info]
221 --mandir=DIR man documentation in DIR [PREFIX/man]
222 --srcdir=DIR find the sources in DIR [configure dir or ..]
223 --program-prefix=PREFIX prepend PREFIX to installed program names
224 --program-suffix=SUFFIX append SUFFIX to installed program names
225 --program-transform-name=PROGRAM
226 run sed PROGRAM on installed program names
227EOF
228 cat << EOF
229Host type:
230 --build=BUILD configure for building on BUILD [BUILD=HOST]
231 --host=HOST configure for HOST [guessed]
232 --target=TARGET configure for TARGET [TARGET=HOST]
233Features and packages:
234 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
235 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
236 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
237 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
238 --x-includes=DIR X include files are in DIR
239 --x-libraries=DIR X library files are in DIR
240EOF
241 if test -n "$ac_help"; then
242 echo "--enable and --with options recognized:$ac_help"
243 fi
244 exit 0 ;;
245
246 -host | --host | --hos | --ho)
247 ac_prev=host ;;
248 -host=* | --host=* | --hos=* | --ho=*)
249 host="$ac_optarg" ;;
250
251 -includedir | --includedir | --includedi | --included | --include \
252 | --includ | --inclu | --incl | --inc)
253 ac_prev=includedir ;;
254 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
255 | --includ=* | --inclu=* | --incl=* | --inc=*)
256 includedir="$ac_optarg" ;;
257
258 -infodir | --infodir | --infodi | --infod | --info | --inf)
259 ac_prev=infodir ;;
260 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
261 infodir="$ac_optarg" ;;
262
263 -libdir | --libdir | --libdi | --libd)
264 ac_prev=libdir ;;
265 -libdir=* | --libdir=* | --libdi=* | --libd=*)
266 libdir="$ac_optarg" ;;
267
268 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
269 | --libexe | --libex | --libe)
270 ac_prev=libexecdir ;;
271 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
272 | --libexe=* | --libex=* | --libe=*)
273 libexecdir="$ac_optarg" ;;
274
275 -localstatedir | --localstatedir | --localstatedi | --localstated \
276 | --localstate | --localstat | --localsta | --localst \
277 | --locals | --local | --loca | --loc | --lo)
278 ac_prev=localstatedir ;;
279 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
280 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
281 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
282 localstatedir="$ac_optarg" ;;
283
284 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
285 ac_prev=mandir ;;
286 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
287 mandir="$ac_optarg" ;;
288
289 -nfp | --nfp | --nf)
290 # Obsolete; use --without-fp.
291 with_fp=no ;;
292
293 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
294 | --no-cr | --no-c)
295 no_create=yes ;;
296
297 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
298 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
299 no_recursion=yes ;;
300
301 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
302 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
303 | --oldin | --oldi | --old | --ol | --o)
304 ac_prev=oldincludedir ;;
305 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
306 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
307 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
308 oldincludedir="$ac_optarg" ;;
309
310 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
311 ac_prev=prefix ;;
312 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
313 prefix="$ac_optarg" ;;
314
315 -program-prefix | --program-prefix | --program-prefi | --program-pref \
316 | --program-pre | --program-pr | --program-p)
317 ac_prev=program_prefix ;;
318 -program-prefix=* | --program-prefix=* | --program-prefi=* \
319 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
320 program_prefix="$ac_optarg" ;;
321
322 -program-suffix | --program-suffix | --program-suffi | --program-suff \
323 | --program-suf | --program-su | --program-s)
324 ac_prev=program_suffix ;;
325 -program-suffix=* | --program-suffix=* | --program-suffi=* \
326 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
327 program_suffix="$ac_optarg" ;;
328
329 -program-transform-name | --program-transform-name \
330 | --program-transform-nam | --program-transform-na \
331 | --program-transform-n | --program-transform- \
332 | --program-transform | --program-transfor \
333 | --program-transfo | --program-transf \
334 | --program-trans | --program-tran \
335 | --progr-tra | --program-tr | --program-t)
336 ac_prev=program_transform_name ;;
337 -program-transform-name=* | --program-transform-name=* \
338 | --program-transform-nam=* | --program-transform-na=* \
339 | --program-transform-n=* | --program-transform-=* \
340 | --program-transform=* | --program-transfor=* \
341 | --program-transfo=* | --program-transf=* \
342 | --program-trans=* | --program-tran=* \
343 | --progr-tra=* | --program-tr=* | --program-t=*)
344 program_transform_name="$ac_optarg" ;;
345
346 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
347 | -silent | --silent | --silen | --sile | --sil)
348 silent=yes ;;
349
350 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
351 ac_prev=sbindir ;;
352 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
353 | --sbi=* | --sb=*)
354 sbindir="$ac_optarg" ;;
355
356 -sharedstatedir | --sharedstatedir | --sharedstatedi \
357 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
358 | --sharedst | --shareds | --shared | --share | --shar \
359 | --sha | --sh)
360 ac_prev=sharedstatedir ;;
361 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
362 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
363 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
364 | --sha=* | --sh=*)
365 sharedstatedir="$ac_optarg" ;;
366
367 -site | --site | --sit)
368 ac_prev=site ;;
369 -site=* | --site=* | --sit=*)
370 site="$ac_optarg" ;;
371
372 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
373 ac_prev=srcdir ;;
374 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
375 srcdir="$ac_optarg" ;;
376
377 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
378 | --syscon | --sysco | --sysc | --sys | --sy)
379 ac_prev=sysconfdir ;;
380 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
381 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
382 sysconfdir="$ac_optarg" ;;
383
384 -target | --target | --targe | --targ | --tar | --ta | --t)
385 ac_prev=target ;;
386 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
387 target="$ac_optarg" ;;
388
389 -v | -verbose | --verbose | --verbos | --verbo | --verb)
390 verbose=yes ;;
391
392 -version | --version | --versio | --versi | --vers)
393 echo "configure generated by autoconf version 2.13"
394 exit 0 ;;
395
396 -with-* | --with-*)
397 ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
398 # Reject names that are not valid shell variable names.
399 if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
400 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
401 fi
402 ac_package=`echo $ac_package| sed 's/-/_/g'`
403 case "$ac_option" in
404 *=*) ;;
405 *) ac_optarg=yes ;;
406 esac
407 eval "with_${ac_package}='$ac_optarg'" ;;
408
409 -without-* | --without-*)
410 ac_package=`echo $ac_option|sed -e 's/-*without-//'`
411 # Reject names that are not valid shell variable names.
412 if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
413 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
414 fi
415 ac_package=`echo $ac_package| sed 's/-/_/g'`
416 eval "with_${ac_package}=no" ;;
417
418 --x)
419 # Obsolete; use --with-x.
420 with_x=yes ;;
421
422 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
423 | --x-incl | --x-inc | --x-in | --x-i)
424 ac_prev=x_includes ;;
425 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
426 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
427 x_includes="$ac_optarg" ;;
428
429 -x-libraries | --x-libraries | --x-librarie | --x-librari \
430 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
431 ac_prev=x_libraries ;;
432 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
433 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
434 x_libraries="$ac_optarg" ;;
435
436 -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
437 ;;
438
439 *)
440 if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
441 echo "configure: warning: $ac_option: invalid host type" 1>&2
442 fi
443 if test "x$nonopt" != xNONE; then
444 { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
445 fi
446 nonopt="$ac_option"
447 ;;
448
449 esac
450done
451
452if test -n "$ac_prev"; then
453 { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
454fi
455
456trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
457
458# File descriptor usage:
459# 0 standard input
460# 1 file creation
461# 2 errors and warnings
462# 3 some systems may open it to /dev/tty
463# 4 used on the Kubota Titan
464# 6 checking for... messages and results
465# 5 compiler messages saved in config.log
466if test "$silent" = yes; then
467 exec 6>/dev/null
468else
469 exec 6>&1
470fi
471exec 5>./config.log
472
473echo "\
474This file contains any messages produced by compilers while
475running configure, to aid debugging if configure makes a mistake.
476" 1>&5
477
478# Strip out --no-create and --no-recursion so they do not pile up.
479# Also quote any args containing shell metacharacters.
480ac_configure_args=
481for ac_arg
482do
483 case "$ac_arg" in
484 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
485 | --no-cr | --no-c) ;;
486 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
487 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
488 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
489 ac_configure_args="$ac_configure_args '$ac_arg'" ;;
490 *) ac_configure_args="$ac_configure_args $ac_arg" ;;
491 esac
492done
493
494# NLS nuisances.
495# Only set these to C if already set. These must not be set unconditionally
496# because not all systems understand e.g. LANG=C (notably SCO).
497# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
498# Non-C LC_CTYPE values break the ctype check.
499if test "${LANG+set}" = set; then LANG=C; export LANG; fi
500if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
501if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
502if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi
503
504# confdefs.h avoids OS command line length limits that DEFS can exceed.
505rm -rf conftest* confdefs.h
506# AIX cpp loses on an empty file, so make sure it contains at least a newline.
507echo > confdefs.h
508
509# A filename unique to this package, relative to the directory that
510# configure is in, which we can look for to find out if srcdir is correct.
1228c7b6 511ac_unique_file=src/ios.cc
b2dad0e3
BK
512
513# Find the source files, if location was not specified.
514if test -z "$srcdir"; then
515 ac_srcdir_defaulted=yes
516 # Try the directory containing this script, then its parent.
517 ac_prog=$0
518 ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
519 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
520 srcdir=$ac_confdir
521 if test ! -r $srcdir/$ac_unique_file; then
522 srcdir=..
523 fi
524else
525 ac_srcdir_defaulted=no
526fi
527if test ! -r $srcdir/$ac_unique_file; then
528 if test "$ac_srcdir_defaulted" = yes; then
529 { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
530 else
531 { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
532 fi
533fi
534srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
535
536# Prefer explicitly selected file to automatically selected ones.
a0f27776
PE
537if test -z "$CONFIG_SITE"; then
538 if test "x$prefix" != xNONE; then
539 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
540 else
541 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
b2dad0e3
BK
542 fi
543fi
544for ac_site_file in $CONFIG_SITE; do
545 if test -r "$ac_site_file"; then
546 echo "loading site script $ac_site_file"
547 . "$ac_site_file"
548 fi
549done
550
551if test -r "$cache_file"; then
552 echo "loading cache $cache_file"
553 . $cache_file
554else
555 echo "creating cache $cache_file"
556 > $cache_file
557fi
558
559ac_ext=c
560# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
561ac_cpp='$CPP $CPPFLAGS'
562ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
563ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
564cross_compiling=$ac_cv_prog_cc_cross
565
566ac_exeext=
567ac_objext=o
568if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
569 # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
570 if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
571 ac_n= ac_c='
572' ac_t=' '
573 else
574 ac_n=-n ac_c= ac_t=
575 fi
576else
577 ac_n= ac_c='\c' ac_t=
578fi
579
580
e2c20fae 581
6706f116
AO
582# This works around the fact that libtool configuration may change LD
583# for this particular configuration, but some shells, instead of
584# keeping the changes in LD private, export them just because LD is
2c839a4e 585# exported. Only used at the end of this file.
6706f116
AO
586ORIGINAL_LD_FOR_MULTILIBS=$LD
587
33590f13 588PACKAGE=libstdc++
33590f13 589
4e10943d 590# For libtool versioning info, format is CURRENT:REVISION:AGE
8d9872d2 591libtool_VERSION=5:2:0
33590f13
BK
592
593
aebb8c22
DD
594
595 # Check whether --enable-multilib or --disable-multilib was given.
596if test "${enable_multilib+set}" = set; then
597 enableval="$enable_multilib"
598 case "${enableval}" in
599 yes) multilib=yes ;;
600 no) multilib=no ;;
601 *) { echo "configure: error: bad value ${enableval} for multilib option" 1>&2; exit 1; } ;;
602 esac
603else
604 multilib=yes
605fi
606
607 # When building with srcdir == objdir, links to the source files will
608 # be created in directories within the target_subdir. We have to
609 # adjust toplevel_srcdir accordingly, so that configure finds
610 # install-sh and other auxiliary files that live in the top-level
611 # source directory.
612 if test "${srcdir}" = "."; then
613 if test -z "${with_target_subdir}"; then
614 toprel=".."
615 else
616 if test "${with_target_subdir}" != "."; then
617 toprel="${with_multisrctop}../.."
618 else
619 toprel="${with_multisrctop}.."
620 fi
621 fi
622 else
623 toprel=".."
624 fi
625 ac_aux_dir=
626for ac_dir in ${srcdir}/$toprel $srcdir/${srcdir}/$toprel; do
b2dad0e3
BK
627 if test -f $ac_dir/install-sh; then
628 ac_aux_dir=$ac_dir
629 ac_install_sh="$ac_aux_dir/install-sh -c"
630 break
631 elif test -f $ac_dir/install.sh; then
632 ac_aux_dir=$ac_dir
633 ac_install_sh="$ac_aux_dir/install.sh -c"
634 break
635 fi
636done
637if test -z "$ac_aux_dir"; then
aebb8c22 638 { echo "configure: error: can not find install-sh or install.sh in ${srcdir}/$toprel $srcdir/${srcdir}/$toprel" 1>&2; exit 1; }
b2dad0e3
BK
639fi
640ac_config_guess=$ac_aux_dir/config.guess
641ac_config_sub=$ac_aux_dir/config.sub
642ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
643
aebb8c22
DD
644 toplevel_srcdir=\${top_srcdir}/$toprel
645
646
647
648# Gets build, host, target, *_vendor, *_cpu, *_os, etc.
649#
650# You will slowly go insane if you do not grok the following fact: when
651# building v3 as part of the compiler, the top-level /target/ becomes the
652# library's /host/. `configure' then causes --target to default to --host,
653# exactly like any other package using autoconf. Therefore, 'target' and
654# 'host' will always be the same. This makes sense both for native and
655# cross compilers, just think about it for a little while. :-)
656#
657# Also, if v3 is being configured as part of a cross compiler, the top-level
658# configure script will pass the "real" host as $with_cross_host.
659#
660# AC 2.5x sets target_alias iff the user specified --target, but we use it
661# everywhere, so we set it here just to be sure. In AC 2.13
662# AC_CANONICAL_TARGET was known as AC_CANONICAL_SYSTEM.
b2dad0e3
BK
663
664# Do some error checking and defaulting for the host and target type.
665# The inputs are:
666# configure --host=HOST --target=TARGET --build=BUILD NONOPT
667#
668# The rules are:
669# 1. You are not allowed to specify --host, --target, and nonopt at the
670# same time.
671# 2. Host defaults to nonopt.
672# 3. If nonopt is not specified, then host defaults to the current host,
673# as determined by config.guess.
674# 4. Target and build default to nonopt.
675# 5. If nonopt is not specified, then target and build default to host.
676
677# The aliases save the names the user supplied, while $host etc.
678# will get canonicalized.
679case $host---$target---$nonopt in
680NONE---*---* | *---NONE---* | *---*---NONE) ;;
681*) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;;
682esac
683
684
685# Make sure we can run config.sub.
686if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
687else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
688fi
689
690echo $ac_n "checking host system type""... $ac_c" 1>&6
a0f27776 691echo "configure:692: checking host system type" >&5
b2dad0e3
BK
692
693host_alias=$host
694case "$host_alias" in
695NONE)
696 case $nonopt in
697 NONE)
698 if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
699 else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
700 fi ;;
701 *) host_alias=$nonopt ;;
702 esac ;;
703esac
704
705host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
706host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
707host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
708host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
709echo "$ac_t""$host" 1>&6
710
711echo $ac_n "checking target system type""... $ac_c" 1>&6
a0f27776 712echo "configure:713: checking target system type" >&5
b2dad0e3
BK
713
714target_alias=$target
715case "$target_alias" in
716NONE)
717 case $nonopt in
718 NONE) target_alias=$host_alias ;;
719 *) target_alias=$nonopt ;;
720 esac ;;
721esac
722
723target=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $target_alias`
724target_cpu=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
725target_vendor=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
726target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
727echo "$ac_t""$target" 1>&6
728
729echo $ac_n "checking build system type""... $ac_c" 1>&6
a0f27776 730echo "configure:731: checking build system type" >&5
b2dad0e3
BK
731
732build_alias=$build
733case "$build_alias" in
734NONE)
735 case $nonopt in
736 NONE) build_alias=$host_alias ;;
737 *) build_alias=$nonopt ;;
738 esac ;;
739esac
740
741build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias`
742build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
743build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
744build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
745echo "$ac_t""$build" 1>&6
746
747test "$host_alias" != "$target_alias" &&
748 test "$program_prefix$program_suffix$program_transform_name" = \
749 NONENONEs,x,x, &&
750 program_prefix=${target_alias}-
751
52b55e7d
PE
752target_alias=${target_alias-$target}
753
b2dad0e3 754
2c839a4e
PE
755# Runs configure.target, finds CC, CXX and assorted other critical bits.
756# Must run this before the GLIBCPP_ENABLE_* macros below.
33590f13
BK
757if test $host != $build; then
758 ac_tool_prefix=${host_alias}-
759else
760 ac_tool_prefix=
761fi
b2dad0e3 762
33590f13 763echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
a0f27776 764echo "configure:765: checking for Cygwin environment" >&5
33590f13 765if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
b2dad0e3
BK
766 echo $ac_n "(cached) $ac_c" 1>&6
767else
33590f13 768 cat > conftest.$ac_ext <<EOF
a0f27776 769#line 770 "configure"
33590f13
BK
770#include "confdefs.h"
771
772int main() {
773
774#ifndef __CYGWIN__
775#define __CYGWIN__ __CYGWIN32__
776#endif
777return __CYGWIN__;
778; return 0; }
779EOF
a0f27776 780if { (eval echo configure:781: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
33590f13
BK
781 rm -rf conftest*
782 ac_cv_cygwin=yes
b2dad0e3 783else
33590f13
BK
784 echo "configure: failed program was:" >&5
785 cat conftest.$ac_ext >&5
786 rm -rf conftest*
787 ac_cv_cygwin=no
b2dad0e3 788fi
33590f13
BK
789rm -f conftest*
790rm -f conftest*
b2dad0e3
BK
791fi
792
33590f13
BK
793echo "$ac_t""$ac_cv_cygwin" 1>&6
794CYGWIN=
795test "$ac_cv_cygwin" = yes && CYGWIN=yes
796echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
a0f27776 797echo "configure:798: checking for mingw32 environment" >&5
33590f13 798if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
b2dad0e3
BK
799 echo $ac_n "(cached) $ac_c" 1>&6
800else
33590f13 801 cat > conftest.$ac_ext <<EOF
a0f27776 802#line 803 "configure"
33590f13
BK
803#include "confdefs.h"
804
805int main() {
806return __MINGW32__;
807; return 0; }
808EOF
a0f27776 809if { (eval echo configure:810: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
33590f13
BK
810 rm -rf conftest*
811 ac_cv_mingw32=yes
b2dad0e3 812else
33590f13
BK
813 echo "configure: failed program was:" >&5
814 cat conftest.$ac_ext >&5
815 rm -rf conftest*
816 ac_cv_mingw32=no
817fi
818rm -f conftest*
819rm -f conftest*
820fi
821
822echo "$ac_t""$ac_cv_mingw32" 1>&6
823MINGW32=
824test "$ac_cv_mingw32" = yes && MINGW32=yes
825
d2caef2e
PE
826 # Export build and source directories.
827 # These need to be absolute paths, yet at the same time need to
828 # canonicalize only relative paths, because then amd will not unmount
829 # drives. Thus the use of PWDCMD: set it to 'pawd' or 'amq -w' if using amd.
1e6347d8 830 glibcpp_builddir=`${PWDCMD-pwd}`
d2caef2e
PE
831 case $srcdir in
832 \\/$* | ?:\\/*) glibcpp_srcdir=${srcdir} ;;
833 *) glibcpp_srcdir=`cd "$srcdir" && ${PWDCMD-pwd} || echo "$srcdir"` ;;
834 esac
835
836
33590f13 837
d2caef2e 838
33590f13 839
162c7cd9 840 for ac_prog in gawk mawk nawk awk
c98b201b
PE
841do
842# Extract the first word of "$ac_prog", so it can be a program name with args.
843set dummy $ac_prog; ac_word=$2
844echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
a0f27776 845echo "configure:846: checking for $ac_word" >&5
c98b201b
PE
846if eval "test \"`echo '$''{'ac_cv_prog_AWK'+set}'`\" = set"; then
847 echo $ac_n "(cached) $ac_c" 1>&6
848else
849 if test -n "$AWK"; then
850 ac_cv_prog_AWK="$AWK" # Let the user override the test.
851else
852 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
853 ac_dummy="$PATH"
854 for ac_dir in $ac_dummy; do
855 test -z "$ac_dir" && ac_dir=.
856 if test -f $ac_dir/$ac_word; then
857 ac_cv_prog_AWK="$ac_prog"
858 break
859 fi
860 done
861 IFS="$ac_save_ifs"
862fi
863fi
864AWK="$ac_cv_prog_AWK"
865if test -n "$AWK"; then
866 echo "$ac_t""$AWK" 1>&6
867else
868 echo "$ac_t""no" 1>&6
869fi
870
871test -n "$AWK" && break
872done
873
d2caef2e 874 # Will set LN_S to either 'ln -s' or 'ln'. With autoconf 2.5x, can also
2c839a4e
PE
875 # be 'cp -p' if linking isn't available. Uncomment the next line to
876 # force a particular method.
d2caef2e
PE
877 #ac_cv_prog_LN_S='cp -p'
878 echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
a0f27776 879echo "configure:880: checking whether ln -s works" >&5
33590f13
BK
880if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
881 echo $ac_n "(cached) $ac_c" 1>&6
882else
883 rm -f conftestdata
884if ln -s X conftestdata 2>/dev/null
885then
886 rm -f conftestdata
887 ac_cv_prog_LN_S="ln -s"
888else
889 ac_cv_prog_LN_S=ln
890fi
891fi
892LN_S="$ac_cv_prog_LN_S"
893if test "$ac_cv_prog_LN_S" = "ln -s"; then
894 echo "$ac_t""yes" 1>&6
895else
896 echo "$ac_t""no" 1>&6
897fi
898
899
d2caef2e
PE
900 # We use these options to decide which functions to include.
901 # Check whether --with-target-subdir or --without-target-subdir was given.
33590f13
BK
902if test "${with_target_subdir+set}" = set; then
903 withval="$with_target_subdir"
904 :
905fi
906
d2caef2e 907 # Check whether --with-cross-host or --without-cross-host was given.
33590f13
BK
908if test "${with_cross_host+set}" = set; then
909 withval="$with_cross_host"
910 :
911fi
912
913
914 glibcpp_basedir=$srcdir/$toprel/./libstdc++-v3
915
916
917 # Never versions of autoconf add an underscore to these functions.
918 # Prevent future problems ...
919
920
921
922
923
d2caef2e
PE
924 # AC_PROG_CC
925 # FIXME: We temporarily define our own version of AC_PROG_CC. This is
926 # copied from autoconf 2.12, but does not call AC_PROG_CC_WORKS. We
927 # are probably using a cross compiler, which will not be able to fully
928 # link an executable. This is addressed in later versions of autoconf.
33590f13 929
d2caef2e 930
33590f13 931
d2caef2e
PE
932
933 # Extract the first word of "gcc", so it can be a program name with args.
33590f13
BK
934set dummy gcc; ac_word=$2
935echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
a0f27776 936echo "configure:937: checking for $ac_word" >&5
33590f13
BK
937if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
938 echo $ac_n "(cached) $ac_c" 1>&6
939else
940 if test -n "$CC"; then
941 ac_cv_prog_CC="$CC" # Let the user override the test.
942else
943 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
944 ac_dummy="$PATH"
945 for ac_dir in $ac_dummy; do
946 test -z "$ac_dir" && ac_dir=.
947 if test -f $ac_dir/$ac_word; then
948 ac_cv_prog_CC="gcc"
949 break
950 fi
951 done
952 IFS="$ac_save_ifs"
953fi
954fi
955CC="$ac_cv_prog_CC"
956if test -n "$CC"; then
957 echo "$ac_t""$CC" 1>&6
958else
959 echo "$ac_t""no" 1>&6
960fi
961
d2caef2e
PE
962 if test -z "$CC"; then
963 # Extract the first word of "cc", so it can be a program name with args.
33590f13
BK
964set dummy cc; ac_word=$2
965echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
a0f27776 966echo "configure:967: checking for $ac_word" >&5
33590f13
BK
967if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
968 echo $ac_n "(cached) $ac_c" 1>&6
969else
970 if test -n "$CC"; then
971 ac_cv_prog_CC="$CC" # Let the user override the test.
972else
973 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
974 ac_prog_rejected=no
975 ac_dummy="$PATH"
976 for ac_dir in $ac_dummy; do
977 test -z "$ac_dir" && ac_dir=.
978 if test -f $ac_dir/$ac_word; then
979 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
980 ac_prog_rejected=yes
981 continue
b2dad0e3
BK
982 fi
983 ac_cv_prog_CC="cc"
984 break
985 fi
986 done
987 IFS="$ac_save_ifs"
988if test $ac_prog_rejected = yes; then
989 # We found a bogon in the path, so make sure we never use it.
990 set dummy $ac_cv_prog_CC
991 shift
992 if test $# -gt 0; then
993 # We chose a different compiler from the bogus one.
994 # However, it has the same basename, so the bogon will be chosen
995 # first if we set CC to just the basename; use the full file name.
996 shift
997 set dummy "$ac_dir/$ac_word" "$@"
998 shift
999 ac_cv_prog_CC="$@"
1000 fi
1001fi
1002fi
1003fi
1004CC="$ac_cv_prog_CC"
1005if test -n "$CC"; then
1006 echo "$ac_t""$CC" 1>&6
1007else
1008 echo "$ac_t""no" 1>&6
1009fi
1010
d2caef2e
PE
1011 test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
1012 fi
b2dad0e3 1013
d2caef2e 1014 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
a0f27776 1015echo "configure:1016: checking whether we are using GNU C" >&5
b2dad0e3
BK
1016if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
1017 echo $ac_n "(cached) $ac_c" 1>&6
1018else
1019 cat > conftest.c <<EOF
1020#ifdef __GNUC__
1021 yes;
1022#endif
1023EOF
a0f27776 1024if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1025: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
b2dad0e3
BK
1025 ac_cv_prog_gcc=yes
1026else
1027 ac_cv_prog_gcc=no
1028fi
1029fi
1030
1031echo "$ac_t""$ac_cv_prog_gcc" 1>&6
1032
d2caef2e
PE
1033 if test $ac_cv_prog_gcc = yes; then
1034 GCC=yes
1035 ac_test_CFLAGS="${CFLAGS+set}"
1036 ac_save_CFLAGS="$CFLAGS"
1037 CFLAGS=
1038 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
a0f27776 1039echo "configure:1040: checking whether ${CC-cc} accepts -g" >&5
b2dad0e3
BK
1040if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
1041 echo $ac_n "(cached) $ac_c" 1>&6
1042else
1043 echo 'void f(){}' > conftest.c
1044if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
1045 ac_cv_prog_cc_g=yes
1046else
1047 ac_cv_prog_cc_g=no
1048fi
1049rm -f conftest*
1050
1051fi
1052
1053echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
d2caef2e
PE
1054 if test "$ac_test_CFLAGS" = set; then
1055 CFLAGS="$ac_save_CFLAGS"
1056 elif test $ac_cv_prog_cc_g = yes; then
1057 CFLAGS="-g -O2"
1058 else
1059 CFLAGS="-O2"
1060 fi
b2dad0e3 1061 else
d2caef2e
PE
1062 GCC=
1063 test "${CFLAGS+set}" = set || CFLAGS="-g"
b2dad0e3 1064 fi
d2caef2e 1065
b2dad0e3 1066
d2caef2e
PE
1067 # Likewise for AC_PROG_CXX. We can't just call it directly because g++
1068 # will try to link in libstdc++.
1069
b2dad0e3 1070
d2caef2e
PE
1071
1072 # Use glibcpp_CXX so that we do not cause CXX to be cached with the
1073 # flags that come in CXX while configuring libstdc++. They're different
1074 # from those used for all other target libraries. If CXX is set in
1075 # the environment, respect that here.
1076 glibcpp_CXX=$CXX
1077 for ac_prog in $CCC c++ g++ gcc CC cxx cc++
b2dad0e3
BK
1078do
1079# Extract the first word of "$ac_prog", so it can be a program name with args.
1080set dummy $ac_prog; ac_word=$2
1081echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
a0f27776 1082echo "configure:1083: checking for $ac_word" >&5
46840bcd 1083if eval "test \"`echo '$''{'ac_cv_prog_glibcpp_CXX'+set}'`\" = set"; then
b2dad0e3
BK
1084 echo $ac_n "(cached) $ac_c" 1>&6
1085else
46840bcd
BK
1086 if test -n "$glibcpp_CXX"; then
1087 ac_cv_prog_glibcpp_CXX="$glibcpp_CXX" # Let the user override the test.
b2dad0e3
BK
1088else
1089 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1090 ac_dummy="$PATH"
1091 for ac_dir in $ac_dummy; do
1092 test -z "$ac_dir" && ac_dir=.
1093 if test -f $ac_dir/$ac_word; then
46840bcd 1094 ac_cv_prog_glibcpp_CXX="$ac_prog"
b2dad0e3
BK
1095 break
1096 fi
1097 done
1098 IFS="$ac_save_ifs"
1099fi
1100fi
46840bcd
BK
1101glibcpp_CXX="$ac_cv_prog_glibcpp_CXX"
1102if test -n "$glibcpp_CXX"; then
1103 echo "$ac_t""$glibcpp_CXX" 1>&6
b2dad0e3
BK
1104else
1105 echo "$ac_t""no" 1>&6
1106fi
1107
46840bcd 1108test -n "$glibcpp_CXX" && break
b2dad0e3 1109done
46840bcd 1110test -n "$glibcpp_CXX" || glibcpp_CXX="gcc"
de9aefe0 1111
d2caef2e
PE
1112
1113 CXX=$glibcpp_CXX
1114 test -z "$glibcpp_CXX" && { echo "configure: error: no acceptable c++ found in \$PATH" 1>&2; exit 1; }
b2dad0e3 1115
d2caef2e 1116 echo $ac_n "checking whether we are using GNU C++""... $ac_c" 1>&6
a0f27776 1117echo "configure:1118: checking whether we are using GNU C++" >&5
b2dad0e3
BK
1118if eval "test \"`echo '$''{'ac_cv_prog_gxx'+set}'`\" = set"; then
1119 echo $ac_n "(cached) $ac_c" 1>&6
1120else
1121 cat > conftest.C <<EOF
1122#ifdef __GNUC__
1123 yes;
1124#endif
1125EOF
a0f27776 1126if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:1127: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
b2dad0e3
BK
1127 ac_cv_prog_gxx=yes
1128else
1129 ac_cv_prog_gxx=no
1130fi
1131fi
1132
1133echo "$ac_t""$ac_cv_prog_gxx" 1>&6
1134
d2caef2e
PE
1135 if test $ac_cv_prog_gxx = yes; then
1136 GXX=yes
1137 ac_test_CXXFLAGS="${CXXFLAGS+set}"
1138 ac_save_CXXFLAGS="$CXXFLAGS"
1139 CXXFLAGS=
1140 echo $ac_n "checking whether ${CXX-g++} accepts -g""... $ac_c" 1>&6
a0f27776 1141echo "configure:1142: checking whether ${CXX-g++} accepts -g" >&5
b2dad0e3
BK
1142if eval "test \"`echo '$''{'ac_cv_prog_cxx_g'+set}'`\" = set"; then
1143 echo $ac_n "(cached) $ac_c" 1>&6
1144else
1145 echo 'void f(){}' > conftest.cc
1146if test -z "`${CXX-g++} -g -c conftest.cc 2>&1`"; then
1147 ac_cv_prog_cxx_g=yes
1148else
1149 ac_cv_prog_cxx_g=no
1150fi
1151rm -f conftest*
1152
1153fi
1154
1155echo "$ac_t""$ac_cv_prog_cxx_g" 1>&6
d2caef2e
PE
1156 if test "$ac_test_CXXFLAGS" = set; then
1157 CXXFLAGS="$ac_save_CXXFLAGS"
1158 elif test $ac_cv_prog_cxx_g = yes; then
1159 CXXFLAGS="-g -O2"
1160 else
1161 CXXFLAGS="-O2"
1162 fi
b2dad0e3 1163 else
d2caef2e
PE
1164 GXX=
1165 test "${CXXFLAGS+set}" = set || CXXFLAGS="-g"
b2dad0e3 1166 fi
d2caef2e 1167
ab3bc736 1168
2f235b6d
PE
1169 # For directory versioning (e.g., headers) and other variables.
1170 echo $ac_n "checking for GCC version number""... $ac_c" 1>&6
a0f27776 1171echo "configure:1172: checking for GCC version number" >&5
2f235b6d
PE
1172 gcc_version=`$glibcpp_CXX -dumpversion`
1173 echo "$ac_t""$gcc_version" 1>&6
93b85586 1174
2f235b6d 1175 # For some reason, gettext needs this.
974e336b
PE
1176
1177 echo $ac_n "checking for strerror in -lcposix""... $ac_c" 1>&6
1178echo "configure:1179: checking for strerror in -lcposix" >&5
1179ac_lib_var=`echo cposix'_'strerror | sed 'y%./+-%__p_%'`
1180if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1181 echo $ac_n "(cached) $ac_c" 1>&6
1182else
1183 ac_save_LIBS="$LIBS"
1184LIBS="-lcposix $LIBS"
1185cat > conftest.$ac_ext <<EOF
1186#line 1187 "configure"
1187#include "confdefs.h"
1188/* Override any gcc2 internal prototype to avoid an error. */
1189/* We use char because int might match the return type of a gcc2
1190 builtin and then its argument prototype would still apply. */
1191char strerror();
1192
1193int main() {
1194strerror()
1195; return 0; }
33590f13 1196EOF
974e336b
PE
1197if { (eval echo configure:1198: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1198 rm -rf conftest*
1199 eval "ac_cv_lib_$ac_lib_var=yes"
1200else
1201 echo "configure: failed program was:" >&5
1202 cat conftest.$ac_ext >&5
1203 rm -rf conftest*
1204 eval "ac_cv_lib_$ac_lib_var=no"
1205fi
1206rm -f conftest*
1207LIBS="$ac_save_LIBS"
33590f13 1208
974e336b
PE
1209fi
1210if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1211 echo "$ac_t""yes" 1>&6
1212 LIBS="$LIBS -lcposix"
33590f13
BK
1213else
1214 echo "$ac_t""no" 1>&6
33590f13
BK
1215fi
1216
974e336b
PE
1217
1218
33590f13 1219
5780a46b 1220 # Extract the first word of "${ac_tool_prefix}as", so it can be a program name with args.
b2dad0e3
BK
1221set dummy ${ac_tool_prefix}as; ac_word=$2
1222echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
974e336b 1223echo "configure:1224: checking for $ac_word" >&5
b2dad0e3
BK
1224if eval "test \"`echo '$''{'ac_cv_prog_AS'+set}'`\" = set"; then
1225 echo $ac_n "(cached) $ac_c" 1>&6
1226else
1227 if test -n "$AS"; then
1228 ac_cv_prog_AS="$AS" # Let the user override the test.
1229else
1230 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1231 ac_dummy="$PATH"
1232 for ac_dir in $ac_dummy; do
1233 test -z "$ac_dir" && ac_dir=.
1234 if test -f $ac_dir/$ac_word; then
1235 ac_cv_prog_AS="${ac_tool_prefix}as"
1236 break
1237 fi
1238 done
1239 IFS="$ac_save_ifs"
1240 test -z "$ac_cv_prog_AS" && ac_cv_prog_AS="as"
1241fi
1242fi
1243AS="$ac_cv_prog_AS"
1244if test -n "$AS"; then
1245 echo "$ac_t""$AS" 1>&6
1246else
1247 echo "$ac_t""no" 1>&6
1248fi
1249
1250
1251
5780a46b 1252 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
b2dad0e3
BK
1253set dummy ${ac_tool_prefix}ar; ac_word=$2
1254echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
974e336b 1255echo "configure:1256: checking for $ac_word" >&5
b2dad0e3
BK
1256if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
1257 echo $ac_n "(cached) $ac_c" 1>&6
1258else
1259 if test -n "$AR"; then
1260 ac_cv_prog_AR="$AR" # Let the user override the test.
1261else
1262 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1263 ac_dummy="$PATH"
1264 for ac_dir in $ac_dummy; do
1265 test -z "$ac_dir" && ac_dir=.
1266 if test -f $ac_dir/$ac_word; then
1267 ac_cv_prog_AR="${ac_tool_prefix}ar"
1268 break
1269 fi
1270 done
1271 IFS="$ac_save_ifs"
1272 test -z "$ac_cv_prog_AR" && ac_cv_prog_AR="ar"
1273fi
1274fi
1275AR="$ac_cv_prog_AR"
1276if test -n "$AR"; then
1277 echo "$ac_t""$AR" 1>&6
1278else
1279 echo "$ac_t""no" 1>&6
1280fi
1281
1282
1283
5780a46b 1284 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
b2dad0e3
BK
1285set dummy ${ac_tool_prefix}ranlib; ac_word=$2
1286echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
974e336b 1287echo "configure:1288: checking for $ac_word" >&5
b2dad0e3
BK
1288if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
1289 echo $ac_n "(cached) $ac_c" 1>&6
1290else
1291 if test -n "$RANLIB"; then
1292 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
1293else
1294 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1295 ac_dummy="$PATH"
1296 for ac_dir in $ac_dummy; do
1297 test -z "$ac_dir" && ac_dir=.
1298 if test -f $ac_dir/$ac_word; then
1299 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
1300 break
1301 fi
1302 done
1303 IFS="$ac_save_ifs"
1304fi
1305fi
1306RANLIB="$ac_cv_prog_RANLIB"
1307if test -n "$RANLIB"; then
1308 echo "$ac_t""$RANLIB" 1>&6
1309else
1310 echo "$ac_t""no" 1>&6
1311fi
1312
1313
1314if test -z "$ac_cv_prog_RANLIB"; then
1315if test -n "$ac_tool_prefix"; then
1316 # Extract the first word of "ranlib", so it can be a program name with args.
1317set dummy ranlib; ac_word=$2
1318echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
974e336b 1319echo "configure:1320: checking for $ac_word" >&5
b2dad0e3
BK
1320if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
1321 echo $ac_n "(cached) $ac_c" 1>&6
1322else
1323 if test -n "$RANLIB"; then
1324 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
1325else
1326 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1327 ac_dummy="$PATH"
1328 for ac_dir in $ac_dummy; do
1329 test -z "$ac_dir" && ac_dir=.
1330 if test -f $ac_dir/$ac_word; then
1331 ac_cv_prog_RANLIB="ranlib"
1332 break
1333 fi
1334 done
1335 IFS="$ac_save_ifs"
46840bcd 1336 test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB="ranlib-not-found-in-path-error"
b2dad0e3
BK
1337fi
1338fi
1339RANLIB="$ac_cv_prog_RANLIB"
1340if test -n "$RANLIB"; then
1341 echo "$ac_t""$RANLIB" 1>&6
1342else
1343 echo "$ac_t""no" 1>&6
1344fi
1345
1346else
46840bcd
BK
1347 RANLIB="ranlib-not-found-in-path-error"
1348fi
1349fi
1350
5780a46b 1351 # Find a good install program. We prefer a C program (faster),
b2dad0e3
BK
1352# so one script is as good as another. But avoid the broken or
1353# incompatible versions:
1354# SysV /etc/install, /usr/sbin/install
1355# SunOS /usr/etc/install
1356# IRIX /sbin/install
1357# AIX /bin/install
1358# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
1359# AFS /usr/afsws/bin/install, which mishandles nonexistent args
1360# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
1361# ./install, which can be erroneously created by make from ./install.sh.
1362echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
974e336b 1363echo "configure:1364: checking for a BSD compatible install" >&5
b2dad0e3
BK
1364if test -z "$INSTALL"; then
1365if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
1366 echo $ac_n "(cached) $ac_c" 1>&6
1367else
1368 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":"
1369 for ac_dir in $PATH; do
1370 # Account for people who put trailing slashes in PATH elements.
1371 case "$ac_dir/" in
1372 /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
1373 *)
1374 # OSF1 and SCO ODT 3.0 have their own names for install.
1375 # Don't use installbsd from OSF since it installs stuff as root
1376 # by default.
1377 for ac_prog in ginstall scoinst install; do
1378 if test -f $ac_dir/$ac_prog; then
1379 if test $ac_prog = install &&
1380 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
1381 # AIX install. It has an incompatible calling convention.
1382 :
1383 else
1384 ac_cv_path_install="$ac_dir/$ac_prog -c"
1385 break 2
1386 fi
1387 fi
1388 done
1389 ;;
1390 esac
1391 done
1392 IFS="$ac_save_IFS"
1393
1394fi
1395 if test "${ac_cv_path_install+set}" = set; then
1396 INSTALL="$ac_cv_path_install"
1397 else
1398 # As a last resort, use the slow shell script. We don't cache a
1399 # path for INSTALL within a source directory, because that will
1400 # break other packages using the cache if that directory is
1401 # removed, or if the path is relative.
1402 INSTALL="$ac_install_sh"
1403 fi
1404fi
1405echo "$ac_t""$INSTALL" 1>&6
1406
1407# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
1408# It thinks the first close brace ends the variable substitution.
1409test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
1410
1411test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
1412
1413test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
1414
1415
5780a46b 1416 echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
974e336b 1417echo "configure:1418: checking whether to enable maintainer-specific portions of Makefiles" >&5
b2dad0e3
BK
1418 # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
1419if test "${enable_maintainer_mode+set}" = set; then
1420 enableval="$enable_maintainer_mode"
1421 USE_MAINTAINER_MODE=$enableval
1422else
1423 USE_MAINTAINER_MODE=no
1424fi
1425
1426 echo "$ac_t""$USE_MAINTAINER_MODE" 1>&6
1427
1428
1429if test $USE_MAINTAINER_MODE = yes; then
1430 MAINTAINER_MODE_TRUE=
1431 MAINTAINER_MODE_FALSE='#'
1432else
1433 MAINTAINER_MODE_TRUE='#'
1434 MAINTAINER_MODE_FALSE=
1435fi
1436 MAINT=$MAINTAINER_MODE_TRUE
1437
1438
1439
5780a46b
BK
1440 # We need AC_EXEEXT to keep automake happy in cygnus mode. However,
1441 # at least currently, we never actually build a program, so we never
1442 # need to use $(EXEEXT). Moreover, the test for EXEEXT normally
1443 # fails, because we are probably configuring with a cross compiler
c5504edb
JM
1444 # which can't create executables. So we include AC_EXEEXT to keep
1445 # automake happy, but we don't execute it, since we don't care about
4d0e4296 1446 # the result.
5780a46b 1447 if false; then
61c71946
BK
1448 # autoconf 2.50 runs AC_EXEEXT by default, and the macro expands
1449 # to nothing, so nothing would remain between `then' and `fi' if it
1450 # were not for the `:' below.
1451 :
5780a46b 1452
b2dad0e3
BK
1453
1454echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
974e336b 1455echo "configure:1456: checking for executable suffix" >&5
b2dad0e3
BK
1456if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
1457 echo $ac_n "(cached) $ac_c" 1>&6
1458else
1459 if test "$CYGWIN" = yes || test "$MINGW32" = yes; then
1460 ac_cv_exeext=.exe
1461else
1462 rm -f conftest*
1463 echo 'int main () { return 0; }' > conftest.$ac_ext
1464 ac_cv_exeext=
974e336b 1465 if { (eval echo configure:1466: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
b2dad0e3
BK
1466 for file in conftest.*; do
1467 case $file in
162c7cd9 1468 *.c | *.o | *.obj) ;;
b2dad0e3
BK
1469 *) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
1470 esac
1471 done
1472 else
1473 { echo "configure: error: installation or configuration problem: compiler cannot create executables." 1>&2; exit 1; }
1474 fi
1475 rm -f conftest*
1476 test x"${ac_cv_exeext}" = x && ac_cv_exeext=no
1477fi
1478fi
1479
1480EXEEXT=""
1481test x"${ac_cv_exeext}" != xno && EXEEXT=${ac_cv_exeext}
1482echo "$ac_t""${ac_cv_exeext}" 1>&6
1483ac_exeext=$EXEEXT
1484
5780a46b 1485 fi
b2dad0e3 1486
5780a46b 1487 case ${glibcpp_basedir} in
56c1d2ee 1488 /* | A-Za-z:\\/*) libgcj_flagbasedir=${glibcpp_basedir} ;;
5780a46b
BK
1489 *) glibcpp_flagbasedir='$(top_builddir)/'${glibcpp_basedir} ;;
1490 esac
3840fa2a 1491
2c839a4e 1492 # Find platform-specific directories containing configuration info. In
5e3cbe0b 1493 # addition to possibly modifying the same flags, it also sets up symlinks.
d0941a31 1494
974e336b
PE
1495 . ${glibcpp_basedir}/configure.target
1496 echo "$ac_t""CPU config directory is $cpu_include_dir" 1>&6
1497 echo "$ac_t""OS config directory is $os_include_dir" 1>&6
d0941a31
PE
1498
1499
33590f13 1500
2f235b6d 1501echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
162c7cd9 1502echo "configure:1503: checking whether build environment is sane" >&5
2f235b6d
PE
1503# Just in case
1504sleep 1
1505echo timestamp > conftestfile
1506# Do `set' in a subshell so we don't clobber the current shell's
1507# arguments. Must try -L first in case configure is actually a
1508# symlink; some systems play weird games with the mod time of symlinks
1509# (eg FreeBSD returns the mod time of the symlink's containing
1510# directory).
1511if (
1512 set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
1513 if test "$*" = "X"; then
1514 # -L didn't work.
1515 set X `ls -t $srcdir/configure conftestfile`
1516 fi
1517 if test "$*" != "X $srcdir/configure conftestfile" \
1518 && test "$*" != "X conftestfile $srcdir/configure"; then
1519
1520 # If neither matched, then we have a broken ls. This can happen
1521 # if, for instance, CONFIG_SHELL is bash and it inherits a
1522 # broken ls alias from the environment. This has actually
1523 # happened. Such a system could not be considered "sane".
1524 { echo "configure: error: ls -t appears to fail. Make sure there is not a broken
1525alias in your environment" 1>&2; exit 1; }
1526 fi
1527
1528 test "$2" = conftestfile
1529 )
1530then
1531 # Ok.
1532 :
1533else
1534 { echo "configure: error: newly created file is older than distributed files!
1535Check your system clock" 1>&2; exit 1; }
1536fi
1537rm -f conftest*
1538echo "$ac_t""yes" 1>&6
1539if test "$program_transform_name" = s,x,x,; then
1540 program_transform_name=
1541else
1542 # Double any \ or $. echo might interpret backslashes.
1543 cat <<\EOF_SED > conftestsed
1544s,\\,\\\\,g; s,\$,$$,g
1545EOF_SED
1546 program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
1547 rm -f conftestsed
1548fi
1549test "$program_prefix" != NONE &&
1550 program_transform_name="s,^,${program_prefix},; $program_transform_name"
1551# Use a double $ so make ignores it.
1552test "$program_suffix" != NONE &&
1553 program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
1554
1555# sed with no file args requires a program.
1556test "$program_transform_name" = "" && program_transform_name="s,x,x,"
1557
1558echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
162c7cd9 1559echo "configure:1560: checking whether ${MAKE-make} sets \${MAKE}" >&5
2f235b6d
PE
1560set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
1561if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
1562 echo $ac_n "(cached) $ac_c" 1>&6
1563else
1564 cat > conftestmake <<\EOF
1565all:
1566 @echo 'ac_maketemp="${MAKE}"'
1567EOF
1568# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1569eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
1570if test -n "$ac_maketemp"; then
1571 eval ac_cv_prog_make_${ac_make}_set=yes
1572else
1573 eval ac_cv_prog_make_${ac_make}_set=no
1574fi
1575rm -f conftestmake
1576fi
1577if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
1578 echo "$ac_t""yes" 1>&6
1579 SET_MAKE=
1580else
1581 echo "$ac_t""no" 1>&6
1582 SET_MAKE="MAKE=${MAKE-make}"
1583fi
1584
1585
1586PACKAGE=$PACKAGE
1587
1588VERSION=$gcc_version
1589
1590if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
1591 { echo "configure: error: source directory already configured; run "make distclean" there first" 1>&2; exit 1; }
1592fi
1593cat >> confdefs.h <<EOF
1594#define PACKAGE "$PACKAGE"
1595EOF
1596
1597cat >> confdefs.h <<EOF
1598#define VERSION "$VERSION"
1599EOF
1600
1601
1602
1603missing_dir=`cd $ac_aux_dir && pwd`
162c7cd9
SW
1604echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
1605echo "configure:1606: checking for working aclocal" >&5
2f235b6d
PE
1606# Run test in a subshell; some versions of sh will print an error if
1607# an executable is not found, even if stderr is redirected.
1608# Redirect stdin to placate older versions of autoconf. Sigh.
162c7cd9
SW
1609if (aclocal --version) < /dev/null > /dev/null 2>&1; then
1610 ACLOCAL=aclocal
2f235b6d
PE
1611 echo "$ac_t""found" 1>&6
1612else
162c7cd9 1613 ACLOCAL="$missing_dir/missing aclocal"
2f235b6d
PE
1614 echo "$ac_t""missing" 1>&6
1615fi
1616
1617echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
162c7cd9 1618echo "configure:1619: checking for working autoconf" >&5
2f235b6d
PE
1619# Run test in a subshell; some versions of sh will print an error if
1620# an executable is not found, even if stderr is redirected.
1621# Redirect stdin to placate older versions of autoconf. Sigh.
1622if (autoconf --version) < /dev/null > /dev/null 2>&1; then
1623 AUTOCONF=autoconf
1624 echo "$ac_t""found" 1>&6
1625else
1626 AUTOCONF="$missing_dir/missing autoconf"
1627 echo "$ac_t""missing" 1>&6
1628fi
1629
162c7cd9
SW
1630echo $ac_n "checking for working automake""... $ac_c" 1>&6
1631echo "configure:1632: checking for working automake" >&5
2f235b6d
PE
1632# Run test in a subshell; some versions of sh will print an error if
1633# an executable is not found, even if stderr is redirected.
1634# Redirect stdin to placate older versions of autoconf. Sigh.
162c7cd9
SW
1635if (automake --version) < /dev/null > /dev/null 2>&1; then
1636 AUTOMAKE=automake
2f235b6d
PE
1637 echo "$ac_t""found" 1>&6
1638else
162c7cd9 1639 AUTOMAKE="$missing_dir/missing automake"
2f235b6d
PE
1640 echo "$ac_t""missing" 1>&6
1641fi
1642
1643echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
162c7cd9 1644echo "configure:1645: checking for working autoheader" >&5
2f235b6d
PE
1645# Run test in a subshell; some versions of sh will print an error if
1646# an executable is not found, even if stderr is redirected.
1647# Redirect stdin to placate older versions of autoconf. Sigh.
1648if (autoheader --version) < /dev/null > /dev/null 2>&1; then
1649 AUTOHEADER=autoheader
1650 echo "$ac_t""found" 1>&6
1651else
1652 AUTOHEADER="$missing_dir/missing autoheader"
1653 echo "$ac_t""missing" 1>&6
1654fi
1655
1656echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
162c7cd9 1657echo "configure:1658: checking for working makeinfo" >&5
2f235b6d
PE
1658# Run test in a subshell; some versions of sh will print an error if
1659# an executable is not found, even if stderr is redirected.
1660# Redirect stdin to placate older versions of autoconf. Sigh.
1661if (makeinfo --version) < /dev/null > /dev/null 2>&1; then
1662 MAKEINFO=makeinfo
1663 echo "$ac_t""found" 1>&6
1664else
1665 MAKEINFO="$missing_dir/missing makeinfo"
1666 echo "$ac_t""missing" 1>&6
1667fi
1668
1669
1670
1671
1672
5780a46b 1673
f4c79fef 1674
b2dad0e3
BK
1675# Check whether --enable-shared or --disable-shared was given.
1676if test "${enable_shared+set}" = set; then
1677 enableval="$enable_shared"
1678 p=${PACKAGE-default}
c21b6f87 1679case $enableval in
b2dad0e3
BK
1680yes) enable_shared=yes ;;
1681no) enable_shared=no ;;
1682*)
1683 enable_shared=no
1684 # Look at the argument we got. We use all the common list separators.
1685 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
1686 for pkg in $enableval; do
1687 if test "X$pkg" = "X$p"; then
1688 enable_shared=yes
1689 fi
1690 done
1691 IFS="$ac_save_ifs"
1692 ;;
1693esac
1694else
1695 enable_shared=yes
1696fi
1697
1698# Check whether --enable-static or --disable-static was given.
1699if test "${enable_static+set}" = set; then
1700 enableval="$enable_static"
1701 p=${PACKAGE-default}
c21b6f87 1702case $enableval in
b2dad0e3
BK
1703yes) enable_static=yes ;;
1704no) enable_static=no ;;
1705*)
1706 enable_static=no
1707 # Look at the argument we got. We use all the common list separators.
1708 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
1709 for pkg in $enableval; do
1710 if test "X$pkg" = "X$p"; then
1711 enable_static=yes
1712 fi
1713 done
1714 IFS="$ac_save_ifs"
1715 ;;
1716esac
1717else
1718 enable_static=yes
1719fi
1720
1721# Check whether --enable-fast-install or --disable-fast-install was given.
1722if test "${enable_fast_install+set}" = set; then
1723 enableval="$enable_fast_install"
1724 p=${PACKAGE-default}
c21b6f87 1725case $enableval in
b2dad0e3
BK
1726yes) enable_fast_install=yes ;;
1727no) enable_fast_install=no ;;
1728*)
1729 enable_fast_install=no
1730 # Look at the argument we got. We use all the common list separators.
1731 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
1732 for pkg in $enableval; do
1733 if test "X$pkg" = "X$p"; then
1734 enable_fast_install=yes
1735 fi
1736 done
1737 IFS="$ac_save_ifs"
1738 ;;
1739esac
1740else
1741 enable_fast_install=yes
1742fi
1743
b2dad0e3
BK
1744# Check whether --with-gnu-ld or --without-gnu-ld was given.
1745if test "${with_gnu_ld+set}" = set; then
1746 withval="$with_gnu_ld"
1747 test "$withval" = no || with_gnu_ld=yes
1748else
1749 with_gnu_ld=no
1750fi
1751
1752ac_prog=ld
c21b6f87 1753if test "$GCC" = yes; then
b2dad0e3
BK
1754 # Check if gcc -print-prog-name=ld gives a path.
1755 echo $ac_n "checking for ld used by GCC""... $ac_c" 1>&6
162c7cd9 1756echo "configure:1757: checking for ld used by GCC" >&5
3df64633
AO
1757 case $host in
1758 *-*-mingw*)
1759 # gcc leaves a trailing carriage return which upsets mingw
1760 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
1761 *)
1762 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
1763 esac
c21b6f87 1764 case $ac_prog in
b2dad0e3 1765 # Accept absolute paths.
3840fa2a 1766 [\\/]* | [A-Za-z]:[\\/]*)
b2dad0e3
BK
1767 re_direlt='/[^/][^/]*/\.\./'
1768 # Canonicalize the path of ld
1769 ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
1770 while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
1771 ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
1772 done
1773 test -z "$LD" && LD="$ac_prog"
1774 ;;
1775 "")
1776 # If it fails, then pretend we aren't using GCC.
1777 ac_prog=ld
1778 ;;
1779 *)
1780 # If it is relative, then search for the first ld in PATH.
1781 with_gnu_ld=unknown
1782 ;;
1783 esac
1784elif test "$with_gnu_ld" = yes; then
1785 echo $ac_n "checking for GNU ld""... $ac_c" 1>&6
162c7cd9 1786echo "configure:1787: checking for GNU ld" >&5
b2dad0e3
BK
1787else
1788 echo $ac_n "checking for non-GNU ld""... $ac_c" 1>&6
162c7cd9 1789echo "configure:1790: checking for non-GNU ld" >&5
b2dad0e3 1790fi
c21b6f87 1791if eval "test \"`echo '$''{'lt_cv_path_LD'+set}'`\" = set"; then
b2dad0e3
BK
1792 echo $ac_n "(cached) $ac_c" 1>&6
1793else
1794 if test -z "$LD"; then
3840fa2a 1795 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
b2dad0e3
BK
1796 for ac_dir in $PATH; do
1797 test -z "$ac_dir" && ac_dir=.
3840fa2a 1798 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
c21b6f87 1799 lt_cv_path_LD="$ac_dir/$ac_prog"
b2dad0e3
BK
1800 # Check to see if the program is GNU ld. I'd rather use --version,
1801 # but apparently some GNU ld's only accept -v.
1802 # Break only if it was the GNU/non-GNU ld that we prefer.
c21b6f87 1803 if "$lt_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
b2dad0e3
BK
1804 test "$with_gnu_ld" != no && break
1805 else
1806 test "$with_gnu_ld" != yes && break
1807 fi
1808 fi
1809 done
1810 IFS="$ac_save_ifs"
1811else
c21b6f87 1812 lt_cv_path_LD="$LD" # Let the user override the test with a path.
b2dad0e3
BK
1813fi
1814fi
1815
c21b6f87 1816LD="$lt_cv_path_LD"
b2dad0e3
BK
1817if test -n "$LD"; then
1818 echo "$ac_t""$LD" 1>&6
1819else
1820 echo "$ac_t""no" 1>&6
1821fi
1822test -z "$LD" && { echo "configure: error: no acceptable ld found in \$PATH" 1>&2; exit 1; }
1823echo $ac_n "checking if the linker ($LD) is GNU ld""... $ac_c" 1>&6
162c7cd9 1824echo "configure:1825: checking if the linker ($LD) is GNU ld" >&5
c21b6f87 1825if eval "test \"`echo '$''{'lt_cv_prog_gnu_ld'+set}'`\" = set"; then
b2dad0e3
BK
1826 echo $ac_n "(cached) $ac_c" 1>&6
1827else
1828 # I'd rather use --version here, but apparently some GNU ld's only accept -v.
1829if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
c21b6f87 1830 lt_cv_prog_gnu_ld=yes
b2dad0e3 1831else
c21b6f87 1832 lt_cv_prog_gnu_ld=no
b2dad0e3
BK
1833fi
1834fi
1835
c21b6f87
PE
1836echo "$ac_t""$lt_cv_prog_gnu_ld" 1>&6
1837with_gnu_ld=$lt_cv_prog_gnu_ld
3df64633 1838
b2dad0e3 1839
3df64633 1840echo $ac_n "checking for $LD option to reload object files""... $ac_c" 1>&6
162c7cd9 1841echo "configure:1842: checking for $LD option to reload object files" >&5
3df64633
AO
1842if eval "test \"`echo '$''{'lt_cv_ld_reload_flag'+set}'`\" = set"; then
1843 echo $ac_n "(cached) $ac_c" 1>&6
1844else
1845 lt_cv_ld_reload_flag='-r'
1846fi
1847
1848echo "$ac_t""$lt_cv_ld_reload_flag" 1>&6
1849reload_flag=$lt_cv_ld_reload_flag
1850test -n "$reload_flag" && reload_flag=" $reload_flag"
b2dad0e3
BK
1851
1852echo $ac_n "checking for BSD-compatible nm""... $ac_c" 1>&6
162c7cd9 1853echo "configure:1854: checking for BSD-compatible nm" >&5
c21b6f87 1854if eval "test \"`echo '$''{'lt_cv_path_NM'+set}'`\" = set"; then
b2dad0e3
BK
1855 echo $ac_n "(cached) $ac_c" 1>&6
1856else
1857 if test -n "$NM"; then
1858 # Let the user override the test.
c21b6f87 1859 lt_cv_path_NM="$NM"
b2dad0e3 1860else
3840fa2a 1861 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
b2dad0e3
BK
1862 for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do
1863 test -z "$ac_dir" && ac_dir=.
3df64633
AO
1864 tmp_nm=$ac_dir/${ac_tool_prefix}nm
1865 if test -f $tmp_nm || test -f $tmp_nm$ac_exeext ; then
b2dad0e3
BK
1866 # Check to see if the nm accepts a BSD-compat flag.
1867 # Adding the `sed 1q' prevents false positives on HP-UX, which says:
1868 # nm: unknown option "B" ignored
6d93bca4
AO
1869 # Tru64's nm complains that /dev/null is an invalid object file
1870 if ($tmp_nm -B /dev/null 2>&1 | sed '1q'; exit 0) | egrep '(/dev/null|Invalid file or object type)' >/dev/null; then
c21b6f87 1871 lt_cv_path_NM="$tmp_nm -B"
b2dad0e3 1872 break
3df64633 1873 elif ($tmp_nm -p /dev/null 2>&1 | sed '1q'; exit 0) | egrep /dev/null >/dev/null; then
c21b6f87 1874 lt_cv_path_NM="$tmp_nm -p"
b2dad0e3
BK
1875 break
1876 else
c21b6f87 1877 lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
b2dad0e3
BK
1878 continue # so that we can try to find one that supports BSD flags
1879 fi
1880 fi
1881 done
1882 IFS="$ac_save_ifs"
c21b6f87 1883 test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm
b2dad0e3
BK
1884fi
1885fi
1886
c21b6f87 1887NM="$lt_cv_path_NM"
b2dad0e3
BK
1888echo "$ac_t""$NM" 1>&6
1889
3df64633 1890echo $ac_n "checking how to recognise dependant libraries""... $ac_c" 1>&6
162c7cd9 1891echo "configure:1892: checking how to recognise dependant libraries" >&5
3df64633
AO
1892if eval "test \"`echo '$''{'lt_cv_deplibs_check_method'+set}'`\" = set"; then
1893 echo $ac_n "(cached) $ac_c" 1>&6
1894else
3dd7094e 1895 lt_cv_file_magic_cmd='$MAGIC_CMD'
3df64633
AO
1896lt_cv_file_magic_test_file=
1897lt_cv_deplibs_check_method='unknown'
1898# Need to set the preceding variable on all platforms that support
1899# interlibrary dependencies.
1900# 'none' -- dependencies not supported.
1901# `unknown' -- same as none, but documents that we really don't know.
1902# 'pass_all' -- all dependencies passed with no checks.
1903# 'test_compile' -- check by making test program.
1904# 'file_magic [regex]' -- check by looking for files in library path
1905# which responds to the $file_magic_cmd with a given egrep regex.
1906# If you have `file' or equivalent on your system and you're not sure
1907# whether `pass_all' will *always* work, you probably want this one.
1908
c21b6f87
PE
1909case $host_os in
1910aix*)
3df64633
AO
1911 lt_cv_deplibs_check_method=pass_all
1912 ;;
1913
1914beos*)
1915 lt_cv_deplibs_check_method=pass_all
1916 ;;
1917
1918bsdi4*)
c21b6f87
PE
1919 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
1920 lt_cv_file_magic_cmd='/usr/bin/file -L'
3df64633
AO
1921 lt_cv_file_magic_test_file=/shlib/libc.so
1922 ;;
1923
3dd7094e 1924cygwin* | mingw* |pw32*)
3df64633 1925 lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
3dd7094e 1926 lt_cv_file_magic_cmd='$OBJDUMP -f'
3df64633
AO
1927 ;;
1928
c21b6f87
PE
1929darwin* | rhapsody*)
1930 lt_cv_deplibs_check_method='file_magic Mach-O dynamically linked shared library'
47e982b2
BK
1931 lt_cv_file_magic_cmd='/usr/bin/file -L'
1932 case "$host_os" in
1933 rhapsody* | darwin1.012)
1934 lt_cv_file_magic_test_file='/System/Library/Frameworks/System.framework/System'
1935 ;;
1936 *) # Darwin 1.3 on
1937 lt_cv_file_magic_test_file='/usr/lib/libSystem.dylib'
1938 ;;
1939 esac
c21b6f87
PE
1940 ;;
1941
3df64633
AO
1942freebsd* )
1943 if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
c21b6f87 1944 case $host_cpu in
3df64633 1945 i*86 )
6d93bca4
AO
1946 # Not sure whether the presence of OpenBSD here was a mistake.
1947 # Let's accept both of them until this is cleared up.
c21b6f87
PE
1948 lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD)/i[3-9]86 (compact )?demand paged shared library'
1949 lt_cv_file_magic_cmd=/usr/bin/file
3df64633
AO
1950 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
1951 ;;
1952 esac
1953 else
1954 lt_cv_deplibs_check_method=pass_all
1955 fi
1956 ;;
1957
1958gnu*)
1959 lt_cv_deplibs_check_method=pass_all
1960 ;;
1961
c21b6f87 1962hpux10.20*|hpux11*)
38cca750
BK
1963 case $host_cpu in
1964 hppa*)
1965 lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9].[0-9]) shared library'
1966 lt_cv_file_magic_cmd=/usr/bin/file
1967 lt_cv_file_magic_test_file=/usr/lib/libc.sl
1968 ;;
1969 ia64*)
1970 lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64'
1971 lt_cv_file_magic_cmd=/usr/bin/file
1972 lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
1973 ;;
1974 esac
3df64633
AO
1975 ;;
1976
1977irix5* | irix6*)
c21b6f87 1978 case $host_os in
3df64633
AO
1979 irix5*)
1980 # this will be overridden with pass_all, but let us keep it just in case
1981 lt_cv_deplibs_check_method="file_magic ELF 32-bit MSB dynamic lib MIPS - version 1"
1982 ;;
1983 *)
c21b6f87 1984 case $LD in
3df64633
AO
1985 *-32|*"-32 ") libmagic=32-bit;;
1986 *-n32|*"-n32 ") libmagic=N32;;
1987 *-64|*"-64 ") libmagic=64-bit;;
1988 *) libmagic=never-match;;
1989 esac
1990 # this will be overridden with pass_all, but let us keep it just in case
c21b6f87
PE
1991 lt_cv_deplibs_check_method="file_magic ELF ${libmagic} MSB mips-[1234] dynamic lib MIPS - version 1"
1992 ;;
3df64633
AO
1993 esac
1994 lt_cv_file_magic_test_file=`echo /lib${libsuff}/libc.so*`
1995 lt_cv_deplibs_check_method=pass_all
1996 ;;
1997
1998# This must be Linux ELF.
6d93bca4 1999linux-gnu*)
c21b6f87 2000 case $host_cpu in
bfa1e6b1 2001 alpha* | hppa* | i*86 | powerpc* | sparc* | ia64* )
3df64633
AO
2002 lt_cv_deplibs_check_method=pass_all ;;
2003 *)
2004 # glibc up to 2.1.1 does not perform some relocations on ARM
c21b6f87
PE
2005 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )' ;;
2006 esac
3df64633
AO
2007 lt_cv_file_magic_test_file=`echo /lib/libc.so* /lib/libc-*.so`
2008 ;;
2009
2010netbsd*)
c21b6f87 2011 if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
47e982b2 2012 lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$'
3df64633 2013 else
47e982b2 2014 lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so$'
3df64633 2015 fi
c21b6f87
PE
2016 ;;
2017
2018newsos6)
2019 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)'
2020 lt_cv_file_magic_cmd=/usr/bin/file
2021 lt_cv_file_magic_test_file=/usr/lib/libnls.so
3df64633
AO
2022 ;;
2023
2024osf3* | osf4* | osf5*)
2025 # this will be overridden with pass_all, but let us keep it just in case
2026 lt_cv_deplibs_check_method='file_magic COFF format alpha shared library'
2027 lt_cv_file_magic_test_file=/shlib/libc.so
2028 lt_cv_deplibs_check_method=pass_all
2029 ;;
2030
2031sco3.2v5*)
2032 lt_cv_deplibs_check_method=pass_all
2033 ;;
2034
2035solaris*)
2036 lt_cv_deplibs_check_method=pass_all
2037 lt_cv_file_magic_test_file=/lib/libc.so
2038 ;;
2039
bfa1e6b1
BK
2040sysv5uw[78]* | sysv4*uw2*)
2041 lt_cv_deplibs_check_method=pass_all
2042 ;;
2043
3df64633 2044sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
c21b6f87 2045 case $host_vendor in
3df64633
AO
2046 ncr)
2047 lt_cv_deplibs_check_method=pass_all
2048 ;;
2049 motorola)
c21b6f87
PE
2050 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]'
2051 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
3df64633
AO
2052 ;;
2053 esac
2054 ;;
2055esac
2056
2057fi
2058
2059echo "$ac_t""$lt_cv_deplibs_check_method" 1>&6
2060file_magic_cmd=$lt_cv_file_magic_cmd
2061deplibs_check_method=$lt_cv_deplibs_check_method
2062
2063echo $ac_n "checking for object suffix""... $ac_c" 1>&6
162c7cd9 2064echo "configure:2065: checking for object suffix" >&5
3df64633
AO
2065if eval "test \"`echo '$''{'ac_cv_objext'+set}'`\" = set"; then
2066 echo $ac_n "(cached) $ac_c" 1>&6
2067else
2068 rm -f conftest*
2069echo 'int i = 1;' > conftest.$ac_ext
162c7cd9 2070if { (eval echo configure:2071: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3df64633
AO
2071 for ac_file in conftest.*; do
2072 case $ac_file in
2073 *.c) ;;
2074 *) ac_cv_objext=`echo $ac_file | sed -e s/conftest.//` ;;
2075 esac
2076 done
2077else
2078 { echo "configure: error: installation or configuration problem; compiler does not work" 1>&2; exit 1; }
2079fi
2080rm -f conftest*
2081fi
2082
2083echo "$ac_t""$ac_cv_objext" 1>&6
2084OBJEXT=$ac_cv_objext
2085ac_objext=$ac_cv_objext
2086
2087# Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers!
2088
2089# Only perform the check for file, if the check method requires it
c21b6f87 2090case $deplibs_check_method in
3df64633 2091file_magic*)
3dd7094e 2092 if test "$file_magic_cmd" = '$MAGIC_CMD'; then
3df64633 2093 echo $ac_n "checking for ${ac_tool_prefix}file""... $ac_c" 1>&6
162c7cd9 2094echo "configure:2095: checking for ${ac_tool_prefix}file" >&5
3dd7094e 2095if eval "test \"`echo '$''{'lt_cv_path_MAGIC_CMD'+set}'`\" = set"; then
3df64633
AO
2096 echo $ac_n "(cached) $ac_c" 1>&6
2097else
c21b6f87 2098 case $MAGIC_CMD in
3df64633 2099 /*)
3dd7094e 2100 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
3df64633
AO
2101 ;;
2102 ?:/*)
3dd7094e 2103 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a dos path.
3df64633
AO
2104 ;;
2105 *)
3dd7094e 2106 ac_save_MAGIC_CMD="$MAGIC_CMD"
3df64633
AO
2107 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2108 ac_dummy="/usr/bin:$PATH"
2109 for ac_dir in $ac_dummy; do
2110 test -z "$ac_dir" && ac_dir=.
2111 if test -f $ac_dir/${ac_tool_prefix}file; then
3dd7094e 2112 lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file"
3df64633 2113 if test -n "$file_magic_test_file"; then
c21b6f87 2114 case $deplibs_check_method in
3df64633
AO
2115 "file_magic "*)
2116 file_magic_regex="`expr \"$deplibs_check_method\" : \"file_magic \(.*\)\"`"
3dd7094e 2117 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
3df64633
AO
2118 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
2119 egrep "$file_magic_regex" > /dev/null; then
2120 :
2121 else
2122 cat <<EOF 1>&2
2123
2124*** Warning: the command libtool uses to detect shared libraries,
2125*** $file_magic_cmd, produces output that libtool cannot recognize.
2126*** The result is that libtool may fail to recognize shared libraries
2127*** as such. This will affect the creation of libtool libraries that
2128*** depend on shared libraries, but programs linked with such libtool
2129*** libraries will work regardless of this problem. Nevertheless, you
2130*** may want to report the problem to your system manager and/or to
2131*** bug-libtool@gnu.org
2132
2133EOF
2134 fi ;;
2135 esac
2136 fi
2137 break
2138 fi
2139 done
2140 IFS="$ac_save_ifs"
3dd7094e 2141 MAGIC_CMD="$ac_save_MAGIC_CMD"
3df64633
AO
2142 ;;
2143esac
2144fi
2145
3dd7094e
AO
2146MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
2147if test -n "$MAGIC_CMD"; then
2148 echo "$ac_t""$MAGIC_CMD" 1>&6
3df64633
AO
2149else
2150 echo "$ac_t""no" 1>&6
2151fi
2152
3dd7094e 2153if test -z "$lt_cv_path_MAGIC_CMD"; then
3df64633
AO
2154 if test -n "$ac_tool_prefix"; then
2155 echo $ac_n "checking for file""... $ac_c" 1>&6
162c7cd9 2156echo "configure:2157: checking for file" >&5
3dd7094e 2157if eval "test \"`echo '$''{'lt_cv_path_MAGIC_CMD'+set}'`\" = set"; then
3df64633
AO
2158 echo $ac_n "(cached) $ac_c" 1>&6
2159else
c21b6f87 2160 case $MAGIC_CMD in
3df64633 2161 /*)
3dd7094e 2162 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
3df64633
AO
2163 ;;
2164 ?:/*)
3dd7094e 2165 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a dos path.
3df64633
AO
2166 ;;
2167 *)
3dd7094e 2168 ac_save_MAGIC_CMD="$MAGIC_CMD"
3df64633
AO
2169 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2170 ac_dummy="/usr/bin:$PATH"
2171 for ac_dir in $ac_dummy; do
2172 test -z "$ac_dir" && ac_dir=.
2173 if test -f $ac_dir/file; then
3dd7094e 2174 lt_cv_path_MAGIC_CMD="$ac_dir/file"
3df64633 2175 if test -n "$file_magic_test_file"; then
c21b6f87 2176 case $deplibs_check_method in
3df64633
AO
2177 "file_magic "*)
2178 file_magic_regex="`expr \"$deplibs_check_method\" : \"file_magic \(.*\)\"`"
3dd7094e 2179 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
3df64633
AO
2180 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
2181 egrep "$file_magic_regex" > /dev/null; then
2182 :
2183 else
2184 cat <<EOF 1>&2
2185
2186*** Warning: the command libtool uses to detect shared libraries,
2187*** $file_magic_cmd, produces output that libtool cannot recognize.
2188*** The result is that libtool may fail to recognize shared libraries
2189*** as such. This will affect the creation of libtool libraries that
2190*** depend on shared libraries, but programs linked with such libtool
2191*** libraries will work regardless of this problem. Nevertheless, you
2192*** may want to report the problem to your system manager and/or to
2193*** bug-libtool@gnu.org
2194
2195EOF
2196 fi ;;
2197 esac
2198 fi
2199 break
2200 fi
2201 done
2202 IFS="$ac_save_ifs"
3dd7094e 2203 MAGIC_CMD="$ac_save_MAGIC_CMD"
3df64633
AO
2204 ;;
2205esac
2206fi
2207
3dd7094e
AO
2208MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
2209if test -n "$MAGIC_CMD"; then
2210 echo "$ac_t""$MAGIC_CMD" 1>&6
3df64633
AO
2211else
2212 echo "$ac_t""no" 1>&6
2213fi
2214
2215 else
3dd7094e 2216 MAGIC_CMD=:
3df64633
AO
2217 fi
2218fi
2219
2220 fi
2221 ;;
2222esac
2223
2224# Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
2225set dummy ${ac_tool_prefix}ranlib; ac_word=$2
2226echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
162c7cd9 2227echo "configure:2228: checking for $ac_word" >&5
3df64633
AO
2228if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
2229 echo $ac_n "(cached) $ac_c" 1>&6
2230else
2231 if test -n "$RANLIB"; then
2232 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
2233else
2234 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2235 ac_dummy="$PATH"
2236 for ac_dir in $ac_dummy; do
2237 test -z "$ac_dir" && ac_dir=.
2238 if test -f $ac_dir/$ac_word; then
2239 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
2240 break
2241 fi
2242 done
2243 IFS="$ac_save_ifs"
2244fi
2245fi
2246RANLIB="$ac_cv_prog_RANLIB"
2247if test -n "$RANLIB"; then
2248 echo "$ac_t""$RANLIB" 1>&6
2249else
2250 echo "$ac_t""no" 1>&6
2251fi
2252
2253
2254if test -z "$ac_cv_prog_RANLIB"; then
2255if test -n "$ac_tool_prefix"; then
2256 # Extract the first word of "ranlib", so it can be a program name with args.
2257set dummy ranlib; ac_word=$2
2258echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
162c7cd9 2259echo "configure:2260: checking for $ac_word" >&5
3df64633
AO
2260if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
2261 echo $ac_n "(cached) $ac_c" 1>&6
2262else
2263 if test -n "$RANLIB"; then
2264 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
2265else
2266 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2267 ac_dummy="$PATH"
2268 for ac_dir in $ac_dummy; do
2269 test -z "$ac_dir" && ac_dir=.
2270 if test -f $ac_dir/$ac_word; then
2271 ac_cv_prog_RANLIB="ranlib"
2272 break
2273 fi
2274 done
2275 IFS="$ac_save_ifs"
2276 test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
2277fi
2278fi
2279RANLIB="$ac_cv_prog_RANLIB"
2280if test -n "$RANLIB"; then
2281 echo "$ac_t""$RANLIB" 1>&6
2282else
2283 echo "$ac_t""no" 1>&6
2284fi
2285
2286else
2287 RANLIB=":"
2288fi
2289fi
2290
2291# Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
2292set dummy ${ac_tool_prefix}strip; ac_word=$2
2293echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
162c7cd9 2294echo "configure:2295: checking for $ac_word" >&5
3df64633
AO
2295if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
2296 echo $ac_n "(cached) $ac_c" 1>&6
2297else
2298 if test -n "$STRIP"; then
2299 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
2300else
2301 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2302 ac_dummy="$PATH"
2303 for ac_dir in $ac_dummy; do
2304 test -z "$ac_dir" && ac_dir=.
2305 if test -f $ac_dir/$ac_word; then
2306 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
2307 break
2308 fi
2309 done
2310 IFS="$ac_save_ifs"
2311fi
2312fi
2313STRIP="$ac_cv_prog_STRIP"
2314if test -n "$STRIP"; then
2315 echo "$ac_t""$STRIP" 1>&6
2316else
2317 echo "$ac_t""no" 1>&6
2318fi
2319
2320
2321if test -z "$ac_cv_prog_STRIP"; then
2322if test -n "$ac_tool_prefix"; then
2323 # Extract the first word of "strip", so it can be a program name with args.
2324set dummy strip; ac_word=$2
2325echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
162c7cd9 2326echo "configure:2327: checking for $ac_word" >&5
3df64633
AO
2327if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
2328 echo $ac_n "(cached) $ac_c" 1>&6
2329else
2330 if test -n "$STRIP"; then
2331 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
2332else
2333 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2334 ac_dummy="$PATH"
2335 for ac_dir in $ac_dummy; do
2336 test -z "$ac_dir" && ac_dir=.
2337 if test -f $ac_dir/$ac_word; then
2338 ac_cv_prog_STRIP="strip"
2339 break
2340 fi
2341 done
2342 IFS="$ac_save_ifs"
2343 test -z "$ac_cv_prog_STRIP" && ac_cv_prog_STRIP=":"
2344fi
2345fi
2346STRIP="$ac_cv_prog_STRIP"
2347if test -n "$STRIP"; then
2348 echo "$ac_t""$STRIP" 1>&6
2349else
2350 echo "$ac_t""no" 1>&6
2351fi
2352
2353else
2354 STRIP=":"
2355fi
2356fi
2357
b2dad0e3 2358
b2dad0e3
BK
2359# Check for any special flags to pass to ltconfig.
2360libtool_flags="--cache-file=$cache_file"
2361test "$enable_shared" = no && libtool_flags="$libtool_flags --disable-shared"
2362test "$enable_static" = no && libtool_flags="$libtool_flags --disable-static"
2363test "$enable_fast_install" = no && libtool_flags="$libtool_flags --disable-fast-install"
c21b6f87
PE
2364test "$GCC" = yes && libtool_flags="$libtool_flags --with-gcc"
2365test "$lt_cv_prog_gnu_ld" = yes && libtool_flags="$libtool_flags --with-gnu-ld"
3840fa2a
BK
2366libtool_flags="$libtool_flags --enable-dlopen"
2367
2368# Check whether --enable-libtool-lock or --disable-libtool-lock was given.
2369if test "${enable_libtool_lock+set}" = set; then
2370 enableval="$enable_libtool_lock"
2371 :
2372fi
2373
2374test "x$enable_libtool_lock" = xno && libtool_flags="$libtool_flags --disable-lock"
2375test x"$silent" = xyes && libtool_flags="$libtool_flags --silent"
b2dad0e3 2376
3df64633
AO
2377# Check whether --with-pic or --without-pic was given.
2378if test "${with_pic+set}" = set; then
2379 withval="$with_pic"
2380 pic_mode="$withval"
2381else
2382 pic_mode=default
2383fi
2384
2385test x"$pic_mode" = xyes && libtool_flags="$libtool_flags --prefer-pic"
2386test x"$pic_mode" = xno && libtool_flags="$libtool_flags --prefer-non-pic"
2387
b2dad0e3
BK
2388# Some flags need to be propagated to the compiler or linker for good
2389# libtool support.
c21b6f87 2390case $host in
b2dad0e3
BK
2391*-*-irix6*)
2392 # Find out which ABI we are using.
162c7cd9
SW
2393 echo '#line 2394 "configure"' > conftest.$ac_ext
2394 if { (eval echo configure:2395: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
c21b6f87 2395 case `/usr/bin/file conftest.$ac_objext` in
b2dad0e3
BK
2396 *32-bit*)
2397 LD="${LD-ld} -32"
2398 ;;
2399 *N32*)
2400 LD="${LD-ld} -n32"
2401 ;;
2402 *64-bit*)
2403 LD="${LD-ld} -64"
2404 ;;
2405 esac
2406 fi
2407 rm -rf conftest*
2408 ;;
2409
38cca750
BK
2410ia64-*-hpux*)
2411 # Find out which ABI we are using.
2412 echo 'int i;' > conftest.$ac_ext
162c7cd9 2413 if { (eval echo configure:2414: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
38cca750
BK
2414 case "`/usr/bin/file conftest.o`" in
2415 *ELF-32*)
2416 HPUX_IA64_MODE="32"
2417 ;;
2418 *ELF-64*)
2419 HPUX_IA64_MODE="64"
2420 ;;
2421 esac
2422 fi
2423 rm -rf conftest*
2424 ;;
2425
162c7cd9
SW
2426x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*|s390*-*linux*|sparc*-*linux*)
2427 # Find out which ABI we are using.
2428 echo 'int i;' > conftest.$ac_ext
2429 if { (eval echo configure:2430: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2430 case "`/usr/bin/file conftest.o`" in
2431 *32-bit*)
2432 case $host in
2433 x86_64-*linux*)
2434 LD="${LD-ld} -m elf_i386"
2435 ;;
2436 ppc64-*linux*)
2437 LD="${LD-ld} -m elf32ppclinux"
2438 ;;
2439 s390x-*linux*)
2440 LD="${LD-ld} -m elf_s390"
2441 ;;
2442 sparc64-*linux*)
2443 LD="${LD-ld} -m elf32_sparc"
2444 ;;
2445 esac
2446 ;;
2447 *64-bit*)
2448 case $host in
2449 x86_64-*linux*)
2450 LD="${LD-ld} -m elf_x86_64"
2451 ;;
2452 ppc*-*linux*|powerpc*-*linux*)
2453 LD="${LD-ld} -m elf64ppc"
2454 ;;
2455 s390*-*linux*)
2456 LD="${LD-ld} -m elf64_s390"
2457 ;;
2458 sparc*-*linux*)
2459 LD="${LD-ld} -m elf64_sparc"
2460 ;;
2461 esac
2462 ;;
2463 esac
2464 fi
2465 rm -rf conftest*
2466 ;;
2467
b2dad0e3
BK
2468*-*-sco3.2v5*)
2469 # On SCO OpenServer 5, we need -belf to get full-featured binaries.
2470 SAVE_CFLAGS="$CFLAGS"
2471 CFLAGS="$CFLAGS -belf"
2472 echo $ac_n "checking whether the C compiler needs -belf""... $ac_c" 1>&6
162c7cd9 2473echo "configure:2474: checking whether the C compiler needs -belf" >&5
b2dad0e3
BK
2474if eval "test \"`echo '$''{'lt_cv_cc_needs_belf'+set}'`\" = set"; then
2475 echo $ac_n "(cached) $ac_c" 1>&6
2476else
3df64633
AO
2477
2478 ac_ext=c
2479# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
2480ac_cpp='$CPP $CPPFLAGS'
2481ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
2482ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
2483cross_compiling=$ac_cv_prog_cc_cross
2484
2485 cat > conftest.$ac_ext <<EOF
162c7cd9 2486#line 2487 "configure"
b2dad0e3
BK
2487#include "confdefs.h"
2488
2489int main() {
2490
2491; return 0; }
2492EOF
162c7cd9 2493if { (eval echo configure:2494: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
b2dad0e3
BK
2494 rm -rf conftest*
2495 lt_cv_cc_needs_belf=yes
2496else
2497 echo "configure: failed program was:" >&5
2498 cat conftest.$ac_ext >&5
2499 rm -rf conftest*
2500 lt_cv_cc_needs_belf=no
2501fi
2502rm -f conftest*
3df64633
AO
2503 ac_ext=c
2504# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
2505ac_cpp='$CPP $CPPFLAGS'
2506ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
2507ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
2508cross_compiling=$ac_cv_prog_cc_cross
2509
b2dad0e3
BK
2510fi
2511
2512echo "$ac_t""$lt_cv_cc_needs_belf" 1>&6
2513 if test x"$lt_cv_cc_needs_belf" != x"yes"; then
2514 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
2515 CFLAGS="$SAVE_CFLAGS"
2516 fi
2517 ;;
2518
2519
2520esac
2521
3df64633 2522echo $ac_n "checking how to run the C++ preprocessor""... $ac_c" 1>&6
162c7cd9 2523echo "configure:2524: checking how to run the C++ preprocessor" >&5
3df64633
AO
2524if test -z "$CXXCPP"; then
2525if eval "test \"`echo '$''{'ac_cv_prog_CXXCPP'+set}'`\" = set"; then
2526 echo $ac_n "(cached) $ac_c" 1>&6
2527else
2528 ac_ext=C
2529# CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
2530ac_cpp='$CXXCPP $CPPFLAGS'
2531ac_compile='${CXX-g++} -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
2532ac_link='${CXX-g++} -o conftest${ac_exeext} $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
2533cross_compiling=$ac_cv_prog_cxx_cross
2534 CXXCPP="${CXX-g++} -E"
2535 cat > conftest.$ac_ext <<EOF
162c7cd9 2536#line 2537 "configure"
3df64633
AO
2537#include "confdefs.h"
2538#include <stdlib.h>
2539EOF
2540ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
162c7cd9 2541{ (eval echo configure:2542: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3df64633
AO
2542ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2543if test -z "$ac_err"; then
2544 :
2545else
2546 echo "$ac_err" >&5
2547 echo "configure: failed program was:" >&5
2548 cat conftest.$ac_ext >&5
2549 rm -rf conftest*
2550 CXXCPP=/lib/cpp
2551fi
2552rm -f conftest*
2553 ac_cv_prog_CXXCPP="$CXXCPP"
2554ac_ext=c
2555# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
2556ac_cpp='$CPP $CPPFLAGS'
2557ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
2558ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
2559cross_compiling=$ac_cv_prog_cc_cross
2560fi
2561fi
2562CXXCPP="$ac_cv_prog_CXXCPP"
2563echo "$ac_t""$CXXCPP" 1>&6
2564
b2dad0e3
BK
2565
2566# Save cache, so that ltconfig can load it
2567cat > confcache <<\EOF
2568# This file is a shell script that caches the results of configure
2569# tests run on this system so they can be shared between configure
2570# scripts and configure runs. It is not useful on other systems.
2571# If it contains results you don't want to keep, you may remove or edit it.
2572#
2573# By default, configure uses ./config.cache as the cache file,
2574# creating it if it does not exist already. You can give configure
2575# the --cache-file=FILE option to use a different cache file; that is
2576# what configure does when it calls configure scripts in
2577# subdirectories, so they share the cache.
2578# Giving --cache-file=/dev/null disables caching, for debugging configure.
2579# config.status only pays attention to the cache file if you give it the
2580# --recheck option to rerun configure.
2581#
2582EOF
2583# The following way of writing the cache mishandles newlines in values,
2584# but we know of no workaround that is simple, portable, and efficient.
2585# So, don't put newlines in cache variables' values.
2586# Ultrix sh set writes to stderr and can't be redirected directly,
2587# and sets the high bit in the cache file unless we assign to the vars.
2588(set) 2>&1 |
2589 case `(ac_space=' '; set | grep ac_space) 2>&1` in
2590 *ac_space=\ *)
2591 # `set' does not quote correctly, so add quotes (double-quote substitution
2592 # turns \\\\ into \\, and sed turns \\ into \).
2593 sed -n \
2594 -e "s/'/'\\\\''/g" \
2595 -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
2596 ;;
2597 *)
2598 # `set' quotes correctly as required by POSIX, so do not add quotes.
2599 sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
2600 ;;
2601 esac >> confcache
2602if cmp -s $cache_file confcache; then
2603 :
2604else
2605 if test -w $cache_file; then
2606 echo "updating cache $cache_file"
2607 cat confcache > $cache_file
2608 else
2609 echo "not updating unwritable cache $cache_file"
2610 fi
2611fi
2612rm -f confcache
2613
2614
2615# Actually configure libtool. ac_aux_dir is where install-sh is found.
3df64633 2616AR="$AR" LTCC="$CC" CC="$CC" CFLAGS="$CFLAGS" CPPFLAGS="$CPPFLAGS" \
3dd7094e 2617MAGIC_CMD="$MAGIC_CMD" LD="$LD" LDFLAGS="$LDFLAGS" LIBS="$LIBS" \
3df64633
AO
2618LN_S="$LN_S" NM="$NM" RANLIB="$RANLIB" STRIP="$STRIP" \
2619AS="$AS" DLLTOOL="$DLLTOOL" OBJDUMP="$OBJDUMP" \
2620objext="$OBJEXT" exeext="$EXEEXT" reload_flag="$reload_flag" \
2621deplibs_check_method="$deplibs_check_method" file_magic_cmd="$file_magic_cmd" \
b2dad0e3 2622${CONFIG_SHELL-/bin/sh} $ac_aux_dir/ltconfig --no-reexec \
3df64633 2623$libtool_flags --no-verify --build="$build" $ac_aux_dir/ltmain.sh $host \
b2dad0e3
BK
2624|| { echo "configure: error: libtool configure failed" 1>&2; exit 1; }
2625
2626# Reload cache, that may have been modified by ltconfig
2627if test -r "$cache_file"; then
2628 echo "loading cache $cache_file"
2629 . $cache_file
2630else
2631 echo "creating cache $cache_file"
2632 > $cache_file
2633fi
2634
2635
2636# This can be used to rebuild libtool when needed
3df64633 2637LIBTOOL_DEPS="$ac_aux_dir/ltconfig $ac_aux_dir/ltmain.sh $ac_aux_dir/ltcf-c.sh"
b2dad0e3
BK
2638
2639# Always use our own libtool.
2640LIBTOOL='$(SHELL) $(top_builddir)/libtool'
2641
2642# Redirect the config.log output again, so that the ltconfig log is not
2643# clobbered by the next message.
2644exec 5>>./config.log
2645
3df64633
AO
2646
2647
3df64633
AO
2648LIBTOOL_DEPS=$LIBTOOL_DEPS" $ac_aux_dir/ltcf-cxx.sh"
2649lt_save_CC="$CC"
2650lt_save_CFLAGS="$CFLAGS"
2651AR="$AR" LTCC="$CC" CC="$CXX" CXX="$CXX" CFLAGS="$CXXFLAGS" CPPFLAGS="$CPPFLAGS" \
c21b6f87 2652MAGIC_CMD="$MAGIC_CMD" LD="$LD" LDFLAGS="$LDFLAGS" LIBS="$LIBS" \
3df64633
AO
2653LN_S="$LN_S" NM="$NM" RANLIB="$RANLIB" STRIP="$STRIP" \
2654AS="$AS" DLLTOOL="$DLLTOOL" OBJDUMP="$OBJDUMP" \
2655objext="$OBJEXT" exeext="$EXEEXT" reload_flag="$reload_flag" \
2656deplibs_check_method="$deplibs_check_method" \
2657file_magic_cmd="$file_magic_cmd" \
2658${CONFIG_SHELL-/bin/sh} $ac_aux_dir/ltconfig -o libtool $libtool_flags \
2659--build="$build" --add-tag=CXX $ac_aux_dir/ltcf-cxx.sh $host \
2660|| { echo "configure: error: libtool tag configuration failed" 1>&2; exit 1; }
2661CC="$lt_save_CC"
2662CFLAGS="$lt_save_CFLAGS"
2663
2664# Redirect the config.log output again, so that the ltconfig log is not
2665# clobbered by the next message.
2666exec 5>>./config.log
2667
3df64633
AO
2668
2669
2670
2671
3dd7094e 2672
34791641
PE
2673
2674
33590f13 2675
33590f13
BK
2676# Check for c++ or library specific bits that don't require linking.
2677#GLIBCPP_CHECK_COMPILER_VERSION
5780a46b 2678echo $ac_n "checking for GNU make""... $ac_c" 1>&6
162c7cd9 2679echo "configure:2680: checking for GNU make" >&5
5780a46b
BK
2680if eval "test \"`echo '$''{'_cv_gnu_make_command'+set}'`\" = set"; then
2681 echo $ac_n "(cached) $ac_c" 1>&6
2682else
2683 _cv_gnu_make_command='' ;
57d278be 2684 for a in "${MAKE-make}" make gmake gnumake ; do
ea0c0b6e 2685 if ( $a --version 2> /dev/null | grep -c GNU > /dev/null )
79f5e38e 2686 then
5780a46b
BK
2687 _cv_gnu_make_command=$a ;
2688 break;
2689 fi
2690 done ;
2691
2692fi
2693
2694echo "$ac_t""$_cv_gnu_make_command" 1>&6 ;
2695 if test "x$_cv_gnu_make_command" != "x" ; then
2696 ifGNUmake='' ;
2697 else
2698 ifGNUmake='#' ;
2699 fi
2700
2701
04e78786 2702
33590f13 2703# Enable all the variable C++ stuff. C_MBCHAR must come early.
44382959
BK
2704# Check whether --enable-debug or --disable-debug was given.
2705if test "${enable_debug+set}" = set; then
2706 enableval="$enable_debug"
2707 case "${enableval}" in
2708 yes) enable_debug=yes ;;
2709 no) enable_debug=no ;;
2710 *) { echo "configure: error: Unknown argument to enable/disable extra debugging" 1>&2; exit 1; } ;;
2711 esac
2712else
2713 enable_debug=no
2714fi
2715
2716case "${enable_debug}" in
2717 yes)
2718 DEBUG_FLAGS='-O0 -ggdb3'
6abd2230 2719 ;;
44382959
BK
2720 no)
2721 DEBUG_FLAGS='-g'
2722 ;;
2723esac
2724
2725
c470c17d 2726echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
162c7cd9 2727echo "configure:2728: checking how to run the C preprocessor" >&5
c470c17d
BK
2728# On Suns, sometimes $CPP names a directory.
2729if test -n "$CPP" && test -d "$CPP"; then
2730 CPP=
2731fi
2732if test -z "$CPP"; then
2733if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
b2dad0e3
BK
2734 echo $ac_n "(cached) $ac_c" 1>&6
2735else
c470c17d
BK
2736 # This must be in double quotes, not single quotes, because CPP may get
2737 # substituted into the Makefile and "${CC-cc}" will confuse make.
2738 CPP="${CC-cc} -E"
2739 # On the NeXT, cc -E runs the code through the compiler's parser,
2740 # not just through cpp.
b2dad0e3 2741 cat > conftest.$ac_ext <<EOF
162c7cd9 2742#line 2743 "configure"
b2dad0e3 2743#include "confdefs.h"
c470c17d
BK
2744#include <assert.h>
2745Syntax Error
b2dad0e3
BK
2746EOF
2747ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
162c7cd9 2748{ (eval echo configure:2749: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
b2dad0e3
BK
2749ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2750if test -z "$ac_err"; then
2751 :
2752else
2753 echo "$ac_err" >&5
2754 echo "configure: failed program was:" >&5
2755 cat conftest.$ac_ext >&5
2756 rm -rf conftest*
c470c17d
BK
2757 CPP="${CC-cc} -E -traditional-cpp"
2758 cat > conftest.$ac_ext <<EOF
162c7cd9 2759#line 2760 "configure"
c470c17d
BK
2760#include "confdefs.h"
2761#include <assert.h>
2762Syntax Error
2763EOF
2764ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
162c7cd9 2765{ (eval echo configure:2766: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
c470c17d
BK
2766ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2767if test -z "$ac_err"; then
2768 :
2769else
2770 echo "$ac_err" >&5
2771 echo "configure: failed program was:" >&5
2772 cat conftest.$ac_ext >&5
2773 rm -rf conftest*
2774 CPP="${CC-cc} -nologo -E"
2775 cat > conftest.$ac_ext <<EOF
162c7cd9 2776#line 2777 "configure"
c470c17d
BK
2777#include "confdefs.h"
2778#include <assert.h>
2779Syntax Error
2780EOF
2781ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
162c7cd9 2782{ (eval echo configure:2783: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
c470c17d
BK
2783ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2784if test -z "$ac_err"; then
2785 :
2786else
2787 echo "$ac_err" >&5
2788 echo "configure: failed program was:" >&5
2789 cat conftest.$ac_ext >&5
2790 rm -rf conftest*
2791 CPP=/lib/cpp
b2dad0e3
BK
2792fi
2793rm -f conftest*
2794fi
33590f13
BK
2795rm -f conftest*
2796fi
2797rm -f conftest*
2798 ac_cv_prog_CPP="$CPP"
2799fi
2800 CPP="$ac_cv_prog_CPP"
2801else
2802 ac_cv_prog_CPP="$CPP"
2803fi
2804echo "$ac_t""$CPP" 1>&6
2805
2806
2807 echo $ac_n "checking for cstdio to use""... $ac_c" 1>&6
162c7cd9 2808echo "configure:2809: checking for cstdio to use" >&5
33590f13
BK
2809 # Check whether --enable-cstdio or --disable-cstdio was given.
2810if test "${enable_cstdio+set}" = set; then
2811 enableval="$enable_cstdio"
2812 if test x$enable_cstdio = xno; then
2813 enable_cstdio=stdio
2814 fi
2815else
2816 enable_cstdio=stdio
2817fi
2818
2819
2820 enable_cstdio_flag=$enable_cstdio
2821
2822 case x${enable_cstdio_flag} in
2823 xlibio)
2824 CSTDIO_H=config/io/c_io_libio.h
2825 BASIC_FILE_H=config/io/basic_file_libio.h
2826 BASIC_FILE_CC=config/io/basic_file_libio.cc
2827 echo "$ac_t""libio" 1>&6
2828
2829 # see if we are on a system with libio native (ie, linux)
2830 ac_safe=`echo "libio.h" | sed 'y%./+-%__p_%'`
2831echo $ac_n "checking for libio.h""... $ac_c" 1>&6
162c7cd9 2832echo "configure:2833: checking for libio.h" >&5
33590f13
BK
2833if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2834 echo $ac_n "(cached) $ac_c" 1>&6
2835else
2836 cat > conftest.$ac_ext <<EOF
162c7cd9 2837#line 2838 "configure"
33590f13
BK
2838#include "confdefs.h"
2839#include <libio.h>
2840EOF
2841ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
162c7cd9 2842{ (eval echo configure:2843: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
33590f13
BK
2843ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2844if test -z "$ac_err"; then
2845 rm -rf conftest*
2846 eval "ac_cv_header_$ac_safe=yes"
2847else
2848 echo "$ac_err" >&5
2849 echo "configure: failed program was:" >&5
2850 cat conftest.$ac_ext >&5
2851 rm -rf conftest*
2852 eval "ac_cv_header_$ac_safe=no"
2853fi
2854rm -f conftest*
2855fi
2856if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2857 echo "$ac_t""yes" 1>&6
2858 has_libio=yes
2859else
2860 echo "$ac_t""no" 1>&6
2861has_libio=no
2862fi
2863
2864
2865 # Need to check and see what version of glibc is being used. If
2866 # it's not glibc-2.2 or higher, then we'll need to go ahead and
2867 # compile most of libio for linux systems.
2868 if test x$has_libio = x"yes"; then
2869 case "$target" in
2870 *-*-linux*)
2871 echo $ac_n "checking for glibc version >= 2.2""... $ac_c" 1>&6
162c7cd9 2872echo "configure:2873: checking for glibc version >= 2.2" >&5
33590f13 2873 cat > conftest.$ac_ext <<EOF
162c7cd9 2874#line 2875 "configure"
33590f13
BK
2875#include "confdefs.h"
2876
2877 #include <features.h>
2878 #if __GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 2)
2879 ok
2880 #endif
2881
2882EOF
2883if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2884 egrep "ok" >/dev/null 2>&1; then
2885 rm -rf conftest*
2886 glibc_satisfactory=yes
2887else
2888 rm -rf conftest*
2889 glibc_satisfactory=no
2890fi
2891rm -f conftest*
2892
2893 echo "$ac_t""$glibc_satisfactory" 1>&6
2894 ;;
2895 esac
2896
2897 # XXX at the moment, admit defeat and force the recompilation
2898 # XXX of glibc even on glibc-2.2 systems, because libio is not synched.
2899 glibc_satisfactory=no
2900
2901 if test x$glibc_satisfactory = x"yes"; then
2902 need_libio=no
2903 need_wlibio=no
2904 else
2905 need_libio=yes
2906 # bkoz XXX need to add checks to enable this
2907 # pme XXX here's a first pass at such a check
2908 if test x$enable_c_mbchar != xno; then
2909 need_wlibio=yes
2910 else
2911 need_wlibio=no
2912 fi
2913 fi
2914
2915 else
2916 # Using libio, but <libio.h> doesn't exist on the target system. . .
2917 need_libio=yes
2918 # bkoz XXX need to add checks to enable this
2919 # pme XXX here's a first pass at such a check
2920 if test x$enable_c_mbchar != xno; then
2921 need_wlibio=yes
2922 else
2923 need_wlibio=no
2924 fi
2925 fi
2926 ;;
2927 xstdio | x | xno | xnone | xyes)
2928 # default
2929 CSTDIO_H=config/io/c_io_stdio.h
2930 BASIC_FILE_H=config/io/basic_file_stdio.h
2931 BASIC_FILE_CC=config/io/basic_file_stdio.cc
2932 echo "$ac_t""stdio" 1>&6
2933
2934 # We're not using stdio.
2935 need_libio=no
2936 need_wlibio=no
2937 ;;
2938 *)
2939 echo "$enable_cstdio is an unknown io package" 1>&2
2940 exit 1
2941 ;;
2942 esac
2943
2944
2945
2946
2947 # 2000-08-04 bkoz hack
2948 CCODECVT_C=config/io/c_io_libio_codecvt.c
2949
2950 # 2000-08-04 bkoz hack
2951
2952
2953
4e10943d
BK
2954if test "$need_libio" = yes || test "$need_wlibio" = yes; then
2955 GLIBCPP_BUILD_LIBIO_TRUE=
2956 GLIBCPP_BUILD_LIBIO_FALSE='#'
b2dad0e3 2957else
4e10943d
BK
2958 GLIBCPP_BUILD_LIBIO_TRUE='#'
2959 GLIBCPP_BUILD_LIBIO_FALSE=
2960fi
2961
2962
2963if test "$need_libio" = yes; then
2964 GLIBCPP_NEED_LIBIO_TRUE=
2965 GLIBCPP_NEED_LIBIO_FALSE='#'
b2dad0e3 2966else
4e10943d
BK
2967 GLIBCPP_NEED_LIBIO_TRUE='#'
2968 GLIBCPP_NEED_LIBIO_FALSE=
b2dad0e3 2969fi
4e10943d
BK
2970
2971
2972if test "$need_wlibio" = yes; then
2973 GLIBCPP_NEED_WLIBIO_TRUE=
2974 GLIBCPP_NEED_WLIBIO_FALSE='#'
2975else
2976 GLIBCPP_NEED_WLIBIO_TRUE='#'
2977 GLIBCPP_NEED_WLIBIO_FALSE=
b2dad0e3 2978fi
4e10943d
BK
2979 if test "$need_libio" = yes || test "$need_wlibio" = yes; then
2980 libio_la=../libio/libio.la
2981 else
2982 libio_la=
2983 fi
2984
2985
2986
2987 echo $ac_n "checking for clocale to use""... $ac_c" 1>&6
162c7cd9 2988echo "configure:2989: checking for clocale to use" >&5
4e10943d
BK
2989 # Check whether --enable-clocale or --disable-clocale was given.
2990if test "${enable_clocale+set}" = set; then
2991 enableval="$enable_clocale"
2992 if test x$enable_clocale = xno; then
56deb74c 2993 enable_clocale=no
4e10943d 2994 fi
b2dad0e3 2995else
56deb74c 2996 enable_clocale=no
b2dad0e3
BK
2997fi
2998
20427c6b 2999
4e10943d 3000 enable_clocale_flag=$enable_clocale
dd75251f 3001
56deb74c
BK
3002 if test x$enable_clocale_flag = xno; then
3003 case x${target_os} in
3004 xlinux* | xgnu*)
3005 cat > conftest.$ac_ext <<EOF
162c7cd9 3006#line 3007 "configure"
56deb74c
BK
3007#include "confdefs.h"
3008
3009 #include <features.h>
3010 #if __GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 2)
1451a492 3011 _GLIBCPP_ok
56deb74c
BK
3012 #endif
3013
3014EOF
3015if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1451a492 3016 egrep "_GLIBCPP_ok" >/dev/null 2>&1; then
56deb74c
BK
3017 rm -rf conftest*
3018 enable_clocale_flag=gnu
3019else
3020 rm -rf conftest*
3021 enable_clocale_flag=generic
3022fi
3023rm -f conftest*
3024
1451a492
BK
3025
3026 # Test for bugs early in glibc-2.2.x series
3027 if test x$enable_clocale_flag = xgnu; then
3028 if test "$cross_compiling" = yes; then
3029 enable_clocale_flag=generic
3030else
3031 cat > conftest.$ac_ext <<EOF
162c7cd9 3032#line 3033 "configure"
1451a492
BK
3033#include "confdefs.h"
3034
3035 #define _GNU_SOURCE 1
3036 #include <locale.h>
89671b70
JJ
3037 #include <string.h>
3038 #if __GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ > 2)
3039 extern __typeof(newlocale) __newlocale;
3040 extern __typeof(duplocale) __duplocale;
3041 extern __typeof(strcoll_l) __strcoll_l;
3042 #endif
1451a492
BK
3043 int main()
3044 {
3045