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 --x-includes=DIR X include files are in DIR
659 --x-libraries=DIR X library files are in DIR
662 --build=BUILD configure for building on BUILD [guessed]
663 --host=HOST build programs to run on HOST [BUILD]
667 if test -n "$ac_init_help"; then
672 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
673 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
676 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
677 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
679 --disable-echo display "compiling" commands
680 --enable-warnings test: turn on gcc compiler warnings
681 --with-curses-dir=DIR directory in which (n)curses is installed
682 --with-5lib use SunOS sysv-libraries
683 --with-ncursesw use wide ncurses-libraries (installed)
684 --with-ncurses use ncurses-libraries (installed)
685 --with-pdcurses compile/link with pdcurses X11 library
686 --with-Xaw3d link with Xaw 3d library
687 --with-neXtaw link with neXT Athena library
688 --with-XawPlus link with Athena-Plus library
689 --with-pkg-config{=path} enable/disable use of pkg-config
690 --with-x use the X Window System
691 --with-ncurses-wrap-prefix naming-prefix for ncurses wrapped-variables
693 Some influential environment variables:
694 CC C compiler command
695 CFLAGS C compiler flags
696 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
697 nonstandard directory <lib dir>
698 CPPFLAGS C/C++ preprocessor flags, e.g. -I<include dir> if you have
699 headers in a nonstandard directory <include dir>
702 Use these variables to override the choices made by `configure' or to help
703 it to find libraries and programs with nonstandard names/locations.
708 if test "$ac_init_help" = "recursive"; then
709 # If there are subdirs, report their specific --help.
711 for ac_subdir in : $ac_subdirs_all; do test "x$ac_subdir" = x: && continue
713 # A "../" for each directory in /$ac_subdir.
714 ac_dots=`echo $ac_subdir |
715 sed 's,^\./,,;s,[^/]$,&/,;s,[^/]*/,../,g'`
718 .) # No --srcdir option. We are building in place.
719 ac_sub_srcdir=$srcdir ;;
720 [\\/]* | ?:[\\/]* ) # Absolute path.
721 ac_sub_srcdir=$srcdir/$ac_subdir ;;
723 ac_sub_srcdir=$ac_dots$srcdir/$ac_subdir ;;
726 # Check for guested configure; otherwise get Cygnus style configure.
727 if test -f $ac_sub_srcdir/configure.gnu; then
729 $SHELL $ac_sub_srcdir/configure.gnu --help=recursive
730 elif test -f $ac_sub_srcdir/configure; then
732 $SHELL $ac_sub_srcdir/configure --help=recursive
733 elif test -f $ac_sub_srcdir/configure.ac ||
734 test -f $ac_sub_srcdir/configure.in; then
738 echo "$as_me: WARNING: no configuration information is in $ac_subdir" >&2
744 test -n "$ac_init_help" && exit 0
745 if $ac_init_version; then
748 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
749 Free Software Foundation, Inc.
750 This configure script is free software; the Free Software Foundation
751 gives unlimited permission to copy, distribute and modify it.
757 This file contains any messages produced by compilers while
758 running configure, to aid debugging if configure makes a mistake.
760 It was created by $as_me, which was
761 generated by GNU Autoconf 2.52.20101001. Invocation command line was
772 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
773 uname -m = `(uname -m) 2>/dev/null || echo unknown`
774 uname -r = `(uname -r) 2>/dev/null || echo unknown`
775 uname -s = `(uname -s) 2>/dev/null || echo unknown`
776 uname -v = `(uname -v) 2>/dev/null || echo unknown`
778 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
779 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
781 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
782 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
783 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
784 hostinfo = `(hostinfo) 2>/dev/null || echo unknown`
785 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
786 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
787 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
801 # Keep a trace of the command line.
802 # Strip out --no-create and --no-recursion so they do not pile up.
803 # Also quote any args containing shell meta-characters.
809 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
810 | --no-cr | --no-c) ;;
811 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
812 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
813 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
814 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"`
815 ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
817 *) ac_configure_args="$ac_configure_args$ac_sep$ac_arg"
820 # Get rid of the leading space.
823 # When interrupted or exit'd, cleanup temporary files, and complete
824 # config.log. We remove comments because anyway the quotes in there
825 # would cause problems or look ugly.
827 # Save into config.log some information that might help in debugging.
829 echo "## ----------------- ##" >&5
830 echo "## Cache variables. ##" >&5
831 echo "## ----------------- ##" >&5
833 # The following way of writing the cache mishandles newlines in values,
836 case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
839 "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
840 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
844 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
848 sed "/^$/d" confdefs.h >conftest.log
849 if test -s conftest.log; then
851 echo "## ------------ ##" >&5
852 echo "## confdefs.h. ##" >&5
853 echo "## ------------ ##" >&5
858 test "$ac_signal" != 0 &&
859 echo "$as_me: caught signal $ac_signal" >&5
860 echo "$as_me: exit $exit_status" >&5
861 rm -rf conftest* confdefs* core core.* *.core conf$$* $ac_clean_files &&
864 for ac_signal in 1 2 13 15; do
865 trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
869 # confdefs.h avoids OS command line length limits that DEFS can exceed.
870 rm -rf conftest* confdefs.h
871 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
874 # Let the site file select an alternate cache file if it wants to.
875 # Prefer explicitly selected file to automatically selected ones.
876 if test -z "$CONFIG_SITE"; then
877 if test "x$prefix" != xNONE; then
878 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
880 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
883 for ac_site_file in $CONFIG_SITE; do
884 if test -r "$ac_site_file"; then
885 { echo "$as_me:885: loading site script $ac_site_file" >&5
886 echo "$as_me: loading site script $ac_site_file" >&6;}
887 cat "$ac_site_file" >&5
892 if test -r "$cache_file"; then
893 # Some versions of bash will fail to source /dev/null (special
894 # files actually), so we avoid doing that.
895 if test -f "$cache_file"; then
896 { echo "$as_me:896: loading cache $cache_file" >&5
897 echo "$as_me: loading cache $cache_file" >&6;}
899 [\\/]* | ?:[\\/]* ) . $cache_file;;
904 { echo "$as_me:904: creating cache $cache_file" >&5
905 echo "$as_me: creating cache $cache_file" >&6;}
909 # Check that the precious variables saved in the cache have kept the same
911 ac_cache_corrupted=false
912 for ac_var in `(set) 2>&1 |
913 sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
914 eval ac_old_set=\$ac_cv_env_${ac_var}_set
915 eval ac_new_set=\$ac_env_${ac_var}_set
916 eval ac_old_val="\$ac_cv_env_${ac_var}_value"
917 eval ac_new_val="\$ac_env_${ac_var}_value"
918 case $ac_old_set,$ac_new_set in
920 { echo "$as_me:920: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
921 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
922 ac_cache_corrupted=: ;;
924 { echo "$as_me:924: error: \`$ac_var' was not set in the previous run" >&5
925 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
926 ac_cache_corrupted=: ;;
929 if test "x$ac_old_val" != "x$ac_new_val"; then
930 { echo "$as_me:930: error: \`$ac_var' has changed since the previous run:" >&5
931 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
932 { echo "$as_me:932: former value: $ac_old_val" >&5
933 echo "$as_me: former value: $ac_old_val" >&2;}
934 { echo "$as_me:934: current value: $ac_new_val" >&5
935 echo "$as_me: current value: $ac_new_val" >&2;}
939 # Pass precious variables to config.status. It doesn't matter if
940 # we pass some twice (in addition to the command line arguments).
941 if test "$ac_new_set" = set; then
943 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
944 ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"`
945 ac_configure_args="$ac_configure_args '$ac_arg'"
947 *) ac_configure_args="$ac_configure_args $ac_var=$ac_new_val"
952 if $ac_cache_corrupted; then
953 { echo "$as_me:953: error: changes in the environment can compromise the build" >&5
954 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
955 { { echo "$as_me:955: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
956 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
957 { (exit 1); exit 1; }; }
961 ac_cpp='$CPP $CPPFLAGS'
962 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
963 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
964 ac_compiler_gnu=$ac_cv_c_compiler_gnu
965 ac_main_return=return
967 case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
968 *c*,-n*) ECHO_N= ECHO_C='
970 *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
971 *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
973 echo "#! $SHELL" >conftest.sh
974 echo "exit 0" >>conftest.sh
976 if { (echo "$as_me:976: PATH=\".;.\"; conftest.sh") >&5
977 (PATH=".;."; conftest.sh) 2>&5
979 echo "$as_me:979: \$? = $ac_status" >&5
980 (exit $ac_status); }; then
981 ac_path_separator=';'
985 PATH_SEPARATOR="$ac_path_separator"
988 ac_config_headers="$ac_config_headers ncurses_cfg.h:ncurses_tst.hin"
990 test -f config.guess || ( test -f ../config.guess && cp ../config.guess ./ )
992 test -f config.sub || ( test -f ../config.sub && cp ../config.sub ./ )
995 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
996 if test -f $ac_dir/install-sh; then
998 ac_install_sh="$ac_aux_dir/install-sh -c"
1000 elif test -f $ac_dir/install.sh; then
1002 ac_install_sh="$ac_aux_dir/install.sh -c"
1004 elif test -f $ac_dir/shtool; then
1006 ac_install_sh="$ac_aux_dir/shtool install -c"
1010 if test -z "$ac_aux_dir"; then
1011 { { echo "$as_me:1011: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
1012 echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
1013 { (exit 1); exit 1; }; }
1015 ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1016 ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1017 ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
1019 # Make sure we can run config.sub.
1020 $ac_config_sub sun4 >/dev/null 2>&1 ||
1021 { { echo "$as_me:1021: error: cannot run $ac_config_sub" >&5
1022 echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1023 { (exit 1); exit 1; }; }
1025 echo "$as_me:1025: checking build system type" >&5
1026 echo $ECHO_N "checking build system type... $ECHO_C" >&6
1027 if test "${ac_cv_build+set}" = set; then
1028 echo $ECHO_N "(cached) $ECHO_C" >&6
1030 ac_cv_build_alias=$build_alias
1031 test -z "$ac_cv_build_alias" &&
1032 ac_cv_build_alias=`$ac_config_guess`
1033 test -z "$ac_cv_build_alias" &&
1034 { { echo "$as_me:1034: error: cannot guess build type; you must specify one" >&5
1035 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1036 { (exit 1); exit 1; }; }
1037 ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
1038 { { echo "$as_me:1038: error: $ac_config_sub $ac_cv_build_alias failed." >&5
1039 echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed." >&2;}
1040 { (exit 1); exit 1; }; }
1043 echo "$as_me:1043: result: $ac_cv_build" >&5
1044 echo "${ECHO_T}$ac_cv_build" >&6
1046 build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1047 build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1048 build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1050 if test -f $srcdir/config.guess || test -f $ac_aux_dir/config.guess ; then
1051 echo "$as_me:1051: checking host system type" >&5
1052 echo $ECHO_N "checking host system type... $ECHO_C" >&6
1053 if test "${ac_cv_host+set}" = set; then
1054 echo $ECHO_N "(cached) $ECHO_C" >&6
1056 ac_cv_host_alias=$host_alias
1057 test -z "$ac_cv_host_alias" &&
1058 ac_cv_host_alias=$ac_cv_build_alias
1059 ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
1060 { { echo "$as_me:1060: error: $ac_config_sub $ac_cv_host_alias failed" >&5
1061 echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1062 { (exit 1); exit 1; }; }
1065 echo "$as_me:1065: result: $ac_cv_host" >&5
1066 echo "${ECHO_T}$ac_cv_host" >&6
1068 host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1069 host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1070 host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1072 system_name="$host_os"
1074 system_name="`(uname -s -r) 2>/dev/null`"
1075 if test -z "$system_name" ; then
1076 system_name="`(hostname) 2>/dev/null`"
1079 test -n "$system_name" && cat >>confdefs.h <<EOF
1080 #define SYSTEM_NAME "$system_name"
1083 if test "${cf_cv_system_name+set}" = set; then
1084 echo $ECHO_N "(cached) $ECHO_C" >&6
1086 cf_cv_system_name="$system_name"
1089 test -z "$system_name" && system_name="$cf_cv_system_name"
1090 test -n "$cf_cv_system_name" && echo "$as_me:1090: result: Configuring for $cf_cv_system_name" >&5
1091 echo "${ECHO_T}Configuring for $cf_cv_system_name" >&6
1093 if test ".$system_name" != ".$cf_cv_system_name" ; then
1094 echo "$as_me:1094: result: Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&5
1095 echo "${ECHO_T}Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&6
1096 { { echo "$as_me:1096: error: \"Please remove config.cache and try again.\"" >&5
1097 echo "$as_me: error: \"Please remove config.cache and try again.\"" >&2;}
1098 { (exit 1); exit 1; }; }
1101 echo "$as_me:1101: checking whether ${MAKE-make} sets \${MAKE}" >&5
1102 echo $ECHO_N "checking whether ${MAKE-make} sets \${MAKE}... $ECHO_C" >&6
1103 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,./+-,__p_,'`
1104 if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
1105 echo $ECHO_N "(cached) $ECHO_C" >&6
1107 cat >conftest.make <<\EOF
1109 @echo 'ac_maketemp="${MAKE}"'
1111 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1112 eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
1113 if test -n "$ac_maketemp"; then
1114 eval ac_cv_prog_make_${ac_make}_set=yes
1116 eval ac_cv_prog_make_${ac_make}_set=no
1120 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
1121 echo "$as_me:1121: result: yes" >&5
1122 echo "${ECHO_T}yes" >&6
1125 echo "$as_me:1125: result: no" >&5
1126 echo "${ECHO_T}no" >&6
1127 SET_MAKE="MAKE=${MAKE-make}"
1131 ac_cpp='$CPP $CPPFLAGS'
1132 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1133 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1134 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1135 ac_main_return=return
1136 if test -n "$ac_tool_prefix"; then
1137 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
1138 set dummy ${ac_tool_prefix}gcc; ac_word=$2
1139 echo "$as_me:1139: checking for $ac_word" >&5
1140 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1141 if test "${ac_cv_prog_CC+set}" = set; then
1142 echo $ECHO_N "(cached) $ECHO_C" >&6
1144 if test -n "$CC"; then
1145 ac_cv_prog_CC="$CC" # Let the user override the test.
1147 ac_save_IFS=$IFS; IFS=$ac_path_separator
1149 for ac_dir in $ac_dummy; do
1151 test -z "$ac_dir" && ac_dir=.
1152 $as_executable_p "$ac_dir/$ac_word" || continue
1153 ac_cv_prog_CC="${ac_tool_prefix}gcc"
1154 echo "$as_me:1154: found $ac_dir/$ac_word" >&5
1161 if test -n "$CC"; then
1162 echo "$as_me:1162: result: $CC" >&5
1163 echo "${ECHO_T}$CC" >&6
1165 echo "$as_me:1165: result: no" >&5
1166 echo "${ECHO_T}no" >&6
1170 if test -z "$ac_cv_prog_CC"; then
1172 # Extract the first word of "gcc", so it can be a program name with args.
1173 set dummy gcc; ac_word=$2
1174 echo "$as_me:1174: checking for $ac_word" >&5
1175 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1176 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1177 echo $ECHO_N "(cached) $ECHO_C" >&6
1179 if test -n "$ac_ct_CC"; then
1180 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1182 ac_save_IFS=$IFS; IFS=$ac_path_separator
1184 for ac_dir in $ac_dummy; do
1186 test -z "$ac_dir" && ac_dir=.
1187 $as_executable_p "$ac_dir/$ac_word" || continue
1188 ac_cv_prog_ac_ct_CC="gcc"
1189 echo "$as_me:1189: found $ac_dir/$ac_word" >&5
1195 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1196 if test -n "$ac_ct_CC"; then
1197 echo "$as_me:1197: result: $ac_ct_CC" >&5
1198 echo "${ECHO_T}$ac_ct_CC" >&6
1200 echo "$as_me:1200: result: no" >&5
1201 echo "${ECHO_T}no" >&6
1209 if test -z "$CC"; then
1210 if test -n "$ac_tool_prefix"; then
1211 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
1212 set dummy ${ac_tool_prefix}cc; ac_word=$2
1213 echo "$as_me:1213: checking for $ac_word" >&5
1214 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1215 if test "${ac_cv_prog_CC+set}" = set; then
1216 echo $ECHO_N "(cached) $ECHO_C" >&6
1218 if test -n "$CC"; then
1219 ac_cv_prog_CC="$CC" # Let the user override the test.
1221 ac_save_IFS=$IFS; IFS=$ac_path_separator
1223 for ac_dir in $ac_dummy; do
1225 test -z "$ac_dir" && ac_dir=.
1226 $as_executable_p "$ac_dir/$ac_word" || continue
1227 ac_cv_prog_CC="${ac_tool_prefix}cc"
1228 echo "$as_me:1228: found $ac_dir/$ac_word" >&5
1235 if test -n "$CC"; then
1236 echo "$as_me:1236: result: $CC" >&5
1237 echo "${ECHO_T}$CC" >&6
1239 echo "$as_me:1239: result: no" >&5
1240 echo "${ECHO_T}no" >&6
1244 if test -z "$ac_cv_prog_CC"; then
1246 # Extract the first word of "cc", so it can be a program name with args.
1247 set dummy cc; ac_word=$2
1248 echo "$as_me:1248: checking for $ac_word" >&5
1249 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1250 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1251 echo $ECHO_N "(cached) $ECHO_C" >&6
1253 if test -n "$ac_ct_CC"; then
1254 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1256 ac_save_IFS=$IFS; IFS=$ac_path_separator
1258 for ac_dir in $ac_dummy; do
1260 test -z "$ac_dir" && ac_dir=.
1261 $as_executable_p "$ac_dir/$ac_word" || continue
1262 ac_cv_prog_ac_ct_CC="cc"
1263 echo "$as_me:1263: found $ac_dir/$ac_word" >&5
1269 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1270 if test -n "$ac_ct_CC"; then
1271 echo "$as_me:1271: result: $ac_ct_CC" >&5
1272 echo "${ECHO_T}$ac_ct_CC" >&6
1274 echo "$as_me:1274: result: no" >&5
1275 echo "${ECHO_T}no" >&6
1284 if test -z "$CC"; then
1285 # Extract the first word of "cc", so it can be a program name with args.
1286 set dummy cc; ac_word=$2
1287 echo "$as_me:1287: checking for $ac_word" >&5
1288 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1289 if test "${ac_cv_prog_CC+set}" = set; then
1290 echo $ECHO_N "(cached) $ECHO_C" >&6
1292 if test -n "$CC"; then
1293 ac_cv_prog_CC="$CC" # Let the user override the test.
1296 ac_save_IFS=$IFS; IFS=$ac_path_separator
1298 for ac_dir in $ac_dummy; do
1300 test -z "$ac_dir" && ac_dir=.
1301 $as_executable_p "$ac_dir/$ac_word" || continue
1302 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
1303 ac_prog_rejected=yes
1307 echo "$as_me:1307: found $ac_dir/$ac_word" >&5
1311 if test $ac_prog_rejected = yes; then
1312 # We found a bogon in the path, so make sure we never use it.
1313 set dummy $ac_cv_prog_CC
1315 if test $# != 0; then
1316 # We chose a different compiler from the bogus one.
1317 # However, it has the same basename, so the bogon will be chosen
1318 # first if we set CC to just the basename; use the full file name.
1320 set dummy "$ac_dir/$ac_word" ${1+"$@"}
1328 if test -n "$CC"; then
1329 echo "$as_me:1329: result: $CC" >&5
1330 echo "${ECHO_T}$CC" >&6
1332 echo "$as_me:1332: result: no" >&5
1333 echo "${ECHO_T}no" >&6
1337 if test -z "$CC"; then
1338 if test -n "$ac_tool_prefix"; then
1341 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
1342 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
1343 echo "$as_me:1343: checking for $ac_word" >&5
1344 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1345 if test "${ac_cv_prog_CC+set}" = set; then
1346 echo $ECHO_N "(cached) $ECHO_C" >&6
1348 if test -n "$CC"; then
1349 ac_cv_prog_CC="$CC" # Let the user override the test.
1351 ac_save_IFS=$IFS; IFS=$ac_path_separator
1353 for ac_dir in $ac_dummy; do
1355 test -z "$ac_dir" && ac_dir=.
1356 $as_executable_p "$ac_dir/$ac_word" || continue
1357 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
1358 echo "$as_me:1358: found $ac_dir/$ac_word" >&5
1365 if test -n "$CC"; then
1366 echo "$as_me:1366: result: $CC" >&5
1367 echo "${ECHO_T}$CC" >&6
1369 echo "$as_me:1369: result: no" >&5
1370 echo "${ECHO_T}no" >&6
1373 test -n "$CC" && break
1376 if test -z "$CC"; then
1380 # Extract the first word of "$ac_prog", so it can be a program name with args.
1381 set dummy $ac_prog; ac_word=$2
1382 echo "$as_me:1382: checking for $ac_word" >&5
1383 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1384 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1385 echo $ECHO_N "(cached) $ECHO_C" >&6
1387 if test -n "$ac_ct_CC"; then
1388 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1390 ac_save_IFS=$IFS; IFS=$ac_path_separator
1392 for ac_dir in $ac_dummy; do
1394 test -z "$ac_dir" && ac_dir=.
1395 $as_executable_p "$ac_dir/$ac_word" || continue
1396 ac_cv_prog_ac_ct_CC="$ac_prog"
1397 echo "$as_me:1397: found $ac_dir/$ac_word" >&5
1403 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1404 if test -n "$ac_ct_CC"; then
1405 echo "$as_me:1405: result: $ac_ct_CC" >&5
1406 echo "${ECHO_T}$ac_ct_CC" >&6
1408 echo "$as_me:1408: result: no" >&5
1409 echo "${ECHO_T}no" >&6
1412 test -n "$ac_ct_CC" && break
1420 test -z "$CC" && { { echo "$as_me:1420: error: no acceptable cc found in \$PATH" >&5
1421 echo "$as_me: error: no acceptable cc found in \$PATH" >&2;}
1422 { (exit 1); exit 1; }; }
1424 # Provide some information about the compiler.
1425 echo "$as_me:1425:" \
1426 "checking for C compiler version" >&5
1427 ac_compiler=`set X $ac_compile; echo $2`
1428 { (eval echo "$as_me:1428: \"$ac_compiler --version </dev/null >&5\"") >&5
1429 (eval $ac_compiler --version </dev/null >&5) 2>&5
1431 echo "$as_me:1431: \$? = $ac_status" >&5
1432 (exit $ac_status); }
1433 { (eval echo "$as_me:1433: \"$ac_compiler -v </dev/null >&5\"") >&5
1434 (eval $ac_compiler -v </dev/null >&5) 2>&5
1436 echo "$as_me:1436: \$? = $ac_status" >&5
1437 (exit $ac_status); }
1438 { (eval echo "$as_me:1438: \"$ac_compiler -V </dev/null >&5\"") >&5
1439 (eval $ac_compiler -V </dev/null >&5) 2>&5
1441 echo "$as_me:1441: \$? = $ac_status" >&5
1442 (exit $ac_status); }
1444 cat >conftest.$ac_ext <<_ACEOF
1445 #line 1445 "configure"
1446 #include "confdefs.h"
1456 ac_clean_files_save=$ac_clean_files
1457 ac_clean_files="$ac_clean_files a.out a.exe"
1458 # Try to create an executable without -o first, disregard a.out.
1459 # It will help us diagnose broken compilers, and finding out an intuition
1461 echo "$as_me:1461: checking for C compiler default output" >&5
1462 echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
1463 ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
1464 if { (eval echo "$as_me:1464: \"$ac_link_default\"") >&5
1465 (eval $ac_link_default) 2>&5
1467 echo "$as_me:1467: \$? = $ac_status" >&5
1468 (exit $ac_status); }; then
1469 # Find the output, starting from the most likely. This scheme is
1470 # not robust to junk in `.', hence go to wildcards (a.*) only as a last
1472 for ac_file in `ls a.exe conftest.exe 2>/dev/null;
1473 ls a.out conftest 2>/dev/null;
1474 ls a.* conftest.* 2>/dev/null`; do
1476 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1477 a.out ) # We found the default executable, but exeext='' is most
1480 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1481 # FIXME: I believe we export ac_cv_exeext for Libtool --akim.
1488 echo "$as_me: failed program was:" >&5
1489 cat conftest.$ac_ext >&5
1490 { { echo "$as_me:1490: error: C compiler cannot create executables" >&5
1491 echo "$as_me: error: C compiler cannot create executables" >&2;}
1492 { (exit 77); exit 77; }; }
1495 ac_exeext=$ac_cv_exeext
1496 echo "$as_me:1496: result: $ac_file" >&5
1497 echo "${ECHO_T}$ac_file" >&6
1499 # Check the compiler produces executables we can run. If not, either
1500 # the compiler is broken, or we cross compile.
1501 echo "$as_me:1501: checking whether the C compiler works" >&5
1502 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
1503 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
1504 # If not cross compiling, check that we can run a simple program.
1505 if test "$cross_compiling" != yes; then
1506 if { ac_try='./$ac_file'
1507 { (eval echo "$as_me:1507: \"$ac_try\"") >&5
1510 echo "$as_me:1510: \$? = $ac_status" >&5
1511 (exit $ac_status); }; }; then
1514 if test "$cross_compiling" = maybe; then
1517 { { echo "$as_me:1517: error: cannot run C compiled programs.
1518 If you meant to cross compile, use \`--host'." >&5
1519 echo "$as_me: error: cannot run C compiled programs.
1520 If you meant to cross compile, use \`--host'." >&2;}
1521 { (exit 1); exit 1; }; }
1525 echo "$as_me:1525: result: yes" >&5
1526 echo "${ECHO_T}yes" >&6
1528 rm -f a.out a.exe conftest$ac_cv_exeext
1529 ac_clean_files=$ac_clean_files_save
1530 # Check the compiler produces executables we can run. If not, either
1531 # the compiler is broken, or we cross compile.
1532 echo "$as_me:1532: checking whether we are cross compiling" >&5
1533 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
1534 echo "$as_me:1534: result: $cross_compiling" >&5
1535 echo "${ECHO_T}$cross_compiling" >&6
1537 echo "$as_me:1537: checking for executable suffix" >&5
1538 echo $ECHO_N "checking for executable suffix... $ECHO_C" >&6
1539 if { (eval echo "$as_me:1539: \"$ac_link\"") >&5
1540 (eval $ac_link) 2>&5
1542 echo "$as_me:1542: \$? = $ac_status" >&5
1543 (exit $ac_status); }; then
1544 # If both `conftest.exe' and `conftest' are `present' (well, observable)
1545 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
1546 # work properly (i.e., refer to `conftest.exe'), while it won't with
1548 for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do
1550 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1551 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1558 { { echo "$as_me:1558: error: cannot compute EXEEXT: cannot compile and link" >&5
1559 echo "$as_me: error: cannot compute EXEEXT: cannot compile and link" >&2;}
1560 { (exit 1); exit 1; }; }
1563 rm -f conftest$ac_cv_exeext
1564 echo "$as_me:1564: result: $ac_cv_exeext" >&5
1565 echo "${ECHO_T}$ac_cv_exeext" >&6
1567 rm -f conftest.$ac_ext
1568 EXEEXT=$ac_cv_exeext
1570 echo "$as_me:1570: checking for object suffix" >&5
1571 echo $ECHO_N "checking for object suffix... $ECHO_C" >&6
1572 if test "${ac_cv_objext+set}" = set; then
1573 echo $ECHO_N "(cached) $ECHO_C" >&6
1575 cat >conftest.$ac_ext <<_ACEOF
1576 #line 1576 "configure"
1577 #include "confdefs.h"
1587 rm -f conftest.o conftest.obj
1588 if { (eval echo "$as_me:1588: \"$ac_compile\"") >&5
1589 (eval $ac_compile) 2>&5
1591 echo "$as_me:1591: \$? = $ac_status" >&5
1592 (exit $ac_status); }; then
1593 for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
1595 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.map | *.inf ) ;;
1596 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
1601 echo "$as_me: failed program was:" >&5
1602 cat conftest.$ac_ext >&5
1603 { { echo "$as_me:1603: error: cannot compute OBJEXT: cannot compile" >&5
1604 echo "$as_me: error: cannot compute OBJEXT: cannot compile" >&2;}
1605 { (exit 1); exit 1; }; }
1608 rm -f conftest.$ac_cv_objext conftest.$ac_ext
1610 echo "$as_me:1610: result: $ac_cv_objext" >&5
1611 echo "${ECHO_T}$ac_cv_objext" >&6
1612 OBJEXT=$ac_cv_objext
1614 echo "$as_me:1614: checking whether we are using the GNU C compiler" >&5
1615 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
1616 if test "${ac_cv_c_compiler_gnu+set}" = set; then
1617 echo $ECHO_N "(cached) $ECHO_C" >&6
1619 cat >conftest.$ac_ext <<_ACEOF
1620 #line 1620 "configure"
1621 #include "confdefs.h"
1634 rm -f conftest.$ac_objext
1635 if { (eval echo "$as_me:1635: \"$ac_compile\"") >&5
1636 (eval $ac_compile) 2>&5
1638 echo "$as_me:1638: \$? = $ac_status" >&5
1639 (exit $ac_status); } &&
1640 { ac_try='test -s conftest.$ac_objext'
1641 { (eval echo "$as_me:1641: \"$ac_try\"") >&5
1644 echo "$as_me:1644: \$? = $ac_status" >&5
1645 (exit $ac_status); }; }; then
1648 echo "$as_me: failed program was:" >&5
1649 cat conftest.$ac_ext >&5
1652 rm -f conftest.$ac_objext conftest.$ac_ext
1653 ac_cv_c_compiler_gnu=$ac_compiler_gnu
1656 echo "$as_me:1656: result: $ac_cv_c_compiler_gnu" >&5
1657 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
1658 GCC=`test $ac_compiler_gnu = yes && echo yes`
1659 ac_test_CFLAGS=${CFLAGS+set}
1660 ac_save_CFLAGS=$CFLAGS
1662 echo "$as_me:1662: checking whether $CC accepts -g" >&5
1663 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
1664 if test "${ac_cv_prog_cc_g+set}" = set; then
1665 echo $ECHO_N "(cached) $ECHO_C" >&6
1667 cat >conftest.$ac_ext <<_ACEOF
1668 #line 1668 "configure"
1669 #include "confdefs.h"
1679 rm -f conftest.$ac_objext
1680 if { (eval echo "$as_me:1680: \"$ac_compile\"") >&5
1681 (eval $ac_compile) 2>&5
1683 echo "$as_me:1683: \$? = $ac_status" >&5
1684 (exit $ac_status); } &&
1685 { ac_try='test -s conftest.$ac_objext'
1686 { (eval echo "$as_me:1686: \"$ac_try\"") >&5
1689 echo "$as_me:1689: \$? = $ac_status" >&5
1690 (exit $ac_status); }; }; then
1693 echo "$as_me: failed program was:" >&5
1694 cat conftest.$ac_ext >&5
1697 rm -f conftest.$ac_objext conftest.$ac_ext
1699 echo "$as_me:1699: result: $ac_cv_prog_cc_g" >&5
1700 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
1701 if test "$ac_test_CFLAGS" = set; then
1702 CFLAGS=$ac_save_CFLAGS
1703 elif test $ac_cv_prog_cc_g = yes; then
1704 if test "$GCC" = yes; then
1710 if test "$GCC" = yes; then
1716 # Some people use a C++ compiler to compile C. Since we use `exit',
1717 # in C++ we need to declare it. In case someone uses the same compiler
1718 # for both compiling C and C++ we need to have the C++ compiler decide
1719 # the declaration of exit, since it's the most demanding environment.
1720 cat >conftest.$ac_ext <<_ACEOF
1725 rm -f conftest.$ac_objext
1726 if { (eval echo "$as_me:1726: \"$ac_compile\"") >&5
1727 (eval $ac_compile) 2>&5
1729 echo "$as_me:1729: \$? = $ac_status" >&5
1730 (exit $ac_status); } &&
1731 { ac_try='test -s conftest.$ac_objext'
1732 { (eval echo "$as_me:1732: \"$ac_try\"") >&5
1735 echo "$as_me:1735: \$? = $ac_status" >&5
1736 (exit $ac_status); }; }; then
1737 for ac_declaration in \
1739 '#include <stdlib.h>' \
1740 'extern "C" void std::exit (int) throw (); using std::exit;' \
1741 'extern "C" void std::exit (int); using std::exit;' \
1742 'extern "C" void exit (int) throw ();' \
1743 'extern "C" void exit (int);' \
1746 cat >conftest.$ac_ext <<_ACEOF
1747 #line 1747 "configure"
1748 #include "confdefs.h"
1759 rm -f conftest.$ac_objext
1760 if { (eval echo "$as_me:1760: \"$ac_compile\"") >&5
1761 (eval $ac_compile) 2>&5
1763 echo "$as_me:1763: \$? = $ac_status" >&5
1764 (exit $ac_status); } &&
1765 { ac_try='test -s conftest.$ac_objext'
1766 { (eval echo "$as_me:1766: \"$ac_try\"") >&5
1769 echo "$as_me:1769: \$? = $ac_status" >&5
1770 (exit $ac_status); }; }; then
1773 echo "$as_me: failed program was:" >&5
1774 cat conftest.$ac_ext >&5
1777 rm -f conftest.$ac_objext conftest.$ac_ext
1778 cat >conftest.$ac_ext <<_ACEOF
1779 #line 1779 "configure"
1780 #include "confdefs.h"
1790 rm -f conftest.$ac_objext
1791 if { (eval echo "$as_me:1791: \"$ac_compile\"") >&5
1792 (eval $ac_compile) 2>&5
1794 echo "$as_me:1794: \$? = $ac_status" >&5
1795 (exit $ac_status); } &&
1796 { ac_try='test -s conftest.$ac_objext'
1797 { (eval echo "$as_me:1797: \"$ac_try\"") >&5
1800 echo "$as_me:1800: \$? = $ac_status" >&5
1801 (exit $ac_status); }; }; then
1804 echo "$as_me: failed program was:" >&5
1805 cat conftest.$ac_ext >&5
1807 rm -f conftest.$ac_objext conftest.$ac_ext
1810 if test -n "$ac_declaration"; then
1811 echo '#ifdef __cplusplus' >>confdefs.h
1812 echo $ac_declaration >>confdefs.h
1813 echo '#endif' >>confdefs.h
1817 echo "$as_me: failed program was:" >&5
1818 cat conftest.$ac_ext >&5
1820 rm -f conftest.$ac_objext conftest.$ac_ext
1822 ac_cpp='$CPP $CPPFLAGS'
1823 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1824 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1825 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1826 ac_main_return=return
1829 ac_cpp='$CPP $CPPFLAGS'
1830 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1831 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1832 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1833 ac_main_return=return
1834 echo "$as_me:1834: checking how to run the C preprocessor" >&5
1835 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
1836 # On Suns, sometimes $CPP names a directory.
1837 if test -n "$CPP" && test -d "$CPP"; then
1840 if test -z "$CPP"; then
1841 if test "${ac_cv_prog_CPP+set}" = set; then
1842 echo $ECHO_N "(cached) $ECHO_C" >&6
1844 # Double quotes because CPP needs to be expanded
1845 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
1848 for ac_c_preproc_warn_flag in '' yes
1850 # Use a header file that comes with gcc, so configuring glibc
1851 # with a fresh cross-compiler works.
1852 # On the NeXT, cc -E runs the code through the compiler's parser,
1853 # not just through cpp. "Syntax error" is here to catch this case.
1854 cat >conftest.$ac_ext <<_ACEOF
1855 #line 1855 "configure"
1856 #include "confdefs.h"
1860 if { (eval echo "$as_me:1860: \"$ac_cpp conftest.$ac_ext\"") >&5
1861 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
1863 egrep -v '^ *\+' conftest.er1 >conftest.err
1865 cat conftest.err >&5
1866 echo "$as_me:1866: \$? = $ac_status" >&5
1867 (exit $ac_status); } >/dev/null; then
1868 if test -s conftest.err; then
1869 ac_cpp_err=$ac_c_preproc_warn_flag
1876 if test -z "$ac_cpp_err"; then
1879 echo "$as_me: failed program was:" >&5
1880 cat conftest.$ac_ext >&5
1881 # Broken: fails on valid input.
1884 rm -f conftest.err conftest.$ac_ext
1886 # OK, works on sane cases. Now check whether non-existent headers
1887 # can be detected and how.
1888 cat >conftest.$ac_ext <<_ACEOF
1889 #line 1889 "configure"
1890 #include "confdefs.h"
1891 #include <ac_nonexistent.h>
1893 if { (eval echo "$as_me:1893: \"$ac_cpp conftest.$ac_ext\"") >&5
1894 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
1896 egrep -v '^ *\+' conftest.er1 >conftest.err
1898 cat conftest.err >&5
1899 echo "$as_me:1899: \$? = $ac_status" >&5
1900 (exit $ac_status); } >/dev/null; then
1901 if test -s conftest.err; then
1902 ac_cpp_err=$ac_c_preproc_warn_flag
1909 if test -z "$ac_cpp_err"; then
1910 # Broken: success on invalid input.
1913 echo "$as_me: failed program was:" >&5
1914 cat conftest.$ac_ext >&5
1915 # Passes both tests.
1919 rm -f conftest.err conftest.$ac_ext
1922 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
1923 rm -f conftest.err conftest.$ac_ext
1924 if $ac_preproc_ok; then
1936 echo "$as_me:1936: result: $CPP" >&5
1937 echo "${ECHO_T}$CPP" >&6
1939 for ac_c_preproc_warn_flag in '' yes
1941 # Use a header file that comes with gcc, so configuring glibc
1942 # with a fresh cross-compiler works.
1943 # On the NeXT, cc -E runs the code through the compiler's parser,
1944 # not just through cpp. "Syntax error" is here to catch this case.
1945 cat >conftest.$ac_ext <<_ACEOF
1946 #line 1946 "configure"
1947 #include "confdefs.h"
1951 if { (eval echo "$as_me:1951: \"$ac_cpp conftest.$ac_ext\"") >&5
1952 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
1954 egrep -v '^ *\+' conftest.er1 >conftest.err
1956 cat conftest.err >&5
1957 echo "$as_me:1957: \$? = $ac_status" >&5
1958 (exit $ac_status); } >/dev/null; then
1959 if test -s conftest.err; then
1960 ac_cpp_err=$ac_c_preproc_warn_flag
1967 if test -z "$ac_cpp_err"; then
1970 echo "$as_me: failed program was:" >&5
1971 cat conftest.$ac_ext >&5
1972 # Broken: fails on valid input.
1975 rm -f conftest.err conftest.$ac_ext
1977 # OK, works on sane cases. Now check whether non-existent headers
1978 # can be detected and how.
1979 cat >conftest.$ac_ext <<_ACEOF
1980 #line 1980 "configure"
1981 #include "confdefs.h"
1982 #include <ac_nonexistent.h>
1984 if { (eval echo "$as_me:1984: \"$ac_cpp conftest.$ac_ext\"") >&5
1985 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
1987 egrep -v '^ *\+' conftest.er1 >conftest.err
1989 cat conftest.err >&5
1990 echo "$as_me:1990: \$? = $ac_status" >&5
1991 (exit $ac_status); } >/dev/null; then
1992 if test -s conftest.err; then
1993 ac_cpp_err=$ac_c_preproc_warn_flag
2000 if test -z "$ac_cpp_err"; then
2001 # Broken: success on invalid input.
2004 echo "$as_me: failed program was:" >&5
2005 cat conftest.$ac_ext >&5
2006 # Passes both tests.
2010 rm -f conftest.err conftest.$ac_ext
2013 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2014 rm -f conftest.err conftest.$ac_ext
2015 if $ac_preproc_ok; then
2018 { { echo "$as_me:2018: error: C preprocessor \"$CPP\" fails sanity check" >&5
2019 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;}
2020 { (exit 1); exit 1; }; }
2024 ac_cpp='$CPP $CPPFLAGS'
2025 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2026 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2027 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2028 ac_main_return=return
2030 for ac_prog in mawk gawk nawk awk
2032 # Extract the first word of "$ac_prog", so it can be a program name with args.
2033 set dummy $ac_prog; ac_word=$2
2034 echo "$as_me:2034: checking for $ac_word" >&5
2035 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2036 if test "${ac_cv_prog_AWK+set}" = set; then
2037 echo $ECHO_N "(cached) $ECHO_C" >&6
2039 if test -n "$AWK"; then
2040 ac_cv_prog_AWK="$AWK" # Let the user override the test.
2042 ac_save_IFS=$IFS; IFS=$ac_path_separator
2044 for ac_dir in $ac_dummy; do
2046 test -z "$ac_dir" && ac_dir=.
2047 $as_executable_p "$ac_dir/$ac_word" || continue
2048 ac_cv_prog_AWK="$ac_prog"
2049 echo "$as_me:2049: found $ac_dir/$ac_word" >&5
2056 if test -n "$AWK"; then
2057 echo "$as_me:2057: result: $AWK" >&5
2058 echo "${ECHO_T}$AWK" >&6
2060 echo "$as_me:2060: result: no" >&5
2061 echo "${ECHO_T}no" >&6
2064 test -n "$AWK" && break
2067 echo "$as_me:2067: checking if filesystem supports mixed-case filenames" >&5
2068 echo $ECHO_N "checking if filesystem supports mixed-case filenames... $ECHO_C" >&6
2069 if test "${cf_cv_mixedcase+set}" = set; then
2070 echo $ECHO_N "(cached) $ECHO_C" >&6
2073 if test "$cross_compiling" = yes ; then
2074 case $target_alias in #(vi
2075 *-os2-emx*|*-msdosdjgpp*|*-cygwin*|*-mingw32*|*-uwin*) #(vi
2083 rm -f conftest CONFTEST
2085 if test -f CONFTEST ; then
2090 rm -f conftest CONFTEST
2094 echo "$as_me:2094: result: $cf_cv_mixedcase" >&5
2095 echo "${ECHO_T}$cf_cv_mixedcase" >&6
2096 test "$cf_cv_mixedcase" = yes && cat >>confdefs.h <<\EOF
2097 #define MIXEDCASE_FILENAMES 1
2100 for ac_prog in exctags ctags
2102 # Extract the first word of "$ac_prog", so it can be a program name with args.
2103 set dummy $ac_prog; ac_word=$2
2104 echo "$as_me:2104: checking for $ac_word" >&5
2105 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2106 if test "${ac_cv_prog_CTAGS+set}" = set; then
2107 echo $ECHO_N "(cached) $ECHO_C" >&6
2109 if test -n "$CTAGS"; then
2110 ac_cv_prog_CTAGS="$CTAGS" # Let the user override the test.
2112 ac_save_IFS=$IFS; IFS=$ac_path_separator
2114 for ac_dir in $ac_dummy; do
2116 test -z "$ac_dir" && ac_dir=.
2117 $as_executable_p "$ac_dir/$ac_word" || continue
2118 ac_cv_prog_CTAGS="$ac_prog"
2119 echo "$as_me:2119: found $ac_dir/$ac_word" >&5
2125 CTAGS=$ac_cv_prog_CTAGS
2126 if test -n "$CTAGS"; then
2127 echo "$as_me:2127: result: $CTAGS" >&5
2128 echo "${ECHO_T}$CTAGS" >&6
2130 echo "$as_me:2130: result: no" >&5
2131 echo "${ECHO_T}no" >&6
2134 test -n "$CTAGS" && break
2137 for ac_prog in exetags etags
2139 # Extract the first word of "$ac_prog", so it can be a program name with args.
2140 set dummy $ac_prog; ac_word=$2
2141 echo "$as_me:2141: checking for $ac_word" >&5
2142 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2143 if test "${ac_cv_prog_ETAGS+set}" = set; then
2144 echo $ECHO_N "(cached) $ECHO_C" >&6
2146 if test -n "$ETAGS"; then
2147 ac_cv_prog_ETAGS="$ETAGS" # Let the user override the test.
2149 ac_save_IFS=$IFS; IFS=$ac_path_separator
2151 for ac_dir in $ac_dummy; do
2153 test -z "$ac_dir" && ac_dir=.
2154 $as_executable_p "$ac_dir/$ac_word" || continue
2155 ac_cv_prog_ETAGS="$ac_prog"
2156 echo "$as_me:2156: found $ac_dir/$ac_word" >&5
2162 ETAGS=$ac_cv_prog_ETAGS
2163 if test -n "$ETAGS"; then
2164 echo "$as_me:2164: result: $ETAGS" >&5
2165 echo "${ECHO_T}$ETAGS" >&6
2167 echo "$as_me:2167: result: no" >&5
2168 echo "${ECHO_T}no" >&6
2171 test -n "$ETAGS" && break
2174 # Extract the first word of "${CTAGS:-ctags}", so it can be a program name with args.
2175 set dummy ${CTAGS:-ctags}; ac_word=$2
2176 echo "$as_me:2176: checking for $ac_word" >&5
2177 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2178 if test "${ac_cv_prog_MAKE_LOWER_TAGS+set}" = set; then
2179 echo $ECHO_N "(cached) $ECHO_C" >&6
2181 if test -n "$MAKE_LOWER_TAGS"; then
2182 ac_cv_prog_MAKE_LOWER_TAGS="$MAKE_LOWER_TAGS" # Let the user override the test.
2184 ac_save_IFS=$IFS; IFS=$ac_path_separator
2186 for ac_dir in $ac_dummy; do
2188 test -z "$ac_dir" && ac_dir=.
2189 $as_executable_p "$ac_dir/$ac_word" || continue
2190 ac_cv_prog_MAKE_LOWER_TAGS="yes"
2191 echo "$as_me:2191: found $ac_dir/$ac_word" >&5
2195 test -z "$ac_cv_prog_MAKE_LOWER_TAGS" && ac_cv_prog_MAKE_LOWER_TAGS="no"
2198 MAKE_LOWER_TAGS=$ac_cv_prog_MAKE_LOWER_TAGS
2199 if test -n "$MAKE_LOWER_TAGS"; then
2200 echo "$as_me:2200: result: $MAKE_LOWER_TAGS" >&5
2201 echo "${ECHO_T}$MAKE_LOWER_TAGS" >&6
2203 echo "$as_me:2203: result: no" >&5
2204 echo "${ECHO_T}no" >&6
2207 if test "$cf_cv_mixedcase" = yes ; then
2208 # Extract the first word of "${ETAGS:-etags}", so it can be a program name with args.
2209 set dummy ${ETAGS:-etags}; ac_word=$2
2210 echo "$as_me:2210: checking for $ac_word" >&5
2211 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2212 if test "${ac_cv_prog_MAKE_UPPER_TAGS+set}" = set; then
2213 echo $ECHO_N "(cached) $ECHO_C" >&6
2215 if test -n "$MAKE_UPPER_TAGS"; then
2216 ac_cv_prog_MAKE_UPPER_TAGS="$MAKE_UPPER_TAGS" # Let the user override the test.
2218 ac_save_IFS=$IFS; IFS=$ac_path_separator
2220 for ac_dir in $ac_dummy; do
2222 test -z "$ac_dir" && ac_dir=.
2223 $as_executable_p "$ac_dir/$ac_word" || continue
2224 ac_cv_prog_MAKE_UPPER_TAGS="yes"
2225 echo "$as_me:2225: found $ac_dir/$ac_word" >&5
2229 test -z "$ac_cv_prog_MAKE_UPPER_TAGS" && ac_cv_prog_MAKE_UPPER_TAGS="no"
2232 MAKE_UPPER_TAGS=$ac_cv_prog_MAKE_UPPER_TAGS
2233 if test -n "$MAKE_UPPER_TAGS"; then
2234 echo "$as_me:2234: result: $MAKE_UPPER_TAGS" >&5
2235 echo "${ECHO_T}$MAKE_UPPER_TAGS" >&6
2237 echo "$as_me:2237: result: no" >&5
2238 echo "${ECHO_T}no" >&6
2245 if test "$MAKE_UPPER_TAGS" = yes ; then
2251 if test "$MAKE_LOWER_TAGS" = yes ; then
2258 CC_SHARED_OPTS=unknown
2259 CPPFLAGS="$CPPFLAGS"
2261 DFT_OBJ_SUBDIR=`pwd|sed -e's:.*/::'`
2262 DFT_UPR_MODEL="NORMAL"
2281 TINFO_ARGS='$(LIBS_CURSES)'
2282 cf_cv_abi_version=""
2283 cf_cv_rel_version=""
2288 echo "$as_me:2288: checking for ${CC:-cc} option to accept ANSI C" >&5
2289 echo $ECHO_N "checking for ${CC:-cc} option to accept ANSI C... $ECHO_C" >&6
2290 if test "${cf_cv_ansi_cc+set}" = set; then
2291 echo $ECHO_N "(cached) $ECHO_C" >&6
2295 cf_save_CFLAGS="$CFLAGS"
2296 cf_save_CPPFLAGS="$CPPFLAGS"
2297 # Don't try gcc -ansi; that turns off useful extensions and
2298 # breaks some systems' header files.
2299 # AIX -qlanglvl=ansi
2300 # Ultrix and OSF/1 -std1
2301 # HP-UX -Aa -D_HPUX_SOURCE
2303 # UnixWare 1.2 (cannot use -Xc, since ANSI/POSIX clashes)
2304 for cf_arg in "-DCC_HAS_PROTOS" \
2309 "-Aa -D_HPUX_SOURCE" \
2316 cf_new_extra_cppflags=
2318 for cf_add_cflags in $cf_arg
2320 case $cf_fix_cppflags in
2322 case $cf_add_cflags in #(vi
2323 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
2324 case $cf_add_cflags in
2326 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
2328 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
2329 && test -z "${cf_tst_cflags}" \
2330 && cf_fix_cppflags=yes
2332 if test $cf_fix_cppflags = yes ; then
2333 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2335 elif test "${cf_tst_cflags}" = "\"'" ; then
2336 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2342 *$cf_add_cflags) #(vi
2345 case $cf_add_cflags in #(vi
2347 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
2349 CPPFLAGS=`echo "$CPPFLAGS" | \
2350 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
2351 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
2355 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
2360 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
2365 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2367 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
2369 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
2370 && test -z "${cf_tst_cflags}" \
2371 && cf_fix_cppflags=no
2376 if test -n "$cf_new_cflags" ; then
2378 CFLAGS="$CFLAGS $cf_new_cflags"
2381 if test -n "$cf_new_cppflags" ; then
2383 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
2386 if test -n "$cf_new_extra_cppflags" ; then
2388 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
2391 cat >conftest.$ac_ext <<_ACEOF
2392 #line 2392 "configure"
2393 #include "confdefs.h"
2395 #ifndef CC_HAS_PROTOS
2396 #if !defined(__STDC__) || (__STDC__ != 1)
2405 int test (int i, double x);
2406 struct s1 {int (*f) (int a);};
2407 struct s2 {int (*f) (double a);};
2412 rm -f conftest.$ac_objext
2413 if { (eval echo "$as_me:2413: \"$ac_compile\"") >&5
2414 (eval $ac_compile) 2>&5
2416 echo "$as_me:2416: \$? = $ac_status" >&5
2417 (exit $ac_status); } &&
2418 { ac_try='test -s conftest.$ac_objext'
2419 { (eval echo "$as_me:2419: \"$ac_try\"") >&5
2422 echo "$as_me:2422: \$? = $ac_status" >&5
2423 (exit $ac_status); }; }; then
2424 cf_cv_ansi_cc="$cf_arg"; break
2426 echo "$as_me: failed program was:" >&5
2427 cat conftest.$ac_ext >&5
2429 rm -f conftest.$ac_objext conftest.$ac_ext
2431 CFLAGS="$cf_save_CFLAGS"
2432 CPPFLAGS="$cf_save_CPPFLAGS"
2435 echo "$as_me:2435: result: $cf_cv_ansi_cc" >&5
2436 echo "${ECHO_T}$cf_cv_ansi_cc" >&6
2438 if test "$cf_cv_ansi_cc" != "no"; then
2439 if test ".$cf_cv_ansi_cc" != ".-DCC_HAS_PROTOS"; then
2444 cf_new_extra_cppflags=
2446 for cf_add_cflags in $cf_cv_ansi_cc
2448 case $cf_fix_cppflags in
2450 case $cf_add_cflags in #(vi
2451 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
2452 case $cf_add_cflags in
2454 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
2456 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
2457 && test -z "${cf_tst_cflags}" \
2458 && cf_fix_cppflags=yes
2460 if test $cf_fix_cppflags = yes ; then
2461 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2463 elif test "${cf_tst_cflags}" = "\"'" ; then
2464 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2470 *$cf_add_cflags) #(vi
2473 case $cf_add_cflags in #(vi
2475 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
2477 CPPFLAGS=`echo "$CPPFLAGS" | \
2478 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
2479 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
2483 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
2488 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
2493 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2495 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
2497 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
2498 && test -z "${cf_tst_cflags}" \
2499 && cf_fix_cppflags=no
2504 if test -n "$cf_new_cflags" ; then
2506 CFLAGS="$CFLAGS $cf_new_cflags"
2509 if test -n "$cf_new_cppflags" ; then
2511 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
2514 if test -n "$cf_new_extra_cppflags" ; then
2516 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
2520 cat >>confdefs.h <<\EOF
2521 #define CC_HAS_PROTOS 1
2527 if test "$cf_cv_ansi_cc" = "no"; then
2528 { { echo "$as_me:2528: error: Your compiler does not appear to recognize prototypes.
2529 You have the following choices:
2530 a. adjust your compiler options
2531 b. get an up-to-date compiler
2532 c. use a wrapper such as unproto" >&5
2533 echo "$as_me: error: Your compiler does not appear to recognize prototypes.
2534 You have the following choices:
2535 a. adjust your compiler options
2536 b. get an up-to-date compiler
2537 c. use a wrapper such as unproto" >&2;}
2538 { (exit 1); exit 1; }; }
2541 if test "$GCC" = yes
2543 cat > conftest.i <<EOF
2545 #define GCC_PRINTF 0
2550 #ifndef GCC_NORETURN
2551 #define GCC_NORETURN /* nothing */
2554 #define GCC_UNUSED /* nothing */
2557 if test "$GCC" = yes
2559 { echo "$as_me:2559: checking for $CC __attribute__ directives..." >&5
2560 echo "$as_me: checking for $CC __attribute__ directives..." >&6;}
2561 cat > conftest.$ac_ext <<EOF
2562 #line 2562 "${as_me:-configure}"
2563 #include "confdefs.h"
2564 #include "conftest.h"
2565 #include "conftest.i"
2567 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
2569 #define GCC_PRINTFLIKE(fmt,var) /*nothing*/
2572 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
2574 #define GCC_SCANFLIKE(fmt,var) /*nothing*/
2576 extern void wow(char *,...) GCC_SCANFLIKE(1,2);
2577 extern void oops(char *,...) GCC_PRINTFLIKE(1,2) GCC_NORETURN;
2578 extern void foo(void) GCC_NORETURN;
2579 int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { return 0; }
2581 cf_printf_attribute=no
2582 cf_scanf_attribute=no
2583 for cf_attribute in scanf printf unused noreturn
2586 cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
2588 cf_directive="__attribute__(($cf_attribute))"
2589 echo "checking for $CC $cf_directive" 1>&5
2591 case $cf_attribute in #(vi
2593 cf_printf_attribute=yes
2594 cat >conftest.h <<EOF
2595 #define GCC_$cf_ATTRIBUTE 1
2599 cf_scanf_attribute=yes
2600 cat >conftest.h <<EOF
2601 #define GCC_$cf_ATTRIBUTE 1
2605 cat >conftest.h <<EOF
2606 #define GCC_$cf_ATTRIBUTE $cf_directive
2611 if { (eval echo "$as_me:2611: \"$ac_compile\"") >&5
2612 (eval $ac_compile) 2>&5
2614 echo "$as_me:2614: \$? = $ac_status" >&5
2615 (exit $ac_status); }; then
2616 test -n "$verbose" && echo "$as_me:2616: result: ... $cf_attribute" >&5
2617 echo "${ECHO_T}... $cf_attribute" >&6
2618 cat conftest.h >>confdefs.h
2619 case $cf_attribute in #(vi
2621 if test "$cf_printf_attribute" = no ; then
2622 cat >>confdefs.h <<EOF
2623 #define GCC_PRINTFLIKE(fmt,var) /* nothing */
2626 cat >>confdefs.h <<EOF
2627 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
2632 if test "$cf_scanf_attribute" = no ; then
2633 cat >>confdefs.h <<EOF
2634 #define GCC_SCANFLIKE(fmt,var) /* nothing */
2637 cat >>confdefs.h <<EOF
2638 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
2646 fgrep define conftest.i >>confdefs.h
2652 cf_POSIX_C_SOURCE=199506L
2655 case $host_os in #(vi
2657 cf_xopen_source="-D_ALL_SOURCE"
2660 cf_xopen_source="-D_APPLE_C_SOURCE"
2663 cf_xopen_source="-D_DARWIN_C_SOURCE"
2665 freebsd*|dragonfly*) #(vi
2666 # 5.x headers associate
2667 # _XOPEN_SOURCE=600 with _POSIX_C_SOURCE=200112L
2668 # _XOPEN_SOURCE=500 with _POSIX_C_SOURCE=199506L
2669 cf_POSIX_C_SOURCE=200112L
2671 cf_xopen_source="-D_BSD_TYPES -D__BSD_VISIBLE -D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
2674 cf_xopen_source="-D_HPUX_SOURCE -D_XOPEN_SOURCE=500"
2677 cf_xopen_source="-D_HPUX_SOURCE"
2680 cf_xopen_source="-D_SGI_SOURCE"
2682 linux*|gnu*|mint*|k*bsd*-gnu) #(vi
2684 echo "$as_me:2684: checking if we must define _GNU_SOURCE" >&5
2685 echo $ECHO_N "checking if we must define _GNU_SOURCE... $ECHO_C" >&6
2686 if test "${cf_cv_gnu_source+set}" = set; then
2687 echo $ECHO_N "(cached) $ECHO_C" >&6
2690 cat >conftest.$ac_ext <<_ACEOF
2691 #line 2691 "configure"
2692 #include "confdefs.h"
2693 #include <sys/types.h>
2698 #ifndef _XOPEN_SOURCE
2705 rm -f conftest.$ac_objext
2706 if { (eval echo "$as_me:2706: \"$ac_compile\"") >&5
2707 (eval $ac_compile) 2>&5
2709 echo "$as_me:2709: \$? = $ac_status" >&5
2710 (exit $ac_status); } &&
2711 { ac_try='test -s conftest.$ac_objext'
2712 { (eval echo "$as_me:2712: \"$ac_try\"") >&5
2715 echo "$as_me:2715: \$? = $ac_status" >&5
2716 (exit $ac_status); }; }; then
2719 echo "$as_me: failed program was:" >&5
2720 cat conftest.$ac_ext >&5
2722 CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE"
2723 cat >conftest.$ac_ext <<_ACEOF
2724 #line 2724 "configure"
2725 #include "confdefs.h"
2726 #include <sys/types.h>
2731 #ifdef _XOPEN_SOURCE
2738 rm -f conftest.$ac_objext
2739 if { (eval echo "$as_me:2739: \"$ac_compile\"") >&5
2740 (eval $ac_compile) 2>&5
2742 echo "$as_me:2742: \$? = $ac_status" >&5
2743 (exit $ac_status); } &&
2744 { ac_try='test -s conftest.$ac_objext'
2745 { (eval echo "$as_me:2745: \"$ac_try\"") >&5
2748 echo "$as_me:2748: \$? = $ac_status" >&5
2749 (exit $ac_status); }; }; then
2752 echo "$as_me: failed program was:" >&5
2753 cat conftest.$ac_ext >&5
2754 cf_cv_gnu_source=yes
2756 rm -f conftest.$ac_objext conftest.$ac_ext
2760 rm -f conftest.$ac_objext conftest.$ac_ext
2763 echo "$as_me:2763: result: $cf_cv_gnu_source" >&5
2764 echo "${ECHO_T}$cf_cv_gnu_source" >&6
2765 test "$cf_cv_gnu_source" = yes && CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE"
2769 # setting _XOPEN_SOURCE or _POSIX_SOURCE breaks <arpa/inet.h>
2772 # setting _XOPEN_SOURCE breaks IPv6 for lynx on NetBSD 1.6, breaks xterm, is not needed for ncursesw
2775 # setting _XOPEN_SOURCE breaks xterm on OpenBSD 2.8, is not needed for ncursesw
2778 cf_xopen_source="-D_OSF_SOURCE"
2781 cf_xopen_source="-D_QNX_SOURCE"
2784 # setting _XOPEN_SOURCE breaks Lynx on SCO Unix / OpenServer
2786 solaris2.1[0-9]) #(vi
2787 cf_xopen_source="-D__EXTENSIONS__ -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
2789 solaris2.[1-9]) #(vi
2790 cf_xopen_source="-D__EXTENSIONS__"
2793 echo "$as_me:2793: checking if we should define _XOPEN_SOURCE" >&5
2794 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
2795 if test "${cf_cv_xopen_source+set}" = set; then
2796 echo $ECHO_N "(cached) $ECHO_C" >&6
2799 cat >conftest.$ac_ext <<_ACEOF
2800 #line 2800 "configure"
2801 #include "confdefs.h"
2802 #include <sys/types.h>
2807 #ifndef _XOPEN_SOURCE
2814 rm -f conftest.$ac_objext
2815 if { (eval echo "$as_me:2815: \"$ac_compile\"") >&5
2816 (eval $ac_compile) 2>&5
2818 echo "$as_me:2818: \$? = $ac_status" >&5
2819 (exit $ac_status); } &&
2820 { ac_try='test -s conftest.$ac_objext'
2821 { (eval echo "$as_me:2821: \"$ac_try\"") >&5
2824 echo "$as_me:2824: \$? = $ac_status" >&5
2825 (exit $ac_status); }; }; then
2826 cf_cv_xopen_source=no
2828 echo "$as_me: failed program was:" >&5
2829 cat conftest.$ac_ext >&5
2831 CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
2832 cat >conftest.$ac_ext <<_ACEOF
2833 #line 2833 "configure"
2834 #include "confdefs.h"
2835 #include <sys/types.h>
2840 #ifdef _XOPEN_SOURCE
2847 rm -f conftest.$ac_objext
2848 if { (eval echo "$as_me:2848: \"$ac_compile\"") >&5
2849 (eval $ac_compile) 2>&5
2851 echo "$as_me:2851: \$? = $ac_status" >&5
2852 (exit $ac_status); } &&
2853 { ac_try='test -s conftest.$ac_objext'
2854 { (eval echo "$as_me:2854: \"$ac_try\"") >&5
2857 echo "$as_me:2857: \$? = $ac_status" >&5
2858 (exit $ac_status); }; }; then
2859 cf_cv_xopen_source=no
2861 echo "$as_me: failed program was:" >&5
2862 cat conftest.$ac_ext >&5
2863 cf_cv_xopen_source=$cf_XOPEN_SOURCE
2865 rm -f conftest.$ac_objext conftest.$ac_ext
2869 rm -f conftest.$ac_objext conftest.$ac_ext
2872 echo "$as_me:2872: result: $cf_cv_xopen_source" >&5
2873 echo "${ECHO_T}$cf_cv_xopen_source" >&6
2874 if test "$cf_cv_xopen_source" != no ; then
2876 CFLAGS=`echo "$CFLAGS" | \
2877 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
2878 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
2880 CPPFLAGS=`echo "$CPPFLAGS" | \
2881 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
2882 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
2884 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
2889 cf_new_extra_cppflags=
2891 for cf_add_cflags in $cf_temp_xopen_source
2893 case $cf_fix_cppflags in
2895 case $cf_add_cflags in #(vi
2896 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
2897 case $cf_add_cflags in
2899 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
2901 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
2902 && test -z "${cf_tst_cflags}" \
2903 && cf_fix_cppflags=yes
2905 if test $cf_fix_cppflags = yes ; then
2906 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2908 elif test "${cf_tst_cflags}" = "\"'" ; then
2909 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2915 *$cf_add_cflags) #(vi
2918 case $cf_add_cflags in #(vi
2920 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
2922 CPPFLAGS=`echo "$CPPFLAGS" | \
2923 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
2924 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
2928 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
2933 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
2938 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2940 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
2942 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
2943 && test -z "${cf_tst_cflags}" \
2944 && cf_fix_cppflags=no
2949 if test -n "$cf_new_cflags" ; then
2951 CFLAGS="$CFLAGS $cf_new_cflags"
2954 if test -n "$cf_new_cppflags" ; then
2956 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
2959 if test -n "$cf_new_extra_cppflags" ; then
2961 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
2966 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
2968 cf_save_CFLAGS="$CFLAGS"
2969 cf_save_CPPFLAGS="$CPPFLAGS"
2971 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
2972 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
2973 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
2975 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
2976 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
2977 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
2979 echo "$as_me:2979: checking if we should define _POSIX_C_SOURCE" >&5
2980 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
2981 if test "${cf_cv_posix_c_source+set}" = set; then
2982 echo $ECHO_N "(cached) $ECHO_C" >&6
2985 echo "${as_me:-configure}:2985: testing if the symbol is already defined go no further ..." 1>&5
2987 cat >conftest.$ac_ext <<_ACEOF
2988 #line 2988 "configure"
2989 #include "confdefs.h"
2990 #include <sys/types.h>
2995 #ifndef _POSIX_C_SOURCE
3002 rm -f conftest.$ac_objext
3003 if { (eval echo "$as_me:3003: \"$ac_compile\"") >&5
3004 (eval $ac_compile) 2>&5
3006 echo "$as_me:3006: \$? = $ac_status" >&5
3007 (exit $ac_status); } &&
3008 { ac_try='test -s conftest.$ac_objext'
3009 { (eval echo "$as_me:3009: \"$ac_try\"") >&5
3012 echo "$as_me:3012: \$? = $ac_status" >&5
3013 (exit $ac_status); }; }; then
3014 cf_cv_posix_c_source=no
3016 echo "$as_me: failed program was:" >&5
3017 cat conftest.$ac_ext >&5
3018 cf_want_posix_source=no
3019 case .$cf_POSIX_C_SOURCE in #(vi
3021 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
3024 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
3025 cf_want_posix_source=yes
3028 cf_want_posix_source=yes
3031 if test "$cf_want_posix_source" = yes ; then
3032 cat >conftest.$ac_ext <<_ACEOF
3033 #line 3033 "configure"
3034 #include "confdefs.h"
3035 #include <sys/types.h>
3040 #ifdef _POSIX_SOURCE
3047 rm -f conftest.$ac_objext
3048 if { (eval echo "$as_me:3048: \"$ac_compile\"") >&5
3049 (eval $ac_compile) 2>&5
3051 echo "$as_me:3051: \$? = $ac_status" >&5
3052 (exit $ac_status); } &&
3053 { ac_try='test -s conftest.$ac_objext'
3054 { (eval echo "$as_me:3054: \"$ac_try\"") >&5
3057 echo "$as_me:3057: \$? = $ac_status" >&5
3058 (exit $ac_status); }; }; then
3061 echo "$as_me: failed program was:" >&5
3062 cat conftest.$ac_ext >&5
3063 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
3065 rm -f conftest.$ac_objext conftest.$ac_ext
3068 echo "${as_me:-configure}:3068: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
3070 CFLAGS="$cf_trim_CFLAGS"
3071 CPPFLAGS="$cf_trim_CPPFLAGS $cf_cv_posix_c_source"
3073 echo "${as_me:-configure}:3073: testing if the second compile does not leave our definition intact error ..." 1>&5
3075 cat >conftest.$ac_ext <<_ACEOF
3076 #line 3076 "configure"
3077 #include "confdefs.h"
3078 #include <sys/types.h>
3083 #ifndef _POSIX_C_SOURCE
3090 rm -f conftest.$ac_objext
3091 if { (eval echo "$as_me:3091: \"$ac_compile\"") >&5
3092 (eval $ac_compile) 2>&5
3094 echo "$as_me:3094: \$? = $ac_status" >&5
3095 (exit $ac_status); } &&
3096 { ac_try='test -s conftest.$ac_objext'
3097 { (eval echo "$as_me:3097: \"$ac_try\"") >&5
3100 echo "$as_me:3100: \$? = $ac_status" >&5
3101 (exit $ac_status); }; }; then
3104 echo "$as_me: failed program was:" >&5
3105 cat conftest.$ac_ext >&5
3106 cf_cv_posix_c_source=no
3108 rm -f conftest.$ac_objext conftest.$ac_ext
3109 CFLAGS="$cf_save_CFLAGS"
3110 CPPFLAGS="$cf_save_CPPFLAGS"
3113 rm -f conftest.$ac_objext conftest.$ac_ext
3116 echo "$as_me:3116: result: $cf_cv_posix_c_source" >&5
3117 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
3119 if test "$cf_cv_posix_c_source" != no ; then
3120 CFLAGS="$cf_trim_CFLAGS"
3121 CPPFLAGS="$cf_trim_CPPFLAGS"
3126 cf_new_extra_cppflags=
3128 for cf_add_cflags in $cf_cv_posix_c_source
3130 case $cf_fix_cppflags in
3132 case $cf_add_cflags in #(vi
3133 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
3134 case $cf_add_cflags in
3136 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3138 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3139 && test -z "${cf_tst_cflags}" \
3140 && cf_fix_cppflags=yes
3142 if test $cf_fix_cppflags = yes ; then
3143 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3145 elif test "${cf_tst_cflags}" = "\"'" ; then
3146 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3152 *$cf_add_cflags) #(vi
3155 case $cf_add_cflags in #(vi
3157 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3159 CPPFLAGS=`echo "$CPPFLAGS" | \
3160 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3161 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3165 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
3170 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
3175 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3177 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
3179 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3180 && test -z "${cf_tst_cflags}" \
3181 && cf_fix_cppflags=no
3186 if test -n "$cf_new_cflags" ; then
3188 CFLAGS="$CFLAGS $cf_new_cflags"
3191 if test -n "$cf_new_cppflags" ; then
3193 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
3196 if test -n "$cf_new_extra_cppflags" ; then
3198 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
3206 if test -n "$cf_xopen_source" ; then
3211 cf_new_extra_cppflags=
3213 for cf_add_cflags in $cf_xopen_source
3215 case $cf_fix_cppflags in
3217 case $cf_add_cflags in #(vi
3218 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
3219 case $cf_add_cflags in
3221 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3223 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3224 && test -z "${cf_tst_cflags}" \
3225 && cf_fix_cppflags=yes
3227 if test $cf_fix_cppflags = yes ; then
3228 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3230 elif test "${cf_tst_cflags}" = "\"'" ; then
3231 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3237 *$cf_add_cflags) #(vi
3240 case $cf_add_cflags in #(vi
3242 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3244 CPPFLAGS=`echo "$CPPFLAGS" | \
3245 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3246 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3250 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
3255 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
3260 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3262 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
3264 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3265 && test -z "${cf_tst_cflags}" \
3266 && cf_fix_cppflags=no
3271 if test -n "$cf_new_cflags" ; then
3273 CFLAGS="$CFLAGS $cf_new_cflags"
3276 if test -n "$cf_new_cppflags" ; then
3278 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
3281 if test -n "$cf_new_extra_cppflags" ; then
3283 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
3288 echo "$as_me:3288: checking for $CC option to accept ANSI C" >&5
3289 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
3290 if test "${ac_cv_prog_cc_stdc+set}" = set; then
3291 echo $ECHO_N "(cached) $ECHO_C" >&6
3293 ac_cv_prog_cc_stdc=no
3295 cat >conftest.$ac_ext <<_ACEOF
3296 #line 3296 "configure"
3297 #include "confdefs.h"
3300 #include <sys/types.h>
3301 #include <sys/stat.h>
3302 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
3303 struct buf { int x; };
3304 FILE * (*rcsopen) (struct buf *, struct stat *, int);
3305 static char *e (p, i)
3311 static char *f (char * (*g) (char **, int), char **p, ...)
3316 s = g (p, va_arg (v,int));
3320 int test (int i, double x);
3321 struct s1 {int (*f) (int a);};
3322 struct s2 {int (*f) (double a);};
3323 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3329 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
3334 # Don't try gcc -ansi; that turns off useful extensions and
3335 # breaks some systems' header files.
3336 # AIX -qlanglvl=ansi
3337 # Ultrix and OSF/1 -std1
3338 # HP-UX 10.20 and later -Ae
3339 # HP-UX older versions -Aa -D_HPUX_SOURCE
3340 # SVR4 -Xc -D__EXTENSIONS__
3341 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3343 CC="$ac_save_CC $ac_arg"
3344 rm -f conftest.$ac_objext
3345 if { (eval echo "$as_me:3345: \"$ac_compile\"") >&5
3346 (eval $ac_compile) 2>&5
3348 echo "$as_me:3348: \$? = $ac_status" >&5
3349 (exit $ac_status); } &&
3350 { ac_try='test -s conftest.$ac_objext'
3351 { (eval echo "$as_me:3351: \"$ac_try\"") >&5
3354 echo "$as_me:3354: \$? = $ac_status" >&5
3355 (exit $ac_status); }; }; then
3356 ac_cv_prog_cc_stdc=$ac_arg
3359 echo "$as_me: failed program was:" >&5
3360 cat conftest.$ac_ext >&5
3362 rm -f conftest.$ac_objext
3364 rm -f conftest.$ac_ext conftest.$ac_objext
3369 case "x$ac_cv_prog_cc_stdc" in
3371 echo "$as_me:3371: result: none needed" >&5
3372 echo "${ECHO_T}none needed" >&6 ;;
3374 echo "$as_me:3374: result: $ac_cv_prog_cc_stdc" >&5
3375 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
3376 CC="$CC $ac_cv_prog_cc_stdc" ;;
3379 echo "$as_me:3379: checking for an ANSI C-conforming const" >&5
3380 echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
3381 if test "${ac_cv_c_const+set}" = set; then
3382 echo $ECHO_N "(cached) $ECHO_C" >&6
3384 cat >conftest.$ac_ext <<_ACEOF
3385 #line 3385 "configure"
3386 #include "confdefs.h"
3391 /* FIXME: Include the comments suggested by Paul. */
3393 /* Ultrix mips cc rejects this. */
3394 typedef int charset[2];
3396 /* SunOS 4.1.1 cc rejects this. */
3397 char const *const *ccp;
3399 /* NEC SVR4.0.2 mips cc rejects this. */
3400 struct point {int x, y;};
3401 static struct point const zero = {0,0};
3402 /* AIX XL C 1.02.0.0 rejects this.
3403 It does not let you subtract one const X* pointer from another in
3404 an arm of an if-expression whose if-part is not a constant
3406 const char *g = "string";
3407 ccp = &g + (g ? g-g : 0);
3408 /* HPUX 7.0 cc rejects these. */
3411 ccp = (char const *const *) p;
3412 { /* SCO 3.2v4 cc rejects this. */
3414 char const *s = 0 ? (char *) 0 : (char const *) 0;
3418 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
3420 const int *foo = &x[0];
3423 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
3424 typedef const int *iptr;
3428 { /* AIX XL C 1.02.0.0 rejects this saying
3429 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
3430 struct s { int j; const int *ap[3]; };
3431 struct s *b; b->j = 5;
3433 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
3442 rm -f conftest.$ac_objext
3443 if { (eval echo "$as_me:3443: \"$ac_compile\"") >&5
3444 (eval $ac_compile) 2>&5
3446 echo "$as_me:3446: \$? = $ac_status" >&5
3447 (exit $ac_status); } &&
3448 { ac_try='test -s conftest.$ac_objext'
3449 { (eval echo "$as_me:3449: \"$ac_try\"") >&5
3452 echo "$as_me:3452: \$? = $ac_status" >&5
3453 (exit $ac_status); }; }; then
3456 echo "$as_me: failed program was:" >&5
3457 cat conftest.$ac_ext >&5
3460 rm -f conftest.$ac_objext conftest.$ac_ext
3462 echo "$as_me:3462: result: $ac_cv_c_const" >&5
3463 echo "${ECHO_T}$ac_cv_c_const" >&6
3464 if test $ac_cv_c_const = no; then
3466 cat >>confdefs.h <<\EOF
3472 echo "$as_me:3472: checking for signal global datatype" >&5
3473 echo $ECHO_N "checking for signal global datatype... $ECHO_C" >&6
3474 if test "${cf_cv_sig_atomic_t+set}" = set; then
3475 echo $ECHO_N "(cached) $ECHO_C" >&6
3479 "volatile sig_atomic_t" \
3483 cat >conftest.$ac_ext <<_ACEOF
3484 #line 3484 "configure"
3485 #include "confdefs.h"
3487 #include <sys/types.h>
3493 static void handler(int sig)
3500 signal(SIGINT, handler);
3506 rm -f conftest.$ac_objext
3507 if { (eval echo "$as_me:3507: \"$ac_compile\"") >&5
3508 (eval $ac_compile) 2>&5
3510 echo "$as_me:3510: \$? = $ac_status" >&5
3511 (exit $ac_status); } &&
3512 { ac_try='test -s conftest.$ac_objext'
3513 { (eval echo "$as_me:3513: \"$ac_try\"") >&5
3516 echo "$as_me:3516: \$? = $ac_status" >&5
3517 (exit $ac_status); }; }; then
3518 cf_cv_sig_atomic_t=$cf_type
3520 echo "$as_me: failed program was:" >&5
3521 cat conftest.$ac_ext >&5
3522 cf_cv_sig_atomic_t=no
3524 rm -f conftest.$ac_objext conftest.$ac_ext
3525 test "$cf_cv_sig_atomic_t" != no && break
3530 echo "$as_me:3530: result: $cf_cv_sig_atomic_t" >&5
3531 echo "${ECHO_T}$cf_cv_sig_atomic_t" >&6
3532 test "$cf_cv_sig_atomic_t" != no && cat >>confdefs.h <<EOF
3533 #define SIG_ATOMIC_T $cf_cv_sig_atomic_t
3536 echo "$as_me:3536: checking if you want to see long compiling messages" >&5
3537 echo $ECHO_N "checking if you want to see long compiling messages... $ECHO_C" >&6
3539 # Check whether --enable-echo or --disable-echo was given.
3540 if test "${enable_echo+set}" = set; then
3541 enableval="$enable_echo"
3542 test "$enableval" != no && enableval=yes
3543 if test "$enableval" != "yes" ; then
3546 ECHO_LD='@echo linking $@;'
3547 RULE_CC='@echo compiling $<'
3548 SHOW_CC='@echo compiling $@'
3570 echo "$as_me:3570: result: $enableval" >&5
3571 echo "${ECHO_T}$enableval" >&6
3574 if test "$GCC" = yes ; then
3575 echo "$as_me:3575: checking version of $CC" >&5
3576 echo $ECHO_N "checking version of $CC... $ECHO_C" >&6
3577 GCC_VERSION="`${CC} --version 2>/dev/null | sed -e '2,$d' -e 's/^.*(GCC) //' -e 's/^[^0-9.]*//' -e 's/[^0-9.].*//'`"
3578 test -z "$GCC_VERSION" && GCC_VERSION=unknown
3579 echo "$as_me:3579: result: $GCC_VERSION" >&5
3580 echo "${ECHO_T}$GCC_VERSION" >&6
3583 if ( test "$GCC" = yes || test "$GXX" = yes )
3585 echo "$as_me:3585: checking if you want to turn on gcc warnings" >&5
3586 echo $ECHO_N "checking if you want to turn on gcc warnings... $ECHO_C" >&6
3588 # Check whether --enable-warnings or --disable-warnings was given.
3589 if test "${enable_warnings+set}" = set; then
3590 enableval="$enable_warnings"
3591 test "$enableval" != yes && enableval=no
3592 if test "$enableval" != "no" ; then
3602 echo "$as_me:3602: result: $with_warnings" >&5
3603 echo "${ECHO_T}$with_warnings" >&6
3604 if test "$with_warnings" = "yes"
3607 if test "$GCC" = yes
3609 cat > conftest.i <<EOF
3611 #define GCC_PRINTF 0
3616 #ifndef GCC_NORETURN
3617 #define GCC_NORETURN /* nothing */
3620 #define GCC_UNUSED /* nothing */
3623 if test "$GCC" = yes
3625 { echo "$as_me:3625: checking for $CC __attribute__ directives..." >&5
3626 echo "$as_me: checking for $CC __attribute__ directives..." >&6;}
3627 cat > conftest.$ac_ext <<EOF
3628 #line 3628 "${as_me:-configure}"
3629 #include "confdefs.h"
3630 #include "conftest.h"
3631 #include "conftest.i"
3633 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
3635 #define GCC_PRINTFLIKE(fmt,var) /*nothing*/
3638 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
3640 #define GCC_SCANFLIKE(fmt,var) /*nothing*/
3642 extern void wow(char *,...) GCC_SCANFLIKE(1,2);
3643 extern void oops(char *,...) GCC_PRINTFLIKE(1,2) GCC_NORETURN;
3644 extern void foo(void) GCC_NORETURN;
3645 int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { return 0; }
3647 cf_printf_attribute=no
3648 cf_scanf_attribute=no
3649 for cf_attribute in scanf printf unused noreturn
3652 cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
3654 cf_directive="__attribute__(($cf_attribute))"
3655 echo "checking for $CC $cf_directive" 1>&5
3657 case $cf_attribute in #(vi
3659 cf_printf_attribute=yes
3660 cat >conftest.h <<EOF
3661 #define GCC_$cf_ATTRIBUTE 1
3665 cf_scanf_attribute=yes
3666 cat >conftest.h <<EOF
3667 #define GCC_$cf_ATTRIBUTE 1
3671 cat >conftest.h <<EOF
3672 #define GCC_$cf_ATTRIBUTE $cf_directive
3677 if { (eval echo "$as_me:3677: \"$ac_compile\"") >&5
3678 (eval $ac_compile) 2>&5
3680 echo "$as_me:3680: \$? = $ac_status" >&5
3681 (exit $ac_status); }; then
3682 test -n "$verbose" && echo "$as_me:3682: result: ... $cf_attribute" >&5
3683 echo "${ECHO_T}... $cf_attribute" >&6
3684 cat conftest.h >>confdefs.h
3685 case $cf_attribute in #(vi
3687 if test "$cf_printf_attribute" = no ; then
3688 cat >>confdefs.h <<EOF
3689 #define GCC_PRINTFLIKE(fmt,var) /* nothing */
3692 cat >>confdefs.h <<EOF
3693 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
3698 if test "$cf_scanf_attribute" = no ; then
3699 cat >>confdefs.h <<EOF
3700 #define GCC_SCANFLIKE(fmt,var) /* nothing */
3703 cat >>confdefs.h <<EOF
3704 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
3712 fgrep define conftest.i >>confdefs.h
3719 if test "$GCC" = yes ; then
3722 echo "$as_me:3722: checking if this is really Intel C compiler" >&5
3723 echo $ECHO_N "checking if this is really Intel C compiler... $ECHO_C" >&6
3724 cf_save_CFLAGS="$CFLAGS"
3725 CFLAGS="$CFLAGS -no-gcc"
3726 cat >conftest.$ac_ext <<_ACEOF
3727 #line 3727 "configure"
3728 #include "confdefs.h"
3734 #ifdef __INTEL_COMPILER
3743 rm -f conftest.$ac_objext
3744 if { (eval echo "$as_me:3744: \"$ac_compile\"") >&5
3745 (eval $ac_compile) 2>&5
3747 echo "$as_me:3747: \$? = $ac_status" >&5
3748 (exit $ac_status); } &&
3749 { ac_try='test -s conftest.$ac_objext'
3750 { (eval echo "$as_me:3750: \"$ac_try\"") >&5
3753 echo "$as_me:3753: \$? = $ac_status" >&5
3754 (exit $ac_status); }; }; then
3756 cf_save_CFLAGS="$cf_save_CFLAGS -we147 -no-gcc"
3759 echo "$as_me: failed program was:" >&5
3760 cat conftest.$ac_ext >&5
3762 rm -f conftest.$ac_objext conftest.$ac_ext
3763 CFLAGS="$cf_save_CFLAGS"
3764 echo "$as_me:3764: result: $INTEL_COMPILER" >&5
3765 echo "${ECHO_T}$INTEL_COMPILER" >&6
3770 cat > conftest.$ac_ext <<EOF
3771 #line 3771 "${as_me:-configure}"
3772 int main(int argc, char *argv[]) { return (argv[argc-1] == 0) ; }
3775 if test "$INTEL_COMPILER" = yes
3777 # The "-wdXXX" options suppress warnings:
3778 # remark #1419: external declaration in primary source file
3779 # remark #1683: explicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem)
3780 # remark #1684: conversion from pointer to same-sized integral type (potential portability problem)
3781 # remark #193: zero used for undefined preprocessing identifier
3782 # remark #593: variable "curs_sb_left_arrow" was set but never used
3783 # remark #810: conversion from "int" to "Dimension={unsigned short}" may lose significant bits
3784 # remark #869: parameter "tw" was never referenced
3785 # remark #981: operands are evaluated in unspecified order
3786 # warning #279: controlling expression is constant
3788 { echo "$as_me:3788: checking for $CC warning options..." >&5
3789 echo "$as_me: checking for $CC warning options..." >&6;}
3790 cf_save_CFLAGS="$CFLAGS"
3791 EXTRA_CFLAGS="-Wall"
3803 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
3804 if { (eval echo "$as_me:3804: \"$ac_compile\"") >&5
3805 (eval $ac_compile) 2>&5
3807 echo "$as_me:3807: \$? = $ac_status" >&5
3808 (exit $ac_status); }; then
3809 test -n "$verbose" && echo "$as_me:3809: result: ... -$cf_opt" >&5
3810 echo "${ECHO_T}... -$cf_opt" >&6
3811 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
3814 CFLAGS="$cf_save_CFLAGS"
3816 elif test "$GCC" = yes
3818 { echo "$as_me:3818: checking for $CC warning options..." >&5
3819 echo "$as_me: checking for $CC warning options..." >&6;}
3820 cf_save_CFLAGS="$CFLAGS"
3823 test "$with_ext_const" = yes && cf_warn_CONST="Wwrite-strings"
3824 for cf_opt in W Wall \
3825 Wbad-function-cast \
3829 Wmissing-declarations \
3830 Wmissing-prototypes \
3834 Wstrict-prototypes \
3835 Wundef $cf_warn_CONST
3837 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
3838 if { (eval echo "$as_me:3838: \"$ac_compile\"") >&5
3839 (eval $ac_compile) 2>&5
3841 echo "$as_me:3841: \$? = $ac_status" >&5
3842 (exit $ac_status); }; then
3843 test -n "$verbose" && echo "$as_me:3843: result: ... -$cf_opt" >&5
3844 echo "${ECHO_T}... -$cf_opt" >&6
3845 case $cf_opt in #(vi
3847 CPPFLAGS="$CPPFLAGS -DXTSTRINGDEFINES"
3850 case $GCC_VERSION in
3852 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
3854 echo "${as_me:-configure}:3854: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
3860 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
3863 CFLAGS="$cf_save_CFLAGS"
3870 # Check whether --with-curses-dir or --without-curses-dir was given.
3871 if test "${with_curses_dir+set}" = set; then
3872 withval="$with_curses_dir"
3874 if test "x$prefix" != xNONE; then
3875 cf_path_syntax="$prefix"
3877 cf_path_syntax="$ac_default_prefix"
3880 case ".$withval" in #(vi
3881 .\$\(*\)*|.\'*\'*) #(vi
3885 .[a-zA-Z]:[\\/]*) #(vi OS/2 EMX
3888 eval withval="$withval"
3889 case ".$withval" in #(vi
3891 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
3896 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
3899 { { echo "$as_me:3899: error: expected a pathname, not \"$withval\"" >&5
3900 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
3901 { (exit 1); exit 1; }; }
3905 cf_cv_curses_dir=$withval
3910 # Check whether --with-5lib or --without-5lib was given.
3911 if test "${with_5lib+set}" = set; then
3912 withval="$with_5lib"
3913 LIBS="-L/usr/5lib $LIBS"
3914 CPPFLAGS="$CPPFLAGS -I/usr/5include"
3917 # Check whether --with-ncursesw or --without-ncursesw was given.
3918 if test "${with_ncursesw+set}" = set; then
3919 withval="$with_ncursesw"
3920 cf_cv_screen=ncursesw
3923 # Check whether --with-ncurses or --without-ncurses was given.
3924 if test "${with_ncurses+set}" = set; then
3925 withval="$with_ncurses"
3926 cf_cv_screen=ncurses
3929 # Check whether --with-pdcurses or --without-pdcurses was given.
3930 if test "${with_pdcurses+set}" = set; then
3931 withval="$with_pdcurses"
3932 cf_cv_screen=pdcurses
3937 case $cf_cv_screen in
3940 echo "$as_me:3940: checking for extra include directories" >&5
3941 echo $ECHO_N "checking for extra include directories... $ECHO_C" >&6
3942 if test "${cf_cv_curses_incdir+set}" = set; then
3943 echo $ECHO_N "(cached) $ECHO_C" >&6
3946 cf_cv_curses_incdir=no
3947 case $host_os in #(vi
3949 test -d /usr/include/curses_colr && \
3950 cf_cv_curses_incdir="-I/usr/include/curses_colr"
3953 test -d /usr/5lib && \
3954 test -d /usr/5include && \
3955 cf_cv_curses_incdir="-I/usr/5include"
3960 echo "$as_me:3960: result: $cf_cv_curses_incdir" >&5
3961 echo "${ECHO_T}$cf_cv_curses_incdir" >&6
3962 test "$cf_cv_curses_incdir" != no && CPPFLAGS="$CPPFLAGS $cf_cv_curses_incdir"
3964 echo "$as_me:3964: checking if we have identified curses headers" >&5
3965 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
3966 if test "${cf_cv_ncurses_header+set}" = set; then
3967 echo $ECHO_N "(cached) $ECHO_C" >&6
3970 cf_cv_ncurses_header=none
3973 ncurses.h ncurses/curses.h ncurses/ncurses.h
3975 cat >conftest.$ac_ext <<_ACEOF
3976 #line 3976 "configure"
3977 #include "confdefs.h"
3978 #include <${cf_header}>
3982 initscr(); tgoto("?", 0,0)
3987 rm -f conftest.$ac_objext
3988 if { (eval echo "$as_me:3988: \"$ac_compile\"") >&5
3989 (eval $ac_compile) 2>&5
3991 echo "$as_me:3991: \$? = $ac_status" >&5
3992 (exit $ac_status); } &&
3993 { ac_try='test -s conftest.$ac_objext'
3994 { (eval echo "$as_me:3994: \"$ac_try\"") >&5
3997 echo "$as_me:3997: \$? = $ac_status" >&5
3998 (exit $ac_status); }; }; then
3999 cf_cv_ncurses_header=$cf_header; break
4001 echo "$as_me: failed program was:" >&5
4002 cat conftest.$ac_ext >&5
4004 rm -f conftest.$ac_objext conftest.$ac_ext
4008 echo "$as_me:4008: result: $cf_cv_ncurses_header" >&5
4009 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
4011 if test "$cf_cv_ncurses_header" = none ; then
4012 { { echo "$as_me:4012: error: No curses header-files found" >&5
4013 echo "$as_me: error: No curses header-files found" >&2;}
4014 { (exit 1); exit 1; }; }
4017 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
4019 for ac_header in $cf_cv_ncurses_header
4021 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
4022 echo "$as_me:4022: checking for $ac_header" >&5
4023 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4024 if eval "test \"\${$as_ac_Header+set}\" = set"; then
4025 echo $ECHO_N "(cached) $ECHO_C" >&6
4027 cat >conftest.$ac_ext <<_ACEOF
4028 #line 4028 "configure"
4029 #include "confdefs.h"
4030 #include <$ac_header>
4032 if { (eval echo "$as_me:4032: \"$ac_cpp conftest.$ac_ext\"") >&5
4033 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4035 egrep -v '^ *\+' conftest.er1 >conftest.err
4037 cat conftest.err >&5
4038 echo "$as_me:4038: \$? = $ac_status" >&5
4039 (exit $ac_status); } >/dev/null; then
4040 if test -s conftest.err; then
4041 ac_cpp_err=$ac_c_preproc_warn_flag
4048 if test -z "$ac_cpp_err"; then
4049 eval "$as_ac_Header=yes"
4051 echo "$as_me: failed program was:" >&5
4052 cat conftest.$ac_ext >&5
4053 eval "$as_ac_Header=no"
4055 rm -f conftest.err conftest.$ac_ext
4057 echo "$as_me:4057: result: `eval echo '${'$as_ac_Header'}'`" >&5
4058 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4059 if test `eval echo '${'$as_ac_Header'}'` = yes; then
4060 cat >>confdefs.h <<EOF
4061 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
4067 echo "$as_me:4067: checking for terminfo header" >&5
4068 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
4069 if test "${cf_cv_term_header+set}" = set; then
4070 echo $ECHO_N "(cached) $ECHO_C" >&6
4073 case ${cf_cv_ncurses_header} in #(vi
4074 */ncurses.h|*/ncursesw.h) #(vi
4075 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
4078 cf_term_header=term.h
4082 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
4084 cat >conftest.$ac_ext <<_ACEOF
4085 #line 4085 "configure"
4086 #include "confdefs.h"
4088 #include <${cf_cv_ncurses_header:-curses.h}>
4094 int x = auto_left_margin
4099 rm -f conftest.$ac_objext
4100 if { (eval echo "$as_me:4100: \"$ac_compile\"") >&5
4101 (eval $ac_compile) 2>&5
4103 echo "$as_me:4103: \$? = $ac_status" >&5
4104 (exit $ac_status); } &&
4105 { ac_try='test -s conftest.$ac_objext'
4106 { (eval echo "$as_me:4106: \"$ac_try\"") >&5
4109 echo "$as_me:4109: \$? = $ac_status" >&5
4110 (exit $ac_status); }; }; then
4112 cf_cv_term_header="$cf_test"
4114 echo "$as_me: failed program was:" >&5
4115 cat conftest.$ac_ext >&5
4117 cf_cv_term_header=unknown
4120 rm -f conftest.$ac_objext conftest.$ac_ext
4121 test "$cf_cv_term_header" != unknown && break
4125 echo "$as_me:4125: result: $cf_cv_term_header" >&5
4126 echo "${ECHO_T}$cf_cv_term_header" >&6
4128 # Set definitions to allow ifdef'ing to accommodate subdirectories
4130 case $cf_cv_term_header in # (vi
4132 cat >>confdefs.h <<\EOF
4133 #define HAVE_TERM_H 1
4139 case $cf_cv_term_header in # (vi
4140 ncurses/term.h) #(vi
4141 cat >>confdefs.h <<\EOF
4142 #define HAVE_NCURSES_TERM_H 1
4147 cat >>confdefs.h <<\EOF
4148 #define HAVE_NCURSESW_TERM_H 1
4154 echo "$as_me:4154: checking for ncurses version" >&5
4155 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
4156 if test "${cf_cv_ncurses_version+set}" = set; then
4157 echo $ECHO_N "(cached) $ECHO_C" >&6
4160 cf_cv_ncurses_version=no
4163 if test "$cross_compiling" = yes; then
4165 # This will not work if the preprocessor splits the line after the
4166 # Autoconf token. The 'unproto' program does that.
4167 cat > conftest.$ac_ext <<EOF
4168 #include <${cf_cv_ncurses_header:-curses.h}>
4170 #ifdef NCURSES_VERSION
4171 Autoconf NCURSES_VERSION
4179 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
4180 { (eval echo "$as_me:4180: \"$cf_try\"") >&5
4183 echo "$as_me:4183: \$? = $ac_status" >&5
4184 (exit $ac_status); }
4185 if test -f conftest.out ; then
4186 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
4187 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
4192 cat >conftest.$ac_ext <<_ACEOF
4193 #line 4193 "configure"
4194 #include "confdefs.h"
4196 #include <${cf_cv_ncurses_header:-curses.h}>
4200 FILE *fp = fopen("$cf_tempfile", "w");
4201 #ifdef NCURSES_VERSION
4202 # ifdef NCURSES_VERSION_PATCH
4203 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
4205 fprintf(fp, "%s\n", NCURSES_VERSION);
4209 fprintf(fp, "old\n");
4214 ${cf_cv_main_return:-return}(0);
4217 rm -f conftest$ac_exeext
4218 if { (eval echo "$as_me:4218: \"$ac_link\"") >&5
4219 (eval $ac_link) 2>&5
4221 echo "$as_me:4221: \$? = $ac_status" >&5
4222 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4223 { (eval echo "$as_me:4223: \"$ac_try\"") >&5
4226 echo "$as_me:4226: \$? = $ac_status" >&5
4227 (exit $ac_status); }; }; then
4229 cf_cv_ncurses_version=`cat $cf_tempfile`
4231 echo "$as_me: program exited with status $ac_status" >&5
4232 echo "$as_me: failed program was:" >&5
4233 cat conftest.$ac_ext >&5
4235 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
4240 echo "$as_me:4240: result: $cf_cv_ncurses_version" >&5
4241 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
4242 test "$cf_cv_ncurses_version" = no || cat >>confdefs.h <<\EOF
4246 echo "$as_me:4246: checking if we have identified curses libraries" >&5
4247 echo $ECHO_N "checking if we have identified curses libraries... $ECHO_C" >&6
4248 cat >conftest.$ac_ext <<_ACEOF
4249 #line 4249 "configure"
4250 #include "confdefs.h"
4251 #include <${cf_cv_ncurses_header:-curses.h}>
4255 initscr(); tgoto("?", 0,0)
4260 rm -f conftest.$ac_objext conftest$ac_exeext
4261 if { (eval echo "$as_me:4261: \"$ac_link\"") >&5
4262 (eval $ac_link) 2>&5
4264 echo "$as_me:4264: \$? = $ac_status" >&5
4265 (exit $ac_status); } &&
4266 { ac_try='test -s conftest$ac_exeext'
4267 { (eval echo "$as_me:4267: \"$ac_try\"") >&5
4270 echo "$as_me:4270: \$? = $ac_status" >&5
4271 (exit $ac_status); }; }; then
4274 echo "$as_me: failed program was:" >&5
4275 cat conftest.$ac_ext >&5
4278 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4279 echo "$as_me:4279: result: $cf_result" >&5
4280 echo "${ECHO_T}$cf_result" >&6
4282 if test "$cf_result" = no ; then
4283 case $host_os in #(vi
4285 echo "$as_me:4285: checking for tgoto in -lmytinfo" >&5
4286 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
4287 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
4288 echo $ECHO_N "(cached) $ECHO_C" >&6
4290 ac_check_lib_save_LIBS=$LIBS
4291 LIBS="-lmytinfo $LIBS"
4292 cat >conftest.$ac_ext <<_ACEOF
4293 #line 4293 "configure"
4294 #include "confdefs.h"
4296 /* Override any gcc2 internal prototype to avoid an error. */
4300 /* We use char because int might match the return type of a gcc2
4301 builtin and then its argument prototype would still apply. */
4311 rm -f conftest.$ac_objext conftest$ac_exeext
4312 if { (eval echo "$as_me:4312: \"$ac_link\"") >&5
4313 (eval $ac_link) 2>&5
4315 echo "$as_me:4315: \$? = $ac_status" >&5
4316 (exit $ac_status); } &&
4317 { ac_try='test -s conftest$ac_exeext'
4318 { (eval echo "$as_me:4318: \"$ac_try\"") >&5
4321 echo "$as_me:4321: \$? = $ac_status" >&5
4322 (exit $ac_status); }; }; then
4323 ac_cv_lib_mytinfo_tgoto=yes
4325 echo "$as_me: failed program was:" >&5
4326 cat conftest.$ac_ext >&5
4327 ac_cv_lib_mytinfo_tgoto=no
4329 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4330 LIBS=$ac_check_lib_save_LIBS
4332 echo "$as_me:4332: result: $ac_cv_lib_mytinfo_tgoto" >&5
4333 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
4334 if test $ac_cv_lib_mytinfo_tgoto = yes; then
4335 LIBS="-lmytinfo $LIBS"
4340 echo "$as_me:4340: checking for initscr in -lcur_colr" >&5
4341 echo $ECHO_N "checking for initscr in -lcur_colr... $ECHO_C" >&6
4342 if test "${ac_cv_lib_cur_colr_initscr+set}" = set; then
4343 echo $ECHO_N "(cached) $ECHO_C" >&6
4345 ac_check_lib_save_LIBS=$LIBS
4346 LIBS="-lcur_colr $LIBS"
4347 cat >conftest.$ac_ext <<_ACEOF
4348 #line 4348 "configure"
4349 #include "confdefs.h"
4351 /* Override any gcc2 internal prototype to avoid an error. */
4355 /* We use char because int might match the return type of a gcc2
4356 builtin and then its argument prototype would still apply. */
4366 rm -f conftest.$ac_objext conftest$ac_exeext
4367 if { (eval echo "$as_me:4367: \"$ac_link\"") >&5
4368 (eval $ac_link) 2>&5
4370 echo "$as_me:4370: \$? = $ac_status" >&5
4371 (exit $ac_status); } &&
4372 { ac_try='test -s conftest$ac_exeext'
4373 { (eval echo "$as_me:4373: \"$ac_try\"") >&5
4376 echo "$as_me:4376: \$? = $ac_status" >&5
4377 (exit $ac_status); }; }; then
4378 ac_cv_lib_cur_colr_initscr=yes
4380 echo "$as_me: failed program was:" >&5
4381 cat conftest.$ac_ext >&5
4382 ac_cv_lib_cur_colr_initscr=no
4384 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4385 LIBS=$ac_check_lib_save_LIBS
4387 echo "$as_me:4387: result: $ac_cv_lib_cur_colr_initscr" >&5
4388 echo "${ECHO_T}$ac_cv_lib_cur_colr_initscr" >&6
4389 if test $ac_cv_lib_cur_colr_initscr = yes; then
4391 LIBS="-lcur_colr $LIBS"
4392 ac_cv_func_initscr=yes
4396 echo "$as_me:4396: checking for initscr in -lHcurses" >&5
4397 echo $ECHO_N "checking for initscr in -lHcurses... $ECHO_C" >&6
4398 if test "${ac_cv_lib_Hcurses_initscr+set}" = set; then
4399 echo $ECHO_N "(cached) $ECHO_C" >&6
4401 ac_check_lib_save_LIBS=$LIBS
4402 LIBS="-lHcurses $LIBS"
4403 cat >conftest.$ac_ext <<_ACEOF
4404 #line 4404 "configure"
4405 #include "confdefs.h"
4407 /* Override any gcc2 internal prototype to avoid an error. */
4411 /* We use char because int might match the return type of a gcc2
4412 builtin and then its argument prototype would still apply. */
4422 rm -f conftest.$ac_objext conftest$ac_exeext
4423 if { (eval echo "$as_me:4423: \"$ac_link\"") >&5
4424 (eval $ac_link) 2>&5
4426 echo "$as_me:4426: \$? = $ac_status" >&5
4427 (exit $ac_status); } &&
4428 { ac_try='test -s conftest$ac_exeext'
4429 { (eval echo "$as_me:4429: \"$ac_try\"") >&5
4432 echo "$as_me:4432: \$? = $ac_status" >&5
4433 (exit $ac_status); }; }; then
4434 ac_cv_lib_Hcurses_initscr=yes
4436 echo "$as_me: failed program was:" >&5
4437 cat conftest.$ac_ext >&5
4438 ac_cv_lib_Hcurses_initscr=no
4440 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4441 LIBS=$ac_check_lib_save_LIBS
4443 echo "$as_me:4443: result: $ac_cv_lib_Hcurses_initscr" >&5
4444 echo "${ECHO_T}$ac_cv_lib_Hcurses_initscr" >&6
4445 if test $ac_cv_lib_Hcurses_initscr = yes; then
4447 # HP's header uses __HP_CURSES, but user claims _HP_CURSES.
4448 LIBS="-lHcurses $LIBS"
4449 CPPFLAGS="$CPPFLAGS -D__HP_CURSES -D_HP_CURSES"
4450 ac_cv_func_initscr=yes
4457 linux*) # Suse Linux does not follow /usr/lib convention
4459 if test -n "/lib" ; then
4460 for cf_add_libdir in /lib
4462 if test $cf_add_libdir = /usr/lib ; then
4464 elif test -d $cf_add_libdir
4467 if test -n "$LDFLAGS$LIBS" ; then
4468 # a loop is needed to ensure we can add subdirs of existing dirs
4469 for cf_test_libdir in $LDFLAGS $LIBS ; do
4470 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
4471 cf_have_libdir=yes; break
4475 if test "$cf_have_libdir" = no ; then
4476 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
4478 echo "${as_me:-configure}:4478: testing adding $cf_add_libdir to library-path ..." 1>&5
4480 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
4488 if test -d /usr/5lib ; then
4490 if test -n "/usr/5lib" ; then
4491 for cf_add_libdir in /usr/5lib
4493 if test $cf_add_libdir = /usr/lib ; then
4495 elif test -d $cf_add_libdir
4498 if test -n "$LDFLAGS$LIBS" ; then
4499 # a loop is needed to ensure we can add subdirs of existing dirs
4500 for cf_test_libdir in $LDFLAGS $LIBS ; do
4501 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
4502 cf_have_libdir=yes; break
4506 if test "$cf_have_libdir" = no ; then
4507 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
4509 echo "${as_me:-configure}:4509: testing adding $cf_add_libdir to library-path ..." 1>&5
4511 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
4517 LIBS="-lcurses -ltermcap $LIBS"
4519 ac_cv_func_initscr=yes
4523 if test ".$ac_cv_func_initscr" != .yes ; then
4524 cf_save_LIBS="$LIBS"
4528 if test ".${cf_cv_ncurses_version:-no}" != .no
4530 cf_check_list="ncurses curses cursesX"
4532 cf_check_list="cursesX curses ncurses"
4535 # Check for library containing tgoto. Do this before curses library
4536 # because it may be needed to link the test-case for initscr.
4537 echo "$as_me:4537: checking for tgoto" >&5
4538 echo $ECHO_N "checking for tgoto... $ECHO_C" >&6
4539 if test "${ac_cv_func_tgoto+set}" = set; then
4540 echo $ECHO_N "(cached) $ECHO_C" >&6
4542 cat >conftest.$ac_ext <<_ACEOF
4543 #line 4543 "configure"
4544 #include "confdefs.h"
4545 /* System header to define __stub macros and hopefully few prototypes,
4546 which can conflict with char tgoto (); below. */
4548 /* Override any gcc2 internal prototype to avoid an error. */
4552 /* We use char because int might match the return type of a gcc2
4553 builtin and then its argument prototype would still apply. */
4560 /* The GNU C library defines this for functions which it implements
4561 to always fail with ENOSYS. Some functions are actually named
4562 something starting with __ and the normal name is an alias. */
4563 #if defined (__stub_tgoto) || defined (__stub___tgoto)
4573 rm -f conftest.$ac_objext conftest$ac_exeext
4574 if { (eval echo "$as_me:4574: \"$ac_link\"") >&5
4575 (eval $ac_link) 2>&5
4577 echo "$as_me:4577: \$? = $ac_status" >&5
4578 (exit $ac_status); } &&
4579 { ac_try='test -s conftest$ac_exeext'
4580 { (eval echo "$as_me:4580: \"$ac_try\"") >&5
4583 echo "$as_me:4583: \$? = $ac_status" >&5
4584 (exit $ac_status); }; }; then
4585 ac_cv_func_tgoto=yes
4587 echo "$as_me: failed program was:" >&5
4588 cat conftest.$ac_ext >&5
4591 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4593 echo "$as_me:4593: result: $ac_cv_func_tgoto" >&5
4594 echo "${ECHO_T}$ac_cv_func_tgoto" >&6
4595 if test $ac_cv_func_tgoto = yes; then
4596 cf_term_lib=predefined
4599 for cf_term_lib in $cf_check_list termcap termlib unknown
4601 as_ac_Lib=`echo "ac_cv_lib_$cf_term_lib''_tgoto" | $as_tr_sh`
4602 echo "$as_me:4602: checking for tgoto in -l$cf_term_lib" >&5
4603 echo $ECHO_N "checking for tgoto in -l$cf_term_lib... $ECHO_C" >&6
4604 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
4605 echo $ECHO_N "(cached) $ECHO_C" >&6
4607 ac_check_lib_save_LIBS=$LIBS
4608 LIBS="-l$cf_term_lib $LIBS"
4609 cat >conftest.$ac_ext <<_ACEOF
4610 #line 4610 "configure"
4611 #include "confdefs.h"
4613 /* Override any gcc2 internal prototype to avoid an error. */
4617 /* We use char because int might match the return type of a gcc2
4618 builtin and then its argument prototype would still apply. */
4628 rm -f conftest.$ac_objext conftest$ac_exeext
4629 if { (eval echo "$as_me:4629: \"$ac_link\"") >&5
4630 (eval $ac_link) 2>&5
4632 echo "$as_me:4632: \$? = $ac_status" >&5
4633 (exit $ac_status); } &&
4634 { ac_try='test -s conftest$ac_exeext'
4635 { (eval echo "$as_me:4635: \"$ac_try\"") >&5
4638 echo "$as_me:4638: \$? = $ac_status" >&5
4639 (exit $ac_status); }; }; then
4640 eval "$as_ac_Lib=yes"
4642 echo "$as_me: failed program was:" >&5
4643 cat conftest.$ac_ext >&5
4644 eval "$as_ac_Lib=no"
4646 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4647 LIBS=$ac_check_lib_save_LIBS
4649 echo "$as_me:4649: result: `eval echo '${'$as_ac_Lib'}'`" >&5
4650 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
4651 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
4659 # Check for library containing initscr
4660 test "$cf_term_lib" != predefined && test "$cf_term_lib" != unknown && LIBS="-l$cf_term_lib $cf_save_LIBS"
4661 for cf_curs_lib in $cf_check_list xcurses jcurses pdcurses unknown
4663 as_ac_Lib=`echo "ac_cv_lib_$cf_curs_lib''_initscr" | $as_tr_sh`
4664 echo "$as_me:4664: checking for initscr in -l$cf_curs_lib" >&5
4665 echo $ECHO_N "checking for initscr in -l$cf_curs_lib... $ECHO_C" >&6
4666 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
4667 echo $ECHO_N "(cached) $ECHO_C" >&6
4669 ac_check_lib_save_LIBS=$LIBS
4670 LIBS="-l$cf_curs_lib $LIBS"
4671 cat >conftest.$ac_ext <<_ACEOF
4672 #line 4672 "configure"
4673 #include "confdefs.h"
4675 /* Override any gcc2 internal prototype to avoid an error. */
4679 /* We use char because int might match the return type of a gcc2
4680 builtin and then its argument prototype would still apply. */
4690 rm -f conftest.$ac_objext conftest$ac_exeext
4691 if { (eval echo "$as_me:4691: \"$ac_link\"") >&5
4692 (eval $ac_link) 2>&5
4694 echo "$as_me:4694: \$? = $ac_status" >&5
4695 (exit $ac_status); } &&
4696 { ac_try='test -s conftest$ac_exeext'
4697 { (eval echo "$as_me:4697: \"$ac_try\"") >&5
4700 echo "$as_me:4700: \$? = $ac_status" >&5
4701 (exit $ac_status); }; }; then
4702 eval "$as_ac_Lib=yes"
4704 echo "$as_me: failed program was:" >&5
4705 cat conftest.$ac_ext >&5
4706 eval "$as_ac_Lib=no"
4708 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4709 LIBS=$ac_check_lib_save_LIBS
4711 echo "$as_me:4711: result: `eval echo '${'$as_ac_Lib'}'`" >&5
4712 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
4713 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
4718 test $cf_curs_lib = unknown && { { echo "$as_me:4718: error: no curses library found" >&5
4719 echo "$as_me: error: no curses library found" >&2;}
4720 { (exit 1); exit 1; }; }
4722 LIBS="-l$cf_curs_lib $cf_save_LIBS"
4723 if test "$cf_term_lib" = unknown ; then
4724 echo "$as_me:4724: checking if we can link with $cf_curs_lib library" >&5
4725 echo $ECHO_N "checking if we can link with $cf_curs_lib library... $ECHO_C" >&6
4726 cat >conftest.$ac_ext <<_ACEOF
4727 #line 4727 "configure"
4728 #include "confdefs.h"
4729 #include <${cf_cv_ncurses_header:-curses.h}>
4738 rm -f conftest.$ac_objext conftest$ac_exeext
4739 if { (eval echo "$as_me:4739: \"$ac_link\"") >&5
4740 (eval $ac_link) 2>&5
4742 echo "$as_me:4742: \$? = $ac_status" >&5
4743 (exit $ac_status); } &&
4744 { ac_try='test -s conftest$ac_exeext'
4745 { (eval echo "$as_me:4745: \"$ac_try\"") >&5
4748 echo "$as_me:4748: \$? = $ac_status" >&5
4749 (exit $ac_status); }; }; then
4752 echo "$as_me: failed program was:" >&5
4753 cat conftest.$ac_ext >&5
4756 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4757 echo "$as_me:4757: result: $cf_result" >&5
4758 echo "${ECHO_T}$cf_result" >&6
4759 test $cf_result = no && { { echo "$as_me:4759: error: Cannot link curses library" >&5
4760 echo "$as_me: error: Cannot link curses library" >&2;}
4761 { (exit 1); exit 1; }; }
4762 elif test "$cf_curs_lib" = "$cf_term_lib" ; then
4764 elif test "$cf_term_lib" != predefined ; then
4765 echo "$as_me:4765: checking if we need both $cf_curs_lib and $cf_term_lib libraries" >&5
4766 echo $ECHO_N "checking if we need both $cf_curs_lib and $cf_term_lib libraries... $ECHO_C" >&6
4767 cat >conftest.$ac_ext <<_ACEOF
4768 #line 4768 "configure"
4769 #include "confdefs.h"
4770 #include <${cf_cv_ncurses_header:-curses.h}>
4774 initscr(); tgoto((char *)0, 0, 0);
4779 rm -f conftest.$ac_objext conftest$ac_exeext
4780 if { (eval echo "$as_me:4780: \"$ac_link\"") >&5
4781 (eval $ac_link) 2>&5
4783 echo "$as_me:4783: \$? = $ac_status" >&5
4784 (exit $ac_status); } &&
4785 { ac_try='test -s conftest$ac_exeext'
4786 { (eval echo "$as_me:4786: \"$ac_try\"") >&5
4789 echo "$as_me:4789: \$? = $ac_status" >&5
4790 (exit $ac_status); }; }; then
4793 echo "$as_me: failed program was:" >&5
4794 cat conftest.$ac_ext >&5
4796 LIBS="-l$cf_curs_lib -l$cf_term_lib $cf_save_LIBS"
4797 cat >conftest.$ac_ext <<_ACEOF
4798 #line 4798 "configure"
4799 #include "confdefs.h"
4800 #include <${cf_cv_ncurses_header:-curses.h}>
4809 rm -f conftest.$ac_objext conftest$ac_exeext
4810 if { (eval echo "$as_me:4810: \"$ac_link\"") >&5
4811 (eval $ac_link) 2>&5
4813 echo "$as_me:4813: \$? = $ac_status" >&5
4814 (exit $ac_status); } &&
4815 { ac_try='test -s conftest$ac_exeext'
4816 { (eval echo "$as_me:4816: \"$ac_try\"") >&5
4819 echo "$as_me:4819: \$? = $ac_status" >&5
4820 (exit $ac_status); }; }; then
4823 echo "$as_me: failed program was:" >&5
4824 cat conftest.$ac_ext >&5
4827 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4830 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4831 echo "$as_me:4831: result: $cf_result" >&5
4832 echo "${ECHO_T}$cf_result" >&6
4840 cf_ncuconfig_root=ncurses
4842 echo "Looking for ${cf_ncuconfig_root}-config"
4843 for ac_prog in ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
4845 # Extract the first word of "$ac_prog", so it can be a program name with args.
4846 set dummy $ac_prog; ac_word=$2
4847 echo "$as_me:4847: checking for $ac_word" >&5
4848 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4849 if test "${ac_cv_path_NCURSES_CONFIG+set}" = set; then
4850 echo $ECHO_N "(cached) $ECHO_C" >&6
4852 case $NCURSES_CONFIG in
4854 ac_cv_path_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test with a path.
4857 ac_save_IFS=$IFS; IFS=$ac_path_separator
4859 for ac_dir in $ac_dummy; do
4861 test -z "$ac_dir" && ac_dir=.
4862 if $as_executable_p "$ac_dir/$ac_word"; then
4863 ac_cv_path_NCURSES_CONFIG="$ac_dir/$ac_word"
4864 echo "$as_me:4864: found $ac_dir/$ac_word" >&5
4872 NCURSES_CONFIG=$ac_cv_path_NCURSES_CONFIG
4874 if test -n "$NCURSES_CONFIG"; then
4875 echo "$as_me:4875: result: $NCURSES_CONFIG" >&5
4876 echo "${ECHO_T}$NCURSES_CONFIG" >&6
4878 echo "$as_me:4878: result: no" >&5
4879 echo "${ECHO_T}no" >&6
4882 test -n "$NCURSES_CONFIG" && break
4884 test -n "$NCURSES_CONFIG" || NCURSES_CONFIG="none"
4886 if test "$NCURSES_CONFIG" != none ; then
4888 CPPFLAGS="$CPPFLAGS `$NCURSES_CONFIG --cflags`"
4889 LIBS="`$NCURSES_CONFIG --libs` $LIBS"
4891 # even with config script, some packages use no-override for curses.h
4893 echo "$as_me:4893: checking if we have identified curses headers" >&5
4894 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
4895 if test "${cf_cv_ncurses_header+set}" = set; then
4896 echo $ECHO_N "(cached) $ECHO_C" >&6
4899 cf_cv_ncurses_header=none
4906 cat >conftest.$ac_ext <<_ACEOF
4907 #line 4907 "configure"
4908 #include "confdefs.h"
4909 #include <${cf_header}>
4913 initscr(); tgoto("?", 0,0)
4918 rm -f conftest.$ac_objext
4919 if { (eval echo "$as_me:4919: \"$ac_compile\"") >&5
4920 (eval $ac_compile) 2>&5
4922 echo "$as_me:4922: \$? = $ac_status" >&5
4923 (exit $ac_status); } &&
4924 { ac_try='test -s conftest.$ac_objext'
4925 { (eval echo "$as_me:4925: \"$ac_try\"") >&5
4928 echo "$as_me:4928: \$? = $ac_status" >&5
4929 (exit $ac_status); }; }; then
4930 cf_cv_ncurses_header=$cf_header; break
4932 echo "$as_me: failed program was:" >&5
4933 cat conftest.$ac_ext >&5
4935 rm -f conftest.$ac_objext conftest.$ac_ext
4939 echo "$as_me:4939: result: $cf_cv_ncurses_header" >&5
4940 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
4942 if test "$cf_cv_ncurses_header" = none ; then
4943 { { echo "$as_me:4943: error: No curses header-files found" >&5
4944 echo "$as_me: error: No curses header-files found" >&2;}
4945 { (exit 1); exit 1; }; }
4948 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
4950 for ac_header in $cf_cv_ncurses_header
4952 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
4953 echo "$as_me:4953: checking for $ac_header" >&5
4954 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4955 if eval "test \"\${$as_ac_Header+set}\" = set"; then
4956 echo $ECHO_N "(cached) $ECHO_C" >&6
4958 cat >conftest.$ac_ext <<_ACEOF
4959 #line 4959 "configure"
4960 #include "confdefs.h"
4961 #include <$ac_header>
4963 if { (eval echo "$as_me:4963: \"$ac_cpp conftest.$ac_ext\"") >&5
4964 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4966 egrep -v '^ *\+' conftest.er1 >conftest.err
4968 cat conftest.err >&5
4969 echo "$as_me:4969: \$? = $ac_status" >&5
4970 (exit $ac_status); } >/dev/null; then
4971 if test -s conftest.err; then
4972 ac_cpp_err=$ac_c_preproc_warn_flag
4979 if test -z "$ac_cpp_err"; then
4980 eval "$as_ac_Header=yes"
4982 echo "$as_me: failed program was:" >&5
4983 cat conftest.$ac_ext >&5
4984 eval "$as_ac_Header=no"
4986 rm -f conftest.err conftest.$ac_ext
4988 echo "$as_me:4988: result: `eval echo '${'$as_ac_Header'}'`" >&5
4989 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4990 if test `eval echo '${'$as_ac_Header'}'` = yes; then
4991 cat >>confdefs.h <<EOF
4992 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
4998 cat >>confdefs.h <<\EOF
5002 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
5004 cat >>confdefs.h <<EOF
5005 #define $cf_nculib_ROOT 1
5008 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
5012 cf_ncuhdr_root=ncurses
5014 test -n "$cf_cv_curses_dir" && \
5015 test "$cf_cv_curses_dir" != "no" && { \
5017 if test -n "$cf_cv_curses_dir/include $cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
5018 for cf_add_incdir in $cf_cv_curses_dir/include $cf_cv_curses_dir/include/$cf_ncuhdr_root
5020 while test $cf_add_incdir != /usr/include
5022 if test -d $cf_add_incdir
5025 if test -n "$CFLAGS$CPPFLAGS" ; then
5026 # a loop is needed to ensure we can add subdirs of existing dirs
5027 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
5028 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
5029 cf_have_incdir=yes; break
5034 if test "$cf_have_incdir" = no ; then
5035 if test "$cf_add_incdir" = /usr/local/include ; then
5036 if test "$GCC" = yes
5038 cf_save_CPPFLAGS=$CPPFLAGS
5039 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
5040 cat >conftest.$ac_ext <<_ACEOF
5041 #line 5041 "configure"
5042 #include "confdefs.h"
5052 rm -f conftest.$ac_objext
5053 if { (eval echo "$as_me:5053: \"$ac_compile\"") >&5
5054 (eval $ac_compile) 2>&5
5056 echo "$as_me:5056: \$? = $ac_status" >&5
5057 (exit $ac_status); } &&
5058 { ac_try='test -s conftest.$ac_objext'
5059 { (eval echo "$as_me:5059: \"$ac_try\"") >&5
5062 echo "$as_me:5062: \$? = $ac_status" >&5
5063 (exit $ac_status); }; }; then
5066 echo "$as_me: failed program was:" >&5
5067 cat conftest.$ac_ext >&5
5070 rm -f conftest.$ac_objext conftest.$ac_ext
5071 CPPFLAGS=$cf_save_CPPFLAGS
5076 if test "$cf_have_incdir" = no ; then
5077 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
5079 echo "${as_me:-configure}:5079: testing adding $cf_add_incdir to include-path ..." 1>&5
5081 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
5083 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
5084 test "$cf_top_incdir" = "$cf_add_incdir" && break
5085 cf_add_incdir="$cf_top_incdir"
5096 echo "$as_me:5096: checking for $cf_ncuhdr_root header in include-path" >&5
5097 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
5098 if test "${cf_cv_ncurses_h+set}" = set; then
5099 echo $ECHO_N "(cached) $ECHO_C" >&6
5102 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
5103 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
5104 for cf_header in $cf_header_list
5107 cat >conftest.$ac_ext <<_ACEOF
5108 #line 5108 "configure"
5109 #include "confdefs.h"
5111 #include <$cf_header>
5116 #ifdef NCURSES_VERSION
5118 printf("%s\n", NCURSES_VERSION);
5131 rm -f conftest.$ac_objext
5132 if { (eval echo "$as_me:5132: \"$ac_compile\"") >&5
5133 (eval $ac_compile) 2>&5
5135 echo "$as_me:5135: \$? = $ac_status" >&5
5136 (exit $ac_status); } &&
5137 { ac_try='test -s conftest.$ac_objext'
5138 { (eval echo "$as_me:5138: \"$ac_try\"") >&5
5141 echo "$as_me:5141: \$? = $ac_status" >&5
5142 (exit $ac_status); }; }; then
5143 cf_cv_ncurses_h=$cf_header
5146 echo "$as_me: failed program was:" >&5
5147 cat conftest.$ac_ext >&5
5150 rm -f conftest.$ac_objext conftest.$ac_ext
5152 test "$cf_cv_ncurses_h" != no && break
5156 echo "$as_me:5156: result: $cf_cv_ncurses_h" >&5
5157 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
5159 if test "$cf_cv_ncurses_h" != no ; then
5160 cf_cv_ncurses_header=$cf_cv_ncurses_h
5163 echo "$as_me:5163: checking for $cf_ncuhdr_root include-path" >&5
5164 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
5165 if test "${cf_cv_ncurses_h2+set}" = set; then
5166 echo $ECHO_N "(cached) $ECHO_C" >&6
5169 test -n "$verbose" && echo
5173 # collect the current set of include-directories from compiler flags
5174 cf_header_path_list=""
5175 if test -n "${CFLAGS}${CPPFLAGS}" ; then
5176 for cf_header_path in $CPPFLAGS $CFLAGS
5178 case $cf_header_path in #(vi
5180 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
5182 test "$cf_header_path" != "NONE" && \
5183 test -d "$cf_header_path" && \
5185 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
5186 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
5187 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
5188 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
5189 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
5190 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"
5193 cf_header_path_list="$cf_header_path_list $cf_search"
5199 # add the variations for the package we are looking for
5203 test "/usr" != "$prefix" && \
5205 (test $prefix = NONE || test "/usr" != "$prefix") && {
5206 test -n "$verbose" && echo " ... testing for include-directories under /usr"
5207 test -d /usr/include && cf_search="$cf_search /usr/include"
5208 test -d /usr/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/include/$cf_ncuhdr_root"
5209 test -d /usr/include/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/include/$cf_ncuhdr_root/include"
5210 test -d /usr/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/$cf_ncuhdr_root/include"
5211 test -d /usr/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
5214 test "$prefix" != "NONE" && \
5215 test -d "$prefix" && \
5217 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
5218 test -d $prefix/include && cf_search="$cf_search $prefix/include"
5219 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
5220 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
5221 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
5222 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
5225 test "/usr/local" != "$prefix" && \
5226 test -d "/usr/local" && \
5227 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
5228 test -n "$verbose" && echo " ... testing for include-directories under /usr/local"
5229 test -d /usr/local/include && cf_search="$cf_search /usr/local/include"
5230 test -d /usr/local/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/local/include/$cf_ncuhdr_root"
5231 test -d /usr/local/include/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/local/include/$cf_ncuhdr_root/include"
5232 test -d /usr/local/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/local/$cf_ncuhdr_root/include"
5233 test -d /usr/local/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/local/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
5236 test "/opt" != "$prefix" && \
5238 (test $prefix = NONE || test "/opt" != "$prefix") && {
5239 test -n "$verbose" && echo " ... testing for include-directories under /opt"
5240 test -d /opt/include && cf_search="$cf_search /opt/include"
5241 test -d /opt/include/$cf_ncuhdr_root && cf_search="$cf_search /opt/include/$cf_ncuhdr_root"
5242 test -d /opt/include/$cf_ncuhdr_root/include && cf_search="$cf_search /opt/include/$cf_ncuhdr_root/include"
5243 test -d /opt/$cf_ncuhdr_root/include && cf_search="$cf_search /opt/$cf_ncuhdr_root/include"
5244 test -d /opt/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /opt/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
5247 test "$HOME" != "$prefix" && \
5248 test -d "$HOME" && \
5249 (test $prefix = NONE || test "$HOME" != "$prefix") && {
5250 test -n "$verbose" && echo " ... testing for include-directories under $HOME"
5251 test -d $HOME/include && cf_search="$cf_search $HOME/include"
5252 test -d $HOME/include/$cf_ncuhdr_root && cf_search="$cf_search $HOME/include/$cf_ncuhdr_root"
5253 test -d $HOME/include/$cf_ncuhdr_root/include && cf_search="$cf_search $HOME/include/$cf_ncuhdr_root/include"
5254 test -d $HOME/$cf_ncuhdr_root/include && cf_search="$cf_search $HOME/$cf_ncuhdr_root/include"
5255 test -d $HOME/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $HOME/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
5258 test "$includedir" != NONE && \
5259 test "$includedir" != "/usr/include" && \
5260 test -d "$includedir" && {
5261 test -d $includedir && cf_search="$cf_search $includedir"
5262 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
5265 test "$oldincludedir" != NONE && \
5266 test "$oldincludedir" != "/usr/include" && \
5267 test -d "$oldincludedir" && {
5268 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
5269 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
5272 cf_search="$cf_search $cf_header_path_list"
5274 test -n "$verbose" && echo search path $cf_search
5275 cf_save2_CPPFLAGS="$CPPFLAGS"
5276 for cf_incdir in $cf_search
5279 if test -n "$cf_incdir" ; then
5280 for cf_add_incdir in $cf_incdir
5282 while test $cf_add_incdir != /usr/include
5284 if test -d $cf_add_incdir
5287 if test -n "$CFLAGS$CPPFLAGS" ; then
5288 # a loop is needed to ensure we can add subdirs of existing dirs
5289 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
5290 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
5291 cf_have_incdir=yes; break
5296 if test "$cf_have_incdir" = no ; then
5297 if test "$cf_add_incdir" = /usr/local/include ; then
5298 if test "$GCC" = yes
5300 cf_save_CPPFLAGS=$CPPFLAGS
5301 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
5302 cat >conftest.$ac_ext <<_ACEOF
5303 #line 5303 "configure"
5304 #include "confdefs.h"
5314 rm -f conftest.$ac_objext
5315 if { (eval echo "$as_me:5315: \"$ac_compile\"") >&5
5316 (eval $ac_compile) 2>&5
5318 echo "$as_me:5318: \$? = $ac_status" >&5
5319 (exit $ac_status); } &&
5320 { ac_try='test -s conftest.$ac_objext'
5321 { (eval echo "$as_me:5321: \"$ac_try\"") >&5
5324 echo "$as_me:5324: \$? = $ac_status" >&5
5325 (exit $ac_status); }; }; then
5328 echo "$as_me: failed program was:" >&5
5329 cat conftest.$ac_ext >&5
5332 rm -f conftest.$ac_objext conftest.$ac_ext
5333 CPPFLAGS=$cf_save_CPPFLAGS
5338 if test "$cf_have_incdir" = no ; then
5339 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
5341 echo "${as_me:-configure}:5341: testing adding $cf_add_incdir to include-path ..." 1>&5
5343 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
5345 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
5346 test "$cf_top_incdir" = "$cf_add_incdir" && break
5347 cf_add_incdir="$cf_top_incdir"
5361 cat >conftest.$ac_ext <<_ACEOF
5362 #line 5362 "configure"
5363 #include "confdefs.h"
5365 #include <$cf_header>
5370 #ifdef NCURSES_VERSION
5372 printf("%s\n", NCURSES_VERSION);
5385 rm -f conftest.$ac_objext
5386 if { (eval echo "$as_me:5386: \"$ac_compile\"") >&5
5387 (eval $ac_compile) 2>&5
5389 echo "$as_me:5389: \$? = $ac_status" >&5
5390 (exit $ac_status); } &&
5391 { ac_try='test -s conftest.$ac_objext'
5392 { (eval echo "$as_me:5392: \"$ac_try\"") >&5
5395 echo "$as_me:5395: \$? = $ac_status" >&5
5396 (exit $ac_status); }; }; then
5397 cf_cv_ncurses_h2=$cf_header
5400 echo "$as_me: failed program was:" >&5
5401 cat conftest.$ac_ext >&5
5404 rm -f conftest.$ac_objext conftest.$ac_ext
5406 if test "$cf_cv_ncurses_h2" != no ; then
5407 cf_cv_ncurses_h2=$cf_incdir/$cf_header
5408 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
5411 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
5413 CPPFLAGS="$cf_save2_CPPFLAGS"
5414 test "$cf_cv_ncurses_h2" != no && break
5416 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:5416: error: not found" >&5
5417 echo "$as_me: error: not found" >&2;}
5418 { (exit 1); exit 1; }; }
5421 echo "$as_me:5421: result: $cf_cv_ncurses_h2" >&5
5422 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
5424 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
5425 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
5426 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
5427 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
5430 if test -n "$cf_1st_incdir" ; then
5431 for cf_add_incdir in $cf_1st_incdir
5433 while test $cf_add_incdir != /usr/include
5435 if test -d $cf_add_incdir
5438 if test -n "$CFLAGS$CPPFLAGS" ; then
5439 # a loop is needed to ensure we can add subdirs of existing dirs
5440 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
5441 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
5442 cf_have_incdir=yes; break
5447 if test "$cf_have_incdir" = no ; then
5448 if test "$cf_add_incdir" = /usr/local/include ; then
5449 if test "$GCC" = yes
5451 cf_save_CPPFLAGS=$CPPFLAGS
5452 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
5453 cat >conftest.$ac_ext <<_ACEOF
5454 #line 5454 "configure"
5455 #include "confdefs.h"
5465 rm -f conftest.$ac_objext
5466 if { (eval echo "$as_me:5466: \"$ac_compile\"") >&5
5467 (eval $ac_compile) 2>&5
5469 echo "$as_me:5469: \$? = $ac_status" >&5
5470 (exit $ac_status); } &&
5471 { ac_try='test -s conftest.$ac_objext'
5472 { (eval echo "$as_me:5472: \"$ac_try\"") >&5
5475 echo "$as_me:5475: \$? = $ac_status" >&5
5476 (exit $ac_status); }; }; then
5479 echo "$as_me: failed program was:" >&5
5480 cat conftest.$ac_ext >&5
5483 rm -f conftest.$ac_objext conftest.$ac_ext
5484 CPPFLAGS=$cf_save_CPPFLAGS
5489 if test "$cf_have_incdir" = no ; then
5490 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
5492 echo "${as_me:-configure}:5492: testing adding $cf_add_incdir to include-path ..." 1>&5
5494 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
5496 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
5497 test "$cf_top_incdir" = "$cf_add_incdir" && break
5498 cf_add_incdir="$cf_top_incdir"
5509 # Set definitions to allow ifdef'ing for ncurses.h
5511 case $cf_cv_ncurses_header in # (vi
5513 cat >>confdefs.h <<\EOF
5514 #define HAVE_NCURSES_H 1
5520 case $cf_cv_ncurses_header in # (vi
5521 ncurses/curses.h|ncurses/ncurses.h)
5522 cat >>confdefs.h <<\EOF
5523 #define HAVE_NCURSES_NCURSES_H 1
5527 ncursesw/curses.h|ncursesw/ncurses.h)
5528 cat >>confdefs.h <<\EOF
5529 #define HAVE_NCURSESW_NCURSES_H 1
5535 echo "$as_me:5535: checking for terminfo header" >&5
5536 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
5537 if test "${cf_cv_term_header+set}" = set; then
5538 echo $ECHO_N "(cached) $ECHO_C" >&6
5541 case ${cf_cv_ncurses_header} in #(vi
5542 */ncurses.h|*/ncursesw.h) #(vi
5543 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
5546 cf_term_header=term.h
5550 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
5552 cat >conftest.$ac_ext <<_ACEOF
5553 #line 5553 "configure"
5554 #include "confdefs.h"
5556 #include <${cf_cv_ncurses_header:-curses.h}>
5562 int x = auto_left_margin
5567 rm -f conftest.$ac_objext
5568 if { (eval echo "$as_me:5568: \"$ac_compile\"") >&5
5569 (eval $ac_compile) 2>&5
5571 echo "$as_me:5571: \$? = $ac_status" >&5
5572 (exit $ac_status); } &&
5573 { ac_try='test -s conftest.$ac_objext'
5574 { (eval echo "$as_me:5574: \"$ac_try\"") >&5
5577 echo "$as_me:5577: \$? = $ac_status" >&5
5578 (exit $ac_status); }; }; then
5580 cf_cv_term_header="$cf_test"
5582 echo "$as_me: failed program was:" >&5
5583 cat conftest.$ac_ext >&5
5585 cf_cv_term_header=unknown
5588 rm -f conftest.$ac_objext conftest.$ac_ext
5589 test "$cf_cv_term_header" != unknown && break
5593 echo "$as_me:5593: result: $cf_cv_term_header" >&5
5594 echo "${ECHO_T}$cf_cv_term_header" >&6
5596 # Set definitions to allow ifdef'ing to accommodate subdirectories
5598 case $cf_cv_term_header in # (vi
5600 cat >>confdefs.h <<\EOF
5601 #define HAVE_TERM_H 1
5607 case $cf_cv_term_header in # (vi
5608 ncurses/term.h) #(vi
5609 cat >>confdefs.h <<\EOF
5610 #define HAVE_NCURSES_TERM_H 1
5615 cat >>confdefs.h <<\EOF
5616 #define HAVE_NCURSESW_TERM_H 1
5622 # some applications need this, but should check for NCURSES_VERSION
5623 cat >>confdefs.h <<\EOF
5627 echo "$as_me:5627: checking for ncurses version" >&5
5628 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
5629 if test "${cf_cv_ncurses_version+set}" = set; then
5630 echo $ECHO_N "(cached) $ECHO_C" >&6
5633 cf_cv_ncurses_version=no
5636 if test "$cross_compiling" = yes; then
5638 # This will not work if the preprocessor splits the line after the
5639 # Autoconf token. The 'unproto' program does that.
5640 cat > conftest.$ac_ext <<EOF
5641 #include <${cf_cv_ncurses_header:-curses.h}>
5643 #ifdef NCURSES_VERSION
5644 Autoconf NCURSES_VERSION
5652 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
5653 { (eval echo "$as_me:5653: \"$cf_try\"") >&5
5656 echo "$as_me:5656: \$? = $ac_status" >&5
5657 (exit $ac_status); }
5658 if test -f conftest.out ; then
5659 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
5660 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
5665 cat >conftest.$ac_ext <<_ACEOF
5666 #line 5666 "configure"
5667 #include "confdefs.h"
5669 #include <${cf_cv_ncurses_header:-curses.h}>
5673 FILE *fp = fopen("$cf_tempfile", "w");
5674 #ifdef NCURSES_VERSION
5675 # ifdef NCURSES_VERSION_PATCH
5676 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
5678 fprintf(fp, "%s\n", NCURSES_VERSION);
5682 fprintf(fp, "old\n");
5687 ${cf_cv_main_return:-return}(0);
5690 rm -f conftest$ac_exeext
5691 if { (eval echo "$as_me:5691: \"$ac_link\"") >&5
5692 (eval $ac_link) 2>&5
5694 echo "$as_me:5694: \$? = $ac_status" >&5
5695 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5696 { (eval echo "$as_me:5696: \"$ac_try\"") >&5
5699 echo "$as_me:5699: \$? = $ac_status" >&5
5700 (exit $ac_status); }; }; then
5702 cf_cv_ncurses_version=`cat $cf_tempfile`
5704 echo "$as_me: program exited with status $ac_status" >&5
5705 echo "$as_me: failed program was:" >&5
5706 cat conftest.$ac_ext >&5
5708 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
5713 echo "$as_me:5713: result: $cf_cv_ncurses_version" >&5
5714 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
5715 test "$cf_cv_ncurses_version" = no || cat >>confdefs.h <<\EOF
5719 cf_nculib_root=ncurses
5720 # This works, except for the special case where we find gpm, but
5721 # ncurses is in a nonstandard location via $LIBS, and we really want
5724 cf_ncurses_SAVE="$LIBS"
5725 echo "$as_me:5725: checking for Gpm_Open in -lgpm" >&5
5726 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
5727 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
5728 echo $ECHO_N "(cached) $ECHO_C" >&6
5730 ac_check_lib_save_LIBS=$LIBS
5732 cat >conftest.$ac_ext <<_ACEOF
5733 #line 5733 "configure"
5734 #include "confdefs.h"
5736 /* Override any gcc2 internal prototype to avoid an error. */
5740 /* We use char because int might match the return type of a gcc2
5741 builtin and then its argument prototype would still apply. */
5751 rm -f conftest.$ac_objext conftest$ac_exeext
5752 if { (eval echo "$as_me:5752: \"$ac_link\"") >&5
5753 (eval $ac_link) 2>&5
5755 echo "$as_me:5755: \$? = $ac_status" >&5
5756 (exit $ac_status); } &&
5757 { ac_try='test -s conftest$ac_exeext'
5758 { (eval echo "$as_me:5758: \"$ac_try\"") >&5
5761 echo "$as_me:5761: \$? = $ac_status" >&5
5762 (exit $ac_status); }; }; then
5763 ac_cv_lib_gpm_Gpm_Open=yes
5765 echo "$as_me: failed program was:" >&5
5766 cat conftest.$ac_ext >&5
5767 ac_cv_lib_gpm_Gpm_Open=no
5769 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5770 LIBS=$ac_check_lib_save_LIBS
5772 echo "$as_me:5772: result: $ac_cv_lib_gpm_Gpm_Open" >&5
5773 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
5774 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
5775 echo "$as_me:5775: checking for initscr in -lgpm" >&5
5776 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
5777 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
5778 echo $ECHO_N "(cached) $ECHO_C" >&6
5780 ac_check_lib_save_LIBS=$LIBS
5782 cat >conftest.$ac_ext <<_ACEOF
5783 #line 5783 "configure"
5784 #include "confdefs.h"
5786 /* Override any gcc2 internal prototype to avoid an error. */
5790 /* We use char because int might match the return type of a gcc2
5791 builtin and then its argument prototype would still apply. */
5801 rm -f conftest.$ac_objext conftest$ac_exeext
5802 if { (eval echo "$as_me:5802: \"$ac_link\"") >&5
5803 (eval $ac_link) 2>&5
5805 echo "$as_me:5805: \$? = $ac_status" >&5
5806 (exit $ac_status); } &&
5807 { ac_try='test -s conftest$ac_exeext'
5808 { (eval echo "$as_me:5808: \"$ac_try\"") >&5
5811 echo "$as_me:5811: \$? = $ac_status" >&5
5812 (exit $ac_status); }; }; then
5813 ac_cv_lib_gpm_initscr=yes
5815 echo "$as_me: failed program was:" >&5
5816 cat conftest.$ac_ext >&5
5817 ac_cv_lib_gpm_initscr=no
5819 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5820 LIBS=$ac_check_lib_save_LIBS
5822 echo "$as_me:5822: result: $ac_cv_lib_gpm_initscr" >&5
5823 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
5824 if test $ac_cv_lib_gpm_initscr = yes; then
5825 LIBS="$cf_ncurses_SAVE"
5827 cf_ncurses_LIBS="-lgpm"
5832 case $host_os in #(vi
5834 # This is only necessary if you are linking against an obsolete
5835 # version of ncurses (but it should do no harm, since it's static).
5836 if test "$cf_nculib_root" = ncurses ; then
5837 echo "$as_me:5837: checking for tgoto in -lmytinfo" >&5
5838 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
5839 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
5840 echo $ECHO_N "(cached) $ECHO_C" >&6
5842 ac_check_lib_save_LIBS=$LIBS
5843 LIBS="-lmytinfo $LIBS"
5844 cat >conftest.$ac_ext <<_ACEOF
5845 #line 5845 "configure"
5846 #include "confdefs.h"
5848 /* Override any gcc2 internal prototype to avoid an error. */
5852 /* We use char because int might match the return type of a gcc2
5853 builtin and then its argument prototype would still apply. */
5863 rm -f conftest.$ac_objext conftest$ac_exeext
5864 if { (eval echo "$as_me:5864: \"$ac_link\"") >&5
5865 (eval $ac_link) 2>&5
5867 echo "$as_me:5867: \$? = $ac_status" >&5
5868 (exit $ac_status); } &&
5869 { ac_try='test -s conftest$ac_exeext'
5870 { (eval echo "$as_me:5870: \"$ac_try\"") >&5
5873 echo "$as_me:5873: \$? = $ac_status" >&5
5874 (exit $ac_status); }; }; then
5875 ac_cv_lib_mytinfo_tgoto=yes
5877 echo "$as_me: failed program was:" >&5
5878 cat conftest.$ac_ext >&5
5879 ac_cv_lib_mytinfo_tgoto=no
5881 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5882 LIBS=$ac_check_lib_save_LIBS
5884 echo "$as_me:5884: result: $ac_cv_lib_mytinfo_tgoto" >&5
5885 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
5886 if test $ac_cv_lib_mytinfo_tgoto = yes; then
5887 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
5894 LIBS="$cf_ncurses_LIBS $LIBS"
5896 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
5899 if test -n "$cf_cv_curses_dir/lib" ; then
5900 for cf_add_libdir in $cf_cv_curses_dir/lib
5902 if test $cf_add_libdir = /usr/lib ; then
5904 elif test -d $cf_add_libdir
5907 if test -n "$LDFLAGS$LIBS" ; then
5908 # a loop is needed to ensure we can add subdirs of existing dirs
5909 for cf_test_libdir in $LDFLAGS $LIBS ; do
5910 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
5911 cf_have_libdir=yes; break
5915 if test "$cf_have_libdir" = no ; then
5916 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
5918 echo "${as_me:-configure}:5918: testing adding $cf_add_libdir to library-path ..." 1>&5
5920 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
5926 LIBS="-l$cf_nculib_root $LIBS"
5929 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
5931 echo "$as_me:5931: checking for initscr" >&5
5932 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
5933 if test "${ac_cv_func_initscr+set}" = set; then
5934 echo $ECHO_N "(cached) $ECHO_C" >&6
5936 cat >conftest.$ac_ext <<_ACEOF
5937 #line 5937 "configure"
5938 #include "confdefs.h"
5939 /* System header to define __stub macros and hopefully few prototypes,
5940 which can conflict with char initscr (); below. */
5942 /* Override any gcc2 internal prototype to avoid an error. */
5946 /* We use char because int might match the return type of a gcc2
5947 builtin and then its argument prototype would still apply. */
5954 /* The GNU C library defines this for functions which it implements
5955 to always fail with ENOSYS. Some functions are actually named
5956 something starting with __ and the normal name is an alias. */
5957 #if defined (__stub_initscr) || defined (__stub___initscr)
5967 rm -f conftest.$ac_objext conftest$ac_exeext
5968 if { (eval echo "$as_me:5968: \"$ac_link\"") >&5
5969 (eval $ac_link) 2>&5
5971 echo "$as_me:5971: \$? = $ac_status" >&5
5972 (exit $ac_status); } &&
5973 { ac_try='test -s conftest$ac_exeext'
5974 { (eval echo "$as_me:5974: \"$ac_try\"") >&5
5977 echo "$as_me:5977: \$? = $ac_status" >&5
5978 (exit $ac_status); }; }; then
5979 ac_cv_func_initscr=yes
5981 echo "$as_me: failed program was:" >&5
5982 cat conftest.$ac_ext >&5
5983 ac_cv_func_initscr=no
5985 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5987 echo "$as_me:5987: result: $ac_cv_func_initscr" >&5
5988 echo "${ECHO_T}$ac_cv_func_initscr" >&6
5989 if test $ac_cv_func_initscr = yes; then
5990 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
5993 cf_save_LIBS="$LIBS"
5994 echo "$as_me:5994: checking for initscr in -l$cf_nculib_root" >&5
5995 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
5996 LIBS="-l$cf_nculib_root $LIBS"
5997 cat >conftest.$ac_ext <<_ACEOF
5998 #line 5998 "configure"
5999 #include "confdefs.h"
6000 #include <${cf_cv_ncurses_header:-curses.h}>
6009 rm -f conftest.$ac_objext conftest$ac_exeext
6010 if { (eval echo "$as_me:6010: \"$ac_link\"") >&5
6011 (eval $ac_link) 2>&5
6013 echo "$as_me:6013: \$? = $ac_status" >&5
6014 (exit $ac_status); } &&
6015 { ac_try='test -s conftest$ac_exeext'
6016 { (eval echo "$as_me:6016: \"$ac_try\"") >&5
6019 echo "$as_me:6019: \$? = $ac_status" >&5
6020 (exit $ac_status); }; }; then
6021 echo "$as_me:6021: result: yes" >&5
6022 echo "${ECHO_T}yes" >&6
6023 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
6026 echo "$as_me: failed program was:" >&5
6027 cat conftest.$ac_ext >&5
6028 echo "$as_me:6028: result: no" >&5
6029 echo "${ECHO_T}no" >&6
6032 cf_library_path_list=""
6033 if test -n "${LDFLAGS}${LIBS}" ; then
6034 for cf_library_path in $LDFLAGS $LIBS
6036 case $cf_library_path in #(vi
6038 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
6040 test "$cf_library_path" != "NONE" && \
6041 test -d "$cf_library_path" && \
6043 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
6044 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
6045 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
6046 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
6047 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
6048 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"
6051 cf_library_path_list="$cf_library_path_list $cf_search"
6059 test "/usr" != "$prefix" && \
6061 (test $prefix = NONE || test "/usr" != "$prefix") && {
6062 test -n "$verbose" && echo " ... testing for lib-directories under /usr"
6063 test -d /usr/lib && cf_search="$cf_search /usr/lib"
6064 test -d /usr/lib/$cf_nculib_root && cf_search="$cf_search /usr/lib/$cf_nculib_root"
6065 test -d /usr/lib/$cf_nculib_root/lib && cf_search="$cf_search /usr/lib/$cf_nculib_root/lib"
6066 test -d /usr/$cf_nculib_root/lib && cf_search="$cf_search /usr/$cf_nculib_root/lib"
6067 test -d /usr/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /usr/$cf_nculib_root/lib/$cf_nculib_root"
6070 test "$prefix" != "NONE" && \
6071 test -d "$prefix" && \
6073 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
6074 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
6075 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
6076 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
6077 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
6078 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
6081 test "/usr/local" != "$prefix" && \
6082 test -d "/usr/local" && \
6083 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
6084 test -n "$verbose" && echo " ... testing for lib-directories under /usr/local"
6085 test -d /usr/local/lib && cf_search="$cf_search /usr/local/lib"
6086 test -d /usr/local/lib/$cf_nculib_root && cf_search="$cf_search /usr/local/lib/$cf_nculib_root"
6087 test -d /usr/local/lib/$cf_nculib_root/lib && cf_search="$cf_search /usr/local/lib/$cf_nculib_root/lib"
6088 test -d /usr/local/$cf_nculib_root/lib && cf_search="$cf_search /usr/local/$cf_nculib_root/lib"
6089 test -d /usr/local/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /usr/local/$cf_nculib_root/lib/$cf_nculib_root"
6092 test "/opt" != "$prefix" && \
6094 (test $prefix = NONE || test "/opt" != "$prefix") && {
6095 test -n "$verbose" && echo " ... testing for lib-directories under /opt"
6096 test -d /opt/lib && cf_search="$cf_search /opt/lib"
6097 test -d /opt/lib/$cf_nculib_root && cf_search="$cf_search /opt/lib/$cf_nculib_root"
6098 test -d /opt/lib/$cf_nculib_root/lib && cf_search="$cf_search /opt/lib/$cf_nculib_root/lib"
6099 test -d /opt/$cf_nculib_root/lib && cf_search="$cf_search /opt/$cf_nculib_root/lib"
6100 test -d /opt/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /opt/$cf_nculib_root/lib/$cf_nculib_root"
6103 test "$HOME" != "$prefix" && \
6104 test -d "$HOME" && \
6105 (test $prefix = NONE || test "$HOME" != "$prefix") && {
6106 test -n "$verbose" && echo " ... testing for lib-directories under $HOME"
6107 test -d $HOME/lib && cf_search="$cf_search $HOME/lib"
6108 test -d $HOME/lib/$cf_nculib_root && cf_search="$cf_search $HOME/lib/$cf_nculib_root"
6109 test -d $HOME/lib/$cf_nculib_root/lib && cf_search="$cf_search $HOME/lib/$cf_nculib_root/lib"
6110 test -d $HOME/$cf_nculib_root/lib && cf_search="$cf_search $HOME/$cf_nculib_root/lib"
6111 test -d $HOME/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $HOME/$cf_nculib_root/lib/$cf_nculib_root"
6114 cf_search="$cf_library_path_list $cf_search"
6116 for cf_libdir in $cf_search
6118 echo "$as_me:6118: checking for -l$cf_nculib_root in $cf_libdir" >&5
6119 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
6120 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
6121 cat >conftest.$ac_ext <<_ACEOF
6122 #line 6122 "configure"
6123 #include "confdefs.h"
6124 #include <${cf_cv_ncurses_header:-curses.h}>
6133 rm -f conftest.$ac_objext conftest$ac_exeext
6134 if { (eval echo "$as_me:6134: \"$ac_link\"") >&5
6135 (eval $ac_link) 2>&5
6137 echo "$as_me:6137: \$? = $ac_status" >&5
6138 (exit $ac_status); } &&
6139 { ac_try='test -s conftest$ac_exeext'
6140 { (eval echo "$as_me:6140: \"$ac_try\"") >&5
6143 echo "$as_me:6143: \$? = $ac_status" >&5
6144 (exit $ac_status); }; }; then
6145 echo "$as_me:6145: result: yes" >&5
6146 echo "${ECHO_T}yes" >&6
6147 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
6150 echo "$as_me: failed program was:" >&5
6151 cat conftest.$ac_ext >&5
6152 echo "$as_me:6152: result: no" >&5
6153 echo "${ECHO_T}no" >&6
6154 LIBS="$cf_save_LIBS"
6156 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6160 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6164 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
6166 if test $cf_found_library = no ; then
6167 { { echo "$as_me:6167: error: Cannot link $cf_nculib_root library" >&5
6168 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
6169 { (exit 1); exit 1; }; }
6174 if test -n "$cf_ncurses_LIBS" ; then
6175 echo "$as_me:6175: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
6176 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
6177 cf_ncurses_SAVE="$LIBS"
6178 for p in $cf_ncurses_LIBS ; do
6179 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
6180 if test "$q" != "$LIBS" ; then
6184 cat >conftest.$ac_ext <<_ACEOF
6185 #line 6185 "configure"
6186 #include "confdefs.h"
6187 #include <${cf_cv_ncurses_header:-curses.h}>
6191 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
6196 rm -f conftest.$ac_objext conftest$ac_exeext
6197 if { (eval echo "$as_me:6197: \"$ac_link\"") >&5
6198 (eval $ac_link) 2>&5
6200 echo "$as_me:6200: \$? = $ac_status" >&5
6201 (exit $ac_status); } &&
6202 { ac_try='test -s conftest$ac_exeext'
6203 { (eval echo "$as_me:6203: \"$ac_try\"") >&5
6206 echo "$as_me:6206: \$? = $ac_status" >&5
6207 (exit $ac_status); }; }; then
6208 echo "$as_me:6208: result: yes" >&5
6209 echo "${ECHO_T}yes" >&6
6211 echo "$as_me: failed program was:" >&5
6212 cat conftest.$ac_ext >&5
6213 echo "$as_me:6213: result: no" >&5
6214 echo "${ECHO_T}no" >&6
6215 LIBS="$cf_ncurses_SAVE"
6217 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6220 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
6222 cat >>confdefs.h <<EOF
6223 #define $cf_nculib_ROOT 1
6232 echo "$as_me:6232: checking for multibyte character support" >&5
6233 echo $ECHO_N "checking for multibyte character support... $ECHO_C" >&6
6234 if test "${cf_cv_utf8_lib+set}" = set; then
6235 echo $ECHO_N "(cached) $ECHO_C" >&6
6238 cf_save_LIBS="$LIBS"
6239 cat >conftest.$ac_ext <<_ACEOF
6240 #line 6240 "configure"
6241 #include "confdefs.h"
6252 rm -f conftest.$ac_objext conftest$ac_exeext
6253 if { (eval echo "$as_me:6253: \"$ac_link\"") >&5
6254 (eval $ac_link) 2>&5
6256 echo "$as_me:6256: \$? = $ac_status" >&5
6257 (exit $ac_status); } &&
6258 { ac_try='test -s conftest$ac_exeext'
6259 { (eval echo "$as_me:6259: \"$ac_try\"") >&5
6262 echo "$as_me:6262: \$? = $ac_status" >&5
6263 (exit $ac_status); }; }; then
6266 echo "$as_me: failed program was:" >&5
6267 cat conftest.$ac_ext >&5
6269 # If the linkage is not already in the $CPPFLAGS/$LDFLAGS configuration, these
6270 # will be set on completion of the AC_TRY_LINK below.
6271 cf_cv_header_path_utf8=
6272 cf_cv_library_path_utf8=
6274 echo "${as_me:-configure}:6274: testing Starting FIND_LINKAGE(utf8,) ..." 1>&5
6276 cf_save_LIBS="$LIBS"
6278 cat >conftest.$ac_ext <<_ACEOF
6279 #line 6279 "configure"
6280 #include "confdefs.h"
6282 #include <libutf8.h>
6291 rm -f conftest.$ac_objext conftest$ac_exeext
6292 if { (eval echo "$as_me:6292: \"$ac_link\"") >&5
6293 (eval $ac_link) 2>&5
6295 echo "$as_me:6295: \$? = $ac_status" >&5
6296 (exit $ac_status); } &&
6297 { ac_try='test -s conftest$ac_exeext'
6298 { (eval echo "$as_me:6298: \"$ac_try\"") >&5
6301 echo "$as_me:6301: \$? = $ac_status" >&5
6302 (exit $ac_status); }; }; then
6304 cf_cv_find_linkage_utf8=yes
6305 cf_cv_header_path_utf8=/usr/include
6306 cf_cv_library_path_utf8=/usr/lib
6309 echo "$as_me: failed program was:" >&5
6310 cat conftest.$ac_ext >&5
6312 LIBS="-lutf8 $cf_save_LIBS"
6314 cat >conftest.$ac_ext <<_ACEOF
6315 #line 6315 "configure"
6316 #include "confdefs.h"
6318 #include <libutf8.h>
6327 rm -f conftest.$ac_objext conftest$ac_exeext
6328 if { (eval echo "$as_me:6328: \"$ac_link\"") >&5
6329 (eval $ac_link) 2>&5
6331 echo "$as_me:6331: \$? = $ac_status" >&5
6332 (exit $ac_status); } &&
6333 { ac_try='test -s conftest$ac_exeext'
6334 { (eval echo "$as_me:6334: \"$ac_try\"") >&5
6337 echo "$as_me:6337: \$? = $ac_status" >&5
6338 (exit $ac_status); }; }; then
6340 cf_cv_find_linkage_utf8=yes
6341 cf_cv_header_path_utf8=/usr/include
6342 cf_cv_library_path_utf8=/usr/lib
6343 cf_cv_library_file_utf8="-lutf8"
6346 echo "$as_me: failed program was:" >&5
6347 cat conftest.$ac_ext >&5
6349 cf_cv_find_linkage_utf8=no
6350 LIBS="$cf_save_LIBS"
6352 test -n "$verbose" && echo " find linkage for utf8 library" 1>&6
6354 echo "${as_me:-configure}:6354: testing find linkage for utf8 library ..." 1>&5
6356 echo "${as_me:-configure}:6356: testing Searching for headers in FIND_LINKAGE(utf8,) ..." 1>&5
6358 cf_save_CPPFLAGS="$CPPFLAGS"
6359 cf_test_CPPFLAGS="$CPPFLAGS"
6363 # collect the current set of include-directories from compiler flags
6364 cf_header_path_list=""
6365 if test -n "${CFLAGS}${CPPFLAGS}" ; then
6366 for cf_header_path in $CPPFLAGS $CFLAGS
6368 case $cf_header_path in #(vi
6370 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
6372 test "$cf_header_path" != "NONE" && \
6373 test -d "$cf_header_path" && \
6375 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
6376 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
6377 test -d $cf_header_path/include/utf8 && cf_search="$cf_search $cf_header_path/include/utf8"
6378 test -d $cf_header_path/include/utf8/include && cf_search="$cf_search $cf_header_path/include/utf8/include"
6379 test -d $cf_header_path/utf8/include && cf_search="$cf_search $cf_header_path/utf8/include"
6380 test -d $cf_header_path/utf8/include/utf8 && cf_search="$cf_search $cf_header_path/utf8/include/utf8"
6383 cf_header_path_list="$cf_header_path_list $cf_search"
6389 # add the variations for the package we are looking for
6393 test "/usr" != "$prefix" && \
6395 (test $prefix = NONE || test "/usr" != "$prefix") && {
6396 test -n "$verbose" && echo " ... testing for include-directories under /usr"
6397 test -d /usr/include && cf_search="$cf_search /usr/include"
6398 test -d /usr/include/utf8 && cf_search="$cf_search /usr/include/utf8"
6399 test -d /usr/include/utf8/include && cf_search="$cf_search /usr/include/utf8/include"
6400 test -d /usr/utf8/include && cf_search="$cf_search /usr/utf8/include"
6401 test -d /usr/utf8/include/utf8 && cf_search="$cf_search /usr/utf8/include/utf8"
6404 test "$prefix" != "NONE" && \
6405 test -d "$prefix" && \
6407 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
6408 test -d $prefix/include && cf_search="$cf_search $prefix/include"
6409 test -d $prefix/include/utf8 && cf_search="$cf_search $prefix/include/utf8"
6410 test -d $prefix/include/utf8/include && cf_search="$cf_search $prefix/include/utf8/include"
6411 test -d $prefix/utf8/include && cf_search="$cf_search $prefix/utf8/include"
6412 test -d $prefix/utf8/include/utf8 && cf_search="$cf_search $prefix/utf8/include/utf8"
6415 test "/usr/local" != "$prefix" && \
6416 test -d "/usr/local" && \
6417 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
6418 test -n "$verbose" && echo " ... testing for include-directories under /usr/local"
6419 test -d /usr/local/include && cf_search="$cf_search /usr/local/include"
6420 test -d /usr/local/include/utf8 && cf_search="$cf_search /usr/local/include/utf8"
6421 test -d /usr/local/include/utf8/include && cf_search="$cf_search /usr/local/include/utf8/include"
6422 test -d /usr/local/utf8/include && cf_search="$cf_search /usr/local/utf8/include"
6423 test -d /usr/local/utf8/include/utf8 && cf_search="$cf_search /usr/local/utf8/include/utf8"
6426 test "/opt" != "$prefix" && \
6428 (test $prefix = NONE || test "/opt" != "$prefix") && {
6429 test -n "$verbose" && echo " ... testing for include-directories under /opt"
6430 test -d /opt/include && cf_search="$cf_search /opt/include"
6431 test -d /opt/include/utf8 && cf_search="$cf_search /opt/include/utf8"
6432 test -d /opt/include/utf8/include && cf_search="$cf_search /opt/include/utf8/include"
6433 test -d /opt/utf8/include && cf_search="$cf_search /opt/utf8/include"
6434 test -d /opt/utf8/include/utf8 && cf_search="$cf_search /opt/utf8/include/utf8"
6437 test "$HOME" != "$prefix" && \
6438 test -d "$HOME" && \
6439 (test $prefix = NONE || test "$HOME" != "$prefix") && {
6440 test -n "$verbose" && echo " ... testing for include-directories under $HOME"
6441 test -d $HOME/include && cf_search="$cf_search $HOME/include"
6442 test -d $HOME/include/utf8 && cf_search="$cf_search $HOME/include/utf8"
6443 test -d $HOME/include/utf8/include && cf_search="$cf_search $HOME/include/utf8/include"
6444 test -d $HOME/utf8/include && cf_search="$cf_search $HOME/utf8/include"
6445 test -d $HOME/utf8/include/utf8 && cf_search="$cf_search $HOME/utf8/include/utf8"
6448 test "$includedir" != NONE && \
6449 test "$includedir" != "/usr/include" && \
6450 test -d "$includedir" && {
6451 test -d $includedir && cf_search="$cf_search $includedir"
6452 test -d $includedir/utf8 && cf_search="$cf_search $includedir/utf8"
6455 test "$oldincludedir" != NONE && \
6456 test "$oldincludedir" != "/usr/include" && \
6457 test -d "$oldincludedir" && {
6458 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
6459 test -d $oldincludedir/utf8 && cf_search="$cf_search $oldincludedir/utf8"
6462 cf_search="$cf_search $cf_header_path_list"
6464 for cf_cv_header_path_utf8 in $cf_search
6466 if test -d $cf_cv_header_path_utf8 ; then
6467 test -n "$verbose" && echo " ... testing $cf_cv_header_path_utf8" 1>&6
6469 echo "${as_me:-configure}:6469: testing ... testing $cf_cv_header_path_utf8 ..." 1>&5
6471 CPPFLAGS="$cf_save_CPPFLAGS -I$cf_cv_header_path_utf8"
6472 cat >conftest.$ac_ext <<_ACEOF
6473 #line 6473 "configure"
6474 #include "confdefs.h"
6476 #include <libutf8.h>
6485 rm -f conftest.$ac_objext
6486 if { (eval echo "$as_me:6486: \"$ac_compile\"") >&5
6487 (eval $ac_compile) 2>&5
6489 echo "$as_me:6489: \$? = $ac_status" >&5
6490 (exit $ac_status); } &&
6491 { ac_try='test -s conftest.$ac_objext'
6492 { (eval echo "$as_me:6492: \"$ac_try\"") >&5
6495 echo "$as_me:6495: \$? = $ac_status" >&5
6496 (exit $ac_status); }; }; then
6498 test -n "$verbose" && echo " ... found utf8 headers in $cf_cv_header_path_utf8" 1>&6
6500 echo "${as_me:-configure}:6500: testing ... found utf8 headers in $cf_cv_header_path_utf8 ..." 1>&5
6502 cf_cv_find_linkage_utf8=maybe
6503 cf_test_CPPFLAGS="$CPPFLAGS"
6506 echo "$as_me: failed program was:" >&5
6507 cat conftest.$ac_ext >&5
6509 CPPFLAGS="$cf_save_CPPFLAGS"
6512 rm -f conftest.$ac_objext conftest.$ac_ext
6516 if test "$cf_cv_find_linkage_utf8" = maybe ; then
6518 echo "${as_me:-configure}:6518: testing Searching for utf8 library in FIND_LINKAGE(utf8,) ..." 1>&5
6520 cf_save_LIBS="$LIBS"
6521 cf_save_LDFLAGS="$LDFLAGS"
6523 if test "$cf_cv_find_linkage_utf8" != yes ; then
6526 cf_library_path_list=""
6527 if test -n "${LDFLAGS}${LIBS}" ; then
6528 for cf_library_path in $LDFLAGS $LIBS
6530 case $cf_library_path in #(vi
6532 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
6534 test "$cf_library_path" != "NONE" && \
6535 test -d "$cf_library_path" && \
6537 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
6538 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
6539 test -d $cf_library_path/lib/utf8 && cf_search="$cf_search $cf_library_path/lib/utf8"
6540 test -d $cf_library_path/lib/utf8/lib && cf_search="$cf_search $cf_library_path/lib/utf8/lib"
6541 test -d $cf_library_path/utf8/lib && cf_search="$cf_search $cf_library_path/utf8/lib"
6542 test -d $cf_library_path/utf8/lib/utf8 && cf_search="$cf_search $cf_library_path/utf8/lib/utf8"
6545 cf_library_path_list="$cf_library_path_list $cf_search"
6553 test "/usr" != "$prefix" && \
6555 (test $prefix = NONE || test "/usr" != "$prefix") && {
6556 test -n "$verbose" && echo " ... testing for lib-directories under /usr"
6557 test -d /usr/lib && cf_search="$cf_search /usr/lib"
6558 test -d /usr/lib/utf8 && cf_search="$cf_search /usr/lib/utf8"
6559 test -d /usr/lib/utf8/lib && cf_search="$cf_search /usr/lib/utf8/lib"
6560 test -d /usr/utf8/lib && cf_search="$cf_search /usr/utf8/lib"
6561 test -d /usr/utf8/lib/utf8 && cf_search="$cf_search /usr/utf8/lib/utf8"
6564 test "$prefix" != "NONE" && \
6565 test -d "$prefix" && \
6567 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
6568 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
6569 test -d $prefix/lib/utf8 && cf_search="$cf_search $prefix/lib/utf8"
6570 test -d $prefix/lib/utf8/lib && cf_search="$cf_search $prefix/lib/utf8/lib"
6571 test -d $prefix/utf8/lib && cf_search="$cf_search $prefix/utf8/lib"
6572 test -d $prefix/utf8/lib/utf8 && cf_search="$cf_search $prefix/utf8/lib/utf8"
6575 test "/usr/local" != "$prefix" && \
6576 test -d "/usr/local" && \
6577 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
6578 test -n "$verbose" && echo " ... testing for lib-directories under /usr/local"
6579 test -d /usr/local/lib && cf_search="$cf_search /usr/local/lib"
6580 test -d /usr/local/lib/utf8 && cf_search="$cf_search /usr/local/lib/utf8"
6581 test -d /usr/local/lib/utf8/lib && cf_search="$cf_search /usr/local/lib/utf8/lib"
6582 test -d /usr/local/utf8/lib && cf_search="$cf_search /usr/local/utf8/lib"
6583 test -d /usr/local/utf8/lib/utf8 && cf_search="$cf_search /usr/local/utf8/lib/utf8"
6586 test "/opt" != "$prefix" && \
6588 (test $prefix = NONE || test "/opt" != "$prefix") && {
6589 test -n "$verbose" && echo " ... testing for lib-directories under /opt"
6590 test -d /opt/lib && cf_search="$cf_search /opt/lib"
6591 test -d /opt/lib/utf8 && cf_search="$cf_search /opt/lib/utf8"
6592 test -d /opt/lib/utf8/lib && cf_search="$cf_search /opt/lib/utf8/lib"
6593 test -d /opt/utf8/lib && cf_search="$cf_search /opt/utf8/lib"
6594 test -d /opt/utf8/lib/utf8 && cf_search="$cf_search /opt/utf8/lib/utf8"
6597 test "$HOME" != "$prefix" && \
6598 test -d "$HOME" && \
6599 (test $prefix = NONE || test "$HOME" != "$prefix") && {
6600 test -n "$verbose" && echo " ... testing for lib-directories under $HOME"
6601 test -d $HOME/lib && cf_search="$cf_search $HOME/lib"
6602 test -d $HOME/lib/utf8 && cf_search="$cf_search $HOME/lib/utf8"
6603 test -d $HOME/lib/utf8/lib && cf_search="$cf_search $HOME/lib/utf8/lib"
6604 test -d $HOME/utf8/lib && cf_search="$cf_search $HOME/utf8/lib"
6605 test -d $HOME/utf8/lib/utf8 && cf_search="$cf_search $HOME/utf8/lib/utf8"
6608 cf_search="$cf_library_path_list $cf_search"
6610 for cf_cv_library_path_utf8 in $cf_search
6612 if test -d $cf_cv_library_path_utf8 ; then
6613 test -n "$verbose" && echo " ... testing $cf_cv_library_path_utf8" 1>&6
6615 echo "${as_me:-configure}:6615: testing ... testing $cf_cv_library_path_utf8 ..." 1>&5
6617 CPPFLAGS="$cf_test_CPPFLAGS"
6618 LIBS="-lutf8 $cf_save_LIBS"
6619 LDFLAGS="$cf_save_LDFLAGS -L$cf_cv_library_path_utf8"
6620 cat >conftest.$ac_ext <<_ACEOF
6621 #line 6621 "configure"
6622 #include "confdefs.h"
6624 #include <libutf8.h>
6633 rm -f conftest.$ac_objext conftest$ac_exeext
6634 if { (eval echo "$as_me:6634: \"$ac_link\"") >&5
6635 (eval $ac_link) 2>&5
6637 echo "$as_me:6637: \$? = $ac_status" >&5
6638 (exit $ac_status); } &&
6639 { ac_try='test -s conftest$ac_exeext'
6640 { (eval echo "$as_me:6640: \"$ac_try\"") >&5
6643 echo "$as_me:6643: \$? = $ac_status" >&5
6644 (exit $ac_status); }; }; then
6646 test -n "$verbose" && echo " ... found utf8 library in $cf_cv_library_path_utf8" 1>&6
6648 echo "${as_me:-configure}:6648: testing ... found utf8 library in $cf_cv_library_path_utf8 ..." 1>&5
6650 cf_cv_find_linkage_utf8=yes
6651 cf_cv_library_file_utf8="-lutf8"
6654 echo "$as_me: failed program was:" >&5
6655 cat conftest.$ac_ext >&5
6657 CPPFLAGS="$cf_save_CPPFLAGS"
6658 LIBS="$cf_save_LIBS"
6659 LDFLAGS="$cf_save_LDFLAGS"
6662 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6665 CPPFLAGS="$cf_save_CPPFLAGS"
6666 LDFLAGS="$cf_save_LDFLAGS"
6670 cf_cv_find_linkage_utf8=no
6674 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6677 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6679 LIBS="$cf_save_LIBS"
6681 if test "$cf_cv_find_linkage_utf8" = yes ; then
6682 cf_cv_utf8_lib=add-on
6688 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6690 echo "$as_me:6690: result: $cf_cv_utf8_lib" >&5
6691 echo "${ECHO_T}$cf_cv_utf8_lib" >&6
6693 # HAVE_LIBUTF8_H is used by ncurses if curses.h is shared between
6695 if test "$cf_cv_utf8_lib" = "add-on" ; then
6696 cat >>confdefs.h <<\EOF
6697 #define HAVE_LIBUTF8_H 1
6700 if test -n "$cf_cv_header_path_utf8" ; then
6701 for cf_add_incdir in $cf_cv_header_path_utf8
6703 while test $cf_add_incdir != /usr/include
6705 if test -d $cf_add_incdir
6708 if test -n "$CFLAGS$CPPFLAGS" ; then
6709 # a loop is needed to ensure we can add subdirs of existing dirs
6710 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
6711 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
6712 cf_have_incdir=yes; break
6717 if test "$cf_have_incdir" = no ; then
6718 if test "$cf_add_incdir" = /usr/local/include ; then
6719 if test "$GCC" = yes
6721 cf_save_CPPFLAGS=$CPPFLAGS
6722 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6723 cat >conftest.$ac_ext <<_ACEOF
6724 #line 6724 "configure"
6725 #include "confdefs.h"
6735 rm -f conftest.$ac_objext
6736 if { (eval echo "$as_me:6736: \"$ac_compile\"") >&5
6737 (eval $ac_compile) 2>&5
6739 echo "$as_me:6739: \$? = $ac_status" >&5
6740 (exit $ac_status); } &&
6741 { ac_try='test -s conftest.$ac_objext'
6742 { (eval echo "$as_me:6742: \"$ac_try\"") >&5
6745 echo "$as_me:6745: \$? = $ac_status" >&5
6746 (exit $ac_status); }; }; then
6749 echo "$as_me: failed program was:" >&5
6750 cat conftest.$ac_ext >&5
6753 rm -f conftest.$ac_objext conftest.$ac_ext
6754 CPPFLAGS=$cf_save_CPPFLAGS
6759 if test "$cf_have_incdir" = no ; then
6760 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
6762 echo "${as_me:-configure}:6762: testing adding $cf_add_incdir to include-path ..." 1>&5
6764 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6766 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
6767 test "$cf_top_incdir" = "$cf_add_incdir" && break
6768 cf_add_incdir="$cf_top_incdir"
6777 if test -n "$cf_cv_library_path_utf8" ; then
6778 for cf_add_libdir in $cf_cv_library_path_utf8
6780 if test $cf_add_libdir = /usr/lib ; then
6782 elif test -d $cf_add_libdir
6785 if test -n "$LDFLAGS$LIBS" ; then
6786 # a loop is needed to ensure we can add subdirs of existing dirs
6787 for cf_test_libdir in $LDFLAGS $LIBS ; do
6788 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
6789 cf_have_libdir=yes; break
6793 if test "$cf_have_libdir" = no ; then
6794 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
6796 echo "${as_me:-configure}:6796: testing adding $cf_add_libdir to library-path ..." 1>&5
6798 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
6804 LIBS="$cf_cv_library_file_utf8 $LIBS"
6807 cf_ncuconfig_root=ncursesw
6809 echo "Looking for ${cf_ncuconfig_root}-config"
6810 for ac_prog in ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
6812 # Extract the first word of "$ac_prog", so it can be a program name with args.
6813 set dummy $ac_prog; ac_word=$2
6814 echo "$as_me:6814: checking for $ac_word" >&5
6815 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
6816 if test "${ac_cv_path_NCURSES_CONFIG+set}" = set; then
6817 echo $ECHO_N "(cached) $ECHO_C" >&6
6819 case $NCURSES_CONFIG in
6821 ac_cv_path_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test with a path.
6824 ac_save_IFS=$IFS; IFS=$ac_path_separator
6826 for ac_dir in $ac_dummy; do
6828 test -z "$ac_dir" && ac_dir=.
6829 if $as_executable_p "$ac_dir/$ac_word"; then
6830 ac_cv_path_NCURSES_CONFIG="$ac_dir/$ac_word"
6831 echo "$as_me:6831: found $ac_dir/$ac_word" >&5
6839 NCURSES_CONFIG=$ac_cv_path_NCURSES_CONFIG
6841 if test -n "$NCURSES_CONFIG"; then
6842 echo "$as_me:6842: result: $NCURSES_CONFIG" >&5
6843 echo "${ECHO_T}$NCURSES_CONFIG" >&6
6845 echo "$as_me:6845: result: no" >&5
6846 echo "${ECHO_T}no" >&6
6849 test -n "$NCURSES_CONFIG" && break
6851 test -n "$NCURSES_CONFIG" || NCURSES_CONFIG="none"
6853 if test "$NCURSES_CONFIG" != none ; then
6855 CPPFLAGS="$CPPFLAGS `$NCURSES_CONFIG --cflags`"
6856 LIBS="`$NCURSES_CONFIG --libs` $LIBS"
6858 # even with config script, some packages use no-override for curses.h
6860 echo "$as_me:6860: checking if we have identified curses headers" >&5
6861 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
6862 if test "${cf_cv_ncurses_header+set}" = set; then
6863 echo $ECHO_N "(cached) $ECHO_C" >&6
6866 cf_cv_ncurses_header=none
6869 ncursesw/ncurses.h \
6873 cat >conftest.$ac_ext <<_ACEOF
6874 #line 6874 "configure"
6875 #include "confdefs.h"
6876 #include <${cf_header}>
6880 initscr(); tgoto("?", 0,0)
6885 rm -f conftest.$ac_objext
6886 if { (eval echo "$as_me:6886: \"$ac_compile\"") >&5
6887 (eval $ac_compile) 2>&5
6889 echo "$as_me:6889: \$? = $ac_status" >&5
6890 (exit $ac_status); } &&
6891 { ac_try='test -s conftest.$ac_objext'
6892 { (eval echo "$as_me:6892: \"$ac_try\"") >&5
6895 echo "$as_me:6895: \$? = $ac_status" >&5
6896 (exit $ac_status); }; }; then
6897 cf_cv_ncurses_header=$cf_header; break
6899 echo "$as_me: failed program was:" >&5
6900 cat conftest.$ac_ext >&5
6902 rm -f conftest.$ac_objext conftest.$ac_ext
6906 echo "$as_me:6906: result: $cf_cv_ncurses_header" >&5
6907 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
6909 if test "$cf_cv_ncurses_header" = none ; then
6910 { { echo "$as_me:6910: error: No curses header-files found" >&5
6911 echo "$as_me: error: No curses header-files found" >&2;}
6912 { (exit 1); exit 1; }; }
6915 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
6917 for ac_header in $cf_cv_ncurses_header
6919 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6920 echo "$as_me:6920: checking for $ac_header" >&5
6921 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6922 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6923 echo $ECHO_N "(cached) $ECHO_C" >&6
6925 cat >conftest.$ac_ext <<_ACEOF
6926 #line 6926 "configure"
6927 #include "confdefs.h"
6928 #include <$ac_header>
6930 if { (eval echo "$as_me:6930: \"$ac_cpp conftest.$ac_ext\"") >&5
6931 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6933 egrep -v '^ *\+' conftest.er1 >conftest.err
6935 cat conftest.err >&5
6936 echo "$as_me:6936: \$? = $ac_status" >&5
6937 (exit $ac_status); } >/dev/null; then
6938 if test -s conftest.err; then
6939 ac_cpp_err=$ac_c_preproc_warn_flag
6946 if test -z "$ac_cpp_err"; then
6947 eval "$as_ac_Header=yes"
6949 echo "$as_me: failed program was:" >&5
6950 cat conftest.$ac_ext >&5
6951 eval "$as_ac_Header=no"
6953 rm -f conftest.err conftest.$ac_ext
6955 echo "$as_me:6955: result: `eval echo '${'$as_ac_Header'}'`" >&5
6956 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6957 if test `eval echo '${'$as_ac_Header'}'` = yes; then
6958 cat >>confdefs.h <<EOF
6959 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6965 cat >>confdefs.h <<\EOF
6969 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
6971 cat >>confdefs.h <<EOF
6972 #define $cf_nculib_ROOT 1
6975 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
6979 cf_ncuhdr_root=ncursesw
6981 test -n "$cf_cv_curses_dir" && \
6982 test "$cf_cv_curses_dir" != "no" && { \
6984 if test -n "$cf_cv_curses_dir/include $cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
6985 for cf_add_incdir in $cf_cv_curses_dir/include $cf_cv_curses_dir/include/$cf_ncuhdr_root
6987 while test $cf_add_incdir != /usr/include
6989 if test -d $cf_add_incdir
6992 if test -n "$CFLAGS$CPPFLAGS" ; then
6993 # a loop is needed to ensure we can add subdirs of existing dirs
6994 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
6995 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
6996 cf_have_incdir=yes; break
7001 if test "$cf_have_incdir" = no ; then
7002 if test "$cf_add_incdir" = /usr/local/include ; then
7003 if test "$GCC" = yes
7005 cf_save_CPPFLAGS=$CPPFLAGS
7006 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7007 cat >conftest.$ac_ext <<_ACEOF
7008 #line 7008 "configure"
7009 #include "confdefs.h"
7019 rm -f conftest.$ac_objext
7020 if { (eval echo "$as_me:7020: \"$ac_compile\"") >&5
7021 (eval $ac_compile) 2>&5
7023 echo "$as_me:7023: \$? = $ac_status" >&5
7024 (exit $ac_status); } &&
7025 { ac_try='test -s conftest.$ac_objext'
7026 { (eval echo "$as_me:7026: \"$ac_try\"") >&5
7029 echo "$as_me:7029: \$? = $ac_status" >&5
7030 (exit $ac_status); }; }; then
7033 echo "$as_me: failed program was:" >&5
7034 cat conftest.$ac_ext >&5
7037 rm -f conftest.$ac_objext conftest.$ac_ext
7038 CPPFLAGS=$cf_save_CPPFLAGS
7043 if test "$cf_have_incdir" = no ; then
7044 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
7046 echo "${as_me:-configure}:7046: testing adding $cf_add_incdir to include-path ..." 1>&5
7048 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7050 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
7051 test "$cf_top_incdir" = "$cf_add_incdir" && break
7052 cf_add_incdir="$cf_top_incdir"
7063 echo "$as_me:7063: checking for $cf_ncuhdr_root header in include-path" >&5
7064 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
7065 if test "${cf_cv_ncurses_h+set}" = set; then
7066 echo $ECHO_N "(cached) $ECHO_C" >&6
7069 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
7070 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
7071 for cf_header in $cf_header_list
7074 cat >conftest.$ac_ext <<_ACEOF
7075 #line 7075 "configure"
7076 #include "confdefs.h"
7078 #define _XOPEN_SOURCE_EXTENDED
7079 #undef HAVE_LIBUTF8_H /* in case we used CF_UTF8_LIB */
7080 #define HAVE_LIBUTF8_H /* to force ncurses' header file to use cchar_t */
7082 #include <$cf_header>
7087 #ifdef NCURSES_VERSION
7093 printf("%s\n", NCURSES_VERSION);
7106 rm -f conftest.$ac_objext
7107 if { (eval echo "$as_me:7107: \"$ac_compile\"") >&5
7108 (eval $ac_compile) 2>&5
7110 echo "$as_me:7110: \$? = $ac_status" >&5
7111 (exit $ac_status); } &&
7112 { ac_try='test -s conftest.$ac_objext'
7113 { (eval echo "$as_me:7113: \"$ac_try\"") >&5
7116 echo "$as_me:7116: \$? = $ac_status" >&5
7117 (exit $ac_status); }; }; then
7118 cf_cv_ncurses_h=$cf_header
7121 echo "$as_me: failed program was:" >&5
7122 cat conftest.$ac_ext >&5
7125 rm -f conftest.$ac_objext conftest.$ac_ext
7127 test "$cf_cv_ncurses_h" != no && break
7131 echo "$as_me:7131: result: $cf_cv_ncurses_h" >&5
7132 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
7134 if test "$cf_cv_ncurses_h" != no ; then
7135 cf_cv_ncurses_header=$cf_cv_ncurses_h
7138 echo "$as_me:7138: checking for $cf_ncuhdr_root include-path" >&5
7139 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
7140 if test "${cf_cv_ncurses_h2+set}" = set; then
7141 echo $ECHO_N "(cached) $ECHO_C" >&6
7144 test -n "$verbose" && echo
7148 # collect the current set of include-directories from compiler flags
7149 cf_header_path_list=""
7150 if test -n "${CFLAGS}${CPPFLAGS}" ; then
7151 for cf_header_path in $CPPFLAGS $CFLAGS
7153 case $cf_header_path in #(vi
7155 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
7157 test "$cf_header_path" != "NONE" && \
7158 test -d "$cf_header_path" && \
7160 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
7161 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
7162 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
7163 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
7164 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
7165 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"
7168 cf_header_path_list="$cf_header_path_list $cf_search"
7174 # add the variations for the package we are looking for
7178 test "/usr" != "$prefix" && \
7180 (test $prefix = NONE || test "/usr" != "$prefix") && {
7181 test -n "$verbose" && echo " ... testing for include-directories under /usr"
7182 test -d /usr/include && cf_search="$cf_search /usr/include"
7183 test -d /usr/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/include/$cf_ncuhdr_root"
7184 test -d /usr/include/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/include/$cf_ncuhdr_root/include"
7185 test -d /usr/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/$cf_ncuhdr_root/include"
7186 test -d /usr/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
7189 test "$prefix" != "NONE" && \
7190 test -d "$prefix" && \
7192 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
7193 test -d $prefix/include && cf_search="$cf_search $prefix/include"
7194 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
7195 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
7196 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
7197 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
7200 test "/usr/local" != "$prefix" && \
7201 test -d "/usr/local" && \
7202 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
7203 test -n "$verbose" && echo " ... testing for include-directories under /usr/local"
7204 test -d /usr/local/include && cf_search="$cf_search /usr/local/include"
7205 test -d /usr/local/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/local/include/$cf_ncuhdr_root"
7206 test -d /usr/local/include/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/local/include/$cf_ncuhdr_root/include"
7207 test -d /usr/local/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/local/$cf_ncuhdr_root/include"
7208 test -d /usr/local/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/local/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
7211 test "/opt" != "$prefix" && \
7213 (test $prefix = NONE || test "/opt" != "$prefix") && {
7214 test -n "$verbose" && echo " ... testing for include-directories under /opt"
7215 test -d /opt/include && cf_search="$cf_search /opt/include"
7216 test -d /opt/include/$cf_ncuhdr_root && cf_search="$cf_search /opt/include/$cf_ncuhdr_root"
7217 test -d /opt/include/$cf_ncuhdr_root/include && cf_search="$cf_search /opt/include/$cf_ncuhdr_root/include"
7218 test -d /opt/$cf_ncuhdr_root/include && cf_search="$cf_search /opt/$cf_ncuhdr_root/include"
7219 test -d /opt/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /opt/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
7222 test "$HOME" != "$prefix" && \
7223 test -d "$HOME" && \
7224 (test $prefix = NONE || test "$HOME" != "$prefix") && {
7225 test -n "$verbose" && echo " ... testing for include-directories under $HOME"
7226 test -d $HOME/include && cf_search="$cf_search $HOME/include"
7227 test -d $HOME/include/$cf_ncuhdr_root && cf_search="$cf_search $HOME/include/$cf_ncuhdr_root"
7228 test -d $HOME/include/$cf_ncuhdr_root/include && cf_search="$cf_search $HOME/include/$cf_ncuhdr_root/include"
7229 test -d $HOME/$cf_ncuhdr_root/include && cf_search="$cf_search $HOME/$cf_ncuhdr_root/include"
7230 test -d $HOME/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $HOME/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
7233 test "$includedir" != NONE && \
7234 test "$includedir" != "/usr/include" && \
7235 test -d "$includedir" && {
7236 test -d $includedir && cf_search="$cf_search $includedir"
7237 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
7240 test "$oldincludedir" != NONE && \
7241 test "$oldincludedir" != "/usr/include" && \
7242 test -d "$oldincludedir" && {
7243 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
7244 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
7247 cf_search="$cf_search $cf_header_path_list"
7249 test -n "$verbose" && echo search path $cf_search
7250 cf_save2_CPPFLAGS="$CPPFLAGS"
7251 for cf_incdir in $cf_search
7254 if test -n "$cf_incdir" ; then
7255 for cf_add_incdir in $cf_incdir
7257 while test $cf_add_incdir != /usr/include
7259 if test -d $cf_add_incdir
7262 if test -n "$CFLAGS$CPPFLAGS" ; then
7263 # a loop is needed to ensure we can add subdirs of existing dirs
7264 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
7265 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
7266 cf_have_incdir=yes; break
7271 if test "$cf_have_incdir" = no ; then
7272 if test "$cf_add_incdir" = /usr/local/include ; then
7273 if test "$GCC" = yes
7275 cf_save_CPPFLAGS=$CPPFLAGS
7276 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7277 cat >conftest.$ac_ext <<_ACEOF
7278 #line 7278 "configure"
7279 #include "confdefs.h"
7289 rm -f conftest.$ac_objext
7290 if { (eval echo "$as_me:7290: \"$ac_compile\"") >&5
7291 (eval $ac_compile) 2>&5
7293 echo "$as_me:7293: \$? = $ac_status" >&5
7294 (exit $ac_status); } &&
7295 { ac_try='test -s conftest.$ac_objext'
7296 { (eval echo "$as_me:7296: \"$ac_try\"") >&5
7299 echo "$as_me:7299: \$? = $ac_status" >&5
7300 (exit $ac_status); }; }; then
7303 echo "$as_me: failed program was:" >&5
7304 cat conftest.$ac_ext >&5
7307 rm -f conftest.$ac_objext conftest.$ac_ext
7308 CPPFLAGS=$cf_save_CPPFLAGS
7313 if test "$cf_have_incdir" = no ; then
7314 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
7316 echo "${as_me:-configure}:7316: testing adding $cf_add_incdir to include-path ..." 1>&5
7318 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7320 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
7321 test "$cf_top_incdir" = "$cf_add_incdir" && break
7322 cf_add_incdir="$cf_top_incdir"
7336 cat >conftest.$ac_ext <<_ACEOF
7337 #line 7337 "configure"
7338 #include "confdefs.h"
7340 #include <$cf_header>
7345 #ifdef NCURSES_VERSION
7347 printf("%s\n", NCURSES_VERSION);
7360 rm -f conftest.$ac_objext
7361 if { (eval echo "$as_me:7361: \"$ac_compile\"") >&5
7362 (eval $ac_compile) 2>&5
7364 echo "$as_me:7364: \$? = $ac_status" >&5
7365 (exit $ac_status); } &&
7366 { ac_try='test -s conftest.$ac_objext'
7367 { (eval echo "$as_me:7367: \"$ac_try\"") >&5
7370 echo "$as_me:7370: \$? = $ac_status" >&5
7371 (exit $ac_status); }; }; then
7372 cf_cv_ncurses_h2=$cf_header
7375 echo "$as_me: failed program was:" >&5
7376 cat conftest.$ac_ext >&5
7379 rm -f conftest.$ac_objext conftest.$ac_ext
7381 if test "$cf_cv_ncurses_h2" != no ; then
7382 cf_cv_ncurses_h2=$cf_incdir/$cf_header
7383 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
7386 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
7388 CPPFLAGS="$cf_save2_CPPFLAGS"
7389 test "$cf_cv_ncurses_h2" != no && break
7391 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:7391: error: not found" >&5
7392 echo "$as_me: error: not found" >&2;}
7393 { (exit 1); exit 1; }; }
7396 echo "$as_me:7396: result: $cf_cv_ncurses_h2" >&5
7397 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
7399 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
7400 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
7401 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
7402 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
7405 if test -n "$cf_1st_incdir" ; then
7406 for cf_add_incdir in $cf_1st_incdir
7408 while test $cf_add_incdir != /usr/include
7410 if test -d $cf_add_incdir
7413 if test -n "$CFLAGS$CPPFLAGS" ; then
7414 # a loop is needed to ensure we can add subdirs of existing dirs
7415 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
7416 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
7417 cf_have_incdir=yes; break
7422 if test "$cf_have_incdir" = no ; then
7423 if test "$cf_add_incdir" = /usr/local/include ; then
7424 if test "$GCC" = yes
7426 cf_save_CPPFLAGS=$CPPFLAGS
7427 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7428 cat >conftest.$ac_ext <<_ACEOF
7429 #line 7429 "configure"
7430 #include "confdefs.h"
7440 rm -f conftest.$ac_objext
7441 if { (eval echo "$as_me:7441: \"$ac_compile\"") >&5
7442 (eval $ac_compile) 2>&5
7444 echo "$as_me:7444: \$? = $ac_status" >&5
7445 (exit $ac_status); } &&
7446 { ac_try='test -s conftest.$ac_objext'
7447 { (eval echo "$as_me:7447: \"$ac_try\"") >&5
7450 echo "$as_me:7450: \$? = $ac_status" >&5
7451 (exit $ac_status); }; }; then
7454 echo "$as_me: failed program was:" >&5
7455 cat conftest.$ac_ext >&5
7458 rm -f conftest.$ac_objext conftest.$ac_ext
7459 CPPFLAGS=$cf_save_CPPFLAGS
7464 if test "$cf_have_incdir" = no ; then
7465 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
7467 echo "${as_me:-configure}:7467: testing adding $cf_add_incdir to include-path ..." 1>&5
7469 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7471 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
7472 test "$cf_top_incdir" = "$cf_add_incdir" && break
7473 cf_add_incdir="$cf_top_incdir"
7484 # Set definitions to allow ifdef'ing for ncurses.h
7486 case $cf_cv_ncurses_header in # (vi
7488 cat >>confdefs.h <<\EOF
7489 #define HAVE_NCURSES_H 1
7495 case $cf_cv_ncurses_header in # (vi
7496 ncurses/curses.h|ncurses/ncurses.h)
7497 cat >>confdefs.h <<\EOF
7498 #define HAVE_NCURSES_NCURSES_H 1
7502 ncursesw/curses.h|ncursesw/ncurses.h)
7503 cat >>confdefs.h <<\EOF
7504 #define HAVE_NCURSESW_NCURSES_H 1
7510 echo "$as_me:7510: checking for terminfo header" >&5
7511 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
7512 if test "${cf_cv_term_header+set}" = set; then
7513 echo $ECHO_N "(cached) $ECHO_C" >&6
7516 case ${cf_cv_ncurses_header} in #(vi
7517 */ncurses.h|*/ncursesw.h) #(vi
7518 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
7521 cf_term_header=term.h
7525 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
7527 cat >conftest.$ac_ext <<_ACEOF
7528 #line 7528 "configure"
7529 #include "confdefs.h"
7531 #include <${cf_cv_ncurses_header:-curses.h}>
7537 int x = auto_left_margin
7542 rm -f conftest.$ac_objext
7543 if { (eval echo "$as_me:7543: \"$ac_compile\"") >&5
7544 (eval $ac_compile) 2>&5
7546 echo "$as_me:7546: \$? = $ac_status" >&5
7547 (exit $ac_status); } &&
7548 { ac_try='test -s conftest.$ac_objext'
7549 { (eval echo "$as_me:7549: \"$ac_try\"") >&5
7552 echo "$as_me:7552: \$? = $ac_status" >&5
7553 (exit $ac_status); }; }; then
7555 cf_cv_term_header="$cf_test"
7557 echo "$as_me: failed program was:" >&5
7558 cat conftest.$ac_ext >&5
7560 cf_cv_term_header=unknown
7563 rm -f conftest.$ac_objext conftest.$ac_ext
7564 test "$cf_cv_term_header" != unknown && break
7568 echo "$as_me:7568: result: $cf_cv_term_header" >&5
7569 echo "${ECHO_T}$cf_cv_term_header" >&6
7571 # Set definitions to allow ifdef'ing to accommodate subdirectories
7573 case $cf_cv_term_header in # (vi
7575 cat >>confdefs.h <<\EOF
7576 #define HAVE_TERM_H 1
7582 case $cf_cv_term_header in # (vi
7583 ncurses/term.h) #(vi
7584 cat >>confdefs.h <<\EOF
7585 #define HAVE_NCURSES_TERM_H 1
7590 cat >>confdefs.h <<\EOF
7591 #define HAVE_NCURSESW_TERM_H 1
7597 # some applications need this, but should check for NCURSES_VERSION
7598 cat >>confdefs.h <<\EOF
7602 echo "$as_me:7602: checking for ncurses version" >&5
7603 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
7604 if test "${cf_cv_ncurses_version+set}" = set; then
7605 echo $ECHO_N "(cached) $ECHO_C" >&6
7608 cf_cv_ncurses_version=no
7611 if test "$cross_compiling" = yes; then
7613 # This will not work if the preprocessor splits the line after the
7614 # Autoconf token. The 'unproto' program does that.
7615 cat > conftest.$ac_ext <<EOF
7616 #include <${cf_cv_ncurses_header:-curses.h}>
7618 #ifdef NCURSES_VERSION
7619 Autoconf NCURSES_VERSION
7627 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
7628 { (eval echo "$as_me:7628: \"$cf_try\"") >&5
7631 echo "$as_me:7631: \$? = $ac_status" >&5
7632 (exit $ac_status); }
7633 if test -f conftest.out ; then
7634 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
7635 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
7640 cat >conftest.$ac_ext <<_ACEOF
7641 #line 7641 "configure"
7642 #include "confdefs.h"
7644 #include <${cf_cv_ncurses_header:-curses.h}>
7648 FILE *fp = fopen("$cf_tempfile", "w");
7649 #ifdef NCURSES_VERSION
7650 # ifdef NCURSES_VERSION_PATCH
7651 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
7653 fprintf(fp, "%s\n", NCURSES_VERSION);
7657 fprintf(fp, "old\n");
7662 ${cf_cv_main_return:-return}(0);
7665 rm -f conftest$ac_exeext
7666 if { (eval echo "$as_me:7666: \"$ac_link\"") >&5
7667 (eval $ac_link) 2>&5
7669 echo "$as_me:7669: \$? = $ac_status" >&5
7670 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
7671 { (eval echo "$as_me:7671: \"$ac_try\"") >&5
7674 echo "$as_me:7674: \$? = $ac_status" >&5
7675 (exit $ac_status); }; }; then
7677 cf_cv_ncurses_version=`cat $cf_tempfile`
7679 echo "$as_me: program exited with status $ac_status" >&5
7680 echo "$as_me: failed program was:" >&5
7681 cat conftest.$ac_ext >&5
7683 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
7688 echo "$as_me:7688: result: $cf_cv_ncurses_version" >&5
7689 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
7690 test "$cf_cv_ncurses_version" = no || cat >>confdefs.h <<\EOF
7694 cf_nculib_root=ncursesw
7695 # This works, except for the special case where we find gpm, but
7696 # ncurses is in a nonstandard location via $LIBS, and we really want
7699 cf_ncurses_SAVE="$LIBS"
7700 echo "$as_me:7700: checking for Gpm_Open in -lgpm" >&5
7701 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
7702 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
7703 echo $ECHO_N "(cached) $ECHO_C" >&6
7705 ac_check_lib_save_LIBS=$LIBS
7707 cat >conftest.$ac_ext <<_ACEOF
7708 #line 7708 "configure"
7709 #include "confdefs.h"
7711 /* Override any gcc2 internal prototype to avoid an error. */
7715 /* We use char because int might match the return type of a gcc2
7716 builtin and then its argument prototype would still apply. */
7726 rm -f conftest.$ac_objext conftest$ac_exeext
7727 if { (eval echo "$as_me:7727: \"$ac_link\"") >&5
7728 (eval $ac_link) 2>&5
7730 echo "$as_me:7730: \$? = $ac_status" >&5
7731 (exit $ac_status); } &&
7732 { ac_try='test -s conftest$ac_exeext'
7733 { (eval echo "$as_me:7733: \"$ac_try\"") >&5
7736 echo "$as_me:7736: \$? = $ac_status" >&5
7737 (exit $ac_status); }; }; then
7738 ac_cv_lib_gpm_Gpm_Open=yes
7740 echo "$as_me: failed program was:" >&5
7741 cat conftest.$ac_ext >&5
7742 ac_cv_lib_gpm_Gpm_Open=no
7744 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7745 LIBS=$ac_check_lib_save_LIBS
7747 echo "$as_me:7747: result: $ac_cv_lib_gpm_Gpm_Open" >&5
7748 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
7749 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
7750 echo "$as_me:7750: checking for initscr in -lgpm" >&5
7751 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
7752 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
7753 echo $ECHO_N "(cached) $ECHO_C" >&6
7755 ac_check_lib_save_LIBS=$LIBS
7757 cat >conftest.$ac_ext <<_ACEOF
7758 #line 7758 "configure"
7759 #include "confdefs.h"
7761 /* Override any gcc2 internal prototype to avoid an error. */
7765 /* We use char because int might match the return type of a gcc2
7766 builtin and then its argument prototype would still apply. */
7776 rm -f conftest.$ac_objext conftest$ac_exeext
7777 if { (eval echo "$as_me:7777: \"$ac_link\"") >&5
7778 (eval $ac_link) 2>&5
7780 echo "$as_me:7780: \$? = $ac_status" >&5
7781 (exit $ac_status); } &&
7782 { ac_try='test -s conftest$ac_exeext'
7783 { (eval echo "$as_me:7783: \"$ac_try\"") >&5
7786 echo "$as_me:7786: \$? = $ac_status" >&5
7787 (exit $ac_status); }; }; then
7788 ac_cv_lib_gpm_initscr=yes
7790 echo "$as_me: failed program was:" >&5
7791 cat conftest.$ac_ext >&5
7792 ac_cv_lib_gpm_initscr=no
7794 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7795 LIBS=$ac_check_lib_save_LIBS
7797 echo "$as_me:7797: result: $ac_cv_lib_gpm_initscr" >&5
7798 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
7799 if test $ac_cv_lib_gpm_initscr = yes; then
7800 LIBS="$cf_ncurses_SAVE"
7802 cf_ncurses_LIBS="-lgpm"
7807 case $host_os in #(vi
7809 # This is only necessary if you are linking against an obsolete
7810 # version of ncurses (but it should do no harm, since it's static).
7811 if test "$cf_nculib_root" = ncurses ; then
7812 echo "$as_me:7812: checking for tgoto in -lmytinfo" >&5
7813 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
7814 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
7815 echo $ECHO_N "(cached) $ECHO_C" >&6
7817 ac_check_lib_save_LIBS=$LIBS
7818 LIBS="-lmytinfo $LIBS"
7819 cat >conftest.$ac_ext <<_ACEOF
7820 #line 7820 "configure"
7821 #include "confdefs.h"
7823 /* Override any gcc2 internal prototype to avoid an error. */
7827 /* We use char because int might match the return type of a gcc2
7828 builtin and then its argument prototype would still apply. */
7838 rm -f conftest.$ac_objext conftest$ac_exeext
7839 if { (eval echo "$as_me:7839: \"$ac_link\"") >&5
7840 (eval $ac_link) 2>&5
7842 echo "$as_me:7842: \$? = $ac_status" >&5
7843 (exit $ac_status); } &&
7844 { ac_try='test -s conftest$ac_exeext'
7845 { (eval echo "$as_me:7845: \"$ac_try\"") >&5
7848 echo "$as_me:7848: \$? = $ac_status" >&5
7849 (exit $ac_status); }; }; then
7850 ac_cv_lib_mytinfo_tgoto=yes
7852 echo "$as_me: failed program was:" >&5
7853 cat conftest.$ac_ext >&5
7854 ac_cv_lib_mytinfo_tgoto=no
7856 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7857 LIBS=$ac_check_lib_save_LIBS
7859 echo "$as_me:7859: result: $ac_cv_lib_mytinfo_tgoto" >&5
7860 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
7861 if test $ac_cv_lib_mytinfo_tgoto = yes; then
7862 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
7869 LIBS="$cf_ncurses_LIBS $LIBS"
7871 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
7874 if test -n "$cf_cv_curses_dir/lib" ; then
7875 for cf_add_libdir in $cf_cv_curses_dir/lib
7877 if test $cf_add_libdir = /usr/lib ; then
7879 elif test -d $cf_add_libdir
7882 if test -n "$LDFLAGS$LIBS" ; then
7883 # a loop is needed to ensure we can add subdirs of existing dirs
7884 for cf_test_libdir in $LDFLAGS $LIBS ; do
7885 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
7886 cf_have_libdir=yes; break
7890 if test "$cf_have_libdir" = no ; then
7891 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
7893 echo "${as_me:-configure}:7893: testing adding $cf_add_libdir to library-path ..." 1>&5
7895 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
7901 LIBS="-l$cf_nculib_root $LIBS"
7904 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
7906 echo "$as_me:7906: checking for initscr" >&5
7907 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
7908 if test "${ac_cv_func_initscr+set}" = set; then
7909 echo $ECHO_N "(cached) $ECHO_C" >&6
7911 cat >conftest.$ac_ext <<_ACEOF
7912 #line 7912 "configure"
7913 #include "confdefs.h"
7914 /* System header to define __stub macros and hopefully few prototypes,
7915 which can conflict with char initscr (); below. */
7917 /* Override any gcc2 internal prototype to avoid an error. */
7921 /* We use char because int might match the return type of a gcc2
7922 builtin and then its argument prototype would still apply. */
7929 /* The GNU C library defines this for functions which it implements
7930 to always fail with ENOSYS. Some functions are actually named
7931 something starting with __ and the normal name is an alias. */
7932 #if defined (__stub_initscr) || defined (__stub___initscr)
7942 rm -f conftest.$ac_objext conftest$ac_exeext
7943 if { (eval echo "$as_me:7943: \"$ac_link\"") >&5
7944 (eval $ac_link) 2>&5
7946 echo "$as_me:7946: \$? = $ac_status" >&5
7947 (exit $ac_status); } &&
7948 { ac_try='test -s conftest$ac_exeext'
7949 { (eval echo "$as_me:7949: \"$ac_try\"") >&5
7952 echo "$as_me:7952: \$? = $ac_status" >&5
7953 (exit $ac_status); }; }; then
7954 ac_cv_func_initscr=yes
7956 echo "$as_me: failed program was:" >&5
7957 cat conftest.$ac_ext >&5
7958 ac_cv_func_initscr=no
7960 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7962 echo "$as_me:7962: result: $ac_cv_func_initscr" >&5
7963 echo "${ECHO_T}$ac_cv_func_initscr" >&6
7964 if test $ac_cv_func_initscr = yes; then
7965 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
7968 cf_save_LIBS="$LIBS"
7969 echo "$as_me:7969: checking for initscr in -l$cf_nculib_root" >&5
7970 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
7971 LIBS="-l$cf_nculib_root $LIBS"
7972 cat >conftest.$ac_ext <<_ACEOF
7973 #line 7973 "configure"
7974 #include "confdefs.h"
7975 #include <${cf_cv_ncurses_header:-curses.h}>
7984 rm -f conftest.$ac_objext conftest$ac_exeext
7985 if { (eval echo "$as_me:7985: \"$ac_link\"") >&5
7986 (eval $ac_link) 2>&5
7988 echo "$as_me:7988: \$? = $ac_status" >&5
7989 (exit $ac_status); } &&
7990 { ac_try='test -s conftest$ac_exeext'
7991 { (eval echo "$as_me:7991: \"$ac_try\"") >&5
7994 echo "$as_me:7994: \$? = $ac_status" >&5
7995 (exit $ac_status); }; }; then
7996 echo "$as_me:7996: result: yes" >&5
7997 echo "${ECHO_T}yes" >&6
7998 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
8001 echo "$as_me: failed program was:" >&5
8002 cat conftest.$ac_ext >&5
8003 echo "$as_me:8003: result: no" >&5
8004 echo "${ECHO_T}no" >&6
8007 cf_library_path_list=""
8008 if test -n "${LDFLAGS}${LIBS}" ; then
8009 for cf_library_path in $LDFLAGS $LIBS
8011 case $cf_library_path in #(vi
8013 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
8015 test "$cf_library_path" != "NONE" && \
8016 test -d "$cf_library_path" && \
8018 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
8019 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
8020 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
8021 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
8022 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
8023 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"
8026 cf_library_path_list="$cf_library_path_list $cf_search"
8034 test "/usr" != "$prefix" && \
8036 (test $prefix = NONE || test "/usr" != "$prefix") && {
8037 test -n "$verbose" && echo " ... testing for lib-directories under /usr"
8038 test -d /usr/lib && cf_search="$cf_search /usr/lib"
8039 test -d /usr/lib/$cf_nculib_root && cf_search="$cf_search /usr/lib/$cf_nculib_root"
8040 test -d /usr/lib/$cf_nculib_root/lib && cf_search="$cf_search /usr/lib/$cf_nculib_root/lib"
8041 test -d /usr/$cf_nculib_root/lib && cf_search="$cf_search /usr/$cf_nculib_root/lib"
8042 test -d /usr/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /usr/$cf_nculib_root/lib/$cf_nculib_root"
8045 test "$prefix" != "NONE" && \
8046 test -d "$prefix" && \
8048 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
8049 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
8050 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
8051 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
8052 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
8053 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
8056 test "/usr/local" != "$prefix" && \
8057 test -d "/usr/local" && \
8058 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
8059 test -n "$verbose" && echo " ... testing for lib-directories under /usr/local"
8060 test -d /usr/local/lib && cf_search="$cf_search /usr/local/lib"
8061 test -d /usr/local/lib/$cf_nculib_root && cf_search="$cf_search /usr/local/lib/$cf_nculib_root"
8062 test -d /usr/local/lib/$cf_nculib_root/lib && cf_search="$cf_search /usr/local/lib/$cf_nculib_root/lib"
8063 test -d /usr/local/$cf_nculib_root/lib && cf_search="$cf_search /usr/local/$cf_nculib_root/lib"
8064 test -d /usr/local/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /usr/local/$cf_nculib_root/lib/$cf_nculib_root"
8067 test "/opt" != "$prefix" && \
8069 (test $prefix = NONE || test "/opt" != "$prefix") && {
8070 test -n "$verbose" && echo " ... testing for lib-directories under /opt"
8071 test -d /opt/lib && cf_search="$cf_search /opt/lib"
8072 test -d /opt/lib/$cf_nculib_root && cf_search="$cf_search /opt/lib/$cf_nculib_root"
8073 test -d /opt/lib/$cf_nculib_root/lib && cf_search="$cf_search /opt/lib/$cf_nculib_root/lib"
8074 test -d /opt/$cf_nculib_root/lib && cf_search="$cf_search /opt/$cf_nculib_root/lib"
8075 test -d /opt/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /opt/$cf_nculib_root/lib/$cf_nculib_root"
8078 test "$HOME" != "$prefix" && \
8079 test -d "$HOME" && \
8080 (test $prefix = NONE || test "$HOME" != "$prefix") && {
8081 test -n "$verbose" && echo " ... testing for lib-directories under $HOME"
8082 test -d $HOME/lib && cf_search="$cf_search $HOME/lib"
8083 test -d $HOME/lib/$cf_nculib_root && cf_search="$cf_search $HOME/lib/$cf_nculib_root"
8084 test -d $HOME/lib/$cf_nculib_root/lib && cf_search="$cf_search $HOME/lib/$cf_nculib_root/lib"
8085 test -d $HOME/$cf_nculib_root/lib && cf_search="$cf_search $HOME/$cf_nculib_root/lib"
8086 test -d $HOME/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $HOME/$cf_nculib_root/lib/$cf_nculib_root"
8089 cf_search="$cf_library_path_list $cf_search"
8091 for cf_libdir in $cf_search
8093 echo "$as_me:8093: checking for -l$cf_nculib_root in $cf_libdir" >&5
8094 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
8095 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
8096 cat >conftest.$ac_ext <<_ACEOF
8097 #line 8097 "configure"
8098 #include "confdefs.h"
8099 #include <${cf_cv_ncurses_header:-curses.h}>
8108 rm -f conftest.$ac_objext conftest$ac_exeext
8109 if { (eval echo "$as_me:8109: \"$ac_link\"") >&5
8110 (eval $ac_link) 2>&5
8112 echo "$as_me:8112: \$? = $ac_status" >&5
8113 (exit $ac_status); } &&
8114 { ac_try='test -s conftest$ac_exeext'
8115 { (eval echo "$as_me:8115: \"$ac_try\"") >&5
8118 echo "$as_me:8118: \$? = $ac_status" >&5
8119 (exit $ac_status); }; }; then
8120 echo "$as_me:8120: result: yes" >&5
8121 echo "${ECHO_T}yes" >&6
8122 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
8125 echo "$as_me: failed program was:" >&5
8126 cat conftest.$ac_ext >&5
8127 echo "$as_me:8127: result: no" >&5
8128 echo "${ECHO_T}no" >&6
8129 LIBS="$cf_save_LIBS"
8131 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8135 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8139 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
8141 if test $cf_found_library = no ; then
8142 { { echo "$as_me:8142: error: Cannot link $cf_nculib_root library" >&5
8143 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
8144 { (exit 1); exit 1; }; }
8149 if test -n "$cf_ncurses_LIBS" ; then
8150 echo "$as_me:8150: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
8151 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
8152 cf_ncurses_SAVE="$LIBS"
8153 for p in $cf_ncurses_LIBS ; do
8154 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
8155 if test "$q" != "$LIBS" ; then
8159 cat >conftest.$ac_ext <<_ACEOF
8160 #line 8160 "configure"
8161 #include "confdefs.h"
8162 #include <${cf_cv_ncurses_header:-curses.h}>
8166 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
8171 rm -f conftest.$ac_objext conftest$ac_exeext
8172 if { (eval echo "$as_me:8172: \"$ac_link\"") >&5
8173 (eval $ac_link) 2>&5
8175 echo "$as_me:8175: \$? = $ac_status" >&5
8176 (exit $ac_status); } &&
8177 { ac_try='test -s conftest$ac_exeext'
8178 { (eval echo "$as_me:8178: \"$ac_try\"") >&5
8181 echo "$as_me:8181: \$? = $ac_status" >&5
8182 (exit $ac_status); }; }; then
8183 echo "$as_me:8183: result: yes" >&5
8184 echo "${ECHO_T}yes" >&6
8186 echo "$as_me: failed program was:" >&5
8187 cat conftest.$ac_ext >&5
8188 echo "$as_me:8188: result: no" >&5
8189 echo "${ECHO_T}no" >&6
8190 LIBS="$cf_ncurses_SAVE"
8192 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8195 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
8197 cat >>confdefs.h <<EOF
8198 #define $cf_nculib_ROOT 1
8206 echo "$as_me:8206: checking if you want to use pkg-config" >&5
8207 echo $ECHO_N "checking if you want to use pkg-config... $ECHO_C" >&6
8209 # Check whether --with-pkg-config or --without-pkg-config was given.
8210 if test "${with_pkg_config+set}" = set; then
8211 withval="$with_pkg_config"
8212 cf_pkg_config=$withval
8216 echo "$as_me:8216: result: $cf_pkg_config" >&5
8217 echo "${ECHO_T}$cf_pkg_config" >&6
8219 case $cf_pkg_config in #(vi
8224 # Extract the first word of "pkg-config", so it can be a program name with args.
8225 set dummy pkg-config; ac_word=$2
8226 echo "$as_me:8226: checking for $ac_word" >&5
8227 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
8228 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then
8229 echo $ECHO_N "(cached) $ECHO_C" >&6
8233 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
8236 ac_save_IFS=$IFS; IFS=$ac_path_separator
8238 for ac_dir in $ac_dummy; do
8240 test -z "$ac_dir" && ac_dir=.
8241 if $as_executable_p "$ac_dir/$ac_word"; then
8242 ac_cv_path_PKG_CONFIG="$ac_dir/$ac_word"
8243 echo "$as_me:8243: found $ac_dir/$ac_word" >&5
8248 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="none"
8252 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
8254 if test -n "$PKG_CONFIG"; then
8255 echo "$as_me:8255: result: $PKG_CONFIG" >&5
8256 echo "${ECHO_T}$PKG_CONFIG" >&6
8258 echo "$as_me:8258: result: no" >&5
8259 echo "${ECHO_T}no" >&6
8268 test -z "$PKG_CONFIG" && PKG_CONFIG=none
8269 if test "$PKG_CONFIG" != none ; then
8271 if test "x$prefix" != xNONE; then
8272 cf_path_syntax="$prefix"
8274 cf_path_syntax="$ac_default_prefix"
8277 case ".$PKG_CONFIG" in #(vi
8278 .\$\(*\)*|.\'*\'*) #(vi
8282 .[a-zA-Z]:[\\/]*) #(vi OS/2 EMX
8285 eval PKG_CONFIG="$PKG_CONFIG"
8286 case ".$PKG_CONFIG" in #(vi
8288 PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
8293 PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
8296 { { echo "$as_me:8296: error: expected a pathname, not \"$PKG_CONFIG\"" >&5
8297 echo "$as_me: error: expected a pathname, not \"$PKG_CONFIG\"" >&2;}
8298 { (exit 1); exit 1; }; }
8304 echo "$as_me:8304: checking for X" >&5
8305 echo $ECHO_N "checking for X... $ECHO_C" >&6
8307 # Check whether --with-x or --without-x was given.
8308 if test "${with_x+set}" = set; then
8312 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
8313 if test "x$with_x" = xno; then
8314 # The user explicitly disabled X.
8317 if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
8318 # Both variables are already set.
8321 if test "${ac_cv_have_x+set}" = set; then
8322 echo $ECHO_N "(cached) $ECHO_C" >&6
8324 # One or both of the vars are not set, and there is no cached value.
8325 ac_x_includes=no ac_x_libraries=no
8327 if mkdir conftest.dir; then
8329 # Make sure to not put "make" in the Imakefile rules, since we grep it out.
8330 cat >Imakefile <<'EOF'
8332 @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
8334 if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
8335 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
8336 eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
8337 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
8338 for ac_extension in a so sl dylib dll; do
8339 if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
8340 test -f $ac_im_libdir/libX11.$ac_extension; then
8341 ac_im_usrlibdir=$ac_im_libdir; break
8344 # Screen out bogus values from the imake configuration. They are
8345 # bogus both because they are the default anyway, and because
8346 # using them would break gcc on systems where it needs fixed includes.
8347 case $ac_im_incroot in
8349 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
8351 case $ac_im_usrlibdir in
8353 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
8360 # Standard set of common directories for X headers.
8361 # Check X11 before X11Rn because it is often a symlink to the current release.
8373 /usr/local/X11/include
8374 /usr/local/X11R6/include
8375 /usr/local/X11R5/include
8376 /usr/local/X11R4/include
8378 /usr/local/include/X11
8379 /usr/local/include/X11R6
8380 /usr/local/include/X11R5
8381 /usr/local/include/X11R4
8385 /usr/XFree86/include/X11
8389 /usr/unsupported/include
8391 /usr/local/x11r5/include
8392 /usr/lpp/Xamples/include
8394 /usr/openwin/include
8395 /usr/openwin/share/include'
8397 if test "$ac_x_includes" = no; then
8398 # Guess where to find include files, by looking for Intrinsic.h.
8399 # First, try using that file with no special directory specified.
8400 cat >conftest.$ac_ext <<_ACEOF
8401 #line 8401 "configure"
8402 #include "confdefs.h"
8403 #include <X11/Intrinsic.h>
8405 if { (eval echo "$as_me:8405: \"$ac_cpp conftest.$ac_ext\"") >&5
8406 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8408 egrep -v '^ *\+' conftest.er1 >conftest.err
8410 cat conftest.err >&5
8411 echo "$as_me:8411: \$? = $ac_status" >&5
8412 (exit $ac_status); } >/dev/null; then
8413 if test -s conftest.err; then
8414 ac_cpp_err=$ac_c_preproc_warn_flag
8421 if test -z "$ac_cpp_err"; then
8422 # We can compile using X headers with no special include directory.
8425 echo "$as_me: failed program was:" >&5
8426 cat conftest.$ac_ext >&5
8427 for ac_dir in $ac_x_header_dirs; do
8428 if test -r "$ac_dir/X11/Intrinsic.h"; then
8429 ac_x_includes=$ac_dir
8434 rm -f conftest.err conftest.$ac_ext
8435 fi # $ac_x_includes = no
8437 if test "$ac_x_libraries" = no; then
8438 # Check for the libraries.
8439 # See if we find them without any special options.
8440 # Don't add to $LIBS permanently.
8443 cat >conftest.$ac_ext <<_ACEOF
8444 #line 8444 "configure"
8445 #include "confdefs.h"
8446 #include <X11/Intrinsic.h>
8455 rm -f conftest.$ac_objext conftest$ac_exeext
8456 if { (eval echo "$as_me:8456: \"$ac_link\"") >&5
8457 (eval $ac_link) 2>&5
8459 echo "$as_me:8459: \$? = $ac_status" >&5
8460 (exit $ac_status); } &&
8461 { ac_try='test -s conftest$ac_exeext'
8462 { (eval echo "$as_me:8462: \"$ac_try\"") >&5
8465 echo "$as_me:8465: \$? = $ac_status" >&5
8466 (exit $ac_status); }; }; then
8468 # We can link X programs with no special library path.
8471 echo "$as_me: failed program was:" >&5
8472 cat conftest.$ac_ext >&5
8474 for ac_dir in `echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
8476 # Don't even attempt the hair of trying to link an X program!
8477 for ac_extension in a so sl dylib dll; do
8478 if test -r $ac_dir/libXt.$ac_extension; then
8479 ac_x_libraries=$ac_dir
8485 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8486 fi # $ac_x_libraries = no
8488 if test "$ac_x_includes" = no || test "$ac_x_libraries" = no; then
8489 # Didn't find X anywhere. Cache the known absence of X.
8490 ac_cv_have_x="have_x=no"
8492 # Record where we found X for the cache.
8493 ac_cv_have_x="have_x=yes \
8494 ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
8499 eval "$ac_cv_have_x"
8502 if test "$have_x" != yes; then
8503 echo "$as_me:8503: result: $have_x" >&5
8504 echo "${ECHO_T}$have_x" >&6
8507 # If each of the values was on the command line, it overrides each guess.
8508 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
8509 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
8510 # Update the cache value to reflect the command line values.
8511 ac_cv_have_x="have_x=yes \
8512 ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
8513 echo "$as_me:8513: result: libraries $x_libraries, headers $x_includes" >&5
8514 echo "${ECHO_T}libraries $x_libraries, headers $x_includes" >&6
8517 if test "$no_x" = yes; then
8518 # Not all programs may use this symbol, but it does not hurt to define it.
8520 cat >>confdefs.h <<\EOF
8521 #define X_DISPLAY_MISSING 1
8524 X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS=
8526 if test -n "$x_includes"; then
8527 X_CFLAGS="$X_CFLAGS -I$x_includes"
8530 # It would also be nice to do this for all -L options, not just this one.
8531 if test -n "$x_libraries"; then
8532 X_LIBS="$X_LIBS -L$x_libraries"
8533 # For Solaris; some versions of Sun CC require a space after -R and
8534 # others require no space. Words are not sufficient . . . .
8535 case `(uname -sr) 2>/dev/null` in
8537 echo "$as_me:8537: checking whether -R must be followed by a space" >&5
8538 echo $ECHO_N "checking whether -R must be followed by a space... $ECHO_C" >&6
8539 ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries"
8540 cat >conftest.$ac_ext <<_ACEOF
8541 #line 8541 "configure"
8542 #include "confdefs.h"
8552 rm -f conftest.$ac_objext conftest$ac_exeext
8553 if { (eval echo "$as_me:8553: \"$ac_link\"") >&5
8554 (eval $ac_link) 2>&5
8556 echo "$as_me:8556: \$? = $ac_status" >&5
8557 (exit $ac_status); } &&
8558 { ac_try='test -s conftest$ac_exeext'
8559 { (eval echo "$as_me:8559: \"$ac_try\"") >&5
8562 echo "$as_me:8562: \$? = $ac_status" >&5
8563 (exit $ac_status); }; }; then
8566 echo "$as_me: failed program was:" >&5
8567 cat conftest.$ac_ext >&5
8570 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8571 if test $ac_R_nospace = yes; then
8572 echo "$as_me:8572: result: no" >&5
8573 echo "${ECHO_T}no" >&6
8574 X_LIBS="$X_LIBS -R$x_libraries"
8576 LIBS="$ac_xsave_LIBS -R $x_libraries"
8577 cat >conftest.$ac_ext <<_ACEOF
8578 #line 8578 "configure"
8579 #include "confdefs.h"
8589 rm -f conftest.$ac_objext conftest$ac_exeext
8590 if { (eval echo "$as_me:8590: \"$ac_link\"") >&5
8591 (eval $ac_link) 2>&5
8593 echo "$as_me:8593: \$? = $ac_status" >&5
8594 (exit $ac_status); } &&
8595 { ac_try='test -s conftest$ac_exeext'
8596 { (eval echo "$as_me:8596: \"$ac_try\"") >&5
8599 echo "$as_me:8599: \$? = $ac_status" >&5
8600 (exit $ac_status); }; }; then
8603 echo "$as_me: failed program was:" >&5
8604 cat conftest.$ac_ext >&5
8607 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8608 if test $ac_R_space = yes; then
8609 echo "$as_me:8609: result: yes" >&5
8610 echo "${ECHO_T}yes" >&6
8611 X_LIBS="$X_LIBS -R $x_libraries"
8613 echo "$as_me:8613: result: neither works" >&5
8614 echo "${ECHO_T}neither works" >&6
8621 # Check for system-dependent libraries X programs must link with.
8622 # Do this before checking for the system-independent R6 libraries
8623 # (-lICE), since we may need -lsocket or whatever for X linking.
8625 if test "$ISC" = yes; then
8626 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
8628 # Martyn Johnson says this is needed for Ultrix, if the X
8629 # libraries were built with DECnet support. And Karl Berry says
8630 # the Alpha needs dnet_stub (dnet does not exist).
8631 ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11"
8632 cat >conftest.$ac_ext <<_ACEOF
8633 #line 8633 "configure"
8634 #include "confdefs.h"
8636 /* Override any gcc2 internal prototype to avoid an error. */
8640 /* We use char because int might match the return type of a gcc2
8641 builtin and then its argument prototype would still apply. */
8642 char XOpenDisplay ();
8651 rm -f conftest.$ac_objext conftest$ac_exeext
8652 if { (eval echo "$as_me:8652: \"$ac_link\"") >&5
8653 (eval $ac_link) 2>&5
8655 echo "$as_me:8655: \$? = $ac_status" >&5
8656 (exit $ac_status); } &&
8657 { ac_try='test -s conftest$ac_exeext'
8658 { (eval echo "$as_me:8658: \"$ac_try\"") >&5
8661 echo "$as_me:8661: \$? = $ac_status" >&5
8662 (exit $ac_status); }; }; then
8665 echo "$as_me: failed program was:" >&5
8666 cat conftest.$ac_ext >&5
8667 echo "$as_me:8667: checking for dnet_ntoa in -ldnet" >&5
8668 echo $ECHO_N "checking for dnet_ntoa in -ldnet... $ECHO_C" >&6
8669 if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then
8670 echo $ECHO_N "(cached) $ECHO_C" >&6
8672 ac_check_lib_save_LIBS=$LIBS
8674 cat >conftest.$ac_ext <<_ACEOF
8675 #line 8675 "configure"
8676 #include "confdefs.h"
8678 /* Override any gcc2 internal prototype to avoid an error. */
8682 /* We use char because int might match the return type of a gcc2
8683 builtin and then its argument prototype would still apply. */
8693 rm -f conftest.$ac_objext conftest$ac_exeext
8694 if { (eval echo "$as_me:8694: \"$ac_link\"") >&5
8695 (eval $ac_link) 2>&5
8697 echo "$as_me:8697: \$? = $ac_status" >&5
8698 (exit $ac_status); } &&
8699 { ac_try='test -s conftest$ac_exeext'
8700 { (eval echo "$as_me:8700: \"$ac_try\"") >&5
8703 echo "$as_me:8703: \$? = $ac_status" >&5
8704 (exit $ac_status); }; }; then
8705 ac_cv_lib_dnet_dnet_ntoa=yes
8707 echo "$as_me: failed program was:" >&5
8708 cat conftest.$ac_ext >&5
8709 ac_cv_lib_dnet_dnet_ntoa=no
8711 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8712 LIBS=$ac_check_lib_save_LIBS
8714 echo "$as_me:8714: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
8715 echo "${ECHO_T}$ac_cv_lib_dnet_dnet_ntoa" >&6
8716 if test $ac_cv_lib_dnet_dnet_ntoa = yes; then
8717 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
8720 if test $ac_cv_lib_dnet_dnet_ntoa = no; then
8721 echo "$as_me:8721: checking for dnet_ntoa in -ldnet_stub" >&5
8722 echo $ECHO_N "checking for dnet_ntoa in -ldnet_stub... $ECHO_C" >&6
8723 if test "${ac_cv_lib_dnet_stub_dnet_ntoa+set}" = set; then
8724 echo $ECHO_N "(cached) $ECHO_C" >&6
8726 ac_check_lib_save_LIBS=$LIBS
8727 LIBS="-ldnet_stub $LIBS"
8728 cat >conftest.$ac_ext <<_ACEOF
8729 #line 8729 "configure"
8730 #include "confdefs.h"
8732 /* Override any gcc2 internal prototype to avoid an error. */
8736 /* We use char because int might match the return type of a gcc2
8737 builtin and then its argument prototype would still apply. */
8747 rm -f conftest.$ac_objext conftest$ac_exeext
8748 if { (eval echo "$as_me:8748: \"$ac_link\"") >&5
8749 (eval $ac_link) 2>&5
8751 echo "$as_me:8751: \$? = $ac_status" >&5
8752 (exit $ac_status); } &&
8753 { ac_try='test -s conftest$ac_exeext'
8754 { (eval echo "$as_me:8754: \"$ac_try\"") >&5
8757 echo "$as_me:8757: \$? = $ac_status" >&5
8758 (exit $ac_status); }; }; then
8759 ac_cv_lib_dnet_stub_dnet_ntoa=yes
8761 echo "$as_me: failed program was:" >&5
8762 cat conftest.$ac_ext >&5
8763 ac_cv_lib_dnet_stub_dnet_ntoa=no
8765 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8766 LIBS=$ac_check_lib_save_LIBS
8768 echo "$as_me:8768: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5
8769 echo "${ECHO_T}$ac_cv_lib_dnet_stub_dnet_ntoa" >&6
8770 if test $ac_cv_lib_dnet_stub_dnet_ntoa = yes; then
8771 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
8776 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8777 LIBS="$ac_xsave_LIBS"
8779 # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT,
8780 # to get the SysV transport functions.
8781 # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4)
8783 # The nsl library prevents programs from opening the X display
8784 # on Irix 5.2, according to T.E. Dickey.
8785 # The functions gethostbyname, getservbyname, and inet_addr are
8786 # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking.
8787 echo "$as_me:8787: checking for gethostbyname" >&5
8788 echo $ECHO_N "checking for gethostbyname... $ECHO_C" >&6
8789 if test "${ac_cv_func_gethostbyname+set}" = set; then
8790 echo $ECHO_N "(cached) $ECHO_C" >&6
8792 cat >conftest.$ac_ext <<_ACEOF
8793 #line 8793 "configure"
8794 #include "confdefs.h"
8795 /* System header to define __stub macros and hopefully few prototypes,
8796 which can conflict with char gethostbyname (); below. */
8798 /* Override any gcc2 internal prototype to avoid an error. */
8802 /* We use char because int might match the return type of a gcc2
8803 builtin and then its argument prototype would still apply. */
8804 char gethostbyname ();
8810 /* The GNU C library defines this for functions which it implements
8811 to always fail with ENOSYS. Some functions are actually named
8812 something starting with __ and the normal name is an alias. */
8813 #if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
8823 rm -f conftest.$ac_objext conftest$ac_exeext
8824 if { (eval echo "$as_me:8824: \"$ac_link\"") >&5
8825 (eval $ac_link) 2>&5
8827 echo "$as_me:8827: \$? = $ac_status" >&5
8828 (exit $ac_status); } &&
8829 { ac_try='test -s conftest$ac_exeext'
8830 { (eval echo "$as_me:8830: \"$ac_try\"") >&5
8833 echo "$as_me:8833: \$? = $ac_status" >&5
8834 (exit $ac_status); }; }; then
8835 ac_cv_func_gethostbyname=yes
8837 echo "$as_me: failed program was:" >&5
8838 cat conftest.$ac_ext >&5
8839 ac_cv_func_gethostbyname=no
8841 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8843 echo "$as_me:8843: result: $ac_cv_func_gethostbyname" >&5
8844 echo "${ECHO_T}$ac_cv_func_gethostbyname" >&6
8846 if test $ac_cv_func_gethostbyname = no; then
8847 echo "$as_me:8847: checking for gethostbyname in -lnsl" >&5
8848 echo $ECHO_N "checking for gethostbyname in -lnsl... $ECHO_C" >&6
8849 if test "${ac_cv_lib_nsl_gethostbyname+set}" = set; then
8850 echo $ECHO_N "(cached) $ECHO_C" >&6
8852 ac_check_lib_save_LIBS=$LIBS
8854 cat >conftest.$ac_ext <<_ACEOF
8855 #line 8855 "configure"
8856 #include "confdefs.h"
8858 /* Override any gcc2 internal prototype to avoid an error. */
8862 /* We use char because int might match the return type of a gcc2
8863 builtin and then its argument prototype would still apply. */
8864 char gethostbyname ();
8873 rm -f conftest.$ac_objext conftest$ac_exeext
8874 if { (eval echo "$as_me:8874: \"$ac_link\"") >&5
8875 (eval $ac_link) 2>&5
8877 echo "$as_me:8877: \$? = $ac_status" >&5
8878 (exit $ac_status); } &&
8879 { ac_try='test -s conftest$ac_exeext'
8880 { (eval echo "$as_me:8880: \"$ac_try\"") >&5
8883 echo "$as_me:8883: \$? = $ac_status" >&5
8884 (exit $ac_status); }; }; then
8885 ac_cv_lib_nsl_gethostbyname=yes
8887 echo "$as_me: failed program was:" >&5
8888 cat conftest.$ac_ext >&5
8889 ac_cv_lib_nsl_gethostbyname=no
8891 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8892 LIBS=$ac_check_lib_save_LIBS
8894 echo "$as_me:8894: result: $ac_cv_lib_nsl_gethostbyname" >&5
8895 echo "${ECHO_T}$ac_cv_lib_nsl_gethostbyname" >&6
8896 if test $ac_cv_lib_nsl_gethostbyname = yes; then
8897 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
8900 if test $ac_cv_lib_nsl_gethostbyname = no; then
8901 echo "$as_me:8901: checking for gethostbyname in -lbsd" >&5
8902 echo $ECHO_N "checking for gethostbyname in -lbsd... $ECHO_C" >&6
8903 if test "${ac_cv_lib_bsd_gethostbyname+set}" = set; then
8904 echo $ECHO_N "(cached) $ECHO_C" >&6
8906 ac_check_lib_save_LIBS=$LIBS
8908 cat >conftest.$ac_ext <<_ACEOF
8909 #line 8909 "configure"
8910 #include "confdefs.h"
8912 /* Override any gcc2 internal prototype to avoid an error. */
8916 /* We use char because int might match the return type of a gcc2
8917 builtin and then its argument prototype would still apply. */
8918 char gethostbyname ();
8927 rm -f conftest.$ac_objext conftest$ac_exeext
8928 if { (eval echo "$as_me:8928: \"$ac_link\"") >&5
8929 (eval $ac_link) 2>&5
8931 echo "$as_me:8931: \$? = $ac_status" >&5
8932 (exit $ac_status); } &&
8933 { ac_try='test -s conftest$ac_exeext'
8934 { (eval echo "$as_me:8934: \"$ac_try\"") >&5
8937 echo "$as_me:8937: \$? = $ac_status" >&5
8938 (exit $ac_status); }; }; then
8939 ac_cv_lib_bsd_gethostbyname=yes
8941 echo "$as_me: failed program was:" >&5
8942 cat conftest.$ac_ext >&5
8943 ac_cv_lib_bsd_gethostbyname=no
8945 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8946 LIBS=$ac_check_lib_save_LIBS
8948 echo "$as_me:8948: result: $ac_cv_lib_bsd_gethostbyname" >&5
8949 echo "${ECHO_T}$ac_cv_lib_bsd_gethostbyname" >&6
8950 if test $ac_cv_lib_bsd_gethostbyname = yes; then
8951 X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd"
8957 # lieder@skyler.mavd.honeywell.com says without -lsocket,
8958 # socket/setsockopt and other routines are undefined under SCO ODT
8959 # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary
8960 # on later versions), says Simon Leinen: it contains gethostby*
8961 # variants that don't use the nameserver (or something). -lsocket
8962 # must be given before -lnsl if both are needed. We assume that
8963 # if connect needs -lnsl, so does gethostbyname.
8964 echo "$as_me:8964: checking for connect" >&5
8965 echo $ECHO_N "checking for connect... $ECHO_C" >&6
8966 if test "${ac_cv_func_connect+set}" = set; then
8967 echo $ECHO_N "(cached) $ECHO_C" >&6
8969 cat >conftest.$ac_ext <<_ACEOF
8970 #line 8970 "configure"
8971 #include "confdefs.h"
8972 /* System header to define __stub macros and hopefully few prototypes,
8973 which can conflict with char connect (); below. */
8975 /* Override any gcc2 internal prototype to avoid an error. */
8979 /* We use char because int might match the return type of a gcc2
8980 builtin and then its argument prototype would still apply. */
8987 /* The GNU C library defines this for functions which it implements
8988 to always fail with ENOSYS. Some functions are actually named
8989 something starting with __ and the normal name is an alias. */
8990 #if defined (__stub_connect) || defined (__stub___connect)
9000 rm -f conftest.$ac_objext conftest$ac_exeext
9001 if { (eval echo "$as_me:9001: \"$ac_link\"") >&5
9002 (eval $ac_link) 2>&5
9004 echo "$as_me:9004: \$? = $ac_status" >&5
9005 (exit $ac_status); } &&
9006 { ac_try='test -s conftest$ac_exeext'
9007 { (eval echo "$as_me:9007: \"$ac_try\"") >&5
9010 echo "$as_me:9010: \$? = $ac_status" >&5
9011 (exit $ac_status); }; }; then
9012 ac_cv_func_connect=yes
9014 echo "$as_me: failed program was:" >&5
9015 cat conftest.$ac_ext >&5
9016 ac_cv_func_connect=no
9018 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9020 echo "$as_me:9020: result: $ac_cv_func_connect" >&5
9021 echo "${ECHO_T}$ac_cv_func_connect" >&6
9023 if test $ac_cv_func_connect = no; then
9024 echo "$as_me:9024: checking for connect in -lsocket" >&5
9025 echo $ECHO_N "checking for connect in -lsocket... $ECHO_C" >&6
9026 if test "${ac_cv_lib_socket_connect+set}" = set; then
9027 echo $ECHO_N "(cached) $ECHO_C" >&6
9029 ac_check_lib_save_LIBS=$LIBS
9030 LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
9031 cat >conftest.$ac_ext <<_ACEOF
9032 #line 9032 "configure"
9033 #include "confdefs.h"
9035 /* Override any gcc2 internal prototype to avoid an error. */
9039 /* We use char because int might match the return type of a gcc2
9040 builtin and then its argument prototype would still apply. */
9050 rm -f conftest.$ac_objext conftest$ac_exeext
9051 if { (eval echo "$as_me:9051: \"$ac_link\"") >&5
9052 (eval $ac_link) 2>&5
9054 echo "$as_me:9054: \$? = $ac_status" >&5
9055 (exit $ac_status); } &&
9056 { ac_try='test -s conftest$ac_exeext'
9057 { (eval echo "$as_me:9057: \"$ac_try\"") >&5
9060 echo "$as_me:9060: \$? = $ac_status" >&5
9061 (exit $ac_status); }; }; then
9062 ac_cv_lib_socket_connect=yes
9064 echo "$as_me: failed program was:" >&5
9065 cat conftest.$ac_ext >&5
9066 ac_cv_lib_socket_connect=no
9068 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9069 LIBS=$ac_check_lib_save_LIBS
9071 echo "$as_me:9071: result: $ac_cv_lib_socket_connect" >&5
9072 echo "${ECHO_T}$ac_cv_lib_socket_connect" >&6
9073 if test $ac_cv_lib_socket_connect = yes; then
9074 X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS"
9079 # Guillermo Gomez says -lposix is necessary on A/UX.
9080 echo "$as_me:9080: checking for remove" >&5
9081 echo $ECHO_N "checking for remove... $ECHO_C" >&6
9082 if test "${ac_cv_func_remove+set}" = set; then
9083 echo $ECHO_N "(cached) $ECHO_C" >&6
9085 cat >conftest.$ac_ext <<_ACEOF
9086 #line 9086 "configure"
9087 #include "confdefs.h"
9088 /* System header to define __stub macros and hopefully few prototypes,
9089 which can conflict with char remove (); below. */
9091 /* Override any gcc2 internal prototype to avoid an error. */
9095 /* We use char because int might match the return type of a gcc2
9096 builtin and then its argument prototype would still apply. */
9103 /* The GNU C library defines this for functions which it implements
9104 to always fail with ENOSYS. Some functions are actually named
9105 something starting with __ and the normal name is an alias. */
9106 #if defined (__stub_remove) || defined (__stub___remove)
9116 rm -f conftest.$ac_objext conftest$ac_exeext
9117 if { (eval echo "$as_me:9117: \"$ac_link\"") >&5
9118 (eval $ac_link) 2>&5
9120 echo "$as_me:9120: \$? = $ac_status" >&5
9121 (exit $ac_status); } &&
9122 { ac_try='test -s conftest$ac_exeext'
9123 { (eval echo "$as_me:9123: \"$ac_try\"") >&5
9126 echo "$as_me:9126: \$? = $ac_status" >&5
9127 (exit $ac_status); }; }; then
9128 ac_cv_func_remove=yes
9130 echo "$as_me: failed program was:" >&5
9131 cat conftest.$ac_ext >&5
9132 ac_cv_func_remove=no
9134 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9136 echo "$as_me:9136: result: $ac_cv_func_remove" >&5
9137 echo "${ECHO_T}$ac_cv_func_remove" >&6
9139 if test $ac_cv_func_remove = no; then
9140 echo "$as_me:9140: checking for remove in -lposix" >&5
9141 echo $ECHO_N "checking for remove in -lposix... $ECHO_C" >&6
9142 if test "${ac_cv_lib_posix_remove+set}" = set; then
9143 echo $ECHO_N "(cached) $ECHO_C" >&6
9145 ac_check_lib_save_LIBS=$LIBS
9146 LIBS="-lposix $LIBS"
9147 cat >conftest.$ac_ext <<_ACEOF
9148 #line 9148 "configure"
9149 #include "confdefs.h"
9151 /* Override any gcc2 internal prototype to avoid an error. */
9155 /* We use char because int might match the return type of a gcc2
9156 builtin and then its argument prototype would still apply. */
9166 rm -f conftest.$ac_objext conftest$ac_exeext
9167 if { (eval echo "$as_me:9167: \"$ac_link\"") >&5
9168 (eval $ac_link) 2>&5
9170 echo "$as_me:9170: \$? = $ac_status" >&5
9171 (exit $ac_status); } &&
9172 { ac_try='test -s conftest$ac_exeext'
9173 { (eval echo "$as_me:9173: \"$ac_try\"") >&5
9176 echo "$as_me:9176: \$? = $ac_status" >&5
9177 (exit $ac_status); }; }; then
9178 ac_cv_lib_posix_remove=yes
9180 echo "$as_me: failed program was:" >&5
9181 cat conftest.$ac_ext >&5
9182 ac_cv_lib_posix_remove=no
9184 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9185 LIBS=$ac_check_lib_save_LIBS
9187 echo "$as_me:9187: result: $ac_cv_lib_posix_remove" >&5
9188 echo "${ECHO_T}$ac_cv_lib_posix_remove" >&6
9189 if test $ac_cv_lib_posix_remove = yes; then
9190 X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix"
9195 # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
9196 echo "$as_me:9196: checking for shmat" >&5
9197 echo $ECHO_N "checking for shmat... $ECHO_C" >&6
9198 if test "${ac_cv_func_shmat+set}" = set; then
9199 echo $ECHO_N "(cached) $ECHO_C" >&6
9201 cat >conftest.$ac_ext <<_ACEOF
9202 #line 9202 "configure"
9203 #include "confdefs.h"
9204 /* System header to define __stub macros and hopefully few prototypes,
9205 which can conflict with char shmat (); below. */
9207 /* Override any gcc2 internal prototype to avoid an error. */
9211 /* We use char because int might match the return type of a gcc2
9212 builtin and then its argument prototype would still apply. */
9219 /* The GNU C library defines this for functions which it implements
9220 to always fail with ENOSYS. Some functions are actually named
9221 something starting with __ and the normal name is an alias. */
9222 #if defined (__stub_shmat) || defined (__stub___shmat)
9232 rm -f conftest.$ac_objext conftest$ac_exeext
9233 if { (eval echo "$as_me:9233: \"$ac_link\"") >&5
9234 (eval $ac_link) 2>&5
9236 echo "$as_me:9236: \$? = $ac_status" >&5
9237 (exit $ac_status); } &&
9238 { ac_try='test -s conftest$ac_exeext'
9239 { (eval echo "$as_me:9239: \"$ac_try\"") >&5
9242 echo "$as_me:9242: \$? = $ac_status" >&5
9243 (exit $ac_status); }; }; then
9244 ac_cv_func_shmat=yes
9246 echo "$as_me: failed program was:" >&5
9247 cat conftest.$ac_ext >&5
9250 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9252 echo "$as_me:9252: result: $ac_cv_func_shmat" >&5
9253 echo "${ECHO_T}$ac_cv_func_shmat" >&6
9255 if test $ac_cv_func_shmat = no; then
9256 echo "$as_me:9256: checking for shmat in -lipc" >&5
9257 echo $ECHO_N "checking for shmat in -lipc... $ECHO_C" >&6
9258 if test "${ac_cv_lib_ipc_shmat+set}" = set; then
9259 echo $ECHO_N "(cached) $ECHO_C" >&6
9261 ac_check_lib_save_LIBS=$LIBS
9263 cat >conftest.$ac_ext <<_ACEOF
9264 #line 9264 "configure"
9265 #include "confdefs.h"
9267 /* Override any gcc2 internal prototype to avoid an error. */
9271 /* We use char because int might match the return type of a gcc2
9272 builtin and then its argument prototype would still apply. */
9282 rm -f conftest.$ac_objext conftest$ac_exeext
9283 if { (eval echo "$as_me:9283: \"$ac_link\"") >&5
9284 (eval $ac_link) 2>&5
9286 echo "$as_me:9286: \$? = $ac_status" >&5
9287 (exit $ac_status); } &&
9288 { ac_try='test -s conftest$ac_exeext'
9289 { (eval echo "$as_me:9289: \"$ac_try\"") >&5
9292 echo "$as_me:9292: \$? = $ac_status" >&5
9293 (exit $ac_status); }; }; then
9294 ac_cv_lib_ipc_shmat=yes
9296 echo "$as_me: failed program was:" >&5
9297 cat conftest.$ac_ext >&5
9298 ac_cv_lib_ipc_shmat=no
9300 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9301 LIBS=$ac_check_lib_save_LIBS
9303 echo "$as_me:9303: result: $ac_cv_lib_ipc_shmat" >&5
9304 echo "${ECHO_T}$ac_cv_lib_ipc_shmat" >&6
9305 if test $ac_cv_lib_ipc_shmat = yes; then
9306 X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc"
9312 # Check for libraries that X11R6 Xt/Xaw programs need.
9313 ac_save_LDFLAGS=$LDFLAGS
9314 test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries"
9315 # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
9316 # check for ICE first), but we must link in the order -lSM -lICE or
9317 # we get undefined symbols. So assume we have SM if we have ICE.
9318 # These have to be linked with before -lX11, unlike the other
9319 # libraries we check for below, so use a different variable.
9320 # John Interrante, Karl Berry
9321 echo "$as_me:9321: checking for IceConnectionNumber in -lICE" >&5
9322 echo $ECHO_N "checking for IceConnectionNumber in -lICE... $ECHO_C" >&6
9323 if test "${ac_cv_lib_ICE_IceConnectionNumber+set}" = set; then
9324 echo $ECHO_N "(cached) $ECHO_C" >&6
9326 ac_check_lib_save_LIBS=$LIBS
9327 LIBS="-lICE $X_EXTRA_LIBS $LIBS"
9328 cat >conftest.$ac_ext <<_ACEOF
9329 #line 9329 "configure"
9330 #include "confdefs.h"
9332 /* Override any gcc2 internal prototype to avoid an error. */
9336 /* We use char because int might match the return type of a gcc2
9337 builtin and then its argument prototype would still apply. */
9338 char IceConnectionNumber ();
9342 IceConnectionNumber ();
9347 rm -f conftest.$ac_objext conftest$ac_exeext
9348 if { (eval echo "$as_me:9348: \"$ac_link\"") >&5
9349 (eval $ac_link) 2>&5
9351 echo "$as_me:9351: \$? = $ac_status" >&5
9352 (exit $ac_status); } &&
9353 { ac_try='test -s conftest$ac_exeext'
9354 { (eval echo "$as_me:9354: \"$ac_try\"") >&5
9357 echo "$as_me:9357: \$? = $ac_status" >&5
9358 (exit $ac_status); }; }; then
9359 ac_cv_lib_ICE_IceConnectionNumber=yes
9361 echo "$as_me: failed program was:" >&5
9362 cat conftest.$ac_ext >&5
9363 ac_cv_lib_ICE_IceConnectionNumber=no
9365 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9366 LIBS=$ac_check_lib_save_LIBS
9368 echo "$as_me:9368: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5
9369 echo "${ECHO_T}$ac_cv_lib_ICE_IceConnectionNumber" >&6
9370 if test $ac_cv_lib_ICE_IceConnectionNumber = yes; then
9371 X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
9374 LDFLAGS=$ac_save_LDFLAGS
9378 cf_x_athena=${cf_x_athena:-Xaw}
9380 echo "$as_me:9380: checking if you want to link with Xaw 3d library" >&5
9381 echo $ECHO_N "checking if you want to link with Xaw 3d library... $ECHO_C" >&6
9384 # Check whether --with-Xaw3d or --without-Xaw3d was given.
9385 if test "${with_Xaw3d+set}" = set; then
9386 withval="$with_Xaw3d"
9389 if test "$withval" = yes ; then
9391 echo "$as_me:9391: result: yes" >&5
9392 echo "${ECHO_T}yes" >&6
9394 echo "$as_me:9394: result: no" >&5
9395 echo "${ECHO_T}no" >&6
9398 echo "$as_me:9398: checking if you want to link with neXT Athena library" >&5
9399 echo $ECHO_N "checking if you want to link with neXT Athena library... $ECHO_C" >&6
9402 # Check whether --with-neXtaw or --without-neXtaw was given.
9403 if test "${with_neXtaw+set}" = set; then
9404 withval="$with_neXtaw"
9407 if test "$withval" = yes ; then
9409 echo "$as_me:9409: result: yes" >&5
9410 echo "${ECHO_T}yes" >&6
9412 echo "$as_me:9412: result: no" >&5
9413 echo "${ECHO_T}no" >&6
9416 echo "$as_me:9416: checking if you want to link with Athena-Plus library" >&5
9417 echo $ECHO_N "checking if you want to link with Athena-Plus library... $ECHO_C" >&6
9420 # Check whether --with-XawPlus or --without-XawPlus was given.
9421 if test "${with_XawPlus+set}" = set; then
9422 withval="$with_XawPlus"
9425 if test "$withval" = yes ; then
9427 echo "$as_me:9427: result: yes" >&5
9428 echo "${ECHO_T}yes" >&6
9430 echo "$as_me:9430: result: no" >&5
9431 echo "${ECHO_T}no" >&6
9436 if test "$PKG_CONFIG" != none ; then
9438 test "$cf_x_athena" = Xaw && cf_athena_list="xaw8 xaw7 xaw6"
9439 for cf_athena_pkg in \
9442 ${cf_x_athena}-devel \
9444 lib${cf_x_athena}-devel
9447 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists $cf_athena_pkg; then
9448 test -n "$verbose" && echo " found package $cf_athena_pkg" 1>&6
9450 echo "${as_me:-configure}:9450: testing found package $cf_athena_pkg ..." 1>&5
9452 cf_pkgconfig_incs="`$PKG_CONFIG --cflags $cf_athena_pkg 2>/dev/null`"
9453 cf_pkgconfig_libs="`$PKG_CONFIG --libs $cf_athena_pkg 2>/dev/null`"
9454 test -n "$verbose" && echo " package $cf_athena_pkg CFLAGS: $cf_pkgconfig_incs" 1>&6
9456 echo "${as_me:-configure}:9456: testing package $cf_athena_pkg CFLAGS: $cf_pkgconfig_incs ..." 1>&5
9458 test -n "$verbose" && echo " package $cf_athena_pkg LIBS: $cf_pkgconfig_libs" 1>&6
9460 echo "${as_me:-configure}:9460: testing package $cf_athena_pkg LIBS: $cf_pkgconfig_libs ..." 1>&5
9465 cf_new_extra_cppflags=
9467 for cf_add_cflags in $cf_pkgconfig_incs
9469 case $cf_fix_cppflags in
9471 case $cf_add_cflags in #(vi
9472 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
9473 case $cf_add_cflags in
9475 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
9477 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
9478 && test -z "${cf_tst_cflags}" \
9479 && cf_fix_cppflags=yes
9481 if test $cf_fix_cppflags = yes ; then
9482 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
9484 elif test "${cf_tst_cflags}" = "\"'" ; then
9485 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
9491 *$cf_add_cflags) #(vi
9494 case $cf_add_cflags in #(vi
9496 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
9498 CPPFLAGS=`echo "$CPPFLAGS" | \
9499 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
9500 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
9504 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
9509 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
9514 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
9516 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
9518 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
9519 && test -z "${cf_tst_cflags}" \
9520 && cf_fix_cppflags=no
9525 if test -n "$cf_new_cflags" ; then
9527 CFLAGS="$CFLAGS $cf_new_cflags"
9530 if test -n "$cf_new_cppflags" ; then
9532 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
9535 if test -n "$cf_new_extra_cppflags" ; then
9537 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
9540 LIBS="$cf_pkgconfig_libs $LIBS"
9542 cf_x_athena_lib="$cf_pkgconfig_libs"
9544 cf_x_athena_LIBS=`echo "HAVE_LIB_$cf_x_athena" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
9546 cat >>confdefs.h <<EOF
9547 #define $cf_x_athena_LIBS 1
9558 if test -z "$cf_x_athena_lib" ; then
9560 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists Xext; then
9561 test -n "$verbose" && echo " found package Xext" 1>&6
9563 echo "${as_me:-configure}:9563: testing found package Xext ..." 1>&5
9565 cf_pkgconfig_incs="`$PKG_CONFIG --cflags Xext 2>/dev/null`"
9566 cf_pkgconfig_libs="`$PKG_CONFIG --libs Xext 2>/dev/null`"
9567 test -n "$verbose" && echo " package Xext CFLAGS: $cf_pkgconfig_incs" 1>&6
9569 echo "${as_me:-configure}:9569: testing package Xext CFLAGS: $cf_pkgconfig_incs ..." 1>&5
9571 test -n "$verbose" && echo " package Xext LIBS: $cf_pkgconfig_libs" 1>&6
9573 echo "${as_me:-configure}:9573: testing package Xext LIBS: $cf_pkgconfig_libs ..." 1>&5
9578 cf_new_extra_cppflags=
9580 for cf_add_cflags in $cf_pkgconfig_incs
9582 case $cf_fix_cppflags in
9584 case $cf_add_cflags in #(vi
9585 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
9586 case $cf_add_cflags in
9588 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
9590 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
9591 && test -z "${cf_tst_cflags}" \
9592 && cf_fix_cppflags=yes
9594 if test $cf_fix_cppflags = yes ; then
9595 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
9597 elif test "${cf_tst_cflags}" = "\"'" ; then
9598 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
9604 *$cf_add_cflags) #(vi
9607 case $cf_add_cflags in #(vi
9609 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
9611 CPPFLAGS=`echo "$CPPFLAGS" | \
9612 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
9613 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
9617 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
9622 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
9627 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
9629 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
9631 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
9632 && test -z "${cf_tst_cflags}" \
9633 && cf_fix_cppflags=no
9638 if test -n "$cf_new_cflags" ; then
9640 CFLAGS="$CFLAGS $cf_new_cflags"
9643 if test -n "$cf_new_cppflags" ; then
9645 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
9648 if test -n "$cf_new_extra_cppflags" ; then
9650 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
9653 LIBS="$cf_pkgconfig_libs $LIBS"
9657 echo "$as_me:9657: checking for XextCreateExtension in -lXext" >&5
9658 echo $ECHO_N "checking for XextCreateExtension in -lXext... $ECHO_C" >&6
9659 if test "${ac_cv_lib_Xext_XextCreateExtension+set}" = set; then
9660 echo $ECHO_N "(cached) $ECHO_C" >&6
9662 ac_check_lib_save_LIBS=$LIBS
9664 cat >conftest.$ac_ext <<_ACEOF
9665 #line 9665 "configure"
9666 #include "confdefs.h"
9668 /* Override any gcc2 internal prototype to avoid an error. */
9672 /* We use char because int might match the return type of a gcc2
9673 builtin and then its argument prototype would still apply. */
9674 char XextCreateExtension ();
9678 XextCreateExtension ();
9683 rm -f conftest.$ac_objext conftest$ac_exeext
9684 if { (eval echo "$as_me:9684: \"$ac_link\"") >&5
9685 (eval $ac_link) 2>&5
9687 echo "$as_me:9687: \$? = $ac_status" >&5
9688 (exit $ac_status); } &&
9689 { ac_try='test -s conftest$ac_exeext'
9690 { (eval echo "$as_me:9690: \"$ac_try\"") >&5
9693 echo "$as_me:9693: \$? = $ac_status" >&5
9694 (exit $ac_status); }; }; then
9695 ac_cv_lib_Xext_XextCreateExtension=yes
9697 echo "$as_me: failed program was:" >&5
9698 cat conftest.$ac_ext >&5
9699 ac_cv_lib_Xext_XextCreateExtension=no
9701 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9702 LIBS=$ac_check_lib_save_LIBS
9704 echo "$as_me:9704: result: $ac_cv_lib_Xext_XextCreateExtension" >&5
9705 echo "${ECHO_T}$ac_cv_lib_Xext_XextCreateExtension" >&6
9706 if test $ac_cv_lib_Xext_XextCreateExtension = yes; then
9714 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xt; then
9715 test -n "$verbose" && echo " found package xt" 1>&6
9717 echo "${as_me:-configure}:9717: testing found package xt ..." 1>&5
9719 cf_pkgconfig_incs="`$PKG_CONFIG --cflags xt 2>/dev/null`"
9720 cf_pkgconfig_libs="`$PKG_CONFIG --libs xt 2>/dev/null`"
9721 test -n "$verbose" && echo " package xt CFLAGS: $cf_pkgconfig_incs" 1>&6
9723 echo "${as_me:-configure}:9723: testing package xt CFLAGS: $cf_pkgconfig_incs ..." 1>&5
9725 test -n "$verbose" && echo " package xt LIBS: $cf_pkgconfig_libs" 1>&6
9727 echo "${as_me:-configure}:9727: testing package xt LIBS: $cf_pkgconfig_libs ..." 1>&5
9732 cf_new_extra_cppflags=
9734 for cf_add_cflags in $cf_pkgconfig_incs
9736 case $cf_fix_cppflags in
9738 case $cf_add_cflags in #(vi
9739 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
9740 case $cf_add_cflags in
9742 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
9744 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
9745 && test -z "${cf_tst_cflags}" \
9746 && cf_fix_cppflags=yes
9748 if test $cf_fix_cppflags = yes ; then
9749 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
9751 elif test "${cf_tst_cflags}" = "\"'" ; then
9752 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
9758 *$cf_add_cflags) #(vi
9761 case $cf_add_cflags in #(vi
9763 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
9765 CPPFLAGS=`echo "$CPPFLAGS" | \
9766 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
9767 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
9771 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
9776 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
9781 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
9783 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
9785 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
9786 && test -z "${cf_tst_cflags}" \
9787 && cf_fix_cppflags=no
9792 if test -n "$cf_new_cflags" ; then
9794 CFLAGS="$CFLAGS $cf_new_cflags"
9797 if test -n "$cf_new_cppflags" ; then
9799 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
9802 if test -n "$cf_new_extra_cppflags" ; then
9804 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
9807 LIBS="$cf_pkgconfig_libs $LIBS"
9809 # workaround for broken ".pc" files used for X Toolkit.
9810 case "x$X_PRE_LIBS" in #(vi
9812 case "x$LIBS" in #(vi
9816 test -n "$verbose" && echo " work around broken package" 1>&6
9818 echo "${as_me:-configure}:9818: testing work around broken package ..." 1>&5
9820 test -n "$verbose" && echo " ...before $LIBS" 1>&6
9822 echo "${as_me:-configure}:9822: testing ...before $LIBS ..." 1>&5
9824 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s,-lXt ,-lXt $X_PRE_LIBS ," -e 's/ / /g'`
9825 test -n "$verbose" && echo " ...after $LIBS" 1>&6
9827 echo "${as_me:-configure}:9827: testing ...after $LIBS ..." 1>&5
9838 LDFLAGS="$X_LIBS $LDFLAGS"
9840 test -n "$verbose" && echo " checking additions to CFLAGS" 1>&6
9842 echo "${as_me:-configure}:9842: testing checking additions to CFLAGS ..." 1>&5
9844 cf_check_cflags="$CFLAGS"
9845 cf_check_cppflags="$CPPFLAGS"
9850 cf_new_extra_cppflags=
9852 for cf_add_cflags in $X_CFLAGS
9854 case $cf_fix_cppflags in
9856 case $cf_add_cflags in #(vi
9857 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
9858 case $cf_add_cflags in
9860 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
9862 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
9863 && test -z "${cf_tst_cflags}" \
9864 && cf_fix_cppflags=yes
9866 if test $cf_fix_cppflags = yes ; then
9867 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
9869 elif test "${cf_tst_cflags}" = "\"'" ; then
9870 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
9876 *$cf_add_cflags) #(vi
9879 case $cf_add_cflags in #(vi
9881 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
9883 CPPFLAGS=`echo "$CPPFLAGS" | \
9884 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
9885 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
9889 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
9894 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
9899 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
9901 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
9903 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
9904 && test -z "${cf_tst_cflags}" \
9905 && cf_fix_cppflags=no
9910 if test -n "$cf_new_cflags" ; then
9911 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
9913 echo "${as_me:-configure}:9913: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
9915 CFLAGS="$CFLAGS $cf_new_cflags"
9918 if test -n "$cf_new_cppflags" ; then
9919 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
9921 echo "${as_me:-configure}:9921: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
9923 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
9926 if test -n "$cf_new_extra_cppflags" ; then
9927 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
9929 echo "${as_me:-configure}:9929: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
9931 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
9934 if test "$cf_check_cflags" != "$CFLAGS" ; then
9935 cat >conftest.$ac_ext <<_ACEOF
9936 #line 9936 "configure"
9937 #include "confdefs.h"
9942 printf("Hello world");
9947 rm -f conftest.$ac_objext conftest$ac_exeext
9948 if { (eval echo "$as_me:9948: \"$ac_link\"") >&5
9949 (eval $ac_link) 2>&5
9951 echo "$as_me:9951: \$? = $ac_status" >&5
9952 (exit $ac_status); } &&
9953 { ac_try='test -s conftest$ac_exeext'
9954 { (eval echo "$as_me:9954: \"$ac_try\"") >&5
9957 echo "$as_me:9957: \$? = $ac_status" >&5
9958 (exit $ac_status); }; }; then
9961 echo "$as_me: failed program was:" >&5
9962 cat conftest.$ac_ext >&5
9963 test -n "$verbose" && echo " test-compile failed. Undoing change to \$CFLAGS" 1>&6
9965 echo "${as_me:-configure}:9965: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5
9967 if test "$cf_check_cppflags" != "$CPPFLAGS" ; then
9968 test -n "$verbose" && echo " but keeping change to \$CPPFLAGS" 1>&6
9970 echo "${as_me:-configure}:9970: testing but keeping change to \$CPPFLAGS ..." 1>&5
9973 CFLAGS="$cf_check_flags"
9975 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9978 echo "$as_me:9978: checking for XOpenDisplay" >&5
9979 echo $ECHO_N "checking for XOpenDisplay... $ECHO_C" >&6
9980 if test "${ac_cv_func_XOpenDisplay+set}" = set; then
9981 echo $ECHO_N "(cached) $ECHO_C" >&6
9983 cat >conftest.$ac_ext <<_ACEOF
9984 #line 9984 "configure"
9985 #include "confdefs.h"
9986 /* System header to define __stub macros and hopefully few prototypes,
9987 which can conflict with char XOpenDisplay (); below. */
9989 /* Override any gcc2 internal prototype to avoid an error. */
9993 /* We use char because int might match the return type of a gcc2
9994 builtin and then its argument prototype would still apply. */
9995 char XOpenDisplay ();
10001 /* The GNU C library defines this for functions which it implements
10002 to always fail with ENOSYS. Some functions are actually named
10003 something starting with __ and the normal name is an alias. */
10004 #if defined (__stub_XOpenDisplay) || defined (__stub___XOpenDisplay)
10014 rm -f conftest.$ac_objext conftest$ac_exeext
10015 if { (eval echo "$as_me:10015: \"$ac_link\"") >&5
10016 (eval $ac_link) 2>&5
10018 echo "$as_me:10018: \$? = $ac_status" >&5
10019 (exit $ac_status); } &&
10020 { ac_try='test -s conftest$ac_exeext'
10021 { (eval echo "$as_me:10021: \"$ac_try\"") >&5
10022 (eval $ac_try) 2>&5
10024 echo "$as_me:10024: \$? = $ac_status" >&5
10025 (exit $ac_status); }; }; then
10026 ac_cv_func_XOpenDisplay=yes
10028 echo "$as_me: failed program was:" >&5
10029 cat conftest.$ac_ext >&5
10030 ac_cv_func_XOpenDisplay=no
10032 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10034 echo "$as_me:10034: result: $ac_cv_func_XOpenDisplay" >&5
10035 echo "${ECHO_T}$ac_cv_func_XOpenDisplay" >&6
10036 if test $ac_cv_func_XOpenDisplay = yes; then
10040 echo "$as_me:10040: checking for XOpenDisplay in -lX11" >&5
10041 echo $ECHO_N "checking for XOpenDisplay in -lX11... $ECHO_C" >&6
10042 if test "${ac_cv_lib_X11_XOpenDisplay+set}" = set; then
10043 echo $ECHO_N "(cached) $ECHO_C" >&6
10045 ac_check_lib_save_LIBS=$LIBS
10046 LIBS="-lX11 $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
10047 cat >conftest.$ac_ext <<_ACEOF
10048 #line 10048 "configure"
10049 #include "confdefs.h"
10051 /* Override any gcc2 internal prototype to avoid an error. */
10055 /* We use char because int might match the return type of a gcc2
10056 builtin and then its argument prototype would still apply. */
10057 char XOpenDisplay ();
10066 rm -f conftest.$ac_objext conftest$ac_exeext
10067 if { (eval echo "$as_me:10067: \"$ac_link\"") >&5
10068 (eval $ac_link) 2>&5
10070 echo "$as_me:10070: \$? = $ac_status" >&5
10071 (exit $ac_status); } &&
10072 { ac_try='test -s conftest$ac_exeext'
10073 { (eval echo "$as_me:10073: \"$ac_try\"") >&5
10074 (eval $ac_try) 2>&5
10076 echo "$as_me:10076: \$? = $ac_status" >&5
10077 (exit $ac_status); }; }; then
10078 ac_cv_lib_X11_XOpenDisplay=yes
10080 echo "$as_me: failed program was:" >&5
10081 cat conftest.$ac_ext >&5
10082 ac_cv_lib_X11_XOpenDisplay=no
10084 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10085 LIBS=$ac_check_lib_save_LIBS
10087 echo "$as_me:10087: result: $ac_cv_lib_X11_XOpenDisplay" >&5
10088 echo "${ECHO_T}$ac_cv_lib_X11_XOpenDisplay" >&6
10089 if test $ac_cv_lib_X11_XOpenDisplay = yes; then
10095 echo "$as_me:10095: checking for XtAppInitialize" >&5
10096 echo $ECHO_N "checking for XtAppInitialize... $ECHO_C" >&6
10097 if test "${ac_cv_func_XtAppInitialize+set}" = set; then
10098 echo $ECHO_N "(cached) $ECHO_C" >&6
10100 cat >conftest.$ac_ext <<_ACEOF
10101 #line 10101 "configure"
10102 #include "confdefs.h"
10103 /* System header to define __stub macros and hopefully few prototypes,
10104 which can conflict with char XtAppInitialize (); below. */
10105 #include <assert.h>
10106 /* Override any gcc2 internal prototype to avoid an error. */
10110 /* We use char because int might match the return type of a gcc2
10111 builtin and then its argument prototype would still apply. */
10112 char XtAppInitialize ();
10118 /* The GNU C library defines this for functions which it implements
10119 to always fail with ENOSYS. Some functions are actually named
10120 something starting with __ and the normal name is an alias. */
10121 #if defined (__stub_XtAppInitialize) || defined (__stub___XtAppInitialize)
10124 f = XtAppInitialize;
10131 rm -f conftest.$ac_objext conftest$ac_exeext
10132 if { (eval echo "$as_me:10132: \"$ac_link\"") >&5
10133 (eval $ac_link) 2>&5
10135 echo "$as_me:10135: \$? = $ac_status" >&5
10136 (exit $ac_status); } &&
10137 { ac_try='test -s conftest$ac_exeext'
10138 { (eval echo "$as_me:10138: \"$ac_try\"") >&5
10139 (eval $ac_try) 2>&5
10141 echo "$as_me:10141: \$? = $ac_status" >&5
10142 (exit $ac_status); }; }; then
10143 ac_cv_func_XtAppInitialize=yes
10145 echo "$as_me: failed program was:" >&5
10146 cat conftest.$ac_ext >&5
10147 ac_cv_func_XtAppInitialize=no
10149 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10151 echo "$as_me:10151: result: $ac_cv_func_XtAppInitialize" >&5
10152 echo "${ECHO_T}$ac_cv_func_XtAppInitialize" >&6
10153 if test $ac_cv_func_XtAppInitialize = yes; then
10157 echo "$as_me:10157: checking for XtAppInitialize in -lXt" >&5
10158 echo $ECHO_N "checking for XtAppInitialize in -lXt... $ECHO_C" >&6
10159 if test "${ac_cv_lib_Xt_XtAppInitialize+set}" = set; then
10160 echo $ECHO_N "(cached) $ECHO_C" >&6
10162 ac_check_lib_save_LIBS=$LIBS
10163 LIBS="-lXt $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
10164 cat >conftest.$ac_ext <<_ACEOF
10165 #line 10165 "configure"
10166 #include "confdefs.h"
10168 /* Override any gcc2 internal prototype to avoid an error. */
10172 /* We use char because int might match the return type of a gcc2
10173 builtin and then its argument prototype would still apply. */
10174 char XtAppInitialize ();
10178 XtAppInitialize ();
10183 rm -f conftest.$ac_objext conftest$ac_exeext
10184 if { (eval echo "$as_me:10184: \"$ac_link\"") >&5
10185 (eval $ac_link) 2>&5
10187 echo "$as_me:10187: \$? = $ac_status" >&5
10188 (exit $ac_status); } &&
10189 { ac_try='test -s conftest$ac_exeext'
10190 { (eval echo "$as_me:10190: \"$ac_try\"") >&5
10191 (eval $ac_try) 2>&5
10193 echo "$as_me:10193: \$? = $ac_status" >&5
10194 (exit $ac_status); }; }; then
10195 ac_cv_lib_Xt_XtAppInitialize=yes
10197 echo "$as_me: failed program was:" >&5
10198 cat conftest.$ac_ext >&5
10199 ac_cv_lib_Xt_XtAppInitialize=no
10201 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10202 LIBS=$ac_check_lib_save_LIBS
10204 echo "$as_me:10204: result: $ac_cv_lib_Xt_XtAppInitialize" >&5
10205 echo "${ECHO_T}$ac_cv_lib_Xt_XtAppInitialize" >&6
10206 if test $ac_cv_lib_Xt_XtAppInitialize = yes; then
10207 cat >>confdefs.h <<\EOF
10208 #define HAVE_LIBXT 1
10212 LIBS="-lXt $X_PRE_LIBS $LIBS $X_EXTRA_LIBS"
10219 if test $cf_have_X_LIBS = no ; then
10220 { echo "$as_me:10220: WARNING: Unable to successfully link X Toolkit library (-lXt) with
10221 test program. You will have to check and add the proper libraries by hand
10223 echo "$as_me: WARNING: Unable to successfully link X Toolkit library (-lXt) with
10224 test program. You will have to check and add the proper libraries by hand
10225 to makefile." >&2;}
10228 cf_x_athena_root=$cf_x_athena
10231 for cf_path in default \
10232 /usr/contrib/X11R6 \
10233 /usr/contrib/X11R5 \
10237 if test -z "$cf_x_athena_inc" ; then
10238 cf_save="$CPPFLAGS"
10239 cf_test=X11/$cf_x_athena_root/SimpleMenu.h
10240 if test $cf_path != default ; then
10241 CPPFLAGS="$cf_save -I$cf_path/include"
10242 echo "$as_me:10242: checking for $cf_test in $cf_path" >&5
10243 echo $ECHO_N "checking for $cf_test in $cf_path... $ECHO_C" >&6
10245 echo "$as_me:10245: checking for $cf_test" >&5
10246 echo $ECHO_N "checking for $cf_test... $ECHO_C" >&6
10248 cat >conftest.$ac_ext <<_ACEOF
10249 #line 10249 "configure"
10250 #include "confdefs.h"
10252 #include <X11/Intrinsic.h>
10253 #include <$cf_test>
10262 rm -f conftest.$ac_objext
10263 if { (eval echo "$as_me:10263: \"$ac_compile\"") >&5
10264 (eval $ac_compile) 2>&5
10266 echo "$as_me:10266: \$? = $ac_status" >&5
10267 (exit $ac_status); } &&
10268 { ac_try='test -s conftest.$ac_objext'
10269 { (eval echo "$as_me:10269: \"$ac_try\"") >&5
10270 (eval $ac_try) 2>&5
10272 echo "$as_me:10272: \$? = $ac_status" >&5
10273 (exit $ac_status); }; }; then
10276 echo "$as_me: failed program was:" >&5
10277 cat conftest.$ac_ext >&5
10280 rm -f conftest.$ac_objext conftest.$ac_ext
10281 echo "$as_me:10281: result: $cf_result" >&5
10282 echo "${ECHO_T}$cf_result" >&6
10283 if test "$cf_result" = yes ; then
10284 cf_x_athena_inc=$cf_path
10287 CPPFLAGS="$cf_save"
10292 if test -z "$cf_x_athena_inc" ; then
10293 { echo "$as_me:10293: WARNING: Unable to successfully find Athena header files with test program" >&5
10294 echo "$as_me: WARNING: Unable to successfully find Athena header files with test program" >&2;}
10295 elif test "$cf_x_athena_inc" != default ; then
10296 CPPFLAGS="$CPPFLAGS -I$cf_x_athena_inc"
10299 cf_x_athena_root=$cf_x_athena
10302 for cf_path in default \
10303 /usr/contrib/X11R6 \
10304 /usr/contrib/X11R5 \
10309 "-l$cf_x_athena_root -lXmu" \
10310 "-l$cf_x_athena_root -lXpm -lXmu" \
10311 "-l${cf_x_athena_root}_s -lXmu_s"
10313 if test -z "$cf_x_athena_lib" ; then
10315 cf_test=XawSimpleMenuAddGlobalActions
10316 if test $cf_path != default ; then
10317 LIBS="-L$cf_path/lib $cf_lib $LIBS"
10318 echo "$as_me:10318: checking for $cf_lib in $cf_path" >&5
10319 echo $ECHO_N "checking for $cf_lib in $cf_path... $ECHO_C" >&6
10321 LIBS="$cf_lib $LIBS"
10322 echo "$as_me:10322: checking for $cf_test in $cf_lib" >&5
10323 echo $ECHO_N "checking for $cf_test in $cf_lib... $ECHO_C" >&6
10325 cat >conftest.$ac_ext <<_ACEOF
10326 #line 10326 "configure"
10327 #include "confdefs.h"
10337 rm -f conftest.$ac_objext conftest$ac_exeext
10338 if { (eval echo "$as_me:10338: \"$ac_link\"") >&5
10339 (eval $ac_link) 2>&5
10341 echo "$as_me:10341: \$? = $ac_status" >&5
10342 (exit $ac_status); } &&
10343 { ac_try='test -s conftest$ac_exeext'
10344 { (eval echo "$as_me:10344: \"$ac_try\"") >&5
10345 (eval $ac_try) 2>&5
10347 echo "$as_me:10347: \$? = $ac_status" >&5
10348 (exit $ac_status); }; }; then
10351 echo "$as_me: failed program was:" >&5
10352 cat conftest.$ac_ext >&5
10355 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10356 echo "$as_me:10356: result: $cf_result" >&5
10357 echo "${ECHO_T}$cf_result" >&6
10358 if test "$cf_result" = yes ; then
10359 cf_x_athena_lib="$cf_lib"
10367 if test -z "$cf_x_athena_lib" ; then
10368 { { echo "$as_me:10368: error: Unable to successfully link Athena library (-l$cf_x_athena_root) with test program" >&5
10369 echo "$as_me: error: Unable to successfully link Athena library (-l$cf_x_athena_root) with test program" >&2;}
10370 { (exit 1); exit 1; }; }
10373 cf_x_athena_LIBS=`echo "HAVE_LIB_$cf_x_athena" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
10375 cat >>confdefs.h <<EOF
10376 #define $cf_x_athena_LIBS 1
10381 for ac_prog in xcurses-config
10383 # Extract the first word of "$ac_prog", so it can be a program name with args.
10384 set dummy $ac_prog; ac_word=$2
10385 echo "$as_me:10385: checking for $ac_word" >&5
10386 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
10387 if test "${ac_cv_path_XCURSES_CONFIG+set}" = set; then
10388 echo $ECHO_N "(cached) $ECHO_C" >&6
10390 case $XCURSES_CONFIG in
10392 ac_cv_path_XCURSES_CONFIG="$XCURSES_CONFIG" # Let the user override the test with a path.
10395 ac_save_IFS=$IFS; IFS=$ac_path_separator
10397 for ac_dir in $ac_dummy; do
10399 test -z "$ac_dir" && ac_dir=.
10400 if $as_executable_p "$ac_dir/$ac_word"; then
10401 ac_cv_path_XCURSES_CONFIG="$ac_dir/$ac_word"
10402 echo "$as_me:10402: found $ac_dir/$ac_word" >&5
10410 XCURSES_CONFIG=$ac_cv_path_XCURSES_CONFIG
10412 if test -n "$XCURSES_CONFIG"; then
10413 echo "$as_me:10413: result: $XCURSES_CONFIG" >&5
10414 echo "${ECHO_T}$XCURSES_CONFIG" >&6
10416 echo "$as_me:10416: result: no" >&5
10417 echo "${ECHO_T}no" >&6
10420 test -n "$XCURSES_CONFIG" && break
10422 test -n "$XCURSES_CONFIG" || XCURSES_CONFIG="none"
10424 if test "$XCURSES_CONFIG" != none ; then
10426 CPPFLAGS="$CPPFLAGS `$XCURSES_CONFIG --cflags`"
10427 LIBS="`$XCURSES_CONFIG --libs` $LIBS"
10429 cf_cv_lib_XCurses=yes
10433 LDFLAGS="$LDFLAGS $X_LIBS"
10435 test -n "$verbose" && echo " checking additions to CFLAGS" 1>&6
10437 echo "${as_me:-configure}:10437: testing checking additions to CFLAGS ..." 1>&5
10439 cf_check_cflags="$CFLAGS"
10440 cf_check_cppflags="$CPPFLAGS"
10445 cf_new_extra_cppflags=
10447 for cf_add_cflags in $X_CFLAGS
10449 case $cf_fix_cppflags in
10451 case $cf_add_cflags in #(vi
10452 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
10453 case $cf_add_cflags in
10455 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10457 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10458 && test -z "${cf_tst_cflags}" \
10459 && cf_fix_cppflags=yes
10461 if test $cf_fix_cppflags = yes ; then
10462 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10464 elif test "${cf_tst_cflags}" = "\"'" ; then
10465 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10470 case "$CPPFLAGS" in
10471 *$cf_add_cflags) #(vi
10474 case $cf_add_cflags in #(vi
10476 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10478 CPPFLAGS=`echo "$CPPFLAGS" | \
10479 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10480 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10484 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
10489 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
10494 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10496 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10498 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10499 && test -z "${cf_tst_cflags}" \
10500 && cf_fix_cppflags=no
10505 if test -n "$cf_new_cflags" ; then
10506 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
10508 echo "${as_me:-configure}:10508: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
10510 CFLAGS="$CFLAGS $cf_new_cflags"
10513 if test -n "$cf_new_cppflags" ; then
10514 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
10516 echo "${as_me:-configure}:10516: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
10518 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
10521 if test -n "$cf_new_extra_cppflags" ; then
10522 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
10524 echo "${as_me:-configure}:10524: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
10526 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
10529 if test "$cf_check_cflags" != "$CFLAGS" ; then
10530 cat >conftest.$ac_ext <<_ACEOF
10531 #line 10531 "configure"
10532 #include "confdefs.h"
10537 printf("Hello world");
10542 rm -f conftest.$ac_objext conftest$ac_exeext
10543 if { (eval echo "$as_me:10543: \"$ac_link\"") >&5
10544 (eval $ac_link) 2>&5
10546 echo "$as_me:10546: \$? = $ac_status" >&5
10547 (exit $ac_status); } &&
10548 { ac_try='test -s conftest$ac_exeext'
10549 { (eval echo "$as_me:10549: \"$ac_try\"") >&5
10550 (eval $ac_try) 2>&5
10552 echo "$as_me:10552: \$? = $ac_status" >&5
10553 (exit $ac_status); }; }; then
10556 echo "$as_me: failed program was:" >&5
10557 cat conftest.$ac_ext >&5
10558 test -n "$verbose" && echo " test-compile failed. Undoing change to \$CFLAGS" 1>&6
10560 echo "${as_me:-configure}:10560: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5
10562 if test "$cf_check_cppflags" != "$CPPFLAGS" ; then
10563 test -n "$verbose" && echo " but keeping change to \$CPPFLAGS" 1>&6
10565 echo "${as_me:-configure}:10565: testing but keeping change to \$CPPFLAGS ..." 1>&5
10568 CFLAGS="$cf_check_flags"
10570 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10573 echo "$as_me:10573: checking for XOpenDisplay in -lX11" >&5
10574 echo $ECHO_N "checking for XOpenDisplay in -lX11... $ECHO_C" >&6
10575 if test "${ac_cv_lib_X11_XOpenDisplay+set}" = set; then
10576 echo $ECHO_N "(cached) $ECHO_C" >&6
10578 ac_check_lib_save_LIBS=$LIBS
10579 LIBS="-lX11 $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
10580 cat >conftest.$ac_ext <<_ACEOF
10581 #line 10581 "configure"
10582 #include "confdefs.h"
10584 /* Override any gcc2 internal prototype to avoid an error. */
10588 /* We use char because int might match the return type of a gcc2
10589 builtin and then its argument prototype would still apply. */
10590 char XOpenDisplay ();
10599 rm -f conftest.$ac_objext conftest$ac_exeext
10600 if { (eval echo "$as_me:10600: \"$ac_link\"") >&5
10601 (eval $ac_link) 2>&5
10603 echo "$as_me:10603: \$? = $ac_status" >&5
10604 (exit $ac_status); } &&
10605 { ac_try='test -s conftest$ac_exeext'
10606 { (eval echo "$as_me:10606: \"$ac_try\"") >&5
10607 (eval $ac_try) 2>&5
10609 echo "$as_me:10609: \$? = $ac_status" >&5
10610 (exit $ac_status); }; }; then
10611 ac_cv_lib_X11_XOpenDisplay=yes
10613 echo "$as_me: failed program was:" >&5
10614 cat conftest.$ac_ext >&5
10615 ac_cv_lib_X11_XOpenDisplay=no
10617 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10618 LIBS=$ac_check_lib_save_LIBS
10620 echo "$as_me:10620: result: $ac_cv_lib_X11_XOpenDisplay" >&5
10621 echo "${ECHO_T}$ac_cv_lib_X11_XOpenDisplay" >&6
10622 if test $ac_cv_lib_X11_XOpenDisplay = yes; then
10626 echo "$as_me:10626: checking for XCurses library" >&5
10627 echo $ECHO_N "checking for XCurses library... $ECHO_C" >&6
10628 if test "${cf_cv_lib_XCurses+set}" = set; then
10629 echo $ECHO_N "(cached) $ECHO_C" >&6
10632 LIBS="-lXCurses $LIBS"
10633 cat >conftest.$ac_ext <<_ACEOF
10634 #line 10634 "configure"
10635 #include "confdefs.h"
10637 #include <xcurses.h>
10638 char *XCursesProgramName = "test";
10648 rm -f conftest.$ac_objext conftest$ac_exeext
10649 if { (eval echo "$as_me:10649: \"$ac_link\"") >&5
10650 (eval $ac_link) 2>&5
10652 echo "$as_me:10652: \$? = $ac_status" >&5
10653 (exit $ac_status); } &&
10654 { ac_try='test -s conftest$ac_exeext'
10655 { (eval echo "$as_me:10655: \"$ac_try\"") >&5
10656 (eval $ac_try) 2>&5
10658 echo "$as_me:10658: \$? = $ac_status" >&5
10659 (exit $ac_status); }; }; then
10660 cf_cv_lib_XCurses=yes
10662 echo "$as_me: failed program was:" >&5
10663 cat conftest.$ac_ext >&5
10664 cf_cv_lib_XCurses=no
10666 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10669 echo "$as_me:10669: result: $cf_cv_lib_XCurses" >&5
10670 echo "${ECHO_T}$cf_cv_lib_XCurses" >&6
10674 if test $cf_cv_lib_XCurses = yes ; then
10675 cat >>confdefs.h <<\EOF
10679 cat >>confdefs.h <<\EOF
10683 cat >>confdefs.h <<\EOF
10684 #define HAVE_XCURSES 1
10688 { { echo "$as_me:10688: error: Cannot link with XCurses" >&5
10689 echo "$as_me: error: Cannot link with XCurses" >&2;}
10690 { (exit 1); exit 1; }; }
10696 case $cf_cv_screen in #(vi
10700 # look for curses-related libraries
10702 as_ac_Lib=`echo "ac_cv_lib_panel$cf_cv_libtype''_new_panel" | $as_tr_sh`
10703 echo "$as_me:10703: checking for new_panel in -lpanel$cf_cv_libtype" >&5
10704 echo $ECHO_N "checking for new_panel in -lpanel$cf_cv_libtype... $ECHO_C" >&6
10705 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
10706 echo $ECHO_N "(cached) $ECHO_C" >&6
10708 ac_check_lib_save_LIBS=$LIBS
10709 LIBS="-lpanel$cf_cv_libtype $LIBS"
10710 cat >conftest.$ac_ext <<_ACEOF
10711 #line 10711 "configure"
10712 #include "confdefs.h"
10714 /* Override any gcc2 internal prototype to avoid an error. */
10718 /* We use char because int might match the return type of a gcc2
10719 builtin and then its argument prototype would still apply. */
10729 rm -f conftest.$ac_objext conftest$ac_exeext
10730 if { (eval echo "$as_me:10730: \"$ac_link\"") >&5
10731 (eval $ac_link) 2>&5
10733 echo "$as_me:10733: \$? = $ac_status" >&5
10734 (exit $ac_status); } &&
10735 { ac_try='test -s conftest$ac_exeext'
10736 { (eval echo "$as_me:10736: \"$ac_try\"") >&5
10737 (eval $ac_try) 2>&5
10739 echo "$as_me:10739: \$? = $ac_status" >&5
10740 (exit $ac_status); }; }; then
10741 eval "$as_ac_Lib=yes"
10743 echo "$as_me: failed program was:" >&5
10744 cat conftest.$ac_ext >&5
10745 eval "$as_ac_Lib=no"
10747 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10748 LIBS=$ac_check_lib_save_LIBS
10750 echo "$as_me:10750: result: `eval echo '${'$as_ac_Lib'}'`" >&5
10751 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
10752 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
10753 cat >>confdefs.h <<EOF
10754 #define `echo "HAVE_LIBpanel$cf_cv_libtype" | $as_tr_cpp` 1
10757 LIBS="-lpanel$cf_cv_libtype $LIBS"
10761 as_ac_Lib=`echo "ac_cv_lib_menu$cf_cv_libtype''_menu_driver" | $as_tr_sh`
10762 echo "$as_me:10762: checking for menu_driver in -lmenu$cf_cv_libtype" >&5
10763 echo $ECHO_N "checking for menu_driver in -lmenu$cf_cv_libtype... $ECHO_C" >&6
10764 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
10765 echo $ECHO_N "(cached) $ECHO_C" >&6
10767 ac_check_lib_save_LIBS=$LIBS
10768 LIBS="-lmenu$cf_cv_libtype $LIBS"
10769 cat >conftest.$ac_ext <<_ACEOF
10770 #line 10770 "configure"
10771 #include "confdefs.h"
10773 /* Override any gcc2 internal prototype to avoid an error. */
10777 /* We use char because int might match the return type of a gcc2
10778 builtin and then its argument prototype would still apply. */
10779 char menu_driver ();
10788 rm -f conftest.$ac_objext conftest$ac_exeext
10789 if { (eval echo "$as_me:10789: \"$ac_link\"") >&5
10790 (eval $ac_link) 2>&5
10792 echo "$as_me:10792: \$? = $ac_status" >&5
10793 (exit $ac_status); } &&
10794 { ac_try='test -s conftest$ac_exeext'
10795 { (eval echo "$as_me:10795: \"$ac_try\"") >&5
10796 (eval $ac_try) 2>&5
10798 echo "$as_me:10798: \$? = $ac_status" >&5
10799 (exit $ac_status); }; }; then
10800 eval "$as_ac_Lib=yes"
10802 echo "$as_me: failed program was:" >&5
10803 cat conftest.$ac_ext >&5
10804 eval "$as_ac_Lib=no"
10806 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10807 LIBS=$ac_check_lib_save_LIBS
10809 echo "$as_me:10809: result: `eval echo '${'$as_ac_Lib'}'`" >&5
10810 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
10811 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
10812 cat >>confdefs.h <<EOF
10813 #define `echo "HAVE_LIBmenu$cf_cv_libtype" | $as_tr_cpp` 1
10816 LIBS="-lmenu$cf_cv_libtype $LIBS"
10820 as_ac_Lib=`echo "ac_cv_lib_form$cf_cv_libtype''_form_driver" | $as_tr_sh`
10821 echo "$as_me:10821: checking for form_driver in -lform$cf_cv_libtype" >&5
10822 echo $ECHO_N "checking for form_driver in -lform$cf_cv_libtype... $ECHO_C" >&6
10823 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
10824 echo $ECHO_N "(cached) $ECHO_C" >&6
10826 ac_check_lib_save_LIBS=$LIBS
10827 LIBS="-lform$cf_cv_libtype $LIBS"
10828 cat >conftest.$ac_ext <<_ACEOF
10829 #line 10829 "configure"
10830 #include "confdefs.h"
10832 /* Override any gcc2 internal prototype to avoid an error. */
10836 /* We use char because int might match the return type of a gcc2
10837 builtin and then its argument prototype would still apply. */
10838 char form_driver ();
10847 rm -f conftest.$ac_objext conftest$ac_exeext
10848 if { (eval echo "$as_me:10848: \"$ac_link\"") >&5
10849 (eval $ac_link) 2>&5
10851 echo "$as_me:10851: \$? = $ac_status" >&5
10852 (exit $ac_status); } &&
10853 { ac_try='test -s conftest$ac_exeext'
10854 { (eval echo "$as_me:10854: \"$ac_try\"") >&5
10855 (eval $ac_try) 2>&5
10857 echo "$as_me:10857: \$? = $ac_status" >&5
10858 (exit $ac_status); }; }; then
10859 eval "$as_ac_Lib=yes"
10861 echo "$as_me: failed program was:" >&5
10862 cat conftest.$ac_ext >&5
10863 eval "$as_ac_Lib=no"
10865 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10866 LIBS=$ac_check_lib_save_LIBS
10868 echo "$as_me:10868: result: `eval echo '${'$as_ac_Lib'}'`" >&5
10869 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
10870 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
10871 cat >>confdefs.h <<EOF
10872 #define `echo "HAVE_LIBform$cf_cv_libtype" | $as_tr_cpp` 1
10875 LIBS="-lform$cf_cv_libtype $LIBS"
10879 # look for curses-related headers
10889 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
10890 echo "$as_me:10890: checking for $ac_header" >&5
10891 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
10892 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10893 echo $ECHO_N "(cached) $ECHO_C" >&6
10895 cat >conftest.$ac_ext <<_ACEOF
10896 #line 10896 "configure"
10897 #include "confdefs.h"
10898 #include <$ac_header>
10900 if { (eval echo "$as_me:10900: \"$ac_cpp conftest.$ac_ext\"") >&5
10901 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10903 egrep -v '^ *\+' conftest.er1 >conftest.err
10905 cat conftest.err >&5
10906 echo "$as_me:10906: \$? = $ac_status" >&5
10907 (exit $ac_status); } >/dev/null; then
10908 if test -s conftest.err; then
10909 ac_cpp_err=$ac_c_preproc_warn_flag
10916 if test -z "$ac_cpp_err"; then
10917 eval "$as_ac_Header=yes"
10919 echo "$as_me: failed program was:" >&5
10920 cat conftest.$ac_ext >&5
10921 eval "$as_ac_Header=no"
10923 rm -f conftest.err conftest.$ac_ext
10925 echo "$as_me:10925: result: `eval echo '${'$as_ac_Header'}'`" >&5
10926 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
10927 if test `eval echo '${'$as_ac_Header'}'` = yes; then
10928 cat >>confdefs.h <<EOF
10929 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
10938 echo "$as_me:10938: checking return type of signal handlers" >&5
10939 echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6
10940 if test "${ac_cv_type_signal+set}" = set; then
10941 echo $ECHO_N "(cached) $ECHO_C" >&6
10943 cat >conftest.$ac_ext <<_ACEOF
10944 #line 10944 "configure"
10945 #include "confdefs.h"
10946 #include <sys/types.h>
10947 #include <signal.h>
10952 extern "C" void (*signal (int, void (*)(int)))(int);
10954 void (*signal ()) ();
10965 rm -f conftest.$ac_objext
10966 if { (eval echo "$as_me:10966: \"$ac_compile\"") >&5
10967 (eval $ac_compile) 2>&5
10969 echo "$as_me:10969: \$? = $ac_status" >&5
10970 (exit $ac_status); } &&
10971 { ac_try='test -s conftest.$ac_objext'
10972 { (eval echo "$as_me:10972: \"$ac_try\"") >&5
10973 (eval $ac_try) 2>&5
10975 echo "$as_me:10975: \$? = $ac_status" >&5
10976 (exit $ac_status); }; }; then
10977 ac_cv_type_signal=void
10979 echo "$as_me: failed program was:" >&5
10980 cat conftest.$ac_ext >&5
10981 ac_cv_type_signal=int
10983 rm -f conftest.$ac_objext conftest.$ac_ext
10985 echo "$as_me:10985: result: $ac_cv_type_signal" >&5
10986 echo "${ECHO_T}$ac_cv_type_signal" >&6
10988 cat >>confdefs.h <<EOF
10989 #define RETSIGTYPE $ac_cv_type_signal
10992 echo "$as_me:10992: checking for ANSI C header files" >&5
10993 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
10994 if test "${ac_cv_header_stdc+set}" = set; then
10995 echo $ECHO_N "(cached) $ECHO_C" >&6
10997 cat >conftest.$ac_ext <<_ACEOF
10998 #line 10998 "configure"
10999 #include "confdefs.h"
11000 #include <stdlib.h>
11001 #include <stdarg.h>
11002 #include <string.h>
11006 if { (eval echo "$as_me:11006: \"$ac_cpp conftest.$ac_ext\"") >&5
11007 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11009 egrep -v '^ *\+' conftest.er1 >conftest.err
11011 cat conftest.err >&5
11012 echo "$as_me:11012: \$? = $ac_status" >&5
11013 (exit $ac_status); } >/dev/null; then
11014 if test -s conftest.err; then
11015 ac_cpp_err=$ac_c_preproc_warn_flag
11022 if test -z "$ac_cpp_err"; then
11023 ac_cv_header_stdc=yes
11025 echo "$as_me: failed program was:" >&5
11026 cat conftest.$ac_ext >&5
11027 ac_cv_header_stdc=no
11029 rm -f conftest.err conftest.$ac_ext
11031 if test $ac_cv_header_stdc = yes; then
11032 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
11033 cat >conftest.$ac_ext <<_ACEOF
11034 #line 11034 "configure"
11035 #include "confdefs.h"
11036 #include <string.h>
11039 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11040 egrep "memchr" >/dev/null 2>&1; then
11043 ac_cv_header_stdc=no
11049 if test $ac_cv_header_stdc = yes; then
11050 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
11051 cat >conftest.$ac_ext <<_ACEOF
11052 #line 11052 "configure"
11053 #include "confdefs.h"
11054 #include <stdlib.h>
11057 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11058 egrep "free" >/dev/null 2>&1; then
11061 ac_cv_header_stdc=no
11067 if test $ac_cv_header_stdc = yes; then
11068 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
11069 if test "$cross_compiling" = yes; then
11072 cat >conftest.$ac_ext <<_ACEOF
11073 #line 11073 "configure"
11074 #include "confdefs.h"
11076 #if ((' ' & 0x0FF) == 0x020)
11077 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
11078 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
11080 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
11081 || ('j' <= (c) && (c) <= 'r') \
11082 || ('s' <= (c) && (c) <= 'z'))
11083 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
11086 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
11091 for (i = 0; i < 256; i++)
11092 if (XOR (islower (i), ISLOWER (i))
11093 || toupper (i) != TOUPPER (i))
11094 $ac_main_return(2);
11095 $ac_main_return (0);
11098 rm -f conftest$ac_exeext
11099 if { (eval echo "$as_me:11099: \"$ac_link\"") >&5
11100 (eval $ac_link) 2>&5
11102 echo "$as_me:11102: \$? = $ac_status" >&5
11103 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
11104 { (eval echo "$as_me:11104: \"$ac_try\"") >&5
11105 (eval $ac_try) 2>&5
11107 echo "$as_me:11107: \$? = $ac_status" >&5
11108 (exit $ac_status); }; }; then
11111 echo "$as_me: program exited with status $ac_status" >&5
11112 echo "$as_me: failed program was:" >&5
11113 cat conftest.$ac_ext >&5
11114 ac_cv_header_stdc=no
11116 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
11120 echo "$as_me:11120: result: $ac_cv_header_stdc" >&5
11121 echo "${ECHO_T}$ac_cv_header_stdc" >&6
11122 if test $ac_cv_header_stdc = yes; then
11124 cat >>confdefs.h <<\EOF
11125 #define STDC_HEADERS 1
11130 echo "$as_me:11130: checking whether time.h and sys/time.h may both be included" >&5
11131 echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
11132 if test "${ac_cv_header_time+set}" = set; then
11133 echo $ECHO_N "(cached) $ECHO_C" >&6
11135 cat >conftest.$ac_ext <<_ACEOF
11136 #line 11136 "configure"
11137 #include "confdefs.h"
11138 #include <sys/types.h>
11139 #include <sys/time.h>
11145 if ((struct tm *) 0)
11151 rm -f conftest.$ac_objext
11152 if { (eval echo "$as_me:11152: \"$ac_compile\"") >&5
11153 (eval $ac_compile) 2>&5
11155 echo "$as_me:11155: \$? = $ac_status" >&5
11156 (exit $ac_status); } &&
11157 { ac_try='test -s conftest.$ac_objext'
11158 { (eval echo "$as_me:11158: \"$ac_try\"") >&5
11159 (eval $ac_try) 2>&5
11161 echo "$as_me:11161: \$? = $ac_status" >&5
11162 (exit $ac_status); }; }; then
11163 ac_cv_header_time=yes
11165 echo "$as_me: failed program was:" >&5
11166 cat conftest.$ac_ext >&5
11167 ac_cv_header_time=no
11169 rm -f conftest.$ac_objext conftest.$ac_ext
11171 echo "$as_me:11171: result: $ac_cv_header_time" >&5
11172 echo "${ECHO_T}$ac_cv_header_time" >&6
11173 if test $ac_cv_header_time = yes; then
11175 cat >>confdefs.h <<\EOF
11176 #define TIME_WITH_SYS_TIME 1
11192 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
11193 echo "$as_me:11193: checking for $ac_header" >&5
11194 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
11195 if eval "test \"\${$as_ac_Header+set}\" = set"; then
11196 echo $ECHO_N "(cached) $ECHO_C" >&6
11198 cat >conftest.$ac_ext <<_ACEOF
11199 #line 11199 "configure"
11200 #include "confdefs.h"
11201 #include <$ac_header>
11203 if { (eval echo "$as_me:11203: \"$ac_cpp conftest.$ac_ext\"") >&5
11204 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11206 egrep -v '^ *\+' conftest.er1 >conftest.err
11208 cat conftest.err >&5
11209 echo "$as_me:11209: \$? = $ac_status" >&5
11210 (exit $ac_status); } >/dev/null; then
11211 if test -s conftest.err; then
11212 ac_cpp_err=$ac_c_preproc_warn_flag
11219 if test -z "$ac_cpp_err"; then
11220 eval "$as_ac_Header=yes"
11222 echo "$as_me: failed program was:" >&5
11223 cat conftest.$ac_ext >&5
11224 eval "$as_ac_Header=no"
11226 rm -f conftest.err conftest.$ac_ext
11228 echo "$as_me:11228: result: `eval echo '${'$as_ac_Header'}'`" >&5
11229 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
11230 if test `eval echo '${'$as_ac_Header'}'` = yes; then
11231 cat >>confdefs.h <<EOF
11232 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
11251 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11252 echo "$as_me:11252: checking for $ac_func" >&5
11253 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11254 if eval "test \"\${$as_ac_var+set}\" = set"; then
11255 echo $ECHO_N "(cached) $ECHO_C" >&6
11257 cat >conftest.$ac_ext <<_ACEOF
11258 #line 11258 "configure"
11259 #include "confdefs.h"
11260 /* System header to define __stub macros and hopefully few prototypes,
11261 which can conflict with char $ac_func (); below. */
11262 #include <assert.h>
11263 /* Override any gcc2 internal prototype to avoid an error. */
11267 /* We use char because int might match the return type of a gcc2
11268 builtin and then its argument prototype would still apply. */
11275 /* The GNU C library defines this for functions which it implements
11276 to always fail with ENOSYS. Some functions are actually named
11277 something starting with __ and the normal name is an alias. */
11278 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
11288 rm -f conftest.$ac_objext conftest$ac_exeext
11289 if { (eval echo "$as_me:11289: \"$ac_link\"") >&5
11290 (eval $ac_link) 2>&5
11292 echo "$as_me:11292: \$? = $ac_status" >&5
11293 (exit $ac_status); } &&
11294 { ac_try='test -s conftest$ac_exeext'
11295 { (eval echo "$as_me:11295: \"$ac_try\"") >&5
11296 (eval $ac_try) 2>&5
11298 echo "$as_me:11298: \$? = $ac_status" >&5
11299 (exit $ac_status); }; }; then
11300 eval "$as_ac_var=yes"
11302 echo "$as_me: failed program was:" >&5
11303 cat conftest.$ac_ext >&5
11304 eval "$as_ac_var=no"
11306 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11308 echo "$as_me:11308: result: `eval echo '${'$as_ac_var'}'`" >&5
11309 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11310 if test `eval echo '${'$as_ac_var'}'` = yes; then
11311 cat >>confdefs.h <<EOF
11312 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11318 echo "$as_me:11318: checking if we must define _XOPEN_SOURCE_EXTENDED" >&5
11319 echo $ECHO_N "checking if we must define _XOPEN_SOURCE_EXTENDED... $ECHO_C" >&6
11320 if test "${cf_cv_need_xopen_extension+set}" = set; then
11321 echo $ECHO_N "(cached) $ECHO_C" >&6
11324 cat >conftest.$ac_ext <<_ACEOF
11325 #line 11325 "configure"
11326 #include "confdefs.h"
11328 #include <stdlib.h>
11329 #include <${cf_cv_ncurses_header:-curses.h}>
11334 #if defined(NCURSES_VERSION_PATCH)
11335 if (NCURSES_VERSION_PATCH < 20100501) && (NCURSES_VERSION_PATCH >= 20100403)
11339 long x = winnstr(stdscr, "", 0);
11341 getbegyx(stdscr, y1, x1)
11346 rm -f conftest.$ac_objext conftest$ac_exeext
11347 if { (eval echo "$as_me:11347: \"$ac_link\"") >&5
11348 (eval $ac_link) 2>&5
11350 echo "$as_me:11350: \$? = $ac_status" >&5
11351 (exit $ac_status); } &&
11352 { ac_try='test -s conftest$ac_exeext'
11353 { (eval echo "$as_me:11353: \"$ac_try\"") >&5
11354 (eval $ac_try) 2>&5
11356 echo "$as_me:11356: \$? = $ac_status" >&5
11357 (exit $ac_status); }; }; then
11358 cf_cv_need_xopen_extension=no
11360 echo "$as_me: failed program was:" >&5
11361 cat conftest.$ac_ext >&5
11362 cat >conftest.$ac_ext <<_ACEOF
11363 #line 11363 "configure"
11364 #include "confdefs.h"
11366 #define _XOPEN_SOURCE_EXTENDED
11367 #include <stdlib.h>
11368 #include <${cf_cv_ncurses_header:-curses.h}>
11373 #ifdef NCURSES_VERSION
11375 int check2 = curs_set((int)sizeof(check));
11377 long x = winnstr(stdscr, "", 0);
11379 getbegyx(stdscr, y1, x1)
11384 rm -f conftest.$ac_objext conftest$ac_exeext
11385 if { (eval echo "$as_me:11385: \"$ac_link\"") >&5
11386 (eval $ac_link) 2>&5
11388 echo "$as_me:11388: \$? = $ac_status" >&5
11389 (exit $ac_status); } &&
11390 { ac_try='test -s conftest$ac_exeext'
11391 { (eval echo "$as_me:11391: \"$ac_try\"") >&5
11392 (eval $ac_try) 2>&5
11394 echo "$as_me:11394: \$? = $ac_status" >&5
11395 (exit $ac_status); }; }; then
11396 cf_cv_need_xopen_extension=yes
11398 echo "$as_me: failed program was:" >&5
11399 cat conftest.$ac_ext >&5
11400 cf_cv_need_xopen_extension=unknown
11402 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11404 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11406 echo "$as_me:11406: result: $cf_cv_need_xopen_extension" >&5
11407 echo "${ECHO_T}$cf_cv_need_xopen_extension" >&6
11408 test $cf_cv_need_xopen_extension = yes && CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE_EXTENDED"
11410 echo "$as_me:11410: checking for term.h" >&5
11411 echo $ECHO_N "checking for term.h... $ECHO_C" >&6
11412 if test "${cf_cv_term_header+set}" = set; then
11413 echo $ECHO_N "(cached) $ECHO_C" >&6
11416 # If we found <ncurses/curses.h>, look for <ncurses/term.h>, but always look
11417 # for <term.h> if we do not find the variant.
11419 `echo ${cf_cv_ncurses_header:-curses.h} | sed -e 's%/.*%/%'`term.h \
11422 cat >conftest.$ac_ext <<_ACEOF
11423 #line 11423 "configure"
11424 #include "confdefs.h"
11426 #include <${cf_cv_ncurses_header:-curses.h}>
11427 #include <${cf_header}>
11436 rm -f conftest.$ac_objext
11437 if { (eval echo "$as_me:11437: \"$ac_compile\"") >&5
11438 (eval $ac_compile) 2>&5
11440 echo "$as_me:11440: \$? = $ac_status" >&5
11441 (exit $ac_status); } &&
11442 { ac_try='test -s conftest.$ac_objext'
11443 { (eval echo "$as_me:11443: \"$ac_try\"") >&5
11444 (eval $ac_try) 2>&5
11446 echo "$as_me:11446: \$? = $ac_status" >&5
11447 (exit $ac_status); }; }; then
11448 cf_cv_term_header=$cf_header
11451 echo "$as_me: failed program was:" >&5
11452 cat conftest.$ac_ext >&5
11453 cf_cv_term_header=no
11455 rm -f conftest.$ac_objext conftest.$ac_ext
11458 case $cf_cv_term_header in #(vi
11460 # If curses is ncurses, some packagers still mess it up by trying to make
11461 # us use GNU termcap. This handles the most common case.
11462 for cf_header in ncurses/term.h ncursesw/term.h
11464 cat >conftest.$ac_ext <<_ACEOF
11465 #line 11465 "configure"
11466 #include "confdefs.h"
11468 #include <${cf_cv_ncurses_header:-curses.h}>
11469 #ifdef NCURSES_VERSION
11470 #include <${cf_header}>
11482 rm -f conftest.$ac_objext
11483 if { (eval echo "$as_me:11483: \"$ac_compile\"") >&5
11484 (eval $ac_compile) 2>&5
11486 echo "$as_me:11486: \$? = $ac_status" >&5
11487 (exit $ac_status); } &&
11488 { ac_try='test -s conftest.$ac_objext'
11489 { (eval echo "$as_me:11489: \"$ac_try\"") >&5
11490 (eval $ac_try) 2>&5
11492 echo "$as_me:11492: \$? = $ac_status" >&5
11493 (exit $ac_status); }; }; then
11494 cf_cv_term_header=$cf_header
11497 echo "$as_me: failed program was:" >&5
11498 cat conftest.$ac_ext >&5
11499 cf_cv_term_header=no
11501 rm -f conftest.$ac_objext conftest.$ac_ext
11507 echo "$as_me:11507: result: $cf_cv_term_header" >&5
11508 echo "${ECHO_T}$cf_cv_term_header" >&6
11510 case $cf_cv_term_header in #(vi
11512 cat >>confdefs.h <<\EOF
11513 #define HAVE_TERM_H 1
11517 ncurses/term.h) #(vi
11518 cat >>confdefs.h <<\EOF
11519 #define HAVE_NCURSES_TERM_H 1
11524 cat >>confdefs.h <<\EOF
11525 #define HAVE_NCURSESW_TERM_H 1
11556 use_default_colors \
11565 cf_tr_func=`echo "$cf_func" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
11567 echo "$as_me:11567: checking for ${cf_func}" >&5
11568 echo $ECHO_N "checking for ${cf_func}... $ECHO_C" >&6
11570 echo "${as_me:-configure}:11570: testing ${cf_func} ..." 1>&5
11572 if eval "test \"\${cf_cv_func_$cf_func+set}\" = set"; then
11573 echo $ECHO_N "(cached) $ECHO_C" >&6
11576 eval cf_result='$ac_cv_func_'$cf_func
11577 if test ".$cf_result" != ".no"; then
11578 cat >conftest.$ac_ext <<_ACEOF
11579 #line 11579 "configure"
11580 #include "confdefs.h"
11582 #ifdef HAVE_XCURSES
11583 #include <xcurses.h>
11584 char * XCursesProgramName = "test";
11586 #include <${cf_cv_ncurses_header:-curses.h}>
11587 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
11588 #include <ncursesw/term.h>
11589 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
11590 #include <ncurses/term.h>
11591 #elif defined(HAVE_TERM_H)
11601 long foo = (long)(&${cf_func});
11602 ${cf_cv_main_return:-return}(foo == 0);
11609 rm -f conftest.$ac_objext conftest$ac_exeext
11610 if { (eval echo "$as_me:11610: \"$ac_link\"") >&5
11611 (eval $ac_link) 2>&5
11613 echo "$as_me:11613: \$? = $ac_status" >&5
11614 (exit $ac_status); } &&
11615 { ac_try='test -s conftest$ac_exeext'
11616 { (eval echo "$as_me:11616: \"$ac_try\"") >&5
11617 (eval $ac_try) 2>&5
11619 echo "$as_me:11619: \$? = $ac_status" >&5
11620 (exit $ac_status); }; }; then
11623 echo "$as_me: failed program was:" >&5
11624 cat conftest.$ac_ext >&5
11627 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11629 eval 'cf_cv_func_'$cf_func'=$cf_result'
11633 # use the computed/retrieved cache-value:
11634 eval 'cf_result=$cf_cv_func_'$cf_func
11635 echo "$as_me:11635: result: $cf_result" >&5
11636 echo "${ECHO_T}$cf_result" >&6
11637 if test $cf_result != no; then
11638 cat >>confdefs.h <<EOF
11639 #define HAVE_${cf_tr_func} 1
11645 echo "$as_me:11645: checking for ncurses extended functions" >&5
11646 echo $ECHO_N "checking for ncurses extended functions... $ECHO_C" >&6
11647 if test "${cf_cv_ncurses_ext_funcs+set}" = set; then
11648 echo $ECHO_N "(cached) $ECHO_C" >&6
11651 cat >conftest.$ac_ext <<_ACEOF
11652 #line 11652 "configure"
11653 #include "confdefs.h"
11655 #include <${cf_cv_ncurses_header:-curses.h}>
11660 int x = NCURSES_EXT_FUNCS
11666 rm -f conftest.$ac_objext
11667 if { (eval echo "$as_me:11667: \"$ac_compile\"") >&5
11668 (eval $ac_compile) 2>&5
11670 echo "$as_me:11670: \$? = $ac_status" >&5
11671 (exit $ac_status); } &&
11672 { ac_try='test -s conftest.$ac_objext'
11673 { (eval echo "$as_me:11673: \"$ac_try\"") >&5
11674 (eval $ac_try) 2>&5
11676 echo "$as_me:11676: \$? = $ac_status" >&5
11677 (exit $ac_status); }; }; then
11678 cf_cv_ncurses_ext_funcs=defined
11680 echo "$as_me: failed program was:" >&5
11681 cat conftest.$ac_ext >&5
11683 cat >conftest.$ac_ext <<_ACEOF
11684 #line 11684 "configure"
11685 #include "confdefs.h"
11687 #include <${cf_cv_ncurses_header:-curses.h}>
11692 (void) assume_default_colors (0, 0);
11693 (void) curses_version ();
11694 (void) define_key (0, 0);
11695 (void) is_term_resized (0, 0);
11696 (void) key_defined (0);
11697 (void) keybound (0, 0);
11698 (void) keyok (0, 0);
11699 (void) resize_term (0, 0);
11700 (void) resizeterm (0, 0);
11701 (void) use_default_colors ();
11702 (void) use_extended_names (0);
11703 (void) wresize (0, 0, 0);
11708 rm -f conftest.$ac_objext conftest$ac_exeext
11709 if { (eval echo "$as_me:11709: \"$ac_link\"") >&5
11710 (eval $ac_link) 2>&5
11712 echo "$as_me:11712: \$? = $ac_status" >&5
11713 (exit $ac_status); } &&
11714 { ac_try='test -s conftest$ac_exeext'
11715 { (eval echo "$as_me:11715: \"$ac_try\"") >&5
11716 (eval $ac_try) 2>&5
11718 echo "$as_me:11718: \$? = $ac_status" >&5
11719 (exit $ac_status); }; }; then
11720 cf_cv_ncurses_ext_funcs=yes
11722 echo "$as_me: failed program was:" >&5
11723 cat conftest.$ac_ext >&5
11724 cf_cv_ncurses_ext_funcs=no
11726 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11729 rm -f conftest.$ac_objext conftest.$ac_ext
11732 echo "$as_me:11732: result: $cf_cv_ncurses_ext_funcs" >&5
11733 echo "${ECHO_T}$cf_cv_ncurses_ext_funcs" >&6
11734 test "$cf_cv_ncurses_ext_funcs" == yes && cat >>confdefs.h <<\EOF
11735 #define NCURSES_EXT_FUNCS 1
11738 echo "$as_me:11738: checking for wide-character functions" >&5
11739 echo $ECHO_N "checking for wide-character functions... $ECHO_C" >&6
11740 if test "${cf_cv_widechar_funcs+set}" = set; then
11741 echo $ECHO_N "(cached) $ECHO_C" >&6
11744 cat >conftest.$ac_ext <<_ACEOF
11745 #line 11745 "configure"
11746 #include "confdefs.h"
11748 #include <${cf_cv_ncurses_header:-curses.h}>
11753 static wchar_t src_wchar[2];
11754 static cchar_t dst_cchar;
11755 setcchar(&dst_cchar, src_wchar, A_NORMAL, 0, (void *) 0);
11761 rm -f conftest.$ac_objext conftest$ac_exeext
11762 if { (eval echo "$as_me:11762: \"$ac_link\"") >&5
11763 (eval $ac_link) 2>&5
11765 echo "$as_me:11765: \$? = $ac_status" >&5
11766 (exit $ac_status); } &&
11767 { ac_try='test -s conftest$ac_exeext'
11768 { (eval echo "$as_me:11768: \"$ac_try\"") >&5
11769 (eval $ac_try) 2>&5
11771 echo "$as_me:11771: \$? = $ac_status" >&5
11772 (exit $ac_status); }; }; then
11773 cf_cv_widechar_funcs=yes
11775 echo "$as_me: failed program was:" >&5
11776 cat conftest.$ac_ext >&5
11777 cf_cv_widechar_funcs=no
11779 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11782 echo "$as_me:11782: result: $cf_cv_widechar_funcs" >&5
11783 echo "${ECHO_T}$cf_cv_widechar_funcs" >&6
11784 if test "$cf_cv_widechar_funcs" != no ; then
11785 cat >>confdefs.h <<\EOF
11786 #define USE_WIDEC_SUPPORT 1
11790 cat >>confdefs.h <<\EOF
11791 #define USE_WIDEC_SUPPORT 0
11796 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
11798 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
11799 inttypes.h stdint.h unistd.h
11801 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
11802 echo "$as_me:11802: checking for $ac_header" >&5
11803 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
11804 if eval "test \"\${$as_ac_Header+set}\" = set"; then
11805 echo $ECHO_N "(cached) $ECHO_C" >&6
11807 cat >conftest.$ac_ext <<_ACEOF
11808 #line 11808 "configure"
11809 #include "confdefs.h"
11810 $ac_includes_default
11811 #include <$ac_header>
11813 rm -f conftest.$ac_objext
11814 if { (eval echo "$as_me:11814: \"$ac_compile\"") >&5
11815 (eval $ac_compile) 2>&5
11817 echo "$as_me:11817: \$? = $ac_status" >&5
11818 (exit $ac_status); } &&
11819 { ac_try='test -s conftest.$ac_objext'
11820 { (eval echo "$as_me:11820: \"$ac_try\"") >&5
11821 (eval $ac_try) 2>&5
11823 echo "$as_me:11823: \$? = $ac_status" >&5
11824 (exit $ac_status); }; }; then
11825 eval "$as_ac_Header=yes"
11827 echo "$as_me: failed program was:" >&5
11828 cat conftest.$ac_ext >&5
11829 eval "$as_ac_Header=no"
11831 rm -f conftest.$ac_objext conftest.$ac_ext
11833 echo "$as_me:11833: result: `eval echo '${'$as_ac_Header'}'`" >&5
11834 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
11835 if test `eval echo '${'$as_ac_Header'}'` = yes; then
11836 cat >>confdefs.h <<EOF
11837 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
11843 echo "$as_me:11843: checking for pid_t" >&5
11844 echo $ECHO_N "checking for pid_t... $ECHO_C" >&6
11845 if test "${ac_cv_type_pid_t+set}" = set; then
11846 echo $ECHO_N "(cached) $ECHO_C" >&6
11848 cat >conftest.$ac_ext <<_ACEOF
11849 #line 11849 "configure"
11850 #include "confdefs.h"
11851 $ac_includes_default
11857 if (sizeof (pid_t))
11863 rm -f conftest.$ac_objext
11864 if { (eval echo "$as_me:11864: \"$ac_compile\"") >&5
11865 (eval $ac_compile) 2>&5
11867 echo "$as_me:11867: \$? = $ac_status" >&5
11868 (exit $ac_status); } &&
11869 { ac_try='test -s conftest.$ac_objext'
11870 { (eval echo "$as_me:11870: \"$ac_try\"") >&5
11871 (eval $ac_try) 2>&5
11873 echo "$as_me:11873: \$? = $ac_status" >&5
11874 (exit $ac_status); }; }; then
11875 ac_cv_type_pid_t=yes
11877 echo "$as_me: failed program was:" >&5
11878 cat conftest.$ac_ext >&5
11879 ac_cv_type_pid_t=no
11881 rm -f conftest.$ac_objext conftest.$ac_ext
11883 echo "$as_me:11883: result: $ac_cv_type_pid_t" >&5
11884 echo "${ECHO_T}$ac_cv_type_pid_t" >&6
11885 if test $ac_cv_type_pid_t = yes; then
11889 cat >>confdefs.h <<EOF
11895 for ac_header in unistd.h vfork.h
11897 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
11898 echo "$as_me:11898: checking for $ac_header" >&5
11899 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
11900 if eval "test \"\${$as_ac_Header+set}\" = set"; then
11901 echo $ECHO_N "(cached) $ECHO_C" >&6
11903 cat >conftest.$ac_ext <<_ACEOF
11904 #line 11904 "configure"
11905 #include "confdefs.h"
11906 #include <$ac_header>
11908 if { (eval echo "$as_me:11908: \"$ac_cpp conftest.$ac_ext\"") >&5
11909 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11911 egrep -v '^ *\+' conftest.er1 >conftest.err
11913 cat conftest.err >&5
11914 echo "$as_me:11914: \$? = $ac_status" >&5
11915 (exit $ac_status); } >/dev/null; then
11916 if test -s conftest.err; then
11917 ac_cpp_err=$ac_c_preproc_warn_flag
11924 if test -z "$ac_cpp_err"; then
11925 eval "$as_ac_Header=yes"
11927 echo "$as_me: failed program was:" >&5
11928 cat conftest.$ac_ext >&5
11929 eval "$as_ac_Header=no"
11931 rm -f conftest.err conftest.$ac_ext
11933 echo "$as_me:11933: result: `eval echo '${'$as_ac_Header'}'`" >&5
11934 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
11935 if test `eval echo '${'$as_ac_Header'}'` = yes; then
11936 cat >>confdefs.h <<EOF
11937 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
11943 for ac_func in fork vfork
11945 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11946 echo "$as_me:11946: checking for $ac_func" >&5
11947 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11948 if eval "test \"\${$as_ac_var+set}\" = set"; then
11949 echo $ECHO_N "(cached) $ECHO_C" >&6
11951 cat >conftest.$ac_ext <<_ACEOF
11952 #line 11952 "configure"
11953 #include "confdefs.h"
11954 /* System header to define __stub macros and hopefully few prototypes,
11955 which can conflict with char $ac_func (); below. */
11956 #include <assert.h>
11957 /* Override any gcc2 internal prototype to avoid an error. */
11961 /* We use char because int might match the return type of a gcc2
11962 builtin and then its argument prototype would still apply. */
11969 /* The GNU C library defines this for functions which it implements
11970 to always fail with ENOSYS. Some functions are actually named
11971 something starting with __ and the normal name is an alias. */
11972 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
11982 rm -f conftest.$ac_objext conftest$ac_exeext
11983 if { (eval echo "$as_me:11983: \"$ac_link\"") >&5
11984 (eval $ac_link) 2>&5
11986 echo "$as_me:11986: \$? = $ac_status" >&5
11987 (exit $ac_status); } &&
11988 { ac_try='test -s conftest$ac_exeext'
11989 { (eval echo "$as_me:11989: \"$ac_try\"") >&5
11990 (eval $ac_try) 2>&5
11992 echo "$as_me:11992: \$? = $ac_status" >&5
11993 (exit $ac_status); }; }; then
11994 eval "$as_ac_var=yes"
11996 echo "$as_me: failed program was:" >&5
11997 cat conftest.$ac_ext >&5
11998 eval "$as_ac_var=no"
12000 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12002 echo "$as_me:12002: result: `eval echo '${'$as_ac_var'}'`" >&5
12003 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12004 if test `eval echo '${'$as_ac_var'}'` = yes; then
12005 cat >>confdefs.h <<EOF
12006 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12012 ac_cv_func_fork_works=$ac_cv_func_fork
12013 if test "x$ac_cv_func_fork" = xyes; then
12014 echo "$as_me:12014: checking for working fork" >&5
12015 echo $ECHO_N "checking for working fork... $ECHO_C" >&6
12016 if test "${ac_cv_func_fork_works+set}" = set; then
12017 echo $ECHO_N "(cached) $ECHO_C" >&6
12019 if test "$cross_compiling" = yes; then
12020 ac_cv_func_fork_works=cross
12022 cat >conftest.$ac_ext <<_ACEOF
12023 /* By Rüdiger Kuhlmann. */
12024 #include <sys/types.h>
12026 # include <unistd.h>
12028 /* Some systems only have a dummy stub for fork() */
12032 $ac_main_return (1);
12033 $ac_main_return (0);
12036 rm -f 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); } && { ac_try='./conftest$ac_exeext'
12042 { (eval echo "$as_me:12042: \"$ac_try\"") >&5
12043 (eval $ac_try) 2>&5
12045 echo "$as_me:12045: \$? = $ac_status" >&5
12046 (exit $ac_status); }; }; then
12047 ac_cv_func_fork_works=yes
12049 echo "$as_me: program exited with status $ac_status" >&5
12050 echo "$as_me: failed program was:" >&5
12051 cat conftest.$ac_ext >&5
12052 ac_cv_func_fork_works=no
12054 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
12057 echo "$as_me:12057: result: $ac_cv_func_fork_works" >&5
12058 echo "${ECHO_T}$ac_cv_func_fork_works" >&6
12061 if test "x$ac_cv_func_fork_works" = xcross; then
12063 *-*-amigaos* | *-*-msdosdjgpp*)
12064 # Override, as these systems have only a dummy fork() stub
12065 ac_cv_func_fork_works=no
12068 ac_cv_func_fork_works=yes
12071 { echo "$as_me:12071: WARNING: CROSS: Result $ac_cv_func_fork_works guessed due to cross-compiling." >&5
12072 echo "$as_me: WARNING: CROSS: Result $ac_cv_func_fork_works guessed due to cross-compiling." >&2;}
12074 ac_cv_func_vfork_works=$ac_cv_func_vfork
12075 if test "x$ac_cv_func_vfork" = xyes; then
12076 echo "$as_me:12076: checking for working vfork" >&5
12077 echo $ECHO_N "checking for working vfork... $ECHO_C" >&6
12078 if test "${ac_cv_func_vfork_works+set}" = set; then
12079 echo $ECHO_N "(cached) $ECHO_C" >&6
12081 if test "$cross_compiling" = yes; then
12082 ac_cv_func_vfork_works=cross
12084 cat >conftest.$ac_ext <<_ACEOF
12085 #line 12085 "configure"
12086 #include "confdefs.h"
12087 /* Thanks to Paul Eggert for this test. */
12089 #include <sys/types.h>
12090 #include <sys/stat.h>
12092 # include <unistd.h>
12095 # include <vfork.h>
12097 /* On some sparc systems, changes by the child to local and incoming
12098 argument registers are propagated back to the parent. The compiler
12099 is told about this with #include <vfork.h>, but some compilers
12100 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
12101 static variable whose address is put into a register that is
12102 clobbered by the vfork. */
12105 sparc_address_test (int arg)
12107 sparc_address_test (arg) int arg;
12110 static pid_t child;
12128 pid_t parent = getpid ();
12131 sparc_address_test ();
12136 /* Here is another test for sparc vfork register problems. This
12137 test uses lots of local variables, at least as many local
12138 variables as main has allocated so far including compiler
12139 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
12140 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
12141 reuse the register of parent for one of the local variables,
12142 since it will think that parent can't possibly be used any more
12143 in this routine. Assigning to the local variable will thus
12144 munge parent in the parent process. */
12146 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
12147 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
12148 /* Convince the compiler that p..p7 are live; otherwise, it might
12149 use the same hardware register for all 8 local variables. */
12150 if (p != p1 || p != p2 || p != p3 || p != p4
12151 || p != p5 || p != p6 || p != p7)
12154 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
12155 from child file descriptors. If the child closes a descriptor
12156 before it execs or exits, this munges the parent's descriptor
12157 as well. Test for this by closing stdout in the child. */
12158 _exit(close(fileno(stdout)) != 0);
12163 while (wait(&status) != child)
12166 /* Was there some problem with vforking? */
12169 /* Did the child fail? (This shouldn't happen.) */
12172 /* Did the vfork/compiler bug occur? */
12173 || parent != getpid()
12175 /* Did the file descriptor bug occur? */
12176 || fstat(fileno(stdout), &st) != 0
12181 rm -f conftest$ac_exeext
12182 if { (eval echo "$as_me:12182: \"$ac_link\"") >&5
12183 (eval $ac_link) 2>&5
12185 echo "$as_me:12185: \$? = $ac_status" >&5
12186 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
12187 { (eval echo "$as_me:12187: \"$ac_try\"") >&5
12188 (eval $ac_try) 2>&5
12190 echo "$as_me:12190: \$? = $ac_status" >&5
12191 (exit $ac_status); }; }; then
12192 ac_cv_func_vfork_works=yes
12194 echo "$as_me: program exited with status $ac_status" >&5
12195 echo "$as_me: failed program was:" >&5
12196 cat conftest.$ac_ext >&5
12197 ac_cv_func_vfork_works=no
12199 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
12202 echo "$as_me:12202: result: $ac_cv_func_vfork_works" >&5
12203 echo "${ECHO_T}$ac_cv_func_vfork_works" >&6
12206 if test "x$ac_cv_func_fork_works" = xcross; then
12207 ac_cv_func_vfork_works=ac_cv_func_vfork
12208 { echo "$as_me:12208: WARNING: CROSS: Result $ac_cv_func_vfork_works guessed due to cross-compiling." >&5
12209 echo "$as_me: WARNING: CROSS: Result $ac_cv_func_vfork_works guessed due to cross-compiling." >&2;}
12212 if test "x$ac_cv_func_vfork_works" = xyes; then
12214 cat >>confdefs.h <<\EOF
12215 #define HAVE_WORKING_VFORK 1
12220 cat >>confdefs.h <<\EOF
12225 if test "x$ac_cv_func_fork_works" = xyes; then
12227 cat >>confdefs.h <<\EOF
12228 #define HAVE_WORKING_FORK 1
12233 echo "$as_me:12233: checking if sys/time.h works with sys/select.h" >&5
12234 echo $ECHO_N "checking if sys/time.h works with sys/select.h... $ECHO_C" >&6
12235 if test "${cf_cv_sys_time_select+set}" = set; then
12236 echo $ECHO_N "(cached) $ECHO_C" >&6
12239 cat >conftest.$ac_ext <<_ACEOF
12240 #line 12240 "configure"
12241 #include "confdefs.h"
12243 #include <sys/types.h>
12244 #ifdef HAVE_SYS_TIME_H
12245 #include <sys/time.h>
12247 #ifdef HAVE_SYS_SELECT_H
12248 #include <sys/select.h>
12259 rm -f conftest.$ac_objext
12260 if { (eval echo "$as_me:12260: \"$ac_compile\"") >&5
12261 (eval $ac_compile) 2>&5
12263 echo "$as_me:12263: \$? = $ac_status" >&5
12264 (exit $ac_status); } &&
12265 { ac_try='test -s conftest.$ac_objext'
12266 { (eval echo "$as_me:12266: \"$ac_try\"") >&5
12267 (eval $ac_try) 2>&5
12269 echo "$as_me:12269: \$? = $ac_status" >&5
12270 (exit $ac_status); }; }; then
12271 cf_cv_sys_time_select=yes
12273 echo "$as_me: failed program was:" >&5
12274 cat conftest.$ac_ext >&5
12275 cf_cv_sys_time_select=no
12277 rm -f conftest.$ac_objext conftest.$ac_ext
12281 echo "$as_me:12281: result: $cf_cv_sys_time_select" >&5
12282 echo "${ECHO_T}$cf_cv_sys_time_select" >&6
12283 test "$cf_cv_sys_time_select" = yes && cat >>confdefs.h <<\EOF
12284 #define HAVE_SYS_TIME_SELECT 1
12287 echo "$as_me:12287: checking for function curses_version" >&5
12288 echo $ECHO_N "checking for function curses_version... $ECHO_C" >&6
12289 if test "${cf_cv_func_curses_version+set}" = set; then
12290 echo $ECHO_N "(cached) $ECHO_C" >&6
12293 if test "$cross_compiling" = yes; then
12294 cf_cv_func_curses_version=unknown
12296 cat >conftest.$ac_ext <<_ACEOF
12297 #line 12297 "configure"
12298 #include "confdefs.h"
12300 #include <${cf_cv_ncurses_header:-curses.h}>
12304 sprintf(temp, "%s\n", curses_version());
12305 ${cf_cv_main_return:-return}(0);
12309 rm -f conftest$ac_exeext
12310 if { (eval echo "$as_me:12310: \"$ac_link\"") >&5
12311 (eval $ac_link) 2>&5
12313 echo "$as_me:12313: \$? = $ac_status" >&5
12314 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
12315 { (eval echo "$as_me:12315: \"$ac_try\"") >&5
12316 (eval $ac_try) 2>&5
12318 echo "$as_me:12318: \$? = $ac_status" >&5
12319 (exit $ac_status); }; }; then
12320 cf_cv_func_curses_version=yes
12323 echo "$as_me: program exited with status $ac_status" >&5
12324 echo "$as_me: failed program was:" >&5
12325 cat conftest.$ac_ext >&5
12326 cf_cv_func_curses_version=no
12329 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
12333 echo "$as_me:12333: result: $cf_cv_func_curses_version" >&5
12334 echo "${ECHO_T}$cf_cv_func_curses_version" >&6
12335 test "$cf_cv_func_curses_version" = yes && cat >>confdefs.h <<\EOF
12336 #define HAVE_CURSES_VERSION 1
12339 echo "$as_me:12339: checking for ncurses wrap-prefix" >&5
12340 echo $ECHO_N "checking for ncurses wrap-prefix... $ECHO_C" >&6
12342 # Check whether --with-ncurses-wrap-prefix or --without-ncurses-wrap-prefix was given.
12343 if test "${with_ncurses_wrap_prefix+set}" = set; then
12344 withval="$with_ncurses_wrap_prefix"
12345 NCURSES_WRAP_PREFIX=$withval
12347 NCURSES_WRAP_PREFIX=_nc_
12349 echo "$as_me:12349: result: $NCURSES_WRAP_PREFIX" >&5
12350 echo "${ECHO_T}$NCURSES_WRAP_PREFIX" >&6
12352 echo "$as_me:12352: checking for alternate character set array" >&5
12353 echo $ECHO_N "checking for alternate character set array... $ECHO_C" >&6
12354 if test "${cf_cv_curses_acs_map+set}" = set; then
12355 echo $ECHO_N "(cached) $ECHO_C" >&6
12358 cf_cv_curses_acs_map=unknown
12359 for name in acs_map _acs_map __acs_map ${NCURSES_WRAP_PREFIX}acs_map
12361 cat >conftest.$ac_ext <<_ACEOF
12362 #line 12362 "configure"
12363 #include "confdefs.h"
12365 #include <${cf_cv_ncurses_header:-curses.h}>
12371 $name['k'] = ACS_PLUS
12377 rm -f conftest.$ac_objext conftest$ac_exeext
12378 if { (eval echo "$as_me:12378: \"$ac_link\"") >&5
12379 (eval $ac_link) 2>&5
12381 echo "$as_me:12381: \$? = $ac_status" >&5
12382 (exit $ac_status); } &&
12383 { ac_try='test -s conftest$ac_exeext'
12384 { (eval echo "$as_me:12384: \"$ac_try\"") >&5
12385 (eval $ac_try) 2>&5
12387 echo "$as_me:12387: \$? = $ac_status" >&5
12388 (exit $ac_status); }; }; then
12389 cf_cv_curses_acs_map=$name; break
12391 echo "$as_me: failed program was:" >&5
12392 cat conftest.$ac_ext >&5
12394 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12398 echo "$as_me:12398: result: $cf_cv_curses_acs_map" >&5
12399 echo "${ECHO_T}$cf_cv_curses_acs_map" >&6
12401 test "$cf_cv_curses_acs_map" != unknown && cat >>confdefs.h <<EOF
12402 #define CURSES_ACS_ARRAY $cf_cv_curses_acs_map
12405 echo "$as_me:12405: checking for wide alternate character set array" >&5
12406 echo $ECHO_N "checking for wide alternate character set array... $ECHO_C" >&6
12407 if test "${cf_cv_curses_wacs_map+set}" = set; then
12408 echo $ECHO_N "(cached) $ECHO_C" >&6
12411 cf_cv_curses_wacs_map=unknown
12412 for name in wacs_map _wacs_map __wacs_map _nc_wacs
12414 cat >conftest.$ac_ext <<_ACEOF
12415 #line 12415 "configure"
12416 #include "confdefs.h"
12418 #ifndef _XOPEN_SOURCE_EXTENDED
12419 #define _XOPEN_SOURCE_EXTENDED
12421 #include <${cf_cv_ncurses_header:-curses.h}>
12425 $name['k'] = *WACS_PLUS
12430 rm -f conftest.$ac_objext conftest$ac_exeext
12431 if { (eval echo "$as_me:12431: \"$ac_link\"") >&5
12432 (eval $ac_link) 2>&5
12434 echo "$as_me:12434: \$? = $ac_status" >&5
12435 (exit $ac_status); } &&
12436 { ac_try='test -s conftest$ac_exeext'
12437 { (eval echo "$as_me:12437: \"$ac_try\"") >&5
12438 (eval $ac_try) 2>&5
12440 echo "$as_me:12440: \$? = $ac_status" >&5
12441 (exit $ac_status); }; }; then
12442 cf_cv_curses_wacs_map=$name
12445 echo "$as_me: failed program was:" >&5
12446 cat conftest.$ac_ext >&5
12448 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12451 echo "$as_me:12451: result: $cf_cv_curses_wacs_map" >&5
12452 echo "${ECHO_T}$cf_cv_curses_wacs_map" >&6
12454 echo "$as_me:12454: checking for type attr_t in ${cf_cv_ncurses_header:-curses.h}" >&5
12455 echo $ECHO_N "checking for type attr_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
12456 cat >conftest.$ac_ext <<_ACEOF
12457 #line 12457 "configure"
12458 #include "confdefs.h"
12460 #ifndef _XOPEN_SOURCE_EXTENDED
12461 #define _XOPEN_SOURCE_EXTENDED
12463 #include <${cf_cv_ncurses_header:-curses.h}>
12474 rm -f conftest.$ac_objext
12475 if { (eval echo "$as_me:12475: \"$ac_compile\"") >&5
12476 (eval $ac_compile) 2>&5
12478 echo "$as_me:12478: \$? = $ac_status" >&5
12479 (exit $ac_status); } &&
12480 { ac_try='test -s conftest.$ac_objext'
12481 { (eval echo "$as_me:12481: \"$ac_try\"") >&5
12482 (eval $ac_try) 2>&5
12484 echo "$as_me:12484: \$? = $ac_status" >&5
12485 (exit $ac_status); }; }; then
12488 echo "$as_me: failed program was:" >&5
12489 cat conftest.$ac_ext >&5
12492 rm -f conftest.$ac_objext conftest.$ac_ext
12493 echo "$as_me:12493: result: $cf_result" >&5
12494 echo "${ECHO_T}$cf_result" >&6
12495 if test $cf_result = yes ; then
12497 cf_result=`echo "have_type_attr_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
12499 cat >>confdefs.h <<EOF
12500 #define $cf_result 1
12504 cat >>confdefs.h <<EOF
12505 #define attr_t long
12510 # This is needed on Tru64 5.0 to declare mbstate_t
12511 echo "$as_me:12511: checking if we must include wchar.h to declare mbstate_t" >&5
12512 echo $ECHO_N "checking if we must include wchar.h to declare mbstate_t... $ECHO_C" >&6
12513 if test "${cf_cv_mbstate_t+set}" = set; then
12514 echo $ECHO_N "(cached) $ECHO_C" >&6
12517 cat >conftest.$ac_ext <<_ACEOF
12518 #line 12518 "configure"
12519 #include "confdefs.h"
12521 #include <stdlib.h>
12522 #include <stdarg.h>
12524 #ifdef HAVE_LIBUTF8_H
12525 #include <libutf8.h>
12535 rm -f conftest.$ac_objext
12536 if { (eval echo "$as_me:12536: \"$ac_compile\"") >&5
12537 (eval $ac_compile) 2>&5
12539 echo "$as_me:12539: \$? = $ac_status" >&5
12540 (exit $ac_status); } &&
12541 { ac_try='test -s conftest.$ac_objext'
12542 { (eval echo "$as_me:12542: \"$ac_try\"") >&5
12543 (eval $ac_try) 2>&5
12545 echo "$as_me:12545: \$? = $ac_status" >&5
12546 (exit $ac_status); }; }; then
12549 echo "$as_me: failed program was:" >&5
12550 cat conftest.$ac_ext >&5
12551 cat >conftest.$ac_ext <<_ACEOF
12552 #line 12552 "configure"
12553 #include "confdefs.h"
12555 #include <stdlib.h>
12556 #include <stdarg.h>
12559 #ifdef HAVE_LIBUTF8_H
12560 #include <libutf8.h>
12570 rm -f conftest.$ac_objext
12571 if { (eval echo "$as_me:12571: \"$ac_compile\"") >&5
12572 (eval $ac_compile) 2>&5
12574 echo "$as_me:12574: \$? = $ac_status" >&5
12575 (exit $ac_status); } &&
12576 { ac_try='test -s conftest.$ac_objext'
12577 { (eval echo "$as_me:12577: \"$ac_try\"") >&5
12578 (eval $ac_try) 2>&5
12580 echo "$as_me:12580: \$? = $ac_status" >&5
12581 (exit $ac_status); }; }; then
12582 cf_cv_mbstate_t=yes
12584 echo "$as_me: failed program was:" >&5
12585 cat conftest.$ac_ext >&5
12586 cf_cv_mbstate_t=unknown
12588 rm -f conftest.$ac_objext conftest.$ac_ext
12590 rm -f conftest.$ac_objext conftest.$ac_ext
12592 echo "$as_me:12592: result: $cf_cv_mbstate_t" >&5
12593 echo "${ECHO_T}$cf_cv_mbstate_t" >&6
12595 if test "$cf_cv_mbstate_t" = yes ; then
12596 cat >>confdefs.h <<\EOF
12597 #define NEED_WCHAR_H 1
12603 # if we do not find mbstate_t in either place, use substitution to provide a fallback.
12604 if test "$cf_cv_mbstate_t" = unknown ; then
12605 NCURSES_MBSTATE_T=1
12608 # if we find mbstate_t in either place, use substitution to provide a fallback.
12609 if test "$cf_cv_mbstate_t" != unknown ; then
12610 NCURSES_OK_MBSTATE_T=1
12613 # This is needed on Tru64 5.0 to declare wchar_t
12614 echo "$as_me:12614: checking if we must include wchar.h to declare wchar_t" >&5
12615 echo $ECHO_N "checking if we must include wchar.h to declare wchar_t... $ECHO_C" >&6
12616 if test "${cf_cv_wchar_t+set}" = set; then
12617 echo $ECHO_N "(cached) $ECHO_C" >&6
12620 cat >conftest.$ac_ext <<_ACEOF
12621 #line 12621 "configure"
12622 #include "confdefs.h"
12624 #include <stdlib.h>
12625 #include <stdarg.h>
12627 #ifdef HAVE_LIBUTF8_H
12628 #include <libutf8.h>
12638 rm -f conftest.$ac_objext
12639 if { (eval echo "$as_me:12639: \"$ac_compile\"") >&5
12640 (eval $ac_compile) 2>&5
12642 echo "$as_me:12642: \$? = $ac_status" >&5
12643 (exit $ac_status); } &&
12644 { ac_try='test -s conftest.$ac_objext'
12645 { (eval echo "$as_me:12645: \"$ac_try\"") >&5
12646 (eval $ac_try) 2>&5
12648 echo "$as_me:12648: \$? = $ac_status" >&5
12649 (exit $ac_status); }; }; then
12652 echo "$as_me: failed program was:" >&5
12653 cat conftest.$ac_ext >&5
12654 cat >conftest.$ac_ext <<_ACEOF
12655 #line 12655 "configure"
12656 #include "confdefs.h"
12658 #include <stdlib.h>
12659 #include <stdarg.h>
12662 #ifdef HAVE_LIBUTF8_H
12663 #include <libutf8.h>
12673 rm -f conftest.$ac_objext
12674 if { (eval echo "$as_me:12674: \"$ac_compile\"") >&5
12675 (eval $ac_compile) 2>&5
12677 echo "$as_me:12677: \$? = $ac_status" >&5
12678 (exit $ac_status); } &&
12679 { ac_try='test -s conftest.$ac_objext'
12680 { (eval echo "$as_me:12680: \"$ac_try\"") >&5
12681 (eval $ac_try) 2>&5
12683 echo "$as_me:12683: \$? = $ac_status" >&5
12684 (exit $ac_status); }; }; then
12687 echo "$as_me: failed program was:" >&5
12688 cat conftest.$ac_ext >&5
12689 cf_cv_wchar_t=unknown
12691 rm -f conftest.$ac_objext conftest.$ac_ext
12693 rm -f conftest.$ac_objext conftest.$ac_ext
12695 echo "$as_me:12695: result: $cf_cv_wchar_t" >&5
12696 echo "${ECHO_T}$cf_cv_wchar_t" >&6
12698 if test "$cf_cv_wchar_t" = yes ; then
12699 cat >>confdefs.h <<\EOF
12700 #define NEED_WCHAR_H 1
12706 # if we do not find wchar_t in either place, use substitution to provide a fallback.
12707 if test "$cf_cv_wchar_t" = unknown ; then
12711 # if we find wchar_t in either place, use substitution to provide a fallback.
12712 if test "$cf_cv_wchar_t" != unknown ; then
12713 NCURSES_OK_WCHAR_T=1
12716 # This is needed on Tru64 5.0 to declare wint_t
12717 echo "$as_me:12717: checking if we must include wchar.h to declare wint_t" >&5
12718 echo $ECHO_N "checking if we must include wchar.h to declare wint_t... $ECHO_C" >&6
12719 if test "${cf_cv_wint_t+set}" = set; then
12720 echo $ECHO_N "(cached) $ECHO_C" >&6
12723 cat >conftest.$ac_ext <<_ACEOF
12724 #line 12724 "configure"
12725 #include "confdefs.h"
12727 #include <stdlib.h>
12728 #include <stdarg.h>
12730 #ifdef HAVE_LIBUTF8_H
12731 #include <libutf8.h>
12741 rm -f conftest.$ac_objext
12742 if { (eval echo "$as_me:12742: \"$ac_compile\"") >&5
12743 (eval $ac_compile) 2>&5
12745 echo "$as_me:12745: \$? = $ac_status" >&5
12746 (exit $ac_status); } &&
12747 { ac_try='test -s conftest.$ac_objext'
12748 { (eval echo "$as_me:12748: \"$ac_try\"") >&5
12749 (eval $ac_try) 2>&5
12751 echo "$as_me:12751: \$? = $ac_status" >&5
12752 (exit $ac_status); }; }; then
12755 echo "$as_me: failed program was:" >&5
12756 cat conftest.$ac_ext >&5
12757 cat >conftest.$ac_ext <<_ACEOF
12758 #line 12758 "configure"
12759 #include "confdefs.h"
12761 #include <stdlib.h>
12762 #include <stdarg.h>
12765 #ifdef HAVE_LIBUTF8_H
12766 #include <libutf8.h>
12776 rm -f conftest.$ac_objext
12777 if { (eval echo "$as_me:12777: \"$ac_compile\"") >&5
12778 (eval $ac_compile) 2>&5
12780 echo "$as_me:12780: \$? = $ac_status" >&5
12781 (exit $ac_status); } &&
12782 { ac_try='test -s conftest.$ac_objext'
12783 { (eval echo "$as_me:12783: \"$ac_try\"") >&5
12784 (eval $ac_try) 2>&5
12786 echo "$as_me:12786: \$? = $ac_status" >&5
12787 (exit $ac_status); }; }; then
12790 echo "$as_me: failed program was:" >&5
12791 cat conftest.$ac_ext >&5
12792 cf_cv_wint_t=unknown
12794 rm -f conftest.$ac_objext conftest.$ac_ext
12796 rm -f conftest.$ac_objext conftest.$ac_ext
12798 echo "$as_me:12798: result: $cf_cv_wint_t" >&5
12799 echo "${ECHO_T}$cf_cv_wint_t" >&6
12801 if test "$cf_cv_wint_t" = yes ; then
12802 cat >>confdefs.h <<\EOF
12803 #define NEED_WCHAR_H 1
12809 # if we do not find wint_t in either place, use substitution to provide a fallback.
12810 if test "$cf_cv_wint_t" = unknown ; then
12814 # if we find wint_t in either place, use substitution to provide a fallback.
12815 if test "$cf_cv_wint_t" != unknown ; then
12816 NCURSES_OK_WINT_T=1
12819 if test "$NCURSES_OK_MBSTATE_T" = 0 ; then
12821 echo "$as_me:12821: checking for type mbstate_t in ${cf_cv_ncurses_header:-curses.h}" >&5
12822 echo $ECHO_N "checking for type mbstate_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
12823 cat >conftest.$ac_ext <<_ACEOF
12824 #line 12824 "configure"
12825 #include "confdefs.h"
12827 #ifndef _XOPEN_SOURCE_EXTENDED
12828 #define _XOPEN_SOURCE_EXTENDED
12830 #include <${cf_cv_ncurses_header:-curses.h}>
12841 rm -f conftest.$ac_objext
12842 if { (eval echo "$as_me:12842: \"$ac_compile\"") >&5
12843 (eval $ac_compile) 2>&5
12845 echo "$as_me:12845: \$? = $ac_status" >&5
12846 (exit $ac_status); } &&
12847 { ac_try='test -s conftest.$ac_objext'
12848 { (eval echo "$as_me:12848: \"$ac_try\"") >&5
12849 (eval $ac_try) 2>&5
12851 echo "$as_me:12851: \$? = $ac_status" >&5
12852 (exit $ac_status); }; }; then
12855 echo "$as_me: failed program was:" >&5
12856 cat conftest.$ac_ext >&5
12859 rm -f conftest.$ac_objext conftest.$ac_ext
12860 echo "$as_me:12860: result: $cf_result" >&5
12861 echo "${ECHO_T}$cf_result" >&6
12862 if test $cf_result = yes ; then
12864 cf_result=`echo "have_type_mbstate_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
12866 cat >>confdefs.h <<EOF
12867 #define $cf_result 1
12871 cat >>confdefs.h <<EOF
12872 #define mbstate_t long
12879 if test "$NCURSES_OK_WCHAR_T" = 0 ; then
12881 echo "$as_me:12881: checking for type wchar_t in ${cf_cv_ncurses_header:-curses.h}" >&5
12882 echo $ECHO_N "checking for type wchar_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
12883 cat >conftest.$ac_ext <<_ACEOF
12884 #line 12884 "configure"
12885 #include "confdefs.h"
12887 #ifndef _XOPEN_SOURCE_EXTENDED
12888 #define _XOPEN_SOURCE_EXTENDED
12890 #include <${cf_cv_ncurses_header:-curses.h}>
12901 rm -f conftest.$ac_objext
12902 if { (eval echo "$as_me:12902: \"$ac_compile\"") >&5
12903 (eval $ac_compile) 2>&5
12905 echo "$as_me:12905: \$? = $ac_status" >&5
12906 (exit $ac_status); } &&
12907 { ac_try='test -s conftest.$ac_objext'
12908 { (eval echo "$as_me:12908: \"$ac_try\"") >&5
12909 (eval $ac_try) 2>&5
12911 echo "$as_me:12911: \$? = $ac_status" >&5
12912 (exit $ac_status); }; }; then
12915 echo "$as_me: failed program was:" >&5
12916 cat conftest.$ac_ext >&5
12919 rm -f conftest.$ac_objext conftest.$ac_ext
12920 echo "$as_me:12920: result: $cf_result" >&5
12921 echo "${ECHO_T}$cf_result" >&6
12922 if test $cf_result = yes ; then
12924 cf_result=`echo "have_type_wchar_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
12926 cat >>confdefs.h <<EOF
12927 #define $cf_result 1
12931 cat >>confdefs.h <<EOF
12932 #define wchar_t long
12939 if test "$NCURSES_OK_WINT_T" = 0 ; then
12941 echo "$as_me:12941: checking for type wint_t in ${cf_cv_ncurses_header:-curses.h}" >&5
12942 echo $ECHO_N "checking for type wint_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
12943 cat >conftest.$ac_ext <<_ACEOF
12944 #line 12944 "configure"
12945 #include "confdefs.h"
12947 #ifndef _XOPEN_SOURCE_EXTENDED
12948 #define _XOPEN_SOURCE_EXTENDED
12950 #include <${cf_cv_ncurses_header:-curses.h}>
12961 rm -f conftest.$ac_objext
12962 if { (eval echo "$as_me:12962: \"$ac_compile\"") >&5
12963 (eval $ac_compile) 2>&5
12965 echo "$as_me:12965: \$? = $ac_status" >&5
12966 (exit $ac_status); } &&
12967 { ac_try='test -s conftest.$ac_objext'
12968 { (eval echo "$as_me:12968: \"$ac_try\"") >&5
12969 (eval $ac_try) 2>&5
12971 echo "$as_me:12971: \$? = $ac_status" >&5
12972 (exit $ac_status); }; }; then
12975 echo "$as_me: failed program was:" >&5
12976 cat conftest.$ac_ext >&5
12979 rm -f conftest.$ac_objext conftest.$ac_ext
12980 echo "$as_me:12980: result: $cf_result" >&5
12981 echo "${ECHO_T}$cf_result" >&6
12982 if test $cf_result = yes ; then
12984 cf_result=`echo "have_type_wint_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
12986 cat >>confdefs.h <<EOF
12987 #define $cf_result 1
12991 cat >>confdefs.h <<EOF
12992 #define wint_t long
12999 echo "$as_me:12999: checking for data boolnames declaration in ${cf_cv_ncurses_header:-curses.h}" >&5
13000 echo $ECHO_N "checking for data boolnames declaration in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
13001 cat >conftest.$ac_ext <<_ACEOF
13002 #line 13002 "configure"
13003 #include "confdefs.h"
13005 #ifdef HAVE_XCURSES
13006 #include <xcurses.h>
13007 char * XCursesProgramName = "test";
13009 #include <${cf_cv_ncurses_header:-curses.h}>
13010 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
13011 #include <ncursesw/term.h>
13012 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
13013 #include <ncurses/term.h>
13014 #elif defined(HAVE_TERM_H)
13023 void *foo = &(boolnames)
13029 rm -f conftest.$ac_objext
13030 if { (eval echo "$as_me:13030: \"$ac_compile\"") >&5
13031 (eval $ac_compile) 2>&5
13033 echo "$as_me:13033: \$? = $ac_status" >&5
13034 (exit $ac_status); } &&
13035 { ac_try='test -s conftest.$ac_objext'
13036 { (eval echo "$as_me:13036: \"$ac_try\"") >&5
13037 (eval $ac_try) 2>&5
13039 echo "$as_me:13039: \$? = $ac_status" >&5
13040 (exit $ac_status); }; }; then
13043 echo "$as_me: failed program was:" >&5
13044 cat conftest.$ac_ext >&5
13047 rm -f conftest.$ac_objext conftest.$ac_ext
13048 echo "$as_me:13048: result: $cf_result" >&5
13049 echo "${ECHO_T}$cf_result" >&6
13050 if test $cf_result = yes ; then
13052 cf_result=`echo "have_curses_data_boolnames" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
13054 cat >>confdefs.h <<EOF
13055 #define $cf_result 1
13059 echo "$as_me:13059: checking for data boolnames in library" >&5
13060 echo $ECHO_N "checking for data boolnames in library... $ECHO_C" >&6
13061 cat >conftest.$ac_ext <<_ACEOF
13062 #line 13062 "configure"
13063 #include "confdefs.h"
13065 #ifdef HAVE_XCURSES
13066 #include <xcurses.h>
13067 char * XCursesProgramName = "test";
13069 #include <${cf_cv_ncurses_header:-curses.h}>
13070 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
13071 #include <ncursesw/term.h>
13072 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
13073 #include <ncurses/term.h>
13074 #elif defined(HAVE_TERM_H)
13079 extern char boolnames;
13085 void *foo = &(boolnames);
13086 ${cf_cv_main_return:-return}(foo == 0);
13093 rm -f conftest.$ac_objext conftest$ac_exeext
13094 if { (eval echo "$as_me:13094: \"$ac_link\"") >&5
13095 (eval $ac_link) 2>&5
13097 echo "$as_me:13097: \$? = $ac_status" >&5
13098 (exit $ac_status); } &&
13099 { ac_try='test -s conftest$ac_exeext'
13100 { (eval echo "$as_me:13100: \"$ac_try\"") >&5
13101 (eval $ac_try) 2>&5
13103 echo "$as_me:13103: \$? = $ac_status" >&5
13104 (exit $ac_status); }; }; then
13107 echo "$as_me: failed program was:" >&5
13108 cat conftest.$ac_ext >&5
13111 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13112 echo "$as_me:13112: result: $cf_result" >&5
13113 echo "${ECHO_T}$cf_result" >&6
13114 if test $cf_result = yes ; then
13116 cf_result=`echo "decl_curses_data_boolnames" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
13118 cat >>confdefs.h <<EOF
13119 #define $cf_result 1
13125 echo "$as_me:13125: checking for data boolfnames declaration in ${cf_cv_ncurses_header:-curses.h}" >&5
13126 echo $ECHO_N "checking for data boolfnames declaration in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
13127 cat >conftest.$ac_ext <<_ACEOF
13128 #line 13128 "configure"
13129 #include "confdefs.h"
13131 #ifdef HAVE_XCURSES
13132 #include <xcurses.h>
13133 char * XCursesProgramName = "test";
13135 #include <${cf_cv_ncurses_header:-curses.h}>
13136 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
13137 #include <ncursesw/term.h>
13138 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
13139 #include <ncurses/term.h>
13140 #elif defined(HAVE_TERM_H)
13149 void *foo = &(boolfnames)
13155 rm -f conftest.$ac_objext
13156 if { (eval echo "$as_me:13156: \"$ac_compile\"") >&5
13157 (eval $ac_compile) 2>&5
13159 echo "$as_me:13159: \$? = $ac_status" >&5
13160 (exit $ac_status); } &&
13161 { ac_try='test -s conftest.$ac_objext'
13162 { (eval echo "$as_me:13162: \"$ac_try\"") >&5
13163 (eval $ac_try) 2>&5
13165 echo "$as_me:13165: \$? = $ac_status" >&5
13166 (exit $ac_status); }; }; then
13169 echo "$as_me: failed program was:" >&5
13170 cat conftest.$ac_ext >&5
13173 rm -f conftest.$ac_objext conftest.$ac_ext
13174 echo "$as_me:13174: result: $cf_result" >&5
13175 echo "${ECHO_T}$cf_result" >&6
13176 if test $cf_result = yes ; then
13178 cf_result=`echo "have_curses_data_boolfnames" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
13180 cat >>confdefs.h <<EOF
13181 #define $cf_result 1
13185 echo "$as_me:13185: checking for data boolfnames in library" >&5
13186 echo $ECHO_N "checking for data boolfnames in library... $ECHO_C" >&6
13187 cat >conftest.$ac_ext <<_ACEOF
13188 #line 13188 "configure"
13189 #include "confdefs.h"
13191 #ifdef HAVE_XCURSES
13192 #include <xcurses.h>
13193 char * XCursesProgramName = "test";
13195 #include <${cf_cv_ncurses_header:-curses.h}>
13196 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
13197 #include <ncursesw/term.h>
13198 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
13199 #include <ncurses/term.h>
13200 #elif defined(HAVE_TERM_H)
13205 extern char boolfnames;
13211 void *foo = &(boolfnames);
13212 ${cf_cv_main_return:-return}(foo == 0);
13219 rm -f conftest.$ac_objext conftest$ac_exeext
13220 if { (eval echo "$as_me:13220: \"$ac_link\"") >&5
13221 (eval $ac_link) 2>&5
13223 echo "$as_me:13223: \$? = $ac_status" >&5
13224 (exit $ac_status); } &&
13225 { ac_try='test -s conftest$ac_exeext'
13226 { (eval echo "$as_me:13226: \"$ac_try\"") >&5
13227 (eval $ac_try) 2>&5
13229 echo "$as_me:13229: \$? = $ac_status" >&5
13230 (exit $ac_status); }; }; then
13233 echo "$as_me: failed program was:" >&5
13234 cat conftest.$ac_ext >&5
13237 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13238 echo "$as_me:13238: result: $cf_result" >&5
13239 echo "${ECHO_T}$cf_result" >&6
13240 if test $cf_result = yes ; then
13242 cf_result=`echo "decl_curses_data_boolfnames" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
13244 cat >>confdefs.h <<EOF
13245 #define $cf_result 1
13254 ac_config_files="$ac_config_files Makefile"
13255 ac_config_commands="$ac_config_commands default"
13256 cat >confcache <<\_ACEOF
13257 # This file is a shell script that caches the results of configure
13258 # tests run on this system so they can be shared between configure
13259 # scripts and configure runs, see configure's option --config-cache.
13260 # It is not useful on other systems. If it contains results you don't
13261 # want to keep, you may remove or edit it.
13263 # config.status only pays attention to the cache file if you give it
13264 # the --recheck option to rerun configure.
13266 # `ac_cv_env_foo' variables (set or unset) will be overriden when
13267 # loading this file, other *unset* `ac_cv_foo' will be assigned the
13268 # following values.
13272 # The following way of writing the cache mishandles newlines in values,
13273 # but we know of no workaround that is simple, portable, and efficient.
13274 # So, don't put newlines in cache variables' values.
13275 # Ultrix sh set writes to stderr and can't be redirected directly,
13276 # and sets the high bit in the cache file unless we assign to the vars.
13279 case `(ac_space=' '; set | grep ac_space) 2>&1` in
13281 # `set' does not quote correctly, so add quotes (double-quote
13282 # substitution turns \\\\ into \\, and sed turns \\ into \).
13285 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
13288 # `set' quotes correctly as required by POSIX, so do not add quotes.
13290 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
13297 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
13299 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
13301 if cmp -s $cache_file confcache; then :; else
13302 if test -w $cache_file; then
13303 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
13304 cat confcache >$cache_file
13306 echo "not updating unwritable cache $cache_file"
13311 test "x$prefix" = xNONE && prefix=$ac_default_prefix
13312 # Let make expand exec_prefix.
13313 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
13315 # VPATH may cause trouble with some makes, so we remove $(srcdir),
13316 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
13317 # trailing colons and then remove the whole line if VPATH becomes empty
13318 # (actually we leave an empty line to preserve line numbers).
13319 if test "x$srcdir" = x.; then
13320 ac_vpsub='/^[ ]*VPATH[ ]*=/{
13321 s/:*\$(srcdir):*/:/;
13322 s/:*\${srcdir}:*/:/;
13324 s/^\([^=]*=[ ]*\):*/\1/;
13330 DEFS=-DHAVE_CONFIG_H
13332 : ${CONFIG_STATUS=./config.status}
13333 ac_clean_files_save=$ac_clean_files
13334 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
13335 { echo "$as_me:13335: creating $CONFIG_STATUS" >&5
13336 echo "$as_me: creating $CONFIG_STATUS" >&6;}
13337 cat >$CONFIG_STATUS <<_ACEOF
13339 # Generated automatically by configure.
13340 # Run this file to recreate the current configuration.
13341 # Compiler output produced by configure, useful for debugging
13342 # configure, is in config.log if it exists.
13345 SHELL=\${CONFIG_SHELL-$SHELL}
13346 ac_cs_invocation="\$0 \$@"
13350 cat >>$CONFIG_STATUS <<\_ACEOF
13351 # Be Bourne compatible
13352 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
13355 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
13359 # Name of the executable.
13360 as_me=`echo "$0" |sed 's,.*[\\/],,'`
13362 if expr a : '\(a\)' >/dev/null 2>&1; then
13368 rm -f conf$$ conf$$.exe conf$$.file
13370 if ln -s conf$$.file conf$$ 2>/dev/null; then
13371 # We could just check for DJGPP; but this test a) works b) is more generic
13372 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
13373 if test -f conf$$.exe; then
13374 # Don't use ln at all; we don't have any links
13379 elif ln conf$$.file conf$$ 2>/dev/null; then
13384 rm -f conf$$ conf$$.exe conf$$.file
13386 as_executable_p="test -f"
13388 # Support unset when possible.
13389 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
13396 $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
13397 $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
13398 $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
13399 $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
13400 $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
13401 $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
13402 $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
13403 $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
13406 # We need space, tab and new line, in precisely that order.
13412 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
13418 # Files that config.status was made for.
13419 if test -n "$ac_config_files"; then
13420 echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
13423 if test -n "$ac_config_headers"; then
13424 echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
13427 if test -n "$ac_config_links"; then
13428 echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
13431 if test -n "$ac_config_commands"; then
13432 echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
13435 cat >>$CONFIG_STATUS <<\EOF
13438 \`$as_me' instantiates files from templates according to the
13439 current configuration.
13441 Usage: $0 [OPTIONS] [FILE]...
13443 -h, --help print this help, then exit
13444 -V, --version print version number, then exit
13445 -d, --debug don't remove temporary files
13446 --recheck update $as_me by reconfiguring in the same conditions
13447 --file=FILE[:TEMPLATE]
13448 instantiate the configuration file FILE
13449 --header=FILE[:TEMPLATE]
13450 instantiate the configuration header FILE
13452 Configuration files:
13455 Configuration headers:
13458 Configuration commands:
13461 Report bugs to <dickey@invisible-island.net>."
13464 cat >>$CONFIG_STATUS <<EOF
13467 configured by $0, generated by GNU Autoconf 2.52.20101001,
13468 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
13470 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
13471 Free Software Foundation, Inc.
13472 This config.status script is free software; the Free Software Foundation
13473 gives unlimited permission to copy, distribute and modify it."
13477 cat >>$CONFIG_STATUS <<\EOF
13478 # If no file are specified by the user, then we need to provide default
13479 # value. By we need to know if files were specified by the user.
13485 ac_option=`expr "x$1" : 'x\([^=]*\)='`
13486 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
13488 set dummy "$ac_option" "$ac_optarg" ${1+"$@"}
13492 *) # This is not an option, so the user has probably given explicit
13494 ac_need_defaults=false;;
13498 # Handling of the options.
13500 cat >>$CONFIG_STATUS <<EOF
13501 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
13502 echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion"
13503 exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;;
13505 cat >>$CONFIG_STATUS <<\EOF
13506 --version | --vers* | -V )
13507 echo "$ac_cs_version"; exit 0 ;;
13509 # Conflict between --help and --header
13510 { { echo "$as_me:13510: error: ambiguous option: $1
13511 Try \`$0 --help' for more information." >&5
13512 echo "$as_me: error: ambiguous option: $1
13513 Try \`$0 --help' for more information." >&2;}
13514 { (exit 1); exit 1; }; };;
13515 --help | --hel | -h )
13516 echo "$ac_cs_usage"; exit 0 ;;
13517 --debug | --d* | -d )
13519 --file | --fil | --fi | --f )
13521 CONFIG_FILES="$CONFIG_FILES $1"
13522 ac_need_defaults=false;;
13523 --header | --heade | --head | --hea )
13525 CONFIG_HEADERS="$CONFIG_HEADERS $1"
13526 ac_need_defaults=false;;
13528 # This is an error.
13529 -*) { { echo "$as_me:13529: error: unrecognized option: $1
13530 Try \`$0 --help' for more information." >&5
13531 echo "$as_me: error: unrecognized option: $1
13532 Try \`$0 --help' for more information." >&2;}
13533 { (exit 1); exit 1; }; } ;;
13535 *) ac_config_targets="$ac_config_targets $1" ;;
13544 ## ----------------------- ##
13545 ## Running config.status. ##
13546 ## ----------------------- ##
13548 This file was extended by $as_me 2.52.20101001, executed with
13549 CONFIG_FILES = $CONFIG_FILES
13550 CONFIG_HEADERS = $CONFIG_HEADERS
13551 CONFIG_LINKS = $CONFIG_LINKS
13552 CONFIG_COMMANDS = $CONFIG_COMMANDS
13553 > $ac_cs_invocation
13554 on `(hostname || uname -n) 2>/dev/null | sed 1q`
13559 cat >>$CONFIG_STATUS <<EOF
13561 # INIT-COMMANDS section.
13569 cat >>$CONFIG_STATUS <<\EOF
13570 for ac_config_target in $ac_config_targets
13572 case "$ac_config_target" in
13573 # Handling of arguments.
13574 "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
13575 "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
13576 "ncurses_cfg.h" ) CONFIG_HEADERS="$CONFIG_HEADERS ncurses_cfg.h:ncurses_tst.hin" ;;
13577 *) { { echo "$as_me:13577: error: invalid argument: $ac_config_target" >&5
13578 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
13579 { (exit 1); exit 1; }; };;
13583 # If the user did not use the arguments to specify the items to instantiate,
13584 # then the envvar interface is used. Set only those that are not.
13585 # We use the long form for the default assignment because of an extremely
13586 # bizarre bug on SunOS 4.1.3.
13587 if $ac_need_defaults; then
13588 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
13589 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
13590 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
13593 # Create a temporary directory, and hook for its removal unless debugging.
13596 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
13597 trap '{ (exit 1); exit 1; }' 1 2 13 15
13600 # Create a (secure) tmp directory for tmp files.
13603 tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` &&
13604 test -n "$tmp" && test -d "$tmp"
13607 tmp=$TMPDIR/cs$$-$RANDOM
13608 (umask 077 && mkdir $tmp)
13611 echo "$me: cannot create a temporary directory in $TMPDIR" >&2
13612 { (exit 1); exit 1; }
13617 cat >>$CONFIG_STATUS <<EOF
13620 # CONFIG_FILES section.
13623 # No need to generate the scripts if there are no CONFIG_FILES.
13624 # This happens for instance when ./config.status config.h
13625 if test -n "\$CONFIG_FILES"; then
13626 # Protect against being on the right side of a sed subst in config.status.
13627 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
13628 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
13629 s,@SHELL@,$SHELL,;t t
13630 s,@exec_prefix@,$exec_prefix,;t t
13631 s,@prefix@,$prefix,;t t
13632 s,@program_transform_name@,$program_transform_name,;t t
13633 s,@bindir@,$bindir,;t t
13634 s,@sbindir@,$sbindir,;t t
13635 s,@libexecdir@,$libexecdir,;t t
13636 s,@datadir@,$datadir,;t t
13637 s,@sysconfdir@,$sysconfdir,;t t
13638 s,@sharedstatedir@,$sharedstatedir,;t t
13639 s,@localstatedir@,$localstatedir,;t t
13640 s,@libdir@,$libdir,;t t
13641 s,@includedir@,$includedir,;t t
13642 s,@oldincludedir@,$oldincludedir,;t t
13643 s,@infodir@,$infodir,;t t
13644 s,@mandir@,$mandir,;t t
13645 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
13646 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
13647 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
13648 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
13649 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
13650 s,@build_alias@,$build_alias,;t t
13651 s,@host_alias@,$host_alias,;t t
13652 s,@target_alias@,$target_alias,;t t
13653 s,@ECHO_C@,$ECHO_C,;t t
13654 s,@ECHO_N@,$ECHO_N,;t t
13655 s,@ECHO_T@,$ECHO_T,;t t
13656 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
13657 s,@DEFS@,$DEFS,;t t
13658 s,@LIBS@,$LIBS,;t t
13659 s,@build@,$build,;t t
13660 s,@build_cpu@,$build_cpu,;t t
13661 s,@build_vendor@,$build_vendor,;t t
13662 s,@build_os@,$build_os,;t t
13663 s,@host@,$host,;t t
13664 s,@host_cpu@,$host_cpu,;t t
13665 s,@host_vendor@,$host_vendor,;t t
13666 s,@host_os@,$host_os,;t t
13667 s,@SET_MAKE@,$SET_MAKE,;t t
13669 s,@CFLAGS@,$CFLAGS,;t t
13670 s,@LDFLAGS@,$LDFLAGS,;t t
13671 s,@CPPFLAGS@,$CPPFLAGS,;t t
13672 s,@ac_ct_CC@,$ac_ct_CC,;t t
13673 s,@EXEEXT@,$EXEEXT,;t t
13674 s,@OBJEXT@,$OBJEXT,;t t
13677 s,@CTAGS@,$CTAGS,;t t
13678 s,@ETAGS@,$ETAGS,;t t
13679 s,@MAKE_LOWER_TAGS@,$MAKE_LOWER_TAGS,;t t
13680 s,@MAKE_UPPER_TAGS@,$MAKE_UPPER_TAGS,;t t
13681 s,@CC_G_OPT@,$CC_G_OPT,;t t
13682 s,@CC_SHARED_OPTS@,$CC_SHARED_OPTS,;t t
13683 s,@DFT_DEP_SUFFIX@,$DFT_DEP_SUFFIX,;t t
13684 s,@DFT_OBJ_SUBDIR@,$DFT_OBJ_SUBDIR,;t t
13685 s,@DFT_UPR_MODEL@,$DFT_UPR_MODEL,;t t
13687 s,@LDFLAGS_SHARED@,$LDFLAGS_SHARED,;t t
13688 s,@LDFLAGS_STATIC@,$LDFLAGS_STATIC,;t t
13689 s,@LD_MODEL@,$LD_MODEL,;t t
13690 s,@LD_SHARED_OPTS@,$LD_SHARED_OPTS,;t t
13691 s,@LIBTOOL@,$LIBTOOL,;t t
13692 s,@LIB_CLEAN@,$LIB_CLEAN,;t t
13693 s,@LIB_COMPILE@,$LIB_COMPILE,;t t
13694 s,@LIB_LINK@,$LIB_LINK,;t t
13695 s,@LINK_TESTS@,$LINK_TESTS,;t t
13696 s,@LINT@,$LINT,;t t
13697 s,@LINT_OPTS@,$LINT_OPTS,;t t
13698 s,@LOCAL_LDFLAGS@,$LOCAL_LDFLAGS,;t t
13699 s,@MATH_LIB@,$MATH_LIB,;t t
13700 s,@PTHREAD@,$PTHREAD,;t t
13701 s,@TEST_ARGS@,$TEST_ARGS,;t t
13702 s,@TEST_DEPS@,$TEST_DEPS,;t t
13703 s,@TEST_LIBS@,$TEST_LIBS,;t t
13704 s,@TINFO_ARGS@,$TINFO_ARGS,;t t
13705 s,@cf_cv_abi_version@,$cf_cv_abi_version,;t t
13706 s,@cf_cv_rel_version@,$cf_cv_rel_version,;t t
13707 s,@EXTRA_CPPFLAGS@,$EXTRA_CPPFLAGS,;t t
13708 s,@ECHO_LT@,$ECHO_LT,;t t
13709 s,@ECHO_LD@,$ECHO_LD,;t t
13710 s,@RULE_CC@,$RULE_CC,;t t
13711 s,@SHOW_CC@,$SHOW_CC,;t t
13712 s,@ECHO_CC@,$ECHO_CC,;t t
13713 s,@EXTRA_CFLAGS@,$EXTRA_CFLAGS,;t t
13714 s,@NCURSES_CONFIG@,$NCURSES_CONFIG,;t t
13715 s,@PKG_CONFIG@,$PKG_CONFIG,;t t
13716 s,@X_CFLAGS@,$X_CFLAGS,;t t
13717 s,@X_PRE_LIBS@,$X_PRE_LIBS,;t t
13718 s,@X_LIBS@,$X_LIBS,;t t
13719 s,@X_EXTRA_LIBS@,$X_EXTRA_LIBS,;t t
13720 s,@XCURSES_CONFIG@,$XCURSES_CONFIG,;t t
13721 s,@NCURSES_WRAP_PREFIX@,$NCURSES_WRAP_PREFIX,;t t
13726 cat >>$CONFIG_STATUS <<\EOF
13727 # Split the substitutions into bite-sized pieces for seds with
13728 # small command number limits, like on Digital OSF/1 and HP-UX.
13729 ac_max_sed_lines=48
13730 ac_sed_frag=1 # Number of current file.
13731 ac_beg=1 # First line for current file.
13732 ac_end=$ac_max_sed_lines # Line after last line for current file.
13735 while $ac_more_lines; do
13736 if test $ac_beg -gt 1; then
13737 sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
13739 sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
13741 if test ! -s $tmp/subs.frag; then
13742 ac_more_lines=false
13744 # The purpose of the label and of the branching condition is to
13745 # speed up the sed processing (if there are no `@' at all, there
13746 # is no need to browse any of the substitutions).
13747 # These are the two extra sed commands mentioned above.
13749 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
13750 if test -z "$ac_sed_cmds"; then
13751 ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
13753 ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
13755 ac_sed_frag=`expr $ac_sed_frag + 1`
13757 ac_end=`expr $ac_end + $ac_max_sed_lines`
13760 if test -z "$ac_sed_cmds"; then
13763 fi # test -n "$CONFIG_FILES"
13766 cat >>$CONFIG_STATUS <<\EOF
13767 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
13768 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
13770 - | *:- | *:-:* ) # input from stdin
13772 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
13773 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
13774 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
13775 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
13776 * ) ac_file_in=$ac_file.in ;;
13779 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
13780 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
13781 X"$ac_file" : 'X\(//\)[^/]' \| \
13782 X"$ac_file" : 'X\(//\)$' \| \
13783 X"$ac_file" : 'X\(/\)' \| \
13784 . : '\(.\)' 2>/dev/null ||
13786 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
13787 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
13788 /^X\(\/\/\)$/{ s//\1/; q; }
13789 /^X\(\/\).*/{ s//\1/; q; }
13791 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
13792 { case "$ac_dir" in
13793 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
13797 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
13798 case $as_mkdir_dir in
13799 # Skip DOS drivespec
13800 ?:) as_incr_dir=$as_mkdir_dir ;;
13802 as_incr_dir=$as_incr_dir/$as_mkdir_dir
13803 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
13808 ac_dir_suffix="/`echo $ac_dir|sed 's,^\./,,'`"
13809 # A "../" for each directory in $ac_dir_suffix.
13810 ac_dots=`echo "$ac_dir_suffix" | sed 's,/[^/]*,../,g'`
13812 ac_dir_suffix= ac_dots=
13817 if test -z "$ac_dots"; then
13820 ac_top_srcdir=`echo $ac_dots | sed 's,/$,,'`
13822 [\\/]* | ?:[\\/]* )
13823 ac_srcdir=$srcdir$ac_dir_suffix;
13824 ac_top_srcdir=$srcdir ;;
13825 *) # Relative path.
13826 ac_srcdir=$ac_dots$srcdir$ac_dir_suffix
13827 ac_top_srcdir=$ac_dots$srcdir ;;
13830 if test x"$ac_file" != x-; then
13831 { echo "$as_me:13831: creating $ac_file" >&5
13832 echo "$as_me: creating $ac_file" >&6;}
13835 # Let's still pretend it is `configure' which instantiates (i.e., don't
13836 # use $as_me), people would be surprised to read:
13837 # /* config.h. Generated automatically by config.status. */
13838 configure_input="Generated automatically from `echo $ac_file_in |
13839 sed 's,.*/,,'` by configure."
13841 # First look for the input files in the build tree, otherwise in the
13843 ac_file_inputs=`IFS=:
13844 for f in $ac_file_in; do
13846 -) echo $tmp/stdin ;;
13848 # Absolute (can't be DOS-style, as IFS=:)
13849 test -f "$f" || { { echo "$as_me:13849: error: cannot find input file: $f" >&5
13850 echo "$as_me: error: cannot find input file: $f" >&2;}
13851 { (exit 1); exit 1; }; }
13854 if test -f "$f"; then
13857 elif test -f "$srcdir/$f"; then
13862 { { echo "$as_me:13862: error: cannot find input file: $f" >&5
13863 echo "$as_me: error: cannot find input file: $f" >&2;}
13864 { (exit 1); exit 1; }; }
13867 done` || { (exit 1); exit 1; }
13869 cat >>$CONFIG_STATUS <<EOF
13873 cat >>$CONFIG_STATUS <<\EOF
13875 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
13876 s,@configure_input@,$configure_input,;t t
13877 s,@srcdir@,$ac_srcdir,;t t
13878 s,@top_srcdir@,$ac_top_srcdir,;t t
13879 " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
13881 if test x"$ac_file" != x-; then
13882 mv $tmp/out $ac_file
13890 cat >>$CONFIG_STATUS <<\EOF
13893 # CONFIG_HEADER section.
13896 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
13897 # NAME is the cpp macro being defined and VALUE is the value it is being given.
13899 # ac_d sets the value in "#define NAME VALUE" lines.
13900 ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
13901 ac_dB='[ ].*$,\1#\2'
13904 # ac_i turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
13905 ac_iA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
13906 ac_iB='\([ ]\),\1#\2define\3'
13909 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
13910 ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
13911 ac_uB='$,\1#\2define\3'
13915 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
13916 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
13918 - | *:- | *:-:* ) # input from stdin
13920 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
13921 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
13922 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
13923 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
13924 * ) ac_file_in=$ac_file.in ;;
13927 test x"$ac_file" != x- && { echo "$as_me:13927: creating $ac_file" >&5
13928 echo "$as_me: creating $ac_file" >&6;}
13930 # First look for the input files in the build tree, otherwise in the
13932 ac_file_inputs=`IFS=:
13933 for f in $ac_file_in; do
13935 -) echo $tmp/stdin ;;
13937 # Absolute (can't be DOS-style, as IFS=:)
13938 test -f "$f" || { { echo "$as_me:13938: error: cannot find input file: $f" >&5
13939 echo "$as_me: error: cannot find input file: $f" >&2;}
13940 { (exit 1); exit 1; }; }
13943 if test -f "$f"; then
13946 elif test -f "$srcdir/$f"; then
13951 { { echo "$as_me:13951: error: cannot find input file: $f" >&5
13952 echo "$as_me: error: cannot find input file: $f" >&2;}
13953 { (exit 1); exit 1; }; }
13956 done` || { (exit 1); exit 1; }
13957 # Remove the trailing spaces.
13958 sed 's/[ ]*$//' $ac_file_inputs >$tmp/in
13962 # Transform confdefs.h into a list of #define's. We won't use it as a sed
13963 # script, but as data to insert where we see @DEFS@. We expect AC_SAVE_DEFS to
13964 # be either 'cat' or 'sort'.
13965 cat confdefs.h | uniq >conftest.vals
13967 # Break up conftest.vals because some shells have a limit on
13968 # the size of here documents, and old seds have small limits too.
13970 rm -f conftest.tail
13971 echo ' rm -f conftest.frag' >> $CONFIG_STATUS
13972 while grep . conftest.vals >/dev/null
13974 # Write chunks of a limited-size here document to conftest.frag.
13975 echo ' cat >> conftest.frag <<CEOF' >> $CONFIG_STATUS
13976 sed ${ac_max_here_lines}q conftest.vals | sed -e 's/#ifdef.*/#if 0/' >> $CONFIG_STATUS
13977 echo 'CEOF' >> $CONFIG_STATUS
13978 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
13979 rm -f conftest.vals
13980 mv conftest.tail conftest.vals
13982 rm -f conftest.vals
13984 # Run sed to substitute the contents of conftest.frag into $tmp/in at the
13986 echo ' cat >> conftest.edit <<CEOF
13987 /@DEFS@/r conftest.frag
13990 sed -f conftest.edit $tmp/in > $tmp/out
13992 mv $tmp/out $tmp/in
13993 rm -f conftest.edit conftest.frag
13994 ' >> $CONFIG_STATUS
13996 cat >>$CONFIG_STATUS <<\EOF
13997 # Let's still pretend it is `configure' which instantiates (i.e., don't
13998 # use $as_me), people would be surprised to read:
13999 # /* config.h. Generated automatically by config.status. */
14000 if test x"$ac_file" = x-; then
14001 echo "/* Generated automatically by configure. */" >$tmp/config.h
14003 echo "/* $ac_file. Generated automatically by configure. */" >$tmp/config.h
14005 cat $tmp/in >>$tmp/config.h
14007 if test x"$ac_file" != x-; then
14008 if cmp -s $ac_file $tmp/config.h 2>/dev/null; then
14009 { echo "$as_me:14009: $ac_file is unchanged" >&5
14010 echo "$as_me: $ac_file is unchanged" >&6;}
14012 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
14013 X"$ac_file" : 'X\(//\)[^/]' \| \
14014 X"$ac_file" : 'X\(//\)$' \| \
14015 X"$ac_file" : 'X\(/\)' \| \
14016 . : '\(.\)' 2>/dev/null ||
14018 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
14019 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
14020 /^X\(\/\/\)$/{ s//\1/; q; }
14021 /^X\(\/\).*/{ s//\1/; q; }
14023 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
14024 { case "$ac_dir" in
14025 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
14029 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
14030 case $as_mkdir_dir in
14031 # Skip DOS drivespec
14032 ?:) as_incr_dir=$as_mkdir_dir ;;
14034 as_incr_dir=$as_incr_dir/$as_mkdir_dir
14035 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
14042 mv $tmp/config.h $ac_file
14046 rm -f $tmp/config.h
14050 cat >>$CONFIG_STATUS <<\EOF
14052 # CONFIG_COMMANDS section.
14054 for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
14055 ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
14056 ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
14063 if test ! -d $srcdir/$cf_dir; then
14065 elif test -f $srcdir/$cf_dir/programs; then
14066 $AWK -f $srcdir/mk-test.awk ECHO_LINK="$ECHO_LD" $srcdir/$cf_dir/programs >>$cf_dir/Makefile
14070 cat >>Makefile <<TEST_EOF
14072 # These rules are generated so we do not rely on suffix rules, which do not
14073 # work consistently for different make-programs (the '\$(MODEL)/' confuses
14074 # some, and the '\$x' confuses others).
14076 LIST=`sed -e 's/[ ].*//' -e '/^[#@]/d' $srcdir/modules`
14079 cat >>Makefile <<TEST_EOF
14081 \$(MODEL)/$N.o : $N.c \\
14084 @echo compiling $N; \$(CC) -c \$(CFLAGS_DEFAULT) $N.c
14092 cat >>$CONFIG_STATUS <<\EOF
14094 { (exit 0); exit 0; }
14096 chmod +x $CONFIG_STATUS
14097 ac_clean_files=$ac_clean_files_save
14099 # configure is writing to config.log, and then calls config.status.
14100 # config.status does its own redirection, appending to config.log.
14101 # Unfortunately, on DOS this fails, as config.log is still kept open
14102 # by configure, so config.status won't be able to write to it; its
14103 # output is simply discarded. So we exec the FD to /dev/null,
14104 # effectively closing config.log, so it can be properly (re)opened and
14105 # appended to by config.status. When coming back to configure, we
14106 # need to make the FD available again.
14107 if test "$no_create" != yes; then
14110 $SHELL $CONFIG_STATUS || ac_cs_success=false
14112 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
14113 # would make configure fail if this is the last instruction.
14114 $ac_cs_success || { (exit 1); exit 1; }