From K. Richard Pixley <rich@noir.com>:
[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=
ac50feda 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
ac50feda 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
ac50feda
RH
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.
ac50feda
RH
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
ac50feda
RH
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
ac50feda 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
ac50feda 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
ac50feda 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
ac50feda 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
ac50feda 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
ac50feda 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
819VERSION=2.9.4
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
ac50feda 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
ac50feda 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
ac50feda 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
ac50feda 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
ac50feda 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
ac50feda 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
ac50feda 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
ac50feda 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
ac50feda 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
ac50feda 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
ac50feda 1128#line 1129 "configure"
252b5132
RH
1129#include "confdefs.h"
1130
1131main(){return(0);}
1132EOF
ac50feda 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
ac50feda 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
ac50feda 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
ac50feda 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
ac50feda 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
ac50feda 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
ac50feda 1259echo "configure:1260: checking for GNU ld" >&5
252b5132
RH
1260else
1261 echo $ac_n "checking for non-GNU ld""... $ac_c" 1>&6
ac50feda 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
ac50feda 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
ac50feda 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
ac50feda 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
ac50feda 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
ac50feda 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"
ac50feda 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
ac50feda 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
ac50feda 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
ac50feda 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
ac50feda 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.
ac50feda
RH
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
ac50feda 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
ac50feda 1624#line 1625 "configure"
bedf545c
ILT
1625#include "confdefs.h"
1626
1627int main() {
1628
1629; return 0; }
1630EOF
ac50feda 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
ac50feda 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
ac50feda 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
ac50feda 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
ac50feda 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
1921te_file=generic
1922
1923# Makefile target for installing gas in $(tooldir)/bin.
1924install_tooldir=install-exec-tooldir
1925
1926canon_targets=""
1927if test -n "$enable_targets" ; then
1928 for t in `echo $enable_targets | sed 's/,/ /g'`; do
1929 result=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $t 2>/dev/null`
1930 if test -n "$result" ; then
1931 canon_targets="$canon_targets $result"
1932# else
1933# # Permit "all", etc. We don't support it yet though.
1934# canon_targets="$canon_targets $t"
1935 fi
1936 done
1937 _gas_uniq_list="$canon_targets"
1938_gas_uniq_newlist=""
1939for _gas_uniq_i in _gas_uniq_dummy $_gas_uniq_list ; do
1940 case $_gas_uniq_i in
1941 _gas_uniq_dummy) ;;
1942 *) case " $_gas_uniq_newlist " in
1943 *" $_gas_uniq_i "*) ;;
1944 *) _gas_uniq_newlist="$_gas_uniq_newlist $_gas_uniq_i" ;;
1945 esac ;;
1946 esac
1947done
1948canon_targets=$_gas_uniq_newlist
1949
1950fi
1951
1952emulations=""
1953
1954for this_target in $target $canon_targets ; do
1955
1956 eval `echo $this_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/cpu=\1 vendor=\2 os=\3/'`
1957
1958 # check for architecture variants
1959 arch=
1960 endian=
1961 case ${cpu} in
1962 alpha*) cpu_type=alpha ;;
1963 armeb) cpu_type=arm endian=big ;;
1964 arm*) cpu_type=arm endian=little ;;
1965 armb*) cpu_type=arm endian=little ;;
1966 armv*l) cpu_type=arm endian=little ;;
1967 armv*b) cpu_type=arm endian=big ;;
1968 strongarm*) cpu_type=arm endian=little ;;
1969 thumb*) cpu_type=arm endian=little ;;
1970 hppa*) cpu_type=hppa ;;
1971 i[456]86) cpu_type=i386 ;;
1972 m680[012346]0) cpu_type=m68k ;;
1973 m68008) cpu_type=m68k ;;
1974 m683??) cpu_type=m68k ;;
1975 m5200) cpu_type=m68k ;;
1976 m8*) cpu_type=m88k ;;
1977 mips*el) cpu_type=mips endian=little ;;
1978 mips*) cpu_type=mips endian=big ;;
1979 powerpcle*) cpu_type=ppc endian=little ;;
1980 powerpc*) cpu_type=ppc endian=big ;;
1981 rs6000*) cpu_type=ppc ;;
1982 sparclite*) cpu_type=sparc arch=sparclite ;;
1983 sparclet*) cpu_type=sparc arch=sparclet ;;
1984 sparc64*) cpu_type=sparc arch=v9-64 ;;
1985 sparc86x*) cpu_type=sparc arch=sparc86x ;;
1986 sparc*) cpu_type=sparc arch=sparclite ;; # ??? See tc-sparc.c.
1987 v850*) cpu_type=v850 ;;
1988 *) cpu_type=${cpu} ;;
1989 esac
1990
1991 if test ${this_target} = $target ; then
1992 target_cpu_type=${cpu_type}
1993 elif test ${target_cpu_type} != ${cpu_type} ; then
1994 continue
1995 fi
1996
1997 generic_target=${cpu_type}-$vendor-$os
1998 dev=no
1999 bfd_gas=no
2000 em=generic
2001
2002 # assign object format
2003 case ${generic_target} in
2004 a29k-*-coff) fmt=coff ;;
2005 a29k-amd-udi) fmt=coff ;;
2006 a29k-amd-ebmon) fmt=coff ;;
2007 a29k-nyu-sym1) fmt=coff ;;
2008 a29k-*-vxworks*) fmt=coff ;;
2009
2010 alpha*-*-*vms*) fmt=evax ;;
2011 alpha*-*-netware*) fmt=ecoff ;;
2012 alpha*-*-openbsd*) fmt=ecoff ;;
2013 alpha*-*-osf*) fmt=ecoff ;;
2014 alpha*-*-linuxecoff*) fmt=ecoff ;;
2015 alpha*-*-linux-gnu*) fmt=elf em=linux ;;
2016 alpha*-*-netbsd*) fmt=elf em=nbsd ;;
2017
2018 arc-*-elf*) fmt=elf bfd_gas=yes ;;
2019
2020 arm-*-aout) fmt=aout ;;
2021 arm-*-coff | thumb-*-coff) fmt=coff ;;
2022 arm-*-elf | thumb-*-elf) fmt=elf ;;
2023 arm-*-linux*aout*) fmt=aout em=linux ;;
2024 arm-*-linux* | armv*-*-linux-gnu) fmt=elf em=linux ;;
2025 arm-*-netbsd*) fmt=aout em=nbsd bfd_gas=yes ;;
2026 arm-*-oabi | thumb-*-oabi) fmt=elf ;;
2027 arm-epoc-pe | thumb-epoc-pe) fmt=coff em=epoc-pe ;;
2028 arm-*-pe | thumb-*-pe) fmt=coff em=pe ;;
2029 arm-*-riscix*) fmt=aout em=riscix ;;
2030
2031 d10v-*-*) fmt=elf bfd_gas=yes ;;
2032 d30v-*-*) fmt=elf bfd_gas=yes ;;
2033
2034
2035 fr30-*-*) fmt=elf bfd_gas=yes ;;
2036
2037 hppa-*-*elf*) fmt=elf em=hppa ;;
2038 hppa-*-lites*) fmt=elf em=hppa ;;
2039 hppa-*-osf*) fmt=som em=hppa ;;
2040 hppa-*-rtems*) fmt=elf em=hppa ;;
2041 hppa-*-hpux*) fmt=som em=hppa ;;
2042 hppa-*-mpeix*) fmt=som em=hppa ;;
2043 hppa-*-bsd*) fmt=som em=hppa ;;
2044 hppa-*-hiux*) fmt=som em=hppa ;;
2045
2046 h8300-*-coff) fmt=coff ;;
2047
2048 i386-ibm-aix*) fmt=coff em=i386aix ;;
2049 i386-sequent-bsd*) fmt=aout em=dynix bfd_gas=yes ;;
2050 i386-*-beospe*) fmt=coff em=pe bfd_gas=yes ;;
2051 i386-*-beoself* | i386-*-beos*) fmt=elf bfd_gas=yes ;;
2052 i386-*-bsd*) fmt=aout em=386bsd ;;
2053 i386-*-netbsd0.8) fmt=aout em=386bsd ;;
2054 i386-*-netbsd*) fmt=aout em=nbsd bfd_gas=yes;;
2055 i386-*-openbsd*) fmt=aout em=nbsd bfd_gas=yes;;
2056 i386-*-linux*aout* | i386-*-linuxoldld) fmt=aout em=linux ;;
2057 i386-*-linux*coff*) fmt=coff em=linux ;;
2058 i386-*-linux-gnu*) fmt=elf em=linux bfd_gas=yes ;;
2059 i386-*-lynxos*) fmt=coff em=lynx ;;
2060 i386-*-sysv4* | i386-*-solaris* | i386-*-elf)
2061 fmt=elf bfd_gas=yes ;;
008960a5
ILT
2062 i386-*-freebsdaout* | i386-*-freebsd12.* | i386-*-freebsd12)
2063 fmt=aout em=386bsd ;;
2064 i386-*-freebsd*) fmt=elf bfd_gas=yes ;;
252b5132
RH
2065 i386-*-coff | i386-*-sysv* | i386-*-sco3.2v5*coff | i386-*-isc*)
2066 fmt=coff ;;
2067 i386-*-sco3.2v5*) fmt=elf
2068 if test ${this_target} = $target; then
2069 cat >> confdefs.h <<\EOF
2070#define SCO_ELF 1
2071EOF
2072
2073 fi
2074 ;;
2075 i386-*-sco3.2*) fmt=coff ;;
2076 i386-*-vsta) fmt=aout ;;
2077 i386-*-msdosdjgpp* | i386-*-go32* | i386-go32-rtems*)
2078 fmt=coff em=go32;;
53f3de98 2079 i386-*-rtemself*) fmt=elf ;;
252b5132
RH
2080 i386-*-rtems*) fmt=coff ;;
2081 i386-*-gnu*) fmt=elf ;;
2082 i386-*-mach*)
2083 fmt=aout em=mach bfd_gas=yes ;;
2084 i386-*-msdos*) fmt=aout ;;
2085 i386-*-moss*) fmt=elf ;;
2086 i386-*-pe) fmt=coff em=pe ;;
2087 i386-*-cygwin*) fmt=coff em=pe bfd_gas=yes ;;
2088 i386-*-mingw32*) fmt=coff em=pe bfd_gas=yes ;;
2089 i386-*-*nt*) fmt=coff em=pe ;;
2090 i960-*-bout) fmt=bout ;;
2091 i960-*-coff) fmt=coff em=ic960 ;;
2092 i960-*-rtems*) fmt=coff em=ic960 ;;
2093 i960-*-nindy*) fmt=bout ;;
2094 i960-*-vxworks4*) fmt=bout ;;
2095 i960-*-vxworks5.0) fmt=bout ;;
2096 i960-*-vxworks5.*) fmt=coff em=ic960 ;;
2097 i960-*-vxworks*) fmt=bout ;;
bedf545c 2098 i960-*-elf*) fmt=elf ;;
252b5132
RH
2099
2100 m32r-*-*) fmt=elf bfd_gas=yes ;;
2101
2102 m68k-*-vxworks* | m68k-ericsson-ose | m68k-*-sunos*)
2103 fmt=aout em=sun3 ;;
2104 m68k-motorola-sysv*) fmt=coff em=delta ;;
2105 m68k-bull-sysv3*) fmt=coff em=dpx2 ;;
2106 m68k-apollo-*) fmt=coff em=apollo ;;
2107 m68k-*-sysv4*) # must be before -sysv*
2108 fmt=elf em=svr4 ;;
2109 m68k-*-elf*) fmt=elf ;;
2110 m68k-*-coff | m68k-*-sysv* | m68k-*-rtems*)
2111 fmt=coff ;;
2112 m68k-*-hpux*) fmt=hp300 em=hp300 ;;
2113 m68k-*-linux*aout*) fmt=aout em=linux ;;
2114 m68k-*-linux-gnu*) fmt=elf em=linux ;;
2115 m68k-*-gnu*) fmt=elf ;;
2116 m68k-*-lynxos*) fmt=coff em=lynx ;;
2117 m68k-*-netbsd*) fmt=aout em=nbsd bfd_gas=yes ;;
2118 m68k-*-openbsd*) fmt=aout em=nbsd bfd_gas=yes ;;
2119 m68k-apple-aux*) fmt=coff em=aux ;;
2120 m68k-*-psos*) fmt=elf em=psos;;
2121
2122 m88k-motorola-sysv3*) fmt=coff em=delt88 ;;
2123 m88k-*-coff*) fmt=coff ;;
2124
2125 mcore-*-elf) fmt=elf bfd_gas=yes ;;
2126 mcore-*-pe) fmt=coff em=pe bfd_gas=yes ;;
2127
2128 # don't change em like *-*-bsd does
2129 mips-dec-netbsd*) fmt=elf endian=little ;;
2130 mips-dec-openbsd*) fmt=elf endian=little ;;
2131 mips-dec-bsd*) fmt=aout endian=little ;;
2132 mips-sony-bsd*) fmt=ecoff ;;
2133 mips-*-bsd*) { echo "configure: error: Unknown vendor for mips-bsd configuration." 1>&2; exit 1; } ;;
2134 mips-*-ultrix*) fmt=ecoff endian=little ;;
2135 mips-*-osf*) fmt=ecoff endian=little ;;
2136 mips-*-ecoff*) fmt=ecoff ;;
2137 mips-*-ecoff*) fmt=ecoff ;;
2138 mips-*-irix6*) fmt=elf ;;
2139 mips-*-irix5*) fmt=elf ;;
2140 mips-*-irix*) fmt=ecoff ;;
2141 mips-*-lnews*) fmt=ecoff em=lnews ;;
2142 mips-*-riscos*) fmt=ecoff ;;
2143 mips-*-sysv*) fmt=ecoff ;;
2144 mips-*-elf* | mips-*-rtems* | mips-*-linux-gnu* | mips-*-gnu* | mips-*-openbsd*)
2145 fmt=elf ;;
2146 mips-*-vxworks*) fmt=elf
2147 cat >> confdefs.h <<\EOF
2148#define MIPS_STABS_ELF 1
2149EOF
2150
2151 ;;
2152 mn10200-*-*) fmt=elf bfd_gas=yes ;;
2153 mn10300-*-*) fmt=elf bfd_gas=yes ;;
2154 ppc-*-pe | ppc-*-cygwin* | ppc-*-winnt*)
2155 fmt=coff em=pe ;;
2156 ppc-*-aix*) fmt=coff ;;
2157 ppc-*-beos*) fmt=coff ;;
2158 ppc-*-*bsd* | ppc-*-elf* | ppc-*-eabi* | ppc-*-sysv4*)
2159 fmt=elf ;;
2160 ppc-*-linux-gnu*) fmt=elf
2161 case "$endian" in
2162 big) ;;
2163 *) { echo "configure: error: GNU/Linux must be configured big endian" 1>&2; exit 1; } ;;
2164 esac
2165 ;;
2166 ppc-*-solaris*) fmt=elf
2167 if test ${this_target} = $target; then
2168 cat >> confdefs.h <<\EOF
2169#define TARGET_SOLARIS_COMMENT 1
2170EOF
2171
2172 fi
2173 if test x${endian} = xbig; then
2174 { echo "configure: error: Solaris must be configured little endian" 1>&2; exit 1; }
2175 fi
2176 ;;
2177 ppc-*-rtems*) fmt=elf ;;
2178 ppc-*-macos* | ppc-*-mpw*)
2179 fmt=coff em=macos ;;
2180 ppc-*-netware*) fmt=elf em=ppcnw ;;
e4a86f6f 2181 ppc-*-vxworks*) fmt=elf ;;
252b5132
RH
2182
2183 sh-*-elf*) fmt=elf ;;
2184 sh-*-coff*) fmt=coff ;;
53f3de98 2185 sh-*-rtemself*) fmt=elf ;;
252b5132
RH
2186 sh-*-rtems*) fmt=coff ;;
2187
2188 ns32k-pc532-mach* | ns32k-pc532-ux*) fmt=aout em=pc532mach ;;
2189 ns32k-pc532-netbsd* | ns32k-pc532-lites*) fmt=aout em=nbsd532 ;;
2190 ns32k-pc532-openbsd*) fmt=aout em=nbsd532 ;;
2191
2192 sparc-*-rtems*) fmt=aout ;;
2193 sparc-*-sunos4*) fmt=aout em=sun3 ;;
2194 sparc-*-aout | sparc*-*-vxworks*)
2195 fmt=aout em=sparcaout ;;
2196 sparc-*-coff) fmt=coff ;;
2197 sparc-*-linux*aout*) fmt=aout em=linux ;;
2198 sparc-*-linux-gnu*) fmt=elf em=linux ;;
2199 sparc-*-lynxos*) fmt=coff em=lynx ;;
2200 sparc-fujitsu-none) fmt=aout ;;
2201 sparc-*-elf | sparc-*-sysv4* | sparc-*-solaris*)
2202 fmt=elf ;;
2203 sparc-*-netbsd*) fmt=aout em=nbsd ;;
2204 sparc-*-openbsd*) fmt=aout em=nbsd ;;
2205
2206 strongarm-*-coff) fmt=coff ;;
2207 strongarm-*-elf) fmt=elf ;;
2208
2209 tic30-*-*aout*) fmt=aout bfd_gas=yes ;;
2210 tic30-*-*coff*) fmt=coff bfd_gas=yes ;;
2211 tic80-*-*) fmt=coff ;;
2212
2213 v850-*-*) fmt=elf bfd_gas=yes ;;
2214 v850e-*-*) fmt=elf bfd_gas=yes ;;
2215 v850ea-*-*) fmt=elf bfd_gas=yes ;;
2216
2217 vax-*-bsd* | vax-*-ultrix*)
2218 fmt=aout ;;
2219 vax-*-vms) fmt=vms ;;
2220
2221
2222 z8k-*-coff | z8k-*-sim)
2223 fmt=coff ;;
2224
2225 w65-*-*) fmt=coff ;;
2226
2227 *-*-aout | *-*-scout)
2228 fmt=aout ;;
2229 *-*-nindy*)
2230 fmt=bout ;;
2231 *-*-bsd*)
2232 fmt=aout em=sun3 ;;
2233 *-*-generic) fmt=generic ;;
2234 *-*-xray | *-*-hms) fmt=coff ;;
2235 *-*-sim) fmt=coff ;;
2236 *-*-elf | *-*-sysv4* | *-*-solaris*)
2237 echo "configure: warning: GAS support for ${generic_target} is incomplete." 1>&2
2238 fmt=elf dev=yes ;;
2239 *-*-vxworks) fmt=aout ;;
2240 *-*-netware) fmt=elf ;;
2241 esac
2242
2243 if test ${this_target} = $target ; then
2244 endian_def=
2245 if test x${endian} = xbig; then
2246 endian_def=1
2247 elif test x${endian} = xlittle; then
2248 endian_def=0
2249 fi
2250 if test x${endian_def} != x; then
2251 cat >> confdefs.h <<EOF
2252#define TARGET_BYTES_BIG_ENDIAN $endian_def
2253EOF
2254
2255 fi
2256 fi
2257
2258 case ${cpu_type}-${fmt} in
2259 alpha*-*) bfd_gas=yes ;;
2260 arm-*) bfd_gas=yes ;;
2261 # not yet
2262 # i386-aout) bfd_gas=preferred ;;
2263 mips-*) bfd_gas=yes ;;
2264 ns32k-*) bfd_gas=yes ;;
2265 ppc-*) bfd_gas=yes ;;
2266 sparc-*) bfd_gas=yes ;;
2267 strongarm-*) bfd_gas=yes ;;
2268 *-elf) bfd_gas=yes ;;
2269 *-ecoff) bfd_gas=yes ;;
2270 *-som) bfd_gas=yes ;;
2271 *) ;;
2272 esac
2273
2274# Other random stuff.
2275
2276 # Do we need the opcodes library?
2277 case ${cpu_type} in
2278 vax | i386 | tic30)
2279 ;;
2280
2281 *)
2282 need_opcodes=yes
2283
2284 case "${enable_shared}" in
2285 yes) shared_opcodes=true ;;
2286 *opcodes*) shared_opcodes=true ;;
2287 *) shared_opcodes=false ;;
2288 esac
2289 if test "${shared_opcodes}" = "true"; then
2290 # A shared libopcodes must be linked against libbfd.
2291 need_bfd=yes
2292 fi
2293 ;;
2294 esac
2295
2296 # Any other special object files needed ?
2297 case ${cpu_type} in
2298 fr30 | m32r)
2299 using_cgen=yes
2300 ;;
2301
2302 m68k)
2303 case ${extra_objects} in
2304 *m68k-parse.o*) ;;
2305 *) extra_objects="$extra_objects m68k-parse.o" ;;
2306 esac
2307 ;;
2308
2309 mips)
2310 echo ${extra_objects} | grep -s "itbl-parse.o"
2311 if test $? -ne 0 ; then
2312 extra_objects="$extra_objects itbl-parse.o"
2313 fi
2314
2315 echo ${extra_objects} | grep -s "itbl-lex.o"
2316 if test $? -ne 0 ; then
2317 extra_objects="$extra_objects itbl-lex.o"
2318 fi
2319
2320 echo ${extra_objects} | grep -s "itbl-ops.o"
2321 if test $? -ne 0 ; then
2322 extra_objects="$extra_objects itbl-ops.o"
2323 fi
2324 ;;
2325
2326 sparc)
2327 if test $this_target = $target ; then
2328 cat >> confdefs.h <<EOF
2329#define DEFAULT_ARCH "${arch}"
2330EOF
2331
2332 fi
2333 ;;
2334 *)
2335 ;;
2336 esac
2337
2338 if test $using_cgen = yes ; then
2339 case "x${extra_objects}" in
2340 *cgen.o*) ;;
2341 *) extra_objects="$extra_objects cgen.o" ;;
2342 esac
2343 fi
2344
2345# See if we really can support this configuration with the emulation code.
2346
2347 if test $this_target = $target ; then
2348 primary_bfd_gas=$bfd_gas
2349 obj_format=$fmt
2350 te_file=$em
2351
2352 if test $bfd_gas = no ; then
2353 # Can't support other configurations this way.
2354 break
2355 fi
2356 elif test $bfd_gas = no ; then
2357 # Can't support this configuration.
2358 break
2359 fi
2360
2361# From target name and format, produce a list of supported emulations.
2362
2363 case ${generic_target}-${fmt} in
2364 mips-*-irix5*-*) emulation="mipsbelf mipslelf mipself mipsbecoff mipslecoff mipsecoff" ;;
2365 mips-*-linux-gnu*-*) case "$endian" in
2366 big) emulation="mipsbelf mipslelf mipself mipsbecoff mipslecoff mipsecoff" ;;
2367 *) emulation="mipslelf mipsbelf mipself mipslecoff mipsbecoff mipsecoff" ;;
2368 esac ;;
2369 mips-*-lnews*-ecoff) ;;
2370 mips-*-*-ecoff) case "$endian" in
2371 big) emulation="mipsbecoff mipslecoff mipsecoff" ;;
2372 *) emulation="mipslecoff mipsbecoff mipsecoff" ;;
2373 esac ;;
2374 mips-*-*-elf) case "$endian" in
2375 big) emulation="mipsbelf mipslelf mipself" ;;
2376 *) emulation="mipslelf mipsbelf mipself" ;;
2377 # Uncommenting the next line will turn on support for i386 COFF
2378 # in any i386 ELF configuration. This probably doesn't work
2379 # correctly.
2380 # i386-*-*-elf) emulation="i386coff i386elf" ;;
2381 esac ;;
2382 esac
2383
2384 emulations="$emulations $emulation"
2385
2386done
2387
2388# Assign floating point type. Most processors with FP support
2389# IEEE FP. On those that don't support FP at all, usually IEEE
2390# is emulated.
2391case ${target_cpu} in
2392 vax | tahoe ) atof=${target_cpu} ;;
2393 *) atof=ieee ;;
2394esac
2395
2396case "${obj_format}" in
2397 "") { echo "configure: error: GAS does not know what format to use for target ${target}" 1>&2; exit 1; } ;;
2398esac
2399
2400# Unfortunately the cpu in cpu-opc.h file isn't always $(TARGET_CPU).
2401cgen_cpu_prefix=""
2402if test $using_cgen = yes ; then
2403 case ${target_cpu} in
2404 *) cgen_cpu_prefix=${target_cpu} ;;
2405 esac
2406
2407 cat >> confdefs.h <<\EOF
2408#define USING_CGEN 1
2409EOF
2410
2411fi
2412
2413
2414if test ! -r ${srcdir}/config/tc-${target_cpu_type}.c; then
2415 { echo "configure: error: GAS does not support target CPU ${target_cpu_type}" 1>&2; exit 1; }
2416fi
2417
2418if test ! -r ${srcdir}/config/obj-${obj_format}.c; then
2419 { echo "configure: error: GAS does not have support for object file format ${obj_format}" 1>&2; exit 1; }
2420fi
2421
2422case ${user_bfd_gas}-${primary_bfd_gas} in
2423 yes-yes | no-no)
2424 # We didn't override user's choice.
2425 ;;
2426 no-yes)
2427 echo "configure: warning: Use of BFD is required for ${target}; overriding config options." 1>&2
2428 ;;
2429 no-preferred)
2430 primary_bfd_gas=no
2431 ;;
2432 *-preferred)
2433 primary_bfd_gas=yes
2434 ;;
2435 yes-*)
2436 primary_bfd_gas=yes
2437 ;;
2438 -*)
2439 # User specified nothing.
2440 ;;
2441esac
2442
2443# Some COFF configurations want these random other flags set.
2444case ${obj_format} in
2445 coff)
2446 case ${target_cpu_type} in
2447 i386) cat >> confdefs.h <<\EOF
2448#define I386COFF 1
2449EOF
2450 ;;
2451 m68k) cat >> confdefs.h <<\EOF
2452#define M68KCOFF 1
2453EOF
2454 ;;
2455 m88k) cat >> confdefs.h <<\EOF
2456#define M88KCOFF 1
2457EOF
2458 ;;
2459 esac
2460 ;;
2461esac
2462
2463# Getting this done right is going to be a bitch. Each configuration specified
2464# with --enable-targets=... should be checked for environment, format, cpu, and
2465# bfd_gas setting.
2466#
2467# For each configuration, the necessary object file support code must be linked
2468# in. This might be only one, it might be up to four. The necessary emulation
2469# code needs to be provided, too.
2470#
2471# And then there's "--enable-targets=all"....
2472#
2473# For now, just always do it for MIPS ELF or ECOFF configurations. Sigh.
2474
2475formats="${obj_format}"
2476emfiles=""
2477EMULATIONS=""
2478_gas_uniq_list="$emulations"
2479_gas_uniq_newlist=""
2480for _gas_uniq_i in _gas_uniq_dummy $_gas_uniq_list ; do
2481 case $_gas_uniq_i in
2482 _gas_uniq_dummy) ;;
2483 *) case " $_gas_uniq_newlist " in
2484 *" $_gas_uniq_i "*) ;;
2485 *) _gas_uniq_newlist="$_gas_uniq_newlist $_gas_uniq_i" ;;
2486 esac ;;
2487 esac
2488done
2489emulations=$_gas_uniq_newlist
2490
2491for em in . $emulations ; do
2492 case $em in
2493 .) continue ;;
2494 mipsbelf | mipslelf)
2495 fmt=elf file=mipself ;;
2496 mipsbecoff | mipslecoff)
2497 fmt=ecoff file=mipsecoff ;;
2498 i386coff)
2499 fmt=coff file=i386coff ;;
2500 i386elf)
2501 fmt=elf file=i386elf ;;
2502 esac
2503 formats="$formats $fmt"
2504 emfiles="$emfiles e-$file.o"
2505 EMULATIONS="$EMULATIONS &$em,"
2506done
2507_gas_uniq_list="$formats"
2508_gas_uniq_newlist=""
2509for _gas_uniq_i in _gas_uniq_dummy $_gas_uniq_list ; do
2510 case $_gas_uniq_i in
2511 _gas_uniq_dummy) ;;
2512 *) case " $_gas_uniq_newlist " in
2513 *" $_gas_uniq_i "*) ;;
2514 *) _gas_uniq_newlist="$_gas_uniq_newlist $_gas_uniq_i" ;;
2515 esac ;;
2516 esac
2517done
2518formats=$_gas_uniq_newlist
2519
2520_gas_uniq_list="$emfiles"
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
2531emfiles=$_gas_uniq_newlist
2532
2533if test `set . $formats ; shift ; echo $#` -gt 1 ; then
2534 for fmt in $formats ; do
2535 case $fmt in
2536 aout) cat >> confdefs.h <<\EOF
2537#define OBJ_MAYBE_AOUT 1
2538EOF
2539 ;;
2540 bout) cat >> confdefs.h <<\EOF
2541#define OBJ_MAYBE_BOUT 1
2542EOF
2543 ;;
2544 coff) cat >> confdefs.h <<\EOF
2545#define OBJ_MAYBE_COFF 1
2546EOF
2547 ;;
2548 ecoff) cat >> confdefs.h <<\EOF
2549#define OBJ_MAYBE_ECOFF 1
2550EOF
2551 ;;
2552 elf) cat >> confdefs.h <<\EOF
2553#define OBJ_MAYBE_ELF 1
2554EOF
2555 ;;
2556 generic) cat >> confdefs.h <<\EOF
2557#define OBJ_MAYBE_GENERIC 1
2558EOF
2559 ;;
2560 hp300) cat >> confdefs.h <<\EOF
2561#define OBJ_MAYBE_HP300 1
2562EOF
2563 ;;
2564 ieee) cat >> confdefs.h <<\EOF
2565#define OBJ_MAYBE_IEEE 1
2566EOF
2567 ;;
2568 som) cat >> confdefs.h <<\EOF
2569#define OBJ_MAYBE_SOM 1
2570EOF
2571 ;;
2572 vms) cat >> confdefs.h <<\EOF
2573#define OBJ_MAYBE_VMS 1
2574EOF
2575 ;;
2576 esac
2577 extra_objects="$extra_objects obj-$fmt.o"
2578 done
2579 obj_format=multi
2580fi
2581if test `set . $emfiles ; shift ; echo $#` -gt 0 ; then
2582 te_file=multi
2583 extra_objects="$extra_objects $emfiles"
2584 DEFAULT_EMULATION=`set . $emulations ; echo $2`
2585 cat >> confdefs.h <<\EOF
2586#define USE_EMULATIONS 1
2587EOF
2588
2589fi
2590
2591cat >> confdefs.h <<EOF
2592#define EMULATIONS $EMULATIONS
2593EOF
2594
2595cat >> confdefs.h <<EOF
2596#define DEFAULT_EMULATION "$DEFAULT_EMULATION"
2597EOF
2598
2599
2600case ${primary_bfd_gas}-${target_cpu_type}-${obj_format} in
2601 yes-*-coff) need_bfd=yes ;;
2602 no-*-coff) need_bfd=yes
2603 cat >> confdefs.h <<\EOF
2604#define MANY_SEGMENTS 1
2605EOF
2606 ;;
2607esac
2608
2609reject_dev_configs=yes
2610
2611case ${reject_dev_configs}-${dev} in
2612 yes-yes) # Oops.
2613 { echo "configure: error: GAS does not support the ${generic_target} configuration." 1>&2; exit 1; }
2614 ;;
2615esac
2616
2617
2618
2619
2620
2621
2622
2623case "${primary_bfd_gas}" in
2624 yes) cat >> confdefs.h <<\EOF
2625#define BFD_ASSEMBLER 1
2626EOF
2627
2628 need_bfd=yes ;;
2629esac
2630
2631# do we need the opcodes library?
2632case "${need_opcodes}" in
2633yes)
2634 OPCODES_LIB=../opcodes/libopcodes.la
2635 ;;
2636esac
2637
2638case "${need_bfd}" in
2639yes)
2640 BFDLIB=../bfd/libbfd.la
2641 ALL_OBJ_DEPS="$ALL_OBJ_DEPS ../bfd/bfd.h"
2642 ;;
2643esac
2644
2645
2646
2647
2648
2649
2650cat >> confdefs.h <<EOF
2651#define TARGET_ALIAS "${target_alias}"
2652EOF
2653
2654cat >> confdefs.h <<EOF
2655#define TARGET_CANONICAL "${target}"
2656EOF
2657
2658cat >> confdefs.h <<EOF
2659#define TARGET_CPU "${target_cpu}"
2660EOF
2661
2662cat >> confdefs.h <<EOF
2663#define TARGET_VENDOR "${target_vendor}"
2664EOF
2665
2666cat >> confdefs.h <<EOF
2667#define TARGET_OS "${target_os}"
2668EOF
2669
2670
2671# Extract the first word of "gcc", so it can be a program name with args.
2672set dummy gcc; ac_word=$2
2673echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e4a86f6f 2674echo "configure:2675: checking for $ac_word" >&5
252b5132
RH
2675if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
2676 echo $ac_n "(cached) $ac_c" 1>&6
2677else
2678 if test -n "$CC"; then
2679 ac_cv_prog_CC="$CC" # Let the user override the test.
2680else
2681 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2682 ac_dummy="$PATH"
2683 for ac_dir in $ac_dummy; do
2684 test -z "$ac_dir" && ac_dir=.
2685 if test -f $ac_dir/$ac_word; then
2686 ac_cv_prog_CC="gcc"
2687 break
2688 fi
2689 done
2690 IFS="$ac_save_ifs"
2691fi
2692fi
2693CC="$ac_cv_prog_CC"
2694if test -n "$CC"; then
2695 echo "$ac_t""$CC" 1>&6
2696else
2697 echo "$ac_t""no" 1>&6
2698fi
2699
2700if test -z "$CC"; then
2701 # Extract the first word of "cc", so it can be a program name with args.
2702set dummy cc; ac_word=$2
2703echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e4a86f6f 2704echo "configure:2705: checking for $ac_word" >&5
252b5132
RH
2705if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
2706 echo $ac_n "(cached) $ac_c" 1>&6
2707else
2708 if test -n "$CC"; then
2709 ac_cv_prog_CC="$CC" # Let the user override the test.
2710else
2711 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2712 ac_prog_rejected=no
2713 ac_dummy="$PATH"
2714 for ac_dir in $ac_dummy; do
2715 test -z "$ac_dir" && ac_dir=.
2716 if test -f $ac_dir/$ac_word; then
2717 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
2718 ac_prog_rejected=yes
2719 continue
2720 fi
2721 ac_cv_prog_CC="cc"
2722 break
2723 fi
2724 done
2725 IFS="$ac_save_ifs"
2726if test $ac_prog_rejected = yes; then
2727 # We found a bogon in the path, so make sure we never use it.
2728 set dummy $ac_cv_prog_CC
2729 shift
2730 if test $# -gt 0; then
2731 # We chose a different compiler from the bogus one.
2732 # However, it has the same basename, so the bogon will be chosen
2733 # first if we set CC to just the basename; use the full file name.
2734 shift
2735 set dummy "$ac_dir/$ac_word" "$@"
2736 shift
2737 ac_cv_prog_CC="$@"
2738 fi
2739fi
2740fi
2741fi
2742CC="$ac_cv_prog_CC"
2743if test -n "$CC"; then
2744 echo "$ac_t""$CC" 1>&6
2745else
2746 echo "$ac_t""no" 1>&6
2747fi
2748
2749 if test -z "$CC"; then
2750 case "`uname -s`" in
2751 *win32* | *WIN32*)
2752 # Extract the first word of "cl", so it can be a program name with args.
2753set dummy cl; ac_word=$2
2754echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e4a86f6f 2755echo "configure:2756: checking for $ac_word" >&5
252b5132
RH
2756if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
2757 echo $ac_n "(cached) $ac_c" 1>&6
2758else
2759 if test -n "$CC"; then
2760 ac_cv_prog_CC="$CC" # Let the user override the test.
2761else
2762 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2763 ac_dummy="$PATH"
2764 for ac_dir in $ac_dummy; do
2765 test -z "$ac_dir" && ac_dir=.
2766 if test -f $ac_dir/$ac_word; then
2767 ac_cv_prog_CC="cl"
2768 break
2769 fi
2770 done
2771 IFS="$ac_save_ifs"
2772fi
2773fi
2774CC="$ac_cv_prog_CC"
2775if test -n "$CC"; then
2776 echo "$ac_t""$CC" 1>&6
2777else
2778 echo "$ac_t""no" 1>&6
2779fi
2780 ;;
2781 esac
2782 fi
2783 test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
2784fi
2785
2786echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
e4a86f6f 2787echo "configure:2788: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
252b5132
RH
2788
2789ac_ext=c
2790# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
2791ac_cpp='$CPP $CPPFLAGS'
2792ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
2793ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
2794cross_compiling=$ac_cv_prog_cc_cross
2795
2796cat > conftest.$ac_ext << EOF
2797
e4a86f6f 2798#line 2799 "configure"
252b5132
RH
2799#include "confdefs.h"
2800
2801main(){return(0);}
2802EOF
e4a86f6f 2803if { (eval echo configure:2804: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
2804 ac_cv_prog_cc_works=yes
2805 # If we can't run a trivial program, we are probably using a cross compiler.
2806 if (./conftest; exit) 2>/dev/null; then
2807 ac_cv_prog_cc_cross=no
2808 else
2809 ac_cv_prog_cc_cross=yes
2810 fi
2811else
2812 echo "configure: failed program was:" >&5
2813 cat conftest.$ac_ext >&5
2814 ac_cv_prog_cc_works=no
2815fi
2816rm -fr conftest*
2817ac_ext=c
2818# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
2819ac_cpp='$CPP $CPPFLAGS'
2820ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
2821ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
2822cross_compiling=$ac_cv_prog_cc_cross
2823
2824echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
2825if test $ac_cv_prog_cc_works = no; then
2826 { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
2827fi
2828echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
e4a86f6f 2829echo "configure:2830: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
252b5132
RH
2830echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
2831cross_compiling=$ac_cv_prog_cc_cross
2832
2833echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
e4a86f6f 2834echo "configure:2835: checking whether we are using GNU C" >&5
252b5132
RH
2835if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
2836 echo $ac_n "(cached) $ac_c" 1>&6
2837else
2838 cat > conftest.c <<EOF
2839#ifdef __GNUC__
2840 yes;
2841#endif
2842EOF
e4a86f6f 2843if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:2844: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
252b5132
RH
2844 ac_cv_prog_gcc=yes
2845else
2846 ac_cv_prog_gcc=no
2847fi
2848fi
2849
2850echo "$ac_t""$ac_cv_prog_gcc" 1>&6
2851
2852if test $ac_cv_prog_gcc = yes; then
2853 GCC=yes
2854else
2855 GCC=
2856fi
2857
2858ac_test_CFLAGS="${CFLAGS+set}"
2859ac_save_CFLAGS="$CFLAGS"
2860CFLAGS=
2861echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
e4a86f6f 2862echo "configure:2863: checking whether ${CC-cc} accepts -g" >&5
252b5132
RH
2863if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
2864 echo $ac_n "(cached) $ac_c" 1>&6
2865else
2866 echo 'void f(){}' > conftest.c
2867if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
2868 ac_cv_prog_cc_g=yes
2869else
2870 ac_cv_prog_cc_g=no
2871fi
2872rm -f conftest*
2873
2874fi
2875
2876echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
2877if test "$ac_test_CFLAGS" = set; then
2878 CFLAGS="$ac_save_CFLAGS"
2879elif test $ac_cv_prog_cc_g = yes; then
2880 if test "$GCC" = yes; then
2881 CFLAGS="-g -O2"
2882 else
2883 CFLAGS="-g"
2884 fi
2885else
2886 if test "$GCC" = yes; then
2887 CFLAGS="-O2"
2888 else
2889 CFLAGS=
2890 fi
2891fi
2892
2893
2894for ac_prog in 'bison -y' byacc
2895do
2896# Extract the first word of "$ac_prog", so it can be a program name with args.
2897set dummy $ac_prog; ac_word=$2
2898echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e4a86f6f 2899echo "configure:2900: checking for $ac_word" >&5
252b5132
RH
2900if eval "test \"`echo '$''{'ac_cv_prog_YACC'+set}'`\" = set"; then
2901 echo $ac_n "(cached) $ac_c" 1>&6
2902else
2903 if test -n "$YACC"; then
2904 ac_cv_prog_YACC="$YACC" # Let the user override the test.
2905else
2906 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2907 ac_dummy="$PATH"
2908 for ac_dir in $ac_dummy; do
2909 test -z "$ac_dir" && ac_dir=.
2910 if test -f $ac_dir/$ac_word; then
2911 ac_cv_prog_YACC="$ac_prog"
2912 break
2913 fi
2914 done
2915 IFS="$ac_save_ifs"
2916fi
2917fi
2918YACC="$ac_cv_prog_YACC"
2919if test -n "$YACC"; then
2920 echo "$ac_t""$YACC" 1>&6
2921else
2922 echo "$ac_t""no" 1>&6
2923fi
2924
2925test -n "$YACC" && break
2926done
2927test -n "$YACC" || YACC="yacc"
2928
2929echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
e4a86f6f 2930echo "configure:2931: checking how to run the C preprocessor" >&5
252b5132
RH
2931# On Suns, sometimes $CPP names a directory.
2932if test -n "$CPP" && test -d "$CPP"; then
2933 CPP=
2934fi
2935if test -z "$CPP"; then
2936if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
2937 echo $ac_n "(cached) $ac_c" 1>&6
2938else
2939 # This must be in double quotes, not single quotes, because CPP may get
2940 # substituted into the Makefile and "${CC-cc}" will confuse make.
2941 CPP="${CC-cc} -E"
2942 # On the NeXT, cc -E runs the code through the compiler's parser,
2943 # not just through cpp.
2944 cat > conftest.$ac_ext <<EOF
e4a86f6f 2945#line 2946 "configure"
252b5132
RH
2946#include "confdefs.h"
2947#include <assert.h>
2948Syntax Error
2949EOF
2950ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
e4a86f6f 2951{ (eval echo configure:2952: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
252b5132
RH
2952ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2953if test -z "$ac_err"; then
2954 :
2955else
2956 echo "$ac_err" >&5
2957 echo "configure: failed program was:" >&5
2958 cat conftest.$ac_ext >&5
2959 rm -rf conftest*
2960 CPP="${CC-cc} -E -traditional-cpp"
2961 cat > conftest.$ac_ext <<EOF
e4a86f6f 2962#line 2963 "configure"
252b5132
RH
2963#include "confdefs.h"
2964#include <assert.h>
2965Syntax Error
2966EOF
2967ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
e4a86f6f 2968{ (eval echo configure:2969: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
252b5132
RH
2969ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2970if test -z "$ac_err"; then
2971 :
2972else
2973 echo "$ac_err" >&5
2974 echo "configure: failed program was:" >&5
2975 cat conftest.$ac_ext >&5
2976 rm -rf conftest*
2977 CPP="${CC-cc} -nologo -E"
2978 cat > conftest.$ac_ext <<EOF
e4a86f6f 2979#line 2980 "configure"
252b5132
RH
2980#include "confdefs.h"
2981#include <assert.h>
2982Syntax Error
2983EOF
2984ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
e4a86f6f 2985{ (eval echo configure:2986: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
252b5132
RH
2986ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2987if test -z "$ac_err"; then
2988 :
2989else
2990 echo "$ac_err" >&5
2991 echo "configure: failed program was:" >&5
2992 cat conftest.$ac_ext >&5
2993 rm -rf conftest*
2994 CPP=/lib/cpp
2995fi
2996rm -f conftest*
2997fi
2998rm -f conftest*
2999fi
3000rm -f conftest*
3001 ac_cv_prog_CPP="$CPP"
3002fi
3003 CPP="$ac_cv_prog_CPP"
3004else
3005 ac_cv_prog_CPP="$CPP"
3006fi
3007echo "$ac_t""$CPP" 1>&6
3008
3009missing_dir=`cd $ac_aux_dir && pwd`
3010for ac_prog in flex lex
3011do
3012# Extract the first word of "$ac_prog", so it can be a program name with args.
3013set dummy $ac_prog; ac_word=$2
3014echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e4a86f6f 3015echo "configure:3016: checking for $ac_word" >&5
252b5132
RH
3016if eval "test \"`echo '$''{'ac_cv_prog_LEX'+set}'`\" = set"; then
3017 echo $ac_n "(cached) $ac_c" 1>&6
3018else
3019 if test -n "$LEX"; then
3020 ac_cv_prog_LEX="$LEX" # Let the user override the test.
3021else
3022 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3023 ac_dummy="$PATH"
3024 for ac_dir in $ac_dummy; do
3025 test -z "$ac_dir" && ac_dir=.
3026 if test -f $ac_dir/$ac_word; then
3027 ac_cv_prog_LEX="$ac_prog"
3028 break
3029 fi
3030 done
3031 IFS="$ac_save_ifs"
3032fi
3033fi
3034LEX="$ac_cv_prog_LEX"
3035if test -n "$LEX"; then
3036 echo "$ac_t""$LEX" 1>&6
3037else
3038 echo "$ac_t""no" 1>&6
3039fi
3040
3041test -n "$LEX" && break
3042done
3043test -n "$LEX" || LEX=""$missing_dir/missing flex""
3044
3045# Extract the first word of "flex", so it can be a program name with args.
3046set dummy flex; ac_word=$2
3047echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e4a86f6f 3048echo "configure:3049: checking for $ac_word" >&5
252b5132
RH
3049if eval "test \"`echo '$''{'ac_cv_prog_LEX'+set}'`\" = set"; then
3050 echo $ac_n "(cached) $ac_c" 1>&6
3051else
3052 if test -n "$LEX"; then
3053 ac_cv_prog_LEX="$LEX" # Let the user override the test.
3054else
3055 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3056 ac_dummy="$PATH"
3057 for ac_dir in $ac_dummy; do
3058 test -z "$ac_dir" && ac_dir=.
3059 if test -f $ac_dir/$ac_word; then
3060 ac_cv_prog_LEX="flex"
3061 break
3062 fi
3063 done
3064 IFS="$ac_save_ifs"
3065 test -z "$ac_cv_prog_LEX" && ac_cv_prog_LEX="lex"
3066fi
3067fi
3068LEX="$ac_cv_prog_LEX"
3069if test -n "$LEX"; then
3070 echo "$ac_t""$LEX" 1>&6
3071else
3072 echo "$ac_t""no" 1>&6
3073fi
3074
3075if test -z "$LEXLIB"
3076then
3077 case "$LEX" in
3078 flex*) ac_lib=fl ;;
3079 *) ac_lib=l ;;
3080 esac
3081 echo $ac_n "checking for yywrap in -l$ac_lib""... $ac_c" 1>&6
e4a86f6f 3082echo "configure:3083: checking for yywrap in -l$ac_lib" >&5
252b5132
RH
3083ac_lib_var=`echo $ac_lib'_'yywrap | sed 'y%./+-%__p_%'`
3084if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3085 echo $ac_n "(cached) $ac_c" 1>&6
3086else
3087 ac_save_LIBS="$LIBS"
3088LIBS="-l$ac_lib $LIBS"
3089cat > conftest.$ac_ext <<EOF
e4a86f6f 3090#line 3091 "configure"
252b5132
RH
3091#include "confdefs.h"
3092/* Override any gcc2 internal prototype to avoid an error. */
3093/* We use char because int might match the return type of a gcc2
3094 builtin and then its argument prototype would still apply. */
3095char yywrap();
3096
3097int main() {
3098yywrap()
3099; return 0; }
3100EOF
e4a86f6f 3101if { (eval echo configure:3102: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
3102 rm -rf conftest*
3103 eval "ac_cv_lib_$ac_lib_var=yes"
3104else
3105 echo "configure: failed program was:" >&5
3106 cat conftest.$ac_ext >&5
3107 rm -rf conftest*
3108 eval "ac_cv_lib_$ac_lib_var=no"
3109fi
3110rm -f conftest*
3111LIBS="$ac_save_LIBS"
3112
3113fi
3114if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3115 echo "$ac_t""yes" 1>&6
3116 LEXLIB="-l$ac_lib"
3117else
3118 echo "$ac_t""no" 1>&6
3119fi
3120
3121fi
3122
3123echo $ac_n "checking lex output file root""... $ac_c" 1>&6
e4a86f6f 3124echo "configure:3125: checking lex output file root" >&5
252b5132
RH
3125if eval "test \"`echo '$''{'ac_cv_prog_lex_root'+set}'`\" = set"; then
3126 echo $ac_n "(cached) $ac_c" 1>&6
3127else
3128 # The minimal lex program is just a single line: %%. But some broken lexes
3129# (Solaris, I think it was) want two %% lines, so accommodate them.
3130echo '%%
3131%%' | $LEX
3132if test -f lex.yy.c; then
3133 ac_cv_prog_lex_root=lex.yy
3134elif test -f lexyy.c; then
3135 ac_cv_prog_lex_root=lexyy
3136else
3137 { echo "configure: error: cannot find output from $LEX; giving up" 1>&2; exit 1; }
3138fi
3139fi
3140
3141echo "$ac_t""$ac_cv_prog_lex_root" 1>&6
3142LEX_OUTPUT_ROOT=$ac_cv_prog_lex_root
3143
3144echo $ac_n "checking whether yytext is a pointer""... $ac_c" 1>&6
e4a86f6f 3145echo "configure:3146: checking whether yytext is a pointer" >&5
252b5132
RH
3146if eval "test \"`echo '$''{'ac_cv_prog_lex_yytext_pointer'+set}'`\" = set"; then
3147 echo $ac_n "(cached) $ac_c" 1>&6
3148else
3149 # POSIX says lex can declare yytext either as a pointer or an array; the
3150# default is implementation-dependent. Figure out which it is, since
3151# not all implementations provide the %pointer and %array declarations.
3152ac_cv_prog_lex_yytext_pointer=no
3153echo 'extern char *yytext;' >>$LEX_OUTPUT_ROOT.c
3154ac_save_LIBS="$LIBS"
3155LIBS="$LIBS $LEXLIB"
3156cat > conftest.$ac_ext <<EOF
e4a86f6f 3157#line 3158 "configure"
252b5132
RH
3158#include "confdefs.h"
3159`cat $LEX_OUTPUT_ROOT.c`
3160int main() {
3161
3162; return 0; }
3163EOF
e4a86f6f 3164if { (eval echo configure:3165: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
3165 rm -rf conftest*
3166 ac_cv_prog_lex_yytext_pointer=yes
3167else
3168 echo "configure: failed program was:" >&5
3169 cat conftest.$ac_ext >&5
3170fi
3171rm -f conftest*
3172LIBS="$ac_save_LIBS"
3173rm -f "${LEX_OUTPUT_ROOT}.c"
3174
3175fi
3176
3177echo "$ac_t""$ac_cv_prog_lex_yytext_pointer" 1>&6
3178if test $ac_cv_prog_lex_yytext_pointer = yes; then
3179 cat >> confdefs.h <<\EOF
3180#define YYTEXT_POINTER 1
3181EOF
3182
3183fi
3184
3185
3186ALL_LINGUAS=
3187echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6
e4a86f6f 3188echo "configure:3189: checking for POSIXized ISC" >&5
252b5132
RH
3189if test -d /etc/conf/kconfig.d &&
3190 grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
3191then
3192 echo "$ac_t""yes" 1>&6
3193 ISC=yes # If later tests want to check for ISC.
3194 cat >> confdefs.h <<\EOF
3195#define _POSIX_SOURCE 1
3196EOF
3197
3198 if test "$GCC" = yes; then
3199 CC="$CC -posix"
3200 else
3201 CC="$CC -Xp"
3202 fi
3203else
3204 echo "$ac_t""no" 1>&6
3205 ISC=
3206fi
3207
3208echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
e4a86f6f 3209echo "configure:3210: checking for ANSI C header files" >&5
252b5132
RH
3210if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
3211 echo $ac_n "(cached) $ac_c" 1>&6
3212else
3213 cat > conftest.$ac_ext <<EOF
e4a86f6f 3214#line 3215 "configure"
252b5132
RH
3215#include "confdefs.h"
3216#include <stdlib.h>
3217#include <stdarg.h>
3218#include <string.h>
3219#include <float.h>
3220EOF
3221ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
e4a86f6f 3222{ (eval echo configure:3223: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
252b5132
RH
3223ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3224if test -z "$ac_err"; then
3225 rm -rf conftest*
3226 ac_cv_header_stdc=yes
3227else
3228 echo "$ac_err" >&5
3229 echo "configure: failed program was:" >&5
3230 cat conftest.$ac_ext >&5
3231 rm -rf conftest*
3232 ac_cv_header_stdc=no
3233fi
3234rm -f conftest*
3235
3236if test $ac_cv_header_stdc = yes; then
3237 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
3238cat > conftest.$ac_ext <<EOF
e4a86f6f 3239#line 3240 "configure"
252b5132
RH
3240#include "confdefs.h"
3241#include <string.h>
3242EOF
3243if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3244 egrep "memchr" >/dev/null 2>&1; then
3245 :
3246else
3247 rm -rf conftest*
3248 ac_cv_header_stdc=no
3249fi
3250rm -f conftest*
3251
3252fi
3253
3254if test $ac_cv_header_stdc = yes; then
3255 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
3256cat > conftest.$ac_ext <<EOF
e4a86f6f 3257#line 3258 "configure"
252b5132
RH
3258#include "confdefs.h"
3259#include <stdlib.h>
3260EOF
3261if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3262 egrep "free" >/dev/null 2>&1; then
3263 :
3264else
3265 rm -rf conftest*
3266 ac_cv_header_stdc=no
3267fi
3268rm -f conftest*
3269
3270fi
3271
3272if test $ac_cv_header_stdc = yes; then
3273 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
3274if test "$cross_compiling" = yes; then
3275 :
3276else
3277 cat > conftest.$ac_ext <<EOF
e4a86f6f 3278#line 3279 "configure"
252b5132
RH
3279#include "confdefs.h"
3280#include <ctype.h>
3281#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
3282#define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
3283#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
3284int main () { int i; for (i = 0; i < 256; i++)
3285if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
3286exit (0); }
3287
3288EOF
e4a86f6f 3289if { (eval echo configure:3290: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
252b5132
RH
3290then
3291 :
3292else
3293 echo "configure: failed program was:" >&5
3294 cat conftest.$ac_ext >&5
3295 rm -fr conftest*
3296 ac_cv_header_stdc=no
3297fi
3298rm -fr conftest*
3299fi
3300
3301fi
3302fi
3303
3304echo "$ac_t""$ac_cv_header_stdc" 1>&6
3305if test $ac_cv_header_stdc = yes; then
3306 cat >> confdefs.h <<\EOF
3307#define STDC_HEADERS 1
3308EOF
3309
3310fi
3311
3312echo $ac_n "checking for working const""... $ac_c" 1>&6
e4a86f6f 3313echo "configure:3314: checking for working const" >&5
252b5132
RH
3314if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
3315 echo $ac_n "(cached) $ac_c" 1>&6
3316else
3317 cat > conftest.$ac_ext <<EOF
e4a86f6f 3318#line 3319 "configure"
252b5132
RH
3319#include "confdefs.h"
3320
3321int main() {
3322
3323/* Ultrix mips cc rejects this. */
3324typedef int charset[2]; const charset x;
3325/* SunOS 4.1.1 cc rejects this. */
3326char const *const *ccp;
3327char **p;
3328/* NEC SVR4.0.2 mips cc rejects this. */
3329struct point {int x, y;};
3330static struct point const zero = {0,0};
3331/* AIX XL C 1.02.0.0 rejects this.
3332 It does not let you subtract one const X* pointer from another in an arm
3333 of an if-expression whose if-part is not a constant expression */
3334const char *g = "string";
3335ccp = &g + (g ? g-g : 0);
3336/* HPUX 7.0 cc rejects these. */
3337++ccp;
3338p = (char**) ccp;
3339ccp = (char const *const *) p;
3340{ /* SCO 3.2v4 cc rejects this. */
3341 char *t;
3342 char const *s = 0 ? (char *) 0 : (char const *) 0;
3343
3344 *t++ = 0;
3345}
3346{ /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
3347 int x[] = {25, 17};
3348 const int *foo = &x[0];
3349 ++foo;
3350}
3351{ /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
3352 typedef const int *iptr;
3353 iptr p = 0;
3354 ++p;
3355}
3356{ /* AIX XL C 1.02.0.0 rejects this saying
3357 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
3358 struct s { int j; const int *ap[3]; };
3359 struct s *b; b->j = 5;
3360}
3361{ /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
3362 const int foo = 10;
3363}
3364
3365; return 0; }
3366EOF
e4a86f6f 3367if { (eval echo configure:3368: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
252b5132
RH
3368 rm -rf conftest*
3369 ac_cv_c_const=yes
3370else
3371 echo "configure: failed program was:" >&5
3372 cat conftest.$ac_ext >&5
3373 rm -rf conftest*
3374 ac_cv_c_const=no
3375fi
3376rm -f conftest*
3377fi
3378
3379echo "$ac_t""$ac_cv_c_const" 1>&6
3380if test $ac_cv_c_const = no; then
3381 cat >> confdefs.h <<\EOF
3382#define const
3383EOF
3384
3385fi
3386
3387echo $ac_n "checking for inline""... $ac_c" 1>&6
e4a86f6f 3388echo "configure:3389: checking for inline" >&5
252b5132
RH
3389if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
3390 echo $ac_n "(cached) $ac_c" 1>&6
3391else
3392 ac_cv_c_inline=no
3393for ac_kw in inline __inline__ __inline; do
3394 cat > conftest.$ac_ext <<EOF
e4a86f6f 3395#line 3396 "configure"
252b5132
RH
3396#include "confdefs.h"
3397
3398int main() {
3399} $ac_kw foo() {
3400; return 0; }
3401EOF
e4a86f6f 3402if { (eval echo configure:3403: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
252b5132
RH
3403 rm -rf conftest*
3404 ac_cv_c_inline=$ac_kw; break
3405else
3406 echo "configure: failed program was:" >&5
3407 cat conftest.$ac_ext >&5
3408fi
3409rm -f conftest*
3410done
3411
3412fi
3413
3414echo "$ac_t""$ac_cv_c_inline" 1>&6
3415case "$ac_cv_c_inline" in
3416 inline | yes) ;;
3417 no) cat >> confdefs.h <<\EOF
3418#define inline
3419EOF
3420 ;;
3421 *) cat >> confdefs.h <<EOF
3422#define inline $ac_cv_c_inline
3423EOF
3424 ;;
3425esac
3426
3427echo $ac_n "checking for off_t""... $ac_c" 1>&6
e4a86f6f 3428echo "configure:3429: checking for off_t" >&5
252b5132
RH
3429if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then
3430 echo $ac_n "(cached) $ac_c" 1>&6
3431else
3432 cat > conftest.$ac_ext <<EOF
e4a86f6f 3433#line 3434 "configure"
252b5132
RH
3434#include "confdefs.h"
3435#include <sys/types.h>
3436#if STDC_HEADERS
3437#include <stdlib.h>
3438#include <stddef.h>
3439#endif
3440EOF
3441if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3442 egrep "(^|[^a-zA-Z_0-9])off_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
3443 rm -rf conftest*
3444 ac_cv_type_off_t=yes
3445else
3446 rm -rf conftest*
3447 ac_cv_type_off_t=no
3448fi
3449rm -f conftest*
3450
3451fi
3452echo "$ac_t""$ac_cv_type_off_t" 1>&6
3453if test $ac_cv_type_off_t = no; then
3454 cat >> confdefs.h <<\EOF
3455#define off_t long
3456EOF
3457
3458fi
3459
3460echo $ac_n "checking for size_t""... $ac_c" 1>&6
e4a86f6f 3461echo "configure:3462: checking for size_t" >&5
252b5132
RH
3462if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
3463 echo $ac_n "(cached) $ac_c" 1>&6
3464else
3465 cat > conftest.$ac_ext <<EOF
e4a86f6f 3466#line 3467 "configure"
252b5132
RH
3467#include "confdefs.h"
3468#include <sys/types.h>
3469#if STDC_HEADERS
3470#include <stdlib.h>
3471#include <stddef.h>
3472#endif
3473EOF
3474if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3475 egrep "(^|[^a-zA-Z_0-9])size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
3476 rm -rf conftest*
3477 ac_cv_type_size_t=yes
3478else
3479 rm -rf conftest*
3480 ac_cv_type_size_t=no
3481fi
3482rm -f conftest*
3483
3484fi
3485echo "$ac_t""$ac_cv_type_size_t" 1>&6
3486if test $ac_cv_type_size_t = no; then
3487 cat >> confdefs.h <<\EOF
3488#define size_t unsigned
3489EOF
3490
3491fi
3492
3493# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
3494# for constant arguments. Useless!
3495echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
e4a86f6f 3496echo "configure:3497: checking for working alloca.h" >&5
252b5132
RH
3497if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
3498 echo $ac_n "(cached) $ac_c" 1>&6
3499else
3500 cat > conftest.$ac_ext <<EOF
e4a86f6f 3501#line 3502 "configure"
252b5132
RH
3502#include "confdefs.h"
3503#include <alloca.h>
3504int main() {
3505char *p = alloca(2 * sizeof(int));
3506; return 0; }
3507EOF
e4a86f6f 3508if { (eval echo configure:3509: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
3509 rm -rf conftest*
3510 ac_cv_header_alloca_h=yes
3511else
3512 echo "configure: failed program was:" >&5
3513 cat conftest.$ac_ext >&5
3514 rm -rf conftest*
3515 ac_cv_header_alloca_h=no
3516fi
3517rm -f conftest*
3518fi
3519
3520echo "$ac_t""$ac_cv_header_alloca_h" 1>&6
3521if test $ac_cv_header_alloca_h = yes; then
3522 cat >> confdefs.h <<\EOF
3523#define HAVE_ALLOCA_H 1
3524EOF
3525
3526fi
3527
3528echo $ac_n "checking for alloca""... $ac_c" 1>&6
e4a86f6f 3529echo "configure:3530: checking for alloca" >&5
252b5132
RH
3530if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
3531 echo $ac_n "(cached) $ac_c" 1>&6
3532else
3533 cat > conftest.$ac_ext <<EOF
e4a86f6f 3534#line 3535 "configure"
252b5132
RH
3535#include "confdefs.h"
3536
3537#ifdef __GNUC__
3538# define alloca __builtin_alloca
3539#else
3540# ifdef _MSC_VER
3541# include <malloc.h>
3542# define alloca _alloca
3543# else
3544# if HAVE_ALLOCA_H
3545# include <alloca.h>
3546# else
3547# ifdef _AIX
3548 #pragma alloca
3549# else
3550# ifndef alloca /* predefined by HP cc +Olibcalls */
3551char *alloca ();
3552# endif
3553# endif
3554# endif
3555# endif
3556#endif
3557
3558int main() {
3559char *p = (char *) alloca(1);
3560; return 0; }
3561EOF
e4a86f6f 3562if { (eval echo configure:3563: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
3563 rm -rf conftest*
3564 ac_cv_func_alloca_works=yes
3565else
3566 echo "configure: failed program was:" >&5
3567 cat conftest.$ac_ext >&5
3568 rm -rf conftest*
3569 ac_cv_func_alloca_works=no
3570fi
3571rm -f conftest*
3572fi
3573
3574echo "$ac_t""$ac_cv_func_alloca_works" 1>&6
3575if test $ac_cv_func_alloca_works = yes; then
3576 cat >> confdefs.h <<\EOF
3577#define HAVE_ALLOCA 1
3578EOF
3579
3580fi
3581
3582if test $ac_cv_func_alloca_works = no; then
3583 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
3584 # that cause trouble. Some versions do not even contain alloca or
3585 # contain a buggy version. If you still want to use their alloca,
3586 # use ar to extract alloca.o from them instead of compiling alloca.c.
3587 ALLOCA=alloca.${ac_objext}
3588 cat >> confdefs.h <<\EOF
3589#define C_ALLOCA 1
3590EOF
3591
3592
3593echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
e4a86f6f 3594echo "configure:3595: checking whether alloca needs Cray hooks" >&5
252b5132
RH
3595if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
3596 echo $ac_n "(cached) $ac_c" 1>&6
3597else
3598 cat > conftest.$ac_ext <<EOF
e4a86f6f 3599#line 3600 "configure"
252b5132
RH
3600#include "confdefs.h"
3601#if defined(CRAY) && ! defined(CRAY2)
3602webecray
3603#else
3604wenotbecray
3605#endif
3606
3607EOF
3608if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3609 egrep "webecray" >/dev/null 2>&1; then
3610 rm -rf conftest*
3611 ac_cv_os_cray=yes
3612else
3613 rm -rf conftest*
3614 ac_cv_os_cray=no
3615fi
3616rm -f conftest*
3617
3618fi
3619
3620echo "$ac_t""$ac_cv_os_cray" 1>&6
3621if test $ac_cv_os_cray = yes; then
3622for ac_func in _getb67 GETB67 getb67; do
3623 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
e4a86f6f 3624echo "configure:3625: checking for $ac_func" >&5
252b5132
RH
3625if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3626 echo $ac_n "(cached) $ac_c" 1>&6
3627else
3628 cat > conftest.$ac_ext <<EOF
e4a86f6f 3629#line 3630 "configure"
252b5132
RH
3630#include "confdefs.h"
3631/* System header to define __stub macros and hopefully few prototypes,
3632 which can conflict with char $ac_func(); below. */
3633#include <assert.h>
3634/* Override any gcc2 internal prototype to avoid an error. */
3635/* We use char because int might match the return type of a gcc2
3636 builtin and then its argument prototype would still apply. */
3637char $ac_func();
3638
3639int main() {
3640
3641/* The GNU C library defines this for functions which it implements
3642 to always fail with ENOSYS. Some functions are actually named
3643 something starting with __ and the normal name is an alias. */
3644#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3645choke me
3646#else
3647$ac_func();
3648#endif
3649
3650; return 0; }
3651EOF
e4a86f6f 3652if { (eval echo configure:3653: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
3653 rm -rf conftest*
3654 eval "ac_cv_func_$ac_func=yes"
3655else
3656 echo "configure: failed program was:" >&5
3657 cat conftest.$ac_ext >&5
3658 rm -rf conftest*
3659 eval "ac_cv_func_$ac_func=no"
3660fi
3661rm -f conftest*
3662fi
3663
3664if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3665 echo "$ac_t""yes" 1>&6
3666 cat >> confdefs.h <<EOF
3667#define CRAY_STACKSEG_END $ac_func
3668EOF
3669
3670 break
3671else
3672 echo "$ac_t""no" 1>&6
3673fi
3674
3675done
3676fi
3677
3678echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
e4a86f6f 3679echo "configure:3680: checking stack direction for C alloca" >&5
252b5132
RH
3680if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
3681 echo $ac_n "(cached) $ac_c" 1>&6
3682else
3683 if test "$cross_compiling" = yes; then
3684 ac_cv_c_stack_direction=0
3685else
3686 cat > conftest.$ac_ext <<EOF
e4a86f6f 3687#line 3688 "configure"
252b5132
RH
3688#include "confdefs.h"
3689find_stack_direction ()
3690{
3691 static char *addr = 0;
3692 auto char dummy;
3693 if (addr == 0)
3694 {
3695 addr = &dummy;
3696 return find_stack_direction ();
3697 }
3698 else
3699 return (&dummy > addr) ? 1 : -1;
3700}
3701main ()
3702{
3703 exit (find_stack_direction() < 0);
3704}
3705EOF
e4a86f6f 3706if { (eval echo configure:3707: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
252b5132
RH
3707then
3708 ac_cv_c_stack_direction=1
3709else
3710 echo "configure: failed program was:" >&5
3711 cat conftest.$ac_ext >&5
3712 rm -fr conftest*
3713 ac_cv_c_stack_direction=-1
3714fi
3715rm -fr conftest*
3716fi
3717
3718fi
3719
3720echo "$ac_t""$ac_cv_c_stack_direction" 1>&6
3721cat >> confdefs.h <<EOF
3722#define STACK_DIRECTION $ac_cv_c_stack_direction
3723EOF
3724
3725fi
3726
3727for ac_hdr in unistd.h
3728do
3729ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
3730echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
e4a86f6f 3731echo "configure:3732: checking for $ac_hdr" >&5
252b5132
RH
3732if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3733 echo $ac_n "(cached) $ac_c" 1>&6
3734else
3735 cat > conftest.$ac_ext <<EOF
e4a86f6f 3736#line 3737 "configure"
252b5132
RH
3737#include "confdefs.h"
3738#include <$ac_hdr>
3739EOF
3740ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
e4a86f6f 3741{ (eval echo configure:3742: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
252b5132
RH
3742ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3743if test -z "$ac_err"; then
3744 rm -rf conftest*
3745 eval "ac_cv_header_$ac_safe=yes"
3746else
3747 echo "$ac_err" >&5
3748 echo "configure: failed program was:" >&5
3749 cat conftest.$ac_ext >&5
3750 rm -rf conftest*
3751 eval "ac_cv_header_$ac_safe=no"
3752fi
3753rm -f conftest*
3754fi
3755if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3756 echo "$ac_t""yes" 1>&6
3757 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
3758 cat >> confdefs.h <<EOF
3759#define $ac_tr_hdr 1
3760EOF
3761
3762else
3763 echo "$ac_t""no" 1>&6
3764fi
3765done
3766
3767for ac_func in getpagesize
3768do
3769echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
e4a86f6f 3770echo "configure:3771: checking for $ac_func" >&5
252b5132
RH
3771if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3772 echo $ac_n "(cached) $ac_c" 1>&6
3773else
3774 cat > conftest.$ac_ext <<EOF
e4a86f6f 3775#line 3776 "configure"
252b5132
RH
3776#include "confdefs.h"
3777/* System header to define __stub macros and hopefully few prototypes,
3778 which can conflict with char $ac_func(); below. */
3779#include <assert.h>
3780/* Override any gcc2 internal prototype to avoid an error. */
3781/* We use char because int might match the return type of a gcc2
3782 builtin and then its argument prototype would still apply. */
3783char $ac_func();
3784
3785int main() {
3786
3787/* The GNU C library defines this for functions which it implements
3788 to always fail with ENOSYS. Some functions are actually named
3789 something starting with __ and the normal name is an alias. */
3790#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3791choke me
3792#else
3793$ac_func();
3794#endif
3795
3796; return 0; }
3797EOF
e4a86f6f 3798if { (eval echo configure:3799: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
3799 rm -rf conftest*
3800 eval "ac_cv_func_$ac_func=yes"
3801else
3802 echo "configure: failed program was:" >&5
3803 cat conftest.$ac_ext >&5
3804 rm -rf conftest*
3805 eval "ac_cv_func_$ac_func=no"
3806fi
3807rm -f conftest*
3808fi
3809
3810if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3811 echo "$ac_t""yes" 1>&6
3812 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3813 cat >> confdefs.h <<EOF
3814#define $ac_tr_func 1
3815EOF
3816
3817else
3818 echo "$ac_t""no" 1>&6
3819fi
3820done
3821
3822echo $ac_n "checking for working mmap""... $ac_c" 1>&6
e4a86f6f 3823echo "configure:3824: checking for working mmap" >&5
252b5132
RH
3824if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
3825 echo $ac_n "(cached) $ac_c" 1>&6
3826else
3827 if test "$cross_compiling" = yes; then
3828 ac_cv_func_mmap_fixed_mapped=no
3829else
3830 cat > conftest.$ac_ext <<EOF
e4a86f6f 3831#line 3832 "configure"
252b5132
RH
3832#include "confdefs.h"
3833
3834/* Thanks to Mike Haertel and Jim Avera for this test.
3835 Here is a matrix of mmap possibilities:
3836 mmap private not fixed
3837 mmap private fixed at somewhere currently unmapped
3838 mmap private fixed at somewhere already mapped
3839 mmap shared not fixed
3840 mmap shared fixed at somewhere currently unmapped
3841 mmap shared fixed at somewhere already mapped
3842 For private mappings, we should verify that changes cannot be read()
3843 back from the file, nor mmap's back from the file at a different
3844 address. (There have been systems where private was not correctly
3845 implemented like the infamous i386 svr4.0, and systems where the
3846 VM page cache was not coherent with the filesystem buffer cache
3847 like early versions of FreeBSD and possibly contemporary NetBSD.)
3848 For shared mappings, we should conversely verify that changes get
3849 propogated back to all the places they're supposed to be.
3850
3851 Grep wants private fixed already mapped.
3852 The main things grep needs to know about mmap are:
3853 * does it exist and is it safe to write into the mmap'd area
3854 * how to use it (BSD variants) */
3855#include <sys/types.h>
3856#include <fcntl.h>
3857#include <sys/mman.h>
3858
3859/* This mess was copied from the GNU getpagesize.h. */
3860#ifndef HAVE_GETPAGESIZE
3861# ifdef HAVE_UNISTD_H
3862# include <unistd.h>
3863# endif
3864
3865/* Assume that all systems that can run configure have sys/param.h. */
3866# ifndef HAVE_SYS_PARAM_H
3867# define HAVE_SYS_PARAM_H 1
3868# endif
3869
3870# ifdef _SC_PAGESIZE
3871# define getpagesize() sysconf(_SC_PAGESIZE)
3872# else /* no _SC_PAGESIZE */
3873# ifdef HAVE_SYS_PARAM_H
3874# include <sys/param.h>
3875# ifdef EXEC_PAGESIZE
3876# define getpagesize() EXEC_PAGESIZE
3877# else /* no EXEC_PAGESIZE */
3878# ifdef NBPG
3879# define getpagesize() NBPG * CLSIZE
3880# ifndef CLSIZE
3881# define CLSIZE 1
3882# endif /* no CLSIZE */
3883# else /* no NBPG */
3884# ifdef NBPC
3885# define getpagesize() NBPC
3886# else /* no NBPC */
3887# ifdef PAGESIZE
3888# define getpagesize() PAGESIZE
3889# endif /* PAGESIZE */
3890# endif /* no NBPC */
3891# endif /* no NBPG */
3892# endif /* no EXEC_PAGESIZE */
3893# else /* no HAVE_SYS_PARAM_H */
3894# define getpagesize() 8192 /* punt totally */
3895# endif /* no HAVE_SYS_PARAM_H */
3896# endif /* no _SC_PAGESIZE */
3897
3898#endif /* no HAVE_GETPAGESIZE */
3899
3900#ifdef __cplusplus
3901extern "C" { void *malloc(unsigned); }
3902#else
3903char *malloc();
3904#endif
3905
3906int
3907main()
3908{
3909 char *data, *data2, *data3;
3910 int i, pagesize;
3911 int fd;
3912
3913 pagesize = getpagesize();
3914
3915 /*
3916 * First, make a file with some known garbage in it.
3917 */
3918 data = malloc(pagesize);
3919 if (!data)
3920 exit(1);
3921 for (i = 0; i < pagesize; ++i)
3922 *(data + i) = rand();
3923 umask(0);
3924 fd = creat("conftestmmap", 0600);
3925 if (fd < 0)
3926 exit(1);
3927 if (write(fd, data, pagesize) != pagesize)
3928 exit(1);
3929 close(fd);
3930
3931 /*
3932 * Next, try to mmap the file at a fixed address which
3933 * already has something else allocated at it. If we can,
3934 * also make sure that we see the same garbage.
3935 */
3936 fd = open("conftestmmap", O_RDWR);
3937 if (fd < 0)
3938 exit(1);
3939 data2 = malloc(2 * pagesize);
3940 if (!data2)
3941 exit(1);
3942 data2 += (pagesize - ((int) data2 & (pagesize - 1))) & (pagesize - 1);
3943 if (data2 != mmap(data2, pagesize, PROT_READ | PROT_WRITE,
3944 MAP_PRIVATE | MAP_FIXED, fd, 0L))
3945 exit(1);
3946 for (i = 0; i < pagesize; ++i)
3947 if (*(data + i) != *(data2 + i))
3948 exit(1);
3949
3950 /*
3951 * Finally, make sure that changes to the mapped area
3952 * do not percolate back to the file as seen by read().
3953 * (This is a bug on some variants of i386 svr4.0.)
3954 */
3955 for (i = 0; i < pagesize; ++i)
3956 *(data2 + i) = *(data2 + i) + 1;
3957 data3 = malloc(pagesize);
3958 if (!data3)
3959 exit(1);
3960 if (read(fd, data3, pagesize) != pagesize)
3961 exit(1);
3962 for (i = 0; i < pagesize; ++i)
3963 if (*(data + i) != *(data3 + i))
3964 exit(1);
3965 close(fd);
3966 unlink("conftestmmap");
3967 exit(0);
3968}
3969
3970EOF
e4a86f6f 3971if { (eval echo configure:3972: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
252b5132
RH
3972then
3973 ac_cv_func_mmap_fixed_mapped=yes
3974else
3975 echo "configure: failed program was:" >&5
3976 cat conftest.$ac_ext >&5
3977 rm -fr conftest*
3978 ac_cv_func_mmap_fixed_mapped=no
3979fi
3980rm -fr conftest*
3981fi
3982
3983fi
3984
3985echo "$ac_t""$ac_cv_func_mmap_fixed_mapped" 1>&6
3986if test $ac_cv_func_mmap_fixed_mapped = yes; then
3987 cat >> confdefs.h <<\EOF
3988#define HAVE_MMAP 1
3989EOF
3990
3991fi
3992
3993
3994 for ac_hdr in argz.h limits.h locale.h nl_types.h malloc.h string.h \
3995unistd.h values.h sys/param.h
3996do
3997ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
3998echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
e4a86f6f 3999echo "configure:4000: checking for $ac_hdr" >&5
252b5132
RH
4000if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4001 echo $ac_n "(cached) $ac_c" 1>&6
4002else
4003 cat > conftest.$ac_ext <<EOF
e4a86f6f 4004#line 4005 "configure"
252b5132
RH
4005#include "confdefs.h"
4006#include <$ac_hdr>
4007EOF
4008ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
e4a86f6f 4009{ (eval echo configure:4010: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
252b5132
RH
4010ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4011if test -z "$ac_err"; then
4012 rm -rf conftest*
4013 eval "ac_cv_header_$ac_safe=yes"
4014else
4015 echo "$ac_err" >&5
4016 echo "configure: failed program was:" >&5
4017 cat conftest.$ac_ext >&5
4018 rm -rf conftest*
4019 eval "ac_cv_header_$ac_safe=no"
4020fi
4021rm -f conftest*
4022fi
4023if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4024 echo "$ac_t""yes" 1>&6
4025 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4026 cat >> confdefs.h <<EOF
4027#define $ac_tr_hdr 1
4028EOF
4029
4030else
4031 echo "$ac_t""no" 1>&6
4032fi
4033done
4034
4035 for ac_func in getcwd munmap putenv setenv setlocale strchr strcasecmp \
4036__argz_count __argz_stringify __argz_next
4037do
4038echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
e4a86f6f 4039echo "configure:4040: checking for $ac_func" >&5
252b5132
RH
4040if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
4041 echo $ac_n "(cached) $ac_c" 1>&6
4042else
4043 cat > conftest.$ac_ext <<EOF
e4a86f6f 4044#line 4045 "configure"
252b5132
RH
4045#include "confdefs.h"
4046/* System header to define __stub macros and hopefully few prototypes,
4047 which can conflict with char $ac_func(); below. */
4048#include <assert.h>
4049/* Override any gcc2 internal prototype to avoid an error. */
4050/* We use char because int might match the return type of a gcc2
4051 builtin and then its argument prototype would still apply. */
4052char $ac_func();
4053
4054int main() {
4055
4056/* The GNU C library defines this for functions which it implements
4057 to always fail with ENOSYS. Some functions are actually named
4058 something starting with __ and the normal name is an alias. */
4059#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
4060choke me
4061#else
4062$ac_func();
4063#endif
4064
4065; return 0; }
4066EOF
e4a86f6f 4067if { (eval echo configure:4068: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
4068 rm -rf conftest*
4069 eval "ac_cv_func_$ac_func=yes"
4070else
4071 echo "configure: failed program was:" >&5
4072 cat conftest.$ac_ext >&5
4073 rm -rf conftest*
4074 eval "ac_cv_func_$ac_func=no"
4075fi
4076rm -f conftest*
4077fi
4078
4079if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
4080 echo "$ac_t""yes" 1>&6
4081 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
4082 cat >> confdefs.h <<EOF
4083#define $ac_tr_func 1
4084EOF
4085
4086else
4087 echo "$ac_t""no" 1>&6
4088fi
4089done
4090
4091
4092 if test "${ac_cv_func_stpcpy+set}" != "set"; then
4093 for ac_func in stpcpy
4094do
4095echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
e4a86f6f 4096echo "configure:4097: checking for $ac_func" >&5
252b5132
RH
4097if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
4098 echo $ac_n "(cached) $ac_c" 1>&6
4099else
4100 cat > conftest.$ac_ext <<EOF
e4a86f6f 4101#line 4102 "configure"
252b5132
RH
4102#include "confdefs.h"
4103/* System header to define __stub macros and hopefully few prototypes,
4104 which can conflict with char $ac_func(); below. */
4105#include <assert.h>
4106/* Override any gcc2 internal prototype to avoid an error. */
4107/* We use char because int might match the return type of a gcc2
4108 builtin and then its argument prototype would still apply. */
4109char $ac_func();
4110
4111int main() {
4112
4113/* The GNU C library defines this for functions which it implements
4114 to always fail with ENOSYS. Some functions are actually named
4115 something starting with __ and the normal name is an alias. */
4116#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
4117choke me
4118#else
4119$ac_func();
4120#endif
4121
4122; return 0; }
4123EOF
e4a86f6f 4124if { (eval echo configure:4125: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
4125 rm -rf conftest*
4126 eval "ac_cv_func_$ac_func=yes"
4127else
4128 echo "configure: failed program was:" >&5
4129 cat conftest.$ac_ext >&5
4130 rm -rf conftest*
4131 eval "ac_cv_func_$ac_func=no"
4132fi
4133rm -f conftest*
4134fi
4135
4136if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
4137 echo "$ac_t""yes" 1>&6
4138 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
4139 cat >> confdefs.h <<EOF
4140#define $ac_tr_func 1
4141EOF
4142
4143else
4144 echo "$ac_t""no" 1>&6
4145fi
4146done
4147
4148 fi
4149 if test "${ac_cv_func_stpcpy}" = "yes"; then
4150 cat >> confdefs.h <<\EOF
4151#define HAVE_STPCPY 1
4152EOF
4153
4154 fi
4155
4156 if test $ac_cv_header_locale_h = yes; then
4157 echo $ac_n "checking for LC_MESSAGES""... $ac_c" 1>&6
e4a86f6f 4158echo "configure:4159: checking for LC_MESSAGES" >&5
252b5132
RH
4159if eval "test \"`echo '$''{'am_cv_val_LC_MESSAGES'+set}'`\" = set"; then
4160 echo $ac_n "(cached) $ac_c" 1>&6
4161else
4162 cat > conftest.$ac_ext <<EOF
e4a86f6f 4163#line 4164 "configure"
252b5132
RH
4164#include "confdefs.h"
4165#include <locale.h>
4166int main() {
4167return LC_MESSAGES
4168; return 0; }
4169EOF
e4a86f6f 4170if { (eval echo configure:4171: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
4171 rm -rf conftest*
4172 am_cv_val_LC_MESSAGES=yes
4173else
4174 echo "configure: failed program was:" >&5
4175 cat conftest.$ac_ext >&5
4176 rm -rf conftest*
4177 am_cv_val_LC_MESSAGES=no
4178fi
4179rm -f conftest*
4180fi
4181
4182echo "$ac_t""$am_cv_val_LC_MESSAGES" 1>&6
4183 if test $am_cv_val_LC_MESSAGES = yes; then
4184 cat >> confdefs.h <<\EOF
4185#define HAVE_LC_MESSAGES 1
4186EOF
4187
4188 fi
4189 fi
4190 echo $ac_n "checking whether NLS is requested""... $ac_c" 1>&6
e4a86f6f 4191echo "configure:4192: checking whether NLS is requested" >&5
252b5132
RH
4192 # Check whether --enable-nls or --disable-nls was given.
4193if test "${enable_nls+set}" = set; then
4194 enableval="$enable_nls"
4195 USE_NLS=$enableval
4196else
4197 USE_NLS=yes
4198fi
4199
4200 echo "$ac_t""$USE_NLS" 1>&6
4201
4202
4203 USE_INCLUDED_LIBINTL=no
4204
4205 if test "$USE_NLS" = "yes"; then
4206 cat >> confdefs.h <<\EOF
4207#define ENABLE_NLS 1
4208EOF
4209
4210 echo $ac_n "checking whether included gettext is requested""... $ac_c" 1>&6
e4a86f6f 4211echo "configure:4212: checking whether included gettext is requested" >&5
252b5132
RH
4212 # Check whether --with-included-gettext or --without-included-gettext was given.
4213if test "${with_included_gettext+set}" = set; then
4214 withval="$with_included_gettext"
4215 nls_cv_force_use_gnu_gettext=$withval
4216else
4217 nls_cv_force_use_gnu_gettext=no
4218fi
4219
4220 echo "$ac_t""$nls_cv_force_use_gnu_gettext" 1>&6
4221
4222 nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext"
4223 if test "$nls_cv_force_use_gnu_gettext" != "yes"; then
4224 nls_cv_header_intl=
4225 nls_cv_header_libgt=
4226 CATOBJEXT=NONE
4227
4228 ac_safe=`echo "libintl.h" | sed 'y%./+-%__p_%'`
4229echo $ac_n "checking for libintl.h""... $ac_c" 1>&6
e4a86f6f 4230echo "configure:4231: checking for libintl.h" >&5
252b5132
RH
4231if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4232 echo $ac_n "(cached) $ac_c" 1>&6
4233else
4234 cat > conftest.$ac_ext <<EOF
e4a86f6f 4235#line 4236 "configure"
252b5132
RH
4236#include "confdefs.h"
4237#include <libintl.h>
4238EOF
4239ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
e4a86f6f 4240{ (eval echo configure:4241: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
252b5132
RH
4241ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4242if test -z "$ac_err"; then
4243 rm -rf conftest*
4244 eval "ac_cv_header_$ac_safe=yes"
4245else
4246 echo "$ac_err" >&5
4247 echo "configure: failed program was:" >&5
4248 cat conftest.$ac_ext >&5
4249 rm -rf conftest*
4250 eval "ac_cv_header_$ac_safe=no"
4251fi
4252rm -f conftest*
4253fi
4254if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4255 echo "$ac_t""yes" 1>&6
4256 echo $ac_n "checking for gettext in libc""... $ac_c" 1>&6
e4a86f6f 4257echo "configure:4258: checking for gettext in libc" >&5
252b5132
RH
4258if eval "test \"`echo '$''{'gt_cv_func_gettext_libc'+set}'`\" = set"; then
4259 echo $ac_n "(cached) $ac_c" 1>&6
4260else
4261 cat > conftest.$ac_ext <<EOF
e4a86f6f 4262#line 4263 "configure"
252b5132
RH
4263#include "confdefs.h"
4264#include <libintl.h>
4265int main() {
4266return (int) gettext ("")
4267; return 0; }
4268EOF
e4a86f6f 4269if { (eval echo configure:4270: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
4270 rm -rf conftest*
4271 gt_cv_func_gettext_libc=yes
4272else
4273 echo "configure: failed program was:" >&5
4274 cat conftest.$ac_ext >&5
4275 rm -rf conftest*
4276 gt_cv_func_gettext_libc=no
4277fi
4278rm -f conftest*
4279fi
4280
4281echo "$ac_t""$gt_cv_func_gettext_libc" 1>&6
4282
4283 if test "$gt_cv_func_gettext_libc" != "yes"; then
4284 echo $ac_n "checking for bindtextdomain in -lintl""... $ac_c" 1>&6
e4a86f6f 4285echo "configure:4286: checking for bindtextdomain in -lintl" >&5
252b5132
RH
4286ac_lib_var=`echo intl'_'bindtextdomain | sed 'y%./+-%__p_%'`
4287if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4288 echo $ac_n "(cached) $ac_c" 1>&6
4289else
4290 ac_save_LIBS="$LIBS"
4291LIBS="-lintl $LIBS"
4292cat > conftest.$ac_ext <<EOF
e4a86f6f 4293#line 4294 "configure"
252b5132
RH
4294#include "confdefs.h"
4295/* Override any gcc2 internal prototype to avoid an error. */
4296/* We use char because int might match the return type of a gcc2
4297 builtin and then its argument prototype would still apply. */
4298char bindtextdomain();
4299
4300int main() {
4301bindtextdomain()
4302; return 0; }
4303EOF
e4a86f6f 4304if { (eval echo configure:4305: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
4305 rm -rf conftest*
4306 eval "ac_cv_lib_$ac_lib_var=yes"
4307else
4308 echo "configure: failed program was:" >&5
4309 cat conftest.$ac_ext >&5
4310 rm -rf conftest*
4311 eval "ac_cv_lib_$ac_lib_var=no"
4312fi
4313rm -f conftest*
4314LIBS="$ac_save_LIBS"
4315
4316fi
4317if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4318 echo "$ac_t""yes" 1>&6
4319 echo $ac_n "checking for gettext in libintl""... $ac_c" 1>&6
e4a86f6f 4320echo "configure:4321: checking for gettext in libintl" >&5
252b5132
RH
4321if eval "test \"`echo '$''{'gt_cv_func_gettext_libintl'+set}'`\" = set"; then
4322 echo $ac_n "(cached) $ac_c" 1>&6
4323else
4324 cat > conftest.$ac_ext <<EOF
e4a86f6f 4325#line 4326 "configure"
252b5132
RH
4326#include "confdefs.h"
4327
4328int main() {
4329return (int) gettext ("")
4330; return 0; }
4331EOF
e4a86f6f 4332if { (eval echo configure:4333: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
4333 rm -rf conftest*
4334 gt_cv_func_gettext_libintl=yes
4335else
4336 echo "configure: failed program was:" >&5
4337 cat conftest.$ac_ext >&5
4338 rm -rf conftest*
4339 gt_cv_func_gettext_libintl=no
4340fi
4341rm -f conftest*
4342fi
4343
4344echo "$ac_t""$gt_cv_func_gettext_libintl" 1>&6
4345else
4346 echo "$ac_t""no" 1>&6
4347fi
4348
4349 fi
4350
4351 if test "$gt_cv_func_gettext_libc" = "yes" \
4352 || test "$gt_cv_func_gettext_libintl" = "yes"; then
4353 cat >> confdefs.h <<\EOF
4354#define HAVE_GETTEXT 1
4355EOF
4356
4357 # Extract the first word of "msgfmt", so it can be a program name with args.
4358set dummy msgfmt; ac_word=$2
4359echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e4a86f6f 4360echo "configure:4361: checking for $ac_word" >&5
252b5132
RH
4361if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
4362 echo $ac_n "(cached) $ac_c" 1>&6
4363else
4364 case "$MSGFMT" in
4365 /*)
4366 ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
4367 ;;
4368 *)
4369 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
4370 for ac_dir in $PATH; do
4371 test -z "$ac_dir" && ac_dir=.
4372 if test -f $ac_dir/$ac_word; then
4373 if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then
4374 ac_cv_path_MSGFMT="$ac_dir/$ac_word"
4375 break
4376 fi
4377 fi
4378 done
4379 IFS="$ac_save_ifs"
4380 test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="no"
4381 ;;
4382esac
4383fi
4384MSGFMT="$ac_cv_path_MSGFMT"
4385if test -n "$MSGFMT"; then
4386 echo "$ac_t""$MSGFMT" 1>&6
4387else
4388 echo "$ac_t""no" 1>&6
4389fi
4390 if test "$MSGFMT" != "no"; then
4391 for ac_func in dcgettext
4392do
4393echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
e4a86f6f 4394echo "configure:4395: checking for $ac_func" >&5
252b5132
RH
4395if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
4396 echo $ac_n "(cached) $ac_c" 1>&6
4397else
4398 cat > conftest.$ac_ext <<EOF
e4a86f6f 4399#line 4400 "configure"
252b5132
RH
4400#include "confdefs.h"
4401/* System header to define __stub macros and hopefully few prototypes,
4402 which can conflict with char $ac_func(); below. */
4403#include <assert.h>
4404/* Override any gcc2 internal prototype to avoid an error. */
4405/* We use char because int might match the return type of a gcc2
4406 builtin and then its argument prototype would still apply. */
4407char $ac_func();
4408
4409int main() {
4410
4411/* The GNU C library defines this for functions which it implements
4412 to always fail with ENOSYS. Some functions are actually named
4413 something starting with __ and the normal name is an alias. */
4414#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
4415choke me
4416#else
4417$ac_func();
4418#endif
4419
4420; return 0; }
4421EOF
e4a86f6f 4422if { (eval echo configure:4423: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
4423 rm -rf conftest*
4424 eval "ac_cv_func_$ac_func=yes"
4425else
4426 echo "configure: failed program was:" >&5
4427 cat conftest.$ac_ext >&5
4428 rm -rf conftest*
4429 eval "ac_cv_func_$ac_func=no"
4430fi
4431rm -f conftest*
4432fi
4433
4434if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
4435 echo "$ac_t""yes" 1>&6
4436 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
4437 cat >> confdefs.h <<EOF
4438#define $ac_tr_func 1
4439EOF
4440
4441else
4442 echo "$ac_t""no" 1>&6
4443fi
4444done
4445
4446 # Extract the first word of "gmsgfmt", so it can be a program name with args.
4447set dummy gmsgfmt; ac_word=$2
4448echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e4a86f6f 4449echo "configure:4450: checking for $ac_word" >&5
252b5132
RH
4450if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
4451 echo $ac_n "(cached) $ac_c" 1>&6
4452else
4453 case "$GMSGFMT" in
4454 /*)
4455 ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
4456 ;;
4457 ?:/*)
4458 ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a dos path.
4459 ;;
4460 *)
4461 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4462 ac_dummy="$PATH"
4463 for ac_dir in $ac_dummy; do
4464 test -z "$ac_dir" && ac_dir=.
4465 if test -f $ac_dir/$ac_word; then
4466 ac_cv_path_GMSGFMT="$ac_dir/$ac_word"
4467 break
4468 fi
4469 done
4470 IFS="$ac_save_ifs"
4471 test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
4472 ;;
4473esac
4474fi
4475GMSGFMT="$ac_cv_path_GMSGFMT"
4476if test -n "$GMSGFMT"; then
4477 echo "$ac_t""$GMSGFMT" 1>&6
4478else
4479 echo "$ac_t""no" 1>&6
4480fi
4481
4482 # Extract the first word of "xgettext", so it can be a program name with args.
4483set dummy xgettext; ac_word=$2
4484echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e4a86f6f 4485echo "configure:4486: checking for $ac_word" >&5
252b5132
RH
4486if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
4487 echo $ac_n "(cached) $ac_c" 1>&6
4488else
4489 case "$XGETTEXT" in
4490 /*)
4491 ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
4492 ;;
4493 *)
4494 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
4495 for ac_dir in $PATH; do
4496 test -z "$ac_dir" && ac_dir=.
4497 if test -f $ac_dir/$ac_word; then
4498 if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then
4499 ac_cv_path_XGETTEXT="$ac_dir/$ac_word"
4500 break
4501 fi
4502 fi
4503 done
4504 IFS="$ac_save_ifs"
4505 test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
4506 ;;
4507esac
4508fi
4509XGETTEXT="$ac_cv_path_XGETTEXT"
4510if test -n "$XGETTEXT"; then
4511 echo "$ac_t""$XGETTEXT" 1>&6
4512else
4513 echo "$ac_t""no" 1>&6
4514fi
4515
4516 cat > conftest.$ac_ext <<EOF
e4a86f6f 4517#line 4518 "configure"
252b5132
RH
4518#include "confdefs.h"
4519
4520int main() {
4521extern int _nl_msg_cat_cntr;
4522 return _nl_msg_cat_cntr
4523; return 0; }
4524EOF
e4a86f6f 4525if { (eval echo configure:4526: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
4526 rm -rf conftest*
4527 CATOBJEXT=.gmo
4528 DATADIRNAME=share
4529else
4530 echo "configure: failed program was:" >&5
4531 cat conftest.$ac_ext >&5
4532 rm -rf conftest*
4533 CATOBJEXT=.mo
4534 DATADIRNAME=lib
4535fi
4536rm -f conftest*
4537 INSTOBJEXT=.mo
4538 fi
4539 fi
4540
4541else
4542 echo "$ac_t""no" 1>&6
4543fi
4544
4545
4546
4547 if test "$CATOBJEXT" = "NONE"; then
4548 nls_cv_use_gnu_gettext=yes
4549 fi
4550 fi
4551
4552 if test "$nls_cv_use_gnu_gettext" = "yes"; then
4553 INTLOBJS="\$(GETTOBJS)"
4554 # Extract the first word of "msgfmt", so it can be a program name with args.
4555set dummy msgfmt; ac_word=$2
4556echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e4a86f6f 4557echo "configure:4558: checking for $ac_word" >&5
252b5132
RH
4558if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
4559 echo $ac_n "(cached) $ac_c" 1>&6
4560else
4561 case "$MSGFMT" in
4562 /*)
4563 ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
4564 ;;
4565 *)
4566 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
4567 for ac_dir in $PATH; do
4568 test -z "$ac_dir" && ac_dir=.
4569 if test -f $ac_dir/$ac_word; then
4570 if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then
4571 ac_cv_path_MSGFMT="$ac_dir/$ac_word"
4572 break
4573 fi
4574 fi
4575 done
4576 IFS="$ac_save_ifs"
4577 test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="msgfmt"
4578 ;;
4579esac
4580fi
4581MSGFMT="$ac_cv_path_MSGFMT"
4582if test -n "$MSGFMT"; then
4583 echo "$ac_t""$MSGFMT" 1>&6
4584else
4585 echo "$ac_t""no" 1>&6
4586fi
4587
4588 # Extract the first word of "gmsgfmt", so it can be a program name with args.
4589set dummy gmsgfmt; ac_word=$2
4590echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e4a86f6f 4591echo "configure:4592: checking for $ac_word" >&5
252b5132
RH
4592if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
4593 echo $ac_n "(cached) $ac_c" 1>&6
4594else
4595 case "$GMSGFMT" in
4596 /*)
4597 ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
4598 ;;
4599 ?:/*)
4600 ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a dos path.
4601 ;;
4602 *)
4603 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4604 ac_dummy="$PATH"
4605 for ac_dir in $ac_dummy; do
4606 test -z "$ac_dir" && ac_dir=.
4607 if test -f $ac_dir/$ac_word; then
4608 ac_cv_path_GMSGFMT="$ac_dir/$ac_word"
4609 break
4610 fi
4611 done
4612 IFS="$ac_save_ifs"
4613 test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
4614 ;;
4615esac
4616fi
4617GMSGFMT="$ac_cv_path_GMSGFMT"
4618if test -n "$GMSGFMT"; then
4619 echo "$ac_t""$GMSGFMT" 1>&6
4620else
4621 echo "$ac_t""no" 1>&6
4622fi
4623
4624 # Extract the first word of "xgettext", so it can be a program name with args.
4625set dummy xgettext; ac_word=$2
4626echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e4a86f6f 4627echo "configure:4628: checking for $ac_word" >&5
252b5132
RH
4628if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
4629 echo $ac_n "(cached) $ac_c" 1>&6
4630else
4631 case "$XGETTEXT" in
4632 /*)
4633 ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
4634 ;;
4635 *)
4636 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
4637 for ac_dir in $PATH; do
4638 test -z "$ac_dir" && ac_dir=.
4639 if test -f $ac_dir/$ac_word; then
4640 if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then
4641 ac_cv_path_XGETTEXT="$ac_dir/$ac_word"
4642 break
4643 fi
4644 fi
4645 done
4646 IFS="$ac_save_ifs"
4647 test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
4648 ;;
4649esac
4650fi
4651XGETTEXT="$ac_cv_path_XGETTEXT"
4652if test -n "$XGETTEXT"; then
4653 echo "$ac_t""$XGETTEXT" 1>&6
4654else
4655 echo "$ac_t""no" 1>&6
4656fi
4657
4658
4659 USE_INCLUDED_LIBINTL=yes
4660 CATOBJEXT=.gmo
4661 INSTOBJEXT=.mo
4662 DATADIRNAME=share
4663 INTLDEPS='$(top_builddir)/../intl/libintl.a'
4664 INTLLIBS=$INTLDEPS
4665 LIBS=`echo $LIBS | sed -e 's/-lintl//'`
4666 nls_cv_header_intl=libintl.h
4667 nls_cv_header_libgt=libgettext.h
4668 fi
4669
4670 if test "$XGETTEXT" != ":"; then
4671 if $XGETTEXT --omit-header /dev/null 2> /dev/null; then
4672 : ;
4673 else
4674 echo "$ac_t""found xgettext programs is not GNU xgettext; ignore it" 1>&6
4675 XGETTEXT=":"
4676 fi
4677 fi
4678
4679 # We need to process the po/ directory.
4680 POSUB=po
4681 else
4682 DATADIRNAME=share
4683 nls_cv_header_intl=libintl.h
4684 nls_cv_header_libgt=libgettext.h
4685 fi
4686
4687 # If this is used in GNU gettext we have to set USE_NLS to `yes'
4688 # because some of the sources are only built for this goal.
4689 if test "$PACKAGE" = gettext; then
4690 USE_NLS=yes
4691 USE_INCLUDED_LIBINTL=yes
4692 fi
4693
4694 for lang in $ALL_LINGUAS; do
4695 GMOFILES="$GMOFILES $lang.gmo"
4696 POFILES="$POFILES $lang.po"
4697 done
4698
4699
4700
4701
4702
4703
4704
4705
4706
4707
4708
4709
4710
4711
4712 if test "x$CATOBJEXT" != "x"; then
4713 if test "x$ALL_LINGUAS" = "x"; then
4714 LINGUAS=
4715 else
4716 echo $ac_n "checking for catalogs to be installed""... $ac_c" 1>&6
e4a86f6f 4717echo "configure:4718: checking for catalogs to be installed" >&5
252b5132
RH
4718 NEW_LINGUAS=
4719 for lang in ${LINGUAS=$ALL_LINGUAS}; do
4720 case "$ALL_LINGUAS" in
4721 *$lang*) NEW_LINGUAS="$NEW_LINGUAS $lang" ;;
4722 esac
4723 done
4724 LINGUAS=$NEW_LINGUAS
4725 echo "$ac_t""$LINGUAS" 1>&6
4726 fi
4727
4728 if test -n "$LINGUAS"; then
4729 for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done
4730 fi
4731 fi
4732
4733 if test $ac_cv_header_locale_h = yes; then
4734 INCLUDE_LOCALE_H="#include <locale.h>"
4735 else
4736 INCLUDE_LOCALE_H="\
4737/* The system does not provide the header <locale.h>. Take care yourself. */"
4738 fi
4739
4740
4741 if test -f $srcdir/po2tbl.sed.in; then
4742 if test "$CATOBJEXT" = ".cat"; then
4743 ac_safe=`echo "linux/version.h" | sed 'y%./+-%__p_%'`
4744echo $ac_n "checking for linux/version.h""... $ac_c" 1>&6
e4a86f6f 4745echo "configure:4746: checking for linux/version.h" >&5
252b5132
RH
4746if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4747 echo $ac_n "(cached) $ac_c" 1>&6
4748else
4749 cat > conftest.$ac_ext <<EOF
e4a86f6f 4750#line 4751 "configure"
252b5132
RH
4751#include "confdefs.h"
4752#include <linux/version.h>
4753EOF
4754ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
e4a86f6f 4755{ (eval echo configure:4756: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
252b5132
RH
4756ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4757if test -z "$ac_err"; then
4758 rm -rf conftest*
4759 eval "ac_cv_header_$ac_safe=yes"
4760else
4761 echo "$ac_err" >&5
4762 echo "configure: failed program was:" >&5
4763 cat conftest.$ac_ext >&5
4764 rm -rf conftest*
4765 eval "ac_cv_header_$ac_safe=no"
4766fi
4767rm -f conftest*
4768fi
4769if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4770 echo "$ac_t""yes" 1>&6
4771 msgformat=linux
4772else
4773 echo "$ac_t""no" 1>&6
4774msgformat=xopen
4775fi
4776
4777
4778 sed -e '/^#/d' $srcdir/$msgformat-msg.sed > po2msg.sed
4779 fi
4780 sed -e '/^#.*[^\\]$/d' -e '/^#$/d' \
4781 $srcdir/po2tbl.sed.in > po2tbl.sed
4782 fi
4783
4784 if test "$PACKAGE" = "gettext"; then
4785 GT_NO="#NO#"
4786 GT_YES=
4787 else
4788 GT_NO=
4789 GT_YES="#YES#"
4790 fi
4791
4792
4793
4794 MKINSTALLDIRS="\$(srcdir)/../../mkinstalldirs"
4795
4796
4797 l=
4798
4799
4800 if test -d $srcdir/po; then
4801 test -d po || mkdir po
4802 if test "x$srcdir" != "x."; then
4803 if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then
4804 posrcprefix="$srcdir/"
4805 else
4806 posrcprefix="../$srcdir/"
4807 fi
4808 else
4809 posrcprefix="../"
4810 fi
4811 rm -f po/POTFILES
4812 sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \
4813 < $srcdir/po/POTFILES.in > po/POTFILES
4814 fi
4815
4816
4817echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
e4a86f6f 4818echo "configure:4819: checking whether to enable maintainer-specific portions of Makefiles" >&5
252b5132
RH
4819 # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
4820if test "${enable_maintainer_mode+set}" = set; then
4821 enableval="$enable_maintainer_mode"
4822 USE_MAINTAINER_MODE=$enableval
4823else
4824 USE_MAINTAINER_MODE=no
4825fi
4826
4827 echo "$ac_t""$USE_MAINTAINER_MODE" 1>&6
4828
4829
4830if test $USE_MAINTAINER_MODE = yes; then
4831 MAINTAINER_MODE_TRUE=
4832 MAINTAINER_MODE_FALSE='#'
4833else
4834 MAINTAINER_MODE_TRUE='#'
4835 MAINTAINER_MODE_FALSE=
4836fi
4837 MAINT=$MAINTAINER_MODE_TRUE
4838
4839
4840echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
e4a86f6f 4841echo "configure:4842: checking for Cygwin environment" >&5
252b5132
RH
4842if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
4843 echo $ac_n "(cached) $ac_c" 1>&6
4844else
4845 cat > conftest.$ac_ext <<EOF
e4a86f6f 4846#line 4847 "configure"
252b5132
RH
4847#include "confdefs.h"
4848
4849int main() {
4850
4851#ifndef __CYGWIN__
4852#define __CYGWIN__ __CYGWIN32__
4853#endif
4854return __CYGWIN__;
4855; return 0; }
4856EOF
e4a86f6f 4857if { (eval echo configure:4858: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
252b5132
RH
4858 rm -rf conftest*
4859 ac_cv_cygwin=yes
4860else
4861 echo "configure: failed program was:" >&5
4862 cat conftest.$ac_ext >&5
4863 rm -rf conftest*
4864 ac_cv_cygwin=no
4865fi
4866rm -f conftest*
4867rm -f conftest*
4868fi
4869
4870echo "$ac_t""$ac_cv_cygwin" 1>&6
4871CYGWIN=
4872test "$ac_cv_cygwin" = yes && CYGWIN=yes
4873echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
e4a86f6f 4874echo "configure:4875: checking for mingw32 environment" >&5
252b5132
RH
4875if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
4876 echo $ac_n "(cached) $ac_c" 1>&6
4877else
4878 cat > conftest.$ac_ext <<EOF
e4a86f6f 4879#line 4880 "configure"
252b5132
RH
4880#include "confdefs.h"
4881
4882int main() {
4883return __MINGW32__;
4884; return 0; }
4885EOF
e4a86f6f 4886if { (eval echo configure:4887: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
252b5132
RH
4887 rm -rf conftest*
4888 ac_cv_mingw32=yes
4889else
4890 echo "configure: failed program was:" >&5
4891 cat conftest.$ac_ext >&5
4892 rm -rf conftest*
4893 ac_cv_mingw32=no
4894fi
4895rm -f conftest*
4896rm -f conftest*
4897fi
4898
4899echo "$ac_t""$ac_cv_mingw32" 1>&6
4900MINGW32=
4901test "$ac_cv_mingw32" = yes && MINGW32=yes
4902
4903
4904echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
e4a86f6f 4905echo "configure:4906: checking for executable suffix" >&5
252b5132
RH
4906if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
4907 echo $ac_n "(cached) $ac_c" 1>&6
4908else
4909 if test "$CYGWIN" = yes || test "$MINGW32" = yes; then
4910 ac_cv_exeext=.exe
4911else
4912 rm -f conftest*
4913 echo 'int main () { return 0; }' > conftest.$ac_ext
4914 ac_cv_exeext=
e4a86f6f 4915 if { (eval echo configure:4916: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
252b5132
RH
4916 for file in conftest.*; do
4917 case $file in
bedf545c 4918 *.c | *.o | *.obj | *.ilk | *.pdb) ;;
252b5132
RH
4919 *) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
4920 esac
4921 done
4922 else
4923 { echo "configure: error: installation or configuration problem: compiler cannot create executables." 1>&2; exit 1; }
4924 fi
4925 rm -f conftest*
4926 test x"${ac_cv_exeext}" = x && ac_cv_exeext=no
4927fi
4928fi
4929
4930EXEEXT=""
4931test x"${ac_cv_exeext}" != xno && EXEEXT=${ac_cv_exeext}
4932echo "$ac_t""${ac_cv_exeext}" 1>&6
4933ac_exeext=$EXEEXT
4934
4935
4936for ac_hdr in string.h stdlib.h memory.h strings.h unistd.h stdarg.h varargs.h errno.h sys/types.h
4937do
4938ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4939echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
e4a86f6f 4940echo "configure:4941: checking for $ac_hdr" >&5
252b5132
RH
4941if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4942 echo $ac_n "(cached) $ac_c" 1>&6
4943else
4944 cat > conftest.$ac_ext <<EOF
e4a86f6f 4945#line 4946 "configure"
252b5132
RH
4946#include "confdefs.h"
4947#include <$ac_hdr>
4948EOF
4949ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
e4a86f6f 4950{ (eval echo configure:4951: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
252b5132
RH
4951ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4952if test -z "$ac_err"; then
4953 rm -rf conftest*
4954 eval "ac_cv_header_$ac_safe=yes"
4955else
4956 echo "$ac_err" >&5
4957 echo "configure: failed program was:" >&5
4958 cat conftest.$ac_ext >&5
4959 rm -rf conftest*
4960 eval "ac_cv_header_$ac_safe=no"
4961fi
4962rm -f conftest*
4963fi
4964if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4965 echo "$ac_t""yes" 1>&6
4966 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4967 cat >> confdefs.h <<EOF
4968#define $ac_tr_hdr 1
4969EOF
4970
4971else
4972 echo "$ac_t""no" 1>&6
4973fi
4974done
4975
4976
4977# Put this here so that autoconf's "cross-compiling" message doesn't confuse
4978# people who are not cross-compiling but are compiling cross-assemblers.
4979echo $ac_n "checking whether compiling a cross-assembler""... $ac_c" 1>&6
e4a86f6f 4980echo "configure:4981: checking whether compiling a cross-assembler" >&5
252b5132
RH
4981if test "${host}" = "${target}"; then
4982 cross_gas=no
4983else
4984 cross_gas=yes
4985 cat >> confdefs.h <<\EOF
4986#define CROSS_COMPILE 1
4987EOF
4988
4989fi
4990echo "$ac_t""$cross_gas" 1>&6
4991
4992# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
4993# for constant arguments. Useless!
4994echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
e4a86f6f 4995echo "configure:4996: checking for working alloca.h" >&5
252b5132
RH
4996if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
4997 echo $ac_n "(cached) $ac_c" 1>&6
4998else
4999 cat > conftest.$ac_ext <<EOF
e4a86f6f 5000#line 5001 "configure"
252b5132
RH
5001#include "confdefs.h"
5002#include <alloca.h>
5003int main() {
5004char *p = alloca(2 * sizeof(int));
5005; return 0; }
5006EOF
e4a86f6f 5007if { (eval echo configure:5008: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
5008 rm -rf conftest*
5009 ac_cv_header_alloca_h=yes
5010else
5011 echo "configure: failed program was:" >&5
5012 cat conftest.$ac_ext >&5
5013 rm -rf conftest*
5014 ac_cv_header_alloca_h=no
5015fi
5016rm -f conftest*
5017fi
5018
5019echo "$ac_t""$ac_cv_header_alloca_h" 1>&6
5020if test $ac_cv_header_alloca_h = yes; then
5021 cat >> confdefs.h <<\EOF
5022#define HAVE_ALLOCA_H 1
5023EOF
5024
5025fi
5026
5027echo $ac_n "checking for alloca""... $ac_c" 1>&6
e4a86f6f 5028echo "configure:5029: checking for alloca" >&5
252b5132
RH
5029if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
5030 echo $ac_n "(cached) $ac_c" 1>&6
5031else
5032 cat > conftest.$ac_ext <<EOF
e4a86f6f 5033#line 5034 "configure"
252b5132
RH
5034#include "confdefs.h"
5035
5036#ifdef __GNUC__
5037# define alloca __builtin_alloca
5038#else
5039# ifdef _MSC_VER
5040# include <malloc.h>
5041# define alloca _alloca
5042# else
5043# if HAVE_ALLOCA_H
5044# include <alloca.h>
5045# else
5046# ifdef _AIX
5047 #pragma alloca
5048# else
5049# ifndef alloca /* predefined by HP cc +Olibcalls */
5050char *alloca ();
5051# endif
5052# endif
5053# endif
5054# endif
5055#endif
5056
5057int main() {
5058char *p = (char *) alloca(1);
5059; return 0; }
5060EOF
e4a86f6f 5061if { (eval echo configure:5062: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
5062 rm -rf conftest*
5063 ac_cv_func_alloca_works=yes
5064else
5065 echo "configure: failed program was:" >&5
5066 cat conftest.$ac_ext >&5
5067 rm -rf conftest*
5068 ac_cv_func_alloca_works=no
5069fi
5070rm -f conftest*
5071fi
5072
5073echo "$ac_t""$ac_cv_func_alloca_works" 1>&6
5074if test $ac_cv_func_alloca_works = yes; then
5075 cat >> confdefs.h <<\EOF
5076#define HAVE_ALLOCA 1
5077EOF
5078
5079fi
5080
5081if test $ac_cv_func_alloca_works = no; then
5082 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
5083 # that cause trouble. Some versions do not even contain alloca or
5084 # contain a buggy version. If you still want to use their alloca,
5085 # use ar to extract alloca.o from them instead of compiling alloca.c.
5086 ALLOCA=alloca.${ac_objext}
5087 cat >> confdefs.h <<\EOF
5088#define C_ALLOCA 1
5089EOF
5090
5091
5092echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
e4a86f6f 5093echo "configure:5094: checking whether alloca needs Cray hooks" >&5
252b5132
RH
5094if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
5095 echo $ac_n "(cached) $ac_c" 1>&6
5096else
5097 cat > conftest.$ac_ext <<EOF
e4a86f6f 5098#line 5099 "configure"
252b5132
RH
5099#include "confdefs.h"
5100#if defined(CRAY) && ! defined(CRAY2)
5101webecray
5102#else
5103wenotbecray
5104#endif
5105
5106EOF
5107if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5108 egrep "webecray" >/dev/null 2>&1; then
5109 rm -rf conftest*
5110 ac_cv_os_cray=yes
5111else
5112 rm -rf conftest*
5113 ac_cv_os_cray=no
5114fi
5115rm -f conftest*
5116
5117fi
5118
5119echo "$ac_t""$ac_cv_os_cray" 1>&6
5120if test $ac_cv_os_cray = yes; then
5121for ac_func in _getb67 GETB67 getb67; do
5122 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
e4a86f6f 5123echo "configure:5124: checking for $ac_func" >&5
252b5132
RH
5124if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
5125 echo $ac_n "(cached) $ac_c" 1>&6
5126else
5127 cat > conftest.$ac_ext <<EOF
e4a86f6f 5128#line 5129 "configure"
252b5132
RH
5129#include "confdefs.h"
5130/* System header to define __stub macros and hopefully few prototypes,
5131 which can conflict with char $ac_func(); below. */
5132#include <assert.h>
5133/* Override any gcc2 internal prototype to avoid an error. */
5134/* We use char because int might match the return type of a gcc2
5135 builtin and then its argument prototype would still apply. */
5136char $ac_func();
5137
5138int main() {
5139
5140/* The GNU C library defines this for functions which it implements
5141 to always fail with ENOSYS. Some functions are actually named
5142 something starting with __ and the normal name is an alias. */
5143#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
5144choke me
5145#else
5146$ac_func();
5147#endif
5148
5149; return 0; }
5150EOF
e4a86f6f 5151if { (eval echo configure:5152: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
5152 rm -rf conftest*
5153 eval "ac_cv_func_$ac_func=yes"
5154else
5155 echo "configure: failed program was:" >&5
5156 cat conftest.$ac_ext >&5
5157 rm -rf conftest*
5158 eval "ac_cv_func_$ac_func=no"
5159fi
5160rm -f conftest*
5161fi
5162
5163if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
5164 echo "$ac_t""yes" 1>&6
5165 cat >> confdefs.h <<EOF
5166#define CRAY_STACKSEG_END $ac_func
5167EOF
5168
5169 break
5170else
5171 echo "$ac_t""no" 1>&6
5172fi
5173
5174done
5175fi
5176
5177echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
e4a86f6f 5178echo "configure:5179: checking stack direction for C alloca" >&5
252b5132
RH
5179if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
5180 echo $ac_n "(cached) $ac_c" 1>&6
5181else
5182 if test "$cross_compiling" = yes; then
5183 ac_cv_c_stack_direction=0
5184else
5185 cat > conftest.$ac_ext <<EOF
e4a86f6f 5186#line 5187 "configure"
252b5132
RH
5187#include "confdefs.h"
5188find_stack_direction ()
5189{
5190 static char *addr = 0;
5191 auto char dummy;
5192 if (addr == 0)
5193 {
5194 addr = &dummy;
5195 return find_stack_direction ();
5196 }
5197 else
5198 return (&dummy > addr) ? 1 : -1;
5199}
5200main ()
5201{
5202 exit (find_stack_direction() < 0);
5203}
5204EOF
e4a86f6f 5205if { (eval echo configure:5206: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
252b5132
RH
5206then
5207 ac_cv_c_stack_direction=1
5208else
5209 echo "configure: failed program was:" >&5
5210 cat conftest.$ac_ext >&5
5211 rm -fr conftest*
5212 ac_cv_c_stack_direction=-1
5213fi
5214rm -fr conftest*
5215fi
5216
5217fi
5218
5219echo "$ac_t""$ac_cv_c_stack_direction" 1>&6
5220cat >> confdefs.h <<EOF
5221#define STACK_DIRECTION $ac_cv_c_stack_direction
5222EOF
5223
5224fi
5225
5226echo $ac_n "checking for inline""... $ac_c" 1>&6
e4a86f6f 5227echo "configure:5228: checking for inline" >&5
252b5132
RH
5228if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
5229 echo $ac_n "(cached) $ac_c" 1>&6
5230else
5231 ac_cv_c_inline=no
5232for ac_kw in inline __inline__ __inline; do
5233 cat > conftest.$ac_ext <<EOF
e4a86f6f 5234#line 5235 "configure"
252b5132
RH
5235#include "confdefs.h"
5236
5237int main() {
5238} $ac_kw foo() {
5239; return 0; }
5240EOF
e4a86f6f 5241if { (eval echo configure:5242: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
252b5132
RH
5242 rm -rf conftest*
5243 ac_cv_c_inline=$ac_kw; break
5244else
5245 echo "configure: failed program was:" >&5
5246 cat conftest.$ac_ext >&5
5247fi
5248rm -f conftest*
5249done
5250
5251fi
5252
5253echo "$ac_t""$ac_cv_c_inline" 1>&6
5254case "$ac_cv_c_inline" in
5255 inline | yes) ;;
5256 no) cat >> confdefs.h <<\EOF
5257#define inline
5258EOF
5259 ;;
5260 *) cat >> confdefs.h <<EOF
5261#define inline $ac_cv_c_inline
5262EOF
5263 ;;
5264esac
5265
5266
5267# VMS doesn't have unlink.
5268for ac_func in unlink remove
5269do
5270echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
e4a86f6f 5271echo "configure:5272: checking for $ac_func" >&5
252b5132
RH
5272if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
5273 echo $ac_n "(cached) $ac_c" 1>&6
5274else
5275 cat > conftest.$ac_ext <<EOF
e4a86f6f 5276#line 5277 "configure"
252b5132
RH
5277#include "confdefs.h"
5278/* System header to define __stub macros and hopefully few prototypes,
5279 which can conflict with char $ac_func(); below. */
5280#include <assert.h>
5281/* Override any gcc2 internal prototype to avoid an error. */
5282/* We use char because int might match the return type of a gcc2
5283 builtin and then its argument prototype would still apply. */
5284char $ac_func();
5285
5286int main() {
5287
5288/* The GNU C library defines this for functions which it implements
5289 to always fail with ENOSYS. Some functions are actually named
5290 something starting with __ and the normal name is an alias. */
5291#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
5292choke me
5293#else
5294$ac_func();
5295#endif
5296
5297; return 0; }
5298EOF
e4a86f6f 5299if { (eval echo configure:5300: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
5300 rm -rf conftest*
5301 eval "ac_cv_func_$ac_func=yes"
5302else
5303 echo "configure: failed program was:" >&5
5304 cat conftest.$ac_ext >&5
5305 rm -rf conftest*
5306 eval "ac_cv_func_$ac_func=no"
5307fi
5308rm -f conftest*
5309fi
5310
5311if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
5312 echo "$ac_t""yes" 1>&6
5313 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
5314 cat >> confdefs.h <<EOF
5315#define $ac_tr_func 1
5316EOF
5317 break
5318else
5319 echo "$ac_t""no" 1>&6
5320fi
5321done
5322
5323
5324# Some systems don't have sbrk().
5325for ac_func in sbrk
5326do
5327echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
e4a86f6f 5328echo "configure:5329: checking for $ac_func" >&5
252b5132
RH
5329if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
5330 echo $ac_n "(cached) $ac_c" 1>&6
5331else
5332 cat > conftest.$ac_ext <<EOF
e4a86f6f 5333#line 5334 "configure"
252b5132
RH
5334#include "confdefs.h"
5335/* System header to define __stub macros and hopefully few prototypes,
5336 which can conflict with char $ac_func(); below. */
5337#include <assert.h>
5338/* Override any gcc2 internal prototype to avoid an error. */
5339/* We use char because int might match the return type of a gcc2
5340 builtin and then its argument prototype would still apply. */
5341char $ac_func();
5342
5343int main() {
5344
5345/* The GNU C library defines this for functions which it implements
5346 to always fail with ENOSYS. Some functions are actually named
5347 something starting with __ and the normal name is an alias. */
5348#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
5349choke me
5350#else
5351$ac_func();
5352#endif
5353
5354; return 0; }
5355EOF
e4a86f6f 5356if { (eval echo configure:5357: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
5357 rm -rf conftest*
5358 eval "ac_cv_func_$ac_func=yes"
5359else
5360 echo "configure: failed program was:" >&5
5361 cat conftest.$ac_ext >&5
5362 rm -rf conftest*
5363 eval "ac_cv_func_$ac_func=no"
5364fi
5365rm -f conftest*
5366fi
5367
5368if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
5369 echo "$ac_t""yes" 1>&6
5370 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
5371 cat >> confdefs.h <<EOF
5372#define $ac_tr_func 1
5373EOF
5374
5375else
5376 echo "$ac_t""no" 1>&6
5377fi
5378done
5379
5380
5381# Some non-ANSI preprocessors botch requoting inside strings. That's bad
5382# enough, but on some of those systems, the assert macro relies on requoting
5383# working properly!
5384echo $ac_n "checking for working assert macro""... $ac_c" 1>&6
e4a86f6f 5385echo "configure:5386: checking for working assert macro" >&5
252b5132
RH
5386if eval "test \"`echo '$''{'gas_cv_assert_ok'+set}'`\" = set"; then
5387 echo $ac_n "(cached) $ac_c" 1>&6
5388else
5389 cat > conftest.$ac_ext <<EOF
e4a86f6f 5390#line 5391 "configure"
252b5132
RH
5391#include "confdefs.h"
5392#include <assert.h>
5393#include <stdio.h>
5394int main() {
5395
5396/* check for requoting problems */
5397static int a, b, c, d;
5398static char *s;
5399assert (!strcmp(s, "foo bar baz quux"));
5400/* check for newline handling */
5401assert (a == b
5402 || c == d);
5403
5404; return 0; }
5405EOF
e4a86f6f 5406if { (eval echo configure:5407: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
5407 rm -rf conftest*
5408 gas_cv_assert_ok=yes
5409else
5410 echo "configure: failed program was:" >&5
5411 cat conftest.$ac_ext >&5
5412 rm -rf conftest*
5413 gas_cv_assert_ok=no
5414fi
5415rm -f conftest*
5416fi
5417echo "$ac_t""$gas_cv_assert_ok" 1>&6
5418test $gas_cv_assert_ok = yes || cat >> confdefs.h <<\EOF
5419#define BROKEN_ASSERT 1
5420EOF
5421
5422
5423
5424# On some systems, the system header files may not declare malloc, realloc,
5425# and free. There are places where gas needs these functions to have been
5426# declared -- such as when taking their addresses.
5427gas_test_headers="
5428#ifdef HAVE_MEMORY_H
5429#include <memory.h>
5430#endif
5431#ifdef HAVE_STRING_H
5432#include <string.h>
5433#else
5434#ifdef HAVE_STRINGS_H
5435#include <strings.h>
5436#endif
5437#endif
5438#ifdef HAVE_STDLIB_H
5439#include <stdlib.h>
5440#endif
5441#ifdef HAVE_UNISTD_H
5442#include <unistd.h>
5443#endif
5444"
5445
5446echo $ac_n "checking whether declaration is required for strstr""... $ac_c" 1>&6
e4a86f6f 5447echo "configure:5448: checking whether declaration is required for strstr" >&5
252b5132
RH
5448if eval "test \"`echo '$''{'gas_cv_decl_needed_strstr'+set}'`\" = set"; then
5449 echo $ac_n "(cached) $ac_c" 1>&6
5450else
5451 cat > conftest.$ac_ext <<EOF
e4a86f6f 5452#line 5453 "configure"
252b5132
RH
5453#include "confdefs.h"
5454$gas_test_headers
5455int main() {
5456
5457typedef char *(*f)();
5458f x;
5459x = (f) strstr;
5460
5461; return 0; }
5462EOF
e4a86f6f 5463if { (eval echo configure:5464: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
5464 rm -rf conftest*
5465 gas_cv_decl_needed_strstr=no
5466else
5467 echo "configure: failed program was:" >&5
5468 cat conftest.$ac_ext >&5
5469 rm -rf conftest*
5470 gas_cv_decl_needed_strstr=yes
5471fi
5472rm -f conftest*
5473fi
5474echo "$ac_t""$gas_cv_decl_needed_strstr" 1>&6
5475if test $gas_cv_decl_needed_strstr = yes; then
5476 cat >> confdefs.h <<\EOF
5477#define NEED_DECLARATION_STRSTR 1
5478EOF
5479
5480fi
5481
5482
5483echo $ac_n "checking whether declaration is required for malloc""... $ac_c" 1>&6
e4a86f6f 5484echo "configure:5485: checking whether declaration is required for malloc" >&5
252b5132
RH
5485if eval "test \"`echo '$''{'gas_cv_decl_needed_malloc'+set}'`\" = set"; then
5486 echo $ac_n "(cached) $ac_c" 1>&6
5487else
5488 cat > conftest.$ac_ext <<EOF
e4a86f6f 5489#line 5490 "configure"
252b5132
RH
5490#include "confdefs.h"
5491$gas_test_headers
5492int main() {
5493
5494typedef char *(*f)();
5495f x;
5496x = (f) malloc;
5497
5498; return 0; }
5499EOF
e4a86f6f 5500if { (eval echo configure:5501: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
5501 rm -rf conftest*
5502 gas_cv_decl_needed_malloc=no
5503else
5504 echo "configure: failed program was:" >&5
5505 cat conftest.$ac_ext >&5
5506 rm -rf conftest*
5507 gas_cv_decl_needed_malloc=yes
5508fi
5509rm -f conftest*
5510fi
5511echo "$ac_t""$gas_cv_decl_needed_malloc" 1>&6
5512if test $gas_cv_decl_needed_malloc = yes; then
5513 cat >> confdefs.h <<\EOF
5514#define NEED_DECLARATION_MALLOC 1
5515EOF
5516
5517fi
5518
5519
5520echo $ac_n "checking whether declaration is required for free""... $ac_c" 1>&6
e4a86f6f 5521echo "configure:5522: checking whether declaration is required for free" >&5
252b5132
RH
5522if eval "test \"`echo '$''{'gas_cv_decl_needed_free'+set}'`\" = set"; then
5523 echo $ac_n "(cached) $ac_c" 1>&6
5524else
5525 cat > conftest.$ac_ext <<EOF
e4a86f6f 5526#line 5527 "configure"
252b5132
RH
5527#include "confdefs.h"
5528$gas_test_headers
5529int main() {
5530
5531typedef void (*f)();
5532f x;
5533x = (f) free;
5534
5535; return 0; }
5536EOF
e4a86f6f 5537if { (eval echo configure:5538: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
5538 rm -rf conftest*
5539 gas_cv_decl_needed_free=no
5540else
5541 echo "configure: failed program was:" >&5
5542 cat conftest.$ac_ext >&5
5543 rm -rf conftest*
5544 gas_cv_decl_needed_free=yes
5545fi
5546rm -f conftest*
5547fi
5548echo "$ac_t""$gas_cv_decl_needed_free" 1>&6
5549if test $gas_cv_decl_needed_free = yes; then
5550 cat >> confdefs.h <<\EOF
5551#define NEED_DECLARATION_FREE 1
5552EOF
5553
5554fi
5555
5556
5557echo $ac_n "checking whether declaration is required for sbrk""... $ac_c" 1>&6
e4a86f6f 5558echo "configure:5559: checking whether declaration is required for sbrk" >&5
252b5132
RH
5559if eval "test \"`echo '$''{'gas_cv_decl_needed_sbrk'+set}'`\" = set"; then
5560 echo $ac_n "(cached) $ac_c" 1>&6
5561else
5562 cat > conftest.$ac_ext <<EOF
e4a86f6f 5563#line 5564 "configure"
252b5132
RH
5564#include "confdefs.h"
5565$gas_test_headers
5566int main() {
5567
5568typedef char *(*f)();
5569f x;
5570x = (f) sbrk;
5571
5572; return 0; }
5573EOF
e4a86f6f 5574if { (eval echo configure:5575: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
5575 rm -rf conftest*
5576 gas_cv_decl_needed_sbrk=no
5577else
5578 echo "configure: failed program was:" >&5
5579 cat conftest.$ac_ext >&5
5580 rm -rf conftest*
5581 gas_cv_decl_needed_sbrk=yes
5582fi
5583rm -f conftest*
5584fi
5585echo "$ac_t""$gas_cv_decl_needed_sbrk" 1>&6
5586if test $gas_cv_decl_needed_sbrk = yes; then
5587 cat >> confdefs.h <<\EOF
5588#define NEED_DECLARATION_SBRK 1
5589EOF
5590
5591fi
5592
5593
5594echo $ac_n "checking whether declaration is required for environ""... $ac_c" 1>&6
e4a86f6f 5595echo "configure:5596: checking whether declaration is required for environ" >&5
252b5132
RH
5596if eval "test \"`echo '$''{'gas_cv_decl_needed_environ'+set}'`\" = set"; then
5597 echo $ac_n "(cached) $ac_c" 1>&6
5598else
5599 cat > conftest.$ac_ext <<EOF
e4a86f6f 5600#line 5601 "configure"
252b5132
RH
5601#include "confdefs.h"
5602$gas_test_headers
5603int main() {
5604
5605typedef char **f;
5606f x;
5607x = (f) environ;
5608
5609; return 0; }
5610EOF
e4a86f6f 5611if { (eval echo configure:5612: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
5612 rm -rf conftest*
5613 gas_cv_decl_needed_environ=no
5614else
5615 echo "configure: failed program was:" >&5
5616 cat conftest.$ac_ext >&5
5617 rm -rf conftest*
5618 gas_cv_decl_needed_environ=yes
5619fi
5620rm -f conftest*
5621fi
5622echo "$ac_t""$gas_cv_decl_needed_environ" 1>&6
5623if test $gas_cv_decl_needed_environ = yes; then
5624 cat >> confdefs.h <<\EOF
5625#define NEED_DECLARATION_ENVIRON 1
5626EOF
5627
5628fi
5629
5630
5631# Does errno.h declare errno, or do we have to add a separate declaration
5632# for it?
5633
5634echo $ac_n "checking whether declaration is required for errno""... $ac_c" 1>&6
e4a86f6f 5635echo "configure:5636: checking whether declaration is required for errno" >&5
252b5132
RH
5636if eval "test \"`echo '$''{'gas_cv_decl_needed_errno'+set}'`\" = set"; then
5637 echo $ac_n "(cached) $ac_c" 1>&6
5638else
5639 cat > conftest.$ac_ext <<EOF
e4a86f6f 5640#line 5641 "configure"
252b5132
RH
5641#include "confdefs.h"
5642
5643#ifdef HAVE_ERRNO_H
5644#include <errno.h>
5645#endif
5646
5647int main() {
5648
5649typedef int f;
5650f x;
5651x = (f) errno;
5652
5653; return 0; }
5654EOF
e4a86f6f 5655if { (eval echo configure:5656: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
252b5132
RH
5656 rm -rf conftest*
5657 gas_cv_decl_needed_errno=no
5658else
5659 echo "configure: failed program was:" >&5
5660 cat conftest.$ac_ext >&5
5661 rm -rf conftest*
5662 gas_cv_decl_needed_errno=yes
5663fi
5664rm -f conftest*
5665fi
5666echo "$ac_t""$gas_cv_decl_needed_errno" 1>&6
5667if test $gas_cv_decl_needed_errno = yes; then
5668 cat >> confdefs.h <<\EOF
5669#define NEED_DECLARATION_ERRNO 1
5670EOF
5671
5672fi
5673
5674
5675
5676
5677trap '' 1 2 15
5678cat > confcache <<\EOF
5679# This file is a shell script that caches the results of configure
5680# tests run on this system so they can be shared between configure
5681# scripts and configure runs. It is not useful on other systems.
5682# If it contains results you don't want to keep, you may remove or edit it.
5683#
5684# By default, configure uses ./config.cache as the cache file,
5685# creating it if it does not exist already. You can give configure
5686# the --cache-file=FILE option to use a different cache file; that is
5687# what configure does when it calls configure scripts in
5688# subdirectories, so they share the cache.
5689# Giving --cache-file=/dev/null disables caching, for debugging configure.
5690# config.status only pays attention to the cache file if you give it the
5691# --recheck option to rerun configure.
5692#
5693EOF
5694# The following way of writing the cache mishandles newlines in values,
5695# but we know of no workaround that is simple, portable, and efficient.
5696# So, don't put newlines in cache variables' values.
5697# Ultrix sh set writes to stderr and can't be redirected directly,
5698# and sets the high bit in the cache file unless we assign to the vars.
5699(set) 2>&1 |
5700 case `(ac_space=' '; set | grep ac_space) 2>&1` in
5701 *ac_space=\ *)
5702 # `set' does not quote correctly, so add quotes (double-quote substitution
5703 # turns \\\\ into \\, and sed turns \\ into \).
5704 sed -n \
5705 -e "s/'/'\\\\''/g" \
5706 -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
5707 ;;
5708 *)
5709 # `set' quotes correctly as required by POSIX, so do not add quotes.
5710 sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
5711 ;;
5712 esac >> confcache
5713if cmp -s $cache_file confcache; then
5714 :
5715else
5716 if test -w $cache_file; then
5717 echo "updating cache $cache_file"
5718 cat confcache > $cache_file
5719 else
5720 echo "not updating unwritable cache $cache_file"
5721 fi
5722fi
5723rm -f confcache
5724
5725trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
5726
5727test "x$prefix" = xNONE && prefix=$ac_default_prefix
5728# Let make expand exec_prefix.
5729test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
5730
5731# Any assignment to VPATH causes Sun make to only execute
5732# the first set of double-colon rules, so remove it if not needed.
5733# If there is a colon in the path, we need to keep it.
5734if test "x$srcdir" = x.; then
5735 ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
5736fi
5737
5738trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
5739
5740DEFS=-DHAVE_CONFIG_H
5741
5742# Without the "./", some shells look in PATH for config.status.
5743: ${CONFIG_STATUS=./config.status}
5744
5745echo creating $CONFIG_STATUS
5746rm -f $CONFIG_STATUS
5747cat > $CONFIG_STATUS <<EOF
5748#! /bin/sh
5749# Generated automatically by configure.
5750# Run this file to recreate the current configuration.
5751# This directory was configured as follows,
5752# on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
5753#
5754# $0 $ac_configure_args
5755#
5756# Compiler output produced by configure, useful for debugging
5757# configure, is in ./config.log if it exists.
5758
5759ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
5760for ac_option
5761do
5762 case "\$ac_option" in
5763 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
5764 echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
5765 exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
5766 -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
5767 echo "$CONFIG_STATUS generated by autoconf version 2.13"
5768 exit 0 ;;
5769 -help | --help | --hel | --he | --h)
5770 echo "\$ac_cs_usage"; exit 0 ;;
5771 *) echo "\$ac_cs_usage"; exit 1 ;;
5772 esac
5773done
5774
5775ac_given_srcdir=$srcdir
5776ac_given_INSTALL="$INSTALL"
5777
5778trap '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
5779EOF
5780cat >> $CONFIG_STATUS <<EOF
5781
5782# Protect against being on the right side of a sed subst in config.status.
5783sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
5784 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
5785$ac_vpsub
5786$extrasub
5787s%@SHELL@%$SHELL%g
5788s%@CFLAGS@%$CFLAGS%g
5789s%@CPPFLAGS@%$CPPFLAGS%g
5790s%@CXXFLAGS@%$CXXFLAGS%g
5791s%@FFLAGS@%$FFLAGS%g
5792s%@DEFS@%$DEFS%g
5793s%@LDFLAGS@%$LDFLAGS%g
5794s%@LIBS@%$LIBS%g
5795s%@exec_prefix@%$exec_prefix%g
5796s%@prefix@%$prefix%g
5797s%@program_transform_name@%$program_transform_name%g
5798s%@bindir@%$bindir%g
5799s%@sbindir@%$sbindir%g
5800s%@libexecdir@%$libexecdir%g
5801s%@datadir@%$datadir%g
5802s%@sysconfdir@%$sysconfdir%g
5803s%@sharedstatedir@%$sharedstatedir%g
5804s%@localstatedir@%$localstatedir%g
5805s%@libdir@%$libdir%g
5806s%@includedir@%$includedir%g
5807s%@oldincludedir@%$oldincludedir%g
5808s%@infodir@%$infodir%g
5809s%@mandir@%$mandir%g
5810s%@host@%$host%g
5811s%@host_alias@%$host_alias%g
5812s%@host_cpu@%$host_cpu%g
5813s%@host_vendor@%$host_vendor%g
5814s%@host_os@%$host_os%g
5815s%@target@%$target%g
5816s%@target_alias@%$target_alias%g
5817s%@target_cpu@%$target_cpu%g
5818s%@target_vendor@%$target_vendor%g
5819s%@target_os@%$target_os%g
5820s%@build@%$build%g
5821s%@build_alias@%$build_alias%g
5822s%@build_cpu@%$build_cpu%g
5823s%@build_vendor@%$build_vendor%g
5824s%@build_os@%$build_os%g
5825s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
5826s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
5827s%@INSTALL_DATA@%$INSTALL_DATA%g
5828s%@PACKAGE@%$PACKAGE%g
5829s%@VERSION@%$VERSION%g
5830s%@ACLOCAL@%$ACLOCAL%g
5831s%@AUTOCONF@%$AUTOCONF%g
5832s%@AUTOMAKE@%$AUTOMAKE%g
5833s%@AUTOHEADER@%$AUTOHEADER%g
5834s%@MAKEINFO@%$MAKEINFO%g
5835s%@SET_MAKE@%$SET_MAKE%g
5836s%@RANLIB@%$RANLIB%g
5837s%@CC@%$CC%g
5838s%@LD@%$LD%g
5839s%@NM@%$NM%g
bedf545c 5840s%@USE_SYMBOL_UNDERSCORE@%$USE_SYMBOL_UNDERSCORE%g
252b5132 5841s%@LN_S@%$LN_S%g
252b5132
RH
5842s%@DLLTOOL@%$DLLTOOL%g
5843s%@AS@%$AS%g
bedf545c 5844s%@LIBTOOL@%$LIBTOOL%g
252b5132
RH
5845s%@cgen_cpu_prefix@%$cgen_cpu_prefix%g
5846s%@extra_objects@%$extra_objects%g
5847s%@target_cpu_type@%$target_cpu_type%g
5848s%@obj_format@%$obj_format%g
5849s%@te_file@%$te_file%g
5850s%@install_tooldir@%$install_tooldir%g
5851s%@atof@%$atof%g
5852s%@BFDLIB@%$BFDLIB%g
5853s%@OPCODES_LIB@%$OPCODES_LIB%g
5854s%@ALL_OBJ_DEPS@%$ALL_OBJ_DEPS%g
5855s%@YACC@%$YACC%g
5856s%@LEX@%$LEX%g
5857s%@LEXLIB@%$LEXLIB%g
5858s%@CPP@%$CPP%g
5859s%@LEX_OUTPUT_ROOT@%$LEX_OUTPUT_ROOT%g
5860s%@ALLOCA@%$ALLOCA%g
5861s%@USE_NLS@%$USE_NLS%g
5862s%@MSGFMT@%$MSGFMT%g
5863s%@GMSGFMT@%$GMSGFMT%g
5864s%@XGETTEXT@%$XGETTEXT%g
5865s%@USE_INCLUDED_LIBINTL@%$USE_INCLUDED_LIBINTL%g
5866s%@CATALOGS@%$CATALOGS%g
5867s%@CATOBJEXT@%$CATOBJEXT%g
5868s%@DATADIRNAME@%$DATADIRNAME%g
5869s%@GMOFILES@%$GMOFILES%g
5870s%@INSTOBJEXT@%$INSTOBJEXT%g
5871s%@INTLDEPS@%$INTLDEPS%g
5872s%@INTLLIBS@%$INTLLIBS%g
5873s%@INTLOBJS@%$INTLOBJS%g
5874s%@POFILES@%$POFILES%g
5875s%@POSUB@%$POSUB%g
5876s%@INCLUDE_LOCALE_H@%$INCLUDE_LOCALE_H%g
5877s%@GT_NO@%$GT_NO%g
5878s%@GT_YES@%$GT_YES%g
5879s%@MKINSTALLDIRS@%$MKINSTALLDIRS%g
5880s%@l@%$l%g
5881s%@MAINTAINER_MODE_TRUE@%$MAINTAINER_MODE_TRUE%g
5882s%@MAINTAINER_MODE_FALSE@%$MAINTAINER_MODE_FALSE%g
5883s%@MAINT@%$MAINT%g
5884s%@EXEEXT@%$EXEEXT%g
5885
5886CEOF
5887EOF
5888
5889cat >> $CONFIG_STATUS <<\EOF
5890
5891# Split the substitutions into bite-sized pieces for seds with
5892# small command number limits, like on Digital OSF/1 and HP-UX.
5893ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
5894ac_file=1 # Number of current file.
5895ac_beg=1 # First line for current file.
5896ac_end=$ac_max_sed_cmds # Line after last line for current file.
5897ac_more_lines=:
5898ac_sed_cmds=""
5899while $ac_more_lines; do
5900 if test $ac_beg -gt 1; then
5901 sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
5902 else
5903 sed "${ac_end}q" conftest.subs > conftest.s$ac_file
5904 fi
5905 if test ! -s conftest.s$ac_file; then
5906 ac_more_lines=false
5907 rm -f conftest.s$ac_file
5908 else
5909 if test -z "$ac_sed_cmds"; then
5910 ac_sed_cmds="sed -f conftest.s$ac_file"
5911 else
5912 ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
5913 fi
5914 ac_file=`expr $ac_file + 1`
5915 ac_beg=$ac_end
5916 ac_end=`expr $ac_end + $ac_max_sed_cmds`
5917 fi
5918done
5919if test -z "$ac_sed_cmds"; then
5920 ac_sed_cmds=cat
5921fi
5922EOF
5923
5924cat >> $CONFIG_STATUS <<EOF
5925
5926CONFIG_FILES=\${CONFIG_FILES-"Makefile doc/Makefile .gdbinit:gdbinit.in po/Makefile.in:po/Make-in"}
5927EOF
5928cat >> $CONFIG_STATUS <<\EOF
5929for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
5930 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
5931 case "$ac_file" in
5932 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
5933 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
5934 *) ac_file_in="${ac_file}.in" ;;
5935 esac
5936
5937 # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
5938
5939 # Remove last slash and all that follows it. Not all systems have dirname.
5940 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
5941 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
5942 # The file is in a subdirectory.
5943 test ! -d "$ac_dir" && mkdir "$ac_dir"
5944 ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
5945 # A "../" for each directory in $ac_dir_suffix.
5946 ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
5947 else
5948 ac_dir_suffix= ac_dots=
5949 fi
5950
5951 case "$ac_given_srcdir" in
5952 .) srcdir=.
5953 if test -z "$ac_dots"; then top_srcdir=.
5954 else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
5955 /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
5956 *) # Relative path.
5957 srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
5958 top_srcdir="$ac_dots$ac_given_srcdir" ;;
5959 esac
5960
5961 case "$ac_given_INSTALL" in
5962 [/$]*) INSTALL="$ac_given_INSTALL" ;;
5963 *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
5964 esac
5965
5966 echo creating "$ac_file"
5967 rm -f "$ac_file"
5968 configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
5969 case "$ac_file" in
5970 *Makefile*) ac_comsub="1i\\
5971# $configure_input" ;;
5972 *) ac_comsub= ;;
5973 esac
5974
5975 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
5976 sed -e "$ac_comsub
5977s%@configure_input@%$configure_input%g
5978s%@srcdir@%$srcdir%g
5979s%@top_srcdir@%$top_srcdir%g
5980s%@INSTALL@%$INSTALL%g
5981" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
5982fi; done
5983rm -f conftest.s*
5984
5985# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
5986# NAME is the cpp macro being defined and VALUE is the value it is being given.
5987#
5988# ac_d sets the value in "#define NAME VALUE" lines.
5989ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)'
5990ac_dB='\([ ][ ]*\)[^ ]*%\1#\2'
5991ac_dC='\3'
5992ac_dD='%g'
5993# ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
5994ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
5995ac_uB='\([ ]\)%\1#\2define\3'
5996ac_uC=' '
5997ac_uD='\4%g'
5998# ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
5999ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
6000ac_eB='$%\1#\2define\3'
6001ac_eC=' '
6002ac_eD='%g'
6003
6004if test "${CONFIG_HEADERS+set}" != set; then
6005EOF
6006cat >> $CONFIG_STATUS <<EOF
6007 CONFIG_HEADERS="config.h:config.in"
6008EOF
6009cat >> $CONFIG_STATUS <<\EOF
6010fi
6011for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
6012 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
6013 case "$ac_file" in
6014 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
6015 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
6016 *) ac_file_in="${ac_file}.in" ;;
6017 esac
6018
6019 echo creating $ac_file
6020
6021 rm -f conftest.frag conftest.in conftest.out
6022 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
6023 cat $ac_file_inputs > conftest.in
6024
6025EOF
6026
6027# Transform confdefs.h into a sed script conftest.vals that substitutes
6028# the proper values into config.h.in to produce config.h. And first:
6029# Protect against being on the right side of a sed subst in config.status.
6030# Protect against being in an unquoted here document in config.status.
6031rm -f conftest.vals
6032cat > conftest.hdr <<\EOF
6033s/[\\&%]/\\&/g
6034s%[\\$`]%\\&%g
6035s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
6036s%ac_d%ac_u%gp
6037s%ac_u%ac_e%gp
6038EOF
6039sed -n -f conftest.hdr confdefs.h > conftest.vals
6040rm -f conftest.hdr
6041
6042# This sed command replaces #undef with comments. This is necessary, for
6043# example, in the case of _POSIX_SOURCE, which is predefined and required
6044# on some systems where configure will not decide to define it.
6045cat >> conftest.vals <<\EOF
6046s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
6047EOF
6048
6049# Break up conftest.vals because some shells have a limit on
6050# the size of here documents, and old seds have small limits too.
6051
6052rm -f conftest.tail
6053while :
6054do
6055 ac_lines=`grep -c . conftest.vals`
6056 # grep -c gives empty output for an empty file on some AIX systems.
6057 if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
6058 # Write a limited-size here document to conftest.frag.
6059 echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
6060 sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
6061 echo 'CEOF
6062 sed -f conftest.frag conftest.in > conftest.out
6063 rm -f conftest.in
6064 mv conftest.out conftest.in
6065' >> $CONFIG_STATUS
6066 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
6067 rm -f conftest.vals
6068 mv conftest.tail conftest.vals
6069done
6070rm -f conftest.vals
6071
6072cat >> $CONFIG_STATUS <<\EOF
6073 rm -f conftest.frag conftest.h
6074 echo "/* $ac_file. Generated automatically by configure. */" > conftest.h
6075 cat conftest.in >> conftest.h
6076 rm -f conftest.in
6077 if cmp -s $ac_file conftest.h 2>/dev/null; then
6078 echo "$ac_file is unchanged"
6079 rm -f conftest.h
6080 else
6081 # Remove last slash and all that follows it. Not all systems have dirname.
6082 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
6083 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
6084 # The file is in a subdirectory.
6085 test ! -d "$ac_dir" && mkdir "$ac_dir"
6086 fi
6087 rm -f $ac_file
6088 mv conftest.h $ac_file
6089 fi
6090fi; done
6091
6092EOF
6093cat >> $CONFIG_STATUS <<EOF
6094
6095target_cpu_type=${target_cpu_type}
6096 cgen_cpu_prefix=${cgen_cpu_prefix}
6097 obj_format=${obj_format}
6098 te_file=${te_file}
6099EOF
6100cat >> $CONFIG_STATUS <<\EOF
6101test -z "$CONFIG_HEADERS" || echo timestamp > stamp-h
6102rm -f targ-cpu.c targ-cpu.h obj-format.h obj-format.c targ-env.h atof-targ.c itbl-cpu.h
6103 echo '#include "tc-'"${target_cpu_type}"'.h"' > targ-cpu.h
6104 echo '#include "obj-'"${obj_format}"'.h"' > obj-format.h
6105 echo '#include "te-'"${te_file}"'.h"' > targ-env.h
6106 echo '#include "itbl-'"${target_cpu_type}"'.h"' > itbl-cpu.h
6107 if test "x$cgen_cpu_prefix" != x ; then
6108 echo '#include "opcodes/'"${cgen_cpu_prefix}"'-desc.h"' > cgen-desc.h
6109 fi
6110
6111 sed -e '/POTFILES =/r po/POTFILES' po/Makefile.in > po/Makefile
6112exit 0
6113EOF
6114chmod +x $CONFIG_STATUS
6115rm -fr confdefs* $ac_clean_files
6116test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
6117
This page took 0.256654 seconds and 4 git commands to generate.