2 # From configure.in Revision: 1.74 .
3 # Guess values for system-dependent variables and create Makefiles.
4 # Generated by Autoconf 2.52.20200111.
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.
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
18 # Sed expression to map a string onto a valid variable name.
19 as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
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"
24 # Be Bourne compatible
25 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
28 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
32 # Name of the executable.
33 as_me=`echo "$0" |sed 's,.*[\\/],,'`
35 if expr a : '\(a\)' >/dev/null 2>&1; then
41 rm -f conf$$ conf$$.exe 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
52 elif ln conf$$.file conf$$ 2>/dev/null; then
57 rm -f conf$$ conf$$.exe conf$$.file
59 as_executable_p="test -f"
61 # Support unset when possible.
62 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
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; }
79 # We need space, tab and new line, in precisely that order.
85 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
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`
97 ac_default_prefix=/usr/local
101 SHELL=${CONFIG_SHELL-/bin/sh}
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}
108 ac_unique_file="gen/gen.c"
109 # Factoring default headers for most tests.
110 ac_includes_default="\
113 # include <sys/types.h>
116 # include <sys/stat.h>
127 # if !STDC_HEADERS && HAVE_MEMORY_H
133 # include <strings.h>
136 # include <inttypes.h>
146 # Initialize some variables set by options.
148 ac_init_version=false
149 # The variables have the same names as the options, with
150 # dashes changed to underlines.
158 program_transform_name=s,x,x,
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 runstatedir='${localstatedir}/run'
180 libdir='${exec_prefix}/lib'
181 includedir='${prefix}/include'
182 oldincludedir='/usr/include'
183 infodir='${datarootdir}/info'
184 mandir='${datarootdir}/man'
186 # Identity of this package.
196 # If the previous option needs an argument, assign it.
197 if test -n "$ac_prev"; then
198 eval "$ac_prev=\$ac_option"
203 ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
205 # Accept the important Cygnus configure options, so we can diagnose typos.
209 -bindir | --bindir | --bindi | --bind | --bin | --bi)
211 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
214 -build | --build | --buil | --bui | --bu)
215 ac_prev=build_alias ;;
216 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
217 build_alias=$ac_optarg ;;
219 -cache-file | --cache-file | --cache-fil | --cache-fi \
220 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
221 ac_prev=cache_file ;;
222 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
223 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
224 cache_file=$ac_optarg ;;
227 cache_file=config.cache ;;
229 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
231 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
233 datadir=$ac_optarg ;;
235 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
236 | --dataroo | --dataro | --datar)
237 ac_prev=datarootdir ;;
238 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
239 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
240 datarootdir=$ac_optarg ;;
242 -disable-* | --disable-*)
243 ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
244 # Reject names that are not valid shell variable names.
245 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
246 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
247 { (exit 1); exit 1; }; }
248 ac_feature=`echo $ac_feature | sed 's/-/_/g'`
249 eval "enable_$ac_feature=no" ;;
251 -enable-* | --enable-*)
252 ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
253 # Reject names that are not valid shell variable names.
254 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
255 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
256 { (exit 1); exit 1; }; }
257 ac_feature=`echo $ac_feature | sed 's/-/_/g'`
259 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
262 eval "enable_$ac_feature='$ac_optarg'" ;;
264 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
265 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
266 | --exec | --exe | --ex)
267 ac_prev=exec_prefix ;;
268 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
269 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
270 | --exec=* | --exe=* | --ex=*)
271 exec_prefix=$ac_optarg ;;
273 -gas | --gas | --ga | --g)
274 # Obsolete; use --with-gas.
277 -help | --help | --hel | --he | -h)
279 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
280 ac_init_help=recursive ;;
281 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
282 ac_init_help=short ;;
284 -host | --host | --hos | --ho)
285 ac_prev=host_alias ;;
286 -host=* | --host=* | --hos=* | --ho=*)
287 host_alias=$ac_optarg ;;
289 -includedir | --includedir | --includedi | --included | --include \
290 | --includ | --inclu | --incl | --inc)
291 ac_prev=includedir ;;
292 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
293 | --includ=* | --inclu=* | --incl=* | --inc=*)
294 includedir=$ac_optarg ;;
296 -infodir | --infodir | --infodi | --infod | --info | --inf)
298 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
299 infodir=$ac_optarg ;;
301 -libdir | --libdir | --libdi | --libd)
303 -libdir=* | --libdir=* | --libdi=* | --libd=*)
306 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
307 | --libexe | --libex | --libe)
308 ac_prev=libexecdir ;;
309 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
310 | --libexe=* | --libex=* | --libe=*)
311 libexecdir=$ac_optarg ;;
313 -localstatedir | --localstatedir | --localstatedi | --localstated \
314 | --localstate | --localstat | --localsta | --localst \
315 | --locals | --local | --loca | --loc | --lo)
316 ac_prev=localstatedir ;;
317 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
318 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
319 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
320 localstatedir=$ac_optarg ;;
322 -runstatedir | --runstatedir | --runstatedi | --runstated \
323 | --runstate | --runstat | --runsta | --runst \
324 | --runs | --run | --ru)
325 ac_prev=runstatedir ;;
326 -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \
327 | --runstate=* | --runstat=* | --runsta=* | --runst=* \
328 | --runs=* | --run=* | --ru=*)
329 runstatedir=$ac_optarg ;;
331 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
333 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
337 # Obsolete; use --without-fp.
340 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
344 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
345 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
348 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
349 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
350 | --oldin | --oldi | --old | --ol | --o)
351 ac_prev=oldincludedir ;;
352 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
353 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
354 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
355 oldincludedir=$ac_optarg ;;
357 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
359 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
362 -program-prefix | --program-prefix | --program-prefi | --program-pref \
363 | --program-pre | --program-pr | --program-p)
364 ac_prev=program_prefix ;;
365 -program-prefix=* | --program-prefix=* | --program-prefi=* \
366 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
367 program_prefix=$ac_optarg ;;
369 -program-suffix | --program-suffix | --program-suffi | --program-suff \
370 | --program-suf | --program-su | --program-s)
371 ac_prev=program_suffix ;;
372 -program-suffix=* | --program-suffix=* | --program-suffi=* \
373 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
374 program_suffix=$ac_optarg ;;
376 -program-transform-name | --program-transform-name \
377 | --program-transform-nam | --program-transform-na \
378 | --program-transform-n | --program-transform- \
379 | --program-transform | --program-transfor \
380 | --program-transfo | --program-transf \
381 | --program-trans | --program-tran \
382 | --progr-tra | --program-tr | --program-t)
383 ac_prev=program_transform_name ;;
384 -program-transform-name=* | --program-transform-name=* \
385 | --program-transform-nam=* | --program-transform-na=* \
386 | --program-transform-n=* | --program-transform-=* \
387 | --program-transform=* | --program-transfor=* \
388 | --program-transfo=* | --program-transf=* \
389 | --program-trans=* | --program-tran=* \
390 | --progr-tra=* | --program-tr=* | --program-t=*)
391 program_transform_name=$ac_optarg ;;
393 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
394 | -silent | --silent | --silen | --sile | --sil)
397 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
399 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
401 sbindir=$ac_optarg ;;
403 -sharedstatedir | --sharedstatedir | --sharedstatedi \
404 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
405 | --sharedst | --shareds | --shared | --share | --shar \
407 ac_prev=sharedstatedir ;;
408 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
409 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
410 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
412 sharedstatedir=$ac_optarg ;;
414 -site | --site | --sit)
416 -site=* | --site=* | --sit=*)
419 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
421 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
424 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
425 | --syscon | --sysco | --sysc | --sys | --sy)
426 ac_prev=sysconfdir ;;
427 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
428 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
429 sysconfdir=$ac_optarg ;;
431 -target | --target | --targe | --targ | --tar | --ta | --t)
432 ac_prev=target_alias ;;
433 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
434 target_alias=$ac_optarg ;;
436 -v | -verbose | --verbose | --verbos | --verbo | --verb)
439 -version | --version | --versio | --versi | --vers | -V)
443 ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
444 # Reject names that are not valid shell variable names.
445 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
446 { echo "$as_me: error: invalid package name: $ac_package" >&2
447 { (exit 1); exit 1; }; }
448 ac_package=`echo $ac_package| sed 's/-/_/g'`
450 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
453 eval "with_$ac_package='$ac_optarg'" ;;
455 -without-* | --without-*)
456 ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
457 # Reject names that are not valid shell variable names.
458 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
459 { echo "$as_me: error: invalid package name: $ac_package" >&2
460 { (exit 1); exit 1; }; }
461 ac_package=`echo $ac_package | sed 's/-/_/g'`
462 eval "with_$ac_package=no" ;;
465 # Obsolete; use --with-x.
468 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
469 | --x-incl | --x-inc | --x-in | --x-i)
470 ac_prev=x_includes ;;
471 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
472 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
473 x_includes=$ac_optarg ;;
475 -x-libraries | --x-libraries | --x-librarie | --x-librari \
476 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
477 ac_prev=x_libraries ;;
478 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
479 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
480 x_libraries=$ac_optarg ;;
482 -*) { echo "$as_me: error: unrecognized option: $ac_option
483 Try \`$0 --help' for more information." >&2
484 { (exit 1); exit 1; }; }
488 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
489 # Reject names that are not valid shell variable names.
490 expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
491 { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
492 { (exit 1); exit 1; }; }
493 ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
494 eval "$ac_envvar='$ac_optarg'"
498 # FIXME: should be removed in autoconf 3.0.
499 echo "$as_me: WARNING: you should use --build, --host, --target" >&2
500 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
501 echo "$as_me: WARNING: invalid host type: $ac_option" >&2
502 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
508 if test -n "$ac_prev"; then
509 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
510 { echo "$as_me: error: missing argument to $ac_option" >&2
511 { (exit 1); exit 1; }; }
514 # Be sure to have absolute paths.
515 for ac_var in exec_prefix prefix
517 eval ac_val=$`echo $ac_var`
519 [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
520 *) { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
521 { (exit 1); exit 1; }; };;
525 # Be sure to have absolute paths.
526 for ac_var in bindir sbindir libexecdir datarootdir datadir sysconfdir sharedstatedir \
527 localstatedir libdir includedir oldincludedir infodir mandir
529 eval ac_val=$`echo $ac_var`
531 [\\/$]* | ?:[\\/]* ) ;;
532 *) { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
533 { (exit 1); exit 1; }; };;
537 # There might be people who depend on the old broken behavior: `$host'
538 # used to hold the argument of --host etc.
543 # FIXME: should be removed in autoconf 3.0.
544 if test "x$host_alias" != x; then
545 if test "x$build_alias" = x; then
546 cross_compiling=maybe
547 echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
548 If a cross compiler is detected then cross compile mode will be used." >&2
549 elif test "x$build_alias" != "x$host_alias"; then
555 test -n "$host_alias" && ac_tool_prefix=$host_alias-
557 test "$silent" = yes && exec 6>/dev/null
559 # Find the source files, if location was not specified.
560 if test -z "$srcdir"; then
561 ac_srcdir_defaulted=yes
562 # Try the directory containing this script, then its parent.
564 ac_confdir=`echo "$ac_prog" | sed 's%[\\/][^\\/][^\\/]*$%%'`
565 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
567 if test ! -r $srcdir/$ac_unique_file; then
571 ac_srcdir_defaulted=no
573 if test ! -r $srcdir/$ac_unique_file; then
574 if test "$ac_srcdir_defaulted" = yes; then
575 { echo "$as_me: error: cannot find sources in $ac_confdir or .." >&2
576 { (exit 1); exit 1; }; }
578 { echo "$as_me: error: cannot find sources in $srcdir" >&2
579 { (exit 1); exit 1; }; }
582 srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
583 ac_env_build_alias_set=${build_alias+set}
584 ac_env_build_alias_value=$build_alias
585 ac_cv_env_build_alias_set=${build_alias+set}
586 ac_cv_env_build_alias_value=$build_alias
587 ac_env_host_alias_set=${host_alias+set}
588 ac_env_host_alias_value=$host_alias
589 ac_cv_env_host_alias_set=${host_alias+set}
590 ac_cv_env_host_alias_value=$host_alias
591 ac_env_target_alias_set=${target_alias+set}
592 ac_env_target_alias_value=$target_alias
593 ac_cv_env_target_alias_set=${target_alias+set}
594 ac_cv_env_target_alias_value=$target_alias
595 ac_env_CC_set=${CC+set}
597 ac_cv_env_CC_set=${CC+set}
598 ac_cv_env_CC_value=$CC
599 ac_env_CFLAGS_set=${CFLAGS+set}
600 ac_env_CFLAGS_value=$CFLAGS
601 ac_cv_env_CFLAGS_set=${CFLAGS+set}
602 ac_cv_env_CFLAGS_value=$CFLAGS
603 ac_env_LDFLAGS_set=${LDFLAGS+set}
604 ac_env_LDFLAGS_value=$LDFLAGS
605 ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
606 ac_cv_env_LDFLAGS_value=$LDFLAGS
607 ac_env_CPPFLAGS_set=${CPPFLAGS+set}
608 ac_env_CPPFLAGS_value=$CPPFLAGS
609 ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
610 ac_cv_env_CPPFLAGS_value=$CPPFLAGS
611 ac_env_CPP_set=${CPP+set}
612 ac_env_CPP_value=$CPP
613 ac_cv_env_CPP_set=${CPP+set}
614 ac_cv_env_CPP_value=$CPP
617 # Report the --help message.
619 if test "$ac_init_help" = "long"; then
620 # Omit some internal or obsolete options to make the list less imposing.
621 # This message is too long to be a string in the A/UX 3.1 sh.
623 \`configure' configures this package to adapt to many kinds of systems.
625 Usage: $0 [OPTION]... [VAR=VALUE]...
627 To assign environment variables (e.g., CC, CFLAGS...), specify them as
628 VAR=VALUE. See below for descriptions of some of the useful variables.
630 Defaults for the options are specified in brackets.
633 -h, --help display this help and exit
634 --help=short display options specific to this package
635 --help=recursive display the short help of all the included packages
636 -V, --version display version information and exit
637 -q, --quiet, --silent do not print \`checking...' messages
638 --cache-file=FILE cache test results in FILE [disabled]
639 -C, --config-cache alias for \`--cache-file=config.cache'
640 -n, --no-create do not create output files
641 --srcdir=DIR find the sources in DIR [configure dir or \`..']
646 Installation directories:
647 --prefix=PREFIX install architecture-independent files in PREFIX
649 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
652 By default, \`make install' will install all the files in
653 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
654 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
655 for instance \`--prefix=\$HOME'.
657 For better control, use the options below.
659 Fine tuning of the installation directories:
660 --bindir=DIR user executables [EPREFIX/bin]
661 --sbindir=DIR system admin executables [EPREFIX/sbin]
662 --libexecdir=DIR program executables [EPREFIX/libexec]
663 --datarootdir=DIR read-only architecture-independent data [PREFIX/share]
664 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
665 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
666 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
667 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
668 --runstatedir=DIR extra definition of runtime data [LOCALSTATEDIR/run]
669 --libdir=DIR object code libraries [EPREFIX/lib]
670 --includedir=DIR C header files [PREFIX/include]
671 --oldincludedir=DIR C header files for non-gcc [/usr/include]
672 --infodir=DIR info documentation [DATAROOTDIR/info]
673 --mandir=DIR man documentation [DATAROOTDIR/man]
679 --program-prefix=PREFIX prepend PREFIX to installed program names
680 --program-suffix=SUFFIX append SUFFIX to installed program names
681 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
684 --build=BUILD configure for building on BUILD [guessed]
685 --host=HOST build programs to run on HOST [BUILD]
686 --target=TARGET configure for building compilers for TARGET [HOST]
690 if test -n "$ac_init_help"; then
695 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
696 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
699 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
700 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
703 --with-system-type=XXX test: override derived host system-type
704 --disable-stripping do not strip (debug info) installed executables
705 --with-pkg-config{=path} enable/disable use of pkg-config
706 --with-pkg-config-libdir=XXX use given directory for installing pc-files
707 --without-tests suppress build with test-programs
708 --enable-mixed-case tic should assume mixed-case filenames
709 --with-install-prefix prefixes actual install-location ($DESTDIR)
710 Build-Tools Needed to Compile Temporary Applications for Cross-compiling:
711 --with-build-cc=XXX the build C compiler ($BUILD_CC)
712 --with-build-cpp=XXX the build C preprocessor ($BUILD_CPP)
713 --with-build-cflags=XXX the build C compiler-flags ($BUILD_CFLAGS)
714 --with-build-cppflags=XXX the build C preprocessor-flags ($BUILD_CPPFLAGS)
715 --with-build-ldflags=XXX the build linker-flags ($BUILD_LDFLAGS)
716 --with-build-libs=XXX the build libraries (${BUILD_LIBS})
717 Options to Specify the Libraries Built/Used:
718 --with-shared generate shared C-objects (needed for --with-ada-sharedlib)
719 --with-curses-dir=DIR directory in which (n)curses is installed
720 --enable-widec compile with wide-char/UTF-8 code
721 --with-lib-prefix override library-prefix
722 --with-shlib-version=X Specify rel or abi version for shared libs
723 --enable-rpath-link link sample programs with rpath option
724 Fine-Tuning Your Configuration:
725 --enable-broken_linker compile with broken-linker support code
726 --disable-largefile omit support for large files
727 --with-rcs-ids compile-in RCS identifiers
729 --disable-ext-funcs disable function-extensions
730 --enable-const compile with extra/non-standard const
732 --without-develop disable development options
734 --with-pthread use POSIX thread library
735 --enable-weak-symbols enable weak-symbols for pthreads
736 --enable-reentrant compile with experimental reentrant code
737 --with-wrap-prefix=XXX override prefix used for public variables
738 Testing/development Options:
739 --disable-echo do not display "compiling" commands
740 --enable-warnings build: turn on GCC compiler warnings
741 --enable-assertions test: turn on generation of assertion code
742 --enable-expanded test: generate functions for certain macros
743 --disable-macros test: use functions rather than macros
744 --with-trace test: add trace() function to all models of ncurses
745 --disable-gnat-projects test: disable GNAT projects even if usable
746 Ada95 Binding Options:
747 --with-ada-compiler=CMD specify Ada95 compiler command (default gnatmake)
748 --with-ada-include=DIR Ada includes are in DIR (default: PREFIX/share/ada/adainclude)
749 --with-ada-objects=DIR Ada objects are in DIR (default: PREFIX/lib/ada/adalib)
750 --with-ada-sharedlib=soname build shared-library (requires GNAT projects)
751 --with-ada-libname=XXX override default Ada library-name
753 Some influential environment variables:
754 CC C compiler command
755 CFLAGS C compiler flags
756 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
757 nonstandard directory <lib dir>
758 CPPFLAGS C/C++ preprocessor flags, e.g. -I<include dir> if you have
759 headers in a nonstandard directory <include dir>
762 Use these variables to override the choices made by `configure' or to help
763 it to find libraries and programs with nonstandard names/locations.
768 if test "$ac_init_help" = "recursive"; then
769 # If there are subdirs, report their specific --help.
771 for ac_subdir in : $ac_subdirs_all; do test "x$ac_subdir" = x: && continue
773 # A "../" for each directory in /$ac_subdir.
774 ac_dots=`echo $ac_subdir |
775 sed 's,^\./,,;s,[^/]$,&/,;s,[^/]*/,../,g'`
778 .) # No --srcdir option. We are building in place.
779 ac_sub_srcdir=$srcdir ;;
780 [\\/]* | ?:[\\/]* ) # Absolute path.
781 ac_sub_srcdir=$srcdir/$ac_subdir ;;
783 ac_sub_srcdir=$ac_dots$srcdir/$ac_subdir ;;
786 # Check for guested configure; otherwise get Cygnus style configure.
787 if test -f $ac_sub_srcdir/configure.gnu; then
789 $SHELL $ac_sub_srcdir/configure.gnu --help=recursive
790 elif test -f $ac_sub_srcdir/configure; then
792 $SHELL $ac_sub_srcdir/configure --help=recursive
793 elif test -f $ac_sub_srcdir/configure.ac ||
794 test -f $ac_sub_srcdir/configure.in; then
798 echo "$as_me: WARNING: no configuration information is in $ac_subdir" >&2
804 test -n "$ac_init_help" && exit 0
805 if $ac_init_version; then
808 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
809 Free Software Foundation, Inc.
810 This configure script is free software; the Free Software Foundation
811 gives unlimited permission to copy, distribute and modify it.
817 This file contains any messages produced by compilers while
818 running configure, to aid debugging if configure makes a mistake.
820 It was created by $as_me, which was
821 generated by GNU Autoconf 2.52.20200111. Invocation command line was
832 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
833 uname -m = `(uname -m) 2>/dev/null || echo unknown`
834 uname -r = `(uname -r) 2>/dev/null || echo unknown`
835 uname -s = `(uname -s) 2>/dev/null || echo unknown`
836 uname -v = `(uname -v) 2>/dev/null || echo unknown`
838 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
839 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
841 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
842 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
843 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
844 hostinfo = `(hostinfo) 2>/dev/null || echo unknown`
845 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
846 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
847 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
861 # Keep a trace of the command line.
862 # Strip out --no-create and --no-recursion so they do not pile up.
863 # Also quote any args containing shell meta-characters.
869 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
870 | --no-cr | --no-c) ;;
871 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
872 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
873 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
874 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"`
875 ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
877 *) ac_configure_args="$ac_configure_args$ac_sep$ac_arg"
880 # Get rid of the leading space.
883 # When interrupted or exit'd, cleanup temporary files, and complete
884 # config.log. We remove comments because anyway the quotes in there
885 # would cause problems or look ugly.
887 # Save into config.log some information that might help in debugging.
889 echo "## ----------------- ##" >&5
890 echo "## Cache variables. ##" >&5
891 echo "## ----------------- ##" >&5
893 # The following way of writing the cache mishandles newlines in values,
896 case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
899 "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
900 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
904 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
908 sed "/^$/d" confdefs.h >conftest.log
909 if test -s conftest.log; then
911 echo "## ------------ ##" >&5
912 echo "## confdefs.h. ##" >&5
913 echo "## ------------ ##" >&5
918 test "$ac_signal" != 0 &&
919 echo "$as_me: caught signal $ac_signal" >&5
920 echo "$as_me: exit $exit_status" >&5
921 rm -rf conftest* confdefs* core core.* *.core conf$$* $ac_clean_files &&
924 for ac_signal in 1 2 13 15; do
925 trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
929 # confdefs.h avoids OS command line length limits that DEFS can exceed.
930 rm -rf conftest* confdefs.h
931 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
934 # Let the site file select an alternate cache file if it wants to.
935 # Prefer explicitly selected file to automatically selected ones.
936 if test -z "$CONFIG_SITE"; then
937 if test "x$prefix" != xNONE; then
938 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
940 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
943 for ac_site_file in $CONFIG_SITE; do
944 if test -r "$ac_site_file"; then
945 { echo "$as_me:945: loading site script $ac_site_file" >&5
946 echo "$as_me: loading site script $ac_site_file" >&6;}
947 cat "$ac_site_file" >&5
952 if test -r "$cache_file"; then
953 # Some versions of bash will fail to source /dev/null (special
954 # files actually), so we avoid doing that.
955 if test -f "$cache_file"; then
956 { echo "$as_me:956: loading cache $cache_file" >&5
957 echo "$as_me: loading cache $cache_file" >&6;}
959 [\\/]* | ?:[\\/]* ) . $cache_file;;
964 { echo "$as_me:964: creating cache $cache_file" >&5
965 echo "$as_me: creating cache $cache_file" >&6;}
969 # Check that the precious variables saved in the cache have kept the same
971 ac_cache_corrupted=false
972 for ac_var in `(set) 2>&1 |
973 sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
974 eval ac_old_set=\$ac_cv_env_${ac_var}_set
975 eval ac_new_set=\$ac_env_${ac_var}_set
976 eval ac_old_val="\$ac_cv_env_${ac_var}_value"
977 eval ac_new_val="\$ac_env_${ac_var}_value"
978 case $ac_old_set,$ac_new_set in
980 { echo "$as_me:980: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
981 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
982 ac_cache_corrupted=: ;;
984 { echo "$as_me:984: error: \`$ac_var' was not set in the previous run" >&5
985 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
986 ac_cache_corrupted=: ;;
989 if test "x$ac_old_val" != "x$ac_new_val"; then
990 { echo "$as_me:990: error: \`$ac_var' has changed since the previous run:" >&5
991 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
992 { echo "$as_me:992: former value: $ac_old_val" >&5
993 echo "$as_me: former value: $ac_old_val" >&2;}
994 { echo "$as_me:994: current value: $ac_new_val" >&5
995 echo "$as_me: current value: $ac_new_val" >&2;}
999 # Pass precious variables to config.status. It doesn't matter if
1000 # we pass some twice (in addition to the command line arguments).
1001 if test "$ac_new_set" = set; then
1003 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1004 ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"`
1005 ac_configure_args="$ac_configure_args '$ac_arg'"
1007 *) ac_configure_args="$ac_configure_args $ac_var=$ac_new_val"
1012 if $ac_cache_corrupted; then
1013 { echo "$as_me:1013: error: changes in the environment can compromise the build" >&5
1014 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1015 { { echo "$as_me:1015: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1016 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1017 { (exit 1); exit 1; }; }
1021 ac_cpp='$CPP $CPPFLAGS'
1022 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1023 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1024 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1025 ac_main_return=return
1027 case `echo "testing\c" 2>/dev/null; echo 1,2,3`,`echo -n testing 2>/dev/null; echo 1,2,3` in
1028 *c*,-n*) ECHO_N= ECHO_C= # newlines do not sed ;-) only broken shells would use this case anyway
1030 *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
1031 *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
1033 echo "#! $SHELL" >conftest.sh
1034 echo "exit 0" >>conftest.sh
1035 chmod +x conftest.sh
1036 if { (echo "$as_me:1036: PATH=\".;.\"; conftest.sh") >&5
1037 (PATH=".;."; conftest.sh) 2>&5
1039 echo "$as_me:1039: \$? = $ac_status" >&5
1040 (exit $ac_status); }; then
1041 ac_path_separator=';'
1045 PATH_SEPARATOR="$ac_path_separator"
1048 ac_config_headers="$ac_config_headers include/ncurses_cfg.h:include/ncurses_cfg.hin"
1053 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
1054 if test -f $ac_dir/install-sh; then
1056 ac_install_sh="$ac_aux_dir/install-sh -c"
1058 elif test -f $ac_dir/install.sh; then
1060 ac_install_sh="$ac_aux_dir/install.sh -c"
1062 elif test -f $ac_dir/shtool; then
1064 ac_install_sh="$ac_aux_dir/shtool install -c"
1068 if test -z "$ac_aux_dir"; then
1069 { { echo "$as_me:1069: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
1070 echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
1071 { (exit 1); exit 1; }; }
1073 ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1074 ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1075 ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
1077 # Make sure we can run config.sub.
1078 $ac_config_sub sun4 >/dev/null 2>&1 ||
1079 { { echo "$as_me:1079: error: cannot run $ac_config_sub" >&5
1080 echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1081 { (exit 1); exit 1; }; }
1083 echo "$as_me:1083: checking build system type" >&5
1084 echo $ECHO_N "checking build system type... $ECHO_C" >&6
1085 if test "${ac_cv_build+set}" = set; then
1086 echo $ECHO_N "(cached) $ECHO_C" >&6
1088 ac_cv_build_alias=$build_alias
1089 test -z "$ac_cv_build_alias" &&
1090 ac_cv_build_alias=`$ac_config_guess`
1091 test -z "$ac_cv_build_alias" &&
1092 { { echo "$as_me:1092: error: cannot guess build type; you must specify one" >&5
1093 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1094 { (exit 1); exit 1; }; }
1095 ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
1096 { { echo "$as_me:1096: error: $ac_config_sub $ac_cv_build_alias failed." >&5
1097 echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed." >&2;}
1098 { (exit 1); exit 1; }; }
1101 echo "$as_me:1101: result: $ac_cv_build" >&5
1102 echo "${ECHO_T}$ac_cv_build" >&6
1104 build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1105 build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1106 build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1108 echo "$as_me:1108: checking host system type" >&5
1109 echo $ECHO_N "checking host system type... $ECHO_C" >&6
1110 if test "${ac_cv_host+set}" = set; then
1111 echo $ECHO_N "(cached) $ECHO_C" >&6
1113 ac_cv_host_alias=$host_alias
1114 test -z "$ac_cv_host_alias" &&
1115 ac_cv_host_alias=$ac_cv_build_alias
1116 ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
1117 { { echo "$as_me:1117: error: $ac_config_sub $ac_cv_host_alias failed" >&5
1118 echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1119 { (exit 1); exit 1; }; }
1122 echo "$as_me:1122: result: $ac_cv_host" >&5
1123 echo "${ECHO_T}$ac_cv_host" >&6
1125 host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1126 host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1127 host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1129 if test -f $srcdir/config.guess || test -f $ac_aux_dir/config.guess ; then
1130 echo "$as_me:1130: checking target system type" >&5
1131 echo $ECHO_N "checking target system type... $ECHO_C" >&6
1132 if test "${ac_cv_target+set}" = set; then
1133 echo $ECHO_N "(cached) $ECHO_C" >&6
1135 ac_cv_target_alias=$target_alias
1136 test "x$ac_cv_target_alias" = "x" &&
1137 ac_cv_target_alias=$ac_cv_host_alias
1138 ac_cv_target=`$ac_config_sub $ac_cv_target_alias` ||
1139 { { echo "$as_me:1139: error: $ac_config_sub $ac_cv_target_alias failed" >&5
1140 echo "$as_me: error: $ac_config_sub $ac_cv_target_alias failed" >&2;}
1141 { (exit 1); exit 1; }; }
1144 echo "$as_me:1144: result: $ac_cv_target" >&5
1145 echo "${ECHO_T}$ac_cv_target" >&6
1146 target=$ac_cv_target
1147 target_cpu=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1148 target_vendor=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1149 target_os=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1151 # The aliases save the names the user supplied, while $host etc.
1152 # will get canonicalized.
1153 test -n "$target_alias" &&
1154 test "$program_prefix$program_suffix$program_transform_name" = \
1156 program_prefix=${target_alias}-
1157 system_name="$host_os"
1159 system_name="`(uname -s -r) 2>/dev/null`"
1160 if test -z "$system_name" ; then
1161 system_name="`(hostname) 2>/dev/null`"
1164 test -n "$system_name" &&
1165 cat >>confdefs.h <<EOF
1166 #define SYSTEM_NAME "$system_name"
1169 if test "${cf_cv_system_name+set}" = set; then
1170 echo $ECHO_N "(cached) $ECHO_C" >&6
1172 cf_cv_system_name="$system_name"
1175 test -z "$system_name" && system_name="$cf_cv_system_name"
1176 test -n "$cf_cv_system_name" && echo "$as_me:1176: result: Configuring for $cf_cv_system_name" >&5
1177 echo "${ECHO_T}Configuring for $cf_cv_system_name" >&6
1179 if test ".$system_name" != ".$cf_cv_system_name" ; then
1180 echo "$as_me:1180: result: Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&5
1181 echo "${ECHO_T}Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&6
1182 { { echo "$as_me:1182: error: \"Please remove config.cache and try again.\"" >&5
1183 echo "$as_me: error: \"Please remove config.cache and try again.\"" >&2;}
1184 { (exit 1); exit 1; }; }
1187 # Check whether --with-system-type or --without-system-type was given.
1188 if test "${with_system_type+set}" = set; then
1189 withval="$with_system_type"
1190 { echo "$as_me:1190: WARNING: overriding system type to $withval" >&5
1191 echo "$as_me: WARNING: overriding system type to $withval" >&2;}
1192 cf_cv_system_name=$withval
1197 ### Save the given $CFLAGS to allow user-override.
1198 cf_user_CFLAGS="$CFLAGS"
1200 ### Default install-location
1202 echo "$as_me:1202: checking for prefix" >&5
1203 echo $ECHO_N "checking for prefix... $ECHO_C" >&6
1204 if test "x$prefix" = "xNONE" ; then
1205 case "$cf_cv_system_name" in
1206 # non-vendor systems don't have a conflict
1207 (openbsd*|freebsd*|mirbsd*|linux*|cygwin*|msys*|k*bsd*-gnu|mingw*)
1210 (*) prefix=$ac_default_prefix
1214 echo "$as_me:1214: result: $prefix" >&5
1215 echo "${ECHO_T}$prefix" >&6
1217 if test "x$prefix" = "xNONE" ; then
1218 echo "$as_me:1218: checking for default include-directory" >&5
1219 echo $ECHO_N "checking for default include-directory... $ECHO_C" >&6
1220 test -n "$verbose" && echo 1>&6
1223 $includedir/ncurses \
1225 $prefix/include/ncurses \
1226 /usr/local/include \
1227 /usr/local/include/ncurses \
1229 /usr/include/ncurses
1231 cf_dir=`eval echo $cf_symbol`
1232 if test -f $cf_dir/curses.h ; then
1233 if ( fgrep NCURSES_VERSION $cf_dir/curses.h 2>&1 >/dev/null ) ; then
1234 includedir="$cf_symbol"
1235 test -n "$verbose" && echo $ac_n " found " 1>&6
1239 test -n "$verbose" && echo " tested $cf_dir" 1>&6
1241 echo "$as_me:1241: result: $includedir" >&5
1242 echo "${ECHO_T}$includedir" >&6
1245 ### Checks for programs.
1248 ac_cpp='$CPP $CPPFLAGS'
1249 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1250 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1251 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1252 ac_main_return=return
1253 if test -n "$ac_tool_prefix"; then
1254 for ac_prog in gnatgcc gcc cc
1256 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
1257 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
1258 echo "$as_me:1258: checking for $ac_word" >&5
1259 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1260 if test "${ac_cv_prog_CC+set}" = set; then
1261 echo $ECHO_N "(cached) $ECHO_C" >&6
1263 if test -n "$CC"; then
1264 ac_cv_prog_CC="$CC" # Let the user override the test.
1266 ac_save_IFS=$IFS; IFS=$ac_path_separator
1268 for ac_dir in $ac_dummy; do
1270 test -z "$ac_dir" && ac_dir=.
1271 $as_executable_p "$ac_dir/$ac_word" || continue
1272 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
1273 echo "$as_me:1273: found $ac_dir/$ac_word" >&5
1280 if test -n "$CC"; then
1281 echo "$as_me:1281: result: $CC" >&5
1282 echo "${ECHO_T}$CC" >&6
1284 echo "$as_me:1284: result: no" >&5
1285 echo "${ECHO_T}no" >&6
1288 test -n "$CC" && break
1291 if test -z "$CC"; then
1293 for ac_prog in gnatgcc gcc cc
1295 # Extract the first word of "$ac_prog", so it can be a program name with args.
1296 set dummy $ac_prog; ac_word=$2
1297 echo "$as_me:1297: checking for $ac_word" >&5
1298 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1299 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1300 echo $ECHO_N "(cached) $ECHO_C" >&6
1302 if test -n "$ac_ct_CC"; then
1303 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1305 ac_save_IFS=$IFS; IFS=$ac_path_separator
1307 for ac_dir in $ac_dummy; do
1309 test -z "$ac_dir" && ac_dir=.
1310 $as_executable_p "$ac_dir/$ac_word" || continue
1311 ac_cv_prog_ac_ct_CC="$ac_prog"
1312 echo "$as_me:1312: found $ac_dir/$ac_word" >&5
1318 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1319 if test -n "$ac_ct_CC"; then
1320 echo "$as_me:1320: result: $ac_ct_CC" >&5
1321 echo "${ECHO_T}$ac_ct_CC" >&6
1323 echo "$as_me:1323: result: no" >&5
1324 echo "${ECHO_T}no" >&6
1327 test -n "$ac_ct_CC" && break
1333 test -z "$CC" && { { echo "$as_me:1333: error: no acceptable cc found in \$PATH" >&5
1334 echo "$as_me: error: no acceptable cc found in \$PATH" >&2;}
1335 { (exit 1); exit 1; }; }
1337 # Provide some information about the compiler.
1338 echo "$as_me:1338:" \
1339 "checking for C compiler version" >&5
1340 ac_compiler=`set X $ac_compile; echo $2`
1341 { (eval echo "$as_me:1341: \"$ac_compiler --version </dev/null >&5\"") >&5
1342 (eval $ac_compiler --version </dev/null >&5) 2>&5
1344 echo "$as_me:1344: \$? = $ac_status" >&5
1345 (exit $ac_status); }
1346 { (eval echo "$as_me:1346: \"$ac_compiler -v </dev/null >&5\"") >&5
1347 (eval $ac_compiler -v </dev/null >&5) 2>&5
1349 echo "$as_me:1349: \$? = $ac_status" >&5
1350 (exit $ac_status); }
1351 { (eval echo "$as_me:1351: \"$ac_compiler -V </dev/null >&5\"") >&5
1352 (eval $ac_compiler -V </dev/null >&5) 2>&5
1354 echo "$as_me:1354: \$? = $ac_status" >&5
1355 (exit $ac_status); }
1357 cat >conftest.$ac_ext <<_ACEOF
1358 #line 1358 "configure"
1359 #include "confdefs.h"
1369 ac_clean_files_save=$ac_clean_files
1370 ac_clean_files="$ac_clean_files a.out a.exe"
1371 # Try to create an executable without -o first, disregard a.out.
1372 # It will help us diagnose broken compilers, and finding out an intuition
1374 echo "$as_me:1374: checking for C compiler default output" >&5
1375 echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
1376 ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
1377 if { (eval echo "$as_me:1377: \"$ac_link_default\"") >&5
1378 (eval $ac_link_default) 2>&5
1380 echo "$as_me:1380: \$? = $ac_status" >&5
1381 (exit $ac_status); }; then
1382 # Find the output, starting from the most likely. This scheme is
1383 # not robust to junk in `.', hence go to wildcards (a.*) only as a last
1385 for ac_file in `ls a.exe conftest.exe 2>/dev/null;
1386 ls a.out conftest 2>/dev/null;
1387 ls a.* conftest.* 2>/dev/null`; do
1389 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1390 a.out ) # We found the default executable, but exeext='' is most
1393 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1394 # FIXME: I believe we export ac_cv_exeext for Libtool --akim.
1401 echo "$as_me: failed program was:" >&5
1402 cat conftest.$ac_ext >&5
1403 { { echo "$as_me:1403: error: C compiler cannot create executables" >&5
1404 echo "$as_me: error: C compiler cannot create executables" >&2;}
1405 { (exit 77); exit 77; }; }
1408 ac_exeext=$ac_cv_exeext
1409 echo "$as_me:1409: result: $ac_file" >&5
1410 echo "${ECHO_T}$ac_file" >&6
1412 # Check the compiler produces executables we can run. If not, either
1413 # the compiler is broken, or we cross compile.
1414 echo "$as_me:1414: checking whether the C compiler works" >&5
1415 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
1416 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
1417 # If not cross compiling, check that we can run a simple program.
1418 if test "$cross_compiling" != yes; then
1419 if { ac_try='./$ac_file'
1420 { (eval echo "$as_me:1420: \"$ac_try\"") >&5
1423 echo "$as_me:1423: \$? = $ac_status" >&5
1424 (exit $ac_status); }; }; then
1427 if test "$cross_compiling" = maybe; then
1430 { { echo "$as_me:1430: error: cannot run C compiled programs.
1431 If you meant to cross compile, use \`--host'." >&5
1432 echo "$as_me: error: cannot run C compiled programs.
1433 If you meant to cross compile, use \`--host'." >&2;}
1434 { (exit 1); exit 1; }; }
1438 echo "$as_me:1438: result: yes" >&5
1439 echo "${ECHO_T}yes" >&6
1441 rm -f a.out a.exe conftest$ac_cv_exeext
1442 ac_clean_files=$ac_clean_files_save
1443 # Check the compiler produces executables we can run. If not, either
1444 # the compiler is broken, or we cross compile.
1445 echo "$as_me:1445: checking whether we are cross compiling" >&5
1446 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
1447 echo "$as_me:1447: result: $cross_compiling" >&5
1448 echo "${ECHO_T}$cross_compiling" >&6
1450 echo "$as_me:1450: checking for executable suffix" >&5
1451 echo $ECHO_N "checking for executable suffix... $ECHO_C" >&6
1452 if { (eval echo "$as_me:1452: \"$ac_link\"") >&5
1453 (eval $ac_link) 2>&5
1455 echo "$as_me:1455: \$? = $ac_status" >&5
1456 (exit $ac_status); }; then
1457 # If both `conftest.exe' and `conftest' are `present' (well, observable)
1458 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
1459 # work properly (i.e., refer to `conftest.exe'), while it won't with
1461 for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do
1463 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1464 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1471 { { echo "$as_me:1471: error: cannot compute EXEEXT: cannot compile and link" >&5
1472 echo "$as_me: error: cannot compute EXEEXT: cannot compile and link" >&2;}
1473 { (exit 1); exit 1; }; }
1476 rm -f conftest$ac_cv_exeext
1477 echo "$as_me:1477: result: $ac_cv_exeext" >&5
1478 echo "${ECHO_T}$ac_cv_exeext" >&6
1480 rm -f conftest.$ac_ext
1481 EXEEXT=$ac_cv_exeext
1483 echo "$as_me:1483: checking for object suffix" >&5
1484 echo $ECHO_N "checking for object suffix... $ECHO_C" >&6
1485 if test "${ac_cv_objext+set}" = set; then
1486 echo $ECHO_N "(cached) $ECHO_C" >&6
1488 cat >conftest.$ac_ext <<_ACEOF
1489 #line 1489 "configure"
1490 #include "confdefs.h"
1500 rm -f conftest.o conftest.obj
1501 if { (eval echo "$as_me:1501: \"$ac_compile\"") >&5
1502 (eval $ac_compile) 2>&5
1504 echo "$as_me:1504: \$? = $ac_status" >&5
1505 (exit $ac_status); }; then
1506 for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
1508 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.map | *.inf ) ;;
1509 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
1514 echo "$as_me: failed program was:" >&5
1515 cat conftest.$ac_ext >&5
1516 { { echo "$as_me:1516: error: cannot compute OBJEXT: cannot compile" >&5
1517 echo "$as_me: error: cannot compute OBJEXT: cannot compile" >&2;}
1518 { (exit 1); exit 1; }; }
1521 rm -f conftest.$ac_cv_objext conftest.$ac_ext
1523 echo "$as_me:1523: result: $ac_cv_objext" >&5
1524 echo "${ECHO_T}$ac_cv_objext" >&6
1525 OBJEXT=$ac_cv_objext
1527 echo "$as_me:1527: checking whether we are using the GNU C compiler" >&5
1528 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
1529 if test "${ac_cv_c_compiler_gnu+set}" = set; then
1530 echo $ECHO_N "(cached) $ECHO_C" >&6
1532 cat >conftest.$ac_ext <<_ACEOF
1533 #line 1533 "configure"
1534 #include "confdefs.h"
1547 rm -f conftest.$ac_objext
1548 if { (eval echo "$as_me:1548: \"$ac_compile\"") >&5
1549 (eval $ac_compile) 2>&5
1551 echo "$as_me:1551: \$? = $ac_status" >&5
1552 (exit $ac_status); } &&
1553 { ac_try='test -s conftest.$ac_objext'
1554 { (eval echo "$as_me:1554: \"$ac_try\"") >&5
1557 echo "$as_me:1557: \$? = $ac_status" >&5
1558 (exit $ac_status); }; }; then
1561 echo "$as_me: failed program was:" >&5
1562 cat conftest.$ac_ext >&5
1565 rm -f conftest.$ac_objext conftest.$ac_ext
1566 ac_cv_c_compiler_gnu=$ac_compiler_gnu
1569 echo "$as_me:1569: result: $ac_cv_c_compiler_gnu" >&5
1570 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
1571 GCC=`test $ac_compiler_gnu = yes && echo yes`
1572 ac_test_CFLAGS=${CFLAGS+set}
1573 ac_save_CFLAGS=$CFLAGS
1575 echo "$as_me:1575: checking whether $CC accepts -g" >&5
1576 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
1577 if test "${ac_cv_prog_cc_g+set}" = set; then
1578 echo $ECHO_N "(cached) $ECHO_C" >&6
1580 cat >conftest.$ac_ext <<_ACEOF
1581 #line 1581 "configure"
1582 #include "confdefs.h"
1592 rm -f conftest.$ac_objext
1593 if { (eval echo "$as_me:1593: \"$ac_compile\"") >&5
1594 (eval $ac_compile) 2>&5
1596 echo "$as_me:1596: \$? = $ac_status" >&5
1597 (exit $ac_status); } &&
1598 { ac_try='test -s conftest.$ac_objext'
1599 { (eval echo "$as_me:1599: \"$ac_try\"") >&5
1602 echo "$as_me:1602: \$? = $ac_status" >&5
1603 (exit $ac_status); }; }; then
1606 echo "$as_me: failed program was:" >&5
1607 cat conftest.$ac_ext >&5
1610 rm -f conftest.$ac_objext conftest.$ac_ext
1612 echo "$as_me:1612: result: $ac_cv_prog_cc_g" >&5
1613 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
1614 if test "$ac_test_CFLAGS" = set; then
1615 CFLAGS=$ac_save_CFLAGS
1616 elif test $ac_cv_prog_cc_g = yes; then
1617 if test "$GCC" = yes; then
1623 if test "$GCC" = yes; then
1629 # Some people use a C++ compiler to compile C. Since we use `exit',
1630 # in C++ we need to declare it. In case someone uses the same compiler
1631 # for both compiling C and C++ we need to have the C++ compiler decide
1632 # the declaration of exit, since it's the most demanding environment.
1633 cat >conftest.$ac_ext <<_ACEOF
1638 rm -f conftest.$ac_objext
1639 if { (eval echo "$as_me:1639: \"$ac_compile\"") >&5
1640 (eval $ac_compile) 2>&5
1642 echo "$as_me:1642: \$? = $ac_status" >&5
1643 (exit $ac_status); } &&
1644 { ac_try='test -s conftest.$ac_objext'
1645 { (eval echo "$as_me:1645: \"$ac_try\"") >&5
1648 echo "$as_me:1648: \$? = $ac_status" >&5
1649 (exit $ac_status); }; }; then
1650 for ac_declaration in \
1652 '#include <stdlib.h>' \
1653 'extern "C" void std::exit (int) throw (); using std::exit;' \
1654 'extern "C" void std::exit (int); using std::exit;' \
1655 'extern "C" void exit (int) throw ();' \
1656 'extern "C" void exit (int);' \
1659 cat >conftest.$ac_ext <<_ACEOF
1660 #line 1660 "configure"
1661 #include "confdefs.h"
1672 rm -f conftest.$ac_objext
1673 if { (eval echo "$as_me:1673: \"$ac_compile\"") >&5
1674 (eval $ac_compile) 2>&5
1676 echo "$as_me:1676: \$? = $ac_status" >&5
1677 (exit $ac_status); } &&
1678 { ac_try='test -s conftest.$ac_objext'
1679 { (eval echo "$as_me:1679: \"$ac_try\"") >&5
1682 echo "$as_me:1682: \$? = $ac_status" >&5
1683 (exit $ac_status); }; }; then
1686 echo "$as_me: failed program was:" >&5
1687 cat conftest.$ac_ext >&5
1690 rm -f conftest.$ac_objext conftest.$ac_ext
1691 cat >conftest.$ac_ext <<_ACEOF
1692 #line 1692 "configure"
1693 #include "confdefs.h"
1703 rm -f conftest.$ac_objext
1704 if { (eval echo "$as_me:1704: \"$ac_compile\"") >&5
1705 (eval $ac_compile) 2>&5
1707 echo "$as_me:1707: \$? = $ac_status" >&5
1708 (exit $ac_status); } &&
1709 { ac_try='test -s conftest.$ac_objext'
1710 { (eval echo "$as_me:1710: \"$ac_try\"") >&5
1713 echo "$as_me:1713: \$? = $ac_status" >&5
1714 (exit $ac_status); }; }; then
1717 echo "$as_me: failed program was:" >&5
1718 cat conftest.$ac_ext >&5
1720 rm -f conftest.$ac_objext conftest.$ac_ext
1723 if test -n "$ac_declaration"; then
1724 echo '#ifdef __cplusplus' >>confdefs.h
1725 echo $ac_declaration >>confdefs.h
1726 echo '#endif' >>confdefs.h
1730 echo "$as_me: failed program was:" >&5
1731 cat conftest.$ac_ext >&5
1733 rm -f conftest.$ac_objext conftest.$ac_ext
1735 ac_cpp='$CPP $CPPFLAGS'
1736 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1737 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1738 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1739 ac_main_return=return
1742 if test "$GCC" = yes ; then
1743 echo "$as_me:1743: checking version of $CC" >&5
1744 echo $ECHO_N "checking version of $CC... $ECHO_C" >&6
1745 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.].*//'`"
1746 test -z "$GCC_VERSION" && GCC_VERSION=unknown
1747 echo "$as_me:1747: result: $GCC_VERSION" >&5
1748 echo "${ECHO_T}$GCC_VERSION" >&6
1753 if test "$GCC" = yes ; then
1756 echo "$as_me:1756: checking if this is really Intel C compiler" >&5
1757 echo $ECHO_N "checking if this is really Intel C compiler... $ECHO_C" >&6
1758 cf_save_CFLAGS="$CFLAGS"
1759 CFLAGS="$CFLAGS -no-gcc"
1760 cat >conftest.$ac_ext <<_ACEOF
1761 #line 1761 "configure"
1762 #include "confdefs.h"
1768 #ifdef __INTEL_COMPILER
1777 rm -f conftest.$ac_objext
1778 if { (eval echo "$as_me:1778: \"$ac_compile\"") >&5
1779 (eval $ac_compile) 2>&5
1781 echo "$as_me:1781: \$? = $ac_status" >&5
1782 (exit $ac_status); } &&
1783 { ac_try='test -s conftest.$ac_objext'
1784 { (eval echo "$as_me:1784: \"$ac_try\"") >&5
1787 echo "$as_me:1787: \$? = $ac_status" >&5
1788 (exit $ac_status); }; }; then
1790 cf_save_CFLAGS="$cf_save_CFLAGS -we147"
1793 echo "$as_me: failed program was:" >&5
1794 cat conftest.$ac_ext >&5
1796 rm -f conftest.$ac_objext conftest.$ac_ext
1797 CFLAGS="$cf_save_CFLAGS"
1798 echo "$as_me:1798: result: $INTEL_COMPILER" >&5
1799 echo "${ECHO_T}$INTEL_COMPILER" >&6
1806 if test "$GCC" = yes ; then
1807 echo "$as_me:1807: checking if this is really Clang C compiler" >&5
1808 echo $ECHO_N "checking if this is really Clang C compiler... $ECHO_C" >&6
1809 cf_save_CFLAGS="$CFLAGS"
1810 CFLAGS="$CFLAGS -Qunused-arguments"
1811 cat >conftest.$ac_ext <<_ACEOF
1812 #line 1812 "configure"
1813 #include "confdefs.h"
1828 rm -f conftest.$ac_objext
1829 if { (eval echo "$as_me:1829: \"$ac_compile\"") >&5
1830 (eval $ac_compile) 2>&5
1832 echo "$as_me:1832: \$? = $ac_status" >&5
1833 (exit $ac_status); } &&
1834 { ac_try='test -s conftest.$ac_objext'
1835 { (eval echo "$as_me:1835: \"$ac_try\"") >&5
1838 echo "$as_me:1838: \$? = $ac_status" >&5
1839 (exit $ac_status); }; }; then
1841 cf_save_CFLAGS="$cf_save_CFLAGS -Qunused-arguments"
1844 echo "$as_me: failed program was:" >&5
1845 cat conftest.$ac_ext >&5
1847 rm -f conftest.$ac_objext conftest.$ac_ext
1848 CFLAGS="$cf_save_CFLAGS"
1849 echo "$as_me:1849: result: $CLANG_COMPILER" >&5
1850 echo "${ECHO_T}$CLANG_COMPILER" >&6
1853 echo "$as_me:1853: checking for $CC option to accept ANSI C" >&5
1854 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
1855 if test "${ac_cv_prog_cc_stdc+set}" = set; then
1856 echo $ECHO_N "(cached) $ECHO_C" >&6
1858 ac_cv_prog_cc_stdc=no
1860 cat >conftest.$ac_ext <<_ACEOF
1861 #line 1861 "configure"
1862 #include "confdefs.h"
1865 #include <sys/types.h>
1866 #include <sys/stat.h>
1867 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
1868 struct buf { int x; };
1869 FILE * (*rcsopen) (struct buf *, struct stat *, int);
1870 static char *e (p, i)
1876 static char *f (char * (*g) (char **, int), char **p, ...)
1881 s = g (p, va_arg (v,int));
1885 int test (int i, double x);
1886 struct s1 {int (*f) (int a);};
1887 struct s2 {int (*f) (double a);};
1888 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
1894 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
1899 # Don't try gcc -ansi; that turns off useful extensions and
1900 # breaks some systems' header files.
1901 # AIX -qlanglvl=ansi
1902 # Ultrix and OSF/1 -std1
1903 # HP-UX 10.20 and later -Ae
1904 # HP-UX older versions -Aa -D_HPUX_SOURCE
1905 # SVR4 -Xc -D__EXTENSIONS__
1906 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
1908 CC="$ac_save_CC $ac_arg"
1909 rm -f conftest.$ac_objext
1910 if { (eval echo "$as_me:1910: \"$ac_compile\"") >&5
1911 (eval $ac_compile) 2>&5
1913 echo "$as_me:1913: \$? = $ac_status" >&5
1914 (exit $ac_status); } &&
1915 { ac_try='test -s conftest.$ac_objext'
1916 { (eval echo "$as_me:1916: \"$ac_try\"") >&5
1919 echo "$as_me:1919: \$? = $ac_status" >&5
1920 (exit $ac_status); }; }; then
1921 ac_cv_prog_cc_stdc=$ac_arg
1924 echo "$as_me: failed program was:" >&5
1925 cat conftest.$ac_ext >&5
1927 rm -f conftest.$ac_objext
1929 rm -f conftest.$ac_ext conftest.$ac_objext
1934 case "x$ac_cv_prog_cc_stdc" in
1936 echo "$as_me:1936: result: none needed" >&5
1937 echo "${ECHO_T}none needed" >&6 ;;
1939 echo "$as_me:1939: result: $ac_cv_prog_cc_stdc" >&5
1940 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
1941 CC="$CC $ac_cv_prog_cc_stdc" ;;
1944 # This should have been defined by AC_PROG_CC
1947 echo "$as_me:1947: checking \$CFLAGS variable" >&5
1948 echo $ECHO_N "checking \$CFLAGS variable... $ECHO_C" >&6
1951 echo "$as_me:1951: result: broken" >&5
1952 echo "${ECHO_T}broken" >&6
1953 { echo "$as_me:1953: WARNING: your environment uses the CFLAGS variable to hold CPPFLAGS options" >&5
1954 echo "$as_me: WARNING: your environment uses the CFLAGS variable to hold CPPFLAGS options" >&2;}
1957 for cf_arg in $cf_flags
1963 cf_new_extra_cppflags=
1965 for cf_add_cflags in $cf_arg
1967 case $cf_fix_cppflags in
1969 case $cf_add_cflags in
1970 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
1971 case $cf_add_cflags in
1973 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
1975 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
1976 && test -z "${cf_tst_cflags}" \
1977 && cf_fix_cppflags=yes
1979 if test $cf_fix_cppflags = yes ; then
1981 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
1982 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
1985 elif test "${cf_tst_cflags}" = "\"'" ; then
1987 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
1988 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
1998 case $cf_add_cflags in
2000 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
2002 CPPFLAGS=`echo "$CPPFLAGS" | \
2003 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
2004 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
2009 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
2010 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
2017 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
2018 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
2025 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2026 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2028 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
2030 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2031 && test -z "${cf_tst_cflags}" \
2032 && cf_fix_cppflags=no
2037 if test -n "$cf_new_cflags" ; then
2039 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
2040 CFLAGS="${CFLAGS}$cf_new_cflags"
2044 if test -n "$cf_new_cppflags" ; then
2046 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
2047 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
2051 if test -n "$cf_new_extra_cppflags" ; then
2053 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
2054 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
2061 echo "$as_me:2061: result: ok" >&5
2062 echo "${ECHO_T}ok" >&6
2066 echo "$as_me:2066: checking \$CC variable" >&5
2067 echo $ECHO_N "checking \$CC variable... $ECHO_C" >&6
2070 echo "$as_me:2070: result: broken" >&5
2071 echo "${ECHO_T}broken" >&6
2072 { echo "$as_me:2072: WARNING: your environment uses the CC variable to hold CFLAGS/CPPFLAGS options" >&5
2073 echo "$as_me: WARNING: your environment uses the CC variable to hold CFLAGS/CPPFLAGS options" >&2;}
2075 cf_prog=`echo "$CC" | sed -e 's/ / /g' -e 's/[ ]* / /g' -e 's/[ ]*[ ]-[^ ].*//'`
2076 cf_flags=`echo "$CC" | ${AWK:-awk} -v prog="$cf_prog" '{ printf("%s", substr($0,1+length(prog))); }'`
2078 for cf_arg in $cf_flags
2086 cf_new_extra_cppflags=
2088 for cf_add_cflags in $cf_arg
2090 case $cf_fix_cppflags in
2092 case $cf_add_cflags in
2093 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
2094 case $cf_add_cflags in
2096 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
2098 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2099 && test -z "${cf_tst_cflags}" \
2100 && cf_fix_cppflags=yes
2102 if test $cf_fix_cppflags = yes ; then
2104 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2105 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2108 elif test "${cf_tst_cflags}" = "\"'" ; then
2110 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2111 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2121 case $cf_add_cflags in
2123 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
2125 CPPFLAGS=`echo "$CPPFLAGS" | \
2126 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
2127 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
2132 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
2133 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
2140 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
2141 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
2148 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2149 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2151 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
2153 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2154 && test -z "${cf_tst_cflags}" \
2155 && cf_fix_cppflags=no
2160 if test -n "$cf_new_cflags" ; then
2162 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
2163 CFLAGS="${CFLAGS}$cf_new_cflags"
2167 if test -n "$cf_new_cppflags" ; then
2169 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
2170 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
2174 if test -n "$cf_new_extra_cppflags" ; then
2176 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
2177 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
2187 test -n "$verbose" && echo " resulting CC: '$CC'" 1>&6
2189 echo "${as_me:-configure}:2189: testing resulting CC: '$CC' ..." 1>&5
2191 test -n "$verbose" && echo " resulting CFLAGS: '$CFLAGS'" 1>&6
2193 echo "${as_me:-configure}:2193: testing resulting CFLAGS: '$CFLAGS' ..." 1>&5
2195 test -n "$verbose" && echo " resulting CPPFLAGS: '$CPPFLAGS'" 1>&6
2197 echo "${as_me:-configure}:2197: testing resulting CPPFLAGS: '$CPPFLAGS' ..." 1>&5
2201 echo "$as_me:2201: result: ok" >&5
2202 echo "${ECHO_T}ok" >&6
2207 ac_cpp='$CPP $CPPFLAGS'
2208 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2209 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2210 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2211 ac_main_return=return
2212 echo "$as_me:2212: checking how to run the C preprocessor" >&5
2213 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
2214 # On Suns, sometimes $CPP names a directory.
2215 if test -n "$CPP" && test -d "$CPP"; then
2218 if test -z "$CPP"; then
2219 if test "${ac_cv_prog_CPP+set}" = set; then
2220 echo $ECHO_N "(cached) $ECHO_C" >&6
2222 # Double quotes because CPP needs to be expanded
2223 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
2226 for ac_c_preproc_warn_flag in '' yes
2228 # Use a header file that comes with gcc, so configuring glibc
2229 # with a fresh cross-compiler works.
2230 # On the NeXT, cc -E runs the code through the compiler's parser,
2231 # not just through cpp. "Syntax error" is here to catch this case.
2232 cat >conftest.$ac_ext <<_ACEOF
2233 #line 2233 "configure"
2234 #include "confdefs.h"
2238 if { (eval echo "$as_me:2238: \"$ac_cpp conftest.$ac_ext\"") >&5
2239 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2241 egrep -v '^ *\+' conftest.er1 >conftest.err
2243 cat conftest.err >&5
2244 echo "$as_me:2244: \$? = $ac_status" >&5
2245 (exit $ac_status); } >/dev/null; then
2246 if test -s conftest.err; then
2247 ac_cpp_err=$ac_c_preproc_warn_flag
2254 if test -z "$ac_cpp_err"; then
2257 echo "$as_me: failed program was:" >&5
2258 cat conftest.$ac_ext >&5
2259 # Broken: fails on valid input.
2262 rm -f conftest.err conftest.$ac_ext
2264 # OK, works on sane cases. Now check whether non-existent headers
2265 # can be detected and how.
2266 cat >conftest.$ac_ext <<_ACEOF
2267 #line 2267 "configure"
2268 #include "confdefs.h"
2269 #include <ac_nonexistent.h>
2271 if { (eval echo "$as_me:2271: \"$ac_cpp conftest.$ac_ext\"") >&5
2272 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2274 egrep -v '^ *\+' conftest.er1 >conftest.err
2276 cat conftest.err >&5
2277 echo "$as_me:2277: \$? = $ac_status" >&5
2278 (exit $ac_status); } >/dev/null; then
2279 if test -s conftest.err; then
2280 ac_cpp_err=$ac_c_preproc_warn_flag
2287 if test -z "$ac_cpp_err"; then
2288 # Broken: success on invalid input.
2291 echo "$as_me: failed program was:" >&5
2292 cat conftest.$ac_ext >&5
2293 # Passes both tests.
2297 rm -f conftest.err conftest.$ac_ext
2300 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2301 rm -f conftest.err conftest.$ac_ext
2302 if $ac_preproc_ok; then
2314 echo "$as_me:2314: result: $CPP" >&5
2315 echo "${ECHO_T}$CPP" >&6
2317 for ac_c_preproc_warn_flag in '' yes
2319 # Use a header file that comes with gcc, so configuring glibc
2320 # with a fresh cross-compiler works.
2321 # On the NeXT, cc -E runs the code through the compiler's parser,
2322 # not just through cpp. "Syntax error" is here to catch this case.
2323 cat >conftest.$ac_ext <<_ACEOF
2324 #line 2324 "configure"
2325 #include "confdefs.h"
2329 if { (eval echo "$as_me:2329: \"$ac_cpp conftest.$ac_ext\"") >&5
2330 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2332 egrep -v '^ *\+' conftest.er1 >conftest.err
2334 cat conftest.err >&5
2335 echo "$as_me:2335: \$? = $ac_status" >&5
2336 (exit $ac_status); } >/dev/null; then
2337 if test -s conftest.err; then
2338 ac_cpp_err=$ac_c_preproc_warn_flag
2345 if test -z "$ac_cpp_err"; then
2348 echo "$as_me: failed program was:" >&5
2349 cat conftest.$ac_ext >&5
2350 # Broken: fails on valid input.
2353 rm -f conftest.err conftest.$ac_ext
2355 # OK, works on sane cases. Now check whether non-existent headers
2356 # can be detected and how.
2357 cat >conftest.$ac_ext <<_ACEOF
2358 #line 2358 "configure"
2359 #include "confdefs.h"
2360 #include <ac_nonexistent.h>
2362 if { (eval echo "$as_me:2362: \"$ac_cpp conftest.$ac_ext\"") >&5
2363 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2365 egrep -v '^ *\+' conftest.er1 >conftest.err
2367 cat conftest.err >&5
2368 echo "$as_me:2368: \$? = $ac_status" >&5
2369 (exit $ac_status); } >/dev/null; then
2370 if test -s conftest.err; then
2371 ac_cpp_err=$ac_c_preproc_warn_flag
2378 if test -z "$ac_cpp_err"; then
2379 # Broken: success on invalid input.
2382 echo "$as_me: failed program was:" >&5
2383 cat conftest.$ac_ext >&5
2384 # Passes both tests.
2388 rm -f conftest.err conftest.$ac_ext
2391 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2392 rm -f conftest.err conftest.$ac_ext
2393 if $ac_preproc_ok; then
2396 { { echo "$as_me:2396: error: C preprocessor \"$CPP\" fails sanity check" >&5
2397 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;}
2398 { (exit 1); exit 1; }; }
2402 ac_cpp='$CPP $CPPFLAGS'
2403 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2404 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2405 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2406 ac_main_return=return
2408 if test $ac_cv_c_compiler_gnu = yes; then
2409 echo "$as_me:2409: checking whether $CC needs -traditional" >&5
2410 echo $ECHO_N "checking whether $CC needs -traditional... $ECHO_C" >&6
2411 if test "${ac_cv_prog_gcc_traditional+set}" = set; then
2412 echo $ECHO_N "(cached) $ECHO_C" >&6
2414 ac_pattern="Autoconf.*'x'"
2415 cat >conftest.$ac_ext <<_ACEOF
2416 #line 2416 "configure"
2417 #include "confdefs.h"
2419 int Autoconf = TIOCGETP;
2421 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2422 egrep "$ac_pattern" >/dev/null 2>&1; then
2423 ac_cv_prog_gcc_traditional=yes
2425 ac_cv_prog_gcc_traditional=no
2429 if test $ac_cv_prog_gcc_traditional = no; then
2430 cat >conftest.$ac_ext <<_ACEOF
2431 #line 2431 "configure"
2432 #include "confdefs.h"
2434 int Autoconf = TCGETA;
2436 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2437 egrep "$ac_pattern" >/dev/null 2>&1; then
2438 ac_cv_prog_gcc_traditional=yes
2444 echo "$as_me:2444: result: $ac_cv_prog_gcc_traditional" >&5
2445 echo "${ECHO_T}$ac_cv_prog_gcc_traditional" >&6
2446 if test $ac_cv_prog_gcc_traditional = yes; then
2447 CC="$CC -traditional"
2451 echo "$as_me:2451: checking whether $CC understands -c and -o together" >&5
2452 echo $ECHO_N "checking whether $CC understands -c and -o together... $ECHO_C" >&6
2453 if test "${cf_cv_prog_CC_c_o+set}" = set; then
2454 echo $ECHO_N "(cached) $ECHO_C" >&6
2457 cat > conftest.$ac_ext <<CF_EOF
2460 ${cf_cv_main_return:-return}(0);
2463 # We do the test twice because some compilers refuse to overwrite an
2464 # existing .o file with -o, though they will create one.
2465 ac_try='$CC $CFLAGS $CPPFLAGS -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
2466 if { (eval echo "$as_me:2466: \"$ac_try\"") >&5
2469 echo "$as_me:2469: \$? = $ac_status" >&5
2470 (exit $ac_status); } &&
2471 test -f conftest2.$ac_objext && { (eval echo "$as_me:2471: \"$ac_try\"") >&5
2474 echo "$as_me:2474: \$? = $ac_status" >&5
2475 (exit $ac_status); };
2477 eval cf_cv_prog_CC_c_o=yes
2479 eval cf_cv_prog_CC_c_o=no
2484 if test $cf_cv_prog_CC_c_o = yes; then
2485 echo "$as_me:2485: result: yes" >&5
2486 echo "${ECHO_T}yes" >&6
2488 echo "$as_me:2488: result: no" >&5
2489 echo "${ECHO_T}no" >&6
2492 test "$program_prefix" != NONE &&
2493 program_transform_name="s,^,$program_prefix,;$program_transform_name"
2494 # Use a double $ so make ignores it.
2495 test "$program_suffix" != NONE &&
2496 program_transform_name="s,\$,$program_suffix,;$program_transform_name"
2497 # Double any \ or $. echo might interpret backslashes.
2498 # By default was `s,x,x', remove it if useless.
2499 cat <<\_ACEOF >conftest.sed
2500 s/[\\$]/&&/g;s/;s,x,x,$//
2502 program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
2505 for ac_prog in mawk gawk nawk awk
2507 # Extract the first word of "$ac_prog", so it can be a program name with args.
2508 set dummy $ac_prog; ac_word=$2
2509 echo "$as_me:2509: checking for $ac_word" >&5
2510 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2511 if test "${ac_cv_prog_AWK+set}" = set; then
2512 echo $ECHO_N "(cached) $ECHO_C" >&6
2514 if test -n "$AWK"; then
2515 ac_cv_prog_AWK="$AWK" # Let the user override the test.
2517 ac_save_IFS=$IFS; IFS=$ac_path_separator
2519 for ac_dir in $ac_dummy; do
2521 test -z "$ac_dir" && ac_dir=.
2522 $as_executable_p "$ac_dir/$ac_word" || continue
2523 ac_cv_prog_AWK="$ac_prog"
2524 echo "$as_me:2524: found $ac_dir/$ac_word" >&5
2531 if test -n "$AWK"; then
2532 echo "$as_me:2532: result: $AWK" >&5
2533 echo "${ECHO_T}$AWK" >&6
2535 echo "$as_me:2535: result: no" >&5
2536 echo "${ECHO_T}no" >&6
2539 test -n "$AWK" && break
2542 test -z "$AWK" && { { echo "$as_me:2542: error: No awk program found" >&5
2543 echo "$as_me: error: No awk program found" >&2;}
2544 { (exit 1); exit 1; }; }
2546 echo "$as_me:2546: checking for egrep" >&5
2547 echo $ECHO_N "checking for egrep... $ECHO_C" >&6
2548 if test "${ac_cv_prog_egrep+set}" = set; then
2549 echo $ECHO_N "(cached) $ECHO_C" >&6
2551 if echo a | (grep -E '(a|b)') >/dev/null 2>&1
2552 then ac_cv_prog_egrep='grep -E'
2553 else ac_cv_prog_egrep='egrep'
2556 echo "$as_me:2556: result: $ac_cv_prog_egrep" >&5
2557 echo "${ECHO_T}$ac_cv_prog_egrep" >&6
2558 EGREP=$ac_cv_prog_egrep
2560 test -z "$EGREP" && { { echo "$as_me:2560: error: No egrep program found" >&5
2561 echo "$as_me: error: No egrep program found" >&2;}
2562 { (exit 1); exit 1; }; }
2564 # Find a good install program. We prefer a C program (faster),
2565 # so one script is as good as another. But avoid the broken or
2566 # incompatible versions:
2567 # SysV /etc/install, /usr/sbin/install
2568 # SunOS /usr/etc/install
2569 # IRIX /sbin/install
2571 # AmigaOS /C/install, which installs bootblocks on floppy discs
2572 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
2573 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
2574 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
2575 # ./install, which can be erroneously created by make from ./install.sh.
2576 echo "$as_me:2576: checking for a BSD compatible install" >&5
2577 echo $ECHO_N "checking for a BSD compatible install... $ECHO_C" >&6
2578 if test -z "$INSTALL"; then
2579 if test "${ac_cv_path_install+set}" = set; then
2580 echo $ECHO_N "(cached) $ECHO_C" >&6
2582 ac_save_IFS=$IFS; IFS=$ac_path_separator
2583 for ac_dir in $PATH; do
2585 # Account for people who put trailing slashes in PATH elements.
2587 / | ./ | .// | /cC/* \
2588 | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* \
2591 # OSF1 and SCO ODT 3.0 have their own names for install.
2592 # Don't use installbsd from OSF since it installs stuff as root
2594 for ac_prog in ginstall scoinst install; do
2595 if $as_executable_p "$ac_dir/$ac_prog"; then
2596 if test $ac_prog = install &&
2597 grep dspmsg "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2598 # AIX install. It has an incompatible calling convention.
2600 elif test $ac_prog = install &&
2601 grep pwplus "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2602 # program-specific install script used by HP pwplus--don't use.
2605 ac_cv_path_install="$ac_dir/$ac_prog -c"
2615 if test "${ac_cv_path_install+set}" = set; then
2616 INSTALL=$ac_cv_path_install
2618 # As a last resort, use the slow shell script. We don't cache a
2619 # path for INSTALL within a source directory, because that will
2620 # break other packages using the cache if that directory is
2621 # removed, or if the path is relative.
2622 INSTALL=$ac_install_sh
2625 echo "$as_me:2625: result: $INSTALL" >&5
2626 echo "${ECHO_T}$INSTALL" >&6
2628 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
2629 # It thinks the first close brace ends the variable substitution.
2630 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
2632 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
2634 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
2636 echo "$as_me:2636: checking whether ln -s works" >&5
2637 echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
2639 if test "$LN_S" = "ln -s"; then
2640 echo "$as_me:2640: result: yes" >&5
2641 echo "${ECHO_T}yes" >&6
2643 echo "$as_me:2643: result: no, using $LN_S" >&5
2644 echo "${ECHO_T}no, using $LN_S" >&6
2647 echo "$as_me:2647: checking if $LN_S -f options work" >&5
2648 echo $ECHO_N "checking if $LN_S -f options work... $ECHO_C" >&6
2650 rm -f conf$$.src conf$$dst
2652 echo first >conf$$.src
2653 if $LN_S -f conf$$.src conf$$.dst 2>/dev/null; then
2658 rm -f conf$$.dst conf$$src
2659 echo "$as_me:2659: result: $cf_prog_ln_sf" >&5
2660 echo "${ECHO_T}$cf_prog_ln_sf" >&6
2662 test "$cf_prog_ln_sf" = yes && LN_S="$LN_S -f"
2664 # Find a good install program. We prefer a C program (faster),
2665 # so one script is as good as another. But avoid the broken or
2666 # incompatible versions:
2667 # SysV /etc/install, /usr/sbin/install
2668 # SunOS /usr/etc/install
2669 # IRIX /sbin/install
2671 # AmigaOS /C/install, which installs bootblocks on floppy discs
2672 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
2673 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
2674 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
2675 # ./install, which can be erroneously created by make from ./install.sh.
2676 echo "$as_me:2676: checking for a BSD compatible install" >&5
2677 echo $ECHO_N "checking for a BSD compatible install... $ECHO_C" >&6
2678 if test -z "$INSTALL"; then
2679 if test "${ac_cv_path_install+set}" = set; then
2680 echo $ECHO_N "(cached) $ECHO_C" >&6
2682 ac_save_IFS=$IFS; IFS=$ac_path_separator
2683 for ac_dir in $PATH; do
2685 # Account for people who put trailing slashes in PATH elements.
2687 / | ./ | .// | /cC/* \
2688 | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* \
2691 # OSF1 and SCO ODT 3.0 have their own names for install.
2692 # Don't use installbsd from OSF since it installs stuff as root
2694 for ac_prog in ginstall scoinst install; do
2695 if $as_executable_p "$ac_dir/$ac_prog"; then
2696 if test $ac_prog = install &&
2697 grep dspmsg "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2698 # AIX install. It has an incompatible calling convention.
2700 elif test $ac_prog = install &&
2701 grep pwplus "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2702 # program-specific install script used by HP pwplus--don't use.
2705 ac_cv_path_install="$ac_dir/$ac_prog -c"
2715 if test "${ac_cv_path_install+set}" = set; then
2716 INSTALL=$ac_cv_path_install
2718 # As a last resort, use the slow shell script. We don't cache a
2719 # path for INSTALL within a source directory, because that will
2720 # break other packages using the cache if that directory is
2721 # removed, or if the path is relative.
2722 INSTALL=$ac_install_sh
2725 echo "$as_me:2725: result: $INSTALL" >&5
2726 echo "${ECHO_T}$INSTALL" >&6
2728 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
2729 # It thinks the first close brace ends the variable substitution.
2730 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
2732 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
2734 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
2740 cf_dir=`echo $INSTALL | sed -e 's%/[^/]*$%%'`
2741 test -z "$cf_dir" && cf_dir=.
2742 INSTALL=`cd $cf_dir && pwd`/`echo $INSTALL | sed -e 's%^.*/%%'`
2746 echo "$as_me:2746: checking if you want to install stripped executables" >&5
2747 echo $ECHO_N "checking if you want to install stripped executables... $ECHO_C" >&6
2749 # Check whether --enable-stripping or --disable-stripping was given.
2750 if test "${enable_stripping+set}" = set; then
2751 enableval="$enable_stripping"
2752 test "$enableval" != no && enableval=yes
2753 if test "$enableval" != "yes" ; then
2763 echo "$as_me:2763: result: $with_stripping" >&5
2764 echo "${ECHO_T}$with_stripping" >&6
2766 if test "$with_stripping" = yes
2773 : ${INSTALL:=install}
2774 echo "$as_me:2774: checking if install accepts -p option" >&5
2775 echo $ECHO_N "checking if install accepts -p option... $ECHO_C" >&6
2776 if test "${cf_cv_install_p+set}" = set; then
2777 echo $ECHO_N "(cached) $ECHO_C" >&6
2784 if $INSTALL -p conftest.in conftest.out 2>/dev/null
2786 if test -f conftest.out/conftest.in
2788 test conftest.in -nt conftest.out/conftest.in 2>conftest.err && \
2789 test conftest.out/conftest.in -nt conftest.in 2>conftest.err
2790 if test -s conftest.err
2805 echo "$as_me:2805: result: $cf_cv_install_p" >&5
2806 echo "${ECHO_T}$cf_cv_install_p" >&6
2808 echo "$as_me:2808: checking if install needs to be told about ownership" >&5
2809 echo $ECHO_N "checking if install needs to be told about ownership... $ECHO_C" >&6
2810 case `$ac_config_guess` in
2819 echo "$as_me:2819: result: $with_install_o" >&5
2820 echo "${ECHO_T}$with_install_o" >&6
2821 if test "x$with_install_o" = xyes
2823 INSTALL_OPT_O=`id root|sed -e 's/uid=[0-9]*(/ -o /' -e 's/gid=[0-9]*(/ -g /' -e 's/ [^=[:space:]][^=[:space:]]*=.*/ /' -e 's/)//g'`
2828 echo "$as_me:2828: checking for long file names" >&5
2829 echo $ECHO_N "checking for long file names... $ECHO_C" >&6
2830 if test "${ac_cv_sys_long_file_names+set}" = set; then
2831 echo $ECHO_N "(cached) $ECHO_C" >&6
2833 ac_cv_sys_long_file_names=yes
2834 # Test for long file names in all the places we know might matter:
2835 # . the current directory, where building will happen
2836 # $prefix/lib where we will be installing things
2837 # $exec_prefix/lib likewise
2838 # eval it to expand exec_prefix.
2839 # $TMPDIR if set, where it might want to write temporary files
2840 # if $TMPDIR is not set:
2841 # /tmp where it might want to write temporary files
2844 if test -n "$TMPDIR" && test -d "$TMPDIR" && test -w "$TMPDIR"; then
2847 ac_tmpdirs='/tmp /var/tmp /usr/tmp'
2849 for ac_dir in . $ac_tmpdirs `eval echo $prefix/lib $exec_prefix/lib` ; do
2850 test -d $ac_dir || continue
2851 test -w $ac_dir || continue # It is less confusing to not echo anything here.
2852 ac_xdir=$ac_dir/cf$$
2853 (umask 077 && mkdir $ac_xdir 2>/dev/null) || continue
2854 ac_tf1=$ac_xdir/conftest9012345
2855 ac_tf2=$ac_xdir/conftest9012346
2856 (echo 1 >$ac_tf1) 2>/dev/null
2857 (echo 2 >$ac_tf2) 2>/dev/null
2858 ac_val=`cat $ac_tf1 2>/dev/null`
2859 if test ! -f $ac_tf1 || test "$ac_val" != 1; then
2860 ac_cv_sys_long_file_names=no
2861 rm -rf $ac_xdir 2>/dev/null
2864 rm -rf $ac_xdir 2>/dev/null
2867 echo "$as_me:2867: result: $ac_cv_sys_long_file_names" >&5
2868 echo "${ECHO_T}$ac_cv_sys_long_file_names" >&6
2869 if test $ac_cv_sys_long_file_names = yes; then
2871 cat >>confdefs.h <<\EOF
2872 #define HAVE_LONG_FILE_NAMES 1
2877 # if we find pkg-config, check if we should install the ".pc" files.
2879 echo "$as_me:2879: checking if you want to use pkg-config" >&5
2880 echo $ECHO_N "checking if you want to use pkg-config... $ECHO_C" >&6
2882 # Check whether --with-pkg-config or --without-pkg-config was given.
2883 if test "${with_pkg_config+set}" = set; then
2884 withval="$with_pkg_config"
2885 cf_pkg_config=$withval
2889 echo "$as_me:2889: result: $cf_pkg_config" >&5
2890 echo "${ECHO_T}$cf_pkg_config" >&6
2892 case $cf_pkg_config in
2898 if test -n "$ac_tool_prefix"; then
2899 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
2900 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
2901 echo "$as_me:2901: checking for $ac_word" >&5
2902 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2903 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then
2904 echo $ECHO_N "(cached) $ECHO_C" >&6
2908 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
2911 ac_save_IFS=$IFS; IFS=$ac_path_separator
2913 for ac_dir in $ac_dummy; do
2915 test -z "$ac_dir" && ac_dir=.
2916 if $as_executable_p "$ac_dir/$ac_word"; then
2917 ac_cv_path_PKG_CONFIG="$ac_dir/$ac_word"
2918 echo "$as_me:2918: found $ac_dir/$ac_word" >&5
2926 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
2928 if test -n "$PKG_CONFIG"; then
2929 echo "$as_me:2929: result: $PKG_CONFIG" >&5
2930 echo "${ECHO_T}$PKG_CONFIG" >&6
2932 echo "$as_me:2932: result: no" >&5
2933 echo "${ECHO_T}no" >&6
2937 if test -z "$ac_cv_path_PKG_CONFIG"; then
2938 ac_pt_PKG_CONFIG=$PKG_CONFIG
2939 # Extract the first word of "pkg-config", so it can be a program name with args.
2940 set dummy pkg-config; ac_word=$2
2941 echo "$as_me:2941: checking for $ac_word" >&5
2942 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2943 if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then
2944 echo $ECHO_N "(cached) $ECHO_C" >&6
2946 case $ac_pt_PKG_CONFIG in
2948 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
2951 ac_save_IFS=$IFS; IFS=$ac_path_separator
2953 for ac_dir in $ac_dummy; do
2955 test -z "$ac_dir" && ac_dir=.
2956 if $as_executable_p "$ac_dir/$ac_word"; then
2957 ac_cv_path_ac_pt_PKG_CONFIG="$ac_dir/$ac_word"
2958 echo "$as_me:2958: found $ac_dir/$ac_word" >&5
2963 test -z "$ac_cv_path_ac_pt_PKG_CONFIG" && ac_cv_path_ac_pt_PKG_CONFIG="none"
2967 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
2969 if test -n "$ac_pt_PKG_CONFIG"; then
2970 echo "$as_me:2970: result: $ac_pt_PKG_CONFIG" >&5
2971 echo "${ECHO_T}$ac_pt_PKG_CONFIG" >&6
2973 echo "$as_me:2973: result: no" >&5
2974 echo "${ECHO_T}no" >&6
2977 PKG_CONFIG=$ac_pt_PKG_CONFIG
2979 PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
2988 test -z "$PKG_CONFIG" && PKG_CONFIG=none
2989 if test "$PKG_CONFIG" != none ; then
2991 if test "x$prefix" != xNONE; then
2992 cf_path_syntax="$prefix"
2994 cf_path_syntax="$ac_default_prefix"
2997 case ".$PKG_CONFIG" in
3002 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
3004 (.\${*prefix}*|.\${*dir}*)
3005 eval PKG_CONFIG="$PKG_CONFIG"
3006 case ".$PKG_CONFIG" in
3008 PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
3013 PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
3016 { { echo "$as_me:3016: error: expected a pathname, not \"$PKG_CONFIG\"" >&5
3017 echo "$as_me: error: expected a pathname, not \"$PKG_CONFIG\"" >&2;}
3018 { (exit 1); exit 1; }; }
3022 elif test "x$cf_pkg_config" != xno ; then
3023 { echo "$as_me:3023: WARNING: pkg-config is not installed" >&5
3024 echo "$as_me: WARNING: pkg-config is not installed" >&2;}
3029 echo "$as_me:3029: checking for pkg-config library directory" >&5
3030 echo $ECHO_N "checking for pkg-config library directory... $ECHO_C" >&6
3033 echo "$as_me:3033: checking for $PKG_CONFIG library directory" >&5
3034 echo $ECHO_N "checking for $PKG_CONFIG library directory... $ECHO_C" >&6
3038 PKG_CONFIG_LIBDIR=no
3040 # Check whether --with-pkg-config-libdir or --without-pkg-config-libdir was given.
3041 if test "${with_pkg_config_libdir+set}" = set; then
3042 withval="$with_pkg_config_libdir"
3043 PKG_CONFIG_LIBDIR=$withval
3045 test "x$PKG_CONFIG" != xnone && PKG_CONFIG_LIBDIR=yes
3048 case x$PKG_CONFIG_LIBDIR in
3052 # Look for the library directory using the same prefix as the executable
3053 if test "x$PKG_CONFIG" = xnone
3057 cf_path=`echo "$PKG_CONFIG" | sed -e 's,/[^/]*/[^/]*$,,'`
3060 # If you don't like using the default architecture, you have to specify the
3061 # intended library directory and corresponding compiler/linker options.
3063 # This case allows for Debian's 2014-flavor of multiarch, along with the
3064 # most common variations before that point. Some other variants spell the
3065 # directory differently, e.g., "pkg-config", and put it in unusual places.
3066 # pkg-config has always been poorly standardized, which is ironic...
3067 case x`(arch) 2>/dev/null` in
3070 $cf_path/lib/*64-linux-gnu \
3078 $cf_path/lib/*-linux-gnu \
3086 test -n "$verbose" && echo " list..." 1>&6
3088 echo "${as_me:-configure}:3088: testing list... ..." 1>&5
3090 for cf_config in $cf_search_path
3092 test -n "$verbose" && echo " checking $cf_config/pkgconfig" 1>&6
3094 echo "${as_me:-configure}:3094: testing checking $cf_config/pkgconfig ..." 1>&5
3096 if test -d $cf_config/pkgconfig
3098 PKG_CONFIG_LIBDIR=$cf_config/pkgconfig
3099 echo "$as_me:3099: checking done" >&5
3100 echo $ECHO_N "checking done... $ECHO_C" >&6
3109 if test "x$PKG_CONFIG_LIBDIR" != xno ; then
3110 echo "$as_me:3110: result: $PKG_CONFIG_LIBDIR" >&5
3111 echo "${ECHO_T}$PKG_CONFIG_LIBDIR" >&6
3114 echo "$as_me:3114: checking if you want to build test-programs" >&5
3115 echo $ECHO_N "checking if you want to build test-programs... $ECHO_C" >&6
3117 # Check whether --with-tests or --without-tests was given.
3118 if test "${with_tests+set}" = set; then
3119 withval="$with_tests"
3120 cf_with_tests=$withval
3124 echo "$as_me:3124: result: $cf_with_tests" >&5
3125 echo "${ECHO_T}$cf_with_tests" >&6
3127 echo "$as_me:3127: checking if we should assume mixed-case filenames" >&5
3128 echo $ECHO_N "checking if we should assume mixed-case filenames... $ECHO_C" >&6
3130 # Check whether --enable-mixed-case or --disable-mixed-case was given.
3131 if test "${enable_mixed_case+set}" = set; then
3132 enableval="$enable_mixed_case"
3133 enable_mixedcase=$enableval
3135 enable_mixedcase=auto
3137 echo "$as_me:3137: result: $enable_mixedcase" >&5
3138 echo "${ECHO_T}$enable_mixedcase" >&6
3139 if test "$enable_mixedcase" = "auto" ; then
3141 echo "$as_me:3141: checking if filesystem supports mixed-case filenames" >&5
3142 echo $ECHO_N "checking if filesystem supports mixed-case filenames... $ECHO_C" >&6
3143 if test "${cf_cv_mixedcase+set}" = set; then
3144 echo $ECHO_N "(cached) $ECHO_C" >&6
3147 if test "$cross_compiling" = yes ; then
3148 case $target_alias in
3149 (*-os2-emx*|*-msdosdjgpp*|*-cygwin*|*-msys*|*-mingw*|*-uwin*)
3157 rm -f conftest CONFTEST
3159 if test -f CONFTEST ; then
3164 rm -f conftest CONFTEST
3168 echo "$as_me:3168: result: $cf_cv_mixedcase" >&5
3169 echo "${ECHO_T}$cf_cv_mixedcase" >&6
3170 test "$cf_cv_mixedcase" = yes &&
3171 cat >>confdefs.h <<\EOF
3172 #define MIXEDCASE_FILENAMES 1
3176 cf_cv_mixedcase=$enable_mixedcase
3177 if test "$enable_mixedcase" = "yes" ; then
3178 cat >>confdefs.h <<\EOF
3179 #define MIXEDCASE_FILENAMES 1
3185 # do this after mixed-case option (tags/TAGS is not as important as tic).
3186 echo "$as_me:3186: checking whether ${MAKE-make} sets \${MAKE}" >&5
3187 echo $ECHO_N "checking whether ${MAKE-make} sets \${MAKE}... $ECHO_C" >&6
3188 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,./+-,__p_,'`
3189 if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
3190 echo $ECHO_N "(cached) $ECHO_C" >&6
3192 cat >conftest.make <<\EOF
3194 @echo 'ac_maketemp="${MAKE}"'
3196 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
3197 eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
3198 if test -n "$ac_maketemp"; then
3199 eval ac_cv_prog_make_${ac_make}_set=yes
3201 eval ac_cv_prog_make_${ac_make}_set=no
3205 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
3206 echo "$as_me:3206: result: yes" >&5
3207 echo "${ECHO_T}yes" >&6
3210 echo "$as_me:3210: result: no" >&5
3211 echo "${ECHO_T}no" >&6
3212 SET_MAKE="MAKE=${MAKE-make}"
3215 for ac_prog in exctags ctags
3217 # Extract the first word of "$ac_prog", so it can be a program name with args.
3218 set dummy $ac_prog; ac_word=$2
3219 echo "$as_me:3219: checking for $ac_word" >&5
3220 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3221 if test "${ac_cv_prog_CTAGS+set}" = set; then
3222 echo $ECHO_N "(cached) $ECHO_C" >&6
3224 if test -n "$CTAGS"; then
3225 ac_cv_prog_CTAGS="$CTAGS" # Let the user override the test.
3227 ac_save_IFS=$IFS; IFS=$ac_path_separator
3229 for ac_dir in $ac_dummy; do
3231 test -z "$ac_dir" && ac_dir=.
3232 $as_executable_p "$ac_dir/$ac_word" || continue
3233 ac_cv_prog_CTAGS="$ac_prog"
3234 echo "$as_me:3234: found $ac_dir/$ac_word" >&5
3240 CTAGS=$ac_cv_prog_CTAGS
3241 if test -n "$CTAGS"; then
3242 echo "$as_me:3242: result: $CTAGS" >&5
3243 echo "${ECHO_T}$CTAGS" >&6
3245 echo "$as_me:3245: result: no" >&5
3246 echo "${ECHO_T}no" >&6
3249 test -n "$CTAGS" && break
3252 for ac_prog in exetags etags
3254 # Extract the first word of "$ac_prog", so it can be a program name with args.
3255 set dummy $ac_prog; ac_word=$2
3256 echo "$as_me:3256: checking for $ac_word" >&5
3257 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3258 if test "${ac_cv_prog_ETAGS+set}" = set; then
3259 echo $ECHO_N "(cached) $ECHO_C" >&6
3261 if test -n "$ETAGS"; then
3262 ac_cv_prog_ETAGS="$ETAGS" # Let the user override the test.
3264 ac_save_IFS=$IFS; IFS=$ac_path_separator
3266 for ac_dir in $ac_dummy; do
3268 test -z "$ac_dir" && ac_dir=.
3269 $as_executable_p "$ac_dir/$ac_word" || continue
3270 ac_cv_prog_ETAGS="$ac_prog"
3271 echo "$as_me:3271: found $ac_dir/$ac_word" >&5
3277 ETAGS=$ac_cv_prog_ETAGS
3278 if test -n "$ETAGS"; then
3279 echo "$as_me:3279: result: $ETAGS" >&5
3280 echo "${ECHO_T}$ETAGS" >&6
3282 echo "$as_me:3282: result: no" >&5
3283 echo "${ECHO_T}no" >&6
3286 test -n "$ETAGS" && break
3289 # Extract the first word of "${CTAGS:-ctags}", so it can be a program name with args.
3290 set dummy ${CTAGS:-ctags}; ac_word=$2
3291 echo "$as_me:3291: checking for $ac_word" >&5
3292 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3293 if test "${ac_cv_prog_MAKE_LOWER_TAGS+set}" = set; then
3294 echo $ECHO_N "(cached) $ECHO_C" >&6
3296 if test -n "$MAKE_LOWER_TAGS"; then
3297 ac_cv_prog_MAKE_LOWER_TAGS="$MAKE_LOWER_TAGS" # Let the user override the test.
3299 ac_save_IFS=$IFS; IFS=$ac_path_separator
3301 for ac_dir in $ac_dummy; do
3303 test -z "$ac_dir" && ac_dir=.
3304 $as_executable_p "$ac_dir/$ac_word" || continue
3305 ac_cv_prog_MAKE_LOWER_TAGS="yes"
3306 echo "$as_me:3306: found $ac_dir/$ac_word" >&5
3310 test -z "$ac_cv_prog_MAKE_LOWER_TAGS" && ac_cv_prog_MAKE_LOWER_TAGS="no"
3313 MAKE_LOWER_TAGS=$ac_cv_prog_MAKE_LOWER_TAGS
3314 if test -n "$MAKE_LOWER_TAGS"; then
3315 echo "$as_me:3315: result: $MAKE_LOWER_TAGS" >&5
3316 echo "${ECHO_T}$MAKE_LOWER_TAGS" >&6
3318 echo "$as_me:3318: result: no" >&5
3319 echo "${ECHO_T}no" >&6
3322 if test "$cf_cv_mixedcase" = yes ; then
3323 # Extract the first word of "${ETAGS:-etags}", so it can be a program name with args.
3324 set dummy ${ETAGS:-etags}; ac_word=$2
3325 echo "$as_me:3325: checking for $ac_word" >&5
3326 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3327 if test "${ac_cv_prog_MAKE_UPPER_TAGS+set}" = set; then
3328 echo $ECHO_N "(cached) $ECHO_C" >&6
3330 if test -n "$MAKE_UPPER_TAGS"; then
3331 ac_cv_prog_MAKE_UPPER_TAGS="$MAKE_UPPER_TAGS" # Let the user override the test.
3333 ac_save_IFS=$IFS; IFS=$ac_path_separator
3335 for ac_dir in $ac_dummy; do
3337 test -z "$ac_dir" && ac_dir=.
3338 $as_executable_p "$ac_dir/$ac_word" || continue
3339 ac_cv_prog_MAKE_UPPER_TAGS="yes"
3340 echo "$as_me:3340: found $ac_dir/$ac_word" >&5
3344 test -z "$ac_cv_prog_MAKE_UPPER_TAGS" && ac_cv_prog_MAKE_UPPER_TAGS="no"
3347 MAKE_UPPER_TAGS=$ac_cv_prog_MAKE_UPPER_TAGS
3348 if test -n "$MAKE_UPPER_TAGS"; then
3349 echo "$as_me:3349: result: $MAKE_UPPER_TAGS" >&5
3350 echo "${ECHO_T}$MAKE_UPPER_TAGS" >&6
3352 echo "$as_me:3352: result: no" >&5
3353 echo "${ECHO_T}no" >&6
3360 if test "$MAKE_UPPER_TAGS" = yes ; then
3366 if test "$MAKE_LOWER_TAGS" = yes ; then
3372 echo "$as_me:3372: checking for makeflags variable" >&5
3373 echo $ECHO_N "checking for makeflags variable... $ECHO_C" >&6
3374 if test "${cf_cv_makeflags+set}" = set; then
3375 echo $ECHO_N "(cached) $ECHO_C" >&6
3379 for cf_option in '-${MAKEFLAGS}' '${MFLAGS}'
3381 cat >cf_makeflags.tmp <<CF_EOF
3384 @ echo '.$cf_option'
3386 cf_result=`${MAKE:-make} -k -f cf_makeflags.tmp 2>/dev/null | fgrep -v "ing directory" | sed -e 's,[ ]*$,,'`
3387 case "$cf_result" in
3389 cf_result=`${MAKE:-make} -k -f cf_makeflags.tmp CC=cc 2>/dev/null`
3390 case "$cf_result" in
3391 (.*CC=*) cf_cv_makeflags=
3393 (*) cf_cv_makeflags=$cf_option
3402 echo "${as_me:-configure}:3402: testing given option \"$cf_option\",no match \"$cf_result\" ..." 1>&5
3407 rm -f cf_makeflags.tmp
3410 echo "$as_me:3410: result: $cf_cv_makeflags" >&5
3411 echo "${ECHO_T}$cf_cv_makeflags" >&6
3413 if test -n "$ac_tool_prefix"; then
3414 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
3415 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
3416 echo "$as_me:3416: checking for $ac_word" >&5
3417 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3418 if test "${ac_cv_prog_RANLIB+set}" = set; then
3419 echo $ECHO_N "(cached) $ECHO_C" >&6
3421 if test -n "$RANLIB"; then
3422 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
3424 ac_save_IFS=$IFS; IFS=$ac_path_separator
3426 for ac_dir in $ac_dummy; do
3428 test -z "$ac_dir" && ac_dir=.
3429 $as_executable_p "$ac_dir/$ac_word" || continue
3430 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
3431 echo "$as_me:3431: found $ac_dir/$ac_word" >&5
3437 RANLIB=$ac_cv_prog_RANLIB
3438 if test -n "$RANLIB"; then
3439 echo "$as_me:3439: result: $RANLIB" >&5
3440 echo "${ECHO_T}$RANLIB" >&6
3442 echo "$as_me:3442: result: no" >&5
3443 echo "${ECHO_T}no" >&6
3447 if test -z "$ac_cv_prog_RANLIB"; then
3448 ac_ct_RANLIB=$RANLIB
3449 # Extract the first word of "ranlib", so it can be a program name with args.
3450 set dummy ranlib; ac_word=$2
3451 echo "$as_me:3451: checking for $ac_word" >&5
3452 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3453 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
3454 echo $ECHO_N "(cached) $ECHO_C" >&6
3456 if test -n "$ac_ct_RANLIB"; then
3457 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
3459 ac_save_IFS=$IFS; IFS=$ac_path_separator
3461 for ac_dir in $ac_dummy; do
3463 test -z "$ac_dir" && ac_dir=.
3464 $as_executable_p "$ac_dir/$ac_word" || continue
3465 ac_cv_prog_ac_ct_RANLIB="ranlib"
3466 echo "$as_me:3466: found $ac_dir/$ac_word" >&5
3470 test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB="':'"
3473 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
3474 if test -n "$ac_ct_RANLIB"; then
3475 echo "$as_me:3475: result: $ac_ct_RANLIB" >&5
3476 echo "${ECHO_T}$ac_ct_RANLIB" >&6
3478 echo "$as_me:3478: result: no" >&5
3479 echo "${ECHO_T}no" >&6
3482 RANLIB=$ac_ct_RANLIB
3484 RANLIB="$ac_cv_prog_RANLIB"
3487 if test -n "$ac_tool_prefix"; then
3488 # Extract the first word of "${ac_tool_prefix}ld", so it can be a program name with args.
3489 set dummy ${ac_tool_prefix}ld; ac_word=$2
3490 echo "$as_me:3490: checking for $ac_word" >&5
3491 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3492 if test "${ac_cv_prog_LD+set}" = set; then
3493 echo $ECHO_N "(cached) $ECHO_C" >&6
3495 if test -n "$LD"; then
3496 ac_cv_prog_LD="$LD" # Let the user override the test.
3498 ac_save_IFS=$IFS; IFS=$ac_path_separator
3500 for ac_dir in $ac_dummy; do
3502 test -z "$ac_dir" && ac_dir=.
3503 $as_executable_p "$ac_dir/$ac_word" || continue
3504 ac_cv_prog_LD="${ac_tool_prefix}ld"
3505 echo "$as_me:3505: found $ac_dir/$ac_word" >&5
3512 if test -n "$LD"; then
3513 echo "$as_me:3513: result: $LD" >&5
3514 echo "${ECHO_T}$LD" >&6
3516 echo "$as_me:3516: result: no" >&5
3517 echo "${ECHO_T}no" >&6
3521 if test -z "$ac_cv_prog_LD"; then
3523 # Extract the first word of "ld", so it can be a program name with args.
3524 set dummy ld; 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_ac_ct_LD+set}" = set; then
3528 echo $ECHO_N "(cached) $ECHO_C" >&6
3530 if test -n "$ac_ct_LD"; then
3531 ac_cv_prog_ac_ct_LD="$ac_ct_LD" # Let the user override the test.
3533 ac_save_IFS=$IFS; IFS=$ac_path_separator
3535 for ac_dir in $ac_dummy; do
3537 test -z "$ac_dir" && ac_dir=.
3538 $as_executable_p "$ac_dir/$ac_word" || continue
3539 ac_cv_prog_ac_ct_LD="ld"
3540 echo "$as_me:3540: found $ac_dir/$ac_word" >&5
3544 test -z "$ac_cv_prog_ac_ct_LD" && ac_cv_prog_ac_ct_LD="ld"
3547 ac_ct_LD=$ac_cv_prog_ac_ct_LD
3548 if test -n "$ac_ct_LD"; then
3549 echo "$as_me:3549: result: $ac_ct_LD" >&5
3550 echo "${ECHO_T}$ac_ct_LD" >&6
3552 echo "$as_me:3552: result: no" >&5
3553 echo "${ECHO_T}no" >&6
3561 if test -n "$ac_tool_prefix"; then
3562 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
3563 set dummy ${ac_tool_prefix}ar; ac_word=$2
3564 echo "$as_me:3564: checking for $ac_word" >&5
3565 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3566 if test "${ac_cv_prog_AR+set}" = set; then
3567 echo $ECHO_N "(cached) $ECHO_C" >&6
3569 if test -n "$AR"; then
3570 ac_cv_prog_AR="$AR" # Let the user override the test.
3572 ac_save_IFS=$IFS; IFS=$ac_path_separator
3574 for ac_dir in $ac_dummy; do
3576 test -z "$ac_dir" && ac_dir=.
3577 $as_executable_p "$ac_dir/$ac_word" || continue
3578 ac_cv_prog_AR="${ac_tool_prefix}ar"
3579 echo "$as_me:3579: found $ac_dir/$ac_word" >&5
3586 if test -n "$AR"; then
3587 echo "$as_me:3587: result: $AR" >&5
3588 echo "${ECHO_T}$AR" >&6
3590 echo "$as_me:3590: result: no" >&5
3591 echo "${ECHO_T}no" >&6
3595 if test -z "$ac_cv_prog_AR"; then
3597 # Extract the first word of "ar", so it can be a program name with args.
3598 set dummy ar; ac_word=$2
3599 echo "$as_me:3599: checking for $ac_word" >&5
3600 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3601 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
3602 echo $ECHO_N "(cached) $ECHO_C" >&6
3604 if test -n "$ac_ct_AR"; then
3605 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
3607 ac_save_IFS=$IFS; IFS=$ac_path_separator
3609 for ac_dir in $ac_dummy; do
3611 test -z "$ac_dir" && ac_dir=.
3612 $as_executable_p "$ac_dir/$ac_word" || continue
3613 ac_cv_prog_ac_ct_AR="ar"
3614 echo "$as_me:3614: found $ac_dir/$ac_word" >&5
3618 test -z "$ac_cv_prog_ac_ct_AR" && ac_cv_prog_ac_ct_AR="ar"
3621 ac_ct_AR=$ac_cv_prog_ac_ct_AR
3622 if test -n "$ac_ct_AR"; then
3623 echo "$as_me:3623: result: $ac_ct_AR" >&5
3624 echo "${ECHO_T}$ac_ct_AR" >&6
3626 echo "$as_me:3626: result: no" >&5
3627 echo "${ECHO_T}no" >&6
3635 if test -n "$ac_tool_prefix"; then
3636 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
3637 set dummy ${ac_tool_prefix}ar; ac_word=$2
3638 echo "$as_me:3638: checking for $ac_word" >&5
3639 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3640 if test "${ac_cv_prog_AR+set}" = set; then
3641 echo $ECHO_N "(cached) $ECHO_C" >&6
3643 if test -n "$AR"; then
3644 ac_cv_prog_AR="$AR" # Let the user override the test.
3646 ac_save_IFS=$IFS; IFS=$ac_path_separator
3648 for ac_dir in $ac_dummy; do
3650 test -z "$ac_dir" && ac_dir=.
3651 $as_executable_p "$ac_dir/$ac_word" || continue
3652 ac_cv_prog_AR="${ac_tool_prefix}ar"
3653 echo "$as_me:3653: found $ac_dir/$ac_word" >&5
3660 if test -n "$AR"; then
3661 echo "$as_me:3661: result: $AR" >&5
3662 echo "${ECHO_T}$AR" >&6
3664 echo "$as_me:3664: result: no" >&5
3665 echo "${ECHO_T}no" >&6
3669 if test -z "$ac_cv_prog_AR"; then
3671 # Extract the first word of "ar", so it can be a program name with args.
3672 set dummy ar; ac_word=$2
3673 echo "$as_me:3673: checking for $ac_word" >&5
3674 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3675 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
3676 echo $ECHO_N "(cached) $ECHO_C" >&6
3678 if test -n "$ac_ct_AR"; then
3679 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
3681 ac_save_IFS=$IFS; IFS=$ac_path_separator
3683 for ac_dir in $ac_dummy; do
3685 test -z "$ac_dir" && ac_dir=.
3686 $as_executable_p "$ac_dir/$ac_word" || continue
3687 ac_cv_prog_ac_ct_AR="ar"
3688 echo "$as_me:3688: found $ac_dir/$ac_word" >&5
3692 test -z "$ac_cv_prog_ac_ct_AR" && ac_cv_prog_ac_ct_AR="ar"
3695 ac_ct_AR=$ac_cv_prog_ac_ct_AR
3696 if test -n "$ac_ct_AR"; then
3697 echo "$as_me:3697: result: $ac_ct_AR" >&5
3698 echo "${ECHO_T}$ac_ct_AR" >&6
3700 echo "$as_me:3700: result: no" >&5
3701 echo "${ECHO_T}no" >&6
3709 echo "$as_me:3709: checking for options to update archives" >&5
3710 echo $ECHO_N "checking for options to update archives... $ECHO_C" >&6
3711 if test "${cf_cv_ar_flags+set}" = set; then
3712 echo $ECHO_N "(cached) $ECHO_C" >&6
3715 cf_cv_ar_flags=unknown
3716 for cf_ar_flags in -curvU -curv curv -crv crv -cqv cqv -rv rv
3719 # check if $ARFLAGS already contains this choice
3720 if test "x$ARFLAGS" != "x" ; then
3721 cf_check_ar_flags=`echo "x$ARFLAGS" | sed -e "s/$cf_ar_flags\$//" -e "s/$cf_ar_flags / /"`
3722 if test "x$ARFLAGS" != "$cf_check_ar_flags" ; then
3728 rm -f conftest.$ac_cv_objext
3731 cat >conftest.$ac_ext <<EOF
3732 #line 3732 "configure"
3733 int testdata[3] = { 123, 456, 789 };
3735 if { (eval echo "$as_me:3735: \"$ac_compile\"") >&5
3736 (eval $ac_compile) 2>&5
3738 echo "$as_me:3738: \$? = $ac_status" >&5
3739 (exit $ac_status); } ; then
3740 echo "$AR $ARFLAGS $cf_ar_flags conftest.a conftest.$ac_cv_objext" >&5
3741 $AR $ARFLAGS $cf_ar_flags conftest.a conftest.$ac_cv_objext 2>&5 1>/dev/null
3742 if test -f conftest.a ; then
3743 cf_cv_ar_flags=$cf_ar_flags
3747 test -n "$verbose" && echo " cannot compile test-program" 1>&6
3749 echo "${as_me:-configure}:3749: testing cannot compile test-program ..." 1>&5
3754 rm -f conftest.a conftest.$ac_ext conftest.$ac_cv_objext
3757 echo "$as_me:3757: result: $cf_cv_ar_flags" >&5
3758 echo "${ECHO_T}$cf_cv_ar_flags" >&6
3760 if test -n "$ARFLAGS" ; then
3761 if test -n "$cf_cv_ar_flags" ; then
3762 ARFLAGS="$ARFLAGS $cf_cv_ar_flags"
3765 ARFLAGS=$cf_cv_ar_flags
3768 echo "$as_me:3768: checking for PATH separator" >&5
3769 echo $ECHO_N "checking for PATH separator... $ECHO_C" >&6
3770 case $cf_cv_system_name in
3771 (os2*) PATH_SEPARATOR=';' ;;
3772 (*) ${PATH_SEPARATOR:=':'} ;;
3775 echo "$as_me:3775: result: $PATH_SEPARATOR" >&5
3776 echo "${ECHO_T}$PATH_SEPARATOR" >&6
3778 echo "$as_me:3778: checking if you have specified an install-prefix" >&5
3779 echo $ECHO_N "checking if you have specified an install-prefix... $ECHO_C" >&6
3781 # Check whether --with-install-prefix or --without-install-prefix was given.
3782 if test "${with_install_prefix+set}" = set; then
3783 withval="$with_install_prefix"
3787 (*) DESTDIR="$withval"
3791 echo "$as_me:3791: result: $DESTDIR" >&5
3792 echo "${ECHO_T}$DESTDIR" >&6
3794 ###############################################################################
3796 # If we're cross-compiling, allow the user to override the tools and their
3797 # options. The configure script is oriented toward identifying the host
3798 # compiler, etc., but we need a build compiler to generate parts of the source.
3800 if test "$cross_compiling" = yes ; then
3802 # defaults that we might want to override
3803 : ${BUILD_CFLAGS:=''}
3804 : ${BUILD_CPPFLAGS:=''}
3805 : ${BUILD_LDFLAGS:=''}
3807 : ${BUILD_EXEEXT:='$x'}
3808 : ${BUILD_OBJEXT:='o'}
3810 # Check whether --with-build-cc or --without-build-cc was given.
3811 if test "${with_build_cc+set}" = set; then
3812 withval="$with_build_cc"
3815 for ac_prog in gcc clang c99 c89 cc cl
3817 # Extract the first word of "$ac_prog", so it can be a program name with args.
3818 set dummy $ac_prog; ac_word=$2
3819 echo "$as_me:3819: checking for $ac_word" >&5
3820 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3821 if test "${ac_cv_prog_BUILD_CC+set}" = set; then
3822 echo $ECHO_N "(cached) $ECHO_C" >&6
3824 if test -n "$BUILD_CC"; then
3825 ac_cv_prog_BUILD_CC="$BUILD_CC" # Let the user override the test.
3827 ac_save_IFS=$IFS; IFS=$ac_path_separator
3829 for ac_dir in $ac_dummy; do
3831 test -z "$ac_dir" && ac_dir=.
3832 $as_executable_p "$ac_dir/$ac_word" || continue
3833 ac_cv_prog_BUILD_CC="$ac_prog"
3834 echo "$as_me:3834: found $ac_dir/$ac_word" >&5
3840 BUILD_CC=$ac_cv_prog_BUILD_CC
3841 if test -n "$BUILD_CC"; then
3842 echo "$as_me:3842: result: $BUILD_CC" >&5
3843 echo "${ECHO_T}$BUILD_CC" >&6
3845 echo "$as_me:3845: result: no" >&5
3846 echo "${ECHO_T}no" >&6
3849 test -n "$BUILD_CC" && break
3851 test -n "$BUILD_CC" || BUILD_CC="none"
3854 echo "$as_me:3854: checking for native build C compiler" >&5
3855 echo $ECHO_N "checking for native build C compiler... $ECHO_C" >&6
3856 echo "$as_me:3856: result: $BUILD_CC" >&5
3857 echo "${ECHO_T}$BUILD_CC" >&6
3859 echo "$as_me:3859: checking for native build C preprocessor" >&5
3860 echo $ECHO_N "checking for native build C preprocessor... $ECHO_C" >&6
3862 # Check whether --with-build-cpp or --without-build-cpp was given.
3863 if test "${with_build_cpp+set}" = set; then
3864 withval="$with_build_cpp"
3865 BUILD_CPP="$withval"
3867 BUILD_CPP='${BUILD_CC} -E'
3869 echo "$as_me:3869: result: $BUILD_CPP" >&5
3870 echo "${ECHO_T}$BUILD_CPP" >&6
3872 echo "$as_me:3872: checking for native build C flags" >&5
3873 echo $ECHO_N "checking for native build C flags... $ECHO_C" >&6
3875 # Check whether --with-build-cflags or --without-build-cflags was given.
3876 if test "${with_build_cflags+set}" = set; then
3877 withval="$with_build_cflags"
3878 BUILD_CFLAGS="$withval"
3880 echo "$as_me:3880: result: $BUILD_CFLAGS" >&5
3881 echo "${ECHO_T}$BUILD_CFLAGS" >&6
3883 echo "$as_me:3883: checking for native build C preprocessor-flags" >&5
3884 echo $ECHO_N "checking for native build C preprocessor-flags... $ECHO_C" >&6
3886 # Check whether --with-build-cppflags or --without-build-cppflags was given.
3887 if test "${with_build_cppflags+set}" = set; then
3888 withval="$with_build_cppflags"
3889 BUILD_CPPFLAGS="$withval"
3891 echo "$as_me:3891: result: $BUILD_CPPFLAGS" >&5
3892 echo "${ECHO_T}$BUILD_CPPFLAGS" >&6
3894 echo "$as_me:3894: checking for native build linker-flags" >&5
3895 echo $ECHO_N "checking for native build linker-flags... $ECHO_C" >&6
3897 # Check whether --with-build-ldflags or --without-build-ldflags was given.
3898 if test "${with_build_ldflags+set}" = set; then
3899 withval="$with_build_ldflags"
3900 BUILD_LDFLAGS="$withval"
3902 echo "$as_me:3902: result: $BUILD_LDFLAGS" >&5
3903 echo "${ECHO_T}$BUILD_LDFLAGS" >&6
3905 echo "$as_me:3905: checking for native build linker-libraries" >&5
3906 echo $ECHO_N "checking for native build linker-libraries... $ECHO_C" >&6
3908 # Check whether --with-build-libs or --without-build-libs was given.
3909 if test "${with_build_libs+set}" = set; then
3910 withval="$with_build_libs"
3911 BUILD_LIBS="$withval"
3913 echo "$as_me:3913: result: $BUILD_LIBS" >&5
3914 echo "${ECHO_T}$BUILD_LIBS" >&6
3916 # this assumes we're on Unix.
3920 : ${BUILD_CC:='${CC}'}
3922 if ( test "$BUILD_CC" = "$CC" || test "$BUILD_CC" = '${CC}' ) ; then
3923 { { echo "$as_me:3923: error: Cross-build requires two compilers.
3924 Use --with-build-cc to specify the native compiler." >&5
3925 echo "$as_me: error: Cross-build requires two compilers.
3926 Use --with-build-cc to specify the native compiler." >&2;}
3927 { (exit 1); exit 1; }; }
3931 : ${BUILD_CC:='${CC}'}
3932 : ${BUILD_CPP:='${CPP}'}
3933 : ${BUILD_CFLAGS:='${CFLAGS}'}
3934 : ${BUILD_CPPFLAGS:='${CPPFLAGS}'}
3935 : ${BUILD_LDFLAGS:='${LDFLAGS}'}
3936 : ${BUILD_LIBS:='${LIBS}'}
3937 : ${BUILD_EXEEXT:='$x'}
3938 : ${BUILD_OBJEXT:='o'}
3941 ###############################################################################
3943 ### Options to allow the user to specify the set of libraries which are used.
3944 ### Use "--without-normal --with-shared" to allow the default model to be
3945 ### shared, for example.
3948 echo "$as_me:3948: checking if you want to build shared C-objects" >&5
3949 echo $ECHO_N "checking if you want to build shared C-objects... $ECHO_C" >&6
3951 # Check whether --with-shared or --without-shared was given.
3952 if test "${with_shared+set}" = set; then
3953 withval="$with_shared"
3954 with_shared=$withval
3958 echo "$as_me:3958: result: $with_shared" >&5
3959 echo "${ECHO_T}$with_shared" >&6
3960 test "$with_shared" = "yes" && cf_list_models="$cf_list_models shared"
3962 echo "$as_me:3962: checking for specified models" >&5
3963 echo $ECHO_N "checking for specified models... $ECHO_C" >&6
3964 test -z "$cf_list_models" && cf_list_models=normal
3965 echo "$as_me:3965: result: $cf_list_models" >&5
3966 echo "${ECHO_T}$cf_list_models" >&6
3968 ### Use the first model as the default, and save its suffix for use in building
3969 ### up test-applications.
3970 echo "$as_me:3970: checking for default model" >&5
3971 echo $ECHO_N "checking for default model... $ECHO_C" >&6
3972 DFT_LWR_MODEL=`echo "$cf_list_models" | $AWK '{print $1}'`
3973 echo "$as_me:3973: result: $DFT_LWR_MODEL" >&5
3974 echo "${ECHO_T}$DFT_LWR_MODEL" >&6
3976 DFT_UPR_MODEL=`echo "$DFT_LWR_MODEL" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
3978 echo "$as_me:3978: checking for specific curses-directory" >&5
3979 echo $ECHO_N "checking for specific curses-directory... $ECHO_C" >&6
3981 # Check whether --with-curses-dir or --without-curses-dir was given.
3982 if test "${with_curses_dir+set}" = set; then
3983 withval="$with_curses_dir"
3984 cf_cv_curses_dir=$withval
3988 echo "$as_me:3988: result: $cf_cv_curses_dir" >&5
3989 echo "${ECHO_T}$cf_cv_curses_dir" >&6
3991 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
3994 if test "x$prefix" != xNONE; then
3995 cf_path_syntax="$prefix"
3997 cf_path_syntax="$ac_default_prefix"
4005 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
4007 (.\${*prefix}*|.\${*dir}*)
4008 eval withval="$withval"
4011 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
4016 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
4019 { { echo "$as_me:4019: error: expected a pathname, not \"$withval\"" >&5
4020 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
4021 { (exit 1); exit 1; }; }
4025 if test -d "$cf_cv_curses_dir"
4028 if test -n "$cf_cv_curses_dir/include" ; then
4029 for cf_add_incdir in $cf_cv_curses_dir/include
4031 while test $cf_add_incdir != /usr/include
4033 if test -d $cf_add_incdir
4036 if test -n "$CFLAGS$CPPFLAGS" ; then
4037 # a loop is needed to ensure we can add subdirs of existing dirs
4038 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
4039 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
4040 cf_have_incdir=yes; break
4045 if test "$cf_have_incdir" = no ; then
4046 if test "$cf_add_incdir" = /usr/local/include ; then
4047 if test "$GCC" = yes
4049 cf_save_CPPFLAGS=$CPPFLAGS
4051 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4052 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
4054 cat >conftest.$ac_ext <<_ACEOF
4055 #line 4055 "configure"
4056 #include "confdefs.h"
4066 rm -f conftest.$ac_objext
4067 if { (eval echo "$as_me:4067: \"$ac_compile\"") >&5
4068 (eval $ac_compile) 2>&5
4070 echo "$as_me:4070: \$? = $ac_status" >&5
4071 (exit $ac_status); } &&
4072 { ac_try='test -s conftest.$ac_objext'
4073 { (eval echo "$as_me:4073: \"$ac_try\"") >&5
4076 echo "$as_me:4076: \$? = $ac_status" >&5
4077 (exit $ac_status); }; }; then
4080 echo "$as_me: failed program was:" >&5
4081 cat conftest.$ac_ext >&5
4084 rm -f conftest.$ac_objext conftest.$ac_ext
4085 CPPFLAGS=$cf_save_CPPFLAGS
4090 if test "$cf_have_incdir" = no ; then
4091 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
4093 echo "${as_me:-configure}:4093: testing adding $cf_add_incdir to include-path ..." 1>&5
4095 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
4097 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
4098 test "$cf_top_incdir" = "$cf_add_incdir" && break
4099 cf_add_incdir="$cf_top_incdir"
4110 if test -n "$cf_cv_curses_dir/lib" ; then
4111 for cf_add_libdir in $cf_cv_curses_dir/lib
4113 if test $cf_add_libdir = /usr/lib ; then
4115 elif test -d $cf_add_libdir
4118 if test -n "$LDFLAGS$LIBS" ; then
4119 # a loop is needed to ensure we can add subdirs of existing dirs
4120 for cf_test_libdir in $LDFLAGS $LIBS ; do
4121 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
4122 cf_have_libdir=yes; break
4126 if test "$cf_have_libdir" = no ; then
4127 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
4129 echo "${as_me:-configure}:4129: testing adding $cf_add_libdir to library-path ..." 1>&5
4131 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
4140 cf_ncuconfig_root=ncurses
4141 cf_have_ncuconfig=no
4143 if test "x${PKG_CONFIG:=none}" != xnone; then
4144 echo "$as_me:4144: checking pkg-config for $cf_ncuconfig_root" >&5
4145 echo $ECHO_N "checking pkg-config for $cf_ncuconfig_root... $ECHO_C" >&6
4146 if "$PKG_CONFIG" --exists $cf_ncuconfig_root ; then
4147 echo "$as_me:4147: result: yes" >&5
4148 echo "${ECHO_T}yes" >&6
4150 echo "$as_me:4150: checking if the $cf_ncuconfig_root package files work" >&5
4151 echo $ECHO_N "checking if the $cf_ncuconfig_root package files work... $ECHO_C" >&6
4152 cf_have_ncuconfig=unknown
4154 cf_save_CPPFLAGS="$CPPFLAGS"
4155 cf_save_LIBS="$LIBS"
4160 cf_new_extra_cppflags=
4162 for cf_add_cflags in `$PKG_CONFIG --cflags $cf_ncuconfig_root`
4164 case $cf_fix_cppflags in
4166 case $cf_add_cflags in
4167 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4168 case $cf_add_cflags in
4170 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4172 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4173 && test -z "${cf_tst_cflags}" \
4174 && cf_fix_cppflags=yes
4176 if test $cf_fix_cppflags = yes ; then
4178 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4179 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4182 elif test "${cf_tst_cflags}" = "\"'" ; then
4184 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4185 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4195 case $cf_add_cflags in
4197 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4199 CPPFLAGS=`echo "$CPPFLAGS" | \
4200 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4201 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4206 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4207 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4214 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4215 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4222 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4223 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4225 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
4227 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4228 && test -z "${cf_tst_cflags}" \
4229 && cf_fix_cppflags=no
4234 if test -n "$cf_new_cflags" ; then
4236 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4237 CFLAGS="${CFLAGS}$cf_new_cflags"
4241 if test -n "$cf_new_cppflags" ; then
4243 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4244 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4248 if test -n "$cf_new_extra_cppflags" ; then
4250 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4251 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4258 for cf_add_1lib in `$PKG_CONFIG --libs $cf_ncuconfig_root`; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
4260 for cf_add_1lib in $cf_add_0lib; do
4261 for cf_add_2lib in $cf_add_libs; do
4262 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
4267 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
4271 cat >conftest.$ac_ext <<_ACEOF
4272 #line 4272 "configure"
4273 #include "confdefs.h"
4274 #include <${cf_cv_ncurses_header:-curses.h}>
4278 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
4283 rm -f conftest.$ac_objext conftest$ac_exeext
4284 if { (eval echo "$as_me:4284: \"$ac_link\"") >&5
4285 (eval $ac_link) 2>&5
4287 echo "$as_me:4287: \$? = $ac_status" >&5
4288 (exit $ac_status); } &&
4289 { ac_try='test -s conftest$ac_exeext'
4290 { (eval echo "$as_me:4290: \"$ac_try\"") >&5
4293 echo "$as_me:4293: \$? = $ac_status" >&5
4294 (exit $ac_status); }; }; then
4295 if test "$cross_compiling" = yes; then
4296 cf_have_ncuconfig=maybe
4298 cat >conftest.$ac_ext <<_ACEOF
4299 #line 4299 "configure"
4300 #include "confdefs.h"
4301 #include <${cf_cv_ncurses_header:-curses.h}>
4303 { char *xx = curses_version(); return (xx == 0); }
4305 rm -f conftest$ac_exeext
4306 if { (eval echo "$as_me:4306: \"$ac_link\"") >&5
4307 (eval $ac_link) 2>&5
4309 echo "$as_me:4309: \$? = $ac_status" >&5
4310 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4311 { (eval echo "$as_me:4311: \"$ac_try\"") >&5
4314 echo "$as_me:4314: \$? = $ac_status" >&5
4315 (exit $ac_status); }; }; then
4316 cf_have_ncuconfig=yes
4318 echo "$as_me: program exited with status $ac_status" >&5
4319 echo "$as_me: failed program was:" >&5
4320 cat conftest.$ac_ext >&5
4321 cf_have_ncuconfig=no
4323 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
4326 echo "$as_me: failed program was:" >&5
4327 cat conftest.$ac_ext >&5
4328 cf_have_ncuconfig=no
4330 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4331 echo "$as_me:4331: result: $cf_have_ncuconfig" >&5
4332 echo "${ECHO_T}$cf_have_ncuconfig" >&6
4333 test "$cf_have_ncuconfig" = maybe && cf_have_ncuconfig=yes
4334 if test "$cf_have_ncuconfig" != "yes"
4336 CPPFLAGS="$cf_save_CPPFLAGS"
4337 LIBS="$cf_save_LIBS"
4338 NCURSES_CONFIG_PKG=none
4341 cat >>confdefs.h <<\EOF
4345 NCURSES_CONFIG_PKG=$cf_ncuconfig_root
4347 echo "$as_me:4347: checking for terminfo header" >&5
4348 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
4349 if test "${cf_cv_term_header+set}" = set; then
4350 echo $ECHO_N "(cached) $ECHO_C" >&6
4353 case ${cf_cv_ncurses_header} in
4354 (*/ncurses.h|*/ncursesw.h)
4355 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
4358 cf_term_header=term.h
4362 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
4364 cat >conftest.$ac_ext <<_ACEOF
4365 #line 4365 "configure"
4366 #include "confdefs.h"
4368 #include <${cf_cv_ncurses_header:-curses.h}>
4374 int x = auto_left_margin
4379 rm -f conftest.$ac_objext
4380 if { (eval echo "$as_me:4380: \"$ac_compile\"") >&5
4381 (eval $ac_compile) 2>&5
4383 echo "$as_me:4383: \$? = $ac_status" >&5
4384 (exit $ac_status); } &&
4385 { ac_try='test -s conftest.$ac_objext'
4386 { (eval echo "$as_me:4386: \"$ac_try\"") >&5
4389 echo "$as_me:4389: \$? = $ac_status" >&5
4390 (exit $ac_status); }; }; then
4392 cf_cv_term_header="$cf_test"
4394 echo "$as_me: failed program was:" >&5
4395 cat conftest.$ac_ext >&5
4397 cf_cv_term_header=unknown
4400 rm -f conftest.$ac_objext conftest.$ac_ext
4401 test "$cf_cv_term_header" != unknown && break
4405 echo "$as_me:4405: result: $cf_cv_term_header" >&5
4406 echo "${ECHO_T}$cf_cv_term_header" >&6
4408 # Set definitions to allow ifdef'ing to accommodate subdirectories
4410 case $cf_cv_term_header in
4413 cat >>confdefs.h <<\EOF
4414 #define HAVE_TERM_H 1
4420 case $cf_cv_term_header in
4423 cat >>confdefs.h <<\EOF
4424 #define HAVE_NCURSES_TERM_H 1
4430 cat >>confdefs.h <<\EOF
4431 #define HAVE_NCURSESW_TERM_H 1
4440 echo "$as_me:4440: result: no" >&5
4441 echo "${ECHO_T}no" >&6
4442 NCURSES_CONFIG_PKG=none
4445 NCURSES_CONFIG_PKG=none
4448 if test "x$cf_have_ncuconfig" = "xno"; then
4449 cf_ncurses_config="${cf_ncuconfig_root}${NCURSES_CONFIG_SUFFIX}-config"; echo "Looking for ${cf_ncurses_config}"
4451 if test -n "$ac_tool_prefix"; then
4452 for ac_prog in ${cf_ncurses_config} ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
4454 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4455 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
4456 echo "$as_me:4456: checking for $ac_word" >&5
4457 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4458 if test "${ac_cv_prog_NCURSES_CONFIG+set}" = set; then
4459 echo $ECHO_N "(cached) $ECHO_C" >&6
4461 if test -n "$NCURSES_CONFIG"; then
4462 ac_cv_prog_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test.
4464 ac_save_IFS=$IFS; IFS=$ac_path_separator
4466 for ac_dir in $ac_dummy; do
4468 test -z "$ac_dir" && ac_dir=.
4469 $as_executable_p "$ac_dir/$ac_word" || continue
4470 ac_cv_prog_NCURSES_CONFIG="$ac_tool_prefix$ac_prog"
4471 echo "$as_me:4471: found $ac_dir/$ac_word" >&5
4477 NCURSES_CONFIG=$ac_cv_prog_NCURSES_CONFIG
4478 if test -n "$NCURSES_CONFIG"; then
4479 echo "$as_me:4479: result: $NCURSES_CONFIG" >&5
4480 echo "${ECHO_T}$NCURSES_CONFIG" >&6
4482 echo "$as_me:4482: result: no" >&5
4483 echo "${ECHO_T}no" >&6
4486 test -n "$NCURSES_CONFIG" && break
4489 if test -z "$NCURSES_CONFIG"; then
4490 ac_ct_NCURSES_CONFIG=$NCURSES_CONFIG
4491 for ac_prog in ${cf_ncurses_config} ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
4493 # Extract the first word of "$ac_prog", so it can be a program name with args.
4494 set dummy $ac_prog; ac_word=$2
4495 echo "$as_me:4495: checking for $ac_word" >&5
4496 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4497 if test "${ac_cv_prog_ac_ct_NCURSES_CONFIG+set}" = set; then
4498 echo $ECHO_N "(cached) $ECHO_C" >&6
4500 if test -n "$ac_ct_NCURSES_CONFIG"; then
4501 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_ct_NCURSES_CONFIG" # Let the user override the test.
4503 ac_save_IFS=$IFS; IFS=$ac_path_separator
4505 for ac_dir in $ac_dummy; do
4507 test -z "$ac_dir" && ac_dir=.
4508 $as_executable_p "$ac_dir/$ac_word" || continue
4509 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_prog"
4510 echo "$as_me:4510: found $ac_dir/$ac_word" >&5
4516 ac_ct_NCURSES_CONFIG=$ac_cv_prog_ac_ct_NCURSES_CONFIG
4517 if test -n "$ac_ct_NCURSES_CONFIG"; then
4518 echo "$as_me:4518: result: $ac_ct_NCURSES_CONFIG" >&5
4519 echo "${ECHO_T}$ac_ct_NCURSES_CONFIG" >&6
4521 echo "$as_me:4521: result: no" >&5
4522 echo "${ECHO_T}no" >&6
4525 test -n "$ac_ct_NCURSES_CONFIG" && break
4527 test -n "$ac_ct_NCURSES_CONFIG" || ac_ct_NCURSES_CONFIG="none"
4529 NCURSES_CONFIG=$ac_ct_NCURSES_CONFIG
4532 if test "$NCURSES_CONFIG" != none ; then
4537 cf_new_extra_cppflags=
4539 for cf_add_cflags in `$NCURSES_CONFIG --cflags`
4541 case $cf_fix_cppflags in
4543 case $cf_add_cflags in
4544 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4545 case $cf_add_cflags in
4547 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4549 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4550 && test -z "${cf_tst_cflags}" \
4551 && cf_fix_cppflags=yes
4553 if test $cf_fix_cppflags = yes ; then
4555 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4556 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4559 elif test "${cf_tst_cflags}" = "\"'" ; then
4561 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4562 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4572 case $cf_add_cflags in
4574 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4576 CPPFLAGS=`echo "$CPPFLAGS" | \
4577 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4578 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4583 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4584 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4591 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4592 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4599 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4600 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4602 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
4604 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4605 && test -z "${cf_tst_cflags}" \
4606 && cf_fix_cppflags=no
4611 if test -n "$cf_new_cflags" ; then
4613 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4614 CFLAGS="${CFLAGS}$cf_new_cflags"
4618 if test -n "$cf_new_cppflags" ; then
4620 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4621 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4625 if test -n "$cf_new_extra_cppflags" ; then
4627 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4628 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4635 for cf_add_1lib in `$NCURSES_CONFIG --libs`; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
4637 for cf_add_1lib in $cf_add_0lib; do
4638 for cf_add_2lib in $cf_add_libs; do
4639 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
4644 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
4648 # even with config script, some packages use no-override for curses.h
4650 echo "$as_me:4650: checking if we have identified curses headers" >&5
4651 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
4652 if test "${cf_cv_ncurses_header+set}" = set; then
4653 echo $ECHO_N "(cached) $ECHO_C" >&6
4656 cf_cv_ncurses_header=none
4658 ncurses.h ncurses/ncurses.h \
4659 curses.h ncurses/curses.h
4661 cat >conftest.$ac_ext <<_ACEOF
4662 #line 4662 "configure"
4663 #include "confdefs.h"
4664 #include <${cf_header}>
4668 initscr(); tgoto("?", 0,0)
4673 rm -f conftest.$ac_objext
4674 if { (eval echo "$as_me:4674: \"$ac_compile\"") >&5
4675 (eval $ac_compile) 2>&5
4677 echo "$as_me:4677: \$? = $ac_status" >&5
4678 (exit $ac_status); } &&
4679 { ac_try='test -s conftest.$ac_objext'
4680 { (eval echo "$as_me:4680: \"$ac_try\"") >&5
4683 echo "$as_me:4683: \$? = $ac_status" >&5
4684 (exit $ac_status); }; }; then
4685 cf_cv_ncurses_header=$cf_header; break
4687 echo "$as_me: failed program was:" >&5
4688 cat conftest.$ac_ext >&5
4690 rm -f conftest.$ac_objext conftest.$ac_ext
4694 echo "$as_me:4694: result: $cf_cv_ncurses_header" >&5
4695 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
4697 if test "$cf_cv_ncurses_header" = none ; then
4698 { { echo "$as_me:4698: error: No curses header-files found" >&5
4699 echo "$as_me: error: No curses header-files found" >&2;}
4700 { (exit 1); exit 1; }; }
4703 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
4705 for ac_header in $cf_cv_ncurses_header
4707 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
4708 echo "$as_me:4708: checking for $ac_header" >&5
4709 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4710 if eval "test \"\${$as_ac_Header+set}\" = set"; then
4711 echo $ECHO_N "(cached) $ECHO_C" >&6
4713 cat >conftest.$ac_ext <<_ACEOF
4714 #line 4714 "configure"
4715 #include "confdefs.h"
4716 #include <$ac_header>
4718 if { (eval echo "$as_me:4718: \"$ac_cpp conftest.$ac_ext\"") >&5
4719 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4721 egrep -v '^ *\+' conftest.er1 >conftest.err
4723 cat conftest.err >&5
4724 echo "$as_me:4724: \$? = $ac_status" >&5
4725 (exit $ac_status); } >/dev/null; then
4726 if test -s conftest.err; then
4727 ac_cpp_err=$ac_c_preproc_warn_flag
4734 if test -z "$ac_cpp_err"; then
4735 eval "$as_ac_Header=yes"
4737 echo "$as_me: failed program was:" >&5
4738 cat conftest.$ac_ext >&5
4739 eval "$as_ac_Header=no"
4741 rm -f conftest.err conftest.$ac_ext
4743 echo "$as_me:4743: result: `eval echo '${'$as_ac_Header'}'`" >&5
4744 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4745 if test `eval echo '${'$as_ac_Header'}'` = yes; then
4746 cat >>confdefs.h <<EOF
4747 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
4753 cat >>confdefs.h <<\EOF
4757 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
4759 cat >>confdefs.h <<EOF
4760 #define $cf_nculib_ROOT 1
4763 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
4767 cf_ncuhdr_root=ncurses
4769 test -n "$cf_cv_curses_dir" && \
4770 test "$cf_cv_curses_dir" != "no" && { \
4772 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
4773 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
4775 while test $cf_add_incdir != /usr/include
4777 if test -d $cf_add_incdir
4780 if test -n "$CFLAGS$CPPFLAGS" ; then
4781 # a loop is needed to ensure we can add subdirs of existing dirs
4782 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
4783 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
4784 cf_have_incdir=yes; break
4789 if test "$cf_have_incdir" = no ; then
4790 if test "$cf_add_incdir" = /usr/local/include ; then
4791 if test "$GCC" = yes
4793 cf_save_CPPFLAGS=$CPPFLAGS
4795 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4796 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
4798 cat >conftest.$ac_ext <<_ACEOF
4799 #line 4799 "configure"
4800 #include "confdefs.h"
4810 rm -f conftest.$ac_objext
4811 if { (eval echo "$as_me:4811: \"$ac_compile\"") >&5
4812 (eval $ac_compile) 2>&5
4814 echo "$as_me:4814: \$? = $ac_status" >&5
4815 (exit $ac_status); } &&
4816 { ac_try='test -s conftest.$ac_objext'
4817 { (eval echo "$as_me:4817: \"$ac_try\"") >&5
4820 echo "$as_me:4820: \$? = $ac_status" >&5
4821 (exit $ac_status); }; }; then
4824 echo "$as_me: failed program was:" >&5
4825 cat conftest.$ac_ext >&5
4828 rm -f conftest.$ac_objext conftest.$ac_ext
4829 CPPFLAGS=$cf_save_CPPFLAGS
4834 if test "$cf_have_incdir" = no ; then
4835 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
4837 echo "${as_me:-configure}:4837: testing adding $cf_add_incdir to include-path ..." 1>&5
4839 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
4841 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
4842 test "$cf_top_incdir" = "$cf_add_incdir" && break
4843 cf_add_incdir="$cf_top_incdir"
4856 echo "$as_me:4856: checking for $cf_ncuhdr_root header in include-path" >&5
4857 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
4858 if test "${cf_cv_ncurses_h+set}" = set; then
4859 echo $ECHO_N "(cached) $ECHO_C" >&6
4862 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
4863 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
4864 for cf_header in $cf_header_list
4867 cat >conftest.$ac_ext <<_ACEOF
4868 #line 4868 "configure"
4869 #include "confdefs.h"
4871 #include <$cf_header>
4876 #ifdef NCURSES_VERSION
4878 printf("%s\n", NCURSES_VERSION);
4891 rm -f conftest.$ac_objext
4892 if { (eval echo "$as_me:4892: \"$ac_compile\"") >&5
4893 (eval $ac_compile) 2>&5
4895 echo "$as_me:4895: \$? = $ac_status" >&5
4896 (exit $ac_status); } &&
4897 { ac_try='test -s conftest.$ac_objext'
4898 { (eval echo "$as_me:4898: \"$ac_try\"") >&5
4901 echo "$as_me:4901: \$? = $ac_status" >&5
4902 (exit $ac_status); }; }; then
4903 cf_cv_ncurses_h=$cf_header
4906 echo "$as_me: failed program was:" >&5
4907 cat conftest.$ac_ext >&5
4910 rm -f conftest.$ac_objext conftest.$ac_ext
4912 test "$cf_cv_ncurses_h" != no && break
4916 echo "$as_me:4916: result: $cf_cv_ncurses_h" >&5
4917 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
4919 if test "$cf_cv_ncurses_h" != no ; then
4920 cf_cv_ncurses_header=$cf_cv_ncurses_h
4923 echo "$as_me:4923: checking for $cf_ncuhdr_root include-path" >&5
4924 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
4925 if test "${cf_cv_ncurses_h2+set}" = set; then
4926 echo $ECHO_N "(cached) $ECHO_C" >&6
4929 test -n "$verbose" && echo
4933 # collect the current set of include-directories from compiler flags
4934 cf_header_path_list=""
4935 if test -n "${CFLAGS}${CPPFLAGS}" ; then
4936 for cf_header_path in $CPPFLAGS $CFLAGS
4938 case $cf_header_path in
4940 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
4942 test "x$cf_header_path" != "xNONE" && \
4943 test -d "$cf_header_path" && \
4945 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
4946 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
4947 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
4948 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
4949 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
4950 test -d $cf_header_path/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
4953 cf_header_path_list="$cf_header_path_list $cf_search"
4959 # add the variations for the package we are looking for
4963 test "x$prefix" != "xNONE" && \
4964 test -d "$prefix" && \
4966 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
4967 test -d $prefix/include && cf_search="$cf_search $prefix/include"
4968 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
4969 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
4970 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
4971 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
4974 for cf_subdir_prefix in \
4983 test "x$cf_subdir_prefix" != "x$prefix" && \
4984 test -d "$cf_subdir_prefix" && \
4985 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
4986 test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
4987 test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include"
4988 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root"
4989 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root/include"
4990 test -d $cf_subdir_prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include"
4991 test -d $cf_subdir_prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
4996 test "$includedir" != NONE && \
4997 test "$includedir" != "/usr/include" && \
4998 test -d "$includedir" && {
4999 test -d $includedir && cf_search="$cf_search $includedir"
5000 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
5003 test "$oldincludedir" != NONE && \
5004 test "$oldincludedir" != "/usr/include" && \
5005 test -d "$oldincludedir" && {
5006 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
5007 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
5010 cf_search="$cf_search $cf_header_path_list"
5012 test -n "$verbose" && echo search path $cf_search
5013 cf_save2_CPPFLAGS="$CPPFLAGS"
5014 for cf_incdir in $cf_search
5017 if test -n "$cf_incdir" ; then
5018 for cf_add_incdir in $cf_incdir
5020 while test $cf_add_incdir != /usr/include
5022 if test -d $cf_add_incdir
5025 if test -n "$CFLAGS$CPPFLAGS" ; then
5026 # a loop is needed to ensure we can add subdirs of existing dirs
5027 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
5028 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
5029 cf_have_incdir=yes; break
5034 if test "$cf_have_incdir" = no ; then
5035 if test "$cf_add_incdir" = /usr/local/include ; then
5036 if test "$GCC" = yes
5038 cf_save_CPPFLAGS=$CPPFLAGS
5040 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5041 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
5043 cat >conftest.$ac_ext <<_ACEOF
5044 #line 5044 "configure"
5045 #include "confdefs.h"
5055 rm -f conftest.$ac_objext
5056 if { (eval echo "$as_me:5056: \"$ac_compile\"") >&5
5057 (eval $ac_compile) 2>&5
5059 echo "$as_me:5059: \$? = $ac_status" >&5
5060 (exit $ac_status); } &&
5061 { ac_try='test -s conftest.$ac_objext'
5062 { (eval echo "$as_me:5062: \"$ac_try\"") >&5
5065 echo "$as_me:5065: \$? = $ac_status" >&5
5066 (exit $ac_status); }; }; then
5069 echo "$as_me: failed program was:" >&5
5070 cat conftest.$ac_ext >&5
5073 rm -f conftest.$ac_objext conftest.$ac_ext
5074 CPPFLAGS=$cf_save_CPPFLAGS
5079 if test "$cf_have_incdir" = no ; then
5080 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
5082 echo "${as_me:-configure}:5082: testing adding $cf_add_incdir to include-path ..." 1>&5
5084 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
5086 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
5087 test "$cf_top_incdir" = "$cf_add_incdir" && break
5088 cf_add_incdir="$cf_top_incdir"
5104 cat >conftest.$ac_ext <<_ACEOF
5105 #line 5105 "configure"
5106 #include "confdefs.h"
5108 #include <$cf_header>
5113 #ifdef NCURSES_VERSION
5115 printf("%s\n", NCURSES_VERSION);
5128 rm -f conftest.$ac_objext
5129 if { (eval echo "$as_me:5129: \"$ac_compile\"") >&5
5130 (eval $ac_compile) 2>&5
5132 echo "$as_me:5132: \$? = $ac_status" >&5
5133 (exit $ac_status); } &&
5134 { ac_try='test -s conftest.$ac_objext'
5135 { (eval echo "$as_me:5135: \"$ac_try\"") >&5
5138 echo "$as_me:5138: \$? = $ac_status" >&5
5139 (exit $ac_status); }; }; then
5140 cf_cv_ncurses_h2=$cf_header
5143 echo "$as_me: failed program was:" >&5
5144 cat conftest.$ac_ext >&5
5147 rm -f conftest.$ac_objext conftest.$ac_ext
5149 if test "$cf_cv_ncurses_h2" != no ; then
5150 cf_cv_ncurses_h2=$cf_incdir/$cf_header
5151 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
5154 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
5156 CPPFLAGS="$cf_save2_CPPFLAGS"
5157 test "$cf_cv_ncurses_h2" != no && break
5159 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:5159: error: not found" >&5
5160 echo "$as_me: error: not found" >&2;}
5161 { (exit 1); exit 1; }; }
5164 echo "$as_me:5164: result: $cf_cv_ncurses_h2" >&5
5165 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
5167 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
5168 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
5169 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
5170 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
5173 if test -n "$cf_1st_incdir" ; then
5174 for cf_add_incdir in $cf_1st_incdir
5176 while test $cf_add_incdir != /usr/include
5178 if test -d $cf_add_incdir
5181 if test -n "$CFLAGS$CPPFLAGS" ; then
5182 # a loop is needed to ensure we can add subdirs of existing dirs
5183 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
5184 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
5185 cf_have_incdir=yes; break
5190 if test "$cf_have_incdir" = no ; then
5191 if test "$cf_add_incdir" = /usr/local/include ; then
5192 if test "$GCC" = yes
5194 cf_save_CPPFLAGS=$CPPFLAGS
5196 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5197 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
5199 cat >conftest.$ac_ext <<_ACEOF
5200 #line 5200 "configure"
5201 #include "confdefs.h"
5211 rm -f conftest.$ac_objext
5212 if { (eval echo "$as_me:5212: \"$ac_compile\"") >&5
5213 (eval $ac_compile) 2>&5
5215 echo "$as_me:5215: \$? = $ac_status" >&5
5216 (exit $ac_status); } &&
5217 { ac_try='test -s conftest.$ac_objext'
5218 { (eval echo "$as_me:5218: \"$ac_try\"") >&5
5221 echo "$as_me:5221: \$? = $ac_status" >&5
5222 (exit $ac_status); }; }; then
5225 echo "$as_me: failed program was:" >&5
5226 cat conftest.$ac_ext >&5
5229 rm -f conftest.$ac_objext conftest.$ac_ext
5230 CPPFLAGS=$cf_save_CPPFLAGS
5235 if test "$cf_have_incdir" = no ; then
5236 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
5238 echo "${as_me:-configure}:5238: testing adding $cf_add_incdir to include-path ..." 1>&5
5240 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
5242 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
5243 test "$cf_top_incdir" = "$cf_add_incdir" && break
5244 cf_add_incdir="$cf_top_incdir"
5257 # Set definitions to allow ifdef'ing for ncurses.h
5259 case $cf_cv_ncurses_header in
5262 cat >>confdefs.h <<\EOF
5263 #define HAVE_NCURSES_H 1
5269 case $cf_cv_ncurses_header in
5270 (ncurses/curses.h|ncurses/ncurses.h)
5272 cat >>confdefs.h <<\EOF
5273 #define HAVE_NCURSES_NCURSES_H 1
5277 (ncursesw/curses.h|ncursesw/ncurses.h)
5279 cat >>confdefs.h <<\EOF
5280 #define HAVE_NCURSESW_NCURSES_H 1
5286 echo "$as_me:5286: checking for terminfo header" >&5
5287 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
5288 if test "${cf_cv_term_header+set}" = set; then
5289 echo $ECHO_N "(cached) $ECHO_C" >&6
5292 case ${cf_cv_ncurses_header} in
5293 (*/ncurses.h|*/ncursesw.h)
5294 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
5297 cf_term_header=term.h
5301 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
5303 cat >conftest.$ac_ext <<_ACEOF
5304 #line 5304 "configure"
5305 #include "confdefs.h"
5307 #include <${cf_cv_ncurses_header:-curses.h}>
5313 int x = auto_left_margin
5318 rm -f conftest.$ac_objext
5319 if { (eval echo "$as_me:5319: \"$ac_compile\"") >&5
5320 (eval $ac_compile) 2>&5
5322 echo "$as_me:5322: \$? = $ac_status" >&5
5323 (exit $ac_status); } &&
5324 { ac_try='test -s conftest.$ac_objext'
5325 { (eval echo "$as_me:5325: \"$ac_try\"") >&5
5328 echo "$as_me:5328: \$? = $ac_status" >&5
5329 (exit $ac_status); }; }; then
5331 cf_cv_term_header="$cf_test"
5333 echo "$as_me: failed program was:" >&5
5334 cat conftest.$ac_ext >&5
5336 cf_cv_term_header=unknown
5339 rm -f conftest.$ac_objext conftest.$ac_ext
5340 test "$cf_cv_term_header" != unknown && break
5344 echo "$as_me:5344: result: $cf_cv_term_header" >&5
5345 echo "${ECHO_T}$cf_cv_term_header" >&6
5347 # Set definitions to allow ifdef'ing to accommodate subdirectories
5349 case $cf_cv_term_header in
5352 cat >>confdefs.h <<\EOF
5353 #define HAVE_TERM_H 1
5359 case $cf_cv_term_header in
5362 cat >>confdefs.h <<\EOF
5363 #define HAVE_NCURSES_TERM_H 1
5369 cat >>confdefs.h <<\EOF
5370 #define HAVE_NCURSESW_TERM_H 1
5376 # some applications need this, but should check for NCURSES_VERSION
5378 cat >>confdefs.h <<\EOF
5382 echo "$as_me:5382: checking for ncurses version" >&5
5383 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
5384 if test "${cf_cv_ncurses_version+set}" = set; then
5385 echo $ECHO_N "(cached) $ECHO_C" >&6
5388 cf_cv_ncurses_version=no
5391 if test "$cross_compiling" = yes; then
5393 # This will not work if the preprocessor splits the line after the
5394 # Autoconf token. The 'unproto' program does that.
5395 cat > conftest.$ac_ext <<EOF
5396 #include <${cf_cv_ncurses_header:-curses.h}>
5398 #ifdef NCURSES_VERSION
5399 Autoconf NCURSES_VERSION
5407 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
5408 { (eval echo "$as_me:5408: \"$cf_try\"") >&5
5411 echo "$as_me:5411: \$? = $ac_status" >&5
5412 (exit $ac_status); }
5413 if test -f conftest.out ; then
5414 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
5415 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
5420 cat >conftest.$ac_ext <<_ACEOF
5421 #line 5421 "configure"
5422 #include "confdefs.h"
5424 #include <${cf_cv_ncurses_header:-curses.h}>
5428 FILE *fp = fopen("$cf_tempfile", "w");
5429 #ifdef NCURSES_VERSION
5430 # ifdef NCURSES_VERSION_PATCH
5431 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
5433 fprintf(fp, "%s\n", NCURSES_VERSION);
5437 fprintf(fp, "old\n");
5442 ${cf_cv_main_return:-return}(0);
5445 rm -f conftest$ac_exeext
5446 if { (eval echo "$as_me:5446: \"$ac_link\"") >&5
5447 (eval $ac_link) 2>&5
5449 echo "$as_me:5449: \$? = $ac_status" >&5
5450 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5451 { (eval echo "$as_me:5451: \"$ac_try\"") >&5
5454 echo "$as_me:5454: \$? = $ac_status" >&5
5455 (exit $ac_status); }; }; then
5457 cf_cv_ncurses_version=`cat $cf_tempfile`
5459 echo "$as_me: program exited with status $ac_status" >&5
5460 echo "$as_me: failed program was:" >&5
5461 cat conftest.$ac_ext >&5
5463 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
5468 echo "$as_me:5468: result: $cf_cv_ncurses_version" >&5
5469 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
5470 test "$cf_cv_ncurses_version" = no ||
5471 cat >>confdefs.h <<\EOF
5475 cf_nculib_root=ncurses
5476 # This works, except for the special case where we find gpm, but
5477 # ncurses is in a nonstandard location via $LIBS, and we really want
5480 cf_ncurses_SAVE="$LIBS"
5481 echo "$as_me:5481: checking for Gpm_Open in -lgpm" >&5
5482 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
5483 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
5484 echo $ECHO_N "(cached) $ECHO_C" >&6
5486 ac_check_lib_save_LIBS=$LIBS
5488 cat >conftest.$ac_ext <<_ACEOF
5489 #line 5489 "configure"
5490 #include "confdefs.h"
5492 /* Override any gcc2 internal prototype to avoid an error. */
5496 /* We use char because int might match the return type of a gcc2
5497 builtin and then its argument prototype would still apply. */
5507 rm -f conftest.$ac_objext conftest$ac_exeext
5508 if { (eval echo "$as_me:5508: \"$ac_link\"") >&5
5509 (eval $ac_link) 2>&5
5511 echo "$as_me:5511: \$? = $ac_status" >&5
5512 (exit $ac_status); } &&
5513 { ac_try='test -s conftest$ac_exeext'
5514 { (eval echo "$as_me:5514: \"$ac_try\"") >&5
5517 echo "$as_me:5517: \$? = $ac_status" >&5
5518 (exit $ac_status); }; }; then
5519 ac_cv_lib_gpm_Gpm_Open=yes
5521 echo "$as_me: failed program was:" >&5
5522 cat conftest.$ac_ext >&5
5523 ac_cv_lib_gpm_Gpm_Open=no
5525 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5526 LIBS=$ac_check_lib_save_LIBS
5528 echo "$as_me:5528: result: $ac_cv_lib_gpm_Gpm_Open" >&5
5529 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
5530 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
5531 echo "$as_me:5531: checking for initscr in -lgpm" >&5
5532 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
5533 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
5534 echo $ECHO_N "(cached) $ECHO_C" >&6
5536 ac_check_lib_save_LIBS=$LIBS
5538 cat >conftest.$ac_ext <<_ACEOF
5539 #line 5539 "configure"
5540 #include "confdefs.h"
5542 /* Override any gcc2 internal prototype to avoid an error. */
5546 /* We use char because int might match the return type of a gcc2
5547 builtin and then its argument prototype would still apply. */
5557 rm -f conftest.$ac_objext conftest$ac_exeext
5558 if { (eval echo "$as_me:5558: \"$ac_link\"") >&5
5559 (eval $ac_link) 2>&5
5561 echo "$as_me:5561: \$? = $ac_status" >&5
5562 (exit $ac_status); } &&
5563 { ac_try='test -s conftest$ac_exeext'
5564 { (eval echo "$as_me:5564: \"$ac_try\"") >&5
5567 echo "$as_me:5567: \$? = $ac_status" >&5
5568 (exit $ac_status); }; }; then
5569 ac_cv_lib_gpm_initscr=yes
5571 echo "$as_me: failed program was:" >&5
5572 cat conftest.$ac_ext >&5
5573 ac_cv_lib_gpm_initscr=no
5575 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5576 LIBS=$ac_check_lib_save_LIBS
5578 echo "$as_me:5578: result: $ac_cv_lib_gpm_initscr" >&5
5579 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
5580 if test $ac_cv_lib_gpm_initscr = yes; then
5581 LIBS="$cf_ncurses_SAVE"
5583 cf_ncurses_LIBS="-lgpm"
5590 # This is only necessary if you are linking against an obsolete
5591 # version of ncurses (but it should do no harm, since it's static).
5592 if test "$cf_nculib_root" = ncurses ; then
5593 echo "$as_me:5593: checking for tgoto in -lmytinfo" >&5
5594 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
5595 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
5596 echo $ECHO_N "(cached) $ECHO_C" >&6
5598 ac_check_lib_save_LIBS=$LIBS
5599 LIBS="-lmytinfo $LIBS"
5600 cat >conftest.$ac_ext <<_ACEOF
5601 #line 5601 "configure"
5602 #include "confdefs.h"
5604 /* Override any gcc2 internal prototype to avoid an error. */
5608 /* We use char because int might match the return type of a gcc2
5609 builtin and then its argument prototype would still apply. */
5619 rm -f conftest.$ac_objext conftest$ac_exeext
5620 if { (eval echo "$as_me:5620: \"$ac_link\"") >&5
5621 (eval $ac_link) 2>&5
5623 echo "$as_me:5623: \$? = $ac_status" >&5
5624 (exit $ac_status); } &&
5625 { ac_try='test -s conftest$ac_exeext'
5626 { (eval echo "$as_me:5626: \"$ac_try\"") >&5
5629 echo "$as_me:5629: \$? = $ac_status" >&5
5630 (exit $ac_status); }; }; then
5631 ac_cv_lib_mytinfo_tgoto=yes
5633 echo "$as_me: failed program was:" >&5
5634 cat conftest.$ac_ext >&5
5635 ac_cv_lib_mytinfo_tgoto=no
5637 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5638 LIBS=$ac_check_lib_save_LIBS
5640 echo "$as_me:5640: result: $ac_cv_lib_mytinfo_tgoto" >&5
5641 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
5642 if test $ac_cv_lib_mytinfo_tgoto = yes; then
5643 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
5653 for cf_add_1lib in $cf_ncurses_LIBS; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
5655 for cf_add_1lib in $cf_add_0lib; do
5656 for cf_add_2lib in $cf_add_libs; do
5657 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
5662 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
5666 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
5672 for cf_add_1lib in -l$cf_nculib_root; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
5674 for cf_add_1lib in $cf_add_0lib; do
5675 for cf_add_2lib in $cf_add_libs; do
5676 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
5681 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
5687 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
5689 echo "$as_me:5689: checking for initscr" >&5
5690 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
5691 if test "${ac_cv_func_initscr+set}" = set; then
5692 echo $ECHO_N "(cached) $ECHO_C" >&6
5694 cat >conftest.$ac_ext <<_ACEOF
5695 #line 5695 "configure"
5696 #include "confdefs.h"
5697 #define initscr autoconf_temporary
5698 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
5705 /* We use char because int might match the return type of a gcc2
5706 builtin and then its argument prototype would still apply. */
5707 char initscr (void);
5713 /* The GNU C library defines stubs for functions which it implements
5714 to always fail with ENOSYS. Some functions are actually named
5715 something starting with __ and the normal name is an alias. */
5716 #if defined (__stub_initscr) || defined (__stub___initscr)
5717 #error found stub for initscr
5725 rm -f conftest.$ac_objext conftest$ac_exeext
5726 if { (eval echo "$as_me:5726: \"$ac_link\"") >&5
5727 (eval $ac_link) 2>&5
5729 echo "$as_me:5729: \$? = $ac_status" >&5
5730 (exit $ac_status); } &&
5731 { ac_try='test -s conftest$ac_exeext'
5732 { (eval echo "$as_me:5732: \"$ac_try\"") >&5
5735 echo "$as_me:5735: \$? = $ac_status" >&5
5736 (exit $ac_status); }; }; then
5737 ac_cv_func_initscr=yes
5739 echo "$as_me: failed program was:" >&5
5740 cat conftest.$ac_ext >&5
5741 ac_cv_func_initscr=no
5743 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5745 echo "$as_me:5745: result: $ac_cv_func_initscr" >&5
5746 echo "${ECHO_T}$ac_cv_func_initscr" >&6
5747 if test $ac_cv_func_initscr = yes; then
5748 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
5751 cf_save_LIBS="$LIBS"
5752 echo "$as_me:5752: checking for initscr in -l$cf_nculib_root" >&5
5753 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
5754 LIBS="-l$cf_nculib_root $LIBS"
5755 cat >conftest.$ac_ext <<_ACEOF
5756 #line 5756 "configure"
5757 #include "confdefs.h"
5758 #include <${cf_cv_ncurses_header:-curses.h}>
5767 rm -f conftest.$ac_objext conftest$ac_exeext
5768 if { (eval echo "$as_me:5768: \"$ac_link\"") >&5
5769 (eval $ac_link) 2>&5
5771 echo "$as_me:5771: \$? = $ac_status" >&5
5772 (exit $ac_status); } &&
5773 { ac_try='test -s conftest$ac_exeext'
5774 { (eval echo "$as_me:5774: \"$ac_try\"") >&5
5777 echo "$as_me:5777: \$? = $ac_status" >&5
5778 (exit $ac_status); }; }; then
5779 echo "$as_me:5779: result: yes" >&5
5780 echo "${ECHO_T}yes" >&6
5781 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
5784 echo "$as_me: failed program was:" >&5
5785 cat conftest.$ac_ext >&5
5786 echo "$as_me:5786: result: no" >&5
5787 echo "${ECHO_T}no" >&6
5790 cf_library_path_list=""
5791 if test -n "${LDFLAGS}${LIBS}" ; then
5792 for cf_library_path in $LDFLAGS $LIBS
5794 case $cf_library_path in
5796 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
5798 test "x$cf_library_path" != "xNONE" && \
5799 test -d "$cf_library_path" && \
5801 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
5802 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
5803 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
5804 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
5805 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
5806 test -d $cf_library_path/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib/$cf_nculib_root"
5809 cf_library_path_list="$cf_library_path_list $cf_search"
5817 test "x$prefix" != "xNONE" && \
5818 test -d "$prefix" && \
5820 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
5821 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
5822 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
5823 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
5824 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
5825 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
5828 for cf_subdir_prefix in \
5837 test "x$cf_subdir_prefix" != "x$prefix" && \
5838 test -d "$cf_subdir_prefix" && \
5839 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
5840 test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
5841 test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib"
5842 test -d $cf_subdir_prefix/lib/$cf_nculib_root && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root"
5843 test -d $cf_subdir_prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root/lib"
5844 test -d $cf_subdir_prefix/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib"
5845 test -d $cf_subdir_prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib/$cf_nculib_root"
5850 cf_search="$cf_library_path_list $cf_search"
5852 for cf_libdir in $cf_search
5854 echo "$as_me:5854: checking for -l$cf_nculib_root in $cf_libdir" >&5
5855 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
5856 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
5857 cat >conftest.$ac_ext <<_ACEOF
5858 #line 5858 "configure"
5859 #include "confdefs.h"
5860 #include <${cf_cv_ncurses_header:-curses.h}>
5869 rm -f conftest.$ac_objext conftest$ac_exeext
5870 if { (eval echo "$as_me:5870: \"$ac_link\"") >&5
5871 (eval $ac_link) 2>&5
5873 echo "$as_me:5873: \$? = $ac_status" >&5
5874 (exit $ac_status); } &&
5875 { ac_try='test -s conftest$ac_exeext'
5876 { (eval echo "$as_me:5876: \"$ac_try\"") >&5
5879 echo "$as_me:5879: \$? = $ac_status" >&5
5880 (exit $ac_status); }; }; then
5881 echo "$as_me:5881: result: yes" >&5
5882 echo "${ECHO_T}yes" >&6
5883 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
5886 echo "$as_me: failed program was:" >&5
5887 cat conftest.$ac_ext >&5
5888 echo "$as_me:5888: result: no" >&5
5889 echo "${ECHO_T}no" >&6
5890 LIBS="$cf_save_LIBS"
5892 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5896 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5900 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
5902 if test $cf_found_library = no ; then
5903 { { echo "$as_me:5903: error: Cannot link $cf_nculib_root library" >&5
5904 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
5905 { (exit 1); exit 1; }; }
5910 if test -n "$cf_ncurses_LIBS" ; then
5911 echo "$as_me:5911: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
5912 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
5913 cf_ncurses_SAVE="$LIBS"
5914 for p in $cf_ncurses_LIBS ; do
5915 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
5916 if test "$q" != "$LIBS" ; then
5920 cat >conftest.$ac_ext <<_ACEOF
5921 #line 5921 "configure"
5922 #include "confdefs.h"
5923 #include <${cf_cv_ncurses_header:-curses.h}>
5927 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
5932 rm -f conftest.$ac_objext conftest$ac_exeext
5933 if { (eval echo "$as_me:5933: \"$ac_link\"") >&5
5934 (eval $ac_link) 2>&5
5936 echo "$as_me:5936: \$? = $ac_status" >&5
5937 (exit $ac_status); } &&
5938 { ac_try='test -s conftest$ac_exeext'
5939 { (eval echo "$as_me:5939: \"$ac_try\"") >&5
5942 echo "$as_me:5942: \$? = $ac_status" >&5
5943 (exit $ac_status); }; }; then
5944 echo "$as_me:5944: result: yes" >&5
5945 echo "${ECHO_T}yes" >&6
5947 echo "$as_me: failed program was:" >&5
5948 cat conftest.$ac_ext >&5
5949 echo "$as_me:5949: result: no" >&5
5950 echo "${ECHO_T}no" >&6
5951 LIBS="$cf_ncurses_SAVE"
5953 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5956 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
5958 cat >>confdefs.h <<EOF
5959 #define $cf_nculib_ROOT 1
5967 echo "$as_me:5967: checking if you want wide-character code" >&5
5968 echo $ECHO_N "checking if you want wide-character code... $ECHO_C" >&6
5970 # Check whether --enable-widec or --disable-widec was given.
5971 if test "${enable_widec+set}" = set; then
5972 enableval="$enable_widec"
5973 with_widec=$enableval
5977 echo "$as_me:5977: result: $with_widec" >&5
5978 echo "${ECHO_T}$with_widec" >&6
5979 if test "$with_widec" = yes ; then
5981 echo "$as_me:5981: checking for multibyte character support" >&5
5982 echo $ECHO_N "checking for multibyte character support... $ECHO_C" >&6
5983 if test "${cf_cv_utf8_lib+set}" = set; then
5984 echo $ECHO_N "(cached) $ECHO_C" >&6
5987 cf_save_LIBS="$LIBS"
5988 cat >conftest.$ac_ext <<_ACEOF
5989 #line 5989 "configure"
5990 #include "confdefs.h"
6001 rm -f conftest.$ac_objext conftest$ac_exeext
6002 if { (eval echo "$as_me:6002: \"$ac_link\"") >&5
6003 (eval $ac_link) 2>&5
6005 echo "$as_me:6005: \$? = $ac_status" >&5
6006 (exit $ac_status); } &&
6007 { ac_try='test -s conftest$ac_exeext'
6008 { (eval echo "$as_me:6008: \"$ac_try\"") >&5
6011 echo "$as_me:6011: \$? = $ac_status" >&5
6012 (exit $ac_status); }; }; then
6015 echo "$as_me: failed program was:" >&5
6016 cat conftest.$ac_ext >&5
6018 # If the linkage is not already in the $CPPFLAGS/$LDFLAGS configuration, these
6019 # will be set on completion of the AC_TRY_LINK below.
6020 cf_cv_header_path_utf8=
6021 cf_cv_library_path_utf8=
6023 echo "${as_me:-configure}:6023: testing Starting FIND_LINKAGE(utf8,) ..." 1>&5
6025 cf_save_LIBS="$LIBS"
6027 cat >conftest.$ac_ext <<_ACEOF
6028 #line 6028 "configure"
6029 #include "confdefs.h"
6031 #include <libutf8.h>
6040 rm -f conftest.$ac_objext conftest$ac_exeext
6041 if { (eval echo "$as_me:6041: \"$ac_link\"") >&5
6042 (eval $ac_link) 2>&5
6044 echo "$as_me:6044: \$? = $ac_status" >&5
6045 (exit $ac_status); } &&
6046 { ac_try='test -s conftest$ac_exeext'
6047 { (eval echo "$as_me:6047: \"$ac_try\"") >&5
6050 echo "$as_me:6050: \$? = $ac_status" >&5
6051 (exit $ac_status); }; }; then
6053 cf_cv_find_linkage_utf8=yes
6054 cf_cv_header_path_utf8=/usr/include
6055 cf_cv_library_path_utf8=/usr/lib
6058 echo "$as_me: failed program was:" >&5
6059 cat conftest.$ac_ext >&5
6061 LIBS="-lutf8 $cf_save_LIBS"
6063 cat >conftest.$ac_ext <<_ACEOF
6064 #line 6064 "configure"
6065 #include "confdefs.h"
6067 #include <libutf8.h>
6076 rm -f conftest.$ac_objext conftest$ac_exeext
6077 if { (eval echo "$as_me:6077: \"$ac_link\"") >&5
6078 (eval $ac_link) 2>&5
6080 echo "$as_me:6080: \$? = $ac_status" >&5
6081 (exit $ac_status); } &&
6082 { ac_try='test -s conftest$ac_exeext'
6083 { (eval echo "$as_me:6083: \"$ac_try\"") >&5
6086 echo "$as_me:6086: \$? = $ac_status" >&5
6087 (exit $ac_status); }; }; then
6089 cf_cv_find_linkage_utf8=yes
6090 cf_cv_header_path_utf8=/usr/include
6091 cf_cv_library_path_utf8=/usr/lib
6092 cf_cv_library_file_utf8="-lutf8"
6095 echo "$as_me: failed program was:" >&5
6096 cat conftest.$ac_ext >&5
6098 cf_cv_find_linkage_utf8=no
6099 LIBS="$cf_save_LIBS"
6101 test -n "$verbose" && echo " find linkage for utf8 library" 1>&6
6103 echo "${as_me:-configure}:6103: testing find linkage for utf8 library ..." 1>&5
6105 echo "${as_me:-configure}:6105: testing Searching for headers in FIND_LINKAGE(utf8,) ..." 1>&5
6107 cf_save_CPPFLAGS="$CPPFLAGS"
6108 cf_test_CPPFLAGS="$CPPFLAGS"
6112 # collect the current set of include-directories from compiler flags
6113 cf_header_path_list=""
6114 if test -n "${CFLAGS}${CPPFLAGS}" ; then
6115 for cf_header_path in $CPPFLAGS $CFLAGS
6117 case $cf_header_path in
6119 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
6121 test "x$cf_header_path" != "xNONE" && \
6122 test -d "$cf_header_path" && \
6124 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
6125 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
6126 test -d $cf_header_path/include/utf8 && cf_search="$cf_search $cf_header_path/include/utf8"
6127 test -d $cf_header_path/include/utf8/include && cf_search="$cf_search $cf_header_path/include/utf8/include"
6128 test -d $cf_header_path/utf8/include && cf_search="$cf_search $cf_header_path/utf8/include"
6129 test -d $cf_header_path/utf8/include/utf8 && cf_search="$cf_search $cf_header_path/utf8/include/utf8"
6132 cf_header_path_list="$cf_header_path_list $cf_search"
6138 # add the variations for the package we are looking for
6142 test "x$prefix" != "xNONE" && \
6143 test -d "$prefix" && \
6145 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
6146 test -d $prefix/include && cf_search="$cf_search $prefix/include"
6147 test -d $prefix/include/utf8 && cf_search="$cf_search $prefix/include/utf8"
6148 test -d $prefix/include/utf8/include && cf_search="$cf_search $prefix/include/utf8/include"
6149 test -d $prefix/utf8/include && cf_search="$cf_search $prefix/utf8/include"
6150 test -d $prefix/utf8/include/utf8 && cf_search="$cf_search $prefix/utf8/include/utf8"
6153 for cf_subdir_prefix in \
6162 test "x$cf_subdir_prefix" != "x$prefix" && \
6163 test -d "$cf_subdir_prefix" && \
6164 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
6165 test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
6166 test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include"
6167 test -d $cf_subdir_prefix/include/utf8 && cf_search="$cf_search $cf_subdir_prefix/include/utf8"
6168 test -d $cf_subdir_prefix/include/utf8/include && cf_search="$cf_search $cf_subdir_prefix/include/utf8/include"
6169 test -d $cf_subdir_prefix/utf8/include && cf_search="$cf_search $cf_subdir_prefix/utf8/include"
6170 test -d $cf_subdir_prefix/utf8/include/utf8 && cf_search="$cf_search $cf_subdir_prefix/utf8/include/utf8"
6175 test "$includedir" != NONE && \
6176 test "$includedir" != "/usr/include" && \
6177 test -d "$includedir" && {
6178 test -d $includedir && cf_search="$cf_search $includedir"
6179 test -d $includedir/utf8 && cf_search="$cf_search $includedir/utf8"
6182 test "$oldincludedir" != NONE && \
6183 test "$oldincludedir" != "/usr/include" && \
6184 test -d "$oldincludedir" && {
6185 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
6186 test -d $oldincludedir/utf8 && cf_search="$cf_search $oldincludedir/utf8"
6189 cf_search="$cf_search $cf_header_path_list"
6191 for cf_cv_header_path_utf8 in $cf_search
6193 if test -d $cf_cv_header_path_utf8 ; then
6194 test -n "$verbose" && echo " ... testing $cf_cv_header_path_utf8" 1>&6
6196 echo "${as_me:-configure}:6196: testing ... testing $cf_cv_header_path_utf8 ..." 1>&5
6198 CPPFLAGS="$cf_save_CPPFLAGS"
6200 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
6201 CPPFLAGS="${CPPFLAGS}-I$cf_cv_header_path_utf8"
6203 cat >conftest.$ac_ext <<_ACEOF
6204 #line 6204 "configure"
6205 #include "confdefs.h"
6207 #include <libutf8.h>
6216 rm -f conftest.$ac_objext
6217 if { (eval echo "$as_me:6217: \"$ac_compile\"") >&5
6218 (eval $ac_compile) 2>&5
6220 echo "$as_me:6220: \$? = $ac_status" >&5
6221 (exit $ac_status); } &&
6222 { ac_try='test -s conftest.$ac_objext'
6223 { (eval echo "$as_me:6223: \"$ac_try\"") >&5
6226 echo "$as_me:6226: \$? = $ac_status" >&5
6227 (exit $ac_status); }; }; then
6229 test -n "$verbose" && echo " ... found utf8 headers in $cf_cv_header_path_utf8" 1>&6
6231 echo "${as_me:-configure}:6231: testing ... found utf8 headers in $cf_cv_header_path_utf8 ..." 1>&5
6233 cf_cv_find_linkage_utf8=maybe
6234 cf_test_CPPFLAGS="$CPPFLAGS"
6237 echo "$as_me: failed program was:" >&5
6238 cat conftest.$ac_ext >&5
6240 CPPFLAGS="$cf_save_CPPFLAGS"
6243 rm -f conftest.$ac_objext conftest.$ac_ext
6247 if test "$cf_cv_find_linkage_utf8" = maybe ; then
6249 echo "${as_me:-configure}:6249: testing Searching for utf8 library in FIND_LINKAGE(utf8,) ..." 1>&5
6251 cf_save_LIBS="$LIBS"
6252 cf_save_LDFLAGS="$LDFLAGS"
6254 if test "$cf_cv_find_linkage_utf8" != yes ; then
6257 cf_library_path_list=""
6258 if test -n "${LDFLAGS}${LIBS}" ; then
6259 for cf_library_path in $LDFLAGS $LIBS
6261 case $cf_library_path in
6263 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
6265 test "x$cf_library_path" != "xNONE" && \
6266 test -d "$cf_library_path" && \
6268 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
6269 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
6270 test -d $cf_library_path/lib/utf8 && cf_search="$cf_search $cf_library_path/lib/utf8"
6271 test -d $cf_library_path/lib/utf8/lib && cf_search="$cf_search $cf_library_path/lib/utf8/lib"
6272 test -d $cf_library_path/utf8/lib && cf_search="$cf_search $cf_library_path/utf8/lib"
6273 test -d $cf_library_path/utf8/lib/utf8 && cf_search="$cf_search $cf_library_path/utf8/lib/utf8"
6276 cf_library_path_list="$cf_library_path_list $cf_search"
6284 test "x$prefix" != "xNONE" && \
6285 test -d "$prefix" && \
6287 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
6288 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
6289 test -d $prefix/lib/utf8 && cf_search="$cf_search $prefix/lib/utf8"
6290 test -d $prefix/lib/utf8/lib && cf_search="$cf_search $prefix/lib/utf8/lib"
6291 test -d $prefix/utf8/lib && cf_search="$cf_search $prefix/utf8/lib"
6292 test -d $prefix/utf8/lib/utf8 && cf_search="$cf_search $prefix/utf8/lib/utf8"
6295 for cf_subdir_prefix in \
6304 test "x$cf_subdir_prefix" != "x$prefix" && \
6305 test -d "$cf_subdir_prefix" && \
6306 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
6307 test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
6308 test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib"
6309 test -d $cf_subdir_prefix/lib/utf8 && cf_search="$cf_search $cf_subdir_prefix/lib/utf8"
6310 test -d $cf_subdir_prefix/lib/utf8/lib && cf_search="$cf_search $cf_subdir_prefix/lib/utf8/lib"
6311 test -d $cf_subdir_prefix/utf8/lib && cf_search="$cf_search $cf_subdir_prefix/utf8/lib"
6312 test -d $cf_subdir_prefix/utf8/lib/utf8 && cf_search="$cf_search $cf_subdir_prefix/utf8/lib/utf8"
6317 cf_search="$cf_library_path_list $cf_search"
6319 for cf_cv_library_path_utf8 in $cf_search
6321 if test -d $cf_cv_library_path_utf8 ; then
6322 test -n "$verbose" && echo " ... testing $cf_cv_library_path_utf8" 1>&6
6324 echo "${as_me:-configure}:6324: testing ... testing $cf_cv_library_path_utf8 ..." 1>&5
6326 CPPFLAGS="$cf_test_CPPFLAGS"
6327 LIBS="-lutf8 $cf_save_LIBS"
6328 LDFLAGS="$cf_save_LDFLAGS -L$cf_cv_library_path_utf8"
6329 cat >conftest.$ac_ext <<_ACEOF
6330 #line 6330 "configure"
6331 #include "confdefs.h"
6333 #include <libutf8.h>
6342 rm -f conftest.$ac_objext conftest$ac_exeext
6343 if { (eval echo "$as_me:6343: \"$ac_link\"") >&5
6344 (eval $ac_link) 2>&5
6346 echo "$as_me:6346: \$? = $ac_status" >&5
6347 (exit $ac_status); } &&
6348 { ac_try='test -s conftest$ac_exeext'
6349 { (eval echo "$as_me:6349: \"$ac_try\"") >&5
6352 echo "$as_me:6352: \$? = $ac_status" >&5
6353 (exit $ac_status); }; }; then
6355 test -n "$verbose" && echo " ... found utf8 library in $cf_cv_library_path_utf8" 1>&6
6357 echo "${as_me:-configure}:6357: testing ... found utf8 library in $cf_cv_library_path_utf8 ..." 1>&5
6359 cf_cv_find_linkage_utf8=yes
6360 cf_cv_library_file_utf8="-lutf8"
6363 echo "$as_me: failed program was:" >&5
6364 cat conftest.$ac_ext >&5
6366 CPPFLAGS="$cf_save_CPPFLAGS"
6367 LIBS="$cf_save_LIBS"
6368 LDFLAGS="$cf_save_LDFLAGS"
6371 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6374 CPPFLAGS="$cf_save_CPPFLAGS"
6375 LDFLAGS="$cf_save_LDFLAGS"
6379 cf_cv_find_linkage_utf8=no
6383 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6386 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6388 LIBS="$cf_save_LIBS"
6390 if test "$cf_cv_find_linkage_utf8" = yes ; then
6391 cf_cv_utf8_lib=add-on
6397 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6399 echo "$as_me:6399: result: $cf_cv_utf8_lib" >&5
6400 echo "${ECHO_T}$cf_cv_utf8_lib" >&6
6402 # HAVE_LIBUTF8_H is used by ncurses if curses.h is shared between
6404 if test "$cf_cv_utf8_lib" = "add-on" ; then
6406 cat >>confdefs.h <<\EOF
6407 #define HAVE_LIBUTF8_H 1
6410 if test -n "$cf_cv_header_path_utf8" ; then
6411 for cf_add_incdir in $cf_cv_header_path_utf8
6413 while test $cf_add_incdir != /usr/include
6415 if test -d $cf_add_incdir
6418 if test -n "$CFLAGS$CPPFLAGS" ; then
6419 # a loop is needed to ensure we can add subdirs of existing dirs
6420 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
6421 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
6422 cf_have_incdir=yes; break
6427 if test "$cf_have_incdir" = no ; then
6428 if test "$cf_add_incdir" = /usr/local/include ; then
6429 if test "$GCC" = yes
6431 cf_save_CPPFLAGS=$CPPFLAGS
6433 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
6434 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
6436 cat >conftest.$ac_ext <<_ACEOF
6437 #line 6437 "configure"
6438 #include "confdefs.h"
6448 rm -f conftest.$ac_objext
6449 if { (eval echo "$as_me:6449: \"$ac_compile\"") >&5
6450 (eval $ac_compile) 2>&5
6452 echo "$as_me:6452: \$? = $ac_status" >&5
6453 (exit $ac_status); } &&
6454 { ac_try='test -s conftest.$ac_objext'
6455 { (eval echo "$as_me:6455: \"$ac_try\"") >&5
6458 echo "$as_me:6458: \$? = $ac_status" >&5
6459 (exit $ac_status); }; }; then
6462 echo "$as_me: failed program was:" >&5
6463 cat conftest.$ac_ext >&5
6466 rm -f conftest.$ac_objext conftest.$ac_ext
6467 CPPFLAGS=$cf_save_CPPFLAGS
6472 if test "$cf_have_incdir" = no ; then
6473 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
6475 echo "${as_me:-configure}:6475: testing adding $cf_add_incdir to include-path ..." 1>&5
6477 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6479 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
6480 test "$cf_top_incdir" = "$cf_add_incdir" && break
6481 cf_add_incdir="$cf_top_incdir"
6492 if test -n "$cf_cv_library_path_utf8" ; then
6493 for cf_add_libdir in $cf_cv_library_path_utf8
6495 if test $cf_add_libdir = /usr/lib ; then
6497 elif test -d $cf_add_libdir
6500 if test -n "$LDFLAGS$LIBS" ; then
6501 # a loop is needed to ensure we can add subdirs of existing dirs
6502 for cf_test_libdir in $LDFLAGS $LIBS ; do
6503 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
6504 cf_have_libdir=yes; break
6508 if test "$cf_have_libdir" = no ; then
6509 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
6511 echo "${as_me:-configure}:6511: testing adding $cf_add_libdir to library-path ..." 1>&5
6513 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
6522 for cf_add_1lib in $cf_cv_library_file_utf8; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
6524 for cf_add_1lib in $cf_add_0lib; do
6525 for cf_add_2lib in $cf_add_libs; do
6526 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
6531 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
6537 cf_ncuconfig_root=ncursesw
6538 cf_have_ncuconfig=no
6540 if test "x${PKG_CONFIG:=none}" != xnone; then
6541 echo "$as_me:6541: checking pkg-config for $cf_ncuconfig_root" >&5
6542 echo $ECHO_N "checking pkg-config for $cf_ncuconfig_root... $ECHO_C" >&6
6543 if "$PKG_CONFIG" --exists $cf_ncuconfig_root ; then
6544 echo "$as_me:6544: result: yes" >&5
6545 echo "${ECHO_T}yes" >&6
6547 echo "$as_me:6547: checking if the $cf_ncuconfig_root package files work" >&5
6548 echo $ECHO_N "checking if the $cf_ncuconfig_root package files work... $ECHO_C" >&6
6549 cf_have_ncuconfig=unknown
6551 cf_save_CPPFLAGS="$CPPFLAGS"
6552 cf_save_LIBS="$LIBS"
6557 cf_new_extra_cppflags=
6559 for cf_add_cflags in `$PKG_CONFIG --cflags $cf_ncuconfig_root`
6561 case $cf_fix_cppflags in
6563 case $cf_add_cflags in
6564 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
6565 case $cf_add_cflags in
6567 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
6569 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
6570 && test -z "${cf_tst_cflags}" \
6571 && cf_fix_cppflags=yes
6573 if test $cf_fix_cppflags = yes ; then
6575 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
6576 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
6579 elif test "${cf_tst_cflags}" = "\"'" ; then
6581 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
6582 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
6592 case $cf_add_cflags in
6594 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
6596 CPPFLAGS=`echo "$CPPFLAGS" | \
6597 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
6598 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
6603 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
6604 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
6611 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
6612 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
6619 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
6620 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
6622 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
6624 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
6625 && test -z "${cf_tst_cflags}" \
6626 && cf_fix_cppflags=no
6631 if test -n "$cf_new_cflags" ; then
6633 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
6634 CFLAGS="${CFLAGS}$cf_new_cflags"
6638 if test -n "$cf_new_cppflags" ; then
6640 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
6641 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
6645 if test -n "$cf_new_extra_cppflags" ; then
6647 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
6648 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
6655 for cf_add_1lib in `$PKG_CONFIG --libs $cf_ncuconfig_root`; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
6657 for cf_add_1lib in $cf_add_0lib; do
6658 for cf_add_2lib in $cf_add_libs; do
6659 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
6664 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
6668 cat >conftest.$ac_ext <<_ACEOF
6669 #line 6669 "configure"
6670 #include "confdefs.h"
6671 #include <${cf_cv_ncurses_header:-curses.h}>
6675 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
6680 rm -f conftest.$ac_objext conftest$ac_exeext
6681 if { (eval echo "$as_me:6681: \"$ac_link\"") >&5
6682 (eval $ac_link) 2>&5
6684 echo "$as_me:6684: \$? = $ac_status" >&5
6685 (exit $ac_status); } &&
6686 { ac_try='test -s conftest$ac_exeext'
6687 { (eval echo "$as_me:6687: \"$ac_try\"") >&5
6690 echo "$as_me:6690: \$? = $ac_status" >&5
6691 (exit $ac_status); }; }; then
6692 if test "$cross_compiling" = yes; then
6693 cf_have_ncuconfig=maybe
6695 cat >conftest.$ac_ext <<_ACEOF
6696 #line 6696 "configure"
6697 #include "confdefs.h"
6698 #include <${cf_cv_ncurses_header:-curses.h}>
6700 { char *xx = curses_version(); return (xx == 0); }
6702 rm -f conftest$ac_exeext
6703 if { (eval echo "$as_me:6703: \"$ac_link\"") >&5
6704 (eval $ac_link) 2>&5
6706 echo "$as_me:6706: \$? = $ac_status" >&5
6707 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
6708 { (eval echo "$as_me:6708: \"$ac_try\"") >&5
6711 echo "$as_me:6711: \$? = $ac_status" >&5
6712 (exit $ac_status); }; }; then
6713 cf_have_ncuconfig=yes
6715 echo "$as_me: program exited with status $ac_status" >&5
6716 echo "$as_me: failed program was:" >&5
6717 cat conftest.$ac_ext >&5
6718 cf_have_ncuconfig=no
6720 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6723 echo "$as_me: failed program was:" >&5
6724 cat conftest.$ac_ext >&5
6725 cf_have_ncuconfig=no
6727 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6728 echo "$as_me:6728: result: $cf_have_ncuconfig" >&5
6729 echo "${ECHO_T}$cf_have_ncuconfig" >&6
6730 test "$cf_have_ncuconfig" = maybe && cf_have_ncuconfig=yes
6731 if test "$cf_have_ncuconfig" != "yes"
6733 CPPFLAGS="$cf_save_CPPFLAGS"
6734 LIBS="$cf_save_LIBS"
6735 NCURSES_CONFIG_PKG=none
6738 cat >>confdefs.h <<\EOF
6742 NCURSES_CONFIG_PKG=$cf_ncuconfig_root
6744 echo "$as_me:6744: checking for terminfo header" >&5
6745 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
6746 if test "${cf_cv_term_header+set}" = set; then
6747 echo $ECHO_N "(cached) $ECHO_C" >&6
6750 case ${cf_cv_ncurses_header} in
6751 (*/ncurses.h|*/ncursesw.h)
6752 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
6755 cf_term_header=term.h
6759 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
6761 cat >conftest.$ac_ext <<_ACEOF
6762 #line 6762 "configure"
6763 #include "confdefs.h"
6765 #include <${cf_cv_ncurses_header:-curses.h}>
6771 int x = auto_left_margin
6776 rm -f conftest.$ac_objext
6777 if { (eval echo "$as_me:6777: \"$ac_compile\"") >&5
6778 (eval $ac_compile) 2>&5
6780 echo "$as_me:6780: \$? = $ac_status" >&5
6781 (exit $ac_status); } &&
6782 { ac_try='test -s conftest.$ac_objext'
6783 { (eval echo "$as_me:6783: \"$ac_try\"") >&5
6786 echo "$as_me:6786: \$? = $ac_status" >&5
6787 (exit $ac_status); }; }; then
6789 cf_cv_term_header="$cf_test"
6791 echo "$as_me: failed program was:" >&5
6792 cat conftest.$ac_ext >&5
6794 cf_cv_term_header=unknown
6797 rm -f conftest.$ac_objext conftest.$ac_ext
6798 test "$cf_cv_term_header" != unknown && break
6802 echo "$as_me:6802: result: $cf_cv_term_header" >&5
6803 echo "${ECHO_T}$cf_cv_term_header" >&6
6805 # Set definitions to allow ifdef'ing to accommodate subdirectories
6807 case $cf_cv_term_header in
6810 cat >>confdefs.h <<\EOF
6811 #define HAVE_TERM_H 1
6817 case $cf_cv_term_header in
6820 cat >>confdefs.h <<\EOF
6821 #define HAVE_NCURSES_TERM_H 1
6827 cat >>confdefs.h <<\EOF
6828 #define HAVE_NCURSESW_TERM_H 1
6837 echo "$as_me:6837: result: no" >&5
6838 echo "${ECHO_T}no" >&6
6839 NCURSES_CONFIG_PKG=none
6842 NCURSES_CONFIG_PKG=none
6845 if test "x$cf_have_ncuconfig" = "xno"; then
6846 cf_ncurses_config="${cf_ncuconfig_root}${NCURSES_CONFIG_SUFFIX}-config"; echo "Looking for ${cf_ncurses_config}"
6848 if test -n "$ac_tool_prefix"; then
6849 for ac_prog in ${cf_ncurses_config} ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
6851 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
6852 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
6853 echo "$as_me:6853: checking for $ac_word" >&5
6854 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
6855 if test "${ac_cv_prog_NCURSES_CONFIG+set}" = set; then
6856 echo $ECHO_N "(cached) $ECHO_C" >&6
6858 if test -n "$NCURSES_CONFIG"; then
6859 ac_cv_prog_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test.
6861 ac_save_IFS=$IFS; IFS=$ac_path_separator
6863 for ac_dir in $ac_dummy; do
6865 test -z "$ac_dir" && ac_dir=.
6866 $as_executable_p "$ac_dir/$ac_word" || continue
6867 ac_cv_prog_NCURSES_CONFIG="$ac_tool_prefix$ac_prog"
6868 echo "$as_me:6868: found $ac_dir/$ac_word" >&5
6874 NCURSES_CONFIG=$ac_cv_prog_NCURSES_CONFIG
6875 if test -n "$NCURSES_CONFIG"; then
6876 echo "$as_me:6876: result: $NCURSES_CONFIG" >&5
6877 echo "${ECHO_T}$NCURSES_CONFIG" >&6
6879 echo "$as_me:6879: result: no" >&5
6880 echo "${ECHO_T}no" >&6
6883 test -n "$NCURSES_CONFIG" && break
6886 if test -z "$NCURSES_CONFIG"; then
6887 ac_ct_NCURSES_CONFIG=$NCURSES_CONFIG
6888 for ac_prog in ${cf_ncurses_config} ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
6890 # Extract the first word of "$ac_prog", so it can be a program name with args.
6891 set dummy $ac_prog; ac_word=$2
6892 echo "$as_me:6892: checking for $ac_word" >&5
6893 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
6894 if test "${ac_cv_prog_ac_ct_NCURSES_CONFIG+set}" = set; then
6895 echo $ECHO_N "(cached) $ECHO_C" >&6
6897 if test -n "$ac_ct_NCURSES_CONFIG"; then
6898 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_ct_NCURSES_CONFIG" # Let the user override the test.
6900 ac_save_IFS=$IFS; IFS=$ac_path_separator
6902 for ac_dir in $ac_dummy; do
6904 test -z "$ac_dir" && ac_dir=.
6905 $as_executable_p "$ac_dir/$ac_word" || continue
6906 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_prog"
6907 echo "$as_me:6907: found $ac_dir/$ac_word" >&5
6913 ac_ct_NCURSES_CONFIG=$ac_cv_prog_ac_ct_NCURSES_CONFIG
6914 if test -n "$ac_ct_NCURSES_CONFIG"; then
6915 echo "$as_me:6915: result: $ac_ct_NCURSES_CONFIG" >&5
6916 echo "${ECHO_T}$ac_ct_NCURSES_CONFIG" >&6
6918 echo "$as_me:6918: result: no" >&5
6919 echo "${ECHO_T}no" >&6
6922 test -n "$ac_ct_NCURSES_CONFIG" && break
6924 test -n "$ac_ct_NCURSES_CONFIG" || ac_ct_NCURSES_CONFIG="none"
6926 NCURSES_CONFIG=$ac_ct_NCURSES_CONFIG
6929 if test "$NCURSES_CONFIG" != none ; then
6934 cf_new_extra_cppflags=
6936 for cf_add_cflags in `$NCURSES_CONFIG --cflags`
6938 case $cf_fix_cppflags in
6940 case $cf_add_cflags in
6941 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
6942 case $cf_add_cflags in
6944 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
6946 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
6947 && test -z "${cf_tst_cflags}" \
6948 && cf_fix_cppflags=yes
6950 if test $cf_fix_cppflags = yes ; then
6952 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
6953 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
6956 elif test "${cf_tst_cflags}" = "\"'" ; then
6958 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
6959 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
6969 case $cf_add_cflags in
6971 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
6973 CPPFLAGS=`echo "$CPPFLAGS" | \
6974 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
6975 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
6980 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
6981 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
6988 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
6989 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
6996 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
6997 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
6999 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
7001 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
7002 && test -z "${cf_tst_cflags}" \
7003 && cf_fix_cppflags=no
7008 if test -n "$cf_new_cflags" ; then
7010 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
7011 CFLAGS="${CFLAGS}$cf_new_cflags"
7015 if test -n "$cf_new_cppflags" ; then
7017 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
7018 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
7022 if test -n "$cf_new_extra_cppflags" ; then
7024 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
7025 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
7032 for cf_add_1lib in `$NCURSES_CONFIG --libs`; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
7034 for cf_add_1lib in $cf_add_0lib; do
7035 for cf_add_2lib in $cf_add_libs; do
7036 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
7041 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
7045 # even with config script, some packages use no-override for curses.h
7047 echo "$as_me:7047: checking if we have identified curses headers" >&5
7048 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
7049 if test "${cf_cv_ncurses_header+set}" = set; then
7050 echo $ECHO_N "(cached) $ECHO_C" >&6
7053 cf_cv_ncurses_header=none
7055 ncurses.h ncursesw/ncurses.h \
7056 curses.h ncursesw/curses.h
7058 cat >conftest.$ac_ext <<_ACEOF
7059 #line 7059 "configure"
7060 #include "confdefs.h"
7061 #include <${cf_header}>
7065 initscr(); tgoto("?", 0,0)
7070 rm -f conftest.$ac_objext
7071 if { (eval echo "$as_me:7071: \"$ac_compile\"") >&5
7072 (eval $ac_compile) 2>&5
7074 echo "$as_me:7074: \$? = $ac_status" >&5
7075 (exit $ac_status); } &&
7076 { ac_try='test -s conftest.$ac_objext'
7077 { (eval echo "$as_me:7077: \"$ac_try\"") >&5
7080 echo "$as_me:7080: \$? = $ac_status" >&5
7081 (exit $ac_status); }; }; then
7082 cf_cv_ncurses_header=$cf_header; break
7084 echo "$as_me: failed program was:" >&5
7085 cat conftest.$ac_ext >&5
7087 rm -f conftest.$ac_objext conftest.$ac_ext
7091 echo "$as_me:7091: result: $cf_cv_ncurses_header" >&5
7092 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
7094 if test "$cf_cv_ncurses_header" = none ; then
7095 { { echo "$as_me:7095: error: No curses header-files found" >&5
7096 echo "$as_me: error: No curses header-files found" >&2;}
7097 { (exit 1); exit 1; }; }
7100 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
7102 for ac_header in $cf_cv_ncurses_header
7104 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7105 echo "$as_me:7105: checking for $ac_header" >&5
7106 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7107 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7108 echo $ECHO_N "(cached) $ECHO_C" >&6
7110 cat >conftest.$ac_ext <<_ACEOF
7111 #line 7111 "configure"
7112 #include "confdefs.h"
7113 #include <$ac_header>
7115 if { (eval echo "$as_me:7115: \"$ac_cpp conftest.$ac_ext\"") >&5
7116 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7118 egrep -v '^ *\+' conftest.er1 >conftest.err
7120 cat conftest.err >&5
7121 echo "$as_me:7121: \$? = $ac_status" >&5
7122 (exit $ac_status); } >/dev/null; then
7123 if test -s conftest.err; then
7124 ac_cpp_err=$ac_c_preproc_warn_flag
7131 if test -z "$ac_cpp_err"; then
7132 eval "$as_ac_Header=yes"
7134 echo "$as_me: failed program was:" >&5
7135 cat conftest.$ac_ext >&5
7136 eval "$as_ac_Header=no"
7138 rm -f conftest.err conftest.$ac_ext
7140 echo "$as_me:7140: result: `eval echo '${'$as_ac_Header'}'`" >&5
7141 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7142 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7143 cat >>confdefs.h <<EOF
7144 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7150 cat >>confdefs.h <<\EOF
7154 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
7156 cat >>confdefs.h <<EOF
7157 #define $cf_nculib_ROOT 1
7160 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
7164 cf_ncuhdr_root=ncursesw
7166 test -n "$cf_cv_curses_dir" && \
7167 test "$cf_cv_curses_dir" != "no" && { \
7169 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
7170 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
7172 while test $cf_add_incdir != /usr/include
7174 if test -d $cf_add_incdir
7177 if test -n "$CFLAGS$CPPFLAGS" ; then
7178 # a loop is needed to ensure we can add subdirs of existing dirs
7179 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
7180 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
7181 cf_have_incdir=yes; break
7186 if test "$cf_have_incdir" = no ; then
7187 if test "$cf_add_incdir" = /usr/local/include ; then
7188 if test "$GCC" = yes
7190 cf_save_CPPFLAGS=$CPPFLAGS
7192 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
7193 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
7195 cat >conftest.$ac_ext <<_ACEOF
7196 #line 7196 "configure"
7197 #include "confdefs.h"
7207 rm -f conftest.$ac_objext
7208 if { (eval echo "$as_me:7208: \"$ac_compile\"") >&5
7209 (eval $ac_compile) 2>&5
7211 echo "$as_me:7211: \$? = $ac_status" >&5
7212 (exit $ac_status); } &&
7213 { ac_try='test -s conftest.$ac_objext'
7214 { (eval echo "$as_me:7214: \"$ac_try\"") >&5
7217 echo "$as_me:7217: \$? = $ac_status" >&5
7218 (exit $ac_status); }; }; then
7221 echo "$as_me: failed program was:" >&5
7222 cat conftest.$ac_ext >&5
7225 rm -f conftest.$ac_objext conftest.$ac_ext
7226 CPPFLAGS=$cf_save_CPPFLAGS
7231 if test "$cf_have_incdir" = no ; then
7232 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
7234 echo "${as_me:-configure}:7234: testing adding $cf_add_incdir to include-path ..." 1>&5
7236 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7238 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
7239 test "$cf_top_incdir" = "$cf_add_incdir" && break
7240 cf_add_incdir="$cf_top_incdir"
7253 echo "$as_me:7253: checking for $cf_ncuhdr_root header in include-path" >&5
7254 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
7255 if test "${cf_cv_ncurses_h+set}" = set; then
7256 echo $ECHO_N "(cached) $ECHO_C" >&6
7259 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
7260 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
7261 for cf_header in $cf_header_list
7264 cat >conftest.$ac_ext <<_ACEOF
7265 #line 7265 "configure"
7266 #include "confdefs.h"
7268 #define _XOPEN_SOURCE_EXTENDED
7269 #undef HAVE_LIBUTF8_H /* in case we used CF_UTF8_LIB */
7270 #define HAVE_LIBUTF8_H /* to force ncurses' header file to use cchar_t */
7272 #include <$cf_header>
7277 #ifdef NCURSES_VERSION
7283 printf("%s\n", NCURSES_VERSION);
7296 rm -f conftest.$ac_objext
7297 if { (eval echo "$as_me:7297: \"$ac_compile\"") >&5
7298 (eval $ac_compile) 2>&5
7300 echo "$as_me:7300: \$? = $ac_status" >&5
7301 (exit $ac_status); } &&
7302 { ac_try='test -s conftest.$ac_objext'
7303 { (eval echo "$as_me:7303: \"$ac_try\"") >&5
7306 echo "$as_me:7306: \$? = $ac_status" >&5
7307 (exit $ac_status); }; }; then
7308 cf_cv_ncurses_h=$cf_header
7311 echo "$as_me: failed program was:" >&5
7312 cat conftest.$ac_ext >&5
7315 rm -f conftest.$ac_objext conftest.$ac_ext
7317 test "$cf_cv_ncurses_h" != no && break
7321 echo "$as_me:7321: result: $cf_cv_ncurses_h" >&5
7322 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
7324 if test "$cf_cv_ncurses_h" != no ; then
7325 cf_cv_ncurses_header=$cf_cv_ncurses_h
7328 echo "$as_me:7328: checking for $cf_ncuhdr_root include-path" >&5
7329 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
7330 if test "${cf_cv_ncurses_h2+set}" = set; then
7331 echo $ECHO_N "(cached) $ECHO_C" >&6
7334 test -n "$verbose" && echo
7338 # collect the current set of include-directories from compiler flags
7339 cf_header_path_list=""
7340 if test -n "${CFLAGS}${CPPFLAGS}" ; then
7341 for cf_header_path in $CPPFLAGS $CFLAGS
7343 case $cf_header_path in
7345 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
7347 test "x$cf_header_path" != "xNONE" && \
7348 test -d "$cf_header_path" && \
7350 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
7351 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
7352 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
7353 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
7354 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
7355 test -d $cf_header_path/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
7358 cf_header_path_list="$cf_header_path_list $cf_search"
7364 # add the variations for the package we are looking for
7368 test "x$prefix" != "xNONE" && \
7369 test -d "$prefix" && \
7371 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
7372 test -d $prefix/include && cf_search="$cf_search $prefix/include"
7373 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
7374 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
7375 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
7376 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
7379 for cf_subdir_prefix in \
7388 test "x$cf_subdir_prefix" != "x$prefix" && \
7389 test -d "$cf_subdir_prefix" && \
7390 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
7391 test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
7392 test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include"
7393 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root"
7394 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root/include"
7395 test -d $cf_subdir_prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include"
7396 test -d $cf_subdir_prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
7401 test "$includedir" != NONE && \
7402 test "$includedir" != "/usr/include" && \
7403 test -d "$includedir" && {
7404 test -d $includedir && cf_search="$cf_search $includedir"
7405 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
7408 test "$oldincludedir" != NONE && \
7409 test "$oldincludedir" != "/usr/include" && \
7410 test -d "$oldincludedir" && {
7411 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
7412 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
7415 cf_search="$cf_search $cf_header_path_list"
7417 test -n "$verbose" && echo search path $cf_search
7418 cf_save2_CPPFLAGS="$CPPFLAGS"
7419 for cf_incdir in $cf_search
7422 if test -n "$cf_incdir" ; then
7423 for cf_add_incdir in $cf_incdir
7425 while test $cf_add_incdir != /usr/include
7427 if test -d $cf_add_incdir
7430 if test -n "$CFLAGS$CPPFLAGS" ; then
7431 # a loop is needed to ensure we can add subdirs of existing dirs
7432 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
7433 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
7434 cf_have_incdir=yes; break
7439 if test "$cf_have_incdir" = no ; then
7440 if test "$cf_add_incdir" = /usr/local/include ; then
7441 if test "$GCC" = yes
7443 cf_save_CPPFLAGS=$CPPFLAGS
7445 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
7446 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
7448 cat >conftest.$ac_ext <<_ACEOF
7449 #line 7449 "configure"
7450 #include "confdefs.h"
7460 rm -f conftest.$ac_objext
7461 if { (eval echo "$as_me:7461: \"$ac_compile\"") >&5
7462 (eval $ac_compile) 2>&5
7464 echo "$as_me:7464: \$? = $ac_status" >&5
7465 (exit $ac_status); } &&
7466 { ac_try='test -s conftest.$ac_objext'
7467 { (eval echo "$as_me:7467: \"$ac_try\"") >&5
7470 echo "$as_me:7470: \$? = $ac_status" >&5
7471 (exit $ac_status); }; }; then
7474 echo "$as_me: failed program was:" >&5
7475 cat conftest.$ac_ext >&5
7478 rm -f conftest.$ac_objext conftest.$ac_ext
7479 CPPFLAGS=$cf_save_CPPFLAGS
7484 if test "$cf_have_incdir" = no ; then
7485 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
7487 echo "${as_me:-configure}:7487: testing adding $cf_add_incdir to include-path ..." 1>&5
7489 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7491 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
7492 test "$cf_top_incdir" = "$cf_add_incdir" && break
7493 cf_add_incdir="$cf_top_incdir"
7509 cat >conftest.$ac_ext <<_ACEOF
7510 #line 7510 "configure"
7511 #include "confdefs.h"
7513 #include <$cf_header>
7518 #ifdef NCURSES_VERSION
7520 printf("%s\n", NCURSES_VERSION);
7533 rm -f conftest.$ac_objext
7534 if { (eval echo "$as_me:7534: \"$ac_compile\"") >&5
7535 (eval $ac_compile) 2>&5
7537 echo "$as_me:7537: \$? = $ac_status" >&5
7538 (exit $ac_status); } &&
7539 { ac_try='test -s conftest.$ac_objext'
7540 { (eval echo "$as_me:7540: \"$ac_try\"") >&5
7543 echo "$as_me:7543: \$? = $ac_status" >&5
7544 (exit $ac_status); }; }; then
7545 cf_cv_ncurses_h2=$cf_header
7548 echo "$as_me: failed program was:" >&5
7549 cat conftest.$ac_ext >&5
7552 rm -f conftest.$ac_objext conftest.$ac_ext
7554 if test "$cf_cv_ncurses_h2" != no ; then
7555 cf_cv_ncurses_h2=$cf_incdir/$cf_header
7556 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
7559 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
7561 CPPFLAGS="$cf_save2_CPPFLAGS"
7562 test "$cf_cv_ncurses_h2" != no && break
7564 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:7564: error: not found" >&5
7565 echo "$as_me: error: not found" >&2;}
7566 { (exit 1); exit 1; }; }
7569 echo "$as_me:7569: result: $cf_cv_ncurses_h2" >&5
7570 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
7572 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
7573 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
7574 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
7575 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
7578 if test -n "$cf_1st_incdir" ; then
7579 for cf_add_incdir in $cf_1st_incdir
7581 while test $cf_add_incdir != /usr/include
7583 if test -d $cf_add_incdir
7586 if test -n "$CFLAGS$CPPFLAGS" ; then
7587 # a loop is needed to ensure we can add subdirs of existing dirs
7588 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
7589 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
7590 cf_have_incdir=yes; break
7595 if test "$cf_have_incdir" = no ; then
7596 if test "$cf_add_incdir" = /usr/local/include ; then
7597 if test "$GCC" = yes
7599 cf_save_CPPFLAGS=$CPPFLAGS
7601 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
7602 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
7604 cat >conftest.$ac_ext <<_ACEOF
7605 #line 7605 "configure"
7606 #include "confdefs.h"
7616 rm -f conftest.$ac_objext
7617 if { (eval echo "$as_me:7617: \"$ac_compile\"") >&5
7618 (eval $ac_compile) 2>&5
7620 echo "$as_me:7620: \$? = $ac_status" >&5
7621 (exit $ac_status); } &&
7622 { ac_try='test -s conftest.$ac_objext'
7623 { (eval echo "$as_me:7623: \"$ac_try\"") >&5
7626 echo "$as_me:7626: \$? = $ac_status" >&5
7627 (exit $ac_status); }; }; then
7630 echo "$as_me: failed program was:" >&5
7631 cat conftest.$ac_ext >&5
7634 rm -f conftest.$ac_objext conftest.$ac_ext
7635 CPPFLAGS=$cf_save_CPPFLAGS
7640 if test "$cf_have_incdir" = no ; then
7641 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
7643 echo "${as_me:-configure}:7643: testing adding $cf_add_incdir to include-path ..." 1>&5
7645 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7647 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
7648 test "$cf_top_incdir" = "$cf_add_incdir" && break
7649 cf_add_incdir="$cf_top_incdir"
7662 # Set definitions to allow ifdef'ing for ncurses.h
7664 case $cf_cv_ncurses_header in
7667 cat >>confdefs.h <<\EOF
7668 #define HAVE_NCURSES_H 1
7674 case $cf_cv_ncurses_header in
7675 (ncurses/curses.h|ncurses/ncurses.h)
7677 cat >>confdefs.h <<\EOF
7678 #define HAVE_NCURSES_NCURSES_H 1
7682 (ncursesw/curses.h|ncursesw/ncurses.h)
7684 cat >>confdefs.h <<\EOF
7685 #define HAVE_NCURSESW_NCURSES_H 1
7691 echo "$as_me:7691: checking for terminfo header" >&5
7692 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
7693 if test "${cf_cv_term_header+set}" = set; then
7694 echo $ECHO_N "(cached) $ECHO_C" >&6
7697 case ${cf_cv_ncurses_header} in
7698 (*/ncurses.h|*/ncursesw.h)
7699 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
7702 cf_term_header=term.h
7706 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
7708 cat >conftest.$ac_ext <<_ACEOF
7709 #line 7709 "configure"
7710 #include "confdefs.h"
7712 #include <${cf_cv_ncurses_header:-curses.h}>
7718 int x = auto_left_margin
7723 rm -f conftest.$ac_objext
7724 if { (eval echo "$as_me:7724: \"$ac_compile\"") >&5
7725 (eval $ac_compile) 2>&5
7727 echo "$as_me:7727: \$? = $ac_status" >&5
7728 (exit $ac_status); } &&
7729 { ac_try='test -s conftest.$ac_objext'
7730 { (eval echo "$as_me:7730: \"$ac_try\"") >&5
7733 echo "$as_me:7733: \$? = $ac_status" >&5
7734 (exit $ac_status); }; }; then
7736 cf_cv_term_header="$cf_test"
7738 echo "$as_me: failed program was:" >&5
7739 cat conftest.$ac_ext >&5
7741 cf_cv_term_header=unknown
7744 rm -f conftest.$ac_objext conftest.$ac_ext
7745 test "$cf_cv_term_header" != unknown && break
7749 echo "$as_me:7749: result: $cf_cv_term_header" >&5
7750 echo "${ECHO_T}$cf_cv_term_header" >&6
7752 # Set definitions to allow ifdef'ing to accommodate subdirectories
7754 case $cf_cv_term_header in
7757 cat >>confdefs.h <<\EOF
7758 #define HAVE_TERM_H 1
7764 case $cf_cv_term_header in
7767 cat >>confdefs.h <<\EOF
7768 #define HAVE_NCURSES_TERM_H 1
7774 cat >>confdefs.h <<\EOF
7775 #define HAVE_NCURSESW_TERM_H 1
7781 # some applications need this, but should check for NCURSES_VERSION
7783 cat >>confdefs.h <<\EOF
7787 echo "$as_me:7787: checking for ncurses version" >&5
7788 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
7789 if test "${cf_cv_ncurses_version+set}" = set; then
7790 echo $ECHO_N "(cached) $ECHO_C" >&6
7793 cf_cv_ncurses_version=no
7796 if test "$cross_compiling" = yes; then
7798 # This will not work if the preprocessor splits the line after the
7799 # Autoconf token. The 'unproto' program does that.
7800 cat > conftest.$ac_ext <<EOF
7801 #include <${cf_cv_ncurses_header:-curses.h}>
7803 #ifdef NCURSES_VERSION
7804 Autoconf NCURSES_VERSION
7812 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
7813 { (eval echo "$as_me:7813: \"$cf_try\"") >&5
7816 echo "$as_me:7816: \$? = $ac_status" >&5
7817 (exit $ac_status); }
7818 if test -f conftest.out ; then
7819 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
7820 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
7825 cat >conftest.$ac_ext <<_ACEOF
7826 #line 7826 "configure"
7827 #include "confdefs.h"
7829 #include <${cf_cv_ncurses_header:-curses.h}>
7833 FILE *fp = fopen("$cf_tempfile", "w");
7834 #ifdef NCURSES_VERSION
7835 # ifdef NCURSES_VERSION_PATCH
7836 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
7838 fprintf(fp, "%s\n", NCURSES_VERSION);
7842 fprintf(fp, "old\n");
7847 ${cf_cv_main_return:-return}(0);
7850 rm -f conftest$ac_exeext
7851 if { (eval echo "$as_me:7851: \"$ac_link\"") >&5
7852 (eval $ac_link) 2>&5
7854 echo "$as_me:7854: \$? = $ac_status" >&5
7855 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
7856 { (eval echo "$as_me:7856: \"$ac_try\"") >&5
7859 echo "$as_me:7859: \$? = $ac_status" >&5
7860 (exit $ac_status); }; }; then
7862 cf_cv_ncurses_version=`cat $cf_tempfile`
7864 echo "$as_me: program exited with status $ac_status" >&5
7865 echo "$as_me: failed program was:" >&5
7866 cat conftest.$ac_ext >&5
7868 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
7873 echo "$as_me:7873: result: $cf_cv_ncurses_version" >&5
7874 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
7875 test "$cf_cv_ncurses_version" = no ||
7876 cat >>confdefs.h <<\EOF
7880 cf_nculib_root=ncursesw
7881 # This works, except for the special case where we find gpm, but
7882 # ncurses is in a nonstandard location via $LIBS, and we really want
7885 cf_ncurses_SAVE="$LIBS"
7886 echo "$as_me:7886: checking for Gpm_Open in -lgpm" >&5
7887 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
7888 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
7889 echo $ECHO_N "(cached) $ECHO_C" >&6
7891 ac_check_lib_save_LIBS=$LIBS
7893 cat >conftest.$ac_ext <<_ACEOF
7894 #line 7894 "configure"
7895 #include "confdefs.h"
7897 /* Override any gcc2 internal prototype to avoid an error. */
7901 /* We use char because int might match the return type of a gcc2
7902 builtin and then its argument prototype would still apply. */
7912 rm -f conftest.$ac_objext conftest$ac_exeext
7913 if { (eval echo "$as_me:7913: \"$ac_link\"") >&5
7914 (eval $ac_link) 2>&5
7916 echo "$as_me:7916: \$? = $ac_status" >&5
7917 (exit $ac_status); } &&
7918 { ac_try='test -s conftest$ac_exeext'
7919 { (eval echo "$as_me:7919: \"$ac_try\"") >&5
7922 echo "$as_me:7922: \$? = $ac_status" >&5
7923 (exit $ac_status); }; }; then
7924 ac_cv_lib_gpm_Gpm_Open=yes
7926 echo "$as_me: failed program was:" >&5
7927 cat conftest.$ac_ext >&5
7928 ac_cv_lib_gpm_Gpm_Open=no
7930 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7931 LIBS=$ac_check_lib_save_LIBS
7933 echo "$as_me:7933: result: $ac_cv_lib_gpm_Gpm_Open" >&5
7934 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
7935 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
7936 echo "$as_me:7936: checking for initscr in -lgpm" >&5
7937 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
7938 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
7939 echo $ECHO_N "(cached) $ECHO_C" >&6
7941 ac_check_lib_save_LIBS=$LIBS
7943 cat >conftest.$ac_ext <<_ACEOF
7944 #line 7944 "configure"
7945 #include "confdefs.h"
7947 /* Override any gcc2 internal prototype to avoid an error. */
7951 /* We use char because int might match the return type of a gcc2
7952 builtin and then its argument prototype would still apply. */
7962 rm -f conftest.$ac_objext conftest$ac_exeext
7963 if { (eval echo "$as_me:7963: \"$ac_link\"") >&5
7964 (eval $ac_link) 2>&5
7966 echo "$as_me:7966: \$? = $ac_status" >&5
7967 (exit $ac_status); } &&
7968 { ac_try='test -s conftest$ac_exeext'
7969 { (eval echo "$as_me:7969: \"$ac_try\"") >&5
7972 echo "$as_me:7972: \$? = $ac_status" >&5
7973 (exit $ac_status); }; }; then
7974 ac_cv_lib_gpm_initscr=yes
7976 echo "$as_me: failed program was:" >&5
7977 cat conftest.$ac_ext >&5
7978 ac_cv_lib_gpm_initscr=no
7980 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7981 LIBS=$ac_check_lib_save_LIBS
7983 echo "$as_me:7983: result: $ac_cv_lib_gpm_initscr" >&5
7984 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
7985 if test $ac_cv_lib_gpm_initscr = yes; then
7986 LIBS="$cf_ncurses_SAVE"
7988 cf_ncurses_LIBS="-lgpm"
7995 # This is only necessary if you are linking against an obsolete
7996 # version of ncurses (but it should do no harm, since it's static).
7997 if test "$cf_nculib_root" = ncurses ; then
7998 echo "$as_me:7998: checking for tgoto in -lmytinfo" >&5
7999 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
8000 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
8001 echo $ECHO_N "(cached) $ECHO_C" >&6
8003 ac_check_lib_save_LIBS=$LIBS
8004 LIBS="-lmytinfo $LIBS"
8005 cat >conftest.$ac_ext <<_ACEOF
8006 #line 8006 "configure"
8007 #include "confdefs.h"
8009 /* Override any gcc2 internal prototype to avoid an error. */
8013 /* We use char because int might match the return type of a gcc2
8014 builtin and then its argument prototype would still apply. */
8024 rm -f conftest.$ac_objext conftest$ac_exeext
8025 if { (eval echo "$as_me:8025: \"$ac_link\"") >&5
8026 (eval $ac_link) 2>&5
8028 echo "$as_me:8028: \$? = $ac_status" >&5
8029 (exit $ac_status); } &&
8030 { ac_try='test -s conftest$ac_exeext'
8031 { (eval echo "$as_me:8031: \"$ac_try\"") >&5
8034 echo "$as_me:8034: \$? = $ac_status" >&5
8035 (exit $ac_status); }; }; then
8036 ac_cv_lib_mytinfo_tgoto=yes
8038 echo "$as_me: failed program was:" >&5
8039 cat conftest.$ac_ext >&5
8040 ac_cv_lib_mytinfo_tgoto=no
8042 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8043 LIBS=$ac_check_lib_save_LIBS
8045 echo "$as_me:8045: result: $ac_cv_lib_mytinfo_tgoto" >&5
8046 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
8047 if test $ac_cv_lib_mytinfo_tgoto = yes; then
8048 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
8058 for cf_add_1lib in $cf_ncurses_LIBS; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
8060 for cf_add_1lib in $cf_add_0lib; do
8061 for cf_add_2lib in $cf_add_libs; do
8062 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
8067 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
8071 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
8077 for cf_add_1lib in -l$cf_nculib_root; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
8079 for cf_add_1lib in $cf_add_0lib; do
8080 for cf_add_2lib in $cf_add_libs; do
8081 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
8086 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
8092 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
8094 echo "$as_me:8094: checking for initscr" >&5
8095 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
8096 if test "${ac_cv_func_initscr+set}" = set; then
8097 echo $ECHO_N "(cached) $ECHO_C" >&6
8099 cat >conftest.$ac_ext <<_ACEOF
8100 #line 8100 "configure"
8101 #include "confdefs.h"
8102 #define initscr autoconf_temporary
8103 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
8110 /* We use char because int might match the return type of a gcc2
8111 builtin and then its argument prototype would still apply. */
8112 char initscr (void);
8118 /* The GNU C library defines stubs for functions which it implements
8119 to always fail with ENOSYS. Some functions are actually named
8120 something starting with __ and the normal name is an alias. */
8121 #if defined (__stub_initscr) || defined (__stub___initscr)
8122 #error found stub for initscr
8130 rm -f conftest.$ac_objext conftest$ac_exeext
8131 if { (eval echo "$as_me:8131: \"$ac_link\"") >&5
8132 (eval $ac_link) 2>&5
8134 echo "$as_me:8134: \$? = $ac_status" >&5
8135 (exit $ac_status); } &&
8136 { ac_try='test -s conftest$ac_exeext'
8137 { (eval echo "$as_me:8137: \"$ac_try\"") >&5
8140 echo "$as_me:8140: \$? = $ac_status" >&5
8141 (exit $ac_status); }; }; then
8142 ac_cv_func_initscr=yes
8144 echo "$as_me: failed program was:" >&5
8145 cat conftest.$ac_ext >&5
8146 ac_cv_func_initscr=no
8148 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8150 echo "$as_me:8150: result: $ac_cv_func_initscr" >&5
8151 echo "${ECHO_T}$ac_cv_func_initscr" >&6
8152 if test $ac_cv_func_initscr = yes; then
8153 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
8156 cf_save_LIBS="$LIBS"
8157 echo "$as_me:8157: checking for initscr in -l$cf_nculib_root" >&5
8158 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
8159 LIBS="-l$cf_nculib_root $LIBS"
8160 cat >conftest.$ac_ext <<_ACEOF
8161 #line 8161 "configure"
8162 #include "confdefs.h"
8163 #include <${cf_cv_ncurses_header:-curses.h}>
8172 rm -f conftest.$ac_objext conftest$ac_exeext
8173 if { (eval echo "$as_me:8173: \"$ac_link\"") >&5
8174 (eval $ac_link) 2>&5
8176 echo "$as_me:8176: \$? = $ac_status" >&5
8177 (exit $ac_status); } &&
8178 { ac_try='test -s conftest$ac_exeext'
8179 { (eval echo "$as_me:8179: \"$ac_try\"") >&5
8182 echo "$as_me:8182: \$? = $ac_status" >&5
8183 (exit $ac_status); }; }; then
8184 echo "$as_me:8184: result: yes" >&5
8185 echo "${ECHO_T}yes" >&6
8186 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
8189 echo "$as_me: failed program was:" >&5
8190 cat conftest.$ac_ext >&5
8191 echo "$as_me:8191: result: no" >&5
8192 echo "${ECHO_T}no" >&6
8195 cf_library_path_list=""
8196 if test -n "${LDFLAGS}${LIBS}" ; then
8197 for cf_library_path in $LDFLAGS $LIBS
8199 case $cf_library_path in
8201 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
8203 test "x$cf_library_path" != "xNONE" && \
8204 test -d "$cf_library_path" && \
8206 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
8207 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
8208 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
8209 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
8210 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
8211 test -d $cf_library_path/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib/$cf_nculib_root"
8214 cf_library_path_list="$cf_library_path_list $cf_search"
8222 test "x$prefix" != "xNONE" && \
8223 test -d "$prefix" && \
8225 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
8226 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
8227 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
8228 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
8229 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
8230 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
8233 for cf_subdir_prefix in \
8242 test "x$cf_subdir_prefix" != "x$prefix" && \
8243 test -d "$cf_subdir_prefix" && \
8244 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
8245 test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
8246 test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib"
8247 test -d $cf_subdir_prefix/lib/$cf_nculib_root && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root"
8248 test -d $cf_subdir_prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root/lib"
8249 test -d $cf_subdir_prefix/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib"
8250 test -d $cf_subdir_prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib/$cf_nculib_root"
8255 cf_search="$cf_library_path_list $cf_search"
8257 for cf_libdir in $cf_search
8259 echo "$as_me:8259: checking for -l$cf_nculib_root in $cf_libdir" >&5
8260 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
8261 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
8262 cat >conftest.$ac_ext <<_ACEOF
8263 #line 8263 "configure"
8264 #include "confdefs.h"
8265 #include <${cf_cv_ncurses_header:-curses.h}>
8274 rm -f conftest.$ac_objext conftest$ac_exeext
8275 if { (eval echo "$as_me:8275: \"$ac_link\"") >&5
8276 (eval $ac_link) 2>&5
8278 echo "$as_me:8278: \$? = $ac_status" >&5
8279 (exit $ac_status); } &&
8280 { ac_try='test -s conftest$ac_exeext'
8281 { (eval echo "$as_me:8281: \"$ac_try\"") >&5
8284 echo "$as_me:8284: \$? = $ac_status" >&5
8285 (exit $ac_status); }; }; then
8286 echo "$as_me:8286: result: yes" >&5
8287 echo "${ECHO_T}yes" >&6
8288 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
8291 echo "$as_me: failed program was:" >&5
8292 cat conftest.$ac_ext >&5
8293 echo "$as_me:8293: result: no" >&5
8294 echo "${ECHO_T}no" >&6
8295 LIBS="$cf_save_LIBS"
8297 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8301 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8305 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
8307 if test $cf_found_library = no ; then
8308 { { echo "$as_me:8308: error: Cannot link $cf_nculib_root library" >&5
8309 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
8310 { (exit 1); exit 1; }; }
8315 if test -n "$cf_ncurses_LIBS" ; then
8316 echo "$as_me:8316: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
8317 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
8318 cf_ncurses_SAVE="$LIBS"
8319 for p in $cf_ncurses_LIBS ; do
8320 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
8321 if test "$q" != "$LIBS" ; then
8325 cat >conftest.$ac_ext <<_ACEOF
8326 #line 8326 "configure"
8327 #include "confdefs.h"
8328 #include <${cf_cv_ncurses_header:-curses.h}>
8332 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
8337 rm -f conftest.$ac_objext conftest$ac_exeext
8338 if { (eval echo "$as_me:8338: \"$ac_link\"") >&5
8339 (eval $ac_link) 2>&5
8341 echo "$as_me:8341: \$? = $ac_status" >&5
8342 (exit $ac_status); } &&
8343 { ac_try='test -s conftest$ac_exeext'
8344 { (eval echo "$as_me:8344: \"$ac_try\"") >&5
8347 echo "$as_me:8347: \$? = $ac_status" >&5
8348 (exit $ac_status); }; }; then
8349 echo "$as_me:8349: result: yes" >&5
8350 echo "${ECHO_T}yes" >&6
8352 echo "$as_me: failed program was:" >&5
8353 cat conftest.$ac_ext >&5
8354 echo "$as_me:8354: result: no" >&5
8355 echo "${ECHO_T}no" >&6
8356 LIBS="$cf_ncurses_SAVE"
8358 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8361 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
8363 cat >>confdefs.h <<EOF
8364 #define $cf_nculib_ROOT 1
8374 cf_ncuconfig_root=ncurses
8375 cf_have_ncuconfig=no
8377 if test "x${PKG_CONFIG:=none}" != xnone; then
8378 echo "$as_me:8378: checking pkg-config for $cf_ncuconfig_root" >&5
8379 echo $ECHO_N "checking pkg-config for $cf_ncuconfig_root... $ECHO_C" >&6
8380 if "$PKG_CONFIG" --exists $cf_ncuconfig_root ; then
8381 echo "$as_me:8381: result: yes" >&5
8382 echo "${ECHO_T}yes" >&6
8384 echo "$as_me:8384: checking if the $cf_ncuconfig_root package files work" >&5
8385 echo $ECHO_N "checking if the $cf_ncuconfig_root package files work... $ECHO_C" >&6
8386 cf_have_ncuconfig=unknown
8388 cf_save_CPPFLAGS="$CPPFLAGS"
8389 cf_save_LIBS="$LIBS"
8394 cf_new_extra_cppflags=
8396 for cf_add_cflags in `$PKG_CONFIG --cflags $cf_ncuconfig_root`
8398 case $cf_fix_cppflags in
8400 case $cf_add_cflags in
8401 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
8402 case $cf_add_cflags in
8404 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
8406 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
8407 && test -z "${cf_tst_cflags}" \
8408 && cf_fix_cppflags=yes
8410 if test $cf_fix_cppflags = yes ; then
8412 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
8413 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
8416 elif test "${cf_tst_cflags}" = "\"'" ; then
8418 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
8419 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
8429 case $cf_add_cflags in
8431 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
8433 CPPFLAGS=`echo "$CPPFLAGS" | \
8434 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
8435 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
8440 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
8441 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
8448 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
8449 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
8456 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
8457 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
8459 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
8461 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
8462 && test -z "${cf_tst_cflags}" \
8463 && cf_fix_cppflags=no
8468 if test -n "$cf_new_cflags" ; then
8470 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
8471 CFLAGS="${CFLAGS}$cf_new_cflags"
8475 if test -n "$cf_new_cppflags" ; then
8477 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
8478 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
8482 if test -n "$cf_new_extra_cppflags" ; then
8484 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
8485 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
8492 for cf_add_1lib in `$PKG_CONFIG --libs $cf_ncuconfig_root`; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
8494 for cf_add_1lib in $cf_add_0lib; do
8495 for cf_add_2lib in $cf_add_libs; do
8496 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
8501 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
8505 cat >conftest.$ac_ext <<_ACEOF
8506 #line 8506 "configure"
8507 #include "confdefs.h"
8508 #include <${cf_cv_ncurses_header:-curses.h}>
8512 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
8517 rm -f conftest.$ac_objext conftest$ac_exeext
8518 if { (eval echo "$as_me:8518: \"$ac_link\"") >&5
8519 (eval $ac_link) 2>&5
8521 echo "$as_me:8521: \$? = $ac_status" >&5
8522 (exit $ac_status); } &&
8523 { ac_try='test -s conftest$ac_exeext'
8524 { (eval echo "$as_me:8524: \"$ac_try\"") >&5
8527 echo "$as_me:8527: \$? = $ac_status" >&5
8528 (exit $ac_status); }; }; then
8529 if test "$cross_compiling" = yes; then
8530 cf_have_ncuconfig=maybe
8532 cat >conftest.$ac_ext <<_ACEOF
8533 #line 8533 "configure"
8534 #include "confdefs.h"
8535 #include <${cf_cv_ncurses_header:-curses.h}>
8537 { char *xx = curses_version(); return (xx == 0); }
8539 rm -f conftest$ac_exeext
8540 if { (eval echo "$as_me:8540: \"$ac_link\"") >&5
8541 (eval $ac_link) 2>&5
8543 echo "$as_me:8543: \$? = $ac_status" >&5
8544 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
8545 { (eval echo "$as_me:8545: \"$ac_try\"") >&5
8548 echo "$as_me:8548: \$? = $ac_status" >&5
8549 (exit $ac_status); }; }; then
8550 cf_have_ncuconfig=yes
8552 echo "$as_me: program exited with status $ac_status" >&5
8553 echo "$as_me: failed program was:" >&5
8554 cat conftest.$ac_ext >&5
8555 cf_have_ncuconfig=no
8557 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
8560 echo "$as_me: failed program was:" >&5
8561 cat conftest.$ac_ext >&5
8562 cf_have_ncuconfig=no
8564 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8565 echo "$as_me:8565: result: $cf_have_ncuconfig" >&5
8566 echo "${ECHO_T}$cf_have_ncuconfig" >&6
8567 test "$cf_have_ncuconfig" = maybe && cf_have_ncuconfig=yes
8568 if test "$cf_have_ncuconfig" != "yes"
8570 CPPFLAGS="$cf_save_CPPFLAGS"
8571 LIBS="$cf_save_LIBS"
8572 NCURSES_CONFIG_PKG=none
8575 cat >>confdefs.h <<\EOF
8579 NCURSES_CONFIG_PKG=$cf_ncuconfig_root
8581 echo "$as_me:8581: checking for terminfo header" >&5
8582 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
8583 if test "${cf_cv_term_header+set}" = set; then
8584 echo $ECHO_N "(cached) $ECHO_C" >&6
8587 case ${cf_cv_ncurses_header} in
8588 (*/ncurses.h|*/ncursesw.h)
8589 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
8592 cf_term_header=term.h
8596 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
8598 cat >conftest.$ac_ext <<_ACEOF
8599 #line 8599 "configure"
8600 #include "confdefs.h"
8602 #include <${cf_cv_ncurses_header:-curses.h}>
8608 int x = auto_left_margin
8613 rm -f conftest.$ac_objext
8614 if { (eval echo "$as_me:8614: \"$ac_compile\"") >&5
8615 (eval $ac_compile) 2>&5
8617 echo "$as_me:8617: \$? = $ac_status" >&5
8618 (exit $ac_status); } &&
8619 { ac_try='test -s conftest.$ac_objext'
8620 { (eval echo "$as_me:8620: \"$ac_try\"") >&5
8623 echo "$as_me:8623: \$? = $ac_status" >&5
8624 (exit $ac_status); }; }; then
8626 cf_cv_term_header="$cf_test"
8628 echo "$as_me: failed program was:" >&5
8629 cat conftest.$ac_ext >&5
8631 cf_cv_term_header=unknown
8634 rm -f conftest.$ac_objext conftest.$ac_ext
8635 test "$cf_cv_term_header" != unknown && break
8639 echo "$as_me:8639: result: $cf_cv_term_header" >&5
8640 echo "${ECHO_T}$cf_cv_term_header" >&6
8642 # Set definitions to allow ifdef'ing to accommodate subdirectories
8644 case $cf_cv_term_header in
8647 cat >>confdefs.h <<\EOF
8648 #define HAVE_TERM_H 1
8654 case $cf_cv_term_header in
8657 cat >>confdefs.h <<\EOF
8658 #define HAVE_NCURSES_TERM_H 1
8664 cat >>confdefs.h <<\EOF
8665 #define HAVE_NCURSESW_TERM_H 1
8674 echo "$as_me:8674: result: no" >&5
8675 echo "${ECHO_T}no" >&6
8676 NCURSES_CONFIG_PKG=none
8679 NCURSES_CONFIG_PKG=none
8682 if test "x$cf_have_ncuconfig" = "xno"; then
8683 cf_ncurses_config="${cf_ncuconfig_root}${NCURSES_CONFIG_SUFFIX}-config"; echo "Looking for ${cf_ncurses_config}"
8685 if test -n "$ac_tool_prefix"; then
8686 for ac_prog in ${cf_ncurses_config} ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
8688 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
8689 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
8690 echo "$as_me:8690: checking for $ac_word" >&5
8691 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
8692 if test "${ac_cv_prog_NCURSES_CONFIG+set}" = set; then
8693 echo $ECHO_N "(cached) $ECHO_C" >&6
8695 if test -n "$NCURSES_CONFIG"; then
8696 ac_cv_prog_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test.
8698 ac_save_IFS=$IFS; IFS=$ac_path_separator
8700 for ac_dir in $ac_dummy; do
8702 test -z "$ac_dir" && ac_dir=.
8703 $as_executable_p "$ac_dir/$ac_word" || continue
8704 ac_cv_prog_NCURSES_CONFIG="$ac_tool_prefix$ac_prog"
8705 echo "$as_me:8705: found $ac_dir/$ac_word" >&5
8711 NCURSES_CONFIG=$ac_cv_prog_NCURSES_CONFIG
8712 if test -n "$NCURSES_CONFIG"; then
8713 echo "$as_me:8713: result: $NCURSES_CONFIG" >&5
8714 echo "${ECHO_T}$NCURSES_CONFIG" >&6
8716 echo "$as_me:8716: result: no" >&5
8717 echo "${ECHO_T}no" >&6
8720 test -n "$NCURSES_CONFIG" && break
8723 if test -z "$NCURSES_CONFIG"; then
8724 ac_ct_NCURSES_CONFIG=$NCURSES_CONFIG
8725 for ac_prog in ${cf_ncurses_config} ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
8727 # Extract the first word of "$ac_prog", so it can be a program name with args.
8728 set dummy $ac_prog; ac_word=$2
8729 echo "$as_me:8729: checking for $ac_word" >&5
8730 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
8731 if test "${ac_cv_prog_ac_ct_NCURSES_CONFIG+set}" = set; then
8732 echo $ECHO_N "(cached) $ECHO_C" >&6
8734 if test -n "$ac_ct_NCURSES_CONFIG"; then
8735 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_ct_NCURSES_CONFIG" # Let the user override the test.
8737 ac_save_IFS=$IFS; IFS=$ac_path_separator
8739 for ac_dir in $ac_dummy; do
8741 test -z "$ac_dir" && ac_dir=.
8742 $as_executable_p "$ac_dir/$ac_word" || continue
8743 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_prog"
8744 echo "$as_me:8744: found $ac_dir/$ac_word" >&5
8750 ac_ct_NCURSES_CONFIG=$ac_cv_prog_ac_ct_NCURSES_CONFIG
8751 if test -n "$ac_ct_NCURSES_CONFIG"; then
8752 echo "$as_me:8752: result: $ac_ct_NCURSES_CONFIG" >&5
8753 echo "${ECHO_T}$ac_ct_NCURSES_CONFIG" >&6
8755 echo "$as_me:8755: result: no" >&5
8756 echo "${ECHO_T}no" >&6
8759 test -n "$ac_ct_NCURSES_CONFIG" && break
8761 test -n "$ac_ct_NCURSES_CONFIG" || ac_ct_NCURSES_CONFIG="none"
8763 NCURSES_CONFIG=$ac_ct_NCURSES_CONFIG
8766 if test "$NCURSES_CONFIG" != none ; then
8771 cf_new_extra_cppflags=
8773 for cf_add_cflags in `$NCURSES_CONFIG --cflags`
8775 case $cf_fix_cppflags in
8777 case $cf_add_cflags in
8778 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
8779 case $cf_add_cflags in
8781 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
8783 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
8784 && test -z "${cf_tst_cflags}" \
8785 && cf_fix_cppflags=yes
8787 if test $cf_fix_cppflags = yes ; then
8789 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
8790 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
8793 elif test "${cf_tst_cflags}" = "\"'" ; then
8795 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
8796 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
8806 case $cf_add_cflags in
8808 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
8810 CPPFLAGS=`echo "$CPPFLAGS" | \
8811 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
8812 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
8817 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
8818 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
8825 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
8826 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
8833 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
8834 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
8836 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
8838 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
8839 && test -z "${cf_tst_cflags}" \
8840 && cf_fix_cppflags=no
8845 if test -n "$cf_new_cflags" ; then
8847 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
8848 CFLAGS="${CFLAGS}$cf_new_cflags"
8852 if test -n "$cf_new_cppflags" ; then
8854 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
8855 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
8859 if test -n "$cf_new_extra_cppflags" ; then
8861 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
8862 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
8869 for cf_add_1lib in `$NCURSES_CONFIG --libs`; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
8871 for cf_add_1lib in $cf_add_0lib; do
8872 for cf_add_2lib in $cf_add_libs; do
8873 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
8878 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
8882 # even with config script, some packages use no-override for curses.h
8884 echo "$as_me:8884: checking if we have identified curses headers" >&5
8885 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
8886 if test "${cf_cv_ncurses_header+set}" = set; then
8887 echo $ECHO_N "(cached) $ECHO_C" >&6
8890 cf_cv_ncurses_header=none
8892 ncurses.h ncurses/ncurses.h \
8893 curses.h ncurses/curses.h
8895 cat >conftest.$ac_ext <<_ACEOF
8896 #line 8896 "configure"
8897 #include "confdefs.h"
8898 #include <${cf_header}>
8902 initscr(); tgoto("?", 0,0)
8907 rm -f conftest.$ac_objext
8908 if { (eval echo "$as_me:8908: \"$ac_compile\"") >&5
8909 (eval $ac_compile) 2>&5
8911 echo "$as_me:8911: \$? = $ac_status" >&5
8912 (exit $ac_status); } &&
8913 { ac_try='test -s conftest.$ac_objext'
8914 { (eval echo "$as_me:8914: \"$ac_try\"") >&5
8917 echo "$as_me:8917: \$? = $ac_status" >&5
8918 (exit $ac_status); }; }; then
8919 cf_cv_ncurses_header=$cf_header; break
8921 echo "$as_me: failed program was:" >&5
8922 cat conftest.$ac_ext >&5
8924 rm -f conftest.$ac_objext conftest.$ac_ext
8928 echo "$as_me:8928: result: $cf_cv_ncurses_header" >&5
8929 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
8931 if test "$cf_cv_ncurses_header" = none ; then
8932 { { echo "$as_me:8932: error: No curses header-files found" >&5
8933 echo "$as_me: error: No curses header-files found" >&2;}
8934 { (exit 1); exit 1; }; }
8937 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
8939 for ac_header in $cf_cv_ncurses_header
8941 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8942 echo "$as_me:8942: checking for $ac_header" >&5
8943 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8944 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8945 echo $ECHO_N "(cached) $ECHO_C" >&6
8947 cat >conftest.$ac_ext <<_ACEOF
8948 #line 8948 "configure"
8949 #include "confdefs.h"
8950 #include <$ac_header>
8952 if { (eval echo "$as_me:8952: \"$ac_cpp conftest.$ac_ext\"") >&5
8953 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8955 egrep -v '^ *\+' conftest.er1 >conftest.err
8957 cat conftest.err >&5
8958 echo "$as_me:8958: \$? = $ac_status" >&5
8959 (exit $ac_status); } >/dev/null; then
8960 if test -s conftest.err; then
8961 ac_cpp_err=$ac_c_preproc_warn_flag
8968 if test -z "$ac_cpp_err"; then
8969 eval "$as_ac_Header=yes"
8971 echo "$as_me: failed program was:" >&5
8972 cat conftest.$ac_ext >&5
8973 eval "$as_ac_Header=no"
8975 rm -f conftest.err conftest.$ac_ext
8977 echo "$as_me:8977: result: `eval echo '${'$as_ac_Header'}'`" >&5
8978 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8979 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8980 cat >>confdefs.h <<EOF
8981 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8987 cat >>confdefs.h <<\EOF
8991 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
8993 cat >>confdefs.h <<EOF
8994 #define $cf_nculib_ROOT 1
8997 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
9001 cf_ncuhdr_root=ncurses
9003 test -n "$cf_cv_curses_dir" && \
9004 test "$cf_cv_curses_dir" != "no" && { \
9006 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
9007 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
9009 while test $cf_add_incdir != /usr/include
9011 if test -d $cf_add_incdir
9014 if test -n "$CFLAGS$CPPFLAGS" ; then
9015 # a loop is needed to ensure we can add subdirs of existing dirs
9016 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
9017 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
9018 cf_have_incdir=yes; break
9023 if test "$cf_have_incdir" = no ; then
9024 if test "$cf_add_incdir" = /usr/local/include ; then
9025 if test "$GCC" = yes
9027 cf_save_CPPFLAGS=$CPPFLAGS
9029 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
9030 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
9032 cat >conftest.$ac_ext <<_ACEOF
9033 #line 9033 "configure"
9034 #include "confdefs.h"
9044 rm -f conftest.$ac_objext
9045 if { (eval echo "$as_me:9045: \"$ac_compile\"") >&5
9046 (eval $ac_compile) 2>&5
9048 echo "$as_me:9048: \$? = $ac_status" >&5
9049 (exit $ac_status); } &&
9050 { ac_try='test -s conftest.$ac_objext'
9051 { (eval echo "$as_me:9051: \"$ac_try\"") >&5
9054 echo "$as_me:9054: \$? = $ac_status" >&5
9055 (exit $ac_status); }; }; then
9058 echo "$as_me: failed program was:" >&5
9059 cat conftest.$ac_ext >&5
9062 rm -f conftest.$ac_objext conftest.$ac_ext
9063 CPPFLAGS=$cf_save_CPPFLAGS
9068 if test "$cf_have_incdir" = no ; then
9069 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
9071 echo "${as_me:-configure}:9071: testing adding $cf_add_incdir to include-path ..." 1>&5
9073 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
9075 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
9076 test "$cf_top_incdir" = "$cf_add_incdir" && break
9077 cf_add_incdir="$cf_top_incdir"
9090 echo "$as_me:9090: checking for $cf_ncuhdr_root header in include-path" >&5
9091 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
9092 if test "${cf_cv_ncurses_h+set}" = set; then
9093 echo $ECHO_N "(cached) $ECHO_C" >&6
9096 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
9097 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
9098 for cf_header in $cf_header_list
9101 cat >conftest.$ac_ext <<_ACEOF
9102 #line 9102 "configure"
9103 #include "confdefs.h"
9105 #include <$cf_header>
9110 #ifdef NCURSES_VERSION
9112 printf("%s\n", NCURSES_VERSION);
9125 rm -f conftest.$ac_objext
9126 if { (eval echo "$as_me:9126: \"$ac_compile\"") >&5
9127 (eval $ac_compile) 2>&5
9129 echo "$as_me:9129: \$? = $ac_status" >&5
9130 (exit $ac_status); } &&
9131 { ac_try='test -s conftest.$ac_objext'
9132 { (eval echo "$as_me:9132: \"$ac_try\"") >&5
9135 echo "$as_me:9135: \$? = $ac_status" >&5
9136 (exit $ac_status); }; }; then
9137 cf_cv_ncurses_h=$cf_header
9140 echo "$as_me: failed program was:" >&5
9141 cat conftest.$ac_ext >&5
9144 rm -f conftest.$ac_objext conftest.$ac_ext
9146 test "$cf_cv_ncurses_h" != no && break
9150 echo "$as_me:9150: result: $cf_cv_ncurses_h" >&5
9151 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
9153 if test "$cf_cv_ncurses_h" != no ; then
9154 cf_cv_ncurses_header=$cf_cv_ncurses_h
9157 echo "$as_me:9157: checking for $cf_ncuhdr_root include-path" >&5
9158 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
9159 if test "${cf_cv_ncurses_h2+set}" = set; then
9160 echo $ECHO_N "(cached) $ECHO_C" >&6
9163 test -n "$verbose" && echo
9167 # collect the current set of include-directories from compiler flags
9168 cf_header_path_list=""
9169 if test -n "${CFLAGS}${CPPFLAGS}" ; then
9170 for cf_header_path in $CPPFLAGS $CFLAGS
9172 case $cf_header_path in
9174 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
9176 test "x$cf_header_path" != "xNONE" && \
9177 test -d "$cf_header_path" && \
9179 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
9180 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
9181 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
9182 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
9183 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
9184 test -d $cf_header_path/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
9187 cf_header_path_list="$cf_header_path_list $cf_search"
9193 # add the variations for the package we are looking for
9197 test "x$prefix" != "xNONE" && \
9198 test -d "$prefix" && \
9200 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
9201 test -d $prefix/include && cf_search="$cf_search $prefix/include"
9202 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
9203 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
9204 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
9205 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
9208 for cf_subdir_prefix in \
9217 test "x$cf_subdir_prefix" != "x$prefix" && \
9218 test -d "$cf_subdir_prefix" && \
9219 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
9220 test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
9221 test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include"
9222 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root"
9223 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root/include"
9224 test -d $cf_subdir_prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include"
9225 test -d $cf_subdir_prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
9230 test "$includedir" != NONE && \
9231 test "$includedir" != "/usr/include" && \
9232 test -d "$includedir" && {
9233 test -d $includedir && cf_search="$cf_search $includedir"
9234 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
9237 test "$oldincludedir" != NONE && \
9238 test "$oldincludedir" != "/usr/include" && \
9239 test -d "$oldincludedir" && {
9240 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
9241 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
9244 cf_search="$cf_search $cf_header_path_list"
9246 test -n "$verbose" && echo search path $cf_search
9247 cf_save2_CPPFLAGS="$CPPFLAGS"
9248 for cf_incdir in $cf_search
9251 if test -n "$cf_incdir" ; then
9252 for cf_add_incdir in $cf_incdir
9254 while test $cf_add_incdir != /usr/include
9256 if test -d $cf_add_incdir
9259 if test -n "$CFLAGS$CPPFLAGS" ; then
9260 # a loop is needed to ensure we can add subdirs of existing dirs
9261 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
9262 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
9263 cf_have_incdir=yes; break
9268 if test "$cf_have_incdir" = no ; then
9269 if test "$cf_add_incdir" = /usr/local/include ; then
9270 if test "$GCC" = yes
9272 cf_save_CPPFLAGS=$CPPFLAGS
9274 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
9275 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
9277 cat >conftest.$ac_ext <<_ACEOF
9278 #line 9278 "configure"
9279 #include "confdefs.h"
9289 rm -f conftest.$ac_objext
9290 if { (eval echo "$as_me:9290: \"$ac_compile\"") >&5
9291 (eval $ac_compile) 2>&5
9293 echo "$as_me:9293: \$? = $ac_status" >&5
9294 (exit $ac_status); } &&
9295 { ac_try='test -s conftest.$ac_objext'
9296 { (eval echo "$as_me:9296: \"$ac_try\"") >&5
9299 echo "$as_me:9299: \$? = $ac_status" >&5
9300 (exit $ac_status); }; }; then
9303 echo "$as_me: failed program was:" >&5
9304 cat conftest.$ac_ext >&5
9307 rm -f conftest.$ac_objext conftest.$ac_ext
9308 CPPFLAGS=$cf_save_CPPFLAGS
9313 if test "$cf_have_incdir" = no ; then
9314 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
9316 echo "${as_me:-configure}:9316: testing adding $cf_add_incdir to include-path ..." 1>&5
9318 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
9320 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
9321 test "$cf_top_incdir" = "$cf_add_incdir" && break
9322 cf_add_incdir="$cf_top_incdir"
9338 cat >conftest.$ac_ext <<_ACEOF
9339 #line 9339 "configure"
9340 #include "confdefs.h"
9342 #include <$cf_header>
9347 #ifdef NCURSES_VERSION
9349 printf("%s\n", NCURSES_VERSION);
9362 rm -f conftest.$ac_objext
9363 if { (eval echo "$as_me:9363: \"$ac_compile\"") >&5
9364 (eval $ac_compile) 2>&5
9366 echo "$as_me:9366: \$? = $ac_status" >&5
9367 (exit $ac_status); } &&
9368 { ac_try='test -s conftest.$ac_objext'
9369 { (eval echo "$as_me:9369: \"$ac_try\"") >&5
9372 echo "$as_me:9372: \$? = $ac_status" >&5
9373 (exit $ac_status); }; }; then
9374 cf_cv_ncurses_h2=$cf_header
9377 echo "$as_me: failed program was:" >&5
9378 cat conftest.$ac_ext >&5
9381 rm -f conftest.$ac_objext conftest.$ac_ext
9383 if test "$cf_cv_ncurses_h2" != no ; then
9384 cf_cv_ncurses_h2=$cf_incdir/$cf_header
9385 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
9388 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
9390 CPPFLAGS="$cf_save2_CPPFLAGS"
9391 test "$cf_cv_ncurses_h2" != no && break
9393 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:9393: error: not found" >&5
9394 echo "$as_me: error: not found" >&2;}
9395 { (exit 1); exit 1; }; }
9398 echo "$as_me:9398: result: $cf_cv_ncurses_h2" >&5
9399 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
9401 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
9402 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
9403 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
9404 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
9407 if test -n "$cf_1st_incdir" ; then
9408 for cf_add_incdir in $cf_1st_incdir
9410 while test $cf_add_incdir != /usr/include
9412 if test -d $cf_add_incdir
9415 if test -n "$CFLAGS$CPPFLAGS" ; then
9416 # a loop is needed to ensure we can add subdirs of existing dirs
9417 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
9418 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
9419 cf_have_incdir=yes; break
9424 if test "$cf_have_incdir" = no ; then
9425 if test "$cf_add_incdir" = /usr/local/include ; then
9426 if test "$GCC" = yes
9428 cf_save_CPPFLAGS=$CPPFLAGS
9430 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
9431 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
9433 cat >conftest.$ac_ext <<_ACEOF
9434 #line 9434 "configure"
9435 #include "confdefs.h"
9445 rm -f conftest.$ac_objext
9446 if { (eval echo "$as_me:9446: \"$ac_compile\"") >&5
9447 (eval $ac_compile) 2>&5
9449 echo "$as_me:9449: \$? = $ac_status" >&5
9450 (exit $ac_status); } &&
9451 { ac_try='test -s conftest.$ac_objext'
9452 { (eval echo "$as_me:9452: \"$ac_try\"") >&5
9455 echo "$as_me:9455: \$? = $ac_status" >&5
9456 (exit $ac_status); }; }; then
9459 echo "$as_me: failed program was:" >&5
9460 cat conftest.$ac_ext >&5
9463 rm -f conftest.$ac_objext conftest.$ac_ext
9464 CPPFLAGS=$cf_save_CPPFLAGS
9469 if test "$cf_have_incdir" = no ; then
9470 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
9472 echo "${as_me:-configure}:9472: testing adding $cf_add_incdir to include-path ..." 1>&5
9474 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
9476 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
9477 test "$cf_top_incdir" = "$cf_add_incdir" && break
9478 cf_add_incdir="$cf_top_incdir"
9491 # Set definitions to allow ifdef'ing for ncurses.h
9493 case $cf_cv_ncurses_header in
9496 cat >>confdefs.h <<\EOF
9497 #define HAVE_NCURSES_H 1
9503 case $cf_cv_ncurses_header in
9504 (ncurses/curses.h|ncurses/ncurses.h)
9506 cat >>confdefs.h <<\EOF
9507 #define HAVE_NCURSES_NCURSES_H 1
9511 (ncursesw/curses.h|ncursesw/ncurses.h)
9513 cat >>confdefs.h <<\EOF
9514 #define HAVE_NCURSESW_NCURSES_H 1
9520 echo "$as_me:9520: checking for terminfo header" >&5
9521 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
9522 if test "${cf_cv_term_header+set}" = set; then
9523 echo $ECHO_N "(cached) $ECHO_C" >&6
9526 case ${cf_cv_ncurses_header} in
9527 (*/ncurses.h|*/ncursesw.h)
9528 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
9531 cf_term_header=term.h
9535 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
9537 cat >conftest.$ac_ext <<_ACEOF
9538 #line 9538 "configure"
9539 #include "confdefs.h"
9541 #include <${cf_cv_ncurses_header:-curses.h}>
9547 int x = auto_left_margin
9552 rm -f conftest.$ac_objext
9553 if { (eval echo "$as_me:9553: \"$ac_compile\"") >&5
9554 (eval $ac_compile) 2>&5
9556 echo "$as_me:9556: \$? = $ac_status" >&5
9557 (exit $ac_status); } &&
9558 { ac_try='test -s conftest.$ac_objext'
9559 { (eval echo "$as_me:9559: \"$ac_try\"") >&5
9562 echo "$as_me:9562: \$? = $ac_status" >&5
9563 (exit $ac_status); }; }; then
9565 cf_cv_term_header="$cf_test"
9567 echo "$as_me: failed program was:" >&5
9568 cat conftest.$ac_ext >&5
9570 cf_cv_term_header=unknown
9573 rm -f conftest.$ac_objext conftest.$ac_ext
9574 test "$cf_cv_term_header" != unknown && break
9578 echo "$as_me:9578: result: $cf_cv_term_header" >&5
9579 echo "${ECHO_T}$cf_cv_term_header" >&6
9581 # Set definitions to allow ifdef'ing to accommodate subdirectories
9583 case $cf_cv_term_header in
9586 cat >>confdefs.h <<\EOF
9587 #define HAVE_TERM_H 1
9593 case $cf_cv_term_header in
9596 cat >>confdefs.h <<\EOF
9597 #define HAVE_NCURSES_TERM_H 1
9603 cat >>confdefs.h <<\EOF
9604 #define HAVE_NCURSESW_TERM_H 1
9610 # some applications need this, but should check for NCURSES_VERSION
9612 cat >>confdefs.h <<\EOF
9616 echo "$as_me:9616: checking for ncurses version" >&5
9617 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
9618 if test "${cf_cv_ncurses_version+set}" = set; then
9619 echo $ECHO_N "(cached) $ECHO_C" >&6
9622 cf_cv_ncurses_version=no
9625 if test "$cross_compiling" = yes; then
9627 # This will not work if the preprocessor splits the line after the
9628 # Autoconf token. The 'unproto' program does that.
9629 cat > conftest.$ac_ext <<EOF
9630 #include <${cf_cv_ncurses_header:-curses.h}>
9632 #ifdef NCURSES_VERSION
9633 Autoconf NCURSES_VERSION
9641 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
9642 { (eval echo "$as_me:9642: \"$cf_try\"") >&5
9645 echo "$as_me:9645: \$? = $ac_status" >&5
9646 (exit $ac_status); }
9647 if test -f conftest.out ; then
9648 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
9649 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
9654 cat >conftest.$ac_ext <<_ACEOF
9655 #line 9655 "configure"
9656 #include "confdefs.h"
9658 #include <${cf_cv_ncurses_header:-curses.h}>
9662 FILE *fp = fopen("$cf_tempfile", "w");
9663 #ifdef NCURSES_VERSION
9664 # ifdef NCURSES_VERSION_PATCH
9665 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
9667 fprintf(fp, "%s\n", NCURSES_VERSION);
9671 fprintf(fp, "old\n");
9676 ${cf_cv_main_return:-return}(0);
9679 rm -f conftest$ac_exeext
9680 if { (eval echo "$as_me:9680: \"$ac_link\"") >&5
9681 (eval $ac_link) 2>&5
9683 echo "$as_me:9683: \$? = $ac_status" >&5
9684 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
9685 { (eval echo "$as_me:9685: \"$ac_try\"") >&5
9688 echo "$as_me:9688: \$? = $ac_status" >&5
9689 (exit $ac_status); }; }; then
9691 cf_cv_ncurses_version=`cat $cf_tempfile`
9693 echo "$as_me: program exited with status $ac_status" >&5
9694 echo "$as_me: failed program was:" >&5
9695 cat conftest.$ac_ext >&5
9697 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
9702 echo "$as_me:9702: result: $cf_cv_ncurses_version" >&5
9703 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
9704 test "$cf_cv_ncurses_version" = no ||
9705 cat >>confdefs.h <<\EOF
9709 cf_nculib_root=ncurses
9710 # This works, except for the special case where we find gpm, but
9711 # ncurses is in a nonstandard location via $LIBS, and we really want
9714 cf_ncurses_SAVE="$LIBS"
9715 echo "$as_me:9715: checking for Gpm_Open in -lgpm" >&5
9716 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
9717 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
9718 echo $ECHO_N "(cached) $ECHO_C" >&6
9720 ac_check_lib_save_LIBS=$LIBS
9722 cat >conftest.$ac_ext <<_ACEOF
9723 #line 9723 "configure"
9724 #include "confdefs.h"
9726 /* Override any gcc2 internal prototype to avoid an error. */
9730 /* We use char because int might match the return type of a gcc2
9731 builtin and then its argument prototype would still apply. */
9741 rm -f conftest.$ac_objext conftest$ac_exeext
9742 if { (eval echo "$as_me:9742: \"$ac_link\"") >&5
9743 (eval $ac_link) 2>&5
9745 echo "$as_me:9745: \$? = $ac_status" >&5
9746 (exit $ac_status); } &&
9747 { ac_try='test -s conftest$ac_exeext'
9748 { (eval echo "$as_me:9748: \"$ac_try\"") >&5
9751 echo "$as_me:9751: \$? = $ac_status" >&5
9752 (exit $ac_status); }; }; then
9753 ac_cv_lib_gpm_Gpm_Open=yes
9755 echo "$as_me: failed program was:" >&5
9756 cat conftest.$ac_ext >&5
9757 ac_cv_lib_gpm_Gpm_Open=no
9759 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9760 LIBS=$ac_check_lib_save_LIBS
9762 echo "$as_me:9762: result: $ac_cv_lib_gpm_Gpm_Open" >&5
9763 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
9764 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
9765 echo "$as_me:9765: checking for initscr in -lgpm" >&5
9766 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
9767 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
9768 echo $ECHO_N "(cached) $ECHO_C" >&6
9770 ac_check_lib_save_LIBS=$LIBS
9772 cat >conftest.$ac_ext <<_ACEOF
9773 #line 9773 "configure"
9774 #include "confdefs.h"
9776 /* Override any gcc2 internal prototype to avoid an error. */
9780 /* We use char because int might match the return type of a gcc2
9781 builtin and then its argument prototype would still apply. */
9791 rm -f conftest.$ac_objext conftest$ac_exeext
9792 if { (eval echo "$as_me:9792: \"$ac_link\"") >&5
9793 (eval $ac_link) 2>&5
9795 echo "$as_me:9795: \$? = $ac_status" >&5
9796 (exit $ac_status); } &&
9797 { ac_try='test -s conftest$ac_exeext'
9798 { (eval echo "$as_me:9798: \"$ac_try\"") >&5
9801 echo "$as_me:9801: \$? = $ac_status" >&5
9802 (exit $ac_status); }; }; then
9803 ac_cv_lib_gpm_initscr=yes
9805 echo "$as_me: failed program was:" >&5
9806 cat conftest.$ac_ext >&5
9807 ac_cv_lib_gpm_initscr=no
9809 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9810 LIBS=$ac_check_lib_save_LIBS
9812 echo "$as_me:9812: result: $ac_cv_lib_gpm_initscr" >&5
9813 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
9814 if test $ac_cv_lib_gpm_initscr = yes; then
9815 LIBS="$cf_ncurses_SAVE"
9817 cf_ncurses_LIBS="-lgpm"
9824 # This is only necessary if you are linking against an obsolete
9825 # version of ncurses (but it should do no harm, since it's static).
9826 if test "$cf_nculib_root" = ncurses ; then
9827 echo "$as_me:9827: checking for tgoto in -lmytinfo" >&5
9828 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
9829 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
9830 echo $ECHO_N "(cached) $ECHO_C" >&6
9832 ac_check_lib_save_LIBS=$LIBS
9833 LIBS="-lmytinfo $LIBS"
9834 cat >conftest.$ac_ext <<_ACEOF
9835 #line 9835 "configure"
9836 #include "confdefs.h"
9838 /* Override any gcc2 internal prototype to avoid an error. */
9842 /* We use char because int might match the return type of a gcc2
9843 builtin and then its argument prototype would still apply. */
9853 rm -f conftest.$ac_objext conftest$ac_exeext
9854 if { (eval echo "$as_me:9854: \"$ac_link\"") >&5
9855 (eval $ac_link) 2>&5
9857 echo "$as_me:9857: \$? = $ac_status" >&5
9858 (exit $ac_status); } &&
9859 { ac_try='test -s conftest$ac_exeext'
9860 { (eval echo "$as_me:9860: \"$ac_try\"") >&5
9863 echo "$as_me:9863: \$? = $ac_status" >&5
9864 (exit $ac_status); }; }; then
9865 ac_cv_lib_mytinfo_tgoto=yes
9867 echo "$as_me: failed program was:" >&5
9868 cat conftest.$ac_ext >&5
9869 ac_cv_lib_mytinfo_tgoto=no
9871 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9872 LIBS=$ac_check_lib_save_LIBS
9874 echo "$as_me:9874: result: $ac_cv_lib_mytinfo_tgoto" >&5
9875 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
9876 if test $ac_cv_lib_mytinfo_tgoto = yes; then
9877 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
9887 for cf_add_1lib in $cf_ncurses_LIBS; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
9889 for cf_add_1lib in $cf_add_0lib; do
9890 for cf_add_2lib in $cf_add_libs; do
9891 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
9896 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
9900 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
9906 for cf_add_1lib in -l$cf_nculib_root; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
9908 for cf_add_1lib in $cf_add_0lib; do
9909 for cf_add_2lib in $cf_add_libs; do
9910 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
9915 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
9921 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
9923 echo "$as_me:9923: checking for initscr" >&5
9924 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
9925 if test "${ac_cv_func_initscr+set}" = set; then
9926 echo $ECHO_N "(cached) $ECHO_C" >&6
9928 cat >conftest.$ac_ext <<_ACEOF
9929 #line 9929 "configure"
9930 #include "confdefs.h"
9931 #define initscr autoconf_temporary
9932 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
9939 /* We use char because int might match the return type of a gcc2
9940 builtin and then its argument prototype would still apply. */
9941 char initscr (void);
9947 /* The GNU C library defines stubs for functions which it implements
9948 to always fail with ENOSYS. Some functions are actually named
9949 something starting with __ and the normal name is an alias. */
9950 #if defined (__stub_initscr) || defined (__stub___initscr)
9951 #error found stub for initscr
9959 rm -f conftest.$ac_objext conftest$ac_exeext
9960 if { (eval echo "$as_me:9960: \"$ac_link\"") >&5
9961 (eval $ac_link) 2>&5
9963 echo "$as_me:9963: \$? = $ac_status" >&5
9964 (exit $ac_status); } &&
9965 { ac_try='test -s conftest$ac_exeext'
9966 { (eval echo "$as_me:9966: \"$ac_try\"") >&5
9969 echo "$as_me:9969: \$? = $ac_status" >&5
9970 (exit $ac_status); }; }; then
9971 ac_cv_func_initscr=yes
9973 echo "$as_me: failed program was:" >&5
9974 cat conftest.$ac_ext >&5
9975 ac_cv_func_initscr=no
9977 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9979 echo "$as_me:9979: result: $ac_cv_func_initscr" >&5
9980 echo "${ECHO_T}$ac_cv_func_initscr" >&6
9981 if test $ac_cv_func_initscr = yes; then
9982 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
9985 cf_save_LIBS="$LIBS"
9986 echo "$as_me:9986: checking for initscr in -l$cf_nculib_root" >&5
9987 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
9988 LIBS="-l$cf_nculib_root $LIBS"
9989 cat >conftest.$ac_ext <<_ACEOF
9990 #line 9990 "configure"
9991 #include "confdefs.h"
9992 #include <${cf_cv_ncurses_header:-curses.h}>
10001 rm -f conftest.$ac_objext conftest$ac_exeext
10002 if { (eval echo "$as_me:10002: \"$ac_link\"") >&5
10003 (eval $ac_link) 2>&5
10005 echo "$as_me:10005: \$? = $ac_status" >&5
10006 (exit $ac_status); } &&
10007 { ac_try='test -s conftest$ac_exeext'
10008 { (eval echo "$as_me:10008: \"$ac_try\"") >&5
10009 (eval $ac_try) 2>&5
10011 echo "$as_me:10011: \$? = $ac_status" >&5
10012 (exit $ac_status); }; }; then
10013 echo "$as_me:10013: result: yes" >&5
10014 echo "${ECHO_T}yes" >&6
10015 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
10018 echo "$as_me: failed program was:" >&5
10019 cat conftest.$ac_ext >&5
10020 echo "$as_me:10020: result: no" >&5
10021 echo "${ECHO_T}no" >&6
10024 cf_library_path_list=""
10025 if test -n "${LDFLAGS}${LIBS}" ; then
10026 for cf_library_path in $LDFLAGS $LIBS
10028 case $cf_library_path in
10030 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
10032 test "x$cf_library_path" != "xNONE" && \
10033 test -d "$cf_library_path" && \
10035 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
10036 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
10037 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
10038 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
10039 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
10040 test -d $cf_library_path/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib/$cf_nculib_root"
10043 cf_library_path_list="$cf_library_path_list $cf_search"
10051 test "x$prefix" != "xNONE" && \
10052 test -d "$prefix" && \
10054 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
10055 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
10056 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
10057 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
10058 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
10059 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
10062 for cf_subdir_prefix in \
10071 test "x$cf_subdir_prefix" != "x$prefix" && \
10072 test -d "$cf_subdir_prefix" && \
10073 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
10074 test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
10075 test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib"
10076 test -d $cf_subdir_prefix/lib/$cf_nculib_root && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root"
10077 test -d $cf_subdir_prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root/lib"
10078 test -d $cf_subdir_prefix/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib"
10079 test -d $cf_subdir_prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib/$cf_nculib_root"
10084 cf_search="$cf_library_path_list $cf_search"
10086 for cf_libdir in $cf_search
10088 echo "$as_me:10088: checking for -l$cf_nculib_root in $cf_libdir" >&5
10089 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
10090 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
10091 cat >conftest.$ac_ext <<_ACEOF
10092 #line 10092 "configure"
10093 #include "confdefs.h"
10094 #include <${cf_cv_ncurses_header:-curses.h}>
10103 rm -f conftest.$ac_objext conftest$ac_exeext
10104 if { (eval echo "$as_me:10104: \"$ac_link\"") >&5
10105 (eval $ac_link) 2>&5
10107 echo "$as_me:10107: \$? = $ac_status" >&5
10108 (exit $ac_status); } &&
10109 { ac_try='test -s conftest$ac_exeext'
10110 { (eval echo "$as_me:10110: \"$ac_try\"") >&5
10111 (eval $ac_try) 2>&5
10113 echo "$as_me:10113: \$? = $ac_status" >&5
10114 (exit $ac_status); }; }; then
10115 echo "$as_me:10115: result: yes" >&5
10116 echo "${ECHO_T}yes" >&6
10117 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
10120 echo "$as_me: failed program was:" >&5
10121 cat conftest.$ac_ext >&5
10122 echo "$as_me:10122: result: no" >&5
10123 echo "${ECHO_T}no" >&6
10124 LIBS="$cf_save_LIBS"
10126 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10130 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10134 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
10136 if test $cf_found_library = no ; then
10137 { { echo "$as_me:10137: error: Cannot link $cf_nculib_root library" >&5
10138 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
10139 { (exit 1); exit 1; }; }
10144 if test -n "$cf_ncurses_LIBS" ; then
10145 echo "$as_me:10145: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
10146 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
10147 cf_ncurses_SAVE="$LIBS"
10148 for p in $cf_ncurses_LIBS ; do
10149 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
10150 if test "$q" != "$LIBS" ; then
10154 cat >conftest.$ac_ext <<_ACEOF
10155 #line 10155 "configure"
10156 #include "confdefs.h"
10157 #include <${cf_cv_ncurses_header:-curses.h}>
10161 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
10166 rm -f conftest.$ac_objext conftest$ac_exeext
10167 if { (eval echo "$as_me:10167: \"$ac_link\"") >&5
10168 (eval $ac_link) 2>&5
10170 echo "$as_me:10170: \$? = $ac_status" >&5
10171 (exit $ac_status); } &&
10172 { ac_try='test -s conftest$ac_exeext'
10173 { (eval echo "$as_me:10173: \"$ac_try\"") >&5
10174 (eval $ac_try) 2>&5
10176 echo "$as_me:10176: \$? = $ac_status" >&5
10177 (exit $ac_status); }; }; then
10178 echo "$as_me:10178: result: yes" >&5
10179 echo "${ECHO_T}yes" >&6
10181 echo "$as_me: failed program was:" >&5
10182 cat conftest.$ac_ext >&5
10183 echo "$as_me:10183: result: no" >&5
10184 echo "${ECHO_T}no" >&6
10185 LIBS="$cf_ncurses_SAVE"
10187 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10190 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
10192 cat >>confdefs.h <<EOF
10193 #define $cf_nculib_ROOT 1
10198 NCURSES_CONFIG=none
10203 if test "$NCURSES_CONFIG_PKG" != none ; then
10204 cf_version=`$PKG_CONFIG --modversion $NCURSES_CONFIG_PKG 2>/dev/null`
10206 NCURSES_MAJOR=`echo "$cf_version" | sed -e 's/\..*//'`
10207 NCURSES_MINOR=`echo "$cf_version" | sed -e 's/^[0-9][0-9]*\.//' -e 's/\..*//'`
10208 NCURSES_PATCH=`echo "$cf_version" | sed -e 's/^[0-9][0-9]*\.[0-9][0-9]*\.//'`
10210 cf_cv_abi_version=`$PKG_CONFIG --variable=abi_version $NCURSES_CONFIG_PKG 2>/dev/null`
10211 if test -z "$cf_cv_abi_version"
10213 cf_cv_abi_version=`$PKG_CONFIG --variable=major_version $NCURSES_CONFIG_PKG 2>/dev/null`
10216 elif test "$NCURSES_CONFIG" != none ; then
10218 cf_version=`$NCURSES_CONFIG --version 2>/dev/null`
10220 NCURSES_MAJOR=`echo "$cf_version" | sed -e 's/\..*//'`
10221 NCURSES_MINOR=`echo "$cf_version" | sed -e 's/^[0-9][0-9]*\.//' -e 's/\..*//'`
10222 NCURSES_PATCH=`echo "$cf_version" | sed -e 's/^[0-9][0-9]*\.[0-9][0-9]*\.//'`
10224 # ABI version is not available from headers
10225 cf_cv_abi_version=`$NCURSES_CONFIG --abi-version 2>/dev/null`
10229 for cf_name in MAJOR MINOR PATCH
10231 cat >conftest.$ac_ext <<CF_EOF
10232 #include <${cf_cv_ncurses_header:-curses.h}>
10233 AUTOCONF_$cf_name NCURSES_VERSION_$cf_name
10235 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | fgrep AUTOCONF_$cf_name >conftest.out"
10236 { (eval echo "$as_me:10236: \"$cf_try\"") >&5
10237 (eval $cf_try) 2>&5
10239 echo "$as_me:10239: \$? = $ac_status" >&5
10240 (exit $ac_status); }
10241 if test -f conftest.out ; then
10242 cf_result=`cat conftest.out | sed -e "s/^.*AUTOCONF_$cf_name[ ][ ]*//"`
10243 eval NCURSES_$cf_name=\"$cf_result\"
10244 # cat conftest.$ac_ext
10249 cf_cv_abi_version=${NCURSES_MAJOR}
10253 cf_cv_rel_version=${NCURSES_MAJOR}.${NCURSES_MINOR}
10255 cf_cv_timestamp=`date`
10257 echo "$as_me:10257: result: Configuring NCURSES $cf_cv_rel_version ABI $cf_cv_abi_version ($cf_cv_timestamp)" >&5
10258 echo "${ECHO_T}Configuring NCURSES $cf_cv_rel_version ABI $cf_cv_abi_version ($cf_cv_timestamp)" >&6
10260 echo "$as_me:10260: checking if you want to have a library-prefix" >&5
10261 echo $ECHO_N "checking if you want to have a library-prefix... $ECHO_C" >&6
10263 # Check whether --with-lib-prefix or --without-lib-prefix was given.
10264 if test "${with_lib_prefix+set}" = set; then
10265 withval="$with_lib_prefix"
10266 with_lib_prefix=$withval
10268 with_lib_prefix=auto
10270 echo "$as_me:10270: result: $with_lib_prefix" >&5
10271 echo "${ECHO_T}$with_lib_prefix" >&6
10273 if test $with_lib_prefix = auto
10276 case $cf_cv_system_name in
10278 if test "$DFT_LWR_MODEL" = libtool; then
10284 (*) LIB_PREFIX='lib'
10287 cf_prefix=$LIB_PREFIX
10289 elif test $with_lib_prefix = no
10293 LIB_PREFIX=$with_lib_prefix
10298 ###############################################################################
10300 if test X"$CC_G_OPT" = X"" ; then
10302 test -n "$GCC" && test "${ac_cv_prog_cc_g}" != yes && CC_G_OPT=''
10305 echo "$as_me:10305: checking for default loader flags" >&5
10306 echo $ECHO_N "checking for default loader flags... $ECHO_C" >&6
10307 case $DFT_LWR_MODEL in
10308 (normal) LD_MODEL='' ;;
10309 (debug) LD_MODEL=$CC_G_OPT ;;
10310 (profile) LD_MODEL='-pg';;
10311 (shared) LD_MODEL='' ;;
10313 echo "$as_me:10313: result: $LD_MODEL" >&5
10314 echo "${ECHO_T}$LD_MODEL" >&6
10317 if test "x$cf_cv_enable_rpath" != xno
10319 echo "$as_me:10319: checking for an rpath option" >&5
10320 echo $ECHO_N "checking for an rpath option... $ECHO_C" >&6
10321 case $cf_cv_system_name in
10323 if test "$GCC" = yes; then
10324 LD_RPATH_OPT="-Wl,-rpath,"
10326 LD_RPATH_OPT="-rpath "
10329 (linux*|gnu*|k*bsd*-gnu|freebsd*)
10330 LD_RPATH_OPT="-Wl,-rpath,"
10332 (openbsd[2-9].*|mirbsd*)
10333 LD_RPATH_OPT="-Wl,-rpath,"
10336 LD_RPATH_OPT="-rpath "
10339 LD_RPATH_OPT="-Wl,-rpath,"
10342 LD_RPATH_OPT="-rpath "
10350 echo "$as_me:10350: result: $LD_RPATH_OPT" >&5
10351 echo "${ECHO_T}$LD_RPATH_OPT" >&6
10353 case "x$LD_RPATH_OPT" in
10355 echo "$as_me:10355: checking if we need a space after rpath option" >&5
10356 echo $ECHO_N "checking if we need a space after rpath option... $ECHO_C" >&6
10357 cf_save_LIBS="$LIBS"
10359 cf_add_libs="$LIBS"
10362 for cf_add_1lib in ${LD_RPATH_OPT}$libdir; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
10363 # filter duplicates
10364 for cf_add_1lib in $cf_add_0lib; do
10365 for cf_add_2lib in $cf_add_libs; do
10366 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
10371 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
10373 LIBS="$cf_add_libs"
10375 cat >conftest.$ac_ext <<_ACEOF
10376 #line 10376 "configure"
10377 #include "confdefs.h"
10387 rm -f conftest.$ac_objext conftest$ac_exeext
10388 if { (eval echo "$as_me:10388: \"$ac_link\"") >&5
10389 (eval $ac_link) 2>&5
10391 echo "$as_me:10391: \$? = $ac_status" >&5
10392 (exit $ac_status); } &&
10393 { ac_try='test -s conftest$ac_exeext'
10394 { (eval echo "$as_me:10394: \"$ac_try\"") >&5
10395 (eval $ac_try) 2>&5
10397 echo "$as_me:10397: \$? = $ac_status" >&5
10398 (exit $ac_status); }; }; then
10401 echo "$as_me: failed program was:" >&5
10402 cat conftest.$ac_ext >&5
10405 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10406 LIBS="$cf_save_LIBS"
10407 echo "$as_me:10407: result: $cf_rpath_space" >&5
10408 echo "${ECHO_T}$cf_rpath_space" >&6
10409 test "$cf_rpath_space" = yes && LD_RPATH_OPT="$LD_RPATH_OPT "
10418 INSTALL_LIB="-m 644"
10419 : ${rel_builddir:=.}
10425 cf_cv_do_symlinks=no
10427 test "$cf_cv_enable_rpath" = yes && cf_ld_rpath_opt="$LD_RPATH_OPT"
10429 echo "$as_me:10429: checking if release/abi version should be used for shared libs" >&5
10430 echo $ECHO_N "checking if release/abi version should be used for shared libs... $ECHO_C" >&6
10432 # Check whether --with-shlib-version or --without-shlib-version was given.
10433 if test "${with_shlib_version+set}" = set; then
10434 withval="$with_shlib_version"
10435 test -z "$withval" && withval=auto
10438 cf_cv_shlib_version=auto
10441 cf_cv_shlib_version=$withval
10444 echo "$as_me:10444: result: $withval" >&5
10445 echo "${ECHO_T}$withval" >&6
10446 { { echo "$as_me:10446: error: option value must be one of: rel, abi, or auto" >&5
10447 echo "$as_me: error: option value must be one of: rel, abi, or auto" >&2;}
10448 { (exit 1); exit 1; }; }
10453 cf_cv_shlib_version=auto
10455 echo "$as_me:10455: result: $cf_cv_shlib_version" >&5
10456 echo "${ECHO_T}$cf_cv_shlib_version" >&6
10458 cf_cv_rm_so_locs=no
10461 # Some less-capable ports of gcc support only -fpic
10465 if test "$GCC" = yes
10469 case $cf_cv_system_name in
10470 (*linux*) # e.g., PGI compiler
10476 if test "$cf_try_fPIC" = yes
10478 echo "$as_me:10478: checking which $CC option to use" >&5
10479 echo $ECHO_N "checking which $CC option to use... $ECHO_C" >&6
10480 cf_save_CFLAGS="$CFLAGS"
10481 for CC_SHARED_OPTS in -fPIC -fpic ''
10483 CFLAGS="$cf_save_CFLAGS $CC_SHARED_OPTS"
10484 cat >conftest.$ac_ext <<_ACEOF
10485 #line 10485 "configure"
10486 #include "confdefs.h"
10496 rm -f conftest.$ac_objext
10497 if { (eval echo "$as_me:10497: \"$ac_compile\"") >&5
10498 (eval $ac_compile) 2>&5
10500 echo "$as_me:10500: \$? = $ac_status" >&5
10501 (exit $ac_status); } &&
10502 { ac_try='test -s conftest.$ac_objext'
10503 { (eval echo "$as_me:10503: \"$ac_try\"") >&5
10504 (eval $ac_try) 2>&5
10506 echo "$as_me:10506: \$? = $ac_status" >&5
10507 (exit $ac_status); }; }; then
10510 echo "$as_me: failed program was:" >&5
10511 cat conftest.$ac_ext >&5
10513 rm -f conftest.$ac_objext conftest.$ac_ext
10515 echo "$as_me:10515: result: $CC_SHARED_OPTS" >&5
10516 echo "${ECHO_T}$CC_SHARED_OPTS" >&6
10517 CFLAGS="$cf_save_CFLAGS"
10520 cf_cv_shlib_version_infix=no
10522 case $cf_cv_system_name in
10523 (aix4.3-9*|aix[5-7]*)
10524 if test "$GCC" = yes; then
10525 CC_SHARED_OPTS='-Wl,-brtl'
10526 MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -shared -Wl,-brtl -Wl,-blibpath:${RPATH_LIST}:/usr/lib -o $@'
10528 CC_SHARED_OPTS='-brtl'
10529 # as well as '-qpic=large -G' or perhaps "-bM:SRE -bnoentry -bexpall"
10530 MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -G -Wl,-brtl -Wl,-blibpath:${RPATH_LIST}:/usr/lib -o $@'
10534 MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -o $@ -Xlinker -soname=`basename $@` -nostart -e 0'
10538 MK_SHARED_LIB=$SHELL' '$rel_builddir'/mk_shared_lib.sh $@ ${CC} ${CFLAGS}'
10539 RM_SHARED_OPTS="$RM_SHARED_OPTS $rel_builddir/mk_shared_lib.sh *.dll.a"
10540 cf_cv_shlib_version=cygdll
10541 cf_cv_shlib_version_infix=cygdll
10544 cat >mk_shared_lib.sh <<-CF_EOF
10547 IMPORT_LIB=\`echo "\$1" | sed -e 's/cyg/lib/' -e 's/[0-9]*\.dll$/.dll.a/'\`
10550 Linking shared library
10551 ** SHARED_LIB \$SHARED_LIB
10552 ** IMPORT_LIB \$IMPORT_LIB
10554 exec \$* ${LDFLAGS} -shared -Wl,--out-implib=\${IMPORT_LIB} -Wl,--export-all-symbols -o \${SHARED_LIB}
10556 chmod +x mk_shared_lib.sh
10560 MK_SHARED_LIB=$SHELL' '$rel_builddir'/mk_shared_lib.sh $@ ${CC} ${CFLAGS}'
10561 RM_SHARED_OPTS="$RM_SHARED_OPTS $rel_builddir/mk_shared_lib.sh *.dll.a"
10562 cf_cv_shlib_version=msysdll
10563 cf_cv_shlib_version_infix=msysdll
10566 cat >mk_shared_lib.sh <<-CF_EOF
10569 IMPORT_LIB=\`echo "\$1" | sed -e 's/msys-/lib/' -e 's/[0-9]*\.dll$/.dll.a/'\`
10572 Linking shared library
10573 ** SHARED_LIB \$SHARED_LIB
10574 ** IMPORT_LIB \$IMPORT_LIB
10576 exec \$* ${LDFLAGS} -shared -Wl,--out-implib=\${IMPORT_LIB} -Wl,--export-all-symbols -o \${SHARED_LIB}
10578 chmod +x mk_shared_lib.sh
10581 cf_try_cflags="no-cpp-precomp"
10582 CC_SHARED_OPTS="-dynamic"
10583 MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -dynamiclib -install_name ${libdir}/`basename $@` -compatibility_version ${ABI_VERSION} -current_version ${ABI_VERSION} -o $@'
10584 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=abi
10585 cf_cv_shlib_version_infix=yes
10586 echo "$as_me:10586: checking if ld -search_paths_first works" >&5
10587 echo $ECHO_N "checking if ld -search_paths_first works... $ECHO_C" >&6
10588 if test "${cf_cv_ldflags_search_paths_first+set}" = set; then
10589 echo $ECHO_N "(cached) $ECHO_C" >&6
10592 cf_save_LDFLAGS=$LDFLAGS
10593 LDFLAGS="$LDFLAGS -Wl,-search_paths_first"
10594 cat >conftest.$ac_ext <<_ACEOF
10595 #line 10595 "configure"
10596 #include "confdefs.h"
10606 rm -f conftest.$ac_objext conftest$ac_exeext
10607 if { (eval echo "$as_me:10607: \"$ac_link\"") >&5
10608 (eval $ac_link) 2>&5
10610 echo "$as_me:10610: \$? = $ac_status" >&5
10611 (exit $ac_status); } &&
10612 { ac_try='test -s conftest$ac_exeext'
10613 { (eval echo "$as_me:10613: \"$ac_try\"") >&5
10614 (eval $ac_try) 2>&5
10616 echo "$as_me:10616: \$? = $ac_status" >&5
10617 (exit $ac_status); }; }; then
10618 cf_cv_ldflags_search_paths_first=yes
10620 echo "$as_me: failed program was:" >&5
10621 cat conftest.$ac_ext >&5
10622 cf_cv_ldflags_search_paths_first=no
10624 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10625 LDFLAGS=$cf_save_LDFLAGS
10627 echo "$as_me:10627: result: $cf_cv_ldflags_search_paths_first" >&5
10628 echo "${ECHO_T}$cf_cv_ldflags_search_paths_first" >&6
10629 if test $cf_cv_ldflags_search_paths_first = yes; then
10630 LDFLAGS="$LDFLAGS -Wl,-search_paths_first"
10634 # HP-UX 8.07 ld lacks "+b" option used for libdir search-list
10635 if test "$GCC" != yes; then
10636 CC_SHARED_OPTS='+Z'
10638 MK_SHARED_LIB='${LD} ${LDFLAGS} -b -o $@'
10639 INSTALL_LIB="-m 555"
10642 # (tested with gcc 2.7.2 -- I don't have c89)
10643 if test "$GCC" = yes; then
10644 LD_SHARED_OPTS='-Xlinker +b -Xlinker ${libdir}'
10646 CC_SHARED_OPTS='+Z'
10647 LD_SHARED_OPTS='-Wl,+b,${libdir}'
10649 MK_SHARED_LIB='${LD} ${LDFLAGS} +b ${libdir} -b -o $@'
10650 # HP-UX shared libraries must be executable, and should be
10651 # readonly to exploit a quirk in the memory manager.
10652 INSTALL_LIB="-m 555"
10655 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
10656 if test "$cf_cv_shlib_version" = rel; then
10657 cf_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
10659 cf_shared_soname='`basename $@`'
10662 MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -shared -Wl,-rpath,${RPATH_LIST} -Wl,-h,'$cf_shared_soname' -o $@'
10665 if test "$cf_cv_enable_rpath" = yes ; then
10666 EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${RPATH_LIST} $EXTRA_LDFLAGS"
10668 # tested with IRIX 5.2 and 'cc'.
10669 if test "$GCC" != yes; then
10670 CC_SHARED_OPTS='-KPIC'
10671 MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -shared -rdata_shared -soname `basename $@` -o $@'
10673 MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -shared -Wl,-soname,`basename $@` -o $@'
10675 cf_cv_rm_so_locs=yes
10677 (linux*|gnu*|k*bsd*-gnu)
10678 if test "$DFT_LWR_MODEL" = "shared" && test -n "$LD_RPATH_OPT" ; then
10679 LOCAL_LDFLAGS="${LD_RPATH_OPT}\$(LOCAL_LIBDIR)"
10680 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
10682 if test "$cf_cv_enable_rpath" = yes ; then
10683 EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${RPATH_LIST} $EXTRA_LDFLAGS"
10686 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
10687 if test "$cf_cv_shlib_version" = rel; then
10688 cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
10690 cf_cv_shared_soname='`basename $@`'
10693 MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -shared -Wl,-soname,'$cf_cv_shared_soname',-stats,-lc -o $@'
10696 cf_cv_shlib_version=mingw
10697 cf_cv_shlib_version_infix=mingw
10700 if test "$DFT_LWR_MODEL" = "shared" ; then
10701 LOCAL_LDFLAGS="-Wl,--enable-auto-import"
10702 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
10703 EXTRA_LDFLAGS="-Wl,--enable-auto-import $EXTRA_LDFLAGS"
10706 MK_SHARED_LIB=$SHELL' '$rel_builddir'/mk_shared_lib.sh $@ ${CC} ${CFLAGS}'
10707 RM_SHARED_OPTS="$RM_SHARED_OPTS $rel_builddir/mk_shared_lib.sh *.dll.a"
10708 cat >mk_shared_lib.sh <<-CF_EOF
10711 IMPORT_LIB=\`echo "\$1" | sed -e 's/[0-9]*\.dll$/.dll.a/'\`
10714 Linking shared library
10715 ** SHARED_LIB \$SHARED_LIB
10716 ** IMPORT_LIB \$IMPORT_LIB
10718 exec \$* ${LDFLAGS} -shared -Wl,--enable-auto-import,--out-implib=\${IMPORT_LIB} -Wl,--export-all-symbols -o \${SHARED_LIB}
10720 chmod +x mk_shared_lib.sh
10722 (openbsd[2-9].*|mirbsd*)
10723 if test "$DFT_LWR_MODEL" = "shared" && test -n "$LD_RPATH_OPT" ; then
10724 LOCAL_LDFLAGS="${LD_RPATH_OPT}\$(LOCAL_LIBDIR)"
10725 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
10727 if test "$cf_cv_enable_rpath" = yes ; then
10728 EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${RPATH_LIST} $EXTRA_LDFLAGS"
10730 CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC"
10732 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
10733 if test "$cf_cv_shlib_version" = rel; then
10734 cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
10736 cf_cv_shared_soname='`basename $@`'
10739 MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -shared -Wl,-Bshareable,-soname,'$cf_cv_shared_soname',-stats,-lc -o $@'
10741 (nto-qnx*|openbsd*|freebsd[12].*)
10742 CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC"
10743 MK_SHARED_LIB='${LD} ${LDFLAGS} -Bshareable -o $@'
10744 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
10746 (dragonfly*|freebsd*)
10747 CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC"
10748 if test "$DFT_LWR_MODEL" = "shared" && test "$cf_cv_enable_rpath" = yes ; then
10749 LOCAL_LDFLAGS="${cf_ld_rpath_opt}\$(LOCAL_LIBDIR)"
10750 LOCAL_LDFLAGS2="${cf_ld_rpath_opt}\${RPATH_LIST} $LOCAL_LDFLAGS"
10751 EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${RPATH_LIST} $EXTRA_LDFLAGS"
10754 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
10755 if test "$cf_cv_shlib_version" = rel; then
10756 cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
10758 cf_cv_shared_soname='`basename $@`'
10761 MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -shared -Wl,-soname,'$cf_cv_shared_soname',-stats,-lc -o $@'
10764 CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC"
10765 if test "$DFT_LWR_MODEL" = "shared" && test "$cf_cv_enable_rpath" = yes ; then
10766 LOCAL_LDFLAGS="${cf_ld_rpath_opt}\$(LOCAL_LIBDIR)"
10767 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
10768 EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${RPATH_LIST} $EXTRA_LDFLAGS"
10769 if test "$cf_cv_shlib_version" = auto; then
10770 if test -f /usr/libexec/ld.elf_so; then
10771 cf_cv_shlib_version=abi
10773 cf_cv_shlib_version=rel
10777 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
10778 if test "$cf_cv_shlib_version" = rel; then
10779 cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
10781 cf_cv_shared_soname='`basename $@`'
10784 MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -shared -Wl,-soname,'$cf_cv_shared_soname' -o $@'
10786 MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -Wl,-shared -Wl,-Bshareable -o $@'
10790 # tested with OSF/1 V3.2 and 'cc'
10791 # tested with OSF/1 V3.2 and gcc 2.6.3 (but the c++ demo didn't
10792 # link with shared libs).
10793 MK_SHARED_LIB='${LD} ${LDFLAGS} -set_version ${REL_VERSION}:${ABI_VERSION} -expect_unresolved "*" -shared -soname `basename $@`'
10796 MK_SHARED_LIB="${MK_SHARED_LIB} -msym"
10799 MK_SHARED_LIB="${MK_SHARED_LIB}"' -o $@'
10800 if test "$DFT_LWR_MODEL" = "shared" && test -n "$LD_RPATH_OPT" ; then
10801 LOCAL_LDFLAGS="${LD_RPATH_OPT}\$(LOCAL_LIBDIR)"
10802 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
10804 cf_cv_rm_so_locs=yes
10806 (sco3.2v5*) # also uw2* and UW7: hops 13-Apr-98
10807 # tested with osr5.0.5
10808 if test "$GCC" != yes; then
10809 CC_SHARED_OPTS='-belf -KPIC'
10811 MK_SHARED_LIB='${LD} ${LDFLAGS} -dy -G -h `basename $@ .${REL_VERSION}`.${ABI_VERSION} -o $@'
10812 if test "$cf_cv_enable_rpath" = yes ; then
10813 # only way is to set LD_RUN_PATH but no switch for it
10816 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
10817 LINK_PROGS='LD_RUN_PATH=${libdir}'
10818 LINK_TESTS='Pwd=`pwd`;LD_RUN_PATH=`dirname $${Pwd}`/lib'
10821 # tested with SunOS 4.1.1 and gcc 2.7.0
10822 if test "$GCC" != yes; then
10823 CC_SHARED_OPTS='-KPIC'
10825 MK_SHARED_LIB='${LD} ${LDFLAGS} -assert pure-text -o $@'
10826 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
10829 # tested with SunOS 5.5.1 (solaris 2.5.1) and gcc 2.7.2
10830 # tested with SunOS 5.10 (solaris 10) and gcc 3.4.3
10831 if test "$DFT_LWR_MODEL" = "shared" ; then
10832 LOCAL_LDFLAGS="-R \$(LOCAL_LIBDIR):\${libdir}"
10833 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
10835 if test "$cf_cv_enable_rpath" = yes ; then
10836 EXTRA_LDFLAGS="-R \${libdir} $EXTRA_LDFLAGS"
10839 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
10840 if test "$cf_cv_shlib_version" = rel; then
10841 cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
10843 cf_cv_shared_soname='`basename $@`'
10846 if test "$GCC" != yes; then
10847 cf_save_CFLAGS="$CFLAGS"
10848 for cf_shared_opts in -xcode=pic32 -xcode=pic13 -KPIC -Kpic -O
10850 CFLAGS="$cf_shared_opts $cf_save_CFLAGS"
10851 cat >conftest.$ac_ext <<_ACEOF
10852 #line 10852 "configure"
10853 #include "confdefs.h"
10863 rm -f conftest.$ac_objext
10864 if { (eval echo "$as_me:10864: \"$ac_compile\"") >&5
10865 (eval $ac_compile) 2>&5
10867 echo "$as_me:10867: \$? = $ac_status" >&5
10868 (exit $ac_status); } &&
10869 { ac_try='test -s conftest.$ac_objext'
10870 { (eval echo "$as_me:10870: \"$ac_try\"") >&5
10871 (eval $ac_try) 2>&5
10873 echo "$as_me:10873: \$? = $ac_status" >&5
10874 (exit $ac_status); }; }; then
10877 echo "$as_me: failed program was:" >&5
10878 cat conftest.$ac_ext >&5
10880 rm -f conftest.$ac_objext conftest.$ac_ext
10882 CFLAGS="$cf_save_CFLAGS"
10883 CC_SHARED_OPTS=$cf_shared_opts
10884 MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -dy -G -h '$cf_cv_shared_soname' -o $@'
10886 MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -shared -dy -G -h '$cf_cv_shared_soname' -o $@'
10889 (sysv5uw7*|unix_sv*)
10890 # tested with UnixWare 7.1.0 (gcc 2.95.2 and cc)
10891 if test "$GCC" != yes; then
10892 CC_SHARED_OPTS='-KPIC'
10894 MK_SHARED_LIB='${LD} ${LDFLAGS} -d y -G -o $@'
10897 CC_SHARED_OPTS='unknown'
10898 MK_SHARED_LIB='echo unknown'
10902 # This works if the last tokens in $MK_SHARED_LIB are the -o target.
10903 case "$cf_cv_shlib_version" in
10905 case "$MK_SHARED_LIB" in
10907 test "$cf_cv_do_symlinks" = no && cf_cv_do_symlinks=yes
10910 { echo "$as_me:10910: WARNING: ignored --with-shlib-version" >&5
10911 echo "$as_me: WARNING: ignored --with-shlib-version" >&2;}
10917 if test -n "$cf_try_cflags"
10919 cat > conftest.$ac_ext <<EOF
10920 #line 10920 "${as_me:-configure}"
10922 int main(int argc, char *argv[])
10925 return (argv[argc-1] == 0) ;
10928 cf_save_CFLAGS="$CFLAGS"
10929 for cf_opt in $cf_try_cflags
10931 CFLAGS="$cf_save_CFLAGS -$cf_opt"
10932 echo "$as_me:10932: checking if CFLAGS option -$cf_opt works" >&5
10933 echo $ECHO_N "checking if CFLAGS option -$cf_opt works... $ECHO_C" >&6
10934 if { (eval echo "$as_me:10934: \"$ac_compile\"") >&5
10935 (eval $ac_compile) 2>&5
10937 echo "$as_me:10937: \$? = $ac_status" >&5
10938 (exit $ac_status); }; then
10939 echo "$as_me:10939: result: yes" >&5
10940 echo "${ECHO_T}yes" >&6
10941 cf_save_CFLAGS="$CFLAGS"
10943 echo "$as_me:10943: result: no" >&5
10944 echo "${ECHO_T}no" >&6
10947 CFLAGS="$cf_save_CFLAGS"
10950 # RPATH_LIST is a colon-separated list of directories
10951 test -n "$cf_ld_rpath_opt" && MK_SHARED_LIB="$MK_SHARED_LIB $cf_ld_rpath_opt\${RPATH_LIST}"
10952 test -z "$RPATH_LIST" && RPATH_LIST="\${libdir}"
10954 test $cf_cv_rm_so_locs = yes && RM_SHARED_OPTS="$RM_SHARED_OPTS so_locations"
10956 test -n "$verbose" && echo " CC_SHARED_OPTS: $CC_SHARED_OPTS" 1>&6
10958 echo "${as_me:-configure}:10958: testing CC_SHARED_OPTS: $CC_SHARED_OPTS ..." 1>&5
10960 test -n "$verbose" && echo " MK_SHARED_LIB: $MK_SHARED_LIB" 1>&6
10962 echo "${as_me:-configure}:10962: testing MK_SHARED_LIB: $MK_SHARED_LIB ..." 1>&5
10964 # The test/sample programs in the original tree link using rpath option.
10965 # Make it optional for packagers.
10966 if test -n "$LOCAL_LDFLAGS"
10968 echo "$as_me:10968: checking if you want to link sample programs with rpath option" >&5
10969 echo $ECHO_N "checking if you want to link sample programs with rpath option... $ECHO_C" >&6
10971 # Check whether --enable-rpath-link or --disable-rpath-link was given.
10972 if test "${enable_rpath_link+set}" = set; then
10973 enableval="$enable_rpath_link"
10974 with_rpath_link=$enableval
10976 with_rpath_link=yes
10978 echo "$as_me:10978: result: $with_rpath_link" >&5
10979 echo "${ECHO_T}$with_rpath_link" >&6
10980 if test "$with_rpath_link" = no
10987 ###############################################################################
10989 ### use option --enable-broken-linker to force on use of broken-linker support
10990 echo "$as_me:10990: checking if you want broken-linker support code" >&5
10991 echo $ECHO_N "checking if you want broken-linker support code... $ECHO_C" >&6
10993 # Check whether --enable-broken_linker or --disable-broken_linker was given.
10994 if test "${enable_broken_linker+set}" = set; then
10995 enableval="$enable_broken_linker"
10996 with_broken_linker=$enableval
10998 with_broken_linker=${BROKEN_LINKER:-no}
11000 echo "$as_me:11000: result: $with_broken_linker" >&5
11001 echo "${ECHO_T}$with_broken_linker" >&6
11004 if test "$with_broken_linker" = yes ; then
11005 cat >>confdefs.h <<\EOF
11006 #define BROKEN_LINKER 1
11010 elif test "$DFT_LWR_MODEL" = shared ; then
11011 case $cf_cv_system_name in
11013 cat >>confdefs.h <<\EOF
11014 #define BROKEN_LINKER 1
11018 test -n "$verbose" && echo " cygwin linker is broken anyway" 1>&6
11020 echo "${as_me:-configure}:11020: testing cygwin linker is broken anyway ..." 1>&5
11026 # Check to define _XOPEN_SOURCE "automatically"
11028 echo "$as_me:11028: checking if the POSIX test-macros are already defined" >&5
11029 echo $ECHO_N "checking if the POSIX test-macros are already defined... $ECHO_C" >&6
11030 if test "${cf_cv_posix_visible+set}" = set; then
11031 echo $ECHO_N "(cached) $ECHO_C" >&6
11034 cat >conftest.$ac_ext <<_ACEOF
11035 #line 11035 "configure"
11036 #include "confdefs.h"
11042 #if defined(__POSIX_VISIBLE) && ((__POSIX_VISIBLE - 0L) > 0) \
11043 && defined(__XSI_VISIBLE) && ((__XSI_VISIBLE - 0L) > 0) \
11044 && defined(__BSD_VISIBLE) && ((__BSD_VISIBLE - 0L) > 0) \
11045 && defined(__ISO_C_VISIBLE) && ((__ISO_C_VISIBLE - 0L) > 0)
11046 #error conflicting symbols found
11053 rm -f conftest.$ac_objext
11054 if { (eval echo "$as_me:11054: \"$ac_compile\"") >&5
11055 (eval $ac_compile) 2>&5
11057 echo "$as_me:11057: \$? = $ac_status" >&5
11058 (exit $ac_status); } &&
11059 { ac_try='test -s conftest.$ac_objext'
11060 { (eval echo "$as_me:11060: \"$ac_try\"") >&5
11061 (eval $ac_try) 2>&5
11063 echo "$as_me:11063: \$? = $ac_status" >&5
11064 (exit $ac_status); }; }; then
11065 cf_cv_posix_visible=no
11067 echo "$as_me: failed program was:" >&5
11068 cat conftest.$ac_ext >&5
11069 cf_cv_posix_visible=yes
11071 rm -f conftest.$ac_objext conftest.$ac_ext
11074 echo "$as_me:11074: result: $cf_cv_posix_visible" >&5
11075 echo "${ECHO_T}$cf_cv_posix_visible" >&6
11077 if test "$cf_cv_posix_visible" = no; then
11079 cf_XOPEN_SOURCE=600
11080 cf_POSIX_C_SOURCE=199506L
11085 cf_xopen_source="-D_ALL_SOURCE"
11088 cf_XOPEN_SOURCE=600
11091 cf_xopen_source="-D_APPLE_C_SOURCE"
11094 cf_xopen_source="-D_DARWIN_C_SOURCE"
11097 (freebsd*|dragonfly*|midnightbsd*)
11098 # 5.x headers associate
11099 # _XOPEN_SOURCE=600 with _POSIX_C_SOURCE=200112L
11100 # _XOPEN_SOURCE=500 with _POSIX_C_SOURCE=199506L
11101 cf_POSIX_C_SOURCE=200112L
11102 cf_XOPEN_SOURCE=600
11103 cf_xopen_source="-D_BSD_TYPES -D__BSD_VISIBLE -D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
11106 cf_xopen_source="-D_HPUX_SOURCE -D_XOPEN_SOURCE=500"
11109 cf_xopen_source="-D_HPUX_SOURCE"
11112 cf_xopen_source="-D_SGI_SOURCE"
11115 (linux*|uclinux*|gnu*|mint*|k*bsd*-gnu|cygwin)
11117 cf_gnu_xopen_source=$cf_XOPEN_SOURCE
11119 echo "$as_me:11119: checking if this is the GNU C library" >&5
11120 echo $ECHO_N "checking if this is the GNU C library... $ECHO_C" >&6
11121 if test "${cf_cv_gnu_library+set}" = set; then
11122 echo $ECHO_N "(cached) $ECHO_C" >&6
11125 cat >conftest.$ac_ext <<_ACEOF
11126 #line 11126 "configure"
11127 #include "confdefs.h"
11128 #include <sys/types.h>
11133 #if __GLIBC__ > 0 && __GLIBC_MINOR__ >= 0
11135 #elif __NEWLIB__ > 0 && __NEWLIB_MINOR__ >= 0
11138 # error not GNU C library
11144 rm -f conftest.$ac_objext
11145 if { (eval echo "$as_me:11145: \"$ac_compile\"") >&5
11146 (eval $ac_compile) 2>&5
11148 echo "$as_me:11148: \$? = $ac_status" >&5
11149 (exit $ac_status); } &&
11150 { ac_try='test -s conftest.$ac_objext'
11151 { (eval echo "$as_me:11151: \"$ac_try\"") >&5
11152 (eval $ac_try) 2>&5
11154 echo "$as_me:11154: \$? = $ac_status" >&5
11155 (exit $ac_status); }; }; then
11156 cf_cv_gnu_library=yes
11158 echo "$as_me: failed program was:" >&5
11159 cat conftest.$ac_ext >&5
11160 cf_cv_gnu_library=no
11162 rm -f conftest.$ac_objext conftest.$ac_ext
11165 echo "$as_me:11165: result: $cf_cv_gnu_library" >&5
11166 echo "${ECHO_T}$cf_cv_gnu_library" >&6
11168 if test x$cf_cv_gnu_library = xyes; then
11170 # With glibc 2.19 (13 years after this check was begun), _DEFAULT_SOURCE
11171 # was changed to help a little. newlib incorporated the change about 4
11173 echo "$as_me:11173: checking if _DEFAULT_SOURCE can be used as a basis" >&5
11174 echo $ECHO_N "checking if _DEFAULT_SOURCE can be used as a basis... $ECHO_C" >&6
11175 if test "${cf_cv_gnu_library_219+set}" = set; then
11176 echo $ECHO_N "(cached) $ECHO_C" >&6
11179 cf_save="$CPPFLAGS"
11181 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
11182 CPPFLAGS="${CPPFLAGS}-D_DEFAULT_SOURCE"
11184 cat >conftest.$ac_ext <<_ACEOF
11185 #line 11185 "configure"
11186 #include "confdefs.h"
11187 #include <sys/types.h>
11192 #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 19) || (__GLIBC__ > 2)
11194 #elif (__NEWLIB__ == 2 && __NEWLIB_MINOR__ >= 4) || (__GLIBC__ > 3)
11197 # error GNU C library __GLIBC__.__GLIBC_MINOR__ is too old
11203 rm -f conftest.$ac_objext
11204 if { (eval echo "$as_me:11204: \"$ac_compile\"") >&5
11205 (eval $ac_compile) 2>&5
11207 echo "$as_me:11207: \$? = $ac_status" >&5
11208 (exit $ac_status); } &&
11209 { ac_try='test -s conftest.$ac_objext'
11210 { (eval echo "$as_me:11210: \"$ac_try\"") >&5
11211 (eval $ac_try) 2>&5
11213 echo "$as_me:11213: \$? = $ac_status" >&5
11214 (exit $ac_status); }; }; then
11215 cf_cv_gnu_library_219=yes
11217 echo "$as_me: failed program was:" >&5
11218 cat conftest.$ac_ext >&5
11219 cf_cv_gnu_library_219=no
11221 rm -f conftest.$ac_objext conftest.$ac_ext
11222 CPPFLAGS="$cf_save"
11225 echo "$as_me:11225: result: $cf_cv_gnu_library_219" >&5
11226 echo "${ECHO_T}$cf_cv_gnu_library_219" >&6
11228 if test "x$cf_cv_gnu_library_219" = xyes; then
11229 cf_save="$CPPFLAGS"
11230 echo "$as_me:11230: checking if _XOPEN_SOURCE=$cf_gnu_xopen_source works with _DEFAULT_SOURCE" >&5
11231 echo $ECHO_N "checking if _XOPEN_SOURCE=$cf_gnu_xopen_source works with _DEFAULT_SOURCE... $ECHO_C" >&6
11232 if test "${cf_cv_gnu_dftsrc_219+set}" = set; then
11233 echo $ECHO_N "(cached) $ECHO_C" >&6
11239 cf_new_extra_cppflags=
11241 for cf_add_cflags in -D_DEFAULT_SOURCE -D_XOPEN_SOURCE=$cf_gnu_xopen_source
11243 case $cf_fix_cppflags in
11245 case $cf_add_cflags in
11246 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
11247 case $cf_add_cflags in
11249 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11251 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
11252 && test -z "${cf_tst_cflags}" \
11253 && cf_fix_cppflags=yes
11255 if test $cf_fix_cppflags = yes ; then
11257 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11258 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11261 elif test "${cf_tst_cflags}" = "\"'" ; then
11263 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11264 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11270 case "$CPPFLAGS" in
11274 case $cf_add_cflags in
11276 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11278 CPPFLAGS=`echo "$CPPFLAGS" | \
11279 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11280 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11285 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
11286 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
11293 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
11294 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
11301 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11302 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11304 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11306 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
11307 && test -z "${cf_tst_cflags}" \
11308 && cf_fix_cppflags=no
11313 if test -n "$cf_new_cflags" ; then
11315 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
11316 CFLAGS="${CFLAGS}$cf_new_cflags"
11320 if test -n "$cf_new_cppflags" ; then
11322 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
11323 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
11327 if test -n "$cf_new_extra_cppflags" ; then
11329 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
11330 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
11334 cat >conftest.$ac_ext <<_ACEOF
11335 #line 11335 "configure"
11336 #include "confdefs.h"
11338 #include <limits.h>
11339 #include <sys/types.h>
11345 #if (_XOPEN_SOURCE >= $cf_gnu_xopen_source) && (MB_LEN_MAX > 1)
11348 # error GNU C library is too old
11354 rm -f conftest.$ac_objext
11355 if { (eval echo "$as_me:11355: \"$ac_compile\"") >&5
11356 (eval $ac_compile) 2>&5
11358 echo "$as_me:11358: \$? = $ac_status" >&5
11359 (exit $ac_status); } &&
11360 { ac_try='test -s conftest.$ac_objext'
11361 { (eval echo "$as_me:11361: \"$ac_try\"") >&5
11362 (eval $ac_try) 2>&5
11364 echo "$as_me:11364: \$? = $ac_status" >&5
11365 (exit $ac_status); }; }; then
11366 cf_cv_gnu_dftsrc_219=yes
11368 echo "$as_me: failed program was:" >&5
11369 cat conftest.$ac_ext >&5
11370 cf_cv_gnu_dftsrc_219=no
11372 rm -f conftest.$ac_objext conftest.$ac_ext
11375 echo "$as_me:11375: result: $cf_cv_gnu_dftsrc_219" >&5
11376 echo "${ECHO_T}$cf_cv_gnu_dftsrc_219" >&6
11377 test "x$cf_cv_gnu_dftsrc_219" = "xyes" || CPPFLAGS="$cf_save"
11379 cf_cv_gnu_dftsrc_219=maybe
11382 if test "x$cf_cv_gnu_dftsrc_219" != xyes; then
11384 echo "$as_me:11384: checking if we must define _GNU_SOURCE" >&5
11385 echo $ECHO_N "checking if we must define _GNU_SOURCE... $ECHO_C" >&6
11386 if test "${cf_cv_gnu_source+set}" = set; then
11387 echo $ECHO_N "(cached) $ECHO_C" >&6
11390 cat >conftest.$ac_ext <<_ACEOF
11391 #line 11391 "configure"
11392 #include "confdefs.h"
11393 #include <sys/types.h>
11398 #ifndef _XOPEN_SOURCE
11399 #error expected _XOPEN_SOURCE to be defined
11405 rm -f conftest.$ac_objext
11406 if { (eval echo "$as_me:11406: \"$ac_compile\"") >&5
11407 (eval $ac_compile) 2>&5
11409 echo "$as_me:11409: \$? = $ac_status" >&5
11410 (exit $ac_status); } &&
11411 { ac_try='test -s conftest.$ac_objext'
11412 { (eval echo "$as_me:11412: \"$ac_try\"") >&5
11413 (eval $ac_try) 2>&5
11415 echo "$as_me:11415: \$? = $ac_status" >&5
11416 (exit $ac_status); }; }; then
11417 cf_cv_gnu_source=no
11419 echo "$as_me: failed program was:" >&5
11420 cat conftest.$ac_ext >&5
11421 cf_save="$CPPFLAGS"
11426 cf_new_extra_cppflags=
11428 for cf_add_cflags in -D_GNU_SOURCE
11430 case $cf_fix_cppflags in
11432 case $cf_add_cflags in
11433 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
11434 case $cf_add_cflags in
11436 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11438 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
11439 && test -z "${cf_tst_cflags}" \
11440 && cf_fix_cppflags=yes
11442 if test $cf_fix_cppflags = yes ; then
11444 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11445 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11448 elif test "${cf_tst_cflags}" = "\"'" ; then
11450 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11451 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11457 case "$CPPFLAGS" in
11461 case $cf_add_cflags in
11463 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11465 CPPFLAGS=`echo "$CPPFLAGS" | \
11466 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11467 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11472 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
11473 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
11480 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
11481 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
11488 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11489 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11491 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11493 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
11494 && test -z "${cf_tst_cflags}" \
11495 && cf_fix_cppflags=no
11500 if test -n "$cf_new_cflags" ; then
11502 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
11503 CFLAGS="${CFLAGS}$cf_new_cflags"
11507 if test -n "$cf_new_cppflags" ; then
11509 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
11510 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
11514 if test -n "$cf_new_extra_cppflags" ; then
11516 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
11517 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
11521 cat >conftest.$ac_ext <<_ACEOF
11522 #line 11522 "configure"
11523 #include "confdefs.h"
11524 #include <sys/types.h>
11529 #ifdef _XOPEN_SOURCE
11530 #error expected _XOPEN_SOURCE to be undefined
11536 rm -f conftest.$ac_objext
11537 if { (eval echo "$as_me:11537: \"$ac_compile\"") >&5
11538 (eval $ac_compile) 2>&5
11540 echo "$as_me:11540: \$? = $ac_status" >&5
11541 (exit $ac_status); } &&
11542 { ac_try='test -s conftest.$ac_objext'
11543 { (eval echo "$as_me:11543: \"$ac_try\"") >&5
11544 (eval $ac_try) 2>&5
11546 echo "$as_me:11546: \$? = $ac_status" >&5
11547 (exit $ac_status); }; }; then
11548 cf_cv_gnu_source=no
11550 echo "$as_me: failed program was:" >&5
11551 cat conftest.$ac_ext >&5
11552 cf_cv_gnu_source=yes
11554 rm -f conftest.$ac_objext conftest.$ac_ext
11555 CPPFLAGS="$cf_save"
11558 rm -f conftest.$ac_objext conftest.$ac_ext
11561 echo "$as_me:11561: result: $cf_cv_gnu_source" >&5
11562 echo "${ECHO_T}$cf_cv_gnu_source" >&6
11564 if test "$cf_cv_gnu_source" = yes
11566 echo "$as_me:11566: checking if we should also define _DEFAULT_SOURCE" >&5
11567 echo $ECHO_N "checking if we should also define _DEFAULT_SOURCE... $ECHO_C" >&6
11568 if test "${cf_cv_default_source+set}" = set; then
11569 echo $ECHO_N "(cached) $ECHO_C" >&6
11572 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
11573 CPPFLAGS="${CPPFLAGS}-D_GNU_SOURCE"
11575 cat >conftest.$ac_ext <<_ACEOF
11576 #line 11576 "configure"
11577 #include "confdefs.h"
11578 #include <sys/types.h>
11583 #ifdef _DEFAULT_SOURCE
11584 #error expected _DEFAULT_SOURCE to be undefined
11590 rm -f conftest.$ac_objext
11591 if { (eval echo "$as_me:11591: \"$ac_compile\"") >&5
11592 (eval $ac_compile) 2>&5
11594 echo "$as_me:11594: \$? = $ac_status" >&5
11595 (exit $ac_status); } &&
11596 { ac_try='test -s conftest.$ac_objext'
11597 { (eval echo "$as_me:11597: \"$ac_try\"") >&5
11598 (eval $ac_try) 2>&5
11600 echo "$as_me:11600: \$? = $ac_status" >&5
11601 (exit $ac_status); }; }; then
11602 cf_cv_default_source=no
11604 echo "$as_me: failed program was:" >&5
11605 cat conftest.$ac_ext >&5
11606 cf_cv_default_source=yes
11608 rm -f conftest.$ac_objext conftest.$ac_ext
11611 echo "$as_me:11611: result: $cf_cv_default_source" >&5
11612 echo "${ECHO_T}$cf_cv_default_source" >&6
11613 if test "$cf_cv_default_source" = yes
11616 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
11617 CPPFLAGS="${CPPFLAGS}-D_DEFAULT_SOURCE"
11627 cf_xopen_source="-D_NETBSD_SOURCE" # POSIX.1-2001 features are ifdef'd with this...
11630 # setting _XOPEN_SOURCE or _POSIX_SOURCE breaks <sys/select.h> and other headers which use u_int / u_short types
11633 if test "$cf_cv_posix_visible" = no; then
11635 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
11637 cf_save_CFLAGS="$CFLAGS"
11638 cf_save_CPPFLAGS="$CPPFLAGS"
11640 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
11641 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
11642 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
11644 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
11645 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
11646 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
11648 echo "$as_me:11648: checking if we should define _POSIX_C_SOURCE" >&5
11649 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
11650 if test "${cf_cv_posix_c_source+set}" = set; then
11651 echo $ECHO_N "(cached) $ECHO_C" >&6
11654 echo "${as_me:-configure}:11654: testing if the symbol is already defined go no further ..." 1>&5
11656 cat >conftest.$ac_ext <<_ACEOF
11657 #line 11657 "configure"
11658 #include "confdefs.h"
11659 #include <sys/types.h>
11664 #ifndef _POSIX_C_SOURCE
11671 rm -f conftest.$ac_objext
11672 if { (eval echo "$as_me:11672: \"$ac_compile\"") >&5
11673 (eval $ac_compile) 2>&5
11675 echo "$as_me:11675: \$? = $ac_status" >&5
11676 (exit $ac_status); } &&
11677 { ac_try='test -s conftest.$ac_objext'
11678 { (eval echo "$as_me:11678: \"$ac_try\"") >&5
11679 (eval $ac_try) 2>&5
11681 echo "$as_me:11681: \$? = $ac_status" >&5
11682 (exit $ac_status); }; }; then
11683 cf_cv_posix_c_source=no
11685 echo "$as_me: failed program was:" >&5
11686 cat conftest.$ac_ext >&5
11687 cf_want_posix_source=no
11688 case .$cf_POSIX_C_SOURCE in
11690 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
11693 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
11694 cf_want_posix_source=yes
11697 cf_want_posix_source=yes
11700 if test "$cf_want_posix_source" = yes ; then
11701 cat >conftest.$ac_ext <<_ACEOF
11702 #line 11702 "configure"
11703 #include "confdefs.h"
11704 #include <sys/types.h>
11709 #ifdef _POSIX_SOURCE
11716 rm -f conftest.$ac_objext
11717 if { (eval echo "$as_me:11717: \"$ac_compile\"") >&5
11718 (eval $ac_compile) 2>&5
11720 echo "$as_me:11720: \$? = $ac_status" >&5
11721 (exit $ac_status); } &&
11722 { ac_try='test -s conftest.$ac_objext'
11723 { (eval echo "$as_me:11723: \"$ac_try\"") >&5
11724 (eval $ac_try) 2>&5
11726 echo "$as_me:11726: \$? = $ac_status" >&5
11727 (exit $ac_status); }; }; then
11730 echo "$as_me: failed program was:" >&5
11731 cat conftest.$ac_ext >&5
11732 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
11734 rm -f conftest.$ac_objext conftest.$ac_ext
11737 echo "${as_me:-configure}:11737: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
11739 CFLAGS="$cf_trim_CFLAGS"
11740 CPPFLAGS="$cf_trim_CPPFLAGS"
11742 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
11743 CPPFLAGS="${CPPFLAGS}$cf_cv_posix_c_source"
11745 echo "${as_me:-configure}:11745: testing if the second compile does not leave our definition intact error ..." 1>&5
11747 cat >conftest.$ac_ext <<_ACEOF
11748 #line 11748 "configure"
11749 #include "confdefs.h"
11750 #include <sys/types.h>
11755 #ifndef _POSIX_C_SOURCE
11762 rm -f conftest.$ac_objext
11763 if { (eval echo "$as_me:11763: \"$ac_compile\"") >&5
11764 (eval $ac_compile) 2>&5
11766 echo "$as_me:11766: \$? = $ac_status" >&5
11767 (exit $ac_status); } &&
11768 { ac_try='test -s conftest.$ac_objext'
11769 { (eval echo "$as_me:11769: \"$ac_try\"") >&5
11770 (eval $ac_try) 2>&5
11772 echo "$as_me:11772: \$? = $ac_status" >&5
11773 (exit $ac_status); }; }; then
11776 echo "$as_me: failed program was:" >&5
11777 cat conftest.$ac_ext >&5
11778 cf_cv_posix_c_source=no
11780 rm -f conftest.$ac_objext conftest.$ac_ext
11781 CFLAGS="$cf_save_CFLAGS"
11782 CPPFLAGS="$cf_save_CPPFLAGS"
11785 rm -f conftest.$ac_objext conftest.$ac_ext
11788 echo "$as_me:11788: result: $cf_cv_posix_c_source" >&5
11789 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
11791 if test "$cf_cv_posix_c_source" != no ; then
11792 CFLAGS="$cf_trim_CFLAGS"
11793 CPPFLAGS="$cf_trim_CPPFLAGS"
11798 cf_new_extra_cppflags=
11800 for cf_add_cflags in $cf_cv_posix_c_source
11802 case $cf_fix_cppflags in
11804 case $cf_add_cflags in
11805 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
11806 case $cf_add_cflags in
11808 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11810 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
11811 && test -z "${cf_tst_cflags}" \
11812 && cf_fix_cppflags=yes
11814 if test $cf_fix_cppflags = yes ; then
11816 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11817 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11820 elif test "${cf_tst_cflags}" = "\"'" ; then
11822 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11823 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11829 case "$CPPFLAGS" in
11833 case $cf_add_cflags in
11835 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11837 CPPFLAGS=`echo "$CPPFLAGS" | \
11838 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11839 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11844 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
11845 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
11852 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
11853 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
11860 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11861 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11863 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11865 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
11866 && test -z "${cf_tst_cflags}" \
11867 && cf_fix_cppflags=no
11872 if test -n "$cf_new_cflags" ; then
11874 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
11875 CFLAGS="${CFLAGS}$cf_new_cflags"
11879 if test -n "$cf_new_cppflags" ; then
11881 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
11882 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
11886 if test -n "$cf_new_extra_cppflags" ; then
11888 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
11889 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
11895 fi # cf_cv_posix_visible
11899 cf_xopen_source="-D_NETBSD_SOURCE" # setting _XOPEN_SOURCE breaks IPv6 for lynx on NetBSD 1.6, breaks xterm, is not needed for ncursesw
11902 # setting _XOPEN_SOURCE lower than 500 breaks g++ compile with wchar.h, needed for ncursesw
11903 cf_xopen_source="-D_BSD_SOURCE"
11904 cf_XOPEN_SOURCE=600
11907 # setting _XOPEN_SOURCE breaks xterm on OpenBSD 2.8, is not needed for ncursesw
11910 cf_xopen_source="-D_OSF_SOURCE"
11913 cf_xopen_source="-D_QNX_SOURCE"
11916 # setting _XOPEN_SOURCE breaks Lynx on SCO Unix / OpenServer
11919 cf_xopen_source="-D__EXTENSIONS__"
11920 cf_cv_xopen_source=broken
11922 (sysv4.2uw2.*) # Novell/SCO UnixWare 2.x (tested on 2.1.2)
11928 echo "$as_me:11928: checking if we should define _XOPEN_SOURCE" >&5
11929 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
11930 if test "${cf_cv_xopen_source+set}" = set; then
11931 echo $ECHO_N "(cached) $ECHO_C" >&6
11934 cat >conftest.$ac_ext <<_ACEOF
11935 #line 11935 "configure"
11936 #include "confdefs.h"
11938 #include <stdlib.h>
11939 #include <string.h>
11940 #include <sys/types.h>
11946 #ifndef _XOPEN_SOURCE
11953 rm -f conftest.$ac_objext
11954 if { (eval echo "$as_me:11954: \"$ac_compile\"") >&5
11955 (eval $ac_compile) 2>&5
11957 echo "$as_me:11957: \$? = $ac_status" >&5
11958 (exit $ac_status); } &&
11959 { ac_try='test -s conftest.$ac_objext'
11960 { (eval echo "$as_me:11960: \"$ac_try\"") >&5
11961 (eval $ac_try) 2>&5
11963 echo "$as_me:11963: \$? = $ac_status" >&5
11964 (exit $ac_status); }; }; then
11965 cf_cv_xopen_source=no
11967 echo "$as_me: failed program was:" >&5
11968 cat conftest.$ac_ext >&5
11969 cf_save="$CPPFLAGS"
11971 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
11972 CPPFLAGS="${CPPFLAGS}-D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
11974 cat >conftest.$ac_ext <<_ACEOF
11975 #line 11975 "configure"
11976 #include "confdefs.h"
11978 #include <stdlib.h>
11979 #include <string.h>
11980 #include <sys/types.h>
11986 #ifdef _XOPEN_SOURCE
11993 rm -f conftest.$ac_objext
11994 if { (eval echo "$as_me:11994: \"$ac_compile\"") >&5
11995 (eval $ac_compile) 2>&5
11997 echo "$as_me:11997: \$? = $ac_status" >&5
11998 (exit $ac_status); } &&
11999 { ac_try='test -s conftest.$ac_objext'
12000 { (eval echo "$as_me:12000: \"$ac_try\"") >&5
12001 (eval $ac_try) 2>&5
12003 echo "$as_me:12003: \$? = $ac_status" >&5
12004 (exit $ac_status); }; }; then
12005 cf_cv_xopen_source=no
12007 echo "$as_me: failed program was:" >&5
12008 cat conftest.$ac_ext >&5
12009 cf_cv_xopen_source=$cf_XOPEN_SOURCE
12011 rm -f conftest.$ac_objext conftest.$ac_ext
12012 CPPFLAGS="$cf_save"
12015 rm -f conftest.$ac_objext conftest.$ac_ext
12018 echo "$as_me:12018: result: $cf_cv_xopen_source" >&5
12019 echo "${ECHO_T}$cf_cv_xopen_source" >&6
12021 if test "$cf_cv_xopen_source" != no ; then
12023 CFLAGS=`echo "$CFLAGS" | \
12024 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
12025 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
12027 CPPFLAGS=`echo "$CPPFLAGS" | \
12028 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
12029 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
12031 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
12036 cf_new_extra_cppflags=
12038 for cf_add_cflags in $cf_temp_xopen_source
12040 case $cf_fix_cppflags in
12042 case $cf_add_cflags in
12043 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
12044 case $cf_add_cflags in
12046 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
12048 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12049 && test -z "${cf_tst_cflags}" \
12050 && cf_fix_cppflags=yes
12052 if test $cf_fix_cppflags = yes ; then
12054 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12055 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12058 elif test "${cf_tst_cflags}" = "\"'" ; then
12060 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12061 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12067 case "$CPPFLAGS" in
12071 case $cf_add_cflags in
12073 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12075 CPPFLAGS=`echo "$CPPFLAGS" | \
12076 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12077 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12082 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
12083 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
12090 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
12091 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
12098 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12099 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12101 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
12103 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12104 && test -z "${cf_tst_cflags}" \
12105 && cf_fix_cppflags=no
12110 if test -n "$cf_new_cflags" ; then
12112 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
12113 CFLAGS="${CFLAGS}$cf_new_cflags"
12117 if test -n "$cf_new_cppflags" ; then
12119 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
12120 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
12124 if test -n "$cf_new_extra_cppflags" ; then
12126 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
12127 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
12133 if test "$cf_cv_posix_visible" = no; then
12135 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
12137 cf_save_CFLAGS="$CFLAGS"
12138 cf_save_CPPFLAGS="$CPPFLAGS"
12140 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
12141 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
12142 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
12144 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
12145 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
12146 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
12148 echo "$as_me:12148: checking if we should define _POSIX_C_SOURCE" >&5
12149 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
12150 if test "${cf_cv_posix_c_source+set}" = set; then
12151 echo $ECHO_N "(cached) $ECHO_C" >&6
12154 echo "${as_me:-configure}:12154: testing if the symbol is already defined go no further ..." 1>&5
12156 cat >conftest.$ac_ext <<_ACEOF
12157 #line 12157 "configure"
12158 #include "confdefs.h"
12159 #include <sys/types.h>
12164 #ifndef _POSIX_C_SOURCE
12171 rm -f conftest.$ac_objext
12172 if { (eval echo "$as_me:12172: \"$ac_compile\"") >&5
12173 (eval $ac_compile) 2>&5
12175 echo "$as_me:12175: \$? = $ac_status" >&5
12176 (exit $ac_status); } &&
12177 { ac_try='test -s conftest.$ac_objext'
12178 { (eval echo "$as_me:12178: \"$ac_try\"") >&5
12179 (eval $ac_try) 2>&5
12181 echo "$as_me:12181: \$? = $ac_status" >&5
12182 (exit $ac_status); }; }; then
12183 cf_cv_posix_c_source=no
12185 echo "$as_me: failed program was:" >&5
12186 cat conftest.$ac_ext >&5
12187 cf_want_posix_source=no
12188 case .$cf_POSIX_C_SOURCE in
12190 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
12193 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
12194 cf_want_posix_source=yes
12197 cf_want_posix_source=yes
12200 if test "$cf_want_posix_source" = yes ; then
12201 cat >conftest.$ac_ext <<_ACEOF
12202 #line 12202 "configure"
12203 #include "confdefs.h"
12204 #include <sys/types.h>
12209 #ifdef _POSIX_SOURCE
12216 rm -f conftest.$ac_objext
12217 if { (eval echo "$as_me:12217: \"$ac_compile\"") >&5
12218 (eval $ac_compile) 2>&5
12220 echo "$as_me:12220: \$? = $ac_status" >&5
12221 (exit $ac_status); } &&
12222 { ac_try='test -s conftest.$ac_objext'
12223 { (eval echo "$as_me:12223: \"$ac_try\"") >&5
12224 (eval $ac_try) 2>&5
12226 echo "$as_me:12226: \$? = $ac_status" >&5
12227 (exit $ac_status); }; }; then
12230 echo "$as_me: failed program was:" >&5
12231 cat conftest.$ac_ext >&5
12232 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
12234 rm -f conftest.$ac_objext conftest.$ac_ext
12237 echo "${as_me:-configure}:12237: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
12239 CFLAGS="$cf_trim_CFLAGS"
12240 CPPFLAGS="$cf_trim_CPPFLAGS"
12242 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
12243 CPPFLAGS="${CPPFLAGS}$cf_cv_posix_c_source"
12245 echo "${as_me:-configure}:12245: testing if the second compile does not leave our definition intact error ..." 1>&5
12247 cat >conftest.$ac_ext <<_ACEOF
12248 #line 12248 "configure"
12249 #include "confdefs.h"
12250 #include <sys/types.h>
12255 #ifndef _POSIX_C_SOURCE
12262 rm -f conftest.$ac_objext
12263 if { (eval echo "$as_me:12263: \"$ac_compile\"") >&5
12264 (eval $ac_compile) 2>&5
12266 echo "$as_me:12266: \$? = $ac_status" >&5
12267 (exit $ac_status); } &&
12268 { ac_try='test -s conftest.$ac_objext'
12269 { (eval echo "$as_me:12269: \"$ac_try\"") >&5
12270 (eval $ac_try) 2>&5
12272 echo "$as_me:12272: \$? = $ac_status" >&5
12273 (exit $ac_status); }; }; then
12276 echo "$as_me: failed program was:" >&5
12277 cat conftest.$ac_ext >&5
12278 cf_cv_posix_c_source=no
12280 rm -f conftest.$ac_objext conftest.$ac_ext
12281 CFLAGS="$cf_save_CFLAGS"
12282 CPPFLAGS="$cf_save_CPPFLAGS"
12285 rm -f conftest.$ac_objext conftest.$ac_ext
12288 echo "$as_me:12288: result: $cf_cv_posix_c_source" >&5
12289 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
12291 if test "$cf_cv_posix_c_source" != no ; then
12292 CFLAGS="$cf_trim_CFLAGS"
12293 CPPFLAGS="$cf_trim_CPPFLAGS"
12298 cf_new_extra_cppflags=
12300 for cf_add_cflags in $cf_cv_posix_c_source
12302 case $cf_fix_cppflags in
12304 case $cf_add_cflags in
12305 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
12306 case $cf_add_cflags in
12308 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
12310 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12311 && test -z "${cf_tst_cflags}" \
12312 && cf_fix_cppflags=yes
12314 if test $cf_fix_cppflags = yes ; then
12316 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12317 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12320 elif test "${cf_tst_cflags}" = "\"'" ; then
12322 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12323 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12329 case "$CPPFLAGS" in
12333 case $cf_add_cflags in
12335 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12337 CPPFLAGS=`echo "$CPPFLAGS" | \
12338 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12339 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12344 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
12345 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
12352 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
12353 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
12360 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12361 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12363 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
12365 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12366 && test -z "${cf_tst_cflags}" \
12367 && cf_fix_cppflags=no
12372 if test -n "$cf_new_cflags" ; then
12374 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
12375 CFLAGS="${CFLAGS}$cf_new_cflags"
12379 if test -n "$cf_new_cppflags" ; then
12381 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
12382 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
12386 if test -n "$cf_new_extra_cppflags" ; then
12388 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
12389 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
12395 fi # cf_cv_posix_visible
12400 if test -n "$cf_xopen_source" ; then
12405 cf_new_extra_cppflags=
12407 for cf_add_cflags in $cf_xopen_source
12409 case $cf_fix_cppflags in
12411 case $cf_add_cflags in
12412 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
12413 case $cf_add_cflags in
12415 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
12417 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12418 && test -z "${cf_tst_cflags}" \
12419 && cf_fix_cppflags=yes
12421 if test $cf_fix_cppflags = yes ; then
12423 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12424 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12427 elif test "${cf_tst_cflags}" = "\"'" ; then
12429 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12430 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12436 case "$CPPFLAGS" in
12440 case $cf_add_cflags in
12442 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12444 CPPFLAGS=`echo "$CPPFLAGS" | \
12445 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12446 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12451 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
12452 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
12459 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
12460 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
12467 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12468 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12470 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
12472 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12473 && test -z "${cf_tst_cflags}" \
12474 && cf_fix_cppflags=no
12479 if test -n "$cf_new_cflags" ; then
12480 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
12482 echo "${as_me:-configure}:12482: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
12484 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
12485 CFLAGS="${CFLAGS}$cf_new_cflags"
12489 if test -n "$cf_new_cppflags" ; then
12490 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
12492 echo "${as_me:-configure}:12492: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
12494 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
12495 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
12499 if test -n "$cf_new_extra_cppflags" ; then
12500 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
12502 echo "${as_me:-configure}:12502: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
12504 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
12505 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
12511 if test -n "$cf_XOPEN_SOURCE" && test -z "$cf_cv_xopen_source" ; then
12512 echo "$as_me:12512: checking if _XOPEN_SOURCE really is set" >&5
12513 echo $ECHO_N "checking if _XOPEN_SOURCE really is set... $ECHO_C" >&6
12514 cat >conftest.$ac_ext <<_ACEOF
12515 #line 12515 "configure"
12516 #include "confdefs.h"
12517 #include <stdlib.h>
12522 #ifndef _XOPEN_SOURCE
12529 rm -f conftest.$ac_objext
12530 if { (eval echo "$as_me:12530: \"$ac_compile\"") >&5
12531 (eval $ac_compile) 2>&5
12533 echo "$as_me:12533: \$? = $ac_status" >&5
12534 (exit $ac_status); } &&
12535 { ac_try='test -s conftest.$ac_objext'
12536 { (eval echo "$as_me:12536: \"$ac_try\"") >&5
12537 (eval $ac_try) 2>&5
12539 echo "$as_me:12539: \$? = $ac_status" >&5
12540 (exit $ac_status); }; }; then
12541 cf_XOPEN_SOURCE_set=yes
12543 echo "$as_me: failed program was:" >&5
12544 cat conftest.$ac_ext >&5
12545 cf_XOPEN_SOURCE_set=no
12547 rm -f conftest.$ac_objext conftest.$ac_ext
12548 echo "$as_me:12548: result: $cf_XOPEN_SOURCE_set" >&5
12549 echo "${ECHO_T}$cf_XOPEN_SOURCE_set" >&6
12550 if test $cf_XOPEN_SOURCE_set = yes
12552 cat >conftest.$ac_ext <<_ACEOF
12553 #line 12553 "configure"
12554 #include "confdefs.h"
12555 #include <stdlib.h>
12560 #if (_XOPEN_SOURCE - 0) < $cf_XOPEN_SOURCE
12567 rm -f conftest.$ac_objext
12568 if { (eval echo "$as_me:12568: \"$ac_compile\"") >&5
12569 (eval $ac_compile) 2>&5
12571 echo "$as_me:12571: \$? = $ac_status" >&5
12572 (exit $ac_status); } &&
12573 { ac_try='test -s conftest.$ac_objext'
12574 { (eval echo "$as_me:12574: \"$ac_try\"") >&5
12575 (eval $ac_try) 2>&5
12577 echo "$as_me:12577: \$? = $ac_status" >&5
12578 (exit $ac_status); }; }; then
12579 cf_XOPEN_SOURCE_set_ok=yes
12581 echo "$as_me: failed program was:" >&5
12582 cat conftest.$ac_ext >&5
12583 cf_XOPEN_SOURCE_set_ok=no
12585 rm -f conftest.$ac_objext conftest.$ac_ext
12586 if test $cf_XOPEN_SOURCE_set_ok = no
12588 { echo "$as_me:12588: WARNING: _XOPEN_SOURCE is lower than requested" >&5
12589 echo "$as_me: WARNING: _XOPEN_SOURCE is lower than requested" >&2;}
12593 echo "$as_me:12593: checking if we should define _XOPEN_SOURCE" >&5
12594 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
12595 if test "${cf_cv_xopen_source+set}" = set; then
12596 echo $ECHO_N "(cached) $ECHO_C" >&6
12599 cat >conftest.$ac_ext <<_ACEOF
12600 #line 12600 "configure"
12601 #include "confdefs.h"
12603 #include <stdlib.h>
12604 #include <string.h>
12605 #include <sys/types.h>
12611 #ifndef _XOPEN_SOURCE
12618 rm -f conftest.$ac_objext
12619 if { (eval echo "$as_me:12619: \"$ac_compile\"") >&5
12620 (eval $ac_compile) 2>&5
12622 echo "$as_me:12622: \$? = $ac_status" >&5
12623 (exit $ac_status); } &&
12624 { ac_try='test -s conftest.$ac_objext'
12625 { (eval echo "$as_me:12625: \"$ac_try\"") >&5
12626 (eval $ac_try) 2>&5
12628 echo "$as_me:12628: \$? = $ac_status" >&5
12629 (exit $ac_status); }; }; then
12630 cf_cv_xopen_source=no
12632 echo "$as_me: failed program was:" >&5
12633 cat conftest.$ac_ext >&5
12634 cf_save="$CPPFLAGS"
12636 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
12637 CPPFLAGS="${CPPFLAGS}-D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
12639 cat >conftest.$ac_ext <<_ACEOF
12640 #line 12640 "configure"
12641 #include "confdefs.h"
12643 #include <stdlib.h>
12644 #include <string.h>
12645 #include <sys/types.h>
12651 #ifdef _XOPEN_SOURCE
12658 rm -f conftest.$ac_objext
12659 if { (eval echo "$as_me:12659: \"$ac_compile\"") >&5
12660 (eval $ac_compile) 2>&5
12662 echo "$as_me:12662: \$? = $ac_status" >&5
12663 (exit $ac_status); } &&
12664 { ac_try='test -s conftest.$ac_objext'
12665 { (eval echo "$as_me:12665: \"$ac_try\"") >&5
12666 (eval $ac_try) 2>&5
12668 echo "$as_me:12668: \$? = $ac_status" >&5
12669 (exit $ac_status); }; }; then
12670 cf_cv_xopen_source=no
12672 echo "$as_me: failed program was:" >&5
12673 cat conftest.$ac_ext >&5
12674 cf_cv_xopen_source=$cf_XOPEN_SOURCE
12676 rm -f conftest.$ac_objext conftest.$ac_ext
12677 CPPFLAGS="$cf_save"
12680 rm -f conftest.$ac_objext conftest.$ac_ext
12683 echo "$as_me:12683: result: $cf_cv_xopen_source" >&5
12684 echo "${ECHO_T}$cf_cv_xopen_source" >&6
12686 if test "$cf_cv_xopen_source" != no ; then
12688 CFLAGS=`echo "$CFLAGS" | \
12689 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
12690 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
12692 CPPFLAGS=`echo "$CPPFLAGS" | \
12693 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
12694 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
12696 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
12701 cf_new_extra_cppflags=
12703 for cf_add_cflags in $cf_temp_xopen_source
12705 case $cf_fix_cppflags in
12707 case $cf_add_cflags in
12708 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
12709 case $cf_add_cflags in
12711 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
12713 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12714 && test -z "${cf_tst_cflags}" \
12715 && cf_fix_cppflags=yes
12717 if test $cf_fix_cppflags = yes ; then
12719 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12720 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12723 elif test "${cf_tst_cflags}" = "\"'" ; then
12725 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12726 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12732 case "$CPPFLAGS" in
12736 case $cf_add_cflags in
12738 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12740 CPPFLAGS=`echo "$CPPFLAGS" | \
12741 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12742 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12747 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
12748 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
12755 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
12756 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
12763 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12764 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12766 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
12768 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12769 && test -z "${cf_tst_cflags}" \
12770 && cf_fix_cppflags=no
12775 if test -n "$cf_new_cflags" ; then
12777 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
12778 CFLAGS="${CFLAGS}$cf_new_cflags"
12782 if test -n "$cf_new_cppflags" ; then
12784 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
12785 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
12789 if test -n "$cf_new_extra_cppflags" ; then
12791 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
12792 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
12800 fi # cf_cv_posix_visible
12802 # Check whether --enable-largefile or --disable-largefile was given.
12803 if test "${enable_largefile+set}" = set; then
12804 enableval="$enable_largefile"
12807 if test "$enable_largefile" != no; then
12809 echo "$as_me:12809: checking for special C compiler options needed for large files" >&5
12810 echo $ECHO_N "checking for special C compiler options needed for large files... $ECHO_C" >&6
12811 if test "${ac_cv_sys_largefile_CC+set}" = set; then
12812 echo $ECHO_N "(cached) $ECHO_C" >&6
12814 ac_cv_sys_largefile_CC=no
12815 if test "$GCC" != yes; then
12818 # IRIX 6.2 and later do not support large files by default,
12819 # so use the C compiler's -n32 option if that helps.
12820 cat >conftest.$ac_ext <<_ACEOF
12821 #line 12821 "configure"
12822 #include "confdefs.h"
12823 #include <sys/types.h>
12824 /* Check that off_t can represent 2**63 - 1 correctly.
12825 We can't simply define LARGE_OFF_T to be 9223372036854775807,
12826 since some C++ compilers masquerading as C compilers
12827 incorrectly reject 9223372036854775807. */
12828 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
12829 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
12830 && LARGE_OFF_T % 2147483647 == 1)
12840 rm -f conftest.$ac_objext
12841 if { (eval echo "$as_me:12841: \"$ac_compile\"") >&5
12842 (eval $ac_compile) 2>&5
12844 echo "$as_me:12844: \$? = $ac_status" >&5
12845 (exit $ac_status); } &&
12846 { ac_try='test -s conftest.$ac_objext'
12847 { (eval echo "$as_me:12847: \"$ac_try\"") >&5
12848 (eval $ac_try) 2>&5
12850 echo "$as_me:12850: \$? = $ac_status" >&5
12851 (exit $ac_status); }; }; then
12854 echo "$as_me: failed program was:" >&5
12855 cat conftest.$ac_ext >&5
12857 rm -f conftest.$ac_objext
12859 rm -f conftest.$ac_objext
12860 if { (eval echo "$as_me:12860: \"$ac_compile\"") >&5
12861 (eval $ac_compile) 2>&5
12863 echo "$as_me:12863: \$? = $ac_status" >&5
12864 (exit $ac_status); } &&
12865 { ac_try='test -s conftest.$ac_objext'
12866 { (eval echo "$as_me:12866: \"$ac_try\"") >&5
12867 (eval $ac_try) 2>&5
12869 echo "$as_me:12869: \$? = $ac_status" >&5
12870 (exit $ac_status); }; }; then
12871 ac_cv_sys_largefile_CC=' -n32'; break
12873 echo "$as_me: failed program was:" >&5
12874 cat conftest.$ac_ext >&5
12876 rm -f conftest.$ac_objext
12880 rm -f conftest.$ac_ext
12883 echo "$as_me:12883: result: $ac_cv_sys_largefile_CC" >&5
12884 echo "${ECHO_T}$ac_cv_sys_largefile_CC" >&6
12885 if test "$ac_cv_sys_largefile_CC" != no; then
12886 CC=$CC$ac_cv_sys_largefile_CC
12889 echo "$as_me:12889: checking for _FILE_OFFSET_BITS value needed for large files" >&5
12890 echo $ECHO_N "checking for _FILE_OFFSET_BITS value needed for large files... $ECHO_C" >&6
12891 if test "${ac_cv_sys_file_offset_bits+set}" = set; then
12892 echo $ECHO_N "(cached) $ECHO_C" >&6
12895 ac_cv_sys_file_offset_bits=no
12896 cat >conftest.$ac_ext <<_ACEOF
12897 #line 12897 "configure"
12898 #include "confdefs.h"
12899 #include <sys/types.h>
12900 /* Check that off_t can represent 2**63 - 1 correctly.
12901 We can't simply define LARGE_OFF_T to be 9223372036854775807,
12902 since some C++ compilers masquerading as C compilers
12903 incorrectly reject 9223372036854775807. */
12904 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
12905 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
12906 && LARGE_OFF_T % 2147483647 == 1)
12916 rm -f conftest.$ac_objext
12917 if { (eval echo "$as_me:12917: \"$ac_compile\"") >&5
12918 (eval $ac_compile) 2>&5
12920 echo "$as_me:12920: \$? = $ac_status" >&5
12921 (exit $ac_status); } &&
12922 { ac_try='test -s conftest.$ac_objext'
12923 { (eval echo "$as_me:12923: \"$ac_try\"") >&5
12924 (eval $ac_try) 2>&5
12926 echo "$as_me:12926: \$? = $ac_status" >&5
12927 (exit $ac_status); }; }; then
12930 echo "$as_me: failed program was:" >&5
12931 cat conftest.$ac_ext >&5
12933 rm -f conftest.$ac_objext conftest.$ac_ext
12934 cat >conftest.$ac_ext <<_ACEOF
12935 #line 12935 "configure"
12936 #include "confdefs.h"
12937 #define _FILE_OFFSET_BITS 64
12938 #include <sys/types.h>
12939 /* Check that off_t can represent 2**63 - 1 correctly.
12940 We can't simply define LARGE_OFF_T to be 9223372036854775807,
12941 since some C++ compilers masquerading as C compilers
12942 incorrectly reject 9223372036854775807. */
12943 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
12944 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
12945 && LARGE_OFF_T % 2147483647 == 1)
12955 rm -f conftest.$ac_objext
12956 if { (eval echo "$as_me:12956: \"$ac_compile\"") >&5
12957 (eval $ac_compile) 2>&5
12959 echo "$as_me:12959: \$? = $ac_status" >&5
12960 (exit $ac_status); } &&
12961 { ac_try='test -s conftest.$ac_objext'
12962 { (eval echo "$as_me:12962: \"$ac_try\"") >&5
12963 (eval $ac_try) 2>&5
12965 echo "$as_me:12965: \$? = $ac_status" >&5
12966 (exit $ac_status); }; }; then
12967 ac_cv_sys_file_offset_bits=64; break
12969 echo "$as_me: failed program was:" >&5
12970 cat conftest.$ac_ext >&5
12972 rm -f conftest.$ac_objext conftest.$ac_ext
12976 echo "$as_me:12976: result: $ac_cv_sys_file_offset_bits" >&5
12977 echo "${ECHO_T}$ac_cv_sys_file_offset_bits" >&6
12978 if test "$ac_cv_sys_file_offset_bits" != no; then
12980 cat >>confdefs.h <<EOF
12981 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
12986 echo "$as_me:12986: checking for _LARGE_FILES value needed for large files" >&5
12987 echo $ECHO_N "checking for _LARGE_FILES value needed for large files... $ECHO_C" >&6
12988 if test "${ac_cv_sys_large_files+set}" = set; then
12989 echo $ECHO_N "(cached) $ECHO_C" >&6
12992 ac_cv_sys_large_files=no
12993 cat >conftest.$ac_ext <<_ACEOF
12994 #line 12994 "configure"
12995 #include "confdefs.h"
12996 #include <sys/types.h>
12997 /* Check that off_t can represent 2**63 - 1 correctly.
12998 We can't simply define LARGE_OFF_T to be 9223372036854775807,
12999 since some C++ compilers masquerading as C compilers
13000 incorrectly reject 9223372036854775807. */
13001 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
13002 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
13003 && LARGE_OFF_T % 2147483647 == 1)
13013 rm -f conftest.$ac_objext
13014 if { (eval echo "$as_me:13014: \"$ac_compile\"") >&5
13015 (eval $ac_compile) 2>&5
13017 echo "$as_me:13017: \$? = $ac_status" >&5
13018 (exit $ac_status); } &&
13019 { ac_try='test -s conftest.$ac_objext'
13020 { (eval echo "$as_me:13020: \"$ac_try\"") >&5
13021 (eval $ac_try) 2>&5
13023 echo "$as_me:13023: \$? = $ac_status" >&5
13024 (exit $ac_status); }; }; then
13027 echo "$as_me: failed program was:" >&5
13028 cat conftest.$ac_ext >&5
13030 rm -f conftest.$ac_objext conftest.$ac_ext
13031 cat >conftest.$ac_ext <<_ACEOF
13032 #line 13032 "configure"
13033 #include "confdefs.h"
13034 #define _LARGE_FILES 1
13035 #include <sys/types.h>
13036 /* Check that off_t can represent 2**63 - 1 correctly.
13037 We can't simply define LARGE_OFF_T to be 9223372036854775807,
13038 since some C++ compilers masquerading as C compilers
13039 incorrectly reject 9223372036854775807. */
13040 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
13041 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
13042 && LARGE_OFF_T % 2147483647 == 1)
13052 rm -f conftest.$ac_objext
13053 if { (eval echo "$as_me:13053: \"$ac_compile\"") >&5
13054 (eval $ac_compile) 2>&5
13056 echo "$as_me:13056: \$? = $ac_status" >&5
13057 (exit $ac_status); } &&
13058 { ac_try='test -s conftest.$ac_objext'
13059 { (eval echo "$as_me:13059: \"$ac_try\"") >&5
13060 (eval $ac_try) 2>&5
13062 echo "$as_me:13062: \$? = $ac_status" >&5
13063 (exit $ac_status); }; }; then
13064 ac_cv_sys_large_files=1; break
13066 echo "$as_me: failed program was:" >&5
13067 cat conftest.$ac_ext >&5
13069 rm -f conftest.$ac_objext conftest.$ac_ext
13073 echo "$as_me:13073: result: $ac_cv_sys_large_files" >&5
13074 echo "${ECHO_T}$ac_cv_sys_large_files" >&6
13075 if test "$ac_cv_sys_large_files" != no; then
13077 cat >>confdefs.h <<EOF
13078 #define _LARGE_FILES $ac_cv_sys_large_files
13085 if test "$enable_largefile" != no ; then
13086 echo "$as_me:13086: checking for _LARGEFILE_SOURCE value needed for large files" >&5
13087 echo $ECHO_N "checking for _LARGEFILE_SOURCE value needed for large files... $ECHO_C" >&6
13088 if test "${ac_cv_sys_largefile_source+set}" = set; then
13089 echo $ECHO_N "(cached) $ECHO_C" >&6
13092 ac_cv_sys_largefile_source=no
13093 cat >conftest.$ac_ext <<_ACEOF
13094 #line 13094 "configure"
13095 #include "confdefs.h"
13105 rm -f conftest.$ac_objext
13106 if { (eval echo "$as_me:13106: \"$ac_compile\"") >&5
13107 (eval $ac_compile) 2>&5
13109 echo "$as_me:13109: \$? = $ac_status" >&5
13110 (exit $ac_status); } &&
13111 { ac_try='test -s conftest.$ac_objext'
13112 { (eval echo "$as_me:13112: \"$ac_try\"") >&5
13113 (eval $ac_try) 2>&5
13115 echo "$as_me:13115: \$? = $ac_status" >&5
13116 (exit $ac_status); }; }; then
13119 echo "$as_me: failed program was:" >&5
13120 cat conftest.$ac_ext >&5
13122 rm -f conftest.$ac_objext conftest.$ac_ext
13123 cat >conftest.$ac_ext <<_ACEOF
13124 #line 13124 "configure"
13125 #include "confdefs.h"
13126 #define _LARGEFILE_SOURCE 1
13136 rm -f conftest.$ac_objext
13137 if { (eval echo "$as_me:13137: \"$ac_compile\"") >&5
13138 (eval $ac_compile) 2>&5
13140 echo "$as_me:13140: \$? = $ac_status" >&5
13141 (exit $ac_status); } &&
13142 { ac_try='test -s conftest.$ac_objext'
13143 { (eval echo "$as_me:13143: \"$ac_try\"") >&5
13144 (eval $ac_try) 2>&5
13146 echo "$as_me:13146: \$? = $ac_status" >&5
13147 (exit $ac_status); }; }; then
13148 ac_cv_sys_largefile_source=1; break
13150 echo "$as_me: failed program was:" >&5
13151 cat conftest.$ac_ext >&5
13153 rm -f conftest.$ac_objext conftest.$ac_ext
13157 echo "$as_me:13157: result: $ac_cv_sys_largefile_source" >&5
13158 echo "${ECHO_T}$ac_cv_sys_largefile_source" >&6
13159 if test "$ac_cv_sys_largefile_source" != no; then
13161 cat >>confdefs.h <<EOF
13162 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
13168 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
13169 # in glibc 2.1.3, but that breaks too many other things.
13170 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
13171 echo "$as_me:13171: checking for fseeko" >&5
13172 echo $ECHO_N "checking for fseeko... $ECHO_C" >&6
13173 if test "${ac_cv_func_fseeko+set}" = set; then
13174 echo $ECHO_N "(cached) $ECHO_C" >&6
13176 cat >conftest.$ac_ext <<_ACEOF
13177 #line 13177 "configure"
13178 #include "confdefs.h"
13183 return fseeko && fseeko (stdin, 0, 0);
13188 rm -f conftest.$ac_objext conftest$ac_exeext
13189 if { (eval echo "$as_me:13189: \"$ac_link\"") >&5
13190 (eval $ac_link) 2>&5
13192 echo "$as_me:13192: \$? = $ac_status" >&5
13193 (exit $ac_status); } &&
13194 { ac_try='test -s conftest$ac_exeext'
13195 { (eval echo "$as_me:13195: \"$ac_try\"") >&5
13196 (eval $ac_try) 2>&5
13198 echo "$as_me:13198: \$? = $ac_status" >&5
13199 (exit $ac_status); }; }; then
13200 ac_cv_func_fseeko=yes
13202 echo "$as_me: failed program was:" >&5
13203 cat conftest.$ac_ext >&5
13204 ac_cv_func_fseeko=no
13206 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13208 echo "$as_me:13208: result: $ac_cv_func_fseeko" >&5
13209 echo "${ECHO_T}$ac_cv_func_fseeko" >&6
13210 if test $ac_cv_func_fseeko = yes; then
13212 cat >>confdefs.h <<\EOF
13213 #define HAVE_FSEEKO 1
13218 # Normally we would collect these definitions in the config.h,
13219 # but (like _XOPEN_SOURCE), some environments rely on having these
13220 # defined before any of the system headers are included. Another
13221 # case comes up with C++, e.g., on AIX the compiler compiles the
13222 # header files by themselves before looking at the body files it is
13223 # told to compile. For ncurses, those header files do not include
13225 if test "$ac_cv_sys_large_files" != no
13228 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13229 CPPFLAGS="${CPPFLAGS}-D_LARGE_FILES"
13232 if test "$ac_cv_sys_largefile_source" != no
13235 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13236 CPPFLAGS="${CPPFLAGS}-D_LARGEFILE_SOURCE"
13239 if test "$ac_cv_sys_file_offset_bits" != no
13242 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13243 CPPFLAGS="${CPPFLAGS}-D_FILE_OFFSET_BITS=$ac_cv_sys_file_offset_bits"
13247 echo "$as_me:13247: checking whether to use struct dirent64" >&5
13248 echo $ECHO_N "checking whether to use struct dirent64... $ECHO_C" >&6
13249 if test "${cf_cv_struct_dirent64+set}" = set; then
13250 echo $ECHO_N "(cached) $ECHO_C" >&6
13253 cat >conftest.$ac_ext <<_ACEOF
13254 #line 13254 "configure"
13255 #include "confdefs.h"
13257 #pragma GCC diagnostic error "-Wincompatible-pointer-types"
13258 #include <sys/types.h>
13259 #include <dirent.h>
13265 /* if transitional largefile support is setup, this is true */
13266 extern struct dirent64 * readdir(DIR *);
13267 struct dirent64 *x = readdir((DIR *)0);
13268 struct dirent *y = readdir((DIR *)0);
13275 rm -f conftest.$ac_objext
13276 if { (eval echo "$as_me:13276: \"$ac_compile\"") >&5
13277 (eval $ac_compile) 2>&5
13279 echo "$as_me:13279: \$? = $ac_status" >&5
13280 (exit $ac_status); } &&
13281 { ac_try='test -s conftest.$ac_objext'
13282 { (eval echo "$as_me:13282: \"$ac_try\"") >&5
13283 (eval $ac_try) 2>&5
13285 echo "$as_me:13285: \$? = $ac_status" >&5
13286 (exit $ac_status); }; }; then
13287 cf_cv_struct_dirent64=yes
13289 echo "$as_me: failed program was:" >&5
13290 cat conftest.$ac_ext >&5
13291 cf_cv_struct_dirent64=no
13293 rm -f conftest.$ac_objext conftest.$ac_ext
13296 echo "$as_me:13296: result: $cf_cv_struct_dirent64" >&5
13297 echo "${ECHO_T}$cf_cv_struct_dirent64" >&6
13298 test "$cf_cv_struct_dirent64" = yes &&
13299 cat >>confdefs.h <<\EOF
13300 #define HAVE_STRUCT_DIRENT64 1
13305 ### Enable compiling-in rcs id's
13306 echo "$as_me:13306: checking if RCS identifiers should be compiled-in" >&5
13307 echo $ECHO_N "checking if RCS identifiers should be compiled-in... $ECHO_C" >&6
13309 # Check whether --with-rcs-ids or --without-rcs-ids was given.
13310 if test "${with_rcs_ids+set}" = set; then
13311 withval="$with_rcs_ids"
13312 with_rcs_ids=$withval
13316 echo "$as_me:13316: result: $with_rcs_ids" >&5
13317 echo "${ECHO_T}$with_rcs_ids" >&6
13318 test "$with_rcs_ids" = yes &&
13319 cat >>confdefs.h <<\EOF
13320 #define USE_RCS_IDS 1
13323 ###############################################################################
13325 ### Note that some functions (such as const) are normally disabled anyway.
13326 echo "$as_me:13326: checking if you want to build with function extensions" >&5
13327 echo $ECHO_N "checking if you want to build with function extensions... $ECHO_C" >&6
13329 # Check whether --enable-ext-funcs or --disable-ext-funcs was given.
13330 if test "${enable_ext_funcs+set}" = set; then
13331 enableval="$enable_ext_funcs"
13332 with_ext_funcs=$enableval
13336 echo "$as_me:13336: result: $with_ext_funcs" >&5
13337 echo "${ECHO_T}$with_ext_funcs" >&6
13338 if test "$with_ext_funcs" = yes ; then
13339 NCURSES_EXT_FUNCS=1
13341 cat >>confdefs.h <<\EOF
13342 #define HAVE_USE_DEFAULT_COLORS 1
13345 cat >>confdefs.h <<\EOF
13346 #define NCURSES_EXT_FUNCS 1
13350 NCURSES_EXT_FUNCS=0
13353 ### use option --enable-const to turn on use of const beyond that in XSI.
13354 echo "$as_me:13354: checking for extended use of const keyword" >&5
13355 echo $ECHO_N "checking for extended use of const keyword... $ECHO_C" >&6
13357 # Check whether --enable-const or --disable-const was given.
13358 if test "${enable_const+set}" = set; then
13359 enableval="$enable_const"
13360 with_ext_const=$enableval
13364 echo "$as_me:13364: result: $with_ext_const" >&5
13365 echo "${ECHO_T}$with_ext_const" >&6
13366 NCURSES_CONST='/*nothing*/'
13367 if test "$with_ext_const" = yes ; then
13368 NCURSES_CONST=const
13371 ###############################################################################
13372 # These options are relatively safe to experiment with.
13374 echo "$as_me:13374: checking if you want all development code" >&5
13375 echo $ECHO_N "checking if you want all development code... $ECHO_C" >&6
13377 # Check whether --with-develop or --without-develop was given.
13378 if test "${with_develop+set}" = set; then
13379 withval="$with_develop"
13380 with_develop=$withval
13384 echo "$as_me:13384: result: $with_develop" >&5
13385 echo "${ECHO_T}$with_develop" >&6
13387 ###############################################################################
13388 # These are just experimental, probably should not be in a package:
13390 # This is still experimental (20080329), but should ultimately be moved to
13391 # the script-block --with-normal, etc.
13393 echo "$as_me:13393: checking if you want to link with the pthread library" >&5
13394 echo $ECHO_N "checking if you want to link with the pthread library... $ECHO_C" >&6
13396 # Check whether --with-pthread or --without-pthread was given.
13397 if test "${with_pthread+set}" = set; then
13398 withval="$with_pthread"
13399 with_pthread=$withval
13403 echo "$as_me:13403: result: $with_pthread" >&5
13404 echo "${ECHO_T}$with_pthread" >&6
13406 if test "$with_pthread" != no ; then
13407 echo "$as_me:13407: checking for pthread.h" >&5
13408 echo $ECHO_N "checking for pthread.h... $ECHO_C" >&6
13409 if test "${ac_cv_header_pthread_h+set}" = set; then
13410 echo $ECHO_N "(cached) $ECHO_C" >&6
13412 cat >conftest.$ac_ext <<_ACEOF
13413 #line 13413 "configure"
13414 #include "confdefs.h"
13415 #include <pthread.h>
13417 if { (eval echo "$as_me:13417: \"$ac_cpp conftest.$ac_ext\"") >&5
13418 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13420 egrep -v '^ *\+' conftest.er1 >conftest.err
13422 cat conftest.err >&5
13423 echo "$as_me:13423: \$? = $ac_status" >&5
13424 (exit $ac_status); } >/dev/null; then
13425 if test -s conftest.err; then
13426 ac_cpp_err=$ac_c_preproc_warn_flag
13433 if test -z "$ac_cpp_err"; then
13434 ac_cv_header_pthread_h=yes
13436 echo "$as_me: failed program was:" >&5
13437 cat conftest.$ac_ext >&5
13438 ac_cv_header_pthread_h=no
13440 rm -f conftest.err conftest.$ac_ext
13442 echo "$as_me:13442: result: $ac_cv_header_pthread_h" >&5
13443 echo "${ECHO_T}$ac_cv_header_pthread_h" >&6
13444 if test $ac_cv_header_pthread_h = yes; then
13446 cat >>confdefs.h <<\EOF
13447 #define HAVE_PTHREADS_H 1
13450 for cf_lib_pthread in pthread c_r
13452 echo "$as_me:13452: checking if we can link with the $cf_lib_pthread library" >&5
13453 echo $ECHO_N "checking if we can link with the $cf_lib_pthread library... $ECHO_C" >&6
13454 cf_save_LIBS="$LIBS"
13456 cf_add_libs="$LIBS"
13459 for cf_add_1lib in -l$cf_lib_pthread; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
13460 # filter duplicates
13461 for cf_add_1lib in $cf_add_0lib; do
13462 for cf_add_2lib in $cf_add_libs; do
13463 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
13468 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
13470 LIBS="$cf_add_libs"
13472 cat >conftest.$ac_ext <<_ACEOF
13473 #line 13473 "configure"
13474 #include "confdefs.h"
13476 #include <pthread.h>
13482 int rc = pthread_create(0,0,0,0);
13483 int r2 = pthread_mutexattr_settype(0, 0);
13489 rm -f conftest.$ac_objext conftest$ac_exeext
13490 if { (eval echo "$as_me:13490: \"$ac_link\"") >&5
13491 (eval $ac_link) 2>&5
13493 echo "$as_me:13493: \$? = $ac_status" >&5
13494 (exit $ac_status); } &&
13495 { ac_try='test -s conftest$ac_exeext'
13496 { (eval echo "$as_me:13496: \"$ac_try\"") >&5
13497 (eval $ac_try) 2>&5
13499 echo "$as_me:13499: \$? = $ac_status" >&5
13500 (exit $ac_status); }; }; then
13503 echo "$as_me: failed program was:" >&5
13504 cat conftest.$ac_ext >&5
13507 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13508 LIBS="$cf_save_LIBS"
13509 echo "$as_me:13509: result: $with_pthread" >&5
13510 echo "${ECHO_T}$with_pthread" >&6
13511 test "$with_pthread" = yes && break
13514 if test "$with_pthread" = yes ; then
13516 cf_add_libs="$LIBS"
13519 for cf_add_1lib in -l$cf_lib_pthread; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
13520 # filter duplicates
13521 for cf_add_1lib in $cf_add_0lib; do
13522 for cf_add_2lib in $cf_add_libs; do
13523 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
13528 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
13530 LIBS="$cf_add_libs"
13532 cat >>confdefs.h <<\EOF
13533 #define HAVE_LIBPTHREADS 1
13537 { { echo "$as_me:13537: error: Cannot link with pthread library" >&5
13538 echo "$as_me: error: Cannot link with pthread library" >&2;}
13539 { (exit 1); exit 1; }; }
13546 echo "$as_me:13546: checking if you want to use weak-symbols for pthreads" >&5
13547 echo $ECHO_N "checking if you want to use weak-symbols for pthreads... $ECHO_C" >&6
13549 # Check whether --enable-weak-symbols or --disable-weak-symbols was given.
13550 if test "${enable_weak_symbols+set}" = set; then
13551 enableval="$enable_weak_symbols"
13552 use_weak_symbols=$withval
13554 use_weak_symbols=no
13556 echo "$as_me:13556: result: $use_weak_symbols" >&5
13557 echo "${ECHO_T}$use_weak_symbols" >&6
13558 if test "$use_weak_symbols" = yes ; then
13560 echo "$as_me:13560: checking if $CC supports weak symbols" >&5
13561 echo $ECHO_N "checking if $CC supports weak symbols... $ECHO_C" >&6
13562 if test "${cf_cv_weak_symbols+set}" = set; then
13563 echo $ECHO_N "(cached) $ECHO_C" >&6
13566 cat >conftest.$ac_ext <<_ACEOF
13567 #line 13567 "configure"
13568 #include "confdefs.h"
13575 #if defined(__GNUC__)
13576 # if defined __USE_ISOC99
13577 # define _cat_pragma(exp) _Pragma(#exp)
13578 # define _weak_pragma(exp) _cat_pragma(weak name)
13580 # define _weak_pragma(exp)
13582 # define _declare(name) __extension__ extern __typeof__(name) name
13583 # define weak_symbol(name) _weak_pragma(name) _declare(name) __attribute__((weak))
13586 weak_symbol(fopen);
13592 rm -f conftest.$ac_objext
13593 if { (eval echo "$as_me:13593: \"$ac_compile\"") >&5
13594 (eval $ac_compile) 2>&5
13596 echo "$as_me:13596: \$? = $ac_status" >&5
13597 (exit $ac_status); } &&
13598 { ac_try='test -s conftest.$ac_objext'
13599 { (eval echo "$as_me:13599: \"$ac_try\"") >&5
13600 (eval $ac_try) 2>&5
13602 echo "$as_me:13602: \$? = $ac_status" >&5
13603 (exit $ac_status); }; }; then
13604 cf_cv_weak_symbols=yes
13606 echo "$as_me: failed program was:" >&5
13607 cat conftest.$ac_ext >&5
13608 cf_cv_weak_symbols=no
13610 rm -f conftest.$ac_objext conftest.$ac_ext
13613 echo "$as_me:13613: result: $cf_cv_weak_symbols" >&5
13614 echo "${ECHO_T}$cf_cv_weak_symbols" >&6
13617 cf_cv_weak_symbols=no
13620 if test $cf_cv_weak_symbols = yes ; then
13622 cat >>confdefs.h <<\EOF
13623 #define USE_WEAK_SYMBOLS 1
13629 if test "$with_pthread" = "yes" ; then
13631 cat >>confdefs.h <<\EOF
13632 #define USE_PTHREADS 1
13635 enable_reentrant=yes
13636 if test $cf_cv_weak_symbols = yes ; then
13641 # OpenSUSE is installing ncurses6, using reentrant option.
13642 echo "$as_me:13642: checking for _nc_TABSIZE" >&5
13643 echo $ECHO_N "checking for _nc_TABSIZE... $ECHO_C" >&6
13644 if test "${ac_cv_func__nc_TABSIZE+set}" = set; then
13645 echo $ECHO_N "(cached) $ECHO_C" >&6
13647 cat >conftest.$ac_ext <<_ACEOF
13648 #line 13648 "configure"
13649 #include "confdefs.h"
13650 #define _nc_TABSIZE autoconf_temporary
13651 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
13658 /* We use char because int might match the return type of a gcc2
13659 builtin and then its argument prototype would still apply. */
13660 char _nc_TABSIZE (void);
13666 /* The GNU C library defines stubs for functions which it implements
13667 to always fail with ENOSYS. Some functions are actually named
13668 something starting with __ and the normal name is an alias. */
13669 #if defined (__stub__nc_TABSIZE) || defined (__stub____nc_TABSIZE)
13670 #error found stub for _nc_TABSIZE
13673 return _nc_TABSIZE ();
13678 rm -f conftest.$ac_objext conftest$ac_exeext
13679 if { (eval echo "$as_me:13679: \"$ac_link\"") >&5
13680 (eval $ac_link) 2>&5
13682 echo "$as_me:13682: \$? = $ac_status" >&5
13683 (exit $ac_status); } &&
13684 { ac_try='test -s conftest$ac_exeext'
13685 { (eval echo "$as_me:13685: \"$ac_try\"") >&5
13686 (eval $ac_try) 2>&5
13688 echo "$as_me:13688: \$? = $ac_status" >&5
13689 (exit $ac_status); }; }; then
13690 ac_cv_func__nc_TABSIZE=yes
13692 echo "$as_me: failed program was:" >&5
13693 cat conftest.$ac_ext >&5
13694 ac_cv_func__nc_TABSIZE=no
13696 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13698 echo "$as_me:13698: result: $ac_cv_func__nc_TABSIZE" >&5
13699 echo "${ECHO_T}$ac_cv_func__nc_TABSIZE" >&6
13700 if test $ac_cv_func__nc_TABSIZE = yes; then
13701 assume_reentrant=yes
13703 assume_reentrant=no
13706 # Reentrant code has to be opaque; there's little advantage to making ncurses
13707 # opaque outside of that, so there is no --enable-opaque option. We can use
13708 # this option without --with-pthreads, but this will be always set for
13710 echo "$as_me:13710: checking if you want experimental reentrant code" >&5
13711 echo $ECHO_N "checking if you want experimental reentrant code... $ECHO_C" >&6
13713 # Check whether --enable-reentrant or --disable-reentrant was given.
13714 if test "${enable_reentrant+set}" = set; then
13715 enableval="$enable_reentrant"
13716 with_reentrant=$enableval
13718 with_reentrant=$assume_reentrant
13720 echo "$as_me:13720: result: $with_reentrant" >&5
13721 echo "${ECHO_T}$with_reentrant" >&6
13722 if test "$with_reentrant" = yes ; then
13723 cf_cv_enable_reentrant=1
13724 if test $cf_cv_weak_symbols = yes ; then
13726 # remove pthread library from $LIBS
13727 LIBS=`echo "$LIBS" | sed -e 's/-lpthread[ ]//g' -e 's/-lpthread$//'`
13729 elif test "$assume_reentrant" = no ; then
13730 LIB_SUFFIX="t${LIB_SUFFIX}"
13733 cat >>confdefs.h <<\EOF
13734 #define USE_REENTRANT 1
13738 cf_cv_enable_reentrant=0
13741 ### Allow using a different wrap-prefix
13742 if test "$cf_cv_enable_reentrant" != 0 || test "$BROKEN_LINKER" = 1 ; then
13743 echo "$as_me:13743: checking for prefix used to wrap public variables" >&5
13744 echo $ECHO_N "checking for prefix used to wrap public variables... $ECHO_C" >&6
13746 # Check whether --with-wrap-prefix or --without-wrap-prefix was given.
13747 if test "${with_wrap_prefix+set}" = set; then
13748 withval="$with_wrap_prefix"
13749 NCURSES_WRAP_PREFIX=$withval
13751 NCURSES_WRAP_PREFIX=_nc_
13753 echo "$as_me:13753: result: $NCURSES_WRAP_PREFIX" >&5
13754 echo "${ECHO_T}$NCURSES_WRAP_PREFIX" >&6
13756 NCURSES_WRAP_PREFIX=_nc_
13759 cat >>confdefs.h <<EOF
13760 #define NCURSES_WRAP_PREFIX "$NCURSES_WRAP_PREFIX"
13763 ###############################################################################
13765 ### use option --disable-echo to suppress full display compiling commands
13767 echo "$as_me:13767: checking if you want to see long compiling messages" >&5
13768 echo $ECHO_N "checking if you want to see long compiling messages... $ECHO_C" >&6
13770 # Check whether --enable-echo or --disable-echo was given.
13771 if test "${enable_echo+set}" = set; then
13772 enableval="$enable_echo"
13773 test "$enableval" != no && enableval=yes
13774 if test "$enableval" != "yes" ; then
13777 ECHO_LD='@echo linking $@;'
13778 RULE_CC='@echo compiling $<'
13779 SHOW_CC='@echo compiling $@'
13801 echo "$as_me:13801: result: $enableval" >&5
13802 echo "${ECHO_T}$enableval" >&6
13804 ### use option --enable-warnings to turn on all gcc warnings
13805 echo "$as_me:13805: checking if you want to see compiler warnings" >&5
13806 echo $ECHO_N "checking if you want to see compiler warnings... $ECHO_C" >&6
13808 # Check whether --enable-warnings or --disable-warnings was given.
13809 if test "${enable_warnings+set}" = set; then
13810 enableval="$enable_warnings"
13811 with_warnings=$enableval
13813 echo "$as_me:13813: result: $with_warnings" >&5
13814 echo "${ECHO_T}$with_warnings" >&6
13816 if test "x$with_warnings" = "xyes"; then
13818 ADAFLAGS="$ADAFLAGS -gnatg"
13820 if test "x$have_x" = xyes; then
13822 cf_save_LIBS_CF_CONST_X_STRING="$LIBS"
13823 cf_save_CFLAGS_CF_CONST_X_STRING="$CFLAGS"
13824 cf_save_CPPFLAGS_CF_CONST_X_STRING="$CPPFLAGS"
13825 LIBS="$LIBS ${X_PRE_LIBS} ${X_LIBS} ${X_EXTRA_LIBS}"
13826 for cf_X_CFLAGS in $X_CFLAGS
13828 case "x$cf_X_CFLAGS" in
13830 CPPFLAGS="$CPPFLAGS $cf_X_CFLAGS"
13833 CFLAGS="$CFLAGS $cf_X_CFLAGS"
13838 cat >conftest.$ac_ext <<_ACEOF
13839 #line 13839 "configure"
13840 #include "confdefs.h"
13842 #include <stdlib.h>
13843 #include <X11/Intrinsic.h>
13848 String foo = malloc(1)
13853 rm -f conftest.$ac_objext
13854 if { (eval echo "$as_me:13854: \"$ac_compile\"") >&5
13855 (eval $ac_compile) 2>&5
13857 echo "$as_me:13857: \$? = $ac_status" >&5
13858 (exit $ac_status); } &&
13859 { ac_try='test -s conftest.$ac_objext'
13860 { (eval echo "$as_me:13860: \"$ac_try\"") >&5
13861 (eval $ac_try) 2>&5
13863 echo "$as_me:13863: \$? = $ac_status" >&5
13864 (exit $ac_status); }; }; then
13866 echo "$as_me:13866: checking for X11/Xt const-feature" >&5
13867 echo $ECHO_N "checking for X11/Xt const-feature... $ECHO_C" >&6
13868 if test "${cf_cv_const_x_string+set}" = set; then
13869 echo $ECHO_N "(cached) $ECHO_C" >&6
13872 cat >conftest.$ac_ext <<_ACEOF
13873 #line 13873 "configure"
13874 #include "confdefs.h"
13876 #define _CONST_X_STRING /* X11R7.8 (perhaps) */
13877 #undef XTSTRINGDEFINES /* X11R5 and later */
13878 #include <stdlib.h>
13879 #include <X11/Intrinsic.h>
13884 String foo = malloc(1); *foo = 0
13889 rm -f conftest.$ac_objext
13890 if { (eval echo "$as_me:13890: \"$ac_compile\"") >&5
13891 (eval $ac_compile) 2>&5
13893 echo "$as_me:13893: \$? = $ac_status" >&5
13894 (exit $ac_status); } &&
13895 { ac_try='test -s conftest.$ac_objext'
13896 { (eval echo "$as_me:13896: \"$ac_try\"") >&5
13897 (eval $ac_try) 2>&5
13899 echo "$as_me:13899: \$? = $ac_status" >&5
13900 (exit $ac_status); }; }; then
13902 cf_cv_const_x_string=no
13905 echo "$as_me: failed program was:" >&5
13906 cat conftest.$ac_ext >&5
13908 cf_cv_const_x_string=yes
13911 rm -f conftest.$ac_objext conftest.$ac_ext
13914 echo "$as_me:13914: result: $cf_cv_const_x_string" >&5
13915 echo "${ECHO_T}$cf_cv_const_x_string" >&6
13917 LIBS="$cf_save_LIBS_CF_CONST_X_STRING"
13918 CFLAGS="$cf_save_CFLAGS_CF_CONST_X_STRING"
13919 CPPFLAGS="$cf_save_CPPFLAGS_CF_CONST_X_STRING"
13921 case $cf_cv_const_x_string in
13924 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13925 CPPFLAGS="${CPPFLAGS}-DXTSTRINGDEFINES"
13930 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13931 CPPFLAGS="${CPPFLAGS}-D_CONST_X_STRING"
13937 echo "$as_me: failed program was:" >&5
13938 cat conftest.$ac_ext >&5
13940 rm -f conftest.$ac_objext conftest.$ac_ext
13942 cat > conftest.$ac_ext <<EOF
13943 #line 13943 "${as_me:-configure}"
13944 int main(int argc, char *argv[]) { return (argv[argc-1] == 0) ; }
13946 if test "$INTEL_COMPILER" = yes
13948 # The "-wdXXX" options suppress warnings:
13949 # remark #1419: external declaration in primary source file
13950 # remark #1683: explicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem)
13951 # remark #1684: conversion from pointer to same-sized integral type (potential portability problem)
13952 # remark #193: zero used for undefined preprocessing identifier
13953 # remark #593: variable "curs_sb_left_arrow" was set but never used
13954 # remark #810: conversion from "int" to "Dimension={unsigned short}" may lose significant bits
13955 # remark #869: parameter "tw" was never referenced
13956 # remark #981: operands are evaluated in unspecified order
13957 # warning #279: controlling expression is constant
13959 { echo "$as_me:13959: checking for $CC warning options..." >&5
13960 echo "$as_me: checking for $CC warning options..." >&6;}
13961 cf_save_CFLAGS="$CFLAGS"
13962 EXTRA_CFLAGS="-Wall"
13974 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
13975 if { (eval echo "$as_me:13975: \"$ac_compile\"") >&5
13976 (eval $ac_compile) 2>&5
13978 echo "$as_me:13978: \$? = $ac_status" >&5
13979 (exit $ac_status); }; then
13980 test -n "$verbose" && echo "$as_me:13980: result: ... -$cf_opt" >&5
13981 echo "${ECHO_T}... -$cf_opt" >&6
13982 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
13985 CFLAGS="$cf_save_CFLAGS"
13986 elif test "$GCC" = yes && test "$GCC_VERSION" != "unknown"
13988 { echo "$as_me:13988: checking for $CC warning options..." >&5
13989 echo "$as_me: checking for $CC warning options..." >&6;}
13990 cf_save_CFLAGS="$CFLAGS"
13993 test "$with_ext_const" = yes && cf_warn_CONST="Wwrite-strings"
13994 cf_gcc_warnings="Wignored-qualifiers Wlogical-op Wvarargs"
13995 test "x$CLANG_COMPILER" = xyes && cf_gcc_warnings=
13996 for cf_opt in W Wall \
13997 Wbad-function-cast \
14000 Wdeclaration-after-statement \
14003 Wmissing-declarations \
14004 Wmissing-prototypes \
14008 Wstrict-prototypes \
14009 Wundef Wno-inline $cf_gcc_warnings $cf_warn_CONST Wno-unknown-pragmas Wswitch-enum
14011 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
14012 if { (eval echo "$as_me:14012: \"$ac_compile\"") >&5
14013 (eval $ac_compile) 2>&5
14015 echo "$as_me:14015: \$? = $ac_status" >&5
14016 (exit $ac_status); }; then
14017 test -n "$verbose" && echo "$as_me:14017: result: ... -$cf_opt" >&5
14018 echo "${ECHO_T}... -$cf_opt" >&6
14021 case $GCC_VERSION in
14023 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
14025 echo "${as_me:-configure}:14025: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
14031 case $GCC_VERSION in
14033 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
14035 echo "${as_me:-configure}:14035: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
14041 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
14044 CFLAGS="$cf_save_CFLAGS"
14050 if test "$GCC" = yes
14052 cat > conftest.i <<EOF
14054 #define GCC_PRINTF 0
14057 #define GCC_SCANF 0
14059 #ifndef GCC_NORETURN
14060 #define GCC_NORETURN /* nothing */
14063 #define GCC_UNUSED /* nothing */
14066 if test "$GCC" = yes
14068 { echo "$as_me:14068: checking for $CC __attribute__ directives..." >&5
14069 echo "$as_me: checking for $CC __attribute__ directives..." >&6;}
14070 cat > conftest.$ac_ext <<EOF
14071 #line 14071 "${as_me:-configure}"
14072 #include "confdefs.h"
14073 #include "conftest.h"
14074 #include "conftest.i"
14076 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
14078 #define GCC_PRINTFLIKE(fmt,var) /*nothing*/
14081 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
14083 #define GCC_SCANFLIKE(fmt,var) /*nothing*/
14085 extern void wow(char *,...) GCC_SCANFLIKE(1,2);
14086 extern void oops(char *,...) GCC_PRINTFLIKE(1,2) GCC_NORETURN;
14087 extern void foo(void) GCC_NORETURN;
14088 int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { return 0; }
14090 cf_printf_attribute=no
14091 cf_scanf_attribute=no
14092 for cf_attribute in scanf printf unused noreturn
14095 cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14097 cf_directive="__attribute__(($cf_attribute))"
14098 echo "checking for $CC $cf_directive" 1>&5
14100 case $cf_attribute in
14102 cf_printf_attribute=yes
14103 cat >conftest.h <<EOF
14104 #define GCC_$cf_ATTRIBUTE 1
14108 cf_scanf_attribute=yes
14109 cat >conftest.h <<EOF
14110 #define GCC_$cf_ATTRIBUTE 1
14114 cat >conftest.h <<EOF
14115 #define GCC_$cf_ATTRIBUTE $cf_directive
14120 if { (eval echo "$as_me:14120: \"$ac_compile\"") >&5
14121 (eval $ac_compile) 2>&5
14123 echo "$as_me:14123: \$? = $ac_status" >&5
14124 (exit $ac_status); }; then
14125 test -n "$verbose" && echo "$as_me:14125: result: ... $cf_attribute" >&5
14126 echo "${ECHO_T}... $cf_attribute" >&6
14127 cat conftest.h >>confdefs.h
14128 case $cf_attribute in
14131 cat >>confdefs.h <<EOF
14132 #define GCC_NORETURN $cf_directive
14137 cf_value='/* nothing */'
14138 if test "$cf_printf_attribute" != no ; then
14139 cf_value='__attribute__((format(printf,fmt,var)))'
14141 cat >>confdefs.h <<\EOF
14142 #define GCC_PRINTF 1
14147 cat >>confdefs.h <<EOF
14148 #define GCC_PRINTFLIKE(fmt,var) $cf_value
14153 cf_value='/* nothing */'
14154 if test "$cf_scanf_attribute" != no ; then
14155 cf_value='__attribute__((format(scanf,fmt,var)))'
14157 cat >>confdefs.h <<\EOF
14158 #define GCC_SCANF 1
14163 cat >>confdefs.h <<EOF
14164 #define GCC_SCANFLIKE(fmt,var) $cf_value
14170 cat >>confdefs.h <<EOF
14171 #define GCC_UNUSED $cf_directive
14179 fgrep define conftest.i >>confdefs.h
14184 ### use option --enable-assertions to turn on generation of assertion code
14185 echo "$as_me:14185: checking if you want to enable runtime assertions" >&5
14186 echo $ECHO_N "checking if you want to enable runtime assertions... $ECHO_C" >&6
14188 # Check whether --enable-assertions or --disable-assertions was given.
14189 if test "${enable_assertions+set}" = set; then
14190 enableval="$enable_assertions"
14191 with_assertions=$enableval
14195 echo "$as_me:14195: result: $with_assertions" >&5
14196 echo "${ECHO_T}$with_assertions" >&6
14199 if test "$with_assertions" = no
14201 CPPFLAGS="$CPPFLAGS -DNDEBUG"
14204 ADAFLAGS="$ADAFLAGS -gnata"
14209 ### use option --disable-leaks to suppress "permanent" leaks, for testing
14211 cat >>confdefs.h <<\EOF
14212 #define HAVE_NC_ALLOC_H 1
14215 ### use option --enable-expanded to generate certain macros as functions
14217 # Check whether --enable-expanded or --disable-expanded was given.
14218 if test "${enable_expanded+set}" = set; then
14219 enableval="$enable_expanded"
14220 test "$enableval" = yes &&
14221 cat >>confdefs.h <<\EOF
14222 #define NCURSES_EXPANDED 1
14227 ### use option --disable-macros to suppress macros in favor of functions
14229 # Check whether --enable-macros or --disable-macros was given.
14230 if test "${enable_macros+set}" = set; then
14231 enableval="$enable_macros"
14232 test "$enableval" = no &&
14233 cat >>confdefs.h <<\EOF
14234 #define NCURSES_NOMACROS 1
14239 # Normally we only add trace() to the debug-library. Allow this to be
14240 # extended to all models of the ncurses library:
14242 case "$CFLAGS $CPPFLAGS" in
14248 echo "$as_me:14248: checking whether to add trace feature to all models" >&5
14249 echo $ECHO_N "checking whether to add trace feature to all models... $ECHO_C" >&6
14251 # Check whether --with-trace or --without-trace was given.
14252 if test "${with_trace+set}" = set; then
14253 withval="$with_trace"
14254 cf_with_trace=$withval
14256 cf_with_trace=$cf_all_traces
14258 echo "$as_me:14258: result: $cf_with_trace" >&5
14259 echo "${ECHO_T}$cf_with_trace" >&6
14261 if test "$cf_with_trace" = yes ; then
14267 cf_new_extra_cppflags=
14269 for cf_add_cflags in -DTRACE
14271 case $cf_fix_cppflags in
14273 case $cf_add_cflags in
14274 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
14275 case $cf_add_cflags in
14277 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
14279 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14280 && test -z "${cf_tst_cflags}" \
14281 && cf_fix_cppflags=yes
14283 if test $cf_fix_cppflags = yes ; then
14285 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14286 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14289 elif test "${cf_tst_cflags}" = "\"'" ; then
14291 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14292 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14298 case "$CPPFLAGS" in
14302 case $cf_add_cflags in
14304 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
14306 CPPFLAGS=`echo "$CPPFLAGS" | \
14307 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
14308 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
14313 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
14314 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
14321 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
14322 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
14329 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14330 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14332 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
14334 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14335 && test -z "${cf_tst_cflags}" \
14336 && cf_fix_cppflags=no
14341 if test -n "$cf_new_cflags" ; then
14343 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
14344 CFLAGS="${CFLAGS}$cf_new_cflags"
14348 if test -n "$cf_new_cppflags" ; then
14350 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
14351 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
14355 if test -n "$cf_new_extra_cppflags" ; then
14357 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
14358 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
14366 echo "$as_me:14366: checking if we want to use GNAT projects" >&5
14367 echo $ECHO_N "checking if we want to use GNAT projects... $ECHO_C" >&6
14369 # Check whether --enable-gnat-projects or --disable-gnat-projects was given.
14370 if test "${enable_gnat_projects+set}" = set; then
14371 enableval="$enable_gnat_projects"
14372 test "$enableval" != no && enableval=yes
14373 if test "$enableval" != "yes" ; then
14374 enable_gnat_projects=no
14376 enable_gnat_projects=yes
14380 enable_gnat_projects=yes
14383 echo "$as_me:14383: result: $enable_gnat_projects" >&5
14384 echo "${ECHO_T}$enable_gnat_projects" >&6
14386 ### Checks for libraries.
14387 case $cf_cv_system_name in
14391 echo "$as_me:14391: checking for gettimeofday" >&5
14392 echo $ECHO_N "checking for gettimeofday... $ECHO_C" >&6
14393 if test "${ac_cv_func_gettimeofday+set}" = set; then
14394 echo $ECHO_N "(cached) $ECHO_C" >&6
14396 cat >conftest.$ac_ext <<_ACEOF
14397 #line 14397 "configure"
14398 #include "confdefs.h"
14399 #define gettimeofday autoconf_temporary
14400 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
14401 #undef gettimeofday
14407 /* We use char because int might match the return type of a gcc2
14408 builtin and then its argument prototype would still apply. */
14409 char gettimeofday (void);
14415 /* The GNU C library defines stubs for functions which it implements
14416 to always fail with ENOSYS. Some functions are actually named
14417 something starting with __ and the normal name is an alias. */
14418 #if defined (__stub_gettimeofday) || defined (__stub___gettimeofday)
14419 #error found stub for gettimeofday
14422 return gettimeofday ();
14427 rm -f conftest.$ac_objext conftest$ac_exeext
14428 if { (eval echo "$as_me:14428: \"$ac_link\"") >&5
14429 (eval $ac_link) 2>&5
14431 echo "$as_me:14431: \$? = $ac_status" >&5
14432 (exit $ac_status); } &&
14433 { ac_try='test -s conftest$ac_exeext'
14434 { (eval echo "$as_me:14434: \"$ac_try\"") >&5
14435 (eval $ac_try) 2>&5
14437 echo "$as_me:14437: \$? = $ac_status" >&5
14438 (exit $ac_status); }; }; then
14439 ac_cv_func_gettimeofday=yes
14441 echo "$as_me: failed program was:" >&5
14442 cat conftest.$ac_ext >&5
14443 ac_cv_func_gettimeofday=no
14445 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14447 echo "$as_me:14447: result: $ac_cv_func_gettimeofday" >&5
14448 echo "${ECHO_T}$ac_cv_func_gettimeofday" >&6
14449 if test $ac_cv_func_gettimeofday = yes; then
14450 cat >>confdefs.h <<\EOF
14451 #define HAVE_GETTIMEOFDAY 1
14456 echo "$as_me:14456: checking for gettimeofday in -lbsd" >&5
14457 echo $ECHO_N "checking for gettimeofday in -lbsd... $ECHO_C" >&6
14458 if test "${ac_cv_lib_bsd_gettimeofday+set}" = set; then
14459 echo $ECHO_N "(cached) $ECHO_C" >&6
14461 ac_check_lib_save_LIBS=$LIBS
14463 cat >conftest.$ac_ext <<_ACEOF
14464 #line 14464 "configure"
14465 #include "confdefs.h"
14467 /* Override any gcc2 internal prototype to avoid an error. */
14471 /* We use char because int might match the return type of a gcc2
14472 builtin and then its argument prototype would still apply. */
14473 char gettimeofday ();
14482 rm -f conftest.$ac_objext conftest$ac_exeext
14483 if { (eval echo "$as_me:14483: \"$ac_link\"") >&5
14484 (eval $ac_link) 2>&5
14486 echo "$as_me:14486: \$? = $ac_status" >&5
14487 (exit $ac_status); } &&
14488 { ac_try='test -s conftest$ac_exeext'
14489 { (eval echo "$as_me:14489: \"$ac_try\"") >&5
14490 (eval $ac_try) 2>&5
14492 echo "$as_me:14492: \$? = $ac_status" >&5
14493 (exit $ac_status); }; }; then
14494 ac_cv_lib_bsd_gettimeofday=yes
14496 echo "$as_me: failed program was:" >&5
14497 cat conftest.$ac_ext >&5
14498 ac_cv_lib_bsd_gettimeofday=no
14500 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14501 LIBS=$ac_check_lib_save_LIBS
14503 echo "$as_me:14503: result: $ac_cv_lib_bsd_gettimeofday" >&5
14504 echo "${ECHO_T}$ac_cv_lib_bsd_gettimeofday" >&6
14505 if test $ac_cv_lib_bsd_gettimeofday = yes; then
14507 cat >>confdefs.h <<\EOF
14508 #define HAVE_GETTIMEOFDAY 1
14518 ### Checks for header files.
14519 echo "$as_me:14519: checking for ANSI C header files" >&5
14520 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
14521 if test "${ac_cv_header_stdc+set}" = set; then
14522 echo $ECHO_N "(cached) $ECHO_C" >&6
14524 cat >conftest.$ac_ext <<_ACEOF
14525 #line 14525 "configure"
14526 #include "confdefs.h"
14527 #include <stdlib.h>
14528 #include <stdarg.h>
14529 #include <string.h>
14533 if { (eval echo "$as_me:14533: \"$ac_cpp conftest.$ac_ext\"") >&5
14534 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
14536 egrep -v '^ *\+' conftest.er1 >conftest.err
14538 cat conftest.err >&5
14539 echo "$as_me:14539: \$? = $ac_status" >&5
14540 (exit $ac_status); } >/dev/null; then
14541 if test -s conftest.err; then
14542 ac_cpp_err=$ac_c_preproc_warn_flag
14549 if test -z "$ac_cpp_err"; then
14550 ac_cv_header_stdc=yes
14552 echo "$as_me: failed program was:" >&5
14553 cat conftest.$ac_ext >&5
14554 ac_cv_header_stdc=no
14556 rm -f conftest.err conftest.$ac_ext
14558 if test $ac_cv_header_stdc = yes; then
14559 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
14560 cat >conftest.$ac_ext <<_ACEOF
14561 #line 14561 "configure"
14562 #include "confdefs.h"
14563 #include <string.h>
14566 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14567 egrep "memchr" >/dev/null 2>&1; then
14570 ac_cv_header_stdc=no
14576 if test $ac_cv_header_stdc = yes; then
14577 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
14578 cat >conftest.$ac_ext <<_ACEOF
14579 #line 14579 "configure"
14580 #include "confdefs.h"
14581 #include <stdlib.h>
14584 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14585 egrep "free" >/dev/null 2>&1; then
14588 ac_cv_header_stdc=no
14594 if test $ac_cv_header_stdc = yes; then
14595 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
14596 if test "$cross_compiling" = yes; then
14599 cat >conftest.$ac_ext <<_ACEOF
14600 #line 14600 "configure"
14601 #include "confdefs.h"
14603 #if ((' ' & 0x0FF) == 0x020)
14604 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
14605 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
14607 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
14608 || ('j' <= (c) && (c) <= 'r') \
14609 || ('s' <= (c) && (c) <= 'z'))
14610 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
14613 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
14618 for (i = 0; i < 256; i++)
14619 if (XOR (islower (i), ISLOWER (i))
14620 || toupper (i) != TOUPPER (i))
14621 $ac_main_return(2);
14622 $ac_main_return (0);
14625 rm -f conftest$ac_exeext
14626 if { (eval echo "$as_me:14626: \"$ac_link\"") >&5
14627 (eval $ac_link) 2>&5
14629 echo "$as_me:14629: \$? = $ac_status" >&5
14630 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14631 { (eval echo "$as_me:14631: \"$ac_try\"") >&5
14632 (eval $ac_try) 2>&5
14634 echo "$as_me:14634: \$? = $ac_status" >&5
14635 (exit $ac_status); }; }; then
14638 echo "$as_me: program exited with status $ac_status" >&5
14639 echo "$as_me: failed program was:" >&5
14640 cat conftest.$ac_ext >&5
14641 ac_cv_header_stdc=no
14643 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14647 echo "$as_me:14647: result: $ac_cv_header_stdc" >&5
14648 echo "${ECHO_T}$ac_cv_header_stdc" >&6
14649 if test $ac_cv_header_stdc = yes; then
14651 cat >>confdefs.h <<\EOF
14652 #define STDC_HEADERS 1
14657 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
14659 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
14660 inttypes.h stdint.h unistd.h
14662 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
14663 echo "$as_me:14663: checking for $ac_header" >&5
14664 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14665 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14666 echo $ECHO_N "(cached) $ECHO_C" >&6
14668 cat >conftest.$ac_ext <<_ACEOF
14669 #line 14669 "configure"
14670 #include "confdefs.h"
14671 $ac_includes_default
14672 #include <$ac_header>
14674 rm -f conftest.$ac_objext
14675 if { (eval echo "$as_me:14675: \"$ac_compile\"") >&5
14676 (eval $ac_compile) 2>&5
14678 echo "$as_me:14678: \$? = $ac_status" >&5
14679 (exit $ac_status); } &&
14680 { ac_try='test -s conftest.$ac_objext'
14681 { (eval echo "$as_me:14681: \"$ac_try\"") >&5
14682 (eval $ac_try) 2>&5
14684 echo "$as_me:14684: \$? = $ac_status" >&5
14685 (exit $ac_status); }; }; then
14686 eval "$as_ac_Header=yes"
14688 echo "$as_me: failed program was:" >&5
14689 cat conftest.$ac_ext >&5
14690 eval "$as_ac_Header=no"
14692 rm -f conftest.$ac_objext conftest.$ac_ext
14694 echo "$as_me:14694: result: `eval echo '${'$as_ac_Header'}'`" >&5
14695 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
14696 if test `eval echo '${'$as_ac_Header'}'` = yes; then
14697 cat >>confdefs.h <<EOF
14698 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
14704 echo "$as_me:14704: checking for signed char" >&5
14705 echo $ECHO_N "checking for signed char... $ECHO_C" >&6
14706 if test "${ac_cv_type_signed_char+set}" = set; then
14707 echo $ECHO_N "(cached) $ECHO_C" >&6
14709 cat >conftest.$ac_ext <<_ACEOF
14710 #line 14710 "configure"
14711 #include "confdefs.h"
14712 $ac_includes_default
14716 if ((signed char *) 0)
14718 if (sizeof (signed char))
14724 rm -f conftest.$ac_objext
14725 if { (eval echo "$as_me:14725: \"$ac_compile\"") >&5
14726 (eval $ac_compile) 2>&5
14728 echo "$as_me:14728: \$? = $ac_status" >&5
14729 (exit $ac_status); } &&
14730 { ac_try='test -s conftest.$ac_objext'
14731 { (eval echo "$as_me:14731: \"$ac_try\"") >&5
14732 (eval $ac_try) 2>&5
14734 echo "$as_me:14734: \$? = $ac_status" >&5
14735 (exit $ac_status); }; }; then
14736 ac_cv_type_signed_char=yes
14738 echo "$as_me: failed program was:" >&5
14739 cat conftest.$ac_ext >&5
14740 ac_cv_type_signed_char=no
14742 rm -f conftest.$ac_objext conftest.$ac_ext
14744 echo "$as_me:14744: result: $ac_cv_type_signed_char" >&5
14745 echo "${ECHO_T}$ac_cv_type_signed_char" >&6
14747 echo "$as_me:14747: checking size of signed char" >&5
14748 echo $ECHO_N "checking size of signed char... $ECHO_C" >&6
14749 if test "${ac_cv_sizeof_signed_char+set}" = set; then
14750 echo $ECHO_N "(cached) $ECHO_C" >&6
14752 if test "$ac_cv_type_signed_char" = yes; then
14753 if test "$cross_compiling" = yes; then
14754 # Depending upon the size, compute the lo and hi bounds.
14755 cat >conftest.$ac_ext <<_ACEOF
14756 #line 14756 "configure"
14757 #include "confdefs.h"
14758 $ac_includes_default
14762 int _array_ [1 - 2 * !((sizeof (signed char)) >= 0)]
14767 rm -f conftest.$ac_objext
14768 if { (eval echo "$as_me:14768: \"$ac_compile\"") >&5
14769 (eval $ac_compile) 2>&5
14771 echo "$as_me:14771: \$? = $ac_status" >&5
14772 (exit $ac_status); } &&
14773 { ac_try='test -s conftest.$ac_objext'
14774 { (eval echo "$as_me:14774: \"$ac_try\"") >&5
14775 (eval $ac_try) 2>&5
14777 echo "$as_me:14777: \$? = $ac_status" >&5
14778 (exit $ac_status); }; }; then
14781 cat >conftest.$ac_ext <<_ACEOF
14782 #line 14782 "configure"
14783 #include "confdefs.h"
14784 $ac_includes_default
14788 int _array_ [1 - 2 * !((sizeof (signed char)) <= $ac_mid)]
14793 rm -f conftest.$ac_objext
14794 if { (eval echo "$as_me:14794: \"$ac_compile\"") >&5
14795 (eval $ac_compile) 2>&5
14797 echo "$as_me:14797: \$? = $ac_status" >&5
14798 (exit $ac_status); } &&
14799 { ac_try='test -s conftest.$ac_objext'
14800 { (eval echo "$as_me:14800: \"$ac_try\"") >&5
14801 (eval $ac_try) 2>&5
14803 echo "$as_me:14803: \$? = $ac_status" >&5
14804 (exit $ac_status); }; }; then
14805 ac_hi=$ac_mid; break
14807 echo "$as_me: failed program was:" >&5
14808 cat conftest.$ac_ext >&5
14809 ac_lo=`expr $ac_mid + 1`; ac_mid=`expr 2 '*' $ac_mid + 1`
14811 rm -f conftest.$ac_objext conftest.$ac_ext
14814 echo "$as_me: failed program was:" >&5
14815 cat conftest.$ac_ext >&5
14818 cat >conftest.$ac_ext <<_ACEOF
14819 #line 14819 "configure"
14820 #include "confdefs.h"
14821 $ac_includes_default
14825 int _array_ [1 - 2 * !((sizeof (signed char)) >= $ac_mid)]
14830 rm -f conftest.$ac_objext
14831 if { (eval echo "$as_me:14831: \"$ac_compile\"") >&5
14832 (eval $ac_compile) 2>&5
14834 echo "$as_me:14834: \$? = $ac_status" >&5
14835 (exit $ac_status); } &&
14836 { ac_try='test -s conftest.$ac_objext'
14837 { (eval echo "$as_me:14837: \"$ac_try\"") >&5
14838 (eval $ac_try) 2>&5
14840 echo "$as_me:14840: \$? = $ac_status" >&5
14841 (exit $ac_status); }; }; then
14842 ac_lo=$ac_mid; break
14844 echo "$as_me: failed program was:" >&5
14845 cat conftest.$ac_ext >&5
14846 ac_hi=`expr $ac_mid - 1`; ac_mid=`expr 2 '*' $ac_mid`
14848 rm -f conftest.$ac_objext conftest.$ac_ext
14851 rm -f conftest.$ac_objext conftest.$ac_ext
14852 # Binary search between lo and hi bounds.
14853 while test "x$ac_lo" != "x$ac_hi"; do
14854 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
14855 cat >conftest.$ac_ext <<_ACEOF
14856 #line 14856 "configure"
14857 #include "confdefs.h"
14858 $ac_includes_default
14862 int _array_ [1 - 2 * !((sizeof (signed char)) <= $ac_mid)]
14867 rm -f conftest.$ac_objext
14868 if { (eval echo "$as_me:14868: \"$ac_compile\"") >&5
14869 (eval $ac_compile) 2>&5
14871 echo "$as_me:14871: \$? = $ac_status" >&5
14872 (exit $ac_status); } &&
14873 { ac_try='test -s conftest.$ac_objext'
14874 { (eval echo "$as_me:14874: \"$ac_try\"") >&5
14875 (eval $ac_try) 2>&5
14877 echo "$as_me:14877: \$? = $ac_status" >&5
14878 (exit $ac_status); }; }; then
14881 echo "$as_me: failed program was:" >&5
14882 cat conftest.$ac_ext >&5
14883 ac_lo=`expr $ac_mid + 1`
14885 rm -f conftest.$ac_objext conftest.$ac_ext
14887 ac_cv_sizeof_signed_char=$ac_lo
14889 if test "$cross_compiling" = yes; then
14890 { { echo "$as_me:14890: error: cannot run test program while cross compiling" >&5
14891 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
14892 { (exit 1); exit 1; }; }
14894 cat >conftest.$ac_ext <<_ACEOF
14895 #line 14895 "configure"
14896 #include "confdefs.h"
14897 $ac_includes_default
14901 FILE *f = fopen ("conftest.val", "w");
14903 $ac_main_return (1);
14904 fprintf (f, "%d", (sizeof (signed char)));
14910 rm -f conftest$ac_exeext
14911 if { (eval echo "$as_me:14911: \"$ac_link\"") >&5
14912 (eval $ac_link) 2>&5
14914 echo "$as_me:14914: \$? = $ac_status" >&5
14915 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14916 { (eval echo "$as_me:14916: \"$ac_try\"") >&5
14917 (eval $ac_try) 2>&5
14919 echo "$as_me:14919: \$? = $ac_status" >&5
14920 (exit $ac_status); }; }; then
14921 ac_cv_sizeof_signed_char=`cat conftest.val`
14923 echo "$as_me: program exited with status $ac_status" >&5
14924 echo "$as_me: failed program was:" >&5
14925 cat conftest.$ac_ext >&5
14927 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14932 ac_cv_sizeof_signed_char=0
14935 echo "$as_me:14935: result: $ac_cv_sizeof_signed_char" >&5
14936 echo "${ECHO_T}$ac_cv_sizeof_signed_char" >&6
14937 cat >>confdefs.h <<EOF
14938 #define SIZEOF_SIGNED_CHAR $ac_cv_sizeof_signed_char
14941 echo "$as_me:14941: checking for ANSI C header files" >&5
14942 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
14943 if test "${ac_cv_header_stdc+set}" = set; then
14944 echo $ECHO_N "(cached) $ECHO_C" >&6
14946 cat >conftest.$ac_ext <<_ACEOF
14947 #line 14947 "configure"
14948 #include "confdefs.h"
14949 #include <stdlib.h>
14950 #include <stdarg.h>
14951 #include <string.h>
14955 if { (eval echo "$as_me:14955: \"$ac_cpp conftest.$ac_ext\"") >&5
14956 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
14958 egrep -v '^ *\+' conftest.er1 >conftest.err
14960 cat conftest.err >&5
14961 echo "$as_me:14961: \$? = $ac_status" >&5
14962 (exit $ac_status); } >/dev/null; then
14963 if test -s conftest.err; then
14964 ac_cpp_err=$ac_c_preproc_warn_flag
14971 if test -z "$ac_cpp_err"; then
14972 ac_cv_header_stdc=yes
14974 echo "$as_me: failed program was:" >&5
14975 cat conftest.$ac_ext >&5
14976 ac_cv_header_stdc=no
14978 rm -f conftest.err conftest.$ac_ext
14980 if test $ac_cv_header_stdc = yes; then
14981 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
14982 cat >conftest.$ac_ext <<_ACEOF
14983 #line 14983 "configure"
14984 #include "confdefs.h"
14985 #include <string.h>
14988 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14989 egrep "memchr" >/dev/null 2>&1; then
14992 ac_cv_header_stdc=no
14998 if test $ac_cv_header_stdc = yes; then
14999 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
15000 cat >conftest.$ac_ext <<_ACEOF
15001 #line 15001 "configure"
15002 #include "confdefs.h"
15003 #include <stdlib.h>
15006 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
15007 egrep "free" >/dev/null 2>&1; then
15010 ac_cv_header_stdc=no
15016 if test $ac_cv_header_stdc = yes; then
15017 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
15018 if test "$cross_compiling" = yes; then
15021 cat >conftest.$ac_ext <<_ACEOF
15022 #line 15022 "configure"
15023 #include "confdefs.h"
15025 #if ((' ' & 0x0FF) == 0x020)
15026 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
15027 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
15029 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
15030 || ('j' <= (c) && (c) <= 'r') \
15031 || ('s' <= (c) && (c) <= 'z'))
15032 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
15035 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
15040 for (i = 0; i < 256; i++)
15041 if (XOR (islower (i), ISLOWER (i))
15042 || toupper (i) != TOUPPER (i))
15043 $ac_main_return(2);
15044 $ac_main_return (0);
15047 rm -f conftest$ac_exeext
15048 if { (eval echo "$as_me:15048: \"$ac_link\"") >&5
15049 (eval $ac_link) 2>&5
15051 echo "$as_me:15051: \$? = $ac_status" >&5
15052 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15053 { (eval echo "$as_me:15053: \"$ac_try\"") >&5
15054 (eval $ac_try) 2>&5
15056 echo "$as_me:15056: \$? = $ac_status" >&5
15057 (exit $ac_status); }; }; then
15060 echo "$as_me: program exited with status $ac_status" >&5
15061 echo "$as_me: failed program was:" >&5
15062 cat conftest.$ac_ext >&5
15063 ac_cv_header_stdc=no
15065 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15069 echo "$as_me:15069: result: $ac_cv_header_stdc" >&5
15070 echo "${ECHO_T}$ac_cv_header_stdc" >&6
15071 if test $ac_cv_header_stdc = yes; then
15073 cat >>confdefs.h <<\EOF
15074 #define STDC_HEADERS 1
15079 ac_header_dirent=no
15080 for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
15081 as_ac_Header=`echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
15082 echo "$as_me:15082: checking for $ac_hdr that defines DIR" >&5
15083 echo $ECHO_N "checking for $ac_hdr that defines DIR... $ECHO_C" >&6
15084 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15085 echo $ECHO_N "(cached) $ECHO_C" >&6
15087 cat >conftest.$ac_ext <<_ACEOF
15088 #line 15088 "configure"
15089 #include "confdefs.h"
15090 #include <sys/types.h>
15102 rm -f conftest.$ac_objext
15103 if { (eval echo "$as_me:15103: \"$ac_compile\"") >&5
15104 (eval $ac_compile) 2>&5
15106 echo "$as_me:15106: \$? = $ac_status" >&5
15107 (exit $ac_status); } &&
15108 { ac_try='test -s conftest.$ac_objext'
15109 { (eval echo "$as_me:15109: \"$ac_try\"") >&5
15110 (eval $ac_try) 2>&5
15112 echo "$as_me:15112: \$? = $ac_status" >&5
15113 (exit $ac_status); }; }; then
15114 eval "$as_ac_Header=yes"
15116 echo "$as_me: failed program was:" >&5
15117 cat conftest.$ac_ext >&5
15118 eval "$as_ac_Header=no"
15120 rm -f conftest.$ac_objext conftest.$ac_ext
15122 echo "$as_me:15122: result: `eval echo '${'$as_ac_Header'}'`" >&5
15123 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15124 if test `eval echo '${'$as_ac_Header'}'` = yes; then
15125 cat >>confdefs.h <<EOF
15126 #define `echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
15129 ac_header_dirent=$ac_hdr; break
15133 # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
15134 if test $ac_header_dirent = dirent.h; then
15135 echo "$as_me:15135: checking for opendir in -ldir" >&5
15136 echo $ECHO_N "checking for opendir in -ldir... $ECHO_C" >&6
15137 if test "${ac_cv_lib_dir_opendir+set}" = set; then
15138 echo $ECHO_N "(cached) $ECHO_C" >&6
15140 ac_check_lib_save_LIBS=$LIBS
15142 cat >conftest.$ac_ext <<_ACEOF
15143 #line 15143 "configure"
15144 #include "confdefs.h"
15146 /* Override any gcc2 internal prototype to avoid an error. */
15150 /* We use char because int might match the return type of a gcc2
15151 builtin and then its argument prototype would still apply. */
15161 rm -f conftest.$ac_objext conftest$ac_exeext
15162 if { (eval echo "$as_me:15162: \"$ac_link\"") >&5
15163 (eval $ac_link) 2>&5
15165 echo "$as_me:15165: \$? = $ac_status" >&5
15166 (exit $ac_status); } &&
15167 { ac_try='test -s conftest$ac_exeext'
15168 { (eval echo "$as_me:15168: \"$ac_try\"") >&5
15169 (eval $ac_try) 2>&5
15171 echo "$as_me:15171: \$? = $ac_status" >&5
15172 (exit $ac_status); }; }; then
15173 ac_cv_lib_dir_opendir=yes
15175 echo "$as_me: failed program was:" >&5
15176 cat conftest.$ac_ext >&5
15177 ac_cv_lib_dir_opendir=no
15179 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15180 LIBS=$ac_check_lib_save_LIBS
15182 echo "$as_me:15182: result: $ac_cv_lib_dir_opendir" >&5
15183 echo "${ECHO_T}$ac_cv_lib_dir_opendir" >&6
15184 if test $ac_cv_lib_dir_opendir = yes; then
15189 echo "$as_me:15189: checking for opendir in -lx" >&5
15190 echo $ECHO_N "checking for opendir in -lx... $ECHO_C" >&6
15191 if test "${ac_cv_lib_x_opendir+set}" = set; then
15192 echo $ECHO_N "(cached) $ECHO_C" >&6
15194 ac_check_lib_save_LIBS=$LIBS
15196 cat >conftest.$ac_ext <<_ACEOF
15197 #line 15197 "configure"
15198 #include "confdefs.h"
15200 /* Override any gcc2 internal prototype to avoid an error. */
15204 /* We use char because int might match the return type of a gcc2
15205 builtin and then its argument prototype would still apply. */
15215 rm -f conftest.$ac_objext conftest$ac_exeext
15216 if { (eval echo "$as_me:15216: \"$ac_link\"") >&5
15217 (eval $ac_link) 2>&5
15219 echo "$as_me:15219: \$? = $ac_status" >&5
15220 (exit $ac_status); } &&
15221 { ac_try='test -s conftest$ac_exeext'
15222 { (eval echo "$as_me:15222: \"$ac_try\"") >&5
15223 (eval $ac_try) 2>&5
15225 echo "$as_me:15225: \$? = $ac_status" >&5
15226 (exit $ac_status); }; }; then
15227 ac_cv_lib_x_opendir=yes
15229 echo "$as_me: failed program was:" >&5
15230 cat conftest.$ac_ext >&5
15231 ac_cv_lib_x_opendir=no
15233 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15234 LIBS=$ac_check_lib_save_LIBS
15236 echo "$as_me:15236: result: $ac_cv_lib_x_opendir" >&5
15237 echo "${ECHO_T}$ac_cv_lib_x_opendir" >&6
15238 if test $ac_cv_lib_x_opendir = yes; then
15244 echo "$as_me:15244: checking whether time.h and sys/time.h may both be included" >&5
15245 echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
15246 if test "${ac_cv_header_time+set}" = set; then
15247 echo $ECHO_N "(cached) $ECHO_C" >&6
15249 cat >conftest.$ac_ext <<_ACEOF
15250 #line 15250 "configure"
15251 #include "confdefs.h"
15252 #include <sys/types.h>
15253 #include <sys/time.h>
15259 if ((struct tm *) 0)
15265 rm -f conftest.$ac_objext
15266 if { (eval echo "$as_me:15266: \"$ac_compile\"") >&5
15267 (eval $ac_compile) 2>&5
15269 echo "$as_me:15269: \$? = $ac_status" >&5
15270 (exit $ac_status); } &&
15271 { ac_try='test -s conftest.$ac_objext'
15272 { (eval echo "$as_me:15272: \"$ac_try\"") >&5
15273 (eval $ac_try) 2>&5
15275 echo "$as_me:15275: \$? = $ac_status" >&5
15276 (exit $ac_status); }; }; then
15277 ac_cv_header_time=yes
15279 echo "$as_me: failed program was:" >&5
15280 cat conftest.$ac_ext >&5
15281 ac_cv_header_time=no
15283 rm -f conftest.$ac_objext conftest.$ac_ext
15285 echo "$as_me:15285: result: $ac_cv_header_time" >&5
15286 echo "${ECHO_T}$ac_cv_header_time" >&6
15287 if test $ac_cv_header_time = yes; then
15289 cat >>confdefs.h <<\EOF
15290 #define TIME_WITH_SYS_TIME 1
15295 ### checks for compiler characteristics
15297 ac_cpp='$CPP $CPPFLAGS'
15298 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
15299 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
15300 ac_compiler_gnu=$ac_cv_c_compiler_gnu
15301 ac_main_return=return
15303 echo "$as_me:15303: checking for an ANSI C-conforming const" >&5
15304 echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
15305 if test "${ac_cv_c_const+set}" = set; then
15306 echo $ECHO_N "(cached) $ECHO_C" >&6
15308 cat >conftest.$ac_ext <<_ACEOF
15309 #line 15309 "configure"
15310 #include "confdefs.h"
15315 /* FIXME: Include the comments suggested by Paul. */
15316 #ifndef __cplusplus
15317 /* Ultrix mips cc rejects this. */
15318 typedef int charset[2];
15320 /* SunOS 4.1.1 cc rejects this. */
15321 char const *const *ccp;
15323 /* NEC SVR4.0.2 mips cc rejects this. */
15324 struct point {int x, y;};
15325 static struct point const zero = {0,0};
15326 /* AIX XL C 1.02.0.0 rejects this.
15327 It does not let you subtract one const X* pointer from another in
15328 an arm of an if-expression whose if-part is not a constant
15330 const char *g = "string";
15331 ccp = &g + (g ? g-g : 0);
15332 /* HPUX 7.0 cc rejects these. */
15335 ccp = (char const *const *) p;
15336 { /* SCO 3.2v4 cc rejects this. */
15338 char const *s = 0 ? (char *) 0 : (char const *) 0;
15342 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
15343 int x[] = {25, 17};
15344 const int *foo = &x[0];
15347 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
15348 typedef const int *iptr;
15352 { /* AIX XL C 1.02.0.0 rejects this saying
15353 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
15354 struct s { int j; const int *ap[3]; };
15355 struct s *b; b->j = 5;
15357 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
15358 const int foo = 10;
15366 rm -f conftest.$ac_objext
15367 if { (eval echo "$as_me:15367: \"$ac_compile\"") >&5
15368 (eval $ac_compile) 2>&5
15370 echo "$as_me:15370: \$? = $ac_status" >&5
15371 (exit $ac_status); } &&
15372 { ac_try='test -s conftest.$ac_objext'
15373 { (eval echo "$as_me:15373: \"$ac_try\"") >&5
15374 (eval $ac_try) 2>&5
15376 echo "$as_me:15376: \$? = $ac_status" >&5
15377 (exit $ac_status); }; }; then
15380 echo "$as_me: failed program was:" >&5
15381 cat conftest.$ac_ext >&5
15384 rm -f conftest.$ac_objext conftest.$ac_ext
15386 echo "$as_me:15386: result: $ac_cv_c_const" >&5
15387 echo "${ECHO_T}$ac_cv_c_const" >&6
15388 if test $ac_cv_c_const = no; then
15390 cat >>confdefs.h <<\EOF
15396 ### Checks for external-data
15398 echo "$as_me:15398: checking if data-only library module links" >&5
15399 echo $ECHO_N "checking if data-only library module links... $ECHO_C" >&6
15400 if test "${cf_cv_link_dataonly+set}" = set; then
15401 echo $ECHO_N "(cached) $ECHO_C" >&6
15405 cat >conftest.$ac_ext <<EOF
15406 #line 15406 "configure"
15407 int testdata[3] = { 123, 456, 789 };
15409 if { (eval echo "$as_me:15409: \"$ac_compile\"") >&5
15410 (eval $ac_compile) 2>&5
15412 echo "$as_me:15412: \$? = $ac_status" >&5
15413 (exit $ac_status); } ; then
15414 mv conftest.o data.o && \
15415 ( $AR $ARFLAGS conftest.a data.o ) 2>&5 1>/dev/null
15417 rm -f conftest.$ac_ext data.o
15418 cat >conftest.$ac_ext <<EOF
15419 #line 15419 "configure"
15423 ${cf_cv_main_return:-return}(1); /* I'm told this linker is broken */
15425 extern int testdata[3];
15426 return testdata[0] == 123
15427 && testdata[1] == 456
15428 && testdata[2] == 789;
15432 if { (eval echo "$as_me:15432: \"$ac_compile\"") >&5
15433 (eval $ac_compile) 2>&5
15435 echo "$as_me:15435: \$? = $ac_status" >&5
15436 (exit $ac_status); }; then
15437 mv conftest.o func.o && \
15438 ( $AR $ARFLAGS conftest.a func.o ) 2>&5 1>/dev/null
15440 rm -f conftest.$ac_ext func.o
15441 ( eval $RANLIB conftest.a ) 2>&5 >/dev/null
15442 cf_saveLIBS="$LIBS"
15443 LIBS="conftest.a $LIBS"
15444 if test "$cross_compiling" = yes; then
15445 cf_cv_link_dataonly=unknown
15447 cat >conftest.$ac_ext <<_ACEOF
15448 #line 15448 "configure"
15449 #include "confdefs.h"
15453 extern int testfunc();
15454 ${cf_cv_main_return:-return} (!testfunc());
15458 rm -f conftest$ac_exeext
15459 if { (eval echo "$as_me:15459: \"$ac_link\"") >&5
15460 (eval $ac_link) 2>&5
15462 echo "$as_me:15462: \$? = $ac_status" >&5
15463 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15464 { (eval echo "$as_me:15464: \"$ac_try\"") >&5
15465 (eval $ac_try) 2>&5
15467 echo "$as_me:15467: \$? = $ac_status" >&5
15468 (exit $ac_status); }; }; then
15469 cf_cv_link_dataonly=yes
15471 echo "$as_me: program exited with status $ac_status" >&5
15472 echo "$as_me: failed program was:" >&5
15473 cat conftest.$ac_ext >&5
15474 cf_cv_link_dataonly=no
15476 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15478 LIBS="$cf_saveLIBS"
15482 echo "$as_me:15482: result: $cf_cv_link_dataonly" >&5
15483 echo "${ECHO_T}$cf_cv_link_dataonly" >&6
15485 if test "$cf_cv_link_dataonly" = no ; then
15487 cat >>confdefs.h <<\EOF
15488 #define BROKEN_LINKER 1
15494 ### Checks for library functions.
15500 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15501 echo "$as_me:15501: checking for $ac_header" >&5
15502 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15503 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15504 echo $ECHO_N "(cached) $ECHO_C" >&6
15506 cat >conftest.$ac_ext <<_ACEOF
15507 #line 15507 "configure"
15508 #include "confdefs.h"
15509 #include <$ac_header>
15511 if { (eval echo "$as_me:15511: \"$ac_cpp conftest.$ac_ext\"") >&5
15512 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15514 egrep -v '^ *\+' conftest.er1 >conftest.err
15516 cat conftest.err >&5
15517 echo "$as_me:15517: \$? = $ac_status" >&5
15518 (exit $ac_status); } >/dev/null; then
15519 if test -s conftest.err; then
15520 ac_cpp_err=$ac_c_preproc_warn_flag
15527 if test -z "$ac_cpp_err"; then
15528 eval "$as_ac_Header=yes"
15530 echo "$as_me: failed program was:" >&5
15531 cat conftest.$ac_ext >&5
15532 eval "$as_ac_Header=no"
15534 rm -f conftest.err conftest.$ac_ext
15536 echo "$as_me:15536: result: `eval echo '${'$as_ac_Header'}'`" >&5
15537 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15538 if test `eval echo '${'$as_ac_Header'}'` = yes; then
15539 cat >>confdefs.h <<EOF
15540 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
15546 echo "$as_me:15546: checking for working mkstemp" >&5
15547 echo $ECHO_N "checking for working mkstemp... $ECHO_C" >&6
15548 if test "${cf_cv_func_mkstemp+set}" = set; then
15549 echo $ECHO_N "(cached) $ECHO_C" >&6
15553 if test "$cross_compiling" = yes; then
15554 cf_cv_func_mkstemp=maybe
15556 cat >conftest.$ac_ext <<_ACEOF
15557 #line 15557 "configure"
15558 #include "confdefs.h"
15560 #include <sys/types.h>
15561 #ifdef HAVE_UNISTD_H
15562 #include <unistd.h>
15564 #include <stdlib.h>
15566 #include <string.h>
15567 #include <sys/stat.h>
15570 char *tmpl = "conftestXXXXXX";
15578 for (n = 0; n < 2; ++n) {
15579 strcpy(name[n], tmpl);
15580 if ((fd = mkstemp(name[n])) >= 0) {
15581 if (!strcmp(name[n], tmpl)
15582 || stat(name[n], &sb) != 0
15583 || (sb.st_mode & S_IFMT) != S_IFREG
15584 || (sb.st_mode & 077) != 0) {
15591 && !strcmp(name[0], name[1]))
15593 ${cf_cv_main_return:-return}(result);
15597 rm -f conftest$ac_exeext
15598 if { (eval echo "$as_me:15598: \"$ac_link\"") >&5
15599 (eval $ac_link) 2>&5
15601 echo "$as_me:15601: \$? = $ac_status" >&5
15602 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15603 { (eval echo "$as_me:15603: \"$ac_try\"") >&5
15604 (eval $ac_try) 2>&5
15606 echo "$as_me:15606: \$? = $ac_status" >&5
15607 (exit $ac_status); }; }; then
15608 cf_cv_func_mkstemp=yes
15611 echo "$as_me: program exited with status $ac_status" >&5
15612 echo "$as_me: failed program was:" >&5
15613 cat conftest.$ac_ext >&5
15614 cf_cv_func_mkstemp=no
15617 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15621 echo "$as_me:15621: result: $cf_cv_func_mkstemp" >&5
15622 echo "${ECHO_T}$cf_cv_func_mkstemp" >&6
15623 if test "x$cf_cv_func_mkstemp" = xmaybe ; then
15624 echo "$as_me:15624: checking for mkstemp" >&5
15625 echo $ECHO_N "checking for mkstemp... $ECHO_C" >&6
15626 if test "${ac_cv_func_mkstemp+set}" = set; then
15627 echo $ECHO_N "(cached) $ECHO_C" >&6
15629 cat >conftest.$ac_ext <<_ACEOF
15630 #line 15630 "configure"
15631 #include "confdefs.h"
15632 #define mkstemp autoconf_temporary
15633 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
15640 /* We use char because int might match the return type of a gcc2
15641 builtin and then its argument prototype would still apply. */
15642 char mkstemp (void);
15648 /* The GNU C library defines stubs for functions which it implements
15649 to always fail with ENOSYS. Some functions are actually named
15650 something starting with __ and the normal name is an alias. */
15651 #if defined (__stub_mkstemp) || defined (__stub___mkstemp)
15652 #error found stub for mkstemp
15660 rm -f conftest.$ac_objext conftest$ac_exeext
15661 if { (eval echo "$as_me:15661: \"$ac_link\"") >&5
15662 (eval $ac_link) 2>&5
15664 echo "$as_me:15664: \$? = $ac_status" >&5
15665 (exit $ac_status); } &&
15666 { ac_try='test -s conftest$ac_exeext'
15667 { (eval echo "$as_me:15667: \"$ac_try\"") >&5
15668 (eval $ac_try) 2>&5
15670 echo "$as_me:15670: \$? = $ac_status" >&5
15671 (exit $ac_status); }; }; then
15672 ac_cv_func_mkstemp=yes
15674 echo "$as_me: failed program was:" >&5
15675 cat conftest.$ac_ext >&5
15676 ac_cv_func_mkstemp=no
15678 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15680 echo "$as_me:15680: result: $ac_cv_func_mkstemp" >&5
15681 echo "${ECHO_T}$ac_cv_func_mkstemp" >&6
15684 if test "x$cf_cv_func_mkstemp" = xyes || test "x$ac_cv_func_mkstemp" = xyes ; then
15686 cat >>confdefs.h <<\EOF
15687 #define HAVE_MKSTEMP 1
15692 if test -z "$cf_user_CFLAGS" && test "$with_no_leaks" = no ; then
15693 CFLAGS=`echo ${CFLAGS} | sed -e 's%-g %%' -e 's%-g$%%'`
15694 CXXFLAGS=`echo ${CXXFLAGS} | sed -e 's%-g %%' -e 's%-g$%%'`
15698 if test "$cf_with_ada" != "no" ; then
15700 for cf_prog_gnat in gnat gnatmake gprconfig gprbuild
15703 cf_upper_prog_gnat=`echo "${cf_prog_gnat}" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
15705 unset ac_cv_path_cf_TEMP_gnat
15707 # Extract the first word of "$cf_prog_gnat", so it can be a program name with args.
15708 set dummy $cf_prog_gnat; ac_word=$2
15709 echo "$as_me:15709: checking for $ac_word" >&5
15710 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
15711 if test "${ac_cv_path_cf_TEMP_gnat+set}" = set; then
15712 echo $ECHO_N "(cached) $ECHO_C" >&6
15714 case $cf_TEMP_gnat in
15716 ac_cv_path_cf_TEMP_gnat="$cf_TEMP_gnat" # Let the user override the test with a path.
15719 ac_save_IFS=$IFS; IFS=$ac_path_separator
15721 for ac_dir in $ac_dummy; do
15723 test -z "$ac_dir" && ac_dir=.
15724 if $as_executable_p "$ac_dir/$ac_word"; then
15725 ac_cv_path_cf_TEMP_gnat="$ac_dir/$ac_word"
15726 echo "$as_me:15726: found $ac_dir/$ac_word" >&5
15731 test -z "$ac_cv_path_cf_TEMP_gnat" && ac_cv_path_cf_TEMP_gnat="no"
15735 cf_TEMP_gnat=$ac_cv_path_cf_TEMP_gnat
15737 if test -n "$cf_TEMP_gnat"; then
15738 echo "$as_me:15738: result: $cf_TEMP_gnat" >&5
15739 echo "${ECHO_T}$cf_TEMP_gnat" >&6
15741 echo "$as_me:15741: result: no" >&5
15742 echo "${ECHO_T}no" >&6
15745 eval cf_cv_PATH_$cf_upper_prog_gnat=$ac_cv_path_cf_TEMP_gnat
15747 if test "x$cf_TEMP_gnat" != xno; then
15748 unset cf_cv_gnat_version
15751 echo "$as_me:15751: checking for $cf_prog_gnat version" >&5
15752 echo $ECHO_N "checking for $cf_prog_gnat version... $ECHO_C" >&6
15753 if test "${cf_cv_gnat_version+set}" = set; then
15754 echo $ECHO_N "(cached) $ECHO_C" >&6
15757 cf_cv_gnat_version=`$cf_prog_gnat --version 2>&1 | \
15758 grep '[0-9].[0-9][0-9]*' |\
15759 sed -e '2,$d' -e 's/[^0-9 \.]//g' -e 's/^[ ]*//' -e 's/ .*//'`
15762 echo "$as_me:15762: result: $cf_cv_gnat_version" >&5
15763 echo "${ECHO_T}$cf_cv_gnat_version" >&6
15764 test -z "$cf_cv_gnat_version" && cf_cv_gnat_version=no
15765 eval cf_TEMP_gnat=$cf_cv_gnat_version; unset cf_cv_gnat_version
15768 eval cf_cv_VERSION_$cf_upper_prog_gnat=$cf_TEMP_gnat
15771 unset cf_cv_gnat_version
15772 unset ac_cv_path_cf_TEMP_gnat
15775 if test "x$cf_cv_VERSION_GNATMAKE" = "xno"; then
15777 cf_cv_prog_gnat_correct=no
15779 cf_ada_make=gnatmake
15780 if test "x$cf_cv_VERSION_GPRCONFIG" = "xno"; then
15781 # gprconfig is newer than gnatmake; we can continue...
15784 rm -rf conftest* *~conftest*
15785 if mkdir conftest.src
15789 for cf_gprconfig in Ada C
15791 echo "$as_me:15791: checking for gprconfig name for $cf_gprconfig" >&5
15792 echo $ECHO_N "checking for gprconfig name for $cf_gprconfig... $ECHO_C" >&6
15793 if test $cf_gprconfig = C
15795 for cf_gprconfig_param in \
15796 $cf_gprconfig,,,,GNATGCC \
15797 $cf_gprconfig,,,,GCC \
15800 cf_gprconfig_value=`echo s| gprconfig --config=$cf_gprconfig_param 2>&5 | ${AWK:-awk} '/^\*/{print $3;}' | head -n 1`
15801 test -n "$cf_gprconfig_value" && break
15804 cf_gprconfig_param=$cf_gprconfig
15805 cf_gprconfig_value=`echo s| gprconfig --config=$cf_gprconfig_param 2>&5 | ${AWK:-awk} '/^\*/{print $3;}' | head -n 1`
15807 if test -n "$cf_gprconfig_value"
15809 eval cf_ada_config_$cf_gprconfig=$cf_gprconfig_value
15810 echo "$as_me:15810: result: $cf_gprconfig_value" >&5
15811 echo "${ECHO_T}$cf_gprconfig_value" >&6
15813 echo "$as_me:15813: result: missing" >&5
15814 echo "${ECHO_T}missing" >&6
15820 rm -rf conftest* *~conftest*
15823 if test "x$cf_ada_config" != "x#"
15826 echo "$as_me:15826: checking for gnat version" >&5
15827 echo $ECHO_N "checking for gnat version... $ECHO_C" >&6
15828 if test "${cf_cv_gnat_version+set}" = set; then
15829 echo $ECHO_N "(cached) $ECHO_C" >&6
15832 cf_cv_gnat_version=`${cf_ada_make:-gnatmake} --version 2>&1 | \
15833 grep '[0-9].[0-9][0-9]*' |\
15834 sed -e '2,$d' -e 's/[^0-9 \.]//g' -e 's/^[ ]*//' -e 's/ .*//'`
15837 echo "$as_me:15837: result: $cf_cv_gnat_version" >&5
15838 echo "${ECHO_T}$cf_cv_gnat_version" >&6
15839 test -z "$cf_cv_gnat_version" && cf_cv_gnat_version=no
15841 case $cf_cv_gnat_version in
15842 (3.1[1-9]*|3.[2-9]*|[4-9].*|20[0-9][0-9])
15843 cf_cv_prog_gnat_correct=yes
15846 { echo "$as_me:15846: WARNING: Unsupported GNAT version $cf_cv_gnat_version. We require 3.11 or better. Disabling Ada95 binding." >&5
15847 echo "$as_me: WARNING: Unsupported GNAT version $cf_cv_gnat_version. We require 3.11 or better. Disabling Ada95 binding." >&2;}
15848 cf_cv_prog_gnat_correct=no
15852 # Extract the first word of "m4", so it can be a program name with args.
15853 set dummy m4; ac_word=$2
15854 echo "$as_me:15854: checking for $ac_word" >&5
15855 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
15856 if test "${ac_cv_prog_M4_exists+set}" = set; then
15857 echo $ECHO_N "(cached) $ECHO_C" >&6
15859 if test -n "$M4_exists"; then
15860 ac_cv_prog_M4_exists="$M4_exists" # Let the user override the test.
15862 ac_save_IFS=$IFS; IFS=$ac_path_separator
15864 for ac_dir in $ac_dummy; do
15866 test -z "$ac_dir" && ac_dir=.
15867 $as_executable_p "$ac_dir/$ac_word" || continue
15868 ac_cv_prog_M4_exists="yes"
15869 echo "$as_me:15869: found $ac_dir/$ac_word" >&5
15873 test -z "$ac_cv_prog_M4_exists" && ac_cv_prog_M4_exists="no"
15876 M4_exists=$ac_cv_prog_M4_exists
15877 if test -n "$M4_exists"; then
15878 echo "$as_me:15878: result: $M4_exists" >&5
15879 echo "${ECHO_T}$M4_exists" >&6
15881 echo "$as_me:15881: result: no" >&5
15882 echo "${ECHO_T}no" >&6
15885 if test "$ac_cv_prog_M4_exists" = no; then
15886 cf_cv_prog_gnat_correct=no
15887 { echo "$as_me:15887: WARNING: Ada95 binding required program m4 not found. Ada95 binding disabled" >&5
15888 echo "$as_me: WARNING: Ada95 binding required program m4 not found. Ada95 binding disabled" >&2;}
15890 if test "$cf_cv_prog_gnat_correct" = yes; then
15891 echo "$as_me:15891: checking if GNAT works" >&5
15892 echo $ECHO_N "checking if GNAT works... $ECHO_C" >&6
15894 rm -rf conftest* *~conftest*
15895 cat >>conftest.ads <<CF_EOF
15896 procedure conftest;
15898 cat >>conftest.adb <<CF_EOF
15901 procedure conftest is
15903 Text_IO.Put ("Hello World");
15905 GNAT.OS_Lib.OS_Exit (0);
15908 if ( $cf_ada_make $ADAFLAGS conftest 1>&5 2>&1 ) ; then
15909 if ( ./conftest 1>&5 2>&1 ) ; then
15910 cf_cv_prog_gnat_correct=yes
15912 cf_cv_prog_gnat_correct=no
15915 cf_cv_prog_gnat_correct=no
15917 rm -rf conftest* *~conftest*
15919 echo "$as_me:15919: result: $cf_cv_prog_gnat_correct" >&5
15920 echo "${ECHO_T}$cf_cv_prog_gnat_correct" >&6
15923 cf_cv_prog_gnat_correct=no
15927 if test "$cf_cv_prog_gnat_correct" = yes; then
15929 echo "$as_me:15929: checking optimization options for ADAFLAGS" >&5
15930 echo $ECHO_N "checking optimization options for ADAFLAGS... $ECHO_C" >&6
15934 ADAFLAGS="$ADAFLAGS -g"
15940 cf_O_flag=`echo "$CFLAGS" |sed -e 's/^.*-O/-O/' -e 's/[ ].*//'`
15942 ADAFLAGS="$ADAFLAGS $cf_O_flag"
15946 echo "$as_me:15946: result: $ADAFLAGS" >&5
15947 echo "${ECHO_T}$ADAFLAGS" >&6
15949 echo "$as_me:15949: checking if GNATPREP supports -T option" >&5
15950 echo $ECHO_N "checking if GNATPREP supports -T option... $ECHO_C" >&6
15951 if test "${cf_cv_gnatprep_opt_t+set}" = set; then
15952 echo $ECHO_N "(cached) $ECHO_C" >&6
15955 cf_cv_gnatprep_opt_t=no
15956 gnatprep -T 2>/dev/null >/dev/null && cf_cv_gnatprep_opt_t=yes
15959 echo "$as_me:15959: result: $cf_cv_gnatprep_opt_t" >&5
15960 echo "${ECHO_T}$cf_cv_gnatprep_opt_t" >&6
15961 test "$cf_cv_gnatprep_opt_t" = yes && GNATPREP_OPTS="-T $GNATPREP_OPTS"
15963 echo "$as_me:15963: checking if GNAT supports generics" >&5
15964 echo $ECHO_N "checking if GNAT supports generics... $ECHO_C" >&6
15965 case $cf_cv_gnat_version in
15967 cf_gnat_generics=yes
15970 cf_gnat_generics=no
15973 echo "$as_me:15973: result: $cf_gnat_generics" >&5
15974 echo "${ECHO_T}$cf_gnat_generics" >&6
15976 if test "$cf_gnat_generics" = yes
15978 cf_compile_generics=generics
15979 cf_generic_objects="\${GENOBJS}"
15981 cf_compile_generics=
15982 cf_generic_objects=
15985 echo "$as_me:15985: checking if GNAT supports SIGINT" >&5
15986 echo $ECHO_N "checking if GNAT supports SIGINT... $ECHO_C" >&6
15987 if test "${cf_cv_gnat_sigint+set}" = set; then
15988 echo $ECHO_N "(cached) $ECHO_C" >&6
15991 rm -rf conftest* *~conftest*
15992 cat >>conftest.ads <<CF_EOF
15993 with Ada.Interrupts.Names;
15995 package ConfTest is
15997 pragma Warnings (Off); -- the next pragma exists since 3.11p
15998 pragma Unreserve_All_Interrupts;
15999 pragma Warnings (On);
16001 protected Process is
16003 function Continue return Boolean;
16004 pragma Attach_Handler (Stop, Ada.Interrupts.Names.SIGINT);
16006 Done : Boolean := False;
16011 cat >>conftest.adb <<CF_EOF
16012 package body ConfTest is
16013 protected body Process is
16018 function Continue return Boolean is
16025 if ( $cf_ada_make $ADAFLAGS conftest 1>&5 2>&1 ) ; then
16026 cf_cv_gnat_sigint=yes
16028 cf_cv_gnat_sigint=no
16030 rm -rf conftest* *~conftest*
16033 echo "$as_me:16033: result: $cf_cv_gnat_sigint" >&5
16034 echo "${ECHO_T}$cf_cv_gnat_sigint" >&6
16036 if test $cf_cv_gnat_sigint = yes ; then
16039 USE_GNAT_SIGINT="#"
16042 cf_gnat_libraries=no
16043 cf_gnat_projects=no
16045 if test "$enable_gnat_projects" != no ; then
16046 echo "$as_me:16046: checking if GNAT supports project files" >&5
16047 echo $ECHO_N "checking if GNAT supports project files... $ECHO_C" >&6
16048 case $cf_cv_gnat_version in
16052 case $cf_cv_system_name in
16056 rm -rf conftest* *~conftest*
16057 if mkdir conftest.src conftest.bin conftest.lib
16060 rm -rf conftest* *~conftest*
16061 cat >>library.gpr <<CF_EOF
16063 Kind := External ("LIB_KIND");
16064 for Library_Name use "ConfTest";
16065 for Object_Dir use ".";
16066 for Library_ALI_Dir use External("LIBRARY_DIR");
16067 for Library_Version use External ("SONAME");
16068 for Library_Kind use Kind;
16069 for Library_Dir use External("BUILD_DIR");
16070 Source_Dir := External ("SOURCE_DIR");
16071 for Source_Dirs use (Source_Dir);
16074 cat >>confpackage.ads <<CF_EOF
16075 package ConfPackage is
16076 procedure conftest;
16079 cat >>confpackage.adb <<CF_EOF
16081 package body ConfPackage is
16082 procedure conftest is
16084 Text_IO.Put ("Hello World");
16089 if ( $cf_ada_make $ADAFLAGS \
16091 -XBUILD_DIR=`cd ../conftest.bin;pwd` \
16092 -XLIBRARY_DIR=`cd ../conftest.lib;pwd` \
16093 -XSOURCE_DIR=`pwd` \
16094 -XSONAME=libConfTest.so.1 \
16095 -XLIB_KIND=static 1>&5 2>&1 ) ; then
16096 cf_gnat_projects=yes
16100 if test -f conftest.lib/confpackage.ali
16102 cf_gnat_libraries=yes
16104 rm -rf conftest* *~conftest*
16109 echo "$as_me:16109: result: $cf_gnat_projects" >&5
16110 echo "${ECHO_T}$cf_gnat_projects" >&6
16111 fi # enable_gnat_projects
16113 if test $cf_gnat_projects = yes
16115 echo "$as_me:16115: checking if GNAT supports libraries" >&5
16116 echo $ECHO_N "checking if GNAT supports libraries... $ECHO_C" >&6
16117 echo "$as_me:16117: result: $cf_gnat_libraries" >&5
16118 echo "${ECHO_T}$cf_gnat_libraries" >&6
16121 if test "$cf_gnat_projects" = yes
16123 USE_OLD_MAKERULES="#"
16124 USE_GNAT_PROJECTS=""
16126 USE_OLD_MAKERULES=""
16127 USE_GNAT_PROJECTS="#"
16130 if test "$cf_gnat_libraries" = yes
16132 USE_GNAT_LIBRARIES=""
16134 USE_GNAT_LIBRARIES="#"
16137 echo "$as_me:16137: checking for ada-compiler" >&5
16138 echo $ECHO_N "checking for ada-compiler... $ECHO_C" >&6
16140 # Check whether --with-ada-compiler or --without-ada-compiler was given.
16141 if test "${with_ada_compiler+set}" = set; then
16142 withval="$with_ada_compiler"
16143 cf_ada_compiler=$withval
16145 cf_ada_compiler=gnatmake
16148 echo "$as_me:16148: result: $cf_ada_compiler" >&5
16149 echo "${ECHO_T}$cf_ada_compiler" >&6
16151 cf_ada_package=terminal_interface
16153 echo "$as_me:16153: checking for ada-include" >&5
16154 echo $ECHO_N "checking for ada-include... $ECHO_C" >&6
16156 # Check whether --with-ada-include or --without-ada-include was given.
16157 if test "${with_ada_include+set}" = set; then
16158 withval="$with_ada_include"
16161 withval="${ADA_INCLUDE:-$prefix/share/ada/adainclude}"
16162 fi; if test -n "$prefix/share/ada/adainclude" ; then
16164 if test "x$prefix" != xNONE; then
16165 cf_path_syntax="$prefix"
16167 cf_path_syntax="$ac_default_prefix"
16170 case ".$withval" in
16171 (.\$\(*\)*|.\'*\'*)
16175 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
16177 (.\${*prefix}*|.\${*dir}*)
16178 eval withval="$withval"
16179 case ".$withval" in
16181 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
16186 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
16189 { { echo "$as_me:16189: error: expected a pathname, not \"$withval\"" >&5
16190 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
16191 { (exit 1); exit 1; }; }
16196 eval ADA_INCLUDE="$withval"
16198 echo "$as_me:16198: result: $ADA_INCLUDE" >&5
16199 echo "${ECHO_T}$ADA_INCLUDE" >&6
16201 echo "$as_me:16201: checking for ada-objects" >&5
16202 echo $ECHO_N "checking for ada-objects... $ECHO_C" >&6
16204 # Check whether --with-ada-objects or --without-ada-objects was given.
16205 if test "${with_ada_objects+set}" = set; then
16206 withval="$with_ada_objects"
16209 withval="${ADA_OBJECTS:-$prefix/lib/ada/adalib}"
16210 fi; if test -n "$prefix/lib/ada/adalib" ; then
16212 if test "x$prefix" != xNONE; then
16213 cf_path_syntax="$prefix"
16215 cf_path_syntax="$ac_default_prefix"
16218 case ".$withval" in
16219 (.\$\(*\)*|.\'*\'*)
16223 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
16225 (.\${*prefix}*|.\${*dir}*)
16226 eval withval="$withval"
16227 case ".$withval" in
16229 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
16234 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
16237 { { echo "$as_me:16237: error: expected a pathname, not \"$withval\"" >&5
16238 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
16239 { (exit 1); exit 1; }; }
16244 eval ADA_OBJECTS="$withval"
16246 echo "$as_me:16246: result: $ADA_OBJECTS" >&5
16247 echo "${ECHO_T}$ADA_OBJECTS" >&6
16249 echo "$as_me:16249: checking if an Ada95 shared-library should be built" >&5
16250 echo $ECHO_N "checking if an Ada95 shared-library should be built... $ECHO_C" >&6
16252 # Check whether --with-ada-sharedlib or --without-ada-sharedlib was given.
16253 if test "${with_ada_sharedlib+set}" = set; then
16254 withval="$with_ada_sharedlib"
16255 with_ada_sharedlib=$withval
16257 with_ada_sharedlib=no
16259 echo "$as_me:16259: result: $with_ada_sharedlib" >&5
16260 echo "${ECHO_T}$with_ada_sharedlib" >&6
16262 if test "x$with_ada_sharedlib" != xno
16264 if test "x$cf_gnat_projects" != xyes
16266 { echo "$as_me:16266: WARNING: disabling shared-library since GNAT projects are not supported" >&5
16267 echo "$as_me: WARNING: disabling shared-library since GNAT projects are not supported" >&2;}
16268 with_ada_sharedlib=no
16272 ADA_SHAREDLIB='lib$(LIB_NAME).so.1'
16273 MAKE_ADA_SHAREDLIB="#"
16275 if test "x$with_ada_sharedlib" != xno
16277 MAKE_ADA_SHAREDLIB=
16278 if test "x$with_ada_sharedlib" != xyes
16280 ADA_SHAREDLIB="$with_ada_sharedlib"
16284 # allow the Ada binding to be renamed
16286 echo "$as_me:16286: checking for ada-libname" >&5
16287 echo $ECHO_N "checking for ada-libname... $ECHO_C" >&6
16289 # Check whether --with-ada-libname or --without-ada-libname was given.
16290 if test "${with_ada_libname+set}" = set; then
16291 withval="$with_ada_libname"
16292 ADA_LIBNAME=$withval
16294 ADA_LIBNAME=AdaCurses
16296 case "x$ADA_LIBNAME" in
16298 ADA_LIBNAME=AdaCurses
16302 echo "$as_me:16302: result: $ADA_LIBNAME" >&5
16303 echo "${ECHO_T}$ADA_LIBNAME" >&6
16306 { { echo "$as_me:16306: error: No usable Ada compiler found" >&5
16307 echo "$as_me: error: No usable Ada compiler found" >&2;}
16308 { (exit 1); exit 1; }; }
16311 { { echo "$as_me:16311: error: The Ada compiler is needed for this package" >&5
16312 echo "$as_me: error: The Ada compiler is needed for this package" >&2;}
16313 { (exit 1); exit 1; }; }
16316 ################################################################################
16323 ### Construct the list of include-directories to be generated
16325 if test "$srcdir" != "."; then
16326 CPPFLAGS="-I\${srcdir}/../include $CPPFLAGS"
16328 CPPFLAGS="-I../include $CPPFLAGS"
16329 if test "$srcdir" != "."; then
16330 CPPFLAGS="-I\${srcdir} $CPPFLAGS"
16332 CPPFLAGS="-I. $CPPFLAGS"
16334 ACPPFLAGS="-I. -I../include -I../../include $ACPPFLAGS"
16335 if test "$srcdir" != "."; then
16336 ACPPFLAGS="-I\${srcdir}/../../include $ACPPFLAGS"
16338 if test "$GCC" != yes; then
16339 ACPPFLAGS="$ACPPFLAGS -I\${includedir}"
16340 elif test "$includedir" != "/usr/include"; then
16341 if test "$includedir" = '${prefix}/include' ; then
16342 if test x$prefix != x/usr ; then
16343 ACPPFLAGS="$ACPPFLAGS -I\${includedir}"
16346 ACPPFLAGS="$ACPPFLAGS -I\${includedir}"
16350 ### Build up pieces for makefile rules
16351 echo "$as_me:16351: checking default library suffix" >&5
16352 echo $ECHO_N "checking default library suffix... $ECHO_C" >&6
16354 case $DFT_LWR_MODEL in
16355 (libtool) DFT_ARG_SUFFIX='' ;;
16356 (normal) DFT_ARG_SUFFIX='' ;;
16357 (debug) DFT_ARG_SUFFIX='_g' ;;
16358 (profile) DFT_ARG_SUFFIX='_p' ;;
16359 (shared) DFT_ARG_SUFFIX='' ;;
16361 test -n "$LIB_SUFFIX" && DFT_ARG_SUFFIX="${LIB_SUFFIX}${DFT_ARG_SUFFIX}"
16362 echo "$as_me:16362: result: $DFT_ARG_SUFFIX" >&5
16363 echo "${ECHO_T}$DFT_ARG_SUFFIX" >&6
16365 echo "$as_me:16365: checking default library-dependency suffix" >&5
16366 echo $ECHO_N "checking default library-dependency suffix... $ECHO_C" >&6
16368 case X$DFT_LWR_MODEL in
16370 DFT_LIB_SUFFIX='.la'
16371 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
16374 DFT_LIB_SUFFIX='_g.a'
16375 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
16378 DFT_LIB_SUFFIX='_p.a'
16379 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
16382 case $cf_cv_system_name in
16384 DFT_LIB_SUFFIX='.so'
16385 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
16387 (cygwin*|msys*|mingw*)
16388 DFT_LIB_SUFFIX='.dll'
16389 DFT_DEP_SUFFIX='.dll.a'
16392 DFT_LIB_SUFFIX='.dylib'
16393 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
16398 DFT_LIB_SUFFIX='.so'
16399 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
16402 DFT_LIB_SUFFIX='.sl'
16403 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
16408 DFT_LIB_SUFFIX='.so'
16409 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
16414 DFT_LIB_SUFFIX='.a'
16415 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
16418 if test -n "${LIB_SUFFIX}${EXTRA_SUFFIX}"
16420 DFT_LIB_SUFFIX="${LIB_SUFFIX}${EXTRA_SUFFIX}${DFT_LIB_SUFFIX}"
16421 DFT_DEP_SUFFIX="${LIB_SUFFIX}${EXTRA_SUFFIX}${DFT_DEP_SUFFIX}"
16423 echo "$as_me:16423: result: $DFT_DEP_SUFFIX" >&5
16424 echo "${ECHO_T}$DFT_DEP_SUFFIX" >&6
16426 echo "$as_me:16426: checking default object directory" >&5
16427 echo $ECHO_N "checking default object directory... $ECHO_C" >&6
16429 case $DFT_LWR_MODEL in
16430 (libtool) DFT_OBJ_SUBDIR='obj_lo' ;;
16431 (normal) DFT_OBJ_SUBDIR='objects' ;;
16432 (debug) DFT_OBJ_SUBDIR='obj_g' ;;
16433 (profile) DFT_OBJ_SUBDIR='obj_p' ;;
16435 case $cf_cv_system_name in
16437 DFT_OBJ_SUBDIR='objects' ;;
16439 DFT_OBJ_SUBDIR='obj_s' ;;
16442 echo "$as_me:16442: result: $DFT_OBJ_SUBDIR" >&5
16443 echo "${ECHO_T}$DFT_OBJ_SUBDIR" >&6
16445 ### Set up low-level terminfo dependencies for makefiles.
16447 if test "$DFT_LWR_MODEL" = shared ; then
16448 case $cf_cv_system_name in
16450 # "lib" files have ".dll.a" suffix, "cyg" files have ".dll"
16453 # "lib" files have ".dll.a" suffix, "msys-" files have ".dll"
16458 USE_ARG_SUFFIX=${DFT_ARG_SUFFIX}
16460 USE_LIB_SUFFIX=${DFT_ARG_SUFFIX}
16462 USE_CFG_SUFFIX=${DFT_ARG_SUFFIX}
16464 ### Construct the list of subdirectories for which we'll customize makefiles
16465 ### with the appropriate compile-rules.
16467 SUB_MAKEFILES="gen/adacurses${USE_ARG_SUFFIX}-config:gen/adacurses-config.in"
16469 cat >>confdefs.h <<EOF
16470 #define NCURSES_PATHSEP '$PATH_SEPARATOR'
16473 ### Now that we're done running tests, add the compiler-warnings, if any
16478 cf_new_extra_cppflags=
16480 for cf_add_cflags in $EXTRA_CFLAGS
16482 case $cf_fix_cppflags in
16484 case $cf_add_cflags in
16485 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
16486 case $cf_add_cflags in
16488 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
16490 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
16491 && test -z "${cf_tst_cflags}" \
16492 && cf_fix_cppflags=yes
16494 if test $cf_fix_cppflags = yes ; then
16496 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
16497 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
16500 elif test "${cf_tst_cflags}" = "\"'" ; then
16502 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
16503 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
16509 case "$CPPFLAGS" in
16513 case $cf_add_cflags in
16515 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
16517 CPPFLAGS=`echo "$CPPFLAGS" | \
16518 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
16519 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
16524 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
16525 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
16532 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
16533 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
16540 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
16541 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
16543 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
16545 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
16546 && test -z "${cf_tst_cflags}" \
16547 && cf_fix_cppflags=no
16552 if test -n "$cf_new_cflags" ; then
16554 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
16555 CFLAGS="${CFLAGS}$cf_new_cflags"
16559 if test -n "$cf_new_cppflags" ; then
16561 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
16562 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
16566 if test -n "$cf_new_extra_cppflags" ; then
16568 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
16569 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
16573 ################################################################################
16579 NCURSES_SHLIB2="sh -c"
16581 ADA_SUBDIRS="include gen src doc"
16582 if test "x$cf_with_tests" != "xno" ; then
16583 ADA_SUBDIRS="$ADA_SUBDIRS samples"
16585 for cf_dir in $ADA_SUBDIRS
16587 SUB_MAKEFILES="$SUB_MAKEFILES $cf_dir/Makefile"
16594 # match layout used by make-tar.sh
16595 ADAHTML_DIR=../doc/ada
16597 if test "x$cross_compiling" = xyes ; then
16598 ADAGEN_LDFLAGS='$(CROSS_LDFLAGS)'
16600 ADAGEN_LDFLAGS='$(NATIVE_LDFLAGS)'
16603 ac_config_files="$ac_config_files $SUB_MAKEFILES src/library.gpr:src/library.gpr.in doc/adacurses${DFT_ARG_SUFFIX}-config.1:doc/MKada_config.in Makefile"
16604 ac_config_commands="$ac_config_commands default"
16605 cat >confcache <<\_ACEOF
16606 # This file is a shell script that caches the results of configure
16607 # tests run on this system so they can be shared between configure
16608 # scripts and configure runs, see configure's option --config-cache.
16609 # It is not useful on other systems. If it contains results you don't
16610 # want to keep, you may remove or edit it.
16612 # config.status only pays attention to the cache file if you give it
16613 # the --recheck option to rerun configure.
16615 # `ac_cv_env_foo' variables (set or unset) will be overriden when
16616 # loading this file, other *unset* `ac_cv_foo' will be assigned the
16617 # following values.
16621 # The following way of writing the cache mishandles newlines in values,
16622 # but we know of no workaround that is simple, portable, and efficient.
16623 # So, don't put newlines in cache variables' values.
16624 # Ultrix sh set writes to stderr and can't be redirected directly,
16625 # and sets the high bit in the cache file unless we assign to the vars.
16628 case `(ac_space=' '; set | grep ac_space) 2>&1` in
16630 # `set' does not quote correctly, so add quotes (double-quote
16631 # substitution turns \\\\ into \\, and sed turns \\ into \).
16634 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
16637 # `set' quotes correctly as required by POSIX, so do not add quotes.
16639 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
16646 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
16648 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
16650 if cmp -s $cache_file confcache; then :; else
16651 if test -w $cache_file; then
16652 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
16653 cat confcache >$cache_file
16655 echo "not updating unwritable cache $cache_file"
16660 test "x$prefix" = xNONE && prefix=$ac_default_prefix
16661 # Let make expand exec_prefix.
16662 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
16664 # VPATH may cause trouble with some makes, so we remove $(srcdir),
16665 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
16666 # trailing colons and then remove the whole line if VPATH becomes empty
16667 # (actually we leave an empty line to preserve line numbers).
16668 if test "x$srcdir" = x.; then
16669 ac_vpsub='/^[ ]*VPATH[ ]*=/{
16670 s/:*\$(srcdir):*/:/;
16671 s/:*\${srcdir}:*/:/;
16673 s/^\([^=]*=[ ]*\):*/\1/;
16679 DEFS=-DHAVE_CONFIG_H
16681 : ${CONFIG_STATUS=./config.status}
16682 ac_clean_files_save=$ac_clean_files
16683 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
16684 { echo "$as_me:16684: creating $CONFIG_STATUS" >&5
16685 echo "$as_me: creating $CONFIG_STATUS" >&6;}
16686 cat >$CONFIG_STATUS <<_ACEOF
16688 # Generated automatically by configure.
16689 # Run this file to recreate the current configuration.
16690 # Compiler output produced by configure, useful for debugging
16691 # configure, is in config.log if it exists.
16694 SHELL=\${CONFIG_SHELL-$SHELL}
16695 ac_cs_invocation="\$0 \$@"
16699 cat >>$CONFIG_STATUS <<\_ACEOF
16700 # Be Bourne compatible
16701 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
16704 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
16708 # Name of the executable.
16709 as_me=`echo "$0" |sed 's,.*[\\/],,'`
16711 if expr a : '\(a\)' >/dev/null 2>&1; then
16717 rm -f conf$$ conf$$.exe conf$$.file
16719 if ln -s conf$$.file conf$$ 2>/dev/null; then
16720 # We could just check for DJGPP; but this test a) works b) is more generic
16721 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
16722 if test -f conf$$.exe; then
16723 # Don't use ln at all; we don't have any links
16728 elif ln conf$$.file conf$$ 2>/dev/null; then
16733 rm -f conf$$ conf$$.exe conf$$.file
16735 as_executable_p="test -f"
16737 # Support unset when possible.
16738 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
16745 $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
16746 $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
16747 $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
16748 $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
16749 $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
16750 $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
16751 $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
16752 $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
16755 # We need space, tab and new line, in precisely that order.
16761 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
16767 # Files that config.status was made for.
16768 if test -n "$ac_config_files"; then
16769 echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
16772 if test -n "$ac_config_headers"; then
16773 echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
16776 if test -n "$ac_config_links"; then
16777 echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
16780 if test -n "$ac_config_commands"; then
16781 echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
16784 cat >>$CONFIG_STATUS <<\EOF
16787 \`$as_me' instantiates files from templates according to the
16788 current configuration.
16790 Usage: $0 [OPTIONS] [FILE]...
16792 -h, --help print this help, then exit
16793 -V, --version print version number, then exit
16794 -d, --debug don't remove temporary files
16795 --recheck update $as_me by reconfiguring in the same conditions
16796 --file=FILE[:TEMPLATE]
16797 instantiate the configuration file FILE
16798 --header=FILE[:TEMPLATE]
16799 instantiate the configuration header FILE
16801 Configuration files:
16804 Configuration headers:
16807 Configuration commands:
16810 Report bugs to <dickey@invisible-island.net>."
16813 cat >>$CONFIG_STATUS <<EOF
16816 configured by $0, generated by GNU Autoconf 2.52.20200111,
16817 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
16819 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
16820 Free Software Foundation, Inc.
16821 This config.status script is free software; the Free Software Foundation
16822 gives unlimited permission to copy, distribute and modify it."
16827 cat >>$CONFIG_STATUS <<\EOF
16828 # If no file are specified by the user, then we need to provide default
16829 # value. By we need to know if files were specified by the user.
16835 ac_option=`expr "x$1" : 'x\([^=]*\)='`
16836 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
16838 set dummy "$ac_option" "$ac_optarg" ${1+"$@"}
16842 *) # This is not an option, so the user has probably given explicit
16844 ac_need_defaults=false;;
16848 # Handling of the options.
16850 cat >>$CONFIG_STATUS <<EOF
16851 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
16852 echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion"
16853 exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;;
16855 cat >>$CONFIG_STATUS <<\EOF
16856 --version | --vers* | -V )
16857 echo "$ac_cs_version"; exit 0 ;;
16859 # Conflict between --help and --header
16860 { { echo "$as_me:16860: error: ambiguous option: $1
16861 Try \`$0 --help' for more information." >&5
16862 echo "$as_me: error: ambiguous option: $1
16863 Try \`$0 --help' for more information." >&2;}
16864 { (exit 1); exit 1; }; };;
16865 --help | --hel | -h )
16866 echo "$ac_cs_usage"; exit 0 ;;
16867 --debug | --d* | -d )
16869 --file | --fil | --fi | --f )
16871 CONFIG_FILES="$CONFIG_FILES $1"
16872 ac_need_defaults=false;;
16873 --header | --heade | --head | --hea )
16875 CONFIG_HEADERS="$CONFIG_HEADERS $1"
16876 ac_need_defaults=false;;
16878 # This is an error.
16879 -*) { { echo "$as_me:16879: error: unrecognized option: $1
16880 Try \`$0 --help' for more information." >&5
16881 echo "$as_me: error: unrecognized option: $1
16882 Try \`$0 --help' for more information." >&2;}
16883 { (exit 1); exit 1; }; } ;;
16885 *) ac_config_targets="$ac_config_targets $1" ;;
16894 ## ----------------------- ##
16895 ## Running config.status. ##
16896 ## ----------------------- ##
16898 This file was extended by $as_me 2.52.20200111, executed with
16899 CONFIG_FILES = $CONFIG_FILES
16900 CONFIG_HEADERS = $CONFIG_HEADERS
16901 CONFIG_LINKS = $CONFIG_LINKS
16902 CONFIG_COMMANDS = $CONFIG_COMMANDS
16903 > $ac_cs_invocation
16904 on `(hostname || uname -n) 2>/dev/null | sed 1q`
16909 cat >>$CONFIG_STATUS <<EOF
16911 # INIT-COMMANDS section.
16914 ### Special initialization commands, used to pass information from the
16915 ### configuration-run into config.status
16918 DFT_ARG_SUFFIX="$DFT_ARG_SUFFIX"
16919 DFT_LWR_MODEL="$DFT_LWR_MODEL"
16920 LIB_NAME="$LIB_NAME"
16921 LIB_PREFIX="$LIB_PREFIX"
16922 LIB_SUFFIX="$LIB_SUFFIX"
16924 NCURSES_MAJOR="$NCURSES_MAJOR"
16925 NCURSES_MINOR="$NCURSES_MINOR"
16926 NCURSES_PATCH="$NCURSES_PATCH"
16927 USE_OLD_MAKERULES="$USE_OLD_MAKERULES"
16928 cf_cv_abi_version="$cf_cv_abi_version"
16929 cf_cv_rel_version="$cf_cv_rel_version"
16930 cf_cv_rm_so_locs="$cf_cv_rm_so_locs"
16931 cf_cv_shared_soname='$cf_cv_shared_soname'
16932 cf_cv_shlib_version="$cf_cv_shlib_version"
16933 cf_cv_shlib_version_infix="$cf_cv_shlib_version_infix"
16934 cf_cv_system_name="$cf_cv_system_name"
16940 cat >>$CONFIG_STATUS <<\EOF
16941 for ac_config_target in $ac_config_targets
16943 case "$ac_config_target" in
16944 # Handling of arguments.
16945 "$SUB_MAKEFILES" ) CONFIG_FILES="$CONFIG_FILES $SUB_MAKEFILES" ;;
16946 "src/library.gpr" ) CONFIG_FILES="$CONFIG_FILES src/library.gpr:src/library.gpr.in" ;;
16947 "doc/adacurses${DFT_ARG_SUFFIX}-config.1" ) CONFIG_FILES="$CONFIG_FILES doc/adacurses${DFT_ARG_SUFFIX}-config.1:doc/MKada_config.in" ;;
16948 "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
16949 "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
16950 "include/ncurses_cfg.h" ) CONFIG_HEADERS="$CONFIG_HEADERS include/ncurses_cfg.h:include/ncurses_cfg.hin" ;;
16951 *) { { echo "$as_me:16951: error: invalid argument: $ac_config_target" >&5
16952 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
16953 { (exit 1); exit 1; }; };;
16957 # If the user did not use the arguments to specify the items to instantiate,
16958 # then the envvar interface is used. Set only those that are not.
16959 # We use the long form for the default assignment because of an extremely
16960 # bizarre bug on SunOS 4.1.3.
16961 if $ac_need_defaults; then
16962 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
16963 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
16964 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
16967 # Create a temporary directory, and hook for its removal unless debugging.
16970 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
16971 trap '{ (exit 1); exit 1; }' 1 2 13 15
16974 # Create a (secure) tmp directory for tmp files.
16977 tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` &&
16978 test -n "$tmp" && test -d "$tmp"
16981 tmp=$TMPDIR/cs$$-$RANDOM
16982 (umask 077 && mkdir $tmp)
16985 echo "$me: cannot create a temporary directory in $TMPDIR" >&2
16986 { (exit 1); exit 1; }
16991 cat >>$CONFIG_STATUS <<EOF
16994 # CONFIG_FILES section.
16997 # No need to generate the scripts if there are no CONFIG_FILES.
16998 # This happens for instance when ./config.status config.h
16999 if test -n "\$CONFIG_FILES"; then
17000 # Protect against being on the right side of a sed subst in config.status.
17001 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
17002 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
17003 s,@SHELL@,$SHELL,;t t
17004 s,@exec_prefix@,$exec_prefix,;t t
17005 s,@prefix@,$prefix,;t t
17006 s,@program_transform_name@,$program_transform_name,;t t
17007 s,@bindir@,$bindir,;t t
17008 s,@sbindir@,$sbindir,;t t
17009 s,@libexecdir@,$libexecdir,;t t
17010 s,@datarootdir@,$datarootdir,;t t
17011 s,@datadir@,$datadir,;t t
17012 s,@sysconfdir@,$sysconfdir,;t t
17013 s,@sharedstatedir@,$sharedstatedir,;t t
17014 s,@localstatedir@,$localstatedir,;t t
17015 s,@runstatedir@,$runstatedir,;t t
17016 s,@libdir@,$libdir,;t t
17017 s,@includedir@,$includedir,;t t
17018 s,@oldincludedir@,$oldincludedir,;t t
17019 s,@infodir@,$infodir,;t t
17020 s,@mandir@,$mandir,;t t
17021 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
17022 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
17023 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
17024 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
17025 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
17026 s,@build_alias@,$build_alias,;t t
17027 s,@host_alias@,$host_alias,;t t
17028 s,@target_alias@,$target_alias,;t t
17029 s,@ECHO_C@,$ECHO_C,;t t
17030 s,@ECHO_N@,$ECHO_N,;t t
17031 s,@ECHO_T@,$ECHO_T,;t t
17032 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
17033 s,@DEFS@,$DEFS,;t t
17034 s,@LIBS@,$LIBS,;t t
17035 s,@top_builddir@,$top_builddir,;t t
17036 s,@build@,$build,;t t
17037 s,@build_cpu@,$build_cpu,;t t
17038 s,@build_vendor@,$build_vendor,;t t
17039 s,@build_os@,$build_os,;t t
17040 s,@host@,$host,;t t
17041 s,@host_cpu@,$host_cpu,;t t
17042 s,@host_vendor@,$host_vendor,;t t
17043 s,@host_os@,$host_os,;t t
17044 s,@target@,$target,;t t
17045 s,@target_cpu@,$target_cpu,;t t
17046 s,@target_vendor@,$target_vendor,;t t
17047 s,@target_os@,$target_os,;t t
17049 s,@CFLAGS@,$CFLAGS,;t t
17050 s,@LDFLAGS@,$LDFLAGS,;t t
17051 s,@CPPFLAGS@,$CPPFLAGS,;t t
17052 s,@ac_ct_CC@,$ac_ct_CC,;t t
17053 s,@EXEEXT@,$EXEEXT,;t t
17054 s,@OBJEXT@,$OBJEXT,;t t
17055 s,@EXTRA_CPPFLAGS@,$EXTRA_CPPFLAGS,;t t
17058 s,@EGREP@,$EGREP,;t t
17059 s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
17060 s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
17061 s,@INSTALL_DATA@,$INSTALL_DATA,;t t
17062 s,@LN_S@,$LN_S,;t t
17063 s,@INSTALL_OPT_S@,$INSTALL_OPT_S,;t t
17064 s,@INSTALL_OPT_O@,$INSTALL_OPT_O,;t t
17065 s,@PKG_CONFIG@,$PKG_CONFIG,;t t
17066 s,@ac_pt_PKG_CONFIG@,$ac_pt_PKG_CONFIG,;t t
17067 s,@PKG_CONFIG_LIBDIR@,$PKG_CONFIG_LIBDIR,;t t
17068 s,@SET_MAKE@,$SET_MAKE,;t t
17069 s,@CTAGS@,$CTAGS,;t t
17070 s,@ETAGS@,$ETAGS,;t t
17071 s,@MAKE_LOWER_TAGS@,$MAKE_LOWER_TAGS,;t t
17072 s,@MAKE_UPPER_TAGS@,$MAKE_UPPER_TAGS,;t t
17073 s,@cf_cv_makeflags@,$cf_cv_makeflags,;t t
17074 s,@RANLIB@,$RANLIB,;t t
17075 s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
17077 s,@ac_ct_LD@,$ac_ct_LD,;t t
17079 s,@ac_ct_AR@,$ac_ct_AR,;t t
17080 s,@ARFLAGS@,$ARFLAGS,;t t
17081 s,@DESTDIR@,$DESTDIR,;t t
17082 s,@BUILD_CC@,$BUILD_CC,;t t
17083 s,@BUILD_CPP@,$BUILD_CPP,;t t
17084 s,@BUILD_CFLAGS@,$BUILD_CFLAGS,;t t
17085 s,@BUILD_CPPFLAGS@,$BUILD_CPPFLAGS,;t t
17086 s,@BUILD_LDFLAGS@,$BUILD_LDFLAGS,;t t
17087 s,@BUILD_LIBS@,$BUILD_LIBS,;t t
17088 s,@BUILD_EXEEXT@,$BUILD_EXEEXT,;t t
17089 s,@BUILD_OBJEXT@,$BUILD_OBJEXT,;t t
17090 s,@DFT_LWR_MODEL@,$DFT_LWR_MODEL,;t t
17091 s,@DFT_UPR_MODEL@,$DFT_UPR_MODEL,;t t
17092 s,@NCURSES_CONFIG@,$NCURSES_CONFIG,;t t
17093 s,@ac_ct_NCURSES_CONFIG@,$ac_ct_NCURSES_CONFIG,;t t
17094 s,@NCURSES_MAJOR@,$NCURSES_MAJOR,;t t
17095 s,@NCURSES_MINOR@,$NCURSES_MINOR,;t t
17096 s,@NCURSES_PATCH@,$NCURSES_PATCH,;t t
17097 s,@cf_cv_rel_version@,$cf_cv_rel_version,;t t
17098 s,@cf_cv_abi_version@,$cf_cv_abi_version,;t t
17099 s,@cf_cv_builtin_bool@,$cf_cv_builtin_bool,;t t
17100 s,@cf_cv_header_stdbool_h@,$cf_cv_header_stdbool_h,;t t
17101 s,@cf_cv_type_of_bool@,$cf_cv_type_of_bool,;t t
17102 s,@LIB_PREFIX@,$LIB_PREFIX,;t t
17103 s,@LIB_SUFFIX@,$LIB_SUFFIX,;t t
17104 s,@CC_G_OPT@,$CC_G_OPT,;t t
17105 s,@LD_MODEL@,$LD_MODEL,;t t
17106 s,@shlibdir@,$shlibdir,;t t
17107 s,@MAKE_DLLS@,$MAKE_DLLS,;t t
17108 s,@CC_SHARED_OPTS@,$CC_SHARED_OPTS,;t t
17109 s,@LD_RPATH_OPT@,$LD_RPATH_OPT,;t t
17110 s,@LD_SHARED_OPTS@,$LD_SHARED_OPTS,;t t
17111 s,@MK_SHARED_LIB@,$MK_SHARED_LIB,;t t
17112 s,@RM_SHARED_OPTS@,$RM_SHARED_OPTS,;t t
17113 s,@LINK_PROGS@,$LINK_PROGS,;t t
17114 s,@LINK_TESTS@,$LINK_TESTS,;t t
17115 s,@EXTRA_LDFLAGS@,$EXTRA_LDFLAGS,;t t
17116 s,@LOCAL_LDFLAGS@,$LOCAL_LDFLAGS,;t t
17117 s,@LOCAL_LDFLAGS2@,$LOCAL_LDFLAGS2,;t t
17118 s,@INSTALL_LIB@,$INSTALL_LIB,;t t
17119 s,@RPATH_LIST@,$RPATH_LIST,;t t
17120 s,@BROKEN_LINKER@,$BROKEN_LINKER,;t t
17121 s,@NCURSES_EXT_FUNCS@,$NCURSES_EXT_FUNCS,;t t
17122 s,@NCURSES_CONST@,$NCURSES_CONST,;t t
17123 s,@PTHREAD@,$PTHREAD,;t t
17124 s,@cf_cv_enable_reentrant@,$cf_cv_enable_reentrant,;t t
17125 s,@NCURSES_WRAP_PREFIX@,$NCURSES_WRAP_PREFIX,;t t
17126 s,@ECHO_LT@,$ECHO_LT,;t t
17127 s,@ECHO_LD@,$ECHO_LD,;t t
17128 s,@RULE_CC@,$RULE_CC,;t t
17129 s,@SHOW_CC@,$SHOW_CC,;t t
17130 s,@ECHO_CC@,$ECHO_CC,;t t
17131 s,@ADAFLAGS@,$ADAFLAGS,;t t
17132 s,@EXTRA_CFLAGS@,$EXTRA_CFLAGS,;t t
17133 s,@ADA_TRACE@,$ADA_TRACE,;t t
17134 s,@cf_TEMP_gnat@,$cf_TEMP_gnat,;t t
17135 s,@M4_exists@,$M4_exists,;t t
17136 s,@cf_ada_make@,$cf_ada_make,;t t
17137 s,@cf_ada_config@,$cf_ada_config,;t t
17138 s,@cf_ada_config_Ada@,$cf_ada_config_Ada,;t t
17139 s,@cf_ada_config_C@,$cf_ada_config_C,;t t
17140 s,@GNATPREP_OPTS@,$GNATPREP_OPTS,;t t
17141 s,@cf_compile_generics@,$cf_compile_generics,;t t
17142 s,@cf_generic_objects@,$cf_generic_objects,;t t
17143 s,@USE_GNAT_SIGINT@,$USE_GNAT_SIGINT,;t t
17144 s,@USE_OLD_MAKERULES@,$USE_OLD_MAKERULES,;t t
17145 s,@USE_GNAT_PROJECTS@,$USE_GNAT_PROJECTS,;t t
17146 s,@USE_GNAT_LIBRARIES@,$USE_GNAT_LIBRARIES,;t t
17147 s,@cf_ada_compiler@,$cf_ada_compiler,;t t
17148 s,@cf_ada_package@,$cf_ada_package,;t t
17149 s,@ADA_INCLUDE@,$ADA_INCLUDE,;t t
17150 s,@ADA_OBJECTS@,$ADA_OBJECTS,;t t
17151 s,@ADA_SHAREDLIB@,$ADA_SHAREDLIB,;t t
17152 s,@MAKE_ADA_SHAREDLIB@,$MAKE_ADA_SHAREDLIB,;t t
17153 s,@ADA_LIBNAME@,$ADA_LIBNAME,;t t
17154 s,@TINFO_LDFLAGS2@,$TINFO_LDFLAGS2,;t t
17155 s,@TINFO_LIBS@,$TINFO_LIBS,;t t
17156 s,@ACPPFLAGS@,$ACPPFLAGS,;t t
17157 s,@DFT_ARG_SUFFIX@,$DFT_ARG_SUFFIX,;t t
17158 s,@DFT_DEP_SUFFIX@,$DFT_DEP_SUFFIX,;t t
17159 s,@DFT_OBJ_SUBDIR@,$DFT_OBJ_SUBDIR,;t t
17160 s,@USE_ARG_SUFFIX@,$USE_ARG_SUFFIX,;t t
17161 s,@USE_LIB_SUFFIX@,$USE_LIB_SUFFIX,;t t
17162 s,@USE_CFG_SUFFIX@,$USE_CFG_SUFFIX,;t t
17163 s,@TEST_ARG2@,$TEST_ARG2,;t t
17164 s,@TEST_LIBS2@,$TEST_LIBS2,;t t
17165 s,@NCURSES_SHLIB2@,$NCURSES_SHLIB2,;t t
17166 s,@ADA_SUBDIRS@,$ADA_SUBDIRS,;t t
17167 s,@NCURSES_TREE@,$NCURSES_TREE,;t t
17168 s,@EXTERNAL_TREE@,$EXTERNAL_TREE,;t t
17169 s,@ADAHTML_DIR@,$ADAHTML_DIR,;t t
17170 s,@ADAGEN_LDFLAGS@,$ADAGEN_LDFLAGS,;t t
17175 cat >>$CONFIG_STATUS <<\EOF
17176 # Split the substitutions into bite-sized pieces for seds with
17177 # small command number limits, like on Digital OSF/1 and HP-UX.
17178 ac_max_sed_lines=48
17179 ac_sed_frag=1 # Number of current file.
17180 ac_beg=1 # First line for current file.
17181 ac_end=$ac_max_sed_lines # Line after last line for current file.
17184 while $ac_more_lines; do
17185 if test $ac_beg -gt 1; then
17186 sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
17188 sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
17190 if test ! -s $tmp/subs.frag; then
17191 ac_more_lines=false
17193 # The purpose of the label and of the branching condition is to
17194 # speed up the sed processing (if there are no `@' at all, there
17195 # is no need to browse any of the substitutions).
17196 # These are the two extra sed commands mentioned above.
17198 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
17199 # It is possible to make a multiline substitution using escaped newlines.
17200 # Ensure that we do not split the substitution between script fragments.
17202 ac_END=`expr $ac_end + $ac_max_sed_lines`
17203 sed "1,${ac_BEG}d; ${ac_END}p; q" $tmp/subs.sed >$tmp/subs.next
17204 if test -s $tmp/subs.next; then
17205 grep '^s,@[^@,][^@,]*@,.*\\$' $tmp/subs.next >$tmp/subs.edit
17206 if test ! -s $tmp/subs.edit; then
17207 grep "^s,@[^@,][^@,]*@,.*,;t t$" $tmp/subs.next >$tmp/subs.edit
17208 if test ! -s $tmp/subs.edit; then
17209 if test $ac_beg -gt 1; then
17210 ac_end=`expr $ac_end - 1`
17217 if test -z "$ac_sed_cmds"; then
17218 ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
17220 ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
17222 ac_sed_frag=`expr $ac_sed_frag + 1`
17224 ac_end=`expr $ac_end + $ac_max_sed_lines`
17227 if test -z "$ac_sed_cmds"; then
17230 fi # test -n "$CONFIG_FILES"
17233 cat >>$CONFIG_STATUS <<\EOF
17234 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
17235 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
17237 - | *:- | *:-:* ) # input from stdin
17239 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
17240 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
17241 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
17242 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
17243 * ) ac_file_in=$ac_file.in ;;
17246 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
17247 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
17248 X"$ac_file" : 'X\(//\)[^/]' \| \
17249 X"$ac_file" : 'X\(//\)$' \| \
17250 X"$ac_file" : 'X\(/\)' \| \
17251 . : '\(.\)' 2>/dev/null ||
17253 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
17254 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
17255 /^X\(\/\/\)$/{ s//\1/; q; }
17256 /^X\(\/\).*/{ s//\1/; q; }
17258 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
17259 { case "$ac_dir" in
17260 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
17264 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
17265 case $as_mkdir_dir in
17266 # Skip DOS drivespec
17267 ?:) as_incr_dir=$as_mkdir_dir ;;
17269 as_incr_dir=$as_incr_dir/$as_mkdir_dir
17270 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
17275 ac_dir_suffix="/`echo $ac_dir|sed 's,^\./,,'`"
17276 # A "../" for each directory in $ac_dir_suffix.
17277 ac_dots=`echo "$ac_dir_suffix" | sed 's,/[^/]*,../,g'`
17279 ac_dir_suffix= ac_dots=
17284 if test -z "$ac_dots"; then
17287 ac_top_srcdir=`echo $ac_dots | sed 's,/$,,'`
17289 [\\/]* | ?:[\\/]* )
17290 ac_srcdir=$srcdir$ac_dir_suffix;
17291 ac_top_srcdir=$srcdir ;;
17292 *) # Relative path.
17293 ac_srcdir=$ac_dots$srcdir$ac_dir_suffix
17294 ac_top_srcdir=$ac_dots$srcdir ;;
17298 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
17299 *) ac_INSTALL=$ac_dots$INSTALL ;;
17302 if test x"$ac_file" != x-; then
17303 { echo "$as_me:17303: creating $ac_file" >&5
17304 echo "$as_me: creating $ac_file" >&6;}
17307 # Let's still pretend it is `configure' which instantiates (i.e., don't
17308 # use $as_me), people would be surprised to read:
17309 # /* config.h. Generated automatically by config.status. */
17310 configure_input="Generated automatically from `echo $ac_file_in |
17311 sed 's,.*/,,'` by configure."
17313 # First look for the input files in the build tree, otherwise in the
17315 ac_file_inputs=`IFS=:
17316 for f in $ac_file_in; do
17318 -) echo $tmp/stdin ;;
17320 # Absolute (can't be DOS-style, as IFS=:)
17321 test -f "$f" || { { echo "$as_me:17321: error: cannot find input file: $f" >&5
17322 echo "$as_me: error: cannot find input file: $f" >&2;}
17323 { (exit 1); exit 1; }; }
17326 if test -f "$f"; then
17329 elif test -f "$srcdir/$f"; then
17334 { { echo "$as_me:17334: error: cannot find input file: $f" >&5
17335 echo "$as_me: error: cannot find input file: $f" >&2;}
17336 { (exit 1); exit 1; }; }
17339 done` || { (exit 1); exit 1; }
17341 cat >>$CONFIG_STATUS <<\EOF
17342 ac_warn_datarootdir=no
17343 if test x"$ac_file" != x-; then
17344 for ac_item in $ac_file_inputs
17346 ac_seen=`grep '@\(datadir\|mandir\|infodir\)@' $ac_item`
17347 if test -n "$ac_seen"; then
17348 ac_used=`grep '@datarootdir@' $ac_item`
17349 if test -z "$ac_used"; then
17350 { echo "$as_me:17350: WARNING: datarootdir was used implicitly but not set:
17352 echo "$as_me: WARNING: datarootdir was used implicitly but not set:
17354 ac_warn_datarootdir=yes
17357 ac_seen=`grep '${datarootdir}' $ac_item`
17358 if test -n "$ac_seen"; then
17359 { echo "$as_me:17359: WARNING: datarootdir was used explicitly but not set:
17361 echo "$as_me: WARNING: datarootdir was used explicitly but not set:
17363 ac_warn_datarootdir=yes
17368 if test "x$ac_warn_datarootdir" = xyes; then
17369 ac_sed_cmds="$ac_sed_cmds | sed -e 's,@datarootdir@,\${prefix}/share,g' -e 's,\${datarootdir},\${prefix}/share,g'"
17373 cat >>$CONFIG_STATUS <<EOF
17377 cat >>$CONFIG_STATUS <<\EOF
17379 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
17380 s,@configure_input@,$configure_input,;t t
17381 s,@srcdir@,$ac_srcdir,;t t
17382 s,@top_srcdir@,$ac_top_srcdir,;t t
17383 s,@INSTALL@,$ac_INSTALL,;t t
17384 " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
17386 if test x"$ac_file" != x-; then
17387 cp $tmp/out $ac_file
17389 for ac_name in prefix exec_prefix datarootdir
17391 ac_seen=`fgrep -n '${'$ac_name'[:=].*}' $ac_file`
17392 if test -n "$ac_seen"; then
17393 ac_init=`egrep '[ ]*'$ac_name'[ ]*=' $ac_file`
17394 if test -z "$ac_init"; then
17395 ac_seen=`echo "$ac_seen" |sed -e 's,^,'$ac_file':,'`
17396 { echo "$as_me:17396: WARNING: Variable $ac_name is used but was not set:
17398 echo "$as_me: WARNING: Variable $ac_name is used but was not set:
17403 egrep -n '@[a-z_][a-z_0-9]+@' $ac_file >$tmp/out
17404 egrep -n '@[A-Z_][A-Z_0-9]+@' $ac_file >>$tmp/out
17405 if test -s $tmp/out; then
17406 ac_seen=`sed -e 's,^,'$ac_file':,' < $tmp/out`
17407 { echo "$as_me:17407: WARNING: Some variables may not be substituted:
17409 echo "$as_me: WARNING: Some variables may not be substituted:
17419 cat >>$CONFIG_STATUS <<\EOF
17422 # CONFIG_HEADER section.
17425 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
17426 # NAME is the cpp macro being defined and VALUE is the value it is being given.
17428 # ac_d sets the value in "#define NAME VALUE" lines.
17429 ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
17430 ac_dB='[ ].*$,\1#\2'
17433 # ac_i turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
17434 ac_iA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
17435 ac_iB='\([ ]\),\1#\2define\3'
17438 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
17439 ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
17440 ac_uB='$,\1#\2define\3'
17444 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
17445 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
17447 - | *:- | *:-:* ) # input from stdin
17449 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
17450 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
17451 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
17452 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
17453 * ) ac_file_in=$ac_file.in ;;
17456 test x"$ac_file" != x- && { echo "$as_me:17456: creating $ac_file" >&5
17457 echo "$as_me: creating $ac_file" >&6;}
17459 # First look for the input files in the build tree, otherwise in the
17461 ac_file_inputs=`IFS=:
17462 for f in $ac_file_in; do
17464 -) echo $tmp/stdin ;;
17466 # Absolute (can't be DOS-style, as IFS=:)
17467 test -f "$f" || { { echo "$as_me:17467: error: cannot find input file: $f" >&5
17468 echo "$as_me: error: cannot find input file: $f" >&2;}
17469 { (exit 1); exit 1; }; }
17472 if test -f "$f"; then
17475 elif test -f "$srcdir/$f"; then
17480 { { echo "$as_me:17480: error: cannot find input file: $f" >&5
17481 echo "$as_me: error: cannot find input file: $f" >&2;}
17482 { (exit 1); exit 1; }; }
17485 done` || { (exit 1); exit 1; }
17486 # Remove the trailing spaces.
17487 sed 's/[ ]*$//' $ac_file_inputs >$tmp/in
17491 # Transform confdefs.h into a list of #define's. We won't use it as a sed
17492 # script, but as data to insert where we see @DEFS@. We expect AC_SAVE_DEFS to
17493 # be either 'cat' or 'sort'.
17494 cat confdefs.h | uniq >conftest.vals
17496 # Break up conftest.vals because some shells have a limit on
17497 # the size of here documents, and old seds have small limits too.
17499 rm -f conftest.tail
17500 echo ' rm -f conftest.frag' >> $CONFIG_STATUS
17501 while grep . conftest.vals >/dev/null
17503 # Write chunks of a limited-size here document to conftest.frag.
17504 echo ' cat >> conftest.frag <<CEOF' >> $CONFIG_STATUS
17505 sed ${ac_max_here_lines}q conftest.vals | sed -e 's/#ifdef.*/#if 0/' >> $CONFIG_STATUS
17506 echo 'CEOF' >> $CONFIG_STATUS
17507 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
17508 rm -f conftest.vals
17509 mv conftest.tail conftest.vals
17511 rm -f conftest.vals
17513 # Run sed to substitute the contents of conftest.frag into $tmp/in at the
17515 echo ' cat >> conftest.edit <<CEOF
17516 /@DEFS@/r conftest.frag
17519 sed -f conftest.edit $tmp/in > $tmp/out
17521 mv $tmp/out $tmp/in
17522 rm -f conftest.edit conftest.frag
17523 ' >> $CONFIG_STATUS
17525 cat >>$CONFIG_STATUS <<\EOF
17526 # Let's still pretend it is `configure' which instantiates (i.e., don't
17527 # use $as_me), people would be surprised to read:
17528 # /* config.h. Generated automatically by config.status. */
17529 if test x"$ac_file" = x-; then
17530 echo "/* Generated automatically by configure. */" >$tmp/config.h
17532 echo "/* $ac_file. Generated automatically by configure. */" >$tmp/config.h
17534 cat $tmp/in >>$tmp/config.h
17536 if test x"$ac_file" != x-; then
17537 if cmp -s $ac_file $tmp/config.h 2>/dev/null; then
17538 { echo "$as_me:17538: $ac_file is unchanged" >&5
17539 echo "$as_me: $ac_file is unchanged" >&6;}
17541 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
17542 X"$ac_file" : 'X\(//\)[^/]' \| \
17543 X"$ac_file" : 'X\(//\)$' \| \
17544 X"$ac_file" : 'X\(/\)' \| \
17545 . : '\(.\)' 2>/dev/null ||
17547 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
17548 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
17549 /^X\(\/\/\)$/{ s//\1/; q; }
17550 /^X\(\/\).*/{ s//\1/; q; }
17552 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
17553 { case "$ac_dir" in
17554 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
17558 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
17559 case $as_mkdir_dir in
17560 # Skip DOS drivespec
17561 ?:) as_incr_dir=$as_mkdir_dir ;;
17563 as_incr_dir=$as_incr_dir/$as_mkdir_dir
17564 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
17571 mv $tmp/config.h $ac_file
17575 rm -f $tmp/config.h
17579 cat >>$CONFIG_STATUS <<\EOF
17581 # CONFIG_COMMANDS section.
17583 for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
17584 ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
17585 ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
17589 if test -z "$USE_OLD_MAKERULES" ; then
17590 $AWK -f $srcdir/mk-1st.awk <$srcdir/src/modules >>src/Makefile
17597 cat >>$CONFIG_STATUS <<\EOF
17599 { (exit 0); exit 0; }
17601 chmod +x $CONFIG_STATUS
17602 ac_clean_files=$ac_clean_files_save
17604 # configure is writing to config.log, and then calls config.status.
17605 # config.status does its own redirection, appending to config.log.
17606 # Unfortunately, on DOS this fails, as config.log is still kept open
17607 # by configure, so config.status won't be able to write to it; its
17608 # output is simply discarded. So we exec the FD to /dev/null,
17609 # effectively closing config.log, so it can be properly (re)opened and
17610 # appended to by config.status. When coming back to configure, we
17611 # need to make the FD available again.
17612 if test "$no_create" != yes; then
17615 $SHELL $CONFIG_STATUS || ac_cs_success=false
17617 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
17618 # would make configure fail if this is the last instruction.
17619 $ac_cs_success || { (exit 1); exit 1; }
17621 ${MAKE:-make} preinstall