source: trunk/src/binutils/ld/configure@ 1796

Last change on this file since 1796 was 1124, checked in by bird, 22 years ago

Regenerated with new autoconf (forced to use stable).

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