1999-07-23 Donn Terry <donn@interix.com>
[deliverable/binutils-gdb.git] / opcodes / 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=no]"
16ac_help="$ac_help
17 --enable-static[=PKGS] build static libraries [default=yes]"
18ac_help="$ac_help
19 --enable-fast-install[=PKGS] optimize for fast installation [default=yes]"
20ac_help="$ac_help
21 --with-gnu-ld assume the C compiler uses GNU ld [default=no]"
22ac_help="$ac_help
23 --disable-libtool-lock force libtool not to do file locking"
24ac_help="$ac_help
25 --enable-targets alternative target configurations"
26ac_help="$ac_help
27 --enable-commonbfdlib build shared BFD/opcodes/libiberty library"
28ac_help="$ac_help
29 --enable-maintainer-mode enable make rules and dependencies not useful
30 (and sometimes confusing) to the casual installer"
31ac_help="$ac_help
32 --disable-nls do not use Native Language Support"
33ac_help="$ac_help
34 --with-included-gettext use the GNU gettext library included here"
35ac_help="$ac_help
36 --enable-cgen-maint[=dir] build cgen generated files"
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=
54srcdir=
55target=NONE
56verbose=
57x_includes=NONE
58x_libraries=NONE
59bindir='${exec_prefix}/bin'
60sbindir='${exec_prefix}/sbin'
61libexecdir='${exec_prefix}/libexec'
62datadir='${prefix}/share'
63sysconfdir='${prefix}/etc'
64sharedstatedir='${prefix}/com'
65localstatedir='${prefix}/var'
66libdir='${exec_prefix}/lib'
67includedir='${prefix}/include'
68oldincludedir='/usr/include'
69infodir='${prefix}/info'
70mandir='${prefix}/man'
71
72# Initialize some other variables.
73subdirs=
74MFLAGS= MAKEFLAGS=
75SHELL=${CONFIG_SHELL-/bin/sh}
76# Maximum number of lines to put in a shell here document.
77ac_max_here_lines=12
78
79ac_prev=
80for ac_option
81do
82
83 # If the previous option needs an argument, assign it.
84 if test -n "$ac_prev"; then
85 eval "$ac_prev=\$ac_option"
86 ac_prev=
87 continue
88 fi
89
90 case "$ac_option" in
91 -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
92 *) ac_optarg= ;;
93 esac
94
95 # Accept the important Cygnus configure options, so we can diagnose typos.
96
97 case "$ac_option" in
98
99 -bindir | --bindir | --bindi | --bind | --bin | --bi)
100 ac_prev=bindir ;;
101 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
102 bindir="$ac_optarg" ;;
103
104 -build | --build | --buil | --bui | --bu)
105 ac_prev=build ;;
106 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
107 build="$ac_optarg" ;;
108
109 -cache-file | --cache-file | --cache-fil | --cache-fi \
110 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
111 ac_prev=cache_file ;;
112 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
113 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
114 cache_file="$ac_optarg" ;;
115
116 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
117 ac_prev=datadir ;;
118 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
119 | --da=*)
120 datadir="$ac_optarg" ;;
121
122 -disable-* | --disable-*)
123 ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
124 # Reject names that are not valid shell variable names.
125 if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
126 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
127 fi
128 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
129 eval "enable_${ac_feature}=no" ;;
130
131 -enable-* | --enable-*)
132 ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
133 # Reject names that are not valid shell variable names.
134 if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
135 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
136 fi
137 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
138 case "$ac_option" in
139 *=*) ;;
140 *) ac_optarg=yes ;;
141 esac
142 eval "enable_${ac_feature}='$ac_optarg'" ;;
143
144 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
145 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
146 | --exec | --exe | --ex)
147 ac_prev=exec_prefix ;;
148 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
149 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
150 | --exec=* | --exe=* | --ex=*)
151 exec_prefix="$ac_optarg" ;;
152
153 -gas | --gas | --ga | --g)
154 # Obsolete; use --with-gas.
155 with_gas=yes ;;
156
157 -help | --help | --hel | --he)
158 # Omit some internal or obsolete options to make the list less imposing.
159 # This message is too long to be a string in the A/UX 3.1 sh.
160 cat << EOF
161Usage: configure [options] [host]
162Options: [defaults in brackets after descriptions]
163Configuration:
164 --cache-file=FILE cache test results in FILE
165 --help print this message
166 --no-create do not create output files
167 --quiet, --silent do not print \`checking...' messages
168 --version print the version of autoconf that created configure
169Directory and file names:
170 --prefix=PREFIX install architecture-independent files in PREFIX
171 [$ac_default_prefix]
172 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
173 [same as prefix]
174 --bindir=DIR user executables in DIR [EPREFIX/bin]
175 --sbindir=DIR system admin executables in DIR [EPREFIX/sbin]
176 --libexecdir=DIR program executables in DIR [EPREFIX/libexec]
177 --datadir=DIR read-only architecture-independent data in DIR
178 [PREFIX/share]
179 --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc]
180 --sharedstatedir=DIR modifiable architecture-independent data in DIR
181 [PREFIX/com]
182 --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var]
183 --libdir=DIR object code libraries in DIR [EPREFIX/lib]
184 --includedir=DIR C header files in DIR [PREFIX/include]
185 --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include]
186 --infodir=DIR info documentation in DIR [PREFIX/info]
187 --mandir=DIR man documentation in DIR [PREFIX/man]
188 --srcdir=DIR find the sources in DIR [configure dir or ..]
189 --program-prefix=PREFIX prepend PREFIX to installed program names
190 --program-suffix=SUFFIX append SUFFIX to installed program names
191 --program-transform-name=PROGRAM
192 run sed PROGRAM on installed program names
193EOF
194 cat << EOF
195Host type:
196 --build=BUILD configure for building on BUILD [BUILD=HOST]
197 --host=HOST configure for HOST [guessed]
198 --target=TARGET configure for TARGET [TARGET=HOST]
199Features and packages:
200 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
201 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
202 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
203 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
204 --x-includes=DIR X include files are in DIR
205 --x-libraries=DIR X library files are in DIR
206EOF
207 if test -n "$ac_help"; then
208 echo "--enable and --with options recognized:$ac_help"
209 fi
210 exit 0 ;;
211
212 -host | --host | --hos | --ho)
213 ac_prev=host ;;
214 -host=* | --host=* | --hos=* | --ho=*)
215 host="$ac_optarg" ;;
216
217 -includedir | --includedir | --includedi | --included | --include \
218 | --includ | --inclu | --incl | --inc)
219 ac_prev=includedir ;;
220 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
221 | --includ=* | --inclu=* | --incl=* | --inc=*)
222 includedir="$ac_optarg" ;;
223
224 -infodir | --infodir | --infodi | --infod | --info | --inf)
225 ac_prev=infodir ;;
226 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
227 infodir="$ac_optarg" ;;
228
229 -libdir | --libdir | --libdi | --libd)
230 ac_prev=libdir ;;
231 -libdir=* | --libdir=* | --libdi=* | --libd=*)
232 libdir="$ac_optarg" ;;
233
234 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
235 | --libexe | --libex | --libe)
236 ac_prev=libexecdir ;;
237 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
238 | --libexe=* | --libex=* | --libe=*)
239 libexecdir="$ac_optarg" ;;
240
241 -localstatedir | --localstatedir | --localstatedi | --localstated \
242 | --localstate | --localstat | --localsta | --localst \
243 | --locals | --local | --loca | --loc | --lo)
244 ac_prev=localstatedir ;;
245 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
246 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
247 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
248 localstatedir="$ac_optarg" ;;
249
250 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
251 ac_prev=mandir ;;
252 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
253 mandir="$ac_optarg" ;;
254
255 -nfp | --nfp | --nf)
256 # Obsolete; use --without-fp.
257 with_fp=no ;;
258
259 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
260 | --no-cr | --no-c)
261 no_create=yes ;;
262
263 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
264 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
265 no_recursion=yes ;;
266
267 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
268 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
269 | --oldin | --oldi | --old | --ol | --o)
270 ac_prev=oldincludedir ;;
271 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
272 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
273 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
274 oldincludedir="$ac_optarg" ;;
275
276 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
277 ac_prev=prefix ;;
278 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
279 prefix="$ac_optarg" ;;
280
281 -program-prefix | --program-prefix | --program-prefi | --program-pref \
282 | --program-pre | --program-pr | --program-p)
283 ac_prev=program_prefix ;;
284 -program-prefix=* | --program-prefix=* | --program-prefi=* \
285 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
286 program_prefix="$ac_optarg" ;;
287
288 -program-suffix | --program-suffix | --program-suffi | --program-suff \
289 | --program-suf | --program-su | --program-s)
290 ac_prev=program_suffix ;;
291 -program-suffix=* | --program-suffix=* | --program-suffi=* \
292 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
293 program_suffix="$ac_optarg" ;;
294
295 -program-transform-name | --program-transform-name \
296 | --program-transform-nam | --program-transform-na \
297 | --program-transform-n | --program-transform- \
298 | --program-transform | --program-transfor \
299 | --program-transfo | --program-transf \
300 | --program-trans | --program-tran \
301 | --progr-tra | --program-tr | --program-t)
302 ac_prev=program_transform_name ;;
303 -program-transform-name=* | --program-transform-name=* \
304 | --program-transform-nam=* | --program-transform-na=* \
305 | --program-transform-n=* | --program-transform-=* \
306 | --program-transform=* | --program-transfor=* \
307 | --program-transfo=* | --program-transf=* \
308 | --program-trans=* | --program-tran=* \
309 | --progr-tra=* | --program-tr=* | --program-t=*)
310 program_transform_name="$ac_optarg" ;;
311
312 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
313 | -silent | --silent | --silen | --sile | --sil)
314 silent=yes ;;
315
316 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
317 ac_prev=sbindir ;;
318 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
319 | --sbi=* | --sb=*)
320 sbindir="$ac_optarg" ;;
321
322 -sharedstatedir | --sharedstatedir | --sharedstatedi \
323 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
324 | --sharedst | --shareds | --shared | --share | --shar \
325 | --sha | --sh)
326 ac_prev=sharedstatedir ;;
327 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
328 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
329 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
330 | --sha=* | --sh=*)
331 sharedstatedir="$ac_optarg" ;;
332
333 -site | --site | --sit)
334 ac_prev=site ;;
335 -site=* | --site=* | --sit=*)
336 site="$ac_optarg" ;;
337
338 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
339 ac_prev=srcdir ;;
340 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
341 srcdir="$ac_optarg" ;;
342
343 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
344 | --syscon | --sysco | --sysc | --sys | --sy)
345 ac_prev=sysconfdir ;;
346 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
347 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
348 sysconfdir="$ac_optarg" ;;
349
350 -target | --target | --targe | --targ | --tar | --ta | --t)
351 ac_prev=target ;;
352 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
353 target="$ac_optarg" ;;
354
355 -v | -verbose | --verbose | --verbos | --verbo | --verb)
356 verbose=yes ;;
357
358 -version | --version | --versio | --versi | --vers)
359 echo "configure generated by autoconf version 2.13"
360 exit 0 ;;
361
362 -with-* | --with-*)
363 ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
364 # Reject names that are not valid shell variable names.
365 if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
366 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
367 fi
368 ac_package=`echo $ac_package| sed 's/-/_/g'`
369 case "$ac_option" in
370 *=*) ;;
371 *) ac_optarg=yes ;;
372 esac
373 eval "with_${ac_package}='$ac_optarg'" ;;
374
375 -without-* | --without-*)
376 ac_package=`echo $ac_option|sed -e 's/-*without-//'`
377 # Reject names that are not valid shell variable names.
378 if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
379 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
380 fi
381 ac_package=`echo $ac_package| sed 's/-/_/g'`
382 eval "with_${ac_package}=no" ;;
383
384 --x)
385 # Obsolete; use --with-x.
386 with_x=yes ;;
387
388 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
389 | --x-incl | --x-inc | --x-in | --x-i)
390 ac_prev=x_includes ;;
391 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
392 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
393 x_includes="$ac_optarg" ;;
394
395 -x-libraries | --x-libraries | --x-librarie | --x-librari \
396 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
397 ac_prev=x_libraries ;;
398 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
399 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
400 x_libraries="$ac_optarg" ;;
401
402 -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
403 ;;
404
405 *)
406 if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
407 echo "configure: warning: $ac_option: invalid host type" 1>&2
408 fi
409 if test "x$nonopt" != xNONE; then
410 { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
411 fi
412 nonopt="$ac_option"
413 ;;
414
415 esac
416done
417
418if test -n "$ac_prev"; then
419 { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
420fi
421
422trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
423
424# File descriptor usage:
425# 0 standard input
426# 1 file creation
427# 2 errors and warnings
428# 3 some systems may open it to /dev/tty
429# 4 used on the Kubota Titan
430# 6 checking for... messages and results
431# 5 compiler messages saved in config.log
432if test "$silent" = yes; then
433 exec 6>/dev/null
434else
435 exec 6>&1
436fi
437exec 5>./config.log
438
439echo "\
440This file contains any messages produced by compilers while
441running configure, to aid debugging if configure makes a mistake.
442" 1>&5
443
444# Strip out --no-create and --no-recursion so they do not pile up.
445# Also quote any args containing shell metacharacters.
446ac_configure_args=
447for ac_arg
448do
449 case "$ac_arg" in
450 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
451 | --no-cr | --no-c) ;;
452 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
453 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
454 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
455 ac_configure_args="$ac_configure_args '$ac_arg'" ;;
456 *) ac_configure_args="$ac_configure_args $ac_arg" ;;
457 esac
458done
459
460# NLS nuisances.
461# Only set these to C if already set. These must not be set unconditionally
462# because not all systems understand e.g. LANG=C (notably SCO).
463# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
464# Non-C LC_CTYPE values break the ctype check.
465if test "${LANG+set}" = set; then LANG=C; export LANG; fi
466if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
467if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
468if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi
469
470# confdefs.h avoids OS command line length limits that DEFS can exceed.
471rm -rf conftest* confdefs.h
472# AIX cpp loses on an empty file, so make sure it contains at least a newline.
473echo > confdefs.h
474
475# A filename unique to this package, relative to the directory that
476# configure is in, which we can look for to find out if srcdir is correct.
477ac_unique_file=z8k-dis.c
478
479# Find the source files, if location was not specified.
480if test -z "$srcdir"; then
481 ac_srcdir_defaulted=yes
482 # Try the directory containing this script, then its parent.
483 ac_prog=$0
484 ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
485 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
486 srcdir=$ac_confdir
487 if test ! -r $srcdir/$ac_unique_file; then
488 srcdir=..
489 fi
490else
491 ac_srcdir_defaulted=no
492fi
493if test ! -r $srcdir/$ac_unique_file; then
494 if test "$ac_srcdir_defaulted" = yes; then
495 { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
496 else
497 { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
498 fi
499fi
500srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
501
502# Prefer explicitly selected file to automatically selected ones.
503if test -z "$CONFIG_SITE"; then
504 if test "x$prefix" != xNONE; then
505 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
506 else
507 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
508 fi
509fi
510for ac_site_file in $CONFIG_SITE; do
511 if test -r "$ac_site_file"; then
512 echo "loading site script $ac_site_file"
513 . "$ac_site_file"
514 fi
515done
516
517if test -r "$cache_file"; then
518 echo "loading cache $cache_file"
519 . $cache_file
520else
521 echo "creating cache $cache_file"
522 > $cache_file
523fi
524
525ac_ext=c
526# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
527ac_cpp='$CPP $CPPFLAGS'
528ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
529ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
530cross_compiling=$ac_cv_prog_cc_cross
531
532ac_exeext=
533ac_objext=o
534if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
535 # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
536 if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
537 ac_n= ac_c='
538' ac_t=' '
539 else
540 ac_n=-n ac_c= ac_t=
541 fi
542else
543 ac_n= ac_c='\c' ac_t=
544fi
545
546
547
548ac_aux_dir=
549for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
550 if test -f $ac_dir/install-sh; then
551 ac_aux_dir=$ac_dir
552 ac_install_sh="$ac_aux_dir/install-sh -c"
553 break
554 elif test -f $ac_dir/install.sh; then
555 ac_aux_dir=$ac_dir
556 ac_install_sh="$ac_aux_dir/install.sh -c"
557 break
558 fi
559done
560if test -z "$ac_aux_dir"; then
561 { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
562fi
563ac_config_guess=$ac_aux_dir/config.guess
564ac_config_sub=$ac_aux_dir/config.sub
565ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
566
567
568# Do some error checking and defaulting for the host and target type.
569# The inputs are:
570# configure --host=HOST --target=TARGET --build=BUILD NONOPT
571#
572# The rules are:
573# 1. You are not allowed to specify --host, --target, and nonopt at the
574# same time.
575# 2. Host defaults to nonopt.
576# 3. If nonopt is not specified, then host defaults to the current host,
577# as determined by config.guess.
578# 4. Target and build default to nonopt.
579# 5. If nonopt is not specified, then target and build default to host.
580
581# The aliases save the names the user supplied, while $host etc.
582# will get canonicalized.
583case $host---$target---$nonopt in
584NONE---*---* | *---NONE---* | *---*---NONE) ;;
585*) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;;
586esac
587
588
589# Make sure we can run config.sub.
590if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
591else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
592fi
593
594echo $ac_n "checking host system type""... $ac_c" 1>&6
595echo "configure:596: checking host system type" >&5
596
597host_alias=$host
598case "$host_alias" in
599NONE)
600 case $nonopt in
601 NONE)
602 if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
603 else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
604 fi ;;
605 *) host_alias=$nonopt ;;
606 esac ;;
607esac
608
609host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
610host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
611host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
612host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
613echo "$ac_t""$host" 1>&6
614
615echo $ac_n "checking target system type""... $ac_c" 1>&6
616echo "configure:617: checking target system type" >&5
617
618target_alias=$target
619case "$target_alias" in
620NONE)
621 case $nonopt in
622 NONE) target_alias=$host_alias ;;
623 *) target_alias=$nonopt ;;
624 esac ;;
625esac
626
627target=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $target_alias`
628target_cpu=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
629target_vendor=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
630target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
631echo "$ac_t""$target" 1>&6
632
633echo $ac_n "checking build system type""... $ac_c" 1>&6
634echo "configure:635: checking build system type" >&5
635
636build_alias=$build
637case "$build_alias" in
638NONE)
639 case $nonopt in
640 NONE) build_alias=$host_alias ;;
641 *) build_alias=$nonopt ;;
642 esac ;;
643esac
644
645build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias`
646build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
647build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
648build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
649echo "$ac_t""$build" 1>&6
650
651test "$host_alias" != "$target_alias" &&
652 test "$program_prefix$program_suffix$program_transform_name" = \
653 NONENONEs,x,x, &&
654 program_prefix=${target_alias}-
655
656# Extract the first word of "gcc", so it can be a program name with args.
657set dummy gcc; ac_word=$2
658echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
659echo "configure:660: checking for $ac_word" >&5
660if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
661 echo $ac_n "(cached) $ac_c" 1>&6
662else
663 if test -n "$CC"; then
664 ac_cv_prog_CC="$CC" # Let the user override the test.
665else
666 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
667 ac_dummy="$PATH"
668 for ac_dir in $ac_dummy; do
669 test -z "$ac_dir" && ac_dir=.
670 if test -f $ac_dir/$ac_word; then
671 ac_cv_prog_CC="gcc"
672 break
673 fi
674 done
675 IFS="$ac_save_ifs"
676fi
677fi
678CC="$ac_cv_prog_CC"
679if test -n "$CC"; then
680 echo "$ac_t""$CC" 1>&6
681else
682 echo "$ac_t""no" 1>&6
683fi
684
685if test -z "$CC"; then
686 # Extract the first word of "cc", so it can be a program name with args.
687set dummy cc; ac_word=$2
688echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
689echo "configure:690: checking for $ac_word" >&5
690if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
691 echo $ac_n "(cached) $ac_c" 1>&6
692else
693 if test -n "$CC"; then
694 ac_cv_prog_CC="$CC" # Let the user override the test.
695else
696 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
697 ac_prog_rejected=no
698 ac_dummy="$PATH"
699 for ac_dir in $ac_dummy; do
700 test -z "$ac_dir" && ac_dir=.
701 if test -f $ac_dir/$ac_word; then
702 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
703 ac_prog_rejected=yes
704 continue
705 fi
706 ac_cv_prog_CC="cc"
707 break
708 fi
709 done
710 IFS="$ac_save_ifs"
711if test $ac_prog_rejected = yes; then
712 # We found a bogon in the path, so make sure we never use it.
713 set dummy $ac_cv_prog_CC
714 shift
715 if test $# -gt 0; then
716 # We chose a different compiler from the bogus one.
717 # However, it has the same basename, so the bogon will be chosen
718 # first if we set CC to just the basename; use the full file name.
719 shift
720 set dummy "$ac_dir/$ac_word" "$@"
721 shift
722 ac_cv_prog_CC="$@"
723 fi
724fi
725fi
726fi
727CC="$ac_cv_prog_CC"
728if test -n "$CC"; then
729 echo "$ac_t""$CC" 1>&6
730else
731 echo "$ac_t""no" 1>&6
732fi
733
734 if test -z "$CC"; then
735 case "`uname -s`" in
736 *win32* | *WIN32*)
737 # Extract the first word of "cl", so it can be a program name with args.
738set dummy cl; ac_word=$2
739echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
740echo "configure:741: checking for $ac_word" >&5
741if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
742 echo $ac_n "(cached) $ac_c" 1>&6
743else
744 if test -n "$CC"; then
745 ac_cv_prog_CC="$CC" # Let the user override the test.
746else
747 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
748 ac_dummy="$PATH"
749 for ac_dir in $ac_dummy; do
750 test -z "$ac_dir" && ac_dir=.
751 if test -f $ac_dir/$ac_word; then
752 ac_cv_prog_CC="cl"
753 break
754 fi
755 done
756 IFS="$ac_save_ifs"
757fi
758fi
759CC="$ac_cv_prog_CC"
760if test -n "$CC"; then
761 echo "$ac_t""$CC" 1>&6
762else
763 echo "$ac_t""no" 1>&6
764fi
765 ;;
766 esac
767 fi
768 test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
769fi
770
771echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
772echo "configure:773: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
773
774ac_ext=c
775# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
776ac_cpp='$CPP $CPPFLAGS'
777ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
778ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
779cross_compiling=$ac_cv_prog_cc_cross
780
781cat > conftest.$ac_ext << EOF
782
783#line 784 "configure"
784#include "confdefs.h"
785
786main(){return(0);}
787EOF
788if { (eval echo configure:789: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
789 ac_cv_prog_cc_works=yes
790 # If we can't run a trivial program, we are probably using a cross compiler.
791 if (./conftest; exit) 2>/dev/null; then
792 ac_cv_prog_cc_cross=no
793 else
794 ac_cv_prog_cc_cross=yes
795 fi
796else
797 echo "configure: failed program was:" >&5
798 cat conftest.$ac_ext >&5
799 ac_cv_prog_cc_works=no
800fi
801rm -fr conftest*
802ac_ext=c
803# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
804ac_cpp='$CPP $CPPFLAGS'
805ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
806ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
807cross_compiling=$ac_cv_prog_cc_cross
808
809echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
810if test $ac_cv_prog_cc_works = no; then
811 { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
812fi
813echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
814echo "configure:815: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
815echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
816cross_compiling=$ac_cv_prog_cc_cross
817
818echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
819echo "configure:820: checking whether we are using GNU C" >&5
820if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
821 echo $ac_n "(cached) $ac_c" 1>&6
822else
823 cat > conftest.c <<EOF
824#ifdef __GNUC__
825 yes;
826#endif
827EOF
828if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:829: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
829 ac_cv_prog_gcc=yes
830else
831 ac_cv_prog_gcc=no
832fi
833fi
834
835echo "$ac_t""$ac_cv_prog_gcc" 1>&6
836
837if test $ac_cv_prog_gcc = yes; then
838 GCC=yes
839else
840 GCC=
841fi
842
843ac_test_CFLAGS="${CFLAGS+set}"
844ac_save_CFLAGS="$CFLAGS"
845CFLAGS=
846echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
847echo "configure:848: checking whether ${CC-cc} accepts -g" >&5
848if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
849 echo $ac_n "(cached) $ac_c" 1>&6
850else
851 echo 'void f(){}' > conftest.c
852if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
853 ac_cv_prog_cc_g=yes
854else
855 ac_cv_prog_cc_g=no
856fi
857rm -f conftest*
858
859fi
860
861echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
862if test "$ac_test_CFLAGS" = set; then
863 CFLAGS="$ac_save_CFLAGS"
864elif test $ac_cv_prog_cc_g = yes; then
865 if test "$GCC" = yes; then
866 CFLAGS="-g -O2"
867 else
868 CFLAGS="-g"
869 fi
870else
871 if test "$GCC" = yes; then
872 CFLAGS="-O2"
873 else
874 CFLAGS=
875 fi
876fi
877
878echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6
879echo "configure:880: checking for POSIXized ISC" >&5
880if test -d /etc/conf/kconfig.d &&
881 grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
882then
883 echo "$ac_t""yes" 1>&6
884 ISC=yes # If later tests want to check for ISC.
885 cat >> confdefs.h <<\EOF
886#define _POSIX_SOURCE 1
887EOF
888
889 if test "$GCC" = yes; then
890 CC="$CC -posix"
891 else
892 CC="$CC -Xp"
893 fi
894else
895 echo "$ac_t""no" 1>&6
896 ISC=
897fi
898
899
900# We currently only use the version number for the name of any shared
901# library. For user convenience, we always use the same version
902# number that BFD is using.
903BFD_VERSION=`grep INIT_AUTOMAKE ${srcdir}/../bfd/configure.in | sed -n -e 's/[ ]//g' -e 's/^.*,\(.*\)).*$/\1/p'`
904
905# Find a good install program. We prefer a C program (faster),
906# so one script is as good as another. But avoid the broken or
907# incompatible versions:
908# SysV /etc/install, /usr/sbin/install
909# SunOS /usr/etc/install
910# IRIX /sbin/install
911# AIX /bin/install
912# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
913# AFS /usr/afsws/bin/install, which mishandles nonexistent args
914# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
915# ./install, which can be erroneously created by make from ./install.sh.
916echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
917echo "configure:918: checking for a BSD compatible install" >&5
918if test -z "$INSTALL"; then
919if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
920 echo $ac_n "(cached) $ac_c" 1>&6
921else
922 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":"
923 for ac_dir in $PATH; do
924 # Account for people who put trailing slashes in PATH elements.
925 case "$ac_dir/" in
926 /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
927 *)
928 # OSF1 and SCO ODT 3.0 have their own names for install.
929 # Don't use installbsd from OSF since it installs stuff as root
930 # by default.
931 for ac_prog in ginstall scoinst install; do
932 if test -f $ac_dir/$ac_prog; then
933 if test $ac_prog = install &&
934 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
935 # AIX install. It has an incompatible calling convention.
936 :
937 else
938 ac_cv_path_install="$ac_dir/$ac_prog -c"
939 break 2
940 fi
941 fi
942 done
943 ;;
944 esac
945 done
946 IFS="$ac_save_IFS"
947
948fi
949 if test "${ac_cv_path_install+set}" = set; then
950 INSTALL="$ac_cv_path_install"
951 else
952 # As a last resort, use the slow shell script. We don't cache a
953 # path for INSTALL within a source directory, because that will
954 # break other packages using the cache if that directory is
955 # removed, or if the path is relative.
956 INSTALL="$ac_install_sh"
957 fi
958fi
959echo "$ac_t""$INSTALL" 1>&6
960
961# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
962# It thinks the first close brace ends the variable substitution.
963test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
964
965test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
966
967test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
968
969echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
970echo "configure:971: checking whether build environment is sane" >&5
971# Just in case
972sleep 1
973echo timestamp > conftestfile
974# Do `set' in a subshell so we don't clobber the current shell's
975# arguments. Must try -L first in case configure is actually a
976# symlink; some systems play weird games with the mod time of symlinks
977# (eg FreeBSD returns the mod time of the symlink's containing
978# directory).
979if (
980 set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
981 if test "$*" = "X"; then
982 # -L didn't work.
983 set X `ls -t $srcdir/configure conftestfile`
984 fi
985 if test "$*" != "X $srcdir/configure conftestfile" \
986 && test "$*" != "X conftestfile $srcdir/configure"; then
987
988 # If neither matched, then we have a broken ls. This can happen
989 # if, for instance, CONFIG_SHELL is bash and it inherits a
990 # broken ls alias from the environment. This has actually
991 # happened. Such a system could not be considered "sane".
992 { echo "configure: error: ls -t appears to fail. Make sure there is not a broken
993alias in your environment" 1>&2; exit 1; }
994 fi
995
996 test "$2" = conftestfile
997 )
998then
999 # Ok.
1000 :
1001else
1002 { echo "configure: error: newly created file is older than distributed files!
1003Check your system clock" 1>&2; exit 1; }
1004fi
1005rm -f conftest*
1006echo "$ac_t""yes" 1>&6
1007if test "$program_transform_name" = s,x,x,; then
1008 program_transform_name=
1009else
1010 # Double any \ or $. echo might interpret backslashes.
1011 cat <<\EOF_SED > conftestsed
1012s,\\,\\\\,g; s,\$,$$,g
1013EOF_SED
1014 program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
1015 rm -f conftestsed
1016fi
1017test "$program_prefix" != NONE &&
1018 program_transform_name="s,^,${program_prefix},; $program_transform_name"
1019# Use a double $ so make ignores it.
1020test "$program_suffix" != NONE &&
1021 program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
1022
1023# sed with no file args requires a program.
1024test "$program_transform_name" = "" && program_transform_name="s,x,x,"
1025
1026echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
1027echo "configure:1028: checking whether ${MAKE-make} sets \${MAKE}" >&5
1028set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
1029if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
1030 echo $ac_n "(cached) $ac_c" 1>&6
1031else
1032 cat > conftestmake <<\EOF
1033all:
1034 @echo 'ac_maketemp="${MAKE}"'
1035EOF
1036# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1037eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
1038if test -n "$ac_maketemp"; then
1039 eval ac_cv_prog_make_${ac_make}_set=yes
1040else
1041 eval ac_cv_prog_make_${ac_make}_set=no
1042fi
1043rm -f conftestmake
1044fi
1045if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
1046 echo "$ac_t""yes" 1>&6
1047 SET_MAKE=
1048else
1049 echo "$ac_t""no" 1>&6
1050 SET_MAKE="MAKE=${MAKE-make}"
1051fi
1052
1053
1054PACKAGE=opcodes
1055
1056VERSION=${BFD_VERSION}
1057
1058if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
1059 { echo "configure: error: source directory already configured; run "make distclean" there first" 1>&2; exit 1; }
1060fi
1061cat >> confdefs.h <<EOF
1062#define PACKAGE "$PACKAGE"
1063EOF
1064
1065cat >> confdefs.h <<EOF
1066#define VERSION "$VERSION"
1067EOF
1068
1069
1070
1071missing_dir=`cd $ac_aux_dir && pwd`
1072echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
1073echo "configure:1074: checking for working aclocal" >&5
1074# Run test in a subshell; some versions of sh will print an error if
1075# an executable is not found, even if stderr is redirected.
1076# Redirect stdin to placate older versions of autoconf. Sigh.
1077if (aclocal --version) < /dev/null > /dev/null 2>&1; then
1078 ACLOCAL=aclocal
1079 echo "$ac_t""found" 1>&6
1080else
1081 ACLOCAL="$missing_dir/missing aclocal"
1082 echo "$ac_t""missing" 1>&6
1083fi
1084
1085echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
1086echo "configure:1087: checking for working autoconf" >&5
1087# Run test in a subshell; some versions of sh will print an error if
1088# an executable is not found, even if stderr is redirected.
1089# Redirect stdin to placate older versions of autoconf. Sigh.
1090if (autoconf --version) < /dev/null > /dev/null 2>&1; then
1091 AUTOCONF=autoconf
1092 echo "$ac_t""found" 1>&6
1093else
1094 AUTOCONF="$missing_dir/missing autoconf"
1095 echo "$ac_t""missing" 1>&6
1096fi
1097
1098echo $ac_n "checking for working automake""... $ac_c" 1>&6
1099echo "configure:1100: checking for working automake" >&5
1100# Run test in a subshell; some versions of sh will print an error if
1101# an executable is not found, even if stderr is redirected.
1102# Redirect stdin to placate older versions of autoconf. Sigh.
1103if (automake --version) < /dev/null > /dev/null 2>&1; then
1104 AUTOMAKE=automake
1105 echo "$ac_t""found" 1>&6
1106else
1107 AUTOMAKE="$missing_dir/missing automake"
1108 echo "$ac_t""missing" 1>&6
1109fi
1110
1111echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
1112echo "configure:1113: checking for working autoheader" >&5
1113# Run test in a subshell; some versions of sh will print an error if
1114# an executable is not found, even if stderr is redirected.
1115# Redirect stdin to placate older versions of autoconf. Sigh.
1116if (autoheader --version) < /dev/null > /dev/null 2>&1; then
1117 AUTOHEADER=autoheader
1118 echo "$ac_t""found" 1>&6
1119else
1120 AUTOHEADER="$missing_dir/missing autoheader"
1121 echo "$ac_t""missing" 1>&6
1122fi
1123
1124echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
1125echo "configure:1126: checking for working makeinfo" >&5
1126# Run test in a subshell; some versions of sh will print an error if
1127# an executable is not found, even if stderr is redirected.
1128# Redirect stdin to placate older versions of autoconf. Sigh.
1129if (makeinfo --version) < /dev/null > /dev/null 2>&1; then
1130 MAKEINFO=makeinfo
1131 echo "$ac_t""found" 1>&6
1132else
1133 MAKEINFO="$missing_dir/missing makeinfo"
1134 echo "$ac_t""missing" 1>&6
1135fi
1136
1137
1138
1139if test $host != $build; then
1140 ac_tool_prefix=${host_alias}-
1141else
1142 ac_tool_prefix=
1143fi
1144
1145# Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
1146set dummy ${ac_tool_prefix}ar; ac_word=$2
1147echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1148echo "configure:1149: checking for $ac_word" >&5
1149if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
1150 echo $ac_n "(cached) $ac_c" 1>&6
1151else
1152 if test -n "$AR"; then
1153 ac_cv_prog_AR="$AR" # Let the user override the test.
1154else
1155 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1156 ac_dummy="$PATH"
1157 for ac_dir in $ac_dummy; do
1158 test -z "$ac_dir" && ac_dir=.
1159 if test -f $ac_dir/$ac_word; then
1160 ac_cv_prog_AR="${ac_tool_prefix}ar"
1161 break
1162 fi
1163 done
1164 IFS="$ac_save_ifs"
1165 test -z "$ac_cv_prog_AR" && ac_cv_prog_AR="ar"
1166fi
1167fi
1168AR="$ac_cv_prog_AR"
1169if test -n "$AR"; then
1170 echo "$ac_t""$AR" 1>&6
1171else
1172 echo "$ac_t""no" 1>&6
1173fi
1174
1175
1176
1177# Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
1178set dummy ${ac_tool_prefix}ranlib; ac_word=$2
1179echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1180echo "configure:1181: checking for $ac_word" >&5
1181if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
1182 echo $ac_n "(cached) $ac_c" 1>&6
1183else
1184 if test -n "$RANLIB"; then
1185 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
1186else
1187 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1188 ac_dummy="$PATH"
1189 for ac_dir in $ac_dummy; do
1190 test -z "$ac_dir" && ac_dir=.
1191 if test -f $ac_dir/$ac_word; then
1192 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
1193 break
1194 fi
1195 done
1196 IFS="$ac_save_ifs"
1197fi
1198fi
1199RANLIB="$ac_cv_prog_RANLIB"
1200if test -n "$RANLIB"; then
1201 echo "$ac_t""$RANLIB" 1>&6
1202else
1203 echo "$ac_t""no" 1>&6
1204fi
1205
1206
1207if test -z "$ac_cv_prog_RANLIB"; then
1208if test -n "$ac_tool_prefix"; then
1209 # Extract the first word of "ranlib", so it can be a program name with args.
1210set dummy ranlib; ac_word=$2
1211echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1212echo "configure:1213: checking for $ac_word" >&5
1213if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
1214 echo $ac_n "(cached) $ac_c" 1>&6
1215else
1216 if test -n "$RANLIB"; then
1217 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
1218else
1219 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1220 ac_dummy="$PATH"
1221 for ac_dir in $ac_dummy; do
1222 test -z "$ac_dir" && ac_dir=.
1223 if test -f $ac_dir/$ac_word; then
1224 ac_cv_prog_RANLIB="ranlib"
1225 break
1226 fi
1227 done
1228 IFS="$ac_save_ifs"
1229 test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
1230fi
1231fi
1232RANLIB="$ac_cv_prog_RANLIB"
1233if test -n "$RANLIB"; then
1234 echo "$ac_t""$RANLIB" 1>&6
1235else
1236 echo "$ac_t""no" 1>&6
1237fi
1238
1239else
1240 RANLIB=":"
1241fi
1242fi
1243
1244
1245# Check whether --enable-shared or --disable-shared was given.
1246if test "${enable_shared+set}" = set; then
1247 enableval="$enable_shared"
1248 p=${PACKAGE-default}
1249case "$enableval" in
1250yes) enable_shared=yes ;;
1251no) enable_shared=no ;;
1252*)
1253 enable_shared=no
1254 # Look at the argument we got. We use all the common list separators.
1255 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
1256 for pkg in $enableval; do
1257 if test "X$pkg" = "X$p"; then
1258 enable_shared=yes
1259 fi
1260 done
1261 IFS="$ac_save_ifs"
1262 ;;
1263esac
1264else
1265 enable_shared=no
1266fi
1267
1268
1269# Check whether --enable-static or --disable-static was given.
1270if test "${enable_static+set}" = set; then
1271 enableval="$enable_static"
1272 p=${PACKAGE-default}
1273case "$enableval" in
1274yes) enable_static=yes ;;
1275no) enable_static=no ;;
1276*)
1277 enable_static=no
1278 # Look at the argument we got. We use all the common list separators.
1279 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
1280 for pkg in $enableval; do
1281 if test "X$pkg" = "X$p"; then
1282 enable_static=yes
1283 fi
1284 done
1285 IFS="$ac_save_ifs"
1286 ;;
1287esac
1288else
1289 enable_static=yes
1290fi
1291
1292# Check whether --enable-fast-install or --disable-fast-install was given.
1293if test "${enable_fast_install+set}" = set; then
1294 enableval="$enable_fast_install"
1295 p=${PACKAGE-default}
1296case "$enableval" in
1297yes) enable_fast_install=yes ;;
1298no) enable_fast_install=no ;;
1299*)
1300 enable_fast_install=no
1301 # Look at the argument we got. We use all the common list separators.
1302 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
1303 for pkg in $enableval; do
1304 if test "X$pkg" = "X$p"; then
1305 enable_fast_install=yes
1306 fi
1307 done
1308 IFS="$ac_save_ifs"
1309 ;;
1310esac
1311else
1312 enable_fast_install=yes
1313fi
1314
1315# Extract the first word of "ranlib", so it can be a program name with args.
1316set dummy ranlib; ac_word=$2
1317echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1318echo "configure:1319: checking for $ac_word" >&5
1319if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
1320 echo $ac_n "(cached) $ac_c" 1>&6
1321else
1322 if test -n "$RANLIB"; then
1323 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
1324else
1325 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1326 ac_dummy="$PATH"
1327 for ac_dir in $ac_dummy; do
1328 test -z "$ac_dir" && ac_dir=.
1329 if test -f $ac_dir/$ac_word; then
1330 ac_cv_prog_RANLIB="ranlib"
1331 break
1332 fi
1333 done
1334 IFS="$ac_save_ifs"
1335 test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
1336fi
1337fi
1338RANLIB="$ac_cv_prog_RANLIB"
1339if test -n "$RANLIB"; then
1340 echo "$ac_t""$RANLIB" 1>&6
1341else
1342 echo "$ac_t""no" 1>&6
1343fi
1344
1345# Check whether --with-gnu-ld or --without-gnu-ld was given.
1346if test "${with_gnu_ld+set}" = set; then
1347 withval="$with_gnu_ld"
1348 test "$withval" = no || with_gnu_ld=yes
1349else
1350 with_gnu_ld=no
1351fi
1352
1353ac_prog=ld
1354if test "$ac_cv_prog_gcc" = yes; then
1355 # Check if gcc -print-prog-name=ld gives a path.
1356 echo $ac_n "checking for ld used by GCC""... $ac_c" 1>&6
1357echo "configure:1358: checking for ld used by GCC" >&5
1358 ac_prog=`($CC -print-prog-name=ld) 2>&5`
1359 case "$ac_prog" in
1360 # Accept absolute paths.
1361 /* | [A-Za-z]:[\\/]*)
1362 re_direlt='/[^/][^/]*/\.\./'
1363 # Canonicalize the path of ld
1364 ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
1365 while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
1366 ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
1367 done
1368 test -z "$LD" && LD="$ac_prog"
1369 ;;
1370 "")
1371 # If it fails, then pretend we aren't using GCC.
1372 ac_prog=ld
1373 ;;
1374 *)
1375 # If it is relative, then search for the first ld in PATH.
1376 with_gnu_ld=unknown
1377 ;;
1378 esac
1379elif test "$with_gnu_ld" = yes; then
1380 echo $ac_n "checking for GNU ld""... $ac_c" 1>&6
1381echo "configure:1382: checking for GNU ld" >&5
1382else
1383 echo $ac_n "checking for non-GNU ld""... $ac_c" 1>&6
1384echo "configure:1385: checking for non-GNU ld" >&5
1385fi
1386if eval "test \"`echo '$''{'ac_cv_path_LD'+set}'`\" = set"; then
1387 echo $ac_n "(cached) $ac_c" 1>&6
1388else
1389 if test -z "$LD"; then
1390 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1391 for ac_dir in $PATH; do
1392 test -z "$ac_dir" && ac_dir=.
1393 if test -f "$ac_dir/$ac_prog"; then
1394 ac_cv_path_LD="$ac_dir/$ac_prog"
1395 # Check to see if the program is GNU ld. I'd rather use --version,
1396 # but apparently some GNU ld's only accept -v.
1397 # Break only if it was the GNU/non-GNU ld that we prefer.
1398 if "$ac_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
1399 test "$with_gnu_ld" != no && break
1400 else
1401 test "$with_gnu_ld" != yes && break
1402 fi
1403 fi
1404 done
1405 IFS="$ac_save_ifs"
1406else
1407 ac_cv_path_LD="$LD" # Let the user override the test with a path.
1408fi
1409fi
1410
1411LD="$ac_cv_path_LD"
1412if test -n "$LD"; then
1413 echo "$ac_t""$LD" 1>&6
1414else
1415 echo "$ac_t""no" 1>&6
1416fi
1417test -z "$LD" && { echo "configure: error: no acceptable ld found in \$PATH" 1>&2; exit 1; }
1418
1419echo $ac_n "checking if the linker ($LD) is GNU ld""... $ac_c" 1>&6
1420echo "configure:1421: checking if the linker ($LD) is GNU ld" >&5
1421if eval "test \"`echo '$''{'ac_cv_prog_gnu_ld'+set}'`\" = set"; then
1422 echo $ac_n "(cached) $ac_c" 1>&6
1423else
1424 # I'd rather use --version here, but apparently some GNU ld's only accept -v.
1425if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
1426 ac_cv_prog_gnu_ld=yes
1427else
1428 ac_cv_prog_gnu_ld=no
1429fi
1430fi
1431
1432echo "$ac_t""$ac_cv_prog_gnu_ld" 1>&6
1433
1434
1435echo $ac_n "checking for BSD-compatible nm""... $ac_c" 1>&6
1436echo "configure:1437: checking for BSD-compatible nm" >&5
1437if eval "test \"`echo '$''{'ac_cv_path_NM'+set}'`\" = set"; then
1438 echo $ac_n "(cached) $ac_c" 1>&6
1439else
1440 if test -n "$NM"; then
1441 # Let the user override the test.
1442 ac_cv_path_NM="$NM"
1443else
1444 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1445 for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do
1446 test -z "$ac_dir" && ac_dir=.
1447 if test -f $ac_dir/nm; then
1448 # Check to see if the nm accepts a BSD-compat flag.
1449 # Adding the `sed 1q' prevents false positives on HP-UX, which says:
1450 # nm: unknown option "B" ignored
1451 if ($ac_dir/nm -B /dev/null 2>&1 | sed '1q'; exit 0) | egrep /dev/null >/dev/null; then
1452 ac_cv_path_NM="$ac_dir/nm -B"
1453 break
1454 elif ($ac_dir/nm -p /dev/null 2>&1 | sed '1q'; exit 0) | egrep /dev/null >/dev/null; then
1455 ac_cv_path_NM="$ac_dir/nm -p"
1456 break
1457 else
1458 ac_cv_path_NM=${ac_cv_path_NM="$ac_dir/nm"} # keep the first match, but
1459 continue # so that we can try to find one that supports BSD flags
1460 fi
1461 fi
1462 done
1463 IFS="$ac_save_ifs"
1464 test -z "$ac_cv_path_NM" && ac_cv_path_NM=nm
1465fi
1466fi
1467
1468NM="$ac_cv_path_NM"
1469echo "$ac_t""$NM" 1>&6
1470
1471
1472# Check for command to grab the raw symbol name followed by C symbol from nm.
1473echo $ac_n "checking command to parse $NM output""... $ac_c" 1>&6
1474echo "configure:1475: checking command to parse $NM output" >&5
1475if eval "test \"`echo '$''{'ac_cv_sys_global_symbol_pipe'+set}'`\" = set"; then
1476 echo $ac_n "(cached) $ac_c" 1>&6
1477else
1478 # These are sane defaults that work on at least a few old systems.
1479# {They come from Ultrix. What could be older than Ultrix?!! ;)}
1480
1481# Character class describing NM global symbol codes.
1482ac_symcode='[BCDEGRST]'
1483
1484# Regexp to match symbols that can be accessed directly from C.
1485ac_sympat='\([_A-Za-z][_A-Za-z0-9]*\)'
1486
1487# Transform the above into a raw symbol and a C symbol.
1488ac_symxfrm='\1 \2\3 \3'
1489
1490# Transform an extracted symbol line into a proper C declaration
1491ac_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern char \1;/p'"
1492
1493# Define system-specific variables.
1494case "$host_os" in
1495aix*)
1496 ac_symcode='[BCDT]'
1497 ;;
1498cygwin* | mingw*)
1499 ac_symcode='[ABCDGISTW]'
1500 ;;
1501hpux*)
1502 ac_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern char \1();/p' -e 's/^. .* \(.*\)$/extern char \1;/p'"
1503 ;;
1504irix*)
1505 ac_symcode='[BCDEGRST]'
1506 ;;
1507solaris*)
1508 ac_symcode='[BDT]'
1509 ;;
1510esac
1511
1512# If we're using GNU nm, then use its standard symbol codes.
1513if $NM -V 2>&1 | egrep '(GNU|with BFD)' > /dev/null; then
1514 ac_symcode='[ABCDGISTW]'
1515fi
1516
1517# Try without a prefix undercore, then with it.
1518for ac_symprfx in "" "_"; do
1519
1520 ac_cv_sys_global_symbol_pipe="sed -n -e 's/^.* \($ac_symcode\) *\($ac_symprfx\)$ac_sympat$/$ac_symxfrm/p'"
1521
1522 # Check to see that the pipe works correctly.
1523 ac_pipe_works=no
1524 rm -f conftest.$ac_ext
1525 cat > conftest.$ac_ext <<EOF
1526#ifdef __cplusplus
1527extern "C" {
1528#endif
1529char nm_test_var;
1530void nm_test_func(){}
1531#ifdef __cplusplus
1532}
1533#endif
1534int main(){nm_test_var='a';nm_test_func;return 0;}
1535EOF
1536
1537 if { (eval echo configure:1538: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1538 # Now try to grab the symbols.
1539 ac_nlist=conftest.nm
1540
1541 if { (eval echo configure:1542: \"$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
1542
1543 # Try sorting and uniquifying the output.
1544 if sort "$ac_nlist" | uniq > "$ac_nlist"T; then
1545 mv -f "$ac_nlist"T "$ac_nlist"
1546 else
1547 rm -f "$ac_nlist"T
1548 fi
1549
1550 # Make sure that we snagged all the symbols we need.
1551 if egrep ' nm_test_var$' "$ac_nlist" >/dev/null; then
1552 if egrep ' nm_test_func$' "$ac_nlist" >/dev/null; then
1553 cat <<EOF > conftest.c
1554#ifdef __cplusplus
1555extern "C" {
1556#endif
1557
1558EOF
1559 # Now generate the symbol file.
1560 eval "$ac_global_symbol_to_cdecl"' < "$ac_nlist" >> conftest.c'
1561
1562 cat <<EOF >> conftest.c
1563#if defined (__STDC__) && __STDC__
1564# define lt_ptr_t void *
1565#else
1566# define lt_ptr_t char *
1567# define const
1568#endif
1569
1570/* The mapping between symbol names and symbols. */
1571const struct {
1572 const char *name;
1573 lt_ptr_t address;
1574}
1575lt_preloaded_symbols[] =
1576{
1577EOF
1578 sed 's/^. \(.*\) \(.*\)$/ {"\2", (lt_ptr_t) \&\2},/' < "$ac_nlist" >> conftest.c
1579 cat <<\EOF >> conftest.c
1580 {0, (lt_ptr_t) 0}
1581};
1582
1583#ifdef __cplusplus
1584}
1585#endif
1586EOF
1587 # Now try linking the two files.
1588 mv conftest.$ac_objext conftestm.$ac_objext
1589 ac_save_LIBS="$LIBS"
1590 ac_save_CFLAGS="$CFLAGS"
1591 LIBS="conftestm.$ac_objext"
1592 CFLAGS="$CFLAGS$no_builtin_flag"
1593 if { (eval echo configure:1594: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1594 ac_pipe_works=yes
1595 else
1596 echo "configure: failed program was:" >&5
1597 cat conftest.c >&5
1598 fi
1599 LIBS="$ac_save_LIBS"
1600 CFLAGS="$ac_save_CFLAGS"
1601 else
1602 echo "cannot find nm_test_func in $ac_nlist" >&5
1603 fi
1604 else
1605 echo "cannot find nm_test_var in $ac_nlist" >&5
1606 fi
1607 else
1608 echo "cannot run $ac_cv_sys_global_symbol_pipe" >&5
1609 fi
1610 else
1611 echo "$progname: failed program was:" >&5
1612 cat conftest.c >&5
1613 fi
1614 rm -rf conftest*
1615
1616 # Do not use the global_symbol_pipe unless it works.
1617 if test "$ac_pipe_works" = yes; then
1618 if test x"$ac_symprfx" = x"_"; then
1619 ac_cv_sys_symbol_underscore=yes
1620 else
1621 ac_cv_sys_symbol_underscore=no
1622 fi
1623 break
1624 else
1625 ac_cv_sys_global_symbol_pipe=
1626 fi
1627done
1628
1629fi
1630
1631
1632ac_result=yes
1633if test -z "$ac_cv_sys_global_symbol_pipe"; then
1634 ac_result=no
1635fi
1636echo "$ac_t""$ac_result" 1>&6
1637
1638echo $ac_n "checking for _ prefix in compiled symbols""... $ac_c" 1>&6
1639echo "configure:1640: checking for _ prefix in compiled symbols" >&5
1640if eval "test \"`echo '$''{'ac_cv_sys_symbol_underscore'+set}'`\" = set"; then
1641 echo $ac_n "(cached) $ac_c" 1>&6
1642else
1643 ac_cv_sys_symbol_underscore=no
1644cat > conftest.$ac_ext <<EOF
1645void nm_test_func(){}
1646int main(){nm_test_func;return 0;}
1647EOF
1648if { (eval echo configure:1649: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1649 # Now try to grab the symbols.
1650 ac_nlist=conftest.nm
1651 if { (eval echo configure:1652: \"$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
1652 # See whether the symbols have a leading underscore.
1653 if egrep '^. _nm_test_func' "$ac_nlist" >/dev/null; then
1654 ac_cv_sys_symbol_underscore=yes
1655 else
1656 if egrep '^. nm_test_func ' "$ac_nlist" >/dev/null; then
1657 :
1658 else
1659 echo "configure: cannot find nm_test_func in $ac_nlist" >&5
1660 fi
1661 fi
1662 else
1663 echo "configure: cannot run $ac_cv_sys_global_symbol_pipe" >&5
1664 fi
1665else
1666 echo "configure: failed program was:" >&5
1667 cat conftest.c >&5
1668fi
1669rm -rf conftest*
1670
1671fi
1672
1673echo "$ac_t""$ac_cv_sys_symbol_underscore" 1>&6
1674USE_SYMBOL_UNDERSCORE=${ac_cv_sys_symbol_underscore=no}
1675
1676echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
1677echo "configure:1678: checking whether ln -s works" >&5
1678if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
1679 echo $ac_n "(cached) $ac_c" 1>&6
1680else
1681 rm -f conftestdata
1682if ln -s X conftestdata 2>/dev/null
1683then
1684 rm -f conftestdata
1685 ac_cv_prog_LN_S="ln -s"
1686else
1687 ac_cv_prog_LN_S=ln
1688fi
1689fi
1690LN_S="$ac_cv_prog_LN_S"
1691if test "$ac_cv_prog_LN_S" = "ln -s"; then
1692 echo "$ac_t""yes" 1>&6
1693else
1694 echo "$ac_t""no" 1>&6
1695fi
1696
1697
1698# Check for any special flags to pass to ltconfig.
1699libtool_flags="--cache-file=$cache_file"
1700test "$enable_shared" = no && libtool_flags="$libtool_flags --disable-shared"
1701test "$enable_static" = no && libtool_flags="$libtool_flags --disable-static"
1702test "$enable_fast_install" = no && libtool_flags="$libtool_flags --disable-fast-install"
1703test "$lt_dlopen" = yes && libtool_flags="$libtool_flags --enable-dlopen"
1704test "$silent" = yes && libtool_flags="$libtool_flags --silent"
1705test "$ac_cv_prog_gcc" = yes && libtool_flags="$libtool_flags --with-gcc"
1706test "$ac_cv_prog_gnu_ld" = yes && libtool_flags="$libtool_flags --with-gnu-ld"
1707
1708# Some flags need to be propagated to the compiler or linker for good
1709# libtool support.
1710case "$host" in
1711*-*-irix6*)
1712 # Find out which ABI we are using.
1713 echo '#line 1714 "configure"' > conftest.$ac_ext
1714 if { (eval echo configure:1715: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1715 case "`/usr/bin/file conftest.o`" in
1716 *32-bit*)
1717 LD="${LD-ld} -32"
1718 ;;
1719 *N32*)
1720 LD="${LD-ld} -n32"
1721 ;;
1722 *64-bit*)
1723 LD="${LD-ld} -64"
1724 ;;
1725 esac
1726 fi
1727 rm -rf conftest*
1728 ;;
1729
1730*-*-sco3.2v5*)
1731 # On SCO OpenServer 5, we need -belf to get full-featured binaries.
1732 SAVE_CFLAGS="$CFLAGS"
1733 CFLAGS="$CFLAGS -belf"
1734 echo $ac_n "checking whether the C compiler needs -belf""... $ac_c" 1>&6
1735echo "configure:1736: checking whether the C compiler needs -belf" >&5
1736if eval "test \"`echo '$''{'lt_cv_cc_needs_belf'+set}'`\" = set"; then
1737 echo $ac_n "(cached) $ac_c" 1>&6
1738else
1739 cat > conftest.$ac_ext <<EOF
1740#line 1741 "configure"
1741#include "confdefs.h"
1742
1743int main() {
1744
1745; return 0; }
1746EOF
1747if { (eval echo configure:1748: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1748 rm -rf conftest*
1749 lt_cv_cc_needs_belf=yes
1750else
1751 echo "configure: failed program was:" >&5
1752 cat conftest.$ac_ext >&5
1753 rm -rf conftest*
1754 lt_cv_cc_needs_belf=no
1755fi
1756rm -f conftest*
1757fi
1758
1759echo "$ac_t""$lt_cv_cc_needs_belf" 1>&6
1760 if test x"$lt_cv_cc_needs_belf" != x"yes"; then
1761 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
1762 CFLAGS="$SAVE_CFLAGS"
1763 fi
1764 ;;
1765
1766*-*-cygwin*)
1767 # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
1768set dummy ${ac_tool_prefix}dlltool; ac_word=$2
1769echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1770echo "configure:1771: checking for $ac_word" >&5
1771if eval "test \"`echo '$''{'ac_cv_prog_DLLTOOL'+set}'`\" = set"; then
1772 echo $ac_n "(cached) $ac_c" 1>&6
1773else
1774 if test -n "$DLLTOOL"; then
1775 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
1776else
1777 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1778 ac_dummy="$PATH"
1779 for ac_dir in $ac_dummy; do
1780 test -z "$ac_dir" && ac_dir=.
1781 if test -f $ac_dir/$ac_word; then
1782 ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
1783 break
1784 fi
1785 done
1786 IFS="$ac_save_ifs"
1787fi
1788fi
1789DLLTOOL="$ac_cv_prog_DLLTOOL"
1790if test -n "$DLLTOOL"; then
1791 echo "$ac_t""$DLLTOOL" 1>&6
1792else
1793 echo "$ac_t""no" 1>&6
1794fi
1795
1796
1797if test -z "$ac_cv_prog_DLLTOOL"; then
1798if test -n "$ac_tool_prefix"; then
1799 # Extract the first word of "dlltool", so it can be a program name with args.
1800set dummy dlltool; ac_word=$2
1801echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1802echo "configure:1803: checking for $ac_word" >&5
1803if eval "test \"`echo '$''{'ac_cv_prog_DLLTOOL'+set}'`\" = set"; then
1804 echo $ac_n "(cached) $ac_c" 1>&6
1805else
1806 if test -n "$DLLTOOL"; then
1807 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
1808else
1809 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1810 ac_dummy="$PATH"
1811 for ac_dir in $ac_dummy; do
1812 test -z "$ac_dir" && ac_dir=.
1813 if test -f $ac_dir/$ac_word; then
1814 ac_cv_prog_DLLTOOL="dlltool"
1815 break
1816 fi
1817 done
1818 IFS="$ac_save_ifs"
1819 test -z "$ac_cv_prog_DLLTOOL" && ac_cv_prog_DLLTOOL="false"
1820fi
1821fi
1822DLLTOOL="$ac_cv_prog_DLLTOOL"
1823if test -n "$DLLTOOL"; then
1824 echo "$ac_t""$DLLTOOL" 1>&6
1825else
1826 echo "$ac_t""no" 1>&6
1827fi
1828
1829else
1830 DLLTOOL="false"
1831fi
1832fi
1833
1834# Extract the first word of "${ac_tool_prefix}as", so it can be a program name with args.
1835set dummy ${ac_tool_prefix}as; ac_word=$2
1836echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1837echo "configure:1838: checking for $ac_word" >&5
1838if eval "test \"`echo '$''{'ac_cv_prog_AS'+set}'`\" = set"; then
1839 echo $ac_n "(cached) $ac_c" 1>&6
1840else
1841 if test -n "$AS"; then
1842 ac_cv_prog_AS="$AS" # Let the user override the test.
1843else
1844 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1845 ac_dummy="$PATH"
1846 for ac_dir in $ac_dummy; do
1847 test -z "$ac_dir" && ac_dir=.
1848 if test -f $ac_dir/$ac_word; then
1849 ac_cv_prog_AS="${ac_tool_prefix}as"
1850 break
1851 fi
1852 done
1853 IFS="$ac_save_ifs"
1854fi
1855fi
1856AS="$ac_cv_prog_AS"
1857if test -n "$AS"; then
1858 echo "$ac_t""$AS" 1>&6
1859else
1860 echo "$ac_t""no" 1>&6
1861fi
1862
1863
1864if test -z "$ac_cv_prog_AS"; then
1865if test -n "$ac_tool_prefix"; then
1866 # Extract the first word of "as", so it can be a program name with args.
1867set dummy as; ac_word=$2
1868echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1869echo "configure:1870: checking for $ac_word" >&5
1870if eval "test \"`echo '$''{'ac_cv_prog_AS'+set}'`\" = set"; then
1871 echo $ac_n "(cached) $ac_c" 1>&6
1872else
1873 if test -n "$AS"; then
1874 ac_cv_prog_AS="$AS" # Let the user override the test.
1875else
1876 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1877 ac_dummy="$PATH"
1878 for ac_dir in $ac_dummy; do
1879 test -z "$ac_dir" && ac_dir=.
1880 if test -f $ac_dir/$ac_word; then
1881 ac_cv_prog_AS="as"
1882 break
1883 fi
1884 done
1885 IFS="$ac_save_ifs"
1886 test -z "$ac_cv_prog_AS" && ac_cv_prog_AS="false"
1887fi
1888fi
1889AS="$ac_cv_prog_AS"
1890if test -n "$AS"; then
1891 echo "$ac_t""$AS" 1>&6
1892else
1893 echo "$ac_t""no" 1>&6
1894fi
1895
1896else
1897 AS="false"
1898fi
1899fi
1900
1901
1902 ;;
1903
1904esac
1905
1906# enable the --disable-libtool-lock switch
1907
1908# Check whether --enable-libtool-lock or --disable-libtool-lock was given.
1909if test "${enable_libtool_lock+set}" = set; then
1910 enableval="$enable_libtool_lock"
1911 need_locks=$enableval
1912else
1913 need_locks=yes
1914fi
1915
1916
1917if test x"$need_locks" = xno; then
1918 libtool_flags="$libtool_flags --disable-lock"
1919fi
1920
1921
1922# Save cache, so that ltconfig can load it
1923cat > confcache <<\EOF
1924# This file is a shell script that caches the results of configure
1925# tests run on this system so they can be shared between configure
1926# scripts and configure runs. It is not useful on other systems.
1927# If it contains results you don't want to keep, you may remove or edit it.
1928#
1929# By default, configure uses ./config.cache as the cache file,
1930# creating it if it does not exist already. You can give configure
1931# the --cache-file=FILE option to use a different cache file; that is
1932# what configure does when it calls configure scripts in
1933# subdirectories, so they share the cache.
1934# Giving --cache-file=/dev/null disables caching, for debugging configure.
1935# config.status only pays attention to the cache file if you give it the
1936# --recheck option to rerun configure.
1937#
1938EOF
1939# The following way of writing the cache mishandles newlines in values,
1940# but we know of no workaround that is simple, portable, and efficient.
1941# So, don't put newlines in cache variables' values.
1942# Ultrix sh set writes to stderr and can't be redirected directly,
1943# and sets the high bit in the cache file unless we assign to the vars.
1944(set) 2>&1 |
1945 case `(ac_space=' '; set | grep ac_space) 2>&1` in
1946 *ac_space=\ *)
1947 # `set' does not quote correctly, so add quotes (double-quote substitution
1948 # turns \\\\ into \\, and sed turns \\ into \).
1949 sed -n \
1950 -e "s/'/'\\\\''/g" \
1951 -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
1952 ;;
1953 *)
1954 # `set' quotes correctly as required by POSIX, so do not add quotes.
1955 sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
1956 ;;
1957 esac >> confcache
1958if cmp -s $cache_file confcache; then
1959 :
1960else
1961 if test -w $cache_file; then
1962 echo "updating cache $cache_file"
1963 cat confcache > $cache_file
1964 else
1965 echo "not updating unwritable cache $cache_file"
1966 fi
1967fi
1968rm -f confcache
1969
1970
1971# Actually configure libtool. ac_aux_dir is where install-sh is found.
1972CC="$CC" CFLAGS="$CFLAGS" CPPFLAGS="$CPPFLAGS" \
1973LD="$LD" NM="$NM" RANLIB="$RANLIB" LN_S="$LN_S" \
1974DLLTOOL="$DLLTOOL" AS="$AS" \
1975${CONFIG_SHELL-/bin/sh} $ac_aux_dir/ltconfig --no-reexec \
1976$libtool_flags --no-verify $ac_aux_dir/ltmain.sh $host \
1977|| { echo "configure: error: libtool configure failed" 1>&2; exit 1; }
1978
1979# Reload cache, that may have been modified by ltconfig
1980if test -r "$cache_file"; then
1981 echo "loading cache $cache_file"
1982 . $cache_file
1983else
1984 echo "creating cache $cache_file"
1985 > $cache_file
1986fi
1987
1988
1989# This can be used to rebuild libtool when needed
1990LIBTOOL_DEPS="$ac_aux_dir/ltconfig $ac_aux_dir/ltmain.sh"
1991
1992# Always use our own libtool.
1993LIBTOOL='$(SHELL) $(top_builddir)/libtool'
1994
1995# Redirect the config.log output again, so that the ltconfig log is not
1996# clobbered by the next message.
1997exec 5>>./config.log
1998
1999
2000# Check whether --enable-targets or --disable-targets was given.
2001if test "${enable_targets+set}" = set; then
2002 enableval="$enable_targets"
2003 case "${enableval}" in
2004 yes | "") { echo "configure: error: enable-targets option must specify target names or 'all'" 1>&2; exit 1; }
2005 ;;
2006 no) enable_targets= ;;
2007 *) enable_targets=$enableval ;;
2008esac
2009fi
2010# Check whether --enable-commonbfdlib or --disable-commonbfdlib was given.
2011if test "${enable_commonbfdlib+set}" = set; then
2012 enableval="$enable_commonbfdlib"
2013 case "${enableval}" in
2014 yes) commonbfdlib=true ;;
2015 no) commonbfdlib=false ;;
2016 *) { echo "configure: error: bad value ${enableval} for opcodes commonbfdlib option" 1>&2; exit 1; } ;;
2017esac
2018fi
2019
2020
2021
2022
2023
2024if test -z "$target" ; then
2025 { echo "configure: error: Unrecognized target system type; please check config.sub." 1>&2; exit 1; }
2026fi
2027if test "$program_transform_name" = s,x,x,; then
2028 program_transform_name=
2029else
2030 # Double any \ or $. echo might interpret backslashes.
2031 cat <<\EOF_SED > conftestsed
2032s,\\,\\\\,g; s,\$,$$,g
2033EOF_SED
2034 program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
2035 rm -f conftestsed
2036fi
2037test "$program_prefix" != NONE &&
2038 program_transform_name="s,^,${program_prefix},; $program_transform_name"
2039# Use a double $ so make ignores it.
2040test "$program_suffix" != NONE &&
2041 program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
2042
2043# sed with no file args requires a program.
2044test "$program_transform_name" = "" && program_transform_name="s,x,x,"
2045
2046
2047echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
2048echo "configure:2049: checking whether to enable maintainer-specific portions of Makefiles" >&5
2049 # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
2050if test "${enable_maintainer_mode+set}" = set; then
2051 enableval="$enable_maintainer_mode"
2052 USE_MAINTAINER_MODE=$enableval
2053else
2054 USE_MAINTAINER_MODE=no
2055fi
2056
2057 echo "$ac_t""$USE_MAINTAINER_MODE" 1>&6
2058
2059
2060if test $USE_MAINTAINER_MODE = yes; then
2061 MAINTAINER_MODE_TRUE=
2062 MAINTAINER_MODE_FALSE='#'
2063else
2064 MAINTAINER_MODE_TRUE='#'
2065 MAINTAINER_MODE_FALSE=
2066fi
2067 MAINT=$MAINTAINER_MODE_TRUE
2068
2069
2070echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
2071echo "configure:2072: checking for Cygwin environment" >&5
2072if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
2073 echo $ac_n "(cached) $ac_c" 1>&6
2074else
2075 cat > conftest.$ac_ext <<EOF
2076#line 2077 "configure"
2077#include "confdefs.h"
2078
2079int main() {
2080
2081#ifndef __CYGWIN__
2082#define __CYGWIN__ __CYGWIN32__
2083#endif
2084return __CYGWIN__;
2085; return 0; }
2086EOF
2087if { (eval echo configure:2088: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2088 rm -rf conftest*
2089 ac_cv_cygwin=yes
2090else
2091 echo "configure: failed program was:" >&5
2092 cat conftest.$ac_ext >&5
2093 rm -rf conftest*
2094 ac_cv_cygwin=no
2095fi
2096rm -f conftest*
2097rm -f conftest*
2098fi
2099
2100echo "$ac_t""$ac_cv_cygwin" 1>&6
2101CYGWIN=
2102test "$ac_cv_cygwin" = yes && CYGWIN=yes
2103echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
2104echo "configure:2105: checking for mingw32 environment" >&5
2105if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
2106 echo $ac_n "(cached) $ac_c" 1>&6
2107else
2108 cat > conftest.$ac_ext <<EOF
2109#line 2110 "configure"
2110#include "confdefs.h"
2111
2112int main() {
2113return __MINGW32__;
2114; return 0; }
2115EOF
2116if { (eval echo configure:2117: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2117 rm -rf conftest*
2118 ac_cv_mingw32=yes
2119else
2120 echo "configure: failed program was:" >&5
2121 cat conftest.$ac_ext >&5
2122 rm -rf conftest*
2123 ac_cv_mingw32=no
2124fi
2125rm -f conftest*
2126rm -f conftest*
2127fi
2128
2129echo "$ac_t""$ac_cv_mingw32" 1>&6
2130MINGW32=
2131test "$ac_cv_mingw32" = yes && MINGW32=yes
2132
2133
2134echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
2135echo "configure:2136: checking for executable suffix" >&5
2136if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
2137 echo $ac_n "(cached) $ac_c" 1>&6
2138else
2139 if test "$CYGWIN" = yes || test "$MINGW32" = yes; then
2140 ac_cv_exeext=.exe
2141else
2142 rm -f conftest*
2143 echo 'int main () { return 0; }' > conftest.$ac_ext
2144 ac_cv_exeext=
2145 if { (eval echo configure:2146: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
2146 for file in conftest.*; do
2147 case $file in
2148 *.c | *.o | *.obj | *.ilk | *.pdb) ;;
2149 *) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
2150 esac
2151 done
2152 else
2153 { echo "configure: error: installation or configuration problem: compiler cannot create executables." 1>&2; exit 1; }
2154 fi
2155 rm -f conftest*
2156 test x"${ac_cv_exeext}" = x && ac_cv_exeext=no
2157fi
2158fi
2159
2160EXEEXT=""
2161test x"${ac_cv_exeext}" != xno && EXEEXT=${ac_cv_exeext}
2162echo "$ac_t""${ac_cv_exeext}" 1>&6
2163ac_exeext=$EXEEXT
2164
2165
2166# host-specific stuff:
2167
2168# Extract the first word of "gcc", so it can be a program name with args.
2169set dummy gcc; ac_word=$2
2170echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2171echo "configure:2172: checking for $ac_word" >&5
2172if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
2173 echo $ac_n "(cached) $ac_c" 1>&6
2174else
2175 if test -n "$CC"; then
2176 ac_cv_prog_CC="$CC" # Let the user override the test.
2177else
2178 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2179 ac_dummy="$PATH"
2180 for ac_dir in $ac_dummy; do
2181 test -z "$ac_dir" && ac_dir=.
2182 if test -f $ac_dir/$ac_word; then
2183 ac_cv_prog_CC="gcc"
2184 break
2185 fi
2186 done
2187 IFS="$ac_save_ifs"
2188fi
2189fi
2190CC="$ac_cv_prog_CC"
2191if test -n "$CC"; then
2192 echo "$ac_t""$CC" 1>&6
2193else
2194 echo "$ac_t""no" 1>&6
2195fi
2196
2197if test -z "$CC"; then
2198 # Extract the first word of "cc", so it can be a program name with args.
2199set dummy cc; ac_word=$2
2200echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2201echo "configure:2202: checking for $ac_word" >&5
2202if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
2203 echo $ac_n "(cached) $ac_c" 1>&6
2204else
2205 if test -n "$CC"; then
2206 ac_cv_prog_CC="$CC" # Let the user override the test.
2207else
2208 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2209 ac_prog_rejected=no
2210 ac_dummy="$PATH"
2211 for ac_dir in $ac_dummy; do
2212 test -z "$ac_dir" && ac_dir=.
2213 if test -f $ac_dir/$ac_word; then
2214 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
2215 ac_prog_rejected=yes
2216 continue
2217 fi
2218 ac_cv_prog_CC="cc"
2219 break
2220 fi
2221 done
2222 IFS="$ac_save_ifs"
2223if test $ac_prog_rejected = yes; then
2224 # We found a bogon in the path, so make sure we never use it.
2225 set dummy $ac_cv_prog_CC
2226 shift
2227 if test $# -gt 0; then
2228 # We chose a different compiler from the bogus one.
2229 # However, it has the same basename, so the bogon will be chosen
2230 # first if we set CC to just the basename; use the full file name.
2231 shift
2232 set dummy "$ac_dir/$ac_word" "$@"
2233 shift
2234 ac_cv_prog_CC="$@"
2235 fi
2236fi
2237fi
2238fi
2239CC="$ac_cv_prog_CC"
2240if test -n "$CC"; then
2241 echo "$ac_t""$CC" 1>&6
2242else
2243 echo "$ac_t""no" 1>&6
2244fi
2245
2246 if test -z "$CC"; then
2247 case "`uname -s`" in
2248 *win32* | *WIN32*)
2249 # Extract the first word of "cl", so it can be a program name with args.
2250set dummy cl; ac_word=$2
2251echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2252echo "configure:2253: checking for $ac_word" >&5
2253if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
2254 echo $ac_n "(cached) $ac_c" 1>&6
2255else
2256 if test -n "$CC"; then
2257 ac_cv_prog_CC="$CC" # Let the user override the test.
2258else
2259 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2260 ac_dummy="$PATH"
2261 for ac_dir in $ac_dummy; do
2262 test -z "$ac_dir" && ac_dir=.
2263 if test -f $ac_dir/$ac_word; then
2264 ac_cv_prog_CC="cl"
2265 break
2266 fi
2267 done
2268 IFS="$ac_save_ifs"
2269fi
2270fi
2271CC="$ac_cv_prog_CC"
2272if test -n "$CC"; then
2273 echo "$ac_t""$CC" 1>&6
2274else
2275 echo "$ac_t""no" 1>&6
2276fi
2277 ;;
2278 esac
2279 fi
2280 test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
2281fi
2282
2283echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
2284echo "configure:2285: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
2285
2286ac_ext=c
2287# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
2288ac_cpp='$CPP $CPPFLAGS'
2289ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
2290ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
2291cross_compiling=$ac_cv_prog_cc_cross
2292
2293cat > conftest.$ac_ext << EOF
2294
2295#line 2296 "configure"
2296#include "confdefs.h"
2297
2298main(){return(0);}
2299EOF
2300if { (eval echo configure:2301: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2301 ac_cv_prog_cc_works=yes
2302 # If we can't run a trivial program, we are probably using a cross compiler.
2303 if (./conftest; exit) 2>/dev/null; then
2304 ac_cv_prog_cc_cross=no
2305 else
2306 ac_cv_prog_cc_cross=yes
2307 fi
2308else
2309 echo "configure: failed program was:" >&5
2310 cat conftest.$ac_ext >&5
2311 ac_cv_prog_cc_works=no
2312fi
2313rm -fr conftest*
2314ac_ext=c
2315# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
2316ac_cpp='$CPP $CPPFLAGS'
2317ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
2318ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
2319cross_compiling=$ac_cv_prog_cc_cross
2320
2321echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
2322if test $ac_cv_prog_cc_works = no; then
2323 { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
2324fi
2325echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
2326echo "configure:2327: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
2327echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
2328cross_compiling=$ac_cv_prog_cc_cross
2329
2330echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
2331echo "configure:2332: checking whether we are using GNU C" >&5
2332if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
2333 echo $ac_n "(cached) $ac_c" 1>&6
2334else
2335 cat > conftest.c <<EOF
2336#ifdef __GNUC__
2337 yes;
2338#endif
2339EOF
2340if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:2341: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
2341 ac_cv_prog_gcc=yes
2342else
2343 ac_cv_prog_gcc=no
2344fi
2345fi
2346
2347echo "$ac_t""$ac_cv_prog_gcc" 1>&6
2348
2349if test $ac_cv_prog_gcc = yes; then
2350 GCC=yes
2351else
2352 GCC=
2353fi
2354
2355ac_test_CFLAGS="${CFLAGS+set}"
2356ac_save_CFLAGS="$CFLAGS"
2357CFLAGS=
2358echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
2359echo "configure:2360: checking whether ${CC-cc} accepts -g" >&5
2360if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
2361 echo $ac_n "(cached) $ac_c" 1>&6
2362else
2363 echo 'void f(){}' > conftest.c
2364if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
2365 ac_cv_prog_cc_g=yes
2366else
2367 ac_cv_prog_cc_g=no
2368fi
2369rm -f conftest*
2370
2371fi
2372
2373echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
2374if test "$ac_test_CFLAGS" = set; then
2375 CFLAGS="$ac_save_CFLAGS"
2376elif test $ac_cv_prog_cc_g = yes; then
2377 if test "$GCC" = yes; then
2378 CFLAGS="-g -O2"
2379 else
2380 CFLAGS="-g"
2381 fi
2382else
2383 if test "$GCC" = yes; then
2384 CFLAGS="-O2"
2385 else
2386 CFLAGS=
2387 fi
2388fi
2389
2390
2391ALL_LINGUAS=
2392echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
2393echo "configure:2394: checking how to run the C preprocessor" >&5
2394# On Suns, sometimes $CPP names a directory.
2395if test -n "$CPP" && test -d "$CPP"; then
2396 CPP=
2397fi
2398if test -z "$CPP"; then
2399if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
2400 echo $ac_n "(cached) $ac_c" 1>&6
2401else
2402 # This must be in double quotes, not single quotes, because CPP may get
2403 # substituted into the Makefile and "${CC-cc}" will confuse make.
2404 CPP="${CC-cc} -E"
2405 # On the NeXT, cc -E runs the code through the compiler's parser,
2406 # not just through cpp.
2407 cat > conftest.$ac_ext <<EOF
2408#line 2409 "configure"
2409#include "confdefs.h"
2410#include <assert.h>
2411Syntax Error
2412EOF
2413ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2414{ (eval echo configure:2415: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2415ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2416if test -z "$ac_err"; then
2417 :
2418else
2419 echo "$ac_err" >&5
2420 echo "configure: failed program was:" >&5
2421 cat conftest.$ac_ext >&5
2422 rm -rf conftest*
2423 CPP="${CC-cc} -E -traditional-cpp"
2424 cat > conftest.$ac_ext <<EOF
2425#line 2426 "configure"
2426#include "confdefs.h"
2427#include <assert.h>
2428Syntax Error
2429EOF
2430ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2431{ (eval echo configure:2432: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2432ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2433if test -z "$ac_err"; then
2434 :
2435else
2436 echo "$ac_err" >&5
2437 echo "configure: failed program was:" >&5
2438 cat conftest.$ac_ext >&5
2439 rm -rf conftest*
2440 CPP="${CC-cc} -nologo -E"
2441 cat > conftest.$ac_ext <<EOF
2442#line 2443 "configure"
2443#include "confdefs.h"
2444#include <assert.h>
2445Syntax Error
2446EOF
2447ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2448{ (eval echo configure:2449: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2449ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2450if test -z "$ac_err"; then
2451 :
2452else
2453 echo "$ac_err" >&5
2454 echo "configure: failed program was:" >&5
2455 cat conftest.$ac_ext >&5
2456 rm -rf conftest*
2457 CPP=/lib/cpp
2458fi
2459rm -f conftest*
2460fi
2461rm -f conftest*
2462fi
2463rm -f conftest*
2464 ac_cv_prog_CPP="$CPP"
2465fi
2466 CPP="$ac_cv_prog_CPP"
2467else
2468 ac_cv_prog_CPP="$CPP"
2469fi
2470echo "$ac_t""$CPP" 1>&6
2471
2472echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
2473echo "configure:2474: checking for ANSI C header files" >&5
2474if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
2475 echo $ac_n "(cached) $ac_c" 1>&6
2476else
2477 cat > conftest.$ac_ext <<EOF
2478#line 2479 "configure"
2479#include "confdefs.h"
2480#include <stdlib.h>
2481#include <stdarg.h>
2482#include <string.h>
2483#include <float.h>
2484EOF
2485ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2486{ (eval echo configure:2487: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2487ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2488if test -z "$ac_err"; then
2489 rm -rf conftest*
2490 ac_cv_header_stdc=yes
2491else
2492 echo "$ac_err" >&5
2493 echo "configure: failed program was:" >&5
2494 cat conftest.$ac_ext >&5
2495 rm -rf conftest*
2496 ac_cv_header_stdc=no
2497fi
2498rm -f conftest*
2499
2500if test $ac_cv_header_stdc = yes; then
2501 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
2502cat > conftest.$ac_ext <<EOF
2503#line 2504 "configure"
2504#include "confdefs.h"
2505#include <string.h>
2506EOF
2507if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2508 egrep "memchr" >/dev/null 2>&1; then
2509 :
2510else
2511 rm -rf conftest*
2512 ac_cv_header_stdc=no
2513fi
2514rm -f conftest*
2515
2516fi
2517
2518if test $ac_cv_header_stdc = yes; then
2519 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
2520cat > conftest.$ac_ext <<EOF
2521#line 2522 "configure"
2522#include "confdefs.h"
2523#include <stdlib.h>
2524EOF
2525if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2526 egrep "free" >/dev/null 2>&1; then
2527 :
2528else
2529 rm -rf conftest*
2530 ac_cv_header_stdc=no
2531fi
2532rm -f conftest*
2533
2534fi
2535
2536if test $ac_cv_header_stdc = yes; then
2537 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
2538if test "$cross_compiling" = yes; then
2539 :
2540else
2541 cat > conftest.$ac_ext <<EOF
2542#line 2543 "configure"
2543#include "confdefs.h"
2544#include <ctype.h>
2545#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
2546#define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
2547#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
2548int main () { int i; for (i = 0; i < 256; i++)
2549if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
2550exit (0); }
2551
2552EOF
2553if { (eval echo configure:2554: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2554then
2555 :
2556else
2557 echo "configure: failed program was:" >&5
2558 cat conftest.$ac_ext >&5
2559 rm -fr conftest*
2560 ac_cv_header_stdc=no
2561fi
2562rm -fr conftest*
2563fi
2564
2565fi
2566fi
2567
2568echo "$ac_t""$ac_cv_header_stdc" 1>&6
2569if test $ac_cv_header_stdc = yes; then
2570 cat >> confdefs.h <<\EOF
2571#define STDC_HEADERS 1
2572EOF
2573
2574fi
2575
2576echo $ac_n "checking for working const""... $ac_c" 1>&6
2577echo "configure:2578: checking for working const" >&5
2578if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
2579 echo $ac_n "(cached) $ac_c" 1>&6
2580else
2581 cat > conftest.$ac_ext <<EOF
2582#line 2583 "configure"
2583#include "confdefs.h"
2584
2585int main() {
2586
2587/* Ultrix mips cc rejects this. */
2588typedef int charset[2]; const charset x;
2589/* SunOS 4.1.1 cc rejects this. */
2590char const *const *ccp;
2591char **p;
2592/* NEC SVR4.0.2 mips cc rejects this. */
2593struct point {int x, y;};
2594static struct point const zero = {0,0};
2595/* AIX XL C 1.02.0.0 rejects this.
2596 It does not let you subtract one const X* pointer from another in an arm
2597 of an if-expression whose if-part is not a constant expression */
2598const char *g = "string";
2599ccp = &g + (g ? g-g : 0);
2600/* HPUX 7.0 cc rejects these. */
2601++ccp;
2602p = (char**) ccp;
2603ccp = (char const *const *) p;
2604{ /* SCO 3.2v4 cc rejects this. */
2605 char *t;
2606 char const *s = 0 ? (char *) 0 : (char const *) 0;
2607
2608 *t++ = 0;
2609}
2610{ /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
2611 int x[] = {25, 17};
2612 const int *foo = &x[0];
2613 ++foo;
2614}
2615{ /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
2616 typedef const int *iptr;
2617 iptr p = 0;
2618 ++p;
2619}
2620{ /* AIX XL C 1.02.0.0 rejects this saying
2621 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
2622 struct s { int j; const int *ap[3]; };
2623 struct s *b; b->j = 5;
2624}
2625{ /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
2626 const int foo = 10;
2627}
2628
2629; return 0; }
2630EOF
2631if { (eval echo configure:2632: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2632 rm -rf conftest*
2633 ac_cv_c_const=yes
2634else
2635 echo "configure: failed program was:" >&5
2636 cat conftest.$ac_ext >&5
2637 rm -rf conftest*
2638 ac_cv_c_const=no
2639fi
2640rm -f conftest*
2641fi
2642
2643echo "$ac_t""$ac_cv_c_const" 1>&6
2644if test $ac_cv_c_const = no; then
2645 cat >> confdefs.h <<\EOF
2646#define const
2647EOF
2648
2649fi
2650
2651echo $ac_n "checking for inline""... $ac_c" 1>&6
2652echo "configure:2653: checking for inline" >&5
2653if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
2654 echo $ac_n "(cached) $ac_c" 1>&6
2655else
2656 ac_cv_c_inline=no
2657for ac_kw in inline __inline__ __inline; do
2658 cat > conftest.$ac_ext <<EOF
2659#line 2660 "configure"
2660#include "confdefs.h"
2661
2662int main() {
2663} $ac_kw foo() {
2664; return 0; }
2665EOF
2666if { (eval echo configure:2667: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2667 rm -rf conftest*
2668 ac_cv_c_inline=$ac_kw; break
2669else
2670 echo "configure: failed program was:" >&5
2671 cat conftest.$ac_ext >&5
2672fi
2673rm -f conftest*
2674done
2675
2676fi
2677
2678echo "$ac_t""$ac_cv_c_inline" 1>&6
2679case "$ac_cv_c_inline" in
2680 inline | yes) ;;
2681 no) cat >> confdefs.h <<\EOF
2682#define inline
2683EOF
2684 ;;
2685 *) cat >> confdefs.h <<EOF
2686#define inline $ac_cv_c_inline
2687EOF
2688 ;;
2689esac
2690
2691echo $ac_n "checking for off_t""... $ac_c" 1>&6
2692echo "configure:2693: checking for off_t" >&5
2693if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then
2694 echo $ac_n "(cached) $ac_c" 1>&6
2695else
2696 cat > conftest.$ac_ext <<EOF
2697#line 2698 "configure"
2698#include "confdefs.h"
2699#include <sys/types.h>
2700#if STDC_HEADERS
2701#include <stdlib.h>
2702#include <stddef.h>
2703#endif
2704EOF
2705if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2706 egrep "(^|[^a-zA-Z_0-9])off_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
2707 rm -rf conftest*
2708 ac_cv_type_off_t=yes
2709else
2710 rm -rf conftest*
2711 ac_cv_type_off_t=no
2712fi
2713rm -f conftest*
2714
2715fi
2716echo "$ac_t""$ac_cv_type_off_t" 1>&6
2717if test $ac_cv_type_off_t = no; then
2718 cat >> confdefs.h <<\EOF
2719#define off_t long
2720EOF
2721
2722fi
2723
2724echo $ac_n "checking for size_t""... $ac_c" 1>&6
2725echo "configure:2726: checking for size_t" >&5
2726if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
2727 echo $ac_n "(cached) $ac_c" 1>&6
2728else
2729 cat > conftest.$ac_ext <<EOF
2730#line 2731 "configure"
2731#include "confdefs.h"
2732#include <sys/types.h>
2733#if STDC_HEADERS
2734#include <stdlib.h>
2735#include <stddef.h>
2736#endif
2737EOF
2738if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2739 egrep "(^|[^a-zA-Z_0-9])size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
2740 rm -rf conftest*
2741 ac_cv_type_size_t=yes
2742else
2743 rm -rf conftest*
2744 ac_cv_type_size_t=no
2745fi
2746rm -f conftest*
2747
2748fi
2749echo "$ac_t""$ac_cv_type_size_t" 1>&6
2750if test $ac_cv_type_size_t = no; then
2751 cat >> confdefs.h <<\EOF
2752#define size_t unsigned
2753EOF
2754
2755fi
2756
2757# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
2758# for constant arguments. Useless!
2759echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
2760echo "configure:2761: checking for working alloca.h" >&5
2761if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
2762 echo $ac_n "(cached) $ac_c" 1>&6
2763else
2764 cat > conftest.$ac_ext <<EOF
2765#line 2766 "configure"
2766#include "confdefs.h"
2767#include <alloca.h>
2768int main() {
2769char *p = alloca(2 * sizeof(int));
2770; return 0; }
2771EOF
2772if { (eval echo configure:2773: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2773 rm -rf conftest*
2774 ac_cv_header_alloca_h=yes
2775else
2776 echo "configure: failed program was:" >&5
2777 cat conftest.$ac_ext >&5
2778 rm -rf conftest*
2779 ac_cv_header_alloca_h=no
2780fi
2781rm -f conftest*
2782fi
2783
2784echo "$ac_t""$ac_cv_header_alloca_h" 1>&6
2785if test $ac_cv_header_alloca_h = yes; then
2786 cat >> confdefs.h <<\EOF
2787#define HAVE_ALLOCA_H 1
2788EOF
2789
2790fi
2791
2792echo $ac_n "checking for alloca""... $ac_c" 1>&6
2793echo "configure:2794: checking for alloca" >&5
2794if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
2795 echo $ac_n "(cached) $ac_c" 1>&6
2796else
2797 cat > conftest.$ac_ext <<EOF
2798#line 2799 "configure"
2799#include "confdefs.h"
2800
2801#ifdef __GNUC__
2802# define alloca __builtin_alloca
2803#else
2804# ifdef _MSC_VER
2805# include <malloc.h>
2806# define alloca _alloca
2807# else
2808# if HAVE_ALLOCA_H
2809# include <alloca.h>
2810# else
2811# ifdef _AIX
2812 #pragma alloca
2813# else
2814# ifndef alloca /* predefined by HP cc +Olibcalls */
2815char *alloca ();
2816# endif
2817# endif
2818# endif
2819# endif
2820#endif
2821
2822int main() {
2823char *p = (char *) alloca(1);
2824; return 0; }
2825EOF
2826if { (eval echo configure:2827: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2827 rm -rf conftest*
2828 ac_cv_func_alloca_works=yes
2829else
2830 echo "configure: failed program was:" >&5
2831 cat conftest.$ac_ext >&5
2832 rm -rf conftest*
2833 ac_cv_func_alloca_works=no
2834fi
2835rm -f conftest*
2836fi
2837
2838echo "$ac_t""$ac_cv_func_alloca_works" 1>&6
2839if test $ac_cv_func_alloca_works = yes; then
2840 cat >> confdefs.h <<\EOF
2841#define HAVE_ALLOCA 1
2842EOF
2843
2844fi
2845
2846if test $ac_cv_func_alloca_works = no; then
2847 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
2848 # that cause trouble. Some versions do not even contain alloca or
2849 # contain a buggy version. If you still want to use their alloca,
2850 # use ar to extract alloca.o from them instead of compiling alloca.c.
2851 ALLOCA=alloca.${ac_objext}
2852 cat >> confdefs.h <<\EOF
2853#define C_ALLOCA 1
2854EOF
2855
2856
2857echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
2858echo "configure:2859: checking whether alloca needs Cray hooks" >&5
2859if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
2860 echo $ac_n "(cached) $ac_c" 1>&6
2861else
2862 cat > conftest.$ac_ext <<EOF
2863#line 2864 "configure"
2864#include "confdefs.h"
2865#if defined(CRAY) && ! defined(CRAY2)
2866webecray
2867#else
2868wenotbecray
2869#endif
2870
2871EOF
2872if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2873 egrep "webecray" >/dev/null 2>&1; then
2874 rm -rf conftest*
2875 ac_cv_os_cray=yes
2876else
2877 rm -rf conftest*
2878 ac_cv_os_cray=no
2879fi
2880rm -f conftest*
2881
2882fi
2883
2884echo "$ac_t""$ac_cv_os_cray" 1>&6
2885if test $ac_cv_os_cray = yes; then
2886for ac_func in _getb67 GETB67 getb67; do
2887 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
2888echo "configure:2889: checking for $ac_func" >&5
2889if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2890 echo $ac_n "(cached) $ac_c" 1>&6
2891else
2892 cat > conftest.$ac_ext <<EOF
2893#line 2894 "configure"
2894#include "confdefs.h"
2895/* System header to define __stub macros and hopefully few prototypes,
2896 which can conflict with char $ac_func(); below. */
2897#include <assert.h>
2898/* Override any gcc2 internal prototype to avoid an error. */
2899/* We use char because int might match the return type of a gcc2
2900 builtin and then its argument prototype would still apply. */
2901char $ac_func();
2902
2903int main() {
2904
2905/* The GNU C library defines this for functions which it implements
2906 to always fail with ENOSYS. Some functions are actually named
2907 something starting with __ and the normal name is an alias. */
2908#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2909choke me
2910#else
2911$ac_func();
2912#endif
2913
2914; return 0; }
2915EOF
2916if { (eval echo configure:2917: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2917 rm -rf conftest*
2918 eval "ac_cv_func_$ac_func=yes"
2919else
2920 echo "configure: failed program was:" >&5
2921 cat conftest.$ac_ext >&5
2922 rm -rf conftest*
2923 eval "ac_cv_func_$ac_func=no"
2924fi
2925rm -f conftest*
2926fi
2927
2928if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2929 echo "$ac_t""yes" 1>&6
2930 cat >> confdefs.h <<EOF
2931#define CRAY_STACKSEG_END $ac_func
2932EOF
2933
2934 break
2935else
2936 echo "$ac_t""no" 1>&6
2937fi
2938
2939done
2940fi
2941
2942echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
2943echo "configure:2944: checking stack direction for C alloca" >&5
2944if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
2945 echo $ac_n "(cached) $ac_c" 1>&6
2946else
2947 if test "$cross_compiling" = yes; then
2948 ac_cv_c_stack_direction=0
2949else
2950 cat > conftest.$ac_ext <<EOF
2951#line 2952 "configure"
2952#include "confdefs.h"
2953find_stack_direction ()
2954{
2955 static char *addr = 0;
2956 auto char dummy;
2957 if (addr == 0)
2958 {
2959 addr = &dummy;
2960 return find_stack_direction ();
2961 }
2962 else
2963 return (&dummy > addr) ? 1 : -1;
2964}
2965main ()
2966{
2967 exit (find_stack_direction() < 0);
2968}
2969EOF
2970if { (eval echo configure:2971: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2971then
2972 ac_cv_c_stack_direction=1
2973else
2974 echo "configure: failed program was:" >&5
2975 cat conftest.$ac_ext >&5
2976 rm -fr conftest*
2977 ac_cv_c_stack_direction=-1
2978fi
2979rm -fr conftest*
2980fi
2981
2982fi
2983
2984echo "$ac_t""$ac_cv_c_stack_direction" 1>&6
2985cat >> confdefs.h <<EOF
2986#define STACK_DIRECTION $ac_cv_c_stack_direction
2987EOF
2988
2989fi
2990
2991for ac_hdr in unistd.h
2992do
2993ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2994echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2995echo "configure:2996: checking for $ac_hdr" >&5
2996if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2997 echo $ac_n "(cached) $ac_c" 1>&6
2998else
2999 cat > conftest.$ac_ext <<EOF
3000#line 3001 "configure"
3001#include "confdefs.h"
3002#include <$ac_hdr>
3003EOF
3004ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3005{ (eval echo configure:3006: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3006ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3007if test -z "$ac_err"; then
3008 rm -rf conftest*
3009 eval "ac_cv_header_$ac_safe=yes"
3010else
3011 echo "$ac_err" >&5
3012 echo "configure: failed program was:" >&5
3013 cat conftest.$ac_ext >&5
3014 rm -rf conftest*
3015 eval "ac_cv_header_$ac_safe=no"
3016fi
3017rm -f conftest*
3018fi
3019if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3020 echo "$ac_t""yes" 1>&6
3021 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
3022 cat >> confdefs.h <<EOF
3023#define $ac_tr_hdr 1
3024EOF
3025
3026else
3027 echo "$ac_t""no" 1>&6
3028fi
3029done
3030
3031for ac_func in getpagesize
3032do
3033echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
3034echo "configure:3035: checking for $ac_func" >&5
3035if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3036 echo $ac_n "(cached) $ac_c" 1>&6
3037else
3038 cat > conftest.$ac_ext <<EOF
3039#line 3040 "configure"
3040#include "confdefs.h"
3041/* System header to define __stub macros and hopefully few prototypes,
3042 which can conflict with char $ac_func(); below. */
3043#include <assert.h>
3044/* Override any gcc2 internal prototype to avoid an error. */
3045/* We use char because int might match the return type of a gcc2
3046 builtin and then its argument prototype would still apply. */
3047char $ac_func();
3048
3049int main() {
3050
3051/* The GNU C library defines this for functions which it implements
3052 to always fail with ENOSYS. Some functions are actually named
3053 something starting with __ and the normal name is an alias. */
3054#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3055choke me
3056#else
3057$ac_func();
3058#endif
3059
3060; return 0; }
3061EOF
3062if { (eval echo configure:3063: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3063 rm -rf conftest*
3064 eval "ac_cv_func_$ac_func=yes"
3065else
3066 echo "configure: failed program was:" >&5
3067 cat conftest.$ac_ext >&5
3068 rm -rf conftest*
3069 eval "ac_cv_func_$ac_func=no"
3070fi
3071rm -f conftest*
3072fi
3073
3074if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3075 echo "$ac_t""yes" 1>&6
3076 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3077 cat >> confdefs.h <<EOF
3078#define $ac_tr_func 1
3079EOF
3080
3081else
3082 echo "$ac_t""no" 1>&6
3083fi
3084done
3085
3086echo $ac_n "checking for working mmap""... $ac_c" 1>&6
3087echo "configure:3088: checking for working mmap" >&5
3088if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
3089 echo $ac_n "(cached) $ac_c" 1>&6
3090else
3091 if test "$cross_compiling" = yes; then
3092 ac_cv_func_mmap_fixed_mapped=no
3093else
3094 cat > conftest.$ac_ext <<EOF
3095#line 3096 "configure"
3096#include "confdefs.h"
3097
3098/* Thanks to Mike Haertel and Jim Avera for this test.
3099 Here is a matrix of mmap possibilities:
3100 mmap private not fixed
3101 mmap private fixed at somewhere currently unmapped
3102 mmap private fixed at somewhere already mapped
3103 mmap shared not fixed
3104 mmap shared fixed at somewhere currently unmapped
3105 mmap shared fixed at somewhere already mapped
3106 For private mappings, we should verify that changes cannot be read()
3107 back from the file, nor mmap's back from the file at a different
3108 address. (There have been systems where private was not correctly
3109 implemented like the infamous i386 svr4.0, and systems where the
3110 VM page cache was not coherent with the filesystem buffer cache
3111 like early versions of FreeBSD and possibly contemporary NetBSD.)
3112 For shared mappings, we should conversely verify that changes get
3113 propogated back to all the places they're supposed to be.
3114
3115 Grep wants private fixed already mapped.
3116 The main things grep needs to know about mmap are:
3117 * does it exist and is it safe to write into the mmap'd area
3118 * how to use it (BSD variants) */
3119#include <sys/types.h>
3120#include <fcntl.h>
3121#include <sys/mman.h>
3122
3123/* This mess was copied from the GNU getpagesize.h. */
3124#ifndef HAVE_GETPAGESIZE
3125# ifdef HAVE_UNISTD_H
3126# include <unistd.h>
3127# endif
3128
3129/* Assume that all systems that can run configure have sys/param.h. */
3130# ifndef HAVE_SYS_PARAM_H
3131# define HAVE_SYS_PARAM_H 1
3132# endif
3133
3134# ifdef _SC_PAGESIZE
3135# define getpagesize() sysconf(_SC_PAGESIZE)
3136# else /* no _SC_PAGESIZE */
3137# ifdef HAVE_SYS_PARAM_H
3138# include <sys/param.h>
3139# ifdef EXEC_PAGESIZE
3140# define getpagesize() EXEC_PAGESIZE
3141# else /* no EXEC_PAGESIZE */
3142# ifdef NBPG
3143# define getpagesize() NBPG * CLSIZE
3144# ifndef CLSIZE
3145# define CLSIZE 1
3146# endif /* no CLSIZE */
3147# else /* no NBPG */
3148# ifdef NBPC
3149# define getpagesize() NBPC
3150# else /* no NBPC */
3151# ifdef PAGESIZE
3152# define getpagesize() PAGESIZE
3153# endif /* PAGESIZE */
3154# endif /* no NBPC */
3155# endif /* no NBPG */
3156# endif /* no EXEC_PAGESIZE */
3157# else /* no HAVE_SYS_PARAM_H */
3158# define getpagesize() 8192 /* punt totally */
3159# endif /* no HAVE_SYS_PARAM_H */
3160# endif /* no _SC_PAGESIZE */
3161
3162#endif /* no HAVE_GETPAGESIZE */
3163
3164#ifdef __cplusplus
3165extern "C" { void *malloc(unsigned); }
3166#else
3167char *malloc();
3168#endif
3169
3170int
3171main()
3172{
3173 char *data, *data2, *data3;
3174 int i, pagesize;
3175 int fd;
3176
3177 pagesize = getpagesize();
3178
3179 /*
3180 * First, make a file with some known garbage in it.
3181 */
3182 data = malloc(pagesize);
3183 if (!data)
3184 exit(1);
3185 for (i = 0; i < pagesize; ++i)
3186 *(data + i) = rand();
3187 umask(0);
3188 fd = creat("conftestmmap", 0600);
3189 if (fd < 0)
3190 exit(1);
3191 if (write(fd, data, pagesize) != pagesize)
3192 exit(1);
3193 close(fd);
3194
3195 /*
3196 * Next, try to mmap the file at a fixed address which
3197 * already has something else allocated at it. If we can,
3198 * also make sure that we see the same garbage.
3199 */
3200 fd = open("conftestmmap", O_RDWR);
3201 if (fd < 0)
3202 exit(1);
3203 data2 = malloc(2 * pagesize);
3204 if (!data2)
3205 exit(1);
3206 data2 += (pagesize - ((int) data2 & (pagesize - 1))) & (pagesize - 1);
3207 if (data2 != mmap(data2, pagesize, PROT_READ | PROT_WRITE,
3208 MAP_PRIVATE | MAP_FIXED, fd, 0L))
3209 exit(1);
3210 for (i = 0; i < pagesize; ++i)
3211 if (*(data + i) != *(data2 + i))
3212 exit(1);
3213
3214 /*
3215 * Finally, make sure that changes to the mapped area
3216 * do not percolate back to the file as seen by read().
3217 * (This is a bug on some variants of i386 svr4.0.)
3218 */
3219 for (i = 0; i < pagesize; ++i)
3220 *(data2 + i) = *(data2 + i) + 1;
3221 data3 = malloc(pagesize);
3222 if (!data3)
3223 exit(1);
3224 if (read(fd, data3, pagesize) != pagesize)
3225 exit(1);
3226 for (i = 0; i < pagesize; ++i)
3227 if (*(data + i) != *(data3 + i))
3228 exit(1);
3229 close(fd);
3230 unlink("conftestmmap");
3231 exit(0);
3232}
3233
3234EOF
3235if { (eval echo configure:3236: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
3236then
3237 ac_cv_func_mmap_fixed_mapped=yes
3238else
3239 echo "configure: failed program was:" >&5
3240 cat conftest.$ac_ext >&5
3241 rm -fr conftest*
3242 ac_cv_func_mmap_fixed_mapped=no
3243fi
3244rm -fr conftest*
3245fi
3246
3247fi
3248
3249echo "$ac_t""$ac_cv_func_mmap_fixed_mapped" 1>&6
3250if test $ac_cv_func_mmap_fixed_mapped = yes; then
3251 cat >> confdefs.h <<\EOF
3252#define HAVE_MMAP 1
3253EOF
3254
3255fi
3256
3257
3258 for ac_hdr in argz.h limits.h locale.h nl_types.h malloc.h string.h \
3259unistd.h values.h sys/param.h
3260do
3261ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
3262echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
3263echo "configure:3264: checking for $ac_hdr" >&5
3264if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3265 echo $ac_n "(cached) $ac_c" 1>&6
3266else
3267 cat > conftest.$ac_ext <<EOF
3268#line 3269 "configure"
3269#include "confdefs.h"
3270#include <$ac_hdr>
3271EOF
3272ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3273{ (eval echo configure:3274: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3274ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3275if test -z "$ac_err"; then
3276 rm -rf conftest*
3277 eval "ac_cv_header_$ac_safe=yes"
3278else
3279 echo "$ac_err" >&5
3280 echo "configure: failed program was:" >&5
3281 cat conftest.$ac_ext >&5
3282 rm -rf conftest*
3283 eval "ac_cv_header_$ac_safe=no"
3284fi
3285rm -f conftest*
3286fi
3287if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3288 echo "$ac_t""yes" 1>&6
3289 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
3290 cat >> confdefs.h <<EOF
3291#define $ac_tr_hdr 1
3292EOF
3293
3294else
3295 echo "$ac_t""no" 1>&6
3296fi
3297done
3298
3299 for ac_func in getcwd munmap putenv setenv setlocale strchr strcasecmp \
3300__argz_count __argz_stringify __argz_next
3301do
3302echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
3303echo "configure:3304: checking for $ac_func" >&5
3304if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3305 echo $ac_n "(cached) $ac_c" 1>&6
3306else
3307 cat > conftest.$ac_ext <<EOF
3308#line 3309 "configure"
3309#include "confdefs.h"
3310/* System header to define __stub macros and hopefully few prototypes,
3311 which can conflict with char $ac_func(); below. */
3312#include <assert.h>
3313/* Override any gcc2 internal prototype to avoid an error. */
3314/* We use char because int might match the return type of a gcc2
3315 builtin and then its argument prototype would still apply. */
3316char $ac_func();
3317
3318int main() {
3319
3320/* The GNU C library defines this for functions which it implements
3321 to always fail with ENOSYS. Some functions are actually named
3322 something starting with __ and the normal name is an alias. */
3323#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3324choke me
3325#else
3326$ac_func();
3327#endif
3328
3329; return 0; }
3330EOF
3331if { (eval echo configure:3332: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3332 rm -rf conftest*
3333 eval "ac_cv_func_$ac_func=yes"
3334else
3335 echo "configure: failed program was:" >&5
3336 cat conftest.$ac_ext >&5
3337 rm -rf conftest*
3338 eval "ac_cv_func_$ac_func=no"
3339fi
3340rm -f conftest*
3341fi
3342
3343if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3344 echo "$ac_t""yes" 1>&6
3345 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3346 cat >> confdefs.h <<EOF
3347#define $ac_tr_func 1
3348EOF
3349
3350else
3351 echo "$ac_t""no" 1>&6
3352fi
3353done
3354
3355
3356 if test "${ac_cv_func_stpcpy+set}" != "set"; then
3357 for ac_func in stpcpy
3358do
3359echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
3360echo "configure:3361: checking for $ac_func" >&5
3361if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3362 echo $ac_n "(cached) $ac_c" 1>&6
3363else
3364 cat > conftest.$ac_ext <<EOF
3365#line 3366 "configure"
3366#include "confdefs.h"
3367/* System header to define __stub macros and hopefully few prototypes,
3368 which can conflict with char $ac_func(); below. */
3369#include <assert.h>
3370/* Override any gcc2 internal prototype to avoid an error. */
3371/* We use char because int might match the return type of a gcc2
3372 builtin and then its argument prototype would still apply. */
3373char $ac_func();
3374
3375int main() {
3376
3377/* The GNU C library defines this for functions which it implements
3378 to always fail with ENOSYS. Some functions are actually named
3379 something starting with __ and the normal name is an alias. */
3380#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3381choke me
3382#else
3383$ac_func();
3384#endif
3385
3386; return 0; }
3387EOF
3388if { (eval echo configure:3389: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3389 rm -rf conftest*
3390 eval "ac_cv_func_$ac_func=yes"
3391else
3392 echo "configure: failed program was:" >&5
3393 cat conftest.$ac_ext >&5
3394 rm -rf conftest*
3395 eval "ac_cv_func_$ac_func=no"
3396fi
3397rm -f conftest*
3398fi
3399
3400if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3401 echo "$ac_t""yes" 1>&6
3402 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3403 cat >> confdefs.h <<EOF
3404#define $ac_tr_func 1
3405EOF
3406
3407else
3408 echo "$ac_t""no" 1>&6
3409fi
3410done
3411
3412 fi
3413 if test "${ac_cv_func_stpcpy}" = "yes"; then
3414 cat >> confdefs.h <<\EOF
3415#define HAVE_STPCPY 1
3416EOF
3417
3418 fi
3419
3420 if test $ac_cv_header_locale_h = yes; then
3421 echo $ac_n "checking for LC_MESSAGES""... $ac_c" 1>&6
3422echo "configure:3423: checking for LC_MESSAGES" >&5
3423if eval "test \"`echo '$''{'am_cv_val_LC_MESSAGES'+set}'`\" = set"; then
3424 echo $ac_n "(cached) $ac_c" 1>&6
3425else
3426 cat > conftest.$ac_ext <<EOF
3427#line 3428 "configure"
3428#include "confdefs.h"
3429#include <locale.h>
3430int main() {
3431return LC_MESSAGES
3432; return 0; }
3433EOF
3434if { (eval echo configure:3435: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3435 rm -rf conftest*
3436 am_cv_val_LC_MESSAGES=yes
3437else
3438 echo "configure: failed program was:" >&5
3439 cat conftest.$ac_ext >&5
3440 rm -rf conftest*
3441 am_cv_val_LC_MESSAGES=no
3442fi
3443rm -f conftest*
3444fi
3445
3446echo "$ac_t""$am_cv_val_LC_MESSAGES" 1>&6
3447 if test $am_cv_val_LC_MESSAGES = yes; then
3448 cat >> confdefs.h <<\EOF
3449#define HAVE_LC_MESSAGES 1
3450EOF
3451
3452 fi
3453 fi
3454 echo $ac_n "checking whether NLS is requested""... $ac_c" 1>&6
3455echo "configure:3456: checking whether NLS is requested" >&5
3456 # Check whether --enable-nls or --disable-nls was given.
3457if test "${enable_nls+set}" = set; then
3458 enableval="$enable_nls"
3459 USE_NLS=$enableval
3460else
3461 USE_NLS=yes
3462fi
3463
3464 echo "$ac_t""$USE_NLS" 1>&6
3465
3466
3467 USE_INCLUDED_LIBINTL=no
3468
3469 if test "$USE_NLS" = "yes"; then
3470 cat >> confdefs.h <<\EOF
3471#define ENABLE_NLS 1
3472EOF
3473
3474 echo $ac_n "checking whether included gettext is requested""... $ac_c" 1>&6
3475echo "configure:3476: checking whether included gettext is requested" >&5
3476 # Check whether --with-included-gettext or --without-included-gettext was given.
3477if test "${with_included_gettext+set}" = set; then
3478 withval="$with_included_gettext"
3479 nls_cv_force_use_gnu_gettext=$withval
3480else
3481 nls_cv_force_use_gnu_gettext=no
3482fi
3483
3484 echo "$ac_t""$nls_cv_force_use_gnu_gettext" 1>&6
3485
3486 nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext"
3487 if test "$nls_cv_force_use_gnu_gettext" != "yes"; then
3488 nls_cv_header_intl=
3489 nls_cv_header_libgt=
3490 CATOBJEXT=NONE
3491
3492 ac_safe=`echo "libintl.h" | sed 'y%./+-%__p_%'`
3493echo $ac_n "checking for libintl.h""... $ac_c" 1>&6
3494echo "configure:3495: checking for libintl.h" >&5
3495if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3496 echo $ac_n "(cached) $ac_c" 1>&6
3497else
3498 cat > conftest.$ac_ext <<EOF
3499#line 3500 "configure"
3500#include "confdefs.h"
3501#include <libintl.h>
3502EOF
3503ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3504{ (eval echo configure:3505: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3505ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3506if test -z "$ac_err"; then
3507 rm -rf conftest*
3508 eval "ac_cv_header_$ac_safe=yes"
3509else
3510 echo "$ac_err" >&5
3511 echo "configure: failed program was:" >&5
3512 cat conftest.$ac_ext >&5
3513 rm -rf conftest*
3514 eval "ac_cv_header_$ac_safe=no"
3515fi
3516rm -f conftest*
3517fi
3518if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3519 echo "$ac_t""yes" 1>&6
3520 echo $ac_n "checking for gettext in libc""... $ac_c" 1>&6
3521echo "configure:3522: checking for gettext in libc" >&5
3522if eval "test \"`echo '$''{'gt_cv_func_gettext_libc'+set}'`\" = set"; then
3523 echo $ac_n "(cached) $ac_c" 1>&6
3524else
3525 cat > conftest.$ac_ext <<EOF
3526#line 3527 "configure"
3527#include "confdefs.h"
3528#include <libintl.h>
3529int main() {
3530return (int) gettext ("")
3531; return 0; }
3532EOF
3533if { (eval echo configure:3534: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3534 rm -rf conftest*
3535 gt_cv_func_gettext_libc=yes
3536else
3537 echo "configure: failed program was:" >&5
3538 cat conftest.$ac_ext >&5
3539 rm -rf conftest*
3540 gt_cv_func_gettext_libc=no
3541fi
3542rm -f conftest*
3543fi
3544
3545echo "$ac_t""$gt_cv_func_gettext_libc" 1>&6
3546
3547 if test "$gt_cv_func_gettext_libc" != "yes"; then
3548 echo $ac_n "checking for bindtextdomain in -lintl""... $ac_c" 1>&6
3549echo "configure:3550: checking for bindtextdomain in -lintl" >&5
3550ac_lib_var=`echo intl'_'bindtextdomain | sed 'y%./+-%__p_%'`
3551if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3552 echo $ac_n "(cached) $ac_c" 1>&6
3553else
3554 ac_save_LIBS="$LIBS"
3555LIBS="-lintl $LIBS"
3556cat > conftest.$ac_ext <<EOF
3557#line 3558 "configure"
3558#include "confdefs.h"
3559/* Override any gcc2 internal prototype to avoid an error. */
3560/* We use char because int might match the return type of a gcc2
3561 builtin and then its argument prototype would still apply. */
3562char bindtextdomain();
3563
3564int main() {
3565bindtextdomain()
3566; return 0; }
3567EOF
3568if { (eval echo configure:3569: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3569 rm -rf conftest*
3570 eval "ac_cv_lib_$ac_lib_var=yes"
3571else
3572 echo "configure: failed program was:" >&5
3573 cat conftest.$ac_ext >&5
3574 rm -rf conftest*
3575 eval "ac_cv_lib_$ac_lib_var=no"
3576fi
3577rm -f conftest*
3578LIBS="$ac_save_LIBS"
3579
3580fi
3581if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3582 echo "$ac_t""yes" 1>&6
3583 echo $ac_n "checking for gettext in libintl""... $ac_c" 1>&6
3584echo "configure:3585: checking for gettext in libintl" >&5
3585if eval "test \"`echo '$''{'gt_cv_func_gettext_libintl'+set}'`\" = set"; then
3586 echo $ac_n "(cached) $ac_c" 1>&6
3587else
3588 cat > conftest.$ac_ext <<EOF
3589#line 3590 "configure"
3590#include "confdefs.h"
3591
3592int main() {
3593return (int) gettext ("")
3594; return 0; }
3595EOF
3596if { (eval echo configure:3597: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3597 rm -rf conftest*
3598 gt_cv_func_gettext_libintl=yes
3599else
3600 echo "configure: failed program was:" >&5
3601 cat conftest.$ac_ext >&5
3602 rm -rf conftest*
3603 gt_cv_func_gettext_libintl=no
3604fi
3605rm -f conftest*
3606fi
3607
3608echo "$ac_t""$gt_cv_func_gettext_libintl" 1>&6
3609else
3610 echo "$ac_t""no" 1>&6
3611fi
3612
3613 fi
3614
3615 if test "$gt_cv_func_gettext_libc" = "yes" \
3616 || test "$gt_cv_func_gettext_libintl" = "yes"; then
3617 cat >> confdefs.h <<\EOF
3618#define HAVE_GETTEXT 1
3619EOF
3620
3621 # Extract the first word of "msgfmt", so it can be a program name with args.
3622set dummy msgfmt; ac_word=$2
3623echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3624echo "configure:3625: checking for $ac_word" >&5
3625if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
3626 echo $ac_n "(cached) $ac_c" 1>&6
3627else
3628 case "$MSGFMT" in
3629 /*)
3630 ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
3631 ;;
3632 *)
3633 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
3634 for ac_dir in $PATH; do
3635 test -z "$ac_dir" && ac_dir=.
3636 if test -f $ac_dir/$ac_word; then
3637 if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then
3638 ac_cv_path_MSGFMT="$ac_dir/$ac_word"
3639 break
3640 fi
3641 fi
3642 done
3643 IFS="$ac_save_ifs"
3644 test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="no"
3645 ;;
3646esac
3647fi
3648MSGFMT="$ac_cv_path_MSGFMT"
3649if test -n "$MSGFMT"; then
3650 echo "$ac_t""$MSGFMT" 1>&6
3651else
3652 echo "$ac_t""no" 1>&6
3653fi
3654 if test "$MSGFMT" != "no"; then
3655 for ac_func in dcgettext
3656do
3657echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
3658echo "configure:3659: checking for $ac_func" >&5
3659if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3660 echo $ac_n "(cached) $ac_c" 1>&6
3661else
3662 cat > conftest.$ac_ext <<EOF
3663#line 3664 "configure"
3664#include "confdefs.h"
3665/* System header to define __stub macros and hopefully few prototypes,
3666 which can conflict with char $ac_func(); below. */
3667#include <assert.h>
3668/* Override any gcc2 internal prototype to avoid an error. */
3669/* We use char because int might match the return type of a gcc2
3670 builtin and then its argument prototype would still apply. */
3671char $ac_func();
3672
3673int main() {
3674
3675/* The GNU C library defines this for functions which it implements
3676 to always fail with ENOSYS. Some functions are actually named
3677 something starting with __ and the normal name is an alias. */
3678#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3679choke me
3680#else
3681$ac_func();
3682#endif
3683
3684; return 0; }
3685EOF
3686if { (eval echo configure:3687: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3687 rm -rf conftest*
3688 eval "ac_cv_func_$ac_func=yes"
3689else
3690 echo "configure: failed program was:" >&5
3691 cat conftest.$ac_ext >&5
3692 rm -rf conftest*
3693 eval "ac_cv_func_$ac_func=no"
3694fi
3695rm -f conftest*
3696fi
3697
3698if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3699 echo "$ac_t""yes" 1>&6
3700 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3701 cat >> confdefs.h <<EOF
3702#define $ac_tr_func 1
3703EOF
3704
3705else
3706 echo "$ac_t""no" 1>&6
3707fi
3708done
3709
3710 # Extract the first word of "gmsgfmt", so it can be a program name with args.
3711set dummy gmsgfmt; ac_word=$2
3712echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3713echo "configure:3714: checking for $ac_word" >&5
3714if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
3715 echo $ac_n "(cached) $ac_c" 1>&6
3716else
3717 case "$GMSGFMT" in
3718 /*)
3719 ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
3720 ;;
3721 ?:/*)
3722 ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a dos path.
3723 ;;
3724 *)
3725 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3726 ac_dummy="$PATH"
3727 for ac_dir in $ac_dummy; do
3728 test -z "$ac_dir" && ac_dir=.
3729 if test -f $ac_dir/$ac_word; then
3730 ac_cv_path_GMSGFMT="$ac_dir/$ac_word"
3731 break
3732 fi
3733 done
3734 IFS="$ac_save_ifs"
3735 test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
3736 ;;
3737esac
3738fi
3739GMSGFMT="$ac_cv_path_GMSGFMT"
3740if test -n "$GMSGFMT"; then
3741 echo "$ac_t""$GMSGFMT" 1>&6
3742else
3743 echo "$ac_t""no" 1>&6
3744fi
3745
3746 # Extract the first word of "xgettext", so it can be a program name with args.
3747set dummy xgettext; ac_word=$2
3748echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3749echo "configure:3750: checking for $ac_word" >&5
3750if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
3751 echo $ac_n "(cached) $ac_c" 1>&6
3752else
3753 case "$XGETTEXT" in
3754 /*)
3755 ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
3756 ;;
3757 *)
3758 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
3759 for ac_dir in $PATH; do
3760 test -z "$ac_dir" && ac_dir=.
3761 if test -f $ac_dir/$ac_word; then
3762 if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then
3763 ac_cv_path_XGETTEXT="$ac_dir/$ac_word"
3764 break
3765 fi
3766 fi
3767 done
3768 IFS="$ac_save_ifs"
3769 test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
3770 ;;
3771esac
3772fi
3773XGETTEXT="$ac_cv_path_XGETTEXT"
3774if test -n "$XGETTEXT"; then
3775 echo "$ac_t""$XGETTEXT" 1>&6
3776else
3777 echo "$ac_t""no" 1>&6
3778fi
3779
3780 cat > conftest.$ac_ext <<EOF
3781#line 3782 "configure"
3782#include "confdefs.h"
3783
3784int main() {
3785extern int _nl_msg_cat_cntr;
3786 return _nl_msg_cat_cntr
3787; return 0; }
3788EOF
3789if { (eval echo configure:3790: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3790 rm -rf conftest*
3791 CATOBJEXT=.gmo
3792 DATADIRNAME=share
3793else
3794 echo "configure: failed program was:" >&5
3795 cat conftest.$ac_ext >&5
3796 rm -rf conftest*
3797 CATOBJEXT=.mo
3798 DATADIRNAME=lib
3799fi
3800rm -f conftest*
3801 INSTOBJEXT=.mo
3802 fi
3803 fi
3804
3805else
3806 echo "$ac_t""no" 1>&6
3807fi
3808
3809
3810
3811 if test "$CATOBJEXT" = "NONE"; then
3812 nls_cv_use_gnu_gettext=yes
3813 fi
3814 fi
3815
3816 if test "$nls_cv_use_gnu_gettext" = "yes"; then
3817 INTLOBJS="\$(GETTOBJS)"
3818 # Extract the first word of "msgfmt", so it can be a program name with args.
3819set dummy msgfmt; ac_word=$2
3820echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3821echo "configure:3822: checking for $ac_word" >&5
3822if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
3823 echo $ac_n "(cached) $ac_c" 1>&6
3824else
3825 case "$MSGFMT" in
3826 /*)
3827 ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
3828 ;;
3829 *)
3830 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
3831 for ac_dir in $PATH; do
3832 test -z "$ac_dir" && ac_dir=.
3833 if test -f $ac_dir/$ac_word; then
3834 if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then
3835 ac_cv_path_MSGFMT="$ac_dir/$ac_word"
3836 break
3837 fi
3838 fi
3839 done
3840 IFS="$ac_save_ifs"
3841 test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="msgfmt"
3842 ;;
3843esac
3844fi
3845MSGFMT="$ac_cv_path_MSGFMT"
3846if test -n "$MSGFMT"; then
3847 echo "$ac_t""$MSGFMT" 1>&6
3848else
3849 echo "$ac_t""no" 1>&6
3850fi
3851
3852 # Extract the first word of "gmsgfmt", so it can be a program name with args.
3853set dummy gmsgfmt; ac_word=$2
3854echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3855echo "configure:3856: checking for $ac_word" >&5
3856if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
3857 echo $ac_n "(cached) $ac_c" 1>&6
3858else
3859 case "$GMSGFMT" in
3860 /*)
3861 ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
3862 ;;
3863 ?:/*)
3864 ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a dos path.
3865 ;;
3866 *)
3867 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3868 ac_dummy="$PATH"
3869 for ac_dir in $ac_dummy; do
3870 test -z "$ac_dir" && ac_dir=.
3871 if test -f $ac_dir/$ac_word; then
3872 ac_cv_path_GMSGFMT="$ac_dir/$ac_word"
3873 break
3874 fi
3875 done
3876 IFS="$ac_save_ifs"
3877 test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
3878 ;;
3879esac
3880fi
3881GMSGFMT="$ac_cv_path_GMSGFMT"
3882if test -n "$GMSGFMT"; then
3883 echo "$ac_t""$GMSGFMT" 1>&6
3884else
3885 echo "$ac_t""no" 1>&6
3886fi
3887
3888 # Extract the first word of "xgettext", so it can be a program name with args.
3889set dummy xgettext; ac_word=$2
3890echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3891echo "configure:3892: checking for $ac_word" >&5
3892if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
3893 echo $ac_n "(cached) $ac_c" 1>&6
3894else
3895 case "$XGETTEXT" in
3896 /*)
3897 ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
3898 ;;
3899 *)
3900 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
3901 for ac_dir in $PATH; do
3902 test -z "$ac_dir" && ac_dir=.
3903 if test -f $ac_dir/$ac_word; then
3904 if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then
3905 ac_cv_path_XGETTEXT="$ac_dir/$ac_word"
3906 break
3907 fi
3908 fi
3909 done
3910 IFS="$ac_save_ifs"
3911 test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
3912 ;;
3913esac
3914fi
3915XGETTEXT="$ac_cv_path_XGETTEXT"
3916if test -n "$XGETTEXT"; then
3917 echo "$ac_t""$XGETTEXT" 1>&6
3918else
3919 echo "$ac_t""no" 1>&6
3920fi
3921
3922
3923 USE_INCLUDED_LIBINTL=yes
3924 CATOBJEXT=.gmo
3925 INSTOBJEXT=.mo
3926 DATADIRNAME=share
3927 INTLDEPS='$(top_builddir)/../intl/libintl.a'
3928 INTLLIBS=$INTLDEPS
3929 LIBS=`echo $LIBS | sed -e 's/-lintl//'`
3930 nls_cv_header_intl=libintl.h
3931 nls_cv_header_libgt=libgettext.h
3932 fi
3933
3934 if test "$XGETTEXT" != ":"; then
3935 if $XGETTEXT --omit-header /dev/null 2> /dev/null; then
3936 : ;
3937 else
3938 echo "$ac_t""found xgettext programs is not GNU xgettext; ignore it" 1>&6
3939 XGETTEXT=":"
3940 fi
3941 fi
3942
3943 # We need to process the po/ directory.
3944 POSUB=po
3945 else
3946 DATADIRNAME=share
3947 nls_cv_header_intl=libintl.h
3948 nls_cv_header_libgt=libgettext.h
3949 fi
3950
3951 # If this is used in GNU gettext we have to set USE_NLS to `yes'
3952 # because some of the sources are only built for this goal.
3953 if test "$PACKAGE" = gettext; then
3954 USE_NLS=yes
3955 USE_INCLUDED_LIBINTL=yes
3956 fi
3957
3958 for lang in $ALL_LINGUAS; do
3959 GMOFILES="$GMOFILES $lang.gmo"
3960 POFILES="$POFILES $lang.po"
3961 done
3962
3963
3964
3965
3966
3967
3968
3969
3970
3971
3972
3973
3974
3975
3976 if test "x$CATOBJEXT" != "x"; then
3977 if test "x$ALL_LINGUAS" = "x"; then
3978 LINGUAS=
3979 else
3980 echo $ac_n "checking for catalogs to be installed""... $ac_c" 1>&6
3981echo "configure:3982: checking for catalogs to be installed" >&5
3982 NEW_LINGUAS=
3983 for lang in ${LINGUAS=$ALL_LINGUAS}; do
3984 case "$ALL_LINGUAS" in
3985 *$lang*) NEW_LINGUAS="$NEW_LINGUAS $lang" ;;
3986 esac
3987 done
3988 LINGUAS=$NEW_LINGUAS
3989 echo "$ac_t""$LINGUAS" 1>&6
3990 fi
3991
3992 if test -n "$LINGUAS"; then
3993 for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done
3994 fi
3995 fi
3996
3997 if test $ac_cv_header_locale_h = yes; then
3998 INCLUDE_LOCALE_H="#include <locale.h>"
3999 else
4000 INCLUDE_LOCALE_H="\
4001/* The system does not provide the header <locale.h>. Take care yourself. */"
4002 fi
4003
4004
4005 if test -f $srcdir/po2tbl.sed.in; then
4006 if test "$CATOBJEXT" = ".cat"; then
4007 ac_safe=`echo "linux/version.h" | sed 'y%./+-%__p_%'`
4008echo $ac_n "checking for linux/version.h""... $ac_c" 1>&6
4009echo "configure:4010: checking for linux/version.h" >&5
4010if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4011 echo $ac_n "(cached) $ac_c" 1>&6
4012else
4013 cat > conftest.$ac_ext <<EOF
4014#line 4015 "configure"
4015#include "confdefs.h"
4016#include <linux/version.h>
4017EOF
4018ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4019{ (eval echo configure:4020: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4020ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4021if test -z "$ac_err"; then
4022 rm -rf conftest*
4023 eval "ac_cv_header_$ac_safe=yes"
4024else
4025 echo "$ac_err" >&5
4026 echo "configure: failed program was:" >&5
4027 cat conftest.$ac_ext >&5
4028 rm -rf conftest*
4029 eval "ac_cv_header_$ac_safe=no"
4030fi
4031rm -f conftest*
4032fi
4033if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4034 echo "$ac_t""yes" 1>&6
4035 msgformat=linux
4036else
4037 echo "$ac_t""no" 1>&6
4038msgformat=xopen
4039fi
4040
4041
4042 sed -e '/^#/d' $srcdir/$msgformat-msg.sed > po2msg.sed
4043 fi
4044 sed -e '/^#.*[^\\]$/d' -e '/^#$/d' \
4045 $srcdir/po2tbl.sed.in > po2tbl.sed
4046 fi
4047
4048 if test "$PACKAGE" = "gettext"; then
4049 GT_NO="#NO#"
4050 GT_YES=
4051 else
4052 GT_NO=
4053 GT_YES="#YES#"
4054 fi
4055
4056
4057
4058 MKINSTALLDIRS="\$(srcdir)/../../mkinstalldirs"
4059
4060
4061 l=
4062
4063
4064 if test -d $srcdir/po; then
4065 test -d po || mkdir po
4066 if test "x$srcdir" != "x."; then
4067 if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then
4068 posrcprefix="$srcdir/"
4069 else
4070 posrcprefix="../$srcdir/"
4071 fi
4072 else
4073 posrcprefix="../"
4074 fi
4075 rm -f po/POTFILES
4076 sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \
4077 < $srcdir/po/POTFILES.in > po/POTFILES
4078 fi
4079
4080
4081. ${srcdir}/../bfd/configure.host
4082
4083
4084# Find a good install program. We prefer a C program (faster),
4085# so one script is as good as another. But avoid the broken or
4086# incompatible versions:
4087# SysV /etc/install, /usr/sbin/install
4088# SunOS /usr/etc/install
4089# IRIX /sbin/install
4090# AIX /bin/install
4091# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
4092# AFS /usr/afsws/bin/install, which mishandles nonexistent args
4093# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
4094# ./install, which can be erroneously created by make from ./install.sh.
4095echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
4096echo "configure:4097: checking for a BSD compatible install" >&5
4097if test -z "$INSTALL"; then
4098if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
4099 echo $ac_n "(cached) $ac_c" 1>&6
4100else
4101 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":"
4102 for ac_dir in $PATH; do
4103 # Account for people who put trailing slashes in PATH elements.
4104 case "$ac_dir/" in
4105 /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
4106 *)
4107 # OSF1 and SCO ODT 3.0 have their own names for install.
4108 # Don't use installbsd from OSF since it installs stuff as root
4109 # by default.
4110 for ac_prog in ginstall scoinst install; do
4111 if test -f $ac_dir/$ac_prog; then
4112 if test $ac_prog = install &&
4113 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
4114 # AIX install. It has an incompatible calling convention.
4115 :
4116 else
4117 ac_cv_path_install="$ac_dir/$ac_prog -c"
4118 break 2
4119 fi
4120 fi
4121 done
4122 ;;
4123 esac
4124 done
4125 IFS="$ac_save_IFS"
4126
4127fi
4128 if test "${ac_cv_path_install+set}" = set; then
4129 INSTALL="$ac_cv_path_install"
4130 else
4131 # As a last resort, use the slow shell script. We don't cache a
4132 # path for INSTALL within a source directory, because that will
4133 # break other packages using the cache if that directory is
4134 # removed, or if the path is relative.
4135 INSTALL="$ac_install_sh"
4136 fi
4137fi
4138echo "$ac_t""$INSTALL" 1>&6
4139
4140# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
4141# It thinks the first close brace ends the variable substitution.
4142test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
4143
4144test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
4145
4146test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
4147
4148
4149for ac_hdr in string.h strings.h stdlib.h
4150do
4151ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4152echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4153echo "configure:4154: checking for $ac_hdr" >&5
4154if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4155 echo $ac_n "(cached) $ac_c" 1>&6
4156else
4157 cat > conftest.$ac_ext <<EOF
4158#line 4159 "configure"
4159#include "confdefs.h"
4160#include <$ac_hdr>
4161EOF
4162ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4163{ (eval echo configure:4164: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4164ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4165if test -z "$ac_err"; then
4166 rm -rf conftest*
4167 eval "ac_cv_header_$ac_safe=yes"
4168else
4169 echo "$ac_err" >&5
4170 echo "configure: failed program was:" >&5
4171 cat conftest.$ac_ext >&5
4172 rm -rf conftest*
4173 eval "ac_cv_header_$ac_safe=no"
4174fi
4175rm -f conftest*
4176fi
4177if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4178 echo "$ac_t""yes" 1>&6
4179 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4180 cat >> confdefs.h <<EOF
4181#define $ac_tr_hdr 1
4182EOF
4183
4184else
4185 echo "$ac_t""no" 1>&6
4186fi
4187done
4188
4189
4190
4191using_cgen=no
4192
4193# Horrible hacks to build DLLs on Windows.
4194WIN32LDFLAGS=
4195WIN32LIBADD=
4196case "${host}" in
4197*-*-cygwin*)
4198 if test "$enable_shared" = "yes"; then
4199 WIN32LDFLAGS="-no-undefined"
4200 WIN32LIBADD="-L`pwd`/../bfd -lbfd -L`pwd`/../libiberty -liberty -L`pwd`/../intl -lintl -lcygwin"
4201 fi
4202 ;;
4203esac
4204
4205
4206
4207# target-specific stuff:
4208
4209# Canonicalize the secondary target names.
4210if test -n "$enable_targets" ; then
4211 for targ in `echo $enable_targets | sed 's/,/ /g'`
4212 do
4213 result=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $targ 2>/dev/null`
4214 if test -n "$result" ; then
4215 canon_targets="$canon_targets $result"
4216 else
4217 # Allow targets that config.sub doesn't recognize, like "all".
4218 canon_targets="$canon_targets $targ"
4219 fi
4220 done
4221fi
4222
4223all_targets=false
4224selarchs=
4225for targ in $target $canon_targets
4226do
4227 if test "x$targ" = "xall" ; then
4228 all_targets=true
4229 else
4230 . $srcdir/../bfd/config.bfd
4231 selarchs="$selarchs $targ_archs"
4232 fi
4233done
4234
4235# Utility var, documents generic cgen support files.
4236
4237cgen_files="cgen-opc.lo cgen-asm.lo cgen-dis.lo"
4238
4239# We don't do any links based on the target system, just makefile config.
4240
4241if test x${all_targets} = xfalse ; then
4242
4243 # Target architecture .o files.
4244 ta=
4245
4246 for arch in $selarchs
4247 do
4248 ad=`echo $arch | sed -e s/bfd_//g -e s/_arch//g`
4249 archdefs="$archdefs -DARCH_$ad"
4250 case "$arch" in
4251 bfd_a29k_arch) ta="$ta a29k-dis.lo" ;;
4252 bfd_alliant_arch) ;;
4253 bfd_alpha_arch) ta="$ta alpha-dis.lo alpha-opc.lo" ;;
4254 bfd_arc_arch) ta="$ta arc-dis.lo arc-opc.lo" ;;
4255 bfd_arm_arch) ta="$ta arm-dis.lo" ;;
4256 bfd_convex_arch) ;;
4257 bfd_d10v_arch) ta="$ta d10v-dis.lo d10v-opc.lo" ;;
4258 bfd_d30v_arch) ta="$ta d30v-dis.lo d30v-opc.lo" ;;
4259 bfd_fr30_arch) ta="$ta fr30-asm.lo fr30-desc.lo fr30-dis.lo fr30-ibld.lo fr30-opc.lo" using_cgen=yes ;;
4260 bfd_h8300_arch) ta="$ta h8300-dis.lo" ;;
4261 bfd_h8500_arch) ta="$ta h8500-dis.lo" ;;
4262 bfd_hppa_arch) ta="$ta hppa-dis.lo" ;;
4263 bfd_i386_arch) ta="$ta i386-dis.lo" ;;
4264 bfd_i860_arch) ;;
4265 bfd_i960_arch) ta="$ta i960-dis.lo" ;;
4266 bfd_m32r_arch) ta="$ta m32r-asm.lo m32r-desc.lo m32r-dis.lo m32r-ibld.lo m32r-opc.lo m32r-opinst.lo" using_cgen=yes ;;
4267 bfd_m68k_arch) ta="$ta m68k-dis.lo m68k-opc.lo" ;;
4268 bfd_m88k_arch) ta="$ta m88k-dis.lo" ;;
4269 bfd_mcore_arch) ta="$ta mcore-dis.lo" ;;
4270 bfd_mips_arch) ta="$ta mips-dis.lo mips-opc.lo mips16-opc.lo" ;;
4271 bfd_mn10200_arch) ta="$ta m10200-dis.lo m10200-opc.lo" ;;
4272 bfd_mn10300_arch) ta="$ta m10300-dis.lo m10300-opc.lo" ;;
4273 bfd_ns32k_arch) ta="$ta ns32k-dis.lo" ;;
4274 bfd_powerpc_arch) ta="$ta ppc-dis.lo ppc-opc.lo" ;;
4275 bfd_pyramid_arch) ;;
4276 bfd_romp_arch) ;;
4277 bfd_rs6000_arch) ta="$ta ppc-dis.lo ppc-opc.lo" ;;
4278 bfd_sh_arch) ta="$ta sh-dis.lo" ;;
4279 bfd_sparc_arch) ta="$ta sparc-dis.lo sparc-opc.lo" ;;
4280 bfd_tahoe_arch) ;;
4281 bfd_tic30_arch) ta="$ta tic30-dis.lo" ;;
4282 bfd_tic80_arch) ta="$ta tic80-dis.lo tic80-opc.lo" ;;
4283 bfd_v850_arch) ta="$ta v850-opc.lo v850-dis.lo" ;;
4284 bfd_v850e_arch) ta="$ta v850-opc.lo v850-dis.lo" ;;
4285 bfd_v850ea_arch) ta="$ta v850-opc.lo v850-dis.lo" ;;
4286 bfd_vax_arch) ta="$ta vax-dis.lo" ;;
4287 bfd_w65_arch) ta="$ta w65-dis.lo" ;;
4288 bfd_we32k_arch) ;;
4289 bfd_z8k_arch) ta="$ta z8k-dis.lo" ;;
4290
4291 "") ;;
4292 *) { echo "configure: error: *** unknown target architecture $arch" 1>&2; exit 1; } ;;
4293 esac
4294 done
4295
4296 if test $using_cgen = yes ; then
4297 ta="$ta $cgen_files"
4298 fi
4299
4300 # Weed out duplicate .o files.
4301 f=""
4302 for i in $ta ; do
4303 case " $f " in
4304 *" $i "*) ;;
4305 *) f="$f $i" ;;
4306 esac
4307 done
4308 ta="$f"
4309
4310 # And duplicate -D flags.
4311 f=""
4312 for i in $archdefs ; do
4313 case " $f " in
4314 *" $i "*) ;;
4315 *) f="$f $i" ;;
4316 esac
4317 done
4318 archdefs="$f"
4319
4320 BFD_MACHINES="$ta"
4321
4322else # all_targets is true
4323 archdefs=-DARCH_all
4324 BFD_MACHINES='$(ALL_MACHINES)'
4325fi
4326
4327
4328
4329
4330trap '' 1 2 15
4331cat > confcache <<\EOF
4332# This file is a shell script that caches the results of configure
4333# tests run on this system so they can be shared between configure
4334# scripts and configure runs. It is not useful on other systems.
4335# If it contains results you don't want to keep, you may remove or edit it.
4336#
4337# By default, configure uses ./config.cache as the cache file,
4338# creating it if it does not exist already. You can give configure
4339# the --cache-file=FILE option to use a different cache file; that is
4340# what configure does when it calls configure scripts in
4341# subdirectories, so they share the cache.
4342# Giving --cache-file=/dev/null disables caching, for debugging configure.
4343# config.status only pays attention to the cache file if you give it the
4344# --recheck option to rerun configure.
4345#
4346EOF
4347# The following way of writing the cache mishandles newlines in values,
4348# but we know of no workaround that is simple, portable, and efficient.
4349# So, don't put newlines in cache variables' values.
4350# Ultrix sh set writes to stderr and can't be redirected directly,
4351# and sets the high bit in the cache file unless we assign to the vars.
4352(set) 2>&1 |
4353 case `(ac_space=' '; set | grep ac_space) 2>&1` in
4354 *ac_space=\ *)
4355 # `set' does not quote correctly, so add quotes (double-quote substitution
4356 # turns \\\\ into \\, and sed turns \\ into \).
4357 sed -n \
4358 -e "s/'/'\\\\''/g" \
4359 -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
4360 ;;
4361 *)
4362 # `set' quotes correctly as required by POSIX, so do not add quotes.
4363 sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
4364 ;;
4365 esac >> confcache
4366if cmp -s $cache_file confcache; then
4367 :
4368else
4369 if test -w $cache_file; then
4370 echo "updating cache $cache_file"
4371 cat confcache > $cache_file
4372 else
4373 echo "not updating unwritable cache $cache_file"
4374 fi
4375fi
4376rm -f confcache
4377
4378trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
4379
4380test "x$prefix" = xNONE && prefix=$ac_default_prefix
4381# Let make expand exec_prefix.
4382test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
4383
4384# Any assignment to VPATH causes Sun make to only execute
4385# the first set of double-colon rules, so remove it if not needed.
4386# If there is a colon in the path, we need to keep it.
4387if test "x$srcdir" = x.; then
4388 ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
4389fi
4390
4391trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
4392
4393DEFS=-DHAVE_CONFIG_H
4394
4395# Without the "./", some shells look in PATH for config.status.
4396: ${CONFIG_STATUS=./config.status}
4397
4398echo creating $CONFIG_STATUS
4399rm -f $CONFIG_STATUS
4400cat > $CONFIG_STATUS <<EOF
4401#! /bin/sh
4402# Generated automatically by configure.
4403# Run this file to recreate the current configuration.
4404# This directory was configured as follows,
4405# on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
4406#
4407# $0 $ac_configure_args
4408#
4409# Compiler output produced by configure, useful for debugging
4410# configure, is in ./config.log if it exists.
4411
4412ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
4413for ac_option
4414do
4415 case "\$ac_option" in
4416 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
4417 echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
4418 exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
4419 -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
4420 echo "$CONFIG_STATUS generated by autoconf version 2.13"
4421 exit 0 ;;
4422 -help | --help | --hel | --he | --h)
4423 echo "\$ac_cs_usage"; exit 0 ;;
4424 *) echo "\$ac_cs_usage"; exit 1 ;;
4425 esac
4426done
4427
4428ac_given_srcdir=$srcdir
4429ac_given_INSTALL="$INSTALL"
4430
4431trap 'rm -fr `echo "Makefile po/Makefile.in:po/Make-in config.h:config.in" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
4432EOF
4433cat >> $CONFIG_STATUS <<EOF
4434
4435# Protect against being on the right side of a sed subst in config.status.
4436sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
4437 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
4438$ac_vpsub
4439$extrasub
4440s%@SHELL@%$SHELL%g
4441s%@CFLAGS@%$CFLAGS%g
4442s%@CPPFLAGS@%$CPPFLAGS%g
4443s%@CXXFLAGS@%$CXXFLAGS%g
4444s%@FFLAGS@%$FFLAGS%g
4445s%@DEFS@%$DEFS%g
4446s%@LDFLAGS@%$LDFLAGS%g
4447s%@LIBS@%$LIBS%g
4448s%@exec_prefix@%$exec_prefix%g
4449s%@prefix@%$prefix%g
4450s%@program_transform_name@%$program_transform_name%g
4451s%@bindir@%$bindir%g
4452s%@sbindir@%$sbindir%g
4453s%@libexecdir@%$libexecdir%g
4454s%@datadir@%$datadir%g
4455s%@sysconfdir@%$sysconfdir%g
4456s%@sharedstatedir@%$sharedstatedir%g
4457s%@localstatedir@%$localstatedir%g
4458s%@libdir@%$libdir%g
4459s%@includedir@%$includedir%g
4460s%@oldincludedir@%$oldincludedir%g
4461s%@infodir@%$infodir%g
4462s%@mandir@%$mandir%g
4463s%@host@%$host%g
4464s%@host_alias@%$host_alias%g
4465s%@host_cpu@%$host_cpu%g
4466s%@host_vendor@%$host_vendor%g
4467s%@host_os@%$host_os%g
4468s%@target@%$target%g
4469s%@target_alias@%$target_alias%g
4470s%@target_cpu@%$target_cpu%g
4471s%@target_vendor@%$target_vendor%g
4472s%@target_os@%$target_os%g
4473s%@build@%$build%g
4474s%@build_alias@%$build_alias%g
4475s%@build_cpu@%$build_cpu%g
4476s%@build_vendor@%$build_vendor%g
4477s%@build_os@%$build_os%g
4478s%@CC@%$CC%g
4479s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
4480s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
4481s%@INSTALL_DATA@%$INSTALL_DATA%g
4482s%@PACKAGE@%$PACKAGE%g
4483s%@VERSION@%$VERSION%g
4484s%@ACLOCAL@%$ACLOCAL%g
4485s%@AUTOCONF@%$AUTOCONF%g
4486s%@AUTOMAKE@%$AUTOMAKE%g
4487s%@AUTOHEADER@%$AUTOHEADER%g
4488s%@MAKEINFO@%$MAKEINFO%g
4489s%@SET_MAKE@%$SET_MAKE%g
4490s%@AR@%$AR%g
4491s%@RANLIB@%$RANLIB%g
4492s%@LD@%$LD%g
4493s%@NM@%$NM%g
4494s%@USE_SYMBOL_UNDERSCORE@%$USE_SYMBOL_UNDERSCORE%g
4495s%@LN_S@%$LN_S%g
4496s%@DLLTOOL@%$DLLTOOL%g
4497s%@AS@%$AS%g
4498s%@LIBTOOL@%$LIBTOOL%g
4499s%@MAINTAINER_MODE_TRUE@%$MAINTAINER_MODE_TRUE%g
4500s%@MAINTAINER_MODE_FALSE@%$MAINTAINER_MODE_FALSE%g
4501s%@MAINT@%$MAINT%g
4502s%@EXEEXT@%$EXEEXT%g
4503s%@CPP@%$CPP%g
4504s%@ALLOCA@%$ALLOCA%g
4505s%@USE_NLS@%$USE_NLS%g
4506s%@MSGFMT@%$MSGFMT%g
4507s%@GMSGFMT@%$GMSGFMT%g
4508s%@XGETTEXT@%$XGETTEXT%g
4509s%@USE_INCLUDED_LIBINTL@%$USE_INCLUDED_LIBINTL%g
4510s%@CATALOGS@%$CATALOGS%g
4511s%@CATOBJEXT@%$CATOBJEXT%g
4512s%@DATADIRNAME@%$DATADIRNAME%g
4513s%@GMOFILES@%$GMOFILES%g
4514s%@INSTOBJEXT@%$INSTOBJEXT%g
4515s%@INTLDEPS@%$INTLDEPS%g
4516s%@INTLLIBS@%$INTLLIBS%g
4517s%@INTLOBJS@%$INTLOBJS%g
4518s%@POFILES@%$POFILES%g
4519s%@POSUB@%$POSUB%g
4520s%@INCLUDE_LOCALE_H@%$INCLUDE_LOCALE_H%g
4521s%@GT_NO@%$GT_NO%g
4522s%@GT_YES@%$GT_YES%g
4523s%@MKINSTALLDIRS@%$MKINSTALLDIRS%g
4524s%@l@%$l%g
4525s%@HDEFINES@%$HDEFINES%g
4526s%@CGEN_MAINT_TRUE@%$CGEN_MAINT_TRUE%g
4527s%@CGEN_MAINT_FALSE@%$CGEN_MAINT_FALSE%g
4528s%@cgendir@%$cgendir%g
4529s%@cgen@%$cgen%g
4530s%@WIN32LDFLAGS@%$WIN32LDFLAGS%g
4531s%@WIN32LIBADD@%$WIN32LIBADD%g
4532s%@archdefs@%$archdefs%g
4533s%@BFD_MACHINES@%$BFD_MACHINES%g
4534
4535CEOF
4536EOF
4537
4538cat >> $CONFIG_STATUS <<\EOF
4539
4540# Split the substitutions into bite-sized pieces for seds with
4541# small command number limits, like on Digital OSF/1 and HP-UX.
4542ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
4543ac_file=1 # Number of current file.
4544ac_beg=1 # First line for current file.
4545ac_end=$ac_max_sed_cmds # Line after last line for current file.
4546ac_more_lines=:
4547ac_sed_cmds=""
4548while $ac_more_lines; do
4549 if test $ac_beg -gt 1; then
4550 sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
4551 else
4552 sed "${ac_end}q" conftest.subs > conftest.s$ac_file
4553 fi
4554 if test ! -s conftest.s$ac_file; then
4555 ac_more_lines=false
4556 rm -f conftest.s$ac_file
4557 else
4558 if test -z "$ac_sed_cmds"; then
4559 ac_sed_cmds="sed -f conftest.s$ac_file"
4560 else
4561 ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
4562 fi
4563 ac_file=`expr $ac_file + 1`
4564 ac_beg=$ac_end
4565 ac_end=`expr $ac_end + $ac_max_sed_cmds`
4566 fi
4567done
4568if test -z "$ac_sed_cmds"; then
4569 ac_sed_cmds=cat
4570fi
4571EOF
4572
4573cat >> $CONFIG_STATUS <<EOF
4574
4575CONFIG_FILES=\${CONFIG_FILES-"Makefile po/Makefile.in:po/Make-in"}
4576EOF
4577cat >> $CONFIG_STATUS <<\EOF
4578for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
4579 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
4580 case "$ac_file" in
4581 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
4582 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
4583 *) ac_file_in="${ac_file}.in" ;;
4584 esac
4585
4586 # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
4587
4588 # Remove last slash and all that follows it. Not all systems have dirname.
4589 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
4590 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
4591 # The file is in a subdirectory.
4592 test ! -d "$ac_dir" && mkdir "$ac_dir"
4593 ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
4594 # A "../" for each directory in $ac_dir_suffix.
4595 ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
4596 else
4597 ac_dir_suffix= ac_dots=
4598 fi
4599
4600 case "$ac_given_srcdir" in
4601 .) srcdir=.
4602 if test -z "$ac_dots"; then top_srcdir=.
4603 else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
4604 /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
4605 *) # Relative path.
4606 srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
4607 top_srcdir="$ac_dots$ac_given_srcdir" ;;
4608 esac
4609
4610 case "$ac_given_INSTALL" in
4611 [/$]*) INSTALL="$ac_given_INSTALL" ;;
4612 *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
4613 esac
4614
4615 echo creating "$ac_file"
4616 rm -f "$ac_file"
4617 configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
4618 case "$ac_file" in
4619 *Makefile*) ac_comsub="1i\\
4620# $configure_input" ;;
4621 *) ac_comsub= ;;
4622 esac
4623
4624 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
4625 sed -e "$ac_comsub
4626s%@configure_input@%$configure_input%g
4627s%@srcdir@%$srcdir%g
4628s%@top_srcdir@%$top_srcdir%g
4629s%@INSTALL@%$INSTALL%g
4630" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
4631fi; done
4632rm -f conftest.s*
4633
4634# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
4635# NAME is the cpp macro being defined and VALUE is the value it is being given.
4636#
4637# ac_d sets the value in "#define NAME VALUE" lines.
4638ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)'
4639ac_dB='\([ ][ ]*\)[^ ]*%\1#\2'
4640ac_dC='\3'
4641ac_dD='%g'
4642# ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
4643ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
4644ac_uB='\([ ]\)%\1#\2define\3'
4645ac_uC=' '
4646ac_uD='\4%g'
4647# ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
4648ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
4649ac_eB='$%\1#\2define\3'
4650ac_eC=' '
4651ac_eD='%g'
4652
4653if test "${CONFIG_HEADERS+set}" != set; then
4654EOF
4655cat >> $CONFIG_STATUS <<EOF
4656 CONFIG_HEADERS="config.h:config.in"
4657EOF
4658cat >> $CONFIG_STATUS <<\EOF
4659fi
4660for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
4661 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
4662 case "$ac_file" in
4663 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
4664 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
4665 *) ac_file_in="${ac_file}.in" ;;
4666 esac
4667
4668 echo creating $ac_file
4669
4670 rm -f conftest.frag conftest.in conftest.out
4671 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
4672 cat $ac_file_inputs > conftest.in
4673
4674EOF
4675
4676# Transform confdefs.h into a sed script conftest.vals that substitutes
4677# the proper values into config.h.in to produce config.h. And first:
4678# Protect against being on the right side of a sed subst in config.status.
4679# Protect against being in an unquoted here document in config.status.
4680rm -f conftest.vals
4681cat > conftest.hdr <<\EOF
4682s/[\\&%]/\\&/g
4683s%[\\$`]%\\&%g
4684s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
4685s%ac_d%ac_u%gp
4686s%ac_u%ac_e%gp
4687EOF
4688sed -n -f conftest.hdr confdefs.h > conftest.vals
4689rm -f conftest.hdr
4690
4691# This sed command replaces #undef with comments. This is necessary, for
4692# example, in the case of _POSIX_SOURCE, which is predefined and required
4693# on some systems where configure will not decide to define it.
4694cat >> conftest.vals <<\EOF
4695s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
4696EOF
4697
4698# Break up conftest.vals because some shells have a limit on
4699# the size of here documents, and old seds have small limits too.
4700
4701rm -f conftest.tail
4702while :
4703do
4704 ac_lines=`grep -c . conftest.vals`
4705 # grep -c gives empty output for an empty file on some AIX systems.
4706 if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
4707 # Write a limited-size here document to conftest.frag.
4708 echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
4709 sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
4710 echo 'CEOF
4711 sed -f conftest.frag conftest.in > conftest.out
4712 rm -f conftest.in
4713 mv conftest.out conftest.in
4714' >> $CONFIG_STATUS
4715 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
4716 rm -f conftest.vals
4717 mv conftest.tail conftest.vals
4718done
4719rm -f conftest.vals
4720
4721cat >> $CONFIG_STATUS <<\EOF
4722 rm -f conftest.frag conftest.h
4723 echo "/* $ac_file. Generated automatically by configure. */" > conftest.h
4724 cat conftest.in >> conftest.h
4725 rm -f conftest.in
4726 if cmp -s $ac_file conftest.h 2>/dev/null; then
4727 echo "$ac_file is unchanged"
4728 rm -f conftest.h
4729 else
4730 # Remove last slash and all that follows it. Not all systems have dirname.
4731 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
4732 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
4733 # The file is in a subdirectory.
4734 test ! -d "$ac_dir" && mkdir "$ac_dir"
4735 fi
4736 rm -f $ac_file
4737 mv conftest.h $ac_file
4738 fi
4739fi; done
4740
4741EOF
4742cat >> $CONFIG_STATUS <<EOF
4743
4744
4745EOF
4746cat >> $CONFIG_STATUS <<\EOF
4747test -z "$CONFIG_HEADERS" || echo timestamp > stamp-h
4748sed -e '/POTFILES =/r po/POTFILES' po/Makefile.in > po/Makefile
4749exit 0
4750EOF
4751chmod +x $CONFIG_STATUS
4752rm -fr confdefs* $ac_clean_files
4753test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
4754
This page took 0.222921 seconds and 4 git commands to generate.