2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by Autoconf 2.52.20231210.
5 # Copyright 2003-2022,2023 Thomas E. Dickey
6 # Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
7 # Free Software Foundation, Inc.
8 # This configure script is free software; the Free Software Foundation
9 # gives unlimited permission to copy, distribute and modify it.
11 # Avoid depending upon Character Ranges.
12 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
13 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
14 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
15 as_cr_digits='0123456789'
16 as_cr_alnum=$as_cr_Letters$as_cr_digits
18 # Sed expression to map a string onto a valid variable name.
19 as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
21 # Sed expression to map a string onto a valid CPP name.
22 as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
24 # Be Bourne compatible
25 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
28 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
32 # Name of the executable.
33 as_me=`echo "$0" |sed 's,.*[\\/],,'`
35 if expr a : '\(a\)' >/dev/null 2>&1; then
41 rm -f conf$$ conf$$.exe conf$$.file
43 if ln -s conf$$.file conf$$ 2>/dev/null; then
44 # We could just check for DJGPP; but this test a) works b) is more generic
45 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
46 if test -f conf$$.exe; then
47 # Don't use ln at all; we don't have any links
52 elif ln conf$$.file conf$$ 2>/dev/null; then
57 rm -f conf$$ conf$$.exe conf$$.file
59 as_executable_p="test -f"
61 # Support unset when possible.
62 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
69 $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
70 $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
71 $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
72 $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
73 $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
74 $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
75 $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
76 $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
79 # We need space, tab and new line, in precisely that order.
85 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
88 # hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
89 # so uname gets run too.
90 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
97 ac_default_prefix=/usr/local
102 SHELL=${CONFIG_SHELL-/bin/sh}
104 # Maximum number of lines to put in a shell here document.
105 # This variable seems obsolete. It should probably be removed, and
106 # only ac_max_sed_lines should be used.
107 : "${ac_max_here_lines=38}"
109 ac_unique_file="ncurses.c"
110 # Factoring default headers for most tests.
111 ac_includes_default="\
114 # include <sys/types.h>
117 # include <sys/stat.h>
128 # if !STDC_HEADERS && HAVE_MEMORY_H
134 # include <strings.h>
137 # include <inttypes.h>
147 # Initialize some variables set by options.
149 ac_init_version=false
150 # The variables have the same names as the options, with
151 # dashes changed to underlines.
159 program_transform_name=s,x,x,
167 # Installation directory options.
168 # These are left unexpanded so users can "make install exec_prefix=/foo"
169 # and all the variables that are supposed to be based on exec_prefix
170 # by default will actually change.
171 # Use braces instead of parens because sh, perl, etc. also accept them.
172 bindir='${exec_prefix}/bin'
173 sbindir='${exec_prefix}/sbin'
174 libexecdir='${exec_prefix}/libexec'
175 datarootdir='${prefix}/share'
176 datadir='${datarootdir}'
177 sysconfdir='${prefix}/etc'
178 sharedstatedir='${prefix}/com'
179 localstatedir='${prefix}/var'
180 runstatedir='${localstatedir}/run'
181 libdir='${exec_prefix}/lib'
182 includedir='${prefix}/include'
183 oldincludedir='/usr/include'
184 infodir='${datarootdir}/info'
185 mandir='${datarootdir}/man'
187 # Identity of this package.
197 # If the previous option needs an argument, assign it.
198 if test -n "$ac_prev"; then
199 eval "$ac_prev=\$ac_option"
204 ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
206 # Accept the important Cygnus configure options, so we can diagnose typos.
210 -bindir | --bindir | --bindi | --bind | --bin | --bi)
212 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
215 -build | --build | --buil | --bui | --bu)
216 ac_prev=build_alias ;;
217 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
218 build_alias=$ac_optarg ;;
220 -cache-file | --cache-file | --cache-fil | --cache-fi \
221 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
222 ac_prev=cache_file ;;
223 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
224 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
225 cache_file=$ac_optarg ;;
228 cache_file=config.cache ;;
230 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
232 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
234 datadir=$ac_optarg ;;
236 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
237 | --dataroo | --dataro | --datar)
238 ac_prev=datarootdir ;;
239 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
240 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
241 datarootdir=$ac_optarg ;;
243 -disable-* | --disable-*)
244 ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
245 # Reject names that are not valid shell variable names.
246 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
247 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
248 { (exit 1); exit 1; }; }
249 ac_feature=`echo "$ac_feature" | sed 's/-/_/g'`
250 eval "enable_$ac_feature=no" ;;
252 -enable-* | --enable-*)
253 ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
254 # Reject names that are not valid shell variable names.
255 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
256 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
257 { (exit 1); exit 1; }; }
258 ac_feature=`echo "$ac_feature" | sed 's/-/_/g'`
260 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
263 eval "enable_$ac_feature='$ac_optarg'" ;;
265 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
266 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
267 | --exec | --exe | --ex)
268 ac_prev=exec_prefix ;;
269 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
270 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
271 | --exec=* | --exe=* | --ex=*)
272 exec_prefix=$ac_optarg ;;
274 -gas | --gas | --ga | --g)
275 # Obsolete; use --with-gas.
278 -help | --help | --hel | --he | -h)
280 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
281 ac_init_help=recursive ;;
282 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
283 ac_init_help=short ;;
285 -host | --host | --hos | --ho)
286 ac_prev=host_alias ;;
287 -host=* | --host=* | --hos=* | --ho=*)
288 host_alias=$ac_optarg ;;
290 -includedir | --includedir | --includedi | --included | --include \
291 | --includ | --inclu | --incl | --inc)
292 ac_prev=includedir ;;
293 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
294 | --includ=* | --inclu=* | --incl=* | --inc=*)
295 includedir=$ac_optarg ;;
297 -infodir | --infodir | --infodi | --infod | --info | --inf)
299 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
300 infodir=$ac_optarg ;;
302 -libdir | --libdir | --libdi | --libd)
304 -libdir=* | --libdir=* | --libdi=* | --libd=*)
307 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
308 | --libexe | --libex | --libe)
309 ac_prev=libexecdir ;;
310 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
311 | --libexe=* | --libex=* | --libe=*)
312 libexecdir=$ac_optarg ;;
314 -localstatedir | --localstatedir | --localstatedi | --localstated \
315 | --localstate | --localstat | --localsta | --localst \
316 | --locals | --local | --loca | --loc | --lo)
317 ac_prev=localstatedir ;;
318 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
319 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
320 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
321 localstatedir=$ac_optarg ;;
323 -runstatedir | --runstatedir | --runstatedi | --runstated \
324 | --runstate | --runstat | --runsta | --runst \
325 | --runs | --run | --ru)
326 ac_prev=runstatedir ;;
327 -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \
328 | --runstate=* | --runstat=* | --runsta=* | --runst=* \
329 | --runs=* | --run=* | --ru=*)
330 runstatedir=$ac_optarg ;;
332 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
334 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
338 # Obsolete; use --without-fp.
341 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
345 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
346 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
349 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
350 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
351 | --oldin | --oldi | --old | --ol | --o)
352 ac_prev=oldincludedir ;;
353 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
354 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
355 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
356 oldincludedir=$ac_optarg ;;
358 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
360 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
363 -program-prefix | --program-prefix | --program-prefi | --program-pref \
364 | --program-pre | --program-pr | --program-p)
365 ac_prev=program_prefix ;;
366 -program-prefix=* | --program-prefix=* | --program-prefi=* \
367 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
368 program_prefix=$ac_optarg ;;
370 -program-suffix | --program-suffix | --program-suffi | --program-suff \
371 | --program-suf | --program-su | --program-s)
372 ac_prev=program_suffix ;;
373 -program-suffix=* | --program-suffix=* | --program-suffi=* \
374 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
375 program_suffix=$ac_optarg ;;
377 -program-transform-name | --program-transform-name \
378 | --program-transform-nam | --program-transform-na \
379 | --program-transform-n | --program-transform- \
380 | --program-transform | --program-transfor \
381 | --program-transfo | --program-transf \
382 | --program-trans | --program-tran \
383 | --progr-tra | --program-tr | --program-t)
384 ac_prev=program_transform_name ;;
385 -program-transform-name=* | --program-transform-name=* \
386 | --program-transform-nam=* | --program-transform-na=* \
387 | --program-transform-n=* | --program-transform-=* \
388 | --program-transform=* | --program-transfor=* \
389 | --program-transfo=* | --program-transf=* \
390 | --program-trans=* | --program-tran=* \
391 | --progr-tra=* | --program-tr=* | --program-t=*)
392 program_transform_name=$ac_optarg ;;
394 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
395 | -silent | --silent | --silen | --sile | --sil)
398 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
400 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
402 sbindir=$ac_optarg ;;
404 -sharedstatedir | --sharedstatedir | --sharedstatedi \
405 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
406 | --sharedst | --shareds | --shared | --share | --shar \
408 ac_prev=sharedstatedir ;;
409 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
410 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
411 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
413 sharedstatedir=$ac_optarg ;;
415 -site | --site | --sit)
417 -site=* | --site=* | --sit=*)
420 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
422 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
425 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
426 | --syscon | --sysco | --sysc | --sys | --sy)
427 ac_prev=sysconfdir ;;
428 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
429 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
430 sysconfdir=$ac_optarg ;;
432 -target | --target | --targe | --targ | --tar | --ta | --t)
433 ac_prev=target_alias ;;
434 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
435 target_alias=$ac_optarg ;;
437 -v | -verbose | --verbose | --verbos | --verbo | --verb)
440 -version | --version | --versio | --versi | --vers | -V)
444 ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
445 # Reject names that are not valid shell variable names.
446 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
447 { echo "$as_me: error: invalid package name: $ac_package" >&2
448 { (exit 1); exit 1; }; }
449 ac_package=`echo "$ac_package" | sed 's/-/_/g'`
451 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
454 eval "with_$ac_package='$ac_optarg'" ;;
456 -without-* | --without-*)
457 ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
458 # Reject names that are not valid shell variable names.
459 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
460 { echo "$as_me: error: invalid package name: $ac_package" >&2
461 { (exit 1); exit 1; }; }
462 ac_package=`echo "$ac_package" | sed 's/-/_/g'`
463 eval "with_$ac_package=no" ;;
466 # Obsolete; use --with-x.
469 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
470 | --x-incl | --x-inc | --x-in | --x-i)
471 ac_prev=x_includes ;;
472 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
473 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
474 x_includes=$ac_optarg ;;
476 -x-libraries | --x-libraries | --x-librarie | --x-librari \
477 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
478 ac_prev=x_libraries ;;
479 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
480 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
481 x_libraries=$ac_optarg ;;
483 -*) { echo "$as_me: error: unrecognized option: $ac_option
484 Try \`$0 --help' for more information." >&2
485 { (exit 1); exit 1; }; }
489 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
490 # Reject names that are not valid shell variable names.
491 expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
492 { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
493 { (exit 1); exit 1; }; }
494 ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
495 eval "$ac_envvar='$ac_optarg'"
496 export "$ac_envvar" ;;
499 # FIXME: should be removed in autoconf 3.0.
500 echo "$as_me: WARNING: you should use --build, --host, --target" >&2
501 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
502 echo "$as_me: WARNING: invalid host type: $ac_option" >&2
503 : "${build_alias=$ac_option}" "${host_alias=$ac_option}" "${target_alias=$ac_option}"
509 if test -n "$ac_prev"; then
510 ac_option=--`echo "$ac_prev" | sed 's/_/-/g'`
511 { echo "$as_me: error: missing argument to $ac_option" >&2
512 { (exit 1); exit 1; }; }
515 # Be sure to have absolute paths.
516 for ac_var in exec_prefix prefix
518 eval ac_val=$`echo "$ac_var"`
520 [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
521 *) { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
522 { (exit 1); exit 1; }; };;
526 # Be sure to have absolute paths.
527 for ac_var in bindir sbindir libexecdir datarootdir datadir sysconfdir sharedstatedir \
528 localstatedir libdir includedir oldincludedir infodir mandir
530 eval ac_val=$`echo "$ac_var"`
532 [\\/$]* | ?:[\\/]* ) ;;
533 *) { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
534 { (exit 1); exit 1; }; };;
538 # There might be people who depend on the old broken behavior: `$host'
539 # used to hold the argument of --host etc.
544 # FIXME: should be removed in autoconf 3.0.
545 if test "x$host_alias" != x; then
546 if test "x$build_alias" = x; then
547 cross_compiling=maybe
548 echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
549 If a cross compiler is detected then cross compile mode will be used." >&2
550 elif test "x$build_alias" != "x$host_alias"; then
556 test -n "$host_alias" && ac_tool_prefix=$host_alias-
558 test "$silent" = yes && exec 6>/dev/null
560 # Find the source files, if location was not specified.
561 if test -z "$srcdir"; then
562 ac_srcdir_defaulted=yes
563 # Try the directory containing this script, then its parent.
565 ac_confdir=`echo "$ac_prog" | sed 's%[\\/][^\\/][^\\/]*$%%'`
566 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
568 if test ! -r "$srcdir/$ac_unique_file"; then
572 ac_srcdir_defaulted=no
574 if test ! -r "$srcdir/$ac_unique_file"; then
575 if test "$ac_srcdir_defaulted" = yes; then
576 { echo "$as_me: error: cannot find sources in $ac_confdir or .." >&2
577 { (exit 1); exit 1; }; }
579 { echo "$as_me: error: cannot find sources in $srcdir" >&2
580 { (exit 1); exit 1; }; }
583 srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
584 ac_env_build_alias_set=${build_alias+set}
585 ac_env_build_alias_value=$build_alias
586 ac_cv_env_build_alias_set=${build_alias+set}
587 ac_cv_env_build_alias_value=$build_alias
588 ac_env_host_alias_set=${host_alias+set}
589 ac_env_host_alias_value=$host_alias
590 ac_cv_env_host_alias_set=${host_alias+set}
591 ac_cv_env_host_alias_value=$host_alias
592 ac_env_target_alias_set=${target_alias+set}
593 ac_env_target_alias_value=$target_alias
594 ac_cv_env_target_alias_set=${target_alias+set}
595 ac_cv_env_target_alias_value=$target_alias
596 ac_env_CC_set=${CC+set}
598 ac_cv_env_CC_set=${CC+set}
599 ac_cv_env_CC_value=$CC
600 ac_env_CFLAGS_set=${CFLAGS+set}
601 ac_env_CFLAGS_value=$CFLAGS
602 ac_cv_env_CFLAGS_set=${CFLAGS+set}
603 ac_cv_env_CFLAGS_value=$CFLAGS
604 ac_env_LDFLAGS_set=${LDFLAGS+set}
605 ac_env_LDFLAGS_value=$LDFLAGS
606 ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
607 ac_cv_env_LDFLAGS_value=$LDFLAGS
608 ac_env_CPPFLAGS_set=${CPPFLAGS+set}
609 ac_env_CPPFLAGS_value=$CPPFLAGS
610 ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
611 ac_cv_env_CPPFLAGS_value=$CPPFLAGS
612 ac_env_CPP_set=${CPP+set}
613 ac_env_CPP_value=$CPP
614 ac_cv_env_CPP_set=${CPP+set}
615 ac_cv_env_CPP_value=$CPP
618 # Report the --help message.
620 if test "$ac_init_help" = "long"; then
621 # Omit some internal or obsolete options to make the list less imposing.
622 # This message is too long to be a string in the A/UX 3.1 sh.
624 \`configure' configures this package to adapt to many kinds of systems.
626 Usage: $0 [OPTION]... [VAR=VALUE]...
628 To assign environment variables (e.g., CC, CFLAGS...), specify them as
629 VAR=VALUE. See below for descriptions of some of the useful variables.
631 Defaults for the options are specified in brackets.
634 -h, --help display this help and exit
635 --help=short display options specific to this package
636 --help=recursive display the short help of all the included packages
637 -V, --version display version information and exit
638 -q, --quiet, --silent do not print \`checking...' messages
639 --cache-file=FILE cache test results in FILE [disabled]
640 -C, --config-cache alias for \`--cache-file=config.cache'
641 -n, --no-create do not create output files
642 --srcdir=DIR find the sources in DIR [configure dir or \`..']
647 Installation directories:
648 --prefix=PREFIX install architecture-independent files in PREFIX
650 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
653 By default, \`make install' will install all the files in
654 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
655 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
656 for instance \`--prefix=\$HOME'.
658 For better control, use the options below.
660 Fine tuning of the installation directories:
661 --bindir=DIR user executables [EPREFIX/bin]
662 --sbindir=DIR system admin executables [EPREFIX/sbin]
663 --libexecdir=DIR program executables [EPREFIX/libexec]
664 --datarootdir=DIR read-only architecture-independent data [PREFIX/share]
665 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
666 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
667 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
668 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
669 --runstatedir=DIR extra definition of runtime data [LOCALSTATEDIR/run]
670 --libdir=DIR object code libraries [EPREFIX/lib]
671 --includedir=DIR C header files [PREFIX/include]
672 --oldincludedir=DIR C header files for non-gcc [/usr/include]
673 --infodir=DIR info documentation [DATAROOTDIR/info]
674 --mandir=DIR man documentation [DATAROOTDIR/man]
680 --program-prefix=PREFIX prepend PREFIX to installed program names
681 --program-suffix=SUFFIX append SUFFIX to installed program names
682 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
685 --x-includes=DIR X include files are in DIR
686 --x-libraries=DIR X library files are in DIR
689 --build=BUILD configure for building on BUILD [guessed]
690 --host=HOST build programs to run on HOST [BUILD]
694 if test -n "$ac_init_help"; then
699 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
700 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
703 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
704 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
707 --disable-stripping do not strip (debug info) installed executables
708 --with-strip-program=XX specify program to use when stripping in install
709 --enable-stdnoreturn enable C11 _Noreturn feature for diagnostics
710 --enable-string-hacks work around bogus compiler/loader warnings
711 --with-pkg-config[=CMD] enable/disable use of pkg-config and its name CMD
712 --disable-echo do not display "compiling" commands
713 Curses Version-dependent Options:
714 --with-ncurses-wrap-prefix naming-prefix for ncurses wrapped-variables
715 --disable-widec disable checks for wide-character functions
716 --with-curses-dir=DIR directory in which (n)curses is installed
717 --with-screen=XXX use specified curses-libraries
718 --with-ncursesw use wide ncurses-libraries
719 --with-ncurses use ncurses-libraries
720 --with-pdcurses compile/link with pdcurses X11 library
721 --with-curses-colr compile/link with HPUX 10.x color-curses
722 --with-curses-5lib compile/link with SunOS 5lib curses
723 --with-Xaw3d link with Xaw 3d library
724 --with-Xaw3dxft link with Xaw 3d xft library
725 --with-neXtaw link with neXT Athena library
726 --with-XawPlus link with Athena-Plus library
727 --with-x use the X Window System
728 --with-x11-rgb=FILE obtain X11 color definitions from FILE (default: EPREFIX/lib/X11/rgb.txt)
729 --with-form-libname[=XXX] override ifelse(,,form,) basename of library
730 --with-menu-libname[=XXX] override ifelse(,,menu,) basename of library
731 --with-panel-libname[=XXX] override ifelse(,,panel,) basename of library
732 --disable-panel disable checks for panel functions
733 --disable-menu disable checks for menu functions
734 --disable-form disable checks for form functions
735 Testing/development Options:
736 --enable-warnings test: turn on gcc compiler warnings
737 --with-dmalloc test: use Gray Watson's dmalloc library
738 --with-dbmalloc test: use Conor Cahill's dbmalloc library
739 --with-valgrind test: use valgrind
740 --disable-leaks test: free permanent memory, analyze leaks
741 --disable-rpath-hack don't add rpath options for additional libraries
743 Some influential environment variables:
744 CC C compiler command
745 CFLAGS C compiler flags
746 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
747 nonstandard directory <lib dir>
748 CPPFLAGS C/C++ preprocessor flags, e.g. -I<include dir> if you have
749 headers in a nonstandard directory <include dir>
752 Use these variables to override the choices made by `configure' or to help
753 it to find libraries and programs with nonstandard names/locations.
758 if test "$ac_init_help" = "recursive"; then
759 # If there are subdirs, report their specific --help.
761 for ac_subdir in : $ac_subdirs_all; do test "x$ac_subdir" = x: && continue
763 # A "../" for each directory in /$ac_subdir.
764 ac_dots=`echo "$ac_subdir" |
765 sed 's,^\./,,;s,[^/]$,&/,;s,[^/]*/,../,g'`
768 .) # No --srcdir option. We are building in place.
769 ac_sub_srcdir="$srcdir" ;;
770 [\\/]* | ?:[\\/]* ) # Absolute path.
771 ac_sub_srcdir="$srcdir/$ac_subdir" ;;
773 ac_sub_srcdir="$ac_dots$srcdir/$ac_subdir" ;;
776 # Check for guested configure; otherwise get Cygnus style configure.
777 if test -f "$ac_sub_srcdir/configure.gnu"; then
779 $SHELL "$ac_sub_srcdir/configure.gnu" --help=recursive
780 elif test -f "$ac_sub_srcdir/configure"; then
782 $SHELL "$ac_sub_srcdir/configure" --help=recursive
783 elif test -f "$ac_sub_srcdir/configure.ac" ||
784 test -f "$ac_sub_srcdir/configure.in"; then
786 "$ac_configure" --help
788 echo "$as_me: WARNING: no configuration information is in $ac_subdir" >&2
794 test -n "$ac_init_help" && exit 0
795 if "$ac_init_version"; then
798 Copyright 2003-2022,2023 Thomas E. Dickey
799 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
800 Free Software Foundation, Inc.
801 This configure script is free software; the Free Software Foundation
802 gives unlimited permission to copy, distribute and modify it.
808 This file contains any messages produced by compilers while
809 running configure, to aid debugging if configure makes a mistake.
811 It was created by $as_me, which was
812 generated by GNU Autoconf 2.52.20231210. Invocation command line was
823 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
824 uname -m = `(uname -m) 2>/dev/null || echo unknown`
825 uname -r = `(uname -r) 2>/dev/null || echo unknown`
826 uname -s = `(uname -s) 2>/dev/null || echo unknown`
827 uname -v = `(uname -v) 2>/dev/null || echo unknown`
829 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
830 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
832 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
833 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
834 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
835 hostinfo = `(hostinfo) 2>/dev/null || echo unknown`
836 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
837 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
838 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
852 # Keep a trace of the command line.
853 # Strip out --no-create and --no-recursion so they do not pile up.
854 # Also quote any args containing shell meta-characters.
860 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
861 | --no-cr | --no-c) ;;
862 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
863 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
864 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
865 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"`
866 ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
868 *) ac_configure_args="$ac_configure_args$ac_sep$ac_arg"
871 # Get rid of the leading space.
874 # When interrupted or exit'd, cleanup temporary files, and complete
875 # config.log. We remove comments because anyway the quotes in there
876 # would cause problems or look ugly.
878 # Save into config.log some information that might help in debugging.
880 echo "## ----------------- ##" >&5
881 echo "## Cache variables. ##" >&5
882 echo "## ----------------- ##" >&5
884 # The following way of writing the cache mishandles newlines in values,
887 case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
890 "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
891 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
895 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
899 sed "/^$/d" confdefs.h >conftest.log
900 if test -s conftest.log; then
902 echo "## ------------ ##" >&5
903 echo "## confdefs.h. ##" >&5
904 echo "## ------------ ##" >&5
909 test "$ac_signal" != 0 &&
910 echo "$as_me: caught signal $ac_signal" >&5
911 echo "$as_me: exit $exit_status" >&5
912 rm -rf conftest* confdefs* core core.* *.core conf$$* $ac_clean_files &&
915 for ac_signal in 1 2 13 15; do
916 trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' "$ac_signal"
920 # confdefs.h avoids OS command line length limits that DEFS can exceed.
921 rm -rf conftest* confdefs.h
922 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
925 # Let the site file select an alternate cache file if it wants to.
926 # Prefer explicitly selected file to automatically selected ones.
927 if test -z "$CONFIG_SITE"; then
928 if test "x$prefix" != xNONE; then
929 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
931 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
934 for ac_site_file in $CONFIG_SITE; do
935 if test -r "$ac_site_file"; then
936 { echo "$as_me:936: loading site script $ac_site_file" >&5
937 echo "$as_me: loading site script $ac_site_file" >&6;}
938 cat "$ac_site_file" >&5
943 if test -r "$cache_file"; then
944 # Some versions of bash will fail to source /dev/null (special
945 # files actually), so we avoid doing that.
946 if test -f "$cache_file"; then
947 { echo "$as_me:947: loading cache $cache_file" >&5
948 echo "$as_me: loading cache $cache_file" >&6;}
950 [\\/]* | ?:[\\/]* ) . $cache_file;;
955 { echo "$as_me:955: creating cache $cache_file" >&5
956 echo "$as_me: creating cache $cache_file" >&6;}
960 # Check that the precious variables saved in the cache have kept the same
962 ac_cache_corrupted=false
963 for ac_var in `(set) 2>&1 |
964 sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
965 eval ac_old_set=\$ac_cv_env_${ac_var}_set
966 eval ac_new_set=\$ac_env_${ac_var}_set
967 eval ac_old_val="\$ac_cv_env_${ac_var}_value"
968 eval ac_new_val="\$ac_env_${ac_var}_value"
969 case "$ac_old_set,$ac_new_set" in
971 { echo "$as_me:971: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
972 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
973 ac_cache_corrupted=: ;;
975 { echo "$as_me:975: error: \`$ac_var' was not set in the previous run" >&5
976 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
977 ac_cache_corrupted=: ;;
980 if test "x$ac_old_val" != "x$ac_new_val"; then
981 { echo "$as_me:981: error: \`$ac_var' has changed since the previous run:" >&5
982 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
983 { echo "$as_me:983: former value: $ac_old_val" >&5
984 echo "$as_me: former value: $ac_old_val" >&2;}
985 { echo "$as_me:985: current value: $ac_new_val" >&5
986 echo "$as_me: current value: $ac_new_val" >&2;}
990 # Pass precious variables to config.status. It doesn't matter if
991 # we pass some twice (in addition to the command line arguments).
992 if test "$ac_new_set" = set; then
993 case "$ac_new_val" in
994 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
995 ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"`
996 ac_configure_args="$ac_configure_args '$ac_arg'"
998 *) ac_configure_args="$ac_configure_args $ac_var=$ac_new_val"
1003 if "$ac_cache_corrupted"; then
1004 { echo "$as_me:1004: error: changes in the environment can compromise the build" >&5
1005 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1006 { { echo "$as_me:1006: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1007 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1008 { (exit 1); exit 1; }; }
1012 ac_cpp='$CPP $CPPFLAGS'
1013 ac_compile='$CC -c $CFLAGS $CPPFLAGS "conftest.$ac_ext" >&5'
1014 ac_link='$CC -o "conftest$ac_exeext" $CFLAGS $CPPFLAGS $LDFLAGS "conftest.$ac_ext" $LIBS >&5'
1015 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1016 ac_main_return="return"
1018 case `echo "testing\c" 2>/dev/null; echo 1,2,3`,`echo -n testing 2>/dev/null; echo 1,2,3` in
1020 ECHO_C= # newlines do not sed ;-) only broken shells would use this case anyway
1032 echo "#! $SHELL" >conftest.sh
1033 echo "exit 0" >>conftest.sh
1034 chmod +x conftest.sh
1035 if { (echo "$as_me:1035: PATH=\".;.\"; conftest.sh") >&5
1036 (PATH=".;."; conftest.sh) 2>&5
1038 echo "$as_me:1038: \$? = $ac_status" >&5
1039 (exit "$ac_status"); }; then
1040 ac_path_separator=';'
1044 PATH_SEPARATOR="$ac_path_separator"
1047 ac_config_headers="$ac_config_headers ncurses_cfg.h:ncurses_tst.hin"
1049 test -f config.guess || ( test -f ../config.guess && cp ../config.guess ./ )
1051 test -f config.sub || ( test -f ../config.sub && cp ../config.sub ./ )
1054 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
1055 if test -f "$ac_dir/install-sh"; then
1057 ac_install_sh="$ac_aux_dir/install-sh -c"
1059 elif test -f "$ac_dir/install.sh"; then
1061 ac_install_sh="$ac_aux_dir/install.sh -c"
1063 elif test -f "$ac_dir/shtool"; then
1065 ac_install_sh="$ac_aux_dir/shtool install -c"
1069 if test -z "$ac_aux_dir"; then
1070 { { echo "$as_me:1070: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
1071 echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
1072 { (exit 1); exit 1; }; }
1074 ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1075 ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1076 ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
1078 # Make sure we can run config.sub.
1079 $ac_config_sub sun4 >/dev/null 2>&1 ||
1080 { { echo "$as_me:1080: error: cannot run $ac_config_sub" >&5
1081 echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1082 { (exit 1); exit 1; }; }
1084 echo "$as_me:1084: checking build system type" >&5
1085 echo $ECHO_N "checking build system type... $ECHO_C" >&6
1086 if test "${ac_cv_build+set}" = set; then
1087 echo $ECHO_N "(cached) $ECHO_C" >&6
1089 ac_cv_build_alias=$build_alias
1090 test -z "$ac_cv_build_alias" &&
1091 ac_cv_build_alias=`$ac_config_guess`
1092 test -z "$ac_cv_build_alias" &&
1093 { { echo "$as_me:1093: error: cannot guess build type; you must specify one" >&5
1094 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1095 { (exit 1); exit 1; }; }
1096 ac_cv_build=`$ac_config_sub "$ac_cv_build_alias"` ||
1097 { { echo "$as_me:1097: error: $ac_config_sub $ac_cv_build_alias failed." >&5
1098 echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed." >&2;}
1099 { (exit 1); exit 1; }; }
1102 echo "$as_me:1102: result: $ac_cv_build" >&5
1103 echo "${ECHO_T}$ac_cv_build" >&6
1105 build_cpu=`echo "$ac_cv_build" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1106 build_vendor=`echo "$ac_cv_build" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1107 build_os=`echo "$ac_cv_build" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1109 if test -f "$srcdir/config.guess" || test -f "$ac_aux_dir/config.guess" ; then
1110 echo "$as_me:1110: checking host system type" >&5
1111 echo $ECHO_N "checking host system type... $ECHO_C" >&6
1112 if test "${ac_cv_host+set}" = set; then
1113 echo $ECHO_N "(cached) $ECHO_C" >&6
1115 ac_cv_host_alias=$host_alias
1116 test -z "$ac_cv_host_alias" &&
1117 ac_cv_host_alias=$ac_cv_build_alias
1118 ac_cv_host=`$ac_config_sub "$ac_cv_host_alias"` ||
1119 { { echo "$as_me:1119: error: $ac_config_sub $ac_cv_host_alias failed" >&5
1120 echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1121 { (exit 1); exit 1; }; }
1124 echo "$as_me:1124: result: $ac_cv_host" >&5
1125 echo "${ECHO_T}$ac_cv_host" >&6
1127 host_cpu=`echo "$ac_cv_host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1128 host_vendor=`echo "$ac_cv_host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1129 host_os=`echo "$ac_cv_host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1131 system_name="$host_os"
1133 system_name="`(uname -s -r) 2>/dev/null`"
1134 if test -z "$system_name" ; then
1135 system_name="`(hostname) 2>/dev/null`"
1138 test -n "$system_name" &&
1139 cat >>confdefs.h <<EOF
1140 #define SYSTEM_NAME "$system_name"
1143 if test "${cf_cv_system_name+set}" = set; then
1144 echo $ECHO_N "(cached) $ECHO_C" >&6
1146 cf_cv_system_name="$system_name"
1149 test -z "$system_name" && system_name="$cf_cv_system_name"
1150 test -n "$cf_cv_system_name" && echo "$as_me:1150: result: Configuring for $cf_cv_system_name" >&5
1151 echo "${ECHO_T}Configuring for $cf_cv_system_name" >&6
1153 if test ".$system_name" != ".$cf_cv_system_name" ; then
1154 echo "$as_me:1154: result: Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&5
1155 echo "${ECHO_T}Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&6
1156 { { echo "$as_me:1156: error: \"Please remove config.cache and try again.\"" >&5
1157 echo "$as_me: error: \"Please remove config.cache and try again.\"" >&2;}
1158 { (exit 1); exit 1; }; }
1161 test "$program_prefix" != NONE &&
1162 program_transform_name="s,^,$program_prefix,;$program_transform_name"
1163 # Use a double $ so make ignores it.
1164 test "$program_suffix" != NONE &&
1165 program_transform_name="s,\$,$program_suffix,;$program_transform_name"
1166 # Double any \ or $. echo might interpret backslashes.
1167 # By default was `s,x,x', remove it if useless.
1168 cat <<\_ACEOF >conftest.sed
1169 s/[\\$]/&&/g;s/;s,x,x,$//
1171 program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
1174 echo "$as_me:1174: checking whether ${MAKE-make} sets \${MAKE}" >&5
1175 echo $ECHO_N "checking whether ${MAKE-make} sets \${MAKE}... $ECHO_C" >&6
1176 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,./+-,__p_,'`
1177 if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
1178 echo $ECHO_N "(cached) $ECHO_C" >&6
1180 cat >conftest.make <<\EOF
1182 @echo 'ac_maketemp="${MAKE}"'
1184 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1185 eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
1186 if test -n "$ac_maketemp"; then
1187 eval ac_cv_prog_make_${ac_make}_set=yes
1189 eval ac_cv_prog_make_${ac_make}_set=no
1193 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
1194 echo "$as_me:1194: result: yes" >&5
1195 echo "${ECHO_T}yes" >&6
1198 echo "$as_me:1198: result: no" >&5
1199 echo "${ECHO_T}no" >&6
1200 SET_MAKE="MAKE=${MAKE-make}"
1204 ac_cpp='$CPP $CPPFLAGS'
1205 ac_compile='$CC -c $CFLAGS $CPPFLAGS "conftest.$ac_ext" >&5'
1206 ac_link='$CC -o "conftest$ac_exeext" $CFLAGS $CPPFLAGS $LDFLAGS "conftest.$ac_ext" $LIBS >&5'
1207 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1208 ac_main_return="return"
1209 if test -n "$ac_tool_prefix"; then
1210 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
1211 set dummy ${ac_tool_prefix}gcc; ac_word=$2
1212 echo "$as_me:1212: checking for $ac_word" >&5
1213 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1214 if test "${ac_cv_prog_CC+set}" = set; then
1215 echo $ECHO_N "(cached) $ECHO_C" >&6
1217 if test -n "$CC"; then
1218 ac_cv_prog_CC="$CC" # Let the user override the test.
1220 ac_save_IFS=$IFS; IFS=$ac_path_separator
1222 for ac_dir in $ac_dummy; do
1224 test -z "$ac_dir" && ac_dir=.
1225 $as_executable_p "$ac_dir/$ac_word" || continue
1226 ac_cv_prog_CC="${ac_tool_prefix}gcc"
1227 echo "$as_me:1227: found $ac_dir/$ac_word" >&5
1234 if test -n "$CC"; then
1235 echo "$as_me:1235: result: $CC" >&5
1236 echo "${ECHO_T}$CC" >&6
1238 echo "$as_me:1238: result: no" >&5
1239 echo "${ECHO_T}no" >&6
1243 if test -z "$ac_cv_prog_CC"; then
1245 # Extract the first word of "gcc", so it can be a program name with args.
1246 set dummy gcc; ac_word=$2
1247 echo "$as_me:1247: checking for $ac_word" >&5
1248 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1249 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1250 echo $ECHO_N "(cached) $ECHO_C" >&6
1252 if test -n "$ac_ct_CC"; then
1253 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1255 ac_save_IFS=$IFS; IFS=$ac_path_separator
1257 for ac_dir in $ac_dummy; do
1259 test -z "$ac_dir" && ac_dir=.
1260 $as_executable_p "$ac_dir/$ac_word" || continue
1261 ac_cv_prog_ac_ct_CC="gcc"
1262 echo "$as_me:1262: found $ac_dir/$ac_word" >&5
1268 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1269 if test -n "$ac_ct_CC"; then
1270 echo "$as_me:1270: result: $ac_ct_CC" >&5
1271 echo "${ECHO_T}$ac_ct_CC" >&6
1273 echo "$as_me:1273: result: no" >&5
1274 echo "${ECHO_T}no" >&6
1282 if test -z "$CC"; then
1283 if test -n "$ac_tool_prefix"; then
1284 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
1285 set dummy ${ac_tool_prefix}cc; ac_word=$2
1286 echo "$as_me:1286: checking for $ac_word" >&5
1287 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1288 if test "${ac_cv_prog_CC+set}" = set; then
1289 echo $ECHO_N "(cached) $ECHO_C" >&6
1291 if test -n "$CC"; then
1292 ac_cv_prog_CC="$CC" # Let the user override the test.
1294 ac_save_IFS=$IFS; IFS=$ac_path_separator
1296 for ac_dir in $ac_dummy; do
1298 test -z "$ac_dir" && ac_dir=.
1299 $as_executable_p "$ac_dir/$ac_word" || continue
1300 ac_cv_prog_CC="${ac_tool_prefix}cc"
1301 echo "$as_me:1301: found $ac_dir/$ac_word" >&5
1308 if test -n "$CC"; then
1309 echo "$as_me:1309: result: $CC" >&5
1310 echo "${ECHO_T}$CC" >&6
1312 echo "$as_me:1312: result: no" >&5
1313 echo "${ECHO_T}no" >&6
1317 if test -z "$ac_cv_prog_CC"; then
1319 # Extract the first word of "cc", so it can be a program name with args.
1320 set dummy cc; ac_word=$2
1321 echo "$as_me:1321: checking for $ac_word" >&5
1322 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1323 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1324 echo $ECHO_N "(cached) $ECHO_C" >&6
1326 if test -n "$ac_ct_CC"; then
1327 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1329 ac_save_IFS=$IFS; IFS=$ac_path_separator
1331 for ac_dir in $ac_dummy; do
1333 test -z "$ac_dir" && ac_dir=.
1334 $as_executable_p "$ac_dir/$ac_word" || continue
1335 ac_cv_prog_ac_ct_CC="cc"
1336 echo "$as_me:1336: found $ac_dir/$ac_word" >&5
1342 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1343 if test -n "$ac_ct_CC"; then
1344 echo "$as_me:1344: result: $ac_ct_CC" >&5
1345 echo "${ECHO_T}$ac_ct_CC" >&6
1347 echo "$as_me:1347: result: no" >&5
1348 echo "${ECHO_T}no" >&6
1357 if test -z "$CC"; then
1358 # Extract the first word of "cc", so it can be a program name with args.
1359 set dummy cc; ac_word=$2
1360 echo "$as_me:1360: checking for $ac_word" >&5
1361 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1362 if test "${ac_cv_prog_CC+set}" = set; then
1363 echo $ECHO_N "(cached) $ECHO_C" >&6
1365 if test -n "$CC"; then
1366 ac_cv_prog_CC="$CC" # Let the user override the test.
1369 ac_save_IFS=$IFS; IFS=$ac_path_separator
1371 for ac_dir in $ac_dummy; do
1373 test -z "$ac_dir" && ac_dir=.
1374 $as_executable_p "$ac_dir/$ac_word" || continue
1375 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
1376 ac_prog_rejected=yes
1380 echo "$as_me:1380: found $ac_dir/$ac_word" >&5
1384 if test "$ac_prog_rejected" = yes; then
1385 # We found a bogon in the path, so make sure we never use it.
1386 set dummy $ac_cv_prog_CC
1388 if test $# != 0; then
1389 # We chose a different compiler from the bogus one.
1390 # However, it has the same basename, so the bogon will be chosen
1391 # first if we set CC to just the basename; use the full file name.
1393 set dummy "$ac_dir/$ac_word" ${1+"$@"}
1401 if test -n "$CC"; then
1402 echo "$as_me:1402: result: $CC" >&5
1403 echo "${ECHO_T}$CC" >&6
1405 echo "$as_me:1405: result: no" >&5
1406 echo "${ECHO_T}no" >&6
1410 if test -z "$CC"; then
1411 if test -n "$ac_tool_prefix"; then
1414 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
1415 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
1416 echo "$as_me:1416: checking for $ac_word" >&5
1417 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1418 if test "${ac_cv_prog_CC+set}" = set; then
1419 echo $ECHO_N "(cached) $ECHO_C" >&6
1421 if test -n "$CC"; then
1422 ac_cv_prog_CC="$CC" # Let the user override the test.
1424 ac_save_IFS=$IFS; IFS=$ac_path_separator
1426 for ac_dir in $ac_dummy; do
1428 test -z "$ac_dir" && ac_dir=.
1429 $as_executable_p "$ac_dir/$ac_word" || continue
1430 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
1431 echo "$as_me:1431: found $ac_dir/$ac_word" >&5
1438 if test -n "$CC"; then
1439 echo "$as_me:1439: result: $CC" >&5
1440 echo "${ECHO_T}$CC" >&6
1442 echo "$as_me:1442: result: no" >&5
1443 echo "${ECHO_T}no" >&6
1446 test -n "$CC" && break
1449 if test -z "$CC"; then
1453 # Extract the first word of "$ac_prog", so it can be a program name with args.
1454 set dummy $ac_prog; ac_word=$2
1455 echo "$as_me:1455: checking for $ac_word" >&5
1456 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1457 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1458 echo $ECHO_N "(cached) $ECHO_C" >&6
1460 if test -n "$ac_ct_CC"; then
1461 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1463 ac_save_IFS=$IFS; IFS=$ac_path_separator
1465 for ac_dir in $ac_dummy; do
1467 test -z "$ac_dir" && ac_dir=.
1468 $as_executable_p "$ac_dir/$ac_word" || continue
1469 ac_cv_prog_ac_ct_CC="$ac_prog"
1470 echo "$as_me:1470: found $ac_dir/$ac_word" >&5
1476 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1477 if test -n "$ac_ct_CC"; then
1478 echo "$as_me:1478: result: $ac_ct_CC" >&5
1479 echo "${ECHO_T}$ac_ct_CC" >&6
1481 echo "$as_me:1481: result: no" >&5
1482 echo "${ECHO_T}no" >&6
1485 test -n "$ac_ct_CC" && break
1493 test -z "$CC" && { { echo "$as_me:1493: error: no acceptable cc found in \$PATH" >&5
1494 echo "$as_me: error: no acceptable cc found in \$PATH" >&2;}
1495 { (exit 1); exit 1; }; }
1497 # Provide some information about the compiler.
1498 echo "$as_me:1498:" \
1499 "checking for C compiler version" >&5
1500 ac_compiler=`set X $ac_compile; echo "$2"`
1501 { (eval echo "$as_me:1501: \"$ac_compiler --version </dev/null >&5\"") >&5
1502 (eval $ac_compiler --version </dev/null >&5) 2>&5
1504 echo "$as_me:1504: \$? = $ac_status" >&5
1505 (exit "$ac_status"); }
1506 { (eval echo "$as_me:1506: \"$ac_compiler -v </dev/null >&5\"") >&5
1507 (eval $ac_compiler -v </dev/null >&5) 2>&5
1509 echo "$as_me:1509: \$? = $ac_status" >&5
1510 (exit "$ac_status"); }
1511 { (eval echo "$as_me:1511: \"$ac_compiler -V </dev/null >&5\"") >&5
1512 (eval $ac_compiler -V </dev/null >&5) 2>&5
1514 echo "$as_me:1514: \$? = $ac_status" >&5
1515 (exit "$ac_status"); }
1517 cat >"conftest.$ac_ext" <<_ACEOF
1518 #line 1518 "configure"
1519 #include "confdefs.h"
1529 ac_clean_files_save=$ac_clean_files
1530 ac_clean_files="$ac_clean_files a.out a.exe"
1531 # Try to create an executable without -o first, disregard a.out.
1532 # It will help us diagnose broken compilers, and finding out an intuition
1534 echo "$as_me:1534: checking for C compiler default output" >&5
1535 echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
1536 ac_link_default=`echo "$ac_link" | sed 's/ -o *"conftest[^"]*"//'`
1537 if { (eval echo "$as_me:1537: \"$ac_link_default\"") >&5
1538 (eval $ac_link_default) 2>&5
1540 echo "$as_me:1540: \$? = $ac_status" >&5
1541 (exit "$ac_status"); }; then
1542 # Find the output, starting from the most likely. This scheme is
1543 # not robust to junk in `.', hence go to wildcards (a.*) only as a last
1545 for ac_file in `ls a.exe conftest.exe 2>/dev/null;
1546 ls a.out conftest 2>/dev/null;
1547 ls a.* conftest.* 2>/dev/null`; do
1549 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1550 a.out ) # We found the default executable, but exeext='' is most
1553 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1554 # FIXME: I believe we export ac_cv_exeext for Libtool --akim.
1561 echo "$as_me: failed program was:" >&5
1562 cat "conftest.$ac_ext" >&5
1563 { { echo "$as_me:1563: error: C compiler cannot create executables" >&5
1564 echo "$as_me: error: C compiler cannot create executables" >&2;}
1565 { (exit 77); exit 77; }; }
1568 ac_exeext=$ac_cv_exeext
1569 echo "$as_me:1569: result: $ac_file" >&5
1570 echo "${ECHO_T}$ac_file" >&6
1572 # Check the compiler produces executables we can run. If not, either
1573 # the compiler is broken, or we cross compile.
1574 echo "$as_me:1574: checking whether the C compiler works" >&5
1575 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
1576 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
1577 # If not cross compiling, check that we can run a simple program.
1578 if test "$cross_compiling" != yes; then
1579 if { ac_try='./$ac_file'
1580 { (eval echo "$as_me:1580: \"$ac_try\"") >&5
1583 echo "$as_me:1583: \$? = $ac_status" >&5
1584 (exit "$ac_status"); }; }; then
1587 if test "$cross_compiling" = maybe; then
1590 { { echo "$as_me:1590: error: cannot run C compiled programs.
1591 If you meant to cross compile, use \`--host'." >&5
1592 echo "$as_me: error: cannot run C compiled programs.
1593 If you meant to cross compile, use \`--host'." >&2;}
1594 { (exit 1); exit 1; }; }
1598 echo "$as_me:1598: result: yes" >&5
1599 echo "${ECHO_T}yes" >&6
1601 rm -f a.out a.exe "conftest$ac_cv_exeext"
1602 ac_clean_files=$ac_clean_files_save
1603 # Check the compiler produces executables we can run. If not, either
1604 # the compiler is broken, or we cross compile.
1605 echo "$as_me:1605: checking whether we are cross compiling" >&5
1606 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
1607 echo "$as_me:1607: result: $cross_compiling" >&5
1608 echo "${ECHO_T}$cross_compiling" >&6
1610 echo "$as_me:1610: checking for executable suffix" >&5
1611 echo $ECHO_N "checking for executable suffix... $ECHO_C" >&6
1612 if { (eval echo "$as_me:1612: \"$ac_link\"") >&5
1613 (eval $ac_link) 2>&5
1615 echo "$as_me:1615: \$? = $ac_status" >&5
1616 (exit "$ac_status"); }; then
1617 # If both `conftest.exe' and `conftest' are `present' (well, observable)
1618 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
1619 # work properly (i.e., refer to `conftest.exe'), while it won't with
1621 for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do
1623 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1624 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1631 { { echo "$as_me:1631: error: cannot compute EXEEXT: cannot compile and link" >&5
1632 echo "$as_me: error: cannot compute EXEEXT: cannot compile and link" >&2;}
1633 { (exit 1); exit 1; }; }
1636 rm -f "conftest$ac_cv_exeext"
1637 echo "$as_me:1637: result: $ac_cv_exeext" >&5
1638 echo "${ECHO_T}$ac_cv_exeext" >&6
1640 rm -f "conftest.$ac_ext"
1641 EXEEXT=$ac_cv_exeext
1643 echo "$as_me:1643: checking for object suffix" >&5
1644 echo $ECHO_N "checking for object suffix... $ECHO_C" >&6
1645 if test "${ac_cv_objext+set}" = set; then
1646 echo $ECHO_N "(cached) $ECHO_C" >&6
1648 cat >"conftest.$ac_ext" <<_ACEOF
1649 #line 1649 "configure"
1650 #include "confdefs.h"
1660 rm -f conftest.o conftest.obj
1661 if { (eval echo "$as_me:1661: \"$ac_compile\"") >&5
1662 (eval $ac_compile) 2>&5
1664 echo "$as_me:1664: \$? = $ac_status" >&5
1665 (exit "$ac_status"); }; then
1666 for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
1668 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.map | *.inf ) ;;
1669 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
1674 echo "$as_me: failed program was:" >&5
1675 cat "conftest.$ac_ext" >&5
1676 { { echo "$as_me:1676: error: cannot compute OBJEXT: cannot compile" >&5
1677 echo "$as_me: error: cannot compute OBJEXT: cannot compile" >&2;}
1678 { (exit 1); exit 1; }; }
1681 rm -f "conftest.$ac_cv_objext" "conftest.$ac_ext"
1683 echo "$as_me:1683: result: $ac_cv_objext" >&5
1684 echo "${ECHO_T}$ac_cv_objext" >&6
1685 OBJEXT=$ac_cv_objext
1687 echo "$as_me:1687: checking whether we are using the GNU C compiler" >&5
1688 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
1689 if test "${ac_cv_c_compiler_gnu+set}" = set; then
1690 echo $ECHO_N "(cached) $ECHO_C" >&6
1692 cat >"conftest.$ac_ext" <<_ACEOF
1693 #line 1693 "configure"
1694 #include "confdefs.h"
1707 rm -f "conftest.$ac_objext"
1708 if { (eval echo "$as_me:1708: \"$ac_compile\"") >&5
1709 (eval $ac_compile) 2>&5
1711 echo "$as_me:1711: \$? = $ac_status" >&5
1712 (exit "$ac_status"); } &&
1713 { ac_try='test -s "conftest.$ac_objext"'
1714 { (eval echo "$as_me:1714: \"$ac_try\"") >&5
1717 echo "$as_me:1717: \$? = $ac_status" >&5
1718 (exit "$ac_status"); }; }; then
1721 echo "$as_me: failed program was:" >&5
1722 cat "conftest.$ac_ext" >&5
1725 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
1726 ac_cv_c_compiler_gnu=$ac_compiler_gnu
1729 echo "$as_me:1729: result: $ac_cv_c_compiler_gnu" >&5
1730 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
1731 GCC=`test $ac_compiler_gnu = yes && echo yes`
1732 ac_test_CFLAGS=${CFLAGS+set}
1733 ac_save_CFLAGS=$CFLAGS
1735 echo "$as_me:1735: checking whether $CC accepts -g" >&5
1736 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
1737 if test "${ac_cv_prog_cc_g+set}" = set; then
1738 echo $ECHO_N "(cached) $ECHO_C" >&6
1740 cat >"conftest.$ac_ext" <<_ACEOF
1741 #line 1741 "configure"
1742 #include "confdefs.h"
1752 rm -f "conftest.$ac_objext"
1753 if { (eval echo "$as_me:1753: \"$ac_compile\"") >&5
1754 (eval $ac_compile) 2>&5
1756 echo "$as_me:1756: \$? = $ac_status" >&5
1757 (exit "$ac_status"); } &&
1758 { ac_try='test -s "conftest.$ac_objext"'
1759 { (eval echo "$as_me:1759: \"$ac_try\"") >&5
1762 echo "$as_me:1762: \$? = $ac_status" >&5
1763 (exit "$ac_status"); }; }; then
1766 echo "$as_me: failed program was:" >&5
1767 cat "conftest.$ac_ext" >&5
1770 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
1772 echo "$as_me:1772: result: $ac_cv_prog_cc_g" >&5
1773 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
1774 if test "$ac_test_CFLAGS" = set; then
1775 CFLAGS=$ac_save_CFLAGS
1776 elif test $ac_cv_prog_cc_g = yes; then
1777 if test "$GCC" = yes; then
1783 if test "$GCC" = yes; then
1789 # Some people use a C++ compiler to compile C. Since we use `exit',
1790 # in C++ we need to declare it. In case someone uses the same compiler
1791 # for both compiling C and C++ we need to have the C++ compiler decide
1792 # the declaration of exit, since it's the most demanding environment.
1793 cat >"conftest.$ac_ext" <<_ACEOF
1798 rm -f "conftest.$ac_objext"
1799 if { (eval echo "$as_me:1799: \"$ac_compile\"") >&5
1800 (eval $ac_compile) 2>&5
1802 echo "$as_me:1802: \$? = $ac_status" >&5
1803 (exit "$ac_status"); } &&
1804 { ac_try='test -s "conftest.$ac_objext"'
1805 { (eval echo "$as_me:1805: \"$ac_try\"") >&5
1808 echo "$as_me:1808: \$? = $ac_status" >&5
1809 (exit "$ac_status"); }; }; then
1810 for ac_declaration in \
1812 '#include <stdlib.h>' \
1813 'extern "C" void std::exit (int) throw (); using std::exit;' \
1814 'extern "C" void std::exit (int); using std::exit;' \
1815 'extern "C" void exit (int) throw ();' \
1816 'extern "C" void exit (int);' \
1819 cat >"conftest.$ac_ext" <<_ACEOF
1820 #line 1820 "configure"
1821 #include "confdefs.h"
1832 rm -f "conftest.$ac_objext"
1833 if { (eval echo "$as_me:1833: \"$ac_compile\"") >&5
1834 (eval $ac_compile) 2>&5
1836 echo "$as_me:1836: \$? = $ac_status" >&5
1837 (exit "$ac_status"); } &&
1838 { ac_try='test -s "conftest.$ac_objext"'
1839 { (eval echo "$as_me:1839: \"$ac_try\"") >&5
1842 echo "$as_me:1842: \$? = $ac_status" >&5
1843 (exit "$ac_status"); }; }; then
1846 echo "$as_me: failed program was:" >&5
1847 cat "conftest.$ac_ext" >&5
1850 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
1851 cat >"conftest.$ac_ext" <<_ACEOF
1852 #line 1852 "configure"
1853 #include "confdefs.h"
1863 rm -f "conftest.$ac_objext"
1864 if { (eval echo "$as_me:1864: \"$ac_compile\"") >&5
1865 (eval $ac_compile) 2>&5
1867 echo "$as_me:1867: \$? = $ac_status" >&5
1868 (exit "$ac_status"); } &&
1869 { ac_try='test -s "conftest.$ac_objext"'
1870 { (eval echo "$as_me:1870: \"$ac_try\"") >&5
1873 echo "$as_me:1873: \$? = $ac_status" >&5
1874 (exit "$ac_status"); }; }; then
1877 echo "$as_me: failed program was:" >&5
1878 cat "conftest.$ac_ext" >&5
1880 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
1883 if test -n "$ac_declaration"; then
1884 echo '#ifdef __cplusplus' >>confdefs.h
1885 echo "$ac_declaration" >>confdefs.h
1886 echo '#endif' >>confdefs.h
1890 echo "$as_me: failed program was:" >&5
1891 cat "conftest.$ac_ext" >&5
1893 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
1895 ac_cpp='$CPP $CPPFLAGS'
1896 ac_compile='$CC -c $CFLAGS $CPPFLAGS "conftest.$ac_ext" >&5'
1897 ac_link='$CC -o "conftest$ac_exeext" $CFLAGS $CPPFLAGS $LDFLAGS "conftest.$ac_ext" $LIBS >&5'
1898 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1899 ac_main_return="return"
1902 if test "$GCC" = yes ; then
1903 echo "$as_me:1903: checking version of $CC" >&5
1904 echo $ECHO_N "checking version of $CC... $ECHO_C" >&6
1905 GCC_VERSION="`${CC} --version 2>/dev/null | sed -e '2,$d' -e 's/^[^(]*([^)][^)]*) //' -e 's/^[^0-9.]*//' -e 's/[^0-9.].*//'`"
1906 test -z "$GCC_VERSION" && GCC_VERSION=unknown
1907 echo "$as_me:1907: result: $GCC_VERSION" >&5
1908 echo "${ECHO_T}$GCC_VERSION" >&6
1913 if test "$GCC" = yes ; then
1916 echo "$as_me:1916: checking if this is really Intel C compiler" >&5
1917 echo $ECHO_N "checking if this is really Intel C compiler... $ECHO_C" >&6
1918 cf_save_CFLAGS="$CFLAGS"
1919 CFLAGS="$CFLAGS -no-gcc"
1920 cat >"conftest.$ac_ext" <<_ACEOF
1921 #line 1921 "configure"
1922 #include "confdefs.h"
1928 #ifdef __INTEL_COMPILER
1930 #error __INTEL_COMPILER is not defined
1937 rm -f "conftest.$ac_objext"
1938 if { (eval echo "$as_me:1938: \"$ac_compile\"") >&5
1939 (eval $ac_compile) 2>&5
1941 echo "$as_me:1941: \$? = $ac_status" >&5
1942 (exit "$ac_status"); } &&
1943 { ac_try='test -s "conftest.$ac_objext"'
1944 { (eval echo "$as_me:1944: \"$ac_try\"") >&5
1947 echo "$as_me:1947: \$? = $ac_status" >&5
1948 (exit "$ac_status"); }; }; then
1950 cf_save_CFLAGS="$cf_save_CFLAGS -we147"
1953 echo "$as_me: failed program was:" >&5
1954 cat "conftest.$ac_ext" >&5
1956 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
1957 CFLAGS="$cf_save_CFLAGS"
1958 echo "$as_me:1958: result: $INTEL_COMPILER" >&5
1959 echo "${ECHO_T}$INTEL_COMPILER" >&6
1966 if test "$GCC" = yes ; then
1967 echo "$as_me:1967: checking if this is really Clang C compiler" >&5
1968 echo $ECHO_N "checking if this is really Clang C compiler... $ECHO_C" >&6
1969 cf_save_CFLAGS="$CFLAGS"
1970 cat >"conftest.$ac_ext" <<_ACEOF
1971 #line 1971 "configure"
1972 #include "confdefs.h"
1980 #error __clang__ is not defined
1987 rm -f "conftest.$ac_objext"
1988 if { (eval echo "$as_me:1988: \"$ac_compile\"") >&5
1989 (eval $ac_compile) 2>&5
1991 echo "$as_me:1991: \$? = $ac_status" >&5
1992 (exit "$ac_status"); } &&
1993 { ac_try='test -s "conftest.$ac_objext"'
1994 { (eval echo "$as_me:1994: \"$ac_try\"") >&5
1997 echo "$as_me:1997: \$? = $ac_status" >&5
1998 (exit "$ac_status"); }; }; then
2002 echo "$as_me: failed program was:" >&5
2003 cat "conftest.$ac_ext" >&5
2005 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
2006 CFLAGS="$cf_save_CFLAGS"
2007 echo "$as_me:2007: result: $CLANG_COMPILER" >&5
2008 echo "${ECHO_T}$CLANG_COMPILER" >&6
2013 if test "x$CLANG_COMPILER" = "xyes" ; then
2015 (c[1-9][0-9]|*/c[1-9][0-9])
2016 { echo "$as_me:2016: WARNING: replacing broken compiler alias $CC" >&5
2017 echo "$as_me: WARNING: replacing broken compiler alias $CC" >&2;}
2018 CFLAGS="$CFLAGS -std=`echo "$CC" | sed -e 's%.*/%%'`"
2023 echo "$as_me:2023: checking version of $CC" >&5
2024 echo $ECHO_N "checking version of $CC... $ECHO_C" >&6
2025 CLANG_VERSION="`$CC --version 2>/dev/null | sed -e '2,$d' -e 's/^.*(CLANG[^)]*) //' -e 's/^.*(Debian[^)]*) //' -e 's/^[^0-9.]*//' -e 's/[^0-9.].*//'`"
2026 test -z "$CLANG_VERSION" && CLANG_VERSION=unknown
2027 echo "$as_me:2027: result: $CLANG_VERSION" >&5
2028 echo "${ECHO_T}$CLANG_VERSION" >&6
2030 for cf_clang_opt in \
2031 -Qunused-arguments \
2032 -Wno-error=implicit-function-declaration
2034 echo "$as_me:2034: checking if option $cf_clang_opt works" >&5
2035 echo $ECHO_N "checking if option $cf_clang_opt works... $ECHO_C" >&6
2036 cf_save_CFLAGS="$CFLAGS"
2037 CFLAGS="$CFLAGS $cf_clang_opt"
2038 cat >"conftest.$ac_ext" <<_ACEOF
2039 #line 2039 "configure"
2040 #include "confdefs.h"
2047 printf("hello!\\n");
2052 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
2053 if { (eval echo "$as_me:2053: \"$ac_link\"") >&5
2054 (eval $ac_link) 2>&5
2056 echo "$as_me:2056: \$? = $ac_status" >&5
2057 (exit "$ac_status"); } &&
2058 { ac_try='test -s "conftest$ac_exeext"'
2059 { (eval echo "$as_me:2059: \"$ac_try\"") >&5
2062 echo "$as_me:2062: \$? = $ac_status" >&5
2063 (exit "$ac_status"); }; }; then
2067 echo "$as_me: failed program was:" >&5
2068 cat "conftest.$ac_ext" >&5
2072 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
2073 echo "$as_me:2073: result: $cf_clang_optok" >&5
2074 echo "${ECHO_T}$cf_clang_optok" >&6
2075 CFLAGS="$cf_save_CFLAGS"
2076 if test "$cf_clang_optok" = yes; then
2077 test -n "$verbose" && echo " adding option $cf_clang_opt" 1>&6
2079 echo "${as_me:-configure}:2079: testing adding option $cf_clang_opt ..." 1>&5
2081 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
2082 CFLAGS="${CFLAGS}$cf_clang_opt"
2088 echo "$as_me:2088: checking for $CC option to accept ANSI C" >&5
2089 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
2090 if test "${ac_cv_prog_cc_stdc+set}" = set; then
2091 echo $ECHO_N "(cached) $ECHO_C" >&6
2093 ac_cv_prog_cc_stdc=no
2095 cat >"conftest.$ac_ext" <<_ACEOF
2096 #line 2096 "configure"
2097 #include "confdefs.h"
2100 #include <sys/types.h>
2101 #include <sys/stat.h>
2102 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
2103 struct buf { int x; };
2104 FILE * (*rcsopen) (struct buf *, struct stat *, int);
2105 static char *e (char **p, int i)
2109 static char *f (char * (*g) (char **, int), char **p, ...)
2114 s = g (p, va_arg (v,int));
2118 int test (int i, double x);
2119 struct s1 {int (*f) (int a);};
2120 struct s2 {int (*f) (double a);};
2121 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
2127 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
2132 # Don't try gcc -ansi; that turns off useful extensions and
2133 # breaks some systems' header files.
2134 # AIX -qlanglvl=ansi
2135 # Ultrix and OSF/1 -std1
2136 # HP-UX 10.20 and later -Ae
2137 # HP-UX older versions -Aa -D_HPUX_SOURCE
2138 # SVR4 -Xc -D__EXTENSIONS__
2139 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
2141 CC="$ac_save_CC $ac_arg"
2142 rm -f "conftest.$ac_objext"
2143 if { (eval echo "$as_me:2143: \"$ac_compile\"") >&5
2144 (eval $ac_compile) 2>&5
2146 echo "$as_me:2146: \$? = $ac_status" >&5
2147 (exit "$ac_status"); } &&
2148 { ac_try='test -s "conftest.$ac_objext"'
2149 { (eval echo "$as_me:2149: \"$ac_try\"") >&5
2152 echo "$as_me:2152: \$? = $ac_status" >&5
2153 (exit "$ac_status"); }; }; then
2154 ac_cv_prog_cc_stdc=$ac_arg
2157 echo "$as_me: failed program was:" >&5
2158 cat "conftest.$ac_ext" >&5
2160 rm -f "conftest.$ac_objext"
2162 rm -f "conftest.$ac_ext" "conftest.$ac_objext"
2167 case "x$ac_cv_prog_cc_stdc" in
2169 echo "$as_me:2169: result: none needed" >&5
2170 echo "${ECHO_T}none needed" >&6 ;;
2172 echo "$as_me:2172: result: $ac_cv_prog_cc_stdc" >&5
2173 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
2174 CC="$CC $ac_cv_prog_cc_stdc" ;;
2177 # This should have been defined by AC_PROG_CC
2180 echo "$as_me:2180: checking \$CFLAGS variable" >&5
2181 echo $ECHO_N "checking \$CFLAGS variable... $ECHO_C" >&6
2184 echo "$as_me:2184: result: broken" >&5
2185 echo "${ECHO_T}broken" >&6
2186 { echo "$as_me:2186: WARNING: your environment uses the CFLAGS variable to hold CPPFLAGS options" >&5
2187 echo "$as_me: WARNING: your environment uses the CFLAGS variable to hold CPPFLAGS options" >&2;}
2190 for cf_arg in $cf_flags
2196 cf_new_extra_cppflags=
2198 for cf_add_cflags in $cf_arg
2200 case "$cf_fix_cppflags" in
2202 case "$cf_add_cflags" in
2203 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
2204 case "$cf_add_cflags" in
2206 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
2208 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2209 && test -z "${cf_tst_cflags}" \
2210 && cf_fix_cppflags=yes
2212 if test "$cf_fix_cppflags" = yes ; then
2214 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2215 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2218 elif test "${cf_tst_cflags}" = "\"'" ; then
2220 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2221 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2231 case "$cf_add_cflags" in
2233 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
2235 CPPFLAGS=`echo "$CPPFLAGS" | \
2236 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
2237 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
2242 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
2243 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
2250 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
2251 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
2258 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2259 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2261 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
2263 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2264 && test -z "${cf_tst_cflags}" \
2265 && cf_fix_cppflags=no
2270 if test -n "$cf_new_cflags" ; then
2272 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
2273 CFLAGS="${CFLAGS}$cf_new_cflags"
2277 if test -n "$cf_new_cppflags" ; then
2279 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
2280 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
2284 if test -n "$cf_new_extra_cppflags" ; then
2286 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
2287 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
2294 echo "$as_me:2294: result: ok" >&5
2295 echo "${ECHO_T}ok" >&6
2299 echo "$as_me:2299: checking \$CC variable" >&5
2300 echo $ECHO_N "checking \$CC variable... $ECHO_C" >&6
2303 echo "$as_me:2303: result: broken" >&5
2304 echo "${ECHO_T}broken" >&6
2305 { echo "$as_me:2305: WARNING: your environment uses the CC variable to hold CFLAGS/CPPFLAGS options" >&5
2306 echo "$as_me: WARNING: your environment uses the CC variable to hold CFLAGS/CPPFLAGS options" >&2;}
2308 cf_prog=`echo "$CC" | sed -e 's/ / /g' -e 's/[ ]* / /g' -e 's/[ ]*[ ]-[^ ].*//'`
2309 cf_flags=`echo "$CC" | sed -e "s%^$cf_prog%%"`
2311 for cf_arg in $cf_flags
2319 cf_new_extra_cppflags=
2321 for cf_add_cflags in $cf_arg
2323 case "$cf_fix_cppflags" in
2325 case "$cf_add_cflags" in
2326 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
2327 case "$cf_add_cflags" in
2329 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
2331 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2332 && test -z "${cf_tst_cflags}" \
2333 && cf_fix_cppflags=yes
2335 if test "$cf_fix_cppflags" = yes ; then
2337 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2338 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2341 elif test "${cf_tst_cflags}" = "\"'" ; then
2343 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2344 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2354 case "$cf_add_cflags" in
2356 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
2358 CPPFLAGS=`echo "$CPPFLAGS" | \
2359 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
2360 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
2365 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
2366 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
2373 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
2374 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
2381 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2382 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2384 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
2386 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2387 && test -z "${cf_tst_cflags}" \
2388 && cf_fix_cppflags=no
2393 if test -n "$cf_new_cflags" ; then
2395 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
2396 CFLAGS="${CFLAGS}$cf_new_cflags"
2400 if test -n "$cf_new_cppflags" ; then
2402 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
2403 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
2407 if test -n "$cf_new_extra_cppflags" ; then
2409 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
2410 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
2420 test -n "$verbose" && echo " resulting CC: '$CC'" 1>&6
2422 echo "${as_me:-configure}:2422: testing resulting CC: '$CC' ..." 1>&5
2424 test -n "$verbose" && echo " resulting CFLAGS: '$CFLAGS'" 1>&6
2426 echo "${as_me:-configure}:2426: testing resulting CFLAGS: '$CFLAGS' ..." 1>&5
2428 test -n "$verbose" && echo " resulting CPPFLAGS: '$CPPFLAGS'" 1>&6
2430 echo "${as_me:-configure}:2430: testing resulting CPPFLAGS: '$CPPFLAGS' ..." 1>&5
2434 echo "$as_me:2434: result: ok" >&5
2435 echo "${ECHO_T}ok" >&6
2439 echo "$as_me:2439: checking for inline" >&5
2440 echo $ECHO_N "checking for inline... $ECHO_C" >&6
2441 if test "${ac_cv_c_inline+set}" = set; then
2442 echo $ECHO_N "(cached) $ECHO_C" >&6
2445 for ac_kw in inline __inline__ __inline; do
2446 cat >"conftest.$ac_ext" <<_ACEOF
2447 #line 2447 "configure"
2448 #include "confdefs.h"
2450 static $ac_kw int static_foo (void) {return 0; }
2451 $ac_kw int foo (void) {return 0; }
2455 rm -f "conftest.$ac_objext"
2456 if { (eval echo "$as_me:2456: \"$ac_compile\"") >&5
2457 (eval $ac_compile) 2>&5
2459 echo "$as_me:2459: \$? = $ac_status" >&5
2460 (exit "$ac_status"); } &&
2461 { ac_try='test -s "conftest.$ac_objext"'
2462 { (eval echo "$as_me:2462: \"$ac_try\"") >&5
2465 echo "$as_me:2465: \$? = $ac_status" >&5
2466 (exit "$ac_status"); }; }; then
2467 ac_cv_c_inline=$ac_kw; break
2469 echo "$as_me: failed program was:" >&5
2470 cat "conftest.$ac_ext" >&5
2472 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
2476 echo "$as_me:2476: result: $ac_cv_c_inline" >&5
2477 echo "${ECHO_T}$ac_cv_c_inline" >&6
2478 case $ac_cv_c_inline in
2481 cat >>confdefs.h <<\EOF
2485 *) cat >>confdefs.h <<EOF
2486 #define inline $ac_cv_c_inline
2491 for ac_prog in ggrep grep
2493 # Extract the first word of "$ac_prog", so it can be a program name with args.
2494 set dummy $ac_prog; ac_word=$2
2495 echo "$as_me:2495: checking for $ac_word" >&5
2496 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2497 if test "${ac_cv_prog_GREP+set}" = set; then
2498 echo $ECHO_N "(cached) $ECHO_C" >&6
2500 if test -n "$GREP"; then
2501 ac_cv_prog_GREP="$GREP" # Let the user override the test.
2503 ac_save_IFS=$IFS; IFS=$ac_path_separator
2505 for ac_dir in $ac_dummy; do
2507 test -z "$ac_dir" && ac_dir=.
2508 $as_executable_p "$ac_dir/$ac_word" || continue
2509 ac_cv_prog_GREP="$ac_prog"
2510 echo "$as_me:2510: found $ac_dir/$ac_word" >&5
2516 GREP=$ac_cv_prog_GREP
2517 if test -n "$GREP"; then
2518 echo "$as_me:2518: result: $GREP" >&5
2519 echo "${ECHO_T}$GREP" >&6
2521 echo "$as_me:2521: result: no" >&5
2522 echo "${ECHO_T}no" >&6
2525 test -n "$GREP" && break
2527 test -n "$GREP" || GREP=": "
2529 echo "$as_me:2529: checking for egrep" >&5
2530 echo $ECHO_N "checking for egrep... $ECHO_C" >&6
2531 if test "${ac_cv_path_EGREP+set}" = set; then
2532 echo $ECHO_N "(cached) $ECHO_C" >&6
2534 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
2535 then ac_cv_path_EGREP="$GREP -E"
2537 for ac_prog in gegrep egrep
2539 # Extract the first word of "$ac_prog", so it can be a program name with args.
2540 set dummy $ac_prog; ac_word=$2
2541 echo "$as_me:2541: checking for $ac_word" >&5
2542 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2543 if test "${ac_cv_path_EGREP+set}" = set; then
2544 echo $ECHO_N "(cached) $ECHO_C" >&6
2548 ac_cv_path_EGREP="$EGREP" # Let the user override the test with a path.
2551 ac_save_IFS=$IFS; IFS=$ac_path_separator
2553 for ac_dir in $ac_dummy; do
2555 test -z "$ac_dir" && ac_dir=.
2556 if $as_executable_p "$ac_dir/$ac_word"; then
2557 ac_cv_path_EGREP="$ac_dir/$ac_word"
2558 echo "$as_me:2558: found $ac_dir/$ac_word" >&5
2566 EGREP=$ac_cv_path_EGREP
2568 if test -n "$EGREP"; then
2569 echo "$as_me:2569: result: $EGREP" >&5
2570 echo "${ECHO_T}$EGREP" >&6
2572 echo "$as_me:2572: result: no" >&5
2573 echo "${ECHO_T}no" >&6
2576 test -n "$EGREP" && break
2578 test -n "$EGREP" || EGREP=": "
2580 test "x$ac_cv_path_EGREP" = "x:" && { { echo "$as_me:2580: error: cannot find workable egrep" >&5
2581 echo "$as_me: error: cannot find workable egrep" >&2;}
2582 { (exit 1); exit 1; }; }
2585 echo "$as_me:2585: result: $ac_cv_path_EGREP" >&5
2586 echo "${ECHO_T}$ac_cv_path_EGREP" >&6
2587 EGREP="$ac_cv_path_EGREP"
2590 ac_cpp='$CPP $CPPFLAGS'
2591 ac_compile='$CC -c $CFLAGS $CPPFLAGS "conftest.$ac_ext" >&5'
2592 ac_link='$CC -o "conftest$ac_exeext" $CFLAGS $CPPFLAGS $LDFLAGS "conftest.$ac_ext" $LIBS >&5'
2593 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2594 ac_main_return="return"
2595 echo "$as_me:2595: checking how to run the C preprocessor" >&5
2596 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
2597 # On Suns, sometimes $CPP names a directory.
2598 if test -n "$CPP" && test -d "$CPP"; then
2601 if test -z "$CPP"; then
2602 if test "${ac_cv_prog_CPP+set}" = set; then
2603 echo $ECHO_N "(cached) $ECHO_C" >&6
2605 # Double quotes because CPP needs to be expanded
2606 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
2609 for ac_c_preproc_warn_flag in '' yes
2611 # Use a header file that comes with gcc, so configuring glibc
2612 # with a fresh cross-compiler works.
2613 # On the NeXT, cc -E runs the code through the compiler's parser,
2614 # not just through cpp. "Syntax error" is here to catch this case.
2615 cat >"conftest.$ac_ext" <<_ACEOF
2616 #line 2616 "configure"
2617 #include "confdefs.h"
2621 if { (eval echo "$as_me:2621: \"$ac_cpp "conftest.$ac_ext"\"") >&5
2622 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
2624 $EGREP -v '^ *\+' conftest.er1 >conftest.err
2626 cat conftest.err >&5
2627 echo "$as_me:2627: \$? = $ac_status" >&5
2628 (exit "$ac_status"); } >/dev/null; then
2629 if test -s conftest.err; then
2630 ac_cpp_err=$ac_c_preproc_warn_flag
2637 if test -z "$ac_cpp_err"; then
2640 echo "$as_me: failed program was:" >&5
2641 cat "conftest.$ac_ext" >&5
2642 # Broken: fails on valid input.
2645 rm -f conftest.err "conftest.$ac_ext"
2647 # OK, works on sane cases. Now check whether non-existent headers
2648 # can be detected and how.
2649 cat >"conftest.$ac_ext" <<_ACEOF
2650 #line 2650 "configure"
2651 #include "confdefs.h"
2652 #include <ac_nonexistent.h>
2654 if { (eval echo "$as_me:2654: \"$ac_cpp "conftest.$ac_ext"\"") >&5
2655 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
2657 $EGREP -v '^ *\+' conftest.er1 >conftest.err
2659 cat conftest.err >&5
2660 echo "$as_me:2660: \$? = $ac_status" >&5
2661 (exit "$ac_status"); } >/dev/null; then
2662 if test -s conftest.err; then
2663 ac_cpp_err=$ac_c_preproc_warn_flag
2670 if test -z "$ac_cpp_err"; then
2671 # Broken: success on invalid input.
2674 echo "$as_me: failed program was:" >&5
2675 cat "conftest.$ac_ext" >&5
2676 # Passes both tests.
2680 rm -f conftest.err "conftest.$ac_ext"
2683 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2684 rm -f conftest.err "conftest.$ac_ext"
2685 if $ac_preproc_ok; then
2697 echo "$as_me:2697: result: $CPP" >&5
2698 echo "${ECHO_T}$CPP" >&6
2700 for ac_c_preproc_warn_flag in '' yes
2702 # Use a header file that comes with gcc, so configuring glibc
2703 # with a fresh cross-compiler works.
2704 # On the NeXT, cc -E runs the code through the compiler's parser,
2705 # not just through cpp. "Syntax error" is here to catch this case.
2706 cat >"conftest.$ac_ext" <<_ACEOF
2707 #line 2707 "configure"
2708 #include "confdefs.h"
2712 if { (eval echo "$as_me:2712: \"$ac_cpp "conftest.$ac_ext"\"") >&5
2713 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
2715 $EGREP -v '^ *\+' conftest.er1 >conftest.err
2717 cat conftest.err >&5
2718 echo "$as_me:2718: \$? = $ac_status" >&5
2719 (exit "$ac_status"); } >/dev/null; then
2720 if test -s conftest.err; then
2721 ac_cpp_err=$ac_c_preproc_warn_flag
2728 if test -z "$ac_cpp_err"; then
2731 echo "$as_me: failed program was:" >&5
2732 cat "conftest.$ac_ext" >&5
2733 # Broken: fails on valid input.
2736 rm -f conftest.err "conftest.$ac_ext"
2738 # OK, works on sane cases. Now check whether non-existent headers
2739 # can be detected and how.
2740 cat >"conftest.$ac_ext" <<_ACEOF
2741 #line 2741 "configure"
2742 #include "confdefs.h"
2743 #include <ac_nonexistent.h>
2745 if { (eval echo "$as_me:2745: \"$ac_cpp "conftest.$ac_ext"\"") >&5
2746 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
2748 $EGREP -v '^ *\+' conftest.er1 >conftest.err
2750 cat conftest.err >&5
2751 echo "$as_me:2751: \$? = $ac_status" >&5
2752 (exit "$ac_status"); } >/dev/null; then
2753 if test -s conftest.err; then
2754 ac_cpp_err=$ac_c_preproc_warn_flag
2761 if test -z "$ac_cpp_err"; then
2762 # Broken: success on invalid input.
2765 echo "$as_me: failed program was:" >&5
2766 cat "conftest.$ac_ext" >&5
2767 # Passes both tests.
2771 rm -f conftest.err "conftest.$ac_ext"
2774 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2775 rm -f conftest.err "conftest.$ac_ext"
2776 if $ac_preproc_ok; then
2779 { { echo "$as_me:2779: error: C preprocessor \"$CPP\" fails sanity check" >&5
2780 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;}
2781 { (exit 1); exit 1; }; }
2785 ac_cpp='$CPP $CPPFLAGS'
2786 ac_compile='$CC -c $CFLAGS $CPPFLAGS "conftest.$ac_ext" >&5'
2787 ac_link='$CC -o "conftest$ac_exeext" $CFLAGS $CPPFLAGS $LDFLAGS "conftest.$ac_ext" $LIBS >&5'
2788 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2789 ac_main_return="return"
2791 for ac_prog in mawk gawk nawk awk
2793 # Extract the first word of "$ac_prog", so it can be a program name with args.
2794 set dummy $ac_prog; ac_word=$2
2795 echo "$as_me:2795: checking for $ac_word" >&5
2796 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2797 if test "${ac_cv_prog_AWK+set}" = set; then
2798 echo $ECHO_N "(cached) $ECHO_C" >&6
2800 if test -n "$AWK"; then
2801 ac_cv_prog_AWK="$AWK" # Let the user override the test.
2803 ac_save_IFS=$IFS; IFS=$ac_path_separator
2805 for ac_dir in $ac_dummy; do
2807 test -z "$ac_dir" && ac_dir=.
2808 $as_executable_p "$ac_dir/$ac_word" || continue
2809 ac_cv_prog_AWK="$ac_prog"
2810 echo "$as_me:2810: found $ac_dir/$ac_word" >&5
2817 if test -n "$AWK"; then
2818 echo "$as_me:2818: result: $AWK" >&5
2819 echo "${ECHO_T}$AWK" >&6
2821 echo "$as_me:2821: result: no" >&5
2822 echo "${ECHO_T}no" >&6
2825 test -n "$AWK" && break
2828 # Find a good install program. We prefer a C program (faster),
2829 # so one script is as good as another. But avoid the broken or
2830 # incompatible versions:
2831 # SysV /etc/install, /usr/sbin/install
2832 # SunOS /usr/etc/install
2833 # IRIX /sbin/install
2835 # AmigaOS /C/install, which installs bootblocks on floppy discs
2836 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
2837 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
2838 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
2839 # ./install, which can be erroneously created by make from ./install.sh.
2840 echo "$as_me:2840: checking for a BSD compatible install" >&5
2841 echo $ECHO_N "checking for a BSD compatible install... $ECHO_C" >&6
2842 if test -z "$INSTALL"; then
2843 if test "${ac_cv_path_install+set}" = set; then
2844 echo $ECHO_N "(cached) $ECHO_C" >&6
2846 ac_save_IFS=$IFS; IFS=$ac_path_separator
2847 for ac_dir in $PATH; do
2849 # Account for people who put trailing slashes in PATH elements.
2851 / | ./ | .// | /cC/* \
2852 | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* \
2855 # OSF1 and SCO ODT 3.0 have their own names for install.
2856 # Don't use installbsd from OSF since it installs stuff as root
2858 for ac_prog in ginstall scoinst install; do
2859 if $as_executable_p "$ac_dir/$ac_prog"; then
2860 if test $ac_prog = install &&
2861 grep dspmsg "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2862 # AIX install. It has an incompatible calling convention.
2864 elif test $ac_prog = install &&
2865 grep pwplus "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2866 # program-specific install script used by HP pwplus--don't use.
2869 ac_cv_path_install="$ac_dir/$ac_prog -c"
2879 if test "${ac_cv_path_install+set}" = set; then
2880 INSTALL=$ac_cv_path_install
2882 # As a last resort, use the slow shell script. We don't cache a
2883 # path for INSTALL within a source directory, because that will
2884 # break other packages using the cache if that directory is
2885 # removed, or if the path is relative.
2886 INSTALL=$ac_install_sh
2889 echo "$as_me:2889: result: $INSTALL" >&5
2890 echo "${ECHO_T}$INSTALL" >&6
2892 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
2893 # It thinks the first close brace ends the variable substitution.
2894 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
2896 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
2898 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
2904 cf_dir=`echo "$INSTALL" | sed -e 's%/[^/]*$%%'`
2905 test -z "$cf_dir" && cf_dir=.
2906 INSTALL="`cd \"$cf_dir\" && pwd`"/"`echo "$INSTALL" | sed -e 's%^.*/%%'`"
2910 echo "$as_me:2910: checking if you want to install stripped executables" >&5
2911 echo $ECHO_N "checking if you want to install stripped executables... $ECHO_C" >&6
2913 # Check whether --enable-stripping or --disable-stripping was given.
2914 if test "${enable_stripping+set}" = set; then
2915 enableval="$enable_stripping"
2916 test "$enableval" != no && enableval=yes
2917 if test "$enableval" != "yes" ; then
2920 enable_stripping=yes
2924 enable_stripping=yes
2927 echo "$as_me:2927: result: $enable_stripping" >&5
2928 echo "${ECHO_T}$enable_stripping" >&6
2930 if test "$enable_stripping" = yes
2937 : "${INSTALL:=install}"
2938 echo "$as_me:2938: checking if install accepts -p option" >&5
2939 echo $ECHO_N "checking if install accepts -p option... $ECHO_C" >&6
2940 if test "${cf_cv_install_p+set}" = set; then
2941 echo $ECHO_N "(cached) $ECHO_C" >&6
2948 if $INSTALL -p conftest.in conftest.out 2>/dev/null
2950 if test -f conftest.out/conftest.in
2952 test conftest.in -nt conftest.out/conftest.in 2>conftest.err && \
2953 test conftest.out/conftest.in -nt conftest.in 2>conftest.err
2954 if test -s conftest.err
2969 echo "$as_me:2969: result: $cf_cv_install_p" >&5
2970 echo "${ECHO_T}$cf_cv_install_p" >&6
2972 echo "$as_me:2972: checking if install needs to be told about ownership" >&5
2973 echo $ECHO_N "checking if install needs to be told about ownership... $ECHO_C" >&6
2974 case `$ac_config_guess` in
2983 echo "$as_me:2983: result: $with_install_o" >&5
2984 echo "${ECHO_T}$with_install_o" >&6
2985 if test "x$with_install_o" = xyes
2987 INSTALL_OPT_O="`id root|sed -e 's/uid=[0-9]*(/ -o /' -e 's/gid=[0-9]*(/ -g /' -e 's/ [^=[:space:]][^=[:space:]]*=.*/ /' -e 's/)//g'`"
2992 if test -n "$INSTALL_OPT_S"
2994 echo "$as_me:2994: checking if you want to specify strip-program" >&5
2995 echo $ECHO_N "checking if you want to specify strip-program... $ECHO_C" >&6
2997 # Check whether --with-strip-program or --without-strip-program was given.
2998 if test "${with_strip_program+set}" = set; then
2999 withval="$with_strip_program"
3000 with_strip_program=$withval
3002 with_strip_program=no
3004 echo "$as_me:3004: result: $with_strip_program" >&5
3005 echo "${ECHO_T}$with_strip_program" >&6
3006 if test "$with_strip_program" != no
3008 echo "$as_me:3008: checking if strip-program is supported with this installer" >&5
3009 echo $ECHO_N "checking if strip-program is supported with this installer... $ECHO_C" >&6
3010 cf_install_program=`echo "$INSTALL" | sed -e 's%[ ]*[ ]-.%%'`
3011 check_install_strip=no
3012 if test -f "$cf_install_program"
3014 check_install_version=`"$cf_install_program" --version 2>/dev/null | head -n 1 | grep coreutils`
3015 if test -n "$check_install_version"
3017 check_install_strip="option"
3019 for check_strip_variable in STRIPBIN STRIP
3021 if strings "$cf_install_program" | grep "^$check_strip_variable$" >/dev/null
3023 check_install_strip="environ"
3029 echo "$as_me:3029: result: $check_install_strip" >&5
3030 echo "${ECHO_T}$check_install_strip" >&6
3031 case "$check_install_strip" in
3033 { echo "$as_me:3033: WARNING: $cf_install_program does not support strip program option" >&5
3034 echo "$as_me: WARNING: $cf_install_program does not support strip program option" >&2;}
3035 with_strip_program=no
3038 cat >install.tmp <<-CF_EOF
3040 STRIPBIN="$with_strip_program" \\
3041 STRIP="$with_strip_program" \\
3044 INSTALL="`pwd`/install.tmp"
3046 test -n "$verbose" && echo " created $INSTALL" 1>&6
3048 echo "${as_me:-configure}:3048: testing created $INSTALL ..." 1>&5
3052 INSTALL_OPT_S="$INSTALL_OPT_S --strip-program=\"$with_strip_program\""
3058 for ac_prog in lint cppcheck splint
3060 # Extract the first word of "$ac_prog", so it can be a program name with args.
3061 set dummy $ac_prog; ac_word=$2
3062 echo "$as_me:3062: checking for $ac_word" >&5
3063 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3064 if test "${ac_cv_prog_LINT+set}" = set; then
3065 echo $ECHO_N "(cached) $ECHO_C" >&6
3067 if test -n "$LINT"; then
3068 ac_cv_prog_LINT="$LINT" # Let the user override the test.
3070 ac_save_IFS=$IFS; IFS=$ac_path_separator
3072 for ac_dir in $ac_dummy; do
3074 test -z "$ac_dir" && ac_dir=.
3075 $as_executable_p "$ac_dir/$ac_word" || continue
3076 ac_cv_prog_LINT="$ac_prog"
3077 echo "$as_me:3077: found $ac_dir/$ac_word" >&5
3083 LINT=$ac_cv_prog_LINT
3084 if test -n "$LINT"; then
3085 echo "$as_me:3085: result: $LINT" >&5
3086 echo "${ECHO_T}$LINT" >&6
3088 echo "$as_me:3088: result: no" >&5
3089 echo "${ECHO_T}no" >&6
3092 test -n "$LINT" && break
3096 (xcppcheck|x*/cppcheck)
3097 test -z "$LINT_OPTS" && LINT_OPTS="--enable=all"
3101 echo "$as_me:3101: checking for \".PHONY\" make-support" >&5
3102 echo $ECHO_N "checking for \".PHONY\" make-support... $ECHO_C" >&6
3103 if test "${cf_cv_make_PHONY+set}" = set; then
3104 echo $ECHO_N "(cached) $ECHO_C" >&6
3109 mkdir conftest || exit 1
3111 cat >makefile <<'CF_EOF'
3115 @echo "** making $@ $(DATA)"
3117 @echo "** making $@ $(DATA)"
3119 @echo "** making $@ $(DATA)"
3122 @echo "** making $@ $(DATA)"
3125 for cf_data in 1 2 3
3127 ${MAKE:-make} always DATA=$cf_data
3128 ${MAKE:-make} once DATA=$cf_data
3129 ${MAKE:-make} -t always once
3130 if test -f always ; then
3131 echo "no (case 1)" > ../conftest.tmp
3132 elif test ! -f always.out ; then
3133 echo "no (case 2)" > ../conftest.tmp
3134 elif test ! -f once.out ; then
3135 echo "no (case 3)" > ../conftest.tmp
3136 elif ! cmp -s always.out once.out ; then
3137 echo "no (case 4)" > ../conftest.tmp
3138 diff always.out once.out
3140 cf_check="`cat always.out`"
3141 if test "x$cf_check" != "x$cf_data" ; then
3142 echo "no (case 5)" > ../conftest.tmp
3144 echo yes > ../conftest.tmp
3152 cf_cv_make_PHONY="`cat conftest.tmp`"
3156 echo "$as_me:3156: result: $cf_cv_make_PHONY" >&5
3157 echo "${ECHO_T}$cf_cv_make_PHONY" >&6
3160 test "x$cf_cv_make_PHONY" = xyes && MAKE_PHONY=
3161 test "x$cf_cv_make_PHONY" != xyes && MAKE_NO_PHONY=
3163 echo "$as_me:3163: checking if filesystem supports mixed-case filenames" >&5
3164 echo $ECHO_N "checking if filesystem supports mixed-case filenames... $ECHO_C" >&6
3165 if test "${cf_cv_mixedcase+set}" = set; then
3166 echo $ECHO_N "(cached) $ECHO_C" >&6
3169 if test "$cross_compiling" = yes ; then
3170 case "$target_alias" in
3171 (*-os2-emx*|*-msdosdjgpp*|*-cygwin*|*-msys*|*-mingw*|*-uwin*|darwin*)
3179 rm -f conftest CONFTEST
3181 if test -f CONFTEST ; then
3186 rm -f conftest CONFTEST
3190 echo "$as_me:3190: result: $cf_cv_mixedcase" >&5
3191 echo "${ECHO_T}$cf_cv_mixedcase" >&6
3192 test "$cf_cv_mixedcase" = yes &&
3193 cat >>confdefs.h <<\EOF
3194 #define MIXEDCASE_FILENAMES 1
3197 for ac_prog in exctags ctags
3199 # Extract the first word of "$ac_prog", so it can be a program name with args.
3200 set dummy $ac_prog; ac_word=$2
3201 echo "$as_me:3201: checking for $ac_word" >&5
3202 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3203 if test "${ac_cv_prog_CTAGS+set}" = set; then
3204 echo $ECHO_N "(cached) $ECHO_C" >&6
3206 if test -n "$CTAGS"; then
3207 ac_cv_prog_CTAGS="$CTAGS" # Let the user override the test.
3209 ac_save_IFS=$IFS; IFS=$ac_path_separator
3211 for ac_dir in $ac_dummy; do
3213 test -z "$ac_dir" && ac_dir=.
3214 $as_executable_p "$ac_dir/$ac_word" || continue
3215 ac_cv_prog_CTAGS="$ac_prog"
3216 echo "$as_me:3216: found $ac_dir/$ac_word" >&5
3222 CTAGS=$ac_cv_prog_CTAGS
3223 if test -n "$CTAGS"; then
3224 echo "$as_me:3224: result: $CTAGS" >&5
3225 echo "${ECHO_T}$CTAGS" >&6
3227 echo "$as_me:3227: result: no" >&5
3228 echo "${ECHO_T}no" >&6
3231 test -n "$CTAGS" && break
3234 for ac_prog in exetags etags
3236 # Extract the first word of "$ac_prog", so it can be a program name with args.
3237 set dummy $ac_prog; ac_word=$2
3238 echo "$as_me:3238: checking for $ac_word" >&5
3239 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3240 if test "${ac_cv_prog_ETAGS+set}" = set; then
3241 echo $ECHO_N "(cached) $ECHO_C" >&6
3243 if test -n "$ETAGS"; then
3244 ac_cv_prog_ETAGS="$ETAGS" # Let the user override the test.
3246 ac_save_IFS=$IFS; IFS=$ac_path_separator
3248 for ac_dir in $ac_dummy; do
3250 test -z "$ac_dir" && ac_dir=.
3251 $as_executable_p "$ac_dir/$ac_word" || continue
3252 ac_cv_prog_ETAGS="$ac_prog"
3253 echo "$as_me:3253: found $ac_dir/$ac_word" >&5
3259 ETAGS=$ac_cv_prog_ETAGS
3260 if test -n "$ETAGS"; then
3261 echo "$as_me:3261: result: $ETAGS" >&5
3262 echo "${ECHO_T}$ETAGS" >&6
3264 echo "$as_me:3264: result: no" >&5
3265 echo "${ECHO_T}no" >&6
3268 test -n "$ETAGS" && break
3271 # Extract the first word of "${CTAGS:-ctags}", so it can be a program name with args.
3272 set dummy ${CTAGS:-ctags}; ac_word=$2
3273 echo "$as_me:3273: checking for $ac_word" >&5
3274 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3275 if test "${ac_cv_prog_MAKE_LOWER_TAGS+set}" = set; then
3276 echo $ECHO_N "(cached) $ECHO_C" >&6
3278 if test -n "$MAKE_LOWER_TAGS"; then
3279 ac_cv_prog_MAKE_LOWER_TAGS="$MAKE_LOWER_TAGS" # Let the user override the test.
3281 ac_save_IFS=$IFS; IFS=$ac_path_separator
3283 for ac_dir in $ac_dummy; do
3285 test -z "$ac_dir" && ac_dir=.
3286 $as_executable_p "$ac_dir/$ac_word" || continue
3287 ac_cv_prog_MAKE_LOWER_TAGS="yes"
3288 echo "$as_me:3288: found $ac_dir/$ac_word" >&5
3292 test -z "$ac_cv_prog_MAKE_LOWER_TAGS" && ac_cv_prog_MAKE_LOWER_TAGS="no"
3295 MAKE_LOWER_TAGS=$ac_cv_prog_MAKE_LOWER_TAGS
3296 if test -n "$MAKE_LOWER_TAGS"; then
3297 echo "$as_me:3297: result: $MAKE_LOWER_TAGS" >&5
3298 echo "${ECHO_T}$MAKE_LOWER_TAGS" >&6
3300 echo "$as_me:3300: result: no" >&5
3301 echo "${ECHO_T}no" >&6
3304 if test "$cf_cv_mixedcase" = yes ; then
3305 # Extract the first word of "${ETAGS:-etags}", so it can be a program name with args.
3306 set dummy ${ETAGS:-etags}; ac_word=$2
3307 echo "$as_me:3307: checking for $ac_word" >&5
3308 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3309 if test "${ac_cv_prog_MAKE_UPPER_TAGS+set}" = set; then
3310 echo $ECHO_N "(cached) $ECHO_C" >&6
3312 if test -n "$MAKE_UPPER_TAGS"; then
3313 ac_cv_prog_MAKE_UPPER_TAGS="$MAKE_UPPER_TAGS" # Let the user override the test.
3315 ac_save_IFS=$IFS; IFS=$ac_path_separator
3317 for ac_dir in $ac_dummy; do
3319 test -z "$ac_dir" && ac_dir=.
3320 $as_executable_p "$ac_dir/$ac_word" || continue
3321 ac_cv_prog_MAKE_UPPER_TAGS="yes"
3322 echo "$as_me:3322: found $ac_dir/$ac_word" >&5
3326 test -z "$ac_cv_prog_MAKE_UPPER_TAGS" && ac_cv_prog_MAKE_UPPER_TAGS="no"
3329 MAKE_UPPER_TAGS=$ac_cv_prog_MAKE_UPPER_TAGS
3330 if test -n "$MAKE_UPPER_TAGS"; then
3331 echo "$as_me:3331: result: $MAKE_UPPER_TAGS" >&5
3332 echo "${ECHO_T}$MAKE_UPPER_TAGS" >&6
3334 echo "$as_me:3334: result: no" >&5
3335 echo "${ECHO_T}no" >&6
3342 if test "$MAKE_UPPER_TAGS" = yes ; then
3348 if test "$MAKE_LOWER_TAGS" = yes ; then
3354 echo "$as_me:3354: checking if -lm needed for math functions" >&5
3355 echo $ECHO_N "checking if -lm needed for math functions... $ECHO_C" >&6
3356 if test "${cf_cv_need_libm+set}" = set; then
3357 echo $ECHO_N "(cached) $ECHO_C" >&6
3360 cat >"conftest.$ac_ext" <<_ACEOF
3361 #line 3361 "configure"
3362 #include "confdefs.h"
3371 double x = rand(); printf("result = %g\\n", pow(sin(x),x))
3376 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
3377 if { (eval echo "$as_me:3377: \"$ac_link\"") >&5
3378 (eval $ac_link) 2>&5
3380 echo "$as_me:3380: \$? = $ac_status" >&5
3381 (exit "$ac_status"); } &&
3382 { ac_try='test -s "conftest$ac_exeext"'
3383 { (eval echo "$as_me:3383: \"$ac_try\"") >&5
3386 echo "$as_me:3386: \$? = $ac_status" >&5
3387 (exit "$ac_status"); }; }; then
3390 echo "$as_me: failed program was:" >&5
3391 cat "conftest.$ac_ext" >&5
3394 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
3396 echo "$as_me:3396: result: $cf_cv_need_libm" >&5
3397 echo "${ECHO_T}$cf_cv_need_libm" >&6
3399 if test "$cf_cv_need_libm" = yes
3402 cf_save_LIBS="$LIBS"
3404 echo "$as_me:3404: checking if -lm is available for math functions" >&5
3405 echo $ECHO_N "checking if -lm is available for math functions... $ECHO_C" >&6
3406 if test "${cf_cv_have_libm+set}" = set; then
3407 echo $ECHO_N "(cached) $ECHO_C" >&6
3410 cat >"conftest.$ac_ext" <<_ACEOF
3411 #line 3411 "configure"
3412 #include "confdefs.h"
3421 double x = rand(); printf("result = %g\\n", pow(sin(x),x))
3426 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
3427 if { (eval echo "$as_me:3427: \"$ac_link\"") >&5
3428 (eval $ac_link) 2>&5
3430 echo "$as_me:3430: \$? = $ac_status" >&5
3431 (exit "$ac_status"); } &&
3432 { ac_try='test -s "conftest$ac_exeext"'
3433 { (eval echo "$as_me:3433: \"$ac_try\"") >&5
3436 echo "$as_me:3436: \$? = $ac_status" >&5
3437 (exit "$ac_status"); }; }; then
3440 echo "$as_me: failed program was:" >&5
3441 cat "conftest.$ac_ext" >&5
3444 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
3446 echo "$as_me:3446: result: $cf_cv_have_libm" >&5
3447 echo "${ECHO_T}$cf_cv_have_libm" >&6
3448 LIBS="$cf_save_LIBS"
3450 if test "$cf_cv_have_libm" = yes
3458 if test "$cf_cv_have_libm" = yes
3461 cat >>confdefs.h <<\EOF
3462 #define HAVE_MATH_FUNCS 1
3470 CC_SHARED_OPTS=unknown
3471 CPPFLAGS="$CPPFLAGS"
3473 DFT_OBJ_SUBDIR=`pwd|sed -e's:.*/::'`
3474 DFT_UPR_MODEL="NORMAL"
3487 PACKAGE="ncurses-examples"
3493 TINFO_LIBS='$(LIBS_CURSES)'
3494 cf_cv_abi_version=""
3495 cf_cv_rel_version=""
3501 echo "$as_me:3501: checking for fgrep" >&5
3502 echo $ECHO_N "checking for fgrep... $ECHO_C" >&6
3503 if test "${ac_cv_path_FGREP+set}" = set; then
3504 echo $ECHO_N "(cached) $ECHO_C" >&6
3506 if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
3507 then ac_cv_path_FGREP="$GREP -F"
3509 for ac_prog in gfgrep fgrep
3511 # Extract the first word of "$ac_prog", so it can be a program name with args.
3512 set dummy $ac_prog; ac_word=$2
3513 echo "$as_me:3513: checking for $ac_word" >&5
3514 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3515 if test "${ac_cv_path_FGREP+set}" = set; then
3516 echo $ECHO_N "(cached) $ECHO_C" >&6
3520 ac_cv_path_FGREP="$FGREP" # Let the user override the test with a path.
3523 ac_save_IFS=$IFS; IFS=$ac_path_separator
3525 for ac_dir in $ac_dummy; do
3527 test -z "$ac_dir" && ac_dir=.
3528 if $as_executable_p "$ac_dir/$ac_word"; then
3529 ac_cv_path_FGREP="$ac_dir/$ac_word"
3530 echo "$as_me:3530: found $ac_dir/$ac_word" >&5
3538 FGREP=$ac_cv_path_FGREP
3540 if test -n "$FGREP"; then
3541 echo "$as_me:3541: result: $FGREP" >&5
3542 echo "${ECHO_T}$FGREP" >&6
3544 echo "$as_me:3544: result: no" >&5
3545 echo "${ECHO_T}no" >&6
3548 test -n "$FGREP" && break
3550 test -n "$FGREP" || FGREP=": "
3552 test "x$ac_cv_path_FGREP" = "x:" && { { echo "$as_me:3552: error: cannot find workable fgrep" >&5
3553 echo "$as_me: error: cannot find workable fgrep" >&2;}
3554 { (exit 1); exit 1; }; }
3557 echo "$as_me:3557: result: $ac_cv_path_FGREP" >&5
3558 echo "${ECHO_T}$ac_cv_path_FGREP" >&6
3559 FGREP="$ac_cv_path_FGREP"
3561 echo "$as_me:3561: checking if you want to use C11 _Noreturn feature" >&5
3562 echo $ECHO_N "checking if you want to use C11 _Noreturn feature... $ECHO_C" >&6
3564 # Check whether --enable-stdnoreturn or --disable-stdnoreturn was given.
3565 if test "${enable_stdnoreturn+set}" = set; then
3566 enableval="$enable_stdnoreturn"
3567 test "$enableval" != yes && enableval=no
3568 if test "$enableval" != "no" ; then
3569 enable_stdnoreturn=yes
3571 enable_stdnoreturn=no
3575 enable_stdnoreturn=no
3578 echo "$as_me:3578: result: $enable_stdnoreturn" >&5
3579 echo "${ECHO_T}$enable_stdnoreturn" >&6
3581 if test $enable_stdnoreturn = yes; then
3582 echo "$as_me:3582: checking for C11 _Noreturn feature" >&5
3583 echo $ECHO_N "checking for C11 _Noreturn feature... $ECHO_C" >&6
3584 if test "${cf_cv_c11_noreturn+set}" = set; then
3585 echo $ECHO_N "(cached) $ECHO_C" >&6
3587 cat >"conftest.$ac_ext" <<_ACEOF
3588 #line 3588 "configure"
3589 #include "confdefs.h"
3591 $ac_includes_default
3592 #include <stdnoreturn.h>
3593 static _Noreturn void giveup(void) { exit(0); }
3598 if (feof(stdin)) giveup()
3603 rm -f "conftest.$ac_objext"
3604 if { (eval echo "$as_me:3604: \"$ac_compile\"") >&5
3605 (eval $ac_compile) 2>&5
3607 echo "$as_me:3607: \$? = $ac_status" >&5
3608 (exit "$ac_status"); } &&
3609 { ac_try='test -s "conftest.$ac_objext"'
3610 { (eval echo "$as_me:3610: \"$ac_try\"") >&5
3613 echo "$as_me:3613: \$? = $ac_status" >&5
3614 (exit "$ac_status"); }; }; then
3615 cf_cv_c11_noreturn=yes
3617 echo "$as_me: failed program was:" >&5
3618 cat "conftest.$ac_ext" >&5
3619 cf_cv_c11_noreturn=no
3621 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
3624 echo "$as_me:3624: result: $cf_cv_c11_noreturn" >&5
3625 echo "${ECHO_T}$cf_cv_c11_noreturn" >&6
3627 cf_cv_c11_noreturn=no,
3630 if test "$cf_cv_c11_noreturn" = yes; then
3632 cat >>confdefs.h <<\EOF
3633 #define HAVE_STDNORETURN_H 1
3636 cat >>confdefs.h <<EOF
3637 #define STDC_NORETURN _Noreturn
3640 HAVE_STDNORETURN_H=1
3642 HAVE_STDNORETURN_H=0
3645 if test "$GCC" = yes || test "$GXX" = yes
3647 cat > conftest.i <<EOF
3649 #define GCC_PRINTF 0
3654 #ifndef GCC_NORETURN
3655 #define GCC_NORETURN /* nothing */
3658 #define GCC_UNUSED /* nothing */
3661 if test "$GCC" = yes
3663 { echo "$as_me:3663: checking for $CC __attribute__ directives..." >&5
3664 echo "$as_me: checking for $CC __attribute__ directives..." >&6;}
3665 cat > "conftest.$ac_ext" <<EOF
3666 #line 3666 "${as_me:-configure}"
3668 #include "confdefs.h"
3669 #include "conftest.h"
3670 #include "conftest.i"
3672 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
3674 #define GCC_PRINTFLIKE(fmt,var) /*nothing*/
3677 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
3679 #define GCC_SCANFLIKE(fmt,var) /*nothing*/
3681 extern void wow(char *,...) GCC_SCANFLIKE(1,2);
3682 extern GCC_NORETURN void oops(char *,...) GCC_PRINTFLIKE(1,2);
3683 extern GCC_NORETURN void foo(void);
3684 int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { (void)argc; (void)argv; return 0; }
3686 cf_printf_attribute=no
3687 cf_scanf_attribute=no
3688 for cf_attribute in scanf printf unused noreturn
3691 cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
3693 cf_directive="__attribute__(($cf_attribute))"
3694 echo "checking for $CC $cf_directive" 1>&5
3696 case "$cf_attribute" in
3698 cf_printf_attribute=yes
3699 cat >conftest.h <<EOF
3700 #define GCC_$cf_ATTRIBUTE 1
3704 cf_scanf_attribute=yes
3705 cat >conftest.h <<EOF
3706 #define GCC_$cf_ATTRIBUTE 1
3710 cat >conftest.h <<EOF
3711 #define GCC_$cf_ATTRIBUTE $cf_directive
3716 if { (eval echo "$as_me:3716: \"$ac_compile\"") >&5
3717 (eval $ac_compile) 2>&5
3719 echo "$as_me:3719: \$? = $ac_status" >&5
3720 (exit "$ac_status"); }; then
3721 test -n "$verbose" && echo "$as_me:3721: result: ... $cf_attribute" >&5
3722 echo "${ECHO_T}... $cf_attribute" >&6
3723 cat conftest.h >>confdefs.h
3724 case "$cf_attribute" in
3727 cat >>confdefs.h <<EOF
3728 #define GCC_NORETURN $cf_directive
3733 cf_value='/* nothing */'
3734 if test "$cf_printf_attribute" != no ; then
3735 cf_value='__attribute__((format(printf,fmt,var)))'
3737 cat >>confdefs.h <<\EOF
3738 #define GCC_PRINTF 1
3743 cat >>confdefs.h <<EOF
3744 #define GCC_PRINTFLIKE(fmt,var) $cf_value
3749 cf_value='/* nothing */'
3750 if test "$cf_scanf_attribute" != no ; then
3751 cf_value='__attribute__((format(scanf,fmt,var)))'
3753 cat >>confdefs.h <<\EOF
3759 cat >>confdefs.h <<EOF
3760 #define GCC_SCANFLIKE(fmt,var) $cf_value
3766 cat >>confdefs.h <<EOF
3767 #define GCC_UNUSED $cf_directive
3775 ${FGREP-fgrep} define conftest.i >>confdefs.h
3780 echo "$as_me:3780: checking if you want to work around bogus compiler/loader warnings" >&5
3781 echo $ECHO_N "checking if you want to work around bogus compiler/loader warnings... $ECHO_C" >&6
3783 # Check whether --enable-string-hacks or --disable-string-hacks was given.
3784 if test "${enable_string_hacks+set}" = set; then
3785 enableval="$enable_string_hacks"
3786 enable_string_hacks=$enableval
3788 enable_string_hacks=no
3790 echo "$as_me:3790: result: $enable_string_hacks" >&5
3791 echo "${ECHO_T}$enable_string_hacks" >&6
3793 if test "x$enable_string_hacks" = "xyes"; then
3795 cat >>confdefs.h <<\EOF
3796 #define USE_STRING_HACKS 1
3799 { echo "$as_me:3799: WARNING: enabling string-hacks to work around bogus compiler/loader warnings" >&5
3800 echo "$as_me: WARNING: enabling string-hacks to work around bogus compiler/loader warnings" >&2;}
3801 echo "$as_me:3801: checking for strlcat" >&5
3802 echo $ECHO_N "checking for strlcat... $ECHO_C" >&6
3803 if test "${ac_cv_func_strlcat+set}" = set; then
3804 echo $ECHO_N "(cached) $ECHO_C" >&6
3806 cat >"conftest.$ac_ext" <<_ACEOF
3807 #line 3807 "configure"
3808 #include "confdefs.h"
3809 #define strlcat autoconf_temporary
3810 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
3817 /* We use char because int might match the return type of a gcc2
3818 builtin and then its argument prototype would still apply. */
3819 char strlcat (void);
3825 /* The GNU C library defines stubs for functions which it implements
3826 to always fail with ENOSYS. Some functions are actually named
3827 something starting with __ and the normal name is an alias. */
3828 #if defined (__stub_strlcat) || defined (__stub___strlcat)
3829 #error found stub for strlcat
3837 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
3838 if { (eval echo "$as_me:3838: \"$ac_link\"") >&5
3839 (eval $ac_link) 2>&5
3841 echo "$as_me:3841: \$? = $ac_status" >&5
3842 (exit "$ac_status"); } &&
3843 { ac_try='test -s "conftest$ac_exeext"'
3844 { (eval echo "$as_me:3844: \"$ac_try\"") >&5
3847 echo "$as_me:3847: \$? = $ac_status" >&5
3848 (exit "$ac_status"); }; }; then
3849 ac_cv_func_strlcat=yes
3851 echo "$as_me: failed program was:" >&5
3852 cat "conftest.$ac_ext" >&5
3853 ac_cv_func_strlcat=no
3855 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
3857 echo "$as_me:3857: result: $ac_cv_func_strlcat" >&5
3858 echo "${ECHO_T}$ac_cv_func_strlcat" >&6
3859 if test "$ac_cv_func_strlcat" = yes; then
3861 cat >>confdefs.h <<\EOF
3862 #define HAVE_STRLCAT 1
3867 echo "$as_me:3867: checking for strlcat in -lbsd" >&5
3868 echo $ECHO_N "checking for strlcat in -lbsd... $ECHO_C" >&6
3869 if test "${ac_cv_lib_bsd_strlcat+set}" = set; then
3870 echo $ECHO_N "(cached) $ECHO_C" >&6
3872 ac_check_lib_save_LIBS=$LIBS
3874 cat >"conftest.$ac_ext" <<_ACEOF
3875 #line 3875 "configure"
3876 #include "confdefs.h"
3878 /* Override any gcc2 internal prototype to avoid an error. */
3882 /* We use char because int might match the return type of a gcc2
3883 builtin and then its argument prototype would still apply. */
3884 char strlcat (void);
3893 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
3894 if { (eval echo "$as_me:3894: \"$ac_link\"") >&5
3895 (eval $ac_link) 2>&5
3897 echo "$as_me:3897: \$? = $ac_status" >&5
3898 (exit "$ac_status"); } &&
3899 { ac_try='test -s "conftest$ac_exeext"'
3900 { (eval echo "$as_me:3900: \"$ac_try\"") >&5
3903 echo "$as_me:3903: \$? = $ac_status" >&5
3904 (exit "$ac_status"); }; }; then
3905 ac_cv_lib_bsd_strlcat=yes
3907 echo "$as_me: failed program was:" >&5
3908 cat "conftest.$ac_ext" >&5
3909 ac_cv_lib_bsd_strlcat=no
3911 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
3912 LIBS=$ac_check_lib_save_LIBS
3914 echo "$as_me:3914: result: $ac_cv_lib_bsd_strlcat" >&5
3915 echo "${ECHO_T}$ac_cv_lib_bsd_strlcat" >&6
3916 if test "$ac_cv_lib_bsd_strlcat" = yes; then
3921 for cf_add_1lib in -lbsd; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
3923 for cf_add_1lib in $cf_add_0lib; do
3924 for cf_add_2lib in $cf_add_libs; do
3925 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
3930 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
3934 for ac_header in bsd/string.h
3936 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
3937 echo "$as_me:3937: checking for $ac_header" >&5
3938 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3939 if eval "test \"\${$as_ac_Header+set}\" = set"; then
3940 echo $ECHO_N "(cached) $ECHO_C" >&6
3942 cat >"conftest.$ac_ext" <<_ACEOF
3943 #line 3943 "configure"
3944 #include "confdefs.h"
3945 #include <$ac_header>
3947 if { (eval echo "$as_me:3947: \"$ac_cpp "conftest.$ac_ext"\"") >&5
3948 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
3950 $EGREP -v '^ *\+' conftest.er1 >conftest.err
3952 cat conftest.err >&5
3953 echo "$as_me:3953: \$? = $ac_status" >&5
3954 (exit "$ac_status"); } >/dev/null; then
3955 if test -s conftest.err; then
3956 ac_cpp_err=$ac_c_preproc_warn_flag
3963 if test -z "$ac_cpp_err"; then
3964 eval "$as_ac_Header=yes"
3966 echo "$as_me: failed program was:" >&5
3967 cat "conftest.$ac_ext" >&5
3968 eval "$as_ac_Header=no"
3970 rm -f conftest.err "conftest.$ac_ext"
3972 echo "$as_me:3972: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
3973 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
3974 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
3975 cat >>confdefs.h <<EOF
3976 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
3982 cat >>confdefs.h <<\EOF
3983 #define HAVE_STRLCAT 1
3990 for ac_func in strlcpy snprintf
3992 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
3993 echo "$as_me:3993: checking for $ac_func" >&5
3994 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
3995 if eval "test \"\${$as_ac_var+set}\" = set"; then
3996 echo $ECHO_N "(cached) $ECHO_C" >&6
3998 cat >"conftest.$ac_ext" <<_ACEOF
3999 #line 3999 "configure"
4000 #include "confdefs.h"
4001 #define $ac_func autoconf_temporary
4002 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
4009 /* We use char because int might match the return type of a gcc2
4010 builtin and then its argument prototype would still apply. */
4011 char $ac_func (void);
4017 /* The GNU C library defines stubs for functions which it implements
4018 to always fail with ENOSYS. Some functions are actually named
4019 something starting with __ and the normal name is an alias. */
4020 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
4021 #error found stub for $ac_func
4029 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
4030 if { (eval echo "$as_me:4030: \"$ac_link\"") >&5
4031 (eval $ac_link) 2>&5
4033 echo "$as_me:4033: \$? = $ac_status" >&5
4034 (exit "$ac_status"); } &&
4035 { ac_try='test -s "conftest$ac_exeext"'
4036 { (eval echo "$as_me:4036: \"$ac_try\"") >&5
4039 echo "$as_me:4039: \$? = $ac_status" >&5
4040 (exit "$ac_status"); }; }; then
4041 eval "$as_ac_var=yes"
4043 echo "$as_me: failed program was:" >&5
4044 cat "conftest.$ac_ext" >&5
4045 eval "$as_ac_var=no"
4047 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
4049 echo "$as_me:4049: result: `eval echo '${'"$as_ac_var"'}'`" >&5
4050 echo "${ECHO_T}`eval echo '${'"$as_ac_var"'}'`" >&6
4051 if test "`eval echo '${'"$as_ac_var"'}'`" = yes; then
4052 cat >>confdefs.h <<EOF
4053 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
4061 echo "$as_me:4061: checking if the POSIX test-macros are already defined" >&5
4062 echo $ECHO_N "checking if the POSIX test-macros are already defined... $ECHO_C" >&6
4063 if test "${cf_cv_posix_visible+set}" = set; then
4064 echo $ECHO_N "(cached) $ECHO_C" >&6
4067 cat >"conftest.$ac_ext" <<_ACEOF
4068 #line 4068 "configure"
4069 #include "confdefs.h"
4075 #if defined(__POSIX_VISIBLE) && ((__POSIX_VISIBLE - 0L) > 0) \
4076 && defined(__XSI_VISIBLE) && ((__XSI_VISIBLE - 0L) > 0) \
4077 && defined(__BSD_VISIBLE) && ((__BSD_VISIBLE - 0L) > 0) \
4078 && defined(__ISO_C_VISIBLE) && ((__ISO_C_VISIBLE - 0L) > 0)
4079 #error conflicting symbols found
4086 rm -f "conftest.$ac_objext"
4087 if { (eval echo "$as_me:4087: \"$ac_compile\"") >&5
4088 (eval $ac_compile) 2>&5
4090 echo "$as_me:4090: \$? = $ac_status" >&5
4091 (exit "$ac_status"); } &&
4092 { ac_try='test -s "conftest.$ac_objext"'
4093 { (eval echo "$as_me:4093: \"$ac_try\"") >&5
4096 echo "$as_me:4096: \$? = $ac_status" >&5
4097 (exit "$ac_status"); }; }; then
4098 cf_cv_posix_visible=no
4100 echo "$as_me: failed program was:" >&5
4101 cat "conftest.$ac_ext" >&5
4102 cf_cv_posix_visible=yes
4104 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4107 echo "$as_me:4107: result: $cf_cv_posix_visible" >&5
4108 echo "${ECHO_T}$cf_cv_posix_visible" >&6
4110 if test "$cf_cv_posix_visible" = no; then
4113 cf_POSIX_C_SOURCE=199506L
4118 cf_xopen_source="-D_ALL_SOURCE"
4121 cf_xopen_source="-D_APPLE_C_SOURCE"
4124 cf_xopen_source="-D_DARWIN_C_SOURCE"
4127 (freebsd*|dragonfly*|midnightbsd*)
4128 # 5.x headers associate
4129 # _XOPEN_SOURCE=600 with _POSIX_C_SOURCE=200112L
4130 # _XOPEN_SOURCE=500 with _POSIX_C_SOURCE=199506L
4131 cf_POSIX_C_SOURCE=200112L
4133 cf_xopen_source="-D_BSD_TYPES -D__BSD_VISIBLE -D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
4136 cf_xopen_source="-D_HPUX_SOURCE -D_XOPEN_SOURCE=500"
4139 cf_xopen_source="-D_HPUX_SOURCE"
4142 cf_xopen_source="-D_SGI_SOURCE"
4145 (linux*gnu|linux*gnuabi64|linux*gnuabin32|linux*gnueabi|linux*gnueabihf|linux*gnux32|uclinux*|gnu*|mint*|k*bsd*-gnu|cygwin|msys|mingw*|linux*uclibc)
4147 cf_gnu_xopen_source=$cf_XOPEN_SOURCE
4149 echo "$as_me:4149: checking if this is the GNU C library" >&5
4150 echo $ECHO_N "checking if this is the GNU C library... $ECHO_C" >&6
4151 if test "${cf_cv_gnu_library+set}" = set; then
4152 echo $ECHO_N "(cached) $ECHO_C" >&6
4155 cat >"conftest.$ac_ext" <<_ACEOF
4156 #line 4156 "configure"
4157 #include "confdefs.h"
4158 #include <sys/types.h>
4163 #if __GLIBC__ > 0 && __GLIBC_MINOR__ >= 0
4165 #elif __NEWLIB__ > 0 && __NEWLIB_MINOR__ >= 0
4168 # error not GNU C library
4174 rm -f "conftest.$ac_objext"
4175 if { (eval echo "$as_me:4175: \"$ac_compile\"") >&5
4176 (eval $ac_compile) 2>&5
4178 echo "$as_me:4178: \$? = $ac_status" >&5
4179 (exit "$ac_status"); } &&
4180 { ac_try='test -s "conftest.$ac_objext"'
4181 { (eval echo "$as_me:4181: \"$ac_try\"") >&5
4184 echo "$as_me:4184: \$? = $ac_status" >&5
4185 (exit "$ac_status"); }; }; then
4186 cf_cv_gnu_library=yes
4188 echo "$as_me: failed program was:" >&5
4189 cat "conftest.$ac_ext" >&5
4190 cf_cv_gnu_library=no
4192 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4195 echo "$as_me:4195: result: $cf_cv_gnu_library" >&5
4196 echo "${ECHO_T}$cf_cv_gnu_library" >&6
4198 if test x$cf_cv_gnu_library = xyes; then
4200 # With glibc 2.19 (13 years after this check was begun), _DEFAULT_SOURCE
4201 # was changed to help a little. newlib incorporated the change about 4
4203 echo "$as_me:4203: checking if _DEFAULT_SOURCE can be used as a basis" >&5
4204 echo $ECHO_N "checking if _DEFAULT_SOURCE can be used as a basis... $ECHO_C" >&6
4205 if test "${cf_cv_gnu_library_219+set}" = set; then
4206 echo $ECHO_N "(cached) $ECHO_C" >&6
4211 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4212 CPPFLAGS="${CPPFLAGS}-D_DEFAULT_SOURCE"
4214 cat >"conftest.$ac_ext" <<_ACEOF
4215 #line 4215 "configure"
4216 #include "confdefs.h"
4217 #include <sys/types.h>
4222 #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 19) || (__GLIBC__ > 2)
4224 #elif (__NEWLIB__ == 2 && __NEWLIB_MINOR__ >= 4) || (__GLIBC__ > 3)
4227 # error GNU C library __GLIBC__.__GLIBC_MINOR__ is too old
4233 rm -f "conftest.$ac_objext"
4234 if { (eval echo "$as_me:4234: \"$ac_compile\"") >&5
4235 (eval $ac_compile) 2>&5
4237 echo "$as_me:4237: \$? = $ac_status" >&5
4238 (exit "$ac_status"); } &&
4239 { ac_try='test -s "conftest.$ac_objext"'
4240 { (eval echo "$as_me:4240: \"$ac_try\"") >&5
4243 echo "$as_me:4243: \$? = $ac_status" >&5
4244 (exit "$ac_status"); }; }; then
4245 cf_cv_gnu_library_219=yes
4247 echo "$as_me: failed program was:" >&5
4248 cat "conftest.$ac_ext" >&5
4249 cf_cv_gnu_library_219=no
4251 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4255 echo "$as_me:4255: result: $cf_cv_gnu_library_219" >&5
4256 echo "${ECHO_T}$cf_cv_gnu_library_219" >&6
4258 if test "x$cf_cv_gnu_library_219" = xyes; then
4260 echo "$as_me:4260: checking if _XOPEN_SOURCE=$cf_gnu_xopen_source works with _DEFAULT_SOURCE" >&5
4261 echo $ECHO_N "checking if _XOPEN_SOURCE=$cf_gnu_xopen_source works with _DEFAULT_SOURCE... $ECHO_C" >&6
4262 if test "${cf_cv_gnu_dftsrc_219+set}" = set; then
4263 echo $ECHO_N "(cached) $ECHO_C" >&6
4269 cf_new_extra_cppflags=
4271 for cf_add_cflags in -D_DEFAULT_SOURCE -D_XOPEN_SOURCE=$cf_gnu_xopen_source
4273 case "$cf_fix_cppflags" in
4275 case "$cf_add_cflags" in
4276 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4277 case "$cf_add_cflags" in
4279 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4281 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4282 && test -z "${cf_tst_cflags}" \
4283 && cf_fix_cppflags=yes
4285 if test "$cf_fix_cppflags" = yes ; then
4287 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4288 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4291 elif test "${cf_tst_cflags}" = "\"'" ; then
4293 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4294 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4304 case "$cf_add_cflags" in
4306 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4308 CPPFLAGS=`echo "$CPPFLAGS" | \
4309 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4310 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4315 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4316 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4323 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4324 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4331 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4332 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4334 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
4336 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4337 && test -z "${cf_tst_cflags}" \
4338 && cf_fix_cppflags=no
4343 if test -n "$cf_new_cflags" ; then
4345 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4346 CFLAGS="${CFLAGS}$cf_new_cflags"
4350 if test -n "$cf_new_cppflags" ; then
4352 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4353 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4357 if test -n "$cf_new_extra_cppflags" ; then
4359 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4360 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4364 cat >"conftest.$ac_ext" <<_ACEOF
4365 #line 4365 "configure"
4366 #include "confdefs.h"
4369 #include <sys/types.h>
4375 #if (_XOPEN_SOURCE >= $cf_gnu_xopen_source) && (MB_LEN_MAX > 1)
4378 # error GNU C library is too old
4384 rm -f "conftest.$ac_objext"
4385 if { (eval echo "$as_me:4385: \"$ac_compile\"") >&5
4386 (eval $ac_compile) 2>&5
4388 echo "$as_me:4388: \$? = $ac_status" >&5
4389 (exit "$ac_status"); } &&
4390 { ac_try='test -s "conftest.$ac_objext"'
4391 { (eval echo "$as_me:4391: \"$ac_try\"") >&5
4394 echo "$as_me:4394: \$? = $ac_status" >&5
4395 (exit "$ac_status"); }; }; then
4396 cf_cv_gnu_dftsrc_219=yes
4398 echo "$as_me: failed program was:" >&5
4399 cat "conftest.$ac_ext" >&5
4400 cf_cv_gnu_dftsrc_219=no
4402 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4405 echo "$as_me:4405: result: $cf_cv_gnu_dftsrc_219" >&5
4406 echo "${ECHO_T}$cf_cv_gnu_dftsrc_219" >&6
4407 test "x$cf_cv_gnu_dftsrc_219" = "xyes" || CPPFLAGS="$cf_save"
4409 cf_cv_gnu_dftsrc_219=maybe
4412 if test "x$cf_cv_gnu_dftsrc_219" != xyes; then
4414 echo "$as_me:4414: checking if we must define _GNU_SOURCE" >&5
4415 echo $ECHO_N "checking if we must define _GNU_SOURCE... $ECHO_C" >&6
4416 if test "${cf_cv_gnu_source+set}" = set; then
4417 echo $ECHO_N "(cached) $ECHO_C" >&6
4420 cat >"conftest.$ac_ext" <<_ACEOF
4421 #line 4421 "configure"
4422 #include "confdefs.h"
4423 #include <sys/types.h>
4428 #ifndef _XOPEN_SOURCE
4429 #error expected _XOPEN_SOURCE to be defined
4435 rm -f "conftest.$ac_objext"
4436 if { (eval echo "$as_me:4436: \"$ac_compile\"") >&5
4437 (eval $ac_compile) 2>&5
4439 echo "$as_me:4439: \$? = $ac_status" >&5
4440 (exit "$ac_status"); } &&
4441 { ac_try='test -s "conftest.$ac_objext"'
4442 { (eval echo "$as_me:4442: \"$ac_try\"") >&5
4445 echo "$as_me:4445: \$? = $ac_status" >&5
4446 (exit "$ac_status"); }; }; then
4449 echo "$as_me: failed program was:" >&5
4450 cat "conftest.$ac_ext" >&5
4456 cf_new_extra_cppflags=
4458 for cf_add_cflags in -D_GNU_SOURCE
4460 case "$cf_fix_cppflags" in
4462 case "$cf_add_cflags" in
4463 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4464 case "$cf_add_cflags" in
4466 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4468 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4469 && test -z "${cf_tst_cflags}" \
4470 && cf_fix_cppflags=yes
4472 if test "$cf_fix_cppflags" = yes ; then
4474 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4475 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4478 elif test "${cf_tst_cflags}" = "\"'" ; then
4480 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4481 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4491 case "$cf_add_cflags" in
4493 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4495 CPPFLAGS=`echo "$CPPFLAGS" | \
4496 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4497 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4502 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4503 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4510 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4511 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4518 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4519 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4521 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
4523 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4524 && test -z "${cf_tst_cflags}" \
4525 && cf_fix_cppflags=no
4530 if test -n "$cf_new_cflags" ; then
4532 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4533 CFLAGS="${CFLAGS}$cf_new_cflags"
4537 if test -n "$cf_new_cppflags" ; then
4539 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4540 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4544 if test -n "$cf_new_extra_cppflags" ; then
4546 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4547 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4551 cat >"conftest.$ac_ext" <<_ACEOF
4552 #line 4552 "configure"
4553 #include "confdefs.h"
4554 #include <sys/types.h>
4559 #ifdef _XOPEN_SOURCE
4560 #error expected _XOPEN_SOURCE to be undefined
4566 rm -f "conftest.$ac_objext"
4567 if { (eval echo "$as_me:4567: \"$ac_compile\"") >&5
4568 (eval $ac_compile) 2>&5
4570 echo "$as_me:4570: \$? = $ac_status" >&5
4571 (exit "$ac_status"); } &&
4572 { ac_try='test -s "conftest.$ac_objext"'
4573 { (eval echo "$as_me:4573: \"$ac_try\"") >&5
4576 echo "$as_me:4576: \$? = $ac_status" >&5
4577 (exit "$ac_status"); }; }; then
4580 echo "$as_me: failed program was:" >&5
4581 cat "conftest.$ac_ext" >&5
4582 cf_cv_gnu_source=yes
4584 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4588 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4591 echo "$as_me:4591: result: $cf_cv_gnu_source" >&5
4592 echo "${ECHO_T}$cf_cv_gnu_source" >&6
4594 if test "$cf_cv_gnu_source" = yes
4596 echo "$as_me:4596: checking if we should also define _DEFAULT_SOURCE" >&5
4597 echo $ECHO_N "checking if we should also define _DEFAULT_SOURCE... $ECHO_C" >&6
4598 if test "${cf_cv_default_source+set}" = set; then
4599 echo $ECHO_N "(cached) $ECHO_C" >&6
4602 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4603 CPPFLAGS="${CPPFLAGS}-D_GNU_SOURCE"
4605 cat >"conftest.$ac_ext" <<_ACEOF
4606 #line 4606 "configure"
4607 #include "confdefs.h"
4608 #include <sys/types.h>
4613 #ifdef _DEFAULT_SOURCE
4614 #error expected _DEFAULT_SOURCE to be undefined
4620 rm -f "conftest.$ac_objext"
4621 if { (eval echo "$as_me:4621: \"$ac_compile\"") >&5
4622 (eval $ac_compile) 2>&5
4624 echo "$as_me:4624: \$? = $ac_status" >&5
4625 (exit "$ac_status"); } &&
4626 { ac_try='test -s "conftest.$ac_objext"'
4627 { (eval echo "$as_me:4627: \"$ac_try\"") >&5
4630 echo "$as_me:4630: \$? = $ac_status" >&5
4631 (exit "$ac_status"); }; }; then
4632 cf_cv_default_source=no
4634 echo "$as_me: failed program was:" >&5
4635 cat "conftest.$ac_ext" >&5
4636 cf_cv_default_source=yes
4638 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4641 echo "$as_me:4641: result: $cf_cv_default_source" >&5
4642 echo "${ECHO_T}$cf_cv_default_source" >&6
4643 if test "$cf_cv_default_source" = yes
4646 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4647 CPPFLAGS="${CPPFLAGS}-D_DEFAULT_SOURCE"
4657 cf_xopen_source="-D_NETBSD_SOURCE" # POSIX.1-2001 features are ifdef'd with this...
4660 # setting _XOPEN_SOURCE or _POSIX_SOURCE breaks <sys/select.h> and other headers which use u_int / u_short types
4663 if test "$cf_cv_posix_visible" = no; then
4665 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
4667 cf_save_CFLAGS="$CFLAGS"
4668 cf_save_CPPFLAGS="$CPPFLAGS"
4670 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
4671 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
4672 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
4674 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
4675 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
4676 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
4678 echo "$as_me:4678: checking if we should define _POSIX_C_SOURCE" >&5
4679 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
4680 if test "${cf_cv_posix_c_source+set}" = set; then
4681 echo $ECHO_N "(cached) $ECHO_C" >&6
4684 echo "${as_me:-configure}:4684: testing if the symbol is already defined go no further ..." 1>&5
4686 cat >"conftest.$ac_ext" <<_ACEOF
4687 #line 4687 "configure"
4688 #include "confdefs.h"
4689 #include <sys/types.h>
4694 #ifndef _POSIX_C_SOURCE
4695 #error _POSIX_C_SOURCE is not defined
4701 rm -f "conftest.$ac_objext"
4702 if { (eval echo "$as_me:4702: \"$ac_compile\"") >&5
4703 (eval $ac_compile) 2>&5
4705 echo "$as_me:4705: \$? = $ac_status" >&5
4706 (exit "$ac_status"); } &&
4707 { ac_try='test -s "conftest.$ac_objext"'
4708 { (eval echo "$as_me:4708: \"$ac_try\"") >&5
4711 echo "$as_me:4711: \$? = $ac_status" >&5
4712 (exit "$ac_status"); }; }; then
4713 cf_cv_posix_c_source=no
4715 echo "$as_me: failed program was:" >&5
4716 cat "conftest.$ac_ext" >&5
4717 cf_want_posix_source=no
4718 case .$cf_POSIX_C_SOURCE in
4720 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
4723 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
4724 cf_want_posix_source=yes
4727 cf_want_posix_source=yes
4730 if test "$cf_want_posix_source" = yes ; then
4731 cat >"conftest.$ac_ext" <<_ACEOF
4732 #line 4732 "configure"
4733 #include "confdefs.h"
4734 #include <sys/types.h>
4739 #ifdef _POSIX_SOURCE
4740 #error _POSIX_SOURCE is defined
4746 rm -f "conftest.$ac_objext"
4747 if { (eval echo "$as_me:4747: \"$ac_compile\"") >&5
4748 (eval $ac_compile) 2>&5
4750 echo "$as_me:4750: \$? = $ac_status" >&5
4751 (exit "$ac_status"); } &&
4752 { ac_try='test -s "conftest.$ac_objext"'
4753 { (eval echo "$as_me:4753: \"$ac_try\"") >&5
4756 echo "$as_me:4756: \$? = $ac_status" >&5
4757 (exit "$ac_status"); }; }; then
4760 echo "$as_me: failed program was:" >&5
4761 cat "conftest.$ac_ext" >&5
4762 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
4764 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4767 echo "${as_me:-configure}:4767: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
4769 CFLAGS="$cf_trim_CFLAGS"
4770 CPPFLAGS="$cf_trim_CPPFLAGS"
4772 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4773 CPPFLAGS="${CPPFLAGS}$cf_cv_posix_c_source"
4775 echo "${as_me:-configure}:4775: testing if the second compile does not leave our definition intact error ..." 1>&5
4777 cat >"conftest.$ac_ext" <<_ACEOF
4778 #line 4778 "configure"
4779 #include "confdefs.h"
4780 #include <sys/types.h>
4785 #ifndef _POSIX_C_SOURCE
4786 #error _POSIX_C_SOURCE is not defined
4792 rm -f "conftest.$ac_objext"
4793 if { (eval echo "$as_me:4793: \"$ac_compile\"") >&5
4794 (eval $ac_compile) 2>&5
4796 echo "$as_me:4796: \$? = $ac_status" >&5
4797 (exit "$ac_status"); } &&
4798 { ac_try='test -s "conftest.$ac_objext"'
4799 { (eval echo "$as_me:4799: \"$ac_try\"") >&5
4802 echo "$as_me:4802: \$? = $ac_status" >&5
4803 (exit "$ac_status"); }; }; then
4806 echo "$as_me: failed program was:" >&5
4807 cat "conftest.$ac_ext" >&5
4808 cf_cv_posix_c_source=no
4810 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4811 CFLAGS="$cf_save_CFLAGS"
4812 CPPFLAGS="$cf_save_CPPFLAGS"
4815 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4818 echo "$as_me:4818: result: $cf_cv_posix_c_source" >&5
4819 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
4821 if test "$cf_cv_posix_c_source" != no ; then
4822 CFLAGS="$cf_trim_CFLAGS"
4823 CPPFLAGS="$cf_trim_CPPFLAGS"
4828 cf_new_extra_cppflags=
4830 for cf_add_cflags in $cf_cv_posix_c_source
4832 case "$cf_fix_cppflags" in
4834 case "$cf_add_cflags" in
4835 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4836 case "$cf_add_cflags" in
4838 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4840 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4841 && test -z "${cf_tst_cflags}" \
4842 && cf_fix_cppflags=yes
4844 if test "$cf_fix_cppflags" = yes ; then
4846 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4847 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4850 elif test "${cf_tst_cflags}" = "\"'" ; then
4852 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4853 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4863 case "$cf_add_cflags" in
4865 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4867 CPPFLAGS=`echo "$CPPFLAGS" | \
4868 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4869 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4874 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4875 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4882 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4883 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4890 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4891 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4893 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
4895 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4896 && test -z "${cf_tst_cflags}" \
4897 && cf_fix_cppflags=no
4902 if test -n "$cf_new_cflags" ; then
4904 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4905 CFLAGS="${CFLAGS}$cf_new_cflags"
4909 if test -n "$cf_new_cppflags" ; then
4911 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4912 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4916 if test -n "$cf_new_extra_cppflags" ; then
4918 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4919 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4925 fi # cf_cv_posix_visible
4929 cf_xopen_source="-D_NETBSD_SOURCE" # setting _XOPEN_SOURCE breaks IPv6 for lynx on NetBSD 1.6, breaks xterm, is not needed for ncursesw
4932 # OpenBSD 6.x has broken locale support, both compile-time and runtime.
4933 # see https://www.mail-archive.com/bugs@openbsd.org/msg13200.html
4934 # Abusing the conformance level is a workaround.
4935 { echo "$as_me:4935: WARNING: this system does not provide usable locale support" >&5
4936 echo "$as_me: WARNING: this system does not provide usable locale support" >&2;}
4937 cf_xopen_source="-D_BSD_SOURCE"
4941 # setting _XOPEN_SOURCE lower than 500 breaks g++ compile with wchar.h, needed for ncursesw
4942 cf_xopen_source="-D_BSD_SOURCE"
4946 # setting _XOPEN_SOURCE breaks xterm on OpenBSD 2.8, is not needed for ncursesw
4949 cf_xopen_source="-D_OSF_SOURCE"
4952 cf_xopen_source="-D_QNX_SOURCE"
4955 # setting _XOPEN_SOURCE breaks Lynx on SCO Unix / OpenServer
4958 cf_xopen_source="-D__EXTENSIONS__"
4959 cf_cv_xopen_source=broken
4961 (sysv4.2uw2.*) # Novell/SCO UnixWare 2.x (tested on 2.1.2)
4967 echo "$as_me:4967: checking if we should define _XOPEN_SOURCE" >&5
4968 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
4969 if test "${cf_cv_xopen_source+set}" = set; then
4970 echo $ECHO_N "(cached) $ECHO_C" >&6
4973 cat >"conftest.$ac_ext" <<_ACEOF
4974 #line 4974 "configure"
4975 #include "confdefs.h"
4977 $ac_includes_default
4983 #ifndef _XOPEN_SOURCE
4984 #error _XOPEN_SOURCE is not defined
4991 rm -f "conftest.$ac_objext"
4992 if { (eval echo "$as_me:4992: \"$ac_compile\"") >&5
4993 (eval $ac_compile) 2>&5
4995 echo "$as_me:4995: \$? = $ac_status" >&5
4996 (exit "$ac_status"); } &&
4997 { ac_try='test -s "conftest.$ac_objext"'
4998 { (eval echo "$as_me:4998: \"$ac_try\"") >&5
5001 echo "$as_me:5001: \$? = $ac_status" >&5
5002 (exit "$ac_status"); }; }; then
5003 cf_cv_xopen_source=no
5005 echo "$as_me: failed program was:" >&5
5006 cat "conftest.$ac_ext" >&5
5009 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5010 CPPFLAGS="${CPPFLAGS}-D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
5012 cat >"conftest.$ac_ext" <<_ACEOF
5013 #line 5013 "configure"
5014 #include "confdefs.h"
5016 $ac_includes_default
5022 #ifndef _XOPEN_SOURCE
5023 #error _XOPEN_SOURCE is not defined
5030 rm -f "conftest.$ac_objext"
5031 if { (eval echo "$as_me:5031: \"$ac_compile\"") >&5
5032 (eval $ac_compile) 2>&5
5034 echo "$as_me:5034: \$? = $ac_status" >&5
5035 (exit "$ac_status"); } &&
5036 { ac_try='test -s "conftest.$ac_objext"'
5037 { (eval echo "$as_me:5037: \"$ac_try\"") >&5
5040 echo "$as_me:5040: \$? = $ac_status" >&5
5041 (exit "$ac_status"); }; }; then
5042 cf_cv_xopen_source=no
5044 echo "$as_me: failed program was:" >&5
5045 cat "conftest.$ac_ext" >&5
5046 cf_cv_xopen_source=$cf_XOPEN_SOURCE
5048 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5052 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5055 echo "$as_me:5055: result: $cf_cv_xopen_source" >&5
5056 echo "${ECHO_T}$cf_cv_xopen_source" >&6
5058 if test "$cf_cv_xopen_source" != no ; then
5060 CFLAGS=`echo "$CFLAGS" | \
5061 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
5062 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
5064 CPPFLAGS=`echo "$CPPFLAGS" | \
5065 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
5066 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
5068 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
5070 for cf_add_cflags in $cf_temp_xopen_source
5072 case "x$cf_add_cflags" in
5075 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
5078 cf_old_cflag=`echo "x$CFLAGS" | sed -e 's/^.//' -e 's/[ ][ ]*-/ -/g' -e "s%$cf_tmp_cflag\\(=[^ ][^ ]*\\)\?%%" -e 's/^[ ]*//' -e 's%[ ][ ]*-D% -D%g' -e 's%[ ][ ]*-I% -I%g'`
5079 test "$CFLAGS" != "$cf_old_cflag" || break
5081 CFLAGS="$cf_old_cflag"
5084 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
5087 cf_old_cflag=`echo "x$CPPFLAGS" | sed -e 's/^.//' -e 's/[ ][ ]*-/ -/g' -e "s%$cf_tmp_cflag\\(=[^ ][^ ]*\\)\?%%" -e 's/^[ ]*//' -e 's%[ ][ ]*-D% -D%g' -e 's%[ ][ ]*-I% -I%g'`
5088 test "$CPPFLAGS" != "$cf_old_cflag" || break
5090 CPPFLAGS="$cf_old_cflag"
5099 cf_new_extra_cppflags=
5101 for cf_add_cflags in $cf_add_cflags
5103 case "$cf_fix_cppflags" in
5105 case "$cf_add_cflags" in
5106 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
5107 case "$cf_add_cflags" in
5109 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
5111 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
5112 && test -z "${cf_tst_cflags}" \
5113 && cf_fix_cppflags=yes
5115 if test "$cf_fix_cppflags" = yes ; then
5117 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5118 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5121 elif test "${cf_tst_cflags}" = "\"'" ; then
5123 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5124 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5134 case "$cf_add_cflags" in
5136 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
5138 CPPFLAGS=`echo "$CPPFLAGS" | \
5139 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
5140 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
5145 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
5146 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
5153 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
5154 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
5161 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5162 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5164 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
5166 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
5167 && test -z "${cf_tst_cflags}" \
5168 && cf_fix_cppflags=no
5173 if test -n "$cf_new_cflags" ; then
5175 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
5176 CFLAGS="${CFLAGS}$cf_new_cflags"
5180 if test -n "$cf_new_cppflags" ; then
5182 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5183 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
5187 if test -n "$cf_new_extra_cppflags" ; then
5189 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
5190 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
5198 cf_save_xopen_cppflags="$CPPFLAGS"
5200 if test "$cf_cv_posix_visible" = no; then
5202 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
5204 cf_save_CFLAGS="$CFLAGS"
5205 cf_save_CPPFLAGS="$CPPFLAGS"
5207 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
5208 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
5209 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
5211 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
5212 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
5213 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
5215 echo "$as_me:5215: checking if we should define _POSIX_C_SOURCE" >&5
5216 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
5217 if test "${cf_cv_posix_c_source+set}" = set; then
5218 echo $ECHO_N "(cached) $ECHO_C" >&6
5221 echo "${as_me:-configure}:5221: testing if the symbol is already defined go no further ..." 1>&5
5223 cat >"conftest.$ac_ext" <<_ACEOF
5224 #line 5224 "configure"
5225 #include "confdefs.h"
5226 #include <sys/types.h>
5231 #ifndef _POSIX_C_SOURCE
5232 #error _POSIX_C_SOURCE is not defined
5238 rm -f "conftest.$ac_objext"
5239 if { (eval echo "$as_me:5239: \"$ac_compile\"") >&5
5240 (eval $ac_compile) 2>&5
5242 echo "$as_me:5242: \$? = $ac_status" >&5
5243 (exit "$ac_status"); } &&
5244 { ac_try='test -s "conftest.$ac_objext"'
5245 { (eval echo "$as_me:5245: \"$ac_try\"") >&5
5248 echo "$as_me:5248: \$? = $ac_status" >&5
5249 (exit "$ac_status"); }; }; then
5250 cf_cv_posix_c_source=no
5252 echo "$as_me: failed program was:" >&5
5253 cat "conftest.$ac_ext" >&5
5254 cf_want_posix_source=no
5255 case .$cf_POSIX_C_SOURCE in
5257 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
5260 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
5261 cf_want_posix_source=yes
5264 cf_want_posix_source=yes
5267 if test "$cf_want_posix_source" = yes ; then
5268 cat >"conftest.$ac_ext" <<_ACEOF
5269 #line 5269 "configure"
5270 #include "confdefs.h"
5271 #include <sys/types.h>
5276 #ifdef _POSIX_SOURCE
5277 #error _POSIX_SOURCE is defined
5283 rm -f "conftest.$ac_objext"
5284 if { (eval echo "$as_me:5284: \"$ac_compile\"") >&5
5285 (eval $ac_compile) 2>&5
5287 echo "$as_me:5287: \$? = $ac_status" >&5
5288 (exit "$ac_status"); } &&
5289 { ac_try='test -s "conftest.$ac_objext"'
5290 { (eval echo "$as_me:5290: \"$ac_try\"") >&5
5293 echo "$as_me:5293: \$? = $ac_status" >&5
5294 (exit "$ac_status"); }; }; then
5297 echo "$as_me: failed program was:" >&5
5298 cat "conftest.$ac_ext" >&5
5299 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
5301 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5304 echo "${as_me:-configure}:5304: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
5306 CFLAGS="$cf_trim_CFLAGS"
5307 CPPFLAGS="$cf_trim_CPPFLAGS"
5309 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5310 CPPFLAGS="${CPPFLAGS}$cf_cv_posix_c_source"
5312 echo "${as_me:-configure}:5312: testing if the second compile does not leave our definition intact error ..." 1>&5
5314 cat >"conftest.$ac_ext" <<_ACEOF
5315 #line 5315 "configure"
5316 #include "confdefs.h"
5317 #include <sys/types.h>
5322 #ifndef _POSIX_C_SOURCE
5323 #error _POSIX_C_SOURCE is not defined
5329 rm -f "conftest.$ac_objext"
5330 if { (eval echo "$as_me:5330: \"$ac_compile\"") >&5
5331 (eval $ac_compile) 2>&5
5333 echo "$as_me:5333: \$? = $ac_status" >&5
5334 (exit "$ac_status"); } &&
5335 { ac_try='test -s "conftest.$ac_objext"'
5336 { (eval echo "$as_me:5336: \"$ac_try\"") >&5
5339 echo "$as_me:5339: \$? = $ac_status" >&5
5340 (exit "$ac_status"); }; }; then
5343 echo "$as_me: failed program was:" >&5
5344 cat "conftest.$ac_ext" >&5
5345 cf_cv_posix_c_source=no
5347 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5348 CFLAGS="$cf_save_CFLAGS"
5349 CPPFLAGS="$cf_save_CPPFLAGS"
5352 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5355 echo "$as_me:5355: result: $cf_cv_posix_c_source" >&5
5356 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
5358 if test "$cf_cv_posix_c_source" != no ; then
5359 CFLAGS="$cf_trim_CFLAGS"
5360 CPPFLAGS="$cf_trim_CPPFLAGS"
5365 cf_new_extra_cppflags=
5367 for cf_add_cflags in $cf_cv_posix_c_source
5369 case "$cf_fix_cppflags" in
5371 case "$cf_add_cflags" in
5372 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
5373 case "$cf_add_cflags" in
5375 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
5377 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
5378 && test -z "${cf_tst_cflags}" \
5379 && cf_fix_cppflags=yes
5381 if test "$cf_fix_cppflags" = yes ; then
5383 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5384 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5387 elif test "${cf_tst_cflags}" = "\"'" ; then
5389 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5390 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5400 case "$cf_add_cflags" in
5402 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
5404 CPPFLAGS=`echo "$CPPFLAGS" | \
5405 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
5406 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
5411 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
5412 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
5419 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
5420 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
5427 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5428 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5430 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
5432 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
5433 && test -z "${cf_tst_cflags}" \
5434 && cf_fix_cppflags=no
5439 if test -n "$cf_new_cflags" ; then
5441 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
5442 CFLAGS="${CFLAGS}$cf_new_cflags"
5446 if test -n "$cf_new_cppflags" ; then
5448 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5449 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
5453 if test -n "$cf_new_extra_cppflags" ; then
5455 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
5456 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
5462 fi # cf_cv_posix_visible
5464 # Some of these niche implementations use copy/paste, double-check...
5465 if test "$cf_cv_xopen_source" = no ; then
5466 test -n "$verbose" && echo " checking if _POSIX_C_SOURCE interferes with _XOPEN_SOURCE" 1>&6
5468 echo "${as_me:-configure}:5468: testing checking if _POSIX_C_SOURCE interferes with _XOPEN_SOURCE ..." 1>&5
5470 cat >"conftest.$ac_ext" <<_ACEOF
5471 #line 5471 "configure"
5472 #include "confdefs.h"
5474 $ac_includes_default
5480 #ifndef _XOPEN_SOURCE
5481 #error _XOPEN_SOURCE is not defined
5488 rm -f "conftest.$ac_objext"
5489 if { (eval echo "$as_me:5489: \"$ac_compile\"") >&5
5490 (eval $ac_compile) 2>&5
5492 echo "$as_me:5492: \$? = $ac_status" >&5
5493 (exit "$ac_status"); } &&
5494 { ac_try='test -s "conftest.$ac_objext"'
5495 { (eval echo "$as_me:5495: \"$ac_try\"") >&5
5498 echo "$as_me:5498: \$? = $ac_status" >&5
5499 (exit "$ac_status"); }; }; then
5502 echo "$as_me: failed program was:" >&5
5503 cat "conftest.$ac_ext" >&5
5505 { echo "$as_me:5505: WARNING: _POSIX_C_SOURCE definition is not usable" >&5
5506 echo "$as_me: WARNING: _POSIX_C_SOURCE definition is not usable" >&2;}
5507 CPPFLAGS="$cf_save_xopen_cppflags"
5509 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5514 if test -n "$cf_xopen_source" ; then
5516 for cf_add_cflags in $cf_xopen_source
5518 case "x$cf_add_cflags" in
5521 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
5524 cf_old_cflag=`echo "x$CFLAGS" | sed -e 's/^.//' -e 's/[ ][ ]*-/ -/g' -e "s%$cf_tmp_cflag\\(=[^ ][^ ]*\\)\?%%" -e 's/^[ ]*//' -e 's%[ ][ ]*-D% -D%g' -e 's%[ ][ ]*-I% -I%g'`
5525 test "$CFLAGS" != "$cf_old_cflag" || break
5526 test -n "$verbose" && echo " removing old option $cf_add_cflags from CFLAGS" 1>&6
5528 echo "${as_me:-configure}:5528: testing removing old option $cf_add_cflags from CFLAGS ..." 1>&5
5530 CFLAGS="$cf_old_cflag"
5533 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
5536 cf_old_cflag=`echo "x$CPPFLAGS" | sed -e 's/^.//' -e 's/[ ][ ]*-/ -/g' -e "s%$cf_tmp_cflag\\(=[^ ][^ ]*\\)\?%%" -e 's/^[ ]*//' -e 's%[ ][ ]*-D% -D%g' -e 's%[ ][ ]*-I% -I%g'`
5537 test "$CPPFLAGS" != "$cf_old_cflag" || break
5538 test -n "$verbose" && echo " removing old option $cf_add_cflags from CPPFLAGS" 1>&6
5540 echo "${as_me:-configure}:5540: testing removing old option $cf_add_cflags from CPPFLAGS ..." 1>&5
5542 CPPFLAGS="$cf_old_cflag"
5551 cf_new_extra_cppflags=
5553 for cf_add_cflags in $cf_add_cflags
5555 case "$cf_fix_cppflags" in
5557 case "$cf_add_cflags" in
5558 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
5559 case "$cf_add_cflags" in
5561 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
5563 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
5564 && test -z "${cf_tst_cflags}" \
5565 && cf_fix_cppflags=yes
5567 if test "$cf_fix_cppflags" = yes ; then
5569 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5570 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5573 elif test "${cf_tst_cflags}" = "\"'" ; then
5575 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5576 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5586 case "$cf_add_cflags" in
5588 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
5590 CPPFLAGS=`echo "$CPPFLAGS" | \
5591 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
5592 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
5597 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
5598 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
5605 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
5606 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
5613 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5614 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5616 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
5618 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
5619 && test -z "${cf_tst_cflags}" \
5620 && cf_fix_cppflags=no
5625 if test -n "$cf_new_cflags" ; then
5626 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
5628 echo "${as_me:-configure}:5628: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
5630 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
5631 CFLAGS="${CFLAGS}$cf_new_cflags"
5635 if test -n "$cf_new_cppflags" ; then
5636 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
5638 echo "${as_me:-configure}:5638: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
5640 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5641 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
5645 if test -n "$cf_new_extra_cppflags" ; then
5646 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
5648 echo "${as_me:-configure}:5648: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
5650 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
5651 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
5659 if test -n "$cf_XOPEN_SOURCE" && test -z "$cf_cv_xopen_source" ; then
5660 echo "$as_me:5660: checking if _XOPEN_SOURCE really is set" >&5
5661 echo $ECHO_N "checking if _XOPEN_SOURCE really is set... $ECHO_C" >&6
5662 cat >"conftest.$ac_ext" <<_ACEOF
5663 #line 5663 "configure"
5664 #include "confdefs.h"
5670 #ifndef _XOPEN_SOURCE
5671 #error _XOPEN_SOURCE is not defined
5677 rm -f "conftest.$ac_objext"
5678 if { (eval echo "$as_me:5678: \"$ac_compile\"") >&5
5679 (eval $ac_compile) 2>&5
5681 echo "$as_me:5681: \$? = $ac_status" >&5
5682 (exit "$ac_status"); } &&
5683 { ac_try='test -s "conftest.$ac_objext"'
5684 { (eval echo "$as_me:5684: \"$ac_try\"") >&5
5687 echo "$as_me:5687: \$? = $ac_status" >&5
5688 (exit "$ac_status"); }; }; then
5689 cf_XOPEN_SOURCE_set=yes
5691 echo "$as_me: failed program was:" >&5
5692 cat "conftest.$ac_ext" >&5
5693 cf_XOPEN_SOURCE_set=no
5695 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5696 echo "$as_me:5696: result: $cf_XOPEN_SOURCE_set" >&5
5697 echo "${ECHO_T}$cf_XOPEN_SOURCE_set" >&6
5698 if test "$cf_XOPEN_SOURCE_set" = yes
5700 cat >"conftest.$ac_ext" <<_ACEOF
5701 #line 5701 "configure"
5702 #include "confdefs.h"
5708 #if (_XOPEN_SOURCE - 0) < $cf_XOPEN_SOURCE
5709 #error (_XOPEN_SOURCE - 0) < $cf_XOPEN_SOURCE
5715 rm -f "conftest.$ac_objext"
5716 if { (eval echo "$as_me:5716: \"$ac_compile\"") >&5
5717 (eval $ac_compile) 2>&5
5719 echo "$as_me:5719: \$? = $ac_status" >&5
5720 (exit "$ac_status"); } &&
5721 { ac_try='test -s "conftest.$ac_objext"'
5722 { (eval echo "$as_me:5722: \"$ac_try\"") >&5
5725 echo "$as_me:5725: \$? = $ac_status" >&5
5726 (exit "$ac_status"); }; }; then
5727 cf_XOPEN_SOURCE_set_ok=yes
5729 echo "$as_me: failed program was:" >&5
5730 cat "conftest.$ac_ext" >&5
5731 cf_XOPEN_SOURCE_set_ok=no
5733 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5734 if test "$cf_XOPEN_SOURCE_set_ok" = no
5736 { echo "$as_me:5736: WARNING: _XOPEN_SOURCE is lower than requested" >&5
5737 echo "$as_me: WARNING: _XOPEN_SOURCE is lower than requested" >&2;}
5741 echo "$as_me:5741: checking if we should define _XOPEN_SOURCE" >&5
5742 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
5743 if test "${cf_cv_xopen_source+set}" = set; then
5744 echo $ECHO_N "(cached) $ECHO_C" >&6
5747 cat >"conftest.$ac_ext" <<_ACEOF
5748 #line 5748 "configure"
5749 #include "confdefs.h"
5751 $ac_includes_default
5757 #ifndef _XOPEN_SOURCE
5758 #error _XOPEN_SOURCE is not defined
5765 rm -f "conftest.$ac_objext"
5766 if { (eval echo "$as_me:5766: \"$ac_compile\"") >&5
5767 (eval $ac_compile) 2>&5
5769 echo "$as_me:5769: \$? = $ac_status" >&5
5770 (exit "$ac_status"); } &&
5771 { ac_try='test -s "conftest.$ac_objext"'
5772 { (eval echo "$as_me:5772: \"$ac_try\"") >&5
5775 echo "$as_me:5775: \$? = $ac_status" >&5
5776 (exit "$ac_status"); }; }; then
5777 cf_cv_xopen_source=no
5779 echo "$as_me: failed program was:" >&5
5780 cat "conftest.$ac_ext" >&5
5783 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5784 CPPFLAGS="${CPPFLAGS}-D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
5786 cat >"conftest.$ac_ext" <<_ACEOF
5787 #line 5787 "configure"
5788 #include "confdefs.h"
5790 $ac_includes_default
5796 #ifndef _XOPEN_SOURCE
5797 #error _XOPEN_SOURCE is not defined
5804 rm -f "conftest.$ac_objext"
5805 if { (eval echo "$as_me:5805: \"$ac_compile\"") >&5
5806 (eval $ac_compile) 2>&5
5808 echo "$as_me:5808: \$? = $ac_status" >&5
5809 (exit "$ac_status"); } &&
5810 { ac_try='test -s "conftest.$ac_objext"'
5811 { (eval echo "$as_me:5811: \"$ac_try\"") >&5
5814 echo "$as_me:5814: \$? = $ac_status" >&5
5815 (exit "$ac_status"); }; }; then
5816 cf_cv_xopen_source=no
5818 echo "$as_me: failed program was:" >&5
5819 cat "conftest.$ac_ext" >&5
5820 cf_cv_xopen_source=$cf_XOPEN_SOURCE
5822 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5826 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5829 echo "$as_me:5829: result: $cf_cv_xopen_source" >&5
5830 echo "${ECHO_T}$cf_cv_xopen_source" >&6
5832 if test "$cf_cv_xopen_source" != no ; then
5834 CFLAGS=`echo "$CFLAGS" | \
5835 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
5836 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
5838 CPPFLAGS=`echo "$CPPFLAGS" | \
5839 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
5840 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
5842 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
5844 for cf_add_cflags in $cf_temp_xopen_source
5846 case "x$cf_add_cflags" in
5849 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
5852 cf_old_cflag=`echo "x$CFLAGS" | sed -e 's/^.//' -e 's/[ ][ ]*-/ -/g' -e "s%$cf_tmp_cflag\\(=[^ ][^ ]*\\)\?%%" -e 's/^[ ]*//' -e 's%[ ][ ]*-D% -D%g' -e 's%[ ][ ]*-I% -I%g'`
5853 test "$CFLAGS" != "$cf_old_cflag" || break
5855 CFLAGS="$cf_old_cflag"
5858 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
5861 cf_old_cflag=`echo "x$CPPFLAGS" | sed -e 's/^.//' -e 's/[ ][ ]*-/ -/g' -e "s%$cf_tmp_cflag\\(=[^ ][^ ]*\\)\?%%" -e 's/^[ ]*//' -e 's%[ ][ ]*-D% -D%g' -e 's%[ ][ ]*-I% -I%g'`
5862 test "$CPPFLAGS" != "$cf_old_cflag" || break
5864 CPPFLAGS="$cf_old_cflag"
5873 cf_new_extra_cppflags=
5875 for cf_add_cflags in $cf_add_cflags
5877 case "$cf_fix_cppflags" in
5879 case "$cf_add_cflags" in
5880 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
5881 case "$cf_add_cflags" in
5883 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
5885 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
5886 && test -z "${cf_tst_cflags}" \
5887 && cf_fix_cppflags=yes
5889 if test "$cf_fix_cppflags" = yes ; then
5891 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5892 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5895 elif test "${cf_tst_cflags}" = "\"'" ; then
5897 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5898 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5908 case "$cf_add_cflags" in
5910 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
5912 CPPFLAGS=`echo "$CPPFLAGS" | \
5913 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
5914 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
5919 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
5920 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
5927 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
5928 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
5935 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5936 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5938 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
5940 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
5941 && test -z "${cf_tst_cflags}" \
5942 && cf_fix_cppflags=no
5947 if test -n "$cf_new_cflags" ; then
5949 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
5950 CFLAGS="${CFLAGS}$cf_new_cflags"
5954 if test -n "$cf_new_cppflags" ; then
5956 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5957 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
5961 if test -n "$cf_new_extra_cppflags" ; then
5963 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
5964 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
5974 fi # cf_cv_posix_visible
5976 echo "$as_me:5976: checking for ANSI C header files" >&5
5977 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
5978 if test "${ac_cv_header_stdc+set}" = set; then
5979 echo $ECHO_N "(cached) $ECHO_C" >&6
5981 cat >"conftest.$ac_ext" <<_ACEOF
5982 #line 5982 "configure"
5983 #include "confdefs.h"
5990 if { (eval echo "$as_me:5990: \"$ac_cpp "conftest.$ac_ext"\"") >&5
5991 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
5993 $EGREP -v '^ *\+' conftest.er1 >conftest.err
5995 cat conftest.err >&5
5996 echo "$as_me:5996: \$? = $ac_status" >&5
5997 (exit "$ac_status"); } >/dev/null; then
5998 if test -s conftest.err; then
5999 ac_cpp_err=$ac_c_preproc_warn_flag
6006 if test -z "$ac_cpp_err"; then
6007 ac_cv_header_stdc=yes
6009 echo "$as_me: failed program was:" >&5
6010 cat "conftest.$ac_ext" >&5
6011 ac_cv_header_stdc=no
6013 rm -f conftest.err "conftest.$ac_ext"
6015 if test $ac_cv_header_stdc = yes; then
6016 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
6017 cat >"conftest.$ac_ext" <<_ACEOF
6018 #line 6018 "configure"
6019 #include "confdefs.h"
6023 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6024 $EGREP "memchr" >/dev/null 2>&1; then
6027 ac_cv_header_stdc=no
6033 if test $ac_cv_header_stdc = yes; then
6034 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
6035 cat >"conftest.$ac_ext" <<_ACEOF
6036 #line 6036 "configure"
6037 #include "confdefs.h"
6041 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6042 $EGREP "free" >/dev/null 2>&1; then
6045 ac_cv_header_stdc=no
6051 if test $ac_cv_header_stdc = yes; then
6052 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
6053 if test "$cross_compiling" = yes; then
6056 cat >"conftest.$ac_ext" <<_ACEOF
6057 #line 6057 "configure"
6058 #include "confdefs.h"
6060 #if ((' ' & 0x0FF) == 0x020)
6061 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
6062 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
6064 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
6065 || ('j' <= (c) && (c) <= 'r') \
6066 || ('s' <= (c) && (c) <= 'z'))
6067 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
6070 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
6075 for (i = 0; i < 256; i++)
6076 if (XOR (islower (i), ISLOWER (i))
6077 || toupper (i) != TOUPPER (i))
6079 $ac_main_return (0);
6082 rm -f "conftest$ac_exeext"
6083 if { (eval echo "$as_me:6083: \"$ac_link\"") >&5
6084 (eval $ac_link) 2>&5
6086 echo "$as_me:6086: \$? = $ac_status" >&5
6087 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
6088 { (eval echo "$as_me:6088: \"$ac_try\"") >&5
6091 echo "$as_me:6091: \$? = $ac_status" >&5
6092 (exit "$ac_status"); }; }; then
6095 echo "$as_me: program exited with status $ac_status" >&5
6096 echo "$as_me: failed program was:" >&5
6097 cat "conftest.$ac_ext" >&5
6098 ac_cv_header_stdc=no
6100 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
6104 echo "$as_me:6104: result: $ac_cv_header_stdc" >&5
6105 echo "${ECHO_T}$ac_cv_header_stdc" >&6
6106 if test $ac_cv_header_stdc = yes; then
6108 cat >>confdefs.h <<\EOF
6109 #define STDC_HEADERS 1
6114 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
6116 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
6117 inttypes.h stdint.h unistd.h
6119 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6120 echo "$as_me:6120: checking for $ac_header" >&5
6121 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6122 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6123 echo $ECHO_N "(cached) $ECHO_C" >&6
6125 cat >"conftest.$ac_ext" <<_ACEOF
6126 #line 6126 "configure"
6127 #include "confdefs.h"
6128 $ac_includes_default
6129 #include <$ac_header>
6131 rm -f "conftest.$ac_objext"
6132 if { (eval echo "$as_me:6132: \"$ac_compile\"") >&5
6133 (eval $ac_compile) 2>&5
6135 echo "$as_me:6135: \$? = $ac_status" >&5
6136 (exit "$ac_status"); } &&
6137 { ac_try='test -s "conftest.$ac_objext"'
6138 { (eval echo "$as_me:6138: \"$ac_try\"") >&5
6141 echo "$as_me:6141: \$? = $ac_status" >&5
6142 (exit "$ac_status"); }; }; then
6143 eval "$as_ac_Header=yes"
6145 echo "$as_me: failed program was:" >&5
6146 cat "conftest.$ac_ext" >&5
6147 eval "$as_ac_Header=no"
6149 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
6151 echo "$as_me:6151: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
6152 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
6153 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
6154 cat >>confdefs.h <<EOF
6155 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6161 echo "$as_me:6161: checking whether exit is declared" >&5
6162 echo $ECHO_N "checking whether exit is declared... $ECHO_C" >&6
6163 if test "${ac_cv_have_decl_exit+set}" = set; then
6164 echo $ECHO_N "(cached) $ECHO_C" >&6
6166 cat >"conftest.$ac_ext" <<_ACEOF
6167 #line 6167 "configure"
6168 #include "confdefs.h"
6169 $ac_includes_default
6181 rm -f "conftest.$ac_objext"
6182 if { (eval echo "$as_me:6182: \"$ac_compile\"") >&5
6183 (eval $ac_compile) 2>&5
6185 echo "$as_me:6185: \$? = $ac_status" >&5
6186 (exit "$ac_status"); } &&
6187 { ac_try='test -s "conftest.$ac_objext"'
6188 { (eval echo "$as_me:6188: \"$ac_try\"") >&5
6191 echo "$as_me:6191: \$? = $ac_status" >&5
6192 (exit "$ac_status"); }; }; then
6193 ac_cv_have_decl_exit=yes
6195 echo "$as_me: failed program was:" >&5
6196 cat "conftest.$ac_ext" >&5
6197 ac_cv_have_decl_exit=no
6199 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
6201 echo "$as_me:6201: result: $ac_cv_have_decl_exit" >&5
6202 echo "${ECHO_T}$ac_cv_have_decl_exit" >&6
6204 echo "$as_me:6204: checking for signal global datatype" >&5
6205 echo $ECHO_N "checking for signal global datatype... $ECHO_C" >&6
6206 if test "${cf_cv_sig_atomic_t+set}" = set; then
6207 echo $ECHO_N "(cached) $ECHO_C" >&6
6211 "volatile sig_atomic_t" \
6215 cat >"conftest.$ac_ext" <<_ACEOF
6216 #line 6216 "configure"
6217 #include "confdefs.h"
6219 #include <sys/types.h>
6225 static void handler(int sig)
6233 signal(SIGINT, handler);
6239 rm -f "conftest.$ac_objext"
6240 if { (eval echo "$as_me:6240: \"$ac_compile\"") >&5
6241 (eval $ac_compile) 2>&5
6243 echo "$as_me:6243: \$? = $ac_status" >&5
6244 (exit "$ac_status"); } &&
6245 { ac_try='test -s "conftest.$ac_objext"'
6246 { (eval echo "$as_me:6246: \"$ac_try\"") >&5
6249 echo "$as_me:6249: \$? = $ac_status" >&5
6250 (exit "$ac_status"); }; }; then
6251 cf_cv_sig_atomic_t=$cf_type
6253 echo "$as_me: failed program was:" >&5
6254 cat "conftest.$ac_ext" >&5
6255 cf_cv_sig_atomic_t=no
6257 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
6258 test "$cf_cv_sig_atomic_t" != no && break
6263 echo "$as_me:6263: result: $cf_cv_sig_atomic_t" >&5
6264 echo "${ECHO_T}$cf_cv_sig_atomic_t" >&6
6265 test "$cf_cv_sig_atomic_t" != no &&
6266 cat >>confdefs.h <<EOF
6267 #define SIG_ATOMIC_T $cf_cv_sig_atomic_t
6270 # Work around breakage on OS X
6272 echo "$as_me:6272: checking if SIGWINCH is defined" >&5
6273 echo $ECHO_N "checking if SIGWINCH is defined... $ECHO_C" >&6
6274 if test "${cf_cv_define_sigwinch+set}" = set; then
6275 echo $ECHO_N "(cached) $ECHO_C" >&6
6278 cat >"conftest.$ac_ext" <<_ACEOF
6279 #line 6279 "configure"
6280 #include "confdefs.h"
6282 #include <sys/types.h>
6283 #include <sys/signal.h>
6288 int x = SIGWINCH; (void)x
6293 rm -f "conftest.$ac_objext"
6294 if { (eval echo "$as_me:6294: \"$ac_compile\"") >&5
6295 (eval $ac_compile) 2>&5
6297 echo "$as_me:6297: \$? = $ac_status" >&5
6298 (exit "$ac_status"); } &&
6299 { ac_try='test -s "conftest.$ac_objext"'
6300 { (eval echo "$as_me:6300: \"$ac_try\"") >&5
6303 echo "$as_me:6303: \$? = $ac_status" >&5
6304 (exit "$ac_status"); }; }; then
6305 cf_cv_define_sigwinch=yes
6307 echo "$as_me: failed program was:" >&5
6308 cat "conftest.$ac_ext" >&5
6309 cat >"conftest.$ac_ext" <<_ACEOF
6310 #line 6310 "configure"
6311 #include "confdefs.h"
6313 #undef _XOPEN_SOURCE
6314 #undef _POSIX_SOURCE
6315 #undef _POSIX_C_SOURCE
6316 #include <sys/types.h>
6317 #include <sys/signal.h>
6322 int x = SIGWINCH; (void)x
6327 rm -f "conftest.$ac_objext"
6328 if { (eval echo "$as_me:6328: \"$ac_compile\"") >&5
6329 (eval $ac_compile) 2>&5
6331 echo "$as_me:6331: \$? = $ac_status" >&5
6332 (exit "$ac_status"); } &&
6333 { ac_try='test -s "conftest.$ac_objext"'
6334 { (eval echo "$as_me:6334: \"$ac_try\"") >&5
6337 echo "$as_me:6337: \$? = $ac_status" >&5
6338 (exit "$ac_status"); }; }; then
6339 cf_cv_define_sigwinch=maybe
6341 echo "$as_me: failed program was:" >&5
6342 cat "conftest.$ac_ext" >&5
6343 cf_cv_define_sigwinch=no
6345 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
6348 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
6351 echo "$as_me:6351: result: $cf_cv_define_sigwinch" >&5
6352 echo "${ECHO_T}$cf_cv_define_sigwinch" >&6
6354 if test "$cf_cv_define_sigwinch" = maybe ; then
6355 echo "$as_me:6355: checking for actual SIGWINCH definition" >&5
6356 echo $ECHO_N "checking for actual SIGWINCH definition... $ECHO_C" >&6
6357 if test "${cf_cv_fixup_sigwinch+set}" = set; then
6358 echo $ECHO_N "(cached) $ECHO_C" >&6
6361 cf_cv_fixup_sigwinch=unknown
6363 while test "$cf_sigwinch" != 1
6365 cat >"conftest.$ac_ext" <<_ACEOF
6366 #line 6366 "configure"
6367 #include "confdefs.h"
6369 #undef _XOPEN_SOURCE
6370 #undef _POSIX_SOURCE
6371 #undef _POSIX_C_SOURCE
6372 #include <sys/types.h>
6373 #include <sys/signal.h>
6379 #if SIGWINCH != $cf_sigwinch
6380 #error SIGWINCH is not $cf_sigwinch
6382 int x = SIGWINCH; (void)x
6387 rm -f "conftest.$ac_objext"
6388 if { (eval echo "$as_me:6388: \"$ac_compile\"") >&5
6389 (eval $ac_compile) 2>&5
6391 echo "$as_me:6391: \$? = $ac_status" >&5
6392 (exit "$ac_status"); } &&
6393 { ac_try='test -s "conftest.$ac_objext"'
6394 { (eval echo "$as_me:6394: \"$ac_try\"") >&5
6397 echo "$as_me:6397: \$? = $ac_status" >&5
6398 (exit "$ac_status"); }; }; then
6399 cf_cv_fixup_sigwinch=$cf_sigwinch
6402 echo "$as_me: failed program was:" >&5
6403 cat "conftest.$ac_ext" >&5
6405 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
6407 cf_sigwinch="`expr "$cf_sigwinch" - 1`"
6411 echo "$as_me:6411: result: $cf_cv_fixup_sigwinch" >&5
6412 echo "${ECHO_T}$cf_cv_fixup_sigwinch" >&6
6414 if test "$cf_cv_fixup_sigwinch" != unknown ; then
6415 CPPFLAGS="$CPPFLAGS -DSIGWINCH=$cf_cv_fixup_sigwinch"
6419 # Checks for CODESET support.
6421 echo "$as_me:6421: checking for nl_langinfo and CODESET" >&5
6422 echo $ECHO_N "checking for nl_langinfo and CODESET... $ECHO_C" >&6
6423 if test "${am_cv_langinfo_codeset+set}" = set; then
6424 echo $ECHO_N "(cached) $ECHO_C" >&6
6426 cat >"conftest.$ac_ext" <<_ACEOF
6427 #line 6427 "configure"
6428 #include "confdefs.h"
6430 $ac_includes_default
6431 #include <langinfo.h>
6435 char* cs = nl_langinfo(CODESET); (void)cs
6440 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
6441 if { (eval echo "$as_me:6441: \"$ac_link\"") >&5
6442 (eval $ac_link) 2>&5
6444 echo "$as_me:6444: \$? = $ac_status" >&5
6445 (exit "$ac_status"); } &&
6446 { ac_try='test -s "conftest$ac_exeext"'
6447 { (eval echo "$as_me:6447: \"$ac_try\"") >&5
6450 echo "$as_me:6450: \$? = $ac_status" >&5
6451 (exit "$ac_status"); }; }; then
6452 am_cv_langinfo_codeset=yes
6454 echo "$as_me: failed program was:" >&5
6455 cat "conftest.$ac_ext" >&5
6456 am_cv_langinfo_codeset=no
6458 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
6461 echo "$as_me:6461: result: $am_cv_langinfo_codeset" >&5
6462 echo "${ECHO_T}$am_cv_langinfo_codeset" >&6
6463 if test "$am_cv_langinfo_codeset" = yes; then
6465 cat >>confdefs.h <<\EOF
6466 #define HAVE_LANGINFO_CODESET 1
6471 echo "$as_me:6471: checking if you want to use pkg-config" >&5
6472 echo $ECHO_N "checking if you want to use pkg-config... $ECHO_C" >&6
6474 # Check whether --with-pkg-config or --without-pkg-config was given.
6475 if test "${with_pkg_config+set}" = set; then
6476 withval="$with_pkg_config"
6477 cf_pkg_config=$withval
6481 echo "$as_me:6481: result: $cf_pkg_config" >&5
6482 echo "${ECHO_T}$cf_pkg_config" >&6
6484 case "$cf_pkg_config" in
6490 if test -n "$ac_tool_prefix"; then
6491 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
6492 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
6493 echo "$as_me:6493: checking for $ac_word" >&5
6494 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
6495 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then
6496 echo $ECHO_N "(cached) $ECHO_C" >&6
6500 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
6503 ac_save_IFS=$IFS; IFS=$ac_path_separator
6505 for ac_dir in $ac_dummy; do
6507 test -z "$ac_dir" && ac_dir=.
6508 if $as_executable_p "$ac_dir/$ac_word"; then
6509 ac_cv_path_PKG_CONFIG="$ac_dir/$ac_word"
6510 echo "$as_me:6510: found $ac_dir/$ac_word" >&5
6518 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
6520 if test -n "$PKG_CONFIG"; then
6521 echo "$as_me:6521: result: $PKG_CONFIG" >&5
6522 echo "${ECHO_T}$PKG_CONFIG" >&6
6524 echo "$as_me:6524: result: no" >&5
6525 echo "${ECHO_T}no" >&6
6529 if test -z "$ac_cv_path_PKG_CONFIG"; then
6530 ac_pt_PKG_CONFIG=$PKG_CONFIG
6531 # Extract the first word of "pkg-config", so it can be a program name with args.
6532 set dummy pkg-config; ac_word=$2
6533 echo "$as_me:6533: checking for $ac_word" >&5
6534 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
6535 if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then
6536 echo $ECHO_N "(cached) $ECHO_C" >&6
6538 case $ac_pt_PKG_CONFIG in
6540 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
6543 ac_save_IFS=$IFS; IFS=$ac_path_separator
6545 for ac_dir in $ac_dummy; do
6547 test -z "$ac_dir" && ac_dir=.
6548 if $as_executable_p "$ac_dir/$ac_word"; then
6549 ac_cv_path_ac_pt_PKG_CONFIG="$ac_dir/$ac_word"
6550 echo "$as_me:6550: found $ac_dir/$ac_word" >&5
6555 test -z "$ac_cv_path_ac_pt_PKG_CONFIG" && ac_cv_path_ac_pt_PKG_CONFIG="none"
6559 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
6561 if test -n "$ac_pt_PKG_CONFIG"; then
6562 echo "$as_me:6562: result: $ac_pt_PKG_CONFIG" >&5
6563 echo "${ECHO_T}$ac_pt_PKG_CONFIG" >&6
6565 echo "$as_me:6565: result: no" >&5
6566 echo "${ECHO_T}no" >&6
6569 PKG_CONFIG=$ac_pt_PKG_CONFIG
6571 PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
6580 test -z "$PKG_CONFIG" && PKG_CONFIG=none
6581 if test "$PKG_CONFIG" != none ; then
6583 if test "x$prefix" != xNONE; then
6584 cf_path_syntax="$prefix"
6586 cf_path_syntax="$ac_default_prefix"
6589 case ".$PKG_CONFIG" in
6594 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
6596 (.\$\{*prefix\}*|.\$\{*dir\}*)
6597 eval PKG_CONFIG="$PKG_CONFIG"
6598 case ".$PKG_CONFIG" in
6600 PKG_CONFIG=`echo "$PKG_CONFIG" | sed -e s%NONE%$cf_path_syntax%`
6605 PKG_CONFIG=`echo "$PKG_CONFIG" | sed -e s%NONE%$cf_path_syntax%`
6608 { { echo "$as_me:6608: error: expected a pathname, not \"$PKG_CONFIG\"" >&5
6609 echo "$as_me: error: expected a pathname, not \"$PKG_CONFIG\"" >&2;}
6610 { (exit 1); exit 1; }; }
6614 elif test "x$cf_pkg_config" != xno ; then
6615 { echo "$as_me:6615: WARNING: pkg-config is not installed" >&5
6616 echo "$as_me: WARNING: pkg-config is not installed" >&2;}
6619 echo "$as_me:6619: checking if you want to see long compiling messages" >&5
6620 echo $ECHO_N "checking if you want to see long compiling messages... $ECHO_C" >&6
6622 # Check whether --enable-echo or --disable-echo was given.
6623 if test "${enable_echo+set}" = set; then
6624 enableval="$enable_echo"
6625 test "$enableval" != no && enableval=yes
6626 if test "$enableval" != "yes" ; then
6629 ECHO_LD='@echo linking $@;'
6630 RULE_CC='@echo compiling $<'
6631 SHOW_CC='@echo compiling $@'
6653 echo "$as_me:6653: result: $enableval" >&5
6654 echo "${ECHO_T}$enableval" >&6
6656 echo "$as_me:6656: checking for ncurses wrap-prefix" >&5
6657 echo $ECHO_N "checking for ncurses wrap-prefix... $ECHO_C" >&6
6659 # Check whether --with-ncurses-wrap-prefix or --without-ncurses-wrap-prefix was given.
6660 if test "${with_ncurses_wrap_prefix+set}" = set; then
6661 withval="$with_ncurses_wrap_prefix"
6662 NCURSES_WRAP_PREFIX=$withval
6664 NCURSES_WRAP_PREFIX=_nc_
6666 echo "$as_me:6666: result: $NCURSES_WRAP_PREFIX" >&5
6667 echo "${ECHO_T}$NCURSES_WRAP_PREFIX" >&6
6669 echo "$as_me:6669: checking if you want to check for wide-character functions" >&5
6670 echo $ECHO_N "checking if you want to check for wide-character functions... $ECHO_C" >&6
6672 # Check whether --enable-widec or --disable-widec was given.
6673 if test "${enable_widec+set}" = set; then
6674 enableval="$enable_widec"
6675 test "$enableval" != no && enableval=yes
6676 if test "$enableval" != "yes" ; then
6686 echo "$as_me:6686: result: $cf_enable_widec" >&5
6687 echo "${ECHO_T}$cf_enable_widec" >&6
6689 echo "$as_me:6689: checking for specific curses-directory" >&5
6690 echo $ECHO_N "checking for specific curses-directory... $ECHO_C" >&6
6692 # Check whether --with-curses-dir or --without-curses-dir was given.
6693 if test "${with_curses_dir+set}" = set; then
6694 withval="$with_curses_dir"
6695 cf_cv_curses_dir=$withval
6699 echo "$as_me:6699: result: $cf_cv_curses_dir" >&5
6700 echo "${ECHO_T}$cf_cv_curses_dir" >&6
6702 if test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no"
6705 if test "x$prefix" != xNONE; then
6706 cf_path_syntax="$prefix"
6708 cf_path_syntax="$ac_default_prefix"
6716 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
6718 (.\$\{*prefix\}*|.\$\{*dir\}*)
6719 eval withval="$withval"
6722 withval=`echo "$withval" | sed -e s%NONE%$cf_path_syntax%`
6727 withval=`echo "$withval" | sed -e s%NONE%$cf_path_syntax%`
6730 { { echo "$as_me:6730: error: expected a pathname, not \"$withval\"" >&5
6731 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
6732 { (exit 1); exit 1; }; }
6736 if test -d "$cf_cv_curses_dir"
6739 if test -n "$cf_cv_curses_dir/include" ; then
6740 for cf_add_incdir in $cf_cv_curses_dir/include
6742 while test "$cf_add_incdir" != /usr/include
6744 if test -d "$cf_add_incdir"
6747 if test -n "$CFLAGS$CPPFLAGS" ; then
6748 # a loop is needed to ensure we can add subdirs of existing dirs
6749 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
6750 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
6751 cf_have_incdir=yes; break
6756 if test "$cf_have_incdir" = no ; then
6757 if test "$cf_add_incdir" = /usr/local/include ; then
6758 if test "$GCC" = yes
6760 cf_save_CPPFLAGS=$CPPFLAGS
6762 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
6763 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
6765 cat >"conftest.$ac_ext" <<_ACEOF
6766 #line 6766 "configure"
6767 #include "confdefs.h"
6777 rm -f "conftest.$ac_objext"
6778 if { (eval echo "$as_me:6778: \"$ac_compile\"") >&5
6779 (eval $ac_compile) 2>&5
6781 echo "$as_me:6781: \$? = $ac_status" >&5
6782 (exit "$ac_status"); } &&
6783 { ac_try='test -s "conftest.$ac_objext"'
6784 { (eval echo "$as_me:6784: \"$ac_try\"") >&5
6787 echo "$as_me:6787: \$? = $ac_status" >&5
6788 (exit "$ac_status"); }; }; then
6791 echo "$as_me: failed program was:" >&5
6792 cat "conftest.$ac_ext" >&5
6795 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
6796 CPPFLAGS=$cf_save_CPPFLAGS
6801 if test "$cf_have_incdir" = no ; then
6802 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
6804 echo "${as_me:-configure}:6804: testing adding $cf_add_incdir to include-path ..." 1>&5
6806 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6808 cf_top_incdir=`echo "$cf_add_incdir" | sed -e 's%/include/.*$%/include%'`
6809 test "$cf_top_incdir" = "$cf_add_incdir" && break
6810 cf_add_incdir="$cf_top_incdir"
6821 if test -n "$cf_cv_curses_dir/lib" ; then
6822 for cf_add_libdir in $cf_cv_curses_dir/lib
6824 if test "$cf_add_libdir" = /usr/lib ; then
6826 elif test -d "$cf_add_libdir"
6829 if test -n "$LDFLAGS$LIBS" ; then
6830 # a loop is needed to ensure we can add subdirs of existing dirs
6831 for cf_test_libdir in $LDFLAGS $LIBS ; do
6832 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
6833 cf_have_libdir=yes; break
6837 if test "$cf_have_libdir" = no ; then
6838 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
6840 echo "${as_me:-configure}:6840: testing adding $cf_add_libdir to library-path ..." 1>&5
6842 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
6853 echo "$as_me:6853: checking for specified curses library type" >&5
6854 echo $ECHO_N "checking for specified curses library type... $ECHO_C" >&6
6856 # Check whether --with-screen or --without-screen was given.
6857 if test "${with_screen+set}" = set; then
6858 withval="$with_screen"
6859 cf_cv_screen=$withval
6862 # Check whether --with-ncursesw or --without-ncursesw was given.
6863 if test "${with_ncursesw+set}" = set; then
6864 withval="$with_ncursesw"
6865 cf_cv_screen=ncursesw
6868 # Check whether --with-ncurses or --without-ncurses was given.
6869 if test "${with_ncurses+set}" = set; then
6870 withval="$with_ncurses"
6871 cf_cv_screen=ncurses
6874 # Check whether --with-pdcurses or --without-pdcurses was given.
6875 if test "${with_pdcurses+set}" = set; then
6876 withval="$with_pdcurses"
6877 cf_cv_screen=pdcurses
6880 # Check whether --with-curses-colr or --without-curses-colr was given.
6881 if test "${with_curses_colr+set}" = set; then
6882 withval="$with_curses_colr"
6883 cf_cv_screen=curses_colr
6886 # Check whether --with-curses-5lib or --without-curses-5lib was given.
6887 if test "${with_curses_5lib+set}" = set; then
6888 withval="$with_curses_5lib"
6889 cf_cv_screen=curses_5lib
6897 echo "$as_me:6897: result: $cf_cv_screen" >&5
6898 echo "${ECHO_T}$cf_cv_screen" >&6
6900 case $cf_cv_screen in
6903 echo "$as_me:6903: checking for extra include directories" >&5
6904 echo $ECHO_N "checking for extra include directories... $ECHO_C" >&6
6905 if test "${cf_cv_curses_incdir+set}" = set; then
6906 echo $ECHO_N "(cached) $ECHO_C" >&6
6909 cf_cv_curses_incdir=no
6912 if test "x$cf_cv_screen" = "xcurses_colr"
6914 test -d /usr/include/curses_colr && \
6915 cf_cv_curses_incdir="-I/usr/include/curses_colr"
6919 if test "x$cf_cv_screen" = "xcurses_5lib"
6921 test -d /usr/5lib && \
6922 test -d /usr/5include && \
6923 cf_cv_curses_incdir="-I/usr/5include"
6929 echo "$as_me:6929: result: $cf_cv_curses_incdir" >&5
6930 echo "${ECHO_T}$cf_cv_curses_incdir" >&6
6931 if test "$cf_cv_curses_incdir" != no
6934 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
6935 CPPFLAGS="${CPPFLAGS}$cf_cv_curses_incdir"
6939 echo "$as_me:6939: checking if we have identified curses headers" >&5
6940 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
6941 if test "${cf_cv_ncurses_header+set}" = set; then
6942 echo $ECHO_N "(cached) $ECHO_C" >&6
6945 cf_cv_ncurses_header=none
6948 curses.h ncurses/ncurses.h ncurses/curses.h
6950 cat >"conftest.$ac_ext" <<_ACEOF
6951 #line 6951 "configure"
6952 #include "confdefs.h"
6953 #include <${cf_header}>
6962 rm -f "conftest.$ac_objext"
6963 if { (eval echo "$as_me:6963: \"$ac_compile\"") >&5
6964 (eval $ac_compile) 2>&5
6966 echo "$as_me:6966: \$? = $ac_status" >&5
6967 (exit "$ac_status"); } &&
6968 { ac_try='test -s "conftest.$ac_objext"'
6969 { (eval echo "$as_me:6969: \"$ac_try\"") >&5
6972 echo "$as_me:6972: \$? = $ac_status" >&5
6973 (exit "$ac_status"); }; }; then
6974 cf_cv_ncurses_header=$cf_header; break
6976 echo "$as_me: failed program was:" >&5
6977 cat "conftest.$ac_ext" >&5
6979 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
6983 echo "$as_me:6983: result: $cf_cv_ncurses_header" >&5
6984 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
6986 if test "$cf_cv_ncurses_header" = none ; then
6987 { { echo "$as_me:6987: error: No curses header-files found" >&5
6988 echo "$as_me: error: No curses header-files found" >&2;}
6989 { (exit 1); exit 1; }; }
6992 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
6994 for ac_header in $cf_cv_ncurses_header
6996 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6997 echo "$as_me:6997: checking for $ac_header" >&5
6998 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6999 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7000 echo $ECHO_N "(cached) $ECHO_C" >&6
7002 cat >"conftest.$ac_ext" <<_ACEOF
7003 #line 7003 "configure"
7004 #include "confdefs.h"
7005 #include <$ac_header>
7007 if { (eval echo "$as_me:7007: \"$ac_cpp "conftest.$ac_ext"\"") >&5
7008 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
7010 $EGREP -v '^ *\+' conftest.er1 >conftest.err
7012 cat conftest.err >&5
7013 echo "$as_me:7013: \$? = $ac_status" >&5
7014 (exit "$ac_status"); } >/dev/null; then
7015 if test -s conftest.err; then
7016 ac_cpp_err=$ac_c_preproc_warn_flag
7023 if test -z "$ac_cpp_err"; then
7024 eval "$as_ac_Header=yes"
7026 echo "$as_me: failed program was:" >&5
7027 cat "conftest.$ac_ext" >&5
7028 eval "$as_ac_Header=no"
7030 rm -f conftest.err "conftest.$ac_ext"
7032 echo "$as_me:7032: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
7033 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
7034 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
7035 cat >>confdefs.h <<EOF
7036 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7042 echo "$as_me:7042: checking for terminfo header" >&5
7043 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
7044 if test "${cf_cv_term_header+set}" = set; then
7045 echo $ECHO_N "(cached) $ECHO_C" >&6
7048 case "${cf_cv_ncurses_header}" in
7049 (*/ncurses.h|*/ncursesw.h)
7050 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
7053 cf_term_header=term.h
7057 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
7059 cat >"conftest.$ac_ext" <<_ACEOF
7060 #line 7060 "configure"
7061 #include "confdefs.h"
7063 #include <${cf_cv_ncurses_header:-curses.h}>
7069 int x = auto_left_margin; (void)x
7074 rm -f "conftest.$ac_objext"
7075 if { (eval echo "$as_me:7075: \"$ac_compile\"") >&5
7076 (eval $ac_compile) 2>&5
7078 echo "$as_me:7078: \$? = $ac_status" >&5
7079 (exit "$ac_status"); } &&
7080 { ac_try='test -s "conftest.$ac_objext"'
7081 { (eval echo "$as_me:7081: \"$ac_try\"") >&5
7084 echo "$as_me:7084: \$? = $ac_status" >&5
7085 (exit "$ac_status"); }; }; then
7087 cf_cv_term_header="$cf_test"
7089 echo "$as_me: failed program was:" >&5
7090 cat "conftest.$ac_ext" >&5
7092 cf_cv_term_header=unknown
7095 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
7096 test "$cf_cv_term_header" != unknown && break
7100 echo "$as_me:7100: result: $cf_cv_term_header" >&5
7101 echo "${ECHO_T}$cf_cv_term_header" >&6
7103 # Set definitions to allow ifdef'ing to accommodate subdirectories
7105 case "$cf_cv_term_header" in
7108 cat >>confdefs.h <<\EOF
7109 #define HAVE_TERM_H 1
7115 case "$cf_cv_term_header" in
7118 cat >>confdefs.h <<\EOF
7119 #define HAVE_NCURSES_TERM_H 1
7125 cat >>confdefs.h <<\EOF
7126 #define HAVE_NCURSESW_TERM_H 1
7132 echo "$as_me:7132: checking for ncurses version" >&5
7133 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
7134 if test "${cf_cv_ncurses_version+set}" = set; then
7135 echo $ECHO_N "(cached) $ECHO_C" >&6
7138 cf_cv_ncurses_version=no
7140 rm -f "$cf_tempfile"
7141 if test "$cross_compiling" = yes; then
7143 # This will not work if the preprocessor splits the line after the
7144 # Autoconf token. The 'unproto' program does that.
7145 cat > "conftest.$ac_ext" <<EOF
7146 #include <${cf_cv_ncurses_header:-curses.h}>
7148 #ifdef NCURSES_VERSION
7149 Autoconf NCURSES_VERSION
7157 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
7158 { (eval echo "$as_me:7158: \"$cf_try\"") >&5
7161 echo "$as_me:7161: \$? = $ac_status" >&5
7162 (exit "$ac_status"); }
7163 if test -f conftest.out ; then
7164 cf_out=`sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%' conftest.out`
7165 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
7170 cat >"conftest.$ac_ext" <<_ACEOF
7171 #line 7171 "configure"
7172 #include "confdefs.h"
7174 $ac_includes_default
7176 #include <${cf_cv_ncurses_header:-curses.h}>
7180 FILE *fp = fopen("$cf_tempfile", "w");
7181 #ifdef NCURSES_VERSION
7182 # ifdef NCURSES_VERSION_PATCH
7183 fprintf(fp, "%s.%d\\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
7185 fprintf(fp, "%s\\n", NCURSES_VERSION);
7189 fprintf(fp, "old\\n");
7191 #error expected ncurses header to define __NCURSES_H
7194 ${cf_cv_main_return:-return}(0);
7197 rm -f "conftest$ac_exeext"
7198 if { (eval echo "$as_me:7198: \"$ac_link\"") >&5
7199 (eval $ac_link) 2>&5
7201 echo "$as_me:7201: \$? = $ac_status" >&5
7202 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
7203 { (eval echo "$as_me:7203: \"$ac_try\"") >&5
7206 echo "$as_me:7206: \$? = $ac_status" >&5
7207 (exit "$ac_status"); }; }; then
7209 cf_cv_ncurses_version=`cat $cf_tempfile`
7211 echo "$as_me: program exited with status $ac_status" >&5
7212 echo "$as_me: failed program was:" >&5
7213 cat "conftest.$ac_ext" >&5
7215 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
7217 rm -f "$cf_tempfile"
7220 echo "$as_me:7220: result: $cf_cv_ncurses_version" >&5
7221 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
7222 test "$cf_cv_ncurses_version" = no ||
7223 cat >>confdefs.h <<\EOF
7227 echo "$as_me:7227: checking if we have identified curses libraries" >&5
7228 echo $ECHO_N "checking if we have identified curses libraries... $ECHO_C" >&6
7229 cat >"conftest.$ac_ext" <<_ACEOF
7230 #line 7230 "configure"
7231 #include "confdefs.h"
7232 #include <${cf_cv_ncurses_header:-curses.h}>
7241 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
7242 if { (eval echo "$as_me:7242: \"$ac_link\"") >&5
7243 (eval $ac_link) 2>&5
7245 echo "$as_me:7245: \$? = $ac_status" >&5
7246 (exit "$ac_status"); } &&
7247 { ac_try='test -s "conftest$ac_exeext"'
7248 { (eval echo "$as_me:7248: \"$ac_try\"") >&5
7251 echo "$as_me:7251: \$? = $ac_status" >&5
7252 (exit "$ac_status"); }; }; then
7255 echo "$as_me: failed program was:" >&5
7256 cat "conftest.$ac_ext" >&5
7259 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
7260 echo "$as_me:7260: result: $cf_result" >&5
7261 echo "${ECHO_T}$cf_result" >&6
7263 if test "$cf_result" = no ; then
7266 echo "$as_me:7266: checking for tgoto in -lmytinfo" >&5
7267 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
7268 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
7269 echo $ECHO_N "(cached) $ECHO_C" >&6
7271 ac_check_lib_save_LIBS=$LIBS
7272 LIBS="-lmytinfo $LIBS"
7273 cat >"conftest.$ac_ext" <<_ACEOF
7274 #line 7274 "configure"
7275 #include "confdefs.h"
7277 /* Override any gcc2 internal prototype to avoid an error. */
7281 /* We use char because int might match the return type of a gcc2
7282 builtin and then its argument prototype would still apply. */
7292 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
7293 if { (eval echo "$as_me:7293: \"$ac_link\"") >&5
7294 (eval $ac_link) 2>&5
7296 echo "$as_me:7296: \$? = $ac_status" >&5
7297 (exit "$ac_status"); } &&
7298 { ac_try='test -s "conftest$ac_exeext"'
7299 { (eval echo "$as_me:7299: \"$ac_try\"") >&5
7302 echo "$as_me:7302: \$? = $ac_status" >&5
7303 (exit "$ac_status"); }; }; then
7304 ac_cv_lib_mytinfo_tgoto=yes
7306 echo "$as_me: failed program was:" >&5
7307 cat "conftest.$ac_ext" >&5
7308 ac_cv_lib_mytinfo_tgoto=no
7310 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
7311 LIBS=$ac_check_lib_save_LIBS
7313 echo "$as_me:7313: result: $ac_cv_lib_mytinfo_tgoto" >&5
7314 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
7315 if test "$ac_cv_lib_mytinfo_tgoto" = yes; then
7320 for cf_add_1lib in -lmytinfo; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
7322 for cf_add_1lib in $cf_add_0lib; do
7323 for cf_add_2lib in $cf_add_libs; do
7324 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
7329 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
7337 # Looking at HPUX 10.20, the Hcurses library is the oldest (1997), cur_colr
7338 # next (1998), and xcurses "newer" (2000). There is no header file for
7339 # Hcurses; the subdirectory curses_colr has the headers (curses.h and
7340 # term.h) for cur_colr
7341 if test "x$cf_cv_screen" = "xcurses_colr"
7343 echo "$as_me:7343: checking for initscr in -lcur_colr" >&5
7344 echo $ECHO_N "checking for initscr in -lcur_colr... $ECHO_C" >&6
7345 if test "${ac_cv_lib_cur_colr_initscr+set}" = set; then
7346 echo $ECHO_N "(cached) $ECHO_C" >&6
7348 ac_check_lib_save_LIBS=$LIBS
7349 LIBS="-lcur_colr $LIBS"
7350 cat >"conftest.$ac_ext" <<_ACEOF
7351 #line 7351 "configure"
7352 #include "confdefs.h"
7354 /* Override any gcc2 internal prototype to avoid an error. */
7358 /* We use char because int might match the return type of a gcc2
7359 builtin and then its argument prototype would still apply. */
7360 char initscr (void);
7369 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
7370 if { (eval echo "$as_me:7370: \"$ac_link\"") >&5
7371 (eval $ac_link) 2>&5
7373 echo "$as_me:7373: \$? = $ac_status" >&5
7374 (exit "$ac_status"); } &&
7375 { ac_try='test -s "conftest$ac_exeext"'
7376 { (eval echo "$as_me:7376: \"$ac_try\"") >&5
7379 echo "$as_me:7379: \$? = $ac_status" >&5
7380 (exit "$ac_status"); }; }; then
7381 ac_cv_lib_cur_colr_initscr=yes
7383 echo "$as_me: failed program was:" >&5
7384 cat "conftest.$ac_ext" >&5
7385 ac_cv_lib_cur_colr_initscr=no
7387 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
7388 LIBS=$ac_check_lib_save_LIBS
7390 echo "$as_me:7390: result: $ac_cv_lib_cur_colr_initscr" >&5
7391 echo "${ECHO_T}$ac_cv_lib_cur_colr_initscr" >&6
7392 if test "$ac_cv_lib_cur_colr_initscr" = yes; then
7397 for cf_add_1lib in -lcur_colr; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
7399 for cf_add_1lib in $cf_add_0lib; do
7400 for cf_add_2lib in $cf_add_libs; do
7401 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
7406 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
7410 ac_cv_func_initscr=yes
7414 echo "$as_me:7414: checking for initscr in -lHcurses" >&5
7415 echo $ECHO_N "checking for initscr in -lHcurses... $ECHO_C" >&6
7416 if test "${ac_cv_lib_Hcurses_initscr+set}" = set; then
7417 echo $ECHO_N "(cached) $ECHO_C" >&6
7419 ac_check_lib_save_LIBS=$LIBS
7420 LIBS="-lHcurses $LIBS"
7421 cat >"conftest.$ac_ext" <<_ACEOF
7422 #line 7422 "configure"
7423 #include "confdefs.h"
7425 /* Override any gcc2 internal prototype to avoid an error. */
7429 /* We use char because int might match the return type of a gcc2
7430 builtin and then its argument prototype would still apply. */
7431 char initscr (void);
7440 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
7441 if { (eval echo "$as_me:7441: \"$ac_link\"") >&5
7442 (eval $ac_link) 2>&5
7444 echo "$as_me:7444: \$? = $ac_status" >&5
7445 (exit "$ac_status"); } &&
7446 { ac_try='test -s "conftest$ac_exeext"'
7447 { (eval echo "$as_me:7447: \"$ac_try\"") >&5
7450 echo "$as_me:7450: \$? = $ac_status" >&5
7451 (exit "$ac_status"); }; }; then
7452 ac_cv_lib_Hcurses_initscr=yes
7454 echo "$as_me: failed program was:" >&5
7455 cat "conftest.$ac_ext" >&5
7456 ac_cv_lib_Hcurses_initscr=no
7458 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
7459 LIBS=$ac_check_lib_save_LIBS
7461 echo "$as_me:7461: result: $ac_cv_lib_Hcurses_initscr" >&5
7462 echo "${ECHO_T}$ac_cv_lib_Hcurses_initscr" >&6
7463 if test "$ac_cv_lib_Hcurses_initscr" = yes; then
7465 # HP's header uses __HP_CURSES, but user claims _HP_CURSES.
7470 for cf_add_1lib in -lHcurses; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
7472 for cf_add_1lib in $cf_add_0lib; do
7473 for cf_add_2lib in $cf_add_libs; do
7474 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
7479 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
7483 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
7484 CPPFLAGS="${CPPFLAGS}-D__HP_CURSES -D_HP_CURSES"
7486 ac_cv_func_initscr=yes
7495 case `arch 2>/dev/null` in
7500 if test -n "/lib64" ; then
7501 for cf_add_libdir in /lib64
7503 if test "$cf_add_libdir" = /usr/lib ; then
7505 elif test -d "$cf_add_libdir"
7508 if test -n "$LDFLAGS$LIBS" ; then
7509 # a loop is needed to ensure we can add subdirs of existing dirs
7510 for cf_test_libdir in $LDFLAGS $LIBS ; do
7511 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
7512 cf_have_libdir=yes; break
7516 if test "$cf_have_libdir" = no ; then
7517 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
7519 echo "${as_me:-configure}:7519: testing adding $cf_add_libdir to library-path ..." 1>&5
7521 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
7529 if test -n "/lib" ; then
7530 for cf_add_libdir in /lib
7532 if test "$cf_add_libdir" = /usr/lib ; then
7534 elif test -d "$cf_add_libdir"
7537 if test -n "$LDFLAGS$LIBS" ; then
7538 # a loop is needed to ensure we can add subdirs of existing dirs
7539 for cf_test_libdir in $LDFLAGS $LIBS ; do
7540 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
7541 cf_have_libdir=yes; break
7545 if test "$cf_have_libdir" = no ; then
7546 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
7548 echo "${as_me:-configure}:7548: testing adding $cf_add_libdir to library-path ..." 1>&5
7550 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
7560 if test -n "/lib" ; then
7561 for cf_add_libdir in /lib
7563 if test "$cf_add_libdir" = /usr/lib ; then
7565 elif test -d "$cf_add_libdir"
7568 if test -n "$LDFLAGS$LIBS" ; then
7569 # a loop is needed to ensure we can add subdirs of existing dirs
7570 for cf_test_libdir in $LDFLAGS $LIBS ; do
7571 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
7572 cf_have_libdir=yes; break
7576 if test "$cf_have_libdir" = no ; then
7577 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
7579 echo "${as_me:-configure}:7579: testing adding $cf_add_libdir to library-path ..." 1>&5
7581 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
7591 if test "x$cf_cv_screen" = "xcurses_5lib"
7593 if test -d /usr/5lib ; then
7595 if test -n "/usr/5lib" ; then
7596 for cf_add_libdir in /usr/5lib
7598 if test "$cf_add_libdir" = /usr/lib ; then
7600 elif test -d "$cf_add_libdir"
7603 if test -n "$LDFLAGS$LIBS" ; then
7604 # a loop is needed to ensure we can add subdirs of existing dirs
7605 for cf_test_libdir in $LDFLAGS $LIBS ; do
7606 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
7607 cf_have_libdir=yes; break
7611 if test "$cf_have_libdir" = no ; then
7612 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
7614 echo "${as_me:-configure}:7614: testing adding $cf_add_libdir to library-path ..." 1>&5
7616 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
7625 for cf_add_1lib in -lcurses -ltermcap; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
7627 for cf_add_1lib in $cf_add_0lib; do
7628 for cf_add_2lib in $cf_add_libs; do
7629 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
7634 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
7640 ac_cv_func_initscr=yes
7644 if test ".$ac_cv_func_initscr" != .yes ; then
7645 cf_save_LIBS="$LIBS"
7647 if test ".${cf_cv_ncurses_version:-no}" != .no
7649 cf_check_list="ncurses curses cursesX"
7651 cf_check_list="cursesX curses ncurses"
7654 # Check for library containing tgoto. Do this before curses library
7655 # because it may be needed to link the test-case for initscr.
7656 if test "x$cf_term_lib" = x
7658 echo "$as_me:7658: checking for tgoto" >&5
7659 echo $ECHO_N "checking for tgoto... $ECHO_C" >&6
7660 if test "${ac_cv_func_tgoto+set}" = set; then
7661 echo $ECHO_N "(cached) $ECHO_C" >&6
7663 cat >"conftest.$ac_ext" <<_ACEOF
7664 #line 7664 "configure"
7665 #include "confdefs.h"
7666 #define tgoto autoconf_temporary
7667 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
7674 /* We use char because int might match the return type of a gcc2
7675 builtin and then its argument prototype would still apply. */
7682 /* The GNU C library defines stubs for functions which it implements
7683 to always fail with ENOSYS. Some functions are actually named
7684 something starting with __ and the normal name is an alias. */
7685 #if defined (__stub_tgoto) || defined (__stub___tgoto)
7686 #error found stub for tgoto
7694 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
7695 if { (eval echo "$as_me:7695: \"$ac_link\"") >&5
7696 (eval $ac_link) 2>&5
7698 echo "$as_me:7698: \$? = $ac_status" >&5
7699 (exit "$ac_status"); } &&
7700 { ac_try='test -s "conftest$ac_exeext"'
7701 { (eval echo "$as_me:7701: \"$ac_try\"") >&5
7704 echo "$as_me:7704: \$? = $ac_status" >&5
7705 (exit "$ac_status"); }; }; then
7706 ac_cv_func_tgoto=yes
7708 echo "$as_me: failed program was:" >&5
7709 cat "conftest.$ac_ext" >&5
7712 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
7714 echo "$as_me:7714: result: $ac_cv_func_tgoto" >&5
7715 echo "${ECHO_T}$ac_cv_func_tgoto" >&6
7716 if test "$ac_cv_func_tgoto" = yes; then
7717 cf_term_lib=predefined
7720 for cf_term_lib in $cf_check_list otermcap termcap tinfo termlib unknown
7722 as_ac_Lib=`echo "ac_cv_lib_$cf_term_lib''_tgoto" | $as_tr_sh`
7723 echo "$as_me:7723: checking for tgoto in -l$cf_term_lib" >&5
7724 echo $ECHO_N "checking for tgoto in -l$cf_term_lib... $ECHO_C" >&6
7725 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
7726 echo $ECHO_N "(cached) $ECHO_C" >&6
7728 ac_check_lib_save_LIBS=$LIBS
7729 LIBS="-l$cf_term_lib $LIBS"
7730 cat >"conftest.$ac_ext" <<_ACEOF
7731 #line 7731 "configure"
7732 #include "confdefs.h"
7734 /* Override any gcc2 internal prototype to avoid an error. */
7738 /* We use char because int might match the return type of a gcc2
7739 builtin and then its argument prototype would still apply. */
7749 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
7750 if { (eval echo "$as_me:7750: \"$ac_link\"") >&5
7751 (eval $ac_link) 2>&5
7753 echo "$as_me:7753: \$? = $ac_status" >&5
7754 (exit "$ac_status"); } &&
7755 { ac_try='test -s "conftest$ac_exeext"'
7756 { (eval echo "$as_me:7756: \"$ac_try\"") >&5
7759 echo "$as_me:7759: \$? = $ac_status" >&5
7760 (exit "$ac_status"); }; }; then
7761 eval "$as_ac_Lib=yes"
7763 echo "$as_me: failed program was:" >&5
7764 cat "conftest.$ac_ext" >&5
7765 eval "$as_ac_Lib=no"
7767 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
7768 LIBS=$ac_check_lib_save_LIBS
7770 echo "$as_me:7770: result: `eval echo '${'"$as_ac_Lib"'}'`" >&5
7771 echo "${ECHO_T}`eval echo '${'"$as_ac_Lib"'}'`" >&6
7772 if test "`eval echo '${'"$as_ac_Lib"'}'`" = yes; then
7774 : "${cf_nculib_root:=$cf_term_lib}"
7785 # Check for library containing initscr
7786 test "$cf_term_lib" != predefined && test "$cf_term_lib" != unknown && LIBS="-l$cf_term_lib $cf_save_LIBS"
7787 if test "x$cf_curs_lib" = x
7789 for cf_curs_lib in $cf_check_list xcurses jcurses pdcurses unknown
7791 LIBS="-l$cf_curs_lib $cf_save_LIBS"
7792 if test "$cf_term_lib" = unknown || test "$cf_term_lib" = "$cf_curs_lib" ; then
7793 echo "$as_me:7793: checking if we can link with $cf_curs_lib library" >&5
7794 echo $ECHO_N "checking if we can link with $cf_curs_lib library... $ECHO_C" >&6
7795 cat >"conftest.$ac_ext" <<_ACEOF
7796 #line 7796 "configure"
7797 #include "confdefs.h"
7798 #include <${cf_cv_ncurses_header:-curses.h}>
7807 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
7808 if { (eval echo "$as_me:7808: \"$ac_link\"") >&5
7809 (eval $ac_link) 2>&5
7811 echo "$as_me:7811: \$? = $ac_status" >&5
7812 (exit "$ac_status"); } &&
7813 { ac_try='test -s "conftest$ac_exeext"'
7814 { (eval echo "$as_me:7814: \"$ac_try\"") >&5
7817 echo "$as_me:7817: \$? = $ac_status" >&5
7818 (exit "$ac_status"); }; }; then
7821 echo "$as_me: failed program was:" >&5
7822 cat "conftest.$ac_ext" >&5
7825 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
7826 echo "$as_me:7826: result: $cf_result" >&5
7827 echo "${ECHO_T}$cf_result" >&6
7828 test "$cf_result" = yes && break
7829 elif test "$cf_curs_lib" = "$cf_term_lib" ; then
7831 elif test "$cf_term_lib" != predefined ; then
7832 echo "$as_me:7832: checking if we need both $cf_curs_lib and $cf_term_lib libraries" >&5
7833 echo $ECHO_N "checking if we need both $cf_curs_lib and $cf_term_lib libraries... $ECHO_C" >&6
7834 cat >"conftest.$ac_ext" <<_ACEOF
7835 #line 7835 "configure"
7836 #include "confdefs.h"
7837 #include <${cf_cv_ncurses_header:-curses.h}>
7841 initscr(); endwin();
7846 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
7847 if { (eval echo "$as_me:7847: \"$ac_link\"") >&5
7848 (eval $ac_link) 2>&5
7850 echo "$as_me:7850: \$? = $ac_status" >&5
7851 (exit "$ac_status"); } &&
7852 { ac_try='test -s "conftest$ac_exeext"'
7853 { (eval echo "$as_me:7853: \"$ac_try\"") >&5
7856 echo "$as_me:7856: \$? = $ac_status" >&5
7857 (exit "$ac_status"); }; }; then
7860 echo "$as_me: failed program was:" >&5
7861 cat "conftest.$ac_ext" >&5
7863 LIBS="-l$cf_curs_lib -l$cf_term_lib $cf_save_LIBS"
7864 cat >"conftest.$ac_ext" <<_ACEOF
7865 #line 7865 "configure"
7866 #include "confdefs.h"
7867 #include <${cf_cv_ncurses_header:-curses.h}>
7876 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
7877 if { (eval echo "$as_me:7877: \"$ac_link\"") >&5
7878 (eval $ac_link) 2>&5
7880 echo "$as_me:7880: \$? = $ac_status" >&5
7881 (exit "$ac_status"); } &&
7882 { ac_try='test -s "conftest$ac_exeext"'
7883 { (eval echo "$as_me:7883: \"$ac_try\"") >&5
7886 echo "$as_me:7886: \$? = $ac_status" >&5
7887 (exit "$ac_status"); }; }; then
7890 echo "$as_me: failed program was:" >&5
7891 cat "conftest.$ac_ext" >&5
7894 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
7897 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
7898 echo "$as_me:7898: result: $cf_result" >&5
7899 echo "${ECHO_T}$cf_result" >&6
7900 test "$cf_result" != error && break
7904 test "$cf_curs_lib" = unknown && { { echo "$as_me:7904: error: no curses library found" >&5
7905 echo "$as_me: error: no curses library found" >&2;}
7906 { (exit 1); exit 1; }; }
7913 for ac_header in wchar.h
7915 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7916 echo "$as_me:7916: checking for $ac_header" >&5
7917 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7918 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7919 echo $ECHO_N "(cached) $ECHO_C" >&6
7921 cat >"conftest.$ac_ext" <<_ACEOF
7922 #line 7922 "configure"
7923 #include "confdefs.h"
7924 #include <$ac_header>
7926 if { (eval echo "$as_me:7926: \"$ac_cpp "conftest.$ac_ext"\"") >&5
7927 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
7929 $EGREP -v '^ *\+' conftest.er1 >conftest.err
7931 cat conftest.err >&5
7932 echo "$as_me:7932: \$? = $ac_status" >&5
7933 (exit "$ac_status"); } >/dev/null; then
7934 if test -s conftest.err; then
7935 ac_cpp_err=$ac_c_preproc_warn_flag
7942 if test -z "$ac_cpp_err"; then
7943 eval "$as_ac_Header=yes"
7945 echo "$as_me: failed program was:" >&5
7946 cat "conftest.$ac_ext" >&5
7947 eval "$as_ac_Header=no"
7949 rm -f conftest.err "conftest.$ac_ext"
7951 echo "$as_me:7951: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
7952 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
7953 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
7954 cat >>confdefs.h <<EOF
7955 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7961 echo "$as_me:7961: checking for multibyte character support" >&5
7962 echo $ECHO_N "checking for multibyte character support... $ECHO_C" >&6
7963 if test "${cf_cv_utf8_lib+set}" = set; then
7964 echo $ECHO_N "(cached) $ECHO_C" >&6
7967 cf_save_LIBS="$LIBS"
7968 cat >"conftest.$ac_ext" <<_ACEOF
7969 #line 7969 "configure"
7970 #include "confdefs.h"
7972 $ac_includes_default
7985 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
7986 if { (eval echo "$as_me:7986: \"$ac_link\"") >&5
7987 (eval $ac_link) 2>&5
7989 echo "$as_me:7989: \$? = $ac_status" >&5
7990 (exit "$ac_status"); } &&
7991 { ac_try='test -s "conftest$ac_exeext"'
7992 { (eval echo "$as_me:7992: \"$ac_try\"") >&5
7995 echo "$as_me:7995: \$? = $ac_status" >&5
7996 (exit "$ac_status"); }; }; then
7999 echo "$as_me: failed program was:" >&5
8000 cat "conftest.$ac_ext" >&5
8002 # If the linkage is not already in the $CPPFLAGS/$LDFLAGS configuration, these
8003 # will be set on completion of the AC_TRY_LINK below.
8004 cf_cv_header_path_utf8=
8005 cf_cv_library_path_utf8=
8007 echo "${as_me:-configure}:8007: testing Starting FIND_LINKAGE(utf8,) ..." 1>&5
8009 cf_save_LIBS="$LIBS"
8011 cat >"conftest.$ac_ext" <<_ACEOF
8012 #line 8012 "configure"
8013 #include "confdefs.h"
8015 #include <libutf8.h>
8024 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
8025 if { (eval echo "$as_me:8025: \"$ac_link\"") >&5
8026 (eval $ac_link) 2>&5
8028 echo "$as_me:8028: \$? = $ac_status" >&5
8029 (exit "$ac_status"); } &&
8030 { ac_try='test -s "conftest$ac_exeext"'
8031 { (eval echo "$as_me:8031: \"$ac_try\"") >&5
8034 echo "$as_me:8034: \$? = $ac_status" >&5
8035 (exit "$ac_status"); }; }; then
8037 cf_cv_find_linkage_utf8=yes
8038 cf_cv_header_path_utf8=/usr/include
8039 cf_cv_library_path_utf8=/usr/lib
8042 echo "$as_me: failed program was:" >&5
8043 cat "conftest.$ac_ext" >&5
8045 LIBS="-lutf8 $cf_save_LIBS"
8047 cat >"conftest.$ac_ext" <<_ACEOF
8048 #line 8048 "configure"
8049 #include "confdefs.h"
8051 #include <libutf8.h>
8060 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
8061 if { (eval echo "$as_me:8061: \"$ac_link\"") >&5
8062 (eval $ac_link) 2>&5
8064 echo "$as_me:8064: \$? = $ac_status" >&5
8065 (exit "$ac_status"); } &&
8066 { ac_try='test -s "conftest$ac_exeext"'
8067 { (eval echo "$as_me:8067: \"$ac_try\"") >&5
8070 echo "$as_me:8070: \$? = $ac_status" >&5
8071 (exit "$ac_status"); }; }; then
8073 cf_cv_find_linkage_utf8=yes
8074 cf_cv_header_path_utf8=/usr/include
8075 cf_cv_library_path_utf8=/usr/lib
8076 cf_cv_library_file_utf8="-lutf8"
8079 echo "$as_me: failed program was:" >&5
8080 cat "conftest.$ac_ext" >&5
8082 cf_cv_find_linkage_utf8=no
8083 LIBS="$cf_save_LIBS"
8085 test -n "$verbose" && echo " find linkage for utf8 library" 1>&6
8087 echo "${as_me:-configure}:8087: testing find linkage for utf8 library ..." 1>&5
8089 echo "${as_me:-configure}:8089: testing Searching for headers in FIND_LINKAGE(utf8,) ..." 1>&5
8091 cf_save_CPPFLAGS="$CPPFLAGS"
8092 cf_test_CPPFLAGS="$CPPFLAGS"
8096 # collect the current set of include-directories from compiler flags
8097 cf_header_path_list=""
8098 if test -n "${CFLAGS}${CPPFLAGS}" ; then
8099 for cf_header_path in $CPPFLAGS $CFLAGS
8101 case "$cf_header_path" in
8103 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
8105 test "x$cf_header_path" != "xNONE" && \
8106 test -d "$cf_header_path" && \
8108 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
8109 test -d "$cf_header_path/include" && cf_search="$cf_search $cf_header_path/include"
8110 test -d "$cf_header_path/include/utf8" && cf_search="$cf_search $cf_header_path/include/utf8"
8111 test -d "$cf_header_path/include/utf8/include" && cf_search="$cf_search $cf_header_path/include/utf8/include"
8112 test -d "$cf_header_path/utf8/include" && cf_search="$cf_search $cf_header_path/utf8/include"
8113 test -d "$cf_header_path/utf8/include/utf8" && cf_search="$cf_search $cf_header_path/utf8/include/utf8"
8116 cf_header_path_list="$cf_header_path_list $cf_search"
8122 # add the variations for the package we are looking for
8126 test "x$prefix" != "xNONE" && \
8127 test -d "$prefix" && \
8129 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
8130 test -d "$prefix/include" && cf_search="$cf_search $prefix/include"
8131 test -d "$prefix/include/utf8" && cf_search="$cf_search $prefix/include/utf8"
8132 test -d "$prefix/include/utf8/include" && cf_search="$cf_search $prefix/include/utf8/include"
8133 test -d "$prefix/utf8/include" && cf_search="$cf_search $prefix/utf8/include"
8134 test -d "$prefix/utf8/include/utf8" && cf_search="$cf_search $prefix/utf8/include/utf8"
8137 for cf_subdir_prefix in \
8146 test "x$cf_subdir_prefix" != "x$prefix" && \
8147 test -d "$cf_subdir_prefix" && \
8148 { test -z "$prefix" || test "x$prefix" = xNONE || test "x$cf_subdir_prefix" != "x$prefix"; } && {
8149 test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
8150 test -d "$cf_subdir_prefix/include" && cf_search="$cf_search $cf_subdir_prefix/include"
8151 test -d "$cf_subdir_prefix/include/utf8" && cf_search="$cf_search $cf_subdir_prefix/include/utf8"
8152 test -d "$cf_subdir_prefix/include/utf8/include" && cf_search="$cf_search $cf_subdir_prefix/include/utf8/include"
8153 test -d "$cf_subdir_prefix/utf8/include" && cf_search="$cf_search $cf_subdir_prefix/utf8/include"
8154 test -d "$cf_subdir_prefix/utf8/include/utf8" && cf_search="$cf_search $cf_subdir_prefix/utf8/include/utf8"
8159 test "$includedir" != NONE && \
8160 test "$includedir" != "/usr/include" && \
8161 test -d "$includedir" && {
8162 test -d "$includedir" && cf_search="$cf_search $includedir"
8163 test -d "$includedir/utf8" && cf_search="$cf_search $includedir/utf8"
8166 test "$oldincludedir" != NONE && \
8167 test "$oldincludedir" != "/usr/include" && \
8168 test -d "$oldincludedir" && {
8169 test -d "$oldincludedir" && cf_search="$cf_search $oldincludedir"
8170 test -d "$oldincludedir/utf8" && cf_search="$cf_search $oldincludedir/utf8"
8173 cf_search="$cf_search $cf_header_path_list"
8175 for cf_cv_header_path_utf8 in $cf_search
8177 if test -d "$cf_cv_header_path_utf8" ; then
8178 test -n "$verbose" && echo " ... testing $cf_cv_header_path_utf8" 1>&6
8180 echo "${as_me:-configure}:8180: testing ... testing $cf_cv_header_path_utf8 ..." 1>&5
8182 CPPFLAGS="$cf_save_CPPFLAGS"
8184 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
8185 CPPFLAGS="${CPPFLAGS}-I$cf_cv_header_path_utf8"
8187 cat >"conftest.$ac_ext" <<_ACEOF
8188 #line 8188 "configure"
8189 #include "confdefs.h"
8191 #include <libutf8.h>
8200 rm -f "conftest.$ac_objext"
8201 if { (eval echo "$as_me:8201: \"$ac_compile\"") >&5
8202 (eval $ac_compile) 2>&5
8204 echo "$as_me:8204: \$? = $ac_status" >&5
8205 (exit "$ac_status"); } &&
8206 { ac_try='test -s "conftest.$ac_objext"'
8207 { (eval echo "$as_me:8207: \"$ac_try\"") >&5
8210 echo "$as_me:8210: \$? = $ac_status" >&5
8211 (exit "$ac_status"); }; }; then
8213 test -n "$verbose" && echo " ... found utf8 headers in $cf_cv_header_path_utf8" 1>&6
8215 echo "${as_me:-configure}:8215: testing ... found utf8 headers in $cf_cv_header_path_utf8 ..." 1>&5
8217 cf_cv_find_linkage_utf8=maybe
8218 cf_test_CPPFLAGS="$CPPFLAGS"
8221 echo "$as_me: failed program was:" >&5
8222 cat "conftest.$ac_ext" >&5
8224 CPPFLAGS="$cf_save_CPPFLAGS"
8227 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
8231 if test "$cf_cv_find_linkage_utf8" = maybe ; then
8233 echo "${as_me:-configure}:8233: testing Searching for utf8 library in FIND_LINKAGE(utf8,) ..." 1>&5
8235 cf_save_LIBS="$LIBS"
8236 cf_save_LDFLAGS="$LDFLAGS"
8238 if test "$cf_cv_find_linkage_utf8" != yes ; then
8241 cf_library_path_list=""
8242 if test -n "${LDFLAGS}${LIBS}" ; then
8243 for cf_library_path in $LDFLAGS $LIBS
8245 case "$cf_library_path" in
8247 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
8249 test "x$cf_library_path" != "xNONE" && \
8250 test -d "$cf_library_path" && \
8252 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
8253 test -d "$cf_library_path/lib" && cf_search="$cf_search $cf_library_path/lib"
8254 test -d "$cf_library_path/lib/utf8" && cf_search="$cf_search $cf_library_path/lib/utf8"
8255 test -d "$cf_library_path/lib/utf8/lib" && cf_search="$cf_search $cf_library_path/lib/utf8/lib"
8256 test -d "$cf_library_path/utf8/lib" && cf_search="$cf_search $cf_library_path/utf8/lib"
8257 test -d "$cf_library_path/utf8/lib/utf8" && cf_search="$cf_search $cf_library_path/utf8/lib/utf8"
8260 cf_library_path_list="$cf_library_path_list $cf_search"
8268 test "x$prefix" != "xNONE" && \
8269 test -d "$prefix" && \
8271 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
8272 test -d "$prefix/lib" && cf_search="$cf_search $prefix/lib"
8273 test -d "$prefix/lib/utf8" && cf_search="$cf_search $prefix/lib/utf8"
8274 test -d "$prefix/lib/utf8/lib" && cf_search="$cf_search $prefix/lib/utf8/lib"
8275 test -d "$prefix/utf8/lib" && cf_search="$cf_search $prefix/utf8/lib"
8276 test -d "$prefix/utf8/lib/utf8" && cf_search="$cf_search $prefix/utf8/lib/utf8"
8279 for cf_subdir_prefix in \
8288 test "x$cf_subdir_prefix" != "x$prefix" && \
8289 test -d "$cf_subdir_prefix" && \
8290 { test -z "$prefix" || test "x$prefix" = xNONE || test "x$cf_subdir_prefix" != "x$prefix"; } && {
8291 test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
8292 test -d "$cf_subdir_prefix/lib" && cf_search="$cf_search $cf_subdir_prefix/lib"
8293 test -d "$cf_subdir_prefix/lib/utf8" && cf_search="$cf_search $cf_subdir_prefix/lib/utf8"
8294 test -d "$cf_subdir_prefix/lib/utf8/lib" && cf_search="$cf_search $cf_subdir_prefix/lib/utf8/lib"
8295 test -d "$cf_subdir_prefix/utf8/lib" && cf_search="$cf_search $cf_subdir_prefix/utf8/lib"
8296 test -d "$cf_subdir_prefix/utf8/lib/utf8" && cf_search="$cf_search $cf_subdir_prefix/utf8/lib/utf8"
8301 cf_search="$cf_library_path_list $cf_search"
8303 for cf_cv_library_path_utf8 in $cf_search
8305 if test -d "$cf_cv_library_path_utf8" ; then
8306 test -n "$verbose" && echo " ... testing $cf_cv_library_path_utf8" 1>&6
8308 echo "${as_me:-configure}:8308: testing ... testing $cf_cv_library_path_utf8 ..." 1>&5
8310 CPPFLAGS="$cf_test_CPPFLAGS"
8311 LIBS="-lutf8 $cf_save_LIBS"
8312 LDFLAGS="$cf_save_LDFLAGS -L$cf_cv_library_path_utf8"
8313 cat >"conftest.$ac_ext" <<_ACEOF
8314 #line 8314 "configure"
8315 #include "confdefs.h"
8317 #include <libutf8.h>
8326 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
8327 if { (eval echo "$as_me:8327: \"$ac_link\"") >&5
8328 (eval $ac_link) 2>&5
8330 echo "$as_me:8330: \$? = $ac_status" >&5
8331 (exit "$ac_status"); } &&
8332 { ac_try='test -s "conftest$ac_exeext"'
8333 { (eval echo "$as_me:8333: \"$ac_try\"") >&5
8336 echo "$as_me:8336: \$? = $ac_status" >&5
8337 (exit "$ac_status"); }; }; then
8339 test -n "$verbose" && echo " ... found utf8 library in $cf_cv_library_path_utf8" 1>&6
8341 echo "${as_me:-configure}:8341: testing ... found utf8 library in $cf_cv_library_path_utf8 ..." 1>&5
8343 cf_cv_find_linkage_utf8=yes
8344 cf_cv_library_file_utf8="-lutf8"
8347 echo "$as_me: failed program was:" >&5
8348 cat "conftest.$ac_ext" >&5
8350 CPPFLAGS="$cf_save_CPPFLAGS"
8351 LIBS="$cf_save_LIBS"
8352 LDFLAGS="$cf_save_LDFLAGS"
8355 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
8358 CPPFLAGS="$cf_save_CPPFLAGS"
8359 LDFLAGS="$cf_save_LDFLAGS"
8363 cf_cv_find_linkage_utf8=no
8367 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
8370 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
8372 LIBS="$cf_save_LIBS"
8374 if test "$cf_cv_find_linkage_utf8" = yes ; then
8375 cf_cv_utf8_lib=add-on
8381 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
8383 echo "$as_me:8383: result: $cf_cv_utf8_lib" >&5
8384 echo "${ECHO_T}$cf_cv_utf8_lib" >&6
8386 # HAVE_LIBUTF8_H is used by ncurses if curses.h is shared between
8388 if test "$cf_cv_utf8_lib" = "add-on" ; then
8390 cat >>confdefs.h <<\EOF
8391 #define HAVE_LIBUTF8_H 1
8394 if test -n "$cf_cv_header_path_utf8" ; then
8395 for cf_add_incdir in $cf_cv_header_path_utf8
8397 while test "$cf_add_incdir" != /usr/include
8399 if test -d "$cf_add_incdir"
8402 if test -n "$CFLAGS$CPPFLAGS" ; then
8403 # a loop is needed to ensure we can add subdirs of existing dirs
8404 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
8405 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
8406 cf_have_incdir=yes; break
8411 if test "$cf_have_incdir" = no ; then
8412 if test "$cf_add_incdir" = /usr/local/include ; then
8413 if test "$GCC" = yes
8415 cf_save_CPPFLAGS=$CPPFLAGS
8417 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
8418 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
8420 cat >"conftest.$ac_ext" <<_ACEOF
8421 #line 8421 "configure"
8422 #include "confdefs.h"
8432 rm -f "conftest.$ac_objext"
8433 if { (eval echo "$as_me:8433: \"$ac_compile\"") >&5
8434 (eval $ac_compile) 2>&5
8436 echo "$as_me:8436: \$? = $ac_status" >&5
8437 (exit "$ac_status"); } &&
8438 { ac_try='test -s "conftest.$ac_objext"'
8439 { (eval echo "$as_me:8439: \"$ac_try\"") >&5
8442 echo "$as_me:8442: \$? = $ac_status" >&5
8443 (exit "$ac_status"); }; }; then
8446 echo "$as_me: failed program was:" >&5
8447 cat "conftest.$ac_ext" >&5
8450 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
8451 CPPFLAGS=$cf_save_CPPFLAGS
8456 if test "$cf_have_incdir" = no ; then
8457 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
8459 echo "${as_me:-configure}:8459: testing adding $cf_add_incdir to include-path ..." 1>&5
8461 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8463 cf_top_incdir=`echo "$cf_add_incdir" | sed -e 's%/include/.*$%/include%'`
8464 test "$cf_top_incdir" = "$cf_add_incdir" && break
8465 cf_add_incdir="$cf_top_incdir"
8476 if test -n "$cf_cv_library_path_utf8" ; then
8477 for cf_add_libdir in $cf_cv_library_path_utf8
8479 if test "$cf_add_libdir" = /usr/lib ; then
8481 elif test -d "$cf_add_libdir"
8484 if test -n "$LDFLAGS$LIBS" ; then
8485 # a loop is needed to ensure we can add subdirs of existing dirs
8486 for cf_test_libdir in $LDFLAGS $LIBS ; do
8487 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
8488 cf_have_libdir=yes; break
8492 if test "$cf_have_libdir" = no ; then
8493 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
8495 echo "${as_me:-configure}:8495: testing adding $cf_add_libdir to library-path ..." 1>&5
8497 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
8506 for cf_add_1lib in $cf_cv_library_file_utf8; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
8508 for cf_add_1lib in $cf_add_0lib; do
8509 for cf_add_2lib in $cf_add_libs; do
8510 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
8515 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
8521 cf_ncuconfig_root=$cf_cv_screen
8522 cf_have_ncuconfig=no
8524 if test "x${PKG_CONFIG:=none}" != xnone; then
8525 echo "$as_me:8525: checking pkg-config for $cf_ncuconfig_root" >&5
8526 echo $ECHO_N "checking pkg-config for $cf_ncuconfig_root... $ECHO_C" >&6
8527 if "$PKG_CONFIG" --exists $cf_ncuconfig_root ; then
8528 echo "$as_me:8528: result: yes" >&5
8529 echo "${ECHO_T}yes" >&6
8531 echo "$as_me:8531: checking if the $cf_ncuconfig_root package files work" >&5
8532 echo $ECHO_N "checking if the $cf_ncuconfig_root package files work... $ECHO_C" >&6
8533 cf_have_ncuconfig=unknown
8535 cf_save_CFLAGS="$CFLAGS"
8536 cf_save_CPPFLAGS="$CPPFLAGS"
8537 cf_save_LIBS="$LIBS"
8539 cf_pkg_cflags="`$PKG_CONFIG --cflags $cf_ncuconfig_root`"
8540 cf_pkg_libs="`$PKG_CONFIG --libs $cf_ncuconfig_root`"
8542 # while -W for passing linker flags is prevalent, it is not "standard".
8543 # At least one wrapper for c89/c99 (in Apple's xcode) has its own
8544 # incompatible _and_ non-standard -W option which gives an error. Work
8545 # around that pitfall.
8546 case "x${CC}@@${cf_pkg_libs}@${cf_pkg_cflags}" in
8552 cf_new_extra_cppflags=
8554 for cf_add_cflags in $cf_pkg_cflags
8556 case "$cf_fix_cppflags" in
8558 case "$cf_add_cflags" in
8559 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
8560 case "$cf_add_cflags" in
8562 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
8564 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
8565 && test -z "${cf_tst_cflags}" \
8566 && cf_fix_cppflags=yes
8568 if test "$cf_fix_cppflags" = yes ; then
8570 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
8571 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
8574 elif test "${cf_tst_cflags}" = "\"'" ; then
8576 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
8577 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
8587 case "$cf_add_cflags" in
8589 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
8591 CPPFLAGS=`echo "$CPPFLAGS" | \
8592 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
8593 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
8598 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
8599 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
8606 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
8607 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
8614 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
8615 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
8617 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
8619 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
8620 && test -z "${cf_tst_cflags}" \
8621 && cf_fix_cppflags=no
8626 if test -n "$cf_new_cflags" ; then
8628 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
8629 CFLAGS="${CFLAGS}$cf_new_cflags"
8633 if test -n "$cf_new_cppflags" ; then
8635 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
8636 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
8640 if test -n "$cf_new_extra_cppflags" ; then
8642 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
8643 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
8650 for cf_add_1lib in $cf_pkg_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
8652 for cf_add_1lib in $cf_add_0lib; do
8653 for cf_add_2lib in $cf_add_libs; do
8654 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
8659 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
8663 cat >"conftest.$ac_ext" <<_ACEOF
8664 #line 8664 "configure"
8665 #include "confdefs.h"
8666 #include <${cf_cv_ncurses_header:-curses.h}>
8670 initscr(); mousemask(0,0); tigetstr((char *)0);
8675 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
8676 if { (eval echo "$as_me:8676: \"$ac_link\"") >&5
8677 (eval $ac_link) 2>&5
8679 echo "$as_me:8679: \$? = $ac_status" >&5
8680 (exit "$ac_status"); } &&
8681 { ac_try='test -s "conftest$ac_exeext"'
8682 { (eval echo "$as_me:8682: \"$ac_try\"") >&5
8685 echo "$as_me:8685: \$? = $ac_status" >&5
8686 (exit "$ac_status"); }; }; then
8687 if test "$cross_compiling" = yes; then
8688 cf_test_ncuconfig=maybe
8690 cat >"conftest.$ac_ext" <<_ACEOF
8691 #line 8691 "configure"
8692 #include "confdefs.h"
8693 #include <${cf_cv_ncurses_header:-curses.h}>
8695 { const char *xx = curses_version(); return (xx == 0); }
8697 rm -f "conftest$ac_exeext"
8698 if { (eval echo "$as_me:8698: \"$ac_link\"") >&5
8699 (eval $ac_link) 2>&5
8701 echo "$as_me:8701: \$? = $ac_status" >&5
8702 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
8703 { (eval echo "$as_me:8703: \"$ac_try\"") >&5
8706 echo "$as_me:8706: \$? = $ac_status" >&5
8707 (exit "$ac_status"); }; }; then
8708 cf_test_ncuconfig=yes
8710 echo "$as_me: program exited with status $ac_status" >&5
8711 echo "$as_me: failed program was:" >&5
8712 cat "conftest.$ac_ext" >&5
8713 cf_test_ncuconfig=no
8715 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
8718 echo "$as_me: failed program was:" >&5
8719 cat "conftest.$ac_ext" >&5
8720 cf_test_ncuconfig=no
8722 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
8724 CFLAGS="$cf_save_CFLAGS"
8725 CPPFLAGS="$cf_save_CPPFLAGS"
8726 LIBS="$cf_save_LIBS"
8728 if test "x$cf_test_ncuconfig" != xyes; then
8729 cf_temp=`echo "x$cf_pkg_cflags" | sed -e s/^x// -e 's/-W[^ ]*//g'`
8730 cf_pkg_cflags="$cf_temp"
8731 cf_temp=`echo "x$cf_pkg_libs" | sed -e s/^x// -e 's/-W[^ ]*//g'`
8732 cf_pkg_libs="$cf_temp"
8737 for cf_add_cflags in $cf_pkg_cflags
8739 case "x$cf_add_cflags" in
8742 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
8745 cf_old_cflag=`echo "x$CFLAGS" | sed -e 's/^.//' -e 's/[ ][ ]*-/ -/g' -e "s%$cf_tmp_cflag\\(=[^ ][^ ]*\\)\?%%" -e 's/^[ ]*//' -e 's%[ ][ ]*-D% -D%g' -e 's%[ ][ ]*-I% -I%g'`
8746 test "$CFLAGS" != "$cf_old_cflag" || break
8748 CFLAGS="$cf_old_cflag"
8751 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
8754 cf_old_cflag=`echo "x$CPPFLAGS" | sed -e 's/^.//' -e 's/[ ][ ]*-/ -/g' -e "s%$cf_tmp_cflag\\(=[^ ][^ ]*\\)\?%%" -e 's/^[ ]*//' -e 's%[ ][ ]*-D% -D%g' -e 's%[ ][ ]*-I% -I%g'`
8755 test "$CPPFLAGS" != "$cf_old_cflag" || break
8757 CPPFLAGS="$cf_old_cflag"
8766 cf_new_extra_cppflags=
8768 for cf_add_cflags in $cf_add_cflags
8770 case "$cf_fix_cppflags" in
8772 case "$cf_add_cflags" in
8773 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
8774 case "$cf_add_cflags" in
8776 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
8778 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
8779 && test -z "${cf_tst_cflags}" \
8780 && cf_fix_cppflags=yes
8782 if test "$cf_fix_cppflags" = yes ; then
8784 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
8785 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
8788 elif test "${cf_tst_cflags}" = "\"'" ; then
8790 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
8791 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
8801 case "$cf_add_cflags" in
8803 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
8805 CPPFLAGS=`echo "$CPPFLAGS" | \
8806 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
8807 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
8812 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
8813 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
8820 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
8821 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
8828 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
8829 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
8831 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
8833 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
8834 && test -z "${cf_tst_cflags}" \
8835 && cf_fix_cppflags=no
8840 if test -n "$cf_new_cflags" ; then
8842 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
8843 CFLAGS="${CFLAGS}$cf_new_cflags"
8847 if test -n "$cf_new_cppflags" ; then
8849 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
8850 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
8854 if test -n "$cf_new_extra_cppflags" ; then
8856 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
8857 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
8866 for cf_add_1lib in $cf_pkg_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
8868 for cf_add_1lib in $cf_add_0lib; do
8869 for cf_add_2lib in $cf_add_libs; do
8870 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
8875 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
8879 cat >"conftest.$ac_ext" <<_ACEOF
8880 #line 8880 "configure"
8881 #include "confdefs.h"
8882 #include <${cf_cv_ncurses_header:-curses.h}>
8886 initscr(); mousemask(0,0); tigetstr((char *)0);
8891 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
8892 if { (eval echo "$as_me:8892: \"$ac_link\"") >&5
8893 (eval $ac_link) 2>&5
8895 echo "$as_me:8895: \$? = $ac_status" >&5
8896 (exit "$ac_status"); } &&
8897 { ac_try='test -s "conftest$ac_exeext"'
8898 { (eval echo "$as_me:8898: \"$ac_try\"") >&5
8901 echo "$as_me:8901: \$? = $ac_status" >&5
8902 (exit "$ac_status"); }; }; then
8903 if test "$cross_compiling" = yes; then
8904 cf_have_ncuconfig=maybe
8906 cat >"conftest.$ac_ext" <<_ACEOF
8907 #line 8907 "configure"
8908 #include "confdefs.h"
8909 #include <${cf_cv_ncurses_header:-curses.h}>
8911 { const char *xx = curses_version(); return (xx == 0); }
8913 rm -f "conftest$ac_exeext"
8914 if { (eval echo "$as_me:8914: \"$ac_link\"") >&5
8915 (eval $ac_link) 2>&5
8917 echo "$as_me:8917: \$? = $ac_status" >&5
8918 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
8919 { (eval echo "$as_me:8919: \"$ac_try\"") >&5
8922 echo "$as_me:8922: \$? = $ac_status" >&5
8923 (exit "$ac_status"); }; }; then
8924 cf_have_ncuconfig=yes
8926 echo "$as_me: program exited with status $ac_status" >&5
8927 echo "$as_me: failed program was:" >&5
8928 cat "conftest.$ac_ext" >&5
8929 cf_have_ncuconfig=no
8931 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
8934 echo "$as_me: failed program was:" >&5
8935 cat "conftest.$ac_ext" >&5
8936 cf_have_ncuconfig=no
8938 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
8939 echo "$as_me:8939: result: $cf_have_ncuconfig" >&5
8940 echo "${ECHO_T}$cf_have_ncuconfig" >&6
8941 test "$cf_have_ncuconfig" = maybe && cf_have_ncuconfig=yes
8942 if test "$cf_have_ncuconfig" != "yes"
8944 CPPFLAGS="$cf_save_CPPFLAGS"
8945 LIBS="$cf_save_LIBS"
8946 NCURSES_CONFIG_PKG=none
8949 cat >>confdefs.h <<\EOF
8953 NCURSES_CONFIG_PKG=$cf_ncuconfig_root
8955 echo "$as_me:8955: checking for terminfo header" >&5
8956 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
8957 if test "${cf_cv_term_header+set}" = set; then
8958 echo $ECHO_N "(cached) $ECHO_C" >&6
8961 case "${cf_cv_ncurses_header}" in
8962 (*/ncurses.h|*/ncursesw.h)
8963 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
8966 cf_term_header=term.h
8970 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
8972 cat >"conftest.$ac_ext" <<_ACEOF
8973 #line 8973 "configure"
8974 #include "confdefs.h"
8976 #include <${cf_cv_ncurses_header:-curses.h}>
8982 int x = auto_left_margin; (void)x
8987 rm -f "conftest.$ac_objext"
8988 if { (eval echo "$as_me:8988: \"$ac_compile\"") >&5
8989 (eval $ac_compile) 2>&5
8991 echo "$as_me:8991: \$? = $ac_status" >&5
8992 (exit "$ac_status"); } &&
8993 { ac_try='test -s "conftest.$ac_objext"'
8994 { (eval echo "$as_me:8994: \"$ac_try\"") >&5
8997 echo "$as_me:8997: \$? = $ac_status" >&5
8998 (exit "$ac_status"); }; }; then
9000 cf_cv_term_header="$cf_test"
9002 echo "$as_me: failed program was:" >&5
9003 cat "conftest.$ac_ext" >&5
9005 cf_cv_term_header=unknown
9008 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
9009 test "$cf_cv_term_header" != unknown && break
9013 echo "$as_me:9013: result: $cf_cv_term_header" >&5
9014 echo "${ECHO_T}$cf_cv_term_header" >&6
9016 # Set definitions to allow ifdef'ing to accommodate subdirectories
9018 case "$cf_cv_term_header" in
9021 cat >>confdefs.h <<\EOF
9022 #define HAVE_TERM_H 1
9028 case "$cf_cv_term_header" in
9031 cat >>confdefs.h <<\EOF
9032 #define HAVE_NCURSES_TERM_H 1
9038 cat >>confdefs.h <<\EOF
9039 #define HAVE_NCURSESW_TERM_H 1
9048 echo "$as_me:9048: result: no" >&5
9049 echo "${ECHO_T}no" >&6
9050 NCURSES_CONFIG_PKG=none
9053 NCURSES_CONFIG_PKG=none
9056 if test "x$cf_have_ncuconfig" = "xno"; then
9057 cf_ncurses_config="${cf_ncuconfig_root}${NCURSES_CONFIG_SUFFIX}-config"; echo "Looking for ${cf_ncurses_config}"
9059 if test -n "$ac_tool_prefix"; then
9060 for ac_prog in ${cf_ncurses_config} ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
9062 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
9063 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
9064 echo "$as_me:9064: checking for $ac_word" >&5
9065 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
9066 if test "${ac_cv_prog_NCURSES_CONFIG+set}" = set; then
9067 echo $ECHO_N "(cached) $ECHO_C" >&6
9069 if test -n "$NCURSES_CONFIG"; then
9070 ac_cv_prog_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test.
9072 ac_save_IFS=$IFS; IFS=$ac_path_separator
9074 for ac_dir in $ac_dummy; do
9076 test -z "$ac_dir" && ac_dir=.
9077 $as_executable_p "$ac_dir/$ac_word" || continue
9078 ac_cv_prog_NCURSES_CONFIG="$ac_tool_prefix$ac_prog"
9079 echo "$as_me:9079: found $ac_dir/$ac_word" >&5
9085 NCURSES_CONFIG=$ac_cv_prog_NCURSES_CONFIG
9086 if test -n "$NCURSES_CONFIG"; then
9087 echo "$as_me:9087: result: $NCURSES_CONFIG" >&5
9088 echo "${ECHO_T}$NCURSES_CONFIG" >&6
9090 echo "$as_me:9090: result: no" >&5
9091 echo "${ECHO_T}no" >&6
9094 test -n "$NCURSES_CONFIG" && break
9097 if test -z "$NCURSES_CONFIG"; then
9098 ac_ct_NCURSES_CONFIG=$NCURSES_CONFIG
9099 for ac_prog in ${cf_ncurses_config} ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
9101 # Extract the first word of "$ac_prog", so it can be a program name with args.
9102 set dummy $ac_prog; ac_word=$2
9103 echo "$as_me:9103: checking for $ac_word" >&5
9104 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
9105 if test "${ac_cv_prog_ac_ct_NCURSES_CONFIG+set}" = set; then
9106 echo $ECHO_N "(cached) $ECHO_C" >&6
9108 if test -n "$ac_ct_NCURSES_CONFIG"; then
9109 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_ct_NCURSES_CONFIG" # Let the user override the test.
9111 ac_save_IFS=$IFS; IFS=$ac_path_separator
9113 for ac_dir in $ac_dummy; do
9115 test -z "$ac_dir" && ac_dir=.
9116 $as_executable_p "$ac_dir/$ac_word" || continue
9117 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_prog"
9118 echo "$as_me:9118: found $ac_dir/$ac_word" >&5
9124 ac_ct_NCURSES_CONFIG=$ac_cv_prog_ac_ct_NCURSES_CONFIG
9125 if test -n "$ac_ct_NCURSES_CONFIG"; then
9126 echo "$as_me:9126: result: $ac_ct_NCURSES_CONFIG" >&5
9127 echo "${ECHO_T}$ac_ct_NCURSES_CONFIG" >&6
9129 echo "$as_me:9129: result: no" >&5
9130 echo "${ECHO_T}no" >&6
9133 test -n "$ac_ct_NCURSES_CONFIG" && break
9135 test -n "$ac_ct_NCURSES_CONFIG" || ac_ct_NCURSES_CONFIG="none"
9137 NCURSES_CONFIG=$ac_ct_NCURSES_CONFIG
9140 if test "$NCURSES_CONFIG" != none ; then
9142 for cf_add_cflags in `$NCURSES_CONFIG --cflags`
9144 case "x$cf_add_cflags" in
9147 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
9150 cf_old_cflag=`echo "x$CFLAGS" | sed -e 's/^.//' -e 's/[ ][ ]*-/ -/g' -e "s%$cf_tmp_cflag\\(=[^ ][^ ]*\\)\?%%" -e 's/^[ ]*//' -e 's%[ ][ ]*-D% -D%g' -e 's%[ ][ ]*-I% -I%g'`
9151 test "$CFLAGS" != "$cf_old_cflag" || break
9153 CFLAGS="$cf_old_cflag"
9156 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
9159 cf_old_cflag=`echo "x$CPPFLAGS" | sed -e 's/^.//' -e 's/[ ][ ]*-/ -/g' -e "s%$cf_tmp_cflag\\(=[^ ][^ ]*\\)\?%%" -e 's/^[ ]*//' -e 's%[ ][ ]*-D% -D%g' -e 's%[ ][ ]*-I% -I%g'`
9160 test "$CPPFLAGS" != "$cf_old_cflag" || break
9162 CPPFLAGS="$cf_old_cflag"
9171 cf_new_extra_cppflags=
9173 for cf_add_cflags in $cf_add_cflags
9175 case "$cf_fix_cppflags" in
9177 case "$cf_add_cflags" in
9178 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
9179 case "$cf_add_cflags" in
9181 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
9183 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
9184 && test -z "${cf_tst_cflags}" \
9185 && cf_fix_cppflags=yes
9187 if test "$cf_fix_cppflags" = yes ; then
9189 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9190 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9193 elif test "${cf_tst_cflags}" = "\"'" ; then
9195 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9196 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9206 case "$cf_add_cflags" in
9208 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
9210 CPPFLAGS=`echo "$CPPFLAGS" | \
9211 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
9212 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
9217 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
9218 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
9225 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
9226 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
9233 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9234 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9236 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
9238 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
9239 && test -z "${cf_tst_cflags}" \
9240 && cf_fix_cppflags=no
9245 if test -n "$cf_new_cflags" ; then
9247 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
9248 CFLAGS="${CFLAGS}$cf_new_cflags"
9252 if test -n "$cf_new_cppflags" ; then
9254 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
9255 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
9259 if test -n "$cf_new_extra_cppflags" ; then
9261 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
9262 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
9271 for cf_add_1lib in `$NCURSES_CONFIG --libs`; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
9273 for cf_add_1lib in $cf_add_0lib; do
9274 for cf_add_2lib in $cf_add_libs; do
9275 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
9280 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
9284 # even with config script, some packages use no-override for curses.h
9286 echo "$as_me:9286: checking if we have identified curses headers" >&5
9287 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
9288 if test "${cf_cv_ncurses_header+set}" = set; then
9289 echo $ECHO_N "(cached) $ECHO_C" >&6
9292 cf_cv_ncurses_header=none
9294 ncurses.h $cf_cv_screen/ncurses.h \
9295 curses.h $cf_cv_screen/curses.h
9297 cat >"conftest.$ac_ext" <<_ACEOF
9298 #line 9298 "configure"
9299 #include "confdefs.h"
9300 #include <${cf_header}>
9309 rm -f "conftest.$ac_objext"
9310 if { (eval echo "$as_me:9310: \"$ac_compile\"") >&5
9311 (eval $ac_compile) 2>&5
9313 echo "$as_me:9313: \$? = $ac_status" >&5
9314 (exit "$ac_status"); } &&
9315 { ac_try='test -s "conftest.$ac_objext"'
9316 { (eval echo "$as_me:9316: \"$ac_try\"") >&5
9319 echo "$as_me:9319: \$? = $ac_status" >&5
9320 (exit "$ac_status"); }; }; then
9321 cf_cv_ncurses_header=$cf_header; break
9323 echo "$as_me: failed program was:" >&5
9324 cat "conftest.$ac_ext" >&5
9326 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
9330 echo "$as_me:9330: result: $cf_cv_ncurses_header" >&5
9331 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
9333 if test "$cf_cv_ncurses_header" = none ; then
9334 { { echo "$as_me:9334: error: No curses header-files found" >&5
9335 echo "$as_me: error: No curses header-files found" >&2;}
9336 { (exit 1); exit 1; }; }
9339 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
9341 for ac_header in $cf_cv_ncurses_header
9343 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9344 echo "$as_me:9344: checking for $ac_header" >&5
9345 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9346 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9347 echo $ECHO_N "(cached) $ECHO_C" >&6
9349 cat >"conftest.$ac_ext" <<_ACEOF
9350 #line 9350 "configure"
9351 #include "confdefs.h"
9352 #include <$ac_header>
9354 if { (eval echo "$as_me:9354: \"$ac_cpp "conftest.$ac_ext"\"") >&5
9355 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
9357 $EGREP -v '^ *\+' conftest.er1 >conftest.err
9359 cat conftest.err >&5
9360 echo "$as_me:9360: \$? = $ac_status" >&5
9361 (exit "$ac_status"); } >/dev/null; then
9362 if test -s conftest.err; then
9363 ac_cpp_err=$ac_c_preproc_warn_flag
9370 if test -z "$ac_cpp_err"; then
9371 eval "$as_ac_Header=yes"
9373 echo "$as_me: failed program was:" >&5
9374 cat "conftest.$ac_ext" >&5
9375 eval "$as_ac_Header=no"
9377 rm -f conftest.err "conftest.$ac_ext"
9379 echo "$as_me:9379: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
9380 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
9381 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
9382 cat >>confdefs.h <<EOF
9383 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9389 cat >>confdefs.h <<\EOF
9393 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
9395 cat >>confdefs.h <<EOF
9396 #define $cf_nculib_ROOT 1
9399 cf_cv_ncurses_version="`$NCURSES_CONFIG --version`"
9403 cf_ncuhdr_root=$cf_cv_screen
9405 test -n "$cf_cv_curses_dir" && \
9406 test "$cf_cv_curses_dir" != "no" && { \
9408 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
9409 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
9411 while test "$cf_add_incdir" != /usr/include
9413 if test -d "$cf_add_incdir"
9416 if test -n "$CFLAGS$CPPFLAGS" ; then
9417 # a loop is needed to ensure we can add subdirs of existing dirs
9418 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
9419 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
9420 cf_have_incdir=yes; break
9425 if test "$cf_have_incdir" = no ; then
9426 if test "$cf_add_incdir" = /usr/local/include ; then
9427 if test "$GCC" = yes
9429 cf_save_CPPFLAGS=$CPPFLAGS
9431 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
9432 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
9434 cat >"conftest.$ac_ext" <<_ACEOF
9435 #line 9435 "configure"
9436 #include "confdefs.h"
9446 rm -f "conftest.$ac_objext"
9447 if { (eval echo "$as_me:9447: \"$ac_compile\"") >&5
9448 (eval $ac_compile) 2>&5
9450 echo "$as_me:9450: \$? = $ac_status" >&5
9451 (exit "$ac_status"); } &&
9452 { ac_try='test -s "conftest.$ac_objext"'
9453 { (eval echo "$as_me:9453: \"$ac_try\"") >&5
9456 echo "$as_me:9456: \$? = $ac_status" >&5
9457 (exit "$ac_status"); }; }; then
9460 echo "$as_me: failed program was:" >&5
9461 cat "conftest.$ac_ext" >&5
9464 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
9465 CPPFLAGS=$cf_save_CPPFLAGS
9470 if test "$cf_have_incdir" = no ; then
9471 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
9473 echo "${as_me:-configure}:9473: testing adding $cf_add_incdir to include-path ..." 1>&5
9475 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
9477 cf_top_incdir=`echo "$cf_add_incdir" | sed -e 's%/include/.*$%/include%'`
9478 test "$cf_top_incdir" = "$cf_add_incdir" && break
9479 cf_add_incdir="$cf_top_incdir"
9492 echo "$as_me:9492: checking for $cf_ncuhdr_root header in include-path" >&5
9493 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
9494 if test "${cf_cv_ncurses_h+set}" = set; then
9495 echo $ECHO_N "(cached) $ECHO_C" >&6
9498 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
9499 { test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw; } && cf_header_list="$cf_header_list curses.h ncurses.h"
9500 for cf_header in $cf_header_list
9503 cat >"conftest.$ac_ext" <<_ACEOF
9504 #line 9504 "configure"
9505 #include "confdefs.h"
9507 #include <$cf_header>
9512 #ifdef NCURSES_VERSION
9514 printf("%s\\n", NCURSES_VERSION);
9519 #error __NCURSES_H is not defined
9527 rm -f "conftest.$ac_objext"
9528 if { (eval echo "$as_me:9528: \"$ac_compile\"") >&5
9529 (eval $ac_compile) 2>&5
9531 echo "$as_me:9531: \$? = $ac_status" >&5
9532 (exit "$ac_status"); } &&
9533 { ac_try='test -s "conftest.$ac_objext"'
9534 { (eval echo "$as_me:9534: \"$ac_try\"") >&5
9537 echo "$as_me:9537: \$? = $ac_status" >&5
9538 (exit "$ac_status"); }; }; then
9539 cf_cv_ncurses_h=$cf_header
9542 echo "$as_me: failed program was:" >&5
9543 cat "conftest.$ac_ext" >&5
9546 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
9548 test "$cf_cv_ncurses_h" != no && break
9552 echo "$as_me:9552: result: $cf_cv_ncurses_h" >&5
9553 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
9555 if test "$cf_cv_ncurses_h" != no ; then
9556 cf_cv_ncurses_header=$cf_cv_ncurses_h
9559 echo "$as_me:9559: checking for $cf_ncuhdr_root include-path" >&5
9560 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
9561 if test "${cf_cv_ncurses_h2+set}" = set; then
9562 echo $ECHO_N "(cached) $ECHO_C" >&6
9565 test -n "$verbose" && echo
9569 # collect the current set of include-directories from compiler flags
9570 cf_header_path_list=""
9571 if test -n "${CFLAGS}${CPPFLAGS}" ; then
9572 for cf_header_path in $CPPFLAGS $CFLAGS
9574 case "$cf_header_path" in
9576 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
9578 test "x$cf_header_path" != "xNONE" && \
9579 test -d "$cf_header_path" && \
9581 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
9582 test -d "$cf_header_path/include" && cf_search="$cf_search $cf_header_path/include"
9583 test -d "$cf_header_path/include/$cf_ncuhdr_root" && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
9584 test -d "$cf_header_path/include/$cf_ncuhdr_root/include" && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
9585 test -d "$cf_header_path/$cf_ncuhdr_root/include" && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
9586 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"
9589 cf_header_path_list="$cf_header_path_list $cf_search"
9595 # add the variations for the package we are looking for
9599 test "x$prefix" != "xNONE" && \
9600 test -d "$prefix" && \
9602 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
9603 test -d "$prefix/include" && cf_search="$cf_search $prefix/include"
9604 test -d "$prefix/include/$cf_ncuhdr_root" && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
9605 test -d "$prefix/include/$cf_ncuhdr_root/include" && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
9606 test -d "$prefix/$cf_ncuhdr_root/include" && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
9607 test -d "$prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root" && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
9610 for cf_subdir_prefix in \
9619 test "x$cf_subdir_prefix" != "x$prefix" && \
9620 test -d "$cf_subdir_prefix" && \
9621 { test -z "$prefix" || test "x$prefix" = xNONE || test "x$cf_subdir_prefix" != "x$prefix"; } && {
9622 test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
9623 test -d "$cf_subdir_prefix/include" && cf_search="$cf_search $cf_subdir_prefix/include"
9624 test -d "$cf_subdir_prefix/include/$cf_ncuhdr_root" && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root"
9625 test -d "$cf_subdir_prefix/include/$cf_ncuhdr_root/include" && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root/include"
9626 test -d "$cf_subdir_prefix/$cf_ncuhdr_root/include" && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include"
9627 test -d "$cf_subdir_prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root" && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
9632 test "$includedir" != NONE && \
9633 test "$includedir" != "/usr/include" && \
9634 test -d "$includedir" && {
9635 test -d "$includedir" && cf_search="$cf_search $includedir"
9636 test -d "$includedir/$cf_ncuhdr_root" && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
9639 test "$oldincludedir" != NONE && \
9640 test "$oldincludedir" != "/usr/include" && \
9641 test -d "$oldincludedir" && {
9642 test -d "$oldincludedir" && cf_search="$cf_search $oldincludedir"
9643 test -d "$oldincludedir/$cf_ncuhdr_root" && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
9646 cf_search="$cf_search $cf_header_path_list"
9648 test -n "$verbose" && echo "search path $cf_search"
9649 cf_save2_CPPFLAGS="$CPPFLAGS"
9650 for cf_incdir in $cf_search
9653 if test -n "$cf_incdir" ; then
9654 for cf_add_incdir in $cf_incdir
9656 while test "$cf_add_incdir" != /usr/include
9658 if test -d "$cf_add_incdir"
9661 if test -n "$CFLAGS$CPPFLAGS" ; then
9662 # a loop is needed to ensure we can add subdirs of existing dirs
9663 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
9664 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
9665 cf_have_incdir=yes; break
9670 if test "$cf_have_incdir" = no ; then
9671 if test "$cf_add_incdir" = /usr/local/include ; then
9672 if test "$GCC" = yes
9674 cf_save_CPPFLAGS=$CPPFLAGS
9676 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
9677 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
9679 cat >"conftest.$ac_ext" <<_ACEOF
9680 #line 9680 "configure"
9681 #include "confdefs.h"
9691 rm -f "conftest.$ac_objext"
9692 if { (eval echo "$as_me:9692: \"$ac_compile\"") >&5
9693 (eval $ac_compile) 2>&5
9695 echo "$as_me:9695: \$? = $ac_status" >&5
9696 (exit "$ac_status"); } &&
9697 { ac_try='test -s "conftest.$ac_objext"'
9698 { (eval echo "$as_me:9698: \"$ac_try\"") >&5
9701 echo "$as_me:9701: \$? = $ac_status" >&5
9702 (exit "$ac_status"); }; }; then
9705 echo "$as_me: failed program was:" >&5
9706 cat "conftest.$ac_ext" >&5
9709 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
9710 CPPFLAGS=$cf_save_CPPFLAGS
9715 if test "$cf_have_incdir" = no ; then
9716 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
9718 echo "${as_me:-configure}:9718: testing adding $cf_add_incdir to include-path ..." 1>&5
9720 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
9722 cf_top_incdir=`echo "$cf_add_incdir" | sed -e 's%/include/.*$%/include%'`
9723 test "$cf_top_incdir" = "$cf_add_incdir" && break
9724 cf_add_incdir="$cf_top_incdir"
9740 cat >"conftest.$ac_ext" <<_ACEOF
9741 #line 9741 "configure"
9742 #include "confdefs.h"
9744 #include <$cf_header>
9749 #ifdef NCURSES_VERSION
9751 printf("%s\\n", NCURSES_VERSION);
9756 #error __NCURSES_H is not defined
9764 rm -f "conftest.$ac_objext"
9765 if { (eval echo "$as_me:9765: \"$ac_compile\"") >&5
9766 (eval $ac_compile) 2>&5
9768 echo "$as_me:9768: \$? = $ac_status" >&5
9769 (exit "$ac_status"); } &&
9770 { ac_try='test -s "conftest.$ac_objext"'
9771 { (eval echo "$as_me:9771: \"$ac_try\"") >&5
9774 echo "$as_me:9774: \$? = $ac_status" >&5
9775 (exit "$ac_status"); }; }; then
9776 cf_cv_ncurses_h2=$cf_header
9779 echo "$as_me: failed program was:" >&5
9780 cat "conftest.$ac_ext" >&5
9783 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
9785 if test "$cf_cv_ncurses_h2" != no ; then
9786 cf_cv_ncurses_h2=$cf_incdir/$cf_header
9787 test -n "$verbose" && echo $ECHO_N " ... found $ECHO_C" 1>&6
9790 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
9792 CPPFLAGS="$cf_save2_CPPFLAGS"
9793 test "$cf_cv_ncurses_h2" != no && break
9795 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:9795: error: not found" >&5
9796 echo "$as_me: error: not found" >&2;}
9797 { (exit 1); exit 1; }; }
9800 echo "$as_me:9800: result: $cf_cv_ncurses_h2" >&5
9801 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
9803 cf_1st_incdir=`echo "$cf_cv_ncurses_h2" | sed -e 's%/[^/]*$%%'`
9804 cf_cv_ncurses_header="`basename "$cf_cv_ncurses_h2"`"
9805 if test "`basename "$cf_1st_incdir"`" = "$cf_ncuhdr_root" ; then
9806 cf_cv_ncurses_header="$cf_ncuhdr_root/$cf_cv_ncurses_header"
9809 if test -n "$cf_1st_incdir" ; then
9810 for cf_add_incdir in $cf_1st_incdir
9812 while test "$cf_add_incdir" != /usr/include
9814 if test -d "$cf_add_incdir"
9817 if test -n "$CFLAGS$CPPFLAGS" ; then
9818 # a loop is needed to ensure we can add subdirs of existing dirs
9819 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
9820 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
9821 cf_have_incdir=yes; break
9826 if test "$cf_have_incdir" = no ; then
9827 if test "$cf_add_incdir" = /usr/local/include ; then
9828 if test "$GCC" = yes
9830 cf_save_CPPFLAGS=$CPPFLAGS
9832 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
9833 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
9835 cat >"conftest.$ac_ext" <<_ACEOF
9836 #line 9836 "configure"
9837 #include "confdefs.h"
9847 rm -f "conftest.$ac_objext"
9848 if { (eval echo "$as_me:9848: \"$ac_compile\"") >&5
9849 (eval $ac_compile) 2>&5
9851 echo "$as_me:9851: \$? = $ac_status" >&5
9852 (exit "$ac_status"); } &&
9853 { ac_try='test -s "conftest.$ac_objext"'
9854 { (eval echo "$as_me:9854: \"$ac_try\"") >&5
9857 echo "$as_me:9857: \$? = $ac_status" >&5
9858 (exit "$ac_status"); }; }; then
9861 echo "$as_me: failed program was:" >&5
9862 cat "conftest.$ac_ext" >&5
9865 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
9866 CPPFLAGS=$cf_save_CPPFLAGS
9871 if test "$cf_have_incdir" = no ; then
9872 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
9874 echo "${as_me:-configure}:9874: testing adding $cf_add_incdir to include-path ..." 1>&5
9876 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
9878 cf_top_incdir=`echo "$cf_add_incdir" | sed -e 's%/include/.*$%/include%'`
9879 test "$cf_top_incdir" = "$cf_add_incdir" && break
9880 cf_add_incdir="$cf_top_incdir"
9893 # Set definitions to allow ifdef'ing for ncurses.h
9895 case "$cf_cv_ncurses_header" in
9898 cat >>confdefs.h <<\EOF
9899 #define HAVE_NCURSES_H 1
9905 case "$cf_cv_ncurses_header" in
9906 (ncurses/curses.h|ncurses/ncurses.h)
9908 cat >>confdefs.h <<\EOF
9909 #define HAVE_NCURSES_NCURSES_H 1
9913 (ncursesw/curses.h|ncursesw/ncurses.h)
9915 cat >>confdefs.h <<\EOF
9916 #define HAVE_NCURSESW_NCURSES_H 1
9922 echo "$as_me:9922: checking for terminfo header" >&5
9923 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
9924 if test "${cf_cv_term_header+set}" = set; then
9925 echo $ECHO_N "(cached) $ECHO_C" >&6
9928 case "${cf_cv_ncurses_header}" in
9929 (*/ncurses.h|*/ncursesw.h)
9930 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
9933 cf_term_header=term.h
9937 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
9939 cat >"conftest.$ac_ext" <<_ACEOF
9940 #line 9940 "configure"
9941 #include "confdefs.h"
9943 #include <${cf_cv_ncurses_header:-curses.h}>
9949 int x = auto_left_margin; (void)x
9954 rm -f "conftest.$ac_objext"
9955 if { (eval echo "$as_me:9955: \"$ac_compile\"") >&5
9956 (eval $ac_compile) 2>&5
9958 echo "$as_me:9958: \$? = $ac_status" >&5
9959 (exit "$ac_status"); } &&
9960 { ac_try='test -s "conftest.$ac_objext"'
9961 { (eval echo "$as_me:9961: \"$ac_try\"") >&5
9964 echo "$as_me:9964: \$? = $ac_status" >&5
9965 (exit "$ac_status"); }; }; then
9967 cf_cv_term_header="$cf_test"
9969 echo "$as_me: failed program was:" >&5
9970 cat "conftest.$ac_ext" >&5
9972 cf_cv_term_header=unknown
9975 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
9976 test "$cf_cv_term_header" != unknown && break
9980 echo "$as_me:9980: result: $cf_cv_term_header" >&5
9981 echo "${ECHO_T}$cf_cv_term_header" >&6
9983 # Set definitions to allow ifdef'ing to accommodate subdirectories
9985 case "$cf_cv_term_header" in
9988 cat >>confdefs.h <<\EOF
9989 #define HAVE_TERM_H 1
9995 case "$cf_cv_term_header" in
9998 cat >>confdefs.h <<\EOF
9999 #define HAVE_NCURSES_TERM_H 1
10005 cat >>confdefs.h <<\EOF
10006 #define HAVE_NCURSESW_TERM_H 1
10012 # some applications need this, but should check for NCURSES_VERSION
10014 cat >>confdefs.h <<\EOF
10018 echo "$as_me:10018: checking for ncurses version" >&5
10019 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
10020 if test "${cf_cv_ncurses_version+set}" = set; then
10021 echo $ECHO_N "(cached) $ECHO_C" >&6
10024 cf_cv_ncurses_version=no
10026 rm -f "$cf_tempfile"
10027 if test "$cross_compiling" = yes; then
10029 # This will not work if the preprocessor splits the line after the
10030 # Autoconf token. The 'unproto' program does that.
10031 cat > "conftest.$ac_ext" <<EOF
10032 #include <${cf_cv_ncurses_header:-curses.h}>
10034 #ifdef NCURSES_VERSION
10035 Autoconf NCURSES_VERSION
10043 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
10044 { (eval echo "$as_me:10044: \"$cf_try\"") >&5
10045 (eval $cf_try) 2>&5
10047 echo "$as_me:10047: \$? = $ac_status" >&5
10048 (exit "$ac_status"); }
10049 if test -f conftest.out ; then
10050 cf_out=`sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%' conftest.out`
10051 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
10056 cat >"conftest.$ac_ext" <<_ACEOF
10057 #line 10057 "configure"
10058 #include "confdefs.h"
10060 $ac_includes_default
10062 #include <${cf_cv_ncurses_header:-curses.h}>
10066 FILE *fp = fopen("$cf_tempfile", "w");
10067 #ifdef NCURSES_VERSION
10068 # ifdef NCURSES_VERSION_PATCH
10069 fprintf(fp, "%s.%d\\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
10071 fprintf(fp, "%s\\n", NCURSES_VERSION);
10074 # ifdef __NCURSES_H
10075 fprintf(fp, "old\\n");
10077 #error expected ncurses header to define __NCURSES_H
10080 ${cf_cv_main_return:-return}(0);
10083 rm -f "conftest$ac_exeext"
10084 if { (eval echo "$as_me:10084: \"$ac_link\"") >&5
10085 (eval $ac_link) 2>&5
10087 echo "$as_me:10087: \$? = $ac_status" >&5
10088 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
10089 { (eval echo "$as_me:10089: \"$ac_try\"") >&5
10090 (eval $ac_try) 2>&5
10092 echo "$as_me:10092: \$? = $ac_status" >&5
10093 (exit "$ac_status"); }; }; then
10095 cf_cv_ncurses_version=`cat $cf_tempfile`
10097 echo "$as_me: program exited with status $ac_status" >&5
10098 echo "$as_me: failed program was:" >&5
10099 cat "conftest.$ac_ext" >&5
10101 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
10103 rm -f "$cf_tempfile"
10106 echo "$as_me:10106: result: $cf_cv_ncurses_version" >&5
10107 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
10108 test "$cf_cv_ncurses_version" = no ||
10109 cat >>confdefs.h <<\EOF
10113 cf_nculib_root=$cf_cv_screen
10114 # This works, except for the special case where we find gpm, but
10115 # ncurses is in a nonstandard location via $LIBS, and we really want
10118 cf_ncurses_SAVE="$LIBS"
10119 echo "$as_me:10119: checking for Gpm_Open in -lgpm" >&5
10120 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
10121 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
10122 echo $ECHO_N "(cached) $ECHO_C" >&6
10124 ac_check_lib_save_LIBS=$LIBS
10126 cat >"conftest.$ac_ext" <<_ACEOF
10127 #line 10127 "configure"
10128 #include "confdefs.h"
10130 /* Override any gcc2 internal prototype to avoid an error. */
10134 /* We use char because int might match the return type of a gcc2
10135 builtin and then its argument prototype would still apply. */
10136 char Gpm_Open (void);
10145 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
10146 if { (eval echo "$as_me:10146: \"$ac_link\"") >&5
10147 (eval $ac_link) 2>&5
10149 echo "$as_me:10149: \$? = $ac_status" >&5
10150 (exit "$ac_status"); } &&
10151 { ac_try='test -s "conftest$ac_exeext"'
10152 { (eval echo "$as_me:10152: \"$ac_try\"") >&5
10153 (eval $ac_try) 2>&5
10155 echo "$as_me:10155: \$? = $ac_status" >&5
10156 (exit "$ac_status"); }; }; then
10157 ac_cv_lib_gpm_Gpm_Open=yes
10159 echo "$as_me: failed program was:" >&5
10160 cat "conftest.$ac_ext" >&5
10161 ac_cv_lib_gpm_Gpm_Open=no
10163 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
10164 LIBS=$ac_check_lib_save_LIBS
10166 echo "$as_me:10166: result: $ac_cv_lib_gpm_Gpm_Open" >&5
10167 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
10168 if test "$ac_cv_lib_gpm_Gpm_Open" = yes; then
10169 echo "$as_me:10169: checking for initscr in -lgpm" >&5
10170 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
10171 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
10172 echo $ECHO_N "(cached) $ECHO_C" >&6
10174 ac_check_lib_save_LIBS=$LIBS
10176 cat >"conftest.$ac_ext" <<_ACEOF
10177 #line 10177 "configure"
10178 #include "confdefs.h"
10180 /* Override any gcc2 internal prototype to avoid an error. */
10184 /* We use char because int might match the return type of a gcc2
10185 builtin and then its argument prototype would still apply. */
10186 char initscr (void);
10195 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
10196 if { (eval echo "$as_me:10196: \"$ac_link\"") >&5
10197 (eval $ac_link) 2>&5
10199 echo "$as_me:10199: \$? = $ac_status" >&5
10200 (exit "$ac_status"); } &&
10201 { ac_try='test -s "conftest$ac_exeext"'
10202 { (eval echo "$as_me:10202: \"$ac_try\"") >&5
10203 (eval $ac_try) 2>&5
10205 echo "$as_me:10205: \$? = $ac_status" >&5
10206 (exit "$ac_status"); }; }; then
10207 ac_cv_lib_gpm_initscr=yes
10209 echo "$as_me: failed program was:" >&5
10210 cat "conftest.$ac_ext" >&5
10211 ac_cv_lib_gpm_initscr=no
10213 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
10214 LIBS=$ac_check_lib_save_LIBS
10216 echo "$as_me:10216: result: $ac_cv_lib_gpm_initscr" >&5
10217 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
10218 if test "$ac_cv_lib_gpm_initscr" = yes; then
10219 LIBS="$cf_ncurses_SAVE"
10221 cf_ncurses_LIBS="-lgpm"
10228 # This is only necessary if you are linking against an obsolete
10229 # version of ncurses (but it should do no harm, since it is static).
10230 if test "$cf_nculib_root" = ncurses ; then
10231 echo "$as_me:10231: checking for tgoto in -lmytinfo" >&5
10232 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
10233 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
10234 echo $ECHO_N "(cached) $ECHO_C" >&6
10236 ac_check_lib_save_LIBS=$LIBS
10237 LIBS="-lmytinfo $LIBS"
10238 cat >"conftest.$ac_ext" <<_ACEOF
10239 #line 10239 "configure"
10240 #include "confdefs.h"
10242 /* Override any gcc2 internal prototype to avoid an error. */
10246 /* We use char because int might match the return type of a gcc2
10247 builtin and then its argument prototype would still apply. */
10257 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
10258 if { (eval echo "$as_me:10258: \"$ac_link\"") >&5
10259 (eval $ac_link) 2>&5
10261 echo "$as_me:10261: \$? = $ac_status" >&5
10262 (exit "$ac_status"); } &&
10263 { ac_try='test -s "conftest$ac_exeext"'
10264 { (eval echo "$as_me:10264: \"$ac_try\"") >&5
10265 (eval $ac_try) 2>&5
10267 echo "$as_me:10267: \$? = $ac_status" >&5
10268 (exit "$ac_status"); }; }; then
10269 ac_cv_lib_mytinfo_tgoto=yes
10271 echo "$as_me: failed program was:" >&5
10272 cat "conftest.$ac_ext" >&5
10273 ac_cv_lib_mytinfo_tgoto=no
10275 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
10276 LIBS=$ac_check_lib_save_LIBS
10278 echo "$as_me:10278: result: $ac_cv_lib_mytinfo_tgoto" >&5
10279 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
10280 if test "$ac_cv_lib_mytinfo_tgoto" = yes; then
10281 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
10288 cf_add_libs="$LIBS"
10291 for cf_add_1lib in $cf_ncurses_LIBS; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
10292 # filter duplicates
10293 for cf_add_1lib in $cf_add_0lib; do
10294 for cf_add_2lib in $cf_add_libs; do
10295 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
10300 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
10302 LIBS="$cf_add_libs"
10304 if test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no"
10307 cf_add_libs="$LIBS"
10310 for cf_add_1lib in -l$cf_nculib_root; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
10311 # filter duplicates
10312 for cf_add_1lib in $cf_add_0lib; do
10313 for cf_add_2lib in $cf_add_libs; do
10314 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
10319 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
10321 LIBS="$cf_add_libs"
10325 eval 'cf_cv_have_lib_'"$cf_nculib_root"'=no'
10327 echo "$as_me:10327: checking for initscr" >&5
10328 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
10329 if test "${ac_cv_func_initscr+set}" = set; then
10330 echo $ECHO_N "(cached) $ECHO_C" >&6
10332 cat >"conftest.$ac_ext" <<_ACEOF
10333 #line 10333 "configure"
10334 #include "confdefs.h"
10335 #define initscr autoconf_temporary
10336 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
10343 /* We use char because int might match the return type of a gcc2
10344 builtin and then its argument prototype would still apply. */
10345 char initscr (void);
10351 /* The GNU C library defines stubs for functions which it implements
10352 to always fail with ENOSYS. Some functions are actually named
10353 something starting with __ and the normal name is an alias. */
10354 #if defined (__stub_initscr) || defined (__stub___initscr)
10355 #error found stub for initscr
10363 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
10364 if { (eval echo "$as_me:10364: \"$ac_link\"") >&5
10365 (eval $ac_link) 2>&5
10367 echo "$as_me:10367: \$? = $ac_status" >&5
10368 (exit "$ac_status"); } &&
10369 { ac_try='test -s "conftest$ac_exeext"'
10370 { (eval echo "$as_me:10370: \"$ac_try\"") >&5
10371 (eval $ac_try) 2>&5
10373 echo "$as_me:10373: \$? = $ac_status" >&5
10374 (exit "$ac_status"); }; }; then
10375 ac_cv_func_initscr=yes
10377 echo "$as_me: failed program was:" >&5
10378 cat "conftest.$ac_ext" >&5
10379 ac_cv_func_initscr=no
10381 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
10383 echo "$as_me:10383: result: $ac_cv_func_initscr" >&5
10384 echo "${ECHO_T}$ac_cv_func_initscr" >&6
10385 if test "$ac_cv_func_initscr" = yes; then
10386 eval 'cf_cv_have_lib_'"$cf_nculib_root"'=yes'
10389 cf_save_LIBS="$LIBS"
10390 echo "$as_me:10390: checking for initscr in -l$cf_nculib_root" >&5
10391 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
10392 LIBS="-l$cf_nculib_root $LIBS"
10393 cat >"conftest.$ac_ext" <<_ACEOF
10394 #line 10394 "configure"
10395 #include "confdefs.h"
10396 #include <${cf_cv_ncurses_header:-curses.h}>
10405 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
10406 if { (eval echo "$as_me:10406: \"$ac_link\"") >&5
10407 (eval $ac_link) 2>&5
10409 echo "$as_me:10409: \$? = $ac_status" >&5
10410 (exit "$ac_status"); } &&
10411 { ac_try='test -s "conftest$ac_exeext"'
10412 { (eval echo "$as_me:10412: \"$ac_try\"") >&5
10413 (eval $ac_try) 2>&5
10415 echo "$as_me:10415: \$? = $ac_status" >&5
10416 (exit "$ac_status"); }; }; then
10417 echo "$as_me:10417: result: yes" >&5
10418 echo "${ECHO_T}yes" >&6
10419 eval 'cf_cv_have_lib_'"$cf_nculib_root"'=yes'
10422 echo "$as_me: failed program was:" >&5
10423 cat "conftest.$ac_ext" >&5
10424 echo "$as_me:10424: result: no" >&5
10425 echo "${ECHO_T}no" >&6
10428 cf_library_path_list=""
10429 if test -n "${LDFLAGS}${LIBS}" ; then
10430 for cf_library_path in $LDFLAGS $LIBS
10432 case "$cf_library_path" in
10434 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
10436 test "x$cf_library_path" != "xNONE" && \
10437 test -d "$cf_library_path" && \
10439 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
10440 test -d "$cf_library_path/lib" && cf_search="$cf_search $cf_library_path/lib"
10441 test -d "$cf_library_path/lib/$cf_nculib_root" && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
10442 test -d "$cf_library_path/lib/$cf_nculib_root/lib" && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
10443 test -d "$cf_library_path/$cf_nculib_root/lib" && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
10444 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"
10447 cf_library_path_list="$cf_library_path_list $cf_search"
10455 test "x$prefix" != "xNONE" && \
10456 test -d "$prefix" && \
10458 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
10459 test -d "$prefix/lib" && cf_search="$cf_search $prefix/lib"
10460 test -d "$prefix/lib/$cf_nculib_root" && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
10461 test -d "$prefix/lib/$cf_nculib_root/lib" && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
10462 test -d "$prefix/$cf_nculib_root/lib" && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
10463 test -d "$prefix/$cf_nculib_root/lib/$cf_nculib_root" && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
10466 for cf_subdir_prefix in \
10475 test "x$cf_subdir_prefix" != "x$prefix" && \
10476 test -d "$cf_subdir_prefix" && \
10477 { test -z "$prefix" || test "x$prefix" = xNONE || test "x$cf_subdir_prefix" != "x$prefix"; } && {
10478 test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
10479 test -d "$cf_subdir_prefix/lib" && cf_search="$cf_search $cf_subdir_prefix/lib"
10480 test -d "$cf_subdir_prefix/lib/$cf_nculib_root" && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root"
10481 test -d "$cf_subdir_prefix/lib/$cf_nculib_root/lib" && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root/lib"
10482 test -d "$cf_subdir_prefix/$cf_nculib_root/lib" && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib"
10483 test -d "$cf_subdir_prefix/$cf_nculib_root/lib/$cf_nculib_root" && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib/$cf_nculib_root"
10488 cf_search="$cf_library_path_list $cf_search"
10490 for cf_libdir in $cf_search
10492 echo "$as_me:10492: checking for -l$cf_nculib_root in $cf_libdir" >&5
10493 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
10494 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
10495 cat >"conftest.$ac_ext" <<_ACEOF
10496 #line 10496 "configure"
10497 #include "confdefs.h"
10498 #include <${cf_cv_ncurses_header:-curses.h}>
10507 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
10508 if { (eval echo "$as_me:10508: \"$ac_link\"") >&5
10509 (eval $ac_link) 2>&5
10511 echo "$as_me:10511: \$? = $ac_status" >&5
10512 (exit "$ac_status"); } &&
10513 { ac_try='test -s "conftest$ac_exeext"'
10514 { (eval echo "$as_me:10514: \"$ac_try\"") >&5
10515 (eval $ac_try) 2>&5
10517 echo "$as_me:10517: \$? = $ac_status" >&5
10518 (exit "$ac_status"); }; }; then
10519 echo "$as_me:10519: result: yes" >&5
10520 echo "${ECHO_T}yes" >&6
10521 eval 'cf_cv_have_lib_'"$cf_nculib_root"'=yes'
10524 echo "$as_me: failed program was:" >&5
10525 cat "conftest.$ac_ext" >&5
10526 echo "$as_me:10526: result: no" >&5
10527 echo "${ECHO_T}no" >&6
10528 LIBS="$cf_save_LIBS"
10530 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
10534 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
10538 eval 'cf_found_library="$cf_cv_have_lib_'"$cf_nculib_root"\"
10540 if test "$cf_found_library" = no ; then
10541 { { echo "$as_me:10541: error: Cannot link $cf_nculib_root library" >&5
10542 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
10543 { (exit 1); exit 1; }; }
10548 if test -n "$cf_ncurses_LIBS" ; then
10549 echo "$as_me:10549: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
10550 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
10551 cf_ncurses_SAVE="$LIBS"
10552 for p in $cf_ncurses_LIBS ; do
10553 q=`echo "$LIBS" | sed -e "s%$p %%" -e "s%$p$%%"`
10554 if test "$q" != "$LIBS" ; then
10558 cat >"conftest.$ac_ext" <<_ACEOF
10559 #line 10559 "configure"
10560 #include "confdefs.h"
10561 #include <${cf_cv_ncurses_header:-curses.h}>
10565 initscr(); mousemask(0,0); tigetstr((char *)0);
10570 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
10571 if { (eval echo "$as_me:10571: \"$ac_link\"") >&5
10572 (eval $ac_link) 2>&5
10574 echo "$as_me:10574: \$? = $ac_status" >&5
10575 (exit "$ac_status"); } &&
10576 { ac_try='test -s "conftest$ac_exeext"'
10577 { (eval echo "$as_me:10577: \"$ac_try\"") >&5
10578 (eval $ac_try) 2>&5
10580 echo "$as_me:10580: \$? = $ac_status" >&5
10581 (exit "$ac_status"); }; }; then
10582 echo "$as_me:10582: result: yes" >&5
10583 echo "${ECHO_T}yes" >&6
10585 echo "$as_me: failed program was:" >&5
10586 cat "conftest.$ac_ext" >&5
10587 echo "$as_me:10587: result: no" >&5
10588 echo "${ECHO_T}no" >&6
10589 LIBS="$cf_ncurses_SAVE"
10591 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
10594 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
10596 cat >>confdefs.h <<EOF
10597 #define $cf_nculib_ROOT 1
10602 NCURSES_CONFIG=none
10608 cf_ncuconfig_root=$cf_cv_screen
10609 cf_have_ncuconfig=no
10611 if test "x${PKG_CONFIG:=none}" != xnone; then
10612 echo "$as_me:10612: checking pkg-config for $cf_ncuconfig_root" >&5
10613 echo $ECHO_N "checking pkg-config for $cf_ncuconfig_root... $ECHO_C" >&6
10614 if "$PKG_CONFIG" --exists $cf_ncuconfig_root ; then
10615 echo "$as_me:10615: result: yes" >&5
10616 echo "${ECHO_T}yes" >&6
10618 echo "$as_me:10618: checking if the $cf_ncuconfig_root package files work" >&5
10619 echo $ECHO_N "checking if the $cf_ncuconfig_root package files work... $ECHO_C" >&6
10620 cf_have_ncuconfig=unknown
10622 cf_save_CFLAGS="$CFLAGS"
10623 cf_save_CPPFLAGS="$CPPFLAGS"
10624 cf_save_LIBS="$LIBS"
10626 cf_pkg_cflags="`$PKG_CONFIG --cflags $cf_ncuconfig_root`"
10627 cf_pkg_libs="`$PKG_CONFIG --libs $cf_ncuconfig_root`"
10629 # while -W for passing linker flags is prevalent, it is not "standard".
10630 # At least one wrapper for c89/c99 (in Apple's xcode) has its own
10631 # incompatible _and_ non-standard -W option which gives an error. Work
10632 # around that pitfall.
10633 case "x${CC}@@${cf_pkg_libs}@${cf_pkg_cflags}" in
10639 cf_new_extra_cppflags=
10641 for cf_add_cflags in $cf_pkg_cflags
10643 case "$cf_fix_cppflags" in
10645 case "$cf_add_cflags" in
10646 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
10647 case "$cf_add_cflags" in
10649 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10651 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10652 && test -z "${cf_tst_cflags}" \
10653 && cf_fix_cppflags=yes
10655 if test "$cf_fix_cppflags" = yes ; then
10657 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10658 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10661 elif test "${cf_tst_cflags}" = "\"'" ; then
10663 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10664 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10670 case "$CPPFLAGS" in
10674 case "$cf_add_cflags" in
10676 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10678 CPPFLAGS=`echo "$CPPFLAGS" | \
10679 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10680 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10685 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
10686 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
10693 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
10694 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
10701 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10702 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10704 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
10706 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10707 && test -z "${cf_tst_cflags}" \
10708 && cf_fix_cppflags=no
10713 if test -n "$cf_new_cflags" ; then
10715 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
10716 CFLAGS="${CFLAGS}$cf_new_cflags"
10720 if test -n "$cf_new_cppflags" ; then
10722 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
10723 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
10727 if test -n "$cf_new_extra_cppflags" ; then
10729 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
10730 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
10734 cf_add_libs="$LIBS"
10737 for cf_add_1lib in $cf_pkg_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
10738 # filter duplicates
10739 for cf_add_1lib in $cf_add_0lib; do
10740 for cf_add_2lib in $cf_add_libs; do
10741 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
10746 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
10748 LIBS="$cf_add_libs"
10750 cat >"conftest.$ac_ext" <<_ACEOF
10751 #line 10751 "configure"
10752 #include "confdefs.h"
10753 #include <${cf_cv_ncurses_header:-curses.h}>
10757 initscr(); mousemask(0,0); tigetstr((char *)0);
10762 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
10763 if { (eval echo "$as_me:10763: \"$ac_link\"") >&5
10764 (eval $ac_link) 2>&5
10766 echo "$as_me:10766: \$? = $ac_status" >&5
10767 (exit "$ac_status"); } &&
10768 { ac_try='test -s "conftest$ac_exeext"'
10769 { (eval echo "$as_me:10769: \"$ac_try\"") >&5
10770 (eval $ac_try) 2>&5
10772 echo "$as_me:10772: \$? = $ac_status" >&5
10773 (exit "$ac_status"); }; }; then
10774 if test "$cross_compiling" = yes; then
10775 cf_test_ncuconfig=maybe
10777 cat >"conftest.$ac_ext" <<_ACEOF
10778 #line 10778 "configure"
10779 #include "confdefs.h"
10780 #include <${cf_cv_ncurses_header:-curses.h}>
10782 { const char *xx = curses_version(); return (xx == 0); }
10784 rm -f "conftest$ac_exeext"
10785 if { (eval echo "$as_me:10785: \"$ac_link\"") >&5
10786 (eval $ac_link) 2>&5
10788 echo "$as_me:10788: \$? = $ac_status" >&5
10789 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
10790 { (eval echo "$as_me:10790: \"$ac_try\"") >&5
10791 (eval $ac_try) 2>&5
10793 echo "$as_me:10793: \$? = $ac_status" >&5
10794 (exit "$ac_status"); }; }; then
10795 cf_test_ncuconfig=yes
10797 echo "$as_me: program exited with status $ac_status" >&5
10798 echo "$as_me: failed program was:" >&5
10799 cat "conftest.$ac_ext" >&5
10800 cf_test_ncuconfig=no
10802 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
10805 echo "$as_me: failed program was:" >&5
10806 cat "conftest.$ac_ext" >&5
10807 cf_test_ncuconfig=no
10809 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
10811 CFLAGS="$cf_save_CFLAGS"
10812 CPPFLAGS="$cf_save_CPPFLAGS"
10813 LIBS="$cf_save_LIBS"
10815 if test "x$cf_test_ncuconfig" != xyes; then
10816 cf_temp=`echo "x$cf_pkg_cflags" | sed -e s/^x// -e 's/-W[^ ]*//g'`
10817 cf_pkg_cflags="$cf_temp"
10818 cf_temp=`echo "x$cf_pkg_libs" | sed -e s/^x// -e 's/-W[^ ]*//g'`
10819 cf_pkg_libs="$cf_temp"
10824 for cf_add_cflags in $cf_pkg_cflags
10826 case "x$cf_add_cflags" in
10829 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
10832 cf_old_cflag=`echo "x$CFLAGS" | sed -e 's/^.//' -e 's/[ ][ ]*-/ -/g' -e "s%$cf_tmp_cflag\\(=[^ ][^ ]*\\)\?%%" -e 's/^[ ]*//' -e 's%[ ][ ]*-D% -D%g' -e 's%[ ][ ]*-I% -I%g'`
10833 test "$CFLAGS" != "$cf_old_cflag" || break
10835 CFLAGS="$cf_old_cflag"
10838 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
10841 cf_old_cflag=`echo "x$CPPFLAGS" | sed -e 's/^.//' -e 's/[ ][ ]*-/ -/g' -e "s%$cf_tmp_cflag\\(=[^ ][^ ]*\\)\?%%" -e 's/^[ ]*//' -e 's%[ ][ ]*-D% -D%g' -e 's%[ ][ ]*-I% -I%g'`
10842 test "$CPPFLAGS" != "$cf_old_cflag" || break
10844 CPPFLAGS="$cf_old_cflag"
10853 cf_new_extra_cppflags=
10855 for cf_add_cflags in $cf_add_cflags
10857 case "$cf_fix_cppflags" in
10859 case "$cf_add_cflags" in
10860 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
10861 case "$cf_add_cflags" in
10863 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10865 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10866 && test -z "${cf_tst_cflags}" \
10867 && cf_fix_cppflags=yes
10869 if test "$cf_fix_cppflags" = yes ; then
10871 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10872 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10875 elif test "${cf_tst_cflags}" = "\"'" ; then
10877 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10878 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10884 case "$CPPFLAGS" in
10888 case "$cf_add_cflags" in
10890 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10892 CPPFLAGS=`echo "$CPPFLAGS" | \
10893 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10894 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10899 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
10900 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
10907 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
10908 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
10915 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10916 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10918 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
10920 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10921 && test -z "${cf_tst_cflags}" \
10922 && cf_fix_cppflags=no
10927 if test -n "$cf_new_cflags" ; then
10929 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
10930 CFLAGS="${CFLAGS}$cf_new_cflags"
10934 if test -n "$cf_new_cppflags" ; then
10936 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
10937 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
10941 if test -n "$cf_new_extra_cppflags" ; then
10943 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
10944 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
10950 cf_add_libs="$LIBS"
10953 for cf_add_1lib in $cf_pkg_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
10954 # filter duplicates
10955 for cf_add_1lib in $cf_add_0lib; do
10956 for cf_add_2lib in $cf_add_libs; do
10957 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
10962 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
10964 LIBS="$cf_add_libs"
10966 cat >"conftest.$ac_ext" <<_ACEOF
10967 #line 10967 "configure"
10968 #include "confdefs.h"
10969 #include <${cf_cv_ncurses_header:-curses.h}>
10973 initscr(); mousemask(0,0); tigetstr((char *)0);
10978 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
10979 if { (eval echo "$as_me:10979: \"$ac_link\"") >&5
10980 (eval $ac_link) 2>&5
10982 echo "$as_me:10982: \$? = $ac_status" >&5
10983 (exit "$ac_status"); } &&
10984 { ac_try='test -s "conftest$ac_exeext"'
10985 { (eval echo "$as_me:10985: \"$ac_try\"") >&5
10986 (eval $ac_try) 2>&5
10988 echo "$as_me:10988: \$? = $ac_status" >&5
10989 (exit "$ac_status"); }; }; then
10990 if test "$cross_compiling" = yes; then
10991 cf_have_ncuconfig=maybe
10993 cat >"conftest.$ac_ext" <<_ACEOF
10994 #line 10994 "configure"
10995 #include "confdefs.h"
10996 #include <${cf_cv_ncurses_header:-curses.h}>
10998 { const char *xx = curses_version(); return (xx == 0); }
11000 rm -f "conftest$ac_exeext"
11001 if { (eval echo "$as_me:11001: \"$ac_link\"") >&5
11002 (eval $ac_link) 2>&5
11004 echo "$as_me:11004: \$? = $ac_status" >&5
11005 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
11006 { (eval echo "$as_me:11006: \"$ac_try\"") >&5
11007 (eval $ac_try) 2>&5
11009 echo "$as_me:11009: \$? = $ac_status" >&5
11010 (exit "$ac_status"); }; }; then
11011 cf_have_ncuconfig=yes
11013 echo "$as_me: program exited with status $ac_status" >&5
11014 echo "$as_me: failed program was:" >&5
11015 cat "conftest.$ac_ext" >&5
11016 cf_have_ncuconfig=no
11018 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
11021 echo "$as_me: failed program was:" >&5
11022 cat "conftest.$ac_ext" >&5
11023 cf_have_ncuconfig=no
11025 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
11026 echo "$as_me:11026: result: $cf_have_ncuconfig" >&5
11027 echo "${ECHO_T}$cf_have_ncuconfig" >&6
11028 test "$cf_have_ncuconfig" = maybe && cf_have_ncuconfig=yes
11029 if test "$cf_have_ncuconfig" != "yes"
11031 CPPFLAGS="$cf_save_CPPFLAGS"
11032 LIBS="$cf_save_LIBS"
11033 NCURSES_CONFIG_PKG=none
11036 cat >>confdefs.h <<\EOF
11040 NCURSES_CONFIG_PKG=$cf_ncuconfig_root
11042 echo "$as_me:11042: checking for terminfo header" >&5
11043 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
11044 if test "${cf_cv_term_header+set}" = set; then
11045 echo $ECHO_N "(cached) $ECHO_C" >&6
11048 case "${cf_cv_ncurses_header}" in
11049 (*/ncurses.h|*/ncursesw.h)
11050 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
11053 cf_term_header=term.h
11057 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
11059 cat >"conftest.$ac_ext" <<_ACEOF
11060 #line 11060 "configure"
11061 #include "confdefs.h"
11063 #include <${cf_cv_ncurses_header:-curses.h}>
11064 #include <$cf_test>
11069 int x = auto_left_margin; (void)x
11074 rm -f "conftest.$ac_objext"
11075 if { (eval echo "$as_me:11075: \"$ac_compile\"") >&5
11076 (eval $ac_compile) 2>&5
11078 echo "$as_me:11078: \$? = $ac_status" >&5
11079 (exit "$ac_status"); } &&
11080 { ac_try='test -s "conftest.$ac_objext"'
11081 { (eval echo "$as_me:11081: \"$ac_try\"") >&5
11082 (eval $ac_try) 2>&5
11084 echo "$as_me:11084: \$? = $ac_status" >&5
11085 (exit "$ac_status"); }; }; then
11087 cf_cv_term_header="$cf_test"
11089 echo "$as_me: failed program was:" >&5
11090 cat "conftest.$ac_ext" >&5
11092 cf_cv_term_header=unknown
11095 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
11096 test "$cf_cv_term_header" != unknown && break
11100 echo "$as_me:11100: result: $cf_cv_term_header" >&5
11101 echo "${ECHO_T}$cf_cv_term_header" >&6
11103 # Set definitions to allow ifdef'ing to accommodate subdirectories
11105 case "$cf_cv_term_header" in
11108 cat >>confdefs.h <<\EOF
11109 #define HAVE_TERM_H 1
11115 case "$cf_cv_term_header" in
11118 cat >>confdefs.h <<\EOF
11119 #define HAVE_NCURSES_TERM_H 1
11125 cat >>confdefs.h <<\EOF
11126 #define HAVE_NCURSESW_TERM_H 1
11135 echo "$as_me:11135: result: no" >&5
11136 echo "${ECHO_T}no" >&6
11137 NCURSES_CONFIG_PKG=none
11140 NCURSES_CONFIG_PKG=none
11143 if test "x$cf_have_ncuconfig" = "xno"; then
11144 cf_ncurses_config="${cf_ncuconfig_root}${NCURSES_CONFIG_SUFFIX}-config"; echo "Looking for ${cf_ncurses_config}"
11146 if test -n "$ac_tool_prefix"; then
11147 for ac_prog in ${cf_ncurses_config} ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
11149 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
11150 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
11151 echo "$as_me:11151: checking for $ac_word" >&5
11152 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
11153 if test "${ac_cv_prog_NCURSES_CONFIG+set}" = set; then
11154 echo $ECHO_N "(cached) $ECHO_C" >&6
11156 if test -n "$NCURSES_CONFIG"; then
11157 ac_cv_prog_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test.
11159 ac_save_IFS=$IFS; IFS=$ac_path_separator
11161 for ac_dir in $ac_dummy; do
11163 test -z "$ac_dir" && ac_dir=.
11164 $as_executable_p "$ac_dir/$ac_word" || continue
11165 ac_cv_prog_NCURSES_CONFIG="$ac_tool_prefix$ac_prog"
11166 echo "$as_me:11166: found $ac_dir/$ac_word" >&5
11172 NCURSES_CONFIG=$ac_cv_prog_NCURSES_CONFIG
11173 if test -n "$NCURSES_CONFIG"; then
11174 echo "$as_me:11174: result: $NCURSES_CONFIG" >&5
11175 echo "${ECHO_T}$NCURSES_CONFIG" >&6
11177 echo "$as_me:11177: result: no" >&5
11178 echo "${ECHO_T}no" >&6
11181 test -n "$NCURSES_CONFIG" && break
11184 if test -z "$NCURSES_CONFIG"; then
11185 ac_ct_NCURSES_CONFIG=$NCURSES_CONFIG
11186 for ac_prog in ${cf_ncurses_config} ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
11188 # Extract the first word of "$ac_prog", so it can be a program name with args.
11189 set dummy $ac_prog; ac_word=$2
11190 echo "$as_me:11190: checking for $ac_word" >&5
11191 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
11192 if test "${ac_cv_prog_ac_ct_NCURSES_CONFIG+set}" = set; then
11193 echo $ECHO_N "(cached) $ECHO_C" >&6
11195 if test -n "$ac_ct_NCURSES_CONFIG"; then
11196 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_ct_NCURSES_CONFIG" # Let the user override the test.
11198 ac_save_IFS=$IFS; IFS=$ac_path_separator
11200 for ac_dir in $ac_dummy; do
11202 test -z "$ac_dir" && ac_dir=.
11203 $as_executable_p "$ac_dir/$ac_word" || continue
11204 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_prog"
11205 echo "$as_me:11205: found $ac_dir/$ac_word" >&5
11211 ac_ct_NCURSES_CONFIG=$ac_cv_prog_ac_ct_NCURSES_CONFIG
11212 if test -n "$ac_ct_NCURSES_CONFIG"; then
11213 echo "$as_me:11213: result: $ac_ct_NCURSES_CONFIG" >&5
11214 echo "${ECHO_T}$ac_ct_NCURSES_CONFIG" >&6
11216 echo "$as_me:11216: result: no" >&5
11217 echo "${ECHO_T}no" >&6
11220 test -n "$ac_ct_NCURSES_CONFIG" && break
11222 test -n "$ac_ct_NCURSES_CONFIG" || ac_ct_NCURSES_CONFIG="none"
11224 NCURSES_CONFIG=$ac_ct_NCURSES_CONFIG
11227 if test "$NCURSES_CONFIG" != none ; then
11229 for cf_add_cflags in `$NCURSES_CONFIG --cflags`
11231 case "x$cf_add_cflags" in
11234 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
11237 cf_old_cflag=`echo "x$CFLAGS" | sed -e 's/^.//' -e 's/[ ][ ]*-/ -/g' -e "s%$cf_tmp_cflag\\(=[^ ][^ ]*\\)\?%%" -e 's/^[ ]*//' -e 's%[ ][ ]*-D% -D%g' -e 's%[ ][ ]*-I% -I%g'`
11238 test "$CFLAGS" != "$cf_old_cflag" || break
11240 CFLAGS="$cf_old_cflag"
11243 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
11246 cf_old_cflag=`echo "x$CPPFLAGS" | sed -e 's/^.//' -e 's/[ ][ ]*-/ -/g' -e "s%$cf_tmp_cflag\\(=[^ ][^ ]*\\)\?%%" -e 's/^[ ]*//' -e 's%[ ][ ]*-D% -D%g' -e 's%[ ][ ]*-I% -I%g'`
11247 test "$CPPFLAGS" != "$cf_old_cflag" || break
11249 CPPFLAGS="$cf_old_cflag"
11258 cf_new_extra_cppflags=
11260 for cf_add_cflags in $cf_add_cflags
11262 case "$cf_fix_cppflags" in
11264 case "$cf_add_cflags" in
11265 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
11266 case "$cf_add_cflags" in
11268 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11270 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
11271 && test -z "${cf_tst_cflags}" \
11272 && cf_fix_cppflags=yes
11274 if test "$cf_fix_cppflags" = yes ; then
11276 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11277 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11280 elif test "${cf_tst_cflags}" = "\"'" ; then
11282 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11283 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11289 case "$CPPFLAGS" in
11293 case "$cf_add_cflags" in
11295 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11297 CPPFLAGS=`echo "$CPPFLAGS" | \
11298 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11299 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11304 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
11305 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
11312 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
11313 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
11320 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11321 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11323 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
11325 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
11326 && test -z "${cf_tst_cflags}" \
11327 && cf_fix_cppflags=no
11332 if test -n "$cf_new_cflags" ; then
11334 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
11335 CFLAGS="${CFLAGS}$cf_new_cflags"
11339 if test -n "$cf_new_cppflags" ; then
11341 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
11342 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
11346 if test -n "$cf_new_extra_cppflags" ; then
11348 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
11349 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
11355 cf_add_libs="$LIBS"
11358 for cf_add_1lib in `$NCURSES_CONFIG --libs`; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
11359 # filter duplicates
11360 for cf_add_1lib in $cf_add_0lib; do
11361 for cf_add_2lib in $cf_add_libs; do
11362 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
11367 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
11369 LIBS="$cf_add_libs"
11371 # even with config script, some packages use no-override for curses.h
11373 echo "$as_me:11373: checking if we have identified curses headers" >&5
11374 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
11375 if test "${cf_cv_ncurses_header+set}" = set; then
11376 echo $ECHO_N "(cached) $ECHO_C" >&6
11379 cf_cv_ncurses_header=none
11381 ncurses.h $cf_cv_screen/ncurses.h \
11382 curses.h $cf_cv_screen/curses.h
11384 cat >"conftest.$ac_ext" <<_ACEOF
11385 #line 11385 "configure"
11386 #include "confdefs.h"
11387 #include <${cf_header}>
11391 initscr(); endwin()
11396 rm -f "conftest.$ac_objext"
11397 if { (eval echo "$as_me:11397: \"$ac_compile\"") >&5
11398 (eval $ac_compile) 2>&5
11400 echo "$as_me:11400: \$? = $ac_status" >&5
11401 (exit "$ac_status"); } &&
11402 { ac_try='test -s "conftest.$ac_objext"'
11403 { (eval echo "$as_me:11403: \"$ac_try\"") >&5
11404 (eval $ac_try) 2>&5
11406 echo "$as_me:11406: \$? = $ac_status" >&5
11407 (exit "$ac_status"); }; }; then
11408 cf_cv_ncurses_header=$cf_header; break
11410 echo "$as_me: failed program was:" >&5
11411 cat "conftest.$ac_ext" >&5
11413 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
11417 echo "$as_me:11417: result: $cf_cv_ncurses_header" >&5
11418 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
11420 if test "$cf_cv_ncurses_header" = none ; then
11421 { { echo "$as_me:11421: error: No curses header-files found" >&5
11422 echo "$as_me: error: No curses header-files found" >&2;}
11423 { (exit 1); exit 1; }; }
11426 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
11428 for ac_header in $cf_cv_ncurses_header
11430 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
11431 echo "$as_me:11431: checking for $ac_header" >&5
11432 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
11433 if eval "test \"\${$as_ac_Header+set}\" = set"; then
11434 echo $ECHO_N "(cached) $ECHO_C" >&6
11436 cat >"conftest.$ac_ext" <<_ACEOF
11437 #line 11437 "configure"
11438 #include "confdefs.h"
11439 #include <$ac_header>
11441 if { (eval echo "$as_me:11441: \"$ac_cpp "conftest.$ac_ext"\"") >&5
11442 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
11444 $EGREP -v '^ *\+' conftest.er1 >conftest.err
11446 cat conftest.err >&5
11447 echo "$as_me:11447: \$? = $ac_status" >&5
11448 (exit "$ac_status"); } >/dev/null; then
11449 if test -s conftest.err; then
11450 ac_cpp_err=$ac_c_preproc_warn_flag
11457 if test -z "$ac_cpp_err"; then
11458 eval "$as_ac_Header=yes"
11460 echo "$as_me: failed program was:" >&5
11461 cat "conftest.$ac_ext" >&5
11462 eval "$as_ac_Header=no"
11464 rm -f conftest.err "conftest.$ac_ext"
11466 echo "$as_me:11466: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
11467 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
11468 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
11469 cat >>confdefs.h <<EOF
11470 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
11476 cat >>confdefs.h <<\EOF
11480 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
11482 cat >>confdefs.h <<EOF
11483 #define $cf_nculib_ROOT 1
11486 cf_cv_ncurses_version="`$NCURSES_CONFIG --version`"
11490 cf_ncuhdr_root=$cf_cv_screen
11492 test -n "$cf_cv_curses_dir" && \
11493 test "$cf_cv_curses_dir" != "no" && { \
11495 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
11496 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
11498 while test "$cf_add_incdir" != /usr/include
11500 if test -d "$cf_add_incdir"
11503 if test -n "$CFLAGS$CPPFLAGS" ; then
11504 # a loop is needed to ensure we can add subdirs of existing dirs
11505 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
11506 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
11507 cf_have_incdir=yes; break
11512 if test "$cf_have_incdir" = no ; then
11513 if test "$cf_add_incdir" = /usr/local/include ; then
11514 if test "$GCC" = yes
11516 cf_save_CPPFLAGS=$CPPFLAGS
11518 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
11519 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
11521 cat >"conftest.$ac_ext" <<_ACEOF
11522 #line 11522 "configure"
11523 #include "confdefs.h"
11533 rm -f "conftest.$ac_objext"
11534 if { (eval echo "$as_me:11534: \"$ac_compile\"") >&5
11535 (eval $ac_compile) 2>&5
11537 echo "$as_me:11537: \$? = $ac_status" >&5
11538 (exit "$ac_status"); } &&
11539 { ac_try='test -s "conftest.$ac_objext"'
11540 { (eval echo "$as_me:11540: \"$ac_try\"") >&5
11541 (eval $ac_try) 2>&5
11543 echo "$as_me:11543: \$? = $ac_status" >&5
11544 (exit "$ac_status"); }; }; then
11547 echo "$as_me: failed program was:" >&5
11548 cat "conftest.$ac_ext" >&5
11551 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
11552 CPPFLAGS=$cf_save_CPPFLAGS
11557 if test "$cf_have_incdir" = no ; then
11558 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
11560 echo "${as_me:-configure}:11560: testing adding $cf_add_incdir to include-path ..." 1>&5
11562 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
11564 cf_top_incdir=`echo "$cf_add_incdir" | sed -e 's%/include/.*$%/include%'`
11565 test "$cf_top_incdir" = "$cf_add_incdir" && break
11566 cf_add_incdir="$cf_top_incdir"
11579 echo "$as_me:11579: checking for $cf_ncuhdr_root header in include-path" >&5
11580 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
11581 if test "${cf_cv_ncurses_h+set}" = set; then
11582 echo $ECHO_N "(cached) $ECHO_C" >&6
11585 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
11586 { test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw; } && cf_header_list="$cf_header_list curses.h ncurses.h"
11587 for cf_header in $cf_header_list
11590 cat >"conftest.$ac_ext" <<_ACEOF
11591 #line 11591 "configure"
11592 #include "confdefs.h"
11594 #include <$cf_header>
11599 #ifdef NCURSES_VERSION
11601 printf("%s\\n", NCURSES_VERSION);
11606 #error __NCURSES_H is not defined
11614 rm -f "conftest.$ac_objext"
11615 if { (eval echo "$as_me:11615: \"$ac_compile\"") >&5
11616 (eval $ac_compile) 2>&5
11618 echo "$as_me:11618: \$? = $ac_status" >&5
11619 (exit "$ac_status"); } &&
11620 { ac_try='test -s "conftest.$ac_objext"'
11621 { (eval echo "$as_me:11621: \"$ac_try\"") >&5
11622 (eval $ac_try) 2>&5
11624 echo "$as_me:11624: \$? = $ac_status" >&5
11625 (exit "$ac_status"); }; }; then
11626 cf_cv_ncurses_h=$cf_header
11629 echo "$as_me: failed program was:" >&5
11630 cat "conftest.$ac_ext" >&5
11633 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
11635 test "$cf_cv_ncurses_h" != no && break
11639 echo "$as_me:11639: result: $cf_cv_ncurses_h" >&5
11640 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
11642 if test "$cf_cv_ncurses_h" != no ; then
11643 cf_cv_ncurses_header=$cf_cv_ncurses_h
11646 echo "$as_me:11646: checking for $cf_ncuhdr_root include-path" >&5
11647 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
11648 if test "${cf_cv_ncurses_h2+set}" = set; then
11649 echo $ECHO_N "(cached) $ECHO_C" >&6
11652 test -n "$verbose" && echo
11656 # collect the current set of include-directories from compiler flags
11657 cf_header_path_list=""
11658 if test -n "${CFLAGS}${CPPFLAGS}" ; then
11659 for cf_header_path in $CPPFLAGS $CFLAGS
11661 case "$cf_header_path" in
11663 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
11665 test "x$cf_header_path" != "xNONE" && \
11666 test -d "$cf_header_path" && \
11668 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
11669 test -d "$cf_header_path/include" && cf_search="$cf_search $cf_header_path/include"
11670 test -d "$cf_header_path/include/$cf_ncuhdr_root" && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
11671 test -d "$cf_header_path/include/$cf_ncuhdr_root/include" && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
11672 test -d "$cf_header_path/$cf_ncuhdr_root/include" && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
11673 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"
11676 cf_header_path_list="$cf_header_path_list $cf_search"
11682 # add the variations for the package we are looking for
11686 test "x$prefix" != "xNONE" && \
11687 test -d "$prefix" && \
11689 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
11690 test -d "$prefix/include" && cf_search="$cf_search $prefix/include"
11691 test -d "$prefix/include/$cf_ncuhdr_root" && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
11692 test -d "$prefix/include/$cf_ncuhdr_root/include" && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
11693 test -d "$prefix/$cf_ncuhdr_root/include" && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
11694 test -d "$prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root" && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
11697 for cf_subdir_prefix in \
11706 test "x$cf_subdir_prefix" != "x$prefix" && \
11707 test -d "$cf_subdir_prefix" && \
11708 { test -z "$prefix" || test "x$prefix" = xNONE || test "x$cf_subdir_prefix" != "x$prefix"; } && {
11709 test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
11710 test -d "$cf_subdir_prefix/include" && cf_search="$cf_search $cf_subdir_prefix/include"
11711 test -d "$cf_subdir_prefix/include/$cf_ncuhdr_root" && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root"
11712 test -d "$cf_subdir_prefix/include/$cf_ncuhdr_root/include" && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root/include"
11713 test -d "$cf_subdir_prefix/$cf_ncuhdr_root/include" && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include"
11714 test -d "$cf_subdir_prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root" && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
11719 test "$includedir" != NONE && \
11720 test "$includedir" != "/usr/include" && \
11721 test -d "$includedir" && {
11722 test -d "$includedir" && cf_search="$cf_search $includedir"
11723 test -d "$includedir/$cf_ncuhdr_root" && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
11726 test "$oldincludedir" != NONE && \
11727 test "$oldincludedir" != "/usr/include" && \
11728 test -d "$oldincludedir" && {
11729 test -d "$oldincludedir" && cf_search="$cf_search $oldincludedir"
11730 test -d "$oldincludedir/$cf_ncuhdr_root" && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
11733 cf_search="$cf_search $cf_header_path_list"
11735 test -n "$verbose" && echo "search path $cf_search"
11736 cf_save2_CPPFLAGS="$CPPFLAGS"
11737 for cf_incdir in $cf_search
11740 if test -n "$cf_incdir" ; then
11741 for cf_add_incdir in $cf_incdir
11743 while test "$cf_add_incdir" != /usr/include
11745 if test -d "$cf_add_incdir"
11748 if test -n "$CFLAGS$CPPFLAGS" ; then
11749 # a loop is needed to ensure we can add subdirs of existing dirs
11750 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
11751 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
11752 cf_have_incdir=yes; break
11757 if test "$cf_have_incdir" = no ; then
11758 if test "$cf_add_incdir" = /usr/local/include ; then
11759 if test "$GCC" = yes
11761 cf_save_CPPFLAGS=$CPPFLAGS
11763 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
11764 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
11766 cat >"conftest.$ac_ext" <<_ACEOF
11767 #line 11767 "configure"
11768 #include "confdefs.h"
11778 rm -f "conftest.$ac_objext"
11779 if { (eval echo "$as_me:11779: \"$ac_compile\"") >&5
11780 (eval $ac_compile) 2>&5
11782 echo "$as_me:11782: \$? = $ac_status" >&5
11783 (exit "$ac_status"); } &&
11784 { ac_try='test -s "conftest.$ac_objext"'
11785 { (eval echo "$as_me:11785: \"$ac_try\"") >&5
11786 (eval $ac_try) 2>&5
11788 echo "$as_me:11788: \$? = $ac_status" >&5
11789 (exit "$ac_status"); }; }; then
11792 echo "$as_me: failed program was:" >&5
11793 cat "conftest.$ac_ext" >&5
11796 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
11797 CPPFLAGS=$cf_save_CPPFLAGS
11802 if test "$cf_have_incdir" = no ; then
11803 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
11805 echo "${as_me:-configure}:11805: testing adding $cf_add_incdir to include-path ..." 1>&5
11807 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
11809 cf_top_incdir=`echo "$cf_add_incdir" | sed -e 's%/include/.*$%/include%'`
11810 test "$cf_top_incdir" = "$cf_add_incdir" && break
11811 cf_add_incdir="$cf_top_incdir"
11827 cat >"conftest.$ac_ext" <<_ACEOF
11828 #line 11828 "configure"
11829 #include "confdefs.h"
11831 #include <$cf_header>
11836 #ifdef NCURSES_VERSION
11838 printf("%s\\n", NCURSES_VERSION);
11843 #error __NCURSES_H is not defined
11851 rm -f "conftest.$ac_objext"
11852 if { (eval echo "$as_me:11852: \"$ac_compile\"") >&5
11853 (eval $ac_compile) 2>&5
11855 echo "$as_me:11855: \$? = $ac_status" >&5
11856 (exit "$ac_status"); } &&
11857 { ac_try='test -s "conftest.$ac_objext"'
11858 { (eval echo "$as_me:11858: \"$ac_try\"") >&5
11859 (eval $ac_try) 2>&5
11861 echo "$as_me:11861: \$? = $ac_status" >&5
11862 (exit "$ac_status"); }; }; then
11863 cf_cv_ncurses_h2=$cf_header
11866 echo "$as_me: failed program was:" >&5
11867 cat "conftest.$ac_ext" >&5
11868 cf_cv_ncurses_h2=no
11870 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
11872 if test "$cf_cv_ncurses_h2" != no ; then
11873 cf_cv_ncurses_h2=$cf_incdir/$cf_header
11874 test -n "$verbose" && echo $ECHO_N " ... found $ECHO_C" 1>&6
11877 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
11879 CPPFLAGS="$cf_save2_CPPFLAGS"
11880 test "$cf_cv_ncurses_h2" != no && break
11882 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:11882: error: not found" >&5
11883 echo "$as_me: error: not found" >&2;}
11884 { (exit 1); exit 1; }; }
11887 echo "$as_me:11887: result: $cf_cv_ncurses_h2" >&5
11888 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
11890 cf_1st_incdir=`echo "$cf_cv_ncurses_h2" | sed -e 's%/[^/]*$%%'`
11891 cf_cv_ncurses_header="`basename "$cf_cv_ncurses_h2"`"
11892 if test "`basename "$cf_1st_incdir"`" = "$cf_ncuhdr_root" ; then
11893 cf_cv_ncurses_header="$cf_ncuhdr_root/$cf_cv_ncurses_header"
11896 if test -n "$cf_1st_incdir" ; then
11897 for cf_add_incdir in $cf_1st_incdir
11899 while test "$cf_add_incdir" != /usr/include
11901 if test -d "$cf_add_incdir"
11904 if test -n "$CFLAGS$CPPFLAGS" ; then
11905 # a loop is needed to ensure we can add subdirs of existing dirs
11906 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
11907 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
11908 cf_have_incdir=yes; break
11913 if test "$cf_have_incdir" = no ; then
11914 if test "$cf_add_incdir" = /usr/local/include ; then
11915 if test "$GCC" = yes
11917 cf_save_CPPFLAGS=$CPPFLAGS
11919 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
11920 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
11922 cat >"conftest.$ac_ext" <<_ACEOF
11923 #line 11923 "configure"
11924 #include "confdefs.h"
11934 rm -f "conftest.$ac_objext"
11935 if { (eval echo "$as_me:11935: \"$ac_compile\"") >&5
11936 (eval $ac_compile) 2>&5
11938 echo "$as_me:11938: \$? = $ac_status" >&5
11939 (exit "$ac_status"); } &&
11940 { ac_try='test -s "conftest.$ac_objext"'
11941 { (eval echo "$as_me:11941: \"$ac_try\"") >&5
11942 (eval $ac_try) 2>&5
11944 echo "$as_me:11944: \$? = $ac_status" >&5
11945 (exit "$ac_status"); }; }; then
11948 echo "$as_me: failed program was:" >&5
11949 cat "conftest.$ac_ext" >&5
11952 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
11953 CPPFLAGS=$cf_save_CPPFLAGS
11958 if test "$cf_have_incdir" = no ; then
11959 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
11961 echo "${as_me:-configure}:11961: testing adding $cf_add_incdir to include-path ..." 1>&5
11963 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
11965 cf_top_incdir=`echo "$cf_add_incdir" | sed -e 's%/include/.*$%/include%'`
11966 test "$cf_top_incdir" = "$cf_add_incdir" && break
11967 cf_add_incdir="$cf_top_incdir"
11980 # Set definitions to allow ifdef'ing for ncurses.h
11982 case "$cf_cv_ncurses_header" in
11985 cat >>confdefs.h <<\EOF
11986 #define HAVE_NCURSES_H 1
11992 case "$cf_cv_ncurses_header" in
11993 (ncurses/curses.h|ncurses/ncurses.h)
11995 cat >>confdefs.h <<\EOF
11996 #define HAVE_NCURSES_NCURSES_H 1
12000 (ncursesw/curses.h|ncursesw/ncurses.h)
12002 cat >>confdefs.h <<\EOF
12003 #define HAVE_NCURSESW_NCURSES_H 1
12009 echo "$as_me:12009: checking for terminfo header" >&5
12010 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
12011 if test "${cf_cv_term_header+set}" = set; then
12012 echo $ECHO_N "(cached) $ECHO_C" >&6
12015 case "${cf_cv_ncurses_header}" in
12016 (*/ncurses.h|*/ncursesw.h)
12017 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
12020 cf_term_header=term.h
12024 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
12026 cat >"conftest.$ac_ext" <<_ACEOF
12027 #line 12027 "configure"
12028 #include "confdefs.h"
12030 #include <${cf_cv_ncurses_header:-curses.h}>
12031 #include <$cf_test>
12036 int x = auto_left_margin; (void)x
12041 rm -f "conftest.$ac_objext"
12042 if { (eval echo "$as_me:12042: \"$ac_compile\"") >&5
12043 (eval $ac_compile) 2>&5
12045 echo "$as_me:12045: \$? = $ac_status" >&5
12046 (exit "$ac_status"); } &&
12047 { ac_try='test -s "conftest.$ac_objext"'
12048 { (eval echo "$as_me:12048: \"$ac_try\"") >&5
12049 (eval $ac_try) 2>&5
12051 echo "$as_me:12051: \$? = $ac_status" >&5
12052 (exit "$ac_status"); }; }; then
12054 cf_cv_term_header="$cf_test"
12056 echo "$as_me: failed program was:" >&5
12057 cat "conftest.$ac_ext" >&5
12059 cf_cv_term_header=unknown
12062 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
12063 test "$cf_cv_term_header" != unknown && break
12067 echo "$as_me:12067: result: $cf_cv_term_header" >&5
12068 echo "${ECHO_T}$cf_cv_term_header" >&6
12070 # Set definitions to allow ifdef'ing to accommodate subdirectories
12072 case "$cf_cv_term_header" in
12075 cat >>confdefs.h <<\EOF
12076 #define HAVE_TERM_H 1
12082 case "$cf_cv_term_header" in
12085 cat >>confdefs.h <<\EOF
12086 #define HAVE_NCURSES_TERM_H 1
12092 cat >>confdefs.h <<\EOF
12093 #define HAVE_NCURSESW_TERM_H 1
12099 # some applications need this, but should check for NCURSES_VERSION
12101 cat >>confdefs.h <<\EOF
12105 echo "$as_me:12105: checking for ncurses version" >&5
12106 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
12107 if test "${cf_cv_ncurses_version+set}" = set; then
12108 echo $ECHO_N "(cached) $ECHO_C" >&6
12111 cf_cv_ncurses_version=no
12113 rm -f "$cf_tempfile"
12114 if test "$cross_compiling" = yes; then
12116 # This will not work if the preprocessor splits the line after the
12117 # Autoconf token. The 'unproto' program does that.
12118 cat > "conftest.$ac_ext" <<EOF
12119 #include <${cf_cv_ncurses_header:-curses.h}>
12121 #ifdef NCURSES_VERSION
12122 Autoconf NCURSES_VERSION
12130 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
12131 { (eval echo "$as_me:12131: \"$cf_try\"") >&5
12132 (eval $cf_try) 2>&5
12134 echo "$as_me:12134: \$? = $ac_status" >&5
12135 (exit "$ac_status"); }
12136 if test -f conftest.out ; then
12137 cf_out=`sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%' conftest.out`
12138 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
12143 cat >"conftest.$ac_ext" <<_ACEOF
12144 #line 12144 "configure"
12145 #include "confdefs.h"
12147 $ac_includes_default
12149 #include <${cf_cv_ncurses_header:-curses.h}>
12153 FILE *fp = fopen("$cf_tempfile", "w");
12154 #ifdef NCURSES_VERSION
12155 # ifdef NCURSES_VERSION_PATCH
12156 fprintf(fp, "%s.%d\\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
12158 fprintf(fp, "%s\\n", NCURSES_VERSION);
12161 # ifdef __NCURSES_H
12162 fprintf(fp, "old\\n");
12164 #error expected ncurses header to define __NCURSES_H
12167 ${cf_cv_main_return:-return}(0);
12170 rm -f "conftest$ac_exeext"
12171 if { (eval echo "$as_me:12171: \"$ac_link\"") >&5
12172 (eval $ac_link) 2>&5
12174 echo "$as_me:12174: \$? = $ac_status" >&5
12175 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
12176 { (eval echo "$as_me:12176: \"$ac_try\"") >&5
12177 (eval $ac_try) 2>&5
12179 echo "$as_me:12179: \$? = $ac_status" >&5
12180 (exit "$ac_status"); }; }; then
12182 cf_cv_ncurses_version=`cat $cf_tempfile`
12184 echo "$as_me: program exited with status $ac_status" >&5
12185 echo "$as_me: failed program was:" >&5
12186 cat "conftest.$ac_ext" >&5
12188 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
12190 rm -f "$cf_tempfile"
12193 echo "$as_me:12193: result: $cf_cv_ncurses_version" >&5
12194 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
12195 test "$cf_cv_ncurses_version" = no ||
12196 cat >>confdefs.h <<\EOF
12200 cf_nculib_root=$cf_cv_screen
12201 # This works, except for the special case where we find gpm, but
12202 # ncurses is in a nonstandard location via $LIBS, and we really want
12205 cf_ncurses_SAVE="$LIBS"
12206 echo "$as_me:12206: checking for Gpm_Open in -lgpm" >&5
12207 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
12208 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
12209 echo $ECHO_N "(cached) $ECHO_C" >&6
12211 ac_check_lib_save_LIBS=$LIBS
12213 cat >"conftest.$ac_ext" <<_ACEOF
12214 #line 12214 "configure"
12215 #include "confdefs.h"
12217 /* Override any gcc2 internal prototype to avoid an error. */
12221 /* We use char because int might match the return type of a gcc2
12222 builtin and then its argument prototype would still apply. */
12223 char Gpm_Open (void);
12232 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
12233 if { (eval echo "$as_me:12233: \"$ac_link\"") >&5
12234 (eval $ac_link) 2>&5
12236 echo "$as_me:12236: \$? = $ac_status" >&5
12237 (exit "$ac_status"); } &&
12238 { ac_try='test -s "conftest$ac_exeext"'
12239 { (eval echo "$as_me:12239: \"$ac_try\"") >&5
12240 (eval $ac_try) 2>&5
12242 echo "$as_me:12242: \$? = $ac_status" >&5
12243 (exit "$ac_status"); }; }; then
12244 ac_cv_lib_gpm_Gpm_Open=yes
12246 echo "$as_me: failed program was:" >&5
12247 cat "conftest.$ac_ext" >&5
12248 ac_cv_lib_gpm_Gpm_Open=no
12250 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
12251 LIBS=$ac_check_lib_save_LIBS
12253 echo "$as_me:12253: result: $ac_cv_lib_gpm_Gpm_Open" >&5
12254 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
12255 if test "$ac_cv_lib_gpm_Gpm_Open" = yes; then
12256 echo "$as_me:12256: checking for initscr in -lgpm" >&5
12257 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
12258 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
12259 echo $ECHO_N "(cached) $ECHO_C" >&6
12261 ac_check_lib_save_LIBS=$LIBS
12263 cat >"conftest.$ac_ext" <<_ACEOF
12264 #line 12264 "configure"
12265 #include "confdefs.h"
12267 /* Override any gcc2 internal prototype to avoid an error. */
12271 /* We use char because int might match the return type of a gcc2
12272 builtin and then its argument prototype would still apply. */
12273 char initscr (void);
12282 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
12283 if { (eval echo "$as_me:12283: \"$ac_link\"") >&5
12284 (eval $ac_link) 2>&5
12286 echo "$as_me:12286: \$? = $ac_status" >&5
12287 (exit "$ac_status"); } &&
12288 { ac_try='test -s "conftest$ac_exeext"'
12289 { (eval echo "$as_me:12289: \"$ac_try\"") >&5
12290 (eval $ac_try) 2>&5
12292 echo "$as_me:12292: \$? = $ac_status" >&5
12293 (exit "$ac_status"); }; }; then
12294 ac_cv_lib_gpm_initscr=yes
12296 echo "$as_me: failed program was:" >&5
12297 cat "conftest.$ac_ext" >&5
12298 ac_cv_lib_gpm_initscr=no
12300 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
12301 LIBS=$ac_check_lib_save_LIBS
12303 echo "$as_me:12303: result: $ac_cv_lib_gpm_initscr" >&5
12304 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
12305 if test "$ac_cv_lib_gpm_initscr" = yes; then
12306 LIBS="$cf_ncurses_SAVE"
12308 cf_ncurses_LIBS="-lgpm"
12315 # This is only necessary if you are linking against an obsolete
12316 # version of ncurses (but it should do no harm, since it is static).
12317 if test "$cf_nculib_root" = ncurses ; then
12318 echo "$as_me:12318: checking for tgoto in -lmytinfo" >&5
12319 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
12320 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
12321 echo $ECHO_N "(cached) $ECHO_C" >&6
12323 ac_check_lib_save_LIBS=$LIBS
12324 LIBS="-lmytinfo $LIBS"
12325 cat >"conftest.$ac_ext" <<_ACEOF
12326 #line 12326 "configure"
12327 #include "confdefs.h"
12329 /* Override any gcc2 internal prototype to avoid an error. */
12333 /* We use char because int might match the return type of a gcc2
12334 builtin and then its argument prototype would still apply. */
12344 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
12345 if { (eval echo "$as_me:12345: \"$ac_link\"") >&5
12346 (eval $ac_link) 2>&5
12348 echo "$as_me:12348: \$? = $ac_status" >&5
12349 (exit "$ac_status"); } &&
12350 { ac_try='test -s "conftest$ac_exeext"'
12351 { (eval echo "$as_me:12351: \"$ac_try\"") >&5
12352 (eval $ac_try) 2>&5
12354 echo "$as_me:12354: \$? = $ac_status" >&5
12355 (exit "$ac_status"); }; }; then
12356 ac_cv_lib_mytinfo_tgoto=yes
12358 echo "$as_me: failed program was:" >&5
12359 cat "conftest.$ac_ext" >&5
12360 ac_cv_lib_mytinfo_tgoto=no
12362 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
12363 LIBS=$ac_check_lib_save_LIBS
12365 echo "$as_me:12365: result: $ac_cv_lib_mytinfo_tgoto" >&5
12366 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
12367 if test "$ac_cv_lib_mytinfo_tgoto" = yes; then
12368 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
12375 cf_add_libs="$LIBS"
12378 for cf_add_1lib in $cf_ncurses_LIBS; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
12379 # filter duplicates
12380 for cf_add_1lib in $cf_add_0lib; do
12381 for cf_add_2lib in $cf_add_libs; do
12382 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
12387 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
12389 LIBS="$cf_add_libs"
12391 if test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no"
12394 cf_add_libs="$LIBS"
12397 for cf_add_1lib in -l$cf_nculib_root; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
12398 # filter duplicates
12399 for cf_add_1lib in $cf_add_0lib; do
12400 for cf_add_2lib in $cf_add_libs; do
12401 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
12406 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
12408 LIBS="$cf_add_libs"
12412 eval 'cf_cv_have_lib_'"$cf_nculib_root"'=no'
12414 echo "$as_me:12414: checking for initscr" >&5
12415 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
12416 if test "${ac_cv_func_initscr+set}" = set; then
12417 echo $ECHO_N "(cached) $ECHO_C" >&6
12419 cat >"conftest.$ac_ext" <<_ACEOF
12420 #line 12420 "configure"
12421 #include "confdefs.h"
12422 #define initscr autoconf_temporary
12423 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
12430 /* We use char because int might match the return type of a gcc2
12431 builtin and then its argument prototype would still apply. */
12432 char initscr (void);
12438 /* The GNU C library defines stubs for functions which it implements
12439 to always fail with ENOSYS. Some functions are actually named
12440 something starting with __ and the normal name is an alias. */
12441 #if defined (__stub_initscr) || defined (__stub___initscr)
12442 #error found stub for initscr
12450 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
12451 if { (eval echo "$as_me:12451: \"$ac_link\"") >&5
12452 (eval $ac_link) 2>&5
12454 echo "$as_me:12454: \$? = $ac_status" >&5
12455 (exit "$ac_status"); } &&
12456 { ac_try='test -s "conftest$ac_exeext"'
12457 { (eval echo "$as_me:12457: \"$ac_try\"") >&5
12458 (eval $ac_try) 2>&5
12460 echo "$as_me:12460: \$? = $ac_status" >&5
12461 (exit "$ac_status"); }; }; then
12462 ac_cv_func_initscr=yes
12464 echo "$as_me: failed program was:" >&5
12465 cat "conftest.$ac_ext" >&5
12466 ac_cv_func_initscr=no
12468 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
12470 echo "$as_me:12470: result: $ac_cv_func_initscr" >&5
12471 echo "${ECHO_T}$ac_cv_func_initscr" >&6
12472 if test "$ac_cv_func_initscr" = yes; then
12473 eval 'cf_cv_have_lib_'"$cf_nculib_root"'=yes'
12476 cf_save_LIBS="$LIBS"
12477 echo "$as_me:12477: checking for initscr in -l$cf_nculib_root" >&5
12478 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
12479 LIBS="-l$cf_nculib_root $LIBS"
12480 cat >"conftest.$ac_ext" <<_ACEOF
12481 #line 12481 "configure"
12482 #include "confdefs.h"
12483 #include <${cf_cv_ncurses_header:-curses.h}>
12492 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
12493 if { (eval echo "$as_me:12493: \"$ac_link\"") >&5
12494 (eval $ac_link) 2>&5
12496 echo "$as_me:12496: \$? = $ac_status" >&5
12497 (exit "$ac_status"); } &&
12498 { ac_try='test -s "conftest$ac_exeext"'
12499 { (eval echo "$as_me:12499: \"$ac_try\"") >&5
12500 (eval $ac_try) 2>&5
12502 echo "$as_me:12502: \$? = $ac_status" >&5
12503 (exit "$ac_status"); }; }; then
12504 echo "$as_me:12504: result: yes" >&5
12505 echo "${ECHO_T}yes" >&6
12506 eval 'cf_cv_have_lib_'"$cf_nculib_root"'=yes'
12509 echo "$as_me: failed program was:" >&5
12510 cat "conftest.$ac_ext" >&5
12511 echo "$as_me:12511: result: no" >&5
12512 echo "${ECHO_T}no" >&6
12515 cf_library_path_list=""
12516 if test -n "${LDFLAGS}${LIBS}" ; then
12517 for cf_library_path in $LDFLAGS $LIBS
12519 case "$cf_library_path" in
12521 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
12523 test "x$cf_library_path" != "xNONE" && \
12524 test -d "$cf_library_path" && \
12526 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
12527 test -d "$cf_library_path/lib" && cf_search="$cf_search $cf_library_path/lib"
12528 test -d "$cf_library_path/lib/$cf_nculib_root" && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
12529 test -d "$cf_library_path/lib/$cf_nculib_root/lib" && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
12530 test -d "$cf_library_path/$cf_nculib_root/lib" && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
12531 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"
12534 cf_library_path_list="$cf_library_path_list $cf_search"
12542 test "x$prefix" != "xNONE" && \
12543 test -d "$prefix" && \
12545 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
12546 test -d "$prefix/lib" && cf_search="$cf_search $prefix/lib"
12547 test -d "$prefix/lib/$cf_nculib_root" && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
12548 test -d "$prefix/lib/$cf_nculib_root/lib" && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
12549 test -d "$prefix/$cf_nculib_root/lib" && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
12550 test -d "$prefix/$cf_nculib_root/lib/$cf_nculib_root" && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
12553 for cf_subdir_prefix in \
12562 test "x$cf_subdir_prefix" != "x$prefix" && \
12563 test -d "$cf_subdir_prefix" && \
12564 { test -z "$prefix" || test "x$prefix" = xNONE || test "x$cf_subdir_prefix" != "x$prefix"; } && {
12565 test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
12566 test -d "$cf_subdir_prefix/lib" && cf_search="$cf_search $cf_subdir_prefix/lib"
12567 test -d "$cf_subdir_prefix/lib/$cf_nculib_root" && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root"
12568 test -d "$cf_subdir_prefix/lib/$cf_nculib_root/lib" && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root/lib"
12569 test -d "$cf_subdir_prefix/$cf_nculib_root/lib" && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib"
12570 test -d "$cf_subdir_prefix/$cf_nculib_root/lib/$cf_nculib_root" && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib/$cf_nculib_root"
12575 cf_search="$cf_library_path_list $cf_search"
12577 for cf_libdir in $cf_search
12579 echo "$as_me:12579: checking for -l$cf_nculib_root in $cf_libdir" >&5
12580 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
12581 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
12582 cat >"conftest.$ac_ext" <<_ACEOF
12583 #line 12583 "configure"
12584 #include "confdefs.h"
12585 #include <${cf_cv_ncurses_header:-curses.h}>
12594 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
12595 if { (eval echo "$as_me:12595: \"$ac_link\"") >&5
12596 (eval $ac_link) 2>&5
12598 echo "$as_me:12598: \$? = $ac_status" >&5
12599 (exit "$ac_status"); } &&
12600 { ac_try='test -s "conftest$ac_exeext"'
12601 { (eval echo "$as_me:12601: \"$ac_try\"") >&5
12602 (eval $ac_try) 2>&5
12604 echo "$as_me:12604: \$? = $ac_status" >&5
12605 (exit "$ac_status"); }; }; then
12606 echo "$as_me:12606: result: yes" >&5
12607 echo "${ECHO_T}yes" >&6
12608 eval 'cf_cv_have_lib_'"$cf_nculib_root"'=yes'
12611 echo "$as_me: failed program was:" >&5
12612 cat "conftest.$ac_ext" >&5
12613 echo "$as_me:12613: result: no" >&5
12614 echo "${ECHO_T}no" >&6
12615 LIBS="$cf_save_LIBS"
12617 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
12621 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
12625 eval 'cf_found_library="$cf_cv_have_lib_'"$cf_nculib_root"\"
12627 if test "$cf_found_library" = no ; then
12628 { { echo "$as_me:12628: error: Cannot link $cf_nculib_root library" >&5
12629 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
12630 { (exit 1); exit 1; }; }
12635 if test -n "$cf_ncurses_LIBS" ; then
12636 echo "$as_me:12636: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
12637 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
12638 cf_ncurses_SAVE="$LIBS"
12639 for p in $cf_ncurses_LIBS ; do
12640 q=`echo "$LIBS" | sed -e "s%$p %%" -e "s%$p$%%"`
12641 if test "$q" != "$LIBS" ; then
12645 cat >"conftest.$ac_ext" <<_ACEOF
12646 #line 12646 "configure"
12647 #include "confdefs.h"
12648 #include <${cf_cv_ncurses_header:-curses.h}>
12652 initscr(); mousemask(0,0); tigetstr((char *)0);
12657 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
12658 if { (eval echo "$as_me:12658: \"$ac_link\"") >&5
12659 (eval $ac_link) 2>&5
12661 echo "$as_me:12661: \$? = $ac_status" >&5
12662 (exit "$ac_status"); } &&
12663 { ac_try='test -s "conftest$ac_exeext"'
12664 { (eval echo "$as_me:12664: \"$ac_try\"") >&5
12665 (eval $ac_try) 2>&5
12667 echo "$as_me:12667: \$? = $ac_status" >&5
12668 (exit "$ac_status"); }; }; then
12669 echo "$as_me:12669: result: yes" >&5
12670 echo "${ECHO_T}yes" >&6
12672 echo "$as_me: failed program was:" >&5
12673 cat "conftest.$ac_ext" >&5
12674 echo "$as_me:12674: result: no" >&5
12675 echo "${ECHO_T}no" >&6
12676 LIBS="$cf_ncurses_SAVE"
12678 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
12681 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
12683 cat >>confdefs.h <<EOF
12684 #define $cf_nculib_ROOT 1
12689 NCURSES_CONFIG=none
12694 echo "$as_me:12694: checking for X" >&5
12695 echo $ECHO_N "checking for X... $ECHO_C" >&6
12697 # Check whether --with-x or --without-x was given.
12698 if test "${with_x+set}" = set; then
12702 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
12703 if test "x$with_x" = xno; then
12704 # The user explicitly disabled X.
12707 if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
12708 # Both variables are already set.
12711 if test "${ac_cv_have_x+set}" = set; then
12712 echo $ECHO_N "(cached) $ECHO_C" >&6
12714 # One or both of the vars are not set, and there is no cached value.
12715 ac_x_includes=no ac_x_libraries=no
12716 rm -fr conftest.dir
12717 if mkdir conftest.dir; then
12719 # Make sure to not put "make" in the Imakefile rules, since we grep it out.
12720 cat >Imakefile <<'EOF'
12722 @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
12724 if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
12725 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
12726 eval "`${MAKE-make} acfindx 2>/dev/null | grep -v make`"
12727 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
12728 for ac_extension in a so sl dylib dll; do
12729 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
12730 test -f "$ac_im_libdir/libX11.$ac_extension"; then
12731 ac_im_usrlibdir=$ac_im_libdir; break
12734 # Screen out bogus values from the imake configuration. They are
12735 # bogus both because they are the default anyway, and because
12736 # using them would break gcc on systems where it needs fixed includes.
12737 case $ac_im_incroot in
12739 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
12741 case $ac_im_usrlibdir in
12742 /usr/lib | /lib) ;;
12743 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
12747 rm -fr conftest.dir
12750 # Standard set of common directories for X headers.
12751 # Check X11 before X11Rn because it is often a symlink to the current release.
12768 /usr/local/X11/include
12769 /usr/local/X11R7/include
12770 /usr/local/X11R6/include
12771 /usr/local/X11R5/include
12772 /usr/local/X11R4/include
12774 /usr/local/include/X11
12775 /usr/local/include/X11R7
12776 /usr/local/include/X11R6
12777 /usr/local/include/X11R5
12778 /usr/local/include/X11R4
12782 /usr/XFree86/include/X11
12786 /usr/unsupported/include
12787 /usr/athena/include
12788 /usr/local/x11r5/include
12789 /usr/lpp/Xamples/include
12791 /usr/openwin/include
12792 /usr/openwin/share/include'
12794 if test "$ac_x_includes" = no; then
12795 # Guess where to find include files, by looking for Intrinsic.h.
12796 # First, try using that file with no special directory specified.
12797 cat >"conftest.$ac_ext" <<_ACEOF
12798 #line 12798 "configure"
12799 #include "confdefs.h"
12800 #include <X11/Intrinsic.h>
12802 if { (eval echo "$as_me:12802: \"$ac_cpp "conftest.$ac_ext"\"") >&5
12803 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
12805 $EGREP -v '^ *\+' conftest.er1 >conftest.err
12807 cat conftest.err >&5
12808 echo "$as_me:12808: \$? = $ac_status" >&5
12809 (exit "$ac_status"); } >/dev/null; then
12810 if test -s conftest.err; then
12811 ac_cpp_err=$ac_c_preproc_warn_flag
12818 if test -z "$ac_cpp_err"; then
12819 # We can compile using X headers with no special include directory.
12822 echo "$as_me: failed program was:" >&5
12823 cat "conftest.$ac_ext" >&5
12824 for ac_dir in $ac_x_header_dirs; do
12825 if test -r "$ac_dir/X11/Intrinsic.h"; then
12826 ac_x_includes=$ac_dir
12831 rm -f conftest.err "conftest.$ac_ext"
12832 fi # $ac_x_includes = no
12834 if test "$ac_x_libraries" = no; then
12835 # Check for the libraries.
12836 # See if we find them without any special options.
12837 # Don't add to $LIBS permanently.
12840 cat >"conftest.$ac_ext" <<_ACEOF
12841 #line 12841 "configure"
12842 #include "confdefs.h"
12843 #include <X11/Intrinsic.h>
12852 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
12853 if { (eval echo "$as_me:12853: \"$ac_link\"") >&5
12854 (eval $ac_link) 2>&5
12856 echo "$as_me:12856: \$? = $ac_status" >&5
12857 (exit "$ac_status"); } &&
12858 { ac_try='test -s "conftest$ac_exeext"'
12859 { (eval echo "$as_me:12859: \"$ac_try\"") >&5
12860 (eval $ac_try) 2>&5
12862 echo "$as_me:12862: \$? = $ac_status" >&5
12863 (exit "$ac_status"); }; }; then
12865 # We can link X programs with no special library path.
12868 echo "$as_me: failed program was:" >&5
12869 cat "conftest.$ac_ext" >&5
12871 for ac_dir in `echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
12873 # Don't even attempt the hair of trying to link an X program!
12874 for ac_extension in a so sl dylib dll; do
12875 if test -r "$ac_dir/libXt.$ac_extension"; then
12876 ac_x_libraries=$ac_dir
12882 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
12883 fi # $ac_x_libraries = no
12885 if test "$ac_x_includes" = no || test "$ac_x_libraries" = no; then
12886 # Didn't find X anywhere. Cache the known absence of X.
12887 ac_cv_have_x="have_x=no"
12889 # Record where we found X for the cache.
12890 ac_cv_have_x="have_x=yes \
12891 ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
12896 eval "$ac_cv_have_x"
12899 if test "$have_x" != yes; then
12900 echo "$as_me:12900: result: $have_x" >&5
12901 echo "${ECHO_T}$have_x" >&6
12904 # If each of the values was on the command line, it overrides each guess.
12905 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
12906 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
12907 # Update the cache value to reflect the command line values.
12908 ac_cv_have_x="have_x=yes \
12909 ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
12910 echo "$as_me:12910: result: libraries $x_libraries, headers $x_includes" >&5
12911 echo "${ECHO_T}libraries $x_libraries, headers $x_includes" >&6
12914 if test "$no_x" = yes; then
12915 # Not all programs may use this symbol, but it does not hurt to define it.
12917 cat >>confdefs.h <<\EOF
12918 #define X_DISPLAY_MISSING 1
12926 if test -n "$x_includes"; then
12927 X_CFLAGS="$X_CFLAGS -I$x_includes"
12930 # It would also be nice to do this for all -L options, not just this one.
12931 if test -n "$x_libraries"; then
12932 X_LIBS="$X_LIBS -L$x_libraries"
12933 # For Solaris; some versions of Sun CC require a space after -R and
12934 # others require no space. Words are not sufficient . . . .
12935 case `(uname -sr) 2>/dev/null` in
12937 echo "$as_me:12937: checking whether -R must be followed by a space" >&5
12938 echo $ECHO_N "checking whether -R must be followed by a space... $ECHO_C" >&6
12939 ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries"
12940 cat >"conftest.$ac_ext" <<_ACEOF
12941 #line 12941 "configure"
12942 #include "confdefs.h"
12952 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
12953 if { (eval echo "$as_me:12953: \"$ac_link\"") >&5
12954 (eval $ac_link) 2>&5
12956 echo "$as_me:12956: \$? = $ac_status" >&5
12957 (exit "$ac_status"); } &&
12958 { ac_try='test -s "conftest$ac_exeext"'
12959 { (eval echo "$as_me:12959: \"$ac_try\"") >&5
12960 (eval $ac_try) 2>&5
12962 echo "$as_me:12962: \$? = $ac_status" >&5
12963 (exit "$ac_status"); }; }; then
12966 echo "$as_me: failed program was:" >&5
12967 cat "conftest.$ac_ext" >&5
12970 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
12971 if test $ac_R_nospace = yes; then
12972 echo "$as_me:12972: result: no" >&5
12973 echo "${ECHO_T}no" >&6
12974 X_LIBS="$X_LIBS -R$x_libraries"
12976 LIBS="$ac_xsave_LIBS -R $x_libraries"
12977 cat >"conftest.$ac_ext" <<_ACEOF
12978 #line 12978 "configure"
12979 #include "confdefs.h"
12989 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
12990 if { (eval echo "$as_me:12990: \"$ac_link\"") >&5
12991 (eval $ac_link) 2>&5
12993 echo "$as_me:12993: \$? = $ac_status" >&5
12994 (exit "$ac_status"); } &&
12995 { ac_try='test -s "conftest$ac_exeext"'
12996 { (eval echo "$as_me:12996: \"$ac_try\"") >&5
12997 (eval $ac_try) 2>&5
12999 echo "$as_me:12999: \$? = $ac_status" >&5
13000 (exit "$ac_status"); }; }; then
13003 echo "$as_me: failed program was:" >&5
13004 cat "conftest.$ac_ext" >&5
13007 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
13008 if test $ac_R_space = yes; then
13009 echo "$as_me:13009: result: yes" >&5
13010 echo "${ECHO_T}yes" >&6
13011 X_LIBS="$X_LIBS -R $x_libraries"
13013 echo "$as_me:13013: result: neither works" >&5
13014 echo "${ECHO_T}neither works" >&6
13017 LIBS=$ac_xsave_LIBS
13021 # Check for system-dependent libraries X programs must link with.
13022 # Do this before checking for the system-independent R6 libraries
13023 # (-lICE), since we may need -lsocket or whatever for X linking.
13025 if test "$ISC" = yes; then
13026 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
13028 # Martyn Johnson says this is needed for Ultrix, if the X
13029 # libraries were built with DECnet support. And Karl Berry says
13030 # the Alpha needs dnet_stub (dnet does not exist).
13031 ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11"
13032 cat >"conftest.$ac_ext" <<_ACEOF
13033 #line 13033 "configure"
13034 #include "confdefs.h"
13036 /* Override any gcc2 internal prototype to avoid an error. */
13040 /* We use char because int might match the return type of a gcc2
13041 builtin and then its argument prototype would still apply. */
13042 char XOpenDisplay (void);
13051 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
13052 if { (eval echo "$as_me:13052: \"$ac_link\"") >&5
13053 (eval $ac_link) 2>&5
13055 echo "$as_me:13055: \$? = $ac_status" >&5
13056 (exit "$ac_status"); } &&
13057 { ac_try='test -s "conftest$ac_exeext"'
13058 { (eval echo "$as_me:13058: \"$ac_try\"") >&5
13059 (eval $ac_try) 2>&5
13061 echo "$as_me:13061: \$? = $ac_status" >&5
13062 (exit "$ac_status"); }; }; then
13065 echo "$as_me: failed program was:" >&5
13066 cat "conftest.$ac_ext" >&5
13067 echo "$as_me:13067: checking for dnet_ntoa in -ldnet" >&5
13068 echo $ECHO_N "checking for dnet_ntoa in -ldnet... $ECHO_C" >&6
13069 if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then
13070 echo $ECHO_N "(cached) $ECHO_C" >&6
13072 ac_check_lib_save_LIBS=$LIBS
13073 LIBS="-ldnet $LIBS"
13074 cat >"conftest.$ac_ext" <<_ACEOF
13075 #line 13075 "configure"
13076 #include "confdefs.h"
13078 /* Override any gcc2 internal prototype to avoid an error. */
13082 /* We use char because int might match the return type of a gcc2
13083 builtin and then its argument prototype would still apply. */
13084 char dnet_ntoa (void);
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
13105 ac_cv_lib_dnet_dnet_ntoa=yes
13107 echo "$as_me: failed program was:" >&5
13108 cat "conftest.$ac_ext" >&5
13109 ac_cv_lib_dnet_dnet_ntoa=no
13111 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
13112 LIBS=$ac_check_lib_save_LIBS
13114 echo "$as_me:13114: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
13115 echo "${ECHO_T}$ac_cv_lib_dnet_dnet_ntoa" >&6
13116 if test "$ac_cv_lib_dnet_dnet_ntoa" = yes; then
13117 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
13120 if test $ac_cv_lib_dnet_dnet_ntoa = no; then
13121 echo "$as_me:13121: checking for dnet_ntoa in -ldnet_stub" >&5
13122 echo $ECHO_N "checking for dnet_ntoa in -ldnet_stub... $ECHO_C" >&6
13123 if test "${ac_cv_lib_dnet_stub_dnet_ntoa+set}" = set; then
13124 echo $ECHO_N "(cached) $ECHO_C" >&6
13126 ac_check_lib_save_LIBS=$LIBS
13127 LIBS="-ldnet_stub $LIBS"
13128 cat >"conftest.$ac_ext" <<_ACEOF
13129 #line 13129 "configure"
13130 #include "confdefs.h"
13132 /* Override any gcc2 internal prototype to avoid an error. */
13136 /* We use char because int might match the return type of a gcc2
13137 builtin and then its argument prototype would still apply. */
13138 char dnet_ntoa (void);
13147 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
13148 if { (eval echo "$as_me:13148: \"$ac_link\"") >&5
13149 (eval $ac_link) 2>&5
13151 echo "$as_me:13151: \$? = $ac_status" >&5
13152 (exit "$ac_status"); } &&
13153 { ac_try='test -s "conftest$ac_exeext"'
13154 { (eval echo "$as_me:13154: \"$ac_try\"") >&5
13155 (eval $ac_try) 2>&5
13157 echo "$as_me:13157: \$? = $ac_status" >&5
13158 (exit "$ac_status"); }; }; then
13159 ac_cv_lib_dnet_stub_dnet_ntoa=yes
13161 echo "$as_me: failed program was:" >&5
13162 cat "conftest.$ac_ext" >&5
13163 ac_cv_lib_dnet_stub_dnet_ntoa=no
13165 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
13166 LIBS=$ac_check_lib_save_LIBS
13168 echo "$as_me:13168: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5
13169 echo "${ECHO_T}$ac_cv_lib_dnet_stub_dnet_ntoa" >&6
13170 if test "$ac_cv_lib_dnet_stub_dnet_ntoa" = yes; then
13171 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
13176 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
13177 LIBS="$ac_xsave_LIBS"
13179 # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT,
13180 # to get the SysV transport functions.
13181 # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4)
13183 # The nsl library prevents programs from opening the X display
13184 # on Irix 5.2, according to T.E. Dickey.
13185 # The functions gethostbyname, getservbyname, and inet_addr are
13186 # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking.
13187 echo "$as_me:13187: checking for gethostbyname" >&5
13188 echo $ECHO_N "checking for gethostbyname... $ECHO_C" >&6
13189 if test "${ac_cv_func_gethostbyname+set}" = set; then
13190 echo $ECHO_N "(cached) $ECHO_C" >&6
13192 cat >"conftest.$ac_ext" <<_ACEOF
13193 #line 13193 "configure"
13194 #include "confdefs.h"
13195 #define gethostbyname autoconf_temporary
13196 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
13197 #undef gethostbyname
13203 /* We use char because int might match the return type of a gcc2
13204 builtin and then its argument prototype would still apply. */
13205 char gethostbyname (void);
13211 /* The GNU C library defines stubs for functions which it implements
13212 to always fail with ENOSYS. Some functions are actually named
13213 something starting with __ and the normal name is an alias. */
13214 #if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
13215 #error found stub for gethostbyname
13218 return gethostbyname ();
13223 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
13224 if { (eval echo "$as_me:13224: \"$ac_link\"") >&5
13225 (eval $ac_link) 2>&5
13227 echo "$as_me:13227: \$? = $ac_status" >&5
13228 (exit "$ac_status"); } &&
13229 { ac_try='test -s "conftest$ac_exeext"'
13230 { (eval echo "$as_me:13230: \"$ac_try\"") >&5
13231 (eval $ac_try) 2>&5
13233 echo "$as_me:13233: \$? = $ac_status" >&5
13234 (exit "$ac_status"); }; }; then
13235 ac_cv_func_gethostbyname=yes
13237 echo "$as_me: failed program was:" >&5
13238 cat "conftest.$ac_ext" >&5
13239 ac_cv_func_gethostbyname=no
13241 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
13243 echo "$as_me:13243: result: $ac_cv_func_gethostbyname" >&5
13244 echo "${ECHO_T}$ac_cv_func_gethostbyname" >&6
13246 if test $ac_cv_func_gethostbyname = no; then
13247 echo "$as_me:13247: checking for gethostbyname in -lnsl" >&5
13248 echo $ECHO_N "checking for gethostbyname in -lnsl... $ECHO_C" >&6
13249 if test "${ac_cv_lib_nsl_gethostbyname+set}" = set; then
13250 echo $ECHO_N "(cached) $ECHO_C" >&6
13252 ac_check_lib_save_LIBS=$LIBS
13254 cat >"conftest.$ac_ext" <<_ACEOF
13255 #line 13255 "configure"
13256 #include "confdefs.h"
13258 /* Override any gcc2 internal prototype to avoid an error. */
13262 /* We use char because int might match the return type of a gcc2
13263 builtin and then its argument prototype would still apply. */
13264 char gethostbyname (void);
13273 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
13274 if { (eval echo "$as_me:13274: \"$ac_link\"") >&5
13275 (eval $ac_link) 2>&5
13277 echo "$as_me:13277: \$? = $ac_status" >&5
13278 (exit "$ac_status"); } &&
13279 { ac_try='test -s "conftest$ac_exeext"'
13280 { (eval echo "$as_me:13280: \"$ac_try\"") >&5
13281 (eval $ac_try) 2>&5
13283 echo "$as_me:13283: \$? = $ac_status" >&5
13284 (exit "$ac_status"); }; }; then
13285 ac_cv_lib_nsl_gethostbyname=yes
13287 echo "$as_me: failed program was:" >&5
13288 cat "conftest.$ac_ext" >&5
13289 ac_cv_lib_nsl_gethostbyname=no
13291 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
13292 LIBS=$ac_check_lib_save_LIBS
13294 echo "$as_me:13294: result: $ac_cv_lib_nsl_gethostbyname" >&5
13295 echo "${ECHO_T}$ac_cv_lib_nsl_gethostbyname" >&6
13296 if test "$ac_cv_lib_nsl_gethostbyname" = yes; then
13297 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
13300 if test $ac_cv_lib_nsl_gethostbyname = no; then
13301 echo "$as_me:13301: checking for gethostbyname in -lbsd" >&5
13302 echo $ECHO_N "checking for gethostbyname in -lbsd... $ECHO_C" >&6
13303 if test "${ac_cv_lib_bsd_gethostbyname+set}" = set; then
13304 echo $ECHO_N "(cached) $ECHO_C" >&6
13306 ac_check_lib_save_LIBS=$LIBS
13308 cat >"conftest.$ac_ext" <<_ACEOF
13309 #line 13309 "configure"
13310 #include "confdefs.h"
13312 /* Override any gcc2 internal prototype to avoid an error. */
13316 /* We use char because int might match the return type of a gcc2
13317 builtin and then its argument prototype would still apply. */
13318 char gethostbyname (void);
13327 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
13328 if { (eval echo "$as_me:13328: \"$ac_link\"") >&5
13329 (eval $ac_link) 2>&5
13331 echo "$as_me:13331: \$? = $ac_status" >&5
13332 (exit "$ac_status"); } &&
13333 { ac_try='test -s "conftest$ac_exeext"'
13334 { (eval echo "$as_me:13334: \"$ac_try\"") >&5
13335 (eval $ac_try) 2>&5
13337 echo "$as_me:13337: \$? = $ac_status" >&5
13338 (exit "$ac_status"); }; }; then
13339 ac_cv_lib_bsd_gethostbyname=yes
13341 echo "$as_me: failed program was:" >&5
13342 cat "conftest.$ac_ext" >&5
13343 ac_cv_lib_bsd_gethostbyname=no
13345 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
13346 LIBS=$ac_check_lib_save_LIBS
13348 echo "$as_me:13348: result: $ac_cv_lib_bsd_gethostbyname" >&5
13349 echo "${ECHO_T}$ac_cv_lib_bsd_gethostbyname" >&6
13350 if test "$ac_cv_lib_bsd_gethostbyname" = yes; then
13351 X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd"
13357 # lieder@skyler.mavd.honeywell.com says without -lsocket,
13358 # socket/setsockopt and other routines are undefined under SCO ODT
13359 # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary
13360 # on later versions), says Simon Leinen: it contains gethostby*
13361 # variants that don't use the nameserver (or something). -lsocket
13362 # must be given before -lnsl if both are needed. We assume that
13363 # if connect needs -lnsl, so does gethostbyname.
13364 echo "$as_me:13364: checking for connect" >&5
13365 echo $ECHO_N "checking for connect... $ECHO_C" >&6
13366 if test "${ac_cv_func_connect+set}" = set; then
13367 echo $ECHO_N "(cached) $ECHO_C" >&6
13369 cat >"conftest.$ac_ext" <<_ACEOF
13370 #line 13370 "configure"
13371 #include "confdefs.h"
13372 #define connect autoconf_temporary
13373 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
13380 /* We use char because int might match the return type of a gcc2
13381 builtin and then its argument prototype would still apply. */
13382 char connect (void);
13388 /* The GNU C library defines stubs for functions which it implements
13389 to always fail with ENOSYS. Some functions are actually named
13390 something starting with __ and the normal name is an alias. */
13391 #if defined (__stub_connect) || defined (__stub___connect)
13392 #error found stub for connect
13400 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
13401 if { (eval echo "$as_me:13401: \"$ac_link\"") >&5
13402 (eval $ac_link) 2>&5
13404 echo "$as_me:13404: \$? = $ac_status" >&5
13405 (exit "$ac_status"); } &&
13406 { ac_try='test -s "conftest$ac_exeext"'
13407 { (eval echo "$as_me:13407: \"$ac_try\"") >&5
13408 (eval $ac_try) 2>&5
13410 echo "$as_me:13410: \$? = $ac_status" >&5
13411 (exit "$ac_status"); }; }; then
13412 ac_cv_func_connect=yes
13414 echo "$as_me: failed program was:" >&5
13415 cat "conftest.$ac_ext" >&5
13416 ac_cv_func_connect=no
13418 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
13420 echo "$as_me:13420: result: $ac_cv_func_connect" >&5
13421 echo "${ECHO_T}$ac_cv_func_connect" >&6
13423 if test $ac_cv_func_connect = no; then
13424 echo "$as_me:13424: checking for connect in -lsocket" >&5
13425 echo $ECHO_N "checking for connect in -lsocket... $ECHO_C" >&6
13426 if test "${ac_cv_lib_socket_connect+set}" = set; then
13427 echo $ECHO_N "(cached) $ECHO_C" >&6
13429 ac_check_lib_save_LIBS=$LIBS
13430 LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
13431 cat >"conftest.$ac_ext" <<_ACEOF
13432 #line 13432 "configure"
13433 #include "confdefs.h"
13435 /* Override any gcc2 internal prototype to avoid an error. */
13439 /* We use char because int might match the return type of a gcc2
13440 builtin and then its argument prototype would still apply. */
13441 char connect (void);
13450 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
13451 if { (eval echo "$as_me:13451: \"$ac_link\"") >&5
13452 (eval $ac_link) 2>&5
13454 echo "$as_me:13454: \$? = $ac_status" >&5
13455 (exit "$ac_status"); } &&
13456 { ac_try='test -s "conftest$ac_exeext"'
13457 { (eval echo "$as_me:13457: \"$ac_try\"") >&5
13458 (eval $ac_try) 2>&5
13460 echo "$as_me:13460: \$? = $ac_status" >&5
13461 (exit "$ac_status"); }; }; then
13462 ac_cv_lib_socket_connect=yes
13464 echo "$as_me: failed program was:" >&5
13465 cat "conftest.$ac_ext" >&5
13466 ac_cv_lib_socket_connect=no
13468 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
13469 LIBS=$ac_check_lib_save_LIBS
13471 echo "$as_me:13471: result: $ac_cv_lib_socket_connect" >&5
13472 echo "${ECHO_T}$ac_cv_lib_socket_connect" >&6
13473 if test "$ac_cv_lib_socket_connect" = yes; then
13474 X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS"
13479 # Guillermo Gomez says -lposix is necessary on A/UX.
13480 echo "$as_me:13480: checking for remove" >&5
13481 echo $ECHO_N "checking for remove... $ECHO_C" >&6
13482 if test "${ac_cv_func_remove+set}" = set; then
13483 echo $ECHO_N "(cached) $ECHO_C" >&6
13485 cat >"conftest.$ac_ext" <<_ACEOF
13486 #line 13486 "configure"
13487 #include "confdefs.h"
13488 #define remove autoconf_temporary
13489 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
13496 /* We use char because int might match the return type of a gcc2
13497 builtin and then its argument prototype would still apply. */
13498 char remove (void);
13504 /* The GNU C library defines stubs for functions which it implements
13505 to always fail with ENOSYS. Some functions are actually named
13506 something starting with __ and the normal name is an alias. */
13507 #if defined (__stub_remove) || defined (__stub___remove)
13508 #error found stub for remove
13516 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
13517 if { (eval echo "$as_me:13517: \"$ac_link\"") >&5
13518 (eval $ac_link) 2>&5
13520 echo "$as_me:13520: \$? = $ac_status" >&5
13521 (exit "$ac_status"); } &&
13522 { ac_try='test -s "conftest$ac_exeext"'
13523 { (eval echo "$as_me:13523: \"$ac_try\"") >&5
13524 (eval $ac_try) 2>&5
13526 echo "$as_me:13526: \$? = $ac_status" >&5
13527 (exit "$ac_status"); }; }; then
13528 ac_cv_func_remove=yes
13530 echo "$as_me: failed program was:" >&5
13531 cat "conftest.$ac_ext" >&5
13532 ac_cv_func_remove=no
13534 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
13536 echo "$as_me:13536: result: $ac_cv_func_remove" >&5
13537 echo "${ECHO_T}$ac_cv_func_remove" >&6
13539 if test $ac_cv_func_remove = no; then
13540 echo "$as_me:13540: checking for remove in -lposix" >&5
13541 echo $ECHO_N "checking for remove in -lposix... $ECHO_C" >&6
13542 if test "${ac_cv_lib_posix_remove+set}" = set; then
13543 echo $ECHO_N "(cached) $ECHO_C" >&6
13545 ac_check_lib_save_LIBS=$LIBS
13546 LIBS="-lposix $LIBS"
13547 cat >"conftest.$ac_ext" <<_ACEOF
13548 #line 13548 "configure"
13549 #include "confdefs.h"
13551 /* Override any gcc2 internal prototype to avoid an error. */
13555 /* We use char because int might match the return type of a gcc2
13556 builtin and then its argument prototype would still apply. */
13557 char remove (void);
13566 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
13567 if { (eval echo "$as_me:13567: \"$ac_link\"") >&5
13568 (eval $ac_link) 2>&5
13570 echo "$as_me:13570: \$? = $ac_status" >&5
13571 (exit "$ac_status"); } &&
13572 { ac_try='test -s "conftest$ac_exeext"'
13573 { (eval echo "$as_me:13573: \"$ac_try\"") >&5
13574 (eval $ac_try) 2>&5
13576 echo "$as_me:13576: \$? = $ac_status" >&5
13577 (exit "$ac_status"); }; }; then
13578 ac_cv_lib_posix_remove=yes
13580 echo "$as_me: failed program was:" >&5
13581 cat "conftest.$ac_ext" >&5
13582 ac_cv_lib_posix_remove=no
13584 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
13585 LIBS=$ac_check_lib_save_LIBS
13587 echo "$as_me:13587: result: $ac_cv_lib_posix_remove" >&5
13588 echo "${ECHO_T}$ac_cv_lib_posix_remove" >&6
13589 if test "$ac_cv_lib_posix_remove" = yes; then
13590 X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix"
13595 # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
13596 echo "$as_me:13596: checking for shmat" >&5
13597 echo $ECHO_N "checking for shmat... $ECHO_C" >&6
13598 if test "${ac_cv_func_shmat+set}" = set; then
13599 echo $ECHO_N "(cached) $ECHO_C" >&6
13601 cat >"conftest.$ac_ext" <<_ACEOF
13602 #line 13602 "configure"
13603 #include "confdefs.h"
13604 #define shmat autoconf_temporary
13605 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
13612 /* We use char because int might match the return type of a gcc2
13613 builtin and then its argument prototype would still apply. */
13620 /* The GNU C library defines stubs for functions which it implements
13621 to always fail with ENOSYS. Some functions are actually named
13622 something starting with __ and the normal name is an alias. */
13623 #if defined (__stub_shmat) || defined (__stub___shmat)
13624 #error found stub for shmat
13632 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
13633 if { (eval echo "$as_me:13633: \"$ac_link\"") >&5
13634 (eval $ac_link) 2>&5
13636 echo "$as_me:13636: \$? = $ac_status" >&5
13637 (exit "$ac_status"); } &&
13638 { ac_try='test -s "conftest$ac_exeext"'
13639 { (eval echo "$as_me:13639: \"$ac_try\"") >&5
13640 (eval $ac_try) 2>&5
13642 echo "$as_me:13642: \$? = $ac_status" >&5
13643 (exit "$ac_status"); }; }; then
13644 ac_cv_func_shmat=yes
13646 echo "$as_me: failed program was:" >&5
13647 cat "conftest.$ac_ext" >&5
13648 ac_cv_func_shmat=no
13650 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
13652 echo "$as_me:13652: result: $ac_cv_func_shmat" >&5
13653 echo "${ECHO_T}$ac_cv_func_shmat" >&6
13655 if test $ac_cv_func_shmat = no; then
13656 echo "$as_me:13656: checking for shmat in -lipc" >&5
13657 echo $ECHO_N "checking for shmat in -lipc... $ECHO_C" >&6
13658 if test "${ac_cv_lib_ipc_shmat+set}" = set; then
13659 echo $ECHO_N "(cached) $ECHO_C" >&6
13661 ac_check_lib_save_LIBS=$LIBS
13663 cat >"conftest.$ac_ext" <<_ACEOF
13664 #line 13664 "configure"
13665 #include "confdefs.h"
13667 /* Override any gcc2 internal prototype to avoid an error. */
13671 /* We use char because int might match the return type of a gcc2
13672 builtin and then its argument prototype would still apply. */
13682 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
13683 if { (eval echo "$as_me:13683: \"$ac_link\"") >&5
13684 (eval $ac_link) 2>&5
13686 echo "$as_me:13686: \$? = $ac_status" >&5
13687 (exit "$ac_status"); } &&
13688 { ac_try='test -s "conftest$ac_exeext"'
13689 { (eval echo "$as_me:13689: \"$ac_try\"") >&5
13690 (eval $ac_try) 2>&5
13692 echo "$as_me:13692: \$? = $ac_status" >&5
13693 (exit "$ac_status"); }; }; then
13694 ac_cv_lib_ipc_shmat=yes
13696 echo "$as_me: failed program was:" >&5
13697 cat "conftest.$ac_ext" >&5
13698 ac_cv_lib_ipc_shmat=no
13700 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
13701 LIBS=$ac_check_lib_save_LIBS
13703 echo "$as_me:13703: result: $ac_cv_lib_ipc_shmat" >&5
13704 echo "${ECHO_T}$ac_cv_lib_ipc_shmat" >&6
13705 if test "$ac_cv_lib_ipc_shmat" = yes; then
13706 X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc"
13712 # Check for libraries that X11R6 Xt/Xaw programs need.
13713 ac_save_LDFLAGS=$LDFLAGS
13714 test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries"
13715 # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
13716 # check for ICE first), but we must link in the order -lSM -lICE or
13717 # we get undefined symbols. So assume we have SM if we have ICE.
13718 # These have to be linked with before -lX11, unlike the other
13719 # libraries we check for below, so use a different variable.
13720 # John Interrante, Karl Berry
13721 echo "$as_me:13721: checking for IceConnectionNumber in -lICE" >&5
13722 echo $ECHO_N "checking for IceConnectionNumber in -lICE... $ECHO_C" >&6
13723 if test "${ac_cv_lib_ICE_IceConnectionNumber+set}" = set; then
13724 echo $ECHO_N "(cached) $ECHO_C" >&6
13726 ac_check_lib_save_LIBS=$LIBS
13727 LIBS="-lICE $X_EXTRA_LIBS $LIBS"
13728 cat >"conftest.$ac_ext" <<_ACEOF
13729 #line 13729 "configure"
13730 #include "confdefs.h"
13732 /* Override any gcc2 internal prototype to avoid an error. */
13736 /* We use char because int might match the return type of a gcc2
13737 builtin and then its argument prototype would still apply. */
13738 char IceConnectionNumber (void);
13742 IceConnectionNumber ();
13747 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
13748 if { (eval echo "$as_me:13748: \"$ac_link\"") >&5
13749 (eval $ac_link) 2>&5
13751 echo "$as_me:13751: \$? = $ac_status" >&5
13752 (exit "$ac_status"); } &&
13753 { ac_try='test -s "conftest$ac_exeext"'
13754 { (eval echo "$as_me:13754: \"$ac_try\"") >&5
13755 (eval $ac_try) 2>&5
13757 echo "$as_me:13757: \$? = $ac_status" >&5
13758 (exit "$ac_status"); }; }; then
13759 ac_cv_lib_ICE_IceConnectionNumber=yes
13761 echo "$as_me: failed program was:" >&5
13762 cat "conftest.$ac_ext" >&5
13763 ac_cv_lib_ICE_IceConnectionNumber=no
13765 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
13766 LIBS=$ac_check_lib_save_LIBS
13768 echo "$as_me:13768: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5
13769 echo "${ECHO_T}$ac_cv_lib_ICE_IceConnectionNumber" >&6
13770 if test "$ac_cv_lib_ICE_IceConnectionNumber" = yes; then
13771 X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
13774 LDFLAGS=$ac_save_LDFLAGS
13778 cf_x_athena=${cf_x_athena:-Xaw}
13780 echo "$as_me:13780: checking if you want to link with Xaw 3d library" >&5
13781 echo $ECHO_N "checking if you want to link with Xaw 3d library... $ECHO_C" >&6
13784 # Check whether --with-Xaw3d or --without-Xaw3d was given.
13785 if test "${with_Xaw3d+set}" = set; then
13786 withval="$with_Xaw3d"
13789 if test "$withval" = yes ; then
13791 echo "$as_me:13791: result: yes" >&5
13792 echo "${ECHO_T}yes" >&6
13794 echo "$as_me:13794: result: no" >&5
13795 echo "${ECHO_T}no" >&6
13798 echo "$as_me:13798: checking if you want to link with Xaw 3d xft library" >&5
13799 echo $ECHO_N "checking if you want to link with Xaw 3d xft library... $ECHO_C" >&6
13802 # Check whether --with-Xaw3dxft or --without-Xaw3dxft was given.
13803 if test "${with_Xaw3dxft+set}" = set; then
13804 withval="$with_Xaw3dxft"
13807 if test "$withval" = yes ; then
13808 cf_x_athena=Xaw3dxft
13809 echo "$as_me:13809: result: yes" >&5
13810 echo "${ECHO_T}yes" >&6
13812 echo "$as_me:13812: result: no" >&5
13813 echo "${ECHO_T}no" >&6
13816 echo "$as_me:13816: checking if you want to link with neXT Athena library" >&5
13817 echo $ECHO_N "checking if you want to link with neXT Athena library... $ECHO_C" >&6
13820 # Check whether --with-neXtaw or --without-neXtaw was given.
13821 if test "${with_neXtaw+set}" = set; then
13822 withval="$with_neXtaw"
13825 if test "$withval" = yes ; then
13827 echo "$as_me:13827: result: yes" >&5
13828 echo "${ECHO_T}yes" >&6
13830 echo "$as_me:13830: result: no" >&5
13831 echo "${ECHO_T}no" >&6
13834 echo "$as_me:13834: checking if you want to link with Athena-Plus library" >&5
13835 echo $ECHO_N "checking if you want to link with Athena-Plus library... $ECHO_C" >&6
13838 # Check whether --with-XawPlus or --without-XawPlus was given.
13839 if test "${with_XawPlus+set}" = set; then
13840 withval="$with_XawPlus"
13843 if test "$withval" = yes ; then
13844 cf_x_athena=XawPlus
13845 echo "$as_me:13845: result: yes" >&5
13846 echo "${ECHO_T}yes" >&6
13848 echo "$as_me:13848: result: no" >&5
13849 echo "${ECHO_T}no" >&6
13854 if test "$PKG_CONFIG" != none ; then
13856 test "$cf_x_athena" = Xaw && cf_athena_list="xaw8 xaw7 xaw6"
13857 for cf_athena_pkg in \
13860 ${cf_x_athena}-devel \
13861 lib${cf_x_athena} \
13862 lib${cf_x_athena}-devel
13865 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "$cf_athena_pkg"; then
13866 test -n "$verbose" && echo " found package $cf_athena_pkg" 1>&6
13868 echo "${as_me:-configure}:13868: testing found package $cf_athena_pkg ..." 1>&5
13870 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "$cf_athena_pkg" 2>/dev/null`"
13871 cf_pkgconfig_libs="`$PKG_CONFIG --libs "$cf_athena_pkg" 2>/dev/null`"
13872 test -n "$verbose" && echo " package $cf_athena_pkg CFLAGS: $cf_pkgconfig_incs" 1>&6
13874 echo "${as_me:-configure}:13874: testing package $cf_athena_pkg CFLAGS: $cf_pkgconfig_incs ..." 1>&5
13876 test -n "$verbose" && echo " package $cf_athena_pkg LIBS: $cf_pkgconfig_libs" 1>&6
13878 echo "${as_me:-configure}:13878: testing package $cf_athena_pkg LIBS: $cf_pkgconfig_libs ..." 1>&5
13883 cf_new_extra_cppflags=
13885 for cf_add_cflags in $cf_pkgconfig_incs
13887 case "$cf_fix_cppflags" in
13889 case "$cf_add_cflags" in
13890 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
13891 case "$cf_add_cflags" in
13893 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
13895 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13896 && test -z "${cf_tst_cflags}" \
13897 && cf_fix_cppflags=yes
13899 if test "$cf_fix_cppflags" = yes ; then
13901 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13902 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13905 elif test "${cf_tst_cflags}" = "\"'" ; then
13907 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13908 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13914 case "$CPPFLAGS" in
13918 case "$cf_add_cflags" in
13920 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
13922 CPPFLAGS=`echo "$CPPFLAGS" | \
13923 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
13924 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
13929 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
13930 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
13937 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
13938 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
13945 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13946 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13948 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
13950 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13951 && test -z "${cf_tst_cflags}" \
13952 && cf_fix_cppflags=no
13957 if test -n "$cf_new_cflags" ; then
13959 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
13960 CFLAGS="${CFLAGS}$cf_new_cflags"
13964 if test -n "$cf_new_cppflags" ; then
13966 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13967 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
13971 if test -n "$cf_new_extra_cppflags" ; then
13973 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
13974 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
13978 cf_add_libs="$LIBS"
13981 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
13982 # filter duplicates
13983 for cf_add_1lib in $cf_add_0lib; do
13984 for cf_add_2lib in $cf_add_libs; do
13985 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
13990 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
13992 LIBS="$cf_add_libs"
13994 cf_x_athena_lib="$cf_pkgconfig_libs"
13996 cf_x_athena_LIBS=`echo "HAVE_LIB_$cf_x_athena" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
13998 cat >>confdefs.h <<EOF
13999 #define $cf_x_athena_LIBS 1
14002 for cf_trim_lib in Xmu Xt X11
14005 (*-l$cf_trim_lib\ *-l$cf_trim_lib*)
14006 LIBS=`echo "$LIBS " | sed -e 's/ / /g' -e 's%-l'"$cf_trim_lib"' %%' -e 's/ $//'`
14007 test -n "$verbose" && echo " ..trimmed $LIBS" 1>&6
14009 echo "${as_me:-configure}:14009: testing ..trimmed $LIBS ..." 1>&5
14015 echo "$as_me:14015: checking for usable $cf_x_athena/Xmu package" >&5
14016 echo $ECHO_N "checking for usable $cf_x_athena/Xmu package... $ECHO_C" >&6
14017 if test "${cf_cv_xaw_compat+set}" = set; then
14018 echo $ECHO_N "(cached) $ECHO_C" >&6
14021 cat >"conftest.$ac_ext" <<_ACEOF
14022 #line 14022 "configure"
14023 #include "confdefs.h"
14025 $ac_includes_default
14026 #include <X11/Xmu/CharSet.h>
14032 int check = XmuCompareISOLatin1("big", "small");
14039 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
14040 if { (eval echo "$as_me:14040: \"$ac_link\"") >&5
14041 (eval $ac_link) 2>&5
14043 echo "$as_me:14043: \$? = $ac_status" >&5
14044 (exit "$ac_status"); } &&
14045 { ac_try='test -s "conftest$ac_exeext"'
14046 { (eval echo "$as_me:14046: \"$ac_try\"") >&5
14047 (eval $ac_try) 2>&5
14049 echo "$as_me:14049: \$? = $ac_status" >&5
14050 (exit "$ac_status"); }; }; then
14051 cf_cv_xaw_compat=yes
14053 echo "$as_me: failed program was:" >&5
14054 cat "conftest.$ac_ext" >&5
14055 cf_cv_xaw_compat=no
14057 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
14059 echo "$as_me:14059: result: $cf_cv_xaw_compat" >&5
14060 echo "${ECHO_T}$cf_cv_xaw_compat" >&6
14062 if test "$cf_cv_xaw_compat" = no
14064 # workaround for broken ".pc" files...
14065 case "$cf_x_athena_lib" in
14069 test -n "$verbose" && echo " work around broken package" 1>&6
14071 echo "${as_me:-configure}:14071: testing work around broken package ..." 1>&5
14073 cf_save_xmu="$LIBS"
14074 cf_first_lib=`echo "$cf_save_xmu" | sed -e 's/^ *//' -e 's/ .*//'`
14076 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "xmu"; then
14077 test -n "$verbose" && echo " found package xmu" 1>&6
14079 echo "${as_me:-configure}:14079: testing found package xmu ..." 1>&5
14081 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "xmu" 2>/dev/null`"
14082 cf_pkgconfig_libs="`$PKG_CONFIG --libs "xmu" 2>/dev/null`"
14083 test -n "$verbose" && echo " package xmu CFLAGS: $cf_pkgconfig_incs" 1>&6
14085 echo "${as_me:-configure}:14085: testing package xmu CFLAGS: $cf_pkgconfig_incs ..." 1>&5
14087 test -n "$verbose" && echo " package xmu LIBS: $cf_pkgconfig_libs" 1>&6
14089 echo "${as_me:-configure}:14089: testing package xmu LIBS: $cf_pkgconfig_libs ..." 1>&5
14094 cf_new_extra_cppflags=
14096 for cf_add_cflags in $cf_pkgconfig_incs
14098 case "$cf_fix_cppflags" in
14100 case "$cf_add_cflags" in
14101 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
14102 case "$cf_add_cflags" in
14104 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
14106 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14107 && test -z "${cf_tst_cflags}" \
14108 && cf_fix_cppflags=yes
14110 if test "$cf_fix_cppflags" = yes ; then
14112 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14113 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14116 elif test "${cf_tst_cflags}" = "\"'" ; then
14118 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14119 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14125 case "$CPPFLAGS" in
14129 case "$cf_add_cflags" in
14131 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
14133 CPPFLAGS=`echo "$CPPFLAGS" | \
14134 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
14135 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
14140 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
14141 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
14148 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
14149 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
14156 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14157 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14159 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
14161 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14162 && test -z "${cf_tst_cflags}" \
14163 && cf_fix_cppflags=no
14168 if test -n "$cf_new_cflags" ; then
14170 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
14171 CFLAGS="${CFLAGS}$cf_new_cflags"
14175 if test -n "$cf_new_cppflags" ; then
14177 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
14178 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
14182 if test -n "$cf_new_extra_cppflags" ; then
14184 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
14185 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
14189 cf_add_libs="$LIBS"
14192 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
14193 # filter duplicates
14194 for cf_add_1lib in $cf_add_0lib; do
14195 for cf_add_2lib in $cf_add_libs; do
14196 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
14201 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
14203 LIBS="$cf_add_libs"
14205 LIBS="$cf_save_xmu"
14207 test -n "$verbose" && echo " ...before $LIBS" 1>&6
14209 echo "${as_me:-configure}:14209: testing ...before $LIBS ..." 1>&5
14211 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%$cf_first_lib %$cf_first_lib $cf_pkgconfig_libs %" -e 's% % %g'`
14212 test -n "$verbose" && echo " ...after $LIBS" 1>&6
14214 echo "${as_me:-configure}:14214: testing ...after $LIBS ..." 1>&5
14220 test -n "$verbose" && echo " ...before $LIBS" 1>&6
14222 echo "${as_me:-configure}:14222: testing ...before $LIBS ..." 1>&5
14224 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%$cf_first_lib %$cf_first_lib -lXmu %" -e 's% % %g'`
14225 test -n "$verbose" && echo " ...after $LIBS" 1>&6
14227 echo "${as_me:-configure}:14227: testing ...after $LIBS ..." 1>&5
14231 for cf_trim_lib in Xmu Xt X11
14234 (*-l$cf_trim_lib\ *-l$cf_trim_lib*)
14235 LIBS=`echo "$LIBS " | sed -e 's/ / /g' -e 's%-l'"$cf_trim_lib"' %%' -e 's/ $//'`
14236 test -n "$verbose" && echo " ..trimmed $LIBS" 1>&6
14238 echo "${as_me:-configure}:14238: testing ..trimmed $LIBS ..." 1>&5
14258 if test -z "$cf_x_athena_lib" ; then
14260 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "Xext"; then
14261 test -n "$verbose" && echo " found package Xext" 1>&6
14263 echo "${as_me:-configure}:14263: testing found package Xext ..." 1>&5
14265 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "Xext" 2>/dev/null`"
14266 cf_pkgconfig_libs="`$PKG_CONFIG --libs "Xext" 2>/dev/null`"
14267 test -n "$verbose" && echo " package Xext CFLAGS: $cf_pkgconfig_incs" 1>&6
14269 echo "${as_me:-configure}:14269: testing package Xext CFLAGS: $cf_pkgconfig_incs ..." 1>&5
14271 test -n "$verbose" && echo " package Xext LIBS: $cf_pkgconfig_libs" 1>&6
14273 echo "${as_me:-configure}:14273: testing package Xext LIBS: $cf_pkgconfig_libs ..." 1>&5
14278 cf_new_extra_cppflags=
14280 for cf_add_cflags in $cf_pkgconfig_incs
14282 case "$cf_fix_cppflags" in
14284 case "$cf_add_cflags" in
14285 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
14286 case "$cf_add_cflags" in
14288 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
14290 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14291 && test -z "${cf_tst_cflags}" \
14292 && cf_fix_cppflags=yes
14294 if test "$cf_fix_cppflags" = yes ; then
14296 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14297 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14300 elif test "${cf_tst_cflags}" = "\"'" ; then
14302 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14303 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14309 case "$CPPFLAGS" in
14313 case "$cf_add_cflags" in
14315 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
14317 CPPFLAGS=`echo "$CPPFLAGS" | \
14318 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
14319 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
14324 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
14325 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
14332 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
14333 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
14340 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14341 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14343 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
14345 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14346 && test -z "${cf_tst_cflags}" \
14347 && cf_fix_cppflags=no
14352 if test -n "$cf_new_cflags" ; then
14354 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
14355 CFLAGS="${CFLAGS}$cf_new_cflags"
14359 if test -n "$cf_new_cppflags" ; then
14361 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
14362 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
14366 if test -n "$cf_new_extra_cppflags" ; then
14368 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
14369 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
14373 cf_add_libs="$LIBS"
14376 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
14377 # filter duplicates
14378 for cf_add_1lib in $cf_add_0lib; do
14379 for cf_add_2lib in $cf_add_libs; do
14380 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
14385 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
14387 LIBS="$cf_add_libs"
14394 echo "$as_me:14394: checking for XextCreateExtension in -lXext" >&5
14395 echo $ECHO_N "checking for XextCreateExtension in -lXext... $ECHO_C" >&6
14396 if test "${ac_cv_lib_Xext_XextCreateExtension+set}" = set; then
14397 echo $ECHO_N "(cached) $ECHO_C" >&6
14399 ac_check_lib_save_LIBS=$LIBS
14400 LIBS="-lXext $LIBS"
14401 cat >"conftest.$ac_ext" <<_ACEOF
14402 #line 14402 "configure"
14403 #include "confdefs.h"
14405 /* Override any gcc2 internal prototype to avoid an error. */
14409 /* We use char because int might match the return type of a gcc2
14410 builtin and then its argument prototype would still apply. */
14411 char XextCreateExtension (void);
14415 XextCreateExtension ();
14420 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
14421 if { (eval echo "$as_me:14421: \"$ac_link\"") >&5
14422 (eval $ac_link) 2>&5
14424 echo "$as_me:14424: \$? = $ac_status" >&5
14425 (exit "$ac_status"); } &&
14426 { ac_try='test -s "conftest$ac_exeext"'
14427 { (eval echo "$as_me:14427: \"$ac_try\"") >&5
14428 (eval $ac_try) 2>&5
14430 echo "$as_me:14430: \$? = $ac_status" >&5
14431 (exit "$ac_status"); }; }; then
14432 ac_cv_lib_Xext_XextCreateExtension=yes
14434 echo "$as_me: failed program was:" >&5
14435 cat "conftest.$ac_ext" >&5
14436 ac_cv_lib_Xext_XextCreateExtension=no
14438 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
14439 LIBS=$ac_check_lib_save_LIBS
14441 echo "$as_me:14441: result: $ac_cv_lib_Xext_XextCreateExtension" >&5
14442 echo "${ECHO_T}$ac_cv_lib_Xext_XextCreateExtension" >&6
14443 if test "$ac_cv_lib_Xext_XextCreateExtension" = yes; then
14445 cf_add_libs="$LIBS"
14448 for cf_add_1lib in -lXext; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
14449 # filter duplicates
14450 for cf_add_1lib in $cf_add_0lib; do
14451 for cf_add_2lib in $cf_add_libs; do
14452 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
14457 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
14459 LIBS="$cf_add_libs"
14465 # OSX is schizoid about who owns /usr/X11 (old) versus /opt/X11 (new) (and
14466 # in some cases has installed dummy files in the former, other cases replaced
14467 # it with a link to the new location). This complicates the configure script.
14468 # Check for that pitfall, and recover using pkg-config
14470 # If none of these are set, the configuration is almost certainly broken.
14471 if test -z "${X_CFLAGS}${X_PRE_LIBS}${X_LIBS}${X_EXTRA_LIBS}"
14474 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "x11"; then
14475 test -n "$verbose" && echo " found package x11" 1>&6
14477 echo "${as_me:-configure}:14477: testing found package x11 ..." 1>&5
14479 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "x11" 2>/dev/null`"
14480 cf_pkgconfig_libs="`$PKG_CONFIG --libs "x11" 2>/dev/null`"
14481 test -n "$verbose" && echo " package x11 CFLAGS: $cf_pkgconfig_incs" 1>&6
14483 echo "${as_me:-configure}:14483: testing package x11 CFLAGS: $cf_pkgconfig_incs ..." 1>&5
14485 test -n "$verbose" && echo " package x11 LIBS: $cf_pkgconfig_libs" 1>&6
14487 echo "${as_me:-configure}:14487: testing package x11 LIBS: $cf_pkgconfig_libs ..." 1>&5
14492 cf_new_extra_cppflags=
14494 for cf_add_cflags in $cf_pkgconfig_incs
14496 case "$cf_fix_cppflags" in
14498 case "$cf_add_cflags" in
14499 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
14500 case "$cf_add_cflags" in
14502 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
14504 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14505 && test -z "${cf_tst_cflags}" \
14506 && cf_fix_cppflags=yes
14508 if test "$cf_fix_cppflags" = yes ; then
14510 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14511 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14514 elif test "${cf_tst_cflags}" = "\"'" ; then
14516 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14517 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14523 case "$CPPFLAGS" in
14527 case "$cf_add_cflags" in
14529 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
14531 CPPFLAGS=`echo "$CPPFLAGS" | \
14532 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
14533 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
14538 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
14539 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
14546 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
14547 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
14554 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14555 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14557 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
14559 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14560 && test -z "${cf_tst_cflags}" \
14561 && cf_fix_cppflags=no
14566 if test -n "$cf_new_cflags" ; then
14568 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
14569 CFLAGS="${CFLAGS}$cf_new_cflags"
14573 if test -n "$cf_new_cppflags" ; then
14575 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
14576 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
14580 if test -n "$cf_new_extra_cppflags" ; then
14582 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
14583 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
14587 cf_add_libs="$LIBS"
14590 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
14591 # filter duplicates
14592 for cf_add_1lib in $cf_add_0lib; do
14593 for cf_add_2lib in $cf_add_libs; do
14594 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
14599 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
14601 LIBS="$cf_add_libs"
14607 { echo "$as_me:14607: WARNING: unable to find X11 library" >&5
14608 echo "$as_me: WARNING: unable to find X11 library" >&2;}
14611 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "ice"; then
14612 test -n "$verbose" && echo " found package ice" 1>&6
14614 echo "${as_me:-configure}:14614: testing found package ice ..." 1>&5
14616 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "ice" 2>/dev/null`"
14617 cf_pkgconfig_libs="`$PKG_CONFIG --libs "ice" 2>/dev/null`"
14618 test -n "$verbose" && echo " package ice CFLAGS: $cf_pkgconfig_incs" 1>&6
14620 echo "${as_me:-configure}:14620: testing package ice CFLAGS: $cf_pkgconfig_incs ..." 1>&5
14622 test -n "$verbose" && echo " package ice LIBS: $cf_pkgconfig_libs" 1>&6
14624 echo "${as_me:-configure}:14624: testing package ice LIBS: $cf_pkgconfig_libs ..." 1>&5
14629 cf_new_extra_cppflags=
14631 for cf_add_cflags in $cf_pkgconfig_incs
14633 case "$cf_fix_cppflags" in
14635 case "$cf_add_cflags" in
14636 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
14637 case "$cf_add_cflags" in
14639 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
14641 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14642 && test -z "${cf_tst_cflags}" \
14643 && cf_fix_cppflags=yes
14645 if test "$cf_fix_cppflags" = yes ; then
14647 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14648 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14651 elif test "${cf_tst_cflags}" = "\"'" ; then
14653 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14654 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14660 case "$CPPFLAGS" in
14664 case "$cf_add_cflags" in
14666 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
14668 CPPFLAGS=`echo "$CPPFLAGS" | \
14669 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
14670 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
14675 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
14676 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
14683 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
14684 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
14691 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14692 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14694 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
14696 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14697 && test -z "${cf_tst_cflags}" \
14698 && cf_fix_cppflags=no
14703 if test -n "$cf_new_cflags" ; then
14705 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
14706 CFLAGS="${CFLAGS}$cf_new_cflags"
14710 if test -n "$cf_new_cppflags" ; then
14712 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
14713 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
14717 if test -n "$cf_new_extra_cppflags" ; then
14719 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
14720 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
14724 cf_add_libs="$LIBS"
14727 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
14728 # filter duplicates
14729 for cf_add_1lib in $cf_add_0lib; do
14730 for cf_add_2lib in $cf_add_libs; do
14731 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
14736 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
14738 LIBS="$cf_add_libs"
14744 { echo "$as_me:14744: WARNING: unable to find ICE library" >&5
14745 echo "$as_me: WARNING: unable to find ICE library" >&2;}
14748 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "sm"; then
14749 test -n "$verbose" && echo " found package sm" 1>&6
14751 echo "${as_me:-configure}:14751: testing found package sm ..." 1>&5
14753 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "sm" 2>/dev/null`"
14754 cf_pkgconfig_libs="`$PKG_CONFIG --libs "sm" 2>/dev/null`"
14755 test -n "$verbose" && echo " package sm CFLAGS: $cf_pkgconfig_incs" 1>&6
14757 echo "${as_me:-configure}:14757: testing package sm CFLAGS: $cf_pkgconfig_incs ..." 1>&5
14759 test -n "$verbose" && echo " package sm LIBS: $cf_pkgconfig_libs" 1>&6
14761 echo "${as_me:-configure}:14761: testing package sm LIBS: $cf_pkgconfig_libs ..." 1>&5
14766 cf_new_extra_cppflags=
14768 for cf_add_cflags in $cf_pkgconfig_incs
14770 case "$cf_fix_cppflags" in
14772 case "$cf_add_cflags" in
14773 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
14774 case "$cf_add_cflags" in
14776 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
14778 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14779 && test -z "${cf_tst_cflags}" \
14780 && cf_fix_cppflags=yes
14782 if test "$cf_fix_cppflags" = yes ; then
14784 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14785 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14788 elif test "${cf_tst_cflags}" = "\"'" ; then
14790 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14791 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14797 case "$CPPFLAGS" in
14801 case "$cf_add_cflags" in
14803 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
14805 CPPFLAGS=`echo "$CPPFLAGS" | \
14806 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
14807 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
14812 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
14813 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
14820 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
14821 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
14828 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14829 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14831 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
14833 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14834 && test -z "${cf_tst_cflags}" \
14835 && cf_fix_cppflags=no
14840 if test -n "$cf_new_cflags" ; then
14842 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
14843 CFLAGS="${CFLAGS}$cf_new_cflags"
14847 if test -n "$cf_new_cppflags" ; then
14849 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
14850 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
14854 if test -n "$cf_new_extra_cppflags" ; then
14856 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
14857 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
14861 cf_add_libs="$LIBS"
14864 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
14865 # filter duplicates
14866 for cf_add_1lib in $cf_add_0lib; do
14867 for cf_add_2lib in $cf_add_libs; do
14868 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
14873 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
14875 LIBS="$cf_add_libs"
14881 { echo "$as_me:14881: WARNING: unable to find SM library" >&5
14882 echo "$as_me: WARNING: unable to find SM library" >&2;}
14885 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "xt"; then
14886 test -n "$verbose" && echo " found package xt" 1>&6
14888 echo "${as_me:-configure}:14888: testing found package xt ..." 1>&5
14890 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "xt" 2>/dev/null`"
14891 cf_pkgconfig_libs="`$PKG_CONFIG --libs "xt" 2>/dev/null`"
14892 test -n "$verbose" && echo " package xt CFLAGS: $cf_pkgconfig_incs" 1>&6
14894 echo "${as_me:-configure}:14894: testing package xt CFLAGS: $cf_pkgconfig_incs ..." 1>&5
14896 test -n "$verbose" && echo " package xt LIBS: $cf_pkgconfig_libs" 1>&6
14898 echo "${as_me:-configure}:14898: testing package xt LIBS: $cf_pkgconfig_libs ..." 1>&5
14903 cf_new_extra_cppflags=
14905 for cf_add_cflags in $cf_pkgconfig_incs
14907 case "$cf_fix_cppflags" in
14909 case "$cf_add_cflags" in
14910 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
14911 case "$cf_add_cflags" in
14913 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
14915 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14916 && test -z "${cf_tst_cflags}" \
14917 && cf_fix_cppflags=yes
14919 if test "$cf_fix_cppflags" = yes ; then
14921 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14922 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14925 elif test "${cf_tst_cflags}" = "\"'" ; then
14927 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14928 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14934 case "$CPPFLAGS" in
14938 case "$cf_add_cflags" in
14940 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
14942 CPPFLAGS=`echo "$CPPFLAGS" | \
14943 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
14944 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
14949 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
14950 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
14957 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
14958 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
14965 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14966 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14968 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
14970 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14971 && test -z "${cf_tst_cflags}" \
14972 && cf_fix_cppflags=no
14977 if test -n "$cf_new_cflags" ; then
14979 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
14980 CFLAGS="${CFLAGS}$cf_new_cflags"
14984 if test -n "$cf_new_cppflags" ; then
14986 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
14987 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
14991 if test -n "$cf_new_extra_cppflags" ; then
14993 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
14994 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
14998 cf_add_libs="$LIBS"
15001 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
15002 # filter duplicates
15003 for cf_add_1lib in $cf_add_0lib; do
15004 for cf_add_2lib in $cf_add_libs; do
15005 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
15010 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
15012 LIBS="$cf_add_libs"
15018 { echo "$as_me:15018: WARNING: unable to find Xt library" >&5
15019 echo "$as_me: WARNING: unable to find Xt library" >&2;}
15023 LIBS="$X_PRE_LIBS $LIBS $X_EXTRA_LIBS"
15028 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "xt"; then
15029 test -n "$verbose" && echo " found package xt" 1>&6
15031 echo "${as_me:-configure}:15031: testing found package xt ..." 1>&5
15033 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "xt" 2>/dev/null`"
15034 cf_pkgconfig_libs="`$PKG_CONFIG --libs "xt" 2>/dev/null`"
15035 test -n "$verbose" && echo " package xt CFLAGS: $cf_pkgconfig_incs" 1>&6
15037 echo "${as_me:-configure}:15037: testing package xt CFLAGS: $cf_pkgconfig_incs ..." 1>&5
15039 test -n "$verbose" && echo " package xt LIBS: $cf_pkgconfig_libs" 1>&6
15041 echo "${as_me:-configure}:15041: testing package xt LIBS: $cf_pkgconfig_libs ..." 1>&5
15046 cf_new_extra_cppflags=
15048 for cf_add_cflags in $cf_pkgconfig_incs
15050 case "$cf_fix_cppflags" in
15052 case "$cf_add_cflags" in
15053 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
15054 case "$cf_add_cflags" in
15056 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
15058 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15059 && test -z "${cf_tst_cflags}" \
15060 && cf_fix_cppflags=yes
15062 if test "$cf_fix_cppflags" = yes ; then
15064 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15065 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15068 elif test "${cf_tst_cflags}" = "\"'" ; then
15070 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15071 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15077 case "$CPPFLAGS" in
15081 case "$cf_add_cflags" in
15083 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
15085 CPPFLAGS=`echo "$CPPFLAGS" | \
15086 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
15087 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
15092 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
15093 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
15100 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
15101 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
15108 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15109 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15111 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
15113 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15114 && test -z "${cf_tst_cflags}" \
15115 && cf_fix_cppflags=no
15120 if test -n "$cf_new_cflags" ; then
15122 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
15123 CFLAGS="${CFLAGS}$cf_new_cflags"
15127 if test -n "$cf_new_cppflags" ; then
15129 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
15130 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
15134 if test -n "$cf_new_extra_cppflags" ; then
15136 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
15137 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
15141 cf_add_libs="$LIBS"
15144 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
15145 # filter duplicates
15146 for cf_add_1lib in $cf_add_0lib; do
15147 for cf_add_2lib in $cf_add_libs; do
15148 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
15153 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
15155 LIBS="$cf_add_libs"
15161 # we have an "xt" package, but it may omit Xt's dependency on X11
15162 echo "$as_me:15162: checking for usable X dependency" >&5
15163 echo $ECHO_N "checking for usable X dependency... $ECHO_C" >&6
15164 if test "${cf_cv_xt_x11_compat+set}" = set; then
15165 echo $ECHO_N "(cached) $ECHO_C" >&6
15168 cat >"conftest.$ac_ext" <<_ACEOF
15169 #line 15169 "configure"
15170 #include "confdefs.h"
15172 $ac_includes_default
15173 #include <X11/Xlib.h>
15179 int rc1 = XDrawLine((Display*) 0, (Drawable) 0, (GC) 0, 0, 0, 0, 0);
15180 int rc2 = XClearWindow((Display*) 0, (Window) 0);
15181 int rc3 = XMoveWindow((Display*) 0, (Window) 0, 0, 0);
15182 int rc4 = XMoveResizeWindow((Display*)0, (Window)0, 0, 0, 0, 0);
15188 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
15189 if { (eval echo "$as_me:15189: \"$ac_link\"") >&5
15190 (eval $ac_link) 2>&5
15192 echo "$as_me:15192: \$? = $ac_status" >&5
15193 (exit "$ac_status"); } &&
15194 { ac_try='test -s "conftest$ac_exeext"'
15195 { (eval echo "$as_me:15195: \"$ac_try\"") >&5
15196 (eval $ac_try) 2>&5
15198 echo "$as_me:15198: \$? = $ac_status" >&5
15199 (exit "$ac_status"); }; }; then
15200 cf_cv_xt_x11_compat=yes
15202 echo "$as_me: failed program was:" >&5
15203 cat "conftest.$ac_ext" >&5
15204 cf_cv_xt_x11_compat=no
15206 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
15208 echo "$as_me:15208: result: $cf_cv_xt_x11_compat" >&5
15209 echo "${ECHO_T}$cf_cv_xt_x11_compat" >&6
15210 if test "$cf_cv_xt_x11_compat" = no
15212 test -n "$verbose" && echo " work around broken X11 dependency" 1>&6
15214 echo "${as_me:-configure}:15214: testing work around broken X11 dependency ..." 1>&5
15216 # 2010/11/19 - good enough until a working Xt on Xcb is delivered.
15218 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "x11"; then
15219 test -n "$verbose" && echo " found package x11" 1>&6
15221 echo "${as_me:-configure}:15221: testing found package x11 ..." 1>&5
15223 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "x11" 2>/dev/null`"
15224 cf_pkgconfig_libs="`$PKG_CONFIG --libs "x11" 2>/dev/null`"
15225 test -n "$verbose" && echo " package x11 CFLAGS: $cf_pkgconfig_incs" 1>&6
15227 echo "${as_me:-configure}:15227: testing package x11 CFLAGS: $cf_pkgconfig_incs ..." 1>&5
15229 test -n "$verbose" && echo " package x11 LIBS: $cf_pkgconfig_libs" 1>&6
15231 echo "${as_me:-configure}:15231: testing package x11 LIBS: $cf_pkgconfig_libs ..." 1>&5
15236 cf_new_extra_cppflags=
15238 for cf_add_cflags in $cf_pkgconfig_incs
15240 case "$cf_fix_cppflags" in
15242 case "$cf_add_cflags" in
15243 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
15244 case "$cf_add_cflags" in
15246 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
15248 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15249 && test -z "${cf_tst_cflags}" \
15250 && cf_fix_cppflags=yes
15252 if test "$cf_fix_cppflags" = yes ; then
15254 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15255 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15258 elif test "${cf_tst_cflags}" = "\"'" ; then
15260 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15261 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15267 case "$CPPFLAGS" in
15271 case "$cf_add_cflags" in
15273 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
15275 CPPFLAGS=`echo "$CPPFLAGS" | \
15276 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
15277 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
15282 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
15283 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
15290 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
15291 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
15298 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15299 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15301 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
15303 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15304 && test -z "${cf_tst_cflags}" \
15305 && cf_fix_cppflags=no
15310 if test -n "$cf_new_cflags" ; then
15312 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
15313 CFLAGS="${CFLAGS}$cf_new_cflags"
15317 if test -n "$cf_new_cppflags" ; then
15319 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
15320 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
15324 if test -n "$cf_new_extra_cppflags" ; then
15326 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
15327 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
15331 cf_add_libs="$LIBS"
15334 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
15335 # filter duplicates
15336 for cf_add_1lib in $cf_add_0lib; do
15337 for cf_add_2lib in $cf_add_libs; do
15338 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
15343 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
15345 LIBS="$cf_add_libs"
15352 test -n "$verbose" && echo " ...before $LIBS" 1>&6
15354 echo "${as_me:-configure}:15354: testing ...before $LIBS ..." 1>&5
15356 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%-lXt %-lXt -lX11 %" -e 's% % %g'`
15357 test -n "$verbose" && echo " ...after $LIBS" 1>&6
15359 echo "${as_me:-configure}:15359: testing ...after $LIBS ..." 1>&5
15367 echo "$as_me:15367: checking for usable X Toolkit package" >&5
15368 echo $ECHO_N "checking for usable X Toolkit package... $ECHO_C" >&6
15369 if test "${cf_cv_xt_ice_compat+set}" = set; then
15370 echo $ECHO_N "(cached) $ECHO_C" >&6
15373 cat >"conftest.$ac_ext" <<_ACEOF
15374 #line 15374 "configure"
15375 #include "confdefs.h"
15377 $ac_includes_default
15378 #include <X11/Shell.h>
15383 int num = IceConnectionNumber(0); (void) num
15389 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
15390 if { (eval echo "$as_me:15390: \"$ac_link\"") >&5
15391 (eval $ac_link) 2>&5
15393 echo "$as_me:15393: \$? = $ac_status" >&5
15394 (exit "$ac_status"); } &&
15395 { ac_try='test -s "conftest$ac_exeext"'
15396 { (eval echo "$as_me:15396: \"$ac_try\"") >&5
15397 (eval $ac_try) 2>&5
15399 echo "$as_me:15399: \$? = $ac_status" >&5
15400 (exit "$ac_status"); }; }; then
15401 cf_cv_xt_ice_compat=yes
15403 echo "$as_me: failed program was:" >&5
15404 cat "conftest.$ac_ext" >&5
15405 cf_cv_xt_ice_compat=no
15407 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
15409 echo "$as_me:15409: result: $cf_cv_xt_ice_compat" >&5
15410 echo "${ECHO_T}$cf_cv_xt_ice_compat" >&6
15412 if test "$cf_cv_xt_ice_compat" = no
15414 # workaround for broken ".pc" files used for X Toolkit.
15415 case "x$X_PRE_LIBS" in
15421 test -n "$verbose" && echo " work around broken ICE dependency" 1>&6
15423 echo "${as_me:-configure}:15423: testing work around broken ICE dependency ..." 1>&5
15425 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "ice"; then
15426 test -n "$verbose" && echo " found package ice" 1>&6
15428 echo "${as_me:-configure}:15428: testing found package ice ..." 1>&5
15430 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "ice" 2>/dev/null`"
15431 cf_pkgconfig_libs="`$PKG_CONFIG --libs "ice" 2>/dev/null`"
15432 test -n "$verbose" && echo " package ice CFLAGS: $cf_pkgconfig_incs" 1>&6
15434 echo "${as_me:-configure}:15434: testing package ice CFLAGS: $cf_pkgconfig_incs ..." 1>&5
15436 test -n "$verbose" && echo " package ice LIBS: $cf_pkgconfig_libs" 1>&6
15438 echo "${as_me:-configure}:15438: testing package ice LIBS: $cf_pkgconfig_libs ..." 1>&5
15443 cf_new_extra_cppflags=
15445 for cf_add_cflags in $cf_pkgconfig_incs
15447 case "$cf_fix_cppflags" in
15449 case "$cf_add_cflags" in
15450 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
15451 case "$cf_add_cflags" in
15453 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
15455 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15456 && test -z "${cf_tst_cflags}" \
15457 && cf_fix_cppflags=yes
15459 if test "$cf_fix_cppflags" = yes ; then
15461 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15462 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15465 elif test "${cf_tst_cflags}" = "\"'" ; then
15467 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15468 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15474 case "$CPPFLAGS" in
15478 case "$cf_add_cflags" in
15480 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
15482 CPPFLAGS=`echo "$CPPFLAGS" | \
15483 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
15484 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
15489 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
15490 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
15497 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
15498 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
15505 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15506 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15508 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
15510 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15511 && test -z "${cf_tst_cflags}" \
15512 && cf_fix_cppflags=no
15517 if test -n "$cf_new_cflags" ; then
15519 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
15520 CFLAGS="${CFLAGS}$cf_new_cflags"
15524 if test -n "$cf_new_cppflags" ; then
15526 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
15527 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
15531 if test -n "$cf_new_extra_cppflags" ; then
15533 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
15534 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
15538 cf_add_libs="$LIBS"
15541 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
15542 # filter duplicates
15543 for cf_add_1lib in $cf_add_0lib; do
15544 for cf_add_2lib in $cf_add_libs; do
15545 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
15550 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
15552 LIBS="$cf_add_libs"
15554 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "sm"; then
15555 test -n "$verbose" && echo " found package sm" 1>&6
15557 echo "${as_me:-configure}:15557: testing found package sm ..." 1>&5
15559 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "sm" 2>/dev/null`"
15560 cf_pkgconfig_libs="`$PKG_CONFIG --libs "sm" 2>/dev/null`"
15561 test -n "$verbose" && echo " package sm CFLAGS: $cf_pkgconfig_incs" 1>&6
15563 echo "${as_me:-configure}:15563: testing package sm CFLAGS: $cf_pkgconfig_incs ..." 1>&5
15565 test -n "$verbose" && echo " package sm LIBS: $cf_pkgconfig_libs" 1>&6
15567 echo "${as_me:-configure}:15567: testing package sm LIBS: $cf_pkgconfig_libs ..." 1>&5
15572 cf_new_extra_cppflags=
15574 for cf_add_cflags in $cf_pkgconfig_incs
15576 case "$cf_fix_cppflags" in
15578 case "$cf_add_cflags" in
15579 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
15580 case "$cf_add_cflags" in
15582 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
15584 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15585 && test -z "${cf_tst_cflags}" \
15586 && cf_fix_cppflags=yes
15588 if test "$cf_fix_cppflags" = yes ; then
15590 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15591 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15594 elif test "${cf_tst_cflags}" = "\"'" ; then
15596 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15597 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15603 case "$CPPFLAGS" in
15607 case "$cf_add_cflags" in
15609 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
15611 CPPFLAGS=`echo "$CPPFLAGS" | \
15612 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
15613 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
15618 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
15619 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
15626 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
15627 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
15634 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15635 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15637 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
15639 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15640 && test -z "${cf_tst_cflags}" \
15641 && cf_fix_cppflags=no
15646 if test -n "$cf_new_cflags" ; then
15648 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
15649 CFLAGS="${CFLAGS}$cf_new_cflags"
15653 if test -n "$cf_new_cppflags" ; then
15655 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
15656 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
15660 if test -n "$cf_new_extra_cppflags" ; then
15662 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
15663 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
15667 cf_add_libs="$LIBS"
15670 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
15671 # filter duplicates
15672 for cf_add_1lib in $cf_add_0lib; do
15673 for cf_add_2lib in $cf_add_libs; do
15674 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
15679 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
15681 LIBS="$cf_add_libs"
15694 test -n "$verbose" && echo " ...before $LIBS" 1>&6
15696 echo "${as_me:-configure}:15696: testing ...before $LIBS ..." 1>&5
15698 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%-lXt %-lXt $X_PRE_LIBS %" -e 's% % %g'`
15699 test -n "$verbose" && echo " ...after $LIBS" 1>&6
15701 echo "${as_me:-configure}:15701: testing ...after $LIBS ..." 1>&5
15717 LDFLAGS="$X_LIBS $LDFLAGS"
15719 test -n "$verbose" && echo " checking additions to CFLAGS" 1>&6
15721 echo "${as_me:-configure}:15721: testing checking additions to CFLAGS ..." 1>&5
15723 cf_check_cflags="$CFLAGS"
15724 cf_check_cppflags="$CPPFLAGS"
15729 cf_new_extra_cppflags=
15731 for cf_add_cflags in $X_CFLAGS
15733 case "$cf_fix_cppflags" in
15735 case "$cf_add_cflags" in
15736 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
15737 case "$cf_add_cflags" in
15739 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
15741 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15742 && test -z "${cf_tst_cflags}" \
15743 && cf_fix_cppflags=yes
15745 if test "$cf_fix_cppflags" = yes ; then
15747 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15748 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15751 elif test "${cf_tst_cflags}" = "\"'" ; then
15753 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15754 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15760 case "$CPPFLAGS" in
15764 case "$cf_add_cflags" in
15766 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
15768 CPPFLAGS=`echo "$CPPFLAGS" | \
15769 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
15770 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
15775 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
15776 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
15783 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
15784 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
15791 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15792 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15794 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
15796 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15797 && test -z "${cf_tst_cflags}" \
15798 && cf_fix_cppflags=no
15803 if test -n "$cf_new_cflags" ; then
15804 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
15806 echo "${as_me:-configure}:15806: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
15808 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
15809 CFLAGS="${CFLAGS}$cf_new_cflags"
15813 if test -n "$cf_new_cppflags" ; then
15814 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
15816 echo "${as_me:-configure}:15816: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
15818 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
15819 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
15823 if test -n "$cf_new_extra_cppflags" ; then
15824 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
15826 echo "${as_me:-configure}:15826: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
15828 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
15829 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
15833 if test "x$cf_check_cflags" != "x$CFLAGS" ; then
15834 cat >"conftest.$ac_ext" <<_ACEOF
15835 #line 15835 "configure"
15836 #include "confdefs.h"
15841 printf("Hello world");
15846 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
15847 if { (eval echo "$as_me:15847: \"$ac_link\"") >&5
15848 (eval $ac_link) 2>&5
15850 echo "$as_me:15850: \$? = $ac_status" >&5
15851 (exit "$ac_status"); } &&
15852 { ac_try='test -s "conftest$ac_exeext"'
15853 { (eval echo "$as_me:15853: \"$ac_try\"") >&5
15854 (eval $ac_try) 2>&5
15856 echo "$as_me:15856: \$? = $ac_status" >&5
15857 (exit "$ac_status"); }; }; then
15860 echo "$as_me: failed program was:" >&5
15861 cat "conftest.$ac_ext" >&5
15862 test -n "$verbose" && echo " test-compile failed. Undoing change to \$CFLAGS" 1>&6
15864 echo "${as_me:-configure}:15864: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5
15866 if test "x$cf_check_cppflags" != "x$CPPFLAGS" ; then
15867 test -n "$verbose" && echo " but keeping change to \$CPPFLAGS" 1>&6
15869 echo "${as_me:-configure}:15869: testing but keeping change to \$CPPFLAGS ..." 1>&5
15872 CFLAGS="$cf_check_cflags"
15874 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
15877 echo "$as_me:15877: checking for XOpenDisplay" >&5
15878 echo $ECHO_N "checking for XOpenDisplay... $ECHO_C" >&6
15879 if test "${ac_cv_func_XOpenDisplay+set}" = set; then
15880 echo $ECHO_N "(cached) $ECHO_C" >&6
15882 cat >"conftest.$ac_ext" <<_ACEOF
15883 #line 15883 "configure"
15884 #include "confdefs.h"
15885 #define XOpenDisplay autoconf_temporary
15886 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
15887 #undef XOpenDisplay
15893 /* We use char because int might match the return type of a gcc2
15894 builtin and then its argument prototype would still apply. */
15895 char XOpenDisplay (void);
15901 /* The GNU C library defines stubs for functions which it implements
15902 to always fail with ENOSYS. Some functions are actually named
15903 something starting with __ and the normal name is an alias. */
15904 #if defined (__stub_XOpenDisplay) || defined (__stub___XOpenDisplay)
15905 #error found stub for XOpenDisplay
15908 return XOpenDisplay ();
15913 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
15914 if { (eval echo "$as_me:15914: \"$ac_link\"") >&5
15915 (eval $ac_link) 2>&5
15917 echo "$as_me:15917: \$? = $ac_status" >&5
15918 (exit "$ac_status"); } &&
15919 { ac_try='test -s "conftest$ac_exeext"'
15920 { (eval echo "$as_me:15920: \"$ac_try\"") >&5
15921 (eval $ac_try) 2>&5
15923 echo "$as_me:15923: \$? = $ac_status" >&5
15924 (exit "$ac_status"); }; }; then
15925 ac_cv_func_XOpenDisplay=yes
15927 echo "$as_me: failed program was:" >&5
15928 cat "conftest.$ac_ext" >&5
15929 ac_cv_func_XOpenDisplay=no
15931 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
15933 echo "$as_me:15933: result: $ac_cv_func_XOpenDisplay" >&5
15934 echo "${ECHO_T}$ac_cv_func_XOpenDisplay" >&6
15935 if test "$ac_cv_func_XOpenDisplay" = yes; then
15939 echo "$as_me:15939: checking for XOpenDisplay in -lX11" >&5
15940 echo $ECHO_N "checking for XOpenDisplay in -lX11... $ECHO_C" >&6
15941 if test "${ac_cv_lib_X11_XOpenDisplay+set}" = set; then
15942 echo $ECHO_N "(cached) $ECHO_C" >&6
15944 ac_check_lib_save_LIBS=$LIBS
15946 cat >"conftest.$ac_ext" <<_ACEOF
15947 #line 15947 "configure"
15948 #include "confdefs.h"
15950 /* Override any gcc2 internal prototype to avoid an error. */
15954 /* We use char because int might match the return type of a gcc2
15955 builtin and then its argument prototype would still apply. */
15956 char XOpenDisplay (void);
15965 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
15966 if { (eval echo "$as_me:15966: \"$ac_link\"") >&5
15967 (eval $ac_link) 2>&5
15969 echo "$as_me:15969: \$? = $ac_status" >&5
15970 (exit "$ac_status"); } &&
15971 { ac_try='test -s "conftest$ac_exeext"'
15972 { (eval echo "$as_me:15972: \"$ac_try\"") >&5
15973 (eval $ac_try) 2>&5
15975 echo "$as_me:15975: \$? = $ac_status" >&5
15976 (exit "$ac_status"); }; }; then
15977 ac_cv_lib_X11_XOpenDisplay=yes
15979 echo "$as_me: failed program was:" >&5
15980 cat "conftest.$ac_ext" >&5
15981 ac_cv_lib_X11_XOpenDisplay=no
15983 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
15984 LIBS=$ac_check_lib_save_LIBS
15986 echo "$as_me:15986: result: $ac_cv_lib_X11_XOpenDisplay" >&5
15987 echo "${ECHO_T}$ac_cv_lib_X11_XOpenDisplay" >&6
15988 if test "$ac_cv_lib_X11_XOpenDisplay" = yes; then
15990 cf_add_libs="$LIBS"
15993 for cf_add_1lib in -lX11; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
15994 # filter duplicates
15995 for cf_add_1lib in $cf_add_0lib; do
15996 for cf_add_2lib in $cf_add_libs; do
15997 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
16002 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
16004 LIBS="$cf_add_libs"
16010 echo "$as_me:16010: checking for XtAppInitialize" >&5
16011 echo $ECHO_N "checking for XtAppInitialize... $ECHO_C" >&6
16012 if test "${ac_cv_func_XtAppInitialize+set}" = set; then
16013 echo $ECHO_N "(cached) $ECHO_C" >&6
16015 cat >"conftest.$ac_ext" <<_ACEOF
16016 #line 16016 "configure"
16017 #include "confdefs.h"
16018 #define XtAppInitialize autoconf_temporary
16019 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
16020 #undef XtAppInitialize
16026 /* We use char because int might match the return type of a gcc2
16027 builtin and then its argument prototype would still apply. */
16028 char XtAppInitialize (void);
16034 /* The GNU C library defines stubs for functions which it implements
16035 to always fail with ENOSYS. Some functions are actually named
16036 something starting with __ and the normal name is an alias. */
16037 #if defined (__stub_XtAppInitialize) || defined (__stub___XtAppInitialize)
16038 #error found stub for XtAppInitialize
16041 return XtAppInitialize ();
16046 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
16047 if { (eval echo "$as_me:16047: \"$ac_link\"") >&5
16048 (eval $ac_link) 2>&5
16050 echo "$as_me:16050: \$? = $ac_status" >&5
16051 (exit "$ac_status"); } &&
16052 { ac_try='test -s "conftest$ac_exeext"'
16053 { (eval echo "$as_me:16053: \"$ac_try\"") >&5
16054 (eval $ac_try) 2>&5
16056 echo "$as_me:16056: \$? = $ac_status" >&5
16057 (exit "$ac_status"); }; }; then
16058 ac_cv_func_XtAppInitialize=yes
16060 echo "$as_me: failed program was:" >&5
16061 cat "conftest.$ac_ext" >&5
16062 ac_cv_func_XtAppInitialize=no
16064 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
16066 echo "$as_me:16066: result: $ac_cv_func_XtAppInitialize" >&5
16067 echo "${ECHO_T}$ac_cv_func_XtAppInitialize" >&6
16068 if test "$ac_cv_func_XtAppInitialize" = yes; then
16072 echo "$as_me:16072: checking for XtAppInitialize in -lXt" >&5
16073 echo $ECHO_N "checking for XtAppInitialize in -lXt... $ECHO_C" >&6
16074 if test "${ac_cv_lib_Xt_XtAppInitialize+set}" = set; then
16075 echo $ECHO_N "(cached) $ECHO_C" >&6
16077 ac_check_lib_save_LIBS=$LIBS
16079 cat >"conftest.$ac_ext" <<_ACEOF
16080 #line 16080 "configure"
16081 #include "confdefs.h"
16083 /* Override any gcc2 internal prototype to avoid an error. */
16087 /* We use char because int might match the return type of a gcc2
16088 builtin and then its argument prototype would still apply. */
16089 char XtAppInitialize (void);
16093 XtAppInitialize ();
16098 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
16099 if { (eval echo "$as_me:16099: \"$ac_link\"") >&5
16100 (eval $ac_link) 2>&5
16102 echo "$as_me:16102: \$? = $ac_status" >&5
16103 (exit "$ac_status"); } &&
16104 { ac_try='test -s "conftest$ac_exeext"'
16105 { (eval echo "$as_me:16105: \"$ac_try\"") >&5
16106 (eval $ac_try) 2>&5
16108 echo "$as_me:16108: \$? = $ac_status" >&5
16109 (exit "$ac_status"); }; }; then
16110 ac_cv_lib_Xt_XtAppInitialize=yes
16112 echo "$as_me: failed program was:" >&5
16113 cat "conftest.$ac_ext" >&5
16114 ac_cv_lib_Xt_XtAppInitialize=no
16116 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
16117 LIBS=$ac_check_lib_save_LIBS
16119 echo "$as_me:16119: result: $ac_cv_lib_Xt_XtAppInitialize" >&5
16120 echo "${ECHO_T}$ac_cv_lib_Xt_XtAppInitialize" >&6
16121 if test "$ac_cv_lib_Xt_XtAppInitialize" = yes; then
16123 cat >>confdefs.h <<\EOF
16124 #define HAVE_LIBXT 1
16135 if test "$cf_have_X_LIBS" = no ; then
16136 { echo "$as_me:16136: WARNING: Unable to successfully link X Toolkit library (-lXt) with
16137 test program. You will have to check and add the proper libraries by hand
16139 echo "$as_me: WARNING: Unable to successfully link X Toolkit library (-lXt) with
16140 test program. You will have to check and add the proper libraries by hand
16141 to makefile." >&2;}
16144 cf_x_athena_root=$cf_x_athena
16147 for cf_path in default \
16148 /usr/contrib/X11R6 \
16149 /usr/contrib/X11R5 \
16153 if test -z "$cf_x_athena_inc" ; then
16155 cf_save_LIBS_CF_X_ATHENA_CPPFLAGS="$LIBS"
16156 cf_save_CFLAGS_CF_X_ATHENA_CPPFLAGS="$CFLAGS"
16157 cf_save_CPPFLAGS_CF_X_ATHENA_CPPFLAGS="$CPPFLAGS"
16158 LIBS="$LIBS ${X_PRE_LIBS} ${X_LIBS} ${X_EXTRA_LIBS}"
16159 for cf_X_CFLAGS in $X_CFLAGS
16161 case "x$cf_X_CFLAGS" in
16163 CPPFLAGS="$CPPFLAGS $cf_X_CFLAGS"
16166 CFLAGS="$CFLAGS $cf_X_CFLAGS"
16171 cf_test=X11/$cf_x_athena_root/SimpleMenu.h
16172 if test "$cf_path" != default ; then
16174 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
16175 CPPFLAGS="${CPPFLAGS}-I$cf_path/include"
16177 echo "$as_me:16177: checking for $cf_test in $cf_path" >&5
16178 echo $ECHO_N "checking for $cf_test in $cf_path... $ECHO_C" >&6
16180 echo "$as_me:16180: checking for $cf_test" >&5
16181 echo $ECHO_N "checking for $cf_test... $ECHO_C" >&6
16183 cat >"conftest.$ac_ext" <<_ACEOF
16184 #line 16184 "configure"
16185 #include "confdefs.h"
16187 #include <X11/Intrinsic.h>
16188 #include <$cf_test>
16197 rm -f "conftest.$ac_objext"
16198 if { (eval echo "$as_me:16198: \"$ac_compile\"") >&5
16199 (eval $ac_compile) 2>&5
16201 echo "$as_me:16201: \$? = $ac_status" >&5
16202 (exit "$ac_status"); } &&
16203 { ac_try='test -s "conftest.$ac_objext"'
16204 { (eval echo "$as_me:16204: \"$ac_try\"") >&5
16205 (eval $ac_try) 2>&5
16207 echo "$as_me:16207: \$? = $ac_status" >&5
16208 (exit "$ac_status"); }; }; then
16211 echo "$as_me: failed program was:" >&5
16212 cat "conftest.$ac_ext" >&5
16215 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
16216 echo "$as_me:16216: result: $cf_result" >&5
16217 echo "${ECHO_T}$cf_result" >&6
16219 LIBS="$cf_save_LIBS_CF_X_ATHENA_CPPFLAGS"
16220 CFLAGS="$cf_save_CFLAGS_CF_X_ATHENA_CPPFLAGS"
16221 CPPFLAGS="$cf_save_CPPFLAGS_CF_X_ATHENA_CPPFLAGS"
16223 if test "$cf_result" = yes ; then
16224 test "$cf_path" = default && cf_x_athena_inc=default
16225 test "$cf_path" != default && cf_x_athena_inc="$cf_path/include"
16231 if test -z "$cf_x_athena_inc" ; then
16232 { echo "$as_me:16232: WARNING: Unable to find Athena header files" >&5
16233 echo "$as_me: WARNING: Unable to find Athena header files" >&2;}
16234 elif test "$cf_x_athena_inc" != default ; then
16236 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
16237 CPPFLAGS="${CPPFLAGS}-I$cf_x_athena_inc"
16241 cf_x_athena_root=$cf_x_athena
16244 for cf_path in default \
16245 /usr/contrib/X11R6 \
16246 /usr/contrib/X11R5 \
16251 ${cf_x_athena_root} \
16252 ${cf_x_athena_root}7 \
16253 ${cf_x_athena_root}6
16256 "-l$cf_lib -lXmu" \
16257 "-l$cf_lib -lXpm -lXmu" \
16258 "-l${cf_lib}_s -lXmu_s"
16260 test -n "$cf_x_athena_lib" && break
16262 cf_save_LIBS_CF_X_ATHENA_LIBS="$LIBS"
16263 cf_save_CFLAGS_CF_X_ATHENA_LIBS="$CFLAGS"
16264 cf_save_CPPFLAGS_CF_X_ATHENA_LIBS="$CPPFLAGS"
16265 LIBS="$LIBS ${X_PRE_LIBS} ${X_LIBS} ${X_EXTRA_LIBS}"
16266 for cf_X_CFLAGS in $X_CFLAGS
16268 case "x$cf_X_CFLAGS" in
16270 CPPFLAGS="$CPPFLAGS $cf_X_CFLAGS"
16273 CFLAGS="$CFLAGS $cf_X_CFLAGS"
16278 cf_test=XawSimpleMenuAddGlobalActions
16279 test "$cf_path" != default && cf_libs="-L$cf_path/lib $cf_libs"
16281 cf_add_libs="$LIBS"
16284 for cf_add_1lib in $cf_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
16285 # filter duplicates
16286 for cf_add_1lib in $cf_add_0lib; do
16287 for cf_add_2lib in $cf_add_libs; do
16288 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
16293 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
16295 LIBS="$cf_add_libs"
16297 echo "$as_me:16297: checking for $cf_test in $cf_libs" >&5
16298 echo $ECHO_N "checking for $cf_test in $cf_libs... $ECHO_C" >&6
16299 cat >"conftest.$ac_ext" <<_ACEOF
16300 #line 16300 "configure"
16301 #include "confdefs.h"
16303 $ac_includes_default
16304 #include <X11/Intrinsic.h>
16305 #include <X11/$cf_x_athena_root/SimpleMenu.h>
16311 $cf_test((XtAppContext) 0)
16316 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
16317 if { (eval echo "$as_me:16317: \"$ac_link\"") >&5
16318 (eval $ac_link) 2>&5
16320 echo "$as_me:16320: \$? = $ac_status" >&5
16321 (exit "$ac_status"); } &&
16322 { ac_try='test -s "conftest$ac_exeext"'
16323 { (eval echo "$as_me:16323: \"$ac_try\"") >&5
16324 (eval $ac_try) 2>&5
16326 echo "$as_me:16326: \$? = $ac_status" >&5
16327 (exit "$ac_status"); }; }; then
16330 echo "$as_me: failed program was:" >&5
16331 cat "conftest.$ac_ext" >&5
16334 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
16335 echo "$as_me:16335: result: $cf_result" >&5
16336 echo "${ECHO_T}$cf_result" >&6
16338 LIBS="$cf_save_LIBS_CF_X_ATHENA_LIBS"
16339 CFLAGS="$cf_save_CFLAGS_CF_X_ATHENA_LIBS"
16340 CPPFLAGS="$cf_save_CPPFLAGS_CF_X_ATHENA_LIBS"
16342 if test "$cf_result" = yes ; then
16343 cf_x_athena_lib="$cf_libs"
16347 test -n "$cf_x_athena_lib" && break
16351 if test -z "$cf_x_athena_lib" ; then
16352 { { echo "$as_me:16352: error: Unable to successfully link Athena library (-l$cf_x_athena_root) with test program" >&5
16353 echo "$as_me: error: Unable to successfully link Athena library (-l$cf_x_athena_root) with test program" >&2;}
16354 { (exit 1); exit 1; }; }
16357 cf_add_libs="$LIBS"
16360 for cf_add_1lib in $cf_x_athena_lib; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
16361 # filter duplicates
16362 for cf_add_1lib in $cf_add_0lib; do
16363 for cf_add_2lib in $cf_add_libs; do
16364 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
16369 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
16371 LIBS="$cf_add_libs"
16373 cf_x_athena_LIBS=`echo "HAVE_LIB_$cf_x_athena" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
16375 cat >>confdefs.h <<EOF
16376 #define $cf_x_athena_LIBS 1
16381 if test -n "$ac_tool_prefix"; then
16382 for ac_prog in xcurses-config
16384 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
16385 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
16386 echo "$as_me:16386: checking for $ac_word" >&5
16387 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
16388 if test "${ac_cv_prog_XCURSES_CONFIG+set}" = set; then
16389 echo $ECHO_N "(cached) $ECHO_C" >&6
16391 if test -n "$XCURSES_CONFIG"; then
16392 ac_cv_prog_XCURSES_CONFIG="$XCURSES_CONFIG" # Let the user override the test.
16394 ac_save_IFS=$IFS; IFS=$ac_path_separator
16396 for ac_dir in $ac_dummy; do
16398 test -z "$ac_dir" && ac_dir=.
16399 $as_executable_p "$ac_dir/$ac_word" || continue
16400 ac_cv_prog_XCURSES_CONFIG="$ac_tool_prefix$ac_prog"
16401 echo "$as_me:16401: found $ac_dir/$ac_word" >&5
16407 XCURSES_CONFIG=$ac_cv_prog_XCURSES_CONFIG
16408 if test -n "$XCURSES_CONFIG"; then
16409 echo "$as_me:16409: result: $XCURSES_CONFIG" >&5
16410 echo "${ECHO_T}$XCURSES_CONFIG" >&6
16412 echo "$as_me:16412: result: no" >&5
16413 echo "${ECHO_T}no" >&6
16416 test -n "$XCURSES_CONFIG" && break
16419 if test -z "$XCURSES_CONFIG"; then
16420 ac_ct_XCURSES_CONFIG=$XCURSES_CONFIG
16421 for ac_prog in xcurses-config
16423 # Extract the first word of "$ac_prog", so it can be a program name with args.
16424 set dummy $ac_prog; ac_word=$2
16425 echo "$as_me:16425: checking for $ac_word" >&5
16426 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
16427 if test "${ac_cv_prog_ac_ct_XCURSES_CONFIG+set}" = set; then
16428 echo $ECHO_N "(cached) $ECHO_C" >&6
16430 if test -n "$ac_ct_XCURSES_CONFIG"; then
16431 ac_cv_prog_ac_ct_XCURSES_CONFIG="$ac_ct_XCURSES_CONFIG" # Let the user override the test.
16433 ac_save_IFS=$IFS; IFS=$ac_path_separator
16435 for ac_dir in $ac_dummy; do
16437 test -z "$ac_dir" && ac_dir=.
16438 $as_executable_p "$ac_dir/$ac_word" || continue
16439 ac_cv_prog_ac_ct_XCURSES_CONFIG="$ac_prog"
16440 echo "$as_me:16440: found $ac_dir/$ac_word" >&5
16446 ac_ct_XCURSES_CONFIG=$ac_cv_prog_ac_ct_XCURSES_CONFIG
16447 if test -n "$ac_ct_XCURSES_CONFIG"; then
16448 echo "$as_me:16448: result: $ac_ct_XCURSES_CONFIG" >&5
16449 echo "${ECHO_T}$ac_ct_XCURSES_CONFIG" >&6
16451 echo "$as_me:16451: result: no" >&5
16452 echo "${ECHO_T}no" >&6
16455 test -n "$ac_ct_XCURSES_CONFIG" && break
16457 test -n "$ac_ct_XCURSES_CONFIG" || ac_ct_XCURSES_CONFIG="none"
16459 XCURSES_CONFIG=$ac_ct_XCURSES_CONFIG
16462 if test "$XCURSES_CONFIG" != none ; then
16467 cf_new_extra_cppflags=
16469 for cf_add_cflags in `$XCURSES_CONFIG --cflags`
16471 case "$cf_fix_cppflags" in
16473 case "$cf_add_cflags" in
16474 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
16475 case "$cf_add_cflags" in
16477 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
16479 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
16480 && test -z "${cf_tst_cflags}" \
16481 && cf_fix_cppflags=yes
16483 if test "$cf_fix_cppflags" = yes ; then
16485 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
16486 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
16489 elif test "${cf_tst_cflags}" = "\"'" ; then
16491 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
16492 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
16498 case "$CPPFLAGS" in
16502 case "$cf_add_cflags" in
16504 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
16506 CPPFLAGS=`echo "$CPPFLAGS" | \
16507 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
16508 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
16513 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
16514 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
16521 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
16522 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
16529 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
16530 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
16532 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
16534 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
16535 && test -z "${cf_tst_cflags}" \
16536 && cf_fix_cppflags=no
16541 if test -n "$cf_new_cflags" ; then
16543 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
16544 CFLAGS="${CFLAGS}$cf_new_cflags"
16548 if test -n "$cf_new_cppflags" ; then
16550 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
16551 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
16555 if test -n "$cf_new_extra_cppflags" ; then
16557 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
16558 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
16562 cf_add_libs="$LIBS"
16565 for cf_add_1lib in `$XCURSES_CONFIG --libs`; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
16566 # filter duplicates
16567 for cf_add_1lib in $cf_add_0lib; do
16568 for cf_add_2lib in $cf_add_libs; do
16569 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
16574 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
16576 LIBS="$cf_add_libs"
16578 cf_cv_lib_XCurses=yes
16582 LDFLAGS="$LDFLAGS $X_LIBS"
16584 test -n "$verbose" && echo " checking additions to CFLAGS" 1>&6
16586 echo "${as_me:-configure}:16586: testing checking additions to CFLAGS ..." 1>&5
16588 cf_check_cflags="$CFLAGS"
16589 cf_check_cppflags="$CPPFLAGS"
16594 cf_new_extra_cppflags=
16596 for cf_add_cflags in $X_CFLAGS
16598 case "$cf_fix_cppflags" in
16600 case "$cf_add_cflags" in
16601 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
16602 case "$cf_add_cflags" in
16604 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
16606 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
16607 && test -z "${cf_tst_cflags}" \
16608 && cf_fix_cppflags=yes
16610 if test "$cf_fix_cppflags" = yes ; then
16612 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
16613 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
16616 elif test "${cf_tst_cflags}" = "\"'" ; then
16618 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
16619 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
16625 case "$CPPFLAGS" in
16629 case "$cf_add_cflags" in
16631 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
16633 CPPFLAGS=`echo "$CPPFLAGS" | \
16634 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
16635 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
16640 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
16641 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
16648 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
16649 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
16656 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
16657 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
16659 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
16661 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
16662 && test -z "${cf_tst_cflags}" \
16663 && cf_fix_cppflags=no
16668 if test -n "$cf_new_cflags" ; then
16669 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
16671 echo "${as_me:-configure}:16671: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
16673 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
16674 CFLAGS="${CFLAGS}$cf_new_cflags"
16678 if test -n "$cf_new_cppflags" ; then
16679 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
16681 echo "${as_me:-configure}:16681: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
16683 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
16684 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
16688 if test -n "$cf_new_extra_cppflags" ; then
16689 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
16691 echo "${as_me:-configure}:16691: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
16693 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
16694 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
16698 if test "x$cf_check_cflags" != "x$CFLAGS" ; then
16699 cat >"conftest.$ac_ext" <<_ACEOF
16700 #line 16700 "configure"
16701 #include "confdefs.h"
16706 printf("Hello world");
16711 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
16712 if { (eval echo "$as_me:16712: \"$ac_link\"") >&5
16713 (eval $ac_link) 2>&5
16715 echo "$as_me:16715: \$? = $ac_status" >&5
16716 (exit "$ac_status"); } &&
16717 { ac_try='test -s "conftest$ac_exeext"'
16718 { (eval echo "$as_me:16718: \"$ac_try\"") >&5
16719 (eval $ac_try) 2>&5
16721 echo "$as_me:16721: \$? = $ac_status" >&5
16722 (exit "$ac_status"); }; }; then
16725 echo "$as_me: failed program was:" >&5
16726 cat "conftest.$ac_ext" >&5
16727 test -n "$verbose" && echo " test-compile failed. Undoing change to \$CFLAGS" 1>&6
16729 echo "${as_me:-configure}:16729: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5
16731 if test "x$cf_check_cppflags" != "x$CPPFLAGS" ; then
16732 test -n "$verbose" && echo " but keeping change to \$CPPFLAGS" 1>&6
16734 echo "${as_me:-configure}:16734: testing but keeping change to \$CPPFLAGS ..." 1>&5
16737 CFLAGS="$cf_check_cflags"
16739 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
16742 echo "$as_me:16742: checking for XOpenDisplay in -lX11" >&5
16743 echo $ECHO_N "checking for XOpenDisplay in -lX11... $ECHO_C" >&6
16744 if test "${ac_cv_lib_X11_XOpenDisplay+set}" = set; then
16745 echo $ECHO_N "(cached) $ECHO_C" >&6
16747 ac_check_lib_save_LIBS=$LIBS
16748 LIBS="-lX11 $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
16749 cat >"conftest.$ac_ext" <<_ACEOF
16750 #line 16750 "configure"
16751 #include "confdefs.h"
16753 /* Override any gcc2 internal prototype to avoid an error. */
16757 /* We use char because int might match the return type of a gcc2
16758 builtin and then its argument prototype would still apply. */
16759 char XOpenDisplay (void);
16768 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
16769 if { (eval echo "$as_me:16769: \"$ac_link\"") >&5
16770 (eval $ac_link) 2>&5
16772 echo "$as_me:16772: \$? = $ac_status" >&5
16773 (exit "$ac_status"); } &&
16774 { ac_try='test -s "conftest$ac_exeext"'
16775 { (eval echo "$as_me:16775: \"$ac_try\"") >&5
16776 (eval $ac_try) 2>&5
16778 echo "$as_me:16778: \$? = $ac_status" >&5
16779 (exit "$ac_status"); }; }; then
16780 ac_cv_lib_X11_XOpenDisplay=yes
16782 echo "$as_me: failed program was:" >&5
16783 cat "conftest.$ac_ext" >&5
16784 ac_cv_lib_X11_XOpenDisplay=no
16786 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
16787 LIBS=$ac_check_lib_save_LIBS
16789 echo "$as_me:16789: result: $ac_cv_lib_X11_XOpenDisplay" >&5
16790 echo "${ECHO_T}$ac_cv_lib_X11_XOpenDisplay" >&6
16791 if test "$ac_cv_lib_X11_XOpenDisplay" = yes; then
16793 cf_add_libs="$LIBS"
16796 for cf_add_1lib in -lX11; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
16797 # filter duplicates
16798 for cf_add_1lib in $cf_add_0lib; do
16799 for cf_add_2lib in $cf_add_libs; do
16800 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
16805 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
16807 LIBS="$cf_add_libs"
16811 echo "$as_me:16811: checking for XCurses library" >&5
16812 echo $ECHO_N "checking for XCurses library... $ECHO_C" >&6
16813 if test "${cf_cv_lib_XCurses+set}" = set; then
16814 echo $ECHO_N "(cached) $ECHO_C" >&6
16817 cf_add_libs="$LIBS"
16820 for cf_add_1lib in -lXCurses; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
16821 # filter duplicates
16822 for cf_add_1lib in $cf_add_0lib; do
16823 for cf_add_2lib in $cf_add_libs; do
16824 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
16829 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
16831 LIBS="$cf_add_libs"
16833 cat >"conftest.$ac_ext" <<_ACEOF
16834 #line 16834 "configure"
16835 #include "confdefs.h"
16837 #include <xcurses.h>
16838 char *XCursesProgramName = "test";
16848 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
16849 if { (eval echo "$as_me:16849: \"$ac_link\"") >&5
16850 (eval $ac_link) 2>&5
16852 echo "$as_me:16852: \$? = $ac_status" >&5
16853 (exit "$ac_status"); } &&
16854 { ac_try='test -s "conftest$ac_exeext"'
16855 { (eval echo "$as_me:16855: \"$ac_try\"") >&5
16856 (eval $ac_try) 2>&5
16858 echo "$as_me:16858: \$? = $ac_status" >&5
16859 (exit "$ac_status"); }; }; then
16860 cf_cv_lib_XCurses=yes
16862 echo "$as_me: failed program was:" >&5
16863 cat "conftest.$ac_ext" >&5
16864 cf_cv_lib_XCurses=no
16866 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
16869 echo "$as_me:16869: result: $cf_cv_lib_XCurses" >&5
16870 echo "${ECHO_T}$cf_cv_lib_XCurses" >&6
16874 if test "$cf_cv_lib_XCurses" = yes ; then
16876 cat >>confdefs.h <<\EOF
16880 cat >>confdefs.h <<\EOF
16884 echo "$as_me:16884: checking for xcurses.h" >&5
16885 echo $ECHO_N "checking for xcurses.h... $ECHO_C" >&6
16886 if test "${ac_cv_header_xcurses_h+set}" = set; then
16887 echo $ECHO_N "(cached) $ECHO_C" >&6
16889 cat >"conftest.$ac_ext" <<_ACEOF
16890 #line 16890 "configure"
16891 #include "confdefs.h"
16892 #include <xcurses.h>
16894 if { (eval echo "$as_me:16894: \"$ac_cpp "conftest.$ac_ext"\"") >&5
16895 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
16897 $EGREP -v '^ *\+' conftest.er1 >conftest.err
16899 cat conftest.err >&5
16900 echo "$as_me:16900: \$? = $ac_status" >&5
16901 (exit "$ac_status"); } >/dev/null; then
16902 if test -s conftest.err; then
16903 ac_cpp_err=$ac_c_preproc_warn_flag
16910 if test -z "$ac_cpp_err"; then
16911 ac_cv_header_xcurses_h=yes
16913 echo "$as_me: failed program was:" >&5
16914 cat "conftest.$ac_ext" >&5
16915 ac_cv_header_xcurses_h=no
16917 rm -f conftest.err "conftest.$ac_ext"
16919 echo "$as_me:16919: result: $ac_cv_header_xcurses_h" >&5
16920 echo "${ECHO_T}$ac_cv_header_xcurses_h" >&6
16921 if test "$ac_cv_header_xcurses_h" = yes; then
16923 cat >>confdefs.h <<\EOF
16924 #define HAVE_XCURSES 1
16930 { { echo "$as_me:16930: error: Cannot link with XCurses" >&5
16931 echo "$as_me: error: Cannot link with XCurses" >&2;}
16932 { (exit 1); exit 1; }; }
16937 { { echo "$as_me:16937: error: unexpected screen-value: $cf_cv_screen" >&5
16938 echo "$as_me: error: unexpected screen-value: $cf_cv_screen" >&2;}
16939 { (exit 1); exit 1; }; }
16943 : ${cf_nculib_root:=$cf_cv_screen}
16944 as_ac_Lib=`echo "ac_cv_lib_$cf_nculib_root''__nc_init_pthreads" | $as_tr_sh`
16945 echo "$as_me:16945: checking for _nc_init_pthreads in -l$cf_nculib_root" >&5
16946 echo $ECHO_N "checking for _nc_init_pthreads in -l$cf_nculib_root... $ECHO_C" >&6
16947 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
16948 echo $ECHO_N "(cached) $ECHO_C" >&6
16950 ac_check_lib_save_LIBS=$LIBS
16951 LIBS="-l$cf_nculib_root $LIBS"
16952 cat >"conftest.$ac_ext" <<_ACEOF
16953 #line 16953 "configure"
16954 #include "confdefs.h"
16956 /* Override any gcc2 internal prototype to avoid an error. */
16960 /* We use char because int might match the return type of a gcc2
16961 builtin and then its argument prototype would still apply. */
16962 char _nc_init_pthreads (void);
16966 _nc_init_pthreads ();
16971 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
16972 if { (eval echo "$as_me:16972: \"$ac_link\"") >&5
16973 (eval $ac_link) 2>&5
16975 echo "$as_me:16975: \$? = $ac_status" >&5
16976 (exit "$ac_status"); } &&
16977 { ac_try='test -s "conftest$ac_exeext"'
16978 { (eval echo "$as_me:16978: \"$ac_try\"") >&5
16979 (eval $ac_try) 2>&5
16981 echo "$as_me:16981: \$? = $ac_status" >&5
16982 (exit "$ac_status"); }; }; then
16983 eval "$as_ac_Lib=yes"
16985 echo "$as_me: failed program was:" >&5
16986 cat "conftest.$ac_ext" >&5
16987 eval "$as_ac_Lib=no"
16989 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
16990 LIBS=$ac_check_lib_save_LIBS
16992 echo "$as_me:16992: result: `eval echo '${'"$as_ac_Lib"'}'`" >&5
16993 echo "${ECHO_T}`eval echo '${'"$as_ac_Lib"'}'`" >&6
16994 if test "`eval echo '${'"$as_ac_Lib"'}'`" = yes; then
16995 cf_cv_ncurses_pthreads=yes
16997 cf_cv_ncurses_pthreads=no
17000 if test "$cf_cv_ncurses_pthreads" = yes
17003 cf_add_libs="$LIBS"
17006 for cf_add_1lib in -lpthread; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
17007 # filter duplicates
17008 for cf_add_1lib in $cf_add_0lib; do
17009 for cf_add_2lib in $cf_add_libs; do
17010 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
17015 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
17017 LIBS="$cf_add_libs"
17021 case $cf_cv_screen in
17023 cf_cv_libtype=`echo "$cf_cv_screen" | sed -e 's/^ncurses//'`
17027 echo "$as_me:17027: checking for X11 rgb file" >&5
17028 echo $ECHO_N "checking for X11 rgb file... $ECHO_C" >&6
17030 # Check whether --with-x11-rgb or --without-x11-rgb was given.
17031 if test "${with_x11_rgb+set}" = set; then
17032 withval="$with_x11_rgb"
17038 if test "x$RGB_PATH" = xauto
17040 RGB_PATH='${exec_prefix}/lib/X11/rgb.txt'
17042 /opt/local/share/X11/rgb.txt \
17043 /opt/X11/share/X11/rgb.txt \
17044 /usr/share/X11/rgb.txt \
17045 /usr/X11/share/X11/rgb.txt \
17046 /usr/X11/lib/X11/rgb.txt \
17047 /usr/lib/X11/rgb.txt \
17049 /usr/pkg/lib/X11/rgb.txt \
17050 /usr/X11R7/lib/X11/rgb.txt \
17051 /usr/X11R6/lib/X11/rgb.txt \
17052 /usr/X11R5/lib/X11/rgb.txt \
17053 /usr/X11R4/lib/X11/rgb.txt \
17054 /usr/local/lib/X11/rgb.txt \
17055 /usr/local/share/X11/rgb.txt \
17056 /usr/lib64/X11/rgb.txt
17058 if test -f "$cf_path" ; then
17059 RGB_PATH="$cf_path"
17066 if test "x$prefix" != xNONE; then
17067 cf_path_syntax="$prefix"
17069 cf_path_syntax="$ac_default_prefix"
17072 case ".$cf_path" in
17073 (.\$\(*\)*|.\'*\'*)
17077 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
17079 (.\$\{*prefix\}*|.\$\{*dir\}*)
17080 eval cf_path="$cf_path"
17081 case ".$cf_path" in
17083 cf_path=`echo "$cf_path" | sed -e s%NONE%$cf_path_syntax%`
17088 cf_path=`echo "$cf_path" | sed -e s%NONE%$cf_path_syntax%`
17091 { { echo "$as_me:17091: error: expected a pathname, not \"$cf_path\"" >&5
17092 echo "$as_me: error: expected a pathname, not \"$cf_path\"" >&2;}
17093 { (exit 1); exit 1; }; }
17099 echo "$as_me:17099: result: $RGB_PATH" >&5
17100 echo "${ECHO_T}$RGB_PATH" >&6
17102 cat >>confdefs.h <<EOF
17103 #define RGB_PATH "$cf_path"
17107 if test "$RGB_PATH" = no
17114 case $cf_cv_screen in
17116 cf_default_panel=no
17119 cf_default_tinfo=no
17121 (xcurses|bsdcurses)
17122 cf_default_panel=no
17125 cf_default_tinfo=yes
17128 cf_default_panel=yes
17129 cf_default_form=yes
17130 cf_default_menu=yes
17131 cf_default_tinfo=yes
17132 case $cf_cv_screen in
17134 cf_curses_headers="nc_alloc.h nomacros.h term_entry.h"
17140 echo "$as_me:17140: checking for desired basename for form library" >&5
17141 echo $ECHO_N "checking for desired basename for form library... $ECHO_C" >&6
17143 # Check whether --with-form-libname or --without-form-libname was given.
17144 if test "${with_form_libname+set}" = set; then
17145 withval="$with_form_libname"
17146 with_lib_basename=$withval
17148 with_lib_basename=form
17150 FORM_NAME="$with_lib_basename"
17152 case "x$FORM_NAME" in
17160 echo "$as_me:17160: result: $FORM_NAME" >&5
17161 echo "${ECHO_T}$FORM_NAME" >&6
17163 echo "$as_me:17163: checking for desired basename for menu library" >&5
17164 echo $ECHO_N "checking for desired basename for menu library... $ECHO_C" >&6
17166 # Check whether --with-menu-libname or --without-menu-libname was given.
17167 if test "${with_menu_libname+set}" = set; then
17168 withval="$with_menu_libname"
17169 with_lib_basename=$withval
17171 with_lib_basename=menu
17173 MENU_NAME="$with_lib_basename"
17175 case "x$MENU_NAME" in
17183 echo "$as_me:17183: result: $MENU_NAME" >&5
17184 echo "${ECHO_T}$MENU_NAME" >&6
17186 echo "$as_me:17186: checking for desired basename for panel library" >&5
17187 echo $ECHO_N "checking for desired basename for panel library... $ECHO_C" >&6
17189 # Check whether --with-panel-libname or --without-panel-libname was given.
17190 if test "${with_panel_libname+set}" = set; then
17191 withval="$with_panel_libname"
17192 with_lib_basename=$withval
17194 with_lib_basename=panel
17196 PANEL_NAME="$with_lib_basename"
17198 case "x$PANEL_NAME" in
17206 echo "$as_me:17206: result: $PANEL_NAME" >&5
17207 echo "${ECHO_T}$PANEL_NAME" >&6
17209 echo "$as_me:17209: checking if you want to check for panel functions" >&5
17210 echo $ECHO_N "checking if you want to check for panel functions... $ECHO_C" >&6
17212 # Check whether --enable-panel or --disable-panel was given.
17213 if test "${enable_panel+set}" = set; then
17214 enableval="$enable_panel"
17215 test "$enableval" != no && enableval=yes
17216 if test "$enableval" != "yes" ; then
17219 cf_enable_panel=$cf_default_panel
17223 cf_enable_panel=$cf_default_panel
17226 echo "$as_me:17226: result: $cf_enable_panel" >&5
17227 echo "${ECHO_T}$cf_enable_panel" >&6
17228 if test $cf_enable_panel = yes
17231 cf_have_curses_lib=no
17233 : ${NCURSES_CONFIG_PKG:=none}
17234 if test "x${NCURSES_CONFIG_PKG}" = xnone; then
17236 elif test "x${PKG_CONFIG:=none}" != xnone; then
17237 echo "$as_me:17237: checking pkg-config for $PANEL_NAME$cf_cv_libtype" >&5
17238 echo $ECHO_N "checking pkg-config for $PANEL_NAME$cf_cv_libtype... $ECHO_C" >&6
17239 if "$PKG_CONFIG" --exists "$PANEL_NAME$cf_cv_libtype" ; then
17240 echo "$as_me:17240: result: yes" >&5
17241 echo "${ECHO_T}yes" >&6
17243 echo "$as_me:17243: checking if the $PANEL_NAME$cf_cv_libtype package files work" >&5
17244 echo $ECHO_N "checking if the $PANEL_NAME$cf_cv_libtype package files work... $ECHO_C" >&6
17246 cf_save_CFLAGS="$CFLAGS"
17247 cf_save_CPPFLAGS="$CPPFLAGS"
17248 cf_save_LIBS="$LIBS"
17250 for cf_add_cflags in `$PKG_CONFIG --cflags "$PANEL_NAME$cf_cv_libtype"`
17252 case "x$cf_add_cflags" in
17255 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
17258 cf_old_cflag=`echo "x$CFLAGS" | sed -e 's/^.//' -e 's/[ ][ ]*-/ -/g' -e "s%$cf_tmp_cflag\\(=[^ ][^ ]*\\)\?%%" -e 's/^[ ]*//' -e 's%[ ][ ]*-D% -D%g' -e 's%[ ][ ]*-I% -I%g'`
17259 test "$CFLAGS" != "$cf_old_cflag" || break
17261 CFLAGS="$cf_old_cflag"
17264 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
17267 cf_old_cflag=`echo "x$CPPFLAGS" | sed -e 's/^.//' -e 's/[ ][ ]*-/ -/g' -e "s%$cf_tmp_cflag\\(=[^ ][^ ]*\\)\?%%" -e 's/^[ ]*//' -e 's%[ ][ ]*-D% -D%g' -e 's%[ ][ ]*-I% -I%g'`
17268 test "$CPPFLAGS" != "$cf_old_cflag" || break
17270 CPPFLAGS="$cf_old_cflag"
17279 cf_new_extra_cppflags=
17281 for cf_add_cflags in $cf_add_cflags
17283 case "$cf_fix_cppflags" in
17285 case "$cf_add_cflags" in
17286 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
17287 case "$cf_add_cflags" in
17289 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
17291 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
17292 && test -z "${cf_tst_cflags}" \
17293 && cf_fix_cppflags=yes
17295 if test "$cf_fix_cppflags" = yes ; then
17297 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
17298 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
17301 elif test "${cf_tst_cflags}" = "\"'" ; then
17303 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
17304 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
17310 case "$CPPFLAGS" in
17314 case "$cf_add_cflags" in
17316 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
17318 CPPFLAGS=`echo "$CPPFLAGS" | \
17319 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
17320 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
17325 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
17326 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
17333 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
17334 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
17341 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
17342 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
17344 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
17346 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
17347 && test -z "${cf_tst_cflags}" \
17348 && cf_fix_cppflags=no
17353 if test -n "$cf_new_cflags" ; then
17355 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
17356 CFLAGS="${CFLAGS}$cf_new_cflags"
17360 if test -n "$cf_new_cppflags" ; then
17362 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
17363 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
17367 if test -n "$cf_new_extra_cppflags" ; then
17369 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
17370 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
17376 cf_add_libs="$LIBS"
17379 for cf_add_1lib in `$PKG_CONFIG --libs "$PANEL_NAME$cf_cv_libtype"`; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
17380 # filter duplicates
17381 for cf_add_1lib in $cf_add_0lib; do
17382 for cf_add_2lib in $cf_add_libs; do
17383 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
17388 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
17390 LIBS="$cf_add_libs"
17392 cat >"conftest.$ac_ext" <<_ACEOF
17393 #line 17393 "configure"
17394 #include "confdefs.h"
17395 #include <$PANEL_NAME.h>
17399 (void) new_panel ( 0 );
17404 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
17405 if { (eval echo "$as_me:17405: \"$ac_link\"") >&5
17406 (eval $ac_link) 2>&5
17408 echo "$as_me:17408: \$? = $ac_status" >&5
17409 (exit "$ac_status"); } &&
17410 { ac_try='test -s "conftest$ac_exeext"'
17411 { (eval echo "$as_me:17411: \"$ac_try\"") >&5
17412 (eval $ac_try) 2>&5
17414 echo "$as_me:17414: \$? = $ac_status" >&5
17415 (exit "$ac_status"); }; }; then
17416 if test "$cross_compiling" = yes; then
17417 cf_have_curses_lib=maybe
17419 cat >"conftest.$ac_ext" <<_ACEOF
17420 #line 17420 "configure"
17421 #include "confdefs.h"
17422 #include <$PANEL_NAME.h>
17424 { (void) new_panel ( 0 ); return 0; }
17426 rm -f "conftest$ac_exeext"
17427 if { (eval echo "$as_me:17427: \"$ac_link\"") >&5
17428 (eval $ac_link) 2>&5
17430 echo "$as_me:17430: \$? = $ac_status" >&5
17431 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
17432 { (eval echo "$as_me:17432: \"$ac_try\"") >&5
17433 (eval $ac_try) 2>&5
17435 echo "$as_me:17435: \$? = $ac_status" >&5
17436 (exit "$ac_status"); }; }; then
17437 cf_have_curses_lib=yes
17439 echo "$as_me: program exited with status $ac_status" >&5
17440 echo "$as_me: failed program was:" >&5
17441 cat "conftest.$ac_ext" >&5
17442 cf_have_curses_lib=no
17444 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
17447 echo "$as_me: failed program was:" >&5
17448 cat "conftest.$ac_ext" >&5
17449 cf_have_curses_lib=no
17451 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
17452 echo "$as_me:17452: result: $cf_have_curses_lib" >&5
17453 echo "${ECHO_T}$cf_have_curses_lib" >&6
17454 test "$cf_have_curses_lib" = maybe && cf_have_curses_lib=yes
17455 if test "$cf_have_curses_lib" = "yes"
17458 cf_upper=`echo "have_lib$PANEL_NAME" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
17460 cat >>confdefs.h <<EOF
17461 #define $cf_upper 1
17465 CFLAGS="$cf_save_CFLAGS"
17466 CPPFLAGS="$cf_save_CPPFLAGS"
17467 LIBS="$cf_save_LIBS"
17471 if test "$cf_have_curses_lib" = no; then
17472 as_ac_Lib=`echo "ac_cv_lib_$PANEL_NAME$cf_cv_libtype''_new_panel" | $as_tr_sh`
17473 echo "$as_me:17473: checking for new_panel in -l$PANEL_NAME$cf_cv_libtype" >&5
17474 echo $ECHO_N "checking for new_panel in -l$PANEL_NAME$cf_cv_libtype... $ECHO_C" >&6
17475 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
17476 echo $ECHO_N "(cached) $ECHO_C" >&6
17478 ac_check_lib_save_LIBS=$LIBS
17479 LIBS="-l$PANEL_NAME$cf_cv_libtype $LIBS"
17480 cat >"conftest.$ac_ext" <<_ACEOF
17481 #line 17481 "configure"
17482 #include "confdefs.h"
17484 /* Override any gcc2 internal prototype to avoid an error. */
17488 /* We use char because int might match the return type of a gcc2
17489 builtin and then its argument prototype would still apply. */
17490 char new_panel (void);
17499 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
17500 if { (eval echo "$as_me:17500: \"$ac_link\"") >&5
17501 (eval $ac_link) 2>&5
17503 echo "$as_me:17503: \$? = $ac_status" >&5
17504 (exit "$ac_status"); } &&
17505 { ac_try='test -s "conftest$ac_exeext"'
17506 { (eval echo "$as_me:17506: \"$ac_try\"") >&5
17507 (eval $ac_try) 2>&5
17509 echo "$as_me:17509: \$? = $ac_status" >&5
17510 (exit "$ac_status"); }; }; then
17511 eval "$as_ac_Lib=yes"
17513 echo "$as_me: failed program was:" >&5
17514 cat "conftest.$ac_ext" >&5
17515 eval "$as_ac_Lib=no"
17517 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
17518 LIBS=$ac_check_lib_save_LIBS
17520 echo "$as_me:17520: result: `eval echo '${'"$as_ac_Lib"'}'`" >&5
17521 echo "${ECHO_T}`eval echo '${'"$as_ac_Lib"'}'`" >&6
17522 if test "`eval echo '${'"$as_ac_Lib"'}'`" = yes; then
17524 cf_upper=`echo "have_lib$PANEL_NAME" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
17526 cf_add_libs="$LIBS"
17529 for cf_add_1lib in -l$PANEL_NAME$cf_cv_libtype; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
17530 # filter duplicates
17531 for cf_add_1lib in $cf_add_0lib; do
17532 for cf_add_2lib in $cf_add_libs; do
17533 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
17538 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
17540 LIBS="$cf_add_libs"
17542 cat >>confdefs.h <<EOF
17543 #define $cf_upper 1
17550 cf_curses_headers="$cf_curses_headers panel.h"
17553 echo "$as_me:17553: checking if you want to check for menu functions" >&5
17554 echo $ECHO_N "checking if you want to check for menu functions... $ECHO_C" >&6
17556 # Check whether --enable-menu or --disable-menu was given.
17557 if test "${enable_menu+set}" = set; then
17558 enableval="$enable_menu"
17559 test "$enableval" != no && enableval=yes
17560 if test "$enableval" != "yes" ; then
17563 cf_enable_menu=$cf_default_menu
17567 cf_enable_menu=$cf_default_menu
17570 echo "$as_me:17570: result: $cf_enable_menu" >&5
17571 echo "${ECHO_T}$cf_enable_menu" >&6
17572 if test $cf_enable_menu = yes
17574 case $cf_cv_screen in
17579 echo "$as_me:17579: checking for NetBSD menu.h" >&5
17580 echo $ECHO_N "checking for NetBSD menu.h... $ECHO_C" >&6
17581 if test "${cf_cv_netbsd_menu_h+set}" = set; then
17582 echo $ECHO_N "(cached) $ECHO_C" >&6
17585 cat >"conftest.$ac_ext" <<_ACEOF
17586 #line 17586 "configure"
17587 #include "confdefs.h"
17589 #include <${cf_cv_ncurses_header:-curses.h}>
17597 int y = menu->max_item_width;
17603 rm -f "conftest.$ac_objext"
17604 if { (eval echo "$as_me:17604: \"$ac_compile\"") >&5
17605 (eval $ac_compile) 2>&5
17607 echo "$as_me:17607: \$? = $ac_status" >&5
17608 (exit "$ac_status"); } &&
17609 { ac_try='test -s "conftest.$ac_objext"'
17610 { (eval echo "$as_me:17610: \"$ac_try\"") >&5
17611 (eval $ac_try) 2>&5
17613 echo "$as_me:17613: \$? = $ac_status" >&5
17614 (exit "$ac_status"); }; }; then
17615 cf_cv_netbsd_menu_h=yes
17618 echo "$as_me: failed program was:" >&5
17619 cat "conftest.$ac_ext" >&5
17620 cf_cv_netbsd_menu_h=no
17622 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
17625 echo "$as_me:17625: result: $cf_cv_netbsd_menu_h" >&5
17626 echo "${ECHO_T}$cf_cv_netbsd_menu_h" >&6
17628 test "$cf_cv_netbsd_menu_h" = yes &&
17629 cat >>confdefs.h <<\EOF
17630 #define HAVE_NETBSD_MENU_H 1
17636 cf_have_curses_lib=no
17638 : ${NCURSES_CONFIG_PKG:=none}
17639 if test "x${NCURSES_CONFIG_PKG}" = xnone; then
17641 elif test "x${PKG_CONFIG:=none}" != xnone; then
17642 echo "$as_me:17642: checking pkg-config for $MENU_NAME$cf_cv_libtype" >&5
17643 echo $ECHO_N "checking pkg-config for $MENU_NAME$cf_cv_libtype... $ECHO_C" >&6
17644 if "$PKG_CONFIG" --exists "$MENU_NAME$cf_cv_libtype" ; then
17645 echo "$as_me:17645: result: yes" >&5
17646 echo "${ECHO_T}yes" >&6
17648 echo "$as_me:17648: checking if the $MENU_NAME$cf_cv_libtype package files work" >&5
17649 echo $ECHO_N "checking if the $MENU_NAME$cf_cv_libtype package files work... $ECHO_C" >&6
17651 cf_save_CFLAGS="$CFLAGS"
17652 cf_save_CPPFLAGS="$CPPFLAGS"
17653 cf_save_LIBS="$LIBS"
17655 for cf_add_cflags in `$PKG_CONFIG --cflags "$MENU_NAME$cf_cv_libtype"`
17657 case "x$cf_add_cflags" in
17660 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
17663 cf_old_cflag=`echo "x$CFLAGS" | sed -e 's/^.//' -e 's/[ ][ ]*-/ -/g' -e "s%$cf_tmp_cflag\\(=[^ ][^ ]*\\)\?%%" -e 's/^[ ]*//' -e 's%[ ][ ]*-D% -D%g' -e 's%[ ][ ]*-I% -I%g'`
17664 test "$CFLAGS" != "$cf_old_cflag" || break
17666 CFLAGS="$cf_old_cflag"
17669 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
17672 cf_old_cflag=`echo "x$CPPFLAGS" | sed -e 's/^.//' -e 's/[ ][ ]*-/ -/g' -e "s%$cf_tmp_cflag\\(=[^ ][^ ]*\\)\?%%" -e 's/^[ ]*//' -e 's%[ ][ ]*-D% -D%g' -e 's%[ ][ ]*-I% -I%g'`
17673 test "$CPPFLAGS" != "$cf_old_cflag" || break
17675 CPPFLAGS="$cf_old_cflag"
17684 cf_new_extra_cppflags=
17686 for cf_add_cflags in $cf_add_cflags
17688 case "$cf_fix_cppflags" in
17690 case "$cf_add_cflags" in
17691 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
17692 case "$cf_add_cflags" in
17694 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
17696 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
17697 && test -z "${cf_tst_cflags}" \
17698 && cf_fix_cppflags=yes
17700 if test "$cf_fix_cppflags" = yes ; then
17702 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
17703 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
17706 elif test "${cf_tst_cflags}" = "\"'" ; then
17708 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
17709 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
17715 case "$CPPFLAGS" in
17719 case "$cf_add_cflags" in
17721 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
17723 CPPFLAGS=`echo "$CPPFLAGS" | \
17724 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
17725 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
17730 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
17731 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
17738 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
17739 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
17746 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
17747 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
17749 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
17751 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
17752 && test -z "${cf_tst_cflags}" \
17753 && cf_fix_cppflags=no
17758 if test -n "$cf_new_cflags" ; then
17760 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
17761 CFLAGS="${CFLAGS}$cf_new_cflags"
17765 if test -n "$cf_new_cppflags" ; then
17767 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
17768 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
17772 if test -n "$cf_new_extra_cppflags" ; then
17774 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
17775 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
17781 cf_add_libs="$LIBS"
17784 for cf_add_1lib in `$PKG_CONFIG --libs "$MENU_NAME$cf_cv_libtype"`; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
17785 # filter duplicates
17786 for cf_add_1lib in $cf_add_0lib; do
17787 for cf_add_2lib in $cf_add_libs; do
17788 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
17793 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
17795 LIBS="$cf_add_libs"
17797 cat >"conftest.$ac_ext" <<_ACEOF
17798 #line 17798 "configure"
17799 #include "confdefs.h"
17800 #include <$MENU_NAME.h>
17804 (void) menu_driver ( 0,0 );
17809 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
17810 if { (eval echo "$as_me:17810: \"$ac_link\"") >&5
17811 (eval $ac_link) 2>&5
17813 echo "$as_me:17813: \$? = $ac_status" >&5
17814 (exit "$ac_status"); } &&
17815 { ac_try='test -s "conftest$ac_exeext"'
17816 { (eval echo "$as_me:17816: \"$ac_try\"") >&5
17817 (eval $ac_try) 2>&5
17819 echo "$as_me:17819: \$? = $ac_status" >&5
17820 (exit "$ac_status"); }; }; then
17821 if test "$cross_compiling" = yes; then
17822 cf_have_curses_lib=maybe
17824 cat >"conftest.$ac_ext" <<_ACEOF
17825 #line 17825 "configure"
17826 #include "confdefs.h"
17827 #include <$MENU_NAME.h>
17829 { (void) menu_driver ( 0,0 ); return 0; }
17831 rm -f "conftest$ac_exeext"
17832 if { (eval echo "$as_me:17832: \"$ac_link\"") >&5
17833 (eval $ac_link) 2>&5
17835 echo "$as_me:17835: \$? = $ac_status" >&5
17836 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
17837 { (eval echo "$as_me:17837: \"$ac_try\"") >&5
17838 (eval $ac_try) 2>&5
17840 echo "$as_me:17840: \$? = $ac_status" >&5
17841 (exit "$ac_status"); }; }; then
17842 cf_have_curses_lib=yes
17844 echo "$as_me: program exited with status $ac_status" >&5
17845 echo "$as_me: failed program was:" >&5
17846 cat "conftest.$ac_ext" >&5
17847 cf_have_curses_lib=no
17849 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
17852 echo "$as_me: failed program was:" >&5
17853 cat "conftest.$ac_ext" >&5
17854 cf_have_curses_lib=no
17856 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
17857 echo "$as_me:17857: result: $cf_have_curses_lib" >&5
17858 echo "${ECHO_T}$cf_have_curses_lib" >&6
17859 test "$cf_have_curses_lib" = maybe && cf_have_curses_lib=yes
17860 if test "$cf_have_curses_lib" = "yes"
17863 cf_upper=`echo "have_lib$MENU_NAME" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
17865 cat >>confdefs.h <<EOF
17866 #define $cf_upper 1
17870 CFLAGS="$cf_save_CFLAGS"
17871 CPPFLAGS="$cf_save_CPPFLAGS"
17872 LIBS="$cf_save_LIBS"
17876 if test "$cf_have_curses_lib" = no; then
17877 as_ac_Lib=`echo "ac_cv_lib_$MENU_NAME$cf_cv_libtype''_menu_driver" | $as_tr_sh`
17878 echo "$as_me:17878: checking for menu_driver in -l$MENU_NAME$cf_cv_libtype" >&5
17879 echo $ECHO_N "checking for menu_driver in -l$MENU_NAME$cf_cv_libtype... $ECHO_C" >&6
17880 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
17881 echo $ECHO_N "(cached) $ECHO_C" >&6
17883 ac_check_lib_save_LIBS=$LIBS
17884 LIBS="-l$MENU_NAME$cf_cv_libtype $LIBS"
17885 cat >"conftest.$ac_ext" <<_ACEOF
17886 #line 17886 "configure"
17887 #include "confdefs.h"
17889 /* Override any gcc2 internal prototype to avoid an error. */
17893 /* We use char because int might match the return type of a gcc2
17894 builtin and then its argument prototype would still apply. */
17895 char menu_driver (void);
17904 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
17905 if { (eval echo "$as_me:17905: \"$ac_link\"") >&5
17906 (eval $ac_link) 2>&5
17908 echo "$as_me:17908: \$? = $ac_status" >&5
17909 (exit "$ac_status"); } &&
17910 { ac_try='test -s "conftest$ac_exeext"'
17911 { (eval echo "$as_me:17911: \"$ac_try\"") >&5
17912 (eval $ac_try) 2>&5
17914 echo "$as_me:17914: \$? = $ac_status" >&5
17915 (exit "$ac_status"); }; }; then
17916 eval "$as_ac_Lib=yes"
17918 echo "$as_me: failed program was:" >&5
17919 cat "conftest.$ac_ext" >&5
17920 eval "$as_ac_Lib=no"
17922 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
17923 LIBS=$ac_check_lib_save_LIBS
17925 echo "$as_me:17925: result: `eval echo '${'"$as_ac_Lib"'}'`" >&5
17926 echo "${ECHO_T}`eval echo '${'"$as_ac_Lib"'}'`" >&6
17927 if test "`eval echo '${'"$as_ac_Lib"'}'`" = yes; then
17929 cf_upper=`echo "have_lib$MENU_NAME" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
17931 cf_add_libs="$LIBS"
17934 for cf_add_1lib in -l$MENU_NAME$cf_cv_libtype; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
17935 # filter duplicates
17936 for cf_add_1lib in $cf_add_0lib; do
17937 for cf_add_2lib in $cf_add_libs; do
17938 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
17943 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
17945 LIBS="$cf_add_libs"
17947 cat >>confdefs.h <<EOF
17948 #define $cf_upper 1
17955 cf_curses_headers="$cf_curses_headers menu.h"
17958 echo "$as_me:17958: checking if you want to check for form functions" >&5
17959 echo $ECHO_N "checking if you want to check for form functions... $ECHO_C" >&6
17961 # Check whether --enable-form or --disable-form was given.
17962 if test "${enable_form+set}" = set; then
17963 enableval="$enable_form"
17964 test "$enableval" != no && enableval=yes
17965 if test "$enableval" != "yes" ; then
17968 cf_enable_form=$cf_default_form
17972 cf_enable_form=$cf_default_form
17975 echo "$as_me:17975: result: $cf_enable_form" >&5
17976 echo "${ECHO_T}$cf_enable_form" >&6
17977 if test $cf_enable_form = yes
17979 case $cf_cv_screen in
17984 echo "$as_me:17984: checking for NetBSD form.h" >&5
17985 echo $ECHO_N "checking for NetBSD form.h... $ECHO_C" >&6
17986 if test "${cf_cv_netbsd_form_h+set}" = set; then
17987 echo $ECHO_N "(cached) $ECHO_C" >&6
17990 cat >"conftest.$ac_ext" <<_ACEOF
17991 #line 17991 "configure"
17992 #include "confdefs.h"
17994 #include <${cf_cv_ncurses_header:-curses.h}>
18002 int y = current_field(form)->cursor_ypos;
18003 int x = current_field(form)->cursor_xpos;
18009 rm -f "conftest.$ac_objext"
18010 if { (eval echo "$as_me:18010: \"$ac_compile\"") >&5
18011 (eval $ac_compile) 2>&5
18013 echo "$as_me:18013: \$? = $ac_status" >&5
18014 (exit "$ac_status"); } &&
18015 { ac_try='test -s "conftest.$ac_objext"'
18016 { (eval echo "$as_me:18016: \"$ac_try\"") >&5
18017 (eval $ac_try) 2>&5
18019 echo "$as_me:18019: \$? = $ac_status" >&5
18020 (exit "$ac_status"); }; }; then
18021 cf_cv_netbsd_form_h=yes
18024 echo "$as_me: failed program was:" >&5
18025 cat "conftest.$ac_ext" >&5
18026 cf_cv_netbsd_form_h=no
18028 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
18031 echo "$as_me:18031: result: $cf_cv_netbsd_form_h" >&5
18032 echo "${ECHO_T}$cf_cv_netbsd_form_h" >&6
18034 test "$cf_cv_netbsd_form_h" = yes &&
18035 cat >>confdefs.h <<\EOF
18036 #define HAVE_NETBSD_FORM_H 1
18042 cf_have_curses_lib=no
18044 : ${NCURSES_CONFIG_PKG:=none}
18045 if test "x${NCURSES_CONFIG_PKG}" = xnone; then
18047 elif test "x${PKG_CONFIG:=none}" != xnone; then
18048 echo "$as_me:18048: checking pkg-config for $FORM_NAME$cf_cv_libtype" >&5
18049 echo $ECHO_N "checking pkg-config for $FORM_NAME$cf_cv_libtype... $ECHO_C" >&6
18050 if "$PKG_CONFIG" --exists "$FORM_NAME$cf_cv_libtype" ; then
18051 echo "$as_me:18051: result: yes" >&5
18052 echo "${ECHO_T}yes" >&6
18054 echo "$as_me:18054: checking if the $FORM_NAME$cf_cv_libtype package files work" >&5
18055 echo $ECHO_N "checking if the $FORM_NAME$cf_cv_libtype package files work... $ECHO_C" >&6
18057 cf_save_CFLAGS="$CFLAGS"
18058 cf_save_CPPFLAGS="$CPPFLAGS"
18059 cf_save_LIBS="$LIBS"
18061 for cf_add_cflags in `$PKG_CONFIG --cflags "$FORM_NAME$cf_cv_libtype"`
18063 case "x$cf_add_cflags" in
18066 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
18069 cf_old_cflag=`echo "x$CFLAGS" | sed -e 's/^.//' -e 's/[ ][ ]*-/ -/g' -e "s%$cf_tmp_cflag\\(=[^ ][^ ]*\\)\?%%" -e 's/^[ ]*//' -e 's%[ ][ ]*-D% -D%g' -e 's%[ ][ ]*-I% -I%g'`
18070 test "$CFLAGS" != "$cf_old_cflag" || break
18072 CFLAGS="$cf_old_cflag"
18075 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
18078 cf_old_cflag=`echo "x$CPPFLAGS" | sed -e 's/^.//' -e 's/[ ][ ]*-/ -/g' -e "s%$cf_tmp_cflag\\(=[^ ][^ ]*\\)\?%%" -e 's/^[ ]*//' -e 's%[ ][ ]*-D% -D%g' -e 's%[ ][ ]*-I% -I%g'`
18079 test "$CPPFLAGS" != "$cf_old_cflag" || break
18081 CPPFLAGS="$cf_old_cflag"
18090 cf_new_extra_cppflags=
18092 for cf_add_cflags in $cf_add_cflags
18094 case "$cf_fix_cppflags" in
18096 case "$cf_add_cflags" in
18097 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
18098 case "$cf_add_cflags" in
18100 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
18102 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
18103 && test -z "${cf_tst_cflags}" \
18104 && cf_fix_cppflags=yes
18106 if test "$cf_fix_cppflags" = yes ; then
18108 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
18109 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
18112 elif test "${cf_tst_cflags}" = "\"'" ; then
18114 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
18115 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
18121 case "$CPPFLAGS" in
18125 case "$cf_add_cflags" in
18127 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
18129 CPPFLAGS=`echo "$CPPFLAGS" | \
18130 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
18131 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
18136 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
18137 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
18144 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
18145 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
18152 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
18153 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
18155 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
18157 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
18158 && test -z "${cf_tst_cflags}" \
18159 && cf_fix_cppflags=no
18164 if test -n "$cf_new_cflags" ; then
18166 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
18167 CFLAGS="${CFLAGS}$cf_new_cflags"
18171 if test -n "$cf_new_cppflags" ; then
18173 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
18174 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
18178 if test -n "$cf_new_extra_cppflags" ; then
18180 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
18181 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
18187 cf_add_libs="$LIBS"
18190 for cf_add_1lib in `$PKG_CONFIG --libs "$FORM_NAME$cf_cv_libtype"`; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
18191 # filter duplicates
18192 for cf_add_1lib in $cf_add_0lib; do
18193 for cf_add_2lib in $cf_add_libs; do
18194 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
18199 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
18201 LIBS="$cf_add_libs"
18203 cat >"conftest.$ac_ext" <<_ACEOF
18204 #line 18204 "configure"
18205 #include "confdefs.h"
18206 #include <$FORM_NAME.h>
18210 (void) form_driver ( 0,0 );
18215 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
18216 if { (eval echo "$as_me:18216: \"$ac_link\"") >&5
18217 (eval $ac_link) 2>&5
18219 echo "$as_me:18219: \$? = $ac_status" >&5
18220 (exit "$ac_status"); } &&
18221 { ac_try='test -s "conftest$ac_exeext"'
18222 { (eval echo "$as_me:18222: \"$ac_try\"") >&5
18223 (eval $ac_try) 2>&5
18225 echo "$as_me:18225: \$? = $ac_status" >&5
18226 (exit "$ac_status"); }; }; then
18227 if test "$cross_compiling" = yes; then
18228 cf_have_curses_lib=maybe
18230 cat >"conftest.$ac_ext" <<_ACEOF
18231 #line 18231 "configure"
18232 #include "confdefs.h"
18233 #include <$FORM_NAME.h>
18235 { (void) form_driver ( 0,0 ); return 0; }
18237 rm -f "conftest$ac_exeext"
18238 if { (eval echo "$as_me:18238: \"$ac_link\"") >&5
18239 (eval $ac_link) 2>&5
18241 echo "$as_me:18241: \$? = $ac_status" >&5
18242 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
18243 { (eval echo "$as_me:18243: \"$ac_try\"") >&5
18244 (eval $ac_try) 2>&5
18246 echo "$as_me:18246: \$? = $ac_status" >&5
18247 (exit "$ac_status"); }; }; then
18248 cf_have_curses_lib=yes
18250 echo "$as_me: program exited with status $ac_status" >&5
18251 echo "$as_me: failed program was:" >&5
18252 cat "conftest.$ac_ext" >&5
18253 cf_have_curses_lib=no
18255 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
18258 echo "$as_me: failed program was:" >&5
18259 cat "conftest.$ac_ext" >&5
18260 cf_have_curses_lib=no
18262 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
18263 echo "$as_me:18263: result: $cf_have_curses_lib" >&5
18264 echo "${ECHO_T}$cf_have_curses_lib" >&6
18265 test "$cf_have_curses_lib" = maybe && cf_have_curses_lib=yes
18266 if test "$cf_have_curses_lib" = "yes"
18269 cf_upper=`echo "have_lib$FORM_NAME" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
18271 cat >>confdefs.h <<EOF
18272 #define $cf_upper 1
18276 CFLAGS="$cf_save_CFLAGS"
18277 CPPFLAGS="$cf_save_CPPFLAGS"
18278 LIBS="$cf_save_LIBS"
18282 if test "$cf_have_curses_lib" = no; then
18283 as_ac_Lib=`echo "ac_cv_lib_$FORM_NAME$cf_cv_libtype''_form_driver" | $as_tr_sh`
18284 echo "$as_me:18284: checking for form_driver in -l$FORM_NAME$cf_cv_libtype" >&5
18285 echo $ECHO_N "checking for form_driver in -l$FORM_NAME$cf_cv_libtype... $ECHO_C" >&6
18286 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
18287 echo $ECHO_N "(cached) $ECHO_C" >&6
18289 ac_check_lib_save_LIBS=$LIBS
18290 LIBS="-l$FORM_NAME$cf_cv_libtype $LIBS"
18291 cat >"conftest.$ac_ext" <<_ACEOF
18292 #line 18292 "configure"
18293 #include "confdefs.h"
18295 /* Override any gcc2 internal prototype to avoid an error. */
18299 /* We use char because int might match the return type of a gcc2
18300 builtin and then its argument prototype would still apply. */
18301 char form_driver (void);
18310 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
18311 if { (eval echo "$as_me:18311: \"$ac_link\"") >&5
18312 (eval $ac_link) 2>&5
18314 echo "$as_me:18314: \$? = $ac_status" >&5
18315 (exit "$ac_status"); } &&
18316 { ac_try='test -s "conftest$ac_exeext"'
18317 { (eval echo "$as_me:18317: \"$ac_try\"") >&5
18318 (eval $ac_try) 2>&5
18320 echo "$as_me:18320: \$? = $ac_status" >&5
18321 (exit "$ac_status"); }; }; then
18322 eval "$as_ac_Lib=yes"
18324 echo "$as_me: failed program was:" >&5
18325 cat "conftest.$ac_ext" >&5
18326 eval "$as_ac_Lib=no"
18328 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
18329 LIBS=$ac_check_lib_save_LIBS
18331 echo "$as_me:18331: result: `eval echo '${'"$as_ac_Lib"'}'`" >&5
18332 echo "${ECHO_T}`eval echo '${'"$as_ac_Lib"'}'`" >&6
18333 if test "`eval echo '${'"$as_ac_Lib"'}'`" = yes; then
18335 cf_upper=`echo "have_lib$FORM_NAME" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
18337 cf_add_libs="$LIBS"
18340 for cf_add_1lib in -l$FORM_NAME$cf_cv_libtype; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
18341 # filter duplicates
18342 for cf_add_1lib in $cf_add_0lib; do
18343 for cf_add_2lib in $cf_add_libs; do
18344 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
18349 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
18351 LIBS="$cf_add_libs"
18353 cat >>confdefs.h <<EOF
18354 #define $cf_upper 1
18361 cf_curses_headers="$cf_curses_headers form.h"
18364 # look for curses-related headers
18366 for ac_header in $cf_curses_headers
18368 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
18369 echo "$as_me:18369: checking for $ac_header" >&5
18370 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18371 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18372 echo $ECHO_N "(cached) $ECHO_C" >&6
18374 cat >"conftest.$ac_ext" <<_ACEOF
18375 #line 18375 "configure"
18376 #include "confdefs.h"
18377 #include <$ac_header>
18379 if { (eval echo "$as_me:18379: \"$ac_cpp "conftest.$ac_ext"\"") >&5
18380 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
18382 $EGREP -v '^ *\+' conftest.er1 >conftest.err
18384 cat conftest.err >&5
18385 echo "$as_me:18385: \$? = $ac_status" >&5
18386 (exit "$ac_status"); } >/dev/null; then
18387 if test -s conftest.err; then
18388 ac_cpp_err=$ac_c_preproc_warn_flag
18395 if test -z "$ac_cpp_err"; then
18396 eval "$as_ac_Header=yes"
18398 echo "$as_me: failed program was:" >&5
18399 cat "conftest.$ac_ext" >&5
18400 eval "$as_ac_Header=no"
18402 rm -f conftest.err "conftest.$ac_ext"
18404 echo "$as_me:18404: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
18405 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
18406 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
18407 cat >>confdefs.h <<EOF
18408 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
18414 echo "$as_me:18414: checking whether time.h and sys/time.h may both be included" >&5
18415 echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
18416 if test "${ac_cv_header_time+set}" = set; then
18417 echo $ECHO_N "(cached) $ECHO_C" >&6
18419 cat >"conftest.$ac_ext" <<_ACEOF
18420 #line 18420 "configure"
18421 #include "confdefs.h"
18422 #include <sys/types.h>
18423 #include <sys/time.h>
18429 if ((struct tm *) 0)
18435 rm -f "conftest.$ac_objext"
18436 if { (eval echo "$as_me:18436: \"$ac_compile\"") >&5
18437 (eval $ac_compile) 2>&5
18439 echo "$as_me:18439: \$? = $ac_status" >&5
18440 (exit "$ac_status"); } &&
18441 { ac_try='test -s "conftest.$ac_objext"'
18442 { (eval echo "$as_me:18442: \"$ac_try\"") >&5
18443 (eval $ac_try) 2>&5
18445 echo "$as_me:18445: \$? = $ac_status" >&5
18446 (exit "$ac_status"); }; }; then
18447 ac_cv_header_time=yes
18449 echo "$as_me: failed program was:" >&5
18450 cat "conftest.$ac_ext" >&5
18451 ac_cv_header_time=no
18453 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
18455 echo "$as_me:18455: result: $ac_cv_header_time" >&5
18456 echo "${ECHO_T}$ac_cv_header_time" >&6
18457 if test $ac_cv_header_time = yes; then
18459 cat >>confdefs.h <<\EOF
18460 #define TIME_WITH_SYS_TIME 1
18477 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
18478 echo "$as_me:18478: checking for $ac_header" >&5
18479 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18480 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18481 echo $ECHO_N "(cached) $ECHO_C" >&6
18483 cat >"conftest.$ac_ext" <<_ACEOF
18484 #line 18484 "configure"
18485 #include "confdefs.h"
18486 #include <$ac_header>
18488 if { (eval echo "$as_me:18488: \"$ac_cpp "conftest.$ac_ext"\"") >&5
18489 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
18491 $EGREP -v '^ *\+' conftest.er1 >conftest.err
18493 cat conftest.err >&5
18494 echo "$as_me:18494: \$? = $ac_status" >&5
18495 (exit "$ac_status"); } >/dev/null; then
18496 if test -s conftest.err; then
18497 ac_cpp_err=$ac_c_preproc_warn_flag
18504 if test -z "$ac_cpp_err"; then
18505 eval "$as_ac_Header=yes"
18507 echo "$as_me: failed program was:" >&5
18508 cat "conftest.$ac_ext" >&5
18509 eval "$as_ac_Header=no"
18511 rm -f conftest.err "conftest.$ac_ext"
18513 echo "$as_me:18513: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
18514 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
18515 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
18516 cat >>confdefs.h <<EOF
18517 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
18523 for ac_header in unistd.h getopt.h
18525 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
18526 echo "$as_me:18526: checking for $ac_header" >&5
18527 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18528 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18529 echo $ECHO_N "(cached) $ECHO_C" >&6
18531 cat >"conftest.$ac_ext" <<_ACEOF
18532 #line 18532 "configure"
18533 #include "confdefs.h"
18534 #include <$ac_header>
18536 if { (eval echo "$as_me:18536: \"$ac_cpp "conftest.$ac_ext"\"") >&5
18537 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
18539 $EGREP -v '^ *\+' conftest.er1 >conftest.err
18541 cat conftest.err >&5
18542 echo "$as_me:18542: \$? = $ac_status" >&5
18543 (exit "$ac_status"); } >/dev/null; then
18544 if test -s conftest.err; then
18545 ac_cpp_err=$ac_c_preproc_warn_flag
18552 if test -z "$ac_cpp_err"; then
18553 eval "$as_ac_Header=yes"
18555 echo "$as_me: failed program was:" >&5
18556 cat "conftest.$ac_ext" >&5
18557 eval "$as_ac_Header=no"
18559 rm -f conftest.err "conftest.$ac_ext"
18561 echo "$as_me:18561: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
18562 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
18563 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
18564 cat >>confdefs.h <<EOF
18565 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
18571 echo "$as_me:18571: checking for header declaring getopt variables" >&5
18572 echo $ECHO_N "checking for header declaring getopt variables... $ECHO_C" >&6
18573 if test "${cf_cv_getopt_header+set}" = set; then
18574 echo $ECHO_N "(cached) $ECHO_C" >&6
18577 cf_cv_getopt_header=none
18578 for cf_header in stdio.h stdlib.h unistd.h getopt.h
18580 cat >"conftest.$ac_ext" <<_ACEOF
18581 #line 18581 "configure"
18582 #include "confdefs.h"
18584 #include <$cf_header>
18588 int x = optind; char *y = optarg; (void)x; (void)y
18593 rm -f "conftest.$ac_objext"
18594 if { (eval echo "$as_me:18594: \"$ac_compile\"") >&5
18595 (eval $ac_compile) 2>&5
18597 echo "$as_me:18597: \$? = $ac_status" >&5
18598 (exit "$ac_status"); } &&
18599 { ac_try='test -s "conftest.$ac_objext"'
18600 { (eval echo "$as_me:18600: \"$ac_try\"") >&5
18601 (eval $ac_try) 2>&5
18603 echo "$as_me:18603: \$? = $ac_status" >&5
18604 (exit "$ac_status"); }; }; then
18605 cf_cv_getopt_header=$cf_header
18608 echo "$as_me: failed program was:" >&5
18609 cat "conftest.$ac_ext" >&5
18611 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
18615 echo "$as_me:18615: result: $cf_cv_getopt_header" >&5
18616 echo "${ECHO_T}$cf_cv_getopt_header" >&6
18617 if test "$cf_cv_getopt_header" != none ; then
18619 cat >>confdefs.h <<\EOF
18620 #define HAVE_GETOPT_HEADER 1
18624 if test "$cf_cv_getopt_header" = getopt.h ; then
18626 cat >>confdefs.h <<\EOF
18627 #define NEED_GETOPT_H 1
18632 cf_save_libs="$LIBS"
18633 echo "$as_me:18633: checking for clock_gettime" >&5
18634 echo $ECHO_N "checking for clock_gettime... $ECHO_C" >&6
18635 if test "${ac_cv_func_clock_gettime+set}" = set; then
18636 echo $ECHO_N "(cached) $ECHO_C" >&6
18638 cat >"conftest.$ac_ext" <<_ACEOF
18639 #line 18639 "configure"
18640 #include "confdefs.h"
18641 #define clock_gettime autoconf_temporary
18642 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
18643 #undef clock_gettime
18649 /* We use char because int might match the return type of a gcc2
18650 builtin and then its argument prototype would still apply. */
18651 char clock_gettime (void);
18657 /* The GNU C library defines stubs for functions which it implements
18658 to always fail with ENOSYS. Some functions are actually named
18659 something starting with __ and the normal name is an alias. */
18660 #if defined (__stub_clock_gettime) || defined (__stub___clock_gettime)
18661 #error found stub for clock_gettime
18664 return clock_gettime ();
18669 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
18670 if { (eval echo "$as_me:18670: \"$ac_link\"") >&5
18671 (eval $ac_link) 2>&5
18673 echo "$as_me:18673: \$? = $ac_status" >&5
18674 (exit "$ac_status"); } &&
18675 { ac_try='test -s "conftest$ac_exeext"'
18676 { (eval echo "$as_me:18676: \"$ac_try\"") >&5
18677 (eval $ac_try) 2>&5
18679 echo "$as_me:18679: \$? = $ac_status" >&5
18680 (exit "$ac_status"); }; }; then
18681 ac_cv_func_clock_gettime=yes
18683 echo "$as_me: failed program was:" >&5
18684 cat "conftest.$ac_ext" >&5
18685 ac_cv_func_clock_gettime=no
18687 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
18689 echo "$as_me:18689: result: $ac_cv_func_clock_gettime" >&5
18690 echo "${ECHO_T}$ac_cv_func_clock_gettime" >&6
18691 if test "$ac_cv_func_clock_gettime" = yes; then
18692 cf_cv_test_clock_gettime=yes
18694 echo "$as_me:18694: checking for clock_gettime in -lrt" >&5
18695 echo $ECHO_N "checking for clock_gettime in -lrt... $ECHO_C" >&6
18696 if test "${ac_cv_lib_rt_clock_gettime+set}" = set; then
18697 echo $ECHO_N "(cached) $ECHO_C" >&6
18699 ac_check_lib_save_LIBS=$LIBS
18701 cat >"conftest.$ac_ext" <<_ACEOF
18702 #line 18702 "configure"
18703 #include "confdefs.h"
18705 /* Override any gcc2 internal prototype to avoid an error. */
18709 /* We use char because int might match the return type of a gcc2
18710 builtin and then its argument prototype would still apply. */
18711 char clock_gettime (void);
18720 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
18721 if { (eval echo "$as_me:18721: \"$ac_link\"") >&5
18722 (eval $ac_link) 2>&5
18724 echo "$as_me:18724: \$? = $ac_status" >&5
18725 (exit "$ac_status"); } &&
18726 { ac_try='test -s "conftest$ac_exeext"'
18727 { (eval echo "$as_me:18727: \"$ac_try\"") >&5
18728 (eval $ac_try) 2>&5
18730 echo "$as_me:18730: \$? = $ac_status" >&5
18731 (exit "$ac_status"); }; }; then
18732 ac_cv_lib_rt_clock_gettime=yes
18734 echo "$as_me: failed program was:" >&5
18735 cat "conftest.$ac_ext" >&5
18736 ac_cv_lib_rt_clock_gettime=no
18738 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
18739 LIBS=$ac_check_lib_save_LIBS
18741 echo "$as_me:18741: result: $ac_cv_lib_rt_clock_gettime" >&5
18742 echo "${ECHO_T}$ac_cv_lib_rt_clock_gettime" >&6
18743 if test "$ac_cv_lib_rt_clock_gettime" = yes; then
18745 cf_cv_test_clock_gettime=yes
18747 cf_cv_test_clock_gettime=no
18752 if test "$cf_cv_test_clock_gettime" = yes ; then
18753 echo "$as_me:18753: checking if clock_gettime links" >&5
18754 echo $ECHO_N "checking if clock_gettime links... $ECHO_C" >&6
18755 if test "${cf_cv_func_clock_gettime+set}" = set; then
18756 echo $ECHO_N "(cached) $ECHO_C" >&6
18759 cat >"conftest.$ac_ext" <<_ACEOF
18760 #line 18760 "configure"
18761 #include "confdefs.h"
18763 $ac_includes_default
18769 struct timespec ts;
18770 int rc = clock_gettime(CLOCK_REALTIME, &ts)
18771 + clock_gettime(CLOCK_MONOTONIC, &ts);
18772 (void) rc; (void)ts
18777 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
18778 if { (eval echo "$as_me:18778: \"$ac_link\"") >&5
18779 (eval $ac_link) 2>&5
18781 echo "$as_me:18781: \$? = $ac_status" >&5
18782 (exit "$ac_status"); } &&
18783 { ac_try='test -s "conftest$ac_exeext"'
18784 { (eval echo "$as_me:18784: \"$ac_try\"") >&5
18785 (eval $ac_try) 2>&5
18787 echo "$as_me:18787: \$? = $ac_status" >&5
18788 (exit "$ac_status"); }; }; then
18789 cf_cv_func_clock_gettime=yes
18791 echo "$as_me: failed program was:" >&5
18792 cat "conftest.$ac_ext" >&5
18793 cf_cv_func_clock_gettime=no
18795 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
18798 echo "$as_me:18798: result: $cf_cv_func_clock_gettime" >&5
18799 echo "${ECHO_T}$cf_cv_func_clock_gettime" >&6
18801 cf_cv_func_clock_gettime=no
18804 if test "$cf_cv_func_clock_gettime" = yes
18807 cat >>confdefs.h <<\EOF
18808 #define HAVE_CLOCK_GETTIME 1
18812 echo "$as_me:18812: checking for gettimeofday" >&5
18813 echo $ECHO_N "checking for gettimeofday... $ECHO_C" >&6
18814 if test "${ac_cv_func_gettimeofday+set}" = set; then
18815 echo $ECHO_N "(cached) $ECHO_C" >&6
18817 cat >"conftest.$ac_ext" <<_ACEOF
18818 #line 18818 "configure"
18819 #include "confdefs.h"
18820 #define gettimeofday autoconf_temporary
18821 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
18822 #undef gettimeofday
18828 /* We use char because int might match the return type of a gcc2
18829 builtin and then its argument prototype would still apply. */
18830 char gettimeofday (void);
18836 /* The GNU C library defines stubs for functions which it implements
18837 to always fail with ENOSYS. Some functions are actually named
18838 something starting with __ and the normal name is an alias. */
18839 #if defined (__stub_gettimeofday) || defined (__stub___gettimeofday)
18840 #error found stub for gettimeofday
18843 return gettimeofday ();
18848 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
18849 if { (eval echo "$as_me:18849: \"$ac_link\"") >&5
18850 (eval $ac_link) 2>&5
18852 echo "$as_me:18852: \$? = $ac_status" >&5
18853 (exit "$ac_status"); } &&
18854 { ac_try='test -s "conftest$ac_exeext"'
18855 { (eval echo "$as_me:18855: \"$ac_try\"") >&5
18856 (eval $ac_try) 2>&5
18858 echo "$as_me:18858: \$? = $ac_status" >&5
18859 (exit "$ac_status"); }; }; then
18860 ac_cv_func_gettimeofday=yes
18862 echo "$as_me: failed program was:" >&5
18863 cat "conftest.$ac_ext" >&5
18864 ac_cv_func_gettimeofday=no
18866 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
18868 echo "$as_me:18868: result: $ac_cv_func_gettimeofday" >&5
18869 echo "${ECHO_T}$ac_cv_func_gettimeofday" >&6
18870 if test "$ac_cv_func_gettimeofday" = yes; then
18872 cat >>confdefs.h <<\EOF
18873 #define HAVE_GETTIMEOFDAY 1
18878 echo "$as_me:18878: checking for gettimeofday in -lbsd" >&5
18879 echo $ECHO_N "checking for gettimeofday in -lbsd... $ECHO_C" >&6
18880 if test "${ac_cv_lib_bsd_gettimeofday+set}" = set; then
18881 echo $ECHO_N "(cached) $ECHO_C" >&6
18883 ac_check_lib_save_LIBS=$LIBS
18885 cat >"conftest.$ac_ext" <<_ACEOF
18886 #line 18886 "configure"
18887 #include "confdefs.h"
18889 /* Override any gcc2 internal prototype to avoid an error. */
18893 /* We use char because int might match the return type of a gcc2
18894 builtin and then its argument prototype would still apply. */
18895 char gettimeofday (void);
18904 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
18905 if { (eval echo "$as_me:18905: \"$ac_link\"") >&5
18906 (eval $ac_link) 2>&5
18908 echo "$as_me:18908: \$? = $ac_status" >&5
18909 (exit "$ac_status"); } &&
18910 { ac_try='test -s "conftest$ac_exeext"'
18911 { (eval echo "$as_me:18911: \"$ac_try\"") >&5
18912 (eval $ac_try) 2>&5
18914 echo "$as_me:18914: \$? = $ac_status" >&5
18915 (exit "$ac_status"); }; }; then
18916 ac_cv_lib_bsd_gettimeofday=yes
18918 echo "$as_me: failed program was:" >&5
18919 cat "conftest.$ac_ext" >&5
18920 ac_cv_lib_bsd_gettimeofday=no
18922 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
18923 LIBS=$ac_check_lib_save_LIBS
18925 echo "$as_me:18925: result: $ac_cv_lib_bsd_gettimeofday" >&5
18926 echo "${ECHO_T}$ac_cv_lib_bsd_gettimeofday" >&6
18927 if test "$ac_cv_lib_bsd_gettimeofday" = yes; then
18929 cat >>confdefs.h <<\EOF
18930 #define HAVE_GETTIMEOFDAY 1
18933 cf_add_libs="$LIBS"
18936 for cf_add_1lib in -lbsd; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
18937 # filter duplicates
18938 for cf_add_1lib in $cf_add_0lib; do
18939 for cf_add_2lib in $cf_add_libs; do
18940 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
18945 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
18947 LIBS="$cf_add_libs"
18962 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
18963 echo "$as_me:18963: checking for $ac_func" >&5
18964 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
18965 if eval "test \"\${$as_ac_var+set}\" = set"; then
18966 echo $ECHO_N "(cached) $ECHO_C" >&6
18968 cat >"conftest.$ac_ext" <<_ACEOF
18969 #line 18969 "configure"
18970 #include "confdefs.h"
18971 #define $ac_func autoconf_temporary
18972 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
18979 /* We use char because int might match the return type of a gcc2
18980 builtin and then its argument prototype would still apply. */
18981 char $ac_func (void);
18987 /* The GNU C library defines stubs for functions which it implements
18988 to always fail with ENOSYS. Some functions are actually named
18989 something starting with __ and the normal name is an alias. */
18990 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
18991 #error found stub for $ac_func
18994 return $ac_func ();
18999 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
19000 if { (eval echo "$as_me:19000: \"$ac_link\"") >&5
19001 (eval $ac_link) 2>&5
19003 echo "$as_me:19003: \$? = $ac_status" >&5
19004 (exit "$ac_status"); } &&
19005 { ac_try='test -s "conftest$ac_exeext"'
19006 { (eval echo "$as_me:19006: \"$ac_try\"") >&5
19007 (eval $ac_try) 2>&5
19009 echo "$as_me:19009: \$? = $ac_status" >&5
19010 (exit "$ac_status"); }; }; then
19011 eval "$as_ac_var=yes"
19013 echo "$as_me: failed program was:" >&5
19014 cat "conftest.$ac_ext" >&5
19015 eval "$as_ac_var=no"
19017 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
19019 echo "$as_me:19019: result: `eval echo '${'"$as_ac_var"'}'`" >&5
19020 echo "${ECHO_T}`eval echo '${'"$as_ac_var"'}'`" >&6
19021 if test "`eval echo '${'"$as_ac_var"'}'`" = yes; then
19022 cat >>confdefs.h <<EOF
19023 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
19029 # use a compile-check to work with ncurses*-config and subdirectory includes
19030 echo "$as_me:19030: checking if we can use termcap.h" >&5
19031 echo $ECHO_N "checking if we can use termcap.h... $ECHO_C" >&6
19032 if test "${cf_cv_have_termcap_h+set}" = set; then
19033 echo $ECHO_N "(cached) $ECHO_C" >&6
19036 cat >"conftest.$ac_ext" <<_ACEOF
19037 #line 19037 "configure"
19038 #include "confdefs.h"
19040 #include <curses.h>
19041 #ifdef NCURSES_VERSION
19042 #undef NCURSES_VERSION
19044 #include <termcap.h>
19045 #ifndef NCURSES_VERSION
19046 #error wrong header
19057 rm -f "conftest.$ac_objext"
19058 if { (eval echo "$as_me:19058: \"$ac_compile\"") >&5
19059 (eval $ac_compile) 2>&5
19061 echo "$as_me:19061: \$? = $ac_status" >&5
19062 (exit "$ac_status"); } &&
19063 { ac_try='test -s "conftest.$ac_objext"'
19064 { (eval echo "$as_me:19064: \"$ac_try\"") >&5
19065 (eval $ac_try) 2>&5
19067 echo "$as_me:19067: \$? = $ac_status" >&5
19068 (exit "$ac_status"); }; }; then
19069 cf_cv_have_termcap_h=yes
19071 echo "$as_me: failed program was:" >&5
19072 cat "conftest.$ac_ext" >&5
19073 cf_cv_have_termcap_h=no
19075 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
19077 echo "$as_me:19077: result: $cf_cv_have_termcap_h" >&5
19078 echo "${ECHO_T}$cf_cv_have_termcap_h" >&6
19079 if test "x$cf_cv_have_termcap_h" = xyes
19082 cat >>confdefs.h <<\EOF
19083 #define HAVE_TERMCAP_H 1
19087 echo "$as_me:19087: checking if we can use ncurses/termcap.h" >&5
19088 echo $ECHO_N "checking if we can use ncurses/termcap.h... $ECHO_C" >&6
19089 if test "${cf_cv_have_ncurses_termcap_h+set}" = set; then
19090 echo $ECHO_N "(cached) $ECHO_C" >&6
19093 cat >"conftest.$ac_ext" <<_ACEOF
19094 #line 19094 "configure"
19095 #include "confdefs.h"
19097 #include <ncurses/curses.h>
19098 #ifdef NCURSES_VERSION
19099 #undef NCURSES_VERSION
19101 #include <ncurses/termcap.h>
19102 #ifndef NCURSES_VERSION
19103 #error wrong header
19114 rm -f "conftest.$ac_objext"
19115 if { (eval echo "$as_me:19115: \"$ac_compile\"") >&5
19116 (eval $ac_compile) 2>&5
19118 echo "$as_me:19118: \$? = $ac_status" >&5
19119 (exit "$ac_status"); } &&
19120 { ac_try='test -s "conftest.$ac_objext"'
19121 { (eval echo "$as_me:19121: \"$ac_try\"") >&5
19122 (eval $ac_try) 2>&5
19124 echo "$as_me:19124: \$? = $ac_status" >&5
19125 (exit "$ac_status"); }; }; then
19126 cf_cv_have_ncurses_termcap_h=yes
19128 echo "$as_me: failed program was:" >&5
19129 cat "conftest.$ac_ext" >&5
19130 cf_cv_have_ncurses_termcap_h=no
19132 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
19134 echo "$as_me:19134: result: $cf_cv_have_ncurses_termcap_h" >&5
19135 echo "${ECHO_T}$cf_cv_have_ncurses_termcap_h" >&6
19136 test "x$cf_cv_have_ncurses_termcap_h" = xyes &&
19137 cat >>confdefs.h <<\EOF
19138 #define HAVE_NCURSES_TERMCAP_H 1
19143 if test "x$ac_cv_func_getopt" = xno; then
19144 { { echo "$as_me:19144: error: getopt is required for building programs" >&5
19145 echo "$as_me: error: getopt is required for building programs" >&2;}
19146 { (exit 1); exit 1; }; }
19149 if test "$cf_enable_widec" = yes; then
19162 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
19163 echo "$as_me:19163: checking for $ac_func" >&5
19164 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
19165 if eval "test \"\${$as_ac_var+set}\" = set"; then
19166 echo $ECHO_N "(cached) $ECHO_C" >&6
19168 cat >"conftest.$ac_ext" <<_ACEOF
19169 #line 19169 "configure"
19170 #include "confdefs.h"
19171 #define $ac_func autoconf_temporary
19172 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
19179 /* We use char because int might match the return type of a gcc2
19180 builtin and then its argument prototype would still apply. */
19181 char $ac_func (void);
19187 /* The GNU C library defines stubs for functions which it implements
19188 to always fail with ENOSYS. Some functions are actually named
19189 something starting with __ and the normal name is an alias. */
19190 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
19191 #error found stub for $ac_func
19194 return $ac_func ();
19199 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
19200 if { (eval echo "$as_me:19200: \"$ac_link\"") >&5
19201 (eval $ac_link) 2>&5
19203 echo "$as_me:19203: \$? = $ac_status" >&5
19204 (exit "$ac_status"); } &&
19205 { ac_try='test -s "conftest$ac_exeext"'
19206 { (eval echo "$as_me:19206: \"$ac_try\"") >&5
19207 (eval $ac_try) 2>&5
19209 echo "$as_me:19209: \$? = $ac_status" >&5
19210 (exit "$ac_status"); }; }; then
19211 eval "$as_ac_var=yes"
19213 echo "$as_me: failed program was:" >&5
19214 cat "conftest.$ac_ext" >&5
19215 eval "$as_ac_var=no"
19217 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
19219 echo "$as_me:19219: result: `eval echo '${'"$as_ac_var"'}'`" >&5
19220 echo "${ECHO_T}`eval echo '${'"$as_ac_var"'}'`" >&6
19221 if test "`eval echo '${'"$as_ac_var"'}'`" = yes; then
19222 cat >>confdefs.h <<EOF
19223 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
19231 echo "$as_me:19231: checking definition to turn on extended curses functions" >&5
19232 echo $ECHO_N "checking definition to turn on extended curses functions... $ECHO_C" >&6
19233 if test "${cf_cv_need_xopen_extension+set}" = set; then
19234 echo $ECHO_N "(cached) $ECHO_C" >&6
19237 cf_cv_need_xopen_extension=unknown
19238 cat >"conftest.$ac_ext" <<_ACEOF
19239 #line 19239 "configure"
19240 #include "confdefs.h"
19242 $ac_includes_default
19243 #include <${cf_cv_ncurses_header:-curses.h}>
19248 #if defined(NCURSES_VERSION_PATCH)
19249 #if (NCURSES_VERSION_PATCH < 20100501) && (NCURSES_VERSION_PATCH >= 20100403)
19250 #error disallow ncurses versions between 2020/04/03 and 2010/05/01
19253 #ifdef NCURSES_WIDECHAR
19254 #error prefer to fall-through on the second checks
19256 static char dummy[10];
19258 int check2 = curs_set((int)sizeof(check));
19259 long x = winnstr(stdscr, dummy, 5);
19262 getbegyx(stdscr, y1, x1);
19271 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
19272 if { (eval echo "$as_me:19272: \"$ac_link\"") >&5
19273 (eval $ac_link) 2>&5
19275 echo "$as_me:19275: \$? = $ac_status" >&5
19276 (exit "$ac_status"); } &&
19277 { ac_try='test -s "conftest$ac_exeext"'
19278 { (eval echo "$as_me:19278: \"$ac_try\"") >&5
19279 (eval $ac_try) 2>&5
19281 echo "$as_me:19281: \$? = $ac_status" >&5
19282 (exit "$ac_status"); }; }; then
19283 cf_cv_need_xopen_extension=none
19285 echo "$as_me: failed program was:" >&5
19286 cat "conftest.$ac_ext" >&5
19288 for cf_try_xopen_extension in _XOPEN_SOURCE_EXTENDED NCURSES_WIDECHAR
19290 cat >"conftest.$ac_ext" <<_ACEOF
19291 #line 19291 "configure"
19292 #include "confdefs.h"
19294 #define $cf_try_xopen_extension 1
19295 $ac_includes_default
19296 #include <${cf_cv_ncurses_header:-curses.h}>
19301 static char dummy[10];
19303 int check2 = curs_set((int)sizeof(check));
19304 long x = winnstr(stdscr, dummy, 5);
19306 getbegyx(stdscr, y1, x1);
19316 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
19317 if { (eval echo "$as_me:19317: \"$ac_link\"") >&5
19318 (eval $ac_link) 2>&5
19320 echo "$as_me:19320: \$? = $ac_status" >&5
19321 (exit "$ac_status"); } &&
19322 { ac_try='test -s "conftest$ac_exeext"'
19323 { (eval echo "$as_me:19323: \"$ac_try\"") >&5
19324 (eval $ac_try) 2>&5
19326 echo "$as_me:19326: \$? = $ac_status" >&5
19327 (exit "$ac_status"); }; }; then
19328 cf_cv_need_xopen_extension=$cf_try_xopen_extension; break
19330 echo "$as_me: failed program was:" >&5
19331 cat "conftest.$ac_ext" >&5
19333 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
19337 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
19340 echo "$as_me:19340: result: $cf_cv_need_xopen_extension" >&5
19341 echo "${ECHO_T}$cf_cv_need_xopen_extension" >&6
19343 case "$cf_cv_need_xopen_extension" in
19346 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
19347 CPPFLAGS="${CPPFLAGS}-D$cf_cv_need_xopen_extension"
19352 echo "$as_me:19352: checking for term.h" >&5
19353 echo $ECHO_N "checking for term.h... $ECHO_C" >&6
19354 if test "${cf_cv_term_header+set}" = set; then
19355 echo $ECHO_N "(cached) $ECHO_C" >&6
19358 # If we found <ncurses/curses.h>, look for <ncurses/term.h>, but always look
19359 # for <term.h> if we do not find the variant.
19361 cf_header_list="term.h ncurses/term.h ncursesw/term.h"
19363 case "${cf_cv_ncurses_header:-curses.h}" in
19365 cf_header_item=`echo "${cf_cv_ncurses_header:-curses.h}" | sed -e 's%\..*%%' -e 's%/.*%/%'`term.h
19366 cf_header_list="$cf_header_item $cf_header_list"
19370 for cf_header in $cf_header_list
19372 cat >"conftest.$ac_ext" <<_ACEOF
19373 #line 19373 "configure"
19374 #include "confdefs.h"
19376 #include <${cf_cv_ncurses_header:-curses.h}>
19377 #include <${cf_header}>
19386 rm -f "conftest.$ac_objext"
19387 if { (eval echo "$as_me:19387: \"$ac_compile\"") >&5
19388 (eval $ac_compile) 2>&5
19390 echo "$as_me:19390: \$? = $ac_status" >&5
19391 (exit "$ac_status"); } &&
19392 { ac_try='test -s "conftest.$ac_objext"'
19393 { (eval echo "$as_me:19393: \"$ac_try\"") >&5
19394 (eval $ac_try) 2>&5
19396 echo "$as_me:19396: \$? = $ac_status" >&5
19397 (exit "$ac_status"); }; }; then
19398 cf_cv_term_header=$cf_header
19401 echo "$as_me: failed program was:" >&5
19402 cat "conftest.$ac_ext" >&5
19403 cf_cv_term_header=no
19405 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
19408 case "$cf_cv_term_header" in
19410 # If curses is ncurses, some packagers still mess it up by trying to make
19411 # us use GNU termcap. This handles the most common case.
19412 for cf_header in ncurses/term.h ncursesw/term.h
19414 cat >"conftest.$ac_ext" <<_ACEOF
19415 #line 19415 "configure"
19416 #include "confdefs.h"
19418 #include <${cf_cv_ncurses_header:-curses.h}>
19419 #ifdef NCURSES_VERSION
19420 #include <${cf_header}>
19422 #error expected NCURSES_VERSION to be defined
19432 rm -f "conftest.$ac_objext"
19433 if { (eval echo "$as_me:19433: \"$ac_compile\"") >&5
19434 (eval $ac_compile) 2>&5
19436 echo "$as_me:19436: \$? = $ac_status" >&5
19437 (exit "$ac_status"); } &&
19438 { ac_try='test -s "conftest.$ac_objext"'
19439 { (eval echo "$as_me:19439: \"$ac_try\"") >&5
19440 (eval $ac_try) 2>&5
19442 echo "$as_me:19442: \$? = $ac_status" >&5
19443 (exit "$ac_status"); }; }; then
19444 cf_cv_term_header=$cf_header
19447 echo "$as_me: failed program was:" >&5
19448 cat "conftest.$ac_ext" >&5
19449 cf_cv_term_header=no
19451 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
19457 echo "$as_me:19457: result: $cf_cv_term_header" >&5
19458 echo "${ECHO_T}$cf_cv_term_header" >&6
19460 case "$cf_cv_term_header" in
19463 cat >>confdefs.h <<\EOF
19464 #define HAVE_TERM_H 1
19470 cat >>confdefs.h <<\EOF
19471 #define HAVE_NCURSES_TERM_H 1
19477 cat >>confdefs.h <<\EOF
19478 #define HAVE_NCURSESW_TERM_H 1
19484 echo "$as_me:19484: checking for unctrl.h" >&5
19485 echo $ECHO_N "checking for unctrl.h... $ECHO_C" >&6
19486 if test "${cf_cv_unctrl_header+set}" = set; then
19487 echo $ECHO_N "(cached) $ECHO_C" >&6
19490 # If we found <ncurses/curses.h>, look for <ncurses/unctrl.h>, but always look
19491 # for <unctrl.h> if we do not find the variant.
19493 cf_header_list="unctrl.h ncurses/unctrl.h ncursesw/unctrl.h"
19495 case "${cf_cv_ncurses_header:-curses.h}" in
19497 cf_header_item=`echo "${cf_cv_ncurses_header:-curses.h}" | sed -e 's%\..*%%' -e 's%/.*%/%'`unctrl.h
19498 cf_header_list="$cf_header_item $cf_header_list"
19502 for cf_header in $cf_header_list
19504 cat >"conftest.$ac_ext" <<_ACEOF
19505 #line 19505 "configure"
19506 #include "confdefs.h"
19508 #include <${cf_cv_ncurses_header:-curses.h}>
19509 #include <${cf_header}>
19518 rm -f "conftest.$ac_objext"
19519 if { (eval echo "$as_me:19519: \"$ac_compile\"") >&5
19520 (eval $ac_compile) 2>&5
19522 echo "$as_me:19522: \$? = $ac_status" >&5
19523 (exit "$ac_status"); } &&
19524 { ac_try='test -s "conftest.$ac_objext"'
19525 { (eval echo "$as_me:19525: \"$ac_try\"") >&5
19526 (eval $ac_try) 2>&5
19528 echo "$as_me:19528: \$? = $ac_status" >&5
19529 (exit "$ac_status"); }; }; then
19530 cf_cv_unctrl_header=$cf_header
19533 echo "$as_me: failed program was:" >&5
19534 cat "conftest.$ac_ext" >&5
19535 cf_cv_unctrl_header=no
19537 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
19541 echo "$as_me:19541: result: $cf_cv_unctrl_header" >&5
19542 echo "${ECHO_T}$cf_cv_unctrl_header" >&6
19544 case "$cf_cv_unctrl_header" in
19546 { echo "$as_me:19546: WARNING: unctrl.h header not found" >&5
19547 echo "$as_me: WARNING: unctrl.h header not found" >&2;}
19551 case "$cf_cv_unctrl_header" in
19554 cat >>confdefs.h <<\EOF
19555 #define HAVE_UNCTRL_H 1
19561 cat >>confdefs.h <<\EOF
19562 #define HAVE_NCURSES_UNCTRL_H 1
19566 (ncursesw/unctrl.h)
19568 cat >>confdefs.h <<\EOF
19569 #define HAVE_NCURSESW_UNCTRL_H 1
19576 _nc_tparm_analyze \
19579 assume_default_colors \
19597 init_extended_color \
19605 reset_color_pairs \
19625 use_default_colors \
19627 use_extended_names \
19642 cf_tr_func=`echo "$cf_func" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
19644 echo "$as_me:19644: checking for ${cf_func}" >&5
19645 echo $ECHO_N "checking for ${cf_func}... $ECHO_C" >&6
19647 echo "${as_me:-configure}:19647: testing ${cf_func} ..." 1>&5
19649 if eval "test \"\${cf_cv_func_$cf_func+set}\" = set"; then
19650 echo $ECHO_N "(cached) $ECHO_C" >&6
19653 eval cf_result='$ac_cv_func_'$cf_func
19654 if test ".$cf_result" != ".no"; then
19655 cat >"conftest.$ac_ext" <<_ACEOF
19656 #line 19656 "configure"
19657 #include "confdefs.h"
19659 #ifdef HAVE_XCURSES
19660 #include <xcurses.h>
19661 char * XCursesProgramName = "test";
19663 #include <${cf_cv_ncurses_header:-curses.h}>
19664 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
19665 #include <ncursesw/term.h>
19666 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
19667 #include <ncurses/term.h>
19668 #elif defined(HAVE_TERM_H)
19678 long foo = (long)(&${cf_func});
19679 fprintf(stderr, "testing linkage of $cf_func:%p\\n", (void *)foo);
19680 if (foo + 1234L > 5678L)
19681 ${cf_cv_main_return:-return}(foo != 0);
19688 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
19689 if { (eval echo "$as_me:19689: \"$ac_link\"") >&5
19690 (eval $ac_link) 2>&5
19692 echo "$as_me:19692: \$? = $ac_status" >&5
19693 (exit "$ac_status"); } &&
19694 { ac_try='test -s "conftest$ac_exeext"'
19695 { (eval echo "$as_me:19695: \"$ac_try\"") >&5
19696 (eval $ac_try) 2>&5
19698 echo "$as_me:19698: \$? = $ac_status" >&5
19699 (exit "$ac_status"); }; }; then
19702 echo "$as_me: failed program was:" >&5
19703 cat "conftest.$ac_ext" >&5
19706 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
19708 eval 'cf_cv_func_'$cf_func'="$cf_result"'
19712 # use the computed/retrieved cache-value:
19713 eval 'cf_result=$cf_cv_func_'$cf_func
19714 echo "$as_me:19714: result: $cf_result" >&5
19715 echo "${ECHO_T}$cf_result" >&6
19716 if test "$cf_result" != no; then
19717 cat >>confdefs.h <<EOF
19718 #define HAVE_${cf_tr_func} 1
19724 for cf_func in tputs
19727 cf_tr_func=`echo "$cf_func" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
19729 echo "$as_me:19729: checking for ${cf_func}" >&5
19730 echo $ECHO_N "checking for ${cf_func}... $ECHO_C" >&6
19732 echo "${as_me:-configure}:19732: testing ${cf_func} ..." 1>&5
19734 if eval "test \"\${cf_cv_func_$cf_func+set}\" = set"; then
19735 echo $ECHO_N "(cached) $ECHO_C" >&6
19738 eval cf_result='$ac_cv_func_'$cf_func
19739 if test ".$cf_result" != ".no"; then
19740 cat >"conftest.$ac_ext" <<_ACEOF
19741 #line 19741 "configure"
19742 #include "confdefs.h"
19744 #ifdef HAVE_XCURSES
19745 #include <xcurses.h>
19746 char * XCursesProgramName = "test";
19748 #include <${cf_cv_ncurses_header:-curses.h}>
19749 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
19750 #include <ncursesw/term.h>
19751 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
19752 #include <ncurses/term.h>
19753 #elif defined(HAVE_TERM_H)
19763 long foo = (long)(&${cf_func});
19764 fprintf(stderr, "testing linkage of $cf_func:%p\\n", (void *)foo);
19765 if (foo + 1234L > 5678L)
19766 ${cf_cv_main_return:-return}(foo != 0);
19773 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
19774 if { (eval echo "$as_me:19774: \"$ac_link\"") >&5
19775 (eval $ac_link) 2>&5
19777 echo "$as_me:19777: \$? = $ac_status" >&5
19778 (exit "$ac_status"); } &&
19779 { ac_try='test -s "conftest$ac_exeext"'
19780 { (eval echo "$as_me:19780: \"$ac_try\"") >&5
19781 (eval $ac_try) 2>&5
19783 echo "$as_me:19783: \$? = $ac_status" >&5
19784 (exit "$ac_status"); }; }; then
19787 echo "$as_me: failed program was:" >&5
19788 cat "conftest.$ac_ext" >&5
19791 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
19793 eval 'cf_cv_func_'$cf_func'="$cf_result"'
19797 # use the computed/retrieved cache-value:
19798 eval 'cf_result=$cf_cv_func_'$cf_func
19799 echo "$as_me:19799: result: $cf_result" >&5
19800 echo "${ECHO_T}$cf_result" >&6
19801 if test "$cf_result" != no; then
19802 cat >>confdefs.h <<EOF
19803 #define HAVE_${cf_tr_func} 1
19809 if test "x$cf_cv_func_tputs" = xyes
19812 for cf_arg in int char
19814 for cf_ret in int void
19816 if test "$cf_ret" = void
19818 cf_return="/* nothing */"
19820 cf_return="return value"
19822 cat >"conftest.$ac_ext" <<_ACEOF
19823 #line 19823 "configure"
19824 #include "confdefs.h"
19826 #include <${cf_cv_ncurses_header:-curses.h}>
19827 #include <$cf_cv_term_header>
19829 static $cf_ret outc($cf_arg value) { $cf_return; }
19835 tputs("hello", 0, outc);
19836 ${cf_cv_main_return:-return}(0);
19842 rm -f "conftest.$ac_objext"
19843 if { (eval echo "$as_me:19843: \"$ac_compile\"") >&5
19844 (eval $ac_compile) 2>&5
19846 echo "$as_me:19846: \$? = $ac_status" >&5
19847 (exit "$ac_status"); } &&
19848 { ac_try='test -s "conftest.$ac_objext"'
19849 { (eval echo "$as_me:19849: \"$ac_try\"") >&5
19850 (eval $ac_try) 2>&5
19852 echo "$as_me:19852: \$? = $ac_status" >&5
19853 (exit "$ac_status"); }; }; then
19855 test -n "$verbose" && echo " prototype $cf_ret func($cf_arg value)" 1>&6
19857 echo "${as_me:-configure}:19857: testing prototype $cf_ret func($cf_arg value) ..." 1>&5
19859 cat >>confdefs.h <<EOF
19860 #define TPUTS_ARG $cf_arg
19861 #define TPUTS_PROTO(func,value) $cf_ret func(TPUTS_ARG value)
19862 #define TPUTS_RETURN(value) $cf_return
19868 echo "$as_me: failed program was:" >&5
19869 cat "conftest.$ac_ext" >&5
19871 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
19873 test "$cf_done" = yes && break
19877 echo "$as_me:19877: checking for ncurses extended functions" >&5
19878 echo $ECHO_N "checking for ncurses extended functions... $ECHO_C" >&6
19879 if test "${cf_cv_ncurses_ext_funcs+set}" = set; then
19880 echo $ECHO_N "(cached) $ECHO_C" >&6
19883 cat >"conftest.$ac_ext" <<_ACEOF
19884 #line 19884 "configure"
19885 #include "confdefs.h"
19887 #include <${cf_cv_ncurses_header:-curses.h}>
19892 int x = NCURSES_EXT_FUNCS
19898 rm -f "conftest.$ac_objext"
19899 if { (eval echo "$as_me:19899: \"$ac_compile\"") >&5
19900 (eval $ac_compile) 2>&5
19902 echo "$as_me:19902: \$? = $ac_status" >&5
19903 (exit "$ac_status"); } &&
19904 { ac_try='test -s "conftest.$ac_objext"'
19905 { (eval echo "$as_me:19905: \"$ac_try\"") >&5
19906 (eval $ac_try) 2>&5
19908 echo "$as_me:19908: \$? = $ac_status" >&5
19909 (exit "$ac_status"); }; }; then
19910 cf_cv_ncurses_ext_funcs=defined
19912 echo "$as_me: failed program was:" >&5
19913 cat "conftest.$ac_ext" >&5
19915 cat >"conftest.$ac_ext" <<_ACEOF
19916 #line 19916 "configure"
19917 #include "confdefs.h"
19919 #include <${cf_cv_ncurses_header:-curses.h}>
19924 (void) assume_default_colors (0, 0);
19925 (void) curses_version ();
19926 (void) define_key (0, 0);
19927 (void) is_term_resized (0, 0);
19928 (void) key_defined (0);
19929 (void) keybound (0, 0);
19930 (void) keyok (0, 0);
19931 (void) resize_term (0, 0);
19932 (void) resizeterm (0, 0);
19933 (void) use_default_colors ();
19934 (void) use_extended_names (0);
19935 (void) wresize (0, 0, 0);
19940 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
19941 if { (eval echo "$as_me:19941: \"$ac_link\"") >&5
19942 (eval $ac_link) 2>&5
19944 echo "$as_me:19944: \$? = $ac_status" >&5
19945 (exit "$ac_status"); } &&
19946 { ac_try='test -s "conftest$ac_exeext"'
19947 { (eval echo "$as_me:19947: \"$ac_try\"") >&5
19948 (eval $ac_try) 2>&5
19950 echo "$as_me:19950: \$? = $ac_status" >&5
19951 (exit "$ac_status"); }; }; then
19952 cf_cv_ncurses_ext_funcs=yes
19954 echo "$as_me: failed program was:" >&5
19955 cat "conftest.$ac_ext" >&5
19956 cf_cv_ncurses_ext_funcs=no
19958 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
19961 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
19964 echo "$as_me:19964: result: $cf_cv_ncurses_ext_funcs" >&5
19965 echo "${ECHO_T}$cf_cv_ncurses_ext_funcs" >&6
19966 test "$cf_cv_ncurses_ext_funcs" = yes &&
19967 cat >>confdefs.h <<\EOF
19968 #define NCURSES_EXT_FUNCS 1
19971 if test "$cf_enable_widec" = yes
19973 # workaround for systems with ncurses before 20111029, due to change of
19974 # feature test macro from _XPG5 to _XOPEN_SOURCE
19975 if test -n "$cf_cv_ncurses_version" && test "x$cf_cv_ncurses_version" != xno
19978 echo "$as_me:19978: checking if _XPG5 should be defined to enable wide-characters" >&5
19979 echo $ECHO_N "checking if _XPG5 should be defined to enable wide-characters... $ECHO_C" >&6
19981 cat >"conftest.$ac_ext" <<_ACEOF
19982 #line 19982 "configure"
19983 #include "confdefs.h"
19985 #include <${cf_cv_ncurses_header:-curses.h}>
19994 rm -f "conftest.$ac_objext"
19995 if { (eval echo "$as_me:19995: \"$ac_compile\"") >&5
19996 (eval $ac_compile) 2>&5
19998 echo "$as_me:19998: \$? = $ac_status" >&5
19999 (exit "$ac_status"); } &&
20000 { ac_try='test -s "conftest.$ac_objext"'
20001 { (eval echo "$as_me:20001: \"$ac_try\"") >&5
20002 (eval $ac_try) 2>&5
20004 echo "$as_me:20004: \$? = $ac_status" >&5
20005 (exit "$ac_status"); }; }; then
20008 echo "$as_me: failed program was:" >&5
20009 cat "conftest.$ac_ext" >&5
20010 cf_save_cppflags="$CPPFLAGS"
20011 CPPFLAGS="$CPPFLAGS -D_XPG5"
20012 cat >"conftest.$ac_ext" <<_ACEOF
20013 #line 20013 "configure"
20014 #include "confdefs.h"
20016 #include <${cf_cv_ncurses_header:-curses.h}>
20025 rm -f "conftest.$ac_objext"
20026 if { (eval echo "$as_me:20026: \"$ac_compile\"") >&5
20027 (eval $ac_compile) 2>&5
20029 echo "$as_me:20029: \$? = $ac_status" >&5
20030 (exit "$ac_status"); } &&
20031 { ac_try='test -s "conftest.$ac_objext"'
20032 { (eval echo "$as_me:20032: \"$ac_try\"") >&5
20033 (eval $ac_try) 2>&5
20035 echo "$as_me:20035: \$? = $ac_status" >&5
20036 (exit "$ac_status"); }; }; then
20039 echo "$as_me: failed program was:" >&5
20040 cat "conftest.$ac_ext" >&5
20042 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
20043 CPPFLAGS="$cf_save_cppflags"
20045 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
20046 echo "$as_me:20046: result: $cf_define_xpg5" >&5
20047 echo "${ECHO_T}$cf_define_xpg5" >&6
20049 if test "$cf_define_xpg5" = yes
20051 CPPFLAGS="$CPPFLAGS -D_XPG5"
20055 echo "$as_me:20055: checking for wide-character functions" >&5
20056 echo $ECHO_N "checking for wide-character functions... $ECHO_C" >&6
20057 if test "${cf_cv_widechar_funcs+set}" = set; then
20058 echo $ECHO_N "(cached) $ECHO_C" >&6
20061 cat >"conftest.$ac_ext" <<_ACEOF
20062 #line 20062 "configure"
20063 #include "confdefs.h"
20065 #include <${cf_cv_ncurses_header:-curses.h}>
20070 static wchar_t src_wchar[2];
20071 static cchar_t dst_cchar;
20072 setcchar(&dst_cchar, src_wchar, A_NORMAL, 0, (void *) 0);
20078 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
20079 if { (eval echo "$as_me:20079: \"$ac_link\"") >&5
20080 (eval $ac_link) 2>&5
20082 echo "$as_me:20082: \$? = $ac_status" >&5
20083 (exit "$ac_status"); } &&
20084 { ac_try='test -s "conftest$ac_exeext"'
20085 { (eval echo "$as_me:20085: \"$ac_try\"") >&5
20086 (eval $ac_try) 2>&5
20088 echo "$as_me:20088: \$? = $ac_status" >&5
20089 (exit "$ac_status"); }; }; then
20090 cf_cv_widechar_funcs=yes
20092 echo "$as_me: failed program was:" >&5
20093 cat "conftest.$ac_ext" >&5
20094 cf_cv_widechar_funcs=no
20096 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
20099 echo "$as_me:20099: result: $cf_cv_widechar_funcs" >&5
20100 echo "${ECHO_T}$cf_cv_widechar_funcs" >&6
20101 if test "$cf_cv_widechar_funcs" != no ; then
20103 cat >>confdefs.h <<\EOF
20104 #define USE_WIDEC_SUPPORT 1
20108 cat >>confdefs.h <<\EOF
20109 #define USE_WIDEC_SUPPORT 0
20114 cat >>confdefs.h <<\EOF
20115 #define USE_WIDEC_SUPPORT 0
20120 echo "$as_me:20120: checking if $cf_cv_screen library uses pthreads" >&5
20121 echo $ECHO_N "checking if $cf_cv_screen library uses pthreads... $ECHO_C" >&6
20122 if test "${cf_cv_use_pthreads+set}" = set; then
20123 echo $ECHO_N "(cached) $ECHO_C" >&6
20126 cat >"conftest.$ac_ext" <<_ACEOF
20127 #line 20127 "configure"
20128 #include "confdefs.h"
20130 #include <${cf_cv_ncurses_header:-curses.h}>
20131 extern void _nc_init_pthreads(void);
20138 _nc_init_pthreads();
20144 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
20145 if { (eval echo "$as_me:20145: \"$ac_link\"") >&5
20146 (eval $ac_link) 2>&5
20148 echo "$as_me:20148: \$? = $ac_status" >&5
20149 (exit "$ac_status"); } &&
20150 { ac_try='test -s "conftest$ac_exeext"'
20151 { (eval echo "$as_me:20151: \"$ac_try\"") >&5
20152 (eval $ac_try) 2>&5
20154 echo "$as_me:20154: \$? = $ac_status" >&5
20155 (exit "$ac_status"); }; }; then
20156 cf_cv_use_pthreads=yes
20158 echo "$as_me: failed program was:" >&5
20159 cat "conftest.$ac_ext" >&5
20160 cf_cv_use_pthreads=no
20162 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
20165 echo "$as_me:20165: result: $cf_cv_use_pthreads" >&5
20166 echo "${ECHO_T}$cf_cv_use_pthreads" >&6
20167 test $cf_cv_use_pthreads = yes &&
20168 cat >>confdefs.h <<\EOF
20169 #define USE_PTHREADS 1
20172 echo "$as_me:20172: checking if sys/time.h works with sys/select.h" >&5
20173 echo $ECHO_N "checking if sys/time.h works with sys/select.h... $ECHO_C" >&6
20174 if test "${cf_cv_sys_time_select+set}" = set; then
20175 echo $ECHO_N "(cached) $ECHO_C" >&6
20178 cat >"conftest.$ac_ext" <<_ACEOF
20179 #line 20179 "configure"
20180 #include "confdefs.h"
20182 #include <sys/types.h>
20183 #ifdef HAVE_SYS_TIME_H
20184 #include <sys/time.h>
20186 #ifdef HAVE_SYS_SELECT_H
20187 #include <sys/select.h>
20198 rm -f "conftest.$ac_objext"
20199 if { (eval echo "$as_me:20199: \"$ac_compile\"") >&5
20200 (eval $ac_compile) 2>&5
20202 echo "$as_me:20202: \$? = $ac_status" >&5
20203 (exit "$ac_status"); } &&
20204 { ac_try='test -s "conftest.$ac_objext"'
20205 { (eval echo "$as_me:20205: \"$ac_try\"") >&5
20206 (eval $ac_try) 2>&5
20208 echo "$as_me:20208: \$? = $ac_status" >&5
20209 (exit "$ac_status"); }; }; then
20210 cf_cv_sys_time_select=yes
20212 echo "$as_me: failed program was:" >&5
20213 cat "conftest.$ac_ext" >&5
20214 cf_cv_sys_time_select=no
20216 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
20220 echo "$as_me:20220: result: $cf_cv_sys_time_select" >&5
20221 echo "${ECHO_T}$cf_cv_sys_time_select" >&6
20222 test "$cf_cv_sys_time_select" = yes &&
20223 cat >>confdefs.h <<\EOF
20224 #define HAVE_SYS_TIME_SELECT 1
20227 # special check for test/ditto.c
20229 echo "$as_me:20229: checking for openpty in -lutil" >&5
20230 echo $ECHO_N "checking for openpty in -lutil... $ECHO_C" >&6
20231 if test "${ac_cv_lib_util_openpty+set}" = set; then
20232 echo $ECHO_N "(cached) $ECHO_C" >&6
20234 ac_check_lib_save_LIBS=$LIBS
20235 LIBS="-lutil $LIBS"
20236 cat >"conftest.$ac_ext" <<_ACEOF
20237 #line 20237 "configure"
20238 #include "confdefs.h"
20240 /* Override any gcc2 internal prototype to avoid an error. */
20244 /* We use char because int might match the return type of a gcc2
20245 builtin and then its argument prototype would still apply. */
20246 char openpty (void);
20255 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
20256 if { (eval echo "$as_me:20256: \"$ac_link\"") >&5
20257 (eval $ac_link) 2>&5
20259 echo "$as_me:20259: \$? = $ac_status" >&5
20260 (exit "$ac_status"); } &&
20261 { ac_try='test -s "conftest$ac_exeext"'
20262 { (eval echo "$as_me:20262: \"$ac_try\"") >&5
20263 (eval $ac_try) 2>&5
20265 echo "$as_me:20265: \$? = $ac_status" >&5
20266 (exit "$ac_status"); }; }; then
20267 ac_cv_lib_util_openpty=yes
20269 echo "$as_me: failed program was:" >&5
20270 cat "conftest.$ac_ext" >&5
20271 ac_cv_lib_util_openpty=no
20273 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
20274 LIBS=$ac_check_lib_save_LIBS
20276 echo "$as_me:20276: result: $ac_cv_lib_util_openpty" >&5
20277 echo "${ECHO_T}$ac_cv_lib_util_openpty" >&6
20278 if test "$ac_cv_lib_util_openpty" = yes; then
20284 echo "$as_me:20284: checking for openpty header" >&5
20285 echo $ECHO_N "checking for openpty header... $ECHO_C" >&6
20286 if test "${cf_cv_func_openpty+set}" = set; then
20287 echo $ECHO_N "(cached) $ECHO_C" >&6
20290 cf_save_LIBS="$LIBS"
20291 test "$cf_cv_lib_util" = yes && {
20292 cf_add_libs="$LIBS"
20295 for cf_add_1lib in -lutil; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
20296 # filter duplicates
20297 for cf_add_1lib in $cf_add_0lib; do
20298 for cf_add_2lib in $cf_add_libs; do
20299 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
20304 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
20306 LIBS="$cf_add_libs"
20308 for cf_header in pty.h libutil.h util.h
20310 cat >"conftest.$ac_ext" <<_ACEOF
20311 #line 20311 "configure"
20312 #include "confdefs.h"
20314 #include <$cf_header>
20320 int x = openpty((int *)0, (int *)0, (char *)0,
20321 (struct termios *)0, (struct winsize *)0);
20328 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
20329 if { (eval echo "$as_me:20329: \"$ac_link\"") >&5
20330 (eval $ac_link) 2>&5
20332 echo "$as_me:20332: \$? = $ac_status" >&5
20333 (exit "$ac_status"); } &&
20334 { ac_try='test -s "conftest$ac_exeext"'
20335 { (eval echo "$as_me:20335: \"$ac_try\"") >&5
20336 (eval $ac_try) 2>&5
20338 echo "$as_me:20338: \$? = $ac_status" >&5
20339 (exit "$ac_status"); }; }; then
20341 cf_cv_func_openpty=$cf_header
20345 echo "$as_me: failed program was:" >&5
20346 cat "conftest.$ac_ext" >&5
20348 cf_cv_func_openpty=no
20351 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
20353 LIBS="$cf_save_LIBS"
20356 echo "$as_me:20356: result: $cf_cv_func_openpty" >&5
20357 echo "${ECHO_T}$cf_cv_func_openpty" >&6
20359 if test "$cf_cv_func_openpty" != no ; then
20361 cat >>confdefs.h <<EOF
20362 #define USE_OPENPTY_HEADER <$cf_cv_func_openpty>
20365 cat >>confdefs.h <<\EOF
20366 #define USE_XTERM_PTY 1
20369 if test "x$cf_cv_lib_util" = xyes ; then
20371 cf_add_libs="$TEST_LIBS"
20374 for cf_add_1lib in -lutil; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
20375 # filter duplicates
20376 for cf_add_1lib in $cf_add_0lib; do
20377 for cf_add_2lib in $cf_add_libs; do
20378 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
20383 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
20385 TEST_LIBS="$cf_add_libs"
20390 echo "$as_me:20390: checking for function curses_version" >&5
20391 echo $ECHO_N "checking for function curses_version... $ECHO_C" >&6
20392 if test "${cf_cv_func_curses_version+set}" = set; then
20393 echo $ECHO_N "(cached) $ECHO_C" >&6
20396 if test "$cross_compiling" = yes; then
20397 cf_cv_func_curses_version=unknown
20399 cat >"conftest.$ac_ext" <<_ACEOF
20400 #line 20400 "configure"
20401 #include "confdefs.h"
20403 $ac_includes_default
20405 #include <${cf_cv_ncurses_header:-curses.h}>
20410 sprintf(temp, "%.999s\\n", curses_version());
20411 ${cf_cv_main_return:-return}(0);
20415 rm -f "conftest$ac_exeext"
20416 if { (eval echo "$as_me:20416: \"$ac_link\"") >&5
20417 (eval $ac_link) 2>&5
20419 echo "$as_me:20419: \$? = $ac_status" >&5
20420 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
20421 { (eval echo "$as_me:20421: \"$ac_try\"") >&5
20422 (eval $ac_try) 2>&5
20424 echo "$as_me:20424: \$? = $ac_status" >&5
20425 (exit "$ac_status"); }; }; then
20426 cf_cv_func_curses_version=yes
20429 echo "$as_me: program exited with status $ac_status" >&5
20430 echo "$as_me: failed program was:" >&5
20431 cat "conftest.$ac_ext" >&5
20432 cf_cv_func_curses_version=no
20435 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
20439 echo "$as_me:20439: result: $cf_cv_func_curses_version" >&5
20440 echo "${ECHO_T}$cf_cv_func_curses_version" >&6
20441 test "$cf_cv_func_curses_version" = yes &&
20442 cat >>confdefs.h <<\EOF
20443 #define HAVE_CURSES_VERSION 1
20446 echo "$as_me:20446: checking for alternate character set array" >&5
20447 echo $ECHO_N "checking for alternate character set array... $ECHO_C" >&6
20448 if test "${cf_cv_curses_acs_map+set}" = set; then
20449 echo $ECHO_N "(cached) $ECHO_C" >&6
20452 cf_cv_curses_acs_map=unknown
20453 for name in acs_map _acs_map __acs_map ${NCURSES_WRAP_PREFIX}acs_map
20455 cat >"conftest.$ac_ext" <<_ACEOF
20456 #line 20456 "configure"
20457 #include "confdefs.h"
20459 #include <${cf_cv_ncurses_header:-curses.h}>
20465 ${name}['k'] = ACS_PLUS
20471 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
20472 if { (eval echo "$as_me:20472: \"$ac_link\"") >&5
20473 (eval $ac_link) 2>&5
20475 echo "$as_me:20475: \$? = $ac_status" >&5
20476 (exit "$ac_status"); } &&
20477 { ac_try='test -s "conftest$ac_exeext"'
20478 { (eval echo "$as_me:20478: \"$ac_try\"") >&5
20479 (eval $ac_try) 2>&5
20481 echo "$as_me:20481: \$? = $ac_status" >&5
20482 (exit "$ac_status"); }; }; then
20483 cf_cv_curses_acs_map=$name; break
20485 echo "$as_me: failed program was:" >&5
20486 cat "conftest.$ac_ext" >&5
20488 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
20492 echo "$as_me:20492: result: $cf_cv_curses_acs_map" >&5
20493 echo "${ECHO_T}$cf_cv_curses_acs_map" >&6
20495 test "$cf_cv_curses_acs_map" != unknown &&
20496 cat >>confdefs.h <<EOF
20497 #define CURSES_ACS_ARRAY $cf_cv_curses_acs_map
20500 if test "$cf_enable_widec" = yes; then
20502 echo "$as_me:20502: checking for wide alternate character set array" >&5
20503 echo $ECHO_N "checking for wide alternate character set array... $ECHO_C" >&6
20504 if test "${cf_cv_curses_wacs_map+set}" = set; then
20505 echo $ECHO_N "(cached) $ECHO_C" >&6
20508 cf_cv_curses_wacs_map=unknown
20509 for name in wacs_map _wacs_map __wacs_map _nc_wacs _wacs_char
20511 cat >"conftest.$ac_ext" <<_ACEOF
20512 #line 20512 "configure"
20513 #include "confdefs.h"
20515 #ifndef _XOPEN_SOURCE_EXTENDED
20516 #define _XOPEN_SOURCE_EXTENDED
20518 #include <${cf_cv_ncurses_header:-curses.h}>
20522 void *foo = &(${name}['k']); (void)foo
20527 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
20528 if { (eval echo "$as_me:20528: \"$ac_link\"") >&5
20529 (eval $ac_link) 2>&5
20531 echo "$as_me:20531: \$? = $ac_status" >&5
20532 (exit "$ac_status"); } &&
20533 { ac_try='test -s "conftest$ac_exeext"'
20534 { (eval echo "$as_me:20534: \"$ac_try\"") >&5
20535 (eval $ac_try) 2>&5
20537 echo "$as_me:20537: \$? = $ac_status" >&5
20538 (exit "$ac_status"); }; }; then
20539 cf_cv_curses_wacs_map=$name
20542 echo "$as_me: failed program was:" >&5
20543 cat "conftest.$ac_ext" >&5
20545 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
20548 echo "$as_me:20548: result: $cf_cv_curses_wacs_map" >&5
20549 echo "${ECHO_T}$cf_cv_curses_wacs_map" >&6
20551 test "$cf_cv_curses_wacs_map" != unknown &&
20552 cat >>confdefs.h <<EOF
20553 #define CURSES_WACS_ARRAY $cf_cv_curses_wacs_map
20556 echo "$as_me:20556: checking for wide alternate character constants" >&5
20557 echo $ECHO_N "checking for wide alternate character constants... $ECHO_C" >&6
20558 if test "${cf_cv_curses_wacs_symbols+set}" = set; then
20559 echo $ECHO_N "(cached) $ECHO_C" >&6
20562 cf_cv_curses_wacs_symbols=no
20563 if test "$cf_cv_curses_wacs_map" != unknown
20565 cat >"conftest.$ac_ext" <<_ACEOF
20566 #line 20566 "configure"
20567 #include "confdefs.h"
20569 #ifndef _XOPEN_SOURCE_EXTENDED
20570 #define _XOPEN_SOURCE_EXTENDED
20572 #include <${cf_cv_ncurses_header:-curses.h}>
20576 cchar_t *foo = WACS_PLUS;
20577 ${cf_cv_curses_wacs_map}['k'] = *WACS_PLUS; (void)foo
20582 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
20583 if { (eval echo "$as_me:20583: \"$ac_link\"") >&5
20584 (eval $ac_link) 2>&5
20586 echo "$as_me:20586: \$? = $ac_status" >&5
20587 (exit "$ac_status"); } &&
20588 { ac_try='test -s "conftest$ac_exeext"'
20589 { (eval echo "$as_me:20589: \"$ac_try\"") >&5
20590 (eval $ac_try) 2>&5
20592 echo "$as_me:20592: \$? = $ac_status" >&5
20593 (exit "$ac_status"); }; }; then
20594 cf_cv_curses_wacs_symbols=yes
20596 echo "$as_me: failed program was:" >&5
20597 cat "conftest.$ac_ext" >&5
20599 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
20601 cat >"conftest.$ac_ext" <<_ACEOF
20602 #line 20602 "configure"
20603 #include "confdefs.h"
20605 #ifndef _XOPEN_SOURCE_EXTENDED
20606 #define _XOPEN_SOURCE_EXTENDED
20608 #include <${cf_cv_ncurses_header:-curses.h}>
20612 cchar_t *foo = WACS_PLUS; (void)foo
20617 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
20618 if { (eval echo "$as_me:20618: \"$ac_link\"") >&5
20619 (eval $ac_link) 2>&5
20621 echo "$as_me:20621: \$? = $ac_status" >&5
20622 (exit "$ac_status"); } &&
20623 { ac_try='test -s "conftest$ac_exeext"'
20624 { (eval echo "$as_me:20624: \"$ac_try\"") >&5
20625 (eval $ac_try) 2>&5
20627 echo "$as_me:20627: \$? = $ac_status" >&5
20628 (exit "$ac_status"); }; }; then
20629 cf_cv_curses_wacs_symbols=yes
20631 echo "$as_me: failed program was:" >&5
20632 cat "conftest.$ac_ext" >&5
20634 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
20638 echo "$as_me:20638: result: $cf_cv_curses_wacs_symbols" >&5
20639 echo "${ECHO_T}$cf_cv_curses_wacs_symbols" >&6
20641 test "$cf_cv_curses_wacs_symbols" != no &&
20642 cat >>confdefs.h <<\EOF
20643 #define CURSES_WACS_SYMBOLS 1
20648 echo "$as_me:20648: checking for type attr_t in ${cf_cv_ncurses_header:-curses.h}" >&5
20649 echo $ECHO_N "checking for type attr_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
20650 cat >"conftest.$ac_ext" <<_ACEOF
20651 #line 20651 "configure"
20652 #include "confdefs.h"
20654 #ifndef _XOPEN_SOURCE_EXTENDED
20655 #define _XOPEN_SOURCE_EXTENDED
20657 #include <${cf_cv_ncurses_header:-curses.h}>
20668 rm -f "conftest.$ac_objext"
20669 if { (eval echo "$as_me:20669: \"$ac_compile\"") >&5
20670 (eval $ac_compile) 2>&5
20672 echo "$as_me:20672: \$? = $ac_status" >&5
20673 (exit "$ac_status"); } &&
20674 { ac_try='test -s "conftest.$ac_objext"'
20675 { (eval echo "$as_me:20675: \"$ac_try\"") >&5
20676 (eval $ac_try) 2>&5
20678 echo "$as_me:20678: \$? = $ac_status" >&5
20679 (exit "$ac_status"); }; }; then
20682 echo "$as_me: failed program was:" >&5
20683 cat "conftest.$ac_ext" >&5
20686 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
20687 echo "$as_me:20687: result: $cf_result" >&5
20688 echo "${ECHO_T}$cf_result" >&6
20689 if test "$cf_result" = yes ; then
20691 cf_result=`echo "have_type_attr_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
20693 cat >>confdefs.h <<EOF
20694 #define $cf_result 1
20699 cat >>confdefs.h <<EOF
20700 #define attr_t long
20705 if test "$cf_enable_widec" = yes; then
20707 # This is needed on Tru64 5.0 to declare mbstate_t
20708 echo "$as_me:20708: checking if we must include wchar.h to declare mbstate_t" >&5
20709 echo $ECHO_N "checking if we must include wchar.h to declare mbstate_t... $ECHO_C" >&6
20710 if test "${cf_cv_mbstate_t+set}" = set; then
20711 echo $ECHO_N "(cached) $ECHO_C" >&6
20714 cat >"conftest.$ac_ext" <<_ACEOF
20715 #line 20715 "configure"
20716 #include "confdefs.h"
20718 #include <stdlib.h>
20719 #include <stdarg.h>
20721 #ifdef HAVE_LIBUTF8_H
20722 #include <libutf8.h>
20727 mbstate_t state; (void)state
20732 rm -f "conftest.$ac_objext"
20733 if { (eval echo "$as_me:20733: \"$ac_compile\"") >&5
20734 (eval $ac_compile) 2>&5
20736 echo "$as_me:20736: \$? = $ac_status" >&5
20737 (exit "$ac_status"); } &&
20738 { ac_try='test -s "conftest.$ac_objext"'
20739 { (eval echo "$as_me:20739: \"$ac_try\"") >&5
20740 (eval $ac_try) 2>&5
20742 echo "$as_me:20742: \$? = $ac_status" >&5
20743 (exit "$ac_status"); }; }; then
20746 echo "$as_me: failed program was:" >&5
20747 cat "conftest.$ac_ext" >&5
20748 cat >"conftest.$ac_ext" <<_ACEOF
20749 #line 20749 "configure"
20750 #include "confdefs.h"
20752 #include <stdlib.h>
20753 #include <stdarg.h>
20756 #ifdef HAVE_LIBUTF8_H
20757 #include <libutf8.h>
20762 mbstate_t value; (void) value
20767 rm -f "conftest.$ac_objext"
20768 if { (eval echo "$as_me:20768: \"$ac_compile\"") >&5
20769 (eval $ac_compile) 2>&5
20771 echo "$as_me:20771: \$? = $ac_status" >&5
20772 (exit "$ac_status"); } &&
20773 { ac_try='test -s "conftest.$ac_objext"'
20774 { (eval echo "$as_me:20774: \"$ac_try\"") >&5
20775 (eval $ac_try) 2>&5
20777 echo "$as_me:20777: \$? = $ac_status" >&5
20778 (exit "$ac_status"); }; }; then
20779 cf_cv_mbstate_t=yes
20781 echo "$as_me: failed program was:" >&5
20782 cat "conftest.$ac_ext" >&5
20783 cf_cv_mbstate_t=unknown
20785 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
20787 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
20789 echo "$as_me:20789: result: $cf_cv_mbstate_t" >&5
20790 echo "${ECHO_T}$cf_cv_mbstate_t" >&6
20792 if test "$cf_cv_mbstate_t" = yes ; then
20794 cat >>confdefs.h <<\EOF
20795 #define NEED_WCHAR_H 1
20801 # if we do not find mbstate_t in either place, use substitution to provide a fallback.
20802 if test "$cf_cv_mbstate_t" = unknown ; then
20803 NCURSES_MBSTATE_T=1
20806 # if we find mbstate_t in either place, use substitution to provide a fallback.
20807 if test "$cf_cv_mbstate_t" != unknown ; then
20808 NCURSES_OK_MBSTATE_T=1
20811 # This is needed on Tru64 5.0 to declare wchar_t
20812 echo "$as_me:20812: checking if we must include wchar.h to declare wchar_t" >&5
20813 echo $ECHO_N "checking if we must include wchar.h to declare wchar_t... $ECHO_C" >&6
20814 if test "${cf_cv_wchar_t+set}" = set; then
20815 echo $ECHO_N "(cached) $ECHO_C" >&6
20818 cat >"conftest.$ac_ext" <<_ACEOF
20819 #line 20819 "configure"
20820 #include "confdefs.h"
20822 #include <stdlib.h>
20823 #include <stdarg.h>
20825 #ifdef HAVE_LIBUTF8_H
20826 #include <libutf8.h>
20831 wchar_t state; (void)state
20836 rm -f "conftest.$ac_objext"
20837 if { (eval echo "$as_me:20837: \"$ac_compile\"") >&5
20838 (eval $ac_compile) 2>&5
20840 echo "$as_me:20840: \$? = $ac_status" >&5
20841 (exit "$ac_status"); } &&
20842 { ac_try='test -s "conftest.$ac_objext"'
20843 { (eval echo "$as_me:20843: \"$ac_try\"") >&5
20844 (eval $ac_try) 2>&5
20846 echo "$as_me:20846: \$? = $ac_status" >&5
20847 (exit "$ac_status"); }; }; then
20850 echo "$as_me: failed program was:" >&5
20851 cat "conftest.$ac_ext" >&5
20852 cat >"conftest.$ac_ext" <<_ACEOF
20853 #line 20853 "configure"
20854 #include "confdefs.h"
20856 #include <stdlib.h>
20857 #include <stdarg.h>
20860 #ifdef HAVE_LIBUTF8_H
20861 #include <libutf8.h>
20866 wchar_t value; (void) value
20871 rm -f "conftest.$ac_objext"
20872 if { (eval echo "$as_me:20872: \"$ac_compile\"") >&5
20873 (eval $ac_compile) 2>&5
20875 echo "$as_me:20875: \$? = $ac_status" >&5
20876 (exit "$ac_status"); } &&
20877 { ac_try='test -s "conftest.$ac_objext"'
20878 { (eval echo "$as_me:20878: \"$ac_try\"") >&5
20879 (eval $ac_try) 2>&5
20881 echo "$as_me:20881: \$? = $ac_status" >&5
20882 (exit "$ac_status"); }; }; then
20885 echo "$as_me: failed program was:" >&5
20886 cat "conftest.$ac_ext" >&5
20887 cf_cv_wchar_t=unknown
20889 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
20891 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
20893 echo "$as_me:20893: result: $cf_cv_wchar_t" >&5
20894 echo "${ECHO_T}$cf_cv_wchar_t" >&6
20896 if test "$cf_cv_wchar_t" = yes ; then
20898 cat >>confdefs.h <<\EOF
20899 #define NEED_WCHAR_H 1
20905 # if we do not find wchar_t in either place, use substitution to provide a fallback.
20906 if test "$cf_cv_wchar_t" = unknown ; then
20910 # if we find wchar_t in either place, use substitution to provide a fallback.
20911 if test "$cf_cv_wchar_t" != unknown ; then
20912 NCURSES_OK_WCHAR_T=1
20915 # This is needed on Tru64 5.0 to declare wint_t
20916 echo "$as_me:20916: checking if we must include wchar.h to declare wint_t" >&5
20917 echo $ECHO_N "checking if we must include wchar.h to declare wint_t... $ECHO_C" >&6
20918 if test "${cf_cv_wint_t+set}" = set; then
20919 echo $ECHO_N "(cached) $ECHO_C" >&6
20922 cat >"conftest.$ac_ext" <<_ACEOF
20923 #line 20923 "configure"
20924 #include "confdefs.h"
20926 #include <stdlib.h>
20927 #include <stdarg.h>
20929 #ifdef HAVE_LIBUTF8_H
20930 #include <libutf8.h>
20935 wint_t state; (void)state
20940 rm -f "conftest.$ac_objext"
20941 if { (eval echo "$as_me:20941: \"$ac_compile\"") >&5
20942 (eval $ac_compile) 2>&5
20944 echo "$as_me:20944: \$? = $ac_status" >&5
20945 (exit "$ac_status"); } &&
20946 { ac_try='test -s "conftest.$ac_objext"'
20947 { (eval echo "$as_me:20947: \"$ac_try\"") >&5
20948 (eval $ac_try) 2>&5
20950 echo "$as_me:20950: \$? = $ac_status" >&5
20951 (exit "$ac_status"); }; }; then
20954 echo "$as_me: failed program was:" >&5
20955 cat "conftest.$ac_ext" >&5
20956 cat >"conftest.$ac_ext" <<_ACEOF
20957 #line 20957 "configure"
20958 #include "confdefs.h"
20960 #include <stdlib.h>
20961 #include <stdarg.h>
20964 #ifdef HAVE_LIBUTF8_H
20965 #include <libutf8.h>
20970 wint_t value; (void) value
20975 rm -f "conftest.$ac_objext"
20976 if { (eval echo "$as_me:20976: \"$ac_compile\"") >&5
20977 (eval $ac_compile) 2>&5
20979 echo "$as_me:20979: \$? = $ac_status" >&5
20980 (exit "$ac_status"); } &&
20981 { ac_try='test -s "conftest.$ac_objext"'
20982 { (eval echo "$as_me:20982: \"$ac_try\"") >&5
20983 (eval $ac_try) 2>&5
20985 echo "$as_me:20985: \$? = $ac_status" >&5
20986 (exit "$ac_status"); }; }; then
20989 echo "$as_me: failed program was:" >&5
20990 cat "conftest.$ac_ext" >&5
20991 cf_cv_wint_t=unknown
20993 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
20995 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
20997 echo "$as_me:20997: result: $cf_cv_wint_t" >&5
20998 echo "${ECHO_T}$cf_cv_wint_t" >&6
21000 if test "$cf_cv_wint_t" = yes ; then
21002 cat >>confdefs.h <<\EOF
21003 #define NEED_WCHAR_H 1
21009 # if we do not find wint_t in either place, use substitution to provide a fallback.
21010 if test "$cf_cv_wint_t" = unknown ; then
21014 # if we find wint_t in either place, use substitution to provide a fallback.
21015 if test "$cf_cv_wint_t" != unknown ; then
21016 NCURSES_OK_WINT_T=1
21019 if test "$NCURSES_OK_MBSTATE_T" = 0 ; then
21021 echo "$as_me:21021: checking for type mbstate_t in ${cf_cv_ncurses_header:-curses.h}" >&5
21022 echo $ECHO_N "checking for type mbstate_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
21023 cat >"conftest.$ac_ext" <<_ACEOF
21024 #line 21024 "configure"
21025 #include "confdefs.h"
21027 #ifndef _XOPEN_SOURCE_EXTENDED
21028 #define _XOPEN_SOURCE_EXTENDED
21030 #include <${cf_cv_ncurses_header:-curses.h}>
21041 rm -f "conftest.$ac_objext"
21042 if { (eval echo "$as_me:21042: \"$ac_compile\"") >&5
21043 (eval $ac_compile) 2>&5
21045 echo "$as_me:21045: \$? = $ac_status" >&5
21046 (exit "$ac_status"); } &&
21047 { ac_try='test -s "conftest.$ac_objext"'
21048 { (eval echo "$as_me:21048: \"$ac_try\"") >&5
21049 (eval $ac_try) 2>&5
21051 echo "$as_me:21051: \$? = $ac_status" >&5
21052 (exit "$ac_status"); }; }; then
21055 echo "$as_me: failed program was:" >&5
21056 cat "conftest.$ac_ext" >&5
21059 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
21060 echo "$as_me:21060: result: $cf_result" >&5
21061 echo "${ECHO_T}$cf_result" >&6
21062 if test "$cf_result" = yes ; then
21064 cf_result=`echo "have_type_mbstate_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
21066 cat >>confdefs.h <<EOF
21067 #define $cf_result 1
21072 cat >>confdefs.h <<EOF
21073 #define mbstate_t long
21080 if test "$NCURSES_OK_WCHAR_T" = 0 ; then
21082 echo "$as_me:21082: checking for type wchar_t in ${cf_cv_ncurses_header:-curses.h}" >&5
21083 echo $ECHO_N "checking for type wchar_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
21084 cat >"conftest.$ac_ext" <<_ACEOF
21085 #line 21085 "configure"
21086 #include "confdefs.h"
21088 #ifndef _XOPEN_SOURCE_EXTENDED
21089 #define _XOPEN_SOURCE_EXTENDED
21091 #include <${cf_cv_ncurses_header:-curses.h}>
21102 rm -f "conftest.$ac_objext"
21103 if { (eval echo "$as_me:21103: \"$ac_compile\"") >&5
21104 (eval $ac_compile) 2>&5
21106 echo "$as_me:21106: \$? = $ac_status" >&5
21107 (exit "$ac_status"); } &&
21108 { ac_try='test -s "conftest.$ac_objext"'
21109 { (eval echo "$as_me:21109: \"$ac_try\"") >&5
21110 (eval $ac_try) 2>&5
21112 echo "$as_me:21112: \$? = $ac_status" >&5
21113 (exit "$ac_status"); }; }; then
21116 echo "$as_me: failed program was:" >&5
21117 cat "conftest.$ac_ext" >&5
21120 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
21121 echo "$as_me:21121: result: $cf_result" >&5
21122 echo "${ECHO_T}$cf_result" >&6
21123 if test "$cf_result" = yes ; then
21125 cf_result=`echo "have_type_wchar_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
21127 cat >>confdefs.h <<EOF
21128 #define $cf_result 1
21133 cat >>confdefs.h <<EOF
21134 #define wchar_t long
21141 if test "$NCURSES_OK_WINT_T" = 0 ; then
21143 echo "$as_me:21143: checking for type wint_t in ${cf_cv_ncurses_header:-curses.h}" >&5
21144 echo $ECHO_N "checking for type wint_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
21145 cat >"conftest.$ac_ext" <<_ACEOF
21146 #line 21146 "configure"
21147 #include "confdefs.h"
21149 #ifndef _XOPEN_SOURCE_EXTENDED
21150 #define _XOPEN_SOURCE_EXTENDED
21152 #include <${cf_cv_ncurses_header:-curses.h}>
21163 rm -f "conftest.$ac_objext"
21164 if { (eval echo "$as_me:21164: \"$ac_compile\"") >&5
21165 (eval $ac_compile) 2>&5
21167 echo "$as_me:21167: \$? = $ac_status" >&5
21168 (exit "$ac_status"); } &&
21169 { ac_try='test -s "conftest.$ac_objext"'
21170 { (eval echo "$as_me:21170: \"$ac_try\"") >&5
21171 (eval $ac_try) 2>&5
21173 echo "$as_me:21173: \$? = $ac_status" >&5
21174 (exit "$ac_status"); }; }; then
21177 echo "$as_me: failed program was:" >&5
21178 cat "conftest.$ac_ext" >&5
21181 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
21182 echo "$as_me:21182: result: $cf_result" >&5
21183 echo "${ECHO_T}$cf_result" >&6
21184 if test "$cf_result" = yes ; then
21186 cf_result=`echo "have_type_wint_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
21188 cat >>confdefs.h <<EOF
21189 #define $cf_result 1
21194 cat >>confdefs.h <<EOF
21195 #define wint_t long
21211 echo "$as_me:21211: checking for data $cf_data declaration in ${cf_cv_ncurses_header:-curses.h}" >&5
21212 echo $ECHO_N "checking for data $cf_data declaration in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
21214 cat >"conftest.$ac_ext" <<_ACEOF
21215 #line 21215 "configure"
21216 #include "confdefs.h"
21218 #ifdef HAVE_XCURSES
21219 #include <xcurses.h>
21220 char * XCursesProgramName = "test";
21222 #include <${cf_cv_ncurses_header:-curses.h}>
21223 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
21224 #include <ncursesw/term.h>
21225 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
21226 #include <ncurses/term.h>
21227 #elif defined(HAVE_TERM_H)
21236 #if defined($cf_data) && ((defined(NCURSES_WRAPPED_VAR) && (NCURSES_VERSION_PATCH < 20200208)) || defined(NCURSES_BROKEN_LINKER) || defined(NCURSES_REENTRANT))
21237 const void *foo = (const void *)($cf_data);
21239 const void *foo = &($cf_data);
21241 fprintf(stderr, "testing linkage of $cf_data:%p\\n", (const void *)foo);
21247 rm -f "conftest.$ac_objext"
21248 if { (eval echo "$as_me:21248: \"$ac_compile\"") >&5
21249 (eval $ac_compile) 2>&5
21251 echo "$as_me:21251: \$? = $ac_status" >&5
21252 (exit "$ac_status"); } &&
21253 { ac_try='test -s "conftest.$ac_objext"'
21254 { (eval echo "$as_me:21254: \"$ac_try\"") >&5
21255 (eval $ac_try) 2>&5
21257 echo "$as_me:21257: \$? = $ac_status" >&5
21258 (exit "$ac_status"); }; }; then
21262 echo "$as_me: failed program was:" >&5
21263 cat "conftest.$ac_ext" >&5
21266 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
21267 echo "$as_me:21267: result: $cf_result" >&5
21268 echo "${ECHO_T}$cf_result" >&6
21270 if test "$cf_result" = yes ; then
21272 cf_result=`echo "have_curses_data_$cf_data" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
21274 cat >>confdefs.h <<EOF
21275 #define $cf_result 1
21279 echo "$as_me:21279: checking for data $cf_data in library" >&5
21280 echo $ECHO_N "checking for data $cf_data in library... $ECHO_C" >&6
21281 # BSD linkers insist on making weak linkage, but resolve at runtime.
21282 if test "$cross_compiling" = yes; then
21285 cat >"conftest.$ac_ext" <<_ACEOF
21286 #line 21286 "configure"
21287 #include "confdefs.h"
21289 #ifdef HAVE_XCURSES
21290 #include <xcurses.h>
21291 char * XCursesProgramName = "test";
21293 #include <${cf_cv_ncurses_header:-curses.h}>
21294 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
21295 #include <ncursesw/term.h>
21296 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
21297 #include <ncurses/term.h>
21298 #elif defined(HAVE_TERM_H)
21303 extern char $cf_data;
21310 #if defined($cf_data) && ((defined(NCURSES_WRAPPED_VAR) && (NCURSES_VERSION_PATCH < 20200208)) || defined(NCURSES_BROKEN_LINKER) || defined(NCURSES_REENTRANT))
21311 const void *foo = (const void *)($cf_data);
21313 const void *foo = &($cf_data);
21315 fprintf(stderr, "testing linkage of $cf_data:%p\\n", (const void *)foo);
21317 ${cf_cv_main_return:-return}(foo == 0);
21324 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
21325 if { (eval echo "$as_me:21325: \"$ac_link\"") >&5
21326 (eval $ac_link) 2>&5
21328 echo "$as_me:21328: \$? = $ac_status" >&5
21329 (exit "$ac_status"); } &&
21330 { ac_try='test -s "conftest$ac_exeext"'
21331 { (eval echo "$as_me:21331: \"$ac_try\"") >&5
21332 (eval $ac_try) 2>&5
21334 echo "$as_me:21334: \$? = $ac_status" >&5
21335 (exit "$ac_status"); }; }; then
21338 echo "$as_me: failed program was:" >&5
21339 cat "conftest.$ac_ext" >&5
21342 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
21345 cat >"conftest.$ac_ext" <<_ACEOF
21346 #line 21346 "configure"
21347 #include "confdefs.h"
21349 #ifdef HAVE_XCURSES
21350 #include <xcurses.h>
21351 char * XCursesProgramName = "test";
21353 #include <${cf_cv_ncurses_header:-curses.h}>
21354 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
21355 #include <ncursesw/term.h>
21356 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
21357 #include <ncurses/term.h>
21358 #elif defined(HAVE_TERM_H)
21363 extern char $cf_data;
21367 #if defined($cf_data) && ((defined(NCURSES_WRAPPED_VAR) && (NCURSES_VERSION_PATCH < 20200208)) || defined(NCURSES_BROKEN_LINKER) || defined(NCURSES_REENTRANT))
21368 const void *foo = (const void *)($cf_data);
21370 const void *foo = &($cf_data);
21372 fprintf(stderr, "testing linkage of $cf_data:%p\\n", (const void *)foo);
21374 ${cf_cv_main_return:-return}(foo == 0);
21377 rm -f "conftest$ac_exeext"
21378 if { (eval echo "$as_me:21378: \"$ac_link\"") >&5
21379 (eval $ac_link) 2>&5
21381 echo "$as_me:21381: \$? = $ac_status" >&5
21382 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
21383 { (eval echo "$as_me:21383: \"$ac_try\"") >&5
21384 (eval $ac_try) 2>&5
21386 echo "$as_me:21386: \$? = $ac_status" >&5
21387 (exit "$ac_status"); }; }; then
21391 echo "$as_me: program exited with status $ac_status" >&5
21392 echo "$as_me: failed program was:" >&5
21393 cat "conftest.$ac_ext" >&5
21396 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
21398 echo "$as_me:21398: result: $cf_result" >&5
21399 echo "${ECHO_T}$cf_result" >&6
21400 if test "$cf_result" = yes ; then
21402 cf_result=`echo "decl_curses_data_$cf_data" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
21404 cat >>confdefs.h <<EOF
21405 #define $cf_result 1
21408 # do not exit loop here, since we prefer system's declarations
21413 if test -n "$with_screen" && test "x$with_screen" = "xpdcurses"
21415 echo "$as_me:21415: checking for X" >&5
21416 echo $ECHO_N "checking for X... $ECHO_C" >&6
21418 # Check whether --with-x or --without-x was given.
21419 if test "${with_x+set}" = set; then
21423 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
21424 if test "x$with_x" = xno; then
21425 # The user explicitly disabled X.
21428 if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
21429 # Both variables are already set.
21432 if test "${ac_cv_have_x+set}" = set; then
21433 echo $ECHO_N "(cached) $ECHO_C" >&6
21435 # One or both of the vars are not set, and there is no cached value.
21436 ac_x_includes=no ac_x_libraries=no
21437 rm -fr conftest.dir
21438 if mkdir conftest.dir; then
21440 # Make sure to not put "make" in the Imakefile rules, since we grep it out.
21441 cat >Imakefile <<'EOF'
21443 @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
21445 if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
21446 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
21447 eval "`${MAKE-make} acfindx 2>/dev/null | grep -v make`"
21448 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
21449 for ac_extension in a so sl dylib dll; do
21450 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
21451 test -f "$ac_im_libdir/libX11.$ac_extension"; then
21452 ac_im_usrlibdir=$ac_im_libdir; break
21455 # Screen out bogus values from the imake configuration. They are
21456 # bogus both because they are the default anyway, and because
21457 # using them would break gcc on systems where it needs fixed includes.
21458 case $ac_im_incroot in
21460 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
21462 case $ac_im_usrlibdir in
21463 /usr/lib | /lib) ;;
21464 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
21468 rm -fr conftest.dir
21471 # Standard set of common directories for X headers.
21472 # Check X11 before X11Rn because it is often a symlink to the current release.
21489 /usr/local/X11/include
21490 /usr/local/X11R7/include
21491 /usr/local/X11R6/include
21492 /usr/local/X11R5/include
21493 /usr/local/X11R4/include
21495 /usr/local/include/X11
21496 /usr/local/include/X11R7
21497 /usr/local/include/X11R6
21498 /usr/local/include/X11R5
21499 /usr/local/include/X11R4
21503 /usr/XFree86/include/X11
21507 /usr/unsupported/include
21508 /usr/athena/include
21509 /usr/local/x11r5/include
21510 /usr/lpp/Xamples/include
21512 /usr/openwin/include
21513 /usr/openwin/share/include'
21515 if test "$ac_x_includes" = no; then
21516 # Guess where to find include files, by looking for Intrinsic.h.
21517 # First, try using that file with no special directory specified.
21518 cat >"conftest.$ac_ext" <<_ACEOF
21519 #line 21519 "configure"
21520 #include "confdefs.h"
21521 #include <X11/Intrinsic.h>
21523 if { (eval echo "$as_me:21523: \"$ac_cpp "conftest.$ac_ext"\"") >&5
21524 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
21526 $EGREP -v '^ *\+' conftest.er1 >conftest.err
21528 cat conftest.err >&5
21529 echo "$as_me:21529: \$? = $ac_status" >&5
21530 (exit "$ac_status"); } >/dev/null; then
21531 if test -s conftest.err; then
21532 ac_cpp_err=$ac_c_preproc_warn_flag
21539 if test -z "$ac_cpp_err"; then
21540 # We can compile using X headers with no special include directory.
21543 echo "$as_me: failed program was:" >&5
21544 cat "conftest.$ac_ext" >&5
21545 for ac_dir in $ac_x_header_dirs; do
21546 if test -r "$ac_dir/X11/Intrinsic.h"; then
21547 ac_x_includes=$ac_dir
21552 rm -f conftest.err "conftest.$ac_ext"
21553 fi # $ac_x_includes = no
21555 if test "$ac_x_libraries" = no; then
21556 # Check for the libraries.
21557 # See if we find them without any special options.
21558 # Don't add to $LIBS permanently.
21561 cat >"conftest.$ac_ext" <<_ACEOF
21562 #line 21562 "configure"
21563 #include "confdefs.h"
21564 #include <X11/Intrinsic.h>
21573 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
21574 if { (eval echo "$as_me:21574: \"$ac_link\"") >&5
21575 (eval $ac_link) 2>&5
21577 echo "$as_me:21577: \$? = $ac_status" >&5
21578 (exit "$ac_status"); } &&
21579 { ac_try='test -s "conftest$ac_exeext"'
21580 { (eval echo "$as_me:21580: \"$ac_try\"") >&5
21581 (eval $ac_try) 2>&5
21583 echo "$as_me:21583: \$? = $ac_status" >&5
21584 (exit "$ac_status"); }; }; then
21586 # We can link X programs with no special library path.
21589 echo "$as_me: failed program was:" >&5
21590 cat "conftest.$ac_ext" >&5
21592 for ac_dir in `echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
21594 # Don't even attempt the hair of trying to link an X program!
21595 for ac_extension in a so sl dylib dll; do
21596 if test -r "$ac_dir/libXt.$ac_extension"; then
21597 ac_x_libraries=$ac_dir
21603 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
21604 fi # $ac_x_libraries = no
21606 if test "$ac_x_includes" = no || test "$ac_x_libraries" = no; then
21607 # Didn't find X anywhere. Cache the known absence of X.
21608 ac_cv_have_x="have_x=no"
21610 # Record where we found X for the cache.
21611 ac_cv_have_x="have_x=yes \
21612 ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
21617 eval "$ac_cv_have_x"
21620 if test "$have_x" != yes; then
21621 echo "$as_me:21621: result: $have_x" >&5
21622 echo "${ECHO_T}$have_x" >&6
21625 # If each of the values was on the command line, it overrides each guess.
21626 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
21627 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
21628 # Update the cache value to reflect the command line values.
21629 ac_cv_have_x="have_x=yes \
21630 ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
21631 echo "$as_me:21631: result: libraries $x_libraries, headers $x_includes" >&5
21632 echo "${ECHO_T}libraries $x_libraries, headers $x_includes" >&6
21635 if test "$no_x" = yes; then
21636 # Not all programs may use this symbol, but it does not hurt to define it.
21638 cat >>confdefs.h <<\EOF
21639 #define X_DISPLAY_MISSING 1
21647 if test -n "$x_includes"; then
21648 X_CFLAGS="$X_CFLAGS -I$x_includes"
21651 # It would also be nice to do this for all -L options, not just this one.
21652 if test -n "$x_libraries"; then
21653 X_LIBS="$X_LIBS -L$x_libraries"
21654 # For Solaris; some versions of Sun CC require a space after -R and
21655 # others require no space. Words are not sufficient . . . .
21656 case `(uname -sr) 2>/dev/null` in
21658 echo "$as_me:21658: checking whether -R must be followed by a space" >&5
21659 echo $ECHO_N "checking whether -R must be followed by a space... $ECHO_C" >&6
21660 ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries"
21661 cat >"conftest.$ac_ext" <<_ACEOF
21662 #line 21662 "configure"
21663 #include "confdefs.h"
21673 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
21674 if { (eval echo "$as_me:21674: \"$ac_link\"") >&5
21675 (eval $ac_link) 2>&5
21677 echo "$as_me:21677: \$? = $ac_status" >&5
21678 (exit "$ac_status"); } &&
21679 { ac_try='test -s "conftest$ac_exeext"'
21680 { (eval echo "$as_me:21680: \"$ac_try\"") >&5
21681 (eval $ac_try) 2>&5
21683 echo "$as_me:21683: \$? = $ac_status" >&5
21684 (exit "$ac_status"); }; }; then
21687 echo "$as_me: failed program was:" >&5
21688 cat "conftest.$ac_ext" >&5
21691 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
21692 if test $ac_R_nospace = yes; then
21693 echo "$as_me:21693: result: no" >&5
21694 echo "${ECHO_T}no" >&6
21695 X_LIBS="$X_LIBS -R$x_libraries"
21697 LIBS="$ac_xsave_LIBS -R $x_libraries"
21698 cat >"conftest.$ac_ext" <<_ACEOF
21699 #line 21699 "configure"
21700 #include "confdefs.h"
21710 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
21711 if { (eval echo "$as_me:21711: \"$ac_link\"") >&5
21712 (eval $ac_link) 2>&5
21714 echo "$as_me:21714: \$? = $ac_status" >&5
21715 (exit "$ac_status"); } &&
21716 { ac_try='test -s "conftest$ac_exeext"'
21717 { (eval echo "$as_me:21717: \"$ac_try\"") >&5
21718 (eval $ac_try) 2>&5
21720 echo "$as_me:21720: \$? = $ac_status" >&5
21721 (exit "$ac_status"); }; }; then
21724 echo "$as_me: failed program was:" >&5
21725 cat "conftest.$ac_ext" >&5
21728 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
21729 if test $ac_R_space = yes; then
21730 echo "$as_me:21730: result: yes" >&5
21731 echo "${ECHO_T}yes" >&6
21732 X_LIBS="$X_LIBS -R $x_libraries"
21734 echo "$as_me:21734: result: neither works" >&5
21735 echo "${ECHO_T}neither works" >&6
21738 LIBS=$ac_xsave_LIBS
21742 # Check for system-dependent libraries X programs must link with.
21743 # Do this before checking for the system-independent R6 libraries
21744 # (-lICE), since we may need -lsocket or whatever for X linking.
21746 if test "$ISC" = yes; then
21747 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
21749 # Martyn Johnson says this is needed for Ultrix, if the X
21750 # libraries were built with DECnet support. And Karl Berry says
21751 # the Alpha needs dnet_stub (dnet does not exist).
21752 ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11"
21753 cat >"conftest.$ac_ext" <<_ACEOF
21754 #line 21754 "configure"
21755 #include "confdefs.h"
21757 /* Override any gcc2 internal prototype to avoid an error. */
21761 /* We use char because int might match the return type of a gcc2
21762 builtin and then its argument prototype would still apply. */
21763 char XOpenDisplay (void);
21772 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
21773 if { (eval echo "$as_me:21773: \"$ac_link\"") >&5
21774 (eval $ac_link) 2>&5
21776 echo "$as_me:21776: \$? = $ac_status" >&5
21777 (exit "$ac_status"); } &&
21778 { ac_try='test -s "conftest$ac_exeext"'
21779 { (eval echo "$as_me:21779: \"$ac_try\"") >&5
21780 (eval $ac_try) 2>&5
21782 echo "$as_me:21782: \$? = $ac_status" >&5
21783 (exit "$ac_status"); }; }; then
21786 echo "$as_me: failed program was:" >&5
21787 cat "conftest.$ac_ext" >&5
21788 echo "$as_me:21788: checking for dnet_ntoa in -ldnet" >&5
21789 echo $ECHO_N "checking for dnet_ntoa in -ldnet... $ECHO_C" >&6
21790 if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then
21791 echo $ECHO_N "(cached) $ECHO_C" >&6
21793 ac_check_lib_save_LIBS=$LIBS
21794 LIBS="-ldnet $LIBS"
21795 cat >"conftest.$ac_ext" <<_ACEOF
21796 #line 21796 "configure"
21797 #include "confdefs.h"
21799 /* Override any gcc2 internal prototype to avoid an error. */
21803 /* We use char because int might match the return type of a gcc2
21804 builtin and then its argument prototype would still apply. */
21805 char dnet_ntoa (void);
21814 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
21815 if { (eval echo "$as_me:21815: \"$ac_link\"") >&5
21816 (eval $ac_link) 2>&5
21818 echo "$as_me:21818: \$? = $ac_status" >&5
21819 (exit "$ac_status"); } &&
21820 { ac_try='test -s "conftest$ac_exeext"'
21821 { (eval echo "$as_me:21821: \"$ac_try\"") >&5
21822 (eval $ac_try) 2>&5
21824 echo "$as_me:21824: \$? = $ac_status" >&5
21825 (exit "$ac_status"); }; }; then
21826 ac_cv_lib_dnet_dnet_ntoa=yes
21828 echo "$as_me: failed program was:" >&5
21829 cat "conftest.$ac_ext" >&5
21830 ac_cv_lib_dnet_dnet_ntoa=no
21832 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
21833 LIBS=$ac_check_lib_save_LIBS
21835 echo "$as_me:21835: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
21836 echo "${ECHO_T}$ac_cv_lib_dnet_dnet_ntoa" >&6
21837 if test "$ac_cv_lib_dnet_dnet_ntoa" = yes; then
21838 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
21841 if test $ac_cv_lib_dnet_dnet_ntoa = no; then
21842 echo "$as_me:21842: checking for dnet_ntoa in -ldnet_stub" >&5
21843 echo $ECHO_N "checking for dnet_ntoa in -ldnet_stub... $ECHO_C" >&6
21844 if test "${ac_cv_lib_dnet_stub_dnet_ntoa+set}" = set; then
21845 echo $ECHO_N "(cached) $ECHO_C" >&6
21847 ac_check_lib_save_LIBS=$LIBS
21848 LIBS="-ldnet_stub $LIBS"
21849 cat >"conftest.$ac_ext" <<_ACEOF
21850 #line 21850 "configure"
21851 #include "confdefs.h"
21853 /* Override any gcc2 internal prototype to avoid an error. */
21857 /* We use char because int might match the return type of a gcc2
21858 builtin and then its argument prototype would still apply. */
21859 char dnet_ntoa (void);
21868 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
21869 if { (eval echo "$as_me:21869: \"$ac_link\"") >&5
21870 (eval $ac_link) 2>&5
21872 echo "$as_me:21872: \$? = $ac_status" >&5
21873 (exit "$ac_status"); } &&
21874 { ac_try='test -s "conftest$ac_exeext"'
21875 { (eval echo "$as_me:21875: \"$ac_try\"") >&5
21876 (eval $ac_try) 2>&5
21878 echo "$as_me:21878: \$? = $ac_status" >&5
21879 (exit "$ac_status"); }; }; then
21880 ac_cv_lib_dnet_stub_dnet_ntoa=yes
21882 echo "$as_me: failed program was:" >&5
21883 cat "conftest.$ac_ext" >&5
21884 ac_cv_lib_dnet_stub_dnet_ntoa=no
21886 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
21887 LIBS=$ac_check_lib_save_LIBS
21889 echo "$as_me:21889: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5
21890 echo "${ECHO_T}$ac_cv_lib_dnet_stub_dnet_ntoa" >&6
21891 if test "$ac_cv_lib_dnet_stub_dnet_ntoa" = yes; then
21892 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
21897 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
21898 LIBS="$ac_xsave_LIBS"
21900 # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT,
21901 # to get the SysV transport functions.
21902 # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4)
21904 # The nsl library prevents programs from opening the X display
21905 # on Irix 5.2, according to T.E. Dickey.
21906 # The functions gethostbyname, getservbyname, and inet_addr are
21907 # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking.
21908 echo "$as_me:21908: checking for gethostbyname" >&5
21909 echo $ECHO_N "checking for gethostbyname... $ECHO_C" >&6
21910 if test "${ac_cv_func_gethostbyname+set}" = set; then
21911 echo $ECHO_N "(cached) $ECHO_C" >&6
21913 cat >"conftest.$ac_ext" <<_ACEOF
21914 #line 21914 "configure"
21915 #include "confdefs.h"
21916 #define gethostbyname autoconf_temporary
21917 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
21918 #undef gethostbyname
21924 /* We use char because int might match the return type of a gcc2
21925 builtin and then its argument prototype would still apply. */
21926 char gethostbyname (void);
21932 /* The GNU C library defines stubs for functions which it implements
21933 to always fail with ENOSYS. Some functions are actually named
21934 something starting with __ and the normal name is an alias. */
21935 #if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
21936 #error found stub for gethostbyname
21939 return gethostbyname ();
21944 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
21945 if { (eval echo "$as_me:21945: \"$ac_link\"") >&5
21946 (eval $ac_link) 2>&5
21948 echo "$as_me:21948: \$? = $ac_status" >&5
21949 (exit "$ac_status"); } &&
21950 { ac_try='test -s "conftest$ac_exeext"'
21951 { (eval echo "$as_me:21951: \"$ac_try\"") >&5
21952 (eval $ac_try) 2>&5
21954 echo "$as_me:21954: \$? = $ac_status" >&5
21955 (exit "$ac_status"); }; }; then
21956 ac_cv_func_gethostbyname=yes
21958 echo "$as_me: failed program was:" >&5
21959 cat "conftest.$ac_ext" >&5
21960 ac_cv_func_gethostbyname=no
21962 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
21964 echo "$as_me:21964: result: $ac_cv_func_gethostbyname" >&5
21965 echo "${ECHO_T}$ac_cv_func_gethostbyname" >&6
21967 if test $ac_cv_func_gethostbyname = no; then
21968 echo "$as_me:21968: checking for gethostbyname in -lnsl" >&5
21969 echo $ECHO_N "checking for gethostbyname in -lnsl... $ECHO_C" >&6
21970 if test "${ac_cv_lib_nsl_gethostbyname+set}" = set; then
21971 echo $ECHO_N "(cached) $ECHO_C" >&6
21973 ac_check_lib_save_LIBS=$LIBS
21975 cat >"conftest.$ac_ext" <<_ACEOF
21976 #line 21976 "configure"
21977 #include "confdefs.h"
21979 /* Override any gcc2 internal prototype to avoid an error. */
21983 /* We use char because int might match the return type of a gcc2
21984 builtin and then its argument prototype would still apply. */
21985 char gethostbyname (void);
21994 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
21995 if { (eval echo "$as_me:21995: \"$ac_link\"") >&5
21996 (eval $ac_link) 2>&5
21998 echo "$as_me:21998: \$? = $ac_status" >&5
21999 (exit "$ac_status"); } &&
22000 { ac_try='test -s "conftest$ac_exeext"'
22001 { (eval echo "$as_me:22001: \"$ac_try\"") >&5
22002 (eval $ac_try) 2>&5
22004 echo "$as_me:22004: \$? = $ac_status" >&5
22005 (exit "$ac_status"); }; }; then
22006 ac_cv_lib_nsl_gethostbyname=yes
22008 echo "$as_me: failed program was:" >&5
22009 cat "conftest.$ac_ext" >&5
22010 ac_cv_lib_nsl_gethostbyname=no
22012 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
22013 LIBS=$ac_check_lib_save_LIBS
22015 echo "$as_me:22015: result: $ac_cv_lib_nsl_gethostbyname" >&5
22016 echo "${ECHO_T}$ac_cv_lib_nsl_gethostbyname" >&6
22017 if test "$ac_cv_lib_nsl_gethostbyname" = yes; then
22018 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
22021 if test $ac_cv_lib_nsl_gethostbyname = no; then
22022 echo "$as_me:22022: checking for gethostbyname in -lbsd" >&5
22023 echo $ECHO_N "checking for gethostbyname in -lbsd... $ECHO_C" >&6
22024 if test "${ac_cv_lib_bsd_gethostbyname+set}" = set; then
22025 echo $ECHO_N "(cached) $ECHO_C" >&6
22027 ac_check_lib_save_LIBS=$LIBS
22029 cat >"conftest.$ac_ext" <<_ACEOF
22030 #line 22030 "configure"
22031 #include "confdefs.h"
22033 /* Override any gcc2 internal prototype to avoid an error. */
22037 /* We use char because int might match the return type of a gcc2
22038 builtin and then its argument prototype would still apply. */
22039 char gethostbyname (void);
22048 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
22049 if { (eval echo "$as_me:22049: \"$ac_link\"") >&5
22050 (eval $ac_link) 2>&5
22052 echo "$as_me:22052: \$? = $ac_status" >&5
22053 (exit "$ac_status"); } &&
22054 { ac_try='test -s "conftest$ac_exeext"'
22055 { (eval echo "$as_me:22055: \"$ac_try\"") >&5
22056 (eval $ac_try) 2>&5
22058 echo "$as_me:22058: \$? = $ac_status" >&5
22059 (exit "$ac_status"); }; }; then
22060 ac_cv_lib_bsd_gethostbyname=yes
22062 echo "$as_me: failed program was:" >&5
22063 cat "conftest.$ac_ext" >&5
22064 ac_cv_lib_bsd_gethostbyname=no
22066 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
22067 LIBS=$ac_check_lib_save_LIBS
22069 echo "$as_me:22069: result: $ac_cv_lib_bsd_gethostbyname" >&5
22070 echo "${ECHO_T}$ac_cv_lib_bsd_gethostbyname" >&6
22071 if test "$ac_cv_lib_bsd_gethostbyname" = yes; then
22072 X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd"
22078 # lieder@skyler.mavd.honeywell.com says without -lsocket,
22079 # socket/setsockopt and other routines are undefined under SCO ODT
22080 # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary
22081 # on later versions), says Simon Leinen: it contains gethostby*
22082 # variants that don't use the nameserver (or something). -lsocket
22083 # must be given before -lnsl if both are needed. We assume that
22084 # if connect needs -lnsl, so does gethostbyname.
22085 echo "$as_me:22085: checking for connect" >&5
22086 echo $ECHO_N "checking for connect... $ECHO_C" >&6
22087 if test "${ac_cv_func_connect+set}" = set; then
22088 echo $ECHO_N "(cached) $ECHO_C" >&6
22090 cat >"conftest.$ac_ext" <<_ACEOF
22091 #line 22091 "configure"
22092 #include "confdefs.h"
22093 #define connect autoconf_temporary
22094 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
22101 /* We use char because int might match the return type of a gcc2
22102 builtin and then its argument prototype would still apply. */
22103 char connect (void);
22109 /* The GNU C library defines stubs for functions which it implements
22110 to always fail with ENOSYS. Some functions are actually named
22111 something starting with __ and the normal name is an alias. */
22112 #if defined (__stub_connect) || defined (__stub___connect)
22113 #error found stub for connect
22121 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
22122 if { (eval echo "$as_me:22122: \"$ac_link\"") >&5
22123 (eval $ac_link) 2>&5
22125 echo "$as_me:22125: \$? = $ac_status" >&5
22126 (exit "$ac_status"); } &&
22127 { ac_try='test -s "conftest$ac_exeext"'
22128 { (eval echo "$as_me:22128: \"$ac_try\"") >&5
22129 (eval $ac_try) 2>&5
22131 echo "$as_me:22131: \$? = $ac_status" >&5
22132 (exit "$ac_status"); }; }; then
22133 ac_cv_func_connect=yes
22135 echo "$as_me: failed program was:" >&5
22136 cat "conftest.$ac_ext" >&5
22137 ac_cv_func_connect=no
22139 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
22141 echo "$as_me:22141: result: $ac_cv_func_connect" >&5
22142 echo "${ECHO_T}$ac_cv_func_connect" >&6
22144 if test $ac_cv_func_connect = no; then
22145 echo "$as_me:22145: checking for connect in -lsocket" >&5
22146 echo $ECHO_N "checking for connect in -lsocket... $ECHO_C" >&6
22147 if test "${ac_cv_lib_socket_connect+set}" = set; then
22148 echo $ECHO_N "(cached) $ECHO_C" >&6
22150 ac_check_lib_save_LIBS=$LIBS
22151 LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
22152 cat >"conftest.$ac_ext" <<_ACEOF
22153 #line 22153 "configure"
22154 #include "confdefs.h"
22156 /* Override any gcc2 internal prototype to avoid an error. */
22160 /* We use char because int might match the return type of a gcc2
22161 builtin and then its argument prototype would still apply. */
22162 char connect (void);
22171 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
22172 if { (eval echo "$as_me:22172: \"$ac_link\"") >&5
22173 (eval $ac_link) 2>&5
22175 echo "$as_me:22175: \$? = $ac_status" >&5
22176 (exit "$ac_status"); } &&
22177 { ac_try='test -s "conftest$ac_exeext"'
22178 { (eval echo "$as_me:22178: \"$ac_try\"") >&5
22179 (eval $ac_try) 2>&5
22181 echo "$as_me:22181: \$? = $ac_status" >&5
22182 (exit "$ac_status"); }; }; then
22183 ac_cv_lib_socket_connect=yes
22185 echo "$as_me: failed program was:" >&5
22186 cat "conftest.$ac_ext" >&5
22187 ac_cv_lib_socket_connect=no
22189 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
22190 LIBS=$ac_check_lib_save_LIBS
22192 echo "$as_me:22192: result: $ac_cv_lib_socket_connect" >&5
22193 echo "${ECHO_T}$ac_cv_lib_socket_connect" >&6
22194 if test "$ac_cv_lib_socket_connect" = yes; then
22195 X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS"
22200 # Guillermo Gomez says -lposix is necessary on A/UX.
22201 echo "$as_me:22201: checking for remove" >&5
22202 echo $ECHO_N "checking for remove... $ECHO_C" >&6
22203 if test "${ac_cv_func_remove+set}" = set; then
22204 echo $ECHO_N "(cached) $ECHO_C" >&6
22206 cat >"conftest.$ac_ext" <<_ACEOF
22207 #line 22207 "configure"
22208 #include "confdefs.h"
22209 #define remove autoconf_temporary
22210 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
22217 /* We use char because int might match the return type of a gcc2
22218 builtin and then its argument prototype would still apply. */
22219 char remove (void);
22225 /* The GNU C library defines stubs for functions which it implements
22226 to always fail with ENOSYS. Some functions are actually named
22227 something starting with __ and the normal name is an alias. */
22228 #if defined (__stub_remove) || defined (__stub___remove)
22229 #error found stub for remove
22237 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
22238 if { (eval echo "$as_me:22238: \"$ac_link\"") >&5
22239 (eval $ac_link) 2>&5
22241 echo "$as_me:22241: \$? = $ac_status" >&5
22242 (exit "$ac_status"); } &&
22243 { ac_try='test -s "conftest$ac_exeext"'
22244 { (eval echo "$as_me:22244: \"$ac_try\"") >&5
22245 (eval $ac_try) 2>&5
22247 echo "$as_me:22247: \$? = $ac_status" >&5
22248 (exit "$ac_status"); }; }; then
22249 ac_cv_func_remove=yes
22251 echo "$as_me: failed program was:" >&5
22252 cat "conftest.$ac_ext" >&5
22253 ac_cv_func_remove=no
22255 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
22257 echo "$as_me:22257: result: $ac_cv_func_remove" >&5
22258 echo "${ECHO_T}$ac_cv_func_remove" >&6
22260 if test $ac_cv_func_remove = no; then
22261 echo "$as_me:22261: checking for remove in -lposix" >&5
22262 echo $ECHO_N "checking for remove in -lposix... $ECHO_C" >&6
22263 if test "${ac_cv_lib_posix_remove+set}" = set; then
22264 echo $ECHO_N "(cached) $ECHO_C" >&6
22266 ac_check_lib_save_LIBS=$LIBS
22267 LIBS="-lposix $LIBS"
22268 cat >"conftest.$ac_ext" <<_ACEOF
22269 #line 22269 "configure"
22270 #include "confdefs.h"
22272 /* Override any gcc2 internal prototype to avoid an error. */
22276 /* We use char because int might match the return type of a gcc2
22277 builtin and then its argument prototype would still apply. */
22278 char remove (void);
22287 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
22288 if { (eval echo "$as_me:22288: \"$ac_link\"") >&5
22289 (eval $ac_link) 2>&5
22291 echo "$as_me:22291: \$? = $ac_status" >&5
22292 (exit "$ac_status"); } &&
22293 { ac_try='test -s "conftest$ac_exeext"'
22294 { (eval echo "$as_me:22294: \"$ac_try\"") >&5
22295 (eval $ac_try) 2>&5
22297 echo "$as_me:22297: \$? = $ac_status" >&5
22298 (exit "$ac_status"); }; }; then
22299 ac_cv_lib_posix_remove=yes
22301 echo "$as_me: failed program was:" >&5
22302 cat "conftest.$ac_ext" >&5
22303 ac_cv_lib_posix_remove=no
22305 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
22306 LIBS=$ac_check_lib_save_LIBS
22308 echo "$as_me:22308: result: $ac_cv_lib_posix_remove" >&5
22309 echo "${ECHO_T}$ac_cv_lib_posix_remove" >&6
22310 if test "$ac_cv_lib_posix_remove" = yes; then
22311 X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix"
22316 # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
22317 echo "$as_me:22317: checking for shmat" >&5
22318 echo $ECHO_N "checking for shmat... $ECHO_C" >&6
22319 if test "${ac_cv_func_shmat+set}" = set; then
22320 echo $ECHO_N "(cached) $ECHO_C" >&6
22322 cat >"conftest.$ac_ext" <<_ACEOF
22323 #line 22323 "configure"
22324 #include "confdefs.h"
22325 #define shmat autoconf_temporary
22326 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
22333 /* We use char because int might match the return type of a gcc2
22334 builtin and then its argument prototype would still apply. */
22341 /* The GNU C library defines stubs for functions which it implements
22342 to always fail with ENOSYS. Some functions are actually named
22343 something starting with __ and the normal name is an alias. */
22344 #if defined (__stub_shmat) || defined (__stub___shmat)
22345 #error found stub for shmat
22353 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
22354 if { (eval echo "$as_me:22354: \"$ac_link\"") >&5
22355 (eval $ac_link) 2>&5
22357 echo "$as_me:22357: \$? = $ac_status" >&5
22358 (exit "$ac_status"); } &&
22359 { ac_try='test -s "conftest$ac_exeext"'
22360 { (eval echo "$as_me:22360: \"$ac_try\"") >&5
22361 (eval $ac_try) 2>&5
22363 echo "$as_me:22363: \$? = $ac_status" >&5
22364 (exit "$ac_status"); }; }; then
22365 ac_cv_func_shmat=yes
22367 echo "$as_me: failed program was:" >&5
22368 cat "conftest.$ac_ext" >&5
22369 ac_cv_func_shmat=no
22371 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
22373 echo "$as_me:22373: result: $ac_cv_func_shmat" >&5
22374 echo "${ECHO_T}$ac_cv_func_shmat" >&6
22376 if test $ac_cv_func_shmat = no; then
22377 echo "$as_me:22377: checking for shmat in -lipc" >&5
22378 echo $ECHO_N "checking for shmat in -lipc... $ECHO_C" >&6
22379 if test "${ac_cv_lib_ipc_shmat+set}" = set; then
22380 echo $ECHO_N "(cached) $ECHO_C" >&6
22382 ac_check_lib_save_LIBS=$LIBS
22384 cat >"conftest.$ac_ext" <<_ACEOF
22385 #line 22385 "configure"
22386 #include "confdefs.h"
22388 /* Override any gcc2 internal prototype to avoid an error. */
22392 /* We use char because int might match the return type of a gcc2
22393 builtin and then its argument prototype would still apply. */
22403 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
22404 if { (eval echo "$as_me:22404: \"$ac_link\"") >&5
22405 (eval $ac_link) 2>&5
22407 echo "$as_me:22407: \$? = $ac_status" >&5
22408 (exit "$ac_status"); } &&
22409 { ac_try='test -s "conftest$ac_exeext"'
22410 { (eval echo "$as_me:22410: \"$ac_try\"") >&5
22411 (eval $ac_try) 2>&5
22413 echo "$as_me:22413: \$? = $ac_status" >&5
22414 (exit "$ac_status"); }; }; then
22415 ac_cv_lib_ipc_shmat=yes
22417 echo "$as_me: failed program was:" >&5
22418 cat "conftest.$ac_ext" >&5
22419 ac_cv_lib_ipc_shmat=no
22421 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
22422 LIBS=$ac_check_lib_save_LIBS
22424 echo "$as_me:22424: result: $ac_cv_lib_ipc_shmat" >&5
22425 echo "${ECHO_T}$ac_cv_lib_ipc_shmat" >&6
22426 if test "$ac_cv_lib_ipc_shmat" = yes; then
22427 X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc"
22433 # Check for libraries that X11R6 Xt/Xaw programs need.
22434 ac_save_LDFLAGS=$LDFLAGS
22435 test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries"
22436 # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
22437 # check for ICE first), but we must link in the order -lSM -lICE or
22438 # we get undefined symbols. So assume we have SM if we have ICE.
22439 # These have to be linked with before -lX11, unlike the other
22440 # libraries we check for below, so use a different variable.
22441 # John Interrante, Karl Berry
22442 echo "$as_me:22442: checking for IceConnectionNumber in -lICE" >&5
22443 echo $ECHO_N "checking for IceConnectionNumber in -lICE... $ECHO_C" >&6
22444 if test "${ac_cv_lib_ICE_IceConnectionNumber+set}" = set; then
22445 echo $ECHO_N "(cached) $ECHO_C" >&6
22447 ac_check_lib_save_LIBS=$LIBS
22448 LIBS="-lICE $X_EXTRA_LIBS $LIBS"
22449 cat >"conftest.$ac_ext" <<_ACEOF
22450 #line 22450 "configure"
22451 #include "confdefs.h"
22453 /* Override any gcc2 internal prototype to avoid an error. */
22457 /* We use char because int might match the return type of a gcc2
22458 builtin and then its argument prototype would still apply. */
22459 char IceConnectionNumber (void);
22463 IceConnectionNumber ();
22468 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
22469 if { (eval echo "$as_me:22469: \"$ac_link\"") >&5
22470 (eval $ac_link) 2>&5
22472 echo "$as_me:22472: \$? = $ac_status" >&5
22473 (exit "$ac_status"); } &&
22474 { ac_try='test -s "conftest$ac_exeext"'
22475 { (eval echo "$as_me:22475: \"$ac_try\"") >&5
22476 (eval $ac_try) 2>&5
22478 echo "$as_me:22478: \$? = $ac_status" >&5
22479 (exit "$ac_status"); }; }; then
22480 ac_cv_lib_ICE_IceConnectionNumber=yes
22482 echo "$as_me: failed program was:" >&5
22483 cat "conftest.$ac_ext" >&5
22484 ac_cv_lib_ICE_IceConnectionNumber=no
22486 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
22487 LIBS=$ac_check_lib_save_LIBS
22489 echo "$as_me:22489: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5
22490 echo "${ECHO_T}$ac_cv_lib_ICE_IceConnectionNumber" >&6
22491 if test "$ac_cv_lib_ICE_IceConnectionNumber" = yes; then
22492 X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
22495 LDFLAGS=$ac_save_LDFLAGS
22501 if test "$GCC" = yes || test "$GXX" = yes
22504 if test "$GCC" = yes || test "$GXX" = yes
22509 for cf_temp_scan in $CFLAGS
22511 case "x$cf_temp_scan" in
22514 test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
22515 cf_temp_flags="${cf_temp_flags}$cf_temp_scan"
22520 test -n "$EXTRA_CFLAGS" && EXTRA_CFLAGS="$EXTRA_CFLAGS "
22521 EXTRA_CFLAGS="${EXTRA_CFLAGS}$cf_temp_scan"
22526 test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
22527 cf_temp_flags="${cf_temp_flags}$cf_temp_scan"
22532 if test "x$CFLAGS" != "x$cf_temp_flags"
22534 test -n "$verbose" && echo " repairing CFLAGS: $CFLAGS" 1>&6
22536 echo "${as_me:-configure}:22536: testing repairing CFLAGS: $CFLAGS ..." 1>&5
22538 CFLAGS="$cf_temp_flags"
22539 test -n "$verbose" && echo " ... fixed $CFLAGS" 1>&6
22541 echo "${as_me:-configure}:22541: testing ... fixed $CFLAGS ..." 1>&5
22543 test -n "$verbose" && echo " ... extra $EXTRA_CFLAGS" 1>&6
22545 echo "${as_me:-configure}:22545: testing ... extra $EXTRA_CFLAGS ..." 1>&5
22552 if test "$GCC" = yes || test "$GXX" = yes
22557 for cf_temp_scan in $CPPFLAGS
22559 case "x$cf_temp_scan" in
22562 test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
22563 cf_temp_flags="${cf_temp_flags}$cf_temp_scan"
22568 test -n "$EXTRA_CFLAGS" && EXTRA_CFLAGS="$EXTRA_CFLAGS "
22569 EXTRA_CFLAGS="${EXTRA_CFLAGS}$cf_temp_scan"
22574 test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
22575 cf_temp_flags="${cf_temp_flags}$cf_temp_scan"
22580 if test "x$CPPFLAGS" != "x$cf_temp_flags"
22582 test -n "$verbose" && echo " repairing CPPFLAGS: $CPPFLAGS" 1>&6
22584 echo "${as_me:-configure}:22584: testing repairing CPPFLAGS: $CPPFLAGS ..." 1>&5
22586 CPPFLAGS="$cf_temp_flags"
22587 test -n "$verbose" && echo " ... fixed $CPPFLAGS" 1>&6
22589 echo "${as_me:-configure}:22589: testing ... fixed $CPPFLAGS ..." 1>&5
22591 test -n "$verbose" && echo " ... extra $EXTRA_CFLAGS" 1>&6
22593 echo "${as_me:-configure}:22593: testing ... extra $EXTRA_CFLAGS ..." 1>&5
22600 if test "$GCC" = yes || test "$GXX" = yes
22605 for cf_temp_scan in $LDFLAGS
22607 case "x$cf_temp_scan" in
22610 test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
22611 cf_temp_flags="${cf_temp_flags}$cf_temp_scan"
22616 test -n "$EXTRA_CFLAGS" && EXTRA_CFLAGS="$EXTRA_CFLAGS "
22617 EXTRA_CFLAGS="${EXTRA_CFLAGS}$cf_temp_scan"
22622 test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
22623 cf_temp_flags="${cf_temp_flags}$cf_temp_scan"
22628 if test "x$LDFLAGS" != "x$cf_temp_flags"
22630 test -n "$verbose" && echo " repairing LDFLAGS: $LDFLAGS" 1>&6
22632 echo "${as_me:-configure}:22632: testing repairing LDFLAGS: $LDFLAGS ..." 1>&5
22634 LDFLAGS="$cf_temp_flags"
22635 test -n "$verbose" && echo " ... fixed $LDFLAGS" 1>&6
22637 echo "${as_me:-configure}:22637: testing ... fixed $LDFLAGS ..." 1>&5
22639 test -n "$verbose" && echo " ... extra $EXTRA_CFLAGS" 1>&6
22641 echo "${as_me:-configure}:22641: testing ... extra $EXTRA_CFLAGS ..." 1>&5
22648 echo "$as_me:22648: checking if you want to turn on gcc warnings" >&5
22649 echo $ECHO_N "checking if you want to turn on gcc warnings... $ECHO_C" >&6
22651 # Check whether --enable-warnings or --disable-warnings was given.
22652 if test "${enable_warnings+set}" = set; then
22653 enableval="$enable_warnings"
22654 test "$enableval" != yes && enableval=no
22655 if test "$enableval" != "no" ; then
22656 enable_warnings=yes
22665 echo "$as_me:22665: result: $enable_warnings" >&5
22666 echo "${ECHO_T}$enable_warnings" >&6
22667 if test "$enable_warnings" = "yes"
22670 if test "$GCC" = yes || test "$GXX" = yes
22672 cat > conftest.i <<EOF
22674 #define GCC_PRINTF 0
22677 #define GCC_SCANF 0
22679 #ifndef GCC_NORETURN
22680 #define GCC_NORETURN /* nothing */
22683 #define GCC_UNUSED /* nothing */
22686 if test "$GCC" = yes
22688 { echo "$as_me:22688: checking for $CC __attribute__ directives..." >&5
22689 echo "$as_me: checking for $CC __attribute__ directives..." >&6;}
22690 cat > "conftest.$ac_ext" <<EOF
22691 #line 22691 "${as_me:-configure}"
22693 #include "confdefs.h"
22694 #include "conftest.h"
22695 #include "conftest.i"
22697 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
22699 #define GCC_PRINTFLIKE(fmt,var) /*nothing*/
22702 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
22704 #define GCC_SCANFLIKE(fmt,var) /*nothing*/
22706 extern void wow(char *,...) GCC_SCANFLIKE(1,2);
22707 extern GCC_NORETURN void oops(char *,...) GCC_PRINTFLIKE(1,2);
22708 extern GCC_NORETURN void foo(void);
22709 int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { (void)argc; (void)argv; return 0; }
22711 cf_printf_attribute=no
22712 cf_scanf_attribute=no
22713 for cf_attribute in scanf printf unused noreturn
22716 cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
22718 cf_directive="__attribute__(($cf_attribute))"
22719 echo "checking for $CC $cf_directive" 1>&5
22721 case "$cf_attribute" in
22723 cf_printf_attribute=yes
22724 cat >conftest.h <<EOF
22725 #define GCC_$cf_ATTRIBUTE 1
22729 cf_scanf_attribute=yes
22730 cat >conftest.h <<EOF
22731 #define GCC_$cf_ATTRIBUTE 1
22735 cat >conftest.h <<EOF
22736 #define GCC_$cf_ATTRIBUTE $cf_directive
22741 if { (eval echo "$as_me:22741: \"$ac_compile\"") >&5
22742 (eval $ac_compile) 2>&5
22744 echo "$as_me:22744: \$? = $ac_status" >&5
22745 (exit "$ac_status"); }; then
22746 test -n "$verbose" && echo "$as_me:22746: result: ... $cf_attribute" >&5
22747 echo "${ECHO_T}... $cf_attribute" >&6
22748 cat conftest.h >>confdefs.h
22749 case "$cf_attribute" in
22752 cat >>confdefs.h <<EOF
22753 #define GCC_NORETURN $cf_directive
22758 cf_value='/* nothing */'
22759 if test "$cf_printf_attribute" != no ; then
22760 cf_value='__attribute__((format(printf,fmt,var)))'
22762 cat >>confdefs.h <<\EOF
22763 #define GCC_PRINTF 1
22768 cat >>confdefs.h <<EOF
22769 #define GCC_PRINTFLIKE(fmt,var) $cf_value
22774 cf_value='/* nothing */'
22775 if test "$cf_scanf_attribute" != no ; then
22776 cf_value='__attribute__((format(scanf,fmt,var)))'
22778 cat >>confdefs.h <<\EOF
22779 #define GCC_SCANF 1
22784 cat >>confdefs.h <<EOF
22785 #define GCC_SCANFLIKE(fmt,var) $cf_value
22791 cat >>confdefs.h <<EOF
22792 #define GCC_UNUSED $cf_directive
22800 ${FGREP-fgrep} define conftest.i >>confdefs.h
22805 if test "x$have_x" = xyes; then
22807 cf_save_LIBS_CF_CONST_X_STRING="$LIBS"
22808 cf_save_CFLAGS_CF_CONST_X_STRING="$CFLAGS"
22809 cf_save_CPPFLAGS_CF_CONST_X_STRING="$CPPFLAGS"
22810 LIBS="$LIBS ${X_PRE_LIBS} ${X_LIBS} ${X_EXTRA_LIBS}"
22811 for cf_X_CFLAGS in $X_CFLAGS
22813 case "x$cf_X_CFLAGS" in
22815 CPPFLAGS="$CPPFLAGS $cf_X_CFLAGS"
22818 CFLAGS="$CFLAGS $cf_X_CFLAGS"
22823 cat >"conftest.$ac_ext" <<_ACEOF
22824 #line 22824 "configure"
22825 #include "confdefs.h"
22827 #include <stdlib.h>
22828 #include <X11/Intrinsic.h>
22833 String foo = malloc(1); free((void*)foo)
22838 rm -f "conftest.$ac_objext"
22839 if { (eval echo "$as_me:22839: \"$ac_compile\"") >&5
22840 (eval $ac_compile) 2>&5
22842 echo "$as_me:22842: \$? = $ac_status" >&5
22843 (exit "$ac_status"); } &&
22844 { ac_try='test -s "conftest.$ac_objext"'
22845 { (eval echo "$as_me:22845: \"$ac_try\"") >&5
22846 (eval $ac_try) 2>&5
22848 echo "$as_me:22848: \$? = $ac_status" >&5
22849 (exit "$ac_status"); }; }; then
22851 echo "$as_me:22851: checking for X11/Xt const-feature" >&5
22852 echo $ECHO_N "checking for X11/Xt const-feature... $ECHO_C" >&6
22853 if test "${cf_cv_const_x_string+set}" = set; then
22854 echo $ECHO_N "(cached) $ECHO_C" >&6
22857 cat >"conftest.$ac_ext" <<_ACEOF
22858 #line 22858 "configure"
22859 #include "confdefs.h"
22861 #undef _CONST_X_STRING
22862 #define _CONST_X_STRING /* X11R7.8 (perhaps) */
22863 #undef XTSTRINGDEFINES /* X11R5 and later */
22864 #include <stdlib.h>
22865 #include <X11/Intrinsic.h>
22870 String foo = malloc(1); *foo = 0
22875 rm -f "conftest.$ac_objext"
22876 if { (eval echo "$as_me:22876: \"$ac_compile\"") >&5
22877 (eval $ac_compile) 2>&5
22879 echo "$as_me:22879: \$? = $ac_status" >&5
22880 (exit "$ac_status"); } &&
22881 { ac_try='test -s "conftest.$ac_objext"'
22882 { (eval echo "$as_me:22882: \"$ac_try\"") >&5
22883 (eval $ac_try) 2>&5
22885 echo "$as_me:22885: \$? = $ac_status" >&5
22886 (exit "$ac_status"); }; }; then
22888 cf_cv_const_x_string=no
22891 echo "$as_me: failed program was:" >&5
22892 cat "conftest.$ac_ext" >&5
22894 cf_cv_const_x_string=yes
22897 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
22900 echo "$as_me:22900: result: $cf_cv_const_x_string" >&5
22901 echo "${ECHO_T}$cf_cv_const_x_string" >&6
22903 LIBS="$cf_save_LIBS_CF_CONST_X_STRING"
22904 CFLAGS="$cf_save_CFLAGS_CF_CONST_X_STRING"
22905 CPPFLAGS="$cf_save_CPPFLAGS_CF_CONST_X_STRING"
22907 case "$cf_cv_const_x_string" in
22910 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
22911 CPPFLAGS="${CPPFLAGS}-DXTSTRINGDEFINES"
22916 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
22917 CPPFLAGS="${CPPFLAGS}-D_CONST_X_STRING"
22923 echo "$as_me: failed program was:" >&5
22924 cat "conftest.$ac_ext" >&5
22926 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
22928 cat > "conftest.$ac_ext" <<EOF
22929 #line 22929 "${as_me:-configure}"
22930 int main(int argc, char *argv[]) { return (argv[argc-1] == 0) ; }
22932 if test "$INTEL_COMPILER" = yes
22934 # The "-wdXXX" options suppress warnings:
22935 # remark #1419: external declaration in primary source file
22936 # remark #1683: explicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem)
22937 # remark #1684: conversion from pointer to same-sized integral type (potential portability problem)
22938 # remark #193: zero used for undefined preprocessing identifier
22939 # remark #593: variable "curs_sb_left_arrow" was set but never used
22940 # remark #810: conversion from "int" to "Dimension={unsigned short}" may lose significant bits
22941 # remark #869: parameter "tw" was never referenced
22942 # remark #981: operands are evaluated in unspecified order
22943 # warning #279: controlling expression is constant
22945 { echo "$as_me:22945: checking for $CC warning options..." >&5
22946 echo "$as_me: checking for $CC warning options..." >&6;}
22947 cf_save_CFLAGS="$CFLAGS"
22948 EXTRA_CFLAGS="$EXTRA_CFLAGS -Wall"
22960 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
22961 if { (eval echo "$as_me:22961: \"$ac_compile\"") >&5
22962 (eval $ac_compile) 2>&5
22964 echo "$as_me:22964: \$? = $ac_status" >&5
22965 (exit "$ac_status"); }; then
22966 test -n "$verbose" && echo "$as_me:22966: result: ... -$cf_opt" >&5
22967 echo "${ECHO_T}... -$cf_opt" >&6
22968 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
22971 CFLAGS="$cf_save_CFLAGS"
22972 elif test "$GCC" = yes && test "$GCC_VERSION" != "unknown"
22974 { echo "$as_me:22974: checking for $CC warning options..." >&5
22975 echo "$as_me: checking for $CC warning options..." >&6;}
22976 cf_save_CFLAGS="$CFLAGS"
22978 test "$with_ext_const" = yes && cf_warn_CONST="Wwrite-strings"
22979 cf_gcc_warnings="Wignored-qualifiers Wlogical-op Wvarargs"
22980 test "x$CLANG_COMPILER" = xyes && cf_gcc_warnings=
22981 for cf_opt in W Wall \
22982 Wbad-function-cast \
22985 Wdeclaration-after-statement \
22988 Wmissing-declarations \
22989 Wmissing-prototypes \
22993 Wstrict-prototypes \
22994 Wundef Wno-inline $cf_gcc_warnings $cf_warn_CONST Wno-unknown-pragmas
22996 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
22997 if { (eval echo "$as_me:22997: \"$ac_compile\"") >&5
22998 (eval $ac_compile) 2>&5
23000 echo "$as_me:23000: \$? = $ac_status" >&5
23001 (exit "$ac_status"); }; then
23002 test -n "$verbose" && echo "$as_me:23002: result: ... -$cf_opt" >&5
23003 echo "${ECHO_T}... -$cf_opt" >&6
23006 case "$GCC_VERSION" in
23008 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
23010 echo "${as_me:-configure}:23010: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
23016 case "$GCC_VERSION" in
23018 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
23020 echo "${as_me:-configure}:23020: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
23026 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
23029 CFLAGS="$cf_save_CFLAGS"
23037 echo "$as_me:23037: checking if you want to use dmalloc for testing" >&5
23038 echo $ECHO_N "checking if you want to use dmalloc for testing... $ECHO_C" >&6
23040 # Check whether --with-dmalloc or --without-dmalloc was given.
23041 if test "${with_dmalloc+set}" = set; then
23042 withval="$with_dmalloc"
23043 case "x$withval" in
23046 : "${with_cflags:=-g}"
23047 : "${enable_leaks:=no}"
23050 cat >>confdefs.h <<EOF
23051 #define USE_DMALLOC 1
23059 echo "$as_me:23059: result: ${with_dmalloc:-no}" >&5
23060 echo "${ECHO_T}${with_dmalloc:-no}" >&6
23062 case ".$with_cflags" in
23072 cf_new_extra_cppflags=
23074 for cf_add_cflags in -g
23076 case "$cf_fix_cppflags" in
23078 case "$cf_add_cflags" in
23079 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
23080 case "$cf_add_cflags" in
23082 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
23084 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
23085 && test -z "${cf_tst_cflags}" \
23086 && cf_fix_cppflags=yes
23088 if test "$cf_fix_cppflags" = yes ; then
23090 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
23091 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
23094 elif test "${cf_tst_cflags}" = "\"'" ; then
23096 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
23097 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
23103 case "$CPPFLAGS" in
23107 case "$cf_add_cflags" in
23109 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
23111 CPPFLAGS=`echo "$CPPFLAGS" | \
23112 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
23113 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
23118 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
23119 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
23126 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
23127 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
23134 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
23135 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
23137 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
23139 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
23140 && test -z "${cf_tst_cflags}" \
23141 && cf_fix_cppflags=no
23146 if test -n "$cf_new_cflags" ; then
23148 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
23149 CFLAGS="${CFLAGS}$cf_new_cflags"
23153 if test -n "$cf_new_cppflags" ; then
23155 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
23156 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
23160 if test -n "$cf_new_extra_cppflags" ; then
23162 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
23163 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
23172 if test "$with_dmalloc" = yes ; then
23173 echo "$as_me:23173: checking for dmalloc.h" >&5
23174 echo $ECHO_N "checking for dmalloc.h... $ECHO_C" >&6
23175 if test "${ac_cv_header_dmalloc_h+set}" = set; then
23176 echo $ECHO_N "(cached) $ECHO_C" >&6
23178 cat >"conftest.$ac_ext" <<_ACEOF
23179 #line 23179 "configure"
23180 #include "confdefs.h"
23181 #include <dmalloc.h>
23183 if { (eval echo "$as_me:23183: \"$ac_cpp "conftest.$ac_ext"\"") >&5
23184 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
23186 $EGREP -v '^ *\+' conftest.er1 >conftest.err
23188 cat conftest.err >&5
23189 echo "$as_me:23189: \$? = $ac_status" >&5
23190 (exit "$ac_status"); } >/dev/null; then
23191 if test -s conftest.err; then
23192 ac_cpp_err=$ac_c_preproc_warn_flag
23199 if test -z "$ac_cpp_err"; then
23200 ac_cv_header_dmalloc_h=yes
23202 echo "$as_me: failed program was:" >&5
23203 cat "conftest.$ac_ext" >&5
23204 ac_cv_header_dmalloc_h=no
23206 rm -f conftest.err "conftest.$ac_ext"
23208 echo "$as_me:23208: result: $ac_cv_header_dmalloc_h" >&5
23209 echo "${ECHO_T}$ac_cv_header_dmalloc_h" >&6
23210 if test "$ac_cv_header_dmalloc_h" = yes; then
23212 echo "$as_me:23212: checking for dmalloc_debug in -ldmalloc" >&5
23213 echo $ECHO_N "checking for dmalloc_debug in -ldmalloc... $ECHO_C" >&6
23214 if test "${ac_cv_lib_dmalloc_dmalloc_debug+set}" = set; then
23215 echo $ECHO_N "(cached) $ECHO_C" >&6
23217 ac_check_lib_save_LIBS=$LIBS
23218 LIBS="-ldmalloc $LIBS"
23219 cat >"conftest.$ac_ext" <<_ACEOF
23220 #line 23220 "configure"
23221 #include "confdefs.h"
23223 /* Override any gcc2 internal prototype to avoid an error. */
23227 /* We use char because int might match the return type of a gcc2
23228 builtin and then its argument prototype would still apply. */
23229 char dmalloc_debug (void);
23238 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
23239 if { (eval echo "$as_me:23239: \"$ac_link\"") >&5
23240 (eval $ac_link) 2>&5
23242 echo "$as_me:23242: \$? = $ac_status" >&5
23243 (exit "$ac_status"); } &&
23244 { ac_try='test -s "conftest$ac_exeext"'
23245 { (eval echo "$as_me:23245: \"$ac_try\"") >&5
23246 (eval $ac_try) 2>&5
23248 echo "$as_me:23248: \$? = $ac_status" >&5
23249 (exit "$ac_status"); }; }; then
23250 ac_cv_lib_dmalloc_dmalloc_debug=yes
23252 echo "$as_me: failed program was:" >&5
23253 cat "conftest.$ac_ext" >&5
23254 ac_cv_lib_dmalloc_dmalloc_debug=no
23256 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
23257 LIBS=$ac_check_lib_save_LIBS
23259 echo "$as_me:23259: result: $ac_cv_lib_dmalloc_dmalloc_debug" >&5
23260 echo "${ECHO_T}$ac_cv_lib_dmalloc_dmalloc_debug" >&6
23261 if test "$ac_cv_lib_dmalloc_dmalloc_debug" = yes; then
23262 cat >>confdefs.h <<EOF
23263 #define HAVE_LIBDMALLOC 1
23266 LIBS="-ldmalloc $LIBS"
23274 echo "$as_me:23274: checking if you want to use dbmalloc for testing" >&5
23275 echo $ECHO_N "checking if you want to use dbmalloc for testing... $ECHO_C" >&6
23277 # Check whether --with-dbmalloc or --without-dbmalloc was given.
23278 if test "${with_dbmalloc+set}" = set; then
23279 withval="$with_dbmalloc"
23280 case "x$withval" in
23283 : "${with_cflags:=-g}"
23284 : "${enable_leaks:=no}"
23287 cat >>confdefs.h <<EOF
23288 #define USE_DBMALLOC 1
23296 echo "$as_me:23296: result: ${with_dbmalloc:-no}" >&5
23297 echo "${ECHO_T}${with_dbmalloc:-no}" >&6
23299 case ".$with_cflags" in
23309 cf_new_extra_cppflags=
23311 for cf_add_cflags in -g
23313 case "$cf_fix_cppflags" in
23315 case "$cf_add_cflags" in
23316 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
23317 case "$cf_add_cflags" in
23319 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
23321 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
23322 && test -z "${cf_tst_cflags}" \
23323 && cf_fix_cppflags=yes
23325 if test "$cf_fix_cppflags" = yes ; then
23327 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
23328 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
23331 elif test "${cf_tst_cflags}" = "\"'" ; then
23333 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
23334 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
23340 case "$CPPFLAGS" in
23344 case "$cf_add_cflags" in
23346 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
23348 CPPFLAGS=`echo "$CPPFLAGS" | \
23349 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
23350 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
23355 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
23356 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
23363 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
23364 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
23371 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
23372 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
23374 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
23376 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
23377 && test -z "${cf_tst_cflags}" \
23378 && cf_fix_cppflags=no
23383 if test -n "$cf_new_cflags" ; then
23385 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
23386 CFLAGS="${CFLAGS}$cf_new_cflags"
23390 if test -n "$cf_new_cppflags" ; then
23392 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
23393 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
23397 if test -n "$cf_new_extra_cppflags" ; then
23399 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
23400 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
23409 if test "$with_dbmalloc" = yes ; then
23410 echo "$as_me:23410: checking for dbmalloc.h" >&5
23411 echo $ECHO_N "checking for dbmalloc.h... $ECHO_C" >&6
23412 if test "${ac_cv_header_dbmalloc_h+set}" = set; then
23413 echo $ECHO_N "(cached) $ECHO_C" >&6
23415 cat >"conftest.$ac_ext" <<_ACEOF
23416 #line 23416 "configure"
23417 #include "confdefs.h"
23418 #include <dbmalloc.h>
23420 if { (eval echo "$as_me:23420: \"$ac_cpp "conftest.$ac_ext"\"") >&5
23421 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
23423 $EGREP -v '^ *\+' conftest.er1 >conftest.err
23425 cat conftest.err >&5
23426 echo "$as_me:23426: \$? = $ac_status" >&5
23427 (exit "$ac_status"); } >/dev/null; then
23428 if test -s conftest.err; then
23429 ac_cpp_err=$ac_c_preproc_warn_flag
23436 if test -z "$ac_cpp_err"; then
23437 ac_cv_header_dbmalloc_h=yes
23439 echo "$as_me: failed program was:" >&5
23440 cat "conftest.$ac_ext" >&5
23441 ac_cv_header_dbmalloc_h=no
23443 rm -f conftest.err "conftest.$ac_ext"
23445 echo "$as_me:23445: result: $ac_cv_header_dbmalloc_h" >&5
23446 echo "${ECHO_T}$ac_cv_header_dbmalloc_h" >&6
23447 if test "$ac_cv_header_dbmalloc_h" = yes; then
23449 echo "$as_me:23449: checking for debug_malloc in -ldbmalloc" >&5
23450 echo $ECHO_N "checking for debug_malloc in -ldbmalloc... $ECHO_C" >&6
23451 if test "${ac_cv_lib_dbmalloc_debug_malloc+set}" = set; then
23452 echo $ECHO_N "(cached) $ECHO_C" >&6
23454 ac_check_lib_save_LIBS=$LIBS
23455 LIBS="-ldbmalloc $LIBS"
23456 cat >"conftest.$ac_ext" <<_ACEOF
23457 #line 23457 "configure"
23458 #include "confdefs.h"
23460 /* Override any gcc2 internal prototype to avoid an error. */
23464 /* We use char because int might match the return type of a gcc2
23465 builtin and then its argument prototype would still apply. */
23466 char debug_malloc (void);
23475 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
23476 if { (eval echo "$as_me:23476: \"$ac_link\"") >&5
23477 (eval $ac_link) 2>&5
23479 echo "$as_me:23479: \$? = $ac_status" >&5
23480 (exit "$ac_status"); } &&
23481 { ac_try='test -s "conftest$ac_exeext"'
23482 { (eval echo "$as_me:23482: \"$ac_try\"") >&5
23483 (eval $ac_try) 2>&5
23485 echo "$as_me:23485: \$? = $ac_status" >&5
23486 (exit "$ac_status"); }; }; then
23487 ac_cv_lib_dbmalloc_debug_malloc=yes
23489 echo "$as_me: failed program was:" >&5
23490 cat "conftest.$ac_ext" >&5
23491 ac_cv_lib_dbmalloc_debug_malloc=no
23493 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
23494 LIBS=$ac_check_lib_save_LIBS
23496 echo "$as_me:23496: result: $ac_cv_lib_dbmalloc_debug_malloc" >&5
23497 echo "${ECHO_T}$ac_cv_lib_dbmalloc_debug_malloc" >&6
23498 if test "$ac_cv_lib_dbmalloc_debug_malloc" = yes; then
23499 cat >>confdefs.h <<EOF
23500 #define HAVE_LIBDBMALLOC 1
23503 LIBS="-ldbmalloc $LIBS"
23511 echo "$as_me:23511: checking if you want to use valgrind for testing" >&5
23512 echo $ECHO_N "checking if you want to use valgrind for testing... $ECHO_C" >&6
23514 # Check whether --with-valgrind or --without-valgrind was given.
23515 if test "${with_valgrind+set}" = set; then
23516 withval="$with_valgrind"
23517 case "x$withval" in
23520 : "${with_cflags:=-g}"
23521 : "${enable_leaks:=no}"
23524 cat >>confdefs.h <<EOF
23525 #define USE_VALGRIND 1
23533 echo "$as_me:23533: result: ${with_valgrind:-no}" >&5
23534 echo "${ECHO_T}${with_valgrind:-no}" >&6
23536 case ".$with_cflags" in
23546 cf_new_extra_cppflags=
23548 for cf_add_cflags in -g
23550 case "$cf_fix_cppflags" in
23552 case "$cf_add_cflags" in
23553 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
23554 case "$cf_add_cflags" in
23556 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
23558 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
23559 && test -z "${cf_tst_cflags}" \
23560 && cf_fix_cppflags=yes
23562 if test "$cf_fix_cppflags" = yes ; then
23564 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
23565 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
23568 elif test "${cf_tst_cflags}" = "\"'" ; then
23570 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
23571 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
23577 case "$CPPFLAGS" in
23581 case "$cf_add_cflags" in
23583 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
23585 CPPFLAGS=`echo "$CPPFLAGS" | \
23586 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
23587 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
23592 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
23593 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
23600 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
23601 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
23608 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
23609 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
23611 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
23613 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
23614 && test -z "${cf_tst_cflags}" \
23615 && cf_fix_cppflags=no
23620 if test -n "$cf_new_cflags" ; then
23622 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
23623 CFLAGS="${CFLAGS}$cf_new_cflags"
23627 if test -n "$cf_new_cppflags" ; then
23629 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
23630 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
23634 if test -n "$cf_new_extra_cppflags" ; then
23636 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
23637 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
23646 echo "$as_me:23646: checking if you want to perform memory-leak testing" >&5
23647 echo $ECHO_N "checking if you want to perform memory-leak testing... $ECHO_C" >&6
23649 # Check whether --enable-leaks or --disable-leaks was given.
23650 if test "${enable_leaks+set}" = set; then
23651 enableval="$enable_leaks"
23652 enable_leaks=$enableval
23656 if test "x$enable_leaks" = xno; then with_no_leaks=yes; else with_no_leaks=no; fi
23657 echo "$as_me:23657: result: $with_no_leaks" >&5
23658 echo "${ECHO_T}$with_no_leaks" >&6
23660 if test "$enable_leaks" = no ; then
23662 cat >>confdefs.h <<\EOF
23666 cat >>confdefs.h <<\EOF
23667 #define YY_NO_LEAKS 1
23673 if test "x$cf_cv_enable_rpath" != xno
23675 echo "$as_me:23675: checking for an rpath option" >&5
23676 echo $ECHO_N "checking for an rpath option... $ECHO_C" >&6
23677 case "$cf_cv_system_name" in
23679 if test "$GCC" = yes; then
23680 LD_RPATH_OPT="-Wl,-rpath,"
23682 LD_RPATH_OPT="-rpath "
23685 (linux*|gnu*|k*bsd*-gnu|freebsd*)
23686 LD_RPATH_OPT="-Wl,-rpath,"
23688 (openbsd[2-9].*|mirbsd*)
23689 LD_RPATH_OPT="-Wl,-rpath,"
23692 LD_RPATH_OPT="-rpath "
23695 LD_RPATH_OPT="-Wl,-rpath,"
23698 LD_RPATH_OPT="-rpath "
23706 echo "$as_me:23706: result: $LD_RPATH_OPT" >&5
23707 echo "${ECHO_T}$LD_RPATH_OPT" >&6
23709 case "x$LD_RPATH_OPT" in
23711 echo "$as_me:23711: checking if we need a space after rpath option" >&5
23712 echo $ECHO_N "checking if we need a space after rpath option... $ECHO_C" >&6
23713 cf_save_LIBS="$LIBS"
23715 cf_add_libs="$LIBS"
23718 for cf_add_1lib in ${LD_RPATH_OPT}$libdir; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
23719 # filter duplicates
23720 for cf_add_1lib in $cf_add_0lib; do
23721 for cf_add_2lib in $cf_add_libs; do
23722 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
23727 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
23729 LIBS="$cf_add_libs"
23731 cat >"conftest.$ac_ext" <<_ACEOF
23732 #line 23732 "configure"
23733 #include "confdefs.h"
23743 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
23744 if { (eval echo "$as_me:23744: \"$ac_link\"") >&5
23745 (eval $ac_link) 2>&5
23747 echo "$as_me:23747: \$? = $ac_status" >&5
23748 (exit "$ac_status"); } &&
23749 { ac_try='test -s "conftest$ac_exeext"'
23750 { (eval echo "$as_me:23750: \"$ac_try\"") >&5
23751 (eval $ac_try) 2>&5
23753 echo "$as_me:23753: \$? = $ac_status" >&5
23754 (exit "$ac_status"); }; }; then
23757 echo "$as_me: failed program was:" >&5
23758 cat "conftest.$ac_ext" >&5
23761 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
23762 LIBS="$cf_save_LIBS"
23763 echo "$as_me:23763: result: $cf_rpath_space" >&5
23764 echo "${ECHO_T}$cf_rpath_space" >&6
23765 test "$cf_rpath_space" = yes && LD_RPATH_OPT="$LD_RPATH_OPT "
23770 echo "$as_me:23770: checking if rpath-hack should be disabled" >&5
23771 echo $ECHO_N "checking if rpath-hack should be disabled... $ECHO_C" >&6
23773 # Check whether --enable-rpath-hack or --disable-rpath-hack was given.
23774 if test "${enable_rpath_hack+set}" = set; then
23775 enableval="$enable_rpath_hack"
23776 test "$enableval" != no && enableval=yes
23777 if test "$enableval" != "yes" ; then
23778 enable_rpath_hack=no
23780 enable_rpath_hack=yes
23784 enable_rpath_hack=yes
23787 if test "x$enable_rpath_hack" = xno; then cf_disable_rpath_hack=yes; else cf_disable_rpath_hack=no; fi
23788 echo "$as_me:23788: result: $cf_disable_rpath_hack" >&5
23789 echo "${ECHO_T}$cf_disable_rpath_hack" >&6
23791 if test "$enable_rpath_hack" = yes ; then
23793 echo "$as_me:23793: checking for updated LDFLAGS" >&5
23794 echo $ECHO_N "checking for updated LDFLAGS... $ECHO_C" >&6
23795 if test -n "$LD_RPATH_OPT" ; then
23796 echo "$as_me:23796: result: maybe" >&5
23797 echo "${ECHO_T}maybe" >&6
23801 # Extract the first word of "$ac_prog", so it can be a program name with args.
23802 set dummy $ac_prog; ac_word=$2
23803 echo "$as_me:23803: checking for $ac_word" >&5
23804 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
23805 if test "${ac_cv_prog_cf_ldd_prog+set}" = set; then
23806 echo $ECHO_N "(cached) $ECHO_C" >&6
23808 if test -n "$cf_ldd_prog"; then
23809 ac_cv_prog_cf_ldd_prog="$cf_ldd_prog" # Let the user override the test.
23811 ac_save_IFS=$IFS; IFS=$ac_path_separator
23813 for ac_dir in $ac_dummy; do
23815 test -z "$ac_dir" && ac_dir=.
23816 $as_executable_p "$ac_dir/$ac_word" || continue
23817 ac_cv_prog_cf_ldd_prog="$ac_prog"
23818 echo "$as_me:23818: found $ac_dir/$ac_word" >&5
23824 cf_ldd_prog=$ac_cv_prog_cf_ldd_prog
23825 if test -n "$cf_ldd_prog"; then
23826 echo "$as_me:23826: result: $cf_ldd_prog" >&5
23827 echo "${ECHO_T}$cf_ldd_prog" >&6
23829 echo "$as_me:23829: result: no" >&5
23830 echo "${ECHO_T}no" >&6
23833 test -n "$cf_ldd_prog" && break
23835 test -n "$cf_ldd_prog" || cf_ldd_prog="no"
23837 cf_rpath_list="/usr/lib /lib"
23838 if test "$cf_ldd_prog" != no
23842 cat >"conftest.$ac_ext" <<_ACEOF
23843 #line 23843 "configure"
23844 #include "confdefs.h"
23854 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
23855 if { (eval echo "$as_me:23855: \"$ac_link\"") >&5
23856 (eval $ac_link) 2>&5
23858 echo "$as_me:23858: \$? = $ac_status" >&5
23859 (exit "$ac_status"); } &&
23860 { ac_try='test -s "conftest$ac_exeext"'
23861 { (eval echo "$as_me:23861: \"$ac_try\"") >&5
23862 (eval $ac_try) 2>&5
23864 echo "$as_me:23864: \$? = $ac_status" >&5
23865 (exit "$ac_status"); }; }; then
23866 cf_rpath_oops=`"$cf_ldd_prog" "conftest$ac_exeext" | ${FGREP-fgrep} ' not found' | sed -e 's% =>.*$%%' |sort | uniq`
23867 cf_rpath_list=`"$cf_ldd_prog" "conftest$ac_exeext" | ${FGREP-fgrep} / | sed -e 's%^.*[ ]/%/%' -e 's%/[^/][^/]*$%%' |sort | uniq`
23869 echo "$as_me: failed program was:" >&5
23870 cat "conftest.$ac_ext" >&5
23872 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
23874 # If we passed the link-test, but get a "not found" on a given library,
23875 # this could be due to inept reconfiguration of gcc to make it only
23876 # partly honor /usr/local/lib (or whatever). Sometimes this behavior
23877 # is intentional, e.g., installing gcc in /usr/bin and suppressing the
23878 # /usr/local libraries.
23879 if test -n "$cf_rpath_oops"
23881 for cf_rpath_src in $cf_rpath_oops
23883 for cf_rpath_dir in \
23888 if test -f "$cf_rpath_dir/lib/$cf_rpath_src"
23890 test -n "$verbose" && echo " ...adding -L$cf_rpath_dir/lib to LDFLAGS for $cf_rpath_src" 1>&6
23892 echo "${as_me:-configure}:23892: testing ...adding -L$cf_rpath_dir/lib to LDFLAGS for $cf_rpath_src ..." 1>&5
23894 LDFLAGS="$LDFLAGS -L$cf_rpath_dir/lib"
23902 test -n "$verbose" && echo " ...checking EXTRA_LDFLAGS $EXTRA_LDFLAGS" 1>&6
23904 echo "${as_me:-configure}:23904: testing ...checking EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5
23906 test -n "$verbose" && echo " ...checking LDFLAGS $LDFLAGS" 1>&6
23908 echo "${as_me:-configure}:23908: testing ...checking LDFLAGS $LDFLAGS ..." 1>&5
23911 for cf_rpath_src in $LDFLAGS
23913 case "$cf_rpath_src" in
23916 # check if this refers to a directory which we will ignore
23918 if test -n "$cf_rpath_list"
23920 for cf_rpath_item in $cf_rpath_list
23922 if test "x$cf_rpath_src" = "x-L$cf_rpath_item"
23930 if test "$cf_rpath_skip" = no
23932 # transform the option
23933 if test "$LD_RPATH_OPT" = "-R " ; then
23934 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%-R %"`
23936 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%$LD_RPATH_OPT%"`
23939 # if we have not already added this, add it now
23940 cf_rpath_tst=`echo "$EXTRA_LDFLAGS" | sed -e "s%$cf_rpath_tmp %%"`
23941 if test "x$cf_rpath_tst" = "x$EXTRA_LDFLAGS"
23943 test -n "$verbose" && echo " ...Filter $cf_rpath_src ->$cf_rpath_tmp" 1>&6
23945 echo "${as_me:-configure}:23945: testing ...Filter $cf_rpath_src ->$cf_rpath_tmp ..." 1>&5
23947 EXTRA_LDFLAGS="$cf_rpath_tmp $EXTRA_LDFLAGS"
23952 cf_rpath_dst="$cf_rpath_dst $cf_rpath_src"
23954 LDFLAGS=$cf_rpath_dst
23956 test -n "$verbose" && echo " ...checked LDFLAGS $LDFLAGS" 1>&6
23958 echo "${as_me:-configure}:23958: testing ...checked LDFLAGS $LDFLAGS ..." 1>&5
23960 test -n "$verbose" && echo " ...checking LIBS $LIBS" 1>&6
23962 echo "${as_me:-configure}:23962: testing ...checking LIBS $LIBS ..." 1>&5
23965 for cf_rpath_src in $LIBS
23967 case "$cf_rpath_src" in
23970 # check if this refers to a directory which we will ignore
23972 if test -n "$cf_rpath_list"
23974 for cf_rpath_item in $cf_rpath_list
23976 if test "x$cf_rpath_src" = "x-L$cf_rpath_item"
23984 if test "$cf_rpath_skip" = no
23986 # transform the option
23987 if test "$LD_RPATH_OPT" = "-R " ; then
23988 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%-R %"`
23990 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%$LD_RPATH_OPT%"`
23993 # if we have not already added this, add it now
23994 cf_rpath_tst=`echo "$EXTRA_LDFLAGS" | sed -e "s%$cf_rpath_tmp %%"`
23995 if test "x$cf_rpath_tst" = "x$EXTRA_LDFLAGS"
23997 test -n "$verbose" && echo " ...Filter $cf_rpath_src ->$cf_rpath_tmp" 1>&6
23999 echo "${as_me:-configure}:23999: testing ...Filter $cf_rpath_src ->$cf_rpath_tmp ..." 1>&5
24001 EXTRA_LDFLAGS="$cf_rpath_tmp $EXTRA_LDFLAGS"
24006 cf_rpath_dst="$cf_rpath_dst $cf_rpath_src"
24010 test -n "$verbose" && echo " ...checked LIBS $LIBS" 1>&6
24012 echo "${as_me:-configure}:24012: testing ...checked LIBS $LIBS ..." 1>&5
24014 test -n "$verbose" && echo " ...checked EXTRA_LDFLAGS $EXTRA_LDFLAGS" 1>&6
24016 echo "${as_me:-configure}:24016: testing ...checked EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5
24019 echo "$as_me:24019: result: no" >&5
24020 echo "${ECHO_T}no" >&6
24028 ac_config_files="$ac_config_files Makefile"
24029 ac_config_commands="$ac_config_commands default"
24030 cat >confcache <<\_ACEOF
24031 # This file is a shell script that caches the results of configure
24032 # tests run on this system so they can be shared between configure
24033 # scripts and configure runs, see configure's option --config-cache.
24034 # It is not useful on other systems. If it contains results you don't
24035 # want to keep, you may remove or edit it.
24037 # config.status only pays attention to the cache file if you give it
24038 # the --recheck option to rerun configure.
24040 # `ac_cv_env_foo' variables (set or unset) will be overridden when
24041 # loading this file, other *unset* `ac_cv_foo' will be assigned the
24042 # following values.
24046 # The following way of writing the cache mishandles newlines in values,
24047 # but we know of no workaround that is simple, portable, and efficient.
24048 # So, don't put newlines in cache variables' values.
24049 # Ultrix sh set writes to stderr and can't be redirected directly,
24050 # and sets the high bit in the cache file unless we assign to the vars.
24053 case `(ac_space=' '; set | grep ac_space) 2>&1` in
24055 # `set' does not quote correctly, so add quotes (double-quote
24056 # substitution turns \\\\ into \\, and sed turns \\ into \).
24059 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
24062 # `set' quotes correctly as required by POSIX, so do not add quotes.
24064 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
24071 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
24073 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
24075 if cmp -s $cache_file confcache; then :; else
24076 if test -w $cache_file; then
24077 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
24078 cat confcache >$cache_file
24080 echo "not updating unwritable cache $cache_file"
24085 test "x$prefix" = xNONE && prefix=$ac_default_prefix
24086 # Let make expand exec_prefix.
24087 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
24089 # VPATH may cause trouble with some makes, so we remove $(srcdir),
24090 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
24091 # trailing colons and then remove the whole line if VPATH becomes empty
24092 # (actually we leave an empty line to preserve line numbers).
24093 if test "x$srcdir" = x.; then
24094 ac_vpsub='/^[ ]*VPATH[ ]*=/{
24095 s/:*\$(srcdir):*/:/;
24096 s/:*\${srcdir}:*/:/;
24098 s/^\([^=]*=[ ]*\):*/\1/;
24104 DEFS=-DHAVE_CONFIG_H
24106 : "${CONFIG_STATUS=./config.status}"
24107 ac_clean_files_save=$ac_clean_files
24108 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
24109 { echo "$as_me:24109: creating $CONFIG_STATUS" >&5
24110 echo "$as_me: creating $CONFIG_STATUS" >&6;}
24111 cat >"$CONFIG_STATUS" <<_ACEOF
24113 # Generated automatically by configure.
24114 # Run this file to recreate the current configuration.
24115 # Compiler output produced by configure, useful for debugging
24116 # configure, is in config.log if it exists.
24118 me=\`echo "\$0" | sed -e 's,.*\\/,,'\`
24121 SHELL=\${CONFIG_SHELL-$SHELL}
24122 ac_cs_invocation="\$0 \$@"
24124 CLICOLOR_FORCE= GREP_OPTIONS=
24125 unset CLICOLOR_FORCE GREP_OPTIONS
24128 cat >>"$CONFIG_STATUS" <<\_ACEOF
24129 # Be Bourne compatible
24130 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
24133 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
24137 # Name of the executable.
24138 as_me=`echo "$0" |sed 's,.*[\\/],,'`
24140 if expr a : '\(a\)' >/dev/null 2>&1; then
24146 rm -f conf$$ conf$$.exe conf$$.file
24148 if ln -s conf$$.file conf$$ 2>/dev/null; then
24149 # We could just check for DJGPP; but this test a) works b) is more generic
24150 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
24151 if test -f conf$$.exe; then
24152 # Don't use ln at all; we don't have any links
24157 elif ln conf$$.file conf$$ 2>/dev/null; then
24162 rm -f conf$$ conf$$.exe conf$$.file
24164 as_executable_p="test -f"
24166 # Support unset when possible.
24167 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
24174 $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
24175 $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
24176 $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
24177 $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
24178 $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
24179 $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
24180 $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
24181 $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
24184 # We need space, tab and new line, in precisely that order.
24190 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
24196 # Files that config.status was made for.
24197 if test -n "$ac_config_files"; then
24198 echo "config_files=\"$ac_config_files\"" >>"$CONFIG_STATUS"
24201 if test -n "$ac_config_headers"; then
24202 echo "config_headers=\"$ac_config_headers\"" >>"$CONFIG_STATUS"
24205 if test -n "$ac_config_links"; then
24206 echo "config_links=\"$ac_config_links\"" >>"$CONFIG_STATUS"
24209 if test -n "$ac_config_commands"; then
24210 echo "config_commands=\"$ac_config_commands\"" >>"$CONFIG_STATUS"
24213 cat >>"$CONFIG_STATUS" <<\EOF
24216 \`$as_me' instantiates files from templates according to the
24217 current configuration.
24219 Usage: $0 [OPTIONS] [FILE]...
24221 -h, --help print this help, then exit
24222 -V, --version print version number, then exit
24223 -d, --debug don't remove temporary files
24224 --recheck update $as_me by reconfiguring in the same conditions
24225 --file=FILE[:TEMPLATE]
24226 instantiate the configuration file FILE
24227 --header=FILE[:TEMPLATE]
24228 instantiate the configuration header FILE
24230 Configuration files:
24233 Configuration headers:
24236 Configuration commands:
24239 Report bugs to <dickey@invisible-island.net>."
24242 cat >>"$CONFIG_STATUS" <<EOF
24245 configured by $0, generated by GNU Autoconf 2.52.20231210,
24246 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
24248 Copyright 2003-2022,2023 Thomas E. Dickey
24249 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
24250 Free Software Foundation, Inc.
24251 This config.status script is free software; the Free Software Foundation
24252 gives unlimited permission to copy, distribute and modify it."
24257 cat >>"$CONFIG_STATUS" <<\EOF
24258 # If no file are specified by the user, then we need to provide default
24259 # value. By we need to know if files were specified by the user.
24265 ac_option=`expr "x$1" : 'x\([^=]*\)='`
24266 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
24268 set dummy "$ac_option" "$ac_optarg" ${1+"$@"}
24272 *) # This is not an option, so the user has probably given explicit
24274 ac_need_defaults=false;;
24278 # Handling of the options.
24280 cat >>"$CONFIG_STATUS" <<EOF
24281 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
24282 echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion"
24283 exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;;
24285 cat >>"$CONFIG_STATUS" <<\EOF
24286 --version | --vers* | -V )
24287 echo "$ac_cs_version"; exit 0 ;;
24289 # Conflict between --help and --header
24290 { { echo "$as_me:24290: error: ambiguous option: $1
24291 Try \`$0 --help' for more information." >&5
24292 echo "$as_me: error: ambiguous option: $1
24293 Try \`$0 --help' for more information." >&2;}
24294 { (exit 1); exit 1; }; };;
24295 --help | --hel | -h )
24296 echo "$ac_cs_usage"; exit 0 ;;
24297 --debug | --d* | -d )
24299 --file | --fil | --fi | --f )
24301 CONFIG_FILES="$CONFIG_FILES $1"
24302 ac_need_defaults=false;;
24303 --header | --heade | --head | --hea )
24305 CONFIG_HEADERS="$CONFIG_HEADERS $1"
24306 ac_need_defaults=false;;
24308 # This is an error.
24309 -*) { { echo "$as_me:24309: error: unrecognized option: $1
24310 Try \`$0 --help' for more information." >&5
24311 echo "$as_me: error: unrecognized option: $1
24312 Try \`$0 --help' for more information." >&2;}
24313 { (exit 1); exit 1; }; } ;;
24315 *) ac_config_targets="$ac_config_targets $1" ;;
24324 ## ----------------------- ##
24325 ## Running config.status. ##
24326 ## ----------------------- ##
24328 This file was extended by $as_me 2.52.20231210, executed with
24329 CONFIG_FILES = $CONFIG_FILES
24330 CONFIG_HEADERS = $CONFIG_HEADERS
24331 CONFIG_LINKS = $CONFIG_LINKS
24332 CONFIG_COMMANDS = $CONFIG_COMMANDS
24333 > "$ac_cs_invocation"
24334 on `(hostname || uname -n) 2>/dev/null | sed 1q`
24339 cat >>"$CONFIG_STATUS" <<EOF
24341 # INIT-COMMANDS section.
24351 cat >>"$CONFIG_STATUS" <<\EOF
24352 for ac_config_target in $ac_config_targets
24354 case "$ac_config_target" in
24355 # Handling of arguments.
24356 "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
24357 "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
24358 "ncurses_cfg.h" ) CONFIG_HEADERS="$CONFIG_HEADERS ncurses_cfg.h:ncurses_tst.hin" ;;
24359 *) { { echo "$as_me:24359: error: invalid argument: $ac_config_target" >&5
24360 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
24361 { (exit 1); exit 1; }; };;
24365 # If the user did not use the arguments to specify the items to instantiate,
24366 # then the envvar interface is used. Set only those that are not.
24367 # We use the long form for the default assignment because of an extremely
24368 # bizarre bug on SunOS 4.1.3.
24369 if "$ac_need_defaults"; then
24370 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
24371 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
24372 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
24375 # Create a temporary directory, and hook for its removal unless debugging.
24378 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
24379 trap '{ (exit 1); exit 1; }' 1 2 13 15
24382 # Create a (secure) tmp directory for tmp files.
24385 tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` &&
24386 test -n "$tmp" && test -d "$tmp"
24389 tmp=$TMPDIR/cs$$-$RANDOM
24390 (umask 077 && mkdir "$tmp")
24393 echo "$me: cannot create a temporary directory in $TMPDIR" >&2
24394 { (exit 1); exit 1; }
24399 cat >>"$CONFIG_STATUS" <<EOF
24402 # CONFIG_FILES section.
24405 # No need to generate the scripts if there are no CONFIG_FILES.
24406 # This happens for instance when ./config.status config.h
24407 if test -n "\$CONFIG_FILES"; then
24408 # Protect against being on the right side of a sed subst in config.status.
24409 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
24410 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >"\$tmp"/subs.sed <<\\CEOF
24411 s,@SHELL@,$SHELL,;t t
24412 s,@exec_prefix@,$exec_prefix,;t t
24413 s,@prefix@,$prefix,;t t
24414 s,@program_transform_name@,$program_transform_name,;t t
24415 s,@bindir@,$bindir,;t t
24416 s,@sbindir@,$sbindir,;t t
24417 s,@libexecdir@,$libexecdir,;t t
24418 s,@datarootdir@,$datarootdir,;t t
24419 s,@datadir@,$datadir,;t t
24420 s,@sysconfdir@,$sysconfdir,;t t
24421 s,@sharedstatedir@,$sharedstatedir,;t t
24422 s,@localstatedir@,$localstatedir,;t t
24423 s,@runstatedir@,$runstatedir,;t t
24424 s,@libdir@,$libdir,;t t
24425 s,@includedir@,$includedir,;t t
24426 s,@oldincludedir@,$oldincludedir,;t t
24427 s,@infodir@,$infodir,;t t
24428 s,@mandir@,$mandir,;t t
24429 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
24430 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
24431 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
24432 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
24433 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
24434 s,@build_alias@,$build_alias,;t t
24435 s,@host_alias@,$host_alias,;t t
24436 s,@target_alias@,$target_alias,;t t
24437 s,@ECHO_C@,$ECHO_C,;t t
24438 s,@ECHO_N@,$ECHO_N,;t t
24439 s,@ECHO_T@,$ECHO_T,;t t
24440 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
24441 s,@DEFS@,$DEFS,;t t
24442 s,@LIBS@,$LIBS,;t t
24443 s,@build@,$build,;t t
24444 s,@build_cpu@,$build_cpu,;t t
24445 s,@build_vendor@,$build_vendor,;t t
24446 s,@build_os@,$build_os,;t t
24447 s,@host@,$host,;t t
24448 s,@host_cpu@,$host_cpu,;t t
24449 s,@host_vendor@,$host_vendor,;t t
24450 s,@host_os@,$host_os,;t t
24451 s,@SET_MAKE@,$SET_MAKE,;t t
24453 s,@CFLAGS@,$CFLAGS,;t t
24454 s,@LDFLAGS@,$LDFLAGS,;t t
24455 s,@CPPFLAGS@,$CPPFLAGS,;t t
24456 s,@ac_ct_CC@,$ac_ct_CC,;t t
24457 s,@EXEEXT@,$EXEEXT,;t t
24458 s,@OBJEXT@,$OBJEXT,;t t
24459 s,@EXTRA_CPPFLAGS@,$EXTRA_CPPFLAGS,;t t
24461 s,@GREP@,$GREP,;t t
24462 s,@EGREP@,$EGREP,;t t
24464 s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
24465 s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
24466 s,@INSTALL_DATA@,$INSTALL_DATA,;t t
24467 s,@INSTALL_OPT_S@,$INSTALL_OPT_S,;t t
24468 s,@INSTALL_OPT_O@,$INSTALL_OPT_O,;t t
24469 s,@LINT@,$LINT,;t t
24470 s,@LINT_OPTS@,$LINT_OPTS,;t t
24471 s,@LINT_LIBS@,$LINT_LIBS,;t t
24472 s,@MAKE_NO_PHONY@,$MAKE_NO_PHONY,;t t
24473 s,@MAKE_PHONY@,$MAKE_PHONY,;t t
24474 s,@CTAGS@,$CTAGS,;t t
24475 s,@ETAGS@,$ETAGS,;t t
24476 s,@MAKE_LOWER_TAGS@,$MAKE_LOWER_TAGS,;t t
24477 s,@MAKE_UPPER_TAGS@,$MAKE_UPPER_TAGS,;t t
24478 s,@MATH_LIB@,$MATH_LIB,;t t
24479 s,@top_builddir@,$top_builddir,;t t
24480 s,@CC_G_OPT@,$CC_G_OPT,;t t
24481 s,@CC_SHARED_OPTS@,$CC_SHARED_OPTS,;t t
24482 s,@DFT_DEP_SUFFIX@,$DFT_DEP_SUFFIX,;t t
24483 s,@DFT_OBJ_SUBDIR@,$DFT_OBJ_SUBDIR,;t t
24484 s,@DFT_UPR_MODEL@,$DFT_UPR_MODEL,;t t
24486 s,@LDFLAGS_SHARED@,$LDFLAGS_SHARED,;t t
24487 s,@LDFLAGS_STATIC@,$LDFLAGS_STATIC,;t t
24488 s,@LD_MODEL@,$LD_MODEL,;t t
24489 s,@LD_SHARED_OPTS@,$LD_SHARED_OPTS,;t t
24490 s,@LIBTOOL@,$LIBTOOL,;t t
24491 s,@LIBTOOL_OPTS@,$LIBTOOL_OPTS,;t t
24492 s,@LIB_CLEAN@,$LIB_CLEAN,;t t
24493 s,@LIB_COMPILE@,$LIB_COMPILE,;t t
24494 s,@LIB_LINK@,$LIB_LINK,;t t
24495 s,@LINK_TESTS@,$LINK_TESTS,;t t
24496 s,@LOCAL_LDFLAGS@,$LOCAL_LDFLAGS,;t t
24497 s,@PACKAGE@,$PACKAGE,;t t
24498 s,@PTHREAD@,$PTHREAD,;t t
24499 s,@TEST_ARGS@,$TEST_ARGS,;t t
24500 s,@TEST_DEPS@,$TEST_DEPS,;t t
24501 s,@TEST_LIBS@,$TEST_LIBS,;t t
24502 s,@TINFO_LDFLAGS@,$TINFO_LDFLAGS,;t t
24503 s,@TINFO_LIBS@,$TINFO_LIBS,;t t
24504 s,@cf_cv_abi_version@,$cf_cv_abi_version,;t t
24505 s,@cf_cv_rel_version@,$cf_cv_rel_version,;t t
24506 s,@includesubdir@,$includesubdir,;t t
24507 s,@FGREP@,$FGREP,;t t
24508 s,@HAVE_STDNORETURN_H@,$HAVE_STDNORETURN_H,;t t
24509 s,@STDC_NORETURN@,$STDC_NORETURN,;t t
24510 s,@PKG_CONFIG@,$PKG_CONFIG,;t t
24511 s,@ac_pt_PKG_CONFIG@,$ac_pt_PKG_CONFIG,;t t
24512 s,@ECHO_LT@,$ECHO_LT,;t t
24513 s,@ECHO_LD@,$ECHO_LD,;t t
24514 s,@RULE_CC@,$RULE_CC,;t t
24515 s,@SHOW_CC@,$SHOW_CC,;t t
24516 s,@ECHO_CC@,$ECHO_CC,;t t
24517 s,@NCURSES_WRAP_PREFIX@,$NCURSES_WRAP_PREFIX,;t t
24518 s,@NCURSES_CONFIG@,$NCURSES_CONFIG,;t t
24519 s,@ac_ct_NCURSES_CONFIG@,$ac_ct_NCURSES_CONFIG,;t t
24520 s,@X_CFLAGS@,$X_CFLAGS,;t t
24521 s,@X_PRE_LIBS@,$X_PRE_LIBS,;t t
24522 s,@X_LIBS@,$X_LIBS,;t t
24523 s,@X_EXTRA_LIBS@,$X_EXTRA_LIBS,;t t
24524 s,@XCURSES_CONFIG@,$XCURSES_CONFIG,;t t
24525 s,@ac_ct_XCURSES_CONFIG@,$ac_ct_XCURSES_CONFIG,;t t
24526 s,@cf_cv_screen@,$cf_cv_screen,;t t
24527 s,@RGB_PATH@,$RGB_PATH,;t t
24528 s,@no_x11_rgb@,$no_x11_rgb,;t t
24529 s,@FORM_NAME@,$FORM_NAME,;t t
24530 s,@MENU_NAME@,$MENU_NAME,;t t
24531 s,@PANEL_NAME@,$PANEL_NAME,;t t
24532 s,@EXTRA_CFLAGS@,$EXTRA_CFLAGS,;t t
24533 s,@cf_ldd_prog@,$cf_ldd_prog,;t t
24534 s,@EXTRA_LDFLAGS@,$EXTRA_LDFLAGS,;t t
24539 cat >>"$CONFIG_STATUS" <<\EOF
24540 # Split the substitutions into bite-sized pieces for seds with
24541 # small command number limits, like on Digital OSF/1 and HP-UX.
24542 ac_max_sed_lines=48
24543 ac_sed_frag=1 # Number of current file.
24544 ac_beg=1 # First line for current file.
24545 ac_end=$ac_max_sed_lines # Line after last line for current file.
24548 while "$ac_more_lines"; do
24549 if test "$ac_beg" -gt 1; then
24550 sed "1,${ac_beg}d; ${ac_end}q" "$tmp"/subs.sed >"$tmp"/subs.frag
24552 sed "${ac_end}q" "$tmp"/subs.sed >"$tmp"/subs.frag
24554 if test ! -s "$tmp"/subs.frag; then
24555 ac_more_lines=false
24557 # The purpose of the label and of the branching condition is to
24558 # speed up the sed processing (if there are no `@' at all, there
24559 # is no need to browse any of the substitutions).
24560 # These are the two extra sed commands mentioned above.
24562 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat "$tmp"/subs.frag) >"$tmp"/subs-$ac_sed_frag.sed
24563 # It is possible to make a multiline substitution using escaped newlines.
24564 # Ensure that we do not split the substitution between script fragments.
24566 ac_END=`expr "$ac_end" + "$ac_max_sed_lines"`
24567 sed "1,${ac_BEG}d; ${ac_END}p; q" "$tmp"/subs.sed >"$tmp"/subs.next
24568 if test -s "$tmp"/subs.next; then
24569 grep '^s,@[^@,][^@,]*@,.*\\$' "$tmp"/subs.next >"$tmp"/subs.edit
24570 if test ! -s "$tmp"/subs.edit; then
24571 grep "^s,@[^@,][^@,]*@,.*,;t t$" "$tmp"/subs.next >"$tmp"/subs.edit
24572 if test ! -s "$tmp"/subs.edit; then
24573 if test "$ac_beg" -gt 1; then
24574 ac_end=`expr "$ac_end" - 1`
24581 if test -z "$ac_sed_cmds"; then
24582 ac_sed_cmds="sed -f \"$tmp\"/subs-$ac_sed_frag.sed"
24584 ac_sed_cmds="$ac_sed_cmds | sed -f \"$tmp\"/subs-$ac_sed_frag.sed"
24586 ac_sed_frag=`expr "$ac_sed_frag" + 1`
24588 ac_end=`expr "$ac_end" + "$ac_max_sed_lines"`
24591 if test -z "$ac_sed_cmds"; then
24594 fi # test -n "$CONFIG_FILES"
24597 cat >>"$CONFIG_STATUS" <<\EOF
24598 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
24599 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
24601 - | *:- | *:-:* ) # input from stdin
24603 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
24604 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
24605 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
24606 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
24607 * ) ac_file_in=$ac_file.in ;;
24610 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
24611 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
24612 X"$ac_file" : 'X\(//\)[^/]' \| \
24613 X"$ac_file" : 'X\(//\)$' \| \
24614 X"$ac_file" : 'X\(/\)' \| \
24615 . : '\(.\)' 2>/dev/null ||
24617 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
24618 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
24619 /^X\(\/\/\)$/{ s//\1/; q; }
24620 /^X\(\/\).*/{ s//\1/; q; }
24622 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
24623 { case "$ac_dir" in
24624 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
24628 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
24629 case $as_mkdir_dir in
24630 # Skip DOS drivespec
24631 ?:) as_incr_dir=$as_mkdir_dir ;;
24633 as_incr_dir=$as_incr_dir/$as_mkdir_dir
24634 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
24639 ac_dir_suffix="/`echo "$ac_dir"|sed 's,^\./,,'`"
24640 # A "../" for each directory in $ac_dir_suffix.
24641 ac_dots=`echo "$ac_dir_suffix" | sed 's,/[^/]*,../,g'`
24643 ac_dir_suffix= ac_dots=
24648 if test -z "$ac_dots"; then
24651 ac_top_srcdir=`echo "$ac_dots" | sed 's,/$,,'`
24653 [\\/]* | ?:[\\/]* )
24654 ac_srcdir="$srcdir$ac_dir_suffix";
24655 ac_top_srcdir="$srcdir" ;;
24656 *) # Relative path.
24657 ac_srcdir="$ac_dots$srcdir$ac_dir_suffix"
24658 ac_top_srcdir="$ac_dots$srcdir" ;;
24662 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
24663 *) ac_INSTALL=$ac_dots$INSTALL ;;
24666 if test x"$ac_file" != x-; then
24667 { echo "$as_me:24667: creating $ac_file" >&5
24668 echo "$as_me: creating $ac_file" >&6;}
24671 # Let's still pretend it is `configure' which instantiates (i.e., don't
24672 # use $as_me), people would be surprised to read:
24673 # /* config.h. Generated automatically by config.status. */
24674 configure_input="Generated automatically from `echo $ac_file_in |
24675 sed 's,.*/,,'` by configure."
24677 # First look for the input files in the build tree, otherwise in the
24679 ac_file_inputs=`IFS=:
24680 for f in $ac_file_in; do
24682 -) echo "$tmp"/stdin ;;
24684 # Absolute (can't be DOS-style, as IFS=:)
24685 test -f "$f" || { { echo "$as_me:24685: error: cannot find input file: $f" >&5
24686 echo "$as_me: error: cannot find input file: $f" >&2;}
24687 { (exit 1); exit 1; }; }
24690 if test -f "$f"; then
24693 elif test -f "$srcdir/$f"; then
24698 { { echo "$as_me:24698: error: cannot find input file: $f" >&5
24699 echo "$as_me: error: cannot find input file: $f" >&2;}
24700 { (exit 1); exit 1; }; }
24703 done` || { (exit 1); exit 1; }
24705 cat >>"$CONFIG_STATUS" <<\EOF
24706 ac_warn_datarootdir=no
24707 if test x"$ac_file" != x-; then
24708 for ac_item in $ac_file_inputs
24710 ac_seen=`grep '@\(datadir\|mandir\|infodir\)@' "$ac_item"`
24711 if test -n "$ac_seen"; then
24712 ac_used=`grep '@datarootdir@' "$ac_item"`
24713 if test -z "$ac_used"; then
24714 { echo "$as_me:24714: WARNING: datarootdir was used implicitly but not set:
24716 echo "$as_me: WARNING: datarootdir was used implicitly but not set:
24718 ac_warn_datarootdir=yes
24721 ac_seen=`grep '${datarootdir}' "$ac_item"`
24722 if test -n "$ac_seen"; then
24723 { echo "$as_me:24723: WARNING: datarootdir was used explicitly but not set:
24725 echo "$as_me: WARNING: datarootdir was used explicitly but not set:
24727 ac_warn_datarootdir=yes
24732 if test "x$ac_warn_datarootdir" = xyes; then
24733 ac_sed_cmds="$ac_sed_cmds | sed -e 's,@datarootdir@,\${prefix}/share,g' -e 's,\${datarootdir},\${prefix}/share,g'"
24737 cat >>"$CONFIG_STATUS" <<EOF
24741 cat >>"$CONFIG_STATUS" <<\EOF
24743 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
24744 s,@configure_input@,$configure_input,;t t
24745 s,@srcdir@,$ac_srcdir,;t t
24746 s,@top_srcdir@,$ac_top_srcdir,;t t
24747 s,@INSTALL@,$ac_INSTALL,;t t
24748 " $ac_file_inputs | (eval "$ac_sed_cmds") >"$tmp"/out
24751 test -n "${FGREP}" || FGREP="grep -F"
24752 test -n "${EGREP}" || EGREP="grep -E"
24753 cat >>"$CONFIG_STATUS" <<EOF
24754 test -n "\${FGREP}" || FGREP="$FGREP"
24755 test -n "\${EGREP}" || EGREP="$EGREP"
24757 cat >>"$CONFIG_STATUS" <<\EOF
24758 if test x"$ac_file" != x-; then
24759 cp "$tmp/out" "$ac_file"
24761 for ac_name in prefix exec_prefix datarootdir
24763 ac_seen=`$FGREP -n '${'$ac_name'[:=].*}' "$ac_file"`
24764 if test -n "$ac_seen"; then
24765 ac_init=`$EGREP '[ ]*'$ac_name'[ ]*=' "$ac_file"`
24766 if test -z "$ac_init"; then
24767 ac_seen=`echo "$ac_seen" |sed -e 's,^,'"$ac_file"':,'`
24768 { echo "$as_me:24768: WARNING: Variable $ac_name is used but was not set:
24770 echo "$as_me: WARNING: Variable $ac_name is used but was not set:
24775 $EGREP -n '@[a-z_][a-z_0-9]+@' "$ac_file" >"$tmp"/out
24776 $EGREP -n '@[A-Z_][A-Z_0-9]+@' "$ac_file" >>"$tmp"/out
24777 if test -s "$tmp"/out; then
24778 ac_seen=`sed -e 's,^,'"$ac_file"':,' < "$tmp"/out`
24779 { echo "$as_me:24779: WARNING: Some variables may not be substituted:
24781 echo "$as_me: WARNING: Some variables may not be substituted:
24791 cat >>"$CONFIG_STATUS" <<\EOF
24794 # CONFIG_HEADER section.
24797 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
24798 # NAME is the cpp macro being defined and VALUE is the value it is being given.
24800 # ac_d sets the value in "#define NAME VALUE" lines.
24801 ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
24802 ac_dB='[ ].*$,\1#\2'
24805 # ac_i turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
24806 ac_iA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
24807 ac_iB='\([ ]\),\1#\2define\3'
24810 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
24811 ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
24812 ac_uB='$,\1#\2define\3'
24816 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
24817 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
24819 - | *:- | *:-:* ) # input from stdin
24821 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
24822 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
24823 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
24824 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
24825 * ) ac_file_in=$ac_file.in ;;
24828 test x"$ac_file" != x- && { echo "$as_me:24828: creating $ac_file" >&5
24829 echo "$as_me: creating $ac_file" >&6;}
24831 # First look for the input files in the build tree, otherwise in the
24833 ac_file_inputs=`IFS=:
24834 for f in $ac_file_in; do
24836 -) echo "$tmp"/stdin ;;
24838 # Absolute (can't be DOS-style, as IFS=:)
24839 test -f "$f" || { { echo "$as_me:24839: error: cannot find input file: $f" >&5
24840 echo "$as_me: error: cannot find input file: $f" >&2;}
24841 { (exit 1); exit 1; }; }
24844 if test -f "$f"; then
24847 elif test -f "$srcdir/$f"; then
24852 { { echo "$as_me:24852: error: cannot find input file: $f" >&5
24853 echo "$as_me: error: cannot find input file: $f" >&2;}
24854 { (exit 1); exit 1; }; }
24857 done` || { (exit 1); exit 1; }
24858 # Remove the trailing spaces.
24859 sed 's/[ ]*$//' $ac_file_inputs >"$tmp"/in
24863 # Transform confdefs.h into a list of #define's. We won't use it as a sed
24864 # script, but as data to insert where we see @DEFS@. We expect AC_SAVE_DEFS to
24865 # be either 'cat' or 'sort'.
24866 cat confdefs.h | uniq >conftest.vals
24868 # Break up conftest.vals because some shells have a limit on
24869 # the size of here documents, and old seds have small limits too.
24871 rm -f conftest.tail
24872 echo ' rm -f conftest.frag' >> "$CONFIG_STATUS"
24873 while grep . conftest.vals >/dev/null
24875 # Write chunks of a limited-size here document to conftest.frag.
24876 echo ' cat >> conftest.frag <<CEOF' >> "$CONFIG_STATUS"
24877 sed "${ac_max_here_lines}q" conftest.vals | sed -e 's/#ifdef.*/#if 0/' >> "$CONFIG_STATUS"
24878 echo 'CEOF' >> "$CONFIG_STATUS"
24879 sed "1,${ac_max_here_lines}d" conftest.vals > conftest.tail
24880 rm -f conftest.vals
24881 mv conftest.tail conftest.vals
24883 rm -f conftest.vals
24885 # Run sed to substitute the contents of conftest.frag into $tmp/in at the
24887 echo ' cat >> conftest.edit <<CEOF
24888 /@DEFS@/r conftest.frag
24891 sed -f conftest.edit "$tmp"/in > "$tmp"/out
24893 mv "$tmp"/out "$tmp"/in
24894 rm -f conftest.edit conftest.frag
24895 ' >> "$CONFIG_STATUS"
24897 cat >>"$CONFIG_STATUS" <<\EOF
24898 # Let's still pretend it is `configure' which instantiates (i.e., don't
24899 # use $as_me), people would be surprised to read:
24900 # /* config.h. Generated automatically by config.status. */
24901 if test x"$ac_file" = x-; then
24902 echo "/* Generated automatically by configure. */" >"$tmp"/config.h
24904 echo "/* $ac_file. Generated automatically by configure. */" >"$tmp"/config.h
24906 cat "$tmp"/in >>"$tmp"/config.h
24908 if test x"$ac_file" != x-; then
24909 if cmp -s "$ac_file" "$tmp/config.h" 2>/dev/null; then
24910 { echo "$as_me:24910: $ac_file is unchanged" >&5
24911 echo "$as_me: $ac_file is unchanged" >&6;}
24913 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
24914 X"$ac_file" : 'X\(//\)[^/]' \| \
24915 X"$ac_file" : 'X\(//\)$' \| \
24916 X"$ac_file" : 'X\(/\)' \| \
24917 . : '\(.\)' 2>/dev/null ||
24919 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
24920 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
24921 /^X\(\/\/\)$/{ s//\1/; q; }
24922 /^X\(\/\).*/{ s//\1/; q; }
24924 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
24925 { case "$ac_dir" in
24926 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
24930 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
24931 case $as_mkdir_dir in
24932 # Skip DOS drivespec
24933 ?:) as_incr_dir=$as_mkdir_dir ;;
24935 as_incr_dir=$as_incr_dir/$as_mkdir_dir
24936 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
24943 mv "$tmp/config.h" "$ac_file"
24946 cat "$tmp"/config.h
24947 rm -f "$tmp"/config.h
24951 cat >>"$CONFIG_STATUS" <<\EOF
24953 # CONFIG_COMMANDS section.
24955 for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
24956 ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
24957 ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
24964 if test ! -d "$srcdir/$cf_dir" ; then
24966 elif test -f "$srcdir/$cf_dir/programs" ; then
24967 $AWK -f $srcdir/mk-test.awk INSTALL=yes ECHO_LINK="$ECHO_LD" "$srcdir/$cf_dir/programs" >>$cf_dir/Makefile
24971 cat >>Makefile <<TEST_EOF
24973 # These rules are generated so we do not rely on suffix rules, which do not
24974 # work consistently for different make-programs (the '\$(MODEL)/' confuses
24975 # some, and the '\$x' confuses others).
24978 LIST=`sed -e 's/[ ].*//' -e '/^[#@]/d' $srcdir/modules`
24981 cat >>Makefile <<TEST_EOF
24983 \$(MODEL)/$N.o : \$(srcdir)/$N.c \\
24984 \$(srcdir)/test.priv.h \\
24987 $ECHO_CC\$(CC) -c \$(CFLAGS_DEFAULT) -DMODULE_NAME="$N" \$(srcdir)/$N.c
24991 if test -f ../config.guess && test -f ../config.sub
24993 cat >>Makefile <<TEST_EOF
24995 # if we used CF_INHERIT for getting these files, we can remove them
24997 rm -f config.guess config.sub
25005 cat >>"$CONFIG_STATUS" <<\EOF
25007 { (exit 0); exit 0; }
25009 chmod +x "$CONFIG_STATUS"
25010 ac_clean_files=$ac_clean_files_save
25012 # configure is writing to config.log, and then calls config.status.
25013 # config.status does its own redirection, appending to config.log.
25014 # Unfortunately, on DOS this fails, as config.log is still kept open
25015 # by configure, so config.status won't be able to write to it; its
25016 # output is simply discarded. So we exec the FD to /dev/null,
25017 # effectively closing config.log, so it can be properly (re)opened and
25018 # appended to by config.status. When coming back to configure, we
25019 # need to make the FD available again.
25020 if test "$no_create" != yes; then
25023 $SHELL "$CONFIG_STATUS" || ac_cs_success=false
25025 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
25026 # would make configure fail if this is the last instruction.
25027 "$ac_cs_success" || { (exit 1); exit 1; }