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