* target.h (TARGET_SIGNAL_REALTIME_64): Added for IRIX 6.
[deliverable/binutils-gdb.git] / binutils / configure
CommitLineData
252b5132
RH
1#! /bin/sh
2
3# Guess values for system-dependent variables and create Makefiles.
4# Generated automatically using autoconf version 2.13
5# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
6#
7# This configure script is free software; the Free Software Foundation
8# gives unlimited permission to copy, distribute and modify it.
9
10# Defaults:
11ac_help=
12ac_default_prefix=/usr/local
13# Any additions from configure.in:
14ac_help="$ac_help
15 --enable-shared[=PKGS] build shared libraries [default=yes]"
16ac_help="$ac_help
17 --enable-static[=PKGS] build static libraries [default=yes]"
18ac_help="$ac_help
19 --enable-fast-install[=PKGS] optimize for fast installation [default=yes]"
20ac_help="$ac_help
21 --with-gnu-ld assume the C compiler uses GNU ld [default=no]"
22ac_help="$ac_help
a74801ba 23 --disable-libtool-lock avoid locking (might break parallel builds)"
ac48eca1
AO
24ac_help="$ac_help
25 --with-pic try to use only PIC/non-PIC objects [default=use both]"
252b5132
RH
26ac_help="$ac_help
27 --enable-targets alternative target configurations"
28ac_help="$ac_help
29 --enable-commonbfdlib build shared BFD/opcodes/libiberty library"
a2d91340
AC
30ac_help="$ac_help
31 --enable-build-warnings Enable build-time compiler warnings if gcc is used"
252b5132
RH
32ac_help="$ac_help
33 --disable-nls do not use Native Language Support"
34ac_help="$ac_help
35 --with-included-gettext use the GNU gettext library included here"
36ac_help="$ac_help
37 --enable-maintainer-mode enable make rules and dependencies not useful
38 (and sometimes confusing) to the casual installer"
39
40# Initialize some variables set by options.
41# The variables have the same names as the options, with
42# dashes changed to underlines.
43build=NONE
44cache_file=./config.cache
45exec_prefix=NONE
46host=NONE
47no_create=
48nonopt=NONE
49no_recursion=
50prefix=NONE
51program_prefix=NONE
52program_suffix=NONE
53program_transform_name=s,x,x,
54silent=
55site=
56srcdir=
57target=NONE
58verbose=
59x_includes=NONE
60x_libraries=NONE
61bindir='${exec_prefix}/bin'
62sbindir='${exec_prefix}/sbin'
63libexecdir='${exec_prefix}/libexec'
64datadir='${prefix}/share'
65sysconfdir='${prefix}/etc'
66sharedstatedir='${prefix}/com'
67localstatedir='${prefix}/var'
68libdir='${exec_prefix}/lib'
69includedir='${prefix}/include'
70oldincludedir='/usr/include'
71infodir='${prefix}/info'
72mandir='${prefix}/man'
73
74# Initialize some other variables.
75subdirs=
76MFLAGS= MAKEFLAGS=
77SHELL=${CONFIG_SHELL-/bin/sh}
78# Maximum number of lines to put in a shell here document.
79ac_max_here_lines=12
80
81ac_prev=
82for ac_option
83do
84
85 # If the previous option needs an argument, assign it.
86 if test -n "$ac_prev"; then
87 eval "$ac_prev=\$ac_option"
88 ac_prev=
89 continue
90 fi
91
92 case "$ac_option" in
93 -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
94 *) ac_optarg= ;;
95 esac
96
97 # Accept the important Cygnus configure options, so we can diagnose typos.
98
99 case "$ac_option" in
100
101 -bindir | --bindir | --bindi | --bind | --bin | --bi)
102 ac_prev=bindir ;;
103 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
104 bindir="$ac_optarg" ;;
105
106 -build | --build | --buil | --bui | --bu)
107 ac_prev=build ;;
108 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
109 build="$ac_optarg" ;;
110
111 -cache-file | --cache-file | --cache-fil | --cache-fi \
112 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
113 ac_prev=cache_file ;;
114 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
115 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
116 cache_file="$ac_optarg" ;;
117
118 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
119 ac_prev=datadir ;;
120 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
121 | --da=*)
122 datadir="$ac_optarg" ;;
123
124 -disable-* | --disable-*)
125 ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
126 # Reject names that are not valid shell variable names.
127 if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
128 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
129 fi
130 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
131 eval "enable_${ac_feature}=no" ;;
132
133 -enable-* | --enable-*)
134 ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
135 # Reject names that are not valid shell variable names.
136 if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
137 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
138 fi
139 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
140 case "$ac_option" in
141 *=*) ;;
142 *) ac_optarg=yes ;;
143 esac
144 eval "enable_${ac_feature}='$ac_optarg'" ;;
145
146 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
147 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
148 | --exec | --exe | --ex)
149 ac_prev=exec_prefix ;;
150 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
151 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
152 | --exec=* | --exe=* | --ex=*)
153 exec_prefix="$ac_optarg" ;;
154
155 -gas | --gas | --ga | --g)
156 # Obsolete; use --with-gas.
157 with_gas=yes ;;
158
159 -help | --help | --hel | --he)
160 # Omit some internal or obsolete options to make the list less imposing.
161 # This message is too long to be a string in the A/UX 3.1 sh.
162 cat << EOF
163Usage: configure [options] [host]
164Options: [defaults in brackets after descriptions]
165Configuration:
166 --cache-file=FILE cache test results in FILE
167 --help print this message
168 --no-create do not create output files
169 --quiet, --silent do not print \`checking...' messages
170 --version print the version of autoconf that created configure
171Directory 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
195EOF
196 cat << EOF
197Host 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]
201Features 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
208EOF
209 if test -n "$ac_help"; then
210 echo "--enable and --with options recognized:$ac_help"
211 fi
212 exit 0 ;;
213
214 -host | --host | --hos | --ho)
215 ac_prev=host ;;
216 -host=* | --host=* | --hos=* | --ho=*)
217 host="$ac_optarg" ;;
218
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" ;;
225
226 -infodir | --infodir | --infodi | --infod | --info | --inf)
227 ac_prev=infodir ;;
228 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
229 infodir="$ac_optarg" ;;
230
231 -libdir | --libdir | --libdi | --libd)
232 ac_prev=libdir ;;
233 -libdir=* | --libdir=* | --libdi=* | --libd=*)
234 libdir="$ac_optarg" ;;
235
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" ;;
242
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" ;;
251
252 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
253 ac_prev=mandir ;;
254 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
255 mandir="$ac_optarg" ;;
256
257 -nfp | --nfp | --nf)
258 # Obsolete; use --without-fp.
259 with_fp=no ;;
260
261 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
262 | --no-cr | --no-c)
263 no_create=yes ;;
264
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 ;;
268
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" ;;
277
278 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
279 ac_prev=prefix ;;
280 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
281 prefix="$ac_optarg" ;;
282
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" ;;
289
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" ;;
296
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" ;;
313
314 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
315 | -silent | --silent | --silen | --sile | --sil)
316 silent=yes ;;
317
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" ;;
323
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" ;;
334
335 -site | --site | --sit)
336 ac_prev=site ;;
337 -site=* | --site=* | --sit=*)
338 site="$ac_optarg" ;;
339
340 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
341 ac_prev=srcdir ;;
342 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
343 srcdir="$ac_optarg" ;;
344
345 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
346 | --syscon | --sysco | --sysc | --sys | --sy)
347 ac_prev=sysconfdir ;;
348 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
349 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
350 sysconfdir="$ac_optarg" ;;
351
352 -target | --target | --targe | --targ | --tar | --ta | --t)
353 ac_prev=target ;;
354 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
355 target="$ac_optarg" ;;
356
357 -v | -verbose | --verbose | --verbos | --verbo | --verb)
358 verbose=yes ;;
359
360 -version | --version | --versio | --versi | --vers)
361 echo "configure generated by autoconf version 2.13"
362 exit 0 ;;
363
364 -with-* | --with-*)
365 ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
366 # Reject names that are not valid shell variable names.
367 if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
368 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
369 fi
370 ac_package=`echo $ac_package| sed 's/-/_/g'`
371 case "$ac_option" in
372 *=*) ;;
373 *) ac_optarg=yes ;;
374 esac
375 eval "with_${ac_package}='$ac_optarg'" ;;
376
377 -without-* | --without-*)
378 ac_package=`echo $ac_option|sed -e 's/-*without-//'`
379 # Reject names that are not valid shell variable names.
380 if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
381 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
382 fi
383 ac_package=`echo $ac_package| sed 's/-/_/g'`
384 eval "with_${ac_package}=no" ;;
385
386 --x)
387 # Obsolete; use --with-x.
388 with_x=yes ;;
389
390 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
391 | --x-incl | --x-inc | --x-in | --x-i)
392 ac_prev=x_includes ;;
393 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
394 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
395 x_includes="$ac_optarg" ;;
396
397 -x-libraries | --x-libraries | --x-librarie | --x-librari \
398 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
399 ac_prev=x_libraries ;;
400 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
401 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
402 x_libraries="$ac_optarg" ;;
403
404 -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
405 ;;
406
407 *)
408 if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
409 echo "configure: warning: $ac_option: invalid host type" 1>&2
410 fi
411 if test "x$nonopt" != xNONE; then
412 { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
413 fi
414 nonopt="$ac_option"
415 ;;
416
417 esac
418done
419
420if test -n "$ac_prev"; then
421 { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
422fi
423
424trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
425
426# File descriptor usage:
427# 0 standard input
428# 1 file creation
429# 2 errors and warnings
430# 3 some systems may open it to /dev/tty
431# 4 used on the Kubota Titan
432# 6 checking for... messages and results
433# 5 compiler messages saved in config.log
434if test "$silent" = yes; then
435 exec 6>/dev/null
436else
437 exec 6>&1
438fi
439exec 5>./config.log
440
441echo "\
442This file contains any messages produced by compilers while
443running configure, to aid debugging if configure makes a mistake.
444" 1>&5
445
446# Strip out --no-create and --no-recursion so they do not pile up.
447# Also quote any args containing shell metacharacters.
448ac_configure_args=
449for ac_arg
450do
451 case "$ac_arg" in
452 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
453 | --no-cr | --no-c) ;;
454 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
455 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
456 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
457 ac_configure_args="$ac_configure_args '$ac_arg'" ;;
458 *) ac_configure_args="$ac_configure_args $ac_arg" ;;
459 esac
460done
461
462# NLS nuisances.
463# Only set these to C if already set. These must not be set unconditionally
464# because not all systems understand e.g. LANG=C (notably SCO).
465# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
466# Non-C LC_CTYPE values break the ctype check.
467if test "${LANG+set}" = set; then LANG=C; export LANG; fi
468if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
469if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
470if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi
471
472# confdefs.h avoids OS command line length limits that DEFS can exceed.
473rm -rf conftest* confdefs.h
474# AIX cpp loses on an empty file, so make sure it contains at least a newline.
475echo > confdefs.h
476
477# A filename unique to this package, relative to the directory that
478# configure is in, which we can look for to find out if srcdir is correct.
479ac_unique_file=ar.c
480
481# Find the source files, if location was not specified.
482if test -z "$srcdir"; then
483 ac_srcdir_defaulted=yes
484 # Try the directory containing this script, then its parent.
485 ac_prog=$0
486 ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
487 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
488 srcdir=$ac_confdir
489 if test ! -r $srcdir/$ac_unique_file; then
490 srcdir=..
491 fi
492else
493 ac_srcdir_defaulted=no
494fi
495if test ! -r $srcdir/$ac_unique_file; then
496 if test "$ac_srcdir_defaulted" = yes; then
497 { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
498 else
499 { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
500 fi
501fi
502srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
503
504# Prefer explicitly selected file to automatically selected ones.
d64552c5
AO
505if test -z "$CONFIG_SITE"; then
506 if test "x$prefix" != xNONE; then
507 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
508 else
509 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
252b5132
RH
510 fi
511fi
512for ac_site_file in $CONFIG_SITE; do
513 if test -r "$ac_site_file"; then
514 echo "loading site script $ac_site_file"
515 . "$ac_site_file"
516 fi
517done
518
519if test -r "$cache_file"; then
520 echo "loading cache $cache_file"
521 . $cache_file
522else
523 echo "creating cache $cache_file"
524 > $cache_file
525fi
526
527ac_ext=c
528# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
529ac_cpp='$CPP $CPPFLAGS'
530ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
531ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
532cross_compiling=$ac_cv_prog_cc_cross
533
534ac_exeext=
535ac_objext=o
536if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
537 # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
538 if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
539 ac_n= ac_c='
540' ac_t=' '
541 else
542 ac_n=-n ac_c= ac_t=
543 fi
544else
545 ac_n= ac_c='\c' ac_t=
546fi
547
ac48eca1 548echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
d64552c5 549echo "configure:550: checking for Cygwin environment" >&5
ac48eca1
AO
550if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
551 echo $ac_n "(cached) $ac_c" 1>&6
552else
553 cat > conftest.$ac_ext <<EOF
d64552c5 554#line 555 "configure"
ac48eca1
AO
555#include "confdefs.h"
556
557int main() {
558
559#ifndef __CYGWIN__
560#define __CYGWIN__ __CYGWIN32__
561#endif
562return __CYGWIN__;
563; return 0; }
564EOF
d64552c5 565if { (eval echo configure:566: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
ac48eca1
AO
566 rm -rf conftest*
567 ac_cv_cygwin=yes
568else
569 echo "configure: failed program was:" >&5
570 cat conftest.$ac_ext >&5
571 rm -rf conftest*
572 ac_cv_cygwin=no
573fi
574rm -f conftest*
575rm -f conftest*
576fi
577
578echo "$ac_t""$ac_cv_cygwin" 1>&6
579CYGWIN=
580test "$ac_cv_cygwin" = yes && CYGWIN=yes
581echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
d64552c5 582echo "configure:583: checking for mingw32 environment" >&5
ac48eca1
AO
583if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
584 echo $ac_n "(cached) $ac_c" 1>&6
585else
586 cat > conftest.$ac_ext <<EOF
d64552c5 587#line 588 "configure"
ac48eca1
AO
588#include "confdefs.h"
589
590int main() {
591return __MINGW32__;
592; return 0; }
593EOF
d64552c5 594if { (eval echo configure:595: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
ac48eca1
AO
595 rm -rf conftest*
596 ac_cv_mingw32=yes
597else
598 echo "configure: failed program was:" >&5
599 cat conftest.$ac_ext >&5
600 rm -rf conftest*
601 ac_cv_mingw32=no
602fi
603rm -f conftest*
604rm -f conftest*
605fi
606
607echo "$ac_t""$ac_cv_mingw32" 1>&6
608MINGW32=
609test "$ac_cv_mingw32" = yes && MINGW32=yes
252b5132
RH
610
611
612ac_aux_dir=
613for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
614 if test -f $ac_dir/install-sh; then
615 ac_aux_dir=$ac_dir
616 ac_install_sh="$ac_aux_dir/install-sh -c"
617 break
618 elif test -f $ac_dir/install.sh; then
619 ac_aux_dir=$ac_dir
620 ac_install_sh="$ac_aux_dir/install.sh -c"
621 break
622 fi
623done
624if test -z "$ac_aux_dir"; then
625 { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
626fi
627ac_config_guess=$ac_aux_dir/config.guess
628ac_config_sub=$ac_aux_dir/config.sub
629ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
630
631
632# Do some error checking and defaulting for the host and target type.
633# The inputs are:
634# configure --host=HOST --target=TARGET --build=BUILD NONOPT
635#
636# The rules are:
637# 1. You are not allowed to specify --host, --target, and nonopt at the
638# same time.
639# 2. Host defaults to nonopt.
640# 3. If nonopt is not specified, then host defaults to the current host,
641# as determined by config.guess.
642# 4. Target and build default to nonopt.
643# 5. If nonopt is not specified, then target and build default to host.
644
645# The aliases save the names the user supplied, while $host etc.
646# will get canonicalized.
647case $host---$target---$nonopt in
648NONE---*---* | *---NONE---* | *---*---NONE) ;;
649*) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;;
650esac
651
652
653# Make sure we can run config.sub.
654if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
655else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
656fi
657
658echo $ac_n "checking host system type""... $ac_c" 1>&6
d64552c5 659echo "configure:660: checking host system type" >&5
252b5132
RH
660
661host_alias=$host
662case "$host_alias" in
663NONE)
664 case $nonopt in
665 NONE)
666 if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
667 else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
668 fi ;;
669 *) host_alias=$nonopt ;;
670 esac ;;
671esac
672
673host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
674host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
675host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
676host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
677echo "$ac_t""$host" 1>&6
678
679echo $ac_n "checking target system type""... $ac_c" 1>&6
d64552c5 680echo "configure:681: checking target system type" >&5
252b5132
RH
681
682target_alias=$target
683case "$target_alias" in
684NONE)
685 case $nonopt in
686 NONE) target_alias=$host_alias ;;
687 *) target_alias=$nonopt ;;
688 esac ;;
689esac
690
691target=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $target_alias`
692target_cpu=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
693target_vendor=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
694target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
695echo "$ac_t""$target" 1>&6
696
697echo $ac_n "checking build system type""... $ac_c" 1>&6
d64552c5 698echo "configure:699: checking build system type" >&5
252b5132
RH
699
700build_alias=$build
701case "$build_alias" in
702NONE)
703 case $nonopt in
704 NONE) build_alias=$host_alias ;;
705 *) build_alias=$nonopt ;;
706 esac ;;
707esac
708
709build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias`
710build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
711build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
712build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
713echo "$ac_t""$build" 1>&6
714
715test "$host_alias" != "$target_alias" &&
716 test "$program_prefix$program_suffix$program_transform_name" = \
717 NONENONEs,x,x, &&
718 program_prefix=${target_alias}-
719
5d64ca4e
L
720# Extract the first word of "gcc", so it can be a program name with args.
721set dummy gcc; ac_word=$2
722echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
d64552c5 723echo "configure:724: checking for $ac_word" >&5
5d64ca4e
L
724if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
725 echo $ac_n "(cached) $ac_c" 1>&6
726else
727 if test -n "$CC"; then
728 ac_cv_prog_CC="$CC" # Let the user override the test.
729else
730 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
731 ac_dummy="$PATH"
732 for ac_dir in $ac_dummy; do
733 test -z "$ac_dir" && ac_dir=.
734 if test -f $ac_dir/$ac_word; then
735 ac_cv_prog_CC="gcc"
736 break
737 fi
738 done
739 IFS="$ac_save_ifs"
740fi
741fi
742CC="$ac_cv_prog_CC"
743if test -n "$CC"; then
744 echo "$ac_t""$CC" 1>&6
745else
746 echo "$ac_t""no" 1>&6
747fi
748
749if test -z "$CC"; then
750 # Extract the first word of "cc", so it can be a program name with args.
751set dummy cc; ac_word=$2
752echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
d64552c5 753echo "configure:754: checking for $ac_word" >&5
5d64ca4e
L
754if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
755 echo $ac_n "(cached) $ac_c" 1>&6
756else
757 if test -n "$CC"; then
758 ac_cv_prog_CC="$CC" # Let the user override the test.
759else
760 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
761 ac_prog_rejected=no
762 ac_dummy="$PATH"
763 for ac_dir in $ac_dummy; do
764 test -z "$ac_dir" && ac_dir=.
765 if test -f $ac_dir/$ac_word; then
766 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
767 ac_prog_rejected=yes
768 continue
769 fi
770 ac_cv_prog_CC="cc"
771 break
772 fi
773 done
774 IFS="$ac_save_ifs"
775if test $ac_prog_rejected = yes; then
776 # We found a bogon in the path, so make sure we never use it.
777 set dummy $ac_cv_prog_CC
778 shift
779 if test $# -gt 0; then
780 # We chose a different compiler from the bogus one.
781 # However, it has the same basename, so the bogon will be chosen
782 # first if we set CC to just the basename; use the full file name.
783 shift
784 set dummy "$ac_dir/$ac_word" "$@"
785 shift
786 ac_cv_prog_CC="$@"
787 fi
788fi
789fi
790fi
791CC="$ac_cv_prog_CC"
792if test -n "$CC"; then
793 echo "$ac_t""$CC" 1>&6
794else
795 echo "$ac_t""no" 1>&6
796fi
797
798 if test -z "$CC"; then
799 case "`uname -s`" in
800 *win32* | *WIN32*)
801 # Extract the first word of "cl", so it can be a program name with args.
802set dummy cl; ac_word=$2
803echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
d64552c5 804echo "configure:805: checking for $ac_word" >&5
5d64ca4e
L
805if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
806 echo $ac_n "(cached) $ac_c" 1>&6
807else
808 if test -n "$CC"; then
809 ac_cv_prog_CC="$CC" # Let the user override the test.
810else
811 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
812 ac_dummy="$PATH"
813 for ac_dir in $ac_dummy; do
814 test -z "$ac_dir" && ac_dir=.
815 if test -f $ac_dir/$ac_word; then
816 ac_cv_prog_CC="cl"
817 break
818 fi
819 done
820 IFS="$ac_save_ifs"
821fi
822fi
823CC="$ac_cv_prog_CC"
824if test -n "$CC"; then
825 echo "$ac_t""$CC" 1>&6
826else
827 echo "$ac_t""no" 1>&6
828fi
829 ;;
830 esac
831 fi
832 test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
833fi
834
835echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
d64552c5 836echo "configure:837: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
5d64ca4e
L
837
838ac_ext=c
839# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
840ac_cpp='$CPP $CPPFLAGS'
841ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
842ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
843cross_compiling=$ac_cv_prog_cc_cross
844
845cat > conftest.$ac_ext << EOF
846
d64552c5 847#line 848 "configure"
5d64ca4e
L
848#include "confdefs.h"
849
850main(){return(0);}
851EOF
d64552c5 852if { (eval echo configure:853: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5d64ca4e
L
853 ac_cv_prog_cc_works=yes
854 # If we can't run a trivial program, we are probably using a cross compiler.
855 if (./conftest; exit) 2>/dev/null; then
856 ac_cv_prog_cc_cross=no
857 else
858 ac_cv_prog_cc_cross=yes
859 fi
860else
861 echo "configure: failed program was:" >&5
862 cat conftest.$ac_ext >&5
863 ac_cv_prog_cc_works=no
864fi
865rm -fr conftest*
866ac_ext=c
867# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
868ac_cpp='$CPP $CPPFLAGS'
869ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
870ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
871cross_compiling=$ac_cv_prog_cc_cross
872
873echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
874if test $ac_cv_prog_cc_works = no; then
875 { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
876fi
877echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
d64552c5 878echo "configure:879: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
5d64ca4e
L
879echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
880cross_compiling=$ac_cv_prog_cc_cross
881
882echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
d64552c5 883echo "configure:884: checking whether we are using GNU C" >&5
5d64ca4e
L
884if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
885 echo $ac_n "(cached) $ac_c" 1>&6
886else
887 cat > conftest.c <<EOF
888#ifdef __GNUC__
889 yes;
890#endif
891EOF
d64552c5 892if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:893: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
5d64ca4e
L
893 ac_cv_prog_gcc=yes
894else
895 ac_cv_prog_gcc=no
896fi
897fi
898
899echo "$ac_t""$ac_cv_prog_gcc" 1>&6
900
901if test $ac_cv_prog_gcc = yes; then
902 GCC=yes
903else
904 GCC=
905fi
906
907ac_test_CFLAGS="${CFLAGS+set}"
908ac_save_CFLAGS="$CFLAGS"
909CFLAGS=
910echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
d64552c5 911echo "configure:912: checking whether ${CC-cc} accepts -g" >&5
5d64ca4e
L
912if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
913 echo $ac_n "(cached) $ac_c" 1>&6
914else
915 echo 'void f(){}' > conftest.c
916if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
917 ac_cv_prog_cc_g=yes
918else
919 ac_cv_prog_cc_g=no
920fi
921rm -f conftest*
922
923fi
924
925echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
926if test "$ac_test_CFLAGS" = set; then
927 CFLAGS="$ac_save_CFLAGS"
928elif test $ac_cv_prog_cc_g = yes; then
929 if test "$GCC" = yes; then
930 CFLAGS="-g -O2"
931 else
932 CFLAGS="-g"
933 fi
934else
935 if test "$GCC" = yes; then
936 CFLAGS="-O2"
937 else
938 CFLAGS=
939 fi
940fi
941
942echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6
d64552c5 943echo "configure:944: checking for POSIXized ISC" >&5
5d64ca4e
L
944if test -d /etc/conf/kconfig.d &&
945 grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
946then
947 echo "$ac_t""yes" 1>&6
948 ISC=yes # If later tests want to check for ISC.
949 cat >> confdefs.h <<\EOF
950#define _POSIX_SOURCE 1
951EOF
952
953 if test "$GCC" = yes; then
954 CC="$CC -posix"
955 else
956 CC="$CC -Xp"
957 fi
958else
959 echo "$ac_t""no" 1>&6
960 ISC=
961fi
962
252b5132
RH
963
964# Find a good install program. We prefer a C program (faster),
965# so one script is as good as another. But avoid the broken or
966# incompatible versions:
967# SysV /etc/install, /usr/sbin/install
968# SunOS /usr/etc/install
969# IRIX /sbin/install
970# AIX /bin/install
971# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
972# AFS /usr/afsws/bin/install, which mishandles nonexistent args
973# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
974# ./install, which can be erroneously created by make from ./install.sh.
975echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
d64552c5 976echo "configure:977: checking for a BSD compatible install" >&5
252b5132
RH
977if test -z "$INSTALL"; then
978if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
979 echo $ac_n "(cached) $ac_c" 1>&6
980else
981 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":"
982 for ac_dir in $PATH; do
983 # Account for people who put trailing slashes in PATH elements.
984 case "$ac_dir/" in
985 /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
986 *)
987 # OSF1 and SCO ODT 3.0 have their own names for install.
988 # Don't use installbsd from OSF since it installs stuff as root
989 # by default.
990 for ac_prog in ginstall scoinst install; do
991 if test -f $ac_dir/$ac_prog; then
992 if test $ac_prog = install &&
993 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
994 # AIX install. It has an incompatible calling convention.
995 :
996 else
997 ac_cv_path_install="$ac_dir/$ac_prog -c"
998 break 2
999 fi
1000 fi
1001 done
1002 ;;
1003 esac
1004 done
1005 IFS="$ac_save_IFS"
1006
1007fi
1008 if test "${ac_cv_path_install+set}" = set; then
1009 INSTALL="$ac_cv_path_install"
1010 else
1011 # As a last resort, use the slow shell script. We don't cache a
1012 # path for INSTALL within a source directory, because that will
1013 # break other packages using the cache if that directory is
1014 # removed, or if the path is relative.
1015 INSTALL="$ac_install_sh"
1016 fi
1017fi
1018echo "$ac_t""$INSTALL" 1>&6
1019
1020# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
1021# It thinks the first close brace ends the variable substitution.
1022test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
1023
1024test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
1025
1026test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
1027
1028echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
d64552c5 1029echo "configure:1030: checking whether build environment is sane" >&5
252b5132
RH
1030# Just in case
1031sleep 1
1032echo timestamp > conftestfile
1033# Do `set' in a subshell so we don't clobber the current shell's
1034# arguments. Must try -L first in case configure is actually a
1035# symlink; some systems play weird games with the mod time of symlinks
1036# (eg FreeBSD returns the mod time of the symlink's containing
1037# directory).
1038if (
1039 set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
1040 if test "$*" = "X"; then
1041 # -L didn't work.
1042 set X `ls -t $srcdir/configure conftestfile`
1043 fi
1044 if test "$*" != "X $srcdir/configure conftestfile" \
1045 && test "$*" != "X conftestfile $srcdir/configure"; then
1046
1047 # If neither matched, then we have a broken ls. This can happen
1048 # if, for instance, CONFIG_SHELL is bash and it inherits a
1049 # broken ls alias from the environment. This has actually
1050 # happened. Such a system could not be considered "sane".
1051 { echo "configure: error: ls -t appears to fail. Make sure there is not a broken
1052alias in your environment" 1>&2; exit 1; }
1053 fi
1054
1055 test "$2" = conftestfile
1056 )
1057then
1058 # Ok.
1059 :
1060else
1061 { echo "configure: error: newly created file is older than distributed files!
1062Check your system clock" 1>&2; exit 1; }
1063fi
1064rm -f conftest*
1065echo "$ac_t""yes" 1>&6
1066if test "$program_transform_name" = s,x,x,; then
1067 program_transform_name=
1068else
1069 # Double any \ or $. echo might interpret backslashes.
1070 cat <<\EOF_SED > conftestsed
1071s,\\,\\\\,g; s,\$,$$,g
1072EOF_SED
1073 program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
1074 rm -f conftestsed
1075fi
1076test "$program_prefix" != NONE &&
1077 program_transform_name="s,^,${program_prefix},; $program_transform_name"
1078# Use a double $ so make ignores it.
1079test "$program_suffix" != NONE &&
1080 program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
1081
1082# sed with no file args requires a program.
1083test "$program_transform_name" = "" && program_transform_name="s,x,x,"
1084
1085echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
d64552c5 1086echo "configure:1087: checking whether ${MAKE-make} sets \${MAKE}" >&5
252b5132
RH
1087set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
1088if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
1089 echo $ac_n "(cached) $ac_c" 1>&6
1090else
1091 cat > conftestmake <<\EOF
1092all:
1093 @echo 'ac_maketemp="${MAKE}"'
1094EOF
1095# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1096eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
1097if test -n "$ac_maketemp"; then
1098 eval ac_cv_prog_make_${ac_make}_set=yes
1099else
1100 eval ac_cv_prog_make_${ac_make}_set=no
1101fi
1102rm -f conftestmake
1103fi
1104if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
1105 echo "$ac_t""yes" 1>&6
1106 SET_MAKE=
1107else
1108 echo "$ac_t""no" 1>&6
1109 SET_MAKE="MAKE=${MAKE-make}"
1110fi
1111
1112
1113PACKAGE=binutils
1114
18e03609 1115VERSION=2.10.91
252b5132
RH
1116
1117if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
1118 { echo "configure: error: source directory already configured; run "make distclean" there first" 1>&2; exit 1; }
1119fi
1120cat >> confdefs.h <<EOF
1121#define PACKAGE "$PACKAGE"
1122EOF
1123
1124cat >> confdefs.h <<EOF
1125#define VERSION "$VERSION"
1126EOF
1127
1128
1129
1130missing_dir=`cd $ac_aux_dir && pwd`
1131echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
d64552c5 1132echo "configure:1133: checking for working aclocal" >&5
252b5132
RH
1133# Run test in a subshell; some versions of sh will print an error if
1134# an executable is not found, even if stderr is redirected.
1135# Redirect stdin to placate older versions of autoconf. Sigh.
1136if (aclocal --version) < /dev/null > /dev/null 2>&1; then
1137 ACLOCAL=aclocal
1138 echo "$ac_t""found" 1>&6
1139else
1140 ACLOCAL="$missing_dir/missing aclocal"
1141 echo "$ac_t""missing" 1>&6
1142fi
1143
1144echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
d64552c5 1145echo "configure:1146: checking for working autoconf" >&5
252b5132
RH
1146# Run test in a subshell; some versions of sh will print an error if
1147# an executable is not found, even if stderr is redirected.
1148# Redirect stdin to placate older versions of autoconf. Sigh.
1149if (autoconf --version) < /dev/null > /dev/null 2>&1; then
1150 AUTOCONF=autoconf
1151 echo "$ac_t""found" 1>&6
1152else
1153 AUTOCONF="$missing_dir/missing autoconf"
1154 echo "$ac_t""missing" 1>&6
1155fi
1156
1157echo $ac_n "checking for working automake""... $ac_c" 1>&6
d64552c5 1158echo "configure:1159: checking for working automake" >&5
252b5132
RH
1159# Run test in a subshell; some versions of sh will print an error if
1160# an executable is not found, even if stderr is redirected.
1161# Redirect stdin to placate older versions of autoconf. Sigh.
1162if (automake --version) < /dev/null > /dev/null 2>&1; then
1163 AUTOMAKE=automake
1164 echo "$ac_t""found" 1>&6
1165else
1166 AUTOMAKE="$missing_dir/missing automake"
1167 echo "$ac_t""missing" 1>&6
1168fi
1169
1170echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
d64552c5 1171echo "configure:1172: checking for working autoheader" >&5
252b5132
RH
1172# Run test in a subshell; some versions of sh will print an error if
1173# an executable is not found, even if stderr is redirected.
1174# Redirect stdin to placate older versions of autoconf. Sigh.
1175if (autoheader --version) < /dev/null > /dev/null 2>&1; then
1176 AUTOHEADER=autoheader
1177 echo "$ac_t""found" 1>&6
1178else
1179 AUTOHEADER="$missing_dir/missing autoheader"
1180 echo "$ac_t""missing" 1>&6
1181fi
1182
1183echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
d64552c5 1184echo "configure:1185: checking for working makeinfo" >&5
252b5132
RH
1185# Run test in a subshell; some versions of sh will print an error if
1186# an executable is not found, even if stderr is redirected.
1187# Redirect stdin to placate older versions of autoconf. Sigh.
1188if (makeinfo --version) < /dev/null > /dev/null 2>&1; then
1189 MAKEINFO=makeinfo
1190 echo "$ac_t""found" 1>&6
1191else
1192 MAKEINFO="$missing_dir/missing makeinfo"
1193 echo "$ac_t""missing" 1>&6
1194fi
1195
1196
1197
1198# Check whether --enable-shared or --disable-shared was given.
1199if test "${enable_shared+set}" = set; then
1200 enableval="$enable_shared"
1201 p=${PACKAGE-default}
1202case "$enableval" in
1203yes) enable_shared=yes ;;
1204no) enable_shared=no ;;
1205*)
1206 enable_shared=no
1207 # Look at the argument we got. We use all the common list separators.
1208 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
1209 for pkg in $enableval; do
1210 if test "X$pkg" = "X$p"; then
1211 enable_shared=yes
1212 fi
1213 done
1214 IFS="$ac_save_ifs"
1215 ;;
1216esac
1217else
1218 enable_shared=yes
1219fi
1220
1221# Check whether --enable-static or --disable-static was given.
1222if test "${enable_static+set}" = set; then
1223 enableval="$enable_static"
1224 p=${PACKAGE-default}
1225case "$enableval" in
1226yes) enable_static=yes ;;
1227no) enable_static=no ;;
1228*)
1229 enable_static=no
1230 # Look at the argument we got. We use all the common list separators.
1231 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
1232 for pkg in $enableval; do
1233 if test "X$pkg" = "X$p"; then
1234 enable_static=yes
1235 fi
1236 done
1237 IFS="$ac_save_ifs"
1238 ;;
1239esac
1240else
1241 enable_static=yes
1242fi
1243
1244# Check whether --enable-fast-install or --disable-fast-install was given.
1245if test "${enable_fast_install+set}" = set; then
1246 enableval="$enable_fast_install"
1247 p=${PACKAGE-default}
1248case "$enableval" in
1249yes) enable_fast_install=yes ;;
1250no) enable_fast_install=no ;;
1251*)
1252 enable_fast_install=no
1253 # Look at the argument we got. We use all the common list separators.
1254 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
1255 for pkg in $enableval; do
1256 if test "X$pkg" = "X$p"; then
1257 enable_fast_install=yes
1258 fi
1259 done
1260 IFS="$ac_save_ifs"
1261 ;;
1262esac
1263else
1264 enable_fast_install=yes
1265fi
1266
252b5132
RH
1267# Check whether --with-gnu-ld or --without-gnu-ld was given.
1268if test "${with_gnu_ld+set}" = set; then
1269 withval="$with_gnu_ld"
1270 test "$withval" = no || with_gnu_ld=yes
1271else
1272 with_gnu_ld=no
1273fi
1274
1275ac_prog=ld
1276if test "$ac_cv_prog_gcc" = yes; then
1277 # Check if gcc -print-prog-name=ld gives a path.
1278 echo $ac_n "checking for ld used by GCC""... $ac_c" 1>&6
d64552c5 1279echo "configure:1280: checking for ld used by GCC" >&5
ac48eca1
AO
1280 case $host in
1281 *-*-mingw*)
1282 # gcc leaves a trailing carriage return which upsets mingw
1283 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
1284 *)
1285 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
1286 esac
252b5132
RH
1287 case "$ac_prog" in
1288 # Accept absolute paths.
a74801ba 1289 [\\/]* | [A-Za-z]:[\\/]*)
252b5132
RH
1290 re_direlt='/[^/][^/]*/\.\./'
1291 # Canonicalize the path of ld
1292 ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
1293 while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
1294 ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
1295 done
1296 test -z "$LD" && LD="$ac_prog"
1297 ;;
1298 "")
1299 # If it fails, then pretend we aren't using GCC.
1300 ac_prog=ld
1301 ;;
1302 *)
1303 # If it is relative, then search for the first ld in PATH.
1304 with_gnu_ld=unknown
1305 ;;
1306 esac
1307elif test "$with_gnu_ld" = yes; then
1308 echo $ac_n "checking for GNU ld""... $ac_c" 1>&6
d64552c5 1309echo "configure:1310: checking for GNU ld" >&5
252b5132
RH
1310else
1311 echo $ac_n "checking for non-GNU ld""... $ac_c" 1>&6
d64552c5 1312echo "configure:1313: checking for non-GNU ld" >&5
252b5132
RH
1313fi
1314if eval "test \"`echo '$''{'ac_cv_path_LD'+set}'`\" = set"; then
1315 echo $ac_n "(cached) $ac_c" 1>&6
1316else
1317 if test -z "$LD"; then
a74801ba 1318 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
252b5132
RH
1319 for ac_dir in $PATH; do
1320 test -z "$ac_dir" && ac_dir=.
a74801ba 1321 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
252b5132
RH
1322 ac_cv_path_LD="$ac_dir/$ac_prog"
1323 # Check to see if the program is GNU ld. I'd rather use --version,
1324 # but apparently some GNU ld's only accept -v.
1325 # Break only if it was the GNU/non-GNU ld that we prefer.
1326 if "$ac_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
1327 test "$with_gnu_ld" != no && break
1328 else
1329 test "$with_gnu_ld" != yes && break
1330 fi
1331 fi
1332 done
1333 IFS="$ac_save_ifs"
1334else
1335 ac_cv_path_LD="$LD" # Let the user override the test with a path.
1336fi
1337fi
1338
1339LD="$ac_cv_path_LD"
1340if test -n "$LD"; then
1341 echo "$ac_t""$LD" 1>&6
1342else
1343 echo "$ac_t""no" 1>&6
1344fi
1345test -z "$LD" && { echo "configure: error: no acceptable ld found in \$PATH" 1>&2; exit 1; }
252b5132 1346echo $ac_n "checking if the linker ($LD) is GNU ld""... $ac_c" 1>&6
d64552c5 1347echo "configure:1348: checking if the linker ($LD) is GNU ld" >&5
252b5132
RH
1348if eval "test \"`echo '$''{'ac_cv_prog_gnu_ld'+set}'`\" = set"; then
1349 echo $ac_n "(cached) $ac_c" 1>&6
1350else
1351 # I'd rather use --version here, but apparently some GNU ld's only accept -v.
1352if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
1353 ac_cv_prog_gnu_ld=yes
1354else
1355 ac_cv_prog_gnu_ld=no
1356fi
1357fi
1358
1359echo "$ac_t""$ac_cv_prog_gnu_ld" 1>&6
ac48eca1 1360with_gnu_ld=$ac_cv_prog_gnu_ld
252b5132
RH
1361
1362
ac48eca1 1363echo $ac_n "checking for $LD option to reload object files""... $ac_c" 1>&6
d64552c5 1364echo "configure:1365: checking for $LD option to reload object files" >&5
ac48eca1
AO
1365if eval "test \"`echo '$''{'lt_cv_ld_reload_flag'+set}'`\" = set"; then
1366 echo $ac_n "(cached) $ac_c" 1>&6
1367else
1368 lt_cv_ld_reload_flag='-r'
1369fi
1370
1371echo "$ac_t""$lt_cv_ld_reload_flag" 1>&6
1372reload_flag=$lt_cv_ld_reload_flag
1373test -n "$reload_flag" && reload_flag=" $reload_flag"
1374
252b5132 1375echo $ac_n "checking for BSD-compatible nm""... $ac_c" 1>&6
d64552c5 1376echo "configure:1377: checking for BSD-compatible nm" >&5
252b5132
RH
1377if eval "test \"`echo '$''{'ac_cv_path_NM'+set}'`\" = set"; then
1378 echo $ac_n "(cached) $ac_c" 1>&6
1379else
1380 if test -n "$NM"; then
1381 # Let the user override the test.
1382 ac_cv_path_NM="$NM"
1383else
a74801ba 1384 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
252b5132
RH
1385 for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do
1386 test -z "$ac_dir" && ac_dir=.
ac48eca1
AO
1387 tmp_nm=$ac_dir/${ac_tool_prefix}nm
1388 if test -f $tmp_nm || test -f $tmp_nm$ac_exeext ; then
252b5132
RH
1389 # Check to see if the nm accepts a BSD-compat flag.
1390 # Adding the `sed 1q' prevents false positives on HP-UX, which says:
1391 # nm: unknown option "B" ignored
58cccadb
AO
1392 # Tru64's nm complains that /dev/null is an invalid object file
1393 if ($tmp_nm -B /dev/null 2>&1 | sed '1q'; exit 0) | egrep '(/dev/null|Invalid file or object type)' >/dev/null; then
ac48eca1 1394 ac_cv_path_NM="$tmp_nm -B"
252b5132 1395 break
ac48eca1
AO
1396 elif ($tmp_nm -p /dev/null 2>&1 | sed '1q'; exit 0) | egrep /dev/null >/dev/null; then
1397 ac_cv_path_NM="$tmp_nm -p"
252b5132
RH
1398 break
1399 else
ac48eca1 1400 ac_cv_path_NM=${ac_cv_path_NM="$tmp_nm"} # keep the first match, but
252b5132
RH
1401 continue # so that we can try to find one that supports BSD flags
1402 fi
1403 fi
1404 done
1405 IFS="$ac_save_ifs"
1406 test -z "$ac_cv_path_NM" && ac_cv_path_NM=nm
1407fi
1408fi
1409
1410NM="$ac_cv_path_NM"
1411echo "$ac_t""$NM" 1>&6
1412
252b5132 1413echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
d64552c5 1414echo "configure:1415: checking whether ln -s works" >&5
252b5132
RH
1415if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
1416 echo $ac_n "(cached) $ac_c" 1>&6
1417else
1418 rm -f conftestdata
1419if ln -s X conftestdata 2>/dev/null
1420then
1421 rm -f conftestdata
1422 ac_cv_prog_LN_S="ln -s"
1423else
1424 ac_cv_prog_LN_S=ln
1425fi
1426fi
1427LN_S="$ac_cv_prog_LN_S"
1428if test "$ac_cv_prog_LN_S" = "ln -s"; then
1429 echo "$ac_t""yes" 1>&6
1430else
1431 echo "$ac_t""no" 1>&6
1432fi
1433
ac48eca1 1434echo $ac_n "checking how to recognise dependant libraries""... $ac_c" 1>&6
d64552c5 1435echo "configure:1436: checking how to recognise dependant libraries" >&5
ac48eca1
AO
1436if eval "test \"`echo '$''{'lt_cv_deplibs_check_method'+set}'`\" = set"; then
1437 echo $ac_n "(cached) $ac_c" 1>&6
1438else
d64552c5 1439 lt_cv_file_magic_cmd='$MAGIC_CMD'
ac48eca1
AO
1440lt_cv_file_magic_test_file=
1441lt_cv_deplibs_check_method='unknown'
1442# Need to set the preceding variable on all platforms that support
1443# interlibrary dependencies.
1444# 'none' -- dependencies not supported.
1445# `unknown' -- same as none, but documents that we really don't know.
1446# 'pass_all' -- all dependencies passed with no checks.
1447# 'test_compile' -- check by making test program.
1448# 'file_magic [regex]' -- check by looking for files in library path
1449# which responds to the $file_magic_cmd with a given egrep regex.
1450# If you have `file' or equivalent on your system and you're not sure
1451# whether `pass_all' will *always* work, you probably want this one.
1452
1453case "$host_os" in
1454aix4*)
1455 lt_cv_deplibs_check_method=pass_all
1456 ;;
1457
1458beos*)
1459 lt_cv_deplibs_check_method=pass_all
1460 ;;
1461
1462bsdi4*)
1463 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
1464 lt_cv_file_magic_cmd='/usr/bin/file -L'
1465 lt_cv_file_magic_test_file=/shlib/libc.so
1466 ;;
1467
d64552c5 1468cygwin* | mingw* |pw32*)
ac48eca1 1469 lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
d64552c5 1470 lt_cv_file_magic_cmd='$OBJDUMP -f'
ac48eca1
AO
1471 ;;
1472
1473freebsd* )
1474 if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
1475 case "$host_cpu" in
1476 i*86 )
58cccadb
AO
1477 # Not sure whether the presence of OpenBSD here was a mistake.
1478 # Let's accept both of them until this is cleared up.
1479 lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD)/i[3-9]86 (compact )?demand paged shared library'
ac48eca1
AO
1480 lt_cv_file_magic_cmd=/usr/bin/file
1481 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
1482 ;;
1483 esac
1484 else
1485 lt_cv_deplibs_check_method=pass_all
1486 fi
1487 ;;
1488
1489gnu*)
1490 lt_cv_deplibs_check_method=pass_all
1491 ;;
1492
1493hpux10.20*)
1494 # TODO: Does this work for hpux-11 too?
1495 lt_cv_deplibs_check_method='file_magic (s0-90-90-9|PA-RISC0-9.0-9) shared library'
1496 lt_cv_file_magic_cmd=/usr/bin/file
1497 lt_cv_file_magic_test_file=/usr/lib/libc.sl
1498 ;;
1499
1500irix5* | irix6*)
1501 case "$host_os" in
1502 irix5*)
1503 # this will be overridden with pass_all, but let us keep it just in case
1504 lt_cv_deplibs_check_method="file_magic ELF 32-bit MSB dynamic lib MIPS - version 1"
1505 ;;
1506 *)
1507 case "$LD" in
1508 *-32|*"-32 ") libmagic=32-bit;;
1509 *-n32|*"-n32 ") libmagic=N32;;
1510 *-64|*"-64 ") libmagic=64-bit;;
1511 *) libmagic=never-match;;
1512 esac
1513 # this will be overridden with pass_all, but let us keep it just in case
1514 lt_cv_deplibs_check_method="file_magic ELF ${libmagic} MSB mips-[1234] dynamic lib MIPS - version 1"
1515 ;;
1516 esac
1517 lt_cv_file_magic_test_file=`echo /lib${libsuff}/libc.so*`
1518 lt_cv_deplibs_check_method=pass_all
1519 ;;
1520
1521# This must be Linux ELF.
58cccadb 1522linux-gnu*)
ac48eca1
AO
1523 case "$host_cpu" in
1524 alpha* | i*86 | powerpc* | sparc* | ia64* )
1525 lt_cv_deplibs_check_method=pass_all ;;
1526 *)
1527 # glibc up to 2.1.1 does not perform some relocations on ARM
1528 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )' ;;
1529 esac
1530 lt_cv_file_magic_test_file=`echo /lib/libc.so* /lib/libc-*.so`
1531 ;;
1532
1533netbsd*)
1534 if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then :
1535 else
1536 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB shared object'
1537 lt_cv_file_magic_cmd='/usr/bin/file -L'
1538 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
1539 fi
1540 ;;
1541
1542osf3* | osf4* | osf5*)
1543 # this will be overridden with pass_all, but let us keep it just in case
1544 lt_cv_deplibs_check_method='file_magic COFF format alpha shared library'
1545 lt_cv_file_magic_test_file=/shlib/libc.so
1546 lt_cv_deplibs_check_method=pass_all
1547 ;;
1548
1549sco3.2v5*)
1550 lt_cv_deplibs_check_method=pass_all
1551 ;;
1552
1553solaris*)
1554 lt_cv_deplibs_check_method=pass_all
1555 lt_cv_file_magic_test_file=/lib/libc.so
1556 ;;
1557
1558sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
1559 case "$host_vendor" in
1560 ncr)
1561 lt_cv_deplibs_check_method=pass_all
1562 ;;
1563 motorola)
1564 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib) M[0-9][0-9]* Version [0-9]'
1565 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
1566 ;;
1567 esac
1568 ;;
1569esac
1570
1571fi
1572
1573echo "$ac_t""$lt_cv_deplibs_check_method" 1>&6
1574file_magic_cmd=$lt_cv_file_magic_cmd
1575deplibs_check_method=$lt_cv_deplibs_check_method
1576
1577echo $ac_n "checking for object suffix""... $ac_c" 1>&6
d64552c5 1578echo "configure:1579: checking for object suffix" >&5
ac48eca1
AO
1579if eval "test \"`echo '$''{'ac_cv_objext'+set}'`\" = set"; then
1580 echo $ac_n "(cached) $ac_c" 1>&6
1581else
1582 rm -f conftest*
1583echo 'int i = 1;' > conftest.$ac_ext
d64552c5 1584if { (eval echo configure:1585: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
ac48eca1
AO
1585 for ac_file in conftest.*; do
1586 case $ac_file in
1587 *.c) ;;
1588 *) ac_cv_objext=`echo $ac_file | sed -e s/conftest.//` ;;
1589 esac
1590 done
1591else
1592 { echo "configure: error: installation or configuration problem; compiler does not work" 1>&2; exit 1; }
1593fi
1594rm -f conftest*
1595fi
1596
1597echo "$ac_t""$ac_cv_objext" 1>&6
1598OBJEXT=$ac_cv_objext
1599ac_objext=$ac_cv_objext
1600
1601
1602
1603echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
d64552c5 1604echo "configure:1605: checking for executable suffix" >&5
ac48eca1
AO
1605if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
1606 echo $ac_n "(cached) $ac_c" 1>&6
1607else
1608 if test "$CYGWIN" = yes || test "$MINGW32" = yes; then
1609 ac_cv_exeext=.exe
1610else
1611 rm -f conftest*
1612 echo 'int main () { return 0; }' > conftest.$ac_ext
1613 ac_cv_exeext=
d64552c5 1614 if { (eval echo configure:1615: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
ac48eca1
AO
1615 for file in conftest.*; do
1616 case $file in
d64552c5 1617 *.c | *.o | *.obj) ;;
ac48eca1
AO
1618 *) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
1619 esac
1620 done
1621 else
1622 { echo "configure: error: installation or configuration problem: compiler cannot create executables." 1>&2; exit 1; }
1623 fi
1624 rm -f conftest*
1625 test x"${ac_cv_exeext}" = x && ac_cv_exeext=no
1626fi
1627fi
1628
1629EXEEXT=""
1630test x"${ac_cv_exeext}" != xno && EXEEXT=${ac_cv_exeext}
1631echo "$ac_t""${ac_cv_exeext}" 1>&6
1632ac_exeext=$EXEEXT
1633
1634if test $host != $build; then
1635 ac_tool_prefix=${host_alias}-
1636else
1637 ac_tool_prefix=
1638fi
1639
1640# Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers!
1641
1642# Only perform the check for file, if the check method requires it
1643case "$deplibs_check_method" in
1644file_magic*)
d64552c5 1645 if test "$file_magic_cmd" = '$MAGIC_CMD'; then
ac48eca1 1646 echo $ac_n "checking for ${ac_tool_prefix}file""... $ac_c" 1>&6
d64552c5
AO
1647echo "configure:1648: checking for ${ac_tool_prefix}file" >&5
1648if eval "test \"`echo '$''{'lt_cv_path_MAGIC_CMD'+set}'`\" = set"; then
ac48eca1
AO
1649 echo $ac_n "(cached) $ac_c" 1>&6
1650else
d64552c5 1651 case "$MAGIC_CMD" in
ac48eca1 1652 /*)
d64552c5 1653 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
ac48eca1
AO
1654 ;;
1655 ?:/*)
d64552c5 1656 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a dos path.
ac48eca1
AO
1657 ;;
1658 *)
d64552c5 1659 ac_save_MAGIC_CMD="$MAGIC_CMD"
ac48eca1
AO
1660 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1661 ac_dummy="/usr/bin:$PATH"
1662 for ac_dir in $ac_dummy; do
1663 test -z "$ac_dir" && ac_dir=.
1664 if test -f $ac_dir/${ac_tool_prefix}file; then
d64552c5 1665 lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file"
ac48eca1
AO
1666 if test -n "$file_magic_test_file"; then
1667 case "$deplibs_check_method" in
1668 "file_magic "*)
1669 file_magic_regex="`expr \"$deplibs_check_method\" : \"file_magic \(.*\)\"`"
d64552c5 1670 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
ac48eca1
AO
1671 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
1672 egrep "$file_magic_regex" > /dev/null; then
1673 :
1674 else
1675 cat <<EOF 1>&2
1676
1677*** Warning: the command libtool uses to detect shared libraries,
1678*** $file_magic_cmd, produces output that libtool cannot recognize.
1679*** The result is that libtool may fail to recognize shared libraries
1680*** as such. This will affect the creation of libtool libraries that
1681*** depend on shared libraries, but programs linked with such libtool
1682*** libraries will work regardless of this problem. Nevertheless, you
1683*** may want to report the problem to your system manager and/or to
1684*** bug-libtool@gnu.org
1685
1686EOF
1687 fi ;;
1688 esac
1689 fi
1690 break
1691 fi
1692 done
1693 IFS="$ac_save_ifs"
d64552c5 1694 MAGIC_CMD="$ac_save_MAGIC_CMD"
ac48eca1
AO
1695 ;;
1696esac
1697fi
1698
d64552c5
AO
1699MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
1700if test -n "$MAGIC_CMD"; then
1701 echo "$ac_t""$MAGIC_CMD" 1>&6
ac48eca1
AO
1702else
1703 echo "$ac_t""no" 1>&6
1704fi
1705
d64552c5 1706if test -z "$lt_cv_path_MAGIC_CMD"; then
ac48eca1
AO
1707 if test -n "$ac_tool_prefix"; then
1708 echo $ac_n "checking for file""... $ac_c" 1>&6
d64552c5
AO
1709echo "configure:1710: checking for file" >&5
1710if eval "test \"`echo '$''{'lt_cv_path_MAGIC_CMD'+set}'`\" = set"; then
ac48eca1
AO
1711 echo $ac_n "(cached) $ac_c" 1>&6
1712else
d64552c5 1713 case "$MAGIC_CMD" in
ac48eca1 1714 /*)
d64552c5 1715 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
ac48eca1
AO
1716 ;;
1717 ?:/*)
d64552c5 1718 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a dos path.
ac48eca1
AO
1719 ;;
1720 *)
d64552c5 1721 ac_save_MAGIC_CMD="$MAGIC_CMD"
ac48eca1
AO
1722 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1723 ac_dummy="/usr/bin:$PATH"
1724 for ac_dir in $ac_dummy; do
1725 test -z "$ac_dir" && ac_dir=.
1726 if test -f $ac_dir/file; then
d64552c5 1727 lt_cv_path_MAGIC_CMD="$ac_dir/file"
ac48eca1
AO
1728 if test -n "$file_magic_test_file"; then
1729 case "$deplibs_check_method" in
1730 "file_magic "*)
1731 file_magic_regex="`expr \"$deplibs_check_method\" : \"file_magic \(.*\)\"`"
d64552c5 1732 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
ac48eca1
AO
1733 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
1734 egrep "$file_magic_regex" > /dev/null; then
1735 :
1736 else
1737 cat <<EOF 1>&2
1738
1739*** Warning: the command libtool uses to detect shared libraries,
1740*** $file_magic_cmd, produces output that libtool cannot recognize.
1741*** The result is that libtool may fail to recognize shared libraries
1742*** as such. This will affect the creation of libtool libraries that
1743*** depend on shared libraries, but programs linked with such libtool
1744*** libraries will work regardless of this problem. Nevertheless, you
1745*** may want to report the problem to your system manager and/or to
1746*** bug-libtool@gnu.org
1747
1748EOF
1749 fi ;;
1750 esac
1751 fi
1752 break
1753 fi
1754 done
1755 IFS="$ac_save_ifs"
d64552c5 1756 MAGIC_CMD="$ac_save_MAGIC_CMD"
ac48eca1
AO
1757 ;;
1758esac
1759fi
1760
d64552c5
AO
1761MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
1762if test -n "$MAGIC_CMD"; then
1763 echo "$ac_t""$MAGIC_CMD" 1>&6
ac48eca1
AO
1764else
1765 echo "$ac_t""no" 1>&6
1766fi
1767
1768 else
d64552c5 1769 MAGIC_CMD=:
ac48eca1
AO
1770 fi
1771fi
252b5132 1772
ac48eca1
AO
1773 fi
1774 ;;
a74801ba 1775esac
252b5132 1776
ac48eca1
AO
1777# Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
1778set dummy ${ac_tool_prefix}ranlib; ac_word=$2
1779echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
d64552c5 1780echo "configure:1781: checking for $ac_word" >&5
ac48eca1
AO
1781if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
1782 echo $ac_n "(cached) $ac_c" 1>&6
1783else
1784 if test -n "$RANLIB"; then
1785 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
1786else
1787 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1788 ac_dummy="$PATH"
1789 for ac_dir in $ac_dummy; do
1790 test -z "$ac_dir" && ac_dir=.
1791 if test -f $ac_dir/$ac_word; then
1792 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
1793 break
1794 fi
1795 done
1796 IFS="$ac_save_ifs"
1797fi
1798fi
1799RANLIB="$ac_cv_prog_RANLIB"
1800if test -n "$RANLIB"; then
1801 echo "$ac_t""$RANLIB" 1>&6
1802else
1803 echo "$ac_t""no" 1>&6
1804fi
1805
1806
1807if test -z "$ac_cv_prog_RANLIB"; then
1808if test -n "$ac_tool_prefix"; then
1809 # Extract the first word of "ranlib", so it can be a program name with args.
1810set dummy ranlib; ac_word=$2
1811echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
d64552c5 1812echo "configure:1813: checking for $ac_word" >&5
ac48eca1
AO
1813if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
1814 echo $ac_n "(cached) $ac_c" 1>&6
1815else
1816 if test -n "$RANLIB"; then
1817 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
1818else
1819 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1820 ac_dummy="$PATH"
1821 for ac_dir in $ac_dummy; do
1822 test -z "$ac_dir" && ac_dir=.
1823 if test -f $ac_dir/$ac_word; then
1824 ac_cv_prog_RANLIB="ranlib"
1825 break
1826 fi
1827 done
1828 IFS="$ac_save_ifs"
1829 test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
1830fi
1831fi
1832RANLIB="$ac_cv_prog_RANLIB"
1833if test -n "$RANLIB"; then
1834 echo "$ac_t""$RANLIB" 1>&6
1835else
1836 echo "$ac_t""no" 1>&6
1837fi
1838
1839else
1840 RANLIB=":"
1841fi
1842fi
1843
1844# Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
1845set dummy ${ac_tool_prefix}strip; ac_word=$2
1846echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
d64552c5 1847echo "configure:1848: checking for $ac_word" >&5
ac48eca1
AO
1848if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
1849 echo $ac_n "(cached) $ac_c" 1>&6
1850else
1851 if test -n "$STRIP"; then
1852 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
1853else
1854 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1855 ac_dummy="$PATH"
1856 for ac_dir in $ac_dummy; do
1857 test -z "$ac_dir" && ac_dir=.
1858 if test -f $ac_dir/$ac_word; then
1859 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
1860 break
1861 fi
1862 done
1863 IFS="$ac_save_ifs"
1864fi
1865fi
1866STRIP="$ac_cv_prog_STRIP"
1867if test -n "$STRIP"; then
1868 echo "$ac_t""$STRIP" 1>&6
1869else
1870 echo "$ac_t""no" 1>&6
1871fi
1872
1873
1874if test -z "$ac_cv_prog_STRIP"; then
1875if test -n "$ac_tool_prefix"; then
1876 # Extract the first word of "strip", so it can be a program name with args.
1877set dummy strip; ac_word=$2
1878echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
d64552c5 1879echo "configure:1880: checking for $ac_word" >&5
ac48eca1
AO
1880if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
1881 echo $ac_n "(cached) $ac_c" 1>&6
1882else
1883 if test -n "$STRIP"; then
1884 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
1885else
1886 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1887 ac_dummy="$PATH"
1888 for ac_dir in $ac_dummy; do
1889 test -z "$ac_dir" && ac_dir=.
1890 if test -f $ac_dir/$ac_word; then
1891 ac_cv_prog_STRIP="strip"
1892 break
1893 fi
1894 done
1895 IFS="$ac_save_ifs"
1896 test -z "$ac_cv_prog_STRIP" && ac_cv_prog_STRIP=":"
1897fi
1898fi
1899STRIP="$ac_cv_prog_STRIP"
1900if test -n "$STRIP"; then
1901 echo "$ac_t""$STRIP" 1>&6
1902else
1903 echo "$ac_t""no" 1>&6
1904fi
1905
1906else
1907 STRIP=":"
1908fi
1909fi
1910
1911
252b5132
RH
1912# Check for any special flags to pass to ltconfig.
1913libtool_flags="--cache-file=$cache_file"
1914test "$enable_shared" = no && libtool_flags="$libtool_flags --disable-shared"
1915test "$enable_static" = no && libtool_flags="$libtool_flags --disable-static"
1916test "$enable_fast_install" = no && libtool_flags="$libtool_flags --disable-fast-install"
252b5132
RH
1917test "$ac_cv_prog_gcc" = yes && libtool_flags="$libtool_flags --with-gcc"
1918test "$ac_cv_prog_gnu_ld" = yes && libtool_flags="$libtool_flags --with-gnu-ld"
1919
a74801ba
ILT
1920
1921# Check whether --enable-libtool-lock or --disable-libtool-lock was given.
1922if test "${enable_libtool_lock+set}" = set; then
1923 enableval="$enable_libtool_lock"
1924 :
1925fi
1926
1927test "x$enable_libtool_lock" = xno && libtool_flags="$libtool_flags --disable-lock"
1928test x"$silent" = xyes && libtool_flags="$libtool_flags --silent"
1929
ac48eca1
AO
1930# Check whether --with-pic or --without-pic was given.
1931if test "${with_pic+set}" = set; then
1932 withval="$with_pic"
1933 pic_mode="$withval"
1934else
1935 pic_mode=default
1936fi
1937
1938test x"$pic_mode" = xyes && libtool_flags="$libtool_flags --prefer-pic"
1939test x"$pic_mode" = xno && libtool_flags="$libtool_flags --prefer-non-pic"
1940
252b5132
RH
1941# Some flags need to be propagated to the compiler or linker for good
1942# libtool support.
ac48eca1 1943case "$host" in
252b5132
RH
1944*-*-irix6*)
1945 # Find out which ABI we are using.
d64552c5
AO
1946 echo '#line 1947 "configure"' > conftest.$ac_ext
1947 if { (eval echo configure:1948: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
252b5132
RH
1948 case "`/usr/bin/file conftest.o`" in
1949 *32-bit*)
1950 LD="${LD-ld} -32"
1951 ;;
1952 *N32*)
1953 LD="${LD-ld} -n32"
1954 ;;
1955 *64-bit*)
1956 LD="${LD-ld} -64"
1957 ;;
1958 esac
1959 fi
1960 rm -rf conftest*
1961 ;;
1962
1963*-*-sco3.2v5*)
1964 # On SCO OpenServer 5, we need -belf to get full-featured binaries.
1965 SAVE_CFLAGS="$CFLAGS"
1966 CFLAGS="$CFLAGS -belf"
1967 echo $ac_n "checking whether the C compiler needs -belf""... $ac_c" 1>&6
d64552c5 1968echo "configure:1969: checking whether the C compiler needs -belf" >&5
252b5132
RH
1969if eval "test \"`echo '$''{'lt_cv_cc_needs_belf'+set}'`\" = set"; then
1970 echo $ac_n "(cached) $ac_c" 1>&6
1971else
ac48eca1
AO
1972
1973 ac_ext=c
1974# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1975ac_cpp='$CPP $CPPFLAGS'
1976ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1977ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1978cross_compiling=$ac_cv_prog_cc_cross
1979
1980 cat > conftest.$ac_ext <<EOF
d64552c5 1981#line 1982 "configure"
252b5132
RH
1982#include "confdefs.h"
1983
1984int main() {
1985
1986; return 0; }
1987EOF
d64552c5 1988if { (eval echo configure:1989: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
1989 rm -rf conftest*
1990 lt_cv_cc_needs_belf=yes
1991else
1992 echo "configure: failed program was:" >&5
1993 cat conftest.$ac_ext >&5
1994 rm -rf conftest*
1995 lt_cv_cc_needs_belf=no
1996fi
1997rm -f conftest*
ac48eca1
AO
1998 ac_ext=c
1999# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
2000ac_cpp='$CPP $CPPFLAGS'
2001ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
2002ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
2003cross_compiling=$ac_cv_prog_cc_cross
2004
252b5132
RH
2005fi
2006
2007echo "$ac_t""$lt_cv_cc_needs_belf" 1>&6
2008 if test x"$lt_cv_cc_needs_belf" != x"yes"; then
2009 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
2010 CFLAGS="$SAVE_CFLAGS"
2011 fi
2012 ;;
2013
252b5132
RH
2014
2015esac
2016
252b5132
RH
2017
2018# Save cache, so that ltconfig can load it
2019cat > confcache <<\EOF
2020# This file is a shell script that caches the results of configure
2021# tests run on this system so they can be shared between configure
2022# scripts and configure runs. It is not useful on other systems.
2023# If it contains results you don't want to keep, you may remove or edit it.
2024#
2025# By default, configure uses ./config.cache as the cache file,
2026# creating it if it does not exist already. You can give configure
2027# the --cache-file=FILE option to use a different cache file; that is
2028# what configure does when it calls configure scripts in
2029# subdirectories, so they share the cache.
2030# Giving --cache-file=/dev/null disables caching, for debugging configure.
2031# config.status only pays attention to the cache file if you give it the
2032# --recheck option to rerun configure.
2033#
2034EOF
2035# The following way of writing the cache mishandles newlines in values,
2036# but we know of no workaround that is simple, portable, and efficient.
2037# So, don't put newlines in cache variables' values.
2038# Ultrix sh set writes to stderr and can't be redirected directly,
2039# and sets the high bit in the cache file unless we assign to the vars.
2040(set) 2>&1 |
2041 case `(ac_space=' '; set | grep ac_space) 2>&1` in
2042 *ac_space=\ *)
2043 # `set' does not quote correctly, so add quotes (double-quote substitution
2044 # turns \\\\ into \\, and sed turns \\ into \).
2045 sed -n \
2046 -e "s/'/'\\\\''/g" \
2047 -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
2048 ;;
2049 *)
2050 # `set' quotes correctly as required by POSIX, so do not add quotes.
2051 sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
2052 ;;
2053 esac >> confcache
2054if cmp -s $cache_file confcache; then
2055 :
2056else
2057 if test -w $cache_file; then
2058 echo "updating cache $cache_file"
2059 cat confcache > $cache_file
2060 else
2061 echo "not updating unwritable cache $cache_file"
2062 fi
2063fi
2064rm -f confcache
2065
2066
2067# Actually configure libtool. ac_aux_dir is where install-sh is found.
ac48eca1 2068AR="$AR" LTCC="$CC" CC="$CC" CFLAGS="$CFLAGS" CPPFLAGS="$CPPFLAGS" \
d64552c5 2069MAGIC_CMD="$MAGIC_CMD" LD="$LD" LDFLAGS="$LDFLAGS" LIBS="$LIBS" \
ac48eca1
AO
2070LN_S="$LN_S" NM="$NM" RANLIB="$RANLIB" STRIP="$STRIP" \
2071AS="$AS" DLLTOOL="$DLLTOOL" OBJDUMP="$OBJDUMP" \
2072objext="$OBJEXT" exeext="$EXEEXT" reload_flag="$reload_flag" \
2073deplibs_check_method="$deplibs_check_method" file_magic_cmd="$file_magic_cmd" \
252b5132 2074${CONFIG_SHELL-/bin/sh} $ac_aux_dir/ltconfig --no-reexec \
ac48eca1 2075$libtool_flags --no-verify --build="$build" $ac_aux_dir/ltmain.sh $host \
252b5132
RH
2076|| { echo "configure: error: libtool configure failed" 1>&2; exit 1; }
2077
2078# Reload cache, that may have been modified by ltconfig
2079if test -r "$cache_file"; then
2080 echo "loading cache $cache_file"
2081 . $cache_file
2082else
2083 echo "creating cache $cache_file"
2084 > $cache_file
2085fi
2086
2087
2088# This can be used to rebuild libtool when needed
ac48eca1 2089LIBTOOL_DEPS="$ac_aux_dir/ltconfig $ac_aux_dir/ltmain.sh $ac_aux_dir/ltcf-c.sh"
252b5132
RH
2090
2091# Always use our own libtool.
2092LIBTOOL='$(SHELL) $(top_builddir)/libtool'
2093
2094# Redirect the config.log output again, so that the ltconfig log is not
2095# clobbered by the next message.
2096exec 5>>./config.log
2097
2098
ac48eca1
AO
2099
2100
2101
2102
d64552c5 2103
ac48eca1 2104
252b5132
RH
2105# Check whether --enable-targets or --disable-targets was given.
2106if test "${enable_targets+set}" = set; then
2107 enableval="$enable_targets"
2108 case "${enableval}" in
2109 yes | "") { echo "configure: error: enable-targets option must specify target names or 'all'" 1>&2; exit 1; }
2110 ;;
2111 no) enable_targets= ;;
2112 *) enable_targets=$enableval ;;
2113esac
2114fi
2115# Check whether --enable-commonbfdlib or --disable-commonbfdlib was given.
2116if test "${enable_commonbfdlib+set}" = set; then
2117 enableval="$enable_commonbfdlib"
2118 case "${enableval}" in
2119 yes) commonbfdlib=true ;;
2120 no) commonbfdlib=false ;;
2121 *) { echo "configure: error: bad value ${enableval} for BFD commonbfdlib option" 1>&2; exit 1; } ;;
2122esac
2123fi
2124
a2d91340
AC
2125build_warnings="-W -Wall"
2126# Check whether --enable-build-warnings or --disable-build-warnings was given.
2127if test "${enable_build_warnings+set}" = set; then
2128 enableval="$enable_build_warnings"
2129 case "${enableval}" in
2130 yes) ;;
2131 no) build_warnings="-w";;
2132 ,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
2133 build_warnings="${build_warnings} ${t}";;
2134 *,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
2135 build_warnings="${t} ${build_warnings}";;
2136 *) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
2137esac
2138if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
2139 echo "Setting warning flags = $build_warnings" 6>&1
2140fi
2141fi
2142WARN_CFLAGS=""
2143if test "x${build_warnings}" != x -a "x$GCC" = xyes ; then
2144 WARN_CFLAGS="${build_warnings}"
2145fi
2146
2147
252b5132
RH
2148
2149
2150
2151
2152if test -z "$target" ; then
2153 { echo "configure: error: Unrecognized target system type; please check config.sub." 1>&2; exit 1; }
2154fi
2155if test -z "$host" ; then
2156 { echo "configure: error: Unrecognized host system type; please check config.sub." 1>&2; exit 1; }
2157fi
2158
2159# Extract the first word of "gcc", so it can be a program name with args.
2160set dummy gcc; ac_word=$2
2161echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
d64552c5 2162echo "configure:2163: checking for $ac_word" >&5
252b5132
RH
2163if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
2164 echo $ac_n "(cached) $ac_c" 1>&6
2165else
2166 if test -n "$CC"; then
2167 ac_cv_prog_CC="$CC" # Let the user override the test.
2168else
2169 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2170 ac_dummy="$PATH"
2171 for ac_dir in $ac_dummy; do
2172 test -z "$ac_dir" && ac_dir=.
2173 if test -f $ac_dir/$ac_word; then
2174 ac_cv_prog_CC="gcc"
2175 break
2176 fi
2177 done
2178 IFS="$ac_save_ifs"
2179fi
2180fi
2181CC="$ac_cv_prog_CC"
2182if test -n "$CC"; then
2183 echo "$ac_t""$CC" 1>&6
2184else
2185 echo "$ac_t""no" 1>&6
2186fi
2187
2188if test -z "$CC"; then
2189 # Extract the first word of "cc", so it can be a program name with args.
2190set dummy cc; ac_word=$2
2191echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
d64552c5 2192echo "configure:2193: checking for $ac_word" >&5
252b5132
RH
2193if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
2194 echo $ac_n "(cached) $ac_c" 1>&6
2195else
2196 if test -n "$CC"; then
2197 ac_cv_prog_CC="$CC" # Let the user override the test.
2198else
2199 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2200 ac_prog_rejected=no
2201 ac_dummy="$PATH"
2202 for ac_dir in $ac_dummy; do
2203 test -z "$ac_dir" && ac_dir=.
2204 if test -f $ac_dir/$ac_word; then
2205 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
2206 ac_prog_rejected=yes
2207 continue
2208 fi
2209 ac_cv_prog_CC="cc"
2210 break
2211 fi
2212 done
2213 IFS="$ac_save_ifs"
2214if test $ac_prog_rejected = yes; then
2215 # We found a bogon in the path, so make sure we never use it.
2216 set dummy $ac_cv_prog_CC
2217 shift
2218 if test $# -gt 0; then
2219 # We chose a different compiler from the bogus one.
2220 # However, it has the same basename, so the bogon will be chosen
2221 # first if we set CC to just the basename; use the full file name.
2222 shift
2223 set dummy "$ac_dir/$ac_word" "$@"
2224 shift
2225 ac_cv_prog_CC="$@"
2226 fi
2227fi
2228fi
2229fi
2230CC="$ac_cv_prog_CC"
2231if test -n "$CC"; then
2232 echo "$ac_t""$CC" 1>&6
2233else
2234 echo "$ac_t""no" 1>&6
2235fi
2236
2237 if test -z "$CC"; then
2238 case "`uname -s`" in
2239 *win32* | *WIN32*)
2240 # Extract the first word of "cl", so it can be a program name with args.
2241set dummy cl; ac_word=$2
2242echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
d64552c5 2243echo "configure:2244: checking for $ac_word" >&5
252b5132
RH
2244if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
2245 echo $ac_n "(cached) $ac_c" 1>&6
2246else
2247 if test -n "$CC"; then
2248 ac_cv_prog_CC="$CC" # Let the user override the test.
2249else
2250 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2251 ac_dummy="$PATH"
2252 for ac_dir in $ac_dummy; do
2253 test -z "$ac_dir" && ac_dir=.
2254 if test -f $ac_dir/$ac_word; then
2255 ac_cv_prog_CC="cl"
2256 break
2257 fi
2258 done
2259 IFS="$ac_save_ifs"
2260fi
2261fi
2262CC="$ac_cv_prog_CC"
2263if test -n "$CC"; then
2264 echo "$ac_t""$CC" 1>&6
2265else
2266 echo "$ac_t""no" 1>&6
2267fi
2268 ;;
2269 esac
2270 fi
2271 test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
2272fi
2273
2274echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
d64552c5 2275echo "configure:2276: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
252b5132
RH
2276
2277ac_ext=c
2278# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
2279ac_cpp='$CPP $CPPFLAGS'
2280ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
2281ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
2282cross_compiling=$ac_cv_prog_cc_cross
2283
2284cat > conftest.$ac_ext << EOF
2285
d64552c5 2286#line 2287 "configure"
252b5132
RH
2287#include "confdefs.h"
2288
2289main(){return(0);}
2290EOF
d64552c5 2291if { (eval echo configure:2292: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
2292 ac_cv_prog_cc_works=yes
2293 # If we can't run a trivial program, we are probably using a cross compiler.
2294 if (./conftest; exit) 2>/dev/null; then
2295 ac_cv_prog_cc_cross=no
2296 else
2297 ac_cv_prog_cc_cross=yes
2298 fi
2299else
2300 echo "configure: failed program was:" >&5
2301 cat conftest.$ac_ext >&5
2302 ac_cv_prog_cc_works=no
2303fi
2304rm -fr conftest*
2305ac_ext=c
2306# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
2307ac_cpp='$CPP $CPPFLAGS'
2308ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
2309ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
2310cross_compiling=$ac_cv_prog_cc_cross
2311
2312echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
2313if test $ac_cv_prog_cc_works = no; then
2314 { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
2315fi
2316echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
d64552c5 2317echo "configure:2318: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
252b5132
RH
2318echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
2319cross_compiling=$ac_cv_prog_cc_cross
2320
2321echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
d64552c5 2322echo "configure:2323: checking whether we are using GNU C" >&5
252b5132
RH
2323if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
2324 echo $ac_n "(cached) $ac_c" 1>&6
2325else
2326 cat > conftest.c <<EOF
2327#ifdef __GNUC__
2328 yes;
2329#endif
2330EOF
d64552c5 2331if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:2332: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
252b5132
RH
2332 ac_cv_prog_gcc=yes
2333else
2334 ac_cv_prog_gcc=no
2335fi
2336fi
2337
2338echo "$ac_t""$ac_cv_prog_gcc" 1>&6
2339
2340if test $ac_cv_prog_gcc = yes; then
2341 GCC=yes
2342else
2343 GCC=
2344fi
2345
2346ac_test_CFLAGS="${CFLAGS+set}"
2347ac_save_CFLAGS="$CFLAGS"
2348CFLAGS=
2349echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
d64552c5 2350echo "configure:2351: checking whether ${CC-cc} accepts -g" >&5
252b5132
RH
2351if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
2352 echo $ac_n "(cached) $ac_c" 1>&6
2353else
2354 echo 'void f(){}' > conftest.c
2355if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
2356 ac_cv_prog_cc_g=yes
2357else
2358 ac_cv_prog_cc_g=no
2359fi
2360rm -f conftest*
2361
2362fi
2363
2364echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
2365if test "$ac_test_CFLAGS" = set; then
2366 CFLAGS="$ac_save_CFLAGS"
2367elif test $ac_cv_prog_cc_g = yes; then
2368 if test "$GCC" = yes; then
2369 CFLAGS="-g -O2"
2370 else
2371 CFLAGS="-g"
2372 fi
2373else
2374 if test "$GCC" = yes; then
2375 CFLAGS="-O2"
2376 else
2377 CFLAGS=
2378 fi
2379fi
2380
2381
2382for ac_prog in 'bison -y' byacc
2383do
2384# Extract the first word of "$ac_prog", so it can be a program name with args.
2385set dummy $ac_prog; ac_word=$2
2386echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
d64552c5 2387echo "configure:2388: checking for $ac_word" >&5
252b5132
RH
2388if eval "test \"`echo '$''{'ac_cv_prog_YACC'+set}'`\" = set"; then
2389 echo $ac_n "(cached) $ac_c" 1>&6
2390else
2391 if test -n "$YACC"; then
2392 ac_cv_prog_YACC="$YACC" # Let the user override the test.
2393else
2394 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2395 ac_dummy="$PATH"
2396 for ac_dir in $ac_dummy; do
2397 test -z "$ac_dir" && ac_dir=.
2398 if test -f $ac_dir/$ac_word; then
2399 ac_cv_prog_YACC="$ac_prog"
2400 break
2401 fi
2402 done
2403 IFS="$ac_save_ifs"
2404fi
2405fi
2406YACC="$ac_cv_prog_YACC"
2407if test -n "$YACC"; then
2408 echo "$ac_t""$YACC" 1>&6
2409else
2410 echo "$ac_t""no" 1>&6
2411fi
2412
2413test -n "$YACC" && break
2414done
2415test -n "$YACC" || YACC="yacc"
2416
2417echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
d64552c5 2418echo "configure:2419: checking how to run the C preprocessor" >&5
252b5132
RH
2419# On Suns, sometimes $CPP names a directory.
2420if test -n "$CPP" && test -d "$CPP"; then
2421 CPP=
2422fi
2423if test -z "$CPP"; then
2424if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
2425 echo $ac_n "(cached) $ac_c" 1>&6
2426else
2427 # This must be in double quotes, not single quotes, because CPP may get
2428 # substituted into the Makefile and "${CC-cc}" will confuse make.
2429 CPP="${CC-cc} -E"
2430 # On the NeXT, cc -E runs the code through the compiler's parser,
2431 # not just through cpp.
2432 cat > conftest.$ac_ext <<EOF
d64552c5 2433#line 2434 "configure"
252b5132
RH
2434#include "confdefs.h"
2435#include <assert.h>
2436Syntax Error
2437EOF
2438ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
d64552c5 2439{ (eval echo configure:2440: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
252b5132
RH
2440ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2441if test -z "$ac_err"; then
2442 :
2443else
2444 echo "$ac_err" >&5
2445 echo "configure: failed program was:" >&5
2446 cat conftest.$ac_ext >&5
2447 rm -rf conftest*
2448 CPP="${CC-cc} -E -traditional-cpp"
2449 cat > conftest.$ac_ext <<EOF
d64552c5 2450#line 2451 "configure"
252b5132
RH
2451#include "confdefs.h"
2452#include <assert.h>
2453Syntax Error
2454EOF
2455ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
d64552c5 2456{ (eval echo configure:2457: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
252b5132
RH
2457ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2458if test -z "$ac_err"; then
2459 :
2460else
2461 echo "$ac_err" >&5
2462 echo "configure: failed program was:" >&5
2463 cat conftest.$ac_ext >&5
2464 rm -rf conftest*
2465 CPP="${CC-cc} -nologo -E"
2466 cat > conftest.$ac_ext <<EOF
d64552c5 2467#line 2468 "configure"
252b5132
RH
2468#include "confdefs.h"
2469#include <assert.h>
2470Syntax Error
2471EOF
2472ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
d64552c5 2473{ (eval echo configure:2474: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
252b5132
RH
2474ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2475if test -z "$ac_err"; then
2476 :
2477else
2478 echo "$ac_err" >&5
2479 echo "configure: failed program was:" >&5
2480 cat conftest.$ac_ext >&5
2481 rm -rf conftest*
2482 CPP=/lib/cpp
2483fi
2484rm -f conftest*
2485fi
2486rm -f conftest*
2487fi
2488rm -f conftest*
2489 ac_cv_prog_CPP="$CPP"
2490fi
2491 CPP="$ac_cv_prog_CPP"
2492else
2493 ac_cv_prog_CPP="$CPP"
2494fi
2495echo "$ac_t""$CPP" 1>&6
2496
2497missing_dir=`cd $ac_aux_dir && pwd`
2498for ac_prog in flex lex
2499do
2500# Extract the first word of "$ac_prog", so it can be a program name with args.
2501set dummy $ac_prog; ac_word=$2
2502echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
d64552c5 2503echo "configure:2504: checking for $ac_word" >&5
252b5132
RH
2504if eval "test \"`echo '$''{'ac_cv_prog_LEX'+set}'`\" = set"; then
2505 echo $ac_n "(cached) $ac_c" 1>&6
2506else
2507 if test -n "$LEX"; then
2508 ac_cv_prog_LEX="$LEX" # Let the user override the test.
2509else
2510 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2511 ac_dummy="$PATH"
2512 for ac_dir in $ac_dummy; do
2513 test -z "$ac_dir" && ac_dir=.
2514 if test -f $ac_dir/$ac_word; then
2515 ac_cv_prog_LEX="$ac_prog"
2516 break
2517 fi
2518 done
2519 IFS="$ac_save_ifs"
2520fi
2521fi
2522LEX="$ac_cv_prog_LEX"
2523if test -n "$LEX"; then
2524 echo "$ac_t""$LEX" 1>&6
2525else
2526 echo "$ac_t""no" 1>&6
2527fi
2528
2529test -n "$LEX" && break
2530done
2531test -n "$LEX" || LEX=""$missing_dir/missing flex""
2532
2533# Extract the first word of "flex", so it can be a program name with args.
2534set dummy flex; ac_word=$2
2535echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
d64552c5 2536echo "configure:2537: checking for $ac_word" >&5
252b5132
RH
2537if eval "test \"`echo '$''{'ac_cv_prog_LEX'+set}'`\" = set"; then
2538 echo $ac_n "(cached) $ac_c" 1>&6
2539else
2540 if test -n "$LEX"; then
2541 ac_cv_prog_LEX="$LEX" # Let the user override the test.
2542else
2543 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2544 ac_dummy="$PATH"
2545 for ac_dir in $ac_dummy; do
2546 test -z "$ac_dir" && ac_dir=.
2547 if test -f $ac_dir/$ac_word; then
2548 ac_cv_prog_LEX="flex"
2549 break
2550 fi
2551 done
2552 IFS="$ac_save_ifs"
2553 test -z "$ac_cv_prog_LEX" && ac_cv_prog_LEX="lex"
2554fi
2555fi
2556LEX="$ac_cv_prog_LEX"
2557if test -n "$LEX"; then
2558 echo "$ac_t""$LEX" 1>&6
2559else
2560 echo "$ac_t""no" 1>&6
2561fi
2562
2563if test -z "$LEXLIB"
2564then
2565 case "$LEX" in
2566 flex*) ac_lib=fl ;;
2567 *) ac_lib=l ;;
2568 esac
2569 echo $ac_n "checking for yywrap in -l$ac_lib""... $ac_c" 1>&6
d64552c5 2570echo "configure:2571: checking for yywrap in -l$ac_lib" >&5
252b5132
RH
2571ac_lib_var=`echo $ac_lib'_'yywrap | sed 'y%./+-%__p_%'`
2572if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2573 echo $ac_n "(cached) $ac_c" 1>&6
2574else
2575 ac_save_LIBS="$LIBS"
2576LIBS="-l$ac_lib $LIBS"
2577cat > conftest.$ac_ext <<EOF
d64552c5 2578#line 2579 "configure"
252b5132
RH
2579#include "confdefs.h"
2580/* Override any gcc2 internal prototype to avoid an error. */
2581/* We use char because int might match the return type of a gcc2
2582 builtin and then its argument prototype would still apply. */
2583char yywrap();
2584
2585int main() {
2586yywrap()
2587; return 0; }
2588EOF
d64552c5 2589if { (eval echo configure:2590: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
2590 rm -rf conftest*
2591 eval "ac_cv_lib_$ac_lib_var=yes"
2592else
2593 echo "configure: failed program was:" >&5
2594 cat conftest.$ac_ext >&5
2595 rm -rf conftest*
2596 eval "ac_cv_lib_$ac_lib_var=no"
2597fi
2598rm -f conftest*
2599LIBS="$ac_save_LIBS"
2600
2601fi
2602if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2603 echo "$ac_t""yes" 1>&6
2604 LEXLIB="-l$ac_lib"
2605else
2606 echo "$ac_t""no" 1>&6
2607fi
2608
2609fi
2610
2611echo $ac_n "checking lex output file root""... $ac_c" 1>&6
d64552c5 2612echo "configure:2613: checking lex output file root" >&5
252b5132
RH
2613if eval "test \"`echo '$''{'ac_cv_prog_lex_root'+set}'`\" = set"; then
2614 echo $ac_n "(cached) $ac_c" 1>&6
2615else
2616 # The minimal lex program is just a single line: %%. But some broken lexes
2617# (Solaris, I think it was) want two %% lines, so accommodate them.
2618echo '%%
2619%%' | $LEX
2620if test -f lex.yy.c; then
2621 ac_cv_prog_lex_root=lex.yy
2622elif test -f lexyy.c; then
2623 ac_cv_prog_lex_root=lexyy
2624else
2625 { echo "configure: error: cannot find output from $LEX; giving up" 1>&2; exit 1; }
2626fi
2627fi
2628
2629echo "$ac_t""$ac_cv_prog_lex_root" 1>&6
2630LEX_OUTPUT_ROOT=$ac_cv_prog_lex_root
2631
2632echo $ac_n "checking whether yytext is a pointer""... $ac_c" 1>&6
d64552c5 2633echo "configure:2634: checking whether yytext is a pointer" >&5
252b5132
RH
2634if eval "test \"`echo '$''{'ac_cv_prog_lex_yytext_pointer'+set}'`\" = set"; then
2635 echo $ac_n "(cached) $ac_c" 1>&6
2636else
2637 # POSIX says lex can declare yytext either as a pointer or an array; the
2638# default is implementation-dependent. Figure out which it is, since
2639# not all implementations provide the %pointer and %array declarations.
2640ac_cv_prog_lex_yytext_pointer=no
2641echo 'extern char *yytext;' >>$LEX_OUTPUT_ROOT.c
2642ac_save_LIBS="$LIBS"
2643LIBS="$LIBS $LEXLIB"
2644cat > conftest.$ac_ext <<EOF
d64552c5 2645#line 2646 "configure"
252b5132
RH
2646#include "confdefs.h"
2647`cat $LEX_OUTPUT_ROOT.c`
2648int main() {
2649
2650; return 0; }
2651EOF
d64552c5 2652if { (eval echo configure:2653: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
2653 rm -rf conftest*
2654 ac_cv_prog_lex_yytext_pointer=yes
2655else
2656 echo "configure: failed program was:" >&5
2657 cat conftest.$ac_ext >&5
2658fi
2659rm -f conftest*
2660LIBS="$ac_save_LIBS"
2661rm -f "${LEX_OUTPUT_ROOT}.c"
2662
2663fi
2664
2665echo "$ac_t""$ac_cv_prog_lex_yytext_pointer" 1>&6
2666if test $ac_cv_prog_lex_yytext_pointer = yes; then
2667 cat >> confdefs.h <<\EOF
2668#define YYTEXT_POINTER 1
2669EOF
2670
2671fi
2672
2673
2674ALL_LINGUAS=
ac48eca1
AO
2675# Extract the first word of "ranlib", so it can be a program name with args.
2676set dummy ranlib; ac_word=$2
2677echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
d64552c5 2678echo "configure:2679: checking for $ac_word" >&5
ac48eca1
AO
2679if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
2680 echo $ac_n "(cached) $ac_c" 1>&6
2681else
2682 if test -n "$RANLIB"; then
2683 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
2684else
2685 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2686 ac_dummy="$PATH"
2687 for ac_dir in $ac_dummy; do
2688 test -z "$ac_dir" && ac_dir=.
2689 if test -f $ac_dir/$ac_word; then
2690 ac_cv_prog_RANLIB="ranlib"
2691 break
2692 fi
2693 done
2694 IFS="$ac_save_ifs"
2695 test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
2696fi
2697fi
2698RANLIB="$ac_cv_prog_RANLIB"
2699if test -n "$RANLIB"; then
2700 echo "$ac_t""$RANLIB" 1>&6
2701else
2702 echo "$ac_t""no" 1>&6
2703fi
2704
252b5132 2705echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
d64552c5 2706echo "configure:2707: checking for ANSI C header files" >&5
252b5132
RH
2707if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
2708 echo $ac_n "(cached) $ac_c" 1>&6
2709else
2710 cat > conftest.$ac_ext <<EOF
d64552c5 2711#line 2712 "configure"
252b5132
RH
2712#include "confdefs.h"
2713#include <stdlib.h>
2714#include <stdarg.h>
2715#include <string.h>
2716#include <float.h>
2717EOF
2718ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
d64552c5 2719{ (eval echo configure:2720: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
252b5132
RH
2720ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2721if test -z "$ac_err"; then
2722 rm -rf conftest*
2723 ac_cv_header_stdc=yes
2724else
2725 echo "$ac_err" >&5
2726 echo "configure: failed program was:" >&5
2727 cat conftest.$ac_ext >&5
2728 rm -rf conftest*
2729 ac_cv_header_stdc=no
2730fi
2731rm -f conftest*
2732
2733if test $ac_cv_header_stdc = yes; then
2734 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
2735cat > conftest.$ac_ext <<EOF
d64552c5 2736#line 2737 "configure"
252b5132
RH
2737#include "confdefs.h"
2738#include <string.h>
2739EOF
2740if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2741 egrep "memchr" >/dev/null 2>&1; then
2742 :
2743else
2744 rm -rf conftest*
2745 ac_cv_header_stdc=no
2746fi
2747rm -f conftest*
2748
2749fi
2750
2751if test $ac_cv_header_stdc = yes; then
2752 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
2753cat > conftest.$ac_ext <<EOF
d64552c5 2754#line 2755 "configure"
252b5132
RH
2755#include "confdefs.h"
2756#include <stdlib.h>
2757EOF
2758if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2759 egrep "free" >/dev/null 2>&1; then
2760 :
2761else
2762 rm -rf conftest*
2763 ac_cv_header_stdc=no
2764fi
2765rm -f conftest*
2766
2767fi
2768
2769if test $ac_cv_header_stdc = yes; then
2770 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
2771if test "$cross_compiling" = yes; then
2772 :
2773else
2774 cat > conftest.$ac_ext <<EOF
d64552c5 2775#line 2776 "configure"
252b5132
RH
2776#include "confdefs.h"
2777#include <ctype.h>
2778#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
2779#define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
2780#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
2781int main () { int i; for (i = 0; i < 256; i++)
2782if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
2783exit (0); }
2784
2785EOF
d64552c5 2786if { (eval echo configure:2787: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
252b5132
RH
2787then
2788 :
2789else
2790 echo "configure: failed program was:" >&5
2791 cat conftest.$ac_ext >&5
2792 rm -fr conftest*
2793 ac_cv_header_stdc=no
2794fi
2795rm -fr conftest*
2796fi
2797
2798fi
2799fi
2800
2801echo "$ac_t""$ac_cv_header_stdc" 1>&6
2802if test $ac_cv_header_stdc = yes; then
2803 cat >> confdefs.h <<\EOF
2804#define STDC_HEADERS 1
2805EOF
2806
2807fi
2808
2809echo $ac_n "checking for working const""... $ac_c" 1>&6
d64552c5 2810echo "configure:2811: checking for working const" >&5
252b5132
RH
2811if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
2812 echo $ac_n "(cached) $ac_c" 1>&6
2813else
2814 cat > conftest.$ac_ext <<EOF
d64552c5 2815#line 2816 "configure"
252b5132
RH
2816#include "confdefs.h"
2817
2818int main() {
2819
2820/* Ultrix mips cc rejects this. */
2821typedef int charset[2]; const charset x;
2822/* SunOS 4.1.1 cc rejects this. */
2823char const *const *ccp;
2824char **p;
2825/* NEC SVR4.0.2 mips cc rejects this. */
2826struct point {int x, y;};
2827static struct point const zero = {0,0};
2828/* AIX XL C 1.02.0.0 rejects this.
2829 It does not let you subtract one const X* pointer from another in an arm
2830 of an if-expression whose if-part is not a constant expression */
2831const char *g = "string";
2832ccp = &g + (g ? g-g : 0);
2833/* HPUX 7.0 cc rejects these. */
2834++ccp;
2835p = (char**) ccp;
2836ccp = (char const *const *) p;
2837{ /* SCO 3.2v4 cc rejects this. */
2838 char *t;
2839 char const *s = 0 ? (char *) 0 : (char const *) 0;
2840
2841 *t++ = 0;
2842}
2843{ /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
2844 int x[] = {25, 17};
2845 const int *foo = &x[0];
2846 ++foo;
2847}
2848{ /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
2849 typedef const int *iptr;
2850 iptr p = 0;
2851 ++p;
2852}
2853{ /* AIX XL C 1.02.0.0 rejects this saying
2854 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
2855 struct s { int j; const int *ap[3]; };
2856 struct s *b; b->j = 5;
2857}
2858{ /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
2859 const int foo = 10;
2860}
2861
2862; return 0; }
2863EOF
d64552c5 2864if { (eval echo configure:2865: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
252b5132
RH
2865 rm -rf conftest*
2866 ac_cv_c_const=yes
2867else
2868 echo "configure: failed program was:" >&5
2869 cat conftest.$ac_ext >&5
2870 rm -rf conftest*
2871 ac_cv_c_const=no
2872fi
2873rm -f conftest*
2874fi
2875
2876echo "$ac_t""$ac_cv_c_const" 1>&6
2877if test $ac_cv_c_const = no; then
2878 cat >> confdefs.h <<\EOF
2879#define const
2880EOF
2881
2882fi
2883
2884echo $ac_n "checking for inline""... $ac_c" 1>&6
d64552c5 2885echo "configure:2886: checking for inline" >&5
252b5132
RH
2886if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
2887 echo $ac_n "(cached) $ac_c" 1>&6
2888else
2889 ac_cv_c_inline=no
2890for ac_kw in inline __inline__ __inline; do
2891 cat > conftest.$ac_ext <<EOF
d64552c5 2892#line 2893 "configure"
252b5132
RH
2893#include "confdefs.h"
2894
2895int main() {
2896} $ac_kw foo() {
2897; return 0; }
2898EOF
d64552c5 2899if { (eval echo configure:2900: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
252b5132
RH
2900 rm -rf conftest*
2901 ac_cv_c_inline=$ac_kw; break
2902else
2903 echo "configure: failed program was:" >&5
2904 cat conftest.$ac_ext >&5
2905fi
2906rm -f conftest*
2907done
2908
2909fi
2910
2911echo "$ac_t""$ac_cv_c_inline" 1>&6
2912case "$ac_cv_c_inline" in
2913 inline | yes) ;;
2914 no) cat >> confdefs.h <<\EOF
2915#define inline
2916EOF
2917 ;;
2918 *) cat >> confdefs.h <<EOF
2919#define inline $ac_cv_c_inline
2920EOF
2921 ;;
2922esac
2923
2924echo $ac_n "checking for off_t""... $ac_c" 1>&6
d64552c5 2925echo "configure:2926: checking for off_t" >&5
252b5132
RH
2926if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then
2927 echo $ac_n "(cached) $ac_c" 1>&6
2928else
2929 cat > conftest.$ac_ext <<EOF
d64552c5 2930#line 2931 "configure"
252b5132
RH
2931#include "confdefs.h"
2932#include <sys/types.h>
2933#if STDC_HEADERS
2934#include <stdlib.h>
2935#include <stddef.h>
2936#endif
2937EOF
2938if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2939 egrep "(^|[^a-zA-Z_0-9])off_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
2940 rm -rf conftest*
2941 ac_cv_type_off_t=yes
2942else
2943 rm -rf conftest*
2944 ac_cv_type_off_t=no
2945fi
2946rm -f conftest*
2947
2948fi
2949echo "$ac_t""$ac_cv_type_off_t" 1>&6
2950if test $ac_cv_type_off_t = no; then
2951 cat >> confdefs.h <<\EOF
2952#define off_t long
2953EOF
2954
2955fi
2956
2957echo $ac_n "checking for size_t""... $ac_c" 1>&6
d64552c5 2958echo "configure:2959: checking for size_t" >&5
252b5132
RH
2959if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
2960 echo $ac_n "(cached) $ac_c" 1>&6
2961else
2962 cat > conftest.$ac_ext <<EOF
d64552c5 2963#line 2964 "configure"
252b5132
RH
2964#include "confdefs.h"
2965#include <sys/types.h>
2966#if STDC_HEADERS
2967#include <stdlib.h>
2968#include <stddef.h>
2969#endif
2970EOF
2971if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2972 egrep "(^|[^a-zA-Z_0-9])size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
2973 rm -rf conftest*
2974 ac_cv_type_size_t=yes
2975else
2976 rm -rf conftest*
2977 ac_cv_type_size_t=no
2978fi
2979rm -f conftest*
2980
2981fi
2982echo "$ac_t""$ac_cv_type_size_t" 1>&6
2983if test $ac_cv_type_size_t = no; then
2984 cat >> confdefs.h <<\EOF
2985#define size_t unsigned
2986EOF
2987
2988fi
2989
2990# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
2991# for constant arguments. Useless!
2992echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
d64552c5 2993echo "configure:2994: checking for working alloca.h" >&5
252b5132
RH
2994if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
2995 echo $ac_n "(cached) $ac_c" 1>&6
2996else
2997 cat > conftest.$ac_ext <<EOF
d64552c5 2998#line 2999 "configure"
252b5132
RH
2999#include "confdefs.h"
3000#include <alloca.h>
3001int main() {
3002char *p = alloca(2 * sizeof(int));
3003; return 0; }
3004EOF
d64552c5 3005if { (eval echo configure:3006: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
3006 rm -rf conftest*
3007 ac_cv_header_alloca_h=yes
3008else
3009 echo "configure: failed program was:" >&5
3010 cat conftest.$ac_ext >&5
3011 rm -rf conftest*
3012 ac_cv_header_alloca_h=no
3013fi
3014rm -f conftest*
3015fi
3016
3017echo "$ac_t""$ac_cv_header_alloca_h" 1>&6
3018if test $ac_cv_header_alloca_h = yes; then
3019 cat >> confdefs.h <<\EOF
3020#define HAVE_ALLOCA_H 1
3021EOF
3022
3023fi
3024
3025echo $ac_n "checking for alloca""... $ac_c" 1>&6
d64552c5 3026echo "configure:3027: checking for alloca" >&5
252b5132
RH
3027if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
3028 echo $ac_n "(cached) $ac_c" 1>&6
3029else
3030 cat > conftest.$ac_ext <<EOF
d64552c5 3031#line 3032 "configure"
252b5132
RH
3032#include "confdefs.h"
3033
3034#ifdef __GNUC__
3035# define alloca __builtin_alloca
3036#else
3037# ifdef _MSC_VER
3038# include <malloc.h>
3039# define alloca _alloca
3040# else
3041# if HAVE_ALLOCA_H
3042# include <alloca.h>
3043# else
3044# ifdef _AIX
3045 #pragma alloca
3046# else
3047# ifndef alloca /* predefined by HP cc +Olibcalls */
3048char *alloca ();
3049# endif
3050# endif
3051# endif
3052# endif
3053#endif
3054
3055int main() {
3056char *p = (char *) alloca(1);
3057; return 0; }
3058EOF
d64552c5 3059if { (eval echo configure:3060: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
3060 rm -rf conftest*
3061 ac_cv_func_alloca_works=yes
3062else
3063 echo "configure: failed program was:" >&5
3064 cat conftest.$ac_ext >&5
3065 rm -rf conftest*
3066 ac_cv_func_alloca_works=no
3067fi
3068rm -f conftest*
3069fi
3070
3071echo "$ac_t""$ac_cv_func_alloca_works" 1>&6
3072if test $ac_cv_func_alloca_works = yes; then
3073 cat >> confdefs.h <<\EOF
3074#define HAVE_ALLOCA 1
3075EOF
3076
3077fi
3078
3079if test $ac_cv_func_alloca_works = no; then
3080 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
3081 # that cause trouble. Some versions do not even contain alloca or
3082 # contain a buggy version. If you still want to use their alloca,
3083 # use ar to extract alloca.o from them instead of compiling alloca.c.
3084 ALLOCA=alloca.${ac_objext}
3085 cat >> confdefs.h <<\EOF
3086#define C_ALLOCA 1
3087EOF
3088
3089
3090echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
d64552c5 3091echo "configure:3092: checking whether alloca needs Cray hooks" >&5
252b5132
RH
3092if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
3093 echo $ac_n "(cached) $ac_c" 1>&6
3094else
3095 cat > conftest.$ac_ext <<EOF
d64552c5 3096#line 3097 "configure"
252b5132
RH
3097#include "confdefs.h"
3098#if defined(CRAY) && ! defined(CRAY2)
3099webecray
3100#else
3101wenotbecray
3102#endif
3103
3104EOF
3105if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3106 egrep "webecray" >/dev/null 2>&1; then
3107 rm -rf conftest*
3108 ac_cv_os_cray=yes
3109else
3110 rm -rf conftest*
3111 ac_cv_os_cray=no
3112fi
3113rm -f conftest*
3114
3115fi
3116
3117echo "$ac_t""$ac_cv_os_cray" 1>&6
3118if test $ac_cv_os_cray = yes; then
3119for ac_func in _getb67 GETB67 getb67; do
3120 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
d64552c5 3121echo "configure:3122: checking for $ac_func" >&5
252b5132
RH
3122if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3123 echo $ac_n "(cached) $ac_c" 1>&6
3124else
3125 cat > conftest.$ac_ext <<EOF
d64552c5 3126#line 3127 "configure"
252b5132
RH
3127#include "confdefs.h"
3128/* System header to define __stub macros and hopefully few prototypes,
3129 which can conflict with char $ac_func(); below. */
3130#include <assert.h>
3131/* Override any gcc2 internal prototype to avoid an error. */
3132/* We use char because int might match the return type of a gcc2
3133 builtin and then its argument prototype would still apply. */
3134char $ac_func();
3135
3136int main() {
3137
3138/* The GNU C library defines this for functions which it implements
3139 to always fail with ENOSYS. Some functions are actually named
3140 something starting with __ and the normal name is an alias. */
3141#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3142choke me
3143#else
3144$ac_func();
3145#endif
3146
3147; return 0; }
3148EOF
d64552c5 3149if { (eval echo configure:3150: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
3150 rm -rf conftest*
3151 eval "ac_cv_func_$ac_func=yes"
3152else
3153 echo "configure: failed program was:" >&5
3154 cat conftest.$ac_ext >&5
3155 rm -rf conftest*
3156 eval "ac_cv_func_$ac_func=no"
3157fi
3158rm -f conftest*
3159fi
3160
3161if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3162 echo "$ac_t""yes" 1>&6
3163 cat >> confdefs.h <<EOF
3164#define CRAY_STACKSEG_END $ac_func
3165EOF
3166
3167 break
3168else
3169 echo "$ac_t""no" 1>&6
3170fi
3171
3172done
3173fi
3174
3175echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
d64552c5 3176echo "configure:3177: checking stack direction for C alloca" >&5
252b5132
RH
3177if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
3178 echo $ac_n "(cached) $ac_c" 1>&6
3179else
3180 if test "$cross_compiling" = yes; then
3181 ac_cv_c_stack_direction=0
3182else
3183 cat > conftest.$ac_ext <<EOF
d64552c5 3184#line 3185 "configure"
252b5132
RH
3185#include "confdefs.h"
3186find_stack_direction ()
3187{
3188 static char *addr = 0;
3189 auto char dummy;
3190 if (addr == 0)
3191 {
3192 addr = &dummy;
3193 return find_stack_direction ();
3194 }
3195 else
3196 return (&dummy > addr) ? 1 : -1;
3197}
3198main ()
3199{
3200 exit (find_stack_direction() < 0);
3201}
3202EOF
d64552c5 3203if { (eval echo configure:3204: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
252b5132
RH
3204then
3205 ac_cv_c_stack_direction=1
3206else
3207 echo "configure: failed program was:" >&5
3208 cat conftest.$ac_ext >&5
3209 rm -fr conftest*
3210 ac_cv_c_stack_direction=-1
3211fi
3212rm -fr conftest*
3213fi
3214
3215fi
3216
3217echo "$ac_t""$ac_cv_c_stack_direction" 1>&6
3218cat >> confdefs.h <<EOF
3219#define STACK_DIRECTION $ac_cv_c_stack_direction
3220EOF
3221
3222fi
3223
3224for ac_hdr in unistd.h
3225do
3226ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
3227echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
d64552c5 3228echo "configure:3229: checking for $ac_hdr" >&5
252b5132
RH
3229if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3230 echo $ac_n "(cached) $ac_c" 1>&6
3231else
3232 cat > conftest.$ac_ext <<EOF
d64552c5 3233#line 3234 "configure"
252b5132
RH
3234#include "confdefs.h"
3235#include <$ac_hdr>
3236EOF
3237ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
d64552c5 3238{ (eval echo configure:3239: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
252b5132
RH
3239ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3240if test -z "$ac_err"; then
3241 rm -rf conftest*
3242 eval "ac_cv_header_$ac_safe=yes"
3243else
3244 echo "$ac_err" >&5
3245 echo "configure: failed program was:" >&5
3246 cat conftest.$ac_ext >&5
3247 rm -rf conftest*
3248 eval "ac_cv_header_$ac_safe=no"
3249fi
3250rm -f conftest*
3251fi
3252if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3253 echo "$ac_t""yes" 1>&6
3254 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
3255 cat >> confdefs.h <<EOF
3256#define $ac_tr_hdr 1
3257EOF
3258
3259else
3260 echo "$ac_t""no" 1>&6
3261fi
3262done
3263
3264for ac_func in getpagesize
3265do
3266echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
d64552c5 3267echo "configure:3268: checking for $ac_func" >&5
252b5132
RH
3268if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3269 echo $ac_n "(cached) $ac_c" 1>&6
3270else
3271 cat > conftest.$ac_ext <<EOF
d64552c5 3272#line 3273 "configure"
252b5132
RH
3273#include "confdefs.h"
3274/* System header to define __stub macros and hopefully few prototypes,
3275 which can conflict with char $ac_func(); below. */
3276#include <assert.h>
3277/* Override any gcc2 internal prototype to avoid an error. */
3278/* We use char because int might match the return type of a gcc2
3279 builtin and then its argument prototype would still apply. */
3280char $ac_func();
3281
3282int main() {
3283
3284/* The GNU C library defines this for functions which it implements
3285 to always fail with ENOSYS. Some functions are actually named
3286 something starting with __ and the normal name is an alias. */
3287#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3288choke me
3289#else
3290$ac_func();
3291#endif
3292
3293; return 0; }
3294EOF
d64552c5 3295if { (eval echo configure:3296: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
3296 rm -rf conftest*
3297 eval "ac_cv_func_$ac_func=yes"
3298else
3299 echo "configure: failed program was:" >&5
3300 cat conftest.$ac_ext >&5
3301 rm -rf conftest*
3302 eval "ac_cv_func_$ac_func=no"
3303fi
3304rm -f conftest*
3305fi
3306
3307if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3308 echo "$ac_t""yes" 1>&6
3309 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3310 cat >> confdefs.h <<EOF
3311#define $ac_tr_func 1
3312EOF
3313
3314else
3315 echo "$ac_t""no" 1>&6
3316fi
3317done
3318
3319echo $ac_n "checking for working mmap""... $ac_c" 1>&6
d64552c5 3320echo "configure:3321: checking for working mmap" >&5
252b5132
RH
3321if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
3322 echo $ac_n "(cached) $ac_c" 1>&6
3323else
3324 if test "$cross_compiling" = yes; then
3325 ac_cv_func_mmap_fixed_mapped=no
3326else
3327 cat > conftest.$ac_ext <<EOF
d64552c5 3328#line 3329 "configure"
252b5132
RH
3329#include "confdefs.h"
3330
3331/* Thanks to Mike Haertel and Jim Avera for this test.
3332 Here is a matrix of mmap possibilities:
3333 mmap private not fixed
3334 mmap private fixed at somewhere currently unmapped
3335 mmap private fixed at somewhere already mapped
3336 mmap shared not fixed
3337 mmap shared fixed at somewhere currently unmapped
3338 mmap shared fixed at somewhere already mapped
3339 For private mappings, we should verify that changes cannot be read()
3340 back from the file, nor mmap's back from the file at a different
3341 address. (There have been systems where private was not correctly
3342 implemented like the infamous i386 svr4.0, and systems where the
3343 VM page cache was not coherent with the filesystem buffer cache
3344 like early versions of FreeBSD and possibly contemporary NetBSD.)
3345 For shared mappings, we should conversely verify that changes get
3346 propogated back to all the places they're supposed to be.
3347
3348 Grep wants private fixed already mapped.
3349 The main things grep needs to know about mmap are:
3350 * does it exist and is it safe to write into the mmap'd area
3351 * how to use it (BSD variants) */
3352#include <sys/types.h>
3353#include <fcntl.h>
3354#include <sys/mman.h>
3355
3356/* This mess was copied from the GNU getpagesize.h. */
3357#ifndef HAVE_GETPAGESIZE
3358# ifdef HAVE_UNISTD_H
3359# include <unistd.h>
3360# endif
3361
3362/* Assume that all systems that can run configure have sys/param.h. */
3363# ifndef HAVE_SYS_PARAM_H
3364# define HAVE_SYS_PARAM_H 1
3365# endif
3366
3367# ifdef _SC_PAGESIZE
3368# define getpagesize() sysconf(_SC_PAGESIZE)
3369# else /* no _SC_PAGESIZE */
3370# ifdef HAVE_SYS_PARAM_H
3371# include <sys/param.h>
3372# ifdef EXEC_PAGESIZE
3373# define getpagesize() EXEC_PAGESIZE
3374# else /* no EXEC_PAGESIZE */
3375# ifdef NBPG
3376# define getpagesize() NBPG * CLSIZE
3377# ifndef CLSIZE
3378# define CLSIZE 1
3379# endif /* no CLSIZE */
3380# else /* no NBPG */
3381# ifdef NBPC
3382# define getpagesize() NBPC
3383# else /* no NBPC */
3384# ifdef PAGESIZE
3385# define getpagesize() PAGESIZE
3386# endif /* PAGESIZE */
3387# endif /* no NBPC */
3388# endif /* no NBPG */
3389# endif /* no EXEC_PAGESIZE */
3390# else /* no HAVE_SYS_PARAM_H */
3391# define getpagesize() 8192 /* punt totally */
3392# endif /* no HAVE_SYS_PARAM_H */
3393# endif /* no _SC_PAGESIZE */
3394
3395#endif /* no HAVE_GETPAGESIZE */
3396
3397#ifdef __cplusplus
3398extern "C" { void *malloc(unsigned); }
3399#else
3400char *malloc();
3401#endif
3402
3403int
3404main()
3405{
3406 char *data, *data2, *data3;
3407 int i, pagesize;
3408 int fd;
3409
3410 pagesize = getpagesize();
3411
3412 /*
3413 * First, make a file with some known garbage in it.
3414 */
3415 data = malloc(pagesize);
3416 if (!data)
3417 exit(1);
3418 for (i = 0; i < pagesize; ++i)
3419 *(data + i) = rand();
3420 umask(0);
3421 fd = creat("conftestmmap", 0600);
3422 if (fd < 0)
3423 exit(1);
3424 if (write(fd, data, pagesize) != pagesize)
3425 exit(1);
3426 close(fd);
3427
3428 /*
3429 * Next, try to mmap the file at a fixed address which
3430 * already has something else allocated at it. If we can,
3431 * also make sure that we see the same garbage.
3432 */
3433 fd = open("conftestmmap", O_RDWR);
3434 if (fd < 0)
3435 exit(1);
3436 data2 = malloc(2 * pagesize);
3437 if (!data2)
3438 exit(1);
3439 data2 += (pagesize - ((int) data2 & (pagesize - 1))) & (pagesize - 1);
3440 if (data2 != mmap(data2, pagesize, PROT_READ | PROT_WRITE,
3441 MAP_PRIVATE | MAP_FIXED, fd, 0L))
3442 exit(1);
3443 for (i = 0; i < pagesize; ++i)
3444 if (*(data + i) != *(data2 + i))
3445 exit(1);
3446
3447 /*
3448 * Finally, make sure that changes to the mapped area
3449 * do not percolate back to the file as seen by read().
3450 * (This is a bug on some variants of i386 svr4.0.)
3451 */
3452 for (i = 0; i < pagesize; ++i)
3453 *(data2 + i) = *(data2 + i) + 1;
3454 data3 = malloc(pagesize);
3455 if (!data3)
3456 exit(1);
3457 if (read(fd, data3, pagesize) != pagesize)
3458 exit(1);
3459 for (i = 0; i < pagesize; ++i)
3460 if (*(data + i) != *(data3 + i))
3461 exit(1);
3462 close(fd);
3463 unlink("conftestmmap");
3464 exit(0);
3465}
3466
3467EOF
d64552c5 3468if { (eval echo configure:3469: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
252b5132
RH
3469then
3470 ac_cv_func_mmap_fixed_mapped=yes
3471else
3472 echo "configure: failed program was:" >&5
3473 cat conftest.$ac_ext >&5
3474 rm -fr conftest*
3475 ac_cv_func_mmap_fixed_mapped=no
3476fi
3477rm -fr conftest*
3478fi
3479
3480fi
3481
3482echo "$ac_t""$ac_cv_func_mmap_fixed_mapped" 1>&6
3483if test $ac_cv_func_mmap_fixed_mapped = yes; then
3484 cat >> confdefs.h <<\EOF
3485#define HAVE_MMAP 1
3486EOF
3487
3488fi
3489
3490
3491 for ac_hdr in argz.h limits.h locale.h nl_types.h malloc.h string.h \
3492unistd.h values.h sys/param.h
3493do
3494ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
3495echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
d64552c5 3496echo "configure:3497: checking for $ac_hdr" >&5
252b5132
RH
3497if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3498 echo $ac_n "(cached) $ac_c" 1>&6
3499else
3500 cat > conftest.$ac_ext <<EOF
d64552c5 3501#line 3502 "configure"
252b5132
RH
3502#include "confdefs.h"
3503#include <$ac_hdr>
3504EOF
3505ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
d64552c5 3506{ (eval echo configure:3507: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
252b5132
RH
3507ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3508if test -z "$ac_err"; then
3509 rm -rf conftest*
3510 eval "ac_cv_header_$ac_safe=yes"
3511else
3512 echo "$ac_err" >&5
3513 echo "configure: failed program was:" >&5
3514 cat conftest.$ac_ext >&5
3515 rm -rf conftest*
3516 eval "ac_cv_header_$ac_safe=no"
3517fi
3518rm -f conftest*
3519fi
3520if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3521 echo "$ac_t""yes" 1>&6
3522 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
3523 cat >> confdefs.h <<EOF
3524#define $ac_tr_hdr 1
3525EOF
3526
3527else
3528 echo "$ac_t""no" 1>&6
3529fi
3530done
3531
3532 for ac_func in getcwd munmap putenv setenv setlocale strchr strcasecmp \
3533__argz_count __argz_stringify __argz_next
3534do
3535echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
d64552c5 3536echo "configure:3537: checking for $ac_func" >&5
252b5132
RH
3537if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3538 echo $ac_n "(cached) $ac_c" 1>&6
3539else
3540 cat > conftest.$ac_ext <<EOF
d64552c5 3541#line 3542 "configure"
252b5132
RH
3542#include "confdefs.h"
3543/* System header to define __stub macros and hopefully few prototypes,
3544 which can conflict with char $ac_func(); below. */
3545#include <assert.h>
3546/* Override any gcc2 internal prototype to avoid an error. */
3547/* We use char because int might match the return type of a gcc2
3548 builtin and then its argument prototype would still apply. */
3549char $ac_func();
3550
3551int main() {
3552
3553/* The GNU C library defines this for functions which it implements
3554 to always fail with ENOSYS. Some functions are actually named
3555 something starting with __ and the normal name is an alias. */
3556#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3557choke me
3558#else
3559$ac_func();
3560#endif
3561
3562; return 0; }
3563EOF
d64552c5 3564if { (eval echo configure:3565: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
3565 rm -rf conftest*
3566 eval "ac_cv_func_$ac_func=yes"
3567else
3568 echo "configure: failed program was:" >&5
3569 cat conftest.$ac_ext >&5
3570 rm -rf conftest*
3571 eval "ac_cv_func_$ac_func=no"
3572fi
3573rm -f conftest*
3574fi
3575
3576if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3577 echo "$ac_t""yes" 1>&6
3578 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3579 cat >> confdefs.h <<EOF
3580#define $ac_tr_func 1
3581EOF
3582
3583else
3584 echo "$ac_t""no" 1>&6
3585fi
3586done
3587
3588
3589 if test "${ac_cv_func_stpcpy+set}" != "set"; then
3590 for ac_func in stpcpy
3591do
3592echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
d64552c5 3593echo "configure:3594: checking for $ac_func" >&5
252b5132
RH
3594if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3595 echo $ac_n "(cached) $ac_c" 1>&6
3596else
3597 cat > conftest.$ac_ext <<EOF
d64552c5 3598#line 3599 "configure"
252b5132
RH
3599#include "confdefs.h"
3600/* System header to define __stub macros and hopefully few prototypes,
3601 which can conflict with char $ac_func(); below. */
3602#include <assert.h>
3603/* Override any gcc2 internal prototype to avoid an error. */
3604/* We use char because int might match the return type of a gcc2
3605 builtin and then its argument prototype would still apply. */
3606char $ac_func();
3607
3608int main() {
3609
3610/* The GNU C library defines this for functions which it implements
3611 to always fail with ENOSYS. Some functions are actually named
3612 something starting with __ and the normal name is an alias. */
3613#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3614choke me
3615#else
3616$ac_func();
3617#endif
3618
3619; return 0; }
3620EOF
d64552c5 3621if { (eval echo configure:3622: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
3622 rm -rf conftest*
3623 eval "ac_cv_func_$ac_func=yes"
3624else
3625 echo "configure: failed program was:" >&5
3626 cat conftest.$ac_ext >&5
3627 rm -rf conftest*
3628 eval "ac_cv_func_$ac_func=no"
3629fi
3630rm -f conftest*
3631fi
3632
3633if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3634 echo "$ac_t""yes" 1>&6
3635 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3636 cat >> confdefs.h <<EOF
3637#define $ac_tr_func 1
3638EOF
3639
3640else
3641 echo "$ac_t""no" 1>&6
3642fi
3643done
3644
3645 fi
3646 if test "${ac_cv_func_stpcpy}" = "yes"; then
3647 cat >> confdefs.h <<\EOF
3648#define HAVE_STPCPY 1
3649EOF
3650
3651 fi
3652
3653 if test $ac_cv_header_locale_h = yes; then
3654 echo $ac_n "checking for LC_MESSAGES""... $ac_c" 1>&6
d64552c5 3655echo "configure:3656: checking for LC_MESSAGES" >&5
252b5132
RH
3656if eval "test \"`echo '$''{'am_cv_val_LC_MESSAGES'+set}'`\" = set"; then
3657 echo $ac_n "(cached) $ac_c" 1>&6
3658else
3659 cat > conftest.$ac_ext <<EOF
d64552c5 3660#line 3661 "configure"
252b5132
RH
3661#include "confdefs.h"
3662#include <locale.h>
3663int main() {
3664return LC_MESSAGES
3665; return 0; }
3666EOF
d64552c5 3667if { (eval echo configure:3668: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
3668 rm -rf conftest*
3669 am_cv_val_LC_MESSAGES=yes
3670else
3671 echo "configure: failed program was:" >&5
3672 cat conftest.$ac_ext >&5
3673 rm -rf conftest*
3674 am_cv_val_LC_MESSAGES=no
3675fi
3676rm -f conftest*
3677fi
3678
3679echo "$ac_t""$am_cv_val_LC_MESSAGES" 1>&6
3680 if test $am_cv_val_LC_MESSAGES = yes; then
3681 cat >> confdefs.h <<\EOF
3682#define HAVE_LC_MESSAGES 1
3683EOF
3684
3685 fi
3686 fi
3687 echo $ac_n "checking whether NLS is requested""... $ac_c" 1>&6
d64552c5 3688echo "configure:3689: checking whether NLS is requested" >&5
252b5132
RH
3689 # Check whether --enable-nls or --disable-nls was given.
3690if test "${enable_nls+set}" = set; then
3691 enableval="$enable_nls"
3692 USE_NLS=$enableval
3693else
3694 USE_NLS=yes
3695fi
3696
3697 echo "$ac_t""$USE_NLS" 1>&6
3698
3699
3700 USE_INCLUDED_LIBINTL=no
3701
3702 if test "$USE_NLS" = "yes"; then
3703 cat >> confdefs.h <<\EOF
3704#define ENABLE_NLS 1
3705EOF
3706
3707 echo $ac_n "checking whether included gettext is requested""... $ac_c" 1>&6
d64552c5 3708echo "configure:3709: checking whether included gettext is requested" >&5
252b5132
RH
3709 # Check whether --with-included-gettext or --without-included-gettext was given.
3710if test "${with_included_gettext+set}" = set; then
3711 withval="$with_included_gettext"
3712 nls_cv_force_use_gnu_gettext=$withval
3713else
3714 nls_cv_force_use_gnu_gettext=no
3715fi
3716
3717 echo "$ac_t""$nls_cv_force_use_gnu_gettext" 1>&6
3718
3719 nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext"
3720 if test "$nls_cv_force_use_gnu_gettext" != "yes"; then
3721 nls_cv_header_intl=
3722 nls_cv_header_libgt=
3723 CATOBJEXT=NONE
3724
3725 ac_safe=`echo "libintl.h" | sed 'y%./+-%__p_%'`
3726echo $ac_n "checking for libintl.h""... $ac_c" 1>&6
d64552c5 3727echo "configure:3728: checking for libintl.h" >&5
252b5132
RH
3728if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3729 echo $ac_n "(cached) $ac_c" 1>&6
3730else
3731 cat > conftest.$ac_ext <<EOF
d64552c5 3732#line 3733 "configure"
252b5132
RH
3733#include "confdefs.h"
3734#include <libintl.h>
3735EOF
3736ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
d64552c5 3737{ (eval echo configure:3738: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
252b5132
RH
3738ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3739if test -z "$ac_err"; then
3740 rm -rf conftest*
3741 eval "ac_cv_header_$ac_safe=yes"
3742else
3743 echo "$ac_err" >&5
3744 echo "configure: failed program was:" >&5
3745 cat conftest.$ac_ext >&5
3746 rm -rf conftest*
3747 eval "ac_cv_header_$ac_safe=no"
3748fi
3749rm -f conftest*
3750fi
3751if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3752 echo "$ac_t""yes" 1>&6
3753 echo $ac_n "checking for gettext in libc""... $ac_c" 1>&6
d64552c5 3754echo "configure:3755: checking for gettext in libc" >&5
252b5132
RH
3755if eval "test \"`echo '$''{'gt_cv_func_gettext_libc'+set}'`\" = set"; then
3756 echo $ac_n "(cached) $ac_c" 1>&6
3757else
3758 cat > conftest.$ac_ext <<EOF
d64552c5 3759#line 3760 "configure"
252b5132
RH
3760#include "confdefs.h"
3761#include <libintl.h>
3762int main() {
3763return (int) gettext ("")
3764; return 0; }
3765EOF
d64552c5 3766if { (eval echo configure:3767: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
3767 rm -rf conftest*
3768 gt_cv_func_gettext_libc=yes
3769else
3770 echo "configure: failed program was:" >&5
3771 cat conftest.$ac_ext >&5
3772 rm -rf conftest*
3773 gt_cv_func_gettext_libc=no
3774fi
3775rm -f conftest*
3776fi
3777
3778echo "$ac_t""$gt_cv_func_gettext_libc" 1>&6
3779
3780 if test "$gt_cv_func_gettext_libc" != "yes"; then
3781 echo $ac_n "checking for bindtextdomain in -lintl""... $ac_c" 1>&6
d64552c5 3782echo "configure:3783: checking for bindtextdomain in -lintl" >&5
252b5132
RH
3783ac_lib_var=`echo intl'_'bindtextdomain | sed 'y%./+-%__p_%'`
3784if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3785 echo $ac_n "(cached) $ac_c" 1>&6
3786else
3787 ac_save_LIBS="$LIBS"
3788LIBS="-lintl $LIBS"
3789cat > conftest.$ac_ext <<EOF
d64552c5 3790#line 3791 "configure"
252b5132
RH
3791#include "confdefs.h"
3792/* Override any gcc2 internal prototype to avoid an error. */
3793/* We use char because int might match the return type of a gcc2
3794 builtin and then its argument prototype would still apply. */
3795char bindtextdomain();
3796
3797int main() {
3798bindtextdomain()
3799; return 0; }
3800EOF
d64552c5 3801if { (eval echo configure:3802: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
3802 rm -rf conftest*
3803 eval "ac_cv_lib_$ac_lib_var=yes"
3804else
3805 echo "configure: failed program was:" >&5
3806 cat conftest.$ac_ext >&5
3807 rm -rf conftest*
3808 eval "ac_cv_lib_$ac_lib_var=no"
3809fi
3810rm -f conftest*
3811LIBS="$ac_save_LIBS"
3812
3813fi
3814if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3815 echo "$ac_t""yes" 1>&6
3816 echo $ac_n "checking for gettext in libintl""... $ac_c" 1>&6
d64552c5 3817echo "configure:3818: checking for gettext in libintl" >&5
252b5132
RH
3818if eval "test \"`echo '$''{'gt_cv_func_gettext_libintl'+set}'`\" = set"; then
3819 echo $ac_n "(cached) $ac_c" 1>&6
3820else
3821 cat > conftest.$ac_ext <<EOF
d64552c5 3822#line 3823 "configure"
252b5132
RH
3823#include "confdefs.h"
3824
3825int main() {
3826return (int) gettext ("")
3827; return 0; }
3828EOF
d64552c5 3829if { (eval echo configure:3830: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
3830 rm -rf conftest*
3831 gt_cv_func_gettext_libintl=yes
3832else
3833 echo "configure: failed program was:" >&5
3834 cat conftest.$ac_ext >&5
3835 rm -rf conftest*
3836 gt_cv_func_gettext_libintl=no
3837fi
3838rm -f conftest*
3839fi
3840
3841echo "$ac_t""$gt_cv_func_gettext_libintl" 1>&6
3842else
3843 echo "$ac_t""no" 1>&6
3844fi
3845
3846 fi
3847
3848 if test "$gt_cv_func_gettext_libc" = "yes" \
3849 || test "$gt_cv_func_gettext_libintl" = "yes"; then
3850 cat >> confdefs.h <<\EOF
3851#define HAVE_GETTEXT 1
3852EOF
3853
3854 # Extract the first word of "msgfmt", so it can be a program name with args.
3855set dummy msgfmt; ac_word=$2
3856echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
d64552c5 3857echo "configure:3858: checking for $ac_word" >&5
252b5132
RH
3858if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
3859 echo $ac_n "(cached) $ac_c" 1>&6
3860else
3861 case "$MSGFMT" in
3862 /*)
3863 ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
3864 ;;
3865 *)
3866 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
3867 for ac_dir in $PATH; do
3868 test -z "$ac_dir" && ac_dir=.
3869 if test -f $ac_dir/$ac_word; then
3870 if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then
3871 ac_cv_path_MSGFMT="$ac_dir/$ac_word"
3872 break
3873 fi
3874 fi
3875 done
3876 IFS="$ac_save_ifs"
3877 test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="no"
3878 ;;
3879esac
3880fi
3881MSGFMT="$ac_cv_path_MSGFMT"
3882if test -n "$MSGFMT"; then
3883 echo "$ac_t""$MSGFMT" 1>&6
3884else
3885 echo "$ac_t""no" 1>&6
3886fi
3887 if test "$MSGFMT" != "no"; then
3888 for ac_func in dcgettext
3889do
3890echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
d64552c5 3891echo "configure:3892: checking for $ac_func" >&5
252b5132
RH
3892if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3893 echo $ac_n "(cached) $ac_c" 1>&6
3894else
3895 cat > conftest.$ac_ext <<EOF
d64552c5 3896#line 3897 "configure"
252b5132
RH
3897#include "confdefs.h"
3898/* System header to define __stub macros and hopefully few prototypes,
3899 which can conflict with char $ac_func(); below. */
3900#include <assert.h>
3901/* Override any gcc2 internal prototype to avoid an error. */
3902/* We use char because int might match the return type of a gcc2
3903 builtin and then its argument prototype would still apply. */
3904char $ac_func();
3905
3906int main() {
3907
3908/* The GNU C library defines this for functions which it implements
3909 to always fail with ENOSYS. Some functions are actually named
3910 something starting with __ and the normal name is an alias. */
3911#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3912choke me
3913#else
3914$ac_func();
3915#endif
3916
3917; return 0; }
3918EOF
d64552c5 3919if { (eval echo configure:3920: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
3920 rm -rf conftest*
3921 eval "ac_cv_func_$ac_func=yes"
3922else
3923 echo "configure: failed program was:" >&5
3924 cat conftest.$ac_ext >&5
3925 rm -rf conftest*
3926 eval "ac_cv_func_$ac_func=no"
3927fi
3928rm -f conftest*
3929fi
3930
3931if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3932 echo "$ac_t""yes" 1>&6
3933 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3934 cat >> confdefs.h <<EOF
3935#define $ac_tr_func 1
3936EOF
3937
3938else
3939 echo "$ac_t""no" 1>&6
3940fi
3941done
3942
3943 # Extract the first word of "gmsgfmt", so it can be a program name with args.
3944set dummy gmsgfmt; ac_word=$2
3945echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
d64552c5 3946echo "configure:3947: checking for $ac_word" >&5
252b5132
RH
3947if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
3948 echo $ac_n "(cached) $ac_c" 1>&6
3949else
3950 case "$GMSGFMT" in
3951 /*)
3952 ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
3953 ;;
3954 ?:/*)
3955 ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a dos path.
3956 ;;
3957 *)
3958 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3959 ac_dummy="$PATH"
3960 for ac_dir in $ac_dummy; do
3961 test -z "$ac_dir" && ac_dir=.
3962 if test -f $ac_dir/$ac_word; then
3963 ac_cv_path_GMSGFMT="$ac_dir/$ac_word"
3964 break
3965 fi
3966 done
3967 IFS="$ac_save_ifs"
3968 test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
3969 ;;
3970esac
3971fi
3972GMSGFMT="$ac_cv_path_GMSGFMT"
3973if test -n "$GMSGFMT"; then
3974 echo "$ac_t""$GMSGFMT" 1>&6
3975else
3976 echo "$ac_t""no" 1>&6
3977fi
3978
3979 # Extract the first word of "xgettext", so it can be a program name with args.
3980set dummy xgettext; ac_word=$2
3981echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
d64552c5 3982echo "configure:3983: checking for $ac_word" >&5
252b5132
RH
3983if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
3984 echo $ac_n "(cached) $ac_c" 1>&6
3985else
3986 case "$XGETTEXT" in
3987 /*)
3988 ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
3989 ;;
3990 *)
3991 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
3992 for ac_dir in $PATH; do
3993 test -z "$ac_dir" && ac_dir=.
3994 if test -f $ac_dir/$ac_word; then
3995 if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then
3996 ac_cv_path_XGETTEXT="$ac_dir/$ac_word"
3997 break
3998 fi
3999 fi
4000 done
4001 IFS="$ac_save_ifs"
4002 test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
4003 ;;
4004esac
4005fi
4006XGETTEXT="$ac_cv_path_XGETTEXT"
4007if test -n "$XGETTEXT"; then
4008 echo "$ac_t""$XGETTEXT" 1>&6
4009else
4010 echo "$ac_t""no" 1>&6
4011fi
4012
4013 cat > conftest.$ac_ext <<EOF
d64552c5 4014#line 4015 "configure"
252b5132
RH
4015#include "confdefs.h"
4016
4017int main() {
4018extern int _nl_msg_cat_cntr;
4019 return _nl_msg_cat_cntr
4020; return 0; }
4021EOF
d64552c5 4022if { (eval echo configure:4023: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
4023 rm -rf conftest*
4024 CATOBJEXT=.gmo
4025 DATADIRNAME=share
4026else
4027 echo "configure: failed program was:" >&5
4028 cat conftest.$ac_ext >&5
4029 rm -rf conftest*
4030 CATOBJEXT=.mo
4031 DATADIRNAME=lib
4032fi
4033rm -f conftest*
4034 INSTOBJEXT=.mo
4035 fi
4036 fi
4037
4038else
4039 echo "$ac_t""no" 1>&6
4040fi
4041
4042
4043
4044 if test "$CATOBJEXT" = "NONE"; then
4045 nls_cv_use_gnu_gettext=yes
4046 fi
4047 fi
4048
4049 if test "$nls_cv_use_gnu_gettext" = "yes"; then
4050 INTLOBJS="\$(GETTOBJS)"
4051 # Extract the first word of "msgfmt", so it can be a program name with args.
4052set dummy msgfmt; ac_word=$2
4053echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
d64552c5 4054echo "configure:4055: checking for $ac_word" >&5
252b5132
RH
4055if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
4056 echo $ac_n "(cached) $ac_c" 1>&6
4057else
4058 case "$MSGFMT" in
4059 /*)
4060 ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
4061 ;;
4062 *)
4063 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
4064 for ac_dir in $PATH; do
4065 test -z "$ac_dir" && ac_dir=.
4066 if test -f $ac_dir/$ac_word; then
4067 if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then
4068 ac_cv_path_MSGFMT="$ac_dir/$ac_word"
4069 break
4070 fi
4071 fi
4072 done
4073 IFS="$ac_save_ifs"
4074 test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="msgfmt"
4075 ;;
4076esac
4077fi
4078MSGFMT="$ac_cv_path_MSGFMT"
4079if test -n "$MSGFMT"; then
4080 echo "$ac_t""$MSGFMT" 1>&6
4081else
4082 echo "$ac_t""no" 1>&6
4083fi
4084
4085 # Extract the first word of "gmsgfmt", so it can be a program name with args.
4086set dummy gmsgfmt; ac_word=$2
4087echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
d64552c5 4088echo "configure:4089: checking for $ac_word" >&5
252b5132
RH
4089if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
4090 echo $ac_n "(cached) $ac_c" 1>&6
4091else
4092 case "$GMSGFMT" in
4093 /*)
4094 ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
4095 ;;
4096 ?:/*)
4097 ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a dos path.
4098 ;;
4099 *)
4100 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4101 ac_dummy="$PATH"
4102 for ac_dir in $ac_dummy; do
4103 test -z "$ac_dir" && ac_dir=.
4104 if test -f $ac_dir/$ac_word; then
4105 ac_cv_path_GMSGFMT="$ac_dir/$ac_word"
4106 break
4107 fi
4108 done
4109 IFS="$ac_save_ifs"
4110 test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
4111 ;;
4112esac
4113fi
4114GMSGFMT="$ac_cv_path_GMSGFMT"
4115if test -n "$GMSGFMT"; then
4116 echo "$ac_t""$GMSGFMT" 1>&6
4117else
4118 echo "$ac_t""no" 1>&6
4119fi
4120
4121 # Extract the first word of "xgettext", so it can be a program name with args.
4122set dummy xgettext; ac_word=$2
4123echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
d64552c5 4124echo "configure:4125: checking for $ac_word" >&5
252b5132
RH
4125if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
4126 echo $ac_n "(cached) $ac_c" 1>&6
4127else
4128 case "$XGETTEXT" in
4129 /*)
4130 ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
4131 ;;
4132 *)
4133 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
4134 for ac_dir in $PATH; do
4135 test -z "$ac_dir" && ac_dir=.
4136 if test -f $ac_dir/$ac_word; then
4137 if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then
4138 ac_cv_path_XGETTEXT="$ac_dir/$ac_word"
4139 break
4140 fi
4141 fi
4142 done
4143 IFS="$ac_save_ifs"
4144 test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
4145 ;;
4146esac
4147fi
4148XGETTEXT="$ac_cv_path_XGETTEXT"
4149if test -n "$XGETTEXT"; then
4150 echo "$ac_t""$XGETTEXT" 1>&6
4151else
4152 echo "$ac_t""no" 1>&6
4153fi
4154
4155
4156 USE_INCLUDED_LIBINTL=yes
4157 CATOBJEXT=.gmo
4158 INSTOBJEXT=.mo
4159 DATADIRNAME=share
4160 INTLDEPS='$(top_builddir)/../intl/libintl.a'
4161 INTLLIBS=$INTLDEPS
4162 LIBS=`echo $LIBS | sed -e 's/-lintl//'`
4163 nls_cv_header_intl=libintl.h
4164 nls_cv_header_libgt=libgettext.h
4165 fi
4166
4167 if test "$XGETTEXT" != ":"; then
4168 if $XGETTEXT --omit-header /dev/null 2> /dev/null; then
4169 : ;
4170 else
4171 echo "$ac_t""found xgettext programs is not GNU xgettext; ignore it" 1>&6
4172 XGETTEXT=":"
4173 fi
4174 fi
4175
4176 # We need to process the po/ directory.
4177 POSUB=po
4178 else
4179 DATADIRNAME=share
4180 nls_cv_header_intl=libintl.h
4181 nls_cv_header_libgt=libgettext.h
4182 fi
4183
4184 # If this is used in GNU gettext we have to set USE_NLS to `yes'
4185 # because some of the sources are only built for this goal.
4186 if test "$PACKAGE" = gettext; then
4187 USE_NLS=yes
4188 USE_INCLUDED_LIBINTL=yes
4189 fi
4190
4191 for lang in $ALL_LINGUAS; do
4192 GMOFILES="$GMOFILES $lang.gmo"
4193 POFILES="$POFILES $lang.po"
4194 done
4195
4196
4197
4198
4199
4200
4201
4202
4203
4204
4205
4206
4207
4208
4209 if test "x$CATOBJEXT" != "x"; then
4210 if test "x$ALL_LINGUAS" = "x"; then
4211 LINGUAS=
4212 else
4213 echo $ac_n "checking for catalogs to be installed""... $ac_c" 1>&6
d64552c5 4214echo "configure:4215: checking for catalogs to be installed" >&5
252b5132
RH
4215 NEW_LINGUAS=
4216 for lang in ${LINGUAS=$ALL_LINGUAS}; do
4217 case "$ALL_LINGUAS" in
4218 *$lang*) NEW_LINGUAS="$NEW_LINGUAS $lang" ;;
4219 esac
4220 done
4221 LINGUAS=$NEW_LINGUAS
4222 echo "$ac_t""$LINGUAS" 1>&6
4223 fi
4224
4225 if test -n "$LINGUAS"; then
4226 for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done
4227 fi
4228 fi
4229
4230 if test $ac_cv_header_locale_h = yes; then
4231 INCLUDE_LOCALE_H="#include <locale.h>"
4232 else
4233 INCLUDE_LOCALE_H="\
4234/* The system does not provide the header <locale.h>. Take care yourself. */"
4235 fi
4236
4237
4238 if test -f $srcdir/po2tbl.sed.in; then
4239 if test "$CATOBJEXT" = ".cat"; then
4240 ac_safe=`echo "linux/version.h" | sed 'y%./+-%__p_%'`
4241echo $ac_n "checking for linux/version.h""... $ac_c" 1>&6
d64552c5 4242echo "configure:4243: checking for linux/version.h" >&5
252b5132
RH
4243if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4244 echo $ac_n "(cached) $ac_c" 1>&6
4245else
4246 cat > conftest.$ac_ext <<EOF
d64552c5 4247#line 4248 "configure"
252b5132
RH
4248#include "confdefs.h"
4249#include <linux/version.h>
4250EOF
4251ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
d64552c5 4252{ (eval echo configure:4253: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
252b5132
RH
4253ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4254if test -z "$ac_err"; then
4255 rm -rf conftest*
4256 eval "ac_cv_header_$ac_safe=yes"
4257else
4258 echo "$ac_err" >&5
4259 echo "configure: failed program was:" >&5
4260 cat conftest.$ac_ext >&5
4261 rm -rf conftest*
4262 eval "ac_cv_header_$ac_safe=no"
4263fi
4264rm -f conftest*
4265fi
4266if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4267 echo "$ac_t""yes" 1>&6
4268 msgformat=linux
4269else
4270 echo "$ac_t""no" 1>&6
4271msgformat=xopen
4272fi
4273
4274
4275 sed -e '/^#/d' $srcdir/$msgformat-msg.sed > po2msg.sed
4276 fi
4277 sed -e '/^#.*[^\\]$/d' -e '/^#$/d' \
4278 $srcdir/po2tbl.sed.in > po2tbl.sed
4279 fi
4280
4281 if test "$PACKAGE" = "gettext"; then
4282 GT_NO="#NO#"
4283 GT_YES=
4284 else
4285 GT_NO=
4286 GT_YES="#YES#"
4287 fi
4288
4289
4290
4291 MKINSTALLDIRS="\$(srcdir)/../../mkinstalldirs"
4292
4293
4294 l=
4295
4296
4297 if test -d $srcdir/po; then
4298 test -d po || mkdir po
4299 if test "x$srcdir" != "x."; then
4300 if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then
4301 posrcprefix="$srcdir/"
4302 else
4303 posrcprefix="../$srcdir/"
4304 fi
4305 else
4306 posrcprefix="../"
4307 fi
4308 rm -f po/POTFILES
4309 sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \
4310 < $srcdir/po/POTFILES.in > po/POTFILES
4311 fi
4312
4313
4314echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
d64552c5 4315echo "configure:4316: checking whether to enable maintainer-specific portions of Makefiles" >&5
252b5132
RH
4316 # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
4317if test "${enable_maintainer_mode+set}" = set; then
4318 enableval="$enable_maintainer_mode"
4319 USE_MAINTAINER_MODE=$enableval
4320else
4321 USE_MAINTAINER_MODE=no
4322fi
4323
4324 echo "$ac_t""$USE_MAINTAINER_MODE" 1>&6
4325
4326
4327if test $USE_MAINTAINER_MODE = yes; then
4328 MAINTAINER_MODE_TRUE=
4329 MAINTAINER_MODE_FALSE='#'
4330else
4331 MAINTAINER_MODE_TRUE='#'
4332 MAINTAINER_MODE_FALSE=
4333fi
4334 MAINT=$MAINTAINER_MODE_TRUE
4335
4336
252b5132
RH
4337
4338
4339echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
d64552c5 4340echo "configure:4341: checking for executable suffix" >&5
252b5132
RH
4341if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
4342 echo $ac_n "(cached) $ac_c" 1>&6
4343else
4344 if test "$CYGWIN" = yes || test "$MINGW32" = yes; then
4345 ac_cv_exeext=.exe
4346else
4347 rm -f conftest*
4348 echo 'int main () { return 0; }' > conftest.$ac_ext
4349 ac_cv_exeext=
d64552c5 4350 if { (eval echo configure:4351: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
252b5132
RH
4351 for file in conftest.*; do
4352 case $file in
d64552c5 4353 *.c | *.o | *.obj) ;;
252b5132
RH
4354 *) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
4355 esac
4356 done
4357 else
4358 { echo "configure: error: installation or configuration problem: compiler cannot create executables." 1>&2; exit 1; }
4359 fi
4360 rm -f conftest*
4361 test x"${ac_cv_exeext}" = x && ac_cv_exeext=no
4362fi
4363fi
4364
4365EXEEXT=""
4366test x"${ac_cv_exeext}" != xno && EXEEXT=${ac_cv_exeext}
4367echo "$ac_t""${ac_cv_exeext}" 1>&6
4368ac_exeext=$EXEEXT
4369
2481e6a2
ILT
4370if test -n "$EXEEXT"; then
4371 cat >> confdefs.h <<\EOF
4372#define HAVE_EXECUTABLE_SUFFIX 1
4373EOF
4374
4375fi
bb0cb4db
ILT
4376cat >> confdefs.h <<EOF
4377#define EXECUTABLE_SUFFIX "${EXEEXT}"
4378EOF
4379
252b5132
RH
4380
4381# host-specific stuff:
4382
4383HDEFINES=
4384
4385. ${srcdir}/../bfd/configure.host
4386
4387
4388AR=${AR-ar}
4389
4390# Extract the first word of "ranlib", so it can be a program name with args.
4391set dummy ranlib; ac_word=$2
4392echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
d64552c5 4393echo "configure:4394: checking for $ac_word" >&5
252b5132
RH
4394if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
4395 echo $ac_n "(cached) $ac_c" 1>&6
4396else
4397 if test -n "$RANLIB"; then
4398 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
4399else
4400 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4401 ac_dummy="$PATH"
4402 for ac_dir in $ac_dummy; do
4403 test -z "$ac_dir" && ac_dir=.
4404 if test -f $ac_dir/$ac_word; then
4405 ac_cv_prog_RANLIB="ranlib"
4406 break
4407 fi
4408 done
4409 IFS="$ac_save_ifs"
4410 test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
4411fi
4412fi
4413RANLIB="$ac_cv_prog_RANLIB"
4414if test -n "$RANLIB"; then
4415 echo "$ac_t""$RANLIB" 1>&6
4416else
4417 echo "$ac_t""no" 1>&6
4418fi
4419
4420# Find a good install program. We prefer a C program (faster),
4421# so one script is as good as another. But avoid the broken or
4422# incompatible versions:
4423# SysV /etc/install, /usr/sbin/install
4424# SunOS /usr/etc/install
4425# IRIX /sbin/install
4426# AIX /bin/install
4427# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
4428# AFS /usr/afsws/bin/install, which mishandles nonexistent args
4429# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
4430# ./install, which can be erroneously created by make from ./install.sh.
4431echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
d64552c5 4432echo "configure:4433: checking for a BSD compatible install" >&5
252b5132
RH
4433if test -z "$INSTALL"; then
4434if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
4435 echo $ac_n "(cached) $ac_c" 1>&6
4436else
4437 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":"
4438 for ac_dir in $PATH; do
4439 # Account for people who put trailing slashes in PATH elements.
4440 case "$ac_dir/" in
4441 /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
4442 *)
4443 # OSF1 and SCO ODT 3.0 have their own names for install.
4444 # Don't use installbsd from OSF since it installs stuff as root
4445 # by default.
4446 for ac_prog in ginstall scoinst install; do
4447 if test -f $ac_dir/$ac_prog; then
4448 if test $ac_prog = install &&
4449 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
4450 # AIX install. It has an incompatible calling convention.
4451 :
4452 else
4453 ac_cv_path_install="$ac_dir/$ac_prog -c"
4454 break 2
4455 fi
4456 fi
4457 done
4458 ;;
4459 esac
4460 done
4461 IFS="$ac_save_IFS"
4462
4463fi
4464 if test "${ac_cv_path_install+set}" = set; then
4465 INSTALL="$ac_cv_path_install"
4466 else
4467 # As a last resort, use the slow shell script. We don't cache a
4468 # path for INSTALL within a source directory, because that will
4469 # break other packages using the cache if that directory is
4470 # removed, or if the path is relative.
4471 INSTALL="$ac_install_sh"
4472 fi
4473fi
4474echo "$ac_t""$INSTALL" 1>&6
4475
4476# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
4477# It thinks the first close brace ends the variable substitution.
4478test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
4479
4480test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
4481
4482test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
4483
4484
4485# Put a plausible default for CC_FOR_BUILD in Makefile.
4486if test -z "$CC_FOR_BUILD"; then
4487 if test "x$cross_compiling" = "xno"; then
4488 CC_FOR_BUILD='$(CC)'
4489 else
4490 CC_FOR_BUILD=gcc
4491 fi
4492fi
4493
4494# Also set EXEEXT_FOR_BUILD.
4495if test "x$cross_compiling" = "xno"; then
4496 EXEEXT_FOR_BUILD='$(EXEEXT)'
4497else
4498 echo $ac_n "checking for build system executable suffix""... $ac_c" 1>&6
d64552c5 4499echo "configure:4500: checking for build system executable suffix" >&5
252b5132
RH
4500if eval "test \"`echo '$''{'bfd_cv_build_exeext'+set}'`\" = set"; then
4501 echo $ac_n "(cached) $ac_c" 1>&6
4502else
7a7b06ef
ILT
4503 rm -f conftest*
4504 echo 'int main () { return 0; }' > conftest.c
4505 bfd_cv_build_exeext=
4506 ${CC_FOR_BUILD} -o conftest conftest.c 1>&5 2>&5
4507 for file in conftest.*; do
4508 case $file in
4509 *.c | *.o | *.obj | *.ilk | *.pdb) ;;
4510 *) bfd_cv_build_exeext=`echo $file | sed -e s/conftest//` ;;
4511 esac
4512 done
4513 rm -f conftest*
4514 test x"${bfd_cv_build_exeext}" = x && bfd_cv_build_exeext=no
252b5132
RH
4515fi
4516
4517echo "$ac_t""$bfd_cv_build_exeext" 1>&6
4518 EXEEXT_FOR_BUILD=""
4519 test x"${bfd_cv_build_exeext}" != xno && EXEEXT_FOR_BUILD=${bfd_cv_build_exeext}
4520fi
4521
4522
8a965946
ILT
4523DEMANGLER_NAME=c++filt
4524case "${host}" in
4525 *-*-go32* | *-*-msdos*)
4526 DEMANGLER_NAME=cxxfilt
4527esac
4528
4529
252b5132
RH
4530for ac_hdr in string.h strings.h stdlib.h unistd.h fcntl.h sys/file.h
4531do
4532ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4533echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
d64552c5 4534echo "configure:4535: checking for $ac_hdr" >&5
252b5132
RH
4535if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4536 echo $ac_n "(cached) $ac_c" 1>&6
4537else
4538 cat > conftest.$ac_ext <<EOF
d64552c5 4539#line 4540 "configure"
252b5132
RH
4540#include "confdefs.h"
4541#include <$ac_hdr>
4542EOF
4543ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
d64552c5 4544{ (eval echo configure:4545: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
252b5132
RH
4545ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4546if test -z "$ac_err"; then
4547 rm -rf conftest*
4548 eval "ac_cv_header_$ac_safe=yes"
4549else
4550 echo "$ac_err" >&5
4551 echo "configure: failed program was:" >&5
4552 cat conftest.$ac_ext >&5
4553 rm -rf conftest*
4554 eval "ac_cv_header_$ac_safe=no"
4555fi
4556rm -f conftest*
4557fi
4558if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4559 echo "$ac_t""yes" 1>&6
4560 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4561 cat >> confdefs.h <<EOF
4562#define $ac_tr_hdr 1
4563EOF
4564
4565else
4566 echo "$ac_t""no" 1>&6
4567fi
4568done
4569
4570echo $ac_n "checking for sys/wait.h that is POSIX.1 compatible""... $ac_c" 1>&6
d64552c5 4571echo "configure:4572: checking for sys/wait.h that is POSIX.1 compatible" >&5
252b5132
RH
4572if eval "test \"`echo '$''{'ac_cv_header_sys_wait_h'+set}'`\" = set"; then
4573 echo $ac_n "(cached) $ac_c" 1>&6
4574else
4575 cat > conftest.$ac_ext <<EOF
d64552c5 4576#line 4577 "configure"
252b5132
RH
4577#include "confdefs.h"
4578#include <sys/types.h>
4579#include <sys/wait.h>
4580#ifndef WEXITSTATUS
4581#define WEXITSTATUS(stat_val) ((unsigned)(stat_val) >> 8)
4582#endif
4583#ifndef WIFEXITED
4584#define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
4585#endif
4586int main() {
4587int s;
4588wait (&s);
4589s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
4590; return 0; }
4591EOF
d64552c5 4592if { (eval echo configure:4593: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
252b5132
RH
4593 rm -rf conftest*
4594 ac_cv_header_sys_wait_h=yes
4595else
4596 echo "configure: failed program was:" >&5
4597 cat conftest.$ac_ext >&5
4598 rm -rf conftest*
4599 ac_cv_header_sys_wait_h=no
4600fi
4601rm -f conftest*
4602fi
4603
4604echo "$ac_t""$ac_cv_header_sys_wait_h" 1>&6
4605if test $ac_cv_header_sys_wait_h = yes; then
4606 cat >> confdefs.h <<\EOF
4607#define HAVE_SYS_WAIT_H 1
4608EOF
4609
4610fi
4611
4612# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
4613# for constant arguments. Useless!
4614echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
d64552c5 4615echo "configure:4616: checking for working alloca.h" >&5
252b5132
RH
4616if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
4617 echo $ac_n "(cached) $ac_c" 1>&6
4618else
4619 cat > conftest.$ac_ext <<EOF
d64552c5 4620#line 4621 "configure"
252b5132
RH
4621#include "confdefs.h"
4622#include <alloca.h>
4623int main() {
4624char *p = alloca(2 * sizeof(int));
4625; return 0; }
4626EOF
d64552c5 4627if { (eval echo configure:4628: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
4628 rm -rf conftest*
4629 ac_cv_header_alloca_h=yes
4630else
4631 echo "configure: failed program was:" >&5
4632 cat conftest.$ac_ext >&5
4633 rm -rf conftest*
4634 ac_cv_header_alloca_h=no
4635fi
4636rm -f conftest*
4637fi
4638
4639echo "$ac_t""$ac_cv_header_alloca_h" 1>&6
4640if test $ac_cv_header_alloca_h = yes; then
4641 cat >> confdefs.h <<\EOF
4642#define HAVE_ALLOCA_H 1
4643EOF
4644
4645fi
4646
4647echo $ac_n "checking for alloca""... $ac_c" 1>&6
d64552c5 4648echo "configure:4649: checking for alloca" >&5
252b5132
RH
4649if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
4650 echo $ac_n "(cached) $ac_c" 1>&6
4651else
4652 cat > conftest.$ac_ext <<EOF
d64552c5 4653#line 4654 "configure"
252b5132
RH
4654#include "confdefs.h"
4655
4656#ifdef __GNUC__
4657# define alloca __builtin_alloca
4658#else
4659# ifdef _MSC_VER
4660# include <malloc.h>
4661# define alloca _alloca
4662# else
4663# if HAVE_ALLOCA_H
4664# include <alloca.h>
4665# else
4666# ifdef _AIX
4667 #pragma alloca
4668# else
4669# ifndef alloca /* predefined by HP cc +Olibcalls */
4670char *alloca ();
4671# endif
4672# endif
4673# endif
4674# endif
4675#endif
4676
4677int main() {
4678char *p = (char *) alloca(1);
4679; return 0; }
4680EOF
d64552c5 4681if { (eval echo configure:4682: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
4682 rm -rf conftest*
4683 ac_cv_func_alloca_works=yes
4684else
4685 echo "configure: failed program was:" >&5
4686 cat conftest.$ac_ext >&5
4687 rm -rf conftest*
4688 ac_cv_func_alloca_works=no
4689fi
4690rm -f conftest*
4691fi
4692
4693echo "$ac_t""$ac_cv_func_alloca_works" 1>&6
4694if test $ac_cv_func_alloca_works = yes; then
4695 cat >> confdefs.h <<\EOF
4696#define HAVE_ALLOCA 1
4697EOF
4698
4699fi
4700
4701if test $ac_cv_func_alloca_works = no; then
4702 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
4703 # that cause trouble. Some versions do not even contain alloca or
4704 # contain a buggy version. If you still want to use their alloca,
4705 # use ar to extract alloca.o from them instead of compiling alloca.c.
4706 ALLOCA=alloca.${ac_objext}
4707 cat >> confdefs.h <<\EOF
4708#define C_ALLOCA 1
4709EOF
4710
4711
4712echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
d64552c5 4713echo "configure:4714: checking whether alloca needs Cray hooks" >&5
252b5132
RH
4714if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
4715 echo $ac_n "(cached) $ac_c" 1>&6
4716else
4717 cat > conftest.$ac_ext <<EOF
d64552c5 4718#line 4719 "configure"
252b5132
RH
4719#include "confdefs.h"
4720#if defined(CRAY) && ! defined(CRAY2)
4721webecray
4722#else
4723wenotbecray
4724#endif
4725
4726EOF
4727if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4728 egrep "webecray" >/dev/null 2>&1; then
4729 rm -rf conftest*
4730 ac_cv_os_cray=yes
4731else
4732 rm -rf conftest*
4733 ac_cv_os_cray=no
4734fi
4735rm -f conftest*
4736
4737fi
4738
4739echo "$ac_t""$ac_cv_os_cray" 1>&6
4740if test $ac_cv_os_cray = yes; then
4741for ac_func in _getb67 GETB67 getb67; do
4742 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
d64552c5 4743echo "configure:4744: checking for $ac_func" >&5
252b5132
RH
4744if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
4745 echo $ac_n "(cached) $ac_c" 1>&6
4746else
4747 cat > conftest.$ac_ext <<EOF
d64552c5 4748#line 4749 "configure"
252b5132
RH
4749#include "confdefs.h"
4750/* System header to define __stub macros and hopefully few prototypes,
4751 which can conflict with char $ac_func(); below. */
4752#include <assert.h>
4753/* Override any gcc2 internal prototype to avoid an error. */
4754/* We use char because int might match the return type of a gcc2
4755 builtin and then its argument prototype would still apply. */
4756char $ac_func();
4757
4758int main() {
4759
4760/* The GNU C library defines this for functions which it implements
4761 to always fail with ENOSYS. Some functions are actually named
4762 something starting with __ and the normal name is an alias. */
4763#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
4764choke me
4765#else
4766$ac_func();
4767#endif
4768
4769; return 0; }
4770EOF
d64552c5 4771if { (eval echo configure:4772: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
4772 rm -rf conftest*
4773 eval "ac_cv_func_$ac_func=yes"
4774else
4775 echo "configure: failed program was:" >&5
4776 cat conftest.$ac_ext >&5
4777 rm -rf conftest*
4778 eval "ac_cv_func_$ac_func=no"
4779fi
4780rm -f conftest*
4781fi
4782
4783if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
4784 echo "$ac_t""yes" 1>&6
4785 cat >> confdefs.h <<EOF
4786#define CRAY_STACKSEG_END $ac_func
4787EOF
4788
4789 break
4790else
4791 echo "$ac_t""no" 1>&6
4792fi
4793
4794done
4795fi
4796
4797echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
d64552c5 4798echo "configure:4799: checking stack direction for C alloca" >&5
252b5132
RH
4799if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
4800 echo $ac_n "(cached) $ac_c" 1>&6
4801else
4802 if test "$cross_compiling" = yes; then
4803 ac_cv_c_stack_direction=0
4804else
4805 cat > conftest.$ac_ext <<EOF
d64552c5 4806#line 4807 "configure"
252b5132
RH
4807#include "confdefs.h"
4808find_stack_direction ()
4809{
4810 static char *addr = 0;
4811 auto char dummy;
4812 if (addr == 0)
4813 {
4814 addr = &dummy;
4815 return find_stack_direction ();
4816 }
4817 else
4818 return (&dummy > addr) ? 1 : -1;
4819}
4820main ()
4821{
4822 exit (find_stack_direction() < 0);
4823}
4824EOF
d64552c5 4825if { (eval echo configure:4826: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
252b5132
RH
4826then
4827 ac_cv_c_stack_direction=1
4828else
4829 echo "configure: failed program was:" >&5
4830 cat conftest.$ac_ext >&5
4831 rm -fr conftest*
4832 ac_cv_c_stack_direction=-1
4833fi
4834rm -fr conftest*
4835fi
4836
4837fi
4838
4839echo "$ac_t""$ac_cv_c_stack_direction" 1>&6
4840cat >> confdefs.h <<EOF
4841#define STACK_DIRECTION $ac_cv_c_stack_direction
4842EOF
4843
4844fi
4845
5af11cab 4846for ac_func in sbrk utimes setmode
252b5132
RH
4847do
4848echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
d64552c5 4849echo "configure:4850: checking for $ac_func" >&5
252b5132
RH
4850if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
4851 echo $ac_n "(cached) $ac_c" 1>&6
4852else
4853 cat > conftest.$ac_ext <<EOF
d64552c5 4854#line 4855 "configure"
252b5132
RH
4855#include "confdefs.h"
4856/* System header to define __stub macros and hopefully few prototypes,
4857 which can conflict with char $ac_func(); below. */
4858#include <assert.h>
4859/* Override any gcc2 internal prototype to avoid an error. */
4860/* We use char because int might match the return type of a gcc2
4861 builtin and then its argument prototype would still apply. */
4862char $ac_func();
4863
4864int main() {
4865
4866/* The GNU C library defines this for functions which it implements
4867 to always fail with ENOSYS. Some functions are actually named
4868 something starting with __ and the normal name is an alias. */
4869#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
4870choke me
4871#else
4872$ac_func();
4873#endif
4874
4875; return 0; }
4876EOF
d64552c5 4877if { (eval echo configure:4878: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
4878 rm -rf conftest*
4879 eval "ac_cv_func_$ac_func=yes"
4880else
4881 echo "configure: failed program was:" >&5
4882 cat conftest.$ac_ext >&5
4883 rm -rf conftest*
4884 eval "ac_cv_func_$ac_func=no"
4885fi
4886rm -f conftest*
4887fi
4888
4889if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
4890 echo "$ac_t""yes" 1>&6
4891 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
4892 cat >> confdefs.h <<EOF
4893#define $ac_tr_func 1
4894EOF
4895
4896else
4897 echo "$ac_t""no" 1>&6
4898fi
4899done
4900
4901
f353eb8a
ILT
4902# Some systems have frexp only in -lm, not in -lc.
4903
4904echo $ac_n "checking for library containing frexp""... $ac_c" 1>&6
d64552c5 4905echo "configure:4906: checking for library containing frexp" >&5
f353eb8a
ILT
4906if eval "test \"`echo '$''{'ac_cv_search_frexp'+set}'`\" = set"; then
4907 echo $ac_n "(cached) $ac_c" 1>&6
4908else
4909 ac_func_search_save_LIBS="$LIBS"
4910ac_cv_search_frexp="no"
4911cat > conftest.$ac_ext <<EOF
d64552c5 4912#line 4913 "configure"
f353eb8a
ILT
4913#include "confdefs.h"
4914/* Override any gcc2 internal prototype to avoid an error. */
4915/* We use char because int might match the return type of a gcc2
4916 builtin and then its argument prototype would still apply. */
4917char frexp();
4918
4919int main() {
4920frexp()
4921; return 0; }
4922EOF
d64552c5 4923if { (eval echo configure:4924: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
f353eb8a
ILT
4924 rm -rf conftest*
4925 ac_cv_search_frexp="none required"
4926else
4927 echo "configure: failed program was:" >&5
4928 cat conftest.$ac_ext >&5
4929fi
4930rm -f conftest*
9a1cab10 4931test "$ac_cv_search_frexp" = "no" && for i in m; do
f353eb8a
ILT
4932LIBS="-l$i $ac_func_search_save_LIBS"
4933cat > conftest.$ac_ext <<EOF
d64552c5 4934#line 4935 "configure"
f353eb8a
ILT
4935#include "confdefs.h"
4936/* Override any gcc2 internal prototype to avoid an error. */
4937/* We use char because int might match the return type of a gcc2
4938 builtin and then its argument prototype would still apply. */
4939char frexp();
4940
4941int main() {
4942frexp()
4943; return 0; }
4944EOF
d64552c5 4945if { (eval echo configure:4946: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
f353eb8a
ILT
4946 rm -rf conftest*
4947 ac_cv_search_frexp="-l$i"
4948break
4949else
4950 echo "configure: failed program was:" >&5
4951 cat conftest.$ac_ext >&5
4952fi
4953rm -f conftest*
4954done
4955LIBS="$ac_func_search_save_LIBS"
4956fi
4957
4958echo "$ac_t""$ac_cv_search_frexp" 1>&6
4959if test "$ac_cv_search_frexp" != "no"; then
4960 test "$ac_cv_search_frexp" = "none required" || LIBS="$ac_cv_search_frexp $LIBS"
4961
4962else :
4963
4964fi
4965
252b5132 4966echo $ac_n "checking for time_t in time.h""... $ac_c" 1>&6
d64552c5 4967echo "configure:4968: checking for time_t in time.h" >&5
252b5132
RH
4968if eval "test \"`echo '$''{'bu_cv_decl_time_t_time_h'+set}'`\" = set"; then
4969 echo $ac_n "(cached) $ac_c" 1>&6
4970else
4971 cat > conftest.$ac_ext <<EOF
d64552c5 4972#line 4973 "configure"
252b5132
RH
4973#include "confdefs.h"
4974#include <time.h>
4975int main() {
4976time_t i;
4977; return 0; }
4978EOF
d64552c5 4979if { (eval echo configure:4980: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
252b5132
RH
4980 rm -rf conftest*
4981 bu_cv_decl_time_t_time_h=yes
4982else
4983 echo "configure: failed program was:" >&5
4984 cat conftest.$ac_ext >&5
4985 rm -rf conftest*
4986 bu_cv_decl_time_t_time_h=no
4987fi
4988rm -f conftest*
4989fi
4990
4991echo "$ac_t""$bu_cv_decl_time_t_time_h" 1>&6
4992if test $bu_cv_decl_time_t_time_h = yes; then
4993 cat >> confdefs.h <<\EOF
4994#define HAVE_TIME_T_IN_TIME_H 1
4995EOF
4996
4997fi
4998
4999echo $ac_n "checking for time_t in sys/types.h""... $ac_c" 1>&6
d64552c5 5000echo "configure:5001: checking for time_t in sys/types.h" >&5
252b5132
RH
5001if eval "test \"`echo '$''{'bu_cv_decl_time_t_types_h'+set}'`\" = set"; then
5002 echo $ac_n "(cached) $ac_c" 1>&6
5003else
5004 cat > conftest.$ac_ext <<EOF
d64552c5 5005#line 5006 "configure"
252b5132
RH
5006#include "confdefs.h"
5007#include <sys/types.h>
5008int main() {
5009time_t i;
5010; return 0; }
5011EOF
d64552c5 5012if { (eval echo configure:5013: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
252b5132
RH
5013 rm -rf conftest*
5014 bu_cv_decl_time_t_types_h=yes
5015else
5016 echo "configure: failed program was:" >&5
5017 cat conftest.$ac_ext >&5
5018 rm -rf conftest*
5019 bu_cv_decl_time_t_types_h=no
5020fi
5021rm -f conftest*
5022fi
5023
5024echo "$ac_t""$bu_cv_decl_time_t_types_h" 1>&6
5025if test $bu_cv_decl_time_t_types_h = yes; then
5026 cat >> confdefs.h <<\EOF
5027#define HAVE_TIME_T_IN_TYPES_H 1
5028EOF
5029
5030fi
5031
5032# Under Next 3.2 <utime.h> apparently does not define struct utimbuf
5033# by default.
5034echo $ac_n "checking for utime.h""... $ac_c" 1>&6
d64552c5 5035echo "configure:5036: checking for utime.h" >&5
252b5132
RH
5036if eval "test \"`echo '$''{'bu_cv_header_utime_h'+set}'`\" = set"; then
5037 echo $ac_n "(cached) $ac_c" 1>&6
5038else
5039 cat > conftest.$ac_ext <<EOF
d64552c5 5040#line 5041 "configure"
252b5132
RH
5041#include "confdefs.h"
5042#include <sys/types.h>
5043#ifdef HAVE_TIME_H
5044#include <time.h>
5045#endif
5046#include <utime.h>
5047int main() {
5048struct utimbuf s;
5049; return 0; }
5050EOF
d64552c5 5051if { (eval echo configure:5052: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
252b5132
RH
5052 rm -rf conftest*
5053 bu_cv_header_utime_h=yes
5054else
5055 echo "configure: failed program was:" >&5
5056 cat conftest.$ac_ext >&5
5057 rm -rf conftest*
5058 bu_cv_header_utime_h=no
5059fi
5060rm -f conftest*
5061fi
5062
5063echo "$ac_t""$bu_cv_header_utime_h" 1>&6
5064if test $bu_cv_header_utime_h = yes; then
5065 cat >> confdefs.h <<\EOF
5066#define HAVE_GOOD_UTIME_H 1
5067EOF
5068
5069fi
5070
5071echo $ac_n "checking whether fprintf must be declared""... $ac_c" 1>&6
d64552c5 5072echo "configure:5073: checking whether fprintf must be declared" >&5
252b5132
RH
5073if eval "test \"`echo '$''{'bfd_cv_decl_needed_fprintf'+set}'`\" = set"; then
5074 echo $ac_n "(cached) $ac_c" 1>&6
5075else
5076 cat > conftest.$ac_ext <<EOF
d64552c5 5077#line 5078 "configure"
252b5132
RH
5078#include "confdefs.h"
5079
5080#include <stdio.h>
5081#ifdef HAVE_STRING_H
5082#include <string.h>
5083#else
5084#ifdef HAVE_STRINGS_H
5085#include <strings.h>
5086#endif
5087#endif
5088#ifdef HAVE_STDLIB_H
5089#include <stdlib.h>
5090#endif
5091#ifdef HAVE_UNISTD_H
5092#include <unistd.h>
5093#endif
5094int main() {
5095char *(*pfn) = (char *(*)) fprintf
5096; return 0; }
5097EOF
d64552c5 5098if { (eval echo configure:5099: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
252b5132
RH
5099 rm -rf conftest*
5100 bfd_cv_decl_needed_fprintf=no
5101else
5102 echo "configure: failed program was:" >&5
5103 cat conftest.$ac_ext >&5
5104 rm -rf conftest*
5105 bfd_cv_decl_needed_fprintf=yes
5106fi
5107rm -f conftest*
5108fi
5109
5110echo "$ac_t""$bfd_cv_decl_needed_fprintf" 1>&6
5111if test $bfd_cv_decl_needed_fprintf = yes; then
5112 cat >> confdefs.h <<\EOF
5113#define NEED_DECLARATION_FPRINTF 1
5114EOF
5115
5116fi
5117
5118echo $ac_n "checking whether strstr must be declared""... $ac_c" 1>&6
d64552c5 5119echo "configure:5120: checking whether strstr must be declared" >&5
252b5132
RH
5120if eval "test \"`echo '$''{'bfd_cv_decl_needed_strstr'+set}'`\" = set"; then
5121 echo $ac_n "(cached) $ac_c" 1>&6
5122else
5123 cat > conftest.$ac_ext <<EOF
d64552c5 5124#line 5125 "configure"
252b5132
RH
5125#include "confdefs.h"
5126
5127#include <stdio.h>
5128#ifdef HAVE_STRING_H
5129#include <string.h>
5130#else
5131#ifdef HAVE_STRINGS_H
5132#include <strings.h>
5133#endif
5134#endif
5135#ifdef HAVE_STDLIB_H
5136#include <stdlib.h>
5137#endif
5138#ifdef HAVE_UNISTD_H
5139#include <unistd.h>
5140#endif
5141int main() {
5142char *(*pfn) = (char *(*)) strstr
5143; return 0; }
5144EOF
d64552c5 5145if { (eval echo configure:5146: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
252b5132
RH
5146 rm -rf conftest*
5147 bfd_cv_decl_needed_strstr=no
5148else
5149 echo "configure: failed program was:" >&5
5150 cat conftest.$ac_ext >&5
5151 rm -rf conftest*
5152 bfd_cv_decl_needed_strstr=yes
5153fi
5154rm -f conftest*
5155fi
5156
5157echo "$ac_t""$bfd_cv_decl_needed_strstr" 1>&6
5158if test $bfd_cv_decl_needed_strstr = yes; then
5159 cat >> confdefs.h <<\EOF
5160#define NEED_DECLARATION_STRSTR 1
5161EOF
5162
5163fi
5164
5165echo $ac_n "checking whether sbrk must be declared""... $ac_c" 1>&6
d64552c5 5166echo "configure:5167: checking whether sbrk must be declared" >&5
252b5132
RH
5167if eval "test \"`echo '$''{'bfd_cv_decl_needed_sbrk'+set}'`\" = set"; then
5168 echo $ac_n "(cached) $ac_c" 1>&6
5169else
5170 cat > conftest.$ac_ext <<EOF
d64552c5 5171#line 5172 "configure"
252b5132
RH
5172#include "confdefs.h"
5173
5174#include <stdio.h>
5175#ifdef HAVE_STRING_H
5176#include <string.h>
5177#else
5178#ifdef HAVE_STRINGS_H
5179#include <strings.h>
5180#endif
5181#endif
5182#ifdef HAVE_STDLIB_H
5183#include <stdlib.h>
5184#endif
5185#ifdef HAVE_UNISTD_H
5186#include <unistd.h>
5187#endif
5188int main() {
5189char *(*pfn) = (char *(*)) sbrk
5190; return 0; }
5191EOF
d64552c5 5192if { (eval echo configure:5193: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
252b5132
RH
5193 rm -rf conftest*
5194 bfd_cv_decl_needed_sbrk=no
5195else
5196 echo "configure: failed program was:" >&5
5197 cat conftest.$ac_ext >&5
5198 rm -rf conftest*
5199 bfd_cv_decl_needed_sbrk=yes
5200fi
5201rm -f conftest*
5202fi
5203
5204echo "$ac_t""$bfd_cv_decl_needed_sbrk" 1>&6
5205if test $bfd_cv_decl_needed_sbrk = yes; then
5206 cat >> confdefs.h <<\EOF
5207#define NEED_DECLARATION_SBRK 1
5208EOF
5209
5210fi
5211
5212echo $ac_n "checking whether getenv must be declared""... $ac_c" 1>&6
d64552c5 5213echo "configure:5214: checking whether getenv must be declared" >&5
252b5132
RH
5214if eval "test \"`echo '$''{'bfd_cv_decl_needed_getenv'+set}'`\" = set"; then
5215 echo $ac_n "(cached) $ac_c" 1>&6
5216else
5217 cat > conftest.$ac_ext <<EOF
d64552c5 5218#line 5219 "configure"
252b5132
RH
5219#include "confdefs.h"
5220
5221#include <stdio.h>
5222#ifdef HAVE_STRING_H
5223#include <string.h>
5224#else
5225#ifdef HAVE_STRINGS_H
5226#include <strings.h>
5227#endif
5228#endif
5229#ifdef HAVE_STDLIB_H
5230#include <stdlib.h>
5231#endif
5232#ifdef HAVE_UNISTD_H
5233#include <unistd.h>
5234#endif
5235int main() {
5236char *(*pfn) = (char *(*)) getenv
5237; return 0; }
5238EOF
d64552c5 5239if { (eval echo configure:5240: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
252b5132
RH
5240 rm -rf conftest*
5241 bfd_cv_decl_needed_getenv=no
5242else
5243 echo "configure: failed program was:" >&5
5244 cat conftest.$ac_ext >&5
5245 rm -rf conftest*
5246 bfd_cv_decl_needed_getenv=yes
5247fi
5248rm -f conftest*
5249fi
5250
5251echo "$ac_t""$bfd_cv_decl_needed_getenv" 1>&6
5252if test $bfd_cv_decl_needed_getenv = yes; then
5253 cat >> confdefs.h <<\EOF
5254#define NEED_DECLARATION_GETENV 1
5255EOF
5256
5257fi
5258
5259echo $ac_n "checking whether environ must be declared""... $ac_c" 1>&6
d64552c5 5260echo "configure:5261: checking whether environ must be declared" >&5
252b5132
RH
5261if eval "test \"`echo '$''{'bfd_cv_decl_needed_environ'+set}'`\" = set"; then
5262 echo $ac_n "(cached) $ac_c" 1>&6
5263else
5264 cat > conftest.$ac_ext <<EOF
d64552c5 5265#line 5266 "configure"
252b5132
RH
5266#include "confdefs.h"
5267
5268#include <stdio.h>
5269#ifdef HAVE_STRING_H
5270#include <string.h>
5271#else
5272#ifdef HAVE_STRINGS_H
5273#include <strings.h>
5274#endif
5275#endif
5276#ifdef HAVE_STDLIB_H
5277#include <stdlib.h>
5278#endif
5279#ifdef HAVE_UNISTD_H
5280#include <unistd.h>
5281#endif
5282int main() {
5283char *(*pfn) = (char *(*)) environ
5284; return 0; }
5285EOF
d64552c5 5286if { (eval echo configure:5287: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
252b5132
RH
5287 rm -rf conftest*
5288 bfd_cv_decl_needed_environ=no
5289else
5290 echo "configure: failed program was:" >&5
5291 cat conftest.$ac_ext >&5
5292 rm -rf conftest*
5293 bfd_cv_decl_needed_environ=yes
5294fi
5295rm -f conftest*
5296fi
5297
5298echo "$ac_t""$bfd_cv_decl_needed_environ" 1>&6
5299if test $bfd_cv_decl_needed_environ = yes; then
5300 cat >> confdefs.h <<\EOF
5301#define NEED_DECLARATION_ENVIRON 1
5302EOF
5303
5304fi
5305
5306
5307
5308case "${host}" in
8a965946 5309*-*-msdos* | *-*-go32* | *-*-mingw32* | *-*-cygwin* | *-*-windows*)
252b5132
RH
5310 cat >> confdefs.h <<\EOF
5311#define USE_BINARY_FOPEN 1
5312EOF
5313 ;;
5314esac
5315
5316# target-specific stuff:
5317
5318# Canonicalize the secondary target names.
5319if test -n "$enable_targets"; then
5320 for targ in `echo $enable_targets | sed 's/,/ /g'`
5321 do
6d83c84b 5322 result=`$ac_config_sub $targ 2>/dev/null`
252b5132
RH
5323 if test -n "$result"; then
5324 canon_targets="$canon_targets $result"
5325 else
5326 # Allow targets that config.sub doesn't recognize, like "all".
5327 canon_targets="$canon_targets $targ"
5328 fi
5329 done
5330fi
5331
5332all_targets=false
5333BUILD_NLMCONV=
5334NLMCONV_DEFS=
5335BUILD_SRCONV=
5336BUILD_DLLTOOL=
5337DLLTOOL_DEFS=
5338BUILD_WINDRES=
5339BUILD_DLLWRAP=
5340BUILD_MISC=
5341
5342for targ in $target $canon_targets
5343do
5344 if test "x$targ" = "xall"; then
5345 all_targets=true
5346 BUILD_NLMCONV='$(NLMCONV_PROG)$(EXEEXT)'
5347 BUILD_SRCONV='$(SRCONV_PROG)'
5348 NLMCONV_DEFS="-DNLMCONV_I386 -DNLMCONV_ALPHA -DNLMCONV_POWERPC -DNLMCONV_SPARC"
5349 else
5350 case $targ in
5351 i[3456]86*-*-netware*)
5352 BUILD_NLMCONV='$(NLMCONV_PROG)$(EXEEXT)'
5353 NLMCONV_DEFS="$NLMCONV_DEFS -DNLMCONV_I386"
5354 ;;
5355 alpha*-*-netware*)
5356 BUILD_NLMCONV='$(NLMCONV_PROG)$(EXEEXT)'
5357 NLMCONV_DEFS="$NLMCONV_DEFS -DNLMCONV_ALPHA"
5358 ;;
5359 powerpc*-*-netware*)
5360 BUILD_NLMCONV='$(NLMCONV_PROG)$(EXEEXT)'
5361 NLMCONV_DEFS="$NLMCONV_DEFS -DNLMCONV_POWERPC"
5362 ;;
5363 sparc*-*-netware*)
5364 BUILD_NLMCONV='$(NLMCONV_PROG)$(EXEEXT)'
5365 NLMCONV_DEFS="$NLMCONV_DEFS -DNLMCONV_SPARC"
5366 ;;
5367 esac
5368 case $targ in
5369 *-*-hms*) BUILD_SRCONV='$(SRCONV_PROG)' ;;
5370 esac
5371 case $targ in
8a0e0f38 5372 arm-*pe* | arm-*-wince)
252b5132
RH
5373 BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
5374 DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_ARM"
5375 BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
7a7b06ef 5376 ;;
252b5132
RH
5377 thumb-*pe*)
5378 BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
5379 DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_ARM"
5380 BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
7a7b06ef 5381 ;;
252b5132
RH
5382 i[3-6]86-*pe* | i[3-6]86-*-cygwin* | i[3-6]86-*-mingw32*)
5383 BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
5384 DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_I386"
5385 BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
5386 BUILD_DLLWRAP='$(DLLWRAP_PROG)$(EXEEXT)'
7a7b06ef
ILT
5387 ;;
5388 i3-686-*-interix)
5389 BUILD_DLLTOOL='$(DLLTOOL_PROG)'
5390 DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_I386"
5391 ;;
252b5132
RH
5392 powerpc*-*-*pe* | powerpc*-*-cygwin*)
5393 BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
5394 DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_PPC"
5395 BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
8a0e0f38
NC
5396 ;;
5397 sh*-*-*pe)
5398 BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
5399 DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_SH"
5400 BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
5401 ;;
5402 mips*-*-*pe)
5403 BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
5404 DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_MIPS"
5405 BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
7a7b06ef 5406 ;;
661016bb
NC
5407 mcore-*pe)
5408 BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
5409 DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_MCORE"
5410 BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
7a7b06ef 5411 ;;
661016bb
NC
5412 mcore-*elf)
5413 BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
5414 DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_MCORE_ELF"
7a7b06ef 5415 ;;
252b5132
RH
5416 esac
5417 fi
5418done
5419
5420
5421
5422
5423
5424
5425
5426
5427
5428
5429cat >> confdefs.h <<EOF
5430#define TARGET "${target}"
5431EOF
5432
5433
5434targ=$target
5435. $srcdir/../bfd/config.bfd
5436if test "x$targ_underscore" = "xyes"; then
5437 UNDERSCORE=1
5438else
5439 UNDERSCORE=0
5440fi
5441
5442
5443trap '' 1 2 15
5444cat > confcache <<\EOF
5445# This file is a shell script that caches the results of configure
5446# tests run on this system so they can be shared between configure
5447# scripts and configure runs. It is not useful on other systems.
5448# If it contains results you don't want to keep, you may remove or edit it.
5449#
5450# By default, configure uses ./config.cache as the cache file,
5451# creating it if it does not exist already. You can give configure
5452# the --cache-file=FILE option to use a different cache file; that is
5453# what configure does when it calls configure scripts in
5454# subdirectories, so they share the cache.
5455# Giving --cache-file=/dev/null disables caching, for debugging configure.
5456# config.status only pays attention to the cache file if you give it the
5457# --recheck option to rerun configure.
5458#
5459EOF
5460# The following way of writing the cache mishandles newlines in values,
5461# but we know of no workaround that is simple, portable, and efficient.
5462# So, don't put newlines in cache variables' values.
5463# Ultrix sh set writes to stderr and can't be redirected directly,
5464# and sets the high bit in the cache file unless we assign to the vars.
5465(set) 2>&1 |
5466 case `(ac_space=' '; set | grep ac_space) 2>&1` in
5467 *ac_space=\ *)
5468 # `set' does not quote correctly, so add quotes (double-quote substitution
5469 # turns \\\\ into \\, and sed turns \\ into \).
5470 sed -n \
5471 -e "s/'/'\\\\''/g" \
5472 -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
5473 ;;
5474 *)
5475 # `set' quotes correctly as required by POSIX, so do not add quotes.
5476 sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
5477 ;;
5478 esac >> confcache
5479if cmp -s $cache_file confcache; then
5480 :
5481else
5482 if test -w $cache_file; then
5483 echo "updating cache $cache_file"
5484 cat confcache > $cache_file
5485 else
5486 echo "not updating unwritable cache $cache_file"
5487 fi
5488fi
5489rm -f confcache
5490
5491trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
5492
5493test "x$prefix" = xNONE && prefix=$ac_default_prefix
5494# Let make expand exec_prefix.
5495test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
5496
5497# Any assignment to VPATH causes Sun make to only execute
5498# the first set of double-colon rules, so remove it if not needed.
5499# If there is a colon in the path, we need to keep it.
5500if test "x$srcdir" = x.; then
5501 ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
5502fi
5503
5504trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
5505
5506DEFS=-DHAVE_CONFIG_H
5507
5508# Without the "./", some shells look in PATH for config.status.
5509: ${CONFIG_STATUS=./config.status}
5510
5511echo creating $CONFIG_STATUS
5512rm -f $CONFIG_STATUS
5513cat > $CONFIG_STATUS <<EOF
5514#! /bin/sh
5515# Generated automatically by configure.
5516# Run this file to recreate the current configuration.
5517# This directory was configured as follows,
5518# on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
5519#
5520# $0 $ac_configure_args
5521#
5522# Compiler output produced by configure, useful for debugging
5523# configure, is in ./config.log if it exists.
5524
5525ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
5526for ac_option
5527do
5528 case "\$ac_option" in
5529 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
5530 echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
5531 exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
5532 -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
5533 echo "$CONFIG_STATUS generated by autoconf version 2.13"
5534 exit 0 ;;
5535 -help | --help | --hel | --he | --h)
5536 echo "\$ac_cs_usage"; exit 0 ;;
5537 *) echo "\$ac_cs_usage"; exit 1 ;;
5538 esac
5539done
5540
5541ac_given_srcdir=$srcdir
5542ac_given_INSTALL="$INSTALL"
5543
5544trap 'rm -fr `echo "Makefile po/Makefile.in:po/Make-in config.h:config.in" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
5545EOF
5546cat >> $CONFIG_STATUS <<EOF
5547
5548# Protect against being on the right side of a sed subst in config.status.
5549sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
5550 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
5551$ac_vpsub
5552$extrasub
5553s%@SHELL@%$SHELL%g
5554s%@CFLAGS@%$CFLAGS%g
5555s%@CPPFLAGS@%$CPPFLAGS%g
5556s%@CXXFLAGS@%$CXXFLAGS%g
5557s%@FFLAGS@%$FFLAGS%g
5558s%@DEFS@%$DEFS%g
5559s%@LDFLAGS@%$LDFLAGS%g
5560s%@LIBS@%$LIBS%g
5561s%@exec_prefix@%$exec_prefix%g
5562s%@prefix@%$prefix%g
5563s%@program_transform_name@%$program_transform_name%g
5564s%@bindir@%$bindir%g
5565s%@sbindir@%$sbindir%g
5566s%@libexecdir@%$libexecdir%g
5567s%@datadir@%$datadir%g
5568s%@sysconfdir@%$sysconfdir%g
5569s%@sharedstatedir@%$sharedstatedir%g
5570s%@localstatedir@%$localstatedir%g
5571s%@libdir@%$libdir%g
5572s%@includedir@%$includedir%g
5573s%@oldincludedir@%$oldincludedir%g
5574s%@infodir@%$infodir%g
5575s%@mandir@%$mandir%g
5576s%@host@%$host%g
5577s%@host_alias@%$host_alias%g
5578s%@host_cpu@%$host_cpu%g
5579s%@host_vendor@%$host_vendor%g
5580s%@host_os@%$host_os%g
5581s%@target@%$target%g
5582s%@target_alias@%$target_alias%g
5583s%@target_cpu@%$target_cpu%g
5584s%@target_vendor@%$target_vendor%g
5585s%@target_os@%$target_os%g
5586s%@build@%$build%g
5587s%@build_alias@%$build_alias%g
5588s%@build_cpu@%$build_cpu%g
5589s%@build_vendor@%$build_vendor%g
5590s%@build_os@%$build_os%g
5d64ca4e 5591s%@CC@%$CC%g
252b5132
RH
5592s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
5593s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
5594s%@INSTALL_DATA@%$INSTALL_DATA%g
5595s%@PACKAGE@%$PACKAGE%g
5596s%@VERSION@%$VERSION%g
5597s%@ACLOCAL@%$ACLOCAL%g
5598s%@AUTOCONF@%$AUTOCONF%g
5599s%@AUTOMAKE@%$AUTOMAKE%g
5600s%@AUTOHEADER@%$AUTOHEADER%g
5601s%@MAKEINFO@%$MAKEINFO%g
5602s%@SET_MAKE@%$SET_MAKE%g
252b5132 5603s%@LN_S@%$LN_S%g
ac48eca1
AO
5604s%@OBJEXT@%$OBJEXT%g
5605s%@EXEEXT@%$EXEEXT%g
5606s%@RANLIB@%$RANLIB%g
5607s%@STRIP@%$STRIP%g
252b5132 5608s%@LIBTOOL@%$LIBTOOL%g
a2d91340 5609s%@WARN_CFLAGS@%$WARN_CFLAGS%g
252b5132
RH
5610s%@YACC@%$YACC%g
5611s%@LEX@%$LEX%g
5612s%@LEXLIB@%$LEXLIB%g
5613s%@CPP@%$CPP%g
5614s%@LEX_OUTPUT_ROOT@%$LEX_OUTPUT_ROOT%g
5615s%@ALLOCA@%$ALLOCA%g
5616s%@USE_NLS@%$USE_NLS%g
5617s%@MSGFMT@%$MSGFMT%g
5618s%@GMSGFMT@%$GMSGFMT%g
5619s%@XGETTEXT@%$XGETTEXT%g
5620s%@USE_INCLUDED_LIBINTL@%$USE_INCLUDED_LIBINTL%g
5621s%@CATALOGS@%$CATALOGS%g
5622s%@CATOBJEXT@%$CATOBJEXT%g
5623s%@DATADIRNAME@%$DATADIRNAME%g
5624s%@GMOFILES@%$GMOFILES%g
5625s%@INSTOBJEXT@%$INSTOBJEXT%g
5626s%@INTLDEPS@%$INTLDEPS%g
5627s%@INTLLIBS@%$INTLLIBS%g
5628s%@INTLOBJS@%$INTLOBJS%g
5629s%@POFILES@%$POFILES%g
5630s%@POSUB@%$POSUB%g
5631s%@INCLUDE_LOCALE_H@%$INCLUDE_LOCALE_H%g
5632s%@GT_NO@%$GT_NO%g
5633s%@GT_YES@%$GT_YES%g
5634s%@MKINSTALLDIRS@%$MKINSTALLDIRS%g
5635s%@l@%$l%g
5636s%@MAINTAINER_MODE_TRUE@%$MAINTAINER_MODE_TRUE%g
5637s%@MAINTAINER_MODE_FALSE@%$MAINTAINER_MODE_FALSE%g
5638s%@MAINT@%$MAINT%g
252b5132
RH
5639s%@HDEFINES@%$HDEFINES%g
5640s%@AR@%$AR%g
5641s%@CC_FOR_BUILD@%$CC_FOR_BUILD%g
5642s%@EXEEXT_FOR_BUILD@%$EXEEXT_FOR_BUILD%g
8a965946 5643s%@DEMANGLER_NAME@%$DEMANGLER_NAME%g
252b5132
RH
5644s%@NLMCONV_DEFS@%$NLMCONV_DEFS%g
5645s%@BUILD_NLMCONV@%$BUILD_NLMCONV%g
5646s%@BUILD_SRCONV@%$BUILD_SRCONV%g
5647s%@BUILD_DLLTOOL@%$BUILD_DLLTOOL%g
5648s%@DLLTOOL_DEFS@%$DLLTOOL_DEFS%g
5649s%@BUILD_WINDRES@%$BUILD_WINDRES%g
5650s%@BUILD_DLLWRAP@%$BUILD_DLLWRAP%g
5651s%@BUILD_MISC@%$BUILD_MISC%g
5652s%@UNDERSCORE@%$UNDERSCORE%g
5653
5654CEOF
5655EOF
5656
5657cat >> $CONFIG_STATUS <<\EOF
5658
5659# Split the substitutions into bite-sized pieces for seds with
5660# small command number limits, like on Digital OSF/1 and HP-UX.
5661ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
5662ac_file=1 # Number of current file.
5663ac_beg=1 # First line for current file.
5664ac_end=$ac_max_sed_cmds # Line after last line for current file.
5665ac_more_lines=:
5666ac_sed_cmds=""
5667while $ac_more_lines; do
5668 if test $ac_beg -gt 1; then
5669 sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
5670 else
5671 sed "${ac_end}q" conftest.subs > conftest.s$ac_file
5672 fi
5673 if test ! -s conftest.s$ac_file; then
5674 ac_more_lines=false
5675 rm -f conftest.s$ac_file
5676 else
5677 if test -z "$ac_sed_cmds"; then
5678 ac_sed_cmds="sed -f conftest.s$ac_file"
5679 else
5680 ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
5681 fi
5682 ac_file=`expr $ac_file + 1`
5683 ac_beg=$ac_end
5684 ac_end=`expr $ac_end + $ac_max_sed_cmds`
5685 fi
5686done
5687if test -z "$ac_sed_cmds"; then
5688 ac_sed_cmds=cat
5689fi
5690EOF
5691
5692cat >> $CONFIG_STATUS <<EOF
5693
5694CONFIG_FILES=\${CONFIG_FILES-"Makefile po/Makefile.in:po/Make-in"}
5695EOF
5696cat >> $CONFIG_STATUS <<\EOF
5697for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
5698 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
5699 case "$ac_file" in
5700 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
5701 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
5702 *) ac_file_in="${ac_file}.in" ;;
5703 esac
5704
5705 # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
5706
5707 # Remove last slash and all that follows it. Not all systems have dirname.
5708 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
5709 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
5710 # The file is in a subdirectory.
5711 test ! -d "$ac_dir" && mkdir "$ac_dir"
5712 ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
5713 # A "../" for each directory in $ac_dir_suffix.
5714 ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
5715 else
5716 ac_dir_suffix= ac_dots=
5717 fi
5718
5719 case "$ac_given_srcdir" in
5720 .) srcdir=.
5721 if test -z "$ac_dots"; then top_srcdir=.
5722 else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
5723 /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
5724 *) # Relative path.
5725 srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
5726 top_srcdir="$ac_dots$ac_given_srcdir" ;;
5727 esac
5728
5729 case "$ac_given_INSTALL" in
5730 [/$]*) INSTALL="$ac_given_INSTALL" ;;
5731 *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
5732 esac
5733
5734 echo creating "$ac_file"
5735 rm -f "$ac_file"
5736 configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
5737 case "$ac_file" in
5738 *Makefile*) ac_comsub="1i\\
5739# $configure_input" ;;
5740 *) ac_comsub= ;;
5741 esac
5742
5743 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
5744 sed -e "$ac_comsub
5745s%@configure_input@%$configure_input%g
5746s%@srcdir@%$srcdir%g
5747s%@top_srcdir@%$top_srcdir%g
5748s%@INSTALL@%$INSTALL%g
5749" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
5750fi; done
5751rm -f conftest.s*
5752
5753# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
5754# NAME is the cpp macro being defined and VALUE is the value it is being given.
5755#
5756# ac_d sets the value in "#define NAME VALUE" lines.
5757ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)'
5758ac_dB='\([ ][ ]*\)[^ ]*%\1#\2'
5759ac_dC='\3'
5760ac_dD='%g'
5761# ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
5762ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
5763ac_uB='\([ ]\)%\1#\2define\3'
5764ac_uC=' '
5765ac_uD='\4%g'
5766# ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
5767ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
5768ac_eB='$%\1#\2define\3'
5769ac_eC=' '
5770ac_eD='%g'
5771
5772if test "${CONFIG_HEADERS+set}" != set; then
5773EOF
5774cat >> $CONFIG_STATUS <<EOF
5775 CONFIG_HEADERS="config.h:config.in"
5776EOF
5777cat >> $CONFIG_STATUS <<\EOF
5778fi
5779for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
5780 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
5781 case "$ac_file" in
5782 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
5783 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
5784 *) ac_file_in="${ac_file}.in" ;;
5785 esac
5786
5787 echo creating $ac_file
5788
5789 rm -f conftest.frag conftest.in conftest.out
5790 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
5791 cat $ac_file_inputs > conftest.in
5792
5793EOF
5794
5795# Transform confdefs.h into a sed script conftest.vals that substitutes
5796# the proper values into config.h.in to produce config.h. And first:
5797# Protect against being on the right side of a sed subst in config.status.
5798# Protect against being in an unquoted here document in config.status.
5799rm -f conftest.vals
5800cat > conftest.hdr <<\EOF
5801s/[\\&%]/\\&/g
5802s%[\\$`]%\\&%g
5803s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
5804s%ac_d%ac_u%gp
5805s%ac_u%ac_e%gp
5806EOF
5807sed -n -f conftest.hdr confdefs.h > conftest.vals
5808rm -f conftest.hdr
5809
5810# This sed command replaces #undef with comments. This is necessary, for
5811# example, in the case of _POSIX_SOURCE, which is predefined and required
5812# on some systems where configure will not decide to define it.
5813cat >> conftest.vals <<\EOF
5814s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
5815EOF
5816
5817# Break up conftest.vals because some shells have a limit on
5818# the size of here documents, and old seds have small limits too.
5819
5820rm -f conftest.tail
5821while :
5822do
5823 ac_lines=`grep -c . conftest.vals`
5824 # grep -c gives empty output for an empty file on some AIX systems.
5825 if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
5826 # Write a limited-size here document to conftest.frag.
5827 echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
5828 sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
5829 echo 'CEOF
5830 sed -f conftest.frag conftest.in > conftest.out
5831 rm -f conftest.in
5832 mv conftest.out conftest.in
5833' >> $CONFIG_STATUS
5834 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
5835 rm -f conftest.vals
5836 mv conftest.tail conftest.vals
5837done
5838rm -f conftest.vals
5839
5840cat >> $CONFIG_STATUS <<\EOF
5841 rm -f conftest.frag conftest.h
5842 echo "/* $ac_file. Generated automatically by configure. */" > conftest.h
5843 cat conftest.in >> conftest.h
5844 rm -f conftest.in
5845 if cmp -s $ac_file conftest.h 2>/dev/null; then
5846 echo "$ac_file is unchanged"
5847 rm -f conftest.h
5848 else
5849 # Remove last slash and all that follows it. Not all systems have dirname.
5850 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
5851 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
5852 # The file is in a subdirectory.
5853 test ! -d "$ac_dir" && mkdir "$ac_dir"
5854 fi
5855 rm -f $ac_file
5856 mv conftest.h $ac_file
5857 fi
5858fi; done
5859
5860EOF
5861cat >> $CONFIG_STATUS <<EOF
5862
5863
5864EOF
5865cat >> $CONFIG_STATUS <<\EOF
5866test -z "$CONFIG_HEADERS" || echo timestamp > stamp-h
5867
5868case "x$CONFIG_FILES" in
5869*) sed -e '/POTFILES =/r po/POTFILES' po/Makefile.in > po/Makefile ;;
5870esac
5871
5872exit 0
5873EOF
5874chmod +x $CONFIG_STATUS
5875rm -fr confdefs* $ac_clean_files
5876test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
5877
This page took 0.29147 seconds and 4 git commands to generate.