]> git.ipfire.org Git - thirdparty/glibc.git/blame - configure
Update.
[thirdparty/glibc.git] / configure
CommitLineData
cd6ede75
UD
1#! /bin/sh
2
3# From configure.in CVSid
4
5
6
7
650425ce
UD
8
9
10
11
63bda0c1
UD
12
13
cd6ede75 14# Guess values for system-dependent variables and create Makefiles.
a808d541 15# Generated automatically using autoconf version 2.13
cd6ede75
UD
16# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
17#
18# This configure script is free software; the Free Software Foundation
19# gives unlimited permission to copy, distribute and modify it.
20
21# Defaults:
22ac_help=
23ac_default_prefix=/usr/local
24# Any additions from configure.in:
25ac_help="$ac_help
26 --with-gmp=DIRECTORY find GMP source code in DIRECTORY (not needed)"
c8f3e6db
UD
27ac_help="$ac_help
28 --with-gd=DIR find libgd include dir and library with prefix DIR"
e41db95b
UD
29ac_help="$ac_help
30 --with-gd-include=DIR find libgd include files in DIR"
31ac_help="$ac_help
32 --with-gd-lib=DIR find libgd library files in DIR"
cd6ede75
UD
33ac_help="$ac_help
34 --with-fp if using floating-point hardware [default=yes]"
35ac_help="$ac_help
a5a0310d 36 --with-binutils=PATH specify location of binutils (as and ld)"
cd6ede75
UD
37ac_help="$ac_help
38 --with-elf if using the ELF object format"
5af3245a
UD
39ac_help="$ac_help
40 --with-xcoff if using the XCOFF object format"
d67281a7 41ac_help="$ac_help
4442d7e8 42 --without-cvs if CVS should not be used"
3c720987
UD
43ac_help="$ac_help
44 --with-headers=PATH location of system headers to use
45 [e.g. /usr/src/linux/include]
46 [default=compiler default]"
cd6ede75
UD
47ac_help="$ac_help
48 --enable-libio build in GNU libio instead of GNU stdio"
49ac_help="$ac_help
50 --disable-sanity-checks really do not use threads (should not be used
51 except in special situations) [default=yes]"
52ac_help="$ac_help
53 --enable-shared build shared library [default=yes if GNU ld & ELF]"
54ac_help="$ac_help
55 --enable-profile build profiled library [default=yes]"
56ac_help="$ac_help
57 --enable-omitfp build undebuggable optimized library [default=no]"
58ac_help="$ac_help
59 --enable-bounded build with runtime bounds checking [default=no]"
650425ce
UD
60ac_help="$ac_help
61 --disable-versioning do not include versioning information in the
62 library objects [default=yes if supported]"
62ab42d6
UD
63ac_help="$ac_help
64 --enable-oldest-abi=ABI configure the oldest ABI supported [e.g. 2.2]
65 [default=glibc default]"
cd6ede75 66ac_help="$ac_help
73237de3
UD
67 --enable-add-ons[=DIR1,DIR2]...
68 configure and build add-ons in DIR1,DIR2,...
69 search for add-ons if no parameter given"
8d4b5a8a
UD
70ac_help="$ac_help
71 --without-tls prevent support for TLS"
cd6ede75
UD
72ac_help="$ac_help
73 --enable-static-nss build static NSS modules [default=no]"
73237de3 74ac_help="$ac_help
310b3460 75 --disable-force-install don't force installation of files from this package,
73237de3 76 even if they are older than the installed files"
958f238f 77ac_help="$ac_help
4a307a98 78 --enable-kernel=VERSION compile for compatibility with kernel not older
958f238f 79 than VERSION"
6cc7d725
UD
80ac_help="$ac_help
81 --enable-all-warnings enable all useful warnings gcc can issue"
cd6ede75
UD
82
83# Initialize some variables set by options.
84# The variables have the same names as the options, with
85# dashes changed to underlines.
86build=NONE
87cache_file=./config.cache
88exec_prefix=NONE
89host=NONE
90no_create=
91nonopt=NONE
92no_recursion=
93prefix=NONE
94program_prefix=NONE
95program_suffix=NONE
96program_transform_name=s,x,x,
97silent=
98site=
99srcdir=
100target=NONE
101verbose=
102x_includes=NONE
103x_libraries=NONE
104bindir='${exec_prefix}/bin'
105sbindir='${exec_prefix}/sbin'
106libexecdir='${exec_prefix}/libexec'
107datadir='${prefix}/share'
108sysconfdir='${prefix}/etc'
109sharedstatedir='${prefix}/com'
110localstatedir='${prefix}/var'
111libdir='${exec_prefix}/lib'
112includedir='${prefix}/include'
113oldincludedir='/usr/include'
114infodir='${prefix}/info'
115mandir='${prefix}/man'
116
117# Initialize some other variables.
118subdirs=
119MFLAGS= MAKEFLAGS=
5c2a0669 120SHELL=${CONFIG_SHELL-/bin/sh}
cd6ede75
UD
121# Maximum number of lines to put in a shell here document.
122ac_max_here_lines=12
123
124ac_prev=
125for ac_option
126do
127
128 # If the previous option needs an argument, assign it.
129 if test -n "$ac_prev"; then
130 eval "$ac_prev=\$ac_option"
131 ac_prev=
132 continue
133 fi
134
135 case "$ac_option" in
136 -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
137 *) ac_optarg= ;;
138 esac
139
140 # Accept the important Cygnus configure options, so we can diagnose typos.
141
142 case "$ac_option" in
143
144 -bindir | --bindir | --bindi | --bind | --bin | --bi)
145 ac_prev=bindir ;;
146 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
147 bindir="$ac_optarg" ;;
148
149 -build | --build | --buil | --bui | --bu)
150 ac_prev=build ;;
151 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
152 build="$ac_optarg" ;;
153
154 -cache-file | --cache-file | --cache-fil | --cache-fi \
155 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
156 ac_prev=cache_file ;;
157 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
158 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
159 cache_file="$ac_optarg" ;;
160
161 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
162 ac_prev=datadir ;;
163 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
164 | --da=*)
165 datadir="$ac_optarg" ;;
166
167 -disable-* | --disable-*)
168 ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
169 # Reject names that are not valid shell variable names.
170 if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
171 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
172 fi
173 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
174 eval "enable_${ac_feature}=no" ;;
175
176 -enable-* | --enable-*)
177 ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
178 # Reject names that are not valid shell variable names.
179 if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
180 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
181 fi
182 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
183 case "$ac_option" in
184 *=*) ;;
185 *) ac_optarg=yes ;;
186 esac
187 eval "enable_${ac_feature}='$ac_optarg'" ;;
188
189 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
190 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
191 | --exec | --exe | --ex)
192 ac_prev=exec_prefix ;;
193 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
194 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
195 | --exec=* | --exe=* | --ex=*)
196 exec_prefix="$ac_optarg" ;;
197
198 -gas | --gas | --ga | --g)
199 # Obsolete; use --with-gas.
200 with_gas=yes ;;
201
202 -help | --help | --hel | --he)
203 # Omit some internal or obsolete options to make the list less imposing.
204 # This message is too long to be a string in the A/UX 3.1 sh.
205 cat << EOF
206Usage: configure [options] [host]
207Options: [defaults in brackets after descriptions]
208Configuration:
209 --cache-file=FILE cache test results in FILE
210 --help print this message
211 --no-create do not create output files
212 --quiet, --silent do not print \`checking...' messages
213 --version print the version of autoconf that created configure
214Directory and file names:
215 --prefix=PREFIX install architecture-independent files in PREFIX
216 [$ac_default_prefix]
217 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
218 [same as prefix]
219 --bindir=DIR user executables in DIR [EPREFIX/bin]
220 --sbindir=DIR system admin executables in DIR [EPREFIX/sbin]
221 --libexecdir=DIR program executables in DIR [EPREFIX/libexec]
222 --datadir=DIR read-only architecture-independent data in DIR
223 [PREFIX/share]
224 --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc]
225 --sharedstatedir=DIR modifiable architecture-independent data in DIR
226 [PREFIX/com]
227 --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var]
228 --libdir=DIR object code libraries in DIR [EPREFIX/lib]
229 --includedir=DIR C header files in DIR [PREFIX/include]
230 --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include]
231 --infodir=DIR info documentation in DIR [PREFIX/info]
232 --mandir=DIR man documentation in DIR [PREFIX/man]
233 --srcdir=DIR find the sources in DIR [configure dir or ..]
234 --program-prefix=PREFIX prepend PREFIX to installed program names
235 --program-suffix=SUFFIX append SUFFIX to installed program names
236 --program-transform-name=PROGRAM
237 run sed PROGRAM on installed program names
238EOF
239 cat << EOF
240Host type:
241 --build=BUILD configure for building on BUILD [BUILD=HOST]
242 --host=HOST configure for HOST [guessed]
243 --target=TARGET configure for TARGET [TARGET=HOST]
244Features and packages:
245 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
246 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
247 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
248 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
249 --x-includes=DIR X include files are in DIR
250 --x-libraries=DIR X library files are in DIR
251EOF
252 if test -n "$ac_help"; then
253 echo "--enable and --with options recognized:$ac_help"
254 fi
255 exit 0 ;;
256
257 -host | --host | --hos | --ho)
258 ac_prev=host ;;
259 -host=* | --host=* | --hos=* | --ho=*)
260 host="$ac_optarg" ;;
261
262 -includedir | --includedir | --includedi | --included | --include \
263 | --includ | --inclu | --incl | --inc)
264 ac_prev=includedir ;;
265 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
266 | --includ=* | --inclu=* | --incl=* | --inc=*)
267 includedir="$ac_optarg" ;;
268
269 -infodir | --infodir | --infodi | --infod | --info | --inf)
270 ac_prev=infodir ;;
271 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
272 infodir="$ac_optarg" ;;
273
274 -libdir | --libdir | --libdi | --libd)
275 ac_prev=libdir ;;
276 -libdir=* | --libdir=* | --libdi=* | --libd=*)
277 libdir="$ac_optarg" ;;
278
279 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
280 | --libexe | --libex | --libe)
281 ac_prev=libexecdir ;;
282 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
283 | --libexe=* | --libex=* | --libe=*)
284 libexecdir="$ac_optarg" ;;
285
286 -localstatedir | --localstatedir | --localstatedi | --localstated \
287 | --localstate | --localstat | --localsta | --localst \
288 | --locals | --local | --loca | --loc | --lo)
289 ac_prev=localstatedir ;;
290 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
291 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
292 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
293 localstatedir="$ac_optarg" ;;
294
295 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
296 ac_prev=mandir ;;
297 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
298 mandir="$ac_optarg" ;;
299
300 -nfp | --nfp | --nf)
301 # Obsolete; use --without-fp.
302 with_fp=no ;;
303
304 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
305 | --no-cr | --no-c)
306 no_create=yes ;;
307
308 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
309 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
310 no_recursion=yes ;;
311
312 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
313 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
314 | --oldin | --oldi | --old | --ol | --o)
315 ac_prev=oldincludedir ;;
316 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
317 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
318 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
319 oldincludedir="$ac_optarg" ;;
320
321 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
322 ac_prev=prefix ;;
323 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
324 prefix="$ac_optarg" ;;
325
326 -program-prefix | --program-prefix | --program-prefi | --program-pref \
327 | --program-pre | --program-pr | --program-p)
328 ac_prev=program_prefix ;;
329 -program-prefix=* | --program-prefix=* | --program-prefi=* \
330 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
331 program_prefix="$ac_optarg" ;;
332
333 -program-suffix | --program-suffix | --program-suffi | --program-suff \
334 | --program-suf | --program-su | --program-s)
335 ac_prev=program_suffix ;;
336 -program-suffix=* | --program-suffix=* | --program-suffi=* \
337 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
338 program_suffix="$ac_optarg" ;;
339
340 -program-transform-name | --program-transform-name \
341 | --program-transform-nam | --program-transform-na \
342 | --program-transform-n | --program-transform- \
343 | --program-transform | --program-transfor \
344 | --program-transfo | --program-transf \
345 | --program-trans | --program-tran \
346 | --progr-tra | --program-tr | --program-t)
347 ac_prev=program_transform_name ;;
348 -program-transform-name=* | --program-transform-name=* \
349 | --program-transform-nam=* | --program-transform-na=* \
350 | --program-transform-n=* | --program-transform-=* \
351 | --program-transform=* | --program-transfor=* \
352 | --program-transfo=* | --program-transf=* \
353 | --program-trans=* | --program-tran=* \
354 | --progr-tra=* | --program-tr=* | --program-t=*)
355 program_transform_name="$ac_optarg" ;;
356
357 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
358 | -silent | --silent | --silen | --sile | --sil)
359 silent=yes ;;
360
361 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
362 ac_prev=sbindir ;;
363 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
364 | --sbi=* | --sb=*)
365 sbindir="$ac_optarg" ;;
366
367 -sharedstatedir | --sharedstatedir | --sharedstatedi \
368 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
369 | --sharedst | --shareds | --shared | --share | --shar \
370 | --sha | --sh)
371 ac_prev=sharedstatedir ;;
372 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
373 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
374 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
375 | --sha=* | --sh=*)
376 sharedstatedir="$ac_optarg" ;;
377
378 -site | --site | --sit)
379 ac_prev=site ;;
380 -site=* | --site=* | --sit=*)
381 site="$ac_optarg" ;;
382
383 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
384 ac_prev=srcdir ;;
385 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
386 srcdir="$ac_optarg" ;;
387
388 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
389 | --syscon | --sysco | --sysc | --sys | --sy)
390 ac_prev=sysconfdir ;;
391 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
392 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
393 sysconfdir="$ac_optarg" ;;
394
395 -target | --target | --targe | --targ | --tar | --ta | --t)
396 ac_prev=target ;;
397 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
398 target="$ac_optarg" ;;
399
400 -v | -verbose | --verbose | --verbos | --verbo | --verb)
401 verbose=yes ;;
402
403 -version | --version | --versio | --versi | --vers)
a808d541 404 echo "configure generated by autoconf version 2.13"
cd6ede75
UD
405 exit 0 ;;
406
407 -with-* | --with-*)
408 ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
409 # Reject names that are not valid shell variable names.
410 if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
411 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
412 fi
413 ac_package=`echo $ac_package| sed 's/-/_/g'`
414 case "$ac_option" in
415 *=*) ;;
416 *) ac_optarg=yes ;;
417 esac
418 eval "with_${ac_package}='$ac_optarg'" ;;
419
420 -without-* | --without-*)
421 ac_package=`echo $ac_option|sed -e 's/-*without-//'`
422 # Reject names that are not valid shell variable names.
423 if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
424 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
425 fi
426 ac_package=`echo $ac_package| sed 's/-/_/g'`
427 eval "with_${ac_package}=no" ;;
428
429 --x)
430 # Obsolete; use --with-x.
431 with_x=yes ;;
432
433 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
434 | --x-incl | --x-inc | --x-in | --x-i)
435 ac_prev=x_includes ;;
436 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
437 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
438 x_includes="$ac_optarg" ;;
439
440 -x-libraries | --x-libraries | --x-librarie | --x-librari \
441 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
442 ac_prev=x_libraries ;;
443 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
444 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
445 x_libraries="$ac_optarg" ;;
446
447 -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
448 ;;
449
450 *)
451 if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
452 echo "configure: warning: $ac_option: invalid host type" 1>&2
453 fi
454 if test "x$nonopt" != xNONE; then
455 { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
456 fi
457 nonopt="$ac_option"
458 ;;
459
460 esac
461done
462
463if test -n "$ac_prev"; then
464 { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
465fi
466
467trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
468
469# File descriptor usage:
470# 0 standard input
471# 1 file creation
472# 2 errors and warnings
473# 3 some systems may open it to /dev/tty
474# 4 used on the Kubota Titan
475# 6 checking for... messages and results
476# 5 compiler messages saved in config.log
477if test "$silent" = yes; then
478 exec 6>/dev/null
479else
480 exec 6>&1
481fi
482exec 5>./config.log
483
484echo "\
485This file contains any messages produced by compilers while
486running configure, to aid debugging if configure makes a mistake.
487" 1>&5
488
489# Strip out --no-create and --no-recursion so they do not pile up.
490# Also quote any args containing shell metacharacters.
491ac_configure_args=
492for ac_arg
493do
494 case "$ac_arg" in
495 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
496 | --no-cr | --no-c) ;;
497 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
498 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
499 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
500 ac_configure_args="$ac_configure_args '$ac_arg'" ;;
501 *) ac_configure_args="$ac_configure_args $ac_arg" ;;
502 esac
503done
504
505# NLS nuisances.
506# Only set these to C if already set. These must not be set unconditionally
507# because not all systems understand e.g. LANG=C (notably SCO).
508# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
509# Non-C LC_CTYPE values break the ctype check.
510if test "${LANG+set}" = set; then LANG=C; export LANG; fi
511if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
512if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
513if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi
514
515# confdefs.h avoids OS command line length limits that DEFS can exceed.
516rm -rf conftest* confdefs.h
517# AIX cpp loses on an empty file, so make sure it contains at least a newline.
518echo > confdefs.h
519
520# A filename unique to this package, relative to the directory that
521# configure is in, which we can look for to find out if srcdir is correct.
522ac_unique_file=include/features.h
523
524# Find the source files, if location was not specified.
525if test -z "$srcdir"; then
526 ac_srcdir_defaulted=yes
527 # Try the directory containing this script, then its parent.
528 ac_prog=$0
529 ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
530 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
531 srcdir=$ac_confdir
532 if test ! -r $srcdir/$ac_unique_file; then
533 srcdir=..
534 fi
535else
536 ac_srcdir_defaulted=no
537fi
538if test ! -r $srcdir/$ac_unique_file; then
539 if test "$ac_srcdir_defaulted" = yes; then
540 { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
541 else
542 { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
543 fi
544fi
545srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
546
547# Prefer explicitly selected file to automatically selected ones.
548if test -z "$CONFIG_SITE"; then
549 if test "x$prefix" != xNONE; then
550 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
551 else
552 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
553 fi
554fi
555for ac_site_file in $CONFIG_SITE; do
556 if test -r "$ac_site_file"; then
557 echo "loading site script $ac_site_file"
558 . "$ac_site_file"
559 fi
560done
561
562if test -r "$cache_file"; then
563 echo "loading cache $cache_file"
a808d541 564 . $cache_file
cd6ede75
UD
565else
566 echo "creating cache $cache_file"
567 > $cache_file
568fi
569
570ac_ext=c
571# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
572ac_cpp='$CPP $CPPFLAGS'
573ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
5c2a0669 574ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
cd6ede75
UD
575cross_compiling=$ac_cv_prog_cc_cross
576
5c2a0669
UD
577ac_exeext=
578ac_objext=o
cd6ede75
UD
579if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
580 # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
581 if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
582 ac_n= ac_c='
583' ac_t=' '
584 else
585 ac_n=-n ac_c= ac_t=
586 fi
587else
588 ac_n= ac_c='\c' ac_t=
589fi
590
63bda0c1
UD
591 if test -r /vmunix; then
592 kernel_id=`strings /vmunix | grep UNIX`
593 elif test -r /dynix; then
594 kernel_id=`strings /dynix | grep DYNIX`
595 else
596 kernel_id=
597 fi
598
cd6ede75
UD
599
600
444518fe
UD
601ac_aux_dir=
602for ac_dir in scripts $srcdir/scripts; do
603 if test -f $ac_dir/install-sh; then
604 ac_aux_dir=$ac_dir
605 ac_install_sh="$ac_aux_dir/install-sh -c"
606 break
607 elif test -f $ac_dir/install.sh; then
608 ac_aux_dir=$ac_dir
609 ac_install_sh="$ac_aux_dir/install.sh -c"
610 break
611 fi
612done
613if test -z "$ac_aux_dir"; then
614 { echo "configure: error: can not find install-sh or install.sh in scripts $srcdir/scripts" 1>&2; exit 1; }
615fi
a808d541
UD
616ac_config_guess=$ac_aux_dir/config.guess
617ac_config_sub=$ac_aux_dir/config.sub
618ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
444518fe 619
cd6ede75
UD
620
621# This will get text that should go into config.make.
622config_vars=
623
624# Check for a --with-gmp argument and set gmp-srcdir in config.make.
625# Check whether --with-gmp or --without-gmp was given.
626if test "${with_gmp+set}" = set; then
627 withval="$with_gmp"
628 case "$with_gmp" in
629yes) { echo "configure: error: --with-gmp requires an argument; use --with-gmp=DIRECTORY" 1>&2; exit 1; } ;;
630''|no) ;;
631*) config_vars="$config_vars
632gmp-srcdir = $withval" ;;
633esac
634
635fi
636
c8f3e6db
UD
637# Check for a --with-gd argument and set libgd-LDFLAGS in config.make.
638# Check whether --with-gd or --without-gd was given.
639if test "${with_gd+set}" = set; then
640 withval="$with_gd"
641 case "$with_gd" in
e41db95b
UD
642yes|''|no) ;;
643*) libgd_include="-I$withval/include"
c8f3e6db
UD
644 libgd_ldflags="-L$withval/lib" ;;
645esac
646
647fi
648
e41db95b
UD
649# Check whether --with-gd-include or --without-gd-include was given.
650if test "${with_gd_include+set}" = set; then
651 withval="$with_gd_include"
652 case "$with_gd_include" in
653''|no) ;;
654*) libgd_include="-I$withval" ;;
655esac
656
657fi
658
659# Check whether --with-gd-lib or --without-gd-lib was given.
660if test "${with_gd_lib+set}" = set; then
661 withval="$with_gd_lib"
662 case "$with_gd_lib" in
663''|no) ;;
664*) libgd_ldflags="-L$withval" ;;
665esac
666
667fi
668
669
670if test -n "$libgd_include"; then
671 config_vars="$config_vars
cf90163d 672CFLAGS-memusagestat.c = $libgd_include"
e41db95b
UD
673fi
674if test -n "$libgd_ldflags"; then
675 config_vars="$config_vars
676libgd-LDFLAGS = $libgd_ldflags"
677fi
cd6ede75
UD
678
679# Check whether --with-fp or --without-fp was given.
680if test "${with_fp+set}" = set; then
681 withval="$with_fp"
682 with_fp=$withval
683else
684 with_fp=yes
685fi
686
675322a5 687
650425ce
UD
688# Check whether --with-binutils or --without-binutils was given.
689if test "${with_binutils+set}" = set; then
690 withval="$with_binutils"
a5a0310d
UD
691 path_binutils=$withval
692else
650425ce 693 path_binutils=''
cd6ede75
UD
694fi
695
cd6ede75
UD
696# Check whether --with-elf or --without-elf was given.
697if test "${with_elf+set}" = set; then
698 withval="$with_elf"
699 elf=$withval
700else
701 elf=no
702fi
703
5af3245a
UD
704# Check whether --with-xcoff or --without-xcoff was given.
705if test "${with_xcoff+set}" = set; then
706 withval="$with_xcoff"
707 xcoff=$withval
708else
709 xcoff=no
710fi
711
d67281a7
UD
712# Check whether --with-cvs or --without-cvs was given.
713if test "${with_cvs+set}" = set; then
714 withval="$with_cvs"
715 with_cvs=$withval
716else
717 with_cvs=yes
718fi
719
6b3f2b3d
UD
720if test "$with_cvs" = yes; then
721 if test -d $srcdir/CVS && grep :pserver: $srcdir/CVS/Root > /dev/null
722 then
723 with_cvs=no
724 fi
4442d7e8 725fi
d67281a7 726
cd6ede75 727
3c720987
UD
728# Check whether --with-headers or --without-headers was given.
729if test "${with_headers+set}" = set; then
730 withval="$with_headers"
731 sysheaders=$withval
732else
733 sysheaders=''
734fi
735
736
cd6ede75
UD
737# Check whether --enable-libio or --disable-libio was given.
738if test "${enable_libio+set}" = set; then
739 enableval="$enable_libio"
740 if test $enableval = yes; then
741 stdio=libio
742 else
743 stdio=stdio
744 fi
745else
746 stdio=default
747fi
748
749
750# Check whether --enable-sanity-checks or --disable-sanity-checks was given.
751if test "${enable_sanity_checks+set}" = set; then
752 enableval="$enable_sanity_checks"
753 enable_sanity=$enableval
754else
755 enable_sanity=yes
756fi
757
758
5c2a0669 759static=yes
cd6ede75
UD
760# Check whether --enable-shared or --disable-shared was given.
761if test "${enable_shared+set}" = set; then
762 enableval="$enable_shared"
763 shared=$enableval
764else
765 shared=default
766fi
767
768# Check whether --enable-profile or --disable-profile was given.
769if test "${enable_profile+set}" = set; then
770 enableval="$enable_profile"
771 profile=$enableval
772else
773 profile=yes
774fi
775
776# Check whether --enable-omitfp or --disable-omitfp was given.
777if test "${enable_omitfp+set}" = set; then
778 enableval="$enable_omitfp"
779 omitfp=$enableval
780else
781 omitfp=no
782fi
783
784# Check whether --enable-bounded or --disable-bounded was given.
785if test "${enable_bounded+set}" = set; then
786 enableval="$enable_bounded"
787 bounded=$enableval
788else
789 bounded=no
790fi
791
650425ce
UD
792# Check whether --enable-versioning or --disable-versioning was given.
793if test "${enable_versioning+set}" = set; then
794 enableval="$enable_versioning"
795 enable_versioning=$enableval
796else
797 enable_versioning=yes
798fi
799
cd6ede75 800
62ab42d6
UD
801# Check whether --enable-oldest-abi or --disable-oldest-abi was given.
802if test "${enable_oldest_abi+set}" = set; then
803 enableval="$enable_oldest_abi"
804 oldest_abi=$enableval
805else
806 oldest_abi=no
807fi
808
809if test "$oldest_abi" = yes || test "$oldest_abi" = no; then
810 oldest_abi=default
811else
812 cat >> confdefs.h <<EOF
813#define GLIBC_OLDEST_ABI "$oldest_abi"
814EOF
815
816fi
817
818
cd6ede75
UD
819# Check whether --enable-add-ons or --disable-add-ons was given.
820if test "${enable_add_ons+set}" = set; then
821 enableval="$enable_add_ons"
61952351 822 case "$enableval" in
9c4c0024
UD
823 yes) add_ons=`cd $srcdir && echo */configure | sed -e 's!/configure!!g'`
824 test "$add_ons" = "*" && add_ons= ;;
61952351
UD
825 *) add_ons=`echo "$enableval" | sed 's/,/ /g'`;;
826 esac
cd6ede75
UD
827else
828 add_ons=
829fi
830
61952351 831
8d4b5a8a
UD
832# Check whether --with-tls or --without-tls was given.
833if test "${with_tls+set}" = set; then
834 withval="$with_tls"
835 usetls=$withval
836else
837 usetls=yes
838fi
839
840
cd6ede75
UD
841subdirs="$add_ons"
842
843add_ons_pfx=
844if test x"$add_ons" != x; then
845 for f in $add_ons; do
aa44a9de
AJ
846 # Some sanity checks
847 if test "$f" = "crypt"; then
848 { echo "configure: error:
849*** It seems that you're using an old \`crypt' add-on. crypt is now
850*** part of glibc and using the old add-on will not work with this
851*** release. Start again with fresh sources and without the old
852*** \`crypt' add-on." 1>&2; exit 1; }
853 fi
854 if test "$f" = "localedata"; then
855 { echo "configure: error:
856*** It seems that you're using an old \`localedata' add-on. localedata
857*** is now part of glibc and using the old add-on will not work with
858*** this release. Start again with fresh sources and without the old
859*** \`localedata' add-on." 1>&2; exit 1; }
860 fi
af6f3906
UD
861 # Test whether such a subdir really exists.
862 if test -d $srcdir/$f; then
863 add_ons_pfx="$add_ons_pfx $f/"
864 else
865 { echo "configure: error: add-on directory \"$f\" does not exist" 1>&2; exit 1; }
866 fi
cd6ede75
UD
867 done
868fi
869
870# Check whether --enable-static-nss or --disable-static-nss was given.
871if test "${enable_static_nss+set}" = set; then
872 enableval="$enable_static_nss"
873 static_nss=$enableval
874else
875 static_nss=no
876fi
877
878if test x"$static_nss" = xyes; then
879 cat >> confdefs.h <<\EOF
880#define DO_STATIC_NSS 1
881EOF
882
883fi
884
73237de3
UD
885# Check whether --enable-force-install or --disable-force-install was given.
886if test "${enable_force_install+set}" = set; then
887 enableval="$enable_force_install"
888 force_install=$enableval
889else
890 force_install=yes
891fi
892
893
894
958f238f
UD
895# Check whether --enable-kernel or --disable-kernel was given.
896if test "${enable_kernel+set}" = set; then
897 enableval="$enable_kernel"
898 minimum_kernel=$enableval
cd6ede75
UD
899fi
900
654de60c
UD
901if test "$minimum_kernel" = yes || test "$minimum_kernel" = no; then
902 # Better nothing than this.
903 minimum_kernel=""
78bba25c
UD
904else
905 if test "$minimum_kernel" = current; then
906 minimum_kernel=`uname -r 2>/dev/null` || minimum_kernel=
907 fi
654de60c 908fi
958f238f 909
6cc7d725
UD
910# Check whether --enable-all-warnings or --disable-all-warnings was given.
911if test "${enable_all_warnings+set}" = set; then
912 enableval="$enable_all_warnings"
913 all_warnings=$enableval
914fi
915
916
958f238f 917
2a068d20 918
958f238f 919# Make sure we can run config.sub.
a808d541
UD
920if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
921else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
958f238f
UD
922fi
923
a808d541 924echo $ac_n "checking host system type""... $ac_c" 1>&6
8d4b5a8a 925echo "configure:926: checking host system type" >&5
958f238f 926
a808d541
UD
927host_alias=$host
928case "$host_alias" in
929NONE)
930 case $nonopt in
931 NONE)
932 if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
933 else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
934 fi ;;
935 *) host_alias=$nonopt ;;
936 esac ;;
937esac
cd6ede75 938
a808d541
UD
939host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
940host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
941host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
942host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
943echo "$ac_t""$host" 1>&6
cd6ede75
UD
944
945
946# The way shlib-versions is used to generate soversions.mk uses a
947# fairly simplistic model for name recognition that can't distinguish
948# i486-pc-linux-gnu fully from i486-pc-gnu. So we mutate a $host_os
949# of `gnu*' here to be `gnu-gnu*' just so that shlib-versions can
950# tell. This doesn't get used much beyond that, so it's fairly safe.
951case "$host_os" in
952linux*)
953 ;;
954gnu*)
955 host_os=`echo $host_os | sed -e 's/gnu/gnu-gnu/'`
956 ;;
957esac
958
959# We keep the original values in `$config_*' and never modify them, so we
960# can write them unchanged into config.make. Everything else uses
961# $machine, $vendor, and $os, and changes them whenever convenient.
962config_machine=$host_cpu config_vendor=$host_vendor config_os=$host_os
963
0816838f
UD
964# Don't allow vendor == "unknown"
965test "$config_vendor" = unknown && config_vendor=
966config_os="`echo $config_os | sed 's/^unknown-//'`"
967
cd6ede75
UD
968# Some configurations imply other options.
969case "$host_os" in
970gnu* | linux* | bsd4.4* | netbsd* | freebsd*)
971 # These systems always use GNU tools.
972 gnu_ld=yes gnu_as=yes ;;
973esac
974case "$host_os" in
975# i586-linuxaout is mangled into i586-pc-linux-gnuaout
976linux*ecoff* | linux*aout* | gnu*aout* | gnu*ecoff*)
977 ;;
9a97d1f7 978gnu* | linux* | sysv4* | solaris2* | irix6*)
cd6ede75
UD
979 # These systems (almost) always use the ELF format.
980 elf=yes
981 ;;
5af3245a
UD
982aix*)
983 # These systems are always xcoff
984 xcoff=yes
a711b01d 985 elf=no
5af3245a 986 ;;
cd6ede75
UD
987esac
988
989machine=$config_machine
990vendor=$config_vendor
991os=$config_os
992
a808d541
UD
993# config.guess on some IBM machines says `rs6000' instead of `powerpc'.
994# Unify this here.
995if test "$machine" = rs6000; then
996 machine="powerpc"
997fi
998
7efb9bd1
UD
999###
1000### I put this here to prevent those annoying emails from people who cannot
1001### read and try to compile glibc on unsupported platforms. --drepper
1002###
1003### By using the undocumented --enable-hacker-mode option for configure
1004### one can skip this test to make the configuration not fail for unsupported
1005### platforms.
1006###
1007if test -z "$enable_hacker_mode"; then
1008 case "$machine-$host_os" in
f0d8cfd7 1009 *-linux* | *-gnu* | arm*-none* | powerpc-aix4.3.*)
7efb9bd1
UD
1010 ;;
1011 *)
1012 echo "*** The GNU C library is currently not available for this platform."
1013 echo "*** So far nobody cared to port it and if there is no volunteer it"
1014 echo "*** might never happen. So, if you have interest to see glibc on"
1015 echo "*** this platform visit"
1016 echo "*** http://www.gnu.org/software/libc/porting.html"
1017 echo "*** and join the group of porters"
1018 exit 1
1019 ;;
1020 esac
1021fi
1022
cd6ede75
UD
1023# Expand the configuration machine name into a subdirectory by architecture
1024# type and particular chip.
1025case "$machine" in
1026a29k | am29000) base_machine=a29k machine=a29k ;;
1027alpha*) base_machine=alpha machine=alpha/$machine ;;
0c8b61e6 1028arm*) base_machine=arm machine=arm/arm32/$machine ;;
60c96635
UD
1029c3[012]) base_machine=cx0 machine=cx0/c30 ;;
1030c4[04]) base_machine=cx0 machine=cx0/c40 ;;
b15cb495
UD
1031hppa*64*) base_machine=hppa machine=hppa/hppa64 ;;
1032hppa*) base_machine=hppa machine=hppa/hppa1.1 ;;
cd6ede75 1033i[3456]86) base_machine=i386 machine=i386/$machine ;;
9dfa9a5a 1034ia64) base_machine=ia64 machine=ia64 ;;
cd6ede75
UD
1035m680?0) base_machine=m68k machine=m68k/$machine ;;
1036m68k) base_machine=m68k machine=m68k/m68020 ;;
1037m88???) base_machine=m88k machine=m88k/$machine ;;
1038m88k) base_machine=m88k machine=m88k/m88100 ;;
1039mips64*) base_machine=mips64 machine=mips/mips64/$machine ;;
2b904739 1040mips*) base_machine=mips machine=mips/$machine ;;
136d4332
UD
1041s390) base_machine=s390 machine=s390/s390-32 ;;
1042s390x) base_machine=s390 machine=s390/s390-64 ;;
0da2f50b
UD
1043sh3*) base_machine=sh machine=sh/sh3 ;;
1044sh4*) base_machine=sh machine=sh/sh4 ;;
ca34d7a7
UD
1045sparc | sparcv[67])
1046 base_machine=sparc machine=sparc/sparc32 ;;
1047sparcv8 | supersparc | hypersparc)
1048 base_machine=sparc machine=sparc/sparc32/sparcv8 ;;
ae6b8730
RH
1049sparcv8plus | sparcv8plusa | sparcv9)
1050 base_machine=sparc machine=sparc/sparc32/sparcv9 ;;
bb769ab6
UD
1051sparcv8plusb | sparcv9b)
1052 base_machine=sparc machine=sparc/sparc32/sparcv9b ;;
ca34d7a7
UD
1053sparc64 | ultrasparc)
1054 base_machine=sparc machine=sparc/sparc64 ;;
bb769ab6
UD
1055sparc64b | ultrasparc3)
1056 base_machine=sparc machine=sparc/sparc64/sparcv9b ;;
0c8b61e6 1057thumb*) base_machine=thumb machine=arm/thumb/$machine ;;
3a2832a0 1058*) base_machine=$machine ;;
cd6ede75
UD
1059esac
1060
1061
dfd2257a
UD
1062if test "$base_machine" = "i386"; then
1063 cat >> confdefs.h <<\EOF
1064#define USE_REGPARMS 1
1065EOF
1066
1067fi
1068
cd6ede75
UD
1069# Compute the list of sysdep directories for this configuration.
1070# This can take a while to compute.
1071sysdep_dir=$srcdir/sysdeps
1072echo $ac_n "checking sysdep dirs""... $ac_c" 1>&6
2b904739 1073echo "configure:1074: checking sysdep dirs" >&5
cd6ede75
UD
1074# Make sco3.2v4 become sco3.2.4 and sunos4.1.1_U1 become sunos4.1.1.U1.
1075os="`echo $os | sed 's/\([0-9A-Z]\)[v_]\([0-9A-Z]\)/\1.\2/g'`"
1076
1077case "$os" in
1078gnu*)
1079 base_os=mach/hurd ;;
1080netbsd* | 386bsd* | freebsd* | bsdi*)
1081 base_os=unix/bsd/bsd4.4 ;;
1082osf* | sunos* | ultrix* | newsos* | dynix* | *bsd*)
1083 base_os=unix/bsd ;;
1084sysv* | isc* | esix* | sco* | minix* | irix4* | linux*)
1085 base_os=unix/sysv ;;
9a97d1f7
UD
1086irix6*)
1087 base_os=unix/sysv/irix6/$os ;;
cd6ede75
UD
1088solaris[2-9]*)
1089 base_os=unix/sysv/sysv4 ;;
908c3d5b
UD
1090hpux*)
1091 base_os=unix/sysv/hpux/$os ;;
f0d8cfd7
UD
1092aix4.3*)
1093 base_os=unix/sysv/aix/aix4.3 ;;
cd6ede75
UD
1094none)
1095 base_os=standalone ;;
1096*)
1097 base_os='' ;;
1098esac
1099
1100# For sunos4.1.1, try sunos4.1.1, then sunos4.1, then sunos4, then sunos.
1101tail=$os
1102ostry=$os
1103while o=`echo $tail | sed 's/\.[^.]*$//'`; test $o != $tail; do
1104 ostry="$ostry /$o"
1105 tail=$o
1106done
1107o=`echo $tail | sed 's/[0-9]*$//'`
1108if test $o != $tail; then
1109 ostry="$ostry /$o"
1110fi
1111# For linux-gnu, try linux-gnu, then linux.
1112o=`echo $tail | sed 's/-.*$//'`
1113if test $o != $tail; then
1114 ostry="$ostry /$o"
1115fi
1116
1117# For unix/sysv/sysv4, try unix/sysv/sysv4, then unix/sysv, then unix.
1118base=
1119tail=$base_os
1120while b=`echo $tail | sed 's@^\(.*\)/\([^/]*\)$@& \1@'`; test -n "$b"; do
1121 set $b
1122 base="$base /$1"
1123 tail="$2"
1124done
1125
ae6b8730 1126# For sparc/sparc32, try sparc/sparc32 and then sparc.
cd6ede75
UD
1127mach=
1128tail=$machine
1129while m=`echo $tail | sed 's@^\(.*\)/\([^/]*\)$@& \1@'`; test -n "$m"; do
1130 set $m
1131 # Prepend the machine's FPU directory unless --without-fp.
1132 if test "$with_fp" = yes; then
1133 mach="$mach /$1/fpu"
1134 fi
1135 mach="$mach /$1"
1136 tail="$2"
1137done
1138
1139
1140# Find what sysdep directories exist.
1141sysnames=
1142IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1143for d in $add_ons_pfx ''; do
1144 for b in $base ''; do
1145 for m0 in $mach ''; do
1146 for v in /$vendor ''; do
ae828bc6 1147 test "$v" = / && continue
cd6ede75 1148 for o in /$ostry ''; do
ae828bc6 1149 test "$o" = / && continue
cd6ede75
UD
1150 for m in $mach ''; do
1151 if test "$m0$b$v$o$m"; then
1152 try="${d}sysdeps$m0$b$v$o$m"
1153 test -n "$enable_debug_configure" &&
1154 echo "$0 DEBUG: try $try" >&2
9c4c0024 1155 if test -d $srcdir/$try; then
cd6ede75
UD
1156 sysnames="$sysnames $try"
1157 { test -n "$o" || test -n "$b"; } && os_used=t
1158 { test -n "$m" || test -n "$m0"; } && machine_used=t
1159 fi
1160 fi
1161 done
1162 done
1163 done
1164 done
1165 done
1166done
1167IFS="$ac_save_ifs"
1168
1169if test -z "$os_used" && test "$os" != none; then
1170 { echo "configure: error: Operating system $os is not supported." 1>&2; exit 1; }
1171fi
1172if test -z "$machine_used" && test "$machine" != none; then
1173 { echo "configure: error: The $machine is not supported." 1>&2; exit 1; }
1174fi
1175
1176# We have now validated the configuration.
1177
1178
1179# If using ELF, look for an `elf' subdirectory of each machine directory.
1180# We prepend these rather than inserting them whereever the machine appears
1181# because things specified by the machine's ELF ABI should override
1182# OS-specific things, and should always be the same for any OS on the
1183# machine (otherwise what's the point of an ABI?).
1184if test "$elf" = yes; then
1185 elf_dirs=
1186 for d in $add_ons_pfx ''; do
cd6ede75 1187 for m in $mach; do
9c4c0024 1188 if test -d $srcdir/${d}sysdeps$m/elf; then
cd6ede75
UD
1189 elf_dirs="$elf_dirs ${d}sysdeps$m/elf"
1190 fi
1191 done
1192 done
1193 sysnames="`echo $elf_dirs | sed -e 's,//,/,g'` $sysnames"
1194fi
1195
1196
1197# Expand the list of system names into a full list of directories
1198# from each element's parent name and Implies file (if present).
1199set $sysnames
1200names=
1201while test $# -gt 0; do
1202 name=$1
1203 shift
1204
1205 case " $names " in *" $name "*)
1206 # Already in the list.
1207 continue
1208 esac
1209
1210 # Report each name as we discover it, so there is no long pause in output.
1211 echo $ac_n "$name $ac_c" >&6
1212
1213 name_base=`echo $name | sed -e 's@\(.*sysdeps\)/.*@\1@'`
1214
1215 case $name in
1216 /*) xsrcdir= ;;
1217 *) xsrcdir=$srcdir/ ;;
1218 esac
1219 test -n "$enable_debug_configure" &&
1220 echo "DEBUG: name/Implies $xsrcdir$name/Implies" >&2
1221
1222 if test -f $xsrcdir$name/Implies; then
1223 # Collect more names from the `Implies' file (removing comments).
1224 implied_candidate="`sed 's/#.*$//' < $xsrcdir$name/Implies`"
1225 implied=
1226 for x in $implied_candidate; do
636ccfc8 1227 found=no
cd6ede75
UD
1228 if test -d $xsrcdir$name_base/$x; then
1229 implied="$implied $name_base/$x";
636ccfc8
UD
1230 found=yes
1231 fi
1232 for d in $add_ons_pfx ''; do
1233 try="${d}sysdeps/$x"
1234 case $d in
1235 /*) try_srcdir= ;;
1236 *) try_srcdir=$srcdir/ ;;
1237 esac
1238 test -n "$enable_debug_configure" &&
1239 echo "DEBUG: $name implied $x try($d) {$try_srcdir}$try" >&2
1240 if test $try != $xsrcdir$name_base/$x && test -d $try_srcdir$try;
1241 then
1242 implied="$implied $try"
1243 found=yes
1244 fi
1245 done
1246 if test $found = no; then
cd6ede75
UD
1247 echo "configure: warning: $name/Implies specifies nonexistent $x" 1>&2
1248 fi
1249 done
1250 else
1251 implied=
1252 fi
1253
1254 # Add NAME to the list of names.
1255 names="$names $name"
1256
1257 # Find the parent of NAME, using the empty string if it has none.
1258 parent="`echo $name | sed -n -e 's=/[^/]*$==' -e '/sysdeps$/q' -e p`"
1259
1260 # Add the names implied by NAME, and NAME's parent (if it has one), to
1261 # the list of names to be processed (the argument list). We prepend the
1262 # implied names to the list and append the parent. We want implied
1263 # directories to come before further directories inferred from the
1264 # configuration components; this ensures that for sysv4, unix/common
1265 # (implied by unix/sysv/sysv4) comes before unix/sysv (in ostry (here $*)
1266 # after sysv4).
1267 sysnames="`echo $implied $* $parent`"
1268 test -n "$sysnames" && set $sysnames
1269done
1270
1271# Add the default directories.
a3a4a74e 1272default_sysnames=sysdeps/generic
2de7874e 1273if test "$elf" = yes; then
a3a4a74e 1274 default_sysnames="sysdeps/generic/elf $default_sysnames"
2de7874e 1275fi
a3a4a74e 1276sysnames="$names $default_sysnames"
cd6ede75
UD
1277
1278# The other names were emitted during the scan.
a3a4a74e 1279echo "$ac_t""$default_sysnames" 1>&6
cd6ede75
UD
1280
1281
1282### Locate tools.
1283
1284# Find a good install program. We prefer a C program (faster),
1285# so one script is as good as another. But avoid the broken or
1286# incompatible versions:
1287# SysV /etc/install, /usr/sbin/install
1288# SunOS /usr/etc/install
1289# IRIX /sbin/install
1290# AIX /bin/install
5c2a0669 1291# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
cd6ede75
UD
1292# AFS /usr/afsws/bin/install, which mishandles nonexistent args
1293# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
1294# ./install, which can be erroneously created by make from ./install.sh.
1295echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
2b904739 1296echo "configure:1297: checking for a BSD compatible install" >&5
cd6ede75 1297if test -z "$INSTALL"; then
a808d541 1298if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
cd6ede75
UD
1299 echo $ac_n "(cached) $ac_c" 1>&6
1300else
5c2a0669 1301 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":"
cd6ede75
UD
1302 for ac_dir in $PATH; do
1303 # Account for people who put trailing slashes in PATH elements.
1304 case "$ac_dir/" in
1305 /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
1306 *)
1307 # OSF1 and SCO ODT 3.0 have their own names for install.
5c2a0669
UD
1308 # Don't use installbsd from OSF since it installs stuff as root
1309 # by default.
1310 for ac_prog in ginstall scoinst install; do
cd6ede75
UD
1311 if test -f $ac_dir/$ac_prog; then
1312 if test $ac_prog = install &&
1313 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
1314 # AIX install. It has an incompatible calling convention.
cd6ede75
UD
1315 :
1316 else
1317 ac_cv_path_install="$ac_dir/$ac_prog -c"
1318 break 2
1319 fi
1320 fi
1321 done
1322 ;;
1323 esac
1324 done
1325 IFS="$ac_save_IFS"
1326
1327fi
1328 if test "${ac_cv_path_install+set}" = set; then
1329 INSTALL="$ac_cv_path_install"
1330 else
1331 # As a last resort, use the slow shell script. We don't cache a
1332 # path for INSTALL within a source directory, because that will
1333 # break other packages using the cache if that directory is
1334 # removed, or if the path is relative.
1335 INSTALL="$ac_install_sh"
1336 fi
1337fi
1338echo "$ac_t""$INSTALL" 1>&6
1339
1340# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
1341# It thinks the first close brace ends the variable substitution.
1342test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
1343
a808d541 1344test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
5c2a0669 1345
cd6ede75
UD
1346test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
1347
ed9c47d9 1348if test "$INSTALL" = "${srcdir}/scripts/install-sh -c"; then
cd6ede75 1349 # The makefiles need to use a different form to find it in $srcdir.
ed9c47d9 1350 INSTALL='\$(..)./scripts/install-sh -c'
cd6ede75
UD
1351fi
1352echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
2b904739 1353echo "configure:1354: checking whether ln -s works" >&5
a808d541 1354if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
cd6ede75
UD
1355 echo $ac_n "(cached) $ac_c" 1>&6
1356else
1357 rm -f conftestdata
1358if ln -s X conftestdata 2>/dev/null
1359then
1360 rm -f conftestdata
1361 ac_cv_prog_LN_S="ln -s"
1362else
1363 ac_cv_prog_LN_S=ln
1364fi
1365fi
1366LN_S="$ac_cv_prog_LN_S"
1367if test "$ac_cv_prog_LN_S" = "ln -s"; then
1368 echo "$ac_t""yes" 1>&6
1369else
1370 echo "$ac_t""no" 1>&6
1371fi
1372
63bda0c1 1373
c218729d
UD
1374# We need the physical current working directory. We cannot use the
1375# "pwd -P" shell builtin since that's not portable. Instead we try to
1376# find a pwd binary. Note that assigning to the PWD environment
1377# variable might have some interesting side effects, so we don't do
1378# that.
1379# Extract the first word of "pwd", so it can be a program name with args.
1380set dummy pwd; ac_word=$2
1381echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2b904739 1382echo "configure:1383: checking for $ac_word" >&5
c218729d
UD
1383if eval "test \"`echo '$''{'ac_cv_path_PWD_P'+set}'`\" = set"; then
1384 echo $ac_n "(cached) $ac_c" 1>&6
1385else
1386 case "$PWD_P" in
1387 /*)
1388 ac_cv_path_PWD_P="$PWD_P" # Let the user override the test with a path.
1389 ;;
1390 ?:/*)
1391 ac_cv_path_PWD_P="$PWD_P" # Let the user override the test with a dos path.
1392 ;;
1393 *)
1394 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1395 ac_dummy="$PATH"
1396 for ac_dir in $ac_dummy; do
1397 test -z "$ac_dir" && ac_dir=.
1398 if test -f $ac_dir/$ac_word; then
1399 ac_cv_path_PWD_P="$ac_dir/$ac_word"
1400 break
1401 fi
1402 done
1403 IFS="$ac_save_ifs"
1404 test -z "$ac_cv_path_PWD_P" && ac_cv_path_PWD_P="no"
1405 ;;
1406esac
1407fi
1408PWD_P="$ac_cv_path_PWD_P"
1409if test -n "$PWD_P"; then
1410 echo "$ac_t""$PWD_P" 1>&6
1411else
1412 echo "$ac_t""no" 1>&6
1413fi
1414
1415if test "$PWD_P" = no; then
1416 { echo "configure: error: *** A pwd binary could not be found." 1>&2; exit 1; }
1417fi
1418
63bda0c1 1419# These programs are version sensitive.
4bca4c17 1420echo $ac_n "checking build system type""... $ac_c" 1>&6
2b904739 1421echo "configure:1422: checking build system type" >&5
a808d541
UD
1422
1423build_alias=$build
1424case "$build_alias" in
1425NONE)
1426 case $nonopt in
1427 NONE) build_alias=$host_alias ;;
1428 *) build_alias=$nonopt ;;
1429 esac ;;
1430esac
4bca4c17 1431
a808d541
UD
1432build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias`
1433build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1434build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1435build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1436echo "$ac_t""$build" 1>&6
4bca4c17
UD
1437
1438if test $host != $build; then
1439 ac_tool_prefix=${host_alias}-
1440else
1441 ac_tool_prefix=
1442fi
1443
1444for ac_prog in ${ac_tool_prefix}gcc ${ac_tool_prefix}cc
1445do
1446# Extract the first word of "$ac_prog", so it can be a program name with args.
1447set dummy $ac_prog; ac_word=$2
1448echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2b904739 1449echo "configure:1450: checking for $ac_word" >&5
a808d541 1450if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
cd6ede75
UD
1451 echo $ac_n "(cached) $ac_c" 1>&6
1452else
63bda0c1
UD
1453 if test -n "$CC"; then
1454 ac_cv_prog_CC="$CC" # Let the user override the test.
cd6ede75 1455else
5c2a0669
UD
1456 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1457 ac_dummy="$PATH"
1458 for ac_dir in $ac_dummy; do
4bca4c17
UD
1459 test -z "$ac_dir" && ac_dir=.
1460 if test -f $ac_dir/$ac_word; then
1461 ac_cv_prog_CC="$ac_prog"
1462 break
1463 fi
cd6ede75
UD
1464 done
1465 IFS="$ac_save_ifs"
1466fi
1467fi
4bca4c17
UD
1468CC="$ac_cv_prog_CC"
1469if test -n "$CC"; then
1470 echo "$ac_t""$CC" 1>&6
1471else
cd6ede75 1472 echo "$ac_t""no" 1>&6
4bca4c17
UD
1473fi
1474
1475test -n "$CC" && break
1476done
1477
1478if test -z "$CC"; then
1479 ac_verc_fail=yes
63bda0c1 1480else
4bca4c17
UD
1481 # Found it, now check the version.
1482 echo $ac_n "checking version of $CC""... $ac_c" 1>&6
2b904739 1483echo "configure:1484: checking version of $CC" >&5
9dfa9a5a 1484 ac_prog_version=`$CC -v 2>&1 | sed -n 's/^.*version \([egcygnustpi-]*[0-9.]*\).*$/\1/p'`
4bca4c17
UD
1485 case $ac_prog_version in
1486 '') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
d60a7756 1487 *gcc-2.9[5-9].*|*2.8.[1-9]*|*2.9|*2.9.[0-9]*|2.9[5-9]*|3.[0-9]*|cygnus-2.9[1-9]*|gcc-2.9[5-9]|gcc-2.1[0-9][0-9]|sgicc-*)
4bca4c17
UD
1488 ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;;
1489 *) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
1490
63bda0c1 1491 esac
4bca4c17
UD
1492 echo "$ac_t""$ac_prog_version" 1>&6
1493fi
1494if test $ac_verc_fail = yes; then
6b4e880f 1495 critic_missing=gcc
ae828bc6
UD
1496fi
1497
22e65f8f 1498for ac_prog in gnumake gmake make
4bca4c17
UD
1499do
1500# Extract the first word of "$ac_prog", so it can be a program name with args.
1501set dummy $ac_prog; ac_word=$2
1502echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2b904739 1503echo "configure:1504: checking for $ac_word" >&5
a808d541 1504if eval "test \"`echo '$''{'ac_cv_prog_MAKE'+set}'`\" = set"; then
04be94a8
UD
1505 echo $ac_n "(cached) $ac_c" 1>&6
1506else
63bda0c1
UD
1507 if test -n "$MAKE"; then
1508 ac_cv_prog_MAKE="$MAKE" # Let the user override the test.
04be94a8 1509else
5c2a0669
UD
1510 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1511 ac_dummy="$PATH"
1512 for ac_dir in $ac_dummy; do
4bca4c17
UD
1513 test -z "$ac_dir" && ac_dir=.
1514 if test -f $ac_dir/$ac_word; then
1515 ac_cv_prog_MAKE="$ac_prog"
1516 break
1517 fi
04be94a8
UD
1518 done
1519 IFS="$ac_save_ifs"
1520fi
1521fi
4bca4c17
UD
1522MAKE="$ac_cv_prog_MAKE"
1523if test -n "$MAKE"; then
1524 echo "$ac_t""$MAKE" 1>&6
1525else
04be94a8 1526 echo "$ac_t""no" 1>&6
4bca4c17
UD
1527fi
1528
1529test -n "$MAKE" && break
1530done
1531
1532if test -z "$MAKE"; then
1533 ac_verc_fail=yes
63bda0c1 1534else
4bca4c17
UD
1535 # Found it, now check the version.
1536 echo $ac_n "checking version of $MAKE""... $ac_c" 1>&6
2b904739 1537echo "configure:1538: checking version of $MAKE" >&5
8fc1e2ca 1538 ac_prog_version=`$MAKE --version 2>&1 | sed -n 's/^.*GNU Make[^0-9]*\([0-9][0-9.]*\).*$/\1/p'`
4bca4c17
UD
1539 case $ac_prog_version in
1540 '') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
2bbc70d5 1541 3.79* | 3.[89]*)
4bca4c17
UD
1542 ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;;
1543 *) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
1544
63bda0c1 1545 esac
4bca4c17
UD
1546 echo "$ac_t""$ac_prog_version" 1>&6
1547fi
1548if test $ac_verc_fail = yes; then
6b4e880f 1549 critic_missing="$critic_missing make"
04be94a8 1550fi
cd6ede75 1551
63bda0c1 1552
de83fb78
AJ
1553
1554if test -n "$critic_missing"; then
1555{ echo "configure: error:
aefdff34 1556*** These critical programs are missing or too old:$critic_missing
de83fb78
AJ
1557*** Check the INSTALL file for required versions." 1>&2; exit 1; }
1558fi
1559
1560
22e65f8f 1561for ac_prog in gnumsgfmt gmsgfmt msgfmt
4bca4c17
UD
1562do
1563# Extract the first word of "$ac_prog", so it can be a program name with args.
1564set dummy $ac_prog; ac_word=$2
1565echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2b904739 1566echo "configure:1567: checking for $ac_word" >&5
a808d541 1567if eval "test \"`echo '$''{'ac_cv_prog_MSGFMT'+set}'`\" = set"; then
cd6ede75
UD
1568 echo $ac_n "(cached) $ac_c" 1>&6
1569else
63bda0c1
UD
1570 if test -n "$MSGFMT"; then
1571 ac_cv_prog_MSGFMT="$MSGFMT" # Let the user override the test.
cd6ede75 1572else
5c2a0669
UD
1573 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1574 ac_dummy="$PATH"
1575 for ac_dir in $ac_dummy; do
4bca4c17
UD
1576 test -z "$ac_dir" && ac_dir=.
1577 if test -f $ac_dir/$ac_word; then
1578 ac_cv_prog_MSGFMT="$ac_prog"
1579 break
1580 fi
cd6ede75
UD
1581 done
1582 IFS="$ac_save_ifs"
1583fi
1584fi
4bca4c17
UD
1585MSGFMT="$ac_cv_prog_MSGFMT"
1586if test -n "$MSGFMT"; then
1587 echo "$ac_t""$MSGFMT" 1>&6
1588else
cd6ede75 1589 echo "$ac_t""no" 1>&6
4bca4c17
UD
1590fi
1591
1592test -n "$MSGFMT" && break
1593done
1594
1595if test -z "$MSGFMT"; then
1596 ac_verc_fail=yes
63bda0c1 1597else
4bca4c17
UD
1598 # Found it, now check the version.
1599 echo $ac_n "checking version of $MSGFMT""... $ac_c" 1>&6
2b904739 1600echo "configure:1601: checking version of $MSGFMT" >&5
bdd421cc 1601 ac_prog_version=`$MSGFMT --version 2>&1 | sed -n 's/^.*GNU gettext.* \([0-9]*\.[0-9.]*\).*$/\1/p'`
4bca4c17
UD
1602 case $ac_prog_version in
1603 '') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
fbd5e005 1604 0.10.3[6-9]* | 0.10.[4-9][0-9]* | 0.1[1-9]* | 0.[2-9][0-9]* | [1-9].*)
4bca4c17
UD
1605 ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;;
1606 *) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
1607
63bda0c1 1608 esac
4bca4c17
UD
1609 echo "$ac_t""$ac_prog_version" 1>&6
1610fi
1611if test $ac_verc_fail = yes; then
aefdff34 1612 MSGFMT=: aux_missing="$aux_missing msgfmt"
cd6ede75
UD
1613fi
1614
4bca4c17
UD
1615for ac_prog in makeinfo
1616do
1617# Extract the first word of "$ac_prog", so it can be a program name with args.
1618set dummy $ac_prog; ac_word=$2
1619echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2b904739 1620echo "configure:1621: checking for $ac_word" >&5
a808d541 1621if eval "test \"`echo '$''{'ac_cv_prog_MAKEINFO'+set}'`\" = set"; then
cd6ede75
UD
1622 echo $ac_n "(cached) $ac_c" 1>&6
1623else
63bda0c1
UD
1624 if test -n "$MAKEINFO"; then
1625 ac_cv_prog_MAKEINFO="$MAKEINFO" # Let the user override the test.
cd6ede75 1626else
5c2a0669
UD
1627 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1628 ac_dummy="$PATH"
1629 for ac_dir in $ac_dummy; do
4bca4c17
UD
1630 test -z "$ac_dir" && ac_dir=.
1631 if test -f $ac_dir/$ac_word; then
1632 ac_cv_prog_MAKEINFO="$ac_prog"
1633 break
1634 fi
cd6ede75
UD
1635 done
1636 IFS="$ac_save_ifs"
cd6ede75
UD
1637fi
1638fi
4bca4c17
UD
1639MAKEINFO="$ac_cv_prog_MAKEINFO"
1640if test -n "$MAKEINFO"; then
1641 echo "$ac_t""$MAKEINFO" 1>&6
1642else
cd6ede75 1643 echo "$ac_t""no" 1>&6
4bca4c17
UD
1644fi
1645
1646test -n "$MAKEINFO" && break
1647done
1648
1649if test -z "$MAKEINFO"; then
1650 ac_verc_fail=yes
63bda0c1 1651else
4bca4c17
UD
1652 # Found it, now check the version.
1653 echo $ac_n "checking version of $MAKEINFO""... $ac_c" 1>&6
2b904739 1654echo "configure:1655: checking version of $MAKEINFO" >&5
be1d9d95 1655 ac_prog_version=`$MAKEINFO --version 2>&1 | sed -n 's/^.*GNU texinfo.* \([0-9][0-9.]*\).*$/\1/p'`
4bca4c17
UD
1656 case $ac_prog_version in
1657 '') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
1468be21 1658 4.*)
4bca4c17
UD
1659 ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;;
1660 *) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
1661
63bda0c1 1662 esac
4bca4c17
UD
1663 echo "$ac_t""$ac_prog_version" 1>&6
1664fi
1665if test $ac_verc_fail = yes; then
aefdff34 1666 MAKEINFO=: aux_missing="$aux_missing makeinfo"
cd6ede75
UD
1667fi
1668
d6a97a28 1669for ac_prog in sed
aec103d3
UD
1670do
1671# Extract the first word of "$ac_prog", so it can be a program name with args.
1672set dummy $ac_prog; ac_word=$2
1673echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2b904739 1674echo "configure:1675: checking for $ac_word" >&5
a808d541 1675if eval "test \"`echo '$''{'ac_cv_prog_SED'+set}'`\" = set"; then
aec103d3
UD
1676 echo $ac_n "(cached) $ac_c" 1>&6
1677else
1678 if test -n "$SED"; then
1679 ac_cv_prog_SED="$SED" # Let the user override the test.
1680else
1681 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1682 ac_dummy="$PATH"
1683 for ac_dir in $ac_dummy; do
1684 test -z "$ac_dir" && ac_dir=.
1685 if test -f $ac_dir/$ac_word; then
1686 ac_cv_prog_SED="$ac_prog"
1687 break
1688 fi
1689 done
1690 IFS="$ac_save_ifs"
1691fi
1692fi
1693SED="$ac_cv_prog_SED"
1694if test -n "$SED"; then
1695 echo "$ac_t""$SED" 1>&6
1696else
1697 echo "$ac_t""no" 1>&6
1698fi
1699
1700test -n "$SED" && break
1701done
1702
1703if test -z "$SED"; then
1704 ac_verc_fail=yes
1705else
1706 # Found it, now check the version.
1707 echo $ac_n "checking version of $SED""... $ac_c" 1>&6
2b904739 1708echo "configure:1709: checking version of $SED" >&5
aec103d3
UD
1709 ac_prog_version=`$SED --version 2>&1 | sed -n 's/^.*GNU sed version \([0-9]*\.[0-9.]*\).*$/\1/p'`
1710 case $ac_prog_version in
1711 '') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
ce19d417 1712 3.0[2-9]*|3.[1-9]*|[4-9]*)
aec103d3
UD
1713 ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;;
1714 *) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
1715
1716 esac
1717 echo "$ac_t""$ac_prog_version" 1>&6
1718fi
1719if test $ac_verc_fail = yes; then
aefdff34 1720 SED=: aux_missing="$aux_missing sed"
aec103d3
UD
1721fi
1722
cd6ede75 1723
63bda0c1
UD
1724
1725echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
2b904739 1726echo "configure:1727: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
a808d541 1727if eval "test \"`echo '$''{'ac_cv_prog_cc_works'+set}'`\" = set"; then
63bda0c1
UD
1728 echo $ac_n "(cached) $ac_c" 1>&6
1729else
1730
cd6ede75
UD
1731ac_ext=c
1732# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1733ac_cpp='$CPP $CPPFLAGS'
1734ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
5c2a0669 1735ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
cd6ede75
UD
1736cross_compiling=$ac_cv_prog_cc_cross
1737
5c2a0669
UD
1738cat > conftest.$ac_ext << EOF
1739
2b904739 1740#line 1741 "configure"
cd6ede75 1741#include "confdefs.h"
5c2a0669 1742
cd6ede75
UD
1743main(){return(0);}
1744EOF
2b904739 1745if { (eval echo configure:1746: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
cd6ede75
UD
1746 ac_cv_prog_cc_works=yes
1747 # If we can't run a trivial program, we are probably using a cross compiler.
1748 if (./conftest; exit) 2>/dev/null; then
1749 ac_cv_prog_cc_cross=no
1750 else
1751 ac_cv_prog_cc_cross=yes
1752 fi
1753else
1754 echo "configure: failed program was:" >&5
1755 cat conftest.$ac_ext >&5
1756 ac_cv_prog_cc_works=no
1757fi
1758rm -fr conftest*
5c2a0669
UD
1759ac_ext=c
1760# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1761ac_cpp='$CPP $CPPFLAGS'
1762ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1763ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1764cross_compiling=$ac_cv_prog_cc_cross
cd6ede75 1765
63bda0c1
UD
1766fi
1767
cd6ede75
UD
1768echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
1769if test $ac_cv_prog_cc_works = no; then
1770 cross_linkable=no
1771 ac_cv_prog_cc_cross=yes
1772else
1773 cross_linkable=yes
1774fi
1775echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
2b904739 1776echo "configure:1777: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
a808d541 1777if eval "test \"`echo '$''{'ac_cv_prog_cc_cross'+set}'`\" = set"; then
63bda0c1
UD
1778 echo $ac_n "(cached) $ac_c" 1>&6
1779else
1780 :
1781fi
1782
cd6ede75
UD
1783echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
1784
1785cross_compiling=$ac_cv_prog_cc_cross
1786
1787echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
2b904739 1788echo "configure:1789: checking whether we are using GNU C" >&5
a808d541 1789if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
cd6ede75
UD
1790 echo $ac_n "(cached) $ac_c" 1>&6
1791else
1792 cat > conftest.c <<EOF
1793#ifdef __GNUC__
1794 yes;
1795#endif
1796EOF
2b904739 1797if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1798: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
cd6ede75
UD
1798 ac_cv_prog_gcc=yes
1799else
1800 ac_cv_prog_gcc=no
1801fi
1802fi
1803
1804echo "$ac_t""$ac_cv_prog_gcc" 1>&6
63bda0c1 1805if test $ac_cv_prog_gcc != yes; then
cd6ede75
UD
1806 { echo "configure: error: GNU libc must be compiled using GNU CC" 1>&2; exit 1; }
1807fi
1808
1809echo $ac_n "checking build system type""... $ac_c" 1>&6
2b904739 1810echo "configure:1811: checking build system type" >&5
a808d541
UD
1811
1812build_alias=$build
1813case "$build_alias" in
1814NONE)
1815 case $nonopt in
1816 NONE) build_alias=$host_alias ;;
1817 *) build_alias=$nonopt ;;
1818 esac ;;
1819esac
cd6ede75 1820
a808d541
UD
1821build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias`
1822build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1823build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1824build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1825echo "$ac_t""$build" 1>&6
cd6ede75
UD
1826
1827if test $host != $build; then
1828 for ac_prog in gcc cc
1829do
1830# Extract the first word of "$ac_prog", so it can be a program name with args.
1831set dummy $ac_prog; ac_word=$2
1832echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2b904739 1833echo "configure:1834: checking for $ac_word" >&5
a808d541 1834if eval "test \"`echo '$''{'ac_cv_prog_BUILD_CC'+set}'`\" = set"; then
cd6ede75
UD
1835 echo $ac_n "(cached) $ac_c" 1>&6
1836else
1837 if test -n "$BUILD_CC"; then
1838 ac_cv_prog_BUILD_CC="$BUILD_CC" # Let the user override the test.
1839else
5c2a0669
UD
1840 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1841 ac_dummy="$PATH"
1842 for ac_dir in $ac_dummy; do
cd6ede75
UD
1843 test -z "$ac_dir" && ac_dir=.
1844 if test -f $ac_dir/$ac_word; then
1845 ac_cv_prog_BUILD_CC="$ac_prog"
1846 break
1847 fi
1848 done
1849 IFS="$ac_save_ifs"
1850fi
1851fi
1852BUILD_CC="$ac_cv_prog_BUILD_CC"
1853if test -n "$BUILD_CC"; then
1854 echo "$ac_t""$BUILD_CC" 1>&6
1855else
1856 echo "$ac_t""no" 1>&6
1857fi
1858
1859test -n "$BUILD_CC" && break
1860done
1861
1862fi
1863
1864echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
2b904739 1865echo "configure:1866: checking how to run the C preprocessor" >&5
cd6ede75
UD
1866# On Suns, sometimes $CPP names a directory.
1867if test -n "$CPP" && test -d "$CPP"; then
1868 CPP=
1869fi
1870if test -z "$CPP"; then
a808d541 1871if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
cd6ede75
UD
1872 echo $ac_n "(cached) $ac_c" 1>&6
1873else
1874 # This must be in double quotes, not single quotes, because CPP may get
1875 # substituted into the Makefile and "${CC-cc}" will confuse make.
1876 CPP="${CC-cc} -E"
1877 # On the NeXT, cc -E runs the code through the compiler's parser,
1878 # not just through cpp.
1879 cat > conftest.$ac_ext <<EOF
2b904739 1880#line 1881 "configure"
cd6ede75
UD
1881#include "confdefs.h"
1882#include <assert.h>
1883Syntax Error
1884EOF
1885ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2b904739 1886{ (eval echo configure:1887: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5c2a0669 1887ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
cd6ede75
UD
1888if test -z "$ac_err"; then
1889 :
1890else
1891 echo "$ac_err" >&5
1892 echo "configure: failed program was:" >&5
1893 cat conftest.$ac_ext >&5
1894 rm -rf conftest*
1895 CPP="${CC-cc} -E -traditional-cpp"
1896 cat > conftest.$ac_ext <<EOF
2b904739 1897#line 1898 "configure"
cd6ede75
UD
1898#include "confdefs.h"
1899#include <assert.h>
1900Syntax Error
1901EOF
1902ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2b904739 1903{ (eval echo configure:1904: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5c2a0669
UD
1904ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1905if test -z "$ac_err"; then
1906 :
1907else
1908 echo "$ac_err" >&5
1909 echo "configure: failed program was:" >&5
1910 cat conftest.$ac_ext >&5
1911 rm -rf conftest*
1912 CPP="${CC-cc} -nologo -E"
1913 cat > conftest.$ac_ext <<EOF
2b904739 1914#line 1915 "configure"
5c2a0669
UD
1915#include "confdefs.h"
1916#include <assert.h>
1917Syntax Error
1918EOF
1919ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2b904739 1920{ (eval echo configure:1921: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5c2a0669 1921ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
cd6ede75
UD
1922if test -z "$ac_err"; then
1923 :
1924else
1925 echo "$ac_err" >&5
1926 echo "configure: failed program was:" >&5
1927 cat conftest.$ac_ext >&5
1928 rm -rf conftest*
1929 CPP=/lib/cpp
1930fi
1931rm -f conftest*
1932fi
5c2a0669
UD
1933rm -f conftest*
1934fi
cd6ede75
UD
1935rm -f conftest*
1936 ac_cv_prog_CPP="$CPP"
1937fi
1938 CPP="$ac_cv_prog_CPP"
1939else
1940 ac_cv_prog_CPP="$CPP"
1941fi
1942echo "$ac_t""$CPP" 1>&6
1943
650425ce
UD
1944# Was a --with-binutils option given?
1945if test -n "$path_binutils"; then
1946 # Make absolute; ensure a single trailing slash.
1947 path_binutils=`(cd $path_binutils; pwd) | sed 's%/*$%/%'`
63bda0c1 1948 CC="$CC -B$path_binutils"
650425ce 1949fi
27a5bb33
UD
1950AS=`$CC -print-prog-name=as`
1951LD=`$CC -print-prog-name=ld`
5edb9387 1952AR=`$CC -print-prog-name=ar`
cd6ede75
UD
1953
1954
5edb9387
UD
1955# ranlib has to be treated a bit differently since it might not exist at all.
1956RANLIB=`$CC -print-prog-name=ranlib`
1957if test $RANLIB = ranlib; then
1958# This extra check has to happen since gcc simply echos the parameter in
1959# case it cannot find the value in its own directories.
cd6ede75
UD
1960# Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
1961set dummy ${ac_tool_prefix}ranlib; ac_word=$2
1962echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2b904739 1963echo "configure:1964: checking for $ac_word" >&5
a808d541 1964if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
cd6ede75
UD
1965 echo $ac_n "(cached) $ac_c" 1>&6
1966else
1967 if test -n "$RANLIB"; then
1968 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
1969else
5c2a0669
UD
1970 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1971 ac_dummy="$PATH"
1972 for ac_dir in $ac_dummy; do
cd6ede75
UD
1973 test -z "$ac_dir" && ac_dir=.
1974 if test -f $ac_dir/$ac_word; then
1975 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
1976 break
1977 fi
1978 done
1979 IFS="$ac_save_ifs"
1980fi
1981fi
1982RANLIB="$ac_cv_prog_RANLIB"
1983if test -n "$RANLIB"; then
1984 echo "$ac_t""$RANLIB" 1>&6
1985else
1986 echo "$ac_t""no" 1>&6
1987fi
1988
1989
1990if test -z "$ac_cv_prog_RANLIB"; then
1991if test -n "$ac_tool_prefix"; then
1992 # Extract the first word of "ranlib", so it can be a program name with args.
1993set dummy ranlib; ac_word=$2
1994echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2b904739 1995echo "configure:1996: checking for $ac_word" >&5
a808d541 1996if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
cd6ede75
UD
1997 echo $ac_n "(cached) $ac_c" 1>&6
1998else
1999 if test -n "$RANLIB"; then
2000 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
2001else
5c2a0669
UD
2002 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2003 ac_dummy="$PATH"
2004 for ac_dir in $ac_dummy; do
cd6ede75
UD
2005 test -z "$ac_dir" && ac_dir=.
2006 if test -f $ac_dir/$ac_word; then
2007 ac_cv_prog_RANLIB="ranlib"
2008 break
2009 fi
2010 done
2011 IFS="$ac_save_ifs"
2012 test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
2013fi
2014fi
2015RANLIB="$ac_cv_prog_RANLIB"
2016if test -n "$RANLIB"; then
2017 echo "$ac_t""$RANLIB" 1>&6
2018else
2019 echo "$ac_t""no" 1>&6
2020fi
2021
2022else
2023 RANLIB=":"
2024fi
2025fi
2026
5edb9387
UD
2027fi
2028
2029
2030# Determine whether we are using GNU binutils.
2031echo $ac_n "checking whether $AS is GNU as""... $ac_c" 1>&6
2b904739 2032echo "configure:2033: checking whether $AS is GNU as" >&5
a808d541 2033if eval "test \"`echo '$''{'libc_cv_prog_as_gnu'+set}'`\" = set"; then
5edb9387
UD
2034 echo $ac_n "(cached) $ac_c" 1>&6
2035else
2036 # Most GNU programs take a -v and spit out some text including
2037# the word 'GNU'. Some try to read stdin, so give them /dev/null.
2038if $AS -o conftest -v </dev/null 2>&1 | grep GNU > /dev/null 2>&1; then
2039 libc_cv_prog_as_gnu=yes
2040else
2041 libc_cv_prog_as_gnu=no
2042fi
2043rm -fr contest*
2044fi
2045
2046echo "$ac_t""$libc_cv_prog_as_gnu" 1>&6
2047rm -f a.out
2048gnu_as=$libc_cv_prog_as_gnu
2049
2050echo $ac_n "checking whether $LD is GNU ld""... $ac_c" 1>&6
2b904739 2051echo "configure:2052: checking whether $LD is GNU ld" >&5
a808d541 2052if eval "test \"`echo '$''{'libc_cv_prog_ld_gnu'+set}'`\" = set"; then
5edb9387
UD
2053 echo $ac_n "(cached) $ac_c" 1>&6
2054else
2055 # Most GNU programs take a -v and spit out some text including
2056# the word 'GNU'. Some try to read stdin, so give them /dev/null.
2057if $LD -o conftest -v </dev/null 2>&1 | grep GNU > /dev/null 2>&1; then
2058 libc_cv_prog_ld_gnu=yes
2059else
2060 libc_cv_prog_ld_gnu=no
2061fi
2062rm -fr contest*
2063fi
2064
2065echo "$ac_t""$libc_cv_prog_ld_gnu" 1>&6
2066gnu_ld=$libc_cv_prog_ld_gnu
2067
4bca4c17
UD
2068# Extract the first word of "${ac_tool_prefix}mig", so it can be a program name with args.
2069set dummy ${ac_tool_prefix}mig; ac_word=$2
2070echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2b904739 2071echo "configure:2072: checking for $ac_word" >&5
a808d541 2072if eval "test \"`echo '$''{'ac_cv_prog_MIG'+set}'`\" = set"; then
4bca4c17
UD
2073 echo $ac_n "(cached) $ac_c" 1>&6
2074else
2075 if test -n "$MIG"; then
2076 ac_cv_prog_MIG="$MIG" # Let the user override the test.
2077else
5c2a0669
UD
2078 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2079 ac_dummy="$PATH"
2080 for ac_dir in $ac_dummy; do
4bca4c17
UD
2081 test -z "$ac_dir" && ac_dir=.
2082 if test -f $ac_dir/$ac_word; then
2083 ac_cv_prog_MIG="${ac_tool_prefix}mig"
2084 break
2085 fi
2086 done
2087 IFS="$ac_save_ifs"
2088 test -z "$ac_cv_prog_MIG" && ac_cv_prog_MIG="mig"
2089fi
2090fi
2091MIG="$ac_cv_prog_MIG"
2092if test -n "$MIG"; then
2093 echo "$ac_t""$MIG" 1>&6
2094else
2095 echo "$ac_t""no" 1>&6
2096fi
2097
2098
2099
cd6ede75 2100
ea9f119b 2101# Accept binutils 2.10.1 or newer (and also any ia64 2.9 version)
45ef592d
UD
2102# XXX Commented out because it filters out too many good versions.
2103# XXX --drepper
2104# AC_CHECK_PROG_VER(AS, $AS, --version,
2105# [GNU assembler.* \([0-9]*\.[0-9.]*\(-ia64-[0-9]*\)*\)],
2106# [2.10.[1-9]* | 2.1[1-9]* | 2.9-ia64-*], AS=: critic_missing=t)
ea9f119b 2107
ea9f119b 2108test -n "$aux_missing" && echo "configure: warning:
aefdff34 2109*** These auxiliary programs are missing or too old:$aux_missing
ea9f119b
AJ
2110*** some features will be disabled.
2111*** Check the INSTALL file for required versions." 1>&2
2112
2113# glibcbug.in wants to know the compiler version.
2114CCVERSION=`$CC -v 2>&1 | sed -n 's/gcc version //p'`
2115
2116
3c720987
UD
2117# if using special system headers, find out the compiler's sekrit
2118# header directory and add that to the list. NOTE: Only does the right
2119# thing on a system that doesn't need fixincludes. (Not presently a problem.)
2120if test -n "$sysheaders"; then
2121 ccheaders=`$CC -print-file-name=include`
2122 SYSINCLUDES="-nostdinc -isystem $ccheaders -isystem $sysheaders"
2123fi
2124
2125
f89ac85c
UD
2126# check if ranlib is necessary
2127echo $ac_n "checking whether ranlib is necessary""... $ac_c" 1>&6
2b904739 2128echo "configure:2129: checking whether ranlib is necessary" >&5
a808d541 2129if eval "test \"`echo '$''{'libc_cv_ranlib_necessary'+set}'`\" = set"; then
f38931a9
UD
2130 echo $ac_n "(cached) $ac_c" 1>&6
2131else
f89ac85c
UD
2132 cat > conftest.c <<EOF
2133int a;
2134char b;
2135void c(void) {}
2136EOF
2137$CC $CFLAGS -c conftest.c
2138$AR cr conftest.a conftest.c
2139cp conftest.a conftest2.a
2140$RANLIB conftest.a
2141if cmp -s conftest.a conftest2.a; then
2142 libc_cv_ranlib_necessary=no
f38931a9 2143else
f89ac85c 2144 libc_cv_ranlib_necessary=yes
f38931a9 2145fi
f89ac85c 2146rm -rf conftest*
f38931a9
UD
2147fi
2148
f89ac85c
UD
2149echo "$ac_t""$libc_cv_ranlib_necessary" 1>&6
2150if test "$libc_cv_ranlib_necessary" = no; then
2151 RANLIB=:
2152fi
f38931a9 2153
3911660e
UD
2154# Test if LD_LIBRARY_PATH contains the notation for the current directory
2155# since this would lead to problems installing/building glibc.
2156# LD_LIBRARY_PATH contains the current directory if one of the following
2157# is true:
2158# - one of the terminals (":" and ";") is the first or last sign
2159# - two terminals occur directly after each other
2160# - the path contains an element with a dot in it
2161echo $ac_n "checking LD_LIBRARY_PATH variable""... $ac_c" 1>&6
2b904739 2162echo "configure:2163: checking LD_LIBRARY_PATH variable" >&5
3911660e
UD
2163case ${LD_LIBRARY_PATH} in
2164 [:\;]* | *[:\;] | *[:\;][:\;]* | *[:\;]. | .[:\;]*| . | *[:\;].[:\;]* )
b3a86ae1 2165 ld_library_path_setting="contains current directory"
3911660e
UD
2166 ;;
2167 *)
2168 ld_library_path_setting="ok"
2169 ;;
2170esac
2171echo "$ac_t""$ld_library_path_setting" 1>&6
2172if test "$ld_library_path_setting" != "ok"; then
63bda0c1
UD
2173{ echo "configure: error:
2174*** LD_LIBRARY_PATH shouldn't contain the current directory when
2175*** building glibc. Please change the environment variable
2176*** and run configure again." 1>&2; exit 1; }
3911660e
UD
2177fi
2178
74bd2300 2179echo $ac_n "checking whether GCC supports -static-libgcc""... $ac_c" 1>&6
2b904739 2180echo "configure:2181: checking whether GCC supports -static-libgcc" >&5
74bd2300
UD
2181if eval "test \"`echo '$''{'libc_cv_gcc_static_libgcc'+set}'`\" = set"; then
2182 echo $ac_n "(cached) $ac_c" 1>&6
2183else
2184 if $CC -v -static-libgcc 2>&1 | grep -q 'unrecognized option.*static-libgcc'; then
2185 libc_cv_gcc_static_libgcc=
2186else
2187 libc_cv_gcc_static_libgcc=-static-libgcc
2188fi
2189fi
2190
2191echo "$ac_t""$libc_cv_gcc_static_libgcc" 1>&6
2192
2193
cd6ede75
UD
2194# Extract the first word of "bash", so it can be a program name with args.
2195set dummy bash; ac_word=$2
2196echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2b904739 2197echo "configure:2198: checking for $ac_word" >&5
a808d541 2198if eval "test \"`echo '$''{'ac_cv_path_BASH'+set}'`\" = set"; then
cd6ede75
UD
2199 echo $ac_n "(cached) $ac_c" 1>&6
2200else
2201 case "$BASH" in
2202 /*)
2203 ac_cv_path_BASH="$BASH" # Let the user override the test with a path.
2204 ;;
5c2a0669
UD
2205 ?:/*)
2206 ac_cv_path_BASH="$BASH" # Let the user override the test with a dos path.
2207 ;;
cd6ede75 2208 *)
5c2a0669
UD
2209 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2210 ac_dummy="$PATH"
2211 for ac_dir in $ac_dummy; do
cd6ede75
UD
2212 test -z "$ac_dir" && ac_dir=.
2213 if test -f $ac_dir/$ac_word; then
2214 ac_cv_path_BASH="$ac_dir/$ac_word"
2215 break
2216 fi
2217 done
2218 IFS="$ac_save_ifs"
2219 test -z "$ac_cv_path_BASH" && ac_cv_path_BASH="no"
2220 ;;
2221esac
2222fi
2223BASH="$ac_cv_path_BASH"
2224if test -n "$BASH"; then
2225 echo "$ac_t""$BASH" 1>&6
2226else
2227 echo "$ac_t""no" 1>&6
2228fi
2229
2230if test "$BASH" != no &&
f43ce637 2231 $BASH -c 'test "$BASH_VERSINFO" \
6973fc01 2232 && test "$BASH_VERSINFO" -ge 2 >&/dev/null'; then
cd6ede75
UD
2233 libc_cv_have_bash2=yes
2234else
2235 libc_cv_have_bash2=no
2236fi
2237
2238
2239if test "$BASH" = no; then
2240 # Extract the first word of "ksh", so it can be a program name with args.
2241set dummy ksh; ac_word=$2
2242echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2b904739 2243echo "configure:2244: checking for $ac_word" >&5
a808d541 2244if eval "test \"`echo '$''{'ac_cv_path_KSH'+set}'`\" = set"; then
cd6ede75
UD
2245 echo $ac_n "(cached) $ac_c" 1>&6
2246else
2247 case "$KSH" in
2248 /*)
2249 ac_cv_path_KSH="$KSH" # Let the user override the test with a path.
2250 ;;
5c2a0669
UD
2251 ?:/*)
2252 ac_cv_path_KSH="$KSH" # Let the user override the test with a dos path.
2253 ;;
cd6ede75 2254 *)
5c2a0669
UD
2255 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2256 ac_dummy="$PATH"
2257 for ac_dir in $ac_dummy; do
cd6ede75
UD
2258 test -z "$ac_dir" && ac_dir=.
2259 if test -f $ac_dir/$ac_word; then
2260 ac_cv_path_KSH="$ac_dir/$ac_word"
2261 break
2262 fi
2263 done
2264 IFS="$ac_save_ifs"
2265 test -z "$ac_cv_path_KSH" && ac_cv_path_KSH="no"
2266 ;;
2267esac
2268fi
2269KSH="$ac_cv_path_KSH"
2270if test -n "$KSH"; then
2271 echo "$ac_t""$KSH" 1>&6
2272else
2273 echo "$ac_t""no" 1>&6
2274fi
2275
2276 if test "$KSH" = no; then
2277 libc_cv_have_ksh=no
2278 else
2279 libc_cv_have_ksh=yes
2280 fi
2281else
2282 KSH="$BASH"
2283
2284 libc_cv_have_ksh=yes
2285fi
2286
2287
2b904739 2288for ac_prog in mawk gawk nawk awk
a2b08ee5
UD
2289do
2290# Extract the first word of "$ac_prog", so it can be a program name with args.
2291set dummy $ac_prog; ac_word=$2
2292echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2b904739 2293echo "configure:2294: checking for $ac_word" >&5
a808d541 2294if eval "test \"`echo '$''{'ac_cv_prog_AWK'+set}'`\" = set"; then
5aa8ff62
UD
2295 echo $ac_n "(cached) $ac_c" 1>&6
2296else
2297 if test -n "$AWK"; then
2298 ac_cv_prog_AWK="$AWK" # Let the user override the test.
2299else
5c2a0669
UD
2300 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2301 ac_dummy="$PATH"
2302 for ac_dir in $ac_dummy; do
5aa8ff62
UD
2303 test -z "$ac_dir" && ac_dir=.
2304 if test -f $ac_dir/$ac_word; then
2305 ac_cv_prog_AWK="$ac_prog"
2306 break
2307 fi
2308 done
2309 IFS="$ac_save_ifs"
2310fi
2311fi
2312AWK="$ac_cv_prog_AWK"
2313if test -n "$AWK"; then
2314 echo "$ac_t""$AWK" 1>&6
2315else
2316 echo "$ac_t""no" 1>&6
2317fi
2318
2319test -n "$AWK" && break
2320done
2321
c0016081
UD
2322# Extract the first word of "perl", so it can be a program name with args.
2323set dummy perl; ac_word=$2
5aa8ff62 2324echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2b904739 2325echo "configure:2326: checking for $ac_word" >&5
a808d541 2326if eval "test \"`echo '$''{'ac_cv_path_PERL'+set}'`\" = set"; then
a2b08ee5
UD
2327 echo $ac_n "(cached) $ac_c" 1>&6
2328else
2329 case "$PERL" in
2330 /*)
2331 ac_cv_path_PERL="$PERL" # Let the user override the test with a path.
2332 ;;
5c2a0669
UD
2333 ?:/*)
2334 ac_cv_path_PERL="$PERL" # Let the user override the test with a dos path.
2335 ;;
a2b08ee5 2336 *)
5c2a0669
UD
2337 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2338 ac_dummy="$PATH"
2339 for ac_dir in $ac_dummy; do
a2b08ee5
UD
2340 test -z "$ac_dir" && ac_dir=.
2341 if test -f $ac_dir/$ac_word; then
2342 ac_cv_path_PERL="$ac_dir/$ac_word"
2343 break
2344 fi
2345 done
2346 IFS="$ac_save_ifs"
c0016081 2347 test -z "$ac_cv_path_PERL" && ac_cv_path_PERL="no"
a2b08ee5
UD
2348 ;;
2349esac
2350fi
2351PERL="$ac_cv_path_PERL"
2352if test -n "$PERL"; then
2353 echo "$ac_t""$PERL" 1>&6
2354else
2355 echo "$ac_t""no" 1>&6
2356fi
2357
2fd5d029
RM
2358if test "$PERL" != no &&
2359 (eval `$PERL -V:apiversion`; test `expr "$apiversion" \< 5` -ne 0); then
2360 PERL=no
fc304e02 2361fi
c0016081
UD
2362# Extract the first word of "install-info", so it can be a program name with args.
2363set dummy install-info; ac_word=$2
2364echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2b904739 2365echo "configure:2366: checking for $ac_word" >&5
a808d541 2366if eval "test \"`echo '$''{'ac_cv_path_INSTALL_INFO'+set}'`\" = set"; then
c0016081
UD
2367 echo $ac_n "(cached) $ac_c" 1>&6
2368else
2369 case "$INSTALL_INFO" in
2370 /*)
2371 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
2372 ;;
5c2a0669
UD
2373 ?:/*)
2374 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a dos path.
2375 ;;
c0016081 2376 *)
5c2a0669 2377 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
9f2a9248 2378 ac_dummy="$PATH:/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin:/bin:/sbin"
5c2a0669 2379 for ac_dir in $ac_dummy; do
c0016081
UD
2380 test -z "$ac_dir" && ac_dir=.
2381 if test -f $ac_dir/$ac_word; then
2382 ac_cv_path_INSTALL_INFO="$ac_dir/$ac_word"
2383 break
2384 fi
2385 done
2386 IFS="$ac_save_ifs"
2387 test -z "$ac_cv_path_INSTALL_INFO" && ac_cv_path_INSTALL_INFO="no"
2388 ;;
2389esac
2390fi
2391INSTALL_INFO="$ac_cv_path_INSTALL_INFO"
2392if test -n "$INSTALL_INFO"; then
2393 echo "$ac_t""$INSTALL_INFO" 1>&6
2394else
2395 echo "$ac_t""no" 1>&6
2396fi
2397
c0016081
UD
2398if test "$INSTALL_INFO" != "no"; then
2399echo $ac_n "checking for old Debian install-info""... $ac_c" 1>&6
2b904739 2400echo "configure:2401: checking for old Debian install-info" >&5
a808d541 2401if eval "test \"`echo '$''{'libc_cv_old_debian_install_info'+set}'`\" = set"; then
c0016081
UD
2402 echo $ac_n "(cached) $ac_c" 1>&6
2403else
2404 mkdir conftest.d
2405 # There is a hard ^_ on the next line. I am open to better ideas.
2406 (echo '\1f'
2407 echo 'File: dir Node: Top This is the top of the INFO tree'
2408 echo '* Menu:') >conftest.d/dir
2409 (echo 'INFO-DIR-SECTION i-d-s works'
2410 echo 'START-INFO-DIR-ENTRY'
2411 echo '* Prog: (prog). Program.'
2412 echo 'END-INFO-DIR-ENTRY') >conftest.d/prog.info
2413 if $INSTALL_INFO --info-dir=conftest.d conftest.d/prog.info >&5 2>&1
d8cceb4f 2414 then
c0016081
UD
2415 if grep -s 'i-d-s works' conftest.d/dir >/dev/null
2416 then libc_cv_old_debian_install_info=no
2417 else libc_cv_old_debian_install_info=yes
2418 fi
2419 else libc_cv_old_debian_install_info=no testfailed=t
2420 fi
2421 rm -fr conftest.d
2422fi
2423
2424echo "$ac_t""$libc_cv_old_debian_install_info" 1>&6
2425if test -n "$testfailed"
2426then echo "configure: warning: install-info errored out, check config.log" 1>&2
2427fi
2428OLD_DEBIAN_INSTALL_INFO=$libc_cv_old_debian_install_info
2429fi
a2b08ee5
UD
2430
2431
ae113383
UD
2432# Extract the first word of "bison", so it can be a program name with args.
2433set dummy bison; ac_word=$2
2434echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2b904739 2435echo "configure:2436: checking for $ac_word" >&5
ae113383
UD
2436if eval "test \"`echo '$''{'ac_cv_path_BISON'+set}'`\" = set"; then
2437 echo $ac_n "(cached) $ac_c" 1>&6
2438else
2439 case "$BISON" in
2440 /*)
2441 ac_cv_path_BISON="$BISON" # Let the user override the test with a path.
2442 ;;
2443 ?:/*)
2444 ac_cv_path_BISON="$BISON" # Let the user override the test with a dos path.
2445 ;;
2446 *)
2447 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2448 ac_dummy="$PATH:/usr/local/bin:/usr/bin:/bin"
2449 for ac_dir in $ac_dummy; do
2450 test -z "$ac_dir" && ac_dir=.
2451 if test -f $ac_dir/$ac_word; then
2452 ac_cv_path_BISON="$ac_dir/$ac_word"
2453 break
2454 fi
2455 done
2456 IFS="$ac_save_ifs"
2457 test -z "$ac_cv_path_BISON" && ac_cv_path_BISON="no"
2458 ;;
2459esac
2460fi
2461BISON="$ac_cv_path_BISON"
2462if test -n "$BISON"; then
2463 echo "$ac_t""$BISON" 1>&6
2464else
2465 echo "$ac_t""no" 1>&6
2466fi
2467
2468
cd6ede75 2469echo $ac_n "checking for signed size_t type""... $ac_c" 1>&6
2b904739 2470echo "configure:2471: checking for signed size_t type" >&5
a808d541 2471if eval "test \"`echo '$''{'libc_cv_signed_size_t'+set}'`\" = set"; then
cd6ede75
UD
2472 echo $ac_n "(cached) $ac_c" 1>&6
2473else
2474 echo '#include <stddef.h>
2475FOOBAR __SIZE_TYPE__ FOOBAR' > conftest.c
2476if eval "$ac_cpp conftest.c 2>/dev/null" \
2477| grep '^FOOBAR.*unsigned.*FOOBAR$' >/dev/null; then
2478 libc_cv_signed_size_t=no
2479else
2480 libc_cv_signed_size_t=yes
2481fi
2482rm -f conftest*
2483fi
2484
2485echo "$ac_t""$libc_cv_signed_size_t" 1>&6
2486if test $libc_cv_signed_size_t = yes; then
2487 cat >> confdefs.h <<\EOF
2488#undef __SIZE_TYPE__
2489#define __SIZE_TYPE__ unsigned
2490EOF
2491fi
2492
2493echo $ac_n "checking for libc-friendly stddef.h""... $ac_c" 1>&6
2b904739 2494echo "configure:2495: checking for libc-friendly stddef.h" >&5
a808d541 2495if eval "test \"`echo '$''{'libc_cv_friendly_stddef'+set}'`\" = set"; then
cd6ede75
UD
2496 echo $ac_n "(cached) $ac_c" 1>&6
2497else
2498 cat > conftest.$ac_ext <<EOF
2b904739 2499#line 2500 "configure"
cd6ede75
UD
2500#include "confdefs.h"
2501#define __need_size_t
2502#define __need_wchar_t
2503#include <stddef.h>
2504#define __need_NULL
2505#include <stddef.h>
2506int main() {
2507size_t size; wchar_t wchar;
2508#ifdef offsetof
2509#error stddef.h ignored __need_*
2510#endif
2511if (&size == NULL || &wchar == NULL) abort ();
2512; return 0; }
2513EOF
2b904739 2514if { (eval echo configure:2515: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
cd6ede75
UD
2515 rm -rf conftest*
2516 libc_cv_friendly_stddef=yes
2517else
2518 echo "configure: failed program was:" >&5
2519 cat conftest.$ac_ext >&5
2520 rm -rf conftest*
2521 libc_cv_friendly_stddef=no
2522fi
2523rm -f conftest*
2524fi
2525
2526echo "$ac_t""$libc_cv_friendly_stddef" 1>&6
2527if test $libc_cv_friendly_stddef = yes; then
2528 config_vars="$config_vars
2529override stddef.h = # The installed <stddef.h> seems to be libc-friendly."
2530fi
2531
2532echo $ac_n "checking whether we need to use -P to assemble .S files""... $ac_c" 1>&6
2b904739 2533echo "configure:2534: checking whether we need to use -P to assemble .S files" >&5
a808d541 2534if eval "test \"`echo '$''{'libc_cv_need_minus_P'+set}'`\" = set"; then
cd6ede75
UD
2535 echo $ac_n "(cached) $ac_c" 1>&6
2536else
2537 cat > conftest.S <<EOF
2538#include "confdefs.h"
2539/* Nothing whatsoever. */
2540EOF
2541if ${CC-cc} $CFLAGS -c conftest.S 2>/dev/null; then
2542 libc_cv_need_minus_P=no
2543else
2544 libc_cv_need_minus_P=yes
2545fi
2546rm -f conftest*
2547fi
2548
2549echo "$ac_t""$libc_cv_need_minus_P" 1>&6
2550if test $libc_cv_need_minus_P = yes; then
2551 config_vars="$config_vars
2552asm-CPPFLAGS = -P # The assembler can't grok cpp's # line directives."
2553fi
2554
2293395f 2555echo $ac_n "checking whether .text pseudo-op must be used""... $ac_c" 1>&6
2b904739 2556echo "configure:2557: checking whether .text pseudo-op must be used" >&5
a808d541 2557if eval "test \"`echo '$''{'libc_cv_dot_text'+set}'`\" = set"; then
2293395f
UD
2558 echo $ac_n "(cached) $ac_c" 1>&6
2559else
2560 cat > conftest.s <<EOF
2561.text
2562EOF
2563libc_cv_dot_text=
2564if ${CC-cc} $CFLAGS -c conftest.s 2>/dev/null; then
2565 libc_cv_dot_text=.text
2566fi
2567rm -f conftest*
2568fi
2569
2570if test -z "$libc_cv_dot_text"; then
2571 echo "$ac_t""no" 1>&6
2572else
2573 echo "$ac_t""yes" 1>&6
2574fi
2575
cd6ede75 2576echo $ac_n "checking for assembler global-symbol directive""... $ac_c" 1>&6
2b904739 2577echo "configure:2578: checking for assembler global-symbol directive" >&5
a808d541 2578if eval "test \"`echo '$''{'libc_cv_asm_global_directive'+set}'`\" = set"; then
cd6ede75
UD
2579 echo $ac_n "(cached) $ac_c" 1>&6
2580else
2581 libc_cv_asm_global_directive=UNKNOWN
908c3d5b 2582for ac_globl in .globl .global .EXPORT; do
cd6ede75 2583 cat > conftest.s <<EOF
2293395f 2584 ${libc_cv_dot_text}
908c3d5b 2585 ${ac_globl} foo
cd6ede75
UD
2586foo:
2587EOF
2588 if ${CC-cc} $CFLAGS -c conftest.s 2>/dev/null; then
2589 libc_cv_asm_global_directive=${ac_globl}
2590 fi
2591 rm -f conftest*
2592 test $libc_cv_asm_global_directive != UNKNOWN && break
2593done
2594fi
2595
2596echo "$ac_t""$libc_cv_asm_global_directive" 1>&6
2597if test $libc_cv_asm_global_directive = UNKNOWN; then
2598 { echo "configure: error: cannot determine asm global directive" 1>&2; exit 1; }
2599else
2600 cat >> confdefs.h <<EOF
2601#define ASM_GLOBAL_DIRECTIVE ${libc_cv_asm_global_directive}
2602EOF
2603
2604fi
2605
2606echo $ac_n "checking for .set assembler directive""... $ac_c" 1>&6
2b904739 2607echo "configure:2608: checking for .set assembler directive" >&5
a808d541 2608if eval "test \"`echo '$''{'libc_cv_asm_set_directive'+set}'`\" = set"; then
cd6ede75
UD
2609 echo $ac_n "(cached) $ac_c" 1>&6
2610else
2611 cat > conftest.s <<EOF
2293395f 2612${libc_cv_dot_text}
cd6ede75
UD
2613foo:
2614.set glibc_conftest_frobozz,foo
2615$libc_cv_asm_global_directive glibc_conftest_frobozz
2616EOF
2617# The alpha-dec-osf1 assembler gives only a warning for `.set'
2618# (but it doesn't work), so we must do a linking check to be sure.
2619cat > conftest1.c <<\EOF
2620extern int glibc_conftest_frobozz;
2621main () { printf ("%d\n", glibc_conftest_frobozz); }
2622EOF
2623if ${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS \
2624 -o conftest conftest.s conftest1.c 1>&5 2>&5; then
2625 libc_cv_asm_set_directive=yes
2626else
2627 libc_cv_asm_set_directive=no
2628fi
2629rm -f conftest*
2630fi
2631
2632echo "$ac_t""$libc_cv_asm_set_directive" 1>&6
2633if test $libc_cv_asm_set_directive = yes; then
2634 cat >> confdefs.h <<\EOF
2635#define HAVE_ASM_SET_DIRECTIVE 1
2636EOF
2637
2638fi
2639
2aa15430
UD
2640# The Aix ld uses global .symbol_names instead of symbol_names.
2641case "$os" in
2642aix4.3*)
2643 cat >> confdefs.h <<\EOF
2644#define HAVE_ASM_GLOBAL_DOT_NAME 1
2645EOF
2646
2647esac
2648
cd6ede75 2649echo $ac_n "checking for .symver assembler directive""... $ac_c" 1>&6
2b904739 2650echo "configure:2651: checking for .symver assembler directive" >&5
a808d541 2651if eval "test \"`echo '$''{'libc_cv_asm_symver_directive'+set}'`\" = set"; then
cd6ede75
UD
2652 echo $ac_n "(cached) $ac_c" 1>&6
2653else
2654 cat > conftest.s <<EOF
2293395f 2655${libc_cv_dot_text}
cd6ede75
UD
2656_sym:
2657.symver _sym,sym@VERS
2658EOF
2659if ${CC-cc} -c $CFLAGS $CPPFLAGS conftest.s 1>&5 2>&5; then
2660 libc_cv_asm_symver_directive=yes
2661else
2662 libc_cv_asm_symver_directive=no
2663fi
2664rm -f conftest*
2665fi
2666
2667echo "$ac_t""$libc_cv_asm_symver_directive" 1>&6
2668echo $ac_n "checking for ld --version-script""... $ac_c" 1>&6
2b904739 2669echo "configure:2670: checking for ld --version-script" >&5
a808d541 2670if eval "test \"`echo '$''{'libc_cv_ld_version_script_option'+set}'`\" = set"; then
cd6ede75
UD
2671 echo $ac_n "(cached) $ac_c" 1>&6
2672else
2673 if test $libc_cv_asm_symver_directive = yes; then
2674 cat > conftest.s <<EOF
2293395f 2675${libc_cv_dot_text}
cd6ede75
UD
2676_sym:
2677.symver _sym,sym@VERS
2678EOF
2679 cat > conftest.map <<EOF
f43ce637 2680VERS_1 {
cd6ede75
UD
2681 global: sym;
2682};
f43ce637
UD
2683
2684VERS_2 {
2685 global: sym;
2686} VERS_1;
cd6ede75
UD
2687EOF
2688 if ${CC-cc} -c $CFLAGS $CPPFLAGS conftest.s 1>&5 2>&5; then
2689 if { ac_try='${CC-cc} $CFLAGS -shared -o conftest.so conftest.o
2690 -nostartfiles -nostdlib
2691 -Wl,--version-script,conftest.map
2b904739 2692 1>&5'; { (eval echo configure:2693: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; };
cd6ede75
UD
2693 then
2694 libc_cv_ld_version_script_option=yes
2695 else
2696 libc_cv_ld_version_script_option=no
2697 fi
2698 else
2699 libc_cv_ld_version_script_option=no
2700 fi
2701else
2702 libc_cv_ld_version_script_option=no
2703fi
2704rm -f conftest*
2705fi
2706
2707echo "$ac_t""$libc_cv_ld_version_script_option" 1>&6
7499a22a
RM
2708if test $shared != no &&
2709 test $libc_cv_asm_symver_directive = yes &&
650425ce
UD
2710 test $libc_cv_ld_version_script_option = yes &&
2711 test $enable_versioning = yes; then
cd6ede75
UD
2712 VERSIONING=yes
2713 cat >> confdefs.h <<\EOF
2714#define DO_VERSIONING 1
2715EOF
2716
2717else
2718 VERSIONING=no
2719fi
2720
2721
22af13de 2722if test $elf = yes && test $shared != no && test $VERSIONING = no; then
f43ce637 2723 echo "\
f4017d20 2724*** WARNING: You should not compile GNU libc without versioning. Not using
f43ce637
UD
2725*** versioning will introduce incompatibilities so that old binaries
2726*** will not run anymore.
08a0d60a 2727*** For versioning you need recent binutils (binutils-2.8.1.0.23 or newer)."
f43ce637 2728fi
cd6ede75
UD
2729if test $elf = yes; then
2730 echo $ac_n "checking for .previous assembler directive""... $ac_c" 1>&6
2b904739 2731echo "configure:2732: checking for .previous assembler directive" >&5
a808d541 2732if eval "test \"`echo '$''{'libc_cv_asm_previous_directive'+set}'`\" = set"; then
cd6ede75
UD
2733 echo $ac_n "(cached) $ac_c" 1>&6
2734else
2735 cat > conftest.s <<EOF
2736.section foo_section
2737.previous
2738EOF
2b904739 2739 if { ac_try='${CC-cc} -c $CFLAGS conftest.s 1>&5'; { (eval echo configure:2740: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
cd6ede75
UD
2740 libc_cv_asm_previous_directive=yes
2741 else
2742 libc_cv_asm_previous_directive=no
2743 fi
2744 rm -f conftest*
2745fi
2746
2747echo "$ac_t""$libc_cv_asm_previous_directive" 1>&6
2748 if test $libc_cv_asm_previous_directive = yes; then
2749 cat >> confdefs.h <<\EOF
2750#define HAVE_ASM_PREVIOUS_DIRECTIVE 1
2751EOF
2752
2753 else
2754 echo $ac_n "checking for .popsection assembler directive""... $ac_c" 1>&6
2b904739 2755echo "configure:2756: checking for .popsection assembler directive" >&5
a808d541 2756if eval "test \"`echo '$''{'libc_cv_asm_popsection_directive'+set}'`\" = set"; then
cd6ede75
UD
2757 echo $ac_n "(cached) $ac_c" 1>&6
2758else
2759 cat > conftest.s <<EOF
2760.pushsection foo_section
2761.popsection
2762EOF
2b904739 2763 if { ac_try='${CC-cc} -c $CFLAGS conftest.s 1>&5'; { (eval echo configure:2764: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
cd6ede75
UD
2764 libc_cv_asm_popsection_directive=yes
2765 else
2766 libc_cv_asm_popsection_directive=no
2767 fi
2768 rm -f conftest*
2769fi
2770
2771echo "$ac_t""$libc_cv_asm_popsection_directive" 1>&6
2772 if test $libc_cv_asm_popsection_directive = yes; then
2773 cat >> confdefs.h <<\EOF
2774#define HAVE_ASM_POPSECTION_DIRECTIVE 1
2775EOF
2776
2777 fi
2778 fi
2d499f55 2779 echo $ac_n "checking for .protected and .hidden assembler directive""... $ac_c" 1>&6
2b904739 2780echo "configure:2781: checking for .protected and .hidden assembler directive" >&5
2d499f55
UD
2781if eval "test \"`echo '$''{'libc_cv_asm_protected_directive'+set}'`\" = set"; then
2782 echo $ac_n "(cached) $ac_c" 1>&6
2783else
2784 cat > conftest.s <<EOF
2785.protected foo
2786foo:
2787.hidden bar
2788bar:
2789EOF
2b904739 2790 if { ac_try='${CC-cc} -c $CFLAGS conftest.s 1>&5'; { (eval echo configure:2791: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
2d499f55
UD
2791 libc_cv_asm_protected_directive=yes
2792 else
2793 libc_cv_asm_protected_directive=no
2794 fi
2795 rm -f conftest*
2796fi
2797
2798echo "$ac_t""$libc_cv_asm_protected_directive" 1>&6
2799
5688da55
UD
2800 cat >> confdefs.h <<\EOF
2801#define HAVE_PROTECTED 1
2802EOF
2803
2f54c82d 2804
0d01dace
UD
2805 if test $libc_cv_asm_protected_directive = yes; then
2806 echo $ac_n "checking whether __attribute__((visibility())) is supported""... $ac_c" 1>&6
2b904739 2807echo "configure:2808: checking whether __attribute__((visibility())) is supported" >&5
0d01dace
UD
2808if eval "test \"`echo '$''{'libc_cv_visibility_attribute'+set}'`\" = set"; then
2809 echo $ac_n "(cached) $ac_c" 1>&6
2810else
2811 cat > conftest.c <<EOF
2812 int foo __attribute__ ((visibility ("hidden"))) = 1;
2813 int bar __attribute__ ((visibility ("protected"))) = 1;
2814EOF
2815 libc_cv_visibility_attribute=no
2816 if ${CC-cc} -Werror -S conftest.c -o conftest.s >/dev/null 2>&1; then
2817 if grep '\.hidden.*foo' conftest.s >/dev/null; then
2818 if grep '\.protected.*bar' conftest.s >/dev/null; then
2819 libc_cv_visibility_attribute=yes
2820 fi
2821 fi
2822 fi
2823 rm -f conftest.cs
2824
2825fi
2826
2827echo "$ac_t""$libc_cv_visibility_attribute" 1>&6
2828 if test $libc_cv_visibility_attribute = yes; then
2829 cat >> confdefs.h <<\EOF
2830#define HAVE_VISIBILITY_ATTRIBUTE 1
2831EOF
2832
2833 fi
2834 fi
2835
2836 if test $libc_cv_visibility_attribute = yes -a $gnu_ld = yes; then
2837 echo $ac_n "checking whether to put _rtld_local into .sdata section""... $ac_c" 1>&6
2b904739 2838echo "configure:2839: checking whether to put _rtld_local into .sdata section" >&5
0d01dace
UD
2839if eval "test \"`echo '$''{'libc_cv_have_sdata_section'+set}'`\" = set"; then
2840 echo $ac_n "(cached) $ac_c" 1>&6
2841else
2842 echo "int i;" > conftest.c
2843 libc_cv_have_sdata_section=no
2844 if ${CC-cc} -shared -Wl,--verbose conftest.c -o conftest.so 2>&1 \
2845 | grep '\.sdata' >/dev/null; then
2846 libc_cv_have_sdata_section=yes
2847 fi
2848 rm -f conftest.c conftest.so
2849
2850fi
2851
2852echo "$ac_t""$libc_cv_have_sdata_section" 1>&6
2853 if test $libc_cv_have_sdata_section = yes; then
2854 cat >> confdefs.h <<\EOF
2855#define HAVE_SDATA_SECTION 1
2856EOF
2857
2858 fi
2859 fi
2860
2c617417 2861 echo $ac_n "checking for .preinit_array/.init_array/.fini_array support""... $ac_c" 1>&6
2b904739 2862echo "configure:2863: checking for .preinit_array/.init_array/.fini_array support" >&5
2c617417
UD
2863if eval "test \"`echo '$''{'libc_cv_initfinit_array'+set}'`\" = set"; then
2864 echo $ac_n "(cached) $ac_c" 1>&6
2865else
2866 cat > conftest.c <<EOF
2867int _start (void) { return 0; }
2868int __start (void) { return 0; }
2869int foo (void) { return 1; }
2870int (*fp) (void) __attribute__ ((section (".init_array"))) = foo;
2871EOF
2872 if { ac_try='${CC-cc} -o conftest conftest.c
2b904739 2873 -static -nostartfiles -nostdlib 1>&5'; { (eval echo configure:2874: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }
2c617417
UD
2874 then
2875 if readelf -S conftest | fgrep INIT_ARRAY > /dev/null; then
2876 libc_cv_initfinit_array=yes
2877 else
2878 libc_cv_initfinit_array=no
2879 fi
2880 else
2881 libc_cv_initfinit_array=no
2882 fi
2883 rm -f conftest*
2884fi
2885
2886echo "$ac_t""$libc_cv_initfinit_array" 1>&6
2887
2888 if test $libc_cv_initfinit_array = yes; then
2889 cat >> confdefs.h <<\EOF
2890#define HAVE_INITFINI_ARRAY 1
2891EOF
2892
2893 fi
2894
2f54c82d 2895 echo $ac_n "checking for -z nodelete option""... $ac_c" 1>&6
2b904739 2896echo "configure:2897: checking for -z nodelete option" >&5
2f54c82d
UD
2897if eval "test \"`echo '$''{'libc_cv_z_nodelete'+set}'`\" = set"; then
2898 echo $ac_n "(cached) $ac_c" 1>&6
2899else
2900 cat > conftest.c <<EOF
2901int _start (void) { return 42; }
2902EOF
35cd3c97
AJ
2903 if { ac_try='${CC-cc} -shared -o conftest.so conftest.c
2904 -nostartfiles -nostdlib
2b904739 2905 -Wl,--enable-new-dtags,-z,nodelete 1>&5'; { (eval echo configure:2906: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }
2f54c82d
UD
2906 then
2907 libc_cv_z_nodelete=yes
2908 else
2909 libc_cv_z_nodelete=no
2910 fi
2911 rm -f conftest*
2912fi
2913
2914echo "$ac_t""$libc_cv_z_nodelete" 1>&6
2915
2916
2917 echo $ac_n "checking for -z nodlopen option""... $ac_c" 1>&6
2b904739 2918echo "configure:2919: checking for -z nodlopen option" >&5
2f54c82d
UD
2919if eval "test \"`echo '$''{'libc_cv_z_nodlopen'+set}'`\" = set"; then
2920 echo $ac_n "(cached) $ac_c" 1>&6
2921else
2922 cat > conftest.c <<EOF
2923int _start (void) { return 42; }
2924EOF
35cd3c97
AJ
2925 if { ac_try='${CC-cc} -shared -o conftest.so conftest.c
2926 -nostartfiles -nostdlib
2b904739 2927 -Wl,--enable-new-dtags,-z,nodlopen 1>&5'; { (eval echo configure:2928: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }
2f54c82d
UD
2928 then
2929 libc_cv_z_nodlopen=yes
2930 else
2931 libc_cv_z_nodlopen=no
2932 fi
2933 rm -f conftest*
2934fi
2935
2936echo "$ac_t""$libc_cv_z_nodlopen" 1>&6
2937
5d916713
UD
2938
2939 echo $ac_n "checking for -z initfirst option""... $ac_c" 1>&6
2b904739 2940echo "configure:2941: checking for -z initfirst option" >&5
5d916713
UD
2941if eval "test \"`echo '$''{'libc_cv_z_initfirst'+set}'`\" = set"; then
2942 echo $ac_n "(cached) $ac_c" 1>&6
2943else
2944 cat > conftest.c <<EOF
2945int _start (void) { return 42; }
2946EOF
35cd3c97
AJ
2947 if { ac_try='${CC-cc} -shared -o conftest.so conftest.c
2948 -nostartfiles -nostdlib
2b904739 2949 -Wl,--enable-new-dtags,-z,initfirst 1>&5'; { (eval echo configure:2950: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }
5d916713
UD
2950 then
2951 libc_cv_z_initfirst=yes
2952 else
2953 libc_cv_z_initfirst=no
2954 fi
2955 rm -f conftest*
2956fi
2957
2958echo "$ac_t""$libc_cv_z_initfirst" 1>&6
2959
639c3248
UD
2960
2961 echo $ac_n "checking for -Bgroup option""... $ac_c" 1>&6
2b904739 2962echo "configure:2963: checking for -Bgroup option" >&5
639c3248
UD
2963if eval "test \"`echo '$''{'libc_cv_Bgroup'+set}'`\" = set"; then
2964 echo $ac_n "(cached) $ac_c" 1>&6
2965else
2966 cat > conftest.c <<EOF
2967int _start (void) { return 42; }
2968EOF
2b904739 2969 if { ac_try='${CC-cc} -shared -o conftest.so conftest.c -Wl,-Bgroup -nostdlib 1>&5'; { (eval echo configure:2970: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }
639c3248
UD
2970 then
2971 libc_cv_Bgroup=yes
2972 else
2973 libc_cv_Bgroup=no
2974 fi
2975 rm -f conftest*
2976fi
2977
2978echo "$ac_t""$libc_cv_Bgroup" 1>&6
2979
a711b01d
UD
2980
2981 echo $ac_n "checking for -z combreloc""... $ac_c" 1>&6
2b904739 2982echo "configure:2983: checking for -z combreloc" >&5
a711b01d
UD
2983if eval "test \"`echo '$''{'libc_cv_z_combreloc'+set}'`\" = set"; then
2984 echo $ac_n "(cached) $ac_c" 1>&6
2985else
2986 cat > conftest.c <<EOF
d555194c
UD
2987extern int bar (int);
2988extern int mumble;
2989int foo (void) { return bar (mumble); }
a711b01d 2990EOF
35cd3c97
AJ
2991 if { ac_try='${CC-cc} -shared -o conftest.so conftest.c
2992 -nostdlib -nostartfiles
2b904739 2993 -Wl,-z,combreloc 1>&5'; { (eval echo configure:2994: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }
a711b01d 2994 then
fdde8349
UD
2995 if readelf -S conftest.so | grep '\.rel\(a\|\)\.dyn' > /dev/null; then
2996 libc_cv_z_combreloc=yes
2997 else
2998 libc_cv_z_combreloc=no
a711b01d 2999 fi
fdde8349
UD
3000 else
3001 libc_cv_z_combreloc=no
a711b01d
UD
3002 fi
3003 rm -f conftest*
3004fi
3005
3006echo "$ac_t""$libc_cv_z_combreloc" 1>&6
fdde8349
UD
3007 if test "$libc_cv_z_combreloc" = yes; then
3008 cat >> confdefs.h <<\EOF
3009#define HAVE_Z_COMBRELOC 1
3010EOF
3011
3012 fi
cd6ede75
UD
3013fi
3014
f13df7c7 3015
cd6ede75
UD
3016if test $elf != yes; then
3017 echo $ac_n "checking for .init and .fini sections""... $ac_c" 1>&6
2b904739 3018echo "configure:3019: checking for .init and .fini sections" >&5
a808d541 3019if eval "test \"`echo '$''{'libc_cv_have_initfini'+set}'`\" = set"; then
cd6ede75
UD
3020 echo $ac_n "(cached) $ac_c" 1>&6
3021else
3022 cat > conftest.$ac_ext <<EOF
2b904739 3023#line 3024 "configure"
cd6ede75
UD
3024#include "confdefs.h"
3025
3026int main() {
3027asm (".section .init");
3028 asm (".section .fini");
2293395f 3029 asm ("${libc_cv_dot_text}");
cd6ede75
UD
3030; return 0; }
3031EOF
2b904739 3032if { (eval echo configure:3033: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
cd6ede75
UD
3033 rm -rf conftest*
3034 libc_cv_have_initfini=yes
3035else
3036 echo "configure: failed program was:" >&5
3037 cat conftest.$ac_ext >&5
3038 rm -rf conftest*
3039 libc_cv_have_initfini=no
3040fi
3041rm -f conftest*
3042fi
3043
3044echo "$ac_t""$libc_cv_have_initfini" 1>&6
3045 if test $libc_cv_have_initfini = yes; then
3046 cat >> confdefs.h <<\EOF
3047#define HAVE_INITFINI 1
3048EOF
3049
3050 fi
3051fi
3052
e26dd47f
UD
3053if test $elf = yes -a $gnu_ld = yes; then
3054 echo $ac_n "checking whether cc puts quotes around section names""... $ac_c" 1>&6
2b904739 3055echo "configure:3056: checking whether cc puts quotes around section names" >&5
e26dd47f
UD
3056if eval "test \"`echo '$''{'libc_cv_have_section_quotes'+set}'`\" = set"; then
3057 echo $ac_n "(cached) $ac_c" 1>&6
3058else
3059 cat > conftest.c <<EOF
3060 static const int foo
3061 __attribute__ ((section ("bar"))) = 1;
3062EOF
3063 if ${CC-cc} -S conftest.c -o conftest.s; then
3064 if grep '\.section.*"bar"' conftest.s >/dev/null; then
3065 libc_cv_have_section_quotes=yes
3066 else
3067 libc_cv_have_section_quotes=no
3068 fi
3069 else
3070 libc_cv_have_section_quotes=unknown
3071 fi
3072 rm -f conftest.cs
3073
3074fi
3075
3076echo "$ac_t""$libc_cv_have_section_quotes" 1>&6
3077 if test $libc_cv_have_section_quotes = yes; then
3078 cat >> confdefs.h <<\EOF
3079#define HAVE_SECTION_QUOTES 1
3080EOF
3081
3082 fi
3083fi
3084
9a0a462c
UD
3085
3086
cd6ede75
UD
3087if test $elf = yes; then
3088 libc_cv_asm_underscores=no
3089else
9a0a462c
UD
3090 if test $ac_cv_prog_cc_works = yes; then
3091 echo $ac_n "checking for _ prefix on C symbol names""... $ac_c" 1>&6
2b904739 3092echo "configure:3093: checking for _ prefix on C symbol names" >&5
a808d541 3093if eval "test \"`echo '$''{'libc_cv_asm_underscores'+set}'`\" = set"; then
cd6ede75
UD
3094 echo $ac_n "(cached) $ac_c" 1>&6
3095else
3096 cat > conftest.$ac_ext <<EOF
2b904739 3097#line 3098 "configure"
cd6ede75
UD
3098#include "confdefs.h"
3099asm ("_glibc_foobar:");
3100int main() {
3101glibc_foobar ();
3102; return 0; }
3103EOF
2b904739 3104if { (eval echo configure:3105: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
cd6ede75
UD
3105 rm -rf conftest*
3106 libc_cv_asm_underscores=yes
3107else
3108 echo "configure: failed program was:" >&5
3109 cat conftest.$ac_ext >&5
3110 rm -rf conftest*
3111 libc_cv_asm_underscores=no
3112fi
3113rm -f conftest*
3114fi
3115
3116echo "$ac_t""$libc_cv_asm_underscores" 1>&6
9a0a462c
UD
3117 else
3118 echo $ac_n "checking for _ prefix on C symbol names""... $ac_c" 1>&6
2b904739 3119echo "configure:3120: checking for _ prefix on C symbol names" >&5
a808d541 3120if eval "test \"`echo '$''{'libc_cv_asm_underscores'+set}'`\" = set"; then
9a0a462c
UD
3121 echo $ac_n "(cached) $ac_c" 1>&6
3122else
3123 cat > conftest.$ac_ext <<EOF
2b904739 3124#line 3125 "configure"
9a0a462c
UD
3125#include "confdefs.h"
3126void underscore_test(void) {
3127return; }
3128EOF
2b904739 3129if { (eval echo configure:3130: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
9a0a462c
UD
3130 if grep _underscore_test conftest* >/dev/null; then
3131 rm -f conftest*
3132 libc_cv_asm_underscores=yes
3133 else
3134 rm -f conftest*
3135 libc_cv_asm_underscores=no
3136 fi
3137else
3138 echo "configure: failed program was:" >&5
3139 cat conftest.$ac_ext >&5
3140 rm -f conftest*
3141 libc_cv_asm_underscores=no
3142fi
3143rm -f conftest*
3144fi
3145
3146echo "$ac_t""$libc_cv_asm_underscores" 1>&6
3147 fi
cd6ede75
UD
3148fi
3149if test $libc_cv_asm_underscores = no; then
3150 cat >> confdefs.h <<\EOF
3151#define NO_UNDERSCORES 1
3152EOF
3153
3154fi
3155
3156if test $elf = yes; then
3157 libc_cv_weak_symbols=yes
9a97d1f7
UD
3158fi
3159
3160echo $ac_n "checking for assembler .weak directive""... $ac_c" 1>&6
2b904739 3161echo "configure:3162: checking for assembler .weak directive" >&5
a808d541 3162if eval "test \"`echo '$''{'libc_cv_asm_weak_directive'+set}'`\" = set"; then
cd6ede75
UD
3163 echo $ac_n "(cached) $ac_c" 1>&6
3164else
3165 cat > conftest.s <<EOF
2293395f 3166${libc_cv_dot_text}
cd6ede75
UD
3167${libc_cv_asm_global_directive} foo
3168foo:
3169.weak foo
3170.weak bar; bar = foo
3171EOF
9a97d1f7
UD
3172if ${CC-cc} $CFLAGS -c conftest.s 2>/dev/null; then
3173 libc_cv_asm_weak_directive=yes
3174else
3175 libc_cv_asm_weak_directive=no
3176fi
3177rm -f conftest*
cd6ede75
UD
3178fi
3179
3180echo "$ac_t""$libc_cv_asm_weak_directive" 1>&6
3181
3182if test $libc_cv_asm_weak_directive = no; then
3183 echo $ac_n "checking for assembler .weakext directive""... $ac_c" 1>&6
2b904739 3184echo "configure:3185: checking for assembler .weakext directive" >&5
a808d541 3185if eval "test \"`echo '$''{'libc_cv_asm_weakext_directive'+set}'`\" = set"; then
cd6ede75
UD
3186 echo $ac_n "(cached) $ac_c" 1>&6
3187else
3188 cat > conftest.s <<EOF
2293395f 3189${libc_cv_dot_text}
cd6ede75
UD
3190${libc_cv_asm_global_directive} foo
3191foo:
9a97d1f7
UD
3192.weakext bar foo
3193.weakext baz
3194${libc_cv_asm_global_directive} baz
3195baz:
cd6ede75
UD
3196EOF
3197 if ${CC-cc} $CFLAGS -c conftest.s 2>/dev/null; then
3198 libc_cv_asm_weakext_directive=yes
3199 else
3200 libc_cv_asm_weakext_directive=no
3201 fi
3202 rm -f conftest*
3203fi
3204
3205echo "$ac_t""$libc_cv_asm_weakext_directive" 1>&6
3206
9a97d1f7 3207fi # no .weak
cd6ede75
UD
3208
3209if test $libc_cv_asm_weak_directive = yes; then
3210 cat >> confdefs.h <<\EOF
3211#define HAVE_ASM_WEAK_DIRECTIVE 1
3212EOF
3213
3214elif test $libc_cv_asm_weakext_directive = yes; then
3215 cat >> confdefs.h <<\EOF
3216#define HAVE_ASM_WEAKEXT_DIRECTIVE 1
3217EOF
3218
3219fi
3220
b15cb495 3221case "${host_cpu}-${host_os}" in
eacde9d0
UD
3222 cris*)
3223 libc_cv_asm_line_sep='@'
3224 cat >> confdefs.h <<EOF
3225#define ASM_LINE_SEP $libc_cv_asm_line_sep
3226EOF
3227
3228 ;;
b15cb495
UD
3229 hppa*linux*)
3230 echo $ac_n "checking for assembler line separator""... $ac_c" 1>&6
2b904739 3231echo "configure:3232: checking for assembler line separator" >&5
b15cb495
UD
3232if eval "test \"`echo '$''{'libc_cv_asm_line_sep'+set}'`\" = set"; then
3233 echo $ac_n "(cached) $ac_c" 1>&6
3234else
3235 cat > conftest.s <<EOF
3236 nop ; is_old_puffin
3237EOF
2b904739 3238 if { ac_try='${CC-cc} -c $CFLAGS conftest.s 1>&5'; { (eval echo configure:3239: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
b15cb495
UD
3239 libc_cv_asm_line_sep='!'
3240 else
3241 if test -z "$enable_hacker_mode"; then
3242 echo "*** You need a newer assembler to compile glibc"
3243 rm -f conftest*
3244 exit 1
3245 fi
3246 libc_cv_asm_line_sep=';'
3247 fi
3248 rm -f conftest*
3249fi
3250
3251echo "$ac_t""$libc_cv_asm_line_sep" 1>&6
3252 cat >> confdefs.h <<EOF
3253#define ASM_LINE_SEP $libc_cv_asm_line_sep
3254EOF
3255
3256 ;;
3257esac
3258
cd6ede75 3259echo $ac_n "checking for ld --no-whole-archive""... $ac_c" 1>&6
2b904739 3260echo "configure:3261: checking for ld --no-whole-archive" >&5
a808d541 3261if eval "test \"`echo '$''{'libc_cv_ld_no_whole_archive'+set}'`\" = set"; then
cd6ede75
UD
3262 echo $ac_n "(cached) $ac_c" 1>&6
3263else
3264 cat > conftest.c <<\EOF
3265_start () {}
3266int __eh_pc;
3267__throw () {}
3268EOF
3269if { ac_try='${CC-cc} $CFLAGS
3270 -nostdlib -nostartfiles -Wl,--no-whole-archive
2b904739 3271 -o conftest conftest.c 1>&5'; { (eval echo configure:3272: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
cd6ede75
UD
3272 libc_cv_ld_no_whole_archive=yes
3273else
3274 libc_cv_ld_no_whole_archive=no
3275fi
3276rm -f conftest*
3277fi
3278
3279echo "$ac_t""$libc_cv_ld_no_whole_archive" 1>&6
b17277cf
UD
3280if test $libc_cv_ld_no_whole_archive = yes; then
3281 no_whole_archive=-Wl,--no-whole-archive
3282fi
cd6ede75 3283
dff14448 3284echo $ac_n "checking for gcc -fexceptions""... $ac_c" 1>&6
2b904739 3285echo "configure:3286: checking for gcc -fexceptions" >&5
a808d541 3286if eval "test \"`echo '$''{'libc_cv_gcc_exceptions'+set}'`\" = set"; then
cd6ede75
UD
3287 echo $ac_n "(cached) $ac_c" 1>&6
3288else
3289 cat > conftest.c <<\EOF
3290_start () {}
3291int __eh_pc;
3292__throw () {}
3293EOF
3294if { ac_try='${CC-cc} $CFLAGS
dff14448 3295 -nostdlib -nostartfiles -fexceptions
2b904739 3296 -o conftest conftest.c 1>&5'; { (eval echo configure:3297: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
dff14448 3297 libc_cv_gcc_exceptions=yes
cd6ede75 3298else
dff14448 3299 libc_cv_gcc_exceptions=no
cd6ede75
UD
3300fi
3301rm -f conftest*
3302fi
3303
dff14448
UD
3304echo "$ac_t""$libc_cv_gcc_exceptions" 1>&6
3305if test $libc_cv_gcc_exceptions = yes; then
3306 exceptions=-fexceptions
b17277cf 3307fi
cd6ede75 3308
d71b808a
UD
3309if test "$base_machine" = alpha ; then
3310echo $ac_n "checking for function ..ng prefix""... $ac_c" 1>&6
2b904739 3311echo "configure:3312: checking for function ..ng prefix" >&5
a808d541 3312if eval "test \"`echo '$''{'libc_cv_gcc_alpha_ng_prefix'+set}'`\" = set"; then
d71b808a
UD
3313 echo $ac_n "(cached) $ac_c" 1>&6
3314else
3315 cat > conftest.c <<\EOF
3316foo () { }
3317EOF
2b904739 3318if { ac_try='${CC-cc} -S conftest.c -o - | fgrep "\$foo..ng" > /dev/null'; { (eval echo configure:3319: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; };
d71b808a
UD
3319then
3320 libc_cv_gcc_alpha_ng_prefix=yes
3321else
3322 libc_cv_gcc_alpha_ng_prefix=no
3323fi
3324rm -f conftest*
3325fi
3326
3327echo "$ac_t""$libc_cv_gcc_alpha_ng_prefix" 1>&6
3328if test $libc_cv_gcc_alpha_ng_prefix = yes ; then
3329 cat >> confdefs.h <<\EOF
3330#define ASM_ALPHA_NG_SYMBOL_PREFIX "$"
3331EOF
3332
3333else
3334 cat >> confdefs.h <<\EOF
3335#define ASM_ALPHA_NG_SYMBOL_PREFIX ""
3336EOF
3337
3338fi
3339fi
3340
ebcd12d4
UD
3341if test "$host_cpu" = powerpc ; then
3342# Check for a bug present in at least versions 2.8.x of GCC
3343# and versions 1.0.x of EGCS.
3344echo $ac_n "checking whether clobbering cr0 causes problems""... $ac_c" 1>&6
2b904739 3345echo "configure:3346: checking whether clobbering cr0 causes problems" >&5
a808d541 3346if eval "test \"`echo '$''{'libc_cv_c_asmcr0_bug'+set}'`\" = set"; then
ebcd12d4
UD
3347 echo $ac_n "(cached) $ac_c" 1>&6
3348else
3349 cat > conftest.$ac_ext <<EOF
2b904739 3350#line 3351 "configure"
ebcd12d4
UD
3351#include "confdefs.h"
3352int tester(int x) { asm ("" : : : "cc"); return x & 123; }
3353int main() {
3354
3355; return 0; }
3356EOF
2b904739 3357if { (eval echo configure:3358: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
ebcd12d4
UD
3358 rm -rf conftest*
3359 libc_cv_c_asmcr0_bug='no'
3360else
3361 echo "configure: failed program was:" >&5
3362 cat conftest.$ac_ext >&5
3363 rm -rf conftest*
3364 libc_cv_c_asmcr0_bug='yes'
3365fi
3366rm -f conftest*
3367fi
3368
3369echo "$ac_t""$libc_cv_c_asmcr0_bug" 1>&6
3370if test "$libc_cv_c_asmcr0_bug" != 'no'; then
3371 cat >> confdefs.h <<\EOF
3372#define BROKEN_PPC_ASM_CR0 1
3373EOF
3374
3375fi
3376fi
3377
650425ce 3378echo $ac_n "checking for DWARF2 unwind info support""... $ac_c" 1>&6
2b904739 3379echo "configure:3380: checking for DWARF2 unwind info support" >&5
a808d541 3380if eval "test \"`echo '$''{'libc_cv_gcc_dwarf2_unwind_info'+set}'`\" = set"; then
650425ce
UD
3381 echo $ac_n "(cached) $ac_c" 1>&6
3382else
3383 cat > conftest.c <<EOF
2b904739
AJ
3384#line 3385 "configure"
3385static char *__EH_FRAME_BEGIN__;
650425ce
UD
3386_start ()
3387{
9756dfe1 3388#ifdef CHECK__register_frame
650425ce
UD
3389 __register_frame (__EH_FRAME_BEGIN__);
3390 __deregister_frame (__EH_FRAME_BEGIN__);
9756dfe1
UD
3391#endif
3392#ifdef CHECK__register_frame_info
3393 __register_frame_info (__EH_FRAME_BEGIN__);
3394 __deregister_frame_info (__EH_FRAME_BEGIN__);
3395#endif
650425ce
UD
3396}
3397int __eh_pc;
3398__throw () {}
3399/* FIXME: this is fragile. */
3400malloc () {}
3401strcmp () {}
3402strlen () {}
3403memcpy () {}
3404memset () {}
3405free () {}
3406abort () {}
dfd2257a 3407__bzero () {}
650425ce 3408EOF
9756dfe1 3409if { ac_try='${CC-cc} $CFLAGS -DCHECK__register_frame_info
650425ce 3410 -nostdlib -nostartfiles
2b904739 3411 -o conftest conftest.c -lgcc >&5'; { (eval echo configure:3412: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
9756dfe1 3412 libc_cv_gcc_dwarf2_unwind_info=static
650425ce
UD
3413else
3414 libc_cv_gcc_dwarf2_unwind_info=no
3415fi
2b904739
AJ
3416if { ac_try='${CC-cc} $CFLAGS -DCHECK__register_frame_info
3417 -nostdlib -nostartfiles
3418 -o conftest conftest.c -lgcc -lgcc_eh >&5'; { (eval echo configure:3419: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
3419 if ${CC-cc} $CFLAGS -DCHECK__register_frame_info -nostdlib -nostartfiles \
3420 -o conftest conftest.c -lgcc -lgcc_eh -v 2>&1 >/dev/null \
3421 | grep -q -- --eh-frame-hdr; then
3422 libc_cv_gcc_dwarf2_unwind_info=no_registry_needed
3423 else
3424 libc_cv_gcc_dwarf2_unwind_info=static
3425 fi
3426else
3427 libc_cv_gcc_dwarf2_unwind_info=no
3428fi
9756dfe1
UD
3429if test $libc_cv_gcc_dwarf2_unwind_info = no; then
3430 if { ac_try='${CC-cc} $CFLAGS -DCHECK__register_frame
3431 -nostdlib -nostartfiles
2b904739 3432 -o conftest conftest.c -lgcc >&5'; { (eval echo configure:3433: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
9756dfe1
UD
3433 libc_cv_gcc_dwarf2_unwind_info=yes
3434 else
3435 libc_cv_gcc_dwarf2_unwind_info=no
3436 fi
3437fi
650425ce
UD
3438rm -f conftest*
3439fi
3440
3441echo "$ac_t""$libc_cv_gcc_dwarf2_unwind_info" 1>&6
9756dfe1
UD
3442case $libc_cv_gcc_dwarf2_unwind_info in
3443yes)
650425ce
UD
3444 cat >> confdefs.h <<\EOF
3445#define HAVE_DWARF2_UNWIND_INFO 1
3446EOF
3447
9756dfe1
UD
3448 ;;
3449static)
3450 cat >> confdefs.h <<\EOF
3451#define HAVE_DWARF2_UNWIND_INFO 1
3452EOF
3453
3454 cat >> confdefs.h <<\EOF
3455#define HAVE_DWARF2_UNWIND_INFO_STATIC 1
3456EOF
3457
3458 ;;
3459esac
650425ce 3460
a8eab8b1 3461echo $ac_n "checking for __builtin_expect""... $ac_c" 1>&6
2b904739 3462echo "configure:3463: checking for __builtin_expect" >&5
a808d541 3463if eval "test \"`echo '$''{'libc_cv_gcc_builtin_expect'+set}'`\" = set"; then
a8eab8b1
UD
3464 echo $ac_n "(cached) $ac_c" 1>&6
3465else
3466 cat > conftest.c <<EOF
2b904739 3467#line 3468 "configure"
a8eab8b1
UD
3468int foo (int a)
3469{
3470 a = __builtin_expect (a, 10);
3471 return a == 10 ? 0 : 1;
3472}
3473EOF
3474if { ac_try='${CC-cc} $CFLAGS -nostdlib -nostartfiles
2b904739 3475 -o conftest conftest.c -lgcc >&5'; { (eval echo configure:3476: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
a8eab8b1
UD
3476 libc_cv_gcc_builtin_expect=yes
3477else
3478 libc_cv_gcc_builtin_expect=no
3479fi
3480rm -f conftest*
3481fi
3482
3483echo "$ac_t""$libc_cv_gcc_builtin_expect" 1>&6
3484if test "$libc_cv_gcc_builtin_expect" = yes; then
3485 cat >> confdefs.h <<\EOF
3486#define HAVE_BUILTIN_EXPECT 1
3487EOF
3488
3489fi
3490
d555194c 3491echo $ac_n "checking for __builtin_memset""... $ac_c" 1>&6
2b904739 3492echo "configure:3493: checking for __builtin_memset" >&5
d555194c
UD
3493if eval "test \"`echo '$''{'libc_cv_gcc_builtin_memset'+set}'`\" = set"; then
3494 echo $ac_n "(cached) $ac_c" 1>&6
3495else
3496 cat > conftest.c <<\EOF
3497void zero (void *x)
3498{
a52d1562 3499 __builtin_memset (x, 0, 1000);
d555194c
UD
3500}
3501EOF
2b904739 3502if { ac_try='${CC-cc} -O3 -S conftest.c -o - | fgrep "memset" > /dev/null'; { (eval echo configure:3503: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; };
d555194c
UD
3503then
3504 libc_cv_gcc_builtin_memset=no
3505else
3506 libc_cv_gcc_builtin_memset=yes
3507fi
3508rm -f conftest*
3509fi
3510
3511echo "$ac_t""$libc_cv_gcc_builtin_memset" 1>&6
3512if test "$libc_cv_gcc_builtin_memset" = yes ; then
3513 cat >> confdefs.h <<\EOF
3514#define HAVE_BUILTIN_MEMSET 1
3515EOF
3516
3517fi
3518
3d558f4e 3519echo $ac_n "checking for local label subtraction""... $ac_c" 1>&6
2b904739 3520echo "configure:3521: checking for local label subtraction" >&5
a808d541 3521if eval "test \"`echo '$''{'libc_cv_gcc_subtract_local_labels'+set}'`\" = set"; then
3d558f4e
UD
3522 echo $ac_n "(cached) $ac_c" 1>&6
3523else
3524 cat > conftest.c <<EOF
2b904739 3525#line 3526 "configure"
3d558f4e
UD
3526int foo (int a)
3527{
3528 static const int ar[] = { &&l1 - &&l1, &&l2 - &&l1 };
3529 void *p = &&l1 + ar[a];
3530 goto *p;
3531 l1:
3532 return 1;
3533 l2:
3534 return 2;
3535}
3536EOF
3537if { ac_try='${CC-cc} $CFLAGS -nostdlib -nostartfiles
2b904739 3538 -o conftest conftest.c -lgcc >&5'; { (eval echo configure:3539: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
3d558f4e
UD
3539 libc_cv_gcc_subtract_local_labels=yes
3540else
3541 libc_cv_gcc_subtract_local_labels=no
3542fi
3543rm -f conftest*
3544fi
3545
3546echo "$ac_t""$libc_cv_gcc_subtract_local_labels" 1>&6
3547if test "$libc_cv_gcc_subtract_local_labels" = yes; then
3548 cat >> confdefs.h <<\EOF
3549#define HAVE_SUBTRACT_LOCAL_LABELS 1
3550EOF
3551
3552fi
3553
c8f3e6db 3554echo $ac_n "checking for libgd""... $ac_c" 1>&6
2b904739 3555echo "configure:3556: checking for libgd" >&5
6dab8688
UD
3556if test "$with_gd" != "no"; then
3557 old_CFLAGS="$CFLAGS"
3558 CFLAGS="$CFLAGS $libgd_include"
3559 old_LDFLAGS="$LDFLAGS"
3560 LDFLAGS="$LDFLAGS $libgd_ldflags"
3561 old_LIBS="$LIBS"
3562 LIBS="$LIBS -lgd -lpng -lz -lm"
3563 cat > conftest.$ac_ext <<EOF
2b904739 3564#line 3565 "configure"
c8f3e6db
UD
3565#include "confdefs.h"
3566#include <gd.h>
3567int main() {
3568gdImagePng (0, 0)
3569; return 0; }
3570EOF
2b904739 3571if { (eval echo configure:3572: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
c8f3e6db
UD
3572 rm -rf conftest*
3573 LIBGD=yes
3574else
3575 echo "configure: failed program was:" >&5
3576 cat conftest.$ac_ext >&5
3577 rm -rf conftest*
3578 LIBGD=no
3579fi
3580rm -f conftest*
6dab8688
UD
3581 CFLAGS="$old_CFLAGS"
3582 LDFLAGS="$old_LDFLAGS"
3583 LIBS="$old_LIBS"
3584else
3585 LIBGD=no
3586fi
c8f3e6db
UD
3587echo "$ac_t""$LIBGD" 1>&6
3588
3d558f4e 3589
8ed1e7d5 3590echo $ac_n "checking size of long double""... $ac_c" 1>&6
2b904739 3591echo "configure:3592: checking size of long double" >&5
8ed1e7d5
GK
3592if eval "test \"`echo '$''{'ac_cv_sizeof_long_double'+set}'`\" = set"; then
3593 echo $ac_n "(cached) $ac_c" 1>&6
3594else
3595 if test "$cross_compiling" = yes; then
3596 ac_cv_sizeof_long_double=0
3597else
3598 cat > conftest.$ac_ext <<EOF
2b904739 3599#line 3600 "configure"
8ed1e7d5
GK
3600#include "confdefs.h"
3601#include <stdio.h>
2b904739 3602main()
8ed1e7d5
GK
3603{
3604 FILE *f=fopen("conftestval", "w");
2b904739 3605 if (!f) exit(1);
8ed1e7d5 3606 fprintf(f, "%d\n", sizeof(long double));
2b904739 3607 exit(0);
8ed1e7d5
GK
3608}
3609EOF
2b904739 3610if { (eval echo configure:3611: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
8ed1e7d5
GK
3611then
3612 ac_cv_sizeof_long_double=`cat conftestval`
3613else
3614 echo "configure: failed program was:" >&5
3615 cat conftest.$ac_ext >&5
3616 rm -fr conftest*
3617 ac_cv_sizeof_long_double=0
3618fi
3619rm -fr conftest*
3620fi
3621
3622fi
3623echo "$ac_t""$ac_cv_sizeof_long_double" 1>&6
3624cat >> confdefs.h <<EOF
3625#define SIZEOF_LONG_DOUBLE $ac_cv_sizeof_long_double
3626EOF
3627
3628
3629sizeof_long_double=$ac_cv_sizeof_long_double
3630
3631
cd6ede75
UD
3632### End of automated tests.
3633### Now run sysdeps configure fragments.
3634
3635# sysdeps configure fragments may set these with files to be linked below.
3636libc_link_dests=
3637libc_link_sources=
3638
cb343854 3639# They also can set these variables.
b43b13ac 3640use_ldconfig=no
cb343854 3641ldd_rewrite_script=no
77259608 3642libc_cv_sysconfdir=$sysconfdir
74bd2300 3643libc_cv_gcc_unwind_find_fde=no
cb343854 3644
cd6ede75
UD
3645# Iterate over all the sysdep directories we will use, running their
3646# configure fragments, and looking for a uname implementation.
3647uname=
3648for dir in $sysnames; do
3649 case $dir in
3650 /*) dest=$dir ;;
3651 *) dest=$srcdir/$dir ;;
3652 esac
3653 if test -r $dest/configure; then
3654 echo "$ac_t""running configure fragment for $dest" 1>&6
3655 . $dest/configure
3656 fi
3657
3658 if test -z "$uname"; then
3659 if test -r $dest/uname.c ||
3660 test -r $dest/uname.S ||
3661 { test -r $dest/syscalls.list &&
3662 grep '^uname[ ]' $dest/syscalls.list >/dev/null; }; then
3663 uname=$dir
3664 fi
3665 fi
3666done
3667
74bd2300
UD
3668if test x$libc_cv_gcc_unwind_find_fde = xyes; then
3669 cat >> confdefs.h <<\EOF
3670#define EXPORT_UNWIND_FIND_FDE 1
3671EOF
3672
3673fi
3674
3675
cd6ede75
UD
3676
3677
3678# If we will use the generic uname implementation, we must figure out what
3679# it will say by examining the system, and write the results in config-name.h.
3680if test "$uname" = "sysdeps/generic"; then
3681
3682 uname_sysname=`echo $config_os | sed 's/[0-9.]*$//'`
3683 if test $uname_sysname != $config_os; then
3684 config_release=`echo $config_os | sed s/$uname_sysname//`
3685 fi
3686
3687 echo $ac_n "checking OS release for uname""... $ac_c" 1>&6
2b904739 3688echo "configure:3689: checking OS release for uname" >&5
a808d541 3689if eval "test \"`echo '$''{'libc_cv_uname_release'+set}'`\" = set"; then
cd6ede75
UD
3690 echo $ac_n "(cached) $ac_c" 1>&6
3691else
3692 kernel_release=`echo "$kernel_id" | sed 's/^[^0-9.]*\([0-9.]*\).*$/\1/'`
3693 if test x`echo "$config_release" | sed "s/^$kernel_release//"` \
3694 != x$config_release; then
3695 # The configuration release is a substring of the kernel release.
3696 libc_cv_uname_release=$kernel_release
3697 elif test x$config_release != x; then
3698 libc_cv_uname_release=$config_release
3699 elif test x$kernel_release != x; then
3700 libc_cv_uname_release=$kernel_release
3701 else
3702 libc_cv_uname_release=unknown
3703 fi
3704fi
3705
3706echo "$ac_t""$libc_cv_uname_release" 1>&6
3707 uname_release="$libc_cv_uname_release"
3708
3709 echo $ac_n "checking OS version for uname""... $ac_c" 1>&6
2b904739 3710echo "configure:3711: checking OS version for uname" >&5
a808d541 3711if eval "test \"`echo '$''{'libc_cv_uname_version'+set}'`\" = set"; then
cd6ede75
UD
3712 echo $ac_n "(cached) $ac_c" 1>&6
3713else
3714 kernel_version=`echo "$kernel_id" | sed 's/^[^#]*#\([0-9]*\).*$/\1/'`
3715 if test -n "$kernel_version"; then
3716 libc_cv_uname_version="$kernel_version"
3717 else
3718 libc_cv_uname_version=unknown
3719 fi
3720fi
3721
3722echo "$ac_t""$libc_cv_uname_version" 1>&6
3723 uname_version="$libc_cv_uname_version"
3724
3725 config_uname=config-name.h:config-name.in
3726else
3727 # For non-generic uname, we don't need to create config-name.h at all.
3728 config_uname=
3729fi
3730
3731echo $ac_n "checking stdio selection""... $ac_c" 1>&6
2b904739 3732echo "configure:3733: checking stdio selection" >&5
cd6ede75
UD
3733
3734case $stdio in
3735libio) cat >> confdefs.h <<\EOF
3736#define USE_IN_LIBIO 1
3737EOF
3738 ;;
3739default) stdio=stdio ;;
3740esac
3741echo "$ac_t""$stdio" 1>&6
3742
a53bad16
UD
3743# Test for old glibc 2.0.x headers so that they can be removed properly
3744# Search only in includedir.
3745echo $ac_n "checking for old glibc 2.0.x headers""... $ac_c" 1>&6
2b904739 3746echo "configure:3747: checking for old glibc 2.0.x headers" >&5
011ce8ed 3747if eval test -f "${includedir}/elfclass.h" -a -f "${includedir}/fcntlbits.h"
a53bad16
UD
3748then
3749 old_glibc_headers=yes
3750else
3751 old_glibc_headers=no
3752fi
3753echo "$ac_t""$old_glibc_headers" 1>&6
3754if test ${old_glibc_headers} = yes; then
3755 echo "configure: warning: *** During \"make install\" old headers from glibc 2.0.x will" 1>&2
3756 echo "configure: warning: *** be removed." 1>&2
3757fi
26b4d766 3758
cd6ede75
UD
3759
3760
3761
3762
3763
3764
cb343854 3765
dff14448 3766
77259608 3767
5af3245a 3768
cd6ede75
UD
3769if test $gnu_ld = yes; then
3770 cat >> confdefs.h <<\EOF
3771#define HAVE_GNU_LD 1
3772EOF
3773
3774fi
3775if test $gnu_as = yes; then
3776 cat >> confdefs.h <<\EOF
3777#define HAVE_GNU_AS 1
3778EOF
3779
3780fi
3781if test $elf = yes; then
3782 cat >> confdefs.h <<\EOF
3783#define HAVE_ELF 1
3784EOF
3785
3786fi
5af3245a
UD
3787if test $xcoff = yes; then
3788 cat >> confdefs.h <<\EOF
3789#define HAVE_XCOFF 1
3790EOF
3791
3792fi
cd6ede75
UD
3793
3794
650425ce 3795
cd6ede75
UD
3796if test $shared = default; then
3797 if test $gnu_ld = yes; then
3798 shared=$elf
3799 else
3800 # For now we do not assume shared libs are available. In future more
3801 # tests might become available.
3802 shared=no
3803 fi
3804fi
3805
cc3fa755 3806echo $ac_n "checking whether -fPIC is default""... $ac_c" 1>&6
2b904739 3807echo "configure:3808: checking whether -fPIC is default" >&5
a808d541 3808if eval "test \"`echo '$''{'pic_default'+set}'`\" = set"; then
cc3fa755
UD
3809 echo $ac_n "(cached) $ac_c" 1>&6
3810else
3811 pic_default=yes
3812cat > conftest.c <<EOF
9756dfe1 3813#if defined __PIC__ || defined __pic__ || defined PIC || defined pic
cc3fa755
UD
3814# error PIC is default.
3815#endif
3816EOF
3817if eval "${CC-cc} -S conftest.c 2>&5 1>&5"; then
3818 pic_default=no
3819fi
3820rm -f conftest.*
3821fi
3822
3823echo "$ac_t""$pic_default" 1>&6
3824
3825
3826
cd6ede75
UD
3827
3828
3829
3830
3831
3832
3833
7cabd57c
UD
3834case "$add_ons" in
3835 *door*) linux_doors=yes ;;
3836 *) linux_doors=no ;;
3837esac
3838
3839
746f4007
RM
3840
3841
cd6ede75
UD
3842if test "`(cd $srcdir; pwd)`" = "`pwd`"; then
3843 config_makefile=
3844else
3845 config_makefile=Makefile
3846fi
3847
ee74a442
UD
3848VERSION=`sed -n -e 's/^#define VERSION "\([^"]*\)"/\1/p' < $srcdir/version.h`
3849RELEASE=`sed -n -e 's/^#define RELEASE "\([^"]*\)"/\1/p' < $srcdir/version.h`
3850
cd6ede75
UD
3851
3852
3853trap '' 1 2 15
3854cat > confcache <<\EOF
3855# This file is a shell script that caches the results of configure
3856# tests run on this system so they can be shared between configure
3857# scripts and configure runs. It is not useful on other systems.
3858# If it contains results you don't want to keep, you may remove or edit it.
3859#
3860# By default, configure uses ./config.cache as the cache file,
3861# creating it if it does not exist already. You can give configure
3862# the --cache-file=FILE option to use a different cache file; that is
3863# what configure does when it calls configure scripts in
3864# subdirectories, so they share the cache.
3865# Giving --cache-file=/dev/null disables caching, for debugging configure.
3866# config.status only pays attention to the cache file if you give it the
3867# --recheck option to rerun configure.
3868#
3869EOF
3870# The following way of writing the cache mishandles newlines in values,
3871# but we know of no workaround that is simple, portable, and efficient.
3872# So, don't put newlines in cache variables' values.
3873# Ultrix sh set writes to stderr and can't be redirected directly,
3874# and sets the high bit in the cache file unless we assign to the vars.
3875(set) 2>&1 |
5c2a0669 3876 case `(ac_space=' '; set | grep ac_space) 2>&1` in
cd6ede75
UD
3877 *ac_space=\ *)
3878 # `set' does not quote correctly, so add quotes (double-quote substitution
3879 # turns \\\\ into \\, and sed turns \\ into \).
3880 sed -n \
3881 -e "s/'/'\\\\''/g" \
3882 -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
3883 ;;
3884 *)
3885 # `set' quotes correctly as required by POSIX, so do not add quotes.
3886 sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
3887 ;;
3888 esac >> confcache
3889if cmp -s $cache_file confcache; then
3890 :
3891else
3892 if test -w $cache_file; then
3893 echo "updating cache $cache_file"
3894 cat confcache > $cache_file
3895 else
3896 echo "not updating unwritable cache $cache_file"
3897 fi
3898fi
3899rm -f confcache
3900
3901trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
3902
3903test "x$prefix" = xNONE && prefix=$ac_default_prefix
3904# Let make expand exec_prefix.
3905test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
3906
3907# Any assignment to VPATH causes Sun make to only execute
3908# the first set of double-colon rules, so remove it if not needed.
3909# If there is a colon in the path, we need to keep it.
3910if test "x$srcdir" = x.; then
3911 ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
3912fi
3913
3914trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
3915
3916DEFS=-DHAVE_CONFIG_H
3917
3918# Without the "./", some shells look in PATH for config.status.
3919: ${CONFIG_STATUS=./config.status}
3920
3921echo creating $CONFIG_STATUS
3922rm -f $CONFIG_STATUS
3923cat > $CONFIG_STATUS <<EOF
3924#! /bin/sh
3925# Generated automatically by configure.
3926# Run this file to recreate the current configuration.
3927# This directory was configured as follows,
3928# on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
3929#
3930# $0 $ac_configure_args
3931#
3932# Compiler output produced by configure, useful for debugging
3933# configure, is in ./config.log if it exists.
3934
3935ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
3936for ac_option
3937do
3938 case "\$ac_option" in
3939 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
3940 echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
3941 exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
3942 -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
a808d541 3943 echo "$CONFIG_STATUS generated by autoconf version 2.13"
cd6ede75
UD
3944 exit 0 ;;
3945 -help | --help | --hel | --he | --h)
3946 echo "\$ac_cs_usage"; exit 0 ;;
3947 *) echo "\$ac_cs_usage"; exit 1 ;;
3948 esac
3949done
3950
3951ac_given_srcdir=$srcdir
3952ac_given_INSTALL="$INSTALL"
3953
3954trap 'rm -fr `echo "config.make glibcbug ${config_makefile} ${config_uname} config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
3955EOF
3956cat >> $CONFIG_STATUS <<EOF
3957
3958# Protect against being on the right side of a sed subst in config.status.
3959sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
3960 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
3961$ac_vpsub
3962$extrasub
5c2a0669 3963s%@SHELL@%$SHELL%g
cd6ede75
UD
3964s%@CFLAGS@%$CFLAGS%g
3965s%@CPPFLAGS@%$CPPFLAGS%g
3966s%@CXXFLAGS@%$CXXFLAGS%g
5c2a0669 3967s%@FFLAGS@%$FFLAGS%g
cd6ede75
UD
3968s%@DEFS@%$DEFS%g
3969s%@LDFLAGS@%$LDFLAGS%g
3970s%@LIBS@%$LIBS%g
3971s%@exec_prefix@%$exec_prefix%g
3972s%@prefix@%$prefix%g
3973s%@program_transform_name@%$program_transform_name%g
3974s%@bindir@%$bindir%g
3975s%@sbindir@%$sbindir%g
3976s%@libexecdir@%$libexecdir%g
3977s%@datadir@%$datadir%g
3978s%@sysconfdir@%$sysconfdir%g
3979s%@sharedstatedir@%$sharedstatedir%g
3980s%@localstatedir@%$localstatedir%g
3981s%@libdir@%$libdir%g
3982s%@includedir@%$includedir%g
3983s%@oldincludedir@%$oldincludedir%g
3984s%@infodir@%$infodir%g
3985s%@mandir@%$mandir%g
675322a5 3986s%@with_fp@%$with_fp%g
d67281a7 3987s%@with_cvs@%$with_cvs%g
deb7f0b4 3988s%@oldest_abi@%$oldest_abi%g
cd6ede75 3989s%@subdirs@%$subdirs%g
73237de3 3990s%@force_install@%$force_install%g
2a068d20 3991s%@all_warnings@%$all_warnings%g
cd6ede75
UD
3992s%@host@%$host%g
3993s%@host_alias@%$host_alias%g
3994s%@host_cpu@%$host_cpu%g
3995s%@host_vendor@%$host_vendor%g
3996s%@host_os@%$host_os%g
3997s%@base_machine@%$base_machine%g
3998s%@sysnames@%$sysnames%g
3999s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
5c2a0669 4000s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
cd6ede75
UD
4001s%@INSTALL_DATA@%$INSTALL_DATA%g
4002s%@LN_S@%$LN_S%g
c218729d 4003s%@PWD_P@%$PWD_P%g
cd6ede75
UD
4004s%@build@%$build%g
4005s%@build_alias@%$build_alias%g
4006s%@build_cpu@%$build_cpu%g
4007s%@build_vendor@%$build_vendor%g
4008s%@build_os@%$build_os%g
4bca4c17
UD
4009s%@CC@%$CC%g
4010s%@MAKE@%$MAKE%g
4011s%@MSGFMT@%$MSGFMT%g
4012s%@MAKEINFO@%$MAKEINFO%g
aec103d3 4013s%@SED@%$SED%g
4bca4c17 4014s%@cross_linkable@%$cross_linkable%g
cd6ede75
UD
4015s%@BUILD_CC@%$BUILD_CC%g
4016s%@cross_compiling@%$cross_compiling%g
4017s%@CPP@%$CPP%g
4018s%@AR@%$AR%g
4019s%@RANLIB@%$RANLIB%g
4bca4c17 4020s%@MIG@%$MIG%g
ea9f119b 4021s%@CCVERSION@%$CCVERSION%g
3c720987 4022s%@SYSINCLUDES@%$SYSINCLUDES%g
74bd2300 4023s%@libc_cv_gcc_static_libgcc@%$libc_cv_gcc_static_libgcc%g
cd6ede75
UD
4024s%@BASH@%$BASH%g
4025s%@libc_cv_have_bash2@%$libc_cv_have_bash2%g
4026s%@KSH@%$KSH%g
4027s%@libc_cv_have_ksh@%$libc_cv_have_ksh%g
5aa8ff62 4028s%@AWK@%$AWK%g
a2b08ee5 4029s%@PERL@%$PERL%g
c0016081
UD
4030s%@INSTALL_INFO@%$INSTALL_INFO%g
4031s%@OLD_DEBIAN_INSTALL_INFO@%$OLD_DEBIAN_INSTALL_INFO%g
ae113383 4032s%@BISON@%$BISON%g
cd6ede75 4033s%@VERSIONING@%$VERSIONING%g
2d499f55 4034s%@libc_cv_asm_protected_directive@%$libc_cv_asm_protected_directive%g
2c617417 4035s%@libc_cv_initfinit_array@%$libc_cv_initfinit_array%g
2f54c82d
UD
4036s%@libc_cv_z_nodelete@%$libc_cv_z_nodelete%g
4037s%@libc_cv_z_nodlopen@%$libc_cv_z_nodlopen%g
5d916713 4038s%@libc_cv_z_initfirst@%$libc_cv_z_initfirst%g
639c3248 4039s%@libc_cv_Bgroup@%$libc_cv_Bgroup%g
f13df7c7 4040s%@libc_cv_z_combreloc@%$libc_cv_z_combreloc%g
cd6ede75 4041s%@libc_cv_have_initfini@%$libc_cv_have_initfini%g
b17277cf 4042s%@no_whole_archive@%$no_whole_archive%g
dff14448 4043s%@exceptions@%$exceptions%g
c8f3e6db 4044s%@LIBGD@%$LIBGD%g
8ed1e7d5 4045s%@sizeof_long_double@%$sizeof_long_double%g
74bd2300 4046s%@libc_cv_gcc_unwind_find_fde@%$libc_cv_gcc_unwind_find_fde%g
cd6ede75
UD
4047s%@uname_sysname@%$uname_sysname%g
4048s%@uname_release@%$uname_release%g
4049s%@uname_version@%$uname_version%g
4050s%@stdio@%$stdio%g
dff14448 4051s%@old_glibc_headers@%$old_glibc_headers%g
cd6ede75 4052s%@libc_cv_slibdir@%$libc_cv_slibdir%g
a1d84548 4053s%@libc_cv_localedir@%$libc_cv_localedir%g
77259608 4054s%@libc_cv_sysconfdir@%$libc_cv_sysconfdir%g
cd6ede75 4055s%@libc_cv_rootsbindir@%$libc_cv_rootsbindir%g
b43b13ac 4056s%@use_ldconfig@%$use_ldconfig%g
cb343854 4057s%@ldd_rewrite_script@%$ldd_rewrite_script%g
cd6ede75
UD
4058s%@gnu_ld@%$gnu_ld%g
4059s%@gnu_as@%$gnu_as%g
4060s%@elf@%$elf%g
5af3245a 4061s%@xcoff@%$xcoff%g
650425ce 4062s%@static@%$static%g
cd6ede75 4063s%@shared@%$shared%g
cc3fa755 4064s%@pic_default@%$pic_default%g
cd6ede75
UD
4065s%@profile@%$profile%g
4066s%@omitfp@%$omitfp%g
4067s%@bounded@%$bounded%g
4068s%@static_nss@%$static_nss%g
4069s%@nopic_initfini@%$nopic_initfini%g
4070s%@DEFINES@%$DEFINES%g
7cabd57c 4071s%@linux_doors@%$linux_doors%g
746f4007 4072s%@mach_interface_list@%$mach_interface_list%g
cd6ede75 4073s%@VERSION@%$VERSION%g
ee74a442 4074s%@RELEASE@%$RELEASE%g
cd6ede75
UD
4075
4076CEOF
4077EOF
4078
4079cat >> $CONFIG_STATUS <<\EOF
4080
4081# Split the substitutions into bite-sized pieces for seds with
4082# small command number limits, like on Digital OSF/1 and HP-UX.
4083ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
4084ac_file=1 # Number of current file.
4085ac_beg=1 # First line for current file.
4086ac_end=$ac_max_sed_cmds # Line after last line for current file.
4087ac_more_lines=:
4088ac_sed_cmds=""
4089while $ac_more_lines; do
4090 if test $ac_beg -gt 1; then
4091 sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
4092 else
4093 sed "${ac_end}q" conftest.subs > conftest.s$ac_file
4094 fi
4095 if test ! -s conftest.s$ac_file; then
4096 ac_more_lines=false
4097 rm -f conftest.s$ac_file
4098 else
4099 if test -z "$ac_sed_cmds"; then
4100 ac_sed_cmds="sed -f conftest.s$ac_file"
4101 else
4102 ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
4103 fi
4104 ac_file=`expr $ac_file + 1`
4105 ac_beg=$ac_end
4106 ac_end=`expr $ac_end + $ac_max_sed_cmds`
4107 fi
4108done
4109if test -z "$ac_sed_cmds"; then
4110 ac_sed_cmds=cat
4111fi
4112EOF
4113
4114cat >> $CONFIG_STATUS <<EOF
4115
4116CONFIG_FILES=\${CONFIG_FILES-"config.make glibcbug ${config_makefile} ${config_uname}"}
4117EOF
4118cat >> $CONFIG_STATUS <<\EOF
4119for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
4120 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
4121 case "$ac_file" in
4122 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
4123 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
4124 *) ac_file_in="${ac_file}.in" ;;
4125 esac
4126
4127 # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
4128
4129 # Remove last slash and all that follows it. Not all systems have dirname.
4130 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
4131 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
4132 # The file is in a subdirectory.
4133 test ! -d "$ac_dir" && mkdir "$ac_dir"
4134 ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
4135 # A "../" for each directory in $ac_dir_suffix.
4136 ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
4137 else
4138 ac_dir_suffix= ac_dots=
4139 fi
4140
4141 case "$ac_given_srcdir" in
4142 .) srcdir=.
4143 if test -z "$ac_dots"; then top_srcdir=.
4144 else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
4145 /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
4146 *) # Relative path.
4147 srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
4148 top_srcdir="$ac_dots$ac_given_srcdir" ;;
4149 esac
4150
4151 case "$ac_given_INSTALL" in
4152 [/$]*) INSTALL="$ac_given_INSTALL" ;;
4153 *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
4154 esac
4155
4156 echo creating "$ac_file"
4157 rm -f "$ac_file"
4158 configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
4159 case "$ac_file" in
4160 *Makefile*) ac_comsub="1i\\
4161# $configure_input" ;;
4162 *) ac_comsub= ;;
4163 esac
4164
4165 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
4166 sed -e "$ac_comsub
4167s%@configure_input@%$configure_input%g
4168s%@srcdir@%$srcdir%g
4169s%@top_srcdir@%$top_srcdir%g
4170s%@INSTALL@%$INSTALL%g
4171" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
4172fi; done
4173rm -f conftest.s*
4174
4175# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
4176# NAME is the cpp macro being defined and VALUE is the value it is being given.
4177#
4178# ac_d sets the value in "#define NAME VALUE" lines.
4179ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)'
4180ac_dB='\([ ][ ]*\)[^ ]*%\1#\2'
4181ac_dC='\3'
4182ac_dD='%g'
4183# ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
4184ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
4185ac_uB='\([ ]\)%\1#\2define\3'
4186ac_uC=' '
4187ac_uD='\4%g'
4188# ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
4189ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
4190ac_eB='$%\1#\2define\3'
4191ac_eC=' '
4192ac_eD='%g'
4193
4194if test "${CONFIG_HEADERS+set}" != set; then
4195EOF
4196cat >> $CONFIG_STATUS <<EOF
4197 CONFIG_HEADERS="config.h"
4198EOF
4199cat >> $CONFIG_STATUS <<\EOF
4200fi
4201for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
4202 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
4203 case "$ac_file" in
4204 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
4205 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
4206 *) ac_file_in="${ac_file}.in" ;;
4207 esac
4208
4209 echo creating $ac_file
4210
4211 rm -f conftest.frag conftest.in conftest.out
4212 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
4213 cat $ac_file_inputs > conftest.in
4214
4215EOF
4216
4217# Transform confdefs.h into a sed script conftest.vals that substitutes
4218# the proper values into config.h.in to produce config.h. And first:
4219# Protect against being on the right side of a sed subst in config.status.
4220# Protect against being in an unquoted here document in config.status.
4221rm -f conftest.vals
4222cat > conftest.hdr <<\EOF
4223s/[\\&%]/\\&/g
4224s%[\\$`]%\\&%g
4225s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
4226s%ac_d%ac_u%gp
4227s%ac_u%ac_e%gp
4228EOF
4229sed -n -f conftest.hdr confdefs.h > conftest.vals
4230rm -f conftest.hdr
4231
4232# This sed command replaces #undef with comments. This is necessary, for
4233# example, in the case of _POSIX_SOURCE, which is predefined and required
4234# on some systems where configure will not decide to define it.
4235cat >> conftest.vals <<\EOF
4236s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
4237EOF
4238
4239# Break up conftest.vals because some shells have a limit on
4240# the size of here documents, and old seds have small limits too.
4241
4242rm -f conftest.tail
4243while :
4244do
4245 ac_lines=`grep -c . conftest.vals`
4246 # grep -c gives empty output for an empty file on some AIX systems.
4247 if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
4248 # Write a limited-size here document to conftest.frag.
4249 echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
4250 sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
4251 echo 'CEOF
4252 sed -f conftest.frag conftest.in > conftest.out
4253 rm -f conftest.in
4254 mv conftest.out conftest.in
4255' >> $CONFIG_STATUS
4256 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
4257 rm -f conftest.vals
4258 mv conftest.tail conftest.vals
4259done
4260rm -f conftest.vals
4261
4262cat >> $CONFIG_STATUS <<\EOF
4263 rm -f conftest.frag conftest.h
4264 echo "/* $ac_file. Generated automatically by configure. */" > conftest.h
4265 cat conftest.in >> conftest.h
4266 rm -f conftest.in
4267 if cmp -s $ac_file conftest.h 2>/dev/null; then
4268 echo "$ac_file is unchanged"
4269 rm -f conftest.h
4270 else
4271 # Remove last slash and all that follows it. Not all systems have dirname.
4272 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
4273 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
4274 # The file is in a subdirectory.
4275 test ! -d "$ac_dir" && mkdir "$ac_dir"
4276 fi
4277 rm -f $ac_file
4278 mv conftest.h $ac_file
4279 fi
4280fi; done
4281
4282EOF
4283
4284cat >> $CONFIG_STATUS <<EOF
4285ac_sources="`echo $libc_link_sources`"
4286ac_dests="`echo $libc_link_dests`"
4287EOF
4288
4289cat >> $CONFIG_STATUS <<\EOF
4290srcdir=$ac_given_srcdir
4291while test -n "$ac_sources"; do
4292 set $ac_dests; ac_dest=$1; shift; ac_dests=$*
4293 set $ac_sources; ac_source=$1; shift; ac_sources=$*
4294
4295 echo "linking $srcdir/$ac_source to $ac_dest"
4296
4297 if test ! -r $srcdir/$ac_source; then
4298 { echo "configure: error: $srcdir/$ac_source: File not found" 1>&2; exit 1; }
4299 fi
4300 rm -f $ac_dest
4301
4302 # Make relative symlinks.
4303 # Remove last slash and all that follows it. Not all systems have dirname.
4304 ac_dest_dir=`echo $ac_dest|sed 's%/[^/][^/]*$%%'`
4305 if test "$ac_dest_dir" != "$ac_dest" && test "$ac_dest_dir" != .; then
4306 # The dest file is in a subdirectory.
4307 test ! -d "$ac_dest_dir" && mkdir "$ac_dest_dir"
4308 ac_dest_dir_suffix="/`echo $ac_dest_dir|sed 's%^\./%%'`"
4309 # A "../" for each directory in $ac_dest_dir_suffix.
4310 ac_dots=`echo $ac_dest_dir_suffix|sed 's%/[^/]*%../%g'`
4311 else
4312 ac_dest_dir_suffix= ac_dots=
4313 fi
4314
4315 case "$srcdir" in
4316 [/$]*) ac_rel_source="$srcdir/$ac_source" ;;
4317 *) ac_rel_source="$ac_dots$srcdir/$ac_source" ;;
4318 esac
4319
4320 # Make a symlink if possible; otherwise try a hard link.
4321 if ln -s $ac_rel_source $ac_dest 2>/dev/null ||
4322 ln $srcdir/$ac_source $ac_dest; then :
4323 else
4324 { echo "configure: error: can not link $ac_dest to $srcdir/$ac_source" 1>&2; exit 1; }
4325 fi
4326done
4327EOF
4328cat >> $CONFIG_STATUS <<EOF
c0fb8a56 4329config_vars='$config_vars'
cd6ede75
UD
4330EOF
4331cat >> $CONFIG_STATUS <<\EOF
4332
c0fb8a56
UD
4333case $CONFIG_FILES in *config.make*)
4334echo "$config_vars" >> config.make;;
4335esac
4336test -d bits || mkdir bits
cd6ede75
UD
4337exit 0
4338EOF
4339chmod +x $CONFIG_STATUS
4340rm -fr confdefs* $ac_clean_files
a808d541 4341test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
cd6ede75
UD
4342
4343if test "$no_recursion" != yes; then
4344
4345 # Remove --cache-file and --srcdir arguments so they do not pile up.
4346 ac_sub_configure_args=
4347 ac_prev=
4348 for ac_arg in $ac_configure_args; do
4349 if test -n "$ac_prev"; then
4350 ac_prev=
4351 continue
4352 fi
4353 case "$ac_arg" in
4354 -cache-file | --cache-file | --cache-fil | --cache-fi \
4355 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
4356 ac_prev=cache_file ;;
4357 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
4358 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
4359 ;;
4360 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
4361 ac_prev=srcdir ;;
4362 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
4363 ;;
4364 *) ac_sub_configure_args="$ac_sub_configure_args $ac_arg" ;;
4365 esac
4366 done
4367
4368 for ac_config_dir in $add_ons; do
4369
4370 # Do not complain, so a configure script can configure whichever
4371 # parts of a large source tree are present.
4372 if test ! -d $srcdir/$ac_config_dir; then
4373 continue
4374 fi
4375
4376 echo configuring in $ac_config_dir
4377
4378 case "$srcdir" in
4379 .) ;;
4380 *)
4381 if test -d ./$ac_config_dir || mkdir ./$ac_config_dir; then :;
4382 else
4383 { echo "configure: error: can not create `pwd`/$ac_config_dir" 1>&2; exit 1; }
4384 fi
4385 ;;
4386 esac
4387
4388 ac_popdir=`pwd`
4389 cd $ac_config_dir
4390
4391 # A "../" for each directory in /$ac_config_dir.
4392 ac_dots=`echo $ac_config_dir|sed -e 's%^\./%%' -e 's%[^/]$%&/%' -e 's%[^/]*/%../%g'`
4393
4394 case "$srcdir" in
4395 .) # No --srcdir option. We are building in place.
4396 ac_sub_srcdir=$srcdir ;;
4397 /*) # Absolute path.
4398 ac_sub_srcdir=$srcdir/$ac_config_dir ;;
4399 *) # Relative path.
4400 ac_sub_srcdir=$ac_dots$srcdir/$ac_config_dir ;;
4401 esac
4402
4403 # Check for guested configure; otherwise get Cygnus style configure.
4404 if test -f $ac_sub_srcdir/configure; then
a808d541 4405 ac_sub_configure=$ac_sub_srcdir/configure
cd6ede75
UD
4406 elif test -f $ac_sub_srcdir/configure.in; then
4407 ac_sub_configure=$ac_configure
4408 else
4409 echo "configure: warning: no configuration information is in $ac_config_dir" 1>&2
4410 ac_sub_configure=
4411 fi
4412
4413 # The recursion is here.
4414 if test -n "$ac_sub_configure"; then
4415
4416 # Make the cache file name correct relative to the subdirectory.
4417 case "$cache_file" in
4418 /*) ac_sub_cache_file=$cache_file ;;
4419 *) # Relative path.
4420 ac_sub_cache_file="$ac_dots$cache_file" ;;
4421 esac
4422 case "$ac_given_INSTALL" in
4423 [/$]*) INSTALL="$ac_given_INSTALL" ;;
4424 *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
4425 esac
4426
a808d541 4427 echo "running ${CONFIG_SHELL-/bin/sh} $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_sub_srcdir"
cd6ede75 4428 # The eval makes quoting arguments work.
a808d541 4429 if eval ${CONFIG_SHELL-/bin/sh} $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_sub_srcdir
cd6ede75
UD
4430 then :
4431 else
4432 { echo "configure: error: $ac_sub_configure failed for $ac_config_dir" 1>&2; exit 1; }
4433 fi
4434 fi
4435
4436 cd $ac_popdir
4437 done
4438fi
4439