Remove ``-W -Wall'' from top-level Makefile/configure.
[binutils.git] / binutils / configure
blob43fe8a69cebca311201475639d3486e222300913
1 #! /bin/sh
3 # Guess values for system-dependent variables and create Makefiles.
4 # Generated automatically using autoconf version 2.13
5 # Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
7 # This configure script is free software; the Free Software Foundation
8 # gives unlimited permission to copy, distribute and modify it.
10 # Defaults:
11 ac_help=
12 ac_default_prefix=/usr/local
13 # Any additions from configure.in:
14 ac_help="$ac_help
15 --enable-shared[=PKGS] build shared libraries [default=yes]"
16 ac_help="$ac_help
17 --enable-static[=PKGS] build static libraries [default=yes]"
18 ac_help="$ac_help
19 --enable-fast-install[=PKGS] optimize for fast installation [default=yes]"
20 ac_help="$ac_help
21 --with-gnu-ld assume the C compiler uses GNU ld [default=no]"
22 ac_help="$ac_help
23 --disable-libtool-lock avoid locking (might break parallel builds)"
24 ac_help="$ac_help
25 --enable-targets alternative target configurations"
26 ac_help="$ac_help
27 --enable-commonbfdlib build shared BFD/opcodes/libiberty library"
28 ac_help="$ac_help
29 --enable-build-warnings Enable build-time compiler warnings if gcc is used"
30 ac_help="$ac_help
31 --disable-nls do not use Native Language Support"
32 ac_help="$ac_help
33 --with-included-gettext use the GNU gettext library included here"
34 ac_help="$ac_help
35 --enable-maintainer-mode enable make rules and dependencies not useful
36 (and sometimes confusing) to the casual installer"
38 # Initialize some variables set by options.
39 # The variables have the same names as the options, with
40 # dashes changed to underlines.
41 build=NONE
42 cache_file=./config.cache
43 exec_prefix=NONE
44 host=NONE
45 no_create=
46 nonopt=NONE
47 no_recursion=
48 prefix=NONE
49 program_prefix=NONE
50 program_suffix=NONE
51 program_transform_name=s,x,x,
52 silent=
53 site=
54 sitefile=
55 srcdir=
56 target=NONE
57 verbose=
58 x_includes=NONE
59 x_libraries=NONE
60 bindir='${exec_prefix}/bin'
61 sbindir='${exec_prefix}/sbin'
62 libexecdir='${exec_prefix}/libexec'
63 datadir='${prefix}/share'
64 sysconfdir='${prefix}/etc'
65 sharedstatedir='${prefix}/com'
66 localstatedir='${prefix}/var'
67 libdir='${exec_prefix}/lib'
68 includedir='${prefix}/include'
69 oldincludedir='/usr/include'
70 infodir='${prefix}/info'
71 mandir='${prefix}/man'
73 # Initialize some other variables.
74 subdirs=
75 MFLAGS= MAKEFLAGS=
76 SHELL=${CONFIG_SHELL-/bin/sh}
77 # Maximum number of lines to put in a shell here document.
78 ac_max_here_lines=12
80 ac_prev=
81 for ac_option
84 # If the previous option needs an argument, assign it.
85 if test -n "$ac_prev"; then
86 eval "$ac_prev=\$ac_option"
87 ac_prev=
88 continue
91 case "$ac_option" in
92 -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
93 *) ac_optarg= ;;
94 esac
96 # Accept the important Cygnus configure options, so we can diagnose typos.
98 case "$ac_option" in
100 -bindir | --bindir | --bindi | --bind | --bin | --bi)
101 ac_prev=bindir ;;
102 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
103 bindir="$ac_optarg" ;;
105 -build | --build | --buil | --bui | --bu)
106 ac_prev=build ;;
107 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
108 build="$ac_optarg" ;;
110 -cache-file | --cache-file | --cache-fil | --cache-fi \
111 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
112 ac_prev=cache_file ;;
113 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
114 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
115 cache_file="$ac_optarg" ;;
117 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
118 ac_prev=datadir ;;
119 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
120 | --da=*)
121 datadir="$ac_optarg" ;;
123 -disable-* | --disable-*)
124 ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
125 # Reject names that are not valid shell variable names.
126 if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
127 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
129 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
130 eval "enable_${ac_feature}=no" ;;
132 -enable-* | --enable-*)
133 ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
134 # Reject names that are not valid shell variable names.
135 if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
136 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
138 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
139 case "$ac_option" in
140 *=*) ;;
141 *) ac_optarg=yes ;;
142 esac
143 eval "enable_${ac_feature}='$ac_optarg'" ;;
145 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
146 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
147 | --exec | --exe | --ex)
148 ac_prev=exec_prefix ;;
149 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
150 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
151 | --exec=* | --exe=* | --ex=*)
152 exec_prefix="$ac_optarg" ;;
154 -gas | --gas | --ga | --g)
155 # Obsolete; use --with-gas.
156 with_gas=yes ;;
158 -help | --help | --hel | --he)
159 # Omit some internal or obsolete options to make the list less imposing.
160 # This message is too long to be a string in the A/UX 3.1 sh.
161 cat << EOF
162 Usage: configure [options] [host]
163 Options: [defaults in brackets after descriptions]
164 Configuration:
165 --cache-file=FILE cache test results in FILE
166 --help print this message
167 --no-create do not create output files
168 --quiet, --silent do not print \`checking...' messages
169 --site-file=FILE use FILE as the site file
170 --version print the version of autoconf that created configure
171 Directory and file names:
172 --prefix=PREFIX install architecture-independent files in PREFIX
173 [$ac_default_prefix]
174 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
175 [same as prefix]
176 --bindir=DIR user executables in DIR [EPREFIX/bin]
177 --sbindir=DIR system admin executables in DIR [EPREFIX/sbin]
178 --libexecdir=DIR program executables in DIR [EPREFIX/libexec]
179 --datadir=DIR read-only architecture-independent data in DIR
180 [PREFIX/share]
181 --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc]
182 --sharedstatedir=DIR modifiable architecture-independent data in DIR
183 [PREFIX/com]
184 --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var]
185 --libdir=DIR object code libraries in DIR [EPREFIX/lib]
186 --includedir=DIR C header files in DIR [PREFIX/include]
187 --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include]
188 --infodir=DIR info documentation in DIR [PREFIX/info]
189 --mandir=DIR man documentation in DIR [PREFIX/man]
190 --srcdir=DIR find the sources in DIR [configure dir or ..]
191 --program-prefix=PREFIX prepend PREFIX to installed program names
192 --program-suffix=SUFFIX append SUFFIX to installed program names
193 --program-transform-name=PROGRAM
194 run sed PROGRAM on installed program names
196 cat << EOF
197 Host type:
198 --build=BUILD configure for building on BUILD [BUILD=HOST]
199 --host=HOST configure for HOST [guessed]
200 --target=TARGET configure for TARGET [TARGET=HOST]
201 Features and packages:
202 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
203 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
204 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
205 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
206 --x-includes=DIR X include files are in DIR
207 --x-libraries=DIR X library files are in DIR
209 if test -n "$ac_help"; then
210 echo "--enable and --with options recognized:$ac_help"
212 exit 0 ;;
214 -host | --host | --hos | --ho)
215 ac_prev=host ;;
216 -host=* | --host=* | --hos=* | --ho=*)
217 host="$ac_optarg" ;;
219 -includedir | --includedir | --includedi | --included | --include \
220 | --includ | --inclu | --incl | --inc)
221 ac_prev=includedir ;;
222 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
223 | --includ=* | --inclu=* | --incl=* | --inc=*)
224 includedir="$ac_optarg" ;;
226 -infodir | --infodir | --infodi | --infod | --info | --inf)
227 ac_prev=infodir ;;
228 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
229 infodir="$ac_optarg" ;;
231 -libdir | --libdir | --libdi | --libd)
232 ac_prev=libdir ;;
233 -libdir=* | --libdir=* | --libdi=* | --libd=*)
234 libdir="$ac_optarg" ;;
236 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
237 | --libexe | --libex | --libe)
238 ac_prev=libexecdir ;;
239 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
240 | --libexe=* | --libex=* | --libe=*)
241 libexecdir="$ac_optarg" ;;
243 -localstatedir | --localstatedir | --localstatedi | --localstated \
244 | --localstate | --localstat | --localsta | --localst \
245 | --locals | --local | --loca | --loc | --lo)
246 ac_prev=localstatedir ;;
247 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
248 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
249 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
250 localstatedir="$ac_optarg" ;;
252 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
253 ac_prev=mandir ;;
254 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
255 mandir="$ac_optarg" ;;
257 -nfp | --nfp | --nf)
258 # Obsolete; use --without-fp.
259 with_fp=no ;;
261 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
262 | --no-cr | --no-c)
263 no_create=yes ;;
265 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
266 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
267 no_recursion=yes ;;
269 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
270 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
271 | --oldin | --oldi | --old | --ol | --o)
272 ac_prev=oldincludedir ;;
273 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
274 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
275 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
276 oldincludedir="$ac_optarg" ;;
278 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
279 ac_prev=prefix ;;
280 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
281 prefix="$ac_optarg" ;;
283 -program-prefix | --program-prefix | --program-prefi | --program-pref \
284 | --program-pre | --program-pr | --program-p)
285 ac_prev=program_prefix ;;
286 -program-prefix=* | --program-prefix=* | --program-prefi=* \
287 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
288 program_prefix="$ac_optarg" ;;
290 -program-suffix | --program-suffix | --program-suffi | --program-suff \
291 | --program-suf | --program-su | --program-s)
292 ac_prev=program_suffix ;;
293 -program-suffix=* | --program-suffix=* | --program-suffi=* \
294 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
295 program_suffix="$ac_optarg" ;;
297 -program-transform-name | --program-transform-name \
298 | --program-transform-nam | --program-transform-na \
299 | --program-transform-n | --program-transform- \
300 | --program-transform | --program-transfor \
301 | --program-transfo | --program-transf \
302 | --program-trans | --program-tran \
303 | --progr-tra | --program-tr | --program-t)
304 ac_prev=program_transform_name ;;
305 -program-transform-name=* | --program-transform-name=* \
306 | --program-transform-nam=* | --program-transform-na=* \
307 | --program-transform-n=* | --program-transform-=* \
308 | --program-transform=* | --program-transfor=* \
309 | --program-transfo=* | --program-transf=* \
310 | --program-trans=* | --program-tran=* \
311 | --progr-tra=* | --program-tr=* | --program-t=*)
312 program_transform_name="$ac_optarg" ;;
314 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
315 | -silent | --silent | --silen | --sile | --sil)
316 silent=yes ;;
318 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
319 ac_prev=sbindir ;;
320 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
321 | --sbi=* | --sb=*)
322 sbindir="$ac_optarg" ;;
324 -sharedstatedir | --sharedstatedir | --sharedstatedi \
325 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
326 | --sharedst | --shareds | --shared | --share | --shar \
327 | --sha | --sh)
328 ac_prev=sharedstatedir ;;
329 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
330 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
331 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
332 | --sha=* | --sh=*)
333 sharedstatedir="$ac_optarg" ;;
335 -site | --site | --sit)
336 ac_prev=site ;;
337 -site=* | --site=* | --sit=*)
338 site="$ac_optarg" ;;
340 -site-file | --site-file | --site-fil | --site-fi | --site-f)
341 ac_prev=sitefile ;;
342 -site-file=* | --site-file=* | --site-fil=* | --site-fi=* | --site-f=*)
343 sitefile="$ac_optarg" ;;
345 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
346 ac_prev=srcdir ;;
347 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
348 srcdir="$ac_optarg" ;;
350 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
351 | --syscon | --sysco | --sysc | --sys | --sy)
352 ac_prev=sysconfdir ;;
353 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
354 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
355 sysconfdir="$ac_optarg" ;;
357 -target | --target | --targe | --targ | --tar | --ta | --t)
358 ac_prev=target ;;
359 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
360 target="$ac_optarg" ;;
362 -v | -verbose | --verbose | --verbos | --verbo | --verb)
363 verbose=yes ;;
365 -version | --version | --versio | --versi | --vers)
366 echo "configure generated by autoconf version 2.13"
367 exit 0 ;;
369 -with-* | --with-*)
370 ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
371 # Reject names that are not valid shell variable names.
372 if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
373 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
375 ac_package=`echo $ac_package| sed 's/-/_/g'`
376 case "$ac_option" in
377 *=*) ;;
378 *) ac_optarg=yes ;;
379 esac
380 eval "with_${ac_package}='$ac_optarg'" ;;
382 -without-* | --without-*)
383 ac_package=`echo $ac_option|sed -e 's/-*without-//'`
384 # Reject names that are not valid shell variable names.
385 if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
386 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
388 ac_package=`echo $ac_package| sed 's/-/_/g'`
389 eval "with_${ac_package}=no" ;;
391 --x)
392 # Obsolete; use --with-x.
393 with_x=yes ;;
395 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
396 | --x-incl | --x-inc | --x-in | --x-i)
397 ac_prev=x_includes ;;
398 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
399 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
400 x_includes="$ac_optarg" ;;
402 -x-libraries | --x-libraries | --x-librarie | --x-librari \
403 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
404 ac_prev=x_libraries ;;
405 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
406 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
407 x_libraries="$ac_optarg" ;;
409 -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
413 if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
414 echo "configure: warning: $ac_option: invalid host type" 1>&2
416 if test "x$nonopt" != xNONE; then
417 { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
419 nonopt="$ac_option"
422 esac
423 done
425 if test -n "$ac_prev"; then
426 { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
429 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
431 # File descriptor usage:
432 # 0 standard input
433 # 1 file creation
434 # 2 errors and warnings
435 # 3 some systems may open it to /dev/tty
436 # 4 used on the Kubota Titan
437 # 6 checking for... messages and results
438 # 5 compiler messages saved in config.log
439 if test "$silent" = yes; then
440 exec 6>/dev/null
441 else
442 exec 6>&1
444 exec 5>./config.log
446 echo "\
447 This file contains any messages produced by compilers while
448 running configure, to aid debugging if configure makes a mistake.
449 " 1>&5
451 # Strip out --no-create and --no-recursion so they do not pile up.
452 # Also quote any args containing shell metacharacters.
453 ac_configure_args=
454 for ac_arg
456 case "$ac_arg" in
457 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
458 | --no-cr | --no-c) ;;
459 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
460 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
461 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
462 ac_configure_args="$ac_configure_args '$ac_arg'" ;;
463 *) ac_configure_args="$ac_configure_args $ac_arg" ;;
464 esac
465 done
467 # NLS nuisances.
468 # Only set these to C if already set. These must not be set unconditionally
469 # because not all systems understand e.g. LANG=C (notably SCO).
470 # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
471 # Non-C LC_CTYPE values break the ctype check.
472 if test "${LANG+set}" = set; then LANG=C; export LANG; fi
473 if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
474 if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
475 if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi
477 # confdefs.h avoids OS command line length limits that DEFS can exceed.
478 rm -rf conftest* confdefs.h
479 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
480 echo > confdefs.h
482 # A filename unique to this package, relative to the directory that
483 # configure is in, which we can look for to find out if srcdir is correct.
484 ac_unique_file=ar.c
486 # Find the source files, if location was not specified.
487 if test -z "$srcdir"; then
488 ac_srcdir_defaulted=yes
489 # Try the directory containing this script, then its parent.
490 ac_prog=$0
491 ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
492 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
493 srcdir=$ac_confdir
494 if test ! -r $srcdir/$ac_unique_file; then
495 srcdir=..
497 else
498 ac_srcdir_defaulted=no
500 if test ! -r $srcdir/$ac_unique_file; then
501 if test "$ac_srcdir_defaulted" = yes; then
502 { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
503 else
504 { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
507 srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
509 # Prefer explicitly selected file to automatically selected ones.
510 if test -z "$sitefile"; then
511 if test -z "$CONFIG_SITE"; then
512 if test "x$prefix" != xNONE; then
513 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
514 else
515 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
518 else
519 CONFIG_SITE="$sitefile"
521 for ac_site_file in $CONFIG_SITE; do
522 if test -r "$ac_site_file"; then
523 echo "loading site script $ac_site_file"
524 . "$ac_site_file"
526 done
528 if test -r "$cache_file"; then
529 echo "loading cache $cache_file"
530 . $cache_file
531 else
532 echo "creating cache $cache_file"
533 > $cache_file
536 ac_ext=c
537 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
538 ac_cpp='$CPP $CPPFLAGS'
539 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
540 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
541 cross_compiling=$ac_cv_prog_cc_cross
543 ac_exeext=
544 ac_objext=o
545 if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
546 # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
547 if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
548 ac_n= ac_c='
549 ' ac_t=' '
550 else
551 ac_n=-n ac_c= ac_t=
553 else
554 ac_n= ac_c='\c' ac_t=
559 ac_aux_dir=
560 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
561 if test -f $ac_dir/install-sh; then
562 ac_aux_dir=$ac_dir
563 ac_install_sh="$ac_aux_dir/install-sh -c"
564 break
565 elif test -f $ac_dir/install.sh; then
566 ac_aux_dir=$ac_dir
567 ac_install_sh="$ac_aux_dir/install.sh -c"
568 break
570 done
571 if test -z "$ac_aux_dir"; then
572 { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
574 ac_config_guess=$ac_aux_dir/config.guess
575 ac_config_sub=$ac_aux_dir/config.sub
576 ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
579 # Do some error checking and defaulting for the host and target type.
580 # The inputs are:
581 # configure --host=HOST --target=TARGET --build=BUILD NONOPT
583 # The rules are:
584 # 1. You are not allowed to specify --host, --target, and nonopt at the
585 # same time.
586 # 2. Host defaults to nonopt.
587 # 3. If nonopt is not specified, then host defaults to the current host,
588 # as determined by config.guess.
589 # 4. Target and build default to nonopt.
590 # 5. If nonopt is not specified, then target and build default to host.
592 # The aliases save the names the user supplied, while $host etc.
593 # will get canonicalized.
594 case $host---$target---$nonopt in
595 NONE---*---* | *---NONE---* | *---*---NONE) ;;
596 *) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;;
597 esac
600 # Make sure we can run config.sub.
601 if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
602 else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
605 echo $ac_n "checking host system type""... $ac_c" 1>&6
606 echo "configure:607: checking host system type" >&5
608 host_alias=$host
609 case "$host_alias" in
610 NONE)
611 case $nonopt in
612 NONE)
613 if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
614 else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
615 fi ;;
616 *) host_alias=$nonopt ;;
617 esac ;;
618 esac
620 host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
621 host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
622 host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
623 host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
624 echo "$ac_t""$host" 1>&6
626 echo $ac_n "checking target system type""... $ac_c" 1>&6
627 echo "configure:628: checking target system type" >&5
629 target_alias=$target
630 case "$target_alias" in
631 NONE)
632 case $nonopt in
633 NONE) target_alias=$host_alias ;;
634 *) target_alias=$nonopt ;;
635 esac ;;
636 esac
638 target=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $target_alias`
639 target_cpu=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
640 target_vendor=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
641 target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
642 echo "$ac_t""$target" 1>&6
644 echo $ac_n "checking build system type""... $ac_c" 1>&6
645 echo "configure:646: checking build system type" >&5
647 build_alias=$build
648 case "$build_alias" in
649 NONE)
650 case $nonopt in
651 NONE) build_alias=$host_alias ;;
652 *) build_alias=$nonopt ;;
653 esac ;;
654 esac
656 build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias`
657 build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
658 build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
659 build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
660 echo "$ac_t""$build" 1>&6
662 test "$host_alias" != "$target_alias" &&
663 test "$program_prefix$program_suffix$program_transform_name" = \
664 NONENONEs,x,x, &&
665 program_prefix=${target_alias}-
668 # Find a good install program. We prefer a C program (faster),
669 # so one script is as good as another. But avoid the broken or
670 # incompatible versions:
671 # SysV /etc/install, /usr/sbin/install
672 # SunOS /usr/etc/install
673 # IRIX /sbin/install
674 # AIX /bin/install
675 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
676 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
677 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
678 # ./install, which can be erroneously created by make from ./install.sh.
679 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
680 echo "configure:681: checking for a BSD compatible install" >&5
681 if test -z "$INSTALL"; then
682 if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
683 echo $ac_n "(cached) $ac_c" 1>&6
684 else
685 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":"
686 for ac_dir in $PATH; do
687 # Account for people who put trailing slashes in PATH elements.
688 case "$ac_dir/" in
689 /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
691 # OSF1 and SCO ODT 3.0 have their own names for install.
692 # Don't use installbsd from OSF since it installs stuff as root
693 # by default.
694 for ac_prog in ginstall scoinst install; do
695 if test -f $ac_dir/$ac_prog; then
696 if test $ac_prog = install &&
697 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
698 # AIX install. It has an incompatible calling convention.
700 else
701 ac_cv_path_install="$ac_dir/$ac_prog -c"
702 break 2
705 done
707 esac
708 done
709 IFS="$ac_save_IFS"
712 if test "${ac_cv_path_install+set}" = set; then
713 INSTALL="$ac_cv_path_install"
714 else
715 # As a last resort, use the slow shell script. We don't cache a
716 # path for INSTALL within a source directory, because that will
717 # break other packages using the cache if that directory is
718 # removed, or if the path is relative.
719 INSTALL="$ac_install_sh"
722 echo "$ac_t""$INSTALL" 1>&6
724 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
725 # It thinks the first close brace ends the variable substitution.
726 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
728 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
730 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
732 echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
733 echo "configure:734: checking whether build environment is sane" >&5
734 # Just in case
735 sleep 1
736 echo timestamp > conftestfile
737 # Do `set' in a subshell so we don't clobber the current shell's
738 # arguments. Must try -L first in case configure is actually a
739 # symlink; some systems play weird games with the mod time of symlinks
740 # (eg FreeBSD returns the mod time of the symlink's containing
741 # directory).
742 if (
743 set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
744 if test "$*" = "X"; then
745 # -L didn't work.
746 set X `ls -t $srcdir/configure conftestfile`
748 if test "$*" != "X $srcdir/configure conftestfile" \
749 && test "$*" != "X conftestfile $srcdir/configure"; then
751 # If neither matched, then we have a broken ls. This can happen
752 # if, for instance, CONFIG_SHELL is bash and it inherits a
753 # broken ls alias from the environment. This has actually
754 # happened. Such a system could not be considered "sane".
755 { echo "configure: error: ls -t appears to fail. Make sure there is not a broken
756 alias in your environment" 1>&2; exit 1; }
759 test "$2" = conftestfile
761 then
762 # Ok.
764 else
765 { echo "configure: error: newly created file is older than distributed files!
766 Check your system clock" 1>&2; exit 1; }
768 rm -f conftest*
769 echo "$ac_t""yes" 1>&6
770 if test "$program_transform_name" = s,x,x,; then
771 program_transform_name=
772 else
773 # Double any \ or $. echo might interpret backslashes.
774 cat <<\EOF_SED > conftestsed
775 s,\\,\\\\,g; s,\$,$$,g
776 EOF_SED
777 program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
778 rm -f conftestsed
780 test "$program_prefix" != NONE &&
781 program_transform_name="s,^,${program_prefix},; $program_transform_name"
782 # Use a double $ so make ignores it.
783 test "$program_suffix" != NONE &&
784 program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
786 # sed with no file args requires a program.
787 test "$program_transform_name" = "" && program_transform_name="s,x,x,"
789 echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
790 echo "configure:791: checking whether ${MAKE-make} sets \${MAKE}" >&5
791 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
792 if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
793 echo $ac_n "(cached) $ac_c" 1>&6
794 else
795 cat > conftestmake <<\EOF
796 all:
797 @echo 'ac_maketemp="${MAKE}"'
799 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
800 eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
801 if test -n "$ac_maketemp"; then
802 eval ac_cv_prog_make_${ac_make}_set=yes
803 else
804 eval ac_cv_prog_make_${ac_make}_set=no
806 rm -f conftestmake
808 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
809 echo "$ac_t""yes" 1>&6
810 SET_MAKE=
811 else
812 echo "$ac_t""no" 1>&6
813 SET_MAKE="MAKE=${MAKE-make}"
817 PACKAGE=binutils
819 VERSION=2.9.5
821 if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
822 { echo "configure: error: source directory already configured; run "make distclean" there first" 1>&2; exit 1; }
824 cat >> confdefs.h <<EOF
825 #define PACKAGE "$PACKAGE"
828 cat >> confdefs.h <<EOF
829 #define VERSION "$VERSION"
834 missing_dir=`cd $ac_aux_dir && pwd`
835 echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
836 echo "configure:837: checking for working aclocal" >&5
837 # Run test in a subshell; some versions of sh will print an error if
838 # an executable is not found, even if stderr is redirected.
839 # Redirect stdin to placate older versions of autoconf. Sigh.
840 if (aclocal --version) < /dev/null > /dev/null 2>&1; then
841 ACLOCAL=aclocal
842 echo "$ac_t""found" 1>&6
843 else
844 ACLOCAL="$missing_dir/missing aclocal"
845 echo "$ac_t""missing" 1>&6
848 echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
849 echo "configure:850: checking for working autoconf" >&5
850 # Run test in a subshell; some versions of sh will print an error if
851 # an executable is not found, even if stderr is redirected.
852 # Redirect stdin to placate older versions of autoconf. Sigh.
853 if (autoconf --version) < /dev/null > /dev/null 2>&1; then
854 AUTOCONF=autoconf
855 echo "$ac_t""found" 1>&6
856 else
857 AUTOCONF="$missing_dir/missing autoconf"
858 echo "$ac_t""missing" 1>&6
861 echo $ac_n "checking for working automake""... $ac_c" 1>&6
862 echo "configure:863: checking for working automake" >&5
863 # Run test in a subshell; some versions of sh will print an error if
864 # an executable is not found, even if stderr is redirected.
865 # Redirect stdin to placate older versions of autoconf. Sigh.
866 if (automake --version) < /dev/null > /dev/null 2>&1; then
867 AUTOMAKE=automake
868 echo "$ac_t""found" 1>&6
869 else
870 AUTOMAKE="$missing_dir/missing automake"
871 echo "$ac_t""missing" 1>&6
874 echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
875 echo "configure:876: checking for working autoheader" >&5
876 # Run test in a subshell; some versions of sh will print an error if
877 # an executable is not found, even if stderr is redirected.
878 # Redirect stdin to placate older versions of autoconf. Sigh.
879 if (autoheader --version) < /dev/null > /dev/null 2>&1; then
880 AUTOHEADER=autoheader
881 echo "$ac_t""found" 1>&6
882 else
883 AUTOHEADER="$missing_dir/missing autoheader"
884 echo "$ac_t""missing" 1>&6
887 echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
888 echo "configure:889: checking for working makeinfo" >&5
889 # Run test in a subshell; some versions of sh will print an error if
890 # an executable is not found, even if stderr is redirected.
891 # Redirect stdin to placate older versions of autoconf. Sigh.
892 if (makeinfo --version) < /dev/null > /dev/null 2>&1; then
893 MAKEINFO=makeinfo
894 echo "$ac_t""found" 1>&6
895 else
896 MAKEINFO="$missing_dir/missing makeinfo"
897 echo "$ac_t""missing" 1>&6
902 # Check whether --enable-shared or --disable-shared was given.
903 if test "${enable_shared+set}" = set; then
904 enableval="$enable_shared"
905 p=${PACKAGE-default}
906 case "$enableval" in
907 yes) enable_shared=yes ;;
908 no) enable_shared=no ;;
910 enable_shared=no
911 # Look at the argument we got. We use all the common list separators.
912 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
913 for pkg in $enableval; do
914 if test "X$pkg" = "X$p"; then
915 enable_shared=yes
917 done
918 IFS="$ac_save_ifs"
920 esac
921 else
922 enable_shared=yes
925 # Check whether --enable-static or --disable-static was given.
926 if test "${enable_static+set}" = set; then
927 enableval="$enable_static"
928 p=${PACKAGE-default}
929 case "$enableval" in
930 yes) enable_static=yes ;;
931 no) enable_static=no ;;
933 enable_static=no
934 # Look at the argument we got. We use all the common list separators.
935 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
936 for pkg in $enableval; do
937 if test "X$pkg" = "X$p"; then
938 enable_static=yes
940 done
941 IFS="$ac_save_ifs"
943 esac
944 else
945 enable_static=yes
948 # Check whether --enable-fast-install or --disable-fast-install was given.
949 if test "${enable_fast_install+set}" = set; then
950 enableval="$enable_fast_install"
951 p=${PACKAGE-default}
952 case "$enableval" in
953 yes) enable_fast_install=yes ;;
954 no) enable_fast_install=no ;;
956 enable_fast_install=no
957 # Look at the argument we got. We use all the common list separators.
958 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
959 for pkg in $enableval; do
960 if test "X$pkg" = "X$p"; then
961 enable_fast_install=yes
963 done
964 IFS="$ac_save_ifs"
966 esac
967 else
968 enable_fast_install=yes
971 # Extract the first word of "ranlib", so it can be a program name with args.
972 set dummy ranlib; ac_word=$2
973 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
974 echo "configure:975: checking for $ac_word" >&5
975 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
976 echo $ac_n "(cached) $ac_c" 1>&6
977 else
978 if test -n "$RANLIB"; then
979 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
980 else
981 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
982 ac_dummy="$PATH"
983 for ac_dir in $ac_dummy; do
984 test -z "$ac_dir" && ac_dir=.
985 if test -f $ac_dir/$ac_word; then
986 ac_cv_prog_RANLIB="ranlib"
987 break
989 done
990 IFS="$ac_save_ifs"
991 test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
994 RANLIB="$ac_cv_prog_RANLIB"
995 if test -n "$RANLIB"; then
996 echo "$ac_t""$RANLIB" 1>&6
997 else
998 echo "$ac_t""no" 1>&6
1001 # Extract the first word of "gcc", so it can be a program name with args.
1002 set dummy gcc; ac_word=$2
1003 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1004 echo "configure:1005: checking for $ac_word" >&5
1005 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
1006 echo $ac_n "(cached) $ac_c" 1>&6
1007 else
1008 if test -n "$CC"; then
1009 ac_cv_prog_CC="$CC" # Let the user override the test.
1010 else
1011 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1012 ac_dummy="$PATH"
1013 for ac_dir in $ac_dummy; do
1014 test -z "$ac_dir" && ac_dir=.
1015 if test -f $ac_dir/$ac_word; then
1016 ac_cv_prog_CC="gcc"
1017 break
1019 done
1020 IFS="$ac_save_ifs"
1023 CC="$ac_cv_prog_CC"
1024 if test -n "$CC"; then
1025 echo "$ac_t""$CC" 1>&6
1026 else
1027 echo "$ac_t""no" 1>&6
1030 if test -z "$CC"; then
1031 # Extract the first word of "cc", so it can be a program name with args.
1032 set dummy cc; ac_word=$2
1033 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1034 echo "configure:1035: checking for $ac_word" >&5
1035 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
1036 echo $ac_n "(cached) $ac_c" 1>&6
1037 else
1038 if test -n "$CC"; then
1039 ac_cv_prog_CC="$CC" # Let the user override the test.
1040 else
1041 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1042 ac_prog_rejected=no
1043 ac_dummy="$PATH"
1044 for ac_dir in $ac_dummy; do
1045 test -z "$ac_dir" && ac_dir=.
1046 if test -f $ac_dir/$ac_word; then
1047 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
1048 ac_prog_rejected=yes
1049 continue
1051 ac_cv_prog_CC="cc"
1052 break
1054 done
1055 IFS="$ac_save_ifs"
1056 if test $ac_prog_rejected = yes; then
1057 # We found a bogon in the path, so make sure we never use it.
1058 set dummy $ac_cv_prog_CC
1059 shift
1060 if test $# -gt 0; then
1061 # We chose a different compiler from the bogus one.
1062 # However, it has the same basename, so the bogon will be chosen
1063 # first if we set CC to just the basename; use the full file name.
1064 shift
1065 set dummy "$ac_dir/$ac_word" "$@"
1066 shift
1067 ac_cv_prog_CC="$@"
1072 CC="$ac_cv_prog_CC"
1073 if test -n "$CC"; then
1074 echo "$ac_t""$CC" 1>&6
1075 else
1076 echo "$ac_t""no" 1>&6
1079 if test -z "$CC"; then
1080 case "`uname -s`" in
1081 *win32* | *WIN32*)
1082 # Extract the first word of "cl", so it can be a program name with args.
1083 set dummy cl; ac_word=$2
1084 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1085 echo "configure:1086: checking for $ac_word" >&5
1086 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
1087 echo $ac_n "(cached) $ac_c" 1>&6
1088 else
1089 if test -n "$CC"; then
1090 ac_cv_prog_CC="$CC" # Let the user override the test.
1091 else
1092 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1093 ac_dummy="$PATH"
1094 for ac_dir in $ac_dummy; do
1095 test -z "$ac_dir" && ac_dir=.
1096 if test -f $ac_dir/$ac_word; then
1097 ac_cv_prog_CC="cl"
1098 break
1100 done
1101 IFS="$ac_save_ifs"
1104 CC="$ac_cv_prog_CC"
1105 if test -n "$CC"; then
1106 echo "$ac_t""$CC" 1>&6
1107 else
1108 echo "$ac_t""no" 1>&6
1111 esac
1113 test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
1116 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
1117 echo "configure:1118: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
1119 ac_ext=c
1120 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1121 ac_cpp='$CPP $CPPFLAGS'
1122 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1123 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1124 cross_compiling=$ac_cv_prog_cc_cross
1126 cat > conftest.$ac_ext << EOF
1128 #line 1129 "configure"
1129 #include "confdefs.h"
1131 main(){return(0);}
1133 if { (eval echo configure:1134: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1134 ac_cv_prog_cc_works=yes
1135 # If we can't run a trivial program, we are probably using a cross compiler.
1136 if (./conftest; exit) 2>/dev/null; then
1137 ac_cv_prog_cc_cross=no
1138 else
1139 ac_cv_prog_cc_cross=yes
1141 else
1142 echo "configure: failed program was:" >&5
1143 cat conftest.$ac_ext >&5
1144 ac_cv_prog_cc_works=no
1146 rm -fr conftest*
1147 ac_ext=c
1148 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1149 ac_cpp='$CPP $CPPFLAGS'
1150 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1151 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1152 cross_compiling=$ac_cv_prog_cc_cross
1154 echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
1155 if test $ac_cv_prog_cc_works = no; then
1156 { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
1158 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
1159 echo "configure:1160: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
1160 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
1161 cross_compiling=$ac_cv_prog_cc_cross
1163 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
1164 echo "configure:1165: checking whether we are using GNU C" >&5
1165 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
1166 echo $ac_n "(cached) $ac_c" 1>&6
1167 else
1168 cat > conftest.c <<EOF
1169 #ifdef __GNUC__
1170 yes;
1171 #endif
1173 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1174: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
1174 ac_cv_prog_gcc=yes
1175 else
1176 ac_cv_prog_gcc=no
1180 echo "$ac_t""$ac_cv_prog_gcc" 1>&6
1182 if test $ac_cv_prog_gcc = yes; then
1183 GCC=yes
1184 else
1185 GCC=
1188 ac_test_CFLAGS="${CFLAGS+set}"
1189 ac_save_CFLAGS="$CFLAGS"
1190 CFLAGS=
1191 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
1192 echo "configure:1193: checking whether ${CC-cc} accepts -g" >&5
1193 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
1194 echo $ac_n "(cached) $ac_c" 1>&6
1195 else
1196 echo 'void f(){}' > conftest.c
1197 if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
1198 ac_cv_prog_cc_g=yes
1199 else
1200 ac_cv_prog_cc_g=no
1202 rm -f conftest*
1206 echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
1207 if test "$ac_test_CFLAGS" = set; then
1208 CFLAGS="$ac_save_CFLAGS"
1209 elif test $ac_cv_prog_cc_g = yes; then
1210 if test "$GCC" = yes; then
1211 CFLAGS="-g -O2"
1212 else
1213 CFLAGS="-g"
1215 else
1216 if test "$GCC" = yes; then
1217 CFLAGS="-O2"
1218 else
1219 CFLAGS=
1223 # Check whether --with-gnu-ld or --without-gnu-ld was given.
1224 if test "${with_gnu_ld+set}" = set; then
1225 withval="$with_gnu_ld"
1226 test "$withval" = no || with_gnu_ld=yes
1227 else
1228 with_gnu_ld=no
1231 ac_prog=ld
1232 if test "$ac_cv_prog_gcc" = yes; then
1233 # Check if gcc -print-prog-name=ld gives a path.
1234 echo $ac_n "checking for ld used by GCC""... $ac_c" 1>&6
1235 echo "configure:1236: checking for ld used by GCC" >&5
1236 ac_prog=`($CC -print-prog-name=ld) 2>&5`
1237 case "$ac_prog" in
1238 # Accept absolute paths.
1239 [\\/]* | [A-Za-z]:[\\/]*)
1240 re_direlt='/[^/][^/]*/\.\./'
1241 # Canonicalize the path of ld
1242 ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
1243 while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
1244 ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
1245 done
1246 test -z "$LD" && LD="$ac_prog"
1249 # If it fails, then pretend we aren't using GCC.
1250 ac_prog=ld
1253 # If it is relative, then search for the first ld in PATH.
1254 with_gnu_ld=unknown
1256 esac
1257 elif test "$with_gnu_ld" = yes; then
1258 echo $ac_n "checking for GNU ld""... $ac_c" 1>&6
1259 echo "configure:1260: checking for GNU ld" >&5
1260 else
1261 echo $ac_n "checking for non-GNU ld""... $ac_c" 1>&6
1262 echo "configure:1263: checking for non-GNU ld" >&5
1264 if eval "test \"`echo '$''{'ac_cv_path_LD'+set}'`\" = set"; then
1265 echo $ac_n "(cached) $ac_c" 1>&6
1266 else
1267 if test -z "$LD"; then
1268 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
1269 for ac_dir in $PATH; do
1270 test -z "$ac_dir" && ac_dir=.
1271 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
1272 ac_cv_path_LD="$ac_dir/$ac_prog"
1273 # Check to see if the program is GNU ld. I'd rather use --version,
1274 # but apparently some GNU ld's only accept -v.
1275 # Break only if it was the GNU/non-GNU ld that we prefer.
1276 if "$ac_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
1277 test "$with_gnu_ld" != no && break
1278 else
1279 test "$with_gnu_ld" != yes && break
1282 done
1283 IFS="$ac_save_ifs"
1284 else
1285 ac_cv_path_LD="$LD" # Let the user override the test with a path.
1289 LD="$ac_cv_path_LD"
1290 if test -n "$LD"; then
1291 echo "$ac_t""$LD" 1>&6
1292 else
1293 echo "$ac_t""no" 1>&6
1295 test -z "$LD" && { echo "configure: error: no acceptable ld found in \$PATH" 1>&2; exit 1; }
1296 echo $ac_n "checking if the linker ($LD) is GNU ld""... $ac_c" 1>&6
1297 echo "configure:1298: checking if the linker ($LD) is GNU ld" >&5
1298 if eval "test \"`echo '$''{'ac_cv_prog_gnu_ld'+set}'`\" = set"; then
1299 echo $ac_n "(cached) $ac_c" 1>&6
1300 else
1301 # I'd rather use --version here, but apparently some GNU ld's only accept -v.
1302 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
1303 ac_cv_prog_gnu_ld=yes
1304 else
1305 ac_cv_prog_gnu_ld=no
1309 echo "$ac_t""$ac_cv_prog_gnu_ld" 1>&6
1312 echo $ac_n "checking for BSD-compatible nm""... $ac_c" 1>&6
1313 echo "configure:1314: checking for BSD-compatible nm" >&5
1314 if eval "test \"`echo '$''{'ac_cv_path_NM'+set}'`\" = set"; then
1315 echo $ac_n "(cached) $ac_c" 1>&6
1316 else
1317 if test -n "$NM"; then
1318 # Let the user override the test.
1319 ac_cv_path_NM="$NM"
1320 else
1321 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
1322 for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do
1323 test -z "$ac_dir" && ac_dir=.
1324 if test -f $ac_dir/nm || test -f $ac_dir/nm$ac_exeext ; then
1325 # Check to see if the nm accepts a BSD-compat flag.
1326 # Adding the `sed 1q' prevents false positives on HP-UX, which says:
1327 # nm: unknown option "B" ignored
1328 if ($ac_dir/nm -B /dev/null 2>&1 | sed '1q'; exit 0) | egrep /dev/null >/dev/null; then
1329 ac_cv_path_NM="$ac_dir/nm -B"
1330 break
1331 elif ($ac_dir/nm -p /dev/null 2>&1 | sed '1q'; exit 0) | egrep /dev/null >/dev/null; then
1332 ac_cv_path_NM="$ac_dir/nm -p"
1333 break
1334 else
1335 ac_cv_path_NM=${ac_cv_path_NM="$ac_dir/nm"} # keep the first match, but
1336 continue # so that we can try to find one that supports BSD flags
1339 done
1340 IFS="$ac_save_ifs"
1341 test -z "$ac_cv_path_NM" && ac_cv_path_NM=nm
1345 NM="$ac_cv_path_NM"
1346 echo "$ac_t""$NM" 1>&6
1348 echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
1349 echo "configure:1350: checking whether ln -s works" >&5
1350 if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
1351 echo $ac_n "(cached) $ac_c" 1>&6
1352 else
1353 rm -f conftestdata
1354 if ln -s X conftestdata 2>/dev/null
1355 then
1356 rm -f conftestdata
1357 ac_cv_prog_LN_S="ln -s"
1358 else
1359 ac_cv_prog_LN_S=ln
1362 LN_S="$ac_cv_prog_LN_S"
1363 if test "$ac_cv_prog_LN_S" = "ln -s"; then
1364 echo "$ac_t""yes" 1>&6
1365 else
1366 echo "$ac_t""no" 1>&6
1370 case "$target" in
1371 NONE) lt_target="$host" ;;
1372 *) lt_target="$target" ;;
1373 esac
1375 # Check for any special flags to pass to ltconfig.
1376 libtool_flags="--cache-file=$cache_file"
1377 test "$enable_shared" = no && libtool_flags="$libtool_flags --disable-shared"
1378 test "$enable_static" = no && libtool_flags="$libtool_flags --disable-static"
1379 test "$enable_fast_install" = no && libtool_flags="$libtool_flags --disable-fast-install"
1380 test "$ac_cv_prog_gcc" = yes && libtool_flags="$libtool_flags --with-gcc"
1381 test "$ac_cv_prog_gnu_ld" = yes && libtool_flags="$libtool_flags --with-gnu-ld"
1384 # Check whether --enable-libtool-lock or --disable-libtool-lock was given.
1385 if test "${enable_libtool_lock+set}" = set; then
1386 enableval="$enable_libtool_lock"
1390 test "x$enable_libtool_lock" = xno && libtool_flags="$libtool_flags --disable-lock"
1391 test x"$silent" = xyes && libtool_flags="$libtool_flags --silent"
1393 # Some flags need to be propagated to the compiler or linker for good
1394 # libtool support.
1395 case "$lt_target" in
1396 *-*-irix6*)
1397 # Find out which ABI we are using.
1398 echo '#line 1399 "configure"' > conftest.$ac_ext
1399 if { (eval echo configure:1400: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1400 case "`/usr/bin/file conftest.o`" in
1401 *32-bit*)
1402 LD="${LD-ld} -32"
1404 *N32*)
1405 LD="${LD-ld} -n32"
1407 *64-bit*)
1408 LD="${LD-ld} -64"
1410 esac
1412 rm -rf conftest*
1415 *-*-sco3.2v5*)
1416 # On SCO OpenServer 5, we need -belf to get full-featured binaries.
1417 SAVE_CFLAGS="$CFLAGS"
1418 CFLAGS="$CFLAGS -belf"
1419 echo $ac_n "checking whether the C compiler needs -belf""... $ac_c" 1>&6
1420 echo "configure:1421: checking whether the C compiler needs -belf" >&5
1421 if eval "test \"`echo '$''{'lt_cv_cc_needs_belf'+set}'`\" = set"; then
1422 echo $ac_n "(cached) $ac_c" 1>&6
1423 else
1424 cat > conftest.$ac_ext <<EOF
1425 #line 1426 "configure"
1426 #include "confdefs.h"
1428 int main() {
1430 ; return 0; }
1432 if { (eval echo configure:1433: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1433 rm -rf conftest*
1434 lt_cv_cc_needs_belf=yes
1435 else
1436 echo "configure: failed program was:" >&5
1437 cat conftest.$ac_ext >&5
1438 rm -rf conftest*
1439 lt_cv_cc_needs_belf=no
1441 rm -f conftest*
1444 echo "$ac_t""$lt_cv_cc_needs_belf" 1>&6
1445 if test x"$lt_cv_cc_needs_belf" != x"yes"; then
1446 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
1447 CFLAGS="$SAVE_CFLAGS"
1452 esac
1455 # Save cache, so that ltconfig can load it
1456 cat > confcache <<\EOF
1457 # This file is a shell script that caches the results of configure
1458 # tests run on this system so they can be shared between configure
1459 # scripts and configure runs. It is not useful on other systems.
1460 # If it contains results you don't want to keep, you may remove or edit it.
1462 # By default, configure uses ./config.cache as the cache file,
1463 # creating it if it does not exist already. You can give configure
1464 # the --cache-file=FILE option to use a different cache file; that is
1465 # what configure does when it calls configure scripts in
1466 # subdirectories, so they share the cache.
1467 # Giving --cache-file=/dev/null disables caching, for debugging configure.
1468 # config.status only pays attention to the cache file if you give it the
1469 # --recheck option to rerun configure.
1472 # The following way of writing the cache mishandles newlines in values,
1473 # but we know of no workaround that is simple, portable, and efficient.
1474 # So, don't put newlines in cache variables' values.
1475 # Ultrix sh set writes to stderr and can't be redirected directly,
1476 # and sets the high bit in the cache file unless we assign to the vars.
1477 (set) 2>&1 |
1478 case `(ac_space=' '; set | grep ac_space) 2>&1` in
1479 *ac_space=\ *)
1480 # `set' does not quote correctly, so add quotes (double-quote substitution
1481 # turns \\\\ into \\, and sed turns \\ into \).
1482 sed -n \
1483 -e "s/'/'\\\\''/g" \
1484 -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
1487 # `set' quotes correctly as required by POSIX, so do not add quotes.
1488 sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
1490 esac >> confcache
1491 if cmp -s $cache_file confcache; then
1493 else
1494 if test -w $cache_file; then
1495 echo "updating cache $cache_file"
1496 cat confcache > $cache_file
1497 else
1498 echo "not updating unwritable cache $cache_file"
1501 rm -f confcache
1504 # Actually configure libtool. ac_aux_dir is where install-sh is found.
1505 CC="$CC" CFLAGS="$CFLAGS" CPPFLAGS="$CPPFLAGS" \
1506 LD="$LD" LDFLAGS="$LDFLAGS" LIBS="$LIBS" \
1507 LN_S="$LN_S" NM="$NM" RANLIB="$RANLIB" \
1508 DLLTOOL="$DLLTOOL" AS="$AS" OBJDUMP="$OBJDUMP" \
1509 ${CONFIG_SHELL-/bin/sh} $ac_aux_dir/ltconfig --no-reexec \
1510 $libtool_flags --no-verify $ac_aux_dir/ltmain.sh $lt_target \
1511 || { echo "configure: error: libtool configure failed" 1>&2; exit 1; }
1513 # Reload cache, that may have been modified by ltconfig
1514 if test -r "$cache_file"; then
1515 echo "loading cache $cache_file"
1516 . $cache_file
1517 else
1518 echo "creating cache $cache_file"
1519 > $cache_file
1523 # This can be used to rebuild libtool when needed
1524 LIBTOOL_DEPS="$ac_aux_dir/ltconfig $ac_aux_dir/ltmain.sh"
1526 # Always use our own libtool.
1527 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
1529 # Redirect the config.log output again, so that the ltconfig log is not
1530 # clobbered by the next message.
1531 exec 5>>./config.log
1534 # Check whether --enable-targets or --disable-targets was given.
1535 if test "${enable_targets+set}" = set; then
1536 enableval="$enable_targets"
1537 case "${enableval}" in
1538 yes | "") { echo "configure: error: enable-targets option must specify target names or 'all'" 1>&2; exit 1; }
1540 no) enable_targets= ;;
1541 *) enable_targets=$enableval ;;
1542 esac
1544 # Check whether --enable-commonbfdlib or --disable-commonbfdlib was given.
1545 if test "${enable_commonbfdlib+set}" = set; then
1546 enableval="$enable_commonbfdlib"
1547 case "${enableval}" in
1548 yes) commonbfdlib=true ;;
1549 no) commonbfdlib=false ;;
1550 *) { echo "configure: error: bad value ${enableval} for BFD commonbfdlib option" 1>&2; exit 1; } ;;
1551 esac
1554 build_warnings="-W -Wall"
1555 # Check whether --enable-build-warnings or --disable-build-warnings was given.
1556 if test "${enable_build_warnings+set}" = set; then
1557 enableval="$enable_build_warnings"
1558 case "${enableval}" in
1559 yes) ;;
1560 no) build_warnings="-w";;
1561 ,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
1562 build_warnings="${build_warnings} ${t}";;
1563 *,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
1564 build_warnings="${t} ${build_warnings}";;
1565 *) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
1566 esac
1567 if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
1568 echo "Setting warning flags = $build_warnings" 6>&1
1571 WARN_CFLAGS=""
1572 if test "x${build_warnings}" != x -a "x$GCC" = xyes ; then
1573 WARN_CFLAGS="${build_warnings}"
1581 if test -z "$target" ; then
1582 { echo "configure: error: Unrecognized target system type; please check config.sub." 1>&2; exit 1; }
1584 if test -z "$host" ; then
1585 { echo "configure: error: Unrecognized host system type; please check config.sub." 1>&2; exit 1; }
1588 # Extract the first word of "gcc", so it can be a program name with args.
1589 set dummy gcc; ac_word=$2
1590 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1591 echo "configure:1592: checking for $ac_word" >&5
1592 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
1593 echo $ac_n "(cached) $ac_c" 1>&6
1594 else
1595 if test -n "$CC"; then
1596 ac_cv_prog_CC="$CC" # Let the user override the test.
1597 else
1598 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1599 ac_dummy="$PATH"
1600 for ac_dir in $ac_dummy; do
1601 test -z "$ac_dir" && ac_dir=.
1602 if test -f $ac_dir/$ac_word; then
1603 ac_cv_prog_CC="gcc"
1604 break
1606 done
1607 IFS="$ac_save_ifs"
1610 CC="$ac_cv_prog_CC"
1611 if test -n "$CC"; then
1612 echo "$ac_t""$CC" 1>&6
1613 else
1614 echo "$ac_t""no" 1>&6
1617 if test -z "$CC"; then
1618 # Extract the first word of "cc", so it can be a program name with args.
1619 set dummy cc; ac_word=$2
1620 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1621 echo "configure:1622: checking for $ac_word" >&5
1622 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
1623 echo $ac_n "(cached) $ac_c" 1>&6
1624 else
1625 if test -n "$CC"; then
1626 ac_cv_prog_CC="$CC" # Let the user override the test.
1627 else
1628 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1629 ac_prog_rejected=no
1630 ac_dummy="$PATH"
1631 for ac_dir in $ac_dummy; do
1632 test -z "$ac_dir" && ac_dir=.
1633 if test -f $ac_dir/$ac_word; then
1634 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
1635 ac_prog_rejected=yes
1636 continue
1638 ac_cv_prog_CC="cc"
1639 break
1641 done
1642 IFS="$ac_save_ifs"
1643 if test $ac_prog_rejected = yes; then
1644 # We found a bogon in the path, so make sure we never use it.
1645 set dummy $ac_cv_prog_CC
1646 shift
1647 if test $# -gt 0; then
1648 # We chose a different compiler from the bogus one.
1649 # However, it has the same basename, so the bogon will be chosen
1650 # first if we set CC to just the basename; use the full file name.
1651 shift
1652 set dummy "$ac_dir/$ac_word" "$@"
1653 shift
1654 ac_cv_prog_CC="$@"
1659 CC="$ac_cv_prog_CC"
1660 if test -n "$CC"; then
1661 echo "$ac_t""$CC" 1>&6
1662 else
1663 echo "$ac_t""no" 1>&6
1666 if test -z "$CC"; then
1667 case "`uname -s`" in
1668 *win32* | *WIN32*)
1669 # Extract the first word of "cl", so it can be a program name with args.
1670 set dummy cl; ac_word=$2
1671 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1672 echo "configure:1673: checking for $ac_word" >&5
1673 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
1674 echo $ac_n "(cached) $ac_c" 1>&6
1675 else
1676 if test -n "$CC"; then
1677 ac_cv_prog_CC="$CC" # Let the user override the test.
1678 else
1679 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1680 ac_dummy="$PATH"
1681 for ac_dir in $ac_dummy; do
1682 test -z "$ac_dir" && ac_dir=.
1683 if test -f $ac_dir/$ac_word; then
1684 ac_cv_prog_CC="cl"
1685 break
1687 done
1688 IFS="$ac_save_ifs"
1691 CC="$ac_cv_prog_CC"
1692 if test -n "$CC"; then
1693 echo "$ac_t""$CC" 1>&6
1694 else
1695 echo "$ac_t""no" 1>&6
1698 esac
1700 test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
1703 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
1704 echo "configure:1705: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
1706 ac_ext=c
1707 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1708 ac_cpp='$CPP $CPPFLAGS'
1709 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1710 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1711 cross_compiling=$ac_cv_prog_cc_cross
1713 cat > conftest.$ac_ext << EOF
1715 #line 1716 "configure"
1716 #include "confdefs.h"
1718 main(){return(0);}
1720 if { (eval echo configure:1721: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1721 ac_cv_prog_cc_works=yes
1722 # If we can't run a trivial program, we are probably using a cross compiler.
1723 if (./conftest; exit) 2>/dev/null; then
1724 ac_cv_prog_cc_cross=no
1725 else
1726 ac_cv_prog_cc_cross=yes
1728 else
1729 echo "configure: failed program was:" >&5
1730 cat conftest.$ac_ext >&5
1731 ac_cv_prog_cc_works=no
1733 rm -fr conftest*
1734 ac_ext=c
1735 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1736 ac_cpp='$CPP $CPPFLAGS'
1737 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1738 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1739 cross_compiling=$ac_cv_prog_cc_cross
1741 echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
1742 if test $ac_cv_prog_cc_works = no; then
1743 { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
1745 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
1746 echo "configure:1747: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
1747 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
1748 cross_compiling=$ac_cv_prog_cc_cross
1750 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
1751 echo "configure:1752: checking whether we are using GNU C" >&5
1752 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
1753 echo $ac_n "(cached) $ac_c" 1>&6
1754 else
1755 cat > conftest.c <<EOF
1756 #ifdef __GNUC__
1757 yes;
1758 #endif
1760 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1761: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
1761 ac_cv_prog_gcc=yes
1762 else
1763 ac_cv_prog_gcc=no
1767 echo "$ac_t""$ac_cv_prog_gcc" 1>&6
1769 if test $ac_cv_prog_gcc = yes; then
1770 GCC=yes
1771 else
1772 GCC=
1775 ac_test_CFLAGS="${CFLAGS+set}"
1776 ac_save_CFLAGS="$CFLAGS"
1777 CFLAGS=
1778 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
1779 echo "configure:1780: checking whether ${CC-cc} accepts -g" >&5
1780 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
1781 echo $ac_n "(cached) $ac_c" 1>&6
1782 else
1783 echo 'void f(){}' > conftest.c
1784 if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
1785 ac_cv_prog_cc_g=yes
1786 else
1787 ac_cv_prog_cc_g=no
1789 rm -f conftest*
1793 echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
1794 if test "$ac_test_CFLAGS" = set; then
1795 CFLAGS="$ac_save_CFLAGS"
1796 elif test $ac_cv_prog_cc_g = yes; then
1797 if test "$GCC" = yes; then
1798 CFLAGS="-g -O2"
1799 else
1800 CFLAGS="-g"
1802 else
1803 if test "$GCC" = yes; then
1804 CFLAGS="-O2"
1805 else
1806 CFLAGS=
1811 for ac_prog in 'bison -y' byacc
1813 # Extract the first word of "$ac_prog", so it can be a program name with args.
1814 set dummy $ac_prog; ac_word=$2
1815 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1816 echo "configure:1817: checking for $ac_word" >&5
1817 if eval "test \"`echo '$''{'ac_cv_prog_YACC'+set}'`\" = set"; then
1818 echo $ac_n "(cached) $ac_c" 1>&6
1819 else
1820 if test -n "$YACC"; then
1821 ac_cv_prog_YACC="$YACC" # Let the user override the test.
1822 else
1823 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1824 ac_dummy="$PATH"
1825 for ac_dir in $ac_dummy; do
1826 test -z "$ac_dir" && ac_dir=.
1827 if test -f $ac_dir/$ac_word; then
1828 ac_cv_prog_YACC="$ac_prog"
1829 break
1831 done
1832 IFS="$ac_save_ifs"
1835 YACC="$ac_cv_prog_YACC"
1836 if test -n "$YACC"; then
1837 echo "$ac_t""$YACC" 1>&6
1838 else
1839 echo "$ac_t""no" 1>&6
1842 test -n "$YACC" && break
1843 done
1844 test -n "$YACC" || YACC="yacc"
1846 echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
1847 echo "configure:1848: checking how to run the C preprocessor" >&5
1848 # On Suns, sometimes $CPP names a directory.
1849 if test -n "$CPP" && test -d "$CPP"; then
1850 CPP=
1852 if test -z "$CPP"; then
1853 if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
1854 echo $ac_n "(cached) $ac_c" 1>&6
1855 else
1856 # This must be in double quotes, not single quotes, because CPP may get
1857 # substituted into the Makefile and "${CC-cc}" will confuse make.
1858 CPP="${CC-cc} -E"
1859 # On the NeXT, cc -E runs the code through the compiler's parser,
1860 # not just through cpp.
1861 cat > conftest.$ac_ext <<EOF
1862 #line 1863 "configure"
1863 #include "confdefs.h"
1864 #include <assert.h>
1865 Syntax Error
1867 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1868 { (eval echo configure:1869: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1869 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1870 if test -z "$ac_err"; then
1872 else
1873 echo "$ac_err" >&5
1874 echo "configure: failed program was:" >&5
1875 cat conftest.$ac_ext >&5
1876 rm -rf conftest*
1877 CPP="${CC-cc} -E -traditional-cpp"
1878 cat > conftest.$ac_ext <<EOF
1879 #line 1880 "configure"
1880 #include "confdefs.h"
1881 #include <assert.h>
1882 Syntax Error
1884 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1885 { (eval echo configure:1886: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1886 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1887 if test -z "$ac_err"; then
1889 else
1890 echo "$ac_err" >&5
1891 echo "configure: failed program was:" >&5
1892 cat conftest.$ac_ext >&5
1893 rm -rf conftest*
1894 CPP="${CC-cc} -nologo -E"
1895 cat > conftest.$ac_ext <<EOF
1896 #line 1897 "configure"
1897 #include "confdefs.h"
1898 #include <assert.h>
1899 Syntax Error
1901 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1902 { (eval echo configure:1903: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1903 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1904 if test -z "$ac_err"; then
1906 else
1907 echo "$ac_err" >&5
1908 echo "configure: failed program was:" >&5
1909 cat conftest.$ac_ext >&5
1910 rm -rf conftest*
1911 CPP=/lib/cpp
1913 rm -f conftest*
1915 rm -f conftest*
1917 rm -f conftest*
1918 ac_cv_prog_CPP="$CPP"
1920 CPP="$ac_cv_prog_CPP"
1921 else
1922 ac_cv_prog_CPP="$CPP"
1924 echo "$ac_t""$CPP" 1>&6
1926 missing_dir=`cd $ac_aux_dir && pwd`
1927 for ac_prog in flex lex
1929 # Extract the first word of "$ac_prog", so it can be a program name with args.
1930 set dummy $ac_prog; ac_word=$2
1931 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1932 echo "configure:1933: checking for $ac_word" >&5
1933 if eval "test \"`echo '$''{'ac_cv_prog_LEX'+set}'`\" = set"; then
1934 echo $ac_n "(cached) $ac_c" 1>&6
1935 else
1936 if test -n "$LEX"; then
1937 ac_cv_prog_LEX="$LEX" # Let the user override the test.
1938 else
1939 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1940 ac_dummy="$PATH"
1941 for ac_dir in $ac_dummy; do
1942 test -z "$ac_dir" && ac_dir=.
1943 if test -f $ac_dir/$ac_word; then
1944 ac_cv_prog_LEX="$ac_prog"
1945 break
1947 done
1948 IFS="$ac_save_ifs"
1951 LEX="$ac_cv_prog_LEX"
1952 if test -n "$LEX"; then
1953 echo "$ac_t""$LEX" 1>&6
1954 else
1955 echo "$ac_t""no" 1>&6
1958 test -n "$LEX" && break
1959 done
1960 test -n "$LEX" || LEX=""$missing_dir/missing flex""
1962 # Extract the first word of "flex", so it can be a program name with args.
1963 set dummy flex; ac_word=$2
1964 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1965 echo "configure:1966: checking for $ac_word" >&5
1966 if eval "test \"`echo '$''{'ac_cv_prog_LEX'+set}'`\" = set"; then
1967 echo $ac_n "(cached) $ac_c" 1>&6
1968 else
1969 if test -n "$LEX"; then
1970 ac_cv_prog_LEX="$LEX" # Let the user override the test.
1971 else
1972 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1973 ac_dummy="$PATH"
1974 for ac_dir in $ac_dummy; do
1975 test -z "$ac_dir" && ac_dir=.
1976 if test -f $ac_dir/$ac_word; then
1977 ac_cv_prog_LEX="flex"
1978 break
1980 done
1981 IFS="$ac_save_ifs"
1982 test -z "$ac_cv_prog_LEX" && ac_cv_prog_LEX="lex"
1985 LEX="$ac_cv_prog_LEX"
1986 if test -n "$LEX"; then
1987 echo "$ac_t""$LEX" 1>&6
1988 else
1989 echo "$ac_t""no" 1>&6
1992 if test -z "$LEXLIB"
1993 then
1994 case "$LEX" in
1995 flex*) ac_lib=fl ;;
1996 *) ac_lib=l ;;
1997 esac
1998 echo $ac_n "checking for yywrap in -l$ac_lib""... $ac_c" 1>&6
1999 echo "configure:2000: checking for yywrap in -l$ac_lib" >&5
2000 ac_lib_var=`echo $ac_lib'_'yywrap | sed 'y%./+-%__p_%'`
2001 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2002 echo $ac_n "(cached) $ac_c" 1>&6
2003 else
2004 ac_save_LIBS="$LIBS"
2005 LIBS="-l$ac_lib $LIBS"
2006 cat > conftest.$ac_ext <<EOF
2007 #line 2008 "configure"
2008 #include "confdefs.h"
2009 /* Override any gcc2 internal prototype to avoid an error. */
2010 /* We use char because int might match the return type of a gcc2
2011 builtin and then its argument prototype would still apply. */
2012 char yywrap();
2014 int main() {
2015 yywrap()
2016 ; return 0; }
2018 if { (eval echo configure:2019: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2019 rm -rf conftest*
2020 eval "ac_cv_lib_$ac_lib_var=yes"
2021 else
2022 echo "configure: failed program was:" >&5
2023 cat conftest.$ac_ext >&5
2024 rm -rf conftest*
2025 eval "ac_cv_lib_$ac_lib_var=no"
2027 rm -f conftest*
2028 LIBS="$ac_save_LIBS"
2031 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2032 echo "$ac_t""yes" 1>&6
2033 LEXLIB="-l$ac_lib"
2034 else
2035 echo "$ac_t""no" 1>&6
2040 echo $ac_n "checking lex output file root""... $ac_c" 1>&6
2041 echo "configure:2042: checking lex output file root" >&5
2042 if eval "test \"`echo '$''{'ac_cv_prog_lex_root'+set}'`\" = set"; then
2043 echo $ac_n "(cached) $ac_c" 1>&6
2044 else
2045 # The minimal lex program is just a single line: %%. But some broken lexes
2046 # (Solaris, I think it was) want two %% lines, so accommodate them.
2047 echo '%%
2048 %%' | $LEX
2049 if test -f lex.yy.c; then
2050 ac_cv_prog_lex_root=lex.yy
2051 elif test -f lexyy.c; then
2052 ac_cv_prog_lex_root=lexyy
2053 else
2054 { echo "configure: error: cannot find output from $LEX; giving up" 1>&2; exit 1; }
2058 echo "$ac_t""$ac_cv_prog_lex_root" 1>&6
2059 LEX_OUTPUT_ROOT=$ac_cv_prog_lex_root
2061 echo $ac_n "checking whether yytext is a pointer""... $ac_c" 1>&6
2062 echo "configure:2063: checking whether yytext is a pointer" >&5
2063 if eval "test \"`echo '$''{'ac_cv_prog_lex_yytext_pointer'+set}'`\" = set"; then
2064 echo $ac_n "(cached) $ac_c" 1>&6
2065 else
2066 # POSIX says lex can declare yytext either as a pointer or an array; the
2067 # default is implementation-dependent. Figure out which it is, since
2068 # not all implementations provide the %pointer and %array declarations.
2069 ac_cv_prog_lex_yytext_pointer=no
2070 echo 'extern char *yytext;' >>$LEX_OUTPUT_ROOT.c
2071 ac_save_LIBS="$LIBS"
2072 LIBS="$LIBS $LEXLIB"
2073 cat > conftest.$ac_ext <<EOF
2074 #line 2075 "configure"
2075 #include "confdefs.h"
2076 `cat $LEX_OUTPUT_ROOT.c`
2077 int main() {
2079 ; return 0; }
2081 if { (eval echo configure:2082: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2082 rm -rf conftest*
2083 ac_cv_prog_lex_yytext_pointer=yes
2084 else
2085 echo "configure: failed program was:" >&5
2086 cat conftest.$ac_ext >&5
2088 rm -f conftest*
2089 LIBS="$ac_save_LIBS"
2090 rm -f "${LEX_OUTPUT_ROOT}.c"
2094 echo "$ac_t""$ac_cv_prog_lex_yytext_pointer" 1>&6
2095 if test $ac_cv_prog_lex_yytext_pointer = yes; then
2096 cat >> confdefs.h <<\EOF
2097 #define YYTEXT_POINTER 1
2103 ALL_LINGUAS=
2104 echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6
2105 echo "configure:2106: checking for POSIXized ISC" >&5
2106 if test -d /etc/conf/kconfig.d &&
2107 grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
2108 then
2109 echo "$ac_t""yes" 1>&6
2110 ISC=yes # If later tests want to check for ISC.
2111 cat >> confdefs.h <<\EOF
2112 #define _POSIX_SOURCE 1
2115 if test "$GCC" = yes; then
2116 CC="$CC -posix"
2117 else
2118 CC="$CC -Xp"
2120 else
2121 echo "$ac_t""no" 1>&6
2122 ISC=
2125 echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
2126 echo "configure:2127: checking for ANSI C header files" >&5
2127 if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
2128 echo $ac_n "(cached) $ac_c" 1>&6
2129 else
2130 cat > conftest.$ac_ext <<EOF
2131 #line 2132 "configure"
2132 #include "confdefs.h"
2133 #include <stdlib.h>
2134 #include <stdarg.h>
2135 #include <string.h>
2136 #include <float.h>
2138 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2139 { (eval echo configure:2140: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2140 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2141 if test -z "$ac_err"; then
2142 rm -rf conftest*
2143 ac_cv_header_stdc=yes
2144 else
2145 echo "$ac_err" >&5
2146 echo "configure: failed program was:" >&5
2147 cat conftest.$ac_ext >&5
2148 rm -rf conftest*
2149 ac_cv_header_stdc=no
2151 rm -f conftest*
2153 if test $ac_cv_header_stdc = yes; then
2154 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
2155 cat > conftest.$ac_ext <<EOF
2156 #line 2157 "configure"
2157 #include "confdefs.h"
2158 #include <string.h>
2160 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2161 egrep "memchr" >/dev/null 2>&1; then
2163 else
2164 rm -rf conftest*
2165 ac_cv_header_stdc=no
2167 rm -f conftest*
2171 if test $ac_cv_header_stdc = yes; then
2172 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
2173 cat > conftest.$ac_ext <<EOF
2174 #line 2175 "configure"
2175 #include "confdefs.h"
2176 #include <stdlib.h>
2178 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2179 egrep "free" >/dev/null 2>&1; then
2181 else
2182 rm -rf conftest*
2183 ac_cv_header_stdc=no
2185 rm -f conftest*
2189 if test $ac_cv_header_stdc = yes; then
2190 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
2191 if test "$cross_compiling" = yes; then
2193 else
2194 cat > conftest.$ac_ext <<EOF
2195 #line 2196 "configure"
2196 #include "confdefs.h"
2197 #include <ctype.h>
2198 #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
2199 #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
2200 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
2201 int main () { int i; for (i = 0; i < 256; i++)
2202 if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
2203 exit (0); }
2206 if { (eval echo configure:2207: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2207 then
2209 else
2210 echo "configure: failed program was:" >&5
2211 cat conftest.$ac_ext >&5
2212 rm -fr conftest*
2213 ac_cv_header_stdc=no
2215 rm -fr conftest*
2221 echo "$ac_t""$ac_cv_header_stdc" 1>&6
2222 if test $ac_cv_header_stdc = yes; then
2223 cat >> confdefs.h <<\EOF
2224 #define STDC_HEADERS 1
2229 echo $ac_n "checking for working const""... $ac_c" 1>&6
2230 echo "configure:2231: checking for working const" >&5
2231 if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
2232 echo $ac_n "(cached) $ac_c" 1>&6
2233 else
2234 cat > conftest.$ac_ext <<EOF
2235 #line 2236 "configure"
2236 #include "confdefs.h"
2238 int main() {
2240 /* Ultrix mips cc rejects this. */
2241 typedef int charset[2]; const charset x;
2242 /* SunOS 4.1.1 cc rejects this. */
2243 char const *const *ccp;
2244 char **p;
2245 /* NEC SVR4.0.2 mips cc rejects this. */
2246 struct point {int x, y;};
2247 static struct point const zero = {0,0};
2248 /* AIX XL C 1.02.0.0 rejects this.
2249 It does not let you subtract one const X* pointer from another in an arm
2250 of an if-expression whose if-part is not a constant expression */
2251 const char *g = "string";
2252 ccp = &g + (g ? g-g : 0);
2253 /* HPUX 7.0 cc rejects these. */
2254 ++ccp;
2255 p = (char**) ccp;
2256 ccp = (char const *const *) p;
2257 { /* SCO 3.2v4 cc rejects this. */
2258 char *t;
2259 char const *s = 0 ? (char *) 0 : (char const *) 0;
2261 *t++ = 0;
2263 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
2264 int x[] = {25, 17};
2265 const int *foo = &x[0];
2266 ++foo;
2268 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
2269 typedef const int *iptr;
2270 iptr p = 0;
2271 ++p;
2273 { /* AIX XL C 1.02.0.0 rejects this saying
2274 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
2275 struct s { int j; const int *ap[3]; };
2276 struct s *b; b->j = 5;
2278 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
2279 const int foo = 10;
2282 ; return 0; }
2284 if { (eval echo configure:2285: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2285 rm -rf conftest*
2286 ac_cv_c_const=yes
2287 else
2288 echo "configure: failed program was:" >&5
2289 cat conftest.$ac_ext >&5
2290 rm -rf conftest*
2291 ac_cv_c_const=no
2293 rm -f conftest*
2296 echo "$ac_t""$ac_cv_c_const" 1>&6
2297 if test $ac_cv_c_const = no; then
2298 cat >> confdefs.h <<\EOF
2299 #define const
2304 echo $ac_n "checking for inline""... $ac_c" 1>&6
2305 echo "configure:2306: checking for inline" >&5
2306 if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
2307 echo $ac_n "(cached) $ac_c" 1>&6
2308 else
2309 ac_cv_c_inline=no
2310 for ac_kw in inline __inline__ __inline; do
2311 cat > conftest.$ac_ext <<EOF
2312 #line 2313 "configure"
2313 #include "confdefs.h"
2315 int main() {
2316 } $ac_kw foo() {
2317 ; return 0; }
2319 if { (eval echo configure:2320: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2320 rm -rf conftest*
2321 ac_cv_c_inline=$ac_kw; break
2322 else
2323 echo "configure: failed program was:" >&5
2324 cat conftest.$ac_ext >&5
2326 rm -f conftest*
2327 done
2331 echo "$ac_t""$ac_cv_c_inline" 1>&6
2332 case "$ac_cv_c_inline" in
2333 inline | yes) ;;
2334 no) cat >> confdefs.h <<\EOF
2335 #define inline
2338 *) cat >> confdefs.h <<EOF
2339 #define inline $ac_cv_c_inline
2342 esac
2344 echo $ac_n "checking for off_t""... $ac_c" 1>&6
2345 echo "configure:2346: checking for off_t" >&5
2346 if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then
2347 echo $ac_n "(cached) $ac_c" 1>&6
2348 else
2349 cat > conftest.$ac_ext <<EOF
2350 #line 2351 "configure"
2351 #include "confdefs.h"
2352 #include <sys/types.h>
2353 #if STDC_HEADERS
2354 #include <stdlib.h>
2355 #include <stddef.h>
2356 #endif
2358 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2359 egrep "(^|[^a-zA-Z_0-9])off_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
2360 rm -rf conftest*
2361 ac_cv_type_off_t=yes
2362 else
2363 rm -rf conftest*
2364 ac_cv_type_off_t=no
2366 rm -f conftest*
2369 echo "$ac_t""$ac_cv_type_off_t" 1>&6
2370 if test $ac_cv_type_off_t = no; then
2371 cat >> confdefs.h <<\EOF
2372 #define off_t long
2377 echo $ac_n "checking for size_t""... $ac_c" 1>&6
2378 echo "configure:2379: checking for size_t" >&5
2379 if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
2380 echo $ac_n "(cached) $ac_c" 1>&6
2381 else
2382 cat > conftest.$ac_ext <<EOF
2383 #line 2384 "configure"
2384 #include "confdefs.h"
2385 #include <sys/types.h>
2386 #if STDC_HEADERS
2387 #include <stdlib.h>
2388 #include <stddef.h>
2389 #endif
2391 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2392 egrep "(^|[^a-zA-Z_0-9])size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
2393 rm -rf conftest*
2394 ac_cv_type_size_t=yes
2395 else
2396 rm -rf conftest*
2397 ac_cv_type_size_t=no
2399 rm -f conftest*
2402 echo "$ac_t""$ac_cv_type_size_t" 1>&6
2403 if test $ac_cv_type_size_t = no; then
2404 cat >> confdefs.h <<\EOF
2405 #define size_t unsigned
2410 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
2411 # for constant arguments. Useless!
2412 echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
2413 echo "configure:2414: checking for working alloca.h" >&5
2414 if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
2415 echo $ac_n "(cached) $ac_c" 1>&6
2416 else
2417 cat > conftest.$ac_ext <<EOF
2418 #line 2419 "configure"
2419 #include "confdefs.h"
2420 #include <alloca.h>
2421 int main() {
2422 char *p = alloca(2 * sizeof(int));
2423 ; return 0; }
2425 if { (eval echo configure:2426: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2426 rm -rf conftest*
2427 ac_cv_header_alloca_h=yes
2428 else
2429 echo "configure: failed program was:" >&5
2430 cat conftest.$ac_ext >&5
2431 rm -rf conftest*
2432 ac_cv_header_alloca_h=no
2434 rm -f conftest*
2437 echo "$ac_t""$ac_cv_header_alloca_h" 1>&6
2438 if test $ac_cv_header_alloca_h = yes; then
2439 cat >> confdefs.h <<\EOF
2440 #define HAVE_ALLOCA_H 1
2445 echo $ac_n "checking for alloca""... $ac_c" 1>&6
2446 echo "configure:2447: checking for alloca" >&5
2447 if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
2448 echo $ac_n "(cached) $ac_c" 1>&6
2449 else
2450 cat > conftest.$ac_ext <<EOF
2451 #line 2452 "configure"
2452 #include "confdefs.h"
2454 #ifdef __GNUC__
2455 # define alloca __builtin_alloca
2456 #else
2457 # ifdef _MSC_VER
2458 # include <malloc.h>
2459 # define alloca _alloca
2460 # else
2461 # if HAVE_ALLOCA_H
2462 # include <alloca.h>
2463 # else
2464 # ifdef _AIX
2465 #pragma alloca
2466 # else
2467 # ifndef alloca /* predefined by HP cc +Olibcalls */
2468 char *alloca ();
2469 # endif
2470 # endif
2471 # endif
2472 # endif
2473 #endif
2475 int main() {
2476 char *p = (char *) alloca(1);
2477 ; return 0; }
2479 if { (eval echo configure:2480: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2480 rm -rf conftest*
2481 ac_cv_func_alloca_works=yes
2482 else
2483 echo "configure: failed program was:" >&5
2484 cat conftest.$ac_ext >&5
2485 rm -rf conftest*
2486 ac_cv_func_alloca_works=no
2488 rm -f conftest*
2491 echo "$ac_t""$ac_cv_func_alloca_works" 1>&6
2492 if test $ac_cv_func_alloca_works = yes; then
2493 cat >> confdefs.h <<\EOF
2494 #define HAVE_ALLOCA 1
2499 if test $ac_cv_func_alloca_works = no; then
2500 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
2501 # that cause trouble. Some versions do not even contain alloca or
2502 # contain a buggy version. If you still want to use their alloca,
2503 # use ar to extract alloca.o from them instead of compiling alloca.c.
2504 ALLOCA=alloca.${ac_objext}
2505 cat >> confdefs.h <<\EOF
2506 #define C_ALLOCA 1
2510 echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
2511 echo "configure:2512: checking whether alloca needs Cray hooks" >&5
2512 if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
2513 echo $ac_n "(cached) $ac_c" 1>&6
2514 else
2515 cat > conftest.$ac_ext <<EOF
2516 #line 2517 "configure"
2517 #include "confdefs.h"
2518 #if defined(CRAY) && ! defined(CRAY2)
2519 webecray
2520 #else
2521 wenotbecray
2522 #endif
2525 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2526 egrep "webecray" >/dev/null 2>&1; then
2527 rm -rf conftest*
2528 ac_cv_os_cray=yes
2529 else
2530 rm -rf conftest*
2531 ac_cv_os_cray=no
2533 rm -f conftest*
2537 echo "$ac_t""$ac_cv_os_cray" 1>&6
2538 if test $ac_cv_os_cray = yes; then
2539 for ac_func in _getb67 GETB67 getb67; do
2540 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
2541 echo "configure:2542: checking for $ac_func" >&5
2542 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2543 echo $ac_n "(cached) $ac_c" 1>&6
2544 else
2545 cat > conftest.$ac_ext <<EOF
2546 #line 2547 "configure"
2547 #include "confdefs.h"
2548 /* System header to define __stub macros and hopefully few prototypes,
2549 which can conflict with char $ac_func(); below. */
2550 #include <assert.h>
2551 /* Override any gcc2 internal prototype to avoid an error. */
2552 /* We use char because int might match the return type of a gcc2
2553 builtin and then its argument prototype would still apply. */
2554 char $ac_func();
2556 int main() {
2558 /* The GNU C library defines this for functions which it implements
2559 to always fail with ENOSYS. Some functions are actually named
2560 something starting with __ and the normal name is an alias. */
2561 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2562 choke me
2563 #else
2564 $ac_func();
2565 #endif
2567 ; return 0; }
2569 if { (eval echo configure:2570: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2570 rm -rf conftest*
2571 eval "ac_cv_func_$ac_func=yes"
2572 else
2573 echo "configure: failed program was:" >&5
2574 cat conftest.$ac_ext >&5
2575 rm -rf conftest*
2576 eval "ac_cv_func_$ac_func=no"
2578 rm -f conftest*
2581 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2582 echo "$ac_t""yes" 1>&6
2583 cat >> confdefs.h <<EOF
2584 #define CRAY_STACKSEG_END $ac_func
2587 break
2588 else
2589 echo "$ac_t""no" 1>&6
2592 done
2595 echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
2596 echo "configure:2597: checking stack direction for C alloca" >&5
2597 if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
2598 echo $ac_n "(cached) $ac_c" 1>&6
2599 else
2600 if test "$cross_compiling" = yes; then
2601 ac_cv_c_stack_direction=0
2602 else
2603 cat > conftest.$ac_ext <<EOF
2604 #line 2605 "configure"
2605 #include "confdefs.h"
2606 find_stack_direction ()
2608 static char *addr = 0;
2609 auto char dummy;
2610 if (addr == 0)
2612 addr = &dummy;
2613 return find_stack_direction ();
2615 else
2616 return (&dummy > addr) ? 1 : -1;
2618 main ()
2620 exit (find_stack_direction() < 0);
2623 if { (eval echo configure:2624: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2624 then
2625 ac_cv_c_stack_direction=1
2626 else
2627 echo "configure: failed program was:" >&5
2628 cat conftest.$ac_ext >&5
2629 rm -fr conftest*
2630 ac_cv_c_stack_direction=-1
2632 rm -fr conftest*
2637 echo "$ac_t""$ac_cv_c_stack_direction" 1>&6
2638 cat >> confdefs.h <<EOF
2639 #define STACK_DIRECTION $ac_cv_c_stack_direction
2644 for ac_hdr in unistd.h
2646 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2647 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2648 echo "configure:2649: checking for $ac_hdr" >&5
2649 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2650 echo $ac_n "(cached) $ac_c" 1>&6
2651 else
2652 cat > conftest.$ac_ext <<EOF
2653 #line 2654 "configure"
2654 #include "confdefs.h"
2655 #include <$ac_hdr>
2657 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2658 { (eval echo configure:2659: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2659 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2660 if test -z "$ac_err"; then
2661 rm -rf conftest*
2662 eval "ac_cv_header_$ac_safe=yes"
2663 else
2664 echo "$ac_err" >&5
2665 echo "configure: failed program was:" >&5
2666 cat conftest.$ac_ext >&5
2667 rm -rf conftest*
2668 eval "ac_cv_header_$ac_safe=no"
2670 rm -f conftest*
2672 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2673 echo "$ac_t""yes" 1>&6
2674 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2675 cat >> confdefs.h <<EOF
2676 #define $ac_tr_hdr 1
2679 else
2680 echo "$ac_t""no" 1>&6
2682 done
2684 for ac_func in getpagesize
2686 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
2687 echo "configure:2688: checking for $ac_func" >&5
2688 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2689 echo $ac_n "(cached) $ac_c" 1>&6
2690 else
2691 cat > conftest.$ac_ext <<EOF
2692 #line 2693 "configure"
2693 #include "confdefs.h"
2694 /* System header to define __stub macros and hopefully few prototypes,
2695 which can conflict with char $ac_func(); below. */
2696 #include <assert.h>
2697 /* Override any gcc2 internal prototype to avoid an error. */
2698 /* We use char because int might match the return type of a gcc2
2699 builtin and then its argument prototype would still apply. */
2700 char $ac_func();
2702 int main() {
2704 /* The GNU C library defines this for functions which it implements
2705 to always fail with ENOSYS. Some functions are actually named
2706 something starting with __ and the normal name is an alias. */
2707 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2708 choke me
2709 #else
2710 $ac_func();
2711 #endif
2713 ; return 0; }
2715 if { (eval echo configure:2716: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2716 rm -rf conftest*
2717 eval "ac_cv_func_$ac_func=yes"
2718 else
2719 echo "configure: failed program was:" >&5
2720 cat conftest.$ac_ext >&5
2721 rm -rf conftest*
2722 eval "ac_cv_func_$ac_func=no"
2724 rm -f conftest*
2727 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2728 echo "$ac_t""yes" 1>&6
2729 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2730 cat >> confdefs.h <<EOF
2731 #define $ac_tr_func 1
2734 else
2735 echo "$ac_t""no" 1>&6
2737 done
2739 echo $ac_n "checking for working mmap""... $ac_c" 1>&6
2740 echo "configure:2741: checking for working mmap" >&5
2741 if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
2742 echo $ac_n "(cached) $ac_c" 1>&6
2743 else
2744 if test "$cross_compiling" = yes; then
2745 ac_cv_func_mmap_fixed_mapped=no
2746 else
2747 cat > conftest.$ac_ext <<EOF
2748 #line 2749 "configure"
2749 #include "confdefs.h"
2751 /* Thanks to Mike Haertel and Jim Avera for this test.
2752 Here is a matrix of mmap possibilities:
2753 mmap private not fixed
2754 mmap private fixed at somewhere currently unmapped
2755 mmap private fixed at somewhere already mapped
2756 mmap shared not fixed
2757 mmap shared fixed at somewhere currently unmapped
2758 mmap shared fixed at somewhere already mapped
2759 For private mappings, we should verify that changes cannot be read()
2760 back from the file, nor mmap's back from the file at a different
2761 address. (There have been systems where private was not correctly
2762 implemented like the infamous i386 svr4.0, and systems where the
2763 VM page cache was not coherent with the filesystem buffer cache
2764 like early versions of FreeBSD and possibly contemporary NetBSD.)
2765 For shared mappings, we should conversely verify that changes get
2766 propogated back to all the places they're supposed to be.
2768 Grep wants private fixed already mapped.
2769 The main things grep needs to know about mmap are:
2770 * does it exist and is it safe to write into the mmap'd area
2771 * how to use it (BSD variants) */
2772 #include <sys/types.h>
2773 #include <fcntl.h>
2774 #include <sys/mman.h>
2776 /* This mess was copied from the GNU getpagesize.h. */
2777 #ifndef HAVE_GETPAGESIZE
2778 # ifdef HAVE_UNISTD_H
2779 # include <unistd.h>
2780 # endif
2782 /* Assume that all systems that can run configure have sys/param.h. */
2783 # ifndef HAVE_SYS_PARAM_H
2784 # define HAVE_SYS_PARAM_H 1
2785 # endif
2787 # ifdef _SC_PAGESIZE
2788 # define getpagesize() sysconf(_SC_PAGESIZE)
2789 # else /* no _SC_PAGESIZE */
2790 # ifdef HAVE_SYS_PARAM_H
2791 # include <sys/param.h>
2792 # ifdef EXEC_PAGESIZE
2793 # define getpagesize() EXEC_PAGESIZE
2794 # else /* no EXEC_PAGESIZE */
2795 # ifdef NBPG
2796 # define getpagesize() NBPG * CLSIZE
2797 # ifndef CLSIZE
2798 # define CLSIZE 1
2799 # endif /* no CLSIZE */
2800 # else /* no NBPG */
2801 # ifdef NBPC
2802 # define getpagesize() NBPC
2803 # else /* no NBPC */
2804 # ifdef PAGESIZE
2805 # define getpagesize() PAGESIZE
2806 # endif /* PAGESIZE */
2807 # endif /* no NBPC */
2808 # endif /* no NBPG */
2809 # endif /* no EXEC_PAGESIZE */
2810 # else /* no HAVE_SYS_PARAM_H */
2811 # define getpagesize() 8192 /* punt totally */
2812 # endif /* no HAVE_SYS_PARAM_H */
2813 # endif /* no _SC_PAGESIZE */
2815 #endif /* no HAVE_GETPAGESIZE */
2817 #ifdef __cplusplus
2818 extern "C" { void *malloc(unsigned); }
2819 #else
2820 char *malloc();
2821 #endif
2824 main()
2826 char *data, *data2, *data3;
2827 int i, pagesize;
2828 int fd;
2830 pagesize = getpagesize();
2833 * First, make a file with some known garbage in it.
2835 data = malloc(pagesize);
2836 if (!data)
2837 exit(1);
2838 for (i = 0; i < pagesize; ++i)
2839 *(data + i) = rand();
2840 umask(0);
2841 fd = creat("conftestmmap", 0600);
2842 if (fd < 0)
2843 exit(1);
2844 if (write(fd, data, pagesize) != pagesize)
2845 exit(1);
2846 close(fd);
2849 * Next, try to mmap the file at a fixed address which
2850 * already has something else allocated at it. If we can,
2851 * also make sure that we see the same garbage.
2853 fd = open("conftestmmap", O_RDWR);
2854 if (fd < 0)
2855 exit(1);
2856 data2 = malloc(2 * pagesize);
2857 if (!data2)
2858 exit(1);
2859 data2 += (pagesize - ((int) data2 & (pagesize - 1))) & (pagesize - 1);
2860 if (data2 != mmap(data2, pagesize, PROT_READ | PROT_WRITE,
2861 MAP_PRIVATE | MAP_FIXED, fd, 0L))
2862 exit(1);
2863 for (i = 0; i < pagesize; ++i)
2864 if (*(data + i) != *(data2 + i))
2865 exit(1);
2868 * Finally, make sure that changes to the mapped area
2869 * do not percolate back to the file as seen by read().
2870 * (This is a bug on some variants of i386 svr4.0.)
2872 for (i = 0; i < pagesize; ++i)
2873 *(data2 + i) = *(data2 + i) + 1;
2874 data3 = malloc(pagesize);
2875 if (!data3)
2876 exit(1);
2877 if (read(fd, data3, pagesize) != pagesize)
2878 exit(1);
2879 for (i = 0; i < pagesize; ++i)
2880 if (*(data + i) != *(data3 + i))
2881 exit(1);
2882 close(fd);
2883 unlink("conftestmmap");
2884 exit(0);
2888 if { (eval echo configure:2889: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2889 then
2890 ac_cv_func_mmap_fixed_mapped=yes
2891 else
2892 echo "configure: failed program was:" >&5
2893 cat conftest.$ac_ext >&5
2894 rm -fr conftest*
2895 ac_cv_func_mmap_fixed_mapped=no
2897 rm -fr conftest*
2902 echo "$ac_t""$ac_cv_func_mmap_fixed_mapped" 1>&6
2903 if test $ac_cv_func_mmap_fixed_mapped = yes; then
2904 cat >> confdefs.h <<\EOF
2905 #define HAVE_MMAP 1
2911 for ac_hdr in argz.h limits.h locale.h nl_types.h malloc.h string.h \
2912 unistd.h values.h sys/param.h
2914 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2915 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2916 echo "configure:2917: checking for $ac_hdr" >&5
2917 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2918 echo $ac_n "(cached) $ac_c" 1>&6
2919 else
2920 cat > conftest.$ac_ext <<EOF
2921 #line 2922 "configure"
2922 #include "confdefs.h"
2923 #include <$ac_hdr>
2925 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2926 { (eval echo configure:2927: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2927 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2928 if test -z "$ac_err"; then
2929 rm -rf conftest*
2930 eval "ac_cv_header_$ac_safe=yes"
2931 else
2932 echo "$ac_err" >&5
2933 echo "configure: failed program was:" >&5
2934 cat conftest.$ac_ext >&5
2935 rm -rf conftest*
2936 eval "ac_cv_header_$ac_safe=no"
2938 rm -f conftest*
2940 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2941 echo "$ac_t""yes" 1>&6
2942 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2943 cat >> confdefs.h <<EOF
2944 #define $ac_tr_hdr 1
2947 else
2948 echo "$ac_t""no" 1>&6
2950 done
2952 for ac_func in getcwd munmap putenv setenv setlocale strchr strcasecmp \
2953 __argz_count __argz_stringify __argz_next
2955 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
2956 echo "configure:2957: checking for $ac_func" >&5
2957 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2958 echo $ac_n "(cached) $ac_c" 1>&6
2959 else
2960 cat > conftest.$ac_ext <<EOF
2961 #line 2962 "configure"
2962 #include "confdefs.h"
2963 /* System header to define __stub macros and hopefully few prototypes,
2964 which can conflict with char $ac_func(); below. */
2965 #include <assert.h>
2966 /* Override any gcc2 internal prototype to avoid an error. */
2967 /* We use char because int might match the return type of a gcc2
2968 builtin and then its argument prototype would still apply. */
2969 char $ac_func();
2971 int main() {
2973 /* The GNU C library defines this for functions which it implements
2974 to always fail with ENOSYS. Some functions are actually named
2975 something starting with __ and the normal name is an alias. */
2976 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2977 choke me
2978 #else
2979 $ac_func();
2980 #endif
2982 ; return 0; }
2984 if { (eval echo configure:2985: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2985 rm -rf conftest*
2986 eval "ac_cv_func_$ac_func=yes"
2987 else
2988 echo "configure: failed program was:" >&5
2989 cat conftest.$ac_ext >&5
2990 rm -rf conftest*
2991 eval "ac_cv_func_$ac_func=no"
2993 rm -f conftest*
2996 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2997 echo "$ac_t""yes" 1>&6
2998 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2999 cat >> confdefs.h <<EOF
3000 #define $ac_tr_func 1
3003 else
3004 echo "$ac_t""no" 1>&6
3006 done
3009 if test "${ac_cv_func_stpcpy+set}" != "set"; then
3010 for ac_func in stpcpy
3012 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
3013 echo "configure:3014: checking for $ac_func" >&5
3014 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3015 echo $ac_n "(cached) $ac_c" 1>&6
3016 else
3017 cat > conftest.$ac_ext <<EOF
3018 #line 3019 "configure"
3019 #include "confdefs.h"
3020 /* System header to define __stub macros and hopefully few prototypes,
3021 which can conflict with char $ac_func(); below. */
3022 #include <assert.h>
3023 /* Override any gcc2 internal prototype to avoid an error. */
3024 /* We use char because int might match the return type of a gcc2
3025 builtin and then its argument prototype would still apply. */
3026 char $ac_func();
3028 int main() {
3030 /* The GNU C library defines this for functions which it implements
3031 to always fail with ENOSYS. Some functions are actually named
3032 something starting with __ and the normal name is an alias. */
3033 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3034 choke me
3035 #else
3036 $ac_func();
3037 #endif
3039 ; return 0; }
3041 if { (eval echo configure:3042: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3042 rm -rf conftest*
3043 eval "ac_cv_func_$ac_func=yes"
3044 else
3045 echo "configure: failed program was:" >&5
3046 cat conftest.$ac_ext >&5
3047 rm -rf conftest*
3048 eval "ac_cv_func_$ac_func=no"
3050 rm -f conftest*
3053 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3054 echo "$ac_t""yes" 1>&6
3055 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3056 cat >> confdefs.h <<EOF
3057 #define $ac_tr_func 1
3060 else
3061 echo "$ac_t""no" 1>&6
3063 done
3066 if test "${ac_cv_func_stpcpy}" = "yes"; then
3067 cat >> confdefs.h <<\EOF
3068 #define HAVE_STPCPY 1
3073 if test $ac_cv_header_locale_h = yes; then
3074 echo $ac_n "checking for LC_MESSAGES""... $ac_c" 1>&6
3075 echo "configure:3076: checking for LC_MESSAGES" >&5
3076 if eval "test \"`echo '$''{'am_cv_val_LC_MESSAGES'+set}'`\" = set"; then
3077 echo $ac_n "(cached) $ac_c" 1>&6
3078 else
3079 cat > conftest.$ac_ext <<EOF
3080 #line 3081 "configure"
3081 #include "confdefs.h"
3082 #include <locale.h>
3083 int main() {
3084 return LC_MESSAGES
3085 ; return 0; }
3087 if { (eval echo configure:3088: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3088 rm -rf conftest*
3089 am_cv_val_LC_MESSAGES=yes
3090 else
3091 echo "configure: failed program was:" >&5
3092 cat conftest.$ac_ext >&5
3093 rm -rf conftest*
3094 am_cv_val_LC_MESSAGES=no
3096 rm -f conftest*
3099 echo "$ac_t""$am_cv_val_LC_MESSAGES" 1>&6
3100 if test $am_cv_val_LC_MESSAGES = yes; then
3101 cat >> confdefs.h <<\EOF
3102 #define HAVE_LC_MESSAGES 1
3107 echo $ac_n "checking whether NLS is requested""... $ac_c" 1>&6
3108 echo "configure:3109: checking whether NLS is requested" >&5
3109 # Check whether --enable-nls or --disable-nls was given.
3110 if test "${enable_nls+set}" = set; then
3111 enableval="$enable_nls"
3112 USE_NLS=$enableval
3113 else
3114 USE_NLS=yes
3117 echo "$ac_t""$USE_NLS" 1>&6
3120 USE_INCLUDED_LIBINTL=no
3122 if test "$USE_NLS" = "yes"; then
3123 cat >> confdefs.h <<\EOF
3124 #define ENABLE_NLS 1
3127 echo $ac_n "checking whether included gettext is requested""... $ac_c" 1>&6
3128 echo "configure:3129: checking whether included gettext is requested" >&5
3129 # Check whether --with-included-gettext or --without-included-gettext was given.
3130 if test "${with_included_gettext+set}" = set; then
3131 withval="$with_included_gettext"
3132 nls_cv_force_use_gnu_gettext=$withval
3133 else
3134 nls_cv_force_use_gnu_gettext=no
3137 echo "$ac_t""$nls_cv_force_use_gnu_gettext" 1>&6
3139 nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext"
3140 if test "$nls_cv_force_use_gnu_gettext" != "yes"; then
3141 nls_cv_header_intl=
3142 nls_cv_header_libgt=
3143 CATOBJEXT=NONE
3145 ac_safe=`echo "libintl.h" | sed 'y%./+-%__p_%'`
3146 echo $ac_n "checking for libintl.h""... $ac_c" 1>&6
3147 echo "configure:3148: checking for libintl.h" >&5
3148 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3149 echo $ac_n "(cached) $ac_c" 1>&6
3150 else
3151 cat > conftest.$ac_ext <<EOF
3152 #line 3153 "configure"
3153 #include "confdefs.h"
3154 #include <libintl.h>
3156 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3157 { (eval echo configure:3158: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3158 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3159 if test -z "$ac_err"; then
3160 rm -rf conftest*
3161 eval "ac_cv_header_$ac_safe=yes"
3162 else
3163 echo "$ac_err" >&5
3164 echo "configure: failed program was:" >&5
3165 cat conftest.$ac_ext >&5
3166 rm -rf conftest*
3167 eval "ac_cv_header_$ac_safe=no"
3169 rm -f conftest*
3171 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3172 echo "$ac_t""yes" 1>&6
3173 echo $ac_n "checking for gettext in libc""... $ac_c" 1>&6
3174 echo "configure:3175: checking for gettext in libc" >&5
3175 if eval "test \"`echo '$''{'gt_cv_func_gettext_libc'+set}'`\" = set"; then
3176 echo $ac_n "(cached) $ac_c" 1>&6
3177 else
3178 cat > conftest.$ac_ext <<EOF
3179 #line 3180 "configure"
3180 #include "confdefs.h"
3181 #include <libintl.h>
3182 int main() {
3183 return (int) gettext ("")
3184 ; return 0; }
3186 if { (eval echo configure:3187: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3187 rm -rf conftest*
3188 gt_cv_func_gettext_libc=yes
3189 else
3190 echo "configure: failed program was:" >&5
3191 cat conftest.$ac_ext >&5
3192 rm -rf conftest*
3193 gt_cv_func_gettext_libc=no
3195 rm -f conftest*
3198 echo "$ac_t""$gt_cv_func_gettext_libc" 1>&6
3200 if test "$gt_cv_func_gettext_libc" != "yes"; then
3201 echo $ac_n "checking for bindtextdomain in -lintl""... $ac_c" 1>&6
3202 echo "configure:3203: checking for bindtextdomain in -lintl" >&5
3203 ac_lib_var=`echo intl'_'bindtextdomain | sed 'y%./+-%__p_%'`
3204 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3205 echo $ac_n "(cached) $ac_c" 1>&6
3206 else
3207 ac_save_LIBS="$LIBS"
3208 LIBS="-lintl $LIBS"
3209 cat > conftest.$ac_ext <<EOF
3210 #line 3211 "configure"
3211 #include "confdefs.h"
3212 /* Override any gcc2 internal prototype to avoid an error. */
3213 /* We use char because int might match the return type of a gcc2
3214 builtin and then its argument prototype would still apply. */
3215 char bindtextdomain();
3217 int main() {
3218 bindtextdomain()
3219 ; return 0; }
3221 if { (eval echo configure:3222: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3222 rm -rf conftest*
3223 eval "ac_cv_lib_$ac_lib_var=yes"
3224 else
3225 echo "configure: failed program was:" >&5
3226 cat conftest.$ac_ext >&5
3227 rm -rf conftest*
3228 eval "ac_cv_lib_$ac_lib_var=no"
3230 rm -f conftest*
3231 LIBS="$ac_save_LIBS"
3234 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3235 echo "$ac_t""yes" 1>&6
3236 echo $ac_n "checking for gettext in libintl""... $ac_c" 1>&6
3237 echo "configure:3238: checking for gettext in libintl" >&5
3238 if eval "test \"`echo '$''{'gt_cv_func_gettext_libintl'+set}'`\" = set"; then
3239 echo $ac_n "(cached) $ac_c" 1>&6
3240 else
3241 cat > conftest.$ac_ext <<EOF
3242 #line 3243 "configure"
3243 #include "confdefs.h"
3245 int main() {
3246 return (int) gettext ("")
3247 ; return 0; }
3249 if { (eval echo configure:3250: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3250 rm -rf conftest*
3251 gt_cv_func_gettext_libintl=yes
3252 else
3253 echo "configure: failed program was:" >&5
3254 cat conftest.$ac_ext >&5
3255 rm -rf conftest*
3256 gt_cv_func_gettext_libintl=no
3258 rm -f conftest*
3261 echo "$ac_t""$gt_cv_func_gettext_libintl" 1>&6
3262 else
3263 echo "$ac_t""no" 1>&6
3268 if test "$gt_cv_func_gettext_libc" = "yes" \
3269 || test "$gt_cv_func_gettext_libintl" = "yes"; then
3270 cat >> confdefs.h <<\EOF
3271 #define HAVE_GETTEXT 1
3274 # Extract the first word of "msgfmt", so it can be a program name with args.
3275 set dummy msgfmt; ac_word=$2
3276 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3277 echo "configure:3278: checking for $ac_word" >&5
3278 if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
3279 echo $ac_n "(cached) $ac_c" 1>&6
3280 else
3281 case "$MSGFMT" in
3283 ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
3286 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
3287 for ac_dir in $PATH; do
3288 test -z "$ac_dir" && ac_dir=.
3289 if test -f $ac_dir/$ac_word; then
3290 if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then
3291 ac_cv_path_MSGFMT="$ac_dir/$ac_word"
3292 break
3295 done
3296 IFS="$ac_save_ifs"
3297 test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="no"
3299 esac
3301 MSGFMT="$ac_cv_path_MSGFMT"
3302 if test -n "$MSGFMT"; then
3303 echo "$ac_t""$MSGFMT" 1>&6
3304 else
3305 echo "$ac_t""no" 1>&6
3307 if test "$MSGFMT" != "no"; then
3308 for ac_func in dcgettext
3310 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
3311 echo "configure:3312: checking for $ac_func" >&5
3312 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3313 echo $ac_n "(cached) $ac_c" 1>&6
3314 else
3315 cat > conftest.$ac_ext <<EOF
3316 #line 3317 "configure"
3317 #include "confdefs.h"
3318 /* System header to define __stub macros and hopefully few prototypes,
3319 which can conflict with char $ac_func(); below. */
3320 #include <assert.h>
3321 /* Override any gcc2 internal prototype to avoid an error. */
3322 /* We use char because int might match the return type of a gcc2
3323 builtin and then its argument prototype would still apply. */
3324 char $ac_func();
3326 int main() {
3328 /* The GNU C library defines this for functions which it implements
3329 to always fail with ENOSYS. Some functions are actually named
3330 something starting with __ and the normal name is an alias. */
3331 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3332 choke me
3333 #else
3334 $ac_func();
3335 #endif
3337 ; return 0; }
3339 if { (eval echo configure:3340: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3340 rm -rf conftest*
3341 eval "ac_cv_func_$ac_func=yes"
3342 else
3343 echo "configure: failed program was:" >&5
3344 cat conftest.$ac_ext >&5
3345 rm -rf conftest*
3346 eval "ac_cv_func_$ac_func=no"
3348 rm -f conftest*
3351 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3352 echo "$ac_t""yes" 1>&6
3353 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3354 cat >> confdefs.h <<EOF
3355 #define $ac_tr_func 1
3358 else
3359 echo "$ac_t""no" 1>&6
3361 done
3363 # Extract the first word of "gmsgfmt", so it can be a program name with args.
3364 set dummy gmsgfmt; ac_word=$2
3365 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3366 echo "configure:3367: checking for $ac_word" >&5
3367 if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
3368 echo $ac_n "(cached) $ac_c" 1>&6
3369 else
3370 case "$GMSGFMT" in
3372 ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
3374 ?:/*)
3375 ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a dos path.
3378 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3379 ac_dummy="$PATH"
3380 for ac_dir in $ac_dummy; do
3381 test -z "$ac_dir" && ac_dir=.
3382 if test -f $ac_dir/$ac_word; then
3383 ac_cv_path_GMSGFMT="$ac_dir/$ac_word"
3384 break
3386 done
3387 IFS="$ac_save_ifs"
3388 test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
3390 esac
3392 GMSGFMT="$ac_cv_path_GMSGFMT"
3393 if test -n "$GMSGFMT"; then
3394 echo "$ac_t""$GMSGFMT" 1>&6
3395 else
3396 echo "$ac_t""no" 1>&6
3399 # Extract the first word of "xgettext", so it can be a program name with args.
3400 set dummy xgettext; ac_word=$2
3401 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3402 echo "configure:3403: checking for $ac_word" >&5
3403 if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
3404 echo $ac_n "(cached) $ac_c" 1>&6
3405 else
3406 case "$XGETTEXT" in
3408 ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
3411 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
3412 for ac_dir in $PATH; do
3413 test -z "$ac_dir" && ac_dir=.
3414 if test -f $ac_dir/$ac_word; then
3415 if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then
3416 ac_cv_path_XGETTEXT="$ac_dir/$ac_word"
3417 break
3420 done
3421 IFS="$ac_save_ifs"
3422 test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
3424 esac
3426 XGETTEXT="$ac_cv_path_XGETTEXT"
3427 if test -n "$XGETTEXT"; then
3428 echo "$ac_t""$XGETTEXT" 1>&6
3429 else
3430 echo "$ac_t""no" 1>&6
3433 cat > conftest.$ac_ext <<EOF
3434 #line 3435 "configure"
3435 #include "confdefs.h"
3437 int main() {
3438 extern int _nl_msg_cat_cntr;
3439 return _nl_msg_cat_cntr
3440 ; return 0; }
3442 if { (eval echo configure:3443: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3443 rm -rf conftest*
3444 CATOBJEXT=.gmo
3445 DATADIRNAME=share
3446 else
3447 echo "configure: failed program was:" >&5
3448 cat conftest.$ac_ext >&5
3449 rm -rf conftest*
3450 CATOBJEXT=.mo
3451 DATADIRNAME=lib
3453 rm -f conftest*
3454 INSTOBJEXT=.mo
3458 else
3459 echo "$ac_t""no" 1>&6
3464 if test "$CATOBJEXT" = "NONE"; then
3465 nls_cv_use_gnu_gettext=yes
3469 if test "$nls_cv_use_gnu_gettext" = "yes"; then
3470 INTLOBJS="\$(GETTOBJS)"
3471 # Extract the first word of "msgfmt", so it can be a program name with args.
3472 set dummy msgfmt; ac_word=$2
3473 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3474 echo "configure:3475: checking for $ac_word" >&5
3475 if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
3476 echo $ac_n "(cached) $ac_c" 1>&6
3477 else
3478 case "$MSGFMT" in
3480 ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
3483 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
3484 for ac_dir in $PATH; do
3485 test -z "$ac_dir" && ac_dir=.
3486 if test -f $ac_dir/$ac_word; then
3487 if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then
3488 ac_cv_path_MSGFMT="$ac_dir/$ac_word"
3489 break
3492 done
3493 IFS="$ac_save_ifs"
3494 test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="msgfmt"
3496 esac
3498 MSGFMT="$ac_cv_path_MSGFMT"
3499 if test -n "$MSGFMT"; then
3500 echo "$ac_t""$MSGFMT" 1>&6
3501 else
3502 echo "$ac_t""no" 1>&6
3505 # Extract the first word of "gmsgfmt", so it can be a program name with args.
3506 set dummy gmsgfmt; ac_word=$2
3507 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3508 echo "configure:3509: checking for $ac_word" >&5
3509 if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
3510 echo $ac_n "(cached) $ac_c" 1>&6
3511 else
3512 case "$GMSGFMT" in
3514 ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
3516 ?:/*)
3517 ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a dos path.
3520 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3521 ac_dummy="$PATH"
3522 for ac_dir in $ac_dummy; do
3523 test -z "$ac_dir" && ac_dir=.
3524 if test -f $ac_dir/$ac_word; then
3525 ac_cv_path_GMSGFMT="$ac_dir/$ac_word"
3526 break
3528 done
3529 IFS="$ac_save_ifs"
3530 test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
3532 esac
3534 GMSGFMT="$ac_cv_path_GMSGFMT"
3535 if test -n "$GMSGFMT"; then
3536 echo "$ac_t""$GMSGFMT" 1>&6
3537 else
3538 echo "$ac_t""no" 1>&6
3541 # Extract the first word of "xgettext", so it can be a program name with args.
3542 set dummy xgettext; ac_word=$2
3543 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3544 echo "configure:3545: checking for $ac_word" >&5
3545 if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
3546 echo $ac_n "(cached) $ac_c" 1>&6
3547 else
3548 case "$XGETTEXT" in
3550 ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
3553 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
3554 for ac_dir in $PATH; do
3555 test -z "$ac_dir" && ac_dir=.
3556 if test -f $ac_dir/$ac_word; then
3557 if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then
3558 ac_cv_path_XGETTEXT="$ac_dir/$ac_word"
3559 break
3562 done
3563 IFS="$ac_save_ifs"
3564 test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
3566 esac
3568 XGETTEXT="$ac_cv_path_XGETTEXT"
3569 if test -n "$XGETTEXT"; then
3570 echo "$ac_t""$XGETTEXT" 1>&6
3571 else
3572 echo "$ac_t""no" 1>&6
3576 USE_INCLUDED_LIBINTL=yes
3577 CATOBJEXT=.gmo
3578 INSTOBJEXT=.mo
3579 DATADIRNAME=share
3580 INTLDEPS='$(top_builddir)/../intl/libintl.a'
3581 INTLLIBS=$INTLDEPS
3582 LIBS=`echo $LIBS | sed -e 's/-lintl//'`
3583 nls_cv_header_intl=libintl.h
3584 nls_cv_header_libgt=libgettext.h
3587 if test "$XGETTEXT" != ":"; then
3588 if $XGETTEXT --omit-header /dev/null 2> /dev/null; then
3590 else
3591 echo "$ac_t""found xgettext programs is not GNU xgettext; ignore it" 1>&6
3592 XGETTEXT=":"
3596 # We need to process the po/ directory.
3597 POSUB=po
3598 else
3599 DATADIRNAME=share
3600 nls_cv_header_intl=libintl.h
3601 nls_cv_header_libgt=libgettext.h
3604 # If this is used in GNU gettext we have to set USE_NLS to `yes'
3605 # because some of the sources are only built for this goal.
3606 if test "$PACKAGE" = gettext; then
3607 USE_NLS=yes
3608 USE_INCLUDED_LIBINTL=yes
3611 for lang in $ALL_LINGUAS; do
3612 GMOFILES="$GMOFILES $lang.gmo"
3613 POFILES="$POFILES $lang.po"
3614 done
3629 if test "x$CATOBJEXT" != "x"; then
3630 if test "x$ALL_LINGUAS" = "x"; then
3631 LINGUAS=
3632 else
3633 echo $ac_n "checking for catalogs to be installed""... $ac_c" 1>&6
3634 echo "configure:3635: checking for catalogs to be installed" >&5
3635 NEW_LINGUAS=
3636 for lang in ${LINGUAS=$ALL_LINGUAS}; do
3637 case "$ALL_LINGUAS" in
3638 *$lang*) NEW_LINGUAS="$NEW_LINGUAS $lang" ;;
3639 esac
3640 done
3641 LINGUAS=$NEW_LINGUAS
3642 echo "$ac_t""$LINGUAS" 1>&6
3645 if test -n "$LINGUAS"; then
3646 for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done
3650 if test $ac_cv_header_locale_h = yes; then
3651 INCLUDE_LOCALE_H="#include <locale.h>"
3652 else
3653 INCLUDE_LOCALE_H="\
3654 /* The system does not provide the header <locale.h>. Take care yourself. */"
3658 if test -f $srcdir/po2tbl.sed.in; then
3659 if test "$CATOBJEXT" = ".cat"; then
3660 ac_safe=`echo "linux/version.h" | sed 'y%./+-%__p_%'`
3661 echo $ac_n "checking for linux/version.h""... $ac_c" 1>&6
3662 echo "configure:3663: checking for linux/version.h" >&5
3663 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3664 echo $ac_n "(cached) $ac_c" 1>&6
3665 else
3666 cat > conftest.$ac_ext <<EOF
3667 #line 3668 "configure"
3668 #include "confdefs.h"
3669 #include <linux/version.h>
3671 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3672 { (eval echo configure:3673: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3673 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3674 if test -z "$ac_err"; then
3675 rm -rf conftest*
3676 eval "ac_cv_header_$ac_safe=yes"
3677 else
3678 echo "$ac_err" >&5
3679 echo "configure: failed program was:" >&5
3680 cat conftest.$ac_ext >&5
3681 rm -rf conftest*
3682 eval "ac_cv_header_$ac_safe=no"
3684 rm -f conftest*
3686 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3687 echo "$ac_t""yes" 1>&6
3688 msgformat=linux
3689 else
3690 echo "$ac_t""no" 1>&6
3691 msgformat=xopen
3695 sed -e '/^#/d' $srcdir/$msgformat-msg.sed > po2msg.sed
3697 sed -e '/^#.*[^\\]$/d' -e '/^#$/d' \
3698 $srcdir/po2tbl.sed.in > po2tbl.sed
3701 if test "$PACKAGE" = "gettext"; then
3702 GT_NO="#NO#"
3703 GT_YES=
3704 else
3705 GT_NO=
3706 GT_YES="#YES#"
3711 MKINSTALLDIRS="\$(srcdir)/../../mkinstalldirs"
3717 if test -d $srcdir/po; then
3718 test -d po || mkdir po
3719 if test "x$srcdir" != "x."; then
3720 if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then
3721 posrcprefix="$srcdir/"
3722 else
3723 posrcprefix="../$srcdir/"
3725 else
3726 posrcprefix="../"
3728 rm -f po/POTFILES
3729 sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \
3730 < $srcdir/po/POTFILES.in > po/POTFILES
3734 echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
3735 echo "configure:3736: checking whether to enable maintainer-specific portions of Makefiles" >&5
3736 # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
3737 if test "${enable_maintainer_mode+set}" = set; then
3738 enableval="$enable_maintainer_mode"
3739 USE_MAINTAINER_MODE=$enableval
3740 else
3741 USE_MAINTAINER_MODE=no
3744 echo "$ac_t""$USE_MAINTAINER_MODE" 1>&6
3747 if test $USE_MAINTAINER_MODE = yes; then
3748 MAINTAINER_MODE_TRUE=
3749 MAINTAINER_MODE_FALSE='#'
3750 else
3751 MAINTAINER_MODE_TRUE='#'
3752 MAINTAINER_MODE_FALSE=
3754 MAINT=$MAINTAINER_MODE_TRUE
3757 echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
3758 echo "configure:3759: checking for Cygwin environment" >&5
3759 if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
3760 echo $ac_n "(cached) $ac_c" 1>&6
3761 else
3762 cat > conftest.$ac_ext <<EOF
3763 #line 3764 "configure"
3764 #include "confdefs.h"
3766 int main() {
3768 #ifndef __CYGWIN__
3769 #define __CYGWIN__ __CYGWIN32__
3770 #endif
3771 return __CYGWIN__;
3772 ; return 0; }
3774 if { (eval echo configure:3775: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3775 rm -rf conftest*
3776 ac_cv_cygwin=yes
3777 else
3778 echo "configure: failed program was:" >&5
3779 cat conftest.$ac_ext >&5
3780 rm -rf conftest*
3781 ac_cv_cygwin=no
3783 rm -f conftest*
3784 rm -f conftest*
3787 echo "$ac_t""$ac_cv_cygwin" 1>&6
3788 CYGWIN=
3789 test "$ac_cv_cygwin" = yes && CYGWIN=yes
3790 echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
3791 echo "configure:3792: checking for mingw32 environment" >&5
3792 if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
3793 echo $ac_n "(cached) $ac_c" 1>&6
3794 else
3795 cat > conftest.$ac_ext <<EOF
3796 #line 3797 "configure"
3797 #include "confdefs.h"
3799 int main() {
3800 return __MINGW32__;
3801 ; return 0; }
3803 if { (eval echo configure:3804: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3804 rm -rf conftest*
3805 ac_cv_mingw32=yes
3806 else
3807 echo "configure: failed program was:" >&5
3808 cat conftest.$ac_ext >&5
3809 rm -rf conftest*
3810 ac_cv_mingw32=no
3812 rm -f conftest*
3813 rm -f conftest*
3816 echo "$ac_t""$ac_cv_mingw32" 1>&6
3817 MINGW32=
3818 test "$ac_cv_mingw32" = yes && MINGW32=yes
3821 echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
3822 echo "configure:3823: checking for executable suffix" >&5
3823 if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
3824 echo $ac_n "(cached) $ac_c" 1>&6
3825 else
3826 if test "$CYGWIN" = yes || test "$MINGW32" = yes; then
3827 ac_cv_exeext=.exe
3828 else
3829 rm -f conftest*
3830 echo 'int main () { return 0; }' > conftest.$ac_ext
3831 ac_cv_exeext=
3832 if { (eval echo configure:3833: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
3833 for file in conftest.*; do
3834 case $file in
3835 *.c | *.o | *.obj | *.ilk | *.pdb) ;;
3836 *) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
3837 esac
3838 done
3839 else
3840 { echo "configure: error: installation or configuration problem: compiler cannot create executables." 1>&2; exit 1; }
3842 rm -f conftest*
3843 test x"${ac_cv_exeext}" = x && ac_cv_exeext=no
3847 EXEEXT=""
3848 test x"${ac_cv_exeext}" != xno && EXEEXT=${ac_cv_exeext}
3849 echo "$ac_t""${ac_cv_exeext}" 1>&6
3850 ac_exeext=$EXEEXT
3852 if test -n "$EXEEXT"; then
3853 cat >> confdefs.h <<\EOF
3854 #define HAVE_EXECUTABLE_SUFFIX 1
3858 cat >> confdefs.h <<EOF
3859 #define EXECUTABLE_SUFFIX "${EXEEXT}"
3863 # host-specific stuff:
3865 HDEFINES=
3867 . ${srcdir}/../bfd/configure.host
3870 AR=${AR-ar}
3872 # Extract the first word of "ranlib", so it can be a program name with args.
3873 set dummy ranlib; ac_word=$2
3874 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3875 echo "configure:3876: checking for $ac_word" >&5
3876 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
3877 echo $ac_n "(cached) $ac_c" 1>&6
3878 else
3879 if test -n "$RANLIB"; then
3880 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
3881 else
3882 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3883 ac_dummy="$PATH"
3884 for ac_dir in $ac_dummy; do
3885 test -z "$ac_dir" && ac_dir=.
3886 if test -f $ac_dir/$ac_word; then
3887 ac_cv_prog_RANLIB="ranlib"
3888 break
3890 done
3891 IFS="$ac_save_ifs"
3892 test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
3895 RANLIB="$ac_cv_prog_RANLIB"
3896 if test -n "$RANLIB"; then
3897 echo "$ac_t""$RANLIB" 1>&6
3898 else
3899 echo "$ac_t""no" 1>&6
3902 # Find a good install program. We prefer a C program (faster),
3903 # so one script is as good as another. But avoid the broken or
3904 # incompatible versions:
3905 # SysV /etc/install, /usr/sbin/install
3906 # SunOS /usr/etc/install
3907 # IRIX /sbin/install
3908 # AIX /bin/install
3909 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3910 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
3911 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3912 # ./install, which can be erroneously created by make from ./install.sh.
3913 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
3914 echo "configure:3915: checking for a BSD compatible install" >&5
3915 if test -z "$INSTALL"; then
3916 if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
3917 echo $ac_n "(cached) $ac_c" 1>&6
3918 else
3919 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":"
3920 for ac_dir in $PATH; do
3921 # Account for people who put trailing slashes in PATH elements.
3922 case "$ac_dir/" in
3923 /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
3925 # OSF1 and SCO ODT 3.0 have their own names for install.
3926 # Don't use installbsd from OSF since it installs stuff as root
3927 # by default.
3928 for ac_prog in ginstall scoinst install; do
3929 if test -f $ac_dir/$ac_prog; then
3930 if test $ac_prog = install &&
3931 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
3932 # AIX install. It has an incompatible calling convention.
3934 else
3935 ac_cv_path_install="$ac_dir/$ac_prog -c"
3936 break 2
3939 done
3941 esac
3942 done
3943 IFS="$ac_save_IFS"
3946 if test "${ac_cv_path_install+set}" = set; then
3947 INSTALL="$ac_cv_path_install"
3948 else
3949 # As a last resort, use the slow shell script. We don't cache a
3950 # path for INSTALL within a source directory, because that will
3951 # break other packages using the cache if that directory is
3952 # removed, or if the path is relative.
3953 INSTALL="$ac_install_sh"
3956 echo "$ac_t""$INSTALL" 1>&6
3958 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3959 # It thinks the first close brace ends the variable substitution.
3960 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3962 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
3964 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3967 # Put a plausible default for CC_FOR_BUILD in Makefile.
3968 if test -z "$CC_FOR_BUILD"; then
3969 if test "x$cross_compiling" = "xno"; then
3970 CC_FOR_BUILD='$(CC)'
3971 else
3972 CC_FOR_BUILD=gcc
3976 # Also set EXEEXT_FOR_BUILD.
3977 if test "x$cross_compiling" = "xno"; then
3978 EXEEXT_FOR_BUILD='$(EXEEXT)'
3979 else
3980 echo $ac_n "checking for build system executable suffix""... $ac_c" 1>&6
3981 echo "configure:3982: checking for build system executable suffix" >&5
3982 if eval "test \"`echo '$''{'bfd_cv_build_exeext'+set}'`\" = set"; then
3983 echo $ac_n "(cached) $ac_c" 1>&6
3984 else
3985 rm -f conftest*
3986 echo 'int main () { return 0; }' > conftest.c
3987 bfd_cv_build_exeext=
3988 ${CC_FOR_BUILD} -o conftest conftest.c 1>&5 2>&5
3989 for file in conftest.*; do
3990 case $file in
3991 *.c | *.o | *.obj | *.ilk | *.pdb) ;;
3992 *) bfd_cv_build_exeext=`echo $file | sed -e s/conftest//` ;;
3993 esac
3994 done
3995 rm -f conftest*
3996 test x"${bfd_cv_build_exeext}" = x && bfd_cv_build_exeext=no
3999 echo "$ac_t""$bfd_cv_build_exeext" 1>&6
4000 EXEEXT_FOR_BUILD=""
4001 test x"${bfd_cv_build_exeext}" != xno && EXEEXT_FOR_BUILD=${bfd_cv_build_exeext}
4005 DEMANGLER_NAME=c++filt
4006 case "${host}" in
4007 *-*-go32* | *-*-msdos*)
4008 DEMANGLER_NAME=cxxfilt
4009 esac
4012 for ac_hdr in string.h strings.h stdlib.h unistd.h fcntl.h sys/file.h
4014 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4015 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4016 echo "configure:4017: checking for $ac_hdr" >&5
4017 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4018 echo $ac_n "(cached) $ac_c" 1>&6
4019 else
4020 cat > conftest.$ac_ext <<EOF
4021 #line 4022 "configure"
4022 #include "confdefs.h"
4023 #include <$ac_hdr>
4025 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4026 { (eval echo configure:4027: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4027 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4028 if test -z "$ac_err"; then
4029 rm -rf conftest*
4030 eval "ac_cv_header_$ac_safe=yes"
4031 else
4032 echo "$ac_err" >&5
4033 echo "configure: failed program was:" >&5
4034 cat conftest.$ac_ext >&5
4035 rm -rf conftest*
4036 eval "ac_cv_header_$ac_safe=no"
4038 rm -f conftest*
4040 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4041 echo "$ac_t""yes" 1>&6
4042 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4043 cat >> confdefs.h <<EOF
4044 #define $ac_tr_hdr 1
4047 else
4048 echo "$ac_t""no" 1>&6
4050 done
4052 echo $ac_n "checking for sys/wait.h that is POSIX.1 compatible""... $ac_c" 1>&6
4053 echo "configure:4054: checking for sys/wait.h that is POSIX.1 compatible" >&5
4054 if eval "test \"`echo '$''{'ac_cv_header_sys_wait_h'+set}'`\" = set"; then
4055 echo $ac_n "(cached) $ac_c" 1>&6
4056 else
4057 cat > conftest.$ac_ext <<EOF
4058 #line 4059 "configure"
4059 #include "confdefs.h"
4060 #include <sys/types.h>
4061 #include <sys/wait.h>
4062 #ifndef WEXITSTATUS
4063 #define WEXITSTATUS(stat_val) ((unsigned)(stat_val) >> 8)
4064 #endif
4065 #ifndef WIFEXITED
4066 #define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
4067 #endif
4068 int main() {
4069 int s;
4070 wait (&s);
4071 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
4072 ; return 0; }
4074 if { (eval echo configure:4075: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4075 rm -rf conftest*
4076 ac_cv_header_sys_wait_h=yes
4077 else
4078 echo "configure: failed program was:" >&5
4079 cat conftest.$ac_ext >&5
4080 rm -rf conftest*
4081 ac_cv_header_sys_wait_h=no
4083 rm -f conftest*
4086 echo "$ac_t""$ac_cv_header_sys_wait_h" 1>&6
4087 if test $ac_cv_header_sys_wait_h = yes; then
4088 cat >> confdefs.h <<\EOF
4089 #define HAVE_SYS_WAIT_H 1
4094 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
4095 # for constant arguments. Useless!
4096 echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
4097 echo "configure:4098: checking for working alloca.h" >&5
4098 if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
4099 echo $ac_n "(cached) $ac_c" 1>&6
4100 else
4101 cat > conftest.$ac_ext <<EOF
4102 #line 4103 "configure"
4103 #include "confdefs.h"
4104 #include <alloca.h>
4105 int main() {
4106 char *p = alloca(2 * sizeof(int));
4107 ; return 0; }
4109 if { (eval echo configure:4110: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4110 rm -rf conftest*
4111 ac_cv_header_alloca_h=yes
4112 else
4113 echo "configure: failed program was:" >&5
4114 cat conftest.$ac_ext >&5
4115 rm -rf conftest*
4116 ac_cv_header_alloca_h=no
4118 rm -f conftest*
4121 echo "$ac_t""$ac_cv_header_alloca_h" 1>&6
4122 if test $ac_cv_header_alloca_h = yes; then
4123 cat >> confdefs.h <<\EOF
4124 #define HAVE_ALLOCA_H 1
4129 echo $ac_n "checking for alloca""... $ac_c" 1>&6
4130 echo "configure:4131: checking for alloca" >&5
4131 if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
4132 echo $ac_n "(cached) $ac_c" 1>&6
4133 else
4134 cat > conftest.$ac_ext <<EOF
4135 #line 4136 "configure"
4136 #include "confdefs.h"
4138 #ifdef __GNUC__
4139 # define alloca __builtin_alloca
4140 #else
4141 # ifdef _MSC_VER
4142 # include <malloc.h>
4143 # define alloca _alloca
4144 # else
4145 # if HAVE_ALLOCA_H
4146 # include <alloca.h>
4147 # else
4148 # ifdef _AIX
4149 #pragma alloca
4150 # else
4151 # ifndef alloca /* predefined by HP cc +Olibcalls */
4152 char *alloca ();
4153 # endif
4154 # endif
4155 # endif
4156 # endif
4157 #endif
4159 int main() {
4160 char *p = (char *) alloca(1);
4161 ; return 0; }
4163 if { (eval echo configure:4164: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4164 rm -rf conftest*
4165 ac_cv_func_alloca_works=yes
4166 else
4167 echo "configure: failed program was:" >&5
4168 cat conftest.$ac_ext >&5
4169 rm -rf conftest*
4170 ac_cv_func_alloca_works=no
4172 rm -f conftest*
4175 echo "$ac_t""$ac_cv_func_alloca_works" 1>&6
4176 if test $ac_cv_func_alloca_works = yes; then
4177 cat >> confdefs.h <<\EOF
4178 #define HAVE_ALLOCA 1
4183 if test $ac_cv_func_alloca_works = no; then
4184 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
4185 # that cause trouble. Some versions do not even contain alloca or
4186 # contain a buggy version. If you still want to use their alloca,
4187 # use ar to extract alloca.o from them instead of compiling alloca.c.
4188 ALLOCA=alloca.${ac_objext}
4189 cat >> confdefs.h <<\EOF
4190 #define C_ALLOCA 1
4194 echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
4195 echo "configure:4196: checking whether alloca needs Cray hooks" >&5
4196 if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
4197 echo $ac_n "(cached) $ac_c" 1>&6
4198 else
4199 cat > conftest.$ac_ext <<EOF
4200 #line 4201 "configure"
4201 #include "confdefs.h"
4202 #if defined(CRAY) && ! defined(CRAY2)
4203 webecray
4204 #else
4205 wenotbecray
4206 #endif
4209 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4210 egrep "webecray" >/dev/null 2>&1; then
4211 rm -rf conftest*
4212 ac_cv_os_cray=yes
4213 else
4214 rm -rf conftest*
4215 ac_cv_os_cray=no
4217 rm -f conftest*
4221 echo "$ac_t""$ac_cv_os_cray" 1>&6
4222 if test $ac_cv_os_cray = yes; then
4223 for ac_func in _getb67 GETB67 getb67; do
4224 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
4225 echo "configure:4226: checking for $ac_func" >&5
4226 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
4227 echo $ac_n "(cached) $ac_c" 1>&6
4228 else
4229 cat > conftest.$ac_ext <<EOF
4230 #line 4231 "configure"
4231 #include "confdefs.h"
4232 /* System header to define __stub macros and hopefully few prototypes,
4233 which can conflict with char $ac_func(); below. */
4234 #include <assert.h>
4235 /* Override any gcc2 internal prototype to avoid an error. */
4236 /* We use char because int might match the return type of a gcc2
4237 builtin and then its argument prototype would still apply. */
4238 char $ac_func();
4240 int main() {
4242 /* The GNU C library defines this for functions which it implements
4243 to always fail with ENOSYS. Some functions are actually named
4244 something starting with __ and the normal name is an alias. */
4245 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
4246 choke me
4247 #else
4248 $ac_func();
4249 #endif
4251 ; return 0; }
4253 if { (eval echo configure:4254: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4254 rm -rf conftest*
4255 eval "ac_cv_func_$ac_func=yes"
4256 else
4257 echo "configure: failed program was:" >&5
4258 cat conftest.$ac_ext >&5
4259 rm -rf conftest*
4260 eval "ac_cv_func_$ac_func=no"
4262 rm -f conftest*
4265 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
4266 echo "$ac_t""yes" 1>&6
4267 cat >> confdefs.h <<EOF
4268 #define CRAY_STACKSEG_END $ac_func
4271 break
4272 else
4273 echo "$ac_t""no" 1>&6
4276 done
4279 echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
4280 echo "configure:4281: checking stack direction for C alloca" >&5
4281 if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
4282 echo $ac_n "(cached) $ac_c" 1>&6
4283 else
4284 if test "$cross_compiling" = yes; then
4285 ac_cv_c_stack_direction=0
4286 else
4287 cat > conftest.$ac_ext <<EOF
4288 #line 4289 "configure"
4289 #include "confdefs.h"
4290 find_stack_direction ()
4292 static char *addr = 0;
4293 auto char dummy;
4294 if (addr == 0)
4296 addr = &dummy;
4297 return find_stack_direction ();
4299 else
4300 return (&dummy > addr) ? 1 : -1;
4302 main ()
4304 exit (find_stack_direction() < 0);
4307 if { (eval echo configure:4308: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
4308 then
4309 ac_cv_c_stack_direction=1
4310 else
4311 echo "configure: failed program was:" >&5
4312 cat conftest.$ac_ext >&5
4313 rm -fr conftest*
4314 ac_cv_c_stack_direction=-1
4316 rm -fr conftest*
4321 echo "$ac_t""$ac_cv_c_stack_direction" 1>&6
4322 cat >> confdefs.h <<EOF
4323 #define STACK_DIRECTION $ac_cv_c_stack_direction
4328 for ac_func in sbrk utimes
4330 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
4331 echo "configure:4332: checking for $ac_func" >&5
4332 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
4333 echo $ac_n "(cached) $ac_c" 1>&6
4334 else
4335 cat > conftest.$ac_ext <<EOF
4336 #line 4337 "configure"
4337 #include "confdefs.h"
4338 /* System header to define __stub macros and hopefully few prototypes,
4339 which can conflict with char $ac_func(); below. */
4340 #include <assert.h>
4341 /* Override any gcc2 internal prototype to avoid an error. */
4342 /* We use char because int might match the return type of a gcc2
4343 builtin and then its argument prototype would still apply. */
4344 char $ac_func();
4346 int main() {
4348 /* The GNU C library defines this for functions which it implements
4349 to always fail with ENOSYS. Some functions are actually named
4350 something starting with __ and the normal name is an alias. */
4351 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
4352 choke me
4353 #else
4354 $ac_func();
4355 #endif
4357 ; return 0; }
4359 if { (eval echo configure:4360: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4360 rm -rf conftest*
4361 eval "ac_cv_func_$ac_func=yes"
4362 else
4363 echo "configure: failed program was:" >&5
4364 cat conftest.$ac_ext >&5
4365 rm -rf conftest*
4366 eval "ac_cv_func_$ac_func=no"
4368 rm -f conftest*
4371 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
4372 echo "$ac_t""yes" 1>&6
4373 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
4374 cat >> confdefs.h <<EOF
4375 #define $ac_tr_func 1
4378 else
4379 echo "$ac_t""no" 1>&6
4381 done
4384 # Some systems have frexp only in -lm, not in -lc.
4386 echo $ac_n "checking for library containing frexp""... $ac_c" 1>&6
4387 echo "configure:4388: checking for library containing frexp" >&5
4388 if eval "test \"`echo '$''{'ac_cv_search_frexp'+set}'`\" = set"; then
4389 echo $ac_n "(cached) $ac_c" 1>&6
4390 else
4391 ac_func_search_save_LIBS="$LIBS"
4392 ac_cv_search_frexp="no"
4393 cat > conftest.$ac_ext <<EOF
4394 #line 4395 "configure"
4395 #include "confdefs.h"
4396 /* Override any gcc2 internal prototype to avoid an error. */
4397 /* We use char because int might match the return type of a gcc2
4398 builtin and then its argument prototype would still apply. */
4399 char frexp();
4401 int main() {
4402 frexp()
4403 ; return 0; }
4405 if { (eval echo configure:4406: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4406 rm -rf conftest*
4407 ac_cv_search_frexp="none required"
4408 else
4409 echo "configure: failed program was:" >&5
4410 cat conftest.$ac_ext >&5
4412 rm -f conftest*
4413 test "$ac_cv_search_frexp" = "no" && for i in m; do
4414 LIBS="-l$i $ac_func_search_save_LIBS"
4415 cat > conftest.$ac_ext <<EOF
4416 #line 4417 "configure"
4417 #include "confdefs.h"
4418 /* Override any gcc2 internal prototype to avoid an error. */
4419 /* We use char because int might match the return type of a gcc2
4420 builtin and then its argument prototype would still apply. */
4421 char frexp();
4423 int main() {
4424 frexp()
4425 ; return 0; }
4427 if { (eval echo configure:4428: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4428 rm -rf conftest*
4429 ac_cv_search_frexp="-l$i"
4430 break
4431 else
4432 echo "configure: failed program was:" >&5
4433 cat conftest.$ac_ext >&5
4435 rm -f conftest*
4436 done
4437 LIBS="$ac_func_search_save_LIBS"
4440 echo "$ac_t""$ac_cv_search_frexp" 1>&6
4441 if test "$ac_cv_search_frexp" != "no"; then
4442 test "$ac_cv_search_frexp" = "none required" || LIBS="$ac_cv_search_frexp $LIBS"
4444 else :
4448 echo $ac_n "checking for time_t in time.h""... $ac_c" 1>&6
4449 echo "configure:4450: checking for time_t in time.h" >&5
4450 if eval "test \"`echo '$''{'bu_cv_decl_time_t_time_h'+set}'`\" = set"; then
4451 echo $ac_n "(cached) $ac_c" 1>&6
4452 else
4453 cat > conftest.$ac_ext <<EOF
4454 #line 4455 "configure"
4455 #include "confdefs.h"
4456 #include <time.h>
4457 int main() {
4458 time_t i;
4459 ; return 0; }
4461 if { (eval echo configure:4462: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4462 rm -rf conftest*
4463 bu_cv_decl_time_t_time_h=yes
4464 else
4465 echo "configure: failed program was:" >&5
4466 cat conftest.$ac_ext >&5
4467 rm -rf conftest*
4468 bu_cv_decl_time_t_time_h=no
4470 rm -f conftest*
4473 echo "$ac_t""$bu_cv_decl_time_t_time_h" 1>&6
4474 if test $bu_cv_decl_time_t_time_h = yes; then
4475 cat >> confdefs.h <<\EOF
4476 #define HAVE_TIME_T_IN_TIME_H 1
4481 echo $ac_n "checking for time_t in sys/types.h""... $ac_c" 1>&6
4482 echo "configure:4483: checking for time_t in sys/types.h" >&5
4483 if eval "test \"`echo '$''{'bu_cv_decl_time_t_types_h'+set}'`\" = set"; then
4484 echo $ac_n "(cached) $ac_c" 1>&6
4485 else
4486 cat > conftest.$ac_ext <<EOF
4487 #line 4488 "configure"
4488 #include "confdefs.h"
4489 #include <sys/types.h>
4490 int main() {
4491 time_t i;
4492 ; return 0; }
4494 if { (eval echo configure:4495: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4495 rm -rf conftest*
4496 bu_cv_decl_time_t_types_h=yes
4497 else
4498 echo "configure: failed program was:" >&5
4499 cat conftest.$ac_ext >&5
4500 rm -rf conftest*
4501 bu_cv_decl_time_t_types_h=no
4503 rm -f conftest*
4506 echo "$ac_t""$bu_cv_decl_time_t_types_h" 1>&6
4507 if test $bu_cv_decl_time_t_types_h = yes; then
4508 cat >> confdefs.h <<\EOF
4509 #define HAVE_TIME_T_IN_TYPES_H 1
4514 # Under Next 3.2 <utime.h> apparently does not define struct utimbuf
4515 # by default.
4516 echo $ac_n "checking for utime.h""... $ac_c" 1>&6
4517 echo "configure:4518: checking for utime.h" >&5
4518 if eval "test \"`echo '$''{'bu_cv_header_utime_h'+set}'`\" = set"; then
4519 echo $ac_n "(cached) $ac_c" 1>&6
4520 else
4521 cat > conftest.$ac_ext <<EOF
4522 #line 4523 "configure"
4523 #include "confdefs.h"
4524 #include <sys/types.h>
4525 #ifdef HAVE_TIME_H
4526 #include <time.h>
4527 #endif
4528 #include <utime.h>
4529 int main() {
4530 struct utimbuf s;
4531 ; return 0; }
4533 if { (eval echo configure:4534: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4534 rm -rf conftest*
4535 bu_cv_header_utime_h=yes
4536 else
4537 echo "configure: failed program was:" >&5
4538 cat conftest.$ac_ext >&5
4539 rm -rf conftest*
4540 bu_cv_header_utime_h=no
4542 rm -f conftest*
4545 echo "$ac_t""$bu_cv_header_utime_h" 1>&6
4546 if test $bu_cv_header_utime_h = yes; then
4547 cat >> confdefs.h <<\EOF
4548 #define HAVE_GOOD_UTIME_H 1
4553 echo $ac_n "checking whether fprintf must be declared""... $ac_c" 1>&6
4554 echo "configure:4555: checking whether fprintf must be declared" >&5
4555 if eval "test \"`echo '$''{'bfd_cv_decl_needed_fprintf'+set}'`\" = set"; then
4556 echo $ac_n "(cached) $ac_c" 1>&6
4557 else
4558 cat > conftest.$ac_ext <<EOF
4559 #line 4560 "configure"
4560 #include "confdefs.h"
4562 #include <stdio.h>
4563 #ifdef HAVE_STRING_H
4564 #include <string.h>
4565 #else
4566 #ifdef HAVE_STRINGS_H
4567 #include <strings.h>
4568 #endif
4569 #endif
4570 #ifdef HAVE_STDLIB_H
4571 #include <stdlib.h>
4572 #endif
4573 #ifdef HAVE_UNISTD_H
4574 #include <unistd.h>
4575 #endif
4576 int main() {
4577 char *(*pfn) = (char *(*)) fprintf
4578 ; return 0; }
4580 if { (eval echo configure:4581: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4581 rm -rf conftest*
4582 bfd_cv_decl_needed_fprintf=no
4583 else
4584 echo "configure: failed program was:" >&5
4585 cat conftest.$ac_ext >&5
4586 rm -rf conftest*
4587 bfd_cv_decl_needed_fprintf=yes
4589 rm -f conftest*
4592 echo "$ac_t""$bfd_cv_decl_needed_fprintf" 1>&6
4593 if test $bfd_cv_decl_needed_fprintf = yes; then
4594 cat >> confdefs.h <<\EOF
4595 #define NEED_DECLARATION_FPRINTF 1
4600 echo $ac_n "checking whether strstr must be declared""... $ac_c" 1>&6
4601 echo "configure:4602: checking whether strstr must be declared" >&5
4602 if eval "test \"`echo '$''{'bfd_cv_decl_needed_strstr'+set}'`\" = set"; then
4603 echo $ac_n "(cached) $ac_c" 1>&6
4604 else
4605 cat > conftest.$ac_ext <<EOF
4606 #line 4607 "configure"
4607 #include "confdefs.h"
4609 #include <stdio.h>
4610 #ifdef HAVE_STRING_H
4611 #include <string.h>
4612 #else
4613 #ifdef HAVE_STRINGS_H
4614 #include <strings.h>
4615 #endif
4616 #endif
4617 #ifdef HAVE_STDLIB_H
4618 #include <stdlib.h>
4619 #endif
4620 #ifdef HAVE_UNISTD_H
4621 #include <unistd.h>
4622 #endif
4623 int main() {
4624 char *(*pfn) = (char *(*)) strstr
4625 ; return 0; }
4627 if { (eval echo configure:4628: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4628 rm -rf conftest*
4629 bfd_cv_decl_needed_strstr=no
4630 else
4631 echo "configure: failed program was:" >&5
4632 cat conftest.$ac_ext >&5
4633 rm -rf conftest*
4634 bfd_cv_decl_needed_strstr=yes
4636 rm -f conftest*
4639 echo "$ac_t""$bfd_cv_decl_needed_strstr" 1>&6
4640 if test $bfd_cv_decl_needed_strstr = yes; then
4641 cat >> confdefs.h <<\EOF
4642 #define NEED_DECLARATION_STRSTR 1
4647 echo $ac_n "checking whether sbrk must be declared""... $ac_c" 1>&6
4648 echo "configure:4649: checking whether sbrk must be declared" >&5
4649 if eval "test \"`echo '$''{'bfd_cv_decl_needed_sbrk'+set}'`\" = set"; then
4650 echo $ac_n "(cached) $ac_c" 1>&6
4651 else
4652 cat > conftest.$ac_ext <<EOF
4653 #line 4654 "configure"
4654 #include "confdefs.h"
4656 #include <stdio.h>
4657 #ifdef HAVE_STRING_H
4658 #include <string.h>
4659 #else
4660 #ifdef HAVE_STRINGS_H
4661 #include <strings.h>
4662 #endif
4663 #endif
4664 #ifdef HAVE_STDLIB_H
4665 #include <stdlib.h>
4666 #endif
4667 #ifdef HAVE_UNISTD_H
4668 #include <unistd.h>
4669 #endif
4670 int main() {
4671 char *(*pfn) = (char *(*)) sbrk
4672 ; return 0; }
4674 if { (eval echo configure:4675: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4675 rm -rf conftest*
4676 bfd_cv_decl_needed_sbrk=no
4677 else
4678 echo "configure: failed program was:" >&5
4679 cat conftest.$ac_ext >&5
4680 rm -rf conftest*
4681 bfd_cv_decl_needed_sbrk=yes
4683 rm -f conftest*
4686 echo "$ac_t""$bfd_cv_decl_needed_sbrk" 1>&6
4687 if test $bfd_cv_decl_needed_sbrk = yes; then
4688 cat >> confdefs.h <<\EOF
4689 #define NEED_DECLARATION_SBRK 1
4694 echo $ac_n "checking whether getenv must be declared""... $ac_c" 1>&6
4695 echo "configure:4696: checking whether getenv must be declared" >&5
4696 if eval "test \"`echo '$''{'bfd_cv_decl_needed_getenv'+set}'`\" = set"; then
4697 echo $ac_n "(cached) $ac_c" 1>&6
4698 else
4699 cat > conftest.$ac_ext <<EOF
4700 #line 4701 "configure"
4701 #include "confdefs.h"
4703 #include <stdio.h>
4704 #ifdef HAVE_STRING_H
4705 #include <string.h>
4706 #else
4707 #ifdef HAVE_STRINGS_H
4708 #include <strings.h>
4709 #endif
4710 #endif
4711 #ifdef HAVE_STDLIB_H
4712 #include <stdlib.h>
4713 #endif
4714 #ifdef HAVE_UNISTD_H
4715 #include <unistd.h>
4716 #endif
4717 int main() {
4718 char *(*pfn) = (char *(*)) getenv
4719 ; return 0; }
4721 if { (eval echo configure:4722: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4722 rm -rf conftest*
4723 bfd_cv_decl_needed_getenv=no
4724 else
4725 echo "configure: failed program was:" >&5
4726 cat conftest.$ac_ext >&5
4727 rm -rf conftest*
4728 bfd_cv_decl_needed_getenv=yes
4730 rm -f conftest*
4733 echo "$ac_t""$bfd_cv_decl_needed_getenv" 1>&6
4734 if test $bfd_cv_decl_needed_getenv = yes; then
4735 cat >> confdefs.h <<\EOF
4736 #define NEED_DECLARATION_GETENV 1
4741 echo $ac_n "checking whether environ must be declared""... $ac_c" 1>&6
4742 echo "configure:4743: checking whether environ must be declared" >&5
4743 if eval "test \"`echo '$''{'bfd_cv_decl_needed_environ'+set}'`\" = set"; then
4744 echo $ac_n "(cached) $ac_c" 1>&6
4745 else
4746 cat > conftest.$ac_ext <<EOF
4747 #line 4748 "configure"
4748 #include "confdefs.h"
4750 #include <stdio.h>
4751 #ifdef HAVE_STRING_H
4752 #include <string.h>
4753 #else
4754 #ifdef HAVE_STRINGS_H
4755 #include <strings.h>
4756 #endif
4757 #endif
4758 #ifdef HAVE_STDLIB_H
4759 #include <stdlib.h>
4760 #endif
4761 #ifdef HAVE_UNISTD_H
4762 #include <unistd.h>
4763 #endif
4764 int main() {
4765 char *(*pfn) = (char *(*)) environ
4766 ; return 0; }
4768 if { (eval echo configure:4769: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4769 rm -rf conftest*
4770 bfd_cv_decl_needed_environ=no
4771 else
4772 echo "configure: failed program was:" >&5
4773 cat conftest.$ac_ext >&5
4774 rm -rf conftest*
4775 bfd_cv_decl_needed_environ=yes
4777 rm -f conftest*
4780 echo "$ac_t""$bfd_cv_decl_needed_environ" 1>&6
4781 if test $bfd_cv_decl_needed_environ = yes; then
4782 cat >> confdefs.h <<\EOF
4783 #define NEED_DECLARATION_ENVIRON 1
4790 case "${host}" in
4791 *-*-msdos* | *-*-go32* | *-*-mingw32* | *-*-cygwin* | *-*-windows*)
4792 cat >> confdefs.h <<\EOF
4793 #define USE_BINARY_FOPEN 1
4796 esac
4798 # target-specific stuff:
4800 # Canonicalize the secondary target names.
4801 if test -n "$enable_targets"; then
4802 for targ in `echo $enable_targets | sed 's/,/ /g'`
4804 result=`$ac_config_sub $targ 2>/dev/null`
4805 if test -n "$result"; then
4806 canon_targets="$canon_targets $result"
4807 else
4808 # Allow targets that config.sub doesn't recognize, like "all".
4809 canon_targets="$canon_targets $targ"
4811 done
4814 all_targets=false
4815 BUILD_NLMCONV=
4816 NLMCONV_DEFS=
4817 BUILD_SRCONV=
4818 BUILD_DLLTOOL=
4819 DLLTOOL_DEFS=
4820 BUILD_WINDRES=
4821 BUILD_DLLWRAP=
4822 BUILD_MISC=
4824 for targ in $target $canon_targets
4826 if test "x$targ" = "xall"; then
4827 all_targets=true
4828 BUILD_NLMCONV='$(NLMCONV_PROG)$(EXEEXT)'
4829 BUILD_SRCONV='$(SRCONV_PROG)'
4830 NLMCONV_DEFS="-DNLMCONV_I386 -DNLMCONV_ALPHA -DNLMCONV_POWERPC -DNLMCONV_SPARC"
4831 else
4832 case $targ in
4833 i[3456]86*-*-netware*)
4834 BUILD_NLMCONV='$(NLMCONV_PROG)$(EXEEXT)'
4835 NLMCONV_DEFS="$NLMCONV_DEFS -DNLMCONV_I386"
4837 alpha*-*-netware*)
4838 BUILD_NLMCONV='$(NLMCONV_PROG)$(EXEEXT)'
4839 NLMCONV_DEFS="$NLMCONV_DEFS -DNLMCONV_ALPHA"
4841 powerpc*-*-netware*)
4842 BUILD_NLMCONV='$(NLMCONV_PROG)$(EXEEXT)'
4843 NLMCONV_DEFS="$NLMCONV_DEFS -DNLMCONV_POWERPC"
4845 sparc*-*-netware*)
4846 BUILD_NLMCONV='$(NLMCONV_PROG)$(EXEEXT)'
4847 NLMCONV_DEFS="$NLMCONV_DEFS -DNLMCONV_SPARC"
4849 esac
4850 case $targ in
4851 *-*-hms*) BUILD_SRCONV='$(SRCONV_PROG)' ;;
4852 esac
4853 case $targ in
4854 arm-*pe* | arm-*-wince)
4855 BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
4856 DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_ARM"
4857 BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
4859 thumb-*pe*)
4860 BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
4861 DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_ARM"
4862 BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
4864 i[3-6]86-*pe* | i[3-6]86-*-cygwin* | i[3-6]86-*-mingw32*)
4865 BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
4866 DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_I386"
4867 BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
4868 BUILD_DLLWRAP='$(DLLWRAP_PROG)$(EXEEXT)'
4870 i3-686-*-interix)
4871 BUILD_DLLTOOL='$(DLLTOOL_PROG)'
4872 DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_I386"
4874 powerpc*-*-*pe* | powerpc*-*-cygwin*)
4875 BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
4876 DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_PPC"
4877 BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
4879 sh*-*-*pe)
4880 BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
4881 DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_SH"
4882 BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
4884 mips*-*-*pe)
4885 BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
4886 DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_MIPS"
4887 BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
4889 mcore-*pe)
4890 BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
4891 DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_MCORE"
4892 BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
4894 mcore-*elf)
4895 BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
4896 DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_MCORE_ELF"
4898 esac
4900 done
4911 cat >> confdefs.h <<EOF
4912 #define TARGET "${target}"
4916 targ=$target
4917 . $srcdir/../bfd/config.bfd
4918 if test "x$targ_underscore" = "xyes"; then
4919 UNDERSCORE=1
4920 else
4921 UNDERSCORE=0
4925 trap '' 1 2 15
4926 cat > confcache <<\EOF
4927 # This file is a shell script that caches the results of configure
4928 # tests run on this system so they can be shared between configure
4929 # scripts and configure runs. It is not useful on other systems.
4930 # If it contains results you don't want to keep, you may remove or edit it.
4932 # By default, configure uses ./config.cache as the cache file,
4933 # creating it if it does not exist already. You can give configure
4934 # the --cache-file=FILE option to use a different cache file; that is
4935 # what configure does when it calls configure scripts in
4936 # subdirectories, so they share the cache.
4937 # Giving --cache-file=/dev/null disables caching, for debugging configure.
4938 # config.status only pays attention to the cache file if you give it the
4939 # --recheck option to rerun configure.
4942 # The following way of writing the cache mishandles newlines in values,
4943 # but we know of no workaround that is simple, portable, and efficient.
4944 # So, don't put newlines in cache variables' values.
4945 # Ultrix sh set writes to stderr and can't be redirected directly,
4946 # and sets the high bit in the cache file unless we assign to the vars.
4947 (set) 2>&1 |
4948 case `(ac_space=' '; set | grep ac_space) 2>&1` in
4949 *ac_space=\ *)
4950 # `set' does not quote correctly, so add quotes (double-quote substitution
4951 # turns \\\\ into \\, and sed turns \\ into \).
4952 sed -n \
4953 -e "s/'/'\\\\''/g" \
4954 -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
4957 # `set' quotes correctly as required by POSIX, so do not add quotes.
4958 sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
4960 esac >> confcache
4961 if cmp -s $cache_file confcache; then
4963 else
4964 if test -w $cache_file; then
4965 echo "updating cache $cache_file"
4966 cat confcache > $cache_file
4967 else
4968 echo "not updating unwritable cache $cache_file"
4971 rm -f confcache
4973 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
4975 test "x$prefix" = xNONE && prefix=$ac_default_prefix
4976 # Let make expand exec_prefix.
4977 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
4979 # Any assignment to VPATH causes Sun make to only execute
4980 # the first set of double-colon rules, so remove it if not needed.
4981 # If there is a colon in the path, we need to keep it.
4982 if test "x$srcdir" = x.; then
4983 ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
4986 trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
4988 DEFS=-DHAVE_CONFIG_H
4990 # Without the "./", some shells look in PATH for config.status.
4991 : ${CONFIG_STATUS=./config.status}
4993 echo creating $CONFIG_STATUS
4994 rm -f $CONFIG_STATUS
4995 cat > $CONFIG_STATUS <<EOF
4996 #! /bin/sh
4997 # Generated automatically by configure.
4998 # Run this file to recreate the current configuration.
4999 # This directory was configured as follows,
5000 # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
5002 # $0 $ac_configure_args
5004 # Compiler output produced by configure, useful for debugging
5005 # configure, is in ./config.log if it exists.
5007 ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
5008 for ac_option
5010 case "\$ac_option" in
5011 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
5012 echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
5013 exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
5014 -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
5015 echo "$CONFIG_STATUS generated by autoconf version 2.13"
5016 exit 0 ;;
5017 -help | --help | --hel | --he | --h)
5018 echo "\$ac_cs_usage"; exit 0 ;;
5019 *) echo "\$ac_cs_usage"; exit 1 ;;
5020 esac
5021 done
5023 ac_given_srcdir=$srcdir
5024 ac_given_INSTALL="$INSTALL"
5026 trap 'rm -fr `echo "Makefile po/Makefile.in:po/Make-in config.h:config.in" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
5028 cat >> $CONFIG_STATUS <<EOF
5030 # Protect against being on the right side of a sed subst in config.status.
5031 sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
5032 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
5033 $ac_vpsub
5034 $extrasub
5035 s%@SHELL@%$SHELL%g
5036 s%@CFLAGS@%$CFLAGS%g
5037 s%@CPPFLAGS@%$CPPFLAGS%g
5038 s%@CXXFLAGS@%$CXXFLAGS%g
5039 s%@FFLAGS@%$FFLAGS%g
5040 s%@DEFS@%$DEFS%g
5041 s%@LDFLAGS@%$LDFLAGS%g
5042 s%@LIBS@%$LIBS%g
5043 s%@exec_prefix@%$exec_prefix%g
5044 s%@prefix@%$prefix%g
5045 s%@program_transform_name@%$program_transform_name%g
5046 s%@bindir@%$bindir%g
5047 s%@sbindir@%$sbindir%g
5048 s%@libexecdir@%$libexecdir%g
5049 s%@datadir@%$datadir%g
5050 s%@sysconfdir@%$sysconfdir%g
5051 s%@sharedstatedir@%$sharedstatedir%g
5052 s%@localstatedir@%$localstatedir%g
5053 s%@libdir@%$libdir%g
5054 s%@includedir@%$includedir%g
5055 s%@oldincludedir@%$oldincludedir%g
5056 s%@infodir@%$infodir%g
5057 s%@mandir@%$mandir%g
5058 s%@host@%$host%g
5059 s%@host_alias@%$host_alias%g
5060 s%@host_cpu@%$host_cpu%g
5061 s%@host_vendor@%$host_vendor%g
5062 s%@host_os@%$host_os%g
5063 s%@target@%$target%g
5064 s%@target_alias@%$target_alias%g
5065 s%@target_cpu@%$target_cpu%g
5066 s%@target_vendor@%$target_vendor%g
5067 s%@target_os@%$target_os%g
5068 s%@build@%$build%g
5069 s%@build_alias@%$build_alias%g
5070 s%@build_cpu@%$build_cpu%g
5071 s%@build_vendor@%$build_vendor%g
5072 s%@build_os@%$build_os%g
5073 s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
5074 s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
5075 s%@INSTALL_DATA@%$INSTALL_DATA%g
5076 s%@PACKAGE@%$PACKAGE%g
5077 s%@VERSION@%$VERSION%g
5078 s%@ACLOCAL@%$ACLOCAL%g
5079 s%@AUTOCONF@%$AUTOCONF%g
5080 s%@AUTOMAKE@%$AUTOMAKE%g
5081 s%@AUTOHEADER@%$AUTOHEADER%g
5082 s%@MAKEINFO@%$MAKEINFO%g
5083 s%@SET_MAKE@%$SET_MAKE%g
5084 s%@RANLIB@%$RANLIB%g
5085 s%@CC@%$CC%g
5086 s%@LN_S@%$LN_S%g
5087 s%@LIBTOOL@%$LIBTOOL%g
5088 s%@WARN_CFLAGS@%$WARN_CFLAGS%g
5089 s%@YACC@%$YACC%g
5090 s%@LEX@%$LEX%g
5091 s%@LEXLIB@%$LEXLIB%g
5092 s%@CPP@%$CPP%g
5093 s%@LEX_OUTPUT_ROOT@%$LEX_OUTPUT_ROOT%g
5094 s%@ALLOCA@%$ALLOCA%g
5095 s%@USE_NLS@%$USE_NLS%g
5096 s%@MSGFMT@%$MSGFMT%g
5097 s%@GMSGFMT@%$GMSGFMT%g
5098 s%@XGETTEXT@%$XGETTEXT%g
5099 s%@USE_INCLUDED_LIBINTL@%$USE_INCLUDED_LIBINTL%g
5100 s%@CATALOGS@%$CATALOGS%g
5101 s%@CATOBJEXT@%$CATOBJEXT%g
5102 s%@DATADIRNAME@%$DATADIRNAME%g
5103 s%@GMOFILES@%$GMOFILES%g
5104 s%@INSTOBJEXT@%$INSTOBJEXT%g
5105 s%@INTLDEPS@%$INTLDEPS%g
5106 s%@INTLLIBS@%$INTLLIBS%g
5107 s%@INTLOBJS@%$INTLOBJS%g
5108 s%@POFILES@%$POFILES%g
5109 s%@POSUB@%$POSUB%g
5110 s%@INCLUDE_LOCALE_H@%$INCLUDE_LOCALE_H%g
5111 s%@GT_NO@%$GT_NO%g
5112 s%@GT_YES@%$GT_YES%g
5113 s%@MKINSTALLDIRS@%$MKINSTALLDIRS%g
5114 s%@l@%$l%g
5115 s%@MAINTAINER_MODE_TRUE@%$MAINTAINER_MODE_TRUE%g
5116 s%@MAINTAINER_MODE_FALSE@%$MAINTAINER_MODE_FALSE%g
5117 s%@MAINT@%$MAINT%g
5118 s%@EXEEXT@%$EXEEXT%g
5119 s%@HDEFINES@%$HDEFINES%g
5120 s%@AR@%$AR%g
5121 s%@CC_FOR_BUILD@%$CC_FOR_BUILD%g
5122 s%@EXEEXT_FOR_BUILD@%$EXEEXT_FOR_BUILD%g
5123 s%@DEMANGLER_NAME@%$DEMANGLER_NAME%g
5124 s%@NLMCONV_DEFS@%$NLMCONV_DEFS%g
5125 s%@BUILD_NLMCONV@%$BUILD_NLMCONV%g
5126 s%@BUILD_SRCONV@%$BUILD_SRCONV%g
5127 s%@BUILD_DLLTOOL@%$BUILD_DLLTOOL%g
5128 s%@DLLTOOL_DEFS@%$DLLTOOL_DEFS%g
5129 s%@BUILD_WINDRES@%$BUILD_WINDRES%g
5130 s%@BUILD_DLLWRAP@%$BUILD_DLLWRAP%g
5131 s%@BUILD_MISC@%$BUILD_MISC%g
5132 s%@UNDERSCORE@%$UNDERSCORE%g
5134 CEOF
5137 cat >> $CONFIG_STATUS <<\EOF
5139 # Split the substitutions into bite-sized pieces for seds with
5140 # small command number limits, like on Digital OSF/1 and HP-UX.
5141 ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
5142 ac_file=1 # Number of current file.
5143 ac_beg=1 # First line for current file.
5144 ac_end=$ac_max_sed_cmds # Line after last line for current file.
5145 ac_more_lines=:
5146 ac_sed_cmds=""
5147 while $ac_more_lines; do
5148 if test $ac_beg -gt 1; then
5149 sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
5150 else
5151 sed "${ac_end}q" conftest.subs > conftest.s$ac_file
5153 if test ! -s conftest.s$ac_file; then
5154 ac_more_lines=false
5155 rm -f conftest.s$ac_file
5156 else
5157 if test -z "$ac_sed_cmds"; then
5158 ac_sed_cmds="sed -f conftest.s$ac_file"
5159 else
5160 ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
5162 ac_file=`expr $ac_file + 1`
5163 ac_beg=$ac_end
5164 ac_end=`expr $ac_end + $ac_max_sed_cmds`
5166 done
5167 if test -z "$ac_sed_cmds"; then
5168 ac_sed_cmds=cat
5172 cat >> $CONFIG_STATUS <<EOF
5174 CONFIG_FILES=\${CONFIG_FILES-"Makefile po/Makefile.in:po/Make-in"}
5176 cat >> $CONFIG_STATUS <<\EOF
5177 for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
5178 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
5179 case "$ac_file" in
5180 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
5181 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
5182 *) ac_file_in="${ac_file}.in" ;;
5183 esac
5185 # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
5187 # Remove last slash and all that follows it. Not all systems have dirname.
5188 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
5189 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
5190 # The file is in a subdirectory.
5191 test ! -d "$ac_dir" && mkdir "$ac_dir"
5192 ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
5193 # A "../" for each directory in $ac_dir_suffix.
5194 ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
5195 else
5196 ac_dir_suffix= ac_dots=
5199 case "$ac_given_srcdir" in
5200 .) srcdir=.
5201 if test -z "$ac_dots"; then top_srcdir=.
5202 else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
5203 /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
5204 *) # Relative path.
5205 srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
5206 top_srcdir="$ac_dots$ac_given_srcdir" ;;
5207 esac
5209 case "$ac_given_INSTALL" in
5210 [/$]*) INSTALL="$ac_given_INSTALL" ;;
5211 *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
5212 esac
5214 echo creating "$ac_file"
5215 rm -f "$ac_file"
5216 configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
5217 case "$ac_file" in
5218 *Makefile*) ac_comsub="1i\\
5219 # $configure_input" ;;
5220 *) ac_comsub= ;;
5221 esac
5223 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
5224 sed -e "$ac_comsub
5225 s%@configure_input@%$configure_input%g
5226 s%@srcdir@%$srcdir%g
5227 s%@top_srcdir@%$top_srcdir%g
5228 s%@INSTALL@%$INSTALL%g
5229 " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
5230 fi; done
5231 rm -f conftest.s*
5233 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
5234 # NAME is the cpp macro being defined and VALUE is the value it is being given.
5236 # ac_d sets the value in "#define NAME VALUE" lines.
5237 ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)'
5238 ac_dB='\([ ][ ]*\)[^ ]*%\1#\2'
5239 ac_dC='\3'
5240 ac_dD='%g'
5241 # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
5242 ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
5243 ac_uB='\([ ]\)%\1#\2define\3'
5244 ac_uC=' '
5245 ac_uD='\4%g'
5246 # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
5247 ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
5248 ac_eB='$%\1#\2define\3'
5249 ac_eC=' '
5250 ac_eD='%g'
5252 if test "${CONFIG_HEADERS+set}" != set; then
5254 cat >> $CONFIG_STATUS <<EOF
5255 CONFIG_HEADERS="config.h:config.in"
5257 cat >> $CONFIG_STATUS <<\EOF
5259 for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
5260 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
5261 case "$ac_file" in
5262 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
5263 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
5264 *) ac_file_in="${ac_file}.in" ;;
5265 esac
5267 echo creating $ac_file
5269 rm -f conftest.frag conftest.in conftest.out
5270 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
5271 cat $ac_file_inputs > conftest.in
5275 # Transform confdefs.h into a sed script conftest.vals that substitutes
5276 # the proper values into config.h.in to produce config.h. And first:
5277 # Protect against being on the right side of a sed subst in config.status.
5278 # Protect against being in an unquoted here document in config.status.
5279 rm -f conftest.vals
5280 cat > conftest.hdr <<\EOF
5281 s/[\\&%]/\\&/g
5282 s%[\\$`]%\\&%g
5283 s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
5284 s%ac_d%ac_u%gp
5285 s%ac_u%ac_e%gp
5287 sed -n -f conftest.hdr confdefs.h > conftest.vals
5288 rm -f conftest.hdr
5290 # This sed command replaces #undef with comments. This is necessary, for
5291 # example, in the case of _POSIX_SOURCE, which is predefined and required
5292 # on some systems where configure will not decide to define it.
5293 cat >> conftest.vals <<\EOF
5294 s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
5297 # Break up conftest.vals because some shells have a limit on
5298 # the size of here documents, and old seds have small limits too.
5300 rm -f conftest.tail
5301 while :
5303 ac_lines=`grep -c . conftest.vals`
5304 # grep -c gives empty output for an empty file on some AIX systems.
5305 if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
5306 # Write a limited-size here document to conftest.frag.
5307 echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
5308 sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
5309 echo 'CEOF
5310 sed -f conftest.frag conftest.in > conftest.out
5311 rm -f conftest.in
5312 mv conftest.out conftest.in
5313 ' >> $CONFIG_STATUS
5314 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
5315 rm -f conftest.vals
5316 mv conftest.tail conftest.vals
5317 done
5318 rm -f conftest.vals
5320 cat >> $CONFIG_STATUS <<\EOF
5321 rm -f conftest.frag conftest.h
5322 echo "/* $ac_file. Generated automatically by configure. */" > conftest.h
5323 cat conftest.in >> conftest.h
5324 rm -f conftest.in
5325 if cmp -s $ac_file conftest.h 2>/dev/null; then
5326 echo "$ac_file is unchanged"
5327 rm -f conftest.h
5328 else
5329 # Remove last slash and all that follows it. Not all systems have dirname.
5330 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
5331 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
5332 # The file is in a subdirectory.
5333 test ! -d "$ac_dir" && mkdir "$ac_dir"
5335 rm -f $ac_file
5336 mv conftest.h $ac_file
5338 fi; done
5341 cat >> $CONFIG_STATUS <<EOF
5345 cat >> $CONFIG_STATUS <<\EOF
5346 test -z "$CONFIG_HEADERS" || echo timestamp > stamp-h
5348 case "x$CONFIG_FILES" in
5349 *) sed -e '/POTFILES =/r po/POTFILES' po/Makefile.in > po/Makefile ;;
5350 esac
5352 exit 0
5354 chmod +x $CONFIG_STATUS
5355 rm -fr confdefs* $ac_clean_files
5356 test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1