* gdbarch.sh (ADDRESS_CLASS_TYPE_FLAGS_TO_NAME)
[deliverable/binutils-gdb.git] / readline / configure
CommitLineData
d60d9f65 1#! /bin/sh
9255ee31
EZ
2# From configure.in for Readline 4.3, version 2.45, from autoconf version 2.52.
3# Guess values for system-dependent variables and create Makefiles.
4# Generated by Autoconf 2.52 for readline 4.3.
5#
6# Report bugs to <bug-readline@gnu.org>.
7#
8# Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
9# Free Software Foundation, Inc.
10# This configure script is free software; the Free Software Foundation
11# gives unlimited permission to copy, distribute and modify it.
d60d9f65 12
9255ee31
EZ
13# Avoid depending upon Character Ranges.
14as_cr_letters='abcdefghijklmnopqrstuvwxyz'
15as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
16as_cr_Letters=$as_cr_letters$as_cr_LETTERS
17as_cr_digits='0123456789'
18as_cr_alnum=$as_cr_Letters$as_cr_digits
d60d9f65 19
9255ee31
EZ
20# Sed expression to map a string onto a valid variable name.
21as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
d60d9f65 22
9255ee31
EZ
23# Sed expression to map a string onto a valid CPP name.
24as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
d60d9f65 25
9255ee31
EZ
26# Be Bourne compatible
27if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
28 emulate sh
29 NULLCMD=:
30elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
31 set -o posix
32fi
d60d9f65 33
9255ee31
EZ
34# Name of the executable.
35as_me=`echo "$0" |sed 's,.*[\\/],,'`
d60d9f65 36
9255ee31
EZ
37if expr a : '\(a\)' >/dev/null 2>&1; then
38 as_expr=expr
39else
40 as_expr=false
41fi
d60d9f65 42
9255ee31
EZ
43rm -f conf$$ conf$$.exe conf$$.file
44echo >conf$$.file
45if ln -s conf$$.file conf$$ 2>/dev/null; then
46 # We could just check for DJGPP; but this test a) works b) is more generic
47 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
48 if test -f conf$$.exe; then
49 # Don't use ln at all; we don't have any links
50 as_ln_s='cp -p'
51 else
52 as_ln_s='ln -s'
53 fi
54elif ln conf$$.file conf$$ 2>/dev/null; then
55 as_ln_s=ln
56else
57 as_ln_s='cp -p'
58fi
59rm -f conf$$ conf$$.exe conf$$.file
d60d9f65 60
9255ee31 61as_executable_p="test -f"
d60d9f65 62
9255ee31
EZ
63# Support unset when possible.
64if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
65 as_unset=unset
66else
67 as_unset=false
68fi
d60d9f65 69
9255ee31
EZ
70# NLS nuisances.
71$as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
72$as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
73$as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
74$as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
75$as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
76$as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
77$as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
78$as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
79
80# IFS
81# We need space, tab and new line, in precisely that order.
82as_nl='
83'
84IFS=" $as_nl"
85
86# CDPATH.
87$as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
88
89# Name of the host.
90# hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
91# so uname gets run too.
92ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
93
94exec 6>&1
d60d9f65 95
d60d9f65 96#
9255ee31
EZ
97# Initializations.
98#
d60d9f65 99ac_default_prefix=/usr/local
9255ee31
EZ
100cross_compiling=no
101subdirs=
102MFLAGS= MAKEFLAGS=
103SHELL=${CONFIG_SHELL-/bin/sh}
104
105# Maximum number of lines to put in a shell here document.
106# This variable seems obsolete. It should probably be removed, and
107# only ac_max_sed_lines should be used.
108: ${ac_max_here_lines=38}
109
110ac_unique_file="readline.h"
111# Factoring default headers for most tests.
112ac_includes_default="\
113#include <stdio.h>
114#if HAVE_SYS_TYPES_H
115# include <sys/types.h>
116#endif
117#if HAVE_SYS_STAT_H
118# include <sys/stat.h>
119#endif
120#if STDC_HEADERS
121# include <stdlib.h>
122# include <stddef.h>
123#else
124# if HAVE_STDLIB_H
125# include <stdlib.h>
126# endif
127#endif
128#if HAVE_STRING_H
129# if !STDC_HEADERS && HAVE_MEMORY_H
130# include <memory.h>
131# endif
132# include <string.h>
133#endif
134#if HAVE_STRINGS_H
135# include <strings.h>
136#endif
137#if HAVE_INTTYPES_H
138# include <inttypes.h>
139#else
140# if HAVE_STDINT_H
141# include <stdint.h>
142# endif
143#endif
144#if HAVE_UNISTD_H
145# include <unistd.h>
146#endif"
d60d9f65
SS
147
148# Initialize some variables set by options.
9255ee31
EZ
149ac_init_help=
150ac_init_version=false
d60d9f65
SS
151# The variables have the same names as the options, with
152# dashes changed to underlines.
9255ee31 153cache_file=/dev/null
d60d9f65 154exec_prefix=NONE
d60d9f65 155no_create=
d60d9f65
SS
156no_recursion=
157prefix=NONE
158program_prefix=NONE
159program_suffix=NONE
160program_transform_name=s,x,x,
161silent=
162site=
163srcdir=
d60d9f65
SS
164verbose=
165x_includes=NONE
166x_libraries=NONE
9255ee31
EZ
167
168# Installation directory options.
169# These are left unexpanded so users can "make install exec_prefix=/foo"
170# and all the variables that are supposed to be based on exec_prefix
171# by default will actually change.
172# Use braces instead of parens because sh, perl, etc. also accept them.
d60d9f65
SS
173bindir='${exec_prefix}/bin'
174sbindir='${exec_prefix}/sbin'
175libexecdir='${exec_prefix}/libexec'
176datadir='${prefix}/share'
177sysconfdir='${prefix}/etc'
178sharedstatedir='${prefix}/com'
179localstatedir='${prefix}/var'
180libdir='${exec_prefix}/lib'
181includedir='${prefix}/include'
182oldincludedir='/usr/include'
183infodir='${prefix}/info'
184mandir='${prefix}/man'
185
9255ee31
EZ
186# Identity of this package.
187PACKAGE_NAME='readline'
188PACKAGE_TARNAME='readline'
189PACKAGE_VERSION='4.3'
190PACKAGE_STRING='readline 4.3'
191PACKAGE_BUGREPORT='bug-readline@gnu.org'
d60d9f65
SS
192
193ac_prev=
194for ac_option
195do
d60d9f65
SS
196 # If the previous option needs an argument, assign it.
197 if test -n "$ac_prev"; then
198 eval "$ac_prev=\$ac_option"
199 ac_prev=
200 continue
201 fi
202
9255ee31 203 ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
d60d9f65
SS
204
205 # Accept the important Cygnus configure options, so we can diagnose typos.
206
9255ee31 207 case $ac_option in
d60d9f65
SS
208
209 -bindir | --bindir | --bindi | --bind | --bin | --bi)
210 ac_prev=bindir ;;
211 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
9255ee31 212 bindir=$ac_optarg ;;
d60d9f65
SS
213
214 -build | --build | --buil | --bui | --bu)
9255ee31 215 ac_prev=build_alias ;;
d60d9f65 216 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
9255ee31 217 build_alias=$ac_optarg ;;
d60d9f65
SS
218
219 -cache-file | --cache-file | --cache-fil | --cache-fi \
220 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
221 ac_prev=cache_file ;;
222 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
223 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
9255ee31
EZ
224 cache_file=$ac_optarg ;;
225
226 --config-cache | -C)
227 cache_file=config.cache ;;
d60d9f65
SS
228
229 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
230 ac_prev=datadir ;;
231 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
232 | --da=*)
9255ee31 233 datadir=$ac_optarg ;;
d60d9f65
SS
234
235 -disable-* | --disable-*)
9255ee31 236 ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
d60d9f65 237 # Reject names that are not valid shell variable names.
9255ee31
EZ
238 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
239 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
240 { (exit 1); exit 1; }; }
241 ac_feature=`echo $ac_feature | sed 's/-/_/g'`
242 eval "enable_$ac_feature=no" ;;
d60d9f65
SS
243
244 -enable-* | --enable-*)
9255ee31 245 ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
d60d9f65 246 # Reject names that are not valid shell variable names.
9255ee31
EZ
247 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
248 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
249 { (exit 1); exit 1; }; }
250 ac_feature=`echo $ac_feature | sed 's/-/_/g'`
251 case $ac_option in
252 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
d60d9f65
SS
253 *) ac_optarg=yes ;;
254 esac
9255ee31 255 eval "enable_$ac_feature='$ac_optarg'" ;;
d60d9f65
SS
256
257 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
258 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
259 | --exec | --exe | --ex)
260 ac_prev=exec_prefix ;;
261 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
262 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
263 | --exec=* | --exe=* | --ex=*)
9255ee31 264 exec_prefix=$ac_optarg ;;
d60d9f65
SS
265
266 -gas | --gas | --ga | --g)
267 # Obsolete; use --with-gas.
268 with_gas=yes ;;
269
9255ee31
EZ
270 -help | --help | --hel | --he | -h)
271 ac_init_help=long ;;
272 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
273 ac_init_help=recursive ;;
274 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
275 ac_init_help=short ;;
d60d9f65
SS
276
277 -host | --host | --hos | --ho)
9255ee31 278 ac_prev=host_alias ;;
d60d9f65 279 -host=* | --host=* | --hos=* | --ho=*)
9255ee31 280 host_alias=$ac_optarg ;;
d60d9f65
SS
281
282 -includedir | --includedir | --includedi | --included | --include \
283 | --includ | --inclu | --incl | --inc)
284 ac_prev=includedir ;;
285 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
286 | --includ=* | --inclu=* | --incl=* | --inc=*)
9255ee31 287 includedir=$ac_optarg ;;
d60d9f65
SS
288
289 -infodir | --infodir | --infodi | --infod | --info | --inf)
290 ac_prev=infodir ;;
291 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
9255ee31 292 infodir=$ac_optarg ;;
d60d9f65
SS
293
294 -libdir | --libdir | --libdi | --libd)
295 ac_prev=libdir ;;
296 -libdir=* | --libdir=* | --libdi=* | --libd=*)
9255ee31 297 libdir=$ac_optarg ;;
d60d9f65
SS
298
299 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
300 | --libexe | --libex | --libe)
301 ac_prev=libexecdir ;;
302 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
303 | --libexe=* | --libex=* | --libe=*)
9255ee31 304 libexecdir=$ac_optarg ;;
d60d9f65
SS
305
306 -localstatedir | --localstatedir | --localstatedi | --localstated \
307 | --localstate | --localstat | --localsta | --localst \
308 | --locals | --local | --loca | --loc | --lo)
309 ac_prev=localstatedir ;;
310 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
311 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
312 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
9255ee31 313 localstatedir=$ac_optarg ;;
d60d9f65
SS
314
315 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
316 ac_prev=mandir ;;
317 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
9255ee31 318 mandir=$ac_optarg ;;
d60d9f65
SS
319
320 -nfp | --nfp | --nf)
321 # Obsolete; use --without-fp.
322 with_fp=no ;;
323
324 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
325 | --no-cr | --no-c)
326 no_create=yes ;;
327
328 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
329 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
330 no_recursion=yes ;;
331
332 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
333 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
334 | --oldin | --oldi | --old | --ol | --o)
335 ac_prev=oldincludedir ;;
336 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
337 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
338 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
9255ee31 339 oldincludedir=$ac_optarg ;;
d60d9f65
SS
340
341 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
342 ac_prev=prefix ;;
343 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
9255ee31 344 prefix=$ac_optarg ;;
d60d9f65
SS
345
346 -program-prefix | --program-prefix | --program-prefi | --program-pref \
347 | --program-pre | --program-pr | --program-p)
348 ac_prev=program_prefix ;;
349 -program-prefix=* | --program-prefix=* | --program-prefi=* \
350 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
9255ee31 351 program_prefix=$ac_optarg ;;
d60d9f65
SS
352
353 -program-suffix | --program-suffix | --program-suffi | --program-suff \
354 | --program-suf | --program-su | --program-s)
355 ac_prev=program_suffix ;;
356 -program-suffix=* | --program-suffix=* | --program-suffi=* \
357 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
9255ee31 358 program_suffix=$ac_optarg ;;
d60d9f65
SS
359
360 -program-transform-name | --program-transform-name \
361 | --program-transform-nam | --program-transform-na \
362 | --program-transform-n | --program-transform- \
363 | --program-transform | --program-transfor \
364 | --program-transfo | --program-transf \
365 | --program-trans | --program-tran \
366 | --progr-tra | --program-tr | --program-t)
367 ac_prev=program_transform_name ;;
368 -program-transform-name=* | --program-transform-name=* \
369 | --program-transform-nam=* | --program-transform-na=* \
370 | --program-transform-n=* | --program-transform-=* \
371 | --program-transform=* | --program-transfor=* \
372 | --program-transfo=* | --program-transf=* \
373 | --program-trans=* | --program-tran=* \
374 | --progr-tra=* | --program-tr=* | --program-t=*)
9255ee31 375 program_transform_name=$ac_optarg ;;
d60d9f65
SS
376
377 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
378 | -silent | --silent | --silen | --sile | --sil)
379 silent=yes ;;
380
381 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
382 ac_prev=sbindir ;;
383 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
384 | --sbi=* | --sb=*)
9255ee31 385 sbindir=$ac_optarg ;;
d60d9f65
SS
386
387 -sharedstatedir | --sharedstatedir | --sharedstatedi \
388 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
389 | --sharedst | --shareds | --shared | --share | --shar \
390 | --sha | --sh)
391 ac_prev=sharedstatedir ;;
392 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
393 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
394 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
395 | --sha=* | --sh=*)
9255ee31 396 sharedstatedir=$ac_optarg ;;
d60d9f65
SS
397
398 -site | --site | --sit)
399 ac_prev=site ;;
400 -site=* | --site=* | --sit=*)
9255ee31 401 site=$ac_optarg ;;
d60d9f65
SS
402
403 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
404 ac_prev=srcdir ;;
405 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
9255ee31 406 srcdir=$ac_optarg ;;
d60d9f65
SS
407
408 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
409 | --syscon | --sysco | --sysc | --sys | --sy)
410 ac_prev=sysconfdir ;;
411 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
412 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
9255ee31 413 sysconfdir=$ac_optarg ;;
d60d9f65
SS
414
415 -target | --target | --targe | --targ | --tar | --ta | --t)
9255ee31 416 ac_prev=target_alias ;;
d60d9f65 417 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
9255ee31 418 target_alias=$ac_optarg ;;
d60d9f65
SS
419
420 -v | -verbose | --verbose | --verbos | --verbo | --verb)
421 verbose=yes ;;
422
9255ee31
EZ
423 -version | --version | --versio | --versi | --vers | -V)
424 ac_init_version=: ;;
d60d9f65
SS
425
426 -with-* | --with-*)
9255ee31 427 ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
d60d9f65 428 # Reject names that are not valid shell variable names.
9255ee31
EZ
429 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
430 { echo "$as_me: error: invalid package name: $ac_package" >&2
431 { (exit 1); exit 1; }; }
d60d9f65 432 ac_package=`echo $ac_package| sed 's/-/_/g'`
9255ee31
EZ
433 case $ac_option in
434 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
d60d9f65
SS
435 *) ac_optarg=yes ;;
436 esac
9255ee31 437 eval "with_$ac_package='$ac_optarg'" ;;
d60d9f65
SS
438
439 -without-* | --without-*)
9255ee31 440 ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
d60d9f65 441 # Reject names that are not valid shell variable names.
9255ee31
EZ
442 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
443 { echo "$as_me: error: invalid package name: $ac_package" >&2
444 { (exit 1); exit 1; }; }
445 ac_package=`echo $ac_package | sed 's/-/_/g'`
446 eval "with_$ac_package=no" ;;
d60d9f65
SS
447
448 --x)
449 # Obsolete; use --with-x.
450 with_x=yes ;;
451
452 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
453 | --x-incl | --x-inc | --x-in | --x-i)
454 ac_prev=x_includes ;;
455 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
456 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
9255ee31 457 x_includes=$ac_optarg ;;
d60d9f65
SS
458
459 -x-libraries | --x-libraries | --x-librarie | --x-librari \
460 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
461 ac_prev=x_libraries ;;
462 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
463 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
9255ee31 464 x_libraries=$ac_optarg ;;
d60d9f65 465
9255ee31
EZ
466 -*) { echo "$as_me: error: unrecognized option: $ac_option
467Try \`$0 --help' for more information." >&2
468 { (exit 1); exit 1; }; }
d60d9f65
SS
469 ;;
470
9255ee31
EZ
471 *=*)
472 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
473 # Reject names that are not valid shell variable names.
474 expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
475 { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
476 { (exit 1); exit 1; }; }
477 ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
478 eval "$ac_envvar='$ac_optarg'"
479 export $ac_envvar ;;
480
d60d9f65 481 *)
9255ee31
EZ
482 # FIXME: should be removed in autoconf 3.0.
483 echo "$as_me: WARNING: you should use --build, --host, --target" >&2
484 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
485 echo "$as_me: WARNING: invalid host type: $ac_option" >&2
486 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
d60d9f65
SS
487 ;;
488
489 esac
490done
491
492if test -n "$ac_prev"; then
9255ee31
EZ
493 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
494 { echo "$as_me: error: missing argument to $ac_option" >&2
495 { (exit 1); exit 1; }; }
d60d9f65 496fi
d60d9f65 497
9255ee31
EZ
498# Be sure to have absolute paths.
499for ac_var in exec_prefix prefix
500do
501 eval ac_val=$`echo $ac_var`
502 case $ac_val in
503 [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
504 *) { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
505 { (exit 1); exit 1; }; };;
506 esac
507done
d60d9f65 508
9255ee31
EZ
509# Be sure to have absolute paths.
510for ac_var in bindir sbindir libexecdir datadir sysconfdir sharedstatedir \
511 localstatedir libdir includedir oldincludedir infodir mandir
d60d9f65 512do
9255ee31
EZ
513 eval ac_val=$`echo $ac_var`
514 case $ac_val in
515 [\\/$]* | ?:[\\/]* ) ;;
516 *) { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
517 { (exit 1); exit 1; }; };;
d60d9f65
SS
518 esac
519done
520
9255ee31
EZ
521# There might be people who depend on the old broken behavior: `$host'
522# used to hold the argument of --host etc.
523build=$build_alias
524host=$host_alias
525target=$target_alias
526
527# FIXME: should be removed in autoconf 3.0.
528if test "x$host_alias" != x; then
529 if test "x$build_alias" = x; then
530 cross_compiling=maybe
531 echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
532 If a cross compiler is detected then cross compile mode will be used." >&2
533 elif test "x$build_alias" != "x$host_alias"; then
534 cross_compiling=yes
535 fi
536fi
d60d9f65 537
9255ee31
EZ
538ac_tool_prefix=
539test -n "$host_alias" && ac_tool_prefix=$host_alias-
d60d9f65 540
9255ee31 541test "$silent" = yes && exec 6>/dev/null
d60d9f65
SS
542
543# Find the source files, if location was not specified.
544if test -z "$srcdir"; then
545 ac_srcdir_defaulted=yes
546 # Try the directory containing this script, then its parent.
547 ac_prog=$0
9255ee31 548 ac_confdir=`echo "$ac_prog" | sed 's%[\\/][^\\/][^\\/]*$%%'`
d60d9f65
SS
549 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
550 srcdir=$ac_confdir
551 if test ! -r $srcdir/$ac_unique_file; then
552 srcdir=..
553 fi
554else
555 ac_srcdir_defaulted=no
556fi
557if test ! -r $srcdir/$ac_unique_file; then
558 if test "$ac_srcdir_defaulted" = yes; then
9255ee31
EZ
559 { echo "$as_me: error: cannot find sources in $ac_confdir or .." >&2
560 { (exit 1); exit 1; }; }
1b17e766 561 else
9255ee31
EZ
562 { echo "$as_me: error: cannot find sources in $srcdir" >&2
563 { (exit 1); exit 1; }; }
d60d9f65
SS
564 fi
565fi
9255ee31
EZ
566srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
567ac_env_build_alias_set=${build_alias+set}
568ac_env_build_alias_value=$build_alias
569ac_cv_env_build_alias_set=${build_alias+set}
570ac_cv_env_build_alias_value=$build_alias
571ac_env_host_alias_set=${host_alias+set}
572ac_env_host_alias_value=$host_alias
573ac_cv_env_host_alias_set=${host_alias+set}
574ac_cv_env_host_alias_value=$host_alias
575ac_env_target_alias_set=${target_alias+set}
576ac_env_target_alias_value=$target_alias
577ac_cv_env_target_alias_set=${target_alias+set}
578ac_cv_env_target_alias_value=$target_alias
579ac_env_CC_set=${CC+set}
580ac_env_CC_value=$CC
581ac_cv_env_CC_set=${CC+set}
582ac_cv_env_CC_value=$CC
583ac_env_CFLAGS_set=${CFLAGS+set}
584ac_env_CFLAGS_value=$CFLAGS
585ac_cv_env_CFLAGS_set=${CFLAGS+set}
586ac_cv_env_CFLAGS_value=$CFLAGS
587ac_env_LDFLAGS_set=${LDFLAGS+set}
588ac_env_LDFLAGS_value=$LDFLAGS
589ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
590ac_cv_env_LDFLAGS_value=$LDFLAGS
591ac_env_CPPFLAGS_set=${CPPFLAGS+set}
592ac_env_CPPFLAGS_value=$CPPFLAGS
593ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
594ac_cv_env_CPPFLAGS_value=$CPPFLAGS
595ac_env_CPP_set=${CPP+set}
596ac_env_CPP_value=$CPP
597ac_cv_env_CPP_set=${CPP+set}
598ac_cv_env_CPP_value=$CPP
d60d9f65 599
9255ee31
EZ
600#
601# Report the --help message.
602#
603if test "$ac_init_help" = "long"; then
604 # Omit some internal or obsolete options to make the list less imposing.
605 # This message is too long to be a string in the A/UX 3.1 sh.
606 cat <<EOF
607\`configure' configures readline 4.3 to adapt to many kinds of systems.
d60d9f65 608
9255ee31 609Usage: $0 [OPTION]... [VAR=VALUE]...
d60d9f65 610
9255ee31
EZ
611To assign environment variables (e.g., CC, CFLAGS...), specify them as
612VAR=VALUE. See below for descriptions of some of the useful variables.
d60d9f65 613
9255ee31 614Defaults for the options are specified in brackets.
d60d9f65 615
9255ee31
EZ
616Configuration:
617 -h, --help display this help and exit
618 --help=short display options specific to this package
619 --help=recursive display the short help of all the included packages
620 -V, --version display version information and exit
621 -q, --quiet, --silent do not print \`checking...' messages
622 --cache-file=FILE cache test results in FILE [disabled]
623 -C, --config-cache alias for \`--cache-file=config.cache'
624 -n, --no-create do not create output files
625 --srcdir=DIR find the sources in DIR [configure dir or \`..']
d60d9f65 626
9255ee31 627EOF
d60d9f65 628
9255ee31
EZ
629 cat <<EOF
630Installation directories:
631 --prefix=PREFIX install architecture-independent files in PREFIX
632 [$ac_default_prefix]
633 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
634 [PREFIX]
635
636By default, \`make install' will install all the files in
637\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
638an installation prefix other than \`$ac_default_prefix' using \`--prefix',
639for instance \`--prefix=\$HOME'.
640
641For better control, use the options below.
642
643Fine tuning of the installation directories:
644 --bindir=DIR user executables [EPREFIX/bin]
645 --sbindir=DIR system admin executables [EPREFIX/sbin]
646 --libexecdir=DIR program executables [EPREFIX/libexec]
647 --datadir=DIR read-only architecture-independent data [PREFIX/share]
648 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
649 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
650 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
651 --libdir=DIR object code libraries [EPREFIX/lib]
652 --includedir=DIR C header files [PREFIX/include]
653 --oldincludedir=DIR C header files for non-gcc [/usr/include]
654 --infodir=DIR info documentation [PREFIX/info]
655 --mandir=DIR man documentation [PREFIX/man]
656EOF
d60d9f65 657
9255ee31 658 cat <<\EOF
d60d9f65 659
9255ee31
EZ
660System types:
661 --build=BUILD configure for building on BUILD [guessed]
662 --host=HOST build programs to run on HOST [BUILD]
663EOF
d60d9f65 664fi
d60d9f65 665
9255ee31
EZ
666if test -n "$ac_init_help"; then
667 case $ac_init_help in
668 short | recursive ) echo "Configuration of readline 4.3:";;
669 esac
670 cat <<\EOF
d60d9f65 671
9255ee31
EZ
672Optional Features:
673 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
674 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
675 --enable-shared build shared libraries [default=YES]
676 --enable-static build static libraries [default=YES]
d60d9f65 677
9255ee31
EZ
678Optional Packages:
679 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
680 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
681 --with-curses use the curses library instead of the termcap
682 library
683
684Some influential environment variables:
685 CC C compiler command
686 CFLAGS C compiler flags
687 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
688 nonstandard directory <lib dir>
689 CPPFLAGS C/C++ preprocessor flags, e.g. -I<include dir> if you have
690 headers in a nonstandard directory <include dir>
691 CPP C preprocessor
692
693Use these variables to override the choices made by `configure' or to help
694it to find libraries and programs with nonstandard names/locations.
695
696Report bugs to <bug-readline@gnu.org>.
697EOF
698fi
d60d9f65 699
9255ee31
EZ
700if test "$ac_init_help" = "recursive"; then
701 # If there are subdirs, report their specific --help.
702 ac_popdir=`pwd`
703 for ac_subdir in : $ac_subdirs_all; do test "x$ac_subdir" = x: && continue
704 cd $ac_subdir
705 # A "../" for each directory in /$ac_subdir.
706 ac_dots=`echo $ac_subdir |
707 sed 's,^\./,,;s,[^/]$,&/,;s,[^/]*/,../,g'`
708
709 case $srcdir in
710 .) # No --srcdir option. We are building in place.
711 ac_sub_srcdir=$srcdir ;;
712 [\\/]* | ?:[\\/]* ) # Absolute path.
713 ac_sub_srcdir=$srcdir/$ac_subdir ;;
714 *) # Relative path.
715 ac_sub_srcdir=$ac_dots$srcdir/$ac_subdir ;;
716 esac
d60d9f65 717
9255ee31
EZ
718 # Check for guested configure; otherwise get Cygnus style configure.
719 if test -f $ac_sub_srcdir/configure.gnu; then
720 echo
721 $SHELL $ac_sub_srcdir/configure.gnu --help=recursive
722 elif test -f $ac_sub_srcdir/configure; then
723 echo
724 $SHELL $ac_sub_srcdir/configure --help=recursive
725 elif test -f $ac_sub_srcdir/configure.ac ||
726 test -f $ac_sub_srcdir/configure.in; then
727 echo
728 $ac_configure --help
729 else
730 echo "$as_me: WARNING: no configuration information is in $ac_subdir" >&2
731 fi
732 cd $ac_popdir
733 done
d60d9f65
SS
734fi
735
9255ee31
EZ
736test -n "$ac_init_help" && exit 0
737if $ac_init_version; then
738 cat <<\EOF
739readline configure 4.3
740generated by GNU Autoconf 2.52
d60d9f65 741
9255ee31
EZ
742Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
743Free Software Foundation, Inc.
744This configure script is free software; the Free Software Foundation
745gives unlimited permission to copy, distribute and modify it.
746EOF
747 exit 0
d60d9f65 748fi
9255ee31
EZ
749exec 5>config.log
750cat >&5 <<EOF
751This file contains any messages produced by compilers while
752running configure, to aid debugging if configure makes a mistake.
d60d9f65 753
9255ee31
EZ
754It was created by readline $as_me 4.3, which was
755generated by GNU Autoconf 2.52. Invocation command line was
d60d9f65 756
9255ee31
EZ
757 $ $0 $@
758
759EOF
760{
761cat <<_ASUNAME
762## ---------- ##
763## Platform. ##
764## ---------- ##
765
766hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
767uname -m = `(uname -m) 2>/dev/null || echo unknown`
768uname -r = `(uname -r) 2>/dev/null || echo unknown`
769uname -s = `(uname -s) 2>/dev/null || echo unknown`
770uname -v = `(uname -v) 2>/dev/null || echo unknown`
771
772/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
773/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
774
775/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
776/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
777/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
778hostinfo = `(hostinfo) 2>/dev/null || echo unknown`
779/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
780/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
781/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
782
783PATH = $PATH
784
785_ASUNAME
786} >&5
787
788cat >&5 <<EOF
789## ------------ ##
790## Core tests. ##
791## ------------ ##
792
793EOF
794
795# Keep a trace of the command line.
796# Strip out --no-create and --no-recursion so they do not pile up.
797# Also quote any args containing shell meta-characters.
798ac_configure_args=
799ac_sep=
800for ac_arg
801do
802 case $ac_arg in
803 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
804 | --no-cr | --no-c) ;;
805 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
806 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
807 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
808 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"`
809 ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
810 ac_sep=" " ;;
811 *) ac_configure_args="$ac_configure_args$ac_sep$ac_arg"
812 ac_sep=" " ;;
813 esac
814 # Get rid of the leading space.
815done
816
817# When interrupted or exit'd, cleanup temporary files, and complete
818# config.log. We remove comments because anyway the quotes in there
819# would cause problems or look ugly.
820trap 'exit_status=$?
821 # Save into config.log some information that might help in debugging.
822 echo >&5
823 echo "## ----------------- ##" >&5
824 echo "## Cache variables. ##" >&5
825 echo "## ----------------- ##" >&5
826 echo >&5
827 # The following way of writing the cache mishandles newlines in values,
828{
829 (set) 2>&1 |
830 case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
831 *ac_space=\ *)
832 sed -n \
833 "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
834 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
835 ;;
836 *)
837 sed -n \
838 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
839 ;;
840 esac;
841} >&5
842 sed "/^$/d" confdefs.h >conftest.log
843 if test -s conftest.log; then
844 echo >&5
845 echo "## ------------ ##" >&5
846 echo "## confdefs.h. ##" >&5
847 echo "## ------------ ##" >&5
848 echo >&5
849 cat conftest.log >&5
850 fi
851 (echo; echo) >&5
852 test "$ac_signal" != 0 &&
853 echo "$as_me: caught signal $ac_signal" >&5
854 echo "$as_me: exit $exit_status" >&5
855 rm -rf conftest* confdefs* core core.* *.core conf$$* $ac_clean_files &&
856 exit $exit_status
857 ' 0
858for ac_signal in 1 2 13 15; do
859 trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
860done
861ac_signal=0
862
863# confdefs.h avoids OS command line length limits that DEFS can exceed.
864rm -rf conftest* confdefs.h
865# AIX cpp loses on an empty file, so make sure it contains at least a newline.
866echo >confdefs.h
867
868# Let the site file select an alternate cache file if it wants to.
869# Prefer explicitly selected file to automatically selected ones.
870if test -z "$CONFIG_SITE"; then
871 if test "x$prefix" != xNONE; then
872 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
873 else
874 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
875 fi
876fi
877for ac_site_file in $CONFIG_SITE; do
878 if test -r "$ac_site_file"; then
879 { echo "$as_me:879: loading site script $ac_site_file" >&5
880echo "$as_me: loading site script $ac_site_file" >&6;}
881 cat "$ac_site_file" >&5
882 . "$ac_site_file"
883 fi
884done
885
886if test -r "$cache_file"; then
887 # Some versions of bash will fail to source /dev/null (special
888 # files actually), so we avoid doing that.
889 if test -f "$cache_file"; then
890 { echo "$as_me:890: loading cache $cache_file" >&5
891echo "$as_me: loading cache $cache_file" >&6;}
892 case $cache_file in
893 [\\/]* | ?:[\\/]* ) . $cache_file;;
894 *) . ./$cache_file;;
895 esac
896 fi
897else
898 { echo "$as_me:898: creating cache $cache_file" >&5
899echo "$as_me: creating cache $cache_file" >&6;}
900 >$cache_file
901fi
902
903# Check that the precious variables saved in the cache have kept the same
904# value.
905ac_cache_corrupted=false
906for ac_var in `(set) 2>&1 |
907 sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
908 eval ac_old_set=\$ac_cv_env_${ac_var}_set
909 eval ac_new_set=\$ac_env_${ac_var}_set
910 eval ac_old_val="\$ac_cv_env_${ac_var}_value"
911 eval ac_new_val="\$ac_env_${ac_var}_value"
912 case $ac_old_set,$ac_new_set in
913 set,)
914 { echo "$as_me:914: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
915echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
916 ac_cache_corrupted=: ;;
917 ,set)
918 { echo "$as_me:918: error: \`$ac_var' was not set in the previous run" >&5
919echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
920 ac_cache_corrupted=: ;;
921 ,);;
922 *)
923 if test "x$ac_old_val" != "x$ac_new_val"; then
924 { echo "$as_me:924: error: \`$ac_var' has changed since the previous run:" >&5
925echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
926 { echo "$as_me:926: former value: $ac_old_val" >&5
927echo "$as_me: former value: $ac_old_val" >&2;}
928 { echo "$as_me:928: current value: $ac_new_val" >&5
929echo "$as_me: current value: $ac_new_val" >&2;}
930 ac_cache_corrupted=:
931 fi;;
932 esac
933 # Pass precious variables to config.status. It doesn't matter if
934 # we pass some twice (in addition to the command line arguments).
935 if test "$ac_new_set" = set; then
936 case $ac_new_val in
937 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
938 ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"`
939 ac_configure_args="$ac_configure_args '$ac_arg'"
940 ;;
941 *) ac_configure_args="$ac_configure_args $ac_var=$ac_new_val"
942 ;;
943 esac
944 fi
945done
946if $ac_cache_corrupted; then
947 { echo "$as_me:947: error: changes in the environment can compromise the build" >&5
948echo "$as_me: error: changes in the environment can compromise the build" >&2;}
949 { { echo "$as_me:949: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
950echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
951 { (exit 1); exit 1; }; }
952fi
953
954ac_ext=c
955ac_cpp='$CPP $CPPFLAGS'
956ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
957ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
958ac_compiler_gnu=$ac_cv_c_compiler_gnu
959
960case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
961 *c*,-n*) ECHO_N= ECHO_C='
962' ECHO_T=' ' ;;
963 *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
964 *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
965esac
966echo "#! $SHELL" >conftest.sh
967echo "exit 0" >>conftest.sh
968chmod +x conftest.sh
969if { (echo "$as_me:969: PATH=\".;.\"; conftest.sh") >&5
970 (PATH=".;."; conftest.sh) 2>&5
971 ac_status=$?
972 echo "$as_me:972: \$? = $ac_status" >&5
973 (exit $ac_status); }; then
974 ac_path_separator=';'
975else
976 ac_path_separator=:
d60d9f65 977fi
9255ee31
EZ
978PATH_SEPARATOR="$ac_path_separator"
979rm -f conftest.sh
980
981ac_config_headers="$ac_config_headers config.h"
982
983LIBVERSION=4.3
984
985ac_aux_dir=
986for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
987 if test -f $ac_dir/install-sh; then
988 ac_aux_dir=$ac_dir
989 ac_install_sh="$ac_aux_dir/install-sh -c"
990 break
991 elif test -f $ac_dir/install.sh; then
992 ac_aux_dir=$ac_dir
993 ac_install_sh="$ac_aux_dir/install.sh -c"
994 break
995 elif test -f $ac_dir/shtool; then
996 ac_aux_dir=$ac_dir
997 ac_install_sh="$ac_aux_dir/shtool install -c"
998 break
999 fi
1000done
1001if test -z "$ac_aux_dir"; then
1002 { { echo "$as_me:1002: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
1003echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
1004 { (exit 1); exit 1; }; }
1005fi
1006ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1007ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1008ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
1009
1010# Make sure we can run config.sub.
1011$ac_config_sub sun4 >/dev/null 2>&1 ||
1012 { { echo "$as_me:1012: error: cannot run $ac_config_sub" >&5
1013echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1014 { (exit 1); exit 1; }; }
1015
1016echo "$as_me:1016: checking build system type" >&5
1017echo $ECHO_N "checking build system type... $ECHO_C" >&6
1018if test "${ac_cv_build+set}" = set; then
1019 echo $ECHO_N "(cached) $ECHO_C" >&6
1020else
1021 ac_cv_build_alias=$build_alias
1022test -z "$ac_cv_build_alias" &&
1023 ac_cv_build_alias=`$ac_config_guess`
1024test -z "$ac_cv_build_alias" &&
1025 { { echo "$as_me:1025: error: cannot guess build type; you must specify one" >&5
1026echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1027 { (exit 1); exit 1; }; }
1028ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
1029 { { echo "$as_me:1029: error: $ac_config_sub $ac_cv_build_alias failed." >&5
1030echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed." >&2;}
1031 { (exit 1); exit 1; }; }
1032
1033fi
1034echo "$as_me:1034: result: $ac_cv_build" >&5
1035echo "${ECHO_T}$ac_cv_build" >&6
1036build=$ac_cv_build
1037build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1038build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1039build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1040
1041echo "$as_me:1041: checking host system type" >&5
1042echo $ECHO_N "checking host system type... $ECHO_C" >&6
1043if test "${ac_cv_host+set}" = set; then
1044 echo $ECHO_N "(cached) $ECHO_C" >&6
1045else
1046 ac_cv_host_alias=$host_alias
1047test -z "$ac_cv_host_alias" &&
1048 ac_cv_host_alias=$ac_cv_build_alias
1049ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
1050 { { echo "$as_me:1050: error: $ac_config_sub $ac_cv_host_alias failed" >&5
1051echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1052 { (exit 1); exit 1; }; }
1053
1054fi
1055echo "$as_me:1055: result: $ac_cv_host" >&5
1056echo "${ECHO_T}$ac_cv_host" >&6
1057host=$ac_cv_host
1058host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1059host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1060host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1061
1062opt_curses=no
1063
1064# Check whether --with-curses or --without-curses was given.
1065if test "${with_curses+set}" = set; then
1066 withval="$with_curses"
1067 opt_curses=$withval
1068fi;
1069
1070if test "$opt_curses" = "yes"; then
1071 prefer_curses=yes
1072fi
1073
1074opt_static_libs=yes
1075opt_shared_libs=yes
1076
1077# Check whether --enable-shared or --disable-shared was given.
1078if test "${enable_shared+set}" = set; then
1079 enableval="$enable_shared"
1080 opt_shared_libs=$enableval
1081fi;
1082# Check whether --enable-static or --disable-static was given.
1083if test "${enable_static+set}" = set; then
1084 enableval="$enable_static"
1085 opt_static_libs=$enableval
1086fi;
1087
1088echo ""
1089echo "Beginning configuration for readline-$LIBVERSION for ${host_cpu}-${host_vendor}-${host_os}"
1090echo ""
1091
1092# We want these before the checks, so the checks can modify their values.
1093test -z "$CFLAGS" && CFLAGS=-g auto_cflags=1
1094
1095echo "$as_me:1095: checking whether ${MAKE-make} sets \${MAKE}" >&5
1096echo $ECHO_N "checking whether ${MAKE-make} sets \${MAKE}... $ECHO_C" >&6
1097set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,./+-,__p_,'`
1098if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
1099 echo $ECHO_N "(cached) $ECHO_C" >&6
1100else
1101 cat >conftest.make <<\EOF
1102all:
1103 @echo 'ac_maketemp="${MAKE}"'
1104EOF
1105# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1106eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
1107if test -n "$ac_maketemp"; then
1108 eval ac_cv_prog_make_${ac_make}_set=yes
1109else
1110 eval ac_cv_prog_make_${ac_make}_set=no
1111fi
1112rm -f conftest.make
1113fi
1114if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
1115 echo "$as_me:1115: result: yes" >&5
1116echo "${ECHO_T}yes" >&6
1117 SET_MAKE=
1118else
1119 echo "$as_me:1119: result: no" >&5
1120echo "${ECHO_T}no" >&6
1121 SET_MAKE="MAKE=${MAKE-make}"
1122fi
1123
1124ac_ext=c
1125ac_cpp='$CPP $CPPFLAGS'
1126ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1127ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1128ac_compiler_gnu=$ac_cv_c_compiler_gnu
1129if test -n "$ac_tool_prefix"; then
1130 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
1131set dummy ${ac_tool_prefix}gcc; ac_word=$2
1132echo "$as_me:1132: checking for $ac_word" >&5
1133echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1134if test "${ac_cv_prog_CC+set}" = set; then
1135 echo $ECHO_N "(cached) $ECHO_C" >&6
1136else
1137 if test -n "$CC"; then
1138 ac_cv_prog_CC="$CC" # Let the user override the test.
1139else
1140 ac_save_IFS=$IFS; IFS=$ac_path_separator
1141ac_dummy="$PATH"
1142for ac_dir in $ac_dummy; do
1143 IFS=$ac_save_IFS
1144 test -z "$ac_dir" && ac_dir=.
1145 $as_executable_p "$ac_dir/$ac_word" || continue
1146ac_cv_prog_CC="${ac_tool_prefix}gcc"
1147echo "$as_me:1147: found $ac_dir/$ac_word" >&5
1148break
1149done
1150
d60d9f65 1151fi
9255ee31
EZ
1152fi
1153CC=$ac_cv_prog_CC
d60d9f65 1154if test -n "$CC"; then
9255ee31
EZ
1155 echo "$as_me:1155: result: $CC" >&5
1156echo "${ECHO_T}$CC" >&6
1157else
1158 echo "$as_me:1158: result: no" >&5
1159echo "${ECHO_T}no" >&6
1160fi
1161
1162fi
1163if test -z "$ac_cv_prog_CC"; then
1164 ac_ct_CC=$CC
1165 # Extract the first word of "gcc", so it can be a program name with args.
1166set dummy gcc; ac_word=$2
1167echo "$as_me:1167: checking for $ac_word" >&5
1168echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1169if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1170 echo $ECHO_N "(cached) $ECHO_C" >&6
1171else
1172 if test -n "$ac_ct_CC"; then
1173 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1174else
1175 ac_save_IFS=$IFS; IFS=$ac_path_separator
1176ac_dummy="$PATH"
1177for ac_dir in $ac_dummy; do
1178 IFS=$ac_save_IFS
1179 test -z "$ac_dir" && ac_dir=.
1180 $as_executable_p "$ac_dir/$ac_word" || continue
1181ac_cv_prog_ac_ct_CC="gcc"
1182echo "$as_me:1182: found $ac_dir/$ac_word" >&5
1183break
1184done
1185
1186fi
1187fi
1188ac_ct_CC=$ac_cv_prog_ac_ct_CC
1189if test -n "$ac_ct_CC"; then
1190 echo "$as_me:1190: result: $ac_ct_CC" >&5
1191echo "${ECHO_T}$ac_ct_CC" >&6
1192else
1193 echo "$as_me:1193: result: no" >&5
1194echo "${ECHO_T}no" >&6
1195fi
1196
1197 CC=$ac_ct_CC
d60d9f65 1198else
9255ee31 1199 CC="$ac_cv_prog_CC"
d60d9f65
SS
1200fi
1201
1202if test -z "$CC"; then
9255ee31
EZ
1203 if test -n "$ac_tool_prefix"; then
1204 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
1205set dummy ${ac_tool_prefix}cc; ac_word=$2
1206echo "$as_me:1206: checking for $ac_word" >&5
1207echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1208if test "${ac_cv_prog_CC+set}" = set; then
1209 echo $ECHO_N "(cached) $ECHO_C" >&6
1210else
1211 if test -n "$CC"; then
1212 ac_cv_prog_CC="$CC" # Let the user override the test.
1213else
1214 ac_save_IFS=$IFS; IFS=$ac_path_separator
1215ac_dummy="$PATH"
1216for ac_dir in $ac_dummy; do
1217 IFS=$ac_save_IFS
1218 test -z "$ac_dir" && ac_dir=.
1219 $as_executable_p "$ac_dir/$ac_word" || continue
1220ac_cv_prog_CC="${ac_tool_prefix}cc"
1221echo "$as_me:1221: found $ac_dir/$ac_word" >&5
1222break
1223done
1224
1225fi
1226fi
1227CC=$ac_cv_prog_CC
1228if test -n "$CC"; then
1229 echo "$as_me:1229: result: $CC" >&5
1230echo "${ECHO_T}$CC" >&6
1231else
1232 echo "$as_me:1232: result: no" >&5
1233echo "${ECHO_T}no" >&6
1234fi
1235
1236fi
1237if test -z "$ac_cv_prog_CC"; then
1238 ac_ct_CC=$CC
d60d9f65
SS
1239 # Extract the first word of "cc", so it can be a program name with args.
1240set dummy cc; ac_word=$2
9255ee31
EZ
1241echo "$as_me:1241: checking for $ac_word" >&5
1242echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1243if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1244 echo $ECHO_N "(cached) $ECHO_C" >&6
1245else
1246 if test -n "$ac_ct_CC"; then
1247 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1248else
1249 ac_save_IFS=$IFS; IFS=$ac_path_separator
1250ac_dummy="$PATH"
1251for ac_dir in $ac_dummy; do
1252 IFS=$ac_save_IFS
1253 test -z "$ac_dir" && ac_dir=.
1254 $as_executable_p "$ac_dir/$ac_word" || continue
1255ac_cv_prog_ac_ct_CC="cc"
1256echo "$as_me:1256: found $ac_dir/$ac_word" >&5
1257break
1258done
1259
1260fi
1261fi
1262ac_ct_CC=$ac_cv_prog_ac_ct_CC
1263if test -n "$ac_ct_CC"; then
1264 echo "$as_me:1264: result: $ac_ct_CC" >&5
1265echo "${ECHO_T}$ac_ct_CC" >&6
1266else
1267 echo "$as_me:1267: result: no" >&5
1268echo "${ECHO_T}no" >&6
1269fi
1270
1271 CC=$ac_ct_CC
1272else
1273 CC="$ac_cv_prog_CC"
1274fi
1275
1276fi
1277if test -z "$CC"; then
1278 # Extract the first word of "cc", so it can be a program name with args.
1279set dummy cc; ac_word=$2
1280echo "$as_me:1280: checking for $ac_word" >&5
1281echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1282if test "${ac_cv_prog_CC+set}" = set; then
1283 echo $ECHO_N "(cached) $ECHO_C" >&6
d60d9f65
SS
1284else
1285 if test -n "$CC"; then
1286 ac_cv_prog_CC="$CC" # Let the user override the test.
1287else
d60d9f65 1288 ac_prog_rejected=no
9255ee31
EZ
1289 ac_save_IFS=$IFS; IFS=$ac_path_separator
1290ac_dummy="$PATH"
1291for ac_dir in $ac_dummy; do
1292 IFS=$ac_save_IFS
1293 test -z "$ac_dir" && ac_dir=.
1294 $as_executable_p "$ac_dir/$ac_word" || continue
1295if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
1296 ac_prog_rejected=yes
1297 continue
1298fi
1299ac_cv_prog_CC="cc"
1300echo "$as_me:1300: found $ac_dir/$ac_word" >&5
1301break
1302done
1303
d60d9f65
SS
1304if test $ac_prog_rejected = yes; then
1305 # We found a bogon in the path, so make sure we never use it.
1306 set dummy $ac_cv_prog_CC
1307 shift
9255ee31 1308 if test $# != 0; then
d60d9f65
SS
1309 # We chose a different compiler from the bogus one.
1310 # However, it has the same basename, so the bogon will be chosen
1311 # first if we set CC to just the basename; use the full file name.
1312 shift
9255ee31 1313 set dummy "$ac_dir/$ac_word" ${1+"$@"}
d60d9f65
SS
1314 shift
1315 ac_cv_prog_CC="$@"
1316 fi
1317fi
1318fi
1319fi
9255ee31 1320CC=$ac_cv_prog_CC
d60d9f65 1321if test -n "$CC"; then
9255ee31
EZ
1322 echo "$as_me:1322: result: $CC" >&5
1323echo "${ECHO_T}$CC" >&6
d60d9f65 1324else
9255ee31
EZ
1325 echo "$as_me:1325: result: no" >&5
1326echo "${ECHO_T}no" >&6
d60d9f65
SS
1327fi
1328
9255ee31
EZ
1329fi
1330if test -z "$CC"; then
1331 if test -n "$ac_tool_prefix"; then
1332 for ac_prog in cl
1333 do
1334 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
1335set dummy $ac_tool_prefix$ac_prog; ac_word=$2
1336echo "$as_me:1336: checking for $ac_word" >&5
1337echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1338if test "${ac_cv_prog_CC+set}" = set; then
1339 echo $ECHO_N "(cached) $ECHO_C" >&6
d60d9f65
SS
1340else
1341 if test -n "$CC"; then
1342 ac_cv_prog_CC="$CC" # Let the user override the test.
1343else
9255ee31
EZ
1344 ac_save_IFS=$IFS; IFS=$ac_path_separator
1345ac_dummy="$PATH"
1346for ac_dir in $ac_dummy; do
1347 IFS=$ac_save_IFS
1348 test -z "$ac_dir" && ac_dir=.
1349 $as_executable_p "$ac_dir/$ac_word" || continue
1350ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
1351echo "$as_me:1351: found $ac_dir/$ac_word" >&5
1352break
1353done
1354
d60d9f65
SS
1355fi
1356fi
9255ee31 1357CC=$ac_cv_prog_CC
d60d9f65 1358if test -n "$CC"; then
9255ee31
EZ
1359 echo "$as_me:1359: result: $CC" >&5
1360echo "${ECHO_T}$CC" >&6
d60d9f65 1361else
9255ee31
EZ
1362 echo "$as_me:1362: result: no" >&5
1363echo "${ECHO_T}no" >&6
d60d9f65
SS
1364fi
1365
9255ee31
EZ
1366 test -n "$CC" && break
1367 done
1368fi
1369if test -z "$CC"; then
1370 ac_ct_CC=$CC
1371 for ac_prog in cl
1372do
1373 # Extract the first word of "$ac_prog", so it can be a program name with args.
1374set dummy $ac_prog; ac_word=$2
1375echo "$as_me:1375: checking for $ac_word" >&5
1376echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1377if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1378 echo $ECHO_N "(cached) $ECHO_C" >&6
1379else
1380 if test -n "$ac_ct_CC"; then
1381 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1382else
1383 ac_save_IFS=$IFS; IFS=$ac_path_separator
1384ac_dummy="$PATH"
1385for ac_dir in $ac_dummy; do
1386 IFS=$ac_save_IFS
1387 test -z "$ac_dir" && ac_dir=.
1388 $as_executable_p "$ac_dir/$ac_word" || continue
1389ac_cv_prog_ac_ct_CC="$ac_prog"
1390echo "$as_me:1390: found $ac_dir/$ac_word" >&5
1391break
1392done
d60d9f65 1393
9255ee31
EZ
1394fi
1395fi
1396ac_ct_CC=$ac_cv_prog_ac_ct_CC
1397if test -n "$ac_ct_CC"; then
1398 echo "$as_me:1398: result: $ac_ct_CC" >&5
1399echo "${ECHO_T}$ac_ct_CC" >&6
1400else
1401 echo "$as_me:1401: result: no" >&5
1402echo "${ECHO_T}no" >&6
1403fi
d60d9f65 1404
9255ee31
EZ
1405 test -n "$ac_ct_CC" && break
1406done
c862e87b 1407
9255ee31
EZ
1408 CC=$ac_ct_CC
1409fi
1410
1411fi
1412
1413test -z "$CC" && { { echo "$as_me:1413: error: no acceptable cc found in \$PATH" >&5
1414echo "$as_me: error: no acceptable cc found in \$PATH" >&2;}
1415 { (exit 1); exit 1; }; }
1416
1417# Provide some information about the compiler.
1418echo "$as_me:1418:" \
1419 "checking for C compiler version" >&5
1420ac_compiler=`set X $ac_compile; echo $2`
1421{ (eval echo "$as_me:1421: \"$ac_compiler --version </dev/null >&5\"") >&5
1422 (eval $ac_compiler --version </dev/null >&5) 2>&5
1423 ac_status=$?
1424 echo "$as_me:1424: \$? = $ac_status" >&5
1425 (exit $ac_status); }
1426{ (eval echo "$as_me:1426: \"$ac_compiler -v </dev/null >&5\"") >&5
1427 (eval $ac_compiler -v </dev/null >&5) 2>&5
1428 ac_status=$?
1429 echo "$as_me:1429: \$? = $ac_status" >&5
1430 (exit $ac_status); }
1431{ (eval echo "$as_me:1431: \"$ac_compiler -V </dev/null >&5\"") >&5
1432 (eval $ac_compiler -V </dev/null >&5) 2>&5
1433 ac_status=$?
1434 echo "$as_me:1434: \$? = $ac_status" >&5
1435 (exit $ac_status); }
1436
1437cat >conftest.$ac_ext <<_ACEOF
1438#line 1438 "configure"
d60d9f65 1439#include "confdefs.h"
c862e87b 1440
9255ee31
EZ
1441int
1442main ()
1443{
1444
1445 ;
1446 return 0;
1447}
1448_ACEOF
1449ac_clean_files_save=$ac_clean_files
1450ac_clean_files="$ac_clean_files a.out a.exe"
1451# Try to create an executable without -o first, disregard a.out.
1452# It will help us diagnose broken compilers, and finding out an intuition
1453# of exeext.
1454echo "$as_me:1454: checking for C compiler default output" >&5
1455echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
1456ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
1457if { (eval echo "$as_me:1457: \"$ac_link_default\"") >&5
1458 (eval $ac_link_default) 2>&5
1459 ac_status=$?
1460 echo "$as_me:1460: \$? = $ac_status" >&5
1461 (exit $ac_status); }; then
1462 # Find the output, starting from the most likely. This scheme is
1463# not robust to junk in `.', hence go to wildcards (a.*) only as a last
1464# resort.
1465for ac_file in `ls a.exe conftest.exe 2>/dev/null;
1466 ls a.out conftest 2>/dev/null;
1467 ls a.* conftest.* 2>/dev/null`; do
1468 case $ac_file in
1469 *.$ac_ext | *.o | *.obj | *.xcoff | *.tds | *.d | *.pdb ) ;;
1470 a.out ) # We found the default executable, but exeext='' is most
1471 # certainly right.
1472 break;;
1473 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1474 # FIXME: I believe we export ac_cv_exeext for Libtool --akim.
1475 export ac_cv_exeext
1476 break;;
1477 * ) break;;
1478 esac
1479done
1480else
1481 echo "$as_me: failed program was:" >&5
1482cat conftest.$ac_ext >&5
1483{ { echo "$as_me:1483: error: C compiler cannot create executables" >&5
1484echo "$as_me: error: C compiler cannot create executables" >&2;}
1485 { (exit 77); exit 77; }; }
1486fi
1487
1488ac_exeext=$ac_cv_exeext
1489echo "$as_me:1489: result: $ac_file" >&5
1490echo "${ECHO_T}$ac_file" >&6
1491
1492# Check the compiler produces executables we can run. If not, either
1493# the compiler is broken, or we cross compile.
1494echo "$as_me:1494: checking whether the C compiler works" >&5
1495echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
1496# FIXME: These cross compiler hacks should be removed for Autoconf 3.0
1497# If not cross compiling, check that we can run a simple program.
1498if test "$cross_compiling" != yes; then
1499 if { ac_try='./$ac_file'
1500 { (eval echo "$as_me:1500: \"$ac_try\"") >&5
1501 (eval $ac_try) 2>&5
1502 ac_status=$?
1503 echo "$as_me:1503: \$? = $ac_status" >&5
1504 (exit $ac_status); }; }; then
1505 cross_compiling=no
d60d9f65 1506 else
9255ee31
EZ
1507 if test "$cross_compiling" = maybe; then
1508 cross_compiling=yes
1509 else
1510 { { echo "$as_me:1510: error: cannot run C compiled programs.
1511If you meant to cross compile, use \`--host'." >&5
1512echo "$as_me: error: cannot run C compiled programs.
1513If you meant to cross compile, use \`--host'." >&2;}
1514 { (exit 1); exit 1; }; }
1515 fi
d60d9f65 1516 fi
d60d9f65 1517fi
9255ee31
EZ
1518echo "$as_me:1518: result: yes" >&5
1519echo "${ECHO_T}yes" >&6
1520
1521rm -f a.out a.exe conftest$ac_cv_exeext
1522ac_clean_files=$ac_clean_files_save
1523# Check the compiler produces executables we can run. If not, either
1524# the compiler is broken, or we cross compile.
1525echo "$as_me:1525: checking whether we are cross compiling" >&5
1526echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
1527echo "$as_me:1527: result: $cross_compiling" >&5
1528echo "${ECHO_T}$cross_compiling" >&6
1529
1530echo "$as_me:1530: checking for executable suffix" >&5
1531echo $ECHO_N "checking for executable suffix... $ECHO_C" >&6
1532if { (eval echo "$as_me:1532: \"$ac_link\"") >&5
1533 (eval $ac_link) 2>&5
1534 ac_status=$?
1535 echo "$as_me:1535: \$? = $ac_status" >&5
1536 (exit $ac_status); }; then
1537 # If both `conftest.exe' and `conftest' are `present' (well, observable)
1538# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
1539# work properly (i.e., refer to `conftest.exe'), while it won't with
1540# `rm'.
1541for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do
1542 case $ac_file in
1543 *.$ac_ext | *.o | *.obj | *.xcoff | *.tds | *.d | *.pdb ) ;;
1544 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1545 export ac_cv_exeext
1546 break;;
1547 * ) break;;
1548 esac
1549done
d60d9f65 1550else
9255ee31
EZ
1551 { { echo "$as_me:1551: error: cannot compute EXEEXT: cannot compile and link" >&5
1552echo "$as_me: error: cannot compute EXEEXT: cannot compile and link" >&2;}
1553 { (exit 1); exit 1; }; }
1554fi
1555
1556rm -f conftest$ac_cv_exeext
1557echo "$as_me:1557: result: $ac_cv_exeext" >&5
1558echo "${ECHO_T}$ac_cv_exeext" >&6
1559
1560rm -f conftest.$ac_ext
1561EXEEXT=$ac_cv_exeext
1562ac_exeext=$EXEEXT
1563echo "$as_me:1563: checking for object suffix" >&5
1564echo $ECHO_N "checking for object suffix... $ECHO_C" >&6
1565if test "${ac_cv_objext+set}" = set; then
1566 echo $ECHO_N "(cached) $ECHO_C" >&6
1567else
1568 cat >conftest.$ac_ext <<_ACEOF
1569#line 1569 "configure"
1570#include "confdefs.h"
d60d9f65 1571
9255ee31
EZ
1572int
1573main ()
1574{
d60d9f65 1575
9255ee31
EZ
1576 ;
1577 return 0;
1578}
1579_ACEOF
1580rm -f conftest.o conftest.obj
1581if { (eval echo "$as_me:1581: \"$ac_compile\"") >&5
1582 (eval $ac_compile) 2>&5
1583 ac_status=$?
1584 echo "$as_me:1584: \$? = $ac_status" >&5
1585 (exit $ac_status); }; then
1586 for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
1587 case $ac_file in
1588 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb ) ;;
1589 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
1590 break;;
1591 esac
1592done
d60d9f65 1593else
9255ee31
EZ
1594 echo "$as_me: failed program was:" >&5
1595cat conftest.$ac_ext >&5
1596{ { echo "$as_me:1596: error: cannot compute OBJEXT: cannot compile" >&5
1597echo "$as_me: error: cannot compute OBJEXT: cannot compile" >&2;}
1598 { (exit 1); exit 1; }; }
1599fi
1600
1601rm -f conftest.$ac_cv_objext conftest.$ac_ext
1602fi
1603echo "$as_me:1603: result: $ac_cv_objext" >&5
1604echo "${ECHO_T}$ac_cv_objext" >&6
1605OBJEXT=$ac_cv_objext
1606ac_objext=$OBJEXT
1607echo "$as_me:1607: checking whether we are using the GNU C compiler" >&5
1608echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
1609if test "${ac_cv_c_compiler_gnu+set}" = set; then
1610 echo $ECHO_N "(cached) $ECHO_C" >&6
1611else
1612 cat >conftest.$ac_ext <<_ACEOF
1613#line 1613 "configure"
1614#include "confdefs.h"
1615
1616int
1617main ()
1618{
1619#ifndef __GNUC__
1620 choke me
1621#endif
d60d9f65 1622
9255ee31
EZ
1623 ;
1624 return 0;
1625}
1626_ACEOF
1627rm -f conftest.$ac_objext
1628if { (eval echo "$as_me:1628: \"$ac_compile\"") >&5
1629 (eval $ac_compile) 2>&5
1630 ac_status=$?
1631 echo "$as_me:1631: \$? = $ac_status" >&5
1632 (exit $ac_status); } &&
1633 { ac_try='test -s conftest.$ac_objext'
1634 { (eval echo "$as_me:1634: \"$ac_try\"") >&5
1635 (eval $ac_try) 2>&5
1636 ac_status=$?
1637 echo "$as_me:1637: \$? = $ac_status" >&5
1638 (exit $ac_status); }; }; then
1639 ac_compiler_gnu=yes
1640else
1641 echo "$as_me: failed program was:" >&5
1642cat conftest.$ac_ext >&5
1643ac_compiler_gnu=no
1644fi
1645rm -f conftest.$ac_objext conftest.$ac_ext
1646ac_cv_c_compiler_gnu=$ac_compiler_gnu
1647
1648fi
1649echo "$as_me:1649: result: $ac_cv_c_compiler_gnu" >&5
1650echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
1651GCC=`test $ac_compiler_gnu = yes && echo yes`
1652ac_test_CFLAGS=${CFLAGS+set}
1653ac_save_CFLAGS=$CFLAGS
1654CFLAGS="-g"
1655echo "$as_me:1655: checking whether $CC accepts -g" >&5
1656echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
1657if test "${ac_cv_prog_cc_g+set}" = set; then
1658 echo $ECHO_N "(cached) $ECHO_C" >&6
d60d9f65 1659else
9255ee31
EZ
1660 cat >conftest.$ac_ext <<_ACEOF
1661#line 1661 "configure"
1662#include "confdefs.h"
1663
1664int
1665main ()
1666{
1667
1668 ;
1669 return 0;
1670}
1671_ACEOF
1672rm -f conftest.$ac_objext
1673if { (eval echo "$as_me:1673: \"$ac_compile\"") >&5
1674 (eval $ac_compile) 2>&5
1675 ac_status=$?
1676 echo "$as_me:1676: \$? = $ac_status" >&5
1677 (exit $ac_status); } &&
1678 { ac_try='test -s conftest.$ac_objext'
1679 { (eval echo "$as_me:1679: \"$ac_try\"") >&5
1680 (eval $ac_try) 2>&5
1681 ac_status=$?
1682 echo "$as_me:1682: \$? = $ac_status" >&5
1683 (exit $ac_status); }; }; then
d60d9f65
SS
1684 ac_cv_prog_cc_g=yes
1685else
9255ee31
EZ
1686 echo "$as_me: failed program was:" >&5
1687cat conftest.$ac_ext >&5
1688ac_cv_prog_cc_g=no
d60d9f65 1689fi
9255ee31 1690rm -f conftest.$ac_objext conftest.$ac_ext
d60d9f65 1691fi
9255ee31
EZ
1692echo "$as_me:1692: result: $ac_cv_prog_cc_g" >&5
1693echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
d60d9f65 1694if test "$ac_test_CFLAGS" = set; then
9255ee31 1695 CFLAGS=$ac_save_CFLAGS
d60d9f65
SS
1696elif test $ac_cv_prog_cc_g = yes; then
1697 if test "$GCC" = yes; then
1698 CFLAGS="-g -O2"
1699 else
1700 CFLAGS="-g"
1701 fi
1702else
1703 if test "$GCC" = yes; then
1704 CFLAGS="-O2"
1705 else
1706 CFLAGS=
1707 fi
1708fi
9255ee31
EZ
1709# Some people use a C++ compiler to compile C. Since we use `exit',
1710# in C++ we need to declare it. In case someone uses the same compiler
1711# for both compiling C and C++ we need to have the C++ compiler decide
1712# the declaration of exit, since it's the most demanding environment.
1713cat >conftest.$ac_ext <<_ACEOF
1714#ifndef __cplusplus
1715 choke me
1716#endif
1717_ACEOF
1718rm -f conftest.$ac_objext
1719if { (eval echo "$as_me:1719: \"$ac_compile\"") >&5
1720 (eval $ac_compile) 2>&5
1721 ac_status=$?
1722 echo "$as_me:1722: \$? = $ac_status" >&5
1723 (exit $ac_status); } &&
1724 { ac_try='test -s conftest.$ac_objext'
1725 { (eval echo "$as_me:1725: \"$ac_try\"") >&5
1726 (eval $ac_try) 2>&5
1727 ac_status=$?
1728 echo "$as_me:1728: \$? = $ac_status" >&5
1729 (exit $ac_status); }; }; then
1730 for ac_declaration in \
1731 ''\
1732 '#include <stdlib.h>' \
1733 'extern "C" void std::exit (int) throw (); using std::exit;' \
1734 'extern "C" void std::exit (int); using std::exit;' \
1735 'extern "C" void exit (int) throw ();' \
1736 'extern "C" void exit (int);' \
1737 'void exit (int);'
1738do
1739 cat >conftest.$ac_ext <<_ACEOF
1740#line 1740 "configure"
1741#include "confdefs.h"
1742#include <stdlib.h>
1743$ac_declaration
1744int
1745main ()
1746{
1747exit (42);
1748 ;
1749 return 0;
1750}
1751_ACEOF
1752rm -f conftest.$ac_objext
1753if { (eval echo "$as_me:1753: \"$ac_compile\"") >&5
1754 (eval $ac_compile) 2>&5
1755 ac_status=$?
1756 echo "$as_me:1756: \$? = $ac_status" >&5
1757 (exit $ac_status); } &&
1758 { ac_try='test -s conftest.$ac_objext'
1759 { (eval echo "$as_me:1759: \"$ac_try\"") >&5
1760 (eval $ac_try) 2>&5
1761 ac_status=$?
1762 echo "$as_me:1762: \$? = $ac_status" >&5
1763 (exit $ac_status); }; }; then
1764 :
1765else
1766 echo "$as_me: failed program was:" >&5
1767cat conftest.$ac_ext >&5
1768continue
1769fi
1770rm -f conftest.$ac_objext conftest.$ac_ext
1771 cat >conftest.$ac_ext <<_ACEOF
1772#line 1772 "configure"
1773#include "confdefs.h"
1774$ac_declaration
1775int
1776main ()
1777{
1778exit (42);
1779 ;
1780 return 0;
1781}
1782_ACEOF
1783rm -f conftest.$ac_objext
1784if { (eval echo "$as_me:1784: \"$ac_compile\"") >&5
1785 (eval $ac_compile) 2>&5
1786 ac_status=$?
1787 echo "$as_me:1787: \$? = $ac_status" >&5
1788 (exit $ac_status); } &&
1789 { ac_try='test -s conftest.$ac_objext'
1790 { (eval echo "$as_me:1790: \"$ac_try\"") >&5
1791 (eval $ac_try) 2>&5
1792 ac_status=$?
1793 echo "$as_me:1793: \$? = $ac_status" >&5
1794 (exit $ac_status); }; }; then
1795 break
1796else
1797 echo "$as_me: failed program was:" >&5
1798cat conftest.$ac_ext >&5
1799fi
1800rm -f conftest.$ac_objext conftest.$ac_ext
1801done
1802rm -f conftest*
1803if test -n "$ac_declaration"; then
1804 echo '#ifdef __cplusplus' >>confdefs.h
1805 echo $ac_declaration >>confdefs.h
1806 echo '#endif' >>confdefs.h
1807fi
d60d9f65 1808
9255ee31
EZ
1809else
1810 echo "$as_me: failed program was:" >&5
1811cat conftest.$ac_ext >&5
1812fi
1813rm -f conftest.$ac_objext conftest.$ac_ext
1814ac_ext=c
1815ac_cpp='$CPP $CPPFLAGS'
1816ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1817ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1818ac_compiler_gnu=$ac_cv_c_compiler_gnu
1819
1820ac_ext=c
1821ac_cpp='$CPP $CPPFLAGS'
1822ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1823ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1824ac_compiler_gnu=$ac_cv_c_compiler_gnu
1825echo "$as_me:1825: checking how to run the C preprocessor" >&5
1826echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
d60d9f65
SS
1827# On Suns, sometimes $CPP names a directory.
1828if test -n "$CPP" && test -d "$CPP"; then
1829 CPP=
1830fi
1831if test -z "$CPP"; then
9255ee31
EZ
1832 if test "${ac_cv_prog_CPP+set}" = set; then
1833 echo $ECHO_N "(cached) $ECHO_C" >&6
d60d9f65 1834else
9255ee31
EZ
1835 # Double quotes because CPP needs to be expanded
1836 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
1837 do
1838 ac_preproc_ok=false
1839for ac_c_preproc_warn_flag in '' yes
1840do
1841 # Use a header file that comes with gcc, so configuring glibc
1842 # with a fresh cross-compiler works.
d60d9f65 1843 # On the NeXT, cc -E runs the code through the compiler's parser,
9255ee31
EZ
1844 # not just through cpp. "Syntax error" is here to catch this case.
1845 cat >conftest.$ac_ext <<_ACEOF
1846#line 1846 "configure"
d60d9f65
SS
1847#include "confdefs.h"
1848#include <assert.h>
9255ee31
EZ
1849 Syntax error
1850_ACEOF
1851if { (eval echo "$as_me:1851: \"$ac_cpp conftest.$ac_ext\"") >&5
1852 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
1853 ac_status=$?
1854 egrep -v '^ *\+' conftest.er1 >conftest.err
1855 rm -f conftest.er1
1856 cat conftest.err >&5
1857 echo "$as_me:1857: \$? = $ac_status" >&5
1858 (exit $ac_status); } >/dev/null; then
1859 if test -s conftest.err; then
1860 ac_cpp_err=$ac_c_preproc_warn_flag
1861 else
1862 ac_cpp_err=
1863 fi
1864else
1865 ac_cpp_err=yes
1866fi
1867if test -z "$ac_cpp_err"; then
d60d9f65
SS
1868 :
1869else
9255ee31 1870 echo "$as_me: failed program was:" >&5
d60d9f65 1871 cat conftest.$ac_ext >&5
9255ee31
EZ
1872 # Broken: fails on valid input.
1873continue
1874fi
1875rm -f conftest.err conftest.$ac_ext
1876
1877 # OK, works on sane cases. Now check whether non-existent headers
1878 # can be detected and how.
1879 cat >conftest.$ac_ext <<_ACEOF
1880#line 1880 "configure"
d60d9f65 1881#include "confdefs.h"
9255ee31
EZ
1882#include <ac_nonexistent.h>
1883_ACEOF
1884if { (eval echo "$as_me:1884: \"$ac_cpp conftest.$ac_ext\"") >&5
1885 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
1886 ac_status=$?
1887 egrep -v '^ *\+' conftest.er1 >conftest.err
1888 rm -f conftest.er1
1889 cat conftest.err >&5
1890 echo "$as_me:1890: \$? = $ac_status" >&5
1891 (exit $ac_status); } >/dev/null; then
1892 if test -s conftest.err; then
1893 ac_cpp_err=$ac_c_preproc_warn_flag
1894 else
1895 ac_cpp_err=
1896 fi
1897else
1898 ac_cpp_err=yes
1899fi
1900if test -z "$ac_cpp_err"; then
1901 # Broken: success on invalid input.
1902continue
d60d9f65 1903else
9255ee31 1904 echo "$as_me: failed program was:" >&5
d60d9f65 1905 cat conftest.$ac_ext >&5
9255ee31
EZ
1906 # Passes both tests.
1907ac_preproc_ok=:
1908break
1909fi
1910rm -f conftest.err conftest.$ac_ext
1911
1912done
1913# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
1914rm -f conftest.err conftest.$ac_ext
1915if $ac_preproc_ok; then
1916 break
1917fi
1918
1919 done
1920 ac_cv_prog_CPP=$CPP
1921
1922fi
1923 CPP=$ac_cv_prog_CPP
1924else
1925 ac_cv_prog_CPP=$CPP
1926fi
1927echo "$as_me:1927: result: $CPP" >&5
1928echo "${ECHO_T}$CPP" >&6
1929ac_preproc_ok=false
1930for ac_c_preproc_warn_flag in '' yes
1931do
1932 # Use a header file that comes with gcc, so configuring glibc
1933 # with a fresh cross-compiler works.
1934 # On the NeXT, cc -E runs the code through the compiler's parser,
1935 # not just through cpp. "Syntax error" is here to catch this case.
1936 cat >conftest.$ac_ext <<_ACEOF
1937#line 1937 "configure"
d60d9f65
SS
1938#include "confdefs.h"
1939#include <assert.h>
9255ee31
EZ
1940 Syntax error
1941_ACEOF
1942if { (eval echo "$as_me:1942: \"$ac_cpp conftest.$ac_ext\"") >&5
1943 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
1944 ac_status=$?
1945 egrep -v '^ *\+' conftest.er1 >conftest.err
1946 rm -f conftest.er1
1947 cat conftest.err >&5
1948 echo "$as_me:1948: \$? = $ac_status" >&5
1949 (exit $ac_status); } >/dev/null; then
1950 if test -s conftest.err; then
1951 ac_cpp_err=$ac_c_preproc_warn_flag
1952 else
1953 ac_cpp_err=
1954 fi
1955else
1956 ac_cpp_err=yes
1957fi
1958if test -z "$ac_cpp_err"; then
d60d9f65
SS
1959 :
1960else
9255ee31 1961 echo "$as_me: failed program was:" >&5
d60d9f65 1962 cat conftest.$ac_ext >&5
9255ee31
EZ
1963 # Broken: fails on valid input.
1964continue
d60d9f65 1965fi
9255ee31
EZ
1966rm -f conftest.err conftest.$ac_ext
1967
1968 # OK, works on sane cases. Now check whether non-existent headers
1969 # can be detected and how.
1970 cat >conftest.$ac_ext <<_ACEOF
1971#line 1971 "configure"
1972#include "confdefs.h"
1973#include <ac_nonexistent.h>
1974_ACEOF
1975if { (eval echo "$as_me:1975: \"$ac_cpp conftest.$ac_ext\"") >&5
1976 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
1977 ac_status=$?
1978 egrep -v '^ *\+' conftest.er1 >conftest.err
1979 rm -f conftest.er1
1980 cat conftest.err >&5
1981 echo "$as_me:1981: \$? = $ac_status" >&5
1982 (exit $ac_status); } >/dev/null; then
1983 if test -s conftest.err; then
1984 ac_cpp_err=$ac_c_preproc_warn_flag
1985 else
1986 ac_cpp_err=
1987 fi
1988else
1989 ac_cpp_err=yes
d60d9f65 1990fi
9255ee31
EZ
1991if test -z "$ac_cpp_err"; then
1992 # Broken: success on invalid input.
1993continue
1994else
1995 echo "$as_me: failed program was:" >&5
1996 cat conftest.$ac_ext >&5
1997 # Passes both tests.
1998ac_preproc_ok=:
1999break
d60d9f65 2000fi
9255ee31
EZ
2001rm -f conftest.err conftest.$ac_ext
2002
2003done
2004# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2005rm -f conftest.err conftest.$ac_ext
2006if $ac_preproc_ok; then
2007 :
d60d9f65 2008else
9255ee31
EZ
2009 { { echo "$as_me:2009: error: C preprocessor \"$CPP\" fails sanity check" >&5
2010echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;}
2011 { (exit 1); exit 1; }; }
d60d9f65 2012fi
d60d9f65 2013
9255ee31
EZ
2014ac_ext=c
2015ac_cpp='$CPP $CPPFLAGS'
2016ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2017ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2018ac_compiler_gnu=$ac_cv_c_compiler_gnu
2019
2020echo "$as_me:2020: checking for minix/config.h" >&5
2021echo $ECHO_N "checking for minix/config.h... $ECHO_C" >&6
2022if test "${ac_cv_header_minix_config_h+set}" = set; then
2023 echo $ECHO_N "(cached) $ECHO_C" >&6
d60d9f65 2024else
9255ee31
EZ
2025 cat >conftest.$ac_ext <<_ACEOF
2026#line 2026 "configure"
d60d9f65
SS
2027#include "confdefs.h"
2028#include <minix/config.h>
9255ee31
EZ
2029_ACEOF
2030if { (eval echo "$as_me:2030: \"$ac_cpp conftest.$ac_ext\"") >&5
2031 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2032 ac_status=$?
2033 egrep -v '^ *\+' conftest.er1 >conftest.err
2034 rm -f conftest.er1
2035 cat conftest.err >&5
2036 echo "$as_me:2036: \$? = $ac_status" >&5
2037 (exit $ac_status); } >/dev/null; then
2038 if test -s conftest.err; then
2039 ac_cpp_err=$ac_c_preproc_warn_flag
2040 else
2041 ac_cpp_err=
2042 fi
d60d9f65 2043else
9255ee31
EZ
2044 ac_cpp_err=yes
2045fi
2046if test -z "$ac_cpp_err"; then
2047 ac_cv_header_minix_config_h=yes
2048else
2049 echo "$as_me: failed program was:" >&5
d60d9f65 2050 cat conftest.$ac_ext >&5
9255ee31 2051 ac_cv_header_minix_config_h=no
d60d9f65 2052fi
9255ee31 2053rm -f conftest.err conftest.$ac_ext
d60d9f65 2054fi
9255ee31
EZ
2055echo "$as_me:2055: result: $ac_cv_header_minix_config_h" >&5
2056echo "${ECHO_T}$ac_cv_header_minix_config_h" >&6
2057if test $ac_cv_header_minix_config_h = yes; then
d60d9f65
SS
2058 MINIX=yes
2059else
9255ee31 2060 MINIX=
d60d9f65
SS
2061fi
2062
2063if test "$MINIX" = yes; then
9255ee31
EZ
2064
2065cat >>confdefs.h <<\EOF
d60d9f65
SS
2066#define _POSIX_SOURCE 1
2067EOF
2068
9255ee31 2069cat >>confdefs.h <<\EOF
d60d9f65
SS
2070#define _POSIX_1_SOURCE 2
2071EOF
2072
9255ee31 2073cat >>confdefs.h <<\EOF
d60d9f65
SS
2074#define _MINIX 1
2075EOF
2076
2077fi
2078
d60d9f65
SS
2079if test "x$cross_compiling" = "xyes"; then
2080 case "${host}" in
2081 *-cygwin*)
2082 cross_cache=${srcdir}/cross-build/cygwin.cache
2083 if test -r "${cross_cache}"; then
2084 echo "loading cross-build cache file ${cross_cache}"
2085 . ${cross_cache}
2086 fi
2087 LOCAL_CFLAGS="$LOCAL_CFLAGS -I${srcdir}/../libtermcap"
2088 unset cross_cache
2089 ;;
2090 *) echo "configure: cross-compiling for a non-cygwin target is not supported" >&2
2091 ;;
2092 esac
2093fi
9255ee31 2094
d60d9f65
SS
2095if test "x$cross_compiling" = "xyes"; then
2096 CROSS_COMPILING_FLAG=-DCROSS_COMPILING
2097else
2098 CROSS_COMPILING_FLAG=
2099fi
2100
d60d9f65
SS
2101if test -z "$CC_FOR_BUILD"; then
2102 if test "x$cross_compiling" = "xno"; then
2103 CC_FOR_BUILD='$(CC)'
2104 else
2105 CC_FOR_BUILD=gcc
2106 fi
2107fi
2108
d60d9f65
SS
2109# If we're using gcc and the user hasn't specified CFLAGS, add -O to CFLAGS.
2110test -n "$GCC" && test -n "$auto_cflags" && CFLAGS="$CFLAGS -O"
2111
9255ee31
EZ
2112if test $ac_cv_c_compiler_gnu = yes; then
2113 echo "$as_me:2113: checking whether $CC needs -traditional" >&5
2114echo $ECHO_N "checking whether $CC needs -traditional... $ECHO_C" >&6
2115if test "${ac_cv_prog_gcc_traditional+set}" = set; then
2116 echo $ECHO_N "(cached) $ECHO_C" >&6
d60d9f65
SS
2117else
2118 ac_pattern="Autoconf.*'x'"
9255ee31
EZ
2119 cat >conftest.$ac_ext <<_ACEOF
2120#line 2120 "configure"
d60d9f65
SS
2121#include "confdefs.h"
2122#include <sgtty.h>
2123Autoconf TIOCGETP
9255ee31 2124_ACEOF
d60d9f65
SS
2125if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2126 egrep "$ac_pattern" >/dev/null 2>&1; then
d60d9f65
SS
2127 ac_cv_prog_gcc_traditional=yes
2128else
d60d9f65
SS
2129 ac_cv_prog_gcc_traditional=no
2130fi
2131rm -f conftest*
2132
d60d9f65 2133 if test $ac_cv_prog_gcc_traditional = no; then
9255ee31
EZ
2134 cat >conftest.$ac_ext <<_ACEOF
2135#line 2135 "configure"
d60d9f65
SS
2136#include "confdefs.h"
2137#include <termio.h>
2138Autoconf TCGETA
9255ee31 2139_ACEOF
d60d9f65
SS
2140if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2141 egrep "$ac_pattern" >/dev/null 2>&1; then
d60d9f65
SS
2142 ac_cv_prog_gcc_traditional=yes
2143fi
2144rm -f conftest*
2145
2146 fi
2147fi
9255ee31
EZ
2148echo "$as_me:2148: result: $ac_cv_prog_gcc_traditional" >&5
2149echo "${ECHO_T}$ac_cv_prog_gcc_traditional" >&6
d60d9f65
SS
2150 if test $ac_cv_prog_gcc_traditional = yes; then
2151 CC="$CC -traditional"
2152 fi
2153fi
2154
2155# Find a good install program. We prefer a C program (faster),
2156# so one script is as good as another. But avoid the broken or
2157# incompatible versions:
2158# SysV /etc/install, /usr/sbin/install
2159# SunOS /usr/etc/install
2160# IRIX /sbin/install
2161# AIX /bin/install
9255ee31 2162# AmigaOS /C/install, which installs bootblocks on floppy discs
d60d9f65
SS
2163# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
2164# AFS /usr/afsws/bin/install, which mishandles nonexistent args
2165# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
2166# ./install, which can be erroneously created by make from ./install.sh.
9255ee31
EZ
2167echo "$as_me:2167: checking for a BSD compatible install" >&5
2168echo $ECHO_N "checking for a BSD compatible install... $ECHO_C" >&6
d60d9f65 2169if test -z "$INSTALL"; then
9255ee31
EZ
2170if test "${ac_cv_path_install+set}" = set; then
2171 echo $ECHO_N "(cached) $ECHO_C" >&6
d60d9f65 2172else
9255ee31 2173 ac_save_IFS=$IFS; IFS=$ac_path_separator
d60d9f65 2174 for ac_dir in $PATH; do
9255ee31 2175 IFS=$ac_save_IFS
d60d9f65 2176 # Account for people who put trailing slashes in PATH elements.
9255ee31
EZ
2177 case $ac_dir/ in
2178 / | ./ | .// | /cC/* \
2179 | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* \
2180 | /usr/ucb/* ) ;;
d60d9f65
SS
2181 *)
2182 # OSF1 and SCO ODT 3.0 have their own names for install.
2183 # Don't use installbsd from OSF since it installs stuff as root
2184 # by default.
2185 for ac_prog in ginstall scoinst install; do
9255ee31 2186 if $as_executable_p "$ac_dir/$ac_prog"; then
d60d9f65 2187 if test $ac_prog = install &&
9255ee31 2188 grep dspmsg "$ac_dir/$ac_prog" >/dev/null 2>&1; then
d60d9f65
SS
2189 # AIX install. It has an incompatible calling convention.
2190 :
9255ee31
EZ
2191 elif test $ac_prog = install &&
2192 grep pwplus "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2193 # program-specific install script used by HP pwplus--don't use.
2194 :
d60d9f65
SS
2195 else
2196 ac_cv_path_install="$ac_dir/$ac_prog -c"
2197 break 2
2198 fi
2199 fi
2200 done
2201 ;;
2202 esac
2203 done
d60d9f65
SS
2204
2205fi
2206 if test "${ac_cv_path_install+set}" = set; then
9255ee31 2207 INSTALL=$ac_cv_path_install
d60d9f65
SS
2208 else
2209 # As a last resort, use the slow shell script. We don't cache a
2210 # path for INSTALL within a source directory, because that will
2211 # break other packages using the cache if that directory is
2212 # removed, or if the path is relative.
9255ee31 2213 INSTALL=$ac_install_sh
d60d9f65
SS
2214 fi
2215fi
9255ee31
EZ
2216echo "$as_me:2216: result: $INSTALL" >&5
2217echo "${ECHO_T}$INSTALL" >&6
d60d9f65
SS
2218
2219# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
2220# It thinks the first close brace ends the variable substitution.
2221test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
2222
9255ee31 2223test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
c862e87b 2224
d60d9f65
SS
2225test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
2226
c862e87b
JM
2227# Extract the first word of "ar", so it can be a program name with args.
2228set dummy ar; ac_word=$2
9255ee31
EZ
2229echo "$as_me:2229: checking for $ac_word" >&5
2230echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2231if test "${ac_cv_prog_AR+set}" = set; then
2232 echo $ECHO_N "(cached) $ECHO_C" >&6
c862e87b
JM
2233else
2234 if test -n "$AR"; then
2235 ac_cv_prog_AR="$AR" # Let the user override the test.
2236else
9255ee31
EZ
2237 ac_save_IFS=$IFS; IFS=$ac_path_separator
2238ac_dummy="$PATH"
2239for ac_dir in $ac_dummy; do
2240 IFS=$ac_save_IFS
2241 test -z "$ac_dir" && ac_dir=.
2242 $as_executable_p "$ac_dir/$ac_word" || continue
2243ac_cv_prog_AR=""
2244echo "$as_me:2244: found $ac_dir/$ac_word" >&5
2245break
2246done
2247
2248 test -z "$ac_cv_prog_AR" && ac_cv_prog_AR="ar"
2249fi
2250fi
2251AR=$ac_cv_prog_AR
2252if test -n "$AR"; then
2253 echo "$as_me:2253: result: $AR" >&5
2254echo "${ECHO_T}$AR" >&6
2255else
2256 echo "$as_me:2256: result: no" >&5
2257echo "${ECHO_T}no" >&6
2258fi
2259
2260test -n "$ARFLAGS" || ARFLAGS="cr"
2261if test -n "$ac_tool_prefix"; then
2262 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
2263set dummy ${ac_tool_prefix}ranlib; ac_word=$2
2264echo "$as_me:2264: checking for $ac_word" >&5
2265echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2266if test "${ac_cv_prog_RANLIB+set}" = set; then
2267 echo $ECHO_N "(cached) $ECHO_C" >&6
2268else
2269 if test -n "$RANLIB"; then
2270 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
2271else
2272 ac_save_IFS=$IFS; IFS=$ac_path_separator
2273ac_dummy="$PATH"
2274for ac_dir in $ac_dummy; do
2275 IFS=$ac_save_IFS
2276 test -z "$ac_dir" && ac_dir=.
2277 $as_executable_p "$ac_dir/$ac_word" || continue
2278ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
2279echo "$as_me:2279: found $ac_dir/$ac_word" >&5
2280break
2281done
2282
2283fi
2284fi
2285RANLIB=$ac_cv_prog_RANLIB
2286if test -n "$RANLIB"; then
2287 echo "$as_me:2287: result: $RANLIB" >&5
2288echo "${ECHO_T}$RANLIB" >&6
2289else
2290 echo "$as_me:2290: result: no" >&5
2291echo "${ECHO_T}no" >&6
2292fi
2293
2294fi
2295if test -z "$ac_cv_prog_RANLIB"; then
2296 ac_ct_RANLIB=$RANLIB
2297 # Extract the first word of "ranlib", so it can be a program name with args.
2298set dummy ranlib; ac_word=$2
2299echo "$as_me:2299: checking for $ac_word" >&5
2300echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2301if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
2302 echo $ECHO_N "(cached) $ECHO_C" >&6
2303else
2304 if test -n "$ac_ct_RANLIB"; then
2305 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
2306else
2307 ac_save_IFS=$IFS; IFS=$ac_path_separator
2308ac_dummy="$PATH"
2309for ac_dir in $ac_dummy; do
2310 IFS=$ac_save_IFS
2311 test -z "$ac_dir" && ac_dir=.
2312 $as_executable_p "$ac_dir/$ac_word" || continue
2313ac_cv_prog_ac_ct_RANLIB="ranlib"
2314echo "$as_me:2314: found $ac_dir/$ac_word" >&5
2315break
2316done
2317
2318 test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
2319fi
2320fi
2321ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
2322if test -n "$ac_ct_RANLIB"; then
2323 echo "$as_me:2323: result: $ac_ct_RANLIB" >&5
2324echo "${ECHO_T}$ac_ct_RANLIB" >&6
2325else
2326 echo "$as_me:2326: result: no" >&5
2327echo "${ECHO_T}no" >&6
2328fi
2329
2330 RANLIB=$ac_ct_RANLIB
2331else
2332 RANLIB="$ac_cv_prog_RANLIB"
2333fi
2334
2335MAKE_SHELL=/bin/sh
2336
2337echo "$as_me:2337: checking for $CC option to accept ANSI C" >&5
2338echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
2339if test "${ac_cv_prog_cc_stdc+set}" = set; then
2340 echo $ECHO_N "(cached) $ECHO_C" >&6
2341else
2342 ac_cv_prog_cc_stdc=no
2343ac_save_CC=$CC
2344cat >conftest.$ac_ext <<_ACEOF
2345#line 2345 "configure"
2346#include "confdefs.h"
2347#include <stdarg.h>
2348#include <stdio.h>
2349#include <sys/types.h>
2350#include <sys/stat.h>
2351/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
2352struct buf { int x; };
2353FILE * (*rcsopen) (struct buf *, struct stat *, int);
2354static char *e (p, i)
2355 char **p;
2356 int i;
2357{
2358 return p[i];
2359}
2360static char *f (char * (*g) (char **, int), char **p, ...)
2361{
2362 char *s;
2363 va_list v;
2364 va_start (v,p);
2365 s = g (p, va_arg (v,int));
2366 va_end (v);
2367 return s;
2368}
2369int test (int i, double x);
2370struct s1 {int (*f) (int a);};
2371struct s2 {int (*f) (double a);};
2372int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
2373int argc;
2374char **argv;
2375int
2376main ()
2377{
2378return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
2379 ;
2380 return 0;
2381}
2382_ACEOF
2383# Don't try gcc -ansi; that turns off useful extensions and
2384# breaks some systems' header files.
2385# AIX -qlanglvl=ansi
2386# Ultrix and OSF/1 -std1
2387# HP-UX 10.20 and later -Ae
2388# HP-UX older versions -Aa -D_HPUX_SOURCE
2389# SVR4 -Xc -D__EXTENSIONS__
2390for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
2391do
2392 CC="$ac_save_CC $ac_arg"
2393 rm -f conftest.$ac_objext
2394if { (eval echo "$as_me:2394: \"$ac_compile\"") >&5
2395 (eval $ac_compile) 2>&5
2396 ac_status=$?
2397 echo "$as_me:2397: \$? = $ac_status" >&5
2398 (exit $ac_status); } &&
2399 { ac_try='test -s conftest.$ac_objext'
2400 { (eval echo "$as_me:2400: \"$ac_try\"") >&5
2401 (eval $ac_try) 2>&5
2402 ac_status=$?
2403 echo "$as_me:2403: \$? = $ac_status" >&5
2404 (exit $ac_status); }; }; then
2405 ac_cv_prog_cc_stdc=$ac_arg
2406break
2407else
2408 echo "$as_me: failed program was:" >&5
2409cat conftest.$ac_ext >&5
2410fi
2411rm -f conftest.$ac_objext
2412done
2413rm -f conftest.$ac_ext conftest.$ac_objext
2414CC=$ac_save_CC
2415
2416fi
2417
2418case "x$ac_cv_prog_cc_stdc" in
2419 x|xno)
2420 echo "$as_me:2420: result: none needed" >&5
2421echo "${ECHO_T}none needed" >&6 ;;
2422 *)
2423 echo "$as_me:2423: result: $ac_cv_prog_cc_stdc" >&5
2424echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
2425 CC="$CC $ac_cv_prog_cc_stdc" ;;
2426esac
2427
2428echo "$as_me:2428: checking for an ANSI C-conforming const" >&5
2429echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
2430if test "${ac_cv_c_const+set}" = set; then
2431 echo $ECHO_N "(cached) $ECHO_C" >&6
2432else
2433 cat >conftest.$ac_ext <<_ACEOF
2434#line 2434 "configure"
2435#include "confdefs.h"
2436
2437int
2438main ()
2439{
2440/* FIXME: Include the comments suggested by Paul. */
2441#ifndef __cplusplus
2442 /* Ultrix mips cc rejects this. */
2443 typedef int charset[2];
2444 const charset x;
2445 /* SunOS 4.1.1 cc rejects this. */
2446 char const *const *ccp;
2447 char **p;
2448 /* NEC SVR4.0.2 mips cc rejects this. */
2449 struct point {int x, y;};
2450 static struct point const zero = {0,0};
2451 /* AIX XL C 1.02.0.0 rejects this.
2452 It does not let you subtract one const X* pointer from another in
2453 an arm of an if-expression whose if-part is not a constant
2454 expression */
2455 const char *g = "string";
2456 ccp = &g + (g ? g-g : 0);
2457 /* HPUX 7.0 cc rejects these. */
2458 ++ccp;
2459 p = (char**) ccp;
2460 ccp = (char const *const *) p;
2461 { /* SCO 3.2v4 cc rejects this. */
2462 char *t;
2463 char const *s = 0 ? (char *) 0 : (char const *) 0;
2464
2465 *t++ = 0;
2466 }
2467 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
2468 int x[] = {25, 17};
2469 const int *foo = &x[0];
2470 ++foo;
2471 }
2472 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
2473 typedef const int *iptr;
2474 iptr p = 0;
2475 ++p;
2476 }
2477 { /* AIX XL C 1.02.0.0 rejects this saying
2478 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
2479 struct s { int j; const int *ap[3]; };
2480 struct s *b; b->j = 5;
2481 }
2482 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
2483 const int foo = 10;
2484 }
2485#endif
2486
2487 ;
2488 return 0;
2489}
2490_ACEOF
2491rm -f conftest.$ac_objext
2492if { (eval echo "$as_me:2492: \"$ac_compile\"") >&5
2493 (eval $ac_compile) 2>&5
2494 ac_status=$?
2495 echo "$as_me:2495: \$? = $ac_status" >&5
2496 (exit $ac_status); } &&
2497 { ac_try='test -s conftest.$ac_objext'
2498 { (eval echo "$as_me:2498: \"$ac_try\"") >&5
2499 (eval $ac_try) 2>&5
2500 ac_status=$?
2501 echo "$as_me:2501: \$? = $ac_status" >&5
2502 (exit $ac_status); }; }; then
2503 ac_cv_c_const=yes
2504else
2505 echo "$as_me: failed program was:" >&5
2506cat conftest.$ac_ext >&5
2507ac_cv_c_const=no
2508fi
2509rm -f conftest.$ac_objext conftest.$ac_ext
2510fi
2511echo "$as_me:2511: result: $ac_cv_c_const" >&5
2512echo "${ECHO_T}$ac_cv_c_const" >&6
2513if test $ac_cv_c_const = no; then
2514
2515cat >>confdefs.h <<\EOF
2516#define const
2517EOF
2518
2519fi
2520
2521echo "$as_me:2521: checking for function prototypes" >&5
2522echo $ECHO_N "checking for function prototypes... $ECHO_C" >&6
2523if test "$ac_cv_prog_cc_stdc" != no; then
2524 echo "$as_me:2524: result: yes" >&5
2525echo "${ECHO_T}yes" >&6
2526
2527cat >>confdefs.h <<\EOF
2528#define PROTOTYPES 1
2529EOF
2530
2531else
2532 echo "$as_me:2532: result: no" >&5
2533echo "${ECHO_T}no" >&6
2534fi
2535
2536echo "$as_me:2536: checking for ANSI C header files" >&5
2537echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
2538if test "${ac_cv_header_stdc+set}" = set; then
2539 echo $ECHO_N "(cached) $ECHO_C" >&6
2540else
2541 cat >conftest.$ac_ext <<_ACEOF
2542#line 2542 "configure"
2543#include "confdefs.h"
2544#include <stdlib.h>
2545#include <stdarg.h>
2546#include <string.h>
2547#include <float.h>
2548
2549_ACEOF
2550if { (eval echo "$as_me:2550: \"$ac_cpp conftest.$ac_ext\"") >&5
2551 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2552 ac_status=$?
2553 egrep -v '^ *\+' conftest.er1 >conftest.err
2554 rm -f conftest.er1
2555 cat conftest.err >&5
2556 echo "$as_me:2556: \$? = $ac_status" >&5
2557 (exit $ac_status); } >/dev/null; then
2558 if test -s conftest.err; then
2559 ac_cpp_err=$ac_c_preproc_warn_flag
2560 else
2561 ac_cpp_err=
2562 fi
2563else
2564 ac_cpp_err=yes
2565fi
2566if test -z "$ac_cpp_err"; then
2567 ac_cv_header_stdc=yes
2568else
2569 echo "$as_me: failed program was:" >&5
2570 cat conftest.$ac_ext >&5
2571 ac_cv_header_stdc=no
2572fi
2573rm -f conftest.err conftest.$ac_ext
2574
2575if test $ac_cv_header_stdc = yes; then
2576 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
2577 cat >conftest.$ac_ext <<_ACEOF
2578#line 2578 "configure"
2579#include "confdefs.h"
2580#include <string.h>
2581
2582_ACEOF
2583if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2584 egrep "memchr" >/dev/null 2>&1; then
2585 :
2586else
2587 ac_cv_header_stdc=no
2588fi
2589rm -f conftest*
2590
2591fi
2592
2593if test $ac_cv_header_stdc = yes; then
2594 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
2595 cat >conftest.$ac_ext <<_ACEOF
2596#line 2596 "configure"
2597#include "confdefs.h"
2598#include <stdlib.h>
2599
2600_ACEOF
2601if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2602 egrep "free" >/dev/null 2>&1; then
2603 :
2604else
2605 ac_cv_header_stdc=no
2606fi
2607rm -f conftest*
2608
2609fi
2610
2611if test $ac_cv_header_stdc = yes; then
2612 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
2613 if test "$cross_compiling" = yes; then
2614 :
2615else
2616 cat >conftest.$ac_ext <<_ACEOF
2617#line 2617 "configure"
2618#include "confdefs.h"
2619#include <ctype.h>
2620#if ((' ' & 0x0FF) == 0x020)
2621# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
2622# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
2623#else
2624# define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
2625 || ('j' <= (c) && (c) <= 'r') \
2626 || ('s' <= (c) && (c) <= 'z'))
2627# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
2628#endif
2629
2630#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
2631int
2632main ()
2633{
2634 int i;
2635 for (i = 0; i < 256; i++)
2636 if (XOR (islower (i), ISLOWER (i))
2637 || toupper (i) != TOUPPER (i))
2638 exit(2);
2639 exit (0);
2640}
2641_ACEOF
2642rm -f conftest$ac_exeext
2643if { (eval echo "$as_me:2643: \"$ac_link\"") >&5
2644 (eval $ac_link) 2>&5
2645 ac_status=$?
2646 echo "$as_me:2646: \$? = $ac_status" >&5
2647 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
2648 { (eval echo "$as_me:2648: \"$ac_try\"") >&5
2649 (eval $ac_try) 2>&5
2650 ac_status=$?
2651 echo "$as_me:2651: \$? = $ac_status" >&5
2652 (exit $ac_status); }; }; then
2653 :
2654else
2655 echo "$as_me: program exited with status $ac_status" >&5
2656echo "$as_me: failed program was:" >&5
2657cat conftest.$ac_ext >&5
2658ac_cv_header_stdc=no
2659fi
2660rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
2661fi
2662fi
2663fi
2664echo "$as_me:2664: result: $ac_cv_header_stdc" >&5
2665echo "${ECHO_T}$ac_cv_header_stdc" >&6
2666if test $ac_cv_header_stdc = yes; then
2667
2668cat >>confdefs.h <<\EOF
2669#define STDC_HEADERS 1
2670EOF
2671
2672fi
2673
2674# On IRIX 5.3, sys/types and inttypes.h are conflicting.
2675
2676for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
2677 inttypes.h stdint.h unistd.h
2678do
2679as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
2680echo "$as_me:2680: checking for $ac_header" >&5
2681echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
2682if eval "test \"\${$as_ac_Header+set}\" = set"; then
2683 echo $ECHO_N "(cached) $ECHO_C" >&6
2684else
2685 cat >conftest.$ac_ext <<_ACEOF
2686#line 2686 "configure"
2687#include "confdefs.h"
2688$ac_includes_default
2689#include <$ac_header>
2690_ACEOF
2691rm -f conftest.$ac_objext
2692if { (eval echo "$as_me:2692: \"$ac_compile\"") >&5
2693 (eval $ac_compile) 2>&5
2694 ac_status=$?
2695 echo "$as_me:2695: \$? = $ac_status" >&5
2696 (exit $ac_status); } &&
2697 { ac_try='test -s conftest.$ac_objext'
2698 { (eval echo "$as_me:2698: \"$ac_try\"") >&5
2699 (eval $ac_try) 2>&5
2700 ac_status=$?
2701 echo "$as_me:2701: \$? = $ac_status" >&5
2702 (exit $ac_status); }; }; then
2703 eval "$as_ac_Header=yes"
2704else
2705 echo "$as_me: failed program was:" >&5
2706cat conftest.$ac_ext >&5
2707eval "$as_ac_Header=no"
c862e87b 2708fi
9255ee31 2709rm -f conftest.$ac_objext conftest.$ac_ext
c862e87b 2710fi
9255ee31
EZ
2711echo "$as_me:2711: result: `eval echo '${'$as_ac_Header'}'`" >&5
2712echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
2713if test `eval echo '${'$as_ac_Header'}'` = yes; then
2714 cat >>confdefs.h <<EOF
2715#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
2716EOF
2717
c862e87b 2718fi
9255ee31 2719done
c862e87b 2720
9255ee31
EZ
2721echo "$as_me:2721: checking whether char is unsigned" >&5
2722echo $ECHO_N "checking whether char is unsigned... $ECHO_C" >&6
2723if test "${ac_cv_c_char_unsigned+set}" = set; then
2724 echo $ECHO_N "(cached) $ECHO_C" >&6
d60d9f65 2725else
9255ee31
EZ
2726 cat >conftest.$ac_ext <<_ACEOF
2727#line 2727 "configure"
2728#include "confdefs.h"
2729$ac_includes_default
2730int
2731main ()
2732{
2733int _array_ [1 - 2 * !(((char) -1) < 0)]
2734 ;
2735 return 0;
2736}
2737_ACEOF
2738rm -f conftest.$ac_objext
2739if { (eval echo "$as_me:2739: \"$ac_compile\"") >&5
2740 (eval $ac_compile) 2>&5
2741 ac_status=$?
2742 echo "$as_me:2742: \$? = $ac_status" >&5
2743 (exit $ac_status); } &&
2744 { ac_try='test -s conftest.$ac_objext'
2745 { (eval echo "$as_me:2745: \"$ac_try\"") >&5
2746 (eval $ac_try) 2>&5
2747 ac_status=$?
2748 echo "$as_me:2748: \$? = $ac_status" >&5
2749 (exit $ac_status); }; }; then
2750 ac_cv_c_char_unsigned=no
d60d9f65 2751else
9255ee31
EZ
2752 echo "$as_me: failed program was:" >&5
2753cat conftest.$ac_ext >&5
2754ac_cv_c_char_unsigned=yes
d60d9f65 2755fi
9255ee31 2756rm -f conftest.$ac_objext conftest.$ac_ext
d60d9f65 2757fi
9255ee31
EZ
2758echo "$as_me:2758: result: $ac_cv_c_char_unsigned" >&5
2759echo "${ECHO_T}$ac_cv_c_char_unsigned" >&6
2760if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then
2761 cat >>confdefs.h <<\EOF
2762#define __CHAR_UNSIGNED__ 1
2763EOF
d60d9f65 2764
9255ee31 2765fi
d60d9f65 2766
9255ee31
EZ
2767echo "$as_me:2767: checking return type of signal handlers" >&5
2768echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6
2769if test "${ac_cv_type_signal+set}" = set; then
2770 echo $ECHO_N "(cached) $ECHO_C" >&6
d60d9f65 2771else
9255ee31
EZ
2772 cat >conftest.$ac_ext <<_ACEOF
2773#line 2773 "configure"
d60d9f65
SS
2774#include "confdefs.h"
2775#include <sys/types.h>
2776#include <signal.h>
2777#ifdef signal
9255ee31 2778# undef signal
d60d9f65
SS
2779#endif
2780#ifdef __cplusplus
2781extern "C" void (*signal (int, void (*)(int)))(int);
2782#else
2783void (*signal ()) ();
2784#endif
2785
9255ee31
EZ
2786int
2787main ()
2788{
d60d9f65 2789int i;
9255ee31
EZ
2790 ;
2791 return 0;
2792}
2793_ACEOF
2794rm -f conftest.$ac_objext
2795if { (eval echo "$as_me:2795: \"$ac_compile\"") >&5
2796 (eval $ac_compile) 2>&5
2797 ac_status=$?
2798 echo "$as_me:2798: \$? = $ac_status" >&5
2799 (exit $ac_status); } &&
2800 { ac_try='test -s conftest.$ac_objext'
2801 { (eval echo "$as_me:2801: \"$ac_try\"") >&5
2802 (eval $ac_try) 2>&5
2803 ac_status=$?
2804 echo "$as_me:2804: \$? = $ac_status" >&5
2805 (exit $ac_status); }; }; then
d60d9f65
SS
2806 ac_cv_type_signal=void
2807else
9255ee31
EZ
2808 echo "$as_me: failed program was:" >&5
2809cat conftest.$ac_ext >&5
2810ac_cv_type_signal=int
d60d9f65 2811fi
9255ee31 2812rm -f conftest.$ac_objext conftest.$ac_ext
d60d9f65 2813fi
9255ee31
EZ
2814echo "$as_me:2814: result: $ac_cv_type_signal" >&5
2815echo "${ECHO_T}$ac_cv_type_signal" >&6
d60d9f65 2816
9255ee31 2817cat >>confdefs.h <<EOF
d60d9f65
SS
2818#define RETSIGTYPE $ac_cv_type_signal
2819EOF
2820
9255ee31
EZ
2821echo "$as_me:2821: checking for size_t" >&5
2822echo $ECHO_N "checking for size_t... $ECHO_C" >&6
2823if test "${ac_cv_type_size_t+set}" = set; then
2824 echo $ECHO_N "(cached) $ECHO_C" >&6
2825else
2826 cat >conftest.$ac_ext <<_ACEOF
2827#line 2827 "configure"
2828#include "confdefs.h"
2829$ac_includes_default
2830int
2831main ()
2832{
2833if ((size_t *) 0)
2834 return 0;
2835if (sizeof (size_t))
2836 return 0;
2837 ;
2838 return 0;
2839}
2840_ACEOF
2841rm -f conftest.$ac_objext
2842if { (eval echo "$as_me:2842: \"$ac_compile\"") >&5
2843 (eval $ac_compile) 2>&5
2844 ac_status=$?
2845 echo "$as_me:2845: \$? = $ac_status" >&5
2846 (exit $ac_status); } &&
2847 { ac_try='test -s conftest.$ac_objext'
2848 { (eval echo "$as_me:2848: \"$ac_try\"") >&5
2849 (eval $ac_try) 2>&5
2850 ac_status=$?
2851 echo "$as_me:2851: \$? = $ac_status" >&5
2852 (exit $ac_status); }; }; then
2853 ac_cv_type_size_t=yes
2854else
2855 echo "$as_me: failed program was:" >&5
2856cat conftest.$ac_ext >&5
2857ac_cv_type_size_t=no
2858fi
2859rm -f conftest.$ac_objext conftest.$ac_ext
2860fi
2861echo "$as_me:2861: result: $ac_cv_type_size_t" >&5
2862echo "${ECHO_T}$ac_cv_type_size_t" >&6
2863if test $ac_cv_type_size_t = yes; then
2864 :
2865else
2866
2867cat >>confdefs.h <<EOF
2868#define size_t unsigned
2869EOF
2870
2871fi
2872
2873echo "$as_me:2873: checking for ssize_t" >&5
2874echo $ECHO_N "checking for ssize_t... $ECHO_C" >&6
2875if test "${ac_cv_type_ssize_t+set}" = set; then
2876 echo $ECHO_N "(cached) $ECHO_C" >&6
2877else
2878 cat >conftest.$ac_ext <<_ACEOF
2879#line 2879 "configure"
2880#include "confdefs.h"
2881$ac_includes_default
2882int
2883main ()
2884{
2885if ((ssize_t *) 0)
2886 return 0;
2887if (sizeof (ssize_t))
2888 return 0;
2889 ;
2890 return 0;
2891}
2892_ACEOF
2893rm -f conftest.$ac_objext
2894if { (eval echo "$as_me:2894: \"$ac_compile\"") >&5
2895 (eval $ac_compile) 2>&5
2896 ac_status=$?
2897 echo "$as_me:2897: \$? = $ac_status" >&5
2898 (exit $ac_status); } &&
2899 { ac_try='test -s conftest.$ac_objext'
2900 { (eval echo "$as_me:2900: \"$ac_try\"") >&5
2901 (eval $ac_try) 2>&5
2902 ac_status=$?
2903 echo "$as_me:2903: \$? = $ac_status" >&5
2904 (exit $ac_status); }; }; then
2905 ac_cv_type_ssize_t=yes
2906else
2907 echo "$as_me: failed program was:" >&5
2908cat conftest.$ac_ext >&5
2909ac_cv_type_ssize_t=no
2910fi
2911rm -f conftest.$ac_objext conftest.$ac_ext
2912fi
2913echo "$as_me:2913: result: $ac_cv_type_ssize_t" >&5
2914echo "${ECHO_T}$ac_cv_type_ssize_t" >&6
2915if test $ac_cv_type_ssize_t = yes; then
2916 :
2917else
2918
2919cat >>confdefs.h <<EOF
2920#define ssize_t int
2921EOF
d60d9f65 2922
9255ee31 2923fi
d60d9f65 2924
9255ee31
EZ
2925echo "$as_me:2925: checking whether stat file-mode macros are broken" >&5
2926echo $ECHO_N "checking whether stat file-mode macros are broken... $ECHO_C" >&6
2927if test "${ac_cv_header_stat_broken+set}" = set; then
2928 echo $ECHO_N "(cached) $ECHO_C" >&6
d60d9f65 2929else
9255ee31
EZ
2930 cat >conftest.$ac_ext <<_ACEOF
2931#line 2931 "configure"
d60d9f65
SS
2932#include "confdefs.h"
2933#include <sys/types.h>
2934#include <sys/stat.h>
2935
2936#if defined(S_ISBLK) && defined(S_IFDIR)
2937# if S_ISBLK (S_IFDIR)
2938You lose.
2939# endif
2940#endif
2941
2942#if defined(S_ISBLK) && defined(S_IFCHR)
2943# if S_ISBLK (S_IFCHR)
2944You lose.
2945# endif
2946#endif
2947
2948#if defined(S_ISLNK) && defined(S_IFREG)
2949# if S_ISLNK (S_IFREG)
2950You lose.
2951# endif
2952#endif
2953
2954#if defined(S_ISSOCK) && defined(S_IFREG)
2955# if S_ISSOCK (S_IFREG)
2956You lose.
2957# endif
2958#endif
2959
9255ee31 2960_ACEOF
d60d9f65
SS
2961if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2962 egrep "You lose" >/dev/null 2>&1; then
d60d9f65
SS
2963 ac_cv_header_stat_broken=yes
2964else
d60d9f65
SS
2965 ac_cv_header_stat_broken=no
2966fi
2967rm -f conftest*
2968
2969fi
9255ee31
EZ
2970echo "$as_me:2970: result: $ac_cv_header_stat_broken" >&5
2971echo "${ECHO_T}$ac_cv_header_stat_broken" >&6
d60d9f65 2972if test $ac_cv_header_stat_broken = yes; then
9255ee31
EZ
2973
2974cat >>confdefs.h <<\EOF
d60d9f65
SS
2975#define STAT_MACROS_BROKEN 1
2976EOF
2977
2978fi
2979
2980ac_header_dirent=no
9255ee31
EZ
2981for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
2982 as_ac_Header=`echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
2983echo "$as_me:2983: checking for $ac_hdr that defines DIR" >&5
2984echo $ECHO_N "checking for $ac_hdr that defines DIR... $ECHO_C" >&6
2985if eval "test \"\${$as_ac_Header+set}\" = set"; then
2986 echo $ECHO_N "(cached) $ECHO_C" >&6
2987else
2988 cat >conftest.$ac_ext <<_ACEOF
2989#line 2989 "configure"
d60d9f65
SS
2990#include "confdefs.h"
2991#include <sys/types.h>
2992#include <$ac_hdr>
9255ee31
EZ
2993
2994int
2995main ()
2996{
2997if ((DIR *) 0)
2998return 0;
2999 ;
3000 return 0;
3001}
3002_ACEOF
3003rm -f conftest.$ac_objext
3004if { (eval echo "$as_me:3004: \"$ac_compile\"") >&5
3005 (eval $ac_compile) 2>&5
3006 ac_status=$?
3007 echo "$as_me:3007: \$? = $ac_status" >&5
3008 (exit $ac_status); } &&
3009 { ac_try='test -s conftest.$ac_objext'
3010 { (eval echo "$as_me:3010: \"$ac_try\"") >&5
3011 (eval $ac_try) 2>&5
3012 ac_status=$?
3013 echo "$as_me:3013: \$? = $ac_status" >&5
3014 (exit $ac_status); }; }; then
3015 eval "$as_ac_Header=yes"
d60d9f65 3016else
9255ee31
EZ
3017 echo "$as_me: failed program was:" >&5
3018cat conftest.$ac_ext >&5
3019eval "$as_ac_Header=no"
d60d9f65 3020fi
9255ee31 3021rm -f conftest.$ac_objext conftest.$ac_ext
d60d9f65 3022fi
9255ee31
EZ
3023echo "$as_me:3023: result: `eval echo '${'$as_ac_Header'}'`" >&5
3024echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
3025if test `eval echo '${'$as_ac_Header'}'` = yes; then
3026 cat >>confdefs.h <<EOF
3027#define `echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
d60d9f65 3028EOF
9255ee31
EZ
3029
3030ac_header_dirent=$ac_hdr; break
d60d9f65 3031fi
9255ee31 3032
d60d9f65
SS
3033done
3034# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
3035if test $ac_header_dirent = dirent.h; then
9255ee31
EZ
3036 echo "$as_me:3036: checking for opendir in -ldir" >&5
3037echo $ECHO_N "checking for opendir in -ldir... $ECHO_C" >&6
3038if test "${ac_cv_lib_dir_opendir+set}" = set; then
3039 echo $ECHO_N "(cached) $ECHO_C" >&6
d60d9f65 3040else
9255ee31 3041 ac_check_lib_save_LIBS=$LIBS
d60d9f65 3042LIBS="-ldir $LIBS"
9255ee31
EZ
3043cat >conftest.$ac_ext <<_ACEOF
3044#line 3044 "configure"
d60d9f65 3045#include "confdefs.h"
9255ee31 3046
d60d9f65 3047/* Override any gcc2 internal prototype to avoid an error. */
9255ee31
EZ
3048#ifdef __cplusplus
3049extern "C"
3050#endif
d60d9f65 3051/* We use char because int might match the return type of a gcc2
9255ee31
EZ
3052 builtin and then its argument prototype would still apply. */
3053char opendir ();
3054int
3055main ()
3056{
3057opendir ();
3058 ;
3059 return 0;
3060}
3061_ACEOF
3062rm -f conftest.$ac_objext conftest$ac_exeext
3063if { (eval echo "$as_me:3063: \"$ac_link\"") >&5
3064 (eval $ac_link) 2>&5
3065 ac_status=$?
3066 echo "$as_me:3066: \$? = $ac_status" >&5
3067 (exit $ac_status); } &&
3068 { ac_try='test -s conftest$ac_exeext'
3069 { (eval echo "$as_me:3069: \"$ac_try\"") >&5
3070 (eval $ac_try) 2>&5
3071 ac_status=$?
3072 echo "$as_me:3072: \$? = $ac_status" >&5
3073 (exit $ac_status); }; }; then
3074 ac_cv_lib_dir_opendir=yes
d60d9f65 3075else
9255ee31
EZ
3076 echo "$as_me: failed program was:" >&5
3077cat conftest.$ac_ext >&5
3078ac_cv_lib_dir_opendir=no
d60d9f65 3079fi
9255ee31
EZ
3080rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
3081LIBS=$ac_check_lib_save_LIBS
d60d9f65 3082fi
9255ee31
EZ
3083echo "$as_me:3083: result: $ac_cv_lib_dir_opendir" >&5
3084echo "${ECHO_T}$ac_cv_lib_dir_opendir" >&6
3085if test $ac_cv_lib_dir_opendir = yes; then
d60d9f65 3086 LIBS="$LIBS -ldir"
d60d9f65
SS
3087fi
3088
3089else
9255ee31
EZ
3090 echo "$as_me:3090: checking for opendir in -lx" >&5
3091echo $ECHO_N "checking for opendir in -lx... $ECHO_C" >&6
3092if test "${ac_cv_lib_x_opendir+set}" = set; then
3093 echo $ECHO_N "(cached) $ECHO_C" >&6
d60d9f65 3094else
9255ee31 3095 ac_check_lib_save_LIBS=$LIBS
d60d9f65 3096LIBS="-lx $LIBS"
9255ee31
EZ
3097cat >conftest.$ac_ext <<_ACEOF
3098#line 3098 "configure"
d60d9f65 3099#include "confdefs.h"
9255ee31 3100
d60d9f65 3101/* Override any gcc2 internal prototype to avoid an error. */
9255ee31
EZ
3102#ifdef __cplusplus
3103extern "C"
3104#endif
d60d9f65 3105/* We use char because int might match the return type of a gcc2
9255ee31
EZ
3106 builtin and then its argument prototype would still apply. */
3107char opendir ();
3108int
3109main ()
3110{
3111opendir ();
3112 ;
3113 return 0;
3114}
3115_ACEOF
3116rm -f conftest.$ac_objext conftest$ac_exeext
3117if { (eval echo "$as_me:3117: \"$ac_link\"") >&5
3118 (eval $ac_link) 2>&5
3119 ac_status=$?
3120 echo "$as_me:3120: \$? = $ac_status" >&5
3121 (exit $ac_status); } &&
3122 { ac_try='test -s conftest$ac_exeext'
3123 { (eval echo "$as_me:3123: \"$ac_try\"") >&5
3124 (eval $ac_try) 2>&5
3125 ac_status=$?
3126 echo "$as_me:3126: \$? = $ac_status" >&5
3127 (exit $ac_status); }; }; then
3128 ac_cv_lib_x_opendir=yes
d60d9f65 3129else
9255ee31
EZ
3130 echo "$as_me: failed program was:" >&5
3131cat conftest.$ac_ext >&5
3132ac_cv_lib_x_opendir=no
d60d9f65 3133fi
9255ee31
EZ
3134rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
3135LIBS=$ac_check_lib_save_LIBS
d60d9f65 3136fi
9255ee31
EZ
3137echo "$as_me:3137: result: $ac_cv_lib_x_opendir" >&5
3138echo "${ECHO_T}$ac_cv_lib_x_opendir" >&6
3139if test $ac_cv_lib_x_opendir = yes; then
d60d9f65 3140 LIBS="$LIBS -lx"
d60d9f65
SS
3141fi
3142
3143fi
3144
1b17e766 3145for ac_func in lstat memmove putenv select setenv setlocale \
9255ee31 3146 strcasecmp strpbrk tcgetattr vsnprintf isascii isxdigit
d60d9f65 3147do
9255ee31
EZ
3148as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
3149echo "$as_me:3149: checking for $ac_func" >&5
3150echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
3151if eval "test \"\${$as_ac_var+set}\" = set"; then
3152 echo $ECHO_N "(cached) $ECHO_C" >&6
d60d9f65 3153else
9255ee31
EZ
3154 cat >conftest.$ac_ext <<_ACEOF
3155#line 3155 "configure"
d60d9f65
SS
3156#include "confdefs.h"
3157/* System header to define __stub macros and hopefully few prototypes,
9255ee31 3158 which can conflict with char $ac_func (); below. */
d60d9f65
SS
3159#include <assert.h>
3160/* Override any gcc2 internal prototype to avoid an error. */
9255ee31
EZ
3161#ifdef __cplusplus
3162extern "C"
3163#endif
d60d9f65 3164/* We use char because int might match the return type of a gcc2
9255ee31
EZ
3165 builtin and then its argument prototype would still apply. */
3166char $ac_func ();
3167char (*f) ();
d60d9f65 3168
9255ee31
EZ
3169int
3170main ()
3171{
d60d9f65
SS
3172/* The GNU C library defines this for functions which it implements
3173 to always fail with ENOSYS. Some functions are actually named
3174 something starting with __ and the normal name is an alias. */
3175#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3176choke me
3177#else
9255ee31 3178f = $ac_func;
d60d9f65
SS
3179#endif
3180
9255ee31
EZ
3181 ;
3182 return 0;
3183}
3184_ACEOF
3185rm -f conftest.$ac_objext conftest$ac_exeext
3186if { (eval echo "$as_me:3186: \"$ac_link\"") >&5
3187 (eval $ac_link) 2>&5
3188 ac_status=$?
3189 echo "$as_me:3189: \$? = $ac_status" >&5
3190 (exit $ac_status); } &&
3191 { ac_try='test -s conftest$ac_exeext'
3192 { (eval echo "$as_me:3192: \"$ac_try\"") >&5
3193 (eval $ac_try) 2>&5
3194 ac_status=$?
3195 echo "$as_me:3195: \$? = $ac_status" >&5
3196 (exit $ac_status); }; }; then
3197 eval "$as_ac_var=yes"
d60d9f65 3198else
9255ee31
EZ
3199 echo "$as_me: failed program was:" >&5
3200cat conftest.$ac_ext >&5
3201eval "$as_ac_var=no"
d60d9f65 3202fi
9255ee31 3203rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
d60d9f65 3204fi
9255ee31
EZ
3205echo "$as_me:3205: result: `eval echo '${'$as_ac_var'}'`" >&5
3206echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
3207if test `eval echo '${'$as_ac_var'}'` = yes; then
3208 cat >>confdefs.h <<EOF
3209#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
d60d9f65 3210EOF
9255ee31 3211
d60d9f65
SS
3212fi
3213done
3214
9255ee31
EZ
3215echo "$as_me:3215: checking for working strcoll" >&5
3216echo $ECHO_N "checking for working strcoll... $ECHO_C" >&6
3217if test "${ac_cv_func_strcoll_works+set}" = set; then
3218 echo $ECHO_N "(cached) $ECHO_C" >&6
d60d9f65
SS
3219else
3220 if test "$cross_compiling" = yes; then
3221 ac_cv_func_strcoll_works=no
3222else
9255ee31
EZ
3223 cat >conftest.$ac_ext <<_ACEOF
3224#line 3224 "configure"
d60d9f65 3225#include "confdefs.h"
9255ee31
EZ
3226$ac_includes_default
3227int
d60d9f65
SS
3228main ()
3229{
9255ee31
EZ
3230exit (strcoll ("abc", "def") >= 0 ||
3231 strcoll ("ABC", "DEF") >= 0 ||
3232 strcoll ("123", "456") >= 0)
3233 ;
3234 return 0;
d60d9f65 3235}
9255ee31
EZ
3236_ACEOF
3237rm -f conftest$ac_exeext
3238if { (eval echo "$as_me:3238: \"$ac_link\"") >&5
3239 (eval $ac_link) 2>&5
3240 ac_status=$?
3241 echo "$as_me:3241: \$? = $ac_status" >&5
3242 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
3243 { (eval echo "$as_me:3243: \"$ac_try\"") >&5
3244 (eval $ac_try) 2>&5
3245 ac_status=$?
3246 echo "$as_me:3246: \$? = $ac_status" >&5
3247 (exit $ac_status); }; }; then
d60d9f65
SS
3248 ac_cv_func_strcoll_works=yes
3249else
9255ee31
EZ
3250 echo "$as_me: program exited with status $ac_status" >&5
3251echo "$as_me: failed program was:" >&5
3252cat conftest.$ac_ext >&5
3253ac_cv_func_strcoll_works=no
d60d9f65 3254fi
9255ee31 3255rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
d60d9f65 3256fi
d60d9f65 3257fi
9255ee31
EZ
3258echo "$as_me:3258: result: $ac_cv_func_strcoll_works" >&5
3259echo "${ECHO_T}$ac_cv_func_strcoll_works" >&6
d60d9f65 3260if test $ac_cv_func_strcoll_works = yes; then
9255ee31
EZ
3261
3262cat >>confdefs.h <<\EOF
d60d9f65
SS
3263#define HAVE_STRCOLL 1
3264EOF
3265
3266fi
3267
9255ee31
EZ
3268for ac_header in unistd.h stdlib.h varargs.h stdarg.h string.h strings.h \
3269 limits.h sys/ptem.h sys/pte.h sys/stream.h sys/select.h \
3270 termcap.h termios.h termio.h sys/file.h locale.h memory.h
d60d9f65 3271do
9255ee31
EZ
3272as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
3273echo "$as_me:3273: checking for $ac_header" >&5
3274echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3275if eval "test \"\${$as_ac_Header+set}\" = set"; then
3276 echo $ECHO_N "(cached) $ECHO_C" >&6
3277else
3278 cat >conftest.$ac_ext <<_ACEOF
3279#line 3279 "configure"
d60d9f65 3280#include "confdefs.h"
9255ee31
EZ
3281#include <$ac_header>
3282_ACEOF
3283if { (eval echo "$as_me:3283: \"$ac_cpp conftest.$ac_ext\"") >&5
3284 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3285 ac_status=$?
3286 egrep -v '^ *\+' conftest.er1 >conftest.err
3287 rm -f conftest.er1
3288 cat conftest.err >&5
3289 echo "$as_me:3289: \$? = $ac_status" >&5
3290 (exit $ac_status); } >/dev/null; then
3291 if test -s conftest.err; then
3292 ac_cpp_err=$ac_c_preproc_warn_flag
3293 else
3294 ac_cpp_err=
3295 fi
3296else
3297 ac_cpp_err=yes
3298fi
3299if test -z "$ac_cpp_err"; then
3300 eval "$as_ac_Header=yes"
d60d9f65 3301else
9255ee31 3302 echo "$as_me: failed program was:" >&5
d60d9f65 3303 cat conftest.$ac_ext >&5
9255ee31 3304 eval "$as_ac_Header=no"
d60d9f65 3305fi
9255ee31 3306rm -f conftest.err conftest.$ac_ext
d60d9f65 3307fi
9255ee31
EZ
3308echo "$as_me:3308: result: `eval echo '${'$as_ac_Header'}'`" >&5
3309echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
3310if test `eval echo '${'$as_ac_Header'}'` = yes; then
3311 cat >>confdefs.h <<EOF
3312#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
d60d9f65 3313EOF
9255ee31 3314
d60d9f65
SS
3315fi
3316done
3317
9255ee31
EZ
3318echo "$as_me:3318: checking for type of signal functions" >&5
3319echo $ECHO_N "checking for type of signal functions... $ECHO_C" >&6
3320if test "${bash_cv_signal_vintage+set}" = set; then
3321 echo $ECHO_N "(cached) $ECHO_C" >&6
d60d9f65 3322else
9255ee31
EZ
3323
3324 cat >conftest.$ac_ext <<_ACEOF
3325#line 3325 "configure"
d60d9f65
SS
3326#include "confdefs.h"
3327#include <signal.h>
9255ee31
EZ
3328int
3329main ()
3330{
d60d9f65
SS
3331
3332 sigset_t ss;
3333 struct sigaction sa;
3334 sigemptyset(&ss); sigsuspend(&ss);
3335 sigaction(SIGINT, &sa, (struct sigaction *) 0);
3336 sigprocmask(SIG_BLOCK, &ss, (sigset_t *) 0);
9255ee31
EZ
3337
3338 ;
3339 return 0;
3340}
3341_ACEOF
3342rm -f conftest.$ac_objext conftest$ac_exeext
3343if { (eval echo "$as_me:3343: \"$ac_link\"") >&5
3344 (eval $ac_link) 2>&5
3345 ac_status=$?
3346 echo "$as_me:3346: \$? = $ac_status" >&5
3347 (exit $ac_status); } &&
3348 { ac_try='test -s conftest$ac_exeext'
3349 { (eval echo "$as_me:3349: \"$ac_try\"") >&5
3350 (eval $ac_try) 2>&5
3351 ac_status=$?
3352 echo "$as_me:3352: \$? = $ac_status" >&5
3353 (exit $ac_status); }; }; then
d60d9f65
SS
3354 bash_cv_signal_vintage=posix
3355else
9255ee31
EZ
3356 echo "$as_me: failed program was:" >&5
3357cat conftest.$ac_ext >&5
3358
3359 cat >conftest.$ac_ext <<_ACEOF
3360#line 3360 "configure"
d60d9f65
SS
3361#include "confdefs.h"
3362#include <signal.h>
9255ee31
EZ
3363int
3364main ()
3365{
d60d9f65
SS
3366
3367 int mask = sigmask(SIGINT);
3368 sigsetmask(mask); sigblock(mask); sigpause(mask);
9255ee31
EZ
3369
3370 ;
3371 return 0;
3372}
3373_ACEOF
3374rm -f conftest.$ac_objext conftest$ac_exeext
3375if { (eval echo "$as_me:3375: \"$ac_link\"") >&5
3376 (eval $ac_link) 2>&5
3377 ac_status=$?
3378 echo "$as_me:3378: \$? = $ac_status" >&5
3379 (exit $ac_status); } &&
3380 { ac_try='test -s conftest$ac_exeext'
3381 { (eval echo "$as_me:3381: \"$ac_try\"") >&5
3382 (eval $ac_try) 2>&5
3383 ac_status=$?
3384 echo "$as_me:3384: \$? = $ac_status" >&5
3385 (exit $ac_status); }; }; then
d60d9f65
SS
3386 bash_cv_signal_vintage=4.2bsd
3387else
9255ee31
EZ
3388 echo "$as_me: failed program was:" >&5
3389cat conftest.$ac_ext >&5
3390
3391 cat >conftest.$ac_ext <<_ACEOF
3392#line 3392 "configure"
d60d9f65
SS
3393#include "confdefs.h"
3394
3395 #include <signal.h>
3396 RETSIGTYPE foo() { }
9255ee31
EZ
3397int
3398main ()
3399{
d60d9f65
SS
3400
3401 int mask = sigmask(SIGINT);
3402 sigset(SIGINT, foo); sigrelse(SIGINT);
3403 sighold(SIGINT); sigpause(SIGINT);
9255ee31
EZ
3404
3405 ;
3406 return 0;
3407}
3408_ACEOF
3409rm -f conftest.$ac_objext conftest$ac_exeext
3410if { (eval echo "$as_me:3410: \"$ac_link\"") >&5
3411 (eval $ac_link) 2>&5
3412 ac_status=$?
3413 echo "$as_me:3413: \$? = $ac_status" >&5
3414 (exit $ac_status); } &&
3415 { ac_try='test -s conftest$ac_exeext'
3416 { (eval echo "$as_me:3416: \"$ac_try\"") >&5
3417 (eval $ac_try) 2>&5
3418 ac_status=$?
3419 echo "$as_me:3419: \$? = $ac_status" >&5
3420 (exit $ac_status); }; }; then
d60d9f65
SS
3421 bash_cv_signal_vintage=svr3
3422else
9255ee31
EZ
3423 echo "$as_me: failed program was:" >&5
3424cat conftest.$ac_ext >&5
3425bash_cv_signal_vintage=v7
3426
d60d9f65 3427fi
9255ee31
EZ
3428rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
3429
d60d9f65 3430fi
9255ee31 3431rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
d60d9f65
SS
3432
3433fi
9255ee31 3434rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
d60d9f65
SS
3435
3436fi
3437
9255ee31
EZ
3438echo "$as_me:3438: result: $bash_cv_signal_vintage" >&5
3439echo "${ECHO_T}$bash_cv_signal_vintage" >&6
d60d9f65 3440if test "$bash_cv_signal_vintage" = posix; then
9255ee31 3441cat >>confdefs.h <<\EOF
d60d9f65
SS
3442#define HAVE_POSIX_SIGNALS 1
3443EOF
3444
3445elif test "$bash_cv_signal_vintage" = "4.2bsd"; then
9255ee31 3446cat >>confdefs.h <<\EOF
d60d9f65
SS
3447#define HAVE_BSD_SIGNALS 1
3448EOF
3449
3450elif test "$bash_cv_signal_vintage" = svr3; then
9255ee31 3451cat >>confdefs.h <<\EOF
d60d9f65
SS
3452#define HAVE_USG_SIGHOLD 1
3453EOF
3454
3455fi
3456
9255ee31
EZ
3457echo "$as_me:3457: checking if signal handlers must be reinstalled when invoked" >&5
3458echo $ECHO_N "checking if signal handlers must be reinstalled when invoked... $ECHO_C" >&6
3459if test "${bash_cv_must_reinstall_sighandlers+set}" = set; then
3460 echo $ECHO_N "(cached) $ECHO_C" >&6
d60d9f65
SS
3461else
3462 if test "$cross_compiling" = yes; then
9255ee31
EZ
3463 { echo "$as_me:3463: WARNING: cannot check signal handling if cross compiling -- defaulting to no" >&5
3464echo "$as_me: WARNING: cannot check signal handling if cross compiling -- defaulting to no" >&2;}
d60d9f65
SS
3465 bash_cv_must_reinstall_sighandlers=no
3466
3467else
9255ee31
EZ
3468 cat >conftest.$ac_ext <<_ACEOF
3469#line 3469 "configure"
d60d9f65
SS
3470#include "confdefs.h"
3471
3472#include <signal.h>
3473#ifdef HAVE_UNISTD_H
3474#include <unistd.h>
3475#endif
3476
3477typedef RETSIGTYPE sigfunc();
3478
3479int nsigint;
3480
3481#ifdef HAVE_POSIX_SIGNALS
3482sigfunc *
3483set_signal_handler(sig, handler)
3484 int sig;
3485 sigfunc *handler;
3486{
3487 struct sigaction act, oact;
3488 act.sa_handler = handler;
3489 act.sa_flags = 0;
3490 sigemptyset (&act.sa_mask);
3491 sigemptyset (&oact.sa_mask);
3492 sigaction (sig, &act, &oact);
3493 return (oact.sa_handler);
3494}
3495#else
3496#define set_signal_handler(s, h) signal(s, h)
3497#endif
3498
3499RETSIGTYPE
3500sigint(s)
3501int s;
3502{
3503 nsigint++;
3504}
3505
3506main()
3507{
3508 nsigint = 0;
3509 set_signal_handler(SIGINT, sigint);
3510 kill((int)getpid(), SIGINT);
3511 kill((int)getpid(), SIGINT);
3512 exit(nsigint != 2);
3513}
3514
9255ee31
EZ
3515_ACEOF
3516rm -f conftest$ac_exeext
3517if { (eval echo "$as_me:3517: \"$ac_link\"") >&5
3518 (eval $ac_link) 2>&5
3519 ac_status=$?
3520 echo "$as_me:3520: \$? = $ac_status" >&5
3521 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
3522 { (eval echo "$as_me:3522: \"$ac_try\"") >&5
3523 (eval $ac_try) 2>&5
3524 ac_status=$?
3525 echo "$as_me:3525: \$? = $ac_status" >&5
3526 (exit $ac_status); }; }; then
d60d9f65
SS
3527 bash_cv_must_reinstall_sighandlers=no
3528else
9255ee31
EZ
3529 echo "$as_me: program exited with status $ac_status" >&5
3530echo "$as_me: failed program was:" >&5
3531cat conftest.$ac_ext >&5
3532bash_cv_must_reinstall_sighandlers=yes
d60d9f65 3533fi
9255ee31 3534rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
d60d9f65 3535fi
d60d9f65
SS
3536fi
3537
9255ee31
EZ
3538echo "$as_me:3538: result: $bash_cv_must_reinstall_sighandlers" >&5
3539echo "${ECHO_T}$bash_cv_must_reinstall_sighandlers" >&6
d60d9f65 3540if test $bash_cv_must_reinstall_sighandlers = yes; then
9255ee31 3541cat >>confdefs.h <<\EOF
d60d9f65
SS
3542#define MUST_REINSTALL_SIGHANDLERS 1
3543EOF
3544
3545fi
3546
9255ee31
EZ
3547echo "$as_me:3547: checking for presence of POSIX-style sigsetjmp/siglongjmp" >&5
3548echo $ECHO_N "checking for presence of POSIX-style sigsetjmp/siglongjmp... $ECHO_C" >&6
3549if test "${bash_cv_func_sigsetjmp+set}" = set; then
3550 echo $ECHO_N "(cached) $ECHO_C" >&6
d60d9f65
SS
3551else
3552 if test "$cross_compiling" = yes; then
9255ee31
EZ
3553 { echo "$as_me:3553: WARNING: cannot check for sigsetjmp/siglongjmp if cross-compiling -- defaulting to missing" >&5
3554echo "$as_me: WARNING: cannot check for sigsetjmp/siglongjmp if cross-compiling -- defaulting to missing" >&2;}
d60d9f65
SS
3555 bash_cv_func_sigsetjmp=missing
3556
3557else
9255ee31
EZ
3558 cat >conftest.$ac_ext <<_ACEOF
3559#line 3559 "configure"
d60d9f65
SS
3560#include "confdefs.h"
3561
3562#ifdef HAVE_UNISTD_H
3563#include <unistd.h>
3564#endif
3565#include <sys/types.h>
3566#include <signal.h>
3567#include <setjmp.h>
3568
3569main()
3570{
3571#if !defined (_POSIX_VERSION) || !defined (HAVE_POSIX_SIGNALS)
3572exit (1);
3573#else
3574
3575int code;
3576sigset_t set, oset;
3577sigjmp_buf xx;
3578
3579/* get the mask */
3580sigemptyset(&set);
3581sigemptyset(&oset);
3582sigprocmask(SIG_BLOCK, (sigset_t *)NULL, &set);
3583sigprocmask(SIG_BLOCK, (sigset_t *)NULL, &oset);
3584
3585/* save it */
3586code = sigsetjmp(xx, 1);
3587if (code)
3588 exit(0); /* could get sigmask and compare to oset here. */
3589
3590/* change it */
3591sigaddset(&set, SIGINT);
3592sigprocmask(SIG_BLOCK, &set, (sigset_t *)NULL);
3593
3594/* and siglongjmp */
3595siglongjmp(xx, 10);
3596exit(1);
3597#endif
3598}
9255ee31
EZ
3599_ACEOF
3600rm -f conftest$ac_exeext
3601if { (eval echo "$as_me:3601: \"$ac_link\"") >&5
3602 (eval $ac_link) 2>&5
3603 ac_status=$?
3604 echo "$as_me:3604: \$? = $ac_status" >&5
3605 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
3606 { (eval echo "$as_me:3606: \"$ac_try\"") >&5
3607 (eval $ac_try) 2>&5
3608 ac_status=$?
3609 echo "$as_me:3609: \$? = $ac_status" >&5
3610 (exit $ac_status); }; }; then
d60d9f65
SS
3611 bash_cv_func_sigsetjmp=present
3612else
9255ee31
EZ
3613 echo "$as_me: program exited with status $ac_status" >&5
3614echo "$as_me: failed program was:" >&5
3615cat conftest.$ac_ext >&5
3616bash_cv_func_sigsetjmp=missing
d60d9f65 3617fi
9255ee31 3618rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
d60d9f65 3619fi
d60d9f65
SS
3620fi
3621
9255ee31
EZ
3622echo "$as_me:3622: result: $bash_cv_func_sigsetjmp" >&5
3623echo "${ECHO_T}$bash_cv_func_sigsetjmp" >&6
d60d9f65 3624if test $bash_cv_func_sigsetjmp = present; then
9255ee31 3625cat >>confdefs.h <<\EOF
d60d9f65
SS
3626#define HAVE_POSIX_SIGSETJMP 1
3627EOF
3628
3629fi
3630
9255ee31
EZ
3631echo "$as_me:3631: checking for lstat" >&5
3632echo $ECHO_N "checking for lstat... $ECHO_C" >&6
3633if test "${bash_cv_func_lstat+set}" = set; then
3634 echo $ECHO_N "(cached) $ECHO_C" >&6
d60d9f65 3635else
9255ee31
EZ
3636 cat >conftest.$ac_ext <<_ACEOF
3637#line 3637 "configure"
d60d9f65
SS
3638#include "confdefs.h"
3639
3640#include <sys/types.h>
3641#include <sys/stat.h>
3642
9255ee31
EZ
3643int
3644main ()
3645{
3646 lstat(".",(struct stat *)0);
3647 ;
3648 return 0;
3649}
3650_ACEOF
3651rm -f conftest.$ac_objext conftest$ac_exeext
3652if { (eval echo "$as_me:3652: \"$ac_link\"") >&5
3653 (eval $ac_link) 2>&5
3654 ac_status=$?
3655 echo "$as_me:3655: \$? = $ac_status" >&5
3656 (exit $ac_status); } &&
3657 { ac_try='test -s conftest$ac_exeext'
3658 { (eval echo "$as_me:3658: \"$ac_try\"") >&5
3659 (eval $ac_try) 2>&5
3660 ac_status=$?
3661 echo "$as_me:3661: \$? = $ac_status" >&5
3662 (exit $ac_status); }; }; then
d60d9f65
SS
3663 bash_cv_func_lstat=yes
3664else
9255ee31
EZ
3665 echo "$as_me: failed program was:" >&5
3666cat conftest.$ac_ext >&5
3667bash_cv_func_lstat=no
d60d9f65 3668fi
9255ee31 3669rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
d60d9f65 3670fi
9255ee31
EZ
3671echo "$as_me:3671: result: $bash_cv_func_lstat" >&5
3672echo "${ECHO_T}$bash_cv_func_lstat" >&6
d60d9f65 3673if test $bash_cv_func_lstat = yes; then
9255ee31 3674 cat >>confdefs.h <<\EOF
d60d9f65
SS
3675#define HAVE_LSTAT 1
3676EOF
3677
3678fi
3679
9255ee31
EZ
3680echo "$as_me:3680: checking whether or not strcoll and strcmp differ" >&5
3681echo $ECHO_N "checking whether or not strcoll and strcmp differ... $ECHO_C" >&6
3682if test "${bash_cv_func_strcoll_broken+set}" = set; then
3683 echo $ECHO_N "(cached) $ECHO_C" >&6
d60d9f65
SS
3684else
3685 if test "$cross_compiling" = yes; then
9255ee31
EZ
3686 { echo "$as_me:3686: WARNING: cannot check strcoll if cross compiling -- defaulting to no" >&5
3687echo "$as_me: WARNING: cannot check strcoll if cross compiling -- defaulting to no" >&2;}
d60d9f65
SS
3688 bash_cv_func_strcoll_broken=no
3689
3690else
9255ee31
EZ
3691 cat >conftest.$ac_ext <<_ACEOF
3692#line 3692 "configure"
d60d9f65
SS
3693#include "confdefs.h"
3694
3695#include <stdio.h>
3696#if defined (HAVE_LOCALE_H)
3697#include <locale.h>
3698#endif
3699
3700main(c, v)
3701int c;
3702char *v[];
3703{
3704 int r1, r2;
3705 char *deflocale, *defcoll;
3706
3707#ifdef HAVE_SETLOCALE
3708 deflocale = setlocale(LC_ALL, "");
3709 defcoll = setlocale(LC_COLLATE, "");
3710#endif
3711
3712#ifdef HAVE_STRCOLL
3713 /* These two values are taken from tests/glob-test. */
3714 r1 = strcoll("abd", "aXd");
3715#else
3716 r1 = 0;
3717#endif
9255ee31
EZ
3718 r2 = strcmp("abd", "aXd");
3719
3720 /* These two should both be greater than 0. It is permissible for
3721 a system to return different values, as long as the sign is the
3722 same. */
3723
3724 /* Exit with 1 (failure) if these two values are both > 0, since
3725 this tests whether strcoll(3) is broken with respect to strcmp(3)
3726 in the default locale. */
3727 exit (r1 > 0 && r2 > 0);
3728}
3729
3730_ACEOF
3731rm -f conftest$ac_exeext
3732if { (eval echo "$as_me:3732: \"$ac_link\"") >&5
3733 (eval $ac_link) 2>&5
3734 ac_status=$?
3735 echo "$as_me:3735: \$? = $ac_status" >&5
3736 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
3737 { (eval echo "$as_me:3737: \"$ac_try\"") >&5
3738 (eval $ac_try) 2>&5
3739 ac_status=$?
3740 echo "$as_me:3740: \$? = $ac_status" >&5
3741 (exit $ac_status); }; }; then
3742 bash_cv_func_strcoll_broken=yes
3743else
3744 echo "$as_me: program exited with status $ac_status" >&5
3745echo "$as_me: failed program was:" >&5
3746cat conftest.$ac_ext >&5
3747bash_cv_func_strcoll_broken=no
3748fi
3749rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
3750fi
3751fi
3752
3753echo "$as_me:3753: result: $bash_cv_func_strcoll_broken" >&5
3754echo "${ECHO_T}$bash_cv_func_strcoll_broken" >&6
3755if test $bash_cv_func_strcoll_broken = yes; then
3756cat >>confdefs.h <<\EOF
3757#define STRCOLL_BROKEN 1
3758EOF
3759
3760fi
3761
3762echo "$as_me:3762: checking whether getpw functions are declared in pwd.h" >&5
3763echo $ECHO_N "checking whether getpw functions are declared in pwd.h... $ECHO_C" >&6
3764if test "${bash_cv_getpw_declared+set}" = set; then
3765 echo $ECHO_N "(cached) $ECHO_C" >&6
3766else
3767 cat >conftest.$ac_ext <<_ACEOF
3768#line 3768 "configure"
3769#include "confdefs.h"
3770
3771#include <sys/types.h>
3772#ifdef HAVE_UNISTD_H
3773# include <unistd.h>
3774#endif
3775#include <pwd.h>
3776
3777_ACEOF
3778if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3779 egrep "getpwuid" >/dev/null 2>&1; then
3780 bash_cv_getpw_declared=yes
3781else
3782 bash_cv_getpw_declared=no
3783fi
3784rm -f conftest*
3785
3786fi
3787
3788echo "$as_me:3788: result: $bash_cv_getpw_declared" >&5
3789echo "${ECHO_T}$bash_cv_getpw_declared" >&6
3790if test $bash_cv_getpw_declared = yes; then
3791cat >>confdefs.h <<\EOF
3792#define HAVE_GETPW_DECLS 1
3793EOF
3794
3795fi
3796
3797echo "$as_me:3797: checking POSIX termios" >&5
3798echo $ECHO_N "checking POSIX termios... $ECHO_C" >&6
3799if test "${ac_cv_sys_posix_termios+set}" = set; then
3800 echo $ECHO_N "(cached) $ECHO_C" >&6
3801else
3802 cat >conftest.$ac_ext <<_ACEOF
3803#line 3803 "configure"
3804#include "confdefs.h"
3805#include <sys/types.h>
3806#include <unistd.h>
3807#include <termios.h>
3808int
3809main ()
3810{
3811/* SunOS 4.0.3 has termios.h but not the library calls. */
3812 tcgetattr(0, 0);
3813 ;
3814 return 0;
3815}
3816_ACEOF
3817rm -f conftest.$ac_objext conftest$ac_exeext
3818if { (eval echo "$as_me:3818: \"$ac_link\"") >&5
3819 (eval $ac_link) 2>&5
3820 ac_status=$?
3821 echo "$as_me:3821: \$? = $ac_status" >&5
3822 (exit $ac_status); } &&
3823 { ac_try='test -s conftest$ac_exeext'
3824 { (eval echo "$as_me:3824: \"$ac_try\"") >&5
3825 (eval $ac_try) 2>&5
3826 ac_status=$?
3827 echo "$as_me:3827: \$? = $ac_status" >&5
3828 (exit $ac_status); }; }; then
3829 ac_cv_sys_posix_termios=yes
3830else
3831 echo "$as_me: failed program was:" >&5
3832cat conftest.$ac_ext >&5
3833ac_cv_sys_posix_termios=no
3834fi
3835rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
3836fi
3837echo "$as_me:3837: result: $ac_cv_sys_posix_termios" >&5
3838echo "${ECHO_T}$ac_cv_sys_posix_termios" >&6
3839
3840if test $ac_cv_sys_posix_termios = yes; then
3841 echo "$as_me:3841: checking whether termios.h defines TIOCGWINSZ" >&5
3842echo $ECHO_N "checking whether termios.h defines TIOCGWINSZ... $ECHO_C" >&6
3843if test "${ac_cv_sys_tiocgwinsz_in_termios_h+set}" = set; then
3844 echo $ECHO_N "(cached) $ECHO_C" >&6
3845else
3846 cat >conftest.$ac_ext <<_ACEOF
3847#line 3847 "configure"
3848#include "confdefs.h"
3849#include <sys/types.h>
3850#include <termios.h>
3851#ifdef TIOCGWINSZ
3852 yes
3853#endif
d60d9f65 3854
9255ee31
EZ
3855_ACEOF
3856if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3857 egrep "yes" >/dev/null 2>&1; then
3858 ac_cv_sys_tiocgwinsz_in_termios_h=yes
3859else
3860 ac_cv_sys_tiocgwinsz_in_termios_h=no
3861fi
3862rm -f conftest*
d60d9f65 3863
9255ee31
EZ
3864fi
3865echo "$as_me:3865: result: $ac_cv_sys_tiocgwinsz_in_termios_h" >&5
3866echo "${ECHO_T}$ac_cv_sys_tiocgwinsz_in_termios_h" >&6
d60d9f65 3867
d60d9f65 3868fi
9255ee31
EZ
3869if test $ac_cv_sys_tiocgwinsz_in_termios_h != yes; then
3870 echo "$as_me:3870: checking whether sys/ioctl.h defines TIOCGWINSZ" >&5
3871echo $ECHO_N "checking whether sys/ioctl.h defines TIOCGWINSZ... $ECHO_C" >&6
3872if test "${ac_cv_sys_tiocgwinsz_in_sys_ioctl_h+set}" = set; then
3873 echo $ECHO_N "(cached) $ECHO_C" >&6
3874else
3875 cat >conftest.$ac_ext <<_ACEOF
3876#line 3876 "configure"
3877#include "confdefs.h"
3878#include <sys/types.h>
3879#include <sys/ioctl.h>
3880#ifdef TIOCGWINSZ
3881 yes
3882#endif
3883
3884_ACEOF
3885if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3886 egrep "yes" >/dev/null 2>&1; then
3887 ac_cv_sys_tiocgwinsz_in_sys_ioctl_h=yes
3888else
3889 ac_cv_sys_tiocgwinsz_in_sys_ioctl_h=no
d60d9f65 3890fi
9255ee31 3891rm -f conftest*
d60d9f65
SS
3892
3893fi
9255ee31
EZ
3894echo "$as_me:3894: result: $ac_cv_sys_tiocgwinsz_in_sys_ioctl_h" >&5
3895echo "${ECHO_T}$ac_cv_sys_tiocgwinsz_in_sys_ioctl_h" >&6
d60d9f65 3896
9255ee31
EZ
3897 if test $ac_cv_sys_tiocgwinsz_in_sys_ioctl_h = yes; then
3898
3899cat >>confdefs.h <<\EOF
3900#define GWINSZ_IN_SYS_IOCTL 1
d60d9f65
SS
3901EOF
3902
9255ee31 3903 fi
d60d9f65
SS
3904fi
3905
9255ee31
EZ
3906echo "$as_me:3906: checking whether signal handlers are of type void" >&5
3907echo $ECHO_N "checking whether signal handlers are of type void... $ECHO_C" >&6
3908if test "${bash_cv_void_sighandler+set}" = set; then
3909 echo $ECHO_N "(cached) $ECHO_C" >&6
d60d9f65 3910else
9255ee31
EZ
3911 cat >conftest.$ac_ext <<_ACEOF
3912#line 3912 "configure"
d60d9f65
SS
3913#include "confdefs.h"
3914#include <sys/types.h>
3915#include <signal.h>
3916#ifdef signal
3917#undef signal
3918#endif
3919#ifdef __cplusplus
3920extern "C"
3921#endif
3922void (*signal ()) ();
9255ee31
EZ
3923int
3924main ()
3925{
d60d9f65 3926int i;
9255ee31
EZ
3927 ;
3928 return 0;
3929}
3930_ACEOF
3931rm -f conftest.$ac_objext
3932if { (eval echo "$as_me:3932: \"$ac_compile\"") >&5
3933 (eval $ac_compile) 2>&5
3934 ac_status=$?
3935 echo "$as_me:3935: \$? = $ac_status" >&5
3936 (exit $ac_status); } &&
3937 { ac_try='test -s conftest.$ac_objext'
3938 { (eval echo "$as_me:3938: \"$ac_try\"") >&5
3939 (eval $ac_try) 2>&5
3940 ac_status=$?
3941 echo "$as_me:3941: \$? = $ac_status" >&5
3942 (exit $ac_status); }; }; then
d60d9f65
SS
3943 bash_cv_void_sighandler=yes
3944else
9255ee31
EZ
3945 echo "$as_me: failed program was:" >&5
3946cat conftest.$ac_ext >&5
3947bash_cv_void_sighandler=no
d60d9f65 3948fi
9255ee31 3949rm -f conftest.$ac_objext conftest.$ac_ext
d60d9f65 3950fi
9255ee31
EZ
3951echo "$as_me:3951: result: $bash_cv_void_sighandler" >&5
3952echo "${ECHO_T}$bash_cv_void_sighandler" >&6
d60d9f65 3953if test $bash_cv_void_sighandler = yes; then
9255ee31 3954cat >>confdefs.h <<\EOF
d60d9f65
SS
3955#define VOID_SIGHANDLER 1
3956EOF
3957
3958fi
3959
9255ee31
EZ
3960echo "$as_me:3960: checking for TIOCSTAT in sys/ioctl.h" >&5
3961echo $ECHO_N "checking for TIOCSTAT in sys/ioctl.h... $ECHO_C" >&6
3962if test "${bash_cv_tiocstat_in_ioctl+set}" = set; then
3963 echo $ECHO_N "(cached) $ECHO_C" >&6
d60d9f65 3964else
9255ee31
EZ
3965 cat >conftest.$ac_ext <<_ACEOF
3966#line 3966 "configure"
d60d9f65
SS
3967#include "confdefs.h"
3968#include <sys/types.h>
3969#include <sys/ioctl.h>
9255ee31
EZ
3970int
3971main ()
3972{
d60d9f65 3973int x = TIOCSTAT;
9255ee31
EZ
3974 ;
3975 return 0;
3976}
3977_ACEOF
3978rm -f conftest.$ac_objext
3979if { (eval echo "$as_me:3979: \"$ac_compile\"") >&5
3980 (eval $ac_compile) 2>&5
3981 ac_status=$?
3982 echo "$as_me:3982: \$? = $ac_status" >&5
3983 (exit $ac_status); } &&
3984 { ac_try='test -s conftest.$ac_objext'
3985 { (eval echo "$as_me:3985: \"$ac_try\"") >&5
3986 (eval $ac_try) 2>&5
3987 ac_status=$?
3988 echo "$as_me:3988: \$? = $ac_status" >&5
3989 (exit $ac_status); }; }; then
d60d9f65
SS
3990 bash_cv_tiocstat_in_ioctl=yes
3991else
9255ee31
EZ
3992 echo "$as_me: failed program was:" >&5
3993cat conftest.$ac_ext >&5
3994bash_cv_tiocstat_in_ioctl=no
d60d9f65 3995fi
9255ee31 3996rm -f conftest.$ac_objext conftest.$ac_ext
d60d9f65
SS
3997fi
3998
9255ee31
EZ
3999echo "$as_me:3999: result: $bash_cv_tiocstat_in_ioctl" >&5
4000echo "${ECHO_T}$bash_cv_tiocstat_in_ioctl" >&6
4001if test $bash_cv_tiocstat_in_ioctl = yes; then
4002cat >>confdefs.h <<\EOF
d60d9f65
SS
4003#define TIOCSTAT_IN_SYS_IOCTL 1
4004EOF
4005
4006fi
4007
9255ee31
EZ
4008echo "$as_me:4008: checking for FIONREAD in sys/ioctl.h" >&5
4009echo $ECHO_N "checking for FIONREAD in sys/ioctl.h... $ECHO_C" >&6
4010if test "${bash_cv_fionread_in_ioctl+set}" = set; then
4011 echo $ECHO_N "(cached) $ECHO_C" >&6
d60d9f65 4012else
9255ee31
EZ
4013 cat >conftest.$ac_ext <<_ACEOF
4014#line 4014 "configure"
d60d9f65
SS
4015#include "confdefs.h"
4016#include <sys/types.h>
4017#include <sys/ioctl.h>
9255ee31
EZ
4018int
4019main ()
4020{
d60d9f65 4021int x = FIONREAD;
9255ee31
EZ
4022 ;
4023 return 0;
4024}
4025_ACEOF
4026rm -f conftest.$ac_objext
4027if { (eval echo "$as_me:4027: \"$ac_compile\"") >&5
4028 (eval $ac_compile) 2>&5
4029 ac_status=$?
4030 echo "$as_me:4030: \$? = $ac_status" >&5
4031 (exit $ac_status); } &&
4032 { ac_try='test -s conftest.$ac_objext'
4033 { (eval echo "$as_me:4033: \"$ac_try\"") >&5
4034 (eval $ac_try) 2>&5
4035 ac_status=$?
4036 echo "$as_me:4036: \$? = $ac_status" >&5
4037 (exit $ac_status); }; }; then
d60d9f65
SS
4038 bash_cv_fionread_in_ioctl=yes
4039else
9255ee31
EZ
4040 echo "$as_me: failed program was:" >&5
4041cat conftest.$ac_ext >&5
4042bash_cv_fionread_in_ioctl=no
d60d9f65 4043fi
9255ee31 4044rm -f conftest.$ac_objext conftest.$ac_ext
d60d9f65
SS
4045fi
4046
9255ee31
EZ
4047echo "$as_me:4047: result: $bash_cv_fionread_in_ioctl" >&5
4048echo "${ECHO_T}$bash_cv_fionread_in_ioctl" >&6
4049if test $bash_cv_fionread_in_ioctl = yes; then
4050cat >>confdefs.h <<\EOF
d60d9f65
SS
4051#define FIONREAD_IN_SYS_IOCTL 1
4052EOF
4053
4054fi
4055
9255ee31
EZ
4056echo "$as_me:4056: checking for speed_t in sys/types.h" >&5
4057echo $ECHO_N "checking for speed_t in sys/types.h... $ECHO_C" >&6
4058if test "${bash_cv_speed_t_in_sys_types+set}" = set; then
4059 echo $ECHO_N "(cached) $ECHO_C" >&6
d60d9f65 4060else
9255ee31
EZ
4061 cat >conftest.$ac_ext <<_ACEOF
4062#line 4062 "configure"
d60d9f65
SS
4063#include "confdefs.h"
4064#include <sys/types.h>
9255ee31
EZ
4065int
4066main ()
4067{
d60d9f65 4068speed_t x;
9255ee31
EZ
4069 ;
4070 return 0;
4071}
4072_ACEOF
4073rm -f conftest.$ac_objext
4074if { (eval echo "$as_me:4074: \"$ac_compile\"") >&5
4075 (eval $ac_compile) 2>&5
4076 ac_status=$?
4077 echo "$as_me:4077: \$? = $ac_status" >&5
4078 (exit $ac_status); } &&
4079 { ac_try='test -s conftest.$ac_objext'
4080 { (eval echo "$as_me:4080: \"$ac_try\"") >&5
4081 (eval $ac_try) 2>&5
4082 ac_status=$?
4083 echo "$as_me:4083: \$? = $ac_status" >&5
4084 (exit $ac_status); }; }; then
d60d9f65
SS
4085 bash_cv_speed_t_in_sys_types=yes
4086else
9255ee31
EZ
4087 echo "$as_me: failed program was:" >&5
4088cat conftest.$ac_ext >&5
4089bash_cv_speed_t_in_sys_types=no
d60d9f65 4090fi
9255ee31 4091rm -f conftest.$ac_objext conftest.$ac_ext
d60d9f65
SS
4092fi
4093
9255ee31
EZ
4094echo "$as_me:4094: result: $bash_cv_speed_t_in_sys_types" >&5
4095echo "${ECHO_T}$bash_cv_speed_t_in_sys_types" >&6
4096if test $bash_cv_speed_t_in_sys_types = yes; then
4097cat >>confdefs.h <<\EOF
d60d9f65
SS
4098#define SPEED_T_IN_SYS_TYPES 1
4099EOF
4100
4101fi
4102
9255ee31
EZ
4103echo "$as_me:4103: checking for struct winsize in sys/ioctl.h and termios.h" >&5
4104echo $ECHO_N "checking for struct winsize in sys/ioctl.h and termios.h... $ECHO_C" >&6
4105if test "${bash_cv_struct_winsize_header+set}" = set; then
4106 echo $ECHO_N "(cached) $ECHO_C" >&6
d60d9f65 4107else
9255ee31
EZ
4108 cat >conftest.$ac_ext <<_ACEOF
4109#line 4109 "configure"
d60d9f65
SS
4110#include "confdefs.h"
4111#include <sys/types.h>
4112#include <sys/ioctl.h>
9255ee31
EZ
4113int
4114main ()
4115{
d60d9f65 4116struct winsize x;
9255ee31
EZ
4117 ;
4118 return 0;
4119}
4120_ACEOF
4121rm -f conftest.$ac_objext
4122if { (eval echo "$as_me:4122: \"$ac_compile\"") >&5
4123 (eval $ac_compile) 2>&5
4124 ac_status=$?
4125 echo "$as_me:4125: \$? = $ac_status" >&5
4126 (exit $ac_status); } &&
4127 { ac_try='test -s conftest.$ac_objext'
4128 { (eval echo "$as_me:4128: \"$ac_try\"") >&5
4129 (eval $ac_try) 2>&5
4130 ac_status=$?
4131 echo "$as_me:4131: \$? = $ac_status" >&5
4132 (exit $ac_status); }; }; then
d60d9f65
SS
4133 bash_cv_struct_winsize_header=ioctl_h
4134else
9255ee31
EZ
4135 echo "$as_me: failed program was:" >&5
4136cat conftest.$ac_ext >&5
4137cat >conftest.$ac_ext <<_ACEOF
4138#line 4138 "configure"
d60d9f65
SS
4139#include "confdefs.h"
4140#include <sys/types.h>
4141#include <termios.h>
9255ee31
EZ
4142int
4143main ()
4144{
d60d9f65 4145struct winsize x;
9255ee31
EZ
4146 ;
4147 return 0;
4148}
4149_ACEOF
4150rm -f conftest.$ac_objext
4151if { (eval echo "$as_me:4151: \"$ac_compile\"") >&5
4152 (eval $ac_compile) 2>&5
4153 ac_status=$?
4154 echo "$as_me:4154: \$? = $ac_status" >&5
4155 (exit $ac_status); } &&
4156 { ac_try='test -s conftest.$ac_objext'
4157 { (eval echo "$as_me:4157: \"$ac_try\"") >&5
4158 (eval $ac_try) 2>&5
4159 ac_status=$?
4160 echo "$as_me:4160: \$? = $ac_status" >&5
4161 (exit $ac_status); }; }; then
d60d9f65
SS
4162 bash_cv_struct_winsize_header=termios_h
4163else
9255ee31
EZ
4164 echo "$as_me: failed program was:" >&5
4165cat conftest.$ac_ext >&5
4166bash_cv_struct_winsize_header=other
d60d9f65 4167fi
9255ee31 4168rm -f conftest.$ac_objext conftest.$ac_ext
d60d9f65
SS
4169
4170fi
9255ee31 4171rm -f conftest.$ac_objext conftest.$ac_ext
d60d9f65
SS
4172fi
4173
4174if test $bash_cv_struct_winsize_header = ioctl_h; then
9255ee31
EZ
4175 echo "$as_me:4175: result: sys/ioctl.h" >&5
4176echo "${ECHO_T}sys/ioctl.h" >&6
4177 cat >>confdefs.h <<\EOF
d60d9f65
SS
4178#define STRUCT_WINSIZE_IN_SYS_IOCTL 1
4179EOF
4180
4181elif test $bash_cv_struct_winsize_header = termios_h; then
9255ee31
EZ
4182 echo "$as_me:4182: result: termios.h" >&5
4183echo "${ECHO_T}termios.h" >&6
4184 cat >>confdefs.h <<\EOF
d60d9f65
SS
4185#define STRUCT_WINSIZE_IN_TERMIOS 1
4186EOF
4187
4188else
9255ee31
EZ
4189 echo "$as_me:4189: result: not found" >&5
4190echo "${ECHO_T}not found" >&6
d60d9f65
SS
4191fi
4192
9255ee31
EZ
4193echo "$as_me:4193: checking if struct dirent has a d_ino member" >&5
4194echo $ECHO_N "checking if struct dirent has a d_ino member... $ECHO_C" >&6
4195if test "${bash_cv_dirent_has_dino+set}" = set; then
4196 echo $ECHO_N "(cached) $ECHO_C" >&6
d60d9f65 4197else
9255ee31
EZ
4198 cat >conftest.$ac_ext <<_ACEOF
4199#line 4199 "configure"
d60d9f65
SS
4200#include "confdefs.h"
4201
4202#include <stdio.h>
4203#include <sys/types.h>
4204#ifdef HAVE_UNISTD_H
4205# include <unistd.h>
4206#endif /* HAVE_UNISTD_H */
4207#if defined(HAVE_DIRENT_H)
4208# include <dirent.h>
4209#else
4210# define dirent direct
4211# ifdef HAVE_SYS_NDIR_H
4212# include <sys/ndir.h>
4213# endif /* SYSNDIR */
4214# ifdef HAVE_SYS_DIR_H
4215# include <sys/dir.h>
4216# endif /* SYSDIR */
4217# ifdef HAVE_NDIR_H
4218# include <ndir.h>
4219# endif
4220#endif /* HAVE_DIRENT_H */
4221
9255ee31
EZ
4222int
4223main ()
4224{
d60d9f65
SS
4225
4226struct dirent d; int z; z = d.d_ino;
4227
9255ee31
EZ
4228 ;
4229 return 0;
4230}
4231_ACEOF
4232rm -f conftest.$ac_objext
4233if { (eval echo "$as_me:4233: \"$ac_compile\"") >&5
4234 (eval $ac_compile) 2>&5
4235 ac_status=$?
4236 echo "$as_me:4236: \$? = $ac_status" >&5
4237 (exit $ac_status); } &&
4238 { ac_try='test -s conftest.$ac_objext'
4239 { (eval echo "$as_me:4239: \"$ac_try\"") >&5
4240 (eval $ac_try) 2>&5
4241 ac_status=$?
4242 echo "$as_me:4242: \$? = $ac_status" >&5
4243 (exit $ac_status); }; }; then
d60d9f65
SS
4244 bash_cv_dirent_has_dino=yes
4245else
9255ee31
EZ
4246 echo "$as_me: failed program was:" >&5
4247cat conftest.$ac_ext >&5
4248bash_cv_dirent_has_dino=no
d60d9f65 4249fi
9255ee31 4250rm -f conftest.$ac_objext conftest.$ac_ext
d60d9f65
SS
4251fi
4252
9255ee31
EZ
4253echo "$as_me:4253: result: $bash_cv_dirent_has_dino" >&5
4254echo "${ECHO_T}$bash_cv_dirent_has_dino" >&6
d60d9f65 4255if test $bash_cv_dirent_has_dino = yes; then
9255ee31 4256cat >>confdefs.h <<\EOF
d60d9f65
SS
4257#define STRUCT_DIRENT_HAS_D_INO 1
4258EOF
4259
4260fi
4261
9255ee31
EZ
4262echo "$as_me:4262: checking if struct dirent has a d_fileno member" >&5
4263echo $ECHO_N "checking if struct dirent has a d_fileno member... $ECHO_C" >&6
4264if test "${bash_cv_dirent_has_d_fileno+set}" = set; then
4265 echo $ECHO_N "(cached) $ECHO_C" >&6
d60d9f65 4266else
9255ee31
EZ
4267 cat >conftest.$ac_ext <<_ACEOF
4268#line 4268 "configure"
d60d9f65
SS
4269#include "confdefs.h"
4270
4271#include <stdio.h>
4272#include <sys/types.h>
4273#ifdef HAVE_UNISTD_H
4274# include <unistd.h>
4275#endif /* HAVE_UNISTD_H */
4276#if defined(HAVE_DIRENT_H)
4277# include <dirent.h>
4278#else
4279# define dirent direct
4280# ifdef HAVE_SYS_NDIR_H
4281# include <sys/ndir.h>
4282# endif /* SYSNDIR */
4283# ifdef HAVE_SYS_DIR_H
4284# include <sys/dir.h>
4285# endif /* SYSDIR */
4286# ifdef HAVE_NDIR_H
4287# include <ndir.h>
4288# endif
4289#endif /* HAVE_DIRENT_H */
4290
9255ee31
EZ
4291int
4292main ()
4293{
d60d9f65
SS
4294
4295struct dirent d; int z; z = d.d_fileno;
4296
9255ee31
EZ
4297 ;
4298 return 0;
4299}
4300_ACEOF
4301rm -f conftest.$ac_objext
4302if { (eval echo "$as_me:4302: \"$ac_compile\"") >&5
4303 (eval $ac_compile) 2>&5
4304 ac_status=$?
4305 echo "$as_me:4305: \$? = $ac_status" >&5
4306 (exit $ac_status); } &&
4307 { ac_try='test -s conftest.$ac_objext'
4308 { (eval echo "$as_me:4308: \"$ac_try\"") >&5
4309 (eval $ac_try) 2>&5
4310 ac_status=$?
4311 echo "$as_me:4311: \$? = $ac_status" >&5
4312 (exit $ac_status); }; }; then
d60d9f65
SS
4313 bash_cv_dirent_has_d_fileno=yes
4314else
9255ee31
EZ
4315 echo "$as_me: failed program was:" >&5
4316cat conftest.$ac_ext >&5
4317bash_cv_dirent_has_d_fileno=no
d60d9f65 4318fi
9255ee31 4319rm -f conftest.$ac_objext conftest.$ac_ext
d60d9f65
SS
4320fi
4321
9255ee31
EZ
4322echo "$as_me:4322: result: $bash_cv_dirent_has_d_fileno" >&5
4323echo "${ECHO_T}$bash_cv_dirent_has_d_fileno" >&6
d60d9f65 4324if test $bash_cv_dirent_has_d_fileno = yes; then
9255ee31 4325cat >>confdefs.h <<\EOF
d60d9f65
SS
4326#define STRUCT_DIRENT_HAS_D_FILENO 1
4327EOF
4328
4329fi
4330
d60d9f65
SS
4331case "$host_os" in
4332aix*) prefer_curses=yes ;;
4333esac
4334
4335if test "X$bash_cv_termcap_lib" = "X"; then
4336_bash_needmsg=yes
4337else
9255ee31
EZ
4338echo "$as_me:4338: checking which library has the termcap functions" >&5
4339echo $ECHO_N "checking which library has the termcap functions... $ECHO_C" >&6
d60d9f65
SS
4340_bash_needmsg=
4341fi
9255ee31
EZ
4342if test "${bash_cv_termcap_lib+set}" = set; then
4343 echo $ECHO_N "(cached) $ECHO_C" >&6
d60d9f65 4344else
9255ee31
EZ
4345 echo "$as_me:4345: checking for tgetent in -ltermcap" >&5
4346echo $ECHO_N "checking for tgetent in -ltermcap... $ECHO_C" >&6
4347if test "${ac_cv_lib_termcap_tgetent+set}" = set; then
4348 echo $ECHO_N "(cached) $ECHO_C" >&6
d60d9f65 4349else
9255ee31 4350 ac_check_lib_save_LIBS=$LIBS
d60d9f65 4351LIBS="-ltermcap $LIBS"
9255ee31
EZ
4352cat >conftest.$ac_ext <<_ACEOF
4353#line 4353 "configure"
4354#include "confdefs.h"
4355
4356/* Override any gcc2 internal prototype to avoid an error. */
4357#ifdef __cplusplus
4358extern "C"
4359#endif
4360/* We use char because int might match the return type of a gcc2
4361 builtin and then its argument prototype would still apply. */
4362char tgetent ();
4363int
4364main ()
4365{
4366tgetent ();
4367 ;
4368 return 0;
4369}
4370_ACEOF
4371rm -f conftest.$ac_objext conftest$ac_exeext
4372if { (eval echo "$as_me:4372: \"$ac_link\"") >&5
4373 (eval $ac_link) 2>&5
4374 ac_status=$?
4375 echo "$as_me:4375: \$? = $ac_status" >&5
4376 (exit $ac_status); } &&
4377 { ac_try='test -s conftest$ac_exeext'
4378 { (eval echo "$as_me:4378: \"$ac_try\"") >&5
4379 (eval $ac_try) 2>&5
4380 ac_status=$?
4381 echo "$as_me:4381: \$? = $ac_status" >&5
4382 (exit $ac_status); }; }; then
4383 ac_cv_lib_termcap_tgetent=yes
4384else
4385 echo "$as_me: failed program was:" >&5
4386cat conftest.$ac_ext >&5
4387ac_cv_lib_termcap_tgetent=no
4388fi
4389rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4390LIBS=$ac_check_lib_save_LIBS
4391fi
4392echo "$as_me:4392: result: $ac_cv_lib_termcap_tgetent" >&5
4393echo "${ECHO_T}$ac_cv_lib_termcap_tgetent" >&6
4394if test $ac_cv_lib_termcap_tgetent = yes; then
4395 bash_cv_termcap_lib=libtermcap
4396else
4397 echo "$as_me:4397: checking for tgetent in -ltinfo" >&5
4398echo $ECHO_N "checking for tgetent in -ltinfo... $ECHO_C" >&6
4399if test "${ac_cv_lib_tinfo_tgetent+set}" = set; then
4400 echo $ECHO_N "(cached) $ECHO_C" >&6
4401else
4402 ac_check_lib_save_LIBS=$LIBS
4403LIBS="-ltinfo $LIBS"
4404cat >conftest.$ac_ext <<_ACEOF
4405#line 4405 "configure"
4406#include "confdefs.h"
4407
4408/* Override any gcc2 internal prototype to avoid an error. */
4409#ifdef __cplusplus
4410extern "C"
4411#endif
4412/* We use char because int might match the return type of a gcc2
4413 builtin and then its argument prototype would still apply. */
4414char tgetent ();
4415int
4416main ()
4417{
4418tgetent ();
4419 ;
4420 return 0;
4421}
4422_ACEOF
4423rm -f conftest.$ac_objext conftest$ac_exeext
4424if { (eval echo "$as_me:4424: \"$ac_link\"") >&5
4425 (eval $ac_link) 2>&5
4426 ac_status=$?
4427 echo "$as_me:4427: \$? = $ac_status" >&5
4428 (exit $ac_status); } &&
4429 { ac_try='test -s conftest$ac_exeext'
4430 { (eval echo "$as_me:4430: \"$ac_try\"") >&5
4431 (eval $ac_try) 2>&5
4432 ac_status=$?
4433 echo "$as_me:4433: \$? = $ac_status" >&5
4434 (exit $ac_status); }; }; then
4435 ac_cv_lib_tinfo_tgetent=yes
4436else
4437 echo "$as_me: failed program was:" >&5
4438cat conftest.$ac_ext >&5
4439ac_cv_lib_tinfo_tgetent=no
4440fi
4441rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4442LIBS=$ac_check_lib_save_LIBS
4443fi
4444echo "$as_me:4444: result: $ac_cv_lib_tinfo_tgetent" >&5
4445echo "${ECHO_T}$ac_cv_lib_tinfo_tgetent" >&6
4446if test $ac_cv_lib_tinfo_tgetent = yes; then
4447 bash_cv_termcap_lib=libtinfo
4448else
4449 echo "$as_me:4449: checking for tgetent in -lcurses" >&5
4450echo $ECHO_N "checking for tgetent in -lcurses... $ECHO_C" >&6
4451if test "${ac_cv_lib_curses_tgetent+set}" = set; then
4452 echo $ECHO_N "(cached) $ECHO_C" >&6
4453else
4454 ac_check_lib_save_LIBS=$LIBS
4455LIBS="-lcurses $LIBS"
4456cat >conftest.$ac_ext <<_ACEOF
4457#line 4457 "configure"
4458#include "confdefs.h"
4459
4460/* Override any gcc2 internal prototype to avoid an error. */
4461#ifdef __cplusplus
4462extern "C"
4463#endif
4464/* We use char because int might match the return type of a gcc2
4465 builtin and then its argument prototype would still apply. */
4466char tgetent ();
4467int
4468main ()
4469{
4470tgetent ();
4471 ;
4472 return 0;
4473}
4474_ACEOF
4475rm -f conftest.$ac_objext conftest$ac_exeext
4476if { (eval echo "$as_me:4476: \"$ac_link\"") >&5
4477 (eval $ac_link) 2>&5
4478 ac_status=$?
4479 echo "$as_me:4479: \$? = $ac_status" >&5
4480 (exit $ac_status); } &&
4481 { ac_try='test -s conftest$ac_exeext'
4482 { (eval echo "$as_me:4482: \"$ac_try\"") >&5
4483 (eval $ac_try) 2>&5
4484 ac_status=$?
4485 echo "$as_me:4485: \$? = $ac_status" >&5
4486 (exit $ac_status); }; }; then
4487 ac_cv_lib_curses_tgetent=yes
4488else
4489 echo "$as_me: failed program was:" >&5
4490cat conftest.$ac_ext >&5
4491ac_cv_lib_curses_tgetent=no
4492fi
4493rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4494LIBS=$ac_check_lib_save_LIBS
4495fi
4496echo "$as_me:4496: result: $ac_cv_lib_curses_tgetent" >&5
4497echo "${ECHO_T}$ac_cv_lib_curses_tgetent" >&6
4498if test $ac_cv_lib_curses_tgetent = yes; then
4499 bash_cv_termcap_lib=libcurses
4500else
4501 echo "$as_me:4501: checking for tgetent in -lncurses" >&5
4502echo $ECHO_N "checking for tgetent in -lncurses... $ECHO_C" >&6
4503if test "${ac_cv_lib_ncurses_tgetent+set}" = set; then
4504 echo $ECHO_N "(cached) $ECHO_C" >&6
4505else
4506 ac_check_lib_save_LIBS=$LIBS
4507LIBS="-lncurses $LIBS"
4508cat >conftest.$ac_ext <<_ACEOF
4509#line 4509 "configure"
4510#include "confdefs.h"
4511
4512/* Override any gcc2 internal prototype to avoid an error. */
4513#ifdef __cplusplus
4514extern "C"
4515#endif
4516/* We use char because int might match the return type of a gcc2
4517 builtin and then its argument prototype would still apply. */
4518char tgetent ();
4519int
4520main ()
4521{
4522tgetent ();
4523 ;
4524 return 0;
4525}
4526_ACEOF
4527rm -f conftest.$ac_objext conftest$ac_exeext
4528if { (eval echo "$as_me:4528: \"$ac_link\"") >&5
4529 (eval $ac_link) 2>&5
4530 ac_status=$?
4531 echo "$as_me:4531: \$? = $ac_status" >&5
4532 (exit $ac_status); } &&
4533 { ac_try='test -s conftest$ac_exeext'
4534 { (eval echo "$as_me:4534: \"$ac_try\"") >&5
4535 (eval $ac_try) 2>&5
4536 ac_status=$?
4537 echo "$as_me:4537: \$? = $ac_status" >&5
4538 (exit $ac_status); }; }; then
4539 ac_cv_lib_ncurses_tgetent=yes
4540else
4541 echo "$as_me: failed program was:" >&5
4542cat conftest.$ac_ext >&5
4543ac_cv_lib_ncurses_tgetent=no
4544fi
4545rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4546LIBS=$ac_check_lib_save_LIBS
4547fi
4548echo "$as_me:4548: result: $ac_cv_lib_ncurses_tgetent" >&5
4549echo "${ECHO_T}$ac_cv_lib_ncurses_tgetent" >&6
4550if test $ac_cv_lib_ncurses_tgetent = yes; then
4551 bash_cv_termcap_lib=libncurses
4552else
4553 bash_cv_termcap_lib=gnutermcap
4554fi
4555
4556fi
4557
4558fi
4559
4560fi
4561
4562fi
4563
4564if test "X$_bash_needmsg" = "Xyes"; then
4565echo "$as_me:4565: checking which library has the termcap functions" >&5
4566echo $ECHO_N "checking which library has the termcap functions... $ECHO_C" >&6
4567fi
4568echo "$as_me:4568: result: using $bash_cv_termcap_lib" >&5
4569echo "${ECHO_T}using $bash_cv_termcap_lib" >&6
4570if test $bash_cv_termcap_lib = gnutermcap && test -z "$prefer_curses"; then
4571LDFLAGS="$LDFLAGS -L./lib/termcap"
4572TERMCAP_LIB="./lib/termcap/libtermcap.a"
4573TERMCAP_DEP="./lib/termcap/libtermcap.a"
4574elif test $bash_cv_termcap_lib = libtermcap && test -z "$prefer_curses"; then
4575TERMCAP_LIB=-ltermcap
4576TERMCAP_DEP=
4577elif test $bash_cv_termcap_lib = libtinfo; then
4578TERMCAP_LIB=-ltinfo
4579TERMCAP_DEP=
4580elif test $bash_cv_termcap_lib = libncurses; then
4581TERMCAP_LIB=-lncurses
4582TERMCAP_DEP=
4583else
4584TERMCAP_LIB=-lcurses
4585TERMCAP_DEP=
4586fi
4587
4588if test "$TERMCAP_LIB" = "./lib/termcap/libtermcap.a"; then
4589 if test "$prefer_curses" = yes; then
4590 TERMCAP_LIB=-lcurses
4591 else
4592 TERMCAP_LIB=-ltermcap #default
4593 fi
4594fi
4595
4596for ac_header in wctype.h
4597do
4598as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
4599echo "$as_me:4599: checking for $ac_header" >&5
4600echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4601if eval "test \"\${$as_ac_Header+set}\" = set"; then
4602 echo $ECHO_N "(cached) $ECHO_C" >&6
4603else
4604 cat >conftest.$ac_ext <<_ACEOF
4605#line 4605 "configure"
4606#include "confdefs.h"
4607#include <$ac_header>
4608_ACEOF
4609if { (eval echo "$as_me:4609: \"$ac_cpp conftest.$ac_ext\"") >&5
4610 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4611 ac_status=$?
4612 egrep -v '^ *\+' conftest.er1 >conftest.err
4613 rm -f conftest.er1
4614 cat conftest.err >&5
4615 echo "$as_me:4615: \$? = $ac_status" >&5
4616 (exit $ac_status); } >/dev/null; then
4617 if test -s conftest.err; then
4618 ac_cpp_err=$ac_c_preproc_warn_flag
4619 else
4620 ac_cpp_err=
4621 fi
4622else
4623 ac_cpp_err=yes
4624fi
4625if test -z "$ac_cpp_err"; then
4626 eval "$as_ac_Header=yes"
4627else
4628 echo "$as_me: failed program was:" >&5
4629 cat conftest.$ac_ext >&5
4630 eval "$as_ac_Header=no"
4631fi
4632rm -f conftest.err conftest.$ac_ext
4633fi
4634echo "$as_me:4634: result: `eval echo '${'$as_ac_Header'}'`" >&5
4635echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4636if test `eval echo '${'$as_ac_Header'}'` = yes; then
4637 cat >>confdefs.h <<EOF
4638#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
4639EOF
4640
4641fi
4642done
4643
4644for ac_header in wchar.h
4645do
4646as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
4647echo "$as_me:4647: checking for $ac_header" >&5
4648echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4649if eval "test \"\${$as_ac_Header+set}\" = set"; then
4650 echo $ECHO_N "(cached) $ECHO_C" >&6
4651else
4652 cat >conftest.$ac_ext <<_ACEOF
4653#line 4653 "configure"
4654#include "confdefs.h"
4655#include <$ac_header>
4656_ACEOF
4657if { (eval echo "$as_me:4657: \"$ac_cpp conftest.$ac_ext\"") >&5
4658 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4659 ac_status=$?
4660 egrep -v '^ *\+' conftest.er1 >conftest.err
4661 rm -f conftest.er1
4662 cat conftest.err >&5
4663 echo "$as_me:4663: \$? = $ac_status" >&5
4664 (exit $ac_status); } >/dev/null; then
4665 if test -s conftest.err; then
4666 ac_cpp_err=$ac_c_preproc_warn_flag
4667 else
4668 ac_cpp_err=
4669 fi
4670else
4671 ac_cpp_err=yes
4672fi
4673if test -z "$ac_cpp_err"; then
4674 eval "$as_ac_Header=yes"
4675else
4676 echo "$as_me: failed program was:" >&5
4677 cat conftest.$ac_ext >&5
4678 eval "$as_ac_Header=no"
4679fi
4680rm -f conftest.err conftest.$ac_ext
4681fi
4682echo "$as_me:4682: result: `eval echo '${'$as_ac_Header'}'`" >&5
4683echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4684if test `eval echo '${'$as_ac_Header'}'` = yes; then
4685 cat >>confdefs.h <<EOF
4686#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
4687EOF
4688
4689fi
4690done
4691
4692for ac_header in langinfo.h
4693do
4694as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
4695echo "$as_me:4695: checking for $ac_header" >&5
4696echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4697if eval "test \"\${$as_ac_Header+set}\" = set"; then
4698 echo $ECHO_N "(cached) $ECHO_C" >&6
4699else
4700 cat >conftest.$ac_ext <<_ACEOF
4701#line 4701 "configure"
4702#include "confdefs.h"
4703#include <$ac_header>
4704_ACEOF
4705if { (eval echo "$as_me:4705: \"$ac_cpp conftest.$ac_ext\"") >&5
4706 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4707 ac_status=$?
4708 egrep -v '^ *\+' conftest.er1 >conftest.err
4709 rm -f conftest.er1
4710 cat conftest.err >&5
4711 echo "$as_me:4711: \$? = $ac_status" >&5
4712 (exit $ac_status); } >/dev/null; then
4713 if test -s conftest.err; then
4714 ac_cpp_err=$ac_c_preproc_warn_flag
4715 else
4716 ac_cpp_err=
4717 fi
4718else
4719 ac_cpp_err=yes
4720fi
4721if test -z "$ac_cpp_err"; then
4722 eval "$as_ac_Header=yes"
4723else
4724 echo "$as_me: failed program was:" >&5
4725 cat conftest.$ac_ext >&5
4726 eval "$as_ac_Header=no"
4727fi
4728rm -f conftest.err conftest.$ac_ext
4729fi
4730echo "$as_me:4730: result: `eval echo '${'$as_ac_Header'}'`" >&5
4731echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4732if test `eval echo '${'$as_ac_Header'}'` = yes; then
4733 cat >>confdefs.h <<EOF
4734#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
4735EOF
4736
4737fi
4738done
4739
4740echo "$as_me:4740: checking for mbsrtowcs" >&5
4741echo $ECHO_N "checking for mbsrtowcs... $ECHO_C" >&6
4742if test "${ac_cv_func_mbsrtowcs+set}" = set; then
4743 echo $ECHO_N "(cached) $ECHO_C" >&6
4744else
4745 cat >conftest.$ac_ext <<_ACEOF
4746#line 4746 "configure"
d60d9f65 4747#include "confdefs.h"
9255ee31
EZ
4748/* System header to define __stub macros and hopefully few prototypes,
4749 which can conflict with char mbsrtowcs (); below. */
4750#include <assert.h>
d60d9f65 4751/* Override any gcc2 internal prototype to avoid an error. */
9255ee31
EZ
4752#ifdef __cplusplus
4753extern "C"
4754#endif
d60d9f65 4755/* We use char because int might match the return type of a gcc2
9255ee31
EZ
4756 builtin and then its argument prototype would still apply. */
4757char mbsrtowcs ();
4758char (*f) ();
4759
4760int
4761main ()
4762{
4763/* The GNU C library defines this for functions which it implements
4764 to always fail with ENOSYS. Some functions are actually named
4765 something starting with __ and the normal name is an alias. */
4766#if defined (__stub_mbsrtowcs) || defined (__stub___mbsrtowcs)
4767choke me
4768#else
4769f = mbsrtowcs;
4770#endif
d60d9f65 4771
9255ee31
EZ
4772 ;
4773 return 0;
4774}
4775_ACEOF
4776rm -f conftest.$ac_objext conftest$ac_exeext
4777if { (eval echo "$as_me:4777: \"$ac_link\"") >&5
4778 (eval $ac_link) 2>&5
4779 ac_status=$?
4780 echo "$as_me:4780: \$? = $ac_status" >&5
4781 (exit $ac_status); } &&
4782 { ac_try='test -s conftest$ac_exeext'
4783 { (eval echo "$as_me:4783: \"$ac_try\"") >&5
4784 (eval $ac_try) 2>&5
4785 ac_status=$?
4786 echo "$as_me:4786: \$? = $ac_status" >&5
4787 (exit $ac_status); }; }; then
4788 ac_cv_func_mbsrtowcs=yes
d60d9f65 4789else
9255ee31
EZ
4790 echo "$as_me: failed program was:" >&5
4791cat conftest.$ac_ext >&5
4792ac_cv_func_mbsrtowcs=no
d60d9f65 4793fi
9255ee31
EZ
4794rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4795fi
4796echo "$as_me:4796: result: $ac_cv_func_mbsrtowcs" >&5
4797echo "${ECHO_T}$ac_cv_func_mbsrtowcs" >&6
4798if test $ac_cv_func_mbsrtowcs = yes; then
4799 cat >>confdefs.h <<\EOF
4800#define HAVE_MBSRTOWCS 1
4801EOF
d60d9f65
SS
4802
4803fi
9255ee31
EZ
4804
4805echo "$as_me:4805: checking for wcwidth" >&5
4806echo $ECHO_N "checking for wcwidth... $ECHO_C" >&6
4807if test "${ac_cv_func_wcwidth+set}" = set; then
4808 echo $ECHO_N "(cached) $ECHO_C" >&6
d60d9f65 4809else
9255ee31
EZ
4810 cat >conftest.$ac_ext <<_ACEOF
4811#line 4811 "configure"
d60d9f65 4812#include "confdefs.h"
9255ee31
EZ
4813/* System header to define __stub macros and hopefully few prototypes,
4814 which can conflict with char wcwidth (); below. */
4815#include <assert.h>
d60d9f65 4816/* Override any gcc2 internal prototype to avoid an error. */
9255ee31
EZ
4817#ifdef __cplusplus
4818extern "C"
4819#endif
d60d9f65 4820/* We use char because int might match the return type of a gcc2
9255ee31
EZ
4821 builtin and then its argument prototype would still apply. */
4822char wcwidth ();
4823char (*f) ();
d60d9f65 4824
9255ee31
EZ
4825int
4826main ()
4827{
4828/* The GNU C library defines this for functions which it implements
4829 to always fail with ENOSYS. Some functions are actually named
4830 something starting with __ and the normal name is an alias. */
4831#if defined (__stub_wcwidth) || defined (__stub___wcwidth)
4832choke me
4833#else
4834f = wcwidth;
4835#endif
4836
4837 ;
4838 return 0;
4839}
4840_ACEOF
4841rm -f conftest.$ac_objext conftest$ac_exeext
4842if { (eval echo "$as_me:4842: \"$ac_link\"") >&5
4843 (eval $ac_link) 2>&5
4844 ac_status=$?
4845 echo "$as_me:4845: \$? = $ac_status" >&5
4846 (exit $ac_status); } &&
4847 { ac_try='test -s conftest$ac_exeext'
4848 { (eval echo "$as_me:4848: \"$ac_try\"") >&5
4849 (eval $ac_try) 2>&5
4850 ac_status=$?
4851 echo "$as_me:4851: \$? = $ac_status" >&5
4852 (exit $ac_status); }; }; then
4853 ac_cv_func_wcwidth=yes
d60d9f65 4854else
9255ee31
EZ
4855 echo "$as_me: failed program was:" >&5
4856cat conftest.$ac_ext >&5
4857ac_cv_func_wcwidth=no
d60d9f65 4858fi
9255ee31
EZ
4859rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4860fi
4861echo "$as_me:4861: result: $ac_cv_func_wcwidth" >&5
4862echo "${ECHO_T}$ac_cv_func_wcwidth" >&6
4863if test $ac_cv_func_wcwidth = yes; then
4864 cat >>confdefs.h <<\EOF
4865#define HAVE_WCWIDTH 1
4866EOF
d60d9f65
SS
4867
4868fi
9255ee31
EZ
4869
4870echo "$as_me:4870: checking for mbstate_t" >&5
4871echo $ECHO_N "checking for mbstate_t... $ECHO_C" >&6
4872if test "${bash_cv_have_mbstate_t+set}" = set; then
4873 echo $ECHO_N "(cached) $ECHO_C" >&6
d60d9f65 4874else
9255ee31
EZ
4875 if test "$cross_compiling" = yes; then
4876 { { echo "$as_me:4876: error: cannot run test program while cross compiling" >&5
4877echo "$as_me: error: cannot run test program while cross compiling" >&2;}
4878 { (exit 1); exit 1; }; }
d60d9f65 4879else
9255ee31
EZ
4880 cat >conftest.$ac_ext <<_ACEOF
4881#line 4881 "configure"
d60d9f65 4882#include "confdefs.h"
d60d9f65 4883
9255ee31
EZ
4884#include <wchar.h>
4885int
4886main ()
4887{
4888 mbstate_t ps;
4889 return 0;
4890}
4891_ACEOF
4892rm -f conftest$ac_exeext
4893if { (eval echo "$as_me:4893: \"$ac_link\"") >&5
4894 (eval $ac_link) 2>&5
4895 ac_status=$?
4896 echo "$as_me:4896: \$? = $ac_status" >&5
4897 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4898 { (eval echo "$as_me:4898: \"$ac_try\"") >&5
4899 (eval $ac_try) 2>&5
4900 ac_status=$?
4901 echo "$as_me:4901: \$? = $ac_status" >&5
4902 (exit $ac_status); }; }; then
4903 bash_cv_have_mbstate_t=yes
d60d9f65 4904else
9255ee31
EZ
4905 echo "$as_me: program exited with status $ac_status" >&5
4906echo "$as_me: failed program was:" >&5
4907cat conftest.$ac_ext >&5
4908bash_cv_have_mbstate_t=no
d60d9f65 4909fi
9255ee31 4910rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
d60d9f65 4911fi
d60d9f65 4912fi
9255ee31
EZ
4913echo "$as_me:4913: result: $bash_cv_have_mbstate_t" >&5
4914echo "${ECHO_T}$bash_cv_have_mbstate_t" >&6
4915if test $bash_cv_have_mbstate_t = yes; then
4916 cat >>confdefs.h <<\EOF
4917#define HAVE_MBSTATE_T 1
4918EOF
d60d9f65
SS
4919
4920fi
4921
9255ee31
EZ
4922echo "$as_me:4922: checking for nl_langinfo and CODESET" >&5
4923echo $ECHO_N "checking for nl_langinfo and CODESET... $ECHO_C" >&6
4924if test "${bash_cv_langinfo_codeset+set}" = set; then
4925 echo $ECHO_N "(cached) $ECHO_C" >&6
d60d9f65 4926else
9255ee31
EZ
4927 cat >conftest.$ac_ext <<_ACEOF
4928#line 4928 "configure"
4929#include "confdefs.h"
4930#include <langinfo.h>
4931int
4932main ()
4933{
4934char* cs = nl_langinfo(CODESET);
4935 ;
4936 return 0;
4937}
4938_ACEOF
4939rm -f conftest.$ac_objext conftest$ac_exeext
4940if { (eval echo "$as_me:4940: \"$ac_link\"") >&5
4941 (eval $ac_link) 2>&5
4942 ac_status=$?
4943 echo "$as_me:4943: \$? = $ac_status" >&5
4944 (exit $ac_status); } &&
4945 { ac_try='test -s conftest$ac_exeext'
4946 { (eval echo "$as_me:4946: \"$ac_try\"") >&5
4947 (eval $ac_try) 2>&5
4948 ac_status=$?
4949 echo "$as_me:4949: \$? = $ac_status" >&5
4950 (exit $ac_status); }; }; then
4951 bash_cv_langinfo_codeset=yes
4952else
4953 echo "$as_me: failed program was:" >&5
4954cat conftest.$ac_ext >&5
4955bash_cv_langinfo_codeset=no
4956fi
4957rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
d60d9f65 4958fi
9255ee31
EZ
4959echo "$as_me:4959: result: $bash_cv_langinfo_codeset" >&5
4960echo "${ECHO_T}$bash_cv_langinfo_codeset" >&6
4961if test $bash_cv_langinfo_codeset = yes; then
4962 cat >>confdefs.h <<\EOF
4963#define HAVE_LANGINFO_CODESET 1
4964EOF
d60d9f65 4965
d60d9f65
SS
4966fi
4967
4968case "$host_cpu" in
4969*cray*) LOCAL_CFLAGS=-DCRAY ;;
9255ee31 4970*s390*) LOCAL_CFLAGS=-fsigned-char ;;
d60d9f65
SS
4971esac
4972
4973case "$host_os" in
4974isc*) LOCAL_CFLAGS=-Disc386 ;;
4975esac
4976
c862e87b
JM
4977# shared library configuration section
4978#
4979# Shared object configuration section. These values are generated by
4980# ${srcdir}/support/shobj-conf
4981#
4982if test -f ${srcdir}/support/shobj-conf; then
9255ee31
EZ
4983 echo "$as_me:4983: checking configuration for building shared libraries" >&5
4984echo $ECHO_N "checking configuration for building shared libraries... $ECHO_C" >&6
1b17e766 4985 eval `${CONFIG_SHELL-/bin/sh} ${srcdir}/support/shobj-conf -C "${CC}" -c ${host_cpu} -o ${host_os} -v ${host_vendor}`
9255ee31
EZ
4986
4987 echo "$as_me:4987: result: $SHLIB_STATUS" >&5
4988echo "${ECHO_T}$SHLIB_STATUS" >&6
4989
4990 # SHLIB_STATUS is either `supported' or `unsupported'. If it's
4991 # `unsupported', turn off any default shared library building
4992 if test "$SHLIB_STATUS" = 'unsupported'; then
4993 opt_shared_libs=no
4994 fi
1b17e766
EZ
4995
4996 # shared library versioning
4997 # quoted for m4 so I can use character classes
4998 SHLIB_MAJOR=`expr "$LIBVERSION" : '\([0-9]\)\..*'`
4999 SHLIB_MINOR=`expr "$LIBVERSION" : '[0-9]\.\([0-9]\).*'`
9255ee31
EZ
5000
5001fi
5002
5003if test "$opt_static_libs" = "yes"; then
5004 STATIC_TARGET=static
5005 STATIC_INSTALL_TARGET=install-static
5006fi
5007if test "$opt_shared_libs" = "yes"; then
5008 SHARED_TARGET=shared
5009 SHARED_INSTALL_TARGET=install-shared
c862e87b
JM
5010fi
5011
1b17e766
EZ
5012case "$host_os" in
5013msdosdjgpp*) BUILD_DIR=`pwd.exe` ;; # to prevent //d/path/file
5014*) BUILD_DIR=`pwd` ;;
5015esac
5016
9255ee31
EZ
5017ac_config_files="$ac_config_files Makefile doc/Makefile examples/Makefile shlib/Makefile"
5018ac_config_commands="$ac_config_commands default"
5019cat >confcache <<\_ACEOF
d60d9f65
SS
5020# This file is a shell script that caches the results of configure
5021# tests run on this system so they can be shared between configure
9255ee31
EZ
5022# scripts and configure runs, see configure's option --config-cache.
5023# It is not useful on other systems. If it contains results you don't
5024# want to keep, you may remove or edit it.
d60d9f65 5025#
9255ee31
EZ
5026# config.status only pays attention to the cache file if you give it
5027# the --recheck option to rerun configure.
d60d9f65 5028#
9255ee31
EZ
5029# `ac_cv_env_foo' variables (set or unset) will be overriden when
5030# loading this file, other *unset* `ac_cv_foo' will be assigned the
5031# following values.
5032
5033_ACEOF
5034
d60d9f65
SS
5035# The following way of writing the cache mishandles newlines in values,
5036# but we know of no workaround that is simple, portable, and efficient.
5037# So, don't put newlines in cache variables' values.
5038# Ultrix sh set writes to stderr and can't be redirected directly,
5039# and sets the high bit in the cache file unless we assign to the vars.
9255ee31
EZ
5040{
5041 (set) 2>&1 |
5042 case `(ac_space=' '; set | grep ac_space) 2>&1` in
5043 *ac_space=\ *)
5044 # `set' does not quote correctly, so add quotes (double-quote
5045 # substitution turns \\\\ into \\, and sed turns \\ into \).
5046 sed -n \
5047 "s/'/'\\\\''/g;
5048 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
5049 ;;
5050 *)
5051 # `set' quotes correctly as required by POSIX, so do not add quotes.
5052 sed -n \
5053 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
5054 ;;
5055 esac;
5056} |
5057 sed '
5058 t clear
5059 : clear
5060 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
5061 t end
5062 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
5063 : end' >>confcache
5064if cmp -s $cache_file confcache; then :; else
d60d9f65 5065 if test -w $cache_file; then
9255ee31
EZ
5066 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
5067 cat confcache >$cache_file
d60d9f65
SS
5068 else
5069 echo "not updating unwritable cache $cache_file"
5070 fi
5071fi
5072rm -f confcache
5073
d60d9f65
SS
5074test "x$prefix" = xNONE && prefix=$ac_default_prefix
5075# Let make expand exec_prefix.
5076test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
5077
9255ee31
EZ
5078# VPATH may cause trouble with some makes, so we remove $(srcdir),
5079# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
5080# trailing colons and then remove the whole line if VPATH becomes empty
5081# (actually we leave an empty line to preserve line numbers).
d60d9f65 5082if test "x$srcdir" = x.; then
9255ee31
EZ
5083 ac_vpsub='/^[ ]*VPATH[ ]*=/{
5084s/:*\$(srcdir):*/:/;
5085s/:*\${srcdir}:*/:/;
5086s/:*@srcdir@:*/:/;
5087s/^\([^=]*=[ ]*\):*/\1/;
5088s/:*$//;
5089s/^[^=]*=[ ]*$//;
5090}'
d60d9f65
SS
5091fi
5092
d60d9f65
SS
5093DEFS=-DHAVE_CONFIG_H
5094
d60d9f65 5095: ${CONFIG_STATUS=./config.status}
9255ee31
EZ
5096ac_clean_files_save=$ac_clean_files
5097ac_clean_files="$ac_clean_files $CONFIG_STATUS"
5098{ echo "$as_me:5098: creating $CONFIG_STATUS" >&5
5099echo "$as_me: creating $CONFIG_STATUS" >&6;}
5100cat >$CONFIG_STATUS <<_ACEOF
5101#! $SHELL
d60d9f65
SS
5102# Generated automatically by configure.
5103# Run this file to recreate the current configuration.
d60d9f65 5104# Compiler output produced by configure, useful for debugging
9255ee31 5105# configure, is in config.log if it exists.
d60d9f65 5106
9255ee31
EZ
5107debug=false
5108SHELL=\${CONFIG_SHELL-$SHELL}
5109ac_cs_invocation="\$0 \$@"
5110
5111_ACEOF
5112
5113cat >>$CONFIG_STATUS <<\_ACEOF
5114# Be Bourne compatible
5115if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
5116 emulate sh
5117 NULLCMD=:
5118elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
5119 set -o posix
5120fi
5121
5122# Name of the executable.
5123as_me=`echo "$0" |sed 's,.*[\\/],,'`
5124
5125if expr a : '\(a\)' >/dev/null 2>&1; then
5126 as_expr=expr
5127else
5128 as_expr=false
5129fi
5130
5131rm -f conf$$ conf$$.exe conf$$.file
5132echo >conf$$.file
5133if ln -s conf$$.file conf$$ 2>/dev/null; then
5134 # We could just check for DJGPP; but this test a) works b) is more generic
5135 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
5136 if test -f conf$$.exe; then
5137 # Don't use ln at all; we don't have any links
5138 as_ln_s='cp -p'
5139 else
5140 as_ln_s='ln -s'
5141 fi
5142elif ln conf$$.file conf$$ 2>/dev/null; then
5143 as_ln_s=ln
5144else
5145 as_ln_s='cp -p'
5146fi
5147rm -f conf$$ conf$$.exe conf$$.file
5148
5149as_executable_p="test -f"
5150
5151# Support unset when possible.
5152if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
5153 as_unset=unset
5154else
5155 as_unset=false
5156fi
5157
5158# NLS nuisances.
5159$as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
5160$as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
5161$as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
5162$as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
5163$as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
5164$as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
5165$as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
5166$as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
5167
5168# IFS
5169# We need space, tab and new line, in precisely that order.
5170as_nl='
5171'
5172IFS=" $as_nl"
5173
5174# CDPATH.
5175$as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
5176
5177exec 6>&1
5178
5179_ACEOF
5180
5181# Files that config.status was made for.
5182if test -n "$ac_config_files"; then
5183 echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
5184fi
5185
5186if test -n "$ac_config_headers"; then
5187 echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
5188fi
5189
5190if test -n "$ac_config_links"; then
5191 echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
5192fi
5193
5194if test -n "$ac_config_commands"; then
5195 echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
5196fi
5197
5198cat >>$CONFIG_STATUS <<\EOF
5199
5200ac_cs_usage="\
5201\`$as_me' instantiates files from templates according to the
5202current configuration.
5203
5204Usage: $0 [OPTIONS] [FILE]...
5205
5206 -h, --help print this help, then exit
5207 -V, --version print version number, then exit
5208 -d, --debug don't remove temporary files
5209 --recheck update $as_me by reconfiguring in the same conditions
5210 --file=FILE[:TEMPLATE]
5211 instantiate the configuration file FILE
5212 --header=FILE[:TEMPLATE]
5213 instantiate the configuration header FILE
5214
5215Configuration files:
5216$config_files
5217
5218Configuration headers:
5219$config_headers
5220
5221Configuration commands:
5222$config_commands
5223
5224Report bugs to <bug-autoconf@gnu.org>."
5225EOF
5226
5227cat >>$CONFIG_STATUS <<EOF
5228ac_cs_version="\\
5229readline config.status 4.3
5230configured by $0, generated by GNU Autoconf 2.52,
5231 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
5232
5233Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
5234Free Software Foundation, Inc.
5235This config.status script is free software; the Free Software Foundation
5236gives unlimited permission to copy, distribute and modify it."
5237srcdir=$srcdir
5238INSTALL="$INSTALL"
5239EOF
5240
5241cat >>$CONFIG_STATUS <<\EOF
5242# If no file are specified by the user, then we need to provide default
5243# value. By we need to know if files were specified by the user.
5244ac_need_defaults=:
5245while test $# != 0
d60d9f65 5246do
9255ee31
EZ
5247 case $1 in
5248 --*=*)
5249 ac_option=`expr "x$1" : 'x\([^=]*\)='`
5250 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
5251 shift
5252 set dummy "$ac_option" "$ac_optarg" ${1+"$@"}
5253 shift
5254 ;;
5255 -*);;
5256 *) # This is not an option, so the user has probably given explicit
5257 # arguments.
5258 ac_need_defaults=false;;
5259 esac
5260
5261 case $1 in
5262 # Handling of the options.
5263EOF
5264cat >>$CONFIG_STATUS <<EOF
d60d9f65 5265 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
9255ee31
EZ
5266 echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion"
5267 exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;;
5268EOF
5269cat >>$CONFIG_STATUS <<\EOF
5270 --version | --vers* | -V )
5271 echo "$ac_cs_version"; exit 0 ;;
5272 --he | --h)
5273 # Conflict between --help and --header
5274 { { echo "$as_me:5274: error: ambiguous option: $1
5275Try \`$0 --help' for more information." >&5
5276echo "$as_me: error: ambiguous option: $1
5277Try \`$0 --help' for more information." >&2;}
5278 { (exit 1); exit 1; }; };;
5279 --help | --hel | -h )
5280 echo "$ac_cs_usage"; exit 0 ;;
5281 --debug | --d* | -d )
5282 debug=: ;;
5283 --file | --fil | --fi | --f )
5284 shift
5285 CONFIG_FILES="$CONFIG_FILES $1"
5286 ac_need_defaults=false;;
5287 --header | --heade | --head | --hea )
5288 shift
5289 CONFIG_HEADERS="$CONFIG_HEADERS $1"
5290 ac_need_defaults=false;;
5291
5292 # This is an error.
5293 -*) { { echo "$as_me:5293: error: unrecognized option: $1
5294Try \`$0 --help' for more information." >&5
5295echo "$as_me: error: unrecognized option: $1
5296Try \`$0 --help' for more information." >&2;}
5297 { (exit 1); exit 1; }; } ;;
5298
5299 *) ac_config_targets="$ac_config_targets $1" ;;
5300
d60d9f65 5301 esac
9255ee31 5302 shift
d60d9f65
SS
5303done
5304
9255ee31
EZ
5305exec 5>>config.log
5306cat >&5 << _ACEOF
5307
5308## ----------------------- ##
5309## Running config.status. ##
5310## ----------------------- ##
5311
5312This file was extended by $as_me (readline 4.3) 2.52, executed with
5313 CONFIG_FILES = $CONFIG_FILES
5314 CONFIG_HEADERS = $CONFIG_HEADERS
5315 CONFIG_LINKS = $CONFIG_LINKS
5316 CONFIG_COMMANDS = $CONFIG_COMMANDS
5317 > $ac_cs_invocation
5318on `(hostname || uname -n) 2>/dev/null | sed 1q`
d60d9f65 5319
9255ee31 5320_ACEOF
d60d9f65 5321EOF
d60d9f65 5322
9255ee31
EZ
5323cat >>$CONFIG_STATUS <<\EOF
5324for ac_config_target in $ac_config_targets
5325do
5326 case "$ac_config_target" in
5327 # Handling of arguments.
5328 "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
5329 "doc/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/Makefile" ;;
5330 "examples/Makefile" ) CONFIG_FILES="$CONFIG_FILES examples/Makefile" ;;
5331 "shlib/Makefile" ) CONFIG_FILES="$CONFIG_FILES shlib/Makefile" ;;
5332 "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
5333 "config.h" ) CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;;
5334 *) { { echo "$as_me:5334: error: invalid argument: $ac_config_target" >&5
5335echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
5336 { (exit 1); exit 1; }; };;
5337 esac
5338done
5339
5340# If the user did not use the arguments to specify the items to instantiate,
5341# then the envvar interface is used. Set only those that are not.
5342# We use the long form for the default assignment because of an extremely
5343# bizarre bug on SunOS 4.1.3.
5344if $ac_need_defaults; then
5345 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
5346 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
5347 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
5348fi
5349
5350# Create a temporary directory, and hook for its removal unless debugging.
5351$debug ||
5352{
5353 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
5354 trap '{ (exit 1); exit 1; }' 1 2 13 15
5355}
5356
5357# Create a (secure) tmp directory for tmp files.
5358: ${TMPDIR=/tmp}
5359{
5360 tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` &&
5361 test -n "$tmp" && test -d "$tmp"
5362} ||
5363{
5364 tmp=$TMPDIR/cs$$-$RANDOM
5365 (umask 077 && mkdir $tmp)
5366} ||
5367{
5368 echo "$me: cannot create a temporary directory in $TMPDIR" >&2
5369 { (exit 1); exit 1; }
5370}
d60d9f65 5371
d60d9f65
SS
5372EOF
5373
9255ee31 5374cat >>$CONFIG_STATUS <<EOF
d60d9f65 5375
9255ee31
EZ
5376#
5377# CONFIG_FILES section.
5378#
5379
5380# No need to generate the scripts if there are no CONFIG_FILES.
5381# This happens for instance when ./config.status config.h
5382if test -n "\$CONFIG_FILES"; then
5383 # Protect against being on the right side of a sed subst in config.status.
5384 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
5385 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
5386s,@SHELL@,$SHELL,;t t
5387s,@exec_prefix@,$exec_prefix,;t t
5388s,@prefix@,$prefix,;t t
5389s,@program_transform_name@,$program_transform_name,;t t
5390s,@bindir@,$bindir,;t t
5391s,@sbindir@,$sbindir,;t t
5392s,@libexecdir@,$libexecdir,;t t
5393s,@datadir@,$datadir,;t t
5394s,@sysconfdir@,$sysconfdir,;t t
5395s,@sharedstatedir@,$sharedstatedir,;t t
5396s,@localstatedir@,$localstatedir,;t t
5397s,@libdir@,$libdir,;t t
5398s,@includedir@,$includedir,;t t
5399s,@oldincludedir@,$oldincludedir,;t t
5400s,@infodir@,$infodir,;t t
5401s,@mandir@,$mandir,;t t
5402s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
5403s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
5404s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
5405s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
5406s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
5407s,@build_alias@,$build_alias,;t t
5408s,@host_alias@,$host_alias,;t t
5409s,@target_alias@,$target_alias,;t t
5410s,@ECHO_C@,$ECHO_C,;t t
5411s,@ECHO_N@,$ECHO_N,;t t
5412s,@ECHO_T@,$ECHO_T,;t t
5413s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
5414s,@DEFS@,$DEFS,;t t
5415s,@LIBS@,$LIBS,;t t
5416s,@build@,$build,;t t
5417s,@build_cpu@,$build_cpu,;t t
5418s,@build_vendor@,$build_vendor,;t t
5419s,@build_os@,$build_os,;t t
5420s,@host@,$host,;t t
5421s,@host_cpu@,$host_cpu,;t t
5422s,@host_vendor@,$host_vendor,;t t
5423s,@host_os@,$host_os,;t t
5424s,@SET_MAKE@,$SET_MAKE,;t t
5425s,@CC@,$CC,;t t
5426s,@CFLAGS@,$CFLAGS,;t t
5427s,@LDFLAGS@,$LDFLAGS,;t t
5428s,@CPPFLAGS@,$CPPFLAGS,;t t
5429s,@ac_ct_CC@,$ac_ct_CC,;t t
5430s,@EXEEXT@,$EXEEXT,;t t
5431s,@OBJEXT@,$OBJEXT,;t t
5432s,@CPP@,$CPP,;t t
5433s,@CROSS_COMPILING_FLAG@,$CROSS_COMPILING_FLAG,;t t
5434s,@CC_FOR_BUILD@,$CC_FOR_BUILD,;t t
5435s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
5436s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
5437s,@INSTALL_DATA@,$INSTALL_DATA,;t t
5438s,@AR@,$AR,;t t
5439s,@RANLIB@,$RANLIB,;t t
5440s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
5441s,@MAKE_SHELL@,$MAKE_SHELL,;t t
5442s,@SHOBJ_CC@,$SHOBJ_CC,;t t
5443s,@SHOBJ_CFLAGS@,$SHOBJ_CFLAGS,;t t
5444s,@SHOBJ_LD@,$SHOBJ_LD,;t t
5445s,@SHOBJ_LDFLAGS@,$SHOBJ_LDFLAGS,;t t
5446s,@SHOBJ_XLDFLAGS@,$SHOBJ_XLDFLAGS,;t t
5447s,@SHOBJ_LIBS@,$SHOBJ_LIBS,;t t
5448s,@SHOBJ_STATUS@,$SHOBJ_STATUS,;t t
5449s,@SHLIB_STATUS@,$SHLIB_STATUS,;t t
5450s,@SHLIB_XLDFLAGS@,$SHLIB_XLDFLAGS,;t t
5451s,@SHLIB_LIBSUFF@,$SHLIB_LIBSUFF,;t t
5452s,@SHLIB_LIBVERSION@,$SHLIB_LIBVERSION,;t t
5453s,@SHLIB_LIBS@,$SHLIB_LIBS,;t t
5454s,@SHLIB_MAJOR@,$SHLIB_MAJOR,;t t
5455s,@SHLIB_MINOR@,$SHLIB_MINOR,;t t
5456s,@STATIC_TARGET@,$STATIC_TARGET,;t t
5457s,@SHARED_TARGET@,$SHARED_TARGET,;t t
5458s,@STATIC_INSTALL_TARGET@,$STATIC_INSTALL_TARGET,;t t
5459s,@SHARED_INSTALL_TARGET@,$SHARED_INSTALL_TARGET,;t t
5460s,@BUILD_DIR@,$BUILD_DIR,;t t
5461s,@LOCAL_CFLAGS@,$LOCAL_CFLAGS,;t t
5462s,@LOCAL_LDFLAGS@,$LOCAL_LDFLAGS,;t t
5463s,@LOCAL_DEFS@,$LOCAL_DEFS,;t t
5464s,@ARFLAGS@,$ARFLAGS,;t t
5465s,@LIBVERSION@,$LIBVERSION,;t t
5466s,@TERMCAP_LIB@,$TERMCAP_LIB,;t t
5467CEOF
5468
5469EOF
5470
5471 cat >>$CONFIG_STATUS <<\EOF
5472 # Split the substitutions into bite-sized pieces for seds with
5473 # small command number limits, like on Digital OSF/1 and HP-UX.
5474 ac_max_sed_lines=48
5475 ac_sed_frag=1 # Number of current file.
5476 ac_beg=1 # First line for current file.
5477 ac_end=$ac_max_sed_lines # Line after last line for current file.
5478 ac_more_lines=:
5479 ac_sed_cmds=
5480 while $ac_more_lines; do
5481 if test $ac_beg -gt 1; then
5482 sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
5483 else
5484 sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
5485 fi
5486 if test ! -s $tmp/subs.frag; then
5487 ac_more_lines=false
d60d9f65 5488 else
9255ee31
EZ
5489 # The purpose of the label and of the branching condition is to
5490 # speed up the sed processing (if there are no `@' at all, there
5491 # is no need to browse any of the substitutions).
5492 # These are the two extra sed commands mentioned above.
5493 (echo ':t
5494 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
5495 if test -z "$ac_sed_cmds"; then
5496 ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
5497 else
5498 ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
5499 fi
5500 ac_sed_frag=`expr $ac_sed_frag + 1`
5501 ac_beg=$ac_end
5502 ac_end=`expr $ac_end + $ac_max_sed_lines`
d60d9f65 5503 fi
9255ee31
EZ
5504 done
5505 if test -z "$ac_sed_cmds"; then
5506 ac_sed_cmds=cat
d60d9f65 5507 fi
9255ee31 5508fi # test -n "$CONFIG_FILES"
d60d9f65 5509
d60d9f65 5510EOF
9255ee31
EZ
5511cat >>$CONFIG_STATUS <<\EOF
5512for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
d60d9f65 5513 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
9255ee31
EZ
5514 case $ac_file in
5515 - | *:- | *:-:* ) # input from stdin
5516 cat >$tmp/stdin
5517 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
5518 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
5519 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
5520 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
5521 * ) ac_file_in=$ac_file.in ;;
d60d9f65
SS
5522 esac
5523
9255ee31
EZ
5524 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
5525 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
5526 X"$ac_file" : 'X\(//\)[^/]' \| \
5527 X"$ac_file" : 'X\(//\)$' \| \
5528 X"$ac_file" : 'X\(/\)' \| \
5529 . : '\(.\)' 2>/dev/null ||
5530echo X"$ac_file" |
5531 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
5532 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
5533 /^X\(\/\/\)$/{ s//\1/; q; }
5534 /^X\(\/\).*/{ s//\1/; q; }
5535 s/.*/./; q'`
d60d9f65 5536 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
9255ee31
EZ
5537 { case "$ac_dir" in
5538 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
5539 *) as_incr_dir=.;;
5540esac
5541as_dummy="$ac_dir"
5542for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
5543 case $as_mkdir_dir in
5544 # Skip DOS drivespec
5545 ?:) as_incr_dir=$as_mkdir_dir ;;
5546 *)
5547 as_incr_dir=$as_incr_dir/$as_mkdir_dir
5548 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
5549 ;;
5550 esac
5551done; }
5552
5553 ac_dir_suffix="/`echo $ac_dir|sed 's,^\./,,'`"
d60d9f65 5554 # A "../" for each directory in $ac_dir_suffix.
9255ee31 5555 ac_dots=`echo "$ac_dir_suffix" | sed 's,/[^/]*,../,g'`
d60d9f65
SS
5556 else
5557 ac_dir_suffix= ac_dots=
5558 fi
5559
9255ee31
EZ
5560 case $srcdir in
5561 .) ac_srcdir=.
5562 if test -z "$ac_dots"; then
5563 ac_top_srcdir=.
5564 else
5565 ac_top_srcdir=`echo $ac_dots | sed 's,/$,,'`
5566 fi ;;
5567 [\\/]* | ?:[\\/]* )
5568 ac_srcdir=$srcdir$ac_dir_suffix;
5569 ac_top_srcdir=$srcdir ;;
d60d9f65 5570 *) # Relative path.
9255ee31
EZ
5571 ac_srcdir=$ac_dots$srcdir$ac_dir_suffix
5572 ac_top_srcdir=$ac_dots$srcdir ;;
d60d9f65
SS
5573 esac
5574
9255ee31
EZ
5575 case $INSTALL in
5576 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
5577 *) ac_INSTALL=$ac_dots$INSTALL ;;
d60d9f65
SS
5578 esac
5579
9255ee31
EZ
5580 if test x"$ac_file" != x-; then
5581 { echo "$as_me:5581: creating $ac_file" >&5
5582echo "$as_me: creating $ac_file" >&6;}
5583 rm -f "$ac_file"
5584 fi
5585 # Let's still pretend it is `configure' which instantiates (i.e., don't
5586 # use $as_me), people would be surprised to read:
5587 # /* config.h. Generated automatically by config.status. */
5588 configure_input="Generated automatically from `echo $ac_file_in |
5589 sed 's,.*/,,'` by configure."
5590
5591 # First look for the input files in the build tree, otherwise in the
5592 # src tree.
5593 ac_file_inputs=`IFS=:
5594 for f in $ac_file_in; do
5595 case $f in
5596 -) echo $tmp/stdin ;;
5597 [\\/$]*)
5598 # Absolute (can't be DOS-style, as IFS=:)
5599 test -f "$f" || { { echo "$as_me:5599: error: cannot find input file: $f" >&5
5600echo "$as_me: error: cannot find input file: $f" >&2;}
5601 { (exit 1); exit 1; }; }
5602 echo $f;;
5603 *) # Relative
5604 if test -f "$f"; then
5605 # Build tree
5606 echo $f
5607 elif test -f "$srcdir/$f"; then
5608 # Source tree
5609 echo $srcdir/$f
5610 else
5611 # /dev/null tree
5612 { { echo "$as_me:5612: error: cannot find input file: $f" >&5
5613echo "$as_me: error: cannot find input file: $f" >&2;}
5614 { (exit 1); exit 1; }; }
5615 fi;;
5616 esac
5617 done` || { (exit 1); exit 1; }
5618EOF
5619cat >>$CONFIG_STATUS <<EOF
5620 sed "$ac_vpsub
5621$extrasub
5622EOF
5623cat >>$CONFIG_STATUS <<\EOF
5624:t
5625/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
5626s,@configure_input@,$configure_input,;t t
5627s,@srcdir@,$ac_srcdir,;t t
5628s,@top_srcdir@,$ac_top_srcdir,;t t
5629s,@INSTALL@,$ac_INSTALL,;t t
5630" $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
5631 rm -f $tmp/stdin
5632 if test x"$ac_file" != x-; then
5633 mv $tmp/out $ac_file
5634 else
5635 cat $tmp/out
5636 rm -f $tmp/out
5637 fi
5638
5639done
5640EOF
5641cat >>$CONFIG_STATUS <<\EOF
d60d9f65 5642
9255ee31
EZ
5643#
5644# CONFIG_HEADER section.
5645#
d60d9f65
SS
5646
5647# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
5648# NAME is the cpp macro being defined and VALUE is the value it is being given.
5649#
5650# ac_d sets the value in "#define NAME VALUE" lines.
9255ee31
EZ
5651ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
5652ac_dB='[ ].*$,\1#\2'
5653ac_dC=' '
5654ac_dD=',;t'
5655# ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
5656ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
5657ac_uB='$,\1#\2define\3'
d60d9f65 5658ac_uC=' '
9255ee31 5659ac_uD=',;t'
d60d9f65 5660
9255ee31 5661for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
d60d9f65 5662 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
9255ee31
EZ
5663 case $ac_file in
5664 - | *:- | *:-:* ) # input from stdin
5665 cat >$tmp/stdin
5666 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
5667 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
5668 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
5669 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
5670 * ) ac_file_in=$ac_file.in ;;
d60d9f65
SS
5671 esac
5672
9255ee31
EZ
5673 test x"$ac_file" != x- && { echo "$as_me:5673: creating $ac_file" >&5
5674echo "$as_me: creating $ac_file" >&6;}
5675
5676 # First look for the input files in the build tree, otherwise in the
5677 # src tree.
5678 ac_file_inputs=`IFS=:
5679 for f in $ac_file_in; do
5680 case $f in
5681 -) echo $tmp/stdin ;;
5682 [\\/$]*)
5683 # Absolute (can't be DOS-style, as IFS=:)
5684 test -f "$f" || { { echo "$as_me:5684: error: cannot find input file: $f" >&5
5685echo "$as_me: error: cannot find input file: $f" >&2;}
5686 { (exit 1); exit 1; }; }
5687 echo $f;;
5688 *) # Relative
5689 if test -f "$f"; then
5690 # Build tree
5691 echo $f
5692 elif test -f "$srcdir/$f"; then
5693 # Source tree
5694 echo $srcdir/$f
5695 else
5696 # /dev/null tree
5697 { { echo "$as_me:5697: error: cannot find input file: $f" >&5
5698echo "$as_me: error: cannot find input file: $f" >&2;}
5699 { (exit 1); exit 1; }; }
5700 fi;;
5701 esac
5702 done` || { (exit 1); exit 1; }
5703 # Remove the trailing spaces.
5704 sed 's/[ ]*$//' $ac_file_inputs >$tmp/in
d60d9f65
SS
5705
5706EOF
5707
9255ee31
EZ
5708# Transform confdefs.h into two sed scripts, `conftest.defines' and
5709# `conftest.undefs', that substitutes the proper values into
5710# config.h.in to produce config.h. The first handles `#define'
5711# templates, and the second `#undef' templates.
5712# And first: Protect against being on the right side of a sed subst in
5713# config.status. Protect against being in an unquoted here document
5714# in config.status.
5715rm -f conftest.defines conftest.undefs
5716# Using a here document instead of a string reduces the quoting nightmare.
5717# Putting comments in sed scripts is not portable.
5718#
5719# `end' is used to avoid that the second main sed command (meant for
5720# 0-ary CPP macros) applies to n-ary macro definitions.
5721# See the Autoconf documentation for `clear'.
5722cat >confdef2sed.sed <<\EOF
5723s/[\\&,]/\\&/g
5724s,[\\$`],\\&,g
5725t clear
5726: clear
5727s,^[ ]*#[ ]*define[ ][ ]*\(\([^ (][^ (]*\)([^)]*)\)[ ]*\(.*\)$,${ac_dA}\2${ac_dB}\1${ac_dC}\3${ac_dD},gp
5728t end
5729s,^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
5730: end
d60d9f65 5731EOF
9255ee31
EZ
5732# If some macros were called several times there might be several times
5733# the same #defines, which is useless. Nevertheless, we may not want to
5734# sort them, since we want the *last* AC-DEFINE to be honored.
5735uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
5736sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
5737rm -f confdef2sed.sed
d60d9f65
SS
5738
5739# This sed command replaces #undef with comments. This is necessary, for
5740# example, in the case of _POSIX_SOURCE, which is predefined and required
5741# on some systems where configure will not decide to define it.
9255ee31
EZ
5742cat >>conftest.undefs <<\EOF
5743s,^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
d60d9f65
SS
5744EOF
5745
9255ee31
EZ
5746# Break up conftest.defines because some shells have a limit on the size
5747# of here documents, and old seds have small limits too (100 cmds).
5748echo ' # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
5749echo ' if egrep "^[ ]*#[ ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
5750echo ' # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
5751echo ' :' >>$CONFIG_STATUS
5752rm -f conftest.tail
5753while grep . conftest.defines >/dev/null
5754do
5755 # Write a limited-size here document to $tmp/defines.sed.
5756 echo ' cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
5757 # Speed up: don't consider the non `#define' lines.
5758 echo '/^[ ]*#[ ]*define/!b' >>$CONFIG_STATUS
5759 # Work around the forget-to-reset-the-flag bug.
5760 echo 't clr' >>$CONFIG_STATUS
5761 echo ': clr' >>$CONFIG_STATUS
5762 sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
5763 echo 'CEOF
5764 sed -f $tmp/defines.sed $tmp/in >$tmp/out
5765 rm -f $tmp/in
5766 mv $tmp/out $tmp/in
5767' >>$CONFIG_STATUS
5768 sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
5769 rm -f conftest.defines
5770 mv conftest.tail conftest.defines
5771done
5772rm -f conftest.defines
5773echo ' fi # egrep' >>$CONFIG_STATUS
5774echo >>$CONFIG_STATUS
d60d9f65 5775
9255ee31
EZ
5776# Break up conftest.undefs because some shells have a limit on the size
5777# of here documents, and old seds have small limits too (100 cmds).
5778echo ' # Handle all the #undef templates' >>$CONFIG_STATUS
d60d9f65 5779rm -f conftest.tail
9255ee31 5780while grep . conftest.undefs >/dev/null
d60d9f65 5781do
9255ee31
EZ
5782 # Write a limited-size here document to $tmp/undefs.sed.
5783 echo ' cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
5784 # Speed up: don't consider the non `#undef'
5785 echo '/^[ ]*#[ ]*undef/!b' >>$CONFIG_STATUS
5786 # Work around the forget-to-reset-the-flag bug.
5787 echo 't clr' >>$CONFIG_STATUS
5788 echo ': clr' >>$CONFIG_STATUS
5789 sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
d60d9f65 5790 echo 'CEOF
9255ee31
EZ
5791 sed -f $tmp/undefs.sed $tmp/in >$tmp/out
5792 rm -f $tmp/in
5793 mv $tmp/out $tmp/in
5794' >>$CONFIG_STATUS
5795 sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
5796 rm -f conftest.undefs
5797 mv conftest.tail conftest.undefs
d60d9f65 5798done
9255ee31
EZ
5799rm -f conftest.undefs
5800
5801cat >>$CONFIG_STATUS <<\EOF
5802 # Let's still pretend it is `configure' which instantiates (i.e., don't
5803 # use $as_me), people would be surprised to read:
5804 # /* config.h. Generated automatically by config.status. */
5805 if test x"$ac_file" = x-; then
5806 echo "/* Generated automatically by configure. */" >$tmp/config.h
d60d9f65 5807 else
9255ee31
EZ
5808 echo "/* $ac_file. Generated automatically by configure. */" >$tmp/config.h
5809 fi
5810 cat $tmp/in >>$tmp/config.h
5811 rm -f $tmp/in
5812 if test x"$ac_file" != x-; then
5813 if cmp -s $ac_file $tmp/config.h 2>/dev/null; then
5814 { echo "$as_me:5814: $ac_file is unchanged" >&5
5815echo "$as_me: $ac_file is unchanged" >&6;}
5816 else
5817 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
5818 X"$ac_file" : 'X\(//\)[^/]' \| \
5819 X"$ac_file" : 'X\(//\)$' \| \
5820 X"$ac_file" : 'X\(/\)' \| \
5821 . : '\(.\)' 2>/dev/null ||
5822echo X"$ac_file" |
5823 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
5824 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
5825 /^X\(\/\/\)$/{ s//\1/; q; }
5826 /^X\(\/\).*/{ s//\1/; q; }
5827 s/.*/./; q'`
d60d9f65 5828 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
9255ee31
EZ
5829 { case "$ac_dir" in
5830 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
5831 *) as_incr_dir=.;;
5832esac
5833as_dummy="$ac_dir"
5834for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
5835 case $as_mkdir_dir in
5836 # Skip DOS drivespec
5837 ?:) as_incr_dir=$as_mkdir_dir ;;
5838 *)
5839 as_incr_dir=$as_incr_dir/$as_mkdir_dir
5840 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
5841 ;;
5842 esac
5843done; }
5844
5845 fi
5846 rm -f $ac_file
5847 mv $tmp/config.h $ac_file
d60d9f65 5848 fi
9255ee31
EZ
5849 else
5850 cat $tmp/config.h
5851 rm -f $tmp/config.h
d60d9f65 5852 fi
9255ee31 5853done
d60d9f65 5854EOF
9255ee31 5855cat >>$CONFIG_STATUS <<\EOF
d60d9f65 5856
9255ee31
EZ
5857#
5858# CONFIG_COMMANDS section.
5859#
5860for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
5861 ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
5862 ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
d60d9f65 5863
9255ee31
EZ
5864 case $ac_dest in
5865 default )
d60d9f65
SS
5866# Makefile uses this timestamp file to record whether config.h is up to date.
5867echo > stamp-h
9255ee31
EZ
5868 ;;
5869 esac
5870done
5871EOF
d60d9f65 5872
9255ee31
EZ
5873cat >>$CONFIG_STATUS <<\EOF
5874
5875{ (exit 0); exit 0; }
d60d9f65
SS
5876EOF
5877chmod +x $CONFIG_STATUS
9255ee31
EZ
5878ac_clean_files=$ac_clean_files_save
5879
5880# configure is writing to config.log, and then calls config.status.
5881# config.status does its own redirection, appending to config.log.
5882# Unfortunately, on DOS this fails, as config.log is still kept open
5883# by configure, so config.status won't be able to write to it; its
5884# output is simply discarded. So we exec the FD to /dev/null,
5885# effectively closing config.log, so it can be properly (re)opened and
5886# appended to by config.status. When coming back to configure, we
5887# need to make the FD available again.
5888if test "$no_create" != yes; then
5889 ac_cs_success=:
5890 exec 5>/dev/null
5891 $SHELL $CONFIG_STATUS || ac_cs_success=false
5892 exec 5>>config.log
5893 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
5894 # would make configure fail if this is the last instruction.
5895 $ac_cs_success || { (exit 1); exit 1; }
5896fi
d60d9f65 5897
This page took 0.407638 seconds and 4 git commands to generate.