2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by Autoconf 2.52.20101001.
5 # Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
6 # Free Software Foundation, Inc.
7 # This configure script is free software; the Free Software Foundation
8 # gives unlimited permission to copy, distribute and modify it.
10 # Avoid depending upon Character Ranges.
11 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
12 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
13 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
14 as_cr_digits='0123456789'
15 as_cr_alnum=$as_cr_Letters$as_cr_digits
17 # Sed expression to map a string onto a valid variable name.
18 as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
20 # Sed expression to map a string onto a valid CPP name.
21 as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
23 # Be Bourne compatible
24 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
27 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
31 # Name of the executable.
32 as_me=`echo "$0" |sed 's,.*[\\/],,'`
34 if expr a : '\(a\)' >/dev/null 2>&1; then
40 rm -f conf$$ conf$$.exe conf$$.file
42 if ln -s conf$$.file conf$$ 2>/dev/null; then
43 # We could just check for DJGPP; but this test a) works b) is more generic
44 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
45 if test -f conf$$.exe; then
46 # Don't use ln at all; we don't have any links
51 elif ln conf$$.file conf$$ 2>/dev/null; then
56 rm -f conf$$ conf$$.exe conf$$.file
58 as_executable_p="test -f"
60 # Support unset when possible.
61 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
68 $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
69 $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
70 $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
71 $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
72 $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
73 $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
74 $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
75 $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
78 # We need space, tab and new line, in precisely that order.
84 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
87 # hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
88 # so uname gets run too.
89 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
96 ac_default_prefix=/usr/local
100 SHELL=${CONFIG_SHELL-/bin/sh}
102 # Maximum number of lines to put in a shell here document.
103 # This variable seems obsolete. It should probably be removed, and
104 # only ac_max_sed_lines should be used.
105 : ${ac_max_here_lines=38}
107 ac_unique_file="ncurses.c"
108 # Factoring default headers for most tests.
109 ac_includes_default="\
112 # include <sys/types.h>
115 # include <sys/stat.h>
126 # if !STDC_HEADERS && HAVE_MEMORY_H
132 # include <strings.h>
135 # include <inttypes.h>
145 # Initialize some variables set by options.
147 ac_init_version=false
148 # The variables have the same names as the options, with
149 # dashes changed to underlines.
157 program_transform_name=s,x,x,
165 # Installation directory options.
166 # These are left unexpanded so users can "make install exec_prefix=/foo"
167 # and all the variables that are supposed to be based on exec_prefix
168 # by default will actually change.
169 # Use braces instead of parens because sh, perl, etc. also accept them.
170 bindir='${exec_prefix}/bin'
171 sbindir='${exec_prefix}/sbin'
172 libexecdir='${exec_prefix}/libexec'
173 datadir='${prefix}/share'
174 sysconfdir='${prefix}/etc'
175 sharedstatedir='${prefix}/com'
176 localstatedir='${prefix}/var'
177 libdir='${exec_prefix}/lib'
178 includedir='${prefix}/include'
179 oldincludedir='/usr/include'
180 infodir='${prefix}/info'
181 mandir='${prefix}/man'
183 # Identity of this package.
193 # If the previous option needs an argument, assign it.
194 if test -n "$ac_prev"; then
195 eval "$ac_prev=\$ac_option"
200 ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
202 # Accept the important Cygnus configure options, so we can diagnose typos.
206 -bindir | --bindir | --bindi | --bind | --bin | --bi)
208 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
211 -build | --build | --buil | --bui | --bu)
212 ac_prev=build_alias ;;
213 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
214 build_alias=$ac_optarg ;;
216 -cache-file | --cache-file | --cache-fil | --cache-fi \
217 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
218 ac_prev=cache_file ;;
219 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
220 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
221 cache_file=$ac_optarg ;;
224 cache_file=config.cache ;;
226 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
228 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
230 datadir=$ac_optarg ;;
232 -disable-* | --disable-*)
233 ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
234 # Reject names that are not valid shell variable names.
235 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
236 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
237 { (exit 1); exit 1; }; }
238 ac_feature=`echo $ac_feature | sed 's/-/_/g'`
239 eval "enable_$ac_feature=no" ;;
241 -enable-* | --enable-*)
242 ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
243 # Reject names that are not valid shell variable names.
244 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
245 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
246 { (exit 1); exit 1; }; }
247 ac_feature=`echo $ac_feature | sed 's/-/_/g'`
249 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
252 eval "enable_$ac_feature='$ac_optarg'" ;;
254 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
255 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
256 | --exec | --exe | --ex)
257 ac_prev=exec_prefix ;;
258 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
259 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
260 | --exec=* | --exe=* | --ex=*)
261 exec_prefix=$ac_optarg ;;
263 -gas | --gas | --ga | --g)
264 # Obsolete; use --with-gas.
267 -help | --help | --hel | --he | -h)
269 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
270 ac_init_help=recursive ;;
271 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
272 ac_init_help=short ;;
274 -host | --host | --hos | --ho)
275 ac_prev=host_alias ;;
276 -host=* | --host=* | --hos=* | --ho=*)
277 host_alias=$ac_optarg ;;
279 -includedir | --includedir | --includedi | --included | --include \
280 | --includ | --inclu | --incl | --inc)
281 ac_prev=includedir ;;
282 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
283 | --includ=* | --inclu=* | --incl=* | --inc=*)
284 includedir=$ac_optarg ;;
286 -infodir | --infodir | --infodi | --infod | --info | --inf)
288 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
289 infodir=$ac_optarg ;;
291 -libdir | --libdir | --libdi | --libd)
293 -libdir=* | --libdir=* | --libdi=* | --libd=*)
296 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
297 | --libexe | --libex | --libe)
298 ac_prev=libexecdir ;;
299 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
300 | --libexe=* | --libex=* | --libe=*)
301 libexecdir=$ac_optarg ;;
303 -localstatedir | --localstatedir | --localstatedi | --localstated \
304 | --localstate | --localstat | --localsta | --localst \
305 | --locals | --local | --loca | --loc | --lo)
306 ac_prev=localstatedir ;;
307 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
308 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
309 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
310 localstatedir=$ac_optarg ;;
312 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
314 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
318 # Obsolete; use --without-fp.
321 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
325 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
326 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
329 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
330 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
331 | --oldin | --oldi | --old | --ol | --o)
332 ac_prev=oldincludedir ;;
333 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
334 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
335 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
336 oldincludedir=$ac_optarg ;;
338 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
340 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
343 -program-prefix | --program-prefix | --program-prefi | --program-pref \
344 | --program-pre | --program-pr | --program-p)
345 ac_prev=program_prefix ;;
346 -program-prefix=* | --program-prefix=* | --program-prefi=* \
347 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
348 program_prefix=$ac_optarg ;;
350 -program-suffix | --program-suffix | --program-suffi | --program-suff \
351 | --program-suf | --program-su | --program-s)
352 ac_prev=program_suffix ;;
353 -program-suffix=* | --program-suffix=* | --program-suffi=* \
354 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
355 program_suffix=$ac_optarg ;;
357 -program-transform-name | --program-transform-name \
358 | --program-transform-nam | --program-transform-na \
359 | --program-transform-n | --program-transform- \
360 | --program-transform | --program-transfor \
361 | --program-transfo | --program-transf \
362 | --program-trans | --program-tran \
363 | --progr-tra | --program-tr | --program-t)
364 ac_prev=program_transform_name ;;
365 -program-transform-name=* | --program-transform-name=* \
366 | --program-transform-nam=* | --program-transform-na=* \
367 | --program-transform-n=* | --program-transform-=* \
368 | --program-transform=* | --program-transfor=* \
369 | --program-transfo=* | --program-transf=* \
370 | --program-trans=* | --program-tran=* \
371 | --progr-tra=* | --program-tr=* | --program-t=*)
372 program_transform_name=$ac_optarg ;;
374 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
375 | -silent | --silent | --silen | --sile | --sil)
378 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
380 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
382 sbindir=$ac_optarg ;;
384 -sharedstatedir | --sharedstatedir | --sharedstatedi \
385 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
386 | --sharedst | --shareds | --shared | --share | --shar \
388 ac_prev=sharedstatedir ;;
389 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
390 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
391 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
393 sharedstatedir=$ac_optarg ;;
395 -site | --site | --sit)
397 -site=* | --site=* | --sit=*)
400 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
402 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
405 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
406 | --syscon | --sysco | --sysc | --sys | --sy)
407 ac_prev=sysconfdir ;;
408 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
409 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
410 sysconfdir=$ac_optarg ;;
412 -target | --target | --targe | --targ | --tar | --ta | --t)
413 ac_prev=target_alias ;;
414 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
415 target_alias=$ac_optarg ;;
417 -v | -verbose | --verbose | --verbos | --verbo | --verb)
420 -version | --version | --versio | --versi | --vers | -V)
424 ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
425 # Reject names that are not valid shell variable names.
426 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
427 { echo "$as_me: error: invalid package name: $ac_package" >&2
428 { (exit 1); exit 1; }; }
429 ac_package=`echo $ac_package| sed 's/-/_/g'`
431 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
434 eval "with_$ac_package='$ac_optarg'" ;;
436 -without-* | --without-*)
437 ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
438 # Reject names that are not valid shell variable names.
439 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
440 { echo "$as_me: error: invalid package name: $ac_package" >&2
441 { (exit 1); exit 1; }; }
442 ac_package=`echo $ac_package | sed 's/-/_/g'`
443 eval "with_$ac_package=no" ;;
446 # Obsolete; use --with-x.
449 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
450 | --x-incl | --x-inc | --x-in | --x-i)
451 ac_prev=x_includes ;;
452 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
453 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
454 x_includes=$ac_optarg ;;
456 -x-libraries | --x-libraries | --x-librarie | --x-librari \
457 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
458 ac_prev=x_libraries ;;
459 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
460 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
461 x_libraries=$ac_optarg ;;
463 -*) { echo "$as_me: error: unrecognized option: $ac_option
464 Try \`$0 --help' for more information." >&2
465 { (exit 1); exit 1; }; }
469 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
470 # Reject names that are not valid shell variable names.
471 expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
472 { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
473 { (exit 1); exit 1; }; }
474 ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
475 eval "$ac_envvar='$ac_optarg'"
479 # FIXME: should be removed in autoconf 3.0.
480 echo "$as_me: WARNING: you should use --build, --host, --target" >&2
481 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
482 echo "$as_me: WARNING: invalid host type: $ac_option" >&2
483 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
489 if test -n "$ac_prev"; then
490 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
491 { echo "$as_me: error: missing argument to $ac_option" >&2
492 { (exit 1); exit 1; }; }
495 # Be sure to have absolute paths.
496 for ac_var in exec_prefix prefix
498 eval ac_val=$`echo $ac_var`
500 [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
501 *) { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
502 { (exit 1); exit 1; }; };;
506 # Be sure to have absolute paths.
507 for ac_var in bindir sbindir libexecdir datadir sysconfdir sharedstatedir \
508 localstatedir libdir includedir oldincludedir infodir mandir
510 eval ac_val=$`echo $ac_var`
512 [\\/$]* | ?:[\\/]* ) ;;
513 *) { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
514 { (exit 1); exit 1; }; };;
518 # There might be people who depend on the old broken behavior: `$host'
519 # used to hold the argument of --host etc.
524 # FIXME: should be removed in autoconf 3.0.
525 if test "x$host_alias" != x; then
526 if test "x$build_alias" = x; then
527 cross_compiling=maybe
528 echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
529 If a cross compiler is detected then cross compile mode will be used." >&2
530 elif test "x$build_alias" != "x$host_alias"; then
536 test -n "$host_alias" && ac_tool_prefix=$host_alias-
538 test "$silent" = yes && exec 6>/dev/null
540 # Find the source files, if location was not specified.
541 if test -z "$srcdir"; then
542 ac_srcdir_defaulted=yes
543 # Try the directory containing this script, then its parent.
545 ac_confdir=`echo "$ac_prog" | sed 's%[\\/][^\\/][^\\/]*$%%'`
546 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
548 if test ! -r $srcdir/$ac_unique_file; then
552 ac_srcdir_defaulted=no
554 if test ! -r $srcdir/$ac_unique_file; then
555 if test "$ac_srcdir_defaulted" = yes; then
556 { echo "$as_me: error: cannot find sources in $ac_confdir or .." >&2
557 { (exit 1); exit 1; }; }
559 { echo "$as_me: error: cannot find sources in $srcdir" >&2
560 { (exit 1); exit 1; }; }
563 srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
564 ac_env_build_alias_set=${build_alias+set}
565 ac_env_build_alias_value=$build_alias
566 ac_cv_env_build_alias_set=${build_alias+set}
567 ac_cv_env_build_alias_value=$build_alias
568 ac_env_host_alias_set=${host_alias+set}
569 ac_env_host_alias_value=$host_alias
570 ac_cv_env_host_alias_set=${host_alias+set}
571 ac_cv_env_host_alias_value=$host_alias
572 ac_env_target_alias_set=${target_alias+set}
573 ac_env_target_alias_value=$target_alias
574 ac_cv_env_target_alias_set=${target_alias+set}
575 ac_cv_env_target_alias_value=$target_alias
576 ac_env_CC_set=${CC+set}
578 ac_cv_env_CC_set=${CC+set}
579 ac_cv_env_CC_value=$CC
580 ac_env_CFLAGS_set=${CFLAGS+set}
581 ac_env_CFLAGS_value=$CFLAGS
582 ac_cv_env_CFLAGS_set=${CFLAGS+set}
583 ac_cv_env_CFLAGS_value=$CFLAGS
584 ac_env_LDFLAGS_set=${LDFLAGS+set}
585 ac_env_LDFLAGS_value=$LDFLAGS
586 ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
587 ac_cv_env_LDFLAGS_value=$LDFLAGS
588 ac_env_CPPFLAGS_set=${CPPFLAGS+set}
589 ac_env_CPPFLAGS_value=$CPPFLAGS
590 ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
591 ac_cv_env_CPPFLAGS_value=$CPPFLAGS
592 ac_env_CPP_set=${CPP+set}
593 ac_env_CPP_value=$CPP
594 ac_cv_env_CPP_set=${CPP+set}
595 ac_cv_env_CPP_value=$CPP
598 # Report the --help message.
600 if test "$ac_init_help" = "long"; then
601 # Omit some internal or obsolete options to make the list less imposing.
602 # This message is too long to be a string in the A/UX 3.1 sh.
604 \`configure' configures this package to adapt to many kinds of systems.
606 Usage: $0 [OPTION]... [VAR=VALUE]...
608 To assign environment variables (e.g., CC, CFLAGS...), specify them as
609 VAR=VALUE. See below for descriptions of some of the useful variables.
611 Defaults for the options are specified in brackets.
614 -h, --help display this help and exit
615 --help=short display options specific to this package
616 --help=recursive display the short help of all the included packages
617 -V, --version display version information and exit
618 -q, --quiet, --silent do not print \`checking...' messages
619 --cache-file=FILE cache test results in FILE [disabled]
620 -C, --config-cache alias for \`--cache-file=config.cache'
621 -n, --no-create do not create output files
622 --srcdir=DIR find the sources in DIR [configure dir or \`..']
627 Installation directories:
628 --prefix=PREFIX install architecture-independent files in PREFIX
630 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
633 By default, \`make install' will install all the files in
634 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
635 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
636 for instance \`--prefix=\$HOME'.
638 For better control, use the options below.
640 Fine tuning of the installation directories:
641 --bindir=DIR user executables [EPREFIX/bin]
642 --sbindir=DIR system admin executables [EPREFIX/sbin]
643 --libexecdir=DIR program executables [EPREFIX/libexec]
644 --datadir=DIR read-only architecture-independent data [PREFIX/share]
645 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
646 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
647 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
648 --libdir=DIR object code libraries [EPREFIX/lib]
649 --includedir=DIR C header files [PREFIX/include]
650 --oldincludedir=DIR C header files for non-gcc [/usr/include]
651 --infodir=DIR info documentation [PREFIX/info]
652 --mandir=DIR man documentation [PREFIX/man]
658 --program-prefix=PREFIX prepend PREFIX to installed program names
659 --program-suffix=SUFFIX append SUFFIX to installed program names
660 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
663 --x-includes=DIR X include files are in DIR
664 --x-libraries=DIR X library files are in DIR
667 --build=BUILD configure for building on BUILD [guessed]
668 --host=HOST build programs to run on HOST [BUILD]
672 if test -n "$ac_init_help"; then
677 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
678 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
681 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
682 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
684 --disable-echo display "compiling" commands
685 --enable-warnings test: turn on gcc compiler warnings
686 --with-dmalloc test: use Gray Watson's dmalloc library
687 --with-dbmalloc test: use Conor Cahill's dbmalloc library
688 --with-valgrind test: use valgrind
689 --disable-leaks test: free permanent memory, analyze leaks
690 --with-curses-dir=DIR directory in which (n)curses is installed
691 --with-5lib use SunOS sysv-libraries
692 --with-ncursesw use wide ncurses-libraries (installed)
693 --with-ncurses use ncurses-libraries (installed)
694 --with-pdcurses compile/link with pdcurses X11 library
695 --with-Xaw3d link with Xaw 3d library
696 --with-neXtaw link with neXT Athena library
697 --with-XawPlus link with Athena-Plus library
698 --with-pkg-config{=path} enable/disable use of pkg-config
699 --with-x use the X Window System
700 --with-ncurses-wrap-prefix naming-prefix for ncurses wrapped-variables
702 Some influential environment variables:
703 CC C compiler command
704 CFLAGS C compiler flags
705 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
706 nonstandard directory <lib dir>
707 CPPFLAGS C/C++ preprocessor flags, e.g. -I<include dir> if you have
708 headers in a nonstandard directory <include dir>
711 Use these variables to override the choices made by `configure' or to help
712 it to find libraries and programs with nonstandard names/locations.
717 if test "$ac_init_help" = "recursive"; then
718 # If there are subdirs, report their specific --help.
720 for ac_subdir in : $ac_subdirs_all; do test "x$ac_subdir" = x: && continue
722 # A "../" for each directory in /$ac_subdir.
723 ac_dots=`echo $ac_subdir |
724 sed 's,^\./,,;s,[^/]$,&/,;s,[^/]*/,../,g'`
727 .) # No --srcdir option. We are building in place.
728 ac_sub_srcdir=$srcdir ;;
729 [\\/]* | ?:[\\/]* ) # Absolute path.
730 ac_sub_srcdir=$srcdir/$ac_subdir ;;
732 ac_sub_srcdir=$ac_dots$srcdir/$ac_subdir ;;
735 # Check for guested configure; otherwise get Cygnus style configure.
736 if test -f $ac_sub_srcdir/configure.gnu; then
738 $SHELL $ac_sub_srcdir/configure.gnu --help=recursive
739 elif test -f $ac_sub_srcdir/configure; then
741 $SHELL $ac_sub_srcdir/configure --help=recursive
742 elif test -f $ac_sub_srcdir/configure.ac ||
743 test -f $ac_sub_srcdir/configure.in; then
747 echo "$as_me: WARNING: no configuration information is in $ac_subdir" >&2
753 test -n "$ac_init_help" && exit 0
754 if $ac_init_version; then
757 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
758 Free Software Foundation, Inc.
759 This configure script is free software; the Free Software Foundation
760 gives unlimited permission to copy, distribute and modify it.
766 This file contains any messages produced by compilers while
767 running configure, to aid debugging if configure makes a mistake.
769 It was created by $as_me, which was
770 generated by GNU Autoconf 2.52.20101001. Invocation command line was
781 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
782 uname -m = `(uname -m) 2>/dev/null || echo unknown`
783 uname -r = `(uname -r) 2>/dev/null || echo unknown`
784 uname -s = `(uname -s) 2>/dev/null || echo unknown`
785 uname -v = `(uname -v) 2>/dev/null || echo unknown`
787 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
788 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
790 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
791 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
792 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
793 hostinfo = `(hostinfo) 2>/dev/null || echo unknown`
794 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
795 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
796 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
810 # Keep a trace of the command line.
811 # Strip out --no-create and --no-recursion so they do not pile up.
812 # Also quote any args containing shell meta-characters.
818 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
819 | --no-cr | --no-c) ;;
820 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
821 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
822 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
823 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"`
824 ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
826 *) ac_configure_args="$ac_configure_args$ac_sep$ac_arg"
829 # Get rid of the leading space.
832 # When interrupted or exit'd, cleanup temporary files, and complete
833 # config.log. We remove comments because anyway the quotes in there
834 # would cause problems or look ugly.
836 # Save into config.log some information that might help in debugging.
838 echo "## ----------------- ##" >&5
839 echo "## Cache variables. ##" >&5
840 echo "## ----------------- ##" >&5
842 # The following way of writing the cache mishandles newlines in values,
845 case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
848 "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
849 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
853 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
857 sed "/^$/d" confdefs.h >conftest.log
858 if test -s conftest.log; then
860 echo "## ------------ ##" >&5
861 echo "## confdefs.h. ##" >&5
862 echo "## ------------ ##" >&5
867 test "$ac_signal" != 0 &&
868 echo "$as_me: caught signal $ac_signal" >&5
869 echo "$as_me: exit $exit_status" >&5
870 rm -rf conftest* confdefs* core core.* *.core conf$$* $ac_clean_files &&
873 for ac_signal in 1 2 13 15; do
874 trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
878 # confdefs.h avoids OS command line length limits that DEFS can exceed.
879 rm -rf conftest* confdefs.h
880 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
883 # Let the site file select an alternate cache file if it wants to.
884 # Prefer explicitly selected file to automatically selected ones.
885 if test -z "$CONFIG_SITE"; then
886 if test "x$prefix" != xNONE; then
887 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
889 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
892 for ac_site_file in $CONFIG_SITE; do
893 if test -r "$ac_site_file"; then
894 { echo "$as_me:894: loading site script $ac_site_file" >&5
895 echo "$as_me: loading site script $ac_site_file" >&6;}
896 cat "$ac_site_file" >&5
901 if test -r "$cache_file"; then
902 # Some versions of bash will fail to source /dev/null (special
903 # files actually), so we avoid doing that.
904 if test -f "$cache_file"; then
905 { echo "$as_me:905: loading cache $cache_file" >&5
906 echo "$as_me: loading cache $cache_file" >&6;}
908 [\\/]* | ?:[\\/]* ) . $cache_file;;
913 { echo "$as_me:913: creating cache $cache_file" >&5
914 echo "$as_me: creating cache $cache_file" >&6;}
918 # Check that the precious variables saved in the cache have kept the same
920 ac_cache_corrupted=false
921 for ac_var in `(set) 2>&1 |
922 sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
923 eval ac_old_set=\$ac_cv_env_${ac_var}_set
924 eval ac_new_set=\$ac_env_${ac_var}_set
925 eval ac_old_val="\$ac_cv_env_${ac_var}_value"
926 eval ac_new_val="\$ac_env_${ac_var}_value"
927 case $ac_old_set,$ac_new_set in
929 { echo "$as_me:929: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
930 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
931 ac_cache_corrupted=: ;;
933 { echo "$as_me:933: error: \`$ac_var' was not set in the previous run" >&5
934 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
935 ac_cache_corrupted=: ;;
938 if test "x$ac_old_val" != "x$ac_new_val"; then
939 { echo "$as_me:939: error: \`$ac_var' has changed since the previous run:" >&5
940 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
941 { echo "$as_me:941: former value: $ac_old_val" >&5
942 echo "$as_me: former value: $ac_old_val" >&2;}
943 { echo "$as_me:943: current value: $ac_new_val" >&5
944 echo "$as_me: current value: $ac_new_val" >&2;}
948 # Pass precious variables to config.status. It doesn't matter if
949 # we pass some twice (in addition to the command line arguments).
950 if test "$ac_new_set" = set; then
952 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
953 ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"`
954 ac_configure_args="$ac_configure_args '$ac_arg'"
956 *) ac_configure_args="$ac_configure_args $ac_var=$ac_new_val"
961 if $ac_cache_corrupted; then
962 { echo "$as_me:962: error: changes in the environment can compromise the build" >&5
963 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
964 { { echo "$as_me:964: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
965 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
966 { (exit 1); exit 1; }; }
970 ac_cpp='$CPP $CPPFLAGS'
971 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
972 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
973 ac_compiler_gnu=$ac_cv_c_compiler_gnu
974 ac_main_return=return
976 case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
977 *c*,-n*) ECHO_N= ECHO_C='
979 *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
980 *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
982 echo "#! $SHELL" >conftest.sh
983 echo "exit 0" >>conftest.sh
985 if { (echo "$as_me:985: PATH=\".;.\"; conftest.sh") >&5
986 (PATH=".;."; conftest.sh) 2>&5
988 echo "$as_me:988: \$? = $ac_status" >&5
989 (exit $ac_status); }; then
990 ac_path_separator=';'
994 PATH_SEPARATOR="$ac_path_separator"
997 ac_config_headers="$ac_config_headers ncurses_cfg.h:ncurses_tst.hin"
999 test -f config.guess || ( test -f ../config.guess && cp ../config.guess ./ )
1001 test -f config.sub || ( test -f ../config.sub && cp ../config.sub ./ )
1004 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
1005 if test -f $ac_dir/install-sh; then
1007 ac_install_sh="$ac_aux_dir/install-sh -c"
1009 elif test -f $ac_dir/install.sh; then
1011 ac_install_sh="$ac_aux_dir/install.sh -c"
1013 elif test -f $ac_dir/shtool; then
1015 ac_install_sh="$ac_aux_dir/shtool install -c"
1019 if test -z "$ac_aux_dir"; then
1020 { { echo "$as_me:1020: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
1021 echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
1022 { (exit 1); exit 1; }; }
1024 ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1025 ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1026 ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
1028 # Make sure we can run config.sub.
1029 $ac_config_sub sun4 >/dev/null 2>&1 ||
1030 { { echo "$as_me:1030: error: cannot run $ac_config_sub" >&5
1031 echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1032 { (exit 1); exit 1; }; }
1034 echo "$as_me:1034: checking build system type" >&5
1035 echo $ECHO_N "checking build system type... $ECHO_C" >&6
1036 if test "${ac_cv_build+set}" = set; then
1037 echo $ECHO_N "(cached) $ECHO_C" >&6
1039 ac_cv_build_alias=$build_alias
1040 test -z "$ac_cv_build_alias" &&
1041 ac_cv_build_alias=`$ac_config_guess`
1042 test -z "$ac_cv_build_alias" &&
1043 { { echo "$as_me:1043: error: cannot guess build type; you must specify one" >&5
1044 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1045 { (exit 1); exit 1; }; }
1046 ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
1047 { { echo "$as_me:1047: error: $ac_config_sub $ac_cv_build_alias failed." >&5
1048 echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed." >&2;}
1049 { (exit 1); exit 1; }; }
1052 echo "$as_me:1052: result: $ac_cv_build" >&5
1053 echo "${ECHO_T}$ac_cv_build" >&6
1055 build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1056 build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1057 build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1059 if test -f $srcdir/config.guess || test -f $ac_aux_dir/config.guess ; then
1060 echo "$as_me:1060: checking host system type" >&5
1061 echo $ECHO_N "checking host system type... $ECHO_C" >&6
1062 if test "${ac_cv_host+set}" = set; then
1063 echo $ECHO_N "(cached) $ECHO_C" >&6
1065 ac_cv_host_alias=$host_alias
1066 test -z "$ac_cv_host_alias" &&
1067 ac_cv_host_alias=$ac_cv_build_alias
1068 ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
1069 { { echo "$as_me:1069: error: $ac_config_sub $ac_cv_host_alias failed" >&5
1070 echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1071 { (exit 1); exit 1; }; }
1074 echo "$as_me:1074: result: $ac_cv_host" >&5
1075 echo "${ECHO_T}$ac_cv_host" >&6
1077 host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1078 host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1079 host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1081 system_name="$host_os"
1083 system_name="`(uname -s -r) 2>/dev/null`"
1084 if test -z "$system_name" ; then
1085 system_name="`(hostname) 2>/dev/null`"
1088 test -n "$system_name" && cat >>confdefs.h <<EOF
1089 #define SYSTEM_NAME "$system_name"
1092 if test "${cf_cv_system_name+set}" = set; then
1093 echo $ECHO_N "(cached) $ECHO_C" >&6
1095 cf_cv_system_name="$system_name"
1098 test -z "$system_name" && system_name="$cf_cv_system_name"
1099 test -n "$cf_cv_system_name" && echo "$as_me:1099: result: Configuring for $cf_cv_system_name" >&5
1100 echo "${ECHO_T}Configuring for $cf_cv_system_name" >&6
1102 if test ".$system_name" != ".$cf_cv_system_name" ; then
1103 echo "$as_me:1103: result: Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&5
1104 echo "${ECHO_T}Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&6
1105 { { echo "$as_me:1105: error: \"Please remove config.cache and try again.\"" >&5
1106 echo "$as_me: error: \"Please remove config.cache and try again.\"" >&2;}
1107 { (exit 1); exit 1; }; }
1110 test "$program_prefix" != NONE &&
1111 program_transform_name="s,^,$program_prefix,;$program_transform_name"
1112 # Use a double $ so make ignores it.
1113 test "$program_suffix" != NONE &&
1114 program_transform_name="s,\$,$program_suffix,;$program_transform_name"
1115 # Double any \ or $. echo might interpret backslashes.
1116 # By default was `s,x,x', remove it if useless.
1117 cat <<\_ACEOF >conftest.sed
1118 s/[\\$]/&&/g;s/;s,x,x,$//
1120 program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
1123 echo "$as_me:1123: checking whether ${MAKE-make} sets \${MAKE}" >&5
1124 echo $ECHO_N "checking whether ${MAKE-make} sets \${MAKE}... $ECHO_C" >&6
1125 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,./+-,__p_,'`
1126 if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
1127 echo $ECHO_N "(cached) $ECHO_C" >&6
1129 cat >conftest.make <<\EOF
1131 @echo 'ac_maketemp="${MAKE}"'
1133 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1134 eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
1135 if test -n "$ac_maketemp"; then
1136 eval ac_cv_prog_make_${ac_make}_set=yes
1138 eval ac_cv_prog_make_${ac_make}_set=no
1142 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
1143 echo "$as_me:1143: result: yes" >&5
1144 echo "${ECHO_T}yes" >&6
1147 echo "$as_me:1147: result: no" >&5
1148 echo "${ECHO_T}no" >&6
1149 SET_MAKE="MAKE=${MAKE-make}"
1153 ac_cpp='$CPP $CPPFLAGS'
1154 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1155 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1156 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1157 ac_main_return=return
1158 if test -n "$ac_tool_prefix"; then
1159 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
1160 set dummy ${ac_tool_prefix}gcc; ac_word=$2
1161 echo "$as_me:1161: checking for $ac_word" >&5
1162 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1163 if test "${ac_cv_prog_CC+set}" = set; then
1164 echo $ECHO_N "(cached) $ECHO_C" >&6
1166 if test -n "$CC"; then
1167 ac_cv_prog_CC="$CC" # Let the user override the test.
1169 ac_save_IFS=$IFS; IFS=$ac_path_separator
1171 for ac_dir in $ac_dummy; do
1173 test -z "$ac_dir" && ac_dir=.
1174 $as_executable_p "$ac_dir/$ac_word" || continue
1175 ac_cv_prog_CC="${ac_tool_prefix}gcc"
1176 echo "$as_me:1176: found $ac_dir/$ac_word" >&5
1183 if test -n "$CC"; then
1184 echo "$as_me:1184: result: $CC" >&5
1185 echo "${ECHO_T}$CC" >&6
1187 echo "$as_me:1187: result: no" >&5
1188 echo "${ECHO_T}no" >&6
1192 if test -z "$ac_cv_prog_CC"; then
1194 # Extract the first word of "gcc", so it can be a program name with args.
1195 set dummy gcc; ac_word=$2
1196 echo "$as_me:1196: checking for $ac_word" >&5
1197 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1198 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1199 echo $ECHO_N "(cached) $ECHO_C" >&6
1201 if test -n "$ac_ct_CC"; then
1202 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1204 ac_save_IFS=$IFS; IFS=$ac_path_separator
1206 for ac_dir in $ac_dummy; do
1208 test -z "$ac_dir" && ac_dir=.
1209 $as_executable_p "$ac_dir/$ac_word" || continue
1210 ac_cv_prog_ac_ct_CC="gcc"
1211 echo "$as_me:1211: found $ac_dir/$ac_word" >&5
1217 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1218 if test -n "$ac_ct_CC"; then
1219 echo "$as_me:1219: result: $ac_ct_CC" >&5
1220 echo "${ECHO_T}$ac_ct_CC" >&6
1222 echo "$as_me:1222: result: no" >&5
1223 echo "${ECHO_T}no" >&6
1231 if test -z "$CC"; then
1232 if test -n "$ac_tool_prefix"; then
1233 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
1234 set dummy ${ac_tool_prefix}cc; ac_word=$2
1235 echo "$as_me:1235: checking for $ac_word" >&5
1236 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1237 if test "${ac_cv_prog_CC+set}" = set; then
1238 echo $ECHO_N "(cached) $ECHO_C" >&6
1240 if test -n "$CC"; then
1241 ac_cv_prog_CC="$CC" # Let the user override the test.
1243 ac_save_IFS=$IFS; IFS=$ac_path_separator
1245 for ac_dir in $ac_dummy; do
1247 test -z "$ac_dir" && ac_dir=.
1248 $as_executable_p "$ac_dir/$ac_word" || continue
1249 ac_cv_prog_CC="${ac_tool_prefix}cc"
1250 echo "$as_me:1250: found $ac_dir/$ac_word" >&5
1257 if test -n "$CC"; then
1258 echo "$as_me:1258: result: $CC" >&5
1259 echo "${ECHO_T}$CC" >&6
1261 echo "$as_me:1261: result: no" >&5
1262 echo "${ECHO_T}no" >&6
1266 if test -z "$ac_cv_prog_CC"; then
1268 # Extract the first word of "cc", so it can be a program name with args.
1269 set dummy cc; ac_word=$2
1270 echo "$as_me:1270: checking for $ac_word" >&5
1271 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1272 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1273 echo $ECHO_N "(cached) $ECHO_C" >&6
1275 if test -n "$ac_ct_CC"; then
1276 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1278 ac_save_IFS=$IFS; IFS=$ac_path_separator
1280 for ac_dir in $ac_dummy; do
1282 test -z "$ac_dir" && ac_dir=.
1283 $as_executable_p "$ac_dir/$ac_word" || continue
1284 ac_cv_prog_ac_ct_CC="cc"
1285 echo "$as_me:1285: found $ac_dir/$ac_word" >&5
1291 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1292 if test -n "$ac_ct_CC"; then
1293 echo "$as_me:1293: result: $ac_ct_CC" >&5
1294 echo "${ECHO_T}$ac_ct_CC" >&6
1296 echo "$as_me:1296: result: no" >&5
1297 echo "${ECHO_T}no" >&6
1306 if test -z "$CC"; then
1307 # Extract the first word of "cc", so it can be a program name with args.
1308 set dummy cc; ac_word=$2
1309 echo "$as_me:1309: checking for $ac_word" >&5
1310 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1311 if test "${ac_cv_prog_CC+set}" = set; then
1312 echo $ECHO_N "(cached) $ECHO_C" >&6
1314 if test -n "$CC"; then
1315 ac_cv_prog_CC="$CC" # Let the user override the test.
1318 ac_save_IFS=$IFS; IFS=$ac_path_separator
1320 for ac_dir in $ac_dummy; do
1322 test -z "$ac_dir" && ac_dir=.
1323 $as_executable_p "$ac_dir/$ac_word" || continue
1324 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
1325 ac_prog_rejected=yes
1329 echo "$as_me:1329: found $ac_dir/$ac_word" >&5
1333 if test $ac_prog_rejected = yes; then
1334 # We found a bogon in the path, so make sure we never use it.
1335 set dummy $ac_cv_prog_CC
1337 if test $# != 0; then
1338 # We chose a different compiler from the bogus one.
1339 # However, it has the same basename, so the bogon will be chosen
1340 # first if we set CC to just the basename; use the full file name.
1342 set dummy "$ac_dir/$ac_word" ${1+"$@"}
1350 if test -n "$CC"; then
1351 echo "$as_me:1351: result: $CC" >&5
1352 echo "${ECHO_T}$CC" >&6
1354 echo "$as_me:1354: result: no" >&5
1355 echo "${ECHO_T}no" >&6
1359 if test -z "$CC"; then
1360 if test -n "$ac_tool_prefix"; then
1363 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
1364 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
1365 echo "$as_me:1365: checking for $ac_word" >&5
1366 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1367 if test "${ac_cv_prog_CC+set}" = set; then
1368 echo $ECHO_N "(cached) $ECHO_C" >&6
1370 if test -n "$CC"; then
1371 ac_cv_prog_CC="$CC" # Let the user override the test.
1373 ac_save_IFS=$IFS; IFS=$ac_path_separator
1375 for ac_dir in $ac_dummy; do
1377 test -z "$ac_dir" && ac_dir=.
1378 $as_executable_p "$ac_dir/$ac_word" || continue
1379 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
1380 echo "$as_me:1380: found $ac_dir/$ac_word" >&5
1387 if test -n "$CC"; then
1388 echo "$as_me:1388: result: $CC" >&5
1389 echo "${ECHO_T}$CC" >&6
1391 echo "$as_me:1391: result: no" >&5
1392 echo "${ECHO_T}no" >&6
1395 test -n "$CC" && break
1398 if test -z "$CC"; then
1402 # Extract the first word of "$ac_prog", so it can be a program name with args.
1403 set dummy $ac_prog; ac_word=$2
1404 echo "$as_me:1404: checking for $ac_word" >&5
1405 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1406 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1407 echo $ECHO_N "(cached) $ECHO_C" >&6
1409 if test -n "$ac_ct_CC"; then
1410 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1412 ac_save_IFS=$IFS; IFS=$ac_path_separator
1414 for ac_dir in $ac_dummy; do
1416 test -z "$ac_dir" && ac_dir=.
1417 $as_executable_p "$ac_dir/$ac_word" || continue
1418 ac_cv_prog_ac_ct_CC="$ac_prog"
1419 echo "$as_me:1419: found $ac_dir/$ac_word" >&5
1425 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1426 if test -n "$ac_ct_CC"; then
1427 echo "$as_me:1427: result: $ac_ct_CC" >&5
1428 echo "${ECHO_T}$ac_ct_CC" >&6
1430 echo "$as_me:1430: result: no" >&5
1431 echo "${ECHO_T}no" >&6
1434 test -n "$ac_ct_CC" && break
1442 test -z "$CC" && { { echo "$as_me:1442: error: no acceptable cc found in \$PATH" >&5
1443 echo "$as_me: error: no acceptable cc found in \$PATH" >&2;}
1444 { (exit 1); exit 1; }; }
1446 # Provide some information about the compiler.
1447 echo "$as_me:1447:" \
1448 "checking for C compiler version" >&5
1449 ac_compiler=`set X $ac_compile; echo $2`
1450 { (eval echo "$as_me:1450: \"$ac_compiler --version </dev/null >&5\"") >&5
1451 (eval $ac_compiler --version </dev/null >&5) 2>&5
1453 echo "$as_me:1453: \$? = $ac_status" >&5
1454 (exit $ac_status); }
1455 { (eval echo "$as_me:1455: \"$ac_compiler -v </dev/null >&5\"") >&5
1456 (eval $ac_compiler -v </dev/null >&5) 2>&5
1458 echo "$as_me:1458: \$? = $ac_status" >&5
1459 (exit $ac_status); }
1460 { (eval echo "$as_me:1460: \"$ac_compiler -V </dev/null >&5\"") >&5
1461 (eval $ac_compiler -V </dev/null >&5) 2>&5
1463 echo "$as_me:1463: \$? = $ac_status" >&5
1464 (exit $ac_status); }
1466 cat >conftest.$ac_ext <<_ACEOF
1467 #line 1467 "configure"
1468 #include "confdefs.h"
1478 ac_clean_files_save=$ac_clean_files
1479 ac_clean_files="$ac_clean_files a.out a.exe"
1480 # Try to create an executable without -o first, disregard a.out.
1481 # It will help us diagnose broken compilers, and finding out an intuition
1483 echo "$as_me:1483: checking for C compiler default output" >&5
1484 echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
1485 ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
1486 if { (eval echo "$as_me:1486: \"$ac_link_default\"") >&5
1487 (eval $ac_link_default) 2>&5
1489 echo "$as_me:1489: \$? = $ac_status" >&5
1490 (exit $ac_status); }; then
1491 # Find the output, starting from the most likely. This scheme is
1492 # not robust to junk in `.', hence go to wildcards (a.*) only as a last
1494 for ac_file in `ls a.exe conftest.exe 2>/dev/null;
1495 ls a.out conftest 2>/dev/null;
1496 ls a.* conftest.* 2>/dev/null`; do
1498 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1499 a.out ) # We found the default executable, but exeext='' is most
1502 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1503 # FIXME: I believe we export ac_cv_exeext for Libtool --akim.
1510 echo "$as_me: failed program was:" >&5
1511 cat conftest.$ac_ext >&5
1512 { { echo "$as_me:1512: error: C compiler cannot create executables" >&5
1513 echo "$as_me: error: C compiler cannot create executables" >&2;}
1514 { (exit 77); exit 77; }; }
1517 ac_exeext=$ac_cv_exeext
1518 echo "$as_me:1518: result: $ac_file" >&5
1519 echo "${ECHO_T}$ac_file" >&6
1521 # Check the compiler produces executables we can run. If not, either
1522 # the compiler is broken, or we cross compile.
1523 echo "$as_me:1523: checking whether the C compiler works" >&5
1524 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
1525 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
1526 # If not cross compiling, check that we can run a simple program.
1527 if test "$cross_compiling" != yes; then
1528 if { ac_try='./$ac_file'
1529 { (eval echo "$as_me:1529: \"$ac_try\"") >&5
1532 echo "$as_me:1532: \$? = $ac_status" >&5
1533 (exit $ac_status); }; }; then
1536 if test "$cross_compiling" = maybe; then
1539 { { echo "$as_me:1539: error: cannot run C compiled programs.
1540 If you meant to cross compile, use \`--host'." >&5
1541 echo "$as_me: error: cannot run C compiled programs.
1542 If you meant to cross compile, use \`--host'." >&2;}
1543 { (exit 1); exit 1; }; }
1547 echo "$as_me:1547: result: yes" >&5
1548 echo "${ECHO_T}yes" >&6
1550 rm -f a.out a.exe conftest$ac_cv_exeext
1551 ac_clean_files=$ac_clean_files_save
1552 # Check the compiler produces executables we can run. If not, either
1553 # the compiler is broken, or we cross compile.
1554 echo "$as_me:1554: checking whether we are cross compiling" >&5
1555 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
1556 echo "$as_me:1556: result: $cross_compiling" >&5
1557 echo "${ECHO_T}$cross_compiling" >&6
1559 echo "$as_me:1559: checking for executable suffix" >&5
1560 echo $ECHO_N "checking for executable suffix... $ECHO_C" >&6
1561 if { (eval echo "$as_me:1561: \"$ac_link\"") >&5
1562 (eval $ac_link) 2>&5
1564 echo "$as_me:1564: \$? = $ac_status" >&5
1565 (exit $ac_status); }; then
1566 # If both `conftest.exe' and `conftest' are `present' (well, observable)
1567 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
1568 # work properly (i.e., refer to `conftest.exe'), while it won't with
1570 for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do
1572 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1573 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1580 { { echo "$as_me:1580: error: cannot compute EXEEXT: cannot compile and link" >&5
1581 echo "$as_me: error: cannot compute EXEEXT: cannot compile and link" >&2;}
1582 { (exit 1); exit 1; }; }
1585 rm -f conftest$ac_cv_exeext
1586 echo "$as_me:1586: result: $ac_cv_exeext" >&5
1587 echo "${ECHO_T}$ac_cv_exeext" >&6
1589 rm -f conftest.$ac_ext
1590 EXEEXT=$ac_cv_exeext
1592 echo "$as_me:1592: checking for object suffix" >&5
1593 echo $ECHO_N "checking for object suffix... $ECHO_C" >&6
1594 if test "${ac_cv_objext+set}" = set; then
1595 echo $ECHO_N "(cached) $ECHO_C" >&6
1597 cat >conftest.$ac_ext <<_ACEOF
1598 #line 1598 "configure"
1599 #include "confdefs.h"
1609 rm -f conftest.o conftest.obj
1610 if { (eval echo "$as_me:1610: \"$ac_compile\"") >&5
1611 (eval $ac_compile) 2>&5
1613 echo "$as_me:1613: \$? = $ac_status" >&5
1614 (exit $ac_status); }; then
1615 for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
1617 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.map | *.inf ) ;;
1618 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
1623 echo "$as_me: failed program was:" >&5
1624 cat conftest.$ac_ext >&5
1625 { { echo "$as_me:1625: error: cannot compute OBJEXT: cannot compile" >&5
1626 echo "$as_me: error: cannot compute OBJEXT: cannot compile" >&2;}
1627 { (exit 1); exit 1; }; }
1630 rm -f conftest.$ac_cv_objext conftest.$ac_ext
1632 echo "$as_me:1632: result: $ac_cv_objext" >&5
1633 echo "${ECHO_T}$ac_cv_objext" >&6
1634 OBJEXT=$ac_cv_objext
1636 echo "$as_me:1636: checking whether we are using the GNU C compiler" >&5
1637 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
1638 if test "${ac_cv_c_compiler_gnu+set}" = set; then
1639 echo $ECHO_N "(cached) $ECHO_C" >&6
1641 cat >conftest.$ac_ext <<_ACEOF
1642 #line 1642 "configure"
1643 #include "confdefs.h"
1656 rm -f conftest.$ac_objext
1657 if { (eval echo "$as_me:1657: \"$ac_compile\"") >&5
1658 (eval $ac_compile) 2>&5
1660 echo "$as_me:1660: \$? = $ac_status" >&5
1661 (exit $ac_status); } &&
1662 { ac_try='test -s conftest.$ac_objext'
1663 { (eval echo "$as_me:1663: \"$ac_try\"") >&5
1666 echo "$as_me:1666: \$? = $ac_status" >&5
1667 (exit $ac_status); }; }; then
1670 echo "$as_me: failed program was:" >&5
1671 cat conftest.$ac_ext >&5
1674 rm -f conftest.$ac_objext conftest.$ac_ext
1675 ac_cv_c_compiler_gnu=$ac_compiler_gnu
1678 echo "$as_me:1678: result: $ac_cv_c_compiler_gnu" >&5
1679 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
1680 GCC=`test $ac_compiler_gnu = yes && echo yes`
1681 ac_test_CFLAGS=${CFLAGS+set}
1682 ac_save_CFLAGS=$CFLAGS
1684 echo "$as_me:1684: checking whether $CC accepts -g" >&5
1685 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
1686 if test "${ac_cv_prog_cc_g+set}" = set; then
1687 echo $ECHO_N "(cached) $ECHO_C" >&6
1689 cat >conftest.$ac_ext <<_ACEOF
1690 #line 1690 "configure"
1691 #include "confdefs.h"
1701 rm -f conftest.$ac_objext
1702 if { (eval echo "$as_me:1702: \"$ac_compile\"") >&5
1703 (eval $ac_compile) 2>&5
1705 echo "$as_me:1705: \$? = $ac_status" >&5
1706 (exit $ac_status); } &&
1707 { ac_try='test -s conftest.$ac_objext'
1708 { (eval echo "$as_me:1708: \"$ac_try\"") >&5
1711 echo "$as_me:1711: \$? = $ac_status" >&5
1712 (exit $ac_status); }; }; then
1715 echo "$as_me: failed program was:" >&5
1716 cat conftest.$ac_ext >&5
1719 rm -f conftest.$ac_objext conftest.$ac_ext
1721 echo "$as_me:1721: result: $ac_cv_prog_cc_g" >&5
1722 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
1723 if test "$ac_test_CFLAGS" = set; then
1724 CFLAGS=$ac_save_CFLAGS
1725 elif test $ac_cv_prog_cc_g = yes; then
1726 if test "$GCC" = yes; then
1732 if test "$GCC" = yes; then
1738 # Some people use a C++ compiler to compile C. Since we use `exit',
1739 # in C++ we need to declare it. In case someone uses the same compiler
1740 # for both compiling C and C++ we need to have the C++ compiler decide
1741 # the declaration of exit, since it's the most demanding environment.
1742 cat >conftest.$ac_ext <<_ACEOF
1747 rm -f conftest.$ac_objext
1748 if { (eval echo "$as_me:1748: \"$ac_compile\"") >&5
1749 (eval $ac_compile) 2>&5
1751 echo "$as_me:1751: \$? = $ac_status" >&5
1752 (exit $ac_status); } &&
1753 { ac_try='test -s conftest.$ac_objext'
1754 { (eval echo "$as_me:1754: \"$ac_try\"") >&5
1757 echo "$as_me:1757: \$? = $ac_status" >&5
1758 (exit $ac_status); }; }; then
1759 for ac_declaration in \
1761 '#include <stdlib.h>' \
1762 'extern "C" void std::exit (int) throw (); using std::exit;' \
1763 'extern "C" void std::exit (int); using std::exit;' \
1764 'extern "C" void exit (int) throw ();' \
1765 'extern "C" void exit (int);' \
1768 cat >conftest.$ac_ext <<_ACEOF
1769 #line 1769 "configure"
1770 #include "confdefs.h"
1781 rm -f conftest.$ac_objext
1782 if { (eval echo "$as_me:1782: \"$ac_compile\"") >&5
1783 (eval $ac_compile) 2>&5
1785 echo "$as_me:1785: \$? = $ac_status" >&5
1786 (exit $ac_status); } &&
1787 { ac_try='test -s conftest.$ac_objext'
1788 { (eval echo "$as_me:1788: \"$ac_try\"") >&5
1791 echo "$as_me:1791: \$? = $ac_status" >&5
1792 (exit $ac_status); }; }; then
1795 echo "$as_me: failed program was:" >&5
1796 cat conftest.$ac_ext >&5
1799 rm -f conftest.$ac_objext conftest.$ac_ext
1800 cat >conftest.$ac_ext <<_ACEOF
1801 #line 1801 "configure"
1802 #include "confdefs.h"
1812 rm -f conftest.$ac_objext
1813 if { (eval echo "$as_me:1813: \"$ac_compile\"") >&5
1814 (eval $ac_compile) 2>&5
1816 echo "$as_me:1816: \$? = $ac_status" >&5
1817 (exit $ac_status); } &&
1818 { ac_try='test -s conftest.$ac_objext'
1819 { (eval echo "$as_me:1819: \"$ac_try\"") >&5
1822 echo "$as_me:1822: \$? = $ac_status" >&5
1823 (exit $ac_status); }; }; then
1826 echo "$as_me: failed program was:" >&5
1827 cat conftest.$ac_ext >&5
1829 rm -f conftest.$ac_objext conftest.$ac_ext
1832 if test -n "$ac_declaration"; then
1833 echo '#ifdef __cplusplus' >>confdefs.h
1834 echo $ac_declaration >>confdefs.h
1835 echo '#endif' >>confdefs.h
1839 echo "$as_me: failed program was:" >&5
1840 cat conftest.$ac_ext >&5
1842 rm -f conftest.$ac_objext conftest.$ac_ext
1844 ac_cpp='$CPP $CPPFLAGS'
1845 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1846 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1847 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1848 ac_main_return=return
1851 ac_cpp='$CPP $CPPFLAGS'
1852 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1853 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1854 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1855 ac_main_return=return
1856 echo "$as_me:1856: checking how to run the C preprocessor" >&5
1857 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
1858 # On Suns, sometimes $CPP names a directory.
1859 if test -n "$CPP" && test -d "$CPP"; then
1862 if test -z "$CPP"; then
1863 if test "${ac_cv_prog_CPP+set}" = set; then
1864 echo $ECHO_N "(cached) $ECHO_C" >&6
1866 # Double quotes because CPP needs to be expanded
1867 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
1870 for ac_c_preproc_warn_flag in '' yes
1872 # Use a header file that comes with gcc, so configuring glibc
1873 # with a fresh cross-compiler works.
1874 # On the NeXT, cc -E runs the code through the compiler's parser,
1875 # not just through cpp. "Syntax error" is here to catch this case.
1876 cat >conftest.$ac_ext <<_ACEOF
1877 #line 1877 "configure"
1878 #include "confdefs.h"
1882 if { (eval echo "$as_me:1882: \"$ac_cpp conftest.$ac_ext\"") >&5
1883 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
1885 egrep -v '^ *\+' conftest.er1 >conftest.err
1887 cat conftest.err >&5
1888 echo "$as_me:1888: \$? = $ac_status" >&5
1889 (exit $ac_status); } >/dev/null; then
1890 if test -s conftest.err; then
1891 ac_cpp_err=$ac_c_preproc_warn_flag
1898 if test -z "$ac_cpp_err"; then
1901 echo "$as_me: failed program was:" >&5
1902 cat conftest.$ac_ext >&5
1903 # Broken: fails on valid input.
1906 rm -f conftest.err conftest.$ac_ext
1908 # OK, works on sane cases. Now check whether non-existent headers
1909 # can be detected and how.
1910 cat >conftest.$ac_ext <<_ACEOF
1911 #line 1911 "configure"
1912 #include "confdefs.h"
1913 #include <ac_nonexistent.h>
1915 if { (eval echo "$as_me:1915: \"$ac_cpp conftest.$ac_ext\"") >&5
1916 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
1918 egrep -v '^ *\+' conftest.er1 >conftest.err
1920 cat conftest.err >&5
1921 echo "$as_me:1921: \$? = $ac_status" >&5
1922 (exit $ac_status); } >/dev/null; then
1923 if test -s conftest.err; then
1924 ac_cpp_err=$ac_c_preproc_warn_flag
1931 if test -z "$ac_cpp_err"; then
1932 # Broken: success on invalid input.
1935 echo "$as_me: failed program was:" >&5
1936 cat conftest.$ac_ext >&5
1937 # Passes both tests.
1941 rm -f conftest.err conftest.$ac_ext
1944 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
1945 rm -f conftest.err conftest.$ac_ext
1946 if $ac_preproc_ok; then
1958 echo "$as_me:1958: result: $CPP" >&5
1959 echo "${ECHO_T}$CPP" >&6
1961 for ac_c_preproc_warn_flag in '' yes
1963 # Use a header file that comes with gcc, so configuring glibc
1964 # with a fresh cross-compiler works.
1965 # On the NeXT, cc -E runs the code through the compiler's parser,
1966 # not just through cpp. "Syntax error" is here to catch this case.
1967 cat >conftest.$ac_ext <<_ACEOF
1968 #line 1968 "configure"
1969 #include "confdefs.h"
1973 if { (eval echo "$as_me:1973: \"$ac_cpp conftest.$ac_ext\"") >&5
1974 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
1976 egrep -v '^ *\+' conftest.er1 >conftest.err
1978 cat conftest.err >&5
1979 echo "$as_me:1979: \$? = $ac_status" >&5
1980 (exit $ac_status); } >/dev/null; then
1981 if test -s conftest.err; then
1982 ac_cpp_err=$ac_c_preproc_warn_flag
1989 if test -z "$ac_cpp_err"; then
1992 echo "$as_me: failed program was:" >&5
1993 cat conftest.$ac_ext >&5
1994 # Broken: fails on valid input.
1997 rm -f conftest.err conftest.$ac_ext
1999 # OK, works on sane cases. Now check whether non-existent headers
2000 # can be detected and how.
2001 cat >conftest.$ac_ext <<_ACEOF
2002 #line 2002 "configure"
2003 #include "confdefs.h"
2004 #include <ac_nonexistent.h>
2006 if { (eval echo "$as_me:2006: \"$ac_cpp conftest.$ac_ext\"") >&5
2007 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2009 egrep -v '^ *\+' conftest.er1 >conftest.err
2011 cat conftest.err >&5
2012 echo "$as_me:2012: \$? = $ac_status" >&5
2013 (exit $ac_status); } >/dev/null; then
2014 if test -s conftest.err; then
2015 ac_cpp_err=$ac_c_preproc_warn_flag
2022 if test -z "$ac_cpp_err"; then
2023 # Broken: success on invalid input.
2026 echo "$as_me: failed program was:" >&5
2027 cat conftest.$ac_ext >&5
2028 # Passes both tests.
2032 rm -f conftest.err conftest.$ac_ext
2035 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2036 rm -f conftest.err conftest.$ac_ext
2037 if $ac_preproc_ok; then
2040 { { echo "$as_me:2040: error: C preprocessor \"$CPP\" fails sanity check" >&5
2041 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;}
2042 { (exit 1); exit 1; }; }
2046 ac_cpp='$CPP $CPPFLAGS'
2047 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2048 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2049 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2050 ac_main_return=return
2052 for ac_prog in mawk gawk nawk awk
2054 # Extract the first word of "$ac_prog", so it can be a program name with args.
2055 set dummy $ac_prog; ac_word=$2
2056 echo "$as_me:2056: checking for $ac_word" >&5
2057 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2058 if test "${ac_cv_prog_AWK+set}" = set; then
2059 echo $ECHO_N "(cached) $ECHO_C" >&6
2061 if test -n "$AWK"; then
2062 ac_cv_prog_AWK="$AWK" # Let the user override the test.
2064 ac_save_IFS=$IFS; IFS=$ac_path_separator
2066 for ac_dir in $ac_dummy; do
2068 test -z "$ac_dir" && ac_dir=.
2069 $as_executable_p "$ac_dir/$ac_word" || continue
2070 ac_cv_prog_AWK="$ac_prog"
2071 echo "$as_me:2071: found $ac_dir/$ac_word" >&5
2078 if test -n "$AWK"; then
2079 echo "$as_me:2079: result: $AWK" >&5
2080 echo "${ECHO_T}$AWK" >&6
2082 echo "$as_me:2082: result: no" >&5
2083 echo "${ECHO_T}no" >&6
2086 test -n "$AWK" && break
2089 # Find a good install program. We prefer a C program (faster),
2090 # so one script is as good as another. But avoid the broken or
2091 # incompatible versions:
2092 # SysV /etc/install, /usr/sbin/install
2093 # SunOS /usr/etc/install
2094 # IRIX /sbin/install
2096 # AmigaOS /C/install, which installs bootblocks on floppy discs
2097 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
2098 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
2099 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
2100 # ./install, which can be erroneously created by make from ./install.sh.
2101 echo "$as_me:2101: checking for a BSD compatible install" >&5
2102 echo $ECHO_N "checking for a BSD compatible install... $ECHO_C" >&6
2103 if test -z "$INSTALL"; then
2104 if test "${ac_cv_path_install+set}" = set; then
2105 echo $ECHO_N "(cached) $ECHO_C" >&6
2107 ac_save_IFS=$IFS; IFS=$ac_path_separator
2108 for ac_dir in $PATH; do
2110 # Account for people who put trailing slashes in PATH elements.
2112 / | ./ | .// | /cC/* \
2113 | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* \
2116 # OSF1 and SCO ODT 3.0 have their own names for install.
2117 # Don't use installbsd from OSF since it installs stuff as root
2119 for ac_prog in ginstall scoinst install; do
2120 if $as_executable_p "$ac_dir/$ac_prog"; then
2121 if test $ac_prog = install &&
2122 grep dspmsg "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2123 # AIX install. It has an incompatible calling convention.
2125 elif test $ac_prog = install &&
2126 grep pwplus "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2127 # program-specific install script used by HP pwplus--don't use.
2130 ac_cv_path_install="$ac_dir/$ac_prog -c"
2140 if test "${ac_cv_path_install+set}" = set; then
2141 INSTALL=$ac_cv_path_install
2143 # As a last resort, use the slow shell script. We don't cache a
2144 # path for INSTALL within a source directory, because that will
2145 # break other packages using the cache if that directory is
2146 # removed, or if the path is relative.
2147 INSTALL=$ac_install_sh
2150 echo "$as_me:2150: result: $INSTALL" >&5
2151 echo "${ECHO_T}$INSTALL" >&6
2153 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
2154 # It thinks the first close brace ends the variable substitution.
2155 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
2157 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
2159 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
2165 cf_dir=`echo $INSTALL | sed -e 's%/[^/]*$%%'`
2166 test -z "$cf_dir" && cf_dir=.
2167 INSTALL=`cd $cf_dir && pwd`/`echo $INSTALL | sed -e 's%^.*/%%'`
2171 for ac_prog in tdlint lint alint splint lclint
2173 # Extract the first word of "$ac_prog", so it can be a program name with args.
2174 set dummy $ac_prog; ac_word=$2
2175 echo "$as_me:2175: checking for $ac_word" >&5
2176 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2177 if test "${ac_cv_prog_LINT+set}" = set; then
2178 echo $ECHO_N "(cached) $ECHO_C" >&6
2180 if test -n "$LINT"; then
2181 ac_cv_prog_LINT="$LINT" # Let the user override the test.
2183 ac_save_IFS=$IFS; IFS=$ac_path_separator
2185 for ac_dir in $ac_dummy; do
2187 test -z "$ac_dir" && ac_dir=.
2188 $as_executable_p "$ac_dir/$ac_word" || continue
2189 ac_cv_prog_LINT="$ac_prog"
2190 echo "$as_me:2190: found $ac_dir/$ac_word" >&5
2196 LINT=$ac_cv_prog_LINT
2197 if test -n "$LINT"; then
2198 echo "$as_me:2198: result: $LINT" >&5
2199 echo "${ECHO_T}$LINT" >&6
2201 echo "$as_me:2201: result: no" >&5
2202 echo "${ECHO_T}no" >&6
2205 test -n "$LINT" && break
2208 echo "$as_me:2208: checking if filesystem supports mixed-case filenames" >&5
2209 echo $ECHO_N "checking if filesystem supports mixed-case filenames... $ECHO_C" >&6
2210 if test "${cf_cv_mixedcase+set}" = set; then
2211 echo $ECHO_N "(cached) $ECHO_C" >&6
2214 if test "$cross_compiling" = yes ; then
2215 case $target_alias in #(vi
2216 *-os2-emx*|*-msdosdjgpp*|*-cygwin*|*-mingw32*|*-uwin*) #(vi
2224 rm -f conftest CONFTEST
2226 if test -f CONFTEST ; then
2231 rm -f conftest CONFTEST
2235 echo "$as_me:2235: result: $cf_cv_mixedcase" >&5
2236 echo "${ECHO_T}$cf_cv_mixedcase" >&6
2237 test "$cf_cv_mixedcase" = yes && cat >>confdefs.h <<\EOF
2238 #define MIXEDCASE_FILENAMES 1
2241 for ac_prog in exctags ctags
2243 # Extract the first word of "$ac_prog", so it can be a program name with args.
2244 set dummy $ac_prog; ac_word=$2
2245 echo "$as_me:2245: checking for $ac_word" >&5
2246 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2247 if test "${ac_cv_prog_CTAGS+set}" = set; then
2248 echo $ECHO_N "(cached) $ECHO_C" >&6
2250 if test -n "$CTAGS"; then
2251 ac_cv_prog_CTAGS="$CTAGS" # Let the user override the test.
2253 ac_save_IFS=$IFS; IFS=$ac_path_separator
2255 for ac_dir in $ac_dummy; do
2257 test -z "$ac_dir" && ac_dir=.
2258 $as_executable_p "$ac_dir/$ac_word" || continue
2259 ac_cv_prog_CTAGS="$ac_prog"
2260 echo "$as_me:2260: found $ac_dir/$ac_word" >&5
2266 CTAGS=$ac_cv_prog_CTAGS
2267 if test -n "$CTAGS"; then
2268 echo "$as_me:2268: result: $CTAGS" >&5
2269 echo "${ECHO_T}$CTAGS" >&6
2271 echo "$as_me:2271: result: no" >&5
2272 echo "${ECHO_T}no" >&6
2275 test -n "$CTAGS" && break
2278 for ac_prog in exetags etags
2280 # Extract the first word of "$ac_prog", so it can be a program name with args.
2281 set dummy $ac_prog; ac_word=$2
2282 echo "$as_me:2282: checking for $ac_word" >&5
2283 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2284 if test "${ac_cv_prog_ETAGS+set}" = set; then
2285 echo $ECHO_N "(cached) $ECHO_C" >&6
2287 if test -n "$ETAGS"; then
2288 ac_cv_prog_ETAGS="$ETAGS" # Let the user override the test.
2290 ac_save_IFS=$IFS; IFS=$ac_path_separator
2292 for ac_dir in $ac_dummy; do
2294 test -z "$ac_dir" && ac_dir=.
2295 $as_executable_p "$ac_dir/$ac_word" || continue
2296 ac_cv_prog_ETAGS="$ac_prog"
2297 echo "$as_me:2297: found $ac_dir/$ac_word" >&5
2303 ETAGS=$ac_cv_prog_ETAGS
2304 if test -n "$ETAGS"; then
2305 echo "$as_me:2305: result: $ETAGS" >&5
2306 echo "${ECHO_T}$ETAGS" >&6
2308 echo "$as_me:2308: result: no" >&5
2309 echo "${ECHO_T}no" >&6
2312 test -n "$ETAGS" && break
2315 # Extract the first word of "${CTAGS:-ctags}", so it can be a program name with args.
2316 set dummy ${CTAGS:-ctags}; ac_word=$2
2317 echo "$as_me:2317: checking for $ac_word" >&5
2318 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2319 if test "${ac_cv_prog_MAKE_LOWER_TAGS+set}" = set; then
2320 echo $ECHO_N "(cached) $ECHO_C" >&6
2322 if test -n "$MAKE_LOWER_TAGS"; then
2323 ac_cv_prog_MAKE_LOWER_TAGS="$MAKE_LOWER_TAGS" # Let the user override the test.
2325 ac_save_IFS=$IFS; IFS=$ac_path_separator
2327 for ac_dir in $ac_dummy; do
2329 test -z "$ac_dir" && ac_dir=.
2330 $as_executable_p "$ac_dir/$ac_word" || continue
2331 ac_cv_prog_MAKE_LOWER_TAGS="yes"
2332 echo "$as_me:2332: found $ac_dir/$ac_word" >&5
2336 test -z "$ac_cv_prog_MAKE_LOWER_TAGS" && ac_cv_prog_MAKE_LOWER_TAGS="no"
2339 MAKE_LOWER_TAGS=$ac_cv_prog_MAKE_LOWER_TAGS
2340 if test -n "$MAKE_LOWER_TAGS"; then
2341 echo "$as_me:2341: result: $MAKE_LOWER_TAGS" >&5
2342 echo "${ECHO_T}$MAKE_LOWER_TAGS" >&6
2344 echo "$as_me:2344: result: no" >&5
2345 echo "${ECHO_T}no" >&6
2348 if test "$cf_cv_mixedcase" = yes ; then
2349 # Extract the first word of "${ETAGS:-etags}", so it can be a program name with args.
2350 set dummy ${ETAGS:-etags}; ac_word=$2
2351 echo "$as_me:2351: checking for $ac_word" >&5
2352 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2353 if test "${ac_cv_prog_MAKE_UPPER_TAGS+set}" = set; then
2354 echo $ECHO_N "(cached) $ECHO_C" >&6
2356 if test -n "$MAKE_UPPER_TAGS"; then
2357 ac_cv_prog_MAKE_UPPER_TAGS="$MAKE_UPPER_TAGS" # Let the user override the test.
2359 ac_save_IFS=$IFS; IFS=$ac_path_separator
2361 for ac_dir in $ac_dummy; do
2363 test -z "$ac_dir" && ac_dir=.
2364 $as_executable_p "$ac_dir/$ac_word" || continue
2365 ac_cv_prog_MAKE_UPPER_TAGS="yes"
2366 echo "$as_me:2366: found $ac_dir/$ac_word" >&5
2370 test -z "$ac_cv_prog_MAKE_UPPER_TAGS" && ac_cv_prog_MAKE_UPPER_TAGS="no"
2373 MAKE_UPPER_TAGS=$ac_cv_prog_MAKE_UPPER_TAGS
2374 if test -n "$MAKE_UPPER_TAGS"; then
2375 echo "$as_me:2375: result: $MAKE_UPPER_TAGS" >&5
2376 echo "${ECHO_T}$MAKE_UPPER_TAGS" >&6
2378 echo "$as_me:2378: result: no" >&5
2379 echo "${ECHO_T}no" >&6
2386 if test "$MAKE_UPPER_TAGS" = yes ; then
2392 if test "$MAKE_LOWER_TAGS" = yes ; then
2398 echo "$as_me:2398: checking if -lm needed for math functions" >&5
2399 echo $ECHO_N "checking if -lm needed for math functions... $ECHO_C" >&6
2400 if test "${cf_cv_need_libm+set}" = set; then
2401 echo $ECHO_N "(cached) $ECHO_C" >&6
2404 cat >conftest.$ac_ext <<_ACEOF
2405 #line 2405 "configure"
2406 #include "confdefs.h"
2414 double x = rand(); printf("result = %g\n", sin(x))
2419 rm -f conftest.$ac_objext conftest$ac_exeext
2420 if { (eval echo "$as_me:2420: \"$ac_link\"") >&5
2421 (eval $ac_link) 2>&5
2423 echo "$as_me:2423: \$? = $ac_status" >&5
2424 (exit $ac_status); } &&
2425 { ac_try='test -s conftest$ac_exeext'
2426 { (eval echo "$as_me:2426: \"$ac_try\"") >&5
2429 echo "$as_me:2429: \$? = $ac_status" >&5
2430 (exit $ac_status); }; }; then
2433 echo "$as_me: failed program was:" >&5
2434 cat conftest.$ac_ext >&5
2437 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
2439 echo "$as_me:2439: result: $cf_cv_need_libm" >&5
2440 echo "${ECHO_T}$cf_cv_need_libm" >&6
2441 if test "$cf_cv_need_libm" = yes
2447 CC_SHARED_OPTS=unknown
2448 CPPFLAGS="$CPPFLAGS"
2450 DFT_OBJ_SUBDIR=`pwd|sed -e's:.*/::'`
2451 DFT_UPR_MODEL="NORMAL"
2467 TINFO_ARGS='$(LIBS_CURSES)'
2468 cf_cv_abi_version=""
2469 cf_cv_rel_version=""
2474 echo "$as_me:2474: checking for ${CC:-cc} option to accept ANSI C" >&5
2475 echo $ECHO_N "checking for ${CC:-cc} option to accept ANSI C... $ECHO_C" >&6
2476 if test "${cf_cv_ansi_cc+set}" = set; then
2477 echo $ECHO_N "(cached) $ECHO_C" >&6
2481 cf_save_CFLAGS="$CFLAGS"
2482 cf_save_CPPFLAGS="$CPPFLAGS"
2483 # Don't try gcc -ansi; that turns off useful extensions and
2484 # breaks some systems' header files.
2485 # AIX -qlanglvl=ansi
2486 # Ultrix and OSF/1 -std1
2487 # HP-UX -Aa -D_HPUX_SOURCE
2489 # UnixWare 1.2 (cannot use -Xc, since ANSI/POSIX clashes)
2490 for cf_arg in "-DCC_HAS_PROTOS" \
2495 "-Aa -D_HPUX_SOURCE" \
2502 cf_new_extra_cppflags=
2504 for cf_add_cflags in $cf_arg
2506 case $cf_fix_cppflags in
2508 case $cf_add_cflags in #(vi
2509 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
2510 case $cf_add_cflags in
2512 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
2514 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
2515 && test -z "${cf_tst_cflags}" \
2516 && cf_fix_cppflags=yes
2518 if test $cf_fix_cppflags = yes ; then
2519 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2521 elif test "${cf_tst_cflags}" = "\"'" ; then
2522 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2528 *$cf_add_cflags) #(vi
2531 case $cf_add_cflags in #(vi
2533 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
2535 CPPFLAGS=`echo "$CPPFLAGS" | \
2536 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
2537 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
2541 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
2546 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
2551 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2553 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
2555 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
2556 && test -z "${cf_tst_cflags}" \
2557 && cf_fix_cppflags=no
2562 if test -n "$cf_new_cflags" ; then
2564 CFLAGS="$CFLAGS $cf_new_cflags"
2567 if test -n "$cf_new_cppflags" ; then
2569 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
2572 if test -n "$cf_new_extra_cppflags" ; then
2574 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
2577 cat >conftest.$ac_ext <<_ACEOF
2578 #line 2578 "configure"
2579 #include "confdefs.h"
2581 #ifndef CC_HAS_PROTOS
2582 #if !defined(__STDC__) || (__STDC__ != 1)
2591 int test (int i, double x);
2592 struct s1 {int (*f) (int a);};
2593 struct s2 {int (*f) (double a);};
2598 rm -f conftest.$ac_objext
2599 if { (eval echo "$as_me:2599: \"$ac_compile\"") >&5
2600 (eval $ac_compile) 2>&5
2602 echo "$as_me:2602: \$? = $ac_status" >&5
2603 (exit $ac_status); } &&
2604 { ac_try='test -s conftest.$ac_objext'
2605 { (eval echo "$as_me:2605: \"$ac_try\"") >&5
2608 echo "$as_me:2608: \$? = $ac_status" >&5
2609 (exit $ac_status); }; }; then
2610 cf_cv_ansi_cc="$cf_arg"; break
2612 echo "$as_me: failed program was:" >&5
2613 cat conftest.$ac_ext >&5
2615 rm -f conftest.$ac_objext conftest.$ac_ext
2617 CFLAGS="$cf_save_CFLAGS"
2618 CPPFLAGS="$cf_save_CPPFLAGS"
2621 echo "$as_me:2621: result: $cf_cv_ansi_cc" >&5
2622 echo "${ECHO_T}$cf_cv_ansi_cc" >&6
2624 if test "$cf_cv_ansi_cc" != "no"; then
2625 if test ".$cf_cv_ansi_cc" != ".-DCC_HAS_PROTOS"; then
2630 cf_new_extra_cppflags=
2632 for cf_add_cflags in $cf_cv_ansi_cc
2634 case $cf_fix_cppflags in
2636 case $cf_add_cflags in #(vi
2637 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
2638 case $cf_add_cflags in
2640 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
2642 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
2643 && test -z "${cf_tst_cflags}" \
2644 && cf_fix_cppflags=yes
2646 if test $cf_fix_cppflags = yes ; then
2647 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2649 elif test "${cf_tst_cflags}" = "\"'" ; then
2650 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2656 *$cf_add_cflags) #(vi
2659 case $cf_add_cflags in #(vi
2661 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
2663 CPPFLAGS=`echo "$CPPFLAGS" | \
2664 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
2665 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
2669 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
2674 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
2679 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2681 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
2683 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
2684 && test -z "${cf_tst_cflags}" \
2685 && cf_fix_cppflags=no
2690 if test -n "$cf_new_cflags" ; then
2692 CFLAGS="$CFLAGS $cf_new_cflags"
2695 if test -n "$cf_new_cppflags" ; then
2697 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
2700 if test -n "$cf_new_extra_cppflags" ; then
2702 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
2706 cat >>confdefs.h <<\EOF
2707 #define CC_HAS_PROTOS 1
2713 if test "$cf_cv_ansi_cc" = "no"; then
2714 { { echo "$as_me:2714: error: Your compiler does not appear to recognize prototypes.
2715 You have the following choices:
2716 a. adjust your compiler options
2717 b. get an up-to-date compiler
2718 c. use a wrapper such as unproto" >&5
2719 echo "$as_me: error: Your compiler does not appear to recognize prototypes.
2720 You have the following choices:
2721 a. adjust your compiler options
2722 b. get an up-to-date compiler
2723 c. use a wrapper such as unproto" >&2;}
2724 { (exit 1); exit 1; }; }
2727 if test "$GCC" = yes
2729 cat > conftest.i <<EOF
2731 #define GCC_PRINTF 0
2736 #ifndef GCC_NORETURN
2737 #define GCC_NORETURN /* nothing */
2740 #define GCC_UNUSED /* nothing */
2743 if test "$GCC" = yes
2745 { echo "$as_me:2745: checking for $CC __attribute__ directives..." >&5
2746 echo "$as_me: checking for $CC __attribute__ directives..." >&6;}
2747 cat > conftest.$ac_ext <<EOF
2748 #line 2748 "${as_me:-configure}"
2749 #include "confdefs.h"
2750 #include "conftest.h"
2751 #include "conftest.i"
2753 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
2755 #define GCC_PRINTFLIKE(fmt,var) /*nothing*/
2758 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
2760 #define GCC_SCANFLIKE(fmt,var) /*nothing*/
2762 extern void wow(char *,...) GCC_SCANFLIKE(1,2);
2763 extern void oops(char *,...) GCC_PRINTFLIKE(1,2) GCC_NORETURN;
2764 extern void foo(void) GCC_NORETURN;
2765 int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { return 0; }
2767 cf_printf_attribute=no
2768 cf_scanf_attribute=no
2769 for cf_attribute in scanf printf unused noreturn
2772 cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
2774 cf_directive="__attribute__(($cf_attribute))"
2775 echo "checking for $CC $cf_directive" 1>&5
2777 case $cf_attribute in #(vi
2779 cf_printf_attribute=yes
2780 cat >conftest.h <<EOF
2781 #define GCC_$cf_ATTRIBUTE 1
2785 cf_scanf_attribute=yes
2786 cat >conftest.h <<EOF
2787 #define GCC_$cf_ATTRIBUTE 1
2791 cat >conftest.h <<EOF
2792 #define GCC_$cf_ATTRIBUTE $cf_directive
2797 if { (eval echo "$as_me:2797: \"$ac_compile\"") >&5
2798 (eval $ac_compile) 2>&5
2800 echo "$as_me:2800: \$? = $ac_status" >&5
2801 (exit $ac_status); }; then
2802 test -n "$verbose" && echo "$as_me:2802: result: ... $cf_attribute" >&5
2803 echo "${ECHO_T}... $cf_attribute" >&6
2804 cat conftest.h >>confdefs.h
2805 case $cf_attribute in #(vi
2807 if test "$cf_printf_attribute" = no ; then
2808 cat >>confdefs.h <<EOF
2809 #define GCC_PRINTFLIKE(fmt,var) /* nothing */
2812 cat >>confdefs.h <<EOF
2813 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
2818 if test "$cf_scanf_attribute" = no ; then
2819 cat >>confdefs.h <<EOF
2820 #define GCC_SCANFLIKE(fmt,var) /* nothing */
2823 cat >>confdefs.h <<EOF
2824 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
2832 fgrep define conftest.i >>confdefs.h
2838 cf_POSIX_C_SOURCE=199506L
2841 case $host_os in #(vi
2843 cf_xopen_source="-D_ALL_SOURCE"
2846 cf_xopen_source="-D_APPLE_C_SOURCE"
2849 cf_xopen_source="-D_DARWIN_C_SOURCE"
2851 freebsd*|dragonfly*) #(vi
2852 # 5.x headers associate
2853 # _XOPEN_SOURCE=600 with _POSIX_C_SOURCE=200112L
2854 # _XOPEN_SOURCE=500 with _POSIX_C_SOURCE=199506L
2855 cf_POSIX_C_SOURCE=200112L
2857 cf_xopen_source="-D_BSD_TYPES -D__BSD_VISIBLE -D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
2860 cf_xopen_source="-D_HPUX_SOURCE -D_XOPEN_SOURCE=500"
2863 cf_xopen_source="-D_HPUX_SOURCE"
2866 cf_xopen_source="-D_SGI_SOURCE"
2868 linux*|gnu*|mint*|k*bsd*-gnu) #(vi
2870 echo "$as_me:2870: checking if we must define _GNU_SOURCE" >&5
2871 echo $ECHO_N "checking if we must define _GNU_SOURCE... $ECHO_C" >&6
2872 if test "${cf_cv_gnu_source+set}" = set; then
2873 echo $ECHO_N "(cached) $ECHO_C" >&6
2876 cat >conftest.$ac_ext <<_ACEOF
2877 #line 2877 "configure"
2878 #include "confdefs.h"
2879 #include <sys/types.h>
2884 #ifndef _XOPEN_SOURCE
2891 rm -f conftest.$ac_objext
2892 if { (eval echo "$as_me:2892: \"$ac_compile\"") >&5
2893 (eval $ac_compile) 2>&5
2895 echo "$as_me:2895: \$? = $ac_status" >&5
2896 (exit $ac_status); } &&
2897 { ac_try='test -s conftest.$ac_objext'
2898 { (eval echo "$as_me:2898: \"$ac_try\"") >&5
2901 echo "$as_me:2901: \$? = $ac_status" >&5
2902 (exit $ac_status); }; }; then
2905 echo "$as_me: failed program was:" >&5
2906 cat conftest.$ac_ext >&5
2908 CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE"
2909 cat >conftest.$ac_ext <<_ACEOF
2910 #line 2910 "configure"
2911 #include "confdefs.h"
2912 #include <sys/types.h>
2917 #ifdef _XOPEN_SOURCE
2924 rm -f conftest.$ac_objext
2925 if { (eval echo "$as_me:2925: \"$ac_compile\"") >&5
2926 (eval $ac_compile) 2>&5
2928 echo "$as_me:2928: \$? = $ac_status" >&5
2929 (exit $ac_status); } &&
2930 { ac_try='test -s conftest.$ac_objext'
2931 { (eval echo "$as_me:2931: \"$ac_try\"") >&5
2934 echo "$as_me:2934: \$? = $ac_status" >&5
2935 (exit $ac_status); }; }; then
2938 echo "$as_me: failed program was:" >&5
2939 cat conftest.$ac_ext >&5
2940 cf_cv_gnu_source=yes
2942 rm -f conftest.$ac_objext conftest.$ac_ext
2946 rm -f conftest.$ac_objext conftest.$ac_ext
2949 echo "$as_me:2949: result: $cf_cv_gnu_source" >&5
2950 echo "${ECHO_T}$cf_cv_gnu_source" >&6
2951 test "$cf_cv_gnu_source" = yes && CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE"
2955 # setting _XOPEN_SOURCE or _POSIX_SOURCE breaks <arpa/inet.h>
2958 # setting _XOPEN_SOURCE breaks IPv6 for lynx on NetBSD 1.6, breaks xterm, is not needed for ncursesw
2961 # setting _XOPEN_SOURCE breaks xterm on OpenBSD 2.8, is not needed for ncursesw
2964 cf_xopen_source="-D_OSF_SOURCE"
2967 cf_xopen_source="-D_QNX_SOURCE"
2970 # setting _XOPEN_SOURCE breaks Lynx on SCO Unix / OpenServer
2972 solaris2.1[0-9]) #(vi
2973 cf_xopen_source="-D__EXTENSIONS__ -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
2975 solaris2.[1-9]) #(vi
2976 cf_xopen_source="-D__EXTENSIONS__"
2979 echo "$as_me:2979: checking if we should define _XOPEN_SOURCE" >&5
2980 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
2981 if test "${cf_cv_xopen_source+set}" = set; then
2982 echo $ECHO_N "(cached) $ECHO_C" >&6
2985 cat >conftest.$ac_ext <<_ACEOF
2986 #line 2986 "configure"
2987 #include "confdefs.h"
2988 #include <sys/types.h>
2993 #ifndef _XOPEN_SOURCE
3000 rm -f conftest.$ac_objext
3001 if { (eval echo "$as_me:3001: \"$ac_compile\"") >&5
3002 (eval $ac_compile) 2>&5
3004 echo "$as_me:3004: \$? = $ac_status" >&5
3005 (exit $ac_status); } &&
3006 { ac_try='test -s conftest.$ac_objext'
3007 { (eval echo "$as_me:3007: \"$ac_try\"") >&5
3010 echo "$as_me:3010: \$? = $ac_status" >&5
3011 (exit $ac_status); }; }; then
3012 cf_cv_xopen_source=no
3014 echo "$as_me: failed program was:" >&5
3015 cat conftest.$ac_ext >&5
3017 CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
3018 cat >conftest.$ac_ext <<_ACEOF
3019 #line 3019 "configure"
3020 #include "confdefs.h"
3021 #include <sys/types.h>
3026 #ifdef _XOPEN_SOURCE
3033 rm -f conftest.$ac_objext
3034 if { (eval echo "$as_me:3034: \"$ac_compile\"") >&5
3035 (eval $ac_compile) 2>&5
3037 echo "$as_me:3037: \$? = $ac_status" >&5
3038 (exit $ac_status); } &&
3039 { ac_try='test -s conftest.$ac_objext'
3040 { (eval echo "$as_me:3040: \"$ac_try\"") >&5
3043 echo "$as_me:3043: \$? = $ac_status" >&5
3044 (exit $ac_status); }; }; then
3045 cf_cv_xopen_source=no
3047 echo "$as_me: failed program was:" >&5
3048 cat conftest.$ac_ext >&5
3049 cf_cv_xopen_source=$cf_XOPEN_SOURCE
3051 rm -f conftest.$ac_objext conftest.$ac_ext
3055 rm -f conftest.$ac_objext conftest.$ac_ext
3058 echo "$as_me:3058: result: $cf_cv_xopen_source" >&5
3059 echo "${ECHO_T}$cf_cv_xopen_source" >&6
3060 if test "$cf_cv_xopen_source" != no ; then
3062 CFLAGS=`echo "$CFLAGS" | \
3063 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3064 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
3066 CPPFLAGS=`echo "$CPPFLAGS" | \
3067 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3068 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
3070 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
3075 cf_new_extra_cppflags=
3077 for cf_add_cflags in $cf_temp_xopen_source
3079 case $cf_fix_cppflags in
3081 case $cf_add_cflags in #(vi
3082 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
3083 case $cf_add_cflags in
3085 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3087 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3088 && test -z "${cf_tst_cflags}" \
3089 && cf_fix_cppflags=yes
3091 if test $cf_fix_cppflags = yes ; then
3092 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3094 elif test "${cf_tst_cflags}" = "\"'" ; then
3095 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3101 *$cf_add_cflags) #(vi
3104 case $cf_add_cflags in #(vi
3106 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3108 CPPFLAGS=`echo "$CPPFLAGS" | \
3109 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3110 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3114 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
3119 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
3124 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3126 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
3128 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3129 && test -z "${cf_tst_cflags}" \
3130 && cf_fix_cppflags=no
3135 if test -n "$cf_new_cflags" ; then
3137 CFLAGS="$CFLAGS $cf_new_cflags"
3140 if test -n "$cf_new_cppflags" ; then
3142 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
3145 if test -n "$cf_new_extra_cppflags" ; then
3147 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
3152 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
3154 cf_save_CFLAGS="$CFLAGS"
3155 cf_save_CPPFLAGS="$CPPFLAGS"
3157 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
3158 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3159 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
3161 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
3162 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3163 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
3165 echo "$as_me:3165: checking if we should define _POSIX_C_SOURCE" >&5
3166 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
3167 if test "${cf_cv_posix_c_source+set}" = set; then
3168 echo $ECHO_N "(cached) $ECHO_C" >&6
3171 echo "${as_me:-configure}:3171: testing if the symbol is already defined go no further ..." 1>&5
3173 cat >conftest.$ac_ext <<_ACEOF
3174 #line 3174 "configure"
3175 #include "confdefs.h"
3176 #include <sys/types.h>
3181 #ifndef _POSIX_C_SOURCE
3188 rm -f conftest.$ac_objext
3189 if { (eval echo "$as_me:3189: \"$ac_compile\"") >&5
3190 (eval $ac_compile) 2>&5
3192 echo "$as_me:3192: \$? = $ac_status" >&5
3193 (exit $ac_status); } &&
3194 { ac_try='test -s conftest.$ac_objext'
3195 { (eval echo "$as_me:3195: \"$ac_try\"") >&5
3198 echo "$as_me:3198: \$? = $ac_status" >&5
3199 (exit $ac_status); }; }; then
3200 cf_cv_posix_c_source=no
3202 echo "$as_me: failed program was:" >&5
3203 cat conftest.$ac_ext >&5
3204 cf_want_posix_source=no
3205 case .$cf_POSIX_C_SOURCE in #(vi
3207 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
3210 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
3211 cf_want_posix_source=yes
3214 cf_want_posix_source=yes
3217 if test "$cf_want_posix_source" = yes ; then
3218 cat >conftest.$ac_ext <<_ACEOF
3219 #line 3219 "configure"
3220 #include "confdefs.h"
3221 #include <sys/types.h>
3226 #ifdef _POSIX_SOURCE
3233 rm -f conftest.$ac_objext
3234 if { (eval echo "$as_me:3234: \"$ac_compile\"") >&5
3235 (eval $ac_compile) 2>&5
3237 echo "$as_me:3237: \$? = $ac_status" >&5
3238 (exit $ac_status); } &&
3239 { ac_try='test -s conftest.$ac_objext'
3240 { (eval echo "$as_me:3240: \"$ac_try\"") >&5
3243 echo "$as_me:3243: \$? = $ac_status" >&5
3244 (exit $ac_status); }; }; then
3247 echo "$as_me: failed program was:" >&5
3248 cat conftest.$ac_ext >&5
3249 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
3251 rm -f conftest.$ac_objext conftest.$ac_ext
3254 echo "${as_me:-configure}:3254: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
3256 CFLAGS="$cf_trim_CFLAGS"
3257 CPPFLAGS="$cf_trim_CPPFLAGS $cf_cv_posix_c_source"
3259 echo "${as_me:-configure}:3259: testing if the second compile does not leave our definition intact error ..." 1>&5
3261 cat >conftest.$ac_ext <<_ACEOF
3262 #line 3262 "configure"
3263 #include "confdefs.h"
3264 #include <sys/types.h>
3269 #ifndef _POSIX_C_SOURCE
3276 rm -f conftest.$ac_objext
3277 if { (eval echo "$as_me:3277: \"$ac_compile\"") >&5
3278 (eval $ac_compile) 2>&5
3280 echo "$as_me:3280: \$? = $ac_status" >&5
3281 (exit $ac_status); } &&
3282 { ac_try='test -s conftest.$ac_objext'
3283 { (eval echo "$as_me:3283: \"$ac_try\"") >&5
3286 echo "$as_me:3286: \$? = $ac_status" >&5
3287 (exit $ac_status); }; }; then
3290 echo "$as_me: failed program was:" >&5
3291 cat conftest.$ac_ext >&5
3292 cf_cv_posix_c_source=no
3294 rm -f conftest.$ac_objext conftest.$ac_ext
3295 CFLAGS="$cf_save_CFLAGS"
3296 CPPFLAGS="$cf_save_CPPFLAGS"
3299 rm -f conftest.$ac_objext conftest.$ac_ext
3302 echo "$as_me:3302: result: $cf_cv_posix_c_source" >&5
3303 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
3305 if test "$cf_cv_posix_c_source" != no ; then
3306 CFLAGS="$cf_trim_CFLAGS"
3307 CPPFLAGS="$cf_trim_CPPFLAGS"
3312 cf_new_extra_cppflags=
3314 for cf_add_cflags in $cf_cv_posix_c_source
3316 case $cf_fix_cppflags in
3318 case $cf_add_cflags in #(vi
3319 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
3320 case $cf_add_cflags in
3322 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3324 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3325 && test -z "${cf_tst_cflags}" \
3326 && cf_fix_cppflags=yes
3328 if test $cf_fix_cppflags = yes ; then
3329 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3331 elif test "${cf_tst_cflags}" = "\"'" ; then
3332 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3338 *$cf_add_cflags) #(vi
3341 case $cf_add_cflags in #(vi
3343 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3345 CPPFLAGS=`echo "$CPPFLAGS" | \
3346 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3347 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3351 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
3356 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
3361 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3363 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
3365 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3366 && test -z "${cf_tst_cflags}" \
3367 && cf_fix_cppflags=no
3372 if test -n "$cf_new_cflags" ; then
3374 CFLAGS="$CFLAGS $cf_new_cflags"
3377 if test -n "$cf_new_cppflags" ; then
3379 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
3382 if test -n "$cf_new_extra_cppflags" ; then
3384 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
3392 if test -n "$cf_xopen_source" ; then
3397 cf_new_extra_cppflags=
3399 for cf_add_cflags in $cf_xopen_source
3401 case $cf_fix_cppflags in
3403 case $cf_add_cflags in #(vi
3404 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
3405 case $cf_add_cflags in
3407 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3409 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3410 && test -z "${cf_tst_cflags}" \
3411 && cf_fix_cppflags=yes
3413 if test $cf_fix_cppflags = yes ; then
3414 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3416 elif test "${cf_tst_cflags}" = "\"'" ; then
3417 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3423 *$cf_add_cflags) #(vi
3426 case $cf_add_cflags in #(vi
3428 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3430 CPPFLAGS=`echo "$CPPFLAGS" | \
3431 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3432 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3436 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
3441 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
3446 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3448 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
3450 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3451 && test -z "${cf_tst_cflags}" \
3452 && cf_fix_cppflags=no
3457 if test -n "$cf_new_cflags" ; then
3459 CFLAGS="$CFLAGS $cf_new_cflags"
3462 if test -n "$cf_new_cppflags" ; then
3464 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
3467 if test -n "$cf_new_extra_cppflags" ; then
3469 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
3474 echo "$as_me:3474: checking for $CC option to accept ANSI C" >&5
3475 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
3476 if test "${ac_cv_prog_cc_stdc+set}" = set; then
3477 echo $ECHO_N "(cached) $ECHO_C" >&6
3479 ac_cv_prog_cc_stdc=no
3481 cat >conftest.$ac_ext <<_ACEOF
3482 #line 3482 "configure"
3483 #include "confdefs.h"
3486 #include <sys/types.h>
3487 #include <sys/stat.h>
3488 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
3489 struct buf { int x; };
3490 FILE * (*rcsopen) (struct buf *, struct stat *, int);
3491 static char *e (p, i)
3497 static char *f (char * (*g) (char **, int), char **p, ...)
3502 s = g (p, va_arg (v,int));
3506 int test (int i, double x);
3507 struct s1 {int (*f) (int a);};
3508 struct s2 {int (*f) (double a);};
3509 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3515 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
3520 # Don't try gcc -ansi; that turns off useful extensions and
3521 # breaks some systems' header files.
3522 # AIX -qlanglvl=ansi
3523 # Ultrix and OSF/1 -std1
3524 # HP-UX 10.20 and later -Ae
3525 # HP-UX older versions -Aa -D_HPUX_SOURCE
3526 # SVR4 -Xc -D__EXTENSIONS__
3527 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3529 CC="$ac_save_CC $ac_arg"
3530 rm -f conftest.$ac_objext
3531 if { (eval echo "$as_me:3531: \"$ac_compile\"") >&5
3532 (eval $ac_compile) 2>&5
3534 echo "$as_me:3534: \$? = $ac_status" >&5
3535 (exit $ac_status); } &&
3536 { ac_try='test -s conftest.$ac_objext'
3537 { (eval echo "$as_me:3537: \"$ac_try\"") >&5
3540 echo "$as_me:3540: \$? = $ac_status" >&5
3541 (exit $ac_status); }; }; then
3542 ac_cv_prog_cc_stdc=$ac_arg
3545 echo "$as_me: failed program was:" >&5
3546 cat conftest.$ac_ext >&5
3548 rm -f conftest.$ac_objext
3550 rm -f conftest.$ac_ext conftest.$ac_objext
3555 case "x$ac_cv_prog_cc_stdc" in
3557 echo "$as_me:3557: result: none needed" >&5
3558 echo "${ECHO_T}none needed" >&6 ;;
3560 echo "$as_me:3560: result: $ac_cv_prog_cc_stdc" >&5
3561 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
3562 CC="$CC $ac_cv_prog_cc_stdc" ;;
3565 echo "$as_me:3565: checking for an ANSI C-conforming const" >&5
3566 echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
3567 if test "${ac_cv_c_const+set}" = set; then
3568 echo $ECHO_N "(cached) $ECHO_C" >&6
3570 cat >conftest.$ac_ext <<_ACEOF
3571 #line 3571 "configure"
3572 #include "confdefs.h"
3577 /* FIXME: Include the comments suggested by Paul. */
3579 /* Ultrix mips cc rejects this. */
3580 typedef int charset[2];
3582 /* SunOS 4.1.1 cc rejects this. */
3583 char const *const *ccp;
3585 /* NEC SVR4.0.2 mips cc rejects this. */
3586 struct point {int x, y;};
3587 static struct point const zero = {0,0};
3588 /* AIX XL C 1.02.0.0 rejects this.
3589 It does not let you subtract one const X* pointer from another in
3590 an arm of an if-expression whose if-part is not a constant
3592 const char *g = "string";
3593 ccp = &g + (g ? g-g : 0);
3594 /* HPUX 7.0 cc rejects these. */
3597 ccp = (char const *const *) p;
3598 { /* SCO 3.2v4 cc rejects this. */
3600 char const *s = 0 ? (char *) 0 : (char const *) 0;
3604 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
3606 const int *foo = &x[0];
3609 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
3610 typedef const int *iptr;
3614 { /* AIX XL C 1.02.0.0 rejects this saying
3615 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
3616 struct s { int j; const int *ap[3]; };
3617 struct s *b; b->j = 5;
3619 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
3628 rm -f conftest.$ac_objext
3629 if { (eval echo "$as_me:3629: \"$ac_compile\"") >&5
3630 (eval $ac_compile) 2>&5
3632 echo "$as_me:3632: \$? = $ac_status" >&5
3633 (exit $ac_status); } &&
3634 { ac_try='test -s conftest.$ac_objext'
3635 { (eval echo "$as_me:3635: \"$ac_try\"") >&5
3638 echo "$as_me:3638: \$? = $ac_status" >&5
3639 (exit $ac_status); }; }; then
3642 echo "$as_me: failed program was:" >&5
3643 cat conftest.$ac_ext >&5
3646 rm -f conftest.$ac_objext conftest.$ac_ext
3648 echo "$as_me:3648: result: $ac_cv_c_const" >&5
3649 echo "${ECHO_T}$ac_cv_c_const" >&6
3650 if test $ac_cv_c_const = no; then
3652 cat >>confdefs.h <<\EOF
3658 echo "$as_me:3658: checking for signal global datatype" >&5
3659 echo $ECHO_N "checking for signal global datatype... $ECHO_C" >&6
3660 if test "${cf_cv_sig_atomic_t+set}" = set; then
3661 echo $ECHO_N "(cached) $ECHO_C" >&6
3665 "volatile sig_atomic_t" \
3669 cat >conftest.$ac_ext <<_ACEOF
3670 #line 3670 "configure"
3671 #include "confdefs.h"
3673 #include <sys/types.h>
3679 static void handler(int sig)
3686 signal(SIGINT, handler);
3692 rm -f conftest.$ac_objext
3693 if { (eval echo "$as_me:3693: \"$ac_compile\"") >&5
3694 (eval $ac_compile) 2>&5
3696 echo "$as_me:3696: \$? = $ac_status" >&5
3697 (exit $ac_status); } &&
3698 { ac_try='test -s conftest.$ac_objext'
3699 { (eval echo "$as_me:3699: \"$ac_try\"") >&5
3702 echo "$as_me:3702: \$? = $ac_status" >&5
3703 (exit $ac_status); }; }; then
3704 cf_cv_sig_atomic_t=$cf_type
3706 echo "$as_me: failed program was:" >&5
3707 cat conftest.$ac_ext >&5
3708 cf_cv_sig_atomic_t=no
3710 rm -f conftest.$ac_objext conftest.$ac_ext
3711 test "$cf_cv_sig_atomic_t" != no && break
3716 echo "$as_me:3716: result: $cf_cv_sig_atomic_t" >&5
3717 echo "${ECHO_T}$cf_cv_sig_atomic_t" >&6
3718 test "$cf_cv_sig_atomic_t" != no && cat >>confdefs.h <<EOF
3719 #define SIG_ATOMIC_T $cf_cv_sig_atomic_t
3722 echo "$as_me:3722: checking if you want to see long compiling messages" >&5
3723 echo $ECHO_N "checking if you want to see long compiling messages... $ECHO_C" >&6
3725 # Check whether --enable-echo or --disable-echo was given.
3726 if test "${enable_echo+set}" = set; then
3727 enableval="$enable_echo"
3728 test "$enableval" != no && enableval=yes
3729 if test "$enableval" != "yes" ; then
3732 ECHO_LD='@echo linking $@;'
3733 RULE_CC='@echo compiling $<'
3734 SHOW_CC='@echo compiling $@'
3756 echo "$as_me:3756: result: $enableval" >&5
3757 echo "${ECHO_T}$enableval" >&6
3760 if test "$GCC" = yes ; then
3761 echo "$as_me:3761: checking version of $CC" >&5
3762 echo $ECHO_N "checking version of $CC... $ECHO_C" >&6
3763 GCC_VERSION="`${CC} --version 2>/dev/null | sed -e '2,$d' -e 's/^.*(GCC) //' -e 's/^[^0-9.]*//' -e 's/[^0-9.].*//'`"
3764 test -z "$GCC_VERSION" && GCC_VERSION=unknown
3765 echo "$as_me:3765: result: $GCC_VERSION" >&5
3766 echo "${ECHO_T}$GCC_VERSION" >&6
3769 if ( test "$GCC" = yes || test "$GXX" = yes )
3771 echo "$as_me:3771: checking if you want to turn on gcc warnings" >&5
3772 echo $ECHO_N "checking if you want to turn on gcc warnings... $ECHO_C" >&6
3774 # Check whether --enable-warnings or --disable-warnings was given.
3775 if test "${enable_warnings+set}" = set; then
3776 enableval="$enable_warnings"
3777 test "$enableval" != yes && enableval=no
3778 if test "$enableval" != "no" ; then
3788 echo "$as_me:3788: result: $with_warnings" >&5
3789 echo "${ECHO_T}$with_warnings" >&6
3790 if test "$with_warnings" = "yes"
3793 if test "$GCC" = yes
3795 cat > conftest.i <<EOF
3797 #define GCC_PRINTF 0
3802 #ifndef GCC_NORETURN
3803 #define GCC_NORETURN /* nothing */
3806 #define GCC_UNUSED /* nothing */
3809 if test "$GCC" = yes
3811 { echo "$as_me:3811: checking for $CC __attribute__ directives..." >&5
3812 echo "$as_me: checking for $CC __attribute__ directives..." >&6;}
3813 cat > conftest.$ac_ext <<EOF
3814 #line 3814 "${as_me:-configure}"
3815 #include "confdefs.h"
3816 #include "conftest.h"
3817 #include "conftest.i"
3819 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
3821 #define GCC_PRINTFLIKE(fmt,var) /*nothing*/
3824 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
3826 #define GCC_SCANFLIKE(fmt,var) /*nothing*/
3828 extern void wow(char *,...) GCC_SCANFLIKE(1,2);
3829 extern void oops(char *,...) GCC_PRINTFLIKE(1,2) GCC_NORETURN;
3830 extern void foo(void) GCC_NORETURN;
3831 int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { return 0; }
3833 cf_printf_attribute=no
3834 cf_scanf_attribute=no
3835 for cf_attribute in scanf printf unused noreturn
3838 cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
3840 cf_directive="__attribute__(($cf_attribute))"
3841 echo "checking for $CC $cf_directive" 1>&5
3843 case $cf_attribute in #(vi
3845 cf_printf_attribute=yes
3846 cat >conftest.h <<EOF
3847 #define GCC_$cf_ATTRIBUTE 1
3851 cf_scanf_attribute=yes
3852 cat >conftest.h <<EOF
3853 #define GCC_$cf_ATTRIBUTE 1
3857 cat >conftest.h <<EOF
3858 #define GCC_$cf_ATTRIBUTE $cf_directive
3863 if { (eval echo "$as_me:3863: \"$ac_compile\"") >&5
3864 (eval $ac_compile) 2>&5
3866 echo "$as_me:3866: \$? = $ac_status" >&5
3867 (exit $ac_status); }; then
3868 test -n "$verbose" && echo "$as_me:3868: result: ... $cf_attribute" >&5
3869 echo "${ECHO_T}... $cf_attribute" >&6
3870 cat conftest.h >>confdefs.h
3871 case $cf_attribute in #(vi
3873 if test "$cf_printf_attribute" = no ; then
3874 cat >>confdefs.h <<EOF
3875 #define GCC_PRINTFLIKE(fmt,var) /* nothing */
3878 cat >>confdefs.h <<EOF
3879 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
3884 if test "$cf_scanf_attribute" = no ; then
3885 cat >>confdefs.h <<EOF
3886 #define GCC_SCANFLIKE(fmt,var) /* nothing */
3889 cat >>confdefs.h <<EOF
3890 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
3898 fgrep define conftest.i >>confdefs.h
3905 if test "$GCC" = yes ; then
3908 echo "$as_me:3908: checking if this is really Intel C compiler" >&5
3909 echo $ECHO_N "checking if this is really Intel C compiler... $ECHO_C" >&6
3910 cf_save_CFLAGS="$CFLAGS"
3911 CFLAGS="$CFLAGS -no-gcc"
3912 cat >conftest.$ac_ext <<_ACEOF
3913 #line 3913 "configure"
3914 #include "confdefs.h"
3920 #ifdef __INTEL_COMPILER
3929 rm -f conftest.$ac_objext
3930 if { (eval echo "$as_me:3930: \"$ac_compile\"") >&5
3931 (eval $ac_compile) 2>&5
3933 echo "$as_me:3933: \$? = $ac_status" >&5
3934 (exit $ac_status); } &&
3935 { ac_try='test -s conftest.$ac_objext'
3936 { (eval echo "$as_me:3936: \"$ac_try\"") >&5
3939 echo "$as_me:3939: \$? = $ac_status" >&5
3940 (exit $ac_status); }; }; then
3942 cf_save_CFLAGS="$cf_save_CFLAGS -we147 -no-gcc"
3945 echo "$as_me: failed program was:" >&5
3946 cat conftest.$ac_ext >&5
3948 rm -f conftest.$ac_objext conftest.$ac_ext
3949 CFLAGS="$cf_save_CFLAGS"
3950 echo "$as_me:3950: result: $INTEL_COMPILER" >&5
3951 echo "${ECHO_T}$INTEL_COMPILER" >&6
3956 cat > conftest.$ac_ext <<EOF
3957 #line 3957 "${as_me:-configure}"
3958 int main(int argc, char *argv[]) { return (argv[argc-1] == 0) ; }
3961 if test "$INTEL_COMPILER" = yes
3963 # The "-wdXXX" options suppress warnings:
3964 # remark #1419: external declaration in primary source file
3965 # remark #1683: explicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem)
3966 # remark #1684: conversion from pointer to same-sized integral type (potential portability problem)
3967 # remark #193: zero used for undefined preprocessing identifier
3968 # remark #593: variable "curs_sb_left_arrow" was set but never used
3969 # remark #810: conversion from "int" to "Dimension={unsigned short}" may lose significant bits
3970 # remark #869: parameter "tw" was never referenced
3971 # remark #981: operands are evaluated in unspecified order
3972 # warning #279: controlling expression is constant
3974 { echo "$as_me:3974: checking for $CC warning options..." >&5
3975 echo "$as_me: checking for $CC warning options..." >&6;}
3976 cf_save_CFLAGS="$CFLAGS"
3977 EXTRA_CFLAGS="-Wall"
3989 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
3990 if { (eval echo "$as_me:3990: \"$ac_compile\"") >&5
3991 (eval $ac_compile) 2>&5
3993 echo "$as_me:3993: \$? = $ac_status" >&5
3994 (exit $ac_status); }; then
3995 test -n "$verbose" && echo "$as_me:3995: result: ... -$cf_opt" >&5
3996 echo "${ECHO_T}... -$cf_opt" >&6
3997 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
4000 CFLAGS="$cf_save_CFLAGS"
4002 elif test "$GCC" = yes
4004 { echo "$as_me:4004: checking for $CC warning options..." >&5
4005 echo "$as_me: checking for $CC warning options..." >&6;}
4006 cf_save_CFLAGS="$CFLAGS"
4009 test "$with_ext_const" = yes && cf_warn_CONST="Wwrite-strings"
4010 for cf_opt in W Wall \
4011 Wbad-function-cast \
4015 Wmissing-declarations \
4016 Wmissing-prototypes \
4020 Wstrict-prototypes \
4021 Wundef $cf_warn_CONST
4023 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
4024 if { (eval echo "$as_me:4024: \"$ac_compile\"") >&5
4025 (eval $ac_compile) 2>&5
4027 echo "$as_me:4027: \$? = $ac_status" >&5
4028 (exit $ac_status); }; then
4029 test -n "$verbose" && echo "$as_me:4029: result: ... -$cf_opt" >&5
4030 echo "${ECHO_T}... -$cf_opt" >&6
4031 case $cf_opt in #(vi
4033 CPPFLAGS="$CPPFLAGS -DXTSTRINGDEFINES"
4036 case $GCC_VERSION in
4038 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
4040 echo "${as_me:-configure}:4040: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
4046 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
4049 CFLAGS="$cf_save_CFLAGS"
4056 echo "$as_me:4056: checking if you want to use dmalloc for testing" >&5
4057 echo $ECHO_N "checking if you want to use dmalloc for testing... $ECHO_C" >&6
4059 # Check whether --with-dmalloc or --without-dmalloc was given.
4060 if test "${with_dmalloc+set}" = set; then
4061 withval="$with_dmalloc"
4062 cat >>confdefs.h <<\EOF
4063 #define USE_DMALLOC 1
4066 : ${with_cflags:=-g}
4067 : ${with_no_leaks:=yes}
4072 echo "$as_me:4072: result: ${with_dmalloc:-no}" >&5
4073 echo "${ECHO_T}${with_dmalloc:-no}" >&6
4075 case .$with_cflags in #(vi
4077 case .$CFLAGS in #(vi
4085 cf_new_extra_cppflags=
4087 for cf_add_cflags in -g
4089 case $cf_fix_cppflags in
4091 case $cf_add_cflags in #(vi
4092 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
4093 case $cf_add_cflags in
4095 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4097 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
4098 && test -z "${cf_tst_cflags}" \
4099 && cf_fix_cppflags=yes
4101 if test $cf_fix_cppflags = yes ; then
4102 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4104 elif test "${cf_tst_cflags}" = "\"'" ; then
4105 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4111 *$cf_add_cflags) #(vi
4114 case $cf_add_cflags in #(vi
4116 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4118 CPPFLAGS=`echo "$CPPFLAGS" | \
4119 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4120 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4124 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
4129 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
4134 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4136 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
4138 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
4139 && test -z "${cf_tst_cflags}" \
4140 && cf_fix_cppflags=no
4145 if test -n "$cf_new_cflags" ; then
4147 CFLAGS="$CFLAGS $cf_new_cflags"
4150 if test -n "$cf_new_cppflags" ; then
4152 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
4155 if test -n "$cf_new_extra_cppflags" ; then
4157 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
4165 if test "$with_dmalloc" = yes ; then
4166 echo "$as_me:4166: checking for dmalloc.h" >&5
4167 echo $ECHO_N "checking for dmalloc.h... $ECHO_C" >&6
4168 if test "${ac_cv_header_dmalloc_h+set}" = set; then
4169 echo $ECHO_N "(cached) $ECHO_C" >&6
4171 cat >conftest.$ac_ext <<_ACEOF
4172 #line 4172 "configure"
4173 #include "confdefs.h"
4174 #include <dmalloc.h>
4176 if { (eval echo "$as_me:4176: \"$ac_cpp conftest.$ac_ext\"") >&5
4177 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4179 egrep -v '^ *\+' conftest.er1 >conftest.err
4181 cat conftest.err >&5
4182 echo "$as_me:4182: \$? = $ac_status" >&5
4183 (exit $ac_status); } >/dev/null; then
4184 if test -s conftest.err; then
4185 ac_cpp_err=$ac_c_preproc_warn_flag
4192 if test -z "$ac_cpp_err"; then
4193 ac_cv_header_dmalloc_h=yes
4195 echo "$as_me: failed program was:" >&5
4196 cat conftest.$ac_ext >&5
4197 ac_cv_header_dmalloc_h=no
4199 rm -f conftest.err conftest.$ac_ext
4201 echo "$as_me:4201: result: $ac_cv_header_dmalloc_h" >&5
4202 echo "${ECHO_T}$ac_cv_header_dmalloc_h" >&6
4203 if test $ac_cv_header_dmalloc_h = yes; then
4205 echo "$as_me:4205: checking for dmalloc_debug in -ldmalloc" >&5
4206 echo $ECHO_N "checking for dmalloc_debug in -ldmalloc... $ECHO_C" >&6
4207 if test "${ac_cv_lib_dmalloc_dmalloc_debug+set}" = set; then
4208 echo $ECHO_N "(cached) $ECHO_C" >&6
4210 ac_check_lib_save_LIBS=$LIBS
4211 LIBS="-ldmalloc $LIBS"
4212 cat >conftest.$ac_ext <<_ACEOF
4213 #line 4213 "configure"
4214 #include "confdefs.h"
4216 /* Override any gcc2 internal prototype to avoid an error. */
4220 /* We use char because int might match the return type of a gcc2
4221 builtin and then its argument prototype would still apply. */
4222 char dmalloc_debug ();
4231 rm -f conftest.$ac_objext conftest$ac_exeext
4232 if { (eval echo "$as_me:4232: \"$ac_link\"") >&5
4233 (eval $ac_link) 2>&5
4235 echo "$as_me:4235: \$? = $ac_status" >&5
4236 (exit $ac_status); } &&
4237 { ac_try='test -s conftest$ac_exeext'
4238 { (eval echo "$as_me:4238: \"$ac_try\"") >&5
4241 echo "$as_me:4241: \$? = $ac_status" >&5
4242 (exit $ac_status); }; }; then
4243 ac_cv_lib_dmalloc_dmalloc_debug=yes
4245 echo "$as_me: failed program was:" >&5
4246 cat conftest.$ac_ext >&5
4247 ac_cv_lib_dmalloc_dmalloc_debug=no
4249 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4250 LIBS=$ac_check_lib_save_LIBS
4252 echo "$as_me:4252: result: $ac_cv_lib_dmalloc_dmalloc_debug" >&5
4253 echo "${ECHO_T}$ac_cv_lib_dmalloc_dmalloc_debug" >&6
4254 if test $ac_cv_lib_dmalloc_dmalloc_debug = yes; then
4255 cat >>confdefs.h <<EOF
4256 #define HAVE_LIBDMALLOC 1
4259 LIBS="-ldmalloc $LIBS"
4267 echo "$as_me:4267: checking if you want to use dbmalloc for testing" >&5
4268 echo $ECHO_N "checking if you want to use dbmalloc for testing... $ECHO_C" >&6
4270 # Check whether --with-dbmalloc or --without-dbmalloc was given.
4271 if test "${with_dbmalloc+set}" = set; then
4272 withval="$with_dbmalloc"
4273 cat >>confdefs.h <<\EOF
4274 #define USE_DBMALLOC 1
4277 : ${with_cflags:=-g}
4278 : ${with_no_leaks:=yes}
4283 echo "$as_me:4283: result: ${with_dbmalloc:-no}" >&5
4284 echo "${ECHO_T}${with_dbmalloc:-no}" >&6
4286 case .$with_cflags in #(vi
4288 case .$CFLAGS in #(vi
4296 cf_new_extra_cppflags=
4298 for cf_add_cflags in -g
4300 case $cf_fix_cppflags in
4302 case $cf_add_cflags in #(vi
4303 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
4304 case $cf_add_cflags in
4306 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4308 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
4309 && test -z "${cf_tst_cflags}" \
4310 && cf_fix_cppflags=yes
4312 if test $cf_fix_cppflags = yes ; then
4313 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4315 elif test "${cf_tst_cflags}" = "\"'" ; then
4316 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4322 *$cf_add_cflags) #(vi
4325 case $cf_add_cflags in #(vi
4327 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4329 CPPFLAGS=`echo "$CPPFLAGS" | \
4330 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4331 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4335 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
4340 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
4345 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4347 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
4349 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
4350 && test -z "${cf_tst_cflags}" \
4351 && cf_fix_cppflags=no
4356 if test -n "$cf_new_cflags" ; then
4358 CFLAGS="$CFLAGS $cf_new_cflags"
4361 if test -n "$cf_new_cppflags" ; then
4363 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
4366 if test -n "$cf_new_extra_cppflags" ; then
4368 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
4376 if test "$with_dbmalloc" = yes ; then
4377 echo "$as_me:4377: checking for dbmalloc.h" >&5
4378 echo $ECHO_N "checking for dbmalloc.h... $ECHO_C" >&6
4379 if test "${ac_cv_header_dbmalloc_h+set}" = set; then
4380 echo $ECHO_N "(cached) $ECHO_C" >&6
4382 cat >conftest.$ac_ext <<_ACEOF
4383 #line 4383 "configure"
4384 #include "confdefs.h"
4385 #include <dbmalloc.h>
4387 if { (eval echo "$as_me:4387: \"$ac_cpp conftest.$ac_ext\"") >&5
4388 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4390 egrep -v '^ *\+' conftest.er1 >conftest.err
4392 cat conftest.err >&5
4393 echo "$as_me:4393: \$? = $ac_status" >&5
4394 (exit $ac_status); } >/dev/null; then
4395 if test -s conftest.err; then
4396 ac_cpp_err=$ac_c_preproc_warn_flag
4403 if test -z "$ac_cpp_err"; then
4404 ac_cv_header_dbmalloc_h=yes
4406 echo "$as_me: failed program was:" >&5
4407 cat conftest.$ac_ext >&5
4408 ac_cv_header_dbmalloc_h=no
4410 rm -f conftest.err conftest.$ac_ext
4412 echo "$as_me:4412: result: $ac_cv_header_dbmalloc_h" >&5
4413 echo "${ECHO_T}$ac_cv_header_dbmalloc_h" >&6
4414 if test $ac_cv_header_dbmalloc_h = yes; then
4416 echo "$as_me:4416: checking for debug_malloc in -ldbmalloc" >&5
4417 echo $ECHO_N "checking for debug_malloc in -ldbmalloc... $ECHO_C" >&6
4418 if test "${ac_cv_lib_dbmalloc_debug_malloc+set}" = set; then
4419 echo $ECHO_N "(cached) $ECHO_C" >&6
4421 ac_check_lib_save_LIBS=$LIBS
4422 LIBS="-ldbmalloc $LIBS"
4423 cat >conftest.$ac_ext <<_ACEOF
4424 #line 4424 "configure"
4425 #include "confdefs.h"
4427 /* Override any gcc2 internal prototype to avoid an error. */
4431 /* We use char because int might match the return type of a gcc2
4432 builtin and then its argument prototype would still apply. */
4433 char debug_malloc ();
4442 rm -f conftest.$ac_objext conftest$ac_exeext
4443 if { (eval echo "$as_me:4443: \"$ac_link\"") >&5
4444 (eval $ac_link) 2>&5
4446 echo "$as_me:4446: \$? = $ac_status" >&5
4447 (exit $ac_status); } &&
4448 { ac_try='test -s conftest$ac_exeext'
4449 { (eval echo "$as_me:4449: \"$ac_try\"") >&5
4452 echo "$as_me:4452: \$? = $ac_status" >&5
4453 (exit $ac_status); }; }; then
4454 ac_cv_lib_dbmalloc_debug_malloc=yes
4456 echo "$as_me: failed program was:" >&5
4457 cat conftest.$ac_ext >&5
4458 ac_cv_lib_dbmalloc_debug_malloc=no
4460 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4461 LIBS=$ac_check_lib_save_LIBS
4463 echo "$as_me:4463: result: $ac_cv_lib_dbmalloc_debug_malloc" >&5
4464 echo "${ECHO_T}$ac_cv_lib_dbmalloc_debug_malloc" >&6
4465 if test $ac_cv_lib_dbmalloc_debug_malloc = yes; then
4466 cat >>confdefs.h <<EOF
4467 #define HAVE_LIBDBMALLOC 1
4470 LIBS="-ldbmalloc $LIBS"
4478 echo "$as_me:4478: checking if you want to use valgrind for testing" >&5
4479 echo $ECHO_N "checking if you want to use valgrind for testing... $ECHO_C" >&6
4481 # Check whether --with-valgrind or --without-valgrind was given.
4482 if test "${with_valgrind+set}" = set; then
4483 withval="$with_valgrind"
4484 cat >>confdefs.h <<\EOF
4485 #define USE_VALGRIND 1
4488 : ${with_cflags:=-g}
4489 : ${with_no_leaks:=yes}
4494 echo "$as_me:4494: result: ${with_valgrind:-no}" >&5
4495 echo "${ECHO_T}${with_valgrind:-no}" >&6
4497 case .$with_cflags in #(vi
4499 case .$CFLAGS in #(vi
4507 cf_new_extra_cppflags=
4509 for cf_add_cflags in -g
4511 case $cf_fix_cppflags in
4513 case $cf_add_cflags in #(vi
4514 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
4515 case $cf_add_cflags in
4517 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4519 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
4520 && test -z "${cf_tst_cflags}" \
4521 && cf_fix_cppflags=yes
4523 if test $cf_fix_cppflags = yes ; then
4524 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4526 elif test "${cf_tst_cflags}" = "\"'" ; then
4527 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4533 *$cf_add_cflags) #(vi
4536 case $cf_add_cflags in #(vi
4538 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4540 CPPFLAGS=`echo "$CPPFLAGS" | \
4541 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4542 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4546 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
4551 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
4556 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4558 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
4560 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
4561 && test -z "${cf_tst_cflags}" \
4562 && cf_fix_cppflags=no
4567 if test -n "$cf_new_cflags" ; then
4569 CFLAGS="$CFLAGS $cf_new_cflags"
4572 if test -n "$cf_new_cppflags" ; then
4574 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
4577 if test -n "$cf_new_extra_cppflags" ; then
4579 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
4587 echo "$as_me:4587: checking if you want to perform memory-leak testing" >&5
4588 echo $ECHO_N "checking if you want to perform memory-leak testing... $ECHO_C" >&6
4590 # Check whether --enable-leaks or --disable-leaks was given.
4591 if test "${enable_leaks+set}" = set; then
4592 enableval="$enable_leaks"
4593 if test "x$enableval" = xno; then with_no_leaks=yes; else with_no_leaks=no; fi
4595 : ${with_no_leaks:=no}
4597 echo "$as_me:4597: result: $with_no_leaks" >&5
4598 echo "${ECHO_T}$with_no_leaks" >&6
4600 if test "$with_no_leaks" = yes ; then
4601 cat >>confdefs.h <<\EOF
4605 cat >>confdefs.h <<\EOF
4606 #define YY_NO_LEAKS 1
4611 echo "$as_me:4611: checking for specific curses-directory" >&5
4612 echo $ECHO_N "checking for specific curses-directory... $ECHO_C" >&6
4614 # Check whether --with-curses-dir or --without-curses-dir was given.
4615 if test "${with_curses_dir+set}" = set; then
4616 withval="$with_curses_dir"
4617 cf_cv_curses_dir=$withval
4621 echo "$as_me:4621: result: $cf_cv_curses_dir" >&5
4622 echo "${ECHO_T}$cf_cv_curses_dir" >&6
4624 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
4627 if test "x$prefix" != xNONE; then
4628 cf_path_syntax="$prefix"
4630 cf_path_syntax="$ac_default_prefix"
4633 case ".$withval" in #(vi
4634 .\$\(*\)*|.\'*\'*) #(vi
4638 .[a-zA-Z]:[\\/]*) #(vi OS/2 EMX
4641 eval withval="$withval"
4642 case ".$withval" in #(vi
4644 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
4649 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
4652 { { echo "$as_me:4652: error: expected a pathname, not \"$withval\"" >&5
4653 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
4654 { (exit 1); exit 1; }; }
4658 if test -d "$cf_cv_curses_dir"
4661 if test -n "$cf_cv_curses_dir/include" ; then
4662 for cf_add_incdir in $cf_cv_curses_dir/include
4664 while test $cf_add_incdir != /usr/include
4666 if test -d $cf_add_incdir
4669 if test -n "$CFLAGS$CPPFLAGS" ; then
4670 # a loop is needed to ensure we can add subdirs of existing dirs
4671 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
4672 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
4673 cf_have_incdir=yes; break
4678 if test "$cf_have_incdir" = no ; then
4679 if test "$cf_add_incdir" = /usr/local/include ; then
4680 if test "$GCC" = yes
4682 cf_save_CPPFLAGS=$CPPFLAGS
4683 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
4684 cat >conftest.$ac_ext <<_ACEOF
4685 #line 4685 "configure"
4686 #include "confdefs.h"
4696 rm -f conftest.$ac_objext
4697 if { (eval echo "$as_me:4697: \"$ac_compile\"") >&5
4698 (eval $ac_compile) 2>&5
4700 echo "$as_me:4700: \$? = $ac_status" >&5
4701 (exit $ac_status); } &&
4702 { ac_try='test -s conftest.$ac_objext'
4703 { (eval echo "$as_me:4703: \"$ac_try\"") >&5
4706 echo "$as_me:4706: \$? = $ac_status" >&5
4707 (exit $ac_status); }; }; then
4710 echo "$as_me: failed program was:" >&5
4711 cat conftest.$ac_ext >&5
4714 rm -f conftest.$ac_objext conftest.$ac_ext
4715 CPPFLAGS=$cf_save_CPPFLAGS
4720 if test "$cf_have_incdir" = no ; then
4721 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
4723 echo "${as_me:-configure}:4723: testing adding $cf_add_incdir to include-path ..." 1>&5
4725 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
4727 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
4728 test "$cf_top_incdir" = "$cf_add_incdir" && break
4729 cf_add_incdir="$cf_top_incdir"
4738 if test -n "$cf_cv_curses_dir/lib" ; then
4739 for cf_add_libdir in $cf_cv_curses_dir/lib
4741 if test $cf_add_libdir = /usr/lib ; then
4743 elif test -d $cf_add_libdir
4746 if test -n "$LDFLAGS$LIBS" ; then
4747 # a loop is needed to ensure we can add subdirs of existing dirs
4748 for cf_test_libdir in $LDFLAGS $LIBS ; do
4749 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
4750 cf_have_libdir=yes; break
4754 if test "$cf_have_libdir" = no ; then
4755 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
4757 echo "${as_me:-configure}:4757: testing adding $cf_add_libdir to library-path ..." 1>&5
4759 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
4768 # Check whether --with-5lib or --without-5lib was given.
4769 if test "${with_5lib+set}" = set; then
4770 withval="$with_5lib"
4771 LIBS="-L/usr/5lib $LIBS"
4772 CPPFLAGS="$CPPFLAGS -I/usr/5include"
4775 # Check whether --with-ncursesw or --without-ncursesw was given.
4776 if test "${with_ncursesw+set}" = set; then
4777 withval="$with_ncursesw"
4778 cf_cv_screen=ncursesw
4781 # Check whether --with-ncurses or --without-ncurses was given.
4782 if test "${with_ncurses+set}" = set; then
4783 withval="$with_ncurses"
4784 cf_cv_screen=ncurses
4787 # Check whether --with-pdcurses or --without-pdcurses was given.
4788 if test "${with_pdcurses+set}" = set; then
4789 withval="$with_pdcurses"
4790 cf_cv_screen=pdcurses
4795 case $cf_cv_screen in
4798 echo "$as_me:4798: checking for extra include directories" >&5
4799 echo $ECHO_N "checking for extra include directories... $ECHO_C" >&6
4800 if test "${cf_cv_curses_incdir+set}" = set; then
4801 echo $ECHO_N "(cached) $ECHO_C" >&6
4804 cf_cv_curses_incdir=no
4805 case $host_os in #(vi
4807 test -d /usr/include/curses_colr && \
4808 cf_cv_curses_incdir="-I/usr/include/curses_colr"
4811 test -d /usr/5lib && \
4812 test -d /usr/5include && \
4813 cf_cv_curses_incdir="-I/usr/5include"
4818 echo "$as_me:4818: result: $cf_cv_curses_incdir" >&5
4819 echo "${ECHO_T}$cf_cv_curses_incdir" >&6
4820 test "$cf_cv_curses_incdir" != no && CPPFLAGS="$CPPFLAGS $cf_cv_curses_incdir"
4822 echo "$as_me:4822: checking if we have identified curses headers" >&5
4823 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
4824 if test "${cf_cv_ncurses_header+set}" = set; then
4825 echo $ECHO_N "(cached) $ECHO_C" >&6
4828 cf_cv_ncurses_header=none
4831 ncurses.h ncurses/curses.h ncurses/ncurses.h
4833 cat >conftest.$ac_ext <<_ACEOF
4834 #line 4834 "configure"
4835 #include "confdefs.h"
4836 #include <${cf_header}>
4840 initscr(); tgoto("?", 0,0)
4845 rm -f conftest.$ac_objext
4846 if { (eval echo "$as_me:4846: \"$ac_compile\"") >&5
4847 (eval $ac_compile) 2>&5
4849 echo "$as_me:4849: \$? = $ac_status" >&5
4850 (exit $ac_status); } &&
4851 { ac_try='test -s conftest.$ac_objext'
4852 { (eval echo "$as_me:4852: \"$ac_try\"") >&5
4855 echo "$as_me:4855: \$? = $ac_status" >&5
4856 (exit $ac_status); }; }; then
4857 cf_cv_ncurses_header=$cf_header; break
4859 echo "$as_me: failed program was:" >&5
4860 cat conftest.$ac_ext >&5
4862 rm -f conftest.$ac_objext conftest.$ac_ext
4866 echo "$as_me:4866: result: $cf_cv_ncurses_header" >&5
4867 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
4869 if test "$cf_cv_ncurses_header" = none ; then
4870 { { echo "$as_me:4870: error: No curses header-files found" >&5
4871 echo "$as_me: error: No curses header-files found" >&2;}
4872 { (exit 1); exit 1; }; }
4875 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
4877 for ac_header in $cf_cv_ncurses_header
4879 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
4880 echo "$as_me:4880: checking for $ac_header" >&5
4881 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4882 if eval "test \"\${$as_ac_Header+set}\" = set"; then
4883 echo $ECHO_N "(cached) $ECHO_C" >&6
4885 cat >conftest.$ac_ext <<_ACEOF
4886 #line 4886 "configure"
4887 #include "confdefs.h"
4888 #include <$ac_header>
4890 if { (eval echo "$as_me:4890: \"$ac_cpp conftest.$ac_ext\"") >&5
4891 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4893 egrep -v '^ *\+' conftest.er1 >conftest.err
4895 cat conftest.err >&5
4896 echo "$as_me:4896: \$? = $ac_status" >&5
4897 (exit $ac_status); } >/dev/null; then
4898 if test -s conftest.err; then
4899 ac_cpp_err=$ac_c_preproc_warn_flag
4906 if test -z "$ac_cpp_err"; then
4907 eval "$as_ac_Header=yes"
4909 echo "$as_me: failed program was:" >&5
4910 cat conftest.$ac_ext >&5
4911 eval "$as_ac_Header=no"
4913 rm -f conftest.err conftest.$ac_ext
4915 echo "$as_me:4915: result: `eval echo '${'$as_ac_Header'}'`" >&5
4916 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4917 if test `eval echo '${'$as_ac_Header'}'` = yes; then
4918 cat >>confdefs.h <<EOF
4919 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
4925 echo "$as_me:4925: checking for terminfo header" >&5
4926 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
4927 if test "${cf_cv_term_header+set}" = set; then
4928 echo $ECHO_N "(cached) $ECHO_C" >&6
4931 case ${cf_cv_ncurses_header} in #(vi
4932 */ncurses.h|*/ncursesw.h) #(vi
4933 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
4936 cf_term_header=term.h
4940 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
4942 cat >conftest.$ac_ext <<_ACEOF
4943 #line 4943 "configure"
4944 #include "confdefs.h"
4946 #include <${cf_cv_ncurses_header:-curses.h}>
4952 int x = auto_left_margin
4957 rm -f conftest.$ac_objext
4958 if { (eval echo "$as_me:4958: \"$ac_compile\"") >&5
4959 (eval $ac_compile) 2>&5
4961 echo "$as_me:4961: \$? = $ac_status" >&5
4962 (exit $ac_status); } &&
4963 { ac_try='test -s conftest.$ac_objext'
4964 { (eval echo "$as_me:4964: \"$ac_try\"") >&5
4967 echo "$as_me:4967: \$? = $ac_status" >&5
4968 (exit $ac_status); }; }; then
4970 cf_cv_term_header="$cf_test"
4972 echo "$as_me: failed program was:" >&5
4973 cat conftest.$ac_ext >&5
4975 cf_cv_term_header=unknown
4978 rm -f conftest.$ac_objext conftest.$ac_ext
4979 test "$cf_cv_term_header" != unknown && break
4983 echo "$as_me:4983: result: $cf_cv_term_header" >&5
4984 echo "${ECHO_T}$cf_cv_term_header" >&6
4986 # Set definitions to allow ifdef'ing to accommodate subdirectories
4988 case $cf_cv_term_header in # (vi
4990 cat >>confdefs.h <<\EOF
4991 #define HAVE_TERM_H 1
4997 case $cf_cv_term_header in # (vi
4998 ncurses/term.h) #(vi
4999 cat >>confdefs.h <<\EOF
5000 #define HAVE_NCURSES_TERM_H 1
5005 cat >>confdefs.h <<\EOF
5006 #define HAVE_NCURSESW_TERM_H 1
5012 echo "$as_me:5012: checking for ncurses version" >&5
5013 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
5014 if test "${cf_cv_ncurses_version+set}" = set; then
5015 echo $ECHO_N "(cached) $ECHO_C" >&6
5018 cf_cv_ncurses_version=no
5021 if test "$cross_compiling" = yes; then
5023 # This will not work if the preprocessor splits the line after the
5024 # Autoconf token. The 'unproto' program does that.
5025 cat > conftest.$ac_ext <<EOF
5026 #include <${cf_cv_ncurses_header:-curses.h}>
5028 #ifdef NCURSES_VERSION
5029 Autoconf NCURSES_VERSION
5037 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
5038 { (eval echo "$as_me:5038: \"$cf_try\"") >&5
5041 echo "$as_me:5041: \$? = $ac_status" >&5
5042 (exit $ac_status); }
5043 if test -f conftest.out ; then
5044 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
5045 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
5050 cat >conftest.$ac_ext <<_ACEOF
5051 #line 5051 "configure"
5052 #include "confdefs.h"
5054 #include <${cf_cv_ncurses_header:-curses.h}>
5058 FILE *fp = fopen("$cf_tempfile", "w");
5059 #ifdef NCURSES_VERSION
5060 # ifdef NCURSES_VERSION_PATCH
5061 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
5063 fprintf(fp, "%s\n", NCURSES_VERSION);
5067 fprintf(fp, "old\n");
5072 ${cf_cv_main_return:-return}(0);
5075 rm -f conftest$ac_exeext
5076 if { (eval echo "$as_me:5076: \"$ac_link\"") >&5
5077 (eval $ac_link) 2>&5
5079 echo "$as_me:5079: \$? = $ac_status" >&5
5080 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5081 { (eval echo "$as_me:5081: \"$ac_try\"") >&5
5084 echo "$as_me:5084: \$? = $ac_status" >&5
5085 (exit $ac_status); }; }; then
5087 cf_cv_ncurses_version=`cat $cf_tempfile`
5089 echo "$as_me: program exited with status $ac_status" >&5
5090 echo "$as_me: failed program was:" >&5
5091 cat conftest.$ac_ext >&5
5093 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
5098 echo "$as_me:5098: result: $cf_cv_ncurses_version" >&5
5099 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
5100 test "$cf_cv_ncurses_version" = no || cat >>confdefs.h <<\EOF
5104 echo "$as_me:5104: checking if we have identified curses libraries" >&5
5105 echo $ECHO_N "checking if we have identified curses libraries... $ECHO_C" >&6
5106 cat >conftest.$ac_ext <<_ACEOF
5107 #line 5107 "configure"
5108 #include "confdefs.h"
5109 #include <${cf_cv_ncurses_header:-curses.h}>
5113 initscr(); tgoto("?", 0,0)
5118 rm -f conftest.$ac_objext conftest$ac_exeext
5119 if { (eval echo "$as_me:5119: \"$ac_link\"") >&5
5120 (eval $ac_link) 2>&5
5122 echo "$as_me:5122: \$? = $ac_status" >&5
5123 (exit $ac_status); } &&
5124 { ac_try='test -s conftest$ac_exeext'
5125 { (eval echo "$as_me:5125: \"$ac_try\"") >&5
5128 echo "$as_me:5128: \$? = $ac_status" >&5
5129 (exit $ac_status); }; }; then
5132 echo "$as_me: failed program was:" >&5
5133 cat conftest.$ac_ext >&5
5136 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5137 echo "$as_me:5137: result: $cf_result" >&5
5138 echo "${ECHO_T}$cf_result" >&6
5140 if test "$cf_result" = no ; then
5141 case $host_os in #(vi
5143 echo "$as_me:5143: checking for tgoto in -lmytinfo" >&5
5144 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
5145 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
5146 echo $ECHO_N "(cached) $ECHO_C" >&6
5148 ac_check_lib_save_LIBS=$LIBS
5149 LIBS="-lmytinfo $LIBS"
5150 cat >conftest.$ac_ext <<_ACEOF
5151 #line 5151 "configure"
5152 #include "confdefs.h"
5154 /* Override any gcc2 internal prototype to avoid an error. */
5158 /* We use char because int might match the return type of a gcc2
5159 builtin and then its argument prototype would still apply. */
5169 rm -f conftest.$ac_objext conftest$ac_exeext
5170 if { (eval echo "$as_me:5170: \"$ac_link\"") >&5
5171 (eval $ac_link) 2>&5
5173 echo "$as_me:5173: \$? = $ac_status" >&5
5174 (exit $ac_status); } &&
5175 { ac_try='test -s conftest$ac_exeext'
5176 { (eval echo "$as_me:5176: \"$ac_try\"") >&5
5179 echo "$as_me:5179: \$? = $ac_status" >&5
5180 (exit $ac_status); }; }; then
5181 ac_cv_lib_mytinfo_tgoto=yes
5183 echo "$as_me: failed program was:" >&5
5184 cat conftest.$ac_ext >&5
5185 ac_cv_lib_mytinfo_tgoto=no
5187 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5188 LIBS=$ac_check_lib_save_LIBS
5190 echo "$as_me:5190: result: $ac_cv_lib_mytinfo_tgoto" >&5
5191 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
5192 if test $ac_cv_lib_mytinfo_tgoto = yes; then
5193 LIBS="-lmytinfo $LIBS"
5198 echo "$as_me:5198: checking for initscr in -lcur_colr" >&5
5199 echo $ECHO_N "checking for initscr in -lcur_colr... $ECHO_C" >&6
5200 if test "${ac_cv_lib_cur_colr_initscr+set}" = set; then
5201 echo $ECHO_N "(cached) $ECHO_C" >&6
5203 ac_check_lib_save_LIBS=$LIBS
5204 LIBS="-lcur_colr $LIBS"
5205 cat >conftest.$ac_ext <<_ACEOF
5206 #line 5206 "configure"
5207 #include "confdefs.h"
5209 /* Override any gcc2 internal prototype to avoid an error. */
5213 /* We use char because int might match the return type of a gcc2
5214 builtin and then its argument prototype would still apply. */
5224 rm -f conftest.$ac_objext conftest$ac_exeext
5225 if { (eval echo "$as_me:5225: \"$ac_link\"") >&5
5226 (eval $ac_link) 2>&5
5228 echo "$as_me:5228: \$? = $ac_status" >&5
5229 (exit $ac_status); } &&
5230 { ac_try='test -s conftest$ac_exeext'
5231 { (eval echo "$as_me:5231: \"$ac_try\"") >&5
5234 echo "$as_me:5234: \$? = $ac_status" >&5
5235 (exit $ac_status); }; }; then
5236 ac_cv_lib_cur_colr_initscr=yes
5238 echo "$as_me: failed program was:" >&5
5239 cat conftest.$ac_ext >&5
5240 ac_cv_lib_cur_colr_initscr=no
5242 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5243 LIBS=$ac_check_lib_save_LIBS
5245 echo "$as_me:5245: result: $ac_cv_lib_cur_colr_initscr" >&5
5246 echo "${ECHO_T}$ac_cv_lib_cur_colr_initscr" >&6
5247 if test $ac_cv_lib_cur_colr_initscr = yes; then
5249 LIBS="-lcur_colr $LIBS"
5250 ac_cv_func_initscr=yes
5254 echo "$as_me:5254: checking for initscr in -lHcurses" >&5
5255 echo $ECHO_N "checking for initscr in -lHcurses... $ECHO_C" >&6
5256 if test "${ac_cv_lib_Hcurses_initscr+set}" = set; then
5257 echo $ECHO_N "(cached) $ECHO_C" >&6
5259 ac_check_lib_save_LIBS=$LIBS
5260 LIBS="-lHcurses $LIBS"
5261 cat >conftest.$ac_ext <<_ACEOF
5262 #line 5262 "configure"
5263 #include "confdefs.h"
5265 /* Override any gcc2 internal prototype to avoid an error. */
5269 /* We use char because int might match the return type of a gcc2
5270 builtin and then its argument prototype would still apply. */
5280 rm -f conftest.$ac_objext conftest$ac_exeext
5281 if { (eval echo "$as_me:5281: \"$ac_link\"") >&5
5282 (eval $ac_link) 2>&5
5284 echo "$as_me:5284: \$? = $ac_status" >&5
5285 (exit $ac_status); } &&
5286 { ac_try='test -s conftest$ac_exeext'
5287 { (eval echo "$as_me:5287: \"$ac_try\"") >&5
5290 echo "$as_me:5290: \$? = $ac_status" >&5
5291 (exit $ac_status); }; }; then
5292 ac_cv_lib_Hcurses_initscr=yes
5294 echo "$as_me: failed program was:" >&5
5295 cat conftest.$ac_ext >&5
5296 ac_cv_lib_Hcurses_initscr=no
5298 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5299 LIBS=$ac_check_lib_save_LIBS
5301 echo "$as_me:5301: result: $ac_cv_lib_Hcurses_initscr" >&5
5302 echo "${ECHO_T}$ac_cv_lib_Hcurses_initscr" >&6
5303 if test $ac_cv_lib_Hcurses_initscr = yes; then
5305 # HP's header uses __HP_CURSES, but user claims _HP_CURSES.
5306 LIBS="-lHcurses $LIBS"
5307 CPPFLAGS="$CPPFLAGS -D__HP_CURSES -D_HP_CURSES"
5308 ac_cv_func_initscr=yes
5315 linux*) # Suse Linux does not follow /usr/lib convention
5317 if test -n "/lib" ; then
5318 for cf_add_libdir in /lib
5320 if test $cf_add_libdir = /usr/lib ; then
5322 elif test -d $cf_add_libdir
5325 if test -n "$LDFLAGS$LIBS" ; then
5326 # a loop is needed to ensure we can add subdirs of existing dirs
5327 for cf_test_libdir in $LDFLAGS $LIBS ; do
5328 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
5329 cf_have_libdir=yes; break
5333 if test "$cf_have_libdir" = no ; then
5334 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
5336 echo "${as_me:-configure}:5336: testing adding $cf_add_libdir to library-path ..." 1>&5
5338 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
5346 if test -d /usr/5lib ; then
5348 if test -n "/usr/5lib" ; then
5349 for cf_add_libdir in /usr/5lib
5351 if test $cf_add_libdir = /usr/lib ; then
5353 elif test -d $cf_add_libdir
5356 if test -n "$LDFLAGS$LIBS" ; then
5357 # a loop is needed to ensure we can add subdirs of existing dirs
5358 for cf_test_libdir in $LDFLAGS $LIBS ; do
5359 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
5360 cf_have_libdir=yes; break
5364 if test "$cf_have_libdir" = no ; then
5365 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
5367 echo "${as_me:-configure}:5367: testing adding $cf_add_libdir to library-path ..." 1>&5
5369 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
5375 LIBS="-lcurses -ltermcap $LIBS"
5377 ac_cv_func_initscr=yes
5381 if test ".$ac_cv_func_initscr" != .yes ; then
5382 cf_save_LIBS="$LIBS"
5386 if test ".${cf_cv_ncurses_version:-no}" != .no
5388 cf_check_list="ncurses curses cursesX"
5390 cf_check_list="cursesX curses ncurses"
5393 # Check for library containing tgoto. Do this before curses library
5394 # because it may be needed to link the test-case for initscr.
5395 echo "$as_me:5395: checking for tgoto" >&5
5396 echo $ECHO_N "checking for tgoto... $ECHO_C" >&6
5397 if test "${ac_cv_func_tgoto+set}" = set; then
5398 echo $ECHO_N "(cached) $ECHO_C" >&6
5400 cat >conftest.$ac_ext <<_ACEOF
5401 #line 5401 "configure"
5402 #include "confdefs.h"
5403 /* System header to define __stub macros and hopefully few prototypes,
5404 which can conflict with char tgoto (); below. */
5406 /* Override any gcc2 internal prototype to avoid an error. */
5410 /* We use char because int might match the return type of a gcc2
5411 builtin and then its argument prototype would still apply. */
5418 /* The GNU C library defines this for functions which it implements
5419 to always fail with ENOSYS. Some functions are actually named
5420 something starting with __ and the normal name is an alias. */
5421 #if defined (__stub_tgoto) || defined (__stub___tgoto)
5431 rm -f conftest.$ac_objext conftest$ac_exeext
5432 if { (eval echo "$as_me:5432: \"$ac_link\"") >&5
5433 (eval $ac_link) 2>&5
5435 echo "$as_me:5435: \$? = $ac_status" >&5
5436 (exit $ac_status); } &&
5437 { ac_try='test -s conftest$ac_exeext'
5438 { (eval echo "$as_me:5438: \"$ac_try\"") >&5
5441 echo "$as_me:5441: \$? = $ac_status" >&5
5442 (exit $ac_status); }; }; then
5443 ac_cv_func_tgoto=yes
5445 echo "$as_me: failed program was:" >&5
5446 cat conftest.$ac_ext >&5
5449 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5451 echo "$as_me:5451: result: $ac_cv_func_tgoto" >&5
5452 echo "${ECHO_T}$ac_cv_func_tgoto" >&6
5453 if test $ac_cv_func_tgoto = yes; then
5454 cf_term_lib=predefined
5457 for cf_term_lib in $cf_check_list termcap termlib unknown
5459 as_ac_Lib=`echo "ac_cv_lib_$cf_term_lib''_tgoto" | $as_tr_sh`
5460 echo "$as_me:5460: checking for tgoto in -l$cf_term_lib" >&5
5461 echo $ECHO_N "checking for tgoto in -l$cf_term_lib... $ECHO_C" >&6
5462 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
5463 echo $ECHO_N "(cached) $ECHO_C" >&6
5465 ac_check_lib_save_LIBS=$LIBS
5466 LIBS="-l$cf_term_lib $LIBS"
5467 cat >conftest.$ac_ext <<_ACEOF
5468 #line 5468 "configure"
5469 #include "confdefs.h"
5471 /* Override any gcc2 internal prototype to avoid an error. */
5475 /* We use char because int might match the return type of a gcc2
5476 builtin and then its argument prototype would still apply. */
5486 rm -f conftest.$ac_objext conftest$ac_exeext
5487 if { (eval echo "$as_me:5487: \"$ac_link\"") >&5
5488 (eval $ac_link) 2>&5
5490 echo "$as_me:5490: \$? = $ac_status" >&5
5491 (exit $ac_status); } &&
5492 { ac_try='test -s conftest$ac_exeext'
5493 { (eval echo "$as_me:5493: \"$ac_try\"") >&5
5496 echo "$as_me:5496: \$? = $ac_status" >&5
5497 (exit $ac_status); }; }; then
5498 eval "$as_ac_Lib=yes"
5500 echo "$as_me: failed program was:" >&5
5501 cat conftest.$ac_ext >&5
5502 eval "$as_ac_Lib=no"
5504 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5505 LIBS=$ac_check_lib_save_LIBS
5507 echo "$as_me:5507: result: `eval echo '${'$as_ac_Lib'}'`" >&5
5508 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
5509 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
5517 # Check for library containing initscr
5518 test "$cf_term_lib" != predefined && test "$cf_term_lib" != unknown && LIBS="-l$cf_term_lib $cf_save_LIBS"
5519 for cf_curs_lib in $cf_check_list xcurses jcurses pdcurses unknown
5521 as_ac_Lib=`echo "ac_cv_lib_$cf_curs_lib''_initscr" | $as_tr_sh`
5522 echo "$as_me:5522: checking for initscr in -l$cf_curs_lib" >&5
5523 echo $ECHO_N "checking for initscr in -l$cf_curs_lib... $ECHO_C" >&6
5524 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
5525 echo $ECHO_N "(cached) $ECHO_C" >&6
5527 ac_check_lib_save_LIBS=$LIBS
5528 LIBS="-l$cf_curs_lib $LIBS"
5529 cat >conftest.$ac_ext <<_ACEOF
5530 #line 5530 "configure"
5531 #include "confdefs.h"
5533 /* Override any gcc2 internal prototype to avoid an error. */
5537 /* We use char because int might match the return type of a gcc2
5538 builtin and then its argument prototype would still apply. */
5548 rm -f conftest.$ac_objext conftest$ac_exeext
5549 if { (eval echo "$as_me:5549: \"$ac_link\"") >&5
5550 (eval $ac_link) 2>&5
5552 echo "$as_me:5552: \$? = $ac_status" >&5
5553 (exit $ac_status); } &&
5554 { ac_try='test -s conftest$ac_exeext'
5555 { (eval echo "$as_me:5555: \"$ac_try\"") >&5
5558 echo "$as_me:5558: \$? = $ac_status" >&5
5559 (exit $ac_status); }; }; then
5560 eval "$as_ac_Lib=yes"
5562 echo "$as_me: failed program was:" >&5
5563 cat conftest.$ac_ext >&5
5564 eval "$as_ac_Lib=no"
5566 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5567 LIBS=$ac_check_lib_save_LIBS
5569 echo "$as_me:5569: result: `eval echo '${'$as_ac_Lib'}'`" >&5
5570 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
5571 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
5576 test $cf_curs_lib = unknown && { { echo "$as_me:5576: error: no curses library found" >&5
5577 echo "$as_me: error: no curses library found" >&2;}
5578 { (exit 1); exit 1; }; }
5580 LIBS="-l$cf_curs_lib $cf_save_LIBS"
5581 if test "$cf_term_lib" = unknown ; then
5582 echo "$as_me:5582: checking if we can link with $cf_curs_lib library" >&5
5583 echo $ECHO_N "checking if we can link with $cf_curs_lib library... $ECHO_C" >&6
5584 cat >conftest.$ac_ext <<_ACEOF
5585 #line 5585 "configure"
5586 #include "confdefs.h"
5587 #include <${cf_cv_ncurses_header:-curses.h}>
5596 rm -f conftest.$ac_objext conftest$ac_exeext
5597 if { (eval echo "$as_me:5597: \"$ac_link\"") >&5
5598 (eval $ac_link) 2>&5
5600 echo "$as_me:5600: \$? = $ac_status" >&5
5601 (exit $ac_status); } &&
5602 { ac_try='test -s conftest$ac_exeext'
5603 { (eval echo "$as_me:5603: \"$ac_try\"") >&5
5606 echo "$as_me:5606: \$? = $ac_status" >&5
5607 (exit $ac_status); }; }; then
5610 echo "$as_me: failed program was:" >&5
5611 cat conftest.$ac_ext >&5
5614 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5615 echo "$as_me:5615: result: $cf_result" >&5
5616 echo "${ECHO_T}$cf_result" >&6
5617 test $cf_result = no && { { echo "$as_me:5617: error: Cannot link curses library" >&5
5618 echo "$as_me: error: Cannot link curses library" >&2;}
5619 { (exit 1); exit 1; }; }
5620 elif test "$cf_curs_lib" = "$cf_term_lib" ; then
5622 elif test "$cf_term_lib" != predefined ; then
5623 echo "$as_me:5623: checking if we need both $cf_curs_lib and $cf_term_lib libraries" >&5
5624 echo $ECHO_N "checking if we need both $cf_curs_lib and $cf_term_lib libraries... $ECHO_C" >&6
5625 cat >conftest.$ac_ext <<_ACEOF
5626 #line 5626 "configure"
5627 #include "confdefs.h"
5628 #include <${cf_cv_ncurses_header:-curses.h}>
5632 initscr(); tgoto((char *)0, 0, 0);
5637 rm -f conftest.$ac_objext conftest$ac_exeext
5638 if { (eval echo "$as_me:5638: \"$ac_link\"") >&5
5639 (eval $ac_link) 2>&5
5641 echo "$as_me:5641: \$? = $ac_status" >&5
5642 (exit $ac_status); } &&
5643 { ac_try='test -s conftest$ac_exeext'
5644 { (eval echo "$as_me:5644: \"$ac_try\"") >&5
5647 echo "$as_me:5647: \$? = $ac_status" >&5
5648 (exit $ac_status); }; }; then
5651 echo "$as_me: failed program was:" >&5
5652 cat conftest.$ac_ext >&5
5654 LIBS="-l$cf_curs_lib -l$cf_term_lib $cf_save_LIBS"
5655 cat >conftest.$ac_ext <<_ACEOF
5656 #line 5656 "configure"
5657 #include "confdefs.h"
5658 #include <${cf_cv_ncurses_header:-curses.h}>
5667 rm -f conftest.$ac_objext conftest$ac_exeext
5668 if { (eval echo "$as_me:5668: \"$ac_link\"") >&5
5669 (eval $ac_link) 2>&5
5671 echo "$as_me:5671: \$? = $ac_status" >&5
5672 (exit $ac_status); } &&
5673 { ac_try='test -s conftest$ac_exeext'
5674 { (eval echo "$as_me:5674: \"$ac_try\"") >&5
5677 echo "$as_me:5677: \$? = $ac_status" >&5
5678 (exit $ac_status); }; }; then
5681 echo "$as_me: failed program was:" >&5
5682 cat conftest.$ac_ext >&5
5685 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5688 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5689 echo "$as_me:5689: result: $cf_result" >&5
5690 echo "${ECHO_T}$cf_result" >&6
5695 echo "$as_me:5695: checking for NetBSD form.h" >&5
5696 echo $ECHO_N "checking for NetBSD form.h... $ECHO_C" >&6
5697 if test "${cf_cv_netbsd_form_h+set}" = set; then
5698 echo $ECHO_N "(cached) $ECHO_C" >&6
5701 cat >conftest.$ac_ext <<_ACEOF
5702 #line 5702 "configure"
5703 #include "confdefs.h"
5705 #include <${cf_cv_ncurses_header:-curses.h}>
5713 int y = current_field(form)->cursor_ypos;
5714 int x = current_field(form)->cursor_xpos;
5720 rm -f conftest.$ac_objext
5721 if { (eval echo "$as_me:5721: \"$ac_compile\"") >&5
5722 (eval $ac_compile) 2>&5
5724 echo "$as_me:5724: \$? = $ac_status" >&5
5725 (exit $ac_status); } &&
5726 { ac_try='test -s conftest.$ac_objext'
5727 { (eval echo "$as_me:5727: \"$ac_try\"") >&5
5730 echo "$as_me:5730: \$? = $ac_status" >&5
5731 (exit $ac_status); }; }; then
5732 cf_cv_netbsd_form_h=yes
5735 echo "$as_me: failed program was:" >&5
5736 cat conftest.$ac_ext >&5
5737 cf_cv_netbsd_form_h=no
5739 rm -f conftest.$ac_objext conftest.$ac_ext
5742 echo "$as_me:5742: result: $cf_cv_netbsd_form_h" >&5
5743 echo "${ECHO_T}$cf_cv_netbsd_form_h" >&6
5745 test "$cf_cv_netbsd_form_h" = yes && cat >>confdefs.h <<\EOF
5746 #define HAVE_NETBSD_FORM_H 1
5749 echo "$as_me:5749: checking for NetBSD menu.h" >&5
5750 echo $ECHO_N "checking for NetBSD menu.h... $ECHO_C" >&6
5751 if test "${cf_cv_netbsd_menu_h+set}" = set; then
5752 echo $ECHO_N "(cached) $ECHO_C" >&6
5755 cat >conftest.$ac_ext <<_ACEOF
5756 #line 5756 "configure"
5757 #include "confdefs.h"
5759 #include <${cf_cv_ncurses_header:-curses.h}>
5767 int y = menu->max_item_width;
5773 rm -f conftest.$ac_objext
5774 if { (eval echo "$as_me:5774: \"$ac_compile\"") >&5
5775 (eval $ac_compile) 2>&5
5777 echo "$as_me:5777: \$? = $ac_status" >&5
5778 (exit $ac_status); } &&
5779 { ac_try='test -s conftest.$ac_objext'
5780 { (eval echo "$as_me:5780: \"$ac_try\"") >&5
5783 echo "$as_me:5783: \$? = $ac_status" >&5
5784 (exit $ac_status); }; }; then
5785 cf_cv_netbsd_menu_h=yes
5788 echo "$as_me: failed program was:" >&5
5789 cat conftest.$ac_ext >&5
5790 cf_cv_netbsd_menu_h=no
5792 rm -f conftest.$ac_objext conftest.$ac_ext
5795 echo "$as_me:5795: result: $cf_cv_netbsd_menu_h" >&5
5796 echo "${ECHO_T}$cf_cv_netbsd_menu_h" >&6
5798 test "$cf_cv_netbsd_menu_h" = yes && cat >>confdefs.h <<\EOF
5799 #define HAVE_NETBSD_MENU_H 1
5805 cf_ncuconfig_root=ncurses
5807 echo "Looking for ${cf_ncuconfig_root}-config"
5808 for ac_prog in ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
5810 # Extract the first word of "$ac_prog", so it can be a program name with args.
5811 set dummy $ac_prog; ac_word=$2
5812 echo "$as_me:5812: checking for $ac_word" >&5
5813 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5814 if test "${ac_cv_path_NCURSES_CONFIG+set}" = set; then
5815 echo $ECHO_N "(cached) $ECHO_C" >&6
5817 case $NCURSES_CONFIG in
5819 ac_cv_path_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test with a path.
5822 ac_save_IFS=$IFS; IFS=$ac_path_separator
5824 for ac_dir in $ac_dummy; do
5826 test -z "$ac_dir" && ac_dir=.
5827 if $as_executable_p "$ac_dir/$ac_word"; then
5828 ac_cv_path_NCURSES_CONFIG="$ac_dir/$ac_word"
5829 echo "$as_me:5829: found $ac_dir/$ac_word" >&5
5837 NCURSES_CONFIG=$ac_cv_path_NCURSES_CONFIG
5839 if test -n "$NCURSES_CONFIG"; then
5840 echo "$as_me:5840: result: $NCURSES_CONFIG" >&5
5841 echo "${ECHO_T}$NCURSES_CONFIG" >&6
5843 echo "$as_me:5843: result: no" >&5
5844 echo "${ECHO_T}no" >&6
5847 test -n "$NCURSES_CONFIG" && break
5849 test -n "$NCURSES_CONFIG" || NCURSES_CONFIG="none"
5851 if test "$NCURSES_CONFIG" != none ; then
5853 CPPFLAGS="$CPPFLAGS `$NCURSES_CONFIG --cflags`"
5854 LIBS="`$NCURSES_CONFIG --libs` $LIBS"
5856 # even with config script, some packages use no-override for curses.h
5858 echo "$as_me:5858: checking if we have identified curses headers" >&5
5859 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
5860 if test "${cf_cv_ncurses_header+set}" = set; then
5861 echo $ECHO_N "(cached) $ECHO_C" >&6
5864 cf_cv_ncurses_header=none
5871 cat >conftest.$ac_ext <<_ACEOF
5872 #line 5872 "configure"
5873 #include "confdefs.h"
5874 #include <${cf_header}>
5878 initscr(); tgoto("?", 0,0)
5883 rm -f conftest.$ac_objext
5884 if { (eval echo "$as_me:5884: \"$ac_compile\"") >&5
5885 (eval $ac_compile) 2>&5
5887 echo "$as_me:5887: \$? = $ac_status" >&5
5888 (exit $ac_status); } &&
5889 { ac_try='test -s conftest.$ac_objext'
5890 { (eval echo "$as_me:5890: \"$ac_try\"") >&5
5893 echo "$as_me:5893: \$? = $ac_status" >&5
5894 (exit $ac_status); }; }; then
5895 cf_cv_ncurses_header=$cf_header; break
5897 echo "$as_me: failed program was:" >&5
5898 cat conftest.$ac_ext >&5
5900 rm -f conftest.$ac_objext conftest.$ac_ext
5904 echo "$as_me:5904: result: $cf_cv_ncurses_header" >&5
5905 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
5907 if test "$cf_cv_ncurses_header" = none ; then
5908 { { echo "$as_me:5908: error: No curses header-files found" >&5
5909 echo "$as_me: error: No curses header-files found" >&2;}
5910 { (exit 1); exit 1; }; }
5913 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
5915 for ac_header in $cf_cv_ncurses_header
5917 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
5918 echo "$as_me:5918: checking for $ac_header" >&5
5919 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5920 if eval "test \"\${$as_ac_Header+set}\" = set"; then
5921 echo $ECHO_N "(cached) $ECHO_C" >&6
5923 cat >conftest.$ac_ext <<_ACEOF
5924 #line 5924 "configure"
5925 #include "confdefs.h"
5926 #include <$ac_header>
5928 if { (eval echo "$as_me:5928: \"$ac_cpp conftest.$ac_ext\"") >&5
5929 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
5931 egrep -v '^ *\+' conftest.er1 >conftest.err
5933 cat conftest.err >&5
5934 echo "$as_me:5934: \$? = $ac_status" >&5
5935 (exit $ac_status); } >/dev/null; then
5936 if test -s conftest.err; then
5937 ac_cpp_err=$ac_c_preproc_warn_flag
5944 if test -z "$ac_cpp_err"; then
5945 eval "$as_ac_Header=yes"
5947 echo "$as_me: failed program was:" >&5
5948 cat conftest.$ac_ext >&5
5949 eval "$as_ac_Header=no"
5951 rm -f conftest.err conftest.$ac_ext
5953 echo "$as_me:5953: result: `eval echo '${'$as_ac_Header'}'`" >&5
5954 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
5955 if test `eval echo '${'$as_ac_Header'}'` = yes; then
5956 cat >>confdefs.h <<EOF
5957 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
5963 cat >>confdefs.h <<\EOF
5967 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
5969 cat >>confdefs.h <<EOF
5970 #define $cf_nculib_ROOT 1
5973 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
5977 cf_ncuhdr_root=ncurses
5979 test -n "$cf_cv_curses_dir" && \
5980 test "$cf_cv_curses_dir" != "no" && { \
5982 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
5983 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
5985 while test $cf_add_incdir != /usr/include
5987 if test -d $cf_add_incdir
5990 if test -n "$CFLAGS$CPPFLAGS" ; then
5991 # a loop is needed to ensure we can add subdirs of existing dirs
5992 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
5993 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
5994 cf_have_incdir=yes; break
5999 if test "$cf_have_incdir" = no ; then
6000 if test "$cf_add_incdir" = /usr/local/include ; then
6001 if test "$GCC" = yes
6003 cf_save_CPPFLAGS=$CPPFLAGS
6004 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6005 cat >conftest.$ac_ext <<_ACEOF
6006 #line 6006 "configure"
6007 #include "confdefs.h"
6017 rm -f conftest.$ac_objext
6018 if { (eval echo "$as_me:6018: \"$ac_compile\"") >&5
6019 (eval $ac_compile) 2>&5
6021 echo "$as_me:6021: \$? = $ac_status" >&5
6022 (exit $ac_status); } &&
6023 { ac_try='test -s conftest.$ac_objext'
6024 { (eval echo "$as_me:6024: \"$ac_try\"") >&5
6027 echo "$as_me:6027: \$? = $ac_status" >&5
6028 (exit $ac_status); }; }; then
6031 echo "$as_me: failed program was:" >&5
6032 cat conftest.$ac_ext >&5
6035 rm -f conftest.$ac_objext conftest.$ac_ext
6036 CPPFLAGS=$cf_save_CPPFLAGS
6041 if test "$cf_have_incdir" = no ; then
6042 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
6044 echo "${as_me:-configure}:6044: testing adding $cf_add_incdir to include-path ..." 1>&5
6046 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6048 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
6049 test "$cf_top_incdir" = "$cf_add_incdir" && break
6050 cf_add_incdir="$cf_top_incdir"
6061 echo "$as_me:6061: checking for $cf_ncuhdr_root header in include-path" >&5
6062 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
6063 if test "${cf_cv_ncurses_h+set}" = set; then
6064 echo $ECHO_N "(cached) $ECHO_C" >&6
6067 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
6068 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
6069 for cf_header in $cf_header_list
6072 cat >conftest.$ac_ext <<_ACEOF
6073 #line 6073 "configure"
6074 #include "confdefs.h"
6076 #include <$cf_header>
6081 #ifdef NCURSES_VERSION
6083 printf("%s\n", NCURSES_VERSION);
6096 rm -f conftest.$ac_objext
6097 if { (eval echo "$as_me:6097: \"$ac_compile\"") >&5
6098 (eval $ac_compile) 2>&5
6100 echo "$as_me:6100: \$? = $ac_status" >&5
6101 (exit $ac_status); } &&
6102 { ac_try='test -s conftest.$ac_objext'
6103 { (eval echo "$as_me:6103: \"$ac_try\"") >&5
6106 echo "$as_me:6106: \$? = $ac_status" >&5
6107 (exit $ac_status); }; }; then
6108 cf_cv_ncurses_h=$cf_header
6111 echo "$as_me: failed program was:" >&5
6112 cat conftest.$ac_ext >&5
6115 rm -f conftest.$ac_objext conftest.$ac_ext
6117 test "$cf_cv_ncurses_h" != no && break
6121 echo "$as_me:6121: result: $cf_cv_ncurses_h" >&5
6122 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
6124 if test "$cf_cv_ncurses_h" != no ; then
6125 cf_cv_ncurses_header=$cf_cv_ncurses_h
6128 echo "$as_me:6128: checking for $cf_ncuhdr_root include-path" >&5
6129 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
6130 if test "${cf_cv_ncurses_h2+set}" = set; then
6131 echo $ECHO_N "(cached) $ECHO_C" >&6
6134 test -n "$verbose" && echo
6138 # collect the current set of include-directories from compiler flags
6139 cf_header_path_list=""
6140 if test -n "${CFLAGS}${CPPFLAGS}" ; then
6141 for cf_header_path in $CPPFLAGS $CFLAGS
6143 case $cf_header_path in #(vi
6145 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
6147 test "$cf_header_path" != "NONE" && \
6148 test -d "$cf_header_path" && \
6150 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
6151 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
6152 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
6153 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
6154 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
6155 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"
6158 cf_header_path_list="$cf_header_path_list $cf_search"
6164 # add the variations for the package we are looking for
6168 test "/usr" != "$prefix" && \
6170 (test $prefix = NONE || test "/usr" != "$prefix") && {
6171 test -n "$verbose" && echo " ... testing for include-directories under /usr"
6172 test -d /usr/include && cf_search="$cf_search /usr/include"
6173 test -d /usr/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/include/$cf_ncuhdr_root"
6174 test -d /usr/include/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/include/$cf_ncuhdr_root/include"
6175 test -d /usr/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/$cf_ncuhdr_root/include"
6176 test -d /usr/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
6179 test "$prefix" != "NONE" && \
6180 test -d "$prefix" && \
6182 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
6183 test -d $prefix/include && cf_search="$cf_search $prefix/include"
6184 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
6185 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
6186 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
6187 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
6190 test "/usr/local" != "$prefix" && \
6191 test -d "/usr/local" && \
6192 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
6193 test -n "$verbose" && echo " ... testing for include-directories under /usr/local"
6194 test -d /usr/local/include && cf_search="$cf_search /usr/local/include"
6195 test -d /usr/local/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/local/include/$cf_ncuhdr_root"
6196 test -d /usr/local/include/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/local/include/$cf_ncuhdr_root/include"
6197 test -d /usr/local/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/local/$cf_ncuhdr_root/include"
6198 test -d /usr/local/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/local/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
6201 test "/opt" != "$prefix" && \
6203 (test $prefix = NONE || test "/opt" != "$prefix") && {
6204 test -n "$verbose" && echo " ... testing for include-directories under /opt"
6205 test -d /opt/include && cf_search="$cf_search /opt/include"
6206 test -d /opt/include/$cf_ncuhdr_root && cf_search="$cf_search /opt/include/$cf_ncuhdr_root"
6207 test -d /opt/include/$cf_ncuhdr_root/include && cf_search="$cf_search /opt/include/$cf_ncuhdr_root/include"
6208 test -d /opt/$cf_ncuhdr_root/include && cf_search="$cf_search /opt/$cf_ncuhdr_root/include"
6209 test -d /opt/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /opt/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
6212 test "$HOME" != "$prefix" && \
6213 test -d "$HOME" && \
6214 (test $prefix = NONE || test "$HOME" != "$prefix") && {
6215 test -n "$verbose" && echo " ... testing for include-directories under $HOME"
6216 test -d $HOME/include && cf_search="$cf_search $HOME/include"
6217 test -d $HOME/include/$cf_ncuhdr_root && cf_search="$cf_search $HOME/include/$cf_ncuhdr_root"
6218 test -d $HOME/include/$cf_ncuhdr_root/include && cf_search="$cf_search $HOME/include/$cf_ncuhdr_root/include"
6219 test -d $HOME/$cf_ncuhdr_root/include && cf_search="$cf_search $HOME/$cf_ncuhdr_root/include"
6220 test -d $HOME/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $HOME/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
6223 test "$includedir" != NONE && \
6224 test "$includedir" != "/usr/include" && \
6225 test -d "$includedir" && {
6226 test -d $includedir && cf_search="$cf_search $includedir"
6227 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
6230 test "$oldincludedir" != NONE && \
6231 test "$oldincludedir" != "/usr/include" && \
6232 test -d "$oldincludedir" && {
6233 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
6234 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
6237 cf_search="$cf_search $cf_header_path_list"
6239 test -n "$verbose" && echo search path $cf_search
6240 cf_save2_CPPFLAGS="$CPPFLAGS"
6241 for cf_incdir in $cf_search
6244 if test -n "$cf_incdir" ; then
6245 for cf_add_incdir in $cf_incdir
6247 while test $cf_add_incdir != /usr/include
6249 if test -d $cf_add_incdir
6252 if test -n "$CFLAGS$CPPFLAGS" ; then
6253 # a loop is needed to ensure we can add subdirs of existing dirs
6254 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
6255 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
6256 cf_have_incdir=yes; break
6261 if test "$cf_have_incdir" = no ; then
6262 if test "$cf_add_incdir" = /usr/local/include ; then
6263 if test "$GCC" = yes
6265 cf_save_CPPFLAGS=$CPPFLAGS
6266 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6267 cat >conftest.$ac_ext <<_ACEOF
6268 #line 6268 "configure"
6269 #include "confdefs.h"
6279 rm -f conftest.$ac_objext
6280 if { (eval echo "$as_me:6280: \"$ac_compile\"") >&5
6281 (eval $ac_compile) 2>&5
6283 echo "$as_me:6283: \$? = $ac_status" >&5
6284 (exit $ac_status); } &&
6285 { ac_try='test -s conftest.$ac_objext'
6286 { (eval echo "$as_me:6286: \"$ac_try\"") >&5
6289 echo "$as_me:6289: \$? = $ac_status" >&5
6290 (exit $ac_status); }; }; then
6293 echo "$as_me: failed program was:" >&5
6294 cat conftest.$ac_ext >&5
6297 rm -f conftest.$ac_objext conftest.$ac_ext
6298 CPPFLAGS=$cf_save_CPPFLAGS
6303 if test "$cf_have_incdir" = no ; then
6304 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
6306 echo "${as_me:-configure}:6306: testing adding $cf_add_incdir to include-path ..." 1>&5
6308 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6310 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
6311 test "$cf_top_incdir" = "$cf_add_incdir" && break
6312 cf_add_incdir="$cf_top_incdir"
6326 cat >conftest.$ac_ext <<_ACEOF
6327 #line 6327 "configure"
6328 #include "confdefs.h"
6330 #include <$cf_header>
6335 #ifdef NCURSES_VERSION
6337 printf("%s\n", NCURSES_VERSION);
6350 rm -f conftest.$ac_objext
6351 if { (eval echo "$as_me:6351: \"$ac_compile\"") >&5
6352 (eval $ac_compile) 2>&5
6354 echo "$as_me:6354: \$? = $ac_status" >&5
6355 (exit $ac_status); } &&
6356 { ac_try='test -s conftest.$ac_objext'
6357 { (eval echo "$as_me:6357: \"$ac_try\"") >&5
6360 echo "$as_me:6360: \$? = $ac_status" >&5
6361 (exit $ac_status); }; }; then
6362 cf_cv_ncurses_h2=$cf_header
6365 echo "$as_me: failed program was:" >&5
6366 cat conftest.$ac_ext >&5
6369 rm -f conftest.$ac_objext conftest.$ac_ext
6371 if test "$cf_cv_ncurses_h2" != no ; then
6372 cf_cv_ncurses_h2=$cf_incdir/$cf_header
6373 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
6376 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
6378 CPPFLAGS="$cf_save2_CPPFLAGS"
6379 test "$cf_cv_ncurses_h2" != no && break
6381 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:6381: error: not found" >&5
6382 echo "$as_me: error: not found" >&2;}
6383 { (exit 1); exit 1; }; }
6386 echo "$as_me:6386: result: $cf_cv_ncurses_h2" >&5
6387 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
6389 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
6390 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
6391 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
6392 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
6395 if test -n "$cf_1st_incdir" ; then
6396 for cf_add_incdir in $cf_1st_incdir
6398 while test $cf_add_incdir != /usr/include
6400 if test -d $cf_add_incdir
6403 if test -n "$CFLAGS$CPPFLAGS" ; then
6404 # a loop is needed to ensure we can add subdirs of existing dirs
6405 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
6406 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
6407 cf_have_incdir=yes; break
6412 if test "$cf_have_incdir" = no ; then
6413 if test "$cf_add_incdir" = /usr/local/include ; then
6414 if test "$GCC" = yes
6416 cf_save_CPPFLAGS=$CPPFLAGS
6417 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6418 cat >conftest.$ac_ext <<_ACEOF
6419 #line 6419 "configure"
6420 #include "confdefs.h"
6430 rm -f conftest.$ac_objext
6431 if { (eval echo "$as_me:6431: \"$ac_compile\"") >&5
6432 (eval $ac_compile) 2>&5
6434 echo "$as_me:6434: \$? = $ac_status" >&5
6435 (exit $ac_status); } &&
6436 { ac_try='test -s conftest.$ac_objext'
6437 { (eval echo "$as_me:6437: \"$ac_try\"") >&5
6440 echo "$as_me:6440: \$? = $ac_status" >&5
6441 (exit $ac_status); }; }; then
6444 echo "$as_me: failed program was:" >&5
6445 cat conftest.$ac_ext >&5
6448 rm -f conftest.$ac_objext conftest.$ac_ext
6449 CPPFLAGS=$cf_save_CPPFLAGS
6454 if test "$cf_have_incdir" = no ; then
6455 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
6457 echo "${as_me:-configure}:6457: testing adding $cf_add_incdir to include-path ..." 1>&5
6459 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6461 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
6462 test "$cf_top_incdir" = "$cf_add_incdir" && break
6463 cf_add_incdir="$cf_top_incdir"
6474 # Set definitions to allow ifdef'ing for ncurses.h
6476 case $cf_cv_ncurses_header in # (vi
6478 cat >>confdefs.h <<\EOF
6479 #define HAVE_NCURSES_H 1
6485 case $cf_cv_ncurses_header in # (vi
6486 ncurses/curses.h|ncurses/ncurses.h)
6487 cat >>confdefs.h <<\EOF
6488 #define HAVE_NCURSES_NCURSES_H 1
6492 ncursesw/curses.h|ncursesw/ncurses.h)
6493 cat >>confdefs.h <<\EOF
6494 #define HAVE_NCURSESW_NCURSES_H 1
6500 echo "$as_me:6500: checking for terminfo header" >&5
6501 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
6502 if test "${cf_cv_term_header+set}" = set; then
6503 echo $ECHO_N "(cached) $ECHO_C" >&6
6506 case ${cf_cv_ncurses_header} in #(vi
6507 */ncurses.h|*/ncursesw.h) #(vi
6508 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
6511 cf_term_header=term.h
6515 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
6517 cat >conftest.$ac_ext <<_ACEOF
6518 #line 6518 "configure"
6519 #include "confdefs.h"
6521 #include <${cf_cv_ncurses_header:-curses.h}>
6527 int x = auto_left_margin
6532 rm -f conftest.$ac_objext
6533 if { (eval echo "$as_me:6533: \"$ac_compile\"") >&5
6534 (eval $ac_compile) 2>&5
6536 echo "$as_me:6536: \$? = $ac_status" >&5
6537 (exit $ac_status); } &&
6538 { ac_try='test -s conftest.$ac_objext'
6539 { (eval echo "$as_me:6539: \"$ac_try\"") >&5
6542 echo "$as_me:6542: \$? = $ac_status" >&5
6543 (exit $ac_status); }; }; then
6545 cf_cv_term_header="$cf_test"
6547 echo "$as_me: failed program was:" >&5
6548 cat conftest.$ac_ext >&5
6550 cf_cv_term_header=unknown
6553 rm -f conftest.$ac_objext conftest.$ac_ext
6554 test "$cf_cv_term_header" != unknown && break
6558 echo "$as_me:6558: result: $cf_cv_term_header" >&5
6559 echo "${ECHO_T}$cf_cv_term_header" >&6
6561 # Set definitions to allow ifdef'ing to accommodate subdirectories
6563 case $cf_cv_term_header in # (vi
6565 cat >>confdefs.h <<\EOF
6566 #define HAVE_TERM_H 1
6572 case $cf_cv_term_header in # (vi
6573 ncurses/term.h) #(vi
6574 cat >>confdefs.h <<\EOF
6575 #define HAVE_NCURSES_TERM_H 1
6580 cat >>confdefs.h <<\EOF
6581 #define HAVE_NCURSESW_TERM_H 1
6587 # some applications need this, but should check for NCURSES_VERSION
6588 cat >>confdefs.h <<\EOF
6592 echo "$as_me:6592: checking for ncurses version" >&5
6593 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
6594 if test "${cf_cv_ncurses_version+set}" = set; then
6595 echo $ECHO_N "(cached) $ECHO_C" >&6
6598 cf_cv_ncurses_version=no
6601 if test "$cross_compiling" = yes; then
6603 # This will not work if the preprocessor splits the line after the
6604 # Autoconf token. The 'unproto' program does that.
6605 cat > conftest.$ac_ext <<EOF
6606 #include <${cf_cv_ncurses_header:-curses.h}>
6608 #ifdef NCURSES_VERSION
6609 Autoconf NCURSES_VERSION
6617 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
6618 { (eval echo "$as_me:6618: \"$cf_try\"") >&5
6621 echo "$as_me:6621: \$? = $ac_status" >&5
6622 (exit $ac_status); }
6623 if test -f conftest.out ; then
6624 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
6625 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
6630 cat >conftest.$ac_ext <<_ACEOF
6631 #line 6631 "configure"
6632 #include "confdefs.h"
6634 #include <${cf_cv_ncurses_header:-curses.h}>
6638 FILE *fp = fopen("$cf_tempfile", "w");
6639 #ifdef NCURSES_VERSION
6640 # ifdef NCURSES_VERSION_PATCH
6641 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
6643 fprintf(fp, "%s\n", NCURSES_VERSION);
6647 fprintf(fp, "old\n");
6652 ${cf_cv_main_return:-return}(0);
6655 rm -f conftest$ac_exeext
6656 if { (eval echo "$as_me:6656: \"$ac_link\"") >&5
6657 (eval $ac_link) 2>&5
6659 echo "$as_me:6659: \$? = $ac_status" >&5
6660 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
6661 { (eval echo "$as_me:6661: \"$ac_try\"") >&5
6664 echo "$as_me:6664: \$? = $ac_status" >&5
6665 (exit $ac_status); }; }; then
6667 cf_cv_ncurses_version=`cat $cf_tempfile`
6669 echo "$as_me: program exited with status $ac_status" >&5
6670 echo "$as_me: failed program was:" >&5
6671 cat conftest.$ac_ext >&5
6673 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6678 echo "$as_me:6678: result: $cf_cv_ncurses_version" >&5
6679 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
6680 test "$cf_cv_ncurses_version" = no || cat >>confdefs.h <<\EOF
6684 cf_nculib_root=ncurses
6685 # This works, except for the special case where we find gpm, but
6686 # ncurses is in a nonstandard location via $LIBS, and we really want
6689 cf_ncurses_SAVE="$LIBS"
6690 echo "$as_me:6690: checking for Gpm_Open in -lgpm" >&5
6691 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
6692 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
6693 echo $ECHO_N "(cached) $ECHO_C" >&6
6695 ac_check_lib_save_LIBS=$LIBS
6697 cat >conftest.$ac_ext <<_ACEOF
6698 #line 6698 "configure"
6699 #include "confdefs.h"
6701 /* Override any gcc2 internal prototype to avoid an error. */
6705 /* We use char because int might match the return type of a gcc2
6706 builtin and then its argument prototype would still apply. */
6716 rm -f conftest.$ac_objext conftest$ac_exeext
6717 if { (eval echo "$as_me:6717: \"$ac_link\"") >&5
6718 (eval $ac_link) 2>&5
6720 echo "$as_me:6720: \$? = $ac_status" >&5
6721 (exit $ac_status); } &&
6722 { ac_try='test -s conftest$ac_exeext'
6723 { (eval echo "$as_me:6723: \"$ac_try\"") >&5
6726 echo "$as_me:6726: \$? = $ac_status" >&5
6727 (exit $ac_status); }; }; then
6728 ac_cv_lib_gpm_Gpm_Open=yes
6730 echo "$as_me: failed program was:" >&5
6731 cat conftest.$ac_ext >&5
6732 ac_cv_lib_gpm_Gpm_Open=no
6734 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6735 LIBS=$ac_check_lib_save_LIBS
6737 echo "$as_me:6737: result: $ac_cv_lib_gpm_Gpm_Open" >&5
6738 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
6739 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
6740 echo "$as_me:6740: checking for initscr in -lgpm" >&5
6741 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
6742 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
6743 echo $ECHO_N "(cached) $ECHO_C" >&6
6745 ac_check_lib_save_LIBS=$LIBS
6747 cat >conftest.$ac_ext <<_ACEOF
6748 #line 6748 "configure"
6749 #include "confdefs.h"
6751 /* Override any gcc2 internal prototype to avoid an error. */
6755 /* We use char because int might match the return type of a gcc2
6756 builtin and then its argument prototype would still apply. */
6766 rm -f conftest.$ac_objext conftest$ac_exeext
6767 if { (eval echo "$as_me:6767: \"$ac_link\"") >&5
6768 (eval $ac_link) 2>&5
6770 echo "$as_me:6770: \$? = $ac_status" >&5
6771 (exit $ac_status); } &&
6772 { ac_try='test -s conftest$ac_exeext'
6773 { (eval echo "$as_me:6773: \"$ac_try\"") >&5
6776 echo "$as_me:6776: \$? = $ac_status" >&5
6777 (exit $ac_status); }; }; then
6778 ac_cv_lib_gpm_initscr=yes
6780 echo "$as_me: failed program was:" >&5
6781 cat conftest.$ac_ext >&5
6782 ac_cv_lib_gpm_initscr=no
6784 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6785 LIBS=$ac_check_lib_save_LIBS
6787 echo "$as_me:6787: result: $ac_cv_lib_gpm_initscr" >&5
6788 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
6789 if test $ac_cv_lib_gpm_initscr = yes; then
6790 LIBS="$cf_ncurses_SAVE"
6792 cf_ncurses_LIBS="-lgpm"
6797 case $host_os in #(vi
6799 # This is only necessary if you are linking against an obsolete
6800 # version of ncurses (but it should do no harm, since it's static).
6801 if test "$cf_nculib_root" = ncurses ; then
6802 echo "$as_me:6802: checking for tgoto in -lmytinfo" >&5
6803 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
6804 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
6805 echo $ECHO_N "(cached) $ECHO_C" >&6
6807 ac_check_lib_save_LIBS=$LIBS
6808 LIBS="-lmytinfo $LIBS"
6809 cat >conftest.$ac_ext <<_ACEOF
6810 #line 6810 "configure"
6811 #include "confdefs.h"
6813 /* Override any gcc2 internal prototype to avoid an error. */
6817 /* We use char because int might match the return type of a gcc2
6818 builtin and then its argument prototype would still apply. */
6828 rm -f conftest.$ac_objext conftest$ac_exeext
6829 if { (eval echo "$as_me:6829: \"$ac_link\"") >&5
6830 (eval $ac_link) 2>&5
6832 echo "$as_me:6832: \$? = $ac_status" >&5
6833 (exit $ac_status); } &&
6834 { ac_try='test -s conftest$ac_exeext'
6835 { (eval echo "$as_me:6835: \"$ac_try\"") >&5
6838 echo "$as_me:6838: \$? = $ac_status" >&5
6839 (exit $ac_status); }; }; then
6840 ac_cv_lib_mytinfo_tgoto=yes
6842 echo "$as_me: failed program was:" >&5
6843 cat conftest.$ac_ext >&5
6844 ac_cv_lib_mytinfo_tgoto=no
6846 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6847 LIBS=$ac_check_lib_save_LIBS
6849 echo "$as_me:6849: result: $ac_cv_lib_mytinfo_tgoto" >&5
6850 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
6851 if test $ac_cv_lib_mytinfo_tgoto = yes; then
6852 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
6859 LIBS="$cf_ncurses_LIBS $LIBS"
6861 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
6863 LIBS="-l$cf_nculib_root $LIBS"
6866 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
6868 echo "$as_me:6868: checking for initscr" >&5
6869 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
6870 if test "${ac_cv_func_initscr+set}" = set; then
6871 echo $ECHO_N "(cached) $ECHO_C" >&6
6873 cat >conftest.$ac_ext <<_ACEOF
6874 #line 6874 "configure"
6875 #include "confdefs.h"
6876 /* System header to define __stub macros and hopefully few prototypes,
6877 which can conflict with char initscr (); below. */
6879 /* Override any gcc2 internal prototype to avoid an error. */
6883 /* We use char because int might match the return type of a gcc2
6884 builtin and then its argument prototype would still apply. */
6891 /* The GNU C library defines this for functions which it implements
6892 to always fail with ENOSYS. Some functions are actually named
6893 something starting with __ and the normal name is an alias. */
6894 #if defined (__stub_initscr) || defined (__stub___initscr)
6904 rm -f conftest.$ac_objext conftest$ac_exeext
6905 if { (eval echo "$as_me:6905: \"$ac_link\"") >&5
6906 (eval $ac_link) 2>&5
6908 echo "$as_me:6908: \$? = $ac_status" >&5
6909 (exit $ac_status); } &&
6910 { ac_try='test -s conftest$ac_exeext'
6911 { (eval echo "$as_me:6911: \"$ac_try\"") >&5
6914 echo "$as_me:6914: \$? = $ac_status" >&5
6915 (exit $ac_status); }; }; then
6916 ac_cv_func_initscr=yes
6918 echo "$as_me: failed program was:" >&5
6919 cat conftest.$ac_ext >&5
6920 ac_cv_func_initscr=no
6922 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6924 echo "$as_me:6924: result: $ac_cv_func_initscr" >&5
6925 echo "${ECHO_T}$ac_cv_func_initscr" >&6
6926 if test $ac_cv_func_initscr = yes; then
6927 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
6930 cf_save_LIBS="$LIBS"
6931 echo "$as_me:6931: checking for initscr in -l$cf_nculib_root" >&5
6932 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
6933 LIBS="-l$cf_nculib_root $LIBS"
6934 cat >conftest.$ac_ext <<_ACEOF
6935 #line 6935 "configure"
6936 #include "confdefs.h"
6937 #include <${cf_cv_ncurses_header:-curses.h}>
6946 rm -f conftest.$ac_objext conftest$ac_exeext
6947 if { (eval echo "$as_me:6947: \"$ac_link\"") >&5
6948 (eval $ac_link) 2>&5
6950 echo "$as_me:6950: \$? = $ac_status" >&5
6951 (exit $ac_status); } &&
6952 { ac_try='test -s conftest$ac_exeext'
6953 { (eval echo "$as_me:6953: \"$ac_try\"") >&5
6956 echo "$as_me:6956: \$? = $ac_status" >&5
6957 (exit $ac_status); }; }; then
6958 echo "$as_me:6958: result: yes" >&5
6959 echo "${ECHO_T}yes" >&6
6960 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
6963 echo "$as_me: failed program was:" >&5
6964 cat conftest.$ac_ext >&5
6965 echo "$as_me:6965: result: no" >&5
6966 echo "${ECHO_T}no" >&6
6969 cf_library_path_list=""
6970 if test -n "${LDFLAGS}${LIBS}" ; then
6971 for cf_library_path in $LDFLAGS $LIBS
6973 case $cf_library_path in #(vi
6975 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
6977 test "$cf_library_path" != "NONE" && \
6978 test -d "$cf_library_path" && \
6980 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
6981 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
6982 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
6983 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
6984 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
6985 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"
6988 cf_library_path_list="$cf_library_path_list $cf_search"
6996 test "/usr" != "$prefix" && \
6998 (test $prefix = NONE || test "/usr" != "$prefix") && {
6999 test -n "$verbose" && echo " ... testing for lib-directories under /usr"
7000 test -d /usr/lib && cf_search="$cf_search /usr/lib"
7001 test -d /usr/lib/$cf_nculib_root && cf_search="$cf_search /usr/lib/$cf_nculib_root"
7002 test -d /usr/lib/$cf_nculib_root/lib && cf_search="$cf_search /usr/lib/$cf_nculib_root/lib"
7003 test -d /usr/$cf_nculib_root/lib && cf_search="$cf_search /usr/$cf_nculib_root/lib"
7004 test -d /usr/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /usr/$cf_nculib_root/lib/$cf_nculib_root"
7007 test "$prefix" != "NONE" && \
7008 test -d "$prefix" && \
7010 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
7011 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
7012 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
7013 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
7014 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
7015 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
7018 test "/usr/local" != "$prefix" && \
7019 test -d "/usr/local" && \
7020 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
7021 test -n "$verbose" && echo " ... testing for lib-directories under /usr/local"
7022 test -d /usr/local/lib && cf_search="$cf_search /usr/local/lib"
7023 test -d /usr/local/lib/$cf_nculib_root && cf_search="$cf_search /usr/local/lib/$cf_nculib_root"
7024 test -d /usr/local/lib/$cf_nculib_root/lib && cf_search="$cf_search /usr/local/lib/$cf_nculib_root/lib"
7025 test -d /usr/local/$cf_nculib_root/lib && cf_search="$cf_search /usr/local/$cf_nculib_root/lib"
7026 test -d /usr/local/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /usr/local/$cf_nculib_root/lib/$cf_nculib_root"
7029 test "/opt" != "$prefix" && \
7031 (test $prefix = NONE || test "/opt" != "$prefix") && {
7032 test -n "$verbose" && echo " ... testing for lib-directories under /opt"
7033 test -d /opt/lib && cf_search="$cf_search /opt/lib"
7034 test -d /opt/lib/$cf_nculib_root && cf_search="$cf_search /opt/lib/$cf_nculib_root"
7035 test -d /opt/lib/$cf_nculib_root/lib && cf_search="$cf_search /opt/lib/$cf_nculib_root/lib"
7036 test -d /opt/$cf_nculib_root/lib && cf_search="$cf_search /opt/$cf_nculib_root/lib"
7037 test -d /opt/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /opt/$cf_nculib_root/lib/$cf_nculib_root"
7040 test "$HOME" != "$prefix" && \
7041 test -d "$HOME" && \
7042 (test $prefix = NONE || test "$HOME" != "$prefix") && {
7043 test -n "$verbose" && echo " ... testing for lib-directories under $HOME"
7044 test -d $HOME/lib && cf_search="$cf_search $HOME/lib"
7045 test -d $HOME/lib/$cf_nculib_root && cf_search="$cf_search $HOME/lib/$cf_nculib_root"
7046 test -d $HOME/lib/$cf_nculib_root/lib && cf_search="$cf_search $HOME/lib/$cf_nculib_root/lib"
7047 test -d $HOME/$cf_nculib_root/lib && cf_search="$cf_search $HOME/$cf_nculib_root/lib"
7048 test -d $HOME/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $HOME/$cf_nculib_root/lib/$cf_nculib_root"
7051 cf_search="$cf_library_path_list $cf_search"
7053 for cf_libdir in $cf_search
7055 echo "$as_me:7055: checking for -l$cf_nculib_root in $cf_libdir" >&5
7056 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
7057 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
7058 cat >conftest.$ac_ext <<_ACEOF
7059 #line 7059 "configure"
7060 #include "confdefs.h"
7061 #include <${cf_cv_ncurses_header:-curses.h}>
7070 rm -f conftest.$ac_objext conftest$ac_exeext
7071 if { (eval echo "$as_me:7071: \"$ac_link\"") >&5
7072 (eval $ac_link) 2>&5
7074 echo "$as_me:7074: \$? = $ac_status" >&5
7075 (exit $ac_status); } &&
7076 { ac_try='test -s conftest$ac_exeext'
7077 { (eval echo "$as_me:7077: \"$ac_try\"") >&5
7080 echo "$as_me:7080: \$? = $ac_status" >&5
7081 (exit $ac_status); }; }; then
7082 echo "$as_me:7082: result: yes" >&5
7083 echo "${ECHO_T}yes" >&6
7084 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
7087 echo "$as_me: failed program was:" >&5
7088 cat conftest.$ac_ext >&5
7089 echo "$as_me:7089: result: no" >&5
7090 echo "${ECHO_T}no" >&6
7091 LIBS="$cf_save_LIBS"
7093 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7097 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7101 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
7103 if test $cf_found_library = no ; then
7104 { { echo "$as_me:7104: error: Cannot link $cf_nculib_root library" >&5
7105 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
7106 { (exit 1); exit 1; }; }
7111 if test -n "$cf_ncurses_LIBS" ; then
7112 echo "$as_me:7112: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
7113 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
7114 cf_ncurses_SAVE="$LIBS"
7115 for p in $cf_ncurses_LIBS ; do
7116 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
7117 if test "$q" != "$LIBS" ; then
7121 cat >conftest.$ac_ext <<_ACEOF
7122 #line 7122 "configure"
7123 #include "confdefs.h"
7124 #include <${cf_cv_ncurses_header:-curses.h}>
7128 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
7133 rm -f conftest.$ac_objext conftest$ac_exeext
7134 if { (eval echo "$as_me:7134: \"$ac_link\"") >&5
7135 (eval $ac_link) 2>&5
7137 echo "$as_me:7137: \$? = $ac_status" >&5
7138 (exit $ac_status); } &&
7139 { ac_try='test -s conftest$ac_exeext'
7140 { (eval echo "$as_me:7140: \"$ac_try\"") >&5
7143 echo "$as_me:7143: \$? = $ac_status" >&5
7144 (exit $ac_status); }; }; then
7145 echo "$as_me:7145: result: yes" >&5
7146 echo "${ECHO_T}yes" >&6
7148 echo "$as_me: failed program was:" >&5
7149 cat conftest.$ac_ext >&5
7150 echo "$as_me:7150: result: no" >&5
7151 echo "${ECHO_T}no" >&6
7152 LIBS="$cf_ncurses_SAVE"
7154 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7157 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
7159 cat >>confdefs.h <<EOF
7160 #define $cf_nculib_ROOT 1
7169 echo "$as_me:7169: checking for multibyte character support" >&5
7170 echo $ECHO_N "checking for multibyte character support... $ECHO_C" >&6
7171 if test "${cf_cv_utf8_lib+set}" = set; then
7172 echo $ECHO_N "(cached) $ECHO_C" >&6
7175 cf_save_LIBS="$LIBS"
7176 cat >conftest.$ac_ext <<_ACEOF
7177 #line 7177 "configure"
7178 #include "confdefs.h"
7189 rm -f conftest.$ac_objext conftest$ac_exeext
7190 if { (eval echo "$as_me:7190: \"$ac_link\"") >&5
7191 (eval $ac_link) 2>&5
7193 echo "$as_me:7193: \$? = $ac_status" >&5
7194 (exit $ac_status); } &&
7195 { ac_try='test -s conftest$ac_exeext'
7196 { (eval echo "$as_me:7196: \"$ac_try\"") >&5
7199 echo "$as_me:7199: \$? = $ac_status" >&5
7200 (exit $ac_status); }; }; then
7203 echo "$as_me: failed program was:" >&5
7204 cat conftest.$ac_ext >&5
7206 # If the linkage is not already in the $CPPFLAGS/$LDFLAGS configuration, these
7207 # will be set on completion of the AC_TRY_LINK below.
7208 cf_cv_header_path_utf8=
7209 cf_cv_library_path_utf8=
7211 echo "${as_me:-configure}:7211: testing Starting FIND_LINKAGE(utf8,) ..." 1>&5
7213 cf_save_LIBS="$LIBS"
7215 cat >conftest.$ac_ext <<_ACEOF
7216 #line 7216 "configure"
7217 #include "confdefs.h"
7219 #include <libutf8.h>
7228 rm -f conftest.$ac_objext conftest$ac_exeext
7229 if { (eval echo "$as_me:7229: \"$ac_link\"") >&5
7230 (eval $ac_link) 2>&5
7232 echo "$as_me:7232: \$? = $ac_status" >&5
7233 (exit $ac_status); } &&
7234 { ac_try='test -s conftest$ac_exeext'
7235 { (eval echo "$as_me:7235: \"$ac_try\"") >&5
7238 echo "$as_me:7238: \$? = $ac_status" >&5
7239 (exit $ac_status); }; }; then
7241 cf_cv_find_linkage_utf8=yes
7242 cf_cv_header_path_utf8=/usr/include
7243 cf_cv_library_path_utf8=/usr/lib
7246 echo "$as_me: failed program was:" >&5
7247 cat conftest.$ac_ext >&5
7249 LIBS="-lutf8 $cf_save_LIBS"
7251 cat >conftest.$ac_ext <<_ACEOF
7252 #line 7252 "configure"
7253 #include "confdefs.h"
7255 #include <libutf8.h>
7264 rm -f conftest.$ac_objext conftest$ac_exeext
7265 if { (eval echo "$as_me:7265: \"$ac_link\"") >&5
7266 (eval $ac_link) 2>&5
7268 echo "$as_me:7268: \$? = $ac_status" >&5
7269 (exit $ac_status); } &&
7270 { ac_try='test -s conftest$ac_exeext'
7271 { (eval echo "$as_me:7271: \"$ac_try\"") >&5
7274 echo "$as_me:7274: \$? = $ac_status" >&5
7275 (exit $ac_status); }; }; then
7277 cf_cv_find_linkage_utf8=yes
7278 cf_cv_header_path_utf8=/usr/include
7279 cf_cv_library_path_utf8=/usr/lib
7280 cf_cv_library_file_utf8="-lutf8"
7283 echo "$as_me: failed program was:" >&5
7284 cat conftest.$ac_ext >&5
7286 cf_cv_find_linkage_utf8=no
7287 LIBS="$cf_save_LIBS"
7289 test -n "$verbose" && echo " find linkage for utf8 library" 1>&6
7291 echo "${as_me:-configure}:7291: testing find linkage for utf8 library ..." 1>&5
7293 echo "${as_me:-configure}:7293: testing Searching for headers in FIND_LINKAGE(utf8,) ..." 1>&5
7295 cf_save_CPPFLAGS="$CPPFLAGS"
7296 cf_test_CPPFLAGS="$CPPFLAGS"
7300 # collect the current set of include-directories from compiler flags
7301 cf_header_path_list=""
7302 if test -n "${CFLAGS}${CPPFLAGS}" ; then
7303 for cf_header_path in $CPPFLAGS $CFLAGS
7305 case $cf_header_path in #(vi
7307 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
7309 test "$cf_header_path" != "NONE" && \
7310 test -d "$cf_header_path" && \
7312 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
7313 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
7314 test -d $cf_header_path/include/utf8 && cf_search="$cf_search $cf_header_path/include/utf8"
7315 test -d $cf_header_path/include/utf8/include && cf_search="$cf_search $cf_header_path/include/utf8/include"
7316 test -d $cf_header_path/utf8/include && cf_search="$cf_search $cf_header_path/utf8/include"
7317 test -d $cf_header_path/utf8/include/utf8 && cf_search="$cf_search $cf_header_path/utf8/include/utf8"
7320 cf_header_path_list="$cf_header_path_list $cf_search"
7326 # add the variations for the package we are looking for
7330 test "/usr" != "$prefix" && \
7332 (test $prefix = NONE || test "/usr" != "$prefix") && {
7333 test -n "$verbose" && echo " ... testing for include-directories under /usr"
7334 test -d /usr/include && cf_search="$cf_search /usr/include"
7335 test -d /usr/include/utf8 && cf_search="$cf_search /usr/include/utf8"
7336 test -d /usr/include/utf8/include && cf_search="$cf_search /usr/include/utf8/include"
7337 test -d /usr/utf8/include && cf_search="$cf_search /usr/utf8/include"
7338 test -d /usr/utf8/include/utf8 && cf_search="$cf_search /usr/utf8/include/utf8"
7341 test "$prefix" != "NONE" && \
7342 test -d "$prefix" && \
7344 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
7345 test -d $prefix/include && cf_search="$cf_search $prefix/include"
7346 test -d $prefix/include/utf8 && cf_search="$cf_search $prefix/include/utf8"
7347 test -d $prefix/include/utf8/include && cf_search="$cf_search $prefix/include/utf8/include"
7348 test -d $prefix/utf8/include && cf_search="$cf_search $prefix/utf8/include"
7349 test -d $prefix/utf8/include/utf8 && cf_search="$cf_search $prefix/utf8/include/utf8"
7352 test "/usr/local" != "$prefix" && \
7353 test -d "/usr/local" && \
7354 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
7355 test -n "$verbose" && echo " ... testing for include-directories under /usr/local"
7356 test -d /usr/local/include && cf_search="$cf_search /usr/local/include"
7357 test -d /usr/local/include/utf8 && cf_search="$cf_search /usr/local/include/utf8"
7358 test -d /usr/local/include/utf8/include && cf_search="$cf_search /usr/local/include/utf8/include"
7359 test -d /usr/local/utf8/include && cf_search="$cf_search /usr/local/utf8/include"
7360 test -d /usr/local/utf8/include/utf8 && cf_search="$cf_search /usr/local/utf8/include/utf8"
7363 test "/opt" != "$prefix" && \
7365 (test $prefix = NONE || test "/opt" != "$prefix") && {
7366 test -n "$verbose" && echo " ... testing for include-directories under /opt"
7367 test -d /opt/include && cf_search="$cf_search /opt/include"
7368 test -d /opt/include/utf8 && cf_search="$cf_search /opt/include/utf8"
7369 test -d /opt/include/utf8/include && cf_search="$cf_search /opt/include/utf8/include"
7370 test -d /opt/utf8/include && cf_search="$cf_search /opt/utf8/include"
7371 test -d /opt/utf8/include/utf8 && cf_search="$cf_search /opt/utf8/include/utf8"
7374 test "$HOME" != "$prefix" && \
7375 test -d "$HOME" && \
7376 (test $prefix = NONE || test "$HOME" != "$prefix") && {
7377 test -n "$verbose" && echo " ... testing for include-directories under $HOME"
7378 test -d $HOME/include && cf_search="$cf_search $HOME/include"
7379 test -d $HOME/include/utf8 && cf_search="$cf_search $HOME/include/utf8"
7380 test -d $HOME/include/utf8/include && cf_search="$cf_search $HOME/include/utf8/include"
7381 test -d $HOME/utf8/include && cf_search="$cf_search $HOME/utf8/include"
7382 test -d $HOME/utf8/include/utf8 && cf_search="$cf_search $HOME/utf8/include/utf8"
7385 test "$includedir" != NONE && \
7386 test "$includedir" != "/usr/include" && \
7387 test -d "$includedir" && {
7388 test -d $includedir && cf_search="$cf_search $includedir"
7389 test -d $includedir/utf8 && cf_search="$cf_search $includedir/utf8"
7392 test "$oldincludedir" != NONE && \
7393 test "$oldincludedir" != "/usr/include" && \
7394 test -d "$oldincludedir" && {
7395 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
7396 test -d $oldincludedir/utf8 && cf_search="$cf_search $oldincludedir/utf8"
7399 cf_search="$cf_search $cf_header_path_list"
7401 for cf_cv_header_path_utf8 in $cf_search
7403 if test -d $cf_cv_header_path_utf8 ; then
7404 test -n "$verbose" && echo " ... testing $cf_cv_header_path_utf8" 1>&6
7406 echo "${as_me:-configure}:7406: testing ... testing $cf_cv_header_path_utf8 ..." 1>&5
7408 CPPFLAGS="$cf_save_CPPFLAGS -I$cf_cv_header_path_utf8"
7409 cat >conftest.$ac_ext <<_ACEOF
7410 #line 7410 "configure"
7411 #include "confdefs.h"
7413 #include <libutf8.h>
7422 rm -f conftest.$ac_objext
7423 if { (eval echo "$as_me:7423: \"$ac_compile\"") >&5
7424 (eval $ac_compile) 2>&5
7426 echo "$as_me:7426: \$? = $ac_status" >&5
7427 (exit $ac_status); } &&
7428 { ac_try='test -s conftest.$ac_objext'
7429 { (eval echo "$as_me:7429: \"$ac_try\"") >&5
7432 echo "$as_me:7432: \$? = $ac_status" >&5
7433 (exit $ac_status); }; }; then
7435 test -n "$verbose" && echo " ... found utf8 headers in $cf_cv_header_path_utf8" 1>&6
7437 echo "${as_me:-configure}:7437: testing ... found utf8 headers in $cf_cv_header_path_utf8 ..." 1>&5
7439 cf_cv_find_linkage_utf8=maybe
7440 cf_test_CPPFLAGS="$CPPFLAGS"
7443 echo "$as_me: failed program was:" >&5
7444 cat conftest.$ac_ext >&5
7446 CPPFLAGS="$cf_save_CPPFLAGS"
7449 rm -f conftest.$ac_objext conftest.$ac_ext
7453 if test "$cf_cv_find_linkage_utf8" = maybe ; then
7455 echo "${as_me:-configure}:7455: testing Searching for utf8 library in FIND_LINKAGE(utf8,) ..." 1>&5
7457 cf_save_LIBS="$LIBS"
7458 cf_save_LDFLAGS="$LDFLAGS"
7460 if test "$cf_cv_find_linkage_utf8" != yes ; then
7463 cf_library_path_list=""
7464 if test -n "${LDFLAGS}${LIBS}" ; then
7465 for cf_library_path in $LDFLAGS $LIBS
7467 case $cf_library_path in #(vi
7469 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
7471 test "$cf_library_path" != "NONE" && \
7472 test -d "$cf_library_path" && \
7474 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
7475 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
7476 test -d $cf_library_path/lib/utf8 && cf_search="$cf_search $cf_library_path/lib/utf8"
7477 test -d $cf_library_path/lib/utf8/lib && cf_search="$cf_search $cf_library_path/lib/utf8/lib"
7478 test -d $cf_library_path/utf8/lib && cf_search="$cf_search $cf_library_path/utf8/lib"
7479 test -d $cf_library_path/utf8/lib/utf8 && cf_search="$cf_search $cf_library_path/utf8/lib/utf8"
7482 cf_library_path_list="$cf_library_path_list $cf_search"
7490 test "/usr" != "$prefix" && \
7492 (test $prefix = NONE || test "/usr" != "$prefix") && {
7493 test -n "$verbose" && echo " ... testing for lib-directories under /usr"
7494 test -d /usr/lib && cf_search="$cf_search /usr/lib"
7495 test -d /usr/lib/utf8 && cf_search="$cf_search /usr/lib/utf8"
7496 test -d /usr/lib/utf8/lib && cf_search="$cf_search /usr/lib/utf8/lib"
7497 test -d /usr/utf8/lib && cf_search="$cf_search /usr/utf8/lib"
7498 test -d /usr/utf8/lib/utf8 && cf_search="$cf_search /usr/utf8/lib/utf8"
7501 test "$prefix" != "NONE" && \
7502 test -d "$prefix" && \
7504 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
7505 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
7506 test -d $prefix/lib/utf8 && cf_search="$cf_search $prefix/lib/utf8"
7507 test -d $prefix/lib/utf8/lib && cf_search="$cf_search $prefix/lib/utf8/lib"
7508 test -d $prefix/utf8/lib && cf_search="$cf_search $prefix/utf8/lib"
7509 test -d $prefix/utf8/lib/utf8 && cf_search="$cf_search $prefix/utf8/lib/utf8"
7512 test "/usr/local" != "$prefix" && \
7513 test -d "/usr/local" && \
7514 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
7515 test -n "$verbose" && echo " ... testing for lib-directories under /usr/local"
7516 test -d /usr/local/lib && cf_search="$cf_search /usr/local/lib"
7517 test -d /usr/local/lib/utf8 && cf_search="$cf_search /usr/local/lib/utf8"
7518 test -d /usr/local/lib/utf8/lib && cf_search="$cf_search /usr/local/lib/utf8/lib"
7519 test -d /usr/local/utf8/lib && cf_search="$cf_search /usr/local/utf8/lib"
7520 test -d /usr/local/utf8/lib/utf8 && cf_search="$cf_search /usr/local/utf8/lib/utf8"
7523 test "/opt" != "$prefix" && \
7525 (test $prefix = NONE || test "/opt" != "$prefix") && {
7526 test -n "$verbose" && echo " ... testing for lib-directories under /opt"
7527 test -d /opt/lib && cf_search="$cf_search /opt/lib"
7528 test -d /opt/lib/utf8 && cf_search="$cf_search /opt/lib/utf8"
7529 test -d /opt/lib/utf8/lib && cf_search="$cf_search /opt/lib/utf8/lib"
7530 test -d /opt/utf8/lib && cf_search="$cf_search /opt/utf8/lib"
7531 test -d /opt/utf8/lib/utf8 && cf_search="$cf_search /opt/utf8/lib/utf8"
7534 test "$HOME" != "$prefix" && \
7535 test -d "$HOME" && \
7536 (test $prefix = NONE || test "$HOME" != "$prefix") && {
7537 test -n "$verbose" && echo " ... testing for lib-directories under $HOME"
7538 test -d $HOME/lib && cf_search="$cf_search $HOME/lib"
7539 test -d $HOME/lib/utf8 && cf_search="$cf_search $HOME/lib/utf8"
7540 test -d $HOME/lib/utf8/lib && cf_search="$cf_search $HOME/lib/utf8/lib"
7541 test -d $HOME/utf8/lib && cf_search="$cf_search $HOME/utf8/lib"
7542 test -d $HOME/utf8/lib/utf8 && cf_search="$cf_search $HOME/utf8/lib/utf8"
7545 cf_search="$cf_library_path_list $cf_search"
7547 for cf_cv_library_path_utf8 in $cf_search
7549 if test -d $cf_cv_library_path_utf8 ; then
7550 test -n "$verbose" && echo " ... testing $cf_cv_library_path_utf8" 1>&6
7552 echo "${as_me:-configure}:7552: testing ... testing $cf_cv_library_path_utf8 ..." 1>&5
7554 CPPFLAGS="$cf_test_CPPFLAGS"
7555 LIBS="-lutf8 $cf_save_LIBS"
7556 LDFLAGS="$cf_save_LDFLAGS -L$cf_cv_library_path_utf8"
7557 cat >conftest.$ac_ext <<_ACEOF
7558 #line 7558 "configure"
7559 #include "confdefs.h"
7561 #include <libutf8.h>
7570 rm -f conftest.$ac_objext conftest$ac_exeext
7571 if { (eval echo "$as_me:7571: \"$ac_link\"") >&5
7572 (eval $ac_link) 2>&5
7574 echo "$as_me:7574: \$? = $ac_status" >&5
7575 (exit $ac_status); } &&
7576 { ac_try='test -s conftest$ac_exeext'
7577 { (eval echo "$as_me:7577: \"$ac_try\"") >&5
7580 echo "$as_me:7580: \$? = $ac_status" >&5
7581 (exit $ac_status); }; }; then
7583 test -n "$verbose" && echo " ... found utf8 library in $cf_cv_library_path_utf8" 1>&6
7585 echo "${as_me:-configure}:7585: testing ... found utf8 library in $cf_cv_library_path_utf8 ..." 1>&5
7587 cf_cv_find_linkage_utf8=yes
7588 cf_cv_library_file_utf8="-lutf8"
7591 echo "$as_me: failed program was:" >&5
7592 cat conftest.$ac_ext >&5
7594 CPPFLAGS="$cf_save_CPPFLAGS"
7595 LIBS="$cf_save_LIBS"
7596 LDFLAGS="$cf_save_LDFLAGS"
7599 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7602 CPPFLAGS="$cf_save_CPPFLAGS"
7603 LDFLAGS="$cf_save_LDFLAGS"
7607 cf_cv_find_linkage_utf8=no
7611 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7614 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7616 LIBS="$cf_save_LIBS"
7618 if test "$cf_cv_find_linkage_utf8" = yes ; then
7619 cf_cv_utf8_lib=add-on
7625 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7627 echo "$as_me:7627: result: $cf_cv_utf8_lib" >&5
7628 echo "${ECHO_T}$cf_cv_utf8_lib" >&6
7630 # HAVE_LIBUTF8_H is used by ncurses if curses.h is shared between
7632 if test "$cf_cv_utf8_lib" = "add-on" ; then
7633 cat >>confdefs.h <<\EOF
7634 #define HAVE_LIBUTF8_H 1
7637 if test -n "$cf_cv_header_path_utf8" ; then
7638 for cf_add_incdir in $cf_cv_header_path_utf8
7640 while test $cf_add_incdir != /usr/include
7642 if test -d $cf_add_incdir
7645 if test -n "$CFLAGS$CPPFLAGS" ; then
7646 # a loop is needed to ensure we can add subdirs of existing dirs
7647 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
7648 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
7649 cf_have_incdir=yes; break
7654 if test "$cf_have_incdir" = no ; then
7655 if test "$cf_add_incdir" = /usr/local/include ; then
7656 if test "$GCC" = yes
7658 cf_save_CPPFLAGS=$CPPFLAGS
7659 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7660 cat >conftest.$ac_ext <<_ACEOF
7661 #line 7661 "configure"
7662 #include "confdefs.h"
7672 rm -f conftest.$ac_objext
7673 if { (eval echo "$as_me:7673: \"$ac_compile\"") >&5
7674 (eval $ac_compile) 2>&5
7676 echo "$as_me:7676: \$? = $ac_status" >&5
7677 (exit $ac_status); } &&
7678 { ac_try='test -s conftest.$ac_objext'
7679 { (eval echo "$as_me:7679: \"$ac_try\"") >&5
7682 echo "$as_me:7682: \$? = $ac_status" >&5
7683 (exit $ac_status); }; }; then
7686 echo "$as_me: failed program was:" >&5
7687 cat conftest.$ac_ext >&5
7690 rm -f conftest.$ac_objext conftest.$ac_ext
7691 CPPFLAGS=$cf_save_CPPFLAGS
7696 if test "$cf_have_incdir" = no ; then
7697 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
7699 echo "${as_me:-configure}:7699: testing adding $cf_add_incdir to include-path ..." 1>&5
7701 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7703 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
7704 test "$cf_top_incdir" = "$cf_add_incdir" && break
7705 cf_add_incdir="$cf_top_incdir"
7714 if test -n "$cf_cv_library_path_utf8" ; then
7715 for cf_add_libdir in $cf_cv_library_path_utf8
7717 if test $cf_add_libdir = /usr/lib ; then
7719 elif test -d $cf_add_libdir
7722 if test -n "$LDFLAGS$LIBS" ; then
7723 # a loop is needed to ensure we can add subdirs of existing dirs
7724 for cf_test_libdir in $LDFLAGS $LIBS ; do
7725 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
7726 cf_have_libdir=yes; break
7730 if test "$cf_have_libdir" = no ; then
7731 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
7733 echo "${as_me:-configure}:7733: testing adding $cf_add_libdir to library-path ..." 1>&5
7735 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
7741 LIBS="$cf_cv_library_file_utf8 $LIBS"
7744 cf_ncuconfig_root=ncursesw
7746 echo "Looking for ${cf_ncuconfig_root}-config"
7747 for ac_prog in ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
7749 # Extract the first word of "$ac_prog", so it can be a program name with args.
7750 set dummy $ac_prog; ac_word=$2
7751 echo "$as_me:7751: checking for $ac_word" >&5
7752 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7753 if test "${ac_cv_path_NCURSES_CONFIG+set}" = set; then
7754 echo $ECHO_N "(cached) $ECHO_C" >&6
7756 case $NCURSES_CONFIG in
7758 ac_cv_path_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test with a path.
7761 ac_save_IFS=$IFS; IFS=$ac_path_separator
7763 for ac_dir in $ac_dummy; do
7765 test -z "$ac_dir" && ac_dir=.
7766 if $as_executable_p "$ac_dir/$ac_word"; then
7767 ac_cv_path_NCURSES_CONFIG="$ac_dir/$ac_word"
7768 echo "$as_me:7768: found $ac_dir/$ac_word" >&5
7776 NCURSES_CONFIG=$ac_cv_path_NCURSES_CONFIG
7778 if test -n "$NCURSES_CONFIG"; then
7779 echo "$as_me:7779: result: $NCURSES_CONFIG" >&5
7780 echo "${ECHO_T}$NCURSES_CONFIG" >&6
7782 echo "$as_me:7782: result: no" >&5
7783 echo "${ECHO_T}no" >&6
7786 test -n "$NCURSES_CONFIG" && break
7788 test -n "$NCURSES_CONFIG" || NCURSES_CONFIG="none"
7790 if test "$NCURSES_CONFIG" != none ; then
7792 CPPFLAGS="$CPPFLAGS `$NCURSES_CONFIG --cflags`"
7793 LIBS="`$NCURSES_CONFIG --libs` $LIBS"
7795 # even with config script, some packages use no-override for curses.h
7797 echo "$as_me:7797: checking if we have identified curses headers" >&5
7798 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
7799 if test "${cf_cv_ncurses_header+set}" = set; then
7800 echo $ECHO_N "(cached) $ECHO_C" >&6
7803 cf_cv_ncurses_header=none
7806 ncursesw/ncurses.h \
7810 cat >conftest.$ac_ext <<_ACEOF
7811 #line 7811 "configure"
7812 #include "confdefs.h"
7813 #include <${cf_header}>
7817 initscr(); tgoto("?", 0,0)
7822 rm -f conftest.$ac_objext
7823 if { (eval echo "$as_me:7823: \"$ac_compile\"") >&5
7824 (eval $ac_compile) 2>&5
7826 echo "$as_me:7826: \$? = $ac_status" >&5
7827 (exit $ac_status); } &&
7828 { ac_try='test -s conftest.$ac_objext'
7829 { (eval echo "$as_me:7829: \"$ac_try\"") >&5
7832 echo "$as_me:7832: \$? = $ac_status" >&5
7833 (exit $ac_status); }; }; then
7834 cf_cv_ncurses_header=$cf_header; break
7836 echo "$as_me: failed program was:" >&5
7837 cat conftest.$ac_ext >&5
7839 rm -f conftest.$ac_objext conftest.$ac_ext
7843 echo "$as_me:7843: result: $cf_cv_ncurses_header" >&5
7844 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
7846 if test "$cf_cv_ncurses_header" = none ; then
7847 { { echo "$as_me:7847: error: No curses header-files found" >&5
7848 echo "$as_me: error: No curses header-files found" >&2;}
7849 { (exit 1); exit 1; }; }
7852 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
7854 for ac_header in $cf_cv_ncurses_header
7856 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7857 echo "$as_me:7857: checking for $ac_header" >&5
7858 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7859 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7860 echo $ECHO_N "(cached) $ECHO_C" >&6
7862 cat >conftest.$ac_ext <<_ACEOF
7863 #line 7863 "configure"
7864 #include "confdefs.h"
7865 #include <$ac_header>
7867 if { (eval echo "$as_me:7867: \"$ac_cpp conftest.$ac_ext\"") >&5
7868 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7870 egrep -v '^ *\+' conftest.er1 >conftest.err
7872 cat conftest.err >&5
7873 echo "$as_me:7873: \$? = $ac_status" >&5
7874 (exit $ac_status); } >/dev/null; then
7875 if test -s conftest.err; then
7876 ac_cpp_err=$ac_c_preproc_warn_flag
7883 if test -z "$ac_cpp_err"; then
7884 eval "$as_ac_Header=yes"
7886 echo "$as_me: failed program was:" >&5
7887 cat conftest.$ac_ext >&5
7888 eval "$as_ac_Header=no"
7890 rm -f conftest.err conftest.$ac_ext
7892 echo "$as_me:7892: result: `eval echo '${'$as_ac_Header'}'`" >&5
7893 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7894 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7895 cat >>confdefs.h <<EOF
7896 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7902 cat >>confdefs.h <<\EOF
7906 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
7908 cat >>confdefs.h <<EOF
7909 #define $cf_nculib_ROOT 1
7912 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
7916 cf_ncuhdr_root=ncursesw
7918 test -n "$cf_cv_curses_dir" && \
7919 test "$cf_cv_curses_dir" != "no" && { \
7921 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
7922 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
7924 while test $cf_add_incdir != /usr/include
7926 if test -d $cf_add_incdir
7929 if test -n "$CFLAGS$CPPFLAGS" ; then
7930 # a loop is needed to ensure we can add subdirs of existing dirs
7931 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
7932 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
7933 cf_have_incdir=yes; break
7938 if test "$cf_have_incdir" = no ; then
7939 if test "$cf_add_incdir" = /usr/local/include ; then
7940 if test "$GCC" = yes
7942 cf_save_CPPFLAGS=$CPPFLAGS
7943 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7944 cat >conftest.$ac_ext <<_ACEOF
7945 #line 7945 "configure"
7946 #include "confdefs.h"
7956 rm -f conftest.$ac_objext
7957 if { (eval echo "$as_me:7957: \"$ac_compile\"") >&5
7958 (eval $ac_compile) 2>&5
7960 echo "$as_me:7960: \$? = $ac_status" >&5
7961 (exit $ac_status); } &&
7962 { ac_try='test -s conftest.$ac_objext'
7963 { (eval echo "$as_me:7963: \"$ac_try\"") >&5
7966 echo "$as_me:7966: \$? = $ac_status" >&5
7967 (exit $ac_status); }; }; then
7970 echo "$as_me: failed program was:" >&5
7971 cat conftest.$ac_ext >&5
7974 rm -f conftest.$ac_objext conftest.$ac_ext
7975 CPPFLAGS=$cf_save_CPPFLAGS
7980 if test "$cf_have_incdir" = no ; then
7981 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
7983 echo "${as_me:-configure}:7983: testing adding $cf_add_incdir to include-path ..." 1>&5
7985 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7987 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
7988 test "$cf_top_incdir" = "$cf_add_incdir" && break
7989 cf_add_incdir="$cf_top_incdir"
8000 echo "$as_me:8000: checking for $cf_ncuhdr_root header in include-path" >&5
8001 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
8002 if test "${cf_cv_ncurses_h+set}" = set; then
8003 echo $ECHO_N "(cached) $ECHO_C" >&6
8006 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
8007 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
8008 for cf_header in $cf_header_list
8011 cat >conftest.$ac_ext <<_ACEOF
8012 #line 8012 "configure"
8013 #include "confdefs.h"
8015 #define _XOPEN_SOURCE_EXTENDED
8016 #undef HAVE_LIBUTF8_H /* in case we used CF_UTF8_LIB */
8017 #define HAVE_LIBUTF8_H /* to force ncurses' header file to use cchar_t */
8019 #include <$cf_header>
8024 #ifdef NCURSES_VERSION
8030 printf("%s\n", NCURSES_VERSION);
8043 rm -f conftest.$ac_objext
8044 if { (eval echo "$as_me:8044: \"$ac_compile\"") >&5
8045 (eval $ac_compile) 2>&5
8047 echo "$as_me:8047: \$? = $ac_status" >&5
8048 (exit $ac_status); } &&
8049 { ac_try='test -s conftest.$ac_objext'
8050 { (eval echo "$as_me:8050: \"$ac_try\"") >&5
8053 echo "$as_me:8053: \$? = $ac_status" >&5
8054 (exit $ac_status); }; }; then
8055 cf_cv_ncurses_h=$cf_header
8058 echo "$as_me: failed program was:" >&5
8059 cat conftest.$ac_ext >&5
8062 rm -f conftest.$ac_objext conftest.$ac_ext
8064 test "$cf_cv_ncurses_h" != no && break
8068 echo "$as_me:8068: result: $cf_cv_ncurses_h" >&5
8069 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
8071 if test "$cf_cv_ncurses_h" != no ; then
8072 cf_cv_ncurses_header=$cf_cv_ncurses_h
8075 echo "$as_me:8075: checking for $cf_ncuhdr_root include-path" >&5
8076 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
8077 if test "${cf_cv_ncurses_h2+set}" = set; then
8078 echo $ECHO_N "(cached) $ECHO_C" >&6
8081 test -n "$verbose" && echo
8085 # collect the current set of include-directories from compiler flags
8086 cf_header_path_list=""
8087 if test -n "${CFLAGS}${CPPFLAGS}" ; then
8088 for cf_header_path in $CPPFLAGS $CFLAGS
8090 case $cf_header_path in #(vi
8092 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
8094 test "$cf_header_path" != "NONE" && \
8095 test -d "$cf_header_path" && \
8097 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
8098 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
8099 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
8100 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
8101 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
8102 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"
8105 cf_header_path_list="$cf_header_path_list $cf_search"
8111 # add the variations for the package we are looking for
8115 test "/usr" != "$prefix" && \
8117 (test $prefix = NONE || test "/usr" != "$prefix") && {
8118 test -n "$verbose" && echo " ... testing for include-directories under /usr"
8119 test -d /usr/include && cf_search="$cf_search /usr/include"
8120 test -d /usr/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/include/$cf_ncuhdr_root"
8121 test -d /usr/include/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/include/$cf_ncuhdr_root/include"
8122 test -d /usr/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/$cf_ncuhdr_root/include"
8123 test -d /usr/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
8126 test "$prefix" != "NONE" && \
8127 test -d "$prefix" && \
8129 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
8130 test -d $prefix/include && cf_search="$cf_search $prefix/include"
8131 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
8132 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
8133 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
8134 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
8137 test "/usr/local" != "$prefix" && \
8138 test -d "/usr/local" && \
8139 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
8140 test -n "$verbose" && echo " ... testing for include-directories under /usr/local"
8141 test -d /usr/local/include && cf_search="$cf_search /usr/local/include"
8142 test -d /usr/local/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/local/include/$cf_ncuhdr_root"
8143 test -d /usr/local/include/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/local/include/$cf_ncuhdr_root/include"
8144 test -d /usr/local/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/local/$cf_ncuhdr_root/include"
8145 test -d /usr/local/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/local/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
8148 test "/opt" != "$prefix" && \
8150 (test $prefix = NONE || test "/opt" != "$prefix") && {
8151 test -n "$verbose" && echo " ... testing for include-directories under /opt"
8152 test -d /opt/include && cf_search="$cf_search /opt/include"
8153 test -d /opt/include/$cf_ncuhdr_root && cf_search="$cf_search /opt/include/$cf_ncuhdr_root"
8154 test -d /opt/include/$cf_ncuhdr_root/include && cf_search="$cf_search /opt/include/$cf_ncuhdr_root/include"
8155 test -d /opt/$cf_ncuhdr_root/include && cf_search="$cf_search /opt/$cf_ncuhdr_root/include"
8156 test -d /opt/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /opt/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
8159 test "$HOME" != "$prefix" && \
8160 test -d "$HOME" && \
8161 (test $prefix = NONE || test "$HOME" != "$prefix") && {
8162 test -n "$verbose" && echo " ... testing for include-directories under $HOME"
8163 test -d $HOME/include && cf_search="$cf_search $HOME/include"
8164 test -d $HOME/include/$cf_ncuhdr_root && cf_search="$cf_search $HOME/include/$cf_ncuhdr_root"
8165 test -d $HOME/include/$cf_ncuhdr_root/include && cf_search="$cf_search $HOME/include/$cf_ncuhdr_root/include"
8166 test -d $HOME/$cf_ncuhdr_root/include && cf_search="$cf_search $HOME/$cf_ncuhdr_root/include"
8167 test -d $HOME/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $HOME/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
8170 test "$includedir" != NONE && \
8171 test "$includedir" != "/usr/include" && \
8172 test -d "$includedir" && {
8173 test -d $includedir && cf_search="$cf_search $includedir"
8174 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
8177 test "$oldincludedir" != NONE && \
8178 test "$oldincludedir" != "/usr/include" && \
8179 test -d "$oldincludedir" && {
8180 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
8181 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
8184 cf_search="$cf_search $cf_header_path_list"
8186 test -n "$verbose" && echo search path $cf_search
8187 cf_save2_CPPFLAGS="$CPPFLAGS"
8188 for cf_incdir in $cf_search
8191 if test -n "$cf_incdir" ; then
8192 for cf_add_incdir in $cf_incdir
8194 while test $cf_add_incdir != /usr/include
8196 if test -d $cf_add_incdir
8199 if test -n "$CFLAGS$CPPFLAGS" ; then
8200 # a loop is needed to ensure we can add subdirs of existing dirs
8201 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
8202 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
8203 cf_have_incdir=yes; break
8208 if test "$cf_have_incdir" = no ; then
8209 if test "$cf_add_incdir" = /usr/local/include ; then
8210 if test "$GCC" = yes
8212 cf_save_CPPFLAGS=$CPPFLAGS
8213 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8214 cat >conftest.$ac_ext <<_ACEOF
8215 #line 8215 "configure"
8216 #include "confdefs.h"
8226 rm -f conftest.$ac_objext
8227 if { (eval echo "$as_me:8227: \"$ac_compile\"") >&5
8228 (eval $ac_compile) 2>&5
8230 echo "$as_me:8230: \$? = $ac_status" >&5
8231 (exit $ac_status); } &&
8232 { ac_try='test -s conftest.$ac_objext'
8233 { (eval echo "$as_me:8233: \"$ac_try\"") >&5
8236 echo "$as_me:8236: \$? = $ac_status" >&5
8237 (exit $ac_status); }; }; then
8240 echo "$as_me: failed program was:" >&5
8241 cat conftest.$ac_ext >&5
8244 rm -f conftest.$ac_objext conftest.$ac_ext
8245 CPPFLAGS=$cf_save_CPPFLAGS
8250 if test "$cf_have_incdir" = no ; then
8251 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
8253 echo "${as_me:-configure}:8253: testing adding $cf_add_incdir to include-path ..." 1>&5
8255 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8257 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
8258 test "$cf_top_incdir" = "$cf_add_incdir" && break
8259 cf_add_incdir="$cf_top_incdir"
8273 cat >conftest.$ac_ext <<_ACEOF
8274 #line 8274 "configure"
8275 #include "confdefs.h"
8277 #include <$cf_header>
8282 #ifdef NCURSES_VERSION
8284 printf("%s\n", NCURSES_VERSION);
8297 rm -f conftest.$ac_objext
8298 if { (eval echo "$as_me:8298: \"$ac_compile\"") >&5
8299 (eval $ac_compile) 2>&5
8301 echo "$as_me:8301: \$? = $ac_status" >&5
8302 (exit $ac_status); } &&
8303 { ac_try='test -s conftest.$ac_objext'
8304 { (eval echo "$as_me:8304: \"$ac_try\"") >&5
8307 echo "$as_me:8307: \$? = $ac_status" >&5
8308 (exit $ac_status); }; }; then
8309 cf_cv_ncurses_h2=$cf_header
8312 echo "$as_me: failed program was:" >&5
8313 cat conftest.$ac_ext >&5
8316 rm -f conftest.$ac_objext conftest.$ac_ext
8318 if test "$cf_cv_ncurses_h2" != no ; then
8319 cf_cv_ncurses_h2=$cf_incdir/$cf_header
8320 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
8323 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
8325 CPPFLAGS="$cf_save2_CPPFLAGS"
8326 test "$cf_cv_ncurses_h2" != no && break
8328 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:8328: error: not found" >&5
8329 echo "$as_me: error: not found" >&2;}
8330 { (exit 1); exit 1; }; }
8333 echo "$as_me:8333: result: $cf_cv_ncurses_h2" >&5
8334 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
8336 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
8337 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
8338 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
8339 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
8342 if test -n "$cf_1st_incdir" ; then
8343 for cf_add_incdir in $cf_1st_incdir
8345 while test $cf_add_incdir != /usr/include
8347 if test -d $cf_add_incdir
8350 if test -n "$CFLAGS$CPPFLAGS" ; then
8351 # a loop is needed to ensure we can add subdirs of existing dirs
8352 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
8353 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
8354 cf_have_incdir=yes; break
8359 if test "$cf_have_incdir" = no ; then
8360 if test "$cf_add_incdir" = /usr/local/include ; then
8361 if test "$GCC" = yes
8363 cf_save_CPPFLAGS=$CPPFLAGS
8364 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8365 cat >conftest.$ac_ext <<_ACEOF
8366 #line 8366 "configure"
8367 #include "confdefs.h"
8377 rm -f conftest.$ac_objext
8378 if { (eval echo "$as_me:8378: \"$ac_compile\"") >&5
8379 (eval $ac_compile) 2>&5
8381 echo "$as_me:8381: \$? = $ac_status" >&5
8382 (exit $ac_status); } &&
8383 { ac_try='test -s conftest.$ac_objext'
8384 { (eval echo "$as_me:8384: \"$ac_try\"") >&5
8387 echo "$as_me:8387: \$? = $ac_status" >&5
8388 (exit $ac_status); }; }; then
8391 echo "$as_me: failed program was:" >&5
8392 cat conftest.$ac_ext >&5
8395 rm -f conftest.$ac_objext conftest.$ac_ext
8396 CPPFLAGS=$cf_save_CPPFLAGS
8401 if test "$cf_have_incdir" = no ; then
8402 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
8404 echo "${as_me:-configure}:8404: testing adding $cf_add_incdir to include-path ..." 1>&5
8406 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8408 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
8409 test "$cf_top_incdir" = "$cf_add_incdir" && break
8410 cf_add_incdir="$cf_top_incdir"
8421 # Set definitions to allow ifdef'ing for ncurses.h
8423 case $cf_cv_ncurses_header in # (vi
8425 cat >>confdefs.h <<\EOF
8426 #define HAVE_NCURSES_H 1
8432 case $cf_cv_ncurses_header in # (vi
8433 ncurses/curses.h|ncurses/ncurses.h)
8434 cat >>confdefs.h <<\EOF
8435 #define HAVE_NCURSES_NCURSES_H 1
8439 ncursesw/curses.h|ncursesw/ncurses.h)
8440 cat >>confdefs.h <<\EOF
8441 #define HAVE_NCURSESW_NCURSES_H 1
8447 echo "$as_me:8447: checking for terminfo header" >&5
8448 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
8449 if test "${cf_cv_term_header+set}" = set; then
8450 echo $ECHO_N "(cached) $ECHO_C" >&6
8453 case ${cf_cv_ncurses_header} in #(vi
8454 */ncurses.h|*/ncursesw.h) #(vi
8455 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
8458 cf_term_header=term.h
8462 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
8464 cat >conftest.$ac_ext <<_ACEOF
8465 #line 8465 "configure"
8466 #include "confdefs.h"
8468 #include <${cf_cv_ncurses_header:-curses.h}>
8474 int x = auto_left_margin
8479 rm -f conftest.$ac_objext
8480 if { (eval echo "$as_me:8480: \"$ac_compile\"") >&5
8481 (eval $ac_compile) 2>&5
8483 echo "$as_me:8483: \$? = $ac_status" >&5
8484 (exit $ac_status); } &&
8485 { ac_try='test -s conftest.$ac_objext'
8486 { (eval echo "$as_me:8486: \"$ac_try\"") >&5
8489 echo "$as_me:8489: \$? = $ac_status" >&5
8490 (exit $ac_status); }; }; then
8492 cf_cv_term_header="$cf_test"
8494 echo "$as_me: failed program was:" >&5
8495 cat conftest.$ac_ext >&5
8497 cf_cv_term_header=unknown
8500 rm -f conftest.$ac_objext conftest.$ac_ext
8501 test "$cf_cv_term_header" != unknown && break
8505 echo "$as_me:8505: result: $cf_cv_term_header" >&5
8506 echo "${ECHO_T}$cf_cv_term_header" >&6
8508 # Set definitions to allow ifdef'ing to accommodate subdirectories
8510 case $cf_cv_term_header in # (vi
8512 cat >>confdefs.h <<\EOF
8513 #define HAVE_TERM_H 1
8519 case $cf_cv_term_header in # (vi
8520 ncurses/term.h) #(vi
8521 cat >>confdefs.h <<\EOF
8522 #define HAVE_NCURSES_TERM_H 1
8527 cat >>confdefs.h <<\EOF
8528 #define HAVE_NCURSESW_TERM_H 1
8534 # some applications need this, but should check for NCURSES_VERSION
8535 cat >>confdefs.h <<\EOF
8539 echo "$as_me:8539: checking for ncurses version" >&5
8540 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
8541 if test "${cf_cv_ncurses_version+set}" = set; then
8542 echo $ECHO_N "(cached) $ECHO_C" >&6
8545 cf_cv_ncurses_version=no
8548 if test "$cross_compiling" = yes; then
8550 # This will not work if the preprocessor splits the line after the
8551 # Autoconf token. The 'unproto' program does that.
8552 cat > conftest.$ac_ext <<EOF
8553 #include <${cf_cv_ncurses_header:-curses.h}>
8555 #ifdef NCURSES_VERSION
8556 Autoconf NCURSES_VERSION
8564 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
8565 { (eval echo "$as_me:8565: \"$cf_try\"") >&5
8568 echo "$as_me:8568: \$? = $ac_status" >&5
8569 (exit $ac_status); }
8570 if test -f conftest.out ; then
8571 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
8572 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
8577 cat >conftest.$ac_ext <<_ACEOF
8578 #line 8578 "configure"
8579 #include "confdefs.h"
8581 #include <${cf_cv_ncurses_header:-curses.h}>
8585 FILE *fp = fopen("$cf_tempfile", "w");
8586 #ifdef NCURSES_VERSION
8587 # ifdef NCURSES_VERSION_PATCH
8588 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
8590 fprintf(fp, "%s\n", NCURSES_VERSION);
8594 fprintf(fp, "old\n");
8599 ${cf_cv_main_return:-return}(0);
8602 rm -f conftest$ac_exeext
8603 if { (eval echo "$as_me:8603: \"$ac_link\"") >&5
8604 (eval $ac_link) 2>&5
8606 echo "$as_me:8606: \$? = $ac_status" >&5
8607 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
8608 { (eval echo "$as_me:8608: \"$ac_try\"") >&5
8611 echo "$as_me:8611: \$? = $ac_status" >&5
8612 (exit $ac_status); }; }; then
8614 cf_cv_ncurses_version=`cat $cf_tempfile`
8616 echo "$as_me: program exited with status $ac_status" >&5
8617 echo "$as_me: failed program was:" >&5
8618 cat conftest.$ac_ext >&5
8620 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
8625 echo "$as_me:8625: result: $cf_cv_ncurses_version" >&5
8626 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
8627 test "$cf_cv_ncurses_version" = no || cat >>confdefs.h <<\EOF
8631 cf_nculib_root=ncursesw
8632 # This works, except for the special case where we find gpm, but
8633 # ncurses is in a nonstandard location via $LIBS, and we really want
8636 cf_ncurses_SAVE="$LIBS"
8637 echo "$as_me:8637: checking for Gpm_Open in -lgpm" >&5
8638 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
8639 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
8640 echo $ECHO_N "(cached) $ECHO_C" >&6
8642 ac_check_lib_save_LIBS=$LIBS
8644 cat >conftest.$ac_ext <<_ACEOF
8645 #line 8645 "configure"
8646 #include "confdefs.h"
8648 /* Override any gcc2 internal prototype to avoid an error. */
8652 /* We use char because int might match the return type of a gcc2
8653 builtin and then its argument prototype would still apply. */
8663 rm -f conftest.$ac_objext conftest$ac_exeext
8664 if { (eval echo "$as_me:8664: \"$ac_link\"") >&5
8665 (eval $ac_link) 2>&5
8667 echo "$as_me:8667: \$? = $ac_status" >&5
8668 (exit $ac_status); } &&
8669 { ac_try='test -s conftest$ac_exeext'
8670 { (eval echo "$as_me:8670: \"$ac_try\"") >&5
8673 echo "$as_me:8673: \$? = $ac_status" >&5
8674 (exit $ac_status); }; }; then
8675 ac_cv_lib_gpm_Gpm_Open=yes
8677 echo "$as_me: failed program was:" >&5
8678 cat conftest.$ac_ext >&5
8679 ac_cv_lib_gpm_Gpm_Open=no
8681 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8682 LIBS=$ac_check_lib_save_LIBS
8684 echo "$as_me:8684: result: $ac_cv_lib_gpm_Gpm_Open" >&5
8685 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
8686 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
8687 echo "$as_me:8687: checking for initscr in -lgpm" >&5
8688 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
8689 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
8690 echo $ECHO_N "(cached) $ECHO_C" >&6
8692 ac_check_lib_save_LIBS=$LIBS
8694 cat >conftest.$ac_ext <<_ACEOF
8695 #line 8695 "configure"
8696 #include "confdefs.h"
8698 /* Override any gcc2 internal prototype to avoid an error. */
8702 /* We use char because int might match the return type of a gcc2
8703 builtin and then its argument prototype would still apply. */
8713 rm -f conftest.$ac_objext conftest$ac_exeext
8714 if { (eval echo "$as_me:8714: \"$ac_link\"") >&5
8715 (eval $ac_link) 2>&5
8717 echo "$as_me:8717: \$? = $ac_status" >&5
8718 (exit $ac_status); } &&
8719 { ac_try='test -s conftest$ac_exeext'
8720 { (eval echo "$as_me:8720: \"$ac_try\"") >&5
8723 echo "$as_me:8723: \$? = $ac_status" >&5
8724 (exit $ac_status); }; }; then
8725 ac_cv_lib_gpm_initscr=yes
8727 echo "$as_me: failed program was:" >&5
8728 cat conftest.$ac_ext >&5
8729 ac_cv_lib_gpm_initscr=no
8731 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8732 LIBS=$ac_check_lib_save_LIBS
8734 echo "$as_me:8734: result: $ac_cv_lib_gpm_initscr" >&5
8735 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
8736 if test $ac_cv_lib_gpm_initscr = yes; then
8737 LIBS="$cf_ncurses_SAVE"
8739 cf_ncurses_LIBS="-lgpm"
8744 case $host_os in #(vi
8746 # This is only necessary if you are linking against an obsolete
8747 # version of ncurses (but it should do no harm, since it's static).
8748 if test "$cf_nculib_root" = ncurses ; then
8749 echo "$as_me:8749: checking for tgoto in -lmytinfo" >&5
8750 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
8751 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
8752 echo $ECHO_N "(cached) $ECHO_C" >&6
8754 ac_check_lib_save_LIBS=$LIBS
8755 LIBS="-lmytinfo $LIBS"
8756 cat >conftest.$ac_ext <<_ACEOF
8757 #line 8757 "configure"
8758 #include "confdefs.h"
8760 /* Override any gcc2 internal prototype to avoid an error. */
8764 /* We use char because int might match the return type of a gcc2
8765 builtin and then its argument prototype would still apply. */
8775 rm -f conftest.$ac_objext conftest$ac_exeext
8776 if { (eval echo "$as_me:8776: \"$ac_link\"") >&5
8777 (eval $ac_link) 2>&5
8779 echo "$as_me:8779: \$? = $ac_status" >&5
8780 (exit $ac_status); } &&
8781 { ac_try='test -s conftest$ac_exeext'
8782 { (eval echo "$as_me:8782: \"$ac_try\"") >&5
8785 echo "$as_me:8785: \$? = $ac_status" >&5
8786 (exit $ac_status); }; }; then
8787 ac_cv_lib_mytinfo_tgoto=yes
8789 echo "$as_me: failed program was:" >&5
8790 cat conftest.$ac_ext >&5
8791 ac_cv_lib_mytinfo_tgoto=no
8793 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8794 LIBS=$ac_check_lib_save_LIBS
8796 echo "$as_me:8796: result: $ac_cv_lib_mytinfo_tgoto" >&5
8797 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
8798 if test $ac_cv_lib_mytinfo_tgoto = yes; then
8799 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
8806 LIBS="$cf_ncurses_LIBS $LIBS"
8808 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
8810 LIBS="-l$cf_nculib_root $LIBS"
8813 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
8815 echo "$as_me:8815: checking for initscr" >&5
8816 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
8817 if test "${ac_cv_func_initscr+set}" = set; then
8818 echo $ECHO_N "(cached) $ECHO_C" >&6
8820 cat >conftest.$ac_ext <<_ACEOF
8821 #line 8821 "configure"
8822 #include "confdefs.h"
8823 /* System header to define __stub macros and hopefully few prototypes,
8824 which can conflict with char initscr (); below. */
8826 /* Override any gcc2 internal prototype to avoid an error. */
8830 /* We use char because int might match the return type of a gcc2
8831 builtin and then its argument prototype would still apply. */
8838 /* The GNU C library defines this for functions which it implements
8839 to always fail with ENOSYS. Some functions are actually named
8840 something starting with __ and the normal name is an alias. */
8841 #if defined (__stub_initscr) || defined (__stub___initscr)
8851 rm -f conftest.$ac_objext conftest$ac_exeext
8852 if { (eval echo "$as_me:8852: \"$ac_link\"") >&5
8853 (eval $ac_link) 2>&5
8855 echo "$as_me:8855: \$? = $ac_status" >&5
8856 (exit $ac_status); } &&
8857 { ac_try='test -s conftest$ac_exeext'
8858 { (eval echo "$as_me:8858: \"$ac_try\"") >&5
8861 echo "$as_me:8861: \$? = $ac_status" >&5
8862 (exit $ac_status); }; }; then
8863 ac_cv_func_initscr=yes
8865 echo "$as_me: failed program was:" >&5
8866 cat conftest.$ac_ext >&5
8867 ac_cv_func_initscr=no
8869 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8871 echo "$as_me:8871: result: $ac_cv_func_initscr" >&5
8872 echo "${ECHO_T}$ac_cv_func_initscr" >&6
8873 if test $ac_cv_func_initscr = yes; then
8874 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
8877 cf_save_LIBS="$LIBS"
8878 echo "$as_me:8878: checking for initscr in -l$cf_nculib_root" >&5
8879 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
8880 LIBS="-l$cf_nculib_root $LIBS"
8881 cat >conftest.$ac_ext <<_ACEOF
8882 #line 8882 "configure"
8883 #include "confdefs.h"
8884 #include <${cf_cv_ncurses_header:-curses.h}>
8893 rm -f conftest.$ac_objext conftest$ac_exeext
8894 if { (eval echo "$as_me:8894: \"$ac_link\"") >&5
8895 (eval $ac_link) 2>&5
8897 echo "$as_me:8897: \$? = $ac_status" >&5
8898 (exit $ac_status); } &&
8899 { ac_try='test -s conftest$ac_exeext'
8900 { (eval echo "$as_me:8900: \"$ac_try\"") >&5
8903 echo "$as_me:8903: \$? = $ac_status" >&5
8904 (exit $ac_status); }; }; then
8905 echo "$as_me:8905: result: yes" >&5
8906 echo "${ECHO_T}yes" >&6
8907 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
8910 echo "$as_me: failed program was:" >&5
8911 cat conftest.$ac_ext >&5
8912 echo "$as_me:8912: result: no" >&5
8913 echo "${ECHO_T}no" >&6
8916 cf_library_path_list=""
8917 if test -n "${LDFLAGS}${LIBS}" ; then
8918 for cf_library_path in $LDFLAGS $LIBS
8920 case $cf_library_path in #(vi
8922 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
8924 test "$cf_library_path" != "NONE" && \
8925 test -d "$cf_library_path" && \
8927 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
8928 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
8929 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
8930 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
8931 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
8932 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"
8935 cf_library_path_list="$cf_library_path_list $cf_search"
8943 test "/usr" != "$prefix" && \
8945 (test $prefix = NONE || test "/usr" != "$prefix") && {
8946 test -n "$verbose" && echo " ... testing for lib-directories under /usr"
8947 test -d /usr/lib && cf_search="$cf_search /usr/lib"
8948 test -d /usr/lib/$cf_nculib_root && cf_search="$cf_search /usr/lib/$cf_nculib_root"
8949 test -d /usr/lib/$cf_nculib_root/lib && cf_search="$cf_search /usr/lib/$cf_nculib_root/lib"
8950 test -d /usr/$cf_nculib_root/lib && cf_search="$cf_search /usr/$cf_nculib_root/lib"
8951 test -d /usr/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /usr/$cf_nculib_root/lib/$cf_nculib_root"
8954 test "$prefix" != "NONE" && \
8955 test -d "$prefix" && \
8957 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
8958 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
8959 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
8960 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
8961 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
8962 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
8965 test "/usr/local" != "$prefix" && \
8966 test -d "/usr/local" && \
8967 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
8968 test -n "$verbose" && echo " ... testing for lib-directories under /usr/local"
8969 test -d /usr/local/lib && cf_search="$cf_search /usr/local/lib"
8970 test -d /usr/local/lib/$cf_nculib_root && cf_search="$cf_search /usr/local/lib/$cf_nculib_root"
8971 test -d /usr/local/lib/$cf_nculib_root/lib && cf_search="$cf_search /usr/local/lib/$cf_nculib_root/lib"
8972 test -d /usr/local/$cf_nculib_root/lib && cf_search="$cf_search /usr/local/$cf_nculib_root/lib"
8973 test -d /usr/local/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /usr/local/$cf_nculib_root/lib/$cf_nculib_root"
8976 test "/opt" != "$prefix" && \
8978 (test $prefix = NONE || test "/opt" != "$prefix") && {
8979 test -n "$verbose" && echo " ... testing for lib-directories under /opt"
8980 test -d /opt/lib && cf_search="$cf_search /opt/lib"
8981 test -d /opt/lib/$cf_nculib_root && cf_search="$cf_search /opt/lib/$cf_nculib_root"
8982 test -d /opt/lib/$cf_nculib_root/lib && cf_search="$cf_search /opt/lib/$cf_nculib_root/lib"
8983 test -d /opt/$cf_nculib_root/lib && cf_search="$cf_search /opt/$cf_nculib_root/lib"
8984 test -d /opt/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /opt/$cf_nculib_root/lib/$cf_nculib_root"
8987 test "$HOME" != "$prefix" && \
8988 test -d "$HOME" && \
8989 (test $prefix = NONE || test "$HOME" != "$prefix") && {
8990 test -n "$verbose" && echo " ... testing for lib-directories under $HOME"
8991 test -d $HOME/lib && cf_search="$cf_search $HOME/lib"
8992 test -d $HOME/lib/$cf_nculib_root && cf_search="$cf_search $HOME/lib/$cf_nculib_root"
8993 test -d $HOME/lib/$cf_nculib_root/lib && cf_search="$cf_search $HOME/lib/$cf_nculib_root/lib"
8994 test -d $HOME/$cf_nculib_root/lib && cf_search="$cf_search $HOME/$cf_nculib_root/lib"
8995 test -d $HOME/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $HOME/$cf_nculib_root/lib/$cf_nculib_root"
8998 cf_search="$cf_library_path_list $cf_search"
9000 for cf_libdir in $cf_search
9002 echo "$as_me:9002: checking for -l$cf_nculib_root in $cf_libdir" >&5
9003 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
9004 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
9005 cat >conftest.$ac_ext <<_ACEOF
9006 #line 9006 "configure"
9007 #include "confdefs.h"
9008 #include <${cf_cv_ncurses_header:-curses.h}>
9017 rm -f conftest.$ac_objext conftest$ac_exeext
9018 if { (eval echo "$as_me:9018: \"$ac_link\"") >&5
9019 (eval $ac_link) 2>&5
9021 echo "$as_me:9021: \$? = $ac_status" >&5
9022 (exit $ac_status); } &&
9023 { ac_try='test -s conftest$ac_exeext'
9024 { (eval echo "$as_me:9024: \"$ac_try\"") >&5
9027 echo "$as_me:9027: \$? = $ac_status" >&5
9028 (exit $ac_status); }; }; then
9029 echo "$as_me:9029: result: yes" >&5
9030 echo "${ECHO_T}yes" >&6
9031 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
9034 echo "$as_me: failed program was:" >&5
9035 cat conftest.$ac_ext >&5
9036 echo "$as_me:9036: result: no" >&5
9037 echo "${ECHO_T}no" >&6
9038 LIBS="$cf_save_LIBS"
9040 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9044 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9048 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
9050 if test $cf_found_library = no ; then
9051 { { echo "$as_me:9051: error: Cannot link $cf_nculib_root library" >&5
9052 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
9053 { (exit 1); exit 1; }; }
9058 if test -n "$cf_ncurses_LIBS" ; then
9059 echo "$as_me:9059: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
9060 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
9061 cf_ncurses_SAVE="$LIBS"
9062 for p in $cf_ncurses_LIBS ; do
9063 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
9064 if test "$q" != "$LIBS" ; then
9068 cat >conftest.$ac_ext <<_ACEOF
9069 #line 9069 "configure"
9070 #include "confdefs.h"
9071 #include <${cf_cv_ncurses_header:-curses.h}>
9075 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
9080 rm -f conftest.$ac_objext conftest$ac_exeext
9081 if { (eval echo "$as_me:9081: \"$ac_link\"") >&5
9082 (eval $ac_link) 2>&5
9084 echo "$as_me:9084: \$? = $ac_status" >&5
9085 (exit $ac_status); } &&
9086 { ac_try='test -s conftest$ac_exeext'
9087 { (eval echo "$as_me:9087: \"$ac_try\"") >&5
9090 echo "$as_me:9090: \$? = $ac_status" >&5
9091 (exit $ac_status); }; }; then
9092 echo "$as_me:9092: result: yes" >&5
9093 echo "${ECHO_T}yes" >&6
9095 echo "$as_me: failed program was:" >&5
9096 cat conftest.$ac_ext >&5
9097 echo "$as_me:9097: result: no" >&5
9098 echo "${ECHO_T}no" >&6
9099 LIBS="$cf_ncurses_SAVE"
9101 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9104 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
9106 cat >>confdefs.h <<EOF
9107 #define $cf_nculib_ROOT 1
9115 echo "$as_me:9115: checking if you want to use pkg-config" >&5
9116 echo $ECHO_N "checking if you want to use pkg-config... $ECHO_C" >&6
9118 # Check whether --with-pkg-config or --without-pkg-config was given.
9119 if test "${with_pkg_config+set}" = set; then
9120 withval="$with_pkg_config"
9121 cf_pkg_config=$withval
9125 echo "$as_me:9125: result: $cf_pkg_config" >&5
9126 echo "${ECHO_T}$cf_pkg_config" >&6
9128 case $cf_pkg_config in #(vi
9133 # Extract the first word of "pkg-config", so it can be a program name with args.
9134 set dummy pkg-config; ac_word=$2
9135 echo "$as_me:9135: checking for $ac_word" >&5
9136 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
9137 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then
9138 echo $ECHO_N "(cached) $ECHO_C" >&6
9142 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
9145 ac_save_IFS=$IFS; IFS=$ac_path_separator
9147 for ac_dir in $ac_dummy; do
9149 test -z "$ac_dir" && ac_dir=.
9150 if $as_executable_p "$ac_dir/$ac_word"; then
9151 ac_cv_path_PKG_CONFIG="$ac_dir/$ac_word"
9152 echo "$as_me:9152: found $ac_dir/$ac_word" >&5
9157 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="none"
9161 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
9163 if test -n "$PKG_CONFIG"; then
9164 echo "$as_me:9164: result: $PKG_CONFIG" >&5
9165 echo "${ECHO_T}$PKG_CONFIG" >&6
9167 echo "$as_me:9167: result: no" >&5
9168 echo "${ECHO_T}no" >&6
9177 test -z "$PKG_CONFIG" && PKG_CONFIG=none
9178 if test "$PKG_CONFIG" != none ; then
9180 if test "x$prefix" != xNONE; then
9181 cf_path_syntax="$prefix"
9183 cf_path_syntax="$ac_default_prefix"
9186 case ".$PKG_CONFIG" in #(vi
9187 .\$\(*\)*|.\'*\'*) #(vi
9191 .[a-zA-Z]:[\\/]*) #(vi OS/2 EMX
9194 eval PKG_CONFIG="$PKG_CONFIG"
9195 case ".$PKG_CONFIG" in #(vi
9197 PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
9202 PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
9205 { { echo "$as_me:9205: error: expected a pathname, not \"$PKG_CONFIG\"" >&5
9206 echo "$as_me: error: expected a pathname, not \"$PKG_CONFIG\"" >&2;}
9207 { (exit 1); exit 1; }; }
9213 echo "$as_me:9213: checking for X" >&5
9214 echo $ECHO_N "checking for X... $ECHO_C" >&6
9216 # Check whether --with-x or --without-x was given.
9217 if test "${with_x+set}" = set; then
9221 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
9222 if test "x$with_x" = xno; then
9223 # The user explicitly disabled X.
9226 if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
9227 # Both variables are already set.
9230 if test "${ac_cv_have_x+set}" = set; then
9231 echo $ECHO_N "(cached) $ECHO_C" >&6
9233 # One or both of the vars are not set, and there is no cached value.
9234 ac_x_includes=no ac_x_libraries=no
9236 if mkdir conftest.dir; then
9238 # Make sure to not put "make" in the Imakefile rules, since we grep it out.
9239 cat >Imakefile <<'EOF'
9241 @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
9243 if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
9244 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
9245 eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
9246 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
9247 for ac_extension in a so sl dylib dll; do
9248 if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
9249 test -f $ac_im_libdir/libX11.$ac_extension; then
9250 ac_im_usrlibdir=$ac_im_libdir; break
9253 # Screen out bogus values from the imake configuration. They are
9254 # bogus both because they are the default anyway, and because
9255 # using them would break gcc on systems where it needs fixed includes.
9256 case $ac_im_incroot in
9258 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
9260 case $ac_im_usrlibdir in
9262 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
9269 # Standard set of common directories for X headers.
9270 # Check X11 before X11Rn because it is often a symlink to the current release.
9282 /usr/local/X11/include
9283 /usr/local/X11R6/include
9284 /usr/local/X11R5/include
9285 /usr/local/X11R4/include
9287 /usr/local/include/X11
9288 /usr/local/include/X11R6
9289 /usr/local/include/X11R5
9290 /usr/local/include/X11R4
9294 /usr/XFree86/include/X11
9298 /usr/unsupported/include
9300 /usr/local/x11r5/include
9301 /usr/lpp/Xamples/include
9303 /usr/openwin/include
9304 /usr/openwin/share/include'
9306 if test "$ac_x_includes" = no; then
9307 # Guess where to find include files, by looking for Intrinsic.h.
9308 # First, try using that file with no special directory specified.
9309 cat >conftest.$ac_ext <<_ACEOF
9310 #line 9310 "configure"
9311 #include "confdefs.h"
9312 #include <X11/Intrinsic.h>
9314 if { (eval echo "$as_me:9314: \"$ac_cpp conftest.$ac_ext\"") >&5
9315 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9317 egrep -v '^ *\+' conftest.er1 >conftest.err
9319 cat conftest.err >&5
9320 echo "$as_me:9320: \$? = $ac_status" >&5
9321 (exit $ac_status); } >/dev/null; then
9322 if test -s conftest.err; then
9323 ac_cpp_err=$ac_c_preproc_warn_flag
9330 if test -z "$ac_cpp_err"; then
9331 # We can compile using X headers with no special include directory.
9334 echo "$as_me: failed program was:" >&5
9335 cat conftest.$ac_ext >&5
9336 for ac_dir in $ac_x_header_dirs; do
9337 if test -r "$ac_dir/X11/Intrinsic.h"; then
9338 ac_x_includes=$ac_dir
9343 rm -f conftest.err conftest.$ac_ext
9344 fi # $ac_x_includes = no
9346 if test "$ac_x_libraries" = no; then
9347 # Check for the libraries.
9348 # See if we find them without any special options.
9349 # Don't add to $LIBS permanently.
9352 cat >conftest.$ac_ext <<_ACEOF
9353 #line 9353 "configure"
9354 #include "confdefs.h"
9355 #include <X11/Intrinsic.h>
9364 rm -f conftest.$ac_objext conftest$ac_exeext
9365 if { (eval echo "$as_me:9365: \"$ac_link\"") >&5
9366 (eval $ac_link) 2>&5
9368 echo "$as_me:9368: \$? = $ac_status" >&5
9369 (exit $ac_status); } &&
9370 { ac_try='test -s conftest$ac_exeext'
9371 { (eval echo "$as_me:9371: \"$ac_try\"") >&5
9374 echo "$as_me:9374: \$? = $ac_status" >&5
9375 (exit $ac_status); }; }; then
9377 # We can link X programs with no special library path.
9380 echo "$as_me: failed program was:" >&5
9381 cat conftest.$ac_ext >&5
9383 for ac_dir in `echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
9385 # Don't even attempt the hair of trying to link an X program!
9386 for ac_extension in a so sl dylib dll; do
9387 if test -r $ac_dir/libXt.$ac_extension; then
9388 ac_x_libraries=$ac_dir
9394 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9395 fi # $ac_x_libraries = no
9397 if test "$ac_x_includes" = no || test "$ac_x_libraries" = no; then
9398 # Didn't find X anywhere. Cache the known absence of X.
9399 ac_cv_have_x="have_x=no"
9401 # Record where we found X for the cache.
9402 ac_cv_have_x="have_x=yes \
9403 ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
9408 eval "$ac_cv_have_x"
9411 if test "$have_x" != yes; then
9412 echo "$as_me:9412: result: $have_x" >&5
9413 echo "${ECHO_T}$have_x" >&6
9416 # If each of the values was on the command line, it overrides each guess.
9417 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
9418 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
9419 # Update the cache value to reflect the command line values.
9420 ac_cv_have_x="have_x=yes \
9421 ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
9422 echo "$as_me:9422: result: libraries $x_libraries, headers $x_includes" >&5
9423 echo "${ECHO_T}libraries $x_libraries, headers $x_includes" >&6
9426 if test "$no_x" = yes; then
9427 # Not all programs may use this symbol, but it does not hurt to define it.
9429 cat >>confdefs.h <<\EOF
9430 #define X_DISPLAY_MISSING 1
9433 X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS=
9435 if test -n "$x_includes"; then
9436 X_CFLAGS="$X_CFLAGS -I$x_includes"
9439 # It would also be nice to do this for all -L options, not just this one.
9440 if test -n "$x_libraries"; then
9441 X_LIBS="$X_LIBS -L$x_libraries"
9442 # For Solaris; some versions of Sun CC require a space after -R and
9443 # others require no space. Words are not sufficient . . . .
9444 case `(uname -sr) 2>/dev/null` in
9446 echo "$as_me:9446: checking whether -R must be followed by a space" >&5
9447 echo $ECHO_N "checking whether -R must be followed by a space... $ECHO_C" >&6
9448 ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries"
9449 cat >conftest.$ac_ext <<_ACEOF
9450 #line 9450 "configure"
9451 #include "confdefs.h"
9461 rm -f conftest.$ac_objext conftest$ac_exeext
9462 if { (eval echo "$as_me:9462: \"$ac_link\"") >&5
9463 (eval $ac_link) 2>&5
9465 echo "$as_me:9465: \$? = $ac_status" >&5
9466 (exit $ac_status); } &&
9467 { ac_try='test -s conftest$ac_exeext'
9468 { (eval echo "$as_me:9468: \"$ac_try\"") >&5
9471 echo "$as_me:9471: \$? = $ac_status" >&5
9472 (exit $ac_status); }; }; then
9475 echo "$as_me: failed program was:" >&5
9476 cat conftest.$ac_ext >&5
9479 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9480 if test $ac_R_nospace = yes; then
9481 echo "$as_me:9481: result: no" >&5
9482 echo "${ECHO_T}no" >&6
9483 X_LIBS="$X_LIBS -R$x_libraries"
9485 LIBS="$ac_xsave_LIBS -R $x_libraries"
9486 cat >conftest.$ac_ext <<_ACEOF
9487 #line 9487 "configure"
9488 #include "confdefs.h"
9498 rm -f conftest.$ac_objext conftest$ac_exeext
9499 if { (eval echo "$as_me:9499: \"$ac_link\"") >&5
9500 (eval $ac_link) 2>&5
9502 echo "$as_me:9502: \$? = $ac_status" >&5
9503 (exit $ac_status); } &&
9504 { ac_try='test -s conftest$ac_exeext'
9505 { (eval echo "$as_me:9505: \"$ac_try\"") >&5
9508 echo "$as_me:9508: \$? = $ac_status" >&5
9509 (exit $ac_status); }; }; then
9512 echo "$as_me: failed program was:" >&5
9513 cat conftest.$ac_ext >&5
9516 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9517 if test $ac_R_space = yes; then
9518 echo "$as_me:9518: result: yes" >&5
9519 echo "${ECHO_T}yes" >&6
9520 X_LIBS="$X_LIBS -R $x_libraries"
9522 echo "$as_me:9522: result: neither works" >&5
9523 echo "${ECHO_T}neither works" >&6
9530 # Check for system-dependent libraries X programs must link with.
9531 # Do this before checking for the system-independent R6 libraries
9532 # (-lICE), since we may need -lsocket or whatever for X linking.
9534 if test "$ISC" = yes; then
9535 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
9537 # Martyn Johnson says this is needed for Ultrix, if the X
9538 # libraries were built with DECnet support. And Karl Berry says
9539 # the Alpha needs dnet_stub (dnet does not exist).
9540 ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11"
9541 cat >conftest.$ac_ext <<_ACEOF
9542 #line 9542 "configure"
9543 #include "confdefs.h"
9545 /* Override any gcc2 internal prototype to avoid an error. */
9549 /* We use char because int might match the return type of a gcc2
9550 builtin and then its argument prototype would still apply. */
9551 char XOpenDisplay ();
9560 rm -f conftest.$ac_objext conftest$ac_exeext
9561 if { (eval echo "$as_me:9561: \"$ac_link\"") >&5
9562 (eval $ac_link) 2>&5
9564 echo "$as_me:9564: \$? = $ac_status" >&5
9565 (exit $ac_status); } &&
9566 { ac_try='test -s conftest$ac_exeext'
9567 { (eval echo "$as_me:9567: \"$ac_try\"") >&5
9570 echo "$as_me:9570: \$? = $ac_status" >&5
9571 (exit $ac_status); }; }; then
9574 echo "$as_me: failed program was:" >&5
9575 cat conftest.$ac_ext >&5
9576 echo "$as_me:9576: checking for dnet_ntoa in -ldnet" >&5
9577 echo $ECHO_N "checking for dnet_ntoa in -ldnet... $ECHO_C" >&6
9578 if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then
9579 echo $ECHO_N "(cached) $ECHO_C" >&6
9581 ac_check_lib_save_LIBS=$LIBS
9583 cat >conftest.$ac_ext <<_ACEOF
9584 #line 9584 "configure"
9585 #include "confdefs.h"
9587 /* Override any gcc2 internal prototype to avoid an error. */
9591 /* We use char because int might match the return type of a gcc2
9592 builtin and then its argument prototype would still apply. */
9602 rm -f conftest.$ac_objext conftest$ac_exeext
9603 if { (eval echo "$as_me:9603: \"$ac_link\"") >&5
9604 (eval $ac_link) 2>&5
9606 echo "$as_me:9606: \$? = $ac_status" >&5
9607 (exit $ac_status); } &&
9608 { ac_try='test -s conftest$ac_exeext'
9609 { (eval echo "$as_me:9609: \"$ac_try\"") >&5
9612 echo "$as_me:9612: \$? = $ac_status" >&5
9613 (exit $ac_status); }; }; then
9614 ac_cv_lib_dnet_dnet_ntoa=yes
9616 echo "$as_me: failed program was:" >&5
9617 cat conftest.$ac_ext >&5
9618 ac_cv_lib_dnet_dnet_ntoa=no
9620 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9621 LIBS=$ac_check_lib_save_LIBS
9623 echo "$as_me:9623: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
9624 echo "${ECHO_T}$ac_cv_lib_dnet_dnet_ntoa" >&6
9625 if test $ac_cv_lib_dnet_dnet_ntoa = yes; then
9626 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
9629 if test $ac_cv_lib_dnet_dnet_ntoa = no; then
9630 echo "$as_me:9630: checking for dnet_ntoa in -ldnet_stub" >&5
9631 echo $ECHO_N "checking for dnet_ntoa in -ldnet_stub... $ECHO_C" >&6
9632 if test "${ac_cv_lib_dnet_stub_dnet_ntoa+set}" = set; then
9633 echo $ECHO_N "(cached) $ECHO_C" >&6
9635 ac_check_lib_save_LIBS=$LIBS
9636 LIBS="-ldnet_stub $LIBS"
9637 cat >conftest.$ac_ext <<_ACEOF
9638 #line 9638 "configure"
9639 #include "confdefs.h"
9641 /* Override any gcc2 internal prototype to avoid an error. */
9645 /* We use char because int might match the return type of a gcc2
9646 builtin and then its argument prototype would still apply. */
9656 rm -f conftest.$ac_objext conftest$ac_exeext
9657 if { (eval echo "$as_me:9657: \"$ac_link\"") >&5
9658 (eval $ac_link) 2>&5
9660 echo "$as_me:9660: \$? = $ac_status" >&5
9661 (exit $ac_status); } &&
9662 { ac_try='test -s conftest$ac_exeext'
9663 { (eval echo "$as_me:9663: \"$ac_try\"") >&5
9666 echo "$as_me:9666: \$? = $ac_status" >&5
9667 (exit $ac_status); }; }; then
9668 ac_cv_lib_dnet_stub_dnet_ntoa=yes
9670 echo "$as_me: failed program was:" >&5
9671 cat conftest.$ac_ext >&5
9672 ac_cv_lib_dnet_stub_dnet_ntoa=no
9674 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9675 LIBS=$ac_check_lib_save_LIBS
9677 echo "$as_me:9677: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5
9678 echo "${ECHO_T}$ac_cv_lib_dnet_stub_dnet_ntoa" >&6
9679 if test $ac_cv_lib_dnet_stub_dnet_ntoa = yes; then
9680 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
9685 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9686 LIBS="$ac_xsave_LIBS"
9688 # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT,
9689 # to get the SysV transport functions.
9690 # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4)
9692 # The nsl library prevents programs from opening the X display
9693 # on Irix 5.2, according to T.E. Dickey.
9694 # The functions gethostbyname, getservbyname, and inet_addr are
9695 # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking.
9696 echo "$as_me:9696: checking for gethostbyname" >&5
9697 echo $ECHO_N "checking for gethostbyname... $ECHO_C" >&6
9698 if test "${ac_cv_func_gethostbyname+set}" = set; then
9699 echo $ECHO_N "(cached) $ECHO_C" >&6
9701 cat >conftest.$ac_ext <<_ACEOF
9702 #line 9702 "configure"
9703 #include "confdefs.h"
9704 /* System header to define __stub macros and hopefully few prototypes,
9705 which can conflict with char gethostbyname (); below. */
9707 /* Override any gcc2 internal prototype to avoid an error. */
9711 /* We use char because int might match the return type of a gcc2
9712 builtin and then its argument prototype would still apply. */
9713 char gethostbyname ();
9719 /* The GNU C library defines this for functions which it implements
9720 to always fail with ENOSYS. Some functions are actually named
9721 something starting with __ and the normal name is an alias. */
9722 #if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
9732 rm -f conftest.$ac_objext conftest$ac_exeext
9733 if { (eval echo "$as_me:9733: \"$ac_link\"") >&5
9734 (eval $ac_link) 2>&5
9736 echo "$as_me:9736: \$? = $ac_status" >&5
9737 (exit $ac_status); } &&
9738 { ac_try='test -s conftest$ac_exeext'
9739 { (eval echo "$as_me:9739: \"$ac_try\"") >&5
9742 echo "$as_me:9742: \$? = $ac_status" >&5
9743 (exit $ac_status); }; }; then
9744 ac_cv_func_gethostbyname=yes
9746 echo "$as_me: failed program was:" >&5
9747 cat conftest.$ac_ext >&5
9748 ac_cv_func_gethostbyname=no
9750 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9752 echo "$as_me:9752: result: $ac_cv_func_gethostbyname" >&5
9753 echo "${ECHO_T}$ac_cv_func_gethostbyname" >&6
9755 if test $ac_cv_func_gethostbyname = no; then
9756 echo "$as_me:9756: checking for gethostbyname in -lnsl" >&5
9757 echo $ECHO_N "checking for gethostbyname in -lnsl... $ECHO_C" >&6
9758 if test "${ac_cv_lib_nsl_gethostbyname+set}" = set; then
9759 echo $ECHO_N "(cached) $ECHO_C" >&6
9761 ac_check_lib_save_LIBS=$LIBS
9763 cat >conftest.$ac_ext <<_ACEOF
9764 #line 9764 "configure"
9765 #include "confdefs.h"
9767 /* Override any gcc2 internal prototype to avoid an error. */
9771 /* We use char because int might match the return type of a gcc2
9772 builtin and then its argument prototype would still apply. */
9773 char gethostbyname ();
9782 rm -f conftest.$ac_objext conftest$ac_exeext
9783 if { (eval echo "$as_me:9783: \"$ac_link\"") >&5
9784 (eval $ac_link) 2>&5
9786 echo "$as_me:9786: \$? = $ac_status" >&5
9787 (exit $ac_status); } &&
9788 { ac_try='test -s conftest$ac_exeext'
9789 { (eval echo "$as_me:9789: \"$ac_try\"") >&5
9792 echo "$as_me:9792: \$? = $ac_status" >&5
9793 (exit $ac_status); }; }; then
9794 ac_cv_lib_nsl_gethostbyname=yes
9796 echo "$as_me: failed program was:" >&5
9797 cat conftest.$ac_ext >&5
9798 ac_cv_lib_nsl_gethostbyname=no
9800 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9801 LIBS=$ac_check_lib_save_LIBS
9803 echo "$as_me:9803: result: $ac_cv_lib_nsl_gethostbyname" >&5
9804 echo "${ECHO_T}$ac_cv_lib_nsl_gethostbyname" >&6
9805 if test $ac_cv_lib_nsl_gethostbyname = yes; then
9806 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
9809 if test $ac_cv_lib_nsl_gethostbyname = no; then
9810 echo "$as_me:9810: checking for gethostbyname in -lbsd" >&5
9811 echo $ECHO_N "checking for gethostbyname in -lbsd... $ECHO_C" >&6
9812 if test "${ac_cv_lib_bsd_gethostbyname+set}" = set; then
9813 echo $ECHO_N "(cached) $ECHO_C" >&6
9815 ac_check_lib_save_LIBS=$LIBS
9817 cat >conftest.$ac_ext <<_ACEOF
9818 #line 9818 "configure"
9819 #include "confdefs.h"
9821 /* Override any gcc2 internal prototype to avoid an error. */
9825 /* We use char because int might match the return type of a gcc2
9826 builtin and then its argument prototype would still apply. */
9827 char gethostbyname ();
9836 rm -f conftest.$ac_objext conftest$ac_exeext
9837 if { (eval echo "$as_me:9837: \"$ac_link\"") >&5
9838 (eval $ac_link) 2>&5
9840 echo "$as_me:9840: \$? = $ac_status" >&5
9841 (exit $ac_status); } &&
9842 { ac_try='test -s conftest$ac_exeext'
9843 { (eval echo "$as_me:9843: \"$ac_try\"") >&5
9846 echo "$as_me:9846: \$? = $ac_status" >&5
9847 (exit $ac_status); }; }; then
9848 ac_cv_lib_bsd_gethostbyname=yes
9850 echo "$as_me: failed program was:" >&5
9851 cat conftest.$ac_ext >&5
9852 ac_cv_lib_bsd_gethostbyname=no
9854 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9855 LIBS=$ac_check_lib_save_LIBS
9857 echo "$as_me:9857: result: $ac_cv_lib_bsd_gethostbyname" >&5
9858 echo "${ECHO_T}$ac_cv_lib_bsd_gethostbyname" >&6
9859 if test $ac_cv_lib_bsd_gethostbyname = yes; then
9860 X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd"
9866 # lieder@skyler.mavd.honeywell.com says without -lsocket,
9867 # socket/setsockopt and other routines are undefined under SCO ODT
9868 # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary
9869 # on later versions), says Simon Leinen: it contains gethostby*
9870 # variants that don't use the nameserver (or something). -lsocket
9871 # must be given before -lnsl if both are needed. We assume that
9872 # if connect needs -lnsl, so does gethostbyname.
9873 echo "$as_me:9873: checking for connect" >&5
9874 echo $ECHO_N "checking for connect... $ECHO_C" >&6
9875 if test "${ac_cv_func_connect+set}" = set; then
9876 echo $ECHO_N "(cached) $ECHO_C" >&6
9878 cat >conftest.$ac_ext <<_ACEOF
9879 #line 9879 "configure"
9880 #include "confdefs.h"
9881 /* System header to define __stub macros and hopefully few prototypes,
9882 which can conflict with char connect (); below. */
9884 /* Override any gcc2 internal prototype to avoid an error. */
9888 /* We use char because int might match the return type of a gcc2
9889 builtin and then its argument prototype would still apply. */
9896 /* The GNU C library defines this for functions which it implements
9897 to always fail with ENOSYS. Some functions are actually named
9898 something starting with __ and the normal name is an alias. */
9899 #if defined (__stub_connect) || defined (__stub___connect)
9909 rm -f conftest.$ac_objext conftest$ac_exeext
9910 if { (eval echo "$as_me:9910: \"$ac_link\"") >&5
9911 (eval $ac_link) 2>&5
9913 echo "$as_me:9913: \$? = $ac_status" >&5
9914 (exit $ac_status); } &&
9915 { ac_try='test -s conftest$ac_exeext'
9916 { (eval echo "$as_me:9916: \"$ac_try\"") >&5
9919 echo "$as_me:9919: \$? = $ac_status" >&5
9920 (exit $ac_status); }; }; then
9921 ac_cv_func_connect=yes
9923 echo "$as_me: failed program was:" >&5
9924 cat conftest.$ac_ext >&5
9925 ac_cv_func_connect=no
9927 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9929 echo "$as_me:9929: result: $ac_cv_func_connect" >&5
9930 echo "${ECHO_T}$ac_cv_func_connect" >&6
9932 if test $ac_cv_func_connect = no; then
9933 echo "$as_me:9933: checking for connect in -lsocket" >&5
9934 echo $ECHO_N "checking for connect in -lsocket... $ECHO_C" >&6
9935 if test "${ac_cv_lib_socket_connect+set}" = set; then
9936 echo $ECHO_N "(cached) $ECHO_C" >&6
9938 ac_check_lib_save_LIBS=$LIBS
9939 LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
9940 cat >conftest.$ac_ext <<_ACEOF
9941 #line 9941 "configure"
9942 #include "confdefs.h"
9944 /* Override any gcc2 internal prototype to avoid an error. */
9948 /* We use char because int might match the return type of a gcc2
9949 builtin and then its argument prototype would still apply. */
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_lib_socket_connect=yes
9973 echo "$as_me: failed program was:" >&5
9974 cat conftest.$ac_ext >&5
9975 ac_cv_lib_socket_connect=no
9977 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9978 LIBS=$ac_check_lib_save_LIBS
9980 echo "$as_me:9980: result: $ac_cv_lib_socket_connect" >&5
9981 echo "${ECHO_T}$ac_cv_lib_socket_connect" >&6
9982 if test $ac_cv_lib_socket_connect = yes; then
9983 X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS"
9988 # Guillermo Gomez says -lposix is necessary on A/UX.
9989 echo "$as_me:9989: checking for remove" >&5
9990 echo $ECHO_N "checking for remove... $ECHO_C" >&6
9991 if test "${ac_cv_func_remove+set}" = set; then
9992 echo $ECHO_N "(cached) $ECHO_C" >&6
9994 cat >conftest.$ac_ext <<_ACEOF
9995 #line 9995 "configure"
9996 #include "confdefs.h"
9997 /* System header to define __stub macros and hopefully few prototypes,
9998 which can conflict with char remove (); below. */
10000 /* Override any gcc2 internal prototype to avoid an error. */
10004 /* We use char because int might match the return type of a gcc2
10005 builtin and then its argument prototype would still apply. */
10012 /* The GNU C library defines this for functions which it implements
10013 to always fail with ENOSYS. Some functions are actually named
10014 something starting with __ and the normal name is an alias. */
10015 #if defined (__stub_remove) || defined (__stub___remove)
10025 rm -f conftest.$ac_objext conftest$ac_exeext
10026 if { (eval echo "$as_me:10026: \"$ac_link\"") >&5
10027 (eval $ac_link) 2>&5
10029 echo "$as_me:10029: \$? = $ac_status" >&5
10030 (exit $ac_status); } &&
10031 { ac_try='test -s conftest$ac_exeext'
10032 { (eval echo "$as_me:10032: \"$ac_try\"") >&5
10033 (eval $ac_try) 2>&5
10035 echo "$as_me:10035: \$? = $ac_status" >&5
10036 (exit $ac_status); }; }; then
10037 ac_cv_func_remove=yes
10039 echo "$as_me: failed program was:" >&5
10040 cat conftest.$ac_ext >&5
10041 ac_cv_func_remove=no
10043 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10045 echo "$as_me:10045: result: $ac_cv_func_remove" >&5
10046 echo "${ECHO_T}$ac_cv_func_remove" >&6
10048 if test $ac_cv_func_remove = no; then
10049 echo "$as_me:10049: checking for remove in -lposix" >&5
10050 echo $ECHO_N "checking for remove in -lposix... $ECHO_C" >&6
10051 if test "${ac_cv_lib_posix_remove+set}" = set; then
10052 echo $ECHO_N "(cached) $ECHO_C" >&6
10054 ac_check_lib_save_LIBS=$LIBS
10055 LIBS="-lposix $LIBS"
10056 cat >conftest.$ac_ext <<_ACEOF
10057 #line 10057 "configure"
10058 #include "confdefs.h"
10060 /* Override any gcc2 internal prototype to avoid an error. */
10064 /* We use char because int might match the return type of a gcc2
10065 builtin and then its argument prototype would still apply. */
10075 rm -f conftest.$ac_objext conftest$ac_exeext
10076 if { (eval echo "$as_me:10076: \"$ac_link\"") >&5
10077 (eval $ac_link) 2>&5
10079 echo "$as_me:10079: \$? = $ac_status" >&5
10080 (exit $ac_status); } &&
10081 { ac_try='test -s conftest$ac_exeext'
10082 { (eval echo "$as_me:10082: \"$ac_try\"") >&5
10083 (eval $ac_try) 2>&5
10085 echo "$as_me:10085: \$? = $ac_status" >&5
10086 (exit $ac_status); }; }; then
10087 ac_cv_lib_posix_remove=yes
10089 echo "$as_me: failed program was:" >&5
10090 cat conftest.$ac_ext >&5
10091 ac_cv_lib_posix_remove=no
10093 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10094 LIBS=$ac_check_lib_save_LIBS
10096 echo "$as_me:10096: result: $ac_cv_lib_posix_remove" >&5
10097 echo "${ECHO_T}$ac_cv_lib_posix_remove" >&6
10098 if test $ac_cv_lib_posix_remove = yes; then
10099 X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix"
10104 # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
10105 echo "$as_me:10105: checking for shmat" >&5
10106 echo $ECHO_N "checking for shmat... $ECHO_C" >&6
10107 if test "${ac_cv_func_shmat+set}" = set; then
10108 echo $ECHO_N "(cached) $ECHO_C" >&6
10110 cat >conftest.$ac_ext <<_ACEOF
10111 #line 10111 "configure"
10112 #include "confdefs.h"
10113 /* System header to define __stub macros and hopefully few prototypes,
10114 which can conflict with char shmat (); below. */
10115 #include <assert.h>
10116 /* Override any gcc2 internal prototype to avoid an error. */
10120 /* We use char because int might match the return type of a gcc2
10121 builtin and then its argument prototype would still apply. */
10128 /* The GNU C library defines this for functions which it implements
10129 to always fail with ENOSYS. Some functions are actually named
10130 something starting with __ and the normal name is an alias. */
10131 #if defined (__stub_shmat) || defined (__stub___shmat)
10141 rm -f conftest.$ac_objext conftest$ac_exeext
10142 if { (eval echo "$as_me:10142: \"$ac_link\"") >&5
10143 (eval $ac_link) 2>&5
10145 echo "$as_me:10145: \$? = $ac_status" >&5
10146 (exit $ac_status); } &&
10147 { ac_try='test -s conftest$ac_exeext'
10148 { (eval echo "$as_me:10148: \"$ac_try\"") >&5
10149 (eval $ac_try) 2>&5
10151 echo "$as_me:10151: \$? = $ac_status" >&5
10152 (exit $ac_status); }; }; then
10153 ac_cv_func_shmat=yes
10155 echo "$as_me: failed program was:" >&5
10156 cat conftest.$ac_ext >&5
10157 ac_cv_func_shmat=no
10159 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10161 echo "$as_me:10161: result: $ac_cv_func_shmat" >&5
10162 echo "${ECHO_T}$ac_cv_func_shmat" >&6
10164 if test $ac_cv_func_shmat = no; then
10165 echo "$as_me:10165: checking for shmat in -lipc" >&5
10166 echo $ECHO_N "checking for shmat in -lipc... $ECHO_C" >&6
10167 if test "${ac_cv_lib_ipc_shmat+set}" = set; then
10168 echo $ECHO_N "(cached) $ECHO_C" >&6
10170 ac_check_lib_save_LIBS=$LIBS
10172 cat >conftest.$ac_ext <<_ACEOF
10173 #line 10173 "configure"
10174 #include "confdefs.h"
10176 /* Override any gcc2 internal prototype to avoid an error. */
10180 /* We use char because int might match the return type of a gcc2
10181 builtin and then its argument prototype would still apply. */
10191 rm -f conftest.$ac_objext conftest$ac_exeext
10192 if { (eval echo "$as_me:10192: \"$ac_link\"") >&5
10193 (eval $ac_link) 2>&5
10195 echo "$as_me:10195: \$? = $ac_status" >&5
10196 (exit $ac_status); } &&
10197 { ac_try='test -s conftest$ac_exeext'
10198 { (eval echo "$as_me:10198: \"$ac_try\"") >&5
10199 (eval $ac_try) 2>&5
10201 echo "$as_me:10201: \$? = $ac_status" >&5
10202 (exit $ac_status); }; }; then
10203 ac_cv_lib_ipc_shmat=yes
10205 echo "$as_me: failed program was:" >&5
10206 cat conftest.$ac_ext >&5
10207 ac_cv_lib_ipc_shmat=no
10209 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10210 LIBS=$ac_check_lib_save_LIBS
10212 echo "$as_me:10212: result: $ac_cv_lib_ipc_shmat" >&5
10213 echo "${ECHO_T}$ac_cv_lib_ipc_shmat" >&6
10214 if test $ac_cv_lib_ipc_shmat = yes; then
10215 X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc"
10221 # Check for libraries that X11R6 Xt/Xaw programs need.
10222 ac_save_LDFLAGS=$LDFLAGS
10223 test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries"
10224 # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
10225 # check for ICE first), but we must link in the order -lSM -lICE or
10226 # we get undefined symbols. So assume we have SM if we have ICE.
10227 # These have to be linked with before -lX11, unlike the other
10228 # libraries we check for below, so use a different variable.
10229 # John Interrante, Karl Berry
10230 echo "$as_me:10230: checking for IceConnectionNumber in -lICE" >&5
10231 echo $ECHO_N "checking for IceConnectionNumber in -lICE... $ECHO_C" >&6
10232 if test "${ac_cv_lib_ICE_IceConnectionNumber+set}" = set; then
10233 echo $ECHO_N "(cached) $ECHO_C" >&6
10235 ac_check_lib_save_LIBS=$LIBS
10236 LIBS="-lICE $X_EXTRA_LIBS $LIBS"
10237 cat >conftest.$ac_ext <<_ACEOF
10238 #line 10238 "configure"
10239 #include "confdefs.h"
10241 /* Override any gcc2 internal prototype to avoid an error. */
10245 /* We use char because int might match the return type of a gcc2
10246 builtin and then its argument prototype would still apply. */
10247 char IceConnectionNumber ();
10251 IceConnectionNumber ();
10256 rm -f conftest.$ac_objext conftest$ac_exeext
10257 if { (eval echo "$as_me:10257: \"$ac_link\"") >&5
10258 (eval $ac_link) 2>&5
10260 echo "$as_me:10260: \$? = $ac_status" >&5
10261 (exit $ac_status); } &&
10262 { ac_try='test -s conftest$ac_exeext'
10263 { (eval echo "$as_me:10263: \"$ac_try\"") >&5
10264 (eval $ac_try) 2>&5
10266 echo "$as_me:10266: \$? = $ac_status" >&5
10267 (exit $ac_status); }; }; then
10268 ac_cv_lib_ICE_IceConnectionNumber=yes
10270 echo "$as_me: failed program was:" >&5
10271 cat conftest.$ac_ext >&5
10272 ac_cv_lib_ICE_IceConnectionNumber=no
10274 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10275 LIBS=$ac_check_lib_save_LIBS
10277 echo "$as_me:10277: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5
10278 echo "${ECHO_T}$ac_cv_lib_ICE_IceConnectionNumber" >&6
10279 if test $ac_cv_lib_ICE_IceConnectionNumber = yes; then
10280 X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
10283 LDFLAGS=$ac_save_LDFLAGS
10287 cf_x_athena=${cf_x_athena:-Xaw}
10289 echo "$as_me:10289: checking if you want to link with Xaw 3d library" >&5
10290 echo $ECHO_N "checking if you want to link with Xaw 3d library... $ECHO_C" >&6
10293 # Check whether --with-Xaw3d or --without-Xaw3d was given.
10294 if test "${with_Xaw3d+set}" = set; then
10295 withval="$with_Xaw3d"
10298 if test "$withval" = yes ; then
10300 echo "$as_me:10300: result: yes" >&5
10301 echo "${ECHO_T}yes" >&6
10303 echo "$as_me:10303: result: no" >&5
10304 echo "${ECHO_T}no" >&6
10307 echo "$as_me:10307: checking if you want to link with neXT Athena library" >&5
10308 echo $ECHO_N "checking if you want to link with neXT Athena library... $ECHO_C" >&6
10311 # Check whether --with-neXtaw or --without-neXtaw was given.
10312 if test "${with_neXtaw+set}" = set; then
10313 withval="$with_neXtaw"
10316 if test "$withval" = yes ; then
10318 echo "$as_me:10318: result: yes" >&5
10319 echo "${ECHO_T}yes" >&6
10321 echo "$as_me:10321: result: no" >&5
10322 echo "${ECHO_T}no" >&6
10325 echo "$as_me:10325: checking if you want to link with Athena-Plus library" >&5
10326 echo $ECHO_N "checking if you want to link with Athena-Plus library... $ECHO_C" >&6
10329 # Check whether --with-XawPlus or --without-XawPlus was given.
10330 if test "${with_XawPlus+set}" = set; then
10331 withval="$with_XawPlus"
10334 if test "$withval" = yes ; then
10335 cf_x_athena=XawPlus
10336 echo "$as_me:10336: result: yes" >&5
10337 echo "${ECHO_T}yes" >&6
10339 echo "$as_me:10339: result: no" >&5
10340 echo "${ECHO_T}no" >&6
10345 if test "$PKG_CONFIG" != none ; then
10347 test "$cf_x_athena" = Xaw && cf_athena_list="xaw8 xaw7 xaw6"
10348 for cf_athena_pkg in \
10351 ${cf_x_athena}-devel \
10352 lib${cf_x_athena} \
10353 lib${cf_x_athena}-devel
10356 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists $cf_athena_pkg; then
10357 test -n "$verbose" && echo " found package $cf_athena_pkg" 1>&6
10359 echo "${as_me:-configure}:10359: testing found package $cf_athena_pkg ..." 1>&5
10361 cf_pkgconfig_incs="`$PKG_CONFIG --cflags $cf_athena_pkg 2>/dev/null`"
10362 cf_pkgconfig_libs="`$PKG_CONFIG --libs $cf_athena_pkg 2>/dev/null`"
10363 test -n "$verbose" && echo " package $cf_athena_pkg CFLAGS: $cf_pkgconfig_incs" 1>&6
10365 echo "${as_me:-configure}:10365: testing package $cf_athena_pkg CFLAGS: $cf_pkgconfig_incs ..." 1>&5
10367 test -n "$verbose" && echo " package $cf_athena_pkg LIBS: $cf_pkgconfig_libs" 1>&6
10369 echo "${as_me:-configure}:10369: testing package $cf_athena_pkg LIBS: $cf_pkgconfig_libs ..." 1>&5
10374 cf_new_extra_cppflags=
10376 for cf_add_cflags in $cf_pkgconfig_incs
10378 case $cf_fix_cppflags in
10380 case $cf_add_cflags in #(vi
10381 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
10382 case $cf_add_cflags in
10384 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10386 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10387 && test -z "${cf_tst_cflags}" \
10388 && cf_fix_cppflags=yes
10390 if test $cf_fix_cppflags = yes ; then
10391 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10393 elif test "${cf_tst_cflags}" = "\"'" ; then
10394 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10399 case "$CPPFLAGS" in
10400 *$cf_add_cflags) #(vi
10403 case $cf_add_cflags in #(vi
10405 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10407 CPPFLAGS=`echo "$CPPFLAGS" | \
10408 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10409 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10413 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
10418 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
10423 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10425 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10427 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10428 && test -z "${cf_tst_cflags}" \
10429 && cf_fix_cppflags=no
10434 if test -n "$cf_new_cflags" ; then
10436 CFLAGS="$CFLAGS $cf_new_cflags"
10439 if test -n "$cf_new_cppflags" ; then
10441 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
10444 if test -n "$cf_new_extra_cppflags" ; then
10446 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
10449 LIBS="$cf_pkgconfig_libs $LIBS"
10451 cf_x_athena_lib="$cf_pkgconfig_libs"
10453 cf_x_athena_LIBS=`echo "HAVE_LIB_$cf_x_athena" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
10455 cat >>confdefs.h <<EOF
10456 #define $cf_x_athena_LIBS 1
10459 echo "$as_me:10459: checking for usable $cf_x_athena/Xmu package" >&5
10460 echo $ECHO_N "checking for usable $cf_x_athena/Xmu package... $ECHO_C" >&6
10461 if test "${cf_cv_xaw_compat+set}" = set; then
10462 echo $ECHO_N "(cached) $ECHO_C" >&6
10465 cat >conftest.$ac_ext <<_ACEOF
10466 #line 10466 "configure"
10467 #include "confdefs.h"
10469 #include <X11/Xmu/CharSet.h>
10475 int check = XmuCompareISOLatin1("big", "small")
10481 rm -f conftest.$ac_objext conftest$ac_exeext
10482 if { (eval echo "$as_me:10482: \"$ac_link\"") >&5
10483 (eval $ac_link) 2>&5
10485 echo "$as_me:10485: \$? = $ac_status" >&5
10486 (exit $ac_status); } &&
10487 { ac_try='test -s conftest$ac_exeext'
10488 { (eval echo "$as_me:10488: \"$ac_try\"") >&5
10489 (eval $ac_try) 2>&5
10491 echo "$as_me:10491: \$? = $ac_status" >&5
10492 (exit $ac_status); }; }; then
10493 cf_cv_xaw_compat=yes
10495 echo "$as_me: failed program was:" >&5
10496 cat conftest.$ac_ext >&5
10497 cf_cv_xaw_compat=no
10499 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10501 echo "$as_me:10501: result: $cf_cv_xaw_compat" >&5
10502 echo "${ECHO_T}$cf_cv_xaw_compat" >&6
10504 if test "$cf_cv_xaw_compat" = no
10506 # workaround for broken ".pc" files...
10507 case "$cf_x_athena_lib" in #(vi
10511 test -n "$verbose" && echo " work around broken package" 1>&6
10513 echo "${as_me:-configure}:10513: testing work around broken package ..." 1>&5
10515 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xmu; then
10516 test -n "$verbose" && echo " found package xmu" 1>&6
10518 echo "${as_me:-configure}:10518: testing found package xmu ..." 1>&5
10520 cf_pkgconfig_incs="`$PKG_CONFIG --cflags xmu 2>/dev/null`"
10521 cf_pkgconfig_libs="`$PKG_CONFIG --libs xmu 2>/dev/null`"
10522 test -n "$verbose" && echo " package xmu CFLAGS: $cf_pkgconfig_incs" 1>&6
10524 echo "${as_me:-configure}:10524: testing package xmu CFLAGS: $cf_pkgconfig_incs ..." 1>&5
10526 test -n "$verbose" && echo " package xmu LIBS: $cf_pkgconfig_libs" 1>&6
10528 echo "${as_me:-configure}:10528: testing package xmu LIBS: $cf_pkgconfig_libs ..." 1>&5
10533 cf_new_extra_cppflags=
10535 for cf_add_cflags in $cf_pkgconfig_incs
10537 case $cf_fix_cppflags in
10539 case $cf_add_cflags in #(vi
10540 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
10541 case $cf_add_cflags in
10543 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10545 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10546 && test -z "${cf_tst_cflags}" \
10547 && cf_fix_cppflags=yes
10549 if test $cf_fix_cppflags = yes ; then
10550 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10552 elif test "${cf_tst_cflags}" = "\"'" ; then
10553 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10558 case "$CPPFLAGS" in
10559 *$cf_add_cflags) #(vi
10562 case $cf_add_cflags in #(vi
10564 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10566 CPPFLAGS=`echo "$CPPFLAGS" | \
10567 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10568 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10572 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
10577 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
10582 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10584 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10586 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10587 && test -z "${cf_tst_cflags}" \
10588 && cf_fix_cppflags=no
10593 if test -n "$cf_new_cflags" ; then
10595 CFLAGS="$CFLAGS $cf_new_cflags"
10598 if test -n "$cf_new_cppflags" ; then
10600 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
10603 if test -n "$cf_new_extra_cppflags" ; then
10605 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
10608 LIBS="$cf_pkgconfig_libs $LIBS"
10612 test -n "$verbose" && echo " ...before $LIBS" 1>&6
10614 echo "${as_me:-configure}:10614: testing ...before $LIBS ..." 1>&5
10616 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s,-lXt ,-lXt -lXmu ," -e 's/ / /g'`
10617 test -n "$verbose" && echo " ...after $LIBS" 1>&6
10619 echo "${as_me:-configure}:10619: testing ...after $LIBS ..." 1>&5
10635 if test -z "$cf_x_athena_lib" ; then
10637 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists Xext; then
10638 test -n "$verbose" && echo " found package Xext" 1>&6
10640 echo "${as_me:-configure}:10640: testing found package Xext ..." 1>&5
10642 cf_pkgconfig_incs="`$PKG_CONFIG --cflags Xext 2>/dev/null`"
10643 cf_pkgconfig_libs="`$PKG_CONFIG --libs Xext 2>/dev/null`"
10644 test -n "$verbose" && echo " package Xext CFLAGS: $cf_pkgconfig_incs" 1>&6
10646 echo "${as_me:-configure}:10646: testing package Xext CFLAGS: $cf_pkgconfig_incs ..." 1>&5
10648 test -n "$verbose" && echo " package Xext LIBS: $cf_pkgconfig_libs" 1>&6
10650 echo "${as_me:-configure}:10650: testing package Xext LIBS: $cf_pkgconfig_libs ..." 1>&5
10655 cf_new_extra_cppflags=
10657 for cf_add_cflags in $cf_pkgconfig_incs
10659 case $cf_fix_cppflags in
10661 case $cf_add_cflags in #(vi
10662 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
10663 case $cf_add_cflags in
10665 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10667 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10668 && test -z "${cf_tst_cflags}" \
10669 && cf_fix_cppflags=yes
10671 if test $cf_fix_cppflags = yes ; then
10672 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10674 elif test "${cf_tst_cflags}" = "\"'" ; then
10675 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10680 case "$CPPFLAGS" in
10681 *$cf_add_cflags) #(vi
10684 case $cf_add_cflags in #(vi
10686 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10688 CPPFLAGS=`echo "$CPPFLAGS" | \
10689 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10690 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10694 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
10699 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
10704 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10706 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10708 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10709 && test -z "${cf_tst_cflags}" \
10710 && cf_fix_cppflags=no
10715 if test -n "$cf_new_cflags" ; then
10717 CFLAGS="$CFLAGS $cf_new_cflags"
10720 if test -n "$cf_new_cppflags" ; then
10722 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
10725 if test -n "$cf_new_extra_cppflags" ; then
10727 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
10730 LIBS="$cf_pkgconfig_libs $LIBS"
10734 echo "$as_me:10734: checking for XextCreateExtension in -lXext" >&5
10735 echo $ECHO_N "checking for XextCreateExtension in -lXext... $ECHO_C" >&6
10736 if test "${ac_cv_lib_Xext_XextCreateExtension+set}" = set; then
10737 echo $ECHO_N "(cached) $ECHO_C" >&6
10739 ac_check_lib_save_LIBS=$LIBS
10740 LIBS="-lXext $LIBS"
10741 cat >conftest.$ac_ext <<_ACEOF
10742 #line 10742 "configure"
10743 #include "confdefs.h"
10745 /* Override any gcc2 internal prototype to avoid an error. */
10749 /* We use char because int might match the return type of a gcc2
10750 builtin and then its argument prototype would still apply. */
10751 char XextCreateExtension ();
10755 XextCreateExtension ();
10760 rm -f conftest.$ac_objext conftest$ac_exeext
10761 if { (eval echo "$as_me:10761: \"$ac_link\"") >&5
10762 (eval $ac_link) 2>&5
10764 echo "$as_me:10764: \$? = $ac_status" >&5
10765 (exit $ac_status); } &&
10766 { ac_try='test -s conftest$ac_exeext'
10767 { (eval echo "$as_me:10767: \"$ac_try\"") >&5
10768 (eval $ac_try) 2>&5
10770 echo "$as_me:10770: \$? = $ac_status" >&5
10771 (exit $ac_status); }; }; then
10772 ac_cv_lib_Xext_XextCreateExtension=yes
10774 echo "$as_me: failed program was:" >&5
10775 cat conftest.$ac_ext >&5
10776 ac_cv_lib_Xext_XextCreateExtension=no
10778 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10779 LIBS=$ac_check_lib_save_LIBS
10781 echo "$as_me:10781: result: $ac_cv_lib_Xext_XextCreateExtension" >&5
10782 echo "${ECHO_T}$ac_cv_lib_Xext_XextCreateExtension" >&6
10783 if test $ac_cv_lib_Xext_XextCreateExtension = yes; then
10784 LIBS="-lXext $LIBS"
10791 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xt; then
10792 test -n "$verbose" && echo " found package xt" 1>&6
10794 echo "${as_me:-configure}:10794: testing found package xt ..." 1>&5
10796 cf_pkgconfig_incs="`$PKG_CONFIG --cflags xt 2>/dev/null`"
10797 cf_pkgconfig_libs="`$PKG_CONFIG --libs xt 2>/dev/null`"
10798 test -n "$verbose" && echo " package xt CFLAGS: $cf_pkgconfig_incs" 1>&6
10800 echo "${as_me:-configure}:10800: testing package xt CFLAGS: $cf_pkgconfig_incs ..." 1>&5
10802 test -n "$verbose" && echo " package xt LIBS: $cf_pkgconfig_libs" 1>&6
10804 echo "${as_me:-configure}:10804: testing package xt LIBS: $cf_pkgconfig_libs ..." 1>&5
10809 cf_new_extra_cppflags=
10811 for cf_add_cflags in $cf_pkgconfig_incs
10813 case $cf_fix_cppflags in
10815 case $cf_add_cflags in #(vi
10816 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
10817 case $cf_add_cflags in
10819 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10821 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10822 && test -z "${cf_tst_cflags}" \
10823 && cf_fix_cppflags=yes
10825 if test $cf_fix_cppflags = yes ; then
10826 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10828 elif test "${cf_tst_cflags}" = "\"'" ; then
10829 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10834 case "$CPPFLAGS" in
10835 *$cf_add_cflags) #(vi
10838 case $cf_add_cflags in #(vi
10840 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10842 CPPFLAGS=`echo "$CPPFLAGS" | \
10843 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10844 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10848 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
10853 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
10858 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10860 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10862 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10863 && test -z "${cf_tst_cflags}" \
10864 && cf_fix_cppflags=no
10869 if test -n "$cf_new_cflags" ; then
10871 CFLAGS="$CFLAGS $cf_new_cflags"
10874 if test -n "$cf_new_cppflags" ; then
10876 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
10879 if test -n "$cf_new_extra_cppflags" ; then
10881 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
10884 LIBS="$cf_pkgconfig_libs $LIBS"
10886 case "x$LIBS" in #(vi
10890 # we have an "xt" package, but it may omit Xt's dependency on X11
10891 echo "$as_me:10891: checking for usable X dependency" >&5
10892 echo $ECHO_N "checking for usable X dependency... $ECHO_C" >&6
10893 if test "${cf_cv_xt_x11_compat+set}" = set; then
10894 echo $ECHO_N "(cached) $ECHO_C" >&6
10897 cat >conftest.$ac_ext <<_ACEOF
10898 #line 10898 "configure"
10899 #include "confdefs.h"
10901 #include <X11/Xlib.h>
10907 int rc1 = XDrawLine((Display*) 0, (Drawable) 0, (GC) 0, 0, 0, 0, 0);
10908 int rc2 = XClearWindow((Display*) 0, (Window) 0);
10909 int rc3 = XMoveWindow((Display*) 0, (Window) 0, 0, 0);
10910 int rc4 = XMoveResizeWindow((Display*)0, (Window)0, 0, 0, 0, 0);
10916 rm -f conftest.$ac_objext conftest$ac_exeext
10917 if { (eval echo "$as_me:10917: \"$ac_link\"") >&5
10918 (eval $ac_link) 2>&5
10920 echo "$as_me:10920: \$? = $ac_status" >&5
10921 (exit $ac_status); } &&
10922 { ac_try='test -s conftest$ac_exeext'
10923 { (eval echo "$as_me:10923: \"$ac_try\"") >&5
10924 (eval $ac_try) 2>&5
10926 echo "$as_me:10926: \$? = $ac_status" >&5
10927 (exit $ac_status); }; }; then
10928 cf_cv_xt_x11_compat=yes
10930 echo "$as_me: failed program was:" >&5
10931 cat conftest.$ac_ext >&5
10932 cf_cv_xt_x11_compat=no
10934 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10936 echo "$as_me:10936: result: $cf_cv_xt_x11_compat" >&5
10937 echo "${ECHO_T}$cf_cv_xt_x11_compat" >&6
10938 if test "$cf_cv_xt_x11_compat" = no
10940 test -n "$verbose" && echo " work around broken X11 dependency" 1>&6
10942 echo "${as_me:-configure}:10942: testing work around broken X11 dependency ..." 1>&5
10944 # 2010/11/19 - good enough until a working Xt on Xcb is delivered.
10946 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists x11; then
10947 test -n "$verbose" && echo " found package x11" 1>&6
10949 echo "${as_me:-configure}:10949: testing found package x11 ..." 1>&5
10951 cf_pkgconfig_incs="`$PKG_CONFIG --cflags x11 2>/dev/null`"
10952 cf_pkgconfig_libs="`$PKG_CONFIG --libs x11 2>/dev/null`"
10953 test -n "$verbose" && echo " package x11 CFLAGS: $cf_pkgconfig_incs" 1>&6
10955 echo "${as_me:-configure}:10955: testing package x11 CFLAGS: $cf_pkgconfig_incs ..." 1>&5
10957 test -n "$verbose" && echo " package x11 LIBS: $cf_pkgconfig_libs" 1>&6
10959 echo "${as_me:-configure}:10959: testing package x11 LIBS: $cf_pkgconfig_libs ..." 1>&5
10964 cf_new_extra_cppflags=
10966 for cf_add_cflags in $cf_pkgconfig_incs
10968 case $cf_fix_cppflags in
10970 case $cf_add_cflags in #(vi
10971 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
10972 case $cf_add_cflags in
10974 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10976 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10977 && test -z "${cf_tst_cflags}" \
10978 && cf_fix_cppflags=yes
10980 if test $cf_fix_cppflags = yes ; then
10981 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10983 elif test "${cf_tst_cflags}" = "\"'" ; then
10984 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10989 case "$CPPFLAGS" in
10990 *$cf_add_cflags) #(vi
10993 case $cf_add_cflags in #(vi
10995 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10997 CPPFLAGS=`echo "$CPPFLAGS" | \
10998 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10999 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11003 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
11008 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
11013 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11015 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11017 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11018 && test -z "${cf_tst_cflags}" \
11019 && cf_fix_cppflags=no
11024 if test -n "$cf_new_cflags" ; then
11026 CFLAGS="$CFLAGS $cf_new_cflags"
11029 if test -n "$cf_new_cppflags" ; then
11031 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
11034 if test -n "$cf_new_extra_cppflags" ; then
11036 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
11039 LIBS="$cf_pkgconfig_libs $LIBS"
11043 test -n "$verbose" && echo " ...before $LIBS" 1>&6
11045 echo "${as_me:-configure}:11045: testing ...before $LIBS ..." 1>&5
11047 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s,-lXt ,-lXt -lX11 ," -e 's/ / /g'`
11048 test -n "$verbose" && echo " ...after $LIBS" 1>&6
11050 echo "${as_me:-configure}:11050: testing ...after $LIBS ..." 1>&5
11058 echo "$as_me:11058: checking for usable X Toolkit package" >&5
11059 echo $ECHO_N "checking for usable X Toolkit package... $ECHO_C" >&6
11060 if test "${cf_cv_xt_ice_compat+set}" = set; then
11061 echo $ECHO_N "(cached) $ECHO_C" >&6
11064 cat >conftest.$ac_ext <<_ACEOF
11065 #line 11065 "configure"
11066 #include "confdefs.h"
11068 #include <X11/Shell.h>
11073 int num = IceConnectionNumber(0)
11079 rm -f conftest.$ac_objext conftest$ac_exeext
11080 if { (eval echo "$as_me:11080: \"$ac_link\"") >&5
11081 (eval $ac_link) 2>&5
11083 echo "$as_me:11083: \$? = $ac_status" >&5
11084 (exit $ac_status); } &&
11085 { ac_try='test -s conftest$ac_exeext'
11086 { (eval echo "$as_me:11086: \"$ac_try\"") >&5
11087 (eval $ac_try) 2>&5
11089 echo "$as_me:11089: \$? = $ac_status" >&5
11090 (exit $ac_status); }; }; then
11091 cf_cv_xt_ice_compat=yes
11093 echo "$as_me: failed program was:" >&5
11094 cat conftest.$ac_ext >&5
11095 cf_cv_xt_ice_compat=no
11097 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11099 echo "$as_me:11099: result: $cf_cv_xt_ice_compat" >&5
11100 echo "${ECHO_T}$cf_cv_xt_ice_compat" >&6
11102 if test "$cf_cv_xt_ice_compat" = no
11104 # workaround for broken ".pc" files used for X Toolkit.
11105 case "x$X_PRE_LIBS" in #(vi
11107 case "x$LIBS" in #(vi
11111 test -n "$verbose" && echo " work around broken ICE dependency" 1>&6
11113 echo "${as_me:-configure}:11113: testing work around broken ICE dependency ..." 1>&5
11115 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists ice; then
11116 test -n "$verbose" && echo " found package ice" 1>&6
11118 echo "${as_me:-configure}:11118: testing found package ice ..." 1>&5
11120 cf_pkgconfig_incs="`$PKG_CONFIG --cflags ice 2>/dev/null`"
11121 cf_pkgconfig_libs="`$PKG_CONFIG --libs ice 2>/dev/null`"
11122 test -n "$verbose" && echo " package ice CFLAGS: $cf_pkgconfig_incs" 1>&6
11124 echo "${as_me:-configure}:11124: testing package ice CFLAGS: $cf_pkgconfig_incs ..." 1>&5
11126 test -n "$verbose" && echo " package ice LIBS: $cf_pkgconfig_libs" 1>&6
11128 echo "${as_me:-configure}:11128: testing package ice LIBS: $cf_pkgconfig_libs ..." 1>&5
11133 cf_new_extra_cppflags=
11135 for cf_add_cflags in $cf_pkgconfig_incs
11137 case $cf_fix_cppflags in
11139 case $cf_add_cflags in #(vi
11140 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
11141 case $cf_add_cflags in
11143 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11145 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11146 && test -z "${cf_tst_cflags}" \
11147 && cf_fix_cppflags=yes
11149 if test $cf_fix_cppflags = yes ; then
11150 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11152 elif test "${cf_tst_cflags}" = "\"'" ; then
11153 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11158 case "$CPPFLAGS" in
11159 *$cf_add_cflags) #(vi
11162 case $cf_add_cflags in #(vi
11164 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11166 CPPFLAGS=`echo "$CPPFLAGS" | \
11167 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11168 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11172 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
11177 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
11182 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11184 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11186 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11187 && test -z "${cf_tst_cflags}" \
11188 && cf_fix_cppflags=no
11193 if test -n "$cf_new_cflags" ; then
11195 CFLAGS="$CFLAGS $cf_new_cflags"
11198 if test -n "$cf_new_cppflags" ; then
11200 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
11203 if test -n "$cf_new_extra_cppflags" ; then
11205 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
11208 LIBS="$cf_pkgconfig_libs $LIBS"
11210 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists sm; then
11211 test -n "$verbose" && echo " found package sm" 1>&6
11213 echo "${as_me:-configure}:11213: testing found package sm ..." 1>&5
11215 cf_pkgconfig_incs="`$PKG_CONFIG --cflags sm 2>/dev/null`"
11216 cf_pkgconfig_libs="`$PKG_CONFIG --libs sm 2>/dev/null`"
11217 test -n "$verbose" && echo " package sm CFLAGS: $cf_pkgconfig_incs" 1>&6
11219 echo "${as_me:-configure}:11219: testing package sm CFLAGS: $cf_pkgconfig_incs ..." 1>&5
11221 test -n "$verbose" && echo " package sm LIBS: $cf_pkgconfig_libs" 1>&6
11223 echo "${as_me:-configure}:11223: testing package sm LIBS: $cf_pkgconfig_libs ..." 1>&5
11228 cf_new_extra_cppflags=
11230 for cf_add_cflags in $cf_pkgconfig_incs
11232 case $cf_fix_cppflags in
11234 case $cf_add_cflags in #(vi
11235 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
11236 case $cf_add_cflags in
11238 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11240 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11241 && test -z "${cf_tst_cflags}" \
11242 && cf_fix_cppflags=yes
11244 if test $cf_fix_cppflags = yes ; then
11245 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11247 elif test "${cf_tst_cflags}" = "\"'" ; then
11248 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11253 case "$CPPFLAGS" in
11254 *$cf_add_cflags) #(vi
11257 case $cf_add_cflags in #(vi
11259 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11261 CPPFLAGS=`echo "$CPPFLAGS" | \
11262 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11263 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11267 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
11272 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
11277 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11279 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11281 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11282 && test -z "${cf_tst_cflags}" \
11283 && cf_fix_cppflags=no
11288 if test -n "$cf_new_cflags" ; then
11290 CFLAGS="$CFLAGS $cf_new_cflags"
11293 if test -n "$cf_new_cppflags" ; then
11295 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
11298 if test -n "$cf_new_extra_cppflags" ; then
11300 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
11303 LIBS="$cf_pkgconfig_libs $LIBS"
11311 test -n "$verbose" && echo " ...before $LIBS" 1>&6
11313 echo "${as_me:-configure}:11313: testing ...before $LIBS ..." 1>&5
11315 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s,-lXt ,-lXt $X_PRE_LIBS ," -e 's/ / /g'`
11316 test -n "$verbose" && echo " ...after $LIBS" 1>&6
11318 echo "${as_me:-configure}:11318: testing ...after $LIBS ..." 1>&5
11332 LDFLAGS="$X_LIBS $LDFLAGS"
11334 test -n "$verbose" && echo " checking additions to CFLAGS" 1>&6
11336 echo "${as_me:-configure}:11336: testing checking additions to CFLAGS ..." 1>&5
11338 cf_check_cflags="$CFLAGS"
11339 cf_check_cppflags="$CPPFLAGS"
11344 cf_new_extra_cppflags=
11346 for cf_add_cflags in $X_CFLAGS
11348 case $cf_fix_cppflags in
11350 case $cf_add_cflags in #(vi
11351 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
11352 case $cf_add_cflags in
11354 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11356 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11357 && test -z "${cf_tst_cflags}" \
11358 && cf_fix_cppflags=yes
11360 if test $cf_fix_cppflags = yes ; then
11361 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11363 elif test "${cf_tst_cflags}" = "\"'" ; then
11364 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11369 case "$CPPFLAGS" in
11370 *$cf_add_cflags) #(vi
11373 case $cf_add_cflags in #(vi
11375 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11377 CPPFLAGS=`echo "$CPPFLAGS" | \
11378 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11379 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11383 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
11388 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
11393 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11395 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11397 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11398 && test -z "${cf_tst_cflags}" \
11399 && cf_fix_cppflags=no
11404 if test -n "$cf_new_cflags" ; then
11405 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
11407 echo "${as_me:-configure}:11407: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
11409 CFLAGS="$CFLAGS $cf_new_cflags"
11412 if test -n "$cf_new_cppflags" ; then
11413 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
11415 echo "${as_me:-configure}:11415: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
11417 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
11420 if test -n "$cf_new_extra_cppflags" ; then
11421 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
11423 echo "${as_me:-configure}:11423: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
11425 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
11428 if test "$cf_check_cflags" != "$CFLAGS" ; then
11429 cat >conftest.$ac_ext <<_ACEOF
11430 #line 11430 "configure"
11431 #include "confdefs.h"
11436 printf("Hello world");
11441 rm -f conftest.$ac_objext conftest$ac_exeext
11442 if { (eval echo "$as_me:11442: \"$ac_link\"") >&5
11443 (eval $ac_link) 2>&5
11445 echo "$as_me:11445: \$? = $ac_status" >&5
11446 (exit $ac_status); } &&
11447 { ac_try='test -s conftest$ac_exeext'
11448 { (eval echo "$as_me:11448: \"$ac_try\"") >&5
11449 (eval $ac_try) 2>&5
11451 echo "$as_me:11451: \$? = $ac_status" >&5
11452 (exit $ac_status); }; }; then
11455 echo "$as_me: failed program was:" >&5
11456 cat conftest.$ac_ext >&5
11457 test -n "$verbose" && echo " test-compile failed. Undoing change to \$CFLAGS" 1>&6
11459 echo "${as_me:-configure}:11459: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5
11461 if test "$cf_check_cppflags" != "$CPPFLAGS" ; then
11462 test -n "$verbose" && echo " but keeping change to \$CPPFLAGS" 1>&6
11464 echo "${as_me:-configure}:11464: testing but keeping change to \$CPPFLAGS ..." 1>&5
11467 CFLAGS="$cf_check_flags"
11469 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11472 echo "$as_me:11472: checking for XOpenDisplay" >&5
11473 echo $ECHO_N "checking for XOpenDisplay... $ECHO_C" >&6
11474 if test "${ac_cv_func_XOpenDisplay+set}" = set; then
11475 echo $ECHO_N "(cached) $ECHO_C" >&6
11477 cat >conftest.$ac_ext <<_ACEOF
11478 #line 11478 "configure"
11479 #include "confdefs.h"
11480 /* System header to define __stub macros and hopefully few prototypes,
11481 which can conflict with char XOpenDisplay (); below. */
11482 #include <assert.h>
11483 /* Override any gcc2 internal prototype to avoid an error. */
11487 /* We use char because int might match the return type of a gcc2
11488 builtin and then its argument prototype would still apply. */
11489 char XOpenDisplay ();
11495 /* The GNU C library defines this for functions which it implements
11496 to always fail with ENOSYS. Some functions are actually named
11497 something starting with __ and the normal name is an alias. */
11498 #if defined (__stub_XOpenDisplay) || defined (__stub___XOpenDisplay)
11508 rm -f conftest.$ac_objext conftest$ac_exeext
11509 if { (eval echo "$as_me:11509: \"$ac_link\"") >&5
11510 (eval $ac_link) 2>&5
11512 echo "$as_me:11512: \$? = $ac_status" >&5
11513 (exit $ac_status); } &&
11514 { ac_try='test -s conftest$ac_exeext'
11515 { (eval echo "$as_me:11515: \"$ac_try\"") >&5
11516 (eval $ac_try) 2>&5
11518 echo "$as_me:11518: \$? = $ac_status" >&5
11519 (exit $ac_status); }; }; then
11520 ac_cv_func_XOpenDisplay=yes
11522 echo "$as_me: failed program was:" >&5
11523 cat conftest.$ac_ext >&5
11524 ac_cv_func_XOpenDisplay=no
11526 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11528 echo "$as_me:11528: result: $ac_cv_func_XOpenDisplay" >&5
11529 echo "${ECHO_T}$ac_cv_func_XOpenDisplay" >&6
11530 if test $ac_cv_func_XOpenDisplay = yes; then
11534 echo "$as_me:11534: checking for XOpenDisplay in -lX11" >&5
11535 echo $ECHO_N "checking for XOpenDisplay in -lX11... $ECHO_C" >&6
11536 if test "${ac_cv_lib_X11_XOpenDisplay+set}" = set; then
11537 echo $ECHO_N "(cached) $ECHO_C" >&6
11539 ac_check_lib_save_LIBS=$LIBS
11540 LIBS="-lX11 $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
11541 cat >conftest.$ac_ext <<_ACEOF
11542 #line 11542 "configure"
11543 #include "confdefs.h"
11545 /* Override any gcc2 internal prototype to avoid an error. */
11549 /* We use char because int might match the return type of a gcc2
11550 builtin and then its argument prototype would still apply. */
11551 char XOpenDisplay ();
11560 rm -f conftest.$ac_objext conftest$ac_exeext
11561 if { (eval echo "$as_me:11561: \"$ac_link\"") >&5
11562 (eval $ac_link) 2>&5
11564 echo "$as_me:11564: \$? = $ac_status" >&5
11565 (exit $ac_status); } &&
11566 { ac_try='test -s conftest$ac_exeext'
11567 { (eval echo "$as_me:11567: \"$ac_try\"") >&5
11568 (eval $ac_try) 2>&5
11570 echo "$as_me:11570: \$? = $ac_status" >&5
11571 (exit $ac_status); }; }; then
11572 ac_cv_lib_X11_XOpenDisplay=yes
11574 echo "$as_me: failed program was:" >&5
11575 cat conftest.$ac_ext >&5
11576 ac_cv_lib_X11_XOpenDisplay=no
11578 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11579 LIBS=$ac_check_lib_save_LIBS
11581 echo "$as_me:11581: result: $ac_cv_lib_X11_XOpenDisplay" >&5
11582 echo "${ECHO_T}$ac_cv_lib_X11_XOpenDisplay" >&6
11583 if test $ac_cv_lib_X11_XOpenDisplay = yes; then
11589 echo "$as_me:11589: checking for XtAppInitialize" >&5
11590 echo $ECHO_N "checking for XtAppInitialize... $ECHO_C" >&6
11591 if test "${ac_cv_func_XtAppInitialize+set}" = set; then
11592 echo $ECHO_N "(cached) $ECHO_C" >&6
11594 cat >conftest.$ac_ext <<_ACEOF
11595 #line 11595 "configure"
11596 #include "confdefs.h"
11597 /* System header to define __stub macros and hopefully few prototypes,
11598 which can conflict with char XtAppInitialize (); below. */
11599 #include <assert.h>
11600 /* Override any gcc2 internal prototype to avoid an error. */
11604 /* We use char because int might match the return type of a gcc2
11605 builtin and then its argument prototype would still apply. */
11606 char XtAppInitialize ();
11612 /* The GNU C library defines this for functions which it implements
11613 to always fail with ENOSYS. Some functions are actually named
11614 something starting with __ and the normal name is an alias. */
11615 #if defined (__stub_XtAppInitialize) || defined (__stub___XtAppInitialize)
11618 f = XtAppInitialize;
11625 rm -f conftest.$ac_objext conftest$ac_exeext
11626 if { (eval echo "$as_me:11626: \"$ac_link\"") >&5
11627 (eval $ac_link) 2>&5
11629 echo "$as_me:11629: \$? = $ac_status" >&5
11630 (exit $ac_status); } &&
11631 { ac_try='test -s conftest$ac_exeext'
11632 { (eval echo "$as_me:11632: \"$ac_try\"") >&5
11633 (eval $ac_try) 2>&5
11635 echo "$as_me:11635: \$? = $ac_status" >&5
11636 (exit $ac_status); }; }; then
11637 ac_cv_func_XtAppInitialize=yes
11639 echo "$as_me: failed program was:" >&5
11640 cat conftest.$ac_ext >&5
11641 ac_cv_func_XtAppInitialize=no
11643 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11645 echo "$as_me:11645: result: $ac_cv_func_XtAppInitialize" >&5
11646 echo "${ECHO_T}$ac_cv_func_XtAppInitialize" >&6
11647 if test $ac_cv_func_XtAppInitialize = yes; then
11651 echo "$as_me:11651: checking for XtAppInitialize in -lXt" >&5
11652 echo $ECHO_N "checking for XtAppInitialize in -lXt... $ECHO_C" >&6
11653 if test "${ac_cv_lib_Xt_XtAppInitialize+set}" = set; then
11654 echo $ECHO_N "(cached) $ECHO_C" >&6
11656 ac_check_lib_save_LIBS=$LIBS
11657 LIBS="-lXt $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
11658 cat >conftest.$ac_ext <<_ACEOF
11659 #line 11659 "configure"
11660 #include "confdefs.h"
11662 /* Override any gcc2 internal prototype to avoid an error. */
11666 /* We use char because int might match the return type of a gcc2
11667 builtin and then its argument prototype would still apply. */
11668 char XtAppInitialize ();
11672 XtAppInitialize ();
11677 rm -f conftest.$ac_objext conftest$ac_exeext
11678 if { (eval echo "$as_me:11678: \"$ac_link\"") >&5
11679 (eval $ac_link) 2>&5
11681 echo "$as_me:11681: \$? = $ac_status" >&5
11682 (exit $ac_status); } &&
11683 { ac_try='test -s conftest$ac_exeext'
11684 { (eval echo "$as_me:11684: \"$ac_try\"") >&5
11685 (eval $ac_try) 2>&5
11687 echo "$as_me:11687: \$? = $ac_status" >&5
11688 (exit $ac_status); }; }; then
11689 ac_cv_lib_Xt_XtAppInitialize=yes
11691 echo "$as_me: failed program was:" >&5
11692 cat conftest.$ac_ext >&5
11693 ac_cv_lib_Xt_XtAppInitialize=no
11695 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11696 LIBS=$ac_check_lib_save_LIBS
11698 echo "$as_me:11698: result: $ac_cv_lib_Xt_XtAppInitialize" >&5
11699 echo "${ECHO_T}$ac_cv_lib_Xt_XtAppInitialize" >&6
11700 if test $ac_cv_lib_Xt_XtAppInitialize = yes; then
11701 cat >>confdefs.h <<\EOF
11702 #define HAVE_LIBXT 1
11706 LIBS="-lXt $X_PRE_LIBS $LIBS $X_EXTRA_LIBS"
11713 if test $cf_have_X_LIBS = no ; then
11714 { echo "$as_me:11714: WARNING: Unable to successfully link X Toolkit library (-lXt) with
11715 test program. You will have to check and add the proper libraries by hand
11717 echo "$as_me: WARNING: Unable to successfully link X Toolkit library (-lXt) with
11718 test program. You will have to check and add the proper libraries by hand
11719 to makefile." >&2;}
11722 cf_x_athena_root=$cf_x_athena
11725 for cf_path in default \
11726 /usr/contrib/X11R6 \
11727 /usr/contrib/X11R5 \
11731 if test -z "$cf_x_athena_inc" ; then
11732 cf_save="$CPPFLAGS"
11733 cf_test=X11/$cf_x_athena_root/SimpleMenu.h
11734 if test $cf_path != default ; then
11735 CPPFLAGS="$cf_save -I$cf_path/include"
11736 echo "$as_me:11736: checking for $cf_test in $cf_path" >&5
11737 echo $ECHO_N "checking for $cf_test in $cf_path... $ECHO_C" >&6
11739 echo "$as_me:11739: checking for $cf_test" >&5
11740 echo $ECHO_N "checking for $cf_test... $ECHO_C" >&6
11742 cat >conftest.$ac_ext <<_ACEOF
11743 #line 11743 "configure"
11744 #include "confdefs.h"
11746 #include <X11/Intrinsic.h>
11747 #include <$cf_test>
11756 rm -f conftest.$ac_objext
11757 if { (eval echo "$as_me:11757: \"$ac_compile\"") >&5
11758 (eval $ac_compile) 2>&5
11760 echo "$as_me:11760: \$? = $ac_status" >&5
11761 (exit $ac_status); } &&
11762 { ac_try='test -s conftest.$ac_objext'
11763 { (eval echo "$as_me:11763: \"$ac_try\"") >&5
11764 (eval $ac_try) 2>&5
11766 echo "$as_me:11766: \$? = $ac_status" >&5
11767 (exit $ac_status); }; }; then
11770 echo "$as_me: failed program was:" >&5
11771 cat conftest.$ac_ext >&5
11774 rm -f conftest.$ac_objext conftest.$ac_ext
11775 echo "$as_me:11775: result: $cf_result" >&5
11776 echo "${ECHO_T}$cf_result" >&6
11777 if test "$cf_result" = yes ; then
11778 cf_x_athena_inc=$cf_path
11781 CPPFLAGS="$cf_save"
11786 if test -z "$cf_x_athena_inc" ; then
11787 { echo "$as_me:11787: WARNING: Unable to successfully find Athena header files with test program" >&5
11788 echo "$as_me: WARNING: Unable to successfully find Athena header files with test program" >&2;}
11789 elif test "$cf_x_athena_inc" != default ; then
11790 CPPFLAGS="$CPPFLAGS -I$cf_x_athena_inc"
11793 cf_x_athena_root=$cf_x_athena
11796 for cf_path in default \
11797 /usr/contrib/X11R6 \
11798 /usr/contrib/X11R5 \
11803 "-l$cf_x_athena_root -lXmu" \
11804 "-l$cf_x_athena_root -lXpm -lXmu" \
11805 "-l${cf_x_athena_root}_s -lXmu_s"
11807 if test -z "$cf_x_athena_lib" ; then
11809 cf_test=XawSimpleMenuAddGlobalActions
11810 if test $cf_path != default ; then
11811 LIBS="-L$cf_path/lib $cf_lib $LIBS"
11812 echo "$as_me:11812: checking for $cf_lib in $cf_path" >&5
11813 echo $ECHO_N "checking for $cf_lib in $cf_path... $ECHO_C" >&6
11815 LIBS="$cf_lib $LIBS"
11816 echo "$as_me:11816: checking for $cf_test in $cf_lib" >&5
11817 echo $ECHO_N "checking for $cf_test in $cf_lib... $ECHO_C" >&6
11819 cat >conftest.$ac_ext <<_ACEOF
11820 #line 11820 "configure"
11821 #include "confdefs.h"
11831 rm -f conftest.$ac_objext conftest$ac_exeext
11832 if { (eval echo "$as_me:11832: \"$ac_link\"") >&5
11833 (eval $ac_link) 2>&5
11835 echo "$as_me:11835: \$? = $ac_status" >&5
11836 (exit $ac_status); } &&
11837 { ac_try='test -s conftest$ac_exeext'
11838 { (eval echo "$as_me:11838: \"$ac_try\"") >&5
11839 (eval $ac_try) 2>&5
11841 echo "$as_me:11841: \$? = $ac_status" >&5
11842 (exit $ac_status); }; }; then
11845 echo "$as_me: failed program was:" >&5
11846 cat conftest.$ac_ext >&5
11849 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11850 echo "$as_me:11850: result: $cf_result" >&5
11851 echo "${ECHO_T}$cf_result" >&6
11852 if test "$cf_result" = yes ; then
11853 cf_x_athena_lib="$cf_lib"
11861 if test -z "$cf_x_athena_lib" ; then
11862 { { echo "$as_me:11862: error: Unable to successfully link Athena library (-l$cf_x_athena_root) with test program" >&5
11863 echo "$as_me: error: Unable to successfully link Athena library (-l$cf_x_athena_root) with test program" >&2;}
11864 { (exit 1); exit 1; }; }
11867 cf_x_athena_LIBS=`echo "HAVE_LIB_$cf_x_athena" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
11869 cat >>confdefs.h <<EOF
11870 #define $cf_x_athena_LIBS 1
11875 for ac_prog in xcurses-config
11877 # Extract the first word of "$ac_prog", so it can be a program name with args.
11878 set dummy $ac_prog; ac_word=$2
11879 echo "$as_me:11879: checking for $ac_word" >&5
11880 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
11881 if test "${ac_cv_path_XCURSES_CONFIG+set}" = set; then
11882 echo $ECHO_N "(cached) $ECHO_C" >&6
11884 case $XCURSES_CONFIG in
11886 ac_cv_path_XCURSES_CONFIG="$XCURSES_CONFIG" # Let the user override the test with a path.
11889 ac_save_IFS=$IFS; IFS=$ac_path_separator
11891 for ac_dir in $ac_dummy; do
11893 test -z "$ac_dir" && ac_dir=.
11894 if $as_executable_p "$ac_dir/$ac_word"; then
11895 ac_cv_path_XCURSES_CONFIG="$ac_dir/$ac_word"
11896 echo "$as_me:11896: found $ac_dir/$ac_word" >&5
11904 XCURSES_CONFIG=$ac_cv_path_XCURSES_CONFIG
11906 if test -n "$XCURSES_CONFIG"; then
11907 echo "$as_me:11907: result: $XCURSES_CONFIG" >&5
11908 echo "${ECHO_T}$XCURSES_CONFIG" >&6
11910 echo "$as_me:11910: result: no" >&5
11911 echo "${ECHO_T}no" >&6
11914 test -n "$XCURSES_CONFIG" && break
11916 test -n "$XCURSES_CONFIG" || XCURSES_CONFIG="none"
11918 if test "$XCURSES_CONFIG" != none ; then
11920 CPPFLAGS="$CPPFLAGS `$XCURSES_CONFIG --cflags`"
11921 LIBS="`$XCURSES_CONFIG --libs` $LIBS"
11923 cf_cv_lib_XCurses=yes
11927 LDFLAGS="$LDFLAGS $X_LIBS"
11929 test -n "$verbose" && echo " checking additions to CFLAGS" 1>&6
11931 echo "${as_me:-configure}:11931: testing checking additions to CFLAGS ..." 1>&5
11933 cf_check_cflags="$CFLAGS"
11934 cf_check_cppflags="$CPPFLAGS"
11939 cf_new_extra_cppflags=
11941 for cf_add_cflags in $X_CFLAGS
11943 case $cf_fix_cppflags in
11945 case $cf_add_cflags in #(vi
11946 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
11947 case $cf_add_cflags in
11949 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11951 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11952 && test -z "${cf_tst_cflags}" \
11953 && cf_fix_cppflags=yes
11955 if test $cf_fix_cppflags = yes ; then
11956 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11958 elif test "${cf_tst_cflags}" = "\"'" ; then
11959 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11964 case "$CPPFLAGS" in
11965 *$cf_add_cflags) #(vi
11968 case $cf_add_cflags in #(vi
11970 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11972 CPPFLAGS=`echo "$CPPFLAGS" | \
11973 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11974 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11978 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
11983 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
11988 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11990 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11992 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11993 && test -z "${cf_tst_cflags}" \
11994 && cf_fix_cppflags=no
11999 if test -n "$cf_new_cflags" ; then
12000 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
12002 echo "${as_me:-configure}:12002: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
12004 CFLAGS="$CFLAGS $cf_new_cflags"
12007 if test -n "$cf_new_cppflags" ; then
12008 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
12010 echo "${as_me:-configure}:12010: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
12012 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
12015 if test -n "$cf_new_extra_cppflags" ; then
12016 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
12018 echo "${as_me:-configure}:12018: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
12020 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
12023 if test "$cf_check_cflags" != "$CFLAGS" ; then
12024 cat >conftest.$ac_ext <<_ACEOF
12025 #line 12025 "configure"
12026 #include "confdefs.h"
12031 printf("Hello world");
12036 rm -f conftest.$ac_objext conftest$ac_exeext
12037 if { (eval echo "$as_me:12037: \"$ac_link\"") >&5
12038 (eval $ac_link) 2>&5
12040 echo "$as_me:12040: \$? = $ac_status" >&5
12041 (exit $ac_status); } &&
12042 { ac_try='test -s conftest$ac_exeext'
12043 { (eval echo "$as_me:12043: \"$ac_try\"") >&5
12044 (eval $ac_try) 2>&5
12046 echo "$as_me:12046: \$? = $ac_status" >&5
12047 (exit $ac_status); }; }; then
12050 echo "$as_me: failed program was:" >&5
12051 cat conftest.$ac_ext >&5
12052 test -n "$verbose" && echo " test-compile failed. Undoing change to \$CFLAGS" 1>&6
12054 echo "${as_me:-configure}:12054: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5
12056 if test "$cf_check_cppflags" != "$CPPFLAGS" ; then
12057 test -n "$verbose" && echo " but keeping change to \$CPPFLAGS" 1>&6
12059 echo "${as_me:-configure}:12059: testing but keeping change to \$CPPFLAGS ..." 1>&5
12062 CFLAGS="$cf_check_flags"
12064 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12067 echo "$as_me:12067: checking for XOpenDisplay in -lX11" >&5
12068 echo $ECHO_N "checking for XOpenDisplay in -lX11... $ECHO_C" >&6
12069 if test "${ac_cv_lib_X11_XOpenDisplay+set}" = set; then
12070 echo $ECHO_N "(cached) $ECHO_C" >&6
12072 ac_check_lib_save_LIBS=$LIBS
12073 LIBS="-lX11 $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
12074 cat >conftest.$ac_ext <<_ACEOF
12075 #line 12075 "configure"
12076 #include "confdefs.h"
12078 /* Override any gcc2 internal prototype to avoid an error. */
12082 /* We use char because int might match the return type of a gcc2
12083 builtin and then its argument prototype would still apply. */
12084 char XOpenDisplay ();
12093 rm -f conftest.$ac_objext conftest$ac_exeext
12094 if { (eval echo "$as_me:12094: \"$ac_link\"") >&5
12095 (eval $ac_link) 2>&5
12097 echo "$as_me:12097: \$? = $ac_status" >&5
12098 (exit $ac_status); } &&
12099 { ac_try='test -s conftest$ac_exeext'
12100 { (eval echo "$as_me:12100: \"$ac_try\"") >&5
12101 (eval $ac_try) 2>&5
12103 echo "$as_me:12103: \$? = $ac_status" >&5
12104 (exit $ac_status); }; }; then
12105 ac_cv_lib_X11_XOpenDisplay=yes
12107 echo "$as_me: failed program was:" >&5
12108 cat conftest.$ac_ext >&5
12109 ac_cv_lib_X11_XOpenDisplay=no
12111 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12112 LIBS=$ac_check_lib_save_LIBS
12114 echo "$as_me:12114: result: $ac_cv_lib_X11_XOpenDisplay" >&5
12115 echo "${ECHO_T}$ac_cv_lib_X11_XOpenDisplay" >&6
12116 if test $ac_cv_lib_X11_XOpenDisplay = yes; then
12120 echo "$as_me:12120: checking for XCurses library" >&5
12121 echo $ECHO_N "checking for XCurses library... $ECHO_C" >&6
12122 if test "${cf_cv_lib_XCurses+set}" = set; then
12123 echo $ECHO_N "(cached) $ECHO_C" >&6
12126 LIBS="-lXCurses $LIBS"
12127 cat >conftest.$ac_ext <<_ACEOF
12128 #line 12128 "configure"
12129 #include "confdefs.h"
12131 #include <xcurses.h>
12132 char *XCursesProgramName = "test";
12142 rm -f conftest.$ac_objext conftest$ac_exeext
12143 if { (eval echo "$as_me:12143: \"$ac_link\"") >&5
12144 (eval $ac_link) 2>&5
12146 echo "$as_me:12146: \$? = $ac_status" >&5
12147 (exit $ac_status); } &&
12148 { ac_try='test -s conftest$ac_exeext'
12149 { (eval echo "$as_me:12149: \"$ac_try\"") >&5
12150 (eval $ac_try) 2>&5
12152 echo "$as_me:12152: \$? = $ac_status" >&5
12153 (exit $ac_status); }; }; then
12154 cf_cv_lib_XCurses=yes
12156 echo "$as_me: failed program was:" >&5
12157 cat conftest.$ac_ext >&5
12158 cf_cv_lib_XCurses=no
12160 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12163 echo "$as_me:12163: result: $cf_cv_lib_XCurses" >&5
12164 echo "${ECHO_T}$cf_cv_lib_XCurses" >&6
12168 if test $cf_cv_lib_XCurses = yes ; then
12169 cat >>confdefs.h <<\EOF
12173 cat >>confdefs.h <<\EOF
12177 echo "$as_me:12177: checking for xcurses.h" >&5
12178 echo $ECHO_N "checking for xcurses.h... $ECHO_C" >&6
12179 if test "${ac_cv_header_xcurses_h+set}" = set; then
12180 echo $ECHO_N "(cached) $ECHO_C" >&6
12182 cat >conftest.$ac_ext <<_ACEOF
12183 #line 12183 "configure"
12184 #include "confdefs.h"
12185 #include <xcurses.h>
12187 if { (eval echo "$as_me:12187: \"$ac_cpp conftest.$ac_ext\"") >&5
12188 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12190 egrep -v '^ *\+' conftest.er1 >conftest.err
12192 cat conftest.err >&5
12193 echo "$as_me:12193: \$? = $ac_status" >&5
12194 (exit $ac_status); } >/dev/null; then
12195 if test -s conftest.err; then
12196 ac_cpp_err=$ac_c_preproc_warn_flag
12203 if test -z "$ac_cpp_err"; then
12204 ac_cv_header_xcurses_h=yes
12206 echo "$as_me: failed program was:" >&5
12207 cat conftest.$ac_ext >&5
12208 ac_cv_header_xcurses_h=no
12210 rm -f conftest.err conftest.$ac_ext
12212 echo "$as_me:12212: result: $ac_cv_header_xcurses_h" >&5
12213 echo "${ECHO_T}$ac_cv_header_xcurses_h" >&6
12214 if test $ac_cv_header_xcurses_h = yes; then
12215 cat >>confdefs.h <<\EOF
12216 #define HAVE_XCURSES 1
12222 { { echo "$as_me:12222: error: Cannot link with XCurses" >&5
12223 echo "$as_me: error: Cannot link with XCurses" >&2;}
12224 { (exit 1); exit 1; }; }
12230 case $cf_cv_screen in #(vi
12234 # look for curses-related libraries
12236 as_ac_Lib=`echo "ac_cv_lib_panel$cf_cv_libtype''_new_panel" | $as_tr_sh`
12237 echo "$as_me:12237: checking for new_panel in -lpanel$cf_cv_libtype" >&5
12238 echo $ECHO_N "checking for new_panel in -lpanel$cf_cv_libtype... $ECHO_C" >&6
12239 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
12240 echo $ECHO_N "(cached) $ECHO_C" >&6
12242 ac_check_lib_save_LIBS=$LIBS
12243 LIBS="-lpanel$cf_cv_libtype $LIBS"
12244 cat >conftest.$ac_ext <<_ACEOF
12245 #line 12245 "configure"
12246 #include "confdefs.h"
12248 /* Override any gcc2 internal prototype to avoid an error. */
12252 /* We use char because int might match the return type of a gcc2
12253 builtin and then its argument prototype would still apply. */
12263 rm -f conftest.$ac_objext conftest$ac_exeext
12264 if { (eval echo "$as_me:12264: \"$ac_link\"") >&5
12265 (eval $ac_link) 2>&5
12267 echo "$as_me:12267: \$? = $ac_status" >&5
12268 (exit $ac_status); } &&
12269 { ac_try='test -s conftest$ac_exeext'
12270 { (eval echo "$as_me:12270: \"$ac_try\"") >&5
12271 (eval $ac_try) 2>&5
12273 echo "$as_me:12273: \$? = $ac_status" >&5
12274 (exit $ac_status); }; }; then
12275 eval "$as_ac_Lib=yes"
12277 echo "$as_me: failed program was:" >&5
12278 cat conftest.$ac_ext >&5
12279 eval "$as_ac_Lib=no"
12281 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12282 LIBS=$ac_check_lib_save_LIBS
12284 echo "$as_me:12284: result: `eval echo '${'$as_ac_Lib'}'`" >&5
12285 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
12286 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
12287 cat >>confdefs.h <<EOF
12288 #define `echo "HAVE_LIBpanel$cf_cv_libtype" | $as_tr_cpp` 1
12291 LIBS="-lpanel$cf_cv_libtype $LIBS"
12295 as_ac_Lib=`echo "ac_cv_lib_menu$cf_cv_libtype''_menu_driver" | $as_tr_sh`
12296 echo "$as_me:12296: checking for menu_driver in -lmenu$cf_cv_libtype" >&5
12297 echo $ECHO_N "checking for menu_driver in -lmenu$cf_cv_libtype... $ECHO_C" >&6
12298 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
12299 echo $ECHO_N "(cached) $ECHO_C" >&6
12301 ac_check_lib_save_LIBS=$LIBS
12302 LIBS="-lmenu$cf_cv_libtype $LIBS"
12303 cat >conftest.$ac_ext <<_ACEOF
12304 #line 12304 "configure"
12305 #include "confdefs.h"
12307 /* Override any gcc2 internal prototype to avoid an error. */
12311 /* We use char because int might match the return type of a gcc2
12312 builtin and then its argument prototype would still apply. */
12313 char menu_driver ();
12322 rm -f conftest.$ac_objext conftest$ac_exeext
12323 if { (eval echo "$as_me:12323: \"$ac_link\"") >&5
12324 (eval $ac_link) 2>&5
12326 echo "$as_me:12326: \$? = $ac_status" >&5
12327 (exit $ac_status); } &&
12328 { ac_try='test -s conftest$ac_exeext'
12329 { (eval echo "$as_me:12329: \"$ac_try\"") >&5
12330 (eval $ac_try) 2>&5
12332 echo "$as_me:12332: \$? = $ac_status" >&5
12333 (exit $ac_status); }; }; then
12334 eval "$as_ac_Lib=yes"
12336 echo "$as_me: failed program was:" >&5
12337 cat conftest.$ac_ext >&5
12338 eval "$as_ac_Lib=no"
12340 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12341 LIBS=$ac_check_lib_save_LIBS
12343 echo "$as_me:12343: result: `eval echo '${'$as_ac_Lib'}'`" >&5
12344 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
12345 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
12346 cat >>confdefs.h <<EOF
12347 #define `echo "HAVE_LIBmenu$cf_cv_libtype" | $as_tr_cpp` 1
12350 LIBS="-lmenu$cf_cv_libtype $LIBS"
12354 as_ac_Lib=`echo "ac_cv_lib_form$cf_cv_libtype''_form_driver" | $as_tr_sh`
12355 echo "$as_me:12355: checking for form_driver in -lform$cf_cv_libtype" >&5
12356 echo $ECHO_N "checking for form_driver in -lform$cf_cv_libtype... $ECHO_C" >&6
12357 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
12358 echo $ECHO_N "(cached) $ECHO_C" >&6
12360 ac_check_lib_save_LIBS=$LIBS
12361 LIBS="-lform$cf_cv_libtype $LIBS"
12362 cat >conftest.$ac_ext <<_ACEOF
12363 #line 12363 "configure"
12364 #include "confdefs.h"
12366 /* Override any gcc2 internal prototype to avoid an error. */
12370 /* We use char because int might match the return type of a gcc2
12371 builtin and then its argument prototype would still apply. */
12372 char form_driver ();
12381 rm -f conftest.$ac_objext conftest$ac_exeext
12382 if { (eval echo "$as_me:12382: \"$ac_link\"") >&5
12383 (eval $ac_link) 2>&5
12385 echo "$as_me:12385: \$? = $ac_status" >&5
12386 (exit $ac_status); } &&
12387 { ac_try='test -s conftest$ac_exeext'
12388 { (eval echo "$as_me:12388: \"$ac_try\"") >&5
12389 (eval $ac_try) 2>&5
12391 echo "$as_me:12391: \$? = $ac_status" >&5
12392 (exit $ac_status); }; }; then
12393 eval "$as_ac_Lib=yes"
12395 echo "$as_me: failed program was:" >&5
12396 cat conftest.$ac_ext >&5
12397 eval "$as_ac_Lib=no"
12399 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12400 LIBS=$ac_check_lib_save_LIBS
12402 echo "$as_me:12402: result: `eval echo '${'$as_ac_Lib'}'`" >&5
12403 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
12404 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
12405 cat >>confdefs.h <<EOF
12406 #define `echo "HAVE_LIBform$cf_cv_libtype" | $as_tr_cpp` 1
12409 LIBS="-lform$cf_cv_libtype $LIBS"
12413 # look for curses-related headers
12424 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12425 echo "$as_me:12425: checking for $ac_header" >&5
12426 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12427 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12428 echo $ECHO_N "(cached) $ECHO_C" >&6
12430 cat >conftest.$ac_ext <<_ACEOF
12431 #line 12431 "configure"
12432 #include "confdefs.h"
12433 #include <$ac_header>
12435 if { (eval echo "$as_me:12435: \"$ac_cpp conftest.$ac_ext\"") >&5
12436 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12438 egrep -v '^ *\+' conftest.er1 >conftest.err
12440 cat conftest.err >&5
12441 echo "$as_me:12441: \$? = $ac_status" >&5
12442 (exit $ac_status); } >/dev/null; then
12443 if test -s conftest.err; then
12444 ac_cpp_err=$ac_c_preproc_warn_flag
12451 if test -z "$ac_cpp_err"; then
12452 eval "$as_ac_Header=yes"
12454 echo "$as_me: failed program was:" >&5
12455 cat conftest.$ac_ext >&5
12456 eval "$as_ac_Header=no"
12458 rm -f conftest.err conftest.$ac_ext
12460 echo "$as_me:12460: result: `eval echo '${'$as_ac_Header'}'`" >&5
12461 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12462 if test `eval echo '${'$as_ac_Header'}'` = yes; then
12463 cat >>confdefs.h <<EOF
12464 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12473 echo "$as_me:12473: checking return type of signal handlers" >&5
12474 echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6
12475 if test "${ac_cv_type_signal+set}" = set; then
12476 echo $ECHO_N "(cached) $ECHO_C" >&6
12478 cat >conftest.$ac_ext <<_ACEOF
12479 #line 12479 "configure"
12480 #include "confdefs.h"
12481 #include <sys/types.h>
12482 #include <signal.h>
12487 extern "C" void (*signal (int, void (*)(int)))(int);
12489 void (*signal ()) ();
12500 rm -f conftest.$ac_objext
12501 if { (eval echo "$as_me:12501: \"$ac_compile\"") >&5
12502 (eval $ac_compile) 2>&5
12504 echo "$as_me:12504: \$? = $ac_status" >&5
12505 (exit $ac_status); } &&
12506 { ac_try='test -s conftest.$ac_objext'
12507 { (eval echo "$as_me:12507: \"$ac_try\"") >&5
12508 (eval $ac_try) 2>&5
12510 echo "$as_me:12510: \$? = $ac_status" >&5
12511 (exit $ac_status); }; }; then
12512 ac_cv_type_signal=void
12514 echo "$as_me: failed program was:" >&5
12515 cat conftest.$ac_ext >&5
12516 ac_cv_type_signal=int
12518 rm -f conftest.$ac_objext conftest.$ac_ext
12520 echo "$as_me:12520: result: $ac_cv_type_signal" >&5
12521 echo "${ECHO_T}$ac_cv_type_signal" >&6
12523 cat >>confdefs.h <<EOF
12524 #define RETSIGTYPE $ac_cv_type_signal
12527 echo "$as_me:12527: checking for ANSI C header files" >&5
12528 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
12529 if test "${ac_cv_header_stdc+set}" = set; then
12530 echo $ECHO_N "(cached) $ECHO_C" >&6
12532 cat >conftest.$ac_ext <<_ACEOF
12533 #line 12533 "configure"
12534 #include "confdefs.h"
12535 #include <stdlib.h>
12536 #include <stdarg.h>
12537 #include <string.h>
12541 if { (eval echo "$as_me:12541: \"$ac_cpp conftest.$ac_ext\"") >&5
12542 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12544 egrep -v '^ *\+' conftest.er1 >conftest.err
12546 cat conftest.err >&5
12547 echo "$as_me:12547: \$? = $ac_status" >&5
12548 (exit $ac_status); } >/dev/null; then
12549 if test -s conftest.err; then
12550 ac_cpp_err=$ac_c_preproc_warn_flag
12557 if test -z "$ac_cpp_err"; then
12558 ac_cv_header_stdc=yes
12560 echo "$as_me: failed program was:" >&5
12561 cat conftest.$ac_ext >&5
12562 ac_cv_header_stdc=no
12564 rm -f conftest.err conftest.$ac_ext
12566 if test $ac_cv_header_stdc = yes; then
12567 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
12568 cat >conftest.$ac_ext <<_ACEOF
12569 #line 12569 "configure"
12570 #include "confdefs.h"
12571 #include <string.h>
12574 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12575 egrep "memchr" >/dev/null 2>&1; then
12578 ac_cv_header_stdc=no
12584 if test $ac_cv_header_stdc = yes; then
12585 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
12586 cat >conftest.$ac_ext <<_ACEOF
12587 #line 12587 "configure"
12588 #include "confdefs.h"
12589 #include <stdlib.h>
12592 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12593 egrep "free" >/dev/null 2>&1; then
12596 ac_cv_header_stdc=no
12602 if test $ac_cv_header_stdc = yes; then
12603 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
12604 if test "$cross_compiling" = yes; then
12607 cat >conftest.$ac_ext <<_ACEOF
12608 #line 12608 "configure"
12609 #include "confdefs.h"
12611 #if ((' ' & 0x0FF) == 0x020)
12612 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
12613 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
12615 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
12616 || ('j' <= (c) && (c) <= 'r') \
12617 || ('s' <= (c) && (c) <= 'z'))
12618 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
12621 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
12626 for (i = 0; i < 256; i++)
12627 if (XOR (islower (i), ISLOWER (i))
12628 || toupper (i) != TOUPPER (i))
12629 $ac_main_return(2);
12630 $ac_main_return (0);
12633 rm -f conftest$ac_exeext
12634 if { (eval echo "$as_me:12634: \"$ac_link\"") >&5
12635 (eval $ac_link) 2>&5
12637 echo "$as_me:12637: \$? = $ac_status" >&5
12638 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
12639 { (eval echo "$as_me:12639: \"$ac_try\"") >&5
12640 (eval $ac_try) 2>&5
12642 echo "$as_me:12642: \$? = $ac_status" >&5
12643 (exit $ac_status); }; }; then
12646 echo "$as_me: program exited with status $ac_status" >&5
12647 echo "$as_me: failed program was:" >&5
12648 cat conftest.$ac_ext >&5
12649 ac_cv_header_stdc=no
12651 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
12655 echo "$as_me:12655: result: $ac_cv_header_stdc" >&5
12656 echo "${ECHO_T}$ac_cv_header_stdc" >&6
12657 if test $ac_cv_header_stdc = yes; then
12659 cat >>confdefs.h <<\EOF
12660 #define STDC_HEADERS 1
12665 echo "$as_me:12665: checking whether time.h and sys/time.h may both be included" >&5
12666 echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
12667 if test "${ac_cv_header_time+set}" = set; then
12668 echo $ECHO_N "(cached) $ECHO_C" >&6
12670 cat >conftest.$ac_ext <<_ACEOF
12671 #line 12671 "configure"
12672 #include "confdefs.h"
12673 #include <sys/types.h>
12674 #include <sys/time.h>
12680 if ((struct tm *) 0)
12686 rm -f conftest.$ac_objext
12687 if { (eval echo "$as_me:12687: \"$ac_compile\"") >&5
12688 (eval $ac_compile) 2>&5
12690 echo "$as_me:12690: \$? = $ac_status" >&5
12691 (exit $ac_status); } &&
12692 { ac_try='test -s conftest.$ac_objext'
12693 { (eval echo "$as_me:12693: \"$ac_try\"") >&5
12694 (eval $ac_try) 2>&5
12696 echo "$as_me:12696: \$? = $ac_status" >&5
12697 (exit $ac_status); }; }; then
12698 ac_cv_header_time=yes
12700 echo "$as_me: failed program was:" >&5
12701 cat conftest.$ac_ext >&5
12702 ac_cv_header_time=no
12704 rm -f conftest.$ac_objext conftest.$ac_ext
12706 echo "$as_me:12706: result: $ac_cv_header_time" >&5
12707 echo "${ECHO_T}$ac_cv_header_time" >&6
12708 if test $ac_cv_header_time = yes; then
12710 cat >>confdefs.h <<\EOF
12711 #define TIME_WITH_SYS_TIME 1
12727 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12728 echo "$as_me:12728: checking for $ac_header" >&5
12729 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12730 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12731 echo $ECHO_N "(cached) $ECHO_C" >&6
12733 cat >conftest.$ac_ext <<_ACEOF
12734 #line 12734 "configure"
12735 #include "confdefs.h"
12736 #include <$ac_header>
12738 if { (eval echo "$as_me:12738: \"$ac_cpp conftest.$ac_ext\"") >&5
12739 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12741 egrep -v '^ *\+' conftest.er1 >conftest.err
12743 cat conftest.err >&5
12744 echo "$as_me:12744: \$? = $ac_status" >&5
12745 (exit $ac_status); } >/dev/null; then
12746 if test -s conftest.err; then
12747 ac_cpp_err=$ac_c_preproc_warn_flag
12754 if test -z "$ac_cpp_err"; then
12755 eval "$as_ac_Header=yes"
12757 echo "$as_me: failed program was:" >&5
12758 cat conftest.$ac_ext >&5
12759 eval "$as_ac_Header=no"
12761 rm -f conftest.err conftest.$ac_ext
12763 echo "$as_me:12763: result: `eval echo '${'$as_ac_Header'}'`" >&5
12764 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12765 if test `eval echo '${'$as_ac_Header'}'` = yes; then
12766 cat >>confdefs.h <<EOF
12767 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12786 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12787 echo "$as_me:12787: checking for $ac_func" >&5
12788 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12789 if eval "test \"\${$as_ac_var+set}\" = set"; then
12790 echo $ECHO_N "(cached) $ECHO_C" >&6
12792 cat >conftest.$ac_ext <<_ACEOF
12793 #line 12793 "configure"
12794 #include "confdefs.h"
12795 /* System header to define __stub macros and hopefully few prototypes,
12796 which can conflict with char $ac_func (); below. */
12797 #include <assert.h>
12798 /* Override any gcc2 internal prototype to avoid an error. */
12802 /* We use char because int might match the return type of a gcc2
12803 builtin and then its argument prototype would still apply. */
12810 /* The GNU C library defines this for functions which it implements
12811 to always fail with ENOSYS. Some functions are actually named
12812 something starting with __ and the normal name is an alias. */
12813 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12823 rm -f conftest.$ac_objext conftest$ac_exeext
12824 if { (eval echo "$as_me:12824: \"$ac_link\"") >&5
12825 (eval $ac_link) 2>&5
12827 echo "$as_me:12827: \$? = $ac_status" >&5
12828 (exit $ac_status); } &&
12829 { ac_try='test -s conftest$ac_exeext'
12830 { (eval echo "$as_me:12830: \"$ac_try\"") >&5
12831 (eval $ac_try) 2>&5
12833 echo "$as_me:12833: \$? = $ac_status" >&5
12834 (exit $ac_status); }; }; then
12835 eval "$as_ac_var=yes"
12837 echo "$as_me: failed program was:" >&5
12838 cat conftest.$ac_ext >&5
12839 eval "$as_ac_var=no"
12841 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12843 echo "$as_me:12843: result: `eval echo '${'$as_ac_var'}'`" >&5
12844 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12845 if test `eval echo '${'$as_ac_var'}'` = yes; then
12846 cat >>confdefs.h <<EOF
12847 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12853 echo "$as_me:12853: checking if we must define _XOPEN_SOURCE_EXTENDED" >&5
12854 echo $ECHO_N "checking if we must define _XOPEN_SOURCE_EXTENDED... $ECHO_C" >&6
12855 if test "${cf_cv_need_xopen_extension+set}" = set; then
12856 echo $ECHO_N "(cached) $ECHO_C" >&6
12859 cat >conftest.$ac_ext <<_ACEOF
12860 #line 12860 "configure"
12861 #include "confdefs.h"
12863 #include <stdlib.h>
12864 #include <${cf_cv_ncurses_header:-curses.h}>
12869 #if defined(NCURSES_VERSION_PATCH)
12870 if (NCURSES_VERSION_PATCH < 20100501) && (NCURSES_VERSION_PATCH >= 20100403)
12874 long x = winnstr(stdscr, "", 0);
12876 getbegyx(stdscr, y1, x1)
12881 rm -f conftest.$ac_objext conftest$ac_exeext
12882 if { (eval echo "$as_me:12882: \"$ac_link\"") >&5
12883 (eval $ac_link) 2>&5
12885 echo "$as_me:12885: \$? = $ac_status" >&5
12886 (exit $ac_status); } &&
12887 { ac_try='test -s conftest$ac_exeext'
12888 { (eval echo "$as_me:12888: \"$ac_try\"") >&5
12889 (eval $ac_try) 2>&5
12891 echo "$as_me:12891: \$? = $ac_status" >&5
12892 (exit $ac_status); }; }; then
12893 cf_cv_need_xopen_extension=no
12895 echo "$as_me: failed program was:" >&5
12896 cat conftest.$ac_ext >&5
12897 cat >conftest.$ac_ext <<_ACEOF
12898 #line 12898 "configure"
12899 #include "confdefs.h"
12901 #define _XOPEN_SOURCE_EXTENDED
12902 #include <stdlib.h>
12903 #include <${cf_cv_ncurses_header:-curses.h}>
12908 #ifdef NCURSES_VERSION
12910 int check2 = curs_set((int)sizeof(check));
12912 long x = winnstr(stdscr, "", 0);
12914 getbegyx(stdscr, y1, x1)
12919 rm -f conftest.$ac_objext conftest$ac_exeext
12920 if { (eval echo "$as_me:12920: \"$ac_link\"") >&5
12921 (eval $ac_link) 2>&5
12923 echo "$as_me:12923: \$? = $ac_status" >&5
12924 (exit $ac_status); } &&
12925 { ac_try='test -s conftest$ac_exeext'
12926 { (eval echo "$as_me:12926: \"$ac_try\"") >&5
12927 (eval $ac_try) 2>&5
12929 echo "$as_me:12929: \$? = $ac_status" >&5
12930 (exit $ac_status); }; }; then
12931 cf_cv_need_xopen_extension=yes
12933 echo "$as_me: failed program was:" >&5
12934 cat conftest.$ac_ext >&5
12935 cf_cv_need_xopen_extension=unknown
12937 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12939 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12941 echo "$as_me:12941: result: $cf_cv_need_xopen_extension" >&5
12942 echo "${ECHO_T}$cf_cv_need_xopen_extension" >&6
12943 test $cf_cv_need_xopen_extension = yes && CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE_EXTENDED"
12945 echo "$as_me:12945: checking for term.h" >&5
12946 echo $ECHO_N "checking for term.h... $ECHO_C" >&6
12947 if test "${cf_cv_term_header+set}" = set; then
12948 echo $ECHO_N "(cached) $ECHO_C" >&6
12951 # If we found <ncurses/curses.h>, look for <ncurses/term.h>, but always look
12952 # for <term.h> if we do not find the variant.
12954 `echo ${cf_cv_ncurses_header:-curses.h} | sed -e 's%/.*%/%'`term.h \
12957 cat >conftest.$ac_ext <<_ACEOF
12958 #line 12958 "configure"
12959 #include "confdefs.h"
12961 #include <${cf_cv_ncurses_header:-curses.h}>
12962 #include <${cf_header}>
12971 rm -f conftest.$ac_objext
12972 if { (eval echo "$as_me:12972: \"$ac_compile\"") >&5
12973 (eval $ac_compile) 2>&5
12975 echo "$as_me:12975: \$? = $ac_status" >&5
12976 (exit $ac_status); } &&
12977 { ac_try='test -s conftest.$ac_objext'
12978 { (eval echo "$as_me:12978: \"$ac_try\"") >&5
12979 (eval $ac_try) 2>&5
12981 echo "$as_me:12981: \$? = $ac_status" >&5
12982 (exit $ac_status); }; }; then
12983 cf_cv_term_header=$cf_header
12986 echo "$as_me: failed program was:" >&5
12987 cat conftest.$ac_ext >&5
12988 cf_cv_term_header=no
12990 rm -f conftest.$ac_objext conftest.$ac_ext
12993 case $cf_cv_term_header in #(vi
12995 # If curses is ncurses, some packagers still mess it up by trying to make
12996 # us use GNU termcap. This handles the most common case.
12997 for cf_header in ncurses/term.h ncursesw/term.h
12999 cat >conftest.$ac_ext <<_ACEOF
13000 #line 13000 "configure"
13001 #include "confdefs.h"
13003 #include <${cf_cv_ncurses_header:-curses.h}>
13004 #ifdef NCURSES_VERSION
13005 #include <${cf_header}>
13017 rm -f conftest.$ac_objext
13018 if { (eval echo "$as_me:13018: \"$ac_compile\"") >&5
13019 (eval $ac_compile) 2>&5
13021 echo "$as_me:13021: \$? = $ac_status" >&5
13022 (exit $ac_status); } &&
13023 { ac_try='test -s conftest.$ac_objext'
13024 { (eval echo "$as_me:13024: \"$ac_try\"") >&5
13025 (eval $ac_try) 2>&5
13027 echo "$as_me:13027: \$? = $ac_status" >&5
13028 (exit $ac_status); }; }; then
13029 cf_cv_term_header=$cf_header
13032 echo "$as_me: failed program was:" >&5
13033 cat conftest.$ac_ext >&5
13034 cf_cv_term_header=no
13036 rm -f conftest.$ac_objext conftest.$ac_ext
13042 echo "$as_me:13042: result: $cf_cv_term_header" >&5
13043 echo "${ECHO_T}$cf_cv_term_header" >&6
13045 case $cf_cv_term_header in #(vi
13047 cat >>confdefs.h <<\EOF
13048 #define HAVE_TERM_H 1
13052 ncurses/term.h) #(vi
13053 cat >>confdefs.h <<\EOF
13054 #define HAVE_NCURSES_TERM_H 1
13059 cat >>confdefs.h <<\EOF
13060 #define HAVE_NCURSESW_TERM_H 1
13092 use_default_colors \
13102 cf_tr_func=`echo "$cf_func" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
13104 echo "$as_me:13104: checking for ${cf_func}" >&5
13105 echo $ECHO_N "checking for ${cf_func}... $ECHO_C" >&6
13107 echo "${as_me:-configure}:13107: testing ${cf_func} ..." 1>&5
13109 if eval "test \"\${cf_cv_func_$cf_func+set}\" = set"; then
13110 echo $ECHO_N "(cached) $ECHO_C" >&6
13113 eval cf_result='$ac_cv_func_'$cf_func
13114 if test ".$cf_result" != ".no"; then
13115 cat >conftest.$ac_ext <<_ACEOF
13116 #line 13116 "configure"
13117 #include "confdefs.h"
13119 #ifdef HAVE_XCURSES
13120 #include <xcurses.h>
13121 char * XCursesProgramName = "test";
13123 #include <${cf_cv_ncurses_header:-curses.h}>
13124 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
13125 #include <ncursesw/term.h>
13126 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
13127 #include <ncurses/term.h>
13128 #elif defined(HAVE_TERM_H)
13138 long foo = (long)(&${cf_func});
13139 ${cf_cv_main_return:-return}(foo == 0);
13146 rm -f conftest.$ac_objext conftest$ac_exeext
13147 if { (eval echo "$as_me:13147: \"$ac_link\"") >&5
13148 (eval $ac_link) 2>&5
13150 echo "$as_me:13150: \$? = $ac_status" >&5
13151 (exit $ac_status); } &&
13152 { ac_try='test -s conftest$ac_exeext'
13153 { (eval echo "$as_me:13153: \"$ac_try\"") >&5
13154 (eval $ac_try) 2>&5
13156 echo "$as_me:13156: \$? = $ac_status" >&5
13157 (exit $ac_status); }; }; then
13160 echo "$as_me: failed program was:" >&5
13161 cat conftest.$ac_ext >&5
13164 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13166 eval 'cf_cv_func_'$cf_func'=$cf_result'
13170 # use the computed/retrieved cache-value:
13171 eval 'cf_result=$cf_cv_func_'$cf_func
13172 echo "$as_me:13172: result: $cf_result" >&5
13173 echo "${ECHO_T}$cf_result" >&6
13174 if test $cf_result != no; then
13175 cat >>confdefs.h <<EOF
13176 #define HAVE_${cf_tr_func} 1
13182 echo "$as_me:13182: checking for ncurses extended functions" >&5
13183 echo $ECHO_N "checking for ncurses extended functions... $ECHO_C" >&6
13184 if test "${cf_cv_ncurses_ext_funcs+set}" = set; then
13185 echo $ECHO_N "(cached) $ECHO_C" >&6
13188 cat >conftest.$ac_ext <<_ACEOF
13189 #line 13189 "configure"
13190 #include "confdefs.h"
13192 #include <${cf_cv_ncurses_header:-curses.h}>
13197 int x = NCURSES_EXT_FUNCS
13203 rm -f conftest.$ac_objext
13204 if { (eval echo "$as_me:13204: \"$ac_compile\"") >&5
13205 (eval $ac_compile) 2>&5
13207 echo "$as_me:13207: \$? = $ac_status" >&5
13208 (exit $ac_status); } &&
13209 { ac_try='test -s conftest.$ac_objext'
13210 { (eval echo "$as_me:13210: \"$ac_try\"") >&5
13211 (eval $ac_try) 2>&5
13213 echo "$as_me:13213: \$? = $ac_status" >&5
13214 (exit $ac_status); }; }; then
13215 cf_cv_ncurses_ext_funcs=defined
13217 echo "$as_me: failed program was:" >&5
13218 cat conftest.$ac_ext >&5
13220 cat >conftest.$ac_ext <<_ACEOF
13221 #line 13221 "configure"
13222 #include "confdefs.h"
13224 #include <${cf_cv_ncurses_header:-curses.h}>
13229 (void) assume_default_colors (0, 0);
13230 (void) curses_version ();
13231 (void) define_key (0, 0);
13232 (void) is_term_resized (0, 0);
13233 (void) key_defined (0);
13234 (void) keybound (0, 0);
13235 (void) keyok (0, 0);
13236 (void) resize_term (0, 0);
13237 (void) resizeterm (0, 0);
13238 (void) use_default_colors ();
13239 (void) use_extended_names (0);
13240 (void) wresize (0, 0, 0);
13245 rm -f conftest.$ac_objext conftest$ac_exeext
13246 if { (eval echo "$as_me:13246: \"$ac_link\"") >&5
13247 (eval $ac_link) 2>&5
13249 echo "$as_me:13249: \$? = $ac_status" >&5
13250 (exit $ac_status); } &&
13251 { ac_try='test -s conftest$ac_exeext'
13252 { (eval echo "$as_me:13252: \"$ac_try\"") >&5
13253 (eval $ac_try) 2>&5
13255 echo "$as_me:13255: \$? = $ac_status" >&5
13256 (exit $ac_status); }; }; then
13257 cf_cv_ncurses_ext_funcs=yes
13259 echo "$as_me: failed program was:" >&5
13260 cat conftest.$ac_ext >&5
13261 cf_cv_ncurses_ext_funcs=no
13263 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13266 rm -f conftest.$ac_objext conftest.$ac_ext
13269 echo "$as_me:13269: result: $cf_cv_ncurses_ext_funcs" >&5
13270 echo "${ECHO_T}$cf_cv_ncurses_ext_funcs" >&6
13271 test "$cf_cv_ncurses_ext_funcs" = yes && cat >>confdefs.h <<\EOF
13272 #define NCURSES_EXT_FUNCS 1
13275 echo "$as_me:13275: checking for wide-character functions" >&5
13276 echo $ECHO_N "checking for wide-character functions... $ECHO_C" >&6
13277 if test "${cf_cv_widechar_funcs+set}" = set; then
13278 echo $ECHO_N "(cached) $ECHO_C" >&6
13281 cat >conftest.$ac_ext <<_ACEOF
13282 #line 13282 "configure"
13283 #include "confdefs.h"
13285 #include <${cf_cv_ncurses_header:-curses.h}>
13290 static wchar_t src_wchar[2];
13291 static cchar_t dst_cchar;
13292 setcchar(&dst_cchar, src_wchar, A_NORMAL, 0, (void *) 0);
13298 rm -f conftest.$ac_objext conftest$ac_exeext
13299 if { (eval echo "$as_me:13299: \"$ac_link\"") >&5
13300 (eval $ac_link) 2>&5
13302 echo "$as_me:13302: \$? = $ac_status" >&5
13303 (exit $ac_status); } &&
13304 { ac_try='test -s conftest$ac_exeext'
13305 { (eval echo "$as_me:13305: \"$ac_try\"") >&5
13306 (eval $ac_try) 2>&5
13308 echo "$as_me:13308: \$? = $ac_status" >&5
13309 (exit $ac_status); }; }; then
13310 cf_cv_widechar_funcs=yes
13312 echo "$as_me: failed program was:" >&5
13313 cat conftest.$ac_ext >&5
13314 cf_cv_widechar_funcs=no
13316 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13319 echo "$as_me:13319: result: $cf_cv_widechar_funcs" >&5
13320 echo "${ECHO_T}$cf_cv_widechar_funcs" >&6
13321 if test "$cf_cv_widechar_funcs" != no ; then
13322 cat >>confdefs.h <<\EOF
13323 #define USE_WIDEC_SUPPORT 1
13327 cat >>confdefs.h <<\EOF
13328 #define USE_WIDEC_SUPPORT 0
13333 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
13335 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
13336 inttypes.h stdint.h unistd.h
13338 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
13339 echo "$as_me:13339: checking for $ac_header" >&5
13340 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13341 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13342 echo $ECHO_N "(cached) $ECHO_C" >&6
13344 cat >conftest.$ac_ext <<_ACEOF
13345 #line 13345 "configure"
13346 #include "confdefs.h"
13347 $ac_includes_default
13348 #include <$ac_header>
13350 rm -f conftest.$ac_objext
13351 if { (eval echo "$as_me:13351: \"$ac_compile\"") >&5
13352 (eval $ac_compile) 2>&5
13354 echo "$as_me:13354: \$? = $ac_status" >&5
13355 (exit $ac_status); } &&
13356 { ac_try='test -s conftest.$ac_objext'
13357 { (eval echo "$as_me:13357: \"$ac_try\"") >&5
13358 (eval $ac_try) 2>&5
13360 echo "$as_me:13360: \$? = $ac_status" >&5
13361 (exit $ac_status); }; }; then
13362 eval "$as_ac_Header=yes"
13364 echo "$as_me: failed program was:" >&5
13365 cat conftest.$ac_ext >&5
13366 eval "$as_ac_Header=no"
13368 rm -f conftest.$ac_objext conftest.$ac_ext
13370 echo "$as_me:13370: result: `eval echo '${'$as_ac_Header'}'`" >&5
13371 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13372 if test `eval echo '${'$as_ac_Header'}'` = yes; then
13373 cat >>confdefs.h <<EOF
13374 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
13380 echo "$as_me:13380: checking for pid_t" >&5
13381 echo $ECHO_N "checking for pid_t... $ECHO_C" >&6
13382 if test "${ac_cv_type_pid_t+set}" = set; then
13383 echo $ECHO_N "(cached) $ECHO_C" >&6
13385 cat >conftest.$ac_ext <<_ACEOF
13386 #line 13386 "configure"
13387 #include "confdefs.h"
13388 $ac_includes_default
13394 if (sizeof (pid_t))
13400 rm -f conftest.$ac_objext
13401 if { (eval echo "$as_me:13401: \"$ac_compile\"") >&5
13402 (eval $ac_compile) 2>&5
13404 echo "$as_me:13404: \$? = $ac_status" >&5
13405 (exit $ac_status); } &&
13406 { ac_try='test -s conftest.$ac_objext'
13407 { (eval echo "$as_me:13407: \"$ac_try\"") >&5
13408 (eval $ac_try) 2>&5
13410 echo "$as_me:13410: \$? = $ac_status" >&5
13411 (exit $ac_status); }; }; then
13412 ac_cv_type_pid_t=yes
13414 echo "$as_me: failed program was:" >&5
13415 cat conftest.$ac_ext >&5
13416 ac_cv_type_pid_t=no
13418 rm -f conftest.$ac_objext conftest.$ac_ext
13420 echo "$as_me:13420: result: $ac_cv_type_pid_t" >&5
13421 echo "${ECHO_T}$ac_cv_type_pid_t" >&6
13422 if test $ac_cv_type_pid_t = yes; then
13426 cat >>confdefs.h <<EOF
13432 for ac_header in unistd.h vfork.h
13434 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
13435 echo "$as_me:13435: checking for $ac_header" >&5
13436 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13437 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13438 echo $ECHO_N "(cached) $ECHO_C" >&6
13440 cat >conftest.$ac_ext <<_ACEOF
13441 #line 13441 "configure"
13442 #include "confdefs.h"
13443 #include <$ac_header>
13445 if { (eval echo "$as_me:13445: \"$ac_cpp conftest.$ac_ext\"") >&5
13446 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13448 egrep -v '^ *\+' conftest.er1 >conftest.err
13450 cat conftest.err >&5
13451 echo "$as_me:13451: \$? = $ac_status" >&5
13452 (exit $ac_status); } >/dev/null; then
13453 if test -s conftest.err; then
13454 ac_cpp_err=$ac_c_preproc_warn_flag
13461 if test -z "$ac_cpp_err"; then
13462 eval "$as_ac_Header=yes"
13464 echo "$as_me: failed program was:" >&5
13465 cat conftest.$ac_ext >&5
13466 eval "$as_ac_Header=no"
13468 rm -f conftest.err conftest.$ac_ext
13470 echo "$as_me:13470: result: `eval echo '${'$as_ac_Header'}'`" >&5
13471 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13472 if test `eval echo '${'$as_ac_Header'}'` = yes; then
13473 cat >>confdefs.h <<EOF
13474 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
13480 for ac_func in fork vfork
13482 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13483 echo "$as_me:13483: checking for $ac_func" >&5
13484 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13485 if eval "test \"\${$as_ac_var+set}\" = set"; then
13486 echo $ECHO_N "(cached) $ECHO_C" >&6
13488 cat >conftest.$ac_ext <<_ACEOF
13489 #line 13489 "configure"
13490 #include "confdefs.h"
13491 /* System header to define __stub macros and hopefully few prototypes,
13492 which can conflict with char $ac_func (); below. */
13493 #include <assert.h>
13494 /* Override any gcc2 internal prototype to avoid an error. */
13498 /* We use char because int might match the return type of a gcc2
13499 builtin and then its argument prototype would still apply. */
13506 /* The GNU C library defines this for functions which it implements
13507 to always fail with ENOSYS. Some functions are actually named
13508 something starting with __ and the normal name is an alias. */
13509 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13519 rm -f conftest.$ac_objext conftest$ac_exeext
13520 if { (eval echo "$as_me:13520: \"$ac_link\"") >&5
13521 (eval $ac_link) 2>&5
13523 echo "$as_me:13523: \$? = $ac_status" >&5
13524 (exit $ac_status); } &&
13525 { ac_try='test -s conftest$ac_exeext'
13526 { (eval echo "$as_me:13526: \"$ac_try\"") >&5
13527 (eval $ac_try) 2>&5
13529 echo "$as_me:13529: \$? = $ac_status" >&5
13530 (exit $ac_status); }; }; then
13531 eval "$as_ac_var=yes"
13533 echo "$as_me: failed program was:" >&5
13534 cat conftest.$ac_ext >&5
13535 eval "$as_ac_var=no"
13537 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13539 echo "$as_me:13539: result: `eval echo '${'$as_ac_var'}'`" >&5
13540 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13541 if test `eval echo '${'$as_ac_var'}'` = yes; then
13542 cat >>confdefs.h <<EOF
13543 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13549 ac_cv_func_fork_works=$ac_cv_func_fork
13550 if test "x$ac_cv_func_fork" = xyes; then
13551 echo "$as_me:13551: checking for working fork" >&5
13552 echo $ECHO_N "checking for working fork... $ECHO_C" >&6
13553 if test "${ac_cv_func_fork_works+set}" = set; then
13554 echo $ECHO_N "(cached) $ECHO_C" >&6
13556 if test "$cross_compiling" = yes; then
13557 ac_cv_func_fork_works=cross
13559 cat >conftest.$ac_ext <<_ACEOF
13560 /* By Rüdiger Kuhlmann. */
13561 #include <sys/types.h>
13563 # include <unistd.h>
13565 /* Some systems only have a dummy stub for fork() */
13569 $ac_main_return (1);
13570 $ac_main_return (0);
13573 rm -f conftest$ac_exeext
13574 if { (eval echo "$as_me:13574: \"$ac_link\"") >&5
13575 (eval $ac_link) 2>&5
13577 echo "$as_me:13577: \$? = $ac_status" >&5
13578 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13579 { (eval echo "$as_me:13579: \"$ac_try\"") >&5
13580 (eval $ac_try) 2>&5
13582 echo "$as_me:13582: \$? = $ac_status" >&5
13583 (exit $ac_status); }; }; then
13584 ac_cv_func_fork_works=yes
13586 echo "$as_me: program exited with status $ac_status" >&5
13587 echo "$as_me: failed program was:" >&5
13588 cat conftest.$ac_ext >&5
13589 ac_cv_func_fork_works=no
13591 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13594 echo "$as_me:13594: result: $ac_cv_func_fork_works" >&5
13595 echo "${ECHO_T}$ac_cv_func_fork_works" >&6
13598 if test "x$ac_cv_func_fork_works" = xcross; then
13600 *-*-amigaos* | *-*-msdosdjgpp*)
13601 # Override, as these systems have only a dummy fork() stub
13602 ac_cv_func_fork_works=no
13605 ac_cv_func_fork_works=yes
13608 { echo "$as_me:13608: WARNING: CROSS: Result $ac_cv_func_fork_works guessed due to cross-compiling." >&5
13609 echo "$as_me: WARNING: CROSS: Result $ac_cv_func_fork_works guessed due to cross-compiling." >&2;}
13611 ac_cv_func_vfork_works=$ac_cv_func_vfork
13612 if test "x$ac_cv_func_vfork" = xyes; then
13613 echo "$as_me:13613: checking for working vfork" >&5
13614 echo $ECHO_N "checking for working vfork... $ECHO_C" >&6
13615 if test "${ac_cv_func_vfork_works+set}" = set; then
13616 echo $ECHO_N "(cached) $ECHO_C" >&6
13618 if test "$cross_compiling" = yes; then
13619 ac_cv_func_vfork_works=cross
13621 cat >conftest.$ac_ext <<_ACEOF
13622 #line 13622 "configure"
13623 #include "confdefs.h"
13624 /* Thanks to Paul Eggert for this test. */
13626 #include <sys/types.h>
13627 #include <sys/stat.h>
13629 # include <unistd.h>
13632 # include <vfork.h>
13634 /* On some sparc systems, changes by the child to local and incoming
13635 argument registers are propagated back to the parent. The compiler
13636 is told about this with #include <vfork.h>, but some compilers
13637 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
13638 static variable whose address is put into a register that is
13639 clobbered by the vfork. */
13642 sparc_address_test (int arg)
13644 sparc_address_test (arg) int arg;
13647 static pid_t child;
13665 pid_t parent = getpid ();
13668 sparc_address_test ();
13673 /* Here is another test for sparc vfork register problems. This
13674 test uses lots of local variables, at least as many local
13675 variables as main has allocated so far including compiler
13676 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
13677 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
13678 reuse the register of parent for one of the local variables,
13679 since it will think that parent can't possibly be used any more
13680 in this routine. Assigning to the local variable will thus
13681 munge parent in the parent process. */
13683 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
13684 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
13685 /* Convince the compiler that p..p7 are live; otherwise, it might
13686 use the same hardware register for all 8 local variables. */
13687 if (p != p1 || p != p2 || p != p3 || p != p4
13688 || p != p5 || p != p6 || p != p7)
13691 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
13692 from child file descriptors. If the child closes a descriptor
13693 before it execs or exits, this munges the parent's descriptor
13694 as well. Test for this by closing stdout in the child. */
13695 _exit(close(fileno(stdout)) != 0);
13700 while (wait(&status) != child)
13703 /* Was there some problem with vforking? */
13706 /* Did the child fail? (This shouldn't happen.) */
13709 /* Did the vfork/compiler bug occur? */
13710 || parent != getpid()
13712 /* Did the file descriptor bug occur? */
13713 || fstat(fileno(stdout), &st) != 0
13718 rm -f conftest$ac_exeext
13719 if { (eval echo "$as_me:13719: \"$ac_link\"") >&5
13720 (eval $ac_link) 2>&5
13722 echo "$as_me:13722: \$? = $ac_status" >&5
13723 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13724 { (eval echo "$as_me:13724: \"$ac_try\"") >&5
13725 (eval $ac_try) 2>&5
13727 echo "$as_me:13727: \$? = $ac_status" >&5
13728 (exit $ac_status); }; }; then
13729 ac_cv_func_vfork_works=yes
13731 echo "$as_me: program exited with status $ac_status" >&5
13732 echo "$as_me: failed program was:" >&5
13733 cat conftest.$ac_ext >&5
13734 ac_cv_func_vfork_works=no
13736 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13739 echo "$as_me:13739: result: $ac_cv_func_vfork_works" >&5
13740 echo "${ECHO_T}$ac_cv_func_vfork_works" >&6
13743 if test "x$ac_cv_func_fork_works" = xcross; then
13744 ac_cv_func_vfork_works=ac_cv_func_vfork
13745 { echo "$as_me:13745: WARNING: CROSS: Result $ac_cv_func_vfork_works guessed due to cross-compiling." >&5
13746 echo "$as_me: WARNING: CROSS: Result $ac_cv_func_vfork_works guessed due to cross-compiling." >&2;}
13749 if test "x$ac_cv_func_vfork_works" = xyes; then
13751 cat >>confdefs.h <<\EOF
13752 #define HAVE_WORKING_VFORK 1
13757 cat >>confdefs.h <<\EOF
13762 if test "x$ac_cv_func_fork_works" = xyes; then
13764 cat >>confdefs.h <<\EOF
13765 #define HAVE_WORKING_FORK 1
13770 echo "$as_me:13770: checking if sys/time.h works with sys/select.h" >&5
13771 echo $ECHO_N "checking if sys/time.h works with sys/select.h... $ECHO_C" >&6
13772 if test "${cf_cv_sys_time_select+set}" = set; then
13773 echo $ECHO_N "(cached) $ECHO_C" >&6
13776 cat >conftest.$ac_ext <<_ACEOF
13777 #line 13777 "configure"
13778 #include "confdefs.h"
13780 #include <sys/types.h>
13781 #ifdef HAVE_SYS_TIME_H
13782 #include <sys/time.h>
13784 #ifdef HAVE_SYS_SELECT_H
13785 #include <sys/select.h>
13796 rm -f conftest.$ac_objext
13797 if { (eval echo "$as_me:13797: \"$ac_compile\"") >&5
13798 (eval $ac_compile) 2>&5
13800 echo "$as_me:13800: \$? = $ac_status" >&5
13801 (exit $ac_status); } &&
13802 { ac_try='test -s conftest.$ac_objext'
13803 { (eval echo "$as_me:13803: \"$ac_try\"") >&5
13804 (eval $ac_try) 2>&5
13806 echo "$as_me:13806: \$? = $ac_status" >&5
13807 (exit $ac_status); }; }; then
13808 cf_cv_sys_time_select=yes
13810 echo "$as_me: failed program was:" >&5
13811 cat conftest.$ac_ext >&5
13812 cf_cv_sys_time_select=no
13814 rm -f conftest.$ac_objext conftest.$ac_ext
13818 echo "$as_me:13818: result: $cf_cv_sys_time_select" >&5
13819 echo "${ECHO_T}$cf_cv_sys_time_select" >&6
13820 test "$cf_cv_sys_time_select" = yes && cat >>confdefs.h <<\EOF
13821 #define HAVE_SYS_TIME_SELECT 1
13824 echo "$as_me:13824: checking for function curses_version" >&5
13825 echo $ECHO_N "checking for function curses_version... $ECHO_C" >&6
13826 if test "${cf_cv_func_curses_version+set}" = set; then
13827 echo $ECHO_N "(cached) $ECHO_C" >&6
13830 if test "$cross_compiling" = yes; then
13831 cf_cv_func_curses_version=unknown
13833 cat >conftest.$ac_ext <<_ACEOF
13834 #line 13834 "configure"
13835 #include "confdefs.h"
13837 #include <${cf_cv_ncurses_header:-curses.h}>
13841 sprintf(temp, "%s\n", curses_version());
13842 ${cf_cv_main_return:-return}(0);
13846 rm -f conftest$ac_exeext
13847 if { (eval echo "$as_me:13847: \"$ac_link\"") >&5
13848 (eval $ac_link) 2>&5
13850 echo "$as_me:13850: \$? = $ac_status" >&5
13851 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13852 { (eval echo "$as_me:13852: \"$ac_try\"") >&5
13853 (eval $ac_try) 2>&5
13855 echo "$as_me:13855: \$? = $ac_status" >&5
13856 (exit $ac_status); }; }; then
13857 cf_cv_func_curses_version=yes
13860 echo "$as_me: program exited with status $ac_status" >&5
13861 echo "$as_me: failed program was:" >&5
13862 cat conftest.$ac_ext >&5
13863 cf_cv_func_curses_version=no
13866 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13870 echo "$as_me:13870: result: $cf_cv_func_curses_version" >&5
13871 echo "${ECHO_T}$cf_cv_func_curses_version" >&6
13872 test "$cf_cv_func_curses_version" = yes && cat >>confdefs.h <<\EOF
13873 #define HAVE_CURSES_VERSION 1
13876 echo "$as_me:13876: checking for ncurses wrap-prefix" >&5
13877 echo $ECHO_N "checking for ncurses wrap-prefix... $ECHO_C" >&6
13879 # Check whether --with-ncurses-wrap-prefix or --without-ncurses-wrap-prefix was given.
13880 if test "${with_ncurses_wrap_prefix+set}" = set; then
13881 withval="$with_ncurses_wrap_prefix"
13882 NCURSES_WRAP_PREFIX=$withval
13884 NCURSES_WRAP_PREFIX=_nc_
13886 echo "$as_me:13886: result: $NCURSES_WRAP_PREFIX" >&5
13887 echo "${ECHO_T}$NCURSES_WRAP_PREFIX" >&6
13889 echo "$as_me:13889: checking for alternate character set array" >&5
13890 echo $ECHO_N "checking for alternate character set array... $ECHO_C" >&6
13891 if test "${cf_cv_curses_acs_map+set}" = set; then
13892 echo $ECHO_N "(cached) $ECHO_C" >&6
13895 cf_cv_curses_acs_map=unknown
13896 for name in acs_map _acs_map __acs_map ${NCURSES_WRAP_PREFIX}acs_map
13898 cat >conftest.$ac_ext <<_ACEOF
13899 #line 13899 "configure"
13900 #include "confdefs.h"
13902 #include <${cf_cv_ncurses_header:-curses.h}>
13908 $name['k'] = ACS_PLUS
13914 rm -f conftest.$ac_objext conftest$ac_exeext
13915 if { (eval echo "$as_me:13915: \"$ac_link\"") >&5
13916 (eval $ac_link) 2>&5
13918 echo "$as_me:13918: \$? = $ac_status" >&5
13919 (exit $ac_status); } &&
13920 { ac_try='test -s conftest$ac_exeext'
13921 { (eval echo "$as_me:13921: \"$ac_try\"") >&5
13922 (eval $ac_try) 2>&5
13924 echo "$as_me:13924: \$? = $ac_status" >&5
13925 (exit $ac_status); }; }; then
13926 cf_cv_curses_acs_map=$name; break
13928 echo "$as_me: failed program was:" >&5
13929 cat conftest.$ac_ext >&5
13931 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13935 echo "$as_me:13935: result: $cf_cv_curses_acs_map" >&5
13936 echo "${ECHO_T}$cf_cv_curses_acs_map" >&6
13938 test "$cf_cv_curses_acs_map" != unknown && cat >>confdefs.h <<EOF
13939 #define CURSES_ACS_ARRAY $cf_cv_curses_acs_map
13942 echo "$as_me:13942: checking for wide alternate character set array" >&5
13943 echo $ECHO_N "checking for wide alternate character set array... $ECHO_C" >&6
13944 if test "${cf_cv_curses_wacs_map+set}" = set; then
13945 echo $ECHO_N "(cached) $ECHO_C" >&6
13948 cf_cv_curses_wacs_map=unknown
13949 for name in wacs_map _wacs_map __wacs_map _nc_wacs _wacs_char
13951 cat >conftest.$ac_ext <<_ACEOF
13952 #line 13952 "configure"
13953 #include "confdefs.h"
13955 #ifndef _XOPEN_SOURCE_EXTENDED
13956 #define _XOPEN_SOURCE_EXTENDED
13958 #include <${cf_cv_ncurses_header:-curses.h}>
13962 void *foo = &($name['k'])
13967 rm -f conftest.$ac_objext conftest$ac_exeext
13968 if { (eval echo "$as_me:13968: \"$ac_link\"") >&5
13969 (eval $ac_link) 2>&5
13971 echo "$as_me:13971: \$? = $ac_status" >&5
13972 (exit $ac_status); } &&
13973 { ac_try='test -s conftest$ac_exeext'
13974 { (eval echo "$as_me:13974: \"$ac_try\"") >&5
13975 (eval $ac_try) 2>&5
13977 echo "$as_me:13977: \$? = $ac_status" >&5
13978 (exit $ac_status); }; }; then
13979 cf_cv_curses_wacs_map=$name
13982 echo "$as_me: failed program was:" >&5
13983 cat conftest.$ac_ext >&5
13985 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13988 echo "$as_me:13988: result: $cf_cv_curses_wacs_map" >&5
13989 echo "${ECHO_T}$cf_cv_curses_wacs_map" >&6
13991 test "$cf_cv_curses_wacs_map" != unknown && cat >>confdefs.h <<EOF
13992 #define CURSES_WACS_ARRAY $cf_cv_curses_wacs_map
13995 echo "$as_me:13995: checking for wide alternate character constants" >&5
13996 echo $ECHO_N "checking for wide alternate character constants... $ECHO_C" >&6
13997 if test "${cf_cv_curses_wacs_symbols+set}" = set; then
13998 echo $ECHO_N "(cached) $ECHO_C" >&6
14001 cf_cv_curses_wacs_symbols=no
14002 if test "$cf_cv_curses_wacs_map" != unknown
14004 cat >conftest.$ac_ext <<_ACEOF
14005 #line 14005 "configure"
14006 #include "confdefs.h"
14008 #ifndef _XOPEN_SOURCE_EXTENDED
14009 #define _XOPEN_SOURCE_EXTENDED
14011 #include <${cf_cv_ncurses_header:-curses.h}>
14015 cchar_t *foo = WACS_PLUS;
14016 $cf_cv_curses_wacs_map['k'] = *WACS_PLUS
14021 rm -f conftest.$ac_objext conftest$ac_exeext
14022 if { (eval echo "$as_me:14022: \"$ac_link\"") >&5
14023 (eval $ac_link) 2>&5
14025 echo "$as_me:14025: \$? = $ac_status" >&5
14026 (exit $ac_status); } &&
14027 { ac_try='test -s conftest$ac_exeext'
14028 { (eval echo "$as_me:14028: \"$ac_try\"") >&5
14029 (eval $ac_try) 2>&5
14031 echo "$as_me:14031: \$? = $ac_status" >&5
14032 (exit $ac_status); }; }; then
14033 cf_cv_curses_wacs_symbols=yes
14035 echo "$as_me: failed program was:" >&5
14036 cat conftest.$ac_ext >&5
14038 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14040 cat >conftest.$ac_ext <<_ACEOF
14041 #line 14041 "configure"
14042 #include "confdefs.h"
14044 #ifndef _XOPEN_SOURCE_EXTENDED
14045 #define _XOPEN_SOURCE_EXTENDED
14047 #include <${cf_cv_ncurses_header:-curses.h}>
14051 cchar_t *foo = WACS_PLUS
14056 rm -f conftest.$ac_objext conftest$ac_exeext
14057 if { (eval echo "$as_me:14057: \"$ac_link\"") >&5
14058 (eval $ac_link) 2>&5
14060 echo "$as_me:14060: \$? = $ac_status" >&5
14061 (exit $ac_status); } &&
14062 { ac_try='test -s conftest$ac_exeext'
14063 { (eval echo "$as_me:14063: \"$ac_try\"") >&5
14064 (eval $ac_try) 2>&5
14066 echo "$as_me:14066: \$? = $ac_status" >&5
14067 (exit $ac_status); }; }; then
14068 cf_cv_curses_wacs_symbols=yes
14070 echo "$as_me: failed program was:" >&5
14071 cat conftest.$ac_ext >&5
14073 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14077 echo "$as_me:14077: result: $cf_cv_curses_wacs_symbols" >&5
14078 echo "${ECHO_T}$cf_cv_curses_wacs_symbols" >&6
14080 test "$cf_cv_curses_wacs_symbols" != no && cat >>confdefs.h <<\EOF
14081 #define CURSES_WACS_SYMBOLS 1
14084 echo "$as_me:14084: checking for type attr_t in ${cf_cv_ncurses_header:-curses.h}" >&5
14085 echo $ECHO_N "checking for type attr_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
14086 cat >conftest.$ac_ext <<_ACEOF
14087 #line 14087 "configure"
14088 #include "confdefs.h"
14090 #ifndef _XOPEN_SOURCE_EXTENDED
14091 #define _XOPEN_SOURCE_EXTENDED
14093 #include <${cf_cv_ncurses_header:-curses.h}>
14104 rm -f conftest.$ac_objext
14105 if { (eval echo "$as_me:14105: \"$ac_compile\"") >&5
14106 (eval $ac_compile) 2>&5
14108 echo "$as_me:14108: \$? = $ac_status" >&5
14109 (exit $ac_status); } &&
14110 { ac_try='test -s conftest.$ac_objext'
14111 { (eval echo "$as_me:14111: \"$ac_try\"") >&5
14112 (eval $ac_try) 2>&5
14114 echo "$as_me:14114: \$? = $ac_status" >&5
14115 (exit $ac_status); }; }; then
14118 echo "$as_me: failed program was:" >&5
14119 cat conftest.$ac_ext >&5
14122 rm -f conftest.$ac_objext conftest.$ac_ext
14123 echo "$as_me:14123: result: $cf_result" >&5
14124 echo "${ECHO_T}$cf_result" >&6
14125 if test $cf_result = yes ; then
14127 cf_result=`echo "have_type_attr_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14129 cat >>confdefs.h <<EOF
14130 #define $cf_result 1
14134 cat >>confdefs.h <<EOF
14135 #define attr_t long
14140 # This is needed on Tru64 5.0 to declare mbstate_t
14141 echo "$as_me:14141: checking if we must include wchar.h to declare mbstate_t" >&5
14142 echo $ECHO_N "checking if we must include wchar.h to declare mbstate_t... $ECHO_C" >&6
14143 if test "${cf_cv_mbstate_t+set}" = set; then
14144 echo $ECHO_N "(cached) $ECHO_C" >&6
14147 cat >conftest.$ac_ext <<_ACEOF
14148 #line 14148 "configure"
14149 #include "confdefs.h"
14151 #include <stdlib.h>
14152 #include <stdarg.h>
14154 #ifdef HAVE_LIBUTF8_H
14155 #include <libutf8.h>
14165 rm -f conftest.$ac_objext
14166 if { (eval echo "$as_me:14166: \"$ac_compile\"") >&5
14167 (eval $ac_compile) 2>&5
14169 echo "$as_me:14169: \$? = $ac_status" >&5
14170 (exit $ac_status); } &&
14171 { ac_try='test -s conftest.$ac_objext'
14172 { (eval echo "$as_me:14172: \"$ac_try\"") >&5
14173 (eval $ac_try) 2>&5
14175 echo "$as_me:14175: \$? = $ac_status" >&5
14176 (exit $ac_status); }; }; then
14179 echo "$as_me: failed program was:" >&5
14180 cat conftest.$ac_ext >&5
14181 cat >conftest.$ac_ext <<_ACEOF
14182 #line 14182 "configure"
14183 #include "confdefs.h"
14185 #include <stdlib.h>
14186 #include <stdarg.h>
14189 #ifdef HAVE_LIBUTF8_H
14190 #include <libutf8.h>
14200 rm -f conftest.$ac_objext
14201 if { (eval echo "$as_me:14201: \"$ac_compile\"") >&5
14202 (eval $ac_compile) 2>&5
14204 echo "$as_me:14204: \$? = $ac_status" >&5
14205 (exit $ac_status); } &&
14206 { ac_try='test -s conftest.$ac_objext'
14207 { (eval echo "$as_me:14207: \"$ac_try\"") >&5
14208 (eval $ac_try) 2>&5
14210 echo "$as_me:14210: \$? = $ac_status" >&5
14211 (exit $ac_status); }; }; then
14212 cf_cv_mbstate_t=yes
14214 echo "$as_me: failed program was:" >&5
14215 cat conftest.$ac_ext >&5
14216 cf_cv_mbstate_t=unknown
14218 rm -f conftest.$ac_objext conftest.$ac_ext
14220 rm -f conftest.$ac_objext conftest.$ac_ext
14222 echo "$as_me:14222: result: $cf_cv_mbstate_t" >&5
14223 echo "${ECHO_T}$cf_cv_mbstate_t" >&6
14225 if test "$cf_cv_mbstate_t" = yes ; then
14226 cat >>confdefs.h <<\EOF
14227 #define NEED_WCHAR_H 1
14233 # if we do not find mbstate_t in either place, use substitution to provide a fallback.
14234 if test "$cf_cv_mbstate_t" = unknown ; then
14235 NCURSES_MBSTATE_T=1
14238 # if we find mbstate_t in either place, use substitution to provide a fallback.
14239 if test "$cf_cv_mbstate_t" != unknown ; then
14240 NCURSES_OK_MBSTATE_T=1
14243 # This is needed on Tru64 5.0 to declare wchar_t
14244 echo "$as_me:14244: checking if we must include wchar.h to declare wchar_t" >&5
14245 echo $ECHO_N "checking if we must include wchar.h to declare wchar_t... $ECHO_C" >&6
14246 if test "${cf_cv_wchar_t+set}" = set; then
14247 echo $ECHO_N "(cached) $ECHO_C" >&6
14250 cat >conftest.$ac_ext <<_ACEOF
14251 #line 14251 "configure"
14252 #include "confdefs.h"
14254 #include <stdlib.h>
14255 #include <stdarg.h>
14257 #ifdef HAVE_LIBUTF8_H
14258 #include <libutf8.h>
14268 rm -f conftest.$ac_objext
14269 if { (eval echo "$as_me:14269: \"$ac_compile\"") >&5
14270 (eval $ac_compile) 2>&5
14272 echo "$as_me:14272: \$? = $ac_status" >&5
14273 (exit $ac_status); } &&
14274 { ac_try='test -s conftest.$ac_objext'
14275 { (eval echo "$as_me:14275: \"$ac_try\"") >&5
14276 (eval $ac_try) 2>&5
14278 echo "$as_me:14278: \$? = $ac_status" >&5
14279 (exit $ac_status); }; }; then
14282 echo "$as_me: failed program was:" >&5
14283 cat conftest.$ac_ext >&5
14284 cat >conftest.$ac_ext <<_ACEOF
14285 #line 14285 "configure"
14286 #include "confdefs.h"
14288 #include <stdlib.h>
14289 #include <stdarg.h>
14292 #ifdef HAVE_LIBUTF8_H
14293 #include <libutf8.h>
14303 rm -f conftest.$ac_objext
14304 if { (eval echo "$as_me:14304: \"$ac_compile\"") >&5
14305 (eval $ac_compile) 2>&5
14307 echo "$as_me:14307: \$? = $ac_status" >&5
14308 (exit $ac_status); } &&
14309 { ac_try='test -s conftest.$ac_objext'
14310 { (eval echo "$as_me:14310: \"$ac_try\"") >&5
14311 (eval $ac_try) 2>&5
14313 echo "$as_me:14313: \$? = $ac_status" >&5
14314 (exit $ac_status); }; }; then
14317 echo "$as_me: failed program was:" >&5
14318 cat conftest.$ac_ext >&5
14319 cf_cv_wchar_t=unknown
14321 rm -f conftest.$ac_objext conftest.$ac_ext
14323 rm -f conftest.$ac_objext conftest.$ac_ext
14325 echo "$as_me:14325: result: $cf_cv_wchar_t" >&5
14326 echo "${ECHO_T}$cf_cv_wchar_t" >&6
14328 if test "$cf_cv_wchar_t" = yes ; then
14329 cat >>confdefs.h <<\EOF
14330 #define NEED_WCHAR_H 1
14336 # if we do not find wchar_t in either place, use substitution to provide a fallback.
14337 if test "$cf_cv_wchar_t" = unknown ; then
14341 # if we find wchar_t in either place, use substitution to provide a fallback.
14342 if test "$cf_cv_wchar_t" != unknown ; then
14343 NCURSES_OK_WCHAR_T=1
14346 # This is needed on Tru64 5.0 to declare wint_t
14347 echo "$as_me:14347: checking if we must include wchar.h to declare wint_t" >&5
14348 echo $ECHO_N "checking if we must include wchar.h to declare wint_t... $ECHO_C" >&6
14349 if test "${cf_cv_wint_t+set}" = set; then
14350 echo $ECHO_N "(cached) $ECHO_C" >&6
14353 cat >conftest.$ac_ext <<_ACEOF
14354 #line 14354 "configure"
14355 #include "confdefs.h"
14357 #include <stdlib.h>
14358 #include <stdarg.h>
14360 #ifdef HAVE_LIBUTF8_H
14361 #include <libutf8.h>
14371 rm -f conftest.$ac_objext
14372 if { (eval echo "$as_me:14372: \"$ac_compile\"") >&5
14373 (eval $ac_compile) 2>&5
14375 echo "$as_me:14375: \$? = $ac_status" >&5
14376 (exit $ac_status); } &&
14377 { ac_try='test -s conftest.$ac_objext'
14378 { (eval echo "$as_me:14378: \"$ac_try\"") >&5
14379 (eval $ac_try) 2>&5
14381 echo "$as_me:14381: \$? = $ac_status" >&5
14382 (exit $ac_status); }; }; then
14385 echo "$as_me: failed program was:" >&5
14386 cat conftest.$ac_ext >&5
14387 cat >conftest.$ac_ext <<_ACEOF
14388 #line 14388 "configure"
14389 #include "confdefs.h"
14391 #include <stdlib.h>
14392 #include <stdarg.h>
14395 #ifdef HAVE_LIBUTF8_H
14396 #include <libutf8.h>
14406 rm -f conftest.$ac_objext
14407 if { (eval echo "$as_me:14407: \"$ac_compile\"") >&5
14408 (eval $ac_compile) 2>&5
14410 echo "$as_me:14410: \$? = $ac_status" >&5
14411 (exit $ac_status); } &&
14412 { ac_try='test -s conftest.$ac_objext'
14413 { (eval echo "$as_me:14413: \"$ac_try\"") >&5
14414 (eval $ac_try) 2>&5
14416 echo "$as_me:14416: \$? = $ac_status" >&5
14417 (exit $ac_status); }; }; then
14420 echo "$as_me: failed program was:" >&5
14421 cat conftest.$ac_ext >&5
14422 cf_cv_wint_t=unknown
14424 rm -f conftest.$ac_objext conftest.$ac_ext
14426 rm -f conftest.$ac_objext conftest.$ac_ext
14428 echo "$as_me:14428: result: $cf_cv_wint_t" >&5
14429 echo "${ECHO_T}$cf_cv_wint_t" >&6
14431 if test "$cf_cv_wint_t" = yes ; then
14432 cat >>confdefs.h <<\EOF
14433 #define NEED_WCHAR_H 1
14439 # if we do not find wint_t in either place, use substitution to provide a fallback.
14440 if test "$cf_cv_wint_t" = unknown ; then
14444 # if we find wint_t in either place, use substitution to provide a fallback.
14445 if test "$cf_cv_wint_t" != unknown ; then
14446 NCURSES_OK_WINT_T=1
14449 if test "$NCURSES_OK_MBSTATE_T" = 0 ; then
14451 echo "$as_me:14451: checking for type mbstate_t in ${cf_cv_ncurses_header:-curses.h}" >&5
14452 echo $ECHO_N "checking for type mbstate_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
14453 cat >conftest.$ac_ext <<_ACEOF
14454 #line 14454 "configure"
14455 #include "confdefs.h"
14457 #ifndef _XOPEN_SOURCE_EXTENDED
14458 #define _XOPEN_SOURCE_EXTENDED
14460 #include <${cf_cv_ncurses_header:-curses.h}>
14471 rm -f conftest.$ac_objext
14472 if { (eval echo "$as_me:14472: \"$ac_compile\"") >&5
14473 (eval $ac_compile) 2>&5
14475 echo "$as_me:14475: \$? = $ac_status" >&5
14476 (exit $ac_status); } &&
14477 { ac_try='test -s conftest.$ac_objext'
14478 { (eval echo "$as_me:14478: \"$ac_try\"") >&5
14479 (eval $ac_try) 2>&5
14481 echo "$as_me:14481: \$? = $ac_status" >&5
14482 (exit $ac_status); }; }; then
14485 echo "$as_me: failed program was:" >&5
14486 cat conftest.$ac_ext >&5
14489 rm -f conftest.$ac_objext conftest.$ac_ext
14490 echo "$as_me:14490: result: $cf_result" >&5
14491 echo "${ECHO_T}$cf_result" >&6
14492 if test $cf_result = yes ; then
14494 cf_result=`echo "have_type_mbstate_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14496 cat >>confdefs.h <<EOF
14497 #define $cf_result 1
14501 cat >>confdefs.h <<EOF
14502 #define mbstate_t long
14509 if test "$NCURSES_OK_WCHAR_T" = 0 ; then
14511 echo "$as_me:14511: checking for type wchar_t in ${cf_cv_ncurses_header:-curses.h}" >&5
14512 echo $ECHO_N "checking for type wchar_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
14513 cat >conftest.$ac_ext <<_ACEOF
14514 #line 14514 "configure"
14515 #include "confdefs.h"
14517 #ifndef _XOPEN_SOURCE_EXTENDED
14518 #define _XOPEN_SOURCE_EXTENDED
14520 #include <${cf_cv_ncurses_header:-curses.h}>
14531 rm -f conftest.$ac_objext
14532 if { (eval echo "$as_me:14532: \"$ac_compile\"") >&5
14533 (eval $ac_compile) 2>&5
14535 echo "$as_me:14535: \$? = $ac_status" >&5
14536 (exit $ac_status); } &&
14537 { ac_try='test -s conftest.$ac_objext'
14538 { (eval echo "$as_me:14538: \"$ac_try\"") >&5
14539 (eval $ac_try) 2>&5
14541 echo "$as_me:14541: \$? = $ac_status" >&5
14542 (exit $ac_status); }; }; then
14545 echo "$as_me: failed program was:" >&5
14546 cat conftest.$ac_ext >&5
14549 rm -f conftest.$ac_objext conftest.$ac_ext
14550 echo "$as_me:14550: result: $cf_result" >&5
14551 echo "${ECHO_T}$cf_result" >&6
14552 if test $cf_result = yes ; then
14554 cf_result=`echo "have_type_wchar_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14556 cat >>confdefs.h <<EOF
14557 #define $cf_result 1
14561 cat >>confdefs.h <<EOF
14562 #define wchar_t long
14569 if test "$NCURSES_OK_WINT_T" = 0 ; then
14571 echo "$as_me:14571: checking for type wint_t in ${cf_cv_ncurses_header:-curses.h}" >&5
14572 echo $ECHO_N "checking for type wint_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
14573 cat >conftest.$ac_ext <<_ACEOF
14574 #line 14574 "configure"
14575 #include "confdefs.h"
14577 #ifndef _XOPEN_SOURCE_EXTENDED
14578 #define _XOPEN_SOURCE_EXTENDED
14580 #include <${cf_cv_ncurses_header:-curses.h}>
14591 rm -f conftest.$ac_objext
14592 if { (eval echo "$as_me:14592: \"$ac_compile\"") >&5
14593 (eval $ac_compile) 2>&5
14595 echo "$as_me:14595: \$? = $ac_status" >&5
14596 (exit $ac_status); } &&
14597 { ac_try='test -s conftest.$ac_objext'
14598 { (eval echo "$as_me:14598: \"$ac_try\"") >&5
14599 (eval $ac_try) 2>&5
14601 echo "$as_me:14601: \$? = $ac_status" >&5
14602 (exit $ac_status); }; }; then
14605 echo "$as_me: failed program was:" >&5
14606 cat conftest.$ac_ext >&5
14609 rm -f conftest.$ac_objext conftest.$ac_ext
14610 echo "$as_me:14610: result: $cf_result" >&5
14611 echo "${ECHO_T}$cf_result" >&6
14612 if test $cf_result = yes ; then
14614 cf_result=`echo "have_type_wint_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14616 cat >>confdefs.h <<EOF
14617 #define $cf_result 1
14621 cat >>confdefs.h <<EOF
14622 #define wint_t long
14629 echo "$as_me:14629: checking for data boolnames declaration in ${cf_cv_ncurses_header:-curses.h}" >&5
14630 echo $ECHO_N "checking for data boolnames declaration in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
14632 cat >conftest.$ac_ext <<_ACEOF
14633 #line 14633 "configure"
14634 #include "confdefs.h"
14636 #ifdef HAVE_XCURSES
14637 #include <xcurses.h>
14638 char * XCursesProgramName = "test";
14640 #include <${cf_cv_ncurses_header:-curses.h}>
14641 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
14642 #include <ncursesw/term.h>
14643 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
14644 #include <ncurses/term.h>
14645 #elif defined(HAVE_TERM_H)
14654 void *foo = &(boolnames)
14660 rm -f conftest.$ac_objext
14661 if { (eval echo "$as_me:14661: \"$ac_compile\"") >&5
14662 (eval $ac_compile) 2>&5
14664 echo "$as_me:14664: \$? = $ac_status" >&5
14665 (exit $ac_status); } &&
14666 { ac_try='test -s conftest.$ac_objext'
14667 { (eval echo "$as_me:14667: \"$ac_try\"") >&5
14668 (eval $ac_try) 2>&5
14670 echo "$as_me:14670: \$? = $ac_status" >&5
14671 (exit $ac_status); }; }; then
14674 echo "$as_me: failed program was:" >&5
14675 cat conftest.$ac_ext >&5
14678 rm -f conftest.$ac_objext conftest.$ac_ext
14679 echo "$as_me:14679: result: $cf_result" >&5
14680 echo "${ECHO_T}$cf_result" >&6
14682 if test $cf_result = yes ; then
14684 cf_result=`echo "have_curses_data_boolnames" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14686 cat >>confdefs.h <<EOF
14687 #define $cf_result 1
14691 echo "$as_me:14691: checking for data boolnames in library" >&5
14692 echo $ECHO_N "checking for data boolnames in library... $ECHO_C" >&6
14693 # BSD linkers insist on making weak linkage, but resolve at runtime.
14694 if test "$cross_compiling" = yes; then
14697 cat >conftest.$ac_ext <<_ACEOF
14698 #line 14698 "configure"
14699 #include "confdefs.h"
14701 #ifdef HAVE_XCURSES
14702 #include <xcurses.h>
14703 char * XCursesProgramName = "test";
14705 #include <${cf_cv_ncurses_header:-curses.h}>
14706 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
14707 #include <ncursesw/term.h>
14708 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
14709 #include <ncurses/term.h>
14710 #elif defined(HAVE_TERM_H)
14715 extern char boolnames;
14721 void *foo = &(boolnames);
14722 ${cf_cv_main_return:-return}(foo == 0);
14729 rm -f conftest.$ac_objext conftest$ac_exeext
14730 if { (eval echo "$as_me:14730: \"$ac_link\"") >&5
14731 (eval $ac_link) 2>&5
14733 echo "$as_me:14733: \$? = $ac_status" >&5
14734 (exit $ac_status); } &&
14735 { ac_try='test -s conftest$ac_exeext'
14736 { (eval echo "$as_me:14736: \"$ac_try\"") >&5
14737 (eval $ac_try) 2>&5
14739 echo "$as_me:14739: \$? = $ac_status" >&5
14740 (exit $ac_status); }; }; then
14743 echo "$as_me: failed program was:" >&5
14744 cat conftest.$ac_ext >&5
14747 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14750 cat >conftest.$ac_ext <<_ACEOF
14751 #line 14751 "configure"
14752 #include "confdefs.h"
14754 #ifdef HAVE_XCURSES
14755 #include <xcurses.h>
14756 char * XCursesProgramName = "test";
14758 #include <${cf_cv_ncurses_header:-curses.h}>
14759 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
14760 #include <ncursesw/term.h>
14761 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
14762 #include <ncurses/term.h>
14763 #elif defined(HAVE_TERM_H)
14768 extern char boolnames;
14771 void *foo = &(boolnames);
14772 ${cf_cv_main_return:-return}(foo == 0);
14775 rm -f conftest$ac_exeext
14776 if { (eval echo "$as_me:14776: \"$ac_link\"") >&5
14777 (eval $ac_link) 2>&5
14779 echo "$as_me:14779: \$? = $ac_status" >&5
14780 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14781 { (eval echo "$as_me:14781: \"$ac_try\"") >&5
14782 (eval $ac_try) 2>&5
14784 echo "$as_me:14784: \$? = $ac_status" >&5
14785 (exit $ac_status); }; }; then
14788 echo "$as_me: program exited with status $ac_status" >&5
14789 echo "$as_me: failed program was:" >&5
14790 cat conftest.$ac_ext >&5
14793 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14795 echo "$as_me:14795: result: $cf_result" >&5
14796 echo "${ECHO_T}$cf_result" >&6
14797 if test $cf_result = yes ; then
14799 cf_result=`echo "decl_curses_data_boolnames" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14801 cat >>confdefs.h <<EOF
14802 #define $cf_result 1
14808 echo "$as_me:14808: checking for data boolfnames declaration in ${cf_cv_ncurses_header:-curses.h}" >&5
14809 echo $ECHO_N "checking for data boolfnames declaration in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
14811 cat >conftest.$ac_ext <<_ACEOF
14812 #line 14812 "configure"
14813 #include "confdefs.h"
14815 #ifdef HAVE_XCURSES
14816 #include <xcurses.h>
14817 char * XCursesProgramName = "test";
14819 #include <${cf_cv_ncurses_header:-curses.h}>
14820 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
14821 #include <ncursesw/term.h>
14822 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
14823 #include <ncurses/term.h>
14824 #elif defined(HAVE_TERM_H)
14833 void *foo = &(boolfnames)
14839 rm -f conftest.$ac_objext
14840 if { (eval echo "$as_me:14840: \"$ac_compile\"") >&5
14841 (eval $ac_compile) 2>&5
14843 echo "$as_me:14843: \$? = $ac_status" >&5
14844 (exit $ac_status); } &&
14845 { ac_try='test -s conftest.$ac_objext'
14846 { (eval echo "$as_me:14846: \"$ac_try\"") >&5
14847 (eval $ac_try) 2>&5
14849 echo "$as_me:14849: \$? = $ac_status" >&5
14850 (exit $ac_status); }; }; then
14853 echo "$as_me: failed program was:" >&5
14854 cat conftest.$ac_ext >&5
14857 rm -f conftest.$ac_objext conftest.$ac_ext
14858 echo "$as_me:14858: result: $cf_result" >&5
14859 echo "${ECHO_T}$cf_result" >&6
14861 if test $cf_result = yes ; then
14863 cf_result=`echo "have_curses_data_boolfnames" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14865 cat >>confdefs.h <<EOF
14866 #define $cf_result 1
14870 echo "$as_me:14870: checking for data boolfnames in library" >&5
14871 echo $ECHO_N "checking for data boolfnames in library... $ECHO_C" >&6
14872 # BSD linkers insist on making weak linkage, but resolve at runtime.
14873 if test "$cross_compiling" = yes; then
14876 cat >conftest.$ac_ext <<_ACEOF
14877 #line 14877 "configure"
14878 #include "confdefs.h"
14880 #ifdef HAVE_XCURSES
14881 #include <xcurses.h>
14882 char * XCursesProgramName = "test";
14884 #include <${cf_cv_ncurses_header:-curses.h}>
14885 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
14886 #include <ncursesw/term.h>
14887 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
14888 #include <ncurses/term.h>
14889 #elif defined(HAVE_TERM_H)
14894 extern char boolfnames;
14900 void *foo = &(boolfnames);
14901 ${cf_cv_main_return:-return}(foo == 0);
14908 rm -f conftest.$ac_objext conftest$ac_exeext
14909 if { (eval echo "$as_me:14909: \"$ac_link\"") >&5
14910 (eval $ac_link) 2>&5
14912 echo "$as_me:14912: \$? = $ac_status" >&5
14913 (exit $ac_status); } &&
14914 { ac_try='test -s conftest$ac_exeext'
14915 { (eval echo "$as_me:14915: \"$ac_try\"") >&5
14916 (eval $ac_try) 2>&5
14918 echo "$as_me:14918: \$? = $ac_status" >&5
14919 (exit $ac_status); }; }; then
14922 echo "$as_me: failed program was:" >&5
14923 cat conftest.$ac_ext >&5
14926 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14929 cat >conftest.$ac_ext <<_ACEOF
14930 #line 14930 "configure"
14931 #include "confdefs.h"
14933 #ifdef HAVE_XCURSES
14934 #include <xcurses.h>
14935 char * XCursesProgramName = "test";
14937 #include <${cf_cv_ncurses_header:-curses.h}>
14938 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
14939 #include <ncursesw/term.h>
14940 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
14941 #include <ncurses/term.h>
14942 #elif defined(HAVE_TERM_H)
14947 extern char boolfnames;
14950 void *foo = &(boolfnames);
14951 ${cf_cv_main_return:-return}(foo == 0);
14954 rm -f conftest$ac_exeext
14955 if { (eval echo "$as_me:14955: \"$ac_link\"") >&5
14956 (eval $ac_link) 2>&5
14958 echo "$as_me:14958: \$? = $ac_status" >&5
14959 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14960 { (eval echo "$as_me:14960: \"$ac_try\"") >&5
14961 (eval $ac_try) 2>&5
14963 echo "$as_me:14963: \$? = $ac_status" >&5
14964 (exit $ac_status); }; }; then
14967 echo "$as_me: program exited with status $ac_status" >&5
14968 echo "$as_me: failed program was:" >&5
14969 cat conftest.$ac_ext >&5
14972 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14974 echo "$as_me:14974: result: $cf_result" >&5
14975 echo "${ECHO_T}$cf_result" >&6
14976 if test $cf_result = yes ; then
14978 cf_result=`echo "decl_curses_data_boolfnames" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14980 cat >>confdefs.h <<EOF
14981 #define $cf_result 1
14990 ac_config_files="$ac_config_files Makefile"
14991 ac_config_commands="$ac_config_commands default"
14992 cat >confcache <<\_ACEOF
14993 # This file is a shell script that caches the results of configure
14994 # tests run on this system so they can be shared between configure
14995 # scripts and configure runs, see configure's option --config-cache.
14996 # It is not useful on other systems. If it contains results you don't
14997 # want to keep, you may remove or edit it.
14999 # config.status only pays attention to the cache file if you give it
15000 # the --recheck option to rerun configure.
15002 # `ac_cv_env_foo' variables (set or unset) will be overriden when
15003 # loading this file, other *unset* `ac_cv_foo' will be assigned the
15004 # following values.
15008 # The following way of writing the cache mishandles newlines in values,
15009 # but we know of no workaround that is simple, portable, and efficient.
15010 # So, don't put newlines in cache variables' values.
15011 # Ultrix sh set writes to stderr and can't be redirected directly,
15012 # and sets the high bit in the cache file unless we assign to the vars.
15015 case `(ac_space=' '; set | grep ac_space) 2>&1` in
15017 # `set' does not quote correctly, so add quotes (double-quote
15018 # substitution turns \\\\ into \\, and sed turns \\ into \).
15021 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
15024 # `set' quotes correctly as required by POSIX, so do not add quotes.
15026 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
15033 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
15035 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
15037 if cmp -s $cache_file confcache; then :; else
15038 if test -w $cache_file; then
15039 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
15040 cat confcache >$cache_file
15042 echo "not updating unwritable cache $cache_file"
15047 test "x$prefix" = xNONE && prefix=$ac_default_prefix
15048 # Let make expand exec_prefix.
15049 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
15051 # VPATH may cause trouble with some makes, so we remove $(srcdir),
15052 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
15053 # trailing colons and then remove the whole line if VPATH becomes empty
15054 # (actually we leave an empty line to preserve line numbers).
15055 if test "x$srcdir" = x.; then
15056 ac_vpsub='/^[ ]*VPATH[ ]*=/{
15057 s/:*\$(srcdir):*/:/;
15058 s/:*\${srcdir}:*/:/;
15060 s/^\([^=]*=[ ]*\):*/\1/;
15066 DEFS=-DHAVE_CONFIG_H
15068 : ${CONFIG_STATUS=./config.status}
15069 ac_clean_files_save=$ac_clean_files
15070 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
15071 { echo "$as_me:15071: creating $CONFIG_STATUS" >&5
15072 echo "$as_me: creating $CONFIG_STATUS" >&6;}
15073 cat >$CONFIG_STATUS <<_ACEOF
15075 # Generated automatically by configure.
15076 # Run this file to recreate the current configuration.
15077 # Compiler output produced by configure, useful for debugging
15078 # configure, is in config.log if it exists.
15081 SHELL=\${CONFIG_SHELL-$SHELL}
15082 ac_cs_invocation="\$0 \$@"
15086 cat >>$CONFIG_STATUS <<\_ACEOF
15087 # Be Bourne compatible
15088 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
15091 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
15095 # Name of the executable.
15096 as_me=`echo "$0" |sed 's,.*[\\/],,'`
15098 if expr a : '\(a\)' >/dev/null 2>&1; then
15104 rm -f conf$$ conf$$.exe conf$$.file
15106 if ln -s conf$$.file conf$$ 2>/dev/null; then
15107 # We could just check for DJGPP; but this test a) works b) is more generic
15108 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
15109 if test -f conf$$.exe; then
15110 # Don't use ln at all; we don't have any links
15115 elif ln conf$$.file conf$$ 2>/dev/null; then
15120 rm -f conf$$ conf$$.exe conf$$.file
15122 as_executable_p="test -f"
15124 # Support unset when possible.
15125 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
15132 $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
15133 $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
15134 $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
15135 $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
15136 $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
15137 $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
15138 $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
15139 $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
15142 # We need space, tab and new line, in precisely that order.
15148 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
15154 # Files that config.status was made for.
15155 if test -n "$ac_config_files"; then
15156 echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
15159 if test -n "$ac_config_headers"; then
15160 echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
15163 if test -n "$ac_config_links"; then
15164 echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
15167 if test -n "$ac_config_commands"; then
15168 echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
15171 cat >>$CONFIG_STATUS <<\EOF
15174 \`$as_me' instantiates files from templates according to the
15175 current configuration.
15177 Usage: $0 [OPTIONS] [FILE]...
15179 -h, --help print this help, then exit
15180 -V, --version print version number, then exit
15181 -d, --debug don't remove temporary files
15182 --recheck update $as_me by reconfiguring in the same conditions
15183 --file=FILE[:TEMPLATE]
15184 instantiate the configuration file FILE
15185 --header=FILE[:TEMPLATE]
15186 instantiate the configuration header FILE
15188 Configuration files:
15191 Configuration headers:
15194 Configuration commands:
15197 Report bugs to <dickey@invisible-island.net>."
15200 cat >>$CONFIG_STATUS <<EOF
15203 configured by $0, generated by GNU Autoconf 2.52.20101001,
15204 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
15206 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
15207 Free Software Foundation, Inc.
15208 This config.status script is free software; the Free Software Foundation
15209 gives unlimited permission to copy, distribute and modify it."
15214 cat >>$CONFIG_STATUS <<\EOF
15215 # If no file are specified by the user, then we need to provide default
15216 # value. By we need to know if files were specified by the user.
15222 ac_option=`expr "x$1" : 'x\([^=]*\)='`
15223 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
15225 set dummy "$ac_option" "$ac_optarg" ${1+"$@"}
15229 *) # This is not an option, so the user has probably given explicit
15231 ac_need_defaults=false;;
15235 # Handling of the options.
15237 cat >>$CONFIG_STATUS <<EOF
15238 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
15239 echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion"
15240 exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;;
15242 cat >>$CONFIG_STATUS <<\EOF
15243 --version | --vers* | -V )
15244 echo "$ac_cs_version"; exit 0 ;;
15246 # Conflict between --help and --header
15247 { { echo "$as_me:15247: error: ambiguous option: $1
15248 Try \`$0 --help' for more information." >&5
15249 echo "$as_me: error: ambiguous option: $1
15250 Try \`$0 --help' for more information." >&2;}
15251 { (exit 1); exit 1; }; };;
15252 --help | --hel | -h )
15253 echo "$ac_cs_usage"; exit 0 ;;
15254 --debug | --d* | -d )
15256 --file | --fil | --fi | --f )
15258 CONFIG_FILES="$CONFIG_FILES $1"
15259 ac_need_defaults=false;;
15260 --header | --heade | --head | --hea )
15262 CONFIG_HEADERS="$CONFIG_HEADERS $1"
15263 ac_need_defaults=false;;
15265 # This is an error.
15266 -*) { { echo "$as_me:15266: error: unrecognized option: $1
15267 Try \`$0 --help' for more information." >&5
15268 echo "$as_me: error: unrecognized option: $1
15269 Try \`$0 --help' for more information." >&2;}
15270 { (exit 1); exit 1; }; } ;;
15272 *) ac_config_targets="$ac_config_targets $1" ;;
15281 ## ----------------------- ##
15282 ## Running config.status. ##
15283 ## ----------------------- ##
15285 This file was extended by $as_me 2.52.20101001, executed with
15286 CONFIG_FILES = $CONFIG_FILES
15287 CONFIG_HEADERS = $CONFIG_HEADERS
15288 CONFIG_LINKS = $CONFIG_LINKS
15289 CONFIG_COMMANDS = $CONFIG_COMMANDS
15290 > $ac_cs_invocation
15291 on `(hostname || uname -n) 2>/dev/null | sed 1q`
15296 cat >>$CONFIG_STATUS <<EOF
15298 # INIT-COMMANDS section.
15306 cat >>$CONFIG_STATUS <<\EOF
15307 for ac_config_target in $ac_config_targets
15309 case "$ac_config_target" in
15310 # Handling of arguments.
15311 "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
15312 "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
15313 "ncurses_cfg.h" ) CONFIG_HEADERS="$CONFIG_HEADERS ncurses_cfg.h:ncurses_tst.hin" ;;
15314 *) { { echo "$as_me:15314: error: invalid argument: $ac_config_target" >&5
15315 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
15316 { (exit 1); exit 1; }; };;
15320 # If the user did not use the arguments to specify the items to instantiate,
15321 # then the envvar interface is used. Set only those that are not.
15322 # We use the long form for the default assignment because of an extremely
15323 # bizarre bug on SunOS 4.1.3.
15324 if $ac_need_defaults; then
15325 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
15326 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
15327 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
15330 # Create a temporary directory, and hook for its removal unless debugging.
15333 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
15334 trap '{ (exit 1); exit 1; }' 1 2 13 15
15337 # Create a (secure) tmp directory for tmp files.
15340 tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` &&
15341 test -n "$tmp" && test -d "$tmp"
15344 tmp=$TMPDIR/cs$$-$RANDOM
15345 (umask 077 && mkdir $tmp)
15348 echo "$me: cannot create a temporary directory in $TMPDIR" >&2
15349 { (exit 1); exit 1; }
15354 cat >>$CONFIG_STATUS <<EOF
15357 # CONFIG_FILES section.
15360 # No need to generate the scripts if there are no CONFIG_FILES.
15361 # This happens for instance when ./config.status config.h
15362 if test -n "\$CONFIG_FILES"; then
15363 # Protect against being on the right side of a sed subst in config.status.
15364 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
15365 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
15366 s,@SHELL@,$SHELL,;t t
15367 s,@exec_prefix@,$exec_prefix,;t t
15368 s,@prefix@,$prefix,;t t
15369 s,@program_transform_name@,$program_transform_name,;t t
15370 s,@bindir@,$bindir,;t t
15371 s,@sbindir@,$sbindir,;t t
15372 s,@libexecdir@,$libexecdir,;t t
15373 s,@datadir@,$datadir,;t t
15374 s,@sysconfdir@,$sysconfdir,;t t
15375 s,@sharedstatedir@,$sharedstatedir,;t t
15376 s,@localstatedir@,$localstatedir,;t t
15377 s,@libdir@,$libdir,;t t
15378 s,@includedir@,$includedir,;t t
15379 s,@oldincludedir@,$oldincludedir,;t t
15380 s,@infodir@,$infodir,;t t
15381 s,@mandir@,$mandir,;t t
15382 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
15383 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
15384 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
15385 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
15386 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
15387 s,@build_alias@,$build_alias,;t t
15388 s,@host_alias@,$host_alias,;t t
15389 s,@target_alias@,$target_alias,;t t
15390 s,@ECHO_C@,$ECHO_C,;t t
15391 s,@ECHO_N@,$ECHO_N,;t t
15392 s,@ECHO_T@,$ECHO_T,;t t
15393 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
15394 s,@DEFS@,$DEFS,;t t
15395 s,@LIBS@,$LIBS,;t t
15396 s,@build@,$build,;t t
15397 s,@build_cpu@,$build_cpu,;t t
15398 s,@build_vendor@,$build_vendor,;t t
15399 s,@build_os@,$build_os,;t t
15400 s,@host@,$host,;t t
15401 s,@host_cpu@,$host_cpu,;t t
15402 s,@host_vendor@,$host_vendor,;t t
15403 s,@host_os@,$host_os,;t t
15404 s,@SET_MAKE@,$SET_MAKE,;t t
15406 s,@CFLAGS@,$CFLAGS,;t t
15407 s,@LDFLAGS@,$LDFLAGS,;t t
15408 s,@CPPFLAGS@,$CPPFLAGS,;t t
15409 s,@ac_ct_CC@,$ac_ct_CC,;t t
15410 s,@EXEEXT@,$EXEEXT,;t t
15411 s,@OBJEXT@,$OBJEXT,;t t
15414 s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
15415 s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
15416 s,@INSTALL_DATA@,$INSTALL_DATA,;t t
15417 s,@LINT@,$LINT,;t t
15418 s,@LINT_OPTS@,$LINT_OPTS,;t t
15419 s,@CTAGS@,$CTAGS,;t t
15420 s,@ETAGS@,$ETAGS,;t t
15421 s,@MAKE_LOWER_TAGS@,$MAKE_LOWER_TAGS,;t t
15422 s,@MAKE_UPPER_TAGS@,$MAKE_UPPER_TAGS,;t t
15423 s,@MATH_LIB@,$MATH_LIB,;t t
15424 s,@CC_G_OPT@,$CC_G_OPT,;t t
15425 s,@CC_SHARED_OPTS@,$CC_SHARED_OPTS,;t t
15426 s,@DFT_DEP_SUFFIX@,$DFT_DEP_SUFFIX,;t t
15427 s,@DFT_OBJ_SUBDIR@,$DFT_OBJ_SUBDIR,;t t
15428 s,@DFT_UPR_MODEL@,$DFT_UPR_MODEL,;t t
15430 s,@LDFLAGS_SHARED@,$LDFLAGS_SHARED,;t t
15431 s,@LDFLAGS_STATIC@,$LDFLAGS_STATIC,;t t
15432 s,@LD_MODEL@,$LD_MODEL,;t t
15433 s,@LD_SHARED_OPTS@,$LD_SHARED_OPTS,;t t
15434 s,@LIBTOOL@,$LIBTOOL,;t t
15435 s,@LIB_CLEAN@,$LIB_CLEAN,;t t
15436 s,@LIB_COMPILE@,$LIB_COMPILE,;t t
15437 s,@LIB_LINK@,$LIB_LINK,;t t
15438 s,@LINK_TESTS@,$LINK_TESTS,;t t
15439 s,@LOCAL_LDFLAGS@,$LOCAL_LDFLAGS,;t t
15440 s,@PTHREAD@,$PTHREAD,;t t
15441 s,@TEST_ARGS@,$TEST_ARGS,;t t
15442 s,@TEST_DEPS@,$TEST_DEPS,;t t
15443 s,@TEST_LIBS@,$TEST_LIBS,;t t
15444 s,@TINFO_ARGS@,$TINFO_ARGS,;t t
15445 s,@cf_cv_abi_version@,$cf_cv_abi_version,;t t
15446 s,@cf_cv_rel_version@,$cf_cv_rel_version,;t t
15447 s,@EXTRA_CPPFLAGS@,$EXTRA_CPPFLAGS,;t t
15448 s,@ECHO_LT@,$ECHO_LT,;t t
15449 s,@ECHO_LD@,$ECHO_LD,;t t
15450 s,@RULE_CC@,$RULE_CC,;t t
15451 s,@SHOW_CC@,$SHOW_CC,;t t
15452 s,@ECHO_CC@,$ECHO_CC,;t t
15453 s,@EXTRA_CFLAGS@,$EXTRA_CFLAGS,;t t
15454 s,@NCURSES_CONFIG@,$NCURSES_CONFIG,;t t
15455 s,@PKG_CONFIG@,$PKG_CONFIG,;t t
15456 s,@X_CFLAGS@,$X_CFLAGS,;t t
15457 s,@X_PRE_LIBS@,$X_PRE_LIBS,;t t
15458 s,@X_LIBS@,$X_LIBS,;t t
15459 s,@X_EXTRA_LIBS@,$X_EXTRA_LIBS,;t t
15460 s,@XCURSES_CONFIG@,$XCURSES_CONFIG,;t t
15461 s,@NCURSES_WRAP_PREFIX@,$NCURSES_WRAP_PREFIX,;t t
15466 cat >>$CONFIG_STATUS <<\EOF
15467 # Split the substitutions into bite-sized pieces for seds with
15468 # small command number limits, like on Digital OSF/1 and HP-UX.
15469 ac_max_sed_lines=48
15470 ac_sed_frag=1 # Number of current file.
15471 ac_beg=1 # First line for current file.
15472 ac_end=$ac_max_sed_lines # Line after last line for current file.
15475 while $ac_more_lines; do
15476 if test $ac_beg -gt 1; then
15477 sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
15479 sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
15481 if test ! -s $tmp/subs.frag; then
15482 ac_more_lines=false
15484 # The purpose of the label and of the branching condition is to
15485 # speed up the sed processing (if there are no `@' at all, there
15486 # is no need to browse any of the substitutions).
15487 # These are the two extra sed commands mentioned above.
15489 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
15490 if test -z "$ac_sed_cmds"; then
15491 ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
15493 ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
15495 ac_sed_frag=`expr $ac_sed_frag + 1`
15497 ac_end=`expr $ac_end + $ac_max_sed_lines`
15500 if test -z "$ac_sed_cmds"; then
15503 fi # test -n "$CONFIG_FILES"
15506 cat >>$CONFIG_STATUS <<\EOF
15507 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
15508 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
15510 - | *:- | *:-:* ) # input from stdin
15512 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
15513 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
15514 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
15515 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
15516 * ) ac_file_in=$ac_file.in ;;
15519 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
15520 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
15521 X"$ac_file" : 'X\(//\)[^/]' \| \
15522 X"$ac_file" : 'X\(//\)$' \| \
15523 X"$ac_file" : 'X\(/\)' \| \
15524 . : '\(.\)' 2>/dev/null ||
15526 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
15527 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
15528 /^X\(\/\/\)$/{ s//\1/; q; }
15529 /^X\(\/\).*/{ s//\1/; q; }
15531 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
15532 { case "$ac_dir" in
15533 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
15537 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
15538 case $as_mkdir_dir in
15539 # Skip DOS drivespec
15540 ?:) as_incr_dir=$as_mkdir_dir ;;
15542 as_incr_dir=$as_incr_dir/$as_mkdir_dir
15543 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
15548 ac_dir_suffix="/`echo $ac_dir|sed 's,^\./,,'`"
15549 # A "../" for each directory in $ac_dir_suffix.
15550 ac_dots=`echo "$ac_dir_suffix" | sed 's,/[^/]*,../,g'`
15552 ac_dir_suffix= ac_dots=
15557 if test -z "$ac_dots"; then
15560 ac_top_srcdir=`echo $ac_dots | sed 's,/$,,'`
15562 [\\/]* | ?:[\\/]* )
15563 ac_srcdir=$srcdir$ac_dir_suffix;
15564 ac_top_srcdir=$srcdir ;;
15565 *) # Relative path.
15566 ac_srcdir=$ac_dots$srcdir$ac_dir_suffix
15567 ac_top_srcdir=$ac_dots$srcdir ;;
15571 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
15572 *) ac_INSTALL=$ac_dots$INSTALL ;;
15575 if test x"$ac_file" != x-; then
15576 { echo "$as_me:15576: creating $ac_file" >&5
15577 echo "$as_me: creating $ac_file" >&6;}
15580 # Let's still pretend it is `configure' which instantiates (i.e., don't
15581 # use $as_me), people would be surprised to read:
15582 # /* config.h. Generated automatically by config.status. */
15583 configure_input="Generated automatically from `echo $ac_file_in |
15584 sed 's,.*/,,'` by configure."
15586 # First look for the input files in the build tree, otherwise in the
15588 ac_file_inputs=`IFS=:
15589 for f in $ac_file_in; do
15591 -) echo $tmp/stdin ;;
15593 # Absolute (can't be DOS-style, as IFS=:)
15594 test -f "$f" || { { echo "$as_me:15594: error: cannot find input file: $f" >&5
15595 echo "$as_me: error: cannot find input file: $f" >&2;}
15596 { (exit 1); exit 1; }; }
15599 if test -f "$f"; then
15602 elif test -f "$srcdir/$f"; then
15607 { { echo "$as_me:15607: error: cannot find input file: $f" >&5
15608 echo "$as_me: error: cannot find input file: $f" >&2;}
15609 { (exit 1); exit 1; }; }
15612 done` || { (exit 1); exit 1; }
15614 cat >>$CONFIG_STATUS <<EOF
15618 cat >>$CONFIG_STATUS <<\EOF
15620 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
15621 s,@configure_input@,$configure_input,;t t
15622 s,@srcdir@,$ac_srcdir,;t t
15623 s,@top_srcdir@,$ac_top_srcdir,;t t
15624 s,@INSTALL@,$ac_INSTALL,;t t
15625 " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
15627 if test x"$ac_file" != x-; then
15628 mv $tmp/out $ac_file
15636 cat >>$CONFIG_STATUS <<\EOF
15639 # CONFIG_HEADER section.
15642 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
15643 # NAME is the cpp macro being defined and VALUE is the value it is being given.
15645 # ac_d sets the value in "#define NAME VALUE" lines.
15646 ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
15647 ac_dB='[ ].*$,\1#\2'
15650 # ac_i turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
15651 ac_iA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
15652 ac_iB='\([ ]\),\1#\2define\3'
15655 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
15656 ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
15657 ac_uB='$,\1#\2define\3'
15661 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
15662 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
15664 - | *:- | *:-:* ) # input from stdin
15666 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
15667 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
15668 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
15669 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
15670 * ) ac_file_in=$ac_file.in ;;
15673 test x"$ac_file" != x- && { echo "$as_me:15673: creating $ac_file" >&5
15674 echo "$as_me: creating $ac_file" >&6;}
15676 # First look for the input files in the build tree, otherwise in the
15678 ac_file_inputs=`IFS=:
15679 for f in $ac_file_in; do
15681 -) echo $tmp/stdin ;;
15683 # Absolute (can't be DOS-style, as IFS=:)
15684 test -f "$f" || { { echo "$as_me:15684: error: cannot find input file: $f" >&5
15685 echo "$as_me: error: cannot find input file: $f" >&2;}
15686 { (exit 1); exit 1; }; }
15689 if test -f "$f"; then
15692 elif test -f "$srcdir/$f"; then
15697 { { echo "$as_me:15697: error: cannot find input file: $f" >&5
15698 echo "$as_me: error: cannot find input file: $f" >&2;}
15699 { (exit 1); exit 1; }; }
15702 done` || { (exit 1); exit 1; }
15703 # Remove the trailing spaces.
15704 sed 's/[ ]*$//' $ac_file_inputs >$tmp/in
15708 # Transform confdefs.h into a list of #define's. We won't use it as a sed
15709 # script, but as data to insert where we see @DEFS@. We expect AC_SAVE_DEFS to
15710 # be either 'cat' or 'sort'.
15711 cat confdefs.h | uniq >conftest.vals
15713 # Break up conftest.vals because some shells have a limit on
15714 # the size of here documents, and old seds have small limits too.
15716 rm -f conftest.tail
15717 echo ' rm -f conftest.frag' >> $CONFIG_STATUS
15718 while grep . conftest.vals >/dev/null
15720 # Write chunks of a limited-size here document to conftest.frag.
15721 echo ' cat >> conftest.frag <<CEOF' >> $CONFIG_STATUS
15722 sed ${ac_max_here_lines}q conftest.vals | sed -e 's/#ifdef.*/#if 0/' >> $CONFIG_STATUS
15723 echo 'CEOF' >> $CONFIG_STATUS
15724 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
15725 rm -f conftest.vals
15726 mv conftest.tail conftest.vals
15728 rm -f conftest.vals
15730 # Run sed to substitute the contents of conftest.frag into $tmp/in at the
15732 echo ' cat >> conftest.edit <<CEOF
15733 /@DEFS@/r conftest.frag
15736 sed -f conftest.edit $tmp/in > $tmp/out
15738 mv $tmp/out $tmp/in
15739 rm -f conftest.edit conftest.frag
15740 ' >> $CONFIG_STATUS
15742 cat >>$CONFIG_STATUS <<\EOF
15743 # Let's still pretend it is `configure' which instantiates (i.e., don't
15744 # use $as_me), people would be surprised to read:
15745 # /* config.h. Generated automatically by config.status. */
15746 if test x"$ac_file" = x-; then
15747 echo "/* Generated automatically by configure. */" >$tmp/config.h
15749 echo "/* $ac_file. Generated automatically by configure. */" >$tmp/config.h
15751 cat $tmp/in >>$tmp/config.h
15753 if test x"$ac_file" != x-; then
15754 if cmp -s $ac_file $tmp/config.h 2>/dev/null; then
15755 { echo "$as_me:15755: $ac_file is unchanged" >&5
15756 echo "$as_me: $ac_file is unchanged" >&6;}
15758 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
15759 X"$ac_file" : 'X\(//\)[^/]' \| \
15760 X"$ac_file" : 'X\(//\)$' \| \
15761 X"$ac_file" : 'X\(/\)' \| \
15762 . : '\(.\)' 2>/dev/null ||
15764 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
15765 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
15766 /^X\(\/\/\)$/{ s//\1/; q; }
15767 /^X\(\/\).*/{ s//\1/; q; }
15769 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
15770 { case "$ac_dir" in
15771 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
15775 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
15776 case $as_mkdir_dir in
15777 # Skip DOS drivespec
15778 ?:) as_incr_dir=$as_mkdir_dir ;;
15780 as_incr_dir=$as_incr_dir/$as_mkdir_dir
15781 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
15788 mv $tmp/config.h $ac_file
15792 rm -f $tmp/config.h
15796 cat >>$CONFIG_STATUS <<\EOF
15798 # CONFIG_COMMANDS section.
15800 for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
15801 ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
15802 ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
15809 if test ! -d $srcdir/$cf_dir; then
15811 elif test -f $srcdir/$cf_dir/programs; then
15812 $AWK -f $srcdir/mk-test.awk INSTALL=yes ECHO_LINK="$ECHO_LD" $srcdir/$cf_dir/programs >>$cf_dir/Makefile
15816 cat >>Makefile <<TEST_EOF
15818 # These rules are generated so we do not rely on suffix rules, which do not
15819 # work consistently for different make-programs (the '\$(MODEL)/' confuses
15820 # some, and the '\$x' confuses others).
15823 LIST=`sed -e 's/[ ].*//' -e '/^[#@]/d' $srcdir/modules`
15826 cat >>Makefile <<TEST_EOF
15828 \$(MODEL)/$N.o : \$(srcdir)/$N.c \\
15829 \$(srcdir)/test.priv.h \\
15831 @echo compiling $N; \$(CC) -c \$(CFLAGS_DEFAULT) \$(srcdir)/$N.c
15835 if test -f ../config.guess && test -f ../config.sub
15837 cat >>Makefile <<TEST_EOF
15839 # if we used CF_INHERIT for getting these files, we can remove them
15841 rm -f config.guess config.sub
15849 cat >>$CONFIG_STATUS <<\EOF
15851 { (exit 0); exit 0; }
15853 chmod +x $CONFIG_STATUS
15854 ac_clean_files=$ac_clean_files_save
15856 # configure is writing to config.log, and then calls config.status.
15857 # config.status does its own redirection, appending to config.log.
15858 # Unfortunately, on DOS this fails, as config.log is still kept open
15859 # by configure, so config.status won't be able to write to it; its
15860 # output is simply discarded. So we exec the FD to /dev/null,
15861 # effectively closing config.log, so it can be properly (re)opened and
15862 # appended to by config.status. When coming back to configure, we
15863 # need to make the FD available again.
15864 if test "$no_create" != yes; then
15867 $SHELL $CONFIG_STATUS || ac_cs_success=false
15869 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
15870 # would make configure fail if this is the last instruction.
15871 $ac_cs_success || { (exit 1); exit 1; }