* extra-lib.mk (install-lib, extra-objs, alltypes-$(lib)): Make
[glibc.git] / configure
blob282c82239f83adf32e3477aa35646b5b11fdfe45
1 #! /bin/sh
3 # From configure.in CVSid
4 # Guess values for system-dependent variables and create Makefiles.
5 # Generated automatically using autoconf version 2.2
6 # Copyright (C) 1992, 1993, 1994 Free Software Foundation, Inc.
8 # This configure script is free software; the Free Software Foundation
9 # gives unlimited permission to copy, distribute and modify it.
11 # Defaults:
12 ac_help=
13 ac_default_prefix=/usr/local
14 # Any additions from configure.in:
15 ac_help="$ac_help
16 --with-gmp=DIRECTORY find GMP source code in DIRECTORY (not needed)"
17 ac_help="$ac_help
18 --with-gnu-binutils if using GNU binutils (as and ld)"
19 ac_help="$ac_help
20 --with-gnu-ld if using GNU ld (in the binutils package)"
21 ac_help="$ac_help
22 --with-gnu-as if using GNU as (in the binutils package)"
23 ac_help="$ac_help
24 --with-elf if using the ELF object format"
25 ac_help="$ac_help
26 --with-weak-symbols if weak symbols are available in as and ld"
27 ac_help="$ac_help
28 --enable-shared build shared library [default=yes if GNU ld & ELF]"
29 ac_help="$ac_help
30 --enable-profile build profiled library [default=yes]"
31 ac_help="$ac_help
32 --enable-omitfp build undebuggable optimized library [default=no]"
34 # Initialize some variables set by options.
35 # The variables have the same names as the options, with
36 # dashes changed to underlines.
37 build=NONE
38 cache_file=./config.cache
39 exec_prefix=NONE
40 host=NONE
41 no_create=
42 nonopt=NONE
43 no_recursion=
44 prefix=NONE
45 program_prefix=NONE
46 program_suffix=NONE
47 program_transform_name=s,x,x,
48 silent=
49 site=
50 srcdir=
51 target=NONE
52 verbose=
53 x_includes=NONE
54 x_libraries=NONE
56 # Initialize some other variables.
57 subdirs=
59 ac_prev=
60 for ac_option
63 # If the previous option needs an argument, assign it.
64 if test -n "$ac_prev"; then
65 eval "$ac_prev=\$ac_option"
66 ac_prev=
67 continue
70 case "$ac_option" in
71 -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
72 *) ac_optarg= ;;
73 esac
75 # Accept the important Cygnus configure options, so we can diagnose typos.
77 case "$ac_option" in
79 -build | --build | --buil | --bui | --bu | --b)
80 ac_prev=build ;;
81 -build=* | --build=* | --buil=* | --bui=* | --bu=* | --b=*)
82 build="$ac_optarg" ;;
84 -cache-file | --cache-file | --cache-fil | --cache-fi \
85 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
86 ac_prev=cache_file ;;
87 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
88 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
89 cache_file="$ac_optarg" ;;
91 -disable-* | --disable-*)
92 ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
93 # Reject names that are not valid shell variable names.
94 if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
95 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
97 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
98 eval "enable_${ac_feature}=no" ;;
100 -enable-* | --enable-*)
101 ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
102 # Reject names that are not valid shell variable names.
103 if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
104 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
106 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
107 case "$ac_option" in
108 *=*) ;;
109 *) ac_optarg=yes ;;
110 esac
111 eval "enable_${ac_feature}='$ac_optarg'" ;;
113 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
114 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
115 | --exec | --exe | --ex)
116 ac_prev=exec_prefix ;;
117 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
118 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
119 | --exec=* | --exe=* | --ex=*)
120 exec_prefix="$ac_optarg" ;;
122 -gas | --gas | --ga | --g)
123 # Obsolete; use --with-gas.
124 with_gas=yes ;;
126 -help | --help | --hel | --he)
127 # Omit some internal or obsolete options to make the list less imposing.
128 # This message is too long to be a string in the A/UX 3.1 sh.
129 cat << EOF
130 Usage: configure [options] [host]
131 Options: [defaults in brackets after descriptions]
132 Configuration:
133 --cache-file=FILE cache test results in FILE
134 --help print this message
135 --no-create do not create output files
136 --quiet, --silent do not print \`checking...' messages
137 --version print the version of autoconf that created configure
138 Directory and file names:
139 --prefix=PREFIX install architecture-independent files in PREFIX
140 [$ac_default_prefix]
141 --exec-prefix=PREFIX install architecture-dependent files in PREFIX
142 [same as prefix]
143 --srcdir=DIR find the sources in DIR [configure dir or ..]
144 --program-prefix=PREFIX prepend PREFIX to installed program names
145 --program-suffix=SUFFIX append SUFFIX to installed program names
146 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
147 Host type:
148 --build=BUILD configure for building on BUILD [BUILD=HOST]
149 --host=HOST configure for HOST [guessed]
150 --target=TARGET configure for TARGET [TARGET=HOST]
151 Features and packages:
152 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
153 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
154 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
155 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
156 --x-includes=DIR X include files are in DIR
157 --x-libraries=DIR X library files are in DIR
158 --enable and --with options recognized:$ac_help
160 exit 0 ;;
162 -host | --host | --hos | --ho)
163 ac_prev=host ;;
164 -host=* | --host=* | --hos=* | --ho=*)
165 host="$ac_optarg" ;;
167 -nfp | --nfp | --nf)
168 # Obsolete; use --without-fp.
169 with_fp=no ;;
171 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
172 | --no-cr | --no-c)
173 no_create=yes ;;
175 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
176 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
177 no_recursion=yes ;;
179 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
180 ac_prev=prefix ;;
181 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
182 prefix="$ac_optarg" ;;
184 -program-prefix | --program-prefix | --program-prefi | --program-pref \
185 | --program-pre | --program-pr | --program-p)
186 ac_prev=program_prefix ;;
187 -program-prefix=* | --program-prefix=* | --program-prefi=* \
188 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
189 program_prefix="$ac_optarg" ;;
191 -program-suffix | --program-suffix | --program-suffi | --program-suff \
192 | --program-suf | --program-su | --program-s)
193 ac_prev=program_suffix ;;
194 -program-suffix=* | --program-suffix=* | --program-suffi=* \
195 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
196 program_suffix="$ac_optarg" ;;
198 -program-transform-name | --program-transform-name \
199 | --program-transform-nam | --program-transform-na \
200 | --program-transform-n | --program-transform- \
201 | --program-transform | --program-transfor \
202 | --program-transfo | --program-transf \
203 | --program-trans | --program-tran \
204 | --progr-tra | --program-tr | --program-t)
205 ac_prev=program_transform_name ;;
206 -program-transform-name=* | --program-transform-name=* \
207 | --program-transform-nam=* | --program-transform-na=* \
208 | --program-transform-n=* | --program-transform-=* \
209 | --program-transform=* | --program-transfor=* \
210 | --program-transfo=* | --program-transf=* \
211 | --program-trans=* | --program-tran=* \
212 | --progr-tra=* | --program-tr=* | --program-t=*)
213 program_transform_name="$ac_optarg" ;;
215 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
216 | -silent | --silent | --silen | --sile | --sil)
217 silent=yes ;;
219 -site | --site | --sit)
220 ac_prev=site ;;
221 -site=* | --site=* | --sit=*)
222 site="$ac_optarg" ;;
224 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
225 ac_prev=srcdir ;;
226 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
227 srcdir="$ac_optarg" ;;
229 -target | --target | --targe | --targ | --tar | --ta | --t)
230 ac_prev=target ;;
231 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
232 target="$ac_optarg" ;;
234 -v | -verbose | --verbose | --verbos | --verbo | --verb)
235 verbose=yes ;;
237 -version | --version | --versio | --versi | --vers)
238 echo "configure generated by autoconf version 2.2"
239 exit 0 ;;
241 -with-* | --with-*)
242 ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
243 # Reject names that are not valid shell variable names.
244 if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
245 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
247 ac_package=`echo $ac_package| sed 's/-/_/g'`
248 case "$ac_option" in
249 *=*) ;;
250 *) ac_optarg=yes ;;
251 esac
252 eval "with_${ac_package}='$ac_optarg'" ;;
254 -without-* | --without-*)
255 ac_package=`echo $ac_option|sed -e 's/-*without-//'`
256 # Reject names that are not valid shell variable names.
257 if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
258 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
260 ac_package=`echo $ac_package| sed 's/-/_/g'`
261 eval "with_${ac_package}=no" ;;
263 --x)
264 # Obsolete; use --with-x.
265 with_x=yes ;;
267 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
268 | --x-incl | --x-inc | --x-in | --x-i)
269 ac_prev=x_includes ;;
270 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
271 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
272 x_includes="$ac_optarg" ;;
274 -x-libraries | --x-libraries | --x-librarie | --x-librari \
275 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
276 ac_prev=x_libraries ;;
277 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
278 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
279 x_libraries="$ac_optarg" ;;
281 -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
285 if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
286 echo "configure: warning: $ac_option: invalid host type" 1>&2
288 if test "x$nonopt" != xNONE; then
289 { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
291 nonopt="$ac_option"
294 esac
295 done
297 if test -n "$ac_prev"; then
298 { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
301 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
303 # File descriptor usage:
304 # 0 standard input
305 # 1 file creation
306 # 2 errors and warnings
307 # 3 some systems may open it to /dev/tty
308 # 4 used on the Kubota Titan
309 # 4 checking for... messages and results
310 # 5 compiler messages saved in config.log
311 if test "$silent" = yes; then
312 exec 4>/dev/null
313 else
314 exec 4>&1
316 exec 5>./config.log
318 echo "\
319 This file contains any messages produced by compilers while
320 running configure, to aid debugging if configure makes a mistake.
321 " 1>&5
323 # Strip out --no-create and --no-recursion so they do not pile up.
324 # Also quote any args containing shell metacharacters.
325 ac_configure_args=
326 for ac_arg
328 case "$ac_arg" in
329 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
330 | --no-cr | --no-c) ;;
331 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
332 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
333 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
334 ac_configure_args="$ac_configure_args '$ac_arg'" ;;
335 *) ac_configure_args="$ac_configure_args $ac_arg" ;;
336 esac
337 done
339 # NLS nuisances.
340 # Only set LANG and LC_ALL to C if already set.
341 # These must not be set unconditionally because not all systems understand
342 # e.g. LANG=C (notably SCO).
343 if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
344 if test "${LANG+set}" = set; then LANG=C; export LANG; fi
346 # confdefs.h avoids OS command line length limits that DEFS can exceed.
347 rm -rf conftest* confdefs.h
348 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
349 echo > confdefs.h
351 # A filename unique to this package, relative to the directory that
352 # configure is in, which we can look for to find out if srcdir is correct.
353 ac_unique_file=features.h
355 # Find the source files, if location was not specified.
356 if test -z "$srcdir"; then
357 ac_srcdir_defaulted=yes
358 # Try the directory containing this script, then its parent.
359 ac_prog=$0
360 ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
361 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
362 srcdir=$ac_confdir
363 if test ! -r $srcdir/$ac_unique_file; then
364 srcdir=..
366 else
367 ac_srcdir_defaulted=no
369 if test ! -r $srcdir/$ac_unique_file; then
370 if test "$ac_srcdir_defaulted" = yes; then
371 { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
372 else
373 { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
376 srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
378 # Prefer explicitly selected file to automatically selected ones.
379 if test -z "$CONFIG_SITE"; then
380 if test "x$prefix" != xNONE; then
381 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
382 else
383 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
386 for ac_site_file in $CONFIG_SITE; do
387 if test -r "$ac_site_file"; then
388 echo "loading site script $ac_site_file"
389 . "$ac_site_file"
391 done
393 if test -r "$cache_file"; then
394 echo "loading cache $cache_file"
395 . $cache_file
396 else
397 echo "creating cache $cache_file"
398 > $cache_file
401 ac_ext=c
402 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
403 ac_cpp='$CPP $CPPFLAGS'
404 ac_compile='${CC-cc} conftest.$ac_ext $CFLAGS $CPPFLAGS -c 1>&5 2>&5'
405 ac_link='${CC-cc} conftest.$ac_ext $CFLAGS $CPPFLAGS $LDFLAGS -o conftest $LIBS 1>&5 2>&5'
407 if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
408 # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
409 if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
410 ac_n= ac_c='
411 ' ac_t=' '
412 else
413 ac_n=-n ac_c= ac_t=
415 else
416 ac_n= ac_c='\c' ac_t=
419 if test -r /vmunix; then
420 kernel_id=`strings /vmunix | grep UNIX`
421 elif test -r /dynix; then
422 kernel_id=`strings /dynix | grep DYNIX`
423 else
424 kernel_id=
430 # This will get text that should go into config.make.
431 config_vars=
433 # Check for a --with-gmp argument and set gmp-srcdir in config.make.
434 # Check whether --with-gmp or --without-gmp was given.
435 withval="$with_gmp"
436 if test -n "$withval"; then
437 case "$with_gmp" in
438 yes) { echo "configure: error: --with-gmp requires an argument; use --with-gmp=DIRECTORY" 1>&2; exit 1; } ;;
439 ''|no) ;;
440 *) config_vars="$config_vars
441 gmp-srcdir = $withval" ;;
442 esac
447 # Check whether --with-gnu-binutils or --without-gnu-binutils was given.
448 withval="$with_gnu_binutils"
449 if test -n "$withval"; then
450 gnu_binutils=yes
451 else
452 gnu_binutils=no
455 # Check whether --with-gnu-ld or --without-gnu-ld was given.
456 withval="$with_gnu_ld"
457 if test -n "$withval"; then
458 gnu_ld=yes
459 else
460 gnu_ld=no
463 # Check whether --with-gnu-as or --without-gnu-as was given.
464 withval="$with_gnu_as"
465 if test -n "$withval"; then
466 gnu_as=yes
467 else
468 gnu_as=no
471 test $gnu_binutils = yes && gnu_as=yes gnu_ld=yes
472 # Check whether --with-elf or --without-elf was given.
473 withval="$with_elf"
474 if test -n "$withval"; then
475 elf=yes
476 else
477 elf=no
480 # Check whether --with-weak-symbols or --without-weak-symbols was given.
481 withval="$with_weak_symbols"
482 if test -n "$withval"; then
483 weak=yes
484 else
485 weak=no
489 # Check whether --enable-shared or --disable-shared was given.
490 enableval="$enable_shared"
491 if test -n "$enableval"; then
492 shared=$enableval
493 else
494 shared=default
497 # Check whether --enable-profile or --disable-profile was given.
498 enableval="$enable_profile"
499 if test -n "$enableval"; then
500 profile=$enableval
501 else
502 profile=yes
505 # Check whether --enable-omitfp or --disable-omitfp was given.
506 enableval="$enable_omitfp"
507 if test -n "$enableval"; then
508 omitfp=$enableval
509 else
510 omitfp=no
514 ac_aux_dir=
515 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
516 if test -f $ac_dir/install-sh; then
517 ac_aux_dir=$ac_dir
518 ac_install_sh="$ac_aux_dir/install-sh -c"
519 break
520 elif test -f $ac_dir/install.sh; then
521 ac_aux_dir=$ac_dir
522 ac_install_sh="$ac_aux_dir/install.sh -c"
523 break
525 done
526 if test -z "$ac_aux_dir"; then
527 { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
529 ac_config_guess=$ac_aux_dir/config.guess
530 ac_config_sub=$ac_aux_dir/config.sub
531 ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
534 # Make sure we can run config.sub.
535 if $ac_config_sub sun4 >/dev/null 2>&1; then :
536 else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
539 echo $ac_n "checking host system type""... $ac_c" 1>&4
541 host_alias=$host
542 case "$host_alias" in
543 NONE)
544 case $nonopt in
545 NONE)
546 if host_alias=`$ac_config_guess`; then :
547 else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
548 fi ;;
549 *) host_alias=$nonopt ;;
550 esac ;;
551 esac
553 host=`$ac_config_sub $host_alias`
554 host_cpu=`echo $host | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\1/'`
555 host_vendor=`echo $host | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\2/'`
556 host_os=`echo $host | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\3/'`
557 echo "$ac_t""$host" 1>&4
559 # We keep the original values in `$config_*' and never modify them, so we
560 # can write them unchanged into config.make. Everything else uses
561 # $machine, $vendor, and $os, and changes them whenever convenient.
562 config_machine=$host_cpu config_vendor=$host_vendor config_os=$host_os
564 sysdep_dir=$srcdir/sysdeps
565 echo $ac_n "checking sysdep dirs""... $ac_c" 1>&4
566 if eval "test \"`echo '$''{'libc_cv_sysdirs'+set}'`\" = set"; then
567 echo $ac_n "(cached) $ac_c" 1>&4
568 else
569 machine=$config_machine
570 vendor=$config_vendor
571 os=$config_os
573 # Expand the configuration machine name into a subdirectory by architecture
574 # type and particular chip.
575 case "$machine" in
576 i[345]86)
577 machine=i386/$machine ;;
578 sparc[6789])
579 machine=sparc/$machine ;;
580 m68k)
581 machine=m68k/m68020 ;;
582 m680?0)
583 machine=m68k/$machine ;;
584 m88k)
585 machine=m88k/m88100 ;;
586 m88???)
587 machine=m88k/$machine ;;
588 mips64*)
589 machine=mips/mips64/$machine ;;
590 mips*)
591 machine=mips/$machine ;;
592 esac
594 # Make sco3.2v4 become sco3.2.4 and sunos4.1.1_U1 become sunos4.1.1.U1.
595 os="`echo $os | sed 's/\([0-9A-Z]\)[v_]\([0-9A-Z]\)/\1.\2/g'`"
597 case "$os" in
598 gnu*)
599 base_os=mach/hurd ;;
600 netbsd* | 386bsd*)
601 base_os=unix/bsd/bsd4.4 ;;
602 osf* | sunos* | ultrix* | newsos* | dynix* | *bsd*)
603 base_os=unix/bsd ;;
604 linux* | sysv* | isc* | esix* | sco* | minix* | irix4*)
605 base_os=unix/sysv ;;
606 solaris[2-9]*)
607 base_os=unix/sysv/sysv4 ;;
608 none)
609 base_os=standalone ;;
611 base_os='' ;;
612 esac
614 # For sunos4.1.1, try sunos4.1.1, then sunos4.1, then sunos4, then sunos.
615 tail=$os
616 ostry=$os
617 while o=`echo $tail | sed 's/\.[^.]*$//'`; test $o != $tail; do
618 ostry="$ostry /$o"
619 tail=$o
620 done
621 o=`echo $tail | sed 's/[0-9]*$//'`
622 if test $o != $tail; then
623 ostry="$ostry /$o"
626 # For unix/sysv/sysv4, try unix/sysv/sysv4, then unix/sysv, then unix.
627 base=
628 tail=$base_os
629 while b=`echo $tail | sed 's@^\(.*\)/\([^/]*\)$@& \1@'`; test -n "$b"; do
630 set $b
631 base="$base /$1"
632 tail="$2"
633 done
635 # For sparc/sparc9, try sparc/sparc9 and then sparc.
636 mach=
637 tail=$machine
638 while m=`echo $tail | sed 's@^\(.*\)/\([^/]*\)$@& \1@'`; test -n "$m"; do
639 set $m
640 mach="$mach /$1"
641 tail="$2"
642 done
645 # Find what sysdep directories exist.
646 sysnames=
647 for b in $base ''; do
648 for m0 in $mach ''; do
649 for v in /$vendor ''; do
650 for o in /$ostry ''; do
651 for m in $mach ''; do
652 try="$m0$b$v$o$m"
653 if test -d $sysdep_dir$try; then
654 sysnames="$sysnames $try"
655 { test -n "$o" || test -n "$b"; } && os_used=t
656 { test -n "$m" || test -n "$m0"; } && machine_used=t
658 done
659 done
660 done
661 done
662 done
664 if test -z "$os_used" && test "$os" != none; then
665 { echo "configure: error: Operating system $os is not supported." 1>&2; exit 1; }
667 if test -z "$machine_used" && test "$machine" != none; then
668 { echo "configure: error: The $machine is not supported." 1>&2; exit 1; }
671 # We have now validated the configuration.
673 # Remove the leading slashes.
674 sysnames="`echo $sysnames | sed -e 's@^/@@' -e 's@ /@ @g'`"
676 # Prepend the machine's FPU directory unless --without-fp.
677 if test "$with_fp" = no; then
678 fpu_dirs=
679 for m in $mach; do
680 if test -d $sysdep_dir$m/fpu; then
681 fpu_dirs="$fpu_dirs $m/fpu"
683 done
684 sysnames="`echo $fpu_dirs | sed -e 's,^/,,' -e 's, /,,g'` $sysnames"
687 # Expand the list of system names into a full list of directories
688 # from each element's parent name and Implies file (if present).
689 set $sysnames
690 while test $# -gt 0; do
691 name=$1
692 shift
694 if test -f $sysdep_dir/$name/Implies; then
695 # Collect more names from the `Implies' file (removing comments).
696 implied="`sed 's/#.*$//' < $sysdep_dir/$name/Implies`"
697 for x in $implied; do
698 test -d $sysdep_dir/$x || echo "Warning: $name implies nonexistent $x">&2
699 done
700 else
701 implied=
704 # Add NAME to the list of names.
705 names="$names $name"
707 # Find the parent of NAME, using the empty string if it has none.
708 parent="`echo $name | sed -n -e '/\//!q' -e 's=/[^/]*$==p'`"
710 # Add the names implied by NAME, and NAME's parent (if it has one), to
711 # the list of names to be processed (the argument list). We prepend the
712 # implied names to the list and append the parent. We want implied
713 # directories to come before further directories inferred from the
714 # configuration components; this ensures that for sysv4, unix/common
715 # (implied by unix/sysv/sysv4) comes before unix/sysv (in ostry (here $*)
716 # after sysv4).
717 sysnames="`echo $implied $* $parent`"
718 test -n "$sysnames" && set $sysnames
719 done
721 # Add the default directories.
722 names="$names generic stub"
724 # Now uniquize the list.
725 seen=
726 sysnames=
727 for name in $names; do
728 if echo "$seen" | fgrep -x $name >/dev/null; then
729 # Already in the list.
730 true;
731 else
732 # A new one.
733 if test -z "$seen"; then
734 seen="$name" sysnames="$name"
735 else
736 seen="$seen
737 $name"
738 sysnames="$sysnames $name"
741 done
742 libc_cv_sysdirs="$sysnames"
745 sysnames="$libc_cv_sysdirs"
746 echo "$ac_t""${sysnames}" 1>&4
748 case "$host_os" in
749 gnu* | linux* | bsd4.4* | netbsd* | freebsd*)
750 gnu_ld=yes gnu_as=yes
751 esac
752 case "$host_os" in
753 gnu*elf* | linux*elf* | sysv4* | solaris2*)
754 elf=yes
755 esac
757 # Find a good install program. We prefer a C program (faster),
758 # so one script is as good as another. But avoid the broken or
759 # incompatible versions:
760 # SysV /etc/install, /usr/sbin/install
761 # SunOS /usr/etc/install
762 # IRIX /sbin/install
763 # AIX /bin/install
764 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
765 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
766 # ./install, which can be erroneously created by make from ./install.sh.
767 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&4
768 if test -z "$INSTALL"; then
769 if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
770 echo $ac_n "(cached) $ac_c" 1>&4
771 else
772 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
773 for ac_dir in $PATH; do
774 # Account for people who put trailing slashes in PATH elements.
775 case "$ac_dir/" in
776 /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
778 # OSF1 and SCO ODT 3.0 have their own names for install.
779 for ac_prog in ginstall installbsd scoinst install; do
780 if test -f $ac_dir/$ac_prog; then
781 if test $ac_prog = install &&
782 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
783 # AIX install. It has an incompatible calling convention.
784 # OSF/1 installbsd also uses dspmsg, but is usable.
786 else
787 ac_cv_path_install="$ac_dir/$ac_prog -c"
788 break 2
791 done
793 esac
794 done
795 IFS="$ac_save_ifs"
796 # As a last resort, use the slow shell script.
797 test -z "$ac_cv_path_install" && ac_cv_path_install="$ac_install_sh"
799 INSTALL="$ac_cv_path_install"
801 echo "$ac_t""$INSTALL" 1>&4
803 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
804 # It thinks the first close brace ends the variable substitution.
805 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
807 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
809 if test "$INSTALL" = "${srcdir}/install-sh"; then
810 # The makefiles need to use a different form to find it in $srcdir.
811 INSTALL='$(..)./install-sh'
814 echo $ac_n "checking build system type""... $ac_c" 1>&4
816 build_alias=$build
817 case "$build_alias" in
818 NONE)
819 case $nonopt in
820 NONE) build_alias=$host_alias ;;
821 *) build_alias=$nonopt ;;
822 esac ;;
823 esac
825 build=`$ac_config_sub $build_alias`
826 build_cpu=`echo $build | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\1/'`
827 build_vendor=`echo $build | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\2/'`
828 build_os=`echo $build | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\3/'`
829 echo "$ac_t""$build" 1>&4
831 if test $host != $build; then
832 ac_tool_prefix=${host_alias}-
833 else
834 ac_tool_prefix=
837 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
838 set dummy ${ac_tool_prefix}gcc; ac_word=$2
839 echo $ac_n "checking for $ac_word""... $ac_c" 1>&4
840 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
841 echo $ac_n "(cached) $ac_c" 1>&4
842 else
843 if test -n "$CC"; then
844 ac_cv_prog_CC="$CC" # Let the user override the test.
845 else
846 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
847 for ac_dir in $PATH; do
848 test -z "$ac_dir" && ac_dir=.
849 if test -f $ac_dir/$ac_word; then
850 ac_cv_prog_CC="${ac_tool_prefix}gcc"
851 break
853 done
854 IFS="$ac_save_ifs"
855 test -z "$ac_cv_prog_CC" && ac_cv_prog_CC="gcc"
858 CC="$ac_cv_prog_CC"
859 if test -n "$CC"; then
860 echo "$ac_t""$CC" 1>&4
861 else
862 echo "$ac_t""no" 1>&4
867 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
868 set dummy ${ac_tool_prefix}ar; ac_word=$2
869 echo $ac_n "checking for $ac_word""... $ac_c" 1>&4
870 if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
871 echo $ac_n "(cached) $ac_c" 1>&4
872 else
873 if test -n "$AR"; then
874 ac_cv_prog_AR="$AR" # Let the user override the test.
875 else
876 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
877 for ac_dir in $PATH; do
878 test -z "$ac_dir" && ac_dir=.
879 if test -f $ac_dir/$ac_word; then
880 ac_cv_prog_AR="${ac_tool_prefix}ar"
881 break
883 done
884 IFS="$ac_save_ifs"
885 test -z "$ac_cv_prog_AR" && ac_cv_prog_AR="ar"
888 AR="$ac_cv_prog_AR"
889 if test -n "$AR"; then
890 echo "$ac_t""$AR" 1>&4
891 else
892 echo "$ac_t""no" 1>&4
897 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
898 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
899 echo $ac_n "checking for $ac_word""... $ac_c" 1>&4
900 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
901 echo $ac_n "(cached) $ac_c" 1>&4
902 else
903 if test -n "$RANLIB"; then
904 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
905 else
906 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
907 for ac_dir in $PATH; do
908 test -z "$ac_dir" && ac_dir=.
909 if test -f $ac_dir/$ac_word; then
910 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
911 break
913 done
914 IFS="$ac_save_ifs"
917 RANLIB="$ac_cv_prog_RANLIB"
918 if test -n "$RANLIB"; then
919 echo "$ac_t""$RANLIB" 1>&4
920 else
921 echo "$ac_t""no" 1>&4
925 if test -z "$ac_cv_prog_RANLIB"; then
926 if test -n "$ac_tool_prefix"; then
927 # Extract the first word of "ranlib", so it can be a program name with args.
928 set dummy ranlib; ac_word=$2
929 echo $ac_n "checking for $ac_word""... $ac_c" 1>&4
930 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
931 echo $ac_n "(cached) $ac_c" 1>&4
932 else
933 if test -n "$RANLIB"; then
934 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
935 else
936 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
937 for ac_dir in $PATH; do
938 test -z "$ac_dir" && ac_dir=.
939 if test -f $ac_dir/$ac_word; then
940 ac_cv_prog_RANLIB="ranlib"
941 break
943 done
944 IFS="$ac_save_ifs"
945 test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
948 RANLIB="$ac_cv_prog_RANLIB"
949 if test -n "$RANLIB"; then
950 echo "$ac_t""$RANLIB" 1>&4
951 else
952 echo "$ac_t""no" 1>&4
955 else
956 RANLIB=":"
960 echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&4
961 # On Suns, sometimes $CPP names a directory.
962 if test -n "$CPP" && test -d "$CPP"; then
963 CPP=
965 if test -z "$CPP"; then
966 if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
967 echo $ac_n "(cached) $ac_c" 1>&4
968 else
969 # This must be in double quotes, not single quotes, because CPP may get
970 # substituted into the Makefile and "${CC-cc}" will confuse make.
971 CPP="${CC-cc} -E"
972 # On the NeXT, cc -E runs the code through the compiler's parser,
973 # not just through cpp.
974 cat > conftest.$ac_ext <<EOF
975 #line 976 "configure"
976 #include "confdefs.h"
977 #include <assert.h>
978 Syntax Error
980 eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
981 ac_err=`grep -v '^ *+' conftest.out`
982 if test -z "$ac_err"; then
984 else
985 echo "$ac_err" >&5
986 rm -rf conftest*
987 CPP="${CC-cc} -E -traditional-cpp"
988 cat > conftest.$ac_ext <<EOF
989 #line 990 "configure"
990 #include "confdefs.h"
991 #include <assert.h>
992 Syntax Error
994 eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
995 ac_err=`grep -v '^ *+' conftest.out`
996 if test -z "$ac_err"; then
998 else
999 echo "$ac_err" >&5
1000 rm -rf conftest*
1001 CPP=/lib/cpp
1003 rm -f conftest*
1005 rm -f conftest*
1006 ac_cv_prog_CPP="$CPP"
1009 CPP="$ac_cv_prog_CPP"
1010 echo "$ac_t""$CPP" 1>&4
1013 echo $ac_n "checking signed size_t type""... $ac_c" 1>&4
1014 if eval "test \"`echo '$''{'libc_cv_signed_size_t'+set}'`\" = set"; then
1015 echo $ac_n "(cached) $ac_c" 1>&4
1016 else
1017 echo '#include <stddef.h>
1018 FOOBAR __SIZE_TYPE__ FOOBAR' > conftest.c
1019 if eval "$ac_cpp conftest.c 2>/dev/null" \
1020 | grep '^FOOBAR.*unsigned.*FOOBAR$' >/dev/null; then
1021 libc_cv_signed_size_t=no
1022 else
1023 libc_cv_signed_size_t=yes
1025 rm -f conftest*
1028 echo "$ac_t""$libc_cv_signed_size_t" 1>&4
1029 if test $libc_cv_signed_size_t = yes; then
1030 cat >> confdefs.h <<\EOF
1031 #undef __SIZE_TYPE__
1032 #define __SIZE_TYPE__ unsigned
1036 echo $ac_n "checking libc-friendly stddef.h""... $ac_c" 1>&4
1037 if eval "test \"`echo '$''{'libc_cv_friendly_stddef'+set}'`\" = set"; then
1038 echo $ac_n "(cached) $ac_c" 1>&4
1039 else
1040 cat > conftest.$ac_ext <<EOF
1041 #line 1042 "configure"
1042 #include "confdefs.h"
1043 #define __need_size_t
1044 #define __need_wchar_t
1045 #include <stddef.h>
1046 #define __need_NULL
1047 #include <stddef.h>
1048 int main() { return 0; }
1049 int t() {
1050 size_t size; wchar_t wchar;
1051 #ifdef offsetof
1052 #error stddef.h ignored __need_*
1053 #endif
1054 if (&size == NULL || &wchar == NULL) abort ();
1055 ; return 0; }
1057 if eval $ac_compile; then
1058 rm -rf conftest*
1059 libc_cv_friendly_stddef=yes
1060 else
1061 rm -rf conftest*
1062 libc_cv_friendly_stddef=no
1064 rm -f conftest*
1068 echo "$ac_t""$libc_cv_friendly_stddef" 1>&4
1069 if test $libc_cv_friendly_stddef = yes; then
1070 config_vars="$config_vars
1071 override stddef.h = # The installed <stddef.h> seems to be libc-friendly."
1074 echo $ac_n "checking whether we need to use -P to assemble .S files""... $ac_c" 1>&4
1075 if eval "test \"`echo '$''{'libc_cv_need_minus_P'+set}'`\" = set"; then
1076 echo $ac_n "(cached) $ac_c" 1>&4
1077 else
1078 cat > conftest.S <<EOF
1079 #include "confdefs.h"
1080 /* Nothing whatsoever. */
1082 if ${CC-cc} $CFLAGS -c conftest.S 2>/dev/null; then
1083 libc_cv_need_minus_P=no
1084 else
1085 libc_cv_need_minus_P=yes
1087 rm -f conftest*
1090 echo "$ac_t""$libc_cv_need_minus_P" 1>&4
1091 if test $libc_cv_need_minus_P = yes; then
1092 config_vars="$config_vars
1093 asm-CPPFLAGS = -P # The assembler can't grok cpp's # line directives."
1096 # sysdeps configure fragments may set these with files to be linked below.
1097 libc_link_dests=
1098 libc_link_sources=
1100 # Iterate over all the sysdep directories we will use, running their
1101 # configure fragments, and looking for a uname implementation.
1102 uname=
1103 for dir in $sysnames; do
1104 if test -r $sysdep_dir/$dir/configure; then
1105 echo "$ac_t""running configure fragment for $dir" 1>&4
1106 . $sysdep_dir/$dir/configure
1108 if test -z "$uname"; then
1109 { test -r $sysdep_dir/$dir/uname.c || test -r $sysdep_dir/$dir/uname.S; } \
1110 && uname=$dir
1112 done
1116 # If we will use the generic uname implementation, we must figure out what
1117 # it will say by examining the system, and write the results in config-name.h.
1118 if test "$uname" = generic; then
1120 uname_sysname=`echo $config_os | sed 's/[0-9.]*$//'`
1121 if test $uname_sysname != $config_os; then
1122 config_release=`echo $config_os | sed s/$uname_sysname//`
1125 echo $ac_n "checking OS release for uname""... $ac_c" 1>&4
1126 if eval "test \"`echo '$''{'libc_cv_uname_release'+set}'`\" = set"; then
1127 echo $ac_n "(cached) $ac_c" 1>&4
1128 else
1129 kernel_release=`echo "$kernel_id" | sed 's/^[^0-9.]*\([0-9.]*\).*$/\1/'`
1130 if test x`echo "$config_release" | sed "s/^$kernel_release//"` \
1131 != x$config_release; then
1132 # The configuration release is a substring of the kernel release.
1133 libc_cv_uname_release=$kernel_release
1134 elif test x$config_release != x; then
1135 libc_cv_uname_release=$config_release
1136 elif test x$kernel_release != x; then
1137 libc_cv_uname_release=$kernel_release
1138 else
1139 libc_cv_uname_release=unknown
1143 echo "$ac_t""$libc_cv_uname_release" 1>&4
1144 uname_release="$libc_cv_uname_release"
1146 echo $ac_n "checking OS version for uname""... $ac_c" 1>&4
1147 if eval "test \"`echo '$''{'libc_cv_uname_version'+set}'`\" = set"; then
1148 echo $ac_n "(cached) $ac_c" 1>&4
1149 else
1150 kernel_version=`echo "$kernel_id" | sed 's/^[^#]*#\([0-9]*\).*$/\1/'`
1151 if test -n "$kernel_version"; then
1152 libc_cv_uname_version="$kernel_version"
1153 else
1154 libc_cv_uname_version=unknown
1158 echo "$ac_t""$libc_cv_uname_version" 1>&4
1159 uname_version="$libc_cv_uname_version"
1161 config_uname=config-name.h:config-name.in
1162 else
1163 # For non-generic uname, we don't need to create config-name.h at all.
1164 config_uname=
1168 if test $gnu_ld = yes; then
1169 cat >> confdefs.h <<\EOF
1170 #define HAVE_GNU_LD 1
1174 if test $gnu_as = yes; then
1175 cat >> confdefs.h <<\EOF
1176 #define HAVE_GNU_AS 1
1180 if test $elf = yes; then
1181 cat >> confdefs.h <<\EOF
1182 #define HAVE_ELF 1
1186 if test $weak = yes; then
1187 cat >> confdefs.h <<\EOF
1188 #define HAVE_WEAK_SYMBOLS 1
1194 if test $shared = default; then
1195 if test $gnu_ld = yes; then
1196 shared=$elf
1203 if test "`(cd $srcdir; pwd)`" = "`pwd`"; then
1204 config_makefile=
1205 else
1206 config_makefile=Makefile
1209 trap '' 1 2 15
1210 cat > confcache <<\EOF
1211 # This file is a shell script that caches the results of configure
1212 # tests run on this system so they can be shared between configure
1213 # scripts and configure runs. It is not useful on other systems.
1214 # If it contains results you don't want to keep, you may remove or edit it.
1216 # By default, configure uses ./config.cache as the cache file,
1217 # creating it if it does not exist already. You can give configure
1218 # the --cache-file=FILE option to use a different cache file; that is
1219 # what configure does when it calls configure scripts in
1220 # subdirectories, so they share the cache.
1221 # Giving --cache-file=/dev/null disables caching, for debugging configure.
1222 # config.status only pays attention to the cache file if you give it the
1223 # --recheck option to rerun configure.
1226 # Ultrix sh set writes to stderr and can't be redirected directly,
1227 # and sets the high bit in the cache file unless we assign to the vars.
1228 (set) 2>&1 |
1229 sed -n "s/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=\${\1='\2'}/p" \
1230 >> confcache
1231 if cmp -s $cache_file confcache; then
1233 else
1234 if test -w $cache_file; then
1235 echo "updating cache $cache_file"
1236 cat confcache > $cache_file
1237 else
1238 echo "not updating unwritable cache $cache_file"
1241 rm -f confcache
1243 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
1245 test "x$prefix" = xNONE && prefix=$ac_default_prefix
1246 # Let make expand exec_prefix.
1247 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
1249 # Any assignment to VPATH causes Sun make to only execute
1250 # the first set of double-colon rules, so remove it if not needed.
1251 # If there is a colon in the path, we need to keep it.
1252 if test "x$srcdir" = x.; then
1253 ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
1256 trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
1258 DEFS=-DHAVE_CONFIG_H
1260 # Without the "./", some shells look in PATH for config.status.
1261 : ${CONFIG_STATUS=./config.status}
1263 echo creating $CONFIG_STATUS
1264 rm -f $CONFIG_STATUS
1265 cat > $CONFIG_STATUS <<EOF
1266 #! /bin/sh
1267 # Generated automatically by configure.
1268 # Run this file to recreate the current configuration.
1269 # This directory was configured as follows,
1270 # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
1272 # $0 $ac_configure_args
1274 # Compiler output produced by configure, useful for debugging
1275 # configure, is in ./config.log if it exists.
1277 ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
1278 for ac_option
1280 case "\$ac_option" in
1281 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
1282 echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
1283 exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
1284 -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
1285 echo "$CONFIG_STATUS generated by autoconf version 2.2"
1286 exit 0 ;;
1287 -help | --help | --hel | --he | --h)
1288 echo "\$ac_cs_usage"; exit 0 ;;
1289 *) echo "\$ac_cs_usage"; exit 1 ;;
1290 esac
1291 done
1293 ac_given_srcdir=$srcdir
1294 ac_given_INSTALL="$INSTALL"
1296 trap 'rm -fr `echo config.make ${config_makefile} ${config_uname} config.h | tr : " "` conftest*; exit 1' 1 2 15
1298 # Protect against being on the right side of a sed subst in config.status.
1299 sed 's/%@/@@/; s/@%/@@/; s/%g$/@g/; /@g$/s/[\\\\&%]/\\\\&/g;
1300 s/@@/%@/; s/@@/@%/; s/@g$/%g/' > conftest.subs <<\CEOF
1301 $ac_vpsub
1302 $extrasub
1303 s%@CFLAGS@%$CFLAGS%g
1304 s%@CPPFLAGS@%$CPPFLAGS%g
1305 s%@CXXFLAGS@%$CXXFLAGS%g
1306 s%@DEFS@%$DEFS%g
1307 s%@LDFLAGS@%$LDFLAGS%g
1308 s%@LIBS@%$LIBS%g
1309 s%@exec_prefix@%$exec_prefix%g
1310 s%@prefix@%$prefix%g
1311 s%@program_transform_name@%$program_transform_name%g
1312 s%@host@%$host%g
1313 s%@host_alias@%$host_alias%g
1314 s%@host_cpu@%$host_cpu%g
1315 s%@host_vendor@%$host_vendor%g
1316 s%@host_os@%$host_os%g
1317 s%@sysnames@%$sysnames%g
1318 s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
1319 s%@INSTALL_DATA@%$INSTALL_DATA%g
1320 s%@build@%$build%g
1321 s%@build_alias@%$build_alias%g
1322 s%@build_cpu@%$build_cpu%g
1323 s%@build_vendor@%$build_vendor%g
1324 s%@build_os@%$build_os%g
1325 s%@CC@%$CC%g
1326 s%@AR@%$AR%g
1327 s%@RANLIB@%$RANLIB%g
1328 s%@CPP@%$CPP%g
1329 s%@uname_sysname@%$uname_sysname%g
1330 s%@uname_release@%$uname_release%g
1331 s%@uname_version@%$uname_version%g
1332 s%@gnu_ld@%$gnu_ld%g
1333 s%@gnu_as@%$gnu_as%g
1334 s%@elf@%$elf%g
1335 s%@weak@%$weak%g
1336 s%@shared@%$shared%g
1337 s%@profile@%$profile%g
1338 s%@omitfp@%$omitfp%g
1340 CEOF
1342 cat >> $CONFIG_STATUS <<EOF
1344 CONFIG_FILES=\${CONFIG_FILES-"config.make ${config_makefile} ${config_uname}"}
1346 cat >> $CONFIG_STATUS <<\EOF
1347 for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
1348 # Support "outfile[:infile]", defaulting infile="outfile.in".
1349 case "$ac_file" in
1350 *:*) ac_file_in=`echo "$ac_file"|sed 's%.*:%%'`
1351 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
1352 *) ac_file_in="${ac_file}.in" ;;
1353 esac
1355 # Adjust relative srcdir, etc. for subdirectories.
1357 # Remove last slash and all that follows it. Not all systems have dirname.
1358 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
1359 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
1360 # The file is in a subdirectory.
1361 test ! -d "$ac_dir" && mkdir "$ac_dir"
1362 ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
1363 # A "../" for each directory in $ac_dir_suffix.
1364 ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
1365 else
1366 ac_dir_suffix= ac_dots=
1369 case "$ac_given_srcdir" in
1370 .) srcdir=.
1371 if test -z "$ac_dots"; then top_srcdir=.
1372 else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
1373 /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
1374 *) # Relative path.
1375 srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
1376 top_srcdir="$ac_dots$ac_given_srcdir" ;;
1377 esac
1379 case "$ac_given_INSTALL" in
1380 [/$]*) INSTALL="$ac_given_INSTALL" ;;
1381 *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
1382 esac
1383 echo creating "$ac_file"
1384 rm -f "$ac_file"
1385 configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
1386 case "$ac_file" in
1387 *Makefile*) ac_comsub="1i\\
1388 # $configure_input" ;;
1389 *) ac_comsub= ;;
1390 esac
1391 sed -e "$ac_comsub
1392 s%@configure_input@%$configure_input%g
1393 s%@srcdir@%$srcdir%g
1394 s%@top_srcdir@%$top_srcdir%g
1395 s%@INSTALL@%$INSTALL%g
1396 " -f conftest.subs $ac_given_srcdir/$ac_file_in > $ac_file
1397 fi; done
1398 rm -f conftest.subs
1400 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
1401 # NAME is the cpp macro being defined and VALUE is the value it is being given.
1403 # ac_d sets the value in "#define NAME VALUE" lines.
1404 ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)'
1405 ac_dB='\([ ][ ]*\)[^ ]*%\1#\2'
1406 ac_dC='\3'
1407 ac_dD='%g'
1408 # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
1409 ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
1410 ac_uB='\([ ]\)%\1#\2define\3'
1411 ac_uC=' '
1412 ac_uD='\4%g'
1413 # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
1414 ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
1415 ac_eB='$%\1#\2define\3'
1416 ac_eC=' '
1417 ac_eD='%g'
1419 CONFIG_HEADERS=${CONFIG_HEADERS-"config.h"}
1420 for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
1421 # Support "outfile[:infile]", defaulting infile="outfile.in".
1422 case "$ac_file" in
1423 *:*) ac_file_in=`echo "$ac_file"|sed 's%.*:%%'`
1424 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
1425 *) ac_file_in="${ac_file}.in" ;;
1426 esac
1428 echo creating $ac_file
1430 rm -f conftest.frag conftest.in conftest.out
1431 cp $ac_given_srcdir/$ac_file_in conftest.in
1435 # Transform confdefs.h into a sed script conftest.vals that substitutes
1436 # the proper values into config.h.in to produce config.h. And first:
1437 # Protect against being on the right side of a sed subst in config.status.
1438 # Protect against being in an unquoted here document in config.status.
1439 rm -f conftest.vals
1440 cat > conftest.hdr <<\EOF
1441 s/[\\&%]/\\&/g
1442 s%[\\$`]%\\&%g
1443 s%#define \([A-Za-z_][A-Za-z0-9_]*\) \(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
1444 s%ac_d%ac_u%gp
1445 s%ac_u%ac_e%gp
1447 sed -n -f conftest.hdr confdefs.h > conftest.vals
1448 rm -f conftest.hdr
1450 # This sed command replaces #undef with comments. This is necessary, for
1451 # example, in the case of _POSIX_SOURCE, which is predefined and required
1452 # on some systems where configure will not decide to define it.
1453 cat >> conftest.vals <<\EOF
1454 s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
1457 # Break up conftest.vals because some shells have a limit on
1458 # the size of here documents, and old seds have small limits too.
1459 # Maximum number of lines to put in a single here document.
1460 ac_max_here_lines=12
1462 rm -f conftest.tail
1463 while :
1465 ac_lines=`grep -c . conftest.vals`
1466 # grep -c gives empty output for an empty file on some AIX systems.
1467 if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
1468 # Write a limited-size here document to conftest.frag.
1469 echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
1470 sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
1471 echo 'CEOF
1472 sed -f conftest.frag conftest.in > conftest.out
1473 rm -f conftest.in
1474 mv conftest.out conftest.in
1475 ' >> $CONFIG_STATUS
1476 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
1477 rm -f conftest.vals
1478 mv conftest.tail conftest.vals
1479 done
1480 rm -f conftest.vals
1482 cat >> $CONFIG_STATUS <<\EOF
1483 rm -f conftest.frag conftest.h
1484 echo "/* $ac_file. Generated automatically by configure. */" > conftest.h
1485 cat conftest.in >> conftest.h
1486 rm -f conftest.in
1487 if cmp -s $ac_file conftest.h 2>/dev/null; then
1488 echo "$ac_file is unchanged"
1489 rm -f conftest.h
1490 else
1491 rm -f $ac_file
1492 mv conftest.h $ac_file
1494 fi; done
1498 cat >> $CONFIG_STATUS <<EOF
1499 ac_sources="`echo $libc_link_sources`"
1500 ac_dests="`echo $libc_link_dests`"
1503 cat >> $CONFIG_STATUS <<\EOF
1504 srcdir=$ac_given_srcdir
1505 while test -n "$ac_sources"; do
1506 set $ac_dests; ac_dest=$1; shift; ac_dests=$*
1507 set $ac_sources; ac_source=$1; shift; ac_sources=$*
1509 echo "linking $srcdir/$ac_source to $ac_dest"
1511 if test ! -r $srcdir/$ac_source; then
1512 { echo "configure: error: $srcdir/$ac_source: File not found" 1>&2; exit 1; }
1514 rm -f $ac_dest
1516 # Make relative symlinks.
1517 # Remove last slash and all that follows it. Not all systems have dirname.
1518 ac_dest_dir=`echo $ac_dest|sed 's%/[^/][^/]*$%%'`
1519 if test "$ac_dest_dir" != "$ac_dest" && test "$ac_dest_dir" != .; then
1520 # The dest file is in a subdirectory.
1521 test ! -d "$ac_dest_dir" && mkdir "$ac_dest_dir"
1522 ac_dest_dir_suffix="/`echo $ac_dest_dir|sed 's%^\./%%'`"
1523 # A "../" for each directory in $ac_dest_dir_suffix.
1524 ac_dots=`echo $ac_dest_dir_suffix|sed 's%/[^/]*%../%g'`
1525 else
1526 ac_dest_dir_suffix= ac_dots=
1529 case "$srcdir" in
1530 [/$]*) ac_rel_source="$srcdir/$ac_source" ;;
1531 *) ac_rel_source="$ac_dots$srcdir/$ac_source" ;;
1532 esac
1534 # Make a symlink if possible; otherwise try a hard link.
1535 if ln -s $ac_rel_source $ac_dest 2>/dev/null ||
1536 ln $srcdir/$ac_source $ac_dest; then :
1537 else
1538 { echo "configure: error: can not link $ac_dest to $srcdir/$ac_source" 1>&2; exit 1; }
1540 done
1542 cat >> $CONFIG_STATUS <<EOF
1543 echo '$config_vars' >> config.make
1545 cat >> $CONFIG_STATUS <<\EOF
1547 exit 0
1549 chmod +x $CONFIG_STATUS
1550 rm -fr confdefs* $ac_clean_files
1551 test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1