]> ncurses.scripts.mit.edu Git - ncurses.git/blob - configure
ncurses 5.9 - patch 20121026
[ncurses.git] / configure
1 #! /bin/sh
2 # From configure.in Revision: 1.558 .
3 # Guess values for system-dependent variables and create Makefiles.
4 # Generated by Autoconf 2.52.20121002.
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   --without-manpages      suppress install of manpages
710   --without-progs         suppress build with programs (e.g., tic)
711   --without-tests         suppress build with test-programs
712   --without-curses-h      install curses.h as ncurses.h only
713   --with-pkg-config{=path} enable/disable use of pkg-config
714   --with-pkg-config-libdir=XXX use given directory for installing pc-files
715   --enable-pc-files       generate and install .pc files for pkg-config
716   --enable-mixed-case     tic should assume mixed-case filenames
717   --with-install-prefix   prefixes actual install-location ($DESTDIR)
718 Build-Tools Needed to Compile Temporary Applications for Cross-compiling:
719   --with-build-cc=XXX     the build C compiler ($BUILD_CC)
720   --with-build-cpp=XXX    the build C preprocessor ($BUILD_CPP)
721   --with-build-cflags=XXX the build C compiler-flags ($BUILD_CFLAGS)
722   --with-build-cppflags=XXX the build C preprocessor-flags ($BUILD_CPPFLAGS)
723   --with-build-ldflags=XXX the build linker-flags ($BUILD_LDFLAGS)
724   --with-build-libs=XXX   the build libraries (${BUILD_LIBS})
725 Options to Specify the Libraries Built/Used:
726   --disable-libtool-version  enable to use libtool's incompatible naming scheme
727   --with-libtool          generate libraries with libtool
728   --with-shared           generate shared-libraries
729   --with-normal           generate normal-libraries (default)
730   --with-debug            generate debug-libraries (default)
731   --with-profile          generate profile-libraries
732   --with-lib-prefix       override library-prefix
733   --with-termlib          generate separate terminfo library
734   --with-ticlib           generate separate tic library
735   --with-gpm              use Alessandro Rubini's GPM library
736   --without-dlsym         do not use dlsym() to load GPM dynamically
737   --with-sysmouse         use sysmouse (FreeBSD console)
738   --enable-rpath          use rpath option when generating shared libraries
739   --disable-relink        relink shared libraries during install
740   --with-shlib-version=X  Specify rel or abi version for shared libs
741   --disable-rpath-hack    don't add rpath options for additional libraries
742 Fine-Tuning Your Configuration:
743   --disable-overwrite     leave out the link to -lcurses
744   --disable-database      do not use terminfo, only fallbacks/termcap
745   --with-database=XXX     specify terminfo source to install
746   --with-hashed-db        specify hashed-database library
747   --with-fallbacks=XXX    specify list of fallback terminal descriptions
748   --without-xterm-new     specify if xterm terminfo should be old version
749   --with-xterm-kbs=XXX     specify if xterm backspace sends BS or DEL
750   --with-terminfo-dirs=XXX specify list of terminfo directories (default: DATADIR/terminfo)
751   --with-default-terminfo-dir=DIR default terminfo directory (default: DATADIR/terminfo)
752   --disable-big-core      assume machine has little memory
753   --disable-big-strings   assume compiler has only standard-size strings
754   --enable-termcap        compile in termcap fallback support
755   --with-termpath=XXX     specify list of termcap files (default: /etc/termcap:/usr/share/misc/termcap)
756   --enable-getcap         fast termcap load, no xrefs to terminfo
757   --enable-getcap-cache   cache translated termcaps in ~/.terminfo
758   --disable-home-terminfo drop ~/.terminfo from terminfo search-path
759   --disable-root-environ  restrict environment when running as root
760   --enable-symlinks       make tic use symbolic links not hard links
761   --enable-broken_linker  compile with broken-linker support code
762   --enable-bsdpad         recognize BSD-style prefix padding
763   --enable-widec          compile with wide-char/UTF-8 code
764   --disable-lp64          allow chtype to be long (ignore _LP64)
765   --disable-largefile     omit support for large files
766   --disable-tparm-varargs compile tparm() without varargs interface
767   --disable-tic-depends   link tic library without explicit dependency on ncurses library
768   --with-bool=TYPE        override fallback type of bool variable
769   --with-caps=alt         compile with alternate Caps file
770   --with-chtype=TYPE      override type of chtype
771   --with-ospeed=TYPE      override type of ospeed variable
772   --with-mmask-t=TYPE     override type of mmask_t
773   --with-ccharw-max=XXX   override size CCHARW_MAX
774   --with-tparm-arg=TYPE   override parameter type of tparm
775   --with-rcs-ids          compile-in RCS identifiers
776 Options to Specify How Manpages are Installed:
777   --with-manpage-format   specify manpage-format: gzip/compress/BSDI/normal and
778                           optionally formatted/catonly, e.g., gzip,formatted
779   --with-manpage-renames  specify manpage-renaming
780   --with-manpage-aliases  specify manpage-aliases using .so
781   --with-manpage-symlinks specify manpage-aliases using symlinks
782   --with-manpage-tbl      specify manpage processing with tbl
783 Extensions:
784   --disable-ext-funcs     disable function-extensions
785   --enable-sp-funcs       enable experimental SCREEN-extensions
786   --enable-term-driver    enable experimental terminal-driver
787   --enable-const          compile with extra/non-standard const
788   --enable-ext-colors     compile for 256-color support
789   --enable-ext-mouse      compile for extended mouse-encoding
790   --enable-no-padding     compile with $NCURSES_NO_PADDING code
791   --enable-signed-char    compile using signed Boolean's in term.h
792   --enable-sigwinch       compile with SIGWINCH handler
793   --enable-tcap-names     compile with user-definable terminal capabilities
794 Development Code:
795   --without-develop       disable development options
796   --enable-hard-tabs      compile with hard-tabs code
797   --enable-xmc-glitch     compile with support for xmc (magic-cookie)
798 Experimental Code:
799   --disable-assumed-color do not assume anything about default-colors
800   --disable-hashmap       compile without hashmap scrolling-optimization
801   --enable-colorfgbg      compile-in experimental $COLORFGBG code
802   --enable-interop        compile-in experimental interop bindings
803   --with-pthread          use POSIX thread library
804   --enable-pthreads-eintr enable EINTR in wgetch with pthreads
805   --enable-weak-symbols   enable weak-symbols for pthreads
806   --enable-reentrant      compile with experimental reentrant code
807   --with-wrap-prefix=XXX  override prefix used for public variables
808   --enable-safe-sprintf   compile with experimental safe-sprintf code
809   --disable-scroll-hints  compile without scroll-hints code
810   --enable-wgetch-events  compile with experimental wgetch-events code
811 Testing/development Options:
812   --disable-echo          do not display "compiling" commands
813   --enable-warnings       build: turn on GCC compiler warnings
814   --enable-string-hacks  work around bogus compiler/loader warnings
815   --enable-assertions     test: turn on generation of assertion code
816   --with-dmalloc          test: use Gray Watson's dmalloc library
817   --with-dbmalloc         test: use Conor Cahill's dbmalloc library
818   --with-valgrind         test: use valgrind
819   --disable-leaks         test: free permanent memory, analyze leaks
820   --enable-expanded       test: generate functions for certain macros
821   --disable-macros        test: use functions rather than macros
822   --with-trace            test: add trace() function to all models of ncurses
823 Ada95 Binding Options:
824   --with-ada-compiler=CMD specify Ada95 compiler command (default gnatmake)
825   --with-ada-include=DIR  Ada includes are in DIR (default: PREFIX/share/ada/adainclude)
826   --with-ada-objects=DIR  Ada objects are in DIR (default: PREFIX/lib/ada/adalib)
827   --with-ada-sharedlib=XX build Ada95 shared-library
828
829 Some influential environment variables:
830   CC          C compiler command
831   CFLAGS      C compiler flags
832   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
833               nonstandard directory <lib dir>
834   CPPFLAGS    C/C++ preprocessor flags, e.g. -I<include dir> if you have
835               headers in a nonstandard directory <include dir>
836   CPP         C preprocessor
837   CXX         C++ compiler command
838   CXXFLAGS    C++ compiler flags
839   CXXCPP      C++ preprocessor
840
841 Use these variables to override the choices made by `configure' or to help
842 it to find libraries and programs with nonstandard names/locations.
843
844 EOF
845 fi
846
847 if test "$ac_init_help" = "recursive"; then
848   # If there are subdirs, report their specific --help.
849   ac_popdir=`pwd`
850   for ac_subdir in : $ac_subdirs_all; do test "x$ac_subdir" = x: && continue
851     cd $ac_subdir
852     # A "../" for each directory in /$ac_subdir.
853     ac_dots=`echo $ac_subdir |
854              sed 's,^\./,,;s,[^/]$,&/,;s,[^/]*/,../,g'`
855
856     case $srcdir in
857     .) # No --srcdir option.  We are building in place.
858       ac_sub_srcdir=$srcdir ;;
859     [\\/]* | ?:[\\/]* ) # Absolute path.
860       ac_sub_srcdir=$srcdir/$ac_subdir ;;
861     *) # Relative path.
862       ac_sub_srcdir=$ac_dots$srcdir/$ac_subdir ;;
863     esac
864
865     # Check for guested configure; otherwise get Cygnus style configure.
866     if test -f $ac_sub_srcdir/configure.gnu; then
867       echo
868       $SHELL $ac_sub_srcdir/configure.gnu  --help=recursive
869     elif test -f $ac_sub_srcdir/configure; then
870       echo
871       $SHELL $ac_sub_srcdir/configure  --help=recursive
872     elif test -f $ac_sub_srcdir/configure.ac ||
873            test -f $ac_sub_srcdir/configure.in; then
874       echo
875       $ac_configure --help
876     else
877       echo "$as_me: WARNING: no configuration information is in $ac_subdir" >&2
878     fi
879     cd $ac_popdir
880   done
881 fi
882
883 test -n "$ac_init_help" && exit 0
884 if $ac_init_version; then
885   cat <<\EOF
886
887 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
888 Free Software Foundation, Inc.
889 This configure script is free software; the Free Software Foundation
890 gives unlimited permission to copy, distribute and modify it.
891 EOF
892   exit 0
893 fi
894 exec 5>config.log
895 cat >&5 <<EOF
896 This file contains any messages produced by compilers while
897 running configure, to aid debugging if configure makes a mistake.
898
899 It was created by $as_me, which was
900 generated by GNU Autoconf 2.52.20121002.  Invocation command line was
901
902   $ $0 $@
903
904 EOF
905 {
906 cat <<_ASUNAME
907 ## ---------- ##
908 ## Platform.  ##
909 ## ---------- ##
910
911 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
912 uname -m = `(uname -m) 2>/dev/null || echo unknown`
913 uname -r = `(uname -r) 2>/dev/null || echo unknown`
914 uname -s = `(uname -s) 2>/dev/null || echo unknown`
915 uname -v = `(uname -v) 2>/dev/null || echo unknown`
916
917 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
918 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
919
920 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
921 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
922 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
923 hostinfo               = `(hostinfo) 2>/dev/null               || echo unknown`
924 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
925 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
926 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
927
928 PATH = $PATH
929
930 _ASUNAME
931 } >&5
932
933 cat >&5 <<EOF
934 ## ------------ ##
935 ## Core tests.  ##
936 ## ------------ ##
937
938 EOF
939
940 # Keep a trace of the command line.
941 # Strip out --no-create and --no-recursion so they do not pile up.
942 # Also quote any args containing shell meta-characters.
943 ac_configure_args=
944 ac_sep=
945 for ac_arg
946 do
947   case $ac_arg in
948   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
949   | --no-cr | --no-c) ;;
950   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
951   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
952   *" "*|*"      "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
953     ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"`
954     ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
955     ac_sep=" " ;;
956   *) ac_configure_args="$ac_configure_args$ac_sep$ac_arg"
957      ac_sep=" " ;;
958   esac
959   # Get rid of the leading space.
960 done
961
962 # When interrupted or exit'd, cleanup temporary files, and complete
963 # config.log.  We remove comments because anyway the quotes in there
964 # would cause problems or look ugly.
965 trap 'exit_status=$?
966   # Save into config.log some information that might help in debugging.
967   echo >&5
968   echo "## ----------------- ##" >&5
969   echo "## Cache variables.  ##" >&5
970   echo "## ----------------- ##" >&5
971   echo >&5
972   # The following way of writing the cache mishandles newlines in values,
973 {
974   (set) 2>&1 |
975     case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
976     *ac_space=\ *)
977       sed -n \
978         "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
979           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
980       ;;
981     *)
982       sed -n \
983         "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
984       ;;
985     esac;
986 } >&5
987   sed "/^$/d" confdefs.h >conftest.log
988   if test -s conftest.log; then
989     echo >&5
990     echo "## ------------ ##" >&5
991     echo "## confdefs.h.  ##" >&5
992     echo "## ------------ ##" >&5
993     echo >&5
994     cat conftest.log >&5
995   fi
996   (echo; echo) >&5
997   test "$ac_signal" != 0 &&
998     echo "$as_me: caught signal $ac_signal" >&5
999   echo "$as_me: exit $exit_status" >&5
1000   rm -rf conftest* confdefs* core core.* *.core conf$$* $ac_clean_files &&
1001     exit $exit_status
1002      ' 0
1003 for ac_signal in 1 2 13 15; do
1004   trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1005 done
1006 ac_signal=0
1007
1008 # confdefs.h avoids OS command line length limits that DEFS can exceed.
1009 rm -rf conftest* confdefs.h
1010 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
1011 echo >confdefs.h
1012
1013 # Let the site file select an alternate cache file if it wants to.
1014 # Prefer explicitly selected file to automatically selected ones.
1015 if test -z "$CONFIG_SITE"; then
1016   if test "x$prefix" != xNONE; then
1017     CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
1018   else
1019     CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
1020   fi
1021 fi
1022 for ac_site_file in $CONFIG_SITE; do
1023   if test -r "$ac_site_file"; then
1024     { echo "$as_me:1024: loading site script $ac_site_file" >&5
1025 echo "$as_me: loading site script $ac_site_file" >&6;}
1026     cat "$ac_site_file" >&5
1027     . "$ac_site_file"
1028   fi
1029 done
1030
1031 if test -r "$cache_file"; then
1032   # Some versions of bash will fail to source /dev/null (special
1033   # files actually), so we avoid doing that.
1034   if test -f "$cache_file"; then
1035     { echo "$as_me:1035: loading cache $cache_file" >&5
1036 echo "$as_me: loading cache $cache_file" >&6;}
1037     case $cache_file in
1038       [\\/]* | ?:[\\/]* ) . $cache_file;;
1039       *)                      . ./$cache_file;;
1040     esac
1041   fi
1042 else
1043   { echo "$as_me:1043: creating cache $cache_file" >&5
1044 echo "$as_me: creating cache $cache_file" >&6;}
1045   >$cache_file
1046 fi
1047
1048 # Check that the precious variables saved in the cache have kept the same
1049 # value.
1050 ac_cache_corrupted=false
1051 for ac_var in `(set) 2>&1 |
1052                sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
1053   eval ac_old_set=\$ac_cv_env_${ac_var}_set
1054   eval ac_new_set=\$ac_env_${ac_var}_set
1055   eval ac_old_val="\$ac_cv_env_${ac_var}_value"
1056   eval ac_new_val="\$ac_env_${ac_var}_value"
1057   case $ac_old_set,$ac_new_set in
1058     set,)
1059       { echo "$as_me:1059: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1060 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1061       ac_cache_corrupted=: ;;
1062     ,set)
1063       { echo "$as_me:1063: error: \`$ac_var' was not set in the previous run" >&5
1064 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1065       ac_cache_corrupted=: ;;
1066     ,);;
1067     *)
1068       if test "x$ac_old_val" != "x$ac_new_val"; then
1069         { echo "$as_me:1069: error: \`$ac_var' has changed since the previous run:" >&5
1070 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1071         { echo "$as_me:1071:   former value:  $ac_old_val" >&5
1072 echo "$as_me:   former value:  $ac_old_val" >&2;}
1073         { echo "$as_me:1073:   current value: $ac_new_val" >&5
1074 echo "$as_me:   current value: $ac_new_val" >&2;}
1075         ac_cache_corrupted=:
1076       fi;;
1077   esac
1078   # Pass precious variables to config.status.  It doesn't matter if
1079   # we pass some twice (in addition to the command line arguments).
1080   if test "$ac_new_set" = set; then
1081     case $ac_new_val in
1082     *" "*|*"    "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1083       ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"`
1084       ac_configure_args="$ac_configure_args '$ac_arg'"
1085       ;;
1086     *) ac_configure_args="$ac_configure_args $ac_var=$ac_new_val"
1087        ;;
1088     esac
1089   fi
1090 done
1091 if $ac_cache_corrupted; then
1092   { echo "$as_me:1092: error: changes in the environment can compromise the build" >&5
1093 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1094   { { echo "$as_me:1094: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1095 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1096    { (exit 1); exit 1; }; }
1097 fi
1098
1099 ac_ext=c
1100 ac_cpp='$CPP $CPPFLAGS'
1101 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1102 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1103 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1104 ac_main_return=return
1105
1106 case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
1107   *c*,-n*) ECHO_N= ECHO_C='
1108 ' ECHO_T='      ' ;;
1109   *c*,*  ) ECHO_N=-n ECHO_C= ECHO_T= ;;
1110   *)      ECHO_N= ECHO_C='\c' ECHO_T= ;;
1111 esac
1112 echo "#! $SHELL" >conftest.sh
1113 echo  "exit 0"   >>conftest.sh
1114 chmod +x conftest.sh
1115 if { (echo "$as_me:1115: PATH=\".;.\"; conftest.sh") >&5
1116   (PATH=".;."; conftest.sh) 2>&5
1117   ac_status=$?
1118   echo "$as_me:1118: \$? = $ac_status" >&5
1119   (exit $ac_status); }; then
1120   ac_path_separator=';'
1121 else
1122   ac_path_separator=:
1123 fi
1124 PATH_SEPARATOR="$ac_path_separator"
1125 rm -f conftest.sh
1126
1127 ac_config_headers="$ac_config_headers include/ncurses_cfg.h:include/ncurses_cfg.hin"
1128
1129 top_builddir=`pwd`
1130
1131 echo "$as_me:1131: checking for egrep" >&5
1132 echo $ECHO_N "checking for egrep... $ECHO_C" >&6
1133 if test "${ac_cv_prog_egrep+set}" = set; then
1134   echo $ECHO_N "(cached) $ECHO_C" >&6
1135 else
1136   if echo a | (grep -E '(a|b)') >/dev/null 2>&1
1137     then ac_cv_prog_egrep='grep -E'
1138     else ac_cv_prog_egrep='egrep'
1139     fi
1140 fi
1141 echo "$as_me:1141: result: $ac_cv_prog_egrep" >&5
1142 echo "${ECHO_T}$ac_cv_prog_egrep" >&6
1143  EGREP=$ac_cv_prog_egrep
1144
1145 test -z "$EGREP" && { { echo "$as_me:1145: error: No egrep program found" >&5
1146 echo "$as_me: error: No egrep program found" >&2;}
1147    { (exit 1); exit 1; }; }
1148
1149 NCURSES_MAJOR="`$ac_cv_prog_egrep '^NCURSES_MAJOR[      ]*=' $srcdir/dist.mk | sed -e 's/^[^0-9]*//'`"
1150 NCURSES_MINOR="`$ac_cv_prog_egrep '^NCURSES_MINOR[      ]*=' $srcdir/dist.mk | sed -e 's/^[^0-9]*//'`"
1151 NCURSES_PATCH="`$ac_cv_prog_egrep '^NCURSES_PATCH[      ]*=' $srcdir/dist.mk | sed -e 's/^[^0-9]*//'`"
1152 cf_cv_abi_version=${NCURSES_MAJOR}
1153 cf_cv_rel_version=${NCURSES_MAJOR}.${NCURSES_MINOR}
1154 cf_cv_timestamp=`date`
1155 echo "$as_me:1155: result: Configuring NCURSES $cf_cv_rel_version ABI $cf_cv_abi_version ($cf_cv_timestamp)" >&5
1156 echo "${ECHO_T}Configuring NCURSES $cf_cv_rel_version ABI $cf_cv_abi_version ($cf_cv_timestamp)" >&6
1157
1158 test -z "$cf_cv_rel_version" && cf_cv_rel_version=0.0
1159
1160 # Check whether --with-rel-version or --without-rel-version was given.
1161 if test "${with_rel_version+set}" = set; then
1162   withval="$with_rel_version"
1163   { echo "$as_me:1163: WARNING: overriding release version $cf_cv_rel_version to $withval" >&5
1164 echo "$as_me: WARNING: overriding release version $cf_cv_rel_version to $withval" >&2;}
1165  cf_cv_rel_version=$withval
1166 fi;
1167
1168  NCURSES_MAJOR=`echo "$cf_cv_rel_version" | sed -e 's/\..*//'`
1169  NCURSES_MINOR=`echo "$cf_cv_rel_version" | sed -e 's/^[^.]*//' -e 's/^\.//' -e 's/\..*//'`
1170
1171 if test -n "$NCURSES_MAJOR" ; then
1172   case $NCURSES_MAJOR in #(vi
1173   [0-9]*) #(vi
1174         ;;
1175   *)
1176         { { echo "$as_me:1176: error: Release major-version is not a number: $NCURSES_MAJOR" >&5
1177 echo "$as_me: error: Release major-version is not a number: $NCURSES_MAJOR" >&2;}
1178    { (exit 1); exit 1; }; }
1179         ;;
1180   esac
1181 else
1182   { { echo "$as_me:1182: error: Release major-version value is empty" >&5
1183 echo "$as_me: error: Release major-version value is empty" >&2;}
1184    { (exit 1); exit 1; }; }
1185 fi
1186
1187 if test -n "$NCURSES_MINOR" ; then
1188   case $NCURSES_MINOR in #(vi
1189   [0-9]*) #(vi
1190         ;;
1191   *)
1192         { { echo "$as_me:1192: error: Release minor-version is not a number: $NCURSES_MINOR" >&5
1193 echo "$as_me: error: Release minor-version is not a number: $NCURSES_MINOR" >&2;}
1194    { (exit 1); exit 1; }; }
1195         ;;
1196   esac
1197 else
1198   { { echo "$as_me:1198: error: Release minor-version value is empty" >&5
1199 echo "$as_me: error: Release minor-version value is empty" >&2;}
1200    { (exit 1); exit 1; }; }
1201 fi
1202
1203 test -z "$cf_cv_abi_version" && cf_cv_abi_version=0
1204
1205 # Check whether --with-abi-version or --without-abi-version was given.
1206 if test "${with_abi_version+set}" = set; then
1207   withval="$with_abi_version"
1208   { echo "$as_me:1208: WARNING: overriding ABI version $cf_cv_abi_version to $withval" >&5
1209 echo "$as_me: WARNING: overriding ABI version $cf_cv_abi_version to $withval" >&2;}
1210  cf_cv_abi_version=$withval
1211 fi;
1212
1213 if test -n "$cf_cv_abi_version" ; then
1214   case $cf_cv_abi_version in #(vi
1215   [0-9]*) #(vi
1216         ;;
1217   *)
1218         { { echo "$as_me:1218: error: ABI version is not a number: $cf_cv_abi_version" >&5
1219 echo "$as_me: error: ABI version is not a number: $cf_cv_abi_version" >&2;}
1220    { (exit 1); exit 1; }; }
1221         ;;
1222   esac
1223 else
1224   { { echo "$as_me:1224: error: ABI version value is empty" >&5
1225 echo "$as_me: error: ABI version value is empty" >&2;}
1226    { (exit 1); exit 1; }; }
1227 fi
1228
1229 ac_aux_dir=
1230 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
1231   if test -f $ac_dir/install-sh; then
1232     ac_aux_dir=$ac_dir
1233     ac_install_sh="$ac_aux_dir/install-sh -c"
1234     break
1235   elif test -f $ac_dir/install.sh; then
1236     ac_aux_dir=$ac_dir
1237     ac_install_sh="$ac_aux_dir/install.sh -c"
1238     break
1239   elif test -f $ac_dir/shtool; then
1240     ac_aux_dir=$ac_dir
1241     ac_install_sh="$ac_aux_dir/shtool install -c"
1242     break
1243   fi
1244 done
1245 if test -z "$ac_aux_dir"; then
1246   { { echo "$as_me:1246: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
1247 echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
1248    { (exit 1); exit 1; }; }
1249 fi
1250 ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1251 ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1252 ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
1253
1254 # Make sure we can run config.sub.
1255 $ac_config_sub sun4 >/dev/null 2>&1 ||
1256   { { echo "$as_me:1256: error: cannot run $ac_config_sub" >&5
1257 echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1258    { (exit 1); exit 1; }; }
1259
1260 echo "$as_me:1260: checking build system type" >&5
1261 echo $ECHO_N "checking build system type... $ECHO_C" >&6
1262 if test "${ac_cv_build+set}" = set; then
1263   echo $ECHO_N "(cached) $ECHO_C" >&6
1264 else
1265   ac_cv_build_alias=$build_alias
1266 test -z "$ac_cv_build_alias" &&
1267   ac_cv_build_alias=`$ac_config_guess`
1268 test -z "$ac_cv_build_alias" &&
1269   { { echo "$as_me:1269: error: cannot guess build type; you must specify one" >&5
1270 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1271    { (exit 1); exit 1; }; }
1272 ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
1273   { { echo "$as_me:1273: error: $ac_config_sub $ac_cv_build_alias failed." >&5
1274 echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed." >&2;}
1275    { (exit 1); exit 1; }; }
1276
1277 fi
1278 echo "$as_me:1278: result: $ac_cv_build" >&5
1279 echo "${ECHO_T}$ac_cv_build" >&6
1280 build=$ac_cv_build
1281 build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1282 build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1283 build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1284
1285 echo "$as_me:1285: checking host system type" >&5
1286 echo $ECHO_N "checking host system type... $ECHO_C" >&6
1287 if test "${ac_cv_host+set}" = set; then
1288   echo $ECHO_N "(cached) $ECHO_C" >&6
1289 else
1290   ac_cv_host_alias=$host_alias
1291 test -z "$ac_cv_host_alias" &&
1292   ac_cv_host_alias=$ac_cv_build_alias
1293 ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
1294   { { echo "$as_me:1294: error: $ac_config_sub $ac_cv_host_alias failed" >&5
1295 echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1296    { (exit 1); exit 1; }; }
1297
1298 fi
1299 echo "$as_me:1299: result: $ac_cv_host" >&5
1300 echo "${ECHO_T}$ac_cv_host" >&6
1301 host=$ac_cv_host
1302 host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1303 host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1304 host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1305
1306 if test -f $srcdir/config.guess || test -f $ac_aux_dir/config.guess ; then
1307         echo "$as_me:1307: checking target system type" >&5
1308 echo $ECHO_N "checking target system type... $ECHO_C" >&6
1309 if test "${ac_cv_target+set}" = set; then
1310   echo $ECHO_N "(cached) $ECHO_C" >&6
1311 else
1312   ac_cv_target_alias=$target_alias
1313 test "x$ac_cv_target_alias" = "x" &&
1314   ac_cv_target_alias=$ac_cv_host_alias
1315 ac_cv_target=`$ac_config_sub $ac_cv_target_alias` ||
1316   { { echo "$as_me:1316: error: $ac_config_sub $ac_cv_target_alias failed" >&5
1317 echo "$as_me: error: $ac_config_sub $ac_cv_target_alias failed" >&2;}
1318    { (exit 1); exit 1; }; }
1319
1320 fi
1321 echo "$as_me:1321: result: $ac_cv_target" >&5
1322 echo "${ECHO_T}$ac_cv_target" >&6
1323 target=$ac_cv_target
1324 target_cpu=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1325 target_vendor=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1326 target_os=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1327
1328 # The aliases save the names the user supplied, while $host etc.
1329 # will get canonicalized.
1330 test -n "$target_alias" &&
1331   test "$program_prefix$program_suffix$program_transform_name" = \
1332     NONENONEs,x,x, &&
1333   program_prefix=${target_alias}-
1334         system_name="$host_os"
1335 else
1336         system_name="`(uname -s -r) 2>/dev/null`"
1337         if test -z "$system_name" ; then
1338                 system_name="`(hostname) 2>/dev/null`"
1339         fi
1340 fi
1341 test -n "$system_name" &&
1342 cat >>confdefs.h <<EOF
1343 #define SYSTEM_NAME "$system_name"
1344 EOF
1345
1346 if test "${cf_cv_system_name+set}" = set; then
1347   echo $ECHO_N "(cached) $ECHO_C" >&6
1348 else
1349   cf_cv_system_name="$system_name"
1350 fi
1351
1352 test -z "$system_name" && system_name="$cf_cv_system_name"
1353 test -n "$cf_cv_system_name" && echo "$as_me:1353: result: Configuring for $cf_cv_system_name" >&5
1354 echo "${ECHO_T}Configuring for $cf_cv_system_name" >&6
1355
1356 if test ".$system_name" != ".$cf_cv_system_name" ; then
1357         echo "$as_me:1357: result: Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&5
1358 echo "${ECHO_T}Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&6
1359         { { echo "$as_me:1359: error: \"Please remove config.cache and try again.\"" >&5
1360 echo "$as_me: error: \"Please remove config.cache and try again.\"" >&2;}
1361    { (exit 1); exit 1; }; }
1362 fi
1363
1364 # Check whether --with-system-type or --without-system-type was given.
1365 if test "${with_system_type+set}" = set; then
1366   withval="$with_system_type"
1367   { echo "$as_me:1367: WARNING: overriding system type to $withval" >&5
1368 echo "$as_me: WARNING: overriding system type to $withval" >&2;}
1369  cf_cv_system_name=$withval
1370 fi;
1371
1372 ###     Save the given $CFLAGS to allow user-override.
1373 cf_user_CFLAGS="$CFLAGS"
1374
1375 ###     Default install-location
1376
1377 echo "$as_me:1377: checking for prefix" >&5
1378 echo $ECHO_N "checking for prefix... $ECHO_C" >&6
1379 if test "x$prefix" = "xNONE" ; then
1380         case "$cf_cv_system_name" in
1381                 # non-vendor systems don't have a conflict
1382         openbsd*|freebsd*|mirbsd*|linux*|cygwin*|k*bsd*-gnu)
1383                 prefix=/usr
1384                 ;;
1385         *)      prefix=$ac_default_prefix
1386                 ;;
1387         esac
1388 fi
1389 echo "$as_me:1389: result: $prefix" >&5
1390 echo "${ECHO_T}$prefix" >&6
1391
1392 if test "x$prefix" = "xNONE" ; then
1393 echo "$as_me:1393: checking for default include-directory" >&5
1394 echo $ECHO_N "checking for default include-directory... $ECHO_C" >&6
1395 test -n "$verbose" && echo 1>&6
1396 for cf_symbol in \
1397         $includedir \
1398         $includedir/ncurses \
1399         $prefix/include \
1400         $prefix/include/ncurses \
1401         /usr/local/include \
1402         /usr/local/include/ncurses \
1403         /usr/include \
1404         /usr/include/ncurses
1405 do
1406         cf_dir=`eval echo $cf_symbol`
1407         if test -f $cf_dir/curses.h ; then
1408         if ( fgrep NCURSES_VERSION $cf_dir/curses.h 2>&1 >/dev/null ) ; then
1409                 includedir="$cf_symbol"
1410                 test -n "$verbose"  && echo $ac_n "     found " 1>&6
1411                 break
1412         fi
1413         fi
1414         test -n "$verbose"  && echo "   tested $cf_dir" 1>&6
1415 done
1416 echo "$as_me:1416: result: $includedir" >&5
1417 echo "${ECHO_T}$includedir" >&6
1418 fi
1419
1420 ###     Checks for programs.
1421
1422 # Check whether --with-ada or --without-ada was given.
1423 if test "${with_ada+set}" = set; then
1424   withval="$with_ada"
1425   cf_with_ada=$withval
1426 else
1427   cf_with_ada=yes
1428 fi;
1429 if test "x$cf_with_ada" = xyes
1430 then
1431         cf_PROG_CC="gnatgcc gcc cc"
1432 else
1433         cf_PROG_CC="gcc cc"
1434 fi
1435
1436 ac_ext=c
1437 ac_cpp='$CPP $CPPFLAGS'
1438 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1439 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1440 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1441 ac_main_return=return
1442 if test -n "$ac_tool_prefix"; then
1443   for ac_prog in $cf_PROG_CC
1444   do
1445     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
1446 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
1447 echo "$as_me:1447: checking for $ac_word" >&5
1448 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1449 if test "${ac_cv_prog_CC+set}" = set; then
1450   echo $ECHO_N "(cached) $ECHO_C" >&6
1451 else
1452   if test -n "$CC"; then
1453   ac_cv_prog_CC="$CC" # Let the user override the test.
1454 else
1455   ac_save_IFS=$IFS; IFS=$ac_path_separator
1456 ac_dummy="$PATH"
1457 for ac_dir in $ac_dummy; do
1458   IFS=$ac_save_IFS
1459   test -z "$ac_dir" && ac_dir=.
1460   $as_executable_p "$ac_dir/$ac_word" || continue
1461 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
1462 echo "$as_me:1462: found $ac_dir/$ac_word" >&5
1463 break
1464 done
1465
1466 fi
1467 fi
1468 CC=$ac_cv_prog_CC
1469 if test -n "$CC"; then
1470   echo "$as_me:1470: result: $CC" >&5
1471 echo "${ECHO_T}$CC" >&6
1472 else
1473   echo "$as_me:1473: result: no" >&5
1474 echo "${ECHO_T}no" >&6
1475 fi
1476
1477     test -n "$CC" && break
1478   done
1479 fi
1480 if test -z "$CC"; then
1481   ac_ct_CC=$CC
1482   for ac_prog in $cf_PROG_CC
1483 do
1484   # Extract the first word of "$ac_prog", so it can be a program name with args.
1485 set dummy $ac_prog; ac_word=$2
1486 echo "$as_me:1486: checking for $ac_word" >&5
1487 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1488 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1489   echo $ECHO_N "(cached) $ECHO_C" >&6
1490 else
1491   if test -n "$ac_ct_CC"; then
1492   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1493 else
1494   ac_save_IFS=$IFS; IFS=$ac_path_separator
1495 ac_dummy="$PATH"
1496 for ac_dir in $ac_dummy; do
1497   IFS=$ac_save_IFS
1498   test -z "$ac_dir" && ac_dir=.
1499   $as_executable_p "$ac_dir/$ac_word" || continue
1500 ac_cv_prog_ac_ct_CC="$ac_prog"
1501 echo "$as_me:1501: found $ac_dir/$ac_word" >&5
1502 break
1503 done
1504
1505 fi
1506 fi
1507 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1508 if test -n "$ac_ct_CC"; then
1509   echo "$as_me:1509: result: $ac_ct_CC" >&5
1510 echo "${ECHO_T}$ac_ct_CC" >&6
1511 else
1512   echo "$as_me:1512: result: no" >&5
1513 echo "${ECHO_T}no" >&6
1514 fi
1515
1516   test -n "$ac_ct_CC" && break
1517 done
1518
1519   CC=$ac_ct_CC
1520 fi
1521
1522 test -z "$CC" && { { echo "$as_me:1522: error: no acceptable cc found in \$PATH" >&5
1523 echo "$as_me: error: no acceptable cc found in \$PATH" >&2;}
1524    { (exit 1); exit 1; }; }
1525
1526 # Provide some information about the compiler.
1527 echo "$as_me:1527:" \
1528      "checking for C compiler version" >&5
1529 ac_compiler=`set X $ac_compile; echo $2`
1530 { (eval echo "$as_me:1530: \"$ac_compiler --version </dev/null >&5\"") >&5
1531   (eval $ac_compiler --version </dev/null >&5) 2>&5
1532   ac_status=$?
1533   echo "$as_me:1533: \$? = $ac_status" >&5
1534   (exit $ac_status); }
1535 { (eval echo "$as_me:1535: \"$ac_compiler -v </dev/null >&5\"") >&5
1536   (eval $ac_compiler -v </dev/null >&5) 2>&5
1537   ac_status=$?
1538   echo "$as_me:1538: \$? = $ac_status" >&5
1539   (exit $ac_status); }
1540 { (eval echo "$as_me:1540: \"$ac_compiler -V </dev/null >&5\"") >&5
1541   (eval $ac_compiler -V </dev/null >&5) 2>&5
1542   ac_status=$?
1543   echo "$as_me:1543: \$? = $ac_status" >&5
1544   (exit $ac_status); }
1545
1546 cat >conftest.$ac_ext <<_ACEOF
1547 #line 1547 "configure"
1548 #include "confdefs.h"
1549
1550 int
1551 main ()
1552 {
1553
1554   ;
1555   return 0;
1556 }
1557 _ACEOF
1558 ac_clean_files_save=$ac_clean_files
1559 ac_clean_files="$ac_clean_files a.out a.exe"
1560 # Try to create an executable without -o first, disregard a.out.
1561 # It will help us diagnose broken compilers, and finding out an intuition
1562 # of exeext.
1563 echo "$as_me:1563: checking for C compiler default output" >&5
1564 echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
1565 ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
1566 if { (eval echo "$as_me:1566: \"$ac_link_default\"") >&5
1567   (eval $ac_link_default) 2>&5
1568   ac_status=$?
1569   echo "$as_me:1569: \$? = $ac_status" >&5
1570   (exit $ac_status); }; then
1571   # Find the output, starting from the most likely.  This scheme is
1572 # not robust to junk in `.', hence go to wildcards (a.*) only as a last
1573 # resort.
1574 for ac_file in `ls a.exe conftest.exe 2>/dev/null;
1575                 ls a.out conftest 2>/dev/null;
1576                 ls a.* conftest.* 2>/dev/null`; do
1577   case $ac_file in
1578     *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1579     a.out ) # We found the default executable, but exeext='' is most
1580             # certainly right.
1581             break;;
1582     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1583           # FIXME: I believe we export ac_cv_exeext for Libtool --akim.
1584           export ac_cv_exeext
1585           break;;
1586     * ) break;;
1587   esac
1588 done
1589 else
1590   echo "$as_me: failed program was:" >&5
1591 cat conftest.$ac_ext >&5
1592 { { echo "$as_me:1592: error: C compiler cannot create executables" >&5
1593 echo "$as_me: error: C compiler cannot create executables" >&2;}
1594    { (exit 77); exit 77; }; }
1595 fi
1596
1597 ac_exeext=$ac_cv_exeext
1598 echo "$as_me:1598: result: $ac_file" >&5
1599 echo "${ECHO_T}$ac_file" >&6
1600
1601 # Check the compiler produces executables we can run.  If not, either
1602 # the compiler is broken, or we cross compile.
1603 echo "$as_me:1603: checking whether the C compiler works" >&5
1604 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
1605 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
1606 # If not cross compiling, check that we can run a simple program.
1607 if test "$cross_compiling" != yes; then
1608   if { ac_try='./$ac_file'
1609   { (eval echo "$as_me:1609: \"$ac_try\"") >&5
1610   (eval $ac_try) 2>&5
1611   ac_status=$?
1612   echo "$as_me:1612: \$? = $ac_status" >&5
1613   (exit $ac_status); }; }; then
1614     cross_compiling=no
1615   else
1616     if test "$cross_compiling" = maybe; then
1617         cross_compiling=yes
1618     else
1619         { { echo "$as_me:1619: error: cannot run C compiled programs.
1620 If you meant to cross compile, use \`--host'." >&5
1621 echo "$as_me: error: cannot run C compiled programs.
1622 If you meant to cross compile, use \`--host'." >&2;}
1623    { (exit 1); exit 1; }; }
1624     fi
1625   fi
1626 fi
1627 echo "$as_me:1627: result: yes" >&5
1628 echo "${ECHO_T}yes" >&6
1629
1630 rm -f a.out a.exe conftest$ac_cv_exeext
1631 ac_clean_files=$ac_clean_files_save
1632 # Check the compiler produces executables we can run.  If not, either
1633 # the compiler is broken, or we cross compile.
1634 echo "$as_me:1634: checking whether we are cross compiling" >&5
1635 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
1636 echo "$as_me:1636: result: $cross_compiling" >&5
1637 echo "${ECHO_T}$cross_compiling" >&6
1638
1639 echo "$as_me:1639: checking for executable suffix" >&5
1640 echo $ECHO_N "checking for executable suffix... $ECHO_C" >&6
1641 if { (eval echo "$as_me:1641: \"$ac_link\"") >&5
1642   (eval $ac_link) 2>&5
1643   ac_status=$?
1644   echo "$as_me:1644: \$? = $ac_status" >&5
1645   (exit $ac_status); }; then
1646   # If both `conftest.exe' and `conftest' are `present' (well, observable)
1647 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
1648 # work properly (i.e., refer to `conftest.exe'), while it won't with
1649 # `rm'.
1650 for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do
1651   case $ac_file in
1652     *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1653     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1654           export ac_cv_exeext
1655           break;;
1656     * ) break;;
1657   esac
1658 done
1659 else
1660   { { echo "$as_me:1660: error: cannot compute EXEEXT: cannot compile and link" >&5
1661 echo "$as_me: error: cannot compute EXEEXT: cannot compile and link" >&2;}
1662    { (exit 1); exit 1; }; }
1663 fi
1664
1665 rm -f conftest$ac_cv_exeext
1666 echo "$as_me:1666: result: $ac_cv_exeext" >&5
1667 echo "${ECHO_T}$ac_cv_exeext" >&6
1668
1669 rm -f conftest.$ac_ext
1670 EXEEXT=$ac_cv_exeext
1671 ac_exeext=$EXEEXT
1672 echo "$as_me:1672: checking for object suffix" >&5
1673 echo $ECHO_N "checking for object suffix... $ECHO_C" >&6
1674 if test "${ac_cv_objext+set}" = set; then
1675   echo $ECHO_N "(cached) $ECHO_C" >&6
1676 else
1677   cat >conftest.$ac_ext <<_ACEOF
1678 #line 1678 "configure"
1679 #include "confdefs.h"
1680
1681 int
1682 main ()
1683 {
1684
1685   ;
1686   return 0;
1687 }
1688 _ACEOF
1689 rm -f conftest.o conftest.obj
1690 if { (eval echo "$as_me:1690: \"$ac_compile\"") >&5
1691   (eval $ac_compile) 2>&5
1692   ac_status=$?
1693   echo "$as_me:1693: \$? = $ac_status" >&5
1694   (exit $ac_status); }; then
1695   for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
1696   case $ac_file in
1697     *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.map | *.inf ) ;;
1698     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
1699        break;;
1700   esac
1701 done
1702 else
1703   echo "$as_me: failed program was:" >&5
1704 cat conftest.$ac_ext >&5
1705 { { echo "$as_me:1705: error: cannot compute OBJEXT: cannot compile" >&5
1706 echo "$as_me: error: cannot compute OBJEXT: cannot compile" >&2;}
1707    { (exit 1); exit 1; }; }
1708 fi
1709
1710 rm -f conftest.$ac_cv_objext conftest.$ac_ext
1711 fi
1712 echo "$as_me:1712: result: $ac_cv_objext" >&5
1713 echo "${ECHO_T}$ac_cv_objext" >&6
1714 OBJEXT=$ac_cv_objext
1715 ac_objext=$OBJEXT
1716 echo "$as_me:1716: checking whether we are using the GNU C compiler" >&5
1717 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
1718 if test "${ac_cv_c_compiler_gnu+set}" = set; then
1719   echo $ECHO_N "(cached) $ECHO_C" >&6
1720 else
1721   cat >conftest.$ac_ext <<_ACEOF
1722 #line 1722 "configure"
1723 #include "confdefs.h"
1724
1725 int
1726 main ()
1727 {
1728 #ifndef __GNUC__
1729        choke me
1730 #endif
1731
1732   ;
1733   return 0;
1734 }
1735 _ACEOF
1736 rm -f conftest.$ac_objext
1737 if { (eval echo "$as_me:1737: \"$ac_compile\"") >&5
1738   (eval $ac_compile) 2>&5
1739   ac_status=$?
1740   echo "$as_me:1740: \$? = $ac_status" >&5
1741   (exit $ac_status); } &&
1742          { ac_try='test -s conftest.$ac_objext'
1743   { (eval echo "$as_me:1743: \"$ac_try\"") >&5
1744   (eval $ac_try) 2>&5
1745   ac_status=$?
1746   echo "$as_me:1746: \$? = $ac_status" >&5
1747   (exit $ac_status); }; }; then
1748   ac_compiler_gnu=yes
1749 else
1750   echo "$as_me: failed program was:" >&5
1751 cat conftest.$ac_ext >&5
1752 ac_compiler_gnu=no
1753 fi
1754 rm -f conftest.$ac_objext conftest.$ac_ext
1755 ac_cv_c_compiler_gnu=$ac_compiler_gnu
1756
1757 fi
1758 echo "$as_me:1758: result: $ac_cv_c_compiler_gnu" >&5
1759 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
1760 GCC=`test $ac_compiler_gnu = yes && echo yes`
1761 ac_test_CFLAGS=${CFLAGS+set}
1762 ac_save_CFLAGS=$CFLAGS
1763 CFLAGS="-g"
1764 echo "$as_me:1764: checking whether $CC accepts -g" >&5
1765 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
1766 if test "${ac_cv_prog_cc_g+set}" = set; then
1767   echo $ECHO_N "(cached) $ECHO_C" >&6
1768 else
1769   cat >conftest.$ac_ext <<_ACEOF
1770 #line 1770 "configure"
1771 #include "confdefs.h"
1772
1773 int
1774 main ()
1775 {
1776
1777   ;
1778   return 0;
1779 }
1780 _ACEOF
1781 rm -f conftest.$ac_objext
1782 if { (eval echo "$as_me:1782: \"$ac_compile\"") >&5
1783   (eval $ac_compile) 2>&5
1784   ac_status=$?
1785   echo "$as_me:1785: \$? = $ac_status" >&5
1786   (exit $ac_status); } &&
1787          { ac_try='test -s conftest.$ac_objext'
1788   { (eval echo "$as_me:1788: \"$ac_try\"") >&5
1789   (eval $ac_try) 2>&5
1790   ac_status=$?
1791   echo "$as_me:1791: \$? = $ac_status" >&5
1792   (exit $ac_status); }; }; then
1793   ac_cv_prog_cc_g=yes
1794 else
1795   echo "$as_me: failed program was:" >&5
1796 cat conftest.$ac_ext >&5
1797 ac_cv_prog_cc_g=no
1798 fi
1799 rm -f conftest.$ac_objext conftest.$ac_ext
1800 fi
1801 echo "$as_me:1801: result: $ac_cv_prog_cc_g" >&5
1802 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
1803 if test "$ac_test_CFLAGS" = set; then
1804   CFLAGS=$ac_save_CFLAGS
1805 elif test $ac_cv_prog_cc_g = yes; then
1806   if test "$GCC" = yes; then
1807     CFLAGS="-g -O2"
1808   else
1809     CFLAGS="-g"
1810   fi
1811 else
1812   if test "$GCC" = yes; then
1813     CFLAGS="-O2"
1814   else
1815     CFLAGS=
1816   fi
1817 fi
1818 # Some people use a C++ compiler to compile C.  Since we use `exit',
1819 # in C++ we need to declare it.  In case someone uses the same compiler
1820 # for both compiling C and C++ we need to have the C++ compiler decide
1821 # the declaration of exit, since it's the most demanding environment.
1822 cat >conftest.$ac_ext <<_ACEOF
1823 #ifndef __cplusplus
1824   choke me
1825 #endif
1826 _ACEOF
1827 rm -f conftest.$ac_objext
1828 if { (eval echo "$as_me:1828: \"$ac_compile\"") >&5
1829   (eval $ac_compile) 2>&5
1830   ac_status=$?
1831   echo "$as_me:1831: \$? = $ac_status" >&5
1832   (exit $ac_status); } &&
1833          { ac_try='test -s conftest.$ac_objext'
1834   { (eval echo "$as_me:1834: \"$ac_try\"") >&5
1835   (eval $ac_try) 2>&5
1836   ac_status=$?
1837   echo "$as_me:1837: \$? = $ac_status" >&5
1838   (exit $ac_status); }; }; then
1839   for ac_declaration in \
1840    ''\
1841    '#include <stdlib.h>' \
1842    'extern "C" void std::exit (int) throw (); using std::exit;' \
1843    'extern "C" void std::exit (int); using std::exit;' \
1844    'extern "C" void exit (int) throw ();' \
1845    'extern "C" void exit (int);' \
1846    'void exit (int);'
1847 do
1848   cat >conftest.$ac_ext <<_ACEOF
1849 #line 1849 "configure"
1850 #include "confdefs.h"
1851 #include <stdlib.h>
1852 $ac_declaration
1853 int
1854 main ()
1855 {
1856 exit (42);
1857   ;
1858   return 0;
1859 }
1860 _ACEOF
1861 rm -f conftest.$ac_objext
1862 if { (eval echo "$as_me:1862: \"$ac_compile\"") >&5
1863   (eval $ac_compile) 2>&5
1864   ac_status=$?
1865   echo "$as_me:1865: \$? = $ac_status" >&5
1866   (exit $ac_status); } &&
1867          { ac_try='test -s conftest.$ac_objext'
1868   { (eval echo "$as_me:1868: \"$ac_try\"") >&5
1869   (eval $ac_try) 2>&5
1870   ac_status=$?
1871   echo "$as_me:1871: \$? = $ac_status" >&5
1872   (exit $ac_status); }; }; then
1873   :
1874 else
1875   echo "$as_me: failed program was:" >&5
1876 cat conftest.$ac_ext >&5
1877 continue
1878 fi
1879 rm -f conftest.$ac_objext conftest.$ac_ext
1880   cat >conftest.$ac_ext <<_ACEOF
1881 #line 1881 "configure"
1882 #include "confdefs.h"
1883 $ac_declaration
1884 int
1885 main ()
1886 {
1887 exit (42);
1888   ;
1889   return 0;
1890 }
1891 _ACEOF
1892 rm -f conftest.$ac_objext
1893 if { (eval echo "$as_me:1893: \"$ac_compile\"") >&5
1894   (eval $ac_compile) 2>&5
1895   ac_status=$?
1896   echo "$as_me:1896: \$? = $ac_status" >&5
1897   (exit $ac_status); } &&
1898          { ac_try='test -s conftest.$ac_objext'
1899   { (eval echo "$as_me:1899: \"$ac_try\"") >&5
1900   (eval $ac_try) 2>&5
1901   ac_status=$?
1902   echo "$as_me:1902: \$? = $ac_status" >&5
1903   (exit $ac_status); }; }; then
1904   break
1905 else
1906   echo "$as_me: failed program was:" >&5
1907 cat conftest.$ac_ext >&5
1908 fi
1909 rm -f conftest.$ac_objext conftest.$ac_ext
1910 done
1911 rm -rf conftest*
1912 if test -n "$ac_declaration"; then
1913   echo '#ifdef __cplusplus' >>confdefs.h
1914   echo $ac_declaration      >>confdefs.h
1915   echo '#endif'             >>confdefs.h
1916 fi
1917
1918 else
1919   echo "$as_me: failed program was:" >&5
1920 cat conftest.$ac_ext >&5
1921 fi
1922 rm -f conftest.$ac_objext conftest.$ac_ext
1923 ac_ext=c
1924 ac_cpp='$CPP $CPPFLAGS'
1925 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1926 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1927 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1928 ac_main_return=return
1929
1930 GCC_VERSION=none
1931 if test "$GCC" = yes ; then
1932         echo "$as_me:1932: checking version of $CC" >&5
1933 echo $ECHO_N "checking version of $CC... $ECHO_C" >&6
1934         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.].*//'`"
1935         test -z "$GCC_VERSION" && GCC_VERSION=unknown
1936         echo "$as_me:1936: result: $GCC_VERSION" >&5
1937 echo "${ECHO_T}$GCC_VERSION" >&6
1938 fi
1939
1940 echo "$as_me:1940: checking for $CC option to accept ANSI C" >&5
1941 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
1942 if test "${ac_cv_prog_cc_stdc+set}" = set; then
1943   echo $ECHO_N "(cached) $ECHO_C" >&6
1944 else
1945   ac_cv_prog_cc_stdc=no
1946 ac_save_CC=$CC
1947 cat >conftest.$ac_ext <<_ACEOF
1948 #line 1948 "configure"
1949 #include "confdefs.h"
1950 #include <stdarg.h>
1951 #include <stdio.h>
1952 #include <sys/types.h>
1953 #include <sys/stat.h>
1954 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
1955 struct buf { int x; };
1956 FILE * (*rcsopen) (struct buf *, struct stat *, int);
1957 static char *e (p, i)
1958      char **p;
1959      int i;
1960 {
1961   return p[i];
1962 }
1963 static char *f (char * (*g) (char **, int), char **p, ...)
1964 {
1965   char *s;
1966   va_list v;
1967   va_start (v,p);
1968   s = g (p, va_arg (v,int));
1969   va_end (v);
1970   return s;
1971 }
1972 int test (int i, double x);
1973 struct s1 {int (*f) (int a);};
1974 struct s2 {int (*f) (double a);};
1975 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
1976 int argc;
1977 char **argv;
1978 int
1979 main ()
1980 {
1981 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
1982   ;
1983   return 0;
1984 }
1985 _ACEOF
1986 # Don't try gcc -ansi; that turns off useful extensions and
1987 # breaks some systems' header files.
1988 # AIX                   -qlanglvl=ansi
1989 # Ultrix and OSF/1      -std1
1990 # HP-UX 10.20 and later -Ae
1991 # HP-UX older versions  -Aa -D_HPUX_SOURCE
1992 # SVR4                  -Xc -D__EXTENSIONS__
1993 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
1994 do
1995   CC="$ac_save_CC $ac_arg"
1996   rm -f conftest.$ac_objext
1997 if { (eval echo "$as_me:1997: \"$ac_compile\"") >&5
1998   (eval $ac_compile) 2>&5
1999   ac_status=$?
2000   echo "$as_me:2000: \$? = $ac_status" >&5
2001   (exit $ac_status); } &&
2002          { ac_try='test -s conftest.$ac_objext'
2003   { (eval echo "$as_me:2003: \"$ac_try\"") >&5
2004   (eval $ac_try) 2>&5
2005   ac_status=$?
2006   echo "$as_me:2006: \$? = $ac_status" >&5
2007   (exit $ac_status); }; }; then
2008   ac_cv_prog_cc_stdc=$ac_arg
2009 break
2010 else
2011   echo "$as_me: failed program was:" >&5
2012 cat conftest.$ac_ext >&5
2013 fi
2014 rm -f conftest.$ac_objext
2015 done
2016 rm -f conftest.$ac_ext conftest.$ac_objext
2017 CC=$ac_save_CC
2018
2019 fi
2020
2021 case "x$ac_cv_prog_cc_stdc" in
2022   x|xno)
2023     echo "$as_me:2023: result: none needed" >&5
2024 echo "${ECHO_T}none needed" >&6 ;;
2025   *)
2026     echo "$as_me:2026: result: $ac_cv_prog_cc_stdc" >&5
2027 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
2028     CC="$CC $ac_cv_prog_cc_stdc" ;;
2029 esac
2030
2031 # This should have been defined by AC_PROG_CC
2032 : ${CC:=cc}
2033
2034 echo "$as_me:2034: checking \$CC variable" >&5
2035 echo $ECHO_N "checking \$CC variable... $ECHO_C" >&6
2036 case "$CC" in #(vi
2037 *[\ \   ]-[IUD]*)
2038         echo "$as_me:2038: result: broken" >&5
2039 echo "${ECHO_T}broken" >&6
2040         { echo "$as_me:2040: WARNING: your environment misuses the CC variable to hold CFLAGS/CPPFLAGS options" >&5
2041 echo "$as_me: WARNING: your environment misuses the CC variable to hold CFLAGS/CPPFLAGS options" >&2;}
2042         # humor him...
2043         cf_flags=`echo "$CC" | sed -e 's/^[^    ]*[     ]//'`
2044         CC=`echo "$CC" | sed -e 's/[    ].*//'`
2045
2046 cf_fix_cppflags=no
2047 cf_new_cflags=
2048 cf_new_cppflags=
2049 cf_new_extra_cppflags=
2050
2051 for cf_add_cflags in $cf_flags
2052 do
2053 case $cf_fix_cppflags in
2054 no)
2055         case $cf_add_cflags in #(vi
2056         -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
2057                 case $cf_add_cflags in
2058                 -D*)
2059                         cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
2060
2061                         test "${cf_add_cflags}" != "${cf_tst_cflags}" \
2062                                 && test -z "${cf_tst_cflags}" \
2063                                 && cf_fix_cppflags=yes
2064
2065                         if test $cf_fix_cppflags = yes ; then
2066                                 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2067                                 continue
2068                         elif test "${cf_tst_cflags}" = "\"'" ; then
2069                                 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2070                                 continue
2071                         fi
2072                         ;;
2073                 esac
2074                 case "$CPPFLAGS" in
2075                 *$cf_add_cflags) #(vi
2076                         ;;
2077                 *) #(vi
2078                         case $cf_add_cflags in #(vi
2079                         -D*)
2080                                 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
2081
2082 CPPFLAGS=`echo "$CPPFLAGS" | \
2083         sed     -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^    ]*\)\?[         ]/ /g' \
2084                 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^    ]*\)\?$//g'`
2085
2086                                 ;;
2087                         esac
2088                         cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
2089                         ;;
2090                 esac
2091                 ;;
2092         *)
2093                 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
2094                 ;;
2095         esac
2096         ;;
2097 yes)
2098         cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2099
2100         cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
2101
2102         test "${cf_add_cflags}" != "${cf_tst_cflags}" \
2103                 && test -z "${cf_tst_cflags}" \
2104                 && cf_fix_cppflags=no
2105         ;;
2106 esac
2107 done
2108
2109 if test -n "$cf_new_cflags" ; then
2110
2111         CFLAGS="$CFLAGS $cf_new_cflags"
2112 fi
2113
2114 if test -n "$cf_new_cppflags" ; then
2115
2116         CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
2117 fi
2118
2119 if test -n "$cf_new_extra_cppflags" ; then
2120
2121         EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
2122 fi
2123
2124         ;;
2125 *)
2126         echo "$as_me:2126: result: ok" >&5
2127 echo "${ECHO_T}ok" >&6
2128         ;;
2129 esac
2130
2131 ac_ext=c
2132 ac_cpp='$CPP $CPPFLAGS'
2133 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2134 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2135 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2136 ac_main_return=return
2137 echo "$as_me:2137: checking how to run the C preprocessor" >&5
2138 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
2139 # On Suns, sometimes $CPP names a directory.
2140 if test -n "$CPP" && test -d "$CPP"; then
2141   CPP=
2142 fi
2143 if test -z "$CPP"; then
2144   if test "${ac_cv_prog_CPP+set}" = set; then
2145   echo $ECHO_N "(cached) $ECHO_C" >&6
2146 else
2147       # Double quotes because CPP needs to be expanded
2148     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
2149     do
2150       ac_preproc_ok=false
2151 for ac_c_preproc_warn_flag in '' yes
2152 do
2153   # Use a header file that comes with gcc, so configuring glibc
2154   # with a fresh cross-compiler works.
2155   # On the NeXT, cc -E runs the code through the compiler's parser,
2156   # not just through cpp. "Syntax error" is here to catch this case.
2157   cat >conftest.$ac_ext <<_ACEOF
2158 #line 2158 "configure"
2159 #include "confdefs.h"
2160 #include <assert.h>
2161                      Syntax error
2162 _ACEOF
2163 if { (eval echo "$as_me:2163: \"$ac_cpp conftest.$ac_ext\"") >&5
2164   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2165   ac_status=$?
2166   egrep -v '^ *\+' conftest.er1 >conftest.err
2167   rm -f conftest.er1
2168   cat conftest.err >&5
2169   echo "$as_me:2169: \$? = $ac_status" >&5
2170   (exit $ac_status); } >/dev/null; then
2171   if test -s conftest.err; then
2172     ac_cpp_err=$ac_c_preproc_warn_flag
2173   else
2174     ac_cpp_err=
2175   fi
2176 else
2177   ac_cpp_err=yes
2178 fi
2179 if test -z "$ac_cpp_err"; then
2180   :
2181 else
2182   echo "$as_me: failed program was:" >&5
2183   cat conftest.$ac_ext >&5
2184   # Broken: fails on valid input.
2185 continue
2186 fi
2187 rm -f conftest.err conftest.$ac_ext
2188
2189   # OK, works on sane cases.  Now check whether non-existent headers
2190   # can be detected and how.
2191   cat >conftest.$ac_ext <<_ACEOF
2192 #line 2192 "configure"
2193 #include "confdefs.h"
2194 #include <ac_nonexistent.h>
2195 _ACEOF
2196 if { (eval echo "$as_me:2196: \"$ac_cpp conftest.$ac_ext\"") >&5
2197   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2198   ac_status=$?
2199   egrep -v '^ *\+' conftest.er1 >conftest.err
2200   rm -f conftest.er1
2201   cat conftest.err >&5
2202   echo "$as_me:2202: \$? = $ac_status" >&5
2203   (exit $ac_status); } >/dev/null; then
2204   if test -s conftest.err; then
2205     ac_cpp_err=$ac_c_preproc_warn_flag
2206   else
2207     ac_cpp_err=
2208   fi
2209 else
2210   ac_cpp_err=yes
2211 fi
2212 if test -z "$ac_cpp_err"; then
2213   # Broken: success on invalid input.
2214 continue
2215 else
2216   echo "$as_me: failed program was:" >&5
2217   cat conftest.$ac_ext >&5
2218   # Passes both tests.
2219 ac_preproc_ok=:
2220 break
2221 fi
2222 rm -f conftest.err conftest.$ac_ext
2223
2224 done
2225 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2226 rm -f conftest.err conftest.$ac_ext
2227 if $ac_preproc_ok; then
2228   break
2229 fi
2230
2231     done
2232     ac_cv_prog_CPP=$CPP
2233
2234 fi
2235   CPP=$ac_cv_prog_CPP
2236 else
2237   ac_cv_prog_CPP=$CPP
2238 fi
2239 echo "$as_me:2239: result: $CPP" >&5
2240 echo "${ECHO_T}$CPP" >&6
2241 ac_preproc_ok=false
2242 for ac_c_preproc_warn_flag in '' yes
2243 do
2244   # Use a header file that comes with gcc, so configuring glibc
2245   # with a fresh cross-compiler works.
2246   # On the NeXT, cc -E runs the code through the compiler's parser,
2247   # not just through cpp. "Syntax error" is here to catch this case.
2248   cat >conftest.$ac_ext <<_ACEOF
2249 #line 2249 "configure"
2250 #include "confdefs.h"
2251 #include <assert.h>
2252                      Syntax error
2253 _ACEOF
2254 if { (eval echo "$as_me:2254: \"$ac_cpp conftest.$ac_ext\"") >&5
2255   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2256   ac_status=$?
2257   egrep -v '^ *\+' conftest.er1 >conftest.err
2258   rm -f conftest.er1
2259   cat conftest.err >&5
2260   echo "$as_me:2260: \$? = $ac_status" >&5
2261   (exit $ac_status); } >/dev/null; then
2262   if test -s conftest.err; then
2263     ac_cpp_err=$ac_c_preproc_warn_flag
2264   else
2265     ac_cpp_err=
2266   fi
2267 else
2268   ac_cpp_err=yes
2269 fi
2270 if test -z "$ac_cpp_err"; then
2271   :
2272 else
2273   echo "$as_me: failed program was:" >&5
2274   cat conftest.$ac_ext >&5
2275   # Broken: fails on valid input.
2276 continue
2277 fi
2278 rm -f conftest.err conftest.$ac_ext
2279
2280   # OK, works on sane cases.  Now check whether non-existent headers
2281   # can be detected and how.
2282   cat >conftest.$ac_ext <<_ACEOF
2283 #line 2283 "configure"
2284 #include "confdefs.h"
2285 #include <ac_nonexistent.h>
2286 _ACEOF
2287 if { (eval echo "$as_me:2287: \"$ac_cpp conftest.$ac_ext\"") >&5
2288   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2289   ac_status=$?
2290   egrep -v '^ *\+' conftest.er1 >conftest.err
2291   rm -f conftest.er1
2292   cat conftest.err >&5
2293   echo "$as_me:2293: \$? = $ac_status" >&5
2294   (exit $ac_status); } >/dev/null; then
2295   if test -s conftest.err; then
2296     ac_cpp_err=$ac_c_preproc_warn_flag
2297   else
2298     ac_cpp_err=
2299   fi
2300 else
2301   ac_cpp_err=yes
2302 fi
2303 if test -z "$ac_cpp_err"; then
2304   # Broken: success on invalid input.
2305 continue
2306 else
2307   echo "$as_me: failed program was:" >&5
2308   cat conftest.$ac_ext >&5
2309   # Passes both tests.
2310 ac_preproc_ok=:
2311 break
2312 fi
2313 rm -f conftest.err conftest.$ac_ext
2314
2315 done
2316 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2317 rm -f conftest.err conftest.$ac_ext
2318 if $ac_preproc_ok; then
2319   :
2320 else
2321   { { echo "$as_me:2321: error: C preprocessor \"$CPP\" fails sanity check" >&5
2322 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;}
2323    { (exit 1); exit 1; }; }
2324 fi
2325
2326 ac_ext=c
2327 ac_cpp='$CPP $CPPFLAGS'
2328 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2329 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2330 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2331 ac_main_return=return
2332
2333 if test $ac_cv_c_compiler_gnu = yes; then
2334     echo "$as_me:2334: checking whether $CC needs -traditional" >&5
2335 echo $ECHO_N "checking whether $CC needs -traditional... $ECHO_C" >&6
2336 if test "${ac_cv_prog_gcc_traditional+set}" = set; then
2337   echo $ECHO_N "(cached) $ECHO_C" >&6
2338 else
2339     ac_pattern="Autoconf.*'x'"
2340   cat >conftest.$ac_ext <<_ACEOF
2341 #line 2341 "configure"
2342 #include "confdefs.h"
2343 #include <sgtty.h>
2344 int Autoconf = TIOCGETP;
2345 _ACEOF
2346 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2347   egrep "$ac_pattern" >/dev/null 2>&1; then
2348   ac_cv_prog_gcc_traditional=yes
2349 else
2350   ac_cv_prog_gcc_traditional=no
2351 fi
2352 rm -rf conftest*
2353
2354   if test $ac_cv_prog_gcc_traditional = no; then
2355     cat >conftest.$ac_ext <<_ACEOF
2356 #line 2356 "configure"
2357 #include "confdefs.h"
2358 #include <termio.h>
2359 int Autoconf = TCGETA;
2360 _ACEOF
2361 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2362   egrep "$ac_pattern" >/dev/null 2>&1; then
2363   ac_cv_prog_gcc_traditional=yes
2364 fi
2365 rm -rf conftest*
2366
2367   fi
2368 fi
2369 echo "$as_me:2369: result: $ac_cv_prog_gcc_traditional" >&5
2370 echo "${ECHO_T}$ac_cv_prog_gcc_traditional" >&6
2371   if test $ac_cv_prog_gcc_traditional = yes; then
2372     CC="$CC -traditional"
2373   fi
2374 fi
2375
2376 echo "$as_me:2376: checking whether $CC understands -c and -o together" >&5
2377 echo $ECHO_N "checking whether $CC understands -c and -o together... $ECHO_C" >&6
2378 if test "${cf_cv_prog_CC_c_o+set}" = set; then
2379   echo $ECHO_N "(cached) $ECHO_C" >&6
2380 else
2381
2382 cat > conftest.$ac_ext <<CF_EOF
2383 #include <stdio.h>
2384 int main()
2385 {
2386         ${cf_cv_main_return:-return}(0);
2387 }
2388 CF_EOF
2389 # We do the test twice because some compilers refuse to overwrite an
2390 # existing .o file with -o, though they will create one.
2391 ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
2392 if { (eval echo "$as_me:2392: \"$ac_try\"") >&5
2393   (eval $ac_try) 2>&5
2394   ac_status=$?
2395   echo "$as_me:2395: \$? = $ac_status" >&5
2396   (exit $ac_status); } &&
2397   test -f conftest2.$ac_objext && { (eval echo "$as_me:2397: \"$ac_try\"") >&5
2398   (eval $ac_try) 2>&5
2399   ac_status=$?
2400   echo "$as_me:2400: \$? = $ac_status" >&5
2401   (exit $ac_status); };
2402 then
2403   eval cf_cv_prog_CC_c_o=yes
2404 else
2405   eval cf_cv_prog_CC_c_o=no
2406 fi
2407 rm -rf conftest*
2408
2409 fi
2410 if test $cf_cv_prog_CC_c_o = yes; then
2411   echo "$as_me:2411: result: yes" >&5
2412 echo "${ECHO_T}yes" >&6
2413 else
2414   echo "$as_me:2414: result: no" >&5
2415 echo "${ECHO_T}no" >&6
2416 fi
2417
2418 if test "$cross_compiling" = yes ; then
2419   LDCONFIG=:
2420 else
2421 case "$cf_cv_system_name" in #(vi
2422 dragonfly*|mirbsd*|freebsd*) #(vi
2423   test -z "$LDCONFIG" && LDCONFIG="/sbin/ldconfig -R"
2424   ;;
2425 *) LDPATH=$PATH:/sbin:/usr/sbin
2426   # Extract the first word of "ldconfig", so it can be a program name with args.
2427 set dummy ldconfig; ac_word=$2
2428 echo "$as_me:2428: checking for $ac_word" >&5
2429 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2430 if test "${ac_cv_path_LDCONFIG+set}" = set; then
2431   echo $ECHO_N "(cached) $ECHO_C" >&6
2432 else
2433   case $LDCONFIG in
2434   [\\/]* | ?:[\\/]*)
2435   ac_cv_path_LDCONFIG="$LDCONFIG" # Let the user override the test with a path.
2436   ;;
2437   *)
2438   ac_save_IFS=$IFS; IFS=$ac_path_separator
2439 ac_dummy="$LDPATH"
2440 for ac_dir in $ac_dummy; do
2441   IFS=$ac_save_IFS
2442   test -z "$ac_dir" && ac_dir=.
2443   if $as_executable_p "$ac_dir/$ac_word"; then
2444    ac_cv_path_LDCONFIG="$ac_dir/$ac_word"
2445    echo "$as_me:2445: found $ac_dir/$ac_word" >&5
2446    break
2447 fi
2448 done
2449
2450   ;;
2451 esac
2452 fi
2453 LDCONFIG=$ac_cv_path_LDCONFIG
2454
2455 if test -n "$LDCONFIG"; then
2456   echo "$as_me:2456: result: $LDCONFIG" >&5
2457 echo "${ECHO_T}$LDCONFIG" >&6
2458 else
2459   echo "$as_me:2459: result: no" >&5
2460 echo "${ECHO_T}no" >&6
2461 fi
2462
2463   ;;
2464 esac
2465 fi
2466
2467 echo "$as_me:2467: checking if you want to ensure bool is consistent with C++" >&5
2468 echo $ECHO_N "checking if you want to ensure bool is consistent with C++... $ECHO_C" >&6
2469
2470 # Check whether --with-cxx or --without-cxx was given.
2471 if test "${with_cxx+set}" = set; then
2472   withval="$with_cxx"
2473   cf_with_cxx=$withval
2474 else
2475   cf_with_cxx=yes
2476 fi;
2477 echo "$as_me:2477: result: $cf_with_cxx" >&5
2478 echo "${ECHO_T}$cf_with_cxx" >&6
2479 if test "X$cf_with_cxx" = Xno ; then
2480         CXX=""
2481         GXX=""
2482 else
2483         # with autoconf 2.13, we can change the error to a warning:
2484                 ac_ext=cc
2485 ac_cpp='$CXXCPP $CPPFLAGS'
2486 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2487 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2488 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
2489 ac_main_return=return
2490 if test -n "$ac_tool_prefix"; then
2491   for ac_prog in $CCC g++ c++ gpp aCC CC cxx cc++ cl FCC KCC RCC xlC_r xlC
2492   do
2493     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
2494 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
2495 echo "$as_me:2495: checking for $ac_word" >&5
2496 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2497 if test "${ac_cv_prog_CXX+set}" = set; then
2498   echo $ECHO_N "(cached) $ECHO_C" >&6
2499 else
2500   if test -n "$CXX"; then
2501   ac_cv_prog_CXX="$CXX" # Let the user override the test.
2502 else
2503   ac_save_IFS=$IFS; IFS=$ac_path_separator
2504 ac_dummy="$PATH"
2505 for ac_dir in $ac_dummy; do
2506   IFS=$ac_save_IFS
2507   test -z "$ac_dir" && ac_dir=.
2508   $as_executable_p "$ac_dir/$ac_word" || continue
2509 ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
2510 echo "$as_me:2510: found $ac_dir/$ac_word" >&5
2511 break
2512 done
2513
2514 fi
2515 fi
2516 CXX=$ac_cv_prog_CXX
2517 if test -n "$CXX"; then
2518   echo "$as_me:2518: result: $CXX" >&5
2519 echo "${ECHO_T}$CXX" >&6
2520 else
2521   echo "$as_me:2521: result: no" >&5
2522 echo "${ECHO_T}no" >&6
2523 fi
2524
2525     test -n "$CXX" && break
2526   done
2527 fi
2528 if test -z "$CXX"; then
2529   ac_ct_CXX=$CXX
2530   for ac_prog in $CCC g++ c++ gpp aCC CC cxx cc++ cl FCC KCC RCC xlC_r xlC
2531 do
2532   # Extract the first word of "$ac_prog", so it can be a program name with args.
2533 set dummy $ac_prog; ac_word=$2
2534 echo "$as_me:2534: checking for $ac_word" >&5
2535 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2536 if test "${ac_cv_prog_ac_ct_CXX+set}" = set; then
2537   echo $ECHO_N "(cached) $ECHO_C" >&6
2538 else
2539   if test -n "$ac_ct_CXX"; then
2540   ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
2541 else
2542   ac_save_IFS=$IFS; IFS=$ac_path_separator
2543 ac_dummy="$PATH"
2544 for ac_dir in $ac_dummy; do
2545   IFS=$ac_save_IFS
2546   test -z "$ac_dir" && ac_dir=.
2547   $as_executable_p "$ac_dir/$ac_word" || continue
2548 ac_cv_prog_ac_ct_CXX="$ac_prog"
2549 echo "$as_me:2549: found $ac_dir/$ac_word" >&5
2550 break
2551 done
2552
2553 fi
2554 fi
2555 ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
2556 if test -n "$ac_ct_CXX"; then
2557   echo "$as_me:2557: result: $ac_ct_CXX" >&5
2558 echo "${ECHO_T}$ac_ct_CXX" >&6
2559 else
2560   echo "$as_me:2560: result: no" >&5
2561 echo "${ECHO_T}no" >&6
2562 fi
2563
2564   test -n "$ac_ct_CXX" && break
2565 done
2566 test -n "$ac_ct_CXX" || ac_ct_CXX="g++"
2567
2568   CXX=$ac_ct_CXX
2569 fi
2570
2571 # Provide some information about the compiler.
2572 echo "$as_me:2572:" \
2573      "checking for C++ compiler version" >&5
2574 ac_compiler=`set X $ac_compile; echo $2`
2575 { (eval echo "$as_me:2575: \"$ac_compiler --version </dev/null >&5\"") >&5
2576   (eval $ac_compiler --version </dev/null >&5) 2>&5
2577   ac_status=$?
2578   echo "$as_me:2578: \$? = $ac_status" >&5
2579   (exit $ac_status); }
2580 { (eval echo "$as_me:2580: \"$ac_compiler -v </dev/null >&5\"") >&5
2581   (eval $ac_compiler -v </dev/null >&5) 2>&5
2582   ac_status=$?
2583   echo "$as_me:2583: \$? = $ac_status" >&5
2584   (exit $ac_status); }
2585 { (eval echo "$as_me:2585: \"$ac_compiler -V </dev/null >&5\"") >&5
2586   (eval $ac_compiler -V </dev/null >&5) 2>&5
2587   ac_status=$?
2588   echo "$as_me:2588: \$? = $ac_status" >&5
2589   (exit $ac_status); }
2590
2591 echo "$as_me:2591: checking whether we are using the GNU C++ compiler" >&5
2592 echo $ECHO_N "checking whether we are using the GNU C++ compiler... $ECHO_C" >&6
2593 if test "${ac_cv_cxx_compiler_gnu+set}" = set; then
2594   echo $ECHO_N "(cached) $ECHO_C" >&6
2595 else
2596   cat >conftest.$ac_ext <<_ACEOF
2597 #line 2597 "configure"
2598 #include "confdefs.h"
2599
2600 int
2601 main ()
2602 {
2603 #ifndef __GNUC__
2604        choke me
2605 #endif
2606
2607   ;
2608   return 0;
2609 }
2610 _ACEOF
2611 rm -f conftest.$ac_objext
2612 if { (eval echo "$as_me:2612: \"$ac_compile\"") >&5
2613   (eval $ac_compile) 2>&5
2614   ac_status=$?
2615   echo "$as_me:2615: \$? = $ac_status" >&5
2616   (exit $ac_status); } &&
2617          { ac_try='test -s conftest.$ac_objext'
2618   { (eval echo "$as_me:2618: \"$ac_try\"") >&5
2619   (eval $ac_try) 2>&5
2620   ac_status=$?
2621   echo "$as_me:2621: \$? = $ac_status" >&5
2622   (exit $ac_status); }; }; then
2623   ac_compiler_gnu=yes
2624 else
2625   echo "$as_me: failed program was:" >&5
2626 cat conftest.$ac_ext >&5
2627 ac_compiler_gnu=no
2628 fi
2629 rm -f conftest.$ac_objext conftest.$ac_ext
2630 ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
2631
2632 fi
2633 echo "$as_me:2633: result: $ac_cv_cxx_compiler_gnu" >&5
2634 echo "${ECHO_T}$ac_cv_cxx_compiler_gnu" >&6
2635 GXX=`test $ac_compiler_gnu = yes && echo yes`
2636 ac_test_CXXFLAGS=${CXXFLAGS+set}
2637 ac_save_CXXFLAGS=$CXXFLAGS
2638 CXXFLAGS="-g"
2639 echo "$as_me:2639: checking whether $CXX accepts -g" >&5
2640 echo $ECHO_N "checking whether $CXX accepts -g... $ECHO_C" >&6
2641 if test "${ac_cv_prog_cxx_g+set}" = set; then
2642   echo $ECHO_N "(cached) $ECHO_C" >&6
2643 else
2644   cat >conftest.$ac_ext <<_ACEOF
2645 #line 2645 "configure"
2646 #include "confdefs.h"
2647
2648 int
2649 main ()
2650 {
2651
2652   ;
2653   return 0;
2654 }
2655 _ACEOF
2656 rm -f conftest.$ac_objext
2657 if { (eval echo "$as_me:2657: \"$ac_compile\"") >&5
2658   (eval $ac_compile) 2>&5
2659   ac_status=$?
2660   echo "$as_me:2660: \$? = $ac_status" >&5
2661   (exit $ac_status); } &&
2662          { ac_try='test -s conftest.$ac_objext'
2663   { (eval echo "$as_me:2663: \"$ac_try\"") >&5
2664   (eval $ac_try) 2>&5
2665   ac_status=$?
2666   echo "$as_me:2666: \$? = $ac_status" >&5
2667   (exit $ac_status); }; }; then
2668   ac_cv_prog_cxx_g=yes
2669 else
2670   echo "$as_me: failed program was:" >&5
2671 cat conftest.$ac_ext >&5
2672 ac_cv_prog_cxx_g=no
2673 fi
2674 rm -f conftest.$ac_objext conftest.$ac_ext
2675 fi
2676 echo "$as_me:2676: result: $ac_cv_prog_cxx_g" >&5
2677 echo "${ECHO_T}$ac_cv_prog_cxx_g" >&6
2678 if test "$ac_test_CXXFLAGS" = set; then
2679   CXXFLAGS=$ac_save_CXXFLAGS
2680 elif test $ac_cv_prog_cxx_g = yes; then
2681   if test "$GXX" = yes; then
2682     CXXFLAGS="-g -O2"
2683   else
2684     CXXFLAGS="-g"
2685   fi
2686 else
2687   if test "$GXX" = yes; then
2688     CXXFLAGS="-O2"
2689   else
2690     CXXFLAGS=
2691   fi
2692 fi
2693 for ac_declaration in \
2694    ''\
2695    '#include <stdlib.h>' \
2696    'extern "C" void std::exit (int) throw (); using std::exit;' \
2697    'extern "C" void std::exit (int); using std::exit;' \
2698    'extern "C" void exit (int) throw ();' \
2699    'extern "C" void exit (int);' \
2700    'void exit (int);'
2701 do
2702   cat >conftest.$ac_ext <<_ACEOF
2703 #line 2703 "configure"
2704 #include "confdefs.h"
2705 #include <stdlib.h>
2706 $ac_declaration
2707 int
2708 main ()
2709 {
2710 exit (42);
2711   ;
2712   return 0;
2713 }
2714 _ACEOF
2715 rm -f conftest.$ac_objext
2716 if { (eval echo "$as_me:2716: \"$ac_compile\"") >&5
2717   (eval $ac_compile) 2>&5
2718   ac_status=$?
2719   echo "$as_me:2719: \$? = $ac_status" >&5
2720   (exit $ac_status); } &&
2721          { ac_try='test -s conftest.$ac_objext'
2722   { (eval echo "$as_me:2722: \"$ac_try\"") >&5
2723   (eval $ac_try) 2>&5
2724   ac_status=$?
2725   echo "$as_me:2725: \$? = $ac_status" >&5
2726   (exit $ac_status); }; }; then
2727   :
2728 else
2729   echo "$as_me: failed program was:" >&5
2730 cat conftest.$ac_ext >&5
2731 continue
2732 fi
2733 rm -f conftest.$ac_objext conftest.$ac_ext
2734   cat >conftest.$ac_ext <<_ACEOF
2735 #line 2735 "configure"
2736 #include "confdefs.h"
2737 $ac_declaration
2738 int
2739 main ()
2740 {
2741 exit (42);
2742   ;
2743   return 0;
2744 }
2745 _ACEOF
2746 rm -f conftest.$ac_objext
2747 if { (eval echo "$as_me:2747: \"$ac_compile\"") >&5
2748   (eval $ac_compile) 2>&5
2749   ac_status=$?
2750   echo "$as_me:2750: \$? = $ac_status" >&5
2751   (exit $ac_status); } &&
2752          { ac_try='test -s conftest.$ac_objext'
2753   { (eval echo "$as_me:2753: \"$ac_try\"") >&5
2754   (eval $ac_try) 2>&5
2755   ac_status=$?
2756   echo "$as_me:2756: \$? = $ac_status" >&5
2757   (exit $ac_status); }; }; then
2758   break
2759 else
2760   echo "$as_me: failed program was:" >&5
2761 cat conftest.$ac_ext >&5
2762 fi
2763 rm -f conftest.$ac_objext conftest.$ac_ext
2764 done
2765 rm -rf conftest*
2766 if test -n "$ac_declaration"; then
2767   echo '#ifdef __cplusplus' >>confdefs.h
2768   echo $ac_declaration      >>confdefs.h
2769   echo '#endif'             >>confdefs.h
2770 fi
2771
2772 ac_ext=c
2773 ac_cpp='$CPP $CPPFLAGS'
2774 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2775 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2776 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2777 ac_main_return=return
2778
2779                 # autoconf 2.5x removed the error (hardcoding it to g++, or just blank)
2780         if test "$CXX" = "g++" ; then
2781                 # Extract the first word of "g++", so it can be a program name with args.
2782 set dummy g++; ac_word=$2
2783 echo "$as_me:2783: checking for $ac_word" >&5
2784 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2785 if test "${ac_cv_path_CXX+set}" = set; then
2786   echo $ECHO_N "(cached) $ECHO_C" >&6
2787 else
2788   case $CXX in
2789   [\\/]* | ?:[\\/]*)
2790   ac_cv_path_CXX="$CXX" # Let the user override the test with a path.
2791   ;;
2792   *)
2793   ac_save_IFS=$IFS; IFS=$ac_path_separator
2794 ac_dummy="$PATH"
2795 for ac_dir in $ac_dummy; do
2796   IFS=$ac_save_IFS
2797   test -z "$ac_dir" && ac_dir=.
2798   if $as_executable_p "$ac_dir/$ac_word"; then
2799    ac_cv_path_CXX="$ac_dir/$ac_word"
2800    echo "$as_me:2800: found $ac_dir/$ac_word" >&5
2801    break
2802 fi
2803 done
2804
2805   ;;
2806 esac
2807 fi
2808 CXX=$ac_cv_path_CXX
2809
2810 if test -n "$CXX"; then
2811   echo "$as_me:2811: result: $CXX" >&5
2812 echo "${ECHO_T}$CXX" >&6
2813 else
2814   echo "$as_me:2814: result: no" >&5
2815 echo "${ECHO_T}no" >&6
2816 fi
2817
2818         fi
2819         case "x$CXX" in #(vi
2820         x|xg++)
2821                 { echo "$as_me:2821: WARNING: You don't have any C++ compiler, too bad" >&5
2822 echo "$as_me: WARNING: You don't have any C++ compiler, too bad" >&2;}
2823                 cf_with_cxx=no; CXX=""; GXX="";
2824                 ;;
2825         esac
2826 fi
2827
2828 GXX_VERSION=none
2829 if test "$GXX" = yes; then
2830         echo "$as_me:2830: checking version of ${CXX:-g++}" >&5
2831 echo $ECHO_N "checking version of ${CXX:-g++}... $ECHO_C" >&6
2832         GXX_VERSION="`${CXX:-g++} --version| sed -e '2,$d' -e 's/^.*(GCC) //' -e 's/^[^0-9.]*//' -e 's/[^0-9.].*//'`"
2833         test -z "$GXX_VERSION" && GXX_VERSION=unknown
2834         echo "$as_me:2834: result: $GXX_VERSION" >&5
2835 echo "${ECHO_T}$GXX_VERSION" >&6
2836 fi
2837
2838 case $GXX_VERSION in
2839 1*|2.[0-6]*)
2840         # GXX=""; CXX=""; ac_cv_prog_gxx=no
2841         # cf_cxx_library=no
2842         { echo "$as_me:2842: WARNING: templates do not work" >&5
2843 echo "$as_me: WARNING: templates do not work" >&2;}
2844         ;;
2845 esac
2846
2847 echo "$as_me:2847: checking if you want to build C++ binding and demo" >&5
2848 echo $ECHO_N "checking if you want to build C++ binding and demo... $ECHO_C" >&6
2849
2850 # Check whether --with-cxx-binding or --without-cxx-binding was given.
2851 if test "${with_cxx_binding+set}" = set; then
2852   withval="$with_cxx_binding"
2853   cf_with_cxx_binding=$withval
2854 else
2855   cf_with_cxx_binding=$cf_with_cxx
2856 fi;
2857 echo "$as_me:2857: result: $cf_with_cxx_binding" >&5
2858 echo "${ECHO_T}$cf_with_cxx_binding" >&6
2859
2860 echo "$as_me:2860: checking if you want to build with Ada95" >&5
2861 echo $ECHO_N "checking if you want to build with Ada95... $ECHO_C" >&6
2862 echo "$as_me:2862: result: $cf_with_ada" >&5
2863 echo "${ECHO_T}$cf_with_ada" >&6
2864
2865 echo "$as_me:2865: checking if you want to install manpages" >&5
2866 echo $ECHO_N "checking if you want to install manpages... $ECHO_C" >&6
2867
2868 # Check whether --with-manpages or --without-manpages was given.
2869 if test "${with_manpages+set}" = set; then
2870   withval="$with_manpages"
2871   cf_with_manpages=$withval
2872 else
2873   cf_with_manpages=yes
2874 fi;
2875 echo "$as_me:2875: result: $cf_with_manpages" >&5
2876 echo "${ECHO_T}$cf_with_manpages" >&6
2877
2878 echo "$as_me:2878: checking if you want to build programs such as tic" >&5
2879 echo $ECHO_N "checking if you want to build programs such as tic... $ECHO_C" >&6
2880
2881 # Check whether --with-progs or --without-progs was given.
2882 if test "${with_progs+set}" = set; then
2883   withval="$with_progs"
2884   cf_with_progs=$withval
2885 else
2886   cf_with_progs=yes
2887 fi;
2888 echo "$as_me:2888: result: $cf_with_progs" >&5
2889 echo "${ECHO_T}$cf_with_progs" >&6
2890
2891 echo "$as_me:2891: checking if you want to build test-programs" >&5
2892 echo $ECHO_N "checking if you want to build test-programs... $ECHO_C" >&6
2893
2894 # Check whether --with-tests or --without-tests was given.
2895 if test "${with_tests+set}" = set; then
2896   withval="$with_tests"
2897   cf_with_tests=$withval
2898 else
2899   cf_with_tests=yes
2900 fi;
2901 echo "$as_me:2901: result: $cf_with_tests" >&5
2902 echo "${ECHO_T}$cf_with_tests" >&6
2903
2904 echo "$as_me:2904: checking if you wish to install curses.h" >&5
2905 echo $ECHO_N "checking if you wish to install curses.h... $ECHO_C" >&6
2906
2907 # Check whether --with-curses-h or --without-curses-h was given.
2908 if test "${with_curses_h+set}" = set; then
2909   withval="$with_curses_h"
2910   with_curses_h=$withval
2911 else
2912   with_curses_h=yes
2913 fi;
2914 echo "$as_me:2914: result: $with_curses_h" >&5
2915 echo "${ECHO_T}$with_curses_h" >&6
2916
2917 modules_to_build="ncurses"
2918 if test "X$cf_with_progs" != Xno ; then
2919 modules_to_build="$modules_to_build progs tack"
2920 fi
2921 modules_to_build="$modules_to_build panel menu form"
2922
2923 test "$program_prefix" != NONE &&
2924   program_transform_name="s,^,$program_prefix,;$program_transform_name"
2925 # Use a double $ so make ignores it.
2926 test "$program_suffix" != NONE &&
2927   program_transform_name="s,\$,$program_suffix,;$program_transform_name"
2928 # Double any \ or $.  echo might interpret backslashes.
2929 # By default was `s,x,x', remove it if useless.
2930 cat <<\_ACEOF >conftest.sed
2931 s/[\\$]/&&/g;s/;s,x,x,$//
2932 _ACEOF
2933 program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
2934 rm conftest.sed
2935
2936 for ac_prog in mawk gawk nawk awk
2937 do
2938   # Extract the first word of "$ac_prog", so it can be a program name with args.
2939 set dummy $ac_prog; ac_word=$2
2940 echo "$as_me:2940: checking for $ac_word" >&5
2941 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2942 if test "${ac_cv_prog_AWK+set}" = set; then
2943   echo $ECHO_N "(cached) $ECHO_C" >&6
2944 else
2945   if test -n "$AWK"; then
2946   ac_cv_prog_AWK="$AWK" # Let the user override the test.
2947 else
2948   ac_save_IFS=$IFS; IFS=$ac_path_separator
2949 ac_dummy="$PATH"
2950 for ac_dir in $ac_dummy; do
2951   IFS=$ac_save_IFS
2952   test -z "$ac_dir" && ac_dir=.
2953   $as_executable_p "$ac_dir/$ac_word" || continue
2954 ac_cv_prog_AWK="$ac_prog"
2955 echo "$as_me:2955: found $ac_dir/$ac_word" >&5
2956 break
2957 done
2958
2959 fi
2960 fi
2961 AWK=$ac_cv_prog_AWK
2962 if test -n "$AWK"; then
2963   echo "$as_me:2963: result: $AWK" >&5
2964 echo "${ECHO_T}$AWK" >&6
2965 else
2966   echo "$as_me:2966: result: no" >&5
2967 echo "${ECHO_T}no" >&6
2968 fi
2969
2970   test -n "$AWK" && break
2971 done
2972
2973 test -z "$AWK" && { { echo "$as_me:2973: error: No awk program found" >&5
2974 echo "$as_me: error: No awk program found" >&2;}
2975    { (exit 1); exit 1; }; }
2976
2977 echo "$as_me:2977: checking for egrep" >&5
2978 echo $ECHO_N "checking for egrep... $ECHO_C" >&6
2979 if test "${ac_cv_prog_egrep+set}" = set; then
2980   echo $ECHO_N "(cached) $ECHO_C" >&6
2981 else
2982   if echo a | (grep -E '(a|b)') >/dev/null 2>&1
2983     then ac_cv_prog_egrep='grep -E'
2984     else ac_cv_prog_egrep='egrep'
2985     fi
2986 fi
2987 echo "$as_me:2987: result: $ac_cv_prog_egrep" >&5
2988 echo "${ECHO_T}$ac_cv_prog_egrep" >&6
2989  EGREP=$ac_cv_prog_egrep
2990
2991 test -z "$EGREP" && { { echo "$as_me:2991: error: No egrep program found" >&5
2992 echo "$as_me: error: No egrep program found" >&2;}
2993    { (exit 1); exit 1; }; }
2994
2995 # Find a good install program.  We prefer a C program (faster),
2996 # so one script is as good as another.  But avoid the broken or
2997 # incompatible versions:
2998 # SysV /etc/install, /usr/sbin/install
2999 # SunOS /usr/etc/install
3000 # IRIX /sbin/install
3001 # AIX /bin/install
3002 # AmigaOS /C/install, which installs bootblocks on floppy discs
3003 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3004 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
3005 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3006 # ./install, which can be erroneously created by make from ./install.sh.
3007 echo "$as_me:3007: checking for a BSD compatible install" >&5
3008 echo $ECHO_N "checking for a BSD compatible install... $ECHO_C" >&6
3009 if test -z "$INSTALL"; then
3010 if test "${ac_cv_path_install+set}" = set; then
3011   echo $ECHO_N "(cached) $ECHO_C" >&6
3012 else
3013     ac_save_IFS=$IFS; IFS=$ac_path_separator
3014   for ac_dir in $PATH; do
3015     IFS=$ac_save_IFS
3016     # Account for people who put trailing slashes in PATH elements.
3017     case $ac_dir/ in
3018     / | ./ | .// | /cC/* \
3019     | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* \
3020     | /usr/ucb/* ) ;;
3021     *)
3022       # OSF1 and SCO ODT 3.0 have their own names for install.
3023       # Don't use installbsd from OSF since it installs stuff as root
3024       # by default.
3025       for ac_prog in ginstall scoinst install; do
3026         if $as_executable_p "$ac_dir/$ac_prog"; then
3027           if test $ac_prog = install &&
3028             grep dspmsg "$ac_dir/$ac_prog" >/dev/null 2>&1; then
3029             # AIX install.  It has an incompatible calling convention.
3030             :
3031           elif test $ac_prog = install &&
3032             grep pwplus "$ac_dir/$ac_prog" >/dev/null 2>&1; then
3033             # program-specific install script used by HP pwplus--don't use.
3034             :
3035           else
3036             ac_cv_path_install="$ac_dir/$ac_prog -c"
3037             break 2
3038           fi
3039         fi
3040       done
3041       ;;
3042     esac
3043   done
3044
3045 fi
3046   if test "${ac_cv_path_install+set}" = set; then
3047     INSTALL=$ac_cv_path_install
3048   else
3049     # As a last resort, use the slow shell script.  We don't cache a
3050     # path for INSTALL within a source directory, because that will
3051     # break other packages using the cache if that directory is
3052     # removed, or if the path is relative.
3053     INSTALL=$ac_install_sh
3054   fi
3055 fi
3056 echo "$as_me:3056: result: $INSTALL" >&5
3057 echo "${ECHO_T}$INSTALL" >&6
3058
3059 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3060 # It thinks the first close brace ends the variable substitution.
3061 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3062
3063 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
3064
3065 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3066
3067 case $INSTALL in
3068 /*)
3069   ;;
3070 *)
3071   cf_dir=`echo $INSTALL | sed -e 's%/[^/]*$%%'`
3072   test -z "$cf_dir" && cf_dir=.
3073   INSTALL=`cd $cf_dir && pwd`/`echo $INSTALL | sed -e 's%^.*/%%'`
3074   ;;
3075 esac
3076
3077 for ac_prog in tdlint lint alint splint lclint
3078 do
3079   # Extract the first word of "$ac_prog", so it can be a program name with args.
3080 set dummy $ac_prog; ac_word=$2
3081 echo "$as_me:3081: checking for $ac_word" >&5
3082 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3083 if test "${ac_cv_prog_LINT+set}" = set; then
3084   echo $ECHO_N "(cached) $ECHO_C" >&6
3085 else
3086   if test -n "$LINT"; then
3087   ac_cv_prog_LINT="$LINT" # Let the user override the test.
3088 else
3089   ac_save_IFS=$IFS; IFS=$ac_path_separator
3090 ac_dummy="$PATH"
3091 for ac_dir in $ac_dummy; do
3092   IFS=$ac_save_IFS
3093   test -z "$ac_dir" && ac_dir=.
3094   $as_executable_p "$ac_dir/$ac_word" || continue
3095 ac_cv_prog_LINT="$ac_prog"
3096 echo "$as_me:3096: found $ac_dir/$ac_word" >&5
3097 break
3098 done
3099
3100 fi
3101 fi
3102 LINT=$ac_cv_prog_LINT
3103 if test -n "$LINT"; then
3104   echo "$as_me:3104: result: $LINT" >&5
3105 echo "${ECHO_T}$LINT" >&6
3106 else
3107   echo "$as_me:3107: result: no" >&5
3108 echo "${ECHO_T}no" >&6
3109 fi
3110
3111   test -n "$LINT" && break
3112 done
3113
3114 echo "$as_me:3114: checking whether ln -s works" >&5
3115 echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
3116 LN_S=$as_ln_s
3117 if test "$LN_S" = "ln -s"; then
3118   echo "$as_me:3118: result: yes" >&5
3119 echo "${ECHO_T}yes" >&6
3120 else
3121   echo "$as_me:3121: result: no, using $LN_S" >&5
3122 echo "${ECHO_T}no, using $LN_S" >&6
3123 fi
3124
3125 echo "$as_me:3125: checking if $LN_S -f options work" >&5
3126 echo $ECHO_N "checking if $LN_S -f options work... $ECHO_C" >&6
3127
3128 rm -f conf$$.src conf$$dst
3129 echo >conf$$.dst
3130 echo first >conf$$.src
3131 if $LN_S -f conf$$.src conf$$.dst 2>/dev/null; then
3132         cf_prog_ln_sf=yes
3133 else
3134         cf_prog_ln_sf=no
3135 fi
3136 rm -f conf$$.dst conf$$src
3137 echo "$as_me:3137: result: $cf_prog_ln_sf" >&5
3138 echo "${ECHO_T}$cf_prog_ln_sf" >&6
3139
3140 test "$cf_prog_ln_sf" = yes && LN_S="$LN_S -f"
3141
3142 echo "$as_me:3142: checking for long file names" >&5
3143 echo $ECHO_N "checking for long file names... $ECHO_C" >&6
3144 if test "${ac_cv_sys_long_file_names+set}" = set; then
3145   echo $ECHO_N "(cached) $ECHO_C" >&6
3146 else
3147   ac_cv_sys_long_file_names=yes
3148 # Test for long file names in all the places we know might matter:
3149 #      .                the current directory, where building will happen
3150 #      $prefix/lib      where we will be installing things
3151 #      $exec_prefix/lib likewise
3152 # eval it to expand exec_prefix.
3153 #      $TMPDIR          if set, where it might want to write temporary files
3154 # if $TMPDIR is not set:
3155 #      /tmp             where it might want to write temporary files
3156 #      /var/tmp         likewise
3157 #      /usr/tmp         likewise
3158 if test -n "$TMPDIR" && test -d "$TMPDIR" && test -w "$TMPDIR"; then
3159   ac_tmpdirs=$TMPDIR
3160 else
3161   ac_tmpdirs='/tmp /var/tmp /usr/tmp'
3162 fi
3163 for ac_dir in  . $ac_tmpdirs `eval echo $prefix/lib $exec_prefix/lib` ; do
3164   test -d $ac_dir || continue
3165   test -w $ac_dir || continue # It is less confusing to not echo anything here.
3166   ac_xdir=$ac_dir/cf$$
3167   (umask 077 && mkdir $ac_xdir 2>/dev/null) || continue
3168   ac_tf1=$ac_xdir/conftest9012345
3169   ac_tf2=$ac_xdir/conftest9012346
3170   (echo 1 >$ac_tf1) 2>/dev/null
3171   (echo 2 >$ac_tf2) 2>/dev/null
3172   ac_val=`cat $ac_tf1 2>/dev/null`
3173   if test ! -f $ac_tf1 || test "$ac_val" != 1; then
3174     ac_cv_sys_long_file_names=no
3175     rm -rf $ac_xdir 2>/dev/null
3176     break
3177   fi
3178   rm -rf $ac_xdir 2>/dev/null
3179 done
3180 fi
3181 echo "$as_me:3181: result: $ac_cv_sys_long_file_names" >&5
3182 echo "${ECHO_T}$ac_cv_sys_long_file_names" >&6
3183 if test $ac_cv_sys_long_file_names = yes; then
3184
3185 cat >>confdefs.h <<\EOF
3186 #define HAVE_LONG_FILE_NAMES 1
3187 EOF
3188
3189 fi
3190
3191 # if we find pkg-config, check if we should install the ".pc" files.
3192
3193 echo "$as_me:3193: checking if you want to use pkg-config" >&5
3194 echo $ECHO_N "checking if you want to use pkg-config... $ECHO_C" >&6
3195
3196 # Check whether --with-pkg-config or --without-pkg-config was given.
3197 if test "${with_pkg_config+set}" = set; then
3198   withval="$with_pkg_config"
3199   cf_pkg_config=$withval
3200 else
3201   cf_pkg_config=yes
3202 fi;
3203 echo "$as_me:3203: result: $cf_pkg_config" >&5
3204 echo "${ECHO_T}$cf_pkg_config" >&6
3205
3206 case $cf_pkg_config in #(vi
3207 no) #(vi
3208         PKG_CONFIG=none
3209         ;;
3210 yes) #(vi
3211
3212 if test -n "$ac_tool_prefix"; then
3213   # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
3214 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
3215 echo "$as_me:3215: checking for $ac_word" >&5
3216 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3217 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then
3218   echo $ECHO_N "(cached) $ECHO_C" >&6
3219 else
3220   case $PKG_CONFIG in
3221   [\\/]* | ?:[\\/]*)
3222   ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
3223   ;;
3224   *)
3225   ac_save_IFS=$IFS; IFS=$ac_path_separator
3226 ac_dummy="$PATH"
3227 for ac_dir in $ac_dummy; do
3228   IFS=$ac_save_IFS
3229   test -z "$ac_dir" && ac_dir=.
3230   if $as_executable_p "$ac_dir/$ac_word"; then
3231    ac_cv_path_PKG_CONFIG="$ac_dir/$ac_word"
3232    echo "$as_me:3232: found $ac_dir/$ac_word" >&5
3233    break
3234 fi
3235 done
3236
3237   ;;
3238 esac
3239 fi
3240 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
3241
3242 if test -n "$PKG_CONFIG"; then
3243   echo "$as_me:3243: result: $PKG_CONFIG" >&5
3244 echo "${ECHO_T}$PKG_CONFIG" >&6
3245 else
3246   echo "$as_me:3246: result: no" >&5
3247 echo "${ECHO_T}no" >&6
3248 fi
3249
3250 fi
3251 if test -z "$ac_cv_path_PKG_CONFIG"; then
3252   ac_pt_PKG_CONFIG=$PKG_CONFIG
3253   # Extract the first word of "pkg-config", so it can be a program name with args.
3254 set dummy pkg-config; ac_word=$2
3255 echo "$as_me:3255: checking for $ac_word" >&5
3256 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3257 if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then
3258   echo $ECHO_N "(cached) $ECHO_C" >&6
3259 else
3260   case $ac_pt_PKG_CONFIG in
3261   [\\/]* | ?:[\\/]*)
3262   ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
3263   ;;
3264   *)
3265   ac_save_IFS=$IFS; IFS=$ac_path_separator
3266 ac_dummy="$PATH"
3267 for ac_dir in $ac_dummy; do
3268   IFS=$ac_save_IFS
3269   test -z "$ac_dir" && ac_dir=.
3270   if $as_executable_p "$ac_dir/$ac_word"; then
3271    ac_cv_path_ac_pt_PKG_CONFIG="$ac_dir/$ac_word"
3272    echo "$as_me:3272: found $ac_dir/$ac_word" >&5
3273    break
3274 fi
3275 done
3276
3277   test -z "$ac_cv_path_ac_pt_PKG_CONFIG" && ac_cv_path_ac_pt_PKG_CONFIG="none"
3278   ;;
3279 esac
3280 fi
3281 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
3282
3283 if test -n "$ac_pt_PKG_CONFIG"; then
3284   echo "$as_me:3284: result: $ac_pt_PKG_CONFIG" >&5
3285 echo "${ECHO_T}$ac_pt_PKG_CONFIG" >&6
3286 else
3287   echo "$as_me:3287: result: no" >&5
3288 echo "${ECHO_T}no" >&6
3289 fi
3290
3291   PKG_CONFIG=$ac_pt_PKG_CONFIG
3292 else
3293   PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
3294 fi
3295
3296         ;;
3297 *)
3298         PKG_CONFIG=$withval
3299         ;;
3300 esac
3301
3302 test -z "$PKG_CONFIG" && PKG_CONFIG=none
3303 if test "$PKG_CONFIG" != none ; then
3304
3305 if test "x$prefix" != xNONE; then
3306   cf_path_syntax="$prefix"
3307 else
3308   cf_path_syntax="$ac_default_prefix"
3309 fi
3310
3311 case ".$PKG_CONFIG" in #(vi
3312 .\$\(*\)*|.\'*\'*) #(vi
3313   ;;
3314 ..|./*|.\\*) #(vi
3315   ;;
3316 .[a-zA-Z]:[\\/]*) #(vi OS/2 EMX
3317   ;;
3318 .\${*prefix}*|.\${*dir}*) #(vi
3319   eval PKG_CONFIG="$PKG_CONFIG"
3320   case ".$PKG_CONFIG" in #(vi
3321   .NONE/*)
3322     PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
3323     ;;
3324   esac
3325   ;; #(vi
3326 .no|.NONE/*)
3327   PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
3328   ;;
3329 *)
3330   { { echo "$as_me:3330: error: expected a pathname, not \"$PKG_CONFIG\"" >&5
3331 echo "$as_me: error: expected a pathname, not \"$PKG_CONFIG\"" >&2;}
3332    { (exit 1); exit 1; }; }
3333   ;;
3334 esac
3335
3336 fi
3337
3338 if test "$PKG_CONFIG" != none ; then
3339         echo "$as_me:3339: checking for $PKG_CONFIG library directory" >&5
3340 echo $ECHO_N "checking for $PKG_CONFIG library directory... $ECHO_C" >&6
3341
3342 # Check whether --with-pkg-config-libdir or --without-pkg-config-libdir was given.
3343 if test "${with_pkg_config_libdir+set}" = set; then
3344   withval="$with_pkg_config_libdir"
3345   PKG_CONFIG_LIBDIR=$withval
3346 else
3347   PKG_CONFIG_LIBDIR=yes
3348 fi;
3349
3350         case x$PKG_CONFIG_LIBDIR in #(vi
3351         x/*) #(vi
3352                 ;;
3353         xyes) #(vi
3354                 # look for the library directory using the same prefix as the executable
3355                 cf_path=`echo "$PKG_CONFIG" | sed -e 's,/[^/]*/[^/]*$,,'`
3356                 case x`(arch) 2>/dev/null` in #(vi
3357                 *64) #(vi
3358                         for cf_config in $cf_path/share $cf_path/lib64 $cf_path/lib32 $cf_path/lib
3359                         do
3360                                 if test -d $cf_config/pkgconfig
3361                                 then
3362                                         PKG_CONFIG_LIBDIR=$cf_config/pkgconfig
3363                                         break
3364                                 fi
3365                         done
3366                         ;;
3367                 *)
3368                         PKG_CONFIG_LIBDIR=$cf_path/lib/pkgconfig
3369                         ;;
3370                 esac
3371                 ;;
3372         *)
3373                 ;;
3374         esac
3375
3376         echo "$as_me:3376: result: $PKG_CONFIG_LIBDIR" >&5
3377 echo "${ECHO_T}$PKG_CONFIG_LIBDIR" >&6
3378 fi
3379
3380 if test "$PKG_CONFIG" != none ; then
3381         echo "$as_me:3381: checking if we should install .pc files for $PKG_CONFIG" >&5
3382 echo $ECHO_N "checking if we should install .pc files for $PKG_CONFIG... $ECHO_C" >&6
3383
3384 # Check whether --enable-pc-files or --disable-pc-files was given.
3385 if test "${enable_pc_files+set}" = set; then
3386   enableval="$enable_pc_files"
3387   enable_pc_files=$enableval
3388 else
3389   enable_pc_files=no
3390 fi;
3391         echo "$as_me:3391: result: $enable_pc_files" >&5
3392 echo "${ECHO_T}$enable_pc_files" >&6
3393         if test "$enable_pc_files" != no
3394         then
3395
3396 if test "x$prefix" != xNONE; then
3397   cf_path_syntax="$prefix"
3398 else
3399   cf_path_syntax="$ac_default_prefix"
3400 fi
3401
3402 case ".$PKG_CONFIG_LIBDIR" in #(vi
3403 .\$\(*\)*|.\'*\'*) #(vi
3404   ;;
3405 ..|./*|.\\*) #(vi
3406   ;;
3407 .[a-zA-Z]:[\\/]*) #(vi OS/2 EMX
3408   ;;
3409 .\${*prefix}*|.\${*dir}*) #(vi
3410   eval PKG_CONFIG_LIBDIR="$PKG_CONFIG_LIBDIR"
3411   case ".$PKG_CONFIG_LIBDIR" in #(vi
3412   .NONE/*)
3413     PKG_CONFIG_LIBDIR=`echo $PKG_CONFIG_LIBDIR | sed -e s%NONE%$cf_path_syntax%`
3414     ;;
3415   esac
3416   ;; #(vi
3417 .no|.NONE/*)
3418   PKG_CONFIG_LIBDIR=`echo $PKG_CONFIG_LIBDIR | sed -e s%NONE%$cf_path_syntax%`
3419   ;;
3420 *)
3421   { { echo "$as_me:3421: error: expected a pathname, not \"$PKG_CONFIG_LIBDIR\"" >&5
3422 echo "$as_me: error: expected a pathname, not \"$PKG_CONFIG_LIBDIR\"" >&2;}
3423    { (exit 1); exit 1; }; }
3424   ;;
3425 esac
3426
3427         fi
3428 else
3429         enable_pc_files=no
3430 fi
3431
3432 echo "$as_me:3432: checking if we should assume mixed-case filenames" >&5
3433 echo $ECHO_N "checking if we should assume mixed-case filenames... $ECHO_C" >&6
3434
3435 # Check whether --enable-mixed-case or --disable-mixed-case was given.
3436 if test "${enable_mixed_case+set}" = set; then
3437   enableval="$enable_mixed_case"
3438   enable_mixedcase=$enableval
3439 else
3440   enable_mixedcase=auto
3441 fi;
3442 echo "$as_me:3442: result: $enable_mixedcase" >&5
3443 echo "${ECHO_T}$enable_mixedcase" >&6
3444 if test "$enable_mixedcase" = "auto" ; then
3445
3446 echo "$as_me:3446: checking if filesystem supports mixed-case filenames" >&5
3447 echo $ECHO_N "checking if filesystem supports mixed-case filenames... $ECHO_C" >&6
3448 if test "${cf_cv_mixedcase+set}" = set; then
3449   echo $ECHO_N "(cached) $ECHO_C" >&6
3450 else
3451
3452 if test "$cross_compiling" = yes ; then
3453         case $target_alias in #(vi
3454         *-os2-emx*|*-msdosdjgpp*|*-cygwin*|*-mingw32*|*-uwin*) #(vi
3455                 cf_cv_mixedcase=no
3456                 ;;
3457         *)
3458                 cf_cv_mixedcase=yes
3459                 ;;
3460         esac
3461 else
3462         rm -f conftest CONFTEST
3463         echo test >conftest
3464         if test -f CONFTEST ; then
3465                 cf_cv_mixedcase=no
3466         else
3467                 cf_cv_mixedcase=yes
3468         fi
3469         rm -f conftest CONFTEST
3470 fi
3471
3472 fi
3473 echo "$as_me:3473: result: $cf_cv_mixedcase" >&5
3474 echo "${ECHO_T}$cf_cv_mixedcase" >&6
3475 test "$cf_cv_mixedcase" = yes &&
3476 cat >>confdefs.h <<\EOF
3477 #define MIXEDCASE_FILENAMES 1
3478 EOF
3479
3480 else
3481     cf_cv_mixedcase=$enable_mixedcase
3482     if test "x$enable_mixedcase" = "xyes" ; then
3483
3484 cat >>confdefs.h <<\EOF
3485 #define MIXEDCASE_FILENAMES 1
3486 EOF
3487
3488     fi
3489 fi
3490
3491 # do this after mixed-case option (tags/TAGS is not as important as tic).
3492 echo "$as_me:3492: checking whether ${MAKE-make} sets \${MAKE}" >&5
3493 echo $ECHO_N "checking whether ${MAKE-make} sets \${MAKE}... $ECHO_C" >&6
3494 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,./+-,__p_,'`
3495 if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
3496   echo $ECHO_N "(cached) $ECHO_C" >&6
3497 else
3498   cat >conftest.make <<\EOF
3499 all:
3500         @echo 'ac_maketemp="${MAKE}"'
3501 EOF
3502 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
3503 eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
3504 if test -n "$ac_maketemp"; then
3505   eval ac_cv_prog_make_${ac_make}_set=yes
3506 else
3507   eval ac_cv_prog_make_${ac_make}_set=no
3508 fi
3509 rm -f conftest.make
3510 fi
3511 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
3512   echo "$as_me:3512: result: yes" >&5
3513 echo "${ECHO_T}yes" >&6
3514   SET_MAKE=
3515 else
3516   echo "$as_me:3516: result: no" >&5
3517 echo "${ECHO_T}no" >&6
3518   SET_MAKE="MAKE=${MAKE-make}"
3519 fi
3520
3521 for ac_prog in exctags ctags
3522 do
3523   # Extract the first word of "$ac_prog", so it can be a program name with args.
3524 set dummy $ac_prog; ac_word=$2
3525 echo "$as_me:3525: checking for $ac_word" >&5
3526 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3527 if test "${ac_cv_prog_CTAGS+set}" = set; then
3528   echo $ECHO_N "(cached) $ECHO_C" >&6
3529 else
3530   if test -n "$CTAGS"; then
3531   ac_cv_prog_CTAGS="$CTAGS" # Let the user override the test.
3532 else
3533   ac_save_IFS=$IFS; IFS=$ac_path_separator
3534 ac_dummy="$PATH"
3535 for ac_dir in $ac_dummy; do
3536   IFS=$ac_save_IFS
3537   test -z "$ac_dir" && ac_dir=.
3538   $as_executable_p "$ac_dir/$ac_word" || continue
3539 ac_cv_prog_CTAGS="$ac_prog"
3540 echo "$as_me:3540: found $ac_dir/$ac_word" >&5
3541 break
3542 done
3543
3544 fi
3545 fi
3546 CTAGS=$ac_cv_prog_CTAGS
3547 if test -n "$CTAGS"; then
3548   echo "$as_me:3548: result: $CTAGS" >&5
3549 echo "${ECHO_T}$CTAGS" >&6
3550 else
3551   echo "$as_me:3551: result: no" >&5
3552 echo "${ECHO_T}no" >&6
3553 fi
3554
3555   test -n "$CTAGS" && break
3556 done
3557
3558 for ac_prog in exetags etags
3559 do
3560   # Extract the first word of "$ac_prog", so it can be a program name with args.
3561 set dummy $ac_prog; ac_word=$2
3562 echo "$as_me:3562: checking for $ac_word" >&5
3563 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3564 if test "${ac_cv_prog_ETAGS+set}" = set; then
3565   echo $ECHO_N "(cached) $ECHO_C" >&6
3566 else
3567   if test -n "$ETAGS"; then
3568   ac_cv_prog_ETAGS="$ETAGS" # Let the user override the test.
3569 else
3570   ac_save_IFS=$IFS; IFS=$ac_path_separator
3571 ac_dummy="$PATH"
3572 for ac_dir in $ac_dummy; do
3573   IFS=$ac_save_IFS
3574   test -z "$ac_dir" && ac_dir=.
3575   $as_executable_p "$ac_dir/$ac_word" || continue
3576 ac_cv_prog_ETAGS="$ac_prog"
3577 echo "$as_me:3577: found $ac_dir/$ac_word" >&5
3578 break
3579 done
3580
3581 fi
3582 fi
3583 ETAGS=$ac_cv_prog_ETAGS
3584 if test -n "$ETAGS"; then
3585   echo "$as_me:3585: result: $ETAGS" >&5
3586 echo "${ECHO_T}$ETAGS" >&6
3587 else
3588   echo "$as_me:3588: result: no" >&5
3589 echo "${ECHO_T}no" >&6
3590 fi
3591
3592   test -n "$ETAGS" && break
3593 done
3594
3595 # Extract the first word of "${CTAGS:-ctags}", so it can be a program name with args.
3596 set dummy ${CTAGS:-ctags}; ac_word=$2
3597 echo "$as_me:3597: checking for $ac_word" >&5
3598 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3599 if test "${ac_cv_prog_MAKE_LOWER_TAGS+set}" = set; then
3600   echo $ECHO_N "(cached) $ECHO_C" >&6
3601 else
3602   if test -n "$MAKE_LOWER_TAGS"; then
3603   ac_cv_prog_MAKE_LOWER_TAGS="$MAKE_LOWER_TAGS" # Let the user override the test.
3604 else
3605   ac_save_IFS=$IFS; IFS=$ac_path_separator
3606 ac_dummy="$PATH"
3607 for ac_dir in $ac_dummy; do
3608   IFS=$ac_save_IFS
3609   test -z "$ac_dir" && ac_dir=.
3610   $as_executable_p "$ac_dir/$ac_word" || continue
3611 ac_cv_prog_MAKE_LOWER_TAGS="yes"
3612 echo "$as_me:3612: found $ac_dir/$ac_word" >&5
3613 break
3614 done
3615
3616   test -z "$ac_cv_prog_MAKE_LOWER_TAGS" && ac_cv_prog_MAKE_LOWER_TAGS="no"
3617 fi
3618 fi
3619 MAKE_LOWER_TAGS=$ac_cv_prog_MAKE_LOWER_TAGS
3620 if test -n "$MAKE_LOWER_TAGS"; then
3621   echo "$as_me:3621: result: $MAKE_LOWER_TAGS" >&5
3622 echo "${ECHO_T}$MAKE_LOWER_TAGS" >&6
3623 else
3624   echo "$as_me:3624: result: no" >&5
3625 echo "${ECHO_T}no" >&6
3626 fi
3627
3628 if test "$cf_cv_mixedcase" = yes ; then
3629         # Extract the first word of "${ETAGS:-etags}", so it can be a program name with args.
3630 set dummy ${ETAGS:-etags}; ac_word=$2
3631 echo "$as_me:3631: checking for $ac_word" >&5
3632 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3633 if test "${ac_cv_prog_MAKE_UPPER_TAGS+set}" = set; then
3634   echo $ECHO_N "(cached) $ECHO_C" >&6
3635 else
3636   if test -n "$MAKE_UPPER_TAGS"; then
3637   ac_cv_prog_MAKE_UPPER_TAGS="$MAKE_UPPER_TAGS" # Let the user override the test.
3638 else
3639   ac_save_IFS=$IFS; IFS=$ac_path_separator
3640 ac_dummy="$PATH"
3641 for ac_dir in $ac_dummy; do
3642   IFS=$ac_save_IFS
3643   test -z "$ac_dir" && ac_dir=.
3644   $as_executable_p "$ac_dir/$ac_word" || continue
3645 ac_cv_prog_MAKE_UPPER_TAGS="yes"
3646 echo "$as_me:3646: found $ac_dir/$ac_word" >&5
3647 break
3648 done
3649
3650   test -z "$ac_cv_prog_MAKE_UPPER_TAGS" && ac_cv_prog_MAKE_UPPER_TAGS="no"
3651 fi
3652 fi
3653 MAKE_UPPER_TAGS=$ac_cv_prog_MAKE_UPPER_TAGS
3654 if test -n "$MAKE_UPPER_TAGS"; then
3655   echo "$as_me:3655: result: $MAKE_UPPER_TAGS" >&5
3656 echo "${ECHO_T}$MAKE_UPPER_TAGS" >&6
3657 else
3658   echo "$as_me:3658: result: no" >&5
3659 echo "${ECHO_T}no" >&6
3660 fi
3661
3662 else
3663         MAKE_UPPER_TAGS=no
3664 fi
3665
3666 if test "$MAKE_UPPER_TAGS" = yes ; then
3667         MAKE_UPPER_TAGS=
3668 else
3669         MAKE_UPPER_TAGS="#"
3670 fi
3671
3672 if test "$MAKE_LOWER_TAGS" = yes ; then
3673         MAKE_LOWER_TAGS=
3674 else
3675         MAKE_LOWER_TAGS="#"
3676 fi
3677
3678 echo "$as_me:3678: checking for makeflags variable" >&5
3679 echo $ECHO_N "checking for makeflags variable... $ECHO_C" >&6
3680 if test "${cf_cv_makeflags+set}" = set; then
3681   echo $ECHO_N "(cached) $ECHO_C" >&6
3682 else
3683
3684         cf_cv_makeflags=''
3685         for cf_option in '-${MAKEFLAGS}' '${MFLAGS}'
3686         do
3687                 cat >cf_makeflags.tmp <<CF_EOF
3688 SHELL = /bin/sh
3689 all :
3690         @ echo '.$cf_option'
3691 CF_EOF
3692                 cf_result=`${MAKE:-make} -k -f cf_makeflags.tmp 2>/dev/null | fgrep -v "ing directory" | sed -e 's,[    ]*$,,'`
3693                 case "$cf_result" in
3694                 .*k)
3695                         cf_result=`${MAKE:-make} -k -f cf_makeflags.tmp CC=cc 2>/dev/null`
3696                         case "$cf_result" in
3697                         .*CC=*) cf_cv_makeflags=
3698                                 ;;
3699                         *)      cf_cv_makeflags=$cf_option
3700                                 ;;
3701                         esac
3702                         break
3703                         ;;
3704                 .-)     ;;
3705                 *)      echo "given option \"$cf_option\", no match \"$cf_result\""
3706                         ;;
3707                 esac
3708         done
3709         rm -f cf_makeflags.tmp
3710
3711 fi
3712 echo "$as_me:3712: result: $cf_cv_makeflags" >&5
3713 echo "${ECHO_T}$cf_cv_makeflags" >&6
3714
3715 if test -n "$ac_tool_prefix"; then
3716   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
3717 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
3718 echo "$as_me:3718: checking for $ac_word" >&5
3719 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3720 if test "${ac_cv_prog_RANLIB+set}" = set; then
3721   echo $ECHO_N "(cached) $ECHO_C" >&6
3722 else
3723   if test -n "$RANLIB"; then
3724   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
3725 else
3726   ac_save_IFS=$IFS; IFS=$ac_path_separator
3727 ac_dummy="$PATH"
3728 for ac_dir in $ac_dummy; do
3729   IFS=$ac_save_IFS
3730   test -z "$ac_dir" && ac_dir=.
3731   $as_executable_p "$ac_dir/$ac_word" || continue
3732 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
3733 echo "$as_me:3733: found $ac_dir/$ac_word" >&5
3734 break
3735 done
3736
3737 fi
3738 fi
3739 RANLIB=$ac_cv_prog_RANLIB
3740 if test -n "$RANLIB"; then
3741   echo "$as_me:3741: result: $RANLIB" >&5
3742 echo "${ECHO_T}$RANLIB" >&6
3743 else
3744   echo "$as_me:3744: result: no" >&5
3745 echo "${ECHO_T}no" >&6
3746 fi
3747
3748 fi
3749 if test -z "$ac_cv_prog_RANLIB"; then
3750   ac_ct_RANLIB=$RANLIB
3751   # Extract the first word of "ranlib", so it can be a program name with args.
3752 set dummy ranlib; ac_word=$2
3753 echo "$as_me:3753: checking for $ac_word" >&5
3754 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3755 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
3756   echo $ECHO_N "(cached) $ECHO_C" >&6
3757 else
3758   if test -n "$ac_ct_RANLIB"; then
3759   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
3760 else
3761   ac_save_IFS=$IFS; IFS=$ac_path_separator
3762 ac_dummy="$PATH"
3763 for ac_dir in $ac_dummy; do
3764   IFS=$ac_save_IFS
3765   test -z "$ac_dir" && ac_dir=.
3766   $as_executable_p "$ac_dir/$ac_word" || continue
3767 ac_cv_prog_ac_ct_RANLIB="ranlib"
3768 echo "$as_me:3768: found $ac_dir/$ac_word" >&5
3769 break
3770 done
3771
3772   test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB="':'"
3773 fi
3774 fi
3775 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
3776 if test -n "$ac_ct_RANLIB"; then
3777   echo "$as_me:3777: result: $ac_ct_RANLIB" >&5
3778 echo "${ECHO_T}$ac_ct_RANLIB" >&6
3779 else
3780   echo "$as_me:3780: result: no" >&5
3781 echo "${ECHO_T}no" >&6
3782 fi
3783
3784   RANLIB=$ac_ct_RANLIB
3785 else
3786   RANLIB="$ac_cv_prog_RANLIB"
3787 fi
3788
3789 if test -n "$ac_tool_prefix"; then
3790   # Extract the first word of "${ac_tool_prefix}ld", so it can be a program name with args.
3791 set dummy ${ac_tool_prefix}ld; ac_word=$2
3792 echo "$as_me:3792: checking for $ac_word" >&5
3793 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3794 if test "${ac_cv_prog_LD+set}" = set; then
3795   echo $ECHO_N "(cached) $ECHO_C" >&6
3796 else
3797   if test -n "$LD"; then
3798   ac_cv_prog_LD="$LD" # Let the user override the test.
3799 else
3800   ac_save_IFS=$IFS; IFS=$ac_path_separator
3801 ac_dummy="$PATH"
3802 for ac_dir in $ac_dummy; do
3803   IFS=$ac_save_IFS
3804   test -z "$ac_dir" && ac_dir=.
3805   $as_executable_p "$ac_dir/$ac_word" || continue
3806 ac_cv_prog_LD="${ac_tool_prefix}ld"
3807 echo "$as_me:3807: found $ac_dir/$ac_word" >&5
3808 break
3809 done
3810
3811 fi
3812 fi
3813 LD=$ac_cv_prog_LD
3814 if test -n "$LD"; then
3815   echo "$as_me:3815: result: $LD" >&5
3816 echo "${ECHO_T}$LD" >&6
3817 else
3818   echo "$as_me:3818: result: no" >&5
3819 echo "${ECHO_T}no" >&6
3820 fi
3821
3822 fi
3823 if test -z "$ac_cv_prog_LD"; then
3824   ac_ct_LD=$LD
3825   # Extract the first word of "ld", so it can be a program name with args.
3826 set dummy ld; ac_word=$2
3827 echo "$as_me:3827: checking for $ac_word" >&5
3828 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3829 if test "${ac_cv_prog_ac_ct_LD+set}" = set; then
3830   echo $ECHO_N "(cached) $ECHO_C" >&6
3831 else
3832   if test -n "$ac_ct_LD"; then
3833   ac_cv_prog_ac_ct_LD="$ac_ct_LD" # Let the user override the test.
3834 else
3835   ac_save_IFS=$IFS; IFS=$ac_path_separator
3836 ac_dummy="$PATH"
3837 for ac_dir in $ac_dummy; do
3838   IFS=$ac_save_IFS
3839   test -z "$ac_dir" && ac_dir=.
3840   $as_executable_p "$ac_dir/$ac_word" || continue
3841 ac_cv_prog_ac_ct_LD="ld"
3842 echo "$as_me:3842: found $ac_dir/$ac_word" >&5
3843 break
3844 done
3845
3846   test -z "$ac_cv_prog_ac_ct_LD" && ac_cv_prog_ac_ct_LD="ld"
3847 fi
3848 fi
3849 ac_ct_LD=$ac_cv_prog_ac_ct_LD
3850 if test -n "$ac_ct_LD"; then
3851   echo "$as_me:3851: result: $ac_ct_LD" >&5
3852 echo "${ECHO_T}$ac_ct_LD" >&6
3853 else
3854   echo "$as_me:3854: result: no" >&5
3855 echo "${ECHO_T}no" >&6
3856 fi
3857
3858   LD=$ac_ct_LD
3859 else
3860   LD="$ac_cv_prog_LD"
3861 fi
3862
3863 if test -n "$ac_tool_prefix"; then
3864   # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
3865 set dummy ${ac_tool_prefix}ar; ac_word=$2
3866 echo "$as_me:3866: checking for $ac_word" >&5
3867 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3868 if test "${ac_cv_prog_AR+set}" = set; then
3869   echo $ECHO_N "(cached) $ECHO_C" >&6
3870 else
3871   if test -n "$AR"; then
3872   ac_cv_prog_AR="$AR" # Let the user override the test.
3873 else
3874   ac_save_IFS=$IFS; IFS=$ac_path_separator
3875 ac_dummy="$PATH"
3876 for ac_dir in $ac_dummy; do
3877   IFS=$ac_save_IFS
3878   test -z "$ac_dir" && ac_dir=.
3879   $as_executable_p "$ac_dir/$ac_word" || continue
3880 ac_cv_prog_AR="${ac_tool_prefix}ar"
3881 echo "$as_me:3881: found $ac_dir/$ac_word" >&5
3882 break
3883 done
3884
3885 fi
3886 fi
3887 AR=$ac_cv_prog_AR
3888 if test -n "$AR"; then
3889   echo "$as_me:3889: result: $AR" >&5
3890 echo "${ECHO_T}$AR" >&6
3891 else
3892   echo "$as_me:3892: result: no" >&5
3893 echo "${ECHO_T}no" >&6
3894 fi
3895
3896 fi
3897 if test -z "$ac_cv_prog_AR"; then
3898   ac_ct_AR=$AR
3899   # Extract the first word of "ar", so it can be a program name with args.
3900 set dummy ar; ac_word=$2
3901 echo "$as_me:3901: checking for $ac_word" >&5
3902 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3903 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
3904   echo $ECHO_N "(cached) $ECHO_C" >&6
3905 else
3906   if test -n "$ac_ct_AR"; then
3907   ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
3908 else
3909   ac_save_IFS=$IFS; IFS=$ac_path_separator
3910 ac_dummy="$PATH"
3911 for ac_dir in $ac_dummy; do
3912   IFS=$ac_save_IFS
3913   test -z "$ac_dir" && ac_dir=.
3914   $as_executable_p "$ac_dir/$ac_word" || continue
3915 ac_cv_prog_ac_ct_AR="ar"
3916 echo "$as_me:3916: found $ac_dir/$ac_word" >&5
3917 break
3918 done
3919
3920   test -z "$ac_cv_prog_ac_ct_AR" && ac_cv_prog_ac_ct_AR="ar"
3921 fi
3922 fi
3923 ac_ct_AR=$ac_cv_prog_ac_ct_AR
3924 if test -n "$ac_ct_AR"; then
3925   echo "$as_me:3925: result: $ac_ct_AR" >&5
3926 echo "${ECHO_T}$ac_ct_AR" >&6
3927 else
3928   echo "$as_me:3928: result: no" >&5
3929 echo "${ECHO_T}no" >&6
3930 fi
3931
3932   AR=$ac_ct_AR
3933 else
3934   AR="$ac_cv_prog_AR"
3935 fi
3936
3937 if test -n "$ac_tool_prefix"; then
3938   # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
3939 set dummy ${ac_tool_prefix}ar; 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_AR+set}" = set; then
3943   echo $ECHO_N "(cached) $ECHO_C" >&6
3944 else
3945   if test -n "$AR"; then
3946   ac_cv_prog_AR="$AR" # 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_AR="${ac_tool_prefix}ar"
3955 echo "$as_me:3955: found $ac_dir/$ac_word" >&5
3956 break
3957 done
3958
3959 fi
3960 fi
3961 AR=$ac_cv_prog_AR
3962 if test -n "$AR"; then
3963   echo "$as_me:3963: result: $AR" >&5
3964 echo "${ECHO_T}$AR" >&6
3965 else
3966   echo "$as_me:3966: result: no" >&5
3967 echo "${ECHO_T}no" >&6
3968 fi
3969
3970 fi
3971 if test -z "$ac_cv_prog_AR"; then
3972   ac_ct_AR=$AR
3973   # Extract the first word of "ar", so it can be a program name with args.
3974 set dummy ar; ac_word=$2
3975 echo "$as_me:3975: checking for $ac_word" >&5
3976 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3977 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
3978   echo $ECHO_N "(cached) $ECHO_C" >&6
3979 else
3980   if test -n "$ac_ct_AR"; then
3981   ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
3982 else
3983   ac_save_IFS=$IFS; IFS=$ac_path_separator
3984 ac_dummy="$PATH"
3985 for ac_dir in $ac_dummy; do
3986   IFS=$ac_save_IFS
3987   test -z "$ac_dir" && ac_dir=.
3988   $as_executable_p "$ac_dir/$ac_word" || continue
3989 ac_cv_prog_ac_ct_AR="ar"
3990 echo "$as_me:3990: found $ac_dir/$ac_word" >&5
3991 break
3992 done
3993
3994   test -z "$ac_cv_prog_ac_ct_AR" && ac_cv_prog_ac_ct_AR="ar"
3995 fi
3996 fi
3997 ac_ct_AR=$ac_cv_prog_ac_ct_AR
3998 if test -n "$ac_ct_AR"; then
3999   echo "$as_me:3999: result: $ac_ct_AR" >&5
4000 echo "${ECHO_T}$ac_ct_AR" >&6
4001 else
4002   echo "$as_me:4002: result: no" >&5
4003 echo "${ECHO_T}no" >&6
4004 fi
4005
4006   AR=$ac_ct_AR
4007 else
4008   AR="$ac_cv_prog_AR"
4009 fi
4010
4011 echo "$as_me:4011: checking for options to update archives" >&5
4012 echo $ECHO_N "checking for options to update archives... $ECHO_C" >&6
4013 if test "${cf_cv_ar_flags+set}" = set; then
4014   echo $ECHO_N "(cached) $ECHO_C" >&6
4015 else
4016
4017         cf_cv_ar_flags=unknown
4018         for cf_ar_flags in -curv curv -crv crv -cqv cqv -rv rv
4019         do
4020
4021                 # check if $ARFLAGS already contains this choice
4022                 if test "x$ARFLAGS" != "x" ; then
4023                         cf_check_ar_flags=`echo "x$ARFLAGS" | sed -e "s/$cf_ar_flags\$//" -e "s/$cf_ar_flags / /"`
4024                         if test "x$ARFLAGS" != "$cf_check_ar_flags" ; then
4025                                 cf_cv_ar_flags=
4026                                 break
4027                         fi
4028                 fi
4029
4030                 rm -f conftest.$ac_cv_objext
4031                 rm -f conftest.a
4032
4033                 cat >conftest.$ac_ext <<EOF
4034 #line 4034 "configure"
4035 int     testdata[3] = { 123, 456, 789 };
4036 EOF
4037                 if { (eval echo "$as_me:4037: \"$ac_compile\"") >&5
4038   (eval $ac_compile) 2>&5
4039   ac_status=$?
4040   echo "$as_me:4040: \$? = $ac_status" >&5
4041   (exit $ac_status); } ; then
4042                         echo "$AR $ARFLAGS $cf_ar_flags conftest.a conftest.$ac_cv_objext" >&5
4043                         $AR $ARFLAGS $cf_ar_flags conftest.a conftest.$ac_cv_objext 2>&5 1>/dev/null
4044                         if test -f conftest.a ; then
4045                                 cf_cv_ar_flags=$cf_ar_flags
4046                                 break
4047                         fi
4048                 else
4049                         test -n "$verbose" && echo "    cannot compile test-program" 1>&6
4050
4051 echo "${as_me:-configure}:4051: testing cannot compile test-program ..." 1>&5
4052
4053                         break
4054                 fi
4055         done
4056         rm -f conftest.a conftest.$ac_ext conftest.$ac_cv_objext
4057
4058 fi
4059 echo "$as_me:4059: result: $cf_cv_ar_flags" >&5
4060 echo "${ECHO_T}$cf_cv_ar_flags" >&6
4061
4062 if test -n "$ARFLAGS" ; then
4063         if test -n "$cf_cv_ar_flags" ; then
4064                 ARFLAGS="$ARFLAGS $cf_cv_ar_flags"
4065         fi
4066 else
4067         ARFLAGS=$cf_cv_ar_flags
4068 fi
4069
4070 echo "$as_me:4070: checking if you have specified an install-prefix" >&5
4071 echo $ECHO_N "checking if you have specified an install-prefix... $ECHO_C" >&6
4072
4073 # Check whether --with-install-prefix or --without-install-prefix was given.
4074 if test "${with_install_prefix+set}" = set; then
4075   withval="$with_install_prefix"
4076   case "x$withval" in #(vi
4077         xyes|xno) #(vi
4078                 ;;
4079         *)      DESTDIR="$withval"
4080                 ;;
4081         esac
4082 fi;
4083 echo "$as_me:4083: result: $DESTDIR" >&5
4084 echo "${ECHO_T}$DESTDIR" >&6
4085
4086 ###############################################################################
4087
4088 # If we're cross-compiling, allow the user to override the tools and their
4089 # options.  The configure script is oriented toward identifying the host
4090 # compiler, etc., but we need a build compiler to generate parts of the source.
4091
4092 if test "$cross_compiling" = yes ; then
4093
4094         # defaults that we might want to override
4095         : ${BUILD_CFLAGS:=''}
4096         : ${BUILD_CPPFLAGS:=''}
4097         : ${BUILD_LDFLAGS:=''}
4098         : ${BUILD_LIBS:=''}
4099         : ${BUILD_EXEEXT:='$x'}
4100         : ${BUILD_OBJEXT:='o'}
4101
4102 # Check whether --with-build-cc or --without-build-cc was given.
4103 if test "${with_build_cc+set}" = set; then
4104   withval="$with_build_cc"
4105   BUILD_CC="$withval"
4106 else
4107   for ac_prog in gcc cc cl
4108 do
4109   # Extract the first word of "$ac_prog", so it can be a program name with args.
4110 set dummy $ac_prog; ac_word=$2
4111 echo "$as_me:4111: checking for $ac_word" >&5
4112 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4113 if test "${ac_cv_prog_BUILD_CC+set}" = set; then
4114   echo $ECHO_N "(cached) $ECHO_C" >&6
4115 else
4116   if test -n "$BUILD_CC"; then
4117   ac_cv_prog_BUILD_CC="$BUILD_CC" # Let the user override the test.
4118 else
4119   ac_save_IFS=$IFS; IFS=$ac_path_separator
4120 ac_dummy="$PATH"
4121 for ac_dir in $ac_dummy; do
4122   IFS=$ac_save_IFS
4123   test -z "$ac_dir" && ac_dir=.
4124   $as_executable_p "$ac_dir/$ac_word" || continue
4125 ac_cv_prog_BUILD_CC="$ac_prog"
4126 echo "$as_me:4126: found $ac_dir/$ac_word" >&5
4127 break
4128 done
4129
4130 fi
4131 fi
4132 BUILD_CC=$ac_cv_prog_BUILD_CC
4133 if test -n "$BUILD_CC"; then
4134   echo "$as_me:4134: result: $BUILD_CC" >&5
4135 echo "${ECHO_T}$BUILD_CC" >&6
4136 else
4137   echo "$as_me:4137: result: no" >&5
4138 echo "${ECHO_T}no" >&6
4139 fi
4140
4141   test -n "$BUILD_CC" && break
4142 done
4143
4144 fi;
4145         echo "$as_me:4145: checking for native build C compiler" >&5
4146 echo $ECHO_N "checking for native build C compiler... $ECHO_C" >&6
4147         echo "$as_me:4147: result: $BUILD_CC" >&5
4148 echo "${ECHO_T}$BUILD_CC" >&6
4149
4150         echo "$as_me:4150: checking for native build C preprocessor" >&5
4151 echo $ECHO_N "checking for native build C preprocessor... $ECHO_C" >&6
4152
4153 # Check whether --with-build-cpp or --without-build-cpp was given.
4154 if test "${with_build_cpp+set}" = set; then
4155   withval="$with_build_cpp"
4156   BUILD_CPP="$withval"
4157 else
4158   BUILD_CPP='${BUILD_CC} -E'
4159 fi;
4160         echo "$as_me:4160: result: $BUILD_CPP" >&5
4161 echo "${ECHO_T}$BUILD_CPP" >&6
4162
4163         echo "$as_me:4163: checking for native build C flags" >&5
4164 echo $ECHO_N "checking for native build C flags... $ECHO_C" >&6
4165
4166 # Check whether --with-build-cflags or --without-build-cflags was given.
4167 if test "${with_build_cflags+set}" = set; then
4168   withval="$with_build_cflags"
4169   BUILD_CFLAGS="$withval"
4170 fi;
4171         echo "$as_me:4171: result: $BUILD_CFLAGS" >&5
4172 echo "${ECHO_T}$BUILD_CFLAGS" >&6
4173
4174         echo "$as_me:4174: checking for native build C preprocessor-flags" >&5
4175 echo $ECHO_N "checking for native build C preprocessor-flags... $ECHO_C" >&6
4176
4177 # Check whether --with-build-cppflags or --without-build-cppflags was given.
4178 if test "${with_build_cppflags+set}" = set; then
4179   withval="$with_build_cppflags"
4180   BUILD_CPPFLAGS="$withval"
4181 fi;
4182         echo "$as_me:4182: result: $BUILD_CPPFLAGS" >&5
4183 echo "${ECHO_T}$BUILD_CPPFLAGS" >&6
4184
4185         echo "$as_me:4185: checking for native build linker-flags" >&5
4186 echo $ECHO_N "checking for native build linker-flags... $ECHO_C" >&6
4187
4188 # Check whether --with-build-ldflags or --without-build-ldflags was given.
4189 if test "${with_build_ldflags+set}" = set; then
4190   withval="$with_build_ldflags"
4191   BUILD_LDFLAGS="$withval"
4192 fi;
4193         echo "$as_me:4193: result: $BUILD_LDFLAGS" >&5
4194 echo "${ECHO_T}$BUILD_LDFLAGS" >&6
4195
4196         echo "$as_me:4196: checking for native build linker-libraries" >&5
4197 echo $ECHO_N "checking for native build linker-libraries... $ECHO_C" >&6
4198
4199 # Check whether --with-build-libs or --without-build-libs was given.
4200 if test "${with_build_libs+set}" = set; then
4201   withval="$with_build_libs"
4202   BUILD_LIBS="$withval"
4203 fi;
4204         echo "$as_me:4204: result: $BUILD_LIBS" >&5
4205 echo "${ECHO_T}$BUILD_LIBS" >&6
4206
4207         # this assumes we're on Unix.
4208         BUILD_EXEEXT=
4209         BUILD_OBJEXT=o
4210
4211         : ${BUILD_CC:='${CC}'}
4212
4213         if ( test "$BUILD_CC" = "$CC" || test "$BUILD_CC" = '${CC}' ) ; then
4214                 { { echo "$as_me:4214: error: Cross-build requires two compilers.
4215 Use --with-build-cc to specify the native compiler." >&5
4216 echo "$as_me: error: Cross-build requires two compilers.
4217 Use --with-build-cc to specify the native compiler." >&2;}
4218    { (exit 1); exit 1; }; }
4219         fi
4220
4221 else
4222         : ${BUILD_CC:='${CC}'}
4223         : ${BUILD_CPP:='${CPP}'}
4224         : ${BUILD_CFLAGS:='${CFLAGS}'}
4225         : ${BUILD_CPPFLAGS:='${CPPFLAGS}'}
4226         : ${BUILD_LDFLAGS:='${LDFLAGS}'}
4227         : ${BUILD_LIBS:='${LIBS}'}
4228         : ${BUILD_EXEEXT:='$x'}
4229         : ${BUILD_OBJEXT:='o'}
4230 fi
4231
4232 ###############################################################################
4233
4234 ### Options to allow the user to specify the set of libraries which are used.
4235 ### Use "--without-normal --with-shared" to allow the default model to be
4236 ### shared, for example.
4237 cf_list_models=""
4238
4239 echo "$as_me:4239: checking if libtool -version-number should be used" >&5
4240 echo $ECHO_N "checking if libtool -version-number should be used... $ECHO_C" >&6
4241
4242 # Check whether --enable-libtool-version or --disable-libtool-version was given.
4243 if test "${enable_libtool_version+set}" = set; then
4244   enableval="$enable_libtool_version"
4245   test "$enableval" != no && enableval=yes
4246   if test "$enableval" != "yes" ; then
4247     cf_libtool_version=no
4248   else
4249     cf_libtool_version=yes
4250   fi
4251 else
4252   enableval=yes
4253   cf_libtool_version=yes
4254
4255 fi;
4256 echo "$as_me:4256: result: $cf_libtool_version" >&5
4257 echo "${ECHO_T}$cf_libtool_version" >&6
4258
4259 if test "$cf_libtool_version" = yes ; then
4260         LIBTOOL_VERSION="-version-number"
4261 else
4262         LIBTOOL_VERSION="-version-info"
4263 fi
4264
4265 LIBTOOL=
4266
4267 # common library maintenance symbols that are convenient for libtool scripts:
4268 LIB_CREATE='${AR} -cr'
4269 LIB_OBJECT='${OBJECTS}'
4270 LIB_SUFFIX=.a
4271 LIB_PREP="$RANLIB"
4272
4273 # symbols used to prop libtool up to enable it to determine what it should be
4274 # doing:
4275 LIB_CLEAN=
4276 LIB_COMPILE=
4277 LIB_LINK='${CC}'
4278 LIB_INSTALL=
4279 LIB_UNINSTALL=
4280
4281 echo "$as_me:4281: checking if you want to build libraries with libtool" >&5
4282 echo $ECHO_N "checking if you want to build libraries with libtool... $ECHO_C" >&6
4283
4284 # Check whether --with-libtool or --without-libtool was given.
4285 if test "${with_libtool+set}" = set; then
4286   withval="$with_libtool"
4287   with_libtool=$withval
4288 else
4289   with_libtool=no
4290 fi;
4291 echo "$as_me:4291: result: $with_libtool" >&5
4292 echo "${ECHO_T}$with_libtool" >&6
4293 if test "$with_libtool" != "no"; then
4294
4295         if test "$with_libtool" != "yes" ; then
4296
4297 if test "x$prefix" != xNONE; then
4298   cf_path_syntax="$prefix"
4299 else
4300   cf_path_syntax="$ac_default_prefix"
4301 fi
4302
4303 case ".$with_libtool" in #(vi
4304 .\$\(*\)*|.\'*\'*) #(vi
4305   ;;
4306 ..|./*|.\\*) #(vi
4307   ;;
4308 .[a-zA-Z]:[\\/]*) #(vi OS/2 EMX
4309   ;;
4310 .\${*prefix}*|.\${*dir}*) #(vi
4311   eval with_libtool="$with_libtool"
4312   case ".$with_libtool" in #(vi
4313   .NONE/*)
4314     with_libtool=`echo $with_libtool | sed -e s%NONE%$cf_path_syntax%`
4315     ;;
4316   esac
4317   ;; #(vi
4318 .no|.NONE/*)
4319   with_libtool=`echo $with_libtool | sed -e s%NONE%$cf_path_syntax%`
4320   ;;
4321 *)
4322   { { echo "$as_me:4322: error: expected a pathname, not \"$with_libtool\"" >&5
4323 echo "$as_me: error: expected a pathname, not \"$with_libtool\"" >&2;}
4324    { (exit 1); exit 1; }; }
4325   ;;
4326 esac
4327
4328                 LIBTOOL=$with_libtool
4329         else
4330                 # Extract the first word of "libtool", so it can be a program name with args.
4331 set dummy libtool; ac_word=$2
4332 echo "$as_me:4332: checking for $ac_word" >&5
4333 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4334 if test "${ac_cv_path_LIBTOOL+set}" = set; then
4335   echo $ECHO_N "(cached) $ECHO_C" >&6
4336 else
4337   case $LIBTOOL in
4338   [\\/]* | ?:[\\/]*)
4339   ac_cv_path_LIBTOOL="$LIBTOOL" # Let the user override the test with a path.
4340   ;;
4341   *)
4342   ac_save_IFS=$IFS; IFS=$ac_path_separator
4343 ac_dummy="$PATH"
4344 for ac_dir in $ac_dummy; do
4345   IFS=$ac_save_IFS
4346   test -z "$ac_dir" && ac_dir=.
4347   if $as_executable_p "$ac_dir/$ac_word"; then
4348    ac_cv_path_LIBTOOL="$ac_dir/$ac_word"
4349    echo "$as_me:4349: found $ac_dir/$ac_word" >&5
4350    break
4351 fi
4352 done
4353
4354   ;;
4355 esac
4356 fi
4357 LIBTOOL=$ac_cv_path_LIBTOOL
4358
4359 if test -n "$LIBTOOL"; then
4360   echo "$as_me:4360: result: $LIBTOOL" >&5
4361 echo "${ECHO_T}$LIBTOOL" >&6
4362 else
4363   echo "$as_me:4363: result: no" >&5
4364 echo "${ECHO_T}no" >&6
4365 fi
4366
4367         fi
4368         if test -z "$LIBTOOL" ; then
4369                 { { echo "$as_me:4369: error: Cannot find libtool" >&5
4370 echo "$as_me: error: Cannot find libtool" >&2;}
4371    { (exit 1); exit 1; }; }
4372         fi
4373         LIB_CREATE='${LIBTOOL} --mode=link ${CC} -rpath ${DESTDIR}${libdir} ${LIBTOOL_VERSION} `cut -f1 ${srcdir}/VERSION` ${LIBTOOL_OPTS} ${LT_UNDEF} $(LIBS) -o'
4374         LIB_OBJECT='${OBJECTS:.o=.lo}'
4375         LIB_SUFFIX=.la
4376         LIB_CLEAN='${LIBTOOL} --mode=clean'
4377         LIB_COMPILE='${LIBTOOL} --mode=compile'
4378         LIB_LINK='${LIBTOOL} --mode=link ${CC} ${LIBTOOL_OPTS}'
4379         LIB_INSTALL='${LIBTOOL} --mode=install'
4380         LIB_UNINSTALL='${LIBTOOL} --mode=uninstall'
4381         LIB_PREP=:
4382
4383         # Show the version of libtool
4384         echo "$as_me:4384: checking version of libtool" >&5
4385 echo $ECHO_N "checking version of libtool... $ECHO_C" >&6
4386
4387         # Save the version in a cache variable - this is not entirely a good
4388         # thing, but the version string from libtool is very ugly, and for
4389         # bug reports it might be useful to have the original string. "("
4390         cf_cv_libtool_version=`$LIBTOOL --version 2>&1 | sed -e '/^$/d' |sed -e '2,$d' -e 's/([^)]*)//g' -e 's/^[^1-9]*//' -e 's/[^0-9.].*//'`
4391         echo "$as_me:4391: result: $cf_cv_libtool_version" >&5
4392 echo "${ECHO_T}$cf_cv_libtool_version" >&6
4393         if test -z "$cf_cv_libtool_version" ; then
4394                 { { echo "$as_me:4394: error: This is not GNU libtool" >&5
4395 echo "$as_me: error: This is not GNU libtool" >&2;}
4396    { (exit 1); exit 1; }; }
4397         fi
4398
4399         # special hack to add -no-undefined (which libtool should do for itself)
4400         LT_UNDEF=
4401         case "$cf_cv_system_name" in #(vi
4402         cygwin*|mingw32*|uwin*|aix[4-7]) #(vi
4403                 LT_UNDEF=-no-undefined
4404                 ;;
4405         esac
4406
4407         # special hack to add --tag option for C++ compiler
4408         case $cf_cv_libtool_version in #(vi
4409         1.[5-9]*|[2-9].[0-9.a-z]*) #(vi
4410                 LIBTOOL_CXX="$LIBTOOL --tag=CXX"
4411                 LIBTOOL="$LIBTOOL --tag=CC"
4412                 ;;
4413         *)
4414                 LIBTOOL_CXX="$LIBTOOL"
4415                 ;;
4416         esac
4417 else
4418         LIBTOOL=""
4419         LIBTOOL_CXX=""
4420 fi
4421
4422 test -z "$LIBTOOL" && ECHO_LT=
4423
4424 if test "$with_libtool" != "no" ; then
4425
4426 cf_list_models="$cf_list_models libtool"
4427
4428 else
4429
4430 echo "$as_me:4430: checking if you want to build shared libraries" >&5
4431 echo $ECHO_N "checking if you want to build shared libraries... $ECHO_C" >&6
4432
4433 # Check whether --with-shared or --without-shared was given.
4434 if test "${with_shared+set}" = set; then
4435   withval="$with_shared"
4436   with_shared=$withval
4437 else
4438   with_shared=no
4439 fi;
4440 echo "$as_me:4440: result: $with_shared" >&5
4441 echo "${ECHO_T}$with_shared" >&6
4442 test "x$with_shared" = "xyes" && cf_list_models="$cf_list_models shared"
4443
4444 echo "$as_me:4444: checking if you want to build static libraries" >&5
4445 echo $ECHO_N "checking if you want to build static libraries... $ECHO_C" >&6
4446
4447 # Check whether --with-normal or --without-normal was given.
4448 if test "${with_normal+set}" = set; then
4449   withval="$with_normal"
4450   with_normal=$withval
4451 else
4452   with_normal=yes
4453 fi;
4454 echo "$as_me:4454: result: $with_normal" >&5
4455 echo "${ECHO_T}$with_normal" >&6
4456 test "x$with_normal" = "xyes" && cf_list_models="$cf_list_models normal"
4457
4458 echo "$as_me:4458: checking if you want to build debug libraries" >&5
4459 echo $ECHO_N "checking if you want to build debug libraries... $ECHO_C" >&6
4460
4461 # Check whether --with-debug or --without-debug was given.
4462 if test "${with_debug+set}" = set; then
4463   withval="$with_debug"
4464   with_debug=$withval
4465 else
4466   with_debug=yes
4467 fi;
4468 echo "$as_me:4468: result: $with_debug" >&5
4469 echo "${ECHO_T}$with_debug" >&6
4470 test "x$with_debug" = "xyes" && cf_list_models="$cf_list_models debug"
4471
4472 echo "$as_me:4472: checking if you want to build profiling libraries" >&5
4473 echo $ECHO_N "checking if you want to build profiling libraries... $ECHO_C" >&6
4474
4475 # Check whether --with-profile or --without-profile was given.
4476 if test "${with_profile+set}" = set; then
4477   withval="$with_profile"
4478   with_profile=$withval
4479 else
4480   with_profile=no
4481 fi;
4482 echo "$as_me:4482: result: $with_profile" >&5
4483 echo "${ECHO_T}$with_profile" >&6
4484 test "x$with_profile" = "xyes" && cf_list_models="$cf_list_models profile"
4485
4486 fi
4487
4488 ###############################################################################
4489
4490 echo "$as_me:4490: checking for specified models" >&5
4491 echo $ECHO_N "checking for specified models... $ECHO_C" >&6
4492 test -z "$cf_list_models" && cf_list_models=normal
4493 test "$with_libtool" != "no" && cf_list_models=libtool
4494 echo "$as_me:4494: result: $cf_list_models" >&5
4495 echo "${ECHO_T}$cf_list_models" >&6
4496
4497 ### Use the first model as the default, and save its suffix for use in building
4498 ### up test-applications.
4499 echo "$as_me:4499: checking for default model" >&5
4500 echo $ECHO_N "checking for default model... $ECHO_C" >&6
4501 DFT_LWR_MODEL=`echo "$cf_list_models" | $AWK '{print $1}'`
4502 echo "$as_me:4502: result: $DFT_LWR_MODEL" >&5
4503 echo "${ECHO_T}$DFT_LWR_MODEL" >&6
4504
4505 DFT_UPR_MODEL=`echo "$DFT_LWR_MODEL" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
4506
4507 TICS_NAME=tic
4508
4509 TINFO_NAME=tinfo
4510
4511 LIB_NAME=ncurses
4512
4513 LIB_DIR=../lib
4514 LIB_2ND=../../lib
4515
4516 echo "$as_me:4516: checking if you want to have a library-prefix" >&5
4517 echo $ECHO_N "checking if you want to have a library-prefix... $ECHO_C" >&6
4518
4519 # Check whether --with-lib-prefix or --without-lib-prefix was given.
4520 if test "${with_lib_prefix+set}" = set; then
4521   withval="$with_lib_prefix"
4522   with_lib_prefix=$withval
4523 else
4524   with_lib_prefix=auto
4525 fi;
4526 echo "$as_me:4526: result: $with_lib_prefix" >&5
4527 echo "${ECHO_T}$with_lib_prefix" >&6
4528
4529 if test $with_lib_prefix = auto
4530 then
4531
4532         case $cf_cv_system_name in #(vi
4533         OS/2*|os2*) #(vi
4534         LIB_PREFIX=''
4535         ;;
4536         *)      LIB_PREFIX='lib'
4537         ;;
4538         esac
4539 cf_prefix=$LIB_PREFIX
4540
4541 elif test $with_lib_prefix = no
4542 then
4543         LIB_PREFIX=
4544 else
4545         LIB_PREFIX=$with_lib_prefix
4546 fi
4547
4548 LIB_SUFFIX=
4549
4550         echo "$as_me:4550: checking for PATH separator" >&5
4551 echo $ECHO_N "checking for PATH separator... $ECHO_C" >&6
4552         case $cf_cv_system_name in
4553         os2*)   PATH_SEPARATOR=';'  ;;
4554         *)      ${PATH_SEPARATOR:=':'}  ;;
4555         esac
4556
4557         echo "$as_me:4557: result: $PATH_SEPARATOR" >&5
4558 echo "${ECHO_T}$PATH_SEPARATOR" >&6
4559
4560 ###############################################################################
4561
4562 echo "$as_me:4562: checking if you want to build a separate terminfo library" >&5
4563 echo $ECHO_N "checking if you want to build a separate terminfo library... $ECHO_C" >&6
4564
4565 # Check whether --with-termlib or --without-termlib was given.
4566 if test "${with_termlib+set}" = set; then
4567   withval="$with_termlib"
4568   with_termlib=$withval
4569 else
4570   with_termlib=no
4571 fi;
4572 echo "$as_me:4572: result: $with_termlib" >&5
4573 echo "${ECHO_T}$with_termlib" >&6
4574
4575 echo "$as_me:4575: checking if you want to build a separate tic library" >&5
4576 echo $ECHO_N "checking if you want to build a separate tic library... $ECHO_C" >&6
4577
4578 # Check whether --with-ticlib or --without-ticlib was given.
4579 if test "${with_ticlib+set}" = set; then
4580   withval="$with_ticlib"
4581   with_ticlib=$withval
4582 else
4583   with_ticlib=no
4584 fi;
4585 echo "$as_me:4585: result: $with_ticlib" >&5
4586 echo "${ECHO_T}$with_ticlib" >&6
4587
4588 ### Checks for special libraries, must be done up-front.
4589 SHLIB_LIST=""
4590
4591 echo "$as_me:4591: checking if you want to link with the GPM mouse library" >&5
4592 echo $ECHO_N "checking if you want to link with the GPM mouse library... $ECHO_C" >&6
4593
4594 # Check whether --with-gpm or --without-gpm was given.
4595 if test "${with_gpm+set}" = set; then
4596   withval="$with_gpm"
4597   with_gpm=$withval
4598 else
4599   with_gpm=maybe
4600 fi;
4601 echo "$as_me:4601: result: $with_gpm" >&5
4602 echo "${ECHO_T}$with_gpm" >&6
4603
4604 if test "$with_gpm" != no ; then
4605         echo "$as_me:4605: checking for gpm.h" >&5
4606 echo $ECHO_N "checking for gpm.h... $ECHO_C" >&6
4607 if test "${ac_cv_header_gpm_h+set}" = set; then
4608   echo $ECHO_N "(cached) $ECHO_C" >&6
4609 else
4610   cat >conftest.$ac_ext <<_ACEOF
4611 #line 4611 "configure"
4612 #include "confdefs.h"
4613 #include <gpm.h>
4614 _ACEOF
4615 if { (eval echo "$as_me:4615: \"$ac_cpp conftest.$ac_ext\"") >&5
4616   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4617   ac_status=$?
4618   egrep -v '^ *\+' conftest.er1 >conftest.err
4619   rm -f conftest.er1
4620   cat conftest.err >&5
4621   echo "$as_me:4621: \$? = $ac_status" >&5
4622   (exit $ac_status); } >/dev/null; then
4623   if test -s conftest.err; then
4624     ac_cpp_err=$ac_c_preproc_warn_flag
4625   else
4626     ac_cpp_err=
4627   fi
4628 else
4629   ac_cpp_err=yes
4630 fi
4631 if test -z "$ac_cpp_err"; then
4632   ac_cv_header_gpm_h=yes
4633 else
4634   echo "$as_me: failed program was:" >&5
4635   cat conftest.$ac_ext >&5
4636   ac_cv_header_gpm_h=no
4637 fi
4638 rm -f conftest.err conftest.$ac_ext
4639 fi
4640 echo "$as_me:4640: result: $ac_cv_header_gpm_h" >&5
4641 echo "${ECHO_T}$ac_cv_header_gpm_h" >&6
4642 if test $ac_cv_header_gpm_h = yes; then
4643
4644 cat >>confdefs.h <<\EOF
4645 #define HAVE_GPM_H 1
4646 EOF
4647
4648                 if test "$with_gpm" != yes && test "$with_gpm" != maybe ; then
4649                         test -n "$verbose" && echo "    assuming we really have GPM library" 1>&6
4650
4651 echo "${as_me:-configure}:4651: testing assuming we really have GPM library ..." 1>&5
4652
4653 cat >>confdefs.h <<\EOF
4654 #define HAVE_LIBGPM 1
4655 EOF
4656
4657                 else
4658                         echo "$as_me:4658: checking for Gpm_Open in -lgpm" >&5
4659 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
4660 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
4661   echo $ECHO_N "(cached) $ECHO_C" >&6
4662 else
4663   ac_check_lib_save_LIBS=$LIBS
4664 LIBS="-lgpm  $LIBS"
4665 cat >conftest.$ac_ext <<_ACEOF
4666 #line 4666 "configure"
4667 #include "confdefs.h"
4668
4669 /* Override any gcc2 internal prototype to avoid an error.  */
4670 #ifdef __cplusplus
4671 extern "C"
4672 #endif
4673 /* We use char because int might match the return type of a gcc2
4674    builtin and then its argument prototype would still apply.  */
4675 char Gpm_Open ();
4676 int
4677 main ()
4678 {
4679 Gpm_Open ();
4680   ;
4681   return 0;
4682 }
4683 _ACEOF
4684 rm -f conftest.$ac_objext conftest$ac_exeext
4685 if { (eval echo "$as_me:4685: \"$ac_link\"") >&5
4686   (eval $ac_link) 2>&5
4687   ac_status=$?
4688   echo "$as_me:4688: \$? = $ac_status" >&5
4689   (exit $ac_status); } &&
4690          { ac_try='test -s conftest$ac_exeext'
4691   { (eval echo "$as_me:4691: \"$ac_try\"") >&5
4692   (eval $ac_try) 2>&5
4693   ac_status=$?
4694   echo "$as_me:4694: \$? = $ac_status" >&5
4695   (exit $ac_status); }; }; then
4696   ac_cv_lib_gpm_Gpm_Open=yes
4697 else
4698   echo "$as_me: failed program was:" >&5
4699 cat conftest.$ac_ext >&5
4700 ac_cv_lib_gpm_Gpm_Open=no
4701 fi
4702 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4703 LIBS=$ac_check_lib_save_LIBS
4704 fi
4705 echo "$as_me:4705: result: $ac_cv_lib_gpm_Gpm_Open" >&5
4706 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
4707 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
4708   :
4709 else
4710
4711                                 { { echo "$as_me:4711: error: Cannot link with GPM library" >&5
4712 echo "$as_me: error: Cannot link with GPM library" >&2;}
4713    { (exit 1); exit 1; }; }
4714                 fi
4715                 with_gpm=yes
4716
4717 fi
4718
4719 else
4720
4721                 test "$with_gpm" != maybe && { echo "$as_me:4721: WARNING: Cannot find GPM header" >&5
4722 echo "$as_me: WARNING: Cannot find GPM header" >&2;}
4723                 with_gpm=no
4724
4725 fi
4726
4727 fi
4728
4729 if test "$with_gpm" != no ; then
4730         echo "$as_me:4730: checking if you want to load GPM dynamically" >&5
4731 echo $ECHO_N "checking if you want to load GPM dynamically... $ECHO_C" >&6
4732
4733 # Check whether --with-dlsym or --without-dlsym was given.
4734 if test "${with_dlsym+set}" = set; then
4735   withval="$with_dlsym"
4736   with_dlsym=$withval
4737 else
4738   with_dlsym=yes
4739 fi;
4740         echo "$as_me:4740: result: $with_dlsym" >&5
4741 echo "${ECHO_T}$with_dlsym" >&6
4742         if test "x$with_dlsym" = xyes ; then
4743
4744 cf_have_dlsym=no
4745 echo "$as_me:4745: checking for dlsym" >&5
4746 echo $ECHO_N "checking for dlsym... $ECHO_C" >&6
4747 if test "${ac_cv_func_dlsym+set}" = set; then
4748   echo $ECHO_N "(cached) $ECHO_C" >&6
4749 else
4750   cat >conftest.$ac_ext <<_ACEOF
4751 #line 4751 "configure"
4752 #include "confdefs.h"
4753 /* System header to define __stub macros and hopefully few prototypes,
4754     which can conflict with char dlsym (); below.  */
4755 #include <assert.h>
4756 /* Override any gcc2 internal prototype to avoid an error.  */
4757 #ifdef __cplusplus
4758 extern "C"
4759 #endif
4760 /* We use char because int might match the return type of a gcc2
4761    builtin and then its argument prototype would still apply.  */
4762 char dlsym ();
4763 char (*f) ();
4764
4765 int
4766 main ()
4767 {
4768 /* The GNU C library defines this for functions which it implements
4769     to always fail with ENOSYS.  Some functions are actually named
4770     something starting with __ and the normal name is an alias.  */
4771 #if defined (__stub_dlsym) || defined (__stub___dlsym)
4772 choke me
4773 #else
4774 f = dlsym; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
4775 #endif
4776
4777   ;
4778   return 0;
4779 }
4780 _ACEOF
4781 rm -f conftest.$ac_objext conftest$ac_exeext
4782 if { (eval echo "$as_me:4782: \"$ac_link\"") >&5
4783   (eval $ac_link) 2>&5
4784   ac_status=$?
4785   echo "$as_me:4785: \$? = $ac_status" >&5
4786   (exit $ac_status); } &&
4787          { ac_try='test -s conftest$ac_exeext'
4788   { (eval echo "$as_me:4788: \"$ac_try\"") >&5
4789   (eval $ac_try) 2>&5
4790   ac_status=$?
4791   echo "$as_me:4791: \$? = $ac_status" >&5
4792   (exit $ac_status); }; }; then
4793   ac_cv_func_dlsym=yes
4794 else
4795   echo "$as_me: failed program was:" >&5
4796 cat conftest.$ac_ext >&5
4797 ac_cv_func_dlsym=no
4798 fi
4799 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4800 fi
4801 echo "$as_me:4801: result: $ac_cv_func_dlsym" >&5
4802 echo "${ECHO_T}$ac_cv_func_dlsym" >&6
4803 if test $ac_cv_func_dlsym = yes; then
4804   cf_have_dlsym=yes
4805 else
4806
4807 cf_have_libdl=no
4808 echo "$as_me:4808: checking for dlsym in -ldl" >&5
4809 echo $ECHO_N "checking for dlsym in -ldl... $ECHO_C" >&6
4810 if test "${ac_cv_lib_dl_dlsym+set}" = set; then
4811   echo $ECHO_N "(cached) $ECHO_C" >&6
4812 else
4813   ac_check_lib_save_LIBS=$LIBS
4814 LIBS="-ldl  $LIBS"
4815 cat >conftest.$ac_ext <<_ACEOF
4816 #line 4816 "configure"
4817 #include "confdefs.h"
4818
4819 /* Override any gcc2 internal prototype to avoid an error.  */
4820 #ifdef __cplusplus
4821 extern "C"
4822 #endif
4823 /* We use char because int might match the return type of a gcc2
4824    builtin and then its argument prototype would still apply.  */
4825 char dlsym ();
4826 int
4827 main ()
4828 {
4829 dlsym ();
4830   ;
4831   return 0;
4832 }
4833 _ACEOF
4834 rm -f conftest.$ac_objext conftest$ac_exeext
4835 if { (eval echo "$as_me:4835: \"$ac_link\"") >&5
4836   (eval $ac_link) 2>&5
4837   ac_status=$?
4838   echo "$as_me:4838: \$? = $ac_status" >&5
4839   (exit $ac_status); } &&
4840          { ac_try='test -s conftest$ac_exeext'
4841   { (eval echo "$as_me:4841: \"$ac_try\"") >&5
4842   (eval $ac_try) 2>&5
4843   ac_status=$?
4844   echo "$as_me:4844: \$? = $ac_status" >&5
4845   (exit $ac_status); }; }; then
4846   ac_cv_lib_dl_dlsym=yes
4847 else
4848   echo "$as_me: failed program was:" >&5
4849 cat conftest.$ac_ext >&5
4850 ac_cv_lib_dl_dlsym=no
4851 fi
4852 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4853 LIBS=$ac_check_lib_save_LIBS
4854 fi
4855 echo "$as_me:4855: result: $ac_cv_lib_dl_dlsym" >&5
4856 echo "${ECHO_T}$ac_cv_lib_dl_dlsym" >&6
4857 if test $ac_cv_lib_dl_dlsym = yes; then
4858
4859         cf_have_dlsym=yes
4860         cf_have_libdl=yes
4861 fi
4862
4863 fi
4864
4865 if test "$cf_have_dlsym" = yes ; then
4866         test "$cf_have_libdl" = yes && LIBS="-ldl $LIBS"
4867
4868         echo "$as_me:4868: checking whether able to link to dl*() functions" >&5
4869 echo $ECHO_N "checking whether able to link to dl*() functions... $ECHO_C" >&6
4870         cat >conftest.$ac_ext <<_ACEOF
4871 #line 4871 "configure"
4872 #include "confdefs.h"
4873 #include <dlfcn.h>
4874 int
4875 main ()
4876 {
4877
4878                 void *obj;
4879                 if ((obj = dlopen("filename", 0)) != 0) {
4880                         if (dlsym(obj, "symbolname") == 0) {
4881                         dlclose(obj);
4882                         }