]> ncurses.scripts.mit.edu Git - ncurses.git/blob - configure
ncurses 6.1 - patch 20180623
[ncurses.git] / configure
1 #! /bin/sh
2 # From configure.in Revision: 1.659 .
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-sysmouse         use sysmouse (FreeBSD console)
749   --disable-lib-suffixes  disable library suffixes
750   --disable-rpath-hack    don't add rpath options for additional libraries
751 Fine-Tuning Your Configuration:
752   --with-extra-suffix=X   append extra suffix to header/library paths
753   --disable-overwrite     put headers in subdir, omit link to -lcurses
754   --disable-database      do not use terminfo, only fallbacks/termcap
755   --with-database=XXX     specify terminfo source to install
756   --with-hashed-db        specify hashed-database library
757   --with-fallbacks=XXX    specify list of fallback terminal descriptions
758   --without-xterm-new     specify if xterm terminfo should be old version
759   --with-xterm-kbs=XXX    specify if xterm backspace sends BS or DEL
760   --with-terminfo-dirs=XXX specify list of terminfo directories (default: DATADIR/terminfo)
761   --with-default-terminfo-dir=DIR default terminfo directory (default: DATADIR/terminfo)
762   --disable-big-core      assume machine has little memory
763   --disable-big-strings   assume compiler has only standard-size strings
764   --enable-termcap        compile in termcap fallback support
765   --with-termpath=XXX     specify list of termcap files (default: /etc/termcap:/usr/share/misc/termcap)
766   --enable-getcap         fast termcap load, no xrefs to terminfo
767   --enable-getcap-cache   cache translated termcaps in ~/.terminfo
768   --disable-home-terminfo drop ~/.terminfo from terminfo search-path
769   --disable-root-environ  restrict environment when running as root
770   --enable-symlinks       make tic use symbolic links not hard links
771   --enable-broken_linker  compile with broken-linker support code
772   --enable-bsdpad         recognize BSD-style prefix padding
773   --enable-widec          compile with wide-char/UTF-8 code
774   --disable-lp64          allow chtype to be long (ignore _LP64)
775   --disable-largefile     omit support for large files
776   --disable-tparm-varargs compile tparm() without varargs interface
777   --disable-tic-depends   link tic library without explicit dependency on ncurses library
778   --disable-wattr-macros  suppress wattr* macros to help with ncurses5/ncurses6 transition
779   --with-x11-rgb=FILE   file containing X11 rgb information (EPREFIX/lib/X11/rgb.txt)
780   --with-bool=TYPE        override fallback type of bool variable
781   --with-caps=alt         compile with alternate Caps file
782   --with-chtype=TYPE      override type of chtype
783   --with-ospeed=TYPE      override type of ospeed variable
784   --with-mmask-t=TYPE     override type of mmask_t
785   --with-ccharw-max=XXX   override size CCHARW_MAX
786   --enable-signed-char    compile using signed Boolean's in term.h
787   --with-tparm-arg=TYPE   override parameter type of tparm
788   --with-rcs-ids          compile-in RCS identifiers
789 Options to Specify How Manpages are Installed:
790   --with-manpage-format   specify manpage-format: gzip/compress/BSDI/normal and
791                           optionally formatted/catonly, e.g., gzip,formatted
792   --with-manpage-renames  specify manpage-renaming
793   --with-manpage-aliases  specify manpage-aliases using .so
794   --with-manpage-symlinks specify manpage-aliases using symlinks
795   --with-manpage-tbl      specify manpage processing with tbl
796 Extensions:
797   --disable-ext-funcs     disable function-extensions
798   --enable-sp-funcs       enable SCREEN-extensions
799   --enable-term-driver    enable terminal-driver
800   --enable-const          compile with extra/non-standard const
801   --enable-ext-colors     compile for 256-color support
802   --enable-ext-mouse      compile for extended mouse-encoding
803   --enable-ext-putwin     compile with extended putwin/screendump
804   --enable-no-padding     compile with $NCURSES_NO_PADDING code
805   --enable-sigwinch       compile with SIGWINCH handler
806   --enable-tcap-names     compile with user-definable terminal capabilities
807 Reentrant Code:
808   --with-pthread          use POSIX thread library
809   --enable-pthreads-eintr enable EINTR in wgetch with pthreads
810   --enable-weak-symbols   enable weak-symbols for pthreads
811   --enable-reentrant      compile with reentrant code
812   --enable-opaque-curses  make curses WINDOW, etc., "opaque"
813   --enable-opaque-form    make form-library structures "opaque"
814   --enable-opaque-menu    make menu-library structures "opaque"
815   --enable-opaque-panel   make panel-library structures "opaque"
816   --with-wrap-prefix=XXX  override prefix used for public variables
817 Development Code:
818   --without-develop       disable development options
819   --enable-hard-tabs      compile with hard-tabs code
820   --enable-xmc-glitch     compile with support for xmc (magic-cookie)
821 Experimental Code:
822   --disable-assumed-color do not assume anything about default-colors
823   --disable-hashmap       compile without hashmap scrolling-optimization
824   --enable-colorfgbg      compile-in experimental $COLORFGBG code
825   --enable-interop        compile-in interop bindings
826   --enable-safe-sprintf   compile with experimental safe-sprintf code
827   --disable-scroll-hints  compile without scroll-hints code
828   --enable-wgetch-events  compile with wgetch-events code
829 Testing/development Options:
830   --disable-echo          do not display "compiling" commands
831   --disable-stripping     do not strip installed executables
832   --enable-warnings       build: turn on GCC compiler warnings
833   --enable-string-hacks   work around bogus compiler/loader warnings
834   --enable-assertions     test: turn on generation of assertion code
835   --with-dmalloc          test: use Gray Watson's dmalloc library
836   --with-dbmalloc         test: use Conor Cahill's dbmalloc library
837   --with-valgrind         test: use valgrind
838   --disable-leaks         test: free permanent memory, analyze leaks
839   --enable-expanded       test: generate functions for certain macros
840   --disable-macros        test: use functions rather than macros
841   --with-trace            test: add trace() function to all models of ncurses
842   --disable-gnat-projects test: disable GNAT projects even if usable
843 Ada95 Binding Options:
844   --with-ada-compiler=CMD specify Ada95 compiler command (default gnatmake)
845   --with-ada-include=DIR  Ada includes are in DIR (default: PREFIX/share/ada/adainclude)
846   --with-ada-objects=DIR  Ada objects are in DIR (default: PREFIX/lib/ada/adalib)
847   --with-ada-sharedlib=soname build shared-library (requires GNAT projects)
848
849 Some influential environment variables:
850   CC          C compiler command
851   CFLAGS      C compiler flags
852   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
853               nonstandard directory <lib dir>
854   CPPFLAGS    C/C++ preprocessor flags, e.g. -I<include dir> if you have
855               headers in a nonstandard directory <include dir>
856   CPP         C preprocessor
857   CXX         C++ compiler command
858   CXXFLAGS    C++ compiler flags
859   CXXCPP      C++ preprocessor
860
861 Use these variables to override the choices made by `configure' or to help
862 it to find libraries and programs with nonstandard names/locations.
863
864 EOF
865 fi
866
867 if test "$ac_init_help" = "recursive"; then
868   # If there are subdirs, report their specific --help.
869   ac_popdir=`pwd`
870   for ac_subdir in : $ac_subdirs_all; do test "x$ac_subdir" = x: && continue
871     cd $ac_subdir
872     # A "../" for each directory in /$ac_subdir.
873     ac_dots=`echo $ac_subdir |
874              sed 's,^\./,,;s,[^/]$,&/,;s,[^/]*/,../,g'`
875
876     case $srcdir in
877     .) # No --srcdir option.  We are building in place.
878       ac_sub_srcdir=$srcdir ;;
879     [\\/]* | ?:[\\/]* ) # Absolute path.
880       ac_sub_srcdir=$srcdir/$ac_subdir ;;
881     *) # Relative path.
882       ac_sub_srcdir=$ac_dots$srcdir/$ac_subdir ;;
883     esac
884
885     # Check for guested configure; otherwise get Cygnus style configure.
886     if test -f $ac_sub_srcdir/configure.gnu; then
887       echo
888       $SHELL $ac_sub_srcdir/configure.gnu  --help=recursive
889     elif test -f $ac_sub_srcdir/configure; then
890       echo
891       $SHELL $ac_sub_srcdir/configure  --help=recursive
892     elif test -f $ac_sub_srcdir/configure.ac ||
893            test -f $ac_sub_srcdir/configure.in; then
894       echo
895       $ac_configure --help
896     else
897       echo "$as_me: WARNING: no configuration information is in $ac_subdir" >&2
898     fi
899     cd $ac_popdir
900   done
901 fi
902
903 test -n "$ac_init_help" && exit 0
904 if $ac_init_version; then
905   cat <<\EOF
906
907 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
908 Free Software Foundation, Inc.
909 This configure script is free software; the Free Software Foundation
910 gives unlimited permission to copy, distribute and modify it.
911 EOF
912   exit 0
913 fi
914 exec 5>config.log
915 cat >&5 <<EOF
916 This file contains any messages produced by compilers while
917 running configure, to aid debugging if configure makes a mistake.
918
919 It was created by $as_me, which was
920 generated by GNU Autoconf 2.52.20170501.  Invocation command line was
921
922   $ $0 $@
923
924 EOF
925 {
926 cat <<_ASUNAME
927 ## ---------- ##
928 ## Platform.  ##
929 ## ---------- ##
930
931 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
932 uname -m = `(uname -m) 2>/dev/null || echo unknown`
933 uname -r = `(uname -r) 2>/dev/null || echo unknown`
934 uname -s = `(uname -s) 2>/dev/null || echo unknown`
935 uname -v = `(uname -v) 2>/dev/null || echo unknown`
936
937 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
938 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
939
940 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
941 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
942 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
943 hostinfo               = `(hostinfo) 2>/dev/null               || echo unknown`
944 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
945 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
946 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
947
948 PATH = $PATH
949
950 _ASUNAME
951 } >&5
952
953 cat >&5 <<EOF
954 ## ------------ ##
955 ## Core tests.  ##
956 ## ------------ ##
957
958 EOF
959
960 # Keep a trace of the command line.
961 # Strip out --no-create and --no-recursion so they do not pile up.
962 # Also quote any args containing shell meta-characters.
963 ac_configure_args=
964 ac_sep=
965 for ac_arg
966 do
967   case $ac_arg in
968   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
969   | --no-cr | --no-c) ;;
970   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
971   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
972   *" "*|*"      "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
973     ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"`
974     ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
975     ac_sep=" " ;;
976   *) ac_configure_args="$ac_configure_args$ac_sep$ac_arg"
977      ac_sep=" " ;;
978   esac
979   # Get rid of the leading space.
980 done
981
982 # When interrupted or exit'd, cleanup temporary files, and complete
983 # config.log.  We remove comments because anyway the quotes in there
984 # would cause problems or look ugly.
985 trap 'exit_status=$?
986   # Save into config.log some information that might help in debugging.
987   echo >&5
988   echo "## ----------------- ##" >&5
989   echo "## Cache variables.  ##" >&5
990   echo "## ----------------- ##" >&5
991   echo >&5
992   # The following way of writing the cache mishandles newlines in values,
993 {
994   (set) 2>&1 |
995     case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
996     *ac_space=\ *)
997       sed -n \
998         "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
999           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
1000       ;;
1001     *)
1002       sed -n \
1003         "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
1004       ;;
1005     esac;
1006 } >&5
1007   sed "/^$/d" confdefs.h >conftest.log
1008   if test -s conftest.log; then
1009     echo >&5
1010     echo "## ------------ ##" >&5
1011     echo "## confdefs.h.  ##" >&5
1012     echo "## ------------ ##" >&5
1013     echo >&5
1014     cat conftest.log >&5
1015   fi
1016   (echo; echo) >&5
1017   test "$ac_signal" != 0 &&
1018     echo "$as_me: caught signal $ac_signal" >&5
1019   echo "$as_me: exit $exit_status" >&5
1020   rm -rf conftest* confdefs* core core.* *.core conf$$* $ac_clean_files &&
1021     exit $exit_status
1022      ' 0
1023 for ac_signal in 1 2 13 15; do
1024   trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1025 done
1026 ac_signal=0
1027
1028 # confdefs.h avoids OS command line length limits that DEFS can exceed.
1029 rm -rf conftest* confdefs.h
1030 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
1031 echo >confdefs.h
1032
1033 # Let the site file select an alternate cache file if it wants to.
1034 # Prefer explicitly selected file to automatically selected ones.
1035 if test -z "$CONFIG_SITE"; then
1036   if test "x$prefix" != xNONE; then
1037     CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
1038   else
1039     CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
1040   fi
1041 fi
1042 for ac_site_file in $CONFIG_SITE; do
1043   if test -r "$ac_site_file"; then
1044     { echo "$as_me:1044: loading site script $ac_site_file" >&5
1045 echo "$as_me: loading site script $ac_site_file" >&6;}
1046     cat "$ac_site_file" >&5
1047     . "$ac_site_file"
1048   fi
1049 done
1050
1051 if test -r "$cache_file"; then
1052   # Some versions of bash will fail to source /dev/null (special
1053   # files actually), so we avoid doing that.
1054   if test -f "$cache_file"; then
1055     { echo "$as_me:1055: loading cache $cache_file" >&5
1056 echo "$as_me: loading cache $cache_file" >&6;}
1057     case $cache_file in
1058       [\\/]* | ?:[\\/]* ) . $cache_file;;
1059       *)                      . ./$cache_file;;
1060     esac
1061   fi
1062 else
1063   { echo "$as_me:1063: creating cache $cache_file" >&5
1064 echo "$as_me: creating cache $cache_file" >&6;}
1065   >$cache_file
1066 fi
1067
1068 # Check that the precious variables saved in the cache have kept the same
1069 # value.
1070 ac_cache_corrupted=false
1071 for ac_var in `(set) 2>&1 |
1072                sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
1073   eval ac_old_set=\$ac_cv_env_${ac_var}_set
1074   eval ac_new_set=\$ac_env_${ac_var}_set
1075   eval ac_old_val="\$ac_cv_env_${ac_var}_value"
1076   eval ac_new_val="\$ac_env_${ac_var}_value"
1077   case $ac_old_set,$ac_new_set in
1078     set,)
1079       { echo "$as_me:1079: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1080 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1081       ac_cache_corrupted=: ;;
1082     ,set)
1083       { echo "$as_me:1083: error: \`$ac_var' was not set in the previous run" >&5
1084 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1085       ac_cache_corrupted=: ;;
1086     ,);;
1087     *)
1088       if test "x$ac_old_val" != "x$ac_new_val"; then
1089         { echo "$as_me:1089: error: \`$ac_var' has changed since the previous run:" >&5
1090 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1091         { echo "$as_me:1091:   former value:  $ac_old_val" >&5
1092 echo "$as_me:   former value:  $ac_old_val" >&2;}
1093         { echo "$as_me:1093:   current value: $ac_new_val" >&5
1094 echo "$as_me:   current value: $ac_new_val" >&2;}
1095         ac_cache_corrupted=:
1096       fi;;
1097   esac
1098   # Pass precious variables to config.status.  It doesn't matter if
1099   # we pass some twice (in addition to the command line arguments).
1100   if test "$ac_new_set" = set; then
1101     case $ac_new_val in
1102     *" "*|*"    "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1103       ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"`
1104       ac_configure_args="$ac_configure_args '$ac_arg'"
1105       ;;
1106     *) ac_configure_args="$ac_configure_args $ac_var=$ac_new_val"
1107        ;;
1108     esac
1109   fi
1110 done
1111 if $ac_cache_corrupted; then
1112   { echo "$as_me:1112: error: changes in the environment can compromise the build" >&5
1113 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1114   { { echo "$as_me:1114: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1115 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1116    { (exit 1); exit 1; }; }
1117 fi
1118
1119 ac_ext=c
1120 ac_cpp='$CPP $CPPFLAGS'
1121 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1122 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1123 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1124 ac_main_return=return
1125
1126 case `echo "testing\c" 2>/dev/null; echo 1,2,3`,`echo -n testing 2>/dev/null; echo 1,2,3` in
1127   *c*,-n*) ECHO_N= ECHO_C=      # newlines do not sed ;-) only broken shells would use this case anyway
1128                    ECHO_T='     ' ;;
1129   *c*,*  ) ECHO_N=-n ECHO_C= ECHO_T= ;;
1130   *)      ECHO_N= ECHO_C='\c' ECHO_T= ;;
1131 esac
1132 echo "#! $SHELL" >conftest.sh
1133 echo  "exit 0"   >>conftest.sh
1134 chmod +x conftest.sh
1135 if { (echo "$as_me:1135: PATH=\".;.\"; conftest.sh") >&5
1136   (PATH=".;."; conftest.sh) 2>&5
1137   ac_status=$?
1138   echo "$as_me:1138: \$? = $ac_status" >&5
1139   (exit $ac_status); }; then
1140   ac_path_separator=';'
1141 else
1142   ac_path_separator=:
1143 fi
1144 PATH_SEPARATOR="$ac_path_separator"
1145 rm -f conftest.sh
1146
1147 ac_config_headers="$ac_config_headers include/ncurses_cfg.h:include/ncurses_cfg.hin"
1148
1149 top_builddir=`pwd`
1150
1151 echo "$as_me:1151: checking for egrep" >&5
1152 echo $ECHO_N "checking for egrep... $ECHO_C" >&6
1153 if test "${ac_cv_prog_egrep+set}" = set; then
1154   echo $ECHO_N "(cached) $ECHO_C" >&6
1155 else
1156   if echo a | (grep -E '(a|b)') >/dev/null 2>&1
1157                 then ac_cv_prog_egrep='grep -E'
1158                 else ac_cv_prog_egrep='egrep'
1159         fi
1160 fi
1161 echo "$as_me:1161: result: $ac_cv_prog_egrep" >&5
1162 echo "${ECHO_T}$ac_cv_prog_egrep" >&6
1163         EGREP=$ac_cv_prog_egrep
1164
1165         test -z "$EGREP" && { { echo "$as_me:1165: error: No egrep program found" >&5
1166 echo "$as_me: error: No egrep program found" >&2;}
1167    { (exit 1); exit 1; }; }
1168
1169 NCURSES_MAJOR="`$ac_cv_prog_egrep '^NCURSES_MAJOR[      ]*=' $srcdir/dist.mk | sed -e 's/^[^0-9]*//'`"
1170 NCURSES_MINOR="`$ac_cv_prog_egrep '^NCURSES_MINOR[      ]*=' $srcdir/dist.mk | sed -e 's/^[^0-9]*//'`"
1171 NCURSES_PATCH="`$ac_cv_prog_egrep '^NCURSES_PATCH[      ]*=' $srcdir/dist.mk | sed -e 's/^[^0-9]*//'`"
1172 cf_cv_abi_version=${NCURSES_MAJOR}
1173 cf_cv_rel_version=${NCURSES_MAJOR}.${NCURSES_MINOR}
1174 cf_cv_timestamp=`date`
1175 echo "$as_me:1175: result: Configuring NCURSES $cf_cv_rel_version ABI $cf_cv_abi_version ($cf_cv_timestamp)" >&5
1176 echo "${ECHO_T}Configuring NCURSES $cf_cv_rel_version ABI $cf_cv_abi_version ($cf_cv_timestamp)" >&6
1177
1178 if test -f $srcdir/VERSION ; then
1179         echo "$as_me:1179: checking for package version" >&5
1180 echo $ECHO_N "checking for package version... $ECHO_C" >&6
1181
1182         # if there are not enough fields, cut returns the last one...
1183         cf_field1=`sed -e '2,$d' $srcdir/VERSION|cut -f1`
1184         cf_field2=`sed -e '2,$d' $srcdir/VERSION|cut -f2`
1185         cf_field3=`sed -e '2,$d' $srcdir/VERSION|cut -f3`
1186
1187         # this is how CF_BUNDLED_INTL uses $VERSION:
1188         VERSION="$cf_field1"
1189
1190         VERSION_MAJOR=`echo "$cf_field2" | sed -e 's/\..*//'`
1191         test -z "$VERSION_MAJOR" && { { echo "$as_me:1191: error: missing major-version" >&5
1192 echo "$as_me: error: missing major-version" >&2;}
1193    { (exit 1); exit 1; }; }
1194
1195         VERSION_MINOR=`echo "$cf_field2" | sed -e 's/^[^.]*\.//' -e 's/-.*//'`
1196         test -z "$VERSION_MINOR" && { { echo "$as_me:1196: error: missing minor-version" >&5
1197 echo "$as_me: error: missing minor-version" >&2;}
1198    { (exit 1); exit 1; }; }
1199
1200         echo "$as_me:1200: result: ${VERSION_MAJOR}.${VERSION_MINOR}" >&5
1201 echo "${ECHO_T}${VERSION_MAJOR}.${VERSION_MINOR}" >&6
1202
1203         echo "$as_me:1203: checking for package patch date" >&5
1204 echo $ECHO_N "checking for package patch date... $ECHO_C" >&6
1205         VERSION_PATCH=`echo "$cf_field3" | sed -e 's/^[^-]*-//'`
1206         case .$VERSION_PATCH in
1207         (.)
1208                 { { echo "$as_me:1208: error: missing patch-date $VERSION_PATCH" >&5
1209 echo "$as_me: error: missing patch-date $VERSION_PATCH" >&2;}
1210    { (exit 1); exit 1; }; }
1211                 ;;
1212         (.[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9])
1213                 ;;
1214         (*)
1215                 { { echo "$as_me:1215: error: illegal patch-date $VERSION_PATCH" >&5
1216 echo "$as_me: error: illegal patch-date $VERSION_PATCH" >&2;}
1217    { (exit 1); exit 1; }; }
1218                 ;;
1219         esac
1220         echo "$as_me:1220: result: $VERSION_PATCH" >&5
1221 echo "${ECHO_T}$VERSION_PATCH" >&6
1222 else
1223         { { echo "$as_me:1223: error: did not find $srcdir/VERSION" >&5
1224 echo "$as_me: error: did not find $srcdir/VERSION" >&2;}
1225    { (exit 1); exit 1; }; }
1226 fi
1227
1228 # show the actual data that we have for versions:
1229 test -n "$verbose" && echo "    ABI VERSION $VERSION" 1>&6
1230
1231 echo "${as_me:-configure}:1231: testing ABI VERSION $VERSION ..." 1>&5
1232
1233 test -n "$verbose" && echo "    VERSION_MAJOR $VERSION_MAJOR" 1>&6
1234
1235 echo "${as_me:-configure}:1235: testing VERSION_MAJOR $VERSION_MAJOR ..." 1>&5
1236
1237 test -n "$verbose" && echo "    VERSION_MINOR $VERSION_MINOR" 1>&6
1238
1239 echo "${as_me:-configure}:1239: testing VERSION_MINOR $VERSION_MINOR ..." 1>&5
1240
1241 test -n "$verbose" && echo "    VERSION_PATCH $VERSION_PATCH" 1>&6
1242
1243 echo "${as_me:-configure}:1243: testing VERSION_PATCH $VERSION_PATCH ..." 1>&5
1244
1245         cf_PACKAGE=NCURSES
1246         PACKAGE=ncurses
1247
1248 cat >>confdefs.h <<EOF
1249 #define PACKAGE "$PACKAGE"
1250 EOF
1251
1252 cf_PACKAGE=`echo "$cf_PACKAGE" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
1253
1254         cat >>confdefs.h <<EOF
1255 #define ${cf_PACKAGE}_VERSION "${VERSION_MAJOR}.${VERSION_MINOR}"
1256 EOF
1257
1258         cat >>confdefs.h <<EOF
1259 #define ${cf_PACKAGE}_PATCHDATE ${VERSION_PATCH}
1260 EOF
1261
1262 test -z "$cf_cv_rel_version" && cf_cv_rel_version=0.0
1263
1264 # Check whether --with-rel-version or --without-rel-version was given.
1265 if test "${with_rel_version+set}" = set; then
1266   withval="$with_rel_version"
1267   { echo "$as_me:1267: WARNING: overriding release version $cf_cv_rel_version to $withval" >&5
1268 echo "$as_me: WARNING: overriding release version $cf_cv_rel_version to $withval" >&2;}
1269  cf_cv_rel_version=$withval
1270 fi;
1271
1272  NCURSES_MAJOR=`echo "$cf_cv_rel_version" | sed -e 's/\..*//'`
1273  NCURSES_MINOR=`echo "$cf_cv_rel_version" | sed -e 's/^[^.]*//' -e 's/^\.//' -e 's/\..*//'`
1274
1275 if test -n "$NCURSES_MAJOR" ; then
1276   case $NCURSES_MAJOR in
1277   ([0-9]*)
1278         ;;
1279   (*)
1280         { { echo "$as_me:1280: error: Release major-version is not a number: $NCURSES_MAJOR" >&5
1281 echo "$as_me: error: Release major-version is not a number: $NCURSES_MAJOR" >&2;}
1282    { (exit 1); exit 1; }; }
1283         ;;
1284   esac
1285 else
1286   { { echo "$as_me:1286: error: Release major-version value is empty" >&5
1287 echo "$as_me: error: Release major-version value is empty" >&2;}
1288    { (exit 1); exit 1; }; }
1289 fi
1290
1291 if test -n "$NCURSES_MINOR" ; then
1292   case $NCURSES_MINOR in
1293   ([0-9]*)
1294         ;;
1295   (*)
1296         { { echo "$as_me:1296: error: Release minor-version is not a number: $NCURSES_MINOR" >&5
1297 echo "$as_me: error: Release minor-version is not a number: $NCURSES_MINOR" >&2;}
1298    { (exit 1); exit 1; }; }
1299         ;;
1300   esac
1301 else
1302   { { echo "$as_me:1302: error: Release minor-version value is empty" >&5
1303 echo "$as_me: error: Release minor-version value is empty" >&2;}
1304    { (exit 1); exit 1; }; }
1305 fi
1306
1307 test -z "$cf_cv_abi_version" && cf_cv_abi_version=0
1308
1309 # Check whether --with-abi-version or --without-abi-version was given.
1310 if test "${with_abi_version+set}" = set; then
1311   withval="$with_abi_version"
1312
1313         if test "x$cf_cv_abi_version" != "x$withval"
1314         then
1315                 { echo "$as_me:1315: WARNING: overriding ABI version $cf_cv_abi_version to $withval" >&5
1316 echo "$as_me: WARNING: overriding ABI version $cf_cv_abi_version to $withval" >&2;}
1317                 case $cf_cv_rel_version in
1318                 (5.*)
1319                         cf_cv_rel_version=$withval.0
1320                         ;;
1321                 (6.*)
1322                         cf_cv_rel_version=$withval.9    # FIXME: should be 10 as of 6.0 release
1323                         ;;
1324                 esac
1325         fi
1326         cf_cv_abi_version=$withval
1327 fi;
1328
1329 if test -n "$cf_cv_abi_version" ; then
1330   case $cf_cv_abi_version in
1331   ([0-9]*)
1332         ;;
1333   (*)
1334         { { echo "$as_me:1334: error: ABI version is not a number: $cf_cv_abi_version" >&5
1335 echo "$as_me: error: ABI version is not a number: $cf_cv_abi_version" >&2;}
1336    { (exit 1); exit 1; }; }
1337         ;;
1338   esac
1339 else
1340   { { echo "$as_me:1340: error: ABI version value is empty" >&5
1341 echo "$as_me: error: ABI version value is empty" >&2;}
1342    { (exit 1); exit 1; }; }
1343 fi
1344
1345 if test "x$cf_cv_abi_version" != "x$with_abi_version"
1346 then
1347         case $cf_cv_rel_version in
1348         (5.*)
1349                 cf_cv_rel_version=$with_abi_version.0
1350                 ;;
1351         esac
1352 fi
1353
1354 ac_aux_dir=
1355 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
1356   if test -f $ac_dir/install-sh; then
1357     ac_aux_dir=$ac_dir
1358     ac_install_sh="$ac_aux_dir/install-sh -c"
1359     break
1360   elif test -f $ac_dir/install.sh; then
1361     ac_aux_dir=$ac_dir
1362     ac_install_sh="$ac_aux_dir/install.sh -c"
1363     break
1364   elif test -f $ac_dir/shtool; then
1365     ac_aux_dir=$ac_dir
1366     ac_install_sh="$ac_aux_dir/shtool install -c"
1367     break
1368   fi
1369 done
1370 if test -z "$ac_aux_dir"; then
1371   { { echo "$as_me:1371: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
1372 echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
1373    { (exit 1); exit 1; }; }
1374 fi
1375 ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1376 ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1377 ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
1378
1379 # Make sure we can run config.sub.
1380 $ac_config_sub sun4 >/dev/null 2>&1 ||
1381   { { echo "$as_me:1381: error: cannot run $ac_config_sub" >&5
1382 echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1383    { (exit 1); exit 1; }; }
1384
1385 echo "$as_me:1385: checking build system type" >&5
1386 echo $ECHO_N "checking build system type... $ECHO_C" >&6
1387 if test "${ac_cv_build+set}" = set; then
1388   echo $ECHO_N "(cached) $ECHO_C" >&6
1389 else
1390   ac_cv_build_alias=$build_alias
1391 test -z "$ac_cv_build_alias" &&
1392   ac_cv_build_alias=`$ac_config_guess`
1393 test -z "$ac_cv_build_alias" &&
1394   { { echo "$as_me:1394: error: cannot guess build type; you must specify one" >&5
1395 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1396    { (exit 1); exit 1; }; }
1397 ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
1398   { { echo "$as_me:1398: error: $ac_config_sub $ac_cv_build_alias failed." >&5
1399 echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed." >&2;}
1400    { (exit 1); exit 1; }; }
1401
1402 fi
1403 echo "$as_me:1403: result: $ac_cv_build" >&5
1404 echo "${ECHO_T}$ac_cv_build" >&6
1405 build=$ac_cv_build
1406 build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1407 build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1408 build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1409
1410 echo "$as_me:1410: checking host system type" >&5
1411 echo $ECHO_N "checking host system type... $ECHO_C" >&6
1412 if test "${ac_cv_host+set}" = set; then
1413   echo $ECHO_N "(cached) $ECHO_C" >&6
1414 else
1415   ac_cv_host_alias=$host_alias
1416 test -z "$ac_cv_host_alias" &&
1417   ac_cv_host_alias=$ac_cv_build_alias
1418 ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
1419   { { echo "$as_me:1419: error: $ac_config_sub $ac_cv_host_alias failed" >&5
1420 echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1421    { (exit 1); exit 1; }; }
1422
1423 fi
1424 echo "$as_me:1424: result: $ac_cv_host" >&5
1425 echo "${ECHO_T}$ac_cv_host" >&6
1426 host=$ac_cv_host
1427 host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1428 host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1429 host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1430
1431 if test -f $srcdir/config.guess || test -f $ac_aux_dir/config.guess ; then
1432         echo "$as_me:1432: checking target system type" >&5
1433 echo $ECHO_N "checking target system type... $ECHO_C" >&6
1434 if test "${ac_cv_target+set}" = set; then
1435   echo $ECHO_N "(cached) $ECHO_C" >&6
1436 else
1437   ac_cv_target_alias=$target_alias
1438 test "x$ac_cv_target_alias" = "x" &&
1439   ac_cv_target_alias=$ac_cv_host_alias
1440 ac_cv_target=`$ac_config_sub $ac_cv_target_alias` ||
1441   { { echo "$as_me:1441: error: $ac_config_sub $ac_cv_target_alias failed" >&5
1442 echo "$as_me: error: $ac_config_sub $ac_cv_target_alias failed" >&2;}
1443    { (exit 1); exit 1; }; }
1444
1445 fi
1446 echo "$as_me:1446: result: $ac_cv_target" >&5
1447 echo "${ECHO_T}$ac_cv_target" >&6
1448 target=$ac_cv_target
1449 target_cpu=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1450 target_vendor=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1451 target_os=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1452
1453 # The aliases save the names the user supplied, while $host etc.
1454 # will get canonicalized.
1455 test -n "$target_alias" &&
1456   test "$program_prefix$program_suffix$program_transform_name" = \
1457     NONENONEs,x,x, &&
1458   program_prefix=${target_alias}-
1459         system_name="$host_os"
1460 else
1461         system_name="`(uname -s -r) 2>/dev/null`"
1462         if test -z "$system_name" ; then
1463                 system_name="`(hostname) 2>/dev/null`"
1464         fi
1465 fi
1466 test -n "$system_name" &&
1467 cat >>confdefs.h <<EOF
1468 #define SYSTEM_NAME "$system_name"
1469 EOF
1470
1471 if test "${cf_cv_system_name+set}" = set; then
1472   echo $ECHO_N "(cached) $ECHO_C" >&6
1473 else
1474   cf_cv_system_name="$system_name"
1475 fi
1476
1477 test -z "$system_name" && system_name="$cf_cv_system_name"
1478 test -n "$cf_cv_system_name" && echo "$as_me:1478: result: Configuring for $cf_cv_system_name" >&5
1479 echo "${ECHO_T}Configuring for $cf_cv_system_name" >&6
1480
1481 if test ".$system_name" != ".$cf_cv_system_name" ; then
1482         echo "$as_me:1482: result: Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&5
1483 echo "${ECHO_T}Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&6
1484         { { echo "$as_me:1484: error: \"Please remove config.cache and try again.\"" >&5
1485 echo "$as_me: error: \"Please remove config.cache and try again.\"" >&2;}
1486    { (exit 1); exit 1; }; }
1487 fi
1488
1489 # Check whether --with-system-type or --without-system-type was given.
1490 if test "${with_system_type+set}" = set; then
1491   withval="$with_system_type"
1492   { echo "$as_me:1492: WARNING: overriding system type to $withval" >&5
1493 echo "$as_me: WARNING: overriding system type to $withval" >&2;}
1494         cf_cv_system_name=$withval
1495         host_os=$withval
1496
1497 fi;
1498
1499 ###     Save the given $CFLAGS to allow user-override.
1500 cf_user_CFLAGS="$CFLAGS"
1501
1502 ###     Default install-location
1503
1504 echo "$as_me:1504: checking for prefix" >&5
1505 echo $ECHO_N "checking for prefix... $ECHO_C" >&6
1506 if test "x$prefix" = "xNONE" ; then
1507         case "$cf_cv_system_name" in
1508                 # non-vendor systems don't have a conflict
1509         (openbsd*|freebsd*|mirbsd*|linux*|cygwin*|msys*|k*bsd*-gnu|mingw*)
1510                 prefix=/usr
1511                 ;;
1512         (*)     prefix=$ac_default_prefix
1513                 ;;
1514         esac
1515 fi
1516 echo "$as_me:1516: result: $prefix" >&5
1517 echo "${ECHO_T}$prefix" >&6
1518
1519 if test "x$prefix" = "xNONE" ; then
1520 echo "$as_me:1520: checking for default include-directory" >&5
1521 echo $ECHO_N "checking for default include-directory... $ECHO_C" >&6
1522 test -n "$verbose" && echo 1>&6
1523 for cf_symbol in \
1524         $includedir \
1525         $includedir/ncurses \
1526         $prefix/include \
1527         $prefix/include/ncurses \
1528         /usr/local/include \
1529         /usr/local/include/ncurses \
1530         /usr/include \
1531         /usr/include/ncurses
1532 do
1533         cf_dir=`eval echo $cf_symbol`
1534         if test -f $cf_dir/curses.h ; then
1535         if ( fgrep NCURSES_VERSION $cf_dir/curses.h 2>&1 >/dev/null ) ; then
1536                 includedir="$cf_symbol"
1537                 test -n "$verbose"  && echo $ac_n "     found " 1>&6
1538                 break
1539         fi
1540         fi
1541         test -n "$verbose"  && echo "   tested $cf_dir" 1>&6
1542 done
1543 echo "$as_me:1543: result: $includedir" >&5
1544 echo "${ECHO_T}$includedir" >&6
1545 fi
1546
1547 ### Defaults for ncurses ABI
1548
1549 case x$cf_cv_abi_version in
1550 (x[6789])
1551         cf_dft_ext_colors=yes
1552         cf_dft_ext_const=yes
1553         cf_dft_ext_mouse=yes
1554         cf_dft_ext_putwin=yes
1555         cf_dft_ext_spfuncs=yes
1556         cf_dft_filter_syms=yes
1557         cf_dft_chtype=uint32_t
1558         cf_dft_mmask_t=uint32_t
1559         cf_dft_interop=yes
1560         cf_dft_tparm_arg=intptr_t
1561         cf_dft_with_lp64=yes
1562         ;;
1563 (*)
1564         cf_dft_ext_colors=no
1565         cf_dft_ext_const=no
1566         cf_dft_ext_mouse=no
1567         cf_dft_ext_putwin=no
1568         cf_dft_ext_spfuncs=no
1569         cf_dft_filter_syms=no
1570         cf_dft_chtype=auto
1571         cf_dft_mmask_t=auto
1572         cf_dft_interop=no
1573         cf_dft_tparm_arg=long
1574         cf_dft_with_lp64=no
1575         ;;
1576 esac
1577
1578 ###     Checks for programs.
1579
1580 # Check whether --with-ada or --without-ada was given.
1581 if test "${with_ada+set}" = set; then
1582   withval="$with_ada"
1583   cf_with_ada=$withval
1584 else
1585   cf_with_ada=yes
1586 fi;
1587 if test "x$cf_with_ada" = xyes
1588 then
1589         cf_PROG_CC="gnatgcc gcc cc"
1590 else
1591         cf_PROG_CC="gcc cc"
1592 fi
1593
1594 ac_ext=c
1595 ac_cpp='$CPP $CPPFLAGS'
1596 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1597 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1598 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1599 ac_main_return=return
1600 if test -n "$ac_tool_prefix"; then
1601   for ac_prog in $cf_PROG_CC
1602   do
1603     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
1604 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
1605 echo "$as_me:1605: checking for $ac_word" >&5
1606 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1607 if test "${ac_cv_prog_CC+set}" = set; then
1608   echo $ECHO_N "(cached) $ECHO_C" >&6
1609 else
1610   if test -n "$CC"; then
1611   ac_cv_prog_CC="$CC" # Let the user override the test.
1612 else
1613   ac_save_IFS=$IFS; IFS=$ac_path_separator
1614 ac_dummy="$PATH"
1615 for ac_dir in $ac_dummy; do
1616   IFS=$ac_save_IFS
1617   test -z "$ac_dir" && ac_dir=.
1618   $as_executable_p "$ac_dir/$ac_word" || continue
1619 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
1620 echo "$as_me:1620: found $ac_dir/$ac_word" >&5
1621 break
1622 done
1623
1624 fi
1625 fi
1626 CC=$ac_cv_prog_CC
1627 if test -n "$CC"; then
1628   echo "$as_me:1628: result: $CC" >&5
1629 echo "${ECHO_T}$CC" >&6
1630 else
1631   echo "$as_me:1631: result: no" >&5
1632 echo "${ECHO_T}no" >&6
1633 fi
1634
1635     test -n "$CC" && break
1636   done
1637 fi
1638 if test -z "$CC"; then
1639   ac_ct_CC=$CC
1640   for ac_prog in $cf_PROG_CC
1641 do
1642   # Extract the first word of "$ac_prog", so it can be a program name with args.
1643 set dummy $ac_prog; ac_word=$2
1644 echo "$as_me:1644: checking for $ac_word" >&5
1645 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1646 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1647   echo $ECHO_N "(cached) $ECHO_C" >&6
1648 else
1649   if test -n "$ac_ct_CC"; then
1650   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1651 else
1652   ac_save_IFS=$IFS; IFS=$ac_path_separator
1653 ac_dummy="$PATH"
1654 for ac_dir in $ac_dummy; do
1655   IFS=$ac_save_IFS
1656   test -z "$ac_dir" && ac_dir=.
1657   $as_executable_p "$ac_dir/$ac_word" || continue
1658 ac_cv_prog_ac_ct_CC="$ac_prog"
1659 echo "$as_me:1659: found $ac_dir/$ac_word" >&5
1660 break
1661 done
1662
1663 fi
1664 fi
1665 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1666 if test -n "$ac_ct_CC"; then
1667   echo "$as_me:1667: result: $ac_ct_CC" >&5
1668 echo "${ECHO_T}$ac_ct_CC" >&6
1669 else
1670   echo "$as_me:1670: result: no" >&5
1671 echo "${ECHO_T}no" >&6
1672 fi
1673
1674   test -n "$ac_ct_CC" && break
1675 done
1676
1677   CC=$ac_ct_CC
1678 fi
1679
1680 test -z "$CC" && { { echo "$as_me:1680: error: no acceptable cc found in \$PATH" >&5
1681 echo "$as_me: error: no acceptable cc found in \$PATH" >&2;}
1682    { (exit 1); exit 1; }; }
1683
1684 # Provide some information about the compiler.
1685 echo "$as_me:1685:" \
1686      "checking for C compiler version" >&5
1687 ac_compiler=`set X $ac_compile; echo $2`
1688 { (eval echo "$as_me:1688: \"$ac_compiler --version </dev/null >&5\"") >&5
1689   (eval $ac_compiler --version </dev/null >&5) 2>&5
1690   ac_status=$?
1691   echo "$as_me:1691: \$? = $ac_status" >&5
1692   (exit $ac_status); }
1693 { (eval echo "$as_me:1693: \"$ac_compiler -v </dev/null >&5\"") >&5
1694   (eval $ac_compiler -v </dev/null >&5) 2>&5
1695   ac_status=$?
1696   echo "$as_me:1696: \$? = $ac_status" >&5
1697   (exit $ac_status); }
1698 { (eval echo "$as_me:1698: \"$ac_compiler -V </dev/null >&5\"") >&5
1699   (eval $ac_compiler -V </dev/null >&5) 2>&5
1700   ac_status=$?
1701   echo "$as_me:1701: \$? = $ac_status" >&5
1702   (exit $ac_status); }
1703
1704 cat >conftest.$ac_ext <<_ACEOF
1705 #line 1705 "configure"
1706 #include "confdefs.h"
1707
1708 int
1709 main (void)
1710 {
1711
1712   ;
1713   return 0;
1714 }
1715 _ACEOF
1716 ac_clean_files_save=$ac_clean_files
1717 ac_clean_files="$ac_clean_files a.out a.exe"
1718 # Try to create an executable without -o first, disregard a.out.
1719 # It will help us diagnose broken compilers, and finding out an intuition
1720 # of exeext.
1721 echo "$as_me:1721: checking for C compiler default output" >&5
1722 echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
1723 ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
1724 if { (eval echo "$as_me:1724: \"$ac_link_default\"") >&5
1725   (eval $ac_link_default) 2>&5
1726   ac_status=$?
1727   echo "$as_me:1727: \$? = $ac_status" >&5
1728   (exit $ac_status); }; then
1729   # Find the output, starting from the most likely.  This scheme is
1730 # not robust to junk in `.', hence go to wildcards (a.*) only as a last
1731 # resort.
1732 for ac_file in `ls a.exe conftest.exe 2>/dev/null;
1733                 ls a.out conftest 2>/dev/null;
1734                 ls a.* conftest.* 2>/dev/null`; do
1735   case $ac_file in
1736     *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1737     a.out ) # We found the default executable, but exeext='' is most
1738             # certainly right.
1739             break;;
1740     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1741           # FIXME: I believe we export ac_cv_exeext for Libtool --akim.
1742           export ac_cv_exeext
1743           break;;
1744     * ) break;;
1745   esac
1746 done
1747 else
1748   echo "$as_me: failed program was:" >&5
1749 cat conftest.$ac_ext >&5
1750 { { echo "$as_me:1750: error: C compiler cannot create executables" >&5
1751 echo "$as_me: error: C compiler cannot create executables" >&2;}
1752    { (exit 77); exit 77; }; }
1753 fi
1754
1755 ac_exeext=$ac_cv_exeext
1756 echo "$as_me:1756: result: $ac_file" >&5
1757 echo "${ECHO_T}$ac_file" >&6
1758
1759 # Check the compiler produces executables we can run.  If not, either
1760 # the compiler is broken, or we cross compile.
1761 echo "$as_me:1761: checking whether the C compiler works" >&5
1762 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
1763 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
1764 # If not cross compiling, check that we can run a simple program.
1765 if test "$cross_compiling" != yes; then
1766   if { ac_try='./$ac_file'
1767   { (eval echo "$as_me:1767: \"$ac_try\"") >&5
1768   (eval $ac_try) 2>&5
1769   ac_status=$?
1770   echo "$as_me:1770: \$? = $ac_status" >&5
1771   (exit $ac_status); }; }; then
1772     cross_compiling=no
1773   else
1774     if test "$cross_compiling" = maybe; then
1775         cross_compiling=yes
1776     else
1777         { { echo "$as_me:1777: error: cannot run C compiled programs.
1778 If you meant to cross compile, use \`--host'." >&5
1779 echo "$as_me: error: cannot run C compiled programs.
1780 If you meant to cross compile, use \`--host'." >&2;}
1781    { (exit 1); exit 1; }; }
1782     fi
1783   fi
1784 fi
1785 echo "$as_me:1785: result: yes" >&5
1786 echo "${ECHO_T}yes" >&6
1787
1788 rm -f a.out a.exe conftest$ac_cv_exeext
1789 ac_clean_files=$ac_clean_files_save
1790 # Check the compiler produces executables we can run.  If not, either
1791 # the compiler is broken, or we cross compile.
1792 echo "$as_me:1792: checking whether we are cross compiling" >&5
1793 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
1794 echo "$as_me:1794: result: $cross_compiling" >&5
1795 echo "${ECHO_T}$cross_compiling" >&6
1796
1797 echo "$as_me:1797: checking for executable suffix" >&5
1798 echo $ECHO_N "checking for executable suffix... $ECHO_C" >&6
1799 if { (eval echo "$as_me:1799: \"$ac_link\"") >&5
1800   (eval $ac_link) 2>&5
1801   ac_status=$?
1802   echo "$as_me:1802: \$? = $ac_status" >&5
1803   (exit $ac_status); }; then
1804   # If both `conftest.exe' and `conftest' are `present' (well, observable)
1805 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
1806 # work properly (i.e., refer to `conftest.exe'), while it won't with
1807 # `rm'.
1808 for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do
1809   case $ac_file in
1810     *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1811     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1812           export ac_cv_exeext
1813           break;;
1814     * ) break;;
1815   esac
1816 done
1817 else
1818   { { echo "$as_me:1818: error: cannot compute EXEEXT: cannot compile and link" >&5
1819 echo "$as_me: error: cannot compute EXEEXT: cannot compile and link" >&2;}
1820    { (exit 1); exit 1; }; }
1821 fi
1822
1823 rm -f conftest$ac_cv_exeext
1824 echo "$as_me:1824: result: $ac_cv_exeext" >&5
1825 echo "${ECHO_T}$ac_cv_exeext" >&6
1826
1827 rm -f conftest.$ac_ext
1828 EXEEXT=$ac_cv_exeext
1829 ac_exeext=$EXEEXT
1830 echo "$as_me:1830: checking for object suffix" >&5
1831 echo $ECHO_N "checking for object suffix... $ECHO_C" >&6
1832 if test "${ac_cv_objext+set}" = set; then
1833   echo $ECHO_N "(cached) $ECHO_C" >&6
1834 else
1835   cat >conftest.$ac_ext <<_ACEOF
1836 #line 1836 "configure"
1837 #include "confdefs.h"
1838
1839 int
1840 main (void)
1841 {
1842
1843   ;
1844   return 0;
1845 }
1846 _ACEOF
1847 rm -f conftest.o conftest.obj
1848 if { (eval echo "$as_me:1848: \"$ac_compile\"") >&5
1849   (eval $ac_compile) 2>&5
1850   ac_status=$?
1851   echo "$as_me:1851: \$? = $ac_status" >&5
1852   (exit $ac_status); }; then
1853   for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
1854   case $ac_file in
1855     *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.map | *.inf ) ;;
1856     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
1857        break;;
1858   esac
1859 done
1860 else
1861   echo "$as_me: failed program was:" >&5
1862 cat conftest.$ac_ext >&5
1863 { { echo "$as_me:1863: error: cannot compute OBJEXT: cannot compile" >&5
1864 echo "$as_me: error: cannot compute OBJEXT: cannot compile" >&2;}
1865    { (exit 1); exit 1; }; }
1866 fi
1867
1868 rm -f conftest.$ac_cv_objext conftest.$ac_ext
1869 fi
1870 echo "$as_me:1870: result: $ac_cv_objext" >&5
1871 echo "${ECHO_T}$ac_cv_objext" >&6
1872 OBJEXT=$ac_cv_objext
1873 ac_objext=$OBJEXT
1874 echo "$as_me:1874: checking whether we are using the GNU C compiler" >&5
1875 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
1876 if test "${ac_cv_c_compiler_gnu+set}" = set; then
1877   echo $ECHO_N "(cached) $ECHO_C" >&6
1878 else
1879   cat >conftest.$ac_ext <<_ACEOF
1880 #line 1880 "configure"
1881 #include "confdefs.h"
1882
1883 int
1884 main (void)
1885 {
1886 #ifndef __GNUC__
1887        choke me
1888 #endif
1889
1890   ;
1891   return 0;
1892 }
1893 _ACEOF
1894 rm -f conftest.$ac_objext
1895 if { (eval echo "$as_me:1895: \"$ac_compile\"") >&5
1896   (eval $ac_compile) 2>&5
1897   ac_status=$?
1898   echo "$as_me:1898: \$? = $ac_status" >&5
1899   (exit $ac_status); } &&
1900          { ac_try='test -s conftest.$ac_objext'
1901   { (eval echo "$as_me:1901: \"$ac_try\"") >&5
1902   (eval $ac_try) 2>&5
1903   ac_status=$?
1904   echo "$as_me:1904: \$? = $ac_status" >&5
1905   (exit $ac_status); }; }; then
1906   ac_compiler_gnu=yes
1907 else
1908   echo "$as_me: failed program was:" >&5
1909 cat conftest.$ac_ext >&5
1910 ac_compiler_gnu=no
1911 fi
1912 rm -f conftest.$ac_objext conftest.$ac_ext
1913 ac_cv_c_compiler_gnu=$ac_compiler_gnu
1914
1915 fi
1916 echo "$as_me:1916: result: $ac_cv_c_compiler_gnu" >&5
1917 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
1918 GCC=`test $ac_compiler_gnu = yes && echo yes`
1919 ac_test_CFLAGS=${CFLAGS+set}
1920 ac_save_CFLAGS=$CFLAGS
1921 CFLAGS="-g"
1922 echo "$as_me:1922: checking whether $CC accepts -g" >&5
1923 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
1924 if test "${ac_cv_prog_cc_g+set}" = set; then
1925   echo $ECHO_N "(cached) $ECHO_C" >&6
1926 else
1927   cat >conftest.$ac_ext <<_ACEOF
1928 #line 1928 "configure"
1929 #include "confdefs.h"
1930
1931 int
1932 main (void)
1933 {
1934
1935   ;
1936   return 0;
1937 }
1938 _ACEOF
1939 rm -f conftest.$ac_objext
1940 if { (eval echo "$as_me:1940: \"$ac_compile\"") >&5
1941   (eval $ac_compile) 2>&5
1942   ac_status=$?
1943   echo "$as_me:1943: \$? = $ac_status" >&5
1944   (exit $ac_status); } &&
1945          { ac_try='test -s conftest.$ac_objext'
1946   { (eval echo "$as_me:1946: \"$ac_try\"") >&5
1947   (eval $ac_try) 2>&5
1948   ac_status=$?
1949   echo "$as_me:1949: \$? = $ac_status" >&5
1950   (exit $ac_status); }; }; then
1951   ac_cv_prog_cc_g=yes
1952 else
1953   echo "$as_me: failed program was:" >&5
1954 cat conftest.$ac_ext >&5
1955 ac_cv_prog_cc_g=no
1956 fi
1957 rm -f conftest.$ac_objext conftest.$ac_ext
1958 fi
1959 echo "$as_me:1959: result: $ac_cv_prog_cc_g" >&5
1960 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
1961 if test "$ac_test_CFLAGS" = set; then
1962   CFLAGS=$ac_save_CFLAGS
1963 elif test $ac_cv_prog_cc_g = yes; then
1964   if test "$GCC" = yes; then
1965     CFLAGS="-g -O2"
1966   else
1967     CFLAGS="-g"
1968   fi
1969 else
1970   if test "$GCC" = yes; then
1971     CFLAGS="-O2"
1972   else
1973     CFLAGS=
1974   fi
1975 fi
1976 # Some people use a C++ compiler to compile C.  Since we use `exit',
1977 # in C++ we need to declare it.  In case someone uses the same compiler
1978 # for both compiling C and C++ we need to have the C++ compiler decide
1979 # the declaration of exit, since it's the most demanding environment.
1980 cat >conftest.$ac_ext <<_ACEOF
1981 #ifndef __cplusplus
1982   choke me
1983 #endif
1984 _ACEOF
1985 rm -f conftest.$ac_objext
1986 if { (eval echo "$as_me:1986: \"$ac_compile\"") >&5
1987   (eval $ac_compile) 2>&5
1988   ac_status=$?
1989   echo "$as_me:1989: \$? = $ac_status" >&5
1990   (exit $ac_status); } &&
1991          { ac_try='test -s conftest.$ac_objext'
1992   { (eval echo "$as_me:1992: \"$ac_try\"") >&5
1993   (eval $ac_try) 2>&5
1994   ac_status=$?
1995   echo "$as_me:1995: \$? = $ac_status" >&5
1996   (exit $ac_status); }; }; then
1997   for ac_declaration in \
1998    ''\
1999    '#include <stdlib.h>' \
2000    'extern "C" void std::exit (int) throw (); using std::exit;' \
2001    'extern "C" void std::exit (int); using std::exit;' \
2002    'extern "C" void exit (int) throw ();' \
2003    'extern "C" void exit (int);' \
2004    'void exit (int);'
2005 do
2006   cat >conftest.$ac_ext <<_ACEOF
2007 #line 2007 "configure"
2008 #include "confdefs.h"
2009 #include <stdlib.h>
2010 $ac_declaration
2011 int
2012 main (void)
2013 {
2014 exit (42);
2015   ;
2016   return 0;
2017 }
2018 _ACEOF
2019 rm -f conftest.$ac_objext
2020 if { (eval echo "$as_me:2020: \"$ac_compile\"") >&5
2021   (eval $ac_compile) 2>&5
2022   ac_status=$?
2023   echo "$as_me:2023: \$? = $ac_status" >&5
2024   (exit $ac_status); } &&
2025          { ac_try='test -s conftest.$ac_objext'
2026   { (eval echo "$as_me:2026: \"$ac_try\"") >&5
2027   (eval $ac_try) 2>&5
2028   ac_status=$?
2029   echo "$as_me:2029: \$? = $ac_status" >&5
2030   (exit $ac_status); }; }; then
2031   :
2032 else
2033   echo "$as_me: failed program was:" >&5
2034 cat conftest.$ac_ext >&5
2035 continue
2036 fi
2037 rm -f conftest.$ac_objext conftest.$ac_ext
2038   cat >conftest.$ac_ext <<_ACEOF
2039 #line 2039 "configure"
2040 #include "confdefs.h"
2041 $ac_declaration
2042 int
2043 main (void)
2044 {
2045 exit (42);
2046   ;
2047   return 0;
2048 }
2049 _ACEOF
2050 rm -f conftest.$ac_objext
2051 if { (eval echo "$as_me:2051: \"$ac_compile\"") >&5
2052   (eval $ac_compile) 2>&5
2053   ac_status=$?
2054   echo "$as_me:2054: \$? = $ac_status" >&5
2055   (exit $ac_status); } &&
2056          { ac_try='test -s conftest.$ac_objext'
2057   { (eval echo "$as_me:2057: \"$ac_try\"") >&5
2058   (eval $ac_try) 2>&5
2059   ac_status=$?
2060   echo "$as_me:2060: \$? = $ac_status" >&5
2061   (exit $ac_status); }; }; then
2062   break
2063 else
2064   echo "$as_me: failed program was:" >&5
2065 cat conftest.$ac_ext >&5
2066 fi
2067 rm -f conftest.$ac_objext conftest.$ac_ext
2068 done
2069 rm -rf conftest*
2070 if test -n "$ac_declaration"; then
2071   echo '#ifdef __cplusplus' >>confdefs.h
2072   echo $ac_declaration      >>confdefs.h
2073   echo '#endif'             >>confdefs.h
2074 fi
2075
2076 else
2077   echo "$as_me: failed program was:" >&5
2078 cat conftest.$ac_ext >&5
2079 fi
2080 rm -f conftest.$ac_objext conftest.$ac_ext
2081 ac_ext=c
2082 ac_cpp='$CPP $CPPFLAGS'
2083 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2084 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2085 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2086 ac_main_return=return
2087
2088 GCC_VERSION=none
2089 if test "$GCC" = yes ; then
2090         echo "$as_me:2090: checking version of $CC" >&5
2091 echo $ECHO_N "checking version of $CC... $ECHO_C" >&6
2092         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.].*//'`"
2093         test -z "$GCC_VERSION" && GCC_VERSION=unknown
2094         echo "$as_me:2094: result: $GCC_VERSION" >&5
2095 echo "${ECHO_T}$GCC_VERSION" >&6
2096 fi
2097
2098 echo "$as_me:2098: checking for $CC option to accept ANSI C" >&5
2099 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
2100 if test "${ac_cv_prog_cc_stdc+set}" = set; then
2101   echo $ECHO_N "(cached) $ECHO_C" >&6
2102 else
2103   ac_cv_prog_cc_stdc=no
2104 ac_save_CC=$CC
2105 cat >conftest.$ac_ext <<_ACEOF
2106 #line 2106 "configure"
2107 #include "confdefs.h"
2108 #include <stdarg.h>
2109 #include <stdio.h>
2110 #include <sys/types.h>
2111 #include <sys/stat.h>
2112 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
2113 struct buf { int x; };
2114 FILE * (*rcsopen) (struct buf *, struct stat *, int);
2115 static char *e (p, i)
2116      char **p;
2117      int i;
2118 {
2119   return p[i];
2120 }
2121 static char *f (char * (*g) (char **, int), char **p, ...)
2122 {
2123   char *s;
2124   va_list v;
2125   va_start (v,p);
2126   s = g (p, va_arg (v,int));
2127   va_end (v);
2128   return s;
2129 }
2130 int test (int i, double x);
2131 struct s1 {int (*f) (int a);};
2132 struct s2 {int (*f) (double a);};
2133 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
2134 int argc;
2135 char **argv;
2136 int
2137 main (void)
2138 {
2139 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
2140   ;
2141   return 0;
2142 }
2143 _ACEOF
2144 # Don't try gcc -ansi; that turns off useful extensions and
2145 # breaks some systems' header files.
2146 # AIX                   -qlanglvl=ansi
2147 # Ultrix and OSF/1      -std1
2148 # HP-UX 10.20 and later -Ae
2149 # HP-UX older versions  -Aa -D_HPUX_SOURCE
2150 # SVR4                  -Xc -D__EXTENSIONS__
2151 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
2152 do
2153   CC="$ac_save_CC $ac_arg"
2154   rm -f conftest.$ac_objext
2155 if { (eval echo "$as_me:2155: \"$ac_compile\"") >&5
2156   (eval $ac_compile) 2>&5
2157   ac_status=$?
2158   echo "$as_me:2158: \$? = $ac_status" >&5
2159   (exit $ac_status); } &&
2160          { ac_try='test -s conftest.$ac_objext'
2161   { (eval echo "$as_me:2161: \"$ac_try\"") >&5
2162   (eval $ac_try) 2>&5
2163   ac_status=$?
2164   echo "$as_me:2164: \$? = $ac_status" >&5
2165   (exit $ac_status); }; }; then
2166   ac_cv_prog_cc_stdc=$ac_arg
2167 break
2168 else
2169   echo "$as_me: failed program was:" >&5
2170 cat conftest.$ac_ext >&5
2171 fi
2172 rm -f conftest.$ac_objext
2173 done
2174 rm -f conftest.$ac_ext conftest.$ac_objext
2175 CC=$ac_save_CC
2176
2177 fi
2178
2179 case "x$ac_cv_prog_cc_stdc" in
2180   x|xno)
2181     echo "$as_me:2181: result: none needed" >&5
2182 echo "${ECHO_T}none needed" >&6 ;;
2183   *)
2184     echo "$as_me:2184: result: $ac_cv_prog_cc_stdc" >&5
2185 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
2186     CC="$CC $ac_cv_prog_cc_stdc" ;;
2187 esac
2188
2189 # This should have been defined by AC_PROG_CC
2190 : ${CC:=cc}
2191
2192 echo "$as_me:2192: checking \$CC variable" >&5
2193 echo $ECHO_N "checking \$CC variable... $ECHO_C" >&6
2194 case "$CC" in
2195 (*[\ \  ]-*)
2196         echo "$as_me:2196: result: broken" >&5
2197 echo "${ECHO_T}broken" >&6
2198         { echo "$as_me:2198: WARNING: your environment misuses the CC variable to hold CFLAGS/CPPFLAGS options" >&5
2199 echo "$as_me: WARNING: your environment misuses the CC variable to hold CFLAGS/CPPFLAGS options" >&2;}
2200         # humor him...
2201         cf_prog=`echo "$CC" | sed -e 's/        / /g' -e 's/[ ]* / /g' -e 's/[ ]*[ ]-[^ ].*//'`
2202         cf_flags=`echo "$CC" | ${AWK:-awk} -v prog="$cf_prog" '{ printf("%s", substr($0,1+length(prog))); }'`
2203         CC="$cf_prog"
2204         for cf_arg in $cf_flags
2205         do
2206                 case "x$cf_arg" in
2207                 (x-[IUDfgOW]*)
2208
2209 cf_fix_cppflags=no
2210 cf_new_cflags=
2211 cf_new_cppflags=
2212 cf_new_extra_cppflags=
2213
2214 for cf_add_cflags in $cf_arg
2215 do
2216 case $cf_fix_cppflags in
2217 (no)
2218         case $cf_add_cflags in
2219         (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
2220                 case $cf_add_cflags in
2221                 (-D*)
2222                         cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
2223
2224                         test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2225                                 && test -z "${cf_tst_cflags}" \
2226                                 && cf_fix_cppflags=yes
2227
2228                         if test $cf_fix_cppflags = yes ; then
2229
2230         test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2231         cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2232
2233                                 continue
2234                         elif test "${cf_tst_cflags}" = "\"'" ; then
2235
2236         test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2237         cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2238
2239                                 continue
2240                         fi
2241                         ;;
2242                 esac
2243                 case "$CPPFLAGS" in
2244                 (*$cf_add_cflags)
2245                         ;;
2246                 (*)
2247                         case $cf_add_cflags in
2248                         (-D*)
2249                                 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
2250
2251 CPPFLAGS=`echo "$CPPFLAGS" | \
2252         sed     -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^    ]*\)\?[         ]/ /g' \
2253                 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^    ]*\)\?$//g'`
2254
2255                                 ;;
2256                         esac
2257
2258         test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
2259         cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
2260
2261                         ;;
2262                 esac
2263                 ;;
2264         (*)
2265
2266         test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
2267         cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
2268
2269                 ;;
2270         esac
2271         ;;
2272 (yes)
2273
2274         test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2275         cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2276
2277         cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
2278
2279         test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2280                 && test -z "${cf_tst_cflags}" \
2281                 && cf_fix_cppflags=no
2282         ;;
2283 esac
2284 done
2285
2286 if test -n "$cf_new_cflags" ; then
2287
2288         test -n "$CFLAGS" && CFLAGS="$CFLAGS "
2289         CFLAGS="${CFLAGS}$cf_new_cflags"
2290
2291 fi
2292
2293 if test -n "$cf_new_cppflags" ; then
2294
2295         test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
2296         CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
2297
2298 fi
2299
2300 if test -n "$cf_new_extra_cppflags" ; then
2301
2302         test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
2303         EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
2304
2305 fi
2306
2307                         ;;
2308                 (*)
2309                         CC="$CC $cf_arg"
2310                         ;;
2311                 esac
2312         done
2313         test -n "$verbose" && echo "    resulting CC: '$CC'" 1>&6
2314
2315 echo "${as_me:-configure}:2315: testing resulting CC: '$CC' ..." 1>&5
2316
2317         test -n "$verbose" && echo "    resulting CFLAGS: '$CFLAGS'" 1>&6
2318
2319 echo "${as_me:-configure}:2319: testing resulting CFLAGS: '$CFLAGS' ..." 1>&5
2320
2321         test -n "$verbose" && echo "    resulting CPPFLAGS: '$CPPFLAGS'" 1>&6
2322
2323 echo "${as_me:-configure}:2323: testing resulting CPPFLAGS: '$CPPFLAGS' ..." 1>&5
2324
2325         ;;
2326 (*)
2327         echo "$as_me:2327: result: ok" >&5
2328 echo "${ECHO_T}ok" >&6
2329         ;;
2330 esac
2331
2332 ac_ext=c
2333 ac_cpp='$CPP $CPPFLAGS'
2334 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2335 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2336 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2337 ac_main_return=return
2338 echo "$as_me:2338: checking how to run the C preprocessor" >&5
2339 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
2340 # On Suns, sometimes $CPP names a directory.
2341 if test -n "$CPP" && test -d "$CPP"; then
2342   CPP=
2343 fi
2344 if test -z "$CPP"; then
2345   if test "${ac_cv_prog_CPP+set}" = set; then
2346   echo $ECHO_N "(cached) $ECHO_C" >&6
2347 else
2348       # Double quotes because CPP needs to be expanded
2349     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
2350     do
2351       ac_preproc_ok=false
2352 for ac_c_preproc_warn_flag in '' yes
2353 do
2354   # Use a header file that comes with gcc, so configuring glibc
2355   # with a fresh cross-compiler works.
2356   # On the NeXT, cc -E runs the code through the compiler's parser,
2357   # not just through cpp. "Syntax error" is here to catch this case.
2358   cat >conftest.$ac_ext <<_ACEOF
2359 #line 2359 "configure"
2360 #include "confdefs.h"
2361 #include <assert.h>
2362                      Syntax error
2363 _ACEOF
2364 if { (eval echo "$as_me:2364: \"$ac_cpp conftest.$ac_ext\"") >&5
2365   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2366   ac_status=$?
2367   egrep -v '^ *\+' conftest.er1 >conftest.err
2368   rm -f conftest.er1
2369   cat conftest.err >&5
2370   echo "$as_me:2370: \$? = $ac_status" >&5
2371   (exit $ac_status); } >/dev/null; then
2372   if test -s conftest.err; then
2373     ac_cpp_err=$ac_c_preproc_warn_flag
2374   else
2375     ac_cpp_err=
2376   fi
2377 else
2378   ac_cpp_err=yes
2379 fi
2380 if test -z "$ac_cpp_err"; then
2381   :
2382 else
2383   echo "$as_me: failed program was:" >&5
2384   cat conftest.$ac_ext >&5
2385   # Broken: fails on valid input.
2386 continue
2387 fi
2388 rm -f conftest.err conftest.$ac_ext
2389
2390   # OK, works on sane cases.  Now check whether non-existent headers
2391   # can be detected and how.
2392   cat >conftest.$ac_ext <<_ACEOF
2393 #line 2393 "configure"
2394 #include "confdefs.h"
2395 #include <ac_nonexistent.h>
2396 _ACEOF
2397 if { (eval echo "$as_me:2397: \"$ac_cpp conftest.$ac_ext\"") >&5
2398   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2399   ac_status=$?
2400   egrep -v '^ *\+' conftest.er1 >conftest.err
2401   rm -f conftest.er1
2402   cat conftest.err >&5
2403   echo "$as_me:2403: \$? = $ac_status" >&5
2404   (exit $ac_status); } >/dev/null; then
2405   if test -s conftest.err; then
2406     ac_cpp_err=$ac_c_preproc_warn_flag
2407   else
2408     ac_cpp_err=
2409   fi
2410 else
2411   ac_cpp_err=yes
2412 fi
2413 if test -z "$ac_cpp_err"; then
2414   # Broken: success on invalid input.
2415 continue
2416 else
2417   echo "$as_me: failed program was:" >&5
2418   cat conftest.$ac_ext >&5
2419   # Passes both tests.
2420 ac_preproc_ok=:
2421 break
2422 fi
2423 rm -f conftest.err conftest.$ac_ext
2424
2425 done
2426 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2427 rm -f conftest.err conftest.$ac_ext
2428 if $ac_preproc_ok; then
2429   break
2430 fi
2431
2432     done
2433     ac_cv_prog_CPP=$CPP
2434
2435 fi
2436   CPP=$ac_cv_prog_CPP
2437 else
2438   ac_cv_prog_CPP=$CPP
2439 fi
2440 echo "$as_me:2440: result: $CPP" >&5
2441 echo "${ECHO_T}$CPP" >&6
2442 ac_preproc_ok=false
2443 for ac_c_preproc_warn_flag in '' yes
2444 do
2445   # Use a header file that comes with gcc, so configuring glibc
2446   # with a fresh cross-compiler works.
2447   # On the NeXT, cc -E runs the code through the compiler's parser,
2448   # not just through cpp. "Syntax error" is here to catch this case.
2449   cat >conftest.$ac_ext <<_ACEOF
2450 #line 2450 "configure"
2451 #include "confdefs.h"
2452 #include <assert.h>
2453                      Syntax error
2454 _ACEOF
2455 if { (eval echo "$as_me:2455: \"$ac_cpp conftest.$ac_ext\"") >&5
2456   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2457   ac_status=$?
2458   egrep -v '^ *\+' conftest.er1 >conftest.err
2459   rm -f conftest.er1
2460   cat conftest.err >&5
2461   echo "$as_me:2461: \$? = $ac_status" >&5
2462   (exit $ac_status); } >/dev/null; then
2463   if test -s conftest.err; then
2464     ac_cpp_err=$ac_c_preproc_warn_flag
2465   else
2466     ac_cpp_err=
2467   fi
2468 else
2469   ac_cpp_err=yes
2470 fi
2471 if test -z "$ac_cpp_err"; then
2472   :
2473 else
2474   echo "$as_me: failed program was:" >&5
2475   cat conftest.$ac_ext >&5
2476   # Broken: fails on valid input.
2477 continue
2478 fi
2479 rm -f conftest.err conftest.$ac_ext
2480
2481   # OK, works on sane cases.  Now check whether non-existent headers
2482   # can be detected and how.
2483   cat >conftest.$ac_ext <<_ACEOF
2484 #line 2484 "configure"
2485 #include "confdefs.h"
2486 #include <ac_nonexistent.h>
2487 _ACEOF
2488 if { (eval echo "$as_me:2488: \"$ac_cpp conftest.$ac_ext\"") >&5
2489   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2490   ac_status=$?
2491   egrep -v '^ *\+' conftest.er1 >conftest.err
2492   rm -f conftest.er1
2493   cat conftest.err >&5
2494   echo "$as_me:2494: \$? = $ac_status" >&5
2495   (exit $ac_status); } >/dev/null; then
2496   if test -s conftest.err; then
2497     ac_cpp_err=$ac_c_preproc_warn_flag
2498   else
2499     ac_cpp_err=
2500   fi
2501 else
2502   ac_cpp_err=yes
2503 fi
2504 if test -z "$ac_cpp_err"; then
2505   # Broken: success on invalid input.
2506 continue
2507 else
2508   echo "$as_me: failed program was:" >&5
2509   cat conftest.$ac_ext >&5
2510   # Passes both tests.
2511 ac_preproc_ok=:
2512 break
2513 fi
2514 rm -f conftest.err conftest.$ac_ext
2515
2516 done
2517 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2518 rm -f conftest.err conftest.$ac_ext
2519 if $ac_preproc_ok; then
2520   :
2521 else
2522   { { echo "$as_me:2522: error: C preprocessor \"$CPP\" fails sanity check" >&5
2523 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;}
2524    { (exit 1); exit 1; }; }
2525 fi
2526
2527 ac_ext=c
2528 ac_cpp='$CPP $CPPFLAGS'
2529 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2530 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2531 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2532 ac_main_return=return
2533
2534 if test $ac_cv_c_compiler_gnu = yes; then
2535     echo "$as_me:2535: checking whether $CC needs -traditional" >&5
2536 echo $ECHO_N "checking whether $CC needs -traditional... $ECHO_C" >&6
2537 if test "${ac_cv_prog_gcc_traditional+set}" = set; then
2538   echo $ECHO_N "(cached) $ECHO_C" >&6
2539 else
2540     ac_pattern="Autoconf.*'x'"
2541   cat >conftest.$ac_ext <<_ACEOF
2542 #line 2542 "configure"
2543 #include "confdefs.h"
2544 #include <sgtty.h>
2545 int Autoconf = TIOCGETP;
2546 _ACEOF
2547 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2548   egrep "$ac_pattern" >/dev/null 2>&1; then
2549   ac_cv_prog_gcc_traditional=yes
2550 else
2551   ac_cv_prog_gcc_traditional=no
2552 fi
2553 rm -rf conftest*
2554
2555   if test $ac_cv_prog_gcc_traditional = no; then
2556     cat >conftest.$ac_ext <<_ACEOF
2557 #line 2557 "configure"
2558 #include "confdefs.h"
2559 #include <termio.h>
2560 int Autoconf = TCGETA;
2561 _ACEOF
2562 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2563   egrep "$ac_pattern" >/dev/null 2>&1; then
2564   ac_cv_prog_gcc_traditional=yes
2565 fi
2566 rm -rf conftest*
2567
2568   fi
2569 fi
2570 echo "$as_me:2570: result: $ac_cv_prog_gcc_traditional" >&5
2571 echo "${ECHO_T}$ac_cv_prog_gcc_traditional" >&6
2572   if test $ac_cv_prog_gcc_traditional = yes; then
2573     CC="$CC -traditional"
2574   fi
2575 fi
2576
2577 echo "$as_me:2577: checking whether $CC understands -c and -o together" >&5
2578 echo $ECHO_N "checking whether $CC understands -c and -o together... $ECHO_C" >&6
2579 if test "${cf_cv_prog_CC_c_o+set}" = set; then
2580   echo $ECHO_N "(cached) $ECHO_C" >&6
2581 else
2582
2583 cat > conftest.$ac_ext <<CF_EOF
2584 int main(void)
2585 {
2586         ${cf_cv_main_return:-return}(0);
2587 }
2588 CF_EOF
2589 # We do the test twice because some compilers refuse to overwrite an
2590 # existing .o file with -o, though they will create one.
2591 ac_try='$CC $CFLAGS $CPPFLAGS -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
2592 if { (eval echo "$as_me:2592: \"$ac_try\"") >&5
2593   (eval $ac_try) 2>&5
2594   ac_status=$?
2595   echo "$as_me:2595: \$? = $ac_status" >&5
2596   (exit $ac_status); } &&
2597   test -f conftest2.$ac_objext && { (eval echo "$as_me:2597: \"$ac_try\"") >&5
2598   (eval $ac_try) 2>&5
2599   ac_status=$?
2600   echo "$as_me:2600: \$? = $ac_status" >&5
2601   (exit $ac_status); };
2602 then
2603   eval cf_cv_prog_CC_c_o=yes
2604 else
2605   eval cf_cv_prog_CC_c_o=no
2606 fi
2607 rm -rf conftest*
2608
2609 fi
2610 if test $cf_cv_prog_CC_c_o = yes; then
2611   echo "$as_me:2611: result: yes" >&5
2612 echo "${ECHO_T}yes" >&6
2613 else
2614   echo "$as_me:2614: result: no" >&5
2615 echo "${ECHO_T}no" >&6
2616 fi
2617
2618 if test "$cross_compiling" = yes ; then
2619         LDCONFIG=:
2620 else
2621         case "$cf_cv_system_name" in
2622         (dragonfly*|mirbsd*|freebsd*)
2623                 test -z "$LDCONFIG" && LDCONFIG="/sbin/ldconfig -R"
2624                 ;;
2625         (*) LDPATH=$PATH:/sbin:/usr/sbin
2626                 # Extract the first word of "ldconfig", so it can be a program name with args.
2627 set dummy ldconfig; ac_word=$2
2628 echo "$as_me:2628: checking for $ac_word" >&5
2629 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2630 if test "${ac_cv_path_LDCONFIG+set}" = set; then
2631   echo $ECHO_N "(cached) $ECHO_C" >&6
2632 else
2633   case $LDCONFIG in
2634   [\\/]* | ?:[\\/]*)
2635   ac_cv_path_LDCONFIG="$LDCONFIG" # Let the user override the test with a path.
2636   ;;
2637   *)
2638   ac_save_IFS=$IFS; IFS=$ac_path_separator
2639 ac_dummy="$LDPATH"
2640 for ac_dir in $ac_dummy; do
2641   IFS=$ac_save_IFS
2642   test -z "$ac_dir" && ac_dir=.
2643   if $as_executable_p "$ac_dir/$ac_word"; then
2644    ac_cv_path_LDCONFIG="$ac_dir/$ac_word"
2645    echo "$as_me:2645: found $ac_dir/$ac_word" >&5
2646    break
2647 fi
2648 done
2649
2650   ;;
2651 esac
2652 fi
2653 LDCONFIG=$ac_cv_path_LDCONFIG
2654
2655 if test -n "$LDCONFIG"; then
2656   echo "$as_me:2656: result: $LDCONFIG" >&5
2657 echo "${ECHO_T}$LDCONFIG" >&6
2658 else
2659   echo "$as_me:2659: result: no" >&5
2660 echo "${ECHO_T}no" >&6
2661 fi
2662
2663                 ;;
2664         esac
2665 fi
2666
2667 echo "$as_me:2667: checking if you want to ensure bool is consistent with C++" >&5
2668 echo $ECHO_N "checking if you want to ensure bool is consistent with C++... $ECHO_C" >&6
2669
2670 # Check whether --with-cxx or --without-cxx was given.
2671 if test "${with_cxx+set}" = set; then
2672   withval="$with_cxx"
2673   cf_with_cxx=$withval
2674 else
2675   cf_with_cxx=yes
2676 fi;
2677 echo "$as_me:2677: result: $cf_with_cxx" >&5
2678 echo "${ECHO_T}$cf_with_cxx" >&6
2679 if test "X$cf_with_cxx" = Xno ; then
2680         CXX=""
2681         GXX=""
2682 else
2683         # with autoconf 2.13, we can change the error to a warning:
2684                 ac_ext=cc
2685 ac_cpp='$CXXCPP $CPPFLAGS'
2686 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2687 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2688 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
2689 ac_main_return=return
2690 if test -n "$ac_tool_prefix"; then
2691   for ac_prog in $CCC g++ c++ gpp aCC CC cxx cc++ cl FCC KCC RCC xlC_r xlC
2692   do
2693     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
2694 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
2695 echo "$as_me:2695: checking for $ac_word" >&5
2696 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2697 if test "${ac_cv_prog_CXX+set}" = set; then
2698   echo $ECHO_N "(cached) $ECHO_C" >&6
2699 else
2700   if test -n "$CXX"; then
2701   ac_cv_prog_CXX="$CXX" # Let the user override the test.
2702 else
2703   ac_save_IFS=$IFS; IFS=$ac_path_separator
2704 ac_dummy="$PATH"
2705 for ac_dir in $ac_dummy; do
2706   IFS=$ac_save_IFS
2707   test -z "$ac_dir" && ac_dir=.
2708   $as_executable_p "$ac_dir/$ac_word" || continue
2709 ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
2710 echo "$as_me:2710: found $ac_dir/$ac_word" >&5
2711 break
2712 done
2713
2714 fi
2715 fi
2716 CXX=$ac_cv_prog_CXX
2717 if test -n "$CXX"; then
2718   echo "$as_me:2718: result: $CXX" >&5
2719 echo "${ECHO_T}$CXX" >&6
2720 else
2721   echo "$as_me:2721: result: no" >&5
2722 echo "${ECHO_T}no" >&6
2723 fi
2724
2725     test -n "$CXX" && break
2726   done
2727 fi
2728 if test -z "$CXX"; then
2729   ac_ct_CXX=$CXX
2730   for ac_prog in $CCC g++ c++ gpp aCC CC cxx cc++ cl FCC KCC RCC xlC_r xlC
2731 do
2732   # Extract the first word of "$ac_prog", so it can be a program name with args.
2733 set dummy $ac_prog; ac_word=$2
2734 echo "$as_me:2734: checking for $ac_word" >&5
2735 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2736 if test "${ac_cv_prog_ac_ct_CXX+set}" = set; then
2737   echo $ECHO_N "(cached) $ECHO_C" >&6
2738 else
2739   if test -n "$ac_ct_CXX"; then
2740   ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
2741 else
2742   ac_save_IFS=$IFS; IFS=$ac_path_separator
2743 ac_dummy="$PATH"
2744 for ac_dir in $ac_dummy; do
2745   IFS=$ac_save_IFS
2746   test -z "$ac_dir" && ac_dir=.
2747   $as_executable_p "$ac_dir/$ac_word" || continue
2748 ac_cv_prog_ac_ct_CXX="$ac_prog"
2749 echo "$as_me:2749: found $ac_dir/$ac_word" >&5
2750 break
2751 done
2752
2753 fi
2754 fi
2755 ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
2756 if test -n "$ac_ct_CXX"; then
2757   echo "$as_me:2757: result: $ac_ct_CXX" >&5
2758 echo "${ECHO_T}$ac_ct_CXX" >&6
2759 else
2760   echo "$as_me:2760: result: no" >&5
2761 echo "${ECHO_T}no" >&6
2762 fi
2763
2764   test -n "$ac_ct_CXX" && break
2765 done
2766 test -n "$ac_ct_CXX" || ac_ct_CXX="g++"
2767
2768   CXX=$ac_ct_CXX
2769 fi
2770
2771 # Provide some information about the compiler.
2772 echo "$as_me:2772:" \
2773      "checking for C++ compiler version" >&5
2774 ac_compiler=`set X $ac_compile; echo $2`
2775 { (eval echo "$as_me:2775: \"$ac_compiler --version </dev/null >&5\"") >&5
2776   (eval $ac_compiler --version </dev/null >&5) 2>&5
2777   ac_status=$?
2778   echo "$as_me:2778: \$? = $ac_status" >&5
2779   (exit $ac_status); }
2780 { (eval echo "$as_me:2780: \"$ac_compiler -v </dev/null >&5\"") >&5
2781   (eval $ac_compiler -v </dev/null >&5) 2>&5
2782   ac_status=$?
2783   echo "$as_me:2783: \$? = $ac_status" >&5
2784   (exit $ac_status); }
2785 { (eval echo "$as_me:2785: \"$ac_compiler -V </dev/null >&5\"") >&5
2786   (eval $ac_compiler -V </dev/null >&5) 2>&5
2787   ac_status=$?
2788   echo "$as_me:2788: \$? = $ac_status" >&5
2789   (exit $ac_status); }
2790
2791 echo "$as_me:2791: checking whether we are using the GNU C++ compiler" >&5
2792 echo $ECHO_N "checking whether we are using the GNU C++ compiler... $ECHO_C" >&6
2793 if test "${ac_cv_cxx_compiler_gnu+set}" = set; then
2794   echo $ECHO_N "(cached) $ECHO_C" >&6
2795 else
2796   cat >conftest.$ac_ext <<_ACEOF
2797 #line 2797 "configure"
2798 #include "confdefs.h"
2799
2800 int
2801 main (void)
2802 {
2803 #ifndef __GNUC__
2804        choke me
2805 #endif
2806
2807   ;
2808   return 0;
2809 }
2810 _ACEOF
2811 rm -f conftest.$ac_objext
2812 if { (eval echo "$as_me:2812: \"$ac_compile\"") >&5
2813   (eval $ac_compile) 2>&5
2814   ac_status=$?
2815   echo "$as_me:2815: \$? = $ac_status" >&5
2816   (exit $ac_status); } &&
2817          { ac_try='test -s conftest.$ac_objext'
2818   { (eval echo "$as_me:2818: \"$ac_try\"") >&5
2819   (eval $ac_try) 2>&5
2820   ac_status=$?
2821   echo "$as_me:2821: \$? = $ac_status" >&5
2822   (exit $ac_status); }; }; then
2823   ac_compiler_gnu=yes
2824 else
2825   echo "$as_me: failed program was:" >&5
2826 cat conftest.$ac_ext >&5
2827 ac_compiler_gnu=no
2828 fi
2829 rm -f conftest.$ac_objext conftest.$ac_ext
2830 ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
2831
2832 fi
2833 echo "$as_me:2833: result: $ac_cv_cxx_compiler_gnu" >&5
2834 echo "${ECHO_T}$ac_cv_cxx_compiler_gnu" >&6
2835 GXX=`test $ac_compiler_gnu = yes && echo yes`
2836 ac_test_CXXFLAGS=${CXXFLAGS+set}
2837 ac_save_CXXFLAGS=$CXXFLAGS
2838 CXXFLAGS="-g"
2839 echo "$as_me:2839: checking whether $CXX accepts -g" >&5
2840 echo $ECHO_N "checking whether $CXX accepts -g... $ECHO_C" >&6
2841 if test "${ac_cv_prog_cxx_g+set}" = set; then
2842   echo $ECHO_N "(cached) $ECHO_C" >&6
2843 else
2844   cat >conftest.$ac_ext <<_ACEOF
2845 #line 2845 "configure"
2846 #include "confdefs.h"
2847
2848 int
2849 main (void)
2850 {
2851
2852   ;
2853   return 0;
2854 }
2855 _ACEOF
2856 rm -f conftest.$ac_objext
2857 if { (eval echo "$as_me:2857: \"$ac_compile\"") >&5
2858   (eval $ac_compile) 2>&5
2859   ac_status=$?
2860   echo "$as_me:2860: \$? = $ac_status" >&5
2861   (exit $ac_status); } &&
2862          { ac_try='test -s conftest.$ac_objext'
2863   { (eval echo "$as_me:2863: \"$ac_try\"") >&5
2864   (eval $ac_try) 2>&5
2865   ac_status=$?
2866   echo "$as_me:2866: \$? = $ac_status" >&5
2867   (exit $ac_status); }; }; then
2868   ac_cv_prog_cxx_g=yes
2869 else
2870   echo "$as_me: failed program was:" >&5
2871 cat conftest.$ac_ext >&5
2872 ac_cv_prog_cxx_g=no
2873 fi
2874 rm -f conftest.$ac_objext conftest.$ac_ext
2875 fi
2876 echo "$as_me:2876: result: $ac_cv_prog_cxx_g" >&5
2877 echo "${ECHO_T}$ac_cv_prog_cxx_g" >&6
2878 if test "$ac_test_CXXFLAGS" = set; then
2879   CXXFLAGS=$ac_save_CXXFLAGS
2880 elif test $ac_cv_prog_cxx_g = yes; then
2881   if test "$GXX" = yes; then
2882     CXXFLAGS="-g -O2"
2883   else
2884     CXXFLAGS="-g"
2885   fi
2886 else
2887   if test "$GXX" = yes; then
2888     CXXFLAGS="-O2"
2889   else
2890     CXXFLAGS=
2891   fi
2892 fi
2893 for ac_declaration in \
2894    ''\
2895    '#include <stdlib.h>' \
2896    'extern "C" void std::exit (int) throw (); using std::exit;' \
2897    'extern "C" void std::exit (int); using std::exit;' \
2898    'extern "C" void exit (int) throw ();' \
2899    'extern "C" void exit (int);' \
2900    'void exit (int);'
2901 do
2902   cat >conftest.$ac_ext <<_ACEOF
2903 #line 2903 "configure"
2904 #include "confdefs.h"
2905 #include <stdlib.h>
2906 $ac_declaration
2907 int
2908 main (void)
2909 {
2910 exit (42);
2911   ;
2912   return 0;
2913 }
2914 _ACEOF
2915 rm -f conftest.$ac_objext
2916 if { (eval echo "$as_me:2916: \"$ac_compile\"") >&5
2917   (eval $ac_compile) 2>&5
2918   ac_status=$?
2919   echo "$as_me:2919: \$? = $ac_status" >&5
2920   (exit $ac_status); } &&
2921          { ac_try='test -s conftest.$ac_objext'
2922   { (eval echo "$as_me:2922: \"$ac_try\"") >&5
2923   (eval $ac_try) 2>&5
2924   ac_status=$?
2925   echo "$as_me:2925: \$? = $ac_status" >&5
2926   (exit $ac_status); }; }; then
2927   :
2928 else
2929   echo "$as_me: failed program was:" >&5
2930 cat conftest.$ac_ext >&5
2931 continue
2932 fi
2933 rm -f conftest.$ac_objext conftest.$ac_ext
2934   cat >conftest.$ac_ext <<_ACEOF
2935 #line 2935 "configure"
2936 #include "confdefs.h"
2937 $ac_declaration
2938 int
2939 main (void)
2940 {
2941 exit (42);
2942   ;
2943   return 0;
2944 }
2945 _ACEOF
2946 rm -f conftest.$ac_objext
2947 if { (eval echo "$as_me:2947: \"$ac_compile\"") >&5
2948   (eval $ac_compile) 2>&5
2949   ac_status=$?
2950   echo "$as_me:2950: \$? = $ac_status" >&5
2951   (exit $ac_status); } &&
2952          { ac_try='test -s conftest.$ac_objext'
2953   { (eval echo "$as_me:2953: \"$ac_try\"") >&5
2954   (eval $ac_try) 2>&5
2955   ac_status=$?
2956   echo "$as_me:2956: \$? = $ac_status" >&5
2957   (exit $ac_status); }; }; then
2958   break
2959 else
2960   echo "$as_me: failed program was:" >&5
2961 cat conftest.$ac_ext >&5
2962 fi
2963 rm -f conftest.$ac_objext conftest.$ac_ext
2964 done
2965 rm -rf conftest*
2966 if test -n "$ac_declaration"; then
2967   echo '#ifdef __cplusplus' >>confdefs.h
2968   echo $ac_declaration      >>confdefs.h
2969   echo '#endif'             >>confdefs.h
2970 fi
2971
2972 ac_ext=c
2973 ac_cpp='$CPP $CPPFLAGS'
2974 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2975 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2976 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2977 ac_main_return=return
2978
2979         ac_ext=cc
2980 ac_cpp='$CXXCPP $CPPFLAGS'
2981 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2982 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2983 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
2984 ac_main_return=return
2985
2986         if test "x$cf_with_cxx" != xno
2987         then
2988                 # Several of the C++ configurations do not work, particularly when
2989                 # cross-compiling (20140913 -TD)
2990                 echo "$as_me:2990: checking if $CXX works" >&5
2991 echo $ECHO_N "checking if $CXX works... $ECHO_C" >&6
2992
2993                 save_CPPFLAGS="$CPPFLAGS"
2994                 eval cf_includedir=${includedir}
2995                 CPPFLAGS="$CPPFLAGS -I${cf_includedir}"
2996
2997 cat >conftest.$ac_ext <<_ACEOF
2998 #line 2998 "configure"
2999 #include "confdefs.h"
3000
3001 #include <stdlib.h>
3002 #include <stdio.h>
3003
3004 int
3005 main (void)
3006 {
3007
3008                 printf("Hello world!\n")
3009
3010   ;
3011   return 0;
3012 }
3013 _ACEOF
3014 rm -f conftest.$ac_objext
3015 if { (eval echo "$as_me:3015: \"$ac_compile\"") >&5
3016   (eval $ac_compile) 2>&5
3017   ac_status=$?
3018   echo "$as_me:3018: \$? = $ac_status" >&5
3019   (exit $ac_status); } &&
3020          { ac_try='test -s conftest.$ac_objext'
3021   { (eval echo "$as_me:3021: \"$ac_try\"") >&5
3022   (eval $ac_try) 2>&5
3023   ac_status=$?
3024   echo "$as_me:3024: \$? = $ac_status" >&5
3025   (exit $ac_status); }; }; then
3026   cf_cxx_works=yes
3027 else
3028   echo "$as_me: failed program was:" >&5
3029 cat conftest.$ac_ext >&5
3030 cf_cxx_works=no
3031 fi
3032 rm -f conftest.$ac_objext conftest.$ac_ext
3033                 CPPFLAGS="$save_CPPFLAGS"
3034
3035                 echo "$as_me:3035: result: $cf_cxx_works" >&5
3036 echo "${ECHO_T}$cf_cxx_works" >&6
3037                 if test "x$cf_cxx_works" = xno
3038                 then
3039                         { echo "$as_me:3039: WARNING: Ignore $CXX, since it cannot compile hello-world." >&5
3040 echo "$as_me: WARNING: Ignore $CXX, since it cannot compile hello-world." >&2;}
3041                         cf_with_cxx=no; CXX=""; GXX="";
3042                 fi
3043         fi
3044         ac_ext=c
3045 ac_cpp='$CPP $CPPFLAGS'
3046 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3047 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3048 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3049 ac_main_return=return
3050
3051         # autoconf 2.5x removed the error (hardcoding it to g++, or just blank)
3052         if test "$CXX" = "g++" ; then
3053                 # Extract the first word of "g++", so it can be a program name with args.
3054 set dummy g++; ac_word=$2
3055 echo "$as_me:3055: checking for $ac_word" >&5
3056 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3057 if test "${ac_cv_path_CXX+set}" = set; then
3058   echo $ECHO_N "(cached) $ECHO_C" >&6
3059 else
3060   case $CXX in
3061   [\\/]* | ?:[\\/]*)
3062   ac_cv_path_CXX="$CXX" # Let the user override the test with a path.
3063   ;;
3064   *)
3065   ac_save_IFS=$IFS; IFS=$ac_path_separator
3066 ac_dummy="$PATH"
3067 for ac_dir in $ac_dummy; do
3068   IFS=$ac_save_IFS
3069   test -z "$ac_dir" && ac_dir=.
3070   if $as_executable_p "$ac_dir/$ac_word"; then
3071    ac_cv_path_CXX="$ac_dir/$ac_word"
3072    echo "$as_me:3072: found $ac_dir/$ac_word" >&5
3073    break
3074 fi
3075 done
3076
3077   ;;
3078 esac
3079 fi
3080 CXX=$ac_cv_path_CXX
3081
3082 if test -n "$CXX"; then
3083   echo "$as_me:3083: result: $CXX" >&5
3084 echo "${ECHO_T}$CXX" >&6
3085 else
3086   echo "$as_me:3086: result: no" >&5
3087 echo "${ECHO_T}no" >&6
3088 fi
3089
3090         fi
3091         case "x$CXX" in
3092         (x|xg++)
3093                 { echo "$as_me:3093: WARNING: You don't have any C++ compiler, too bad" >&5
3094 echo "$as_me: WARNING: You don't have any C++ compiler, too bad" >&2;}
3095                 cf_with_cxx=no; CXX=""; GXX="";
3096                 ;;
3097         esac
3098 fi
3099
3100 GXX_VERSION=none
3101 if test "$GXX" = yes; then
3102         echo "$as_me:3102: checking version of ${CXX:-g++}" >&5
3103 echo $ECHO_N "checking version of ${CXX:-g++}... $ECHO_C" >&6
3104         GXX_VERSION="`${CXX:-g++} --version| sed -e '2,$d' -e 's/^.*(GCC) //' -e 's/^[^0-9.]*//' -e 's/[^0-9.].*//'`"
3105         if test -z "$GXX_VERSION"
3106         then
3107                 GXX_VERSION=unknown
3108                 GXX=no
3109         fi
3110         echo "$as_me:3110: result: $GXX_VERSION" >&5
3111 echo "${ECHO_T}$GXX_VERSION" >&6
3112 fi
3113
3114 case $GXX_VERSION in
3115 (1*|2.[0-6]*)
3116         # GXX=""; CXX=""; ac_cv_prog_gxx=no
3117         # cf_cxx_library=no
3118         { echo "$as_me:3118: WARNING: templates do not work" >&5
3119 echo "$as_me: WARNING: templates do not work" >&2;}
3120         ;;
3121 esac
3122
3123 echo "$as_me:3123: checking if you want to build C++ binding and demo" >&5
3124 echo $ECHO_N "checking if you want to build C++ binding and demo... $ECHO_C" >&6
3125
3126 # Check whether --with-cxx-binding or --without-cxx-binding was given.
3127 if test "${with_cxx_binding+set}" = set; then
3128   withval="$with_cxx_binding"
3129   cf_with_cxx_binding=$withval
3130 else
3131   cf_with_cxx_binding=$cf_with_cxx
3132 fi;
3133 echo "$as_me:3133: result: $cf_with_cxx_binding" >&5
3134 echo "${ECHO_T}$cf_with_cxx_binding" >&6
3135
3136 echo "$as_me:3136: checking if you want to build with Ada95" >&5
3137 echo $ECHO_N "checking if you want to build with Ada95... $ECHO_C" >&6
3138 echo "$as_me:3138: result: $cf_with_ada" >&5
3139 echo "${ECHO_T}$cf_with_ada" >&6
3140
3141 echo "$as_me:3141: checking if you want to install terminal database" >&5
3142 echo $ECHO_N "checking if you want to install terminal database... $ECHO_C" >&6
3143
3144 # Check whether --enable-db-install or --disable-db-install was given.
3145 if test "${enable_db_install+set}" = set; then
3146   enableval="$enable_db_install"
3147   cf_with_db_install=$enableval
3148 else
3149   cf_with_db_install=yes
3150 fi;
3151 echo "$as_me:3151: result: $cf_with_db_install" >&5
3152 echo "${ECHO_T}$cf_with_db_install" >&6
3153
3154 echo "$as_me:3154: checking if you want to install manpages" >&5
3155 echo $ECHO_N "checking if you want to install manpages... $ECHO_C" >&6
3156
3157 # Check whether --with-manpages or --without-manpages was given.
3158 if test "${with_manpages+set}" = set; then
3159   withval="$with_manpages"
3160   cf_with_manpages=$withval
3161 else
3162   cf_with_manpages=yes
3163 fi;
3164 echo "$as_me:3164: result: $cf_with_manpages" >&5
3165 echo "${ECHO_T}$cf_with_manpages" >&6
3166
3167 echo "$as_me:3167: checking if you want to build programs such as tic" >&5
3168 echo $ECHO_N "checking if you want to build programs such as tic... $ECHO_C" >&6
3169
3170 # Check whether --with-progs or --without-progs was given.
3171 if test "${with_progs+set}" = set; then
3172   withval="$with_progs"
3173   cf_with_progs=$withval
3174 else
3175   cf_with_progs=yes
3176 fi;
3177 echo "$as_me:3177: result: $cf_with_progs" >&5
3178 echo "${ECHO_T}$cf_with_progs" >&6
3179
3180 if test -f $srcdir/tack/tack.h; then
3181         if test "x$cross_compiling" = xyes ; then
3182                 test -n "$verbose" && echo "    ignoring tack because we are cross-compiling" 1>&6
3183
3184 echo "${as_me:-configure}:3184: testing ignoring tack because we are cross-compiling ..." 1>&5
3185
3186                 cf_with_tack=no
3187         else
3188                 echo "$as_me:3188: checking if you want to build the tack program" >&5
3189 echo $ECHO_N "checking if you want to build the tack program... $ECHO_C" >&6
3190
3191 # Check whether --with-tack or --without-tack was given.
3192 if test "${with_tack+set}" = set; then
3193   withval="$with_tack"
3194   cf_with_tack=$withval
3195 else
3196   cf_with_tack=$cf_with_progs
3197 fi;
3198                 echo "$as_me:3198: result: $cf_with_tack" >&5
3199 echo "${ECHO_T}$cf_with_tack" >&6
3200         fi
3201 else
3202         cf_with_tack=no
3203 fi
3204
3205 echo "$as_me:3205: checking if you want to build test-programs" >&5
3206 echo $ECHO_N "checking if you want to build test-programs... $ECHO_C" >&6
3207
3208 # Check whether --with-tests or --without-tests was given.
3209 if test "${with_tests+set}" = set; then
3210   withval="$with_tests"
3211   cf_with_tests=$withval
3212 else
3213   cf_with_tests=yes
3214 fi;
3215 echo "$as_me:3215: result: $cf_with_tests" >&5
3216 echo "${ECHO_T}$cf_with_tests" >&6
3217
3218 echo "$as_me:3218: checking if you wish to install curses.h" >&5
3219 echo $ECHO_N "checking if you wish to install curses.h... $ECHO_C" >&6
3220
3221 # Check whether --with-curses-h or --without-curses-h was given.
3222 if test "${with_curses_h+set}" = set; then
3223   withval="$with_curses_h"
3224   with_curses_h=$withval
3225 else
3226   with_curses_h=yes
3227 fi;
3228 echo "$as_me:3228: result: $with_curses_h" >&5
3229 echo "${ECHO_T}$with_curses_h" >&6
3230
3231 modules_to_build="ncurses"
3232 test "X$cf_with_progs" != Xno && modules_to_build="$modules_to_build progs"
3233 test "X$cf_with_tack"  != Xno && modules_to_build="$modules_to_build tack"
3234 modules_to_build="$modules_to_build panel menu form"
3235
3236 test "$program_prefix" != NONE &&
3237   program_transform_name="s,^,$program_prefix,;$program_transform_name"
3238 # Use a double $ so make ignores it.
3239 test "$program_suffix" != NONE &&
3240   program_transform_name="s,\$,$program_suffix,;$program_transform_name"
3241 # Double any \ or $.  echo might interpret backslashes.
3242 # By default was `s,x,x', remove it if useless.
3243 cat <<\_ACEOF >conftest.sed
3244 s/[\\$]/&&/g;s/;s,x,x,$//
3245 _ACEOF
3246 program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
3247 rm conftest.sed
3248
3249 for ac_prog in mawk gawk nawk awk
3250 do
3251   # Extract the first word of "$ac_prog", so it can be a program name with args.
3252 set dummy $ac_prog; ac_word=$2
3253 echo "$as_me:3253: checking for $ac_word" >&5
3254 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3255 if test "${ac_cv_prog_AWK+set}" = set; then
3256   echo $ECHO_N "(cached) $ECHO_C" >&6
3257 else
3258   if test -n "$AWK"; then
3259   ac_cv_prog_AWK="$AWK" # Let the user override the test.
3260 else
3261   ac_save_IFS=$IFS; IFS=$ac_path_separator
3262 ac_dummy="$PATH"
3263 for ac_dir in $ac_dummy; do
3264   IFS=$ac_save_IFS
3265   test -z "$ac_dir" && ac_dir=.
3266   $as_executable_p "$ac_dir/$ac_word" || continue
3267 ac_cv_prog_AWK="$ac_prog"
3268 echo "$as_me:3268: found $ac_dir/$ac_word" >&5
3269 break
3270 done
3271
3272 fi
3273 fi
3274 AWK=$ac_cv_prog_AWK
3275 if test -n "$AWK"; then
3276   echo "$as_me:3276: result: $AWK" >&5
3277 echo "${ECHO_T}$AWK" >&6
3278 else
3279   echo "$as_me:3279: result: no" >&5
3280 echo "${ECHO_T}no" >&6
3281 fi
3282
3283   test -n "$AWK" && break
3284 done
3285
3286 test -z "$AWK" && { { echo "$as_me:3286: error: No awk program found" >&5
3287 echo "$as_me: error: No awk program found" >&2;}
3288    { (exit 1); exit 1; }; }
3289
3290 echo "$as_me:3290: checking for egrep" >&5
3291 echo $ECHO_N "checking for egrep... $ECHO_C" >&6
3292 if test "${ac_cv_prog_egrep+set}" = set; then
3293   echo $ECHO_N "(cached) $ECHO_C" >&6
3294 else
3295   if echo a | (grep -E '(a|b)') >/dev/null 2>&1
3296                 then ac_cv_prog_egrep='grep -E'
3297                 else ac_cv_prog_egrep='egrep'
3298         fi
3299 fi
3300 echo "$as_me:3300: result: $ac_cv_prog_egrep" >&5
3301 echo "${ECHO_T}$ac_cv_prog_egrep" >&6
3302         EGREP=$ac_cv_prog_egrep
3303
3304         test -z "$EGREP" && { { echo "$as_me:3304: error: No egrep program found" >&5
3305 echo "$as_me: error: No egrep program found" >&2;}
3306    { (exit 1); exit 1; }; }
3307
3308 # Find a good install program.  We prefer a C program (faster),
3309 # so one script is as good as another.  But avoid the broken or
3310 # incompatible versions:
3311 # SysV /etc/install, /usr/sbin/install
3312 # SunOS /usr/etc/install
3313 # IRIX /sbin/install
3314 # AIX /bin/install
3315 # AmigaOS /C/install, which installs bootblocks on floppy discs
3316 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3317 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
3318 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3319 # ./install, which can be erroneously created by make from ./install.sh.
3320 echo "$as_me:3320: checking for a BSD compatible install" >&5
3321 echo $ECHO_N "checking for a BSD compatible install... $ECHO_C" >&6
3322 if test -z "$INSTALL"; then
3323 if test "${ac_cv_path_install+set}" = set; then
3324   echo $ECHO_N "(cached) $ECHO_C" >&6
3325 else
3326     ac_save_IFS=$IFS; IFS=$ac_path_separator
3327   for ac_dir in $PATH; do
3328     IFS=$ac_save_IFS
3329     # Account for people who put trailing slashes in PATH elements.
3330     case $ac_dir/ in
3331     / | ./ | .// | /cC/* \
3332     | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* \
3333     | /usr/ucb/* ) ;;
3334     *)
3335       # OSF1 and SCO ODT 3.0 have their own names for install.
3336       # Don't use installbsd from OSF since it installs stuff as root
3337       # by default.
3338       for ac_prog in ginstall scoinst install; do
3339         if $as_executable_p "$ac_dir/$ac_prog"; then
3340           if test $ac_prog = install &&
3341             grep dspmsg "$ac_dir/$ac_prog" >/dev/null 2>&1; then
3342             # AIX install.  It has an incompatible calling convention.
3343             :
3344           elif test $ac_prog = install &&
3345             grep pwplus "$ac_dir/$ac_prog" >/dev/null 2>&1; then
3346             # program-specific install script used by HP pwplus--don't use.
3347             :
3348           else
3349             ac_cv_path_install="$ac_dir/$ac_prog -c"
3350             break 2
3351           fi
3352         fi
3353       done
3354       ;;
3355     esac
3356   done
3357
3358 fi
3359   if test "${ac_cv_path_install+set}" = set; then
3360     INSTALL=$ac_cv_path_install
3361   else
3362     # As a last resort, use the slow shell script.  We don't cache a
3363     # path for INSTALL within a source directory, because that will
3364     # break other packages using the cache if that directory is
3365     # removed, or if the path is relative.
3366     INSTALL=$ac_install_sh
3367   fi
3368 fi
3369 echo "$as_me:3369: result: $INSTALL" >&5
3370 echo "${ECHO_T}$INSTALL" >&6
3371
3372 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3373 # It thinks the first close brace ends the variable substitution.
3374 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3375
3376 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
3377
3378 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3379
3380 case $INSTALL in
3381 (/*)
3382         ;;
3383 (*)
3384         cf_dir=`echo $INSTALL | sed -e 's%/[^/]*$%%'`
3385         test -z "$cf_dir" && cf_dir=.
3386         INSTALL=`cd $cf_dir && pwd`/`echo $INSTALL | sed -e 's%^.*/%%'`
3387         ;;
3388 esac
3389
3390 for ac_prog in lint cppcheck splint
3391 do
3392   # Extract the first word of "$ac_prog", so it can be a program name with args.
3393 set dummy $ac_prog; ac_word=$2
3394 echo "$as_me:3394: checking for $ac_word" >&5
3395 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3396 if test "${ac_cv_prog_LINT+set}" = set; then
3397   echo $ECHO_N "(cached) $ECHO_C" >&6
3398 else
3399   if test -n "$LINT"; then
3400   ac_cv_prog_LINT="$LINT" # Let the user override the test.
3401 else
3402   ac_save_IFS=$IFS; IFS=$ac_path_separator
3403 ac_dummy="$PATH"
3404 for ac_dir in $ac_dummy; do
3405   IFS=$ac_save_IFS
3406   test -z "$ac_dir" && ac_dir=.
3407   $as_executable_p "$ac_dir/$ac_word" || continue
3408 ac_cv_prog_LINT="$ac_prog"
3409 echo "$as_me:3409: found $ac_dir/$ac_word" >&5
3410 break
3411 done
3412
3413 fi
3414 fi
3415 LINT=$ac_cv_prog_LINT
3416 if test -n "$LINT"; then
3417   echo "$as_me:3417: result: $LINT" >&5
3418 echo "${ECHO_T}$LINT" >&6
3419 else
3420   echo "$as_me:3420: result: no" >&5
3421 echo "${ECHO_T}no" >&6
3422 fi
3423
3424   test -n "$LINT" && break
3425 done
3426
3427 echo "$as_me:3427: checking whether ln -s works" >&5
3428 echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
3429 LN_S=$as_ln_s
3430 if test "$LN_S" = "ln -s"; then
3431   echo "$as_me:3431: result: yes" >&5
3432 echo "${ECHO_T}yes" >&6
3433 else
3434   echo "$as_me:3434: result: no, using $LN_S" >&5
3435 echo "${ECHO_T}no, using $LN_S" >&6
3436 fi
3437
3438 echo "$as_me:3438: checking if $LN_S -f options work" >&5
3439 echo $ECHO_N "checking if $LN_S -f options work... $ECHO_C" >&6
3440
3441 rm -f conf$$.src conf$$dst
3442 echo >conf$$.dst
3443 echo first >conf$$.src
3444 if $LN_S -f conf$$.src conf$$.dst 2>/dev/null; then
3445         cf_prog_ln_sf=yes
3446 else
3447         cf_prog_ln_sf=no
3448 fi
3449 rm -f conf$$.dst conf$$src
3450 echo "$as_me:3450: result: $cf_prog_ln_sf" >&5
3451 echo "${ECHO_T}$cf_prog_ln_sf" >&6
3452
3453 test "$cf_prog_ln_sf" = yes && LN_S="$LN_S -f"
3454
3455 echo "$as_me:3455: checking for long file names" >&5
3456 echo $ECHO_N "checking for long file names... $ECHO_C" >&6
3457 if test "${ac_cv_sys_long_file_names+set}" = set; then
3458   echo $ECHO_N "(cached) $ECHO_C" >&6
3459 else
3460   ac_cv_sys_long_file_names=yes
3461 # Test for long file names in all the places we know might matter:
3462 #      .                the current directory, where building will happen
3463 #      $prefix/lib      where we will be installing things
3464 #      $exec_prefix/lib likewise
3465 # eval it to expand exec_prefix.
3466 #      $TMPDIR          if set, where it might want to write temporary files
3467 # if $TMPDIR is not set:
3468 #      /tmp             where it might want to write temporary files
3469 #      /var/tmp         likewise
3470 #      /usr/tmp         likewise
3471 if test -n "$TMPDIR" && test -d "$TMPDIR" && test -w "$TMPDIR"; then
3472   ac_tmpdirs=$TMPDIR
3473 else
3474   ac_tmpdirs='/tmp /var/tmp /usr/tmp'
3475 fi
3476 for ac_dir in  . $ac_tmpdirs `eval echo $prefix/lib $exec_prefix/lib` ; do
3477   test -d $ac_dir || continue
3478   test -w $ac_dir || continue # It is less confusing to not echo anything here.
3479   ac_xdir=$ac_dir/cf$$
3480   (umask 077 && mkdir $ac_xdir 2>/dev/null) || continue
3481   ac_tf1=$ac_xdir/conftest9012345
3482   ac_tf2=$ac_xdir/conftest9012346
3483   (echo 1 >$ac_tf1) 2>/dev/null
3484   (echo 2 >$ac_tf2) 2>/dev/null
3485   ac_val=`cat $ac_tf1 2>/dev/null`
3486   if test ! -f $ac_tf1 || test "$ac_val" != 1; then
3487     ac_cv_sys_long_file_names=no
3488     rm -rf $ac_xdir 2>/dev/null
3489     break
3490   fi
3491   rm -rf $ac_xdir 2>/dev/null
3492 done
3493 fi
3494 echo "$as_me:3494: result: $ac_cv_sys_long_file_names" >&5
3495 echo "${ECHO_T}$ac_cv_sys_long_file_names" >&6
3496 if test $ac_cv_sys_long_file_names = yes; then
3497
3498 cat >>confdefs.h <<\EOF
3499 #define HAVE_LONG_FILE_NAMES 1
3500 EOF
3501
3502 fi
3503
3504 # Provide for renaming "ncurses5-config" to "ncurses5X-config", etc., in case
3505 # of package conflict.
3506 cf_config_suffix=
3507
3508 # Check whether --with-config-suffix or --without-config-suffix was given.
3509 if test "${with_config_suffix+set}" = set; then
3510   withval="$with_config_suffix"
3511   case "x$withval" in
3512         (xyes|xno)
3513                 { echo "$as_me:3513: WARNING: expected a value for config-suffix option" >&5
3514 echo "$as_me: WARNING: expected a value for config-suffix option" >&2;}
3515                 ;;
3516         (*)     cf_config_suffix="$withval"
3517                 ;;
3518         esac
3519 fi;
3520
3521 # If we find pkg-config, check if we should install the ".pc" files.
3522
3523 echo "$as_me:3523: checking if you want to use pkg-config" >&5
3524 echo $ECHO_N "checking if you want to use pkg-config... $ECHO_C" >&6
3525
3526 # Check whether --with-pkg-config or --without-pkg-config was given.
3527 if test "${with_pkg_config+set}" = set; then
3528   withval="$with_pkg_config"
3529   cf_pkg_config=$withval
3530 else
3531   cf_pkg_config=yes
3532 fi;
3533 echo "$as_me:3533: result: $cf_pkg_config" >&5
3534 echo "${ECHO_T}$cf_pkg_config" >&6
3535
3536 case $cf_pkg_config in
3537 (no)
3538         PKG_CONFIG=none
3539         ;;
3540 (yes)
3541
3542 if test -n "$ac_tool_prefix"; then
3543   # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
3544 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
3545 echo "$as_me:3545: checking for $ac_word" >&5
3546 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3547 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then
3548   echo $ECHO_N "(cached) $ECHO_C" >&6
3549 else
3550   case $PKG_CONFIG in
3551   [\\/]* | ?:[\\/]*)
3552   ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
3553   ;;
3554   *)
3555   ac_save_IFS=$IFS; IFS=$ac_path_separator
3556 ac_dummy="$PATH"
3557 for ac_dir in $ac_dummy; do
3558   IFS=$ac_save_IFS
3559   test -z "$ac_dir" && ac_dir=.
3560   if $as_executable_p "$ac_dir/$ac_word"; then
3561    ac_cv_path_PKG_CONFIG="$ac_dir/$ac_word"
3562    echo "$as_me:3562: found $ac_dir/$ac_word" >&5
3563    break
3564 fi
3565 done
3566
3567   ;;
3568 esac
3569 fi
3570 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
3571
3572 if test -n "$PKG_CONFIG"; then
3573   echo "$as_me:3573: result: $PKG_CONFIG" >&5
3574 echo "${ECHO_T}$PKG_CONFIG" >&6
3575 else
3576   echo "$as_me:3576: result: no" >&5
3577 echo "${ECHO_T}no" >&6
3578 fi
3579
3580 fi
3581 if test -z "$ac_cv_path_PKG_CONFIG"; then
3582   ac_pt_PKG_CONFIG=$PKG_CONFIG
3583   # Extract the first word of "pkg-config", so it can be a program name with args.
3584 set dummy pkg-config; ac_word=$2
3585 echo "$as_me:3585: checking for $ac_word" >&5
3586 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3587 if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then
3588   echo $ECHO_N "(cached) $ECHO_C" >&6
3589 else
3590   case $ac_pt_PKG_CONFIG in
3591   [\\/]* | ?:[\\/]*)
3592   ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
3593   ;;
3594   *)
3595   ac_save_IFS=$IFS; IFS=$ac_path_separator
3596 ac_dummy="$PATH"
3597 for ac_dir in $ac_dummy; do
3598   IFS=$ac_save_IFS
3599   test -z "$ac_dir" && ac_dir=.
3600   if $as_executable_p "$ac_dir/$ac_word"; then
3601    ac_cv_path_ac_pt_PKG_CONFIG="$ac_dir/$ac_word"
3602    echo "$as_me:3602: found $ac_dir/$ac_word" >&5
3603    break
3604 fi
3605 done
3606
3607   test -z "$ac_cv_path_ac_pt_PKG_CONFIG" && ac_cv_path_ac_pt_PKG_CONFIG="none"
3608   ;;
3609 esac
3610 fi
3611 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
3612
3613 if test -n "$ac_pt_PKG_CONFIG"; then
3614   echo "$as_me:3614: result: $ac_pt_PKG_CONFIG" >&5
3615 echo "${ECHO_T}$ac_pt_PKG_CONFIG" >&6
3616 else
3617   echo "$as_me:3617: result: no" >&5
3618 echo "${ECHO_T}no" >&6
3619 fi
3620
3621   PKG_CONFIG=$ac_pt_PKG_CONFIG
3622 else
3623   PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
3624 fi
3625
3626         ;;
3627 (*)
3628         PKG_CONFIG=$withval
3629         ;;
3630 esac
3631
3632 test -z "$PKG_CONFIG" && PKG_CONFIG=none
3633 if test "$PKG_CONFIG" != none ; then
3634
3635 if test "x$prefix" != xNONE; then
3636         cf_path_syntax="$prefix"
3637 else
3638         cf_path_syntax="$ac_default_prefix"
3639 fi
3640
3641 case ".$PKG_CONFIG" in
3642 (.\$\(*\)*|.\'*\'*)
3643         ;;
3644 (..|./*|.\\*)
3645         ;;
3646 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
3647         ;;
3648 (.\${*prefix}*|.\${*dir}*)
3649         eval PKG_CONFIG="$PKG_CONFIG"
3650         case ".$PKG_CONFIG" in
3651         (.NONE/*)
3652                 PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
3653                 ;;
3654         esac
3655         ;;
3656 (.no|.NONE/*)
3657         PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
3658         ;;
3659 (*)
3660         { { echo "$as_me:3660: error: expected a pathname, not \"$PKG_CONFIG\"" >&5
3661 echo "$as_me: error: expected a pathname, not \"$PKG_CONFIG\"" >&2;}
3662    { (exit 1); exit 1; }; }
3663         ;;
3664 esac
3665
3666 elif test "x$cf_pkg_config" != xno ; then
3667         { echo "$as_me:3667: WARNING: pkg-config is not installed" >&5
3668 echo "$as_me: WARNING: pkg-config is not installed" >&2;}
3669 fi
3670
3671 case $PKG_CONFIG in
3672 (no|none|yes)
3673         echo "$as_me:3673: checking for pkg-config library directory" >&5
3674 echo $ECHO_N "checking for pkg-config library directory... $ECHO_C" >&6
3675         ;;
3676 (*)
3677         echo "$as_me:3677: checking for $PKG_CONFIG library directory" >&5
3678 echo $ECHO_N "checking for $PKG_CONFIG library directory... $ECHO_C" >&6
3679         ;;
3680 esac
3681
3682 PKG_CONFIG_LIBDIR=no
3683
3684 # Check whether --with-pkg-config-libdir or --without-pkg-config-libdir was given.
3685 if test "${with_pkg_config_libdir+set}" = set; then
3686   withval="$with_pkg_config_libdir"
3687   PKG_CONFIG_LIBDIR=$withval
3688 else
3689   test "x$PKG_CONFIG" != xnone && PKG_CONFIG_LIBDIR=yes
3690 fi;
3691
3692 case x$PKG_CONFIG_LIBDIR in
3693 (x/*)
3694         ;;
3695 (xyes)
3696         # Look for the library directory using the same prefix as the executable
3697         if test "x$PKG_CONFIG" = xnone
3698         then
3699                 cf_path=$prefix
3700         else
3701                 cf_path=`echo "$PKG_CONFIG" | sed -e 's,/[^/]*/[^/]*$,,'`
3702         fi
3703
3704         # If you don't like using the default architecture, you have to specify the
3705         # intended library directory and corresponding compiler/linker options.
3706         #
3707         # This case allows for Debian's 2014-flavor of multiarch, along with the
3708         # most common variations before that point.  Some other variants spell the
3709         # directory differently, e.g., "pkg-config", and put it in unusual places.
3710         # pkg-config has always been poorly standardized, which is ironic...
3711         case x`(arch) 2>/dev/null` in
3712         (*64)
3713                 cf_search_path="\
3714                         $cf_path/lib/*64-linux-gnu \
3715                         $cf_path/share \
3716                         $cf_path/lib64 \
3717                         $cf_path/lib32 \
3718                         $cf_path/lib"
3719                 ;;
3720         (*)
3721                 cf_search_path="\
3722                         $cf_path/lib/*-linux-gnu \
3723                         $cf_path/share \
3724                         $cf_path/lib32 \
3725                         $cf_path/lib \
3726                         $cf_path/libdata"
3727                 ;;
3728         esac
3729
3730         test -n "$verbose" && echo "    list..." 1>&6
3731
3732 echo "${as_me:-configure}:3732: testing list... ..." 1>&5
3733
3734         for cf_config in $cf_search_path
3735         do
3736                 test -n "$verbose" && echo "    checking $cf_config/pkgconfig" 1>&6
3737
3738 echo "${as_me:-configure}:3738: testing checking $cf_config/pkgconfig ..." 1>&5
3739
3740                 if test -d $cf_config/pkgconfig
3741                 then
3742                         PKG_CONFIG_LIBDIR=$cf_config/pkgconfig
3743                         echo "$as_me:3743: checking done" >&5
3744 echo $ECHO_N "checking done... $ECHO_C" >&6
3745                         break
3746                 fi
3747         done
3748         ;;
3749 (*)
3750         ;;
3751 esac
3752
3753 if test "x$PKG_CONFIG_LIBDIR" != xno ; then
3754         echo "$as_me:3754: result: $PKG_CONFIG_LIBDIR" >&5
3755 echo "${ECHO_T}$PKG_CONFIG_LIBDIR" >&6
3756 fi
3757
3758 if test "x$PKG_CONFIG" != xnone
3759 then
3760         echo "$as_me:3760: checking if we should install .pc files for $PKG_CONFIG" >&5
3761 echo $ECHO_N "checking if we should install .pc files for $PKG_CONFIG... $ECHO_C" >&6
3762 else
3763         echo "$as_me:3763: checking if we should install .pc files" >&5
3764 echo $ECHO_N "checking if we should install .pc files... $ECHO_C" >&6
3765 fi
3766
3767 # Check whether --enable-pc-files or --disable-pc-files was given.
3768 if test "${enable_pc_files+set}" = set; then
3769   enableval="$enable_pc_files"
3770   enable_pc_files=$enableval
3771 else
3772   enable_pc_files=no
3773 fi;
3774 echo "$as_me:3774: result: $enable_pc_files" >&5
3775 echo "${ECHO_T}$enable_pc_files" >&6
3776
3777 if test "x$enable_pc_files" != xno
3778 then
3779         MAKE_PC_FILES=
3780         case "x$PKG_CONFIG_LIBDIR" in
3781         (xno|xyes)
3782                 { echo "$as_me:3782: WARNING: no PKG_CONFIG_LIBDIR was found" >&5
3783 echo "$as_me: WARNING: no PKG_CONFIG_LIBDIR was found" >&2;}
3784                 ;;
3785         (*)
3786
3787 if test "x$prefix" != xNONE; then
3788         cf_path_syntax="$prefix"
3789 else
3790         cf_path_syntax="$ac_default_prefix"
3791 fi
3792
3793 case ".$PKG_CONFIG_LIBDIR" in
3794 (.\$\(*\)*|.\'*\'*)
3795         ;;
3796 (..|./*|.\\*)
3797         ;;
3798 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
3799         ;;
3800 (.\${*prefix}*|.\${*dir}*)
3801         eval PKG_CONFIG_LIBDIR="$PKG_CONFIG_LIBDIR"
3802         case ".$PKG_CONFIG_LIBDIR" in
3803         (.NONE/*)
3804                 PKG_CONFIG_LIBDIR=`echo $PKG_CONFIG_LIBDIR | sed -e s%NONE%$cf_path_syntax%`
3805                 ;;
3806         esac
3807         ;;
3808 (.no|.NONE/*)
3809         PKG_CONFIG_LIBDIR=`echo $PKG_CONFIG_LIBDIR | sed -e s%NONE%$cf_path_syntax%`
3810         ;;
3811 (*)
3812         { { echo "$as_me:3812: error: expected a pathname, not \"$PKG_CONFIG_LIBDIR\"" >&5
3813 echo "$as_me: error: expected a pathname, not \"$PKG_CONFIG_LIBDIR\"" >&2;}
3814    { (exit 1); exit 1; }; }
3815         ;;
3816 esac
3817
3818                 ;;
3819         esac
3820 else
3821         MAKE_PC_FILES="#"
3822 fi
3823
3824 if test -z "$MAKE_PC_FILES"
3825 then
3826         echo "$as_me:3826: checking for suffix to add to pc-files" >&5
3827 echo $ECHO_N "checking for suffix to add to pc-files... $ECHO_C" >&6
3828
3829 # Check whether --with-pc-suffix or --without-pc-suffix was given.
3830 if test "${with_pc_suffix+set}" = set; then
3831   withval="$with_pc_suffix"
3832   case "x$withval" in
3833         (xyes|xno)
3834                 PC_MODULE_SUFFIX=
3835                 ;;
3836         (*)     PC_MODULE_SUFFIX="$withval"
3837                 ;;
3838         esac
3839 fi;
3840         test -z "$PC_MODULE_SUFFIX" && PC_MODULE_SUFFIX=none
3841         echo "$as_me:3841: result: $PC_MODULE_SUFFIX" >&5
3842 echo "${ECHO_T}$PC_MODULE_SUFFIX" >&6
3843         test "$PC_MODULE_SUFFIX" = none && PC_MODULE_SUFFIX=
3844
3845 fi
3846
3847 echo "$as_me:3847: checking if we should assume mixed-case filenames" >&5
3848 echo $ECHO_N "checking if we should assume mixed-case filenames... $ECHO_C" >&6
3849
3850 # Check whether --enable-mixed-case or --disable-mixed-case was given.
3851 if test "${enable_mixed_case+set}" = set; then
3852   enableval="$enable_mixed_case"
3853   enable_mixedcase=$enableval
3854 else
3855   enable_mixedcase=auto
3856 fi;
3857 echo "$as_me:3857: result: $enable_mixedcase" >&5
3858 echo "${ECHO_T}$enable_mixedcase" >&6
3859 if test "$enable_mixedcase" = "auto" ; then
3860
3861 echo "$as_me:3861: checking if filesystem supports mixed-case filenames" >&5
3862 echo $ECHO_N "checking if filesystem supports mixed-case filenames... $ECHO_C" >&6
3863 if test "${cf_cv_mixedcase+set}" = set; then
3864   echo $ECHO_N "(cached) $ECHO_C" >&6
3865 else
3866
3867 if test "$cross_compiling" = yes ; then
3868         case $target_alias in
3869         (*-os2-emx*|*-msdosdjgpp*|*-cygwin*|*-msys*|*-mingw*|*-uwin*)
3870                 cf_cv_mixedcase=no
3871                 ;;
3872         (*)
3873                 cf_cv_mixedcase=yes
3874                 ;;
3875         esac
3876 else
3877         rm -f conftest CONFTEST
3878         echo test >conftest
3879         if test -f CONFTEST ; then
3880                 cf_cv_mixedcase=no
3881         else
3882                 cf_cv_mixedcase=yes
3883         fi
3884         rm -f conftest CONFTEST
3885 fi
3886
3887 fi
3888 echo "$as_me:3888: result: $cf_cv_mixedcase" >&5
3889 echo "${ECHO_T}$cf_cv_mixedcase" >&6
3890 test "$cf_cv_mixedcase" = yes &&
3891 cat >>confdefs.h <<\EOF
3892 #define MIXEDCASE_FILENAMES 1
3893 EOF
3894
3895 else
3896         cf_cv_mixedcase=$enable_mixedcase
3897         if test "x$enable_mixedcase" = "xyes" ; then
3898
3899 cat >>confdefs.h <<\EOF
3900 #define MIXEDCASE_FILENAMES 1
3901 EOF
3902
3903         fi
3904 fi
3905
3906 # do this after mixed-case option (tags/TAGS is not as important as tic).
3907 echo "$as_me:3907: checking whether ${MAKE-make} sets \${MAKE}" >&5
3908 echo $ECHO_N "checking whether ${MAKE-make} sets \${MAKE}... $ECHO_C" >&6
3909 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,./+-,__p_,'`
3910 if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
3911   echo $ECHO_N "(cached) $ECHO_C" >&6
3912 else
3913   cat >conftest.make <<\EOF
3914 all:
3915         @echo 'ac_maketemp="${MAKE}"'
3916 EOF
3917 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
3918 eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
3919 if test -n "$ac_maketemp"; then
3920   eval ac_cv_prog_make_${ac_make}_set=yes
3921 else
3922   eval ac_cv_prog_make_${ac_make}_set=no
3923 fi
3924 rm -f conftest.make
3925 fi
3926 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
3927   echo "$as_me:3927: result: yes" >&5
3928 echo "${ECHO_T}yes" >&6
3929   SET_MAKE=
3930 else
3931   echo "$as_me:3931: result: no" >&5
3932 echo "${ECHO_T}no" >&6
3933   SET_MAKE="MAKE=${MAKE-make}"
3934 fi
3935
3936 for ac_prog in exctags ctags
3937 do
3938   # Extract the first word of "$ac_prog", so it can be a program name with args.
3939 set dummy $ac_prog; ac_word=$2
3940 echo "$as_me:3940: checking for $ac_word" >&5
3941 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3942 if test "${ac_cv_prog_CTAGS+set}" = set; then
3943   echo $ECHO_N "(cached) $ECHO_C" >&6
3944 else
3945   if test -n "$CTAGS"; then
3946   ac_cv_prog_CTAGS="$CTAGS" # Let the user override the test.
3947 else
3948   ac_save_IFS=$IFS; IFS=$ac_path_separator
3949 ac_dummy="$PATH"
3950 for ac_dir in $ac_dummy; do
3951   IFS=$ac_save_IFS
3952   test -z "$ac_dir" && ac_dir=.
3953   $as_executable_p "$ac_dir/$ac_word" || continue
3954 ac_cv_prog_CTAGS="$ac_prog"
3955 echo "$as_me:3955: found $ac_dir/$ac_word" >&5
3956 break
3957 done
3958
3959 fi
3960 fi
3961 CTAGS=$ac_cv_prog_CTAGS
3962 if test -n "$CTAGS"; then
3963   echo "$as_me:3963: result: $CTAGS" >&5
3964 echo "${ECHO_T}$CTAGS" >&6
3965 else
3966   echo "$as_me:3966: result: no" >&5
3967 echo "${ECHO_T}no" >&6
3968 fi
3969
3970   test -n "$CTAGS" && break
3971 done
3972
3973 for ac_prog in exetags etags
3974 do
3975   # Extract the first word of "$ac_prog", so it can be a program name with args.
3976 set dummy $ac_prog; ac_word=$2
3977 echo "$as_me:3977: checking for $ac_word" >&5
3978 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3979 if test "${ac_cv_prog_ETAGS+set}" = set; then
3980   echo $ECHO_N "(cached) $ECHO_C" >&6
3981 else
3982   if test -n "$ETAGS"; then
3983   ac_cv_prog_ETAGS="$ETAGS" # Let the user override the test.
3984 else
3985   ac_save_IFS=$IFS; IFS=$ac_path_separator
3986 ac_dummy="$PATH"
3987 for ac_dir in $ac_dummy; do
3988   IFS=$ac_save_IFS
3989   test -z "$ac_dir" && ac_dir=.
3990   $as_executable_p "$ac_dir/$ac_word" || continue
3991 ac_cv_prog_ETAGS="$ac_prog"
3992 echo "$as_me:3992: found $ac_dir/$ac_word" >&5
3993 break
3994 done
3995
3996 fi
3997 fi
3998 ETAGS=$ac_cv_prog_ETAGS
3999 if test -n "$ETAGS"; then
4000   echo "$as_me:4000: result: $ETAGS" >&5
4001 echo "${ECHO_T}$ETAGS" >&6
4002 else
4003   echo "$as_me:4003: result: no" >&5
4004 echo "${ECHO_T}no" >&6
4005 fi
4006
4007   test -n "$ETAGS" && break
4008 done
4009
4010 # Extract the first word of "${CTAGS:-ctags}", so it can be a program name with args.
4011 set dummy ${CTAGS:-ctags}; ac_word=$2
4012 echo "$as_me:4012: checking for $ac_word" >&5
4013 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4014 if test "${ac_cv_prog_MAKE_LOWER_TAGS+set}" = set; then
4015   echo $ECHO_N "(cached) $ECHO_C" >&6
4016 else
4017   if test -n "$MAKE_LOWER_TAGS"; then
4018   ac_cv_prog_MAKE_LOWER_TAGS="$MAKE_LOWER_TAGS" # Let the user override the test.
4019 else
4020   ac_save_IFS=$IFS; IFS=$ac_path_separator
4021 ac_dummy="$PATH"
4022 for ac_dir in $ac_dummy; do
4023   IFS=$ac_save_IFS
4024   test -z "$ac_dir" && ac_dir=.