1#! /bin/sh
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.
12
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
19
20# Sed expression to map a string onto a valid variable name.
21as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
22
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"
25
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
33
34# Name of the executable.
35as_me=`echo "$0" |sed 's,.*[\\/],,'`
36
37if expr a : '\(a\)' >/dev/null 2>&1; then
38  as_expr=expr
39else
40  as_expr=false
41fi
42
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
60
61as_executable_p="test -f"
62
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
69
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
95
96#
97# Initializations.
98#
99ac_default_prefix=/usr/local
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"
147
148# Initialize some variables set by options.
149ac_init_help=
150ac_init_version=false
151# The variables have the same names as the options, with
152# dashes changed to underlines.
153cache_file=/dev/null
154exec_prefix=NONE
155no_create=
156no_recursion=
157prefix=NONE
158program_prefix=NONE
159program_suffix=NONE
160program_transform_name=s,x,x,
161silent=
162site=
163srcdir=
164verbose=
165x_includes=NONE
166x_libraries=NONE
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.
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
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'
192
193ac_prev=
194for ac_option
195do
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
203  ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
204
205  # Accept the important Cygnus configure options, so we can diagnose typos.
206
207  case $ac_option in
208
209  -bindir | --bindir | --bindi | --bind | --bin | --bi)
210    ac_prev=bindir ;;
211  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
212    bindir=$ac_optarg ;;
213
214  -build | --build | --buil | --bui | --bu)
215    ac_prev=build_alias ;;
216  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
217    build_alias=$ac_optarg ;;
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=*)
224    cache_file=$ac_optarg ;;
225
226  --config-cache | -C)
227    cache_file=config.cache ;;
228
229  -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
230    ac_prev=datadir ;;
231  -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
232  | --da=*)
233    datadir=$ac_optarg ;;
234
235  -disable-* | --disable-*)
236    ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
237    # Reject names that are not valid shell variable names.
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" ;;
243
244  -enable-* | --enable-*)
245    ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
246    # Reject names that are not valid shell variable names.
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"`;;
253      *) ac_optarg=yes ;;
254    esac
255    eval "enable_$ac_feature='$ac_optarg'" ;;
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=*)
264    exec_prefix=$ac_optarg ;;
265
266  -gas | --gas | --ga | --g)
267    # Obsolete; use --with-gas.
268    with_gas=yes ;;
269
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 ;;
276
277  -host | --host | --hos | --ho)
278    ac_prev=host_alias ;;
279  -host=* | --host=* | --hos=* | --ho=*)
280    host_alias=$ac_optarg ;;
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=*)
287    includedir=$ac_optarg ;;
288
289  -infodir | --infodir | --infodi | --infod | --info | --inf)
290    ac_prev=infodir ;;
291  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
292    infodir=$ac_optarg ;;
293
294  -libdir | --libdir | --libdi | --libd)
295    ac_prev=libdir ;;
296  -libdir=* | --libdir=* | --libdi=* | --libd=*)
297    libdir=$ac_optarg ;;
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=*)
304    libexecdir=$ac_optarg ;;
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=*)
313    localstatedir=$ac_optarg ;;
314
315  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
316    ac_prev=mandir ;;
317  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
318    mandir=$ac_optarg ;;
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=*)
339    oldincludedir=$ac_optarg ;;
340
341  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
342    ac_prev=prefix ;;
343  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
344    prefix=$ac_optarg ;;
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=*)
351    program_prefix=$ac_optarg ;;
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=*)
358    program_suffix=$ac_optarg ;;
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=*)
375    program_transform_name=$ac_optarg ;;
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=*)
385    sbindir=$ac_optarg ;;
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=*)
396    sharedstatedir=$ac_optarg ;;
397
398  -site | --site | --sit)
399    ac_prev=site ;;
400  -site=* | --site=* | --sit=*)
401    site=$ac_optarg ;;
402
403  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
404    ac_prev=srcdir ;;
405  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
406    srcdir=$ac_optarg ;;
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=*)
413    sysconfdir=$ac_optarg ;;
414
415  -target | --target | --targe | --targ | --tar | --ta | --t)
416    ac_prev=target_alias ;;
417  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
418    target_alias=$ac_optarg ;;
419
420  -v | -verbose | --verbose | --verbos | --verbo | --verb)
421    verbose=yes ;;
422
423  -version | --version | --versio | --versi | --vers | -V)
424    ac_init_version=: ;;
425
426  -with-* | --with-*)
427    ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
428    # Reject names that are not valid shell variable names.
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; }; }
432    ac_package=`echo $ac_package| sed 's/-/_/g'`
433    case $ac_option in
434      *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
435      *) ac_optarg=yes ;;
436    esac
437    eval "with_$ac_package='$ac_optarg'" ;;
438
439  -without-* | --without-*)
440    ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
441    # Reject names that are not valid shell variable names.
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" ;;
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=*)
457    x_includes=$ac_optarg ;;
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=*)
464    x_libraries=$ac_optarg ;;
465
466  -*) { echo "$as_me: error: unrecognized option: $ac_option
467Try \`$0 --help' for more information." >&2
468   { (exit 1); exit 1; }; }
469    ;;
470
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
481  *)
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}
487    ;;
488
489  esac
490done
491
492if test -n "$ac_prev"; then
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; }; }
496fi
497
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
508
509# Be sure to have absolute paths.
510for ac_var in bindir sbindir libexecdir datadir sysconfdir sharedstatedir \
511              localstatedir libdir includedir oldincludedir infodir mandir
512do
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; }; };;
518  esac
519done
520
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
537
538ac_tool_prefix=
539test -n "$host_alias" && ac_tool_prefix=$host_alias-
540
541test "$silent" = yes && exec 6>/dev/null
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
548  ac_confdir=`echo "$ac_prog" | sed 's%[\\/][^\\/][^\\/]*$%%'`
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
559    { echo "$as_me: error: cannot find sources in $ac_confdir or .." >&2
560   { (exit 1); exit 1; }; }
561  else
562    { echo "$as_me: error: cannot find sources in $srcdir" >&2
563   { (exit 1); exit 1; }; }
564  fi
565fi
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
599
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.
608
609Usage: $0 [OPTION]... [VAR=VALUE]...
610
611To assign environment variables (e.g., CC, CFLAGS...), specify them as
612VAR=VALUE.  See below for descriptions of some of the useful variables.
613
614Defaults for the options are specified in brackets.
615
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 \`..']
626
627EOF
628
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
657
658  cat <<\EOF
659
660System types:
661  --build=BUILD     configure for building on BUILD [guessed]
662  --host=HOST       build programs to run on HOST [BUILD]
663EOF
664fi
665
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
671
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]
677
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
699
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
717
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
734fi
735
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
741
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
748fi
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.
753
754It was created by readline $as_me 4.3, which was
755generated by GNU Autoconf 2.52.  Invocation command line was
756
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=:
977fi
978PATH_SEPARATOR="$ac_path_separator"
979rm -f conftest.sh
980
981ac_aux_dir=
982for ac_dir in  ${GNUSYSTEM_AUX_DIR} ./support $srcdir/./support; do
983  if test -f $ac_dir/install-sh; then
984    ac_aux_dir=$ac_dir
985    ac_install_sh="$ac_aux_dir/install-sh -c"
986    break
987  elif 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/shtool; then
992    ac_aux_dir=$ac_dir
993    ac_install_sh="$ac_aux_dir/shtool install -c"
994    break
995  fi
996done
997if test -z "$ac_aux_dir"; then
998  { { echo "$as_me:998: error: cannot find install-sh or install.sh in ./support $srcdir/./support" >&5
999echo "$as_me: error: cannot find install-sh or install.sh in ./support $srcdir/./support" >&2;}
1000   { (exit 1); exit 1; }; }
1001fi
1002ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1003ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1004ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
1005
1006ac_config_headers="$ac_config_headers config.h"
1007
1008LIBVERSION=4.3
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
1151fi
1152fi
1153CC=$ac_cv_prog_CC
1154if test -n "$CC"; then
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
1198else
1199  CC="$ac_cv_prog_CC"
1200fi
1201
1202if test -z "$CC"; then
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
1239  # Extract the first word of "cc", so it can be a program name with args.
1240set dummy cc; ac_word=$2
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
1284else
1285  if test -n "$CC"; then
1286  ac_cv_prog_CC="$CC" # Let the user override the test.
1287else
1288  ac_prog_rejected=no
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
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
1308  if test $# != 0; then
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
1313    set dummy "$ac_dir/$ac_word" ${1+"$@"}
1314    shift
1315    ac_cv_prog_CC="$@"
1316  fi
1317fi
1318fi
1319fi
1320CC=$ac_cv_prog_CC
1321if test -n "$CC"; then
1322  echo "$as_me:1322: result: $CC" >&5
1323echo "${ECHO_T}$CC" >&6
1324else
1325  echo "$as_me:1325: result: no" >&5
1326echo "${ECHO_T}no" >&6
1327fi
1328
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
1340else
1341  if test -n "$CC"; then
1342  ac_cv_prog_CC="$CC" # Let the user override the test.
1343else
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
1355fi
1356fi
1357CC=$ac_cv_prog_CC
1358if test -n "$CC"; then
1359  echo "$as_me:1359: result: $CC" >&5
1360echo "${ECHO_T}$CC" >&6
1361else
1362  echo "$as_me:1362: result: no" >&5
1363echo "${ECHO_T}no" >&6
1364fi
1365
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
1393
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
1404
1405  test -n "$ac_ct_CC" && break
1406done
1407
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"
1439#include "confdefs.h"
1440
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
1506  else
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
1516  fi
1517fi
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
1550else
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"
1571
1572int
1573main ()
1574{
1575
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
1593else
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
1622
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
1659else
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
1684  ac_cv_prog_cc_g=yes
1685else
1686  echo "$as_me: failed program was:" >&5
1687cat conftest.$ac_ext >&5
1688ac_cv_prog_cc_g=no
1689fi
1690rm -f conftest.$ac_objext conftest.$ac_ext
1691fi
1692echo "$as_me:1692: result: $ac_cv_prog_cc_g" >&5
1693echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
1694if test "$ac_test_CFLAGS" = set; then
1695  CFLAGS=$ac_save_CFLAGS
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
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
1808
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
1827# On Suns, sometimes $CPP names a directory.
1828if test -n "$CPP" && test -d "$CPP"; then
1829  CPP=
1830fi
1831if test -z "$CPP"; then
1832  if test "${ac_cv_prog_CPP+set}" = set; then
1833  echo $ECHO_N "(cached) $ECHO_C" >&6
1834else
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.
1843  # On the NeXT, cc -E runs the code through the compiler's parser,
1844  # not just through cpp. "Syntax error" is here to catch this case.
1845  cat >conftest.$ac_ext <<_ACEOF
1846#line 1846 "configure"
1847#include "confdefs.h"
1848#include <assert.h>
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
1868  :
1869else
1870  echo "$as_me: failed program was:" >&5
1871  cat conftest.$ac_ext >&5
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"
1881#include "confdefs.h"
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
1903else
1904  echo "$as_me: failed program was:" >&5
1905  cat conftest.$ac_ext >&5
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"
1938#include "confdefs.h"
1939#include <assert.h>
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
1959  :
1960else
1961  echo "$as_me: failed program was:" >&5
1962  cat conftest.$ac_ext >&5
1963  # Broken: fails on valid input.
1964continue
1965fi
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
1990fi
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
2000fi
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  :
2008else
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; }; }
2012fi
2013
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
2024else
2025  cat >conftest.$ac_ext <<_ACEOF
2026#line 2026 "configure"
2027#include "confdefs.h"
2028#include <minix/config.h>
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
2043else
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
2050  cat conftest.$ac_ext >&5
2051  ac_cv_header_minix_config_h=no
2052fi
2053rm -f conftest.err conftest.$ac_ext
2054fi
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
2058  MINIX=yes
2059else
2060  MINIX=
2061fi
2062
2063if test "$MINIX" = yes; then
2064
2065cat >>confdefs.h <<\EOF
2066#define _POSIX_SOURCE 1
2067EOF
2068
2069cat >>confdefs.h <<\EOF
2070#define _POSIX_1_SOURCE 2
2071EOF
2072
2073cat >>confdefs.h <<\EOF
2074#define _MINIX 1
2075EOF
2076
2077fi
2078
2079# If we're using gcc and the user hasn't specified CFLAGS, add -O to CFLAGS.
2080test -n "$GCC" && test -n "$auto_cflags" && CFLAGS="$CFLAGS -O"
2081
2082if test $ac_cv_c_compiler_gnu = yes; then
2083    echo "$as_me:2083: checking whether $CC needs -traditional" >&5
2084echo $ECHO_N "checking whether $CC needs -traditional... $ECHO_C" >&6
2085if test "${ac_cv_prog_gcc_traditional+set}" = set; then
2086  echo $ECHO_N "(cached) $ECHO_C" >&6
2087else
2088    ac_pattern="Autoconf.*'x'"
2089  cat >conftest.$ac_ext <<_ACEOF
2090#line 2090 "configure"
2091#include "confdefs.h"
2092#include <sgtty.h>
2093Autoconf TIOCGETP
2094_ACEOF
2095if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2096  egrep "$ac_pattern" >/dev/null 2>&1; then
2097  ac_cv_prog_gcc_traditional=yes
2098else
2099  ac_cv_prog_gcc_traditional=no
2100fi
2101rm -f conftest*
2102
2103  if test $ac_cv_prog_gcc_traditional = no; then
2104    cat >conftest.$ac_ext <<_ACEOF
2105#line 2105 "configure"
2106#include "confdefs.h"
2107#include <termio.h>
2108Autoconf TCGETA
2109_ACEOF
2110if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2111  egrep "$ac_pattern" >/dev/null 2>&1; then
2112  ac_cv_prog_gcc_traditional=yes
2113fi
2114rm -f conftest*
2115
2116  fi
2117fi
2118echo "$as_me:2118: result: $ac_cv_prog_gcc_traditional" >&5
2119echo "${ECHO_T}$ac_cv_prog_gcc_traditional" >&6
2120  if test $ac_cv_prog_gcc_traditional = yes; then
2121    CC="$CC -traditional"
2122  fi
2123fi
2124
2125# Find a good install program.  We prefer a C program (faster),
2126# so one script is as good as another.  But avoid the broken or
2127# incompatible versions:
2128# SysV /etc/install, /usr/sbin/install
2129# SunOS /usr/etc/install
2130# IRIX /sbin/install
2131# AIX /bin/install
2132# AmigaOS /C/install, which installs bootblocks on floppy discs
2133# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
2134# AFS /usr/afsws/bin/install, which mishandles nonexistent args
2135# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
2136# ./install, which can be erroneously created by make from ./install.sh.
2137echo "$as_me:2137: checking for a BSD compatible install" >&5
2138echo $ECHO_N "checking for a BSD compatible install... $ECHO_C" >&6
2139if test -z "$INSTALL"; then
2140if test "${ac_cv_path_install+set}" = set; then
2141  echo $ECHO_N "(cached) $ECHO_C" >&6
2142else
2143    ac_save_IFS=$IFS; IFS=$ac_path_separator
2144  for ac_dir in $PATH; do
2145    IFS=$ac_save_IFS
2146    # Account for people who put trailing slashes in PATH elements.
2147    case $ac_dir/ in
2148    / | ./ | .// | /cC/* \
2149    | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* \
2150    | /usr/ucb/* ) ;;
2151    *)
2152      # OSF1 and SCO ODT 3.0 have their own names for install.
2153      # Don't use installbsd from OSF since it installs stuff as root
2154      # by default.
2155      for ac_prog in ginstall scoinst install; do
2156        if $as_executable_p "$ac_dir/$ac_prog"; then
2157	  if test $ac_prog = install &&
2158            grep dspmsg "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2159	    # AIX install.  It has an incompatible calling convention.
2160	    :
2161	  elif test $ac_prog = install &&
2162	    grep pwplus "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2163	    # program-specific install script used by HP pwplus--don't use.
2164	    :
2165	  else
2166	    ac_cv_path_install="$ac_dir/$ac_prog -c"
2167	    break 2
2168	  fi
2169	fi
2170      done
2171      ;;
2172    esac
2173  done
2174
2175fi
2176  if test "${ac_cv_path_install+set}" = set; then
2177    INSTALL=$ac_cv_path_install
2178  else
2179    # As a last resort, use the slow shell script.  We don't cache a
2180    # path for INSTALL within a source directory, because that will
2181    # break other packages using the cache if that directory is
2182    # removed, or if the path is relative.
2183    INSTALL=$ac_install_sh
2184  fi
2185fi
2186echo "$as_me:2186: result: $INSTALL" >&5
2187echo "${ECHO_T}$INSTALL" >&6
2188
2189# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
2190# It thinks the first close brace ends the variable substitution.
2191test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
2192
2193test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
2194
2195test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
2196
2197# Extract the first word of "ar", so it can be a program name with args.
2198set dummy ar; ac_word=$2
2199echo "$as_me:2199: checking for $ac_word" >&5
2200echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2201if test "${ac_cv_prog_AR+set}" = set; then
2202  echo $ECHO_N "(cached) $ECHO_C" >&6
2203else
2204  if test -n "$AR"; then
2205  ac_cv_prog_AR="$AR" # Let the user override the test.
2206else
2207  ac_save_IFS=$IFS; IFS=$ac_path_separator
2208ac_dummy="$PATH"
2209for ac_dir in $ac_dummy; do
2210  IFS=$ac_save_IFS
2211  test -z "$ac_dir" && ac_dir=.
2212  $as_executable_p "$ac_dir/$ac_word" || continue
2213ac_cv_prog_AR=""
2214echo "$as_me:2214: found $ac_dir/$ac_word" >&5
2215break
2216done
2217
2218  test -z "$ac_cv_prog_AR" && ac_cv_prog_AR="ar"
2219fi
2220fi
2221AR=$ac_cv_prog_AR
2222if test -n "$AR"; then
2223  echo "$as_me:2223: result: $AR" >&5
2224echo "${ECHO_T}$AR" >&6
2225else
2226  echo "$as_me:2226: result: no" >&5
2227echo "${ECHO_T}no" >&6
2228fi
2229
2230test -n "$ARFLAGS" || ARFLAGS="cr"
2231if test -n "$ac_tool_prefix"; then
2232  # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
2233set dummy ${ac_tool_prefix}ranlib; ac_word=$2
2234echo "$as_me:2234: checking for $ac_word" >&5
2235echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2236if test "${ac_cv_prog_RANLIB+set}" = set; then
2237  echo $ECHO_N "(cached) $ECHO_C" >&6
2238else
2239  if test -n "$RANLIB"; then
2240  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
2241else
2242  ac_save_IFS=$IFS; IFS=$ac_path_separator
2243ac_dummy="$PATH"
2244for ac_dir in $ac_dummy; do
2245  IFS=$ac_save_IFS
2246  test -z "$ac_dir" && ac_dir=.
2247  $as_executable_p "$ac_dir/$ac_word" || continue
2248ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
2249echo "$as_me:2249: found $ac_dir/$ac_word" >&5
2250break
2251done
2252
2253fi
2254fi
2255RANLIB=$ac_cv_prog_RANLIB
2256if test -n "$RANLIB"; then
2257  echo "$as_me:2257: result: $RANLIB" >&5
2258echo "${ECHO_T}$RANLIB" >&6
2259else
2260  echo "$as_me:2260: result: no" >&5
2261echo "${ECHO_T}no" >&6
2262fi
2263
2264fi
2265if test -z "$ac_cv_prog_RANLIB"; then
2266  ac_ct_RANLIB=$RANLIB
2267  # Extract the first word of "ranlib", so it can be a program name with args.
2268set dummy ranlib; ac_word=$2
2269echo "$as_me:2269: checking for $ac_word" >&5
2270echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2271if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
2272  echo $ECHO_N "(cached) $ECHO_C" >&6
2273else
2274  if test -n "$ac_ct_RANLIB"; then
2275  ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
2276else
2277  ac_save_IFS=$IFS; IFS=$ac_path_separator
2278ac_dummy="$PATH"
2279for ac_dir in $ac_dummy; do
2280  IFS=$ac_save_IFS
2281  test -z "$ac_dir" && ac_dir=.
2282  $as_executable_p "$ac_dir/$ac_word" || continue
2283ac_cv_prog_ac_ct_RANLIB="ranlib"
2284echo "$as_me:2284: found $ac_dir/$ac_word" >&5
2285break
2286done
2287
2288  test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
2289fi
2290fi
2291ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
2292if test -n "$ac_ct_RANLIB"; then
2293  echo "$as_me:2293: result: $ac_ct_RANLIB" >&5
2294echo "${ECHO_T}$ac_ct_RANLIB" >&6
2295else
2296  echo "$as_me:2296: result: no" >&5
2297echo "${ECHO_T}no" >&6
2298fi
2299
2300  RANLIB=$ac_ct_RANLIB
2301else
2302  RANLIB="$ac_cv_prog_RANLIB"
2303fi
2304
2305MAKE_SHELL=/bin/sh
2306
2307echo "$as_me:2307: checking for $CC option to accept ANSI C" >&5
2308echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
2309if test "${ac_cv_prog_cc_stdc+set}" = set; then
2310  echo $ECHO_N "(cached) $ECHO_C" >&6
2311else
2312  ac_cv_prog_cc_stdc=no
2313ac_save_CC=$CC
2314cat >conftest.$ac_ext <<_ACEOF
2315#line 2315 "configure"
2316#include "confdefs.h"
2317#include <stdarg.h>
2318#include <stdio.h>
2319#include <sys/types.h>
2320#include <sys/stat.h>
2321/* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
2322struct buf { int x; };
2323FILE * (*rcsopen) (struct buf *, struct stat *, int);
2324static char *e (p, i)
2325     char **p;
2326     int i;
2327{
2328  return p[i];
2329}
2330static char *f (char * (*g) (char **, int), char **p, ...)
2331{
2332  char *s;
2333  va_list v;
2334  va_start (v,p);
2335  s = g (p, va_arg (v,int));
2336  va_end (v);
2337  return s;
2338}
2339int test (int i, double x);
2340struct s1 {int (*f) (int a);};
2341struct s2 {int (*f) (double a);};
2342int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
2343int argc;
2344char **argv;
2345int
2346main ()
2347{
2348return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
2349  ;
2350  return 0;
2351}
2352_ACEOF
2353# Don't try gcc -ansi; that turns off useful extensions and
2354# breaks some systems' header files.
2355# AIX			-qlanglvl=ansi
2356# Ultrix and OSF/1	-std1
2357# HP-UX 10.20 and later	-Ae
2358# HP-UX older versions	-Aa -D_HPUX_SOURCE
2359# SVR4			-Xc -D__EXTENSIONS__
2360for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
2361do
2362  CC="$ac_save_CC $ac_arg"
2363  rm -f conftest.$ac_objext
2364if { (eval echo "$as_me:2364: \"$ac_compile\"") >&5
2365  (eval $ac_compile) 2>&5
2366  ac_status=$?
2367  echo "$as_me:2367: \$? = $ac_status" >&5
2368  (exit $ac_status); } &&
2369         { ac_try='test -s conftest.$ac_objext'
2370  { (eval echo "$as_me:2370: \"$ac_try\"") >&5
2371  (eval $ac_try) 2>&5
2372  ac_status=$?
2373  echo "$as_me:2373: \$? = $ac_status" >&5
2374  (exit $ac_status); }; }; then
2375  ac_cv_prog_cc_stdc=$ac_arg
2376break
2377else
2378  echo "$as_me: failed program was:" >&5
2379cat conftest.$ac_ext >&5
2380fi
2381rm -f conftest.$ac_objext
2382done
2383rm -f conftest.$ac_ext conftest.$ac_objext
2384CC=$ac_save_CC
2385
2386fi
2387
2388case "x$ac_cv_prog_cc_stdc" in
2389  x|xno)
2390    echo "$as_me:2390: result: none needed" >&5
2391echo "${ECHO_T}none needed" >&6 ;;
2392  *)
2393    echo "$as_me:2393: result: $ac_cv_prog_cc_stdc" >&5
2394echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
2395    CC="$CC $ac_cv_prog_cc_stdc" ;;
2396esac
2397
2398echo "$as_me:2398: checking for an ANSI C-conforming const" >&5
2399echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
2400if test "${ac_cv_c_const+set}" = set; then
2401  echo $ECHO_N "(cached) $ECHO_C" >&6
2402else
2403  cat >conftest.$ac_ext <<_ACEOF
2404#line 2404 "configure"
2405#include "confdefs.h"
2406
2407int
2408main ()
2409{
2410/* FIXME: Include the comments suggested by Paul. */
2411#ifndef __cplusplus
2412  /* Ultrix mips cc rejects this.  */
2413  typedef int charset[2];
2414  const charset x;
2415  /* SunOS 4.1.1 cc rejects this.  */
2416  char const *const *ccp;
2417  char **p;
2418  /* NEC SVR4.0.2 mips cc rejects this.  */
2419  struct point {int x, y;};
2420  static struct point const zero = {0,0};
2421  /* AIX XL C 1.02.0.0 rejects this.
2422     It does not let you subtract one const X* pointer from another in
2423     an arm of an if-expression whose if-part is not a constant
2424     expression */
2425  const char *g = "string";
2426  ccp = &g + (g ? g-g : 0);
2427  /* HPUX 7.0 cc rejects these. */
2428  ++ccp;
2429  p = (char**) ccp;
2430  ccp = (char const *const *) p;
2431  { /* SCO 3.2v4 cc rejects this.  */
2432    char *t;
2433    char const *s = 0 ? (char *) 0 : (char const *) 0;
2434
2435    *t++ = 0;
2436  }
2437  { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
2438    int x[] = {25, 17};
2439    const int *foo = &x[0];
2440    ++foo;
2441  }
2442  { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
2443    typedef const int *iptr;
2444    iptr p = 0;
2445    ++p;
2446  }
2447  { /* AIX XL C 1.02.0.0 rejects this saying
2448       "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
2449    struct s { int j; const int *ap[3]; };
2450    struct s *b; b->j = 5;
2451  }
2452  { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
2453    const int foo = 10;
2454  }
2455#endif
2456
2457  ;
2458  return 0;
2459}
2460_ACEOF
2461rm -f conftest.$ac_objext
2462if { (eval echo "$as_me:2462: \"$ac_compile\"") >&5
2463  (eval $ac_compile) 2>&5
2464  ac_status=$?
2465  echo "$as_me:2465: \$? = $ac_status" >&5
2466  (exit $ac_status); } &&
2467         { ac_try='test -s conftest.$ac_objext'
2468  { (eval echo "$as_me:2468: \"$ac_try\"") >&5
2469  (eval $ac_try) 2>&5
2470  ac_status=$?
2471  echo "$as_me:2471: \$? = $ac_status" >&5
2472  (exit $ac_status); }; }; then
2473  ac_cv_c_const=yes
2474else
2475  echo "$as_me: failed program was:" >&5
2476cat conftest.$ac_ext >&5
2477ac_cv_c_const=no
2478fi
2479rm -f conftest.$ac_objext conftest.$ac_ext
2480fi
2481echo "$as_me:2481: result: $ac_cv_c_const" >&5
2482echo "${ECHO_T}$ac_cv_c_const" >&6
2483if test $ac_cv_c_const = no; then
2484
2485cat >>confdefs.h <<\EOF
2486#define const
2487EOF
2488
2489fi
2490
2491echo "$as_me:2491: checking for function prototypes" >&5
2492echo $ECHO_N "checking for function prototypes... $ECHO_C" >&6
2493if test "$ac_cv_prog_cc_stdc" != no; then
2494  echo "$as_me:2494: result: yes" >&5
2495echo "${ECHO_T}yes" >&6
2496
2497cat >>confdefs.h <<\EOF
2498#define PROTOTYPES 1
2499EOF
2500
2501else
2502  echo "$as_me:2502: result: no" >&5
2503echo "${ECHO_T}no" >&6
2504fi
2505
2506echo "$as_me:2506: checking for ANSI C header files" >&5
2507echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
2508if test "${ac_cv_header_stdc+set}" = set; then
2509  echo $ECHO_N "(cached) $ECHO_C" >&6
2510else
2511  cat >conftest.$ac_ext <<_ACEOF
2512#line 2512 "configure"
2513#include "confdefs.h"
2514#include <stdlib.h>
2515#include <stdarg.h>
2516#include <string.h>
2517#include <float.h>
2518
2519_ACEOF
2520if { (eval echo "$as_me:2520: \"$ac_cpp conftest.$ac_ext\"") >&5
2521  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2522  ac_status=$?
2523  egrep -v '^ *\+' conftest.er1 >conftest.err
2524  rm -f conftest.er1
2525  cat conftest.err >&5
2526  echo "$as_me:2526: \$? = $ac_status" >&5
2527  (exit $ac_status); } >/dev/null; then
2528  if test -s conftest.err; then
2529    ac_cpp_err=$ac_c_preproc_warn_flag
2530  else
2531    ac_cpp_err=
2532  fi
2533else
2534  ac_cpp_err=yes
2535fi
2536if test -z "$ac_cpp_err"; then
2537  ac_cv_header_stdc=yes
2538else
2539  echo "$as_me: failed program was:" >&5
2540  cat conftest.$ac_ext >&5
2541  ac_cv_header_stdc=no
2542fi
2543rm -f conftest.err conftest.$ac_ext
2544
2545if test $ac_cv_header_stdc = yes; then
2546  # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
2547  cat >conftest.$ac_ext <<_ACEOF
2548#line 2548 "configure"
2549#include "confdefs.h"
2550#include <string.h>
2551
2552_ACEOF
2553if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2554  egrep "memchr" >/dev/null 2>&1; then
2555  :
2556else
2557  ac_cv_header_stdc=no
2558fi
2559rm -f conftest*
2560
2561fi
2562
2563if test $ac_cv_header_stdc = yes; then
2564  # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
2565  cat >conftest.$ac_ext <<_ACEOF
2566#line 2566 "configure"
2567#include "confdefs.h"
2568#include <stdlib.h>
2569
2570_ACEOF
2571if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2572  egrep "free" >/dev/null 2>&1; then
2573  :
2574else
2575  ac_cv_header_stdc=no
2576fi
2577rm -f conftest*
2578
2579fi
2580
2581if test $ac_cv_header_stdc = yes; then
2582  # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
2583  if test "$cross_compiling" = yes; then
2584  :
2585else
2586  cat >conftest.$ac_ext <<_ACEOF
2587#line 2587 "configure"
2588#include "confdefs.h"
2589#include <ctype.h>
2590#if ((' ' & 0x0FF) == 0x020)
2591# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
2592# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
2593#else
2594# define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
2595                     || ('j' <= (c) && (c) <= 'r') \
2596                     || ('s' <= (c) && (c) <= 'z'))
2597# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
2598#endif
2599
2600#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
2601int
2602main ()
2603{
2604  int i;
2605  for (i = 0; i < 256; i++)
2606    if (XOR (islower (i), ISLOWER (i))
2607        || toupper (i) != TOUPPER (i))
2608      exit(2);
2609  exit (0);
2610}
2611_ACEOF
2612rm -f conftest$ac_exeext
2613if { (eval echo "$as_me:2613: \"$ac_link\"") >&5
2614  (eval $ac_link) 2>&5
2615  ac_status=$?
2616  echo "$as_me:2616: \$? = $ac_status" >&5
2617  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
2618  { (eval echo "$as_me:2618: \"$ac_try\"") >&5
2619  (eval $ac_try) 2>&5
2620  ac_status=$?
2621  echo "$as_me:2621: \$? = $ac_status" >&5
2622  (exit $ac_status); }; }; then
2623  :
2624else
2625  echo "$as_me: program exited with status $ac_status" >&5
2626echo "$as_me: failed program was:" >&5
2627cat conftest.$ac_ext >&5
2628ac_cv_header_stdc=no
2629fi
2630rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
2631fi
2632fi
2633fi
2634echo "$as_me:2634: result: $ac_cv_header_stdc" >&5
2635echo "${ECHO_T}$ac_cv_header_stdc" >&6
2636if test $ac_cv_header_stdc = yes; then
2637
2638cat >>confdefs.h <<\EOF
2639#define STDC_HEADERS 1
2640EOF
2641
2642fi
2643
2644# On IRIX 5.3, sys/types and inttypes.h are conflicting.
2645
2646for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
2647                  inttypes.h stdint.h unistd.h
2648do
2649as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
2650echo "$as_me:2650: checking for $ac_header" >&5
2651echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
2652if eval "test \"\${$as_ac_Header+set}\" = set"; then
2653  echo $ECHO_N "(cached) $ECHO_C" >&6
2654else
2655  cat >conftest.$ac_ext <<_ACEOF
2656#line 2656 "configure"
2657#include "confdefs.h"
2658$ac_includes_default
2659#include <$ac_header>
2660_ACEOF
2661rm -f conftest.$ac_objext
2662if { (eval echo "$as_me:2662: \"$ac_compile\"") >&5
2663  (eval $ac_compile) 2>&5
2664  ac_status=$?
2665  echo "$as_me:2665: \$? = $ac_status" >&5
2666  (exit $ac_status); } &&
2667         { ac_try='test -s conftest.$ac_objext'
2668  { (eval echo "$as_me:2668: \"$ac_try\"") >&5
2669  (eval $ac_try) 2>&5
2670  ac_status=$?
2671  echo "$as_me:2671: \$? = $ac_status" >&5
2672  (exit $ac_status); }; }; then
2673  eval "$as_ac_Header=yes"
2674else
2675  echo "$as_me: failed program was:" >&5
2676cat conftest.$ac_ext >&5
2677eval "$as_ac_Header=no"
2678fi
2679rm -f conftest.$ac_objext conftest.$ac_ext
2680fi
2681echo "$as_me:2681: result: `eval echo '${'$as_ac_Header'}'`" >&5
2682echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
2683if test `eval echo '${'$as_ac_Header'}'` = yes; then
2684  cat >>confdefs.h <<EOF
2685#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
2686EOF
2687
2688fi
2689done
2690
2691echo "$as_me:2691: checking whether char is unsigned" >&5
2692echo $ECHO_N "checking whether char is unsigned... $ECHO_C" >&6
2693if test "${ac_cv_c_char_unsigned+set}" = set; then
2694  echo $ECHO_N "(cached) $ECHO_C" >&6
2695else
2696  cat >conftest.$ac_ext <<_ACEOF
2697#line 2697 "configure"
2698#include "confdefs.h"
2699$ac_includes_default
2700int
2701main ()
2702{
2703int _array_ [1 - 2 * !(((char) -1) < 0)]
2704  ;
2705  return 0;
2706}
2707_ACEOF
2708rm -f conftest.$ac_objext
2709if { (eval echo "$as_me:2709: \"$ac_compile\"") >&5
2710  (eval $ac_compile) 2>&5
2711  ac_status=$?
2712  echo "$as_me:2712: \$? = $ac_status" >&5
2713  (exit $ac_status); } &&
2714         { ac_try='test -s conftest.$ac_objext'
2715  { (eval echo "$as_me:2715: \"$ac_try\"") >&5
2716  (eval $ac_try) 2>&5
2717  ac_status=$?
2718  echo "$as_me:2718: \$? = $ac_status" >&5
2719  (exit $ac_status); }; }; then
2720  ac_cv_c_char_unsigned=no
2721else
2722  echo "$as_me: failed program was:" >&5
2723cat conftest.$ac_ext >&5
2724ac_cv_c_char_unsigned=yes
2725fi
2726rm -f conftest.$ac_objext conftest.$ac_ext
2727fi
2728echo "$as_me:2728: result: $ac_cv_c_char_unsigned" >&5
2729echo "${ECHO_T}$ac_cv_c_char_unsigned" >&6
2730if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then
2731  cat >>confdefs.h <<\EOF
2732#define __CHAR_UNSIGNED__ 1
2733EOF
2734
2735fi
2736
2737echo "$as_me:2737: checking return type of signal handlers" >&5
2738echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6
2739if test "${ac_cv_type_signal+set}" = set; then
2740  echo $ECHO_N "(cached) $ECHO_C" >&6
2741else
2742  cat >conftest.$ac_ext <<_ACEOF
2743#line 2743 "configure"
2744#include "confdefs.h"
2745#include <sys/types.h>
2746#include <signal.h>
2747#ifdef signal
2748# undef signal
2749#endif
2750#ifdef __cplusplus
2751extern "C" void (*signal (int, void (*)(int)))(int);
2752#else
2753void (*signal ()) ();
2754#endif
2755
2756int
2757main ()
2758{
2759int i;
2760  ;
2761  return 0;
2762}
2763_ACEOF
2764rm -f conftest.$ac_objext
2765if { (eval echo "$as_me:2765: \"$ac_compile\"") >&5
2766  (eval $ac_compile) 2>&5
2767  ac_status=$?
2768  echo "$as_me:2768: \$? = $ac_status" >&5
2769  (exit $ac_status); } &&
2770         { ac_try='test -s conftest.$ac_objext'
2771  { (eval echo "$as_me:2771: \"$ac_try\"") >&5
2772  (eval $ac_try) 2>&5
2773  ac_status=$?
2774  echo "$as_me:2774: \$? = $ac_status" >&5
2775  (exit $ac_status); }; }; then
2776  ac_cv_type_signal=void
2777else
2778  echo "$as_me: failed program was:" >&5
2779cat conftest.$ac_ext >&5
2780ac_cv_type_signal=int
2781fi
2782rm -f conftest.$ac_objext conftest.$ac_ext
2783fi
2784echo "$as_me:2784: result: $ac_cv_type_signal" >&5
2785echo "${ECHO_T}$ac_cv_type_signal" >&6
2786
2787cat >>confdefs.h <<EOF
2788#define RETSIGTYPE $ac_cv_type_signal
2789EOF
2790
2791echo "$as_me:2791: checking for size_t" >&5
2792echo $ECHO_N "checking for size_t... $ECHO_C" >&6
2793if test "${ac_cv_type_size_t+set}" = set; then
2794  echo $ECHO_N "(cached) $ECHO_C" >&6
2795else
2796  cat >conftest.$ac_ext <<_ACEOF
2797#line 2797 "configure"
2798#include "confdefs.h"
2799$ac_includes_default
2800int
2801main ()
2802{
2803if ((size_t *) 0)
2804  return 0;
2805if (sizeof (size_t))
2806  return 0;
2807  ;
2808  return 0;
2809}
2810_ACEOF
2811rm -f conftest.$ac_objext
2812if { (eval echo "$as_me:2812: \"$ac_compile\"") >&5
2813  (eval $ac_compile) 2>&5
2814  ac_status=$?
2815  echo "$as_me:2815: \$? = $ac_status" >&5
2816  (exit $ac_status); } &&
2817         { ac_try='test -s conftest.$ac_objext'
2818  { (eval echo "$as_me:2818: \"$ac_try\"") >&5
2819  (eval $ac_try) 2>&5
2820  ac_status=$?
2821  echo "$as_me:2821: \$? = $ac_status" >&5
2822  (exit $ac_status); }; }; then
2823  ac_cv_type_size_t=yes
2824else
2825  echo "$as_me: failed program was:" >&5
2826cat conftest.$ac_ext >&5
2827ac_cv_type_size_t=no
2828fi
2829rm -f conftest.$ac_objext conftest.$ac_ext
2830fi
2831echo "$as_me:2831: result: $ac_cv_type_size_t" >&5
2832echo "${ECHO_T}$ac_cv_type_size_t" >&6
2833if test $ac_cv_type_size_t = yes; then
2834  :
2835else
2836
2837cat >>confdefs.h <<EOF
2838#define size_t unsigned
2839EOF
2840
2841fi
2842
2843echo "$as_me:2843: checking for ssize_t" >&5
2844echo $ECHO_N "checking for ssize_t... $ECHO_C" >&6
2845if test "${ac_cv_type_ssize_t+set}" = set; then
2846  echo $ECHO_N "(cached) $ECHO_C" >&6
2847else
2848  cat >conftest.$ac_ext <<_ACEOF
2849#line 2849 "configure"
2850#include "confdefs.h"
2851$ac_includes_default
2852int
2853main ()
2854{
2855if ((ssize_t *) 0)
2856  return 0;
2857if (sizeof (ssize_t))
2858  return 0;
2859  ;
2860  return 0;
2861}
2862_ACEOF
2863rm -f conftest.$ac_objext
2864if { (eval echo "$as_me:2864: \"$ac_compile\"") >&5
2865  (eval $ac_compile) 2>&5
2866  ac_status=$?
2867  echo "$as_me:2867: \$? = $ac_status" >&5
2868  (exit $ac_status); } &&
2869         { ac_try='test -s conftest.$ac_objext'
2870  { (eval echo "$as_me:2870: \"$ac_try\"") >&5
2871  (eval $ac_try) 2>&5
2872  ac_status=$?
2873  echo "$as_me:2873: \$? = $ac_status" >&5
2874  (exit $ac_status); }; }; then
2875  ac_cv_type_ssize_t=yes
2876else
2877  echo "$as_me: failed program was:" >&5
2878cat conftest.$ac_ext >&5
2879ac_cv_type_ssize_t=no
2880fi
2881rm -f conftest.$ac_objext conftest.$ac_ext
2882fi
2883echo "$as_me:2883: result: $ac_cv_type_ssize_t" >&5
2884echo "${ECHO_T}$ac_cv_type_ssize_t" >&6
2885if test $ac_cv_type_ssize_t = yes; then
2886  :
2887else
2888
2889cat >>confdefs.h <<EOF
2890#define ssize_t int
2891EOF
2892
2893fi
2894
2895echo "$as_me:2895: checking whether stat file-mode macros are broken" >&5
2896echo $ECHO_N "checking whether stat file-mode macros are broken... $ECHO_C" >&6
2897if test "${ac_cv_header_stat_broken+set}" = set; then
2898  echo $ECHO_N "(cached) $ECHO_C" >&6
2899else
2900  cat >conftest.$ac_ext <<_ACEOF
2901#line 2901 "configure"
2902#include "confdefs.h"
2903#include <sys/types.h>
2904#include <sys/stat.h>
2905
2906#if defined(S_ISBLK) && defined(S_IFDIR)
2907# if S_ISBLK (S_IFDIR)
2908You lose.
2909# endif
2910#endif
2911
2912#if defined(S_ISBLK) && defined(S_IFCHR)
2913# if S_ISBLK (S_IFCHR)
2914You lose.
2915# endif
2916#endif
2917
2918#if defined(S_ISLNK) && defined(S_IFREG)
2919# if S_ISLNK (S_IFREG)
2920You lose.
2921# endif
2922#endif
2923
2924#if defined(S_ISSOCK) && defined(S_IFREG)
2925# if S_ISSOCK (S_IFREG)
2926You lose.
2927# endif
2928#endif
2929
2930_ACEOF
2931if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2932  egrep "You lose" >/dev/null 2>&1; then
2933  ac_cv_header_stat_broken=yes
2934else
2935  ac_cv_header_stat_broken=no
2936fi
2937rm -f conftest*
2938
2939fi
2940echo "$as_me:2940: result: $ac_cv_header_stat_broken" >&5
2941echo "${ECHO_T}$ac_cv_header_stat_broken" >&6
2942if test $ac_cv_header_stat_broken = yes; then
2943
2944cat >>confdefs.h <<\EOF
2945#define STAT_MACROS_BROKEN 1
2946EOF
2947
2948fi
2949
2950ac_header_dirent=no
2951for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
2952  as_ac_Header=`echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
2953echo "$as_me:2953: checking for $ac_hdr that defines DIR" >&5
2954echo $ECHO_N "checking for $ac_hdr that defines DIR... $ECHO_C" >&6
2955if eval "test \"\${$as_ac_Header+set}\" = set"; then
2956  echo $ECHO_N "(cached) $ECHO_C" >&6
2957else
2958  cat >conftest.$ac_ext <<_ACEOF
2959#line 2959 "configure"
2960#include "confdefs.h"
2961#include <sys/types.h>
2962#include <$ac_hdr>
2963
2964int
2965main ()
2966{
2967if ((DIR *) 0)
2968return 0;
2969  ;
2970  return 0;
2971}
2972_ACEOF
2973rm -f conftest.$ac_objext
2974if { (eval echo "$as_me:2974: \"$ac_compile\"") >&5
2975  (eval $ac_compile) 2>&5
2976  ac_status=$?
2977  echo "$as_me:2977: \$? = $ac_status" >&5
2978  (exit $ac_status); } &&
2979         { ac_try='test -s conftest.$ac_objext'
2980  { (eval echo "$as_me:2980: \"$ac_try\"") >&5
2981  (eval $ac_try) 2>&5
2982  ac_status=$?
2983  echo "$as_me:2983: \$? = $ac_status" >&5
2984  (exit $ac_status); }; }; then
2985  eval "$as_ac_Header=yes"
2986else
2987  echo "$as_me: failed program was:" >&5
2988cat conftest.$ac_ext >&5
2989eval "$as_ac_Header=no"
2990fi
2991rm -f conftest.$ac_objext conftest.$ac_ext
2992fi
2993echo "$as_me:2993: result: `eval echo '${'$as_ac_Header'}'`" >&5
2994echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
2995if test `eval echo '${'$as_ac_Header'}'` = yes; then
2996  cat >>confdefs.h <<EOF
2997#define `echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
2998EOF
2999
3000ac_header_dirent=$ac_hdr; break
3001fi
3002
3003done
3004# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
3005if test $ac_header_dirent = dirent.h; then
3006  echo "$as_me:3006: checking for opendir in -ldir" >&5
3007echo $ECHO_N "checking for opendir in -ldir... $ECHO_C" >&6
3008if test "${ac_cv_lib_dir_opendir+set}" = set; then
3009  echo $ECHO_N "(cached) $ECHO_C" >&6
3010else
3011  ac_check_lib_save_LIBS=$LIBS
3012LIBS="-ldir  $LIBS"
3013cat >conftest.$ac_ext <<_ACEOF
3014#line 3014 "configure"
3015#include "confdefs.h"
3016
3017/* Override any gcc2 internal prototype to avoid an error.  */
3018#ifdef __cplusplus
3019extern "C"
3020#endif
3021/* We use char because int might match the return type of a gcc2
3022   builtin and then its argument prototype would still apply.  */
3023char opendir ();
3024int
3025main ()
3026{
3027opendir ();
3028  ;
3029  return 0;
3030}
3031_ACEOF
3032rm -f conftest.$ac_objext conftest$ac_exeext
3033if { (eval echo "$as_me:3033: \"$ac_link\"") >&5
3034  (eval $ac_link) 2>&5
3035  ac_status=$?
3036  echo "$as_me:3036: \$? = $ac_status" >&5
3037  (exit $ac_status); } &&
3038         { ac_try='test -s conftest$ac_exeext'
3039  { (eval echo "$as_me:3039: \"$ac_try\"") >&5
3040  (eval $ac_try) 2>&5
3041  ac_status=$?
3042  echo "$as_me:3042: \$? = $ac_status" >&5
3043  (exit $ac_status); }; }; then
3044  ac_cv_lib_dir_opendir=yes
3045else
3046  echo "$as_me: failed program was:" >&5
3047cat conftest.$ac_ext >&5
3048ac_cv_lib_dir_opendir=no
3049fi
3050rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
3051LIBS=$ac_check_lib_save_LIBS
3052fi
3053echo "$as_me:3053: result: $ac_cv_lib_dir_opendir" >&5
3054echo "${ECHO_T}$ac_cv_lib_dir_opendir" >&6
3055if test $ac_cv_lib_dir_opendir = yes; then
3056  LIBS="$LIBS -ldir"
3057fi
3058
3059else
3060  echo "$as_me:3060: checking for opendir in -lx" >&5
3061echo $ECHO_N "checking for opendir in -lx... $ECHO_C" >&6
3062if test "${ac_cv_lib_x_opendir+set}" = set; then
3063  echo $ECHO_N "(cached) $ECHO_C" >&6
3064else
3065  ac_check_lib_save_LIBS=$LIBS
3066LIBS="-lx  $LIBS"
3067cat >conftest.$ac_ext <<_ACEOF
3068#line 3068 "configure"
3069#include "confdefs.h"
3070
3071/* Override any gcc2 internal prototype to avoid an error.  */
3072#ifdef __cplusplus
3073extern "C"
3074#endif
3075/* We use char because int might match the return type of a gcc2
3076   builtin and then its argument prototype would still apply.  */
3077char opendir ();
3078int
3079main ()
3080{
3081opendir ();
3082  ;
3083  return 0;
3084}
3085_ACEOF
3086rm -f conftest.$ac_objext conftest$ac_exeext
3087if { (eval echo "$as_me:3087: \"$ac_link\"") >&5
3088  (eval $ac_link) 2>&5
3089  ac_status=$?
3090  echo "$as_me:3090: \$? = $ac_status" >&5
3091  (exit $ac_status); } &&
3092         { ac_try='test -s conftest$ac_exeext'
3093  { (eval echo "$as_me:3093: \"$ac_try\"") >&5
3094  (eval $ac_try) 2>&5
3095  ac_status=$?
3096  echo "$as_me:3096: \$? = $ac_status" >&5
3097  (exit $ac_status); }; }; then
3098  ac_cv_lib_x_opendir=yes
3099else
3100  echo "$as_me: failed program was:" >&5
3101cat conftest.$ac_ext >&5
3102ac_cv_lib_x_opendir=no
3103fi
3104rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
3105LIBS=$ac_check_lib_save_LIBS
3106fi
3107echo "$as_me:3107: result: $ac_cv_lib_x_opendir" >&5
3108echo "${ECHO_T}$ac_cv_lib_x_opendir" >&6
3109if test $ac_cv_lib_x_opendir = yes; then
3110  LIBS="$LIBS -lx"
3111fi
3112
3113fi
3114
3115for ac_func in lstat memmove putenv select setenv setlocale \
3116		strcasecmp strpbrk tcgetattr vsnprintf isascii isxdigit
3117do
3118as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
3119echo "$as_me:3119: checking for $ac_func" >&5
3120echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
3121if eval "test \"\${$as_ac_var+set}\" = set"; then
3122  echo $ECHO_N "(cached) $ECHO_C" >&6
3123else
3124  cat >conftest.$ac_ext <<_ACEOF
3125#line 3125 "configure"
3126#include "confdefs.h"
3127/* System header to define __stub macros and hopefully few prototypes,
3128    which can conflict with char $ac_func (); below.  */
3129#include <assert.h>
3130/* Override any gcc2 internal prototype to avoid an error.  */
3131#ifdef __cplusplus
3132extern "C"
3133#endif
3134/* We use char because int might match the return type of a gcc2
3135   builtin and then its argument prototype would still apply.  */
3136char $ac_func ();
3137char (*f) ();
3138
3139int
3140main ()
3141{
3142/* The GNU C library defines this for functions which it implements
3143    to always fail with ENOSYS.  Some functions are actually named
3144    something starting with __ and the normal name is an alias.  */
3145#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3146choke me
3147#else
3148f = $ac_func;
3149#endif
3150
3151  ;
3152  return 0;
3153}
3154_ACEOF
3155rm -f conftest.$ac_objext conftest$ac_exeext
3156if { (eval echo "$as_me:3156: \"$ac_link\"") >&5
3157  (eval $ac_link) 2>&5
3158  ac_status=$?
3159  echo "$as_me:3159: \$? = $ac_status" >&5
3160  (exit $ac_status); } &&
3161         { ac_try='test -s conftest$ac_exeext'
3162  { (eval echo "$as_me:3162: \"$ac_try\"") >&5
3163  (eval $ac_try) 2>&5
3164  ac_status=$?
3165  echo "$as_me:3165: \$? = $ac_status" >&5
3166  (exit $ac_status); }; }; then
3167  eval "$as_ac_var=yes"
3168else
3169  echo "$as_me: failed program was:" >&5
3170cat conftest.$ac_ext >&5
3171eval "$as_ac_var=no"
3172fi
3173rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
3174fi
3175echo "$as_me:3175: result: `eval echo '${'$as_ac_var'}'`" >&5
3176echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
3177if test `eval echo '${'$as_ac_var'}'` = yes; then
3178  cat >>confdefs.h <<EOF
3179#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
3180EOF
3181
3182fi
3183done
3184
3185echo "$as_me:3185: checking for working strcoll" >&5
3186echo $ECHO_N "checking for working strcoll... $ECHO_C" >&6
3187if test "${ac_cv_func_strcoll_works+set}" = set; then
3188  echo $ECHO_N "(cached) $ECHO_C" >&6
3189else
3190  if test "$cross_compiling" = yes; then
3191  ac_cv_func_strcoll_works=no
3192else
3193  cat >conftest.$ac_ext <<_ACEOF
3194#line 3194 "configure"
3195#include "confdefs.h"
3196$ac_includes_default
3197int
3198main ()
3199{
3200exit (strcoll ("abc", "def") >= 0 ||
3201	 strcoll ("ABC", "DEF") >= 0 ||
3202	 strcoll ("123", "456") >= 0)
3203  ;
3204  return 0;
3205}
3206_ACEOF
3207rm -f conftest$ac_exeext
3208if { (eval echo "$as_me:3208: \"$ac_link\"") >&5
3209  (eval $ac_link) 2>&5
3210  ac_status=$?
3211  echo "$as_me:3211: \$? = $ac_status" >&5
3212  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
3213  { (eval echo "$as_me:3213: \"$ac_try\"") >&5
3214  (eval $ac_try) 2>&5
3215  ac_status=$?
3216  echo "$as_me:3216: \$? = $ac_status" >&5
3217  (exit $ac_status); }; }; then
3218  ac_cv_func_strcoll_works=yes
3219else
3220  echo "$as_me: program exited with status $ac_status" >&5
3221echo "$as_me: failed program was:" >&5
3222cat conftest.$ac_ext >&5
3223ac_cv_func_strcoll_works=no
3224fi
3225rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
3226fi
3227fi
3228echo "$as_me:3228: result: $ac_cv_func_strcoll_works" >&5
3229echo "${ECHO_T}$ac_cv_func_strcoll_works" >&6
3230if test $ac_cv_func_strcoll_works = yes; then
3231
3232cat >>confdefs.h <<\EOF
3233#define HAVE_STRCOLL 1
3234EOF
3235
3236fi
3237
3238for ac_header in unistd.h stdlib.h varargs.h stdarg.h string.h strings.h \
3239		limits.h sys/ptem.h sys/pte.h sys/stream.h sys/select.h \
3240		termcap.h termios.h termio.h sys/file.h locale.h memory.h
3241do
3242as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
3243echo "$as_me:3243: checking for $ac_header" >&5
3244echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3245if eval "test \"\${$as_ac_Header+set}\" = set"; then
3246  echo $ECHO_N "(cached) $ECHO_C" >&6
3247else
3248  cat >conftest.$ac_ext <<_ACEOF
3249#line 3249 "configure"
3250#include "confdefs.h"
3251#include <$ac_header>
3252_ACEOF
3253if { (eval echo "$as_me:3253: \"$ac_cpp conftest.$ac_ext\"") >&5
3254  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3255  ac_status=$?
3256  egrep -v '^ *\+' conftest.er1 >conftest.err
3257  rm -f conftest.er1
3258  cat conftest.err >&5
3259  echo "$as_me:3259: \$? = $ac_status" >&5
3260  (exit $ac_status); } >/dev/null; then
3261  if test -s conftest.err; then
3262    ac_cpp_err=$ac_c_preproc_warn_flag
3263  else
3264    ac_cpp_err=
3265  fi
3266else
3267  ac_cpp_err=yes
3268fi
3269if test -z "$ac_cpp_err"; then
3270  eval "$as_ac_Header=yes"
3271else
3272  echo "$as_me: failed program was:" >&5
3273  cat conftest.$ac_ext >&5
3274  eval "$as_ac_Header=no"
3275fi
3276rm -f conftest.err conftest.$ac_ext
3277fi
3278echo "$as_me:3278: result: `eval echo '${'$as_ac_Header'}'`" >&5
3279echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
3280if test `eval echo '${'$as_ac_Header'}'` = yes; then
3281  cat >>confdefs.h <<EOF
3282#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
3283EOF
3284
3285fi
3286done
3287
3288echo "$as_me:3288: checking for type of signal functions" >&5
3289echo $ECHO_N "checking for type of signal functions... $ECHO_C" >&6
3290if test "${bash_cv_signal_vintage+set}" = set; then
3291  echo $ECHO_N "(cached) $ECHO_C" >&6
3292else
3293
3294  cat >conftest.$ac_ext <<_ACEOF
3295#line 3295 "configure"
3296#include "confdefs.h"
3297#include <signal.h>
3298int
3299main ()
3300{
3301
3302    sigset_t ss;
3303    struct sigaction sa;
3304    sigemptyset(&ss); sigsuspend(&ss);
3305    sigaction(SIGINT, &sa, (struct sigaction *) 0);
3306    sigprocmask(SIG_BLOCK, &ss, (sigset_t *) 0);
3307
3308  ;
3309  return 0;
3310}
3311_ACEOF
3312rm -f conftest.$ac_objext conftest$ac_exeext
3313if { (eval echo "$as_me:3313: \"$ac_link\"") >&5
3314  (eval $ac_link) 2>&5
3315  ac_status=$?
3316  echo "$as_me:3316: \$? = $ac_status" >&5
3317  (exit $ac_status); } &&
3318         { ac_try='test -s conftest$ac_exeext'
3319  { (eval echo "$as_me:3319: \"$ac_try\"") >&5
3320  (eval $ac_try) 2>&5
3321  ac_status=$?
3322  echo "$as_me:3322: \$? = $ac_status" >&5
3323  (exit $ac_status); }; }; then
3324  bash_cv_signal_vintage=posix
3325else
3326  echo "$as_me: failed program was:" >&5
3327cat conftest.$ac_ext >&5
3328
3329    cat >conftest.$ac_ext <<_ACEOF
3330#line 3330 "configure"
3331#include "confdefs.h"
3332#include <signal.h>
3333int
3334main ()
3335{
3336
3337	int mask = sigmask(SIGINT);
3338	sigsetmask(mask); sigblock(mask); sigpause(mask);
3339
3340  ;
3341  return 0;
3342}
3343_ACEOF
3344rm -f conftest.$ac_objext conftest$ac_exeext
3345if { (eval echo "$as_me:3345: \"$ac_link\"") >&5
3346  (eval $ac_link) 2>&5
3347  ac_status=$?
3348  echo "$as_me:3348: \$? = $ac_status" >&5
3349  (exit $ac_status); } &&
3350         { ac_try='test -s conftest$ac_exeext'
3351  { (eval echo "$as_me:3351: \"$ac_try\"") >&5
3352  (eval $ac_try) 2>&5
3353  ac_status=$?
3354  echo "$as_me:3354: \$? = $ac_status" >&5
3355  (exit $ac_status); }; }; then
3356  bash_cv_signal_vintage=4.2bsd
3357else
3358  echo "$as_me: failed program was:" >&5
3359cat conftest.$ac_ext >&5
3360
3361      cat >conftest.$ac_ext <<_ACEOF
3362#line 3362 "configure"
3363#include "confdefs.h"
3364
3365	#include <signal.h>
3366	RETSIGTYPE foo() { }
3367int
3368main ()
3369{
3370
3371		int mask = sigmask(SIGINT);
3372		sigset(SIGINT, foo); sigrelse(SIGINT);
3373		sighold(SIGINT); sigpause(SIGINT);
3374
3375  ;
3376  return 0;
3377}
3378_ACEOF
3379rm -f conftest.$ac_objext conftest$ac_exeext
3380if { (eval echo "$as_me:3380: \"$ac_link\"") >&5
3381  (eval $ac_link) 2>&5
3382  ac_status=$?
3383  echo "$as_me:3383: \$? = $ac_status" >&5
3384  (exit $ac_status); } &&
3385         { ac_try='test -s conftest$ac_exeext'
3386  { (eval echo "$as_me:3386: \"$ac_try\"") >&5
3387  (eval $ac_try) 2>&5
3388  ac_status=$?
3389  echo "$as_me:3389: \$? = $ac_status" >&5
3390  (exit $ac_status); }; }; then
3391  bash_cv_signal_vintage=svr3
3392else
3393  echo "$as_me: failed program was:" >&5
3394cat conftest.$ac_ext >&5
3395bash_cv_signal_vintage=v7
3396
3397fi
3398rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
3399
3400fi
3401rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
3402
3403fi
3404rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
3405
3406fi
3407
3408echo "$as_me:3408: result: $bash_cv_signal_vintage" >&5
3409echo "${ECHO_T}$bash_cv_signal_vintage" >&6
3410if test "$bash_cv_signal_vintage" = posix; then
3411cat >>confdefs.h <<\EOF
3412#define HAVE_POSIX_SIGNALS 1
3413EOF
3414
3415elif test "$bash_cv_signal_vintage" = "4.2bsd"; then
3416cat >>confdefs.h <<\EOF
3417#define HAVE_BSD_SIGNALS 1
3418EOF
3419
3420elif test "$bash_cv_signal_vintage" = svr3; then
3421cat >>confdefs.h <<\EOF
3422#define HAVE_USG_SIGHOLD 1
3423EOF
3424
3425fi
3426
3427echo "$as_me:3427: checking if signal handlers must be reinstalled when invoked" >&5
3428echo $ECHO_N "checking if signal handlers must be reinstalled when invoked... $ECHO_C" >&6
3429if test "${bash_cv_must_reinstall_sighandlers+set}" = set; then
3430  echo $ECHO_N "(cached) $ECHO_C" >&6
3431else
3432  if test "$cross_compiling" = yes; then
3433  { echo "$as_me:3433: WARNING: cannot check signal handling if cross compiling -- defaulting to no" >&5
3434echo "$as_me: WARNING: cannot check signal handling if cross compiling -- defaulting to no" >&2;}
3435    bash_cv_must_reinstall_sighandlers=no
3436
3437else
3438  cat >conftest.$ac_ext <<_ACEOF
3439#line 3439 "configure"
3440#include "confdefs.h"
3441
3442#include <signal.h>
3443#ifdef HAVE_UNISTD_H
3444#include <unistd.h>
3445#endif
3446
3447typedef RETSIGTYPE sigfunc();
3448
3449int nsigint;
3450
3451#ifdef HAVE_POSIX_SIGNALS
3452sigfunc *
3453set_signal_handler(sig, handler)
3454     int sig;
3455     sigfunc *handler;
3456{
3457  struct sigaction act, oact;
3458  act.sa_handler = handler;
3459  act.sa_flags = 0;
3460  sigemptyset (&act.sa_mask);
3461  sigemptyset (&oact.sa_mask);
3462  sigaction (sig, &act, &oact);
3463  return (oact.sa_handler);
3464}
3465#else
3466#define set_signal_handler(s, h) signal(s, h)
3467#endif
3468
3469RETSIGTYPE
3470sigint(s)
3471int s;
3472{
3473  nsigint++;
3474}
3475
3476main()
3477{
3478	nsigint = 0;
3479	set_signal_handler(SIGINT, sigint);
3480	kill((int)getpid(), SIGINT);
3481	kill((int)getpid(), SIGINT);
3482	exit(nsigint != 2);
3483}
3484
3485_ACEOF
3486rm -f conftest$ac_exeext
3487if { (eval echo "$as_me:3487: \"$ac_link\"") >&5
3488  (eval $ac_link) 2>&5
3489  ac_status=$?
3490  echo "$as_me:3490: \$? = $ac_status" >&5
3491  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
3492  { (eval echo "$as_me:3492: \"$ac_try\"") >&5
3493  (eval $ac_try) 2>&5
3494  ac_status=$?
3495  echo "$as_me:3495: \$? = $ac_status" >&5
3496  (exit $ac_status); }; }; then
3497  bash_cv_must_reinstall_sighandlers=no
3498else
3499  echo "$as_me: program exited with status $ac_status" >&5
3500echo "$as_me: failed program was:" >&5
3501cat conftest.$ac_ext >&5
3502bash_cv_must_reinstall_sighandlers=yes
3503fi
3504rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
3505fi
3506fi
3507
3508echo "$as_me:3508: result: $bash_cv_must_reinstall_sighandlers" >&5
3509echo "${ECHO_T}$bash_cv_must_reinstall_sighandlers" >&6
3510if test $bash_cv_must_reinstall_sighandlers = yes; then
3511cat >>confdefs.h <<\EOF
3512#define MUST_REINSTALL_SIGHANDLERS 1
3513EOF
3514
3515fi
3516
3517echo "$as_me:3517: checking for presence of POSIX-style sigsetjmp/siglongjmp" >&5
3518echo $ECHO_N "checking for presence of POSIX-style sigsetjmp/siglongjmp... $ECHO_C" >&6
3519if test "${bash_cv_func_sigsetjmp+set}" = set; then
3520  echo $ECHO_N "(cached) $ECHO_C" >&6
3521else
3522  if test "$cross_compiling" = yes; then
3523  { echo "$as_me:3523: WARNING: cannot check for sigsetjmp/siglongjmp if cross-compiling -- defaulting to missing" >&5
3524echo "$as_me: WARNING: cannot check for sigsetjmp/siglongjmp if cross-compiling -- defaulting to missing" >&2;}
3525     bash_cv_func_sigsetjmp=missing
3526
3527else
3528  cat >conftest.$ac_ext <<_ACEOF
3529#line 3529 "configure"
3530#include "confdefs.h"
3531
3532#ifdef HAVE_UNISTD_H
3533#include <unistd.h>
3534#endif
3535#include <sys/types.h>
3536#include <signal.h>
3537#include <setjmp.h>
3538
3539main()
3540{
3541#if !defined (_POSIX_VERSION) || !defined (HAVE_POSIX_SIGNALS)
3542exit (1);
3543#else
3544
3545int code;
3546sigset_t set, oset;
3547sigjmp_buf xx;
3548
3549/* get the mask */
3550sigemptyset(&set);
3551sigemptyset(&oset);
3552sigprocmask(SIG_BLOCK, (sigset_t *)NULL, &set);
3553sigprocmask(SIG_BLOCK, (sigset_t *)NULL, &oset);
3554
3555/* save it */
3556code = sigsetjmp(xx, 1);
3557if (code)
3558  exit(0);	/* could get sigmask and compare to oset here. */
3559
3560/* change it */
3561sigaddset(&set, SIGINT);
3562sigprocmask(SIG_BLOCK, &set, (sigset_t *)NULL);
3563
3564/* and siglongjmp */
3565siglongjmp(xx, 10);
3566exit(1);
3567#endif
3568}
3569_ACEOF
3570rm -f conftest$ac_exeext
3571if { (eval echo "$as_me:3571: \"$ac_link\"") >&5
3572  (eval $ac_link) 2>&5
3573  ac_status=$?
3574  echo "$as_me:3574: \$? = $ac_status" >&5
3575  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
3576  { (eval echo "$as_me:3576: \"$ac_try\"") >&5
3577  (eval $ac_try) 2>&5
3578  ac_status=$?
3579  echo "$as_me:3579: \$? = $ac_status" >&5
3580  (exit $ac_status); }; }; then
3581  bash_cv_func_sigsetjmp=present
3582else
3583  echo "$as_me: program exited with status $ac_status" >&5
3584echo "$as_me: failed program was:" >&5
3585cat conftest.$ac_ext >&5
3586bash_cv_func_sigsetjmp=missing
3587fi
3588rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
3589fi
3590fi
3591
3592echo "$as_me:3592: result: $bash_cv_func_sigsetjmp" >&5
3593echo "${ECHO_T}$bash_cv_func_sigsetjmp" >&6
3594if test $bash_cv_func_sigsetjmp = present; then
3595cat >>confdefs.h <<\EOF
3596#define HAVE_POSIX_SIGSETJMP 1
3597EOF
3598
3599fi
3600
3601echo "$as_me:3601: checking for lstat" >&5
3602echo $ECHO_N "checking for lstat... $ECHO_C" >&6
3603if test "${bash_cv_func_lstat+set}" = set; then
3604  echo $ECHO_N "(cached) $ECHO_C" >&6
3605else
3606  cat >conftest.$ac_ext <<_ACEOF
3607#line 3607 "configure"
3608#include "confdefs.h"
3609
3610#include <sys/types.h>
3611#include <sys/stat.h>
3612
3613int
3614main ()
3615{
3616 lstat(".",(struct stat *)0);
3617  ;
3618  return 0;
3619}
3620_ACEOF
3621rm -f conftest.$ac_objext conftest$ac_exeext
3622if { (eval echo "$as_me:3622: \"$ac_link\"") >&5
3623  (eval $ac_link) 2>&5
3624  ac_status=$?
3625  echo "$as_me:3625: \$? = $ac_status" >&5
3626  (exit $ac_status); } &&
3627         { ac_try='test -s conftest$ac_exeext'
3628  { (eval echo "$as_me:3628: \"$ac_try\"") >&5
3629  (eval $ac_try) 2>&5
3630  ac_status=$?
3631  echo "$as_me:3631: \$? = $ac_status" >&5
3632  (exit $ac_status); }; }; then
3633  bash_cv_func_lstat=yes
3634else
3635  echo "$as_me: failed program was:" >&5
3636cat conftest.$ac_ext >&5
3637bash_cv_func_lstat=no
3638fi
3639rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
3640fi
3641echo "$as_me:3641: result: $bash_cv_func_lstat" >&5
3642echo "${ECHO_T}$bash_cv_func_lstat" >&6
3643if test $bash_cv_func_lstat = yes; then
3644  cat >>confdefs.h <<\EOF
3645#define HAVE_LSTAT 1
3646EOF
3647
3648fi
3649
3650echo "$as_me:3650: checking whether or not strcoll and strcmp differ" >&5
3651echo $ECHO_N "checking whether or not strcoll and strcmp differ... $ECHO_C" >&6
3652if test "${bash_cv_func_strcoll_broken+set}" = set; then
3653  echo $ECHO_N "(cached) $ECHO_C" >&6
3654else
3655  if test "$cross_compiling" = yes; then
3656  { echo "$as_me:3656: WARNING: cannot check strcoll if cross compiling -- defaulting to no" >&5
3657echo "$as_me: WARNING: cannot check strcoll if cross compiling -- defaulting to no" >&2;}
3658    bash_cv_func_strcoll_broken=no
3659
3660else
3661  cat >conftest.$ac_ext <<_ACEOF
3662#line 3662 "configure"
3663#include "confdefs.h"
3664
3665#include <stdio.h>
3666#if defined (HAVE_LOCALE_H)
3667#include <locale.h>
3668#endif
3669
3670main(c, v)
3671int     c;
3672char    *v[];
3673{
3674        int     r1, r2;
3675        char    *deflocale, *defcoll;
3676
3677#ifdef HAVE_SETLOCALE
3678        deflocale = setlocale(LC_ALL, "");
3679	defcoll = setlocale(LC_COLLATE, "");
3680#endif
3681
3682#ifdef HAVE_STRCOLL
3683	/* These two values are taken from tests/glob-test. */
3684        r1 = strcoll("abd", "aXd");
3685#else
3686	r1 = 0;
3687#endif
3688        r2 = strcmp("abd", "aXd");
3689
3690	/* These two should both be greater than 0.  It is permissible for
3691	   a system to return different values, as long as the sign is the
3692	   same. */
3693
3694        /* Exit with 1 (failure) if these two values are both > 0, since
3695	   this tests whether strcoll(3) is broken with respect to strcmp(3)
3696	   in the default locale. */
3697	exit (r1 > 0 && r2 > 0);
3698}
3699
3700_ACEOF
3701rm -f conftest$ac_exeext
3702if { (eval echo "$as_me:3702: \"$ac_link\"") >&5
3703  (eval $ac_link) 2>&5
3704  ac_status=$?
3705  echo "$as_me:3705: \$? = $ac_status" >&5
3706  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
3707  { (eval echo "$as_me:3707: \"$ac_try\"") >&5
3708  (eval $ac_try) 2>&5
3709  ac_status=$?
3710  echo "$as_me:3710: \$? = $ac_status" >&5
3711  (exit $ac_status); }; }; then
3712  bash_cv_func_strcoll_broken=yes
3713else
3714  echo "$as_me: program exited with status $ac_status" >&5
3715echo "$as_me: failed program was:" >&5
3716cat conftest.$ac_ext >&5
3717bash_cv_func_strcoll_broken=no
3718fi
3719rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
3720fi
3721fi
3722
3723echo "$as_me:3723: result: $bash_cv_func_strcoll_broken" >&5
3724echo "${ECHO_T}$bash_cv_func_strcoll_broken" >&6
3725if test $bash_cv_func_strcoll_broken = yes; then
3726cat >>confdefs.h <<\EOF
3727#define STRCOLL_BROKEN 1
3728EOF
3729
3730fi
3731
3732echo "$as_me:3732: checking whether getpw functions are declared in pwd.h" >&5
3733echo $ECHO_N "checking whether getpw functions are declared in pwd.h... $ECHO_C" >&6
3734if test "${bash_cv_getpw_declared+set}" = set; then
3735  echo $ECHO_N "(cached) $ECHO_C" >&6
3736else
3737  cat >conftest.$ac_ext <<_ACEOF
3738#line 3738 "configure"
3739#include "confdefs.h"
3740
3741#include <sys/types.h>
3742#ifdef HAVE_UNISTD_H
3743#  include <unistd.h>
3744#endif
3745#include <pwd.h>
3746
3747_ACEOF
3748if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3749  egrep "getpwuid" >/dev/null 2>&1; then
3750  bash_cv_getpw_declared=yes
3751else
3752  bash_cv_getpw_declared=no
3753fi
3754rm -f conftest*
3755
3756fi
3757
3758echo "$as_me:3758: result: $bash_cv_getpw_declared" >&5
3759echo "${ECHO_T}$bash_cv_getpw_declared" >&6
3760if test $bash_cv_getpw_declared = yes; then
3761cat >>confdefs.h <<\EOF
3762#define HAVE_GETPW_DECLS 1
3763EOF
3764
3765fi
3766
3767echo "$as_me:3767: checking POSIX termios" >&5
3768echo $ECHO_N "checking POSIX termios... $ECHO_C" >&6
3769if test "${ac_cv_sys_posix_termios+set}" = set; then
3770  echo $ECHO_N "(cached) $ECHO_C" >&6
3771else
3772  cat >conftest.$ac_ext <<_ACEOF
3773#line 3773 "configure"
3774#include "confdefs.h"
3775#include <sys/types.h>
3776#include <unistd.h>
3777#include <termios.h>
3778int
3779main ()
3780{
3781/* SunOS 4.0.3 has termios.h but not the library calls.  */
3782   tcgetattr(0, 0);
3783  ;
3784  return 0;
3785}
3786_ACEOF
3787rm -f conftest.$ac_objext conftest$ac_exeext
3788if { (eval echo "$as_me:3788: \"$ac_link\"") >&5
3789  (eval $ac_link) 2>&5
3790  ac_status=$?
3791  echo "$as_me:3791: \$? = $ac_status" >&5
3792  (exit $ac_status); } &&
3793         { ac_try='test -s conftest$ac_exeext'
3794  { (eval echo "$as_me:3794: \"$ac_try\"") >&5
3795  (eval $ac_try) 2>&5
3796  ac_status=$?
3797  echo "$as_me:3797: \$? = $ac_status" >&5
3798  (exit $ac_status); }; }; then
3799  ac_cv_sys_posix_termios=yes
3800else
3801  echo "$as_me: failed program was:" >&5
3802cat conftest.$ac_ext >&5
3803ac_cv_sys_posix_termios=no
3804fi
3805rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
3806fi
3807echo "$as_me:3807: result: $ac_cv_sys_posix_termios" >&5
3808echo "${ECHO_T}$ac_cv_sys_posix_termios" >&6
3809
3810if test $ac_cv_sys_posix_termios = yes; then
3811  echo "$as_me:3811: checking whether termios.h defines TIOCGWINSZ" >&5
3812echo $ECHO_N "checking whether termios.h defines TIOCGWINSZ... $ECHO_C" >&6
3813if test "${ac_cv_sys_tiocgwinsz_in_termios_h+set}" = set; then
3814  echo $ECHO_N "(cached) $ECHO_C" >&6
3815else
3816  cat >conftest.$ac_ext <<_ACEOF
3817#line 3817 "configure"
3818#include "confdefs.h"
3819#include <sys/types.h>
3820#include <termios.h>
3821#ifdef TIOCGWINSZ
3822  yes
3823#endif
3824
3825_ACEOF
3826if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3827  egrep "yes" >/dev/null 2>&1; then
3828  ac_cv_sys_tiocgwinsz_in_termios_h=yes
3829else
3830  ac_cv_sys_tiocgwinsz_in_termios_h=no
3831fi
3832rm -f conftest*
3833
3834fi
3835echo "$as_me:3835: result: $ac_cv_sys_tiocgwinsz_in_termios_h" >&5
3836echo "${ECHO_T}$ac_cv_sys_tiocgwinsz_in_termios_h" >&6
3837
3838fi
3839if test $ac_cv_sys_tiocgwinsz_in_termios_h != yes; then
3840  echo "$as_me:3840: checking whether sys/ioctl.h defines TIOCGWINSZ" >&5
3841echo $ECHO_N "checking whether sys/ioctl.h defines TIOCGWINSZ... $ECHO_C" >&6
3842if test "${ac_cv_sys_tiocgwinsz_in_sys_ioctl_h+set}" = set; then
3843  echo $ECHO_N "(cached) $ECHO_C" >&6
3844else
3845  cat >conftest.$ac_ext <<_ACEOF
3846#line 3846 "configure"
3847#include "confdefs.h"
3848#include <sys/types.h>
3849#include <sys/ioctl.h>
3850#ifdef TIOCGWINSZ
3851  yes
3852#endif
3853
3854_ACEOF
3855if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3856  egrep "yes" >/dev/null 2>&1; then
3857  ac_cv_sys_tiocgwinsz_in_sys_ioctl_h=yes
3858else
3859  ac_cv_sys_tiocgwinsz_in_sys_ioctl_h=no
3860fi
3861rm -f conftest*
3862
3863fi
3864echo "$as_me:3864: result: $ac_cv_sys_tiocgwinsz_in_sys_ioctl_h" >&5
3865echo "${ECHO_T}$ac_cv_sys_tiocgwinsz_in_sys_ioctl_h" >&6
3866
3867  if test $ac_cv_sys_tiocgwinsz_in_sys_ioctl_h = yes; then
3868
3869cat >>confdefs.h <<\EOF
3870#define GWINSZ_IN_SYS_IOCTL 1
3871EOF
3872
3873  fi
3874fi
3875
3876echo "$as_me:3876: checking whether signal handlers are of type void" >&5
3877echo $ECHO_N "checking whether signal handlers are of type void... $ECHO_C" >&6
3878if test "${bash_cv_void_sighandler+set}" = set; then
3879  echo $ECHO_N "(cached) $ECHO_C" >&6
3880else
3881  cat >conftest.$ac_ext <<_ACEOF
3882#line 3882 "configure"
3883#include "confdefs.h"
3884#include <sys/types.h>
3885#include <signal.h>
3886#ifdef signal
3887#undef signal
3888#endif
3889#ifdef __cplusplus
3890extern "C"
3891#endif
3892void (*signal ()) ();
3893int
3894main ()
3895{
3896int i;
3897  ;
3898  return 0;
3899}
3900_ACEOF
3901rm -f conftest.$ac_objext
3902if { (eval echo "$as_me:3902: \"$ac_compile\"") >&5
3903  (eval $ac_compile) 2>&5
3904  ac_status=$?
3905  echo "$as_me:3905: \$? = $ac_status" >&5
3906  (exit $ac_status); } &&
3907         { ac_try='test -s conftest.$ac_objext'
3908  { (eval echo "$as_me:3908: \"$ac_try\"") >&5
3909  (eval $ac_try) 2>&5
3910  ac_status=$?
3911  echo "$as_me:3911: \$? = $ac_status" >&5
3912  (exit $ac_status); }; }; then
3913  bash_cv_void_sighandler=yes
3914else
3915  echo "$as_me: failed program was:" >&5
3916cat conftest.$ac_ext >&5
3917bash_cv_void_sighandler=no
3918fi
3919rm -f conftest.$ac_objext conftest.$ac_ext
3920fi
3921echo "$as_me:3921: result: $bash_cv_void_sighandler" >&5
3922echo "${ECHO_T}$bash_cv_void_sighandler" >&6
3923if test $bash_cv_void_sighandler = yes; then
3924cat >>confdefs.h <<\EOF
3925#define VOID_SIGHANDLER 1
3926EOF
3927
3928fi
3929
3930echo "$as_me:3930: checking for TIOCSTAT in sys/ioctl.h" >&5
3931echo $ECHO_N "checking for TIOCSTAT in sys/ioctl.h... $ECHO_C" >&6
3932if test "${bash_cv_tiocstat_in_ioctl+set}" = set; then
3933  echo $ECHO_N "(cached) $ECHO_C" >&6
3934else
3935  cat >conftest.$ac_ext <<_ACEOF
3936#line 3936 "configure"
3937#include "confdefs.h"
3938#include <sys/types.h>
3939#include <sys/ioctl.h>
3940int
3941main ()
3942{
3943int x = TIOCSTAT;
3944  ;
3945  return 0;
3946}
3947_ACEOF
3948rm -f conftest.$ac_objext
3949if { (eval echo "$as_me:3949: \"$ac_compile\"") >&5
3950  (eval $ac_compile) 2>&5
3951  ac_status=$?
3952  echo "$as_me:3952: \$? = $ac_status" >&5
3953  (exit $ac_status); } &&
3954         { ac_try='test -s conftest.$ac_objext'
3955  { (eval echo "$as_me:3955: \"$ac_try\"") >&5
3956  (eval $ac_try) 2>&5
3957  ac_status=$?
3958  echo "$as_me:3958: \$? = $ac_status" >&5
3959  (exit $ac_status); }; }; then
3960  bash_cv_tiocstat_in_ioctl=yes
3961else
3962  echo "$as_me: failed program was:" >&5
3963cat conftest.$ac_ext >&5
3964bash_cv_tiocstat_in_ioctl=no
3965fi
3966rm -f conftest.$ac_objext conftest.$ac_ext
3967fi
3968
3969echo "$as_me:3969: result: $bash_cv_tiocstat_in_ioctl" >&5
3970echo "${ECHO_T}$bash_cv_tiocstat_in_ioctl" >&6
3971if test $bash_cv_tiocstat_in_ioctl = yes; then
3972cat >>confdefs.h <<\EOF
3973#define TIOCSTAT_IN_SYS_IOCTL 1
3974EOF
3975
3976fi
3977
3978echo "$as_me:3978: checking for FIONREAD in sys/ioctl.h" >&5
3979echo $ECHO_N "checking for FIONREAD in sys/ioctl.h... $ECHO_C" >&6
3980if test "${bash_cv_fionread_in_ioctl+set}" = set; then
3981  echo $ECHO_N "(cached) $ECHO_C" >&6
3982else
3983  cat >conftest.$ac_ext <<_ACEOF
3984#line 3984 "configure"
3985#include "confdefs.h"
3986#include <sys/types.h>
3987#include <sys/ioctl.h>
3988int
3989main ()
3990{
3991int x = FIONREAD;
3992  ;
3993  return 0;
3994}
3995_ACEOF
3996rm -f conftest.$ac_objext
3997if { (eval echo "$as_me:3997: \"$ac_compile\"") >&5
3998  (eval $ac_compile) 2>&5
3999  ac_status=$?
4000  echo "$as_me:4000: \$? = $ac_status" >&5
4001  (exit $ac_status); } &&
4002         { ac_try='test -s conftest.$ac_objext'
4003  { (eval echo "$as_me:4003: \"$ac_try\"") >&5
4004  (eval $ac_try) 2>&5
4005  ac_status=$?
4006  echo "$as_me:4006: \$? = $ac_status" >&5
4007  (exit $ac_status); }; }; then
4008  bash_cv_fionread_in_ioctl=yes
4009else
4010  echo "$as_me: failed program was:" >&5
4011cat conftest.$ac_ext >&5
4012bash_cv_fionread_in_ioctl=no
4013fi
4014rm -f conftest.$ac_objext conftest.$ac_ext
4015fi
4016
4017echo "$as_me:4017: result: $bash_cv_fionread_in_ioctl" >&5
4018echo "${ECHO_T}$bash_cv_fionread_in_ioctl" >&6
4019if test $bash_cv_fionread_in_ioctl = yes; then
4020cat >>confdefs.h <<\EOF
4021#define FIONREAD_IN_SYS_IOCTL 1
4022EOF
4023
4024fi
4025
4026echo "$as_me:4026: checking for speed_t in sys/types.h" >&5
4027echo $ECHO_N "checking for speed_t in sys/types.h... $ECHO_C" >&6
4028if test "${bash_cv_speed_t_in_sys_types+set}" = set; then
4029  echo $ECHO_N "(cached) $ECHO_C" >&6
4030else
4031  cat >conftest.$ac_ext <<_ACEOF
4032#line 4032 "configure"
4033#include "confdefs.h"
4034#include <sys/types.h>
4035int
4036main ()
4037{
4038speed_t x;
4039  ;
4040  return 0;
4041}
4042_ACEOF
4043rm -f conftest.$ac_objext
4044if { (eval echo "$as_me:4044: \"$ac_compile\"") >&5
4045  (eval $ac_compile) 2>&5
4046  ac_status=$?
4047  echo "$as_me:4047: \$? = $ac_status" >&5
4048  (exit $ac_status); } &&
4049         { ac_try='test -s conftest.$ac_objext'
4050  { (eval echo "$as_me:4050: \"$ac_try\"") >&5
4051  (eval $ac_try) 2>&5
4052  ac_status=$?
4053  echo "$as_me:4053: \$? = $ac_status" >&5
4054  (exit $ac_status); }; }; then
4055  bash_cv_speed_t_in_sys_types=yes
4056else
4057  echo "$as_me: failed program was:" >&5
4058cat conftest.$ac_ext >&5
4059bash_cv_speed_t_in_sys_types=no
4060fi
4061rm -f conftest.$ac_objext conftest.$ac_ext
4062fi
4063
4064echo "$as_me:4064: result: $bash_cv_speed_t_in_sys_types" >&5
4065echo "${ECHO_T}$bash_cv_speed_t_in_sys_types" >&6
4066if test $bash_cv_speed_t_in_sys_types = yes; then
4067cat >>confdefs.h <<\EOF
4068#define SPEED_T_IN_SYS_TYPES 1
4069EOF
4070
4071fi
4072
4073echo "$as_me:4073: checking for struct winsize in sys/ioctl.h and termios.h" >&5
4074echo $ECHO_N "checking for struct winsize in sys/ioctl.h and termios.h... $ECHO_C" >&6
4075if test "${bash_cv_struct_winsize_header+set}" = set; then
4076  echo $ECHO_N "(cached) $ECHO_C" >&6
4077else
4078  cat >conftest.$ac_ext <<_ACEOF
4079#line 4079 "configure"
4080#include "confdefs.h"
4081#include <sys/types.h>
4082#include <sys/ioctl.h>
4083int
4084main ()
4085{
4086struct winsize x;
4087  ;
4088  return 0;
4089}
4090_ACEOF
4091rm -f conftest.$ac_objext
4092if { (eval echo "$as_me:4092: \"$ac_compile\"") >&5
4093  (eval $ac_compile) 2>&5
4094  ac_status=$?
4095  echo "$as_me:4095: \$? = $ac_status" >&5
4096  (exit $ac_status); } &&
4097         { ac_try='test -s conftest.$ac_objext'
4098  { (eval echo "$as_me:4098: \"$ac_try\"") >&5
4099  (eval $ac_try) 2>&5
4100  ac_status=$?
4101  echo "$as_me:4101: \$? = $ac_status" >&5
4102  (exit $ac_status); }; }; then
4103  bash_cv_struct_winsize_header=ioctl_h
4104else
4105  echo "$as_me: failed program was:" >&5
4106cat conftest.$ac_ext >&5
4107cat >conftest.$ac_ext <<_ACEOF
4108#line 4108 "configure"
4109#include "confdefs.h"
4110#include <sys/types.h>
4111#include <termios.h>
4112int
4113main ()
4114{
4115struct winsize x;
4116  ;
4117  return 0;
4118}
4119_ACEOF
4120rm -f conftest.$ac_objext
4121if { (eval echo "$as_me:4121: \"$ac_compile\"") >&5
4122  (eval $ac_compile) 2>&5
4123  ac_status=$?
4124  echo "$as_me:4124: \$? = $ac_status" >&5
4125  (exit $ac_status); } &&
4126         { ac_try='test -s conftest.$ac_objext'
4127  { (eval echo "$as_me:4127: \"$ac_try\"") >&5
4128  (eval $ac_try) 2>&5
4129  ac_status=$?
4130  echo "$as_me:4130: \$? = $ac_status" >&5
4131  (exit $ac_status); }; }; then
4132  bash_cv_struct_winsize_header=termios_h
4133else
4134  echo "$as_me: failed program was:" >&5
4135cat conftest.$ac_ext >&5
4136bash_cv_struct_winsize_header=other
4137fi
4138rm -f conftest.$ac_objext conftest.$ac_ext
4139
4140fi
4141rm -f conftest.$ac_objext conftest.$ac_ext
4142fi
4143
4144if test $bash_cv_struct_winsize_header = ioctl_h; then
4145  echo "$as_me:4145: result: sys/ioctl.h" >&5
4146echo "${ECHO_T}sys/ioctl.h" >&6
4147  cat >>confdefs.h <<\EOF
4148#define STRUCT_WINSIZE_IN_SYS_IOCTL 1
4149EOF
4150
4151elif test $bash_cv_struct_winsize_header = termios_h; then
4152  echo "$as_me:4152: result: termios.h" >&5
4153echo "${ECHO_T}termios.h" >&6
4154  cat >>confdefs.h <<\EOF
4155#define STRUCT_WINSIZE_IN_TERMIOS 1
4156EOF
4157
4158else
4159  echo "$as_me:4159: result: not found" >&5
4160echo "${ECHO_T}not found" >&6
4161fi
4162
4163echo "$as_me:4163: checking if struct dirent has a d_ino member" >&5
4164echo $ECHO_N "checking if struct dirent has a d_ino member... $ECHO_C" >&6
4165if test "${bash_cv_dirent_has_dino+set}" = set; then
4166  echo $ECHO_N "(cached) $ECHO_C" >&6
4167else
4168  cat >conftest.$ac_ext <<_ACEOF
4169#line 4169 "configure"
4170#include "confdefs.h"
4171
4172#include <stdio.h>
4173#include <sys/types.h>
4174#ifdef HAVE_UNISTD_H
4175# include <unistd.h>
4176#endif /* HAVE_UNISTD_H */
4177#if defined(HAVE_DIRENT_H)
4178# include <dirent.h>
4179#else
4180# define dirent direct
4181# ifdef HAVE_SYS_NDIR_H
4182#  include <sys/ndir.h>
4183# endif /* SYSNDIR */
4184# ifdef HAVE_SYS_DIR_H
4185#  include <sys/dir.h>
4186# endif /* SYSDIR */
4187# ifdef HAVE_NDIR_H
4188#  include <ndir.h>
4189# endif
4190#endif /* HAVE_DIRENT_H */
4191
4192int
4193main ()
4194{
4195
4196struct dirent d; int z; z = d.d_ino;
4197
4198  ;
4199  return 0;
4200}
4201_ACEOF
4202rm -f conftest.$ac_objext
4203if { (eval echo "$as_me:4203: \"$ac_compile\"") >&5
4204  (eval $ac_compile) 2>&5
4205  ac_status=$?
4206  echo "$as_me:4206: \$? = $ac_status" >&5
4207  (exit $ac_status); } &&
4208         { ac_try='test -s conftest.$ac_objext'
4209  { (eval echo "$as_me:4209: \"$ac_try\"") >&5
4210  (eval $ac_try) 2>&5
4211  ac_status=$?
4212  echo "$as_me:4212: \$? = $ac_status" >&5
4213  (exit $ac_status); }; }; then
4214  bash_cv_dirent_has_dino=yes
4215else
4216  echo "$as_me: failed program was:" >&5
4217cat conftest.$ac_ext >&5
4218bash_cv_dirent_has_dino=no
4219fi
4220rm -f conftest.$ac_objext conftest.$ac_ext
4221fi
4222
4223echo "$as_me:4223: result: $bash_cv_dirent_has_dino" >&5
4224echo "${ECHO_T}$bash_cv_dirent_has_dino" >&6
4225if test $bash_cv_dirent_has_dino = yes; then
4226cat >>confdefs.h <<\EOF
4227#define STRUCT_DIRENT_HAS_D_INO 1
4228EOF
4229
4230fi
4231
4232echo "$as_me:4232: checking if struct dirent has a d_fileno member" >&5
4233echo $ECHO_N "checking if struct dirent has a d_fileno member... $ECHO_C" >&6
4234if test "${bash_cv_dirent_has_d_fileno+set}" = set; then
4235  echo $ECHO_N "(cached) $ECHO_C" >&6
4236else
4237  cat >conftest.$ac_ext <<_ACEOF
4238#line 4238 "configure"
4239#include "confdefs.h"
4240
4241#include <stdio.h>
4242#include <sys/types.h>
4243#ifdef HAVE_UNISTD_H
4244# include <unistd.h>
4245#endif /* HAVE_UNISTD_H */
4246#if defined(HAVE_DIRENT_H)
4247# include <dirent.h>
4248#else
4249# define dirent direct
4250# ifdef HAVE_SYS_NDIR_H
4251#  include <sys/ndir.h>
4252# endif /* SYSNDIR */
4253# ifdef HAVE_SYS_DIR_H
4254#  include <sys/dir.h>
4255# endif /* SYSDIR */
4256# ifdef HAVE_NDIR_H
4257#  include <ndir.h>
4258# endif
4259#endif /* HAVE_DIRENT_H */
4260
4261int
4262main ()
4263{
4264
4265struct dirent d; int z; z = d.d_fileno;
4266
4267  ;
4268  return 0;
4269}
4270_ACEOF
4271rm -f conftest.$ac_objext
4272if { (eval echo "$as_me:4272: \"$ac_compile\"") >&5
4273  (eval $ac_compile) 2>&5
4274  ac_status=$?
4275  echo "$as_me:4275: \$? = $ac_status" >&5
4276  (exit $ac_status); } &&
4277         { ac_try='test -s conftest.$ac_objext'
4278  { (eval echo "$as_me:4278: \"$ac_try\"") >&5
4279  (eval $ac_try) 2>&5
4280  ac_status=$?
4281  echo "$as_me:4281: \$? = $ac_status" >&5
4282  (exit $ac_status); }; }; then
4283  bash_cv_dirent_has_d_fileno=yes
4284else
4285  echo "$as_me: failed program was:" >&5
4286cat conftest.$ac_ext >&5
4287bash_cv_dirent_has_d_fileno=no
4288fi
4289rm -f conftest.$ac_objext conftest.$ac_ext
4290fi
4291
4292echo "$as_me:4292: result: $bash_cv_dirent_has_d_fileno" >&5
4293echo "${ECHO_T}$bash_cv_dirent_has_d_fileno" >&6
4294if test $bash_cv_dirent_has_d_fileno = yes; then
4295cat >>confdefs.h <<\EOF
4296#define STRUCT_DIRENT_HAS_D_FILENO 1
4297EOF
4298
4299fi
4300
4301case "$host_os" in
4302aix*)   prefer_curses=yes ;;
4303esac
4304
4305if test "X$bash_cv_termcap_lib" = "X"; then
4306_bash_needmsg=yes
4307else
4308echo "$as_me:4308: checking which library has the termcap functions" >&5
4309echo $ECHO_N "checking which library has the termcap functions... $ECHO_C" >&6
4310_bash_needmsg=
4311fi
4312if test "${bash_cv_termcap_lib+set}" = set; then
4313  echo $ECHO_N "(cached) $ECHO_C" >&6
4314else
4315  echo "$as_me:4315: checking for tgetent in -ltermcap" >&5
4316echo $ECHO_N "checking for tgetent in -ltermcap... $ECHO_C" >&6
4317if test "${ac_cv_lib_termcap_tgetent+set}" = set; then
4318  echo $ECHO_N "(cached) $ECHO_C" >&6
4319else
4320  ac_check_lib_save_LIBS=$LIBS
4321LIBS="-ltermcap  $LIBS"
4322cat >conftest.$ac_ext <<_ACEOF
4323#line 4323 "configure"
4324#include "confdefs.h"
4325
4326/* Override any gcc2 internal prototype to avoid an error.  */
4327#ifdef __cplusplus
4328extern "C"
4329#endif
4330/* We use char because int might match the return type of a gcc2
4331   builtin and then its argument prototype would still apply.  */
4332char tgetent ();
4333int
4334main ()
4335{
4336tgetent ();
4337  ;
4338  return 0;
4339}
4340_ACEOF
4341rm -f conftest.$ac_objext conftest$ac_exeext
4342if { (eval echo "$as_me:4342: \"$ac_link\"") >&5
4343  (eval $ac_link) 2>&5
4344  ac_status=$?
4345  echo "$as_me:4345: \$? = $ac_status" >&5
4346  (exit $ac_status); } &&
4347         { ac_try='test -s conftest$ac_exeext'
4348  { (eval echo "$as_me:4348: \"$ac_try\"") >&5
4349  (eval $ac_try) 2>&5
4350  ac_status=$?
4351  echo "$as_me:4351: \$? = $ac_status" >&5
4352  (exit $ac_status); }; }; then
4353  ac_cv_lib_termcap_tgetent=yes
4354else
4355  echo "$as_me: failed program was:" >&5
4356cat conftest.$ac_ext >&5
4357ac_cv_lib_termcap_tgetent=no
4358fi
4359rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4360LIBS=$ac_check_lib_save_LIBS
4361fi
4362echo "$as_me:4362: result: $ac_cv_lib_termcap_tgetent" >&5
4363echo "${ECHO_T}$ac_cv_lib_termcap_tgetent" >&6
4364if test $ac_cv_lib_termcap_tgetent = yes; then
4365  bash_cv_termcap_lib=libtermcap
4366else
4367  echo "$as_me:4367: checking for tgetent in -ltinfo" >&5
4368echo $ECHO_N "checking for tgetent in -ltinfo... $ECHO_C" >&6
4369if test "${ac_cv_lib_tinfo_tgetent+set}" = set; then
4370  echo $ECHO_N "(cached) $ECHO_C" >&6
4371else
4372  ac_check_lib_save_LIBS=$LIBS
4373LIBS="-ltinfo  $LIBS"
4374cat >conftest.$ac_ext <<_ACEOF
4375#line 4375 "configure"
4376#include "confdefs.h"
4377
4378/* Override any gcc2 internal prototype to avoid an error.  */
4379#ifdef __cplusplus
4380extern "C"
4381#endif
4382/* We use char because int might match the return type of a gcc2
4383   builtin and then its argument prototype would still apply.  */
4384char tgetent ();
4385int
4386main ()
4387{
4388tgetent ();
4389  ;
4390  return 0;
4391}
4392_ACEOF
4393rm -f conftest.$ac_objext conftest$ac_exeext
4394if { (eval echo "$as_me:4394: \"$ac_link\"") >&5
4395  (eval $ac_link) 2>&5
4396  ac_status=$?
4397  echo "$as_me:4397: \$? = $ac_status" >&5
4398  (exit $ac_status); } &&
4399         { ac_try='test -s conftest$ac_exeext'
4400  { (eval echo "$as_me:4400: \"$ac_try\"") >&5
4401  (eval $ac_try) 2>&5
4402  ac_status=$?
4403  echo "$as_me:4403: \$? = $ac_status" >&5
4404  (exit $ac_status); }; }; then
4405  ac_cv_lib_tinfo_tgetent=yes
4406else
4407  echo "$as_me: failed program was:" >&5
4408cat conftest.$ac_ext >&5
4409ac_cv_lib_tinfo_tgetent=no
4410fi
4411rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4412LIBS=$ac_check_lib_save_LIBS
4413fi
4414echo "$as_me:4414: result: $ac_cv_lib_tinfo_tgetent" >&5
4415echo "${ECHO_T}$ac_cv_lib_tinfo_tgetent" >&6
4416if test $ac_cv_lib_tinfo_tgetent = yes; then
4417  bash_cv_termcap_lib=libtinfo
4418else
4419  echo "$as_me:4419: checking for tgetent in -lcurses" >&5
4420echo $ECHO_N "checking for tgetent in -lcurses... $ECHO_C" >&6
4421if test "${ac_cv_lib_curses_tgetent+set}" = set; then
4422  echo $ECHO_N "(cached) $ECHO_C" >&6
4423else
4424  ac_check_lib_save_LIBS=$LIBS
4425LIBS="-lcurses  $LIBS"
4426cat >conftest.$ac_ext <<_ACEOF
4427#line 4427 "configure"
4428#include "confdefs.h"
4429
4430/* Override any gcc2 internal prototype to avoid an error.  */
4431#ifdef __cplusplus
4432extern "C"
4433#endif
4434/* We use char because int might match the return type of a gcc2
4435   builtin and then its argument prototype would still apply.  */
4436char tgetent ();
4437int
4438main ()
4439{
4440tgetent ();
4441  ;
4442  return 0;
4443}
4444_ACEOF
4445rm -f conftest.$ac_objext conftest$ac_exeext
4446if { (eval echo "$as_me:4446: \"$ac_link\"") >&5
4447  (eval $ac_link) 2>&5
4448  ac_status=$?
4449  echo "$as_me:4449: \$? = $ac_status" >&5
4450  (exit $ac_status); } &&
4451         { ac_try='test -s conftest$ac_exeext'
4452  { (eval echo "$as_me:4452: \"$ac_try\"") >&5
4453  (eval $ac_try) 2>&5
4454  ac_status=$?
4455  echo "$as_me:4455: \$? = $ac_status" >&5
4456  (exit $ac_status); }; }; then
4457  ac_cv_lib_curses_tgetent=yes
4458else
4459  echo "$as_me: failed program was:" >&5
4460cat conftest.$ac_ext >&5
4461ac_cv_lib_curses_tgetent=no
4462fi
4463rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4464LIBS=$ac_check_lib_save_LIBS
4465fi
4466echo "$as_me:4466: result: $ac_cv_lib_curses_tgetent" >&5
4467echo "${ECHO_T}$ac_cv_lib_curses_tgetent" >&6
4468if test $ac_cv_lib_curses_tgetent = yes; then
4469  bash_cv_termcap_lib=libcurses
4470else
4471  echo "$as_me:4471: checking for tgetent in -lncurses" >&5
4472echo $ECHO_N "checking for tgetent in -lncurses... $ECHO_C" >&6
4473if test "${ac_cv_lib_ncurses_tgetent+set}" = set; then
4474  echo $ECHO_N "(cached) $ECHO_C" >&6
4475else
4476  ac_check_lib_save_LIBS=$LIBS
4477LIBS="-lncurses  $LIBS"
4478cat >conftest.$ac_ext <<_ACEOF
4479#line 4479 "configure"
4480#include "confdefs.h"
4481
4482/* Override any gcc2 internal prototype to avoid an error.  */
4483#ifdef __cplusplus
4484extern "C"
4485#endif
4486/* We use char because int might match the return type of a gcc2
4487   builtin and then its argument prototype would still apply.  */
4488char tgetent ();
4489int
4490main ()
4491{
4492tgetent ();
4493  ;
4494  return 0;
4495}
4496_ACEOF
4497rm -f conftest.$ac_objext conftest$ac_exeext
4498if { (eval echo "$as_me:4498: \"$ac_link\"") >&5
4499  (eval $ac_link) 2>&5
4500  ac_status=$?
4501  echo "$as_me:4501: \$? = $ac_status" >&5
4502  (exit $ac_status); } &&
4503         { ac_try='test -s conftest$ac_exeext'
4504  { (eval echo "$as_me:4504: \"$ac_try\"") >&5
4505  (eval $ac_try) 2>&5
4506  ac_status=$?
4507  echo "$as_me:4507: \$? = $ac_status" >&5
4508  (exit $ac_status); }; }; then
4509  ac_cv_lib_ncurses_tgetent=yes
4510else
4511  echo "$as_me: failed program was:" >&5
4512cat conftest.$ac_ext >&5
4513ac_cv_lib_ncurses_tgetent=no
4514fi
4515rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4516LIBS=$ac_check_lib_save_LIBS
4517fi
4518echo "$as_me:4518: result: $ac_cv_lib_ncurses_tgetent" >&5
4519echo "${ECHO_T}$ac_cv_lib_ncurses_tgetent" >&6
4520if test $ac_cv_lib_ncurses_tgetent = yes; then
4521  bash_cv_termcap_lib=libncurses
4522else
4523  bash_cv_termcap_lib=gnutermcap
4524fi
4525
4526fi
4527
4528fi
4529
4530fi
4531
4532fi
4533
4534if test "X$_bash_needmsg" = "Xyes"; then
4535echo "$as_me:4535: checking which library has the termcap functions" >&5
4536echo $ECHO_N "checking which library has the termcap functions... $ECHO_C" >&6
4537fi
4538echo "$as_me:4538: result: using $bash_cv_termcap_lib" >&5
4539echo "${ECHO_T}using $bash_cv_termcap_lib" >&6
4540if test $bash_cv_termcap_lib = gnutermcap && test -z "$prefer_curses"; then
4541LDFLAGS="$LDFLAGS -L./lib/termcap"
4542TERMCAP_LIB="./lib/termcap/libtermcap.a"
4543TERMCAP_DEP="./lib/termcap/libtermcap.a"
4544elif test $bash_cv_termcap_lib = libtermcap && test -z "$prefer_curses"; then
4545TERMCAP_LIB=-ltermcap
4546TERMCAP_DEP=
4547elif test $bash_cv_termcap_lib = libtinfo; then
4548TERMCAP_LIB=-ltinfo
4549TERMCAP_DEP=
4550elif test $bash_cv_termcap_lib = libncurses; then
4551TERMCAP_LIB=-lncurses
4552TERMCAP_DEP=
4553else
4554TERMCAP_LIB=-lcurses
4555TERMCAP_DEP=
4556fi
4557
4558if test "$TERMCAP_LIB" = "./lib/termcap/libtermcap.a"; then
4559	if test "$prefer_curses" = yes; then
4560		TERMCAP_LIB=-lcurses
4561	else
4562		TERMCAP_LIB=-ltermcap	#default
4563	fi
4564fi
4565
4566for ac_header in wctype.h
4567do
4568as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
4569echo "$as_me:4569: checking for $ac_header" >&5
4570echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4571if eval "test \"\${$as_ac_Header+set}\" = set"; then
4572  echo $ECHO_N "(cached) $ECHO_C" >&6
4573else
4574  cat >conftest.$ac_ext <<_ACEOF
4575#line 4575 "configure"
4576#include "confdefs.h"
4577#include <$ac_header>
4578_ACEOF
4579if { (eval echo "$as_me:4579: \"$ac_cpp conftest.$ac_ext\"") >&5
4580  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4581  ac_status=$?
4582  egrep -v '^ *\+' conftest.er1 >conftest.err
4583  rm -f conftest.er1
4584  cat conftest.err >&5
4585  echo "$as_me:4585: \$? = $ac_status" >&5
4586  (exit $ac_status); } >/dev/null; then
4587  if test -s conftest.err; then
4588    ac_cpp_err=$ac_c_preproc_warn_flag
4589  else
4590    ac_cpp_err=
4591  fi
4592else
4593  ac_cpp_err=yes
4594fi
4595if test -z "$ac_cpp_err"; then
4596  eval "$as_ac_Header=yes"
4597else
4598  echo "$as_me: failed program was:" >&5
4599  cat conftest.$ac_ext >&5
4600  eval "$as_ac_Header=no"
4601fi
4602rm -f conftest.err conftest.$ac_ext
4603fi
4604echo "$as_me:4604: result: `eval echo '${'$as_ac_Header'}'`" >&5
4605echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4606if test `eval echo '${'$as_ac_Header'}'` = yes; then
4607  cat >>confdefs.h <<EOF
4608#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
4609EOF
4610
4611fi
4612done
4613
4614for ac_header in wchar.h
4615do
4616as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
4617echo "$as_me:4617: checking for $ac_header" >&5
4618echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4619if eval "test \"\${$as_ac_Header+set}\" = set"; then
4620  echo $ECHO_N "(cached) $ECHO_C" >&6
4621else
4622  cat >conftest.$ac_ext <<_ACEOF
4623#line 4623 "configure"
4624#include "confdefs.h"
4625#include <$ac_header>
4626_ACEOF
4627if { (eval echo "$as_me:4627: \"$ac_cpp conftest.$ac_ext\"") >&5
4628  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4629  ac_status=$?
4630  egrep -v '^ *\+' conftest.er1 >conftest.err
4631  rm -f conftest.er1
4632  cat conftest.err >&5
4633  echo "$as_me:4633: \$? = $ac_status" >&5
4634  (exit $ac_status); } >/dev/null; then
4635  if test -s conftest.err; then
4636    ac_cpp_err=$ac_c_preproc_warn_flag
4637  else
4638    ac_cpp_err=
4639  fi
4640else
4641  ac_cpp_err=yes
4642fi
4643if test -z "$ac_cpp_err"; then
4644  eval "$as_ac_Header=yes"
4645else
4646  echo "$as_me: failed program was:" >&5
4647  cat conftest.$ac_ext >&5
4648  eval "$as_ac_Header=no"
4649fi
4650rm -f conftest.err conftest.$ac_ext
4651fi
4652echo "$as_me:4652: result: `eval echo '${'$as_ac_Header'}'`" >&5
4653echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4654if test `eval echo '${'$as_ac_Header'}'` = yes; then
4655  cat >>confdefs.h <<EOF
4656#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
4657EOF
4658
4659fi
4660done
4661
4662for ac_header in langinfo.h
4663do
4664as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
4665echo "$as_me:4665: checking for $ac_header" >&5
4666echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4667if eval "test \"\${$as_ac_Header+set}\" = set"; then
4668  echo $ECHO_N "(cached) $ECHO_C" >&6
4669else
4670  cat >conftest.$ac_ext <<_ACEOF
4671#line 4671 "configure"
4672#include "confdefs.h"
4673#include <$ac_header>
4674_ACEOF
4675if { (eval echo "$as_me:4675: \"$ac_cpp conftest.$ac_ext\"") >&5
4676  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4677  ac_status=$?
4678  egrep -v '^ *\+' conftest.er1 >conftest.err
4679  rm -f conftest.er1
4680  cat conftest.err >&5
4681  echo "$as_me:4681: \$? = $ac_status" >&5
4682  (exit $ac_status); } >/dev/null; then
4683  if test -s conftest.err; then
4684    ac_cpp_err=$ac_c_preproc_warn_flag
4685  else
4686    ac_cpp_err=
4687  fi
4688else
4689  ac_cpp_err=yes
4690fi
4691if test -z "$ac_cpp_err"; then
4692  eval "$as_ac_Header=yes"
4693else
4694  echo "$as_me: failed program was:" >&5
4695  cat conftest.$ac_ext >&5
4696  eval "$as_ac_Header=no"
4697fi
4698rm -f conftest.err conftest.$ac_ext
4699fi
4700echo "$as_me:4700: result: `eval echo '${'$as_ac_Header'}'`" >&5
4701echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4702if test `eval echo '${'$as_ac_Header'}'` = yes; then
4703  cat >>confdefs.h <<EOF
4704#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
4705EOF
4706
4707fi
4708done
4709
4710echo "$as_me:4710: checking for mbsrtowcs" >&5
4711echo $ECHO_N "checking for mbsrtowcs... $ECHO_C" >&6
4712if test "${ac_cv_func_mbsrtowcs+set}" = set; then
4713  echo $ECHO_N "(cached) $ECHO_C" >&6
4714else
4715  cat >conftest.$ac_ext <<_ACEOF
4716#line 4716 "configure"
4717#include "confdefs.h"
4718/* System header to define __stub macros and hopefully few prototypes,
4719    which can conflict with char mbsrtowcs (); below.  */
4720#include <assert.h>
4721/* Override any gcc2 internal prototype to avoid an error.  */
4722#ifdef __cplusplus
4723extern "C"
4724#endif
4725/* We use char because int might match the return type of a gcc2
4726   builtin and then its argument prototype would still apply.  */
4727char mbsrtowcs ();
4728char (*f) ();
4729
4730int
4731main ()
4732{
4733/* The GNU C library defines this for functions which it implements
4734    to always fail with ENOSYS.  Some functions are actually named
4735    something starting with __ and the normal name is an alias.  */
4736#if defined (__stub_mbsrtowcs) || defined (__stub___mbsrtowcs)
4737choke me
4738#else
4739f = mbsrtowcs;
4740#endif
4741
4742  ;
4743  return 0;
4744}
4745_ACEOF
4746rm -f conftest.$ac_objext conftest$ac_exeext
4747if { (eval echo "$as_me:4747: \"$ac_link\"") >&5
4748  (eval $ac_link) 2>&5
4749  ac_status=$?
4750  echo "$as_me:4750: \$? = $ac_status" >&5
4751  (exit $ac_status); } &&
4752         { ac_try='test -s conftest$ac_exeext'
4753  { (eval echo "$as_me:4753: \"$ac_try\"") >&5
4754  (eval $ac_try) 2>&5
4755  ac_status=$?
4756  echo "$as_me:4756: \$? = $ac_status" >&5
4757  (exit $ac_status); }; }; then
4758  ac_cv_func_mbsrtowcs=yes
4759else
4760  echo "$as_me: failed program was:" >&5
4761cat conftest.$ac_ext >&5
4762ac_cv_func_mbsrtowcs=no
4763fi
4764rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4765fi
4766echo "$as_me:4766: result: $ac_cv_func_mbsrtowcs" >&5
4767echo "${ECHO_T}$ac_cv_func_mbsrtowcs" >&6
4768if test $ac_cv_func_mbsrtowcs = yes; then
4769  cat >>confdefs.h <<\EOF
4770#define HAVE_MBSRTOWCS 1
4771EOF
4772
4773fi
4774
4775echo "$as_me:4775: checking for wcwidth" >&5
4776echo $ECHO_N "checking for wcwidth... $ECHO_C" >&6
4777if test "${ac_cv_func_wcwidth+set}" = set; then
4778  echo $ECHO_N "(cached) $ECHO_C" >&6
4779else
4780  cat >conftest.$ac_ext <<_ACEOF
4781#line 4781 "configure"
4782#include "confdefs.h"
4783/* System header to define __stub macros and hopefully few prototypes,
4784    which can conflict with char wcwidth (); below.  */
4785#include <assert.h>
4786/* Override any gcc2 internal prototype to avoid an error.  */
4787#ifdef __cplusplus
4788extern "C"
4789#endif
4790/* We use char because int might match the return type of a gcc2
4791   builtin and then its argument prototype would still apply.  */
4792char wcwidth ();
4793char (*f) ();
4794
4795int
4796main ()
4797{
4798/* The GNU C library defines this for functions which it implements
4799    to always fail with ENOSYS.  Some functions are actually named
4800    something starting with __ and the normal name is an alias.  */
4801#if defined (__stub_wcwidth) || defined (__stub___wcwidth)
4802choke me
4803#else
4804f = wcwidth;
4805#endif
4806
4807  ;
4808  return 0;
4809}
4810_ACEOF
4811rm -f conftest.$ac_objext conftest$ac_exeext
4812if { (eval echo "$as_me:4812: \"$ac_link\"") >&5
4813  (eval $ac_link) 2>&5
4814  ac_status=$?
4815  echo "$as_me:4815: \$? = $ac_status" >&5
4816  (exit $ac_status); } &&
4817         { ac_try='test -s conftest$ac_exeext'
4818  { (eval echo "$as_me:4818: \"$ac_try\"") >&5
4819  (eval $ac_try) 2>&5
4820  ac_status=$?
4821  echo "$as_me:4821: \$? = $ac_status" >&5
4822  (exit $ac_status); }; }; then
4823  ac_cv_func_wcwidth=yes
4824else
4825  echo "$as_me: failed program was:" >&5
4826cat conftest.$ac_ext >&5
4827ac_cv_func_wcwidth=no
4828fi
4829rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4830fi
4831echo "$as_me:4831: result: $ac_cv_func_wcwidth" >&5
4832echo "${ECHO_T}$ac_cv_func_wcwidth" >&6
4833if test $ac_cv_func_wcwidth = yes; then
4834  cat >>confdefs.h <<\EOF
4835#define HAVE_WCWIDTH 1
4836EOF
4837
4838fi
4839
4840echo "$as_me:4840: checking for mbstate_t" >&5
4841echo $ECHO_N "checking for mbstate_t... $ECHO_C" >&6
4842if test "${bash_cv_have_mbstate_t+set}" = set; then
4843  echo $ECHO_N "(cached) $ECHO_C" >&6
4844else
4845  if test "$cross_compiling" = yes; then
4846  { { echo "$as_me:4846: error: cannot run test program while cross compiling" >&5
4847echo "$as_me: error: cannot run test program while cross compiling" >&2;}
4848   { (exit 1); exit 1; }; }
4849else
4850  cat >conftest.$ac_ext <<_ACEOF
4851#line 4851 "configure"
4852#include "confdefs.h"
4853
4854#include <wchar.h>
4855int
4856main ()
4857{
4858  mbstate_t ps;
4859  return 0;
4860}
4861_ACEOF
4862rm -f conftest$ac_exeext
4863if { (eval echo "$as_me:4863: \"$ac_link\"") >&5
4864  (eval $ac_link) 2>&5
4865  ac_status=$?
4866  echo "$as_me:4866: \$? = $ac_status" >&5
4867  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4868  { (eval echo "$as_me:4868: \"$ac_try\"") >&5
4869  (eval $ac_try) 2>&5
4870  ac_status=$?
4871  echo "$as_me:4871: \$? = $ac_status" >&5
4872  (exit $ac_status); }; }; then
4873  bash_cv_have_mbstate_t=yes
4874else
4875  echo "$as_me: program exited with status $ac_status" >&5
4876echo "$as_me: failed program was:" >&5
4877cat conftest.$ac_ext >&5
4878bash_cv_have_mbstate_t=no
4879fi
4880rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
4881fi
4882fi
4883echo "$as_me:4883: result: $bash_cv_have_mbstate_t" >&5
4884echo "${ECHO_T}$bash_cv_have_mbstate_t" >&6
4885if test $bash_cv_have_mbstate_t = yes; then
4886	cat >>confdefs.h <<\EOF
4887#define HAVE_MBSTATE_T 1
4888EOF
4889
4890fi
4891
4892echo "$as_me:4892: checking for nl_langinfo and CODESET" >&5
4893echo $ECHO_N "checking for nl_langinfo and CODESET... $ECHO_C" >&6
4894if test "${bash_cv_langinfo_codeset+set}" = set; then
4895  echo $ECHO_N "(cached) $ECHO_C" >&6
4896else
4897  cat >conftest.$ac_ext <<_ACEOF
4898#line 4898 "configure"
4899#include "confdefs.h"
4900#include <langinfo.h>
4901int
4902main ()
4903{
4904char* cs = nl_langinfo(CODESET);
4905  ;
4906  return 0;
4907}
4908_ACEOF
4909rm -f conftest.$ac_objext conftest$ac_exeext
4910if { (eval echo "$as_me:4910: \"$ac_link\"") >&5
4911  (eval $ac_link) 2>&5
4912  ac_status=$?
4913  echo "$as_me:4913: \$? = $ac_status" >&5
4914  (exit $ac_status); } &&
4915         { ac_try='test -s conftest$ac_exeext'
4916  { (eval echo "$as_me:4916: \"$ac_try\"") >&5
4917  (eval $ac_try) 2>&5
4918  ac_status=$?
4919  echo "$as_me:4919: \$? = $ac_status" >&5
4920  (exit $ac_status); }; }; then
4921  bash_cv_langinfo_codeset=yes
4922else
4923  echo "$as_me: failed program was:" >&5
4924cat conftest.$ac_ext >&5
4925bash_cv_langinfo_codeset=no
4926fi
4927rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4928fi
4929echo "$as_me:4929: result: $bash_cv_langinfo_codeset" >&5
4930echo "${ECHO_T}$bash_cv_langinfo_codeset" >&6
4931if test $bash_cv_langinfo_codeset = yes; then
4932  cat >>confdefs.h <<\EOF
4933#define HAVE_LANGINFO_CODESET 1
4934EOF
4935
4936fi
4937
4938case "$host_cpu" in
4939*cray*)	LOCAL_CFLAGS=-DCRAY ;;
4940*s390*) LOCAL_CFLAGS=-fsigned-char ;;
4941esac
4942
4943case "$host_os" in
4944isc*)	LOCAL_CFLAGS=-Disc386 ;;
4945esac
4946
4947# shared library configuration section
4948#
4949# Shared object configuration section.  These values are generated by
4950# ${srcdir}/support/shobj-conf
4951#
4952if test -f ${srcdir}/support/shobj-conf; then
4953        echo "$as_me:4953: checking configuration for building shared libraries" >&5
4954echo $ECHO_N "checking configuration for building shared libraries... $ECHO_C" >&6
4955        eval `${CONFIG_SHELL-/bin/sh} ${srcdir}/support/shobj-conf -C "${CC}" -c ${host_cpu} -o ${host_os} -v ${host_vendor}`
4956
4957        echo "$as_me:4957: result: $SHLIB_STATUS" >&5
4958echo "${ECHO_T}$SHLIB_STATUS" >&6
4959
4960	# SHLIB_STATUS is either `supported' or `unsupported'.  If it's
4961	# `unsupported', turn off any default shared library building
4962	if test "$SHLIB_STATUS" = 'unsupported'; then
4963		opt_shared_libs=no
4964	fi
4965
4966	# shared library versioning
4967	# quoted for m4 so I can use character classes
4968	SHLIB_MAJOR=`expr "$LIBVERSION" : '\([0-9]\)\..*'`
4969	SHLIB_MINOR=`expr "$LIBVERSION" : '[0-9]\.\([0-9]\).*'`
4970
4971fi
4972
4973if test "$opt_static_libs" = "yes"; then
4974	STATIC_TARGET=static
4975	STATIC_INSTALL_TARGET=install-static
4976fi
4977if test "$opt_shared_libs" = "yes"; then
4978	SHARED_TARGET=shared
4979	SHARED_INSTALL_TARGET=install-shared
4980fi
4981
4982case "$host_os" in
4983msdosdjgpp*)	BUILD_DIR=`pwd.exe` ;;	# to prevent //d/path/file
4984*)		BUILD_DIR=`pwd` ;;
4985esac
4986
4987ac_config_files="$ac_config_files Makefile doc/Makefile examples/Makefile shlib/Makefile"
4988ac_config_commands="$ac_config_commands default"
4989cat >confcache <<\_ACEOF
4990# This file is a shell script that caches the results of configure
4991# tests run on this system so they can be shared between configure
4992# scripts and configure runs, see configure's option --config-cache.
4993# It is not useful on other systems.  If it contains results you don't
4994# want to keep, you may remove or edit it.
4995#
4996# config.status only pays attention to the cache file if you give it
4997# the --recheck option to rerun configure.
4998#
4999# `ac_cv_env_foo' variables (set or unset) will be overriden when
5000# loading this file, other *unset* `ac_cv_foo' will be assigned the
5001# following values.
5002
5003_ACEOF
5004
5005# The following way of writing the cache mishandles newlines in values,
5006# but we know of no workaround that is simple, portable, and efficient.
5007# So, don't put newlines in cache variables' values.
5008# Ultrix sh set writes to stderr and can't be redirected directly,
5009# and sets the high bit in the cache file unless we assign to the vars.
5010{
5011  (set) 2>&1 |
5012    case `(ac_space=' '; set | grep ac_space) 2>&1` in
5013    *ac_space=\ *)
5014      # `set' does not quote correctly, so add quotes (double-quote
5015      # substitution turns \\\\ into \\, and sed turns \\ into \).
5016      sed -n \
5017        "s/'/'\\\\''/g;
5018    	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
5019      ;;
5020    *)
5021      # `set' quotes correctly as required by POSIX, so do not add quotes.
5022      sed -n \
5023        "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
5024      ;;
5025    esac;
5026} |
5027  sed '
5028     t clear
5029     : clear
5030     s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
5031     t end
5032     /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
5033     : end' >>confcache
5034if cmp -s $cache_file confcache; then :; else
5035  if test -w $cache_file; then
5036    test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
5037    cat confcache >$cache_file
5038  else
5039    echo "not updating unwritable cache $cache_file"
5040  fi
5041fi
5042rm -f confcache
5043
5044test "x$prefix" = xNONE && prefix=$ac_default_prefix
5045# Let make expand exec_prefix.
5046test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
5047
5048# VPATH may cause trouble with some makes, so we remove $(srcdir),
5049# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
5050# trailing colons and then remove the whole line if VPATH becomes empty
5051# (actually we leave an empty line to preserve line numbers).
5052if test "x$srcdir" = x.; then
5053  ac_vpsub='/^[ 	]*VPATH[ 	]*=/{
5054s/:*\$(srcdir):*/:/;
5055s/:*\${srcdir}:*/:/;
5056s/:*@srcdir@:*/:/;
5057s/^\([^=]*=[ 	]*\):*/\1/;
5058s/:*$//;
5059s/^[^=]*=[ 	]*$//;
5060}'
5061fi
5062
5063DEFS=-DHAVE_CONFIG_H
5064
5065: ${CONFIG_STATUS=./config.status}
5066ac_clean_files_save=$ac_clean_files
5067ac_clean_files="$ac_clean_files $CONFIG_STATUS"
5068{ echo "$as_me:5068: creating $CONFIG_STATUS" >&5
5069echo "$as_me: creating $CONFIG_STATUS" >&6;}
5070cat >$CONFIG_STATUS <<_ACEOF
5071#! $SHELL
5072# Generated automatically by configure.
5073# Run this file to recreate the current configuration.
5074# Compiler output produced by configure, useful for debugging
5075# configure, is in config.log if it exists.
5076
5077debug=false
5078SHELL=\${CONFIG_SHELL-$SHELL}
5079ac_cs_invocation="\$0 \$@"
5080
5081_ACEOF
5082
5083cat >>$CONFIG_STATUS <<\_ACEOF
5084# Be Bourne compatible
5085if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
5086  emulate sh
5087  NULLCMD=:
5088elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
5089  set -o posix
5090fi
5091
5092# Name of the executable.
5093as_me=`echo "$0" |sed 's,.*[\\/],,'`
5094
5095if expr a : '\(a\)' >/dev/null 2>&1; then
5096  as_expr=expr
5097else
5098  as_expr=false
5099fi
5100
5101rm -f conf$$ conf$$.exe conf$$.file
5102echo >conf$$.file
5103if ln -s conf$$.file conf$$ 2>/dev/null; then
5104  # We could just check for DJGPP; but this test a) works b) is more generic
5105  # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
5106  if test -f conf$$.exe; then
5107    # Don't use ln at all; we don't have any links
5108    as_ln_s='cp -p'
5109  else
5110    as_ln_s='ln -s'
5111  fi
5112elif ln conf$$.file conf$$ 2>/dev/null; then
5113  as_ln_s=ln
5114else
5115  as_ln_s='cp -p'
5116fi
5117rm -f conf$$ conf$$.exe conf$$.file
5118
5119as_executable_p="test -f"
5120
5121# Support unset when possible.
5122if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
5123  as_unset=unset
5124else
5125  as_unset=false
5126fi
5127
5128# NLS nuisances.
5129$as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
5130$as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
5131$as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
5132$as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
5133$as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
5134$as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
5135$as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
5136$as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
5137
5138# IFS
5139# We need space, tab and new line, in precisely that order.
5140as_nl='
5141'
5142IFS=" 	$as_nl"
5143
5144# CDPATH.
5145$as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
5146
5147exec 6>&1
5148
5149_ACEOF
5150
5151# Files that config.status was made for.
5152if test -n "$ac_config_files"; then
5153  echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
5154fi
5155
5156if test -n "$ac_config_headers"; then
5157  echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
5158fi
5159
5160if test -n "$ac_config_links"; then
5161  echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
5162fi
5163
5164if test -n "$ac_config_commands"; then
5165  echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
5166fi
5167
5168cat >>$CONFIG_STATUS <<\EOF
5169
5170ac_cs_usage="\
5171\`$as_me' instantiates files from templates according to the
5172current configuration.
5173
5174Usage: $0 [OPTIONS] [FILE]...
5175
5176  -h, --help       print this help, then exit
5177  -V, --version    print version number, then exit
5178  -d, --debug      don't remove temporary files
5179      --recheck    update $as_me by reconfiguring in the same conditions
5180  --file=FILE[:TEMPLATE]
5181                   instantiate the configuration file FILE
5182  --header=FILE[:TEMPLATE]
5183                   instantiate the configuration header FILE
5184
5185Configuration files:
5186$config_files
5187
5188Configuration headers:
5189$config_headers
5190
5191Configuration commands:
5192$config_commands
5193
5194Report bugs to <bug-autoconf@gnu.org>."
5195EOF
5196
5197cat >>$CONFIG_STATUS <<EOF
5198ac_cs_version="\\
5199readline config.status 4.3
5200configured by $0, generated by GNU Autoconf 2.52,
5201  with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
5202
5203Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
5204Free Software Foundation, Inc.
5205This config.status script is free software; the Free Software Foundation
5206gives unlimited permission to copy, distribute and modify it."
5207srcdir=$srcdir
5208INSTALL="$INSTALL"
5209EOF
5210
5211cat >>$CONFIG_STATUS <<\EOF
5212# If no file are specified by the user, then we need to provide default
5213# value.  By we need to know if files were specified by the user.
5214ac_need_defaults=:
5215while test $# != 0
5216do
5217  case $1 in
5218  --*=*)
5219    ac_option=`expr "x$1" : 'x\([^=]*\)='`
5220    ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
5221    shift
5222    set dummy "$ac_option" "$ac_optarg" ${1+"$@"}
5223    shift
5224    ;;
5225  -*);;
5226  *) # This is not an option, so the user has probably given explicit
5227     # arguments.
5228     ac_need_defaults=false;;
5229  esac
5230
5231  case $1 in
5232  # Handling of the options.
5233EOF
5234cat >>$CONFIG_STATUS <<EOF
5235  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
5236    echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion"
5237    exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;;
5238EOF
5239cat >>$CONFIG_STATUS <<\EOF
5240  --version | --vers* | -V )
5241    echo "$ac_cs_version"; exit 0 ;;
5242  --he | --h)
5243    # Conflict between --help and --header
5244    { { echo "$as_me:5244: error: ambiguous option: $1
5245Try \`$0 --help' for more information." >&5
5246echo "$as_me: error: ambiguous option: $1
5247Try \`$0 --help' for more information." >&2;}
5248   { (exit 1); exit 1; }; };;
5249  --help | --hel | -h )
5250    echo "$ac_cs_usage"; exit 0 ;;
5251  --debug | --d* | -d )
5252    debug=: ;;
5253  --file | --fil | --fi | --f )
5254    shift
5255    CONFIG_FILES="$CONFIG_FILES $1"
5256    ac_need_defaults=false;;
5257  --header | --heade | --head | --hea )
5258    shift
5259    CONFIG_HEADERS="$CONFIG_HEADERS $1"
5260    ac_need_defaults=false;;
5261
5262  # This is an error.
5263  -*) { { echo "$as_me:5263: error: unrecognized option: $1
5264Try \`$0 --help' for more information." >&5
5265echo "$as_me: error: unrecognized option: $1
5266Try \`$0 --help' for more information." >&2;}
5267   { (exit 1); exit 1; }; } ;;
5268
5269  *) ac_config_targets="$ac_config_targets $1" ;;
5270
5271  esac
5272  shift
5273done
5274
5275exec 5>>config.log
5276cat >&5 << _ACEOF
5277
5278## ----------------------- ##
5279## Running config.status.  ##
5280## ----------------------- ##
5281
5282This file was extended by $as_me (readline 4.3) 2.52, executed with
5283  CONFIG_FILES    = $CONFIG_FILES
5284  CONFIG_HEADERS  = $CONFIG_HEADERS
5285  CONFIG_LINKS    = $CONFIG_LINKS
5286  CONFIG_COMMANDS = $CONFIG_COMMANDS
5287  > $ac_cs_invocation
5288on `(hostname || uname -n) 2>/dev/null | sed 1q`
5289
5290_ACEOF
5291EOF
5292
5293cat >>$CONFIG_STATUS <<\EOF
5294for ac_config_target in $ac_config_targets
5295do
5296  case "$ac_config_target" in
5297  # Handling of arguments.
5298  "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
5299  "doc/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/Makefile" ;;
5300  "examples/Makefile" ) CONFIG_FILES="$CONFIG_FILES examples/Makefile" ;;
5301  "shlib/Makefile" ) CONFIG_FILES="$CONFIG_FILES shlib/Makefile" ;;
5302  "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
5303  "config.h" ) CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;;
5304  *) { { echo "$as_me:5304: error: invalid argument: $ac_config_target" >&5
5305echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
5306   { (exit 1); exit 1; }; };;
5307  esac
5308done
5309
5310# If the user did not use the arguments to specify the items to instantiate,
5311# then the envvar interface is used.  Set only those that are not.
5312# We use the long form for the default assignment because of an extremely
5313# bizarre bug on SunOS 4.1.3.
5314if $ac_need_defaults; then
5315  test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
5316  test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
5317  test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
5318fi
5319
5320# Create a temporary directory, and hook for its removal unless debugging.
5321$debug ||
5322{
5323  trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
5324  trap '{ (exit 1); exit 1; }' 1 2 13 15
5325}
5326
5327# Create a (secure) tmp directory for tmp files.
5328: ${TMPDIR=/tmp}
5329{
5330  tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` &&
5331  test -n "$tmp" && test -d "$tmp"
5332}  ||
5333{
5334  tmp=$TMPDIR/cs$$-$RANDOM
5335  (umask 077 && mkdir $tmp)
5336} ||
5337{
5338   echo "$me: cannot create a temporary directory in $TMPDIR" >&2
5339   { (exit 1); exit 1; }
5340}
5341
5342EOF
5343
5344cat >>$CONFIG_STATUS <<EOF
5345
5346#
5347# CONFIG_FILES section.
5348#
5349
5350# No need to generate the scripts if there are no CONFIG_FILES.
5351# This happens for instance when ./config.status config.h
5352if test -n "\$CONFIG_FILES"; then
5353  # Protect against being on the right side of a sed subst in config.status.
5354  sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
5355   s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
5356s,@SHELL@,$SHELL,;t t
5357s,@exec_prefix@,$exec_prefix,;t t
5358s,@prefix@,$prefix,;t t
5359s,@program_transform_name@,$program_transform_name,;t t
5360s,@bindir@,$bindir,;t t
5361s,@sbindir@,$sbindir,;t t
5362s,@libexecdir@,$libexecdir,;t t
5363s,@datadir@,$datadir,;t t
5364s,@sysconfdir@,$sysconfdir,;t t
5365s,@sharedstatedir@,$sharedstatedir,;t t
5366s,@localstatedir@,$localstatedir,;t t
5367s,@libdir@,$libdir,;t t
5368s,@includedir@,$includedir,;t t
5369s,@oldincludedir@,$oldincludedir,;t t
5370s,@infodir@,$infodir,;t t
5371s,@mandir@,$mandir,;t t
5372s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
5373s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
5374s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
5375s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
5376s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
5377s,@build_alias@,$build_alias,;t t
5378s,@host_alias@,$host_alias,;t t
5379s,@target_alias@,$target_alias,;t t
5380s,@ECHO_C@,$ECHO_C,;t t
5381s,@ECHO_N@,$ECHO_N,;t t
5382s,@ECHO_T@,$ECHO_T,;t t
5383s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
5384s,@DEFS@,$DEFS,;t t
5385s,@LIBS@,$LIBS,;t t
5386s,@build@,$build,;t t
5387s,@build_cpu@,$build_cpu,;t t
5388s,@build_vendor@,$build_vendor,;t t
5389s,@build_os@,$build_os,;t t
5390s,@host@,$host,;t t
5391s,@host_cpu@,$host_cpu,;t t
5392s,@host_vendor@,$host_vendor,;t t
5393s,@host_os@,$host_os,;t t
5394s,@SET_MAKE@,$SET_MAKE,;t t
5395s,@CC@,$CC,;t t
5396s,@CFLAGS@,$CFLAGS,;t t
5397s,@LDFLAGS@,$LDFLAGS,;t t
5398s,@CPPFLAGS@,$CPPFLAGS,;t t
5399s,@ac_ct_CC@,$ac_ct_CC,;t t
5400s,@EXEEXT@,$EXEEXT,;t t
5401s,@OBJEXT@,$OBJEXT,;t t
5402s,@CPP@,$CPP,;t t
5403s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
5404s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
5405s,@INSTALL_DATA@,$INSTALL_DATA,;t t
5406s,@AR@,$AR,;t t
5407s,@RANLIB@,$RANLIB,;t t
5408s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
5409s,@MAKE_SHELL@,$MAKE_SHELL,;t t
5410s,@SHOBJ_CC@,$SHOBJ_CC,;t t
5411s,@SHOBJ_CFLAGS@,$SHOBJ_CFLAGS,;t t
5412s,@SHOBJ_LD@,$SHOBJ_LD,;t t
5413s,@SHOBJ_LDFLAGS@,$SHOBJ_LDFLAGS,;t t
5414s,@SHOBJ_XLDFLAGS@,$SHOBJ_XLDFLAGS,;t t
5415s,@SHOBJ_LIBS@,$SHOBJ_LIBS,;t t
5416s,@SHOBJ_STATUS@,$SHOBJ_STATUS,;t t
5417s,@SHLIB_STATUS@,$SHLIB_STATUS,;t t
5418s,@SHLIB_XLDFLAGS@,$SHLIB_XLDFLAGS,;t t
5419s,@SHLIB_LIBSUFF@,$SHLIB_LIBSUFF,;t t
5420s,@SHLIB_LIBVERSION@,$SHLIB_LIBVERSION,;t t
5421s,@SHLIB_LIBS@,$SHLIB_LIBS,;t t
5422s,@SHLIB_MAJOR@,$SHLIB_MAJOR,;t t
5423s,@SHLIB_MINOR@,$SHLIB_MINOR,;t t
5424s,@STATIC_TARGET@,$STATIC_TARGET,;t t
5425s,@SHARED_TARGET@,$SHARED_TARGET,;t t
5426s,@STATIC_INSTALL_TARGET@,$STATIC_INSTALL_TARGET,;t t
5427s,@SHARED_INSTALL_TARGET@,$SHARED_INSTALL_TARGET,;t t
5428s,@BUILD_DIR@,$BUILD_DIR,;t t
5429s,@LOCAL_CFLAGS@,$LOCAL_CFLAGS,;t t
5430s,@LOCAL_LDFLAGS@,$LOCAL_LDFLAGS,;t t
5431s,@LOCAL_DEFS@,$LOCAL_DEFS,;t t
5432s,@ARFLAGS@,$ARFLAGS,;t t
5433s,@LIBVERSION@,$LIBVERSION,;t t
5434s,@TERMCAP_LIB@,$TERMCAP_LIB,;t t
5435CEOF
5436
5437EOF
5438
5439  cat >>$CONFIG_STATUS <<\EOF
5440  # Split the substitutions into bite-sized pieces for seds with
5441  # small command number limits, like on Digital OSF/1 and HP-UX.
5442  ac_max_sed_lines=48
5443  ac_sed_frag=1 # Number of current file.
5444  ac_beg=1 # First line for current file.
5445  ac_end=$ac_max_sed_lines # Line after last line for current file.
5446  ac_more_lines=:
5447  ac_sed_cmds=
5448  while $ac_more_lines; do
5449    if test $ac_beg -gt 1; then
5450      sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
5451    else
5452      sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
5453    fi
5454    if test ! -s $tmp/subs.frag; then
5455      ac_more_lines=false
5456    else
5457      # The purpose of the label and of the branching condition is to
5458      # speed up the sed processing (if there are no `@' at all, there
5459      # is no need to browse any of the substitutions).
5460      # These are the two extra sed commands mentioned above.
5461      (echo ':t
5462  /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
5463      if test -z "$ac_sed_cmds"; then
5464  	ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
5465      else
5466  	ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
5467      fi
5468      ac_sed_frag=`expr $ac_sed_frag + 1`
5469      ac_beg=$ac_end
5470      ac_end=`expr $ac_end + $ac_max_sed_lines`
5471    fi
5472  done
5473  if test -z "$ac_sed_cmds"; then
5474    ac_sed_cmds=cat
5475  fi
5476fi # test -n "$CONFIG_FILES"
5477
5478EOF
5479cat >>$CONFIG_STATUS <<\EOF
5480for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
5481  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
5482  case $ac_file in
5483  - | *:- | *:-:* ) # input from stdin
5484        cat >$tmp/stdin
5485        ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
5486        ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
5487  *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
5488        ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
5489  * )   ac_file_in=$ac_file.in ;;
5490  esac
5491
5492  # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
5493  ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
5494         X"$ac_file" : 'X\(//\)[^/]' \| \
5495         X"$ac_file" : 'X\(//\)$' \| \
5496         X"$ac_file" : 'X\(/\)' \| \
5497         .     : '\(.\)' 2>/dev/null ||
5498echo X"$ac_file" |
5499    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
5500  	  /^X\(\/\/\)[^/].*/{ s//\1/; q; }
5501  	  /^X\(\/\/\)$/{ s//\1/; q; }
5502  	  /^X\(\/\).*/{ s//\1/; q; }
5503  	  s/.*/./; q'`
5504  if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
5505    { case "$ac_dir" in
5506  [\\/]* | ?:[\\/]* ) as_incr_dir=;;
5507  *)                      as_incr_dir=.;;
5508esac
5509as_dummy="$ac_dir"
5510for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
5511  case $as_mkdir_dir in
5512    # Skip DOS drivespec
5513    ?:) as_incr_dir=$as_mkdir_dir ;;
5514    *)
5515      as_incr_dir=$as_incr_dir/$as_mkdir_dir
5516      test -d "$as_incr_dir" || mkdir "$as_incr_dir"
5517    ;;
5518  esac
5519done; }
5520
5521    ac_dir_suffix="/`echo $ac_dir|sed 's,^\./,,'`"
5522    # A "../" for each directory in $ac_dir_suffix.
5523    ac_dots=`echo "$ac_dir_suffix" | sed 's,/[^/]*,../,g'`
5524  else
5525    ac_dir_suffix= ac_dots=
5526  fi
5527
5528  case $srcdir in
5529  .)  ac_srcdir=.
5530      if test -z "$ac_dots"; then
5531         ac_top_srcdir=.
5532      else
5533         ac_top_srcdir=`echo $ac_dots | sed 's,/$,,'`
5534      fi ;;
5535  [\\/]* | ?:[\\/]* )
5536      ac_srcdir=$srcdir$ac_dir_suffix;
5537      ac_top_srcdir=$srcdir ;;
5538  *) # Relative path.
5539    ac_srcdir=$ac_dots$srcdir$ac_dir_suffix
5540    ac_top_srcdir=$ac_dots$srcdir ;;
5541  esac
5542
5543  case $INSTALL in
5544  [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
5545  *) ac_INSTALL=$ac_dots$INSTALL ;;
5546  esac
5547
5548  if test x"$ac_file" != x-; then
5549    { echo "$as_me:5549: creating $ac_file" >&5
5550echo "$as_me: creating $ac_file" >&6;}
5551    rm -f "$ac_file"
5552  fi
5553  # Let's still pretend it is `configure' which instantiates (i.e., don't
5554  # use $as_me), people would be surprised to read:
5555  #    /* config.h.  Generated automatically by config.status.  */
5556  configure_input="Generated automatically from `echo $ac_file_in |
5557                                                 sed 's,.*/,,'` by configure."
5558
5559  # First look for the input files in the build tree, otherwise in the
5560  # src tree.
5561  ac_file_inputs=`IFS=:
5562    for f in $ac_file_in; do
5563      case $f in
5564      -) echo $tmp/stdin ;;
5565      [\\/$]*)
5566         # Absolute (can't be DOS-style, as IFS=:)
5567         test -f "$f" || { { echo "$as_me:5567: error: cannot find input file: $f" >&5
5568echo "$as_me: error: cannot find input file: $f" >&2;}
5569   { (exit 1); exit 1; }; }
5570         echo $f;;
5571      *) # Relative
5572         if test -f "$f"; then
5573           # Build tree
5574           echo $f
5575         elif test -f "$srcdir/$f"; then
5576           # Source tree
5577           echo $srcdir/$f
5578         else
5579           # /dev/null tree
5580           { { echo "$as_me:5580: error: cannot find input file: $f" >&5
5581echo "$as_me: error: cannot find input file: $f" >&2;}
5582   { (exit 1); exit 1; }; }
5583         fi;;
5584      esac
5585    done` || { (exit 1); exit 1; }
5586EOF
5587cat >>$CONFIG_STATUS <<EOF
5588  sed "$ac_vpsub
5589$extrasub
5590EOF
5591cat >>$CONFIG_STATUS <<\EOF
5592:t
5593/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
5594s,@configure_input@,$configure_input,;t t
5595s,@srcdir@,$ac_srcdir,;t t
5596s,@top_srcdir@,$ac_top_srcdir,;t t
5597s,@INSTALL@,$ac_INSTALL,;t t
5598" $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
5599  rm -f $tmp/stdin
5600  if test x"$ac_file" != x-; then
5601    mv $tmp/out $ac_file
5602  else
5603    cat $tmp/out
5604    rm -f $tmp/out
5605  fi
5606
5607done
5608EOF
5609cat >>$CONFIG_STATUS <<\EOF
5610
5611#
5612# CONFIG_HEADER section.
5613#
5614
5615# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
5616# NAME is the cpp macro being defined and VALUE is the value it is being given.
5617#
5618# ac_d sets the value in "#define NAME VALUE" lines.
5619ac_dA='s,^\([ 	]*\)#\([ 	]*define[ 	][ 	]*\)'
5620ac_dB='[ 	].*$,\1#\2'
5621ac_dC=' '
5622ac_dD=',;t'
5623# ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
5624ac_uA='s,^\([ 	]*\)#\([ 	]*\)undef\([ 	][ 	]*\)'
5625ac_uB='$,\1#\2define\3'
5626ac_uC=' '
5627ac_uD=',;t'
5628
5629for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
5630  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
5631  case $ac_file in
5632  - | *:- | *:-:* ) # input from stdin
5633        cat >$tmp/stdin
5634        ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
5635        ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
5636  *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
5637        ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
5638  * )   ac_file_in=$ac_file.in ;;
5639  esac
5640
5641  test x"$ac_file" != x- && { echo "$as_me:5641: creating $ac_file" >&5
5642echo "$as_me: creating $ac_file" >&6;}
5643
5644  # First look for the input files in the build tree, otherwise in the
5645  # src tree.
5646  ac_file_inputs=`IFS=:
5647    for f in $ac_file_in; do
5648      case $f in
5649      -) echo $tmp/stdin ;;
5650      [\\/$]*)
5651         # Absolute (can't be DOS-style, as IFS=:)
5652         test -f "$f" || { { echo "$as_me:5652: error: cannot find input file: $f" >&5
5653echo "$as_me: error: cannot find input file: $f" >&2;}
5654   { (exit 1); exit 1; }; }
5655         echo $f;;
5656      *) # Relative
5657         if test -f "$f"; then
5658           # Build tree
5659           echo $f
5660         elif test -f "$srcdir/$f"; then
5661           # Source tree
5662           echo $srcdir/$f
5663         else
5664           # /dev/null tree
5665           { { echo "$as_me:5665: error: cannot find input file: $f" >&5
5666echo "$as_me: error: cannot find input file: $f" >&2;}
5667   { (exit 1); exit 1; }; }
5668         fi;;
5669      esac
5670    done` || { (exit 1); exit 1; }
5671  # Remove the trailing spaces.
5672  sed 's/[ 	]*$//' $ac_file_inputs >$tmp/in
5673
5674EOF
5675
5676# Transform confdefs.h into two sed scripts, `conftest.defines' and
5677# `conftest.undefs', that substitutes the proper values into
5678# config.h.in to produce config.h.  The first handles `#define'
5679# templates, and the second `#undef' templates.
5680# And first: Protect against being on the right side of a sed subst in
5681# config.status.  Protect against being in an unquoted here document
5682# in config.status.
5683rm -f conftest.defines conftest.undefs
5684# Using a here document instead of a string reduces the quoting nightmare.
5685# Putting comments in sed scripts is not portable.
5686#
5687# `end' is used to avoid that the second main sed command (meant for
5688# 0-ary CPP macros) applies to n-ary macro definitions.
5689# See the Autoconf documentation for `clear'.
5690cat >confdef2sed.sed <<\EOF
5691s/[\\&,]/\\&/g
5692s,[\\$`],\\&,g
5693t clear
5694: clear
5695s,^[ 	]*#[ 	]*define[ 	][ 	]*\(\([^ 	(][^ 	(]*\)([^)]*)\)[ 	]*\(.*\)$,${ac_dA}\2${ac_dB}\1${ac_dC}\3${ac_dD},gp
5696t end
5697s,^[ 	]*#[ 	]*define[ 	][ 	]*\([^ 	][^ 	]*\)[ 	]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
5698: end
5699EOF
5700# If some macros were called several times there might be several times
5701# the same #defines, which is useless.  Nevertheless, we may not want to
5702# sort them, since we want the *last* AC-DEFINE to be honored.
5703uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
5704sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
5705rm -f confdef2sed.sed
5706
5707# This sed command replaces #undef with comments.  This is necessary, for
5708# example, in the case of _POSIX_SOURCE, which is predefined and required
5709# on some systems where configure will not decide to define it.
5710cat >>conftest.undefs <<\EOF
5711s,^[ 	]*#[ 	]*undef[ 	][ 	]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
5712EOF
5713
5714# Break up conftest.defines because some shells have a limit on the size
5715# of here documents, and old seds have small limits too (100 cmds).
5716echo '  # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
5717echo '  if egrep "^[ 	]*#[ 	]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
5718echo '  # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
5719echo '  :' >>$CONFIG_STATUS
5720rm -f conftest.tail
5721while grep . conftest.defines >/dev/null
5722do
5723  # Write a limited-size here document to $tmp/defines.sed.
5724  echo '  cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
5725  # Speed up: don't consider the non `#define' lines.
5726  echo '/^[ 	]*#[ 	]*define/!b' >>$CONFIG_STATUS
5727  # Work around the forget-to-reset-the-flag bug.
5728  echo 't clr' >>$CONFIG_STATUS
5729  echo ': clr' >>$CONFIG_STATUS
5730  sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
5731  echo 'CEOF
5732  sed -f $tmp/defines.sed $tmp/in >$tmp/out
5733  rm -f $tmp/in
5734  mv $tmp/out $tmp/in
5735' >>$CONFIG_STATUS
5736  sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
5737  rm -f conftest.defines
5738  mv conftest.tail conftest.defines
5739done
5740rm -f conftest.defines
5741echo '  fi # egrep' >>$CONFIG_STATUS
5742echo >>$CONFIG_STATUS
5743
5744# Break up conftest.undefs because some shells have a limit on the size
5745# of here documents, and old seds have small limits too (100 cmds).
5746echo '  # Handle all the #undef templates' >>$CONFIG_STATUS
5747rm -f conftest.tail
5748while grep . conftest.undefs >/dev/null
5749do
5750  # Write a limited-size here document to $tmp/undefs.sed.
5751  echo '  cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
5752  # Speed up: don't consider the non `#undef'
5753  echo '/^[ 	]*#[ 	]*undef/!b' >>$CONFIG_STATUS
5754  # Work around the forget-to-reset-the-flag bug.
5755  echo 't clr' >>$CONFIG_STATUS
5756  echo ': clr' >>$CONFIG_STATUS
5757  sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
5758  echo 'CEOF
5759  sed -f $tmp/undefs.sed $tmp/in >$tmp/out
5760  rm -f $tmp/in
5761  mv $tmp/out $tmp/in
5762' >>$CONFIG_STATUS
5763  sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
5764  rm -f conftest.undefs
5765  mv conftest.tail conftest.undefs
5766done
5767rm -f conftest.undefs
5768
5769cat >>$CONFIG_STATUS <<\EOF
5770  # Let's still pretend it is `configure' which instantiates (i.e., don't
5771  # use $as_me), people would be surprised to read:
5772  #    /* config.h.  Generated automatically by config.status.  */
5773  if test x"$ac_file" = x-; then
5774    echo "/* Generated automatically by configure.  */" >$tmp/config.h
5775  else
5776    echo "/* $ac_file.  Generated automatically by configure.  */" >$tmp/config.h
5777  fi
5778  cat $tmp/in >>$tmp/config.h
5779  rm -f $tmp/in
5780  if test x"$ac_file" != x-; then
5781    if cmp -s $ac_file $tmp/config.h 2>/dev/null; then
5782      { echo "$as_me:5782: $ac_file is unchanged" >&5
5783echo "$as_me: $ac_file is unchanged" >&6;}
5784    else
5785      ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
5786         X"$ac_file" : 'X\(//\)[^/]' \| \
5787         X"$ac_file" : 'X\(//\)$' \| \
5788         X"$ac_file" : 'X\(/\)' \| \
5789         .     : '\(.\)' 2>/dev/null ||
5790echo X"$ac_file" |
5791    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
5792  	  /^X\(\/\/\)[^/].*/{ s//\1/; q; }
5793  	  /^X\(\/\/\)$/{ s//\1/; q; }
5794  	  /^X\(\/\).*/{ s//\1/; q; }
5795  	  s/.*/./; q'`
5796      if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
5797        { case "$ac_dir" in
5798  [\\/]* | ?:[\\/]* ) as_incr_dir=;;
5799  *)                      as_incr_dir=.;;
5800esac
5801as_dummy="$ac_dir"
5802for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
5803  case $as_mkdir_dir in
5804    # Skip DOS drivespec
5805    ?:) as_incr_dir=$as_mkdir_dir ;;
5806    *)
5807      as_incr_dir=$as_incr_dir/$as_mkdir_dir
5808      test -d "$as_incr_dir" || mkdir "$as_incr_dir"
5809    ;;
5810  esac
5811done; }
5812
5813      fi
5814      rm -f $ac_file
5815      mv $tmp/config.h $ac_file
5816    fi
5817  else
5818    cat $tmp/config.h
5819    rm -f $tmp/config.h
5820  fi
5821done
5822EOF
5823cat >>$CONFIG_STATUS <<\EOF
5824
5825#
5826# CONFIG_COMMANDS section.
5827#
5828for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
5829  ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
5830  ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
5831
5832  case $ac_dest in
5833    default )
5834# Makefile uses this timestamp file to record whether config.h is up to date.
5835echo > stamp-h
5836 ;;
5837  esac
5838done
5839EOF
5840
5841cat >>$CONFIG_STATUS <<\EOF
5842
5843{ (exit 0); exit 0; }
5844EOF
5845chmod +x $CONFIG_STATUS
5846ac_clean_files=$ac_clean_files_save
5847
5848# configure is writing to config.log, and then calls config.status.
5849# config.status does its own redirection, appending to config.log.
5850# Unfortunately, on DOS this fails, as config.log is still kept open
5851# by configure, so config.status won't be able to write to it; its
5852# output is simply discarded.  So we exec the FD to /dev/null,
5853# effectively closing config.log, so it can be properly (re)opened and
5854# appended to by config.status.  When coming back to configure, we
5855# need to make the FD available again.
5856if test "$no_create" != yes; then
5857  ac_cs_success=:
5858  exec 5>/dev/null
5859  $SHELL $CONFIG_STATUS || ac_cs_success=false
5860  exec 5>>config.log
5861  # Use ||, not &&, to avoid exiting from the if with $? = 1, which
5862  # would make configure fail if this is the last instruction.
5863  $ac_cs_success || { (exit 1); exit 1; }
5864fi
5865
5866