2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by Autoconf 2.52.20170501.
5 # Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
6 # Free Software Foundation, Inc.
7 # This configure script is free software; the Free Software Foundation
8 # gives unlimited permission to copy, distribute and modify it.
10 # Avoid depending upon Character Ranges.
11 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
12 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
13 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
14 as_cr_digits='0123456789'
15 as_cr_alnum=$as_cr_Letters$as_cr_digits
17 # Sed expression to map a string onto a valid variable name.
18 as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
20 # Sed expression to map a string onto a valid CPP name.
21 as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
23 # Be Bourne compatible
24 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
27 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
31 # Name of the executable.
32 as_me=`echo "$0" |sed 's,.*[\\/],,'`
34 if expr a : '\(a\)' >/dev/null 2>&1; then
40 rm -f conf$$ conf$$.exe conf$$.file
42 if ln -s conf$$.file conf$$ 2>/dev/null; then
43 # We could just check for DJGPP; but this test a) works b) is more generic
44 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
45 if test -f conf$$.exe; then
46 # Don't use ln at all; we don't have any links
51 elif ln conf$$.file conf$$ 2>/dev/null; then
56 rm -f conf$$ conf$$.exe conf$$.file
58 as_executable_p="test -f"
60 # Support unset when possible.
61 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
68 $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
69 $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
70 $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
71 $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
72 $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
73 $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
74 $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
75 $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
78 # We need space, tab and new line, in precisely that order.
84 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
87 # hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
88 # so uname gets run too.
89 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
96 ac_default_prefix=/usr/local
100 SHELL=${CONFIG_SHELL-/bin/sh}
102 # Maximum number of lines to put in a shell here document.
103 # This variable seems obsolete. It should probably be removed, and
104 # only ac_max_sed_lines should be used.
105 : ${ac_max_here_lines=38}
107 ac_unique_file="ncurses.c"
109 # Initialize some variables set by options.
111 ac_init_version=false
112 # The variables have the same names as the options, with
113 # dashes changed to underlines.
121 program_transform_name=s,x,x,
129 # Installation directory options.
130 # These are left unexpanded so users can "make install exec_prefix=/foo"
131 # and all the variables that are supposed to be based on exec_prefix
132 # by default will actually change.
133 # Use braces instead of parens because sh, perl, etc. also accept them.
134 bindir='${exec_prefix}/bin'
135 sbindir='${exec_prefix}/sbin'
136 libexecdir='${exec_prefix}/libexec'
137 datarootdir='${prefix}/share'
138 datadir='${datarootdir}'
139 sysconfdir='${prefix}/etc'
140 sharedstatedir='${prefix}/com'
141 localstatedir='${prefix}/var'
142 libdir='${exec_prefix}/lib'
143 includedir='${prefix}/include'
144 oldincludedir='/usr/include'
145 infodir='${datarootdir}/info'
146 mandir='${datarootdir}/man'
148 # Identity of this package.
158 # If the previous option needs an argument, assign it.
159 if test -n "$ac_prev"; then
160 eval "$ac_prev=\$ac_option"
165 ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
167 # Accept the important Cygnus configure options, so we can diagnose typos.
171 -bindir | --bindir | --bindi | --bind | --bin | --bi)
173 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
176 -build | --build | --buil | --bui | --bu)
177 ac_prev=build_alias ;;
178 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
179 build_alias=$ac_optarg ;;
181 -cache-file | --cache-file | --cache-fil | --cache-fi \
182 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
183 ac_prev=cache_file ;;
184 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
185 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
186 cache_file=$ac_optarg ;;
189 cache_file=config.cache ;;
191 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
193 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
195 datadir=$ac_optarg ;;
197 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
198 | --dataroo | --dataro | --datar)
199 ac_prev=datarootdir ;;
200 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
201 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
202 datarootdir=$ac_optarg ;;
204 -disable-* | --disable-*)
205 ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
206 # Reject names that are not valid shell variable names.
207 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
208 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
209 { (exit 1); exit 1; }; }
210 ac_feature=`echo $ac_feature | sed 's/-/_/g'`
211 eval "enable_$ac_feature=no" ;;
213 -enable-* | --enable-*)
214 ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
215 # Reject names that are not valid shell variable names.
216 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
217 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
218 { (exit 1); exit 1; }; }
219 ac_feature=`echo $ac_feature | sed 's/-/_/g'`
221 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
224 eval "enable_$ac_feature='$ac_optarg'" ;;
226 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
227 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
228 | --exec | --exe | --ex)
229 ac_prev=exec_prefix ;;
230 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
231 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
232 | --exec=* | --exe=* | --ex=*)
233 exec_prefix=$ac_optarg ;;
235 -gas | --gas | --ga | --g)
236 # Obsolete; use --with-gas.
239 -help | --help | --hel | --he | -h)
241 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
242 ac_init_help=recursive ;;
243 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
244 ac_init_help=short ;;
246 -host | --host | --hos | --ho)
247 ac_prev=host_alias ;;
248 -host=* | --host=* | --hos=* | --ho=*)
249 host_alias=$ac_optarg ;;
251 -includedir | --includedir | --includedi | --included | --include \
252 | --includ | --inclu | --incl | --inc)
253 ac_prev=includedir ;;
254 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
255 | --includ=* | --inclu=* | --incl=* | --inc=*)
256 includedir=$ac_optarg ;;
258 -infodir | --infodir | --infodi | --infod | --info | --inf)
260 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
261 infodir=$ac_optarg ;;
263 -libdir | --libdir | --libdi | --libd)
265 -libdir=* | --libdir=* | --libdi=* | --libd=*)
268 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
269 | --libexe | --libex | --libe)
270 ac_prev=libexecdir ;;
271 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
272 | --libexe=* | --libex=* | --libe=*)
273 libexecdir=$ac_optarg ;;
275 -localstatedir | --localstatedir | --localstatedi | --localstated \
276 | --localstate | --localstat | --localsta | --localst \
277 | --locals | --local | --loca | --loc | --lo)
278 ac_prev=localstatedir ;;
279 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
280 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
281 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
282 localstatedir=$ac_optarg ;;
284 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
286 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
290 # Obsolete; use --without-fp.
293 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
297 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
298 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
301 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
302 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
303 | --oldin | --oldi | --old | --ol | --o)
304 ac_prev=oldincludedir ;;
305 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
306 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
307 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
308 oldincludedir=$ac_optarg ;;
310 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
312 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
315 -program-prefix | --program-prefix | --program-prefi | --program-pref \
316 | --program-pre | --program-pr | --program-p)
317 ac_prev=program_prefix ;;
318 -program-prefix=* | --program-prefix=* | --program-prefi=* \
319 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
320 program_prefix=$ac_optarg ;;
322 -program-suffix | --program-suffix | --program-suffi | --program-suff \
323 | --program-suf | --program-su | --program-s)
324 ac_prev=program_suffix ;;
325 -program-suffix=* | --program-suffix=* | --program-suffi=* \
326 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
327 program_suffix=$ac_optarg ;;
329 -program-transform-name | --program-transform-name \
330 | --program-transform-nam | --program-transform-na \
331 | --program-transform-n | --program-transform- \
332 | --program-transform | --program-transfor \
333 | --program-transfo | --program-transf \
334 | --program-trans | --program-tran \
335 | --progr-tra | --program-tr | --program-t)
336 ac_prev=program_transform_name ;;
337 -program-transform-name=* | --program-transform-name=* \
338 | --program-transform-nam=* | --program-transform-na=* \
339 | --program-transform-n=* | --program-transform-=* \
340 | --program-transform=* | --program-transfor=* \
341 | --program-transfo=* | --program-transf=* \
342 | --program-trans=* | --program-tran=* \
343 | --progr-tra=* | --program-tr=* | --program-t=*)
344 program_transform_name=$ac_optarg ;;
346 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
347 | -silent | --silent | --silen | --sile | --sil)
350 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
352 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
354 sbindir=$ac_optarg ;;
356 -sharedstatedir | --sharedstatedir | --sharedstatedi \
357 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
358 | --sharedst | --shareds | --shared | --share | --shar \
360 ac_prev=sharedstatedir ;;
361 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
362 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
363 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
365 sharedstatedir=$ac_optarg ;;
367 -site | --site | --sit)
369 -site=* | --site=* | --sit=*)
372 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
374 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
377 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
378 | --syscon | --sysco | --sysc | --sys | --sy)
379 ac_prev=sysconfdir ;;
380 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
381 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
382 sysconfdir=$ac_optarg ;;
384 -target | --target | --targe | --targ | --tar | --ta | --t)
385 ac_prev=target_alias ;;
386 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
387 target_alias=$ac_optarg ;;
389 -v | -verbose | --verbose | --verbos | --verbo | --verb)
392 -version | --version | --versio | --versi | --vers | -V)
396 ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
397 # Reject names that are not valid shell variable names.
398 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
399 { echo "$as_me: error: invalid package name: $ac_package" >&2
400 { (exit 1); exit 1; }; }
401 ac_package=`echo $ac_package| sed 's/-/_/g'`
403 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
406 eval "with_$ac_package='$ac_optarg'" ;;
408 -without-* | --without-*)
409 ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
410 # Reject names that are not valid shell variable names.
411 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
412 { echo "$as_me: error: invalid package name: $ac_package" >&2
413 { (exit 1); exit 1; }; }
414 ac_package=`echo $ac_package | sed 's/-/_/g'`
415 eval "with_$ac_package=no" ;;
418 # Obsolete; use --with-x.
421 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
422 | --x-incl | --x-inc | --x-in | --x-i)
423 ac_prev=x_includes ;;
424 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
425 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
426 x_includes=$ac_optarg ;;
428 -x-libraries | --x-libraries | --x-librarie | --x-librari \
429 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
430 ac_prev=x_libraries ;;
431 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
432 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
433 x_libraries=$ac_optarg ;;
435 -*) { echo "$as_me: error: unrecognized option: $ac_option
436 Try \`$0 --help' for more information." >&2
437 { (exit 1); exit 1; }; }
441 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
442 # Reject names that are not valid shell variable names.
443 expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
444 { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
445 { (exit 1); exit 1; }; }
446 ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
447 eval "$ac_envvar='$ac_optarg'"
451 # FIXME: should be removed in autoconf 3.0.
452 echo "$as_me: WARNING: you should use --build, --host, --target" >&2
453 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
454 echo "$as_me: WARNING: invalid host type: $ac_option" >&2
455 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
461 if test -n "$ac_prev"; then
462 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
463 { echo "$as_me: error: missing argument to $ac_option" >&2
464 { (exit 1); exit 1; }; }
467 # Be sure to have absolute paths.
468 for ac_var in exec_prefix prefix
470 eval ac_val=$`echo $ac_var`
472 [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
473 *) { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
474 { (exit 1); exit 1; }; };;
478 # Be sure to have absolute paths.
479 for ac_var in bindir sbindir libexecdir datarootdir datadir sysconfdir sharedstatedir \
480 localstatedir libdir includedir oldincludedir infodir mandir
482 eval ac_val=$`echo $ac_var`
484 [\\/$]* | ?:[\\/]* ) ;;
485 *) { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
486 { (exit 1); exit 1; }; };;
490 # There might be people who depend on the old broken behavior: `$host'
491 # used to hold the argument of --host etc.
496 # FIXME: should be removed in autoconf 3.0.
497 if test "x$host_alias" != x; then
498 if test "x$build_alias" = x; then
499 cross_compiling=maybe
500 echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
501 If a cross compiler is detected then cross compile mode will be used." >&2
502 elif test "x$build_alias" != "x$host_alias"; then
508 test -n "$host_alias" && ac_tool_prefix=$host_alias-
510 test "$silent" = yes && exec 6>/dev/null
512 # Find the source files, if location was not specified.
513 if test -z "$srcdir"; then
514 ac_srcdir_defaulted=yes
515 # Try the directory containing this script, then its parent.
517 ac_confdir=`echo "$ac_prog" | sed 's%[\\/][^\\/][^\\/]*$%%'`
518 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
520 if test ! -r $srcdir/$ac_unique_file; then
524 ac_srcdir_defaulted=no
526 if test ! -r $srcdir/$ac_unique_file; then
527 if test "$ac_srcdir_defaulted" = yes; then
528 { echo "$as_me: error: cannot find sources in $ac_confdir or .." >&2
529 { (exit 1); exit 1; }; }
531 { echo "$as_me: error: cannot find sources in $srcdir" >&2
532 { (exit 1); exit 1; }; }
535 srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
536 ac_env_build_alias_set=${build_alias+set}
537 ac_env_build_alias_value=$build_alias
538 ac_cv_env_build_alias_set=${build_alias+set}
539 ac_cv_env_build_alias_value=$build_alias
540 ac_env_host_alias_set=${host_alias+set}
541 ac_env_host_alias_value=$host_alias
542 ac_cv_env_host_alias_set=${host_alias+set}
543 ac_cv_env_host_alias_value=$host_alias
544 ac_env_target_alias_set=${target_alias+set}
545 ac_env_target_alias_value=$target_alias
546 ac_cv_env_target_alias_set=${target_alias+set}
547 ac_cv_env_target_alias_value=$target_alias
548 ac_env_CC_set=${CC+set}
550 ac_cv_env_CC_set=${CC+set}
551 ac_cv_env_CC_value=$CC
552 ac_env_CFLAGS_set=${CFLAGS+set}
553 ac_env_CFLAGS_value=$CFLAGS
554 ac_cv_env_CFLAGS_set=${CFLAGS+set}
555 ac_cv_env_CFLAGS_value=$CFLAGS
556 ac_env_LDFLAGS_set=${LDFLAGS+set}
557 ac_env_LDFLAGS_value=$LDFLAGS
558 ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
559 ac_cv_env_LDFLAGS_value=$LDFLAGS
560 ac_env_CPPFLAGS_set=${CPPFLAGS+set}
561 ac_env_CPPFLAGS_value=$CPPFLAGS
562 ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
563 ac_cv_env_CPPFLAGS_value=$CPPFLAGS
564 ac_env_CPP_set=${CPP+set}
565 ac_env_CPP_value=$CPP
566 ac_cv_env_CPP_set=${CPP+set}
567 ac_cv_env_CPP_value=$CPP
570 # Report the --help message.
572 if test "$ac_init_help" = "long"; then
573 # Omit some internal or obsolete options to make the list less imposing.
574 # This message is too long to be a string in the A/UX 3.1 sh.
576 \`configure' configures this package to adapt to many kinds of systems.
578 Usage: $0 [OPTION]... [VAR=VALUE]...
580 To assign environment variables (e.g., CC, CFLAGS...), specify them as
581 VAR=VALUE. See below for descriptions of some of the useful variables.
583 Defaults for the options are specified in brackets.
586 -h, --help display this help and exit
587 --help=short display options specific to this package
588 --help=recursive display the short help of all the included packages
589 -V, --version display version information and exit
590 -q, --quiet, --silent do not print \`checking...' messages
591 --cache-file=FILE cache test results in FILE [disabled]
592 -C, --config-cache alias for \`--cache-file=config.cache'
593 -n, --no-create do not create output files
594 --srcdir=DIR find the sources in DIR [configure dir or \`..']
599 Installation directories:
600 --prefix=PREFIX install architecture-independent files in PREFIX
602 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
605 By default, \`make install' will install all the files in
606 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
607 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
608 for instance \`--prefix=\$HOME'.
610 For better control, use the options below.
612 Fine tuning of the installation directories:
613 --bindir=DIR user executables [EPREFIX/bin]
614 --sbindir=DIR system admin executables [EPREFIX/sbin]
615 --libexecdir=DIR program executables [EPREFIX/libexec]
616 --datarootdir=DIR read-only architecture-independent data [PREFIX/share]
617 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
618 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
619 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
620 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
621 --libdir=DIR object code libraries [EPREFIX/lib]
622 --includedir=DIR C header files [PREFIX/include]
623 --oldincludedir=DIR C header files for non-gcc [/usr/include]
624 --infodir=DIR info documentation [DATAROOTDIR/info]
625 --mandir=DIR man documentation [DATAROOTDIR/man]
631 --program-prefix=PREFIX prepend PREFIX to installed program names
632 --program-suffix=SUFFIX append SUFFIX to installed program names
633 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
636 --x-includes=DIR X include files are in DIR
637 --x-libraries=DIR X library files are in DIR
640 --build=BUILD configure for building on BUILD [guessed]
641 --host=HOST build programs to run on HOST [BUILD]
645 if test -n "$ac_init_help"; then
650 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
651 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
654 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
655 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
657 --enable-string-hacks work around bogus compiler/loader warnings
659 --with-pkg-config{=path} enable/disable use of pkg-config
660 --disable-echo do not display "compiling" commands
661 Curses Version-dependent Options:
662 --with-ncurses-wrap-prefix naming-prefix for ncurses wrapped-variables
663 --disable-widec disable checks for wide-character functions
664 --with-curses-dir=DIR directory in which (n)curses is installed
665 --with-screen=XXX use specified curses-libraries
666 --with-ncursesw use wide ncurses-libraries
667 --with-ncurses use ncurses-libraries
668 --with-pdcurses compile/link with pdcurses X11 library
669 --with-curses-colr compile/link with HPUX 10.x color-curses
670 --with-curses-5lib compile/link with SunOS 5lib curses
671 --with-Xaw3d link with Xaw 3d library
672 --with-Xaw3dxft link with Xaw 3d xft library
673 --with-neXtaw link with neXT Athena library
674 --with-XawPlus link with Athena-Plus library
675 --with-x use the X Window System
676 --with-x11-rgb=FILE file containing X11 rgb information (EPREFIX/lib/X11/rgb.txt)
677 --disable-panel disable checks for panel functions
678 --disable-menu disable checks for menu functions
679 --disable-form disable checks for form functions
680 Testing/development Options:
681 --enable-warnings test: turn on gcc compiler warnings
682 --with-dmalloc test: use Gray Watson's dmalloc library
683 --with-dbmalloc test: use Conor Cahill's dbmalloc library
684 --with-valgrind test: use valgrind
685 --disable-leaks test: free permanent memory, analyze leaks
686 --disable-rpath-hack don't add rpath options for additional libraries
688 Some influential environment variables:
689 CC C compiler command
690 CFLAGS C compiler flags
691 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
692 nonstandard directory <lib dir>
693 CPPFLAGS C/C++ preprocessor flags, e.g. -I<include dir> if you have
694 headers in a nonstandard directory <include dir>
697 Use these variables to override the choices made by `configure' or to help
698 it to find libraries and programs with nonstandard names/locations.
703 if test "$ac_init_help" = "recursive"; then
704 # If there are subdirs, report their specific --help.
706 for ac_subdir in : $ac_subdirs_all; do test "x$ac_subdir" = x: && continue
708 # A "../" for each directory in /$ac_subdir.
709 ac_dots=`echo $ac_subdir |
710 sed 's,^\./,,;s,[^/]$,&/,;s,[^/]*/,../,g'`
713 .) # No --srcdir option. We are building in place.
714 ac_sub_srcdir=$srcdir ;;
715 [\\/]* | ?:[\\/]* ) # Absolute path.
716 ac_sub_srcdir=$srcdir/$ac_subdir ;;
718 ac_sub_srcdir=$ac_dots$srcdir/$ac_subdir ;;
721 # Check for guested configure; otherwise get Cygnus style configure.
722 if test -f $ac_sub_srcdir/configure.gnu; then
724 $SHELL $ac_sub_srcdir/configure.gnu --help=recursive
725 elif test -f $ac_sub_srcdir/configure; then
727 $SHELL $ac_sub_srcdir/configure --help=recursive
728 elif test -f $ac_sub_srcdir/configure.ac ||
729 test -f $ac_sub_srcdir/configure.in; then
733 echo "$as_me: WARNING: no configuration information is in $ac_subdir" >&2
739 test -n "$ac_init_help" && exit 0
740 if $ac_init_version; then
743 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
744 Free Software Foundation, Inc.
745 This configure script is free software; the Free Software Foundation
746 gives unlimited permission to copy, distribute and modify it.
752 This file contains any messages produced by compilers while
753 running configure, to aid debugging if configure makes a mistake.
755 It was created by $as_me, which was
756 generated by GNU Autoconf 2.52.20170501. Invocation command line was
767 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
768 uname -m = `(uname -m) 2>/dev/null || echo unknown`
769 uname -r = `(uname -r) 2>/dev/null || echo unknown`
770 uname -s = `(uname -s) 2>/dev/null || echo unknown`
771 uname -v = `(uname -v) 2>/dev/null || echo unknown`
773 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
774 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
776 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
777 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
778 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
779 hostinfo = `(hostinfo) 2>/dev/null || echo unknown`
780 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
781 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
782 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
796 # Keep a trace of the command line.
797 # Strip out --no-create and --no-recursion so they do not pile up.
798 # Also quote any args containing shell meta-characters.
804 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
805 | --no-cr | --no-c) ;;
806 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
807 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
808 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
809 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"`
810 ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
812 *) ac_configure_args="$ac_configure_args$ac_sep$ac_arg"
815 # Get rid of the leading space.
818 # When interrupted or exit'd, cleanup temporary files, and complete
819 # config.log. We remove comments because anyway the quotes in there
820 # would cause problems or look ugly.
822 # Save into config.log some information that might help in debugging.
824 echo "## ----------------- ##" >&5
825 echo "## Cache variables. ##" >&5
826 echo "## ----------------- ##" >&5
828 # The following way of writing the cache mishandles newlines in values,
831 case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
834 "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
835 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
839 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
843 sed "/^$/d" confdefs.h >conftest.log
844 if test -s conftest.log; then
846 echo "## ------------ ##" >&5
847 echo "## confdefs.h. ##" >&5
848 echo "## ------------ ##" >&5
853 test "$ac_signal" != 0 &&
854 echo "$as_me: caught signal $ac_signal" >&5
855 echo "$as_me: exit $exit_status" >&5
856 rm -rf conftest* confdefs* core core.* *.core conf$$* $ac_clean_files &&
859 for ac_signal in 1 2 13 15; do
860 trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
864 # confdefs.h avoids OS command line length limits that DEFS can exceed.
865 rm -rf conftest* confdefs.h
866 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
869 # Let the site file select an alternate cache file if it wants to.
870 # Prefer explicitly selected file to automatically selected ones.
871 if test -z "$CONFIG_SITE"; then
872 if test "x$prefix" != xNONE; then
873 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
875 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
878 for ac_site_file in $CONFIG_SITE; do
879 if test -r "$ac_site_file"; then
880 { echo "$as_me:880: loading site script $ac_site_file" >&5
881 echo "$as_me: loading site script $ac_site_file" >&6;}
882 cat "$ac_site_file" >&5
887 if test -r "$cache_file"; then
888 # Some versions of bash will fail to source /dev/null (special
889 # files actually), so we avoid doing that.
890 if test -f "$cache_file"; then
891 { echo "$as_me:891: loading cache $cache_file" >&5
892 echo "$as_me: loading cache $cache_file" >&6;}
894 [\\/]* | ?:[\\/]* ) . $cache_file;;
899 { echo "$as_me:899: creating cache $cache_file" >&5
900 echo "$as_me: creating cache $cache_file" >&6;}
904 # Check that the precious variables saved in the cache have kept the same
906 ac_cache_corrupted=false
907 for ac_var in `(set) 2>&1 |
908 sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
909 eval ac_old_set=\$ac_cv_env_${ac_var}_set
910 eval ac_new_set=\$ac_env_${ac_var}_set
911 eval ac_old_val="\$ac_cv_env_${ac_var}_value"
912 eval ac_new_val="\$ac_env_${ac_var}_value"
913 case $ac_old_set,$ac_new_set in
915 { echo "$as_me:915: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
916 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
917 ac_cache_corrupted=: ;;
919 { echo "$as_me:919: error: \`$ac_var' was not set in the previous run" >&5
920 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
921 ac_cache_corrupted=: ;;
924 if test "x$ac_old_val" != "x$ac_new_val"; then
925 { echo "$as_me:925: error: \`$ac_var' has changed since the previous run:" >&5
926 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
927 { echo "$as_me:927: former value: $ac_old_val" >&5
928 echo "$as_me: former value: $ac_old_val" >&2;}
929 { echo "$as_me:929: current value: $ac_new_val" >&5
930 echo "$as_me: current value: $ac_new_val" >&2;}
934 # Pass precious variables to config.status. It doesn't matter if
935 # we pass some twice (in addition to the command line arguments).
936 if test "$ac_new_set" = set; then
938 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
939 ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"`
940 ac_configure_args="$ac_configure_args '$ac_arg'"
942 *) ac_configure_args="$ac_configure_args $ac_var=$ac_new_val"
947 if $ac_cache_corrupted; then
948 { echo "$as_me:948: error: changes in the environment can compromise the build" >&5
949 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
950 { { echo "$as_me:950: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
951 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
952 { (exit 1); exit 1; }; }
956 ac_cpp='$CPP $CPPFLAGS'
957 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
958 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
959 ac_compiler_gnu=$ac_cv_c_compiler_gnu
960 ac_main_return=return
962 case `echo "testing\c" 2>/dev/null; echo 1,2,3`,`echo -n testing 2>/dev/null; echo 1,2,3` in
963 *c*,-n*) ECHO_N= ECHO_C= # newlines do not sed ;-) only broken shells would use this case anyway
965 *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
966 *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
968 echo "#! $SHELL" >conftest.sh
969 echo "exit 0" >>conftest.sh
971 if { (echo "$as_me:971: PATH=\".;.\"; conftest.sh") >&5
972 (PATH=".;."; conftest.sh) 2>&5
974 echo "$as_me:974: \$? = $ac_status" >&5
975 (exit $ac_status); }; then
976 ac_path_separator=';'
980 PATH_SEPARATOR="$ac_path_separator"
983 ac_config_headers="$ac_config_headers ncurses_cfg.h:ncurses_tst.hin"
985 test -f config.guess || ( test -f ../config.guess && cp ../config.guess ./ )
987 test -f config.sub || ( test -f ../config.sub && cp ../config.sub ./ )
990 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
991 if test -f $ac_dir/install-sh; then
993 ac_install_sh="$ac_aux_dir/install-sh -c"
995 elif test -f $ac_dir/install.sh; then
997 ac_install_sh="$ac_aux_dir/install.sh -c"
999 elif test -f $ac_dir/shtool; then
1001 ac_install_sh="$ac_aux_dir/shtool install -c"
1005 if test -z "$ac_aux_dir"; then
1006 { { echo "$as_me:1006: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
1007 echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
1008 { (exit 1); exit 1; }; }
1010 ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1011 ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1012 ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
1014 # Make sure we can run config.sub.
1015 $ac_config_sub sun4 >/dev/null 2>&1 ||
1016 { { echo "$as_me:1016: error: cannot run $ac_config_sub" >&5
1017 echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1018 { (exit 1); exit 1; }; }
1020 echo "$as_me:1020: checking build system type" >&5
1021 echo $ECHO_N "checking build system type... $ECHO_C" >&6
1022 if test "${ac_cv_build+set}" = set; then
1023 echo $ECHO_N "(cached) $ECHO_C" >&6
1025 ac_cv_build_alias=$build_alias
1026 test -z "$ac_cv_build_alias" &&
1027 ac_cv_build_alias=`$ac_config_guess`
1028 test -z "$ac_cv_build_alias" &&
1029 { { echo "$as_me:1029: error: cannot guess build type; you must specify one" >&5
1030 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1031 { (exit 1); exit 1; }; }
1032 ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
1033 { { echo "$as_me:1033: error: $ac_config_sub $ac_cv_build_alias failed." >&5
1034 echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed." >&2;}
1035 { (exit 1); exit 1; }; }
1038 echo "$as_me:1038: result: $ac_cv_build" >&5
1039 echo "${ECHO_T}$ac_cv_build" >&6
1041 build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1042 build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1043 build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1045 if test -f $srcdir/config.guess || test -f $ac_aux_dir/config.guess ; then
1046 echo "$as_me:1046: checking host system type" >&5
1047 echo $ECHO_N "checking host system type... $ECHO_C" >&6
1048 if test "${ac_cv_host+set}" = set; then
1049 echo $ECHO_N "(cached) $ECHO_C" >&6
1051 ac_cv_host_alias=$host_alias
1052 test -z "$ac_cv_host_alias" &&
1053 ac_cv_host_alias=$ac_cv_build_alias
1054 ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
1055 { { echo "$as_me:1055: error: $ac_config_sub $ac_cv_host_alias failed" >&5
1056 echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1057 { (exit 1); exit 1; }; }
1060 echo "$as_me:1060: result: $ac_cv_host" >&5
1061 echo "${ECHO_T}$ac_cv_host" >&6
1063 host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1064 host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1065 host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1067 system_name="$host_os"
1069 system_name="`(uname -s -r) 2>/dev/null`"
1070 if test -z "$system_name" ; then
1071 system_name="`(hostname) 2>/dev/null`"
1074 test -n "$system_name" &&
1075 cat >>confdefs.h <<EOF
1076 #define SYSTEM_NAME "$system_name"
1079 if test "${cf_cv_system_name+set}" = set; then
1080 echo $ECHO_N "(cached) $ECHO_C" >&6
1082 cf_cv_system_name="$system_name"
1085 test -z "$system_name" && system_name="$cf_cv_system_name"
1086 test -n "$cf_cv_system_name" && echo "$as_me:1086: result: Configuring for $cf_cv_system_name" >&5
1087 echo "${ECHO_T}Configuring for $cf_cv_system_name" >&6
1089 if test ".$system_name" != ".$cf_cv_system_name" ; then
1090 echo "$as_me:1090: result: Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&5
1091 echo "${ECHO_T}Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&6
1092 { { echo "$as_me:1092: error: \"Please remove config.cache and try again.\"" >&5
1093 echo "$as_me: error: \"Please remove config.cache and try again.\"" >&2;}
1094 { (exit 1); exit 1; }; }
1097 test "$program_prefix" != NONE &&
1098 program_transform_name="s,^,$program_prefix,;$program_transform_name"
1099 # Use a double $ so make ignores it.
1100 test "$program_suffix" != NONE &&
1101 program_transform_name="s,\$,$program_suffix,;$program_transform_name"
1102 # Double any \ or $. echo might interpret backslashes.
1103 # By default was `s,x,x', remove it if useless.
1104 cat <<\_ACEOF >conftest.sed
1105 s/[\\$]/&&/g;s/;s,x,x,$//
1107 program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
1110 echo "$as_me:1110: checking whether ${MAKE-make} sets \${MAKE}" >&5
1111 echo $ECHO_N "checking whether ${MAKE-make} sets \${MAKE}... $ECHO_C" >&6
1112 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,./+-,__p_,'`
1113 if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
1114 echo $ECHO_N "(cached) $ECHO_C" >&6
1116 cat >conftest.make <<\EOF
1118 @echo 'ac_maketemp="${MAKE}"'
1120 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1121 eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
1122 if test -n "$ac_maketemp"; then
1123 eval ac_cv_prog_make_${ac_make}_set=yes
1125 eval ac_cv_prog_make_${ac_make}_set=no
1129 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
1130 echo "$as_me:1130: result: yes" >&5
1131 echo "${ECHO_T}yes" >&6
1134 echo "$as_me:1134: result: no" >&5
1135 echo "${ECHO_T}no" >&6
1136 SET_MAKE="MAKE=${MAKE-make}"
1140 ac_cpp='$CPP $CPPFLAGS'
1141 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1142 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1143 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1144 ac_main_return=return
1145 if test -n "$ac_tool_prefix"; then
1146 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
1147 set dummy ${ac_tool_prefix}gcc; ac_word=$2
1148 echo "$as_me:1148: checking for $ac_word" >&5
1149 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1150 if test "${ac_cv_prog_CC+set}" = set; then
1151 echo $ECHO_N "(cached) $ECHO_C" >&6
1153 if test -n "$CC"; then
1154 ac_cv_prog_CC="$CC" # Let the user override the test.
1156 ac_save_IFS=$IFS; IFS=$ac_path_separator
1158 for ac_dir in $ac_dummy; do
1160 test -z "$ac_dir" && ac_dir=.
1161 $as_executable_p "$ac_dir/$ac_word" || continue
1162 ac_cv_prog_CC="${ac_tool_prefix}gcc"
1163 echo "$as_me:1163: found $ac_dir/$ac_word" >&5
1170 if test -n "$CC"; then
1171 echo "$as_me:1171: result: $CC" >&5
1172 echo "${ECHO_T}$CC" >&6
1174 echo "$as_me:1174: result: no" >&5
1175 echo "${ECHO_T}no" >&6
1179 if test -z "$ac_cv_prog_CC"; then
1181 # Extract the first word of "gcc", so it can be a program name with args.
1182 set dummy gcc; ac_word=$2
1183 echo "$as_me:1183: checking for $ac_word" >&5
1184 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1185 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1186 echo $ECHO_N "(cached) $ECHO_C" >&6
1188 if test -n "$ac_ct_CC"; then
1189 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1191 ac_save_IFS=$IFS; IFS=$ac_path_separator
1193 for ac_dir in $ac_dummy; do
1195 test -z "$ac_dir" && ac_dir=.
1196 $as_executable_p "$ac_dir/$ac_word" || continue
1197 ac_cv_prog_ac_ct_CC="gcc"
1198 echo "$as_me:1198: found $ac_dir/$ac_word" >&5
1204 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1205 if test -n "$ac_ct_CC"; then
1206 echo "$as_me:1206: result: $ac_ct_CC" >&5
1207 echo "${ECHO_T}$ac_ct_CC" >&6
1209 echo "$as_me:1209: result: no" >&5
1210 echo "${ECHO_T}no" >&6
1218 if test -z "$CC"; then
1219 if test -n "$ac_tool_prefix"; then
1220 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
1221 set dummy ${ac_tool_prefix}cc; ac_word=$2
1222 echo "$as_me:1222: checking for $ac_word" >&5
1223 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1224 if test "${ac_cv_prog_CC+set}" = set; then
1225 echo $ECHO_N "(cached) $ECHO_C" >&6
1227 if test -n "$CC"; then
1228 ac_cv_prog_CC="$CC" # Let the user override the test.
1230 ac_save_IFS=$IFS; IFS=$ac_path_separator
1232 for ac_dir in $ac_dummy; do
1234 test -z "$ac_dir" && ac_dir=.
1235 $as_executable_p "$ac_dir/$ac_word" || continue
1236 ac_cv_prog_CC="${ac_tool_prefix}cc"
1237 echo "$as_me:1237: found $ac_dir/$ac_word" >&5
1244 if test -n "$CC"; then
1245 echo "$as_me:1245: result: $CC" >&5
1246 echo "${ECHO_T}$CC" >&6
1248 echo "$as_me:1248: result: no" >&5
1249 echo "${ECHO_T}no" >&6
1253 if test -z "$ac_cv_prog_CC"; then
1255 # Extract the first word of "cc", so it can be a program name with args.
1256 set dummy cc; ac_word=$2
1257 echo "$as_me:1257: checking for $ac_word" >&5
1258 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1259 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1260 echo $ECHO_N "(cached) $ECHO_C" >&6
1262 if test -n "$ac_ct_CC"; then
1263 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1265 ac_save_IFS=$IFS; IFS=$ac_path_separator
1267 for ac_dir in $ac_dummy; do
1269 test -z "$ac_dir" && ac_dir=.
1270 $as_executable_p "$ac_dir/$ac_word" || continue
1271 ac_cv_prog_ac_ct_CC="cc"
1272 echo "$as_me:1272: found $ac_dir/$ac_word" >&5
1278 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1279 if test -n "$ac_ct_CC"; then
1280 echo "$as_me:1280: result: $ac_ct_CC" >&5
1281 echo "${ECHO_T}$ac_ct_CC" >&6
1283 echo "$as_me:1283: result: no" >&5
1284 echo "${ECHO_T}no" >&6
1293 if test -z "$CC"; then
1294 # Extract the first word of "cc", so it can be a program name with args.
1295 set dummy cc; ac_word=$2
1296 echo "$as_me:1296: checking for $ac_word" >&5
1297 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1298 if test "${ac_cv_prog_CC+set}" = set; then
1299 echo $ECHO_N "(cached) $ECHO_C" >&6
1301 if test -n "$CC"; then
1302 ac_cv_prog_CC="$CC" # Let the user override the test.
1305 ac_save_IFS=$IFS; IFS=$ac_path_separator
1307 for ac_dir in $ac_dummy; do
1309 test -z "$ac_dir" && ac_dir=.
1310 $as_executable_p "$ac_dir/$ac_word" || continue
1311 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
1312 ac_prog_rejected=yes
1316 echo "$as_me:1316: found $ac_dir/$ac_word" >&5
1320 if test $ac_prog_rejected = yes; then
1321 # We found a bogon in the path, so make sure we never use it.
1322 set dummy $ac_cv_prog_CC
1324 if test $# != 0; then
1325 # We chose a different compiler from the bogus one.
1326 # However, it has the same basename, so the bogon will be chosen
1327 # first if we set CC to just the basename; use the full file name.
1329 set dummy "$ac_dir/$ac_word" ${1+"$@"}
1337 if test -n "$CC"; then
1338 echo "$as_me:1338: result: $CC" >&5
1339 echo "${ECHO_T}$CC" >&6
1341 echo "$as_me:1341: result: no" >&5
1342 echo "${ECHO_T}no" >&6
1346 if test -z "$CC"; then
1347 if test -n "$ac_tool_prefix"; then
1350 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
1351 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
1352 echo "$as_me:1352: checking for $ac_word" >&5
1353 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1354 if test "${ac_cv_prog_CC+set}" = set; then
1355 echo $ECHO_N "(cached) $ECHO_C" >&6
1357 if test -n "$CC"; then
1358 ac_cv_prog_CC="$CC" # Let the user override the test.
1360 ac_save_IFS=$IFS; IFS=$ac_path_separator
1362 for ac_dir in $ac_dummy; do
1364 test -z "$ac_dir" && ac_dir=.
1365 $as_executable_p "$ac_dir/$ac_word" || continue
1366 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
1367 echo "$as_me:1367: found $ac_dir/$ac_word" >&5
1374 if test -n "$CC"; then
1375 echo "$as_me:1375: result: $CC" >&5
1376 echo "${ECHO_T}$CC" >&6
1378 echo "$as_me:1378: result: no" >&5
1379 echo "${ECHO_T}no" >&6
1382 test -n "$CC" && break
1385 if test -z "$CC"; then
1389 # Extract the first word of "$ac_prog", so it can be a program name with args.
1390 set dummy $ac_prog; ac_word=$2
1391 echo "$as_me:1391: checking for $ac_word" >&5
1392 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1393 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1394 echo $ECHO_N "(cached) $ECHO_C" >&6
1396 if test -n "$ac_ct_CC"; then
1397 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1399 ac_save_IFS=$IFS; IFS=$ac_path_separator
1401 for ac_dir in $ac_dummy; do
1403 test -z "$ac_dir" && ac_dir=.
1404 $as_executable_p "$ac_dir/$ac_word" || continue
1405 ac_cv_prog_ac_ct_CC="$ac_prog"
1406 echo "$as_me:1406: found $ac_dir/$ac_word" >&5
1412 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1413 if test -n "$ac_ct_CC"; then
1414 echo "$as_me:1414: result: $ac_ct_CC" >&5
1415 echo "${ECHO_T}$ac_ct_CC" >&6
1417 echo "$as_me:1417: result: no" >&5
1418 echo "${ECHO_T}no" >&6
1421 test -n "$ac_ct_CC" && break
1429 test -z "$CC" && { { echo "$as_me:1429: error: no acceptable cc found in \$PATH" >&5
1430 echo "$as_me: error: no acceptable cc found in \$PATH" >&2;}
1431 { (exit 1); exit 1; }; }
1433 # Provide some information about the compiler.
1434 echo "$as_me:1434:" \
1435 "checking for C compiler version" >&5
1436 ac_compiler=`set X $ac_compile; echo $2`
1437 { (eval echo "$as_me:1437: \"$ac_compiler --version </dev/null >&5\"") >&5
1438 (eval $ac_compiler --version </dev/null >&5) 2>&5
1440 echo "$as_me:1440: \$? = $ac_status" >&5
1441 (exit $ac_status); }
1442 { (eval echo "$as_me:1442: \"$ac_compiler -v </dev/null >&5\"") >&5
1443 (eval $ac_compiler -v </dev/null >&5) 2>&5
1445 echo "$as_me:1445: \$? = $ac_status" >&5
1446 (exit $ac_status); }
1447 { (eval echo "$as_me:1447: \"$ac_compiler -V </dev/null >&5\"") >&5
1448 (eval $ac_compiler -V </dev/null >&5) 2>&5
1450 echo "$as_me:1450: \$? = $ac_status" >&5
1451 (exit $ac_status); }
1453 cat >conftest.$ac_ext <<_ACEOF
1454 #line 1454 "configure"
1455 #include "confdefs.h"
1465 ac_clean_files_save=$ac_clean_files
1466 ac_clean_files="$ac_clean_files a.out a.exe"
1467 # Try to create an executable without -o first, disregard a.out.
1468 # It will help us diagnose broken compilers, and finding out an intuition
1470 echo "$as_me:1470: checking for C compiler default output" >&5
1471 echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
1472 ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
1473 if { (eval echo "$as_me:1473: \"$ac_link_default\"") >&5
1474 (eval $ac_link_default) 2>&5
1476 echo "$as_me:1476: \$? = $ac_status" >&5
1477 (exit $ac_status); }; then
1478 # Find the output, starting from the most likely. This scheme is
1479 # not robust to junk in `.', hence go to wildcards (a.*) only as a last
1481 for ac_file in `ls a.exe conftest.exe 2>/dev/null;
1482 ls a.out conftest 2>/dev/null;
1483 ls a.* conftest.* 2>/dev/null`; do
1485 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1486 a.out ) # We found the default executable, but exeext='' is most
1489 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1490 # FIXME: I believe we export ac_cv_exeext for Libtool --akim.
1497 echo "$as_me: failed program was:" >&5
1498 cat conftest.$ac_ext >&5
1499 { { echo "$as_me:1499: error: C compiler cannot create executables" >&5
1500 echo "$as_me: error: C compiler cannot create executables" >&2;}
1501 { (exit 77); exit 77; }; }
1504 ac_exeext=$ac_cv_exeext
1505 echo "$as_me:1505: result: $ac_file" >&5
1506 echo "${ECHO_T}$ac_file" >&6
1508 # Check the compiler produces executables we can run. If not, either
1509 # the compiler is broken, or we cross compile.
1510 echo "$as_me:1510: checking whether the C compiler works" >&5
1511 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
1512 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
1513 # If not cross compiling, check that we can run a simple program.
1514 if test "$cross_compiling" != yes; then
1515 if { ac_try='./$ac_file'
1516 { (eval echo "$as_me:1516: \"$ac_try\"") >&5
1519 echo "$as_me:1519: \$? = $ac_status" >&5
1520 (exit $ac_status); }; }; then
1523 if test "$cross_compiling" = maybe; then
1526 { { echo "$as_me:1526: error: cannot run C compiled programs.
1527 If you meant to cross compile, use \`--host'." >&5
1528 echo "$as_me: error: cannot run C compiled programs.
1529 If you meant to cross compile, use \`--host'." >&2;}
1530 { (exit 1); exit 1; }; }
1534 echo "$as_me:1534: result: yes" >&5
1535 echo "${ECHO_T}yes" >&6
1537 rm -f a.out a.exe conftest$ac_cv_exeext
1538 ac_clean_files=$ac_clean_files_save
1539 # Check the compiler produces executables we can run. If not, either
1540 # the compiler is broken, or we cross compile.
1541 echo "$as_me:1541: checking whether we are cross compiling" >&5
1542 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
1543 echo "$as_me:1543: result: $cross_compiling" >&5
1544 echo "${ECHO_T}$cross_compiling" >&6
1546 echo "$as_me:1546: checking for executable suffix" >&5
1547 echo $ECHO_N "checking for executable suffix... $ECHO_C" >&6
1548 if { (eval echo "$as_me:1548: \"$ac_link\"") >&5
1549 (eval $ac_link) 2>&5
1551 echo "$as_me:1551: \$? = $ac_status" >&5
1552 (exit $ac_status); }; then
1553 # If both `conftest.exe' and `conftest' are `present' (well, observable)
1554 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
1555 # work properly (i.e., refer to `conftest.exe'), while it won't with
1557 for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do
1559 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1560 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1567 { { echo "$as_me:1567: error: cannot compute EXEEXT: cannot compile and link" >&5
1568 echo "$as_me: error: cannot compute EXEEXT: cannot compile and link" >&2;}
1569 { (exit 1); exit 1; }; }
1572 rm -f conftest$ac_cv_exeext
1573 echo "$as_me:1573: result: $ac_cv_exeext" >&5
1574 echo "${ECHO_T}$ac_cv_exeext" >&6
1576 rm -f conftest.$ac_ext
1577 EXEEXT=$ac_cv_exeext
1579 echo "$as_me:1579: checking for object suffix" >&5
1580 echo $ECHO_N "checking for object suffix... $ECHO_C" >&6
1581 if test "${ac_cv_objext+set}" = set; then
1582 echo $ECHO_N "(cached) $ECHO_C" >&6
1584 cat >conftest.$ac_ext <<_ACEOF
1585 #line 1585 "configure"
1586 #include "confdefs.h"
1596 rm -f conftest.o conftest.obj
1597 if { (eval echo "$as_me:1597: \"$ac_compile\"") >&5
1598 (eval $ac_compile) 2>&5
1600 echo "$as_me:1600: \$? = $ac_status" >&5
1601 (exit $ac_status); }; then
1602 for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
1604 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.map | *.inf ) ;;
1605 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
1610 echo "$as_me: failed program was:" >&5
1611 cat conftest.$ac_ext >&5
1612 { { echo "$as_me:1612: error: cannot compute OBJEXT: cannot compile" >&5
1613 echo "$as_me: error: cannot compute OBJEXT: cannot compile" >&2;}
1614 { (exit 1); exit 1; }; }
1617 rm -f conftest.$ac_cv_objext conftest.$ac_ext
1619 echo "$as_me:1619: result: $ac_cv_objext" >&5
1620 echo "${ECHO_T}$ac_cv_objext" >&6
1621 OBJEXT=$ac_cv_objext
1623 echo "$as_me:1623: checking whether we are using the GNU C compiler" >&5
1624 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
1625 if test "${ac_cv_c_compiler_gnu+set}" = set; then
1626 echo $ECHO_N "(cached) $ECHO_C" >&6
1628 cat >conftest.$ac_ext <<_ACEOF
1629 #line 1629 "configure"
1630 #include "confdefs.h"
1643 rm -f conftest.$ac_objext
1644 if { (eval echo "$as_me:1644: \"$ac_compile\"") >&5
1645 (eval $ac_compile) 2>&5
1647 echo "$as_me:1647: \$? = $ac_status" >&5
1648 (exit $ac_status); } &&
1649 { ac_try='test -s conftest.$ac_objext'
1650 { (eval echo "$as_me:1650: \"$ac_try\"") >&5
1653 echo "$as_me:1653: \$? = $ac_status" >&5
1654 (exit $ac_status); }; }; then
1657 echo "$as_me: failed program was:" >&5
1658 cat conftest.$ac_ext >&5
1661 rm -f conftest.$ac_objext conftest.$ac_ext
1662 ac_cv_c_compiler_gnu=$ac_compiler_gnu
1665 echo "$as_me:1665: result: $ac_cv_c_compiler_gnu" >&5
1666 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
1667 GCC=`test $ac_compiler_gnu = yes && echo yes`
1668 ac_test_CFLAGS=${CFLAGS+set}
1669 ac_save_CFLAGS=$CFLAGS
1671 echo "$as_me:1671: checking whether $CC accepts -g" >&5
1672 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
1673 if test "${ac_cv_prog_cc_g+set}" = set; then
1674 echo $ECHO_N "(cached) $ECHO_C" >&6
1676 cat >conftest.$ac_ext <<_ACEOF
1677 #line 1677 "configure"
1678 #include "confdefs.h"
1688 rm -f conftest.$ac_objext
1689 if { (eval echo "$as_me:1689: \"$ac_compile\"") >&5
1690 (eval $ac_compile) 2>&5
1692 echo "$as_me:1692: \$? = $ac_status" >&5
1693 (exit $ac_status); } &&
1694 { ac_try='test -s conftest.$ac_objext'
1695 { (eval echo "$as_me:1695: \"$ac_try\"") >&5
1698 echo "$as_me:1698: \$? = $ac_status" >&5
1699 (exit $ac_status); }; }; then
1702 echo "$as_me: failed program was:" >&5
1703 cat conftest.$ac_ext >&5
1706 rm -f conftest.$ac_objext conftest.$ac_ext
1708 echo "$as_me:1708: result: $ac_cv_prog_cc_g" >&5
1709 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
1710 if test "$ac_test_CFLAGS" = set; then
1711 CFLAGS=$ac_save_CFLAGS
1712 elif test $ac_cv_prog_cc_g = yes; then
1713 if test "$GCC" = yes; then
1719 if test "$GCC" = yes; then
1725 # Some people use a C++ compiler to compile C. Since we use `exit',
1726 # in C++ we need to declare it. In case someone uses the same compiler
1727 # for both compiling C and C++ we need to have the C++ compiler decide
1728 # the declaration of exit, since it's the most demanding environment.
1729 cat >conftest.$ac_ext <<_ACEOF
1734 rm -f conftest.$ac_objext
1735 if { (eval echo "$as_me:1735: \"$ac_compile\"") >&5
1736 (eval $ac_compile) 2>&5
1738 echo "$as_me:1738: \$? = $ac_status" >&5
1739 (exit $ac_status); } &&
1740 { ac_try='test -s conftest.$ac_objext'
1741 { (eval echo "$as_me:1741: \"$ac_try\"") >&5
1744 echo "$as_me:1744: \$? = $ac_status" >&5
1745 (exit $ac_status); }; }; then
1746 for ac_declaration in \
1748 '#include <stdlib.h>' \
1749 'extern "C" void std::exit (int) throw (); using std::exit;' \
1750 'extern "C" void std::exit (int); using std::exit;' \
1751 'extern "C" void exit (int) throw ();' \
1752 'extern "C" void exit (int);' \
1755 cat >conftest.$ac_ext <<_ACEOF
1756 #line 1756 "configure"
1757 #include "confdefs.h"
1768 rm -f conftest.$ac_objext
1769 if { (eval echo "$as_me:1769: \"$ac_compile\"") >&5
1770 (eval $ac_compile) 2>&5
1772 echo "$as_me:1772: \$? = $ac_status" >&5
1773 (exit $ac_status); } &&
1774 { ac_try='test -s conftest.$ac_objext'
1775 { (eval echo "$as_me:1775: \"$ac_try\"") >&5
1778 echo "$as_me:1778: \$? = $ac_status" >&5
1779 (exit $ac_status); }; }; then
1782 echo "$as_me: failed program was:" >&5
1783 cat conftest.$ac_ext >&5
1786 rm -f conftest.$ac_objext conftest.$ac_ext
1787 cat >conftest.$ac_ext <<_ACEOF
1788 #line 1788 "configure"
1789 #include "confdefs.h"
1799 rm -f conftest.$ac_objext
1800 if { (eval echo "$as_me:1800: \"$ac_compile\"") >&5
1801 (eval $ac_compile) 2>&5
1803 echo "$as_me:1803: \$? = $ac_status" >&5
1804 (exit $ac_status); } &&
1805 { ac_try='test -s conftest.$ac_objext'
1806 { (eval echo "$as_me:1806: \"$ac_try\"") >&5
1809 echo "$as_me:1809: \$? = $ac_status" >&5
1810 (exit $ac_status); }; }; then
1813 echo "$as_me: failed program was:" >&5
1814 cat conftest.$ac_ext >&5
1816 rm -f conftest.$ac_objext conftest.$ac_ext
1819 if test -n "$ac_declaration"; then
1820 echo '#ifdef __cplusplus' >>confdefs.h
1821 echo $ac_declaration >>confdefs.h
1822 echo '#endif' >>confdefs.h
1826 echo "$as_me: failed program was:" >&5
1827 cat conftest.$ac_ext >&5
1829 rm -f conftest.$ac_objext conftest.$ac_ext
1831 ac_cpp='$CPP $CPPFLAGS'
1832 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1833 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1834 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1835 ac_main_return=return
1838 if test "$GCC" = yes ; then
1839 echo "$as_me:1839: checking version of $CC" >&5
1840 echo $ECHO_N "checking version of $CC... $ECHO_C" >&6
1841 GCC_VERSION="`${CC} --version 2>/dev/null | sed -e '2,$d' -e 's/^.*(GCC[^)]*) //' -e 's/^.*(Debian[^)]*) //' -e 's/^[^0-9.]*//' -e 's/[^0-9.].*//'`"
1842 test -z "$GCC_VERSION" && GCC_VERSION=unknown
1843 echo "$as_me:1843: result: $GCC_VERSION" >&5
1844 echo "${ECHO_T}$GCC_VERSION" >&6
1847 echo "$as_me:1847: checking for $CC option to accept ANSI C" >&5
1848 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
1849 if test "${ac_cv_prog_cc_stdc+set}" = set; then
1850 echo $ECHO_N "(cached) $ECHO_C" >&6
1852 ac_cv_prog_cc_stdc=no
1854 cat >conftest.$ac_ext <<_ACEOF
1855 #line 1855 "configure"
1856 #include "confdefs.h"
1859 #include <sys/types.h>
1860 #include <sys/stat.h>
1861 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
1862 struct buf { int x; };
1863 FILE * (*rcsopen) (struct buf *, struct stat *, int);
1864 static char *e (p, i)
1870 static char *f (char * (*g) (char **, int), char **p, ...)
1875 s = g (p, va_arg (v,int));
1879 int test (int i, double x);
1880 struct s1 {int (*f) (int a);};
1881 struct s2 {int (*f) (double a);};
1882 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
1888 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
1893 # Don't try gcc -ansi; that turns off useful extensions and
1894 # breaks some systems' header files.
1895 # AIX -qlanglvl=ansi
1896 # Ultrix and OSF/1 -std1
1897 # HP-UX 10.20 and later -Ae
1898 # HP-UX older versions -Aa -D_HPUX_SOURCE
1899 # SVR4 -Xc -D__EXTENSIONS__
1900 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
1902 CC="$ac_save_CC $ac_arg"
1903 rm -f conftest.$ac_objext
1904 if { (eval echo "$as_me:1904: \"$ac_compile\"") >&5
1905 (eval $ac_compile) 2>&5
1907 echo "$as_me:1907: \$? = $ac_status" >&5
1908 (exit $ac_status); } &&
1909 { ac_try='test -s conftest.$ac_objext'
1910 { (eval echo "$as_me:1910: \"$ac_try\"") >&5
1913 echo "$as_me:1913: \$? = $ac_status" >&5
1914 (exit $ac_status); }; }; then
1915 ac_cv_prog_cc_stdc=$ac_arg
1918 echo "$as_me: failed program was:" >&5
1919 cat conftest.$ac_ext >&5
1921 rm -f conftest.$ac_objext
1923 rm -f conftest.$ac_ext conftest.$ac_objext
1928 case "x$ac_cv_prog_cc_stdc" in
1930 echo "$as_me:1930: result: none needed" >&5
1931 echo "${ECHO_T}none needed" >&6 ;;
1933 echo "$as_me:1933: result: $ac_cv_prog_cc_stdc" >&5
1934 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
1935 CC="$CC $ac_cv_prog_cc_stdc" ;;
1938 # This should have been defined by AC_PROG_CC
1941 echo "$as_me:1941: checking \$CC variable" >&5
1942 echo $ECHO_N "checking \$CC variable... $ECHO_C" >&6
1945 echo "$as_me:1945: result: broken" >&5
1946 echo "${ECHO_T}broken" >&6
1947 { echo "$as_me:1947: WARNING: your environment misuses the CC variable to hold CFLAGS/CPPFLAGS options" >&5
1948 echo "$as_me: WARNING: your environment misuses the CC variable to hold CFLAGS/CPPFLAGS options" >&2;}
1950 cf_prog=`echo "$CC" | sed -e 's/ / /g' -e 's/[ ]* / /g' -e 's/[ ]*[ ]-[^ ].*//'`
1951 cf_flags=`echo "$CC" | ${AWK:-awk} -v prog="$cf_prog" '{ printf("%s", substr($0,1+length(prog))); }'`
1953 for cf_arg in $cf_flags
1961 cf_new_extra_cppflags=
1963 for cf_add_cflags in $cf_arg
1965 case $cf_fix_cppflags in
1967 case $cf_add_cflags in
1968 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
1969 case $cf_add_cflags in
1971 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
1973 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
1974 && test -z "${cf_tst_cflags}" \
1975 && cf_fix_cppflags=yes
1977 if test $cf_fix_cppflags = yes ; then
1979 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
1980 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
1983 elif test "${cf_tst_cflags}" = "\"'" ; then
1985 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
1986 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
1996 case $cf_add_cflags in
1998 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
2000 CPPFLAGS=`echo "$CPPFLAGS" | \
2001 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
2002 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
2007 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
2008 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
2015 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
2016 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
2023 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2024 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2026 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
2028 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2029 && test -z "${cf_tst_cflags}" \
2030 && cf_fix_cppflags=no
2035 if test -n "$cf_new_cflags" ; then
2037 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
2038 CFLAGS="${CFLAGS}$cf_new_cflags"
2042 if test -n "$cf_new_cppflags" ; then
2044 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
2045 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
2049 if test -n "$cf_new_extra_cppflags" ; then
2051 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
2052 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
2062 test -n "$verbose" && echo " resulting CC: '$CC'" 1>&6
2064 echo "${as_me:-configure}:2064: testing resulting CC: '$CC' ..." 1>&5
2066 test -n "$verbose" && echo " resulting CFLAGS: '$CFLAGS'" 1>&6
2068 echo "${as_me:-configure}:2068: testing resulting CFLAGS: '$CFLAGS' ..." 1>&5
2070 test -n "$verbose" && echo " resulting CPPFLAGS: '$CPPFLAGS'" 1>&6
2072 echo "${as_me:-configure}:2072: testing resulting CPPFLAGS: '$CPPFLAGS' ..." 1>&5
2076 echo "$as_me:2076: result: ok" >&5
2077 echo "${ECHO_T}ok" >&6
2081 echo "$as_me:2081: checking for inline" >&5
2082 echo $ECHO_N "checking for inline... $ECHO_C" >&6
2083 if test "${ac_cv_c_inline+set}" = set; then
2084 echo $ECHO_N "(cached) $ECHO_C" >&6
2087 for ac_kw in inline __inline__ __inline; do
2088 cat >conftest.$ac_ext <<_ACEOF
2089 #line 2089 "configure"
2090 #include "confdefs.h"
2092 static $ac_kw int static_foo () {return 0; }
2093 $ac_kw int foo () {return 0; }
2097 rm -f conftest.$ac_objext
2098 if { (eval echo "$as_me:2098: \"$ac_compile\"") >&5
2099 (eval $ac_compile) 2>&5
2101 echo "$as_me:2101: \$? = $ac_status" >&5
2102 (exit $ac_status); } &&
2103 { ac_try='test -s conftest.$ac_objext'
2104 { (eval echo "$as_me:2104: \"$ac_try\"") >&5
2107 echo "$as_me:2107: \$? = $ac_status" >&5
2108 (exit $ac_status); }; }; then
2109 ac_cv_c_inline=$ac_kw; break
2111 echo "$as_me: failed program was:" >&5
2112 cat conftest.$ac_ext >&5
2114 rm -f conftest.$ac_objext conftest.$ac_ext
2118 echo "$as_me:2118: result: $ac_cv_c_inline" >&5
2119 echo "${ECHO_T}$ac_cv_c_inline" >&6
2120 case $ac_cv_c_inline in
2123 cat >>confdefs.h <<\EOF
2127 *) cat >>confdefs.h <<EOF
2128 #define inline $ac_cv_c_inline
2134 ac_cpp='$CPP $CPPFLAGS'
2135 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2136 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2137 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2138 ac_main_return=return
2139 echo "$as_me:2139: checking how to run the C preprocessor" >&5
2140 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
2141 # On Suns, sometimes $CPP names a directory.
2142 if test -n "$CPP" && test -d "$CPP"; then
2145 if test -z "$CPP"; then
2146 if test "${ac_cv_prog_CPP+set}" = set; then
2147 echo $ECHO_N "(cached) $ECHO_C" >&6
2149 # Double quotes because CPP needs to be expanded
2150 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
2153 for ac_c_preproc_warn_flag in '' yes
2155 # Use a header file that comes with gcc, so configuring glibc
2156 # with a fresh cross-compiler works.
2157 # On the NeXT, cc -E runs the code through the compiler's parser,
2158 # not just through cpp. "Syntax error" is here to catch this case.
2159 cat >conftest.$ac_ext <<_ACEOF
2160 #line 2160 "configure"
2161 #include "confdefs.h"
2165 if { (eval echo "$as_me:2165: \"$ac_cpp conftest.$ac_ext\"") >&5
2166 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2168 egrep -v '^ *\+' conftest.er1 >conftest.err
2170 cat conftest.err >&5
2171 echo "$as_me:2171: \$? = $ac_status" >&5
2172 (exit $ac_status); } >/dev/null; then
2173 if test -s conftest.err; then
2174 ac_cpp_err=$ac_c_preproc_warn_flag
2181 if test -z "$ac_cpp_err"; then
2184 echo "$as_me: failed program was:" >&5
2185 cat conftest.$ac_ext >&5
2186 # Broken: fails on valid input.
2189 rm -f conftest.err conftest.$ac_ext
2191 # OK, works on sane cases. Now check whether non-existent headers
2192 # can be detected and how.
2193 cat >conftest.$ac_ext <<_ACEOF
2194 #line 2194 "configure"
2195 #include "confdefs.h"
2196 #include <ac_nonexistent.h>
2198 if { (eval echo "$as_me:2198: \"$ac_cpp conftest.$ac_ext\"") >&5
2199 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2201 egrep -v '^ *\+' conftest.er1 >conftest.err
2203 cat conftest.err >&5
2204 echo "$as_me:2204: \$? = $ac_status" >&5
2205 (exit $ac_status); } >/dev/null; then
2206 if test -s conftest.err; then
2207 ac_cpp_err=$ac_c_preproc_warn_flag
2214 if test -z "$ac_cpp_err"; then
2215 # Broken: success on invalid input.
2218 echo "$as_me: failed program was:" >&5
2219 cat conftest.$ac_ext >&5
2220 # Passes both tests.
2224 rm -f conftest.err conftest.$ac_ext
2227 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2228 rm -f conftest.err conftest.$ac_ext
2229 if $ac_preproc_ok; then
2241 echo "$as_me:2241: result: $CPP" >&5
2242 echo "${ECHO_T}$CPP" >&6
2244 for ac_c_preproc_warn_flag in '' yes
2246 # Use a header file that comes with gcc, so configuring glibc
2247 # with a fresh cross-compiler works.
2248 # On the NeXT, cc -E runs the code through the compiler's parser,
2249 # not just through cpp. "Syntax error" is here to catch this case.
2250 cat >conftest.$ac_ext <<_ACEOF
2251 #line 2251 "configure"
2252 #include "confdefs.h"
2256 if { (eval echo "$as_me:2256: \"$ac_cpp conftest.$ac_ext\"") >&5
2257 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2259 egrep -v '^ *\+' conftest.er1 >conftest.err
2261 cat conftest.err >&5
2262 echo "$as_me:2262: \$? = $ac_status" >&5
2263 (exit $ac_status); } >/dev/null; then
2264 if test -s conftest.err; then
2265 ac_cpp_err=$ac_c_preproc_warn_flag
2272 if test -z "$ac_cpp_err"; then
2275 echo "$as_me: failed program was:" >&5
2276 cat conftest.$ac_ext >&5
2277 # Broken: fails on valid input.
2280 rm -f conftest.err conftest.$ac_ext
2282 # OK, works on sane cases. Now check whether non-existent headers
2283 # can be detected and how.
2284 cat >conftest.$ac_ext <<_ACEOF
2285 #line 2285 "configure"
2286 #include "confdefs.h"
2287 #include <ac_nonexistent.h>
2289 if { (eval echo "$as_me:2289: \"$ac_cpp conftest.$ac_ext\"") >&5
2290 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2292 egrep -v '^ *\+' conftest.er1 >conftest.err
2294 cat conftest.err >&5
2295 echo "$as_me:2295: \$? = $ac_status" >&5
2296 (exit $ac_status); } >/dev/null; then
2297 if test -s conftest.err; then
2298 ac_cpp_err=$ac_c_preproc_warn_flag
2305 if test -z "$ac_cpp_err"; then
2306 # Broken: success on invalid input.
2309 echo "$as_me: failed program was:" >&5
2310 cat conftest.$ac_ext >&5
2311 # Passes both tests.
2315 rm -f conftest.err conftest.$ac_ext
2318 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2319 rm -f conftest.err conftest.$ac_ext
2320 if $ac_preproc_ok; then
2323 { { echo "$as_me:2323: error: C preprocessor \"$CPP\" fails sanity check" >&5
2324 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;}
2325 { (exit 1); exit 1; }; }
2329 ac_cpp='$CPP $CPPFLAGS'
2330 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2331 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2332 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2333 ac_main_return=return
2335 for ac_prog in mawk gawk nawk awk
2337 # Extract the first word of "$ac_prog", so it can be a program name with args.
2338 set dummy $ac_prog; ac_word=$2
2339 echo "$as_me:2339: checking for $ac_word" >&5
2340 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2341 if test "${ac_cv_prog_AWK+set}" = set; then
2342 echo $ECHO_N "(cached) $ECHO_C" >&6
2344 if test -n "$AWK"; then
2345 ac_cv_prog_AWK="$AWK" # Let the user override the test.
2347 ac_save_IFS=$IFS; IFS=$ac_path_separator
2349 for ac_dir in $ac_dummy; do
2351 test -z "$ac_dir" && ac_dir=.
2352 $as_executable_p "$ac_dir/$ac_word" || continue
2353 ac_cv_prog_AWK="$ac_prog"
2354 echo "$as_me:2354: found $ac_dir/$ac_word" >&5
2361 if test -n "$AWK"; then
2362 echo "$as_me:2362: result: $AWK" >&5
2363 echo "${ECHO_T}$AWK" >&6
2365 echo "$as_me:2365: result: no" >&5
2366 echo "${ECHO_T}no" >&6
2369 test -n "$AWK" && break
2372 # Find a good install program. We prefer a C program (faster),
2373 # so one script is as good as another. But avoid the broken or
2374 # incompatible versions:
2375 # SysV /etc/install, /usr/sbin/install
2376 # SunOS /usr/etc/install
2377 # IRIX /sbin/install
2379 # AmigaOS /C/install, which installs bootblocks on floppy discs
2380 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
2381 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
2382 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
2383 # ./install, which can be erroneously created by make from ./install.sh.
2384 echo "$as_me:2384: checking for a BSD compatible install" >&5
2385 echo $ECHO_N "checking for a BSD compatible install... $ECHO_C" >&6
2386 if test -z "$INSTALL"; then
2387 if test "${ac_cv_path_install+set}" = set; then
2388 echo $ECHO_N "(cached) $ECHO_C" >&6
2390 ac_save_IFS=$IFS; IFS=$ac_path_separator
2391 for ac_dir in $PATH; do
2393 # Account for people who put trailing slashes in PATH elements.
2395 / | ./ | .// | /cC/* \
2396 | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* \
2399 # OSF1 and SCO ODT 3.0 have their own names for install.
2400 # Don't use installbsd from OSF since it installs stuff as root
2402 for ac_prog in ginstall scoinst install; do
2403 if $as_executable_p "$ac_dir/$ac_prog"; then
2404 if test $ac_prog = install &&
2405 grep dspmsg "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2406 # AIX install. It has an incompatible calling convention.
2408 elif test $ac_prog = install &&
2409 grep pwplus "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2410 # program-specific install script used by HP pwplus--don't use.
2413 ac_cv_path_install="$ac_dir/$ac_prog -c"
2423 if test "${ac_cv_path_install+set}" = set; then
2424 INSTALL=$ac_cv_path_install
2426 # As a last resort, use the slow shell script. We don't cache a
2427 # path for INSTALL within a source directory, because that will
2428 # break other packages using the cache if that directory is
2429 # removed, or if the path is relative.
2430 INSTALL=$ac_install_sh
2433 echo "$as_me:2433: result: $INSTALL" >&5
2434 echo "${ECHO_T}$INSTALL" >&6
2436 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
2437 # It thinks the first close brace ends the variable substitution.
2438 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
2440 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
2442 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
2448 cf_dir=`echo $INSTALL | sed -e 's%/[^/]*$%%'`
2449 test -z "$cf_dir" && cf_dir=.
2450 INSTALL=`cd $cf_dir && pwd`/`echo $INSTALL | sed -e 's%^.*/%%'`
2454 for ac_prog in lint cppcheck splint
2456 # Extract the first word of "$ac_prog", so it can be a program name with args.
2457 set dummy $ac_prog; ac_word=$2
2458 echo "$as_me:2458: checking for $ac_word" >&5
2459 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2460 if test "${ac_cv_prog_LINT+set}" = set; then
2461 echo $ECHO_N "(cached) $ECHO_C" >&6
2463 if test -n "$LINT"; then
2464 ac_cv_prog_LINT="$LINT" # Let the user override the test.
2466 ac_save_IFS=$IFS; IFS=$ac_path_separator
2468 for ac_dir in $ac_dummy; do
2470 test -z "$ac_dir" && ac_dir=.
2471 $as_executable_p "$ac_dir/$ac_word" || continue
2472 ac_cv_prog_LINT="$ac_prog"
2473 echo "$as_me:2473: found $ac_dir/$ac_word" >&5
2479 LINT=$ac_cv_prog_LINT
2480 if test -n "$LINT"; then
2481 echo "$as_me:2481: result: $LINT" >&5
2482 echo "${ECHO_T}$LINT" >&6
2484 echo "$as_me:2484: result: no" >&5
2485 echo "${ECHO_T}no" >&6
2488 test -n "$LINT" && break
2491 echo "$as_me:2491: checking if filesystem supports mixed-case filenames" >&5
2492 echo $ECHO_N "checking if filesystem supports mixed-case filenames... $ECHO_C" >&6
2493 if test "${cf_cv_mixedcase+set}" = set; then
2494 echo $ECHO_N "(cached) $ECHO_C" >&6
2497 if test "$cross_compiling" = yes ; then
2498 case $target_alias in
2499 (*-os2-emx*|*-msdosdjgpp*|*-cygwin*|*-msys*|*-mingw*|*-uwin*)
2507 rm -f conftest CONFTEST
2509 if test -f CONFTEST ; then
2514 rm -f conftest CONFTEST
2518 echo "$as_me:2518: result: $cf_cv_mixedcase" >&5
2519 echo "${ECHO_T}$cf_cv_mixedcase" >&6
2520 test "$cf_cv_mixedcase" = yes &&
2521 cat >>confdefs.h <<\EOF
2522 #define MIXEDCASE_FILENAMES 1
2525 for ac_prog in exctags ctags
2527 # Extract the first word of "$ac_prog", so it can be a program name with args.
2528 set dummy $ac_prog; ac_word=$2
2529 echo "$as_me:2529: checking for $ac_word" >&5
2530 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2531 if test "${ac_cv_prog_CTAGS+set}" = set; then
2532 echo $ECHO_N "(cached) $ECHO_C" >&6
2534 if test -n "$CTAGS"; then
2535 ac_cv_prog_CTAGS="$CTAGS" # Let the user override the test.
2537 ac_save_IFS=$IFS; IFS=$ac_path_separator
2539 for ac_dir in $ac_dummy; do
2541 test -z "$ac_dir" && ac_dir=.
2542 $as_executable_p "$ac_dir/$ac_word" || continue
2543 ac_cv_prog_CTAGS="$ac_prog"
2544 echo "$as_me:2544: found $ac_dir/$ac_word" >&5
2550 CTAGS=$ac_cv_prog_CTAGS
2551 if test -n "$CTAGS"; then
2552 echo "$as_me:2552: result: $CTAGS" >&5
2553 echo "${ECHO_T}$CTAGS" >&6
2555 echo "$as_me:2555: result: no" >&5
2556 echo "${ECHO_T}no" >&6
2559 test -n "$CTAGS" && break
2562 for ac_prog in exetags etags
2564 # Extract the first word of "$ac_prog", so it can be a program name with args.
2565 set dummy $ac_prog; ac_word=$2
2566 echo "$as_me:2566: checking for $ac_word" >&5
2567 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2568 if test "${ac_cv_prog_ETAGS+set}" = set; then
2569 echo $ECHO_N "(cached) $ECHO_C" >&6
2571 if test -n "$ETAGS"; then
2572 ac_cv_prog_ETAGS="$ETAGS" # Let the user override the test.
2574 ac_save_IFS=$IFS; IFS=$ac_path_separator
2576 for ac_dir in $ac_dummy; do
2578 test -z "$ac_dir" && ac_dir=.
2579 $as_executable_p "$ac_dir/$ac_word" || continue
2580 ac_cv_prog_ETAGS="$ac_prog"
2581 echo "$as_me:2581: found $ac_dir/$ac_word" >&5
2587 ETAGS=$ac_cv_prog_ETAGS
2588 if test -n "$ETAGS"; then
2589 echo "$as_me:2589: result: $ETAGS" >&5
2590 echo "${ECHO_T}$ETAGS" >&6
2592 echo "$as_me:2592: result: no" >&5
2593 echo "${ECHO_T}no" >&6
2596 test -n "$ETAGS" && break
2599 # Extract the first word of "${CTAGS:-ctags}", so it can be a program name with args.
2600 set dummy ${CTAGS:-ctags}; ac_word=$2
2601 echo "$as_me:2601: checking for $ac_word" >&5
2602 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2603 if test "${ac_cv_prog_MAKE_LOWER_TAGS+set}" = set; then
2604 echo $ECHO_N "(cached) $ECHO_C" >&6
2606 if test -n "$MAKE_LOWER_TAGS"; then
2607 ac_cv_prog_MAKE_LOWER_TAGS="$MAKE_LOWER_TAGS" # Let the user override the test.
2609 ac_save_IFS=$IFS; IFS=$ac_path_separator
2611 for ac_dir in $ac_dummy; do
2613 test -z "$ac_dir" && ac_dir=.
2614 $as_executable_p "$ac_dir/$ac_word" || continue
2615 ac_cv_prog_MAKE_LOWER_TAGS="yes"
2616 echo "$as_me:2616: found $ac_dir/$ac_word" >&5
2620 test -z "$ac_cv_prog_MAKE_LOWER_TAGS" && ac_cv_prog_MAKE_LOWER_TAGS="no"
2623 MAKE_LOWER_TAGS=$ac_cv_prog_MAKE_LOWER_TAGS
2624 if test -n "$MAKE_LOWER_TAGS"; then
2625 echo "$as_me:2625: result: $MAKE_LOWER_TAGS" >&5
2626 echo "${ECHO_T}$MAKE_LOWER_TAGS" >&6
2628 echo "$as_me:2628: result: no" >&5
2629 echo "${ECHO_T}no" >&6
2632 if test "$cf_cv_mixedcase" = yes ; then
2633 # Extract the first word of "${ETAGS:-etags}", so it can be a program name with args.
2634 set dummy ${ETAGS:-etags}; ac_word=$2
2635 echo "$as_me:2635: checking for $ac_word" >&5
2636 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2637 if test "${ac_cv_prog_MAKE_UPPER_TAGS+set}" = set; then
2638 echo $ECHO_N "(cached) $ECHO_C" >&6
2640 if test -n "$MAKE_UPPER_TAGS"; then
2641 ac_cv_prog_MAKE_UPPER_TAGS="$MAKE_UPPER_TAGS" # Let the user override the test.
2643 ac_save_IFS=$IFS; IFS=$ac_path_separator
2645 for ac_dir in $ac_dummy; do
2647 test -z "$ac_dir" && ac_dir=.
2648 $as_executable_p "$ac_dir/$ac_word" || continue
2649 ac_cv_prog_MAKE_UPPER_TAGS="yes"
2650 echo "$as_me:2650: found $ac_dir/$ac_word" >&5
2654 test -z "$ac_cv_prog_MAKE_UPPER_TAGS" && ac_cv_prog_MAKE_UPPER_TAGS="no"
2657 MAKE_UPPER_TAGS=$ac_cv_prog_MAKE_UPPER_TAGS
2658 if test -n "$MAKE_UPPER_TAGS"; then
2659 echo "$as_me:2659: result: $MAKE_UPPER_TAGS" >&5
2660 echo "${ECHO_T}$MAKE_UPPER_TAGS" >&6
2662 echo "$as_me:2662: result: no" >&5
2663 echo "${ECHO_T}no" >&6
2670 if test "$MAKE_UPPER_TAGS" = yes ; then
2676 if test "$MAKE_LOWER_TAGS" = yes ; then
2682 echo "$as_me:2682: checking if -lm needed for math functions" >&5
2683 echo $ECHO_N "checking if -lm needed for math functions... $ECHO_C" >&6
2684 if test "${cf_cv_need_libm+set}" = set; then
2685 echo $ECHO_N "(cached) $ECHO_C" >&6
2688 cat >conftest.$ac_ext <<_ACEOF
2689 #line 2689 "configure"
2690 #include "confdefs.h"
2699 double x = rand(); printf("result = %g\n", pow(sin(x),x))
2704 rm -f conftest.$ac_objext conftest$ac_exeext
2705 if { (eval echo "$as_me:2705: \"$ac_link\"") >&5
2706 (eval $ac_link) 2>&5
2708 echo "$as_me:2708: \$? = $ac_status" >&5
2709 (exit $ac_status); } &&
2710 { ac_try='test -s conftest$ac_exeext'
2711 { (eval echo "$as_me:2711: \"$ac_try\"") >&5
2714 echo "$as_me:2714: \$? = $ac_status" >&5
2715 (exit $ac_status); }; }; then
2718 echo "$as_me: failed program was:" >&5
2719 cat conftest.$ac_ext >&5
2722 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
2724 echo "$as_me:2724: result: $cf_cv_need_libm" >&5
2725 echo "${ECHO_T}$cf_cv_need_libm" >&6
2726 if test "$cf_cv_need_libm" = yes
2734 CC_SHARED_OPTS=unknown
2735 CPPFLAGS="$CPPFLAGS"
2737 DFT_OBJ_SUBDIR=`pwd|sed -e's:.*/::'`
2738 DFT_UPR_MODEL="NORMAL"
2751 PACKAGE="ncurses-examples"
2757 TINFO_LIBS='$(LIBS_CURSES)'
2758 cf_cv_abi_version=""
2759 cf_cv_rel_version=""
2765 if test "$GCC" = yes
2767 cat > conftest.i <<EOF
2769 #define GCC_PRINTF 0
2774 #ifndef GCC_NORETURN
2775 #define GCC_NORETURN /* nothing */
2778 #define GCC_UNUSED /* nothing */
2781 if test "$GCC" = yes
2783 { echo "$as_me:2783: checking for $CC __attribute__ directives..." >&5
2784 echo "$as_me: checking for $CC __attribute__ directives..." >&6;}
2785 cat > conftest.$ac_ext <<EOF
2786 #line 2786 "${as_me:-configure}"
2787 #include "confdefs.h"
2788 #include "conftest.h"
2789 #include "conftest.i"
2791 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
2793 #define GCC_PRINTFLIKE(fmt,var) /*nothing*/
2796 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
2798 #define GCC_SCANFLIKE(fmt,var) /*nothing*/
2800 extern void wow(char *,...) GCC_SCANFLIKE(1,2);
2801 extern void oops(char *,...) GCC_PRINTFLIKE(1,2) GCC_NORETURN;
2802 extern void foo(void) GCC_NORETURN;
2803 int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { return 0; }
2805 cf_printf_attribute=no
2806 cf_scanf_attribute=no
2807 for cf_attribute in scanf printf unused noreturn
2810 cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
2812 cf_directive="__attribute__(($cf_attribute))"
2813 echo "checking for $CC $cf_directive" 1>&5
2815 case $cf_attribute in
2817 cf_printf_attribute=yes
2818 cat >conftest.h <<EOF
2819 #define GCC_$cf_ATTRIBUTE 1
2823 cf_scanf_attribute=yes
2824 cat >conftest.h <<EOF
2825 #define GCC_$cf_ATTRIBUTE 1
2829 cat >conftest.h <<EOF
2830 #define GCC_$cf_ATTRIBUTE $cf_directive
2835 if { (eval echo "$as_me:2835: \"$ac_compile\"") >&5
2836 (eval $ac_compile) 2>&5
2838 echo "$as_me:2838: \$? = $ac_status" >&5
2839 (exit $ac_status); }; then
2840 test -n "$verbose" && echo "$as_me:2840: result: ... $cf_attribute" >&5
2841 echo "${ECHO_T}... $cf_attribute" >&6
2842 cat conftest.h >>confdefs.h
2843 case $cf_attribute in
2846 cat >>confdefs.h <<EOF
2847 #define GCC_NORETURN $cf_directive
2852 cf_value='/* nothing */'
2853 if test "$cf_printf_attribute" != no ; then
2854 cf_value='__attribute__((format(printf,fmt,var)))'
2856 cat >>confdefs.h <<\EOF
2857 #define GCC_PRINTF 1
2862 cat >>confdefs.h <<EOF
2863 #define GCC_PRINTFLIKE(fmt,var) $cf_value
2868 cf_value='/* nothing */'
2869 if test "$cf_scanf_attribute" != no ; then
2870 cf_value='__attribute__((format(scanf,fmt,var)))'
2872 cat >>confdefs.h <<\EOF
2878 cat >>confdefs.h <<EOF
2879 #define GCC_SCANFLIKE(fmt,var) $cf_value
2885 cat >>confdefs.h <<EOF
2886 #define GCC_UNUSED $cf_directive
2894 fgrep define conftest.i >>confdefs.h
2899 echo "$as_me:2899: checking if you want to work around bogus compiler/loader warnings" >&5
2900 echo $ECHO_N "checking if you want to work around bogus compiler/loader warnings... $ECHO_C" >&6
2902 # Check whether --enable-string-hacks or --disable-string-hacks was given.
2903 if test "${enable_string_hacks+set}" = set; then
2904 enableval="$enable_string_hacks"
2905 with_string_hacks=$enableval
2907 with_string_hacks=no
2909 echo "$as_me:2909: result: $with_string_hacks" >&5
2910 echo "${ECHO_T}$with_string_hacks" >&6
2912 if test "x$with_string_hacks" = "xyes"; then
2914 cat >>confdefs.h <<\EOF
2915 #define USE_STRING_HACKS 1
2918 { echo "$as_me:2918: WARNING: enabling string-hacks to work around bogus compiler/loader warnings" >&5
2919 echo "$as_me: WARNING: enabling string-hacks to work around bogus compiler/loader warnings" >&2;}
2920 echo "$as_me:2920: checking for strlcat" >&5
2921 echo $ECHO_N "checking for strlcat... $ECHO_C" >&6
2922 if test "${ac_cv_func_strlcat+set}" = set; then
2923 echo $ECHO_N "(cached) $ECHO_C" >&6
2925 cat >conftest.$ac_ext <<_ACEOF
2926 #line 2926 "configure"
2927 #include "confdefs.h"
2928 /* System header to define __stub macros and hopefully few prototypes,
2929 which can conflict with char strlcat (); below. */
2931 /* Override any gcc2 internal prototype to avoid an error. */
2935 /* We use char because int might match the return type of a gcc2
2936 builtin and then its argument prototype would still apply. */
2943 /* The GNU C library defines this for functions which it implements
2944 to always fail with ENOSYS. Some functions are actually named
2945 something starting with __ and the normal name is an alias. */
2946 #if defined (__stub_strlcat) || defined (__stub___strlcat)
2949 f = strlcat; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
2956 rm -f conftest.$ac_objext conftest$ac_exeext
2957 if { (eval echo "$as_me:2957: \"$ac_link\"") >&5
2958 (eval $ac_link) 2>&5
2960 echo "$as_me:2960: \$? = $ac_status" >&5
2961 (exit $ac_status); } &&
2962 { ac_try='test -s conftest$ac_exeext'
2963 { (eval echo "$as_me:2963: \"$ac_try\"") >&5
2966 echo "$as_me:2966: \$? = $ac_status" >&5
2967 (exit $ac_status); }; }; then
2968 ac_cv_func_strlcat=yes
2970 echo "$as_me: failed program was:" >&5
2971 cat conftest.$ac_ext >&5
2972 ac_cv_func_strlcat=no
2974 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
2976 echo "$as_me:2976: result: $ac_cv_func_strlcat" >&5
2977 echo "${ECHO_T}$ac_cv_func_strlcat" >&6
2978 if test $ac_cv_func_strlcat = yes; then
2980 cat >>confdefs.h <<\EOF
2981 #define HAVE_STRLCAT 1
2986 echo "$as_me:2986: checking for strlcat in -lbsd" >&5
2987 echo $ECHO_N "checking for strlcat in -lbsd... $ECHO_C" >&6
2988 if test "${ac_cv_lib_bsd_strlcat+set}" = set; then
2989 echo $ECHO_N "(cached) $ECHO_C" >&6
2991 ac_check_lib_save_LIBS=$LIBS
2993 cat >conftest.$ac_ext <<_ACEOF
2994 #line 2994 "configure"
2995 #include "confdefs.h"
2997 /* Override any gcc2 internal prototype to avoid an error. */
3001 /* We use char because int might match the return type of a gcc2
3002 builtin and then its argument prototype would still apply. */
3012 rm -f conftest.$ac_objext conftest$ac_exeext
3013 if { (eval echo "$as_me:3013: \"$ac_link\"") >&5
3014 (eval $ac_link) 2>&5
3016 echo "$as_me:3016: \$? = $ac_status" >&5
3017 (exit $ac_status); } &&
3018 { ac_try='test -s conftest$ac_exeext'
3019 { (eval echo "$as_me:3019: \"$ac_try\"") >&5
3022 echo "$as_me:3022: \$? = $ac_status" >&5
3023 (exit $ac_status); }; }; then
3024 ac_cv_lib_bsd_strlcat=yes
3026 echo "$as_me: failed program was:" >&5
3027 cat conftest.$ac_ext >&5
3028 ac_cv_lib_bsd_strlcat=no
3030 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
3031 LIBS=$ac_check_lib_save_LIBS
3033 echo "$as_me:3033: result: $ac_cv_lib_bsd_strlcat" >&5
3034 echo "${ECHO_T}$ac_cv_lib_bsd_strlcat" >&6
3035 if test $ac_cv_lib_bsd_strlcat = yes; then
3038 # Filter out duplicates - this happens with badly-designed ".pc" files...
3039 for cf_add_1lib in $LIBS
3041 for cf_add_2lib in $cf_add_libs
3043 if test "x$cf_add_1lib" = "x$cf_add_2lib"
3049 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
3053 for ac_header in bsd/string.h
3055 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
3056 echo "$as_me:3056: checking for $ac_header" >&5
3057 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3058 if eval "test \"\${$as_ac_Header+set}\" = set"; then
3059 echo $ECHO_N "(cached) $ECHO_C" >&6
3061 cat >conftest.$ac_ext <<_ACEOF
3062 #line 3062 "configure"
3063 #include "confdefs.h"
3064 #include <$ac_header>
3066 if { (eval echo "$as_me:3066: \"$ac_cpp conftest.$ac_ext\"") >&5
3067 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3069 egrep -v '^ *\+' conftest.er1 >conftest.err
3071 cat conftest.err >&5
3072 echo "$as_me:3072: \$? = $ac_status" >&5
3073 (exit $ac_status); } >/dev/null; then
3074 if test -s conftest.err; then
3075 ac_cpp_err=$ac_c_preproc_warn_flag
3082 if test -z "$ac_cpp_err"; then
3083 eval "$as_ac_Header=yes"
3085 echo "$as_me: failed program was:" >&5
3086 cat conftest.$ac_ext >&5
3087 eval "$as_ac_Header=no"
3089 rm -f conftest.err conftest.$ac_ext
3091 echo "$as_me:3091: result: `eval echo '${'$as_ac_Header'}'`" >&5
3092 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
3093 if test `eval echo '${'$as_ac_Header'}'` = yes; then
3094 cat >>confdefs.h <<EOF
3095 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
3101 cat >>confdefs.h <<\EOF
3102 #define HAVE_STRLCAT 1
3109 for ac_func in strlcpy snprintf
3111 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
3112 echo "$as_me:3112: checking for $ac_func" >&5
3113 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
3114 if eval "test \"\${$as_ac_var+set}\" = set"; then
3115 echo $ECHO_N "(cached) $ECHO_C" >&6
3117 cat >conftest.$ac_ext <<_ACEOF
3118 #line 3118 "configure"
3119 #include "confdefs.h"
3120 /* System header to define __stub macros and hopefully few prototypes,
3121 which can conflict with char $ac_func (); below. */
3123 /* Override any gcc2 internal prototype to avoid an error. */
3127 /* We use char because int might match the return type of a gcc2
3128 builtin and then its argument prototype would still apply. */
3135 /* The GNU C library defines this for functions which it implements
3136 to always fail with ENOSYS. Some functions are actually named
3137 something starting with __ and the normal name is an alias. */
3138 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3141 f = $ac_func; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
3148 rm -f conftest.$ac_objext conftest$ac_exeext
3149 if { (eval echo "$as_me:3149: \"$ac_link\"") >&5
3150 (eval $ac_link) 2>&5
3152 echo "$as_me:3152: \$? = $ac_status" >&5
3153 (exit $ac_status); } &&
3154 { ac_try='test -s conftest$ac_exeext'
3155 { (eval echo "$as_me:3155: \"$ac_try\"") >&5
3158 echo "$as_me:3158: \$? = $ac_status" >&5
3159 (exit $ac_status); }; }; then
3160 eval "$as_ac_var=yes"
3162 echo "$as_me: failed program was:" >&5
3163 cat conftest.$ac_ext >&5
3164 eval "$as_ac_var=no"
3166 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
3168 echo "$as_me:3168: result: `eval echo '${'$as_ac_var'}'`" >&5
3169 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
3170 if test `eval echo '${'$as_ac_var'}'` = yes; then
3171 cat >>confdefs.h <<EOF
3172 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
3181 cf_POSIX_C_SOURCE=199506L
3186 cf_xopen_source="-D_ALL_SOURCE"
3192 cf_xopen_source="-D_APPLE_C_SOURCE"
3195 cf_xopen_source="-D_DARWIN_C_SOURCE"
3198 (freebsd*|dragonfly*)
3199 # 5.x headers associate
3200 # _XOPEN_SOURCE=600 with _POSIX_C_SOURCE=200112L
3201 # _XOPEN_SOURCE=500 with _POSIX_C_SOURCE=199506L
3202 cf_POSIX_C_SOURCE=200112L
3204 cf_xopen_source="-D_BSD_TYPES -D__BSD_VISIBLE -D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
3207 cf_xopen_source="-D_HPUX_SOURCE -D_XOPEN_SOURCE=500"
3210 cf_xopen_source="-D_HPUX_SOURCE"
3213 cf_xopen_source="-D_SGI_SOURCE"
3216 (linux*|uclinux*|gnu*|mint*|k*bsd*-gnu|cygwin)
3218 echo "$as_me:3218: checking if we must define _GNU_SOURCE" >&5
3219 echo $ECHO_N "checking if we must define _GNU_SOURCE... $ECHO_C" >&6
3220 if test "${cf_cv_gnu_source+set}" = set; then
3221 echo $ECHO_N "(cached) $ECHO_C" >&6
3224 cat >conftest.$ac_ext <<_ACEOF
3225 #line 3225 "configure"
3226 #include "confdefs.h"
3227 #include <sys/types.h>
3232 #ifndef _XOPEN_SOURCE
3239 rm -f conftest.$ac_objext
3240 if { (eval echo "$as_me:3240: \"$ac_compile\"") >&5
3241 (eval $ac_compile) 2>&5
3243 echo "$as_me:3243: \$? = $ac_status" >&5
3244 (exit $ac_status); } &&
3245 { ac_try='test -s conftest.$ac_objext'
3246 { (eval echo "$as_me:3246: \"$ac_try\"") >&5
3249 echo "$as_me:3249: \$? = $ac_status" >&5
3250 (exit $ac_status); }; }; then
3253 echo "$as_me: failed program was:" >&5
3254 cat conftest.$ac_ext >&5
3256 CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE"
3257 cat >conftest.$ac_ext <<_ACEOF
3258 #line 3258 "configure"
3259 #include "confdefs.h"
3260 #include <sys/types.h>
3265 #ifdef _XOPEN_SOURCE
3272 rm -f conftest.$ac_objext
3273 if { (eval echo "$as_me:3273: \"$ac_compile\"") >&5
3274 (eval $ac_compile) 2>&5
3276 echo "$as_me:3276: \$? = $ac_status" >&5
3277 (exit $ac_status); } &&
3278 { ac_try='test -s conftest.$ac_objext'
3279 { (eval echo "$as_me:3279: \"$ac_try\"") >&5
3282 echo "$as_me:3282: \$? = $ac_status" >&5
3283 (exit $ac_status); }; }; then
3286 echo "$as_me: failed program was:" >&5
3287 cat conftest.$ac_ext >&5
3288 cf_cv_gnu_source=yes
3290 rm -f conftest.$ac_objext conftest.$ac_ext
3294 rm -f conftest.$ac_objext conftest.$ac_ext
3297 echo "$as_me:3297: result: $cf_cv_gnu_source" >&5
3298 echo "${ECHO_T}$cf_cv_gnu_source" >&6
3300 if test "$cf_cv_gnu_source" = yes
3302 echo "$as_me:3302: checking if we should also define _DEFAULT_SOURCE" >&5
3303 echo $ECHO_N "checking if we should also define _DEFAULT_SOURCE... $ECHO_C" >&6
3304 if test "${cf_cv_default_source+set}" = set; then
3305 echo $ECHO_N "(cached) $ECHO_C" >&6
3308 CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE"
3309 cat >conftest.$ac_ext <<_ACEOF
3310 #line 3310 "configure"
3311 #include "confdefs.h"
3312 #include <sys/types.h>
3317 #ifdef _DEFAULT_SOURCE
3324 rm -f conftest.$ac_objext
3325 if { (eval echo "$as_me:3325: \"$ac_compile\"") >&5
3326 (eval $ac_compile) 2>&5
3328 echo "$as_me:3328: \$? = $ac_status" >&5
3329 (exit $ac_status); } &&
3330 { ac_try='test -s conftest.$ac_objext'
3331 { (eval echo "$as_me:3331: \"$ac_try\"") >&5
3334 echo "$as_me:3334: \$? = $ac_status" >&5
3335 (exit $ac_status); }; }; then
3336 cf_cv_default_source=no
3338 echo "$as_me: failed program was:" >&5
3339 cat conftest.$ac_ext >&5
3340 cf_cv_default_source=yes
3342 rm -f conftest.$ac_objext conftest.$ac_ext
3345 echo "$as_me:3345: result: $cf_cv_default_source" >&5
3346 echo "${ECHO_T}$cf_cv_default_source" >&6
3347 test "$cf_cv_default_source" = yes && CPPFLAGS="$CPPFLAGS -D_DEFAULT_SOURCE"
3352 cf_xopen_source="-D_NETBSD_SOURCE" # POSIX.1-2001 features are ifdef'd with this...
3355 # setting _XOPEN_SOURCE or _POSIX_SOURCE breaks <sys/select.h> and other headers which use u_int / u_short types
3358 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
3360 cf_save_CFLAGS="$CFLAGS"
3361 cf_save_CPPFLAGS="$CPPFLAGS"
3363 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
3364 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3365 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
3367 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
3368 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3369 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
3371 echo "$as_me:3371: checking if we should define _POSIX_C_SOURCE" >&5
3372 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
3373 if test "${cf_cv_posix_c_source+set}" = set; then
3374 echo $ECHO_N "(cached) $ECHO_C" >&6
3377 echo "${as_me:-configure}:3377: testing if the symbol is already defined go no further ..." 1>&5
3379 cat >conftest.$ac_ext <<_ACEOF
3380 #line 3380 "configure"
3381 #include "confdefs.h"
3382 #include <sys/types.h>
3387 #ifndef _POSIX_C_SOURCE
3394 rm -f conftest.$ac_objext
3395 if { (eval echo "$as_me:3395: \"$ac_compile\"") >&5
3396 (eval $ac_compile) 2>&5
3398 echo "$as_me:3398: \$? = $ac_status" >&5
3399 (exit $ac_status); } &&
3400 { ac_try='test -s conftest.$ac_objext'
3401 { (eval echo "$as_me:3401: \"$ac_try\"") >&5
3404 echo "$as_me:3404: \$? = $ac_status" >&5
3405 (exit $ac_status); }; }; then
3406 cf_cv_posix_c_source=no
3408 echo "$as_me: failed program was:" >&5
3409 cat conftest.$ac_ext >&5
3410 cf_want_posix_source=no
3411 case .$cf_POSIX_C_SOURCE in
3413 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
3416 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
3417 cf_want_posix_source=yes
3420 cf_want_posix_source=yes
3423 if test "$cf_want_posix_source" = yes ; then
3424 cat >conftest.$ac_ext <<_ACEOF
3425 #line 3425 "configure"
3426 #include "confdefs.h"
3427 #include <sys/types.h>
3432 #ifdef _POSIX_SOURCE
3439 rm -f conftest.$ac_objext
3440 if { (eval echo "$as_me:3440: \"$ac_compile\"") >&5
3441 (eval $ac_compile) 2>&5
3443 echo "$as_me:3443: \$? = $ac_status" >&5
3444 (exit $ac_status); } &&
3445 { ac_try='test -s conftest.$ac_objext'
3446 { (eval echo "$as_me:3446: \"$ac_try\"") >&5
3449 echo "$as_me:3449: \$? = $ac_status" >&5
3450 (exit $ac_status); }; }; then
3453 echo "$as_me: failed program was:" >&5
3454 cat conftest.$ac_ext >&5
3455 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
3457 rm -f conftest.$ac_objext conftest.$ac_ext
3460 echo "${as_me:-configure}:3460: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
3462 CFLAGS="$cf_trim_CFLAGS"
3463 CPPFLAGS="$cf_trim_CPPFLAGS $cf_cv_posix_c_source"
3465 echo "${as_me:-configure}:3465: testing if the second compile does not leave our definition intact error ..." 1>&5
3467 cat >conftest.$ac_ext <<_ACEOF
3468 #line 3468 "configure"
3469 #include "confdefs.h"
3470 #include <sys/types.h>
3475 #ifndef _POSIX_C_SOURCE
3482 rm -f conftest.$ac_objext
3483 if { (eval echo "$as_me:3483: \"$ac_compile\"") >&5
3484 (eval $ac_compile) 2>&5
3486 echo "$as_me:3486: \$? = $ac_status" >&5
3487 (exit $ac_status); } &&
3488 { ac_try='test -s conftest.$ac_objext'
3489 { (eval echo "$as_me:3489: \"$ac_try\"") >&5
3492 echo "$as_me:3492: \$? = $ac_status" >&5
3493 (exit $ac_status); }; }; then
3496 echo "$as_me: failed program was:" >&5
3497 cat conftest.$ac_ext >&5
3498 cf_cv_posix_c_source=no
3500 rm -f conftest.$ac_objext conftest.$ac_ext
3501 CFLAGS="$cf_save_CFLAGS"
3502 CPPFLAGS="$cf_save_CPPFLAGS"
3505 rm -f conftest.$ac_objext conftest.$ac_ext
3508 echo "$as_me:3508: result: $cf_cv_posix_c_source" >&5
3509 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
3511 if test "$cf_cv_posix_c_source" != no ; then
3512 CFLAGS="$cf_trim_CFLAGS"
3513 CPPFLAGS="$cf_trim_CPPFLAGS"
3518 cf_new_extra_cppflags=
3520 for cf_add_cflags in $cf_cv_posix_c_source
3522 case $cf_fix_cppflags in
3524 case $cf_add_cflags in
3525 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
3526 case $cf_add_cflags in
3528 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3530 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
3531 && test -z "${cf_tst_cflags}" \
3532 && cf_fix_cppflags=yes
3534 if test $cf_fix_cppflags = yes ; then
3536 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3537 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3540 elif test "${cf_tst_cflags}" = "\"'" ; then
3542 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3543 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3553 case $cf_add_cflags in
3555 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3557 CPPFLAGS=`echo "$CPPFLAGS" | \
3558 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3559 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3564 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
3565 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
3572 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
3573 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
3580 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3581 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3583 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
3585 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
3586 && test -z "${cf_tst_cflags}" \
3587 && cf_fix_cppflags=no
3592 if test -n "$cf_new_cflags" ; then
3594 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
3595 CFLAGS="${CFLAGS}$cf_new_cflags"
3599 if test -n "$cf_new_cppflags" ; then
3601 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
3602 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
3606 if test -n "$cf_new_extra_cppflags" ; then
3608 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
3609 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
3617 cf_xopen_source="-D_NETBSD_SOURCE" # setting _XOPEN_SOURCE breaks IPv6 for lynx on NetBSD 1.6, breaks xterm, is not needed for ncursesw
3620 # setting _XOPEN_SOURCE lower than 500 breaks g++ compile with wchar.h, needed for ncursesw
3621 cf_xopen_source="-D_BSD_SOURCE"
3625 # setting _XOPEN_SOURCE breaks xterm on OpenBSD 2.8, is not needed for ncursesw
3628 cf_xopen_source="-D_OSF_SOURCE"
3631 cf_xopen_source="-D_QNX_SOURCE"
3634 # setting _XOPEN_SOURCE breaks Lynx on SCO Unix / OpenServer
3637 cf_xopen_source="-D__EXTENSIONS__"
3638 cf_cv_xopen_source=broken
3640 (sysv4.2uw2.*) # Novell/SCO UnixWare 2.x (tested on 2.1.2)
3646 echo "$as_me:3646: checking if we should define _XOPEN_SOURCE" >&5
3647 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
3648 if test "${cf_cv_xopen_source+set}" = set; then
3649 echo $ECHO_N "(cached) $ECHO_C" >&6
3652 cat >conftest.$ac_ext <<_ACEOF
3653 #line 3653 "configure"
3654 #include "confdefs.h"
3658 #include <sys/types.h>
3664 #ifndef _XOPEN_SOURCE
3671 rm -f conftest.$ac_objext
3672 if { (eval echo "$as_me:3672: \"$ac_compile\"") >&5
3673 (eval $ac_compile) 2>&5
3675 echo "$as_me:3675: \$? = $ac_status" >&5
3676 (exit $ac_status); } &&
3677 { ac_try='test -s conftest.$ac_objext'
3678 { (eval echo "$as_me:3678: \"$ac_try\"") >&5
3681 echo "$as_me:3681: \$? = $ac_status" >&5
3682 (exit $ac_status); }; }; then
3683 cf_cv_xopen_source=no
3685 echo "$as_me: failed program was:" >&5
3686 cat conftest.$ac_ext >&5
3688 CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
3689 cat >conftest.$ac_ext <<_ACEOF
3690 #line 3690 "configure"
3691 #include "confdefs.h"
3695 #include <sys/types.h>
3701 #ifdef _XOPEN_SOURCE
3708 rm -f conftest.$ac_objext
3709 if { (eval echo "$as_me:3709: \"$ac_compile\"") >&5
3710 (eval $ac_compile) 2>&5
3712 echo "$as_me:3712: \$? = $ac_status" >&5
3713 (exit $ac_status); } &&
3714 { ac_try='test -s conftest.$ac_objext'
3715 { (eval echo "$as_me:3715: \"$ac_try\"") >&5
3718 echo "$as_me:3718: \$? = $ac_status" >&5
3719 (exit $ac_status); }; }; then
3720 cf_cv_xopen_source=no
3722 echo "$as_me: failed program was:" >&5
3723 cat conftest.$ac_ext >&5
3724 cf_cv_xopen_source=$cf_XOPEN_SOURCE
3726 rm -f conftest.$ac_objext conftest.$ac_ext
3730 rm -f conftest.$ac_objext conftest.$ac_ext
3733 echo "$as_me:3733: result: $cf_cv_xopen_source" >&5
3734 echo "${ECHO_T}$cf_cv_xopen_source" >&6
3736 if test "$cf_cv_xopen_source" != no ; then
3738 CFLAGS=`echo "$CFLAGS" | \
3739 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3740 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
3742 CPPFLAGS=`echo "$CPPFLAGS" | \
3743 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3744 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
3746 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
3751 cf_new_extra_cppflags=
3753 for cf_add_cflags in $cf_temp_xopen_source
3755 case $cf_fix_cppflags in
3757 case $cf_add_cflags in
3758 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
3759 case $cf_add_cflags in
3761 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3763 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
3764 && test -z "${cf_tst_cflags}" \
3765 && cf_fix_cppflags=yes
3767 if test $cf_fix_cppflags = yes ; then
3769 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3770 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3773 elif test "${cf_tst_cflags}" = "\"'" ; then
3775 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3776 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3786 case $cf_add_cflags in
3788 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3790 CPPFLAGS=`echo "$CPPFLAGS" | \
3791 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3792 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3797 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
3798 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
3805 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
3806 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
3813 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3814 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3816 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
3818 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
3819 && test -z "${cf_tst_cflags}" \
3820 && cf_fix_cppflags=no
3825 if test -n "$cf_new_cflags" ; then
3827 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
3828 CFLAGS="${CFLAGS}$cf_new_cflags"
3832 if test -n "$cf_new_cppflags" ; then
3834 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
3835 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
3839 if test -n "$cf_new_extra_cppflags" ; then
3841 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
3842 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
3848 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
3850 cf_save_CFLAGS="$CFLAGS"
3851 cf_save_CPPFLAGS="$CPPFLAGS"
3853 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
3854 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3855 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
3857 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
3858 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3859 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
3861 echo "$as_me:3861: checking if we should define _POSIX_C_SOURCE" >&5
3862 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
3863 if test "${cf_cv_posix_c_source+set}" = set; then
3864 echo $ECHO_N "(cached) $ECHO_C" >&6
3867 echo "${as_me:-configure}:3867: testing if the symbol is already defined go no further ..." 1>&5
3869 cat >conftest.$ac_ext <<_ACEOF
3870 #line 3870 "configure"
3871 #include "confdefs.h"
3872 #include <sys/types.h>
3877 #ifndef _POSIX_C_SOURCE
3884 rm -f conftest.$ac_objext
3885 if { (eval echo "$as_me:3885: \"$ac_compile\"") >&5
3886 (eval $ac_compile) 2>&5
3888 echo "$as_me:3888: \$? = $ac_status" >&5
3889 (exit $ac_status); } &&
3890 { ac_try='test -s conftest.$ac_objext'
3891 { (eval echo "$as_me:3891: \"$ac_try\"") >&5
3894 echo "$as_me:3894: \$? = $ac_status" >&5
3895 (exit $ac_status); }; }; then
3896 cf_cv_posix_c_source=no
3898 echo "$as_me: failed program was:" >&5
3899 cat conftest.$ac_ext >&5
3900 cf_want_posix_source=no
3901 case .$cf_POSIX_C_SOURCE in
3903 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
3906 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
3907 cf_want_posix_source=yes
3910 cf_want_posix_source=yes
3913 if test "$cf_want_posix_source" = yes ; then
3914 cat >conftest.$ac_ext <<_ACEOF
3915 #line 3915 "configure"
3916 #include "confdefs.h"
3917 #include <sys/types.h>
3922 #ifdef _POSIX_SOURCE
3929 rm -f conftest.$ac_objext
3930 if { (eval echo "$as_me:3930: \"$ac_compile\"") >&5
3931 (eval $ac_compile) 2>&5
3933 echo "$as_me:3933: \$? = $ac_status" >&5
3934 (exit $ac_status); } &&
3935 { ac_try='test -s conftest.$ac_objext'
3936 { (eval echo "$as_me:3936: \"$ac_try\"") >&5
3939 echo "$as_me:3939: \$? = $ac_status" >&5
3940 (exit $ac_status); }; }; then
3943 echo "$as_me: failed program was:" >&5
3944 cat conftest.$ac_ext >&5
3945 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
3947 rm -f conftest.$ac_objext conftest.$ac_ext
3950 echo "${as_me:-configure}:3950: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
3952 CFLAGS="$cf_trim_CFLAGS"
3953 CPPFLAGS="$cf_trim_CPPFLAGS $cf_cv_posix_c_source"
3955 echo "${as_me:-configure}:3955: testing if the second compile does not leave our definition intact error ..." 1>&5
3957 cat >conftest.$ac_ext <<_ACEOF
3958 #line 3958 "configure"
3959 #include "confdefs.h"
3960 #include <sys/types.h>
3965 #ifndef _POSIX_C_SOURCE
3972 rm -f conftest.$ac_objext
3973 if { (eval echo "$as_me:3973: \"$ac_compile\"") >&5
3974 (eval $ac_compile) 2>&5
3976 echo "$as_me:3976: \$? = $ac_status" >&5
3977 (exit $ac_status); } &&
3978 { ac_try='test -s conftest.$ac_objext'
3979 { (eval echo "$as_me:3979: \"$ac_try\"") >&5
3982 echo "$as_me:3982: \$? = $ac_status" >&5
3983 (exit $ac_status); }; }; then
3986 echo "$as_me: failed program was:" >&5
3987 cat conftest.$ac_ext >&5
3988 cf_cv_posix_c_source=no
3990 rm -f conftest.$ac_objext conftest.$ac_ext
3991 CFLAGS="$cf_save_CFLAGS"
3992 CPPFLAGS="$cf_save_CPPFLAGS"
3995 rm -f conftest.$ac_objext conftest.$ac_ext
3998 echo "$as_me:3998: result: $cf_cv_posix_c_source" >&5
3999 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
4001 if test "$cf_cv_posix_c_source" != no ; then
4002 CFLAGS="$cf_trim_CFLAGS"
4003 CPPFLAGS="$cf_trim_CPPFLAGS"
4008 cf_new_extra_cppflags=
4010 for cf_add_cflags in $cf_cv_posix_c_source
4012 case $cf_fix_cppflags in
4014 case $cf_add_cflags in
4015 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4016 case $cf_add_cflags in
4018 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4020 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4021 && test -z "${cf_tst_cflags}" \
4022 && cf_fix_cppflags=yes
4024 if test $cf_fix_cppflags = yes ; then
4026 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4027 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4030 elif test "${cf_tst_cflags}" = "\"'" ; then
4032 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4033 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4043 case $cf_add_cflags in
4045 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4047 CPPFLAGS=`echo "$CPPFLAGS" | \
4048 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4049 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4054 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4055 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4062 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4063 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4070 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4071 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4073 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
4075 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4076 && test -z "${cf_tst_cflags}" \
4077 && cf_fix_cppflags=no
4082 if test -n "$cf_new_cflags" ; then
4084 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4085 CFLAGS="${CFLAGS}$cf_new_cflags"
4089 if test -n "$cf_new_cppflags" ; then
4091 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4092 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4096 if test -n "$cf_new_extra_cppflags" ; then
4098 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4099 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4108 if test -n "$cf_xopen_source" ; then
4113 cf_new_extra_cppflags=
4115 for cf_add_cflags in $cf_xopen_source
4117 case $cf_fix_cppflags in
4119 case $cf_add_cflags in
4120 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4121 case $cf_add_cflags in
4123 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4125 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4126 && test -z "${cf_tst_cflags}" \
4127 && cf_fix_cppflags=yes
4129 if test $cf_fix_cppflags = yes ; then
4131 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4132 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4135 elif test "${cf_tst_cflags}" = "\"'" ; then
4137 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4138 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4148 case $cf_add_cflags in
4150 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4152 CPPFLAGS=`echo "$CPPFLAGS" | \
4153 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4154 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4159 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4160 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4167 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4168 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4175 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4176 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4178 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
4180 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4181 && test -z "${cf_tst_cflags}" \
4182 && cf_fix_cppflags=no
4187 if test -n "$cf_new_cflags" ; then
4188 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
4190 echo "${as_me:-configure}:4190: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
4192 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4193 CFLAGS="${CFLAGS}$cf_new_cflags"
4197 if test -n "$cf_new_cppflags" ; then
4198 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
4200 echo "${as_me:-configure}:4200: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
4202 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4203 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4207 if test -n "$cf_new_extra_cppflags" ; then
4208 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
4210 echo "${as_me:-configure}:4210: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
4212 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4213 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4219 if test -n "$cf_XOPEN_SOURCE" && test -z "$cf_cv_xopen_source" ; then
4220 echo "$as_me:4220: checking if _XOPEN_SOURCE really is set" >&5
4221 echo $ECHO_N "checking if _XOPEN_SOURCE really is set... $ECHO_C" >&6
4222 cat >conftest.$ac_ext <<_ACEOF
4223 #line 4223 "configure"
4224 #include "confdefs.h"
4230 #ifndef _XOPEN_SOURCE
4237 rm -f conftest.$ac_objext
4238 if { (eval echo "$as_me:4238: \"$ac_compile\"") >&5
4239 (eval $ac_compile) 2>&5
4241 echo "$as_me:4241: \$? = $ac_status" >&5
4242 (exit $ac_status); } &&
4243 { ac_try='test -s conftest.$ac_objext'
4244 { (eval echo "$as_me:4244: \"$ac_try\"") >&5
4247 echo "$as_me:4247: \$? = $ac_status" >&5
4248 (exit $ac_status); }; }; then
4249 cf_XOPEN_SOURCE_set=yes
4251 echo "$as_me: failed program was:" >&5
4252 cat conftest.$ac_ext >&5
4253 cf_XOPEN_SOURCE_set=no
4255 rm -f conftest.$ac_objext conftest.$ac_ext
4256 echo "$as_me:4256: result: $cf_XOPEN_SOURCE_set" >&5
4257 echo "${ECHO_T}$cf_XOPEN_SOURCE_set" >&6
4258 if test $cf_XOPEN_SOURCE_set = yes
4260 cat >conftest.$ac_ext <<_ACEOF
4261 #line 4261 "configure"
4262 #include "confdefs.h"
4268 #if (_XOPEN_SOURCE - 0) < $cf_XOPEN_SOURCE
4275 rm -f conftest.$ac_objext
4276 if { (eval echo "$as_me:4276: \"$ac_compile\"") >&5
4277 (eval $ac_compile) 2>&5
4279 echo "$as_me:4279: \$? = $ac_status" >&5
4280 (exit $ac_status); } &&
4281 { ac_try='test -s conftest.$ac_objext'
4282 { (eval echo "$as_me:4282: \"$ac_try\"") >&5
4285 echo "$as_me:4285: \$? = $ac_status" >&5
4286 (exit $ac_status); }; }; then
4287 cf_XOPEN_SOURCE_set_ok=yes
4289 echo "$as_me: failed program was:" >&5
4290 cat conftest.$ac_ext >&5
4291 cf_XOPEN_SOURCE_set_ok=no
4293 rm -f conftest.$ac_objext conftest.$ac_ext
4294 if test $cf_XOPEN_SOURCE_set_ok = no
4296 { echo "$as_me:4296: WARNING: _XOPEN_SOURCE is lower than requested" >&5
4297 echo "$as_me: WARNING: _XOPEN_SOURCE is lower than requested" >&2;}
4301 echo "$as_me:4301: checking if we should define _XOPEN_SOURCE" >&5
4302 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
4303 if test "${cf_cv_xopen_source+set}" = set; then
4304 echo $ECHO_N "(cached) $ECHO_C" >&6
4307 cat >conftest.$ac_ext <<_ACEOF
4308 #line 4308 "configure"
4309 #include "confdefs.h"
4313 #include <sys/types.h>
4319 #ifndef _XOPEN_SOURCE
4326 rm -f conftest.$ac_objext
4327 if { (eval echo "$as_me:4327: \"$ac_compile\"") >&5
4328 (eval $ac_compile) 2>&5
4330 echo "$as_me:4330: \$? = $ac_status" >&5
4331 (exit $ac_status); } &&
4332 { ac_try='test -s conftest.$ac_objext'
4333 { (eval echo "$as_me:4333: \"$ac_try\"") >&5
4336 echo "$as_me:4336: \$? = $ac_status" >&5
4337 (exit $ac_status); }; }; then
4338 cf_cv_xopen_source=no
4340 echo "$as_me: failed program was:" >&5
4341 cat conftest.$ac_ext >&5
4343 CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
4344 cat >conftest.$ac_ext <<_ACEOF
4345 #line 4345 "configure"
4346 #include "confdefs.h"
4350 #include <sys/types.h>
4356 #ifdef _XOPEN_SOURCE
4363 rm -f conftest.$ac_objext
4364 if { (eval echo "$as_me:4364: \"$ac_compile\"") >&5
4365 (eval $ac_compile) 2>&5
4367 echo "$as_me:4367: \$? = $ac_status" >&5
4368 (exit $ac_status); } &&
4369 { ac_try='test -s conftest.$ac_objext'
4370 { (eval echo "$as_me:4370: \"$ac_try\"") >&5
4373 echo "$as_me:4373: \$? = $ac_status" >&5
4374 (exit $ac_status); }; }; then
4375 cf_cv_xopen_source=no
4377 echo "$as_me: failed program was:" >&5
4378 cat conftest.$ac_ext >&5
4379 cf_cv_xopen_source=$cf_XOPEN_SOURCE
4381 rm -f conftest.$ac_objext conftest.$ac_ext
4385 rm -f conftest.$ac_objext conftest.$ac_ext
4388 echo "$as_me:4388: result: $cf_cv_xopen_source" >&5
4389 echo "${ECHO_T}$cf_cv_xopen_source" >&6
4391 if test "$cf_cv_xopen_source" != no ; then
4393 CFLAGS=`echo "$CFLAGS" | \
4394 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
4395 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
4397 CPPFLAGS=`echo "$CPPFLAGS" | \
4398 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
4399 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
4401 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
4406 cf_new_extra_cppflags=
4408 for cf_add_cflags in $cf_temp_xopen_source
4410 case $cf_fix_cppflags in
4412 case $cf_add_cflags in
4413 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4414 case $cf_add_cflags in
4416 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4418 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4419 && test -z "${cf_tst_cflags}" \
4420 && cf_fix_cppflags=yes
4422 if test $cf_fix_cppflags = yes ; then
4424 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4425 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4428 elif test "${cf_tst_cflags}" = "\"'" ; then
4430 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4431 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4441 case $cf_add_cflags in
4443 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4445 CPPFLAGS=`echo "$CPPFLAGS" | \
4446 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4447 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4452 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4453 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4460 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4461 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4468 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4469 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4471 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
4473 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4474 && test -z "${cf_tst_cflags}" \
4475 && cf_fix_cppflags=no
4480 if test -n "$cf_new_cflags" ; then
4482 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4483 CFLAGS="${CFLAGS}$cf_new_cflags"
4487 if test -n "$cf_new_cppflags" ; then
4489 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4490 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4494 if test -n "$cf_new_extra_cppflags" ; then
4496 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4497 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4506 echo "$as_me:4506: checking for signal global datatype" >&5
4507 echo $ECHO_N "checking for signal global datatype... $ECHO_C" >&6
4508 if test "${cf_cv_sig_atomic_t+set}" = set; then
4509 echo $ECHO_N "(cached) $ECHO_C" >&6
4513 "volatile sig_atomic_t" \
4517 cat >conftest.$ac_ext <<_ACEOF
4518 #line 4518 "configure"
4519 #include "confdefs.h"
4521 #include <sys/types.h>
4527 static void handler(int sig)
4534 signal(SIGINT, handler);
4540 rm -f conftest.$ac_objext
4541 if { (eval echo "$as_me:4541: \"$ac_compile\"") >&5
4542 (eval $ac_compile) 2>&5
4544 echo "$as_me:4544: \$? = $ac_status" >&5
4545 (exit $ac_status); } &&
4546 { ac_try='test -s conftest.$ac_objext'
4547 { (eval echo "$as_me:4547: \"$ac_try\"") >&5
4550 echo "$as_me:4550: \$? = $ac_status" >&5
4551 (exit $ac_status); }; }; then
4552 cf_cv_sig_atomic_t=$cf_type
4554 echo "$as_me: failed program was:" >&5
4555 cat conftest.$ac_ext >&5
4556 cf_cv_sig_atomic_t=no
4558 rm -f conftest.$ac_objext conftest.$ac_ext
4559 test "$cf_cv_sig_atomic_t" != no && break
4564 echo "$as_me:4564: result: $cf_cv_sig_atomic_t" >&5
4565 echo "${ECHO_T}$cf_cv_sig_atomic_t" >&6
4566 test "$cf_cv_sig_atomic_t" != no &&
4567 cat >>confdefs.h <<EOF
4568 #define SIG_ATOMIC_T $cf_cv_sig_atomic_t
4571 # Work around breakage on OS X
4573 echo "$as_me:4573: checking if SIGWINCH is defined" >&5
4574 echo $ECHO_N "checking if SIGWINCH is defined... $ECHO_C" >&6
4575 if test "${cf_cv_define_sigwinch+set}" = set; then
4576 echo $ECHO_N "(cached) $ECHO_C" >&6
4579 cat >conftest.$ac_ext <<_ACEOF
4580 #line 4580 "configure"
4581 #include "confdefs.h"
4583 #include <sys/types.h>
4584 #include <sys/signal.h>
4594 rm -f conftest.$ac_objext
4595 if { (eval echo "$as_me:4595: \"$ac_compile\"") >&5
4596 (eval $ac_compile) 2>&5
4598 echo "$as_me:4598: \$? = $ac_status" >&5
4599 (exit $ac_status); } &&
4600 { ac_try='test -s conftest.$ac_objext'
4601 { (eval echo "$as_me:4601: \"$ac_try\"") >&5
4604 echo "$as_me:4604: \$? = $ac_status" >&5
4605 (exit $ac_status); }; }; then
4606 cf_cv_define_sigwinch=yes
4608 echo "$as_me: failed program was:" >&5
4609 cat conftest.$ac_ext >&5
4610 cat >conftest.$ac_ext <<_ACEOF
4611 #line 4611 "configure"
4612 #include "confdefs.h"
4614 #undef _XOPEN_SOURCE
4615 #undef _POSIX_SOURCE
4616 #undef _POSIX_C_SOURCE
4617 #include <sys/types.h>
4618 #include <sys/signal.h>
4628 rm -f conftest.$ac_objext
4629 if { (eval echo "$as_me:4629: \"$ac_compile\"") >&5
4630 (eval $ac_compile) 2>&5
4632 echo "$as_me:4632: \$? = $ac_status" >&5
4633 (exit $ac_status); } &&
4634 { ac_try='test -s conftest.$ac_objext'
4635 { (eval echo "$as_me:4635: \"$ac_try\"") >&5
4638 echo "$as_me:4638: \$? = $ac_status" >&5
4639 (exit $ac_status); }; }; then
4640 cf_cv_define_sigwinch=maybe
4642 echo "$as_me: failed program was:" >&5
4643 cat conftest.$ac_ext >&5
4644 cf_cv_define_sigwinch=no
4646 rm -f conftest.$ac_objext conftest.$ac_ext
4649 rm -f conftest.$ac_objext conftest.$ac_ext
4652 echo "$as_me:4652: result: $cf_cv_define_sigwinch" >&5
4653 echo "${ECHO_T}$cf_cv_define_sigwinch" >&6
4655 if test "$cf_cv_define_sigwinch" = maybe ; then
4656 echo "$as_me:4656: checking for actual SIGWINCH definition" >&5
4657 echo $ECHO_N "checking for actual SIGWINCH definition... $ECHO_C" >&6
4658 if test "${cf_cv_fixup_sigwinch+set}" = set; then
4659 echo $ECHO_N "(cached) $ECHO_C" >&6
4662 cf_cv_fixup_sigwinch=unknown
4664 while test $cf_sigwinch != 1
4666 cat >conftest.$ac_ext <<_ACEOF
4667 #line 4667 "configure"
4668 #include "confdefs.h"
4670 #undef _XOPEN_SOURCE
4671 #undef _POSIX_SOURCE
4672 #undef _POSIX_C_SOURCE
4673 #include <sys/types.h>
4674 #include <sys/signal.h>
4680 #if SIGWINCH != $cf_sigwinch
4688 rm -f conftest.$ac_objext
4689 if { (eval echo "$as_me:4689: \"$ac_compile\"") >&5
4690 (eval $ac_compile) 2>&5
4692 echo "$as_me:4692: \$? = $ac_status" >&5
4693 (exit $ac_status); } &&
4694 { ac_try='test -s conftest.$ac_objext'
4695 { (eval echo "$as_me:4695: \"$ac_try\"") >&5
4698 echo "$as_me:4698: \$? = $ac_status" >&5
4699 (exit $ac_status); }; }; then
4700 cf_cv_fixup_sigwinch=$cf_sigwinch
4703 echo "$as_me: failed program was:" >&5
4704 cat conftest.$ac_ext >&5
4706 rm -f conftest.$ac_objext conftest.$ac_ext
4708 cf_sigwinch=`expr $cf_sigwinch - 1`
4712 echo "$as_me:4712: result: $cf_cv_fixup_sigwinch" >&5
4713 echo "${ECHO_T}$cf_cv_fixup_sigwinch" >&6
4715 if test "$cf_cv_fixup_sigwinch" != unknown ; then
4716 CPPFLAGS="$CPPFLAGS -DSIGWINCH=$cf_cv_fixup_sigwinch"
4720 # Checks for CODESET support.
4722 echo "$as_me:4722: checking for nl_langinfo and CODESET" >&5
4723 echo $ECHO_N "checking for nl_langinfo and CODESET... $ECHO_C" >&6
4724 if test "${am_cv_langinfo_codeset+set}" = set; then
4725 echo $ECHO_N "(cached) $ECHO_C" >&6
4727 cat >conftest.$ac_ext <<_ACEOF
4728 #line 4728 "configure"
4729 #include "confdefs.h"
4730 #include <langinfo.h>
4734 char* cs = nl_langinfo(CODESET);
4739 rm -f conftest.$ac_objext conftest$ac_exeext
4740 if { (eval echo "$as_me:4740: \"$ac_link\"") >&5
4741 (eval $ac_link) 2>&5
4743 echo "$as_me:4743: \$? = $ac_status" >&5
4744 (exit $ac_status); } &&
4745 { ac_try='test -s conftest$ac_exeext'
4746 { (eval echo "$as_me:4746: \"$ac_try\"") >&5
4749 echo "$as_me:4749: \$? = $ac_status" >&5
4750 (exit $ac_status); }; }; then
4751 am_cv_langinfo_codeset=yes
4753 echo "$as_me: failed program was:" >&5
4754 cat conftest.$ac_ext >&5
4755 am_cv_langinfo_codeset=no
4757 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4760 echo "$as_me:4760: result: $am_cv_langinfo_codeset" >&5
4761 echo "${ECHO_T}$am_cv_langinfo_codeset" >&6
4762 if test $am_cv_langinfo_codeset = yes; then
4764 cat >>confdefs.h <<\EOF
4765 #define HAVE_LANGINFO_CODESET 1
4770 echo "$as_me:4770: checking if you want to use pkg-config" >&5
4771 echo $ECHO_N "checking if you want to use pkg-config... $ECHO_C" >&6
4773 # Check whether --with-pkg-config or --without-pkg-config was given.
4774 if test "${with_pkg_config+set}" = set; then
4775 withval="$with_pkg_config"
4776 cf_pkg_config=$withval
4780 echo "$as_me:4780: result: $cf_pkg_config" >&5
4781 echo "${ECHO_T}$cf_pkg_config" >&6
4783 case $cf_pkg_config in
4789 if test -n "$ac_tool_prefix"; then
4790 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
4791 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
4792 echo "$as_me:4792: checking for $ac_word" >&5
4793 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4794 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then
4795 echo $ECHO_N "(cached) $ECHO_C" >&6
4799 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
4802 ac_save_IFS=$IFS; IFS=$ac_path_separator
4804 for ac_dir in $ac_dummy; do
4806 test -z "$ac_dir" && ac_dir=.
4807 if $as_executable_p "$ac_dir/$ac_word"; then
4808 ac_cv_path_PKG_CONFIG="$ac_dir/$ac_word"
4809 echo "$as_me:4809: found $ac_dir/$ac_word" >&5
4817 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
4819 if test -n "$PKG_CONFIG"; then
4820 echo "$as_me:4820: result: $PKG_CONFIG" >&5
4821 echo "${ECHO_T}$PKG_CONFIG" >&6
4823 echo "$as_me:4823: result: no" >&5
4824 echo "${ECHO_T}no" >&6
4828 if test -z "$ac_cv_path_PKG_CONFIG"; then
4829 ac_pt_PKG_CONFIG=$PKG_CONFIG
4830 # Extract the first word of "pkg-config", so it can be a program name with args.
4831 set dummy pkg-config; ac_word=$2
4832 echo "$as_me:4832: checking for $ac_word" >&5
4833 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4834 if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then
4835 echo $ECHO_N "(cached) $ECHO_C" >&6
4837 case $ac_pt_PKG_CONFIG in
4839 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
4842 ac_save_IFS=$IFS; IFS=$ac_path_separator
4844 for ac_dir in $ac_dummy; do
4846 test -z "$ac_dir" && ac_dir=.
4847 if $as_executable_p "$ac_dir/$ac_word"; then
4848 ac_cv_path_ac_pt_PKG_CONFIG="$ac_dir/$ac_word"
4849 echo "$as_me:4849: found $ac_dir/$ac_word" >&5
4854 test -z "$ac_cv_path_ac_pt_PKG_CONFIG" && ac_cv_path_ac_pt_PKG_CONFIG="none"
4858 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
4860 if test -n "$ac_pt_PKG_CONFIG"; then
4861 echo "$as_me:4861: result: $ac_pt_PKG_CONFIG" >&5
4862 echo "${ECHO_T}$ac_pt_PKG_CONFIG" >&6
4864 echo "$as_me:4864: result: no" >&5
4865 echo "${ECHO_T}no" >&6
4868 PKG_CONFIG=$ac_pt_PKG_CONFIG
4870 PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
4879 test -z "$PKG_CONFIG" && PKG_CONFIG=none
4880 if test "$PKG_CONFIG" != none ; then
4882 if test "x$prefix" != xNONE; then
4883 cf_path_syntax="$prefix"
4885 cf_path_syntax="$ac_default_prefix"
4888 case ".$PKG_CONFIG" in
4893 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
4895 (.\${*prefix}*|.\${*dir}*)
4896 eval PKG_CONFIG="$PKG_CONFIG"
4897 case ".$PKG_CONFIG" in
4899 PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
4904 PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
4907 { { echo "$as_me:4907: error: expected a pathname, not \"$PKG_CONFIG\"" >&5
4908 echo "$as_me: error: expected a pathname, not \"$PKG_CONFIG\"" >&2;}
4909 { (exit 1); exit 1; }; }
4913 elif test "x$cf_pkg_config" != xno ; then
4914 { echo "$as_me:4914: WARNING: pkg-config is not installed" >&5
4915 echo "$as_me: WARNING: pkg-config is not installed" >&2;}
4918 echo "$as_me:4918: checking if you want to see long compiling messages" >&5
4919 echo $ECHO_N "checking if you want to see long compiling messages... $ECHO_C" >&6
4921 # Check whether --enable-echo or --disable-echo was given.
4922 if test "${enable_echo+set}" = set; then
4923 enableval="$enable_echo"
4924 test "$enableval" != no && enableval=yes
4925 if test "$enableval" != "yes" ; then
4928 ECHO_LD='@echo linking $@;'
4929 RULE_CC='@echo compiling $<'
4930 SHOW_CC='@echo compiling $@'
4952 echo "$as_me:4952: result: $enableval" >&5
4953 echo "${ECHO_T}$enableval" >&6
4955 echo "$as_me:4955: checking for ncurses wrap-prefix" >&5
4956 echo $ECHO_N "checking for ncurses wrap-prefix... $ECHO_C" >&6
4958 # Check whether --with-ncurses-wrap-prefix or --without-ncurses-wrap-prefix was given.
4959 if test "${with_ncurses_wrap_prefix+set}" = set; then
4960 withval="$with_ncurses_wrap_prefix"
4961 NCURSES_WRAP_PREFIX=$withval
4963 NCURSES_WRAP_PREFIX=_nc_
4965 echo "$as_me:4965: result: $NCURSES_WRAP_PREFIX" >&5
4966 echo "${ECHO_T}$NCURSES_WRAP_PREFIX" >&6
4968 echo "$as_me:4968: checking if you want to check for wide-character functions" >&5
4969 echo $ECHO_N "checking if you want to check for wide-character functions... $ECHO_C" >&6
4971 # Check whether --enable-widec or --disable-widec was given.
4972 if test "${enable_widec+set}" = set; then
4973 enableval="$enable_widec"
4974 test "$enableval" != no && enableval=yes
4975 if test "$enableval" != "yes" ; then
4985 echo "$as_me:4985: result: $cf_enable_widec" >&5
4986 echo "${ECHO_T}$cf_enable_widec" >&6
4988 echo "$as_me:4988: checking for specific curses-directory" >&5
4989 echo $ECHO_N "checking for specific curses-directory... $ECHO_C" >&6
4991 # Check whether --with-curses-dir or --without-curses-dir was given.
4992 if test "${with_curses_dir+set}" = set; then
4993 withval="$with_curses_dir"
4994 cf_cv_curses_dir=$withval
4998 echo "$as_me:4998: result: $cf_cv_curses_dir" >&5
4999 echo "${ECHO_T}$cf_cv_curses_dir" >&6
5001 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
5004 if test "x$prefix" != xNONE; then
5005 cf_path_syntax="$prefix"
5007 cf_path_syntax="$ac_default_prefix"
5015 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
5017 (.\${*prefix}*|.\${*dir}*)
5018 eval withval="$withval"
5021 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
5026 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
5029 { { echo "$as_me:5029: error: expected a pathname, not \"$withval\"" >&5
5030 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
5031 { (exit 1); exit 1; }; }
5035 if test -d "$cf_cv_curses_dir"
5038 if test -n "$cf_cv_curses_dir/include" ; then
5039 for cf_add_incdir in $cf_cv_curses_dir/include
5041 while test $cf_add_incdir != /usr/include
5043 if test -d $cf_add_incdir
5046 if test -n "$CFLAGS$CPPFLAGS" ; then
5047 # a loop is needed to ensure we can add subdirs of existing dirs
5048 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
5049 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
5050 cf_have_incdir=yes; break
5055 if test "$cf_have_incdir" = no ; then
5056 if test "$cf_add_incdir" = /usr/local/include ; then
5057 if test "$GCC" = yes
5059 cf_save_CPPFLAGS=$CPPFLAGS
5060 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
5061 cat >conftest.$ac_ext <<_ACEOF
5062 #line 5062 "configure"
5063 #include "confdefs.h"
5073 rm -f conftest.$ac_objext
5074 if { (eval echo "$as_me:5074: \"$ac_compile\"") >&5
5075 (eval $ac_compile) 2>&5
5077 echo "$as_me:5077: \$? = $ac_status" >&5
5078 (exit $ac_status); } &&
5079 { ac_try='test -s conftest.$ac_objext'
5080 { (eval echo "$as_me:5080: \"$ac_try\"") >&5
5083 echo "$as_me:5083: \$? = $ac_status" >&5
5084 (exit $ac_status); }; }; then
5087 echo "$as_me: failed program was:" >&5
5088 cat conftest.$ac_ext >&5
5091 rm -f conftest.$ac_objext conftest.$ac_ext
5092 CPPFLAGS=$cf_save_CPPFLAGS
5097 if test "$cf_have_incdir" = no ; then
5098 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
5100 echo "${as_me:-configure}:5100: testing adding $cf_add_incdir to include-path ..." 1>&5
5102 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
5104 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
5105 test "$cf_top_incdir" = "$cf_add_incdir" && break
5106 cf_add_incdir="$cf_top_incdir"
5117 if test -n "$cf_cv_curses_dir/lib" ; then
5118 for cf_add_libdir in $cf_cv_curses_dir/lib
5120 if test $cf_add_libdir = /usr/lib ; then
5122 elif test -d $cf_add_libdir
5125 if test -n "$LDFLAGS$LIBS" ; then
5126 # a loop is needed to ensure we can add subdirs of existing dirs
5127 for cf_test_libdir in $LDFLAGS $LIBS ; do
5128 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
5129 cf_have_libdir=yes; break
5133 if test "$cf_have_libdir" = no ; then
5134 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
5136 echo "${as_me:-configure}:5136: testing adding $cf_add_libdir to library-path ..." 1>&5
5138 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
5149 echo "$as_me:5149: checking for specified curses library type" >&5
5150 echo $ECHO_N "checking for specified curses library type... $ECHO_C" >&6
5152 # Check whether --with-screen or --without-screen was given.
5153 if test "${with_screen+set}" = set; then
5154 withval="$with_screen"
5155 cf_cv_screen=$withval
5158 # Check whether --with-ncursesw or --without-ncursesw was given.
5159 if test "${with_ncursesw+set}" = set; then
5160 withval="$with_ncursesw"
5161 cf_cv_screen=ncursesw
5164 # Check whether --with-ncurses or --without-ncurses was given.
5165 if test "${with_ncurses+set}" = set; then
5166 withval="$with_ncurses"
5167 cf_cv_screen=ncurses
5170 # Check whether --with-pdcurses or --without-pdcurses was given.
5171 if test "${with_pdcurses+set}" = set; then
5172 withval="$with_pdcurses"
5173 cf_cv_screen=pdcurses
5176 # Check whether --with-curses-colr or --without-curses-colr was given.
5177 if test "${with_curses_colr+set}" = set; then
5178 withval="$with_curses_colr"
5179 cf_cv_screen=curses_colr
5182 # Check whether --with-curses-5lib or --without-curses-5lib was given.
5183 if test "${with_curses_5lib+set}" = set; then
5184 withval="$with_curses_5lib"
5185 cf_cv_screen=curses_5lib
5193 echo "$as_me:5193: result: $cf_cv_screen" >&5
5194 echo "${ECHO_T}$cf_cv_screen" >&6
5196 case $cf_cv_screen in
5199 echo "$as_me:5199: checking for extra include directories" >&5
5200 echo $ECHO_N "checking for extra include directories... $ECHO_C" >&6
5201 if test "${cf_cv_curses_incdir+set}" = set; then
5202 echo $ECHO_N "(cached) $ECHO_C" >&6
5205 cf_cv_curses_incdir=no
5208 if test "x$cf_cv_screen" = "xcurses_colr"
5210 test -d /usr/include/curses_colr && \
5211 cf_cv_curses_incdir="-I/usr/include/curses_colr"
5215 if test "x$cf_cv_screen" = "xcurses_5lib"
5217 test -d /usr/5lib && \
5218 test -d /usr/5include && \
5219 cf_cv_curses_incdir="-I/usr/5include"
5225 echo "$as_me:5225: result: $cf_cv_curses_incdir" >&5
5226 echo "${ECHO_T}$cf_cv_curses_incdir" >&6
5227 test "$cf_cv_curses_incdir" != no && CPPFLAGS="$CPPFLAGS $cf_cv_curses_incdir"
5229 echo "$as_me:5229: checking if we have identified curses headers" >&5
5230 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
5231 if test "${cf_cv_ncurses_header+set}" = set; then
5232 echo $ECHO_N "(cached) $ECHO_C" >&6
5235 cf_cv_ncurses_header=none
5238 curses.h ncurses/ncurses.h ncurses/curses.h
5240 cat >conftest.$ac_ext <<_ACEOF
5241 #line 5241 "configure"
5242 #include "confdefs.h"
5243 #include <${cf_header}>
5247 initscr(); tgoto("?", 0,0)
5252 rm -f conftest.$ac_objext
5253 if { (eval echo "$as_me:5253: \"$ac_compile\"") >&5
5254 (eval $ac_compile) 2>&5
5256 echo "$as_me:5256: \$? = $ac_status" >&5
5257 (exit $ac_status); } &&
5258 { ac_try='test -s conftest.$ac_objext'
5259 { (eval echo "$as_me:5259: \"$ac_try\"") >&5
5262 echo "$as_me:5262: \$? = $ac_status" >&5
5263 (exit $ac_status); }; }; then
5264 cf_cv_ncurses_header=$cf_header; break
5266 echo "$as_me: failed program was:" >&5
5267 cat conftest.$ac_ext >&5
5269 rm -f conftest.$ac_objext conftest.$ac_ext
5273 echo "$as_me:5273: result: $cf_cv_ncurses_header" >&5
5274 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
5276 if test "$cf_cv_ncurses_header" = none ; then
5277 { { echo "$as_me:5277: error: No curses header-files found" >&5
5278 echo "$as_me: error: No curses header-files found" >&2;}
5279 { (exit 1); exit 1; }; }
5282 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
5284 for ac_header in $cf_cv_ncurses_header
5286 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
5287 echo "$as_me:5287: checking for $ac_header" >&5
5288 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5289 if eval "test \"\${$as_ac_Header+set}\" = set"; then
5290 echo $ECHO_N "(cached) $ECHO_C" >&6
5292 cat >conftest.$ac_ext <<_ACEOF
5293 #line 5293 "configure"
5294 #include "confdefs.h"
5295 #include <$ac_header>
5297 if { (eval echo "$as_me:5297: \"$ac_cpp conftest.$ac_ext\"") >&5
5298 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
5300 egrep -v '^ *\+' conftest.er1 >conftest.err
5302 cat conftest.err >&5
5303 echo "$as_me:5303: \$? = $ac_status" >&5
5304 (exit $ac_status); } >/dev/null; then
5305 if test -s conftest.err; then
5306 ac_cpp_err=$ac_c_preproc_warn_flag
5313 if test -z "$ac_cpp_err"; then
5314 eval "$as_ac_Header=yes"
5316 echo "$as_me: failed program was:" >&5
5317 cat conftest.$ac_ext >&5
5318 eval "$as_ac_Header=no"
5320 rm -f conftest.err conftest.$ac_ext
5322 echo "$as_me:5322: result: `eval echo '${'$as_ac_Header'}'`" >&5
5323 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
5324 if test `eval echo '${'$as_ac_Header'}'` = yes; then
5325 cat >>confdefs.h <<EOF
5326 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
5332 echo "$as_me:5332: checking for terminfo header" >&5
5333 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
5334 if test "${cf_cv_term_header+set}" = set; then
5335 echo $ECHO_N "(cached) $ECHO_C" >&6
5338 case ${cf_cv_ncurses_header} in
5339 (*/ncurses.h|*/ncursesw.h)
5340 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
5343 cf_term_header=term.h
5347 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
5349 cat >conftest.$ac_ext <<_ACEOF
5350 #line 5350 "configure"
5351 #include "confdefs.h"
5353 #include <${cf_cv_ncurses_header:-curses.h}>
5359 int x = auto_left_margin
5364 rm -f conftest.$ac_objext
5365 if { (eval echo "$as_me:5365: \"$ac_compile\"") >&5
5366 (eval $ac_compile) 2>&5
5368 echo "$as_me:5368: \$? = $ac_status" >&5
5369 (exit $ac_status); } &&
5370 { ac_try='test -s conftest.$ac_objext'
5371 { (eval echo "$as_me:5371: \"$ac_try\"") >&5
5374 echo "$as_me:5374: \$? = $ac_status" >&5
5375 (exit $ac_status); }; }; then
5377 cf_cv_term_header="$cf_test"
5379 echo "$as_me: failed program was:" >&5
5380 cat conftest.$ac_ext >&5
5382 cf_cv_term_header=unknown
5385 rm -f conftest.$ac_objext conftest.$ac_ext
5386 test "$cf_cv_term_header" != unknown && break
5390 echo "$as_me:5390: result: $cf_cv_term_header" >&5
5391 echo "${ECHO_T}$cf_cv_term_header" >&6
5393 # Set definitions to allow ifdef'ing to accommodate subdirectories
5395 case $cf_cv_term_header in
5398 cat >>confdefs.h <<\EOF
5399 #define HAVE_TERM_H 1
5405 case $cf_cv_term_header in
5408 cat >>confdefs.h <<\EOF
5409 #define HAVE_NCURSES_TERM_H 1
5415 cat >>confdefs.h <<\EOF
5416 #define HAVE_NCURSESW_TERM_H 1
5422 echo "$as_me:5422: checking for ncurses version" >&5
5423 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
5424 if test "${cf_cv_ncurses_version+set}" = set; then
5425 echo $ECHO_N "(cached) $ECHO_C" >&6
5428 cf_cv_ncurses_version=no
5431 if test "$cross_compiling" = yes; then
5433 # This will not work if the preprocessor splits the line after the
5434 # Autoconf token. The 'unproto' program does that.
5435 cat > conftest.$ac_ext <<EOF
5436 #include <${cf_cv_ncurses_header:-curses.h}>
5438 #ifdef NCURSES_VERSION
5439 Autoconf NCURSES_VERSION
5447 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
5448 { (eval echo "$as_me:5448: \"$cf_try\"") >&5
5451 echo "$as_me:5451: \$? = $ac_status" >&5
5452 (exit $ac_status); }
5453 if test -f conftest.out ; then
5454 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
5455 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
5460 cat >conftest.$ac_ext <<_ACEOF
5461 #line 5461 "configure"
5462 #include "confdefs.h"
5464 #include <${cf_cv_ncurses_header:-curses.h}>
5468 FILE *fp = fopen("$cf_tempfile", "w");
5469 #ifdef NCURSES_VERSION
5470 # ifdef NCURSES_VERSION_PATCH
5471 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
5473 fprintf(fp, "%s\n", NCURSES_VERSION);
5477 fprintf(fp, "old\n");
5482 ${cf_cv_main_return:-return}(0);
5485 rm -f conftest$ac_exeext
5486 if { (eval echo "$as_me:5486: \"$ac_link\"") >&5
5487 (eval $ac_link) 2>&5
5489 echo "$as_me:5489: \$? = $ac_status" >&5
5490 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5491 { (eval echo "$as_me:5491: \"$ac_try\"") >&5
5494 echo "$as_me:5494: \$? = $ac_status" >&5
5495 (exit $ac_status); }; }; then
5497 cf_cv_ncurses_version=`cat $cf_tempfile`
5499 echo "$as_me: program exited with status $ac_status" >&5
5500 echo "$as_me: failed program was:" >&5
5501 cat conftest.$ac_ext >&5
5503 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
5508 echo "$as_me:5508: result: $cf_cv_ncurses_version" >&5
5509 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
5510 test "$cf_cv_ncurses_version" = no ||
5511 cat >>confdefs.h <<\EOF
5515 echo "$as_me:5515: checking if we have identified curses libraries" >&5
5516 echo $ECHO_N "checking if we have identified curses libraries... $ECHO_C" >&6
5517 cat >conftest.$ac_ext <<_ACEOF
5518 #line 5518 "configure"
5519 #include "confdefs.h"
5520 #include <${cf_cv_ncurses_header:-curses.h}>
5524 initscr(); tgoto("?", 0,0)
5529 rm -f conftest.$ac_objext conftest$ac_exeext
5530 if { (eval echo "$as_me:5530: \"$ac_link\"") >&5
5531 (eval $ac_link) 2>&5
5533 echo "$as_me:5533: \$? = $ac_status" >&5
5534 (exit $ac_status); } &&
5535 { ac_try='test -s conftest$ac_exeext'
5536 { (eval echo "$as_me:5536: \"$ac_try\"") >&5
5539 echo "$as_me:5539: \$? = $ac_status" >&5
5540 (exit $ac_status); }; }; then
5543 echo "$as_me: failed program was:" >&5
5544 cat conftest.$ac_ext >&5
5547 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5548 echo "$as_me:5548: result: $cf_result" >&5
5549 echo "${ECHO_T}$cf_result" >&6
5551 if test "$cf_result" = no ; then
5554 echo "$as_me:5554: checking for tgoto in -lmytinfo" >&5
5555 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
5556 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
5557 echo $ECHO_N "(cached) $ECHO_C" >&6
5559 ac_check_lib_save_LIBS=$LIBS
5560 LIBS="-lmytinfo $LIBS"
5561 cat >conftest.$ac_ext <<_ACEOF
5562 #line 5562 "configure"
5563 #include "confdefs.h"
5565 /* Override any gcc2 internal prototype to avoid an error. */
5569 /* We use char because int might match the return type of a gcc2
5570 builtin and then its argument prototype would still apply. */
5580 rm -f conftest.$ac_objext conftest$ac_exeext
5581 if { (eval echo "$as_me:5581: \"$ac_link\"") >&5
5582 (eval $ac_link) 2>&5
5584 echo "$as_me:5584: \$? = $ac_status" >&5
5585 (exit $ac_status); } &&
5586 { ac_try='test -s conftest$ac_exeext'
5587 { (eval echo "$as_me:5587: \"$ac_try\"") >&5
5590 echo "$as_me:5590: \$? = $ac_status" >&5
5591 (exit $ac_status); }; }; then
5592 ac_cv_lib_mytinfo_tgoto=yes
5594 echo "$as_me: failed program was:" >&5
5595 cat conftest.$ac_ext >&5
5596 ac_cv_lib_mytinfo_tgoto=no
5598 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5599 LIBS=$ac_check_lib_save_LIBS
5601 echo "$as_me:5601: result: $ac_cv_lib_mytinfo_tgoto" >&5
5602 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
5603 if test $ac_cv_lib_mytinfo_tgoto = yes; then
5605 cf_add_libs="-lmytinfo"
5606 # Filter out duplicates - this happens with badly-designed ".pc" files...
5607 for cf_add_1lib in $LIBS
5609 for cf_add_2lib in $cf_add_libs
5611 if test "x$cf_add_1lib" = "x$cf_add_2lib"
5617 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
5625 # Looking at HPUX 10.20, the Hcurses library is the oldest (1997), cur_colr
5626 # next (1998), and xcurses "newer" (2000). There is no header file for
5627 # Hcurses; the subdirectory curses_colr has the headers (curses.h and
5628 # term.h) for cur_colr
5629 if test "x$cf_cv_screen" = "xcurses_colr"
5631 echo "$as_me:5631: checking for initscr in -lcur_colr" >&5
5632 echo $ECHO_N "checking for initscr in -lcur_colr... $ECHO_C" >&6
5633 if test "${ac_cv_lib_cur_colr_initscr+set}" = set; then
5634 echo $ECHO_N "(cached) $ECHO_C" >&6
5636 ac_check_lib_save_LIBS=$LIBS
5637 LIBS="-lcur_colr $LIBS"
5638 cat >conftest.$ac_ext <<_ACEOF
5639 #line 5639 "configure"
5640 #include "confdefs.h"
5642 /* Override any gcc2 internal prototype to avoid an error. */
5646 /* We use char because int might match the return type of a gcc2
5647 builtin and then its argument prototype would still apply. */
5657 rm -f conftest.$ac_objext conftest$ac_exeext
5658 if { (eval echo "$as_me:5658: \"$ac_link\"") >&5
5659 (eval $ac_link) 2>&5
5661 echo "$as_me:5661: \$? = $ac_status" >&5
5662 (exit $ac_status); } &&
5663 { ac_try='test -s conftest$ac_exeext'
5664 { (eval echo "$as_me:5664: \"$ac_try\"") >&5
5667 echo "$as_me:5667: \$? = $ac_status" >&5
5668 (exit $ac_status); }; }; then
5669 ac_cv_lib_cur_colr_initscr=yes
5671 echo "$as_me: failed program was:" >&5
5672 cat conftest.$ac_ext >&5
5673 ac_cv_lib_cur_colr_initscr=no
5675 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5676 LIBS=$ac_check_lib_save_LIBS
5678 echo "$as_me:5678: result: $ac_cv_lib_cur_colr_initscr" >&5
5679 echo "${ECHO_T}$ac_cv_lib_cur_colr_initscr" >&6
5680 if test $ac_cv_lib_cur_colr_initscr = yes; then
5682 cf_add_libs="-lcur_colr"
5683 # Filter out duplicates - this happens with badly-designed ".pc" files...
5684 for cf_add_1lib in $LIBS
5686 for cf_add_2lib in $cf_add_libs
5688 if test "x$cf_add_1lib" = "x$cf_add_2lib"
5694 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
5698 ac_cv_func_initscr=yes
5702 echo "$as_me:5702: checking for initscr in -lHcurses" >&5
5703 echo $ECHO_N "checking for initscr in -lHcurses... $ECHO_C" >&6
5704 if test "${ac_cv_lib_Hcurses_initscr+set}" = set; then
5705 echo $ECHO_N "(cached) $ECHO_C" >&6
5707 ac_check_lib_save_LIBS=$LIBS
5708 LIBS="-lHcurses $LIBS"
5709 cat >conftest.$ac_ext <<_ACEOF
5710 #line 5710 "configure"
5711 #include "confdefs.h"
5713 /* Override any gcc2 internal prototype to avoid an error. */
5717 /* We use char because int might match the return type of a gcc2
5718 builtin and then its argument prototype would still apply. */
5728 rm -f conftest.$ac_objext conftest$ac_exeext
5729 if { (eval echo "$as_me:5729: \"$ac_link\"") >&5
5730 (eval $ac_link) 2>&5
5732 echo "$as_me:5732: \$? = $ac_status" >&5
5733 (exit $ac_status); } &&
5734 { ac_try='test -s conftest$ac_exeext'
5735 { (eval echo "$as_me:5735: \"$ac_try\"") >&5
5738 echo "$as_me:5738: \$? = $ac_status" >&5
5739 (exit $ac_status); }; }; then
5740 ac_cv_lib_Hcurses_initscr=yes
5742 echo "$as_me: failed program was:" >&5
5743 cat conftest.$ac_ext >&5
5744 ac_cv_lib_Hcurses_initscr=no
5746 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5747 LIBS=$ac_check_lib_save_LIBS
5749 echo "$as_me:5749: result: $ac_cv_lib_Hcurses_initscr" >&5
5750 echo "${ECHO_T}$ac_cv_lib_Hcurses_initscr" >&6
5751 if test $ac_cv_lib_Hcurses_initscr = yes; then
5753 # HP's header uses __HP_CURSES, but user claims _HP_CURSES.
5755 cf_add_libs="-lHcurses"
5756 # Filter out duplicates - this happens with badly-designed ".pc" files...
5757 for cf_add_1lib in $LIBS
5759 for cf_add_2lib in $cf_add_libs
5761 if test "x$cf_add_1lib" = "x$cf_add_2lib"
5767 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
5771 CPPFLAGS="$CPPFLAGS -D__HP_CURSES -D_HP_CURSES"
5772 ac_cv_func_initscr=yes
5781 case `arch 2>/dev/null` in
5786 if test -n "/lib64" ; then
5787 for cf_add_libdir in /lib64
5789 if test $cf_add_libdir = /usr/lib ; then
5791 elif test -d $cf_add_libdir
5794 if test -n "$LDFLAGS$LIBS" ; then
5795 # a loop is needed to ensure we can add subdirs of existing dirs
5796 for cf_test_libdir in $LDFLAGS $LIBS ; do
5797 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
5798 cf_have_libdir=yes; break
5802 if test "$cf_have_libdir" = no ; then
5803 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
5805 echo "${as_me:-configure}:5805: testing adding $cf_add_libdir to library-path ..." 1>&5
5807 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
5815 if test -n "/lib" ; then
5816 for cf_add_libdir in /lib
5818 if test $cf_add_libdir = /usr/lib ; then
5820 elif test -d $cf_add_libdir
5823 if test -n "$LDFLAGS$LIBS" ; then
5824 # a loop is needed to ensure we can add subdirs of existing dirs
5825 for cf_test_libdir in $LDFLAGS $LIBS ; do
5826 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
5827 cf_have_libdir=yes; break
5831 if test "$cf_have_libdir" = no ; then
5832 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
5834 echo "${as_me:-configure}:5834: testing adding $cf_add_libdir to library-path ..." 1>&5
5836 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
5846 if test -n "/lib" ; then
5847 for cf_add_libdir in /lib
5849 if test $cf_add_libdir = /usr/lib ; then
5851 elif test -d $cf_add_libdir
5854 if test -n "$LDFLAGS$LIBS" ; then
5855 # a loop is needed to ensure we can add subdirs of existing dirs
5856 for cf_test_libdir in $LDFLAGS $LIBS ; do
5857 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
5858 cf_have_libdir=yes; break
5862 if test "$cf_have_libdir" = no ; then
5863 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
5865 echo "${as_me:-configure}:5865: testing adding $cf_add_libdir to library-path ..." 1>&5
5867 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
5877 if test "x$cf_cv_screen" = "xcurses_5lib"
5879 if test -d /usr/5lib ; then
5881 if test -n "/usr/5lib" ; then
5882 for cf_add_libdir in /usr/5lib
5884 if test $cf_add_libdir = /usr/lib ; then
5886 elif test -d $cf_add_libdir
5889 if test -n "$LDFLAGS$LIBS" ; then
5890 # a loop is needed to ensure we can add subdirs of existing dirs
5891 for cf_test_libdir in $LDFLAGS $LIBS ; do
5892 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
5893 cf_have_libdir=yes; break
5897 if test "$cf_have_libdir" = no ; then
5898 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
5900 echo "${as_me:-configure}:5900: testing adding $cf_add_libdir to library-path ..." 1>&5
5902 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
5908 cf_add_libs="-lcurses -ltermcap"
5909 # Filter out duplicates - this happens with badly-designed ".pc" files...
5910 for cf_add_1lib in $LIBS
5912 for cf_add_2lib in $cf_add_libs
5914 if test "x$cf_add_1lib" = "x$cf_add_2lib"
5920 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
5926 ac_cv_func_initscr=yes
5930 if test ".$ac_cv_func_initscr" != .yes ; then
5931 cf_save_LIBS="$LIBS"
5933 if test ".${cf_cv_ncurses_version:-no}" != .no
5935 cf_check_list="ncurses curses cursesX"
5937 cf_check_list="cursesX curses ncurses"
5940 # Check for library containing tgoto. Do this before curses library
5941 # because it may be needed to link the test-case for initscr.
5942 if test "x$cf_term_lib" = x
5944 echo "$as_me:5944: checking for tgoto" >&5
5945 echo $ECHO_N "checking for tgoto... $ECHO_C" >&6
5946 if test "${ac_cv_func_tgoto+set}" = set; then
5947 echo $ECHO_N "(cached) $ECHO_C" >&6
5949 cat >conftest.$ac_ext <<_ACEOF
5950 #line 5950 "configure"
5951 #include "confdefs.h"
5952 /* System header to define __stub macros and hopefully few prototypes,
5953 which can conflict with char tgoto (); below. */
5955 /* Override any gcc2 internal prototype to avoid an error. */
5959 /* We use char because int might match the return type of a gcc2
5960 builtin and then its argument prototype would still apply. */
5967 /* The GNU C library defines this for functions which it implements
5968 to always fail with ENOSYS. Some functions are actually named
5969 something starting with __ and the normal name is an alias. */
5970 #if defined (__stub_tgoto) || defined (__stub___tgoto)
5973 f = tgoto; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
5980 rm -f conftest.$ac_objext conftest$ac_exeext
5981 if { (eval echo "$as_me:5981: \"$ac_link\"") >&5
5982 (eval $ac_link) 2>&5
5984 echo "$as_me:5984: \$? = $ac_status" >&5
5985 (exit $ac_status); } &&
5986 { ac_try='test -s conftest$ac_exeext'
5987 { (eval echo "$as_me:5987: \"$ac_try\"") >&5
5990 echo "$as_me:5990: \$? = $ac_status" >&5
5991 (exit $ac_status); }; }; then
5992 ac_cv_func_tgoto=yes
5994 echo "$as_me: failed program was:" >&5
5995 cat conftest.$ac_ext >&5
5998 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6000 echo "$as_me:6000: result: $ac_cv_func_tgoto" >&5
6001 echo "${ECHO_T}$ac_cv_func_tgoto" >&6
6002 if test $ac_cv_func_tgoto = yes; then
6003 cf_term_lib=predefined
6006 for cf_term_lib in $cf_check_list otermcap termcap tinfo termlib unknown
6008 as_ac_Lib=`echo "ac_cv_lib_$cf_term_lib''_tgoto" | $as_tr_sh`
6009 echo "$as_me:6009: checking for tgoto in -l$cf_term_lib" >&5
6010 echo $ECHO_N "checking for tgoto in -l$cf_term_lib... $ECHO_C" >&6
6011 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
6012 echo $ECHO_N "(cached) $ECHO_C" >&6
6014 ac_check_lib_save_LIBS=$LIBS
6015 LIBS="-l$cf_term_lib $LIBS"
6016 cat >conftest.$ac_ext <<_ACEOF
6017 #line 6017 "configure"
6018 #include "confdefs.h"
6020 /* Override any gcc2 internal prototype to avoid an error. */
6024 /* We use char because int might match the return type of a gcc2
6025 builtin and then its argument prototype would still apply. */
6035 rm -f conftest.$ac_objext conftest$ac_exeext
6036 if { (eval echo "$as_me:6036: \"$ac_link\"") >&5
6037 (eval $ac_link) 2>&5
6039 echo "$as_me:6039: \$? = $ac_status" >&5
6040 (exit $ac_status); } &&
6041 { ac_try='test -s conftest$ac_exeext'
6042 { (eval echo "$as_me:6042: \"$ac_try\"") >&5
6045 echo "$as_me:6045: \$? = $ac_status" >&5
6046 (exit $ac_status); }; }; then
6047 eval "$as_ac_Lib=yes"
6049 echo "$as_me: failed program was:" >&5
6050 cat conftest.$ac_ext >&5
6051 eval "$as_ac_Lib=no"
6053 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6054 LIBS=$ac_check_lib_save_LIBS
6056 echo "$as_me:6056: result: `eval echo '${'$as_ac_Lib'}'`" >&5
6057 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
6058 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
6060 : ${cf_nculib_root:=$cf_term_lib}
6071 # Check for library containing initscr
6072 test "$cf_term_lib" != predefined && test "$cf_term_lib" != unknown && LIBS="-l$cf_term_lib $cf_save_LIBS"
6073 if test "x$cf_curs_lib" = x
6075 for cf_curs_lib in $cf_check_list xcurses jcurses pdcurses unknown
6077 LIBS="-l$cf_curs_lib $cf_save_LIBS"
6078 if test "$cf_term_lib" = unknown || test "$cf_term_lib" = "$cf_curs_lib" ; then
6079 echo "$as_me:6079: checking if we can link with $cf_curs_lib library" >&5
6080 echo $ECHO_N "checking if we can link with $cf_curs_lib library... $ECHO_C" >&6
6081 cat >conftest.$ac_ext <<_ACEOF
6082 #line 6082 "configure"
6083 #include "confdefs.h"
6084 #include <${cf_cv_ncurses_header:-curses.h}>
6093 rm -f conftest.$ac_objext conftest$ac_exeext
6094 if { (eval echo "$as_me:6094: \"$ac_link\"") >&5
6095 (eval $ac_link) 2>&5
6097 echo "$as_me:6097: \$? = $ac_status" >&5
6098 (exit $ac_status); } &&
6099 { ac_try='test -s conftest$ac_exeext'
6100 { (eval echo "$as_me:6100: \"$ac_try\"") >&5
6103 echo "$as_me:6103: \$? = $ac_status" >&5
6104 (exit $ac_status); }; }; then
6107 echo "$as_me: failed program was:" >&5
6108 cat conftest.$ac_ext >&5
6111 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6112 echo "$as_me:6112: result: $cf_result" >&5
6113 echo "${ECHO_T}$cf_result" >&6
6114 test $cf_result = yes && break
6115 elif test "$cf_curs_lib" = "$cf_term_lib" ; then
6117 elif test "$cf_term_lib" != predefined ; then
6118 echo "$as_me:6118: checking if we need both $cf_curs_lib and $cf_term_lib libraries" >&5
6119 echo $ECHO_N "checking if we need both $cf_curs_lib and $cf_term_lib libraries... $ECHO_C" >&6
6120 cat >conftest.$ac_ext <<_ACEOF
6121 #line 6121 "configure"
6122 #include "confdefs.h"
6123 #include <${cf_cv_ncurses_header:-curses.h}>
6127 initscr(); tgoto((char *)0, 0, 0);
6132 rm -f conftest.$ac_objext conftest$ac_exeext
6133 if { (eval echo "$as_me:6133: \"$ac_link\"") >&5
6134 (eval $ac_link) 2>&5
6136 echo "$as_me:6136: \$? = $ac_status" >&5
6137 (exit $ac_status); } &&
6138 { ac_try='test -s conftest$ac_exeext'
6139 { (eval echo "$as_me:6139: \"$ac_try\"") >&5
6142 echo "$as_me:6142: \$? = $ac_status" >&5
6143 (exit $ac_status); }; }; then
6146 echo "$as_me: failed program was:" >&5
6147 cat conftest.$ac_ext >&5
6149 LIBS="-l$cf_curs_lib -l$cf_term_lib $cf_save_LIBS"
6150 cat >conftest.$ac_ext <<_ACEOF
6151 #line 6151 "configure"
6152 #include "confdefs.h"
6153 #include <${cf_cv_ncurses_header:-curses.h}>
6162 rm -f conftest.$ac_objext conftest$ac_exeext
6163 if { (eval echo "$as_me:6163: \"$ac_link\"") >&5
6164 (eval $ac_link) 2>&5
6166 echo "$as_me:6166: \$? = $ac_status" >&5
6167 (exit $ac_status); } &&
6168 { ac_try='test -s conftest$ac_exeext'
6169 { (eval echo "$as_me:6169: \"$ac_try\"") >&5
6172 echo "$as_me:6172: \$? = $ac_status" >&5
6173 (exit $ac_status); }; }; then
6176 echo "$as_me: failed program was:" >&5
6177 cat conftest.$ac_ext >&5
6180 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6183 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6184 echo "$as_me:6184: result: $cf_result" >&5
6185 echo "${ECHO_T}$cf_result" >&6
6186 test $cf_result != error && break
6190 test $cf_curs_lib = unknown && { { echo "$as_me:6190: error: no curses library found" >&5
6191 echo "$as_me: error: no curses library found" >&2;}
6192 { (exit 1); exit 1; }; }
6199 echo "$as_me:6199: checking for multibyte character support" >&5
6200 echo $ECHO_N "checking for multibyte character support... $ECHO_C" >&6
6201 if test "${cf_cv_utf8_lib+set}" = set; then
6202 echo $ECHO_N "(cached) $ECHO_C" >&6
6205 cf_save_LIBS="$LIBS"
6206 cat >conftest.$ac_ext <<_ACEOF
6207 #line 6207 "configure"
6208 #include "confdefs.h"
6219 rm -f conftest.$ac_objext conftest$ac_exeext
6220 if { (eval echo "$as_me:6220: \"$ac_link\"") >&5
6221 (eval $ac_link) 2>&5
6223 echo "$as_me:6223: \$? = $ac_status" >&5
6224 (exit $ac_status); } &&
6225 { ac_try='test -s conftest$ac_exeext'
6226 { (eval echo "$as_me:6226: \"$ac_try\"") >&5
6229 echo "$as_me:6229: \$? = $ac_status" >&5
6230 (exit $ac_status); }; }; then
6233 echo "$as_me: failed program was:" >&5
6234 cat conftest.$ac_ext >&5
6236 # If the linkage is not already in the $CPPFLAGS/$LDFLAGS configuration, these
6237 # will be set on completion of the AC_TRY_LINK below.
6238 cf_cv_header_path_utf8=
6239 cf_cv_library_path_utf8=
6241 echo "${as_me:-configure}:6241: testing Starting FIND_LINKAGE(utf8,) ..." 1>&5
6243 cf_save_LIBS="$LIBS"
6245 cat >conftest.$ac_ext <<_ACEOF
6246 #line 6246 "configure"
6247 #include "confdefs.h"
6249 #include <libutf8.h>
6258 rm -f conftest.$ac_objext conftest$ac_exeext
6259 if { (eval echo "$as_me:6259: \"$ac_link\"") >&5
6260 (eval $ac_link) 2>&5
6262 echo "$as_me:6262: \$? = $ac_status" >&5
6263 (exit $ac_status); } &&
6264 { ac_try='test -s conftest$ac_exeext'
6265 { (eval echo "$as_me:6265: \"$ac_try\"") >&5
6268 echo "$as_me:6268: \$? = $ac_status" >&5
6269 (exit $ac_status); }; }; then
6271 cf_cv_find_linkage_utf8=yes
6272 cf_cv_header_path_utf8=/usr/include
6273 cf_cv_library_path_utf8=/usr/lib
6276 echo "$as_me: failed program was:" >&5
6277 cat conftest.$ac_ext >&5
6279 LIBS="-lutf8 $cf_save_LIBS"
6281 cat >conftest.$ac_ext <<_ACEOF
6282 #line 6282 "configure"
6283 #include "confdefs.h"
6285 #include <libutf8.h>
6294 rm -f conftest.$ac_objext conftest$ac_exeext
6295 if { (eval echo "$as_me:6295: \"$ac_link\"") >&5
6296 (eval $ac_link) 2>&5
6298 echo "$as_me:6298: \$? = $ac_status" >&5
6299 (exit $ac_status); } &&
6300 { ac_try='test -s conftest$ac_exeext'
6301 { (eval echo "$as_me:6301: \"$ac_try\"") >&5
6304 echo "$as_me:6304: \$? = $ac_status" >&5
6305 (exit $ac_status); }; }; then
6307 cf_cv_find_linkage_utf8=yes
6308 cf_cv_header_path_utf8=/usr/include
6309 cf_cv_library_path_utf8=/usr/lib
6310 cf_cv_library_file_utf8="-lutf8"
6313 echo "$as_me: failed program was:" >&5
6314 cat conftest.$ac_ext >&5
6316 cf_cv_find_linkage_utf8=no
6317 LIBS="$cf_save_LIBS"
6319 test -n "$verbose" && echo " find linkage for utf8 library" 1>&6
6321 echo "${as_me:-configure}:6321: testing find linkage for utf8 library ..." 1>&5
6323 echo "${as_me:-configure}:6323: testing Searching for headers in FIND_LINKAGE(utf8,) ..." 1>&5
6325 cf_save_CPPFLAGS="$CPPFLAGS"
6326 cf_test_CPPFLAGS="$CPPFLAGS"
6330 # collect the current set of include-directories from compiler flags
6331 cf_header_path_list=""
6332 if test -n "${CFLAGS}${CPPFLAGS}" ; then
6333 for cf_header_path in $CPPFLAGS $CFLAGS
6335 case $cf_header_path in
6337 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
6339 test "x$cf_header_path" != "xNONE" && \
6340 test -d "$cf_header_path" && \
6342 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
6343 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
6344 test -d $cf_header_path/include/utf8 && cf_search="$cf_search $cf_header_path/include/utf8"
6345 test -d $cf_header_path/include/utf8/include && cf_search="$cf_search $cf_header_path/include/utf8/include"
6346 test -d $cf_header_path/utf8/include && cf_search="$cf_search $cf_header_path/utf8/include"
6347 test -d $cf_header_path/utf8/include/utf8 && cf_search="$cf_search $cf_header_path/utf8/include/utf8"
6350 cf_header_path_list="$cf_header_path_list $cf_search"
6356 # add the variations for the package we are looking for
6360 test "x$prefix" != "xNONE" && \
6361 test -d "$prefix" && \
6363 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
6364 test -d $prefix/include && cf_search="$cf_search $prefix/include"
6365 test -d $prefix/include/utf8 && cf_search="$cf_search $prefix/include/utf8"
6366 test -d $prefix/include/utf8/include && cf_search="$cf_search $prefix/include/utf8/include"
6367 test -d $prefix/utf8/include && cf_search="$cf_search $prefix/utf8/include"
6368 test -d $prefix/utf8/include/utf8 && cf_search="$cf_search $prefix/utf8/include/utf8"
6371 for cf_subdir_prefix in \
6380 test "x$cf_subdir_prefix" != "x$prefix" && \
6381 test -d "$cf_subdir_prefix" && \
6382 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
6383 test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
6384 test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include"
6385 test -d $cf_subdir_prefix/include/utf8 && cf_search="$cf_search $cf_subdir_prefix/include/utf8"
6386 test -d $cf_subdir_prefix/include/utf8/include && cf_search="$cf_search $cf_subdir_prefix/include/utf8/include"
6387 test -d $cf_subdir_prefix/utf8/include && cf_search="$cf_search $cf_subdir_prefix/utf8/include"
6388 test -d $cf_subdir_prefix/utf8/include/utf8 && cf_search="$cf_search $cf_subdir_prefix/utf8/include/utf8"
6393 test "$includedir" != NONE && \
6394 test "$includedir" != "/usr/include" && \
6395 test -d "$includedir" && {
6396 test -d $includedir && cf_search="$cf_search $includedir"
6397 test -d $includedir/utf8 && cf_search="$cf_search $includedir/utf8"
6400 test "$oldincludedir" != NONE && \
6401 test "$oldincludedir" != "/usr/include" && \
6402 test -d "$oldincludedir" && {
6403 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
6404 test -d $oldincludedir/utf8 && cf_search="$cf_search $oldincludedir/utf8"
6407 cf_search="$cf_search $cf_header_path_list"
6409 for cf_cv_header_path_utf8 in $cf_search
6411 if test -d $cf_cv_header_path_utf8 ; then
6412 test -n "$verbose" && echo " ... testing $cf_cv_header_path_utf8" 1>&6
6414 echo "${as_me:-configure}:6414: testing ... testing $cf_cv_header_path_utf8 ..." 1>&5
6416 CPPFLAGS="$cf_save_CPPFLAGS -I$cf_cv_header_path_utf8"
6417 cat >conftest.$ac_ext <<_ACEOF
6418 #line 6418 "configure"
6419 #include "confdefs.h"
6421 #include <libutf8.h>
6430 rm -f conftest.$ac_objext
6431 if { (eval echo "$as_me:6431: \"$ac_compile\"") >&5
6432 (eval $ac_compile) 2>&5
6434 echo "$as_me:6434: \$? = $ac_status" >&5
6435 (exit $ac_status); } &&
6436 { ac_try='test -s conftest.$ac_objext'
6437 { (eval echo "$as_me:6437: \"$ac_try\"") >&5
6440 echo "$as_me:6440: \$? = $ac_status" >&5
6441 (exit $ac_status); }; }; then
6443 test -n "$verbose" && echo " ... found utf8 headers in $cf_cv_header_path_utf8" 1>&6
6445 echo "${as_me:-configure}:6445: testing ... found utf8 headers in $cf_cv_header_path_utf8 ..." 1>&5
6447 cf_cv_find_linkage_utf8=maybe
6448 cf_test_CPPFLAGS="$CPPFLAGS"
6451 echo "$as_me: failed program was:" >&5
6452 cat conftest.$ac_ext >&5
6454 CPPFLAGS="$cf_save_CPPFLAGS"
6457 rm -f conftest.$ac_objext conftest.$ac_ext
6461 if test "$cf_cv_find_linkage_utf8" = maybe ; then
6463 echo "${as_me:-configure}:6463: testing Searching for utf8 library in FIND_LINKAGE(utf8,) ..." 1>&5
6465 cf_save_LIBS="$LIBS"
6466 cf_save_LDFLAGS="$LDFLAGS"
6468 if test "$cf_cv_find_linkage_utf8" != yes ; then
6471 cf_library_path_list=""
6472 if test -n "${LDFLAGS}${LIBS}" ; then
6473 for cf_library_path in $LDFLAGS $LIBS
6475 case $cf_library_path in
6477 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
6479 test "x$cf_library_path" != "xNONE" && \
6480 test -d "$cf_library_path" && \
6482 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
6483 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
6484 test -d $cf_library_path/lib/utf8 && cf_search="$cf_search $cf_library_path/lib/utf8"
6485 test -d $cf_library_path/lib/utf8/lib && cf_search="$cf_search $cf_library_path/lib/utf8/lib"
6486 test -d $cf_library_path/utf8/lib && cf_search="$cf_search $cf_library_path/utf8/lib"
6487 test -d $cf_library_path/utf8/lib/utf8 && cf_search="$cf_search $cf_library_path/utf8/lib/utf8"
6490 cf_library_path_list="$cf_library_path_list $cf_search"
6498 test "x$prefix" != "xNONE" && \
6499 test -d "$prefix" && \
6501 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
6502 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
6503 test -d $prefix/lib/utf8 && cf_search="$cf_search $prefix/lib/utf8"
6504 test -d $prefix/lib/utf8/lib && cf_search="$cf_search $prefix/lib/utf8/lib"
6505 test -d $prefix/utf8/lib && cf_search="$cf_search $prefix/utf8/lib"
6506 test -d $prefix/utf8/lib/utf8 && cf_search="$cf_search $prefix/utf8/lib/utf8"
6509 for cf_subdir_prefix in \
6518 test "x$cf_subdir_prefix" != "x$prefix" && \
6519 test -d "$cf_subdir_prefix" && \
6520 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
6521 test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
6522 test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib"
6523 test -d $cf_subdir_prefix/lib/utf8 && cf_search="$cf_search $cf_subdir_prefix/lib/utf8"
6524 test -d $cf_subdir_prefix/lib/utf8/lib && cf_search="$cf_search $cf_subdir_prefix/lib/utf8/lib"
6525 test -d $cf_subdir_prefix/utf8/lib && cf_search="$cf_search $cf_subdir_prefix/utf8/lib"
6526 test -d $cf_subdir_prefix/utf8/lib/utf8 && cf_search="$cf_search $cf_subdir_prefix/utf8/lib/utf8"
6531 cf_search="$cf_library_path_list $cf_search"
6533 for cf_cv_library_path_utf8 in $cf_search
6535 if test -d $cf_cv_library_path_utf8 ; then
6536 test -n "$verbose" && echo " ... testing $cf_cv_library_path_utf8" 1>&6
6538 echo "${as_me:-configure}:6538: testing ... testing $cf_cv_library_path_utf8 ..." 1>&5
6540 CPPFLAGS="$cf_test_CPPFLAGS"
6541 LIBS="-lutf8 $cf_save_LIBS"
6542 LDFLAGS="$cf_save_LDFLAGS -L$cf_cv_library_path_utf8"
6543 cat >conftest.$ac_ext <<_ACEOF
6544 #line 6544 "configure"
6545 #include "confdefs.h"
6547 #include <libutf8.h>
6556 rm -f conftest.$ac_objext conftest$ac_exeext
6557 if { (eval echo "$as_me:6557: \"$ac_link\"") >&5
6558 (eval $ac_link) 2>&5
6560 echo "$as_me:6560: \$? = $ac_status" >&5
6561 (exit $ac_status); } &&
6562 { ac_try='test -s conftest$ac_exeext'
6563 { (eval echo "$as_me:6563: \"$ac_try\"") >&5
6566 echo "$as_me:6566: \$? = $ac_status" >&5
6567 (exit $ac_status); }; }; then
6569 test -n "$verbose" && echo " ... found utf8 library in $cf_cv_library_path_utf8" 1>&6
6571 echo "${as_me:-configure}:6571: testing ... found utf8 library in $cf_cv_library_path_utf8 ..." 1>&5
6573 cf_cv_find_linkage_utf8=yes
6574 cf_cv_library_file_utf8="-lutf8"
6577 echo "$as_me: failed program was:" >&5
6578 cat conftest.$ac_ext >&5
6580 CPPFLAGS="$cf_save_CPPFLAGS"
6581 LIBS="$cf_save_LIBS"
6582 LDFLAGS="$cf_save_LDFLAGS"
6585 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6588 CPPFLAGS="$cf_save_CPPFLAGS"
6589 LDFLAGS="$cf_save_LDFLAGS"
6593 cf_cv_find_linkage_utf8=no
6597 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6600 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6602 LIBS="$cf_save_LIBS"
6604 if test "$cf_cv_find_linkage_utf8" = yes ; then
6605 cf_cv_utf8_lib=add-on
6611 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6613 echo "$as_me:6613: result: $cf_cv_utf8_lib" >&5
6614 echo "${ECHO_T}$cf_cv_utf8_lib" >&6
6616 # HAVE_LIBUTF8_H is used by ncurses if curses.h is shared between
6618 if test "$cf_cv_utf8_lib" = "add-on" ; then
6620 cat >>confdefs.h <<\EOF
6621 #define HAVE_LIBUTF8_H 1
6624 if test -n "$cf_cv_header_path_utf8" ; then
6625 for cf_add_incdir in $cf_cv_header_path_utf8
6627 while test $cf_add_incdir != /usr/include
6629 if test -d $cf_add_incdir
6632 if test -n "$CFLAGS$CPPFLAGS" ; then
6633 # a loop is needed to ensure we can add subdirs of existing dirs
6634 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
6635 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
6636 cf_have_incdir=yes; break
6641 if test "$cf_have_incdir" = no ; then
6642 if test "$cf_add_incdir" = /usr/local/include ; then
6643 if test "$GCC" = yes
6645 cf_save_CPPFLAGS=$CPPFLAGS
6646 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6647 cat >conftest.$ac_ext <<_ACEOF
6648 #line 6648 "configure"
6649 #include "confdefs.h"
6659 rm -f conftest.$ac_objext
6660 if { (eval echo "$as_me:6660: \"$ac_compile\"") >&5
6661 (eval $ac_compile) 2>&5
6663 echo "$as_me:6663: \$? = $ac_status" >&5
6664 (exit $ac_status); } &&
6665 { ac_try='test -s conftest.$ac_objext'
6666 { (eval echo "$as_me:6666: \"$ac_try\"") >&5
6669 echo "$as_me:6669: \$? = $ac_status" >&5
6670 (exit $ac_status); }; }; then
6673 echo "$as_me: failed program was:" >&5
6674 cat conftest.$ac_ext >&5
6677 rm -f conftest.$ac_objext conftest.$ac_ext
6678 CPPFLAGS=$cf_save_CPPFLAGS
6683 if test "$cf_have_incdir" = no ; then
6684 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
6686 echo "${as_me:-configure}:6686: testing adding $cf_add_incdir to include-path ..." 1>&5
6688 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6690 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
6691 test "$cf_top_incdir" = "$cf_add_incdir" && break
6692 cf_add_incdir="$cf_top_incdir"
6703 if test -n "$cf_cv_library_path_utf8" ; then
6704 for cf_add_libdir in $cf_cv_library_path_utf8
6706 if test $cf_add_libdir = /usr/lib ; then
6708 elif test -d $cf_add_libdir
6711 if test -n "$LDFLAGS$LIBS" ; then
6712 # a loop is needed to ensure we can add subdirs of existing dirs
6713 for cf_test_libdir in $LDFLAGS $LIBS ; do
6714 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
6715 cf_have_libdir=yes; break
6719 if test "$cf_have_libdir" = no ; then
6720 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
6722 echo "${as_me:-configure}:6722: testing adding $cf_add_libdir to library-path ..." 1>&5
6724 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
6730 cf_add_libs="$cf_cv_library_file_utf8"
6731 # Filter out duplicates - this happens with badly-designed ".pc" files...
6732 for cf_add_1lib in $LIBS
6734 for cf_add_2lib in $cf_add_libs
6736 if test "x$cf_add_1lib" = "x$cf_add_2lib"
6742 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
6748 cf_ncuconfig_root=$cf_cv_screen
6749 cf_have_ncuconfig=no
6751 if test "x${PKG_CONFIG:=none}" != xnone; then
6752 echo "$as_me:6752: checking pkg-config for $cf_ncuconfig_root" >&5
6753 echo $ECHO_N "checking pkg-config for $cf_ncuconfig_root... $ECHO_C" >&6
6754 if "$PKG_CONFIG" --exists $cf_ncuconfig_root ; then
6755 echo "$as_me:6755: result: yes" >&5
6756 echo "${ECHO_T}yes" >&6
6758 echo "$as_me:6758: checking if the $cf_ncuconfig_root package files work" >&5
6759 echo $ECHO_N "checking if the $cf_ncuconfig_root package files work... $ECHO_C" >&6
6760 cf_have_ncuconfig=unknown
6762 cf_save_CPPFLAGS="$CPPFLAGS"
6763 cf_save_LIBS="$LIBS"
6765 CPPFLAGS="$CPPFLAGS `$PKG_CONFIG --cflags $cf_ncuconfig_root`"
6767 cf_add_libs="`$PKG_CONFIG --libs $cf_ncuconfig_root`"
6768 # Filter out duplicates - this happens with badly-designed ".pc" files...
6769 for cf_add_1lib in $LIBS
6771 for cf_add_2lib in $cf_add_libs
6773 if test "x$cf_add_1lib" = "x$cf_add_2lib"
6779 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
6783 cat >conftest.$ac_ext <<_ACEOF
6784 #line 6784 "configure"
6785 #include "confdefs.h"
6786 #include <${cf_cv_ncurses_header:-curses.h}>
6790 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
6795 rm -f conftest.$ac_objext conftest$ac_exeext
6796 if { (eval echo "$as_me:6796: \"$ac_link\"") >&5
6797 (eval $ac_link) 2>&5
6799 echo "$as_me:6799: \$? = $ac_status" >&5
6800 (exit $ac_status); } &&
6801 { ac_try='test -s conftest$ac_exeext'
6802 { (eval echo "$as_me:6802: \"$ac_try\"") >&5
6805 echo "$as_me:6805: \$? = $ac_status" >&5
6806 (exit $ac_status); }; }; then
6807 if test "$cross_compiling" = yes; then
6808 cf_have_ncuconfig=maybe
6810 cat >conftest.$ac_ext <<_ACEOF
6811 #line 6811 "configure"
6812 #include "confdefs.h"
6813 #include <${cf_cv_ncurses_header:-curses.h}>
6815 { char *xx = curses_version(); return (xx == 0); }
6817 rm -f conftest$ac_exeext
6818 if { (eval echo "$as_me:6818: \"$ac_link\"") >&5
6819 (eval $ac_link) 2>&5
6821 echo "$as_me:6821: \$? = $ac_status" >&5
6822 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
6823 { (eval echo "$as_me:6823: \"$ac_try\"") >&5
6826 echo "$as_me:6826: \$? = $ac_status" >&5
6827 (exit $ac_status); }; }; then
6828 cf_have_ncuconfig=yes
6830 echo "$as_me: program exited with status $ac_status" >&5
6831 echo "$as_me: failed program was:" >&5
6832 cat conftest.$ac_ext >&5
6833 cf_have_ncuconfig=no
6835 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6838 echo "$as_me: failed program was:" >&5
6839 cat conftest.$ac_ext >&5
6840 cf_have_ncuconfig=no
6842 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6843 echo "$as_me:6843: result: $cf_have_ncuconfig" >&5
6844 echo "${ECHO_T}$cf_have_ncuconfig" >&6
6845 test "$cf_have_ncuconfig" = maybe && cf_have_ncuconfig=yes
6846 if test "$cf_have_ncuconfig" != "yes"
6848 CPPFLAGS="$cf_save_CPPFLAGS"
6849 LIBS="$cf_save_LIBS"
6850 NCURSES_CONFIG_PKG=none
6853 cat >>confdefs.h <<\EOF
6857 NCURSES_CONFIG_PKG=$cf_ncuconfig_root
6859 echo "$as_me:6859: checking for terminfo header" >&5
6860 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
6861 if test "${cf_cv_term_header+set}" = set; then
6862 echo $ECHO_N "(cached) $ECHO_C" >&6
6865 case ${cf_cv_ncurses_header} in
6866 (*/ncurses.h|*/ncursesw.h)
6867 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
6870 cf_term_header=term.h
6874 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
6876 cat >conftest.$ac_ext <<_ACEOF
6877 #line 6877 "configure"
6878 #include "confdefs.h"
6880 #include <${cf_cv_ncurses_header:-curses.h}>
6886 int x = auto_left_margin
6891 rm -f conftest.$ac_objext
6892 if { (eval echo "$as_me:6892: \"$ac_compile\"") >&5
6893 (eval $ac_compile) 2>&5
6895 echo "$as_me:6895: \$? = $ac_status" >&5
6896 (exit $ac_status); } &&
6897 { ac_try='test -s conftest.$ac_objext'
6898 { (eval echo "$as_me:6898: \"$ac_try\"") >&5
6901 echo "$as_me:6901: \$? = $ac_status" >&5
6902 (exit $ac_status); }; }; then
6904 cf_cv_term_header="$cf_test"
6906 echo "$as_me: failed program was:" >&5
6907 cat conftest.$ac_ext >&5
6909 cf_cv_term_header=unknown
6912 rm -f conftest.$ac_objext conftest.$ac_ext
6913 test "$cf_cv_term_header" != unknown && break
6917 echo "$as_me:6917: result: $cf_cv_term_header" >&5
6918 echo "${ECHO_T}$cf_cv_term_header" >&6
6920 # Set definitions to allow ifdef'ing to accommodate subdirectories
6922 case $cf_cv_term_header in
6925 cat >>confdefs.h <<\EOF
6926 #define HAVE_TERM_H 1
6932 case $cf_cv_term_header in
6935 cat >>confdefs.h <<\EOF
6936 #define HAVE_NCURSES_TERM_H 1
6942 cat >>confdefs.h <<\EOF
6943 #define HAVE_NCURSESW_TERM_H 1
6952 echo "$as_me:6952: result: no" >&5
6953 echo "${ECHO_T}no" >&6
6954 NCURSES_CONFIG_PKG=none
6957 NCURSES_CONFIG_PKG=none
6960 if test "x$cf_have_ncuconfig" = "xno"; then
6961 cf_ncurses_config="${cf_ncuconfig_root}${NCURSES_CONFIG_SUFFIX}-config"; echo "Looking for ${cf_ncurses_config}"
6963 if test -n "$ac_tool_prefix"; then
6964 for ac_prog in ${cf_ncurses_config} ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
6966 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
6967 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
6968 echo "$as_me:6968: checking for $ac_word" >&5
6969 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
6970 if test "${ac_cv_prog_NCURSES_CONFIG+set}" = set; then
6971 echo $ECHO_N "(cached) $ECHO_C" >&6
6973 if test -n "$NCURSES_CONFIG"; then
6974 ac_cv_prog_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test.
6976 ac_save_IFS=$IFS; IFS=$ac_path_separator
6978 for ac_dir in $ac_dummy; do
6980 test -z "$ac_dir" && ac_dir=.
6981 $as_executable_p "$ac_dir/$ac_word" || continue
6982 ac_cv_prog_NCURSES_CONFIG="$ac_tool_prefix$ac_prog"
6983 echo "$as_me:6983: found $ac_dir/$ac_word" >&5
6989 NCURSES_CONFIG=$ac_cv_prog_NCURSES_CONFIG
6990 if test -n "$NCURSES_CONFIG"; then
6991 echo "$as_me:6991: result: $NCURSES_CONFIG" >&5
6992 echo "${ECHO_T}$NCURSES_CONFIG" >&6
6994 echo "$as_me:6994: result: no" >&5
6995 echo "${ECHO_T}no" >&6
6998 test -n "$NCURSES_CONFIG" && break
7001 if test -z "$NCURSES_CONFIG"; then
7002 ac_ct_NCURSES_CONFIG=$NCURSES_CONFIG
7003 for ac_prog in ${cf_ncurses_config} ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
7005 # Extract the first word of "$ac_prog", so it can be a program name with args.
7006 set dummy $ac_prog; ac_word=$2
7007 echo "$as_me:7007: checking for $ac_word" >&5
7008 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7009 if test "${ac_cv_prog_ac_ct_NCURSES_CONFIG+set}" = set; then
7010 echo $ECHO_N "(cached) $ECHO_C" >&6
7012 if test -n "$ac_ct_NCURSES_CONFIG"; then
7013 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_ct_NCURSES_CONFIG" # Let the user override the test.
7015 ac_save_IFS=$IFS; IFS=$ac_path_separator
7017 for ac_dir in $ac_dummy; do
7019 test -z "$ac_dir" && ac_dir=.
7020 $as_executable_p "$ac_dir/$ac_word" || continue
7021 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_prog"
7022 echo "$as_me:7022: found $ac_dir/$ac_word" >&5
7028 ac_ct_NCURSES_CONFIG=$ac_cv_prog_ac_ct_NCURSES_CONFIG
7029 if test -n "$ac_ct_NCURSES_CONFIG"; then
7030 echo "$as_me:7030: result: $ac_ct_NCURSES_CONFIG" >&5
7031 echo "${ECHO_T}$ac_ct_NCURSES_CONFIG" >&6
7033 echo "$as_me:7033: result: no" >&5
7034 echo "${ECHO_T}no" >&6
7037 test -n "$ac_ct_NCURSES_CONFIG" && break
7039 test -n "$ac_ct_NCURSES_CONFIG" || ac_ct_NCURSES_CONFIG="none"
7041 NCURSES_CONFIG=$ac_ct_NCURSES_CONFIG
7044 if test "$NCURSES_CONFIG" != none ; then
7046 CPPFLAGS="$CPPFLAGS `$NCURSES_CONFIG --cflags`"
7048 cf_add_libs="`$NCURSES_CONFIG --libs`"
7049 # Filter out duplicates - this happens with badly-designed ".pc" files...
7050 for cf_add_1lib in $LIBS
7052 for cf_add_2lib in $cf_add_libs
7054 if test "x$cf_add_1lib" = "x$cf_add_2lib"
7060 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
7064 # even with config script, some packages use no-override for curses.h
7066 echo "$as_me:7066: checking if we have identified curses headers" >&5
7067 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
7068 if test "${cf_cv_ncurses_header+set}" = set; then
7069 echo $ECHO_N "(cached) $ECHO_C" >&6
7072 cf_cv_ncurses_header=none
7074 ncurses.h $cf_cv_screen/ncurses.h \
7075 curses.h $cf_cv_screen/curses.h
7077 cat >conftest.$ac_ext <<_ACEOF
7078 #line 7078 "configure"
7079 #include "confdefs.h"
7080 #include <${cf_header}>
7084 initscr(); tgoto("?", 0,0)
7089 rm -f conftest.$ac_objext
7090 if { (eval echo "$as_me:7090: \"$ac_compile\"") >&5
7091 (eval $ac_compile) 2>&5
7093 echo "$as_me:7093: \$? = $ac_status" >&5
7094 (exit $ac_status); } &&
7095 { ac_try='test -s conftest.$ac_objext'
7096 { (eval echo "$as_me:7096: \"$ac_try\"") >&5
7099 echo "$as_me:7099: \$? = $ac_status" >&5
7100 (exit $ac_status); }; }; then
7101 cf_cv_ncurses_header=$cf_header; break
7103 echo "$as_me: failed program was:" >&5
7104 cat conftest.$ac_ext >&5
7106 rm -f conftest.$ac_objext conftest.$ac_ext
7110 echo "$as_me:7110: result: $cf_cv_ncurses_header" >&5
7111 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
7113 if test "$cf_cv_ncurses_header" = none ; then
7114 { { echo "$as_me:7114: error: No curses header-files found" >&5
7115 echo "$as_me: error: No curses header-files found" >&2;}
7116 { (exit 1); exit 1; }; }
7119 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
7121 for ac_header in $cf_cv_ncurses_header
7123 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7124 echo "$as_me:7124: checking for $ac_header" >&5
7125 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7126 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7127 echo $ECHO_N "(cached) $ECHO_C" >&6
7129 cat >conftest.$ac_ext <<_ACEOF
7130 #line 7130 "configure"
7131 #include "confdefs.h"
7132 #include <$ac_header>
7134 if { (eval echo "$as_me:7134: \"$ac_cpp conftest.$ac_ext\"") >&5
7135 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7137 egrep -v '^ *\+' conftest.er1 >conftest.err
7139 cat conftest.err >&5
7140 echo "$as_me:7140: \$? = $ac_status" >&5
7141 (exit $ac_status); } >/dev/null; then
7142 if test -s conftest.err; then
7143 ac_cpp_err=$ac_c_preproc_warn_flag
7150 if test -z "$ac_cpp_err"; then
7151 eval "$as_ac_Header=yes"
7153 echo "$as_me: failed program was:" >&5
7154 cat conftest.$ac_ext >&5
7155 eval "$as_ac_Header=no"
7157 rm -f conftest.err conftest.$ac_ext
7159 echo "$as_me:7159: result: `eval echo '${'$as_ac_Header'}'`" >&5
7160 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7161 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7162 cat >>confdefs.h <<EOF
7163 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7169 cat >>confdefs.h <<\EOF
7173 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
7175 cat >>confdefs.h <<EOF
7176 #define $cf_nculib_ROOT 1
7179 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
7183 cf_ncuhdr_root=$cf_cv_screen
7185 test -n "$cf_cv_curses_dir" && \
7186 test "$cf_cv_curses_dir" != "no" && { \
7188 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
7189 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
7191 while test $cf_add_incdir != /usr/include
7193 if test -d $cf_add_incdir
7196 if test -n "$CFLAGS$CPPFLAGS" ; then
7197 # a loop is needed to ensure we can add subdirs of existing dirs
7198 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
7199 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
7200 cf_have_incdir=yes; break
7205 if test "$cf_have_incdir" = no ; then
7206 if test "$cf_add_incdir" = /usr/local/include ; then
7207 if test "$GCC" = yes
7209 cf_save_CPPFLAGS=$CPPFLAGS
7210 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7211 cat >conftest.$ac_ext <<_ACEOF
7212 #line 7212 "configure"
7213 #include "confdefs.h"
7223 rm -f conftest.$ac_objext
7224 if { (eval echo "$as_me:7224: \"$ac_compile\"") >&5
7225 (eval $ac_compile) 2>&5
7227 echo "$as_me:7227: \$? = $ac_status" >&5
7228 (exit $ac_status); } &&
7229 { ac_try='test -s conftest.$ac_objext'
7230 { (eval echo "$as_me:7230: \"$ac_try\"") >&5
7233 echo "$as_me:7233: \$? = $ac_status" >&5
7234 (exit $ac_status); }; }; then
7237 echo "$as_me: failed program was:" >&5
7238 cat conftest.$ac_ext >&5
7241 rm -f conftest.$ac_objext conftest.$ac_ext
7242 CPPFLAGS=$cf_save_CPPFLAGS
7247 if test "$cf_have_incdir" = no ; then
7248 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
7250 echo "${as_me:-configure}:7250: testing adding $cf_add_incdir to include-path ..." 1>&5
7252 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7254 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
7255 test "$cf_top_incdir" = "$cf_add_incdir" && break
7256 cf_add_incdir="$cf_top_incdir"
7269 echo "$as_me:7269: checking for $cf_ncuhdr_root header in include-path" >&5
7270 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
7271 if test "${cf_cv_ncurses_h+set}" = set; then
7272 echo $ECHO_N "(cached) $ECHO_C" >&6
7275 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
7276 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
7277 for cf_header in $cf_header_list
7280 cat >conftest.$ac_ext <<_ACEOF
7281 #line 7281 "configure"
7282 #include "confdefs.h"
7284 #include <$cf_header>
7289 #ifdef NCURSES_VERSION
7291 printf("%s\n", NCURSES_VERSION);
7304 rm -f conftest.$ac_objext
7305 if { (eval echo "$as_me:7305: \"$ac_compile\"") >&5
7306 (eval $ac_compile) 2>&5
7308 echo "$as_me:7308: \$? = $ac_status" >&5
7309 (exit $ac_status); } &&
7310 { ac_try='test -s conftest.$ac_objext'
7311 { (eval echo "$as_me:7311: \"$ac_try\"") >&5
7314 echo "$as_me:7314: \$? = $ac_status" >&5
7315 (exit $ac_status); }; }; then
7316 cf_cv_ncurses_h=$cf_header
7319 echo "$as_me: failed program was:" >&5
7320 cat conftest.$ac_ext >&5
7323 rm -f conftest.$ac_objext conftest.$ac_ext
7325 test "$cf_cv_ncurses_h" != no && break
7329 echo "$as_me:7329: result: $cf_cv_ncurses_h" >&5
7330 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
7332 if test "$cf_cv_ncurses_h" != no ; then
7333 cf_cv_ncurses_header=$cf_cv_ncurses_h
7336 echo "$as_me:7336: checking for $cf_ncuhdr_root include-path" >&5
7337 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
7338 if test "${cf_cv_ncurses_h2+set}" = set; then
7339 echo $ECHO_N "(cached) $ECHO_C" >&6
7342 test -n "$verbose" && echo
7346 # collect the current set of include-directories from compiler flags
7347 cf_header_path_list=""
7348 if test -n "${CFLAGS}${CPPFLAGS}" ; then
7349 for cf_header_path in $CPPFLAGS $CFLAGS
7351 case $cf_header_path in
7353 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
7355 test "x$cf_header_path" != "xNONE" && \
7356 test -d "$cf_header_path" && \
7358 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
7359 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
7360 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
7361 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
7362 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
7363 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"
7366 cf_header_path_list="$cf_header_path_list $cf_search"
7372 # add the variations for the package we are looking for
7376 test "x$prefix" != "xNONE" && \
7377 test -d "$prefix" && \
7379 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
7380 test -d $prefix/include && cf_search="$cf_search $prefix/include"
7381 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
7382 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
7383 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
7384 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
7387 for cf_subdir_prefix in \
7396 test "x$cf_subdir_prefix" != "x$prefix" && \
7397 test -d "$cf_subdir_prefix" && \
7398 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
7399 test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
7400 test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include"
7401 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root"
7402 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root/include"
7403 test -d $cf_subdir_prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include"
7404 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"
7409 test "$includedir" != NONE && \
7410 test "$includedir" != "/usr/include" && \
7411 test -d "$includedir" && {
7412 test -d $includedir && cf_search="$cf_search $includedir"
7413 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
7416 test "$oldincludedir" != NONE && \
7417 test "$oldincludedir" != "/usr/include" && \
7418 test -d "$oldincludedir" && {
7419 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
7420 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
7423 cf_search="$cf_search $cf_header_path_list"
7425 test -n "$verbose" && echo search path $cf_search
7426 cf_save2_CPPFLAGS="$CPPFLAGS"
7427 for cf_incdir in $cf_search
7430 if test -n "$cf_incdir" ; then
7431 for cf_add_incdir in $cf_incdir
7433 while test $cf_add_incdir != /usr/include
7435 if test -d $cf_add_incdir
7438 if test -n "$CFLAGS$CPPFLAGS" ; then
7439 # a loop is needed to ensure we can add subdirs of existing dirs
7440 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
7441 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
7442 cf_have_incdir=yes; break
7447 if test "$cf_have_incdir" = no ; then
7448 if test "$cf_add_incdir" = /usr/local/include ; then
7449 if test "$GCC" = yes
7451 cf_save_CPPFLAGS=$CPPFLAGS
7452 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7453 cat >conftest.$ac_ext <<_ACEOF
7454 #line 7454 "configure"
7455 #include "confdefs.h"
7465 rm -f conftest.$ac_objext
7466 if { (eval echo "$as_me:7466: \"$ac_compile\"") >&5
7467 (eval $ac_compile) 2>&5
7469 echo "$as_me:7469: \$? = $ac_status" >&5
7470 (exit $ac_status); } &&
7471 { ac_try='test -s conftest.$ac_objext'
7472 { (eval echo "$as_me:7472: \"$ac_try\"") >&5
7475 echo "$as_me:7475: \$? = $ac_status" >&5
7476 (exit $ac_status); }; }; then
7479 echo "$as_me: failed program was:" >&5
7480 cat conftest.$ac_ext >&5
7483 rm -f conftest.$ac_objext conftest.$ac_ext
7484 CPPFLAGS=$cf_save_CPPFLAGS
7489 if test "$cf_have_incdir" = no ; then
7490 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
7492 echo "${as_me:-configure}:7492: testing adding $cf_add_incdir to include-path ..." 1>&5
7494 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7496 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
7497 test "$cf_top_incdir" = "$cf_add_incdir" && break
7498 cf_add_incdir="$cf_top_incdir"
7514 cat >conftest.$ac_ext <<_ACEOF
7515 #line 7515 "configure"
7516 #include "confdefs.h"
7518 #include <$cf_header>
7523 #ifdef NCURSES_VERSION
7525 printf("%s\n", NCURSES_VERSION);
7538 rm -f conftest.$ac_objext
7539 if { (eval echo "$as_me:7539: \"$ac_compile\"") >&5
7540 (eval $ac_compile) 2>&5
7542 echo "$as_me:7542: \$? = $ac_status" >&5
7543 (exit $ac_status); } &&
7544 { ac_try='test -s conftest.$ac_objext'
7545 { (eval echo "$as_me:7545: \"$ac_try\"") >&5
7548 echo "$as_me:7548: \$? = $ac_status" >&5
7549 (exit $ac_status); }; }; then
7550 cf_cv_ncurses_h2=$cf_header
7553 echo "$as_me: failed program was:" >&5
7554 cat conftest.$ac_ext >&5
7557 rm -f conftest.$ac_objext conftest.$ac_ext
7559 if test "$cf_cv_ncurses_h2" != no ; then
7560 cf_cv_ncurses_h2=$cf_incdir/$cf_header
7561 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
7564 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
7566 CPPFLAGS="$cf_save2_CPPFLAGS"
7567 test "$cf_cv_ncurses_h2" != no && break
7569 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:7569: error: not found" >&5
7570 echo "$as_me: error: not found" >&2;}
7571 { (exit 1); exit 1; }; }
7574 echo "$as_me:7574: result: $cf_cv_ncurses_h2" >&5
7575 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
7577 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
7578 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
7579 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
7580 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
7583 if test -n "$cf_1st_incdir" ; then
7584 for cf_add_incdir in $cf_1st_incdir
7586 while test $cf_add_incdir != /usr/include
7588 if test -d $cf_add_incdir
7591 if test -n "$CFLAGS$CPPFLAGS" ; then
7592 # a loop is needed to ensure we can add subdirs of existing dirs
7593 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
7594 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
7595 cf_have_incdir=yes; break
7600 if test "$cf_have_incdir" = no ; then
7601 if test "$cf_add_incdir" = /usr/local/include ; then
7602 if test "$GCC" = yes
7604 cf_save_CPPFLAGS=$CPPFLAGS
7605 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7606 cat >conftest.$ac_ext <<_ACEOF
7607 #line 7607 "configure"
7608 #include "confdefs.h"
7618 rm -f conftest.$ac_objext
7619 if { (eval echo "$as_me:7619: \"$ac_compile\"") >&5
7620 (eval $ac_compile) 2>&5
7622 echo "$as_me:7622: \$? = $ac_status" >&5
7623 (exit $ac_status); } &&
7624 { ac_try='test -s conftest.$ac_objext'
7625 { (eval echo "$as_me:7625: \"$ac_try\"") >&5
7628 echo "$as_me:7628: \$? = $ac_status" >&5
7629 (exit $ac_status); }; }; then
7632 echo "$as_me: failed program was:" >&5
7633 cat conftest.$ac_ext >&5
7636 rm -f conftest.$ac_objext conftest.$ac_ext
7637 CPPFLAGS=$cf_save_CPPFLAGS
7642 if test "$cf_have_incdir" = no ; then
7643 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
7645 echo "${as_me:-configure}:7645: testing adding $cf_add_incdir to include-path ..." 1>&5
7647 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7649 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
7650 test "$cf_top_incdir" = "$cf_add_incdir" && break
7651 cf_add_incdir="$cf_top_incdir"
7664 # Set definitions to allow ifdef'ing for ncurses.h
7666 case $cf_cv_ncurses_header in
7669 cat >>confdefs.h <<\EOF
7670 #define HAVE_NCURSES_H 1
7676 case $cf_cv_ncurses_header in
7677 (ncurses/curses.h|ncurses/ncurses.h)
7679 cat >>confdefs.h <<\EOF
7680 #define HAVE_NCURSES_NCURSES_H 1
7684 (ncursesw/curses.h|ncursesw/ncurses.h)
7686 cat >>confdefs.h <<\EOF
7687 #define HAVE_NCURSESW_NCURSES_H 1
7693 echo "$as_me:7693: checking for terminfo header" >&5
7694 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
7695 if test "${cf_cv_term_header+set}" = set; then
7696 echo $ECHO_N "(cached) $ECHO_C" >&6
7699 case ${cf_cv_ncurses_header} in
7700 (*/ncurses.h|*/ncursesw.h)
7701 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
7704 cf_term_header=term.h
7708 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
7710 cat >conftest.$ac_ext <<_ACEOF
7711 #line 7711 "configure"
7712 #include "confdefs.h"
7714 #include <${cf_cv_ncurses_header:-curses.h}>
7720 int x = auto_left_margin
7725 rm -f conftest.$ac_objext
7726 if { (eval echo "$as_me:7726: \"$ac_compile\"") >&5
7727 (eval $ac_compile) 2>&5
7729 echo "$as_me:7729: \$? = $ac_status" >&5
7730 (exit $ac_status); } &&
7731 { ac_try='test -s conftest.$ac_objext'
7732 { (eval echo "$as_me:7732: \"$ac_try\"") >&5
7735 echo "$as_me:7735: \$? = $ac_status" >&5
7736 (exit $ac_status); }; }; then
7738 cf_cv_term_header="$cf_test"
7740 echo "$as_me: failed program was:" >&5
7741 cat conftest.$ac_ext >&5
7743 cf_cv_term_header=unknown
7746 rm -f conftest.$ac_objext conftest.$ac_ext
7747 test "$cf_cv_term_header" != unknown && break
7751 echo "$as_me:7751: result: $cf_cv_term_header" >&5
7752 echo "${ECHO_T}$cf_cv_term_header" >&6
7754 # Set definitions to allow ifdef'ing to accommodate subdirectories
7756 case $cf_cv_term_header in
7759 cat >>confdefs.h <<\EOF
7760 #define HAVE_TERM_H 1
7766 case $cf_cv_term_header in
7769 cat >>confdefs.h <<\EOF
7770 #define HAVE_NCURSES_TERM_H 1
7776 cat >>confdefs.h <<\EOF
7777 #define HAVE_NCURSESW_TERM_H 1
7783 # some applications need this, but should check for NCURSES_VERSION
7785 cat >>confdefs.h <<\EOF
7789 echo "$as_me:7789: checking for ncurses version" >&5
7790 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
7791 if test "${cf_cv_ncurses_version+set}" = set; then
7792 echo $ECHO_N "(cached) $ECHO_C" >&6
7795 cf_cv_ncurses_version=no
7798 if test "$cross_compiling" = yes; then
7800 # This will not work if the preprocessor splits the line after the
7801 # Autoconf token. The 'unproto' program does that.
7802 cat > conftest.$ac_ext <<EOF
7803 #include <${cf_cv_ncurses_header:-curses.h}>
7805 #ifdef NCURSES_VERSION
7806 Autoconf NCURSES_VERSION
7814 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
7815 { (eval echo "$as_me:7815: \"$cf_try\"") >&5
7818 echo "$as_me:7818: \$? = $ac_status" >&5
7819 (exit $ac_status); }
7820 if test -f conftest.out ; then
7821 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
7822 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
7827 cat >conftest.$ac_ext <<_ACEOF
7828 #line 7828 "configure"
7829 #include "confdefs.h"
7831 #include <${cf_cv_ncurses_header:-curses.h}>
7835 FILE *fp = fopen("$cf_tempfile", "w");
7836 #ifdef NCURSES_VERSION
7837 # ifdef NCURSES_VERSION_PATCH
7838 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
7840 fprintf(fp, "%s\n", NCURSES_VERSION);
7844 fprintf(fp, "old\n");
7849 ${cf_cv_main_return:-return}(0);
7852 rm -f conftest$ac_exeext
7853 if { (eval echo "$as_me:7853: \"$ac_link\"") >&5
7854 (eval $ac_link) 2>&5
7856 echo "$as_me:7856: \$? = $ac_status" >&5
7857 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
7858 { (eval echo "$as_me:7858: \"$ac_try\"") >&5
7861 echo "$as_me:7861: \$? = $ac_status" >&5
7862 (exit $ac_status); }; }; then
7864 cf_cv_ncurses_version=`cat $cf_tempfile`
7866 echo "$as_me: program exited with status $ac_status" >&5
7867 echo "$as_me: failed program was:" >&5
7868 cat conftest.$ac_ext >&5
7870 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
7875 echo "$as_me:7875: result: $cf_cv_ncurses_version" >&5
7876 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
7877 test "$cf_cv_ncurses_version" = no ||
7878 cat >>confdefs.h <<\EOF
7882 cf_nculib_root=$cf_cv_screen
7883 # This works, except for the special case where we find gpm, but
7884 # ncurses is in a nonstandard location via $LIBS, and we really want
7887 cf_ncurses_SAVE="$LIBS"
7888 echo "$as_me:7888: checking for Gpm_Open in -lgpm" >&5
7889 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
7890 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
7891 echo $ECHO_N "(cached) $ECHO_C" >&6
7893 ac_check_lib_save_LIBS=$LIBS
7895 cat >conftest.$ac_ext <<_ACEOF
7896 #line 7896 "configure"
7897 #include "confdefs.h"
7899 /* Override any gcc2 internal prototype to avoid an error. */
7903 /* We use char because int might match the return type of a gcc2
7904 builtin and then its argument prototype would still apply. */
7914 rm -f conftest.$ac_objext conftest$ac_exeext
7915 if { (eval echo "$as_me:7915: \"$ac_link\"") >&5
7916 (eval $ac_link) 2>&5
7918 echo "$as_me:7918: \$? = $ac_status" >&5
7919 (exit $ac_status); } &&
7920 { ac_try='test -s conftest$ac_exeext'
7921 { (eval echo "$as_me:7921: \"$ac_try\"") >&5
7924 echo "$as_me:7924: \$? = $ac_status" >&5
7925 (exit $ac_status); }; }; then
7926 ac_cv_lib_gpm_Gpm_Open=yes
7928 echo "$as_me: failed program was:" >&5
7929 cat conftest.$ac_ext >&5
7930 ac_cv_lib_gpm_Gpm_Open=no
7932 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7933 LIBS=$ac_check_lib_save_LIBS
7935 echo "$as_me:7935: result: $ac_cv_lib_gpm_Gpm_Open" >&5
7936 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
7937 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
7938 echo "$as_me:7938: checking for initscr in -lgpm" >&5
7939 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
7940 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
7941 echo $ECHO_N "(cached) $ECHO_C" >&6
7943 ac_check_lib_save_LIBS=$LIBS
7945 cat >conftest.$ac_ext <<_ACEOF
7946 #line 7946 "configure"
7947 #include "confdefs.h"
7949 /* Override any gcc2 internal prototype to avoid an error. */
7953 /* We use char because int might match the return type of a gcc2
7954 builtin and then its argument prototype would still apply. */
7964 rm -f conftest.$ac_objext conftest$ac_exeext
7965 if { (eval echo "$as_me:7965: \"$ac_link\"") >&5
7966 (eval $ac_link) 2>&5
7968 echo "$as_me:7968: \$? = $ac_status" >&5
7969 (exit $ac_status); } &&
7970 { ac_try='test -s conftest$ac_exeext'
7971 { (eval echo "$as_me:7971: \"$ac_try\"") >&5
7974 echo "$as_me:7974: \$? = $ac_status" >&5
7975 (exit $ac_status); }; }; then
7976 ac_cv_lib_gpm_initscr=yes
7978 echo "$as_me: failed program was:" >&5
7979 cat conftest.$ac_ext >&5
7980 ac_cv_lib_gpm_initscr=no
7982 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7983 LIBS=$ac_check_lib_save_LIBS
7985 echo "$as_me:7985: result: $ac_cv_lib_gpm_initscr" >&5
7986 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
7987 if test $ac_cv_lib_gpm_initscr = yes; then
7988 LIBS="$cf_ncurses_SAVE"
7990 cf_ncurses_LIBS="-lgpm"
7997 # This is only necessary if you are linking against an obsolete
7998 # version of ncurses (but it should do no harm, since it's static).
7999 if test "$cf_nculib_root" = ncurses ; then
8000 echo "$as_me:8000: checking for tgoto in -lmytinfo" >&5
8001 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
8002 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
8003 echo $ECHO_N "(cached) $ECHO_C" >&6
8005 ac_check_lib_save_LIBS=$LIBS
8006 LIBS="-lmytinfo $LIBS"
8007 cat >conftest.$ac_ext <<_ACEOF
8008 #line 8008 "configure"
8009 #include "confdefs.h"
8011 /* Override any gcc2 internal prototype to avoid an error. */
8015 /* We use char because int might match the return type of a gcc2
8016 builtin and then its argument prototype would still apply. */
8026 rm -f conftest.$ac_objext conftest$ac_exeext
8027 if { (eval echo "$as_me:8027: \"$ac_link\"") >&5
8028 (eval $ac_link) 2>&5
8030 echo "$as_me:8030: \$? = $ac_status" >&5
8031 (exit $ac_status); } &&
8032 { ac_try='test -s conftest$ac_exeext'
8033 { (eval echo "$as_me:8033: \"$ac_try\"") >&5
8036 echo "$as_me:8036: \$? = $ac_status" >&5
8037 (exit $ac_status); }; }; then
8038 ac_cv_lib_mytinfo_tgoto=yes
8040 echo "$as_me: failed program was:" >&5
8041 cat conftest.$ac_ext >&5
8042 ac_cv_lib_mytinfo_tgoto=no
8044 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8045 LIBS=$ac_check_lib_save_LIBS
8047 echo "$as_me:8047: result: $ac_cv_lib_mytinfo_tgoto" >&5
8048 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
8049 if test $ac_cv_lib_mytinfo_tgoto = yes; then
8050 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
8057 cf_add_libs="$cf_ncurses_LIBS"
8058 # Filter out duplicates - this happens with badly-designed ".pc" files...
8059 for cf_add_1lib in $LIBS
8061 for cf_add_2lib in $cf_add_libs
8063 if test "x$cf_add_1lib" = "x$cf_add_2lib"
8069 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
8073 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
8076 cf_add_libs="-l$cf_nculib_root"
8077 # Filter out duplicates - this happens with badly-designed ".pc" files...
8078 for cf_add_1lib in $LIBS
8080 for cf_add_2lib in $cf_add_libs
8082 if test "x$cf_add_1lib" = "x$cf_add_2lib"
8088 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
8094 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
8096 echo "$as_me:8096: checking for initscr" >&5
8097 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
8098 if test "${ac_cv_func_initscr+set}" = set; then
8099 echo $ECHO_N "(cached) $ECHO_C" >&6
8101 cat >conftest.$ac_ext <<_ACEOF
8102 #line 8102 "configure"
8103 #include "confdefs.h"
8104 /* System header to define __stub macros and hopefully few prototypes,
8105 which can conflict with char initscr (); below. */
8107 /* Override any gcc2 internal prototype to avoid an error. */
8111 /* We use char because int might match the return type of a gcc2
8112 builtin and then its argument prototype would still apply. */
8119 /* The GNU C library defines this for functions which it implements
8120 to always fail with ENOSYS. Some functions are actually named
8121 something starting with __ and the normal name is an alias. */
8122 #if defined (__stub_initscr) || defined (__stub___initscr)
8125 f = initscr; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
8132 rm -f conftest.$ac_objext conftest$ac_exeext
8133 if { (eval echo "$as_me:8133: \"$ac_link\"") >&5
8134 (eval $ac_link) 2>&5
8136 echo "$as_me:8136: \$? = $ac_status" >&5
8137 (exit $ac_status); } &&
8138 { ac_try='test -s conftest$ac_exeext'
8139 { (eval echo "$as_me:8139: \"$ac_try\"") >&5
8142 echo "$as_me:8142: \$? = $ac_status" >&5
8143 (exit $ac_status); }; }; then
8144 ac_cv_func_initscr=yes
8146 echo "$as_me: failed program was:" >&5
8147 cat conftest.$ac_ext >&5
8148 ac_cv_func_initscr=no
8150 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8152 echo "$as_me:8152: result: $ac_cv_func_initscr" >&5
8153 echo "${ECHO_T}$ac_cv_func_initscr" >&6
8154 if test $ac_cv_func_initscr = yes; then
8155 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
8158 cf_save_LIBS="$LIBS"
8159 echo "$as_me:8159: checking for initscr in -l$cf_nculib_root" >&5
8160 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
8161 LIBS="-l$cf_nculib_root $LIBS"
8162 cat >conftest.$ac_ext <<_ACEOF
8163 #line 8163 "configure"
8164 #include "confdefs.h"
8165 #include <${cf_cv_ncurses_header:-curses.h}>
8174 rm -f conftest.$ac_objext conftest$ac_exeext
8175 if { (eval echo "$as_me:8175: \"$ac_link\"") >&5
8176 (eval $ac_link) 2>&5
8178 echo "$as_me:8178: \$? = $ac_status" >&5
8179 (exit $ac_status); } &&
8180 { ac_try='test -s conftest$ac_exeext'
8181 { (eval echo "$as_me:8181: \"$ac_try\"") >&5
8184 echo "$as_me:8184: \$? = $ac_status" >&5
8185 (exit $ac_status); }; }; then
8186 echo "$as_me:8186: result: yes" >&5
8187 echo "${ECHO_T}yes" >&6
8188 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
8191 echo "$as_me: failed program was:" >&5
8192 cat conftest.$ac_ext >&5
8193 echo "$as_me:8193: result: no" >&5
8194 echo "${ECHO_T}no" >&6
8197 cf_library_path_list=""
8198 if test -n "${LDFLAGS}${LIBS}" ; then
8199 for cf_library_path in $LDFLAGS $LIBS
8201 case $cf_library_path in
8203 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
8205 test "x$cf_library_path" != "xNONE" && \
8206 test -d "$cf_library_path" && \
8208 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
8209 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
8210 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
8211 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
8212 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
8213 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"
8216 cf_library_path_list="$cf_library_path_list $cf_search"
8224 test "x$prefix" != "xNONE" && \
8225 test -d "$prefix" && \
8227 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
8228 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
8229 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
8230 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
8231 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
8232 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
8235 for cf_subdir_prefix in \
8244 test "x$cf_subdir_prefix" != "x$prefix" && \
8245 test -d "$cf_subdir_prefix" && \
8246 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
8247 test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
8248 test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib"
8249 test -d $cf_subdir_prefix/lib/$cf_nculib_root && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root"
8250 test -d $cf_subdir_prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root/lib"
8251 test -d $cf_subdir_prefix/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib"
8252 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"
8257 cf_search="$cf_library_path_list $cf_search"
8259 for cf_libdir in $cf_search
8261 echo "$as_me:8261: checking for -l$cf_nculib_root in $cf_libdir" >&5
8262 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
8263 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
8264 cat >conftest.$ac_ext <<_ACEOF
8265 #line 8265 "configure"
8266 #include "confdefs.h"
8267 #include <${cf_cv_ncurses_header:-curses.h}>
8276 rm -f conftest.$ac_objext conftest$ac_exeext
8277 if { (eval echo "$as_me:8277: \"$ac_link\"") >&5
8278 (eval $ac_link) 2>&5
8280 echo "$as_me:8280: \$? = $ac_status" >&5
8281 (exit $ac_status); } &&
8282 { ac_try='test -s conftest$ac_exeext'
8283 { (eval echo "$as_me:8283: \"$ac_try\"") >&5
8286 echo "$as_me:8286: \$? = $ac_status" >&5
8287 (exit $ac_status); }; }; then
8288 echo "$as_me:8288: result: yes" >&5
8289 echo "${ECHO_T}yes" >&6
8290 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
8293 echo "$as_me: failed program was:" >&5
8294 cat conftest.$ac_ext >&5
8295 echo "$as_me:8295: result: no" >&5
8296 echo "${ECHO_T}no" >&6
8297 LIBS="$cf_save_LIBS"
8299 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8303 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8307 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
8309 if test $cf_found_library = no ; then
8310 { { echo "$as_me:8310: error: Cannot link $cf_nculib_root library" >&5
8311 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
8312 { (exit 1); exit 1; }; }
8317 if test -n "$cf_ncurses_LIBS" ; then
8318 echo "$as_me:8318: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
8319 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
8320 cf_ncurses_SAVE="$LIBS"
8321 for p in $cf_ncurses_LIBS ; do
8322 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
8323 if test "$q" != "$LIBS" ; then
8327 cat >conftest.$ac_ext <<_ACEOF
8328 #line 8328 "configure"
8329 #include "confdefs.h"
8330 #include <${cf_cv_ncurses_header:-curses.h}>
8334 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
8339 rm -f conftest.$ac_objext conftest$ac_exeext
8340 if { (eval echo "$as_me:8340: \"$ac_link\"") >&5
8341 (eval $ac_link) 2>&5
8343 echo "$as_me:8343: \$? = $ac_status" >&5
8344 (exit $ac_status); } &&
8345 { ac_try='test -s conftest$ac_exeext'
8346 { (eval echo "$as_me:8346: \"$ac_try\"") >&5
8349 echo "$as_me:8349: \$? = $ac_status" >&5
8350 (exit $ac_status); }; }; then
8351 echo "$as_me:8351: result: yes" >&5
8352 echo "${ECHO_T}yes" >&6
8354 echo "$as_me: failed program was:" >&5
8355 cat conftest.$ac_ext >&5
8356 echo "$as_me:8356: result: no" >&5
8357 echo "${ECHO_T}no" >&6
8358 LIBS="$cf_ncurses_SAVE"
8360 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8363 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
8365 cat >>confdefs.h <<EOF
8366 #define $cf_nculib_ROOT 1
8377 cf_ncuconfig_root=$cf_cv_screen
8378 cf_have_ncuconfig=no
8380 if test "x${PKG_CONFIG:=none}" != xnone; then
8381 echo "$as_me:8381: checking pkg-config for $cf_ncuconfig_root" >&5
8382 echo $ECHO_N "checking pkg-config for $cf_ncuconfig_root... $ECHO_C" >&6
8383 if "$PKG_CONFIG" --exists $cf_ncuconfig_root ; then
8384 echo "$as_me:8384: result: yes" >&5
8385 echo "${ECHO_T}yes" >&6
8387 echo "$as_me:8387: checking if the $cf_ncuconfig_root package files work" >&5
8388 echo $ECHO_N "checking if the $cf_ncuconfig_root package files work... $ECHO_C" >&6
8389 cf_have_ncuconfig=unknown
8391 cf_save_CPPFLAGS="$CPPFLAGS"
8392 cf_save_LIBS="$LIBS"
8394 CPPFLAGS="$CPPFLAGS `$PKG_CONFIG --cflags $cf_ncuconfig_root`"
8396 cf_add_libs="`$PKG_CONFIG --libs $cf_ncuconfig_root`"
8397 # Filter out duplicates - this happens with badly-designed ".pc" files...
8398 for cf_add_1lib in $LIBS
8400 for cf_add_2lib in $cf_add_libs
8402 if test "x$cf_add_1lib" = "x$cf_add_2lib"
8408 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
8412 cat >conftest.$ac_ext <<_ACEOF
8413 #line 8413 "configure"
8414 #include "confdefs.h"
8415 #include <${cf_cv_ncurses_header:-curses.h}>
8419 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
8424 rm -f conftest.$ac_objext conftest$ac_exeext
8425 if { (eval echo "$as_me:8425: \"$ac_link\"") >&5
8426 (eval $ac_link) 2>&5
8428 echo "$as_me:8428: \$? = $ac_status" >&5
8429 (exit $ac_status); } &&
8430 { ac_try='test -s conftest$ac_exeext'
8431 { (eval echo "$as_me:8431: \"$ac_try\"") >&5
8434 echo "$as_me:8434: \$? = $ac_status" >&5
8435 (exit $ac_status); }; }; then
8436 if test "$cross_compiling" = yes; then
8437 cf_have_ncuconfig=maybe
8439 cat >conftest.$ac_ext <<_ACEOF
8440 #line 8440 "configure"
8441 #include "confdefs.h"
8442 #include <${cf_cv_ncurses_header:-curses.h}>
8444 { char *xx = curses_version(); return (xx == 0); }
8446 rm -f conftest$ac_exeext
8447 if { (eval echo "$as_me:8447: \"$ac_link\"") >&5
8448 (eval $ac_link) 2>&5
8450 echo "$as_me:8450: \$? = $ac_status" >&5
8451 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
8452 { (eval echo "$as_me:8452: \"$ac_try\"") >&5
8455 echo "$as_me:8455: \$? = $ac_status" >&5
8456 (exit $ac_status); }; }; then
8457 cf_have_ncuconfig=yes
8459 echo "$as_me: program exited with status $ac_status" >&5
8460 echo "$as_me: failed program was:" >&5
8461 cat conftest.$ac_ext >&5
8462 cf_have_ncuconfig=no
8464 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
8467 echo "$as_me: failed program was:" >&5
8468 cat conftest.$ac_ext >&5
8469 cf_have_ncuconfig=no
8471 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8472 echo "$as_me:8472: result: $cf_have_ncuconfig" >&5
8473 echo "${ECHO_T}$cf_have_ncuconfig" >&6
8474 test "$cf_have_ncuconfig" = maybe && cf_have_ncuconfig=yes
8475 if test "$cf_have_ncuconfig" != "yes"
8477 CPPFLAGS="$cf_save_CPPFLAGS"
8478 LIBS="$cf_save_LIBS"
8479 NCURSES_CONFIG_PKG=none
8482 cat >>confdefs.h <<\EOF
8486 NCURSES_CONFIG_PKG=$cf_ncuconfig_root
8488 echo "$as_me:8488: checking for terminfo header" >&5
8489 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
8490 if test "${cf_cv_term_header+set}" = set; then
8491 echo $ECHO_N "(cached) $ECHO_C" >&6
8494 case ${cf_cv_ncurses_header} in
8495 (*/ncurses.h|*/ncursesw.h)
8496 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
8499 cf_term_header=term.h
8503 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
8505 cat >conftest.$ac_ext <<_ACEOF
8506 #line 8506 "configure"
8507 #include "confdefs.h"
8509 #include <${cf_cv_ncurses_header:-curses.h}>
8515 int x = auto_left_margin
8520 rm -f conftest.$ac_objext
8521 if { (eval echo "$as_me:8521: \"$ac_compile\"") >&5
8522 (eval $ac_compile) 2>&5
8524 echo "$as_me:8524: \$? = $ac_status" >&5
8525 (exit $ac_status); } &&
8526 { ac_try='test -s conftest.$ac_objext'
8527 { (eval echo "$as_me:8527: \"$ac_try\"") >&5
8530 echo "$as_me:8530: \$? = $ac_status" >&5
8531 (exit $ac_status); }; }; then
8533 cf_cv_term_header="$cf_test"
8535 echo "$as_me: failed program was:" >&5
8536 cat conftest.$ac_ext >&5
8538 cf_cv_term_header=unknown
8541 rm -f conftest.$ac_objext conftest.$ac_ext
8542 test "$cf_cv_term_header" != unknown && break
8546 echo "$as_me:8546: result: $cf_cv_term_header" >&5
8547 echo "${ECHO_T}$cf_cv_term_header" >&6
8549 # Set definitions to allow ifdef'ing to accommodate subdirectories
8551 case $cf_cv_term_header in
8554 cat >>confdefs.h <<\EOF
8555 #define HAVE_TERM_H 1
8561 case $cf_cv_term_header in
8564 cat >>confdefs.h <<\EOF
8565 #define HAVE_NCURSES_TERM_H 1
8571 cat >>confdefs.h <<\EOF
8572 #define HAVE_NCURSESW_TERM_H 1
8581 echo "$as_me:8581: result: no" >&5
8582 echo "${ECHO_T}no" >&6
8583 NCURSES_CONFIG_PKG=none
8586 NCURSES_CONFIG_PKG=none
8589 if test "x$cf_have_ncuconfig" = "xno"; then
8590 cf_ncurses_config="${cf_ncuconfig_root}${NCURSES_CONFIG_SUFFIX}-config"; echo "Looking for ${cf_ncurses_config}"
8592 if test -n "$ac_tool_prefix"; then
8593 for ac_prog in ${cf_ncurses_config} ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
8595 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
8596 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
8597 echo "$as_me:8597: checking for $ac_word" >&5
8598 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
8599 if test "${ac_cv_prog_NCURSES_CONFIG+set}" = set; then
8600 echo $ECHO_N "(cached) $ECHO_C" >&6
8602 if test -n "$NCURSES_CONFIG"; then
8603 ac_cv_prog_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test.
8605 ac_save_IFS=$IFS; IFS=$ac_path_separator
8607 for ac_dir in $ac_dummy; do
8609 test -z "$ac_dir" && ac_dir=.
8610 $as_executable_p "$ac_dir/$ac_word" || continue
8611 ac_cv_prog_NCURSES_CONFIG="$ac_tool_prefix$ac_prog"
8612 echo "$as_me:8612: found $ac_dir/$ac_word" >&5
8618 NCURSES_CONFIG=$ac_cv_prog_NCURSES_CONFIG
8619 if test -n "$NCURSES_CONFIG"; then
8620 echo "$as_me:8620: result: $NCURSES_CONFIG" >&5
8621 echo "${ECHO_T}$NCURSES_CONFIG" >&6
8623 echo "$as_me:8623: result: no" >&5
8624 echo "${ECHO_T}no" >&6
8627 test -n "$NCURSES_CONFIG" && break
8630 if test -z "$NCURSES_CONFIG"; then
8631 ac_ct_NCURSES_CONFIG=$NCURSES_CONFIG
8632 for ac_prog in ${cf_ncurses_config} ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
8634 # Extract the first word of "$ac_prog", so it can be a program name with args.
8635 set dummy $ac_prog; ac_word=$2
8636 echo "$as_me:8636: checking for $ac_word" >&5
8637 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
8638 if test "${ac_cv_prog_ac_ct_NCURSES_CONFIG+set}" = set; then
8639 echo $ECHO_N "(cached) $ECHO_C" >&6
8641 if test -n "$ac_ct_NCURSES_CONFIG"; then
8642 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_ct_NCURSES_CONFIG" # Let the user override the test.
8644 ac_save_IFS=$IFS; IFS=$ac_path_separator
8646 for ac_dir in $ac_dummy; do
8648 test -z "$ac_dir" && ac_dir=.
8649 $as_executable_p "$ac_dir/$ac_word" || continue
8650 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_prog"
8651 echo "$as_me:8651: found $ac_dir/$ac_word" >&5
8657 ac_ct_NCURSES_CONFIG=$ac_cv_prog_ac_ct_NCURSES_CONFIG
8658 if test -n "$ac_ct_NCURSES_CONFIG"; then
8659 echo "$as_me:8659: result: $ac_ct_NCURSES_CONFIG" >&5
8660 echo "${ECHO_T}$ac_ct_NCURSES_CONFIG" >&6
8662 echo "$as_me:8662: result: no" >&5
8663 echo "${ECHO_T}no" >&6
8666 test -n "$ac_ct_NCURSES_CONFIG" && break
8668 test -n "$ac_ct_NCURSES_CONFIG" || ac_ct_NCURSES_CONFIG="none"
8670 NCURSES_CONFIG=$ac_ct_NCURSES_CONFIG
8673 if test "$NCURSES_CONFIG" != none ; then
8675 CPPFLAGS="$CPPFLAGS `$NCURSES_CONFIG --cflags`"
8677 cf_add_libs="`$NCURSES_CONFIG --libs`"
8678 # Filter out duplicates - this happens with badly-designed ".pc" files...
8679 for cf_add_1lib in $LIBS
8681 for cf_add_2lib in $cf_add_libs
8683 if test "x$cf_add_1lib" = "x$cf_add_2lib"
8689 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
8693 # even with config script, some packages use no-override for curses.h
8695 echo "$as_me:8695: checking if we have identified curses headers" >&5
8696 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
8697 if test "${cf_cv_ncurses_header+set}" = set; then
8698 echo $ECHO_N "(cached) $ECHO_C" >&6
8701 cf_cv_ncurses_header=none
8703 ncurses.h $cf_cv_screen/ncurses.h \
8704 curses.h $cf_cv_screen/curses.h
8706 cat >conftest.$ac_ext <<_ACEOF
8707 #line 8707 "configure"
8708 #include "confdefs.h"
8709 #include <${cf_header}>
8713 initscr(); tgoto("?", 0,0)
8718 rm -f conftest.$ac_objext
8719 if { (eval echo "$as_me:8719: \"$ac_compile\"") >&5
8720 (eval $ac_compile) 2>&5
8722 echo "$as_me:8722: \$? = $ac_status" >&5
8723 (exit $ac_status); } &&
8724 { ac_try='test -s conftest.$ac_objext'
8725 { (eval echo "$as_me:8725: \"$ac_try\"") >&5
8728 echo "$as_me:8728: \$? = $ac_status" >&5
8729 (exit $ac_status); }; }; then
8730 cf_cv_ncurses_header=$cf_header; break
8732 echo "$as_me: failed program was:" >&5
8733 cat conftest.$ac_ext >&5
8735 rm -f conftest.$ac_objext conftest.$ac_ext
8739 echo "$as_me:8739: result: $cf_cv_ncurses_header" >&5
8740 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
8742 if test "$cf_cv_ncurses_header" = none ; then
8743 { { echo "$as_me:8743: error: No curses header-files found" >&5
8744 echo "$as_me: error: No curses header-files found" >&2;}
8745 { (exit 1); exit 1; }; }
8748 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
8750 for ac_header in $cf_cv_ncurses_header
8752 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8753 echo "$as_me:8753: checking for $ac_header" >&5
8754 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8755 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8756 echo $ECHO_N "(cached) $ECHO_C" >&6
8758 cat >conftest.$ac_ext <<_ACEOF
8759 #line 8759 "configure"
8760 #include "confdefs.h"
8761 #include <$ac_header>
8763 if { (eval echo "$as_me:8763: \"$ac_cpp conftest.$ac_ext\"") >&5
8764 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8766 egrep -v '^ *\+' conftest.er1 >conftest.err
8768 cat conftest.err >&5
8769 echo "$as_me:8769: \$? = $ac_status" >&5
8770 (exit $ac_status); } >/dev/null; then
8771 if test -s conftest.err; then
8772 ac_cpp_err=$ac_c_preproc_warn_flag
8779 if test -z "$ac_cpp_err"; then
8780 eval "$as_ac_Header=yes"
8782 echo "$as_me: failed program was:" >&5
8783 cat conftest.$ac_ext >&5
8784 eval "$as_ac_Header=no"
8786 rm -f conftest.err conftest.$ac_ext
8788 echo "$as_me:8788: result: `eval echo '${'$as_ac_Header'}'`" >&5
8789 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8790 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8791 cat >>confdefs.h <<EOF
8792 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8798 cat >>confdefs.h <<\EOF
8802 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
8804 cat >>confdefs.h <<EOF
8805 #define $cf_nculib_ROOT 1
8808 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
8812 cf_ncuhdr_root=$cf_cv_screen
8814 test -n "$cf_cv_curses_dir" && \
8815 test "$cf_cv_curses_dir" != "no" && { \
8817 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
8818 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
8820 while test $cf_add_incdir != /usr/include
8822 if test -d $cf_add_incdir
8825 if test -n "$CFLAGS$CPPFLAGS" ; then
8826 # a loop is needed to ensure we can add subdirs of existing dirs
8827 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
8828 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
8829 cf_have_incdir=yes; break
8834 if test "$cf_have_incdir" = no ; then
8835 if test "$cf_add_incdir" = /usr/local/include ; then
8836 if test "$GCC" = yes
8838 cf_save_CPPFLAGS=$CPPFLAGS
8839 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8840 cat >conftest.$ac_ext <<_ACEOF
8841 #line 8841 "configure"
8842 #include "confdefs.h"
8852 rm -f conftest.$ac_objext
8853 if { (eval echo "$as_me:8853: \"$ac_compile\"") >&5
8854 (eval $ac_compile) 2>&5
8856 echo "$as_me:8856: \$? = $ac_status" >&5
8857 (exit $ac_status); } &&
8858 { ac_try='test -s conftest.$ac_objext'
8859 { (eval echo "$as_me:8859: \"$ac_try\"") >&5
8862 echo "$as_me:8862: \$? = $ac_status" >&5
8863 (exit $ac_status); }; }; then
8866 echo "$as_me: failed program was:" >&5
8867 cat conftest.$ac_ext >&5
8870 rm -f conftest.$ac_objext conftest.$ac_ext
8871 CPPFLAGS=$cf_save_CPPFLAGS
8876 if test "$cf_have_incdir" = no ; then
8877 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
8879 echo "${as_me:-configure}:8879: testing adding $cf_add_incdir to include-path ..." 1>&5
8881 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8883 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
8884 test "$cf_top_incdir" = "$cf_add_incdir" && break
8885 cf_add_incdir="$cf_top_incdir"
8898 echo "$as_me:8898: checking for $cf_ncuhdr_root header in include-path" >&5
8899 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
8900 if test "${cf_cv_ncurses_h+set}" = set; then
8901 echo $ECHO_N "(cached) $ECHO_C" >&6
8904 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
8905 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
8906 for cf_header in $cf_header_list
8909 cat >conftest.$ac_ext <<_ACEOF
8910 #line 8910 "configure"
8911 #include "confdefs.h"
8913 #include <$cf_header>
8918 #ifdef NCURSES_VERSION
8920 printf("%s\n", NCURSES_VERSION);
8933 rm -f conftest.$ac_objext
8934 if { (eval echo "$as_me:8934: \"$ac_compile\"") >&5
8935 (eval $ac_compile) 2>&5
8937 echo "$as_me:8937: \$? = $ac_status" >&5
8938 (exit $ac_status); } &&
8939 { ac_try='test -s conftest.$ac_objext'
8940 { (eval echo "$as_me:8940: \"$ac_try\"") >&5
8943 echo "$as_me:8943: \$? = $ac_status" >&5
8944 (exit $ac_status); }; }; then
8945 cf_cv_ncurses_h=$cf_header
8948 echo "$as_me: failed program was:" >&5
8949 cat conftest.$ac_ext >&5
8952 rm -f conftest.$ac_objext conftest.$ac_ext
8954 test "$cf_cv_ncurses_h" != no && break
8958 echo "$as_me:8958: result: $cf_cv_ncurses_h" >&5
8959 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
8961 if test "$cf_cv_ncurses_h" != no ; then
8962 cf_cv_ncurses_header=$cf_cv_ncurses_h
8965 echo "$as_me:8965: checking for $cf_ncuhdr_root include-path" >&5
8966 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
8967 if test "${cf_cv_ncurses_h2+set}" = set; then
8968 echo $ECHO_N "(cached) $ECHO_C" >&6
8971 test -n "$verbose" && echo
8975 # collect the current set of include-directories from compiler flags
8976 cf_header_path_list=""
8977 if test -n "${CFLAGS}${CPPFLAGS}" ; then
8978 for cf_header_path in $CPPFLAGS $CFLAGS
8980 case $cf_header_path in
8982 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
8984 test "x$cf_header_path" != "xNONE" && \
8985 test -d "$cf_header_path" && \
8987 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
8988 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
8989 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
8990 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
8991 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
8992 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"
8995 cf_header_path_list="$cf_header_path_list $cf_search"
9001 # add the variations for the package we are looking for
9005 test "x$prefix" != "xNONE" && \
9006 test -d "$prefix" && \
9008 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
9009 test -d $prefix/include && cf_search="$cf_search $prefix/include"
9010 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
9011 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
9012 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
9013 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
9016 for cf_subdir_prefix in \
9025 test "x$cf_subdir_prefix" != "x$prefix" && \
9026 test -d "$cf_subdir_prefix" && \
9027 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
9028 test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
9029 test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include"
9030 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root"
9031 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root/include"
9032 test -d $cf_subdir_prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include"
9033 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"
9038 test "$includedir" != NONE && \
9039 test "$includedir" != "/usr/include" && \
9040 test -d "$includedir" && {
9041 test -d $includedir && cf_search="$cf_search $includedir"
9042 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
9045 test "$oldincludedir" != NONE && \
9046 test "$oldincludedir" != "/usr/include" && \
9047 test -d "$oldincludedir" && {
9048 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
9049 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
9052 cf_search="$cf_search $cf_header_path_list"
9054 test -n "$verbose" && echo search path $cf_search
9055 cf_save2_CPPFLAGS="$CPPFLAGS"
9056 for cf_incdir in $cf_search
9059 if test -n "$cf_incdir" ; then
9060 for cf_add_incdir in $cf_incdir
9062 while test $cf_add_incdir != /usr/include
9064 if test -d $cf_add_incdir
9067 if test -n "$CFLAGS$CPPFLAGS" ; then
9068 # a loop is needed to ensure we can add subdirs of existing dirs
9069 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
9070 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
9071 cf_have_incdir=yes; break
9076 if test "$cf_have_incdir" = no ; then
9077 if test "$cf_add_incdir" = /usr/local/include ; then
9078 if test "$GCC" = yes
9080 cf_save_CPPFLAGS=$CPPFLAGS
9081 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
9082 cat >conftest.$ac_ext <<_ACEOF
9083 #line 9083 "configure"
9084 #include "confdefs.h"
9094 rm -f conftest.$ac_objext
9095 if { (eval echo "$as_me:9095: \"$ac_compile\"") >&5
9096 (eval $ac_compile) 2>&5
9098 echo "$as_me:9098: \$? = $ac_status" >&5
9099 (exit $ac_status); } &&
9100 { ac_try='test -s conftest.$ac_objext'
9101 { (eval echo "$as_me:9101: \"$ac_try\"") >&5
9104 echo "$as_me:9104: \$? = $ac_status" >&5
9105 (exit $ac_status); }; }; then
9108 echo "$as_me: failed program was:" >&5
9109 cat conftest.$ac_ext >&5
9112 rm -f conftest.$ac_objext conftest.$ac_ext
9113 CPPFLAGS=$cf_save_CPPFLAGS
9118 if test "$cf_have_incdir" = no ; then
9119 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
9121 echo "${as_me:-configure}:9121: testing adding $cf_add_incdir to include-path ..." 1>&5
9123 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
9125 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
9126 test "$cf_top_incdir" = "$cf_add_incdir" && break
9127 cf_add_incdir="$cf_top_incdir"
9143 cat >conftest.$ac_ext <<_ACEOF
9144 #line 9144 "configure"
9145 #include "confdefs.h"
9147 #include <$cf_header>
9152 #ifdef NCURSES_VERSION
9154 printf("%s\n", NCURSES_VERSION);
9167 rm -f conftest.$ac_objext
9168 if { (eval echo "$as_me:9168: \"$ac_compile\"") >&5
9169 (eval $ac_compile) 2>&5
9171 echo "$as_me:9171: \$? = $ac_status" >&5
9172 (exit $ac_status); } &&
9173 { ac_try='test -s conftest.$ac_objext'
9174 { (eval echo "$as_me:9174: \"$ac_try\"") >&5
9177 echo "$as_me:9177: \$? = $ac_status" >&5
9178 (exit $ac_status); }; }; then
9179 cf_cv_ncurses_h2=$cf_header
9182 echo "$as_me: failed program was:" >&5
9183 cat conftest.$ac_ext >&5
9186 rm -f conftest.$ac_objext conftest.$ac_ext
9188 if test "$cf_cv_ncurses_h2" != no ; then
9189 cf_cv_ncurses_h2=$cf_incdir/$cf_header
9190 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
9193 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
9195 CPPFLAGS="$cf_save2_CPPFLAGS"
9196 test "$cf_cv_ncurses_h2" != no && break
9198 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:9198: error: not found" >&5
9199 echo "$as_me: error: not found" >&2;}
9200 { (exit 1); exit 1; }; }
9203 echo "$as_me:9203: result: $cf_cv_ncurses_h2" >&5
9204 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
9206 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
9207 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
9208 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
9209 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
9212 if test -n "$cf_1st_incdir" ; then
9213 for cf_add_incdir in $cf_1st_incdir
9215 while test $cf_add_incdir != /usr/include
9217 if test -d $cf_add_incdir
9220 if test -n "$CFLAGS$CPPFLAGS" ; then
9221 # a loop is needed to ensure we can add subdirs of existing dirs
9222 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
9223 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
9224 cf_have_incdir=yes; break
9229 if test "$cf_have_incdir" = no ; then
9230 if test "$cf_add_incdir" = /usr/local/include ; then
9231 if test "$GCC" = yes
9233 cf_save_CPPFLAGS=$CPPFLAGS
9234 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
9235 cat >conftest.$ac_ext <<_ACEOF
9236 #line 9236 "configure"
9237 #include "confdefs.h"
9247 rm -f conftest.$ac_objext
9248 if { (eval echo "$as_me:9248: \"$ac_compile\"") >&5
9249 (eval $ac_compile) 2>&5
9251 echo "$as_me:9251: \$? = $ac_status" >&5
9252 (exit $ac_status); } &&
9253 { ac_try='test -s conftest.$ac_objext'
9254 { (eval echo "$as_me:9254: \"$ac_try\"") >&5
9257 echo "$as_me:9257: \$? = $ac_status" >&5
9258 (exit $ac_status); }; }; then
9261 echo "$as_me: failed program was:" >&5
9262 cat conftest.$ac_ext >&5
9265 rm -f conftest.$ac_objext conftest.$ac_ext
9266 CPPFLAGS=$cf_save_CPPFLAGS
9271 if test "$cf_have_incdir" = no ; then
9272 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
9274 echo "${as_me:-configure}:9274: testing adding $cf_add_incdir to include-path ..." 1>&5
9276 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
9278 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
9279 test "$cf_top_incdir" = "$cf_add_incdir" && break
9280 cf_add_incdir="$cf_top_incdir"
9293 # Set definitions to allow ifdef'ing for ncurses.h
9295 case $cf_cv_ncurses_header in
9298 cat >>confdefs.h <<\EOF
9299 #define HAVE_NCURSES_H 1
9305 case $cf_cv_ncurses_header in
9306 (ncurses/curses.h|ncurses/ncurses.h)
9308 cat >>confdefs.h <<\EOF
9309 #define HAVE_NCURSES_NCURSES_H 1
9313 (ncursesw/curses.h|ncursesw/ncurses.h)
9315 cat >>confdefs.h <<\EOF
9316 #define HAVE_NCURSESW_NCURSES_H 1
9322 echo "$as_me:9322: checking for terminfo header" >&5
9323 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
9324 if test "${cf_cv_term_header+set}" = set; then
9325 echo $ECHO_N "(cached) $ECHO_C" >&6
9328 case ${cf_cv_ncurses_header} in
9329 (*/ncurses.h|*/ncursesw.h)
9330 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
9333 cf_term_header=term.h
9337 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
9339 cat >conftest.$ac_ext <<_ACEOF
9340 #line 9340 "configure"
9341 #include "confdefs.h"
9343 #include <${cf_cv_ncurses_header:-curses.h}>
9349 int x = auto_left_margin
9354 rm -f conftest.$ac_objext
9355 if { (eval echo "$as_me:9355: \"$ac_compile\"") >&5
9356 (eval $ac_compile) 2>&5
9358 echo "$as_me:9358: \$? = $ac_status" >&5
9359 (exit $ac_status); } &&
9360 { ac_try='test -s conftest.$ac_objext'
9361 { (eval echo "$as_me:9361: \"$ac_try\"") >&5
9364 echo "$as_me:9364: \$? = $ac_status" >&5
9365 (exit $ac_status); }; }; then
9367 cf_cv_term_header="$cf_test"
9369 echo "$as_me: failed program was:" >&5
9370 cat conftest.$ac_ext >&5
9372 cf_cv_term_header=unknown
9375 rm -f conftest.$ac_objext conftest.$ac_ext
9376 test "$cf_cv_term_header" != unknown && break
9380 echo "$as_me:9380: result: $cf_cv_term_header" >&5
9381 echo "${ECHO_T}$cf_cv_term_header" >&6
9383 # Set definitions to allow ifdef'ing to accommodate subdirectories
9385 case $cf_cv_term_header in
9388 cat >>confdefs.h <<\EOF
9389 #define HAVE_TERM_H 1
9395 case $cf_cv_term_header in
9398 cat >>confdefs.h <<\EOF
9399 #define HAVE_NCURSES_TERM_H 1
9405 cat >>confdefs.h <<\EOF
9406 #define HAVE_NCURSESW_TERM_H 1
9412 # some applications need this, but should check for NCURSES_VERSION
9414 cat >>confdefs.h <<\EOF
9418 echo "$as_me:9418: checking for ncurses version" >&5
9419 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
9420 if test "${cf_cv_ncurses_version+set}" = set; then
9421 echo $ECHO_N "(cached) $ECHO_C" >&6
9424 cf_cv_ncurses_version=no
9427 if test "$cross_compiling" = yes; then
9429 # This will not work if the preprocessor splits the line after the
9430 # Autoconf token. The 'unproto' program does that.
9431 cat > conftest.$ac_ext <<EOF
9432 #include <${cf_cv_ncurses_header:-curses.h}>
9434 #ifdef NCURSES_VERSION
9435 Autoconf NCURSES_VERSION
9443 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
9444 { (eval echo "$as_me:9444: \"$cf_try\"") >&5
9447 echo "$as_me:9447: \$? = $ac_status" >&5
9448 (exit $ac_status); }
9449 if test -f conftest.out ; then
9450 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
9451 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
9456 cat >conftest.$ac_ext <<_ACEOF
9457 #line 9457 "configure"
9458 #include "confdefs.h"
9460 #include <${cf_cv_ncurses_header:-curses.h}>
9464 FILE *fp = fopen("$cf_tempfile", "w");
9465 #ifdef NCURSES_VERSION
9466 # ifdef NCURSES_VERSION_PATCH
9467 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
9469 fprintf(fp, "%s\n", NCURSES_VERSION);
9473 fprintf(fp, "old\n");
9478 ${cf_cv_main_return:-return}(0);
9481 rm -f conftest$ac_exeext
9482 if { (eval echo "$as_me:9482: \"$ac_link\"") >&5
9483 (eval $ac_link) 2>&5
9485 echo "$as_me:9485: \$? = $ac_status" >&5
9486 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
9487 { (eval echo "$as_me:9487: \"$ac_try\"") >&5
9490 echo "$as_me:9490: \$? = $ac_status" >&5
9491 (exit $ac_status); }; }; then
9493 cf_cv_ncurses_version=`cat $cf_tempfile`
9495 echo "$as_me: program exited with status $ac_status" >&5
9496 echo "$as_me: failed program was:" >&5
9497 cat conftest.$ac_ext >&5
9499 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
9504 echo "$as_me:9504: result: $cf_cv_ncurses_version" >&5
9505 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
9506 test "$cf_cv_ncurses_version" = no ||
9507 cat >>confdefs.h <<\EOF
9511 cf_nculib_root=$cf_cv_screen
9512 # This works, except for the special case where we find gpm, but
9513 # ncurses is in a nonstandard location via $LIBS, and we really want
9516 cf_ncurses_SAVE="$LIBS"
9517 echo "$as_me:9517: checking for Gpm_Open in -lgpm" >&5
9518 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
9519 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
9520 echo $ECHO_N "(cached) $ECHO_C" >&6
9522 ac_check_lib_save_LIBS=$LIBS
9524 cat >conftest.$ac_ext <<_ACEOF
9525 #line 9525 "configure"
9526 #include "confdefs.h"
9528 /* Override any gcc2 internal prototype to avoid an error. */
9532 /* We use char because int might match the return type of a gcc2
9533 builtin and then its argument prototype would still apply. */
9543 rm -f conftest.$ac_objext conftest$ac_exeext
9544 if { (eval echo "$as_me:9544: \"$ac_link\"") >&5
9545 (eval $ac_link) 2>&5
9547 echo "$as_me:9547: \$? = $ac_status" >&5
9548 (exit $ac_status); } &&
9549 { ac_try='test -s conftest$ac_exeext'
9550 { (eval echo "$as_me:9550: \"$ac_try\"") >&5
9553 echo "$as_me:9553: \$? = $ac_status" >&5
9554 (exit $ac_status); }; }; then
9555 ac_cv_lib_gpm_Gpm_Open=yes
9557 echo "$as_me: failed program was:" >&5
9558 cat conftest.$ac_ext >&5
9559 ac_cv_lib_gpm_Gpm_Open=no
9561 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9562 LIBS=$ac_check_lib_save_LIBS
9564 echo "$as_me:9564: result: $ac_cv_lib_gpm_Gpm_Open" >&5
9565 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
9566 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
9567 echo "$as_me:9567: checking for initscr in -lgpm" >&5
9568 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
9569 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
9570 echo $ECHO_N "(cached) $ECHO_C" >&6
9572 ac_check_lib_save_LIBS=$LIBS
9574 cat >conftest.$ac_ext <<_ACEOF
9575 #line 9575 "configure"
9576 #include "confdefs.h"
9578 /* Override any gcc2 internal prototype to avoid an error. */
9582 /* We use char because int might match the return type of a gcc2
9583 builtin and then its argument prototype would still apply. */
9593 rm -f conftest.$ac_objext conftest$ac_exeext
9594 if { (eval echo "$as_me:9594: \"$ac_link\"") >&5
9595 (eval $ac_link) 2>&5
9597 echo "$as_me:9597: \$? = $ac_status" >&5
9598 (exit $ac_status); } &&
9599 { ac_try='test -s conftest$ac_exeext'
9600 { (eval echo "$as_me:9600: \"$ac_try\"") >&5
9603 echo "$as_me:9603: \$? = $ac_status" >&5
9604 (exit $ac_status); }; }; then
9605 ac_cv_lib_gpm_initscr=yes
9607 echo "$as_me: failed program was:" >&5
9608 cat conftest.$ac_ext >&5
9609 ac_cv_lib_gpm_initscr=no
9611 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9612 LIBS=$ac_check_lib_save_LIBS
9614 echo "$as_me:9614: result: $ac_cv_lib_gpm_initscr" >&5
9615 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
9616 if test $ac_cv_lib_gpm_initscr = yes; then
9617 LIBS="$cf_ncurses_SAVE"
9619 cf_ncurses_LIBS="-lgpm"
9626 # This is only necessary if you are linking against an obsolete
9627 # version of ncurses (but it should do no harm, since it's static).
9628 if test "$cf_nculib_root" = ncurses ; then
9629 echo "$as_me:9629: checking for tgoto in -lmytinfo" >&5
9630 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
9631 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
9632 echo $ECHO_N "(cached) $ECHO_C" >&6
9634 ac_check_lib_save_LIBS=$LIBS
9635 LIBS="-lmytinfo $LIBS"
9636 cat >conftest.$ac_ext <<_ACEOF
9637 #line 9637 "configure"
9638 #include "confdefs.h"
9640 /* Override any gcc2 internal prototype to avoid an error. */
9644 /* We use char because int might match the return type of a gcc2
9645 builtin and then its argument prototype would still apply. */
9655 rm -f conftest.$ac_objext conftest$ac_exeext
9656 if { (eval echo "$as_me:9656: \"$ac_link\"") >&5
9657 (eval $ac_link) 2>&5
9659 echo "$as_me:9659: \$? = $ac_status" >&5
9660 (exit $ac_status); } &&
9661 { ac_try='test -s conftest$ac_exeext'
9662 { (eval echo "$as_me:9662: \"$ac_try\"") >&5
9665 echo "$as_me:9665: \$? = $ac_status" >&5
9666 (exit $ac_status); }; }; then
9667 ac_cv_lib_mytinfo_tgoto=yes
9669 echo "$as_me: failed program was:" >&5
9670 cat conftest.$ac_ext >&5
9671 ac_cv_lib_mytinfo_tgoto=no
9673 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9674 LIBS=$ac_check_lib_save_LIBS
9676 echo "$as_me:9676: result: $ac_cv_lib_mytinfo_tgoto" >&5
9677 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
9678 if test $ac_cv_lib_mytinfo_tgoto = yes; then
9679 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
9686 cf_add_libs="$cf_ncurses_LIBS"
9687 # Filter out duplicates - this happens with badly-designed ".pc" files...
9688 for cf_add_1lib in $LIBS
9690 for cf_add_2lib in $cf_add_libs
9692 if test "x$cf_add_1lib" = "x$cf_add_2lib"
9698 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
9702 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
9705 cf_add_libs="-l$cf_nculib_root"
9706 # Filter out duplicates - this happens with badly-designed ".pc" files...
9707 for cf_add_1lib in $LIBS
9709 for cf_add_2lib in $cf_add_libs
9711 if test "x$cf_add_1lib" = "x$cf_add_2lib"
9717 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
9723 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
9725 echo "$as_me:9725: checking for initscr" >&5
9726 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
9727 if test "${ac_cv_func_initscr+set}" = set; then
9728 echo $ECHO_N "(cached) $ECHO_C" >&6
9730 cat >conftest.$ac_ext <<_ACEOF
9731 #line 9731 "configure"
9732 #include "confdefs.h"
9733 /* System header to define __stub macros and hopefully few prototypes,
9734 which can conflict with char initscr (); below. */
9736 /* Override any gcc2 internal prototype to avoid an error. */
9740 /* We use char because int might match the return type of a gcc2
9741 builtin and then its argument prototype would still apply. */
9748 /* The GNU C library defines this for functions which it implements
9749 to always fail with ENOSYS. Some functions are actually named
9750 something starting with __ and the normal name is an alias. */
9751 #if defined (__stub_initscr) || defined (__stub___initscr)
9754 f = initscr; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
9761 rm -f conftest.$ac_objext conftest$ac_exeext
9762 if { (eval echo "$as_me:9762: \"$ac_link\"") >&5
9763 (eval $ac_link) 2>&5
9765 echo "$as_me:9765: \$? = $ac_status" >&5
9766 (exit $ac_status); } &&
9767 { ac_try='test -s conftest$ac_exeext'
9768 { (eval echo "$as_me:9768: \"$ac_try\"") >&5
9771 echo "$as_me:9771: \$? = $ac_status" >&5
9772 (exit $ac_status); }; }; then
9773 ac_cv_func_initscr=yes
9775 echo "$as_me: failed program was:" >&5
9776 cat conftest.$ac_ext >&5
9777 ac_cv_func_initscr=no
9779 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9781 echo "$as_me:9781: result: $ac_cv_func_initscr" >&5
9782 echo "${ECHO_T}$ac_cv_func_initscr" >&6
9783 if test $ac_cv_func_initscr = yes; then
9784 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
9787 cf_save_LIBS="$LIBS"
9788 echo "$as_me:9788: checking for initscr in -l$cf_nculib_root" >&5
9789 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
9790 LIBS="-l$cf_nculib_root $LIBS"
9791 cat >conftest.$ac_ext <<_ACEOF
9792 #line 9792 "configure"
9793 #include "confdefs.h"
9794 #include <${cf_cv_ncurses_header:-curses.h}>
9803 rm -f conftest.$ac_objext conftest$ac_exeext
9804 if { (eval echo "$as_me:9804: \"$ac_link\"") >&5
9805 (eval $ac_link) 2>&5
9807 echo "$as_me:9807: \$? = $ac_status" >&5
9808 (exit $ac_status); } &&
9809 { ac_try='test -s conftest$ac_exeext'
9810 { (eval echo "$as_me:9810: \"$ac_try\"") >&5
9813 echo "$as_me:9813: \$? = $ac_status" >&5
9814 (exit $ac_status); }; }; then
9815 echo "$as_me:9815: result: yes" >&5
9816 echo "${ECHO_T}yes" >&6
9817 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
9820 echo "$as_me: failed program was:" >&5
9821 cat conftest.$ac_ext >&5
9822 echo "$as_me:9822: result: no" >&5
9823 echo "${ECHO_T}no" >&6
9826 cf_library_path_list=""
9827 if test -n "${LDFLAGS}${LIBS}" ; then
9828 for cf_library_path in $LDFLAGS $LIBS
9830 case $cf_library_path in
9832 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
9834 test "x$cf_library_path" != "xNONE" && \
9835 test -d "$cf_library_path" && \
9837 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
9838 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
9839 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
9840 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
9841 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
9842 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"
9845 cf_library_path_list="$cf_library_path_list $cf_search"
9853 test "x$prefix" != "xNONE" && \
9854 test -d "$prefix" && \
9856 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
9857 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
9858 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
9859 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
9860 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
9861 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
9864 for cf_subdir_prefix in \
9873 test "x$cf_subdir_prefix" != "x$prefix" && \
9874 test -d "$cf_subdir_prefix" && \
9875 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
9876 test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
9877 test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib"
9878 test -d $cf_subdir_prefix/lib/$cf_nculib_root && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root"
9879 test -d $cf_subdir_prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root/lib"
9880 test -d $cf_subdir_prefix/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib"
9881 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"
9886 cf_search="$cf_library_path_list $cf_search"
9888 for cf_libdir in $cf_search
9890 echo "$as_me:9890: checking for -l$cf_nculib_root in $cf_libdir" >&5
9891 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
9892 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
9893 cat >conftest.$ac_ext <<_ACEOF
9894 #line 9894 "configure"
9895 #include "confdefs.h"
9896 #include <${cf_cv_ncurses_header:-curses.h}>
9905 rm -f conftest.$ac_objext conftest$ac_exeext
9906 if { (eval echo "$as_me:9906: \"$ac_link\"") >&5
9907 (eval $ac_link) 2>&5
9909 echo "$as_me:9909: \$? = $ac_status" >&5
9910 (exit $ac_status); } &&
9911 { ac_try='test -s conftest$ac_exeext'
9912 { (eval echo "$as_me:9912: \"$ac_try\"") >&5
9915 echo "$as_me:9915: \$? = $ac_status" >&5
9916 (exit $ac_status); }; }; then
9917 echo "$as_me:9917: result: yes" >&5
9918 echo "${ECHO_T}yes" >&6
9919 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
9922 echo "$as_me: failed program was:" >&5
9923 cat conftest.$ac_ext >&5
9924 echo "$as_me:9924: result: no" >&5
9925 echo "${ECHO_T}no" >&6
9926 LIBS="$cf_save_LIBS"
9928 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9932 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9936 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
9938 if test $cf_found_library = no ; then
9939 { { echo "$as_me:9939: error: Cannot link $cf_nculib_root library" >&5
9940 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
9941 { (exit 1); exit 1; }; }
9946 if test -n "$cf_ncurses_LIBS" ; then
9947 echo "$as_me:9947: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
9948 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
9949 cf_ncurses_SAVE="$LIBS"
9950 for p in $cf_ncurses_LIBS ; do
9951 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
9952 if test "$q" != "$LIBS" ; then
9956 cat >conftest.$ac_ext <<_ACEOF
9957 #line 9957 "configure"
9958 #include "confdefs.h"
9959 #include <${cf_cv_ncurses_header:-curses.h}>
9963 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
9968 rm -f conftest.$ac_objext conftest$ac_exeext
9969 if { (eval echo "$as_me:9969: \"$ac_link\"") >&5
9970 (eval $ac_link) 2>&5
9972 echo "$as_me:9972: \$? = $ac_status" >&5
9973 (exit $ac_status); } &&
9974 { ac_try='test -s conftest$ac_exeext'
9975 { (eval echo "$as_me:9975: \"$ac_try\"") >&5
9978 echo "$as_me:9978: \$? = $ac_status" >&5
9979 (exit $ac_status); }; }; then
9980 echo "$as_me:9980: result: yes" >&5
9981 echo "${ECHO_T}yes" >&6
9983 echo "$as_me: failed program was:" >&5
9984 cat conftest.$ac_ext >&5
9985 echo "$as_me:9985: result: no" >&5
9986 echo "${ECHO_T}no" >&6
9987 LIBS="$cf_ncurses_SAVE"
9989 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9992 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
9994 cat >>confdefs.h <<EOF
9995 #define $cf_nculib_ROOT 1
10000 NCURSES_CONFIG=none
10005 echo "$as_me:10005: checking for X" >&5
10006 echo $ECHO_N "checking for X... $ECHO_C" >&6
10008 # Check whether --with-x or --without-x was given.
10009 if test "${with_x+set}" = set; then
10013 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
10014 if test "x$with_x" = xno; then
10015 # The user explicitly disabled X.
10018 if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
10019 # Both variables are already set.
10022 if test "${ac_cv_have_x+set}" = set; then
10023 echo $ECHO_N "(cached) $ECHO_C" >&6
10025 # One or both of the vars are not set, and there is no cached value.
10026 ac_x_includes=no ac_x_libraries=no
10027 rm -fr conftest.dir
10028 if mkdir conftest.dir; then
10030 # Make sure to not put "make" in the Imakefile rules, since we grep it out.
10031 cat >Imakefile <<'EOF'
10033 @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
10035 if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
10036 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
10037 eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
10038 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
10039 for ac_extension in a so sl dylib dll; do
10040 if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
10041 test -f $ac_im_libdir/libX11.$ac_extension; then
10042 ac_im_usrlibdir=$ac_im_libdir; break
10045 # Screen out bogus values from the imake configuration. They are
10046 # bogus both because they are the default anyway, and because
10047 # using them would break gcc on systems where it needs fixed includes.
10048 case $ac_im_incroot in
10050 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
10052 case $ac_im_usrlibdir in
10053 /usr/lib | /lib) ;;
10054 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
10058 rm -fr conftest.dir
10061 # Standard set of common directories for X headers.
10062 # Check X11 before X11Rn because it is often a symlink to the current release.
10074 /usr/local/X11/include
10075 /usr/local/X11R6/include
10076 /usr/local/X11R5/include
10077 /usr/local/X11R4/include
10079 /usr/local/include/X11
10080 /usr/local/include/X11R6
10081 /usr/local/include/X11R5
10082 /usr/local/include/X11R4
10086 /usr/XFree86/include/X11
10090 /usr/unsupported/include
10091 /usr/athena/include
10092 /usr/local/x11r5/include
10093 /usr/lpp/Xamples/include
10095 /usr/openwin/include
10096 /usr/openwin/share/include'
10098 if test "$ac_x_includes" = no; then
10099 # Guess where to find include files, by looking for Intrinsic.h.
10100 # First, try using that file with no special directory specified.
10101 cat >conftest.$ac_ext <<_ACEOF
10102 #line 10102 "configure"
10103 #include "confdefs.h"
10104 #include <X11/Intrinsic.h>
10106 if { (eval echo "$as_me:10106: \"$ac_cpp conftest.$ac_ext\"") >&5
10107 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10109 egrep -v '^ *\+' conftest.er1 >conftest.err
10111 cat conftest.err >&5
10112 echo "$as_me:10112: \$? = $ac_status" >&5
10113 (exit $ac_status); } >/dev/null; then
10114 if test -s conftest.err; then
10115 ac_cpp_err=$ac_c_preproc_warn_flag
10122 if test -z "$ac_cpp_err"; then
10123 # We can compile using X headers with no special include directory.
10126 echo "$as_me: failed program was:" >&5
10127 cat conftest.$ac_ext >&5
10128 for ac_dir in $ac_x_header_dirs; do
10129 if test -r "$ac_dir/X11/Intrinsic.h"; then
10130 ac_x_includes=$ac_dir
10135 rm -f conftest.err conftest.$ac_ext
10136 fi # $ac_x_includes = no
10138 if test "$ac_x_libraries" = no; then
10139 # Check for the libraries.
10140 # See if we find them without any special options.
10141 # Don't add to $LIBS permanently.
10144 cat >conftest.$ac_ext <<_ACEOF
10145 #line 10145 "configure"
10146 #include "confdefs.h"
10147 #include <X11/Intrinsic.h>
10156 rm -f conftest.$ac_objext conftest$ac_exeext
10157 if { (eval echo "$as_me:10157: \"$ac_link\"") >&5
10158 (eval $ac_link) 2>&5
10160 echo "$as_me:10160: \$? = $ac_status" >&5
10161 (exit $ac_status); } &&
10162 { ac_try='test -s conftest$ac_exeext'
10163 { (eval echo "$as_me:10163: \"$ac_try\"") >&5
10164 (eval $ac_try) 2>&5
10166 echo "$as_me:10166: \$? = $ac_status" >&5
10167 (exit $ac_status); }; }; then
10169 # We can link X programs with no special library path.
10172 echo "$as_me: failed program was:" >&5
10173 cat conftest.$ac_ext >&5
10175 for ac_dir in `echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
10177 # Don't even attempt the hair of trying to link an X program!
10178 for ac_extension in a so sl dylib dll; do
10179 if test -r $ac_dir/libXt.$ac_extension; then
10180 ac_x_libraries=$ac_dir
10186 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10187 fi # $ac_x_libraries = no
10189 if test "$ac_x_includes" = no || test "$ac_x_libraries" = no; then
10190 # Didn't find X anywhere. Cache the known absence of X.
10191 ac_cv_have_x="have_x=no"
10193 # Record where we found X for the cache.
10194 ac_cv_have_x="have_x=yes \
10195 ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
10200 eval "$ac_cv_have_x"
10203 if test "$have_x" != yes; then
10204 echo "$as_me:10204: result: $have_x" >&5
10205 echo "${ECHO_T}$have_x" >&6
10208 # If each of the values was on the command line, it overrides each guess.
10209 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
10210 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
10211 # Update the cache value to reflect the command line values.
10212 ac_cv_have_x="have_x=yes \
10213 ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
10214 echo "$as_me:10214: result: libraries $x_libraries, headers $x_includes" >&5
10215 echo "${ECHO_T}libraries $x_libraries, headers $x_includes" >&6
10218 if test "$no_x" = yes; then
10219 # Not all programs may use this symbol, but it does not hurt to define it.
10221 cat >>confdefs.h <<\EOF
10222 #define X_DISPLAY_MISSING 1
10225 X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS=
10227 if test -n "$x_includes"; then
10228 X_CFLAGS="$X_CFLAGS -I$x_includes"
10231 # It would also be nice to do this for all -L options, not just this one.
10232 if test -n "$x_libraries"; then
10233 X_LIBS="$X_LIBS -L$x_libraries"
10234 # For Solaris; some versions of Sun CC require a space after -R and
10235 # others require no space. Words are not sufficient . . . .
10236 case `(uname -sr) 2>/dev/null` in
10238 echo "$as_me:10238: checking whether -R must be followed by a space" >&5
10239 echo $ECHO_N "checking whether -R must be followed by a space... $ECHO_C" >&6
10240 ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries"
10241 cat >conftest.$ac_ext <<_ACEOF
10242 #line 10242 "configure"
10243 #include "confdefs.h"
10253 rm -f conftest.$ac_objext conftest$ac_exeext
10254 if { (eval echo "$as_me:10254: \"$ac_link\"") >&5
10255 (eval $ac_link) 2>&5
10257 echo "$as_me:10257: \$? = $ac_status" >&5
10258 (exit $ac_status); } &&
10259 { ac_try='test -s conftest$ac_exeext'
10260 { (eval echo "$as_me:10260: \"$ac_try\"") >&5
10261 (eval $ac_try) 2>&5
10263 echo "$as_me:10263: \$? = $ac_status" >&5
10264 (exit $ac_status); }; }; then
10267 echo "$as_me: failed program was:" >&5
10268 cat conftest.$ac_ext >&5
10271 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10272 if test $ac_R_nospace = yes; then
10273 echo "$as_me:10273: result: no" >&5
10274 echo "${ECHO_T}no" >&6
10275 X_LIBS="$X_LIBS -R$x_libraries"
10277 LIBS="$ac_xsave_LIBS -R $x_libraries"
10278 cat >conftest.$ac_ext <<_ACEOF
10279 #line 10279 "configure"
10280 #include "confdefs.h"
10290 rm -f conftest.$ac_objext conftest$ac_exeext
10291 if { (eval echo "$as_me:10291: \"$ac_link\"") >&5
10292 (eval $ac_link) 2>&5
10294 echo "$as_me:10294: \$? = $ac_status" >&5
10295 (exit $ac_status); } &&
10296 { ac_try='test -s conftest$ac_exeext'
10297 { (eval echo "$as_me:10297: \"$ac_try\"") >&5
10298 (eval $ac_try) 2>&5
10300 echo "$as_me:10300: \$? = $ac_status" >&5
10301 (exit $ac_status); }; }; then
10304 echo "$as_me: failed program was:" >&5
10305 cat conftest.$ac_ext >&5
10308 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10309 if test $ac_R_space = yes; then
10310 echo "$as_me:10310: result: yes" >&5
10311 echo "${ECHO_T}yes" >&6
10312 X_LIBS="$X_LIBS -R $x_libraries"
10314 echo "$as_me:10314: result: neither works" >&5
10315 echo "${ECHO_T}neither works" >&6
10318 LIBS=$ac_xsave_LIBS
10322 # Check for system-dependent libraries X programs must link with.
10323 # Do this before checking for the system-independent R6 libraries
10324 # (-lICE), since we may need -lsocket or whatever for X linking.
10326 if test "$ISC" = yes; then
10327 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
10329 # Martyn Johnson says this is needed for Ultrix, if the X
10330 # libraries were built with DECnet support. And Karl Berry says
10331 # the Alpha needs dnet_stub (dnet does not exist).
10332 ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11"
10333 cat >conftest.$ac_ext <<_ACEOF
10334 #line 10334 "configure"
10335 #include "confdefs.h"
10337 /* Override any gcc2 internal prototype to avoid an error. */
10341 /* We use char because int might match the return type of a gcc2
10342 builtin and then its argument prototype would still apply. */
10343 char XOpenDisplay ();
10352 rm -f conftest.$ac_objext conftest$ac_exeext
10353 if { (eval echo "$as_me:10353: \"$ac_link\"") >&5
10354 (eval $ac_link) 2>&5
10356 echo "$as_me:10356: \$? = $ac_status" >&5
10357 (exit $ac_status); } &&
10358 { ac_try='test -s conftest$ac_exeext'
10359 { (eval echo "$as_me:10359: \"$ac_try\"") >&5
10360 (eval $ac_try) 2>&5
10362 echo "$as_me:10362: \$? = $ac_status" >&5
10363 (exit $ac_status); }; }; then
10366 echo "$as_me: failed program was:" >&5
10367 cat conftest.$ac_ext >&5
10368 echo "$as_me:10368: checking for dnet_ntoa in -ldnet" >&5
10369 echo $ECHO_N "checking for dnet_ntoa in -ldnet... $ECHO_C" >&6
10370 if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then
10371 echo $ECHO_N "(cached) $ECHO_C" >&6
10373 ac_check_lib_save_LIBS=$LIBS
10374 LIBS="-ldnet $LIBS"
10375 cat >conftest.$ac_ext <<_ACEOF
10376 #line 10376 "configure"
10377 #include "confdefs.h"
10379 /* Override any gcc2 internal prototype to avoid an error. */
10383 /* We use char because int might match the return type of a gcc2
10384 builtin and then its argument prototype would still apply. */
10394 rm -f conftest.$ac_objext conftest$ac_exeext
10395 if { (eval echo "$as_me:10395: \"$ac_link\"") >&5
10396 (eval $ac_link) 2>&5
10398 echo "$as_me:10398: \$? = $ac_status" >&5
10399 (exit $ac_status); } &&
10400 { ac_try='test -s conftest$ac_exeext'
10401 { (eval echo "$as_me:10401: \"$ac_try\"") >&5
10402 (eval $ac_try) 2>&5
10404 echo "$as_me:10404: \$? = $ac_status" >&5
10405 (exit $ac_status); }; }; then
10406 ac_cv_lib_dnet_dnet_ntoa=yes
10408 echo "$as_me: failed program was:" >&5
10409 cat conftest.$ac_ext >&5
10410 ac_cv_lib_dnet_dnet_ntoa=no
10412 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10413 LIBS=$ac_check_lib_save_LIBS
10415 echo "$as_me:10415: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
10416 echo "${ECHO_T}$ac_cv_lib_dnet_dnet_ntoa" >&6
10417 if test $ac_cv_lib_dnet_dnet_ntoa = yes; then
10418 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
10421 if test $ac_cv_lib_dnet_dnet_ntoa = no; then
10422 echo "$as_me:10422: checking for dnet_ntoa in -ldnet_stub" >&5
10423 echo $ECHO_N "checking for dnet_ntoa in -ldnet_stub... $ECHO_C" >&6
10424 if test "${ac_cv_lib_dnet_stub_dnet_ntoa+set}" = set; then
10425 echo $ECHO_N "(cached) $ECHO_C" >&6
10427 ac_check_lib_save_LIBS=$LIBS
10428 LIBS="-ldnet_stub $LIBS"
10429 cat >conftest.$ac_ext <<_ACEOF
10430 #line 10430 "configure"
10431 #include "confdefs.h"
10433 /* Override any gcc2 internal prototype to avoid an error. */
10437 /* We use char because int might match the return type of a gcc2
10438 builtin and then its argument prototype would still apply. */
10448 rm -f conftest.$ac_objext conftest$ac_exeext
10449 if { (eval echo "$as_me:10449: \"$ac_link\"") >&5
10450 (eval $ac_link) 2>&5
10452 echo "$as_me:10452: \$? = $ac_status" >&5
10453 (exit $ac_status); } &&
10454 { ac_try='test -s conftest$ac_exeext'
10455 { (eval echo "$as_me:10455: \"$ac_try\"") >&5
10456 (eval $ac_try) 2>&5
10458 echo "$as_me:10458: \$? = $ac_status" >&5
10459 (exit $ac_status); }; }; then
10460 ac_cv_lib_dnet_stub_dnet_ntoa=yes
10462 echo "$as_me: failed program was:" >&5
10463 cat conftest.$ac_ext >&5
10464 ac_cv_lib_dnet_stub_dnet_ntoa=no
10466 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10467 LIBS=$ac_check_lib_save_LIBS
10469 echo "$as_me:10469: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5
10470 echo "${ECHO_T}$ac_cv_lib_dnet_stub_dnet_ntoa" >&6
10471 if test $ac_cv_lib_dnet_stub_dnet_ntoa = yes; then
10472 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
10477 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10478 LIBS="$ac_xsave_LIBS"
10480 # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT,
10481 # to get the SysV transport functions.
10482 # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4)
10484 # The nsl library prevents programs from opening the X display
10485 # on Irix 5.2, according to T.E. Dickey.
10486 # The functions gethostbyname, getservbyname, and inet_addr are
10487 # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking.
10488 echo "$as_me:10488: checking for gethostbyname" >&5
10489 echo $ECHO_N "checking for gethostbyname... $ECHO_C" >&6
10490 if test "${ac_cv_func_gethostbyname+set}" = set; then
10491 echo $ECHO_N "(cached) $ECHO_C" >&6
10493 cat >conftest.$ac_ext <<_ACEOF
10494 #line 10494 "configure"
10495 #include "confdefs.h"
10496 /* System header to define __stub macros and hopefully few prototypes,
10497 which can conflict with char gethostbyname (); below. */
10498 #include <assert.h>
10499 /* Override any gcc2 internal prototype to avoid an error. */
10503 /* We use char because int might match the return type of a gcc2
10504 builtin and then its argument prototype would still apply. */
10505 char gethostbyname ();
10511 /* The GNU C library defines this for functions which it implements
10512 to always fail with ENOSYS. Some functions are actually named
10513 something starting with __ and the normal name is an alias. */
10514 #if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
10517 f = gethostbyname; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
10524 rm -f conftest.$ac_objext conftest$ac_exeext
10525 if { (eval echo "$as_me:10525: \"$ac_link\"") >&5
10526 (eval $ac_link) 2>&5
10528 echo "$as_me:10528: \$? = $ac_status" >&5
10529 (exit $ac_status); } &&
10530 { ac_try='test -s conftest$ac_exeext'
10531 { (eval echo "$as_me:10531: \"$ac_try\"") >&5
10532 (eval $ac_try) 2>&5
10534 echo "$as_me:10534: \$? = $ac_status" >&5
10535 (exit $ac_status); }; }; then
10536 ac_cv_func_gethostbyname=yes
10538 echo "$as_me: failed program was:" >&5
10539 cat conftest.$ac_ext >&5
10540 ac_cv_func_gethostbyname=no
10542 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10544 echo "$as_me:10544: result: $ac_cv_func_gethostbyname" >&5
10545 echo "${ECHO_T}$ac_cv_func_gethostbyname" >&6
10547 if test $ac_cv_func_gethostbyname = no; then
10548 echo "$as_me:10548: checking for gethostbyname in -lnsl" >&5
10549 echo $ECHO_N "checking for gethostbyname in -lnsl... $ECHO_C" >&6
10550 if test "${ac_cv_lib_nsl_gethostbyname+set}" = set; then
10551 echo $ECHO_N "(cached) $ECHO_C" >&6
10553 ac_check_lib_save_LIBS=$LIBS
10555 cat >conftest.$ac_ext <<_ACEOF
10556 #line 10556 "configure"
10557 #include "confdefs.h"
10559 /* Override any gcc2 internal prototype to avoid an error. */
10563 /* We use char because int might match the return type of a gcc2
10564 builtin and then its argument prototype would still apply. */
10565 char gethostbyname ();
10574 rm -f conftest.$ac_objext conftest$ac_exeext
10575 if { (eval echo "$as_me:10575: \"$ac_link\"") >&5
10576 (eval $ac_link) 2>&5
10578 echo "$as_me:10578: \$? = $ac_status" >&5
10579 (exit $ac_status); } &&
10580 { ac_try='test -s conftest$ac_exeext'
10581 { (eval echo "$as_me:10581: \"$ac_try\"") >&5
10582 (eval $ac_try) 2>&5
10584 echo "$as_me:10584: \$? = $ac_status" >&5
10585 (exit $ac_status); }; }; then
10586 ac_cv_lib_nsl_gethostbyname=yes
10588 echo "$as_me: failed program was:" >&5
10589 cat conftest.$ac_ext >&5
10590 ac_cv_lib_nsl_gethostbyname=no
10592 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10593 LIBS=$ac_check_lib_save_LIBS
10595 echo "$as_me:10595: result: $ac_cv_lib_nsl_gethostbyname" >&5
10596 echo "${ECHO_T}$ac_cv_lib_nsl_gethostbyname" >&6
10597 if test $ac_cv_lib_nsl_gethostbyname = yes; then
10598 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
10601 if test $ac_cv_lib_nsl_gethostbyname = no; then
10602 echo "$as_me:10602: checking for gethostbyname in -lbsd" >&5
10603 echo $ECHO_N "checking for gethostbyname in -lbsd... $ECHO_C" >&6
10604 if test "${ac_cv_lib_bsd_gethostbyname+set}" = set; then
10605 echo $ECHO_N "(cached) $ECHO_C" >&6
10607 ac_check_lib_save_LIBS=$LIBS
10609 cat >conftest.$ac_ext <<_ACEOF
10610 #line 10610 "configure"
10611 #include "confdefs.h"
10613 /* Override any gcc2 internal prototype to avoid an error. */
10617 /* We use char because int might match the return type of a gcc2
10618 builtin and then its argument prototype would still apply. */
10619 char gethostbyname ();
10628 rm -f conftest.$ac_objext conftest$ac_exeext
10629 if { (eval echo "$as_me:10629: \"$ac_link\"") >&5
10630 (eval $ac_link) 2>&5
10632 echo "$as_me:10632: \$? = $ac_status" >&5
10633 (exit $ac_status); } &&
10634 { ac_try='test -s conftest$ac_exeext'
10635 { (eval echo "$as_me:10635: \"$ac_try\"") >&5
10636 (eval $ac_try) 2>&5
10638 echo "$as_me:10638: \$? = $ac_status" >&5
10639 (exit $ac_status); }; }; then
10640 ac_cv_lib_bsd_gethostbyname=yes
10642 echo "$as_me: failed program was:" >&5
10643 cat conftest.$ac_ext >&5
10644 ac_cv_lib_bsd_gethostbyname=no
10646 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10647 LIBS=$ac_check_lib_save_LIBS
10649 echo "$as_me:10649: result: $ac_cv_lib_bsd_gethostbyname" >&5
10650 echo "${ECHO_T}$ac_cv_lib_bsd_gethostbyname" >&6
10651 if test $ac_cv_lib_bsd_gethostbyname = yes; then
10652 X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd"
10658 # lieder@skyler.mavd.honeywell.com says without -lsocket,
10659 # socket/setsockopt and other routines are undefined under SCO ODT
10660 # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary
10661 # on later versions), says Simon Leinen: it contains gethostby*
10662 # variants that don't use the nameserver (or something). -lsocket
10663 # must be given before -lnsl if both are needed. We assume that
10664 # if connect needs -lnsl, so does gethostbyname.
10665 echo "$as_me:10665: checking for connect" >&5
10666 echo $ECHO_N "checking for connect... $ECHO_C" >&6
10667 if test "${ac_cv_func_connect+set}" = set; then
10668 echo $ECHO_N "(cached) $ECHO_C" >&6
10670 cat >conftest.$ac_ext <<_ACEOF
10671 #line 10671 "configure"
10672 #include "confdefs.h"
10673 /* System header to define __stub macros and hopefully few prototypes,
10674 which can conflict with char connect (); below. */
10675 #include <assert.h>
10676 /* Override any gcc2 internal prototype to avoid an error. */
10680 /* We use char because int might match the return type of a gcc2
10681 builtin and then its argument prototype would still apply. */
10688 /* The GNU C library defines this for functions which it implements
10689 to always fail with ENOSYS. Some functions are actually named
10690 something starting with __ and the normal name is an alias. */
10691 #if defined (__stub_connect) || defined (__stub___connect)
10694 f = connect; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
10701 rm -f conftest.$ac_objext conftest$ac_exeext
10702 if { (eval echo "$as_me:10702: \"$ac_link\"") >&5
10703 (eval $ac_link) 2>&5
10705 echo "$as_me:10705: \$? = $ac_status" >&5
10706 (exit $ac_status); } &&
10707 { ac_try='test -s conftest$ac_exeext'
10708 { (eval echo "$as_me:10708: \"$ac_try\"") >&5
10709 (eval $ac_try) 2>&5
10711 echo "$as_me:10711: \$? = $ac_status" >&5
10712 (exit $ac_status); }; }; then
10713 ac_cv_func_connect=yes
10715 echo "$as_me: failed program was:" >&5
10716 cat conftest.$ac_ext >&5
10717 ac_cv_func_connect=no
10719 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10721 echo "$as_me:10721: result: $ac_cv_func_connect" >&5
10722 echo "${ECHO_T}$ac_cv_func_connect" >&6
10724 if test $ac_cv_func_connect = no; then
10725 echo "$as_me:10725: checking for connect in -lsocket" >&5
10726 echo $ECHO_N "checking for connect in -lsocket... $ECHO_C" >&6
10727 if test "${ac_cv_lib_socket_connect+set}" = set; then
10728 echo $ECHO_N "(cached) $ECHO_C" >&6
10730 ac_check_lib_save_LIBS=$LIBS
10731 LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
10732 cat >conftest.$ac_ext <<_ACEOF
10733 #line 10733 "configure"
10734 #include "confdefs.h"
10736 /* Override any gcc2 internal prototype to avoid an error. */
10740 /* We use char because int might match the return type of a gcc2
10741 builtin and then its argument prototype would still apply. */
10751 rm -f conftest.$ac_objext conftest$ac_exeext
10752 if { (eval echo "$as_me:10752: \"$ac_link\"") >&5
10753 (eval $ac_link) 2>&5
10755 echo "$as_me:10755: \$? = $ac_status" >&5
10756 (exit $ac_status); } &&
10757 { ac_try='test -s conftest$ac_exeext'
10758 { (eval echo "$as_me:10758: \"$ac_try\"") >&5
10759 (eval $ac_try) 2>&5
10761 echo "$as_me:10761: \$? = $ac_status" >&5
10762 (exit $ac_status); }; }; then
10763 ac_cv_lib_socket_connect=yes
10765 echo "$as_me: failed program was:" >&5
10766 cat conftest.$ac_ext >&5
10767 ac_cv_lib_socket_connect=no
10769 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10770 LIBS=$ac_check_lib_save_LIBS
10772 echo "$as_me:10772: result: $ac_cv_lib_socket_connect" >&5
10773 echo "${ECHO_T}$ac_cv_lib_socket_connect" >&6
10774 if test $ac_cv_lib_socket_connect = yes; then
10775 X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS"
10780 # Guillermo Gomez says -lposix is necessary on A/UX.
10781 echo "$as_me:10781: checking for remove" >&5
10782 echo $ECHO_N "checking for remove... $ECHO_C" >&6
10783 if test "${ac_cv_func_remove+set}" = set; then
10784 echo $ECHO_N "(cached) $ECHO_C" >&6
10786 cat >conftest.$ac_ext <<_ACEOF
10787 #line 10787 "configure"
10788 #include "confdefs.h"
10789 /* System header to define __stub macros and hopefully few prototypes,
10790 which can conflict with char remove (); below. */
10791 #include <assert.h>
10792 /* Override any gcc2 internal prototype to avoid an error. */
10796 /* We use char because int might match the return type of a gcc2
10797 builtin and then its argument prototype would still apply. */
10804 /* The GNU C library defines this for functions which it implements
10805 to always fail with ENOSYS. Some functions are actually named
10806 something starting with __ and the normal name is an alias. */
10807 #if defined (__stub_remove) || defined (__stub___remove)
10810 f = remove; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
10817 rm -f conftest.$ac_objext conftest$ac_exeext
10818 if { (eval echo "$as_me:10818: \"$ac_link\"") >&5
10819 (eval $ac_link) 2>&5
10821 echo "$as_me:10821: \$? = $ac_status" >&5
10822 (exit $ac_status); } &&
10823 { ac_try='test -s conftest$ac_exeext'
10824 { (eval echo "$as_me:10824: \"$ac_try\"") >&5
10825 (eval $ac_try) 2>&5
10827 echo "$as_me:10827: \$? = $ac_status" >&5
10828 (exit $ac_status); }; }; then
10829 ac_cv_func_remove=yes
10831 echo "$as_me: failed program was:" >&5
10832 cat conftest.$ac_ext >&5
10833 ac_cv_func_remove=no
10835 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10837 echo "$as_me:10837: result: $ac_cv_func_remove" >&5
10838 echo "${ECHO_T}$ac_cv_func_remove" >&6
10840 if test $ac_cv_func_remove = no; then
10841 echo "$as_me:10841: checking for remove in -lposix" >&5
10842 echo $ECHO_N "checking for remove in -lposix... $ECHO_C" >&6
10843 if test "${ac_cv_lib_posix_remove+set}" = set; then
10844 echo $ECHO_N "(cached) $ECHO_C" >&6
10846 ac_check_lib_save_LIBS=$LIBS
10847 LIBS="-lposix $LIBS"
10848 cat >conftest.$ac_ext <<_ACEOF
10849 #line 10849 "configure"
10850 #include "confdefs.h"
10852 /* Override any gcc2 internal prototype to avoid an error. */
10856 /* We use char because int might match the return type of a gcc2
10857 builtin and then its argument prototype would still apply. */
10867 rm -f conftest.$ac_objext conftest$ac_exeext
10868 if { (eval echo "$as_me:10868: \"$ac_link\"") >&5
10869 (eval $ac_link) 2>&5
10871 echo "$as_me:10871: \$? = $ac_status" >&5
10872 (exit $ac_status); } &&
10873 { ac_try='test -s conftest$ac_exeext'
10874 { (eval echo "$as_me:10874: \"$ac_try\"") >&5
10875 (eval $ac_try) 2>&5
10877 echo "$as_me:10877: \$? = $ac_status" >&5
10878 (exit $ac_status); }; }; then
10879 ac_cv_lib_posix_remove=yes
10881 echo "$as_me: failed program was:" >&5
10882 cat conftest.$ac_ext >&5
10883 ac_cv_lib_posix_remove=no
10885 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10886 LIBS=$ac_check_lib_save_LIBS
10888 echo "$as_me:10888: result: $ac_cv_lib_posix_remove" >&5
10889 echo "${ECHO_T}$ac_cv_lib_posix_remove" >&6
10890 if test $ac_cv_lib_posix_remove = yes; then
10891 X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix"
10896 # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
10897 echo "$as_me:10897: checking for shmat" >&5
10898 echo $ECHO_N "checking for shmat... $ECHO_C" >&6
10899 if test "${ac_cv_func_shmat+set}" = set; then
10900 echo $ECHO_N "(cached) $ECHO_C" >&6
10902 cat >conftest.$ac_ext <<_ACEOF
10903 #line 10903 "configure"
10904 #include "confdefs.h"
10905 /* System header to define __stub macros and hopefully few prototypes,
10906 which can conflict with char shmat (); below. */
10907 #include <assert.h>
10908 /* Override any gcc2 internal prototype to avoid an error. */
10912 /* We use char because int might match the return type of a gcc2
10913 builtin and then its argument prototype would still apply. */
10920 /* The GNU C library defines this for functions which it implements
10921 to always fail with ENOSYS. Some functions are actually named
10922 something starting with __ and the normal name is an alias. */
10923 #if defined (__stub_shmat) || defined (__stub___shmat)
10926 f = shmat; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
10933 rm -f conftest.$ac_objext conftest$ac_exeext
10934 if { (eval echo "$as_me:10934: \"$ac_link\"") >&5
10935 (eval $ac_link) 2>&5
10937 echo "$as_me:10937: \$? = $ac_status" >&5
10938 (exit $ac_status); } &&
10939 { ac_try='test -s conftest$ac_exeext'
10940 { (eval echo "$as_me:10940: \"$ac_try\"") >&5
10941 (eval $ac_try) 2>&5
10943 echo "$as_me:10943: \$? = $ac_status" >&5
10944 (exit $ac_status); }; }; then
10945 ac_cv_func_shmat=yes
10947 echo "$as_me: failed program was:" >&5
10948 cat conftest.$ac_ext >&5
10949 ac_cv_func_shmat=no
10951 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10953 echo "$as_me:10953: result: $ac_cv_func_shmat" >&5
10954 echo "${ECHO_T}$ac_cv_func_shmat" >&6
10956 if test $ac_cv_func_shmat = no; then
10957 echo "$as_me:10957: checking for shmat in -lipc" >&5
10958 echo $ECHO_N "checking for shmat in -lipc... $ECHO_C" >&6
10959 if test "${ac_cv_lib_ipc_shmat+set}" = set; then
10960 echo $ECHO_N "(cached) $ECHO_C" >&6
10962 ac_check_lib_save_LIBS=$LIBS
10964 cat >conftest.$ac_ext <<_ACEOF
10965 #line 10965 "configure"
10966 #include "confdefs.h"
10968 /* Override any gcc2 internal prototype to avoid an error. */
10972 /* We use char because int might match the return type of a gcc2
10973 builtin and then its argument prototype would still apply. */
10983 rm -f conftest.$ac_objext conftest$ac_exeext
10984 if { (eval echo "$as_me:10984: \"$ac_link\"") >&5
10985 (eval $ac_link) 2>&5
10987 echo "$as_me:10987: \$? = $ac_status" >&5
10988 (exit $ac_status); } &&
10989 { ac_try='test -s conftest$ac_exeext'
10990 { (eval echo "$as_me:10990: \"$ac_try\"") >&5
10991 (eval $ac_try) 2>&5
10993 echo "$as_me:10993: \$? = $ac_status" >&5
10994 (exit $ac_status); }; }; then
10995 ac_cv_lib_ipc_shmat=yes
10997 echo "$as_me: failed program was:" >&5
10998 cat conftest.$ac_ext >&5
10999 ac_cv_lib_ipc_shmat=no
11001 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11002 LIBS=$ac_check_lib_save_LIBS
11004 echo "$as_me:11004: result: $ac_cv_lib_ipc_shmat" >&5
11005 echo "${ECHO_T}$ac_cv_lib_ipc_shmat" >&6
11006 if test $ac_cv_lib_ipc_shmat = yes; then
11007 X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc"
11013 # Check for libraries that X11R6 Xt/Xaw programs need.
11014 ac_save_LDFLAGS=$LDFLAGS
11015 test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries"
11016 # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
11017 # check for ICE first), but we must link in the order -lSM -lICE or
11018 # we get undefined symbols. So assume we have SM if we have ICE.
11019 # These have to be linked with before -lX11, unlike the other
11020 # libraries we check for below, so use a different variable.
11021 # John Interrante, Karl Berry
11022 echo "$as_me:11022: checking for IceConnectionNumber in -lICE" >&5
11023 echo $ECHO_N "checking for IceConnectionNumber in -lICE... $ECHO_C" >&6
11024 if test "${ac_cv_lib_ICE_IceConnectionNumber+set}" = set; then
11025 echo $ECHO_N "(cached) $ECHO_C" >&6
11027 ac_check_lib_save_LIBS=$LIBS
11028 LIBS="-lICE $X_EXTRA_LIBS $LIBS"
11029 cat >conftest.$ac_ext <<_ACEOF
11030 #line 11030 "configure"
11031 #include "confdefs.h"
11033 /* Override any gcc2 internal prototype to avoid an error. */
11037 /* We use char because int might match the return type of a gcc2
11038 builtin and then its argument prototype would still apply. */
11039 char IceConnectionNumber ();
11043 IceConnectionNumber ();
11048 rm -f conftest.$ac_objext conftest$ac_exeext
11049 if { (eval echo "$as_me:11049: \"$ac_link\"") >&5
11050 (eval $ac_link) 2>&5
11052 echo "$as_me:11052: \$? = $ac_status" >&5
11053 (exit $ac_status); } &&
11054 { ac_try='test -s conftest$ac_exeext'
11055 { (eval echo "$as_me:11055: \"$ac_try\"") >&5
11056 (eval $ac_try) 2>&5
11058 echo "$as_me:11058: \$? = $ac_status" >&5
11059 (exit $ac_status); }; }; then
11060 ac_cv_lib_ICE_IceConnectionNumber=yes
11062 echo "$as_me: failed program was:" >&5
11063 cat conftest.$ac_ext >&5
11064 ac_cv_lib_ICE_IceConnectionNumber=no
11066 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11067 LIBS=$ac_check_lib_save_LIBS
11069 echo "$as_me:11069: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5
11070 echo "${ECHO_T}$ac_cv_lib_ICE_IceConnectionNumber" >&6
11071 if test $ac_cv_lib_ICE_IceConnectionNumber = yes; then
11072 X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
11075 LDFLAGS=$ac_save_LDFLAGS
11079 cf_x_athena=${cf_x_athena:-Xaw}
11081 echo "$as_me:11081: checking if you want to link with Xaw 3d library" >&5
11082 echo $ECHO_N "checking if you want to link with Xaw 3d library... $ECHO_C" >&6
11085 # Check whether --with-Xaw3d or --without-Xaw3d was given.
11086 if test "${with_Xaw3d+set}" = set; then
11087 withval="$with_Xaw3d"
11090 if test "$withval" = yes ; then
11092 echo "$as_me:11092: result: yes" >&5
11093 echo "${ECHO_T}yes" >&6
11095 echo "$as_me:11095: result: no" >&5
11096 echo "${ECHO_T}no" >&6
11099 echo "$as_me:11099: checking if you want to link with Xaw 3d xft library" >&5
11100 echo $ECHO_N "checking if you want to link with Xaw 3d xft library... $ECHO_C" >&6
11103 # Check whether --with-Xaw3dxft or --without-Xaw3dxft was given.
11104 if test "${with_Xaw3dxft+set}" = set; then
11105 withval="$with_Xaw3dxft"
11108 if test "$withval" = yes ; then
11109 cf_x_athena=Xaw3dxft
11110 echo "$as_me:11110: result: yes" >&5
11111 echo "${ECHO_T}yes" >&6
11113 echo "$as_me:11113: result: no" >&5
11114 echo "${ECHO_T}no" >&6
11117 echo "$as_me:11117: checking if you want to link with neXT Athena library" >&5
11118 echo $ECHO_N "checking if you want to link with neXT Athena library... $ECHO_C" >&6
11121 # Check whether --with-neXtaw or --without-neXtaw was given.
11122 if test "${with_neXtaw+set}" = set; then
11123 withval="$with_neXtaw"
11126 if test "$withval" = yes ; then
11128 echo "$as_me:11128: result: yes" >&5
11129 echo "${ECHO_T}yes" >&6
11131 echo "$as_me:11131: result: no" >&5
11132 echo "${ECHO_T}no" >&6
11135 echo "$as_me:11135: checking if you want to link with Athena-Plus library" >&5
11136 echo $ECHO_N "checking if you want to link with Athena-Plus library... $ECHO_C" >&6
11139 # Check whether --with-XawPlus or --without-XawPlus was given.
11140 if test "${with_XawPlus+set}" = set; then
11141 withval="$with_XawPlus"
11144 if test "$withval" = yes ; then
11145 cf_x_athena=XawPlus
11146 echo "$as_me:11146: result: yes" >&5
11147 echo "${ECHO_T}yes" >&6
11149 echo "$as_me:11149: result: no" >&5
11150 echo "${ECHO_T}no" >&6
11155 if test "$PKG_CONFIG" != none ; then
11157 test "$cf_x_athena" = Xaw && cf_athena_list="xaw8 xaw7 xaw6"
11158 for cf_athena_pkg in \
11161 ${cf_x_athena}-devel \
11162 lib${cf_x_athena} \
11163 lib${cf_x_athena}-devel
11166 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists $cf_athena_pkg; then
11167 test -n "$verbose" && echo " found package $cf_athena_pkg" 1>&6
11169 echo "${as_me:-configure}:11169: testing found package $cf_athena_pkg ..." 1>&5
11171 cf_pkgconfig_incs="`$PKG_CONFIG --cflags $cf_athena_pkg 2>/dev/null`"
11172 cf_pkgconfig_libs="`$PKG_CONFIG --libs $cf_athena_pkg 2>/dev/null`"
11173 test -n "$verbose" && echo " package $cf_athena_pkg CFLAGS: $cf_pkgconfig_incs" 1>&6
11175 echo "${as_me:-configure}:11175: testing package $cf_athena_pkg CFLAGS: $cf_pkgconfig_incs ..." 1>&5
11177 test -n "$verbose" && echo " package $cf_athena_pkg LIBS: $cf_pkgconfig_libs" 1>&6
11179 echo "${as_me:-configure}:11179: testing package $cf_athena_pkg LIBS: $cf_pkgconfig_libs ..." 1>&5
11184 cf_new_extra_cppflags=
11186 for cf_add_cflags in $cf_pkgconfig_incs
11188 case $cf_fix_cppflags in
11190 case $cf_add_cflags in
11191 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
11192 case $cf_add_cflags in
11194 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11196 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
11197 && test -z "${cf_tst_cflags}" \
11198 && cf_fix_cppflags=yes
11200 if test $cf_fix_cppflags = yes ; then
11202 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11203 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11206 elif test "${cf_tst_cflags}" = "\"'" ; then
11208 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11209 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11215 case "$CPPFLAGS" in
11219 case $cf_add_cflags in
11221 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11223 CPPFLAGS=`echo "$CPPFLAGS" | \
11224 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11225 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11230 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
11231 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
11238 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
11239 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
11246 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11247 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11249 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11251 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
11252 && test -z "${cf_tst_cflags}" \
11253 && cf_fix_cppflags=no
11258 if test -n "$cf_new_cflags" ; then
11260 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
11261 CFLAGS="${CFLAGS}$cf_new_cflags"
11265 if test -n "$cf_new_cppflags" ; then
11267 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
11268 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
11272 if test -n "$cf_new_extra_cppflags" ; then
11274 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
11275 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
11279 cf_add_libs="$cf_pkgconfig_libs"
11280 # Filter out duplicates - this happens with badly-designed ".pc" files...
11281 for cf_add_1lib in $LIBS
11283 for cf_add_2lib in $cf_add_libs
11285 if test "x$cf_add_1lib" = "x$cf_add_2lib"
11291 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
11293 LIBS="$cf_add_libs"
11295 cf_x_athena_lib="$cf_pkgconfig_libs"
11297 cf_x_athena_LIBS=`echo "HAVE_LIB_$cf_x_athena" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
11299 cat >>confdefs.h <<EOF
11300 #define $cf_x_athena_LIBS 1
11303 for cf_trim_lib in Xmu Xt X11
11306 (*-l$cf_trim_lib\ *-l$cf_trim_lib*)
11307 LIBS=`echo "$LIBS " | sed -e 's/ / /g' -e 's%-l'"$cf_trim_lib"' %%' -e 's/ $//'`
11308 test -n "$verbose" && echo " ..trimmed $LIBS" 1>&6
11310 echo "${as_me:-configure}:11310: testing ..trimmed $LIBS ..." 1>&5
11316 echo "$as_me:11316: checking for usable $cf_x_athena/Xmu package" >&5
11317 echo $ECHO_N "checking for usable $cf_x_athena/Xmu package... $ECHO_C" >&6
11318 if test "${cf_cv_xaw_compat+set}" = set; then
11319 echo $ECHO_N "(cached) $ECHO_C" >&6
11322 cat >conftest.$ac_ext <<_ACEOF
11323 #line 11323 "configure"
11324 #include "confdefs.h"
11326 #include <X11/Xmu/CharSet.h>
11332 int check = XmuCompareISOLatin1("big", "small")
11338 rm -f conftest.$ac_objext conftest$ac_exeext
11339 if { (eval echo "$as_me:11339: \"$ac_link\"") >&5
11340 (eval $ac_link) 2>&5
11342 echo "$as_me:11342: \$? = $ac_status" >&5
11343 (exit $ac_status); } &&
11344 { ac_try='test -s conftest$ac_exeext'
11345 { (eval echo "$as_me:11345: \"$ac_try\"") >&5
11346 (eval $ac_try) 2>&5
11348 echo "$as_me:11348: \$? = $ac_status" >&5
11349 (exit $ac_status); }; }; then
11350 cf_cv_xaw_compat=yes
11352 echo "$as_me: failed program was:" >&5
11353 cat conftest.$ac_ext >&5
11354 cf_cv_xaw_compat=no
11356 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11358 echo "$as_me:11358: result: $cf_cv_xaw_compat" >&5
11359 echo "${ECHO_T}$cf_cv_xaw_compat" >&6
11361 if test "$cf_cv_xaw_compat" = no
11363 # workaround for broken ".pc" files...
11364 case "$cf_x_athena_lib" in
11368 test -n "$verbose" && echo " work around broken package" 1>&6
11370 echo "${as_me:-configure}:11370: testing work around broken package ..." 1>&5
11372 cf_save_xmu="$LIBS"
11373 cf_first_lib=`echo "$cf_save_xmu" | sed -e 's/^ *//' -e 's/ .*//'`
11375 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xmu; then
11376 test -n "$verbose" && echo " found package xmu" 1>&6
11378 echo "${as_me:-configure}:11378: testing found package xmu ..." 1>&5
11380 cf_pkgconfig_incs="`$PKG_CONFIG --cflags xmu 2>/dev/null`"
11381 cf_pkgconfig_libs="`$PKG_CONFIG --libs xmu 2>/dev/null`"
11382 test -n "$verbose" && echo " package xmu CFLAGS: $cf_pkgconfig_incs" 1>&6
11384 echo "${as_me:-configure}:11384: testing package xmu CFLAGS: $cf_pkgconfig_incs ..." 1>&5
11386 test -n "$verbose" && echo " package xmu LIBS: $cf_pkgconfig_libs" 1>&6
11388 echo "${as_me:-configure}:11388: testing package xmu LIBS: $cf_pkgconfig_libs ..." 1>&5
11393 cf_new_extra_cppflags=
11395 for cf_add_cflags in $cf_pkgconfig_incs
11397 case $cf_fix_cppflags in
11399 case $cf_add_cflags in
11400 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
11401 case $cf_add_cflags in
11403 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11405 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
11406 && test -z "${cf_tst_cflags}" \
11407 && cf_fix_cppflags=yes
11409 if test $cf_fix_cppflags = yes ; then
11411 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11412 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11415 elif test "${cf_tst_cflags}" = "\"'" ; then
11417 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11418 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11424 case "$CPPFLAGS" in
11428 case $cf_add_cflags in
11430 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11432 CPPFLAGS=`echo "$CPPFLAGS" | \
11433 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11434 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11439 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
11440 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
11447 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
11448 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
11455 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11456 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11458 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11460 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
11461 && test -z "${cf_tst_cflags}" \
11462 && cf_fix_cppflags=no
11467 if test -n "$cf_new_cflags" ; then
11469 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
11470 CFLAGS="${CFLAGS}$cf_new_cflags"
11474 if test -n "$cf_new_cppflags" ; then
11476 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
11477 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
11481 if test -n "$cf_new_extra_cppflags" ; then
11483 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
11484 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
11488 cf_add_libs="$cf_pkgconfig_libs"
11489 # Filter out duplicates - this happens with badly-designed ".pc" files...
11490 for cf_add_1lib in $LIBS
11492 for cf_add_2lib in $cf_add_libs
11494 if test "x$cf_add_1lib" = "x$cf_add_2lib"
11500 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
11502 LIBS="$cf_add_libs"
11504 LIBS="$cf_save_xmu"
11506 test -n "$verbose" && echo " ...before $LIBS" 1>&6
11508 echo "${as_me:-configure}:11508: testing ...before $LIBS ..." 1>&5
11510 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%$cf_first_lib %$cf_first_lib $cf_pkgconfig_libs %" -e 's% % %g'`
11511 test -n "$verbose" && echo " ...after $LIBS" 1>&6
11513 echo "${as_me:-configure}:11513: testing ...after $LIBS ..." 1>&5
11519 test -n "$verbose" && echo " ...before $LIBS" 1>&6
11521 echo "${as_me:-configure}:11521: testing ...before $LIBS ..." 1>&5
11523 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%$cf_first_lib %$cf_first_lib -lXmu %" -e 's% % %g'`
11524 test -n "$verbose" && echo " ...after $LIBS" 1>&6
11526 echo "${as_me:-configure}:11526: testing ...after $LIBS ..." 1>&5
11530 for cf_trim_lib in Xmu Xt X11
11533 (*-l$cf_trim_lib\ *-l$cf_trim_lib*)
11534 LIBS=`echo "$LIBS " | sed -e 's/ / /g' -e 's%-l'"$cf_trim_lib"' %%' -e 's/ $//'`
11535 test -n "$verbose" && echo " ..trimmed $LIBS" 1>&6
11537 echo "${as_me:-configure}:11537: testing ..trimmed $LIBS ..." 1>&5
11557 if test -z "$cf_x_athena_lib" ; then
11559 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists Xext; then
11560 test -n "$verbose" && echo " found package Xext" 1>&6
11562 echo "${as_me:-configure}:11562: testing found package Xext ..." 1>&5
11564 cf_pkgconfig_incs="`$PKG_CONFIG --cflags Xext 2>/dev/null`"
11565 cf_pkgconfig_libs="`$PKG_CONFIG --libs Xext 2>/dev/null`"
11566 test -n "$verbose" && echo " package Xext CFLAGS: $cf_pkgconfig_incs" 1>&6
11568 echo "${as_me:-configure}:11568: testing package Xext CFLAGS: $cf_pkgconfig_incs ..." 1>&5
11570 test -n "$verbose" && echo " package Xext LIBS: $cf_pkgconfig_libs" 1>&6
11572 echo "${as_me:-configure}:11572: testing package Xext LIBS: $cf_pkgconfig_libs ..." 1>&5
11577 cf_new_extra_cppflags=
11579 for cf_add_cflags in $cf_pkgconfig_incs
11581 case $cf_fix_cppflags in
11583 case $cf_add_cflags in
11584 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
11585 case $cf_add_cflags in
11587 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11589 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
11590 && test -z "${cf_tst_cflags}" \
11591 && cf_fix_cppflags=yes
11593 if test $cf_fix_cppflags = yes ; then
11595 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11596 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11599 elif test "${cf_tst_cflags}" = "\"'" ; then
11601 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11602 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11608 case "$CPPFLAGS" in
11612 case $cf_add_cflags in
11614 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11616 CPPFLAGS=`echo "$CPPFLAGS" | \
11617 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11618 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11623 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
11624 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
11631 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
11632 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
11639 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11640 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11642 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11644 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
11645 && test -z "${cf_tst_cflags}" \
11646 && cf_fix_cppflags=no
11651 if test -n "$cf_new_cflags" ; then
11653 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
11654 CFLAGS="${CFLAGS}$cf_new_cflags"
11658 if test -n "$cf_new_cppflags" ; then
11660 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
11661 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
11665 if test -n "$cf_new_extra_cppflags" ; then
11667 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
11668 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
11672 cf_add_libs="$cf_pkgconfig_libs"
11673 # Filter out duplicates - this happens with badly-designed ".pc" files...
11674 for cf_add_1lib in $LIBS
11676 for cf_add_2lib in $cf_add_libs
11678 if test "x$cf_add_1lib" = "x$cf_add_2lib"
11684 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
11686 LIBS="$cf_add_libs"
11693 echo "$as_me:11693: checking for XextCreateExtension in -lXext" >&5
11694 echo $ECHO_N "checking for XextCreateExtension in -lXext... $ECHO_C" >&6
11695 if test "${ac_cv_lib_Xext_XextCreateExtension+set}" = set; then
11696 echo $ECHO_N "(cached) $ECHO_C" >&6
11698 ac_check_lib_save_LIBS=$LIBS
11699 LIBS="-lXext $LIBS"
11700 cat >conftest.$ac_ext <<_ACEOF
11701 #line 11701 "configure"
11702 #include "confdefs.h"
11704 /* Override any gcc2 internal prototype to avoid an error. */
11708 /* We use char because int might match the return type of a gcc2
11709 builtin and then its argument prototype would still apply. */
11710 char XextCreateExtension ();
11714 XextCreateExtension ();
11719 rm -f conftest.$ac_objext conftest$ac_exeext
11720 if { (eval echo "$as_me:11720: \"$ac_link\"") >&5
11721 (eval $ac_link) 2>&5
11723 echo "$as_me:11723: \$? = $ac_status" >&5
11724 (exit $ac_status); } &&
11725 { ac_try='test -s conftest$ac_exeext'
11726 { (eval echo "$as_me:11726: \"$ac_try\"") >&5
11727 (eval $ac_try) 2>&5
11729 echo "$as_me:11729: \$? = $ac_status" >&5
11730 (exit $ac_status); }; }; then
11731 ac_cv_lib_Xext_XextCreateExtension=yes
11733 echo "$as_me: failed program was:" >&5
11734 cat conftest.$ac_ext >&5
11735 ac_cv_lib_Xext_XextCreateExtension=no
11737 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11738 LIBS=$ac_check_lib_save_LIBS
11740 echo "$as_me:11740: result: $ac_cv_lib_Xext_XextCreateExtension" >&5
11741 echo "${ECHO_T}$ac_cv_lib_Xext_XextCreateExtension" >&6
11742 if test $ac_cv_lib_Xext_XextCreateExtension = yes; then
11744 cf_add_libs="-lXext"
11745 # Filter out duplicates - this happens with badly-designed ".pc" files...
11746 for cf_add_1lib in $LIBS
11748 for cf_add_2lib in $cf_add_libs
11750 if test "x$cf_add_1lib" = "x$cf_add_2lib"
11756 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
11758 LIBS="$cf_add_libs"
11764 # OSX is schizoid about who owns /usr/X11 (old) versus /opt/X11 (new), and (and
11765 # in some cases has installed dummy files in the former, other cases replaced
11766 # it with a link to the new location). This complicates the configure script.
11767 # Check for that pitfall, and recover using pkg-config
11769 # If none of these are set, the configuration is almost certainly broken.
11770 if test -z "${X_CFLAGS}${X_PRE_LIBS}${X_LIBS}${X_EXTRA_LIBS}"
11773 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists x11; then
11774 test -n "$verbose" && echo " found package x11" 1>&6
11776 echo "${as_me:-configure}:11776: testing found package x11 ..." 1>&5
11778 cf_pkgconfig_incs="`$PKG_CONFIG --cflags x11 2>/dev/null`"
11779 cf_pkgconfig_libs="`$PKG_CONFIG --libs x11 2>/dev/null`"
11780 test -n "$verbose" && echo " package x11 CFLAGS: $cf_pkgconfig_incs" 1>&6
11782 echo "${as_me:-configure}:11782: testing package x11 CFLAGS: $cf_pkgconfig_incs ..." 1>&5
11784 test -n "$verbose" && echo " package x11 LIBS: $cf_pkgconfig_libs" 1>&6
11786 echo "${as_me:-configure}:11786: testing package x11 LIBS: $cf_pkgconfig_libs ..." 1>&5
11791 cf_new_extra_cppflags=
11793 for cf_add_cflags in $cf_pkgconfig_incs
11795 case $cf_fix_cppflags in
11797 case $cf_add_cflags in
11798 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
11799 case $cf_add_cflags in
11801 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11803 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
11804 && test -z "${cf_tst_cflags}" \
11805 && cf_fix_cppflags=yes
11807 if test $cf_fix_cppflags = yes ; then
11809 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11810 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11813 elif test "${cf_tst_cflags}" = "\"'" ; then
11815 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11816 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11822 case "$CPPFLAGS" in
11826 case $cf_add_cflags in
11828 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11830 CPPFLAGS=`echo "$CPPFLAGS" | \
11831 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11832 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11837 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
11838 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
11845 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
11846 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
11853 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11854 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11856 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11858 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
11859 && test -z "${cf_tst_cflags}" \
11860 && cf_fix_cppflags=no
11865 if test -n "$cf_new_cflags" ; then
11867 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
11868 CFLAGS="${CFLAGS}$cf_new_cflags"
11872 if test -n "$cf_new_cppflags" ; then
11874 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
11875 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
11879 if test -n "$cf_new_extra_cppflags" ; then
11881 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
11882 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
11886 cf_add_libs="$cf_pkgconfig_libs"
11887 # Filter out duplicates - this happens with badly-designed ".pc" files...
11888 for cf_add_1lib in $LIBS
11890 for cf_add_2lib in $cf_add_libs
11892 if test "x$cf_add_1lib" = "x$cf_add_2lib"
11898 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
11900 LIBS="$cf_add_libs"
11906 { echo "$as_me:11906: WARNING: unable to find X11 library" >&5
11907 echo "$as_me: WARNING: unable to find X11 library" >&2;}
11910 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists ice; then
11911 test -n "$verbose" && echo " found package ice" 1>&6
11913 echo "${as_me:-configure}:11913: testing found package ice ..." 1>&5
11915 cf_pkgconfig_incs="`$PKG_CONFIG --cflags ice 2>/dev/null`"
11916 cf_pkgconfig_libs="`$PKG_CONFIG --libs ice 2>/dev/null`"
11917 test -n "$verbose" && echo " package ice CFLAGS: $cf_pkgconfig_incs" 1>&6
11919 echo "${as_me:-configure}:11919: testing package ice CFLAGS: $cf_pkgconfig_incs ..." 1>&5
11921 test -n "$verbose" && echo " package ice LIBS: $cf_pkgconfig_libs" 1>&6
11923 echo "${as_me:-configure}:11923: testing package ice LIBS: $cf_pkgconfig_libs ..." 1>&5
11928 cf_new_extra_cppflags=
11930 for cf_add_cflags in $cf_pkgconfig_incs
11932 case $cf_fix_cppflags in
11934 case $cf_add_cflags in
11935 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
11936 case $cf_add_cflags in
11938 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11940 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
11941 && test -z "${cf_tst_cflags}" \
11942 && cf_fix_cppflags=yes
11944 if test $cf_fix_cppflags = yes ; then
11946 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11947 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11950 elif test "${cf_tst_cflags}" = "\"'" ; then
11952 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11953 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11959 case "$CPPFLAGS" in
11963 case $cf_add_cflags in
11965 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11967 CPPFLAGS=`echo "$CPPFLAGS" | \
11968 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11969 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11974 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
11975 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
11982 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
11983 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
11990 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11991 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11993 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11995 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
11996 && test -z "${cf_tst_cflags}" \
11997 && cf_fix_cppflags=no
12002 if test -n "$cf_new_cflags" ; then
12004 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
12005 CFLAGS="${CFLAGS}$cf_new_cflags"
12009 if test -n "$cf_new_cppflags" ; then
12011 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
12012 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
12016 if test -n "$cf_new_extra_cppflags" ; then
12018 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
12019 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
12023 cf_add_libs="$cf_pkgconfig_libs"
12024 # Filter out duplicates - this happens with badly-designed ".pc" files...
12025 for cf_add_1lib in $LIBS
12027 for cf_add_2lib in $cf_add_libs
12029 if test "x$cf_add_1lib" = "x$cf_add_2lib"
12035 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
12037 LIBS="$cf_add_libs"
12043 { echo "$as_me:12043: WARNING: unable to find ICE library" >&5
12044 echo "$as_me: WARNING: unable to find ICE library" >&2;}
12047 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists sm; then
12048 test -n "$verbose" && echo " found package sm" 1>&6
12050 echo "${as_me:-configure}:12050: testing found package sm ..." 1>&5
12052 cf_pkgconfig_incs="`$PKG_CONFIG --cflags sm 2>/dev/null`"
12053 cf_pkgconfig_libs="`$PKG_CONFIG --libs sm 2>/dev/null`"
12054 test -n "$verbose" && echo " package sm CFLAGS: $cf_pkgconfig_incs" 1>&6
12056 echo "${as_me:-configure}:12056: testing package sm CFLAGS: $cf_pkgconfig_incs ..." 1>&5
12058 test -n "$verbose" && echo " package sm LIBS: $cf_pkgconfig_libs" 1>&6
12060 echo "${as_me:-configure}:12060: testing package sm LIBS: $cf_pkgconfig_libs ..." 1>&5
12065 cf_new_extra_cppflags=
12067 for cf_add_cflags in $cf_pkgconfig_incs
12069 case $cf_fix_cppflags in
12071 case $cf_add_cflags in
12072 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
12073 case $cf_add_cflags in
12075 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
12077 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12078 && test -z "${cf_tst_cflags}" \
12079 && cf_fix_cppflags=yes
12081 if test $cf_fix_cppflags = yes ; then
12083 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12084 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12087 elif test "${cf_tst_cflags}" = "\"'" ; then
12089 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12090 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12096 case "$CPPFLAGS" in
12100 case $cf_add_cflags in
12102 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12104 CPPFLAGS=`echo "$CPPFLAGS" | \
12105 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12106 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12111 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
12112 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
12119 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
12120 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
12127 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12128 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12130 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
12132 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12133 && test -z "${cf_tst_cflags}" \
12134 && cf_fix_cppflags=no
12139 if test -n "$cf_new_cflags" ; then
12141 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
12142 CFLAGS="${CFLAGS}$cf_new_cflags"
12146 if test -n "$cf_new_cppflags" ; then
12148 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
12149 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
12153 if test -n "$cf_new_extra_cppflags" ; then
12155 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
12156 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
12160 cf_add_libs="$cf_pkgconfig_libs"
12161 # Filter out duplicates - this happens with badly-designed ".pc" files...
12162 for cf_add_1lib in $LIBS
12164 for cf_add_2lib in $cf_add_libs
12166 if test "x$cf_add_1lib" = "x$cf_add_2lib"
12172 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
12174 LIBS="$cf_add_libs"
12180 { echo "$as_me:12180: WARNING: unable to find SM library" >&5
12181 echo "$as_me: WARNING: unable to find SM library" >&2;}
12184 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xt; then
12185 test -n "$verbose" && echo " found package xt" 1>&6
12187 echo "${as_me:-configure}:12187: testing found package xt ..." 1>&5
12189 cf_pkgconfig_incs="`$PKG_CONFIG --cflags xt 2>/dev/null`"
12190 cf_pkgconfig_libs="`$PKG_CONFIG --libs xt 2>/dev/null`"
12191 test -n "$verbose" && echo " package xt CFLAGS: $cf_pkgconfig_incs" 1>&6
12193 echo "${as_me:-configure}:12193: testing package xt CFLAGS: $cf_pkgconfig_incs ..." 1>&5
12195 test -n "$verbose" && echo " package xt LIBS: $cf_pkgconfig_libs" 1>&6
12197 echo "${as_me:-configure}:12197: testing package xt LIBS: $cf_pkgconfig_libs ..." 1>&5
12202 cf_new_extra_cppflags=
12204 for cf_add_cflags in $cf_pkgconfig_incs
12206 case $cf_fix_cppflags in
12208 case $cf_add_cflags in
12209 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
12210 case $cf_add_cflags in
12212 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
12214 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12215 && test -z "${cf_tst_cflags}" \
12216 && cf_fix_cppflags=yes
12218 if test $cf_fix_cppflags = yes ; then
12220 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12221 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12224 elif test "${cf_tst_cflags}" = "\"'" ; then
12226 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12227 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12233 case "$CPPFLAGS" in
12237 case $cf_add_cflags in
12239 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12241 CPPFLAGS=`echo "$CPPFLAGS" | \
12242 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12243 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12248 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
12249 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
12256 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
12257 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
12264 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12265 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12267 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
12269 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12270 && test -z "${cf_tst_cflags}" \
12271 && cf_fix_cppflags=no
12276 if test -n "$cf_new_cflags" ; then
12278 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
12279 CFLAGS="${CFLAGS}$cf_new_cflags"
12283 if test -n "$cf_new_cppflags" ; then
12285 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
12286 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
12290 if test -n "$cf_new_extra_cppflags" ; then
12292 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
12293 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
12297 cf_add_libs="$cf_pkgconfig_libs"
12298 # Filter out duplicates - this happens with badly-designed ".pc" files...
12299 for cf_add_1lib in $LIBS
12301 for cf_add_2lib in $cf_add_libs
12303 if test "x$cf_add_1lib" = "x$cf_add_2lib"
12309 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
12311 LIBS="$cf_add_libs"
12317 { echo "$as_me:12317: WARNING: unable to find Xt library" >&5
12318 echo "$as_me: WARNING: unable to find Xt library" >&2;}
12325 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xt; then
12326 test -n "$verbose" && echo " found package xt" 1>&6
12328 echo "${as_me:-configure}:12328: testing found package xt ..." 1>&5
12330 cf_pkgconfig_incs="`$PKG_CONFIG --cflags xt 2>/dev/null`"
12331 cf_pkgconfig_libs="`$PKG_CONFIG --libs xt 2>/dev/null`"
12332 test -n "$verbose" && echo " package xt CFLAGS: $cf_pkgconfig_incs" 1>&6
12334 echo "${as_me:-configure}:12334: testing package xt CFLAGS: $cf_pkgconfig_incs ..." 1>&5
12336 test -n "$verbose" && echo " package xt LIBS: $cf_pkgconfig_libs" 1>&6
12338 echo "${as_me:-configure}:12338: testing package xt LIBS: $cf_pkgconfig_libs ..." 1>&5
12343 cf_new_extra_cppflags=
12345 for cf_add_cflags in $cf_pkgconfig_incs
12347 case $cf_fix_cppflags in
12349 case $cf_add_cflags in
12350 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
12351 case $cf_add_cflags in
12353 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
12355 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12356 && test -z "${cf_tst_cflags}" \
12357 && cf_fix_cppflags=yes
12359 if test $cf_fix_cppflags = yes ; then
12361 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12362 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12365 elif test "${cf_tst_cflags}" = "\"'" ; then
12367 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12368 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12374 case "$CPPFLAGS" in
12378 case $cf_add_cflags in
12380 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12382 CPPFLAGS=`echo "$CPPFLAGS" | \
12383 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12384 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12389 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
12390 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
12397 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
12398 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
12405 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12406 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12408 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
12410 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12411 && test -z "${cf_tst_cflags}" \
12412 && cf_fix_cppflags=no
12417 if test -n "$cf_new_cflags" ; then
12419 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
12420 CFLAGS="${CFLAGS}$cf_new_cflags"
12424 if test -n "$cf_new_cppflags" ; then
12426 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
12427 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
12431 if test -n "$cf_new_extra_cppflags" ; then
12433 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
12434 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
12438 cf_add_libs="$cf_pkgconfig_libs"
12439 # Filter out duplicates - this happens with badly-designed ".pc" files...
12440 for cf_add_1lib in $LIBS
12442 for cf_add_2lib in $cf_add_libs
12444 if test "x$cf_add_1lib" = "x$cf_add_2lib"
12450 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
12452 LIBS="$cf_add_libs"
12458 # we have an "xt" package, but it may omit Xt's dependency on X11
12459 echo "$as_me:12459: checking for usable X dependency" >&5
12460 echo $ECHO_N "checking for usable X dependency... $ECHO_C" >&6
12461 if test "${cf_cv_xt_x11_compat+set}" = set; then
12462 echo $ECHO_N "(cached) $ECHO_C" >&6
12465 cat >conftest.$ac_ext <<_ACEOF
12466 #line 12466 "configure"
12467 #include "confdefs.h"
12469 #include <X11/Xlib.h>
12475 int rc1 = XDrawLine((Display*) 0, (Drawable) 0, (GC) 0, 0, 0, 0, 0);
12476 int rc2 = XClearWindow((Display*) 0, (Window) 0);
12477 int rc3 = XMoveWindow((Display*) 0, (Window) 0, 0, 0);
12478 int rc4 = XMoveResizeWindow((Display*)0, (Window)0, 0, 0, 0, 0);
12484 rm -f conftest.$ac_objext conftest$ac_exeext
12485 if { (eval echo "$as_me:12485: \"$ac_link\"") >&5
12486 (eval $ac_link) 2>&5
12488 echo "$as_me:12488: \$? = $ac_status" >&5
12489 (exit $ac_status); } &&
12490 { ac_try='test -s conftest$ac_exeext'
12491 { (eval echo "$as_me:12491: \"$ac_try\"") >&5
12492 (eval $ac_try) 2>&5
12494 echo "$as_me:12494: \$? = $ac_status" >&5
12495 (exit $ac_status); }; }; then
12496 cf_cv_xt_x11_compat=yes
12498 echo "$as_me: failed program was:" >&5
12499 cat conftest.$ac_ext >&5
12500 cf_cv_xt_x11_compat=no
12502 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12504 echo "$as_me:12504: result: $cf_cv_xt_x11_compat" >&5
12505 echo "${ECHO_T}$cf_cv_xt_x11_compat" >&6
12506 if test "$cf_cv_xt_x11_compat" = no
12508 test -n "$verbose" && echo " work around broken X11 dependency" 1>&6
12510 echo "${as_me:-configure}:12510: testing work around broken X11 dependency ..." 1>&5
12512 # 2010/11/19 - good enough until a working Xt on Xcb is delivered.
12514 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists x11; then
12515 test -n "$verbose" && echo " found package x11" 1>&6
12517 echo "${as_me:-configure}:12517: testing found package x11 ..." 1>&5
12519 cf_pkgconfig_incs="`$PKG_CONFIG --cflags x11 2>/dev/null`"
12520 cf_pkgconfig_libs="`$PKG_CONFIG --libs x11 2>/dev/null`"
12521 test -n "$verbose" && echo " package x11 CFLAGS: $cf_pkgconfig_incs" 1>&6
12523 echo "${as_me:-configure}:12523: testing package x11 CFLAGS: $cf_pkgconfig_incs ..." 1>&5
12525 test -n "$verbose" && echo " package x11 LIBS: $cf_pkgconfig_libs" 1>&6
12527 echo "${as_me:-configure}:12527: testing package x11 LIBS: $cf_pkgconfig_libs ..." 1>&5
12532 cf_new_extra_cppflags=
12534 for cf_add_cflags in $cf_pkgconfig_incs
12536 case $cf_fix_cppflags in
12538 case $cf_add_cflags in
12539 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
12540 case $cf_add_cflags in
12542 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
12544 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12545 && test -z "${cf_tst_cflags}" \
12546 && cf_fix_cppflags=yes
12548 if test $cf_fix_cppflags = yes ; then
12550 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12551 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12554 elif test "${cf_tst_cflags}" = "\"'" ; then
12556 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12557 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12563 case "$CPPFLAGS" in
12567 case $cf_add_cflags in
12569 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12571 CPPFLAGS=`echo "$CPPFLAGS" | \
12572 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12573 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12578 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
12579 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
12586 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
12587 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
12594 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12595 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12597 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
12599 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12600 && test -z "${cf_tst_cflags}" \
12601 && cf_fix_cppflags=no
12606 if test -n "$cf_new_cflags" ; then
12608 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
12609 CFLAGS="${CFLAGS}$cf_new_cflags"
12613 if test -n "$cf_new_cppflags" ; then
12615 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
12616 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
12620 if test -n "$cf_new_extra_cppflags" ; then
12622 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
12623 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
12627 cf_add_libs="$cf_pkgconfig_libs"
12628 # Filter out duplicates - this happens with badly-designed ".pc" files...
12629 for cf_add_1lib in $LIBS
12631 for cf_add_2lib in $cf_add_libs
12633 if test "x$cf_add_1lib" = "x$cf_add_2lib"
12639 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
12641 LIBS="$cf_add_libs"
12648 test -n "$verbose" && echo " ...before $LIBS" 1>&6
12650 echo "${as_me:-configure}:12650: testing ...before $LIBS ..." 1>&5
12652 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%-lXt %-lXt -lX11 %" -e 's% % %g'`
12653 test -n "$verbose" && echo " ...after $LIBS" 1>&6
12655 echo "${as_me:-configure}:12655: testing ...after $LIBS ..." 1>&5
12663 echo "$as_me:12663: checking for usable X Toolkit package" >&5
12664 echo $ECHO_N "checking for usable X Toolkit package... $ECHO_C" >&6
12665 if test "${cf_cv_xt_ice_compat+set}" = set; then
12666 echo $ECHO_N "(cached) $ECHO_C" >&6
12669 cat >conftest.$ac_ext <<_ACEOF
12670 #line 12670 "configure"
12671 #include "confdefs.h"
12673 #include <X11/Shell.h>
12678 int num = IceConnectionNumber(0)
12684 rm -f conftest.$ac_objext conftest$ac_exeext
12685 if { (eval echo "$as_me:12685: \"$ac_link\"") >&5
12686 (eval $ac_link) 2>&5
12688 echo "$as_me:12688: \$? = $ac_status" >&5
12689 (exit $ac_status); } &&
12690 { ac_try='test -s conftest$ac_exeext'
12691 { (eval echo "$as_me:12691: \"$ac_try\"") >&5
12692 (eval $ac_try) 2>&5
12694 echo "$as_me:12694: \$? = $ac_status" >&5
12695 (exit $ac_status); }; }; then
12696 cf_cv_xt_ice_compat=yes
12698 echo "$as_me: failed program was:" >&5
12699 cat conftest.$ac_ext >&5
12700 cf_cv_xt_ice_compat=no
12702 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12704 echo "$as_me:12704: result: $cf_cv_xt_ice_compat" >&5
12705 echo "${ECHO_T}$cf_cv_xt_ice_compat" >&6
12707 if test "$cf_cv_xt_ice_compat" = no
12709 # workaround for broken ".pc" files used for X Toolkit.
12710 case "x$X_PRE_LIBS" in
12716 test -n "$verbose" && echo " work around broken ICE dependency" 1>&6
12718 echo "${as_me:-configure}:12718: testing work around broken ICE dependency ..." 1>&5
12720 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists ice; then
12721 test -n "$verbose" && echo " found package ice" 1>&6
12723 echo "${as_me:-configure}:12723: testing found package ice ..." 1>&5
12725 cf_pkgconfig_incs="`$PKG_CONFIG --cflags ice 2>/dev/null`"
12726 cf_pkgconfig_libs="`$PKG_CONFIG --libs ice 2>/dev/null`"
12727 test -n "$verbose" && echo " package ice CFLAGS: $cf_pkgconfig_incs" 1>&6
12729 echo "${as_me:-configure}:12729: testing package ice CFLAGS: $cf_pkgconfig_incs ..." 1>&5
12731 test -n "$verbose" && echo " package ice LIBS: $cf_pkgconfig_libs" 1>&6
12733 echo "${as_me:-configure}:12733: testing package ice LIBS: $cf_pkgconfig_libs ..." 1>&5
12738 cf_new_extra_cppflags=
12740 for cf_add_cflags in $cf_pkgconfig_incs
12742 case $cf_fix_cppflags in
12744 case $cf_add_cflags in
12745 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
12746 case $cf_add_cflags in
12748 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
12750 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12751 && test -z "${cf_tst_cflags}" \
12752 && cf_fix_cppflags=yes
12754 if test $cf_fix_cppflags = yes ; then
12756 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12757 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12760 elif test "${cf_tst_cflags}" = "\"'" ; then
12762 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12763 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12769 case "$CPPFLAGS" in
12773 case $cf_add_cflags in
12775 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12777 CPPFLAGS=`echo "$CPPFLAGS" | \
12778 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12779 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12784 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
12785 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
12792 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
12793 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
12800 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12801 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12803 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
12805 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12806 && test -z "${cf_tst_cflags}" \
12807 && cf_fix_cppflags=no
12812 if test -n "$cf_new_cflags" ; then
12814 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
12815 CFLAGS="${CFLAGS}$cf_new_cflags"
12819 if test -n "$cf_new_cppflags" ; then
12821 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
12822 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
12826 if test -n "$cf_new_extra_cppflags" ; then
12828 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
12829 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
12833 cf_add_libs="$cf_pkgconfig_libs"
12834 # Filter out duplicates - this happens with badly-designed ".pc" files...
12835 for cf_add_1lib in $LIBS
12837 for cf_add_2lib in $cf_add_libs
12839 if test "x$cf_add_1lib" = "x$cf_add_2lib"
12845 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
12847 LIBS="$cf_add_libs"
12849 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists sm; then
12850 test -n "$verbose" && echo " found package sm" 1>&6
12852 echo "${as_me:-configure}:12852: testing found package sm ..." 1>&5
12854 cf_pkgconfig_incs="`$PKG_CONFIG --cflags sm 2>/dev/null`"
12855 cf_pkgconfig_libs="`$PKG_CONFIG --libs sm 2>/dev/null`"
12856 test -n "$verbose" && echo " package sm CFLAGS: $cf_pkgconfig_incs" 1>&6
12858 echo "${as_me:-configure}:12858: testing package sm CFLAGS: $cf_pkgconfig_incs ..." 1>&5
12860 test -n "$verbose" && echo " package sm LIBS: $cf_pkgconfig_libs" 1>&6
12862 echo "${as_me:-configure}:12862: testing package sm LIBS: $cf_pkgconfig_libs ..." 1>&5
12867 cf_new_extra_cppflags=
12869 for cf_add_cflags in $cf_pkgconfig_incs
12871 case $cf_fix_cppflags in
12873 case $cf_add_cflags in
12874 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
12875 case $cf_add_cflags in
12877 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
12879 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12880 && test -z "${cf_tst_cflags}" \
12881 && cf_fix_cppflags=yes
12883 if test $cf_fix_cppflags = yes ; then
12885 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12886 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12889 elif test "${cf_tst_cflags}" = "\"'" ; then
12891 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12892 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12898 case "$CPPFLAGS" in
12902 case $cf_add_cflags in
12904 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12906 CPPFLAGS=`echo "$CPPFLAGS" | \
12907 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12908 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12913 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
12914 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
12921 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
12922 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
12929 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12930 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12932 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
12934 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12935 && test -z "${cf_tst_cflags}" \
12936 && cf_fix_cppflags=no
12941 if test -n "$cf_new_cflags" ; then
12943 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
12944 CFLAGS="${CFLAGS}$cf_new_cflags"
12948 if test -n "$cf_new_cppflags" ; then
12950 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
12951 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
12955 if test -n "$cf_new_extra_cppflags" ; then
12957 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
12958 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
12962 cf_add_libs="$cf_pkgconfig_libs"
12963 # Filter out duplicates - this happens with badly-designed ".pc" files...
12964 for cf_add_1lib in $LIBS
12966 for cf_add_2lib in $cf_add_libs
12968 if test "x$cf_add_1lib" = "x$cf_add_2lib"
12974 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
12976 LIBS="$cf_add_libs"
12989 test -n "$verbose" && echo " ...before $LIBS" 1>&6
12991 echo "${as_me:-configure}:12991: testing ...before $LIBS ..." 1>&5
12993 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%-lXt %-lXt $X_PRE_LIBS %" -e 's% % %g'`
12994 test -n "$verbose" && echo " ...after $LIBS" 1>&6
12996 echo "${as_me:-configure}:12996: testing ...after $LIBS ..." 1>&5
13012 LDFLAGS="$X_LIBS $LDFLAGS"
13014 test -n "$verbose" && echo " checking additions to CFLAGS" 1>&6
13016 echo "${as_me:-configure}:13016: testing checking additions to CFLAGS ..." 1>&5
13018 cf_check_cflags="$CFLAGS"
13019 cf_check_cppflags="$CPPFLAGS"
13024 cf_new_extra_cppflags=
13026 for cf_add_cflags in $X_CFLAGS
13028 case $cf_fix_cppflags in
13030 case $cf_add_cflags in
13031 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
13032 case $cf_add_cflags in
13034 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
13036 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13037 && test -z "${cf_tst_cflags}" \
13038 && cf_fix_cppflags=yes
13040 if test $cf_fix_cppflags = yes ; then
13042 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13043 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13046 elif test "${cf_tst_cflags}" = "\"'" ; then
13048 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13049 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13055 case "$CPPFLAGS" in
13059 case $cf_add_cflags in
13061 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
13063 CPPFLAGS=`echo "$CPPFLAGS" | \
13064 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
13065 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
13070 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
13071 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
13078 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
13079 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
13086 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13087 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13089 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
13091 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13092 && test -z "${cf_tst_cflags}" \
13093 && cf_fix_cppflags=no
13098 if test -n "$cf_new_cflags" ; then
13099 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
13101 echo "${as_me:-configure}:13101: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
13103 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
13104 CFLAGS="${CFLAGS}$cf_new_cflags"
13108 if test -n "$cf_new_cppflags" ; then
13109 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
13111 echo "${as_me:-configure}:13111: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
13113 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13114 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
13118 if test -n "$cf_new_extra_cppflags" ; then
13119 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
13121 echo "${as_me:-configure}:13121: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
13123 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
13124 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
13128 if test "x$cf_check_cflags" != "x$CFLAGS" ; then
13129 cat >conftest.$ac_ext <<_ACEOF
13130 #line 13130 "configure"
13131 #include "confdefs.h"
13136 printf("Hello world");
13141 rm -f conftest.$ac_objext conftest$ac_exeext
13142 if { (eval echo "$as_me:13142: \"$ac_link\"") >&5
13143 (eval $ac_link) 2>&5
13145 echo "$as_me:13145: \$? = $ac_status" >&5
13146 (exit $ac_status); } &&
13147 { ac_try='test -s conftest$ac_exeext'
13148 { (eval echo "$as_me:13148: \"$ac_try\"") >&5
13149 (eval $ac_try) 2>&5
13151 echo "$as_me:13151: \$? = $ac_status" >&5
13152 (exit $ac_status); }; }; then
13155 echo "$as_me: failed program was:" >&5
13156 cat conftest.$ac_ext >&5
13157 test -n "$verbose" && echo " test-compile failed. Undoing change to \$CFLAGS" 1>&6
13159 echo "${as_me:-configure}:13159: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5
13161 if test "x$cf_check_cppflags" != "x$CPPFLAGS" ; then
13162 test -n "$verbose" && echo " but keeping change to \$CPPFLAGS" 1>&6
13164 echo "${as_me:-configure}:13164: testing but keeping change to \$CPPFLAGS ..." 1>&5
13167 CFLAGS="$cf_check_flags"
13169 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13172 echo "$as_me:13172: checking for XOpenDisplay" >&5
13173 echo $ECHO_N "checking for XOpenDisplay... $ECHO_C" >&6
13174 if test "${ac_cv_func_XOpenDisplay+set}" = set; then
13175 echo $ECHO_N "(cached) $ECHO_C" >&6
13177 cat >conftest.$ac_ext <<_ACEOF
13178 #line 13178 "configure"
13179 #include "confdefs.h"
13180 /* System header to define __stub macros and hopefully few prototypes,
13181 which can conflict with char XOpenDisplay (); below. */
13182 #include <assert.h>
13183 /* Override any gcc2 internal prototype to avoid an error. */
13187 /* We use char because int might match the return type of a gcc2
13188 builtin and then its argument prototype would still apply. */
13189 char XOpenDisplay ();
13195 /* The GNU C library defines this for functions which it implements
13196 to always fail with ENOSYS. Some functions are actually named
13197 something starting with __ and the normal name is an alias. */
13198 #if defined (__stub_XOpenDisplay) || defined (__stub___XOpenDisplay)
13201 f = XOpenDisplay; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
13208 rm -f conftest.$ac_objext conftest$ac_exeext
13209 if { (eval echo "$as_me:13209: \"$ac_link\"") >&5
13210 (eval $ac_link) 2>&5
13212 echo "$as_me:13212: \$? = $ac_status" >&5
13213 (exit $ac_status); } &&
13214 { ac_try='test -s conftest$ac_exeext'
13215 { (eval echo "$as_me:13215: \"$ac_try\"") >&5
13216 (eval $ac_try) 2>&5
13218 echo "$as_me:13218: \$? = $ac_status" >&5
13219 (exit $ac_status); }; }; then
13220 ac_cv_func_XOpenDisplay=yes
13222 echo "$as_me: failed program was:" >&5
13223 cat conftest.$ac_ext >&5
13224 ac_cv_func_XOpenDisplay=no
13226 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13228 echo "$as_me:13228: result: $ac_cv_func_XOpenDisplay" >&5
13229 echo "${ECHO_T}$ac_cv_func_XOpenDisplay" >&6
13230 if test $ac_cv_func_XOpenDisplay = yes; then
13234 echo "$as_me:13234: checking for XOpenDisplay in -lX11" >&5
13235 echo $ECHO_N "checking for XOpenDisplay in -lX11... $ECHO_C" >&6
13236 if test "${ac_cv_lib_X11_XOpenDisplay+set}" = set; then
13237 echo $ECHO_N "(cached) $ECHO_C" >&6
13239 ac_check_lib_save_LIBS=$LIBS
13240 LIBS="-lX11 $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
13241 cat >conftest.$ac_ext <<_ACEOF
13242 #line 13242 "configure"
13243 #include "confdefs.h"
13245 /* Override any gcc2 internal prototype to avoid an error. */
13249 /* We use char because int might match the return type of a gcc2
13250 builtin and then its argument prototype would still apply. */
13251 char XOpenDisplay ();
13260 rm -f conftest.$ac_objext conftest$ac_exeext
13261 if { (eval echo "$as_me:13261: \"$ac_link\"") >&5
13262 (eval $ac_link) 2>&5
13264 echo "$as_me:13264: \$? = $ac_status" >&5
13265 (exit $ac_status); } &&
13266 { ac_try='test -s conftest$ac_exeext'
13267 { (eval echo "$as_me:13267: \"$ac_try\"") >&5
13268 (eval $ac_try) 2>&5
13270 echo "$as_me:13270: \$? = $ac_status" >&5
13271 (exit $ac_status); }; }; then
13272 ac_cv_lib_X11_XOpenDisplay=yes
13274 echo "$as_me: failed program was:" >&5
13275 cat conftest.$ac_ext >&5
13276 ac_cv_lib_X11_XOpenDisplay=no
13278 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13279 LIBS=$ac_check_lib_save_LIBS
13281 echo "$as_me:13281: result: $ac_cv_lib_X11_XOpenDisplay" >&5
13282 echo "${ECHO_T}$ac_cv_lib_X11_XOpenDisplay" >&6
13283 if test $ac_cv_lib_X11_XOpenDisplay = yes; then
13285 cf_add_libs="-lX11"
13286 # Filter out duplicates - this happens with badly-designed ".pc" files...
13287 for cf_add_1lib in $LIBS
13289 for cf_add_2lib in $cf_add_libs
13291 if test "x$cf_add_1lib" = "x$cf_add_2lib"
13297 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
13299 LIBS="$cf_add_libs"
13305 echo "$as_me:13305: checking for XtAppInitialize" >&5
13306 echo $ECHO_N "checking for XtAppInitialize... $ECHO_C" >&6
13307 if test "${ac_cv_func_XtAppInitialize+set}" = set; then
13308 echo $ECHO_N "(cached) $ECHO_C" >&6
13310 cat >conftest.$ac_ext <<_ACEOF
13311 #line 13311 "configure"
13312 #include "confdefs.h"
13313 /* System header to define __stub macros and hopefully few prototypes,
13314 which can conflict with char XtAppInitialize (); below. */
13315 #include <assert.h>
13316 /* Override any gcc2 internal prototype to avoid an error. */
13320 /* We use char because int might match the return type of a gcc2
13321 builtin and then its argument prototype would still apply. */
13322 char XtAppInitialize ();
13328 /* The GNU C library defines this for functions which it implements
13329 to always fail with ENOSYS. Some functions are actually named
13330 something starting with __ and the normal name is an alias. */
13331 #if defined (__stub_XtAppInitialize) || defined (__stub___XtAppInitialize)
13334 f = XtAppInitialize; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
13341 rm -f conftest.$ac_objext conftest$ac_exeext
13342 if { (eval echo "$as_me:13342: \"$ac_link\"") >&5
13343 (eval $ac_link) 2>&5
13345 echo "$as_me:13345: \$? = $ac_status" >&5
13346 (exit $ac_status); } &&
13347 { ac_try='test -s conftest$ac_exeext'
13348 { (eval echo "$as_me:13348: \"$ac_try\"") >&5
13349 (eval $ac_try) 2>&5
13351 echo "$as_me:13351: \$? = $ac_status" >&5
13352 (exit $ac_status); }; }; then
13353 ac_cv_func_XtAppInitialize=yes
13355 echo "$as_me: failed program was:" >&5
13356 cat conftest.$ac_ext >&5
13357 ac_cv_func_XtAppInitialize=no
13359 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13361 echo "$as_me:13361: result: $ac_cv_func_XtAppInitialize" >&5
13362 echo "${ECHO_T}$ac_cv_func_XtAppInitialize" >&6
13363 if test $ac_cv_func_XtAppInitialize = yes; then
13367 echo "$as_me:13367: checking for XtAppInitialize in -lXt" >&5
13368 echo $ECHO_N "checking for XtAppInitialize in -lXt... $ECHO_C" >&6
13369 if test "${ac_cv_lib_Xt_XtAppInitialize+set}" = set; then
13370 echo $ECHO_N "(cached) $ECHO_C" >&6
13372 ac_check_lib_save_LIBS=$LIBS
13373 LIBS="-lXt $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
13374 cat >conftest.$ac_ext <<_ACEOF
13375 #line 13375 "configure"
13376 #include "confdefs.h"
13378 /* Override any gcc2 internal prototype to avoid an error. */
13382 /* We use char because int might match the return type of a gcc2
13383 builtin and then its argument prototype would still apply. */
13384 char XtAppInitialize ();
13388 XtAppInitialize ();
13393 rm -f conftest.$ac_objext conftest$ac_exeext
13394 if { (eval echo "$as_me:13394: \"$ac_link\"") >&5
13395 (eval $ac_link) 2>&5
13397 echo "$as_me:13397: \$? = $ac_status" >&5
13398 (exit $ac_status); } &&
13399 { ac_try='test -s conftest$ac_exeext'
13400 { (eval echo "$as_me:13400: \"$ac_try\"") >&5
13401 (eval $ac_try) 2>&5
13403 echo "$as_me:13403: \$? = $ac_status" >&5
13404 (exit $ac_status); }; }; then
13405 ac_cv_lib_Xt_XtAppInitialize=yes
13407 echo "$as_me: failed program was:" >&5
13408 cat conftest.$ac_ext >&5
13409 ac_cv_lib_Xt_XtAppInitialize=no
13411 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13412 LIBS=$ac_check_lib_save_LIBS
13414 echo "$as_me:13414: result: $ac_cv_lib_Xt_XtAppInitialize" >&5
13415 echo "${ECHO_T}$ac_cv_lib_Xt_XtAppInitialize" >&6
13416 if test $ac_cv_lib_Xt_XtAppInitialize = yes; then
13418 cat >>confdefs.h <<\EOF
13419 #define HAVE_LIBXT 1
13423 LIBS="-lXt $X_PRE_LIBS $LIBS $X_EXTRA_LIBS"
13430 if test $cf_have_X_LIBS = no ; then
13431 { echo "$as_me:13431: WARNING: Unable to successfully link X Toolkit library (-lXt) with
13432 test program. You will have to check and add the proper libraries by hand
13434 echo "$as_me: WARNING: Unable to successfully link X Toolkit library (-lXt) with
13435 test program. You will have to check and add the proper libraries by hand
13436 to makefile." >&2;}
13439 cf_x_athena_root=$cf_x_athena
13442 for cf_path in default \
13443 /usr/contrib/X11R6 \
13444 /usr/contrib/X11R5 \
13448 if test -z "$cf_x_athena_inc" ; then
13449 cf_save="$CPPFLAGS"
13450 cf_test=X11/$cf_x_athena_root/SimpleMenu.h
13451 if test $cf_path != default ; then
13452 CPPFLAGS="$cf_save -I$cf_path/include"
13453 echo "$as_me:13453: checking for $cf_test in $cf_path" >&5
13454 echo $ECHO_N "checking for $cf_test in $cf_path... $ECHO_C" >&6
13456 echo "$as_me:13456: checking for $cf_test" >&5
13457 echo $ECHO_N "checking for $cf_test... $ECHO_C" >&6
13459 cat >conftest.$ac_ext <<_ACEOF
13460 #line 13460 "configure"
13461 #include "confdefs.h"
13463 #include <X11/Intrinsic.h>
13464 #include <$cf_test>
13473 rm -f conftest.$ac_objext
13474 if { (eval echo "$as_me:13474: \"$ac_compile\"") >&5
13475 (eval $ac_compile) 2>&5
13477 echo "$as_me:13477: \$? = $ac_status" >&5
13478 (exit $ac_status); } &&
13479 { ac_try='test -s conftest.$ac_objext'
13480 { (eval echo "$as_me:13480: \"$ac_try\"") >&5
13481 (eval $ac_try) 2>&5
13483 echo "$as_me:13483: \$? = $ac_status" >&5
13484 (exit $ac_status); }; }; then
13487 echo "$as_me: failed program was:" >&5
13488 cat conftest.$ac_ext >&5
13491 rm -f conftest.$ac_objext conftest.$ac_ext
13492 echo "$as_me:13492: result: $cf_result" >&5
13493 echo "${ECHO_T}$cf_result" >&6
13494 if test "$cf_result" = yes ; then
13495 cf_x_athena_inc=$cf_path
13498 CPPFLAGS="$cf_save"
13503 if test -z "$cf_x_athena_inc" ; then
13504 { echo "$as_me:13504: WARNING: Unable to successfully find Athena header files with test program" >&5
13505 echo "$as_me: WARNING: Unable to successfully find Athena header files with test program" >&2;}
13506 elif test "$cf_x_athena_inc" != default ; then
13507 CPPFLAGS="$CPPFLAGS -I$cf_x_athena_inc"
13510 cf_x_athena_root=$cf_x_athena
13513 for cf_path in default \
13514 /usr/contrib/X11R6 \
13515 /usr/contrib/X11R5 \
13520 ${cf_x_athena_root} \
13521 ${cf_x_athena_root}7 \
13522 ${cf_x_athena_root}6
13525 "-l$cf_lib -lXmu" \
13526 "-l$cf_lib -lXpm -lXmu" \
13527 "-l${cf_lib}_s -lXmu_s"
13529 if test -z "$cf_x_athena_lib" ; then
13531 cf_test=XawSimpleMenuAddGlobalActions
13532 if test $cf_path != default ; then
13534 cf_add_libs="-L$cf_path/lib $cf_libs"
13535 # Filter out duplicates - this happens with badly-designed ".pc" files...
13536 for cf_add_1lib in $LIBS
13538 for cf_add_2lib in $cf_add_libs
13540 if test "x$cf_add_1lib" = "x$cf_add_2lib"
13546 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
13548 LIBS="$cf_add_libs"
13550 echo "$as_me:13550: checking for $cf_libs in $cf_path" >&5
13551 echo $ECHO_N "checking for $cf_libs in $cf_path... $ECHO_C" >&6
13554 cf_add_libs="$cf_libs"
13555 # Filter out duplicates - this happens with badly-designed ".pc" files...
13556 for cf_add_1lib in $LIBS
13558 for cf_add_2lib in $cf_add_libs
13560 if test "x$cf_add_1lib" = "x$cf_add_2lib"
13566 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
13568 LIBS="$cf_add_libs"
13570 echo "$as_me:13570: checking for $cf_test in $cf_libs" >&5
13571 echo $ECHO_N "checking for $cf_test in $cf_libs... $ECHO_C" >&6
13573 cat >conftest.$ac_ext <<_ACEOF
13574 #line 13574 "configure"
13575 #include "confdefs.h"
13577 #include <X11/Intrinsic.h>
13578 #include <X11/$cf_x_athena_root/SimpleMenu.h>
13584 $cf_test((XtAppContext) 0)
13589 rm -f conftest.$ac_objext conftest$ac_exeext
13590 if { (eval echo "$as_me:13590: \"$ac_link\"") >&5
13591 (eval $ac_link) 2>&5
13593 echo "$as_me:13593: \$? = $ac_status" >&5
13594 (exit $ac_status); } &&
13595 { ac_try='test -s conftest$ac_exeext'
13596 { (eval echo "$as_me:13596: \"$ac_try\"") >&5
13597 (eval $ac_try) 2>&5
13599 echo "$as_me:13599: \$? = $ac_status" >&5
13600 (exit $ac_status); }; }; then
13603 echo "$as_me: failed program was:" >&5
13604 cat conftest.$ac_ext >&5
13607 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13608 echo "$as_me:13608: result: $cf_result" >&5
13609 echo "${ECHO_T}$cf_result" >&6
13610 if test "$cf_result" = yes ; then
13611 cf_x_athena_lib="$cf_libs"
13617 test -n "$cf_x_athena_lib" && break
13621 if test -z "$cf_x_athena_lib" ; then
13622 { { echo "$as_me:13622: error: Unable to successfully link Athena library (-l$cf_x_athena_root) with test program" >&5
13623 echo "$as_me: error: Unable to successfully link Athena library (-l$cf_x_athena_root) with test program" >&2;}
13624 { (exit 1); exit 1; }; }
13627 cf_x_athena_LIBS=`echo "HAVE_LIB_$cf_x_athena" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
13629 cat >>confdefs.h <<EOF
13630 #define $cf_x_athena_LIBS 1
13635 if test -n "$ac_tool_prefix"; then
13636 for ac_prog in xcurses-config
13638 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
13639 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
13640 echo "$as_me:13640: checking for $ac_word" >&5
13641 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
13642 if test "${ac_cv_prog_XCURSES_CONFIG+set}" = set; then
13643 echo $ECHO_N "(cached) $ECHO_C" >&6
13645 if test -n "$XCURSES_CONFIG"; then
13646 ac_cv_prog_XCURSES_CONFIG="$XCURSES_CONFIG" # Let the user override the test.
13648 ac_save_IFS=$IFS; IFS=$ac_path_separator
13650 for ac_dir in $ac_dummy; do
13652 test -z "$ac_dir" && ac_dir=.
13653 $as_executable_p "$ac_dir/$ac_word" || continue
13654 ac_cv_prog_XCURSES_CONFIG="$ac_tool_prefix$ac_prog"
13655 echo "$as_me:13655: found $ac_dir/$ac_word" >&5
13661 XCURSES_CONFIG=$ac_cv_prog_XCURSES_CONFIG
13662 if test -n "$XCURSES_CONFIG"; then
13663 echo "$as_me:13663: result: $XCURSES_CONFIG" >&5
13664 echo "${ECHO_T}$XCURSES_CONFIG" >&6
13666 echo "$as_me:13666: result: no" >&5
13667 echo "${ECHO_T}no" >&6
13670 test -n "$XCURSES_CONFIG" && break
13673 if test -z "$XCURSES_CONFIG"; then
13674 ac_ct_XCURSES_CONFIG=$XCURSES_CONFIG
13675 for ac_prog in xcurses-config
13677 # Extract the first word of "$ac_prog", so it can be a program name with args.
13678 set dummy $ac_prog; ac_word=$2
13679 echo "$as_me:13679: checking for $ac_word" >&5
13680 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
13681 if test "${ac_cv_prog_ac_ct_XCURSES_CONFIG+set}" = set; then
13682 echo $ECHO_N "(cached) $ECHO_C" >&6
13684 if test -n "$ac_ct_XCURSES_CONFIG"; then
13685 ac_cv_prog_ac_ct_XCURSES_CONFIG="$ac_ct_XCURSES_CONFIG" # Let the user override the test.
13687 ac_save_IFS=$IFS; IFS=$ac_path_separator
13689 for ac_dir in $ac_dummy; do
13691 test -z "$ac_dir" && ac_dir=.
13692 $as_executable_p "$ac_dir/$ac_word" || continue
13693 ac_cv_prog_ac_ct_XCURSES_CONFIG="$ac_prog"
13694 echo "$as_me:13694: found $ac_dir/$ac_word" >&5
13700 ac_ct_XCURSES_CONFIG=$ac_cv_prog_ac_ct_XCURSES_CONFIG
13701 if test -n "$ac_ct_XCURSES_CONFIG"; then
13702 echo "$as_me:13702: result: $ac_ct_XCURSES_CONFIG" >&5
13703 echo "${ECHO_T}$ac_ct_XCURSES_CONFIG" >&6
13705 echo "$as_me:13705: result: no" >&5
13706 echo "${ECHO_T}no" >&6
13709 test -n "$ac_ct_XCURSES_CONFIG" && break
13711 test -n "$ac_ct_XCURSES_CONFIG" || ac_ct_XCURSES_CONFIG="none"
13713 XCURSES_CONFIG=$ac_ct_XCURSES_CONFIG
13716 if test "$XCURSES_CONFIG" != none ; then
13718 CPPFLAGS="$CPPFLAGS `$XCURSES_CONFIG --cflags`"
13720 cf_add_libs="`$XCURSES_CONFIG --libs`"
13721 # Filter out duplicates - this happens with badly-designed ".pc" files...
13722 for cf_add_1lib in $LIBS
13724 for cf_add_2lib in $cf_add_libs
13726 if test "x$cf_add_1lib" = "x$cf_add_2lib"
13732 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
13734 LIBS="$cf_add_libs"
13736 cf_cv_lib_XCurses=yes
13740 LDFLAGS="$LDFLAGS $X_LIBS"
13742 test -n "$verbose" && echo " checking additions to CFLAGS" 1>&6
13744 echo "${as_me:-configure}:13744: testing checking additions to CFLAGS ..." 1>&5
13746 cf_check_cflags="$CFLAGS"
13747 cf_check_cppflags="$CPPFLAGS"
13752 cf_new_extra_cppflags=
13754 for cf_add_cflags in $X_CFLAGS
13756 case $cf_fix_cppflags in
13758 case $cf_add_cflags in
13759 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
13760 case $cf_add_cflags in
13762 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
13764 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13765 && test -z "${cf_tst_cflags}" \
13766 && cf_fix_cppflags=yes
13768 if test $cf_fix_cppflags = yes ; then
13770 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13771 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13774 elif test "${cf_tst_cflags}" = "\"'" ; then
13776 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13777 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13783 case "$CPPFLAGS" in
13787 case $cf_add_cflags in
13789 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
13791 CPPFLAGS=`echo "$CPPFLAGS" | \
13792 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
13793 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
13798 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
13799 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
13806 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
13807 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
13814 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13815 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13817 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
13819 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13820 && test -z "${cf_tst_cflags}" \
13821 && cf_fix_cppflags=no
13826 if test -n "$cf_new_cflags" ; then
13827 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
13829 echo "${as_me:-configure}:13829: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
13831 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
13832 CFLAGS="${CFLAGS}$cf_new_cflags"
13836 if test -n "$cf_new_cppflags" ; then
13837 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
13839 echo "${as_me:-configure}:13839: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
13841 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13842 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
13846 if test -n "$cf_new_extra_cppflags" ; then
13847 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
13849 echo "${as_me:-configure}:13849: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
13851 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
13852 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
13856 if test "x$cf_check_cflags" != "x$CFLAGS" ; then
13857 cat >conftest.$ac_ext <<_ACEOF
13858 #line 13858 "configure"
13859 #include "confdefs.h"
13864 printf("Hello world");
13869 rm -f conftest.$ac_objext conftest$ac_exeext
13870 if { (eval echo "$as_me:13870: \"$ac_link\"") >&5
13871 (eval $ac_link) 2>&5
13873 echo "$as_me:13873: \$? = $ac_status" >&5
13874 (exit $ac_status); } &&
13875 { ac_try='test -s conftest$ac_exeext'
13876 { (eval echo "$as_me:13876: \"$ac_try\"") >&5
13877 (eval $ac_try) 2>&5
13879 echo "$as_me:13879: \$? = $ac_status" >&5
13880 (exit $ac_status); }; }; then
13883 echo "$as_me: failed program was:" >&5
13884 cat conftest.$ac_ext >&5
13885 test -n "$verbose" && echo " test-compile failed. Undoing change to \$CFLAGS" 1>&6
13887 echo "${as_me:-configure}:13887: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5
13889 if test "x$cf_check_cppflags" != "x$CPPFLAGS" ; then
13890 test -n "$verbose" && echo " but keeping change to \$CPPFLAGS" 1>&6
13892 echo "${as_me:-configure}:13892: testing but keeping change to \$CPPFLAGS ..." 1>&5
13895 CFLAGS="$cf_check_flags"
13897 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13900 echo "$as_me:13900: checking for XOpenDisplay in -lX11" >&5
13901 echo $ECHO_N "checking for XOpenDisplay in -lX11... $ECHO_C" >&6
13902 if test "${ac_cv_lib_X11_XOpenDisplay+set}" = set; then
13903 echo $ECHO_N "(cached) $ECHO_C" >&6
13905 ac_check_lib_save_LIBS=$LIBS
13906 LIBS="-lX11 $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
13907 cat >conftest.$ac_ext <<_ACEOF
13908 #line 13908 "configure"
13909 #include "confdefs.h"
13911 /* Override any gcc2 internal prototype to avoid an error. */
13915 /* We use char because int might match the return type of a gcc2
13916 builtin and then its argument prototype would still apply. */
13917 char XOpenDisplay ();
13926 rm -f conftest.$ac_objext conftest$ac_exeext
13927 if { (eval echo "$as_me:13927: \"$ac_link\"") >&5
13928 (eval $ac_link) 2>&5
13930 echo "$as_me:13930: \$? = $ac_status" >&5
13931 (exit $ac_status); } &&
13932 { ac_try='test -s conftest$ac_exeext'
13933 { (eval echo "$as_me:13933: \"$ac_try\"") >&5
13934 (eval $ac_try) 2>&5
13936 echo "$as_me:13936: \$? = $ac_status" >&5
13937 (exit $ac_status); }; }; then
13938 ac_cv_lib_X11_XOpenDisplay=yes
13940 echo "$as_me: failed program was:" >&5
13941 cat conftest.$ac_ext >&5
13942 ac_cv_lib_X11_XOpenDisplay=no
13944 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13945 LIBS=$ac_check_lib_save_LIBS
13947 echo "$as_me:13947: result: $ac_cv_lib_X11_XOpenDisplay" >&5
13948 echo "${ECHO_T}$ac_cv_lib_X11_XOpenDisplay" >&6
13949 if test $ac_cv_lib_X11_XOpenDisplay = yes; then
13951 cf_add_libs="-lX11"
13952 # Filter out duplicates - this happens with badly-designed ".pc" files...
13953 for cf_add_1lib in $LIBS
13955 for cf_add_2lib in $cf_add_libs
13957 if test "x$cf_add_1lib" = "x$cf_add_2lib"
13963 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
13965 LIBS="$cf_add_libs"
13969 echo "$as_me:13969: checking for XCurses library" >&5
13970 echo $ECHO_N "checking for XCurses library... $ECHO_C" >&6
13971 if test "${cf_cv_lib_XCurses+set}" = set; then
13972 echo $ECHO_N "(cached) $ECHO_C" >&6
13975 cf_add_libs="-lXCurses"
13976 # Filter out duplicates - this happens with badly-designed ".pc" files...
13977 for cf_add_1lib in $LIBS
13979 for cf_add_2lib in $cf_add_libs
13981 if test "x$cf_add_1lib" = "x$cf_add_2lib"
13987 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
13989 LIBS="$cf_add_libs"
13991 cat >conftest.$ac_ext <<_ACEOF
13992 #line 13992 "configure"
13993 #include "confdefs.h"
13995 #include <xcurses.h>
13996 char *XCursesProgramName = "test";
14006 rm -f conftest.$ac_objext conftest$ac_exeext
14007 if { (eval echo "$as_me:14007: \"$ac_link\"") >&5
14008 (eval $ac_link) 2>&5
14010 echo "$as_me:14010: \$? = $ac_status" >&5
14011 (exit $ac_status); } &&
14012 { ac_try='test -s conftest$ac_exeext'
14013 { (eval echo "$as_me:14013: \"$ac_try\"") >&5
14014 (eval $ac_try) 2>&5
14016 echo "$as_me:14016: \$? = $ac_status" >&5
14017 (exit $ac_status); }; }; then
14018 cf_cv_lib_XCurses=yes
14020 echo "$as_me: failed program was:" >&5
14021 cat conftest.$ac_ext >&5
14022 cf_cv_lib_XCurses=no
14024 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14027 echo "$as_me:14027: result: $cf_cv_lib_XCurses" >&5
14028 echo "${ECHO_T}$cf_cv_lib_XCurses" >&6
14032 if test $cf_cv_lib_XCurses = yes ; then
14034 cat >>confdefs.h <<\EOF
14038 cat >>confdefs.h <<\EOF
14042 echo "$as_me:14042: checking for xcurses.h" >&5
14043 echo $ECHO_N "checking for xcurses.h... $ECHO_C" >&6
14044 if test "${ac_cv_header_xcurses_h+set}" = set; then
14045 echo $ECHO_N "(cached) $ECHO_C" >&6
14047 cat >conftest.$ac_ext <<_ACEOF
14048 #line 14048 "configure"
14049 #include "confdefs.h"
14050 #include <xcurses.h>
14052 if { (eval echo "$as_me:14052: \"$ac_cpp conftest.$ac_ext\"") >&5
14053 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
14055 egrep -v '^ *\+' conftest.er1 >conftest.err
14057 cat conftest.err >&5
14058 echo "$as_me:14058: \$? = $ac_status" >&5
14059 (exit $ac_status); } >/dev/null; then
14060 if test -s conftest.err; then
14061 ac_cpp_err=$ac_c_preproc_warn_flag
14068 if test -z "$ac_cpp_err"; then
14069 ac_cv_header_xcurses_h=yes
14071 echo "$as_me: failed program was:" >&5
14072 cat conftest.$ac_ext >&5
14073 ac_cv_header_xcurses_h=no
14075 rm -f conftest.err conftest.$ac_ext
14077 echo "$as_me:14077: result: $ac_cv_header_xcurses_h" >&5
14078 echo "${ECHO_T}$ac_cv_header_xcurses_h" >&6
14079 if test $ac_cv_header_xcurses_h = yes; then
14081 cat >>confdefs.h <<\EOF
14082 #define HAVE_XCURSES 1
14088 { { echo "$as_me:14088: error: Cannot link with XCurses" >&5
14089 echo "$as_me: error: Cannot link with XCurses" >&2;}
14090 { (exit 1); exit 1; }; }
14095 { { echo "$as_me:14095: error: unexpected screen-value: $cf_cv_screen" >&5
14096 echo "$as_me: error: unexpected screen-value: $cf_cv_screen" >&2;}
14097 { (exit 1); exit 1; }; }
14101 : ${cf_nculib_root:=$cf_cv_screen}
14102 as_ac_Lib=`echo "ac_cv_lib_$cf_nculib_root''__nc_init_pthreads" | $as_tr_sh`
14103 echo "$as_me:14103: checking for _nc_init_pthreads in -l$cf_nculib_root" >&5
14104 echo $ECHO_N "checking for _nc_init_pthreads in -l$cf_nculib_root... $ECHO_C" >&6
14105 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
14106 echo $ECHO_N "(cached) $ECHO_C" >&6
14108 ac_check_lib_save_LIBS=$LIBS
14109 LIBS="-l$cf_nculib_root $LIBS"
14110 cat >conftest.$ac_ext <<_ACEOF
14111 #line 14111 "configure"
14112 #include "confdefs.h"
14114 /* Override any gcc2 internal prototype to avoid an error. */
14118 /* We use char because int might match the return type of a gcc2
14119 builtin and then its argument prototype would still apply. */
14120 char _nc_init_pthreads ();
14124 _nc_init_pthreads ();
14129 rm -f conftest.$ac_objext conftest$ac_exeext
14130 if { (eval echo "$as_me:14130: \"$ac_link\"") >&5
14131 (eval $ac_link) 2>&5
14133 echo "$as_me:14133: \$? = $ac_status" >&5
14134 (exit $ac_status); } &&
14135 { ac_try='test -s conftest$ac_exeext'
14136 { (eval echo "$as_me:14136: \"$ac_try\"") >&5
14137 (eval $ac_try) 2>&5
14139 echo "$as_me:14139: \$? = $ac_status" >&5
14140 (exit $ac_status); }; }; then
14141 eval "$as_ac_Lib=yes"
14143 echo "$as_me: failed program was:" >&5
14144 cat conftest.$ac_ext >&5
14145 eval "$as_ac_Lib=no"
14147 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14148 LIBS=$ac_check_lib_save_LIBS
14150 echo "$as_me:14150: result: `eval echo '${'$as_ac_Lib'}'`" >&5
14151 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
14152 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
14153 cf_cv_ncurses_pthreads=yes
14155 cf_cv_ncurses_pthreads=no
14158 if test "$cf_cv_ncurses_pthreads" = yes
14161 cf_add_libs="-lpthread"
14162 # Filter out duplicates - this happens with badly-designed ".pc" files...
14163 for cf_add_1lib in $LIBS
14165 for cf_add_2lib in $cf_add_libs
14167 if test "x$cf_add_1lib" = "x$cf_add_2lib"
14173 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
14175 LIBS="$cf_add_libs"
14179 case $cf_cv_screen in
14181 cf_cv_libtype=`echo "$cf_cv_screen" | sed -e 's/^ncurses//'`
14185 echo "$as_me:14185: checking for X11 rgb file" >&5
14186 echo $ECHO_N "checking for X11 rgb file... $ECHO_C" >&6
14188 # Check whether --with-x11-rgb or --without-x11-rgb was given.
14189 if test "${with_x11_rgb+set}" = set; then
14190 withval="$with_x11_rgb"
14196 if test "x$RGB_PATH" = xauto
14198 RGB_PATH='${exec_prefix}/lib/X11/rgb.txt'
14200 /opt/local/share/X11/rgb.txt \
14201 /opt/X11/share/X11/rgb.txt \
14202 /usr/share/X11/rgb.txt \
14203 /usr/X11/share/X11/rgb.txt \
14204 /usr/X11/lib/X11/rgb.txt \
14205 /usr/lib/X11/rgb.txt \
14207 /usr/pkg/lib/X11/rgb.txt \
14208 /usr/X11R7/lib/X11/rgb.txt \
14209 /usr/X11R6/lib/X11/rgb.txt \
14210 /usr/X11R5/lib/X11/rgb.txt \
14211 /usr/X11R4/lib/X11/rgb.txt \
14212 /usr/local/lib/X11/rgb.txt \
14213 /usr/local/share/X11/rgb.txt \
14214 /usr/lib64/X11/rgb.txt
14216 if test -f "$cf_path" ; then
14217 RGB_PATH="$cf_path"
14224 if test "x$prefix" != xNONE; then
14225 cf_path_syntax="$prefix"
14227 cf_path_syntax="$ac_default_prefix"
14230 case ".$cf_path" in
14231 (.\$\(*\)*|.\'*\'*)
14235 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
14237 (.\${*prefix}*|.\${*dir}*)
14238 eval cf_path="$cf_path"
14239 case ".$cf_path" in
14241 cf_path=`echo $cf_path | sed -e s%NONE%$cf_path_syntax%`
14246 cf_path=`echo $cf_path | sed -e s%NONE%$cf_path_syntax%`
14249 { { echo "$as_me:14249: error: expected a pathname, not \"$cf_path\"" >&5
14250 echo "$as_me: error: expected a pathname, not \"$cf_path\"" >&2;}
14251 { (exit 1); exit 1; }; }
14257 echo "$as_me:14257: result: $RGB_PATH" >&5
14258 echo "${ECHO_T}$RGB_PATH" >&6
14260 cat >>confdefs.h <<EOF
14261 #define RGB_PATH "$cf_path"
14265 if test "$RGB_PATH" = no
14272 case $cf_cv_screen in
14274 cf_default_panel=no
14277 cf_default_tinfo=no
14279 (xcurses|bsdcurses)
14280 cf_default_panel=no
14283 cf_default_tinfo=yes
14286 cf_default_panel=yes
14287 cf_default_form=yes
14288 cf_default_menu=yes
14289 cf_default_tinfo=yes
14290 case $cf_cv_screen in
14292 cf_curses_headers="nc_alloc.h nomacros.h term_entry.h"
14298 echo "$as_me:14298: checking if you want to check for panel functions" >&5
14299 echo $ECHO_N "checking if you want to check for panel functions... $ECHO_C" >&6
14301 # Check whether --enable-panel or --disable-panel was given.
14302 if test "${enable_panel+set}" = set; then
14303 enableval="$enable_panel"
14304 test "$enableval" != no && enableval=yes
14305 if test "$enableval" != "yes" ; then
14308 cf_enable_panel=$cf_default_panel
14312 cf_enable_panel=$cf_default_panel
14315 echo "$as_me:14315: result: $cf_enable_panel" >&5
14316 echo "${ECHO_T}$cf_enable_panel" >&6
14317 if test $cf_enable_panel = yes
14320 cf_have_curses_lib=no
14322 : ${NCURSES_CONFIG_PKG:=none}
14323 if test "x${NCURSES_CONFIG_PKG}" = xnone; then
14325 elif test "x${PKG_CONFIG:=none}" != xnone; then
14326 echo "$as_me:14326: checking pkg-config for panel$cf_cv_libtype" >&5
14327 echo $ECHO_N "checking pkg-config for panel$cf_cv_libtype... $ECHO_C" >&6
14328 if "$PKG_CONFIG" --exists panel$cf_cv_libtype ; then
14329 echo "$as_me:14329: result: yes" >&5
14330 echo "${ECHO_T}yes" >&6
14332 echo "$as_me:14332: checking if the panel$cf_cv_libtype package files work" >&5
14333 echo $ECHO_N "checking if the panel$cf_cv_libtype package files work... $ECHO_C" >&6
14335 cf_save_CPPFLAGS="$CPPFLAGS"
14336 cf_save_LIBS="$LIBS"
14341 cf_new_extra_cppflags=
14343 for cf_add_cflags in `$PKG_CONFIG --cflags panel$cf_cv_libtype`
14345 case $cf_fix_cppflags in
14347 case $cf_add_cflags in
14348 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
14349 case $cf_add_cflags in
14351 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
14353 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14354 && test -z "${cf_tst_cflags}" \
14355 && cf_fix_cppflags=yes
14357 if test $cf_fix_cppflags = yes ; then
14359 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14360 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14363 elif test "${cf_tst_cflags}" = "\"'" ; then
14365 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14366 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14372 case "$CPPFLAGS" in
14376 case $cf_add_cflags in
14378 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
14380 CPPFLAGS=`echo "$CPPFLAGS" | \
14381 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
14382 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
14387 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
14388 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
14395 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
14396 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
14403 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14404 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14406 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
14408 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14409 && test -z "${cf_tst_cflags}" \
14410 && cf_fix_cppflags=no
14415 if test -n "$cf_new_cflags" ; then
14417 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
14418 CFLAGS="${CFLAGS}$cf_new_cflags"
14422 if test -n "$cf_new_cppflags" ; then
14424 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
14425 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
14429 if test -n "$cf_new_extra_cppflags" ; then
14431 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
14432 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
14436 cf_add_libs="`$PKG_CONFIG --libs panel$cf_cv_libtype`"
14437 # Filter out duplicates - this happens with badly-designed ".pc" files...
14438 for cf_add_1lib in $LIBS
14440 for cf_add_2lib in $cf_add_libs
14442 if test "x$cf_add_1lib" = "x$cf_add_2lib"
14448 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
14450 LIBS="$cf_add_libs"
14452 cat >conftest.$ac_ext <<_ACEOF
14453 #line 14453 "configure"
14454 #include "confdefs.h"
14459 (void) new_panel ( 0 );
14464 rm -f conftest.$ac_objext conftest$ac_exeext
14465 if { (eval echo "$as_me:14465: \"$ac_link\"") >&5
14466 (eval $ac_link) 2>&5
14468 echo "$as_me:14468: \$? = $ac_status" >&5
14469 (exit $ac_status); } &&
14470 { ac_try='test -s conftest$ac_exeext'
14471 { (eval echo "$as_me:14471: \"$ac_try\"") >&5
14472 (eval $ac_try) 2>&5
14474 echo "$as_me:14474: \$? = $ac_status" >&5
14475 (exit $ac_status); }; }; then
14476 if test "$cross_compiling" = yes; then
14477 cf_have_curses_lib=maybe
14479 cat >conftest.$ac_ext <<_ACEOF
14480 #line 14480 "configure"
14481 #include "confdefs.h"
14484 { (void) new_panel ( 0 ); return 0; }
14486 rm -f conftest$ac_exeext
14487 if { (eval echo "$as_me:14487: \"$ac_link\"") >&5
14488 (eval $ac_link) 2>&5
14490 echo "$as_me:14490: \$? = $ac_status" >&5
14491 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14492 { (eval echo "$as_me:14492: \"$ac_try\"") >&5
14493 (eval $ac_try) 2>&5
14495 echo "$as_me:14495: \$? = $ac_status" >&5
14496 (exit $ac_status); }; }; then
14497 cf_have_curses_lib=yes
14499 echo "$as_me: program exited with status $ac_status" >&5
14500 echo "$as_me: failed program was:" >&5
14501 cat conftest.$ac_ext >&5
14502 cf_have_curses_lib=no
14504 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14507 echo "$as_me: failed program was:" >&5
14508 cat conftest.$ac_ext >&5
14509 cf_have_curses_lib=no
14511 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14512 echo "$as_me:14512: result: $cf_have_curses_lib" >&5
14513 echo "${ECHO_T}$cf_have_curses_lib" >&6
14514 test "$cf_have_curses_lib" = maybe && cf_have_curses_lib=yes
14515 if test "$cf_have_curses_lib" != "yes"
14517 CPPFLAGS="$cf_save_CPPFLAGS"
14518 LIBS="$cf_save_LIBS"
14521 cf_upper=`echo "have_libpanel" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14523 cat >>confdefs.h <<EOF
14524 #define $cf_upper 1
14530 if test "$cf_have_curses_lib" = no; then
14531 as_ac_Lib=`echo "ac_cv_lib_panel$cf_cv_libtype''_new_panel" | $as_tr_sh`
14532 echo "$as_me:14532: checking for new_panel in -lpanel$cf_cv_libtype" >&5
14533 echo $ECHO_N "checking for new_panel in -lpanel$cf_cv_libtype... $ECHO_C" >&6
14534 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
14535 echo $ECHO_N "(cached) $ECHO_C" >&6
14537 ac_check_lib_save_LIBS=$LIBS
14538 LIBS="-lpanel$cf_cv_libtype $LIBS"
14539 cat >conftest.$ac_ext <<_ACEOF
14540 #line 14540 "configure"
14541 #include "confdefs.h"
14543 /* Override any gcc2 internal prototype to avoid an error. */
14547 /* We use char because int might match the return type of a gcc2
14548 builtin and then its argument prototype would still apply. */
14558 rm -f conftest.$ac_objext conftest$ac_exeext
14559 if { (eval echo "$as_me:14559: \"$ac_link\"") >&5
14560 (eval $ac_link) 2>&5
14562 echo "$as_me:14562: \$? = $ac_status" >&5
14563 (exit $ac_status); } &&
14564 { ac_try='test -s conftest$ac_exeext'
14565 { (eval echo "$as_me:14565: \"$ac_try\"") >&5
14566 (eval $ac_try) 2>&5
14568 echo "$as_me:14568: \$? = $ac_status" >&5
14569 (exit $ac_status); }; }; then
14570 eval "$as_ac_Lib=yes"
14572 echo "$as_me: failed program was:" >&5
14573 cat conftest.$ac_ext >&5
14574 eval "$as_ac_Lib=no"
14576 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14577 LIBS=$ac_check_lib_save_LIBS
14579 echo "$as_me:14579: result: `eval echo '${'$as_ac_Lib'}'`" >&5
14580 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
14581 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
14583 cf_upper=`echo "have_libpanel" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14585 cf_add_libs="-lpanel$cf_cv_libtype"
14586 # Filter out duplicates - this happens with badly-designed ".pc" files...
14587 for cf_add_1lib in $LIBS
14589 for cf_add_2lib in $cf_add_libs
14591 if test "x$cf_add_1lib" = "x$cf_add_2lib"
14597 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
14599 LIBS="$cf_add_libs"
14601 cat >>confdefs.h <<EOF
14602 #define $cf_upper 1
14609 cf_curses_headers="$cf_curses_headers panel.h"
14612 echo "$as_me:14612: checking if you want to check for menu functions" >&5
14613 echo $ECHO_N "checking if you want to check for menu functions... $ECHO_C" >&6
14615 # Check whether --enable-menu or --disable-menu was given.
14616 if test "${enable_menu+set}" = set; then
14617 enableval="$enable_menu"
14618 test "$enableval" != no && enableval=yes
14619 if test "$enableval" != "yes" ; then
14622 cf_enable_menu=$cf_default_menu
14626 cf_enable_menu=$cf_default_menu
14629 echo "$as_me:14629: result: $cf_enable_menu" >&5
14630 echo "${ECHO_T}$cf_enable_menu" >&6
14631 if test $cf_enable_menu = yes
14633 case $cf_cv_screen in
14638 echo "$as_me:14638: checking for NetBSD menu.h" >&5
14639 echo $ECHO_N "checking for NetBSD menu.h... $ECHO_C" >&6
14640 if test "${cf_cv_netbsd_menu_h+set}" = set; then
14641 echo $ECHO_N "(cached) $ECHO_C" >&6
14644 cat >conftest.$ac_ext <<_ACEOF
14645 #line 14645 "configure"
14646 #include "confdefs.h"
14648 #include <${cf_cv_ncurses_header:-curses.h}>
14656 int y = menu->max_item_width;
14662 rm -f conftest.$ac_objext
14663 if { (eval echo "$as_me:14663: \"$ac_compile\"") >&5
14664 (eval $ac_compile) 2>&5
14666 echo "$as_me:14666: \$? = $ac_status" >&5
14667 (exit $ac_status); } &&
14668 { ac_try='test -s conftest.$ac_objext'
14669 { (eval echo "$as_me:14669: \"$ac_try\"") >&5
14670 (eval $ac_try) 2>&5
14672 echo "$as_me:14672: \$? = $ac_status" >&5
14673 (exit $ac_status); }; }; then
14674 cf_cv_netbsd_menu_h=yes
14677 echo "$as_me: failed program was:" >&5
14678 cat conftest.$ac_ext >&5
14679 cf_cv_netbsd_menu_h=no
14681 rm -f conftest.$ac_objext conftest.$ac_ext
14684 echo "$as_me:14684: result: $cf_cv_netbsd_menu_h" >&5
14685 echo "${ECHO_T}$cf_cv_netbsd_menu_h" >&6
14687 test "$cf_cv_netbsd_menu_h" = yes &&
14688 cat >>confdefs.h <<\EOF
14689 #define HAVE_NETBSD_MENU_H 1
14695 cf_have_curses_lib=no
14697 : ${NCURSES_CONFIG_PKG:=none}
14698 if test "x${NCURSES_CONFIG_PKG}" = xnone; then
14700 elif test "x${PKG_CONFIG:=none}" != xnone; then
14701 echo "$as_me:14701: checking pkg-config for menu$cf_cv_libtype" >&5
14702 echo $ECHO_N "checking pkg-config for menu$cf_cv_libtype... $ECHO_C" >&6
14703 if "$PKG_CONFIG" --exists menu$cf_cv_libtype ; then
14704 echo "$as_me:14704: result: yes" >&5
14705 echo "${ECHO_T}yes" >&6
14707 echo "$as_me:14707: checking if the menu$cf_cv_libtype package files work" >&5
14708 echo $ECHO_N "checking if the menu$cf_cv_libtype package files work... $ECHO_C" >&6
14710 cf_save_CPPFLAGS="$CPPFLAGS"
14711 cf_save_LIBS="$LIBS"
14716 cf_new_extra_cppflags=
14718 for cf_add_cflags in `$PKG_CONFIG --cflags menu$cf_cv_libtype`
14720 case $cf_fix_cppflags in
14722 case $cf_add_cflags in
14723 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
14724 case $cf_add_cflags in
14726 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
14728 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14729 && test -z "${cf_tst_cflags}" \
14730 && cf_fix_cppflags=yes
14732 if test $cf_fix_cppflags = yes ; then
14734 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14735 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14738 elif test "${cf_tst_cflags}" = "\"'" ; then
14740 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14741 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14747 case "$CPPFLAGS" in
14751 case $cf_add_cflags in
14753 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
14755 CPPFLAGS=`echo "$CPPFLAGS" | \
14756 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
14757 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
14762 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
14763 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
14770 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
14771 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
14778 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14779 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14781 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
14783 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14784 && test -z "${cf_tst_cflags}" \
14785 && cf_fix_cppflags=no
14790 if test -n "$cf_new_cflags" ; then
14792 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
14793 CFLAGS="${CFLAGS}$cf_new_cflags"
14797 if test -n "$cf_new_cppflags" ; then
14799 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
14800 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
14804 if test -n "$cf_new_extra_cppflags" ; then
14806 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
14807 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
14811 cf_add_libs="`$PKG_CONFIG --libs menu$cf_cv_libtype`"
14812 # Filter out duplicates - this happens with badly-designed ".pc" files...
14813 for cf_add_1lib in $LIBS
14815 for cf_add_2lib in $cf_add_libs
14817 if test "x$cf_add_1lib" = "x$cf_add_2lib"
14823 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
14825 LIBS="$cf_add_libs"
14827 cat >conftest.$ac_ext <<_ACEOF
14828 #line 14828 "configure"
14829 #include "confdefs.h"
14834 (void) menu_driver ( 0,0 );
14839 rm -f conftest.$ac_objext conftest$ac_exeext
14840 if { (eval echo "$as_me:14840: \"$ac_link\"") >&5
14841 (eval $ac_link) 2>&5
14843 echo "$as_me:14843: \$? = $ac_status" >&5
14844 (exit $ac_status); } &&
14845 { ac_try='test -s conftest$ac_exeext'
14846 { (eval echo "$as_me:14846: \"$ac_try\"") >&5
14847 (eval $ac_try) 2>&5
14849 echo "$as_me:14849: \$? = $ac_status" >&5
14850 (exit $ac_status); }; }; then
14851 if test "$cross_compiling" = yes; then
14852 cf_have_curses_lib=maybe
14854 cat >conftest.$ac_ext <<_ACEOF
14855 #line 14855 "configure"
14856 #include "confdefs.h"
14859 { (void) menu_driver ( 0,0 ); return 0; }
14861 rm -f conftest$ac_exeext
14862 if { (eval echo "$as_me:14862: \"$ac_link\"") >&5
14863 (eval $ac_link) 2>&5
14865 echo "$as_me:14865: \$? = $ac_status" >&5
14866 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14867 { (eval echo "$as_me:14867: \"$ac_try\"") >&5
14868 (eval $ac_try) 2>&5
14870 echo "$as_me:14870: \$? = $ac_status" >&5
14871 (exit $ac_status); }; }; then
14872 cf_have_curses_lib=yes
14874 echo "$as_me: program exited with status $ac_status" >&5
14875 echo "$as_me: failed program was:" >&5
14876 cat conftest.$ac_ext >&5
14877 cf_have_curses_lib=no
14879 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14882 echo "$as_me: failed program was:" >&5
14883 cat conftest.$ac_ext >&5
14884 cf_have_curses_lib=no
14886 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14887 echo "$as_me:14887: result: $cf_have_curses_lib" >&5
14888 echo "${ECHO_T}$cf_have_curses_lib" >&6
14889 test "$cf_have_curses_lib" = maybe && cf_have_curses_lib=yes
14890 if test "$cf_have_curses_lib" != "yes"
14892 CPPFLAGS="$cf_save_CPPFLAGS"
14893 LIBS="$cf_save_LIBS"
14896 cf_upper=`echo "have_libmenu" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14898 cat >>confdefs.h <<EOF
14899 #define $cf_upper 1
14905 if test "$cf_have_curses_lib" = no; then
14906 as_ac_Lib=`echo "ac_cv_lib_menu$cf_cv_libtype''_menu_driver" | $as_tr_sh`
14907 echo "$as_me:14907: checking for menu_driver in -lmenu$cf_cv_libtype" >&5
14908 echo $ECHO_N "checking for menu_driver in -lmenu$cf_cv_libtype... $ECHO_C" >&6
14909 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
14910 echo $ECHO_N "(cached) $ECHO_C" >&6
14912 ac_check_lib_save_LIBS=$LIBS
14913 LIBS="-lmenu$cf_cv_libtype $LIBS"
14914 cat >conftest.$ac_ext <<_ACEOF
14915 #line 14915 "configure"
14916 #include "confdefs.h"
14918 /* Override any gcc2 internal prototype to avoid an error. */
14922 /* We use char because int might match the return type of a gcc2
14923 builtin and then its argument prototype would still apply. */
14924 char menu_driver ();
14933 rm -f conftest.$ac_objext conftest$ac_exeext
14934 if { (eval echo "$as_me:14934: \"$ac_link\"") >&5
14935 (eval $ac_link) 2>&5
14937 echo "$as_me:14937: \$? = $ac_status" >&5
14938 (exit $ac_status); } &&
14939 { ac_try='test -s conftest$ac_exeext'
14940 { (eval echo "$as_me:14940: \"$ac_try\"") >&5
14941 (eval $ac_try) 2>&5
14943 echo "$as_me:14943: \$? = $ac_status" >&5
14944 (exit $ac_status); }; }; then
14945 eval "$as_ac_Lib=yes"
14947 echo "$as_me: failed program was:" >&5
14948 cat conftest.$ac_ext >&5
14949 eval "$as_ac_Lib=no"
14951 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14952 LIBS=$ac_check_lib_save_LIBS
14954 echo "$as_me:14954: result: `eval echo '${'$as_ac_Lib'}'`" >&5
14955 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
14956 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
14958 cf_upper=`echo "have_libmenu" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14960 cf_add_libs="-lmenu$cf_cv_libtype"
14961 # Filter out duplicates - this happens with badly-designed ".pc" files...
14962 for cf_add_1lib in $LIBS
14964 for cf_add_2lib in $cf_add_libs
14966 if test "x$cf_add_1lib" = "x$cf_add_2lib"
14972 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
14974 LIBS="$cf_add_libs"
14976 cat >>confdefs.h <<EOF
14977 #define $cf_upper 1
14984 cf_curses_headers="$cf_curses_headers menu.h"
14987 echo "$as_me:14987: checking if you want to check for form functions" >&5
14988 echo $ECHO_N "checking if you want to check for form functions... $ECHO_C" >&6
14990 # Check whether --enable-form or --disable-form was given.
14991 if test "${enable_form+set}" = set; then
14992 enableval="$enable_form"
14993 test "$enableval" != no && enableval=yes
14994 if test "$enableval" != "yes" ; then
14997 cf_enable_form=$cf_default_form
15001 cf_enable_form=$cf_default_form
15004 echo "$as_me:15004: result: $cf_enable_form" >&5
15005 echo "${ECHO_T}$cf_enable_form" >&6
15006 if test $cf_enable_form = yes
15008 case $cf_cv_screen in
15013 echo "$as_me:15013: checking for NetBSD form.h" >&5
15014 echo $ECHO_N "checking for NetBSD form.h... $ECHO_C" >&6
15015 if test "${cf_cv_netbsd_form_h+set}" = set; then
15016 echo $ECHO_N "(cached) $ECHO_C" >&6
15019 cat >conftest.$ac_ext <<_ACEOF
15020 #line 15020 "configure"
15021 #include "confdefs.h"
15023 #include <${cf_cv_ncurses_header:-curses.h}>
15031 int y = current_field(form)->cursor_ypos;
15032 int x = current_field(form)->cursor_xpos;
15038 rm -f conftest.$ac_objext
15039 if { (eval echo "$as_me:15039: \"$ac_compile\"") >&5
15040 (eval $ac_compile) 2>&5
15042 echo "$as_me:15042: \$? = $ac_status" >&5
15043 (exit $ac_status); } &&
15044 { ac_try='test -s conftest.$ac_objext'
15045 { (eval echo "$as_me:15045: \"$ac_try\"") >&5
15046 (eval $ac_try) 2>&5
15048 echo "$as_me:15048: \$? = $ac_status" >&5
15049 (exit $ac_status); }; }; then
15050 cf_cv_netbsd_form_h=yes
15053 echo "$as_me: failed program was:" >&5
15054 cat conftest.$ac_ext >&5
15055 cf_cv_netbsd_form_h=no
15057 rm -f conftest.$ac_objext conftest.$ac_ext
15060 echo "$as_me:15060: result: $cf_cv_netbsd_form_h" >&5
15061 echo "${ECHO_T}$cf_cv_netbsd_form_h" >&6
15063 test "$cf_cv_netbsd_form_h" = yes &&
15064 cat >>confdefs.h <<\EOF
15065 #define HAVE_NETBSD_FORM_H 1
15071 cf_have_curses_lib=no
15073 : ${NCURSES_CONFIG_PKG:=none}
15074 if test "x${NCURSES_CONFIG_PKG}" = xnone; then
15076 elif test "x${PKG_CONFIG:=none}" != xnone; then
15077 echo "$as_me:15077: checking pkg-config for form$cf_cv_libtype" >&5
15078 echo $ECHO_N "checking pkg-config for form$cf_cv_libtype... $ECHO_C" >&6
15079 if "$PKG_CONFIG" --exists form$cf_cv_libtype ; then
15080 echo "$as_me:15080: result: yes" >&5
15081 echo "${ECHO_T}yes" >&6
15083 echo "$as_me:15083: checking if the form$cf_cv_libtype package files work" >&5
15084 echo $ECHO_N "checking if the form$cf_cv_libtype package files work... $ECHO_C" >&6
15086 cf_save_CPPFLAGS="$CPPFLAGS"
15087 cf_save_LIBS="$LIBS"
15092 cf_new_extra_cppflags=
15094 for cf_add_cflags in `$PKG_CONFIG --cflags form$cf_cv_libtype`
15096 case $cf_fix_cppflags in
15098 case $cf_add_cflags in
15099 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
15100 case $cf_add_cflags in
15102 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
15104 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15105 && test -z "${cf_tst_cflags}" \
15106 && cf_fix_cppflags=yes
15108 if test $cf_fix_cppflags = yes ; then
15110 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15111 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15114 elif test "${cf_tst_cflags}" = "\"'" ; then
15116 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15117 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15123 case "$CPPFLAGS" in
15127 case $cf_add_cflags in
15129 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
15131 CPPFLAGS=`echo "$CPPFLAGS" | \
15132 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
15133 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
15138 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
15139 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
15146 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
15147 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
15154 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15155 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15157 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
15159 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15160 && test -z "${cf_tst_cflags}" \
15161 && cf_fix_cppflags=no
15166 if test -n "$cf_new_cflags" ; then
15168 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
15169 CFLAGS="${CFLAGS}$cf_new_cflags"
15173 if test -n "$cf_new_cppflags" ; then
15175 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
15176 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
15180 if test -n "$cf_new_extra_cppflags" ; then
15182 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
15183 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
15187 cf_add_libs="`$PKG_CONFIG --libs form$cf_cv_libtype`"
15188 # Filter out duplicates - this happens with badly-designed ".pc" files...
15189 for cf_add_1lib in $LIBS
15191 for cf_add_2lib in $cf_add_libs
15193 if test "x$cf_add_1lib" = "x$cf_add_2lib"
15199 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
15201 LIBS="$cf_add_libs"
15203 cat >conftest.$ac_ext <<_ACEOF
15204 #line 15204 "configure"
15205 #include "confdefs.h"
15210 (void) form_driver ( 0,0 );
15215 rm -f conftest.$ac_objext conftest$ac_exeext
15216 if { (eval echo "$as_me:15216: \"$ac_link\"") >&5
15217 (eval $ac_link) 2>&5
15219 echo "$as_me:15219: \$? = $ac_status" >&5
15220 (exit $ac_status); } &&
15221 { ac_try='test -s conftest$ac_exeext'
15222 { (eval echo "$as_me:15222: \"$ac_try\"") >&5
15223 (eval $ac_try) 2>&5
15225 echo "$as_me:15225: \$? = $ac_status" >&5
15226 (exit $ac_status); }; }; then
15227 if test "$cross_compiling" = yes; then
15228 cf_have_curses_lib=maybe
15230 cat >conftest.$ac_ext <<_ACEOF
15231 #line 15231 "configure"
15232 #include "confdefs.h"
15235 { (void) form_driver ( 0,0 ); return 0; }
15237 rm -f conftest$ac_exeext
15238 if { (eval echo "$as_me:15238: \"$ac_link\"") >&5
15239 (eval $ac_link) 2>&5
15241 echo "$as_me:15241: \$? = $ac_status" >&5
15242 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15243 { (eval echo "$as_me:15243: \"$ac_try\"") >&5
15244 (eval $ac_try) 2>&5
15246 echo "$as_me:15246: \$? = $ac_status" >&5
15247 (exit $ac_status); }; }; then
15248 cf_have_curses_lib=yes
15250 echo "$as_me: program exited with status $ac_status" >&5
15251 echo "$as_me: failed program was:" >&5
15252 cat conftest.$ac_ext >&5
15253 cf_have_curses_lib=no
15255 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15258 echo "$as_me: failed program was:" >&5
15259 cat conftest.$ac_ext >&5
15260 cf_have_curses_lib=no
15262 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15263 echo "$as_me:15263: result: $cf_have_curses_lib" >&5
15264 echo "${ECHO_T}$cf_have_curses_lib" >&6
15265 test "$cf_have_curses_lib" = maybe && cf_have_curses_lib=yes
15266 if test "$cf_have_curses_lib" != "yes"
15268 CPPFLAGS="$cf_save_CPPFLAGS"
15269 LIBS="$cf_save_LIBS"
15272 cf_upper=`echo "have_libform" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
15274 cat >>confdefs.h <<EOF
15275 #define $cf_upper 1
15281 if test "$cf_have_curses_lib" = no; then
15282 as_ac_Lib=`echo "ac_cv_lib_form$cf_cv_libtype''_form_driver" | $as_tr_sh`
15283 echo "$as_me:15283: checking for form_driver in -lform$cf_cv_libtype" >&5
15284 echo $ECHO_N "checking for form_driver in -lform$cf_cv_libtype... $ECHO_C" >&6
15285 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
15286 echo $ECHO_N "(cached) $ECHO_C" >&6
15288 ac_check_lib_save_LIBS=$LIBS
15289 LIBS="-lform$cf_cv_libtype $LIBS"
15290 cat >conftest.$ac_ext <<_ACEOF
15291 #line 15291 "configure"
15292 #include "confdefs.h"
15294 /* Override any gcc2 internal prototype to avoid an error. */
15298 /* We use char because int might match the return type of a gcc2
15299 builtin and then its argument prototype would still apply. */
15300 char form_driver ();
15309 rm -f conftest.$ac_objext conftest$ac_exeext
15310 if { (eval echo "$as_me:15310: \"$ac_link\"") >&5
15311 (eval $ac_link) 2>&5
15313 echo "$as_me:15313: \$? = $ac_status" >&5
15314 (exit $ac_status); } &&
15315 { ac_try='test -s conftest$ac_exeext'
15316 { (eval echo "$as_me:15316: \"$ac_try\"") >&5
15317 (eval $ac_try) 2>&5
15319 echo "$as_me:15319: \$? = $ac_status" >&5
15320 (exit $ac_status); }; }; then
15321 eval "$as_ac_Lib=yes"
15323 echo "$as_me: failed program was:" >&5
15324 cat conftest.$ac_ext >&5
15325 eval "$as_ac_Lib=no"
15327 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15328 LIBS=$ac_check_lib_save_LIBS
15330 echo "$as_me:15330: result: `eval echo '${'$as_ac_Lib'}'`" >&5
15331 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
15332 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
15334 cf_upper=`echo "have_libform" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
15336 cf_add_libs="-lform$cf_cv_libtype"
15337 # Filter out duplicates - this happens with badly-designed ".pc" files...
15338 for cf_add_1lib in $LIBS
15340 for cf_add_2lib in $cf_add_libs
15342 if test "x$cf_add_1lib" = "x$cf_add_2lib"
15348 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
15350 LIBS="$cf_add_libs"
15352 cat >>confdefs.h <<EOF
15353 #define $cf_upper 1
15360 cf_curses_headers="$cf_curses_headers form.h"
15363 # look for curses-related headers
15365 for ac_header in $cf_curses_headers
15367 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15368 echo "$as_me:15368: checking for $ac_header" >&5
15369 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15370 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15371 echo $ECHO_N "(cached) $ECHO_C" >&6
15373 cat >conftest.$ac_ext <<_ACEOF
15374 #line 15374 "configure"
15375 #include "confdefs.h"
15376 #include <$ac_header>
15378 if { (eval echo "$as_me:15378: \"$ac_cpp conftest.$ac_ext\"") >&5
15379 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15381 egrep -v '^ *\+' conftest.er1 >conftest.err
15383 cat conftest.err >&5
15384 echo "$as_me:15384: \$? = $ac_status" >&5
15385 (exit $ac_status); } >/dev/null; then
15386 if test -s conftest.err; then
15387 ac_cpp_err=$ac_c_preproc_warn_flag
15394 if test -z "$ac_cpp_err"; then
15395 eval "$as_ac_Header=yes"
15397 echo "$as_me: failed program was:" >&5
15398 cat conftest.$ac_ext >&5
15399 eval "$as_ac_Header=no"
15401 rm -f conftest.err conftest.$ac_ext
15403 echo "$as_me:15403: result: `eval echo '${'$as_ac_Header'}'`" >&5
15404 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15405 if test `eval echo '${'$as_ac_Header'}'` = yes; then
15406 cat >>confdefs.h <<EOF
15407 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
15413 echo "$as_me:15413: checking for ANSI C header files" >&5
15414 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
15415 if test "${ac_cv_header_stdc+set}" = set; then
15416 echo $ECHO_N "(cached) $ECHO_C" >&6
15418 cat >conftest.$ac_ext <<_ACEOF
15419 #line 15419 "configure"
15420 #include "confdefs.h"
15421 #include <stdlib.h>
15422 #include <stdarg.h>
15423 #include <string.h>
15427 if { (eval echo "$as_me:15427: \"$ac_cpp conftest.$ac_ext\"") >&5
15428 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15430 egrep -v '^ *\+' conftest.er1 >conftest.err
15432 cat conftest.err >&5
15433 echo "$as_me:15433: \$? = $ac_status" >&5
15434 (exit $ac_status); } >/dev/null; then
15435 if test -s conftest.err; then
15436 ac_cpp_err=$ac_c_preproc_warn_flag
15443 if test -z "$ac_cpp_err"; then
15444 ac_cv_header_stdc=yes
15446 echo "$as_me: failed program was:" >&5
15447 cat conftest.$ac_ext >&5
15448 ac_cv_header_stdc=no
15450 rm -f conftest.err conftest.$ac_ext
15452 if test $ac_cv_header_stdc = yes; then
15453 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
15454 cat >conftest.$ac_ext <<_ACEOF
15455 #line 15455 "configure"
15456 #include "confdefs.h"
15457 #include <string.h>
15460 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
15461 egrep "memchr" >/dev/null 2>&1; then
15464 ac_cv_header_stdc=no
15470 if test $ac_cv_header_stdc = yes; then
15471 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
15472 cat >conftest.$ac_ext <<_ACEOF
15473 #line 15473 "configure"
15474 #include "confdefs.h"
15475 #include <stdlib.h>
15478 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
15479 egrep "free" >/dev/null 2>&1; then
15482 ac_cv_header_stdc=no
15488 if test $ac_cv_header_stdc = yes; then
15489 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
15490 if test "$cross_compiling" = yes; then
15493 cat >conftest.$ac_ext <<_ACEOF
15494 #line 15494 "configure"
15495 #include "confdefs.h"
15497 #if ((' ' & 0x0FF) == 0x020)
15498 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
15499 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
15501 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
15502 || ('j' <= (c) && (c) <= 'r') \
15503 || ('s' <= (c) && (c) <= 'z'))
15504 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
15507 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
15512 for (i = 0; i < 256; i++)
15513 if (XOR (islower (i), ISLOWER (i))
15514 || toupper (i) != TOUPPER (i))
15515 $ac_main_return(2);
15516 $ac_main_return (0);
15519 rm -f conftest$ac_exeext
15520 if { (eval echo "$as_me:15520: \"$ac_link\"") >&5
15521 (eval $ac_link) 2>&5
15523 echo "$as_me:15523: \$? = $ac_status" >&5
15524 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15525 { (eval echo "$as_me:15525: \"$ac_try\"") >&5
15526 (eval $ac_try) 2>&5
15528 echo "$as_me:15528: \$? = $ac_status" >&5
15529 (exit $ac_status); }; }; then
15532 echo "$as_me: program exited with status $ac_status" >&5
15533 echo "$as_me: failed program was:" >&5
15534 cat conftest.$ac_ext >&5
15535 ac_cv_header_stdc=no
15537 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15541 echo "$as_me:15541: result: $ac_cv_header_stdc" >&5
15542 echo "${ECHO_T}$ac_cv_header_stdc" >&6
15543 if test $ac_cv_header_stdc = yes; then
15545 cat >>confdefs.h <<\EOF
15546 #define STDC_HEADERS 1
15551 echo "$as_me:15551: checking whether time.h and sys/time.h may both be included" >&5
15552 echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
15553 if test "${ac_cv_header_time+set}" = set; then
15554 echo $ECHO_N "(cached) $ECHO_C" >&6
15556 cat >conftest.$ac_ext <<_ACEOF
15557 #line 15557 "configure"
15558 #include "confdefs.h"
15559 #include <sys/types.h>
15560 #include <sys/time.h>
15566 if ((struct tm *) 0)
15572 rm -f conftest.$ac_objext
15573 if { (eval echo "$as_me:15573: \"$ac_compile\"") >&5
15574 (eval $ac_compile) 2>&5
15576 echo "$as_me:15576: \$? = $ac_status" >&5
15577 (exit $ac_status); } &&
15578 { ac_try='test -s conftest.$ac_objext'
15579 { (eval echo "$as_me:15579: \"$ac_try\"") >&5
15580 (eval $ac_try) 2>&5
15582 echo "$as_me:15582: \$? = $ac_status" >&5
15583 (exit $ac_status); }; }; then
15584 ac_cv_header_time=yes
15586 echo "$as_me: failed program was:" >&5
15587 cat conftest.$ac_ext >&5
15588 ac_cv_header_time=no
15590 rm -f conftest.$ac_objext conftest.$ac_ext
15592 echo "$as_me:15592: result: $ac_cv_header_time" >&5
15593 echo "${ECHO_T}$ac_cv_header_time" >&6
15594 if test $ac_cv_header_time = yes; then
15596 cat >>confdefs.h <<\EOF
15597 #define TIME_WITH_SYS_TIME 1
15615 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15616 echo "$as_me:15616: checking for $ac_header" >&5
15617 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15618 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15619 echo $ECHO_N "(cached) $ECHO_C" >&6
15621 cat >conftest.$ac_ext <<_ACEOF
15622 #line 15622 "configure"
15623 #include "confdefs.h"
15624 #include <$ac_header>
15626 if { (eval echo "$as_me:15626: \"$ac_cpp conftest.$ac_ext\"") >&5
15627 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15629 egrep -v '^ *\+' conftest.er1 >conftest.err
15631 cat conftest.err >&5
15632 echo "$as_me:15632: \$? = $ac_status" >&5
15633 (exit $ac_status); } >/dev/null; then
15634 if test -s conftest.err; then
15635 ac_cpp_err=$ac_c_preproc_warn_flag
15642 if test -z "$ac_cpp_err"; then
15643 eval "$as_ac_Header=yes"
15645 echo "$as_me: failed program was:" >&5
15646 cat conftest.$ac_ext >&5
15647 eval "$as_ac_Header=no"
15649 rm -f conftest.err conftest.$ac_ext
15651 echo "$as_me:15651: result: `eval echo '${'$as_ac_Header'}'`" >&5
15652 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15653 if test `eval echo '${'$as_ac_Header'}'` = yes; then
15654 cat >>confdefs.h <<EOF
15655 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
15661 for ac_header in unistd.h getopt.h
15663 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15664 echo "$as_me:15664: checking for $ac_header" >&5
15665 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15666 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15667 echo $ECHO_N "(cached) $ECHO_C" >&6
15669 cat >conftest.$ac_ext <<_ACEOF
15670 #line 15670 "configure"
15671 #include "confdefs.h"
15672 #include <$ac_header>
15674 if { (eval echo "$as_me:15674: \"$ac_cpp conftest.$ac_ext\"") >&5
15675 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15677 egrep -v '^ *\+' conftest.er1 >conftest.err
15679 cat conftest.err >&5
15680 echo "$as_me:15680: \$? = $ac_status" >&5
15681 (exit $ac_status); } >/dev/null; then
15682 if test -s conftest.err; then
15683 ac_cpp_err=$ac_c_preproc_warn_flag
15690 if test -z "$ac_cpp_err"; then
15691 eval "$as_ac_Header=yes"
15693 echo "$as_me: failed program was:" >&5
15694 cat conftest.$ac_ext >&5
15695 eval "$as_ac_Header=no"
15697 rm -f conftest.err conftest.$ac_ext
15699 echo "$as_me:15699: result: `eval echo '${'$as_ac_Header'}'`" >&5
15700 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15701 if test `eval echo '${'$as_ac_Header'}'` = yes; then
15702 cat >>confdefs.h <<EOF
15703 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
15709 echo "$as_me:15709: checking for header declaring getopt variables" >&5
15710 echo $ECHO_N "checking for header declaring getopt variables... $ECHO_C" >&6
15711 if test "${cf_cv_getopt_header+set}" = set; then
15712 echo $ECHO_N "(cached) $ECHO_C" >&6
15715 cf_cv_getopt_header=none
15716 for cf_header in stdio.h stdlib.h unistd.h getopt.h
15718 cat >conftest.$ac_ext <<_ACEOF
15719 #line 15719 "configure"
15720 #include "confdefs.h"
15722 #include <$cf_header>
15726 int x = optind; char *y = optarg
15731 rm -f conftest.$ac_objext
15732 if { (eval echo "$as_me:15732: \"$ac_compile\"") >&5
15733 (eval $ac_compile) 2>&5
15735 echo "$as_me:15735: \$? = $ac_status" >&5
15736 (exit $ac_status); } &&
15737 { ac_try='test -s conftest.$ac_objext'
15738 { (eval echo "$as_me:15738: \"$ac_try\"") >&5
15739 (eval $ac_try) 2>&5
15741 echo "$as_me:15741: \$? = $ac_status" >&5
15742 (exit $ac_status); }; }; then
15743 cf_cv_getopt_header=$cf_header
15746 echo "$as_me: failed program was:" >&5
15747 cat conftest.$ac_ext >&5
15749 rm -f conftest.$ac_objext conftest.$ac_ext
15753 echo "$as_me:15753: result: $cf_cv_getopt_header" >&5
15754 echo "${ECHO_T}$cf_cv_getopt_header" >&6
15755 if test $cf_cv_getopt_header != none ; then
15757 cat >>confdefs.h <<\EOF
15758 #define HAVE_GETOPT_HEADER 1
15762 if test $cf_cv_getopt_header = getopt.h ; then
15764 cat >>confdefs.h <<\EOF
15765 #define NEED_GETOPT_H 1
15777 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15778 echo "$as_me:15778: checking for $ac_func" >&5
15779 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15780 if eval "test \"\${$as_ac_var+set}\" = set"; then
15781 echo $ECHO_N "(cached) $ECHO_C" >&6
15783 cat >conftest.$ac_ext <<_ACEOF
15784 #line 15784 "configure"
15785 #include "confdefs.h"
15786 /* System header to define __stub macros and hopefully few prototypes,
15787 which can conflict with char $ac_func (); below. */
15788 #include <assert.h>
15789 /* Override any gcc2 internal prototype to avoid an error. */
15793 /* We use char because int might match the return type of a gcc2
15794 builtin and then its argument prototype would still apply. */
15801 /* The GNU C library defines this for functions which it implements
15802 to always fail with ENOSYS. Some functions are actually named
15803 something starting with __ and the normal name is an alias. */
15804 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15807 f = $ac_func; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
15814 rm -f conftest.$ac_objext conftest$ac_exeext
15815 if { (eval echo "$as_me:15815: \"$ac_link\"") >&5
15816 (eval $ac_link) 2>&5
15818 echo "$as_me:15818: \$? = $ac_status" >&5
15819 (exit $ac_status); } &&
15820 { ac_try='test -s conftest$ac_exeext'
15821 { (eval echo "$as_me:15821: \"$ac_try\"") >&5
15822 (eval $ac_try) 2>&5
15824 echo "$as_me:15824: \$? = $ac_status" >&5
15825 (exit $ac_status); }; }; then
15826 eval "$as_ac_var=yes"
15828 echo "$as_me: failed program was:" >&5
15829 cat conftest.$ac_ext >&5
15830 eval "$as_ac_var=no"
15832 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15834 echo "$as_me:15834: result: `eval echo '${'$as_ac_var'}'`" >&5
15835 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15836 if test `eval echo '${'$as_ac_var'}'` = yes; then
15837 cat >>confdefs.h <<EOF
15838 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15844 # use a compile-check to work with ncurses*-config and subdirectory includes
15845 echo "$as_me:15845: checking if we can use termcap.h" >&5
15846 echo $ECHO_N "checking if we can use termcap.h... $ECHO_C" >&6
15847 if test "${cf_cv_have_termcap_h+set}" = set; then
15848 echo $ECHO_N "(cached) $ECHO_C" >&6
15851 cat >conftest.$ac_ext <<_ACEOF
15852 #line 15852 "configure"
15853 #include "confdefs.h"
15855 #include <curses.h>
15856 #include <termcap.h>
15866 rm -f conftest.$ac_objext
15867 if { (eval echo "$as_me:15867: \"$ac_compile\"") >&5
15868 (eval $ac_compile) 2>&5
15870 echo "$as_me:15870: \$? = $ac_status" >&5
15871 (exit $ac_status); } &&
15872 { ac_try='test -s conftest.$ac_objext'
15873 { (eval echo "$as_me:15873: \"$ac_try\"") >&5
15874 (eval $ac_try) 2>&5
15876 echo "$as_me:15876: \$? = $ac_status" >&5
15877 (exit $ac_status); }; }; then
15878 cf_cv_have_termcap_h=yes
15880 echo "$as_me: failed program was:" >&5
15881 cat conftest.$ac_ext >&5
15882 cf_cv_have_termcap_h=no
15884 rm -f conftest.$ac_objext conftest.$ac_ext
15886 echo "$as_me:15886: result: $cf_cv_have_termcap_h" >&5
15887 echo "${ECHO_T}$cf_cv_have_termcap_h" >&6
15888 test "x$cf_cv_have_termcap_h" = xyes && cat >>confdefs.h <<\EOF
15889 #define HAVE_TERMCAP_H 1
15892 if test "x$ac_cv_func_getopt" = xno; then
15893 { { echo "$as_me:15893: error: getopt is required for building programs" >&5
15894 echo "$as_me: error: getopt is required for building programs" >&2;}
15895 { (exit 1); exit 1; }; }
15898 if test "$cf_enable_widec" = yes; then
15911 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15912 echo "$as_me:15912: checking for $ac_func" >&5
15913 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15914 if eval "test \"\${$as_ac_var+set}\" = set"; then
15915 echo $ECHO_N "(cached) $ECHO_C" >&6
15917 cat >conftest.$ac_ext <<_ACEOF
15918 #line 15918 "configure"
15919 #include "confdefs.h"
15920 /* System header to define __stub macros and hopefully few prototypes,
15921 which can conflict with char $ac_func (); below. */
15922 #include <assert.h>
15923 /* Override any gcc2 internal prototype to avoid an error. */
15927 /* We use char because int might match the return type of a gcc2
15928 builtin and then its argument prototype would still apply. */
15935 /* The GNU C library defines this for functions which it implements
15936 to always fail with ENOSYS. Some functions are actually named
15937 something starting with __ and the normal name is an alias. */
15938 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15941 f = $ac_func; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
15948 rm -f conftest.$ac_objext conftest$ac_exeext
15949 if { (eval echo "$as_me:15949: \"$ac_link\"") >&5
15950 (eval $ac_link) 2>&5
15952 echo "$as_me:15952: \$? = $ac_status" >&5
15953 (exit $ac_status); } &&
15954 { ac_try='test -s conftest$ac_exeext'
15955 { (eval echo "$as_me:15955: \"$ac_try\"") >&5
15956 (eval $ac_try) 2>&5
15958 echo "$as_me:15958: \$? = $ac_status" >&5
15959 (exit $ac_status); }; }; then
15960 eval "$as_ac_var=yes"
15962 echo "$as_me: failed program was:" >&5
15963 cat conftest.$ac_ext >&5
15964 eval "$as_ac_var=no"
15966 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15968 echo "$as_me:15968: result: `eval echo '${'$as_ac_var'}'`" >&5
15969 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15970 if test `eval echo '${'$as_ac_var'}'` = yes; then
15971 cat >>confdefs.h <<EOF
15972 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15980 echo "$as_me:15980: checking definition to turn on extended curses functions" >&5
15981 echo $ECHO_N "checking definition to turn on extended curses functions... $ECHO_C" >&6
15982 if test "${cf_cv_need_xopen_extension+set}" = set; then
15983 echo $ECHO_N "(cached) $ECHO_C" >&6
15986 cf_cv_need_xopen_extension=unknown
15987 cat >conftest.$ac_ext <<_ACEOF
15988 #line 15988 "configure"
15989 #include "confdefs.h"
15991 #include <stdlib.h>
15992 #include <${cf_cv_ncurses_header:-curses.h}>
15997 #if defined(NCURSES_VERSION_PATCH)
15998 #if (NCURSES_VERSION_PATCH < 20100501) && (NCURSES_VERSION_PATCH >= 20100403)
16002 #ifdef NCURSES_VERSION
16004 int check2 = curs_set((int)sizeof(check));
16006 long x = winnstr(stdscr, "", 0);
16008 getbegyx(stdscr, y1, x1)
16013 rm -f conftest.$ac_objext conftest$ac_exeext
16014 if { (eval echo "$as_me:16014: \"$ac_link\"") >&5
16015 (eval $ac_link) 2>&5
16017 echo "$as_me:16017: \$? = $ac_status" >&5
16018 (exit $ac_status); } &&
16019 { ac_try='test -s conftest$ac_exeext'
16020 { (eval echo "$as_me:16020: \"$ac_try\"") >&5
16021 (eval $ac_try) 2>&5
16023 echo "$as_me:16023: \$? = $ac_status" >&5
16024 (exit $ac_status); }; }; then
16025 cf_cv_need_xopen_extension=none
16027 echo "$as_me: failed program was:" >&5
16028 cat conftest.$ac_ext >&5
16030 for cf_try_xopen_extension in _XOPEN_SOURCE_EXTENDED NCURSES_WIDECHAR
16032 cat >conftest.$ac_ext <<_ACEOF
16033 #line 16033 "configure"
16034 #include "confdefs.h"
16036 #define $cf_try_xopen_extension 1
16037 #include <stdlib.h>
16038 #include <${cf_cv_ncurses_header:-curses.h}>
16043 #ifdef NCURSES_VERSION
16045 int check2 = curs_set((int)sizeof(check));
16047 long x = winnstr(stdscr, "", 0);
16049 getbegyx(stdscr, y1, x1)
16054 rm -f conftest.$ac_objext conftest$ac_exeext
16055 if { (eval echo "$as_me:16055: \"$ac_link\"") >&5
16056 (eval $ac_link) 2>&5
16058 echo "$as_me:16058: \$? = $ac_status" >&5
16059 (exit $ac_status); } &&
16060 { ac_try='test -s conftest$ac_exeext'
16061 { (eval echo "$as_me:16061: \"$ac_try\"") >&5
16062 (eval $ac_try) 2>&5
16064 echo "$as_me:16064: \$? = $ac_status" >&5
16065 (exit $ac_status); }; }; then
16066 cf_cv_need_xopen_extension=$cf_try_xopen_extension; break
16068 echo "$as_me: failed program was:" >&5
16069 cat conftest.$ac_ext >&5
16071 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16075 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16078 echo "$as_me:16078: result: $cf_cv_need_xopen_extension" >&5
16079 echo "${ECHO_T}$cf_cv_need_xopen_extension" >&6
16081 case $cf_cv_need_xopen_extension in
16083 CPPFLAGS="$CPPFLAGS -D$cf_cv_need_xopen_extension"
16087 echo "$as_me:16087: checking for term.h" >&5
16088 echo $ECHO_N "checking for term.h... $ECHO_C" >&6
16089 if test "${cf_cv_term_header+set}" = set; then
16090 echo $ECHO_N "(cached) $ECHO_C" >&6
16093 # If we found <ncurses/curses.h>, look for <ncurses/term.h>, but always look
16094 # for <term.h> if we do not find the variant.
16096 cf_header_list="term.h ncurses/term.h ncursesw/term.h"
16098 case ${cf_cv_ncurses_header:-curses.h} in
16100 cf_header_item=`echo ${cf_cv_ncurses_header:-curses.h} | sed -e 's%\..*%%' -e 's%/.*%/%'`term.h
16101 cf_header_list="$cf_header_item $cf_header_list"
16105 for cf_header in $cf_header_list
16107 cat >conftest.$ac_ext <<_ACEOF
16108 #line 16108 "configure"
16109 #include "confdefs.h"
16111 #include <${cf_cv_ncurses_header:-curses.h}>
16112 #include <${cf_header}>
16121 rm -f conftest.$ac_objext
16122 if { (eval echo "$as_me:16122: \"$ac_compile\"") >&5
16123 (eval $ac_compile) 2>&5
16125 echo "$as_me:16125: \$? = $ac_status" >&5
16126 (exit $ac_status); } &&
16127 { ac_try='test -s conftest.$ac_objext'
16128 { (eval echo "$as_me:16128: \"$ac_try\"") >&5
16129 (eval $ac_try) 2>&5
16131 echo "$as_me:16131: \$? = $ac_status" >&5
16132 (exit $ac_status); }; }; then
16133 cf_cv_term_header=$cf_header
16136 echo "$as_me: failed program was:" >&5
16137 cat conftest.$ac_ext >&5
16138 cf_cv_term_header=no
16140 rm -f conftest.$ac_objext conftest.$ac_ext
16143 case $cf_cv_term_header in
16145 # If curses is ncurses, some packagers still mess it up by trying to make
16146 # us use GNU termcap. This handles the most common case.
16147 for cf_header in ncurses/term.h ncursesw/term.h
16149 cat >conftest.$ac_ext <<_ACEOF
16150 #line 16150 "configure"
16151 #include "confdefs.h"
16153 #include <${cf_cv_ncurses_header:-curses.h}>
16154 #ifdef NCURSES_VERSION
16155 #include <${cf_header}>
16167 rm -f conftest.$ac_objext
16168 if { (eval echo "$as_me:16168: \"$ac_compile\"") >&5
16169 (eval $ac_compile) 2>&5
16171 echo "$as_me:16171: \$? = $ac_status" >&5
16172 (exit $ac_status); } &&
16173 { ac_try='test -s conftest.$ac_objext'
16174 { (eval echo "$as_me:16174: \"$ac_try\"") >&5
16175 (eval $ac_try) 2>&5
16177 echo "$as_me:16177: \$? = $ac_status" >&5
16178 (exit $ac_status); }; }; then
16179 cf_cv_term_header=$cf_header
16182 echo "$as_me: failed program was:" >&5
16183 cat conftest.$ac_ext >&5
16184 cf_cv_term_header=no
16186 rm -f conftest.$ac_objext conftest.$ac_ext
16192 echo "$as_me:16192: result: $cf_cv_term_header" >&5
16193 echo "${ECHO_T}$cf_cv_term_header" >&6
16195 case $cf_cv_term_header in
16198 cat >>confdefs.h <<\EOF
16199 #define HAVE_TERM_H 1
16205 cat >>confdefs.h <<\EOF
16206 #define HAVE_NCURSES_TERM_H 1
16212 cat >>confdefs.h <<\EOF
16213 #define HAVE_NCURSESW_TERM_H 1
16219 echo "$as_me:16219: checking for unctrl.h" >&5
16220 echo $ECHO_N "checking for unctrl.h... $ECHO_C" >&6
16221 if test "${cf_cv_unctrl_header+set}" = set; then
16222 echo $ECHO_N "(cached) $ECHO_C" >&6
16225 # If we found <ncurses/curses.h>, look for <ncurses/unctrl.h>, but always look
16226 # for <unctrl.h> if we do not find the variant.
16228 cf_header_list="unctrl.h ncurses/unctrl.h ncursesw/unctrl.h"
16230 case ${cf_cv_ncurses_header:-curses.h} in
16232 cf_header_item=`echo ${cf_cv_ncurses_header:-curses.h} | sed -e 's%\..*%%' -e 's%/.*%/%'`unctrl.h
16233 cf_header_list="$cf_header_item $cf_header_list"
16237 for cf_header in $cf_header_list
16239 cat >conftest.$ac_ext <<_ACEOF
16240 #line 16240 "configure"
16241 #include "confdefs.h"
16243 #include <${cf_cv_ncurses_header:-curses.h}>
16244 #include <${cf_header}>
16253 rm -f conftest.$ac_objext
16254 if { (eval echo "$as_me:16254: \"$ac_compile\"") >&5
16255 (eval $ac_compile) 2>&5
16257 echo "$as_me:16257: \$? = $ac_status" >&5
16258 (exit $ac_status); } &&
16259 { ac_try='test -s conftest.$ac_objext'
16260 { (eval echo "$as_me:16260: \"$ac_try\"") >&5
16261 (eval $ac_try) 2>&5
16263 echo "$as_me:16263: \$? = $ac_status" >&5
16264 (exit $ac_status); }; }; then
16265 cf_cv_unctrl_header=$cf_header
16268 echo "$as_me: failed program was:" >&5
16269 cat conftest.$ac_ext >&5
16270 cf_cv_unctrl_header=no
16272 rm -f conftest.$ac_objext conftest.$ac_ext
16276 echo "$as_me:16276: result: $cf_cv_unctrl_header" >&5
16277 echo "${ECHO_T}$cf_cv_unctrl_header" >&6
16279 case $cf_cv_unctrl_header in
16281 { echo "$as_me:16281: WARNING: unctrl.h header not found" >&5
16282 echo "$as_me: WARNING: unctrl.h header not found" >&2;}
16286 case $cf_cv_unctrl_header in
16289 cat >>confdefs.h <<\EOF
16290 #define HAVE_UNCTRL_H 1
16296 cat >>confdefs.h <<\EOF
16297 #define HAVE_NCURSES_UNCTRL_H 1
16301 (ncursesw/unctrl.h)
16303 cat >>confdefs.h <<\EOF
16304 #define HAVE_NCURSESW_UNCTRL_H 1
16312 assume_default_colors \
16327 init_extended_color \
16335 reset_color_pairs \
16350 use_default_colors \
16352 use_extended_names \
16368 cf_tr_func=`echo "$cf_func" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
16370 echo "$as_me:16370: checking for ${cf_func}" >&5
16371 echo $ECHO_N "checking for ${cf_func}... $ECHO_C" >&6
16373 echo "${as_me:-configure}:16373: testing ${cf_func} ..." 1>&5
16375 if eval "test \"\${cf_cv_func_$cf_func+set}\" = set"; then
16376 echo $ECHO_N "(cached) $ECHO_C" >&6
16379 eval cf_result='$ac_cv_func_'$cf_func
16380 if test ".$cf_result" != ".no"; then
16381 cat >conftest.$ac_ext <<_ACEOF
16382 #line 16382 "configure"
16383 #include "confdefs.h"
16385 #ifdef HAVE_XCURSES
16386 #include <xcurses.h>
16387 char * XCursesProgramName = "test";
16389 #include <${cf_cv_ncurses_header:-curses.h}>
16390 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
16391 #include <ncursesw/term.h>
16392 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
16393 #include <ncurses/term.h>
16394 #elif defined(HAVE_TERM_H)
16404 long foo = (long)(&${cf_func});
16405 fprintf(stderr, "testing linkage of $cf_func:%p\n", (void *)foo);
16406 if (foo + 1234L > 5678L)
16407 ${cf_cv_main_return:-return}(foo != 0);
16414 rm -f conftest.$ac_objext conftest$ac_exeext
16415 if { (eval echo "$as_me:16415: \"$ac_link\"") >&5
16416 (eval $ac_link) 2>&5
16418 echo "$as_me:16418: \$? = $ac_status" >&5
16419 (exit $ac_status); } &&
16420 { ac_try='test -s conftest$ac_exeext'
16421 { (eval echo "$as_me:16421: \"$ac_try\"") >&5
16422 (eval $ac_try) 2>&5
16424 echo "$as_me:16424: \$? = $ac_status" >&5
16425 (exit $ac_status); }; }; then
16428 echo "$as_me: failed program was:" >&5
16429 cat conftest.$ac_ext >&5
16432 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16434 eval 'cf_cv_func_'$cf_func'=$cf_result'
16438 # use the computed/retrieved cache-value:
16439 eval 'cf_result=$cf_cv_func_'$cf_func
16440 echo "$as_me:16440: result: $cf_result" >&5
16441 echo "${ECHO_T}$cf_result" >&6
16442 if test $cf_result != no; then
16443 cat >>confdefs.h <<EOF
16444 #define HAVE_${cf_tr_func} 1
16450 for cf_func in tputs
16453 cf_tr_func=`echo "$cf_func" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
16455 echo "$as_me:16455: checking for ${cf_func}" >&5
16456 echo $ECHO_N "checking for ${cf_func}... $ECHO_C" >&6
16458 echo "${as_me:-configure}:16458: testing ${cf_func} ..." 1>&5
16460 if eval "test \"\${cf_cv_func_$cf_func+set}\" = set"; then
16461 echo $ECHO_N "(cached) $ECHO_C" >&6
16464 eval cf_result='$ac_cv_func_'$cf_func
16465 if test ".$cf_result" != ".no"; then
16466 cat >conftest.$ac_ext <<_ACEOF
16467 #line 16467 "configure"
16468 #include "confdefs.h"
16470 #ifdef HAVE_XCURSES
16471 #include <xcurses.h>
16472 char * XCursesProgramName = "test";
16474 #include <${cf_cv_ncurses_header:-curses.h}>
16475 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
16476 #include <ncursesw/term.h>
16477 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
16478 #include <ncurses/term.h>
16479 #elif defined(HAVE_TERM_H)
16489 long foo = (long)(&${cf_func});
16490 fprintf(stderr, "testing linkage of $cf_func:%p\n", (void *)foo);
16491 if (foo + 1234L > 5678L)
16492 ${cf_cv_main_return:-return}(foo != 0);
16499 rm -f conftest.$ac_objext conftest$ac_exeext
16500 if { (eval echo "$as_me:16500: \"$ac_link\"") >&5
16501 (eval $ac_link) 2>&5
16503 echo "$as_me:16503: \$? = $ac_status" >&5
16504 (exit $ac_status); } &&
16505 { ac_try='test -s conftest$ac_exeext'
16506 { (eval echo "$as_me:16506: \"$ac_try\"") >&5
16507 (eval $ac_try) 2>&5
16509 echo "$as_me:16509: \$? = $ac_status" >&5
16510 (exit $ac_status); }; }; then
16513 echo "$as_me: failed program was:" >&5
16514 cat conftest.$ac_ext >&5
16517 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16519 eval 'cf_cv_func_'$cf_func'=$cf_result'
16523 # use the computed/retrieved cache-value:
16524 eval 'cf_result=$cf_cv_func_'$cf_func
16525 echo "$as_me:16525: result: $cf_result" >&5
16526 echo "${ECHO_T}$cf_result" >&6
16527 if test $cf_result != no; then
16528 cat >>confdefs.h <<EOF
16529 #define HAVE_${cf_tr_func} 1
16535 if test x$cf_cv_func_tputs = xyes
16538 for cf_arg in int char
16540 for cf_ret in int void
16542 if test $cf_ret = void
16544 cf_return="/* nothing */"
16546 cf_return="return value"
16548 cat >conftest.$ac_ext <<_ACEOF
16549 #line 16549 "configure"
16550 #include "confdefs.h"
16552 #include <${cf_cv_ncurses_header:-curses.h}>
16553 #include <$cf_cv_term_header>
16555 static $cf_ret outc($cf_arg value) { $cf_return; }
16561 tputs("hello", 0, outc);
16562 ${cf_cv_main_return:-return}(0);
16568 rm -f conftest.$ac_objext
16569 if { (eval echo "$as_me:16569: \"$ac_compile\"") >&5
16570 (eval $ac_compile) 2>&5
16572 echo "$as_me:16572: \$? = $ac_status" >&5
16573 (exit $ac_status); } &&
16574 { ac_try='test -s conftest.$ac_objext'
16575 { (eval echo "$as_me:16575: \"$ac_try\"") >&5
16576 (eval $ac_try) 2>&5
16578 echo "$as_me:16578: \$? = $ac_status" >&5
16579 (exit $ac_status); }; }; then
16581 test -n "$verbose" && echo " prototype $cf_ret func($cf_arg value)" 1>&6
16583 echo "${as_me:-configure}:16583: testing prototype $cf_ret func($cf_arg value) ..." 1>&5
16585 cat >>confdefs.h <<EOF
16586 #define TPUTS_ARG $cf_arg
16587 #define TPUTS_PROTO(func,value) $cf_ret func(TPUTS_ARG value)
16588 #define TPUTS_RETURN(value) $cf_return
16594 echo "$as_me: failed program was:" >&5
16595 cat conftest.$ac_ext >&5
16597 rm -f conftest.$ac_objext conftest.$ac_ext
16599 test $cf_done = yes && break
16603 echo "$as_me:16603: checking for ncurses extended functions" >&5
16604 echo $ECHO_N "checking for ncurses extended functions... $ECHO_C" >&6
16605 if test "${cf_cv_ncurses_ext_funcs+set}" = set; then
16606 echo $ECHO_N "(cached) $ECHO_C" >&6
16609 cat >conftest.$ac_ext <<_ACEOF
16610 #line 16610 "configure"
16611 #include "confdefs.h"
16613 #include <${cf_cv_ncurses_header:-curses.h}>
16618 int x = NCURSES_EXT_FUNCS
16624 rm -f conftest.$ac_objext
16625 if { (eval echo "$as_me:16625: \"$ac_compile\"") >&5
16626 (eval $ac_compile) 2>&5
16628 echo "$as_me:16628: \$? = $ac_status" >&5
16629 (exit $ac_status); } &&
16630 { ac_try='test -s conftest.$ac_objext'
16631 { (eval echo "$as_me:16631: \"$ac_try\"") >&5
16632 (eval $ac_try) 2>&5
16634 echo "$as_me:16634: \$? = $ac_status" >&5
16635 (exit $ac_status); }; }; then
16636 cf_cv_ncurses_ext_funcs=defined
16638 echo "$as_me: failed program was:" >&5
16639 cat conftest.$ac_ext >&5
16641 cat >conftest.$ac_ext <<_ACEOF
16642 #line 16642 "configure"
16643 #include "confdefs.h"
16645 #include <${cf_cv_ncurses_header:-curses.h}>
16650 (void) assume_default_colors (0, 0);
16651 (void) curses_version ();
16652 (void) define_key (0, 0);
16653 (void) is_term_resized (0, 0);
16654 (void) key_defined (0);
16655 (void) keybound (0, 0);
16656 (void) keyok (0, 0);
16657 (void) resize_term (0, 0);
16658 (void) resizeterm (0, 0);
16659 (void) use_default_colors ();
16660 (void) use_extended_names (0);
16661 (void) wresize (0, 0, 0);
16666 rm -f conftest.$ac_objext conftest$ac_exeext
16667 if { (eval echo "$as_me:16667: \"$ac_link\"") >&5
16668 (eval $ac_link) 2>&5
16670 echo "$as_me:16670: \$? = $ac_status" >&5
16671 (exit $ac_status); } &&
16672 { ac_try='test -s conftest$ac_exeext'
16673 { (eval echo "$as_me:16673: \"$ac_try\"") >&5
16674 (eval $ac_try) 2>&5
16676 echo "$as_me:16676: \$? = $ac_status" >&5
16677 (exit $ac_status); }; }; then
16678 cf_cv_ncurses_ext_funcs=yes
16680 echo "$as_me: failed program was:" >&5
16681 cat conftest.$ac_ext >&5
16682 cf_cv_ncurses_ext_funcs=no
16684 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16687 rm -f conftest.$ac_objext conftest.$ac_ext
16690 echo "$as_me:16690: result: $cf_cv_ncurses_ext_funcs" >&5
16691 echo "${ECHO_T}$cf_cv_ncurses_ext_funcs" >&6
16692 test "$cf_cv_ncurses_ext_funcs" = yes &&
16693 cat >>confdefs.h <<\EOF
16694 #define NCURSES_EXT_FUNCS 1
16697 if test "$cf_enable_widec" = yes
16699 # workaround for systems with ncurses before 20111029, due to change of
16700 # feature test macro from _XPG5 to _XOPEN_SOURCE
16701 if test -n "$cf_cv_ncurses_version" && test "x$cf_cv_ncurses_version" != xno
16704 echo "$as_me:16704: checking if _XPG5 should be defined to enable wide-characters" >&5
16705 echo $ECHO_N "checking if _XPG5 should be defined to enable wide-characters... $ECHO_C" >&6
16707 cat >conftest.$ac_ext <<_ACEOF
16708 #line 16708 "configure"
16709 #include "confdefs.h"
16711 #include <${cf_cv_ncurses_header:-curses.h}>
16720 rm -f conftest.$ac_objext
16721 if { (eval echo "$as_me:16721: \"$ac_compile\"") >&5
16722 (eval $ac_compile) 2>&5
16724 echo "$as_me:16724: \$? = $ac_status" >&5
16725 (exit $ac_status); } &&
16726 { ac_try='test -s conftest.$ac_objext'
16727 { (eval echo "$as_me:16727: \"$ac_try\"") >&5
16728 (eval $ac_try) 2>&5
16730 echo "$as_me:16730: \$? = $ac_status" >&5
16731 (exit $ac_status); }; }; then
16734 echo "$as_me: failed program was:" >&5
16735 cat conftest.$ac_ext >&5
16736 cf_save_cppflags="$CPPFLAGS"
16737 CPPFLAGS="$CPPFLAGS -D_XPG5"
16738 cat >conftest.$ac_ext <<_ACEOF
16739 #line 16739 "configure"
16740 #include "confdefs.h"
16742 #include <${cf_cv_ncurses_header:-curses.h}>
16751 rm -f conftest.$ac_objext
16752 if { (eval echo "$as_me:16752: \"$ac_compile\"") >&5
16753 (eval $ac_compile) 2>&5
16755 echo "$as_me:16755: \$? = $ac_status" >&5
16756 (exit $ac_status); } &&
16757 { ac_try='test -s conftest.$ac_objext'
16758 { (eval echo "$as_me:16758: \"$ac_try\"") >&5
16759 (eval $ac_try) 2>&5
16761 echo "$as_me:16761: \$? = $ac_status" >&5
16762 (exit $ac_status); }; }; then
16765 echo "$as_me: failed program was:" >&5
16766 cat conftest.$ac_ext >&5
16768 rm -f conftest.$ac_objext conftest.$ac_ext
16769 CPPFLAGS="$cf_save_cppflags"
16771 rm -f conftest.$ac_objext conftest.$ac_ext
16772 echo "$as_me:16772: result: $cf_define_xpg5" >&5
16773 echo "${ECHO_T}$cf_define_xpg5" >&6
16775 if test "$cf_define_xpg5" = yes
16777 CPPFLAGS="$CPPFLAGS -D_XPG5"
16781 echo "$as_me:16781: checking for wide-character functions" >&5
16782 echo $ECHO_N "checking for wide-character functions... $ECHO_C" >&6
16783 if test "${cf_cv_widechar_funcs+set}" = set; then
16784 echo $ECHO_N "(cached) $ECHO_C" >&6
16787 cat >conftest.$ac_ext <<_ACEOF
16788 #line 16788 "configure"
16789 #include "confdefs.h"
16791 #include <${cf_cv_ncurses_header:-curses.h}>
16796 static wchar_t src_wchar[2];
16797 static cchar_t dst_cchar;
16798 setcchar(&dst_cchar, src_wchar, A_NORMAL, 0, (void *) 0);
16804 rm -f conftest.$ac_objext conftest$ac_exeext
16805 if { (eval echo "$as_me:16805: \"$ac_link\"") >&5
16806 (eval $ac_link) 2>&5
16808 echo "$as_me:16808: \$? = $ac_status" >&5
16809 (exit $ac_status); } &&
16810 { ac_try='test -s conftest$ac_exeext'
16811 { (eval echo "$as_me:16811: \"$ac_try\"") >&5
16812 (eval $ac_try) 2>&5
16814 echo "$as_me:16814: \$? = $ac_status" >&5
16815 (exit $ac_status); }; }; then
16816 cf_cv_widechar_funcs=yes
16818 echo "$as_me: failed program was:" >&5
16819 cat conftest.$ac_ext >&5
16820 cf_cv_widechar_funcs=no
16822 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16825 echo "$as_me:16825: result: $cf_cv_widechar_funcs" >&5
16826 echo "${ECHO_T}$cf_cv_widechar_funcs" >&6
16827 if test "$cf_cv_widechar_funcs" != no ; then
16829 cat >>confdefs.h <<\EOF
16830 #define USE_WIDEC_SUPPORT 1
16834 cat >>confdefs.h <<\EOF
16835 #define USE_WIDEC_SUPPORT 0
16840 cat >>confdefs.h <<\EOF
16841 #define USE_WIDEC_SUPPORT 0
16846 echo "$as_me:16846: checking if $cf_cv_screen library uses pthreads" >&5
16847 echo $ECHO_N "checking if $cf_cv_screen library uses pthreads... $ECHO_C" >&6
16848 if test "${cf_cv_use_pthreads+set}" = set; then
16849 echo $ECHO_N "(cached) $ECHO_C" >&6
16852 cat >conftest.$ac_ext <<_ACEOF
16853 #line 16853 "configure"
16854 #include "confdefs.h"
16856 #include <${cf_cv_ncurses_header:-curses.h}>
16857 extern void _nc_init_pthreads(void);
16864 _nc_init_pthreads();
16870 rm -f conftest.$ac_objext conftest$ac_exeext
16871 if { (eval echo "$as_me:16871: \"$ac_link\"") >&5
16872 (eval $ac_link) 2>&5
16874 echo "$as_me:16874: \$? = $ac_status" >&5
16875 (exit $ac_status); } &&
16876 { ac_try='test -s conftest$ac_exeext'
16877 { (eval echo "$as_me:16877: \"$ac_try\"") >&5
16878 (eval $ac_try) 2>&5
16880 echo "$as_me:16880: \$? = $ac_status" >&5
16881 (exit $ac_status); }; }; then
16882 cf_cv_use_pthreads=yes
16884 echo "$as_me: failed program was:" >&5
16885 cat conftest.$ac_ext >&5
16886 cf_cv_use_pthreads=no
16888 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16891 echo "$as_me:16891: result: $cf_cv_use_pthreads" >&5
16892 echo "${ECHO_T}$cf_cv_use_pthreads" >&6
16893 test $cf_cv_use_pthreads = yes && cat >>confdefs.h <<\EOF
16894 #define USE_PTHREADS 1
16897 echo "$as_me:16897: checking if sys/time.h works with sys/select.h" >&5
16898 echo $ECHO_N "checking if sys/time.h works with sys/select.h... $ECHO_C" >&6
16899 if test "${cf_cv_sys_time_select+set}" = set; then
16900 echo $ECHO_N "(cached) $ECHO_C" >&6
16903 cat >conftest.$ac_ext <<_ACEOF
16904 #line 16904 "configure"
16905 #include "confdefs.h"
16907 #include <sys/types.h>
16908 #ifdef HAVE_SYS_TIME_H
16909 #include <sys/time.h>
16911 #ifdef HAVE_SYS_SELECT_H
16912 #include <sys/select.h>
16923 rm -f conftest.$ac_objext
16924 if { (eval echo "$as_me:16924: \"$ac_compile\"") >&5
16925 (eval $ac_compile) 2>&5
16927 echo "$as_me:16927: \$? = $ac_status" >&5
16928 (exit $ac_status); } &&
16929 { ac_try='test -s conftest.$ac_objext'
16930 { (eval echo "$as_me:16930: \"$ac_try\"") >&5
16931 (eval $ac_try) 2>&5
16933 echo "$as_me:16933: \$? = $ac_status" >&5
16934 (exit $ac_status); }; }; then
16935 cf_cv_sys_time_select=yes
16937 echo "$as_me: failed program was:" >&5
16938 cat conftest.$ac_ext >&5
16939 cf_cv_sys_time_select=no
16941 rm -f conftest.$ac_objext conftest.$ac_ext
16945 echo "$as_me:16945: result: $cf_cv_sys_time_select" >&5
16946 echo "${ECHO_T}$cf_cv_sys_time_select" >&6
16947 test "$cf_cv_sys_time_select" = yes &&
16948 cat >>confdefs.h <<\EOF
16949 #define HAVE_SYS_TIME_SELECT 1
16952 # special check for test/ditto.c
16954 echo "$as_me:16954: checking for openpty in -lutil" >&5
16955 echo $ECHO_N "checking for openpty in -lutil... $ECHO_C" >&6
16956 if test "${ac_cv_lib_util_openpty+set}" = set; then
16957 echo $ECHO_N "(cached) $ECHO_C" >&6
16959 ac_check_lib_save_LIBS=$LIBS
16960 LIBS="-lutil $LIBS"
16961 cat >conftest.$ac_ext <<_ACEOF
16962 #line 16962 "configure"
16963 #include "confdefs.h"
16965 /* Override any gcc2 internal prototype to avoid an error. */
16969 /* We use char because int might match the return type of a gcc2
16970 builtin and then its argument prototype would still apply. */
16980 rm -f conftest.$ac_objext conftest$ac_exeext
16981 if { (eval echo "$as_me:16981: \"$ac_link\"") >&5
16982 (eval $ac_link) 2>&5
16984 echo "$as_me:16984: \$? = $ac_status" >&5
16985 (exit $ac_status); } &&
16986 { ac_try='test -s conftest$ac_exeext'
16987 { (eval echo "$as_me:16987: \"$ac_try\"") >&5
16988 (eval $ac_try) 2>&5
16990 echo "$as_me:16990: \$? = $ac_status" >&5
16991 (exit $ac_status); }; }; then
16992 ac_cv_lib_util_openpty=yes
16994 echo "$as_me: failed program was:" >&5
16995 cat conftest.$ac_ext >&5
16996 ac_cv_lib_util_openpty=no
16998 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16999 LIBS=$ac_check_lib_save_LIBS
17001 echo "$as_me:17001: result: $ac_cv_lib_util_openpty" >&5
17002 echo "${ECHO_T}$ac_cv_lib_util_openpty" >&6
17003 if test $ac_cv_lib_util_openpty = yes; then
17009 echo "$as_me:17009: checking for openpty header" >&5
17010 echo $ECHO_N "checking for openpty header... $ECHO_C" >&6
17011 if test "${cf_cv_func_openpty+set}" = set; then
17012 echo $ECHO_N "(cached) $ECHO_C" >&6
17015 cf_save_LIBS="$LIBS"
17016 test $cf_cv_lib_util = yes && {
17017 cf_add_libs="-lutil"
17018 # Filter out duplicates - this happens with badly-designed ".pc" files...
17019 for cf_add_1lib in $LIBS
17021 for cf_add_2lib in $cf_add_libs
17023 if test "x$cf_add_1lib" = "x$cf_add_2lib"
17029 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
17031 LIBS="$cf_add_libs"
17033 for cf_header in pty.h libutil.h util.h
17035 cat >conftest.$ac_ext <<_ACEOF
17036 #line 17036 "configure"
17037 #include "confdefs.h"
17039 #include <$cf_header>
17045 int x = openpty((int *)0, (int *)0, (char *)0,
17046 (struct termios *)0, (struct winsize *)0);
17052 rm -f conftest.$ac_objext conftest$ac_exeext
17053 if { (eval echo "$as_me:17053: \"$ac_link\"") >&5
17054 (eval $ac_link) 2>&5
17056 echo "$as_me:17056: \$? = $ac_status" >&5
17057 (exit $ac_status); } &&
17058 { ac_try='test -s conftest$ac_exeext'
17059 { (eval echo "$as_me:17059: \"$ac_try\"") >&5
17060 (eval $ac_try) 2>&5
17062 echo "$as_me:17062: \$? = $ac_status" >&5
17063 (exit $ac_status); }; }; then
17065 cf_cv_func_openpty=$cf_header
17069 echo "$as_me: failed program was:" >&5
17070 cat conftest.$ac_ext >&5
17072 cf_cv_func_openpty=no
17075 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17077 LIBS="$cf_save_LIBS"
17080 echo "$as_me:17080: result: $cf_cv_func_openpty" >&5
17081 echo "${ECHO_T}$cf_cv_func_openpty" >&6
17083 if test "$cf_cv_func_openpty" != no ; then
17085 cat >>confdefs.h <<EOF
17086 #define USE_OPENPTY_HEADER <$cf_cv_func_openpty>
17089 cat >>confdefs.h <<\EOF
17090 #define USE_XTERM_PTY 1
17093 if test "x$cf_cv_lib_util" = xyes ; then
17095 cf_add_libs="-lutil"
17096 # Filter out duplicates - this happens with badly-designed ".pc" files...
17097 for cf_add_1lib in $TEST_LIBS
17099 for cf_add_2lib in $cf_add_libs
17101 if test "x$cf_add_1lib" = "x$cf_add_2lib"
17107 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
17109 TEST_LIBS="$cf_add_libs"
17114 echo "$as_me:17114: checking for function curses_version" >&5
17115 echo $ECHO_N "checking for function curses_version... $ECHO_C" >&6
17116 if test "${cf_cv_func_curses_version+set}" = set; then
17117 echo $ECHO_N "(cached) $ECHO_C" >&6
17120 if test "$cross_compiling" = yes; then
17121 cf_cv_func_curses_version=unknown
17123 cat >conftest.$ac_ext <<_ACEOF
17124 #line 17124 "configure"
17125 #include "confdefs.h"
17127 #include <${cf_cv_ncurses_header:-curses.h}>
17131 sprintf(temp, "%s\n", curses_version());
17132 ${cf_cv_main_return:-return}(0);
17136 rm -f conftest$ac_exeext
17137 if { (eval echo "$as_me:17137: \"$ac_link\"") >&5
17138 (eval $ac_link) 2>&5
17140 echo "$as_me:17140: \$? = $ac_status" >&5
17141 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17142 { (eval echo "$as_me:17142: \"$ac_try\"") >&5
17143 (eval $ac_try) 2>&5
17145 echo "$as_me:17145: \$? = $ac_status" >&5
17146 (exit $ac_status); }; }; then
17147 cf_cv_func_curses_version=yes
17150 echo "$as_me: program exited with status $ac_status" >&5
17151 echo "$as_me: failed program was:" >&5
17152 cat conftest.$ac_ext >&5
17153 cf_cv_func_curses_version=no
17156 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17160 echo "$as_me:17160: result: $cf_cv_func_curses_version" >&5
17161 echo "${ECHO_T}$cf_cv_func_curses_version" >&6
17162 test "$cf_cv_func_curses_version" = yes &&
17163 cat >>confdefs.h <<\EOF
17164 #define HAVE_CURSES_VERSION 1
17167 echo "$as_me:17167: checking for alternate character set array" >&5
17168 echo $ECHO_N "checking for alternate character set array... $ECHO_C" >&6
17169 if test "${cf_cv_curses_acs_map+set}" = set; then
17170 echo $ECHO_N "(cached) $ECHO_C" >&6
17173 cf_cv_curses_acs_map=unknown
17174 for name in acs_map _acs_map __acs_map ${NCURSES_WRAP_PREFIX}acs_map
17176 cat >conftest.$ac_ext <<_ACEOF
17177 #line 17177 "configure"
17178 #include "confdefs.h"
17180 #include <${cf_cv_ncurses_header:-curses.h}>
17186 $name['k'] = ACS_PLUS
17192 rm -f conftest.$ac_objext conftest$ac_exeext
17193 if { (eval echo "$as_me:17193: \"$ac_link\"") >&5
17194 (eval $ac_link) 2>&5
17196 echo "$as_me:17196: \$? = $ac_status" >&5
17197 (exit $ac_status); } &&
17198 { ac_try='test -s conftest$ac_exeext'
17199 { (eval echo "$as_me:17199: \"$ac_try\"") >&5
17200 (eval $ac_try) 2>&5
17202 echo "$as_me:17202: \$? = $ac_status" >&5
17203 (exit $ac_status); }; }; then
17204 cf_cv_curses_acs_map=$name; break
17206 echo "$as_me: failed program was:" >&5
17207 cat conftest.$ac_ext >&5
17209 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17213 echo "$as_me:17213: result: $cf_cv_curses_acs_map" >&5
17214 echo "${ECHO_T}$cf_cv_curses_acs_map" >&6
17216 test "$cf_cv_curses_acs_map" != unknown &&
17217 cat >>confdefs.h <<EOF
17218 #define CURSES_ACS_ARRAY $cf_cv_curses_acs_map
17221 if test "$cf_enable_widec" = yes; then
17223 echo "$as_me:17223: checking for wide alternate character set array" >&5
17224 echo $ECHO_N "checking for wide alternate character set array... $ECHO_C" >&6
17225 if test "${cf_cv_curses_wacs_map+set}" = set; then
17226 echo $ECHO_N "(cached) $ECHO_C" >&6
17229 cf_cv_curses_wacs_map=unknown
17230 for name in wacs_map _wacs_map __wacs_map _nc_wacs _wacs_char
17232 cat >conftest.$ac_ext <<_ACEOF
17233 #line 17233 "configure"
17234 #include "confdefs.h"
17236 #ifndef _XOPEN_SOURCE_EXTENDED
17237 #define _XOPEN_SOURCE_EXTENDED
17239 #include <${cf_cv_ncurses_header:-curses.h}>
17243 void *foo = &($name['k'])
17248 rm -f conftest.$ac_objext conftest$ac_exeext
17249 if { (eval echo "$as_me:17249: \"$ac_link\"") >&5
17250 (eval $ac_link) 2>&5
17252 echo "$as_me:17252: \$? = $ac_status" >&5
17253 (exit $ac_status); } &&
17254 { ac_try='test -s conftest$ac_exeext'
17255 { (eval echo "$as_me:17255: \"$ac_try\"") >&5
17256 (eval $ac_try) 2>&5
17258 echo "$as_me:17258: \$? = $ac_status" >&5
17259 (exit $ac_status); }; }; then
17260 cf_cv_curses_wacs_map=$name
17263 echo "$as_me: failed program was:" >&5
17264 cat conftest.$ac_ext >&5
17266 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17269 echo "$as_me:17269: result: $cf_cv_curses_wacs_map" >&5
17270 echo "${ECHO_T}$cf_cv_curses_wacs_map" >&6
17272 test "$cf_cv_curses_wacs_map" != unknown &&
17273 cat >>confdefs.h <<EOF
17274 #define CURSES_WACS_ARRAY $cf_cv_curses_wacs_map
17277 echo "$as_me:17277: checking for wide alternate character constants" >&5
17278 echo $ECHO_N "checking for wide alternate character constants... $ECHO_C" >&6
17279 if test "${cf_cv_curses_wacs_symbols+set}" = set; then
17280 echo $ECHO_N "(cached) $ECHO_C" >&6
17283 cf_cv_curses_wacs_symbols=no
17284 if test "$cf_cv_curses_wacs_map" != unknown
17286 cat >conftest.$ac_ext <<_ACEOF
17287 #line 17287 "configure"
17288 #include "confdefs.h"
17290 #ifndef _XOPEN_SOURCE_EXTENDED
17291 #define _XOPEN_SOURCE_EXTENDED
17293 #include <${cf_cv_ncurses_header:-curses.h}>
17297 cchar_t *foo = WACS_PLUS;
17298 $cf_cv_curses_wacs_map['k'] = *WACS_PLUS
17303 rm -f conftest.$ac_objext conftest$ac_exeext
17304 if { (eval echo "$as_me:17304: \"$ac_link\"") >&5
17305 (eval $ac_link) 2>&5
17307 echo "$as_me:17307: \$? = $ac_status" >&5
17308 (exit $ac_status); } &&
17309 { ac_try='test -s conftest$ac_exeext'
17310 { (eval echo "$as_me:17310: \"$ac_try\"") >&5
17311 (eval $ac_try) 2>&5
17313 echo "$as_me:17313: \$? = $ac_status" >&5
17314 (exit $ac_status); }; }; then
17315 cf_cv_curses_wacs_symbols=yes
17317 echo "$as_me: failed program was:" >&5
17318 cat conftest.$ac_ext >&5
17320 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17322 cat >conftest.$ac_ext <<_ACEOF
17323 #line 17323 "configure"
17324 #include "confdefs.h"
17326 #ifndef _XOPEN_SOURCE_EXTENDED
17327 #define _XOPEN_SOURCE_EXTENDED
17329 #include <${cf_cv_ncurses_header:-curses.h}>
17333 cchar_t *foo = WACS_PLUS
17338 rm -f conftest.$ac_objext conftest$ac_exeext
17339 if { (eval echo "$as_me:17339: \"$ac_link\"") >&5
17340 (eval $ac_link) 2>&5
17342 echo "$as_me:17342: \$? = $ac_status" >&5
17343 (exit $ac_status); } &&
17344 { ac_try='test -s conftest$ac_exeext'
17345 { (eval echo "$as_me:17345: \"$ac_try\"") >&5
17346 (eval $ac_try) 2>&5
17348 echo "$as_me:17348: \$? = $ac_status" >&5
17349 (exit $ac_status); }; }; then
17350 cf_cv_curses_wacs_symbols=yes
17352 echo "$as_me: failed program was:" >&5
17353 cat conftest.$ac_ext >&5
17355 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17359 echo "$as_me:17359: result: $cf_cv_curses_wacs_symbols" >&5
17360 echo "${ECHO_T}$cf_cv_curses_wacs_symbols" >&6
17362 test "$cf_cv_curses_wacs_symbols" != no &&
17363 cat >>confdefs.h <<\EOF
17364 #define CURSES_WACS_SYMBOLS 1
17369 echo "$as_me:17369: checking for type attr_t in ${cf_cv_ncurses_header:-curses.h}" >&5
17370 echo $ECHO_N "checking for type attr_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
17371 cat >conftest.$ac_ext <<_ACEOF
17372 #line 17372 "configure"
17373 #include "confdefs.h"
17375 #ifndef _XOPEN_SOURCE_EXTENDED
17376 #define _XOPEN_SOURCE_EXTENDED
17378 #include <${cf_cv_ncurses_header:-curses.h}>
17389 rm -f conftest.$ac_objext
17390 if { (eval echo "$as_me:17390: \"$ac_compile\"") >&5
17391 (eval $ac_compile) 2>&5
17393 echo "$as_me:17393: \$? = $ac_status" >&5
17394 (exit $ac_status); } &&
17395 { ac_try='test -s conftest.$ac_objext'
17396 { (eval echo "$as_me:17396: \"$ac_try\"") >&5
17397 (eval $ac_try) 2>&5
17399 echo "$as_me:17399: \$? = $ac_status" >&5
17400 (exit $ac_status); }; }; then
17403 echo "$as_me: failed program was:" >&5
17404 cat conftest.$ac_ext >&5
17407 rm -f conftest.$ac_objext conftest.$ac_ext
17408 echo "$as_me:17408: result: $cf_result" >&5
17409 echo "${ECHO_T}$cf_result" >&6
17410 if test $cf_result = yes ; then
17412 cf_result=`echo "have_type_attr_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
17414 cat >>confdefs.h <<EOF
17415 #define $cf_result 1
17420 cat >>confdefs.h <<EOF
17421 #define attr_t long
17426 if test "$cf_enable_widec" = yes; then
17428 # This is needed on Tru64 5.0 to declare mbstate_t
17429 echo "$as_me:17429: checking if we must include wchar.h to declare mbstate_t" >&5
17430 echo $ECHO_N "checking if we must include wchar.h to declare mbstate_t... $ECHO_C" >&6
17431 if test "${cf_cv_mbstate_t+set}" = set; then
17432 echo $ECHO_N "(cached) $ECHO_C" >&6
17435 cat >conftest.$ac_ext <<_ACEOF
17436 #line 17436 "configure"
17437 #include "confdefs.h"
17439 #include <stdlib.h>
17440 #include <stdarg.h>
17442 #ifdef HAVE_LIBUTF8_H
17443 #include <libutf8.h>
17453 rm -f conftest.$ac_objext
17454 if { (eval echo "$as_me:17454: \"$ac_compile\"") >&5
17455 (eval $ac_compile) 2>&5
17457 echo "$as_me:17457: \$? = $ac_status" >&5
17458 (exit $ac_status); } &&
17459 { ac_try='test -s conftest.$ac_objext'
17460 { (eval echo "$as_me:17460: \"$ac_try\"") >&5
17461 (eval $ac_try) 2>&5
17463 echo "$as_me:17463: \$? = $ac_status" >&5
17464 (exit $ac_status); }; }; then
17467 echo "$as_me: failed program was:" >&5
17468 cat conftest.$ac_ext >&5
17469 cat >conftest.$ac_ext <<_ACEOF
17470 #line 17470 "configure"
17471 #include "confdefs.h"
17473 #include <stdlib.h>
17474 #include <stdarg.h>
17477 #ifdef HAVE_LIBUTF8_H
17478 #include <libutf8.h>
17488 rm -f conftest.$ac_objext
17489 if { (eval echo "$as_me:17489: \"$ac_compile\"") >&5
17490 (eval $ac_compile) 2>&5
17492 echo "$as_me:17492: \$? = $ac_status" >&5
17493 (exit $ac_status); } &&
17494 { ac_try='test -s conftest.$ac_objext'
17495 { (eval echo "$as_me:17495: \"$ac_try\"") >&5
17496 (eval $ac_try) 2>&5
17498 echo "$as_me:17498: \$? = $ac_status" >&5
17499 (exit $ac_status); }; }; then
17500 cf_cv_mbstate_t=yes
17502 echo "$as_me: failed program was:" >&5
17503 cat conftest.$ac_ext >&5
17504 cf_cv_mbstate_t=unknown
17506 rm -f conftest.$ac_objext conftest.$ac_ext
17508 rm -f conftest.$ac_objext conftest.$ac_ext
17510 echo "$as_me:17510: result: $cf_cv_mbstate_t" >&5
17511 echo "${ECHO_T}$cf_cv_mbstate_t" >&6
17513 if test "$cf_cv_mbstate_t" = yes ; then
17515 cat >>confdefs.h <<\EOF
17516 #define NEED_WCHAR_H 1
17522 # if we do not find mbstate_t in either place, use substitution to provide a fallback.
17523 if test "$cf_cv_mbstate_t" = unknown ; then
17524 NCURSES_MBSTATE_T=1
17527 # if we find mbstate_t in either place, use substitution to provide a fallback.
17528 if test "$cf_cv_mbstate_t" != unknown ; then
17529 NCURSES_OK_MBSTATE_T=1
17532 # This is needed on Tru64 5.0 to declare wchar_t
17533 echo "$as_me:17533: checking if we must include wchar.h to declare wchar_t" >&5
17534 echo $ECHO_N "checking if we must include wchar.h to declare wchar_t... $ECHO_C" >&6
17535 if test "${cf_cv_wchar_t+set}" = set; then
17536 echo $ECHO_N "(cached) $ECHO_C" >&6
17539 cat >conftest.$ac_ext <<_ACEOF
17540 #line 17540 "configure"
17541 #include "confdefs.h"
17543 #include <stdlib.h>
17544 #include <stdarg.h>
17546 #ifdef HAVE_LIBUTF8_H
17547 #include <libutf8.h>
17557 rm -f conftest.$ac_objext
17558 if { (eval echo "$as_me:17558: \"$ac_compile\"") >&5
17559 (eval $ac_compile) 2>&5
17561 echo "$as_me:17561: \$? = $ac_status" >&5
17562 (exit $ac_status); } &&
17563 { ac_try='test -s conftest.$ac_objext'
17564 { (eval echo "$as_me:17564: \"$ac_try\"") >&5
17565 (eval $ac_try) 2>&5
17567 echo "$as_me:17567: \$? = $ac_status" >&5
17568 (exit $ac_status); }; }; then
17571 echo "$as_me: failed program was:" >&5
17572 cat conftest.$ac_ext >&5
17573 cat >conftest.$ac_ext <<_ACEOF
17574 #line 17574 "configure"
17575 #include "confdefs.h"
17577 #include <stdlib.h>
17578 #include <stdarg.h>
17581 #ifdef HAVE_LIBUTF8_H
17582 #include <libutf8.h>
17592 rm -f conftest.$ac_objext
17593 if { (eval echo "$as_me:17593: \"$ac_compile\"") >&5
17594 (eval $ac_compile) 2>&5
17596 echo "$as_me:17596: \$? = $ac_status" >&5
17597 (exit $ac_status); } &&
17598 { ac_try='test -s conftest.$ac_objext'
17599 { (eval echo "$as_me:17599: \"$ac_try\"") >&5
17600 (eval $ac_try) 2>&5
17602 echo "$as_me:17602: \$? = $ac_status" >&5
17603 (exit $ac_status); }; }; then
17606 echo "$as_me: failed program was:" >&5
17607 cat conftest.$ac_ext >&5
17608 cf_cv_wchar_t=unknown
17610 rm -f conftest.$ac_objext conftest.$ac_ext
17612 rm -f conftest.$ac_objext conftest.$ac_ext
17614 echo "$as_me:17614: result: $cf_cv_wchar_t" >&5
17615 echo "${ECHO_T}$cf_cv_wchar_t" >&6
17617 if test "$cf_cv_wchar_t" = yes ; then
17619 cat >>confdefs.h <<\EOF
17620 #define NEED_WCHAR_H 1
17626 # if we do not find wchar_t in either place, use substitution to provide a fallback.
17627 if test "$cf_cv_wchar_t" = unknown ; then
17631 # if we find wchar_t in either place, use substitution to provide a fallback.
17632 if test "$cf_cv_wchar_t" != unknown ; then
17633 NCURSES_OK_WCHAR_T=1
17636 # This is needed on Tru64 5.0 to declare wint_t
17637 echo "$as_me:17637: checking if we must include wchar.h to declare wint_t" >&5
17638 echo $ECHO_N "checking if we must include wchar.h to declare wint_t... $ECHO_C" >&6
17639 if test "${cf_cv_wint_t+set}" = set; then
17640 echo $ECHO_N "(cached) $ECHO_C" >&6
17643 cat >conftest.$ac_ext <<_ACEOF
17644 #line 17644 "configure"
17645 #include "confdefs.h"
17647 #include <stdlib.h>
17648 #include <stdarg.h>
17650 #ifdef HAVE_LIBUTF8_H
17651 #include <libutf8.h>
17661 rm -f conftest.$ac_objext
17662 if { (eval echo "$as_me:17662: \"$ac_compile\"") >&5
17663 (eval $ac_compile) 2>&5
17665 echo "$as_me:17665: \$? = $ac_status" >&5
17666 (exit $ac_status); } &&
17667 { ac_try='test -s conftest.$ac_objext'
17668 { (eval echo "$as_me:17668: \"$ac_try\"") >&5
17669 (eval $ac_try) 2>&5
17671 echo "$as_me:17671: \$? = $ac_status" >&5
17672 (exit $ac_status); }; }; then
17675 echo "$as_me: failed program was:" >&5
17676 cat conftest.$ac_ext >&5
17677 cat >conftest.$ac_ext <<_ACEOF
17678 #line 17678 "configure"
17679 #include "confdefs.h"
17681 #include <stdlib.h>
17682 #include <stdarg.h>
17685 #ifdef HAVE_LIBUTF8_H
17686 #include <libutf8.h>
17696 rm -f conftest.$ac_objext
17697 if { (eval echo "$as_me:17697: \"$ac_compile\"") >&5
17698 (eval $ac_compile) 2>&5
17700 echo "$as_me:17700: \$? = $ac_status" >&5
17701 (exit $ac_status); } &&
17702 { ac_try='test -s conftest.$ac_objext'
17703 { (eval echo "$as_me:17703: \"$ac_try\"") >&5
17704 (eval $ac_try) 2>&5
17706 echo "$as_me:17706: \$? = $ac_status" >&5
17707 (exit $ac_status); }; }; then
17710 echo "$as_me: failed program was:" >&5
17711 cat conftest.$ac_ext >&5
17712 cf_cv_wint_t=unknown
17714 rm -f conftest.$ac_objext conftest.$ac_ext
17716 rm -f conftest.$ac_objext conftest.$ac_ext
17718 echo "$as_me:17718: result: $cf_cv_wint_t" >&5
17719 echo "${ECHO_T}$cf_cv_wint_t" >&6
17721 if test "$cf_cv_wint_t" = yes ; then
17723 cat >>confdefs.h <<\EOF
17724 #define NEED_WCHAR_H 1
17730 # if we do not find wint_t in either place, use substitution to provide a fallback.
17731 if test "$cf_cv_wint_t" = unknown ; then
17735 # if we find wint_t in either place, use substitution to provide a fallback.
17736 if test "$cf_cv_wint_t" != unknown ; then
17737 NCURSES_OK_WINT_T=1
17740 if test "$NCURSES_OK_MBSTATE_T" = 0 ; then
17742 echo "$as_me:17742: checking for type mbstate_t in ${cf_cv_ncurses_header:-curses.h}" >&5
17743 echo $ECHO_N "checking for type mbstate_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
17744 cat >conftest.$ac_ext <<_ACEOF
17745 #line 17745 "configure"
17746 #include "confdefs.h"
17748 #ifndef _XOPEN_SOURCE_EXTENDED
17749 #define _XOPEN_SOURCE_EXTENDED
17751 #include <${cf_cv_ncurses_header:-curses.h}>
17762 rm -f conftest.$ac_objext
17763 if { (eval echo "$as_me:17763: \"$ac_compile\"") >&5
17764 (eval $ac_compile) 2>&5
17766 echo "$as_me:17766: \$? = $ac_status" >&5
17767 (exit $ac_status); } &&
17768 { ac_try='test -s conftest.$ac_objext'
17769 { (eval echo "$as_me:17769: \"$ac_try\"") >&5
17770 (eval $ac_try) 2>&5
17772 echo "$as_me:17772: \$? = $ac_status" >&5
17773 (exit $ac_status); }; }; then
17776 echo "$as_me: failed program was:" >&5
17777 cat conftest.$ac_ext >&5
17780 rm -f conftest.$ac_objext conftest.$ac_ext
17781 echo "$as_me:17781: result: $cf_result" >&5
17782 echo "${ECHO_T}$cf_result" >&6
17783 if test $cf_result = yes ; then
17785 cf_result=`echo "have_type_mbstate_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
17787 cat >>confdefs.h <<EOF
17788 #define $cf_result 1
17793 cat >>confdefs.h <<EOF
17794 #define mbstate_t long
17801 if test "$NCURSES_OK_WCHAR_T" = 0 ; then
17803 echo "$as_me:17803: checking for type wchar_t in ${cf_cv_ncurses_header:-curses.h}" >&5
17804 echo $ECHO_N "checking for type wchar_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
17805 cat >conftest.$ac_ext <<_ACEOF
17806 #line 17806 "configure"
17807 #include "confdefs.h"
17809 #ifndef _XOPEN_SOURCE_EXTENDED
17810 #define _XOPEN_SOURCE_EXTENDED
17812 #include <${cf_cv_ncurses_header:-curses.h}>
17823 rm -f conftest.$ac_objext
17824 if { (eval echo "$as_me:17824: \"$ac_compile\"") >&5
17825 (eval $ac_compile) 2>&5
17827 echo "$as_me:17827: \$? = $ac_status" >&5
17828 (exit $ac_status); } &&
17829 { ac_try='test -s conftest.$ac_objext'
17830 { (eval echo "$as_me:17830: \"$ac_try\"") >&5
17831 (eval $ac_try) 2>&5
17833 echo "$as_me:17833: \$? = $ac_status" >&5
17834 (exit $ac_status); }; }; then
17837 echo "$as_me: failed program was:" >&5
17838 cat conftest.$ac_ext >&5
17841 rm -f conftest.$ac_objext conftest.$ac_ext
17842 echo "$as_me:17842: result: $cf_result" >&5
17843 echo "${ECHO_T}$cf_result" >&6
17844 if test $cf_result = yes ; then
17846 cf_result=`echo "have_type_wchar_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
17848 cat >>confdefs.h <<EOF
17849 #define $cf_result 1
17854 cat >>confdefs.h <<EOF
17855 #define wchar_t long
17862 if test "$NCURSES_OK_WINT_T" = 0 ; then
17864 echo "$as_me:17864: checking for type wint_t in ${cf_cv_ncurses_header:-curses.h}" >&5
17865 echo $ECHO_N "checking for type wint_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
17866 cat >conftest.$ac_ext <<_ACEOF
17867 #line 17867 "configure"
17868 #include "confdefs.h"
17870 #ifndef _XOPEN_SOURCE_EXTENDED
17871 #define _XOPEN_SOURCE_EXTENDED
17873 #include <${cf_cv_ncurses_header:-curses.h}>
17884 rm -f conftest.$ac_objext
17885 if { (eval echo "$as_me:17885: \"$ac_compile\"") >&5
17886 (eval $ac_compile) 2>&5
17888 echo "$as_me:17888: \$? = $ac_status" >&5
17889 (exit $ac_status); } &&
17890 { ac_try='test -s conftest.$ac_objext'
17891 { (eval echo "$as_me:17891: \"$ac_try\"") >&5
17892 (eval $ac_try) 2>&5
17894 echo "$as_me:17894: \$? = $ac_status" >&5
17895 (exit $ac_status); }; }; then
17898 echo "$as_me: failed program was:" >&5
17899 cat conftest.$ac_ext >&5
17902 rm -f conftest.$ac_objext conftest.$ac_ext
17903 echo "$as_me:17903: result: $cf_result" >&5
17904 echo "${ECHO_T}$cf_result" >&6
17905 if test $cf_result = yes ; then
17907 cf_result=`echo "have_type_wint_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
17909 cat >>confdefs.h <<EOF
17910 #define $cf_result 1
17915 cat >>confdefs.h <<EOF
17916 #define wint_t long
17931 echo "$as_me:17931: checking for data $cf_data declaration in ${cf_cv_ncurses_header:-curses.h}" >&5
17932 echo $ECHO_N "checking for data $cf_data declaration in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
17934 cat >conftest.$ac_ext <<_ACEOF
17935 #line 17935 "configure"
17936 #include "confdefs.h"
17938 #ifdef HAVE_XCURSES
17939 #include <xcurses.h>
17940 char * XCursesProgramName = "test";
17942 #include <${cf_cv_ncurses_header:-curses.h}>
17943 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
17944 #include <ncursesw/term.h>
17945 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
17946 #include <ncurses/term.h>
17947 #elif defined(HAVE_TERM_H)
17956 void *foo = &($cf_data)
17962 rm -f conftest.$ac_objext
17963 if { (eval echo "$as_me:17963: \"$ac_compile\"") >&5
17964 (eval $ac_compile) 2>&5
17966 echo "$as_me:17966: \$? = $ac_status" >&5
17967 (exit $ac_status); } &&
17968 { ac_try='test -s conftest.$ac_objext'
17969 { (eval echo "$as_me:17969: \"$ac_try\"") >&5
17970 (eval $ac_try) 2>&5
17972 echo "$as_me:17972: \$? = $ac_status" >&5
17973 (exit $ac_status); }; }; then
17977 echo "$as_me: failed program was:" >&5
17978 cat conftest.$ac_ext >&5
17981 rm -f conftest.$ac_objext conftest.$ac_ext
17982 echo "$as_me:17982: result: $cf_result" >&5
17983 echo "${ECHO_T}$cf_result" >&6
17985 if test $cf_result = yes ; then
17987 cf_result=`echo "have_curses_data_$cf_data" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
17989 cat >>confdefs.h <<EOF
17990 #define $cf_result 1
17994 echo "$as_me:17994: checking for data $cf_data in library" >&5
17995 echo $ECHO_N "checking for data $cf_data in library... $ECHO_C" >&6
17996 # BSD linkers insist on making weak linkage, but resolve at runtime.
17997 if test "$cross_compiling" = yes; then
18000 cat >conftest.$ac_ext <<_ACEOF
18001 #line 18001 "configure"
18002 #include "confdefs.h"
18004 #ifdef HAVE_XCURSES
18005 #include <xcurses.h>
18006 char * XCursesProgramName = "test";
18008 #include <${cf_cv_ncurses_header:-curses.h}>
18009 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
18010 #include <ncursesw/term.h>
18011 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
18012 #include <ncurses/term.h>
18013 #elif defined(HAVE_TERM_H)
18018 extern char $cf_data;
18024 void *foo = &($cf_data);
18025 fprintf(stderr, "testing linkage of $cf_data:%p\n", (void *)foo);
18026 ${cf_cv_main_return:-return}(foo == 0);
18033 rm -f conftest.$ac_objext conftest$ac_exeext
18034 if { (eval echo "$as_me:18034: \"$ac_link\"") >&5
18035 (eval $ac_link) 2>&5
18037 echo "$as_me:18037: \$? = $ac_status" >&5
18038 (exit $ac_status); } &&
18039 { ac_try='test -s conftest$ac_exeext'
18040 { (eval echo "$as_me:18040: \"$ac_try\"") >&5
18041 (eval $ac_try) 2>&5
18043 echo "$as_me:18043: \$? = $ac_status" >&5
18044 (exit $ac_status); }; }; then
18047 echo "$as_me: failed program was:" >&5
18048 cat conftest.$ac_ext >&5
18051 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18054 cat >conftest.$ac_ext <<_ACEOF
18055 #line 18055 "configure"
18056 #include "confdefs.h"
18058 #ifdef HAVE_XCURSES
18059 #include <xcurses.h>
18060 char * XCursesProgramName = "test";
18062 #include <${cf_cv_ncurses_header:-curses.h}>
18063 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
18064 #include <ncursesw/term.h>
18065 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
18066 #include <ncurses/term.h>
18067 #elif defined(HAVE_TERM_H)
18072 extern char $cf_data;
18075 void *foo = &($cf_data);
18076 fprintf(stderr, "testing linkage of $cf_data:%p\n", (void *)foo);
18077 ${cf_cv_main_return:-return}(foo == 0);
18080 rm -f conftest$ac_exeext
18081 if { (eval echo "$as_me:18081: \"$ac_link\"") >&5
18082 (eval $ac_link) 2>&5
18084 echo "$as_me:18084: \$? = $ac_status" >&5
18085 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18086 { (eval echo "$as_me:18086: \"$ac_try\"") >&5
18087 (eval $ac_try) 2>&5
18089 echo "$as_me:18089: \$? = $ac_status" >&5
18090 (exit $ac_status); }; }; then
18094 echo "$as_me: program exited with status $ac_status" >&5
18095 echo "$as_me: failed program was:" >&5
18096 cat conftest.$ac_ext >&5
18099 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18101 echo "$as_me:18101: result: $cf_result" >&5
18102 echo "${ECHO_T}$cf_result" >&6
18103 if test $cf_result = yes ; then
18105 cf_result=`echo "decl_curses_data_$cf_data" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
18107 cat >>confdefs.h <<EOF
18108 #define $cf_result 1
18111 # do not exit loop here, since we prefer system's declarations
18116 if ( test "$GCC" = yes || test "$GXX" = yes )
18118 echo "$as_me:18118: checking if you want to turn on gcc warnings" >&5
18119 echo $ECHO_N "checking if you want to turn on gcc warnings... $ECHO_C" >&6
18121 # Check whether --enable-warnings or --disable-warnings was given.
18122 if test "${enable_warnings+set}" = set; then
18123 enableval="$enable_warnings"
18124 test "$enableval" != yes && enableval=no
18125 if test "$enableval" != "no" ; then
18135 echo "$as_me:18135: result: $with_warnings" >&5
18136 echo "${ECHO_T}$with_warnings" >&6
18137 if test "$with_warnings" = "yes"
18140 if test "$GCC" = yes
18142 cat > conftest.i <<EOF
18144 #define GCC_PRINTF 0
18147 #define GCC_SCANF 0
18149 #ifndef GCC_NORETURN
18150 #define GCC_NORETURN /* nothing */
18153 #define GCC_UNUSED /* nothing */
18156 if test "$GCC" = yes
18158 { echo "$as_me:18158: checking for $CC __attribute__ directives..." >&5
18159 echo "$as_me: checking for $CC __attribute__ directives..." >&6;}
18160 cat > conftest.$ac_ext <<EOF
18161 #line 18161 "${as_me:-configure}"
18162 #include "confdefs.h"
18163 #include "conftest.h"
18164 #include "conftest.i"
18166 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
18168 #define GCC_PRINTFLIKE(fmt,var) /*nothing*/
18171 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
18173 #define GCC_SCANFLIKE(fmt,var) /*nothing*/
18175 extern void wow(char *,...) GCC_SCANFLIKE(1,2);
18176 extern void oops(char *,...) GCC_PRINTFLIKE(1,2) GCC_NORETURN;
18177 extern void foo(void) GCC_NORETURN;
18178 int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { return 0; }
18180 cf_printf_attribute=no
18181 cf_scanf_attribute=no
18182 for cf_attribute in scanf printf unused noreturn
18185 cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
18187 cf_directive="__attribute__(($cf_attribute))"
18188 echo "checking for $CC $cf_directive" 1>&5
18190 case $cf_attribute in
18192 cf_printf_attribute=yes
18193 cat >conftest.h <<EOF
18194 #define GCC_$cf_ATTRIBUTE 1
18198 cf_scanf_attribute=yes
18199 cat >conftest.h <<EOF
18200 #define GCC_$cf_ATTRIBUTE 1
18204 cat >conftest.h <<EOF
18205 #define GCC_$cf_ATTRIBUTE $cf_directive
18210 if { (eval echo "$as_me:18210: \"$ac_compile\"") >&5
18211 (eval $ac_compile) 2>&5
18213 echo "$as_me:18213: \$? = $ac_status" >&5
18214 (exit $ac_status); }; then
18215 test -n "$verbose" && echo "$as_me:18215: result: ... $cf_attribute" >&5
18216 echo "${ECHO_T}... $cf_attribute" >&6
18217 cat conftest.h >>confdefs.h
18218 case $cf_attribute in
18221 cat >>confdefs.h <<EOF
18222 #define GCC_NORETURN $cf_directive
18227 cf_value='/* nothing */'
18228 if test "$cf_printf_attribute" != no ; then
18229 cf_value='__attribute__((format(printf,fmt,var)))'
18231 cat >>confdefs.h <<\EOF
18232 #define GCC_PRINTF 1
18237 cat >>confdefs.h <<EOF
18238 #define GCC_PRINTFLIKE(fmt,var) $cf_value
18243 cf_value='/* nothing */'
18244 if test "$cf_scanf_attribute" != no ; then
18245 cf_value='__attribute__((format(scanf,fmt,var)))'
18247 cat >>confdefs.h <<\EOF
18248 #define GCC_SCANF 1
18253 cat >>confdefs.h <<EOF
18254 #define GCC_SCANFLIKE(fmt,var) $cf_value
18260 cat >>confdefs.h <<EOF
18261 #define GCC_UNUSED $cf_directive
18269 fgrep define conftest.i >>confdefs.h
18276 if test "$GCC" = yes ; then
18279 echo "$as_me:18279: checking if this is really Intel C compiler" >&5
18280 echo $ECHO_N "checking if this is really Intel C compiler... $ECHO_C" >&6
18281 cf_save_CFLAGS="$CFLAGS"
18282 CFLAGS="$CFLAGS -no-gcc"
18283 cat >conftest.$ac_ext <<_ACEOF
18284 #line 18284 "configure"
18285 #include "confdefs.h"
18291 #ifdef __INTEL_COMPILER
18300 rm -f conftest.$ac_objext
18301 if { (eval echo "$as_me:18301: \"$ac_compile\"") >&5
18302 (eval $ac_compile) 2>&5
18304 echo "$as_me:18304: \$? = $ac_status" >&5
18305 (exit $ac_status); } &&
18306 { ac_try='test -s conftest.$ac_objext'
18307 { (eval echo "$as_me:18307: \"$ac_try\"") >&5
18308 (eval $ac_try) 2>&5
18310 echo "$as_me:18310: \$? = $ac_status" >&5
18311 (exit $ac_status); }; }; then
18313 cf_save_CFLAGS="$cf_save_CFLAGS -we147"
18316 echo "$as_me: failed program was:" >&5
18317 cat conftest.$ac_ext >&5
18319 rm -f conftest.$ac_objext conftest.$ac_ext
18320 CFLAGS="$cf_save_CFLAGS"
18321 echo "$as_me:18321: result: $INTEL_COMPILER" >&5
18322 echo "${ECHO_T}$INTEL_COMPILER" >&6
18329 if test "$GCC" = yes ; then
18330 echo "$as_me:18330: checking if this is really Clang C compiler" >&5
18331 echo $ECHO_N "checking if this is really Clang C compiler... $ECHO_C" >&6
18332 cf_save_CFLAGS="$CFLAGS"
18333 CFLAGS="$CFLAGS -Qunused-arguments"
18334 cat >conftest.$ac_ext <<_ACEOF
18335 #line 18335 "configure"
18336 #include "confdefs.h"
18351 rm -f conftest.$ac_objext
18352 if { (eval echo "$as_me:18352: \"$ac_compile\"") >&5
18353 (eval $ac_compile) 2>&5
18355 echo "$as_me:18355: \$? = $ac_status" >&5
18356 (exit $ac_status); } &&
18357 { ac_try='test -s conftest.$ac_objext'
18358 { (eval echo "$as_me:18358: \"$ac_try\"") >&5
18359 (eval $ac_try) 2>&5
18361 echo "$as_me:18361: \$? = $ac_status" >&5
18362 (exit $ac_status); }; }; then
18364 cf_save_CFLAGS="$cf_save_CFLAGS -Qunused-arguments"
18367 echo "$as_me: failed program was:" >&5
18368 cat conftest.$ac_ext >&5
18370 rm -f conftest.$ac_objext conftest.$ac_ext
18371 CFLAGS="$cf_save_CFLAGS"
18372 echo "$as_me:18372: result: $CLANG_COMPILER" >&5
18373 echo "${ECHO_T}$CLANG_COMPILER" >&6
18376 cat > conftest.$ac_ext <<EOF
18377 #line 18377 "${as_me:-configure}"
18378 int main(int argc, char *argv[]) { return (argv[argc-1] == 0) ; }
18381 if test "$INTEL_COMPILER" = yes
18383 # The "-wdXXX" options suppress warnings:
18384 # remark #1419: external declaration in primary source file
18385 # remark #1683: explicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem)
18386 # remark #1684: conversion from pointer to same-sized integral type (potential portability problem)
18387 # remark #193: zero used for undefined preprocessing identifier
18388 # remark #593: variable "curs_sb_left_arrow" was set but never used
18389 # remark #810: conversion from "int" to "Dimension={unsigned short}" may lose significant bits
18390 # remark #869: parameter "tw" was never referenced
18391 # remark #981: operands are evaluated in unspecified order
18392 # warning #279: controlling expression is constant
18394 { echo "$as_me:18394: checking for $CC warning options..." >&5
18395 echo "$as_me: checking for $CC warning options..." >&6;}
18396 cf_save_CFLAGS="$CFLAGS"
18397 EXTRA_CFLAGS="-Wall"
18409 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
18410 if { (eval echo "$as_me:18410: \"$ac_compile\"") >&5
18411 (eval $ac_compile) 2>&5
18413 echo "$as_me:18413: \$? = $ac_status" >&5
18414 (exit $ac_status); }; then
18415 test -n "$verbose" && echo "$as_me:18415: result: ... -$cf_opt" >&5
18416 echo "${ECHO_T}... -$cf_opt" >&6
18417 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
18420 CFLAGS="$cf_save_CFLAGS"
18422 elif test "$GCC" = yes
18424 { echo "$as_me:18424: checking for $CC warning options..." >&5
18425 echo "$as_me: checking for $CC warning options..." >&6;}
18426 cf_save_CFLAGS="$CFLAGS"
18429 test "$with_ext_const" = yes && cf_warn_CONST="Wwrite-strings"
18430 cf_gcc_warnings="Wignored-qualifiers Wlogical-op Wvarargs"
18431 test "x$CLANG_COMPILER" = xyes && cf_gcc_warnings=
18432 for cf_opt in W Wall \
18433 Wbad-function-cast \
18436 Wdeclaration-after-statement \
18439 Wmissing-declarations \
18440 Wmissing-prototypes \
18444 Wstrict-prototypes \
18445 Wundef $cf_gcc_warnings $cf_warn_CONST Wno-unknown-pragmas
18447 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
18448 if { (eval echo "$as_me:18448: \"$ac_compile\"") >&5
18449 (eval $ac_compile) 2>&5
18451 echo "$as_me:18451: \$? = $ac_status" >&5
18452 (exit $ac_status); }; then
18453 test -n "$verbose" && echo "$as_me:18453: result: ... -$cf_opt" >&5
18454 echo "${ECHO_T}... -$cf_opt" >&6
18457 CPPFLAGS="$CPPFLAGS -DXTSTRINGDEFINES"
18460 case $GCC_VERSION in
18462 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
18464 echo "${as_me:-configure}:18464: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
18470 case $GCC_VERSION in
18472 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
18474 echo "${as_me:-configure}:18474: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
18480 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
18483 CFLAGS="$cf_save_CFLAGS"
18490 echo "$as_me:18490: checking if you want to use dmalloc for testing" >&5
18491 echo $ECHO_N "checking if you want to use dmalloc for testing... $ECHO_C" >&6
18493 # Check whether --with-dmalloc or --without-dmalloc was given.
18494 if test "${with_dmalloc+set}" = set; then
18495 withval="$with_dmalloc"
18497 cat >>confdefs.h <<EOF
18498 #define USE_DMALLOC 1
18501 : ${with_cflags:=-g}
18502 : ${with_no_leaks:=yes}
18507 echo "$as_me:18507: result: ${with_dmalloc:-no}" >&5
18508 echo "${ECHO_T}${with_dmalloc:-no}" >&6
18510 case .$with_cflags in
18520 cf_new_extra_cppflags=
18522 for cf_add_cflags in -g
18524 case $cf_fix_cppflags in
18526 case $cf_add_cflags in
18527 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
18528 case $cf_add_cflags in
18530 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
18532 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
18533 && test -z "${cf_tst_cflags}" \
18534 && cf_fix_cppflags=yes
18536 if test $cf_fix_cppflags = yes ; then
18538 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
18539 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
18542 elif test "${cf_tst_cflags}" = "\"'" ; then
18544 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
18545 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
18551 case "$CPPFLAGS" in
18555 case $cf_add_cflags in
18557 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
18559 CPPFLAGS=`echo "$CPPFLAGS" | \
18560 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
18561 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
18566 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
18567 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
18574 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
18575 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
18582 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
18583 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
18585 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
18587 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
18588 && test -z "${cf_tst_cflags}" \
18589 && cf_fix_cppflags=no
18594 if test -n "$cf_new_cflags" ; then
18596 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
18597 CFLAGS="${CFLAGS}$cf_new_cflags"
18601 if test -n "$cf_new_cppflags" ; then
18603 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
18604 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
18608 if test -n "$cf_new_extra_cppflags" ; then
18610 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
18611 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
18620 if test "$with_dmalloc" = yes ; then
18621 echo "$as_me:18621: checking for dmalloc.h" >&5
18622 echo $ECHO_N "checking for dmalloc.h... $ECHO_C" >&6
18623 if test "${ac_cv_header_dmalloc_h+set}" = set; then
18624 echo $ECHO_N "(cached) $ECHO_C" >&6
18626 cat >conftest.$ac_ext <<_ACEOF
18627 #line 18627 "configure"
18628 #include "confdefs.h"
18629 #include <dmalloc.h>
18631 if { (eval echo "$as_me:18631: \"$ac_cpp conftest.$ac_ext\"") >&5
18632 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18634 egrep -v '^ *\+' conftest.er1 >conftest.err
18636 cat conftest.err >&5
18637 echo "$as_me:18637: \$? = $ac_status" >&5
18638 (exit $ac_status); } >/dev/null; then
18639 if test -s conftest.err; then
18640 ac_cpp_err=$ac_c_preproc_warn_flag
18647 if test -z "$ac_cpp_err"; then
18648 ac_cv_header_dmalloc_h=yes
18650 echo "$as_me: failed program was:" >&5
18651 cat conftest.$ac_ext >&5
18652 ac_cv_header_dmalloc_h=no
18654 rm -f conftest.err conftest.$ac_ext
18656 echo "$as_me:18656: result: $ac_cv_header_dmalloc_h" >&5
18657 echo "${ECHO_T}$ac_cv_header_dmalloc_h" >&6
18658 if test $ac_cv_header_dmalloc_h = yes; then
18660 echo "$as_me:18660: checking for dmalloc_debug in -ldmalloc" >&5
18661 echo $ECHO_N "checking for dmalloc_debug in -ldmalloc... $ECHO_C" >&6
18662 if test "${ac_cv_lib_dmalloc_dmalloc_debug+set}" = set; then
18663 echo $ECHO_N "(cached) $ECHO_C" >&6
18665 ac_check_lib_save_LIBS=$LIBS
18666 LIBS="-ldmalloc $LIBS"
18667 cat >conftest.$ac_ext <<_ACEOF
18668 #line 18668 "configure"
18669 #include "confdefs.h"
18671 /* Override any gcc2 internal prototype to avoid an error. */
18675 /* We use char because int might match the return type of a gcc2
18676 builtin and then its argument prototype would still apply. */
18677 char dmalloc_debug ();
18686 rm -f conftest.$ac_objext conftest$ac_exeext
18687 if { (eval echo "$as_me:18687: \"$ac_link\"") >&5
18688 (eval $ac_link) 2>&5
18690 echo "$as_me:18690: \$? = $ac_status" >&5
18691 (exit $ac_status); } &&
18692 { ac_try='test -s conftest$ac_exeext'
18693 { (eval echo "$as_me:18693: \"$ac_try\"") >&5
18694 (eval $ac_try) 2>&5
18696 echo "$as_me:18696: \$? = $ac_status" >&5
18697 (exit $ac_status); }; }; then
18698 ac_cv_lib_dmalloc_dmalloc_debug=yes
18700 echo "$as_me: failed program was:" >&5
18701 cat conftest.$ac_ext >&5
18702 ac_cv_lib_dmalloc_dmalloc_debug=no
18704 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18705 LIBS=$ac_check_lib_save_LIBS
18707 echo "$as_me:18707: result: $ac_cv_lib_dmalloc_dmalloc_debug" >&5
18708 echo "${ECHO_T}$ac_cv_lib_dmalloc_dmalloc_debug" >&6
18709 if test $ac_cv_lib_dmalloc_dmalloc_debug = yes; then
18710 cat >>confdefs.h <<EOF
18711 #define HAVE_LIBDMALLOC 1
18714 LIBS="-ldmalloc $LIBS"
18722 echo "$as_me:18722: checking if you want to use dbmalloc for testing" >&5
18723 echo $ECHO_N "checking if you want to use dbmalloc for testing... $ECHO_C" >&6
18725 # Check whether --with-dbmalloc or --without-dbmalloc was given.
18726 if test "${with_dbmalloc+set}" = set; then
18727 withval="$with_dbmalloc"
18729 cat >>confdefs.h <<EOF
18730 #define USE_DBMALLOC 1
18733 : ${with_cflags:=-g}
18734 : ${with_no_leaks:=yes}
18739 echo "$as_me:18739: result: ${with_dbmalloc:-no}" >&5
18740 echo "${ECHO_T}${with_dbmalloc:-no}" >&6
18742 case .$with_cflags in
18752 cf_new_extra_cppflags=
18754 for cf_add_cflags in -g
18756 case $cf_fix_cppflags in
18758 case $cf_add_cflags in
18759 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
18760 case $cf_add_cflags in
18762 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
18764 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
18765 && test -z "${cf_tst_cflags}" \
18766 && cf_fix_cppflags=yes
18768 if test $cf_fix_cppflags = yes ; then
18770 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
18771 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
18774 elif test "${cf_tst_cflags}" = "\"'" ; then
18776 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
18777 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
18783 case "$CPPFLAGS" in
18787 case $cf_add_cflags in
18789 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
18791 CPPFLAGS=`echo "$CPPFLAGS" | \
18792 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
18793 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
18798 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
18799 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
18806 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
18807 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
18814 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
18815 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
18817 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
18819 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
18820 && test -z "${cf_tst_cflags}" \
18821 && cf_fix_cppflags=no
18826 if test -n "$cf_new_cflags" ; then
18828 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
18829 CFLAGS="${CFLAGS}$cf_new_cflags"
18833 if test -n "$cf_new_cppflags" ; then
18835 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
18836 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
18840 if test -n "$cf_new_extra_cppflags" ; then
18842 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
18843 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
18852 if test "$with_dbmalloc" = yes ; then
18853 echo "$as_me:18853: checking for dbmalloc.h" >&5
18854 echo $ECHO_N "checking for dbmalloc.h... $ECHO_C" >&6
18855 if test "${ac_cv_header_dbmalloc_h+set}" = set; then
18856 echo $ECHO_N "(cached) $ECHO_C" >&6
18858 cat >conftest.$ac_ext <<_ACEOF
18859 #line 18859 "configure"
18860 #include "confdefs.h"
18861 #include <dbmalloc.h>
18863 if { (eval echo "$as_me:18863: \"$ac_cpp conftest.$ac_ext\"") >&5
18864 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18866 egrep -v '^ *\+' conftest.er1 >conftest.err
18868 cat conftest.err >&5
18869 echo "$as_me:18869: \$? = $ac_status" >&5
18870 (exit $ac_status); } >/dev/null; then
18871 if test -s conftest.err; then
18872 ac_cpp_err=$ac_c_preproc_warn_flag
18879 if test -z "$ac_cpp_err"; then
18880 ac_cv_header_dbmalloc_h=yes
18882 echo "$as_me: failed program was:" >&5
18883 cat conftest.$ac_ext >&5
18884 ac_cv_header_dbmalloc_h=no
18886 rm -f conftest.err conftest.$ac_ext
18888 echo "$as_me:18888: result: $ac_cv_header_dbmalloc_h" >&5
18889 echo "${ECHO_T}$ac_cv_header_dbmalloc_h" >&6
18890 if test $ac_cv_header_dbmalloc_h = yes; then
18892 echo "$as_me:18892: checking for debug_malloc in -ldbmalloc" >&5
18893 echo $ECHO_N "checking for debug_malloc in -ldbmalloc... $ECHO_C" >&6
18894 if test "${ac_cv_lib_dbmalloc_debug_malloc+set}" = set; then
18895 echo $ECHO_N "(cached) $ECHO_C" >&6
18897 ac_check_lib_save_LIBS=$LIBS
18898 LIBS="-ldbmalloc $LIBS"
18899 cat >conftest.$ac_ext <<_ACEOF
18900 #line 18900 "configure"
18901 #include "confdefs.h"
18903 /* Override any gcc2 internal prototype to avoid an error. */
18907 /* We use char because int might match the return type of a gcc2
18908 builtin and then its argument prototype would still apply. */
18909 char debug_malloc ();
18918 rm -f conftest.$ac_objext conftest$ac_exeext
18919 if { (eval echo "$as_me:18919: \"$ac_link\"") >&5
18920 (eval $ac_link) 2>&5
18922 echo "$as_me:18922: \$? = $ac_status" >&5
18923 (exit $ac_status); } &&
18924 { ac_try='test -s conftest$ac_exeext'
18925 { (eval echo "$as_me:18925: \"$ac_try\"") >&5
18926 (eval $ac_try) 2>&5
18928 echo "$as_me:18928: \$? = $ac_status" >&5
18929 (exit $ac_status); }; }; then
18930 ac_cv_lib_dbmalloc_debug_malloc=yes
18932 echo "$as_me: failed program was:" >&5
18933 cat conftest.$ac_ext >&5
18934 ac_cv_lib_dbmalloc_debug_malloc=no
18936 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18937 LIBS=$ac_check_lib_save_LIBS
18939 echo "$as_me:18939: result: $ac_cv_lib_dbmalloc_debug_malloc" >&5
18940 echo "${ECHO_T}$ac_cv_lib_dbmalloc_debug_malloc" >&6
18941 if test $ac_cv_lib_dbmalloc_debug_malloc = yes; then
18942 cat >>confdefs.h <<EOF
18943 #define HAVE_LIBDBMALLOC 1
18946 LIBS="-ldbmalloc $LIBS"
18954 echo "$as_me:18954: checking if you want to use valgrind for testing" >&5
18955 echo $ECHO_N "checking if you want to use valgrind for testing... $ECHO_C" >&6
18957 # Check whether --with-valgrind or --without-valgrind was given.
18958 if test "${with_valgrind+set}" = set; then
18959 withval="$with_valgrind"
18961 cat >>confdefs.h <<EOF
18962 #define USE_VALGRIND 1
18965 : ${with_cflags:=-g}
18966 : ${with_no_leaks:=yes}
18971 echo "$as_me:18971: result: ${with_valgrind:-no}" >&5
18972 echo "${ECHO_T}${with_valgrind:-no}" >&6
18974 case .$with_cflags in
18984 cf_new_extra_cppflags=
18986 for cf_add_cflags in -g
18988 case $cf_fix_cppflags in
18990 case $cf_add_cflags in
18991 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
18992 case $cf_add_cflags in
18994 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
18996 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
18997 && test -z "${cf_tst_cflags}" \
18998 && cf_fix_cppflags=yes
19000 if test $cf_fix_cppflags = yes ; then
19002 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
19003 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
19006 elif test "${cf_tst_cflags}" = "\"'" ; then
19008 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
19009 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
19015 case "$CPPFLAGS" in
19019 case $cf_add_cflags in
19021 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
19023 CPPFLAGS=`echo "$CPPFLAGS" | \
19024 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
19025 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
19030 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
19031 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
19038 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
19039 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
19046 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
19047 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
19049 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
19051 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
19052 && test -z "${cf_tst_cflags}" \
19053 && cf_fix_cppflags=no
19058 if test -n "$cf_new_cflags" ; then
19060 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
19061 CFLAGS="${CFLAGS}$cf_new_cflags"
19065 if test -n "$cf_new_cppflags" ; then
19067 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
19068 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
19072 if test -n "$cf_new_extra_cppflags" ; then
19074 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
19075 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
19084 echo "$as_me:19084: checking if you want to perform memory-leak testing" >&5
19085 echo $ECHO_N "checking if you want to perform memory-leak testing... $ECHO_C" >&6
19087 # Check whether --enable-leaks or --disable-leaks was given.
19088 if test "${enable_leaks+set}" = set; then
19089 enableval="$enable_leaks"
19090 if test "x$enableval" = xno; then with_no_leaks=yes; else with_no_leaks=no; fi
19092 : ${with_no_leaks:=no}
19094 echo "$as_me:19094: result: $with_no_leaks" >&5
19095 echo "${ECHO_T}$with_no_leaks" >&6
19097 if test "$with_no_leaks" = yes ; then
19099 cat >>confdefs.h <<\EOF
19103 cat >>confdefs.h <<\EOF
19104 #define YY_NO_LEAKS 1
19110 echo "$as_me:19110: checking for an rpath option" >&5
19111 echo $ECHO_N "checking for an rpath option... $ECHO_C" >&6
19112 case $cf_cv_system_name in
19114 if test "$GCC" = yes; then
19115 LD_RPATH_OPT="-Wl,-rpath,"
19117 LD_RPATH_OPT="-rpath "
19120 (linux*|gnu*|k*bsd*-gnu|freebsd*)
19121 LD_RPATH_OPT="-Wl,-rpath,"
19123 (openbsd[2-9].*|mirbsd*)
19124 LD_RPATH_OPT="-Wl,-rpath,"
19127 LD_RPATH_OPT="-rpath "
19130 LD_RPATH_OPT="-Wl,-rpath,"
19133 LD_RPATH_OPT="-rpath "
19141 echo "$as_me:19141: result: $LD_RPATH_OPT" >&5
19142 echo "${ECHO_T}$LD_RPATH_OPT" >&6
19144 case "x$LD_RPATH_OPT" in
19146 echo "$as_me:19146: checking if we need a space after rpath option" >&5
19147 echo $ECHO_N "checking if we need a space after rpath option... $ECHO_C" >&6
19148 cf_save_LIBS="$LIBS"
19150 cf_add_libs="${LD_RPATH_OPT}$libdir"
19151 # Filter out duplicates - this happens with badly-designed ".pc" files...
19152 for cf_add_1lib in $LIBS
19154 for cf_add_2lib in $cf_add_libs
19156 if test "x$cf_add_1lib" = "x$cf_add_2lib"
19162 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
19164 LIBS="$cf_add_libs"
19166 cat >conftest.$ac_ext <<_ACEOF
19167 #line 19167 "configure"
19168 #include "confdefs.h"
19178 rm -f conftest.$ac_objext conftest$ac_exeext
19179 if { (eval echo "$as_me:19179: \"$ac_link\"") >&5
19180 (eval $ac_link) 2>&5
19182 echo "$as_me:19182: \$? = $ac_status" >&5
19183 (exit $ac_status); } &&
19184 { ac_try='test -s conftest$ac_exeext'
19185 { (eval echo "$as_me:19185: \"$ac_try\"") >&5
19186 (eval $ac_try) 2>&5
19188 echo "$as_me:19188: \$? = $ac_status" >&5
19189 (exit $ac_status); }; }; then
19192 echo "$as_me: failed program was:" >&5
19193 cat conftest.$ac_ext >&5
19196 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
19197 LIBS="$cf_save_LIBS"
19198 echo "$as_me:19198: result: $cf_rpath_space" >&5
19199 echo "${ECHO_T}$cf_rpath_space" >&6
19200 test "$cf_rpath_space" = yes && LD_RPATH_OPT="$LD_RPATH_OPT "
19204 echo "$as_me:19204: checking if rpath-hack should be disabled" >&5
19205 echo $ECHO_N "checking if rpath-hack should be disabled... $ECHO_C" >&6
19207 # Check whether --enable-rpath-hack or --disable-rpath-hack was given.
19208 if test "${enable_rpath_hack+set}" = set; then
19209 enableval="$enable_rpath_hack"
19210 test "$enableval" != no && enableval=yes
19211 if test "$enableval" != "yes" ; then
19212 cf_disable_rpath_hack=yes
19214 cf_disable_rpath_hack=no
19218 cf_disable_rpath_hack=no
19221 echo "$as_me:19221: result: $cf_disable_rpath_hack" >&5
19222 echo "${ECHO_T}$cf_disable_rpath_hack" >&6
19223 if test "$cf_disable_rpath_hack" = no ; then
19225 echo "$as_me:19225: checking for updated LDFLAGS" >&5
19226 echo $ECHO_N "checking for updated LDFLAGS... $ECHO_C" >&6
19227 if test -n "$LD_RPATH_OPT" ; then
19228 echo "$as_me:19228: result: maybe" >&5
19229 echo "${ECHO_T}maybe" >&6
19233 # Extract the first word of "$ac_prog", so it can be a program name with args.
19234 set dummy $ac_prog; ac_word=$2
19235 echo "$as_me:19235: checking for $ac_word" >&5
19236 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
19237 if test "${ac_cv_prog_cf_ldd_prog+set}" = set; then
19238 echo $ECHO_N "(cached) $ECHO_C" >&6
19240 if test -n "$cf_ldd_prog"; then
19241 ac_cv_prog_cf_ldd_prog="$cf_ldd_prog" # Let the user override the test.
19243 ac_save_IFS=$IFS; IFS=$ac_path_separator
19245 for ac_dir in $ac_dummy; do
19247 test -z "$ac_dir" && ac_dir=.
19248 $as_executable_p "$ac_dir/$ac_word" || continue
19249 ac_cv_prog_cf_ldd_prog="$ac_prog"
19250 echo "$as_me:19250: found $ac_dir/$ac_word" >&5
19256 cf_ldd_prog=$ac_cv_prog_cf_ldd_prog
19257 if test -n "$cf_ldd_prog"; then
19258 echo "$as_me:19258: result: $cf_ldd_prog" >&5
19259 echo "${ECHO_T}$cf_ldd_prog" >&6
19261 echo "$as_me:19261: result: no" >&5
19262 echo "${ECHO_T}no" >&6
19265 test -n "$cf_ldd_prog" && break
19267 test -n "$cf_ldd_prog" || cf_ldd_prog="no"
19269 cf_rpath_list="/usr/lib /lib"
19270 if test "$cf_ldd_prog" != no
19274 cat >conftest.$ac_ext <<_ACEOF
19275 #line 19275 "configure"
19276 #include "confdefs.h"
19286 rm -f conftest.$ac_objext conftest$ac_exeext
19287 if { (eval echo "$as_me:19287: \"$ac_link\"") >&5
19288 (eval $ac_link) 2>&5
19290 echo "$as_me:19290: \$? = $ac_status" >&5
19291 (exit $ac_status); } &&
19292 { ac_try='test -s conftest$ac_exeext'
19293 { (eval echo "$as_me:19293: \"$ac_try\"") >&5
19294 (eval $ac_try) 2>&5
19296 echo "$as_me:19296: \$? = $ac_status" >&5
19297 (exit $ac_status); }; }; then
19298 cf_rpath_oops=`$cf_ldd_prog conftest$ac_exeext | fgrep ' not found' | sed -e 's% =>.*$%%' |sort | uniq`
19299 cf_rpath_list=`$cf_ldd_prog conftest$ac_exeext | fgrep / | sed -e 's%^.*[ ]/%/%' -e 's%/[^/][^/]*$%%' |sort | uniq`
19301 echo "$as_me: failed program was:" >&5
19302 cat conftest.$ac_ext >&5
19304 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
19306 # If we passed the link-test, but get a "not found" on a given library,
19307 # this could be due to inept reconfiguration of gcc to make it only
19308 # partly honor /usr/local/lib (or whatever). Sometimes this behavior
19309 # is intentional, e.g., installing gcc in /usr/bin and suppressing the
19310 # /usr/local libraries.
19311 if test -n "$cf_rpath_oops"
19313 for cf_rpath_src in $cf_rpath_oops
19315 for cf_rpath_dir in \
19320 if test -f $cf_rpath_dir/lib/$cf_rpath_src
19322 test -n "$verbose" && echo " ...adding -L$cf_rpath_dir/lib to LDFLAGS for $cf_rpath_src" 1>&6
19324 echo "${as_me:-configure}:19324: testing ...adding -L$cf_rpath_dir/lib to LDFLAGS for $cf_rpath_src ..." 1>&5
19326 LDFLAGS="$LDFLAGS -L$cf_rpath_dir/lib"
19334 test -n "$verbose" && echo " ...checking EXTRA_LDFLAGS $EXTRA_LDFLAGS" 1>&6
19336 echo "${as_me:-configure}:19336: testing ...checking EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5
19338 test -n "$verbose" && echo " ...checking LDFLAGS $LDFLAGS" 1>&6
19340 echo "${as_me:-configure}:19340: testing ...checking LDFLAGS $LDFLAGS ..." 1>&5
19343 for cf_rpath_src in $LDFLAGS
19345 case $cf_rpath_src in
19348 # check if this refers to a directory which we will ignore
19350 if test -n "$cf_rpath_list"
19352 for cf_rpath_item in $cf_rpath_list
19354 if test "x$cf_rpath_src" = "x-L$cf_rpath_item"
19362 if test "$cf_rpath_skip" = no
19364 # transform the option
19365 if test "$LD_RPATH_OPT" = "-R " ; then
19366 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%-R %"`
19368 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%$LD_RPATH_OPT%"`
19371 # if we have not already added this, add it now
19372 cf_rpath_tst=`echo "$EXTRA_LDFLAGS" | sed -e "s%$cf_rpath_tmp %%"`
19373 if test "x$cf_rpath_tst" = "x$EXTRA_LDFLAGS"
19375 test -n "$verbose" && echo " ...Filter $cf_rpath_src ->$cf_rpath_tmp" 1>&6
19377 echo "${as_me:-configure}:19377: testing ...Filter $cf_rpath_src ->$cf_rpath_tmp ..." 1>&5
19379 EXTRA_LDFLAGS="$cf_rpath_tmp $EXTRA_LDFLAGS"
19384 cf_rpath_dst="$cf_rpath_dst $cf_rpath_src"
19386 LDFLAGS=$cf_rpath_dst
19388 test -n "$verbose" && echo " ...checked LDFLAGS $LDFLAGS" 1>&6
19390 echo "${as_me:-configure}:19390: testing ...checked LDFLAGS $LDFLAGS ..." 1>&5
19392 test -n "$verbose" && echo " ...checking LIBS $LIBS" 1>&6
19394 echo "${as_me:-configure}:19394: testing ...checking LIBS $LIBS ..." 1>&5
19397 for cf_rpath_src in $LIBS
19399 case $cf_rpath_src in
19402 # check if this refers to a directory which we will ignore
19404 if test -n "$cf_rpath_list"
19406 for cf_rpath_item in $cf_rpath_list
19408 if test "x$cf_rpath_src" = "x-L$cf_rpath_item"
19416 if test "$cf_rpath_skip" = no
19418 # transform the option
19419 if test "$LD_RPATH_OPT" = "-R " ; then
19420 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%-R %"`
19422 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%$LD_RPATH_OPT%"`
19425 # if we have not already added this, add it now
19426 cf_rpath_tst=`echo "$EXTRA_LDFLAGS" | sed -e "s%$cf_rpath_tmp %%"`
19427 if test "x$cf_rpath_tst" = "x$EXTRA_LDFLAGS"
19429 test -n "$verbose" && echo " ...Filter $cf_rpath_src ->$cf_rpath_tmp" 1>&6
19431 echo "${as_me:-configure}:19431: testing ...Filter $cf_rpath_src ->$cf_rpath_tmp ..." 1>&5
19433 EXTRA_LDFLAGS="$cf_rpath_tmp $EXTRA_LDFLAGS"
19438 cf_rpath_dst="$cf_rpath_dst $cf_rpath_src"
19442 test -n "$verbose" && echo " ...checked LIBS $LIBS" 1>&6
19444 echo "${as_me:-configure}:19444: testing ...checked LIBS $LIBS ..." 1>&5
19446 test -n "$verbose" && echo " ...checked EXTRA_LDFLAGS $EXTRA_LDFLAGS" 1>&6
19448 echo "${as_me:-configure}:19448: testing ...checked EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5
19451 echo "$as_me:19451: result: no" >&5
19452 echo "${ECHO_T}no" >&6
19460 ac_config_files="$ac_config_files Makefile"
19461 ac_config_commands="$ac_config_commands default"
19462 cat >confcache <<\_ACEOF
19463 # This file is a shell script that caches the results of configure
19464 # tests run on this system so they can be shared between configure
19465 # scripts and configure runs, see configure's option --config-cache.
19466 # It is not useful on other systems. If it contains results you don't
19467 # want to keep, you may remove or edit it.
19469 # config.status only pays attention to the cache file if you give it
19470 # the --recheck option to rerun configure.
19472 # `ac_cv_env_foo' variables (set or unset) will be overriden when
19473 # loading this file, other *unset* `ac_cv_foo' will be assigned the
19474 # following values.
19478 # The following way of writing the cache mishandles newlines in values,
19479 # but we know of no workaround that is simple, portable, and efficient.
19480 # So, don't put newlines in cache variables' values.
19481 # Ultrix sh set writes to stderr and can't be redirected directly,
19482 # and sets the high bit in the cache file unless we assign to the vars.
19485 case `(ac_space=' '; set | grep ac_space) 2>&1` in
19487 # `set' does not quote correctly, so add quotes (double-quote
19488 # substitution turns \\\\ into \\, and sed turns \\ into \).
19491 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
19494 # `set' quotes correctly as required by POSIX, so do not add quotes.
19496 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
19503 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
19505 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
19507 if cmp -s $cache_file confcache; then :; else
19508 if test -w $cache_file; then
19509 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
19510 cat confcache >$cache_file
19512 echo "not updating unwritable cache $cache_file"
19517 test "x$prefix" = xNONE && prefix=$ac_default_prefix
19518 # Let make expand exec_prefix.
19519 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
19521 # VPATH may cause trouble with some makes, so we remove $(srcdir),
19522 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
19523 # trailing colons and then remove the whole line if VPATH becomes empty
19524 # (actually we leave an empty line to preserve line numbers).
19525 if test "x$srcdir" = x.; then
19526 ac_vpsub='/^[ ]*VPATH[ ]*=/{
19527 s/:*\$(srcdir):*/:/;
19528 s/:*\${srcdir}:*/:/;
19530 s/^\([^=]*=[ ]*\):*/\1/;
19536 DEFS=-DHAVE_CONFIG_H
19538 : ${CONFIG_STATUS=./config.status}
19539 ac_clean_files_save=$ac_clean_files
19540 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
19541 { echo "$as_me:19541: creating $CONFIG_STATUS" >&5
19542 echo "$as_me: creating $CONFIG_STATUS" >&6;}
19543 cat >$CONFIG_STATUS <<_ACEOF
19545 # Generated automatically by configure.
19546 # Run this file to recreate the current configuration.
19547 # Compiler output produced by configure, useful for debugging
19548 # configure, is in config.log if it exists.
19551 SHELL=\${CONFIG_SHELL-$SHELL}
19552 ac_cs_invocation="\$0 \$@"
19556 cat >>$CONFIG_STATUS <<\_ACEOF
19557 # Be Bourne compatible
19558 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
19561 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
19565 # Name of the executable.
19566 as_me=`echo "$0" |sed 's,.*[\\/],,'`
19568 if expr a : '\(a\)' >/dev/null 2>&1; then
19574 rm -f conf$$ conf$$.exe conf$$.file
19576 if ln -s conf$$.file conf$$ 2>/dev/null; then
19577 # We could just check for DJGPP; but this test a) works b) is more generic
19578 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
19579 if test -f conf$$.exe; then
19580 # Don't use ln at all; we don't have any links
19585 elif ln conf$$.file conf$$ 2>/dev/null; then
19590 rm -f conf$$ conf$$.exe conf$$.file
19592 as_executable_p="test -f"
19594 # Support unset when possible.
19595 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
19602 $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
19603 $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
19604 $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
19605 $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
19606 $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
19607 $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
19608 $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
19609 $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
19612 # We need space, tab and new line, in precisely that order.
19618 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
19624 # Files that config.status was made for.
19625 if test -n "$ac_config_files"; then
19626 echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
19629 if test -n "$ac_config_headers"; then
19630 echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
19633 if test -n "$ac_config_links"; then
19634 echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
19637 if test -n "$ac_config_commands"; then
19638 echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
19641 cat >>$CONFIG_STATUS <<\EOF
19644 \`$as_me' instantiates files from templates according to the
19645 current configuration.
19647 Usage: $0 [OPTIONS] [FILE]...
19649 -h, --help print this help, then exit
19650 -V, --version print version number, then exit
19651 -d, --debug don't remove temporary files
19652 --recheck update $as_me by reconfiguring in the same conditions
19653 --file=FILE[:TEMPLATE]
19654 instantiate the configuration file FILE
19655 --header=FILE[:TEMPLATE]
19656 instantiate the configuration header FILE
19658 Configuration files:
19661 Configuration headers:
19664 Configuration commands:
19667 Report bugs to <dickey@invisible-island.net>."
19670 cat >>$CONFIG_STATUS <<EOF
19673 configured by $0, generated by GNU Autoconf 2.52.20170501,
19674 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
19676 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
19677 Free Software Foundation, Inc.
19678 This config.status script is free software; the Free Software Foundation
19679 gives unlimited permission to copy, distribute and modify it."
19684 cat >>$CONFIG_STATUS <<\EOF
19685 # If no file are specified by the user, then we need to provide default
19686 # value. By we need to know if files were specified by the user.
19692 ac_option=`expr "x$1" : 'x\([^=]*\)='`
19693 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
19695 set dummy "$ac_option" "$ac_optarg" ${1+"$@"}
19699 *) # This is not an option, so the user has probably given explicit
19701 ac_need_defaults=false;;
19705 # Handling of the options.
19707 cat >>$CONFIG_STATUS <<EOF
19708 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
19709 echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion"
19710 exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;;
19712 cat >>$CONFIG_STATUS <<\EOF
19713 --version | --vers* | -V )
19714 echo "$ac_cs_version"; exit 0 ;;
19716 # Conflict between --help and --header
19717 { { echo "$as_me:19717: error: ambiguous option: $1
19718 Try \`$0 --help' for more information." >&5
19719 echo "$as_me: error: ambiguous option: $1
19720 Try \`$0 --help' for more information." >&2;}
19721 { (exit 1); exit 1; }; };;
19722 --help | --hel | -h )
19723 echo "$ac_cs_usage"; exit 0 ;;
19724 --debug | --d* | -d )
19726 --file | --fil | --fi | --f )
19728 CONFIG_FILES="$CONFIG_FILES $1"
19729 ac_need_defaults=false;;
19730 --header | --heade | --head | --hea )
19732 CONFIG_HEADERS="$CONFIG_HEADERS $1"
19733 ac_need_defaults=false;;
19735 # This is an error.
19736 -*) { { echo "$as_me:19736: error: unrecognized option: $1
19737 Try \`$0 --help' for more information." >&5
19738 echo "$as_me: error: unrecognized option: $1
19739 Try \`$0 --help' for more information." >&2;}
19740 { (exit 1); exit 1; }; } ;;
19742 *) ac_config_targets="$ac_config_targets $1" ;;
19751 ## ----------------------- ##
19752 ## Running config.status. ##
19753 ## ----------------------- ##
19755 This file was extended by $as_me 2.52.20170501, executed with
19756 CONFIG_FILES = $CONFIG_FILES
19757 CONFIG_HEADERS = $CONFIG_HEADERS
19758 CONFIG_LINKS = $CONFIG_LINKS
19759 CONFIG_COMMANDS = $CONFIG_COMMANDS
19760 > $ac_cs_invocation
19761 on `(hostname || uname -n) 2>/dev/null | sed 1q`
19766 cat >>$CONFIG_STATUS <<EOF
19768 # INIT-COMMANDS section.
19778 cat >>$CONFIG_STATUS <<\EOF
19779 for ac_config_target in $ac_config_targets
19781 case "$ac_config_target" in
19782 # Handling of arguments.
19783 "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
19784 "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
19785 "ncurses_cfg.h" ) CONFIG_HEADERS="$CONFIG_HEADERS ncurses_cfg.h:ncurses_tst.hin" ;;
19786 *) { { echo "$as_me:19786: error: invalid argument: $ac_config_target" >&5
19787 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
19788 { (exit 1); exit 1; }; };;
19792 # If the user did not use the arguments to specify the items to instantiate,
19793 # then the envvar interface is used. Set only those that are not.
19794 # We use the long form for the default assignment because of an extremely
19795 # bizarre bug on SunOS 4.1.3.
19796 if $ac_need_defaults; then
19797 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
19798 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
19799 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
19802 # Create a temporary directory, and hook for its removal unless debugging.
19805 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
19806 trap '{ (exit 1); exit 1; }' 1 2 13 15
19809 # Create a (secure) tmp directory for tmp files.
19812 tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` &&
19813 test -n "$tmp" && test -d "$tmp"
19816 tmp=$TMPDIR/cs$$-$RANDOM
19817 (umask 077 && mkdir $tmp)
19820 echo "$me: cannot create a temporary directory in $TMPDIR" >&2
19821 { (exit 1); exit 1; }
19826 cat >>$CONFIG_STATUS <<EOF
19829 # CONFIG_FILES section.
19832 # No need to generate the scripts if there are no CONFIG_FILES.
19833 # This happens for instance when ./config.status config.h
19834 if test -n "\$CONFIG_FILES"; then
19835 # Protect against being on the right side of a sed subst in config.status.
19836 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
19837 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
19838 s,@SHELL@,$SHELL,;t t
19839 s,@exec_prefix@,$exec_prefix,;t t
19840 s,@prefix@,$prefix,;t t
19841 s,@program_transform_name@,$program_transform_name,;t t
19842 s,@bindir@,$bindir,;t t
19843 s,@sbindir@,$sbindir,;t t
19844 s,@libexecdir@,$libexecdir,;t t
19845 s,@datarootdir@,$datarootdir,;t t
19846 s,@datadir@,$datadir,;t t
19847 s,@sysconfdir@,$sysconfdir,;t t
19848 s,@sharedstatedir@,$sharedstatedir,;t t
19849 s,@localstatedir@,$localstatedir,;t t
19850 s,@libdir@,$libdir,;t t
19851 s,@includedir@,$includedir,;t t
19852 s,@oldincludedir@,$oldincludedir,;t t
19853 s,@infodir@,$infodir,;t t
19854 s,@mandir@,$mandir,;t t
19855 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
19856 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
19857 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
19858 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
19859 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
19860 s,@build_alias@,$build_alias,;t t
19861 s,@host_alias@,$host_alias,;t t
19862 s,@target_alias@,$target_alias,;t t
19863 s,@ECHO_C@,$ECHO_C,;t t
19864 s,@ECHO_N@,$ECHO_N,;t t
19865 s,@ECHO_T@,$ECHO_T,;t t
19866 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
19867 s,@DEFS@,$DEFS,;t t
19868 s,@LIBS@,$LIBS,;t t
19869 s,@build@,$build,;t t
19870 s,@build_cpu@,$build_cpu,;t t
19871 s,@build_vendor@,$build_vendor,;t t
19872 s,@build_os@,$build_os,;t t
19873 s,@host@,$host,;t t
19874 s,@host_cpu@,$host_cpu,;t t
19875 s,@host_vendor@,$host_vendor,;t t
19876 s,@host_os@,$host_os,;t t
19877 s,@SET_MAKE@,$SET_MAKE,;t t
19879 s,@CFLAGS@,$CFLAGS,;t t
19880 s,@LDFLAGS@,$LDFLAGS,;t t
19881 s,@CPPFLAGS@,$CPPFLAGS,;t t
19882 s,@ac_ct_CC@,$ac_ct_CC,;t t
19883 s,@EXEEXT@,$EXEEXT,;t t
19884 s,@OBJEXT@,$OBJEXT,;t t
19885 s,@EXTRA_CPPFLAGS@,$EXTRA_CPPFLAGS,;t t
19888 s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
19889 s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
19890 s,@INSTALL_DATA@,$INSTALL_DATA,;t t
19891 s,@LINT@,$LINT,;t t
19892 s,@LINT_OPTS@,$LINT_OPTS,;t t
19893 s,@CTAGS@,$CTAGS,;t t
19894 s,@ETAGS@,$ETAGS,;t t
19895 s,@MAKE_LOWER_TAGS@,$MAKE_LOWER_TAGS,;t t
19896 s,@MAKE_UPPER_TAGS@,$MAKE_UPPER_TAGS,;t t
19897 s,@MATH_LIB@,$MATH_LIB,;t t
19898 s,@top_builddir@,$top_builddir,;t t
19899 s,@CC_G_OPT@,$CC_G_OPT,;t t
19900 s,@CC_SHARED_OPTS@,$CC_SHARED_OPTS,;t t
19901 s,@DFT_DEP_SUFFIX@,$DFT_DEP_SUFFIX,;t t
19902 s,@DFT_OBJ_SUBDIR@,$DFT_OBJ_SUBDIR,;t t
19903 s,@DFT_UPR_MODEL@,$DFT_UPR_MODEL,;t t
19905 s,@LDFLAGS_SHARED@,$LDFLAGS_SHARED,;t t
19906 s,@LDFLAGS_STATIC@,$LDFLAGS_STATIC,;t t
19907 s,@LD_MODEL@,$LD_MODEL,;t t
19908 s,@LD_SHARED_OPTS@,$LD_SHARED_OPTS,;t t
19909 s,@LIBTOOL@,$LIBTOOL,;t t
19910 s,@LIBTOOL_OPTS@,$LIBTOOL_OPTS,;t t
19911 s,@LIB_CLEAN@,$LIB_CLEAN,;t t
19912 s,@LIB_COMPILE@,$LIB_COMPILE,;t t
19913 s,@LIB_LINK@,$LIB_LINK,;t t
19914 s,@LINK_TESTS@,$LINK_TESTS,;t t
19915 s,@LOCAL_LDFLAGS@,$LOCAL_LDFLAGS,;t t
19916 s,@PACKAGE@,$PACKAGE,;t t
19917 s,@PTHREAD@,$PTHREAD,;t t
19918 s,@TEST_ARGS@,$TEST_ARGS,;t t
19919 s,@TEST_DEPS@,$TEST_DEPS,;t t
19920 s,@TEST_LIBS@,$TEST_LIBS,;t t
19921 s,@TINFO_LDFLAGS@,$TINFO_LDFLAGS,;t t
19922 s,@TINFO_LIBS@,$TINFO_LIBS,;t t
19923 s,@cf_cv_abi_version@,$cf_cv_abi_version,;t t
19924 s,@cf_cv_rel_version@,$cf_cv_rel_version,;t t
19925 s,@includesubdir@,$includesubdir,;t t
19926 s,@PKG_CONFIG@,$PKG_CONFIG,;t t
19927 s,@ac_pt_PKG_CONFIG@,$ac_pt_PKG_CONFIG,;t t
19928 s,@ECHO_LT@,$ECHO_LT,;t t
19929 s,@ECHO_LD@,$ECHO_LD,;t t
19930 s,@RULE_CC@,$RULE_CC,;t t
19931 s,@SHOW_CC@,$SHOW_CC,;t t
19932 s,@ECHO_CC@,$ECHO_CC,;t t
19933 s,@NCURSES_WRAP_PREFIX@,$NCURSES_WRAP_PREFIX,;t t
19934 s,@NCURSES_CONFIG@,$NCURSES_CONFIG,;t t
19935 s,@ac_ct_NCURSES_CONFIG@,$ac_ct_NCURSES_CONFIG,;t t
19936 s,@X_CFLAGS@,$X_CFLAGS,;t t
19937 s,@X_PRE_LIBS@,$X_PRE_LIBS,;t t
19938 s,@X_LIBS@,$X_LIBS,;t t
19939 s,@X_EXTRA_LIBS@,$X_EXTRA_LIBS,;t t
19940 s,@XCURSES_CONFIG@,$XCURSES_CONFIG,;t t
19941 s,@ac_ct_XCURSES_CONFIG@,$ac_ct_XCURSES_CONFIG,;t t
19942 s,@RGB_PATH@,$RGB_PATH,;t t
19943 s,@no_x11_rgb@,$no_x11_rgb,;t t
19944 s,@EXTRA_CFLAGS@,$EXTRA_CFLAGS,;t t
19945 s,@cf_ldd_prog@,$cf_ldd_prog,;t t
19946 s,@EXTRA_LDFLAGS@,$EXTRA_LDFLAGS,;t t
19951 cat >>$CONFIG_STATUS <<\EOF
19952 # Split the substitutions into bite-sized pieces for seds with
19953 # small command number limits, like on Digital OSF/1 and HP-UX.
19954 ac_max_sed_lines=48
19955 ac_sed_frag=1 # Number of current file.
19956 ac_beg=1 # First line for current file.
19957 ac_end=$ac_max_sed_lines # Line after last line for current file.
19960 while $ac_more_lines; do
19961 if test $ac_beg -gt 1; then
19962 sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
19964 sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
19966 if test ! -s $tmp/subs.frag; then
19967 ac_more_lines=false
19969 # The purpose of the label and of the branching condition is to
19970 # speed up the sed processing (if there are no `@' at all, there
19971 # is no need to browse any of the substitutions).
19972 # These are the two extra sed commands mentioned above.
19974 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
19975 # It is possible to make a multiline substitution using escaped newlines.
19976 # Ensure that we do not split the substitution between script fragments.
19978 ac_END=`expr $ac_end + $ac_max_sed_lines`
19979 sed "1,${ac_BEG}d; ${ac_END}p; q" $tmp/subs.sed >$tmp/subs.next
19980 if test -s $tmp/subs.next; then
19981 grep '^s,@[^@,][^@,]*@,.*\\$' $tmp/subs.next >$tmp/subs.edit
19982 if test ! -s $tmp/subs.edit; then
19983 grep "^s,@[^@,][^@,]*@,.*,;t t$" $tmp/subs.next >$tmp/subs.edit
19984 if test ! -s $tmp/subs.edit; then
19985 if test $ac_beg -gt 1; then
19986 ac_end=`expr $ac_end - 1`
19993 if test -z "$ac_sed_cmds"; then
19994 ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
19996 ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
19998 ac_sed_frag=`expr $ac_sed_frag + 1`
20000 ac_end=`expr $ac_end + $ac_max_sed_lines`
20003 if test -z "$ac_sed_cmds"; then
20006 fi # test -n "$CONFIG_FILES"
20009 cat >>$CONFIG_STATUS <<\EOF
20010 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
20011 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
20013 - | *:- | *:-:* ) # input from stdin
20015 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
20016 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
20017 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
20018 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
20019 * ) ac_file_in=$ac_file.in ;;
20022 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
20023 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
20024 X"$ac_file" : 'X\(//\)[^/]' \| \
20025 X"$ac_file" : 'X\(//\)$' \| \
20026 X"$ac_file" : 'X\(/\)' \| \
20027 . : '\(.\)' 2>/dev/null ||
20029 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
20030 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
20031 /^X\(\/\/\)$/{ s//\1/; q; }
20032 /^X\(\/\).*/{ s//\1/; q; }
20034 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
20035 { case "$ac_dir" in
20036 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
20040 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
20041 case $as_mkdir_dir in
20042 # Skip DOS drivespec
20043 ?:) as_incr_dir=$as_mkdir_dir ;;
20045 as_incr_dir=$as_incr_dir/$as_mkdir_dir
20046 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
20051 ac_dir_suffix="/`echo $ac_dir|sed 's,^\./,,'`"
20052 # A "../" for each directory in $ac_dir_suffix.
20053 ac_dots=`echo "$ac_dir_suffix" | sed 's,/[^/]*,../,g'`
20055 ac_dir_suffix= ac_dots=
20060 if test -z "$ac_dots"; then
20063 ac_top_srcdir=`echo $ac_dots | sed 's,/$,,'`
20065 [\\/]* | ?:[\\/]* )
20066 ac_srcdir=$srcdir$ac_dir_suffix;
20067 ac_top_srcdir=$srcdir ;;
20068 *) # Relative path.
20069 ac_srcdir=$ac_dots$srcdir$ac_dir_suffix
20070 ac_top_srcdir=$ac_dots$srcdir ;;
20074 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
20075 *) ac_INSTALL=$ac_dots$INSTALL ;;
20078 if test x"$ac_file" != x-; then
20079 { echo "$as_me:20079: creating $ac_file" >&5
20080 echo "$as_me: creating $ac_file" >&6;}
20083 # Let's still pretend it is `configure' which instantiates (i.e., don't
20084 # use $as_me), people would be surprised to read:
20085 # /* config.h. Generated automatically by config.status. */
20086 configure_input="Generated automatically from `echo $ac_file_in |
20087 sed 's,.*/,,'` by configure."
20089 # First look for the input files in the build tree, otherwise in the
20091 ac_file_inputs=`IFS=:
20092 for f in $ac_file_in; do
20094 -) echo $tmp/stdin ;;
20096 # Absolute (can't be DOS-style, as IFS=:)
20097 test -f "$f" || { { echo "$as_me:20097: error: cannot find input file: $f" >&5
20098 echo "$as_me: error: cannot find input file: $f" >&2;}
20099 { (exit 1); exit 1; }; }
20102 if test -f "$f"; then
20105 elif test -f "$srcdir/$f"; then
20110 { { echo "$as_me:20110: error: cannot find input file: $f" >&5
20111 echo "$as_me: error: cannot find input file: $f" >&2;}
20112 { (exit 1); exit 1; }; }
20115 done` || { (exit 1); exit 1; }
20117 cat >>$CONFIG_STATUS <<\EOF
20118 ac_warn_datarootdir=no
20119 if test x"$ac_file" != x-; then
20120 for ac_item in $ac_file_inputs
20122 ac_seen=`grep '@\(datadir\|mandir\|infodir\)@' $ac_item`
20123 if test -n "$ac_seen"; then
20124 ac_used=`grep '@datarootdir@' $ac_item`
20125 if test -z "$ac_used"; then
20126 { echo "$as_me:20126: WARNING: datarootdir was used implicitly but not set:
20128 echo "$as_me: WARNING: datarootdir was used implicitly but not set:
20130 ac_warn_datarootdir=yes
20133 ac_seen=`grep '${datarootdir}' $ac_item`
20134 if test -n "$ac_seen"; then
20135 { echo "$as_me:20135: WARNING: datarootdir was used explicitly but not set:
20137 echo "$as_me: WARNING: datarootdir was used explicitly but not set:
20139 ac_warn_datarootdir=yes
20144 if test "x$ac_warn_datarootdir" = xyes; then
20145 ac_sed_cmds="$ac_sed_cmds | sed -e 's,@datarootdir@,\${prefix}/share,g' -e 's,\${datarootdir},\${prefix}/share,g'"
20149 cat >>$CONFIG_STATUS <<EOF
20153 cat >>$CONFIG_STATUS <<\EOF
20155 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
20156 s,@configure_input@,$configure_input,;t t
20157 s,@srcdir@,$ac_srcdir,;t t
20158 s,@top_srcdir@,$ac_top_srcdir,;t t
20159 s,@INSTALL@,$ac_INSTALL,;t t
20160 " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
20162 if test x"$ac_file" != x-; then
20163 cp $tmp/out $ac_file
20165 for ac_name in prefix exec_prefix datarootdir
20167 ac_seen=`fgrep -n '${'$ac_name'[:=].*}' $ac_file`
20168 if test -n "$ac_seen"; then
20169 ac_init=`egrep '[ ]*'$ac_name'[ ]*=' $ac_file`
20170 if test -z "$ac_init"; then
20171 ac_seen=`echo "$ac_seen" |sed -e 's,^,'$ac_file':,'`
20172 { echo "$as_me:20172: WARNING: Variable $ac_name is used but was not set:
20174 echo "$as_me: WARNING: Variable $ac_name is used but was not set:
20179 egrep -n '@[a-z_][a-z_0-9]+@' $ac_file >$tmp/out
20180 egrep -n '@[A-Z_][A-Z_0-9]+@' $ac_file >>$tmp/out
20181 if test -s $tmp/out; then
20182 ac_seen=`sed -e 's,^,'$ac_file':,' < $tmp/out`
20183 { echo "$as_me:20183: WARNING: Some variables may not be substituted:
20185 echo "$as_me: WARNING: Some variables may not be substituted:
20195 cat >>$CONFIG_STATUS <<\EOF
20198 # CONFIG_HEADER section.
20201 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
20202 # NAME is the cpp macro being defined and VALUE is the value it is being given.
20204 # ac_d sets the value in "#define NAME VALUE" lines.
20205 ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
20206 ac_dB='[ ].*$,\1#\2'
20209 # ac_i turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
20210 ac_iA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
20211 ac_iB='\([ ]\),\1#\2define\3'
20214 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
20215 ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
20216 ac_uB='$,\1#\2define\3'
20220 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
20221 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
20223 - | *:- | *:-:* ) # input from stdin
20225 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
20226 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
20227 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
20228 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
20229 * ) ac_file_in=$ac_file.in ;;
20232 test x"$ac_file" != x- && { echo "$as_me:20232: creating $ac_file" >&5
20233 echo "$as_me: creating $ac_file" >&6;}
20235 # First look for the input files in the build tree, otherwise in the
20237 ac_file_inputs=`IFS=:
20238 for f in $ac_file_in; do
20240 -) echo $tmp/stdin ;;
20242 # Absolute (can't be DOS-style, as IFS=:)
20243 test -f "$f" || { { echo "$as_me:20243: error: cannot find input file: $f" >&5
20244 echo "$as_me: error: cannot find input file: $f" >&2;}
20245 { (exit 1); exit 1; }; }
20248 if test -f "$f"; then
20251 elif test -f "$srcdir/$f"; then
20256 { { echo "$as_me:20256: error: cannot find input file: $f" >&5
20257 echo "$as_me: error: cannot find input file: $f" >&2;}
20258 { (exit 1); exit 1; }; }
20261 done` || { (exit 1); exit 1; }
20262 # Remove the trailing spaces.
20263 sed 's/[ ]*$//' $ac_file_inputs >$tmp/in
20267 # Transform confdefs.h into a list of #define's. We won't use it as a sed
20268 # script, but as data to insert where we see @DEFS@. We expect AC_SAVE_DEFS to
20269 # be either 'cat' or 'sort'.
20270 cat confdefs.h | uniq >conftest.vals
20272 # Break up conftest.vals because some shells have a limit on
20273 # the size of here documents, and old seds have small limits too.
20275 rm -f conftest.tail
20276 echo ' rm -f conftest.frag' >> $CONFIG_STATUS
20277 while grep . conftest.vals >/dev/null
20279 # Write chunks of a limited-size here document to conftest.frag.
20280 echo ' cat >> conftest.frag <<CEOF' >> $CONFIG_STATUS
20281 sed ${ac_max_here_lines}q conftest.vals | sed -e 's/#ifdef.*/#if 0/' >> $CONFIG_STATUS
20282 echo 'CEOF' >> $CONFIG_STATUS
20283 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
20284 rm -f conftest.vals
20285 mv conftest.tail conftest.vals
20287 rm -f conftest.vals
20289 # Run sed to substitute the contents of conftest.frag into $tmp/in at the
20291 echo ' cat >> conftest.edit <<CEOF
20292 /@DEFS@/r conftest.frag
20295 sed -f conftest.edit $tmp/in > $tmp/out
20297 mv $tmp/out $tmp/in
20298 rm -f conftest.edit conftest.frag
20299 ' >> $CONFIG_STATUS
20301 cat >>$CONFIG_STATUS <<\EOF
20302 # Let's still pretend it is `configure' which instantiates (i.e., don't
20303 # use $as_me), people would be surprised to read:
20304 # /* config.h. Generated automatically by config.status. */
20305 if test x"$ac_file" = x-; then
20306 echo "/* Generated automatically by configure. */" >$tmp/config.h
20308 echo "/* $ac_file. Generated automatically by configure. */" >$tmp/config.h
20310 cat $tmp/in >>$tmp/config.h
20312 if test x"$ac_file" != x-; then
20313 if cmp -s $ac_file $tmp/config.h 2>/dev/null; then
20314 { echo "$as_me:20314: $ac_file is unchanged" >&5
20315 echo "$as_me: $ac_file is unchanged" >&6;}
20317 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
20318 X"$ac_file" : 'X\(//\)[^/]' \| \
20319 X"$ac_file" : 'X\(//\)$' \| \
20320 X"$ac_file" : 'X\(/\)' \| \
20321 . : '\(.\)' 2>/dev/null ||
20323 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
20324 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
20325 /^X\(\/\/\)$/{ s//\1/; q; }
20326 /^X\(\/\).*/{ s//\1/; q; }
20328 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
20329 { case "$ac_dir" in
20330 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
20334 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
20335 case $as_mkdir_dir in
20336 # Skip DOS drivespec
20337 ?:) as_incr_dir=$as_mkdir_dir ;;
20339 as_incr_dir=$as_incr_dir/$as_mkdir_dir
20340 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
20347 mv $tmp/config.h $ac_file
20351 rm -f $tmp/config.h
20355 cat >>$CONFIG_STATUS <<\EOF
20357 # CONFIG_COMMANDS section.
20359 for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
20360 ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
20361 ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
20368 if test ! -d $srcdir/$cf_dir; then
20370 elif test -f $srcdir/$cf_dir/programs; then
20371 $AWK -f $srcdir/mk-test.awk INSTALL=yes ECHO_LINK="$ECHO_LD" $srcdir/$cf_dir/programs >>$cf_dir/Makefile
20375 cat >>Makefile <<TEST_EOF
20377 # These rules are generated so we do not rely on suffix rules, which do not
20378 # work consistently for different make-programs (the '\$(MODEL)/' confuses
20379 # some, and the '\$x' confuses others).
20382 LIST=`sed -e 's/[ ].*//' -e '/^[#@]/d' $srcdir/modules`
20385 cat >>Makefile <<TEST_EOF
20387 \$(MODEL)/$N.o : \$(srcdir)/$N.c \\
20388 \$(srcdir)/test.priv.h \\
20391 $ECHO_CC\$(CC) -c \$(CFLAGS_DEFAULT) -DMODULE_NAME="$N" \$(srcdir)/$N.c
20395 if test -f ../config.guess && test -f ../config.sub
20397 cat >>Makefile <<TEST_EOF
20399 # if we used CF_INHERIT for getting these files, we can remove them
20401 rm -f config.guess config.sub
20409 cat >>$CONFIG_STATUS <<\EOF
20411 { (exit 0); exit 0; }
20413 chmod +x $CONFIG_STATUS
20414 ac_clean_files=$ac_clean_files_save
20416 # configure is writing to config.log, and then calls config.status.
20417 # config.status does its own redirection, appending to config.log.
20418 # Unfortunately, on DOS this fails, as config.log is still kept open
20419 # by configure, so config.status won't be able to write to it; its
20420 # output is simply discarded. So we exec the FD to /dev/null,
20421 # effectively closing config.log, so it can be properly (re)opened and
20422 # appended to by config.status. When coming back to configure, we
20423 # need to make the FD available again.
20424 if test "$no_create" != yes; then
20427 $SHELL $CONFIG_STATUS || ac_cs_success=false
20429 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
20430 # would make configure fail if this is the last instruction.
20431 $ac_cs_success || { (exit 1); exit 1; }