]> git.ipfire.org Git - thirdparty/glibc.git/blame - configure
Update.
[thirdparty/glibc.git] / configure
CommitLineData
28f540f4
RM
1#! /bin/sh
2
424f8c09 3# From configure.in CVSid
28f540f4 4# Guess values for system-dependent variables and create Makefiles.
a5113b14 5# Generated automatically using autoconf version 2.99
c224a18a 6# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
28f540f4
RM
7#
8# This configure script is free software; the Free Software Foundation
9# gives unlimited permission to copy, distribute and modify it.
10
11# Defaults:
12ac_help=
13ac_default_prefix=/usr/local
14# Any additions from configure.in:
15ac_help="$ac_help
16 --with-gmp=DIRECTORY find GMP source code in DIRECTORY (not needed)"
75914335
RM
17ac_help="$ac_help
18 --with-gettext=DIR find GNU gettext source code in DIR (not needed)"
e215c478 19ac_help="$ac_help
45086082 20 --with-fp if using floating-point hardware default=yes"
28f540f4
RM
21ac_help="$ac_help
22 --with-gnu-binutils if using GNU binutils (as and ld)"
23ac_help="$ac_help
24 --with-gnu-ld if using GNU ld (in the binutils package)"
25ac_help="$ac_help
26 --with-gnu-as if using GNU as (in the binutils package)"
27ac_help="$ac_help
28 --with-elf if using the ELF object format"
d17e960c
RM
29ac_help="$ac_help
30 --enable-libio build in GNU libio instead of GNU stdio"
424f8c09
RM
31ac_help="$ac_help
32 --enable-shared build shared library [default=yes if GNU ld & ELF]"
33ac_help="$ac_help
34 --enable-profile build profiled library [default=yes]"
35ac_help="$ac_help
6b3a2224
RM
36 --enable-omitfp build undebuggable optimized library [default=no]"
37ac_help="$ac_help
38 --enable-add-ons=DIR... configure and build named extra directories"
28f540f4
RM
39
40# Initialize some variables set by options.
41# The variables have the same names as the options, with
42# dashes changed to underlines.
43build=NONE
44cache_file=./config.cache
45exec_prefix=NONE
46host=NONE
47no_create=
48nonopt=NONE
49no_recursion=
50prefix=NONE
51program_prefix=NONE
52program_suffix=NONE
53program_transform_name=s,x,x,
54silent=
55site=
56srcdir=
57target=NONE
58verbose=
59x_includes=NONE
60x_libraries=NONE
b8dc6a10
RM
61bindir='${exec_prefix}/bin'
62sbindir='${exec_prefix}/sbin'
63libexecdir='${exec_prefix}/libexec'
64datadir='${prefix}/share'
65sysconfdir='${prefix}/etc'
66sharedstatedir='${prefix}/com'
67localstatedir='${prefix}/var'
68libdir='${exec_prefix}/lib'
69includedir='${prefix}/include'
70oldincludedir='/usr/include'
71infodir='${prefix}/info'
72mandir='${prefix}/man'
28f540f4
RM
73
74# Initialize some other variables.
75subdirs=
91c7b85d 76MFLAGS= MAKEFLAGS=
28f540f4
RM
77
78ac_prev=
79for ac_option
80do
81
82 # If the previous option needs an argument, assign it.
83 if test -n "$ac_prev"; then
84 eval "$ac_prev=\$ac_option"
85 ac_prev=
86 continue
87 fi
88
89 case "$ac_option" in
90 -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
91 *) ac_optarg= ;;
92 esac
93
94 # Accept the important Cygnus configure options, so we can diagnose typos.
95
96 case "$ac_option" in
97
b8dc6a10
RM
98 -bindir | --bindir | --bindi | --bind | --bin | --bi)
99 ac_prev=bindir ;;
100 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
101 bindir="$ac_optarg" ;;
102
103 -build | --build | --buil | --bui | --bu)
28f540f4 104 ac_prev=build ;;
b8dc6a10 105 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
28f540f4
RM
106 build="$ac_optarg" ;;
107
108 -cache-file | --cache-file | --cache-fil | --cache-fi \
109 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
110 ac_prev=cache_file ;;
111 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
112 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
113 cache_file="$ac_optarg" ;;
114
b8dc6a10
RM
115 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
116 ac_prev=datadir ;;
117 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
118 | --da=*)
119 datadir="$ac_optarg" ;;
120
28f540f4
RM
121 -disable-* | --disable-*)
122 ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
123 # Reject names that are not valid shell variable names.
124 if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
125 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
126 fi
127 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
128 eval "enable_${ac_feature}=no" ;;
129
130 -enable-* | --enable-*)
131 ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
132 # Reject names that are not valid shell variable names.
133 if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
134 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
135 fi
136 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
137 case "$ac_option" in
138 *=*) ;;
139 *) ac_optarg=yes ;;
140 esac
141 eval "enable_${ac_feature}='$ac_optarg'" ;;
142
143 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
144 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
145 | --exec | --exe | --ex)
146 ac_prev=exec_prefix ;;
147 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
148 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
149 | --exec=* | --exe=* | --ex=*)
150 exec_prefix="$ac_optarg" ;;
151
152 -gas | --gas | --ga | --g)
153 # Obsolete; use --with-gas.
154 with_gas=yes ;;
155
156 -help | --help | --hel | --he)
157 # Omit some internal or obsolete options to make the list less imposing.
158 # This message is too long to be a string in the A/UX 3.1 sh.
159 cat << EOF
160Usage: configure [options] [host]
161Options: [defaults in brackets after descriptions]
162Configuration:
163 --cache-file=FILE cache test results in FILE
164 --help print this message
165 --no-create do not create output files
166 --quiet, --silent do not print \`checking...' messages
167 --version print the version of autoconf that created configure
168Directory and file names:
169 --prefix=PREFIX install architecture-independent files in PREFIX
170 [$ac_default_prefix]
b8dc6a10 171 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
28f540f4 172 [same as prefix]
b8dc6a10
RM
173 --bindir=DIR user executables in DIR [EPREFIX/bin]
174 --sbindir=DIR system admin executables in DIR [EPREFIX/sbin]
175 --libexecdir=DIR program executables in DIR [EPREFIX/libexec]
1ed0083c
RM
176 --datadir=DIR read-only architecture-independent data in DIR
177 [PREFIX/share]
b8dc6a10 178 --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc]
1ed0083c
RM
179 --sharedstatedir=DIR modifiable architecture-independent data in DIR
180 [PREFIX/com]
b8dc6a10
RM
181 --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var]
182 --libdir=DIR object code libraries in DIR [EPREFIX/lib]
183 --includedir=DIR C header files in DIR [PREFIX/include]
184 --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include]
185 --infodir=DIR info documentation in DIR [PREFIX/info]
186 --mandir=DIR man documentation in DIR [PREFIX/man]
28f540f4
RM
187 --srcdir=DIR find the sources in DIR [configure dir or ..]
188 --program-prefix=PREFIX prepend PREFIX to installed program names
189 --program-suffix=SUFFIX append SUFFIX to installed program names
1ed0083c
RM
190 --program-transform-name=PROGRAM
191 run sed PROGRAM on installed program names
b8dc6a10
RM
192EOF
193 cat << EOF
28f540f4
RM
194Host type:
195 --build=BUILD configure for building on BUILD [BUILD=HOST]
196 --host=HOST configure for HOST [guessed]
197 --target=TARGET configure for TARGET [TARGET=HOST]
198Features and packages:
199 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
200 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
201 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
202 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
203 --x-includes=DIR X include files are in DIR
204 --x-libraries=DIR X library files are in DIR
28f540f4 205EOF
1ed0083c
RM
206 if test -n "$ac_help"; then
207 echo "--enable and --with options recognized:$ac_help"
208 fi
28f540f4
RM
209 exit 0 ;;
210
211 -host | --host | --hos | --ho)
212 ac_prev=host ;;
213 -host=* | --host=* | --hos=* | --ho=*)
214 host="$ac_optarg" ;;
215
b8dc6a10
RM
216 -includedir | --includedir | --includedi | --included | --include \
217 | --includ | --inclu | --incl | --inc)
218 ac_prev=includedir ;;
219 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
220 | --includ=* | --inclu=* | --incl=* | --inc=*)
221 includedir="$ac_optarg" ;;
222
223 -infodir | --infodir | --infodi | --infod | --info | --inf)
224 ac_prev=infodir ;;
225 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
226 infodir="$ac_optarg" ;;
227
228 -libdir | --libdir | --libdi | --libd)
229 ac_prev=libdir ;;
230 -libdir=* | --libdir=* | --libdi=* | --libd=*)
231 libdir="$ac_optarg" ;;
232
233 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
234 | --libexe | --libex | --libe)
235 ac_prev=libexecdir ;;
236 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
237 | --libexe=* | --libex=* | --libe=*)
238 libexecdir="$ac_optarg" ;;
239
240 -localstatedir | --localstatedir | --localstatedi | --localstated \
241 | --localstate | --localstat | --localsta | --localst \
242 | --locals | --local | --loca | --loc | --lo)
243 ac_prev=localstatedir ;;
244 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
245 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
246 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
247 localstatedir="$ac_optarg" ;;
248
249 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
250 ac_prev=mandir ;;
251 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
252 mandir="$ac_optarg" ;;
253
28f540f4
RM
254 -nfp | --nfp | --nf)
255 # Obsolete; use --without-fp.
256 with_fp=no ;;
257
258 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
259 | --no-cr | --no-c)
260 no_create=yes ;;
261
262 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
263 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
264 no_recursion=yes ;;
265
b8dc6a10
RM
266 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
267 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
268 | --oldin | --oldi | --old | --ol | --o)
269 ac_prev=oldincludedir ;;
270 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
271 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
272 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
273 oldincludedir="$ac_optarg" ;;
274
28f540f4
RM
275 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
276 ac_prev=prefix ;;
277 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
278 prefix="$ac_optarg" ;;
279
280 -program-prefix | --program-prefix | --program-prefi | --program-pref \
281 | --program-pre | --program-pr | --program-p)
282 ac_prev=program_prefix ;;
283 -program-prefix=* | --program-prefix=* | --program-prefi=* \
284 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
285 program_prefix="$ac_optarg" ;;
286
287 -program-suffix | --program-suffix | --program-suffi | --program-suff \
288 | --program-suf | --program-su | --program-s)
289 ac_prev=program_suffix ;;
290 -program-suffix=* | --program-suffix=* | --program-suffi=* \
291 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
292 program_suffix="$ac_optarg" ;;
293
294 -program-transform-name | --program-transform-name \
295 | --program-transform-nam | --program-transform-na \
296 | --program-transform-n | --program-transform- \
297 | --program-transform | --program-transfor \
298 | --program-transfo | --program-transf \
299 | --program-trans | --program-tran \
300 | --progr-tra | --program-tr | --program-t)
301 ac_prev=program_transform_name ;;
302 -program-transform-name=* | --program-transform-name=* \
303 | --program-transform-nam=* | --program-transform-na=* \
304 | --program-transform-n=* | --program-transform-=* \
305 | --program-transform=* | --program-transfor=* \
306 | --program-transfo=* | --program-transf=* \
307 | --program-trans=* | --program-tran=* \
308 | --progr-tra=* | --program-tr=* | --program-t=*)
309 program_transform_name="$ac_optarg" ;;
310
311 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
312 | -silent | --silent | --silen | --sile | --sil)
313 silent=yes ;;
314
b8dc6a10
RM
315 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
316 ac_prev=sbindir ;;
317 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
318 | --sbi=* | --sb=*)
319 sbindir="$ac_optarg" ;;
320
321 -sharedstatedir | --sharedstatedir | --sharedstatedi \
322 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
323 | --sharedst | --shareds | --shared | --share | --shar \
324 | --sha | --sh)
325 ac_prev=sharedstatedir ;;
326 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
327 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
328 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
329 | --sha=* | --sh=*)
330 sharedstatedir="$ac_optarg" ;;
331
28f540f4
RM
332 -site | --site | --sit)
333 ac_prev=site ;;
334 -site=* | --site=* | --sit=*)
335 site="$ac_optarg" ;;
336
337 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
338 ac_prev=srcdir ;;
339 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
340 srcdir="$ac_optarg" ;;
341
b8dc6a10
RM
342 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
343 | --syscon | --sysco | --sysc | --sys | --sy)
344 ac_prev=sysconfdir ;;
345 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
346 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
347 sysconfdir="$ac_optarg" ;;
348
28f540f4
RM
349 -target | --target | --targe | --targ | --tar | --ta | --t)
350 ac_prev=target ;;
351 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
352 target="$ac_optarg" ;;
353
354 -v | -verbose | --verbose | --verbos | --verbo | --verb)
355 verbose=yes ;;
356
357 -version | --version | --versio | --versi | --vers)
a5113b14 358 echo "configure generated by autoconf version 2.99"
28f540f4
RM
359 exit 0 ;;
360
361 -with-* | --with-*)
362 ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
363 # Reject names that are not valid shell variable names.
364 if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
365 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
366 fi
367 ac_package=`echo $ac_package| sed 's/-/_/g'`
368 case "$ac_option" in
369 *=*) ;;
370 *) ac_optarg=yes ;;
371 esac
372 eval "with_${ac_package}='$ac_optarg'" ;;
373
374 -without-* | --without-*)
375 ac_package=`echo $ac_option|sed -e 's/-*without-//'`
376 # Reject names that are not valid shell variable names.
377 if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
378 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
379 fi
380 ac_package=`echo $ac_package| sed 's/-/_/g'`
381 eval "with_${ac_package}=no" ;;
382
383 --x)
384 # Obsolete; use --with-x.
385 with_x=yes ;;
386
387 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
388 | --x-incl | --x-inc | --x-in | --x-i)
389 ac_prev=x_includes ;;
390 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
391 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
392 x_includes="$ac_optarg" ;;
393
394 -x-libraries | --x-libraries | --x-librarie | --x-librari \
395 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
396 ac_prev=x_libraries ;;
397 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
398 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
399 x_libraries="$ac_optarg" ;;
400
401 -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
402 ;;
403
91c7b85d 404 *)
28f540f4
RM
405 if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
406 echo "configure: warning: $ac_option: invalid host type" 1>&2
407 fi
408 if test "x$nonopt" != xNONE; then
409 { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
410 fi
411 nonopt="$ac_option"
412 ;;
413
414 esac
415done
416
417if test -n "$ac_prev"; then
418 { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
419fi
420
421trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
422
423# File descriptor usage:
424# 0 standard input
425# 1 file creation
426# 2 errors and warnings
427# 3 some systems may open it to /dev/tty
428# 4 used on the Kubota Titan
f55814ff 429# 6 checking for... messages and results
28f540f4
RM
430# 5 compiler messages saved in config.log
431if test "$silent" = yes; then
f55814ff 432 exec 6>/dev/null
28f540f4 433else
f55814ff 434 exec 6>&1
28f540f4
RM
435fi
436exec 5>./config.log
437
438echo "\
439This file contains any messages produced by compilers while
440running configure, to aid debugging if configure makes a mistake.
441" 1>&5
442
443# Strip out --no-create and --no-recursion so they do not pile up.
444# Also quote any args containing shell metacharacters.
445ac_configure_args=
446for ac_arg
447do
448 case "$ac_arg" in
449 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
450 | --no-cr | --no-c) ;;
451 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
452 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
453 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
454 ac_configure_args="$ac_configure_args '$ac_arg'" ;;
455 *) ac_configure_args="$ac_configure_args $ac_arg" ;;
456 esac
457done
458
459# NLS nuisances.
460# Only set LANG and LC_ALL to C if already set.
461# These must not be set unconditionally because not all systems understand
462# e.g. LANG=C (notably SCO).
463if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
464if test "${LANG+set}" = set; then LANG=C; export LANG; fi
465
466# confdefs.h avoids OS command line length limits that DEFS can exceed.
467rm -rf conftest* confdefs.h
468# AIX cpp loses on an empty file, so make sure it contains at least a newline.
469echo > confdefs.h
470
471# A filename unique to this package, relative to the directory that
472# configure is in, which we can look for to find out if srcdir is correct.
473ac_unique_file=features.h
474
475# Find the source files, if location was not specified.
476if test -z "$srcdir"; then
477 ac_srcdir_defaulted=yes
478 # Try the directory containing this script, then its parent.
479 ac_prog=$0
480 ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
481 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
482 srcdir=$ac_confdir
483 if test ! -r $srcdir/$ac_unique_file; then
484 srcdir=..
485 fi
486else
487 ac_srcdir_defaulted=no
488fi
489if test ! -r $srcdir/$ac_unique_file; then
490 if test "$ac_srcdir_defaulted" = yes; then
491 { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
492 else
493 { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
494 fi
495fi
496srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
497
498# Prefer explicitly selected file to automatically selected ones.
499if test -z "$CONFIG_SITE"; then
500 if test "x$prefix" != xNONE; then
501 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
502 else
503 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
504 fi
505fi
506for ac_site_file in $CONFIG_SITE; do
507 if test -r "$ac_site_file"; then
508 echo "loading site script $ac_site_file"
509 . "$ac_site_file"
510 fi
511done
512
513if test -r "$cache_file"; then
514 echo "loading cache $cache_file"
515 . $cache_file
516else
517 echo "creating cache $cache_file"
518 > $cache_file
519fi
520
521ac_ext=c
522# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
c6de6968
RM
523ac_cpp='$CPP $CPPFLAGS'
524ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
525ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
28f540f4
RM
526
527if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
528 # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
529 if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
530 ac_n= ac_c='
531' ac_t=' '
532 else
533 ac_n=-n ac_c= ac_t=
534 fi
535else
536 ac_n= ac_c='\c' ac_t=
537fi
538
539 if test -r /vmunix; then
540 kernel_id=`strings /vmunix | grep UNIX`
541 elif test -r /dynix; then
542 kernel_id=`strings /dynix | grep DYNIX`
543 else
544 kernel_id=
545 fi
546
547
548
549
550# This will get text that should go into config.make.
551config_vars=
552
553# Check for a --with-gmp argument and set gmp-srcdir in config.make.
554# Check whether --with-gmp or --without-gmp was given.
b8dc6a10
RM
555if test "${with_gmp+set}" = set; then
556 withval="$with_gmp"
28f540f4
RM
557 case "$with_gmp" in
558yes) { echo "configure: error: --with-gmp requires an argument; use --with-gmp=DIRECTORY" 1>&2; exit 1; } ;;
559''|no) ;;
560*) config_vars="$config_vars
561gmp-srcdir = $withval" ;;
562esac
563
564fi
565
75914335
RM
566# Check for a --with-gettext argument and set gettext-srcdir in config.make.
567# Check whether --with-gettext or --without-gettext was given.
568if test "${with_gettext+set}" = set; then
569 withval="$with_gettext"
570 case "$with_gettext" in
571yes)
572 { echo "configure: error: --with-gettext requires an argument; use --with-gettext=DIR" 1>&2; exit 1; } ;;
573''|no) ;;
574*)
575 config_vars="$config_vars
576gettext-srcdir = $withval" ;;
577esac
578
579fi
580
28f540f4 581
e215c478 582# Check whether --with-fp or --without-fp was given.
b8dc6a10
RM
583if test "${with_fp+set}" = set; then
584 withval="$with_fp"
e215c478
RM
585 with_fp=$withval
586else
587 with_fp=yes
588fi
589
28f540f4 590# Check whether --with-gnu-binutils or --without-gnu-binutils was given.
b8dc6a10
RM
591if test "${with_gnu_binutils+set}" = set; then
592 withval="$with_gnu_binutils"
e215c478 593 gnu_binutils=$withval
28f540f4
RM
594else
595 gnu_binutils=no
596fi
597
598# Check whether --with-gnu-ld or --without-gnu-ld was given.
b8dc6a10
RM
599if test "${with_gnu_ld+set}" = set; then
600 withval="$with_gnu_ld"
e215c478 601 gnu_ld=$withval
28f540f4
RM
602else
603 gnu_ld=no
604fi
605
606# Check whether --with-gnu-as or --without-gnu-as was given.
b8dc6a10
RM
607if test "${with_gnu_as+set}" = set; then
608 withval="$with_gnu_as"
e215c478 609 gnu_as=$withval
28f540f4
RM
610else
611 gnu_as=no
612fi
613
614test $gnu_binutils = yes && gnu_as=yes gnu_ld=yes
615# Check whether --with-elf or --without-elf was given.
b8dc6a10
RM
616if test "${with_elf+set}" = set; then
617 withval="$with_elf"
e215c478 618 elf=$withval
28f540f4
RM
619else
620 elf=no
621fi
622
28f540f4 623
d17e960c
RM
624# Check whether --enable-libio or --disable-libio was given.
625if test "${enable_libio+set}" = set; then
626 enableval="$enable_libio"
1ed0083c
RM
627 if test $enableval = yes; then
628 stdio=libio
629 else
630 stdio=stdio
631 fi
d17e960c 632else
91c7b85d 633 stdio=default
d17e960c
RM
634fi
635
636
424f8c09 637# Check whether --enable-shared or --disable-shared was given.
b8dc6a10
RM
638if test "${enable_shared+set}" = set; then
639 enableval="$enable_shared"
424f8c09
RM
640 shared=$enableval
641else
642 shared=default
643fi
644
645# Check whether --enable-profile or --disable-profile was given.
b8dc6a10
RM
646if test "${enable_profile+set}" = set; then
647 enableval="$enable_profile"
424f8c09
RM
648 profile=$enableval
649else
650 profile=yes
651fi
652
653# Check whether --enable-omitfp or --disable-omitfp was given.
b8dc6a10
RM
654if test "${enable_omitfp+set}" = set; then
655 enableval="$enable_omitfp"
424f8c09
RM
656 omitfp=$enableval
657else
658 omitfp=no
659fi
660
661
6b3a2224
RM
662# Check whether --enable-add-ons or --disable-add-ons was given.
663if test "${enable_add_ons+set}" = set; then
664 enableval="$enable_add_ons"
ba3f9540 665 add_ons=`echo "$enableval" | sed 's/,/ /g'`
6b3a2224 666else
ba3f9540 667 add_ons=
6b3a2224
RM
668fi
669
28f540f4
RM
670ac_aux_dir=
671for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
672 if test -f $ac_dir/install-sh; then
673 ac_aux_dir=$ac_dir
674 ac_install_sh="$ac_aux_dir/install-sh -c"
675 break
676 elif test -f $ac_dir/install.sh; then
677 ac_aux_dir=$ac_dir
678 ac_install_sh="$ac_aux_dir/install.sh -c"
679 break
680 fi
681done
682if test -z "$ac_aux_dir"; then
683 { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
684fi
a5113b14 685ac_config_mkinstalldirs=$ac_aux_dir/mkinstalldirs
28f540f4
RM
686ac_config_guess=$ac_aux_dir/config.guess
687ac_config_sub=$ac_aux_dir/config.sub
688ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
689
6b3a2224
RM
690subdirs="$add_ons"
691
692
28f540f4
RM
693
694# Make sure we can run config.sub.
695if $ac_config_sub sun4 >/dev/null 2>&1; then :
696else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
697fi
698
f55814ff 699echo $ac_n "checking host system type""... $ac_c" 1>&6
28f540f4
RM
700
701host_alias=$host
702case "$host_alias" in
703NONE)
704 case $nonopt in
705 NONE)
706 if host_alias=`$ac_config_guess`; then :
707 else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
708 fi ;;
709 *) host_alias=$nonopt ;;
710 esac ;;
711esac
712
713host=`$ac_config_sub $host_alias`
714host_cpu=`echo $host | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\1/'`
715host_vendor=`echo $host | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\2/'`
716host_os=`echo $host | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\3/'`
f55814ff 717echo "$ac_t""$host" 1>&6
28f540f4
RM
718
719# We keep the original values in `$config_*' and never modify them, so we
720# can write them unchanged into config.make. Everything else uses
721# $machine, $vendor, and $os, and changes them whenever convenient.
722config_machine=$host_cpu config_vendor=$host_vendor config_os=$host_os
723
2b83a2a4
RM
724# Some configurations imply other options.
725case "$host_os" in
726gnu* | linux* | bsd4.4* | netbsd* | freebsd*)
727 # These systems always use GNU tools.
c8cf0b14 728 gnu_ld=yes gnu_as=yes ;;
2b83a2a4
RM
729esac
730case "$host_os" in
d7126ae6
RM
731linux*ecoff*)
732 ;;
2b83a2a4 733gnu* | linux* | sysv4* | solaris2*)
d7126ae6
RM
734 # These systems (almost) always use the ELF format.
735 elf=yes
9004bc20 736 ;;
2b83a2a4
RM
737esac
738
f0523145 739machine=$config_machine
28f540f4
RM
740vendor=$config_vendor
741os=$config_os
742
743# Expand the configuration machine name into a subdirectory by architecture
744# type and particular chip.
745case "$machine" in
f0523145
RM
746a29k | am29000) base_machine=a29k machine=a29k ;;
747alpha*) base_machine=alpha machine=alpha/$machine ;;
748hppa*) base_machine=hppa machine=hppa/$machine ;;
a5113b14 749i[3456]86) base_machine=i386 machine=i386/$machine ;;
f0523145
RM
750m680?0) base_machine=m68k machine=m68k/$machine ;;
751m68k) base_machine=m68k machine=m68k/m68020 ;;
752m88???) base_machine=m88k machine=m88k/$machine ;;
753m88k) base_machine=m88k machine=m88k/m88100 ;;
754mips*) base_machine=mips machine=mips/$machine ;;
755mips64*) base_machine=mips64 machine=mips/mips64/$machine ;;
756sparc[6789]) base_machine=sparc machine=sparc/$machine ;;
757supersparc) base_machine=sparc machine=sparc/sparc8 ;;
28f540f4
RM
758esac
759
f0523145
RM
760
761# Compute the list of sysdep directories for this configuration.
f9496a7b 762# This can take a while to compute.
f0523145 763sysdep_dir=$srcdir/sysdeps
f55814ff 764echo $ac_n "checking sysdep dirs""... $ac_c" 1>&6
f9496a7b 765# Make sco3.2v4 become sco3.2.4 and sunos4.1.1_U1 become sunos4.1.1.U1.
28f540f4
RM
766os="`echo $os | sed 's/\([0-9A-Z]\)[v_]\([0-9A-Z]\)/\1.\2/g'`"
767
768case "$os" in
769gnu*)
770 base_os=mach/hurd ;;
e215c478 771netbsd* | 386bsd* | freebsd* | bsdi*)
28f540f4 772 base_os=unix/bsd/bsd4.4 ;;
222c4e71 773osf* | sunos* | ultrix* | newsos* | dynix* | *bsd*)
28f540f4 774 base_os=unix/bsd ;;
287fbbe7 775sysv* | isc* | esix* | sco* | minix* | irix4* | linux*)
28f540f4 776 base_os=unix/sysv ;;
287fbbe7 777solaris[2-9]*)
28f540f4
RM
778 base_os=unix/sysv/sysv4 ;;
779none)
780 base_os=standalone ;;
781*)
782 base_os='' ;;
783esac
784
785# For sunos4.1.1, try sunos4.1.1, then sunos4.1, then sunos4, then sunos.
786tail=$os
787ostry=$os
788while o=`echo $tail | sed 's/\.[^.]*$//'`; test $o != $tail; do
789 ostry="$ostry /$o"
790 tail=$o
75914335 791done
28f540f4
RM
792o=`echo $tail | sed 's/[0-9]*$//'`
793if test $o != $tail; then
794 ostry="$ostry /$o"
795fi
796
797# For unix/sysv/sysv4, try unix/sysv/sysv4, then unix/sysv, then unix.
798base=
799tail=$base_os
800while b=`echo $tail | sed 's@^\(.*\)/\([^/]*\)$@& \1@'`; test -n "$b"; do
801 set $b
802 base="$base /$1"
803 tail="$2"
804done
805
806# For sparc/sparc9, try sparc/sparc9 and then sparc.
807mach=
808tail=$machine
809while m=`echo $tail | sed 's@^\(.*\)/\([^/]*\)$@& \1@'`; test -n "$m"; do
810 set $m
273d56ce
RM
811 # Prepend the machine's FPU directory unless --without-fp.
812 if test "$with_fp" = yes; then
813 mach="$mach /$1/fpu"
b96bdcd7 814 fi
28f540f4
RM
815 mach="$mach /$1"
816 tail="$2"
817done
818
819
820# Find what sysdep directories exist.
821sysnames=
822for b in $base ''; do
823 for m0 in $mach ''; do
824 for v in /$vendor ''; do
825 for o in /$ostry ''; do
826 for m in $mach ''; do
827 try="$m0$b$v$o$m"
587dbc6f 828 test -n "$enable_debug_configure" && echo "$0 DEBUG: try $try" >&2
28f540f4
RM
829 if test -d $sysdep_dir$try; then
830 sysnames="$sysnames $try"
831 { test -n "$o" || test -n "$b"; } && os_used=t
832 { test -n "$m" || test -n "$m0"; } && machine_used=t
833 fi
834 done
835 done
836 done
837 done
838done
839
840if test -z "$os_used" && test "$os" != none; then
841 { echo "configure: error: Operating system $os is not supported." 1>&2; exit 1; }
842fi
843if test -z "$machine_used" && test "$machine" != none; then
844 { echo "configure: error: The $machine is not supported." 1>&2; exit 1; }
845fi
846
847# We have now validated the configuration.
848
e215c478 849
273d56ce
RM
850# If using ELF, look for an `elf' subdirectory of each machine directory.
851# We prepend these rather than inserting them whereever the machine appears
852# because things specified by the machine's ELF ABI should override
853# OS-specific things, and should always be the same for any OS on the
854# machine (otherwise what's the point of an ABI?).
855if test "$elf" = yes; then
856 elf_dirs=
28f540f4 857 for m in $mach; do
273d56ce
RM
858 if test -d $sysdep_dir$m/elf; then
859 elf_dirs="$elf_dirs $m/elf"
28f540f4
RM
860 fi
861 done
273d56ce 862 sysnames="`echo $elf_dirs | sed -e 's,^/,,' -e 's, /,,g'` $sysnames"
28f540f4
RM
863fi
864
e215c478 865
273d56ce
RM
866# Remove the leading slashes.
867sysnames="`echo $sysnames | sed -e 's@^/@@' -e 's@ /@ @g'`"
868
e215c478 869
28f540f4
RM
870# Expand the list of system names into a full list of directories
871# from each element's parent name and Implies file (if present).
872set $sysnames
959c3674 873names=
28f540f4
RM
874while test $# -gt 0; do
875 name=$1
876 shift
877
959c3674 878 case " $names " in *" $name "*)
f9496a7b
RM
879 # Already in the list.
880 continue
959c3674 881 esac
f9496a7b
RM
882
883 # Report each name as we discover it, so there is no long pause in output.
884 echo $ac_n "$name $ac_c" >&6
885
28f540f4
RM
886 if test -f $sysdep_dir/$name/Implies; then
887 # Collect more names from the `Implies' file (removing comments).
888 implied="`sed 's/#.*$//' < $sysdep_dir/$name/Implies`"
889 for x in $implied; do
f9496a7b
RM
890 test -d $sysdep_dir/$x || {
891 echo "configure: warning: sysdeps/$name/Implies specifies nonexistent $x" 1>&2
892 }
28f540f4
RM
893 done
894 else
895 implied=
896 fi
897
898 # Add NAME to the list of names.
899 names="$names $name"
900
901 # Find the parent of NAME, using the empty string if it has none.
902 parent="`echo $name | sed -n -e '/\//!q' -e 's=/[^/]*$==p'`"
903
904 # Add the names implied by NAME, and NAME's parent (if it has one), to
905 # the list of names to be processed (the argument list). We prepend the
906 # implied names to the list and append the parent. We want implied
907 # directories to come before further directories inferred from the
908 # configuration components; this ensures that for sysv4, unix/common
909 # (implied by unix/sysv/sysv4) comes before unix/sysv (in ostry (here $*)
910 # after sysv4).
911 sysnames="`echo $implied $* $parent`"
912 test -n "$sysnames" && set $sysnames
913done
914
915# Add the default directories.
f9496a7b
RM
916sysnames="$names generic stub"
917
918# The other names were emitted during the scan.
919echo "$ac_t""generic stub" 1>&6
28f540f4 920
28f540f4 921
f9496a7b 922### Locate tools.
28f540f4 923
28f540f4
RM
924# Find a good install program. We prefer a C program (faster),
925# so one script is as good as another. But avoid the broken or
926# incompatible versions:
927# SysV /etc/install, /usr/sbin/install
928# SunOS /usr/etc/install
929# IRIX /sbin/install
930# AIX /bin/install
931# AFS /usr/afsws/bin/install, which mishandles nonexistent args
932# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
933# ./install, which can be erroneously created by make from ./install.sh.
f55814ff 934echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
28f540f4 935if test -z "$INSTALL"; then
424f8c09 936if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
f55814ff 937 echo $ac_n "(cached) $ac_c" 1>&6
28f540f4
RM
938else
939 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
940 for ac_dir in $PATH; do
941 # Account for people who put trailing slashes in PATH elements.
942 case "$ac_dir/" in
943 /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
944 *)
945 # OSF1 and SCO ODT 3.0 have their own names for install.
946 for ac_prog in ginstall installbsd scoinst install; do
947 if test -f $ac_dir/$ac_prog; then
948 if test $ac_prog = install &&
949 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
950 # AIX install. It has an incompatible calling convention.
951 # OSF/1 installbsd also uses dspmsg, but is usable.
952 :
953 else
954 ac_cv_path_install="$ac_dir/$ac_prog -c"
955 break 2
956 fi
957 fi
958 done
959 ;;
960 esac
961 done
962 IFS="$ac_save_ifs"
b8dc6a10 963
28f540f4 964fi
b8dc6a10
RM
965 if test "${ac_cv_path_install+set}" = set; then
966 INSTALL="$ac_cv_path_install"
967 else
968 # As a last resort, use the slow shell script. We don't cache a
969 # path for INSTALL within a source directory, because that will
970 # break other packages using the cache if that directory is
971 # removed, or if the path is relative.
972 INSTALL="$ac_install_sh"
973 fi
28f540f4 974fi
f55814ff 975echo "$ac_t""$INSTALL" 1>&6
28f540f4 976
a5113b14
UD
977# The purpose of this command is only to make sure the auxiliary path
978# is set and that the symbol AC_REQUIRE_AC_PROG_MKINSTALLDIRS is set.
979
980
28f540f4
RM
981# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
982# It thinks the first close brace ends the variable substitution.
983test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
984
985test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
986
987if test "$INSTALL" = "${srcdir}/install-sh"; then
988 # The makefiles need to use a different form to find it in $srcdir.
989 INSTALL='$(..)./install-sh'
990fi
f55814ff 991echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
ad41463d 992if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
f55814ff 993 echo $ac_n "(cached) $ac_c" 1>&6
ad41463d
RM
994else
995 rm -f conftestdata
996if ln -s X conftestdata 2>/dev/null
997then
998 rm -f conftestdata
999 ac_cv_prog_LN_S="ln -s"
1000else
1001 ac_cv_prog_LN_S=ln
1002fi
1003fi
1004LN_S="$ac_cv_prog_LN_S"
1005if test "$ac_cv_prog_LN_S" = "ln -s"; then
f55814ff 1006 echo "$ac_t""yes" 1>&6
ad41463d 1007else
f55814ff 1008 echo "$ac_t""no" 1>&6
ad41463d
RM
1009fi
1010
ce4d8b66
RM
1011for ac_prog in msgfmt gmsgfmt
1012do
1013# Extract the first word of "$ac_prog", so it can be a program name with args.
1014set dummy $ac_prog; ac_word=$2
f55814ff 1015echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
ce4d8b66 1016if eval "test \"`echo '$''{'ac_cv_prog_MSGFMT'+set}'`\" = set"; then
f55814ff 1017 echo $ac_n "(cached) $ac_c" 1>&6
ce4d8b66
RM
1018else
1019 if test -n "$MSGFMT"; then
1020 ac_cv_prog_MSGFMT="$MSGFMT" # Let the user override the test.
1021else
1022 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1023 for ac_dir in $PATH; do
1024 test -z "$ac_dir" && ac_dir=.
1025 if test -f $ac_dir/$ac_word; then
1026 ac_cv_prog_MSGFMT="$ac_prog"
1027 break
1028 fi
1029 done
1030 IFS="$ac_save_ifs"
1031fi
1032fi
1033MSGFMT="$ac_cv_prog_MSGFMT"
1034if test -n "$MSGFMT"; then
f55814ff 1035 echo "$ac_t""$MSGFMT" 1>&6
ce4d8b66 1036else
f55814ff 1037 echo "$ac_t""no" 1>&6
ce4d8b66
RM
1038fi
1039
1040test -n "$MSGFMT" && break
1041done
f0523145 1042test -n "$MSGFMT" || MSGFMT=":"
ce4d8b66 1043
28f540f4 1044
f55814ff 1045echo $ac_n "checking build system type""... $ac_c" 1>&6
28f540f4
RM
1046
1047build_alias=$build
1048case "$build_alias" in
1049NONE)
1050 case $nonopt in
1051 NONE) build_alias=$host_alias ;;
1052 *) build_alias=$nonopt ;;
1053 esac ;;
1054esac
1055
1056build=`$ac_config_sub $build_alias`
1057build_cpu=`echo $build | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\1/'`
1058build_vendor=`echo $build | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\2/'`
1059build_os=`echo $build | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\3/'`
f55814ff 1060echo "$ac_t""$build" 1>&6
28f540f4
RM
1061
1062if test $host != $build; then
1063 ac_tool_prefix=${host_alias}-
1064else
1065 ac_tool_prefix=
1066fi
1067
1068# Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
1069set dummy ${ac_tool_prefix}gcc; ac_word=$2
f55814ff 1070echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
424f8c09 1071if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
f55814ff 1072 echo $ac_n "(cached) $ac_c" 1>&6
28f540f4
RM
1073else
1074 if test -n "$CC"; then
1075 ac_cv_prog_CC="$CC" # Let the user override the test.
1076else
1077 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
3bbceb12 1078 for ac_dir in $PATH; do
28f540f4
RM
1079 test -z "$ac_dir" && ac_dir=.
1080 if test -f $ac_dir/$ac_word; then
1081 ac_cv_prog_CC="${ac_tool_prefix}gcc"
1082 break
1083 fi
1084 done
1085 IFS="$ac_save_ifs"
1086 test -z "$ac_cv_prog_CC" && ac_cv_prog_CC="gcc"
1087fi
1088fi
1089CC="$ac_cv_prog_CC"
1090if test -n "$CC"; then
f55814ff 1091 echo "$ac_t""$CC" 1>&6
28f540f4 1092else
f55814ff 1093 echo "$ac_t""no" 1>&6
28f540f4
RM
1094fi
1095
1096
1097
7f811679 1098if test $host != $build; then
40a4b79f
RM
1099 # Extract the first word of "gcc cc", so it can be a program name with args.
1100set dummy gcc cc; ac_word=$2
1101echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1102if eval "test \"`echo '$''{'ac_cv_prog_BUILD_CC'+set}'`\" = set"; then
1103 echo $ac_n "(cached) $ac_c" 1>&6
1104else
1105 if test -n "$BUILD_CC"; then
1106 ac_cv_prog_BUILD_CC="$BUILD_CC" # Let the user override the test.
1107else
1108 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1109 for ac_dir in $PATH; do
1110 test -z "$ac_dir" && ac_dir=.
1111 if test -f $ac_dir/$ac_word; then
1112 ac_cv_prog_BUILD_CC=""
1113 break
1114 fi
1115 done
1116 IFS="$ac_save_ifs"
1117fi
1118fi
1119BUILD_CC="$ac_cv_prog_BUILD_CC"
1120if test -n "$BUILD_CC"; then
1121 echo "$ac_t""$BUILD_CC" 1>&6
1122else
1123 echo "$ac_t""no" 1>&6
1124fi
1125
1126fi
f55814ff 1127echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
8942a07a
RM
1128# On Suns, sometimes $CPP names a directory.
1129if test -n "$CPP" && test -d "$CPP"; then
1130 CPP=
1131fi
1132if test -z "$CPP"; then
1133if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
f55814ff 1134 echo $ac_n "(cached) $ac_c" 1>&6
8942a07a
RM
1135else
1136 # This must be in double quotes, not single quotes, because CPP may get
1137 # substituted into the Makefile and "${CC-cc}" will confuse make.
1138 CPP="${CC-cc} -E"
1139 # On the NeXT, cc -E runs the code through the compiler's parser,
1140 # not just through cpp.
1141 cat > conftest.$ac_ext <<EOF
a5113b14 1142#line 1143 "configure"
8942a07a
RM
1143#include "confdefs.h"
1144#include <assert.h>
1145Syntax Error
1146EOF
1147ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
a5113b14 1148{ (eval echo configure:1149: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
8942a07a
RM
1149ac_err=`grep -v '^ *+' conftest.out`
1150if test -z "$ac_err"; then
1151 :
1152else
1153 echo "$ac_err" >&5
1154 rm -rf conftest*
1155 CPP="${CC-cc} -E -traditional-cpp"
1156 cat > conftest.$ac_ext <<EOF
a5113b14 1157#line 1158 "configure"
8942a07a
RM
1158#include "confdefs.h"
1159#include <assert.h>
1160Syntax Error
1161EOF
1162ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
a5113b14 1163{ (eval echo configure:1164: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
8942a07a
RM
1164ac_err=`grep -v '^ *+' conftest.out`
1165if test -z "$ac_err"; then
1166 :
1167else
1168 echo "$ac_err" >&5
1169 rm -rf conftest*
1170 CPP=/lib/cpp
1171fi
1172rm -f conftest*
1173fi
1174rm -f conftest*
1175 ac_cv_prog_CPP="$CPP"
1176fi
1177 CPP="$ac_cv_prog_CPP"
1178else
1179 ac_cv_prog_CPP="$CPP"
1180fi
f55814ff 1181echo "$ac_t""$CPP" 1>&6
8942a07a 1182
28f540f4
RM
1183# Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
1184set dummy ${ac_tool_prefix}ar; ac_word=$2
f55814ff 1185echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
424f8c09 1186if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
f55814ff 1187 echo $ac_n "(cached) $ac_c" 1>&6
28f540f4
RM
1188else
1189 if test -n "$AR"; then
1190 ac_cv_prog_AR="$AR" # Let the user override the test.
1191else
1192 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
3bbceb12 1193 for ac_dir in $PATH; do
28f540f4
RM
1194 test -z "$ac_dir" && ac_dir=.
1195 if test -f $ac_dir/$ac_word; then
1196 ac_cv_prog_AR="${ac_tool_prefix}ar"
1197 break
1198 fi
1199 done
1200 IFS="$ac_save_ifs"
1201 test -z "$ac_cv_prog_AR" && ac_cv_prog_AR="ar"
1202fi
1203fi
1204AR="$ac_cv_prog_AR"
1205if test -n "$AR"; then
f55814ff 1206 echo "$ac_t""$AR" 1>&6
28f540f4 1207else
f55814ff 1208 echo "$ac_t""no" 1>&6
28f540f4
RM
1209fi
1210
1211
1212
1213# Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
1214set dummy ${ac_tool_prefix}ranlib; ac_word=$2
f55814ff 1215echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
424f8c09 1216if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
f55814ff 1217 echo $ac_n "(cached) $ac_c" 1>&6
28f540f4
RM
1218else
1219 if test -n "$RANLIB"; then
1220 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
1221else
1222 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1223 for ac_dir in $PATH; do
1224 test -z "$ac_dir" && ac_dir=.
1225 if test -f $ac_dir/$ac_word; then
1226 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
1227 break
1228 fi
1229 done
1230 IFS="$ac_save_ifs"
1231fi
1232fi
1233RANLIB="$ac_cv_prog_RANLIB"
1234if test -n "$RANLIB"; then
f55814ff 1235 echo "$ac_t""$RANLIB" 1>&6
28f540f4 1236else
f55814ff 1237 echo "$ac_t""no" 1>&6
28f540f4
RM
1238fi
1239
1240
1241if test -z "$ac_cv_prog_RANLIB"; then
1242if test -n "$ac_tool_prefix"; then
1243 # Extract the first word of "ranlib", so it can be a program name with args.
1244set dummy ranlib; ac_word=$2
f55814ff 1245echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
424f8c09 1246if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
f55814ff 1247 echo $ac_n "(cached) $ac_c" 1>&6
28f540f4
RM
1248else
1249 if test -n "$RANLIB"; then
1250 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
1251else
1252 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
3bbceb12 1253 for ac_dir in $PATH; do
28f540f4
RM
1254 test -z "$ac_dir" && ac_dir=.
1255 if test -f $ac_dir/$ac_word; then
1256 ac_cv_prog_RANLIB="ranlib"
1257 break
1258 fi
1259 done
1260 IFS="$ac_save_ifs"
1261 test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
1262fi
1263fi
1264RANLIB="$ac_cv_prog_RANLIB"
1265if test -n "$RANLIB"; then
f55814ff 1266 echo "$ac_t""$RANLIB" 1>&6
28f540f4 1267else
f55814ff 1268 echo "$ac_t""no" 1>&6
28f540f4
RM
1269fi
1270
1271else
1272 RANLIB=":"
1273fi
1274fi
1275
28f540f4 1276
f55814ff 1277echo $ac_n "checking for signed size_t type""... $ac_c" 1>&6
424f8c09 1278if eval "test \"`echo '$''{'libc_cv_signed_size_t'+set}'`\" = set"; then
f55814ff 1279 echo $ac_n "(cached) $ac_c" 1>&6
28f540f4
RM
1280else
1281 echo '#include <stddef.h>
1282FOOBAR __SIZE_TYPE__ FOOBAR' > conftest.c
1283if eval "$ac_cpp conftest.c 2>/dev/null" \
1284| grep '^FOOBAR.*unsigned.*FOOBAR$' >/dev/null; then
1285 libc_cv_signed_size_t=no
1286else
1287 libc_cv_signed_size_t=yes
1288fi
1289rm -f conftest*
1290fi
1291
f55814ff 1292echo "$ac_t""$libc_cv_signed_size_t" 1>&6
28f540f4
RM
1293if test $libc_cv_signed_size_t = yes; then
1294 cat >> confdefs.h <<\EOF
1295#undef __SIZE_TYPE__
1296#define __SIZE_TYPE__ unsigned
1297EOF
1298fi
1299
f55814ff 1300echo $ac_n "checking for libc-friendly stddef.h""... $ac_c" 1>&6
424f8c09 1301if eval "test \"`echo '$''{'libc_cv_friendly_stddef'+set}'`\" = set"; then
f55814ff 1302 echo $ac_n "(cached) $ac_c" 1>&6
28f540f4
RM
1303else
1304 cat > conftest.$ac_ext <<EOF
a5113b14 1305#line 1306 "configure"
28f540f4
RM
1306#include "confdefs.h"
1307#define __need_size_t
1308#define __need_wchar_t
1309#include <stddef.h>
1310#define __need_NULL
1311#include <stddef.h>
1312int main() { return 0; }
1313int t() {
1314size_t size; wchar_t wchar;
1315#ifdef offsetof
1316#error stddef.h ignored __need_*
1317#endif
1318if (&size == NULL || &wchar == NULL) abort ();
1319; return 0; }
1320EOF
a5113b14 1321if { (eval echo configure:1322: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
28f540f4
RM
1322 rm -rf conftest*
1323 libc_cv_friendly_stddef=yes
1324else
1325 rm -rf conftest*
1326 libc_cv_friendly_stddef=no
1327fi
1328rm -f conftest*
1329
1330fi
1331
f55814ff 1332echo "$ac_t""$libc_cv_friendly_stddef" 1>&6
28f540f4
RM
1333if test $libc_cv_friendly_stddef = yes; then
1334 config_vars="$config_vars
1335override stddef.h = # The installed <stddef.h> seems to be libc-friendly."
1336fi
1337
f55814ff 1338echo $ac_n "checking whether we need to use -P to assemble .S files""... $ac_c" 1>&6
424f8c09 1339if eval "test \"`echo '$''{'libc_cv_need_minus_P'+set}'`\" = set"; then
f55814ff 1340 echo $ac_n "(cached) $ac_c" 1>&6
28f540f4
RM
1341else
1342 cat > conftest.S <<EOF
1343#include "confdefs.h"
1344/* Nothing whatsoever. */
1345EOF
1346if ${CC-cc} $CFLAGS -c conftest.S 2>/dev/null; then
1347 libc_cv_need_minus_P=no
1348else
1349 libc_cv_need_minus_P=yes
1350fi
1351rm -f conftest*
1352fi
1353
f55814ff 1354echo "$ac_t""$libc_cv_need_minus_P" 1>&6
28f540f4
RM
1355if test $libc_cv_need_minus_P = yes; then
1356 config_vars="$config_vars
1357asm-CPPFLAGS = -P # The assembler can't grok cpp's # line directives."
1358fi
1359
f55814ff 1360echo $ac_n "checking for assembler global-symbol directive""... $ac_c" 1>&6
587dbc6f 1361if eval "test \"`echo '$''{'libc_cv_asm_global_directive'+set}'`\" = set"; then
f55814ff 1362 echo $ac_n "(cached) $ac_c" 1>&6
587dbc6f
RM
1363else
1364 libc_cv_asm_global_directive=UNKNOWN
1365for ac_globl in .globl .global; do
1366 cat > conftest.s <<EOF
1367.text
1368${ac_globl} foo
1369foo: .long 0
1370EOF
1371 if ${CC-cc} $CFLAGS -c conftest.s 2>/dev/null; then
1372 libc_cv_asm_global_directive=${ac_globl}
1373 fi
1374 rm -f conftest*
1375 test $libc_cv_asm_global_directive != UNKNOWN && break
1376done
1377fi
1378
f55814ff 1379echo "$ac_t""$libc_cv_asm_global_directive" 1>&6
587dbc6f
RM
1380if test $libc_cv_asm_global_directive = UNKNOWN; then
1381 { echo "configure: error: cannot determine asm global directive" 1>&2; exit 1; }
1382else
1383 cat >> confdefs.h <<EOF
1384#define ASM_GLOBAL_DIRECTIVE ${libc_cv_asm_global_directive}
1385EOF
1386
1387fi
1388
f55814ff 1389echo $ac_n "checking for .set assembler directive""... $ac_c" 1>&6
e215c478 1390if eval "test \"`echo '$''{'libc_cv_asm_set_directive'+set}'`\" = set"; then
f55814ff 1391 echo $ac_n "(cached) $ac_c" 1>&6
e215c478 1392else
587dbc6f 1393 cat > conftest.s <<EOF
e215c478
RM
1394.text
1395foo: .long 0
df2a0c93 1396.set glibc_conftest_frobozz,foo
587dbc6f 1397$libc_cv_asm_global_directive glibc_conftest_frobozz
e215c478 1398EOF
df2a0c93
RM
1399# The alpha-dec-osf1 assembler gives only a warning for `.set'
1400# (but it doesn't work), so we must do a linking check to be sure.
1401cat > conftest1.c <<\EOF
1402extern int glibc_conftest_frobozz;
1403main () { printf ("%d\n", glibc_conftest_frobozz); }
1404EOF
1405if ${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS \
b3a59f40 1406 -o conftest conftest.s conftest1.c 1>&5 2>&5; then
e215c478
RM
1407 libc_cv_asm_set_directive=yes
1408else
1409 libc_cv_asm_set_directive=no
1410fi
d02907df 1411rm -f conftest*
e215c478
RM
1412fi
1413
f55814ff 1414echo "$ac_t""$libc_cv_asm_set_directive" 1>&6
e215c478
RM
1415if test $libc_cv_asm_set_directive = yes; then
1416 cat >> confdefs.h <<\EOF
1417#define HAVE_ASM_SET_DIRECTIVE 1
1418EOF
1419
1420fi
1421
b8dc6a10 1422if test $elf != yes; then
f55814ff 1423 echo $ac_n "checking for .init and .fini sections""... $ac_c" 1>&6
b8dc6a10 1424if eval "test \"`echo '$''{'libc_cv_have_initfini'+set}'`\" = set"; then
f55814ff 1425 echo $ac_n "(cached) $ac_c" 1>&6
b8dc6a10
RM
1426else
1427 cat > conftest.$ac_ext <<EOF
a5113b14 1428#line 1429 "configure"
b8dc6a10
RM
1429#include "confdefs.h"
1430
1431int main() { return 0; }
1432int t() {
1433asm (".section .init");
1434 asm (".section .fini");
9004bc20 1435 asm (".text");
b8dc6a10
RM
1436; return 0; }
1437EOF
a5113b14 1438if { (eval echo configure:1439: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
b8dc6a10
RM
1439 rm -rf conftest*
1440 libc_cv_have_initfini=yes
1441else
1442 rm -rf conftest*
1443 libc_cv_have_initfini=no
1444fi
1445rm -f conftest*
1446
1447fi
1448
f55814ff 1449echo "$ac_t""$libc_cv_have_initfini" 1>&6
b8dc6a10
RM
1450 if test $libc_cv_have_initfini = yes; then
1451 cat >> confdefs.h <<\EOF
1452#define HAVE_INITFINI 1
1453EOF
1454
1455 fi
1456fi
e215c478 1457
c224a18a
RM
1458if test $elf = yes; then
1459 libc_cv_asm_underscores=no
1460else
f55814ff 1461 echo $ac_n "checking for _ prefix on C symbol names""... $ac_c" 1>&6
c224a18a 1462if eval "test \"`echo '$''{'libc_cv_asm_underscores'+set}'`\" = set"; then
f55814ff 1463 echo $ac_n "(cached) $ac_c" 1>&6
c224a18a
RM
1464else
1465 cat > conftest.$ac_ext <<EOF
a5113b14 1466#line 1467 "configure"
c224a18a
RM
1467#include "confdefs.h"
1468asm ("_glibc_foobar:");
1469int main() { return 0; }
1470int t() {
1471glibc_foobar ();
1472; return 0; }
1473EOF
a5113b14 1474if { (eval echo configure:1475: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
c224a18a
RM
1475 rm -rf conftest*
1476 libc_cv_asm_underscores=yes
1477else
1478 rm -rf conftest*
1479 libc_cv_asm_underscores=no
1480fi
1481rm -f conftest*
1482
1483fi
1484
f55814ff 1485echo "$ac_t""$libc_cv_asm_underscores" 1>&6
c224a18a
RM
1486fi
1487if test $libc_cv_asm_underscores = no; then
1488 cat >> confdefs.h <<\EOF
1489#define NO_UNDERSCORES 1
1490EOF
1491
1492fi
1493
1494if test $elf = yes; then
1495 libc_cv_weak_symbols=yes
1496 libc_cv_asm_weak_directive=yes
1497 libc_cv_asm_weakext_directive=no
1498else
f55814ff 1499 echo $ac_n "checking for assembler .weak directive""... $ac_c" 1>&6
c224a18a 1500if eval "test \"`echo '$''{'libc_cv_asm_weak_directive'+set}'`\" = set"; then
f55814ff 1501 echo $ac_n "(cached) $ac_c" 1>&6
c224a18a
RM
1502else
1503 cat > conftest.s <<EOF
1504.text
1505${libc_cv_asm_global_directive} foo
1506foo: .long 0
1507.weak foo
1508.weak bar; bar = foo
1509EOF
1510 if ${CC-cc} $CFLAGS -c conftest.s 2>/dev/null; then
1511 libc_cv_asm_weak_directive=yes
1512 else
1513 libc_cv_asm_weak_directive=no
1514 fi
1515 rm -f conftest*
1516fi
1517
f55814ff 1518echo "$ac_t""$libc_cv_asm_weak_directive" 1>&6
c224a18a 1519
c8cf0b14 1520if test $libc_cv_asm_weak_directive = no; then
f55814ff 1521 echo $ac_n "checking for assembler .weakext directive""... $ac_c" 1>&6
c224a18a 1522if eval "test \"`echo '$''{'libc_cv_asm_weakext_directive'+set}'`\" = set"; then
f55814ff 1523 echo $ac_n "(cached) $ac_c" 1>&6
c224a18a
RM
1524else
1525 cat > conftest.s <<EOF
1526.text
1527${libc_cv_asm_global_directive} foo
1528foo: .long 0
1529.weakext foo
a1470b6f 1530.weakext foo, bar
c224a18a
RM
1531EOF
1532 if ${CC-cc} $CFLAGS -c conftest.s 2>/dev/null; then
1533 libc_cv_asm_weakext_directive=yes
1534 else
1535 libc_cv_asm_weakext_directive=no
1536 fi
1537 rm -f conftest*
1538fi
1539
f55814ff 1540echo "$ac_t""$libc_cv_asm_weakext_directive" 1>&6
c224a18a
RM
1541
1542 fi # no .weak
1543fi # not ELF
1544
ffcf9634 1545if test $libc_cv_asm_weak_directive = yes; then
c224a18a
RM
1546 cat >> confdefs.h <<\EOF
1547#define HAVE_ASM_WEAK_DIRECTIVE 1
1548EOF
1549
ffcf9634 1550elif test $libc_cv_asm_weakext_directive = yes; then
c224a18a
RM
1551 cat >> confdefs.h <<\EOF
1552#define HAVE_ASM_WEAKEXT_DIRECTIVE 1
1553EOF
1554
1555fi
1556
f55814ff 1557echo $ac_n "checking for ld --no-whole-archive""... $ac_c" 1>&6
ad41463d 1558if eval "test \"`echo '$''{'libc_cv_ld_no_whole_archive'+set}'`\" = set"; then
f55814ff 1559 echo $ac_n "(cached) $ac_c" 1>&6
ad41463d
RM
1560else
1561 cat > conftest.c <<\EOF
5f0e6fc7 1562_start () {}
ad41463d 1563EOF
dcea62dd
RM
1564if { ac_try='${CC-cc} $CFLAGS
1565 -nostdlib -nostartfiles -Wl,--no-whole-archive
a5113b14 1566 -o conftest conftest.c'; { (eval echo configure:1567: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
ad41463d
RM
1567 libc_cv_ld_no_whole_archive=yes
1568else
1569 libc_cv_ld_no_whole_archive=no
1570fi
1571rm -f conftest*
1572fi
1573
f55814ff 1574echo "$ac_t""$libc_cv_ld_no_whole_archive" 1>&6
ad41463d 1575
c224a18a
RM
1576### End of automated tests.
1577### Now run sysdeps configure fragments.
1578
28f540f4
RM
1579# sysdeps configure fragments may set these with files to be linked below.
1580libc_link_dests=
1581libc_link_sources=
1582
1583# Iterate over all the sysdep directories we will use, running their
1584# configure fragments, and looking for a uname implementation.
1585uname=
1586for dir in $sysnames; do
1587 if test -r $sysdep_dir/$dir/configure; then
f55814ff 1588 echo "$ac_t""running configure fragment for $dir" 1>&6
28f540f4
RM
1589 . $sysdep_dir/$dir/configure
1590 fi
c6de6968 1591
28f540f4 1592 if test -z "$uname"; then
c6de6968
RM
1593 if test -r $sysdep_dir/$dir/uname.c ||
1594 test -r $sysdep_dir/$dir/uname.S ||
1595 { test -r $sysdep_dir/$dir/syscalls.list &&
1596 grep '^uname[ ]' $sysdep_dir/$dir/syscalls.list >/dev/null; }; then
1597 uname=$dir
1598 fi
28f540f4
RM
1599 fi
1600done
1601
1602
1603
1604# If we will use the generic uname implementation, we must figure out what
1605# it will say by examining the system, and write the results in config-name.h.
1606if test "$uname" = generic; then
1607
1608 uname_sysname=`echo $config_os | sed 's/[0-9.]*$//'`
1609 if test $uname_sysname != $config_os; then
1610 config_release=`echo $config_os | sed s/$uname_sysname//`
1611 fi
1612
f55814ff 1613 echo $ac_n "checking OS release for uname""... $ac_c" 1>&6
b8dc6a10 1614if eval "test \"`echo '$''{'libc_cv_uname_release'+set}'`\" = set"; then
f55814ff 1615 echo $ac_n "(cached) $ac_c" 1>&6
28f540f4
RM
1616else
1617 kernel_release=`echo "$kernel_id" | sed 's/^[^0-9.]*\([0-9.]*\).*$/\1/'`
1618 if test x`echo "$config_release" | sed "s/^$kernel_release//"` \
1619 != x$config_release; then
1620 # The configuration release is a substring of the kernel release.
1621 libc_cv_uname_release=$kernel_release
1622 elif test x$config_release != x; then
1623 libc_cv_uname_release=$config_release
1624 elif test x$kernel_release != x; then
1625 libc_cv_uname_release=$kernel_release
1626 else
1627 libc_cv_uname_release=unknown
1628 fi
1629fi
1630
f55814ff 1631echo "$ac_t""$libc_cv_uname_release" 1>&6
28f540f4
RM
1632 uname_release="$libc_cv_uname_release"
1633
f55814ff 1634 echo $ac_n "checking OS version for uname""... $ac_c" 1>&6
b8dc6a10 1635if eval "test \"`echo '$''{'libc_cv_uname_version'+set}'`\" = set"; then
f55814ff 1636 echo $ac_n "(cached) $ac_c" 1>&6
28f540f4
RM
1637else
1638 kernel_version=`echo "$kernel_id" | sed 's/^[^#]*#\([0-9]*\).*$/\1/'`
1639 if test -n "$kernel_version"; then
1640 libc_cv_uname_version="$kernel_version"
1641 else
1642 libc_cv_uname_version=unknown
1643 fi
1644fi
1645
f55814ff 1646echo "$ac_t""$libc_cv_uname_version" 1>&6
28f540f4
RM
1647 uname_version="$libc_cv_uname_version"
1648
1649 config_uname=config-name.h:config-name.in
1650else
1651 # For non-generic uname, we don't need to create config-name.h at all.
1652 config_uname=
1653fi
1654
f55814ff 1655echo $ac_n "checking stdio selection""... $ac_c" 1>&6
91c7b85d
RM
1656
1657case $stdio in
1658libio) cat >> confdefs.h <<\EOF
1659#define USE_IN_LIBIO 1
1660EOF
1661 ;;
1662default) stdio=stdio ;;
1663esac
f55814ff 1664echo "$ac_t""$stdio" 1>&6
91c7b85d 1665
c224a18a 1666
28f540f4
RM
1667if test $gnu_ld = yes; then
1668 cat >> confdefs.h <<\EOF
1669#define HAVE_GNU_LD 1
1670EOF
1671
1672fi
1673if test $gnu_as = yes; then
1674 cat >> confdefs.h <<\EOF
1675#define HAVE_GNU_AS 1
1676EOF
1677
1678fi
1679if test $elf = yes; then
1680 cat >> confdefs.h <<\EOF
1681#define HAVE_ELF 1
1682EOF
1683
28f540f4
RM
1684fi
1685
1686
424f8c09
RM
1687if test $shared = default; then
1688 if test $gnu_ld = yes; then
1689 shared=$elf
1690 fi
1691fi
1692
1693
1694
28f540f4
RM
1695if test "`(cd $srcdir; pwd)`" = "`pwd`"; then
1696 config_makefile=
1697else
1698 config_makefile=Makefile
1699fi
1700
1701trap '' 1 2 15
424f8c09 1702cat > confcache <<\EOF
28f540f4
RM
1703# This file is a shell script that caches the results of configure
1704# tests run on this system so they can be shared between configure
1705# scripts and configure runs. It is not useful on other systems.
1706# If it contains results you don't want to keep, you may remove or edit it.
1707#
1708# By default, configure uses ./config.cache as the cache file,
1709# creating it if it does not exist already. You can give configure
1710# the --cache-file=FILE option to use a different cache file; that is
1711# what configure does when it calls configure scripts in
1712# subdirectories, so they share the cache.
1713# Giving --cache-file=/dev/null disables caching, for debugging configure.
1714# config.status only pays attention to the cache file if you give it the
1715# --recheck option to rerun configure.
1716#
1717EOF
1718# Ultrix sh set writes to stderr and can't be redirected directly,
1719# and sets the high bit in the cache file unless we assign to the vars.
1720(set) 2>&1 |
1721 sed -n "s/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=\${\1='\2'}/p" \
424f8c09
RM
1722 >> confcache
1723if cmp -s $cache_file confcache; then
1724 :
28f540f4 1725else
424f8c09
RM
1726 if test -w $cache_file; then
1727 echo "updating cache $cache_file"
1728 cat confcache > $cache_file
1729 else
1730 echo "not updating unwritable cache $cache_file"
1731 fi
28f540f4 1732fi
424f8c09 1733rm -f confcache
28f540f4
RM
1734
1735trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
1736
1737test "x$prefix" = xNONE && prefix=$ac_default_prefix
1738# Let make expand exec_prefix.
1739test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
1740
1741# Any assignment to VPATH causes Sun make to only execute
1742# the first set of double-colon rules, so remove it if not needed.
1743# If there is a colon in the path, we need to keep it.
1744if test "x$srcdir" = x.; then
1745 ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
1746fi
1747
1748trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
1749
1750DEFS=-DHAVE_CONFIG_H
1751
1752# Without the "./", some shells look in PATH for config.status.
1753: ${CONFIG_STATUS=./config.status}
1754
1755echo creating $CONFIG_STATUS
1756rm -f $CONFIG_STATUS
1757cat > $CONFIG_STATUS <<EOF
1758#! /bin/sh
1759# Generated automatically by configure.
1760# Run this file to recreate the current configuration.
1761# This directory was configured as follows,
1762# on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
1763#
1764# $0 $ac_configure_args
1765#
1766# Compiler output produced by configure, useful for debugging
1767# configure, is in ./config.log if it exists.
1768
1769ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
1770for ac_option
1771do
1772 case "\$ac_option" in
1773 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
1774 echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
1775 exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
1776 -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
a5113b14 1777 echo "$CONFIG_STATUS generated by autoconf version 2.99"
28f540f4
RM
1778 exit 0 ;;
1779 -help | --help | --hel | --he | --h)
1780 echo "\$ac_cs_usage"; exit 0 ;;
1781 *) echo "\$ac_cs_usage"; exit 1 ;;
1782 esac
1783done
1784
1785ac_given_srcdir=$srcdir
1786ac_given_INSTALL="$INSTALL"
1787
e215c478 1788trap 'rm -fr `echo "config.make ${config_makefile} ${config_uname} config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
1ed0083c
RM
1789EOF
1790cat >> $CONFIG_STATUS <<EOF
28f540f4 1791
91c7b85d 1792# Protect against being on the right side of a sed subst in config.status.
1ed0083c
RM
1793sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
1794 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
28f540f4
RM
1795$ac_vpsub
1796$extrasub
1797s%@CFLAGS@%$CFLAGS%g
1798s%@CPPFLAGS@%$CPPFLAGS%g
1799s%@CXXFLAGS@%$CXXFLAGS%g
1800s%@DEFS@%$DEFS%g
1801s%@LDFLAGS@%$LDFLAGS%g
1802s%@LIBS@%$LIBS%g
1803s%@exec_prefix@%$exec_prefix%g
1804s%@prefix@%$prefix%g
1805s%@program_transform_name@%$program_transform_name%g
b8dc6a10
RM
1806s%@bindir@%$bindir%g
1807s%@sbindir@%$sbindir%g
1808s%@libexecdir@%$libexecdir%g
1809s%@datadir@%$datadir%g
1810s%@sysconfdir@%$sysconfdir%g
1811s%@sharedstatedir@%$sharedstatedir%g
1812s%@localstatedir@%$localstatedir%g
1813s%@libdir@%$libdir%g
1814s%@includedir@%$includedir%g
1815s%@oldincludedir@%$oldincludedir%g
1816s%@infodir@%$infodir%g
1817s%@mandir@%$mandir%g
6b3a2224 1818s%@subdirs@%$subdirs%g
28f540f4
RM
1819s%@host@%$host%g
1820s%@host_alias@%$host_alias%g
1821s%@host_cpu@%$host_cpu%g
1822s%@host_vendor@%$host_vendor%g
1823s%@host_os@%$host_os%g
f0523145 1824s%@base_machine@%$base_machine%g
28f540f4
RM
1825s%@sysnames@%$sysnames%g
1826s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
1827s%@INSTALL_DATA@%$INSTALL_DATA%g
ad41463d 1828s%@LN_S@%$LN_S%g
ce4d8b66 1829s%@MSGFMT@%$MSGFMT%g
28f540f4
RM
1830s%@build@%$build%g
1831s%@build_alias@%$build_alias%g
1832s%@build_cpu@%$build_cpu%g
1833s%@build_vendor@%$build_vendor%g
1834s%@build_os@%$build_os%g
1835s%@CC@%$CC%g
40a4b79f 1836s%@BUILD_CC@%$BUILD_CC%g
8942a07a 1837s%@CPP@%$CPP%g
28f540f4
RM
1838s%@AR@%$AR%g
1839s%@RANLIB@%$RANLIB%g
b8dc6a10 1840s%@libc_cv_have_initfini@%$libc_cv_have_initfini%g
ad41463d 1841s%@libc_cv_ld_no_whole_archive@%$libc_cv_ld_no_whole_archive%g
28f540f4
RM
1842s%@uname_sysname@%$uname_sysname%g
1843s%@uname_release@%$uname_release%g
1844s%@uname_version@%$uname_version%g
91c7b85d 1845s%@stdio@%$stdio%g
28f540f4
RM
1846s%@gnu_ld@%$gnu_ld%g
1847s%@gnu_as@%$gnu_as%g
1848s%@elf@%$elf%g
424f8c09
RM
1849s%@shared@%$shared%g
1850s%@profile@%$profile%g
1851s%@omitfp@%$omitfp%g
28f540f4
RM
1852
1853CEOF
1854EOF
1855cat >> $CONFIG_STATUS <<EOF
1856
1857CONFIG_FILES=\${CONFIG_FILES-"config.make ${config_makefile} ${config_uname}"}
1858EOF
1859cat >> $CONFIG_STATUS <<\EOF
1860for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
1861 # Support "outfile[:infile]", defaulting infile="outfile.in".
1862 case "$ac_file" in
1863 *:*) ac_file_in=`echo "$ac_file"|sed 's%.*:%%'`
1864 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
1865 *) ac_file_in="${ac_file}.in" ;;
1866 esac
1867
1868 # Adjust relative srcdir, etc. for subdirectories.
1869
1870 # Remove last slash and all that follows it. Not all systems have dirname.
1871 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
1872 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
1873 # The file is in a subdirectory.
1874 test ! -d "$ac_dir" && mkdir "$ac_dir"
1875 ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
1876 # A "../" for each directory in $ac_dir_suffix.
1877 ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
1878 else
1879 ac_dir_suffix= ac_dots=
1880 fi
1881
1882 case "$ac_given_srcdir" in
1883 .) srcdir=.
1884 if test -z "$ac_dots"; then top_srcdir=.
1885 else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
1886 /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
1887 *) # Relative path.
1888 srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
1889 top_srcdir="$ac_dots$ac_given_srcdir" ;;
1890 esac
1891
1892 case "$ac_given_INSTALL" in
1893 [/$]*) INSTALL="$ac_given_INSTALL" ;;
1894 *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
1895 esac
1896 echo creating "$ac_file"
1897 rm -f "$ac_file"
1898 configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
1899 case "$ac_file" in
1900 *Makefile*) ac_comsub="1i\\
1901# $configure_input" ;;
1902 *) ac_comsub= ;;
1903 esac
1904 sed -e "$ac_comsub
1905s%@configure_input@%$configure_input%g
1906s%@srcdir@%$srcdir%g
1907s%@top_srcdir@%$top_srcdir%g
1908s%@INSTALL@%$INSTALL%g
1909" -f conftest.subs $ac_given_srcdir/$ac_file_in > $ac_file
1910fi; done
1911rm -f conftest.subs
1912
1913# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
1914# NAME is the cpp macro being defined and VALUE is the value it is being given.
1915#
1916# ac_d sets the value in "#define NAME VALUE" lines.
1917ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)'
1918ac_dB='\([ ][ ]*\)[^ ]*%\1#\2'
1919ac_dC='\3'
1920ac_dD='%g'
1921# ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
1922ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
1923ac_uB='\([ ]\)%\1#\2define\3'
1924ac_uC=' '
1925ac_uD='\4%g'
1926# ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
1927ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
1928ac_eB='$%\1#\2define\3'
1929ac_eC=' '
1930ac_eD='%g'
1931
1932CONFIG_HEADERS=${CONFIG_HEADERS-"config.h"}
1933for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
1934 # Support "outfile[:infile]", defaulting infile="outfile.in".
1935 case "$ac_file" in
1936 *:*) ac_file_in=`echo "$ac_file"|sed 's%.*:%%'`
1937 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
1938 *) ac_file_in="${ac_file}.in" ;;
1939 esac
1940
1941 echo creating $ac_file
1942
1943 rm -f conftest.frag conftest.in conftest.out
1944 cp $ac_given_srcdir/$ac_file_in conftest.in
1945
1946EOF
1947
1948# Transform confdefs.h into a sed script conftest.vals that substitutes
1949# the proper values into config.h.in to produce config.h. And first:
91c7b85d 1950# Protect against being on the right side of a sed subst in config.status.
28f540f4
RM
1951# Protect against being in an unquoted here document in config.status.
1952rm -f conftest.vals
1953cat > conftest.hdr <<\EOF
1954s/[\\&%]/\\&/g
1955s%[\\$`]%\\&%g
c224a18a 1956s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
28f540f4
RM
1957s%ac_d%ac_u%gp
1958s%ac_u%ac_e%gp
1959EOF
1960sed -n -f conftest.hdr confdefs.h > conftest.vals
1961rm -f conftest.hdr
1962
1963# This sed command replaces #undef with comments. This is necessary, for
1964# example, in the case of _POSIX_SOURCE, which is predefined and required
1965# on some systems where configure will not decide to define it.
1966cat >> conftest.vals <<\EOF
1967s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
1968EOF
1969
1970# Break up conftest.vals because some shells have a limit on
1971# the size of here documents, and old seds have small limits too.
1972# Maximum number of lines to put in a single here document.
1973ac_max_here_lines=12
1974
1975rm -f conftest.tail
1976while :
1977do
1978 ac_lines=`grep -c . conftest.vals`
1979 # grep -c gives empty output for an empty file on some AIX systems.
1980 if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
1981 # Write a limited-size here document to conftest.frag.
1982 echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
1983 sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
1984 echo 'CEOF
1985 sed -f conftest.frag conftest.in > conftest.out
1986 rm -f conftest.in
1987 mv conftest.out conftest.in
1988' >> $CONFIG_STATUS
1989 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
1990 rm -f conftest.vals
1991 mv conftest.tail conftest.vals
1992done
1993rm -f conftest.vals
1994
1995cat >> $CONFIG_STATUS <<\EOF
1996 rm -f conftest.frag conftest.h
1997 echo "/* $ac_file. Generated automatically by configure. */" > conftest.h
1998 cat conftest.in >> conftest.h
1999 rm -f conftest.in
2000 if cmp -s $ac_file conftest.h 2>/dev/null; then
2001 echo "$ac_file is unchanged"
2002 rm -f conftest.h
2003 else
ad41463d
RM
2004 # Remove last slash and all that follows it. Not all systems have dirname.
2005 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
2006 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
2007 # The file is in a subdirectory.
2008 test ! -d "$ac_dir" && mkdir "$ac_dir"
2009 fi
28f540f4
RM
2010 rm -f $ac_file
2011 mv conftest.h $ac_file
2012 fi
2013fi; done
2014
2015EOF
2016
2017cat >> $CONFIG_STATUS <<EOF
2018ac_sources="`echo $libc_link_sources`"
2019ac_dests="`echo $libc_link_dests`"
2020EOF
2021
2022cat >> $CONFIG_STATUS <<\EOF
2023srcdir=$ac_given_srcdir
2024while test -n "$ac_sources"; do
2025 set $ac_dests; ac_dest=$1; shift; ac_dests=$*
2026 set $ac_sources; ac_source=$1; shift; ac_sources=$*
2027
2028 echo "linking $srcdir/$ac_source to $ac_dest"
2029
2030 if test ! -r $srcdir/$ac_source; then
2031 { echo "configure: error: $srcdir/$ac_source: File not found" 1>&2; exit 1; }
2032 fi
2033 rm -f $ac_dest
2034
2035 # Make relative symlinks.
2036 # Remove last slash and all that follows it. Not all systems have dirname.
2037 ac_dest_dir=`echo $ac_dest|sed 's%/[^/][^/]*$%%'`
2038 if test "$ac_dest_dir" != "$ac_dest" && test "$ac_dest_dir" != .; then
2039 # The dest file is in a subdirectory.
2040 test ! -d "$ac_dest_dir" && mkdir "$ac_dest_dir"
2041 ac_dest_dir_suffix="/`echo $ac_dest_dir|sed 's%^\./%%'`"
2042 # A "../" for each directory in $ac_dest_dir_suffix.
2043 ac_dots=`echo $ac_dest_dir_suffix|sed 's%/[^/]*%../%g'`
2044 else
2045 ac_dest_dir_suffix= ac_dots=
2046 fi
2047
2048 case "$srcdir" in
2049 [/$]*) ac_rel_source="$srcdir/$ac_source" ;;
2050 *) ac_rel_source="$ac_dots$srcdir/$ac_source" ;;
2051 esac
2052
2053 # Make a symlink if possible; otherwise try a hard link.
2054 if ln -s $ac_rel_source $ac_dest 2>/dev/null ||
2055 ln $srcdir/$ac_source $ac_dest; then :
2056 else
2057 { echo "configure: error: can not link $ac_dest to $srcdir/$ac_source" 1>&2; exit 1; }
2058 fi
2059done
2060EOF
2061cat >> $CONFIG_STATUS <<EOF
2062echo '$config_vars' >> config.make
2063EOF
2064cat >> $CONFIG_STATUS <<\EOF
2065
2066exit 0
2067EOF
2068chmod +x $CONFIG_STATUS
2069rm -fr confdefs* $ac_clean_files
2070test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
2071
6b3a2224
RM
2072if test "$no_recursion" != yes; then
2073
2074 # Remove --cache-file and --srcdir arguments so they do not pile up.
2075 ac_sub_configure_args=
2076 ac_prev=
2077 for ac_arg in $ac_configure_args; do
2078 if test -n "$ac_prev"; then
2079 ac_prev=
2080 continue
2081 fi
2082 case "$ac_arg" in
2083 -cache-file | --cache-file | --cache-fil | --cache-fi \
2084 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
2085 ac_prev=cache_file ;;
2086 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
2087 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
2088 ;;
2089 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
2090 ac_prev=srcdir ;;
2091 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
2092 ;;
2093 *) ac_sub_configure_args="$ac_sub_configure_args $ac_arg" ;;
2094 esac
2095 done
2096
2097 for ac_config_dir in $add_ons; do
2098
2099 # Do not complain, so a configure script can configure whichever
2100 # parts of a large source tree are present.
2101 if test ! -d $srcdir/$ac_config_dir; then
2102 continue
2103 fi
2104
2105 echo configuring in $ac_config_dir
2106
2107 case "$srcdir" in
2108 .) ;;
2109 *)
2110 if test -d ./$ac_config_dir || mkdir ./$ac_config_dir; then :;
2111 else
2112 { echo "configure: error: can not create `pwd`/$ac_config_dir" 1>&2; exit 1; }
2113 fi
2114 ;;
2115 esac
2116
2117 ac_popdir=`pwd`
2118 cd $ac_config_dir
2119
2120 case "$srcdir" in
2121 .) # No --srcdir option. We are building in place.
2122 ac_sub_srcdir=$srcdir ;;
2123 /*) # Absolute path.
2124 ac_sub_srcdir=$srcdir/$ac_config_dir ;;
2125 *) # Relative path.
2126 ac_sub_srcdir=../$srcdir/$ac_config_dir ;;
2127 esac
2128
2129 # Check for guested configure; otherwise get Cygnus style configure.
2130 if test -f $ac_sub_srcdir/configure; then
2131 ac_sub_configure=$ac_sub_srcdir/configure
2132 elif test -f $ac_sub_srcdir/configure.in; then
2133 ac_sub_configure=$ac_configure
2134 else
2135 echo "configure: warning: no configuration information is in $ac_config_dir" 1>&2
2136 ac_sub_configure=
2137 fi
2138
2139 # The recursion is here.
2140 if test -n "$ac_sub_configure"; then
2141
2142 # Make the cache file name correct relative to the subdirectory.
2143 # A "../" for each directory in /$ac_config_dir.
2144 ac_dots=`echo $ac_config_dir|sed -e 's%^\./%%' -e 's%[^/]$%&/%' -e 's%[^/]*/%../%g'`
2145 case "$cache_file" in
2146 /*) ac_sub_cache_file=$cache_file ;;
2147 *) # Relative path.
2148 ac_sub_cache_file="$ac_dots$cache_file" ;;
2149 esac
2150 case "$ac_given_INSTALL" in
2151 [/$]*) INSTALL="$ac_given_INSTALL" ;;
2152 *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
2153 esac
2154
2155 echo "running ${CONFIG_SHELL-/bin/sh} $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_sub_srcdir"
2156 # The eval makes quoting arguments work.
2157 if eval ${CONFIG_SHELL-/bin/sh} $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_sub_srcdir
2158 then :
2159 else
2160 { echo "configure: error: $ac_sub_configure failed for $ac_config_dir" 1>&2; exit 1; }
2161 fi
2162 fi
2163
2164 cd $ac_popdir
2165 done
2166fi
2167