1#! /bin/sh
2# Guess values for system-dependent variables and create Makefiles.
3# Generated by Autoconf 2.52.20170501.
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="dialog.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'
173datarootdir='${prefix}/share'
174datadir='${datarootdir}'
175sysconfdir='${prefix}/etc'
176sharedstatedir='${prefix}/com'
177localstatedir='${prefix}/var'
178libdir='${exec_prefix}/lib'
179includedir='${prefix}/include'
180oldincludedir='/usr/include'
181infodir='${datarootdir}/info'
182mandir='${datarootdir}/man'
183
184# Identity of this package.
185PACKAGE_NAME=
186PACKAGE_TARNAME=
187PACKAGE_VERSION=
188PACKAGE_STRING=
189PACKAGE_BUGREPORT=
190
191ac_prev=
192for ac_option
193do
194  # If the previous option needs an argument, assign it.
195  if test -n "$ac_prev"; then
196    eval "$ac_prev=\$ac_option"
197    ac_prev=
198    continue
199  fi
200
201  ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
202
203  # Accept the important Cygnus configure options, so we can diagnose typos.
204
205  case $ac_option in
206
207  -bindir | --bindir | --bindi | --bind | --bin | --bi)
208    ac_prev=bindir ;;
209  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
210    bindir=$ac_optarg ;;
211
212  -build | --build | --buil | --bui | --bu)
213    ac_prev=build_alias ;;
214  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
215    build_alias=$ac_optarg ;;
216
217  -cache-file | --cache-file | --cache-fil | --cache-fi \
218  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
219    ac_prev=cache_file ;;
220  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
221  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
222    cache_file=$ac_optarg ;;
223
224  --config-cache | -C)
225    cache_file=config.cache ;;
226
227  -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
228    ac_prev=datadir ;;
229  -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
230  | --da=*)
231    datadir=$ac_optarg ;;
232
233  -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
234  | --dataroo | --dataro | --datar)
235    ac_prev=datarootdir ;;
236  -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
237  | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
238    datarootdir=$ac_optarg ;;
239
240  -disable-* | --disable-*)
241    ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
242    # Reject names that are not valid shell variable names.
243    expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
244      { echo "$as_me: error: invalid feature name: $ac_feature" >&2
245   { (exit 1); exit 1; }; }
246    ac_feature=`echo $ac_feature | sed 's/-/_/g'`
247    eval "enable_$ac_feature=no" ;;
248
249  -enable-* | --enable-*)
250    ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
251    # Reject names that are not valid shell variable names.
252    expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
253      { echo "$as_me: error: invalid feature name: $ac_feature" >&2
254   { (exit 1); exit 1; }; }
255    ac_feature=`echo $ac_feature | sed 's/-/_/g'`
256    case $ac_option in
257      *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
258      *) ac_optarg=yes ;;
259    esac
260    eval "enable_$ac_feature='$ac_optarg'" ;;
261
262  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
263  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
264  | --exec | --exe | --ex)
265    ac_prev=exec_prefix ;;
266  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
267  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
268  | --exec=* | --exe=* | --ex=*)
269    exec_prefix=$ac_optarg ;;
270
271  -gas | --gas | --ga | --g)
272    # Obsolete; use --with-gas.
273    with_gas=yes ;;
274
275  -help | --help | --hel | --he | -h)
276    ac_init_help=long ;;
277  -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
278    ac_init_help=recursive ;;
279  -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
280    ac_init_help=short ;;
281
282  -host | --host | --hos | --ho)
283    ac_prev=host_alias ;;
284  -host=* | --host=* | --hos=* | --ho=*)
285    host_alias=$ac_optarg ;;
286
287  -includedir | --includedir | --includedi | --included | --include \
288  | --includ | --inclu | --incl | --inc)
289    ac_prev=includedir ;;
290  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
291  | --includ=* | --inclu=* | --incl=* | --inc=*)
292    includedir=$ac_optarg ;;
293
294  -infodir | --infodir | --infodi | --infod | --info | --inf)
295    ac_prev=infodir ;;
296  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
297    infodir=$ac_optarg ;;
298
299  -libdir | --libdir | --libdi | --libd)
300    ac_prev=libdir ;;
301  -libdir=* | --libdir=* | --libdi=* | --libd=*)
302    libdir=$ac_optarg ;;
303
304  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
305  | --libexe | --libex | --libe)
306    ac_prev=libexecdir ;;
307  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
308  | --libexe=* | --libex=* | --libe=*)
309    libexecdir=$ac_optarg ;;
310
311  -localstatedir | --localstatedir | --localstatedi | --localstated \
312  | --localstate | --localstat | --localsta | --localst \
313  | --locals | --local | --loca | --loc | --lo)
314    ac_prev=localstatedir ;;
315  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
316  | --localstate=* | --localstat=* | --localsta=* | --localst=* \
317  | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
318    localstatedir=$ac_optarg ;;
319
320  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
321    ac_prev=mandir ;;
322  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
323    mandir=$ac_optarg ;;
324
325  -nfp | --nfp | --nf)
326    # Obsolete; use --without-fp.
327    with_fp=no ;;
328
329  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
330  | --no-cr | --no-c)
331    no_create=yes ;;
332
333  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
334  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
335    no_recursion=yes ;;
336
337  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
338  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
339  | --oldin | --oldi | --old | --ol | --o)
340    ac_prev=oldincludedir ;;
341  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
342  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
343  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
344    oldincludedir=$ac_optarg ;;
345
346  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
347    ac_prev=prefix ;;
348  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
349    prefix=$ac_optarg ;;
350
351  -program-prefix | --program-prefix | --program-prefi | --program-pref \
352  | --program-pre | --program-pr | --program-p)
353    ac_prev=program_prefix ;;
354  -program-prefix=* | --program-prefix=* | --program-prefi=* \
355  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
356    program_prefix=$ac_optarg ;;
357
358  -program-suffix | --program-suffix | --program-suffi | --program-suff \
359  | --program-suf | --program-su | --program-s)
360    ac_prev=program_suffix ;;
361  -program-suffix=* | --program-suffix=* | --program-suffi=* \
362  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
363    program_suffix=$ac_optarg ;;
364
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    ac_prev=program_transform_name ;;
373  -program-transform-name=* | --program-transform-name=* \
374  | --program-transform-nam=* | --program-transform-na=* \
375  | --program-transform-n=* | --program-transform-=* \
376  | --program-transform=* | --program-transfor=* \
377  | --program-transfo=* | --program-transf=* \
378  | --program-trans=* | --program-tran=* \
379  | --progr-tra=* | --program-tr=* | --program-t=*)
380    program_transform_name=$ac_optarg ;;
381
382  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
383  | -silent | --silent | --silen | --sile | --sil)
384    silent=yes ;;
385
386  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
387    ac_prev=sbindir ;;
388  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
389  | --sbi=* | --sb=*)
390    sbindir=$ac_optarg ;;
391
392  -sharedstatedir | --sharedstatedir | --sharedstatedi \
393  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
394  | --sharedst | --shareds | --shared | --share | --shar \
395  | --sha | --sh)
396    ac_prev=sharedstatedir ;;
397  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
398  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
399  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
400  | --sha=* | --sh=*)
401    sharedstatedir=$ac_optarg ;;
402
403  -site | --site | --sit)
404    ac_prev=site ;;
405  -site=* | --site=* | --sit=*)
406    site=$ac_optarg ;;
407
408  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
409    ac_prev=srcdir ;;
410  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
411    srcdir=$ac_optarg ;;
412
413  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
414  | --syscon | --sysco | --sysc | --sys | --sy)
415    ac_prev=sysconfdir ;;
416  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
417  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
418    sysconfdir=$ac_optarg ;;
419
420  -target | --target | --targe | --targ | --tar | --ta | --t)
421    ac_prev=target_alias ;;
422  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
423    target_alias=$ac_optarg ;;
424
425  -v | -verbose | --verbose | --verbos | --verbo | --verb)
426    verbose=yes ;;
427
428  -version | --version | --versio | --versi | --vers | -V)
429    ac_init_version=: ;;
430
431  -with-* | --with-*)
432    ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
433    # Reject names that are not valid shell variable names.
434    expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
435      { echo "$as_me: error: invalid package name: $ac_package" >&2
436   { (exit 1); exit 1; }; }
437    ac_package=`echo $ac_package| sed 's/-/_/g'`
438    case $ac_option in
439      *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
440      *) ac_optarg=yes ;;
441    esac
442    eval "with_$ac_package='$ac_optarg'" ;;
443
444  -without-* | --without-*)
445    ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
446    # Reject names that are not valid shell variable names.
447    expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
448      { echo "$as_me: error: invalid package name: $ac_package" >&2
449   { (exit 1); exit 1; }; }
450    ac_package=`echo $ac_package | sed 's/-/_/g'`
451    eval "with_$ac_package=no" ;;
452
453  --x)
454    # Obsolete; use --with-x.
455    with_x=yes ;;
456
457  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
458  | --x-incl | --x-inc | --x-in | --x-i)
459    ac_prev=x_includes ;;
460  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
461  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
462    x_includes=$ac_optarg ;;
463
464  -x-libraries | --x-libraries | --x-librarie | --x-librari \
465  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
466    ac_prev=x_libraries ;;
467  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
468  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
469    x_libraries=$ac_optarg ;;
470
471  -*) { echo "$as_me: error: unrecognized option: $ac_option
472Try \`$0 --help' for more information." >&2
473   { (exit 1); exit 1; }; }
474    ;;
475
476  *=*)
477    ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
478    # Reject names that are not valid shell variable names.
479    expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
480      { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
481   { (exit 1); exit 1; }; }
482    ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
483    eval "$ac_envvar='$ac_optarg'"
484    export $ac_envvar ;;
485
486  *)
487    # FIXME: should be removed in autoconf 3.0.
488    echo "$as_me: WARNING: you should use --build, --host, --target" >&2
489    expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
490      echo "$as_me: WARNING: invalid host type: $ac_option" >&2
491    : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
492    ;;
493
494  esac
495done
496
497if test -n "$ac_prev"; then
498  ac_option=--`echo $ac_prev | sed 's/_/-/g'`
499  { echo "$as_me: error: missing argument to $ac_option" >&2
500   { (exit 1); exit 1; }; }
501fi
502
503# Be sure to have absolute paths.
504for ac_var in exec_prefix prefix
505do
506  eval ac_val=$`echo $ac_var`
507  case $ac_val in
508    [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
509    *)  { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
510   { (exit 1); exit 1; }; };;
511  esac
512done
513
514# Be sure to have absolute paths.
515for ac_var in bindir sbindir libexecdir datarootdir datadir sysconfdir sharedstatedir \
516              localstatedir libdir includedir oldincludedir infodir mandir
517do
518  eval ac_val=$`echo $ac_var`
519  case $ac_val in
520    [\\/$]* | ?:[\\/]* ) ;;
521    *)  { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
522   { (exit 1); exit 1; }; };;
523  esac
524done
525
526# There might be people who depend on the old broken behavior: `$host'
527# used to hold the argument of --host etc.
528build=$build_alias
529host=$host_alias
530target=$target_alias
531
532# FIXME: should be removed in autoconf 3.0.
533if test "x$host_alias" != x; then
534  if test "x$build_alias" = x; then
535    cross_compiling=maybe
536    echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
537    If a cross compiler is detected then cross compile mode will be used." >&2
538  elif test "x$build_alias" != "x$host_alias"; then
539    cross_compiling=yes
540  fi
541fi
542
543ac_tool_prefix=
544test -n "$host_alias" && ac_tool_prefix=$host_alias-
545
546test "$silent" = yes && exec 6>/dev/null
547
548# Find the source files, if location was not specified.
549if test -z "$srcdir"; then
550  ac_srcdir_defaulted=yes
551  # Try the directory containing this script, then its parent.
552  ac_prog=$0
553  ac_confdir=`echo "$ac_prog" | sed 's%[\\/][^\\/][^\\/]*$%%'`
554  test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
555  srcdir=$ac_confdir
556  if test ! -r $srcdir/$ac_unique_file; then
557    srcdir=..
558  fi
559else
560  ac_srcdir_defaulted=no
561fi
562if test ! -r $srcdir/$ac_unique_file; then
563  if test "$ac_srcdir_defaulted" = yes; then
564    { echo "$as_me: error: cannot find sources in $ac_confdir or .." >&2
565   { (exit 1); exit 1; }; }
566  else
567    { echo "$as_me: error: cannot find sources in $srcdir" >&2
568   { (exit 1); exit 1; }; }
569  fi
570fi
571srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
572ac_env_build_alias_set=${build_alias+set}
573ac_env_build_alias_value=$build_alias
574ac_cv_env_build_alias_set=${build_alias+set}
575ac_cv_env_build_alias_value=$build_alias
576ac_env_host_alias_set=${host_alias+set}
577ac_env_host_alias_value=$host_alias
578ac_cv_env_host_alias_set=${host_alias+set}
579ac_cv_env_host_alias_value=$host_alias
580ac_env_target_alias_set=${target_alias+set}
581ac_env_target_alias_value=$target_alias
582ac_cv_env_target_alias_set=${target_alias+set}
583ac_cv_env_target_alias_value=$target_alias
584ac_env_CC_set=${CC+set}
585ac_env_CC_value=$CC
586ac_cv_env_CC_set=${CC+set}
587ac_cv_env_CC_value=$CC
588ac_env_CFLAGS_set=${CFLAGS+set}
589ac_env_CFLAGS_value=$CFLAGS
590ac_cv_env_CFLAGS_set=${CFLAGS+set}
591ac_cv_env_CFLAGS_value=$CFLAGS
592ac_env_LDFLAGS_set=${LDFLAGS+set}
593ac_env_LDFLAGS_value=$LDFLAGS
594ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
595ac_cv_env_LDFLAGS_value=$LDFLAGS
596ac_env_CPPFLAGS_set=${CPPFLAGS+set}
597ac_env_CPPFLAGS_value=$CPPFLAGS
598ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
599ac_cv_env_CPPFLAGS_value=$CPPFLAGS
600ac_env_CPP_set=${CPP+set}
601ac_env_CPP_value=$CPP
602ac_cv_env_CPP_set=${CPP+set}
603ac_cv_env_CPP_value=$CPP
604
605#
606# Report the --help message.
607#
608if test "$ac_init_help" = "long"; then
609  # Omit some internal or obsolete options to make the list less imposing.
610  # This message is too long to be a string in the A/UX 3.1 sh.
611  cat <<EOF
612\`configure' configures this package to adapt to many kinds of systems.
613
614Usage: $0 [OPTION]... [VAR=VALUE]...
615
616To assign environment variables (e.g., CC, CFLAGS...), specify them as
617VAR=VALUE.  See below for descriptions of some of the useful variables.
618
619Defaults for the options are specified in brackets.
620
621Configuration:
622  -h, --help              display this help and exit
623      --help=short        display options specific to this package
624      --help=recursive    display the short help of all the included packages
625  -V, --version           display version information and exit
626  -q, --quiet, --silent   do not print \`checking...' messages
627      --cache-file=FILE   cache test results in FILE [disabled]
628  -C, --config-cache      alias for \`--cache-file=config.cache'
629  -n, --no-create         do not create output files
630      --srcdir=DIR        find the sources in DIR [configure dir or \`..']
631
632EOF
633
634  cat <<EOF
635Installation directories:
636  --prefix=PREFIX         install architecture-independent files in PREFIX
637                          [$ac_default_prefix]
638  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
639                          [PREFIX]
640
641By default, \`make install' will install all the files in
642\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
643an installation prefix other than \`$ac_default_prefix' using \`--prefix',
644for instance \`--prefix=\$HOME'.
645
646For better control, use the options below.
647
648Fine tuning of the installation directories:
649  --bindir=DIR            user executables [EPREFIX/bin]
650  --sbindir=DIR           system admin executables [EPREFIX/sbin]
651  --libexecdir=DIR        program executables [EPREFIX/libexec]
652  --datarootdir=DIR       read-only architecture-independent data [PREFIX/share]
653  --datadir=DIR           read-only architecture-independent data [DATAROOTDIR]
654  --sysconfdir=DIR        read-only single-machine data [PREFIX/etc]
655  --sharedstatedir=DIR    modifiable architecture-independent data [PREFIX/com]
656  --localstatedir=DIR     modifiable single-machine data [PREFIX/var]
657  --libdir=DIR            object code libraries [EPREFIX/lib]
658  --includedir=DIR        C header files [PREFIX/include]
659  --oldincludedir=DIR     C header files for non-gcc [/usr/include]
660  --infodir=DIR           info documentation [DATAROOTDIR/info]
661  --mandir=DIR            man documentation [DATAROOTDIR/man]
662EOF
663
664  cat <<\EOF
665
666Program names:
667  --program-prefix=PREFIX            prepend PREFIX to installed program names
668  --program-suffix=SUFFIX            append SUFFIX to installed program names
669  --program-transform-name=PROGRAM   run sed PROGRAM on installed program names
670
671X features:
672  --x-includes=DIR    X include files are in DIR
673  --x-libraries=DIR   X library files are in DIR
674
675System types:
676  --build=BUILD           configure for building on BUILD [guessed]
677  --host=HOST       build programs to run on HOST [BUILD]
678EOF
679fi
680
681if test -n "$ac_init_help"; then
682
683  cat <<\EOF
684
685Optional Features:
686  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
687  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
688
689Optional Packages:
690  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
691  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
692
693  --disable-echo          do not display "compiling" commands
694  --disable-largefile     omit support for large files
695  --with-install-prefix=XXX sets DESTDIR, useful for packaging
696  --with-warnings         test: turn on gcc warnings
697  --with-pkg-config{=path} enable/disable use of pkg-config
698  --with-package=XXX      rename dialog to XXX, library to libXXX.a, etc
699  --enable-header-subdir  install dlg_XXX headers to subdirectory
700  --with-man2html=XXX     use XXX rather than groff
701  --with-libiconv-prefix=DIR
702                          search for libiconv in DIR/include and DIR/lib
703  --enable-nls            use Native Language Support
704  --with-included-gettext use the GNU gettext library included here
705  --with-textdomain=PKG   NLS text-domain (default is package name)
706  --disable-included-msgs use included messages, for i18n support
707  --with-dmalloc          test: use Gray Watson's dmalloc library
708  --with-dbmalloc         test: use Conor Cahill's dbmalloc library
709  --with-purify           test: use Purify
710  --with-valgrind         test: use valgrind
711  --with-no-leaks         test: free permanent memory, analyze leaks
712  --disable-trace         do not support --trace option
713  --with-rel-version=XXX  override derived release version
714  --with-abi-version=XXX  override derived ABI version
715  --disable-libtool-version  enable to use libtool's incompatible naming scheme
716  --with-libtool          generate libraries with libtool
717  --with-libtool-opts=XXX specify additional libtool options
718  --with-export-syms=XXX  limit exported symbols using libtool
719  --with-shared           generate shared-libraries
720  --with-shlib-version=X  Specify rel or abi version for shared libs
721  --with-versioned-syms=X markup versioned symbols using ld
722  --with-curses-dir=DIR   directory in which (n)curses is installed
723  --enable-rpath          use rpath option when generating shared libraries
724  --with-screen=XXX       use specified curses-libraries
725  --with-ncursesw         use wide ncurses-libraries
726  --with-ncurses          use ncurses-libraries
727  --with-pdcurses         compile/link with pdcurses X11 library
728  --with-curses-colr      compile/link with HPUX 10.x color-curses
729  --with-curses-5lib      compile/link with SunOS 5lib curses
730  --with-Xaw3d            link with Xaw 3d library
731  --with-Xaw3dxft         link with Xaw 3d xft library
732  --with-neXtaw           link with neXT Athena library
733  --with-XawPlus          link with Athena-Plus library
734  --with-x                use the X Window System
735  --disable-extras        do not include extra dialogs
736  --disable-rc-file       do not include config-file support
737  --disable-Xdialog       do not include Xdialog-style dialogs (1.1)
738  --disable-Xdialog2      do not include extra Xdialog-style dialogs (1.2)
739  --disable-whiptail      do not map extra whiptail options
740  --disable-form          do not include the form dialog
741  --disable-gauge         do not include the gauge dialogs
742  --disable-tailbox       do not include the tailbox dialog
743  --disable-mixedform     do not include the mixedform dialog
744  --disable-mixedgauge    do not include the mixedgauge dialog
745  --enable-widec          enable wide-curses features
746  --disable-rpath-hack    don't add rpath options for additional libraries
747
748Some influential environment variables:
749  CC          C compiler command
750  CFLAGS      C compiler flags
751  LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
752              nonstandard directory <lib dir>
753  CPPFLAGS    C/C++ preprocessor flags, e.g. -I<include dir> if you have
754              headers in a nonstandard directory <include dir>
755  CPP         C preprocessor
756
757Use these variables to override the choices made by `configure' or to help
758it to find libraries and programs with nonstandard names/locations.
759
760EOF
761fi
762
763if test "$ac_init_help" = "recursive"; then
764  # If there are subdirs, report their specific --help.
765  ac_popdir=`pwd`
766  for ac_subdir in : $ac_subdirs_all; do test "x$ac_subdir" = x: && continue
767    cd $ac_subdir
768    # A "../" for each directory in /$ac_subdir.
769    ac_dots=`echo $ac_subdir |
770             sed 's,^\./,,;s,[^/]$,&/,;s,[^/]*/,../,g'`
771
772    case $srcdir in
773    .) # No --srcdir option.  We are building in place.
774      ac_sub_srcdir=$srcdir ;;
775    [\\/]* | ?:[\\/]* ) # Absolute path.
776      ac_sub_srcdir=$srcdir/$ac_subdir ;;
777    *) # Relative path.
778      ac_sub_srcdir=$ac_dots$srcdir/$ac_subdir ;;
779    esac
780
781    # Check for guested configure; otherwise get Cygnus style configure.
782    if test -f $ac_sub_srcdir/configure.gnu; then
783      echo
784      $SHELL $ac_sub_srcdir/configure.gnu  --help=recursive
785    elif test -f $ac_sub_srcdir/configure; then
786      echo
787      $SHELL $ac_sub_srcdir/configure  --help=recursive
788    elif test -f $ac_sub_srcdir/configure.ac ||
789           test -f $ac_sub_srcdir/configure.in; then
790      echo
791      $ac_configure --help
792    else
793      echo "$as_me: WARNING: no configuration information is in $ac_subdir" >&2
794    fi
795    cd $ac_popdir
796  done
797fi
798
799test -n "$ac_init_help" && exit 0
800if $ac_init_version; then
801  cat <<\EOF
802
803Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
804Free Software Foundation, Inc.
805This configure script is free software; the Free Software Foundation
806gives unlimited permission to copy, distribute and modify it.
807EOF
808  exit 0
809fi
810exec 5>config.log
811cat >&5 <<EOF
812This file contains any messages produced by compilers while
813running configure, to aid debugging if configure makes a mistake.
814
815It was created by $as_me, which was
816generated by GNU Autoconf 2.52.20170501.  Invocation command line was
817
818  $ $0 $@
819
820EOF
821{
822cat <<_ASUNAME
823## ---------- ##
824## Platform.  ##
825## ---------- ##
826
827hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
828uname -m = `(uname -m) 2>/dev/null || echo unknown`
829uname -r = `(uname -r) 2>/dev/null || echo unknown`
830uname -s = `(uname -s) 2>/dev/null || echo unknown`
831uname -v = `(uname -v) 2>/dev/null || echo unknown`
832
833/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
834/bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
835
836/bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
837/usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
838/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
839hostinfo               = `(hostinfo) 2>/dev/null               || echo unknown`
840/bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
841/usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
842/bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
843
844PATH = $PATH
845
846_ASUNAME
847} >&5
848
849cat >&5 <<EOF
850## ------------ ##
851## Core tests.  ##
852## ------------ ##
853
854EOF
855
856# Keep a trace of the command line.
857# Strip out --no-create and --no-recursion so they do not pile up.
858# Also quote any args containing shell meta-characters.
859ac_configure_args=
860ac_sep=
861for ac_arg
862do
863  case $ac_arg in
864  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
865  | --no-cr | --no-c) ;;
866  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
867  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
868  *" "*|*"	"*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
869    ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"`
870    ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
871    ac_sep=" " ;;
872  *) ac_configure_args="$ac_configure_args$ac_sep$ac_arg"
873     ac_sep=" " ;;
874  esac
875  # Get rid of the leading space.
876done
877
878# When interrupted or exit'd, cleanup temporary files, and complete
879# config.log.  We remove comments because anyway the quotes in there
880# would cause problems or look ugly.
881trap 'exit_status=$?
882  # Save into config.log some information that might help in debugging.
883  echo >&5
884  echo "## ----------------- ##" >&5
885  echo "## Cache variables.  ##" >&5
886  echo "## ----------------- ##" >&5
887  echo >&5
888  # The following way of writing the cache mishandles newlines in values,
889{
890  (set) 2>&1 |
891    case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
892    *ac_space=\ *)
893      sed -n \
894        "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
895    	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
896      ;;
897    *)
898      sed -n \
899        "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
900      ;;
901    esac;
902} >&5
903  sed "/^$/d" confdefs.h >conftest.log
904  if test -s conftest.log; then
905    echo >&5
906    echo "## ------------ ##" >&5
907    echo "## confdefs.h.  ##" >&5
908    echo "## ------------ ##" >&5
909    echo >&5
910    cat conftest.log >&5
911  fi
912  (echo; echo) >&5
913  test "$ac_signal" != 0 &&
914    echo "$as_me: caught signal $ac_signal" >&5
915  echo "$as_me: exit $exit_status" >&5
916  rm -rf conftest* confdefs* core core.* *.core conf$$* $ac_clean_files &&
917    exit $exit_status
918     ' 0
919for ac_signal in 1 2 13 15; do
920  trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
921done
922ac_signal=0
923
924# confdefs.h avoids OS command line length limits that DEFS can exceed.
925rm -rf conftest* confdefs.h
926# AIX cpp loses on an empty file, so make sure it contains at least a newline.
927echo >confdefs.h
928
929# Let the site file select an alternate cache file if it wants to.
930# Prefer explicitly selected file to automatically selected ones.
931if test -z "$CONFIG_SITE"; then
932  if test "x$prefix" != xNONE; then
933    CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
934  else
935    CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
936  fi
937fi
938for ac_site_file in $CONFIG_SITE; do
939  if test -r "$ac_site_file"; then
940    { echo "$as_me:940: loading site script $ac_site_file" >&5
941echo "$as_me: loading site script $ac_site_file" >&6;}
942    cat "$ac_site_file" >&5
943    . "$ac_site_file"
944  fi
945done
946
947if test -r "$cache_file"; then
948  # Some versions of bash will fail to source /dev/null (special
949  # files actually), so we avoid doing that.
950  if test -f "$cache_file"; then
951    { echo "$as_me:951: loading cache $cache_file" >&5
952echo "$as_me: loading cache $cache_file" >&6;}
953    case $cache_file in
954      [\\/]* | ?:[\\/]* ) . $cache_file;;
955      *)                      . ./$cache_file;;
956    esac
957  fi
958else
959  { echo "$as_me:959: creating cache $cache_file" >&5
960echo "$as_me: creating cache $cache_file" >&6;}
961  >$cache_file
962fi
963
964# Check that the precious variables saved in the cache have kept the same
965# value.
966ac_cache_corrupted=false
967for ac_var in `(set) 2>&1 |
968               sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
969  eval ac_old_set=\$ac_cv_env_${ac_var}_set
970  eval ac_new_set=\$ac_env_${ac_var}_set
971  eval ac_old_val="\$ac_cv_env_${ac_var}_value"
972  eval ac_new_val="\$ac_env_${ac_var}_value"
973  case $ac_old_set,$ac_new_set in
974    set,)
975      { echo "$as_me:975: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
976echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
977      ac_cache_corrupted=: ;;
978    ,set)
979      { echo "$as_me:979: error: \`$ac_var' was not set in the previous run" >&5
980echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
981      ac_cache_corrupted=: ;;
982    ,);;
983    *)
984      if test "x$ac_old_val" != "x$ac_new_val"; then
985        { echo "$as_me:985: error: \`$ac_var' has changed since the previous run:" >&5
986echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
987        { echo "$as_me:987:   former value:  $ac_old_val" >&5
988echo "$as_me:   former value:  $ac_old_val" >&2;}
989        { echo "$as_me:989:   current value: $ac_new_val" >&5
990echo "$as_me:   current value: $ac_new_val" >&2;}
991        ac_cache_corrupted=:
992      fi;;
993  esac
994  # Pass precious variables to config.status.  It doesn't matter if
995  # we pass some twice (in addition to the command line arguments).
996  if test "$ac_new_set" = set; then
997    case $ac_new_val in
998    *" "*|*"	"*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
999      ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"`
1000      ac_configure_args="$ac_configure_args '$ac_arg'"
1001      ;;
1002    *) ac_configure_args="$ac_configure_args $ac_var=$ac_new_val"
1003       ;;
1004    esac
1005  fi
1006done
1007if $ac_cache_corrupted; then
1008  { echo "$as_me:1008: error: changes in the environment can compromise the build" >&5
1009echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1010  { { echo "$as_me:1010: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1011echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1012   { (exit 1); exit 1; }; }
1013fi
1014
1015ac_ext=c
1016ac_cpp='$CPP $CPPFLAGS'
1017ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1018ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1019ac_compiler_gnu=$ac_cv_c_compiler_gnu
1020ac_main_return=return
1021
1022case `echo "testing\c" 2>/dev/null; echo 1,2,3`,`echo -n testing 2>/dev/null; echo 1,2,3` in
1023  *c*,-n*) ECHO_N= ECHO_C=	# newlines do not sed ;-) only broken shells would use this case anyway
1024		   ECHO_T='	' ;;
1025  *c*,*  ) ECHO_N=-n ECHO_C= ECHO_T= ;;
1026  *)      ECHO_N= ECHO_C='\c' ECHO_T= ;;
1027esac
1028echo "#! $SHELL" >conftest.sh
1029echo  "exit 0"   >>conftest.sh
1030chmod +x conftest.sh
1031if { (echo "$as_me:1031: PATH=\".;.\"; conftest.sh") >&5
1032  (PATH=".;."; conftest.sh) 2>&5
1033  ac_status=$?
1034  echo "$as_me:1034: \$? = $ac_status" >&5
1035  (exit $ac_status); }; then
1036  ac_path_separator=';'
1037else
1038  ac_path_separator=:
1039fi
1040PATH_SEPARATOR="$ac_path_separator"
1041rm -f conftest.sh
1042
1043ac_config_headers="$ac_config_headers dlg_config.h:config.hin"
1044
1045test "$program_prefix" != NONE &&
1046  program_transform_name="s,^,$program_prefix,;$program_transform_name"
1047# Use a double $ so make ignores it.
1048test "$program_suffix" != NONE &&
1049  program_transform_name="s,\$,$program_suffix,;$program_transform_name"
1050# Double any \ or $.  echo might interpret backslashes.
1051# By default was `s,x,x', remove it if useless.
1052cat <<\_ACEOF >conftest.sed
1053s/[\\$]/&&/g;s/;s,x,x,$//
1054_ACEOF
1055program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
1056rm conftest.sed
1057
1058DESTDIR=
1059
1060ac_ext=c
1061ac_cpp='$CPP $CPPFLAGS'
1062ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1063ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1064ac_compiler_gnu=$ac_cv_c_compiler_gnu
1065ac_main_return=return
1066if test -n "$ac_tool_prefix"; then
1067  # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
1068set dummy ${ac_tool_prefix}gcc; ac_word=$2
1069echo "$as_me:1069: checking for $ac_word" >&5
1070echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1071if test "${ac_cv_prog_CC+set}" = set; then
1072  echo $ECHO_N "(cached) $ECHO_C" >&6
1073else
1074  if test -n "$CC"; then
1075  ac_cv_prog_CC="$CC" # Let the user override the test.
1076else
1077  ac_save_IFS=$IFS; IFS=$ac_path_separator
1078ac_dummy="$PATH"
1079for ac_dir in $ac_dummy; do
1080  IFS=$ac_save_IFS
1081  test -z "$ac_dir" && ac_dir=.
1082  $as_executable_p "$ac_dir/$ac_word" || continue
1083ac_cv_prog_CC="${ac_tool_prefix}gcc"
1084echo "$as_me:1084: found $ac_dir/$ac_word" >&5
1085break
1086done
1087
1088fi
1089fi
1090CC=$ac_cv_prog_CC
1091if test -n "$CC"; then
1092  echo "$as_me:1092: result: $CC" >&5
1093echo "${ECHO_T}$CC" >&6
1094else
1095  echo "$as_me:1095: result: no" >&5
1096echo "${ECHO_T}no" >&6
1097fi
1098
1099fi
1100if test -z "$ac_cv_prog_CC"; then
1101  ac_ct_CC=$CC
1102  # Extract the first word of "gcc", so it can be a program name with args.
1103set dummy gcc; ac_word=$2
1104echo "$as_me:1104: checking for $ac_word" >&5
1105echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1106if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1107  echo $ECHO_N "(cached) $ECHO_C" >&6
1108else
1109  if test -n "$ac_ct_CC"; then
1110  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1111else
1112  ac_save_IFS=$IFS; IFS=$ac_path_separator
1113ac_dummy="$PATH"
1114for ac_dir in $ac_dummy; do
1115  IFS=$ac_save_IFS
1116  test -z "$ac_dir" && ac_dir=.
1117  $as_executable_p "$ac_dir/$ac_word" || continue
1118ac_cv_prog_ac_ct_CC="gcc"
1119echo "$as_me:1119: found $ac_dir/$ac_word" >&5
1120break
1121done
1122
1123fi
1124fi
1125ac_ct_CC=$ac_cv_prog_ac_ct_CC
1126if test -n "$ac_ct_CC"; then
1127  echo "$as_me:1127: result: $ac_ct_CC" >&5
1128echo "${ECHO_T}$ac_ct_CC" >&6
1129else
1130  echo "$as_me:1130: result: no" >&5
1131echo "${ECHO_T}no" >&6
1132fi
1133
1134  CC=$ac_ct_CC
1135else
1136  CC="$ac_cv_prog_CC"
1137fi
1138
1139if test -z "$CC"; then
1140  if test -n "$ac_tool_prefix"; then
1141  # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
1142set dummy ${ac_tool_prefix}cc; ac_word=$2
1143echo "$as_me:1143: checking for $ac_word" >&5
1144echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1145if test "${ac_cv_prog_CC+set}" = set; then
1146  echo $ECHO_N "(cached) $ECHO_C" >&6
1147else
1148  if test -n "$CC"; then
1149  ac_cv_prog_CC="$CC" # Let the user override the test.
1150else
1151  ac_save_IFS=$IFS; IFS=$ac_path_separator
1152ac_dummy="$PATH"
1153for ac_dir in $ac_dummy; do
1154  IFS=$ac_save_IFS
1155  test -z "$ac_dir" && ac_dir=.
1156  $as_executable_p "$ac_dir/$ac_word" || continue
1157ac_cv_prog_CC="${ac_tool_prefix}cc"
1158echo "$as_me:1158: found $ac_dir/$ac_word" >&5
1159break
1160done
1161
1162fi
1163fi
1164CC=$ac_cv_prog_CC
1165if test -n "$CC"; then
1166  echo "$as_me:1166: result: $CC" >&5
1167echo "${ECHO_T}$CC" >&6
1168else
1169  echo "$as_me:1169: result: no" >&5
1170echo "${ECHO_T}no" >&6
1171fi
1172
1173fi
1174if test -z "$ac_cv_prog_CC"; then
1175  ac_ct_CC=$CC
1176  # Extract the first word of "cc", so it can be a program name with args.
1177set dummy cc; ac_word=$2
1178echo "$as_me:1178: checking for $ac_word" >&5
1179echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1180if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1181  echo $ECHO_N "(cached) $ECHO_C" >&6
1182else
1183  if test -n "$ac_ct_CC"; then
1184  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1185else
1186  ac_save_IFS=$IFS; IFS=$ac_path_separator
1187ac_dummy="$PATH"
1188for ac_dir in $ac_dummy; do
1189  IFS=$ac_save_IFS
1190  test -z "$ac_dir" && ac_dir=.
1191  $as_executable_p "$ac_dir/$ac_word" || continue
1192ac_cv_prog_ac_ct_CC="cc"
1193echo "$as_me:1193: found $ac_dir/$ac_word" >&5
1194break
1195done
1196
1197fi
1198fi
1199ac_ct_CC=$ac_cv_prog_ac_ct_CC
1200if test -n "$ac_ct_CC"; then
1201  echo "$as_me:1201: result: $ac_ct_CC" >&5
1202echo "${ECHO_T}$ac_ct_CC" >&6
1203else
1204  echo "$as_me:1204: result: no" >&5
1205echo "${ECHO_T}no" >&6
1206fi
1207
1208  CC=$ac_ct_CC
1209else
1210  CC="$ac_cv_prog_CC"
1211fi
1212
1213fi
1214if test -z "$CC"; then
1215  # Extract the first word of "cc", so it can be a program name with args.
1216set dummy cc; ac_word=$2
1217echo "$as_me:1217: checking for $ac_word" >&5
1218echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1219if test "${ac_cv_prog_CC+set}" = set; then
1220  echo $ECHO_N "(cached) $ECHO_C" >&6
1221else
1222  if test -n "$CC"; then
1223  ac_cv_prog_CC="$CC" # Let the user override the test.
1224else
1225  ac_prog_rejected=no
1226  ac_save_IFS=$IFS; IFS=$ac_path_separator
1227ac_dummy="$PATH"
1228for ac_dir in $ac_dummy; do
1229  IFS=$ac_save_IFS
1230  test -z "$ac_dir" && ac_dir=.
1231  $as_executable_p "$ac_dir/$ac_word" || continue
1232if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
1233  ac_prog_rejected=yes
1234  continue
1235fi
1236ac_cv_prog_CC="cc"
1237echo "$as_me:1237: found $ac_dir/$ac_word" >&5
1238break
1239done
1240
1241if test $ac_prog_rejected = yes; then
1242  # We found a bogon in the path, so make sure we never use it.
1243  set dummy $ac_cv_prog_CC
1244  shift
1245  if test $# != 0; then
1246    # We chose a different compiler from the bogus one.
1247    # However, it has the same basename, so the bogon will be chosen
1248    # first if we set CC to just the basename; use the full file name.
1249    shift
1250    set dummy "$ac_dir/$ac_word" ${1+"$@"}
1251    shift
1252    ac_cv_prog_CC="$@"
1253  fi
1254fi
1255fi
1256fi
1257CC=$ac_cv_prog_CC
1258if test -n "$CC"; then
1259  echo "$as_me:1259: result: $CC" >&5
1260echo "${ECHO_T}$CC" >&6
1261else
1262  echo "$as_me:1262: result: no" >&5
1263echo "${ECHO_T}no" >&6
1264fi
1265
1266fi
1267if test -z "$CC"; then
1268  if test -n "$ac_tool_prefix"; then
1269  for ac_prog in cl
1270  do
1271    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
1272set dummy $ac_tool_prefix$ac_prog; ac_word=$2
1273echo "$as_me:1273: checking for $ac_word" >&5
1274echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1275if test "${ac_cv_prog_CC+set}" = set; then
1276  echo $ECHO_N "(cached) $ECHO_C" >&6
1277else
1278  if test -n "$CC"; then
1279  ac_cv_prog_CC="$CC" # Let the user override the test.
1280else
1281  ac_save_IFS=$IFS; IFS=$ac_path_separator
1282ac_dummy="$PATH"
1283for ac_dir in $ac_dummy; do
1284  IFS=$ac_save_IFS
1285  test -z "$ac_dir" && ac_dir=.
1286  $as_executable_p "$ac_dir/$ac_word" || continue
1287ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
1288echo "$as_me:1288: found $ac_dir/$ac_word" >&5
1289break
1290done
1291
1292fi
1293fi
1294CC=$ac_cv_prog_CC
1295if test -n "$CC"; then
1296  echo "$as_me:1296: result: $CC" >&5
1297echo "${ECHO_T}$CC" >&6
1298else
1299  echo "$as_me:1299: result: no" >&5
1300echo "${ECHO_T}no" >&6
1301fi
1302
1303    test -n "$CC" && break
1304  done
1305fi
1306if test -z "$CC"; then
1307  ac_ct_CC=$CC
1308  for ac_prog in cl
1309do
1310  # Extract the first word of "$ac_prog", so it can be a program name with args.
1311set dummy $ac_prog; ac_word=$2
1312echo "$as_me:1312: checking for $ac_word" >&5
1313echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1314if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1315  echo $ECHO_N "(cached) $ECHO_C" >&6
1316else
1317  if test -n "$ac_ct_CC"; then
1318  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1319else
1320  ac_save_IFS=$IFS; IFS=$ac_path_separator
1321ac_dummy="$PATH"
1322for ac_dir in $ac_dummy; do
1323  IFS=$ac_save_IFS
1324  test -z "$ac_dir" && ac_dir=.
1325  $as_executable_p "$ac_dir/$ac_word" || continue
1326ac_cv_prog_ac_ct_CC="$ac_prog"
1327echo "$as_me:1327: found $ac_dir/$ac_word" >&5
1328break
1329done
1330
1331fi
1332fi
1333ac_ct_CC=$ac_cv_prog_ac_ct_CC
1334if test -n "$ac_ct_CC"; then
1335  echo "$as_me:1335: result: $ac_ct_CC" >&5
1336echo "${ECHO_T}$ac_ct_CC" >&6
1337else
1338  echo "$as_me:1338: result: no" >&5
1339echo "${ECHO_T}no" >&6
1340fi
1341
1342  test -n "$ac_ct_CC" && break
1343done
1344
1345  CC=$ac_ct_CC
1346fi
1347
1348fi
1349
1350test -z "$CC" && { { echo "$as_me:1350: error: no acceptable cc found in \$PATH" >&5
1351echo "$as_me: error: no acceptable cc found in \$PATH" >&2;}
1352   { (exit 1); exit 1; }; }
1353
1354# Provide some information about the compiler.
1355echo "$as_me:1355:" \
1356     "checking for C compiler version" >&5
1357ac_compiler=`set X $ac_compile; echo $2`
1358{ (eval echo "$as_me:1358: \"$ac_compiler --version </dev/null >&5\"") >&5
1359  (eval $ac_compiler --version </dev/null >&5) 2>&5
1360  ac_status=$?
1361  echo "$as_me:1361: \$? = $ac_status" >&5
1362  (exit $ac_status); }
1363{ (eval echo "$as_me:1363: \"$ac_compiler -v </dev/null >&5\"") >&5
1364  (eval $ac_compiler -v </dev/null >&5) 2>&5
1365  ac_status=$?
1366  echo "$as_me:1366: \$? = $ac_status" >&5
1367  (exit $ac_status); }
1368{ (eval echo "$as_me:1368: \"$ac_compiler -V </dev/null >&5\"") >&5
1369  (eval $ac_compiler -V </dev/null >&5) 2>&5
1370  ac_status=$?
1371  echo "$as_me:1371: \$? = $ac_status" >&5
1372  (exit $ac_status); }
1373
1374cat >conftest.$ac_ext <<_ACEOF
1375#line 1375 "configure"
1376#include "confdefs.h"
1377
1378int
1379main (void)
1380{
1381
1382  ;
1383  return 0;
1384}
1385_ACEOF
1386ac_clean_files_save=$ac_clean_files
1387ac_clean_files="$ac_clean_files a.out a.exe"
1388# Try to create an executable without -o first, disregard a.out.
1389# It will help us diagnose broken compilers, and finding out an intuition
1390# of exeext.
1391echo "$as_me:1391: checking for C compiler default output" >&5
1392echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
1393ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
1394if { (eval echo "$as_me:1394: \"$ac_link_default\"") >&5
1395  (eval $ac_link_default) 2>&5
1396  ac_status=$?
1397  echo "$as_me:1397: \$? = $ac_status" >&5
1398  (exit $ac_status); }; then
1399  # Find the output, starting from the most likely.  This scheme is
1400# not robust to junk in `.', hence go to wildcards (a.*) only as a last
1401# resort.
1402for ac_file in `ls a.exe conftest.exe 2>/dev/null;
1403                ls a.out conftest 2>/dev/null;
1404                ls a.* conftest.* 2>/dev/null`; do
1405  case $ac_file in
1406    *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1407    a.out ) # We found the default executable, but exeext='' is most
1408            # certainly right.
1409            break;;
1410    *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1411          # FIXME: I believe we export ac_cv_exeext for Libtool --akim.
1412          export ac_cv_exeext
1413          break;;
1414    * ) break;;
1415  esac
1416done
1417else
1418  echo "$as_me: failed program was:" >&5
1419cat conftest.$ac_ext >&5
1420{ { echo "$as_me:1420: error: C compiler cannot create executables" >&5
1421echo "$as_me: error: C compiler cannot create executables" >&2;}
1422   { (exit 77); exit 77; }; }
1423fi
1424
1425ac_exeext=$ac_cv_exeext
1426echo "$as_me:1426: result: $ac_file" >&5
1427echo "${ECHO_T}$ac_file" >&6
1428
1429# Check the compiler produces executables we can run.  If not, either
1430# the compiler is broken, or we cross compile.
1431echo "$as_me:1431: checking whether the C compiler works" >&5
1432echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
1433# FIXME: These cross compiler hacks should be removed for Autoconf 3.0
1434# If not cross compiling, check that we can run a simple program.
1435if test "$cross_compiling" != yes; then
1436  if { ac_try='./$ac_file'
1437  { (eval echo "$as_me:1437: \"$ac_try\"") >&5
1438  (eval $ac_try) 2>&5
1439  ac_status=$?
1440  echo "$as_me:1440: \$? = $ac_status" >&5
1441  (exit $ac_status); }; }; then
1442    cross_compiling=no
1443  else
1444    if test "$cross_compiling" = maybe; then
1445	cross_compiling=yes
1446    else
1447	{ { echo "$as_me:1447: error: cannot run C compiled programs.
1448If you meant to cross compile, use \`--host'." >&5
1449echo "$as_me: error: cannot run C compiled programs.
1450If you meant to cross compile, use \`--host'." >&2;}
1451   { (exit 1); exit 1; }; }
1452    fi
1453  fi
1454fi
1455echo "$as_me:1455: result: yes" >&5
1456echo "${ECHO_T}yes" >&6
1457
1458rm -f a.out a.exe conftest$ac_cv_exeext
1459ac_clean_files=$ac_clean_files_save
1460# Check the compiler produces executables we can run.  If not, either
1461# the compiler is broken, or we cross compile.
1462echo "$as_me:1462: checking whether we are cross compiling" >&5
1463echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
1464echo "$as_me:1464: result: $cross_compiling" >&5
1465echo "${ECHO_T}$cross_compiling" >&6
1466
1467echo "$as_me:1467: checking for executable suffix" >&5
1468echo $ECHO_N "checking for executable suffix... $ECHO_C" >&6
1469if { (eval echo "$as_me:1469: \"$ac_link\"") >&5
1470  (eval $ac_link) 2>&5
1471  ac_status=$?
1472  echo "$as_me:1472: \$? = $ac_status" >&5
1473  (exit $ac_status); }; then
1474  # If both `conftest.exe' and `conftest' are `present' (well, observable)
1475# catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
1476# work properly (i.e., refer to `conftest.exe'), while it won't with
1477# `rm'.
1478for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do
1479  case $ac_file in
1480    *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1481    *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1482          export ac_cv_exeext
1483          break;;
1484    * ) break;;
1485  esac
1486done
1487else
1488  { { echo "$as_me:1488: error: cannot compute EXEEXT: cannot compile and link" >&5
1489echo "$as_me: error: cannot compute EXEEXT: cannot compile and link" >&2;}
1490   { (exit 1); exit 1; }; }
1491fi
1492
1493rm -f conftest$ac_cv_exeext
1494echo "$as_me:1494: result: $ac_cv_exeext" >&5
1495echo "${ECHO_T}$ac_cv_exeext" >&6
1496
1497rm -f conftest.$ac_ext
1498EXEEXT=$ac_cv_exeext
1499ac_exeext=$EXEEXT
1500echo "$as_me:1500: checking for object suffix" >&5
1501echo $ECHO_N "checking for object suffix... $ECHO_C" >&6
1502if test "${ac_cv_objext+set}" = set; then
1503  echo $ECHO_N "(cached) $ECHO_C" >&6
1504else
1505  cat >conftest.$ac_ext <<_ACEOF
1506#line 1506 "configure"
1507#include "confdefs.h"
1508
1509int
1510main (void)
1511{
1512
1513  ;
1514  return 0;
1515}
1516_ACEOF
1517rm -f conftest.o conftest.obj
1518if { (eval echo "$as_me:1518: \"$ac_compile\"") >&5
1519  (eval $ac_compile) 2>&5
1520  ac_status=$?
1521  echo "$as_me:1521: \$? = $ac_status" >&5
1522  (exit $ac_status); }; then
1523  for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
1524  case $ac_file in
1525    *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.map | *.inf ) ;;
1526    *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
1527       break;;
1528  esac
1529done
1530else
1531  echo "$as_me: failed program was:" >&5
1532cat conftest.$ac_ext >&5
1533{ { echo "$as_me:1533: error: cannot compute OBJEXT: cannot compile" >&5
1534echo "$as_me: error: cannot compute OBJEXT: cannot compile" >&2;}
1535   { (exit 1); exit 1; }; }
1536fi
1537
1538rm -f conftest.$ac_cv_objext conftest.$ac_ext
1539fi
1540echo "$as_me:1540: result: $ac_cv_objext" >&5
1541echo "${ECHO_T}$ac_cv_objext" >&6
1542OBJEXT=$ac_cv_objext
1543ac_objext=$OBJEXT
1544echo "$as_me:1544: checking whether we are using the GNU C compiler" >&5
1545echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
1546if test "${ac_cv_c_compiler_gnu+set}" = set; then
1547  echo $ECHO_N "(cached) $ECHO_C" >&6
1548else
1549  cat >conftest.$ac_ext <<_ACEOF
1550#line 1550 "configure"
1551#include "confdefs.h"
1552
1553int
1554main (void)
1555{
1556#ifndef __GNUC__
1557       choke me
1558#endif
1559
1560  ;
1561  return 0;
1562}
1563_ACEOF
1564rm -f conftest.$ac_objext
1565if { (eval echo "$as_me:1565: \"$ac_compile\"") >&5
1566  (eval $ac_compile) 2>&5
1567  ac_status=$?
1568  echo "$as_me:1568: \$? = $ac_status" >&5
1569  (exit $ac_status); } &&
1570         { ac_try='test -s conftest.$ac_objext'
1571  { (eval echo "$as_me:1571: \"$ac_try\"") >&5
1572  (eval $ac_try) 2>&5
1573  ac_status=$?
1574  echo "$as_me:1574: \$? = $ac_status" >&5
1575  (exit $ac_status); }; }; then
1576  ac_compiler_gnu=yes
1577else
1578  echo "$as_me: failed program was:" >&5
1579cat conftest.$ac_ext >&5
1580ac_compiler_gnu=no
1581fi
1582rm -f conftest.$ac_objext conftest.$ac_ext
1583ac_cv_c_compiler_gnu=$ac_compiler_gnu
1584
1585fi
1586echo "$as_me:1586: result: $ac_cv_c_compiler_gnu" >&5
1587echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
1588GCC=`test $ac_compiler_gnu = yes && echo yes`
1589ac_test_CFLAGS=${CFLAGS+set}
1590ac_save_CFLAGS=$CFLAGS
1591CFLAGS="-g"
1592echo "$as_me:1592: checking whether $CC accepts -g" >&5
1593echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
1594if test "${ac_cv_prog_cc_g+set}" = set; then
1595  echo $ECHO_N "(cached) $ECHO_C" >&6
1596else
1597  cat >conftest.$ac_ext <<_ACEOF
1598#line 1598 "configure"
1599#include "confdefs.h"
1600
1601int
1602main (void)
1603{
1604
1605  ;
1606  return 0;
1607}
1608_ACEOF
1609rm -f conftest.$ac_objext
1610if { (eval echo "$as_me:1610: \"$ac_compile\"") >&5
1611  (eval $ac_compile) 2>&5
1612  ac_status=$?
1613  echo "$as_me:1613: \$? = $ac_status" >&5
1614  (exit $ac_status); } &&
1615         { ac_try='test -s conftest.$ac_objext'
1616  { (eval echo "$as_me:1616: \"$ac_try\"") >&5
1617  (eval $ac_try) 2>&5
1618  ac_status=$?
1619  echo "$as_me:1619: \$? = $ac_status" >&5
1620  (exit $ac_status); }; }; then
1621  ac_cv_prog_cc_g=yes
1622else
1623  echo "$as_me: failed program was:" >&5
1624cat conftest.$ac_ext >&5
1625ac_cv_prog_cc_g=no
1626fi
1627rm -f conftest.$ac_objext conftest.$ac_ext
1628fi
1629echo "$as_me:1629: result: $ac_cv_prog_cc_g" >&5
1630echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
1631if test "$ac_test_CFLAGS" = set; then
1632  CFLAGS=$ac_save_CFLAGS
1633elif test $ac_cv_prog_cc_g = yes; then
1634  if test "$GCC" = yes; then
1635    CFLAGS="-g -O2"
1636  else
1637    CFLAGS="-g"
1638  fi
1639else
1640  if test "$GCC" = yes; then
1641    CFLAGS="-O2"
1642  else
1643    CFLAGS=
1644  fi
1645fi
1646# Some people use a C++ compiler to compile C.  Since we use `exit',
1647# in C++ we need to declare it.  In case someone uses the same compiler
1648# for both compiling C and C++ we need to have the C++ compiler decide
1649# the declaration of exit, since it's the most demanding environment.
1650cat >conftest.$ac_ext <<_ACEOF
1651#ifndef __cplusplus
1652  choke me
1653#endif
1654_ACEOF
1655rm -f conftest.$ac_objext
1656if { (eval echo "$as_me:1656: \"$ac_compile\"") >&5
1657  (eval $ac_compile) 2>&5
1658  ac_status=$?
1659  echo "$as_me:1659: \$? = $ac_status" >&5
1660  (exit $ac_status); } &&
1661         { ac_try='test -s conftest.$ac_objext'
1662  { (eval echo "$as_me:1662: \"$ac_try\"") >&5
1663  (eval $ac_try) 2>&5
1664  ac_status=$?
1665  echo "$as_me:1665: \$? = $ac_status" >&5
1666  (exit $ac_status); }; }; then
1667  for ac_declaration in \
1668   ''\
1669   '#include <stdlib.h>' \
1670   'extern "C" void std::exit (int) throw (); using std::exit;' \
1671   'extern "C" void std::exit (int); using std::exit;' \
1672   'extern "C" void exit (int) throw ();' \
1673   'extern "C" void exit (int);' \
1674   'void exit (int);'
1675do
1676  cat >conftest.$ac_ext <<_ACEOF
1677#line 1677 "configure"
1678#include "confdefs.h"
1679#include <stdlib.h>
1680$ac_declaration
1681int
1682main (void)
1683{
1684exit (42);
1685  ;
1686  return 0;
1687}
1688_ACEOF
1689rm -f conftest.$ac_objext
1690if { (eval echo "$as_me:1690: \"$ac_compile\"") >&5
1691  (eval $ac_compile) 2>&5
1692  ac_status=$?
1693  echo "$as_me:1693: \$? = $ac_status" >&5
1694  (exit $ac_status); } &&
1695         { ac_try='test -s conftest.$ac_objext'
1696  { (eval echo "$as_me:1696: \"$ac_try\"") >&5
1697  (eval $ac_try) 2>&5
1698  ac_status=$?
1699  echo "$as_me:1699: \$? = $ac_status" >&5
1700  (exit $ac_status); }; }; then
1701  :
1702else
1703  echo "$as_me: failed program was:" >&5
1704cat conftest.$ac_ext >&5
1705continue
1706fi
1707rm -f conftest.$ac_objext conftest.$ac_ext
1708  cat >conftest.$ac_ext <<_ACEOF
1709#line 1709 "configure"
1710#include "confdefs.h"
1711$ac_declaration
1712int
1713main (void)
1714{
1715exit (42);
1716  ;
1717  return 0;
1718}
1719_ACEOF
1720rm -f conftest.$ac_objext
1721if { (eval echo "$as_me:1721: \"$ac_compile\"") >&5
1722  (eval $ac_compile) 2>&5
1723  ac_status=$?
1724  echo "$as_me:1724: \$? = $ac_status" >&5
1725  (exit $ac_status); } &&
1726         { ac_try='test -s conftest.$ac_objext'
1727  { (eval echo "$as_me:1727: \"$ac_try\"") >&5
1728  (eval $ac_try) 2>&5
1729  ac_status=$?
1730  echo "$as_me:1730: \$? = $ac_status" >&5
1731  (exit $ac_status); }; }; then
1732  break
1733else
1734  echo "$as_me: failed program was:" >&5
1735cat conftest.$ac_ext >&5
1736fi
1737rm -f conftest.$ac_objext conftest.$ac_ext
1738done
1739rm -rf conftest*
1740if test -n "$ac_declaration"; then
1741  echo '#ifdef __cplusplus' >>confdefs.h
1742  echo $ac_declaration      >>confdefs.h
1743  echo '#endif'             >>confdefs.h
1744fi
1745
1746else
1747  echo "$as_me: failed program was:" >&5
1748cat conftest.$ac_ext >&5
1749fi
1750rm -f conftest.$ac_objext conftest.$ac_ext
1751ac_ext=c
1752ac_cpp='$CPP $CPPFLAGS'
1753ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1754ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1755ac_compiler_gnu=$ac_cv_c_compiler_gnu
1756ac_main_return=return
1757
1758GCC_VERSION=none
1759if test "$GCC" = yes ; then
1760	echo "$as_me:1760: checking version of $CC" >&5
1761echo $ECHO_N "checking version of $CC... $ECHO_C" >&6
1762	GCC_VERSION="`${CC} --version 2>/dev/null | sed -e '2,$d' -e 's/^.*(GCC[^)]*) //' -e 's/^.*(Debian[^)]*) //' -e 's/^[^0-9.]*//' -e 's/[^0-9.].*//'`"
1763	test -z "$GCC_VERSION" && GCC_VERSION=unknown
1764	echo "$as_me:1764: result: $GCC_VERSION" >&5
1765echo "${ECHO_T}$GCC_VERSION" >&6
1766fi
1767
1768echo "$as_me:1768: checking for $CC option to accept ANSI C" >&5
1769echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
1770if test "${ac_cv_prog_cc_stdc+set}" = set; then
1771  echo $ECHO_N "(cached) $ECHO_C" >&6
1772else
1773  ac_cv_prog_cc_stdc=no
1774ac_save_CC=$CC
1775cat >conftest.$ac_ext <<_ACEOF
1776#line 1776 "configure"
1777#include "confdefs.h"
1778#include <stdarg.h>
1779#include <stdio.h>
1780#include <sys/types.h>
1781#include <sys/stat.h>
1782/* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
1783struct buf { int x; };
1784FILE * (*rcsopen) (struct buf *, struct stat *, int);
1785static char *e (p, i)
1786     char **p;
1787     int i;
1788{
1789  return p[i];
1790}
1791static char *f (char * (*g) (char **, int), char **p, ...)
1792{
1793  char *s;
1794  va_list v;
1795  va_start (v,p);
1796  s = g (p, va_arg (v,int));
1797  va_end (v);
1798  return s;
1799}
1800int test (int i, double x);
1801struct s1 {int (*f) (int a);};
1802struct s2 {int (*f) (double a);};
1803int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
1804int argc;
1805char **argv;
1806int
1807main (void)
1808{
1809return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
1810  ;
1811  return 0;
1812}
1813_ACEOF
1814# Don't try gcc -ansi; that turns off useful extensions and
1815# breaks some systems' header files.
1816# AIX			-qlanglvl=ansi
1817# Ultrix and OSF/1	-std1
1818# HP-UX 10.20 and later	-Ae
1819# HP-UX older versions	-Aa -D_HPUX_SOURCE
1820# SVR4			-Xc -D__EXTENSIONS__
1821for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
1822do
1823  CC="$ac_save_CC $ac_arg"
1824  rm -f conftest.$ac_objext
1825if { (eval echo "$as_me:1825: \"$ac_compile\"") >&5
1826  (eval $ac_compile) 2>&5
1827  ac_status=$?
1828  echo "$as_me:1828: \$? = $ac_status" >&5
1829  (exit $ac_status); } &&
1830         { ac_try='test -s conftest.$ac_objext'
1831  { (eval echo "$as_me:1831: \"$ac_try\"") >&5
1832  (eval $ac_try) 2>&5
1833  ac_status=$?
1834  echo "$as_me:1834: \$? = $ac_status" >&5
1835  (exit $ac_status); }; }; then
1836  ac_cv_prog_cc_stdc=$ac_arg
1837break
1838else
1839  echo "$as_me: failed program was:" >&5
1840cat conftest.$ac_ext >&5
1841fi
1842rm -f conftest.$ac_objext
1843done
1844rm -f conftest.$ac_ext conftest.$ac_objext
1845CC=$ac_save_CC
1846
1847fi
1848
1849case "x$ac_cv_prog_cc_stdc" in
1850  x|xno)
1851    echo "$as_me:1851: result: none needed" >&5
1852echo "${ECHO_T}none needed" >&6 ;;
1853  *)
1854    echo "$as_me:1854: result: $ac_cv_prog_cc_stdc" >&5
1855echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
1856    CC="$CC $ac_cv_prog_cc_stdc" ;;
1857esac
1858
1859# This should have been defined by AC_PROG_CC
1860: ${CC:=cc}
1861
1862echo "$as_me:1862: checking \$CC variable" >&5
1863echo $ECHO_N "checking \$CC variable... $ECHO_C" >&6
1864case "$CC" in
1865(*[\ \	]-*)
1866	echo "$as_me:1866: result: broken" >&5
1867echo "${ECHO_T}broken" >&6
1868	{ echo "$as_me:1868: WARNING: your environment misuses the CC variable to hold CFLAGS/CPPFLAGS options" >&5
1869echo "$as_me: WARNING: your environment misuses the CC variable to hold CFLAGS/CPPFLAGS options" >&2;}
1870	# humor him...
1871	cf_prog=`echo "$CC" | sed -e 's/	/ /g' -e 's/[ ]* / /g' -e 's/[ ]*[ ]-[^ ].*//'`
1872	cf_flags=`echo "$CC" | ${AWK:-awk} -v prog="$cf_prog" '{ printf("%s", substr($0,1+length(prog))); }'`
1873	CC="$cf_prog"
1874	for cf_arg in $cf_flags
1875	do
1876		case "x$cf_arg" in
1877		(x-[IUDfgOW]*)
1878
1879cf_fix_cppflags=no
1880cf_new_cflags=
1881cf_new_cppflags=
1882cf_new_extra_cppflags=
1883
1884for cf_add_cflags in $cf_arg
1885do
1886case $cf_fix_cppflags in
1887(no)
1888	case $cf_add_cflags in
1889	(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
1890		case $cf_add_cflags in
1891		(-D*)
1892			cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
1893
1894			test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
1895				&& test -z "${cf_tst_cflags}" \
1896				&& cf_fix_cppflags=yes
1897
1898			if test $cf_fix_cppflags = yes ; then
1899
1900	test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
1901	cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
1902
1903				continue
1904			elif test "${cf_tst_cflags}" = "\"'" ; then
1905
1906	test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
1907	cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
1908
1909				continue
1910			fi
1911			;;
1912		esac
1913		case "$CPPFLAGS" in
1914		(*$cf_add_cflags)
1915			;;
1916		(*)
1917			case $cf_add_cflags in
1918			(-D*)
1919				cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
1920
1921CPPFLAGS=`echo "$CPPFLAGS" | \
1922	sed	-e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ 	]*\)\?[ 	]/ /g' \
1923		-e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ 	]*\)\?$//g'`
1924
1925				;;
1926			esac
1927
1928	test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
1929	cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
1930
1931			;;
1932		esac
1933		;;
1934	(*)
1935
1936	test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
1937	cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
1938
1939		;;
1940	esac
1941	;;
1942(yes)
1943
1944	test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
1945	cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
1946
1947	cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
1948
1949	test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
1950		&& test -z "${cf_tst_cflags}" \
1951		&& cf_fix_cppflags=no
1952	;;
1953esac
1954done
1955
1956if test -n "$cf_new_cflags" ; then
1957
1958	test -n "$CFLAGS" && CFLAGS="$CFLAGS "
1959	CFLAGS="${CFLAGS}$cf_new_cflags"
1960
1961fi
1962
1963if test -n "$cf_new_cppflags" ; then
1964
1965	test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
1966	CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
1967
1968fi
1969
1970if test -n "$cf_new_extra_cppflags" ; then
1971
1972	test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
1973	EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
1974
1975fi
1976
1977			;;
1978		(*)
1979			CC="$CC $cf_arg"
1980			;;
1981		esac
1982	done
1983	test -n "$verbose" && echo "	resulting CC: '$CC'" 1>&6
1984
1985echo "${as_me:-configure}:1985: testing resulting CC: '$CC' ..." 1>&5
1986
1987	test -n "$verbose" && echo "	resulting CFLAGS: '$CFLAGS'" 1>&6
1988
1989echo "${as_me:-configure}:1989: testing resulting CFLAGS: '$CFLAGS' ..." 1>&5
1990
1991	test -n "$verbose" && echo "	resulting CPPFLAGS: '$CPPFLAGS'" 1>&6
1992
1993echo "${as_me:-configure}:1993: testing resulting CPPFLAGS: '$CPPFLAGS' ..." 1>&5
1994
1995	;;
1996(*)
1997	echo "$as_me:1997: result: ok" >&5
1998echo "${ECHO_T}ok" >&6
1999	;;
2000esac
2001
2002ac_ext=c
2003ac_cpp='$CPP $CPPFLAGS'
2004ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2005ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2006ac_compiler_gnu=$ac_cv_c_compiler_gnu
2007ac_main_return=return
2008echo "$as_me:2008: checking how to run the C preprocessor" >&5
2009echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
2010# On Suns, sometimes $CPP names a directory.
2011if test -n "$CPP" && test -d "$CPP"; then
2012  CPP=
2013fi
2014if test -z "$CPP"; then
2015  if test "${ac_cv_prog_CPP+set}" = set; then
2016  echo $ECHO_N "(cached) $ECHO_C" >&6
2017else
2018      # Double quotes because CPP needs to be expanded
2019    for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
2020    do
2021      ac_preproc_ok=false
2022for ac_c_preproc_warn_flag in '' yes
2023do
2024  # Use a header file that comes with gcc, so configuring glibc
2025  # with a fresh cross-compiler works.
2026  # On the NeXT, cc -E runs the code through the compiler's parser,
2027  # not just through cpp. "Syntax error" is here to catch this case.
2028  cat >conftest.$ac_ext <<_ACEOF
2029#line 2029 "configure"
2030#include "confdefs.h"
2031#include <assert.h>
2032                     Syntax error
2033_ACEOF
2034if { (eval echo "$as_me:2034: \"$ac_cpp conftest.$ac_ext\"") >&5
2035  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2036  ac_status=$?
2037  egrep -v '^ *\+' conftest.er1 >conftest.err
2038  rm -f conftest.er1
2039  cat conftest.err >&5
2040  echo "$as_me:2040: \$? = $ac_status" >&5
2041  (exit $ac_status); } >/dev/null; then
2042  if test -s conftest.err; then
2043    ac_cpp_err=$ac_c_preproc_warn_flag
2044  else
2045    ac_cpp_err=
2046  fi
2047else
2048  ac_cpp_err=yes
2049fi
2050if test -z "$ac_cpp_err"; then
2051  :
2052else
2053  echo "$as_me: failed program was:" >&5
2054  cat conftest.$ac_ext >&5
2055  # Broken: fails on valid input.
2056continue
2057fi
2058rm -f conftest.err conftest.$ac_ext
2059
2060  # OK, works on sane cases.  Now check whether non-existent headers
2061  # can be detected and how.
2062  cat >conftest.$ac_ext <<_ACEOF
2063#line 2063 "configure"
2064#include "confdefs.h"
2065#include <ac_nonexistent.h>
2066_ACEOF
2067if { (eval echo "$as_me:2067: \"$ac_cpp conftest.$ac_ext\"") >&5
2068  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2069  ac_status=$?
2070  egrep -v '^ *\+' conftest.er1 >conftest.err
2071  rm -f conftest.er1
2072  cat conftest.err >&5
2073  echo "$as_me:2073: \$? = $ac_status" >&5
2074  (exit $ac_status); } >/dev/null; then
2075  if test -s conftest.err; then
2076    ac_cpp_err=$ac_c_preproc_warn_flag
2077  else
2078    ac_cpp_err=
2079  fi
2080else
2081  ac_cpp_err=yes
2082fi
2083if test -z "$ac_cpp_err"; then
2084  # Broken: success on invalid input.
2085continue
2086else
2087  echo "$as_me: failed program was:" >&5
2088  cat conftest.$ac_ext >&5
2089  # Passes both tests.
2090ac_preproc_ok=:
2091break
2092fi
2093rm -f conftest.err conftest.$ac_ext
2094
2095done
2096# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2097rm -f conftest.err conftest.$ac_ext
2098if $ac_preproc_ok; then
2099  break
2100fi
2101
2102    done
2103    ac_cv_prog_CPP=$CPP
2104
2105fi
2106  CPP=$ac_cv_prog_CPP
2107else
2108  ac_cv_prog_CPP=$CPP
2109fi
2110echo "$as_me:2110: result: $CPP" >&5
2111echo "${ECHO_T}$CPP" >&6
2112ac_preproc_ok=false
2113for ac_c_preproc_warn_flag in '' yes
2114do
2115  # Use a header file that comes with gcc, so configuring glibc
2116  # with a fresh cross-compiler works.
2117  # On the NeXT, cc -E runs the code through the compiler's parser,
2118  # not just through cpp. "Syntax error" is here to catch this case.
2119  cat >conftest.$ac_ext <<_ACEOF
2120#line 2120 "configure"
2121#include "confdefs.h"
2122#include <assert.h>
2123                     Syntax error
2124_ACEOF
2125if { (eval echo "$as_me:2125: \"$ac_cpp conftest.$ac_ext\"") >&5
2126  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2127  ac_status=$?
2128  egrep -v '^ *\+' conftest.er1 >conftest.err
2129  rm -f conftest.er1
2130  cat conftest.err >&5
2131  echo "$as_me:2131: \$? = $ac_status" >&5
2132  (exit $ac_status); } >/dev/null; then
2133  if test -s conftest.err; then
2134    ac_cpp_err=$ac_c_preproc_warn_flag
2135  else
2136    ac_cpp_err=
2137  fi
2138else
2139  ac_cpp_err=yes
2140fi
2141if test -z "$ac_cpp_err"; then
2142  :
2143else
2144  echo "$as_me: failed program was:" >&5
2145  cat conftest.$ac_ext >&5
2146  # Broken: fails on valid input.
2147continue
2148fi
2149rm -f conftest.err conftest.$ac_ext
2150
2151  # OK, works on sane cases.  Now check whether non-existent headers
2152  # can be detected and how.
2153  cat >conftest.$ac_ext <<_ACEOF
2154#line 2154 "configure"
2155#include "confdefs.h"
2156#include <ac_nonexistent.h>
2157_ACEOF
2158if { (eval echo "$as_me:2158: \"$ac_cpp conftest.$ac_ext\"") >&5
2159  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2160  ac_status=$?
2161  egrep -v '^ *\+' conftest.er1 >conftest.err
2162  rm -f conftest.er1
2163  cat conftest.err >&5
2164  echo "$as_me:2164: \$? = $ac_status" >&5
2165  (exit $ac_status); } >/dev/null; then
2166  if test -s conftest.err; then
2167    ac_cpp_err=$ac_c_preproc_warn_flag
2168  else
2169    ac_cpp_err=
2170  fi
2171else
2172  ac_cpp_err=yes
2173fi
2174if test -z "$ac_cpp_err"; then
2175  # Broken: success on invalid input.
2176continue
2177else
2178  echo "$as_me: failed program was:" >&5
2179  cat conftest.$ac_ext >&5
2180  # Passes both tests.
2181ac_preproc_ok=:
2182break
2183fi
2184rm -f conftest.err conftest.$ac_ext
2185
2186done
2187# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2188rm -f conftest.err conftest.$ac_ext
2189if $ac_preproc_ok; then
2190  :
2191else
2192  { { echo "$as_me:2192: error: C preprocessor \"$CPP\" fails sanity check" >&5
2193echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;}
2194   { (exit 1); exit 1; }; }
2195fi
2196
2197ac_ext=c
2198ac_cpp='$CPP $CPPFLAGS'
2199ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2200ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2201ac_compiler_gnu=$ac_cv_c_compiler_gnu
2202ac_main_return=return
2203
2204echo "$as_me:2204: checking whether ${MAKE-make} sets \${MAKE}" >&5
2205echo $ECHO_N "checking whether ${MAKE-make} sets \${MAKE}... $ECHO_C" >&6
2206set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,./+-,__p_,'`
2207if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
2208  echo $ECHO_N "(cached) $ECHO_C" >&6
2209else
2210  cat >conftest.make <<\EOF
2211all:
2212	@echo 'ac_maketemp="${MAKE}"'
2213EOF
2214# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
2215eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
2216if test -n "$ac_maketemp"; then
2217  eval ac_cv_prog_make_${ac_make}_set=yes
2218else
2219  eval ac_cv_prog_make_${ac_make}_set=no
2220fi
2221rm -f conftest.make
2222fi
2223if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
2224  echo "$as_me:2224: result: yes" >&5
2225echo "${ECHO_T}yes" >&6
2226  SET_MAKE=
2227else
2228  echo "$as_me:2228: result: no" >&5
2229echo "${ECHO_T}no" >&6
2230  SET_MAKE="MAKE=${MAKE-make}"
2231fi
2232
2233if test -n "$ac_tool_prefix"; then
2234  # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
2235set dummy ${ac_tool_prefix}ranlib; ac_word=$2
2236echo "$as_me:2236: checking for $ac_word" >&5
2237echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2238if test "${ac_cv_prog_RANLIB+set}" = set; then
2239  echo $ECHO_N "(cached) $ECHO_C" >&6
2240else
2241  if test -n "$RANLIB"; then
2242  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
2243else
2244  ac_save_IFS=$IFS; IFS=$ac_path_separator
2245ac_dummy="$PATH"
2246for ac_dir in $ac_dummy; do
2247  IFS=$ac_save_IFS
2248  test -z "$ac_dir" && ac_dir=.
2249  $as_executable_p "$ac_dir/$ac_word" || continue
2250ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
2251echo "$as_me:2251: found $ac_dir/$ac_word" >&5
2252break
2253done
2254
2255fi
2256fi
2257RANLIB=$ac_cv_prog_RANLIB
2258if test -n "$RANLIB"; then
2259  echo "$as_me:2259: result: $RANLIB" >&5
2260echo "${ECHO_T}$RANLIB" >&6
2261else
2262  echo "$as_me:2262: result: no" >&5
2263echo "${ECHO_T}no" >&6
2264fi
2265
2266fi
2267if test -z "$ac_cv_prog_RANLIB"; then
2268  ac_ct_RANLIB=$RANLIB
2269  # Extract the first word of "ranlib", so it can be a program name with args.
2270set dummy ranlib; ac_word=$2
2271echo "$as_me:2271: checking for $ac_word" >&5
2272echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2273if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
2274  echo $ECHO_N "(cached) $ECHO_C" >&6
2275else
2276  if test -n "$ac_ct_RANLIB"; then
2277  ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
2278else
2279  ac_save_IFS=$IFS; IFS=$ac_path_separator
2280ac_dummy="$PATH"
2281for ac_dir in $ac_dummy; do
2282  IFS=$ac_save_IFS
2283  test -z "$ac_dir" && ac_dir=.
2284  $as_executable_p "$ac_dir/$ac_word" || continue
2285ac_cv_prog_ac_ct_RANLIB="ranlib"
2286echo "$as_me:2286: found $ac_dir/$ac_word" >&5
2287break
2288done
2289
2290  test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
2291fi
2292fi
2293ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
2294if test -n "$ac_ct_RANLIB"; then
2295  echo "$as_me:2295: result: $ac_ct_RANLIB" >&5
2296echo "${ECHO_T}$ac_ct_RANLIB" >&6
2297else
2298  echo "$as_me:2298: result: no" >&5
2299echo "${ECHO_T}no" >&6
2300fi
2301
2302  RANLIB=$ac_ct_RANLIB
2303else
2304  RANLIB="$ac_cv_prog_RANLIB"
2305fi
2306
2307ac_aux_dir=
2308for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
2309  if test -f $ac_dir/install-sh; then
2310    ac_aux_dir=$ac_dir
2311    ac_install_sh="$ac_aux_dir/install-sh -c"
2312    break
2313  elif test -f $ac_dir/install.sh; then
2314    ac_aux_dir=$ac_dir
2315    ac_install_sh="$ac_aux_dir/install.sh -c"
2316    break
2317  elif test -f $ac_dir/shtool; then
2318    ac_aux_dir=$ac_dir
2319    ac_install_sh="$ac_aux_dir/shtool install -c"
2320    break
2321  fi
2322done
2323if test -z "$ac_aux_dir"; then
2324  { { echo "$as_me:2324: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
2325echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
2326   { (exit 1); exit 1; }; }
2327fi
2328ac_config_guess="$SHELL $ac_aux_dir/config.guess"
2329ac_config_sub="$SHELL $ac_aux_dir/config.sub"
2330ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
2331
2332# Find a good install program.  We prefer a C program (faster),
2333# so one script is as good as another.  But avoid the broken or
2334# incompatible versions:
2335# SysV /etc/install, /usr/sbin/install
2336# SunOS /usr/etc/install
2337# IRIX /sbin/install
2338# AIX /bin/install
2339# AmigaOS /C/install, which installs bootblocks on floppy discs
2340# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
2341# AFS /usr/afsws/bin/install, which mishandles nonexistent args
2342# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
2343# ./install, which can be erroneously created by make from ./install.sh.
2344echo "$as_me:2344: checking for a BSD compatible install" >&5
2345echo $ECHO_N "checking for a BSD compatible install... $ECHO_C" >&6
2346if test -z "$INSTALL"; then
2347if test "${ac_cv_path_install+set}" = set; then
2348  echo $ECHO_N "(cached) $ECHO_C" >&6
2349else
2350    ac_save_IFS=$IFS; IFS=$ac_path_separator
2351  for ac_dir in $PATH; do
2352    IFS=$ac_save_IFS
2353    # Account for people who put trailing slashes in PATH elements.
2354    case $ac_dir/ in
2355    / | ./ | .// | /cC/* \
2356    | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* \
2357    | /usr/ucb/* ) ;;
2358    *)
2359      # OSF1 and SCO ODT 3.0 have their own names for install.
2360      # Don't use installbsd from OSF since it installs stuff as root
2361      # by default.
2362      for ac_prog in ginstall scoinst install; do
2363        if $as_executable_p "$ac_dir/$ac_prog"; then
2364	  if test $ac_prog = install &&
2365            grep dspmsg "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2366	    # AIX install.  It has an incompatible calling convention.
2367	    :
2368	  elif test $ac_prog = install &&
2369	    grep pwplus "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2370	    # program-specific install script used by HP pwplus--don't use.
2371	    :
2372	  else
2373	    ac_cv_path_install="$ac_dir/$ac_prog -c"
2374	    break 2
2375	  fi
2376	fi
2377      done
2378      ;;
2379    esac
2380  done
2381
2382fi
2383  if test "${ac_cv_path_install+set}" = set; then
2384    INSTALL=$ac_cv_path_install
2385  else
2386    # As a last resort, use the slow shell script.  We don't cache a
2387    # path for INSTALL within a source directory, because that will
2388    # break other packages using the cache if that directory is
2389    # removed, or if the path is relative.
2390    INSTALL=$ac_install_sh
2391  fi
2392fi
2393echo "$as_me:2393: result: $INSTALL" >&5
2394echo "${ECHO_T}$INSTALL" >&6
2395
2396# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
2397# It thinks the first close brace ends the variable substitution.
2398test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
2399
2400test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
2401
2402test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
2403
2404echo "$as_me:2404: checking whether ln -s works" >&5
2405echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
2406LN_S=$as_ln_s
2407if test "$LN_S" = "ln -s"; then
2408  echo "$as_me:2408: result: yes" >&5
2409echo "${ECHO_T}yes" >&6
2410else
2411  echo "$as_me:2411: result: no, using $LN_S" >&5
2412echo "${ECHO_T}no, using $LN_S" >&6
2413fi
2414
2415echo "$as_me:2415: checking if $LN_S -f options work" >&5
2416echo $ECHO_N "checking if $LN_S -f options work... $ECHO_C" >&6
2417
2418rm -f conf$$.src conf$$dst
2419echo >conf$$.dst
2420echo first >conf$$.src
2421if $LN_S -f conf$$.src conf$$.dst 2>/dev/null; then
2422	cf_prog_ln_sf=yes
2423else
2424	cf_prog_ln_sf=no
2425fi
2426rm -f conf$$.dst conf$$src
2427echo "$as_me:2427: result: $cf_prog_ln_sf" >&5
2428echo "${ECHO_T}$cf_prog_ln_sf" >&6
2429
2430test "$cf_prog_ln_sf" = yes && LN_S="$LN_S -f"
2431
2432for ac_prog in lint cppcheck splint
2433do
2434  # Extract the first word of "$ac_prog", so it can be a program name with args.
2435set dummy $ac_prog; ac_word=$2
2436echo "$as_me:2436: checking for $ac_word" >&5
2437echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2438if test "${ac_cv_prog_LINT+set}" = set; then
2439  echo $ECHO_N "(cached) $ECHO_C" >&6
2440else
2441  if test -n "$LINT"; then
2442  ac_cv_prog_LINT="$LINT" # Let the user override the test.
2443else
2444  ac_save_IFS=$IFS; IFS=$ac_path_separator
2445ac_dummy="$PATH"
2446for ac_dir in $ac_dummy; do
2447  IFS=$ac_save_IFS
2448  test -z "$ac_dir" && ac_dir=.
2449  $as_executable_p "$ac_dir/$ac_word" || continue
2450ac_cv_prog_LINT="$ac_prog"
2451echo "$as_me:2451: found $ac_dir/$ac_word" >&5
2452break
2453done
2454
2455fi
2456fi
2457LINT=$ac_cv_prog_LINT
2458if test -n "$LINT"; then
2459  echo "$as_me:2459: result: $LINT" >&5
2460echo "${ECHO_T}$LINT" >&6
2461else
2462  echo "$as_me:2462: result: no" >&5
2463echo "${ECHO_T}no" >&6
2464fi
2465
2466  test -n "$LINT" && break
2467done
2468
2469# Extract the first word of "groff", so it can be a program name with args.
2470set dummy groff; ac_word=$2
2471echo "$as_me:2471: checking for $ac_word" >&5
2472echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2473if test "${ac_cv_path_GROFF_PATH+set}" = set; then
2474  echo $ECHO_N "(cached) $ECHO_C" >&6
2475else
2476  case $GROFF_PATH in
2477  [\\/]* | ?:[\\/]*)
2478  ac_cv_path_GROFF_PATH="$GROFF_PATH" # Let the user override the test with a path.
2479  ;;
2480  *)
2481  ac_save_IFS=$IFS; IFS=$ac_path_separator
2482ac_dummy="$PATH"
2483for ac_dir in $ac_dummy; do
2484  IFS=$ac_save_IFS
2485  test -z "$ac_dir" && ac_dir=.
2486  if $as_executable_p "$ac_dir/$ac_word"; then
2487   ac_cv_path_GROFF_PATH="$ac_dir/$ac_word"
2488   echo "$as_me:2488: found $ac_dir/$ac_word" >&5
2489   break
2490fi
2491done
2492
2493  test -z "$ac_cv_path_GROFF_PATH" && ac_cv_path_GROFF_PATH="no"
2494  ;;
2495esac
2496fi
2497GROFF_PATH=$ac_cv_path_GROFF_PATH
2498
2499if test -n "$GROFF_PATH"; then
2500  echo "$as_me:2500: result: $GROFF_PATH" >&5
2501echo "${ECHO_T}$GROFF_PATH" >&6
2502else
2503  echo "$as_me:2503: result: no" >&5
2504echo "${ECHO_T}no" >&6
2505fi
2506
2507for ac_prog in nroff mandoc
2508do
2509  # Extract the first word of "$ac_prog", so it can be a program name with args.
2510set dummy $ac_prog; ac_word=$2
2511echo "$as_me:2511: checking for $ac_word" >&5
2512echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2513if test "${ac_cv_path_NROFF_PATH+set}" = set; then
2514  echo $ECHO_N "(cached) $ECHO_C" >&6
2515else
2516  case $NROFF_PATH in
2517  [\\/]* | ?:[\\/]*)
2518  ac_cv_path_NROFF_PATH="$NROFF_PATH" # Let the user override the test with a path.
2519  ;;
2520  *)
2521  ac_save_IFS=$IFS; IFS=$ac_path_separator
2522ac_dummy="$PATH"
2523for ac_dir in $ac_dummy; do
2524  IFS=$ac_save_IFS
2525  test -z "$ac_dir" && ac_dir=.
2526  if $as_executable_p "$ac_dir/$ac_word"; then
2527   ac_cv_path_NROFF_PATH="$ac_dir/$ac_word"
2528   echo "$as_me:2528: found $ac_dir/$ac_word" >&5
2529   break
2530fi
2531done
2532
2533  ;;
2534esac
2535fi
2536NROFF_PATH=$ac_cv_path_NROFF_PATH
2537
2538if test -n "$NROFF_PATH"; then
2539  echo "$as_me:2539: result: $NROFF_PATH" >&5
2540echo "${ECHO_T}$NROFF_PATH" >&6
2541else
2542  echo "$as_me:2542: result: no" >&5
2543echo "${ECHO_T}no" >&6
2544fi
2545
2546  test -n "$NROFF_PATH" && break
2547done
2548test -n "$NROFF_PATH" || NROFF_PATH="no"
2549
2550# Extract the first word of "tbl", so it can be a program name with args.
2551set dummy tbl; ac_word=$2
2552echo "$as_me:2552: checking for $ac_word" >&5
2553echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2554if test "${ac_cv_path_TBL_PATH+set}" = set; then
2555  echo $ECHO_N "(cached) $ECHO_C" >&6
2556else
2557  case $TBL_PATH in
2558  [\\/]* | ?:[\\/]*)
2559  ac_cv_path_TBL_PATH="$TBL_PATH" # Let the user override the test with a path.
2560  ;;
2561  *)
2562  ac_save_IFS=$IFS; IFS=$ac_path_separator
2563ac_dummy="$PATH"
2564for ac_dir in $ac_dummy; do
2565  IFS=$ac_save_IFS
2566  test -z "$ac_dir" && ac_dir=.
2567  if $as_executable_p "$ac_dir/$ac_word"; then
2568   ac_cv_path_TBL_PATH="$ac_dir/$ac_word"
2569   echo "$as_me:2569: found $ac_dir/$ac_word" >&5
2570   break
2571fi
2572done
2573
2574  test -z "$ac_cv_path_TBL_PATH" && ac_cv_path_TBL_PATH="cat"
2575  ;;
2576esac
2577fi
2578TBL_PATH=$ac_cv_path_TBL_PATH
2579
2580if test -n "$TBL_PATH"; then
2581  echo "$as_me:2581: result: $TBL_PATH" >&5
2582echo "${ECHO_T}$TBL_PATH" >&6
2583else
2584  echo "$as_me:2584: result: no" >&5
2585echo "${ECHO_T}no" >&6
2586fi
2587
2588if test "x$GROFF_PATH" = xno
2589then
2590	NROFF_NOTE=
2591	GROFF_NOTE="#"
2592else
2593	NROFF_NOTE="#"
2594	GROFF_NOTE=
2595fi
2596
2597test -z "$GROFF_NOTE" && NROFF_NOTE=
2598
2599if test -n "$ac_tool_prefix"; then
2600  # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
2601set dummy ${ac_tool_prefix}ar; ac_word=$2
2602echo "$as_me:2602: checking for $ac_word" >&5
2603echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2604if test "${ac_cv_prog_AR+set}" = set; then
2605  echo $ECHO_N "(cached) $ECHO_C" >&6
2606else
2607  if test -n "$AR"; then
2608  ac_cv_prog_AR="$AR" # Let the user override the test.
2609else
2610  ac_save_IFS=$IFS; IFS=$ac_path_separator
2611ac_dummy="$PATH"
2612for ac_dir in $ac_dummy; do
2613  IFS=$ac_save_IFS
2614  test -z "$ac_dir" && ac_dir=.
2615  $as_executable_p "$ac_dir/$ac_word" || continue
2616ac_cv_prog_AR="${ac_tool_prefix}ar"
2617echo "$as_me:2617: found $ac_dir/$ac_word" >&5
2618break
2619done
2620
2621fi
2622fi
2623AR=$ac_cv_prog_AR
2624if test -n "$AR"; then
2625  echo "$as_me:2625: result: $AR" >&5
2626echo "${ECHO_T}$AR" >&6
2627else
2628  echo "$as_me:2628: result: no" >&5
2629echo "${ECHO_T}no" >&6
2630fi
2631
2632fi
2633if test -z "$ac_cv_prog_AR"; then
2634  ac_ct_AR=$AR
2635  # Extract the first word of "ar", so it can be a program name with args.
2636set dummy ar; ac_word=$2
2637echo "$as_me:2637: checking for $ac_word" >&5
2638echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2639if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
2640  echo $ECHO_N "(cached) $ECHO_C" >&6
2641else
2642  if test -n "$ac_ct_AR"; then
2643  ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
2644else
2645  ac_save_IFS=$IFS; IFS=$ac_path_separator
2646ac_dummy="$PATH"
2647for ac_dir in $ac_dummy; do
2648  IFS=$ac_save_IFS
2649  test -z "$ac_dir" && ac_dir=.
2650  $as_executable_p "$ac_dir/$ac_word" || continue
2651ac_cv_prog_ac_ct_AR="ar"
2652echo "$as_me:2652: found $ac_dir/$ac_word" >&5
2653break
2654done
2655
2656  test -z "$ac_cv_prog_ac_ct_AR" && ac_cv_prog_ac_ct_AR="ar"
2657fi
2658fi
2659ac_ct_AR=$ac_cv_prog_ac_ct_AR
2660if test -n "$ac_ct_AR"; then
2661  echo "$as_me:2661: result: $ac_ct_AR" >&5
2662echo "${ECHO_T}$ac_ct_AR" >&6
2663else
2664  echo "$as_me:2664: result: no" >&5
2665echo "${ECHO_T}no" >&6
2666fi
2667
2668  AR=$ac_ct_AR
2669else
2670  AR="$ac_cv_prog_AR"
2671fi
2672
2673echo "$as_me:2673: checking for options to update archives" >&5
2674echo $ECHO_N "checking for options to update archives... $ECHO_C" >&6
2675if test "${cf_cv_ar_flags+set}" = set; then
2676  echo $ECHO_N "(cached) $ECHO_C" >&6
2677else
2678
2679	cf_cv_ar_flags=unknown
2680	for cf_ar_flags in -curvU -curv curv -crv crv -cqv cqv -rv rv
2681	do
2682
2683		# check if $ARFLAGS already contains this choice
2684		if test "x$ARFLAGS" != "x" ; then
2685			cf_check_ar_flags=`echo "x$ARFLAGS" | sed -e "s/$cf_ar_flags\$//" -e "s/$cf_ar_flags / /"`
2686			if test "x$ARFLAGS" != "$cf_check_ar_flags" ; then
2687				cf_cv_ar_flags=
2688				break
2689			fi
2690		fi
2691
2692		rm -f conftest.$ac_cv_objext
2693		rm -f conftest.a
2694
2695		cat >conftest.$ac_ext <<EOF
2696#line 2696 "configure"
2697int	testdata[3] = { 123, 456, 789 };
2698EOF
2699		if { (eval echo "$as_me:2699: \"$ac_compile\"") >&5
2700  (eval $ac_compile) 2>&5
2701  ac_status=$?
2702  echo "$as_me:2702: \$? = $ac_status" >&5
2703  (exit $ac_status); } ; then
2704			echo "$AR $ARFLAGS $cf_ar_flags conftest.a conftest.$ac_cv_objext" >&5
2705			$AR $ARFLAGS $cf_ar_flags conftest.a conftest.$ac_cv_objext 2>&5 1>/dev/null
2706			if test -f conftest.a ; then
2707				cf_cv_ar_flags=$cf_ar_flags
2708				break
2709			fi
2710		else
2711			test -n "$verbose" && echo "	cannot compile test-program" 1>&6
2712
2713echo "${as_me:-configure}:2713: testing cannot compile test-program ..." 1>&5
2714
2715			break
2716		fi
2717	done
2718	rm -f conftest.a conftest.$ac_ext conftest.$ac_cv_objext
2719
2720fi
2721echo "$as_me:2721: result: $cf_cv_ar_flags" >&5
2722echo "${ECHO_T}$cf_cv_ar_flags" >&6
2723
2724if test -n "$ARFLAGS" ; then
2725	if test -n "$cf_cv_ar_flags" ; then
2726		ARFLAGS="$ARFLAGS $cf_cv_ar_flags"
2727	fi
2728else
2729	ARFLAGS=$cf_cv_ar_flags
2730fi
2731
2732echo "$as_me:2732: checking for makeflags variable" >&5
2733echo $ECHO_N "checking for makeflags variable... $ECHO_C" >&6
2734if test "${cf_cv_makeflags+set}" = set; then
2735  echo $ECHO_N "(cached) $ECHO_C" >&6
2736else
2737
2738	cf_cv_makeflags=''
2739	for cf_option in '-${MAKEFLAGS}' '${MFLAGS}'
2740	do
2741		cat >cf_makeflags.tmp <<CF_EOF
2742SHELL = $SHELL
2743all :
2744	@ echo '.$cf_option'
2745CF_EOF
2746		cf_result=`${MAKE:-make} -k -f cf_makeflags.tmp 2>/dev/null | fgrep -v "ing directory" | sed -e 's,[ 	]*$,,'`
2747		case "$cf_result" in
2748		(.*k|.*kw)
2749			cf_result=`${MAKE:-make} -k -f cf_makeflags.tmp CC=cc 2>/dev/null`
2750			case "$cf_result" in
2751			(.*CC=*)	cf_cv_makeflags=
2752				;;
2753			(*)	cf_cv_makeflags=$cf_option
2754				;;
2755			esac
2756			break
2757			;;
2758		(.-)
2759			;;
2760		(*)
2761
2762echo "${as_me:-configure}:2762: testing given option \"$cf_option\",no match \"$cf_result\" ..." 1>&5
2763
2764			;;
2765		esac
2766	done
2767	rm -f cf_makeflags.tmp
2768
2769fi
2770echo "$as_me:2770: result: $cf_cv_makeflags" >&5
2771echo "${ECHO_T}$cf_cv_makeflags" >&6
2772
2773echo "$as_me:2773: checking if filesystem supports mixed-case filenames" >&5
2774echo $ECHO_N "checking if filesystem supports mixed-case filenames... $ECHO_C" >&6
2775if test "${cf_cv_mixedcase+set}" = set; then
2776  echo $ECHO_N "(cached) $ECHO_C" >&6
2777else
2778
2779if test "$cross_compiling" = yes ; then
2780	case $target_alias in
2781	(*-os2-emx*|*-msdosdjgpp*|*-cygwin*|*-msys*|*-mingw*|*-uwin*)
2782		cf_cv_mixedcase=no
2783		;;
2784	(*)
2785		cf_cv_mixedcase=yes
2786		;;
2787	esac
2788else
2789	rm -f conftest CONFTEST
2790	echo test >conftest
2791	if test -f CONFTEST ; then
2792		cf_cv_mixedcase=no
2793	else
2794		cf_cv_mixedcase=yes
2795	fi
2796	rm -f conftest CONFTEST
2797fi
2798
2799fi
2800echo "$as_me:2800: result: $cf_cv_mixedcase" >&5
2801echo "${ECHO_T}$cf_cv_mixedcase" >&6
2802test "$cf_cv_mixedcase" = yes &&
2803cat >>confdefs.h <<\EOF
2804#define MIXEDCASE_FILENAMES 1
2805EOF
2806
2807for ac_prog in exctags ctags
2808do
2809  # Extract the first word of "$ac_prog", so it can be a program name with args.
2810set dummy $ac_prog; ac_word=$2
2811echo "$as_me:2811: checking for $ac_word" >&5
2812echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2813if test "${ac_cv_prog_CTAGS+set}" = set; then
2814  echo $ECHO_N "(cached) $ECHO_C" >&6
2815else
2816  if test -n "$CTAGS"; then
2817  ac_cv_prog_CTAGS="$CTAGS" # Let the user override the test.
2818else
2819  ac_save_IFS=$IFS; IFS=$ac_path_separator
2820ac_dummy="$PATH"
2821for ac_dir in $ac_dummy; do
2822  IFS=$ac_save_IFS
2823  test -z "$ac_dir" && ac_dir=.
2824  $as_executable_p "$ac_dir/$ac_word" || continue
2825ac_cv_prog_CTAGS="$ac_prog"
2826echo "$as_me:2826: found $ac_dir/$ac_word" >&5
2827break
2828done
2829
2830fi
2831fi
2832CTAGS=$ac_cv_prog_CTAGS
2833if test -n "$CTAGS"; then
2834  echo "$as_me:2834: result: $CTAGS" >&5
2835echo "${ECHO_T}$CTAGS" >&6
2836else
2837  echo "$as_me:2837: result: no" >&5
2838echo "${ECHO_T}no" >&6
2839fi
2840
2841  test -n "$CTAGS" && break
2842done
2843
2844for ac_prog in exetags etags
2845do
2846  # Extract the first word of "$ac_prog", so it can be a program name with args.
2847set dummy $ac_prog; ac_word=$2
2848echo "$as_me:2848: checking for $ac_word" >&5
2849echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2850if test "${ac_cv_prog_ETAGS+set}" = set; then
2851  echo $ECHO_N "(cached) $ECHO_C" >&6
2852else
2853  if test -n "$ETAGS"; then
2854  ac_cv_prog_ETAGS="$ETAGS" # Let the user override the test.
2855else
2856  ac_save_IFS=$IFS; IFS=$ac_path_separator
2857ac_dummy="$PATH"
2858for ac_dir in $ac_dummy; do
2859  IFS=$ac_save_IFS
2860  test -z "$ac_dir" && ac_dir=.
2861  $as_executable_p "$ac_dir/$ac_word" || continue
2862ac_cv_prog_ETAGS="$ac_prog"
2863echo "$as_me:2863: found $ac_dir/$ac_word" >&5
2864break
2865done
2866
2867fi
2868fi
2869ETAGS=$ac_cv_prog_ETAGS
2870if test -n "$ETAGS"; then
2871  echo "$as_me:2871: result: $ETAGS" >&5
2872echo "${ECHO_T}$ETAGS" >&6
2873else
2874  echo "$as_me:2874: result: no" >&5
2875echo "${ECHO_T}no" >&6
2876fi
2877
2878  test -n "$ETAGS" && break
2879done
2880
2881# Extract the first word of "${CTAGS:-ctags}", so it can be a program name with args.
2882set dummy ${CTAGS:-ctags}; ac_word=$2
2883echo "$as_me:2883: checking for $ac_word" >&5
2884echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2885if test "${ac_cv_prog_MAKE_LOWER_TAGS+set}" = set; then
2886  echo $ECHO_N "(cached) $ECHO_C" >&6
2887else
2888  if test -n "$MAKE_LOWER_TAGS"; then
2889  ac_cv_prog_MAKE_LOWER_TAGS="$MAKE_LOWER_TAGS" # Let the user override the test.
2890else
2891  ac_save_IFS=$IFS; IFS=$ac_path_separator
2892ac_dummy="$PATH"
2893for ac_dir in $ac_dummy; do
2894  IFS=$ac_save_IFS
2895  test -z "$ac_dir" && ac_dir=.
2896  $as_executable_p "$ac_dir/$ac_word" || continue
2897ac_cv_prog_MAKE_LOWER_TAGS="yes"
2898echo "$as_me:2898: found $ac_dir/$ac_word" >&5
2899break
2900done
2901
2902  test -z "$ac_cv_prog_MAKE_LOWER_TAGS" && ac_cv_prog_MAKE_LOWER_TAGS="no"
2903fi
2904fi
2905MAKE_LOWER_TAGS=$ac_cv_prog_MAKE_LOWER_TAGS
2906if test -n "$MAKE_LOWER_TAGS"; then
2907  echo "$as_me:2907: result: $MAKE_LOWER_TAGS" >&5
2908echo "${ECHO_T}$MAKE_LOWER_TAGS" >&6
2909else
2910  echo "$as_me:2910: result: no" >&5
2911echo "${ECHO_T}no" >&6
2912fi
2913
2914if test "$cf_cv_mixedcase" = yes ; then
2915	# Extract the first word of "${ETAGS:-etags}", so it can be a program name with args.
2916set dummy ${ETAGS:-etags}; ac_word=$2
2917echo "$as_me:2917: checking for $ac_word" >&5
2918echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2919if test "${ac_cv_prog_MAKE_UPPER_TAGS+set}" = set; then
2920  echo $ECHO_N "(cached) $ECHO_C" >&6
2921else
2922  if test -n "$MAKE_UPPER_TAGS"; then
2923  ac_cv_prog_MAKE_UPPER_TAGS="$MAKE_UPPER_TAGS" # Let the user override the test.
2924else
2925  ac_save_IFS=$IFS; IFS=$ac_path_separator
2926ac_dummy="$PATH"
2927for ac_dir in $ac_dummy; do
2928  IFS=$ac_save_IFS
2929  test -z "$ac_dir" && ac_dir=.
2930  $as_executable_p "$ac_dir/$ac_word" || continue
2931ac_cv_prog_MAKE_UPPER_TAGS="yes"
2932echo "$as_me:2932: found $ac_dir/$ac_word" >&5
2933break
2934done
2935
2936  test -z "$ac_cv_prog_MAKE_UPPER_TAGS" && ac_cv_prog_MAKE_UPPER_TAGS="no"
2937fi
2938fi
2939MAKE_UPPER_TAGS=$ac_cv_prog_MAKE_UPPER_TAGS
2940if test -n "$MAKE_UPPER_TAGS"; then
2941  echo "$as_me:2941: result: $MAKE_UPPER_TAGS" >&5
2942echo "${ECHO_T}$MAKE_UPPER_TAGS" >&6
2943else
2944  echo "$as_me:2944: result: no" >&5
2945echo "${ECHO_T}no" >&6
2946fi
2947
2948else
2949	MAKE_UPPER_TAGS=no
2950fi
2951
2952if test "$MAKE_UPPER_TAGS" = yes ; then
2953	MAKE_UPPER_TAGS=
2954else
2955	MAKE_UPPER_TAGS="#"
2956fi
2957
2958if test "$MAKE_LOWER_TAGS" = yes ; then
2959	MAKE_LOWER_TAGS=
2960else
2961	MAKE_LOWER_TAGS="#"
2962fi
2963
2964echo "$as_me:2964: checking if you want to see long compiling messages" >&5
2965echo $ECHO_N "checking if you want to see long compiling messages... $ECHO_C" >&6
2966
2967# Check whether --enable-echo or --disable-echo was given.
2968if test "${enable_echo+set}" = set; then
2969  enableval="$enable_echo"
2970  test "$enableval" != no && enableval=yes
2971	if test "$enableval" != "yes" ; then
2972
2973	ECHO_LT='--silent'
2974	ECHO_LD='@echo linking $@;'
2975	RULE_CC='@echo compiling $<'
2976	SHOW_CC='@echo compiling $@'
2977	ECHO_CC='@'
2978
2979	else
2980
2981	ECHO_LT=''
2982	ECHO_LD=''
2983	RULE_CC=''
2984	SHOW_CC=''
2985	ECHO_CC=''
2986
2987	fi
2988else
2989  enableval=yes
2990
2991	ECHO_LT=''
2992	ECHO_LD=''
2993	RULE_CC=''
2994	SHOW_CC=''
2995	ECHO_CC=''
2996
2997fi;
2998echo "$as_me:2998: result: $enableval" >&5
2999echo "${ECHO_T}$enableval" >&6
3000
3001# Make sure we can run config.sub.
3002$ac_config_sub sun4 >/dev/null 2>&1 ||
3003  { { echo "$as_me:3003: error: cannot run $ac_config_sub" >&5
3004echo "$as_me: error: cannot run $ac_config_sub" >&2;}
3005   { (exit 1); exit 1; }; }
3006
3007echo "$as_me:3007: checking build system type" >&5
3008echo $ECHO_N "checking build system type... $ECHO_C" >&6
3009if test "${ac_cv_build+set}" = set; then
3010  echo $ECHO_N "(cached) $ECHO_C" >&6
3011else
3012  ac_cv_build_alias=$build_alias
3013test -z "$ac_cv_build_alias" &&
3014  ac_cv_build_alias=`$ac_config_guess`
3015test -z "$ac_cv_build_alias" &&
3016  { { echo "$as_me:3016: error: cannot guess build type; you must specify one" >&5
3017echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
3018   { (exit 1); exit 1; }; }
3019ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
3020  { { echo "$as_me:3020: error: $ac_config_sub $ac_cv_build_alias failed." >&5
3021echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed." >&2;}
3022   { (exit 1); exit 1; }; }
3023
3024fi
3025echo "$as_me:3025: result: $ac_cv_build" >&5
3026echo "${ECHO_T}$ac_cv_build" >&6
3027build=$ac_cv_build
3028build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
3029build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
3030build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
3031
3032if test -f $srcdir/config.guess || test -f $ac_aux_dir/config.guess ; then
3033	echo "$as_me:3033: checking host system type" >&5
3034echo $ECHO_N "checking host system type... $ECHO_C" >&6
3035if test "${ac_cv_host+set}" = set; then
3036  echo $ECHO_N "(cached) $ECHO_C" >&6
3037else
3038  ac_cv_host_alias=$host_alias
3039test -z "$ac_cv_host_alias" &&
3040  ac_cv_host_alias=$ac_cv_build_alias
3041ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
3042  { { echo "$as_me:3042: error: $ac_config_sub $ac_cv_host_alias failed" >&5
3043echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
3044   { (exit 1); exit 1; }; }
3045
3046fi
3047echo "$as_me:3047: result: $ac_cv_host" >&5
3048echo "${ECHO_T}$ac_cv_host" >&6
3049host=$ac_cv_host
3050host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
3051host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
3052host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
3053
3054	system_name="$host_os"
3055else
3056	system_name="`(uname -s -r) 2>/dev/null`"
3057	if test -z "$system_name" ; then
3058		system_name="`(hostname) 2>/dev/null`"
3059	fi
3060fi
3061test -n "$system_name" &&
3062cat >>confdefs.h <<EOF
3063#define SYSTEM_NAME "$system_name"
3064EOF
3065
3066if test "${cf_cv_system_name+set}" = set; then
3067  echo $ECHO_N "(cached) $ECHO_C" >&6
3068else
3069  cf_cv_system_name="$system_name"
3070fi
3071
3072test -z "$system_name" && system_name="$cf_cv_system_name"
3073test -n "$cf_cv_system_name" && echo "$as_me:3073: result: Configuring for $cf_cv_system_name" >&5
3074echo "${ECHO_T}Configuring for $cf_cv_system_name" >&6
3075
3076if test ".$system_name" != ".$cf_cv_system_name" ; then
3077	echo "$as_me:3077: result: Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&5
3078echo "${ECHO_T}Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&6
3079	{ { echo "$as_me:3079: error: \"Please remove config.cache and try again.\"" >&5
3080echo "$as_me: error: \"Please remove config.cache and try again.\"" >&2;}
3081   { (exit 1); exit 1; }; }
3082fi
3083
3084case $cf_cv_system_name in
3085(os2*)
3086	CFLAGS="$CFLAGS -Zmt"
3087
3088	test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
3089	CPPFLAGS="${CPPFLAGS}-D__ST_MT_ERRNO__"
3090
3091	CXXFLAGS="$CXXFLAGS -Zmt"
3092	# autoconf's macro sets -Zexe and suffix both, which conflict:w
3093	LDFLAGS="$LDFLAGS -Zmt -Zcrtdll"
3094	ac_cv_exeext=.exe
3095	;;
3096esac
3097
3098PROG_EXT="$EXEEXT"
3099
3100test -n "$PROG_EXT" &&
3101cat >>confdefs.h <<EOF
3102#define PROG_EXT "$PROG_EXT"
3103EOF
3104
3105	echo "$as_me:3105: checking for PATH separator" >&5
3106echo $ECHO_N "checking for PATH separator... $ECHO_C" >&6
3107	case $cf_cv_system_name in
3108	(os2*)	PATH_SEPARATOR=';'  ;;
3109	(*)	${PATH_SEPARATOR:=':'}  ;;
3110	esac
3111
3112	echo "$as_me:3112: result: $PATH_SEPARATOR" >&5
3113echo "${ECHO_T}$PATH_SEPARATOR" >&6
3114
3115	case $cf_cv_system_name in
3116	(OS/2*|os2*)
3117		if test "$DFT_LWR_MODEL" = libtool; then
3118			LIB_PREFIX='lib'
3119		else
3120			LIB_PREFIX=''
3121		fi
3122		;;
3123	(*)	LIB_PREFIX='lib'
3124		;;
3125	esac
3126
3127cf_XOPEN_SOURCE=500
3128cf_POSIX_C_SOURCE=199506L
3129cf_xopen_source=
3130
3131case $host_os in
3132(aix[4-7]*)
3133	cf_xopen_source="-D_ALL_SOURCE"
3134	;;
3135(msys)
3136	cf_XOPEN_SOURCE=600
3137	;;
3138(darwin[0-8].*)
3139	cf_xopen_source="-D_APPLE_C_SOURCE"
3140	;;
3141(darwin*)
3142	cf_xopen_source="-D_DARWIN_C_SOURCE"
3143	cf_XOPEN_SOURCE=
3144	;;
3145(freebsd*|dragonfly*)
3146	# 5.x headers associate
3147	#	_XOPEN_SOURCE=600 with _POSIX_C_SOURCE=200112L
3148	#	_XOPEN_SOURCE=500 with _POSIX_C_SOURCE=199506L
3149	cf_POSIX_C_SOURCE=200112L
3150	cf_XOPEN_SOURCE=600
3151	cf_xopen_source="-D_BSD_TYPES -D__BSD_VISIBLE -D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
3152	;;
3153(hpux11*)
3154	cf_xopen_source="-D_HPUX_SOURCE -D_XOPEN_SOURCE=500"
3155	;;
3156(hpux*)
3157	cf_xopen_source="-D_HPUX_SOURCE"
3158	;;
3159(irix[56].*)
3160	cf_xopen_source="-D_SGI_SOURCE"
3161	cf_XOPEN_SOURCE=
3162	;;
3163(linux*|uclinux*|gnu*|mint*|k*bsd*-gnu|cygwin)
3164
3165cf_gnu_xopen_source=$cf_XOPEN_SOURCE
3166
3167echo "$as_me:3167: checking if this is the GNU C library" >&5
3168echo $ECHO_N "checking if this is the GNU C library... $ECHO_C" >&6
3169if test "${cf_cv_gnu_library+set}" = set; then
3170  echo $ECHO_N "(cached) $ECHO_C" >&6
3171else
3172
3173cat >conftest.$ac_ext <<_ACEOF
3174#line 3174 "configure"
3175#include "confdefs.h"
3176#include <sys/types.h>
3177int
3178main (void)
3179{
3180
3181	#if __GLIBC__ > 0 && __GLIBC_MINOR__ >= 0
3182		return 0;
3183	#else
3184	#	error not GNU C library
3185	#endif
3186  ;
3187  return 0;
3188}
3189_ACEOF
3190rm -f conftest.$ac_objext
3191if { (eval echo "$as_me:3191: \"$ac_compile\"") >&5
3192  (eval $ac_compile) 2>&5
3193  ac_status=$?
3194  echo "$as_me:3194: \$? = $ac_status" >&5
3195  (exit $ac_status); } &&
3196         { ac_try='test -s conftest.$ac_objext'
3197  { (eval echo "$as_me:3197: \"$ac_try\"") >&5
3198  (eval $ac_try) 2>&5
3199  ac_status=$?
3200  echo "$as_me:3200: \$? = $ac_status" >&5
3201  (exit $ac_status); }; }; then
3202  cf_cv_gnu_library=yes
3203else
3204  echo "$as_me: failed program was:" >&5
3205cat conftest.$ac_ext >&5
3206cf_cv_gnu_library=no
3207fi
3208rm -f conftest.$ac_objext conftest.$ac_ext
3209
3210fi
3211echo "$as_me:3211: result: $cf_cv_gnu_library" >&5
3212echo "${ECHO_T}$cf_cv_gnu_library" >&6
3213
3214if test x$cf_cv_gnu_library = xyes; then
3215
3216	# With glibc 2.19 (13 years after this check was begun), _DEFAULT_SOURCE
3217	# was changed to help a little...
3218	echo "$as_me:3218: checking if _DEFAULT_SOURCE can be used as a basis" >&5
3219echo $ECHO_N "checking if _DEFAULT_SOURCE can be used as a basis... $ECHO_C" >&6
3220if test "${cf_cv_gnu_library_219+set}" = set; then
3221  echo $ECHO_N "(cached) $ECHO_C" >&6
3222else
3223
3224		cf_save="$CPPFLAGS"
3225
3226	test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
3227	CPPFLAGS="${CPPFLAGS}-D_DEFAULT_SOURCE"
3228
3229		cat >conftest.$ac_ext <<_ACEOF
3230#line 3230 "configure"
3231#include "confdefs.h"
3232#include <sys/types.h>
3233int
3234main (void)
3235{
3236
3237			#if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 19) || (__GLIBC__ > 2)
3238				return 0;
3239			#else
3240			#	error GNU C library __GLIBC__.__GLIBC_MINOR__ is too old
3241			#endif
3242  ;
3243  return 0;
3244}
3245_ACEOF
3246rm -f conftest.$ac_objext
3247if { (eval echo "$as_me:3247: \"$ac_compile\"") >&5
3248  (eval $ac_compile) 2>&5
3249  ac_status=$?
3250  echo "$as_me:3250: \$? = $ac_status" >&5
3251  (exit $ac_status); } &&
3252         { ac_try='test -s conftest.$ac_objext'
3253  { (eval echo "$as_me:3253: \"$ac_try\"") >&5
3254  (eval $ac_try) 2>&5
3255  ac_status=$?
3256  echo "$as_me:3256: \$? = $ac_status" >&5
3257  (exit $ac_status); }; }; then
3258  cf_cv_gnu_library_219=yes
3259else
3260  echo "$as_me: failed program was:" >&5
3261cat conftest.$ac_ext >&5
3262cf_cv_gnu_library_219=no
3263fi
3264rm -f conftest.$ac_objext conftest.$ac_ext
3265		CPPFLAGS="$cf_save"
3266
3267fi
3268echo "$as_me:3268: result: $cf_cv_gnu_library_219" >&5
3269echo "${ECHO_T}$cf_cv_gnu_library_219" >&6
3270
3271	if test "x$cf_cv_gnu_library_219" = xyes; then
3272		cf_save="$CPPFLAGS"
3273		echo "$as_me:3273: checking if _XOPEN_SOURCE=$cf_gnu_xopen_source works with _DEFAULT_SOURCE" >&5
3274echo $ECHO_N "checking if _XOPEN_SOURCE=$cf_gnu_xopen_source works with _DEFAULT_SOURCE... $ECHO_C" >&6
3275if test "${cf_cv_gnu_dftsrc_219+set}" = set; then
3276  echo $ECHO_N "(cached) $ECHO_C" >&6
3277else
3278
3279cf_fix_cppflags=no
3280cf_new_cflags=
3281cf_new_cppflags=
3282cf_new_extra_cppflags=
3283
3284for cf_add_cflags in -D_DEFAULT_SOURCE -D_XOPEN_SOURCE=$cf_gnu_xopen_source
3285do
3286case $cf_fix_cppflags in
3287(no)
3288	case $cf_add_cflags in
3289	(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
3290		case $cf_add_cflags in
3291		(-D*)
3292			cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3293
3294			test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
3295				&& test -z "${cf_tst_cflags}" \
3296				&& cf_fix_cppflags=yes
3297
3298			if test $cf_fix_cppflags = yes ; then
3299
3300	test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3301	cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3302
3303				continue
3304			elif test "${cf_tst_cflags}" = "\"'" ; then
3305
3306	test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3307	cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3308
3309				continue
3310			fi
3311			;;
3312		esac
3313		case "$CPPFLAGS" in
3314		(*$cf_add_cflags)
3315			;;
3316		(*)
3317			case $cf_add_cflags in
3318			(-D*)
3319				cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3320
3321CPPFLAGS=`echo "$CPPFLAGS" | \
3322	sed	-e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ 	]*\)\?[ 	]/ /g' \
3323		-e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ 	]*\)\?$//g'`
3324
3325				;;
3326			esac
3327
3328	test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
3329	cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
3330
3331			;;
3332		esac
3333		;;
3334	(*)
3335
3336	test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
3337	cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
3338
3339		;;
3340	esac
3341	;;
3342(yes)
3343
3344	test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3345	cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3346
3347	cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
3348
3349	test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
3350		&& test -z "${cf_tst_cflags}" \
3351		&& cf_fix_cppflags=no
3352	;;
3353esac
3354done
3355
3356if test -n "$cf_new_cflags" ; then
3357
3358	test -n "$CFLAGS" && CFLAGS="$CFLAGS "
3359	CFLAGS="${CFLAGS}$cf_new_cflags"
3360
3361fi
3362
3363if test -n "$cf_new_cppflags" ; then
3364
3365	test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
3366	CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
3367
3368fi
3369
3370if test -n "$cf_new_extra_cppflags" ; then
3371
3372	test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
3373	EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
3374
3375fi
3376
3377			cat >conftest.$ac_ext <<_ACEOF
3378#line 3378 "configure"
3379#include "confdefs.h"
3380
3381				#include <limits.h>
3382				#include <sys/types.h>
3383
3384int
3385main (void)
3386{
3387
3388				#if (_XOPEN_SOURCE >= $cf_gnu_xopen_source) && (MB_LEN_MAX > 1)
3389					return 0;
3390				#else
3391				#	error GNU C library is too old
3392				#endif
3393  ;
3394  return 0;
3395}
3396_ACEOF
3397rm -f conftest.$ac_objext
3398if { (eval echo "$as_me:3398: \"$ac_compile\"") >&5
3399  (eval $ac_compile) 2>&5
3400  ac_status=$?
3401  echo "$as_me:3401: \$? = $ac_status" >&5
3402  (exit $ac_status); } &&
3403         { ac_try='test -s conftest.$ac_objext'
3404  { (eval echo "$as_me:3404: \"$ac_try\"") >&5
3405  (eval $ac_try) 2>&5
3406  ac_status=$?
3407  echo "$as_me:3407: \$? = $ac_status" >&5
3408  (exit $ac_status); }; }; then
3409  cf_cv_gnu_dftsrc_219=yes
3410else
3411  echo "$as_me: failed program was:" >&5
3412cat conftest.$ac_ext >&5
3413cf_cv_gnu_dftsrc_219=no
3414fi
3415rm -f conftest.$ac_objext conftest.$ac_ext
3416
3417fi
3418echo "$as_me:3418: result: $cf_cv_gnu_dftsrc_219" >&5
3419echo "${ECHO_T}$cf_cv_gnu_dftsrc_219" >&6
3420		test "x$cf_cv_gnu_dftsrc_219" = "xyes" || CPPFLAGS="$cf_save"
3421	else
3422		cf_cv_gnu_dftsrc_219=maybe
3423	fi
3424
3425	if test "x$cf_cv_gnu_dftsrc_219" != xyes; then
3426
3427		echo "$as_me:3427: checking if we must define _GNU_SOURCE" >&5
3428echo $ECHO_N "checking if we must define _GNU_SOURCE... $ECHO_C" >&6
3429if test "${cf_cv_gnu_source+set}" = set; then
3430  echo $ECHO_N "(cached) $ECHO_C" >&6
3431else
3432
3433		cat >conftest.$ac_ext <<_ACEOF
3434#line 3434 "configure"
3435#include "confdefs.h"
3436#include <sys/types.h>
3437int
3438main (void)
3439{
3440
3441			#ifndef _XOPEN_SOURCE
3442			#error	expected _XOPEN_SOURCE to be defined
3443			#endif
3444  ;
3445  return 0;
3446}
3447_ACEOF
3448rm -f conftest.$ac_objext
3449if { (eval echo "$as_me:3449: \"$ac_compile\"") >&5
3450  (eval $ac_compile) 2>&5
3451  ac_status=$?
3452  echo "$as_me:3452: \$? = $ac_status" >&5
3453  (exit $ac_status); } &&
3454         { ac_try='test -s conftest.$ac_objext'
3455  { (eval echo "$as_me:3455: \"$ac_try\"") >&5
3456  (eval $ac_try) 2>&5
3457  ac_status=$?
3458  echo "$as_me:3458: \$? = $ac_status" >&5
3459  (exit $ac_status); }; }; then
3460  cf_cv_gnu_source=no
3461else
3462  echo "$as_me: failed program was:" >&5
3463cat conftest.$ac_ext >&5
3464cf_save="$CPPFLAGS"
3465
3466cf_fix_cppflags=no
3467cf_new_cflags=
3468cf_new_cppflags=
3469cf_new_extra_cppflags=
3470
3471for cf_add_cflags in -D_GNU_SOURCE
3472do
3473case $cf_fix_cppflags in
3474(no)
3475	case $cf_add_cflags in
3476	(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
3477		case $cf_add_cflags in
3478		(-D*)
3479			cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3480
3481			test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
3482				&& test -z "${cf_tst_cflags}" \
3483				&& cf_fix_cppflags=yes
3484
3485			if test $cf_fix_cppflags = yes ; then
3486
3487	test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3488	cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3489
3490				continue
3491			elif test "${cf_tst_cflags}" = "\"'" ; then
3492
3493	test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3494	cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3495
3496				continue
3497			fi
3498			;;
3499		esac
3500		case "$CPPFLAGS" in
3501		(*$cf_add_cflags)
3502			;;
3503		(*)
3504			case $cf_add_cflags in
3505			(-D*)
3506				cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3507
3508CPPFLAGS=`echo "$CPPFLAGS" | \
3509	sed	-e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ 	]*\)\?[ 	]/ /g' \
3510		-e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ 	]*\)\?$//g'`
3511
3512				;;
3513			esac
3514
3515	test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
3516	cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
3517
3518			;;
3519		esac
3520		;;
3521	(*)
3522
3523	test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
3524	cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
3525
3526		;;
3527	esac
3528	;;
3529(yes)
3530
3531	test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3532	cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3533
3534	cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
3535
3536	test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
3537		&& test -z "${cf_tst_cflags}" \
3538		&& cf_fix_cppflags=no
3539	;;
3540esac
3541done
3542
3543if test -n "$cf_new_cflags" ; then
3544
3545	test -n "$CFLAGS" && CFLAGS="$CFLAGS "
3546	CFLAGS="${CFLAGS}$cf_new_cflags"
3547
3548fi
3549
3550if test -n "$cf_new_cppflags" ; then
3551
3552	test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
3553	CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
3554
3555fi
3556
3557if test -n "$cf_new_extra_cppflags" ; then
3558
3559	test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
3560	EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
3561
3562fi
3563
3564			 cat >conftest.$ac_ext <<_ACEOF
3565#line 3565 "configure"
3566#include "confdefs.h"
3567#include <sys/types.h>
3568int
3569main (void)
3570{
3571
3572				#ifdef _XOPEN_SOURCE
3573				#error	expected _XOPEN_SOURCE to be undefined
3574				#endif
3575  ;
3576  return 0;
3577}
3578_ACEOF
3579rm -f conftest.$ac_objext
3580if { (eval echo "$as_me:3580: \"$ac_compile\"") >&5
3581  (eval $ac_compile) 2>&5
3582  ac_status=$?
3583  echo "$as_me:3583: \$? = $ac_status" >&5
3584  (exit $ac_status); } &&
3585         { ac_try='test -s conftest.$ac_objext'
3586  { (eval echo "$as_me:3586: \"$ac_try\"") >&5
3587  (eval $ac_try) 2>&5
3588  ac_status=$?
3589  echo "$as_me:3589: \$? = $ac_status" >&5
3590  (exit $ac_status); }; }; then
3591  cf_cv_gnu_source=no
3592else
3593  echo "$as_me: failed program was:" >&5
3594cat conftest.$ac_ext >&5
3595cf_cv_gnu_source=yes
3596fi
3597rm -f conftest.$ac_objext conftest.$ac_ext
3598			CPPFLAGS="$cf_save"
3599
3600fi
3601rm -f conftest.$ac_objext conftest.$ac_ext
3602
3603fi
3604echo "$as_me:3604: result: $cf_cv_gnu_source" >&5
3605echo "${ECHO_T}$cf_cv_gnu_source" >&6
3606
3607		if test "$cf_cv_gnu_source" = yes
3608		then
3609		echo "$as_me:3609: checking if we should also define _DEFAULT_SOURCE" >&5
3610echo $ECHO_N "checking if we should also define _DEFAULT_SOURCE... $ECHO_C" >&6
3611if test "${cf_cv_default_source+set}" = set; then
3612  echo $ECHO_N "(cached) $ECHO_C" >&6
3613else
3614
3615	test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
3616	CPPFLAGS="${CPPFLAGS}-D_GNU_SOURCE"
3617
3618			cat >conftest.$ac_ext <<_ACEOF
3619#line 3619 "configure"
3620#include "confdefs.h"
3621#include <sys/types.h>
3622int
3623main (void)
3624{
3625
3626				#ifdef _DEFAULT_SOURCE
3627				#error	expected _DEFAULT_SOURCE to be undefined
3628				#endif
3629  ;
3630  return 0;
3631}
3632_ACEOF
3633rm -f conftest.$ac_objext
3634if { (eval echo "$as_me:3634: \"$ac_compile\"") >&5
3635  (eval $ac_compile) 2>&5
3636  ac_status=$?
3637  echo "$as_me:3637: \$? = $ac_status" >&5
3638  (exit $ac_status); } &&
3639         { ac_try='test -s conftest.$ac_objext'
3640  { (eval echo "$as_me:3640: \"$ac_try\"") >&5
3641  (eval $ac_try) 2>&5
3642  ac_status=$?
3643  echo "$as_me:3643: \$? = $ac_status" >&5
3644  (exit $ac_status); }; }; then
3645  cf_cv_default_source=no
3646else
3647  echo "$as_me: failed program was:" >&5
3648cat conftest.$ac_ext >&5
3649cf_cv_default_source=yes
3650fi
3651rm -f conftest.$ac_objext conftest.$ac_ext
3652
3653fi
3654echo "$as_me:3654: result: $cf_cv_default_source" >&5
3655echo "${ECHO_T}$cf_cv_default_source" >&6
3656			if test "$cf_cv_default_source" = yes
3657			then
3658
3659	test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
3660	CPPFLAGS="${CPPFLAGS}-D_DEFAULT_SOURCE"
3661
3662			fi
3663		fi
3664	fi
3665
3666fi
3667
3668	;;
3669(minix*)
3670	cf_xopen_source="-D_NETBSD_SOURCE" # POSIX.1-2001 features are ifdef'd with this...
3671	;;
3672(mirbsd*)
3673	# setting _XOPEN_SOURCE or _POSIX_SOURCE breaks <sys/select.h> and other headers which use u_int / u_short types
3674	cf_XOPEN_SOURCE=
3675
3676cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
3677
3678cf_save_CFLAGS="$CFLAGS"
3679cf_save_CPPFLAGS="$CPPFLAGS"
3680
3681cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
3682	sed	-e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ 	]*\)\?[ 	]/ /g' \
3683		-e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ 	]*\)\?$//g'`
3684
3685cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
3686	sed	-e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ 	]*\)\?[ 	]/ /g' \
3687		-e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ 	]*\)\?$//g'`
3688
3689echo "$as_me:3689: checking if we should define _POSIX_C_SOURCE" >&5
3690echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
3691if test "${cf_cv_posix_c_source+set}" = set; then
3692  echo $ECHO_N "(cached) $ECHO_C" >&6
3693else
3694
3695echo "${as_me:-configure}:3695: testing if the symbol is already defined go no further ..." 1>&5
3696
3697	cat >conftest.$ac_ext <<_ACEOF
3698#line 3698 "configure"
3699#include "confdefs.h"
3700#include <sys/types.h>
3701int
3702main (void)
3703{
3704
3705#ifndef _POSIX_C_SOURCE
3706make an error
3707#endif
3708  ;
3709  return 0;
3710}
3711_ACEOF
3712rm -f conftest.$ac_objext
3713if { (eval echo "$as_me:3713: \"$ac_compile\"") >&5
3714  (eval $ac_compile) 2>&5
3715  ac_status=$?
3716  echo "$as_me:3716: \$? = $ac_status" >&5
3717  (exit $ac_status); } &&
3718         { ac_try='test -s conftest.$ac_objext'
3719  { (eval echo "$as_me:3719: \"$ac_try\"") >&5
3720  (eval $ac_try) 2>&5
3721  ac_status=$?
3722  echo "$as_me:3722: \$? = $ac_status" >&5
3723  (exit $ac_status); }; }; then
3724  cf_cv_posix_c_source=no
3725else
3726  echo "$as_me: failed program was:" >&5
3727cat conftest.$ac_ext >&5
3728cf_want_posix_source=no
3729	 case .$cf_POSIX_C_SOURCE in
3730	 (.[12]??*)
3731		cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
3732		;;
3733	 (.2)
3734		cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
3735		cf_want_posix_source=yes
3736		;;
3737	 (.*)
3738		cf_want_posix_source=yes
3739		;;
3740	 esac
3741	 if test "$cf_want_posix_source" = yes ; then
3742		cat >conftest.$ac_ext <<_ACEOF
3743#line 3743 "configure"
3744#include "confdefs.h"
3745#include <sys/types.h>
3746int
3747main (void)
3748{
3749
3750#ifdef _POSIX_SOURCE
3751make an error
3752#endif
3753  ;
3754  return 0;
3755}
3756_ACEOF
3757rm -f conftest.$ac_objext
3758if { (eval echo "$as_me:3758: \"$ac_compile\"") >&5
3759  (eval $ac_compile) 2>&5
3760  ac_status=$?
3761  echo "$as_me:3761: \$? = $ac_status" >&5
3762  (exit $ac_status); } &&
3763         { ac_try='test -s conftest.$ac_objext'
3764  { (eval echo "$as_me:3764: \"$ac_try\"") >&5
3765  (eval $ac_try) 2>&5
3766  ac_status=$?
3767  echo "$as_me:3767: \$? = $ac_status" >&5
3768  (exit $ac_status); }; }; then
3769  :
3770else
3771  echo "$as_me: failed program was:" >&5
3772cat conftest.$ac_ext >&5
3773cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
3774fi
3775rm -f conftest.$ac_objext conftest.$ac_ext
3776	 fi
3777
3778echo "${as_me:-configure}:3778: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
3779
3780	 CFLAGS="$cf_trim_CFLAGS"
3781	 CPPFLAGS="$cf_trim_CPPFLAGS"
3782
3783	test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
3784	CPPFLAGS="${CPPFLAGS}$cf_cv_posix_c_source"
3785
3786echo "${as_me:-configure}:3786: testing if the second compile does not leave our definition intact error ..." 1>&5
3787
3788	 cat >conftest.$ac_ext <<_ACEOF
3789#line 3789 "configure"
3790#include "confdefs.h"
3791#include <sys/types.h>
3792int
3793main (void)
3794{
3795
3796#ifndef _POSIX_C_SOURCE
3797make an error
3798#endif
3799  ;
3800  return 0;
3801}
3802_ACEOF
3803rm -f conftest.$ac_objext
3804if { (eval echo "$as_me:3804: \"$ac_compile\"") >&5
3805  (eval $ac_compile) 2>&5
3806  ac_status=$?
3807  echo "$as_me:3807: \$? = $ac_status" >&5
3808  (exit $ac_status); } &&
3809         { ac_try='test -s conftest.$ac_objext'
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  :
3816else
3817  echo "$as_me: failed program was:" >&5
3818cat conftest.$ac_ext >&5
3819cf_cv_posix_c_source=no
3820fi
3821rm -f conftest.$ac_objext conftest.$ac_ext
3822	 CFLAGS="$cf_save_CFLAGS"
3823	 CPPFLAGS="$cf_save_CPPFLAGS"
3824
3825fi
3826rm -f conftest.$ac_objext conftest.$ac_ext
3827
3828fi
3829echo "$as_me:3829: result: $cf_cv_posix_c_source" >&5
3830echo "${ECHO_T}$cf_cv_posix_c_source" >&6
3831
3832if test "$cf_cv_posix_c_source" != no ; then
3833	CFLAGS="$cf_trim_CFLAGS"
3834	CPPFLAGS="$cf_trim_CPPFLAGS"
3835
3836cf_fix_cppflags=no
3837cf_new_cflags=
3838cf_new_cppflags=
3839cf_new_extra_cppflags=
3840
3841for cf_add_cflags in $cf_cv_posix_c_source
3842do
3843case $cf_fix_cppflags in
3844(no)
3845	case $cf_add_cflags in
3846	(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
3847		case $cf_add_cflags in
3848		(-D*)
3849			cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3850
3851			test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
3852				&& test -z "${cf_tst_cflags}" \
3853				&& cf_fix_cppflags=yes
3854
3855			if test $cf_fix_cppflags = yes ; then
3856
3857	test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3858	cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3859
3860				continue
3861			elif test "${cf_tst_cflags}" = "\"'" ; then
3862
3863	test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3864	cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3865
3866				continue
3867			fi
3868			;;
3869		esac
3870		case "$CPPFLAGS" in
3871		(*$cf_add_cflags)
3872			;;
3873		(*)
3874			case $cf_add_cflags in
3875			(-D*)
3876				cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3877
3878CPPFLAGS=`echo "$CPPFLAGS" | \
3879	sed	-e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ 	]*\)\?[ 	]/ /g' \
3880		-e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ 	]*\)\?$//g'`
3881
3882				;;
3883			esac
3884
3885	test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
3886	cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
3887
3888			;;
3889		esac
3890		;;
3891	(*)
3892
3893	test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
3894	cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
3895
3896		;;
3897	esac
3898	;;
3899(yes)
3900
3901	test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3902	cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3903
3904	cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
3905
3906	test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
3907		&& test -z "${cf_tst_cflags}" \
3908		&& cf_fix_cppflags=no
3909	;;
3910esac
3911done
3912
3913if test -n "$cf_new_cflags" ; then
3914
3915	test -n "$CFLAGS" && CFLAGS="$CFLAGS "
3916	CFLAGS="${CFLAGS}$cf_new_cflags"
3917
3918fi
3919
3920if test -n "$cf_new_cppflags" ; then
3921
3922	test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
3923	CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
3924
3925fi
3926
3927if test -n "$cf_new_extra_cppflags" ; then
3928
3929	test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
3930	EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
3931
3932fi
3933
3934fi
3935
3936	;;
3937(netbsd*)
3938	cf_xopen_source="-D_NETBSD_SOURCE" # setting _XOPEN_SOURCE breaks IPv6 for lynx on NetBSD 1.6, breaks xterm, is not needed for ncursesw
3939	;;
3940(openbsd[4-9]*)
3941	# setting _XOPEN_SOURCE lower than 500 breaks g++ compile with wchar.h, needed for ncursesw
3942	cf_xopen_source="-D_BSD_SOURCE"
3943	cf_XOPEN_SOURCE=600
3944	;;
3945(openbsd*)
3946	# setting _XOPEN_SOURCE breaks xterm on OpenBSD 2.8, is not needed for ncursesw
3947	;;
3948(osf[45]*)
3949	cf_xopen_source="-D_OSF_SOURCE"
3950	;;
3951(nto-qnx*)
3952	cf_xopen_source="-D_QNX_SOURCE"
3953	;;
3954(sco*)
3955	# setting _XOPEN_SOURCE breaks Lynx on SCO Unix / OpenServer
3956	;;
3957(solaris2.*)
3958	cf_xopen_source="-D__EXTENSIONS__"
3959	cf_cv_xopen_source=broken
3960	;;
3961(sysv4.2uw2.*) # Novell/SCO UnixWare 2.x (tested on 2.1.2)
3962	cf_XOPEN_SOURCE=
3963	cf_POSIX_C_SOURCE=
3964	;;
3965(*)
3966
3967echo "$as_me:3967: checking if we should define _XOPEN_SOURCE" >&5
3968echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
3969if test "${cf_cv_xopen_source+set}" = set; then
3970  echo $ECHO_N "(cached) $ECHO_C" >&6
3971else
3972
3973	cat >conftest.$ac_ext <<_ACEOF
3974#line 3974 "configure"
3975#include "confdefs.h"
3976
3977#include <stdlib.h>
3978#include <string.h>
3979#include <sys/types.h>
3980
3981int
3982main (void)
3983{
3984
3985#ifndef _XOPEN_SOURCE
3986make an error
3987#endif
3988  ;
3989  return 0;
3990}
3991_ACEOF
3992rm -f conftest.$ac_objext
3993if { (eval echo "$as_me:3993: \"$ac_compile\"") >&5
3994  (eval $ac_compile) 2>&5
3995  ac_status=$?
3996  echo "$as_me:3996: \$? = $ac_status" >&5
3997  (exit $ac_status); } &&
3998         { ac_try='test -s conftest.$ac_objext'
3999  { (eval echo "$as_me:3999: \"$ac_try\"") >&5
4000  (eval $ac_try) 2>&5
4001  ac_status=$?
4002  echo "$as_me:4002: \$? = $ac_status" >&5
4003  (exit $ac_status); }; }; then
4004  cf_cv_xopen_source=no
4005else
4006  echo "$as_me: failed program was:" >&5
4007cat conftest.$ac_ext >&5
4008cf_save="$CPPFLAGS"
4009
4010	test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4011	CPPFLAGS="${CPPFLAGS}-D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
4012
4013	 cat >conftest.$ac_ext <<_ACEOF
4014#line 4014 "configure"
4015#include "confdefs.h"
4016
4017#include <stdlib.h>
4018#include <string.h>
4019#include <sys/types.h>
4020
4021int
4022main (void)
4023{
4024
4025#ifdef _XOPEN_SOURCE
4026make an error
4027#endif
4028  ;
4029  return 0;
4030}
4031_ACEOF
4032rm -f conftest.$ac_objext
4033if { (eval echo "$as_me:4033: \"$ac_compile\"") >&5
4034  (eval $ac_compile) 2>&5
4035  ac_status=$?
4036  echo "$as_me:4036: \$? = $ac_status" >&5
4037  (exit $ac_status); } &&
4038         { ac_try='test -s conftest.$ac_objext'
4039  { (eval echo "$as_me:4039: \"$ac_try\"") >&5
4040  (eval $ac_try) 2>&5
4041  ac_status=$?
4042  echo "$as_me:4042: \$? = $ac_status" >&5
4043  (exit $ac_status); }; }; then
4044  cf_cv_xopen_source=no
4045else
4046  echo "$as_me: failed program was:" >&5
4047cat conftest.$ac_ext >&5
4048cf_cv_xopen_source=$cf_XOPEN_SOURCE
4049fi
4050rm -f conftest.$ac_objext conftest.$ac_ext
4051	CPPFLAGS="$cf_save"
4052
4053fi
4054rm -f conftest.$ac_objext conftest.$ac_ext
4055
4056fi
4057echo "$as_me:4057: result: $cf_cv_xopen_source" >&5
4058echo "${ECHO_T}$cf_cv_xopen_source" >&6
4059
4060if test "$cf_cv_xopen_source" != no ; then
4061
4062CFLAGS=`echo "$CFLAGS" | \
4063	sed	-e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ 	]*\)\?[ 	]/ /g' \
4064		-e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ 	]*\)\?$//g'`
4065
4066CPPFLAGS=`echo "$CPPFLAGS" | \
4067	sed	-e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ 	]*\)\?[ 	]/ /g' \
4068		-e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ 	]*\)\?$//g'`
4069
4070	cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
4071
4072cf_fix_cppflags=no
4073cf_new_cflags=
4074cf_new_cppflags=
4075cf_new_extra_cppflags=
4076
4077for cf_add_cflags in $cf_temp_xopen_source
4078do
4079case $cf_fix_cppflags in
4080(no)
4081	case $cf_add_cflags in
4082	(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4083		case $cf_add_cflags in
4084		(-D*)
4085			cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4086
4087			test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4088				&& test -z "${cf_tst_cflags}" \
4089				&& cf_fix_cppflags=yes
4090
4091			if test $cf_fix_cppflags = yes ; then
4092
4093	test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4094	cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4095
4096				continue
4097			elif test "${cf_tst_cflags}" = "\"'" ; then
4098
4099	test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4100	cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4101
4102				continue
4103			fi
4104			;;
4105		esac
4106		case "$CPPFLAGS" in
4107		(*$cf_add_cflags)
4108			;;
4109		(*)
4110			case $cf_add_cflags in
4111			(-D*)
4112				cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4113
4114CPPFLAGS=`echo "$CPPFLAGS" | \
4115	sed	-e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ 	]*\)\?[ 	]/ /g' \
4116		-e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ 	]*\)\?$//g'`
4117
4118				;;
4119			esac
4120
4121	test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4122	cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4123
4124			;;
4125		esac
4126		;;
4127	(*)
4128
4129	test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4130	cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4131
4132		;;
4133	esac
4134	;;
4135(yes)
4136
4137	test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4138	cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4139
4140	cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
4141
4142	test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4143		&& test -z "${cf_tst_cflags}" \
4144		&& cf_fix_cppflags=no
4145	;;
4146esac
4147done
4148
4149if test -n "$cf_new_cflags" ; then
4150
4151	test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4152	CFLAGS="${CFLAGS}$cf_new_cflags"
4153
4154fi
4155
4156if test -n "$cf_new_cppflags" ; then
4157
4158	test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4159	CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4160
4161fi
4162
4163if test -n "$cf_new_extra_cppflags" ; then
4164
4165	test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4166	EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4167
4168fi
4169
4170fi
4171
4172cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
4173
4174cf_save_CFLAGS="$CFLAGS"
4175cf_save_CPPFLAGS="$CPPFLAGS"
4176
4177cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
4178	sed	-e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ 	]*\)\?[ 	]/ /g' \
4179		-e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ 	]*\)\?$//g'`
4180
4181cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
4182	sed	-e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ 	]*\)\?[ 	]/ /g' \
4183		-e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ 	]*\)\?$//g'`
4184
4185echo "$as_me:4185: checking if we should define _POSIX_C_SOURCE" >&5
4186echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
4187if test "${cf_cv_posix_c_source+set}" = set; then
4188  echo $ECHO_N "(cached) $ECHO_C" >&6
4189else
4190
4191echo "${as_me:-configure}:4191: testing if the symbol is already defined go no further ..." 1>&5
4192
4193	cat >conftest.$ac_ext <<_ACEOF
4194#line 4194 "configure"
4195#include "confdefs.h"
4196#include <sys/types.h>
4197int
4198main (void)
4199{
4200
4201#ifndef _POSIX_C_SOURCE
4202make an error
4203#endif
4204  ;
4205  return 0;
4206}
4207_ACEOF
4208rm -f conftest.$ac_objext
4209if { (eval echo "$as_me:4209: \"$ac_compile\"") >&5
4210  (eval $ac_compile) 2>&5
4211  ac_status=$?
4212  echo "$as_me:4212: \$? = $ac_status" >&5
4213  (exit $ac_status); } &&
4214         { ac_try='test -s conftest.$ac_objext'
4215  { (eval echo "$as_me:4215: \"$ac_try\"") >&5
4216  (eval $ac_try) 2>&5
4217  ac_status=$?
4218  echo "$as_me:4218: \$? = $ac_status" >&5
4219  (exit $ac_status); }; }; then
4220  cf_cv_posix_c_source=no
4221else
4222  echo "$as_me: failed program was:" >&5
4223cat conftest.$ac_ext >&5
4224cf_want_posix_source=no
4225	 case .$cf_POSIX_C_SOURCE in
4226	 (.[12]??*)
4227		cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
4228		;;
4229	 (.2)
4230		cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
4231		cf_want_posix_source=yes
4232		;;
4233	 (.*)
4234		cf_want_posix_source=yes
4235		;;
4236	 esac
4237	 if test "$cf_want_posix_source" = yes ; then
4238		cat >conftest.$ac_ext <<_ACEOF
4239#line 4239 "configure"
4240#include "confdefs.h"
4241#include <sys/types.h>
4242int
4243main (void)
4244{
4245
4246#ifdef _POSIX_SOURCE
4247make an error
4248#endif
4249  ;
4250  return 0;
4251}
4252_ACEOF
4253rm -f conftest.$ac_objext
4254if { (eval echo "$as_me:4254: \"$ac_compile\"") >&5
4255  (eval $ac_compile) 2>&5
4256  ac_status=$?
4257  echo "$as_me:4257: \$? = $ac_status" >&5
4258  (exit $ac_status); } &&
4259         { ac_try='test -s conftest.$ac_objext'
4260  { (eval echo "$as_me:4260: \"$ac_try\"") >&5
4261  (eval $ac_try) 2>&5
4262  ac_status=$?
4263  echo "$as_me:4263: \$? = $ac_status" >&5
4264  (exit $ac_status); }; }; then
4265  :
4266else
4267  echo "$as_me: failed program was:" >&5
4268cat conftest.$ac_ext >&5
4269cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
4270fi
4271rm -f conftest.$ac_objext conftest.$ac_ext
4272	 fi
4273
4274echo "${as_me:-configure}:4274: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
4275
4276	 CFLAGS="$cf_trim_CFLAGS"
4277	 CPPFLAGS="$cf_trim_CPPFLAGS"
4278
4279	test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4280	CPPFLAGS="${CPPFLAGS}$cf_cv_posix_c_source"
4281
4282echo "${as_me:-configure}:4282: testing if the second compile does not leave our definition intact error ..." 1>&5
4283
4284	 cat >conftest.$ac_ext <<_ACEOF
4285#line 4285 "configure"
4286#include "confdefs.h"
4287#include <sys/types.h>
4288int
4289main (void)
4290{
4291
4292#ifndef _POSIX_C_SOURCE
4293make an error
4294#endif
4295  ;
4296  return 0;
4297}
4298_ACEOF
4299rm -f conftest.$ac_objext
4300if { (eval echo "$as_me:4300: \"$ac_compile\"") >&5
4301  (eval $ac_compile) 2>&5
4302  ac_status=$?
4303  echo "$as_me:4303: \$? = $ac_status" >&5
4304  (exit $ac_status); } &&
4305         { ac_try='test -s conftest.$ac_objext'
4306  { (eval echo "$as_me:4306: \"$ac_try\"") >&5
4307  (eval $ac_try) 2>&5
4308  ac_status=$?
4309  echo "$as_me:4309: \$? = $ac_status" >&5
4310  (exit $ac_status); }; }; then
4311  :
4312else
4313  echo "$as_me: failed program was:" >&5
4314cat conftest.$ac_ext >&5
4315cf_cv_posix_c_source=no
4316fi
4317rm -f conftest.$ac_objext conftest.$ac_ext
4318	 CFLAGS="$cf_save_CFLAGS"
4319	 CPPFLAGS="$cf_save_CPPFLAGS"
4320
4321fi
4322rm -f conftest.$ac_objext conftest.$ac_ext
4323
4324fi
4325echo "$as_me:4325: result: $cf_cv_posix_c_source" >&5
4326echo "${ECHO_T}$cf_cv_posix_c_source" >&6
4327
4328if test "$cf_cv_posix_c_source" != no ; then
4329	CFLAGS="$cf_trim_CFLAGS"
4330	CPPFLAGS="$cf_trim_CPPFLAGS"
4331
4332cf_fix_cppflags=no
4333cf_new_cflags=
4334cf_new_cppflags=
4335cf_new_extra_cppflags=
4336
4337for cf_add_cflags in $cf_cv_posix_c_source
4338do
4339case $cf_fix_cppflags in
4340(no)
4341	case $cf_add_cflags in
4342	(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4343		case $cf_add_cflags in
4344		(-D*)
4345			cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4346
4347			test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4348				&& test -z "${cf_tst_cflags}" \
4349				&& cf_fix_cppflags=yes
4350
4351			if test $cf_fix_cppflags = yes ; then
4352
4353	test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4354	cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4355
4356				continue
4357			elif test "${cf_tst_cflags}" = "\"'" ; then
4358
4359	test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4360	cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4361
4362				continue
4363			fi
4364			;;
4365		esac
4366		case "$CPPFLAGS" in
4367		(*$cf_add_cflags)
4368			;;
4369		(*)
4370			case $cf_add_cflags in
4371			(-D*)
4372				cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4373
4374CPPFLAGS=`echo "$CPPFLAGS" | \
4375	sed	-e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ 	]*\)\?[ 	]/ /g' \
4376		-e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ 	]*\)\?$//g'`
4377
4378				;;
4379			esac
4380
4381	test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4382	cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4383
4384			;;
4385		esac
4386		;;
4387	(*)
4388
4389	test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4390	cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4391
4392		;;
4393	esac
4394	;;
4395(yes)
4396
4397	test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4398	cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4399
4400	cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
4401
4402	test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4403		&& test -z "${cf_tst_cflags}" \
4404		&& cf_fix_cppflags=no
4405	;;
4406esac
4407done
4408
4409if test -n "$cf_new_cflags" ; then
4410
4411	test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4412	CFLAGS="${CFLAGS}$cf_new_cflags"
4413
4414fi
4415
4416if test -n "$cf_new_cppflags" ; then
4417
4418	test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4419	CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4420
4421fi
4422
4423if test -n "$cf_new_extra_cppflags" ; then
4424
4425	test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4426	EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4427
4428fi
4429
4430fi
4431
4432	;;
4433esac
4434
4435if test -n "$cf_xopen_source" ; then
4436
4437cf_fix_cppflags=no
4438cf_new_cflags=
4439cf_new_cppflags=
4440cf_new_extra_cppflags=
4441
4442for cf_add_cflags in $cf_xopen_source
4443do
4444case $cf_fix_cppflags in
4445(no)
4446	case $cf_add_cflags in
4447	(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4448		case $cf_add_cflags in
4449		(-D*)
4450			cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4451
4452			test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4453				&& test -z "${cf_tst_cflags}" \
4454				&& cf_fix_cppflags=yes
4455
4456			if test $cf_fix_cppflags = yes ; then
4457
4458	test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4459	cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4460
4461				continue
4462			elif test "${cf_tst_cflags}" = "\"'" ; then
4463
4464	test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4465	cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4466
4467				continue
4468			fi
4469			;;
4470		esac
4471		case "$CPPFLAGS" in
4472		(*$cf_add_cflags)
4473			;;
4474		(*)
4475			case $cf_add_cflags in
4476			(-D*)
4477				cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4478
4479CPPFLAGS=`echo "$CPPFLAGS" | \
4480	sed	-e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ 	]*\)\?[ 	]/ /g' \
4481		-e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ 	]*\)\?$//g'`
4482
4483				;;
4484			esac
4485
4486	test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4487	cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4488
4489			;;
4490		esac
4491		;;
4492	(*)
4493
4494	test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4495	cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4496
4497		;;
4498	esac
4499	;;
4500(yes)
4501
4502	test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4503	cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4504
4505	cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
4506
4507	test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4508		&& test -z "${cf_tst_cflags}" \
4509		&& cf_fix_cppflags=no
4510	;;
4511esac
4512done
4513
4514if test -n "$cf_new_cflags" ; then
4515	test -n "$verbose" && echo "	add to \$CFLAGS $cf_new_cflags" 1>&6
4516
4517echo "${as_me:-configure}:4517: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
4518
4519	test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4520	CFLAGS="${CFLAGS}$cf_new_cflags"
4521
4522fi
4523
4524if test -n "$cf_new_cppflags" ; then
4525	test -n "$verbose" && echo "	add to \$CPPFLAGS $cf_new_cppflags" 1>&6
4526
4527echo "${as_me:-configure}:4527: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
4528
4529	test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4530	CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4531
4532fi
4533
4534if test -n "$cf_new_extra_cppflags" ; then
4535	test -n "$verbose" && echo "	add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
4536
4537echo "${as_me:-configure}:4537: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
4538
4539	test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4540	EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4541
4542fi
4543
4544fi
4545
4546if test -n "$cf_XOPEN_SOURCE" && test -z "$cf_cv_xopen_source" ; then
4547	echo "$as_me:4547: checking if _XOPEN_SOURCE really is set" >&5
4548echo $ECHO_N "checking if _XOPEN_SOURCE really is set... $ECHO_C" >&6
4549	cat >conftest.$ac_ext <<_ACEOF
4550#line 4550 "configure"
4551#include "confdefs.h"
4552#include <stdlib.h>
4553int
4554main (void)
4555{
4556
4557#ifndef _XOPEN_SOURCE
4558make an error
4559#endif
4560  ;
4561  return 0;
4562}
4563_ACEOF
4564rm -f conftest.$ac_objext
4565if { (eval echo "$as_me:4565: \"$ac_compile\"") >&5
4566  (eval $ac_compile) 2>&5
4567  ac_status=$?
4568  echo "$as_me:4568: \$? = $ac_status" >&5
4569  (exit $ac_status); } &&
4570         { ac_try='test -s conftest.$ac_objext'
4571  { (eval echo "$as_me:4571: \"$ac_try\"") >&5
4572  (eval $ac_try) 2>&5
4573  ac_status=$?
4574  echo "$as_me:4574: \$? = $ac_status" >&5
4575  (exit $ac_status); }; }; then
4576  cf_XOPEN_SOURCE_set=yes
4577else
4578  echo "$as_me: failed program was:" >&5
4579cat conftest.$ac_ext >&5
4580cf_XOPEN_SOURCE_set=no
4581fi
4582rm -f conftest.$ac_objext conftest.$ac_ext
4583	echo "$as_me:4583: result: $cf_XOPEN_SOURCE_set" >&5
4584echo "${ECHO_T}$cf_XOPEN_SOURCE_set" >&6
4585	if test $cf_XOPEN_SOURCE_set = yes
4586	then
4587		cat >conftest.$ac_ext <<_ACEOF
4588#line 4588 "configure"
4589#include "confdefs.h"
4590#include <stdlib.h>
4591int
4592main (void)
4593{
4594
4595#if (_XOPEN_SOURCE - 0) < $cf_XOPEN_SOURCE
4596make an error
4597#endif
4598  ;
4599  return 0;
4600}
4601_ACEOF
4602rm -f conftest.$ac_objext
4603if { (eval echo "$as_me:4603: \"$ac_compile\"") >&5
4604  (eval $ac_compile) 2>&5
4605  ac_status=$?
4606  echo "$as_me:4606: \$? = $ac_status" >&5
4607  (exit $ac_status); } &&
4608         { ac_try='test -s conftest.$ac_objext'
4609  { (eval echo "$as_me:4609: \"$ac_try\"") >&5
4610  (eval $ac_try) 2>&5
4611  ac_status=$?
4612  echo "$as_me:4612: \$? = $ac_status" >&5
4613  (exit $ac_status); }; }; then
4614  cf_XOPEN_SOURCE_set_ok=yes
4615else
4616  echo "$as_me: failed program was:" >&5
4617cat conftest.$ac_ext >&5
4618cf_XOPEN_SOURCE_set_ok=no
4619fi
4620rm -f conftest.$ac_objext conftest.$ac_ext
4621		if test $cf_XOPEN_SOURCE_set_ok = no
4622		then
4623			{ echo "$as_me:4623: WARNING: _XOPEN_SOURCE is lower than requested" >&5
4624echo "$as_me: WARNING: _XOPEN_SOURCE is lower than requested" >&2;}
4625		fi
4626	else
4627
4628echo "$as_me:4628: checking if we should define _XOPEN_SOURCE" >&5
4629echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
4630if test "${cf_cv_xopen_source+set}" = set; then
4631  echo $ECHO_N "(cached) $ECHO_C" >&6
4632else
4633
4634	cat >conftest.$ac_ext <<_ACEOF
4635#line 4635 "configure"
4636#include "confdefs.h"
4637
4638#include <stdlib.h>
4639#include <string.h>
4640#include <sys/types.h>
4641
4642int
4643main (void)
4644{
4645
4646#ifndef _XOPEN_SOURCE
4647make an error
4648#endif
4649  ;
4650  return 0;
4651}
4652_ACEOF
4653rm -f conftest.$ac_objext
4654if { (eval echo "$as_me:4654: \"$ac_compile\"") >&5
4655  (eval $ac_compile) 2>&5
4656  ac_status=$?
4657  echo "$as_me:4657: \$? = $ac_status" >&5
4658  (exit $ac_status); } &&
4659         { ac_try='test -s conftest.$ac_objext'
4660  { (eval echo "$as_me:4660: \"$ac_try\"") >&5
4661  (eval $ac_try) 2>&5
4662  ac_status=$?
4663  echo "$as_me:4663: \$? = $ac_status" >&5
4664  (exit $ac_status); }; }; then
4665  cf_cv_xopen_source=no
4666else
4667  echo "$as_me: failed program was:" >&5
4668cat conftest.$ac_ext >&5
4669cf_save="$CPPFLAGS"
4670
4671	test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4672	CPPFLAGS="${CPPFLAGS}-D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
4673
4674	 cat >conftest.$ac_ext <<_ACEOF
4675#line 4675 "configure"
4676#include "confdefs.h"
4677
4678#include <stdlib.h>
4679#include <string.h>
4680#include <sys/types.h>
4681
4682int
4683main (void)
4684{
4685
4686#ifdef _XOPEN_SOURCE
4687make an error
4688#endif
4689  ;
4690  return 0;
4691}
4692_ACEOF
4693rm -f conftest.$ac_objext
4694if { (eval echo "$as_me:4694: \"$ac_compile\"") >&5
4695  (eval $ac_compile) 2>&5
4696  ac_status=$?
4697  echo "$as_me:4697: \$? = $ac_status" >&5
4698  (exit $ac_status); } &&
4699         { ac_try='test -s conftest.$ac_objext'
4700  { (eval echo "$as_me:4700: \"$ac_try\"") >&5
4701  (eval $ac_try) 2>&5
4702  ac_status=$?
4703  echo "$as_me:4703: \$? = $ac_status" >&5
4704  (exit $ac_status); }; }; then
4705  cf_cv_xopen_source=no
4706else
4707  echo "$as_me: failed program was:" >&5
4708cat conftest.$ac_ext >&5
4709cf_cv_xopen_source=$cf_XOPEN_SOURCE
4710fi
4711rm -f conftest.$ac_objext conftest.$ac_ext
4712	CPPFLAGS="$cf_save"
4713
4714fi
4715rm -f conftest.$ac_objext conftest.$ac_ext
4716
4717fi
4718echo "$as_me:4718: result: $cf_cv_xopen_source" >&5
4719echo "${ECHO_T}$cf_cv_xopen_source" >&6
4720
4721if test "$cf_cv_xopen_source" != no ; then
4722
4723CFLAGS=`echo "$CFLAGS" | \
4724	sed	-e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ 	]*\)\?[ 	]/ /g' \
4725		-e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ 	]*\)\?$//g'`
4726
4727CPPFLAGS=`echo "$CPPFLAGS" | \
4728	sed	-e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ 	]*\)\?[ 	]/ /g' \
4729		-e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ 	]*\)\?$//g'`
4730
4731	cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
4732
4733cf_fix_cppflags=no
4734cf_new_cflags=
4735cf_new_cppflags=
4736cf_new_extra_cppflags=
4737
4738for cf_add_cflags in $cf_temp_xopen_source
4739do
4740case $cf_fix_cppflags in
4741(no)
4742	case $cf_add_cflags in
4743	(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4744		case $cf_add_cflags in
4745		(-D*)
4746			cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4747
4748			test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4749				&& test -z "${cf_tst_cflags}" \
4750				&& cf_fix_cppflags=yes
4751
4752			if test $cf_fix_cppflags = yes ; then
4753
4754	test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4755	cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4756
4757				continue
4758			elif test "${cf_tst_cflags}" = "\"'" ; then
4759
4760	test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4761	cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4762
4763				continue
4764			fi
4765			;;
4766		esac
4767		case "$CPPFLAGS" in
4768		(*$cf_add_cflags)
4769			;;
4770		(*)
4771			case $cf_add_cflags in
4772			(-D*)
4773				cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4774
4775CPPFLAGS=`echo "$CPPFLAGS" | \
4776	sed	-e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ 	]*\)\?[ 	]/ /g' \
4777		-e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ 	]*\)\?$//g'`
4778
4779				;;
4780			esac
4781
4782	test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4783	cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4784
4785			;;
4786		esac
4787		;;
4788	(*)
4789
4790	test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4791	cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4792
4793		;;
4794	esac
4795	;;
4796(yes)
4797
4798	test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4799	cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4800
4801	cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
4802
4803	test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4804		&& test -z "${cf_tst_cflags}" \
4805		&& cf_fix_cppflags=no
4806	;;
4807esac
4808done
4809
4810if test -n "$cf_new_cflags" ; then
4811
4812	test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4813	CFLAGS="${CFLAGS}$cf_new_cflags"
4814
4815fi
4816
4817if test -n "$cf_new_cppflags" ; then
4818
4819	test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4820	CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4821
4822fi
4823
4824if test -n "$cf_new_extra_cppflags" ; then
4825
4826	test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4827	EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4828
4829fi
4830
4831fi
4832
4833	fi
4834fi
4835
4836# Check whether --enable-largefile or --disable-largefile was given.
4837if test "${enable_largefile+set}" = set; then
4838  enableval="$enable_largefile"
4839
4840fi;
4841if test "$enable_largefile" != no; then
4842
4843  echo "$as_me:4843: checking for special C compiler options needed for large files" >&5
4844echo $ECHO_N "checking for special C compiler options needed for large files... $ECHO_C" >&6
4845if test "${ac_cv_sys_largefile_CC+set}" = set; then
4846  echo $ECHO_N "(cached) $ECHO_C" >&6
4847else
4848  ac_cv_sys_largefile_CC=no
4849     if test "$GCC" != yes; then
4850       ac_save_CC=$CC
4851       while :; do
4852     	 # IRIX 6.2 and later do not support large files by default,
4853     	 # so use the C compiler's -n32 option if that helps.
4854         cat >conftest.$ac_ext <<_ACEOF
4855#line 4855 "configure"
4856#include "confdefs.h"
4857#include <sys/types.h>
4858 /* Check that off_t can represent 2**63 - 1 correctly.
4859    We can't simply define LARGE_OFF_T to be 9223372036854775807,
4860    since some C++ compilers masquerading as C compilers
4861    incorrectly reject 9223372036854775807.  */
4862#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4863  int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4864		       && LARGE_OFF_T % 2147483647 == 1)
4865		      ? 1 : -1];
4866int
4867main (void)
4868{
4869
4870  ;
4871  return 0;
4872}
4873_ACEOF
4874     	 rm -f conftest.$ac_objext
4875if { (eval echo "$as_me:4875: \"$ac_compile\"") >&5
4876  (eval $ac_compile) 2>&5
4877  ac_status=$?
4878  echo "$as_me:4878: \$? = $ac_status" >&5
4879  (exit $ac_status); } &&
4880         { ac_try='test -s conftest.$ac_objext'
4881  { (eval echo "$as_me:4881: \"$ac_try\"") >&5
4882  (eval $ac_try) 2>&5
4883  ac_status=$?
4884  echo "$as_me:4884: \$? = $ac_status" >&5
4885  (exit $ac_status); }; }; then
4886  break
4887else
4888  echo "$as_me: failed program was:" >&5
4889cat conftest.$ac_ext >&5
4890fi
4891rm -f conftest.$ac_objext
4892     	 CC="$CC -n32"
4893     	 rm -f conftest.$ac_objext
4894if { (eval echo "$as_me:4894: \"$ac_compile\"") >&5
4895  (eval $ac_compile) 2>&5
4896  ac_status=$?
4897  echo "$as_me:4897: \$? = $ac_status" >&5
4898  (exit $ac_status); } &&
4899         { ac_try='test -s conftest.$ac_objext'
4900  { (eval echo "$as_me:4900: \"$ac_try\"") >&5
4901  (eval $ac_try) 2>&5
4902  ac_status=$?
4903  echo "$as_me:4903: \$? = $ac_status" >&5
4904  (exit $ac_status); }; }; then
4905  ac_cv_sys_largefile_CC=' -n32'; break
4906else
4907  echo "$as_me: failed program was:" >&5
4908cat conftest.$ac_ext >&5
4909fi
4910rm -f conftest.$ac_objext
4911         break
4912       done
4913       CC=$ac_save_CC
4914       rm -f conftest.$ac_ext
4915    fi
4916fi
4917echo "$as_me:4917: result: $ac_cv_sys_largefile_CC" >&5
4918echo "${ECHO_T}$ac_cv_sys_largefile_CC" >&6
4919  if test "$ac_cv_sys_largefile_CC" != no; then
4920    CC=$CC$ac_cv_sys_largefile_CC
4921  fi
4922
4923  echo "$as_me:4923: checking for _FILE_OFFSET_BITS value needed for large files" >&5
4924echo $ECHO_N "checking for _FILE_OFFSET_BITS value needed for large files... $ECHO_C" >&6
4925if test "${ac_cv_sys_file_offset_bits+set}" = set; then
4926  echo $ECHO_N "(cached) $ECHO_C" >&6
4927else
4928  while :; do
4929  ac_cv_sys_file_offset_bits=no
4930  cat >conftest.$ac_ext <<_ACEOF
4931#line 4931 "configure"
4932#include "confdefs.h"
4933#include <sys/types.h>
4934 /* Check that off_t can represent 2**63 - 1 correctly.
4935    We can't simply define LARGE_OFF_T to be 9223372036854775807,
4936    since some C++ compilers masquerading as C compilers
4937    incorrectly reject 9223372036854775807.  */
4938#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4939  int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4940		       && LARGE_OFF_T % 2147483647 == 1)
4941		      ? 1 : -1];
4942int
4943main (void)
4944{
4945
4946  ;
4947  return 0;
4948}
4949_ACEOF
4950rm -f conftest.$ac_objext
4951if { (eval echo "$as_me:4951: \"$ac_compile\"") >&5
4952  (eval $ac_compile) 2>&5
4953  ac_status=$?
4954  echo "$as_me:4954: \$? = $ac_status" >&5
4955  (exit $ac_status); } &&
4956         { ac_try='test -s conftest.$ac_objext'
4957  { (eval echo "$as_me:4957: \"$ac_try\"") >&5
4958  (eval $ac_try) 2>&5
4959  ac_status=$?
4960  echo "$as_me:4960: \$? = $ac_status" >&5
4961  (exit $ac_status); }; }; then
4962  break
4963else
4964  echo "$as_me: failed program was:" >&5
4965cat conftest.$ac_ext >&5
4966fi
4967rm -f conftest.$ac_objext conftest.$ac_ext
4968  cat >conftest.$ac_ext <<_ACEOF
4969#line 4969 "configure"
4970#include "confdefs.h"
4971#define _FILE_OFFSET_BITS 64
4972#include <sys/types.h>
4973 /* Check that off_t can represent 2**63 - 1 correctly.
4974    We can't simply define LARGE_OFF_T to be 9223372036854775807,
4975    since some C++ compilers masquerading as C compilers
4976    incorrectly reject 9223372036854775807.  */
4977#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4978  int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4979		       && LARGE_OFF_T % 2147483647 == 1)
4980		      ? 1 : -1];
4981int
4982main (void)
4983{
4984
4985  ;
4986  return 0;
4987}
4988_ACEOF
4989rm -f conftest.$ac_objext
4990if { (eval echo "$as_me:4990: \"$ac_compile\"") >&5
4991  (eval $ac_compile) 2>&5
4992  ac_status=$?
4993  echo "$as_me:4993: \$? = $ac_status" >&5
4994  (exit $ac_status); } &&
4995         { ac_try='test -s conftest.$ac_objext'
4996  { (eval echo "$as_me:4996: \"$ac_try\"") >&5
4997  (eval $ac_try) 2>&5
4998  ac_status=$?
4999  echo "$as_me:4999: \$? = $ac_status" >&5
5000  (exit $ac_status); }; }; then
5001  ac_cv_sys_file_offset_bits=64; break
5002else
5003  echo "$as_me: failed program was:" >&5
5004cat conftest.$ac_ext >&5
5005fi
5006rm -f conftest.$ac_objext conftest.$ac_ext
5007  break
5008done
5009fi
5010echo "$as_me:5010: result: $ac_cv_sys_file_offset_bits" >&5
5011echo "${ECHO_T}$ac_cv_sys_file_offset_bits" >&6
5012if test "$ac_cv_sys_file_offset_bits" != no; then
5013
5014cat >>confdefs.h <<EOF
5015#define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
5016EOF
5017
5018fi
5019rm -rf conftest*
5020  echo "$as_me:5020: checking for _LARGE_FILES value needed for large files" >&5
5021echo $ECHO_N "checking for _LARGE_FILES value needed for large files... $ECHO_C" >&6
5022if test "${ac_cv_sys_large_files+set}" = set; then
5023  echo $ECHO_N "(cached) $ECHO_C" >&6
5024else
5025  while :; do
5026  ac_cv_sys_large_files=no
5027  cat >conftest.$ac_ext <<_ACEOF
5028#line 5028 "configure"
5029#include "confdefs.h"
5030#include <sys/types.h>
5031 /* Check that off_t can represent 2**63 - 1 correctly.
5032    We can't simply define LARGE_OFF_T to be 9223372036854775807,
5033    since some C++ compilers masquerading as C compilers
5034    incorrectly reject 9223372036854775807.  */
5035#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5036  int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5037		       && LARGE_OFF_T % 2147483647 == 1)
5038		      ? 1 : -1];
5039int
5040main (void)
5041{
5042
5043  ;
5044  return 0;
5045}
5046_ACEOF
5047rm -f conftest.$ac_objext
5048if { (eval echo "$as_me:5048: \"$ac_compile\"") >&5
5049  (eval $ac_compile) 2>&5
5050  ac_status=$?
5051  echo "$as_me:5051: \$? = $ac_status" >&5
5052  (exit $ac_status); } &&
5053         { ac_try='test -s conftest.$ac_objext'
5054  { (eval echo "$as_me:5054: \"$ac_try\"") >&5
5055  (eval $ac_try) 2>&5
5056  ac_status=$?
5057  echo "$as_me:5057: \$? = $ac_status" >&5
5058  (exit $ac_status); }; }; then
5059  break
5060else
5061  echo "$as_me: failed program was:" >&5
5062cat conftest.$ac_ext >&5
5063fi
5064rm -f conftest.$ac_objext conftest.$ac_ext
5065  cat >conftest.$ac_ext <<_ACEOF
5066#line 5066 "configure"
5067#include "confdefs.h"
5068#define _LARGE_FILES 1
5069#include <sys/types.h>
5070 /* Check that off_t can represent 2**63 - 1 correctly.
5071    We can't simply define LARGE_OFF_T to be 9223372036854775807,
5072    since some C++ compilers masquerading as C compilers
5073    incorrectly reject 9223372036854775807.  */
5074#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5075  int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5076		       && LARGE_OFF_T % 2147483647 == 1)
5077		      ? 1 : -1];
5078int
5079main (void)
5080{
5081
5082  ;
5083  return 0;
5084}
5085_ACEOF
5086rm -f conftest.$ac_objext
5087if { (eval echo "$as_me:5087: \"$ac_compile\"") >&5
5088  (eval $ac_compile) 2>&5
5089  ac_status=$?
5090  echo "$as_me:5090: \$? = $ac_status" >&5
5091  (exit $ac_status); } &&
5092         { ac_try='test -s conftest.$ac_objext'
5093  { (eval echo "$as_me:5093: \"$ac_try\"") >&5
5094  (eval $ac_try) 2>&5
5095  ac_status=$?
5096  echo "$as_me:5096: \$? = $ac_status" >&5
5097  (exit $ac_status); }; }; then
5098  ac_cv_sys_large_files=1; break
5099else
5100  echo "$as_me: failed program was:" >&5
5101cat conftest.$ac_ext >&5
5102fi
5103rm -f conftest.$ac_objext conftest.$ac_ext
5104  break
5105done
5106fi
5107echo "$as_me:5107: result: $ac_cv_sys_large_files" >&5
5108echo "${ECHO_T}$ac_cv_sys_large_files" >&6
5109if test "$ac_cv_sys_large_files" != no; then
5110
5111cat >>confdefs.h <<EOF
5112#define _LARGE_FILES $ac_cv_sys_large_files
5113EOF
5114
5115fi
5116rm -rf conftest*
5117fi
5118
5119	if test "$enable_largefile" != no ; then
5120	echo "$as_me:5120: checking for _LARGEFILE_SOURCE value needed for large files" >&5
5121echo $ECHO_N "checking for _LARGEFILE_SOURCE value needed for large files... $ECHO_C" >&6
5122if test "${ac_cv_sys_largefile_source+set}" = set; then
5123  echo $ECHO_N "(cached) $ECHO_C" >&6
5124else
5125  while :; do
5126  ac_cv_sys_largefile_source=no
5127  cat >conftest.$ac_ext <<_ACEOF
5128#line 5128 "configure"
5129#include "confdefs.h"
5130#include <stdio.h>
5131int
5132main (void)
5133{
5134return !fseeko;
5135  ;
5136  return 0;
5137}
5138_ACEOF
5139rm -f conftest.$ac_objext
5140if { (eval echo "$as_me:5140: \"$ac_compile\"") >&5
5141  (eval $ac_compile) 2>&5
5142  ac_status=$?
5143  echo "$as_me:5143: \$? = $ac_status" >&5
5144  (exit $ac_status); } &&
5145         { ac_try='test -s conftest.$ac_objext'
5146  { (eval echo "$as_me:5146: \"$ac_try\"") >&5
5147  (eval $ac_try) 2>&5
5148  ac_status=$?
5149  echo "$as_me:5149: \$? = $ac_status" >&5
5150  (exit $ac_status); }; }; then
5151  break
5152else
5153  echo "$as_me: failed program was:" >&5
5154cat conftest.$ac_ext >&5
5155fi
5156rm -f conftest.$ac_objext conftest.$ac_ext
5157  cat >conftest.$ac_ext <<_ACEOF
5158#line 5158 "configure"
5159#include "confdefs.h"
5160#define _LARGEFILE_SOURCE 1
5161#include <stdio.h>
5162int
5163main (void)
5164{
5165return !fseeko;
5166  ;
5167  return 0;
5168}
5169_ACEOF
5170rm -f conftest.$ac_objext
5171if { (eval echo "$as_me:5171: \"$ac_compile\"") >&5
5172  (eval $ac_compile) 2>&5
5173  ac_status=$?
5174  echo "$as_me:5174: \$? = $ac_status" >&5
5175  (exit $ac_status); } &&
5176         { ac_try='test -s conftest.$ac_objext'
5177  { (eval echo "$as_me:5177: \"$ac_try\"") >&5
5178  (eval $ac_try) 2>&5
5179  ac_status=$?
5180  echo "$as_me:5180: \$? = $ac_status" >&5
5181  (exit $ac_status); }; }; then
5182  ac_cv_sys_largefile_source=1; break
5183else
5184  echo "$as_me: failed program was:" >&5
5185cat conftest.$ac_ext >&5
5186fi
5187rm -f conftest.$ac_objext conftest.$ac_ext
5188  break
5189done
5190fi
5191echo "$as_me:5191: result: $ac_cv_sys_largefile_source" >&5
5192echo "${ECHO_T}$ac_cv_sys_largefile_source" >&6
5193if test "$ac_cv_sys_largefile_source" != no; then
5194
5195cat >>confdefs.h <<EOF
5196#define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
5197EOF
5198
5199fi
5200rm -rf conftest*
5201
5202# We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
5203# in glibc 2.1.3, but that breaks too many other things.
5204# If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
5205echo "$as_me:5205: checking for fseeko" >&5
5206echo $ECHO_N "checking for fseeko... $ECHO_C" >&6
5207if test "${ac_cv_func_fseeko+set}" = set; then
5208  echo $ECHO_N "(cached) $ECHO_C" >&6
5209else
5210  cat >conftest.$ac_ext <<_ACEOF
5211#line 5211 "configure"
5212#include "confdefs.h"
5213#include <stdio.h>
5214int
5215main (void)
5216{
5217return fseeko && fseeko (stdin, 0, 0);
5218  ;
5219  return 0;
5220}
5221_ACEOF
5222rm -f conftest.$ac_objext conftest$ac_exeext
5223if { (eval echo "$as_me:5223: \"$ac_link\"") >&5
5224  (eval $ac_link) 2>&5
5225  ac_status=$?
5226  echo "$as_me:5226: \$? = $ac_status" >&5
5227  (exit $ac_status); } &&
5228         { ac_try='test -s conftest$ac_exeext'
5229  { (eval echo "$as_me:5229: \"$ac_try\"") >&5
5230  (eval $ac_try) 2>&5
5231  ac_status=$?
5232  echo "$as_me:5232: \$? = $ac_status" >&5
5233  (exit $ac_status); }; }; then
5234  ac_cv_func_fseeko=yes
5235else
5236  echo "$as_me: failed program was:" >&5
5237cat conftest.$ac_ext >&5
5238ac_cv_func_fseeko=no
5239fi
5240rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5241fi
5242echo "$as_me:5242: result: $ac_cv_func_fseeko" >&5
5243echo "${ECHO_T}$ac_cv_func_fseeko" >&6
5244if test $ac_cv_func_fseeko = yes; then
5245
5246cat >>confdefs.h <<\EOF
5247#define HAVE_FSEEKO 1
5248EOF
5249
5250fi
5251
5252	# Normally we would collect these definitions in the config.h,
5253	# but (like _XOPEN_SOURCE), some environments rely on having these
5254	# defined before any of the system headers are included.  Another
5255	# case comes up with C++, e.g., on AIX the compiler compiles the
5256	# header files by themselves before looking at the body files it is
5257	# told to compile.  For ncurses, those header files do not include
5258	# the config.h
5259	if test "$ac_cv_sys_large_files" != no
5260	then
5261
5262	test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5263	CPPFLAGS="${CPPFLAGS}-D_LARGE_FILES"
5264
5265	fi
5266	if test "$ac_cv_sys_largefile_source" != no
5267	then
5268
5269	test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5270	CPPFLAGS="${CPPFLAGS}-D_LARGEFILE_SOURCE"
5271
5272	fi
5273	if test "$ac_cv_sys_file_offset_bits" != no
5274	then
5275
5276	test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5277	CPPFLAGS="${CPPFLAGS}-D_FILE_OFFSET_BITS=$ac_cv_sys_file_offset_bits"
5278
5279	fi
5280
5281	echo "$as_me:5281: checking whether to use struct dirent64" >&5
5282echo $ECHO_N "checking whether to use struct dirent64... $ECHO_C" >&6
5283if test "${cf_cv_struct_dirent64+set}" = set; then
5284  echo $ECHO_N "(cached) $ECHO_C" >&6
5285else
5286
5287		cat >conftest.$ac_ext <<_ACEOF
5288#line 5288 "configure"
5289#include "confdefs.h"
5290
5291#pragma GCC diagnostic error "-Wincompatible-pointer-types"
5292#include <sys/types.h>
5293#include <dirent.h>
5294
5295int
5296main (void)
5297{
5298
5299		/* if transitional largefile support is setup, this is true */
5300		extern struct dirent64 * readdir(DIR *);
5301		struct dirent64 *x = readdir((DIR *)0);
5302		struct dirent *y = readdir((DIR *)0);
5303		int z = x - y;
5304
5305  ;
5306  return 0;
5307}
5308_ACEOF
5309rm -f conftest.$ac_objext
5310if { (eval echo "$as_me:5310: \"$ac_compile\"") >&5
5311  (eval $ac_compile) 2>&5
5312  ac_status=$?
5313  echo "$as_me:5313: \$? = $ac_status" >&5
5314  (exit $ac_status); } &&
5315         { ac_try='test -s conftest.$ac_objext'
5316  { (eval echo "$as_me:5316: \"$ac_try\"") >&5
5317  (eval $ac_try) 2>&5
5318  ac_status=$?
5319  echo "$as_me:5319: \$? = $ac_status" >&5
5320  (exit $ac_status); }; }; then
5321  cf_cv_struct_dirent64=yes
5322else
5323  echo "$as_me: failed program was:" >&5
5324cat conftest.$ac_ext >&5
5325cf_cv_struct_dirent64=no
5326fi
5327rm -f conftest.$ac_objext conftest.$ac_ext
5328
5329fi
5330echo "$as_me:5330: result: $cf_cv_struct_dirent64" >&5
5331echo "${ECHO_T}$cf_cv_struct_dirent64" >&6
5332	test "$cf_cv_struct_dirent64" = yes &&
5333cat >>confdefs.h <<\EOF
5334#define HAVE_STRUCT_DIRENT64 1
5335EOF
5336
5337	fi
5338
5339echo "$as_me:5339: checking for install-prefix" >&5
5340echo $ECHO_N "checking for install-prefix... $ECHO_C" >&6
5341
5342# Check whether --with-install-prefix or --without-install-prefix was given.
5343if test "${with_install_prefix+set}" = set; then
5344  withval="$with_install_prefix"
5345  cf_opt_with_install_prefix=$withval
5346else
5347  cf_opt_with_install_prefix=${DESTDIR:-no}
5348fi;
5349echo "$as_me:5349: result: $cf_opt_with_install_prefix" >&5
5350echo "${ECHO_T}$cf_opt_with_install_prefix" >&6
5351if test "$cf_opt_with_install_prefix" != no ; then
5352
5353if test "x$prefix" != xNONE; then
5354	cf_path_syntax="$prefix"
5355else
5356	cf_path_syntax="$ac_default_prefix"
5357fi
5358
5359case ".$cf_opt_with_install_prefix" in
5360(.\$\(*\)*|.\'*\'*)
5361	;;
5362(..|./*|.\\*)
5363	;;
5364(.[a-zA-Z]:[\\/]*) # OS/2 EMX
5365	;;
5366(.\${*prefix}*|.\${*dir}*)
5367	eval cf_opt_with_install_prefix="$cf_opt_with_install_prefix"
5368	case ".$cf_opt_with_install_prefix" in
5369	(.NONE/*)
5370		cf_opt_with_install_prefix=`echo $cf_opt_with_install_prefix | sed -e s%NONE%$cf_path_syntax%`
5371		;;
5372	esac
5373	;;
5374(.no|.NONE/*)
5375	cf_opt_with_install_prefix=`echo $cf_opt_with_install_prefix | sed -e s%NONE%$cf_path_syntax%`
5376	;;
5377(*)
5378	{ { echo "$as_me:5378: error: expected a pathname, not \"$cf_opt_with_install_prefix\"" >&5
5379echo "$as_me: error: expected a pathname, not \"$cf_opt_with_install_prefix\"" >&2;}
5380   { (exit 1); exit 1; }; }
5381	;;
5382esac
5383
5384	DESTDIR=$cf_opt_with_install_prefix
5385fi
5386
5387if ( test "$GCC" = yes || test "$GXX" = yes )
5388then
5389echo "$as_me:5389: checking if you want to check for gcc warnings" >&5
5390echo $ECHO_N "checking if you want to check for gcc warnings... $ECHO_C" >&6
5391
5392# Check whether --with-warnings or --without-warnings was given.
5393if test "${with_warnings+set}" = set; then
5394  withval="$with_warnings"
5395  cf_opt_with_warnings=$withval
5396else
5397  cf_opt_with_warnings=no
5398fi;
5399echo "$as_me:5399: result: $cf_opt_with_warnings" >&5
5400echo "${ECHO_T}$cf_opt_with_warnings" >&6
5401if test "$cf_opt_with_warnings" != no ; then
5402
5403if test "$GCC" = yes
5404then
5405cat > conftest.i <<EOF
5406#ifndef GCC_PRINTF
5407#define GCC_PRINTF 0
5408#endif
5409#ifndef GCC_SCANF
5410#define GCC_SCANF 0
5411#endif
5412#ifndef GCC_NORETURN
5413#define GCC_NORETURN /* nothing */
5414#endif
5415#ifndef GCC_UNUSED
5416#define GCC_UNUSED /* nothing */
5417#endif
5418EOF
5419if test "$GCC" = yes
5420then
5421	{ echo "$as_me:5421: checking for $CC __attribute__ directives..." >&5
5422echo "$as_me: checking for $CC __attribute__ directives..." >&6;}
5423cat > conftest.$ac_ext <<EOF
5424#line 5424 "${as_me:-configure}"
5425#include "confdefs.h"
5426#include "conftest.h"
5427#include "conftest.i"
5428#if	GCC_PRINTF
5429#define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
5430#else
5431#define GCC_PRINTFLIKE(fmt,var) /*nothing*/
5432#endif
5433#if	GCC_SCANF
5434#define GCC_SCANFLIKE(fmt,var)  __attribute__((format(scanf,fmt,var)))
5435#else
5436#define GCC_SCANFLIKE(fmt,var)  /*nothing*/
5437#endif
5438extern void wow(char *,...) GCC_SCANFLIKE(1,2);
5439extern void oops(char *,...) GCC_PRINTFLIKE(1,2) GCC_NORETURN;
5440extern void foo(void) GCC_NORETURN;
5441int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { return 0; }
5442EOF
5443	cf_printf_attribute=no
5444	cf_scanf_attribute=no
5445	for cf_attribute in scanf printf unused noreturn
5446	do
5447
5448cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
5449
5450		cf_directive="__attribute__(($cf_attribute))"
5451		echo "checking for $CC $cf_directive" 1>&5
5452
5453		case $cf_attribute in
5454		(printf)
5455			cf_printf_attribute=yes
5456			cat >conftest.h <<EOF
5457#define GCC_$cf_ATTRIBUTE 1
5458EOF
5459			;;
5460		(scanf)
5461			cf_scanf_attribute=yes
5462			cat >conftest.h <<EOF
5463#define GCC_$cf_ATTRIBUTE 1
5464EOF
5465			;;
5466		(*)
5467			cat >conftest.h <<EOF
5468#define GCC_$cf_ATTRIBUTE $cf_directive
5469EOF
5470			;;
5471		esac
5472
5473		if { (eval echo "$as_me:5473: \"$ac_compile\"") >&5
5474  (eval $ac_compile) 2>&5
5475  ac_status=$?
5476  echo "$as_me:5476: \$? = $ac_status" >&5
5477  (exit $ac_status); }; then
5478			test -n "$verbose" && echo "$as_me:5478: result: ... $cf_attribute" >&5
5479echo "${ECHO_T}... $cf_attribute" >&6
5480			cat conftest.h >>confdefs.h
5481			case $cf_attribute in
5482			(noreturn)
5483
5484cat >>confdefs.h <<EOF
5485#define GCC_NORETURN $cf_directive
5486EOF
5487
5488				;;
5489			(printf)
5490				cf_value='/* nothing */'
5491				if test "$cf_printf_attribute" != no ; then
5492					cf_value='__attribute__((format(printf,fmt,var)))'
5493
5494cat >>confdefs.h <<\EOF
5495#define GCC_PRINTF 1
5496EOF
5497
5498				fi
5499
5500cat >>confdefs.h <<EOF
5501#define GCC_PRINTFLIKE(fmt,var) $cf_value
5502EOF
5503
5504				;;
5505			(scanf)
5506				cf_value='/* nothing */'
5507				if test "$cf_scanf_attribute" != no ; then
5508					cf_value='__attribute__((format(scanf,fmt,var)))'
5509
5510cat >>confdefs.h <<\EOF
5511#define GCC_SCANF 1
5512EOF
5513
5514				fi
5515
5516cat >>confdefs.h <<EOF
5517#define GCC_SCANFLIKE(fmt,var) $cf_value
5518EOF
5519
5520				;;
5521			(unused)
5522
5523cat >>confdefs.h <<EOF
5524#define GCC_UNUSED $cf_directive
5525EOF
5526
5527				;;
5528			esac
5529		fi
5530	done
5531else
5532	fgrep define conftest.i >>confdefs.h
5533fi
5534rm -rf conftest*
5535fi
5536
5537INTEL_COMPILER=no
5538
5539if test "$GCC" = yes ; then
5540	case $host_os in
5541	(linux*|gnu*)
5542		echo "$as_me:5542: checking if this is really Intel C compiler" >&5
5543echo $ECHO_N "checking if this is really Intel C compiler... $ECHO_C" >&6
5544		cf_save_CFLAGS="$CFLAGS"
5545		CFLAGS="$CFLAGS -no-gcc"
5546		cat >conftest.$ac_ext <<_ACEOF
5547#line 5547 "configure"
5548#include "confdefs.h"
5549
5550int
5551main (void)
5552{
5553
5554#ifdef __INTEL_COMPILER
5555#else
5556make an error
5557#endif
5558
5559  ;
5560  return 0;
5561}
5562_ACEOF
5563rm -f conftest.$ac_objext
5564if { (eval echo "$as_me:5564: \"$ac_compile\"") >&5
5565  (eval $ac_compile) 2>&5
5566  ac_status=$?
5567  echo "$as_me:5567: \$? = $ac_status" >&5
5568  (exit $ac_status); } &&
5569         { ac_try='test -s conftest.$ac_objext'
5570  { (eval echo "$as_me:5570: \"$ac_try\"") >&5
5571  (eval $ac_try) 2>&5
5572  ac_status=$?
5573  echo "$as_me:5573: \$? = $ac_status" >&5
5574  (exit $ac_status); }; }; then
5575  INTEL_COMPILER=yes
5576cf_save_CFLAGS="$cf_save_CFLAGS -we147"
5577
5578else
5579  echo "$as_me: failed program was:" >&5
5580cat conftest.$ac_ext >&5
5581fi
5582rm -f conftest.$ac_objext conftest.$ac_ext
5583		CFLAGS="$cf_save_CFLAGS"
5584		echo "$as_me:5584: result: $INTEL_COMPILER" >&5
5585echo "${ECHO_T}$INTEL_COMPILER" >&6
5586		;;
5587	esac
5588fi
5589
5590CLANG_COMPILER=no
5591
5592if test "$GCC" = yes ; then
5593	echo "$as_me:5593: checking if this is really Clang C compiler" >&5
5594echo $ECHO_N "checking if this is really Clang C compiler... $ECHO_C" >&6
5595	cf_save_CFLAGS="$CFLAGS"
5596	CFLAGS="$CFLAGS -Qunused-arguments"
5597	cat >conftest.$ac_ext <<_ACEOF
5598#line 5598 "configure"
5599#include "confdefs.h"
5600
5601int
5602main (void)
5603{
5604
5605#ifdef __clang__
5606#else
5607make an error
5608#endif
5609
5610  ;
5611  return 0;
5612}
5613_ACEOF
5614rm -f conftest.$ac_objext
5615if { (eval echo "$as_me:5615: \"$ac_compile\"") >&5
5616  (eval $ac_compile) 2>&5
5617  ac_status=$?
5618  echo "$as_me:5618: \$? = $ac_status" >&5
5619  (exit $ac_status); } &&
5620         { ac_try='test -s conftest.$ac_objext'
5621  { (eval echo "$as_me:5621: \"$ac_try\"") >&5
5622  (eval $ac_try) 2>&5
5623  ac_status=$?
5624  echo "$as_me:5624: \$? = $ac_status" >&5
5625  (exit $ac_status); }; }; then
5626  CLANG_COMPILER=yes
5627cf_save_CFLAGS="$cf_save_CFLAGS -Qunused-arguments"
5628
5629else
5630  echo "$as_me: failed program was:" >&5
5631cat conftest.$ac_ext >&5
5632fi
5633rm -f conftest.$ac_objext conftest.$ac_ext
5634	CFLAGS="$cf_save_CFLAGS"
5635	echo "$as_me:5635: result: $CLANG_COMPILER" >&5
5636echo "${ECHO_T}$CLANG_COMPILER" >&6
5637fi
5638
5639cat > conftest.$ac_ext <<EOF
5640#line 5640 "${as_me:-configure}"
5641int main(int argc, char *argv[]) { return (argv[argc-1] == 0) ; }
5642EOF
5643
5644if test "$INTEL_COMPILER" = yes
5645then
5646# The "-wdXXX" options suppress warnings:
5647# remark #1419: external declaration in primary source file
5648# remark #1683: explicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem)
5649# remark #1684: conversion from pointer to same-sized integral type (potential portability problem)
5650# remark #193: zero used for undefined preprocessing identifier
5651# remark #593: variable "curs_sb_left_arrow" was set but never used
5652# remark #810: conversion from "int" to "Dimension={unsigned short}" may lose significant bits
5653# remark #869: parameter "tw" was never referenced
5654# remark #981: operands are evaluated in unspecified order
5655# warning #279: controlling expression is constant
5656
5657	{ echo "$as_me:5657: checking for $CC warning options..." >&5
5658echo "$as_me: checking for $CC warning options..." >&6;}
5659	cf_save_CFLAGS="$CFLAGS"
5660	EXTRA_CFLAGS="-Wall"
5661	for cf_opt in \
5662		wd1419 \
5663		wd1683 \
5664		wd1684 \
5665		wd193 \
5666		wd593 \
5667		wd279 \
5668		wd810 \
5669		wd869 \
5670		wd981
5671	do
5672		CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
5673		if { (eval echo "$as_me:5673: \"$ac_compile\"") >&5
5674  (eval $ac_compile) 2>&5
5675  ac_status=$?
5676  echo "$as_me:5676: \$? = $ac_status" >&5
5677  (exit $ac_status); }; then
5678			test -n "$verbose" && echo "$as_me:5678: result: ... -$cf_opt" >&5
5679echo "${ECHO_T}... -$cf_opt" >&6
5680			EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
5681		fi
5682	done
5683	CFLAGS="$cf_save_CFLAGS"
5684
5685elif test "$GCC" = yes
5686then
5687	{ echo "$as_me:5687: checking for $CC warning options..." >&5
5688echo "$as_me: checking for $CC warning options..." >&6;}
5689	cf_save_CFLAGS="$CFLAGS"
5690	EXTRA_CFLAGS=
5691	cf_warn_CONST=""
5692	test "$with_ext_const" = yes && cf_warn_CONST="Wwrite-strings"
5693	cf_gcc_warnings="Wignored-qualifiers Wlogical-op Wvarargs"
5694	test "x$CLANG_COMPILER" = xyes && cf_gcc_warnings=
5695	for cf_opt in W Wall \
5696		Wbad-function-cast \
5697		Wcast-align \
5698		Wcast-qual \
5699		Wdeclaration-after-statement \
5700		Wextra \
5701		Winline \
5702		Wmissing-declarations \
5703		Wmissing-prototypes \
5704		Wnested-externs \
5705		Wpointer-arith \
5706		Wshadow \
5707		Wstrict-prototypes \
5708		Wundef $cf_gcc_warnings $cf_warn_CONST
5709	do
5710		CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
5711		if { (eval echo "$as_me:5711: \"$ac_compile\"") >&5
5712  (eval $ac_compile) 2>&5
5713  ac_status=$?
5714  echo "$as_me:5714: \$? = $ac_status" >&5
5715  (exit $ac_status); }; then
5716			test -n "$verbose" && echo "$as_me:5716: result: ... -$cf_opt" >&5
5717echo "${ECHO_T}... -$cf_opt" >&6
5718			case $cf_opt in
5719			(Wcast-qual)
5720
5721	test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5722	CPPFLAGS="${CPPFLAGS}-DXTSTRINGDEFINES"
5723
5724				;;
5725			(Winline)
5726				case $GCC_VERSION in
5727				([34].*)
5728					test -n "$verbose" && echo "	feature is broken in gcc $GCC_VERSION" 1>&6
5729
5730echo "${as_me:-configure}:5730: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
5731
5732					continue;;
5733				esac
5734				;;
5735			(Wpointer-arith)
5736				case $GCC_VERSION in
5737				([12].*)
5738					test -n "$verbose" && echo "	feature is broken in gcc $GCC_VERSION" 1>&6
5739
5740echo "${as_me:-configure}:5740: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
5741
5742					continue;;
5743				esac
5744				;;
5745			esac
5746			EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
5747		fi
5748	done
5749	CFLAGS="$cf_save_CFLAGS"
5750fi
5751rm -rf conftest*
5752
5753fi
5754fi
5755
5756echo "$as_me:5756: checking if you want to use pkg-config" >&5
5757echo $ECHO_N "checking if you want to use pkg-config... $ECHO_C" >&6
5758
5759# Check whether --with-pkg-config or --without-pkg-config was given.
5760if test "${with_pkg_config+set}" = set; then
5761  withval="$with_pkg_config"
5762  cf_pkg_config=$withval
5763else
5764  cf_pkg_config=yes
5765fi;
5766echo "$as_me:5766: result: $cf_pkg_config" >&5
5767echo "${ECHO_T}$cf_pkg_config" >&6
5768
5769case $cf_pkg_config in
5770(no)
5771	PKG_CONFIG=none
5772	;;
5773(yes)
5774
5775if test -n "$ac_tool_prefix"; then
5776  # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
5777set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
5778echo "$as_me:5778: checking for $ac_word" >&5
5779echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5780if test "${ac_cv_path_PKG_CONFIG+set}" = set; then
5781  echo $ECHO_N "(cached) $ECHO_C" >&6
5782else
5783  case $PKG_CONFIG in
5784  [\\/]* | ?:[\\/]*)
5785  ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
5786  ;;
5787  *)
5788  ac_save_IFS=$IFS; IFS=$ac_path_separator
5789ac_dummy="$PATH"
5790for ac_dir in $ac_dummy; do
5791  IFS=$ac_save_IFS
5792  test -z "$ac_dir" && ac_dir=.
5793  if $as_executable_p "$ac_dir/$ac_word"; then
5794   ac_cv_path_PKG_CONFIG="$ac_dir/$ac_word"
5795   echo "$as_me:5795: found $ac_dir/$ac_word" >&5
5796   break
5797fi
5798done
5799
5800  ;;
5801esac
5802fi
5803PKG_CONFIG=$ac_cv_path_PKG_CONFIG
5804
5805if test -n "$PKG_CONFIG"; then
5806  echo "$as_me:5806: result: $PKG_CONFIG" >&5
5807echo "${ECHO_T}$PKG_CONFIG" >&6
5808else
5809  echo "$as_me:5809: result: no" >&5
5810echo "${ECHO_T}no" >&6
5811fi
5812
5813fi
5814if test -z "$ac_cv_path_PKG_CONFIG"; then
5815  ac_pt_PKG_CONFIG=$PKG_CONFIG
5816  # Extract the first word of "pkg-config", so it can be a program name with args.
5817set dummy pkg-config; ac_word=$2
5818echo "$as_me:5818: checking for $ac_word" >&5
5819echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5820if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then
5821  echo $ECHO_N "(cached) $ECHO_C" >&6
5822else
5823  case $ac_pt_PKG_CONFIG in
5824  [\\/]* | ?:[\\/]*)
5825  ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
5826  ;;
5827  *)
5828  ac_save_IFS=$IFS; IFS=$ac_path_separator
5829ac_dummy="$PATH"
5830for ac_dir in $ac_dummy; do
5831  IFS=$ac_save_IFS
5832  test -z "$ac_dir" && ac_dir=.
5833  if $as_executable_p "$ac_dir/$ac_word"; then
5834   ac_cv_path_ac_pt_PKG_CONFIG="$ac_dir/$ac_word"
5835   echo "$as_me:5835: found $ac_dir/$ac_word" >&5
5836   break
5837fi
5838done
5839
5840  test -z "$ac_cv_path_ac_pt_PKG_CONFIG" && ac_cv_path_ac_pt_PKG_CONFIG="none"
5841  ;;
5842esac
5843fi
5844ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
5845
5846if test -n "$ac_pt_PKG_CONFIG"; then
5847  echo "$as_me:5847: result: $ac_pt_PKG_CONFIG" >&5
5848echo "${ECHO_T}$ac_pt_PKG_CONFIG" >&6
5849else
5850  echo "$as_me:5850: result: no" >&5
5851echo "${ECHO_T}no" >&6
5852fi
5853
5854  PKG_CONFIG=$ac_pt_PKG_CONFIG
5855else
5856  PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
5857fi
5858
5859	;;
5860(*)
5861	PKG_CONFIG=$withval
5862	;;
5863esac
5864
5865test -z "$PKG_CONFIG" && PKG_CONFIG=none
5866if test "$PKG_CONFIG" != none ; then
5867
5868if test "x$prefix" != xNONE; then
5869	cf_path_syntax="$prefix"
5870else
5871	cf_path_syntax="$ac_default_prefix"
5872fi
5873
5874case ".$PKG_CONFIG" in
5875(.\$\(*\)*|.\'*\'*)
5876	;;
5877(..|./*|.\\*)
5878	;;
5879(.[a-zA-Z]:[\\/]*) # OS/2 EMX
5880	;;
5881(.\${*prefix}*|.\${*dir}*)
5882	eval PKG_CONFIG="$PKG_CONFIG"
5883	case ".$PKG_CONFIG" in
5884	(.NONE/*)
5885		PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
5886		;;
5887	esac
5888	;;
5889(.no|.NONE/*)
5890	PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
5891	;;
5892(*)
5893	{ { echo "$as_me:5893: error: expected a pathname, not \"$PKG_CONFIG\"" >&5
5894echo "$as_me: error: expected a pathname, not \"$PKG_CONFIG\"" >&2;}
5895   { (exit 1); exit 1; }; }
5896	;;
5897esac
5898
5899elif test "x$cf_pkg_config" != xno ; then
5900	{ echo "$as_me:5900: WARNING: pkg-config is not installed" >&5
5901echo "$as_me: WARNING: pkg-config is not installed" >&2;}
5902fi
5903
5904echo "$as_me:5904: checking for this package's name" >&5
5905echo $ECHO_N "checking for this package's name... $ECHO_C" >&6
5906
5907# Check whether --with-package or --without-package was given.
5908if test "${with_package+set}" = set; then
5909  withval="$with_package"
5910  PACKAGE=$withval
5911else
5912  PACKAGE=dialog
5913fi;
5914echo "$as_me:5914: result: $PACKAGE" >&5
5915echo "${ECHO_T}$PACKAGE" >&6
5916
5917if test -f $srcdir/VERSION ; then
5918	echo "$as_me:5918: checking for package version" >&5
5919echo $ECHO_N "checking for package version... $ECHO_C" >&6
5920
5921	# if there are not enough fields, cut returns the last one...
5922	cf_field1=`sed -e '2,$d' $srcdir/VERSION|cut -f1`
5923	cf_field2=`sed -e '2,$d' $srcdir/VERSION|cut -f2`
5924	cf_field3=`sed -e '2,$d' $srcdir/VERSION|cut -f3`
5925
5926	# this is how CF_BUNDLED_INTL uses $VERSION:
5927	VERSION="$cf_field1"
5928
5929	VERSION_MAJOR=`echo "$cf_field2" | sed -e 's/\..*//'`
5930	test -z "$VERSION_MAJOR" && { { echo "$as_me:5930: error: missing major-version" >&5
5931echo "$as_me: error: missing major-version" >&2;}
5932   { (exit 1); exit 1; }; }
5933
5934	VERSION_MINOR=`echo "$cf_field2" | sed -e 's/^[^.]*\.//' -e 's/-.*//'`
5935	test -z "$VERSION_MINOR" && { { echo "$as_me:5935: error: missing minor-version" >&5
5936echo "$as_me: error: missing minor-version" >&2;}
5937   { (exit 1); exit 1; }; }
5938
5939	echo "$as_me:5939: result: ${VERSION_MAJOR}.${VERSION_MINOR}" >&5
5940echo "${ECHO_T}${VERSION_MAJOR}.${VERSION_MINOR}" >&6
5941
5942	echo "$as_me:5942: checking for package patch date" >&5
5943echo $ECHO_N "checking for package patch date... $ECHO_C" >&6
5944	VERSION_PATCH=`echo "$cf_field3" | sed -e 's/^[^-]*-//'`
5945	case .$VERSION_PATCH in
5946	(.)
5947		{ { echo "$as_me:5947: error: missing patch-date $VERSION_PATCH" >&5
5948echo "$as_me: error: missing patch-date $VERSION_PATCH" >&2;}
5949   { (exit 1); exit 1; }; }
5950		;;
5951	(.[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9])
5952		;;
5953	(*)
5954		{ { echo "$as_me:5954: error: illegal patch-date $VERSION_PATCH" >&5
5955echo "$as_me: error: illegal patch-date $VERSION_PATCH" >&2;}
5956   { (exit 1); exit 1; }; }
5957		;;
5958	esac
5959	echo "$as_me:5959: result: $VERSION_PATCH" >&5
5960echo "${ECHO_T}$VERSION_PATCH" >&6
5961else
5962	{ { echo "$as_me:5962: error: did not find $srcdir/VERSION" >&5
5963echo "$as_me: error: did not find $srcdir/VERSION" >&2;}
5964   { (exit 1); exit 1; }; }
5965fi
5966
5967# show the actual data that we have for versions:
5968test -n "$verbose" && echo "	ABI VERSION $VERSION" 1>&6
5969
5970echo "${as_me:-configure}:5970: testing ABI VERSION $VERSION ..." 1>&5
5971
5972test -n "$verbose" && echo "	VERSION_MAJOR $VERSION_MAJOR" 1>&6
5973
5974echo "${as_me:-configure}:5974: testing VERSION_MAJOR $VERSION_MAJOR ..." 1>&5
5975
5976test -n "$verbose" && echo "	VERSION_MINOR $VERSION_MINOR" 1>&6
5977
5978echo "${as_me:-configure}:5978: testing VERSION_MINOR $VERSION_MINOR ..." 1>&5
5979
5980test -n "$verbose" && echo "	VERSION_PATCH $VERSION_PATCH" 1>&6
5981
5982echo "${as_me:-configure}:5982: testing VERSION_PATCH $VERSION_PATCH ..." 1>&5
5983
5984	cf_PACKAGE=dialog
5985	PACKAGE=$PACKAGE
5986
5987cat >>confdefs.h <<EOF
5988#define PACKAGE "$PACKAGE"
5989EOF
5990
5991cf_PACKAGE=`echo "$cf_PACKAGE" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
5992
5993	cat >>confdefs.h <<EOF
5994#define ${cf_PACKAGE}_VERSION "${VERSION_MAJOR}.${VERSION_MINOR}"
5995EOF
5996
5997	cat >>confdefs.h <<EOF
5998#define ${cf_PACKAGE}_PATCHDATE ${VERSION_PATCH}
5999EOF
6000
6001CFG_ROOTNAME=$PACKAGE
6002HDR_ROOTNAME=$PACKAGE
6003LIB_ROOTNAME=$PACKAGE
6004
6005echo "$as_me:6005: checking if we should install dlg_XXX headers to subdirectory" >&5
6006echo $ECHO_N "checking if we should install dlg_XXX headers to subdirectory... $ECHO_C" >&6
6007
6008# Check whether --enable-header-subdir or --disable-header-subdir was given.
6009if test "${enable_header_subdir+set}" = set; then
6010  enableval="$enable_header_subdir"
6011  SUB_INC=$enableval
6012else
6013  SUB_INC=no
6014fi;
6015echo "$as_me:6015: result: $SUB_INC" >&5
6016echo "${ECHO_T}$SUB_INC" >&6
6017
6018case "x${with_man2html}" in
6019(xno)
6020	cf_man2html=no
6021	;;
6022(x|xyes)
6023	# Extract the first word of "man2html", so it can be a program name with args.
6024set dummy man2html; ac_word=$2
6025echo "$as_me:6025: checking for $ac_word" >&5
6026echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
6027if test "${ac_cv_path_cf_man2html+set}" = set; then
6028  echo $ECHO_N "(cached) $ECHO_C" >&6
6029else
6030  case $cf_man2html in
6031  [\\/]* | ?:[\\/]*)
6032  ac_cv_path_cf_man2html="$cf_man2html" # Let the user override the test with a path.
6033  ;;
6034  *)
6035  ac_save_IFS=$IFS; IFS=$ac_path_separator
6036ac_dummy="$PATH"
6037for ac_dir in $ac_dummy; do
6038  IFS=$ac_save_IFS
6039  test -z "$ac_dir" && ac_dir=.
6040  if $as_executable_p "$ac_dir/$ac_word"; then
6041   ac_cv_path_cf_man2html="$ac_dir/$ac_word"
6042   echo "$as_me:6042: found $ac_dir/$ac_word" >&5
6043   break
6044fi
6045done
6046
6047  test -z "$ac_cv_path_cf_man2html" && ac_cv_path_cf_man2html="no"
6048  ;;
6049esac
6050fi
6051cf_man2html=$ac_cv_path_cf_man2html
6052
6053if test -n "$cf_man2html"; then
6054  echo "$as_me:6054: result: $cf_man2html" >&5
6055echo "${ECHO_T}$cf_man2html" >&6
6056else
6057  echo "$as_me:6057: result: no" >&5
6058echo "${ECHO_T}no" >&6
6059fi
6060
6061	case "x$cf_man2html" in
6062	(x/*)
6063		echo "$as_me:6063: checking for the modified Earl Hood script" >&5
6064echo $ECHO_N "checking for the modified Earl Hood script... $ECHO_C" >&6
6065		if ( $cf_man2html -help 2>&1 | grep 'Make an index of headers at the end' >/dev/null )
6066		then
6067			cf_man2html_ok=yes
6068		else
6069			cf_man2html=no
6070			cf_man2html_ok=no
6071		fi
6072		echo "$as_me:6072: result: $cf_man2html_ok" >&5
6073echo "${ECHO_T}$cf_man2html_ok" >&6
6074		;;
6075	(*)
6076		cf_man2html=no
6077		;;
6078	esac
6079esac
6080
6081echo "$as_me:6081: checking for program to convert manpage to html" >&5
6082echo $ECHO_N "checking for program to convert manpage to html... $ECHO_C" >&6
6083
6084# Check whether --with-man2html or --without-man2html was given.
6085if test "${with_man2html+set}" = set; then
6086  withval="$with_man2html"
6087  cf_man2html=$withval
6088else
6089  cf_man2html=$cf_man2html
6090fi;
6091
6092cf_with_groff=no
6093
6094case $cf_man2html in
6095(yes)
6096	echo "$as_me:6096: result: man2html" >&5
6097echo "${ECHO_T}man2html" >&6
6098	# Extract the first word of "man2html", so it can be a program name with args.
6099set dummy man2html; ac_word=$2
6100echo "$as_me:6100: checking for $ac_word" >&5
6101echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
6102if test "${ac_cv_path_cf_man2html+set}" = set; then
6103  echo $ECHO_N "(cached) $ECHO_C" >&6
6104else
6105  case $cf_man2html in
6106  [\\/]* | ?:[\\/]*)
6107  ac_cv_path_cf_man2html="$cf_man2html" # Let the user override the test with a path.
6108  ;;
6109  *)
6110  ac_save_IFS=$IFS; IFS=$ac_path_separator
6111ac_dummy="$PATH"
6112for ac_dir in $ac_dummy; do
6113  IFS=$ac_save_IFS
6114  test -z "$ac_dir" && ac_dir=.
6115  if $as_executable_p "$ac_dir/$ac_word"; then
6116   ac_cv_path_cf_man2html="$ac_dir/$ac_word"
6117   echo "$as_me:6117: found $ac_dir/$ac_word" >&5
6118   break
6119fi
6120done
6121
6122  test -z "$ac_cv_path_cf_man2html" && ac_cv_path_cf_man2html="no"
6123  ;;
6124esac
6125fi
6126cf_man2html=$ac_cv_path_cf_man2html
6127
6128if test -n "$cf_man2html"; then
6129  echo "$as_me:6129: result: $cf_man2html" >&5
6130echo "${ECHO_T}$cf_man2html" >&6
6131else
6132  echo "$as_me:6132: result: no" >&5
6133echo "${ECHO_T}no" >&6
6134fi
6135
6136	;;
6137(no|groff|*/groff*)
6138	cf_with_groff=yes
6139	cf_man2html=$GROFF_PATH
6140	echo "$as_me:6140: result: $cf_man2html" >&5
6141echo "${ECHO_T}$cf_man2html" >&6
6142	;;
6143(*)
6144	echo "$as_me:6144: result: $cf_man2html" >&5
6145echo "${ECHO_T}$cf_man2html" >&6
6146	;;
6147esac
6148
6149MAN2HTML_TEMP="man2html.tmp"
6150	cat >$MAN2HTML_TEMP <<CF_EOF
6151#!$SHELL
6152# Temporary script generated by CF_WITH_MAN2HTML
6153# Convert inputs to html, sending result to standard output.
6154#
6155# Parameters:
6156# \${1} = rootname of file to convert
6157# \${2} = suffix of file to convert, e.g., "1"
6158# \${3} = macros to use, e.g., "man"
6159#
6160ROOT=\$1
6161TYPE=\$2
6162MACS=\$3
6163
6164unset LANG
6165unset LC_ALL
6166unset LC_CTYPE
6167unset LANGUAGE
6168GROFF_NO_SGR=stupid
6169export GROFF_NO_SGR
6170
6171CF_EOF
6172
6173if test "x$cf_with_groff" = xyes
6174then
6175	MAN2HTML_NOTE="$GROFF_NOTE"
6176	MAN2HTML_PATH="$GROFF_PATH"
6177	cat >>$MAN2HTML_TEMP <<CF_EOF
6178$SHELL -c "$TBL_PATH \${ROOT}.\${TYPE} | $GROFF_PATH -P -o0 -I\${ROOT}_ -Thtml -\${MACS}"
6179CF_EOF
6180else
6181	MAN2HTML_NOTE=""
6182
6183if test "x$prefix" != xNONE; then
6184	cf_path_syntax="$prefix"
6185else
6186	cf_path_syntax="$ac_default_prefix"
6187fi
6188
6189case ".$cf_man2html" in
6190(.\$\(*\)*|.\'*\'*)
6191	;;
6192(..|./*|.\\*)
6193	;;
6194(.[a-zA-Z]:[\\/]*) # OS/2 EMX
6195	;;
6196(.\${*prefix}*|.\${*dir}*)
6197	eval cf_man2html="$cf_man2html"
6198	case ".$cf_man2html" in
6199	(.NONE/*)
6200		cf_man2html=`echo $cf_man2html | sed -e s%NONE%$cf_path_syntax%`
6201		;;
6202	esac
6203	;;
6204(.no|.NONE/*)
6205	cf_man2html=`echo $cf_man2html | sed -e s%NONE%$cf_path_syntax%`
6206	;;
6207(*)
6208	{ { echo "$as_me:6208: error: expected a pathname, not \"$cf_man2html\"" >&5
6209echo "$as_me: error: expected a pathname, not \"$cf_man2html\"" >&2;}
6210   { (exit 1); exit 1; }; }
6211	;;
6212esac
6213
6214	MAN2HTML_PATH="$cf_man2html"
6215	echo "$as_me:6215: checking for $cf_man2html top/bottom margins" >&5
6216echo $ECHO_N "checking for $cf_man2html top/bottom margins... $ECHO_C" >&6
6217
6218	# for this example, expect 3 lines of content, the remainder is head/foot
6219	cat >conftest.in <<CF_EOF
6220.TH HEAD1 HEAD2 HEAD3 HEAD4 HEAD5
6221.SH SECTION
6222MARKER
6223CF_EOF
6224
6225	LC_ALL=C LC_CTYPE=C LANG=C LANGUAGE=C $NROFF_PATH -man conftest.in >conftest.out
6226
6227	cf_man2html_1st=`fgrep -n MARKER conftest.out |sed -e 's/^[^0-9]*://' -e 's/:.*//'`
6228	cf_man2html_top=`expr $cf_man2html_1st - 2`
6229	cf_man2html_bot=`wc -l conftest.out |sed -e 's/[^0-9]//g'`
6230	cf_man2html_bot=`expr $cf_man2html_bot - 2 - $cf_man2html_top`
6231	cf_man2html_top_bot="-topm=$cf_man2html_top -botm=$cf_man2html_bot"
6232
6233	echo "$as_me:6233: result: $cf_man2html_top_bot" >&5
6234echo "${ECHO_T}$cf_man2html_top_bot" >&6
6235
6236	echo "$as_me:6236: checking for pagesize to use" >&5
6237echo $ECHO_N "checking for pagesize to use... $ECHO_C" >&6
6238	for cf_block in 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20
6239	do
6240	cat >>conftest.in <<CF_EOF
6241.nf
62420
62431
62442
62453
62464
62475
62486
62497
62508
62519
6252CF_EOF
6253	done
6254
6255	LC_ALL=C LC_CTYPE=C LANG=C LANGUAGE=C $NROFF_PATH -man conftest.in >conftest.out
6256	cf_man2html_page=`fgrep -n HEAD1 conftest.out |tail -n 1 |sed -e 's/^[^0-9]*://' -e 's/:.*//'`
6257	test -z "$cf_man2html_page" && cf_man2html_page=99999
6258	test "$cf_man2html_page" -gt 100 && cf_man2html_page=99999
6259
6260	rm -rf conftest*
6261	echo "$as_me:6261: result: $cf_man2html_page" >&5
6262echo "${ECHO_T}$cf_man2html_page" >&6
6263
6264	cat >>$MAN2HTML_TEMP <<CF_EOF
6265: \${MAN2HTML_PATH=$MAN2HTML_PATH}
6266MAN2HTML_OPTS="\$MAN2HTML_OPTS -index -title="\$ROOT\(\$TYPE\)" -compress -pgsize $cf_man2html_page"
6267case \${TYPE} in
6268(ms)
6269	$TBL_PATH \${ROOT}.\${TYPE} | $NROFF_PATH -\${MACS} | \$MAN2HTML_PATH -topm=0 -botm=0 \$MAN2HTML_OPTS
6270	;;
6271(*)
6272	$TBL_PATH \${ROOT}.\${TYPE} | $NROFF_PATH -\${MACS} | \$MAN2HTML_PATH $cf_man2html_top_bot \$MAN2HTML_OPTS
6273	;;
6274esac
6275CF_EOF
6276fi
6277
6278chmod 700 $MAN2HTML_TEMP
6279
6280EXTRAOBJS=""
6281
6282echo "$as_me:6282: checking for ANSI C header files" >&5
6283echo