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