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