2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by Autoconf 2.52.20121002.
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 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
651 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
654 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
655 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
658 --with-pkg-config{=path} enable/disable use of pkg-config
659 --disable-echo do not display "compiling" commands
660 Curses Version-dependent Options:
661 --with-ncurses-wrap-prefix naming-prefix for ncurses wrapped-variables
662 --disable-widec disable checks for wide-character functions
663 --with-curses-dir=DIR directory in which (n)curses is installed
664 --with-ncursesw use wide ncurses-libraries
665 --with-ncurses use ncurses-libraries
666 --with-pdcurses compile/link with pdcurses X11 library
667 --with-curses-colr compile/link with HPUX 10.x color-curses
668 --with-curses-5lib compile/link with SunOS 5lib curses
669 --with-Xaw3d link with Xaw 3d library
670 --with-Xaw3dxft link with Xaw 3d xft library
671 --with-neXtaw link with neXT Athena library
672 --with-XawPlus link with Athena-Plus library
673 --with-x use the X Window System
674 Testing/development Options:
675 --enable-warnings test: turn on gcc compiler warnings
676 --with-dmalloc test: use Gray Watson's dmalloc library
677 --with-dbmalloc test: use Conor Cahill's dbmalloc library
678 --with-valgrind test: use valgrind
679 --disable-leaks test: free permanent memory, analyze leaks
680 --disable-rpath-hack don't add rpath options for additional libraries
682 Some influential environment variables:
683 CC C compiler command
684 CFLAGS C compiler flags
685 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
686 nonstandard directory <lib dir>
687 CPPFLAGS C/C++ preprocessor flags, e.g. -I<include dir> if you have
688 headers in a nonstandard directory <include dir>
691 Use these variables to override the choices made by `configure' or to help
692 it to find libraries and programs with nonstandard names/locations.
697 if test "$ac_init_help" = "recursive"; then
698 # If there are subdirs, report their specific --help.
700 for ac_subdir in : $ac_subdirs_all; do test "x$ac_subdir" = x: && continue
702 # A "../" for each directory in /$ac_subdir.
703 ac_dots=`echo $ac_subdir |
704 sed 's,^\./,,;s,[^/]$,&/,;s,[^/]*/,../,g'`
707 .) # No --srcdir option. We are building in place.
708 ac_sub_srcdir=$srcdir ;;
709 [\\/]* | ?:[\\/]* ) # Absolute path.
710 ac_sub_srcdir=$srcdir/$ac_subdir ;;
712 ac_sub_srcdir=$ac_dots$srcdir/$ac_subdir ;;
715 # Check for guested configure; otherwise get Cygnus style configure.
716 if test -f $ac_sub_srcdir/configure.gnu; then
718 $SHELL $ac_sub_srcdir/configure.gnu --help=recursive
719 elif test -f $ac_sub_srcdir/configure; then
721 $SHELL $ac_sub_srcdir/configure --help=recursive
722 elif test -f $ac_sub_srcdir/configure.ac ||
723 test -f $ac_sub_srcdir/configure.in; then
727 echo "$as_me: WARNING: no configuration information is in $ac_subdir" >&2
733 test -n "$ac_init_help" && exit 0
734 if $ac_init_version; then
737 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
738 Free Software Foundation, Inc.
739 This configure script is free software; the Free Software Foundation
740 gives unlimited permission to copy, distribute and modify it.
746 This file contains any messages produced by compilers while
747 running configure, to aid debugging if configure makes a mistake.
749 It was created by $as_me, which was
750 generated by GNU Autoconf 2.52.20121002. Invocation command line was
761 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
762 uname -m = `(uname -m) 2>/dev/null || echo unknown`
763 uname -r = `(uname -r) 2>/dev/null || echo unknown`
764 uname -s = `(uname -s) 2>/dev/null || echo unknown`
765 uname -v = `(uname -v) 2>/dev/null || echo unknown`
767 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
768 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
770 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
771 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
772 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
773 hostinfo = `(hostinfo) 2>/dev/null || echo unknown`
774 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
775 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
776 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
790 # Keep a trace of the command line.
791 # Strip out --no-create and --no-recursion so they do not pile up.
792 # Also quote any args containing shell meta-characters.
798 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
799 | --no-cr | --no-c) ;;
800 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
801 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
802 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
803 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"`
804 ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
806 *) ac_configure_args="$ac_configure_args$ac_sep$ac_arg"
809 # Get rid of the leading space.
812 # When interrupted or exit'd, cleanup temporary files, and complete
813 # config.log. We remove comments because anyway the quotes in there
814 # would cause problems or look ugly.
816 # Save into config.log some information that might help in debugging.
818 echo "## ----------------- ##" >&5
819 echo "## Cache variables. ##" >&5
820 echo "## ----------------- ##" >&5
822 # The following way of writing the cache mishandles newlines in values,
825 case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
828 "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
829 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
833 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
837 sed "/^$/d" confdefs.h >conftest.log
838 if test -s conftest.log; then
840 echo "## ------------ ##" >&5
841 echo "## confdefs.h. ##" >&5
842 echo "## ------------ ##" >&5
847 test "$ac_signal" != 0 &&
848 echo "$as_me: caught signal $ac_signal" >&5
849 echo "$as_me: exit $exit_status" >&5
850 rm -rf conftest* confdefs* core core.* *.core conf$$* $ac_clean_files &&
853 for ac_signal in 1 2 13 15; do
854 trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
858 # confdefs.h avoids OS command line length limits that DEFS can exceed.
859 rm -rf conftest* confdefs.h
860 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
863 # Let the site file select an alternate cache file if it wants to.
864 # Prefer explicitly selected file to automatically selected ones.
865 if test -z "$CONFIG_SITE"; then
866 if test "x$prefix" != xNONE; then
867 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
869 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
872 for ac_site_file in $CONFIG_SITE; do
873 if test -r "$ac_site_file"; then
874 { echo "$as_me:874: loading site script $ac_site_file" >&5
875 echo "$as_me: loading site script $ac_site_file" >&6;}
876 cat "$ac_site_file" >&5
881 if test -r "$cache_file"; then
882 # Some versions of bash will fail to source /dev/null (special
883 # files actually), so we avoid doing that.
884 if test -f "$cache_file"; then
885 { echo "$as_me:885: loading cache $cache_file" >&5
886 echo "$as_me: loading cache $cache_file" >&6;}
888 [\\/]* | ?:[\\/]* ) . $cache_file;;
893 { echo "$as_me:893: creating cache $cache_file" >&5
894 echo "$as_me: creating cache $cache_file" >&6;}
898 # Check that the precious variables saved in the cache have kept the same
900 ac_cache_corrupted=false
901 for ac_var in `(set) 2>&1 |
902 sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
903 eval ac_old_set=\$ac_cv_env_${ac_var}_set
904 eval ac_new_set=\$ac_env_${ac_var}_set
905 eval ac_old_val="\$ac_cv_env_${ac_var}_value"
906 eval ac_new_val="\$ac_env_${ac_var}_value"
907 case $ac_old_set,$ac_new_set in
909 { echo "$as_me:909: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
910 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
911 ac_cache_corrupted=: ;;
913 { echo "$as_me:913: error: \`$ac_var' was not set in the previous run" >&5
914 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
915 ac_cache_corrupted=: ;;
918 if test "x$ac_old_val" != "x$ac_new_val"; then
919 { echo "$as_me:919: error: \`$ac_var' has changed since the previous run:" >&5
920 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
921 { echo "$as_me:921: former value: $ac_old_val" >&5
922 echo "$as_me: former value: $ac_old_val" >&2;}
923 { echo "$as_me:923: current value: $ac_new_val" >&5
924 echo "$as_me: current value: $ac_new_val" >&2;}
928 # Pass precious variables to config.status. It doesn't matter if
929 # we pass some twice (in addition to the command line arguments).
930 if test "$ac_new_set" = set; then
932 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
933 ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"`
934 ac_configure_args="$ac_configure_args '$ac_arg'"
936 *) ac_configure_args="$ac_configure_args $ac_var=$ac_new_val"
941 if $ac_cache_corrupted; then
942 { echo "$as_me:942: error: changes in the environment can compromise the build" >&5
943 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
944 { { echo "$as_me:944: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
945 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
946 { (exit 1); exit 1; }; }
950 ac_cpp='$CPP $CPPFLAGS'
951 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
952 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
953 ac_compiler_gnu=$ac_cv_c_compiler_gnu
954 ac_main_return=return
956 case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
957 *c*,-n*) ECHO_N= ECHO_C='
959 *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
960 *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
962 echo "#! $SHELL" >conftest.sh
963 echo "exit 0" >>conftest.sh
965 if { (echo "$as_me:965: PATH=\".;.\"; conftest.sh") >&5
966 (PATH=".;."; conftest.sh) 2>&5
968 echo "$as_me:968: \$? = $ac_status" >&5
969 (exit $ac_status); }; then
970 ac_path_separator=';'
974 PATH_SEPARATOR="$ac_path_separator"
977 ac_config_headers="$ac_config_headers ncurses_cfg.h:ncurses_tst.hin"
979 test -f config.guess || ( test -f ../config.guess && cp ../config.guess ./ )
981 test -f config.sub || ( test -f ../config.sub && cp ../config.sub ./ )
984 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
985 if test -f $ac_dir/install-sh; then
987 ac_install_sh="$ac_aux_dir/install-sh -c"
989 elif test -f $ac_dir/install.sh; then
991 ac_install_sh="$ac_aux_dir/install.sh -c"
993 elif test -f $ac_dir/shtool; then
995 ac_install_sh="$ac_aux_dir/shtool install -c"
999 if test -z "$ac_aux_dir"; then
1000 { { echo "$as_me:1000: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
1001 echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
1002 { (exit 1); exit 1; }; }
1004 ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1005 ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1006 ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
1008 # Make sure we can run config.sub.
1009 $ac_config_sub sun4 >/dev/null 2>&1 ||
1010 { { echo "$as_me:1010: error: cannot run $ac_config_sub" >&5
1011 echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1012 { (exit 1); exit 1; }; }
1014 echo "$as_me:1014: checking build system type" >&5
1015 echo $ECHO_N "checking build system type... $ECHO_C" >&6
1016 if test "${ac_cv_build+set}" = set; then
1017 echo $ECHO_N "(cached) $ECHO_C" >&6
1019 ac_cv_build_alias=$build_alias
1020 test -z "$ac_cv_build_alias" &&
1021 ac_cv_build_alias=`$ac_config_guess`
1022 test -z "$ac_cv_build_alias" &&
1023 { { echo "$as_me:1023: error: cannot guess build type; you must specify one" >&5
1024 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1025 { (exit 1); exit 1; }; }
1026 ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
1027 { { echo "$as_me:1027: error: $ac_config_sub $ac_cv_build_alias failed." >&5
1028 echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed." >&2;}
1029 { (exit 1); exit 1; }; }
1032 echo "$as_me:1032: result: $ac_cv_build" >&5
1033 echo "${ECHO_T}$ac_cv_build" >&6
1035 build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1036 build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1037 build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1039 if test -f $srcdir/config.guess || test -f $ac_aux_dir/config.guess ; then
1040 echo "$as_me:1040: checking host system type" >&5
1041 echo $ECHO_N "checking host system type... $ECHO_C" >&6
1042 if test "${ac_cv_host+set}" = set; then
1043 echo $ECHO_N "(cached) $ECHO_C" >&6
1045 ac_cv_host_alias=$host_alias
1046 test -z "$ac_cv_host_alias" &&
1047 ac_cv_host_alias=$ac_cv_build_alias
1048 ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
1049 { { echo "$as_me:1049: error: $ac_config_sub $ac_cv_host_alias failed" >&5
1050 echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1051 { (exit 1); exit 1; }; }
1054 echo "$as_me:1054: result: $ac_cv_host" >&5
1055 echo "${ECHO_T}$ac_cv_host" >&6
1057 host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1058 host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1059 host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1061 system_name="$host_os"
1063 system_name="`(uname -s -r) 2>/dev/null`"
1064 if test -z "$system_name" ; then
1065 system_name="`(hostname) 2>/dev/null`"
1068 test -n "$system_name" &&
1069 cat >>confdefs.h <<EOF
1070 #define SYSTEM_NAME "$system_name"
1073 if test "${cf_cv_system_name+set}" = set; then
1074 echo $ECHO_N "(cached) $ECHO_C" >&6
1076 cf_cv_system_name="$system_name"
1079 test -z "$system_name" && system_name="$cf_cv_system_name"
1080 test -n "$cf_cv_system_name" && echo "$as_me:1080: result: Configuring for $cf_cv_system_name" >&5
1081 echo "${ECHO_T}Configuring for $cf_cv_system_name" >&6
1083 if test ".$system_name" != ".$cf_cv_system_name" ; then
1084 echo "$as_me:1084: result: Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&5
1085 echo "${ECHO_T}Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&6
1086 { { echo "$as_me:1086: error: \"Please remove config.cache and try again.\"" >&5
1087 echo "$as_me: error: \"Please remove config.cache and try again.\"" >&2;}
1088 { (exit 1); exit 1; }; }
1091 test "$program_prefix" != NONE &&
1092 program_transform_name="s,^,$program_prefix,;$program_transform_name"
1093 # Use a double $ so make ignores it.
1094 test "$program_suffix" != NONE &&
1095 program_transform_name="s,\$,$program_suffix,;$program_transform_name"
1096 # Double any \ or $. echo might interpret backslashes.
1097 # By default was `s,x,x', remove it if useless.
1098 cat <<\_ACEOF >conftest.sed
1099 s/[\\$]/&&/g;s/;s,x,x,$//
1101 program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
1104 echo "$as_me:1104: checking whether ${MAKE-make} sets \${MAKE}" >&5
1105 echo $ECHO_N "checking whether ${MAKE-make} sets \${MAKE}... $ECHO_C" >&6
1106 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,./+-,__p_,'`
1107 if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
1108 echo $ECHO_N "(cached) $ECHO_C" >&6
1110 cat >conftest.make <<\EOF
1112 @echo 'ac_maketemp="${MAKE}"'
1114 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1115 eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
1116 if test -n "$ac_maketemp"; then
1117 eval ac_cv_prog_make_${ac_make}_set=yes
1119 eval ac_cv_prog_make_${ac_make}_set=no
1123 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
1124 echo "$as_me:1124: result: yes" >&5
1125 echo "${ECHO_T}yes" >&6
1128 echo "$as_me:1128: result: no" >&5
1129 echo "${ECHO_T}no" >&6
1130 SET_MAKE="MAKE=${MAKE-make}"
1134 ac_cpp='$CPP $CPPFLAGS'
1135 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1136 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1137 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1138 ac_main_return=return
1139 if test -n "$ac_tool_prefix"; then
1140 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
1141 set dummy ${ac_tool_prefix}gcc; ac_word=$2
1142 echo "$as_me:1142: checking for $ac_word" >&5
1143 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1144 if test "${ac_cv_prog_CC+set}" = set; then
1145 echo $ECHO_N "(cached) $ECHO_C" >&6
1147 if test -n "$CC"; then
1148 ac_cv_prog_CC="$CC" # Let the user override the test.
1150 ac_save_IFS=$IFS; IFS=$ac_path_separator
1152 for ac_dir in $ac_dummy; do
1154 test -z "$ac_dir" && ac_dir=.
1155 $as_executable_p "$ac_dir/$ac_word" || continue
1156 ac_cv_prog_CC="${ac_tool_prefix}gcc"
1157 echo "$as_me:1157: found $ac_dir/$ac_word" >&5
1164 if test -n "$CC"; then
1165 echo "$as_me:1165: result: $CC" >&5
1166 echo "${ECHO_T}$CC" >&6
1168 echo "$as_me:1168: result: no" >&5
1169 echo "${ECHO_T}no" >&6
1173 if test -z "$ac_cv_prog_CC"; then
1175 # Extract the first word of "gcc", so it can be a program name with args.
1176 set dummy gcc; ac_word=$2
1177 echo "$as_me:1177: checking for $ac_word" >&5
1178 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1179 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1180 echo $ECHO_N "(cached) $ECHO_C" >&6
1182 if test -n "$ac_ct_CC"; then
1183 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1185 ac_save_IFS=$IFS; IFS=$ac_path_separator
1187 for ac_dir in $ac_dummy; do
1189 test -z "$ac_dir" && ac_dir=.
1190 $as_executable_p "$ac_dir/$ac_word" || continue
1191 ac_cv_prog_ac_ct_CC="gcc"
1192 echo "$as_me:1192: found $ac_dir/$ac_word" >&5
1198 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1199 if test -n "$ac_ct_CC"; then
1200 echo "$as_me:1200: result: $ac_ct_CC" >&5
1201 echo "${ECHO_T}$ac_ct_CC" >&6
1203 echo "$as_me:1203: result: no" >&5
1204 echo "${ECHO_T}no" >&6
1212 if test -z "$CC"; then
1213 if test -n "$ac_tool_prefix"; then
1214 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
1215 set dummy ${ac_tool_prefix}cc; ac_word=$2
1216 echo "$as_me:1216: checking for $ac_word" >&5
1217 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1218 if test "${ac_cv_prog_CC+set}" = set; then
1219 echo $ECHO_N "(cached) $ECHO_C" >&6
1221 if test -n "$CC"; then
1222 ac_cv_prog_CC="$CC" # Let the user override the test.
1224 ac_save_IFS=$IFS; IFS=$ac_path_separator
1226 for ac_dir in $ac_dummy; do
1228 test -z "$ac_dir" && ac_dir=.
1229 $as_executable_p "$ac_dir/$ac_word" || continue
1230 ac_cv_prog_CC="${ac_tool_prefix}cc"
1231 echo "$as_me:1231: found $ac_dir/$ac_word" >&5
1238 if test -n "$CC"; then
1239 echo "$as_me:1239: result: $CC" >&5
1240 echo "${ECHO_T}$CC" >&6
1242 echo "$as_me:1242: result: no" >&5
1243 echo "${ECHO_T}no" >&6
1247 if test -z "$ac_cv_prog_CC"; then
1249 # Extract the first word of "cc", so it can be a program name with args.
1250 set dummy cc; ac_word=$2
1251 echo "$as_me:1251: checking for $ac_word" >&5
1252 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1253 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1254 echo $ECHO_N "(cached) $ECHO_C" >&6
1256 if test -n "$ac_ct_CC"; then
1257 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1259 ac_save_IFS=$IFS; IFS=$ac_path_separator
1261 for ac_dir in $ac_dummy; do
1263 test -z "$ac_dir" && ac_dir=.
1264 $as_executable_p "$ac_dir/$ac_word" || continue
1265 ac_cv_prog_ac_ct_CC="cc"
1266 echo "$as_me:1266: found $ac_dir/$ac_word" >&5
1272 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1273 if test -n "$ac_ct_CC"; then
1274 echo "$as_me:1274: result: $ac_ct_CC" >&5
1275 echo "${ECHO_T}$ac_ct_CC" >&6
1277 echo "$as_me:1277: result: no" >&5
1278 echo "${ECHO_T}no" >&6
1287 if test -z "$CC"; then
1288 # Extract the first word of "cc", so it can be a program name with args.
1289 set dummy cc; ac_word=$2
1290 echo "$as_me:1290: checking for $ac_word" >&5
1291 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1292 if test "${ac_cv_prog_CC+set}" = set; then
1293 echo $ECHO_N "(cached) $ECHO_C" >&6
1295 if test -n "$CC"; then
1296 ac_cv_prog_CC="$CC" # Let the user override the test.
1299 ac_save_IFS=$IFS; IFS=$ac_path_separator
1301 for ac_dir in $ac_dummy; do
1303 test -z "$ac_dir" && ac_dir=.
1304 $as_executable_p "$ac_dir/$ac_word" || continue
1305 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
1306 ac_prog_rejected=yes
1310 echo "$as_me:1310: found $ac_dir/$ac_word" >&5
1314 if test $ac_prog_rejected = yes; then
1315 # We found a bogon in the path, so make sure we never use it.
1316 set dummy $ac_cv_prog_CC
1318 if test $# != 0; then
1319 # We chose a different compiler from the bogus one.
1320 # However, it has the same basename, so the bogon will be chosen
1321 # first if we set CC to just the basename; use the full file name.
1323 set dummy "$ac_dir/$ac_word" ${1+"$@"}
1331 if test -n "$CC"; then
1332 echo "$as_me:1332: result: $CC" >&5
1333 echo "${ECHO_T}$CC" >&6
1335 echo "$as_me:1335: result: no" >&5
1336 echo "${ECHO_T}no" >&6
1340 if test -z "$CC"; then
1341 if test -n "$ac_tool_prefix"; then
1344 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
1345 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
1346 echo "$as_me:1346: checking for $ac_word" >&5
1347 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1348 if test "${ac_cv_prog_CC+set}" = set; then
1349 echo $ECHO_N "(cached) $ECHO_C" >&6
1351 if test -n "$CC"; then
1352 ac_cv_prog_CC="$CC" # Let the user override the test.
1354 ac_save_IFS=$IFS; IFS=$ac_path_separator
1356 for ac_dir in $ac_dummy; do
1358 test -z "$ac_dir" && ac_dir=.
1359 $as_executable_p "$ac_dir/$ac_word" || continue
1360 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
1361 echo "$as_me:1361: found $ac_dir/$ac_word" >&5
1368 if test -n "$CC"; then
1369 echo "$as_me:1369: result: $CC" >&5
1370 echo "${ECHO_T}$CC" >&6
1372 echo "$as_me:1372: result: no" >&5
1373 echo "${ECHO_T}no" >&6
1376 test -n "$CC" && break
1379 if test -z "$CC"; then
1383 # Extract the first word of "$ac_prog", so it can be a program name with args.
1384 set dummy $ac_prog; ac_word=$2
1385 echo "$as_me:1385: checking for $ac_word" >&5
1386 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1387 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1388 echo $ECHO_N "(cached) $ECHO_C" >&6
1390 if test -n "$ac_ct_CC"; then
1391 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1393 ac_save_IFS=$IFS; IFS=$ac_path_separator
1395 for ac_dir in $ac_dummy; do
1397 test -z "$ac_dir" && ac_dir=.
1398 $as_executable_p "$ac_dir/$ac_word" || continue
1399 ac_cv_prog_ac_ct_CC="$ac_prog"
1400 echo "$as_me:1400: found $ac_dir/$ac_word" >&5
1406 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1407 if test -n "$ac_ct_CC"; then
1408 echo "$as_me:1408: result: $ac_ct_CC" >&5
1409 echo "${ECHO_T}$ac_ct_CC" >&6
1411 echo "$as_me:1411: result: no" >&5
1412 echo "${ECHO_T}no" >&6
1415 test -n "$ac_ct_CC" && break
1423 test -z "$CC" && { { echo "$as_me:1423: error: no acceptable cc found in \$PATH" >&5
1424 echo "$as_me: error: no acceptable cc found in \$PATH" >&2;}
1425 { (exit 1); exit 1; }; }
1427 # Provide some information about the compiler.
1428 echo "$as_me:1428:" \
1429 "checking for C compiler version" >&5
1430 ac_compiler=`set X $ac_compile; echo $2`
1431 { (eval echo "$as_me:1431: \"$ac_compiler --version </dev/null >&5\"") >&5
1432 (eval $ac_compiler --version </dev/null >&5) 2>&5
1434 echo "$as_me:1434: \$? = $ac_status" >&5
1435 (exit $ac_status); }
1436 { (eval echo "$as_me:1436: \"$ac_compiler -v </dev/null >&5\"") >&5
1437 (eval $ac_compiler -v </dev/null >&5) 2>&5
1439 echo "$as_me:1439: \$? = $ac_status" >&5
1440 (exit $ac_status); }
1441 { (eval echo "$as_me:1441: \"$ac_compiler -V </dev/null >&5\"") >&5
1442 (eval $ac_compiler -V </dev/null >&5) 2>&5
1444 echo "$as_me:1444: \$? = $ac_status" >&5
1445 (exit $ac_status); }
1447 cat >conftest.$ac_ext <<_ACEOF
1448 #line 1448 "configure"
1449 #include "confdefs.h"
1459 ac_clean_files_save=$ac_clean_files
1460 ac_clean_files="$ac_clean_files a.out a.exe"
1461 # Try to create an executable without -o first, disregard a.out.
1462 # It will help us diagnose broken compilers, and finding out an intuition
1464 echo "$as_me:1464: checking for C compiler default output" >&5
1465 echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
1466 ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
1467 if { (eval echo "$as_me:1467: \"$ac_link_default\"") >&5
1468 (eval $ac_link_default) 2>&5
1470 echo "$as_me:1470: \$? = $ac_status" >&5
1471 (exit $ac_status); }; then
1472 # Find the output, starting from the most likely. This scheme is
1473 # not robust to junk in `.', hence go to wildcards (a.*) only as a last
1475 for ac_file in `ls a.exe conftest.exe 2>/dev/null;
1476 ls a.out conftest 2>/dev/null;
1477 ls a.* conftest.* 2>/dev/null`; do
1479 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1480 a.out ) # We found the default executable, but exeext='' is most
1483 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1484 # FIXME: I believe we export ac_cv_exeext for Libtool --akim.
1491 echo "$as_me: failed program was:" >&5
1492 cat conftest.$ac_ext >&5
1493 { { echo "$as_me:1493: error: C compiler cannot create executables" >&5
1494 echo "$as_me: error: C compiler cannot create executables" >&2;}
1495 { (exit 77); exit 77; }; }
1498 ac_exeext=$ac_cv_exeext
1499 echo "$as_me:1499: result: $ac_file" >&5
1500 echo "${ECHO_T}$ac_file" >&6
1502 # Check the compiler produces executables we can run. If not, either
1503 # the compiler is broken, or we cross compile.
1504 echo "$as_me:1504: checking whether the C compiler works" >&5
1505 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
1506 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
1507 # If not cross compiling, check that we can run a simple program.
1508 if test "$cross_compiling" != yes; then
1509 if { ac_try='./$ac_file'
1510 { (eval echo "$as_me:1510: \"$ac_try\"") >&5
1513 echo "$as_me:1513: \$? = $ac_status" >&5
1514 (exit $ac_status); }; }; then
1517 if test "$cross_compiling" = maybe; then
1520 { { echo "$as_me:1520: error: cannot run C compiled programs.
1521 If you meant to cross compile, use \`--host'." >&5
1522 echo "$as_me: error: cannot run C compiled programs.
1523 If you meant to cross compile, use \`--host'." >&2;}
1524 { (exit 1); exit 1; }; }
1528 echo "$as_me:1528: result: yes" >&5
1529 echo "${ECHO_T}yes" >&6
1531 rm -f a.out a.exe conftest$ac_cv_exeext
1532 ac_clean_files=$ac_clean_files_save
1533 # Check the compiler produces executables we can run. If not, either
1534 # the compiler is broken, or we cross compile.
1535 echo "$as_me:1535: checking whether we are cross compiling" >&5
1536 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
1537 echo "$as_me:1537: result: $cross_compiling" >&5
1538 echo "${ECHO_T}$cross_compiling" >&6
1540 echo "$as_me:1540: checking for executable suffix" >&5
1541 echo $ECHO_N "checking for executable suffix... $ECHO_C" >&6
1542 if { (eval echo "$as_me:1542: \"$ac_link\"") >&5
1543 (eval $ac_link) 2>&5
1545 echo "$as_me:1545: \$? = $ac_status" >&5
1546 (exit $ac_status); }; then
1547 # If both `conftest.exe' and `conftest' are `present' (well, observable)
1548 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
1549 # work properly (i.e., refer to `conftest.exe'), while it won't with
1551 for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do
1553 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1554 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1561 { { echo "$as_me:1561: error: cannot compute EXEEXT: cannot compile and link" >&5
1562 echo "$as_me: error: cannot compute EXEEXT: cannot compile and link" >&2;}
1563 { (exit 1); exit 1; }; }
1566 rm -f conftest$ac_cv_exeext
1567 echo "$as_me:1567: result: $ac_cv_exeext" >&5
1568 echo "${ECHO_T}$ac_cv_exeext" >&6
1570 rm -f conftest.$ac_ext
1571 EXEEXT=$ac_cv_exeext
1573 echo "$as_me:1573: checking for object suffix" >&5
1574 echo $ECHO_N "checking for object suffix... $ECHO_C" >&6
1575 if test "${ac_cv_objext+set}" = set; then
1576 echo $ECHO_N "(cached) $ECHO_C" >&6
1578 cat >conftest.$ac_ext <<_ACEOF
1579 #line 1579 "configure"
1580 #include "confdefs.h"
1590 rm -f conftest.o conftest.obj
1591 if { (eval echo "$as_me:1591: \"$ac_compile\"") >&5
1592 (eval $ac_compile) 2>&5
1594 echo "$as_me:1594: \$? = $ac_status" >&5
1595 (exit $ac_status); }; then
1596 for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
1598 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.map | *.inf ) ;;
1599 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
1604 echo "$as_me: failed program was:" >&5
1605 cat conftest.$ac_ext >&5
1606 { { echo "$as_me:1606: error: cannot compute OBJEXT: cannot compile" >&5
1607 echo "$as_me: error: cannot compute OBJEXT: cannot compile" >&2;}
1608 { (exit 1); exit 1; }; }
1611 rm -f conftest.$ac_cv_objext conftest.$ac_ext
1613 echo "$as_me:1613: result: $ac_cv_objext" >&5
1614 echo "${ECHO_T}$ac_cv_objext" >&6
1615 OBJEXT=$ac_cv_objext
1617 echo "$as_me:1617: checking whether we are using the GNU C compiler" >&5
1618 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
1619 if test "${ac_cv_c_compiler_gnu+set}" = set; then
1620 echo $ECHO_N "(cached) $ECHO_C" >&6
1622 cat >conftest.$ac_ext <<_ACEOF
1623 #line 1623 "configure"
1624 #include "confdefs.h"
1637 rm -f conftest.$ac_objext
1638 if { (eval echo "$as_me:1638: \"$ac_compile\"") >&5
1639 (eval $ac_compile) 2>&5
1641 echo "$as_me:1641: \$? = $ac_status" >&5
1642 (exit $ac_status); } &&
1643 { ac_try='test -s conftest.$ac_objext'
1644 { (eval echo "$as_me:1644: \"$ac_try\"") >&5
1647 echo "$as_me:1647: \$? = $ac_status" >&5
1648 (exit $ac_status); }; }; then
1651 echo "$as_me: failed program was:" >&5
1652 cat conftest.$ac_ext >&5
1655 rm -f conftest.$ac_objext conftest.$ac_ext
1656 ac_cv_c_compiler_gnu=$ac_compiler_gnu
1659 echo "$as_me:1659: result: $ac_cv_c_compiler_gnu" >&5
1660 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
1661 GCC=`test $ac_compiler_gnu = yes && echo yes`
1662 ac_test_CFLAGS=${CFLAGS+set}
1663 ac_save_CFLAGS=$CFLAGS
1665 echo "$as_me:1665: checking whether $CC accepts -g" >&5
1666 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
1667 if test "${ac_cv_prog_cc_g+set}" = set; then
1668 echo $ECHO_N "(cached) $ECHO_C" >&6
1670 cat >conftest.$ac_ext <<_ACEOF
1671 #line 1671 "configure"
1672 #include "confdefs.h"
1682 rm -f conftest.$ac_objext
1683 if { (eval echo "$as_me:1683: \"$ac_compile\"") >&5
1684 (eval $ac_compile) 2>&5
1686 echo "$as_me:1686: \$? = $ac_status" >&5
1687 (exit $ac_status); } &&
1688 { ac_try='test -s conftest.$ac_objext'
1689 { (eval echo "$as_me:1689: \"$ac_try\"") >&5
1692 echo "$as_me:1692: \$? = $ac_status" >&5
1693 (exit $ac_status); }; }; then
1696 echo "$as_me: failed program was:" >&5
1697 cat conftest.$ac_ext >&5
1700 rm -f conftest.$ac_objext conftest.$ac_ext
1702 echo "$as_me:1702: result: $ac_cv_prog_cc_g" >&5
1703 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
1704 if test "$ac_test_CFLAGS" = set; then
1705 CFLAGS=$ac_save_CFLAGS
1706 elif test $ac_cv_prog_cc_g = yes; then
1707 if test "$GCC" = yes; then
1713 if test "$GCC" = yes; then
1719 # Some people use a C++ compiler to compile C. Since we use `exit',
1720 # in C++ we need to declare it. In case someone uses the same compiler
1721 # for both compiling C and C++ we need to have the C++ compiler decide
1722 # the declaration of exit, since it's the most demanding environment.
1723 cat >conftest.$ac_ext <<_ACEOF
1728 rm -f conftest.$ac_objext
1729 if { (eval echo "$as_me:1729: \"$ac_compile\"") >&5
1730 (eval $ac_compile) 2>&5
1732 echo "$as_me:1732: \$? = $ac_status" >&5
1733 (exit $ac_status); } &&
1734 { ac_try='test -s conftest.$ac_objext'
1735 { (eval echo "$as_me:1735: \"$ac_try\"") >&5
1738 echo "$as_me:1738: \$? = $ac_status" >&5
1739 (exit $ac_status); }; }; then
1740 for ac_declaration in \
1742 '#include <stdlib.h>' \
1743 'extern "C" void std::exit (int) throw (); using std::exit;' \
1744 'extern "C" void std::exit (int); using std::exit;' \
1745 'extern "C" void exit (int) throw ();' \
1746 'extern "C" void exit (int);' \
1749 cat >conftest.$ac_ext <<_ACEOF
1750 #line 1750 "configure"
1751 #include "confdefs.h"
1762 rm -f conftest.$ac_objext
1763 if { (eval echo "$as_me:1763: \"$ac_compile\"") >&5
1764 (eval $ac_compile) 2>&5
1766 echo "$as_me:1766: \$? = $ac_status" >&5
1767 (exit $ac_status); } &&
1768 { ac_try='test -s conftest.$ac_objext'
1769 { (eval echo "$as_me:1769: \"$ac_try\"") >&5
1772 echo "$as_me:1772: \$? = $ac_status" >&5
1773 (exit $ac_status); }; }; then
1776 echo "$as_me: failed program was:" >&5
1777 cat conftest.$ac_ext >&5
1780 rm -f conftest.$ac_objext conftest.$ac_ext
1781 cat >conftest.$ac_ext <<_ACEOF
1782 #line 1782 "configure"
1783 #include "confdefs.h"
1793 rm -f conftest.$ac_objext
1794 if { (eval echo "$as_me:1794: \"$ac_compile\"") >&5
1795 (eval $ac_compile) 2>&5
1797 echo "$as_me:1797: \$? = $ac_status" >&5
1798 (exit $ac_status); } &&
1799 { ac_try='test -s conftest.$ac_objext'
1800 { (eval echo "$as_me:1800: \"$ac_try\"") >&5
1803 echo "$as_me:1803: \$? = $ac_status" >&5
1804 (exit $ac_status); }; }; then
1807 echo "$as_me: failed program was:" >&5
1808 cat conftest.$ac_ext >&5
1810 rm -f conftest.$ac_objext conftest.$ac_ext
1813 if test -n "$ac_declaration"; then
1814 echo '#ifdef __cplusplus' >>confdefs.h
1815 echo $ac_declaration >>confdefs.h
1816 echo '#endif' >>confdefs.h
1820 echo "$as_me: failed program was:" >&5
1821 cat conftest.$ac_ext >&5
1823 rm -f conftest.$ac_objext conftest.$ac_ext
1825 ac_cpp='$CPP $CPPFLAGS'
1826 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1827 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1828 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1829 ac_main_return=return
1832 if test "$GCC" = yes ; then
1833 echo "$as_me:1833: checking version of $CC" >&5
1834 echo $ECHO_N "checking version of $CC... $ECHO_C" >&6
1835 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.].*//'`"
1836 test -z "$GCC_VERSION" && GCC_VERSION=unknown
1837 echo "$as_me:1837: result: $GCC_VERSION" >&5
1838 echo "${ECHO_T}$GCC_VERSION" >&6
1841 echo "$as_me:1841: checking for $CC option to accept ANSI C" >&5
1842 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
1843 if test "${ac_cv_prog_cc_stdc+set}" = set; then
1844 echo $ECHO_N "(cached) $ECHO_C" >&6
1846 ac_cv_prog_cc_stdc=no
1848 cat >conftest.$ac_ext <<_ACEOF
1849 #line 1849 "configure"
1850 #include "confdefs.h"
1853 #include <sys/types.h>
1854 #include <sys/stat.h>
1855 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
1856 struct buf { int x; };
1857 FILE * (*rcsopen) (struct buf *, struct stat *, int);
1858 static char *e (p, i)
1864 static char *f (char * (*g) (char **, int), char **p, ...)
1869 s = g (p, va_arg (v,int));
1873 int test (int i, double x);
1874 struct s1 {int (*f) (int a);};
1875 struct s2 {int (*f) (double a);};
1876 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
1882 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
1887 # Don't try gcc -ansi; that turns off useful extensions and
1888 # breaks some systems' header files.
1889 # AIX -qlanglvl=ansi
1890 # Ultrix and OSF/1 -std1
1891 # HP-UX 10.20 and later -Ae
1892 # HP-UX older versions -Aa -D_HPUX_SOURCE
1893 # SVR4 -Xc -D__EXTENSIONS__
1894 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
1896 CC="$ac_save_CC $ac_arg"
1897 rm -f conftest.$ac_objext
1898 if { (eval echo "$as_me:1898: \"$ac_compile\"") >&5
1899 (eval $ac_compile) 2>&5
1901 echo "$as_me:1901: \$? = $ac_status" >&5
1902 (exit $ac_status); } &&
1903 { ac_try='test -s conftest.$ac_objext'
1904 { (eval echo "$as_me:1904: \"$ac_try\"") >&5
1907 echo "$as_me:1907: \$? = $ac_status" >&5
1908 (exit $ac_status); }; }; then
1909 ac_cv_prog_cc_stdc=$ac_arg
1912 echo "$as_me: failed program was:" >&5
1913 cat conftest.$ac_ext >&5
1915 rm -f conftest.$ac_objext
1917 rm -f conftest.$ac_ext conftest.$ac_objext
1922 case "x$ac_cv_prog_cc_stdc" in
1924 echo "$as_me:1924: result: none needed" >&5
1925 echo "${ECHO_T}none needed" >&6 ;;
1927 echo "$as_me:1927: result: $ac_cv_prog_cc_stdc" >&5
1928 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
1929 CC="$CC $ac_cv_prog_cc_stdc" ;;
1932 # This should have been defined by AC_PROG_CC
1935 echo "$as_me:1935: checking \$CC variable" >&5
1936 echo $ECHO_N "checking \$CC variable... $ECHO_C" >&6
1939 echo "$as_me:1939: result: broken" >&5
1940 echo "${ECHO_T}broken" >&6
1941 { echo "$as_me:1941: WARNING: your environment misuses the CC variable to hold CFLAGS/CPPFLAGS options" >&5
1942 echo "$as_me: WARNING: your environment misuses the CC variable to hold CFLAGS/CPPFLAGS options" >&2;}
1944 cf_flags=`echo "$CC" | sed -e 's/^[^ ]*[ ]//'`
1945 CC=`echo "$CC" | sed -e 's/[ ].*//'`
1950 cf_new_extra_cppflags=
1952 for cf_add_cflags in $cf_flags
1954 case $cf_fix_cppflags in
1956 case $cf_add_cflags in #(vi
1957 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
1958 case $cf_add_cflags in
1960 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
1962 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
1963 && test -z "${cf_tst_cflags}" \
1964 && cf_fix_cppflags=yes
1966 if test $cf_fix_cppflags = yes ; then
1967 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
1969 elif test "${cf_tst_cflags}" = "\"'" ; then
1970 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
1976 *$cf_add_cflags) #(vi
1979 case $cf_add_cflags in #(vi
1981 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
1983 CPPFLAGS=`echo "$CPPFLAGS" | \
1984 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
1985 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
1989 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
1994 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
1999 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2001 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
2003 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
2004 && test -z "${cf_tst_cflags}" \
2005 && cf_fix_cppflags=no
2010 if test -n "$cf_new_cflags" ; then
2012 CFLAGS="$CFLAGS $cf_new_cflags"
2015 if test -n "$cf_new_cppflags" ; then
2017 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
2020 if test -n "$cf_new_extra_cppflags" ; then
2022 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
2027 echo "$as_me:2027: result: ok" >&5
2028 echo "${ECHO_T}ok" >&6
2033 ac_cpp='$CPP $CPPFLAGS'
2034 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2035 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2036 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2037 ac_main_return=return
2038 echo "$as_me:2038: checking how to run the C preprocessor" >&5
2039 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
2040 # On Suns, sometimes $CPP names a directory.
2041 if test -n "$CPP" && test -d "$CPP"; then
2044 if test -z "$CPP"; then
2045 if test "${ac_cv_prog_CPP+set}" = set; then
2046 echo $ECHO_N "(cached) $ECHO_C" >&6
2048 # Double quotes because CPP needs to be expanded
2049 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
2052 for ac_c_preproc_warn_flag in '' yes
2054 # Use a header file that comes with gcc, so configuring glibc
2055 # with a fresh cross-compiler works.
2056 # On the NeXT, cc -E runs the code through the compiler's parser,
2057 # not just through cpp. "Syntax error" is here to catch this case.
2058 cat >conftest.$ac_ext <<_ACEOF
2059 #line 2059 "configure"
2060 #include "confdefs.h"
2064 if { (eval echo "$as_me:2064: \"$ac_cpp conftest.$ac_ext\"") >&5
2065 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2067 egrep -v '^ *\+' conftest.er1 >conftest.err
2069 cat conftest.err >&5
2070 echo "$as_me:2070: \$? = $ac_status" >&5
2071 (exit $ac_status); } >/dev/null; then
2072 if test -s conftest.err; then
2073 ac_cpp_err=$ac_c_preproc_warn_flag
2080 if test -z "$ac_cpp_err"; then
2083 echo "$as_me: failed program was:" >&5
2084 cat conftest.$ac_ext >&5
2085 # Broken: fails on valid input.
2088 rm -f conftest.err conftest.$ac_ext
2090 # OK, works on sane cases. Now check whether non-existent headers
2091 # can be detected and how.
2092 cat >conftest.$ac_ext <<_ACEOF
2093 #line 2093 "configure"
2094 #include "confdefs.h"
2095 #include <ac_nonexistent.h>
2097 if { (eval echo "$as_me:2097: \"$ac_cpp conftest.$ac_ext\"") >&5
2098 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2100 egrep -v '^ *\+' conftest.er1 >conftest.err
2102 cat conftest.err >&5
2103 echo "$as_me:2103: \$? = $ac_status" >&5
2104 (exit $ac_status); } >/dev/null; then
2105 if test -s conftest.err; then
2106 ac_cpp_err=$ac_c_preproc_warn_flag
2113 if test -z "$ac_cpp_err"; then
2114 # Broken: success on invalid input.
2117 echo "$as_me: failed program was:" >&5
2118 cat conftest.$ac_ext >&5
2119 # Passes both tests.
2123 rm -f conftest.err conftest.$ac_ext
2126 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2127 rm -f conftest.err conftest.$ac_ext
2128 if $ac_preproc_ok; then
2140 echo "$as_me:2140: result: $CPP" >&5
2141 echo "${ECHO_T}$CPP" >&6
2143 for ac_c_preproc_warn_flag in '' yes
2145 # Use a header file that comes with gcc, so configuring glibc
2146 # with a fresh cross-compiler works.
2147 # On the NeXT, cc -E runs the code through the compiler's parser,
2148 # not just through cpp. "Syntax error" is here to catch this case.
2149 cat >conftest.$ac_ext <<_ACEOF
2150 #line 2150 "configure"
2151 #include "confdefs.h"
2155 if { (eval echo "$as_me:2155: \"$ac_cpp conftest.$ac_ext\"") >&5
2156 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2158 egrep -v '^ *\+' conftest.er1 >conftest.err
2160 cat conftest.err >&5
2161 echo "$as_me:2161: \$? = $ac_status" >&5
2162 (exit $ac_status); } >/dev/null; then
2163 if test -s conftest.err; then
2164 ac_cpp_err=$ac_c_preproc_warn_flag
2171 if test -z "$ac_cpp_err"; then
2174 echo "$as_me: failed program was:" >&5
2175 cat conftest.$ac_ext >&5
2176 # Broken: fails on valid input.
2179 rm -f conftest.err conftest.$ac_ext
2181 # OK, works on sane cases. Now check whether non-existent headers
2182 # can be detected and how.
2183 cat >conftest.$ac_ext <<_ACEOF
2184 #line 2184 "configure"
2185 #include "confdefs.h"
2186 #include <ac_nonexistent.h>
2188 if { (eval echo "$as_me:2188: \"$ac_cpp conftest.$ac_ext\"") >&5
2189 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2191 egrep -v '^ *\+' conftest.er1 >conftest.err
2193 cat conftest.err >&5
2194 echo "$as_me:2194: \$? = $ac_status" >&5
2195 (exit $ac_status); } >/dev/null; then
2196 if test -s conftest.err; then
2197 ac_cpp_err=$ac_c_preproc_warn_flag
2204 if test -z "$ac_cpp_err"; then
2205 # Broken: success on invalid input.
2208 echo "$as_me: failed program was:" >&5
2209 cat conftest.$ac_ext >&5
2210 # Passes both tests.
2214 rm -f conftest.err conftest.$ac_ext
2217 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2218 rm -f conftest.err conftest.$ac_ext
2219 if $ac_preproc_ok; then
2222 { { echo "$as_me:2222: error: C preprocessor \"$CPP\" fails sanity check" >&5
2223 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;}
2224 { (exit 1); exit 1; }; }
2228 ac_cpp='$CPP $CPPFLAGS'
2229 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2230 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2231 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2232 ac_main_return=return
2234 for ac_prog in mawk gawk nawk awk
2236 # Extract the first word of "$ac_prog", so it can be a program name with args.
2237 set dummy $ac_prog; ac_word=$2
2238 echo "$as_me:2238: checking for $ac_word" >&5
2239 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2240 if test "${ac_cv_prog_AWK+set}" = set; then
2241 echo $ECHO_N "(cached) $ECHO_C" >&6
2243 if test -n "$AWK"; then
2244 ac_cv_prog_AWK="$AWK" # Let the user override the test.
2246 ac_save_IFS=$IFS; IFS=$ac_path_separator
2248 for ac_dir in $ac_dummy; do
2250 test -z "$ac_dir" && ac_dir=.
2251 $as_executable_p "$ac_dir/$ac_word" || continue
2252 ac_cv_prog_AWK="$ac_prog"
2253 echo "$as_me:2253: found $ac_dir/$ac_word" >&5
2260 if test -n "$AWK"; then
2261 echo "$as_me:2261: result: $AWK" >&5
2262 echo "${ECHO_T}$AWK" >&6
2264 echo "$as_me:2264: result: no" >&5
2265 echo "${ECHO_T}no" >&6
2268 test -n "$AWK" && break
2271 # Find a good install program. We prefer a C program (faster),
2272 # so one script is as good as another. But avoid the broken or
2273 # incompatible versions:
2274 # SysV /etc/install, /usr/sbin/install
2275 # SunOS /usr/etc/install
2276 # IRIX /sbin/install
2278 # AmigaOS /C/install, which installs bootblocks on floppy discs
2279 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
2280 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
2281 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
2282 # ./install, which can be erroneously created by make from ./install.sh.
2283 echo "$as_me:2283: checking for a BSD compatible install" >&5
2284 echo $ECHO_N "checking for a BSD compatible install... $ECHO_C" >&6
2285 if test -z "$INSTALL"; then
2286 if test "${ac_cv_path_install+set}" = set; then
2287 echo $ECHO_N "(cached) $ECHO_C" >&6
2289 ac_save_IFS=$IFS; IFS=$ac_path_separator
2290 for ac_dir in $PATH; do
2292 # Account for people who put trailing slashes in PATH elements.
2294 / | ./ | .// | /cC/* \
2295 | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* \
2298 # OSF1 and SCO ODT 3.0 have their own names for install.
2299 # Don't use installbsd from OSF since it installs stuff as root
2301 for ac_prog in ginstall scoinst install; do
2302 if $as_executable_p "$ac_dir/$ac_prog"; then
2303 if test $ac_prog = install &&
2304 grep dspmsg "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2305 # AIX install. It has an incompatible calling convention.
2307 elif test $ac_prog = install &&
2308 grep pwplus "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2309 # program-specific install script used by HP pwplus--don't use.
2312 ac_cv_path_install="$ac_dir/$ac_prog -c"
2322 if test "${ac_cv_path_install+set}" = set; then
2323 INSTALL=$ac_cv_path_install
2325 # As a last resort, use the slow shell script. We don't cache a
2326 # path for INSTALL within a source directory, because that will
2327 # break other packages using the cache if that directory is
2328 # removed, or if the path is relative.
2329 INSTALL=$ac_install_sh
2332 echo "$as_me:2332: result: $INSTALL" >&5
2333 echo "${ECHO_T}$INSTALL" >&6
2335 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
2336 # It thinks the first close brace ends the variable substitution.
2337 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
2339 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
2341 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
2347 cf_dir=`echo $INSTALL | sed -e 's%/[^/]*$%%'`
2348 test -z "$cf_dir" && cf_dir=.
2349 INSTALL=`cd $cf_dir && pwd`/`echo $INSTALL | sed -e 's%^.*/%%'`
2353 for ac_prog in tdlint lint alint splint lclint
2355 # Extract the first word of "$ac_prog", so it can be a program name with args.
2356 set dummy $ac_prog; ac_word=$2
2357 echo "$as_me:2357: checking for $ac_word" >&5
2358 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2359 if test "${ac_cv_prog_LINT+set}" = set; then
2360 echo $ECHO_N "(cached) $ECHO_C" >&6
2362 if test -n "$LINT"; then
2363 ac_cv_prog_LINT="$LINT" # Let the user override the test.
2365 ac_save_IFS=$IFS; IFS=$ac_path_separator
2367 for ac_dir in $ac_dummy; do
2369 test -z "$ac_dir" && ac_dir=.
2370 $as_executable_p "$ac_dir/$ac_word" || continue
2371 ac_cv_prog_LINT="$ac_prog"
2372 echo "$as_me:2372: found $ac_dir/$ac_word" >&5
2378 LINT=$ac_cv_prog_LINT
2379 if test -n "$LINT"; then
2380 echo "$as_me:2380: result: $LINT" >&5
2381 echo "${ECHO_T}$LINT" >&6
2383 echo "$as_me:2383: result: no" >&5
2384 echo "${ECHO_T}no" >&6
2387 test -n "$LINT" && break
2390 echo "$as_me:2390: checking if filesystem supports mixed-case filenames" >&5
2391 echo $ECHO_N "checking if filesystem supports mixed-case filenames... $ECHO_C" >&6
2392 if test "${cf_cv_mixedcase+set}" = set; then
2393 echo $ECHO_N "(cached) $ECHO_C" >&6
2396 if test "$cross_compiling" = yes ; then
2397 case $target_alias in #(vi
2398 *-os2-emx*|*-msdosdjgpp*|*-cygwin*|*-msys*|*-mingw*|*-uwin*) #(vi
2406 rm -f conftest CONFTEST
2408 if test -f CONFTEST ; then
2413 rm -f conftest CONFTEST
2417 echo "$as_me:2417: result: $cf_cv_mixedcase" >&5
2418 echo "${ECHO_T}$cf_cv_mixedcase" >&6
2419 test "$cf_cv_mixedcase" = yes &&
2420 cat >>confdefs.h <<\EOF
2421 #define MIXEDCASE_FILENAMES 1
2424 for ac_prog in exctags ctags
2426 # Extract the first word of "$ac_prog", so it can be a program name with args.
2427 set dummy $ac_prog; ac_word=$2
2428 echo "$as_me:2428: checking for $ac_word" >&5
2429 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2430 if test "${ac_cv_prog_CTAGS+set}" = set; then
2431 echo $ECHO_N "(cached) $ECHO_C" >&6
2433 if test -n "$CTAGS"; then
2434 ac_cv_prog_CTAGS="$CTAGS" # Let the user override the test.
2436 ac_save_IFS=$IFS; IFS=$ac_path_separator
2438 for ac_dir in $ac_dummy; do
2440 test -z "$ac_dir" && ac_dir=.
2441 $as_executable_p "$ac_dir/$ac_word" || continue
2442 ac_cv_prog_CTAGS="$ac_prog"
2443 echo "$as_me:2443: found $ac_dir/$ac_word" >&5
2449 CTAGS=$ac_cv_prog_CTAGS
2450 if test -n "$CTAGS"; then
2451 echo "$as_me:2451: result: $CTAGS" >&5
2452 echo "${ECHO_T}$CTAGS" >&6
2454 echo "$as_me:2454: result: no" >&5
2455 echo "${ECHO_T}no" >&6
2458 test -n "$CTAGS" && break
2461 for ac_prog in exetags etags
2463 # Extract the first word of "$ac_prog", so it can be a program name with args.
2464 set dummy $ac_prog; ac_word=$2
2465 echo "$as_me:2465: checking for $ac_word" >&5
2466 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2467 if test "${ac_cv_prog_ETAGS+set}" = set; then
2468 echo $ECHO_N "(cached) $ECHO_C" >&6
2470 if test -n "$ETAGS"; then
2471 ac_cv_prog_ETAGS="$ETAGS" # Let the user override the test.
2473 ac_save_IFS=$IFS; IFS=$ac_path_separator
2475 for ac_dir in $ac_dummy; do
2477 test -z "$ac_dir" && ac_dir=.
2478 $as_executable_p "$ac_dir/$ac_word" || continue
2479 ac_cv_prog_ETAGS="$ac_prog"
2480 echo "$as_me:2480: found $ac_dir/$ac_word" >&5
2486 ETAGS=$ac_cv_prog_ETAGS
2487 if test -n "$ETAGS"; then
2488 echo "$as_me:2488: result: $ETAGS" >&5
2489 echo "${ECHO_T}$ETAGS" >&6
2491 echo "$as_me:2491: result: no" >&5
2492 echo "${ECHO_T}no" >&6
2495 test -n "$ETAGS" && break
2498 # Extract the first word of "${CTAGS:-ctags}", so it can be a program name with args.
2499 set dummy ${CTAGS:-ctags}; ac_word=$2
2500 echo "$as_me:2500: checking for $ac_word" >&5
2501 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2502 if test "${ac_cv_prog_MAKE_LOWER_TAGS+set}" = set; then
2503 echo $ECHO_N "(cached) $ECHO_C" >&6
2505 if test -n "$MAKE_LOWER_TAGS"; then
2506 ac_cv_prog_MAKE_LOWER_TAGS="$MAKE_LOWER_TAGS" # Let the user override the test.
2508 ac_save_IFS=$IFS; IFS=$ac_path_separator
2510 for ac_dir in $ac_dummy; do
2512 test -z "$ac_dir" && ac_dir=.
2513 $as_executable_p "$ac_dir/$ac_word" || continue
2514 ac_cv_prog_MAKE_LOWER_TAGS="yes"
2515 echo "$as_me:2515: found $ac_dir/$ac_word" >&5
2519 test -z "$ac_cv_prog_MAKE_LOWER_TAGS" && ac_cv_prog_MAKE_LOWER_TAGS="no"
2522 MAKE_LOWER_TAGS=$ac_cv_prog_MAKE_LOWER_TAGS
2523 if test -n "$MAKE_LOWER_TAGS"; then
2524 echo "$as_me:2524: result: $MAKE_LOWER_TAGS" >&5
2525 echo "${ECHO_T}$MAKE_LOWER_TAGS" >&6
2527 echo "$as_me:2527: result: no" >&5
2528 echo "${ECHO_T}no" >&6
2531 if test "$cf_cv_mixedcase" = yes ; then
2532 # Extract the first word of "${ETAGS:-etags}", so it can be a program name with args.
2533 set dummy ${ETAGS:-etags}; ac_word=$2
2534 echo "$as_me:2534: checking for $ac_word" >&5
2535 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2536 if test "${ac_cv_prog_MAKE_UPPER_TAGS+set}" = set; then
2537 echo $ECHO_N "(cached) $ECHO_C" >&6
2539 if test -n "$MAKE_UPPER_TAGS"; then
2540 ac_cv_prog_MAKE_UPPER_TAGS="$MAKE_UPPER_TAGS" # Let the user override the test.
2542 ac_save_IFS=$IFS; IFS=$ac_path_separator
2544 for ac_dir in $ac_dummy; do
2546 test -z "$ac_dir" && ac_dir=.
2547 $as_executable_p "$ac_dir/$ac_word" || continue
2548 ac_cv_prog_MAKE_UPPER_TAGS="yes"
2549 echo "$as_me:2549: found $ac_dir/$ac_word" >&5
2553 test -z "$ac_cv_prog_MAKE_UPPER_TAGS" && ac_cv_prog_MAKE_UPPER_TAGS="no"
2556 MAKE_UPPER_TAGS=$ac_cv_prog_MAKE_UPPER_TAGS
2557 if test -n "$MAKE_UPPER_TAGS"; then
2558 echo "$as_me:2558: result: $MAKE_UPPER_TAGS" >&5
2559 echo "${ECHO_T}$MAKE_UPPER_TAGS" >&6
2561 echo "$as_me:2561: result: no" >&5
2562 echo "${ECHO_T}no" >&6
2569 if test "$MAKE_UPPER_TAGS" = yes ; then
2575 if test "$MAKE_LOWER_TAGS" = yes ; then
2581 echo "$as_me:2581: checking if -lm needed for math functions" >&5
2582 echo $ECHO_N "checking if -lm needed for math functions... $ECHO_C" >&6
2583 if test "${cf_cv_need_libm+set}" = set; then
2584 echo $ECHO_N "(cached) $ECHO_C" >&6
2587 cat >conftest.$ac_ext <<_ACEOF
2588 #line 2588 "configure"
2589 #include "confdefs.h"
2597 double x = rand(); printf("result = %g\n", pow(sin(x),x))
2602 rm -f conftest.$ac_objext conftest$ac_exeext
2603 if { (eval echo "$as_me:2603: \"$ac_link\"") >&5
2604 (eval $ac_link) 2>&5
2606 echo "$as_me:2606: \$? = $ac_status" >&5
2607 (exit $ac_status); } &&
2608 { ac_try='test -s conftest$ac_exeext'
2609 { (eval echo "$as_me:2609: \"$ac_try\"") >&5
2612 echo "$as_me:2612: \$? = $ac_status" >&5
2613 (exit $ac_status); }; }; then
2616 echo "$as_me: failed program was:" >&5
2617 cat conftest.$ac_ext >&5
2620 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
2622 echo "$as_me:2622: result: $cf_cv_need_libm" >&5
2623 echo "${ECHO_T}$cf_cv_need_libm" >&6
2624 if test "$cf_cv_need_libm" = yes
2632 CC_SHARED_OPTS=unknown
2633 CPPFLAGS="$CPPFLAGS"
2635 DFT_OBJ_SUBDIR=`pwd|sed -e's:.*/::'`
2636 DFT_UPR_MODEL="NORMAL"
2653 TINFO_LIBS='$(LIBS_CURSES)'
2654 cf_cv_abi_version=""
2655 cf_cv_rel_version=""
2661 if test "$GCC" = yes
2663 cat > conftest.i <<EOF
2665 #define GCC_PRINTF 0
2670 #ifndef GCC_NORETURN
2671 #define GCC_NORETURN /* nothing */
2674 #define GCC_UNUSED /* nothing */
2677 if test "$GCC" = yes
2679 { echo "$as_me:2679: checking for $CC __attribute__ directives..." >&5
2680 echo "$as_me: checking for $CC __attribute__ directives..." >&6;}
2681 cat > conftest.$ac_ext <<EOF
2682 #line 2682 "${as_me:-configure}"
2683 #include "confdefs.h"
2684 #include "conftest.h"
2685 #include "conftest.i"
2687 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
2689 #define GCC_PRINTFLIKE(fmt,var) /*nothing*/
2692 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
2694 #define GCC_SCANFLIKE(fmt,var) /*nothing*/
2696 extern void wow(char *,...) GCC_SCANFLIKE(1,2);
2697 extern void oops(char *,...) GCC_PRINTFLIKE(1,2) GCC_NORETURN;
2698 extern void foo(void) GCC_NORETURN;
2699 int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { return 0; }
2701 cf_printf_attribute=no
2702 cf_scanf_attribute=no
2703 for cf_attribute in scanf printf unused noreturn
2706 cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
2708 cf_directive="__attribute__(($cf_attribute))"
2709 echo "checking for $CC $cf_directive" 1>&5
2711 case $cf_attribute in #(vi
2713 cf_printf_attribute=yes
2714 cat >conftest.h <<EOF
2715 #define GCC_$cf_ATTRIBUTE 1
2719 cf_scanf_attribute=yes
2720 cat >conftest.h <<EOF
2721 #define GCC_$cf_ATTRIBUTE 1
2725 cat >conftest.h <<EOF
2726 #define GCC_$cf_ATTRIBUTE $cf_directive
2731 if { (eval echo "$as_me:2731: \"$ac_compile\"") >&5
2732 (eval $ac_compile) 2>&5
2734 echo "$as_me:2734: \$? = $ac_status" >&5
2735 (exit $ac_status); }; then
2736 test -n "$verbose" && echo "$as_me:2736: result: ... $cf_attribute" >&5
2737 echo "${ECHO_T}... $cf_attribute" >&6
2738 cat conftest.h >>confdefs.h
2739 case $cf_attribute in #(vi
2742 cat >>confdefs.h <<EOF
2743 #define GCC_NORETURN $cf_directive
2748 cf_value='/* nothing */'
2749 if test "$cf_printf_attribute" != no ; then
2750 cf_value='__attribute__((format(printf,fmt,var)))'
2752 cat >>confdefs.h <<\EOF
2753 #define GCC_PRINTF 1
2758 cat >>confdefs.h <<EOF
2759 #define GCC_PRINTFLIKE(fmt,var) $cf_value
2764 cf_value='/* nothing */'
2765 if test "$cf_scanf_attribute" != no ; then
2766 cf_value='__attribute__((format(scanf,fmt,var)))'
2768 cat >>confdefs.h <<\EOF
2774 cat >>confdefs.h <<EOF
2775 #define GCC_SCANFLIKE(fmt,var) $cf_value
2781 cat >>confdefs.h <<EOF
2782 #define GCC_UNUSED $cf_directive
2790 fgrep define conftest.i >>confdefs.h
2796 cf_POSIX_C_SOURCE=199506L
2799 case $host_os in #(vi
2801 cf_xopen_source="-D_ALL_SOURCE"
2807 cf_xopen_source="-D_APPLE_C_SOURCE"
2810 cf_xopen_source="-D_DARWIN_C_SOURCE"
2813 freebsd*|dragonfly*) #(vi
2814 # 5.x headers associate
2815 # _XOPEN_SOURCE=600 with _POSIX_C_SOURCE=200112L
2816 # _XOPEN_SOURCE=500 with _POSIX_C_SOURCE=199506L
2817 cf_POSIX_C_SOURCE=200112L
2819 cf_xopen_source="-D_BSD_TYPES -D__BSD_VISIBLE -D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
2822 cf_xopen_source="-D_HPUX_SOURCE -D_XOPEN_SOURCE=500"
2825 cf_xopen_source="-D_HPUX_SOURCE"
2828 cf_xopen_source="-D_SGI_SOURCE"
2831 linux*|gnu*|mint*|k*bsd*-gnu) #(vi
2833 echo "$as_me:2833: checking if we must define _GNU_SOURCE" >&5
2834 echo $ECHO_N "checking if we must define _GNU_SOURCE... $ECHO_C" >&6
2835 if test "${cf_cv_gnu_source+set}" = set; then
2836 echo $ECHO_N "(cached) $ECHO_C" >&6
2839 cat >conftest.$ac_ext <<_ACEOF
2840 #line 2840 "configure"
2841 #include "confdefs.h"
2842 #include <sys/types.h>
2847 #ifndef _XOPEN_SOURCE
2854 rm -f conftest.$ac_objext
2855 if { (eval echo "$as_me:2855: \"$ac_compile\"") >&5
2856 (eval $ac_compile) 2>&5
2858 echo "$as_me:2858: \$? = $ac_status" >&5
2859 (exit $ac_status); } &&
2860 { ac_try='test -s conftest.$ac_objext'
2861 { (eval echo "$as_me:2861: \"$ac_try\"") >&5
2864 echo "$as_me:2864: \$? = $ac_status" >&5
2865 (exit $ac_status); }; }; then
2868 echo "$as_me: failed program was:" >&5
2869 cat conftest.$ac_ext >&5
2871 CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE"
2872 cat >conftest.$ac_ext <<_ACEOF
2873 #line 2873 "configure"
2874 #include "confdefs.h"
2875 #include <sys/types.h>
2880 #ifdef _XOPEN_SOURCE
2887 rm -f conftest.$ac_objext
2888 if { (eval echo "$as_me:2888: \"$ac_compile\"") >&5
2889 (eval $ac_compile) 2>&5
2891 echo "$as_me:2891: \$? = $ac_status" >&5
2892 (exit $ac_status); } &&
2893 { ac_try='test -s conftest.$ac_objext'
2894 { (eval echo "$as_me:2894: \"$ac_try\"") >&5
2897 echo "$as_me:2897: \$? = $ac_status" >&5
2898 (exit $ac_status); }; }; then
2901 echo "$as_me: failed program was:" >&5
2902 cat conftest.$ac_ext >&5
2903 cf_cv_gnu_source=yes
2905 rm -f conftest.$ac_objext conftest.$ac_ext
2909 rm -f conftest.$ac_objext conftest.$ac_ext
2912 echo "$as_me:2912: result: $cf_cv_gnu_source" >&5
2913 echo "${ECHO_T}$cf_cv_gnu_source" >&6
2914 test "$cf_cv_gnu_source" = yes && CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE"
2918 # setting _XOPEN_SOURCE or _POSIX_SOURCE breaks <sys/select.h> and other headers which use u_int / u_short types
2921 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
2923 cf_save_CFLAGS="$CFLAGS"
2924 cf_save_CPPFLAGS="$CPPFLAGS"
2926 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
2927 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
2928 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
2930 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
2931 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
2932 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
2934 echo "$as_me:2934: checking if we should define _POSIX_C_SOURCE" >&5
2935 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
2936 if test "${cf_cv_posix_c_source+set}" = set; then
2937 echo $ECHO_N "(cached) $ECHO_C" >&6
2940 echo "${as_me:-configure}:2940: testing if the symbol is already defined go no further ..." 1>&5
2942 cat >conftest.$ac_ext <<_ACEOF
2943 #line 2943 "configure"
2944 #include "confdefs.h"
2945 #include <sys/types.h>
2950 #ifndef _POSIX_C_SOURCE
2957 rm -f conftest.$ac_objext
2958 if { (eval echo "$as_me:2958: \"$ac_compile\"") >&5
2959 (eval $ac_compile) 2>&5
2961 echo "$as_me:2961: \$? = $ac_status" >&5
2962 (exit $ac_status); } &&
2963 { ac_try='test -s conftest.$ac_objext'
2964 { (eval echo "$as_me:2964: \"$ac_try\"") >&5
2967 echo "$as_me:2967: \$? = $ac_status" >&5
2968 (exit $ac_status); }; }; then
2969 cf_cv_posix_c_source=no
2971 echo "$as_me: failed program was:" >&5
2972 cat conftest.$ac_ext >&5
2973 cf_want_posix_source=no
2974 case .$cf_POSIX_C_SOURCE in #(vi
2976 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
2979 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
2980 cf_want_posix_source=yes
2983 cf_want_posix_source=yes
2986 if test "$cf_want_posix_source" = yes ; then
2987 cat >conftest.$ac_ext <<_ACEOF
2988 #line 2988 "configure"
2989 #include "confdefs.h"
2990 #include <sys/types.h>
2995 #ifdef _POSIX_SOURCE
3002 rm -f conftest.$ac_objext
3003 if { (eval echo "$as_me:3003: \"$ac_compile\"") >&5
3004 (eval $ac_compile) 2>&5
3006 echo "$as_me:3006: \$? = $ac_status" >&5
3007 (exit $ac_status); } &&
3008 { ac_try='test -s conftest.$ac_objext'
3009 { (eval echo "$as_me:3009: \"$ac_try\"") >&5
3012 echo "$as_me:3012: \$? = $ac_status" >&5
3013 (exit $ac_status); }; }; then
3016 echo "$as_me: failed program was:" >&5
3017 cat conftest.$ac_ext >&5
3018 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
3020 rm -f conftest.$ac_objext conftest.$ac_ext
3023 echo "${as_me:-configure}:3023: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
3025 CFLAGS="$cf_trim_CFLAGS"
3026 CPPFLAGS="$cf_trim_CPPFLAGS $cf_cv_posix_c_source"
3028 echo "${as_me:-configure}:3028: testing if the second compile does not leave our definition intact error ..." 1>&5
3030 cat >conftest.$ac_ext <<_ACEOF
3031 #line 3031 "configure"
3032 #include "confdefs.h"
3033 #include <sys/types.h>
3038 #ifndef _POSIX_C_SOURCE
3045 rm -f conftest.$ac_objext
3046 if { (eval echo "$as_me:3046: \"$ac_compile\"") >&5
3047 (eval $ac_compile) 2>&5
3049 echo "$as_me:3049: \$? = $ac_status" >&5
3050 (exit $ac_status); } &&
3051 { ac_try='test -s conftest.$ac_objext'
3052 { (eval echo "$as_me:3052: \"$ac_try\"") >&5
3055 echo "$as_me:3055: \$? = $ac_status" >&5
3056 (exit $ac_status); }; }; then
3059 echo "$as_me: failed program was:" >&5
3060 cat conftest.$ac_ext >&5
3061 cf_cv_posix_c_source=no
3063 rm -f conftest.$ac_objext conftest.$ac_ext
3064 CFLAGS="$cf_save_CFLAGS"
3065 CPPFLAGS="$cf_save_CPPFLAGS"
3068 rm -f conftest.$ac_objext conftest.$ac_ext
3071 echo "$as_me:3071: result: $cf_cv_posix_c_source" >&5
3072 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
3074 if test "$cf_cv_posix_c_source" != no ; then
3075 CFLAGS="$cf_trim_CFLAGS"
3076 CPPFLAGS="$cf_trim_CPPFLAGS"
3081 cf_new_extra_cppflags=
3083 for cf_add_cflags in $cf_cv_posix_c_source
3085 case $cf_fix_cppflags in
3087 case $cf_add_cflags in #(vi
3088 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
3089 case $cf_add_cflags in
3091 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3093 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3094 && test -z "${cf_tst_cflags}" \
3095 && cf_fix_cppflags=yes
3097 if test $cf_fix_cppflags = yes ; then
3098 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3100 elif test "${cf_tst_cflags}" = "\"'" ; then
3101 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3107 *$cf_add_cflags) #(vi
3110 case $cf_add_cflags in #(vi
3112 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3114 CPPFLAGS=`echo "$CPPFLAGS" | \
3115 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3116 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3120 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
3125 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
3130 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3132 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
3134 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3135 && test -z "${cf_tst_cflags}" \
3136 && cf_fix_cppflags=no
3141 if test -n "$cf_new_cflags" ; then
3143 CFLAGS="$CFLAGS $cf_new_cflags"
3146 if test -n "$cf_new_cppflags" ; then
3148 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
3151 if test -n "$cf_new_extra_cppflags" ; then
3153 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
3160 cf_xopen_source="-D_NETBSD_SOURCE" # setting _XOPEN_SOURCE breaks IPv6 for lynx on NetBSD 1.6, breaks xterm, is not needed for ncursesw
3163 # setting _XOPEN_SOURCE lower than 500 breaks g++ compile with wchar.h, needed for ncursesw
3164 cf_xopen_source="-D_BSD_SOURCE"
3168 # setting _XOPEN_SOURCE breaks xterm on OpenBSD 2.8, is not needed for ncursesw
3171 cf_xopen_source="-D_OSF_SOURCE"
3174 cf_xopen_source="-D_QNX_SOURCE"
3177 # setting _XOPEN_SOURCE breaks Lynx on SCO Unix / OpenServer
3180 cf_xopen_source="-D__EXTENSIONS__"
3181 cf_cv_xopen_source=broken
3185 echo "$as_me:3185: checking if we should define _XOPEN_SOURCE" >&5
3186 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
3187 if test "${cf_cv_xopen_source+set}" = set; then
3188 echo $ECHO_N "(cached) $ECHO_C" >&6
3191 cat >conftest.$ac_ext <<_ACEOF
3192 #line 3192 "configure"
3193 #include "confdefs.h"
3197 #include <sys/types.h>
3203 #ifndef _XOPEN_SOURCE
3210 rm -f conftest.$ac_objext
3211 if { (eval echo "$as_me:3211: \"$ac_compile\"") >&5
3212 (eval $ac_compile) 2>&5
3214 echo "$as_me:3214: \$? = $ac_status" >&5
3215 (exit $ac_status); } &&
3216 { ac_try='test -s conftest.$ac_objext'
3217 { (eval echo "$as_me:3217: \"$ac_try\"") >&5
3220 echo "$as_me:3220: \$? = $ac_status" >&5
3221 (exit $ac_status); }; }; then
3222 cf_cv_xopen_source=no
3224 echo "$as_me: failed program was:" >&5
3225 cat conftest.$ac_ext >&5
3227 CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
3228 cat >conftest.$ac_ext <<_ACEOF
3229 #line 3229 "configure"
3230 #include "confdefs.h"
3234 #include <sys/types.h>
3240 #ifdef _XOPEN_SOURCE
3247 rm -f conftest.$ac_objext
3248 if { (eval echo "$as_me:3248: \"$ac_compile\"") >&5
3249 (eval $ac_compile) 2>&5
3251 echo "$as_me:3251: \$? = $ac_status" >&5
3252 (exit $ac_status); } &&
3253 { ac_try='test -s conftest.$ac_objext'
3254 { (eval echo "$as_me:3254: \"$ac_try\"") >&5
3257 echo "$as_me:3257: \$? = $ac_status" >&5
3258 (exit $ac_status); }; }; then
3259 cf_cv_xopen_source=no
3261 echo "$as_me: failed program was:" >&5
3262 cat conftest.$ac_ext >&5
3263 cf_cv_xopen_source=$cf_XOPEN_SOURCE
3265 rm -f conftest.$ac_objext conftest.$ac_ext
3269 rm -f conftest.$ac_objext conftest.$ac_ext
3272 echo "$as_me:3272: result: $cf_cv_xopen_source" >&5
3273 echo "${ECHO_T}$cf_cv_xopen_source" >&6
3275 if test "$cf_cv_xopen_source" != no ; then
3277 CFLAGS=`echo "$CFLAGS" | \
3278 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3279 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
3281 CPPFLAGS=`echo "$CPPFLAGS" | \
3282 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3283 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
3285 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
3290 cf_new_extra_cppflags=
3292 for cf_add_cflags in $cf_temp_xopen_source
3294 case $cf_fix_cppflags in
3296 case $cf_add_cflags in #(vi
3297 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
3298 case $cf_add_cflags in
3300 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3302 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3303 && test -z "${cf_tst_cflags}" \
3304 && cf_fix_cppflags=yes
3306 if test $cf_fix_cppflags = yes ; then
3307 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3309 elif test "${cf_tst_cflags}" = "\"'" ; then
3310 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3316 *$cf_add_cflags) #(vi
3319 case $cf_add_cflags in #(vi
3321 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3323 CPPFLAGS=`echo "$CPPFLAGS" | \
3324 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3325 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3329 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
3334 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
3339 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3341 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
3343 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3344 && test -z "${cf_tst_cflags}" \
3345 && cf_fix_cppflags=no
3350 if test -n "$cf_new_cflags" ; then
3352 CFLAGS="$CFLAGS $cf_new_cflags"
3355 if test -n "$cf_new_cppflags" ; then
3357 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
3360 if test -n "$cf_new_extra_cppflags" ; then
3362 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
3367 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
3369 cf_save_CFLAGS="$CFLAGS"
3370 cf_save_CPPFLAGS="$CPPFLAGS"
3372 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
3373 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3374 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
3376 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
3377 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3378 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
3380 echo "$as_me:3380: checking if we should define _POSIX_C_SOURCE" >&5
3381 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
3382 if test "${cf_cv_posix_c_source+set}" = set; then
3383 echo $ECHO_N "(cached) $ECHO_C" >&6
3386 echo "${as_me:-configure}:3386: testing if the symbol is already defined go no further ..." 1>&5
3388 cat >conftest.$ac_ext <<_ACEOF
3389 #line 3389 "configure"
3390 #include "confdefs.h"
3391 #include <sys/types.h>
3396 #ifndef _POSIX_C_SOURCE
3403 rm -f conftest.$ac_objext
3404 if { (eval echo "$as_me:3404: \"$ac_compile\"") >&5
3405 (eval $ac_compile) 2>&5
3407 echo "$as_me:3407: \$? = $ac_status" >&5
3408 (exit $ac_status); } &&
3409 { ac_try='test -s conftest.$ac_objext'
3410 { (eval echo "$as_me:3410: \"$ac_try\"") >&5
3413 echo "$as_me:3413: \$? = $ac_status" >&5
3414 (exit $ac_status); }; }; then
3415 cf_cv_posix_c_source=no
3417 echo "$as_me: failed program was:" >&5
3418 cat conftest.$ac_ext >&5
3419 cf_want_posix_source=no
3420 case .$cf_POSIX_C_SOURCE in #(vi
3422 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
3425 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
3426 cf_want_posix_source=yes
3429 cf_want_posix_source=yes
3432 if test "$cf_want_posix_source" = yes ; then
3433 cat >conftest.$ac_ext <<_ACEOF
3434 #line 3434 "configure"
3435 #include "confdefs.h"
3436 #include <sys/types.h>
3441 #ifdef _POSIX_SOURCE
3448 rm -f conftest.$ac_objext
3449 if { (eval echo "$as_me:3449: \"$ac_compile\"") >&5
3450 (eval $ac_compile) 2>&5
3452 echo "$as_me:3452: \$? = $ac_status" >&5
3453 (exit $ac_status); } &&
3454 { ac_try='test -s conftest.$ac_objext'
3455 { (eval echo "$as_me:3455: \"$ac_try\"") >&5
3458 echo "$as_me:3458: \$? = $ac_status" >&5
3459 (exit $ac_status); }; }; then
3462 echo "$as_me: failed program was:" >&5
3463 cat conftest.$ac_ext >&5
3464 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
3466 rm -f conftest.$ac_objext conftest.$ac_ext
3469 echo "${as_me:-configure}:3469: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
3471 CFLAGS="$cf_trim_CFLAGS"
3472 CPPFLAGS="$cf_trim_CPPFLAGS $cf_cv_posix_c_source"
3474 echo "${as_me:-configure}:3474: testing if the second compile does not leave our definition intact error ..." 1>&5
3476 cat >conftest.$ac_ext <<_ACEOF
3477 #line 3477 "configure"
3478 #include "confdefs.h"
3479 #include <sys/types.h>
3484 #ifndef _POSIX_C_SOURCE
3491 rm -f conftest.$ac_objext
3492 if { (eval echo "$as_me:3492: \"$ac_compile\"") >&5
3493 (eval $ac_compile) 2>&5
3495 echo "$as_me:3495: \$? = $ac_status" >&5
3496 (exit $ac_status); } &&
3497 { ac_try='test -s conftest.$ac_objext'
3498 { (eval echo "$as_me:3498: \"$ac_try\"") >&5
3501 echo "$as_me:3501: \$? = $ac_status" >&5
3502 (exit $ac_status); }; }; then
3505 echo "$as_me: failed program was:" >&5
3506 cat conftest.$ac_ext >&5
3507 cf_cv_posix_c_source=no
3509 rm -f conftest.$ac_objext conftest.$ac_ext
3510 CFLAGS="$cf_save_CFLAGS"
3511 CPPFLAGS="$cf_save_CPPFLAGS"
3514 rm -f conftest.$ac_objext conftest.$ac_ext
3517 echo "$as_me:3517: result: $cf_cv_posix_c_source" >&5
3518 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
3520 if test "$cf_cv_posix_c_source" != no ; then
3521 CFLAGS="$cf_trim_CFLAGS"
3522 CPPFLAGS="$cf_trim_CPPFLAGS"
3527 cf_new_extra_cppflags=
3529 for cf_add_cflags in $cf_cv_posix_c_source
3531 case $cf_fix_cppflags in
3533 case $cf_add_cflags in #(vi
3534 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
3535 case $cf_add_cflags in
3537 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3539 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3540 && test -z "${cf_tst_cflags}" \
3541 && cf_fix_cppflags=yes
3543 if test $cf_fix_cppflags = yes ; then
3544 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3546 elif test "${cf_tst_cflags}" = "\"'" ; then
3547 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3553 *$cf_add_cflags) #(vi
3556 case $cf_add_cflags in #(vi
3558 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3560 CPPFLAGS=`echo "$CPPFLAGS" | \
3561 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3562 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3566 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
3571 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
3576 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3578 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
3580 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3581 && test -z "${cf_tst_cflags}" \
3582 && cf_fix_cppflags=no
3587 if test -n "$cf_new_cflags" ; then
3589 CFLAGS="$CFLAGS $cf_new_cflags"
3592 if test -n "$cf_new_cppflags" ; then
3594 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
3597 if test -n "$cf_new_extra_cppflags" ; then
3599 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
3607 if test -n "$cf_xopen_source" ; then
3612 cf_new_extra_cppflags=
3614 for cf_add_cflags in $cf_xopen_source
3616 case $cf_fix_cppflags in
3618 case $cf_add_cflags in #(vi
3619 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
3620 case $cf_add_cflags in
3622 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3624 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3625 && test -z "${cf_tst_cflags}" \
3626 && cf_fix_cppflags=yes
3628 if test $cf_fix_cppflags = yes ; then
3629 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3631 elif test "${cf_tst_cflags}" = "\"'" ; then
3632 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3638 *$cf_add_cflags) #(vi
3641 case $cf_add_cflags in #(vi
3643 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3645 CPPFLAGS=`echo "$CPPFLAGS" | \
3646 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3647 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3651 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
3656 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
3661 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3663 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
3665 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3666 && test -z "${cf_tst_cflags}" \
3667 && cf_fix_cppflags=no
3672 if test -n "$cf_new_cflags" ; then
3674 CFLAGS="$CFLAGS $cf_new_cflags"
3677 if test -n "$cf_new_cppflags" ; then
3679 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
3682 if test -n "$cf_new_extra_cppflags" ; then
3684 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
3689 if test -n "$cf_XOPEN_SOURCE" && test -z "$cf_cv_xopen_source" ; then
3690 echo "$as_me:3690: checking if _XOPEN_SOURCE really is set" >&5
3691 echo $ECHO_N "checking if _XOPEN_SOURCE really is set... $ECHO_C" >&6
3692 cat >conftest.$ac_ext <<_ACEOF
3693 #line 3693 "configure"
3694 #include "confdefs.h"
3700 #ifndef _XOPEN_SOURCE
3707 rm -f conftest.$ac_objext
3708 if { (eval echo "$as_me:3708: \"$ac_compile\"") >&5
3709 (eval $ac_compile) 2>&5
3711 echo "$as_me:3711: \$? = $ac_status" >&5
3712 (exit $ac_status); } &&
3713 { ac_try='test -s conftest.$ac_objext'
3714 { (eval echo "$as_me:3714: \"$ac_try\"") >&5
3717 echo "$as_me:3717: \$? = $ac_status" >&5
3718 (exit $ac_status); }; }; then
3719 cf_XOPEN_SOURCE_set=yes
3721 echo "$as_me: failed program was:" >&5
3722 cat conftest.$ac_ext >&5
3723 cf_XOPEN_SOURCE_set=no
3725 rm -f conftest.$ac_objext conftest.$ac_ext
3726 echo "$as_me:3726: result: $cf_XOPEN_SOURCE_set" >&5
3727 echo "${ECHO_T}$cf_XOPEN_SOURCE_set" >&6
3728 if test $cf_XOPEN_SOURCE_set = yes
3730 cat >conftest.$ac_ext <<_ACEOF
3731 #line 3731 "configure"
3732 #include "confdefs.h"
3738 #if (_XOPEN_SOURCE - 0) < $cf_XOPEN_SOURCE
3745 rm -f conftest.$ac_objext
3746 if { (eval echo "$as_me:3746: \"$ac_compile\"") >&5
3747 (eval $ac_compile) 2>&5
3749 echo "$as_me:3749: \$? = $ac_status" >&5
3750 (exit $ac_status); } &&
3751 { ac_try='test -s conftest.$ac_objext'
3752 { (eval echo "$as_me:3752: \"$ac_try\"") >&5
3755 echo "$as_me:3755: \$? = $ac_status" >&5
3756 (exit $ac_status); }; }; then
3757 cf_XOPEN_SOURCE_set_ok=yes
3759 echo "$as_me: failed program was:" >&5
3760 cat conftest.$ac_ext >&5
3761 cf_XOPEN_SOURCE_set_ok=no
3763 rm -f conftest.$ac_objext conftest.$ac_ext
3764 if test $cf_XOPEN_SOURCE_set_ok = no
3766 { echo "$as_me:3766: WARNING: _XOPEN_SOURCE is lower than requested" >&5
3767 echo "$as_me: WARNING: _XOPEN_SOURCE is lower than requested" >&2;}
3771 echo "$as_me:3771: checking if we should define _XOPEN_SOURCE" >&5
3772 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
3773 if test "${cf_cv_xopen_source+set}" = set; then
3774 echo $ECHO_N "(cached) $ECHO_C" >&6
3777 cat >conftest.$ac_ext <<_ACEOF
3778 #line 3778 "configure"
3779 #include "confdefs.h"
3783 #include <sys/types.h>
3789 #ifndef _XOPEN_SOURCE
3796 rm -f conftest.$ac_objext
3797 if { (eval echo "$as_me:3797: \"$ac_compile\"") >&5
3798 (eval $ac_compile) 2>&5
3800 echo "$as_me:3800: \$? = $ac_status" >&5
3801 (exit $ac_status); } &&
3802 { ac_try='test -s conftest.$ac_objext'
3803 { (eval echo "$as_me:3803: \"$ac_try\"") >&5
3806 echo "$as_me:3806: \$? = $ac_status" >&5
3807 (exit $ac_status); }; }; then
3808 cf_cv_xopen_source=no
3810 echo "$as_me: failed program was:" >&5
3811 cat conftest.$ac_ext >&5
3813 CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
3814 cat >conftest.$ac_ext <<_ACEOF
3815 #line 3815 "configure"
3816 #include "confdefs.h"
3820 #include <sys/types.h>
3826 #ifdef _XOPEN_SOURCE
3833 rm -f conftest.$ac_objext
3834 if { (eval echo "$as_me:3834: \"$ac_compile\"") >&5
3835 (eval $ac_compile) 2>&5
3837 echo "$as_me:3837: \$? = $ac_status" >&5
3838 (exit $ac_status); } &&
3839 { ac_try='test -s conftest.$ac_objext'
3840 { (eval echo "$as_me:3840: \"$ac_try\"") >&5
3843 echo "$as_me:3843: \$? = $ac_status" >&5
3844 (exit $ac_status); }; }; then
3845 cf_cv_xopen_source=no
3847 echo "$as_me: failed program was:" >&5
3848 cat conftest.$ac_ext >&5
3849 cf_cv_xopen_source=$cf_XOPEN_SOURCE
3851 rm -f conftest.$ac_objext conftest.$ac_ext
3855 rm -f conftest.$ac_objext conftest.$ac_ext
3858 echo "$as_me:3858: result: $cf_cv_xopen_source" >&5
3859 echo "${ECHO_T}$cf_cv_xopen_source" >&6
3861 if test "$cf_cv_xopen_source" != no ; then
3863 CFLAGS=`echo "$CFLAGS" | \
3864 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3865 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
3867 CPPFLAGS=`echo "$CPPFLAGS" | \
3868 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3869 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
3871 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
3876 cf_new_extra_cppflags=
3878 for cf_add_cflags in $cf_temp_xopen_source
3880 case $cf_fix_cppflags in
3882 case $cf_add_cflags in #(vi
3883 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
3884 case $cf_add_cflags in
3886 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3888 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3889 && test -z "${cf_tst_cflags}" \
3890 && cf_fix_cppflags=yes
3892 if test $cf_fix_cppflags = yes ; then
3893 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3895 elif test "${cf_tst_cflags}" = "\"'" ; then
3896 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3902 *$cf_add_cflags) #(vi
3905 case $cf_add_cflags in #(vi
3907 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3909 CPPFLAGS=`echo "$CPPFLAGS" | \
3910 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3911 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3915 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
3920 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
3925 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3927 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
3929 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3930 && test -z "${cf_tst_cflags}" \
3931 && cf_fix_cppflags=no
3936 if test -n "$cf_new_cflags" ; then
3938 CFLAGS="$CFLAGS $cf_new_cflags"
3941 if test -n "$cf_new_cppflags" ; then
3943 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
3946 if test -n "$cf_new_extra_cppflags" ; then
3948 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
3956 echo "$as_me:3956: checking for signal global datatype" >&5
3957 echo $ECHO_N "checking for signal global datatype... $ECHO_C" >&6
3958 if test "${cf_cv_sig_atomic_t+set}" = set; then
3959 echo $ECHO_N "(cached) $ECHO_C" >&6
3963 "volatile sig_atomic_t" \
3967 cat >conftest.$ac_ext <<_ACEOF
3968 #line 3968 "configure"
3969 #include "confdefs.h"
3971 #include <sys/types.h>
3977 static void handler(int sig)
3984 signal(SIGINT, handler);
3990 rm -f conftest.$ac_objext
3991 if { (eval echo "$as_me:3991: \"$ac_compile\"") >&5
3992 (eval $ac_compile) 2>&5
3994 echo "$as_me:3994: \$? = $ac_status" >&5
3995 (exit $ac_status); } &&
3996 { ac_try='test -s conftest.$ac_objext'
3997 { (eval echo "$as_me:3997: \"$ac_try\"") >&5
4000 echo "$as_me:4000: \$? = $ac_status" >&5
4001 (exit $ac_status); }; }; then
4002 cf_cv_sig_atomic_t=$cf_type
4004 echo "$as_me: failed program was:" >&5
4005 cat conftest.$ac_ext >&5
4006 cf_cv_sig_atomic_t=no
4008 rm -f conftest.$ac_objext conftest.$ac_ext
4009 test "$cf_cv_sig_atomic_t" != no && break
4014 echo "$as_me:4014: result: $cf_cv_sig_atomic_t" >&5
4015 echo "${ECHO_T}$cf_cv_sig_atomic_t" >&6
4016 test "$cf_cv_sig_atomic_t" != no &&
4017 cat >>confdefs.h <<EOF
4018 #define SIG_ATOMIC_T $cf_cv_sig_atomic_t
4021 echo "$as_me:4021: checking if you want to use pkg-config" >&5
4022 echo $ECHO_N "checking if you want to use pkg-config... $ECHO_C" >&6
4024 # Check whether --with-pkg-config or --without-pkg-config was given.
4025 if test "${with_pkg_config+set}" = set; then
4026 withval="$with_pkg_config"
4027 cf_pkg_config=$withval
4031 echo "$as_me:4031: result: $cf_pkg_config" >&5
4032 echo "${ECHO_T}$cf_pkg_config" >&6
4034 case $cf_pkg_config in #(vi
4040 if test -n "$ac_tool_prefix"; then
4041 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
4042 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
4043 echo "$as_me:4043: checking for $ac_word" >&5
4044 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4045 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then
4046 echo $ECHO_N "(cached) $ECHO_C" >&6
4050 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
4053 ac_save_IFS=$IFS; IFS=$ac_path_separator
4055 for ac_dir in $ac_dummy; do
4057 test -z "$ac_dir" && ac_dir=.
4058 if $as_executable_p "$ac_dir/$ac_word"; then
4059 ac_cv_path_PKG_CONFIG="$ac_dir/$ac_word"
4060 echo "$as_me:4060: found $ac_dir/$ac_word" >&5
4068 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
4070 if test -n "$PKG_CONFIG"; then
4071 echo "$as_me:4071: result: $PKG_CONFIG" >&5
4072 echo "${ECHO_T}$PKG_CONFIG" >&6
4074 echo "$as_me:4074: result: no" >&5
4075 echo "${ECHO_T}no" >&6
4079 if test -z "$ac_cv_path_PKG_CONFIG"; then
4080 ac_pt_PKG_CONFIG=$PKG_CONFIG
4081 # Extract the first word of "pkg-config", so it can be a program name with args.
4082 set dummy pkg-config; ac_word=$2
4083 echo "$as_me:4083: checking for $ac_word" >&5
4084 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4085 if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then
4086 echo $ECHO_N "(cached) $ECHO_C" >&6
4088 case $ac_pt_PKG_CONFIG in
4090 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
4093 ac_save_IFS=$IFS; IFS=$ac_path_separator
4095 for ac_dir in $ac_dummy; do
4097 test -z "$ac_dir" && ac_dir=.
4098 if $as_executable_p "$ac_dir/$ac_word"; then
4099 ac_cv_path_ac_pt_PKG_CONFIG="$ac_dir/$ac_word"
4100 echo "$as_me:4100: found $ac_dir/$ac_word" >&5
4105 test -z "$ac_cv_path_ac_pt_PKG_CONFIG" && ac_cv_path_ac_pt_PKG_CONFIG="none"
4109 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
4111 if test -n "$ac_pt_PKG_CONFIG"; then
4112 echo "$as_me:4112: result: $ac_pt_PKG_CONFIG" >&5
4113 echo "${ECHO_T}$ac_pt_PKG_CONFIG" >&6
4115 echo "$as_me:4115: result: no" >&5
4116 echo "${ECHO_T}no" >&6
4119 PKG_CONFIG=$ac_pt_PKG_CONFIG
4121 PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
4130 test -z "$PKG_CONFIG" && PKG_CONFIG=none
4131 if test "$PKG_CONFIG" != none ; then
4133 if test "x$prefix" != xNONE; then
4134 cf_path_syntax="$prefix"
4136 cf_path_syntax="$ac_default_prefix"
4139 case ".$PKG_CONFIG" in #(vi
4140 .\$\(*\)*|.\'*\'*) #(vi
4144 .[a-zA-Z]:[\\/]*) #(vi OS/2 EMX
4146 .\${*prefix}*|.\${*dir}*) #(vi
4147 eval PKG_CONFIG="$PKG_CONFIG"
4148 case ".$PKG_CONFIG" in #(vi
4150 PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
4155 PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
4158 { { echo "$as_me:4158: error: expected a pathname, not \"$PKG_CONFIG\"" >&5
4159 echo "$as_me: error: expected a pathname, not \"$PKG_CONFIG\"" >&2;}
4160 { (exit 1); exit 1; }; }
4166 echo "$as_me:4166: checking if you want to see long compiling messages" >&5
4167 echo $ECHO_N "checking if you want to see long compiling messages... $ECHO_C" >&6
4169 # Check whether --enable-echo or --disable-echo was given.
4170 if test "${enable_echo+set}" = set; then
4171 enableval="$enable_echo"
4172 test "$enableval" != no && enableval=yes
4173 if test "$enableval" != "yes" ; then
4176 ECHO_LD='@echo linking $@;'
4177 RULE_CC='@echo compiling $<'
4178 SHOW_CC='@echo compiling $@'
4200 echo "$as_me:4200: result: $enableval" >&5
4201 echo "${ECHO_T}$enableval" >&6
4203 echo "$as_me:4203: checking for ncurses wrap-prefix" >&5
4204 echo $ECHO_N "checking for ncurses wrap-prefix... $ECHO_C" >&6
4206 # Check whether --with-ncurses-wrap-prefix or --without-ncurses-wrap-prefix was given.
4207 if test "${with_ncurses_wrap_prefix+set}" = set; then
4208 withval="$with_ncurses_wrap_prefix"
4209 NCURSES_WRAP_PREFIX=$withval
4211 NCURSES_WRAP_PREFIX=_nc_
4213 echo "$as_me:4213: result: $NCURSES_WRAP_PREFIX" >&5
4214 echo "${ECHO_T}$NCURSES_WRAP_PREFIX" >&6
4216 echo "$as_me:4216: checking if you want to check for wide-character functions" >&5
4217 echo $ECHO_N "checking if you want to check for wide-character functions... $ECHO_C" >&6
4219 # Check whether --enable-widec or --disable-widec was given.
4220 if test "${enable_widec+set}" = set; then
4221 enableval="$enable_widec"
4222 test "$enableval" != no && enableval=yes
4223 if test "$enableval" != "yes" ; then
4233 echo "$as_me:4233: result: $cf_enable_widec" >&5
4234 echo "${ECHO_T}$cf_enable_widec" >&6
4236 echo "$as_me:4236: checking for specific curses-directory" >&5
4237 echo $ECHO_N "checking for specific curses-directory... $ECHO_C" >&6
4239 # Check whether --with-curses-dir or --without-curses-dir was given.
4240 if test "${with_curses_dir+set}" = set; then
4241 withval="$with_curses_dir"
4242 cf_cv_curses_dir=$withval
4246 echo "$as_me:4246: result: $cf_cv_curses_dir" >&5
4247 echo "${ECHO_T}$cf_cv_curses_dir" >&6
4249 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
4252 if test "x$prefix" != xNONE; then
4253 cf_path_syntax="$prefix"
4255 cf_path_syntax="$ac_default_prefix"
4258 case ".$withval" in #(vi
4259 .\$\(*\)*|.\'*\'*) #(vi
4263 .[a-zA-Z]:[\\/]*) #(vi OS/2 EMX
4265 .\${*prefix}*|.\${*dir}*) #(vi
4266 eval withval="$withval"
4267 case ".$withval" in #(vi
4269 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
4274 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
4277 { { echo "$as_me:4277: error: expected a pathname, not \"$withval\"" >&5
4278 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
4279 { (exit 1); exit 1; }; }
4283 if test -d "$cf_cv_curses_dir"
4286 if test -n "$cf_cv_curses_dir/include" ; then
4287 for cf_add_incdir in $cf_cv_curses_dir/include
4289 while test $cf_add_incdir != /usr/include
4291 if test -d $cf_add_incdir
4294 if test -n "$CFLAGS$CPPFLAGS" ; then
4295 # a loop is needed to ensure we can add subdirs of existing dirs
4296 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
4297 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
4298 cf_have_incdir=yes; break
4303 if test "$cf_have_incdir" = no ; then
4304 if test "$cf_add_incdir" = /usr/local/include ; then
4305 if test "$GCC" = yes
4307 cf_save_CPPFLAGS=$CPPFLAGS
4308 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
4309 cat >conftest.$ac_ext <<_ACEOF
4310 #line 4310 "configure"
4311 #include "confdefs.h"
4321 rm -f conftest.$ac_objext
4322 if { (eval echo "$as_me:4322: \"$ac_compile\"") >&5
4323 (eval $ac_compile) 2>&5
4325 echo "$as_me:4325: \$? = $ac_status" >&5
4326 (exit $ac_status); } &&
4327 { ac_try='test -s conftest.$ac_objext'
4328 { (eval echo "$as_me:4328: \"$ac_try\"") >&5
4331 echo "$as_me:4331: \$? = $ac_status" >&5
4332 (exit $ac_status); }; }; then
4335 echo "$as_me: failed program was:" >&5
4336 cat conftest.$ac_ext >&5
4339 rm -f conftest.$ac_objext conftest.$ac_ext
4340 CPPFLAGS=$cf_save_CPPFLAGS
4345 if test "$cf_have_incdir" = no ; then
4346 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
4348 echo "${as_me:-configure}:4348: testing adding $cf_add_incdir to include-path ..." 1>&5
4350 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
4352 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
4353 test "$cf_top_incdir" = "$cf_add_incdir" && break
4354 cf_add_incdir="$cf_top_incdir"
4363 if test -n "$cf_cv_curses_dir/lib" ; then
4364 for cf_add_libdir in $cf_cv_curses_dir/lib
4366 if test $cf_add_libdir = /usr/lib ; then
4368 elif test -d $cf_add_libdir
4371 if test -n "$LDFLAGS$LIBS" ; then
4372 # a loop is needed to ensure we can add subdirs of existing dirs
4373 for cf_test_libdir in $LDFLAGS $LIBS ; do
4374 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
4375 cf_have_libdir=yes; break
4379 if test "$cf_have_libdir" = no ; then
4380 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
4382 echo "${as_me:-configure}:4382: testing adding $cf_add_libdir to library-path ..." 1>&5
4384 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
4395 echo "$as_me:4395: checking for specified curses library type" >&5
4396 echo $ECHO_N "checking for specified curses library type... $ECHO_C" >&6
4398 # Check whether --with-ncursesw or --without-ncursesw was given.
4399 if test "${with_ncursesw+set}" = set; then
4400 withval="$with_ncursesw"
4401 cf_cv_screen=ncursesw
4404 # Check whether --with-ncurses or --without-ncurses was given.
4405 if test "${with_ncurses+set}" = set; then
4406 withval="$with_ncurses"
4407 cf_cv_screen=ncurses
4410 # Check whether --with-pdcurses or --without-pdcurses was given.
4411 if test "${with_pdcurses+set}" = set; then
4412 withval="$with_pdcurses"
4413 cf_cv_screen=pdcurses
4416 # Check whether --with-curses-colr or --without-curses-colr was given.
4417 if test "${with_curses_colr+set}" = set; then
4418 withval="$with_curses_colr"
4419 cf_cv_screen=curses_colr
4422 # Check whether --with-curses-5lib or --without-curses-5lib was given.
4423 if test "${with_curses_5lib+set}" = set; then
4424 withval="$with_curses_5lib"
4425 cf_cv_screen=curses_5lib
4432 echo "$as_me:4432: result: $cf_cv_screen" >&5
4433 echo "${ECHO_T}$cf_cv_screen" >&6
4435 case $cf_cv_screen in #(vi
4436 curses|curses_*) #(vi
4438 echo "$as_me:4438: checking for extra include directories" >&5
4439 echo $ECHO_N "checking for extra include directories... $ECHO_C" >&6
4440 if test "${cf_cv_curses_incdir+set}" = set; then
4441 echo $ECHO_N "(cached) $ECHO_C" >&6
4444 cf_cv_curses_incdir=no
4445 case $host_os in #(vi
4447 if test "x$cf_cv_screen" = "xcurses_colr"
4449 test -d /usr/include/curses_colr && \
4450 cf_cv_curses_incdir="-I/usr/include/curses_colr"
4454 if test "x$cf_cv_screen" = "xcurses_5lib"
4456 test -d /usr/5lib && \
4457 test -d /usr/5include && \
4458 cf_cv_curses_incdir="-I/usr/5include"
4464 echo "$as_me:4464: result: $cf_cv_curses_incdir" >&5
4465 echo "${ECHO_T}$cf_cv_curses_incdir" >&6
4466 test "$cf_cv_curses_incdir" != no && CPPFLAGS="$CPPFLAGS $cf_cv_curses_incdir"
4468 echo "$as_me:4468: checking if we have identified curses headers" >&5
4469 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
4470 if test "${cf_cv_ncurses_header+set}" = set; then
4471 echo $ECHO_N "(cached) $ECHO_C" >&6
4474 cf_cv_ncurses_header=none
4477 curses.h ncurses/ncurses.h ncurses/curses.h
4479 cat >conftest.$ac_ext <<_ACEOF
4480 #line 4480 "configure"
4481 #include "confdefs.h"
4482 #include <${cf_header}>
4486 initscr(); tgoto("?", 0,0)
4491 rm -f conftest.$ac_objext
4492 if { (eval echo "$as_me:4492: \"$ac_compile\"") >&5
4493 (eval $ac_compile) 2>&5
4495 echo "$as_me:4495: \$? = $ac_status" >&5
4496 (exit $ac_status); } &&
4497 { ac_try='test -s conftest.$ac_objext'
4498 { (eval echo "$as_me:4498: \"$ac_try\"") >&5
4501 echo "$as_me:4501: \$? = $ac_status" >&5
4502 (exit $ac_status); }; }; then
4503 cf_cv_ncurses_header=$cf_header; break
4505 echo "$as_me: failed program was:" >&5
4506 cat conftest.$ac_ext >&5
4508 rm -f conftest.$ac_objext conftest.$ac_ext
4512 echo "$as_me:4512: result: $cf_cv_ncurses_header" >&5
4513 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
4515 if test "$cf_cv_ncurses_header" = none ; then
4516 { { echo "$as_me:4516: error: No curses header-files found" >&5
4517 echo "$as_me: error: No curses header-files found" >&2;}
4518 { (exit 1); exit 1; }; }
4521 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
4523 for ac_header in $cf_cv_ncurses_header
4525 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
4526 echo "$as_me:4526: checking for $ac_header" >&5
4527 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4528 if eval "test \"\${$as_ac_Header+set}\" = set"; then
4529 echo $ECHO_N "(cached) $ECHO_C" >&6
4531 cat >conftest.$ac_ext <<_ACEOF
4532 #line 4532 "configure"
4533 #include "confdefs.h"
4534 #include <$ac_header>
4536 if { (eval echo "$as_me:4536: \"$ac_cpp conftest.$ac_ext\"") >&5
4537 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4539 egrep -v '^ *\+' conftest.er1 >conftest.err
4541 cat conftest.err >&5
4542 echo "$as_me:4542: \$? = $ac_status" >&5
4543 (exit $ac_status); } >/dev/null; then
4544 if test -s conftest.err; then
4545 ac_cpp_err=$ac_c_preproc_warn_flag
4552 if test -z "$ac_cpp_err"; then
4553 eval "$as_ac_Header=yes"
4555 echo "$as_me: failed program was:" >&5
4556 cat conftest.$ac_ext >&5
4557 eval "$as_ac_Header=no"
4559 rm -f conftest.err conftest.$ac_ext
4561 echo "$as_me:4561: result: `eval echo '${'$as_ac_Header'}'`" >&5
4562 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4563 if test `eval echo '${'$as_ac_Header'}'` = yes; then
4564 cat >>confdefs.h <<EOF
4565 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
4571 echo "$as_me:4571: checking for terminfo header" >&5
4572 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
4573 if test "${cf_cv_term_header+set}" = set; then
4574 echo $ECHO_N "(cached) $ECHO_C" >&6
4577 case ${cf_cv_ncurses_header} in #(vi
4578 */ncurses.h|*/ncursesw.h) #(vi
4579 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
4582 cf_term_header=term.h
4586 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
4588 cat >conftest.$ac_ext <<_ACEOF
4589 #line 4589 "configure"
4590 #include "confdefs.h"
4592 #include <${cf_cv_ncurses_header:-curses.h}>
4598 int x = auto_left_margin
4603 rm -f conftest.$ac_objext
4604 if { (eval echo "$as_me:4604: \"$ac_compile\"") >&5
4605 (eval $ac_compile) 2>&5
4607 echo "$as_me:4607: \$? = $ac_status" >&5
4608 (exit $ac_status); } &&
4609 { ac_try='test -s conftest.$ac_objext'
4610 { (eval echo "$as_me:4610: \"$ac_try\"") >&5
4613 echo "$as_me:4613: \$? = $ac_status" >&5
4614 (exit $ac_status); }; }; then
4616 cf_cv_term_header="$cf_test"
4618 echo "$as_me: failed program was:" >&5
4619 cat conftest.$ac_ext >&5
4621 cf_cv_term_header=unknown
4624 rm -f conftest.$ac_objext conftest.$ac_ext
4625 test "$cf_cv_term_header" != unknown && break
4629 echo "$as_me:4629: result: $cf_cv_term_header" >&5
4630 echo "${ECHO_T}$cf_cv_term_header" >&6
4632 # Set definitions to allow ifdef'ing to accommodate subdirectories
4634 case $cf_cv_term_header in # (vi
4637 cat >>confdefs.h <<\EOF
4638 #define HAVE_TERM_H 1
4644 case $cf_cv_term_header in # (vi
4645 ncurses/term.h) #(vi
4647 cat >>confdefs.h <<\EOF
4648 #define HAVE_NCURSES_TERM_H 1
4654 cat >>confdefs.h <<\EOF
4655 #define HAVE_NCURSESW_TERM_H 1
4661 echo "$as_me:4661: checking for ncurses version" >&5
4662 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
4663 if test "${cf_cv_ncurses_version+set}" = set; then
4664 echo $ECHO_N "(cached) $ECHO_C" >&6
4667 cf_cv_ncurses_version=no
4670 if test "$cross_compiling" = yes; then
4672 # This will not work if the preprocessor splits the line after the
4673 # Autoconf token. The 'unproto' program does that.
4674 cat > conftest.$ac_ext <<EOF
4675 #include <${cf_cv_ncurses_header:-curses.h}>
4677 #ifdef NCURSES_VERSION
4678 Autoconf NCURSES_VERSION
4686 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
4687 { (eval echo "$as_me:4687: \"$cf_try\"") >&5
4690 echo "$as_me:4690: \$? = $ac_status" >&5
4691 (exit $ac_status); }
4692 if test -f conftest.out ; then
4693 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
4694 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
4699 cat >conftest.$ac_ext <<_ACEOF
4700 #line 4700 "configure"
4701 #include "confdefs.h"
4703 #include <${cf_cv_ncurses_header:-curses.h}>
4707 FILE *fp = fopen("$cf_tempfile", "w");
4708 #ifdef NCURSES_VERSION
4709 # ifdef NCURSES_VERSION_PATCH
4710 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
4712 fprintf(fp, "%s\n", NCURSES_VERSION);
4716 fprintf(fp, "old\n");
4721 ${cf_cv_main_return:-return}(0);
4724 rm -f conftest$ac_exeext
4725 if { (eval echo "$as_me:4725: \"$ac_link\"") >&5
4726 (eval $ac_link) 2>&5
4728 echo "$as_me:4728: \$? = $ac_status" >&5
4729 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4730 { (eval echo "$as_me:4730: \"$ac_try\"") >&5
4733 echo "$as_me:4733: \$? = $ac_status" >&5
4734 (exit $ac_status); }; }; then
4736 cf_cv_ncurses_version=`cat $cf_tempfile`
4738 echo "$as_me: program exited with status $ac_status" >&5
4739 echo "$as_me: failed program was:" >&5
4740 cat conftest.$ac_ext >&5
4742 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
4747 echo "$as_me:4747: result: $cf_cv_ncurses_version" >&5
4748 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
4749 test "$cf_cv_ncurses_version" = no ||
4750 cat >>confdefs.h <<\EOF
4754 echo "$as_me:4754: checking if we have identified curses libraries" >&5
4755 echo $ECHO_N "checking if we have identified curses libraries... $ECHO_C" >&6
4756 cat >conftest.$ac_ext <<_ACEOF
4757 #line 4757 "configure"
4758 #include "confdefs.h"
4759 #include <${cf_cv_ncurses_header:-curses.h}>
4763 initscr(); tgoto("?", 0,0)
4768 rm -f conftest.$ac_objext conftest$ac_exeext
4769 if { (eval echo "$as_me:4769: \"$ac_link\"") >&5
4770 (eval $ac_link) 2>&5
4772 echo "$as_me:4772: \$? = $ac_status" >&5
4773 (exit $ac_status); } &&
4774 { ac_try='test -s conftest$ac_exeext'
4775 { (eval echo "$as_me:4775: \"$ac_try\"") >&5
4778 echo "$as_me:4778: \$? = $ac_status" >&5
4779 (exit $ac_status); }; }; then
4782 echo "$as_me: failed program was:" >&5
4783 cat conftest.$ac_ext >&5
4786 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4787 echo "$as_me:4787: result: $cf_result" >&5
4788 echo "${ECHO_T}$cf_result" >&6
4790 if test "$cf_result" = no ; then
4791 case $host_os in #(vi
4793 echo "$as_me:4793: checking for tgoto in -lmytinfo" >&5
4794 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
4795 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
4796 echo $ECHO_N "(cached) $ECHO_C" >&6
4798 ac_check_lib_save_LIBS=$LIBS
4799 LIBS="-lmytinfo $LIBS"
4800 cat >conftest.$ac_ext <<_ACEOF
4801 #line 4801 "configure"
4802 #include "confdefs.h"
4804 /* Override any gcc2 internal prototype to avoid an error. */
4808 /* We use char because int might match the return type of a gcc2
4809 builtin and then its argument prototype would still apply. */
4819 rm -f conftest.$ac_objext conftest$ac_exeext
4820 if { (eval echo "$as_me:4820: \"$ac_link\"") >&5
4821 (eval $ac_link) 2>&5
4823 echo "$as_me:4823: \$? = $ac_status" >&5
4824 (exit $ac_status); } &&
4825 { ac_try='test -s conftest$ac_exeext'
4826 { (eval echo "$as_me:4826: \"$ac_try\"") >&5
4829 echo "$as_me:4829: \$? = $ac_status" >&5
4830 (exit $ac_status); }; }; then
4831 ac_cv_lib_mytinfo_tgoto=yes
4833 echo "$as_me: failed program was:" >&5
4834 cat conftest.$ac_ext >&5
4835 ac_cv_lib_mytinfo_tgoto=no
4837 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4838 LIBS=$ac_check_lib_save_LIBS
4840 echo "$as_me:4840: result: $ac_cv_lib_mytinfo_tgoto" >&5
4841 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
4842 if test $ac_cv_lib_mytinfo_tgoto = yes; then
4844 cf_add_libs="-lmytinfo"
4845 # Filter out duplicates - this happens with badly-designed ".pc" files...
4846 for cf_add_1lib in $LIBS
4848 for cf_add_2lib in $cf_add_libs
4850 if test "x$cf_add_1lib" = "x$cf_add_2lib"
4856 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
4864 # Looking at HPUX 10.20, the Hcurses library is the oldest (1997), cur_colr
4865 # next (1998), and xcurses "newer" (2000). There is no header file for
4866 # Hcurses; the subdirectory curses_colr has the headers (curses.h and
4867 # term.h) for cur_colr
4868 if test "x$cf_cv_screen" = "xcurses_colr"
4870 echo "$as_me:4870: checking for initscr in -lcur_colr" >&5
4871 echo $ECHO_N "checking for initscr in -lcur_colr... $ECHO_C" >&6
4872 if test "${ac_cv_lib_cur_colr_initscr+set}" = set; then
4873 echo $ECHO_N "(cached) $ECHO_C" >&6
4875 ac_check_lib_save_LIBS=$LIBS
4876 LIBS="-lcur_colr $LIBS"
4877 cat >conftest.$ac_ext <<_ACEOF
4878 #line 4878 "configure"
4879 #include "confdefs.h"
4881 /* Override any gcc2 internal prototype to avoid an error. */
4885 /* We use char because int might match the return type of a gcc2
4886 builtin and then its argument prototype would still apply. */
4896 rm -f conftest.$ac_objext conftest$ac_exeext
4897 if { (eval echo "$as_me:4897: \"$ac_link\"") >&5
4898 (eval $ac_link) 2>&5
4900 echo "$as_me:4900: \$? = $ac_status" >&5
4901 (exit $ac_status); } &&
4902 { ac_try='test -s conftest$ac_exeext'
4903 { (eval echo "$as_me:4903: \"$ac_try\"") >&5
4906 echo "$as_me:4906: \$? = $ac_status" >&5
4907 (exit $ac_status); }; }; then
4908 ac_cv_lib_cur_colr_initscr=yes
4910 echo "$as_me: failed program was:" >&5
4911 cat conftest.$ac_ext >&5
4912 ac_cv_lib_cur_colr_initscr=no
4914 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4915 LIBS=$ac_check_lib_save_LIBS
4917 echo "$as_me:4917: result: $ac_cv_lib_cur_colr_initscr" >&5
4918 echo "${ECHO_T}$ac_cv_lib_cur_colr_initscr" >&6
4919 if test $ac_cv_lib_cur_colr_initscr = yes; then
4921 cf_add_libs="-lcur_colr"
4922 # Filter out duplicates - this happens with badly-designed ".pc" files...
4923 for cf_add_1lib in $LIBS
4925 for cf_add_2lib in $cf_add_libs
4927 if test "x$cf_add_1lib" = "x$cf_add_2lib"
4933 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
4937 ac_cv_func_initscr=yes
4941 echo "$as_me:4941: checking for initscr in -lHcurses" >&5
4942 echo $ECHO_N "checking for initscr in -lHcurses... $ECHO_C" >&6
4943 if test "${ac_cv_lib_Hcurses_initscr+set}" = set; then
4944 echo $ECHO_N "(cached) $ECHO_C" >&6
4946 ac_check_lib_save_LIBS=$LIBS
4947 LIBS="-lHcurses $LIBS"
4948 cat >conftest.$ac_ext <<_ACEOF
4949 #line 4949 "configure"
4950 #include "confdefs.h"
4952 /* Override any gcc2 internal prototype to avoid an error. */
4956 /* We use char because int might match the return type of a gcc2
4957 builtin and then its argument prototype would still apply. */
4967 rm -f conftest.$ac_objext conftest$ac_exeext
4968 if { (eval echo "$as_me:4968: \"$ac_link\"") >&5
4969 (eval $ac_link) 2>&5
4971 echo "$as_me:4971: \$? = $ac_status" >&5
4972 (exit $ac_status); } &&
4973 { ac_try='test -s conftest$ac_exeext'
4974 { (eval echo "$as_me:4974: \"$ac_try\"") >&5
4977 echo "$as_me:4977: \$? = $ac_status" >&5
4978 (exit $ac_status); }; }; then
4979 ac_cv_lib_Hcurses_initscr=yes
4981 echo "$as_me: failed program was:" >&5
4982 cat conftest.$ac_ext >&5
4983 ac_cv_lib_Hcurses_initscr=no
4985 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4986 LIBS=$ac_check_lib_save_LIBS
4988 echo "$as_me:4988: result: $ac_cv_lib_Hcurses_initscr" >&5
4989 echo "${ECHO_T}$ac_cv_lib_Hcurses_initscr" >&6
4990 if test $ac_cv_lib_Hcurses_initscr = yes; then
4992 # HP's header uses __HP_CURSES, but user claims _HP_CURSES.
4994 cf_add_libs="-lHcurses"
4995 # Filter out duplicates - this happens with badly-designed ".pc" files...
4996 for cf_add_1lib in $LIBS
4998 for cf_add_2lib in $cf_add_libs
5000 if test "x$cf_add_1lib" = "x$cf_add_2lib"
5006 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
5010 CPPFLAGS="$CPPFLAGS -D__HP_CURSES -D_HP_CURSES"
5011 ac_cv_func_initscr=yes
5020 case `arch 2>/dev/null` in
5025 if test -n "/lib64" ; then
5026 for cf_add_libdir in /lib64
5028 if test $cf_add_libdir = /usr/lib ; then
5030 elif test -d $cf_add_libdir
5033 if test -n "$LDFLAGS$LIBS" ; then
5034 # a loop is needed to ensure we can add subdirs of existing dirs
5035 for cf_test_libdir in $LDFLAGS $LIBS ; do
5036 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
5037 cf_have_libdir=yes; break
5041 if test "$cf_have_libdir" = no ; then
5042 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
5044 echo "${as_me:-configure}:5044: testing adding $cf_add_libdir to library-path ..." 1>&5
5046 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
5054 if test -n "/lib" ; then
5055 for cf_add_libdir in /lib
5057 if test $cf_add_libdir = /usr/lib ; then
5059 elif test -d $cf_add_libdir
5062 if test -n "$LDFLAGS$LIBS" ; then
5063 # a loop is needed to ensure we can add subdirs of existing dirs
5064 for cf_test_libdir in $LDFLAGS $LIBS ; do
5065 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
5066 cf_have_libdir=yes; break
5070 if test "$cf_have_libdir" = no ; then
5071 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
5073 echo "${as_me:-configure}:5073: testing adding $cf_add_libdir to library-path ..." 1>&5
5075 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
5085 if test -n "/lib" ; then
5086 for cf_add_libdir in /lib
5088 if test $cf_add_libdir = /usr/lib ; then
5090 elif test -d $cf_add_libdir
5093 if test -n "$LDFLAGS$LIBS" ; then
5094 # a loop is needed to ensure we can add subdirs of existing dirs
5095 for cf_test_libdir in $LDFLAGS $LIBS ; do
5096 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
5097 cf_have_libdir=yes; break
5101 if test "$cf_have_libdir" = no ; then
5102 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
5104 echo "${as_me:-configure}:5104: testing adding $cf_add_libdir to library-path ..." 1>&5
5106 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
5116 if test "x$cf_cv_screen" = "xcurses_5lib"
5118 if test -d /usr/5lib ; then
5120 if test -n "/usr/5lib" ; then
5121 for cf_add_libdir in /usr/5lib
5123 if test $cf_add_libdir = /usr/lib ; then
5125 elif test -d $cf_add_libdir
5128 if test -n "$LDFLAGS$LIBS" ; then
5129 # a loop is needed to ensure we can add subdirs of existing dirs
5130 for cf_test_libdir in $LDFLAGS $LIBS ; do
5131 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
5132 cf_have_libdir=yes; break
5136 if test "$cf_have_libdir" = no ; then
5137 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
5139 echo "${as_me:-configure}:5139: testing adding $cf_add_libdir to library-path ..." 1>&5
5141 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
5147 cf_add_libs="-lcurses -ltermcap"
5148 # Filter out duplicates - this happens with badly-designed ".pc" files...
5149 for cf_add_1lib in $LIBS
5151 for cf_add_2lib in $cf_add_libs
5153 if test "x$cf_add_1lib" = "x$cf_add_2lib"
5159 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
5165 ac_cv_func_initscr=yes
5169 if test ".$ac_cv_func_initscr" != .yes ; then
5170 cf_save_LIBS="$LIBS"
5172 if test ".${cf_cv_ncurses_version:-no}" != .no
5174 cf_check_list="ncurses curses cursesX"
5176 cf_check_list="cursesX curses ncurses"
5179 # Check for library containing tgoto. Do this before curses library
5180 # because it may be needed to link the test-case for initscr.
5181 if test "x$cf_term_lib" = x
5183 echo "$as_me:5183: checking for tgoto" >&5
5184 echo $ECHO_N "checking for tgoto... $ECHO_C" >&6
5185 if test "${ac_cv_func_tgoto+set}" = set; then
5186 echo $ECHO_N "(cached) $ECHO_C" >&6
5188 cat >conftest.$ac_ext <<_ACEOF
5189 #line 5189 "configure"
5190 #include "confdefs.h"
5191 /* System header to define __stub macros and hopefully few prototypes,
5192 which can conflict with char tgoto (); below. */
5194 /* Override any gcc2 internal prototype to avoid an error. */
5198 /* We use char because int might match the return type of a gcc2
5199 builtin and then its argument prototype would still apply. */
5206 /* The GNU C library defines this for functions which it implements
5207 to always fail with ENOSYS. Some functions are actually named
5208 something starting with __ and the normal name is an alias. */
5209 #if defined (__stub_tgoto) || defined (__stub___tgoto)
5212 f = tgoto; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
5219 rm -f conftest.$ac_objext conftest$ac_exeext
5220 if { (eval echo "$as_me:5220: \"$ac_link\"") >&5
5221 (eval $ac_link) 2>&5
5223 echo "$as_me:5223: \$? = $ac_status" >&5
5224 (exit $ac_status); } &&
5225 { ac_try='test -s conftest$ac_exeext'
5226 { (eval echo "$as_me:5226: \"$ac_try\"") >&5
5229 echo "$as_me:5229: \$? = $ac_status" >&5
5230 (exit $ac_status); }; }; then
5231 ac_cv_func_tgoto=yes
5233 echo "$as_me: failed program was:" >&5
5234 cat conftest.$ac_ext >&5
5237 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5239 echo "$as_me:5239: result: $ac_cv_func_tgoto" >&5
5240 echo "${ECHO_T}$ac_cv_func_tgoto" >&6
5241 if test $ac_cv_func_tgoto = yes; then
5242 cf_term_lib=predefined
5245 for cf_term_lib in $cf_check_list otermcap termcap tinfo termlib unknown
5247 as_ac_Lib=`echo "ac_cv_lib_$cf_term_lib''_tgoto" | $as_tr_sh`
5248 echo "$as_me:5248: checking for tgoto in -l$cf_term_lib" >&5
5249 echo $ECHO_N "checking for tgoto in -l$cf_term_lib... $ECHO_C" >&6
5250 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
5251 echo $ECHO_N "(cached) $ECHO_C" >&6
5253 ac_check_lib_save_LIBS=$LIBS
5254 LIBS="-l$cf_term_lib $LIBS"
5255 cat >conftest.$ac_ext <<_ACEOF
5256 #line 5256 "configure"
5257 #include "confdefs.h"
5259 /* Override any gcc2 internal prototype to avoid an error. */
5263 /* We use char because int might match the return type of a gcc2
5264 builtin and then its argument prototype would still apply. */
5274 rm -f conftest.$ac_objext conftest$ac_exeext
5275 if { (eval echo "$as_me:5275: \"$ac_link\"") >&5
5276 (eval $ac_link) 2>&5
5278 echo "$as_me:5278: \$? = $ac_status" >&5
5279 (exit $ac_status); } &&
5280 { ac_try='test -s conftest$ac_exeext'
5281 { (eval echo "$as_me:5281: \"$ac_try\"") >&5
5284 echo "$as_me:5284: \$? = $ac_status" >&5
5285 (exit $ac_status); }; }; then
5286 eval "$as_ac_Lib=yes"
5288 echo "$as_me: failed program was:" >&5
5289 cat conftest.$ac_ext >&5
5290 eval "$as_ac_Lib=no"
5292 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5293 LIBS=$ac_check_lib_save_LIBS
5295 echo "$as_me:5295: result: `eval echo '${'$as_ac_Lib'}'`" >&5
5296 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
5297 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
5307 # Check for library containing initscr
5308 test "$cf_term_lib" != predefined && test "$cf_term_lib" != unknown && LIBS="-l$cf_term_lib $cf_save_LIBS"
5309 if test "x$cf_curs_lib" = x
5311 for cf_curs_lib in $cf_check_list xcurses jcurses pdcurses unknown
5313 as_ac_Lib=`echo "ac_cv_lib_$cf_curs_lib''_initscr" | $as_tr_sh`
5314 echo "$as_me:5314: checking for initscr in -l$cf_curs_lib" >&5
5315 echo $ECHO_N "checking for initscr in -l$cf_curs_lib... $ECHO_C" >&6
5316 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
5317 echo $ECHO_N "(cached) $ECHO_C" >&6
5319 ac_check_lib_save_LIBS=$LIBS
5320 LIBS="-l$cf_curs_lib $LIBS"
5321 cat >conftest.$ac_ext <<_ACEOF
5322 #line 5322 "configure"
5323 #include "confdefs.h"
5325 /* Override any gcc2 internal prototype to avoid an error. */
5329 /* We use char because int might match the return type of a gcc2
5330 builtin and then its argument prototype would still apply. */
5340 rm -f conftest.$ac_objext conftest$ac_exeext
5341 if { (eval echo "$as_me:5341: \"$ac_link\"") >&5
5342 (eval $ac_link) 2>&5
5344 echo "$as_me:5344: \$? = $ac_status" >&5
5345 (exit $ac_status); } &&
5346 { ac_try='test -s conftest$ac_exeext'
5347 { (eval echo "$as_me:5347: \"$ac_try\"") >&5
5350 echo "$as_me:5350: \$? = $ac_status" >&5
5351 (exit $ac_status); }; }; then
5352 eval "$as_ac_Lib=yes"
5354 echo "$as_me: failed program was:" >&5
5355 cat conftest.$ac_ext >&5
5356 eval "$as_ac_Lib=no"
5358 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5359 LIBS=$ac_check_lib_save_LIBS
5361 echo "$as_me:5361: result: `eval echo '${'$as_ac_Lib'}'`" >&5
5362 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
5363 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
5369 test $cf_curs_lib = unknown && { { echo "$as_me:5369: error: no curses library found" >&5
5370 echo "$as_me: error: no curses library found" >&2;}
5371 { (exit 1); exit 1; }; }
5373 LIBS="-l$cf_curs_lib $cf_save_LIBS"
5374 if test "$cf_term_lib" = unknown ; then
5375 echo "$as_me:5375: checking if we can link with $cf_curs_lib library" >&5
5376 echo $ECHO_N "checking if we can link with $cf_curs_lib library... $ECHO_C" >&6
5377 cat >conftest.$ac_ext <<_ACEOF
5378 #line 5378 "configure"
5379 #include "confdefs.h"
5380 #include <${cf_cv_ncurses_header:-curses.h}>
5389 rm -f conftest.$ac_objext conftest$ac_exeext
5390 if { (eval echo "$as_me:5390: \"$ac_link\"") >&5
5391 (eval $ac_link) 2>&5
5393 echo "$as_me:5393: \$? = $ac_status" >&5
5394 (exit $ac_status); } &&
5395 { ac_try='test -s conftest$ac_exeext'
5396 { (eval echo "$as_me:5396: \"$ac_try\"") >&5
5399 echo "$as_me:5399: \$? = $ac_status" >&5
5400 (exit $ac_status); }; }; then
5403 echo "$as_me: failed program was:" >&5
5404 cat conftest.$ac_ext >&5
5407 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5408 echo "$as_me:5408: result: $cf_result" >&5
5409 echo "${ECHO_T}$cf_result" >&6
5410 test $cf_result = no && { { echo "$as_me:5410: error: Cannot link curses library" >&5
5411 echo "$as_me: error: Cannot link curses library" >&2;}
5412 { (exit 1); exit 1; }; }
5413 elif test "$cf_curs_lib" = "$cf_term_lib" ; then
5415 elif test "$cf_term_lib" != predefined ; then
5416 echo "$as_me:5416: checking if we need both $cf_curs_lib and $cf_term_lib libraries" >&5
5417 echo $ECHO_N "checking if we need both $cf_curs_lib and $cf_term_lib libraries... $ECHO_C" >&6
5418 cat >conftest.$ac_ext <<_ACEOF
5419 #line 5419 "configure"
5420 #include "confdefs.h"
5421 #include <${cf_cv_ncurses_header:-curses.h}>
5425 initscr(); tgoto((char *)0, 0, 0);
5430 rm -f conftest.$ac_objext conftest$ac_exeext
5431 if { (eval echo "$as_me:5431: \"$ac_link\"") >&5
5432 (eval $ac_link) 2>&5
5434 echo "$as_me:5434: \$? = $ac_status" >&5
5435 (exit $ac_status); } &&
5436 { ac_try='test -s conftest$ac_exeext'
5437 { (eval echo "$as_me:5437: \"$ac_try\"") >&5
5440 echo "$as_me:5440: \$? = $ac_status" >&5
5441 (exit $ac_status); }; }; then
5444 echo "$as_me: failed program was:" >&5
5445 cat conftest.$ac_ext >&5
5447 LIBS="-l$cf_curs_lib -l$cf_term_lib $cf_save_LIBS"
5448 cat >conftest.$ac_ext <<_ACEOF
5449 #line 5449 "configure"
5450 #include "confdefs.h"
5451 #include <${cf_cv_ncurses_header:-curses.h}>
5460 rm -f conftest.$ac_objext conftest$ac_exeext
5461 if { (eval echo "$as_me:5461: \"$ac_link\"") >&5
5462 (eval $ac_link) 2>&5
5464 echo "$as_me:5464: \$? = $ac_status" >&5
5465 (exit $ac_status); } &&
5466 { ac_try='test -s conftest$ac_exeext'
5467 { (eval echo "$as_me:5467: \"$ac_try\"") >&5
5470 echo "$as_me:5470: \$? = $ac_status" >&5
5471 (exit $ac_status); }; }; then
5474 echo "$as_me: failed program was:" >&5
5475 cat conftest.$ac_ext >&5
5478 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5481 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5482 echo "$as_me:5482: result: $cf_result" >&5
5483 echo "${ECHO_T}$cf_result" >&6
5491 cf_ncuconfig_root=ncurses
5493 echo "Looking for ${cf_ncuconfig_root}-config"
5495 if test -n "$ac_tool_prefix"; then
5496 for ac_prog in ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
5498 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
5499 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
5500 echo "$as_me:5500: checking for $ac_word" >&5
5501 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5502 if test "${ac_cv_prog_NCURSES_CONFIG+set}" = set; then
5503 echo $ECHO_N "(cached) $ECHO_C" >&6
5505 if test -n "$NCURSES_CONFIG"; then
5506 ac_cv_prog_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test.
5508 ac_save_IFS=$IFS; IFS=$ac_path_separator
5510 for ac_dir in $ac_dummy; do
5512 test -z "$ac_dir" && ac_dir=.
5513 $as_executable_p "$ac_dir/$ac_word" || continue
5514 ac_cv_prog_NCURSES_CONFIG="$ac_tool_prefix$ac_prog"
5515 echo "$as_me:5515: found $ac_dir/$ac_word" >&5
5521 NCURSES_CONFIG=$ac_cv_prog_NCURSES_CONFIG
5522 if test -n "$NCURSES_CONFIG"; then
5523 echo "$as_me:5523: result: $NCURSES_CONFIG" >&5
5524 echo "${ECHO_T}$NCURSES_CONFIG" >&6
5526 echo "$as_me:5526: result: no" >&5
5527 echo "${ECHO_T}no" >&6
5530 test -n "$NCURSES_CONFIG" && break
5533 if test -z "$NCURSES_CONFIG"; then
5534 ac_ct_NCURSES_CONFIG=$NCURSES_CONFIG
5535 for ac_prog in ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
5537 # Extract the first word of "$ac_prog", so it can be a program name with args.
5538 set dummy $ac_prog; ac_word=$2
5539 echo "$as_me:5539: checking for $ac_word" >&5
5540 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5541 if test "${ac_cv_prog_ac_ct_NCURSES_CONFIG+set}" = set; then
5542 echo $ECHO_N "(cached) $ECHO_C" >&6
5544 if test -n "$ac_ct_NCURSES_CONFIG"; then
5545 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_ct_NCURSES_CONFIG" # Let the user override the test.
5547 ac_save_IFS=$IFS; IFS=$ac_path_separator
5549 for ac_dir in $ac_dummy; do
5551 test -z "$ac_dir" && ac_dir=.
5552 $as_executable_p "$ac_dir/$ac_word" || continue
5553 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_prog"
5554 echo "$as_me:5554: found $ac_dir/$ac_word" >&5
5560 ac_ct_NCURSES_CONFIG=$ac_cv_prog_ac_ct_NCURSES_CONFIG
5561 if test -n "$ac_ct_NCURSES_CONFIG"; then
5562 echo "$as_me:5562: result: $ac_ct_NCURSES_CONFIG" >&5
5563 echo "${ECHO_T}$ac_ct_NCURSES_CONFIG" >&6
5565 echo "$as_me:5565: result: no" >&5
5566 echo "${ECHO_T}no" >&6
5569 test -n "$ac_ct_NCURSES_CONFIG" && break
5571 test -n "$ac_ct_NCURSES_CONFIG" || ac_ct_NCURSES_CONFIG="none"
5573 NCURSES_CONFIG=$ac_ct_NCURSES_CONFIG
5576 if test "$NCURSES_CONFIG" != none ; then
5578 CPPFLAGS="$CPPFLAGS `$NCURSES_CONFIG --cflags`"
5580 cf_add_libs="`$NCURSES_CONFIG --libs`"
5581 # Filter out duplicates - this happens with badly-designed ".pc" files...
5582 for cf_add_1lib in $LIBS
5584 for cf_add_2lib in $cf_add_libs
5586 if test "x$cf_add_1lib" = "x$cf_add_2lib"
5592 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
5596 # even with config script, some packages use no-override for curses.h
5598 echo "$as_me:5598: checking if we have identified curses headers" >&5
5599 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
5600 if test "${cf_cv_ncurses_header+set}" = set; then
5601 echo $ECHO_N "(cached) $ECHO_C" >&6
5604 cf_cv_ncurses_header=none
5611 cat >conftest.$ac_ext <<_ACEOF
5612 #line 5612 "configure"
5613 #include "confdefs.h"
5614 #include <${cf_header}>
5618 initscr(); tgoto("?", 0,0)
5623 rm -f conftest.$ac_objext
5624 if { (eval echo "$as_me:5624: \"$ac_compile\"") >&5
5625 (eval $ac_compile) 2>&5
5627 echo "$as_me:5627: \$? = $ac_status" >&5
5628 (exit $ac_status); } &&
5629 { ac_try='test -s conftest.$ac_objext'
5630 { (eval echo "$as_me:5630: \"$ac_try\"") >&5
5633 echo "$as_me:5633: \$? = $ac_status" >&5
5634 (exit $ac_status); }; }; then
5635 cf_cv_ncurses_header=$cf_header; break
5637 echo "$as_me: failed program was:" >&5
5638 cat conftest.$ac_ext >&5
5640 rm -f conftest.$ac_objext conftest.$ac_ext
5644 echo "$as_me:5644: result: $cf_cv_ncurses_header" >&5
5645 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
5647 if test "$cf_cv_ncurses_header" = none ; then
5648 { { echo "$as_me:5648: error: No curses header-files found" >&5
5649 echo "$as_me: error: No curses header-files found" >&2;}
5650 { (exit 1); exit 1; }; }
5653 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
5655 for ac_header in $cf_cv_ncurses_header
5657 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
5658 echo "$as_me:5658: checking for $ac_header" >&5
5659 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5660 if eval "test \"\${$as_ac_Header+set}\" = set"; then
5661 echo $ECHO_N "(cached) $ECHO_C" >&6
5663 cat >conftest.$ac_ext <<_ACEOF
5664 #line 5664 "configure"
5665 #include "confdefs.h"
5666 #include <$ac_header>
5668 if { (eval echo "$as_me:5668: \"$ac_cpp conftest.$ac_ext\"") >&5
5669 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
5671 egrep -v '^ *\+' conftest.er1 >conftest.err
5673 cat conftest.err >&5
5674 echo "$as_me:5674: \$? = $ac_status" >&5
5675 (exit $ac_status); } >/dev/null; then
5676 if test -s conftest.err; then
5677 ac_cpp_err=$ac_c_preproc_warn_flag
5684 if test -z "$ac_cpp_err"; then
5685 eval "$as_ac_Header=yes"
5687 echo "$as_me: failed program was:" >&5
5688 cat conftest.$ac_ext >&5
5689 eval "$as_ac_Header=no"
5691 rm -f conftest.err conftest.$ac_ext
5693 echo "$as_me:5693: result: `eval echo '${'$as_ac_Header'}'`" >&5
5694 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
5695 if test `eval echo '${'$as_ac_Header'}'` = yes; then
5696 cat >>confdefs.h <<EOF
5697 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
5703 cat >>confdefs.h <<\EOF
5707 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
5709 cat >>confdefs.h <<EOF
5710 #define $cf_nculib_ROOT 1
5713 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
5717 cf_ncuhdr_root=ncurses
5719 test -n "$cf_cv_curses_dir" && \
5720 test "$cf_cv_curses_dir" != "no" && { \
5722 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
5723 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
5725 while test $cf_add_incdir != /usr/include
5727 if test -d $cf_add_incdir
5730 if test -n "$CFLAGS$CPPFLAGS" ; then
5731 # a loop is needed to ensure we can add subdirs of existing dirs
5732 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
5733 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
5734 cf_have_incdir=yes; break
5739 if test "$cf_have_incdir" = no ; then
5740 if test "$cf_add_incdir" = /usr/local/include ; then
5741 if test "$GCC" = yes
5743 cf_save_CPPFLAGS=$CPPFLAGS
5744 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
5745 cat >conftest.$ac_ext <<_ACEOF
5746 #line 5746 "configure"
5747 #include "confdefs.h"
5757 rm -f conftest.$ac_objext
5758 if { (eval echo "$as_me:5758: \"$ac_compile\"") >&5
5759 (eval $ac_compile) 2>&5
5761 echo "$as_me:5761: \$? = $ac_status" >&5
5762 (exit $ac_status); } &&
5763 { ac_try='test -s conftest.$ac_objext'
5764 { (eval echo "$as_me:5764: \"$ac_try\"") >&5
5767 echo "$as_me:5767: \$? = $ac_status" >&5
5768 (exit $ac_status); }; }; then
5771 echo "$as_me: failed program was:" >&5
5772 cat conftest.$ac_ext >&5
5775 rm -f conftest.$ac_objext conftest.$ac_ext
5776 CPPFLAGS=$cf_save_CPPFLAGS
5781 if test "$cf_have_incdir" = no ; then
5782 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
5784 echo "${as_me:-configure}:5784: testing adding $cf_add_incdir to include-path ..." 1>&5
5786 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
5788 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
5789 test "$cf_top_incdir" = "$cf_add_incdir" && break
5790 cf_add_incdir="$cf_top_incdir"
5801 echo "$as_me:5801: checking for $cf_ncuhdr_root header in include-path" >&5
5802 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
5803 if test "${cf_cv_ncurses_h+set}" = set; then
5804 echo $ECHO_N "(cached) $ECHO_C" >&6
5807 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
5808 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
5809 for cf_header in $cf_header_list
5812 cat >conftest.$ac_ext <<_ACEOF
5813 #line 5813 "configure"
5814 #include "confdefs.h"
5816 #include <$cf_header>
5821 #ifdef NCURSES_VERSION
5823 printf("%s\n", NCURSES_VERSION);
5836 rm -f conftest.$ac_objext
5837 if { (eval echo "$as_me:5837: \"$ac_compile\"") >&5
5838 (eval $ac_compile) 2>&5
5840 echo "$as_me:5840: \$? = $ac_status" >&5
5841 (exit $ac_status); } &&
5842 { ac_try='test -s conftest.$ac_objext'
5843 { (eval echo "$as_me:5843: \"$ac_try\"") >&5
5846 echo "$as_me:5846: \$? = $ac_status" >&5
5847 (exit $ac_status); }; }; then
5848 cf_cv_ncurses_h=$cf_header
5851 echo "$as_me: failed program was:" >&5
5852 cat conftest.$ac_ext >&5
5855 rm -f conftest.$ac_objext conftest.$ac_ext
5857 test "$cf_cv_ncurses_h" != no && break
5861 echo "$as_me:5861: result: $cf_cv_ncurses_h" >&5
5862 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
5864 if test "$cf_cv_ncurses_h" != no ; then
5865 cf_cv_ncurses_header=$cf_cv_ncurses_h
5868 echo "$as_me:5868: checking for $cf_ncuhdr_root include-path" >&5
5869 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
5870 if test "${cf_cv_ncurses_h2+set}" = set; then
5871 echo $ECHO_N "(cached) $ECHO_C" >&6
5874 test -n "$verbose" && echo
5878 # collect the current set of include-directories from compiler flags
5879 cf_header_path_list=""
5880 if test -n "${CFLAGS}${CPPFLAGS}" ; then
5881 for cf_header_path in $CPPFLAGS $CFLAGS
5883 case $cf_header_path in #(vi
5885 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
5887 test "x$cf_header_path" != "xNONE" && \
5888 test -d "$cf_header_path" && \
5890 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
5891 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
5892 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
5893 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
5894 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
5895 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"
5898 cf_header_path_list="$cf_header_path_list $cf_search"
5904 # add the variations for the package we are looking for
5908 test "x/usr" != "x$prefix" && \
5910 (test -z "$prefix" || test x$prefix = xNONE || test "x/usr" != "x$prefix") && {
5911 test -n "$verbose" && echo " ... testing for include-directories under /usr"
5912 test -d /usr/include && cf_search="$cf_search /usr/include"
5913 test -d /usr/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/include/$cf_ncuhdr_root"
5914 test -d /usr/include/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/include/$cf_ncuhdr_root/include"
5915 test -d /usr/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/$cf_ncuhdr_root/include"
5916 test -d /usr/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
5919 test "x$prefix" != "xNONE" && \
5920 test -d "$prefix" && \
5922 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
5923 test -d $prefix/include && cf_search="$cf_search $prefix/include"
5924 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
5925 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
5926 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
5927 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
5930 test "x/usr/local" != "x$prefix" && \
5931 test -d "/usr/local" && \
5932 (test -z "$prefix" || test x$prefix = xNONE || test "x/usr/local" != "x$prefix") && {
5933 test -n "$verbose" && echo " ... testing for include-directories under /usr/local"
5934 test -d /usr/local/include && cf_search="$cf_search /usr/local/include"
5935 test -d /usr/local/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/local/include/$cf_ncuhdr_root"
5936 test -d /usr/local/include/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/local/include/$cf_ncuhdr_root/include"
5937 test -d /usr/local/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/local/$cf_ncuhdr_root/include"
5938 test -d /usr/local/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/local/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
5941 test "x/opt" != "x$prefix" && \
5943 (test -z "$prefix" || test x$prefix = xNONE || test "x/opt" != "x$prefix") && {
5944 test -n "$verbose" && echo " ... testing for include-directories under /opt"
5945 test -d /opt/include && cf_search="$cf_search /opt/include"
5946 test -d /opt/include/$cf_ncuhdr_root && cf_search="$cf_search /opt/include/$cf_ncuhdr_root"
5947 test -d /opt/include/$cf_ncuhdr_root/include && cf_search="$cf_search /opt/include/$cf_ncuhdr_root/include"
5948 test -d /opt/$cf_ncuhdr_root/include && cf_search="$cf_search /opt/$cf_ncuhdr_root/include"
5949 test -d /opt/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /opt/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
5952 test "x$HOME" != "x$prefix" && \
5953 test -d "$HOME" && \
5954 (test -z "$prefix" || test x$prefix = xNONE || test "x$HOME" != "x$prefix") && {
5955 test -n "$verbose" && echo " ... testing for include-directories under $HOME"
5956 test -d $HOME/include && cf_search="$cf_search $HOME/include"
5957 test -d $HOME/include/$cf_ncuhdr_root && cf_search="$cf_search $HOME/include/$cf_ncuhdr_root"
5958 test -d $HOME/include/$cf_ncuhdr_root/include && cf_search="$cf_search $HOME/include/$cf_ncuhdr_root/include"
5959 test -d $HOME/$cf_ncuhdr_root/include && cf_search="$cf_search $HOME/$cf_ncuhdr_root/include"
5960 test -d $HOME/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $HOME/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
5963 test "$includedir" != NONE && \
5964 test "$includedir" != "/usr/include" && \
5965 test -d "$includedir" && {
5966 test -d $includedir && cf_search="$cf_search $includedir"
5967 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
5970 test "$oldincludedir" != NONE && \
5971 test "$oldincludedir" != "/usr/include" && \
5972 test -d "$oldincludedir" && {
5973 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
5974 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
5977 cf_search="$cf_search $cf_header_path_list"
5979 test -n "$verbose" && echo search path $cf_search
5980 cf_save2_CPPFLAGS="$CPPFLAGS"
5981 for cf_incdir in $cf_search
5984 if test -n "$cf_incdir" ; then
5985 for cf_add_incdir in $cf_incdir
5987 while test $cf_add_incdir != /usr/include
5989 if test -d $cf_add_incdir
5992 if test -n "$CFLAGS$CPPFLAGS" ; then
5993 # a loop is needed to ensure we can add subdirs of existing dirs
5994 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
5995 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
5996 cf_have_incdir=yes; break
6001 if test "$cf_have_incdir" = no ; then
6002 if test "$cf_add_incdir" = /usr/local/include ; then
6003 if test "$GCC" = yes
6005 cf_save_CPPFLAGS=$CPPFLAGS
6006 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6007 cat >conftest.$ac_ext <<_ACEOF
6008 #line 6008 "configure"
6009 #include "confdefs.h"
6019 rm -f conftest.$ac_objext
6020 if { (eval echo "$as_me:6020: \"$ac_compile\"") >&5
6021 (eval $ac_compile) 2>&5
6023 echo "$as_me:6023: \$? = $ac_status" >&5
6024 (exit $ac_status); } &&
6025 { ac_try='test -s conftest.$ac_objext'
6026 { (eval echo "$as_me:6026: \"$ac_try\"") >&5
6029 echo "$as_me:6029: \$? = $ac_status" >&5
6030 (exit $ac_status); }; }; then
6033 echo "$as_me: failed program was:" >&5
6034 cat conftest.$ac_ext >&5
6037 rm -f conftest.$ac_objext conftest.$ac_ext
6038 CPPFLAGS=$cf_save_CPPFLAGS
6043 if test "$cf_have_incdir" = no ; then
6044 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
6046 echo "${as_me:-configure}:6046: testing adding $cf_add_incdir to include-path ..." 1>&5
6048 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6050 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
6051 test "$cf_top_incdir" = "$cf_add_incdir" && break
6052 cf_add_incdir="$cf_top_incdir"
6066 cat >conftest.$ac_ext <<_ACEOF
6067 #line 6067 "configure"
6068 #include "confdefs.h"
6070 #include <$cf_header>
6075 #ifdef NCURSES_VERSION
6077 printf("%s\n", NCURSES_VERSION);
6090 rm -f conftest.$ac_objext
6091 if { (eval echo "$as_me:6091: \"$ac_compile\"") >&5
6092 (eval $ac_compile) 2>&5
6094 echo "$as_me:6094: \$? = $ac_status" >&5
6095 (exit $ac_status); } &&
6096 { ac_try='test -s conftest.$ac_objext'
6097 { (eval echo "$as_me:6097: \"$ac_try\"") >&5
6100 echo "$as_me:6100: \$? = $ac_status" >&5
6101 (exit $ac_status); }; }; then
6102 cf_cv_ncurses_h2=$cf_header
6105 echo "$as_me: failed program was:" >&5
6106 cat conftest.$ac_ext >&5
6109 rm -f conftest.$ac_objext conftest.$ac_ext
6111 if test "$cf_cv_ncurses_h2" != no ; then
6112 cf_cv_ncurses_h2=$cf_incdir/$cf_header
6113 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
6116 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
6118 CPPFLAGS="$cf_save2_CPPFLAGS"
6119 test "$cf_cv_ncurses_h2" != no && break
6121 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:6121: error: not found" >&5
6122 echo "$as_me: error: not found" >&2;}
6123 { (exit 1); exit 1; }; }
6126 echo "$as_me:6126: result: $cf_cv_ncurses_h2" >&5
6127 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
6129 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
6130 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
6131 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
6132 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
6135 if test -n "$cf_1st_incdir" ; then
6136 for cf_add_incdir in $cf_1st_incdir
6138 while test $cf_add_incdir != /usr/include
6140 if test -d $cf_add_incdir
6143 if test -n "$CFLAGS$CPPFLAGS" ; then
6144 # a loop is needed to ensure we can add subdirs of existing dirs
6145 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
6146 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
6147 cf_have_incdir=yes; break
6152 if test "$cf_have_incdir" = no ; then
6153 if test "$cf_add_incdir" = /usr/local/include ; then
6154 if test "$GCC" = yes
6156 cf_save_CPPFLAGS=$CPPFLAGS
6157 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6158 cat >conftest.$ac_ext <<_ACEOF
6159 #line 6159 "configure"
6160 #include "confdefs.h"
6170 rm -f conftest.$ac_objext
6171 if { (eval echo "$as_me:6171: \"$ac_compile\"") >&5
6172 (eval $ac_compile) 2>&5
6174 echo "$as_me:6174: \$? = $ac_status" >&5
6175 (exit $ac_status); } &&
6176 { ac_try='test -s conftest.$ac_objext'
6177 { (eval echo "$as_me:6177: \"$ac_try\"") >&5
6180 echo "$as_me:6180: \$? = $ac_status" >&5
6181 (exit $ac_status); }; }; then
6184 echo "$as_me: failed program was:" >&5
6185 cat conftest.$ac_ext >&5
6188 rm -f conftest.$ac_objext conftest.$ac_ext
6189 CPPFLAGS=$cf_save_CPPFLAGS
6194 if test "$cf_have_incdir" = no ; then
6195 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
6197 echo "${as_me:-configure}:6197: testing adding $cf_add_incdir to include-path ..." 1>&5
6199 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6201 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
6202 test "$cf_top_incdir" = "$cf_add_incdir" && break
6203 cf_add_incdir="$cf_top_incdir"
6214 # Set definitions to allow ifdef'ing for ncurses.h
6216 case $cf_cv_ncurses_header in # (vi
6219 cat >>confdefs.h <<\EOF
6220 #define HAVE_NCURSES_H 1
6226 case $cf_cv_ncurses_header in # (vi
6227 ncurses/curses.h|ncurses/ncurses.h)
6229 cat >>confdefs.h <<\EOF
6230 #define HAVE_NCURSES_NCURSES_H 1
6234 ncursesw/curses.h|ncursesw/ncurses.h)
6236 cat >>confdefs.h <<\EOF
6237 #define HAVE_NCURSESW_NCURSES_H 1
6243 echo "$as_me:6243: checking for terminfo header" >&5
6244 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
6245 if test "${cf_cv_term_header+set}" = set; then
6246 echo $ECHO_N "(cached) $ECHO_C" >&6
6249 case ${cf_cv_ncurses_header} in #(vi
6250 */ncurses.h|*/ncursesw.h) #(vi
6251 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
6254 cf_term_header=term.h
6258 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
6260 cat >conftest.$ac_ext <<_ACEOF
6261 #line 6261 "configure"
6262 #include "confdefs.h"
6264 #include <${cf_cv_ncurses_header:-curses.h}>
6270 int x = auto_left_margin
6275 rm -f conftest.$ac_objext
6276 if { (eval echo "$as_me:6276: \"$ac_compile\"") >&5
6277 (eval $ac_compile) 2>&5
6279 echo "$as_me:6279: \$? = $ac_status" >&5
6280 (exit $ac_status); } &&
6281 { ac_try='test -s conftest.$ac_objext'
6282 { (eval echo "$as_me:6282: \"$ac_try\"") >&5
6285 echo "$as_me:6285: \$? = $ac_status" >&5
6286 (exit $ac_status); }; }; then
6288 cf_cv_term_header="$cf_test"
6290 echo "$as_me: failed program was:" >&5
6291 cat conftest.$ac_ext >&5
6293 cf_cv_term_header=unknown
6296 rm -f conftest.$ac_objext conftest.$ac_ext
6297 test "$cf_cv_term_header" != unknown && break
6301 echo "$as_me:6301: result: $cf_cv_term_header" >&5
6302 echo "${ECHO_T}$cf_cv_term_header" >&6
6304 # Set definitions to allow ifdef'ing to accommodate subdirectories
6306 case $cf_cv_term_header in # (vi
6309 cat >>confdefs.h <<\EOF
6310 #define HAVE_TERM_H 1
6316 case $cf_cv_term_header in # (vi
6317 ncurses/term.h) #(vi
6319 cat >>confdefs.h <<\EOF
6320 #define HAVE_NCURSES_TERM_H 1
6326 cat >>confdefs.h <<\EOF
6327 #define HAVE_NCURSESW_TERM_H 1
6333 # some applications need this, but should check for NCURSES_VERSION
6335 cat >>confdefs.h <<\EOF
6339 echo "$as_me:6339: checking for ncurses version" >&5
6340 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
6341 if test "${cf_cv_ncurses_version+set}" = set; then
6342 echo $ECHO_N "(cached) $ECHO_C" >&6
6345 cf_cv_ncurses_version=no
6348 if test "$cross_compiling" = yes; then
6350 # This will not work if the preprocessor splits the line after the
6351 # Autoconf token. The 'unproto' program does that.
6352 cat > conftest.$ac_ext <<EOF
6353 #include <${cf_cv_ncurses_header:-curses.h}>
6355 #ifdef NCURSES_VERSION
6356 Autoconf NCURSES_VERSION
6364 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
6365 { (eval echo "$as_me:6365: \"$cf_try\"") >&5
6368 echo "$as_me:6368: \$? = $ac_status" >&5
6369 (exit $ac_status); }
6370 if test -f conftest.out ; then
6371 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
6372 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
6377 cat >conftest.$ac_ext <<_ACEOF
6378 #line 6378 "configure"
6379 #include "confdefs.h"
6381 #include <${cf_cv_ncurses_header:-curses.h}>
6385 FILE *fp = fopen("$cf_tempfile", "w");
6386 #ifdef NCURSES_VERSION
6387 # ifdef NCURSES_VERSION_PATCH
6388 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
6390 fprintf(fp, "%s\n", NCURSES_VERSION);
6394 fprintf(fp, "old\n");
6399 ${cf_cv_main_return:-return}(0);
6402 rm -f conftest$ac_exeext
6403 if { (eval echo "$as_me:6403: \"$ac_link\"") >&5
6404 (eval $ac_link) 2>&5
6406 echo "$as_me:6406: \$? = $ac_status" >&5
6407 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
6408 { (eval echo "$as_me:6408: \"$ac_try\"") >&5
6411 echo "$as_me:6411: \$? = $ac_status" >&5
6412 (exit $ac_status); }; }; then
6414 cf_cv_ncurses_version=`cat $cf_tempfile`
6416 echo "$as_me: program exited with status $ac_status" >&5
6417 echo "$as_me: failed program was:" >&5
6418 cat conftest.$ac_ext >&5
6420 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6425 echo "$as_me:6425: result: $cf_cv_ncurses_version" >&5
6426 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
6427 test "$cf_cv_ncurses_version" = no ||
6428 cat >>confdefs.h <<\EOF
6432 cf_nculib_root=ncurses
6433 # This works, except for the special case where we find gpm, but
6434 # ncurses is in a nonstandard location via $LIBS, and we really want
6437 cf_ncurses_SAVE="$LIBS"
6438 echo "$as_me:6438: checking for Gpm_Open in -lgpm" >&5
6439 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
6440 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
6441 echo $ECHO_N "(cached) $ECHO_C" >&6
6443 ac_check_lib_save_LIBS=$LIBS
6445 cat >conftest.$ac_ext <<_ACEOF
6446 #line 6446 "configure"
6447 #include "confdefs.h"
6449 /* Override any gcc2 internal prototype to avoid an error. */
6453 /* We use char because int might match the return type of a gcc2
6454 builtin and then its argument prototype would still apply. */
6464 rm -f conftest.$ac_objext conftest$ac_exeext
6465 if { (eval echo "$as_me:6465: \"$ac_link\"") >&5
6466 (eval $ac_link) 2>&5
6468 echo "$as_me:6468: \$? = $ac_status" >&5
6469 (exit $ac_status); } &&
6470 { ac_try='test -s conftest$ac_exeext'
6471 { (eval echo "$as_me:6471: \"$ac_try\"") >&5
6474 echo "$as_me:6474: \$? = $ac_status" >&5
6475 (exit $ac_status); }; }; then
6476 ac_cv_lib_gpm_Gpm_Open=yes
6478 echo "$as_me: failed program was:" >&5
6479 cat conftest.$ac_ext >&5
6480 ac_cv_lib_gpm_Gpm_Open=no
6482 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6483 LIBS=$ac_check_lib_save_LIBS
6485 echo "$as_me:6485: result: $ac_cv_lib_gpm_Gpm_Open" >&5
6486 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
6487 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
6488 echo "$as_me:6488: checking for initscr in -lgpm" >&5
6489 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
6490 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
6491 echo $ECHO_N "(cached) $ECHO_C" >&6
6493 ac_check_lib_save_LIBS=$LIBS
6495 cat >conftest.$ac_ext <<_ACEOF
6496 #line 6496 "configure"
6497 #include "confdefs.h"
6499 /* Override any gcc2 internal prototype to avoid an error. */
6503 /* We use char because int might match the return type of a gcc2
6504 builtin and then its argument prototype would still apply. */
6514 rm -f conftest.$ac_objext conftest$ac_exeext
6515 if { (eval echo "$as_me:6515: \"$ac_link\"") >&5
6516 (eval $ac_link) 2>&5
6518 echo "$as_me:6518: \$? = $ac_status" >&5
6519 (exit $ac_status); } &&
6520 { ac_try='test -s conftest$ac_exeext'
6521 { (eval echo "$as_me:6521: \"$ac_try\"") >&5
6524 echo "$as_me:6524: \$? = $ac_status" >&5
6525 (exit $ac_status); }; }; then
6526 ac_cv_lib_gpm_initscr=yes
6528 echo "$as_me: failed program was:" >&5
6529 cat conftest.$ac_ext >&5
6530 ac_cv_lib_gpm_initscr=no
6532 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6533 LIBS=$ac_check_lib_save_LIBS
6535 echo "$as_me:6535: result: $ac_cv_lib_gpm_initscr" >&5
6536 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
6537 if test $ac_cv_lib_gpm_initscr = yes; then
6538 LIBS="$cf_ncurses_SAVE"
6540 cf_ncurses_LIBS="-lgpm"
6545 case $host_os in #(vi
6547 # This is only necessary if you are linking against an obsolete
6548 # version of ncurses (but it should do no harm, since it's static).
6549 if test "$cf_nculib_root" = ncurses ; then
6550 echo "$as_me:6550: checking for tgoto in -lmytinfo" >&5
6551 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
6552 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
6553 echo $ECHO_N "(cached) $ECHO_C" >&6
6555 ac_check_lib_save_LIBS=$LIBS
6556 LIBS="-lmytinfo $LIBS"
6557 cat >conftest.$ac_ext <<_ACEOF
6558 #line 6558 "configure"
6559 #include "confdefs.h"
6561 /* Override any gcc2 internal prototype to avoid an error. */
6565 /* We use char because int might match the return type of a gcc2
6566 builtin and then its argument prototype would still apply. */
6576 rm -f conftest.$ac_objext conftest$ac_exeext
6577 if { (eval echo "$as_me:6577: \"$ac_link\"") >&5
6578 (eval $ac_link) 2>&5
6580 echo "$as_me:6580: \$? = $ac_status" >&5
6581 (exit $ac_status); } &&
6582 { ac_try='test -s conftest$ac_exeext'
6583 { (eval echo "$as_me:6583: \"$ac_try\"") >&5
6586 echo "$as_me:6586: \$? = $ac_status" >&5
6587 (exit $ac_status); }; }; then
6588 ac_cv_lib_mytinfo_tgoto=yes
6590 echo "$as_me: failed program was:" >&5
6591 cat conftest.$ac_ext >&5
6592 ac_cv_lib_mytinfo_tgoto=no
6594 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6595 LIBS=$ac_check_lib_save_LIBS
6597 echo "$as_me:6597: result: $ac_cv_lib_mytinfo_tgoto" >&5
6598 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
6599 if test $ac_cv_lib_mytinfo_tgoto = yes; then
6600 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
6607 cf_add_libs="$cf_ncurses_LIBS"
6608 # Filter out duplicates - this happens with badly-designed ".pc" files...
6609 for cf_add_1lib in $LIBS
6611 for cf_add_2lib in $cf_add_libs
6613 if test "x$cf_add_1lib" = "x$cf_add_2lib"
6619 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
6623 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
6626 cf_add_libs="-l$cf_nculib_root"
6627 # Filter out duplicates - this happens with badly-designed ".pc" files...
6628 for cf_add_1lib in $LIBS
6630 for cf_add_2lib in $cf_add_libs
6632 if test "x$cf_add_1lib" = "x$cf_add_2lib"
6638 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
6644 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
6646 echo "$as_me:6646: checking for initscr" >&5
6647 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
6648 if test "${ac_cv_func_initscr+set}" = set; then
6649 echo $ECHO_N "(cached) $ECHO_C" >&6
6651 cat >conftest.$ac_ext <<_ACEOF
6652 #line 6652 "configure"
6653 #include "confdefs.h"
6654 /* System header to define __stub macros and hopefully few prototypes,
6655 which can conflict with char initscr (); below. */
6657 /* Override any gcc2 internal prototype to avoid an error. */
6661 /* We use char because int might match the return type of a gcc2
6662 builtin and then its argument prototype would still apply. */
6669 /* The GNU C library defines this for functions which it implements
6670 to always fail with ENOSYS. Some functions are actually named
6671 something starting with __ and the normal name is an alias. */
6672 #if defined (__stub_initscr) || defined (__stub___initscr)
6675 f = initscr; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
6682 rm -f conftest.$ac_objext conftest$ac_exeext
6683 if { (eval echo "$as_me:6683: \"$ac_link\"") >&5
6684 (eval $ac_link) 2>&5
6686 echo "$as_me:6686: \$? = $ac_status" >&5
6687 (exit $ac_status); } &&
6688 { ac_try='test -s conftest$ac_exeext'
6689 { (eval echo "$as_me:6689: \"$ac_try\"") >&5
6692 echo "$as_me:6692: \$? = $ac_status" >&5
6693 (exit $ac_status); }; }; then
6694 ac_cv_func_initscr=yes
6696 echo "$as_me: failed program was:" >&5
6697 cat conftest.$ac_ext >&5
6698 ac_cv_func_initscr=no
6700 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6702 echo "$as_me:6702: result: $ac_cv_func_initscr" >&5
6703 echo "${ECHO_T}$ac_cv_func_initscr" >&6
6704 if test $ac_cv_func_initscr = yes; then
6705 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
6708 cf_save_LIBS="$LIBS"
6709 echo "$as_me:6709: checking for initscr in -l$cf_nculib_root" >&5
6710 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
6711 LIBS="-l$cf_nculib_root $LIBS"
6712 cat >conftest.$ac_ext <<_ACEOF
6713 #line 6713 "configure"
6714 #include "confdefs.h"
6715 #include <${cf_cv_ncurses_header:-curses.h}>
6724 rm -f conftest.$ac_objext conftest$ac_exeext
6725 if { (eval echo "$as_me:6725: \"$ac_link\"") >&5
6726 (eval $ac_link) 2>&5
6728 echo "$as_me:6728: \$? = $ac_status" >&5
6729 (exit $ac_status); } &&
6730 { ac_try='test -s conftest$ac_exeext'
6731 { (eval echo "$as_me:6731: \"$ac_try\"") >&5
6734 echo "$as_me:6734: \$? = $ac_status" >&5
6735 (exit $ac_status); }; }; then
6736 echo "$as_me:6736: result: yes" >&5
6737 echo "${ECHO_T}yes" >&6
6738 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
6741 echo "$as_me: failed program was:" >&5
6742 cat conftest.$ac_ext >&5
6743 echo "$as_me:6743: result: no" >&5
6744 echo "${ECHO_T}no" >&6
6747 cf_library_path_list=""
6748 if test -n "${LDFLAGS}${LIBS}" ; then
6749 for cf_library_path in $LDFLAGS $LIBS
6751 case $cf_library_path in #(vi
6753 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
6755 test "x$cf_library_path" != "xNONE" && \
6756 test -d "$cf_library_path" && \
6758 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
6759 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
6760 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
6761 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
6762 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
6763 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"
6766 cf_library_path_list="$cf_library_path_list $cf_search"
6774 test "x/usr" != "x$prefix" && \
6776 (test -z "$prefix" || test x$prefix = xNONE || test "x/usr" != "x$prefix") && {
6777 test -n "$verbose" && echo " ... testing for lib-directories under /usr"
6778 test -d /usr/lib && cf_search="$cf_search /usr/lib"
6779 test -d /usr/lib/$cf_nculib_root && cf_search="$cf_search /usr/lib/$cf_nculib_root"
6780 test -d /usr/lib/$cf_nculib_root/lib && cf_search="$cf_search /usr/lib/$cf_nculib_root/lib"
6781 test -d /usr/$cf_nculib_root/lib && cf_search="$cf_search /usr/$cf_nculib_root/lib"
6782 test -d /usr/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /usr/$cf_nculib_root/lib/$cf_nculib_root"
6785 test "x$prefix" != "xNONE" && \
6786 test -d "$prefix" && \
6788 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
6789 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
6790 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
6791 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
6792 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
6793 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
6796 test "x/usr/local" != "x$prefix" && \
6797 test -d "/usr/local" && \
6798 (test -z "$prefix" || test x$prefix = xNONE || test "x/usr/local" != "x$prefix") && {
6799 test -n "$verbose" && echo " ... testing for lib-directories under /usr/local"
6800 test -d /usr/local/lib && cf_search="$cf_search /usr/local/lib"
6801 test -d /usr/local/lib/$cf_nculib_root && cf_search="$cf_search /usr/local/lib/$cf_nculib_root"
6802 test -d /usr/local/lib/$cf_nculib_root/lib && cf_search="$cf_search /usr/local/lib/$cf_nculib_root/lib"
6803 test -d /usr/local/$cf_nculib_root/lib && cf_search="$cf_search /usr/local/$cf_nculib_root/lib"
6804 test -d /usr/local/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /usr/local/$cf_nculib_root/lib/$cf_nculib_root"
6807 test "x/opt" != "x$prefix" && \
6809 (test -z "$prefix" || test x$prefix = xNONE || test "x/opt" != "x$prefix") && {
6810 test -n "$verbose" && echo " ... testing for lib-directories under /opt"
6811 test -d /opt/lib && cf_search="$cf_search /opt/lib"
6812 test -d /opt/lib/$cf_nculib_root && cf_search="$cf_search /opt/lib/$cf_nculib_root"
6813 test -d /opt/lib/$cf_nculib_root/lib && cf_search="$cf_search /opt/lib/$cf_nculib_root/lib"
6814 test -d /opt/$cf_nculib_root/lib && cf_search="$cf_search /opt/$cf_nculib_root/lib"
6815 test -d /opt/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /opt/$cf_nculib_root/lib/$cf_nculib_root"
6818 test "x$HOME" != "x$prefix" && \
6819 test -d "$HOME" && \
6820 (test -z "$prefix" || test x$prefix = xNONE || test "x$HOME" != "x$prefix") && {
6821 test -n "$verbose" && echo " ... testing for lib-directories under $HOME"
6822 test -d $HOME/lib && cf_search="$cf_search $HOME/lib"
6823 test -d $HOME/lib/$cf_nculib_root && cf_search="$cf_search $HOME/lib/$cf_nculib_root"
6824 test -d $HOME/lib/$cf_nculib_root/lib && cf_search="$cf_search $HOME/lib/$cf_nculib_root/lib"
6825 test -d $HOME/$cf_nculib_root/lib && cf_search="$cf_search $HOME/$cf_nculib_root/lib"
6826 test -d $HOME/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $HOME/$cf_nculib_root/lib/$cf_nculib_root"
6829 cf_search="$cf_library_path_list $cf_search"
6831 for cf_libdir in $cf_search
6833 echo "$as_me:6833: checking for -l$cf_nculib_root in $cf_libdir" >&5
6834 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
6835 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
6836 cat >conftest.$ac_ext <<_ACEOF
6837 #line 6837 "configure"
6838 #include "confdefs.h"
6839 #include <${cf_cv_ncurses_header:-curses.h}>
6848 rm -f conftest.$ac_objext conftest$ac_exeext
6849 if { (eval echo "$as_me:6849: \"$ac_link\"") >&5
6850 (eval $ac_link) 2>&5
6852 echo "$as_me:6852: \$? = $ac_status" >&5
6853 (exit $ac_status); } &&
6854 { ac_try='test -s conftest$ac_exeext'
6855 { (eval echo "$as_me:6855: \"$ac_try\"") >&5
6858 echo "$as_me:6858: \$? = $ac_status" >&5
6859 (exit $ac_status); }; }; then
6860 echo "$as_me:6860: result: yes" >&5
6861 echo "${ECHO_T}yes" >&6
6862 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
6865 echo "$as_me: failed program was:" >&5
6866 cat conftest.$ac_ext >&5
6867 echo "$as_me:6867: result: no" >&5
6868 echo "${ECHO_T}no" >&6
6869 LIBS="$cf_save_LIBS"
6871 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6875 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6879 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
6881 if test $cf_found_library = no ; then
6882 { { echo "$as_me:6882: error: Cannot link $cf_nculib_root library" >&5
6883 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
6884 { (exit 1); exit 1; }; }
6889 if test -n "$cf_ncurses_LIBS" ; then
6890 echo "$as_me:6890: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
6891 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
6892 cf_ncurses_SAVE="$LIBS"
6893 for p in $cf_ncurses_LIBS ; do
6894 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
6895 if test "$q" != "$LIBS" ; then
6899 cat >conftest.$ac_ext <<_ACEOF
6900 #line 6900 "configure"
6901 #include "confdefs.h"
6902 #include <${cf_cv_ncurses_header:-curses.h}>
6906 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
6911 rm -f conftest.$ac_objext conftest$ac_exeext
6912 if { (eval echo "$as_me:6912: \"$ac_link\"") >&5
6913 (eval $ac_link) 2>&5
6915 echo "$as_me:6915: \$? = $ac_status" >&5
6916 (exit $ac_status); } &&
6917 { ac_try='test -s conftest$ac_exeext'
6918 { (eval echo "$as_me:6918: \"$ac_try\"") >&5
6921 echo "$as_me:6921: \$? = $ac_status" >&5
6922 (exit $ac_status); }; }; then
6923 echo "$as_me:6923: result: yes" >&5
6924 echo "${ECHO_T}yes" >&6
6926 echo "$as_me: failed program was:" >&5
6927 cat conftest.$ac_ext >&5
6928 echo "$as_me:6928: result: no" >&5
6929 echo "${ECHO_T}no" >&6
6930 LIBS="$cf_ncurses_SAVE"
6932 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6935 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
6937 cat >>confdefs.h <<EOF
6938 #define $cf_nculib_ROOT 1
6946 echo "$as_me:6946: checking for multibyte character support" >&5
6947 echo $ECHO_N "checking for multibyte character support... $ECHO_C" >&6
6948 if test "${cf_cv_utf8_lib+set}" = set; then
6949 echo $ECHO_N "(cached) $ECHO_C" >&6
6952 cf_save_LIBS="$LIBS"
6953 cat >conftest.$ac_ext <<_ACEOF
6954 #line 6954 "configure"
6955 #include "confdefs.h"
6966 rm -f conftest.$ac_objext conftest$ac_exeext
6967 if { (eval echo "$as_me:6967: \"$ac_link\"") >&5
6968 (eval $ac_link) 2>&5
6970 echo "$as_me:6970: \$? = $ac_status" >&5
6971 (exit $ac_status); } &&
6972 { ac_try='test -s conftest$ac_exeext'
6973 { (eval echo "$as_me:6973: \"$ac_try\"") >&5
6976 echo "$as_me:6976: \$? = $ac_status" >&5
6977 (exit $ac_status); }; }; then
6980 echo "$as_me: failed program was:" >&5
6981 cat conftest.$ac_ext >&5
6983 # If the linkage is not already in the $CPPFLAGS/$LDFLAGS configuration, these
6984 # will be set on completion of the AC_TRY_LINK below.
6985 cf_cv_header_path_utf8=
6986 cf_cv_library_path_utf8=
6988 echo "${as_me:-configure}:6988: testing Starting FIND_LINKAGE(utf8,) ..." 1>&5
6990 cf_save_LIBS="$LIBS"
6992 cat >conftest.$ac_ext <<_ACEOF
6993 #line 6993 "configure"
6994 #include "confdefs.h"
6996 #include <libutf8.h>
7005 rm -f conftest.$ac_objext conftest$ac_exeext
7006 if { (eval echo "$as_me:7006: \"$ac_link\"") >&5
7007 (eval $ac_link) 2>&5
7009 echo "$as_me:7009: \$? = $ac_status" >&5
7010 (exit $ac_status); } &&
7011 { ac_try='test -s conftest$ac_exeext'
7012 { (eval echo "$as_me:7012: \"$ac_try\"") >&5
7015 echo "$as_me:7015: \$? = $ac_status" >&5
7016 (exit $ac_status); }; }; then
7018 cf_cv_find_linkage_utf8=yes
7019 cf_cv_header_path_utf8=/usr/include
7020 cf_cv_library_path_utf8=/usr/lib
7023 echo "$as_me: failed program was:" >&5
7024 cat conftest.$ac_ext >&5
7026 LIBS="-lutf8 $cf_save_LIBS"
7028 cat >conftest.$ac_ext <<_ACEOF
7029 #line 7029 "configure"
7030 #include "confdefs.h"
7032 #include <libutf8.h>
7041 rm -f conftest.$ac_objext conftest$ac_exeext
7042 if { (eval echo "$as_me:7042: \"$ac_link\"") >&5
7043 (eval $ac_link) 2>&5
7045 echo "$as_me:7045: \$? = $ac_status" >&5
7046 (exit $ac_status); } &&
7047 { ac_try='test -s conftest$ac_exeext'
7048 { (eval echo "$as_me:7048: \"$ac_try\"") >&5
7051 echo "$as_me:7051: \$? = $ac_status" >&5
7052 (exit $ac_status); }; }; then
7054 cf_cv_find_linkage_utf8=yes
7055 cf_cv_header_path_utf8=/usr/include
7056 cf_cv_library_path_utf8=/usr/lib
7057 cf_cv_library_file_utf8="-lutf8"
7060 echo "$as_me: failed program was:" >&5
7061 cat conftest.$ac_ext >&5
7063 cf_cv_find_linkage_utf8=no
7064 LIBS="$cf_save_LIBS"
7066 test -n "$verbose" && echo " find linkage for utf8 library" 1>&6
7068 echo "${as_me:-configure}:7068: testing find linkage for utf8 library ..." 1>&5
7070 echo "${as_me:-configure}:7070: testing Searching for headers in FIND_LINKAGE(utf8,) ..." 1>&5
7072 cf_save_CPPFLAGS="$CPPFLAGS"
7073 cf_test_CPPFLAGS="$CPPFLAGS"
7077 # collect the current set of include-directories from compiler flags
7078 cf_header_path_list=""
7079 if test -n "${CFLAGS}${CPPFLAGS}" ; then
7080 for cf_header_path in $CPPFLAGS $CFLAGS
7082 case $cf_header_path in #(vi
7084 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
7086 test "x$cf_header_path" != "xNONE" && \
7087 test -d "$cf_header_path" && \
7089 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
7090 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
7091 test -d $cf_header_path/include/utf8 && cf_search="$cf_search $cf_header_path/include/utf8"
7092 test -d $cf_header_path/include/utf8/include && cf_search="$cf_search $cf_header_path/include/utf8/include"
7093 test -d $cf_header_path/utf8/include && cf_search="$cf_search $cf_header_path/utf8/include"
7094 test -d $cf_header_path/utf8/include/utf8 && cf_search="$cf_search $cf_header_path/utf8/include/utf8"
7097 cf_header_path_list="$cf_header_path_list $cf_search"
7103 # add the variations for the package we are looking for
7107 test "x/usr" != "x$prefix" && \
7109 (test -z "$prefix" || test x$prefix = xNONE || test "x/usr" != "x$prefix") && {
7110 test -n "$verbose" && echo " ... testing for include-directories under /usr"
7111 test -d /usr/include && cf_search="$cf_search /usr/include"
7112 test -d /usr/include/utf8 && cf_search="$cf_search /usr/include/utf8"
7113 test -d /usr/include/utf8/include && cf_search="$cf_search /usr/include/utf8/include"
7114 test -d /usr/utf8/include && cf_search="$cf_search /usr/utf8/include"
7115 test -d /usr/utf8/include/utf8 && cf_search="$cf_search /usr/utf8/include/utf8"
7118 test "x$prefix" != "xNONE" && \
7119 test -d "$prefix" && \
7121 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
7122 test -d $prefix/include && cf_search="$cf_search $prefix/include"
7123 test -d $prefix/include/utf8 && cf_search="$cf_search $prefix/include/utf8"
7124 test -d $prefix/include/utf8/include && cf_search="$cf_search $prefix/include/utf8/include"
7125 test -d $prefix/utf8/include && cf_search="$cf_search $prefix/utf8/include"
7126 test -d $prefix/utf8/include/utf8 && cf_search="$cf_search $prefix/utf8/include/utf8"
7129 test "x/usr/local" != "x$prefix" && \
7130 test -d "/usr/local" && \
7131 (test -z "$prefix" || test x$prefix = xNONE || test "x/usr/local" != "x$prefix") && {
7132 test -n "$verbose" && echo " ... testing for include-directories under /usr/local"
7133 test -d /usr/local/include && cf_search="$cf_search /usr/local/include"
7134 test -d /usr/local/include/utf8 && cf_search="$cf_search /usr/local/include/utf8"
7135 test -d /usr/local/include/utf8/include && cf_search="$cf_search /usr/local/include/utf8/include"
7136 test -d /usr/local/utf8/include && cf_search="$cf_search /usr/local/utf8/include"
7137 test -d /usr/local/utf8/include/utf8 && cf_search="$cf_search /usr/local/utf8/include/utf8"
7140 test "x/opt" != "x$prefix" && \
7142 (test -z "$prefix" || test x$prefix = xNONE || test "x/opt" != "x$prefix") && {
7143 test -n "$verbose" && echo " ... testing for include-directories under /opt"
7144 test -d /opt/include && cf_search="$cf_search /opt/include"
7145 test -d /opt/include/utf8 && cf_search="$cf_search /opt/include/utf8"
7146 test -d /opt/include/utf8/include && cf_search="$cf_search /opt/include/utf8/include"
7147 test -d /opt/utf8/include && cf_search="$cf_search /opt/utf8/include"
7148 test -d /opt/utf8/include/utf8 && cf_search="$cf_search /opt/utf8/include/utf8"
7151 test "x$HOME" != "x$prefix" && \
7152 test -d "$HOME" && \
7153 (test -z "$prefix" || test x$prefix = xNONE || test "x$HOME" != "x$prefix") && {
7154 test -n "$verbose" && echo " ... testing for include-directories under $HOME"
7155 test -d $HOME/include && cf_search="$cf_search $HOME/include"
7156 test -d $HOME/include/utf8 && cf_search="$cf_search $HOME/include/utf8"
7157 test -d $HOME/include/utf8/include && cf_search="$cf_search $HOME/include/utf8/include"
7158 test -d $HOME/utf8/include && cf_search="$cf_search $HOME/utf8/include"
7159 test -d $HOME/utf8/include/utf8 && cf_search="$cf_search $HOME/utf8/include/utf8"
7162 test "$includedir" != NONE && \
7163 test "$includedir" != "/usr/include" && \
7164 test -d "$includedir" && {
7165 test -d $includedir && cf_search="$cf_search $includedir"
7166 test -d $includedir/utf8 && cf_search="$cf_search $includedir/utf8"
7169 test "$oldincludedir" != NONE && \
7170 test "$oldincludedir" != "/usr/include" && \
7171 test -d "$oldincludedir" && {
7172 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
7173 test -d $oldincludedir/utf8 && cf_search="$cf_search $oldincludedir/utf8"
7176 cf_search="$cf_search $cf_header_path_list"
7178 for cf_cv_header_path_utf8 in $cf_search
7180 if test -d $cf_cv_header_path_utf8 ; then
7181 test -n "$verbose" && echo " ... testing $cf_cv_header_path_utf8" 1>&6
7183 echo "${as_me:-configure}:7183: testing ... testing $cf_cv_header_path_utf8 ..." 1>&5
7185 CPPFLAGS="$cf_save_CPPFLAGS -I$cf_cv_header_path_utf8"
7186 cat >conftest.$ac_ext <<_ACEOF
7187 #line 7187 "configure"
7188 #include "confdefs.h"
7190 #include <libutf8.h>
7199 rm -f conftest.$ac_objext
7200 if { (eval echo "$as_me:7200: \"$ac_compile\"") >&5
7201 (eval $ac_compile) 2>&5
7203 echo "$as_me:7203: \$? = $ac_status" >&5
7204 (exit $ac_status); } &&
7205 { ac_try='test -s conftest.$ac_objext'
7206 { (eval echo "$as_me:7206: \"$ac_try\"") >&5
7209 echo "$as_me:7209: \$? = $ac_status" >&5
7210 (exit $ac_status); }; }; then
7212 test -n "$verbose" && echo " ... found utf8 headers in $cf_cv_header_path_utf8" 1>&6
7214 echo "${as_me:-configure}:7214: testing ... found utf8 headers in $cf_cv_header_path_utf8 ..." 1>&5
7216 cf_cv_find_linkage_utf8=maybe
7217 cf_test_CPPFLAGS="$CPPFLAGS"
7220 echo "$as_me: failed program was:" >&5
7221 cat conftest.$ac_ext >&5
7223 CPPFLAGS="$cf_save_CPPFLAGS"
7226 rm -f conftest.$ac_objext conftest.$ac_ext
7230 if test "$cf_cv_find_linkage_utf8" = maybe ; then
7232 echo "${as_me:-configure}:7232: testing Searching for utf8 library in FIND_LINKAGE(utf8,) ..." 1>&5
7234 cf_save_LIBS="$LIBS"
7235 cf_save_LDFLAGS="$LDFLAGS"
7237 if test "$cf_cv_find_linkage_utf8" != yes ; then
7240 cf_library_path_list=""
7241 if test -n "${LDFLAGS}${LIBS}" ; then
7242 for cf_library_path in $LDFLAGS $LIBS
7244 case $cf_library_path in #(vi
7246 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
7248 test "x$cf_library_path" != "xNONE" && \
7249 test -d "$cf_library_path" && \
7251 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
7252 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
7253 test -d $cf_library_path/lib/utf8 && cf_search="$cf_search $cf_library_path/lib/utf8"
7254 test -d $cf_library_path/lib/utf8/lib && cf_search="$cf_search $cf_library_path/lib/utf8/lib"
7255 test -d $cf_library_path/utf8/lib && cf_search="$cf_search $cf_library_path/utf8/lib"
7256 test -d $cf_library_path/utf8/lib/utf8 && cf_search="$cf_search $cf_library_path/utf8/lib/utf8"
7259 cf_library_path_list="$cf_library_path_list $cf_search"
7267 test "x/usr" != "x$prefix" && \
7269 (test -z "$prefix" || test x$prefix = xNONE || test "x/usr" != "x$prefix") && {
7270 test -n "$verbose" && echo " ... testing for lib-directories under /usr"
7271 test -d /usr/lib && cf_search="$cf_search /usr/lib"
7272 test -d /usr/lib/utf8 && cf_search="$cf_search /usr/lib/utf8"
7273 test -d /usr/lib/utf8/lib && cf_search="$cf_search /usr/lib/utf8/lib"
7274 test -d /usr/utf8/lib && cf_search="$cf_search /usr/utf8/lib"
7275 test -d /usr/utf8/lib/utf8 && cf_search="$cf_search /usr/utf8/lib/utf8"
7278 test "x$prefix" != "xNONE" && \
7279 test -d "$prefix" && \
7281 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
7282 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
7283 test -d $prefix/lib/utf8 && cf_search="$cf_search $prefix/lib/utf8"
7284 test -d $prefix/lib/utf8/lib && cf_search="$cf_search $prefix/lib/utf8/lib"
7285 test -d $prefix/utf8/lib && cf_search="$cf_search $prefix/utf8/lib"
7286 test -d $prefix/utf8/lib/utf8 && cf_search="$cf_search $prefix/utf8/lib/utf8"
7289 test "x/usr/local" != "x$prefix" && \
7290 test -d "/usr/local" && \
7291 (test -z "$prefix" || test x$prefix = xNONE || test "x/usr/local" != "x$prefix") && {
7292 test -n "$verbose" && echo " ... testing for lib-directories under /usr/local"
7293 test -d /usr/local/lib && cf_search="$cf_search /usr/local/lib"
7294 test -d /usr/local/lib/utf8 && cf_search="$cf_search /usr/local/lib/utf8"
7295 test -d /usr/local/lib/utf8/lib && cf_search="$cf_search /usr/local/lib/utf8/lib"
7296 test -d /usr/local/utf8/lib && cf_search="$cf_search /usr/local/utf8/lib"
7297 test -d /usr/local/utf8/lib/utf8 && cf_search="$cf_search /usr/local/utf8/lib/utf8"
7300 test "x/opt" != "x$prefix" && \
7302 (test -z "$prefix" || test x$prefix = xNONE || test "x/opt" != "x$prefix") && {
7303 test -n "$verbose" && echo " ... testing for lib-directories under /opt"
7304 test -d /opt/lib && cf_search="$cf_search /opt/lib"
7305 test -d /opt/lib/utf8 && cf_search="$cf_search /opt/lib/utf8"
7306 test -d /opt/lib/utf8/lib && cf_search="$cf_search /opt/lib/utf8/lib"
7307 test -d /opt/utf8/lib && cf_search="$cf_search /opt/utf8/lib"
7308 test -d /opt/utf8/lib/utf8 && cf_search="$cf_search /opt/utf8/lib/utf8"
7311 test "x$HOME" != "x$prefix" && \
7312 test -d "$HOME" && \
7313 (test -z "$prefix" || test x$prefix = xNONE || test "x$HOME" != "x$prefix") && {
7314 test -n "$verbose" && echo " ... testing for lib-directories under $HOME"
7315 test -d $HOME/lib && cf_search="$cf_search $HOME/lib"
7316 test -d $HOME/lib/utf8 && cf_search="$cf_search $HOME/lib/utf8"
7317 test -d $HOME/lib/utf8/lib && cf_search="$cf_search $HOME/lib/utf8/lib"
7318 test -d $HOME/utf8/lib && cf_search="$cf_search $HOME/utf8/lib"
7319 test -d $HOME/utf8/lib/utf8 && cf_search="$cf_search $HOME/utf8/lib/utf8"
7322 cf_search="$cf_library_path_list $cf_search"
7324 for cf_cv_library_path_utf8 in $cf_search
7326 if test -d $cf_cv_library_path_utf8 ; then
7327 test -n "$verbose" && echo " ... testing $cf_cv_library_path_utf8" 1>&6
7329 echo "${as_me:-configure}:7329: testing ... testing $cf_cv_library_path_utf8 ..." 1>&5
7331 CPPFLAGS="$cf_test_CPPFLAGS"
7332 LIBS="-lutf8 $cf_save_LIBS"
7333 LDFLAGS="$cf_save_LDFLAGS -L$cf_cv_library_path_utf8"
7334 cat >conftest.$ac_ext <<_ACEOF
7335 #line 7335 "configure"
7336 #include "confdefs.h"
7338 #include <libutf8.h>
7347 rm -f conftest.$ac_objext conftest$ac_exeext
7348 if { (eval echo "$as_me:7348: \"$ac_link\"") >&5
7349 (eval $ac_link) 2>&5
7351 echo "$as_me:7351: \$? = $ac_status" >&5
7352 (exit $ac_status); } &&
7353 { ac_try='test -s conftest$ac_exeext'
7354 { (eval echo "$as_me:7354: \"$ac_try\"") >&5
7357 echo "$as_me:7357: \$? = $ac_status" >&5
7358 (exit $ac_status); }; }; then
7360 test -n "$verbose" && echo " ... found utf8 library in $cf_cv_library_path_utf8" 1>&6
7362 echo "${as_me:-configure}:7362: testing ... found utf8 library in $cf_cv_library_path_utf8 ..." 1>&5
7364 cf_cv_find_linkage_utf8=yes
7365 cf_cv_library_file_utf8="-lutf8"
7368 echo "$as_me: failed program was:" >&5
7369 cat conftest.$ac_ext >&5
7371 CPPFLAGS="$cf_save_CPPFLAGS"
7372 LIBS="$cf_save_LIBS"
7373 LDFLAGS="$cf_save_LDFLAGS"
7376 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7379 CPPFLAGS="$cf_save_CPPFLAGS"
7380 LDFLAGS="$cf_save_LDFLAGS"
7384 cf_cv_find_linkage_utf8=no
7388 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7391 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7393 LIBS="$cf_save_LIBS"
7395 if test "$cf_cv_find_linkage_utf8" = yes ; then
7396 cf_cv_utf8_lib=add-on
7402 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7404 echo "$as_me:7404: result: $cf_cv_utf8_lib" >&5
7405 echo "${ECHO_T}$cf_cv_utf8_lib" >&6
7407 # HAVE_LIBUTF8_H is used by ncurses if curses.h is shared between
7409 if test "$cf_cv_utf8_lib" = "add-on" ; then
7411 cat >>confdefs.h <<\EOF
7412 #define HAVE_LIBUTF8_H 1
7415 if test -n "$cf_cv_header_path_utf8" ; then
7416 for cf_add_incdir in $cf_cv_header_path_utf8
7418 while test $cf_add_incdir != /usr/include
7420 if test -d $cf_add_incdir
7423 if test -n "$CFLAGS$CPPFLAGS" ; then
7424 # a loop is needed to ensure we can add subdirs of existing dirs
7425 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
7426 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
7427 cf_have_incdir=yes; break
7432 if test "$cf_have_incdir" = no ; then
7433 if test "$cf_add_incdir" = /usr/local/include ; then
7434 if test "$GCC" = yes
7436 cf_save_CPPFLAGS=$CPPFLAGS
7437 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7438 cat >conftest.$ac_ext <<_ACEOF
7439 #line 7439 "configure"
7440 #include "confdefs.h"
7450 rm -f conftest.$ac_objext
7451 if { (eval echo "$as_me:7451: \"$ac_compile\"") >&5
7452 (eval $ac_compile) 2>&5
7454 echo "$as_me:7454: \$? = $ac_status" >&5
7455 (exit $ac_status); } &&
7456 { ac_try='test -s conftest.$ac_objext'
7457 { (eval echo "$as_me:7457: \"$ac_try\"") >&5
7460 echo "$as_me:7460: \$? = $ac_status" >&5
7461 (exit $ac_status); }; }; then
7464 echo "$as_me: failed program was:" >&5
7465 cat conftest.$ac_ext >&5
7468 rm -f conftest.$ac_objext conftest.$ac_ext
7469 CPPFLAGS=$cf_save_CPPFLAGS
7474 if test "$cf_have_incdir" = no ; then
7475 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
7477 echo "${as_me:-configure}:7477: testing adding $cf_add_incdir to include-path ..." 1>&5
7479 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7481 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
7482 test "$cf_top_incdir" = "$cf_add_incdir" && break
7483 cf_add_incdir="$cf_top_incdir"
7492 if test -n "$cf_cv_library_path_utf8" ; then
7493 for cf_add_libdir in $cf_cv_library_path_utf8
7495 if test $cf_add_libdir = /usr/lib ; then
7497 elif test -d $cf_add_libdir
7500 if test -n "$LDFLAGS$LIBS" ; then
7501 # a loop is needed to ensure we can add subdirs of existing dirs
7502 for cf_test_libdir in $LDFLAGS $LIBS ; do
7503 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
7504 cf_have_libdir=yes; break
7508 if test "$cf_have_libdir" = no ; then
7509 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
7511 echo "${as_me:-configure}:7511: testing adding $cf_add_libdir to library-path ..." 1>&5
7513 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
7519 cf_add_libs="$cf_cv_library_file_utf8"
7520 # Filter out duplicates - this happens with badly-designed ".pc" files...
7521 for cf_add_1lib in $LIBS
7523 for cf_add_2lib in $cf_add_libs
7525 if test "x$cf_add_1lib" = "x$cf_add_2lib"
7531 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
7537 cf_ncuconfig_root=ncursesw
7539 echo "Looking for ${cf_ncuconfig_root}-config"
7541 if test -n "$ac_tool_prefix"; then
7542 for ac_prog in ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
7544 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
7545 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
7546 echo "$as_me:7546: checking for $ac_word" >&5
7547 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7548 if test "${ac_cv_prog_NCURSES_CONFIG+set}" = set; then
7549 echo $ECHO_N "(cached) $ECHO_C" >&6
7551 if test -n "$NCURSES_CONFIG"; then
7552 ac_cv_prog_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test.
7554 ac_save_IFS=$IFS; IFS=$ac_path_separator
7556 for ac_dir in $ac_dummy; do
7558 test -z "$ac_dir" && ac_dir=.
7559 $as_executable_p "$ac_dir/$ac_word" || continue
7560 ac_cv_prog_NCURSES_CONFIG="$ac_tool_prefix$ac_prog"
7561 echo "$as_me:7561: found $ac_dir/$ac_word" >&5
7567 NCURSES_CONFIG=$ac_cv_prog_NCURSES_CONFIG
7568 if test -n "$NCURSES_CONFIG"; then
7569 echo "$as_me:7569: result: $NCURSES_CONFIG" >&5
7570 echo "${ECHO_T}$NCURSES_CONFIG" >&6
7572 echo "$as_me:7572: result: no" >&5
7573 echo "${ECHO_T}no" >&6
7576 test -n "$NCURSES_CONFIG" && break
7579 if test -z "$NCURSES_CONFIG"; then
7580 ac_ct_NCURSES_CONFIG=$NCURSES_CONFIG
7581 for ac_prog in ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
7583 # Extract the first word of "$ac_prog", so it can be a program name with args.
7584 set dummy $ac_prog; ac_word=$2
7585 echo "$as_me:7585: checking for $ac_word" >&5
7586 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7587 if test "${ac_cv_prog_ac_ct_NCURSES_CONFIG+set}" = set; then
7588 echo $ECHO_N "(cached) $ECHO_C" >&6
7590 if test -n "$ac_ct_NCURSES_CONFIG"; then
7591 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_ct_NCURSES_CONFIG" # Let the user override the test.
7593 ac_save_IFS=$IFS; IFS=$ac_path_separator
7595 for ac_dir in $ac_dummy; do
7597 test -z "$ac_dir" && ac_dir=.
7598 $as_executable_p "$ac_dir/$ac_word" || continue
7599 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_prog"
7600 echo "$as_me:7600: found $ac_dir/$ac_word" >&5
7606 ac_ct_NCURSES_CONFIG=$ac_cv_prog_ac_ct_NCURSES_CONFIG
7607 if test -n "$ac_ct_NCURSES_CONFIG"; then
7608 echo "$as_me:7608: result: $ac_ct_NCURSES_CONFIG" >&5
7609 echo "${ECHO_T}$ac_ct_NCURSES_CONFIG" >&6
7611 echo "$as_me:7611: result: no" >&5
7612 echo "${ECHO_T}no" >&6
7615 test -n "$ac_ct_NCURSES_CONFIG" && break
7617 test -n "$ac_ct_NCURSES_CONFIG" || ac_ct_NCURSES_CONFIG="none"
7619 NCURSES_CONFIG=$ac_ct_NCURSES_CONFIG
7622 if test "$NCURSES_CONFIG" != none ; then
7624 CPPFLAGS="$CPPFLAGS `$NCURSES_CONFIG --cflags`"
7626 cf_add_libs="`$NCURSES_CONFIG --libs`"
7627 # Filter out duplicates - this happens with badly-designed ".pc" files...
7628 for cf_add_1lib in $LIBS
7630 for cf_add_2lib in $cf_add_libs
7632 if test "x$cf_add_1lib" = "x$cf_add_2lib"
7638 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
7642 # even with config script, some packages use no-override for curses.h
7644 echo "$as_me:7644: checking if we have identified curses headers" >&5
7645 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
7646 if test "${cf_cv_ncurses_header+set}" = set; then
7647 echo $ECHO_N "(cached) $ECHO_C" >&6
7650 cf_cv_ncurses_header=none
7652 ncursesw/ncurses.h \
7657 cat >conftest.$ac_ext <<_ACEOF
7658 #line 7658 "configure"
7659 #include "confdefs.h"
7660 #include <${cf_header}>
7664 initscr(); tgoto("?", 0,0)
7669 rm -f conftest.$ac_objext
7670 if { (eval echo "$as_me:7670: \"$ac_compile\"") >&5
7671 (eval $ac_compile) 2>&5
7673 echo "$as_me:7673: \$? = $ac_status" >&5
7674 (exit $ac_status); } &&
7675 { ac_try='test -s conftest.$ac_objext'
7676 { (eval echo "$as_me:7676: \"$ac_try\"") >&5
7679 echo "$as_me:7679: \$? = $ac_status" >&5
7680 (exit $ac_status); }; }; then
7681 cf_cv_ncurses_header=$cf_header; break
7683 echo "$as_me: failed program was:" >&5
7684 cat conftest.$ac_ext >&5
7686 rm -f conftest.$ac_objext conftest.$ac_ext
7690 echo "$as_me:7690: result: $cf_cv_ncurses_header" >&5
7691 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
7693 if test "$cf_cv_ncurses_header" = none ; then
7694 { { echo "$as_me:7694: error: No curses header-files found" >&5
7695 echo "$as_me: error: No curses header-files found" >&2;}
7696 { (exit 1); exit 1; }; }
7699 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
7701 for ac_header in $cf_cv_ncurses_header
7703 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7704 echo "$as_me:7704: checking for $ac_header" >&5
7705 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7706 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7707 echo $ECHO_N "(cached) $ECHO_C" >&6
7709 cat >conftest.$ac_ext <<_ACEOF
7710 #line 7710 "configure"
7711 #include "confdefs.h"
7712 #include <$ac_header>
7714 if { (eval echo "$as_me:7714: \"$ac_cpp conftest.$ac_ext\"") >&5
7715 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7717 egrep -v '^ *\+' conftest.er1 >conftest.err
7719 cat conftest.err >&5
7720 echo "$as_me:7720: \$? = $ac_status" >&5
7721 (exit $ac_status); } >/dev/null; then
7722 if test -s conftest.err; then
7723 ac_cpp_err=$ac_c_preproc_warn_flag
7730 if test -z "$ac_cpp_err"; then
7731 eval "$as_ac_Header=yes"
7733 echo "$as_me: failed program was:" >&5
7734 cat conftest.$ac_ext >&5
7735 eval "$as_ac_Header=no"
7737 rm -f conftest.err conftest.$ac_ext
7739 echo "$as_me:7739: result: `eval echo '${'$as_ac_Header'}'`" >&5
7740 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7741 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7742 cat >>confdefs.h <<EOF
7743 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7749 cat >>confdefs.h <<\EOF
7753 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
7755 cat >>confdefs.h <<EOF
7756 #define $cf_nculib_ROOT 1
7759 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
7763 cf_ncuhdr_root=ncursesw
7765 test -n "$cf_cv_curses_dir" && \
7766 test "$cf_cv_curses_dir" != "no" && { \
7768 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
7769 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
7771 while test $cf_add_incdir != /usr/include
7773 if test -d $cf_add_incdir
7776 if test -n "$CFLAGS$CPPFLAGS" ; then
7777 # a loop is needed to ensure we can add subdirs of existing dirs
7778 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
7779 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
7780 cf_have_incdir=yes; break
7785 if test "$cf_have_incdir" = no ; then
7786 if test "$cf_add_incdir" = /usr/local/include ; then
7787 if test "$GCC" = yes
7789 cf_save_CPPFLAGS=$CPPFLAGS
7790 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7791 cat >conftest.$ac_ext <<_ACEOF
7792 #line 7792 "configure"
7793 #include "confdefs.h"
7803 rm -f conftest.$ac_objext
7804 if { (eval echo "$as_me:7804: \"$ac_compile\"") >&5
7805 (eval $ac_compile) 2>&5
7807 echo "$as_me:7807: \$? = $ac_status" >&5
7808 (exit $ac_status); } &&
7809 { ac_try='test -s conftest.$ac_objext'
7810 { (eval echo "$as_me:7810: \"$ac_try\"") >&5
7813 echo "$as_me:7813: \$? = $ac_status" >&5
7814 (exit $ac_status); }; }; then
7817 echo "$as_me: failed program was:" >&5
7818 cat conftest.$ac_ext >&5
7821 rm -f conftest.$ac_objext conftest.$ac_ext
7822 CPPFLAGS=$cf_save_CPPFLAGS
7827 if test "$cf_have_incdir" = no ; then
7828 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
7830 echo "${as_me:-configure}:7830: testing adding $cf_add_incdir to include-path ..." 1>&5
7832 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7834 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
7835 test "$cf_top_incdir" = "$cf_add_incdir" && break
7836 cf_add_incdir="$cf_top_incdir"
7847 echo "$as_me:7847: checking for $cf_ncuhdr_root header in include-path" >&5
7848 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
7849 if test "${cf_cv_ncurses_h+set}" = set; then
7850 echo $ECHO_N "(cached) $ECHO_C" >&6
7853 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
7854 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
7855 for cf_header in $cf_header_list
7858 cat >conftest.$ac_ext <<_ACEOF
7859 #line 7859 "configure"
7860 #include "confdefs.h"
7862 #define _XOPEN_SOURCE_EXTENDED
7863 #undef HAVE_LIBUTF8_H /* in case we used CF_UTF8_LIB */
7864 #define HAVE_LIBUTF8_H /* to force ncurses' header file to use cchar_t */
7866 #include <$cf_header>
7871 #ifdef NCURSES_VERSION
7877 printf("%s\n", NCURSES_VERSION);
7890 rm -f conftest.$ac_objext
7891 if { (eval echo "$as_me:7891: \"$ac_compile\"") >&5
7892 (eval $ac_compile) 2>&5
7894 echo "$as_me:7894: \$? = $ac_status" >&5
7895 (exit $ac_status); } &&
7896 { ac_try='test -s conftest.$ac_objext'
7897 { (eval echo "$as_me:7897: \"$ac_try\"") >&5
7900 echo "$as_me:7900: \$? = $ac_status" >&5
7901 (exit $ac_status); }; }; then
7902 cf_cv_ncurses_h=$cf_header
7905 echo "$as_me: failed program was:" >&5
7906 cat conftest.$ac_ext >&5
7909 rm -f conftest.$ac_objext conftest.$ac_ext
7911 test "$cf_cv_ncurses_h" != no && break
7915 echo "$as_me:7915: result: $cf_cv_ncurses_h" >&5
7916 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
7918 if test "$cf_cv_ncurses_h" != no ; then
7919 cf_cv_ncurses_header=$cf_cv_ncurses_h
7922 echo "$as_me:7922: checking for $cf_ncuhdr_root include-path" >&5
7923 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
7924 if test "${cf_cv_ncurses_h2+set}" = set; then
7925 echo $ECHO_N "(cached) $ECHO_C" >&6
7928 test -n "$verbose" && echo
7932 # collect the current set of include-directories from compiler flags
7933 cf_header_path_list=""
7934 if test -n "${CFLAGS}${CPPFLAGS}" ; then
7935 for cf_header_path in $CPPFLAGS $CFLAGS
7937 case $cf_header_path in #(vi
7939 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
7941 test "x$cf_header_path" != "xNONE" && \
7942 test -d "$cf_header_path" && \
7944 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
7945 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
7946 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
7947 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
7948 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
7949 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"
7952 cf_header_path_list="$cf_header_path_list $cf_search"
7958 # add the variations for the package we are looking for
7962 test "x/usr" != "x$prefix" && \
7964 (test -z "$prefix" || test x$prefix = xNONE || test "x/usr" != "x$prefix") && {
7965 test -n "$verbose" && echo " ... testing for include-directories under /usr"
7966 test -d /usr/include && cf_search="$cf_search /usr/include"
7967 test -d /usr/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/include/$cf_ncuhdr_root"
7968 test -d /usr/include/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/include/$cf_ncuhdr_root/include"
7969 test -d /usr/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/$cf_ncuhdr_root/include"
7970 test -d /usr/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
7973 test "x$prefix" != "xNONE" && \
7974 test -d "$prefix" && \
7976 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
7977 test -d $prefix/include && cf_search="$cf_search $prefix/include"
7978 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
7979 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
7980 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
7981 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
7984 test "x/usr/local" != "x$prefix" && \
7985 test -d "/usr/local" && \
7986 (test -z "$prefix" || test x$prefix = xNONE || test "x/usr/local" != "x$prefix") && {
7987 test -n "$verbose" && echo " ... testing for include-directories under /usr/local"
7988 test -d /usr/local/include && cf_search="$cf_search /usr/local/include"
7989 test -d /usr/local/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/local/include/$cf_ncuhdr_root"
7990 test -d /usr/local/include/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/local/include/$cf_ncuhdr_root/include"
7991 test -d /usr/local/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/local/$cf_ncuhdr_root/include"
7992 test -d /usr/local/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/local/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
7995 test "x/opt" != "x$prefix" && \
7997 (test -z "$prefix" || test x$prefix = xNONE || test "x/opt" != "x$prefix") && {
7998 test -n "$verbose" && echo " ... testing for include-directories under /opt"
7999 test -d /opt/include && cf_search="$cf_search /opt/include"
8000 test -d /opt/include/$cf_ncuhdr_root && cf_search="$cf_search /opt/include/$cf_ncuhdr_root"
8001 test -d /opt/include/$cf_ncuhdr_root/include && cf_search="$cf_search /opt/include/$cf_ncuhdr_root/include"
8002 test -d /opt/$cf_ncuhdr_root/include && cf_search="$cf_search /opt/$cf_ncuhdr_root/include"
8003 test -d /opt/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /opt/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
8006 test "x$HOME" != "x$prefix" && \
8007 test -d "$HOME" && \
8008 (test -z "$prefix" || test x$prefix = xNONE || test "x$HOME" != "x$prefix") && {
8009 test -n "$verbose" && echo " ... testing for include-directories under $HOME"
8010 test -d $HOME/include && cf_search="$cf_search $HOME/include"
8011 test -d $HOME/include/$cf_ncuhdr_root && cf_search="$cf_search $HOME/include/$cf_ncuhdr_root"
8012 test -d $HOME/include/$cf_ncuhdr_root/include && cf_search="$cf_search $HOME/include/$cf_ncuhdr_root/include"
8013 test -d $HOME/$cf_ncuhdr_root/include && cf_search="$cf_search $HOME/$cf_ncuhdr_root/include"
8014 test -d $HOME/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $HOME/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
8017 test "$includedir" != NONE && \
8018 test "$includedir" != "/usr/include" && \
8019 test -d "$includedir" && {
8020 test -d $includedir && cf_search="$cf_search $includedir"
8021 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
8024 test "$oldincludedir" != NONE && \
8025 test "$oldincludedir" != "/usr/include" && \
8026 test -d "$oldincludedir" && {
8027 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
8028 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
8031 cf_search="$cf_search $cf_header_path_list"
8033 test -n "$verbose" && echo search path $cf_search
8034 cf_save2_CPPFLAGS="$CPPFLAGS"
8035 for cf_incdir in $cf_search
8038 if test -n "$cf_incdir" ; then
8039 for cf_add_incdir in $cf_incdir
8041 while test $cf_add_incdir != /usr/include
8043 if test -d $cf_add_incdir
8046 if test -n "$CFLAGS$CPPFLAGS" ; then
8047 # a loop is needed to ensure we can add subdirs of existing dirs
8048 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
8049 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
8050 cf_have_incdir=yes; break
8055 if test "$cf_have_incdir" = no ; then
8056 if test "$cf_add_incdir" = /usr/local/include ; then
8057 if test "$GCC" = yes
8059 cf_save_CPPFLAGS=$CPPFLAGS
8060 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8061 cat >conftest.$ac_ext <<_ACEOF
8062 #line 8062 "configure"
8063 #include "confdefs.h"
8073 rm -f conftest.$ac_objext
8074 if { (eval echo "$as_me:8074: \"$ac_compile\"") >&5
8075 (eval $ac_compile) 2>&5
8077 echo "$as_me:8077: \$? = $ac_status" >&5
8078 (exit $ac_status); } &&
8079 { ac_try='test -s conftest.$ac_objext'
8080 { (eval echo "$as_me:8080: \"$ac_try\"") >&5
8083 echo "$as_me:8083: \$? = $ac_status" >&5
8084 (exit $ac_status); }; }; then
8087 echo "$as_me: failed program was:" >&5
8088 cat conftest.$ac_ext >&5
8091 rm -f conftest.$ac_objext conftest.$ac_ext
8092 CPPFLAGS=$cf_save_CPPFLAGS
8097 if test "$cf_have_incdir" = no ; then
8098 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
8100 echo "${as_me:-configure}:8100: testing adding $cf_add_incdir to include-path ..." 1>&5
8102 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8104 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
8105 test "$cf_top_incdir" = "$cf_add_incdir" && break
8106 cf_add_incdir="$cf_top_incdir"
8120 cat >conftest.$ac_ext <<_ACEOF
8121 #line 8121 "configure"
8122 #include "confdefs.h"
8124 #include <$cf_header>
8129 #ifdef NCURSES_VERSION
8131 printf("%s\n", NCURSES_VERSION);
8144 rm -f conftest.$ac_objext
8145 if { (eval echo "$as_me:8145: \"$ac_compile\"") >&5
8146 (eval $ac_compile) 2>&5
8148 echo "$as_me:8148: \$? = $ac_status" >&5
8149 (exit $ac_status); } &&
8150 { ac_try='test -s conftest.$ac_objext'
8151 { (eval echo "$as_me:8151: \"$ac_try\"") >&5
8154 echo "$as_me:8154: \$? = $ac_status" >&5
8155 (exit $ac_status); }; }; then
8156 cf_cv_ncurses_h2=$cf_header
8159 echo "$as_me: failed program was:" >&5
8160 cat conftest.$ac_ext >&5
8163 rm -f conftest.$ac_objext conftest.$ac_ext
8165 if test "$cf_cv_ncurses_h2" != no ; then
8166 cf_cv_ncurses_h2=$cf_incdir/$cf_header
8167 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
8170 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
8172 CPPFLAGS="$cf_save2_CPPFLAGS"
8173 test "$cf_cv_ncurses_h2" != no && break
8175 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:8175: error: not found" >&5
8176 echo "$as_me: error: not found" >&2;}
8177 { (exit 1); exit 1; }; }
8180 echo "$as_me:8180: result: $cf_cv_ncurses_h2" >&5
8181 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
8183 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
8184 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
8185 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
8186 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
8189 if test -n "$cf_1st_incdir" ; then
8190 for cf_add_incdir in $cf_1st_incdir
8192 while test $cf_add_incdir != /usr/include
8194 if test -d $cf_add_incdir
8197 if test -n "$CFLAGS$CPPFLAGS" ; then
8198 # a loop is needed to ensure we can add subdirs of existing dirs
8199 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
8200 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
8201 cf_have_incdir=yes; break
8206 if test "$cf_have_incdir" = no ; then
8207 if test "$cf_add_incdir" = /usr/local/include ; then
8208 if test "$GCC" = yes
8210 cf_save_CPPFLAGS=$CPPFLAGS
8211 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8212 cat >conftest.$ac_ext <<_ACEOF
8213 #line 8213 "configure"
8214 #include "confdefs.h"
8224 rm -f conftest.$ac_objext
8225 if { (eval echo "$as_me:8225: \"$ac_compile\"") >&5
8226 (eval $ac_compile) 2>&5
8228 echo "$as_me:8228: \$? = $ac_status" >&5
8229 (exit $ac_status); } &&
8230 { ac_try='test -s conftest.$ac_objext'
8231 { (eval echo "$as_me:8231: \"$ac_try\"") >&5
8234 echo "$as_me:8234: \$? = $ac_status" >&5
8235 (exit $ac_status); }; }; then
8238 echo "$as_me: failed program was:" >&5
8239 cat conftest.$ac_ext >&5
8242 rm -f conftest.$ac_objext conftest.$ac_ext
8243 CPPFLAGS=$cf_save_CPPFLAGS
8248 if test "$cf_have_incdir" = no ; then
8249 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
8251 echo "${as_me:-configure}:8251: testing adding $cf_add_incdir to include-path ..." 1>&5
8253 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8255 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
8256 test "$cf_top_incdir" = "$cf_add_incdir" && break
8257 cf_add_incdir="$cf_top_incdir"
8268 # Set definitions to allow ifdef'ing for ncurses.h
8270 case $cf_cv_ncurses_header in # (vi
8273 cat >>confdefs.h <<\EOF
8274 #define HAVE_NCURSES_H 1
8280 case $cf_cv_ncurses_header in # (vi
8281 ncurses/curses.h|ncurses/ncurses.h)
8283 cat >>confdefs.h <<\EOF
8284 #define HAVE_NCURSES_NCURSES_H 1
8288 ncursesw/curses.h|ncursesw/ncurses.h)
8290 cat >>confdefs.h <<\EOF
8291 #define HAVE_NCURSESW_NCURSES_H 1
8297 echo "$as_me:8297: checking for terminfo header" >&5
8298 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
8299 if test "${cf_cv_term_header+set}" = set; then
8300 echo $ECHO_N "(cached) $ECHO_C" >&6
8303 case ${cf_cv_ncurses_header} in #(vi
8304 */ncurses.h|*/ncursesw.h) #(vi
8305 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
8308 cf_term_header=term.h
8312 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
8314 cat >conftest.$ac_ext <<_ACEOF
8315 #line 8315 "configure"
8316 #include "confdefs.h"
8318 #include <${cf_cv_ncurses_header:-curses.h}>
8324 int x = auto_left_margin
8329 rm -f conftest.$ac_objext
8330 if { (eval echo "$as_me:8330: \"$ac_compile\"") >&5
8331 (eval $ac_compile) 2>&5
8333 echo "$as_me:8333: \$? = $ac_status" >&5
8334 (exit $ac_status); } &&
8335 { ac_try='test -s conftest.$ac_objext'
8336 { (eval echo "$as_me:8336: \"$ac_try\"") >&5
8339 echo "$as_me:8339: \$? = $ac_status" >&5
8340 (exit $ac_status); }; }; then
8342 cf_cv_term_header="$cf_test"
8344 echo "$as_me: failed program was:" >&5
8345 cat conftest.$ac_ext >&5
8347 cf_cv_term_header=unknown
8350 rm -f conftest.$ac_objext conftest.$ac_ext
8351 test "$cf_cv_term_header" != unknown && break
8355 echo "$as_me:8355: result: $cf_cv_term_header" >&5
8356 echo "${ECHO_T}$cf_cv_term_header" >&6
8358 # Set definitions to allow ifdef'ing to accommodate subdirectories
8360 case $cf_cv_term_header in # (vi
8363 cat >>confdefs.h <<\EOF
8364 #define HAVE_TERM_H 1
8370 case $cf_cv_term_header in # (vi
8371 ncurses/term.h) #(vi
8373 cat >>confdefs.h <<\EOF
8374 #define HAVE_NCURSES_TERM_H 1
8380 cat >>confdefs.h <<\EOF
8381 #define HAVE_NCURSESW_TERM_H 1
8387 # some applications need this, but should check for NCURSES_VERSION
8389 cat >>confdefs.h <<\EOF
8393 echo "$as_me:8393: checking for ncurses version" >&5
8394 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
8395 if test "${cf_cv_ncurses_version+set}" = set; then
8396 echo $ECHO_N "(cached) $ECHO_C" >&6
8399 cf_cv_ncurses_version=no
8402 if test "$cross_compiling" = yes; then
8404 # This will not work if the preprocessor splits the line after the
8405 # Autoconf token. The 'unproto' program does that.
8406 cat > conftest.$ac_ext <<EOF
8407 #include <${cf_cv_ncurses_header:-curses.h}>
8409 #ifdef NCURSES_VERSION
8410 Autoconf NCURSES_VERSION
8418 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
8419 { (eval echo "$as_me:8419: \"$cf_try\"") >&5
8422 echo "$as_me:8422: \$? = $ac_status" >&5
8423 (exit $ac_status); }
8424 if test -f conftest.out ; then
8425 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
8426 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
8431 cat >conftest.$ac_ext <<_ACEOF
8432 #line 8432 "configure"
8433 #include "confdefs.h"
8435 #include <${cf_cv_ncurses_header:-curses.h}>
8439 FILE *fp = fopen("$cf_tempfile", "w");
8440 #ifdef NCURSES_VERSION
8441 # ifdef NCURSES_VERSION_PATCH
8442 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
8444 fprintf(fp, "%s\n", NCURSES_VERSION);
8448 fprintf(fp, "old\n");
8453 ${cf_cv_main_return:-return}(0);
8456 rm -f conftest$ac_exeext
8457 if { (eval echo "$as_me:8457: \"$ac_link\"") >&5
8458 (eval $ac_link) 2>&5
8460 echo "$as_me:8460: \$? = $ac_status" >&5
8461 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
8462 { (eval echo "$as_me:8462: \"$ac_try\"") >&5
8465 echo "$as_me:8465: \$? = $ac_status" >&5
8466 (exit $ac_status); }; }; then
8468 cf_cv_ncurses_version=`cat $cf_tempfile`
8470 echo "$as_me: program exited with status $ac_status" >&5
8471 echo "$as_me: failed program was:" >&5
8472 cat conftest.$ac_ext >&5
8474 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
8479 echo "$as_me:8479: result: $cf_cv_ncurses_version" >&5
8480 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
8481 test "$cf_cv_ncurses_version" = no ||
8482 cat >>confdefs.h <<\EOF
8486 cf_nculib_root=ncursesw
8487 # This works, except for the special case where we find gpm, but
8488 # ncurses is in a nonstandard location via $LIBS, and we really want
8491 cf_ncurses_SAVE="$LIBS"
8492 echo "$as_me:8492: checking for Gpm_Open in -lgpm" >&5
8493 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
8494 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
8495 echo $ECHO_N "(cached) $ECHO_C" >&6
8497 ac_check_lib_save_LIBS=$LIBS
8499 cat >conftest.$ac_ext <<_ACEOF
8500 #line 8500 "configure"
8501 #include "confdefs.h"
8503 /* Override any gcc2 internal prototype to avoid an error. */
8507 /* We use char because int might match the return type of a gcc2
8508 builtin and then its argument prototype would still apply. */
8518 rm -f conftest.$ac_objext conftest$ac_exeext
8519 if { (eval echo "$as_me:8519: \"$ac_link\"") >&5
8520 (eval $ac_link) 2>&5
8522 echo "$as_me:8522: \$? = $ac_status" >&5
8523 (exit $ac_status); } &&
8524 { ac_try='test -s conftest$ac_exeext'
8525 { (eval echo "$as_me:8525: \"$ac_try\"") >&5
8528 echo "$as_me:8528: \$? = $ac_status" >&5
8529 (exit $ac_status); }; }; then
8530 ac_cv_lib_gpm_Gpm_Open=yes
8532 echo "$as_me: failed program was:" >&5
8533 cat conftest.$ac_ext >&5
8534 ac_cv_lib_gpm_Gpm_Open=no
8536 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8537 LIBS=$ac_check_lib_save_LIBS
8539 echo "$as_me:8539: result: $ac_cv_lib_gpm_Gpm_Open" >&5
8540 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
8541 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
8542 echo "$as_me:8542: checking for initscr in -lgpm" >&5
8543 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
8544 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
8545 echo $ECHO_N "(cached) $ECHO_C" >&6
8547 ac_check_lib_save_LIBS=$LIBS
8549 cat >conftest.$ac_ext <<_ACEOF
8550 #line 8550 "configure"
8551 #include "confdefs.h"
8553 /* Override any gcc2 internal prototype to avoid an error. */
8557 /* We use char because int might match the return type of a gcc2
8558 builtin and then its argument prototype would still apply. */
8568 rm -f conftest.$ac_objext conftest$ac_exeext
8569 if { (eval echo "$as_me:8569: \"$ac_link\"") >&5
8570 (eval $ac_link) 2>&5
8572 echo "$as_me:8572: \$? = $ac_status" >&5
8573 (exit $ac_status); } &&
8574 { ac_try='test -s conftest$ac_exeext'
8575 { (eval echo "$as_me:8575: \"$ac_try\"") >&5
8578 echo "$as_me:8578: \$? = $ac_status" >&5
8579 (exit $ac_status); }; }; then
8580 ac_cv_lib_gpm_initscr=yes
8582 echo "$as_me: failed program was:" >&5
8583 cat conftest.$ac_ext >&5
8584 ac_cv_lib_gpm_initscr=no
8586 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8587 LIBS=$ac_check_lib_save_LIBS
8589 echo "$as_me:8589: result: $ac_cv_lib_gpm_initscr" >&5
8590 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
8591 if test $ac_cv_lib_gpm_initscr = yes; then
8592 LIBS="$cf_ncurses_SAVE"
8594 cf_ncurses_LIBS="-lgpm"
8599 case $host_os in #(vi
8601 # This is only necessary if you are linking against an obsolete
8602 # version of ncurses (but it should do no harm, since it's static).
8603 if test "$cf_nculib_root" = ncurses ; then
8604 echo "$as_me:8604: checking for tgoto in -lmytinfo" >&5
8605 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
8606 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
8607 echo $ECHO_N "(cached) $ECHO_C" >&6
8609 ac_check_lib_save_LIBS=$LIBS
8610 LIBS="-lmytinfo $LIBS"
8611 cat >conftest.$ac_ext <<_ACEOF
8612 #line 8612 "configure"
8613 #include "confdefs.h"
8615 /* Override any gcc2 internal prototype to avoid an error. */
8619 /* We use char because int might match the return type of a gcc2
8620 builtin and then its argument prototype would still apply. */
8630 rm -f conftest.$ac_objext conftest$ac_exeext
8631 if { (eval echo "$as_me:8631: \"$ac_link\"") >&5
8632 (eval $ac_link) 2>&5
8634 echo "$as_me:8634: \$? = $ac_status" >&5
8635 (exit $ac_status); } &&
8636 { ac_try='test -s conftest$ac_exeext'
8637 { (eval echo "$as_me:8637: \"$ac_try\"") >&5
8640 echo "$as_me:8640: \$? = $ac_status" >&5
8641 (exit $ac_status); }; }; then
8642 ac_cv_lib_mytinfo_tgoto=yes
8644 echo "$as_me: failed program was:" >&5
8645 cat conftest.$ac_ext >&5
8646 ac_cv_lib_mytinfo_tgoto=no
8648 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8649 LIBS=$ac_check_lib_save_LIBS
8651 echo "$as_me:8651: result: $ac_cv_lib_mytinfo_tgoto" >&5
8652 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
8653 if test $ac_cv_lib_mytinfo_tgoto = yes; then
8654 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
8661 cf_add_libs="$cf_ncurses_LIBS"
8662 # Filter out duplicates - this happens with badly-designed ".pc" files...
8663 for cf_add_1lib in $LIBS
8665 for cf_add_2lib in $cf_add_libs
8667 if test "x$cf_add_1lib" = "x$cf_add_2lib"
8673 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
8677 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
8680 cf_add_libs="-l$cf_nculib_root"
8681 # Filter out duplicates - this happens with badly-designed ".pc" files...
8682 for cf_add_1lib in $LIBS
8684 for cf_add_2lib in $cf_add_libs
8686 if test "x$cf_add_1lib" = "x$cf_add_2lib"
8692 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
8698 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
8700 echo "$as_me:8700: checking for initscr" >&5
8701 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
8702 if test "${ac_cv_func_initscr+set}" = set; then
8703 echo $ECHO_N "(cached) $ECHO_C" >&6
8705 cat >conftest.$ac_ext <<_ACEOF
8706 #line 8706 "configure"
8707 #include "confdefs.h"
8708 /* System header to define __stub macros and hopefully few prototypes,
8709 which can conflict with char initscr (); below. */
8711 /* Override any gcc2 internal prototype to avoid an error. */
8715 /* We use char because int might match the return type of a gcc2
8716 builtin and then its argument prototype would still apply. */
8723 /* The GNU C library defines this for functions which it implements
8724 to always fail with ENOSYS. Some functions are actually named
8725 something starting with __ and the normal name is an alias. */
8726 #if defined (__stub_initscr) || defined (__stub___initscr)
8729 f = initscr; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
8736 rm -f conftest.$ac_objext conftest$ac_exeext
8737 if { (eval echo "$as_me:8737: \"$ac_link\"") >&5
8738 (eval $ac_link) 2>&5
8740 echo "$as_me:8740: \$? = $ac_status" >&5
8741 (exit $ac_status); } &&
8742 { ac_try='test -s conftest$ac_exeext'
8743 { (eval echo "$as_me:8743: \"$ac_try\"") >&5
8746 echo "$as_me:8746: \$? = $ac_status" >&5
8747 (exit $ac_status); }; }; then
8748 ac_cv_func_initscr=yes
8750 echo "$as_me: failed program was:" >&5
8751 cat conftest.$ac_ext >&5
8752 ac_cv_func_initscr=no
8754 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8756 echo "$as_me:8756: result: $ac_cv_func_initscr" >&5
8757 echo "${ECHO_T}$ac_cv_func_initscr" >&6
8758 if test $ac_cv_func_initscr = yes; then
8759 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
8762 cf_save_LIBS="$LIBS"
8763 echo "$as_me:8763: checking for initscr in -l$cf_nculib_root" >&5
8764 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
8765 LIBS="-l$cf_nculib_root $LIBS"
8766 cat >conftest.$ac_ext <<_ACEOF
8767 #line 8767 "configure"
8768 #include "confdefs.h"
8769 #include <${cf_cv_ncurses_header:-curses.h}>
8778 rm -f conftest.$ac_objext conftest$ac_exeext
8779 if { (eval echo "$as_me:8779: \"$ac_link\"") >&5
8780 (eval $ac_link) 2>&5
8782 echo "$as_me:8782: \$? = $ac_status" >&5
8783 (exit $ac_status); } &&
8784 { ac_try='test -s conftest$ac_exeext'
8785 { (eval echo "$as_me:8785: \"$ac_try\"") >&5
8788 echo "$as_me:8788: \$? = $ac_status" >&5
8789 (exit $ac_status); }; }; then
8790 echo "$as_me:8790: result: yes" >&5
8791 echo "${ECHO_T}yes" >&6
8792 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
8795 echo "$as_me: failed program was:" >&5
8796 cat conftest.$ac_ext >&5
8797 echo "$as_me:8797: result: no" >&5
8798 echo "${ECHO_T}no" >&6
8801 cf_library_path_list=""
8802 if test -n "${LDFLAGS}${LIBS}" ; then
8803 for cf_library_path in $LDFLAGS $LIBS
8805 case $cf_library_path in #(vi
8807 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
8809 test "x$cf_library_path" != "xNONE" && \
8810 test -d "$cf_library_path" && \
8812 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
8813 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
8814 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
8815 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
8816 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
8817 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"
8820 cf_library_path_list="$cf_library_path_list $cf_search"
8828 test "x/usr" != "x$prefix" && \
8830 (test -z "$prefix" || test x$prefix = xNONE || test "x/usr" != "x$prefix") && {
8831 test -n "$verbose" && echo " ... testing for lib-directories under /usr"
8832 test -d /usr/lib && cf_search="$cf_search /usr/lib"
8833 test -d /usr/lib/$cf_nculib_root && cf_search="$cf_search /usr/lib/$cf_nculib_root"
8834 test -d /usr/lib/$cf_nculib_root/lib && cf_search="$cf_search /usr/lib/$cf_nculib_root/lib"
8835 test -d /usr/$cf_nculib_root/lib && cf_search="$cf_search /usr/$cf_nculib_root/lib"
8836 test -d /usr/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /usr/$cf_nculib_root/lib/$cf_nculib_root"
8839 test "x$prefix" != "xNONE" && \
8840 test -d "$prefix" && \
8842 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
8843 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
8844 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
8845 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
8846 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
8847 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
8850 test "x/usr/local" != "x$prefix" && \
8851 test -d "/usr/local" && \
8852 (test -z "$prefix" || test x$prefix = xNONE || test "x/usr/local" != "x$prefix") && {
8853 test -n "$verbose" && echo " ... testing for lib-directories under /usr/local"
8854 test -d /usr/local/lib && cf_search="$cf_search /usr/local/lib"
8855 test -d /usr/local/lib/$cf_nculib_root && cf_search="$cf_search /usr/local/lib/$cf_nculib_root"
8856 test -d /usr/local/lib/$cf_nculib_root/lib && cf_search="$cf_search /usr/local/lib/$cf_nculib_root/lib"
8857 test -d /usr/local/$cf_nculib_root/lib && cf_search="$cf_search /usr/local/$cf_nculib_root/lib"
8858 test -d /usr/local/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /usr/local/$cf_nculib_root/lib/$cf_nculib_root"
8861 test "x/opt" != "x$prefix" && \
8863 (test -z "$prefix" || test x$prefix = xNONE || test "x/opt" != "x$prefix") && {
8864 test -n "$verbose" && echo " ... testing for lib-directories under /opt"
8865 test -d /opt/lib && cf_search="$cf_search /opt/lib"
8866 test -d /opt/lib/$cf_nculib_root && cf_search="$cf_search /opt/lib/$cf_nculib_root"
8867 test -d /opt/lib/$cf_nculib_root/lib && cf_search="$cf_search /opt/lib/$cf_nculib_root/lib"
8868 test -d /opt/$cf_nculib_root/lib && cf_search="$cf_search /opt/$cf_nculib_root/lib"
8869 test -d /opt/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /opt/$cf_nculib_root/lib/$cf_nculib_root"
8872 test "x$HOME" != "x$prefix" && \
8873 test -d "$HOME" && \
8874 (test -z "$prefix" || test x$prefix = xNONE || test "x$HOME" != "x$prefix") && {
8875 test -n "$verbose" && echo " ... testing for lib-directories under $HOME"
8876 test -d $HOME/lib && cf_search="$cf_search $HOME/lib"
8877 test -d $HOME/lib/$cf_nculib_root && cf_search="$cf_search $HOME/lib/$cf_nculib_root"
8878 test -d $HOME/lib/$cf_nculib_root/lib && cf_search="$cf_search $HOME/lib/$cf_nculib_root/lib"
8879 test -d $HOME/$cf_nculib_root/lib && cf_search="$cf_search $HOME/$cf_nculib_root/lib"
8880 test -d $HOME/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $HOME/$cf_nculib_root/lib/$cf_nculib_root"
8883 cf_search="$cf_library_path_list $cf_search"
8885 for cf_libdir in $cf_search
8887 echo "$as_me:8887: checking for -l$cf_nculib_root in $cf_libdir" >&5
8888 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
8889 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
8890 cat >conftest.$ac_ext <<_ACEOF
8891 #line 8891 "configure"
8892 #include "confdefs.h"
8893 #include <${cf_cv_ncurses_header:-curses.h}>
8902 rm -f conftest.$ac_objext conftest$ac_exeext
8903 if { (eval echo "$as_me:8903: \"$ac_link\"") >&5
8904 (eval $ac_link) 2>&5
8906 echo "$as_me:8906: \$? = $ac_status" >&5
8907 (exit $ac_status); } &&
8908 { ac_try='test -s conftest$ac_exeext'
8909 { (eval echo "$as_me:8909: \"$ac_try\"") >&5
8912 echo "$as_me:8912: \$? = $ac_status" >&5
8913 (exit $ac_status); }; }; then
8914 echo "$as_me:8914: result: yes" >&5
8915 echo "${ECHO_T}yes" >&6
8916 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
8919 echo "$as_me: failed program was:" >&5
8920 cat conftest.$ac_ext >&5
8921 echo "$as_me:8921: result: no" >&5
8922 echo "${ECHO_T}no" >&6
8923 LIBS="$cf_save_LIBS"
8925 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8929 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8933 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
8935 if test $cf_found_library = no ; then
8936 { { echo "$as_me:8936: error: Cannot link $cf_nculib_root library" >&5
8937 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
8938 { (exit 1); exit 1; }; }
8943 if test -n "$cf_ncurses_LIBS" ; then
8944 echo "$as_me:8944: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
8945 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
8946 cf_ncurses_SAVE="$LIBS"
8947 for p in $cf_ncurses_LIBS ; do
8948 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
8949 if test "$q" != "$LIBS" ; then
8953 cat >conftest.$ac_ext <<_ACEOF
8954 #line 8954 "configure"
8955 #include "confdefs.h"
8956 #include <${cf_cv_ncurses_header:-curses.h}>
8960 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
8965 rm -f conftest.$ac_objext conftest$ac_exeext
8966 if { (eval echo "$as_me:8966: \"$ac_link\"") >&5
8967 (eval $ac_link) 2>&5
8969 echo "$as_me:8969: \$? = $ac_status" >&5
8970 (exit $ac_status); } &&
8971 { ac_try='test -s conftest$ac_exeext'
8972 { (eval echo "$as_me:8972: \"$ac_try\"") >&5
8975 echo "$as_me:8975: \$? = $ac_status" >&5
8976 (exit $ac_status); }; }; then
8977 echo "$as_me:8977: result: yes" >&5
8978 echo "${ECHO_T}yes" >&6
8980 echo "$as_me: failed program was:" >&5
8981 cat conftest.$ac_ext >&5
8982 echo "$as_me:8982: result: no" >&5
8983 echo "${ECHO_T}no" >&6
8984 LIBS="$cf_ncurses_SAVE"
8986 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8989 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
8991 cat >>confdefs.h <<EOF
8992 #define $cf_nculib_ROOT 1
8999 echo "$as_me:8999: checking for X" >&5
9000 echo $ECHO_N "checking for X... $ECHO_C" >&6
9002 # Check whether --with-x or --without-x was given.
9003 if test "${with_x+set}" = set; then
9007 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
9008 if test "x$with_x" = xno; then
9009 # The user explicitly disabled X.
9012 if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
9013 # Both variables are already set.
9016 if test "${ac_cv_have_x+set}" = set; then
9017 echo $ECHO_N "(cached) $ECHO_C" >&6
9019 # One or both of the vars are not set, and there is no cached value.
9020 ac_x_includes=no ac_x_libraries=no
9022 if mkdir conftest.dir; then
9024 # Make sure to not put "make" in the Imakefile rules, since we grep it out.
9025 cat >Imakefile <<'EOF'
9027 @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
9029 if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
9030 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
9031 eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
9032 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
9033 for ac_extension in a so sl dylib dll; do
9034 if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
9035 test -f $ac_im_libdir/libX11.$ac_extension; then
9036 ac_im_usrlibdir=$ac_im_libdir; break
9039 # Screen out bogus values from the imake configuration. They are
9040 # bogus both because they are the default anyway, and because
9041 # using them would break gcc on systems where it needs fixed includes.
9042 case $ac_im_incroot in
9044 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
9046 case $ac_im_usrlibdir in
9048 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
9055 # Standard set of common directories for X headers.
9056 # Check X11 before X11Rn because it is often a symlink to the current release.
9068 /usr/local/X11/include
9069 /usr/local/X11R6/include
9070 /usr/local/X11R5/include
9071 /usr/local/X11R4/include
9073 /usr/local/include/X11
9074 /usr/local/include/X11R6
9075 /usr/local/include/X11R5
9076 /usr/local/include/X11R4
9080 /usr/XFree86/include/X11
9084 /usr/unsupported/include
9086 /usr/local/x11r5/include
9087 /usr/lpp/Xamples/include
9089 /usr/openwin/include
9090 /usr/openwin/share/include'
9092 if test "$ac_x_includes" = no; then
9093 # Guess where to find include files, by looking for Intrinsic.h.
9094 # First, try using that file with no special directory specified.
9095 cat >conftest.$ac_ext <<_ACEOF
9096 #line 9096 "configure"
9097 #include "confdefs.h"
9098 #include <X11/Intrinsic.h>
9100 if { (eval echo "$as_me:9100: \"$ac_cpp conftest.$ac_ext\"") >&5
9101 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9103 egrep -v '^ *\+' conftest.er1 >conftest.err
9105 cat conftest.err >&5
9106 echo "$as_me:9106: \$? = $ac_status" >&5
9107 (exit $ac_status); } >/dev/null; then
9108 if test -s conftest.err; then
9109 ac_cpp_err=$ac_c_preproc_warn_flag
9116 if test -z "$ac_cpp_err"; then
9117 # We can compile using X headers with no special include directory.
9120 echo "$as_me: failed program was:" >&5
9121 cat conftest.$ac_ext >&5
9122 for ac_dir in $ac_x_header_dirs; do
9123 if test -r "$ac_dir/X11/Intrinsic.h"; then
9124 ac_x_includes=$ac_dir
9129 rm -f conftest.err conftest.$ac_ext
9130 fi # $ac_x_includes = no
9132 if test "$ac_x_libraries" = no; then
9133 # Check for the libraries.
9134 # See if we find them without any special options.
9135 # Don't add to $LIBS permanently.
9138 cat >conftest.$ac_ext <<_ACEOF
9139 #line 9139 "configure"
9140 #include "confdefs.h"
9141 #include <X11/Intrinsic.h>
9150 rm -f conftest.$ac_objext conftest$ac_exeext
9151 if { (eval echo "$as_me:9151: \"$ac_link\"") >&5
9152 (eval $ac_link) 2>&5
9154 echo "$as_me:9154: \$? = $ac_status" >&5
9155 (exit $ac_status); } &&
9156 { ac_try='test -s conftest$ac_exeext'
9157 { (eval echo "$as_me:9157: \"$ac_try\"") >&5
9160 echo "$as_me:9160: \$? = $ac_status" >&5
9161 (exit $ac_status); }; }; then
9163 # We can link X programs with no special library path.
9166 echo "$as_me: failed program was:" >&5
9167 cat conftest.$ac_ext >&5
9169 for ac_dir in `echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
9171 # Don't even attempt the hair of trying to link an X program!
9172 for ac_extension in a so sl dylib dll; do
9173 if test -r $ac_dir/libXt.$ac_extension; then
9174 ac_x_libraries=$ac_dir
9180 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9181 fi # $ac_x_libraries = no
9183 if test "$ac_x_includes" = no || test "$ac_x_libraries" = no; then
9184 # Didn't find X anywhere. Cache the known absence of X.
9185 ac_cv_have_x="have_x=no"
9187 # Record where we found X for the cache.
9188 ac_cv_have_x="have_x=yes \
9189 ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
9194 eval "$ac_cv_have_x"
9197 if test "$have_x" != yes; then
9198 echo "$as_me:9198: result: $have_x" >&5
9199 echo "${ECHO_T}$have_x" >&6
9202 # If each of the values was on the command line, it overrides each guess.
9203 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
9204 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
9205 # Update the cache value to reflect the command line values.
9206 ac_cv_have_x="have_x=yes \
9207 ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
9208 echo "$as_me:9208: result: libraries $x_libraries, headers $x_includes" >&5
9209 echo "${ECHO_T}libraries $x_libraries, headers $x_includes" >&6
9212 if test "$no_x" = yes; then
9213 # Not all programs may use this symbol, but it does not hurt to define it.
9215 cat >>confdefs.h <<\EOF
9216 #define X_DISPLAY_MISSING 1
9219 X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS=
9221 if test -n "$x_includes"; then
9222 X_CFLAGS="$X_CFLAGS -I$x_includes"
9225 # It would also be nice to do this for all -L options, not just this one.
9226 if test -n "$x_libraries"; then
9227 X_LIBS="$X_LIBS -L$x_libraries"
9228 # For Solaris; some versions of Sun CC require a space after -R and
9229 # others require no space. Words are not sufficient . . . .
9230 case `(uname -sr) 2>/dev/null` in
9232 echo "$as_me:9232: checking whether -R must be followed by a space" >&5
9233 echo $ECHO_N "checking whether -R must be followed by a space... $ECHO_C" >&6
9234 ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries"
9235 cat >conftest.$ac_ext <<_ACEOF
9236 #line 9236 "configure"
9237 #include "confdefs.h"
9247 rm -f conftest.$ac_objext conftest$ac_exeext
9248 if { (eval echo "$as_me:9248: \"$ac_link\"") >&5
9249 (eval $ac_link) 2>&5
9251 echo "$as_me:9251: \$? = $ac_status" >&5
9252 (exit $ac_status); } &&
9253 { ac_try='test -s conftest$ac_exeext'
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_exeext conftest.$ac_ext
9266 if test $ac_R_nospace = yes; then
9267 echo "$as_me:9267: result: no" >&5
9268 echo "${ECHO_T}no" >&6
9269 X_LIBS="$X_LIBS -R$x_libraries"
9271 LIBS="$ac_xsave_LIBS -R $x_libraries"
9272 cat >conftest.$ac_ext <<_ACEOF
9273 #line 9273 "configure"
9274 #include "confdefs.h"
9284 rm -f conftest.$ac_objext conftest$ac_exeext
9285 if { (eval echo "$as_me:9285: \"$ac_link\"") >&5
9286 (eval $ac_link) 2>&5
9288 echo "$as_me:9288: \$? = $ac_status" >&5
9289 (exit $ac_status); } &&
9290 { ac_try='test -s conftest$ac_exeext'
9291 { (eval echo "$as_me:9291: \"$ac_try\"") >&5
9294 echo "$as_me:9294: \$? = $ac_status" >&5
9295 (exit $ac_status); }; }; then
9298 echo "$as_me: failed program was:" >&5
9299 cat conftest.$ac_ext >&5
9302 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9303 if test $ac_R_space = yes; then
9304 echo "$as_me:9304: result: yes" >&5
9305 echo "${ECHO_T}yes" >&6
9306 X_LIBS="$X_LIBS -R $x_libraries"
9308 echo "$as_me:9308: result: neither works" >&5
9309 echo "${ECHO_T}neither works" >&6
9316 # Check for system-dependent libraries X programs must link with.
9317 # Do this before checking for the system-independent R6 libraries
9318 # (-lICE), since we may need -lsocket or whatever for X linking.
9320 if test "$ISC" = yes; then
9321 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
9323 # Martyn Johnson says this is needed for Ultrix, if the X
9324 # libraries were built with DECnet support. And Karl Berry says
9325 # the Alpha needs dnet_stub (dnet does not exist).
9326 ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11"
9327 cat >conftest.$ac_ext <<_ACEOF
9328 #line 9328 "configure"
9329 #include "confdefs.h"
9331 /* Override any gcc2 internal prototype to avoid an error. */
9335 /* We use char because int might match the return type of a gcc2
9336 builtin and then its argument prototype would still apply. */
9337 char XOpenDisplay ();
9346 rm -f conftest.$ac_objext conftest$ac_exeext
9347 if { (eval echo "$as_me:9347: \"$ac_link\"") >&5
9348 (eval $ac_link) 2>&5
9350 echo "$as_me:9350: \$? = $ac_status" >&5
9351 (exit $ac_status); } &&
9352 { ac_try='test -s conftest$ac_exeext'
9353 { (eval echo "$as_me:9353: \"$ac_try\"") >&5
9356 echo "$as_me:9356: \$? = $ac_status" >&5
9357 (exit $ac_status); }; }; then
9360 echo "$as_me: failed program was:" >&5
9361 cat conftest.$ac_ext >&5
9362 echo "$as_me:9362: checking for dnet_ntoa in -ldnet" >&5
9363 echo $ECHO_N "checking for dnet_ntoa in -ldnet... $ECHO_C" >&6
9364 if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then
9365 echo $ECHO_N "(cached) $ECHO_C" >&6
9367 ac_check_lib_save_LIBS=$LIBS
9369 cat >conftest.$ac_ext <<_ACEOF
9370 #line 9370 "configure"
9371 #include "confdefs.h"
9373 /* Override any gcc2 internal prototype to avoid an error. */
9377 /* We use char because int might match the return type of a gcc2
9378 builtin and then its argument prototype would still apply. */
9388 rm -f conftest.$ac_objext conftest$ac_exeext
9389 if { (eval echo "$as_me:9389: \"$ac_link\"") >&5
9390 (eval $ac_link) 2>&5
9392 echo "$as_me:9392: \$? = $ac_status" >&5
9393 (exit $ac_status); } &&
9394 { ac_try='test -s conftest$ac_exeext'
9395 { (eval echo "$as_me:9395: \"$ac_try\"") >&5
9398 echo "$as_me:9398: \$? = $ac_status" >&5
9399 (exit $ac_status); }; }; then
9400 ac_cv_lib_dnet_dnet_ntoa=yes
9402 echo "$as_me: failed program was:" >&5
9403 cat conftest.$ac_ext >&5
9404 ac_cv_lib_dnet_dnet_ntoa=no
9406 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9407 LIBS=$ac_check_lib_save_LIBS
9409 echo "$as_me:9409: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
9410 echo "${ECHO_T}$ac_cv_lib_dnet_dnet_ntoa" >&6
9411 if test $ac_cv_lib_dnet_dnet_ntoa = yes; then
9412 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
9415 if test $ac_cv_lib_dnet_dnet_ntoa = no; then
9416 echo "$as_me:9416: checking for dnet_ntoa in -ldnet_stub" >&5
9417 echo $ECHO_N "checking for dnet_ntoa in -ldnet_stub... $ECHO_C" >&6
9418 if test "${ac_cv_lib_dnet_stub_dnet_ntoa+set}" = set; then
9419 echo $ECHO_N "(cached) $ECHO_C" >&6
9421 ac_check_lib_save_LIBS=$LIBS
9422 LIBS="-ldnet_stub $LIBS"
9423 cat >conftest.$ac_ext <<_ACEOF
9424 #line 9424 "configure"
9425 #include "confdefs.h"
9427 /* Override any gcc2 internal prototype to avoid an error. */
9431 /* We use char because int might match the return type of a gcc2
9432 builtin and then its argument prototype would still apply. */
9442 rm -f conftest.$ac_objext conftest$ac_exeext
9443 if { (eval echo "$as_me:9443: \"$ac_link\"") >&5
9444 (eval $ac_link) 2>&5
9446 echo "$as_me:9446: \$? = $ac_status" >&5
9447 (exit $ac_status); } &&
9448 { ac_try='test -s conftest$ac_exeext'
9449 { (eval echo "$as_me:9449: \"$ac_try\"") >&5
9452 echo "$as_me:9452: \$? = $ac_status" >&5
9453 (exit $ac_status); }; }; then
9454 ac_cv_lib_dnet_stub_dnet_ntoa=yes
9456 echo "$as_me: failed program was:" >&5
9457 cat conftest.$ac_ext >&5
9458 ac_cv_lib_dnet_stub_dnet_ntoa=no
9460 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9461 LIBS=$ac_check_lib_save_LIBS
9463 echo "$as_me:9463: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5
9464 echo "${ECHO_T}$ac_cv_lib_dnet_stub_dnet_ntoa" >&6
9465 if test $ac_cv_lib_dnet_stub_dnet_ntoa = yes; then
9466 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
9471 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9472 LIBS="$ac_xsave_LIBS"
9474 # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT,
9475 # to get the SysV transport functions.
9476 # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4)
9478 # The nsl library prevents programs from opening the X display
9479 # on Irix 5.2, according to T.E. Dickey.
9480 # The functions gethostbyname, getservbyname, and inet_addr are
9481 # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking.
9482 echo "$as_me:9482: checking for gethostbyname" >&5
9483 echo $ECHO_N "checking for gethostbyname... $ECHO_C" >&6
9484 if test "${ac_cv_func_gethostbyname+set}" = set; then
9485 echo $ECHO_N "(cached) $ECHO_C" >&6
9487 cat >conftest.$ac_ext <<_ACEOF
9488 #line 9488 "configure"
9489 #include "confdefs.h"
9490 /* System header to define __stub macros and hopefully few prototypes,
9491 which can conflict with char gethostbyname (); below. */
9493 /* Override any gcc2 internal prototype to avoid an error. */
9497 /* We use char because int might match the return type of a gcc2
9498 builtin and then its argument prototype would still apply. */
9499 char gethostbyname ();
9505 /* The GNU C library defines this for functions which it implements
9506 to always fail with ENOSYS. Some functions are actually named
9507 something starting with __ and the normal name is an alias. */
9508 #if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
9511 f = gethostbyname; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
9518 rm -f conftest.$ac_objext conftest$ac_exeext
9519 if { (eval echo "$as_me:9519: \"$ac_link\"") >&5
9520 (eval $ac_link) 2>&5
9522 echo "$as_me:9522: \$? = $ac_status" >&5
9523 (exit $ac_status); } &&
9524 { ac_try='test -s conftest$ac_exeext'
9525 { (eval echo "$as_me:9525: \"$ac_try\"") >&5
9528 echo "$as_me:9528: \$? = $ac_status" >&5
9529 (exit $ac_status); }; }; then
9530 ac_cv_func_gethostbyname=yes
9532 echo "$as_me: failed program was:" >&5
9533 cat conftest.$ac_ext >&5
9534 ac_cv_func_gethostbyname=no
9536 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9538 echo "$as_me:9538: result: $ac_cv_func_gethostbyname" >&5
9539 echo "${ECHO_T}$ac_cv_func_gethostbyname" >&6
9541 if test $ac_cv_func_gethostbyname = no; then
9542 echo "$as_me:9542: checking for gethostbyname in -lnsl" >&5
9543 echo $ECHO_N "checking for gethostbyname in -lnsl... $ECHO_C" >&6
9544 if test "${ac_cv_lib_nsl_gethostbyname+set}" = set; then
9545 echo $ECHO_N "(cached) $ECHO_C" >&6
9547 ac_check_lib_save_LIBS=$LIBS
9549 cat >conftest.$ac_ext <<_ACEOF
9550 #line 9550 "configure"
9551 #include "confdefs.h"
9553 /* Override any gcc2 internal prototype to avoid an error. */
9557 /* We use char because int might match the return type of a gcc2
9558 builtin and then its argument prototype would still apply. */
9559 char gethostbyname ();
9568 rm -f conftest.$ac_objext conftest$ac_exeext
9569 if { (eval echo "$as_me:9569: \"$ac_link\"") >&5
9570 (eval $ac_link) 2>&5
9572 echo "$as_me:9572: \$? = $ac_status" >&5
9573 (exit $ac_status); } &&
9574 { ac_try='test -s conftest$ac_exeext'
9575 { (eval echo "$as_me:9575: \"$ac_try\"") >&5
9578 echo "$as_me:9578: \$? = $ac_status" >&5
9579 (exit $ac_status); }; }; then
9580 ac_cv_lib_nsl_gethostbyname=yes
9582 echo "$as_me: failed program was:" >&5
9583 cat conftest.$ac_ext >&5
9584 ac_cv_lib_nsl_gethostbyname=no
9586 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9587 LIBS=$ac_check_lib_save_LIBS
9589 echo "$as_me:9589: result: $ac_cv_lib_nsl_gethostbyname" >&5
9590 echo "${ECHO_T}$ac_cv_lib_nsl_gethostbyname" >&6
9591 if test $ac_cv_lib_nsl_gethostbyname = yes; then
9592 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
9595 if test $ac_cv_lib_nsl_gethostbyname = no; then
9596 echo "$as_me:9596: checking for gethostbyname in -lbsd" >&5
9597 echo $ECHO_N "checking for gethostbyname in -lbsd... $ECHO_C" >&6
9598 if test "${ac_cv_lib_bsd_gethostbyname+set}" = set; then
9599 echo $ECHO_N "(cached) $ECHO_C" >&6
9601 ac_check_lib_save_LIBS=$LIBS
9603 cat >conftest.$ac_ext <<_ACEOF
9604 #line 9604 "configure"
9605 #include "confdefs.h"
9607 /* Override any gcc2 internal prototype to avoid an error. */
9611 /* We use char because int might match the return type of a gcc2
9612 builtin and then its argument prototype would still apply. */
9613 char gethostbyname ();
9622 rm -f conftest.$ac_objext conftest$ac_exeext
9623 if { (eval echo "$as_me:9623: \"$ac_link\"") >&5
9624 (eval $ac_link) 2>&5
9626 echo "$as_me:9626: \$? = $ac_status" >&5
9627 (exit $ac_status); } &&
9628 { ac_try='test -s conftest$ac_exeext'
9629 { (eval echo "$as_me:9629: \"$ac_try\"") >&5
9632 echo "$as_me:9632: \$? = $ac_status" >&5
9633 (exit $ac_status); }; }; then
9634 ac_cv_lib_bsd_gethostbyname=yes
9636 echo "$as_me: failed program was:" >&5
9637 cat conftest.$ac_ext >&5
9638 ac_cv_lib_bsd_gethostbyname=no
9640 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9641 LIBS=$ac_check_lib_save_LIBS
9643 echo "$as_me:9643: result: $ac_cv_lib_bsd_gethostbyname" >&5
9644 echo "${ECHO_T}$ac_cv_lib_bsd_gethostbyname" >&6
9645 if test $ac_cv_lib_bsd_gethostbyname = yes; then
9646 X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd"
9652 # lieder@skyler.mavd.honeywell.com says without -lsocket,
9653 # socket/setsockopt and other routines are undefined under SCO ODT
9654 # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary
9655 # on later versions), says Simon Leinen: it contains gethostby*
9656 # variants that don't use the nameserver (or something). -lsocket
9657 # must be given before -lnsl if both are needed. We assume that
9658 # if connect needs -lnsl, so does gethostbyname.
9659 echo "$as_me:9659: checking for connect" >&5
9660 echo $ECHO_N "checking for connect... $ECHO_C" >&6
9661 if test "${ac_cv_func_connect+set}" = set; then
9662 echo $ECHO_N "(cached) $ECHO_C" >&6
9664 cat >conftest.$ac_ext <<_ACEOF
9665 #line 9665 "configure"
9666 #include "confdefs.h"
9667 /* System header to define __stub macros and hopefully few prototypes,
9668 which can conflict with char connect (); below. */
9670 /* Override any gcc2 internal prototype to avoid an error. */
9674 /* We use char because int might match the return type of a gcc2
9675 builtin and then its argument prototype would still apply. */
9682 /* The GNU C library defines this for functions which it implements
9683 to always fail with ENOSYS. Some functions are actually named
9684 something starting with __ and the normal name is an alias. */
9685 #if defined (__stub_connect) || defined (__stub___connect)
9688 f = connect; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
9695 rm -f conftest.$ac_objext conftest$ac_exeext
9696 if { (eval echo "$as_me:9696: \"$ac_link\"") >&5
9697 (eval $ac_link) 2>&5
9699 echo "$as_me:9699: \$? = $ac_status" >&5
9700 (exit $ac_status); } &&
9701 { ac_try='test -s conftest$ac_exeext'
9702 { (eval echo "$as_me:9702: \"$ac_try\"") >&5
9705 echo "$as_me:9705: \$? = $ac_status" >&5
9706 (exit $ac_status); }; }; then
9707 ac_cv_func_connect=yes
9709 echo "$as_me: failed program was:" >&5
9710 cat conftest.$ac_ext >&5
9711 ac_cv_func_connect=no
9713 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9715 echo "$as_me:9715: result: $ac_cv_func_connect" >&5
9716 echo "${ECHO_T}$ac_cv_func_connect" >&6
9718 if test $ac_cv_func_connect = no; then
9719 echo "$as_me:9719: checking for connect in -lsocket" >&5
9720 echo $ECHO_N "checking for connect in -lsocket... $ECHO_C" >&6
9721 if test "${ac_cv_lib_socket_connect+set}" = set; then
9722 echo $ECHO_N "(cached) $ECHO_C" >&6
9724 ac_check_lib_save_LIBS=$LIBS
9725 LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
9726 cat >conftest.$ac_ext <<_ACEOF
9727 #line 9727 "configure"
9728 #include "confdefs.h"
9730 /* Override any gcc2 internal prototype to avoid an error. */
9734 /* We use char because int might match the return type of a gcc2
9735 builtin and then its argument prototype would still apply. */
9745 rm -f conftest.$ac_objext conftest$ac_exeext
9746 if { (eval echo "$as_me:9746: \"$ac_link\"") >&5
9747 (eval $ac_link) 2>&5
9749 echo "$as_me:9749: \$? = $ac_status" >&5
9750 (exit $ac_status); } &&
9751 { ac_try='test -s conftest$ac_exeext'
9752 { (eval echo "$as_me:9752: \"$ac_try\"") >&5
9755 echo "$as_me:9755: \$? = $ac_status" >&5
9756 (exit $ac_status); }; }; then
9757 ac_cv_lib_socket_connect=yes
9759 echo "$as_me: failed program was:" >&5
9760 cat conftest.$ac_ext >&5
9761 ac_cv_lib_socket_connect=no
9763 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9764 LIBS=$ac_check_lib_save_LIBS
9766 echo "$as_me:9766: result: $ac_cv_lib_socket_connect" >&5
9767 echo "${ECHO_T}$ac_cv_lib_socket_connect" >&6
9768 if test $ac_cv_lib_socket_connect = yes; then
9769 X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS"
9774 # Guillermo Gomez says -lposix is necessary on A/UX.
9775 echo "$as_me:9775: checking for remove" >&5
9776 echo $ECHO_N "checking for remove... $ECHO_C" >&6
9777 if test "${ac_cv_func_remove+set}" = set; then
9778 echo $ECHO_N "(cached) $ECHO_C" >&6
9780 cat >conftest.$ac_ext <<_ACEOF
9781 #line 9781 "configure"
9782 #include "confdefs.h"
9783 /* System header to define __stub macros and hopefully few prototypes,
9784 which can conflict with char remove (); below. */
9786 /* Override any gcc2 internal prototype to avoid an error. */
9790 /* We use char because int might match the return type of a gcc2
9791 builtin and then its argument prototype would still apply. */
9798 /* The GNU C library defines this for functions which it implements
9799 to always fail with ENOSYS. Some functions are actually named
9800 something starting with __ and the normal name is an alias. */
9801 #if defined (__stub_remove) || defined (__stub___remove)
9804 f = remove; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
9811 rm -f conftest.$ac_objext conftest$ac_exeext
9812 if { (eval echo "$as_me:9812: \"$ac_link\"") >&5
9813 (eval $ac_link) 2>&5
9815 echo "$as_me:9815: \$? = $ac_status" >&5
9816 (exit $ac_status); } &&
9817 { ac_try='test -s conftest$ac_exeext'
9818 { (eval echo "$as_me:9818: \"$ac_try\"") >&5
9821 echo "$as_me:9821: \$? = $ac_status" >&5
9822 (exit $ac_status); }; }; then
9823 ac_cv_func_remove=yes
9825 echo "$as_me: failed program was:" >&5
9826 cat conftest.$ac_ext >&5
9827 ac_cv_func_remove=no
9829 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9831 echo "$as_me:9831: result: $ac_cv_func_remove" >&5
9832 echo "${ECHO_T}$ac_cv_func_remove" >&6
9834 if test $ac_cv_func_remove = no; then
9835 echo "$as_me:9835: checking for remove in -lposix" >&5
9836 echo $ECHO_N "checking for remove in -lposix... $ECHO_C" >&6
9837 if test "${ac_cv_lib_posix_remove+set}" = set; then
9838 echo $ECHO_N "(cached) $ECHO_C" >&6
9840 ac_check_lib_save_LIBS=$LIBS
9841 LIBS="-lposix $LIBS"
9842 cat >conftest.$ac_ext <<_ACEOF
9843 #line 9843 "configure"
9844 #include "confdefs.h"
9846 /* Override any gcc2 internal prototype to avoid an error. */
9850 /* We use char because int might match the return type of a gcc2
9851 builtin and then its argument prototype would still apply. */
9861 rm -f conftest.$ac_objext conftest$ac_exeext
9862 if { (eval echo "$as_me:9862: \"$ac_link\"") >&5
9863 (eval $ac_link) 2>&5
9865 echo "$as_me:9865: \$? = $ac_status" >&5
9866 (exit $ac_status); } &&
9867 { ac_try='test -s conftest$ac_exeext'
9868 { (eval echo "$as_me:9868: \"$ac_try\"") >&5
9871 echo "$as_me:9871: \$? = $ac_status" >&5
9872 (exit $ac_status); }; }; then
9873 ac_cv_lib_posix_remove=yes
9875 echo "$as_me: failed program was:" >&5
9876 cat conftest.$ac_ext >&5
9877 ac_cv_lib_posix_remove=no
9879 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9880 LIBS=$ac_check_lib_save_LIBS
9882 echo "$as_me:9882: result: $ac_cv_lib_posix_remove" >&5
9883 echo "${ECHO_T}$ac_cv_lib_posix_remove" >&6
9884 if test $ac_cv_lib_posix_remove = yes; then
9885 X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix"
9890 # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
9891 echo "$as_me:9891: checking for shmat" >&5
9892 echo $ECHO_N "checking for shmat... $ECHO_C" >&6
9893 if test "${ac_cv_func_shmat+set}" = set; then
9894 echo $ECHO_N "(cached) $ECHO_C" >&6
9896 cat >conftest.$ac_ext <<_ACEOF
9897 #line 9897 "configure"
9898 #include "confdefs.h"
9899 /* System header to define __stub macros and hopefully few prototypes,
9900 which can conflict with char shmat (); below. */
9902 /* Override any gcc2 internal prototype to avoid an error. */
9906 /* We use char because int might match the return type of a gcc2
9907 builtin and then its argument prototype would still apply. */
9914 /* The GNU C library defines this for functions which it implements
9915 to always fail with ENOSYS. Some functions are actually named
9916 something starting with __ and the normal name is an alias. */
9917 #if defined (__stub_shmat) || defined (__stub___shmat)
9920 f = shmat; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
9927 rm -f conftest.$ac_objext conftest$ac_exeext
9928 if { (eval echo "$as_me:9928: \"$ac_link\"") >&5
9929 (eval $ac_link) 2>&5
9931 echo "$as_me:9931: \$? = $ac_status" >&5
9932 (exit $ac_status); } &&
9933 { ac_try='test -s conftest$ac_exeext'
9934 { (eval echo "$as_me:9934: \"$ac_try\"") >&5
9937 echo "$as_me:9937: \$? = $ac_status" >&5
9938 (exit $ac_status); }; }; then
9939 ac_cv_func_shmat=yes
9941 echo "$as_me: failed program was:" >&5
9942 cat conftest.$ac_ext >&5
9945 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9947 echo "$as_me:9947: result: $ac_cv_func_shmat" >&5
9948 echo "${ECHO_T}$ac_cv_func_shmat" >&6
9950 if test $ac_cv_func_shmat = no; then
9951 echo "$as_me:9951: checking for shmat in -lipc" >&5
9952 echo $ECHO_N "checking for shmat in -lipc... $ECHO_C" >&6
9953 if test "${ac_cv_lib_ipc_shmat+set}" = set; then
9954 echo $ECHO_N "(cached) $ECHO_C" >&6
9956 ac_check_lib_save_LIBS=$LIBS
9958 cat >conftest.$ac_ext <<_ACEOF
9959 #line 9959 "configure"
9960 #include "confdefs.h"
9962 /* Override any gcc2 internal prototype to avoid an error. */
9966 /* We use char because int might match the return type of a gcc2
9967 builtin and then its argument prototype would still apply. */
9977 rm -f conftest.$ac_objext conftest$ac_exeext
9978 if { (eval echo "$as_me:9978: \"$ac_link\"") >&5
9979 (eval $ac_link) 2>&5
9981 echo "$as_me:9981: \$? = $ac_status" >&5
9982 (exit $ac_status); } &&
9983 { ac_try='test -s conftest$ac_exeext'
9984 { (eval echo "$as_me:9984: \"$ac_try\"") >&5
9987 echo "$as_me:9987: \$? = $ac_status" >&5
9988 (exit $ac_status); }; }; then
9989 ac_cv_lib_ipc_shmat=yes
9991 echo "$as_me: failed program was:" >&5
9992 cat conftest.$ac_ext >&5
9993 ac_cv_lib_ipc_shmat=no
9995 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9996 LIBS=$ac_check_lib_save_LIBS
9998 echo "$as_me:9998: result: $ac_cv_lib_ipc_shmat" >&5
9999 echo "${ECHO_T}$ac_cv_lib_ipc_shmat" >&6
10000 if test $ac_cv_lib_ipc_shmat = yes; then
10001 X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc"
10007 # Check for libraries that X11R6 Xt/Xaw programs need.
10008 ac_save_LDFLAGS=$LDFLAGS
10009 test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries"
10010 # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
10011 # check for ICE first), but we must link in the order -lSM -lICE or
10012 # we get undefined symbols. So assume we have SM if we have ICE.
10013 # These have to be linked with before -lX11, unlike the other
10014 # libraries we check for below, so use a different variable.
10015 # John Interrante, Karl Berry
10016 echo "$as_me:10016: checking for IceConnectionNumber in -lICE" >&5
10017 echo $ECHO_N "checking for IceConnectionNumber in -lICE... $ECHO_C" >&6
10018 if test "${ac_cv_lib_ICE_IceConnectionNumber+set}" = set; then
10019 echo $ECHO_N "(cached) $ECHO_C" >&6
10021 ac_check_lib_save_LIBS=$LIBS
10022 LIBS="-lICE $X_EXTRA_LIBS $LIBS"
10023 cat >conftest.$ac_ext <<_ACEOF
10024 #line 10024 "configure"
10025 #include "confdefs.h"
10027 /* Override any gcc2 internal prototype to avoid an error. */
10031 /* We use char because int might match the return type of a gcc2
10032 builtin and then its argument prototype would still apply. */
10033 char IceConnectionNumber ();
10037 IceConnectionNumber ();
10042 rm -f conftest.$ac_objext conftest$ac_exeext
10043 if { (eval echo "$as_me:10043: \"$ac_link\"") >&5
10044 (eval $ac_link) 2>&5
10046 echo "$as_me:10046: \$? = $ac_status" >&5
10047 (exit $ac_status); } &&
10048 { ac_try='test -s conftest$ac_exeext'
10049 { (eval echo "$as_me:10049: \"$ac_try\"") >&5
10050 (eval $ac_try) 2>&5
10052 echo "$as_me:10052: \$? = $ac_status" >&5
10053 (exit $ac_status); }; }; then
10054 ac_cv_lib_ICE_IceConnectionNumber=yes
10056 echo "$as_me: failed program was:" >&5
10057 cat conftest.$ac_ext >&5
10058 ac_cv_lib_ICE_IceConnectionNumber=no
10060 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10061 LIBS=$ac_check_lib_save_LIBS
10063 echo "$as_me:10063: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5
10064 echo "${ECHO_T}$ac_cv_lib_ICE_IceConnectionNumber" >&6
10065 if test $ac_cv_lib_ICE_IceConnectionNumber = yes; then
10066 X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
10069 LDFLAGS=$ac_save_LDFLAGS
10073 cf_x_athena=${cf_x_athena:-Xaw}
10075 echo "$as_me:10075: checking if you want to link with Xaw 3d library" >&5
10076 echo $ECHO_N "checking if you want to link with Xaw 3d library... $ECHO_C" >&6
10079 # Check whether --with-Xaw3d or --without-Xaw3d was given.
10080 if test "${with_Xaw3d+set}" = set; then
10081 withval="$with_Xaw3d"
10084 if test "$withval" = yes ; then
10086 echo "$as_me:10086: result: yes" >&5
10087 echo "${ECHO_T}yes" >&6
10089 echo "$as_me:10089: result: no" >&5
10090 echo "${ECHO_T}no" >&6
10093 echo "$as_me:10093: checking if you want to link with Xaw 3d xft library" >&5
10094 echo $ECHO_N "checking if you want to link with Xaw 3d xft library... $ECHO_C" >&6
10097 # Check whether --with-Xaw3dxft or --without-Xaw3dxft was given.
10098 if test "${with_Xaw3dxft+set}" = set; then
10099 withval="$with_Xaw3dxft"
10102 if test "$withval" = yes ; then
10103 cf_x_athena=Xaw3dxft
10104 echo "$as_me:10104: result: yes" >&5
10105 echo "${ECHO_T}yes" >&6
10107 echo "$as_me:10107: result: no" >&5
10108 echo "${ECHO_T}no" >&6
10111 echo "$as_me:10111: checking if you want to link with neXT Athena library" >&5
10112 echo $ECHO_N "checking if you want to link with neXT Athena library... $ECHO_C" >&6
10115 # Check whether --with-neXtaw or --without-neXtaw was given.
10116 if test "${with_neXtaw+set}" = set; then
10117 withval="$with_neXtaw"
10120 if test "$withval" = yes ; then
10122 echo "$as_me:10122: result: yes" >&5
10123 echo "${ECHO_T}yes" >&6
10125 echo "$as_me:10125: result: no" >&5
10126 echo "${ECHO_T}no" >&6
10129 echo "$as_me:10129: checking if you want to link with Athena-Plus library" >&5
10130 echo $ECHO_N "checking if you want to link with Athena-Plus library... $ECHO_C" >&6
10133 # Check whether --with-XawPlus or --without-XawPlus was given.
10134 if test "${with_XawPlus+set}" = set; then
10135 withval="$with_XawPlus"
10138 if test "$withval" = yes ; then
10139 cf_x_athena=XawPlus
10140 echo "$as_me:10140: result: yes" >&5
10141 echo "${ECHO_T}yes" >&6
10143 echo "$as_me:10143: result: no" >&5
10144 echo "${ECHO_T}no" >&6
10149 if test "$PKG_CONFIG" != none ; then
10151 test "$cf_x_athena" = Xaw && cf_athena_list="xaw8 xaw7 xaw6"
10152 for cf_athena_pkg in \
10155 ${cf_x_athena}-devel \
10156 lib${cf_x_athena} \
10157 lib${cf_x_athena}-devel
10160 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists $cf_athena_pkg; then
10161 test -n "$verbose" && echo " found package $cf_athena_pkg" 1>&6
10163 echo "${as_me:-configure}:10163: testing found package $cf_athena_pkg ..." 1>&5
10165 cf_pkgconfig_incs="`$PKG_CONFIG --cflags $cf_athena_pkg 2>/dev/null`"
10166 cf_pkgconfig_libs="`$PKG_CONFIG --libs $cf_athena_pkg 2>/dev/null`"
10167 test -n "$verbose" && echo " package $cf_athena_pkg CFLAGS: $cf_pkgconfig_incs" 1>&6
10169 echo "${as_me:-configure}:10169: testing package $cf_athena_pkg CFLAGS: $cf_pkgconfig_incs ..." 1>&5
10171 test -n "$verbose" && echo " package $cf_athena_pkg LIBS: $cf_pkgconfig_libs" 1>&6
10173 echo "${as_me:-configure}:10173: testing package $cf_athena_pkg LIBS: $cf_pkgconfig_libs ..." 1>&5
10178 cf_new_extra_cppflags=
10180 for cf_add_cflags in $cf_pkgconfig_incs
10182 case $cf_fix_cppflags in
10184 case $cf_add_cflags in #(vi
10185 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
10186 case $cf_add_cflags in
10188 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10190 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10191 && test -z "${cf_tst_cflags}" \
10192 && cf_fix_cppflags=yes
10194 if test $cf_fix_cppflags = yes ; then
10195 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10197 elif test "${cf_tst_cflags}" = "\"'" ; then
10198 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10203 case "$CPPFLAGS" in
10204 *$cf_add_cflags) #(vi
10207 case $cf_add_cflags in #(vi
10209 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10211 CPPFLAGS=`echo "$CPPFLAGS" | \
10212 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10213 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10217 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
10222 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
10227 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10229 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10231 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10232 && test -z "${cf_tst_cflags}" \
10233 && cf_fix_cppflags=no
10238 if test -n "$cf_new_cflags" ; then
10240 CFLAGS="$CFLAGS $cf_new_cflags"
10243 if test -n "$cf_new_cppflags" ; then
10245 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
10248 if test -n "$cf_new_extra_cppflags" ; then
10250 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
10253 cf_add_libs="$cf_pkgconfig_libs"
10254 # Filter out duplicates - this happens with badly-designed ".pc" files...
10255 for cf_add_1lib in $LIBS
10257 for cf_add_2lib in $cf_add_libs
10259 if test "x$cf_add_1lib" = "x$cf_add_2lib"
10265 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
10267 LIBS="$cf_add_libs"
10269 cf_x_athena_lib="$cf_pkgconfig_libs"
10271 cf_x_athena_LIBS=`echo "HAVE_LIB_$cf_x_athena" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
10273 cat >>confdefs.h <<EOF
10274 #define $cf_x_athena_LIBS 1
10277 for cf_trim_lib in Xmu Xt X11
10280 *-l$cf_trim_lib\ *-l$cf_trim_lib*)
10281 LIBS=`echo "$LIBS " | sed -e 's/ / /g' -e 's%-l'"$cf_trim_lib"' %%' -e 's/ $//'`
10282 test -n "$verbose" && echo " ..trimmed $LIBS" 1>&6
10284 echo "${as_me:-configure}:10284: testing ..trimmed $LIBS ..." 1>&5
10290 echo "$as_me:10290: checking for usable $cf_x_athena/Xmu package" >&5
10291 echo $ECHO_N "checking for usable $cf_x_athena/Xmu package... $ECHO_C" >&6
10292 if test "${cf_cv_xaw_compat+set}" = set; then
10293 echo $ECHO_N "(cached) $ECHO_C" >&6
10296 cat >conftest.$ac_ext <<_ACEOF
10297 #line 10297 "configure"
10298 #include "confdefs.h"
10300 #include <X11/Xmu/CharSet.h>
10306 int check = XmuCompareISOLatin1("big", "small")
10312 rm -f conftest.$ac_objext conftest$ac_exeext
10313 if { (eval echo "$as_me:10313: \"$ac_link\"") >&5
10314 (eval $ac_link) 2>&5
10316 echo "$as_me:10316: \$? = $ac_status" >&5
10317 (exit $ac_status); } &&
10318 { ac_try='test -s conftest$ac_exeext'
10319 { (eval echo "$as_me:10319: \"$ac_try\"") >&5
10320 (eval $ac_try) 2>&5
10322 echo "$as_me:10322: \$? = $ac_status" >&5
10323 (exit $ac_status); }; }; then
10324 cf_cv_xaw_compat=yes
10326 echo "$as_me: failed program was:" >&5
10327 cat conftest.$ac_ext >&5
10328 cf_cv_xaw_compat=no
10330 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10332 echo "$as_me:10332: result: $cf_cv_xaw_compat" >&5
10333 echo "${ECHO_T}$cf_cv_xaw_compat" >&6
10335 if test "$cf_cv_xaw_compat" = no
10337 # workaround for broken ".pc" files...
10338 case "$cf_x_athena_lib" in #(vi
10342 test -n "$verbose" && echo " work around broken package" 1>&6
10344 echo "${as_me:-configure}:10344: testing work around broken package ..." 1>&5
10346 cf_save_xmu="$LIBS"
10347 cf_first_lib=`echo "$cf_save_xmu" | sed -e 's/^ *//' -e 's/ .*//'`
10349 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xmu; then
10350 test -n "$verbose" && echo " found package xmu" 1>&6
10352 echo "${as_me:-configure}:10352: testing found package xmu ..." 1>&5
10354 cf_pkgconfig_incs="`$PKG_CONFIG --cflags xmu 2>/dev/null`"
10355 cf_pkgconfig_libs="`$PKG_CONFIG --libs xmu 2>/dev/null`"
10356 test -n "$verbose" && echo " package xmu CFLAGS: $cf_pkgconfig_incs" 1>&6
10358 echo "${as_me:-configure}:10358: testing package xmu CFLAGS: $cf_pkgconfig_incs ..." 1>&5
10360 test -n "$verbose" && echo " package xmu LIBS: $cf_pkgconfig_libs" 1>&6
10362 echo "${as_me:-configure}:10362: testing package xmu LIBS: $cf_pkgconfig_libs ..." 1>&5
10367 cf_new_extra_cppflags=
10369 for cf_add_cflags in $cf_pkgconfig_incs
10371 case $cf_fix_cppflags in
10373 case $cf_add_cflags in #(vi
10374 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
10375 case $cf_add_cflags in
10377 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10379 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10380 && test -z "${cf_tst_cflags}" \
10381 && cf_fix_cppflags=yes
10383 if test $cf_fix_cppflags = yes ; then
10384 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10386 elif test "${cf_tst_cflags}" = "\"'" ; then
10387 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10392 case "$CPPFLAGS" in
10393 *$cf_add_cflags) #(vi
10396 case $cf_add_cflags in #(vi
10398 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10400 CPPFLAGS=`echo "$CPPFLAGS" | \
10401 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10402 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10406 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
10411 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
10416 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10418 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10420 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10421 && test -z "${cf_tst_cflags}" \
10422 && cf_fix_cppflags=no
10427 if test -n "$cf_new_cflags" ; then
10429 CFLAGS="$CFLAGS $cf_new_cflags"
10432 if test -n "$cf_new_cppflags" ; then
10434 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
10437 if test -n "$cf_new_extra_cppflags" ; then
10439 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
10442 cf_add_libs="$cf_pkgconfig_libs"
10443 # Filter out duplicates - this happens with badly-designed ".pc" files...
10444 for cf_add_1lib in $LIBS
10446 for cf_add_2lib in $cf_add_libs
10448 if test "x$cf_add_1lib" = "x$cf_add_2lib"
10454 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
10456 LIBS="$cf_add_libs"
10458 LIBS="$cf_save_xmu"
10460 test -n "$verbose" && echo " ...before $LIBS" 1>&6
10462 echo "${as_me:-configure}:10462: testing ...before $LIBS ..." 1>&5
10464 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%$cf_first_lib %$cf_first_lib $cf_pkgconfig_libs %" -e 's% % %g'`
10465 test -n "$verbose" && echo " ...after $LIBS" 1>&6
10467 echo "${as_me:-configure}:10467: testing ...after $LIBS ..." 1>&5
10473 test -n "$verbose" && echo " ...before $LIBS" 1>&6
10475 echo "${as_me:-configure}:10475: testing ...before $LIBS ..." 1>&5
10477 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%$cf_first_lib %$cf_first_lib -lXmu %" -e 's% % %g'`
10478 test -n "$verbose" && echo " ...after $LIBS" 1>&6
10480 echo "${as_me:-configure}:10480: testing ...after $LIBS ..." 1>&5
10484 for cf_trim_lib in Xmu Xt X11
10487 *-l$cf_trim_lib\ *-l$cf_trim_lib*)
10488 LIBS=`echo "$LIBS " | sed -e 's/ / /g' -e 's%-l'"$cf_trim_lib"' %%' -e 's/ $//'`
10489 test -n "$verbose" && echo " ..trimmed $LIBS" 1>&6
10491 echo "${as_me:-configure}:10491: testing ..trimmed $LIBS ..." 1>&5
10511 if test -z "$cf_x_athena_lib" ; then
10513 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists Xext; then
10514 test -n "$verbose" && echo " found package Xext" 1>&6
10516 echo "${as_me:-configure}:10516: testing found package Xext ..." 1>&5
10518 cf_pkgconfig_incs="`$PKG_CONFIG --cflags Xext 2>/dev/null`"
10519 cf_pkgconfig_libs="`$PKG_CONFIG --libs Xext 2>/dev/null`"
10520 test -n "$verbose" && echo " package Xext CFLAGS: $cf_pkgconfig_incs" 1>&6
10522 echo "${as_me:-configure}:10522: testing package Xext CFLAGS: $cf_pkgconfig_incs ..." 1>&5
10524 test -n "$verbose" && echo " package Xext LIBS: $cf_pkgconfig_libs" 1>&6
10526 echo "${as_me:-configure}:10526: testing package Xext LIBS: $cf_pkgconfig_libs ..." 1>&5
10531 cf_new_extra_cppflags=
10533 for cf_add_cflags in $cf_pkgconfig_incs
10535 case $cf_fix_cppflags in
10537 case $cf_add_cflags in #(vi
10538 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
10539 case $cf_add_cflags in
10541 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10543 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10544 && test -z "${cf_tst_cflags}" \
10545 && cf_fix_cppflags=yes
10547 if test $cf_fix_cppflags = yes ; then
10548 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10550 elif test "${cf_tst_cflags}" = "\"'" ; then
10551 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10556 case "$CPPFLAGS" in
10557 *$cf_add_cflags) #(vi
10560 case $cf_add_cflags in #(vi
10562 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10564 CPPFLAGS=`echo "$CPPFLAGS" | \
10565 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10566 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10570 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
10575 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
10580 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10582 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10584 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10585 && test -z "${cf_tst_cflags}" \
10586 && cf_fix_cppflags=no
10591 if test -n "$cf_new_cflags" ; then
10593 CFLAGS="$CFLAGS $cf_new_cflags"
10596 if test -n "$cf_new_cppflags" ; then
10598 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
10601 if test -n "$cf_new_extra_cppflags" ; then
10603 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
10606 cf_add_libs="$cf_pkgconfig_libs"
10607 # Filter out duplicates - this happens with badly-designed ".pc" files...
10608 for cf_add_1lib in $LIBS
10610 for cf_add_2lib in $cf_add_libs
10612 if test "x$cf_add_1lib" = "x$cf_add_2lib"
10618 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
10620 LIBS="$cf_add_libs"
10627 echo "$as_me:10627: checking for XextCreateExtension in -lXext" >&5
10628 echo $ECHO_N "checking for XextCreateExtension in -lXext... $ECHO_C" >&6
10629 if test "${ac_cv_lib_Xext_XextCreateExtension+set}" = set; then
10630 echo $ECHO_N "(cached) $ECHO_C" >&6
10632 ac_check_lib_save_LIBS=$LIBS
10633 LIBS="-lXext $LIBS"
10634 cat >conftest.$ac_ext <<_ACEOF
10635 #line 10635 "configure"
10636 #include "confdefs.h"
10638 /* Override any gcc2 internal prototype to avoid an error. */
10642 /* We use char because int might match the return type of a gcc2
10643 builtin and then its argument prototype would still apply. */
10644 char XextCreateExtension ();
10648 XextCreateExtension ();
10653 rm -f conftest.$ac_objext conftest$ac_exeext
10654 if { (eval echo "$as_me:10654: \"$ac_link\"") >&5
10655 (eval $ac_link) 2>&5
10657 echo "$as_me:10657: \$? = $ac_status" >&5
10658 (exit $ac_status); } &&
10659 { ac_try='test -s conftest$ac_exeext'
10660 { (eval echo "$as_me:10660: \"$ac_try\"") >&5
10661 (eval $ac_try) 2>&5
10663 echo "$as_me:10663: \$? = $ac_status" >&5
10664 (exit $ac_status); }; }; then
10665 ac_cv_lib_Xext_XextCreateExtension=yes
10667 echo "$as_me: failed program was:" >&5
10668 cat conftest.$ac_ext >&5
10669 ac_cv_lib_Xext_XextCreateExtension=no
10671 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10672 LIBS=$ac_check_lib_save_LIBS
10674 echo "$as_me:10674: result: $ac_cv_lib_Xext_XextCreateExtension" >&5
10675 echo "${ECHO_T}$ac_cv_lib_Xext_XextCreateExtension" >&6
10676 if test $ac_cv_lib_Xext_XextCreateExtension = yes; then
10678 cf_add_libs="-lXext"
10679 # Filter out duplicates - this happens with badly-designed ".pc" files...
10680 for cf_add_1lib in $LIBS
10682 for cf_add_2lib in $cf_add_libs
10684 if test "x$cf_add_1lib" = "x$cf_add_2lib"
10690 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
10692 LIBS="$cf_add_libs"
10698 # OSX is schizoid about who owns /usr/X11 (old) versus /opt/X11 (new), and (and
10699 # in some cases has installed dummy files in the former, other cases replaced
10700 # it with a link to the new location). This complicates the configure script.
10701 # Check for that pitfall, and recover using pkg-config
10703 # If none of these are set, the configuration is almost certainly broken.
10704 if test -z "${X_CFLAGS}${X_PRE_LIBS}${X_LIBS}${X_EXTRA_LIBS}"
10707 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists x11; then
10708 test -n "$verbose" && echo " found package x11" 1>&6
10710 echo "${as_me:-configure}:10710: testing found package x11 ..." 1>&5
10712 cf_pkgconfig_incs="`$PKG_CONFIG --cflags x11 2>/dev/null`"
10713 cf_pkgconfig_libs="`$PKG_CONFIG --libs x11 2>/dev/null`"
10714 test -n "$verbose" && echo " package x11 CFLAGS: $cf_pkgconfig_incs" 1>&6
10716 echo "${as_me:-configure}:10716: testing package x11 CFLAGS: $cf_pkgconfig_incs ..." 1>&5
10718 test -n "$verbose" && echo " package x11 LIBS: $cf_pkgconfig_libs" 1>&6
10720 echo "${as_me:-configure}:10720: testing package x11 LIBS: $cf_pkgconfig_libs ..." 1>&5
10725 cf_new_extra_cppflags=
10727 for cf_add_cflags in $cf_pkgconfig_incs
10729 case $cf_fix_cppflags in
10731 case $cf_add_cflags in #(vi
10732 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
10733 case $cf_add_cflags in
10735 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10737 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10738 && test -z "${cf_tst_cflags}" \
10739 && cf_fix_cppflags=yes
10741 if test $cf_fix_cppflags = yes ; then
10742 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10744 elif test "${cf_tst_cflags}" = "\"'" ; then
10745 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10750 case "$CPPFLAGS" in
10751 *$cf_add_cflags) #(vi
10754 case $cf_add_cflags in #(vi
10756 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10758 CPPFLAGS=`echo "$CPPFLAGS" | \
10759 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10760 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10764 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
10769 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
10774 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10776 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10778 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10779 && test -z "${cf_tst_cflags}" \
10780 && cf_fix_cppflags=no
10785 if test -n "$cf_new_cflags" ; then
10787 CFLAGS="$CFLAGS $cf_new_cflags"
10790 if test -n "$cf_new_cppflags" ; then
10792 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
10795 if test -n "$cf_new_extra_cppflags" ; then
10797 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
10800 cf_add_libs="$cf_pkgconfig_libs"
10801 # Filter out duplicates - this happens with badly-designed ".pc" files...
10802 for cf_add_1lib in $LIBS
10804 for cf_add_2lib in $cf_add_libs
10806 if test "x$cf_add_1lib" = "x$cf_add_2lib"
10812 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
10814 LIBS="$cf_add_libs"
10820 { echo "$as_me:10820: WARNING: unable to find X11 library" >&5
10821 echo "$as_me: WARNING: unable to find X11 library" >&2;}
10824 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists ice; then
10825 test -n "$verbose" && echo " found package ice" 1>&6
10827 echo "${as_me:-configure}:10827: testing found package ice ..." 1>&5
10829 cf_pkgconfig_incs="`$PKG_CONFIG --cflags ice 2>/dev/null`"
10830 cf_pkgconfig_libs="`$PKG_CONFIG --libs ice 2>/dev/null`"
10831 test -n "$verbose" && echo " package ice CFLAGS: $cf_pkgconfig_incs" 1>&6
10833 echo "${as_me:-configure}:10833: testing package ice CFLAGS: $cf_pkgconfig_incs ..." 1>&5
10835 test -n "$verbose" && echo " package ice LIBS: $cf_pkgconfig_libs" 1>&6
10837 echo "${as_me:-configure}:10837: testing package ice LIBS: $cf_pkgconfig_libs ..." 1>&5
10842 cf_new_extra_cppflags=
10844 for cf_add_cflags in $cf_pkgconfig_incs
10846 case $cf_fix_cppflags in
10848 case $cf_add_cflags in #(vi
10849 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
10850 case $cf_add_cflags in
10852 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10854 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10855 && test -z "${cf_tst_cflags}" \
10856 && cf_fix_cppflags=yes
10858 if test $cf_fix_cppflags = yes ; then
10859 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10861 elif test "${cf_tst_cflags}" = "\"'" ; then
10862 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10867 case "$CPPFLAGS" in
10868 *$cf_add_cflags) #(vi
10871 case $cf_add_cflags in #(vi
10873 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10875 CPPFLAGS=`echo "$CPPFLAGS" | \
10876 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10877 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10881 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
10886 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
10891 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10893 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10895 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10896 && test -z "${cf_tst_cflags}" \
10897 && cf_fix_cppflags=no
10902 if test -n "$cf_new_cflags" ; then
10904 CFLAGS="$CFLAGS $cf_new_cflags"
10907 if test -n "$cf_new_cppflags" ; then
10909 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
10912 if test -n "$cf_new_extra_cppflags" ; then
10914 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
10917 cf_add_libs="$cf_pkgconfig_libs"
10918 # Filter out duplicates - this happens with badly-designed ".pc" files...
10919 for cf_add_1lib in $LIBS
10921 for cf_add_2lib in $cf_add_libs
10923 if test "x$cf_add_1lib" = "x$cf_add_2lib"
10929 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
10931 LIBS="$cf_add_libs"
10937 { echo "$as_me:10937: WARNING: unable to find ICE library" >&5
10938 echo "$as_me: WARNING: unable to find ICE library" >&2;}
10941 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists sm; then
10942 test -n "$verbose" && echo " found package sm" 1>&6
10944 echo "${as_me:-configure}:10944: testing found package sm ..." 1>&5
10946 cf_pkgconfig_incs="`$PKG_CONFIG --cflags sm 2>/dev/null`"
10947 cf_pkgconfig_libs="`$PKG_CONFIG --libs sm 2>/dev/null`"
10948 test -n "$verbose" && echo " package sm CFLAGS: $cf_pkgconfig_incs" 1>&6
10950 echo "${as_me:-configure}:10950: testing package sm CFLAGS: $cf_pkgconfig_incs ..." 1>&5
10952 test -n "$verbose" && echo " package sm LIBS: $cf_pkgconfig_libs" 1>&6
10954 echo "${as_me:-configure}:10954: testing package sm LIBS: $cf_pkgconfig_libs ..." 1>&5
10959 cf_new_extra_cppflags=
10961 for cf_add_cflags in $cf_pkgconfig_incs
10963 case $cf_fix_cppflags in
10965 case $cf_add_cflags in #(vi
10966 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
10967 case $cf_add_cflags in
10969 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10971 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10972 && test -z "${cf_tst_cflags}" \
10973 && cf_fix_cppflags=yes
10975 if test $cf_fix_cppflags = yes ; then
10976 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10978 elif test "${cf_tst_cflags}" = "\"'" ; then
10979 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10984 case "$CPPFLAGS" in
10985 *$cf_add_cflags) #(vi
10988 case $cf_add_cflags in #(vi
10990 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10992 CPPFLAGS=`echo "$CPPFLAGS" | \
10993 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10994 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10998 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
11003 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
11008 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11010 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11012 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11013 && test -z "${cf_tst_cflags}" \
11014 && cf_fix_cppflags=no
11019 if test -n "$cf_new_cflags" ; then
11021 CFLAGS="$CFLAGS $cf_new_cflags"
11024 if test -n "$cf_new_cppflags" ; then
11026 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
11029 if test -n "$cf_new_extra_cppflags" ; then
11031 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
11034 cf_add_libs="$cf_pkgconfig_libs"
11035 # Filter out duplicates - this happens with badly-designed ".pc" files...
11036 for cf_add_1lib in $LIBS
11038 for cf_add_2lib in $cf_add_libs
11040 if test "x$cf_add_1lib" = "x$cf_add_2lib"
11046 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
11048 LIBS="$cf_add_libs"
11054 { echo "$as_me:11054: WARNING: unable to find SM library" >&5
11055 echo "$as_me: WARNING: unable to find SM library" >&2;}
11058 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xt; then
11059 test -n "$verbose" && echo " found package xt" 1>&6
11061 echo "${as_me:-configure}:11061: testing found package xt ..." 1>&5
11063 cf_pkgconfig_incs="`$PKG_CONFIG --cflags xt 2>/dev/null`"
11064 cf_pkgconfig_libs="`$PKG_CONFIG --libs xt 2>/dev/null`"
11065 test -n "$verbose" && echo " package xt CFLAGS: $cf_pkgconfig_incs" 1>&6
11067 echo "${as_me:-configure}:11067: testing package xt CFLAGS: $cf_pkgconfig_incs ..." 1>&5
11069 test -n "$verbose" && echo " package xt LIBS: $cf_pkgconfig_libs" 1>&6
11071 echo "${as_me:-configure}:11071: testing package xt LIBS: $cf_pkgconfig_libs ..." 1>&5
11076 cf_new_extra_cppflags=
11078 for cf_add_cflags in $cf_pkgconfig_incs
11080 case $cf_fix_cppflags in
11082 case $cf_add_cflags in #(vi
11083 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
11084 case $cf_add_cflags in
11086 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11088 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11089 && test -z "${cf_tst_cflags}" \
11090 && cf_fix_cppflags=yes
11092 if test $cf_fix_cppflags = yes ; then
11093 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11095 elif test "${cf_tst_cflags}" = "\"'" ; then
11096 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11101 case "$CPPFLAGS" in
11102 *$cf_add_cflags) #(vi
11105 case $cf_add_cflags in #(vi
11107 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11109 CPPFLAGS=`echo "$CPPFLAGS" | \
11110 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11111 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11115 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
11120 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
11125 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11127 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11129 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11130 && test -z "${cf_tst_cflags}" \
11131 && cf_fix_cppflags=no
11136 if test -n "$cf_new_cflags" ; then
11138 CFLAGS="$CFLAGS $cf_new_cflags"
11141 if test -n "$cf_new_cppflags" ; then
11143 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
11146 if test -n "$cf_new_extra_cppflags" ; then
11148 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
11151 cf_add_libs="$cf_pkgconfig_libs"
11152 # Filter out duplicates - this happens with badly-designed ".pc" files...
11153 for cf_add_1lib in $LIBS
11155 for cf_add_2lib in $cf_add_libs
11157 if test "x$cf_add_1lib" = "x$cf_add_2lib"
11163 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
11165 LIBS="$cf_add_libs"
11171 { echo "$as_me:11171: WARNING: unable to find Xt library" >&5
11172 echo "$as_me: WARNING: unable to find Xt library" >&2;}
11179 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xt; then
11180 test -n "$verbose" && echo " found package xt" 1>&6
11182 echo "${as_me:-configure}:11182: testing found package xt ..." 1>&5
11184 cf_pkgconfig_incs="`$PKG_CONFIG --cflags xt 2>/dev/null`"
11185 cf_pkgconfig_libs="`$PKG_CONFIG --libs xt 2>/dev/null`"
11186 test -n "$verbose" && echo " package xt CFLAGS: $cf_pkgconfig_incs" 1>&6
11188 echo "${as_me:-configure}:11188: testing package xt CFLAGS: $cf_pkgconfig_incs ..." 1>&5
11190 test -n "$verbose" && echo " package xt LIBS: $cf_pkgconfig_libs" 1>&6
11192 echo "${as_me:-configure}:11192: testing package xt LIBS: $cf_pkgconfig_libs ..." 1>&5
11197 cf_new_extra_cppflags=
11199 for cf_add_cflags in $cf_pkgconfig_incs
11201 case $cf_fix_cppflags in
11203 case $cf_add_cflags in #(vi
11204 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
11205 case $cf_add_cflags in
11207 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11209 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11210 && test -z "${cf_tst_cflags}" \
11211 && cf_fix_cppflags=yes
11213 if test $cf_fix_cppflags = yes ; then
11214 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11216 elif test "${cf_tst_cflags}" = "\"'" ; then
11217 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11222 case "$CPPFLAGS" in
11223 *$cf_add_cflags) #(vi
11226 case $cf_add_cflags in #(vi
11228 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11230 CPPFLAGS=`echo "$CPPFLAGS" | \
11231 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11232 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11236 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
11241 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
11246 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11248 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11250 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11251 && test -z "${cf_tst_cflags}" \
11252 && cf_fix_cppflags=no
11257 if test -n "$cf_new_cflags" ; then
11259 CFLAGS="$CFLAGS $cf_new_cflags"
11262 if test -n "$cf_new_cppflags" ; then
11264 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
11267 if test -n "$cf_new_extra_cppflags" ; then
11269 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
11272 cf_add_libs="$cf_pkgconfig_libs"
11273 # Filter out duplicates - this happens with badly-designed ".pc" files...
11274 for cf_add_1lib in $LIBS
11276 for cf_add_2lib in $cf_add_libs
11278 if test "x$cf_add_1lib" = "x$cf_add_2lib"
11284 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
11286 LIBS="$cf_add_libs"
11288 case "x$LIBS" in #(vi
11292 # we have an "xt" package, but it may omit Xt's dependency on X11
11293 echo "$as_me:11293: checking for usable X dependency" >&5
11294 echo $ECHO_N "checking for usable X dependency... $ECHO_C" >&6
11295 if test "${cf_cv_xt_x11_compat+set}" = set; then
11296 echo $ECHO_N "(cached) $ECHO_C" >&6
11299 cat >conftest.$ac_ext <<_ACEOF
11300 #line 11300 "configure"
11301 #include "confdefs.h"
11303 #include <X11/Xlib.h>
11309 int rc1 = XDrawLine((Display*) 0, (Drawable) 0, (GC) 0, 0, 0, 0, 0);
11310 int rc2 = XClearWindow((Display*) 0, (Window) 0);
11311 int rc3 = XMoveWindow((Display*) 0, (Window) 0, 0, 0);
11312 int rc4 = XMoveResizeWindow((Display*)0, (Window)0, 0, 0, 0, 0);
11318 rm -f conftest.$ac_objext conftest$ac_exeext
11319 if { (eval echo "$as_me:11319: \"$ac_link\"") >&5
11320 (eval $ac_link) 2>&5
11322 echo "$as_me:11322: \$? = $ac_status" >&5
11323 (exit $ac_status); } &&
11324 { ac_try='test -s conftest$ac_exeext'
11325 { (eval echo "$as_me:11325: \"$ac_try\"") >&5
11326 (eval $ac_try) 2>&5
11328 echo "$as_me:11328: \$? = $ac_status" >&5
11329 (exit $ac_status); }; }; then
11330 cf_cv_xt_x11_compat=yes
11332 echo "$as_me: failed program was:" >&5
11333 cat conftest.$ac_ext >&5
11334 cf_cv_xt_x11_compat=no
11336 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11338 echo "$as_me:11338: result: $cf_cv_xt_x11_compat" >&5
11339 echo "${ECHO_T}$cf_cv_xt_x11_compat" >&6
11340 if test "$cf_cv_xt_x11_compat" = no
11342 test -n "$verbose" && echo " work around broken X11 dependency" 1>&6
11344 echo "${as_me:-configure}:11344: testing work around broken X11 dependency ..." 1>&5
11346 # 2010/11/19 - good enough until a working Xt on Xcb is delivered.
11348 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists x11; then
11349 test -n "$verbose" && echo " found package x11" 1>&6
11351 echo "${as_me:-configure}:11351: testing found package x11 ..." 1>&5
11353 cf_pkgconfig_incs="`$PKG_CONFIG --cflags x11 2>/dev/null`"
11354 cf_pkgconfig_libs="`$PKG_CONFIG --libs x11 2>/dev/null`"
11355 test -n "$verbose" && echo " package x11 CFLAGS: $cf_pkgconfig_incs" 1>&6
11357 echo "${as_me:-configure}:11357: testing package x11 CFLAGS: $cf_pkgconfig_incs ..." 1>&5
11359 test -n "$verbose" && echo " package x11 LIBS: $cf_pkgconfig_libs" 1>&6
11361 echo "${as_me:-configure}:11361: testing package x11 LIBS: $cf_pkgconfig_libs ..." 1>&5
11366 cf_new_extra_cppflags=
11368 for cf_add_cflags in $cf_pkgconfig_incs
11370 case $cf_fix_cppflags in
11372 case $cf_add_cflags in #(vi
11373 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
11374 case $cf_add_cflags in
11376 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11378 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11379 && test -z "${cf_tst_cflags}" \
11380 && cf_fix_cppflags=yes
11382 if test $cf_fix_cppflags = yes ; then
11383 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11385 elif test "${cf_tst_cflags}" = "\"'" ; then
11386 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11391 case "$CPPFLAGS" in
11392 *$cf_add_cflags) #(vi
11395 case $cf_add_cflags in #(vi
11397 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11399 CPPFLAGS=`echo "$CPPFLAGS" | \
11400 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11401 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11405 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
11410 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
11415 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11417 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11419 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11420 && test -z "${cf_tst_cflags}" \
11421 && cf_fix_cppflags=no
11426 if test -n "$cf_new_cflags" ; then
11428 CFLAGS="$CFLAGS $cf_new_cflags"
11431 if test -n "$cf_new_cppflags" ; then
11433 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
11436 if test -n "$cf_new_extra_cppflags" ; then
11438 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
11441 cf_add_libs="$cf_pkgconfig_libs"
11442 # Filter out duplicates - this happens with badly-designed ".pc" files...
11443 for cf_add_1lib in $LIBS
11445 for cf_add_2lib in $cf_add_libs
11447 if test "x$cf_add_1lib" = "x$cf_add_2lib"
11453 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
11455 LIBS="$cf_add_libs"
11462 test -n "$verbose" && echo " ...before $LIBS" 1>&6
11464 echo "${as_me:-configure}:11464: testing ...before $LIBS ..." 1>&5
11466 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%-lXt %-lXt -lX11 %" -e 's% % %g'`
11467 test -n "$verbose" && echo " ...after $LIBS" 1>&6
11469 echo "${as_me:-configure}:11469: testing ...after $LIBS ..." 1>&5
11477 echo "$as_me:11477: checking for usable X Toolkit package" >&5
11478 echo $ECHO_N "checking for usable X Toolkit package... $ECHO_C" >&6
11479 if test "${cf_cv_xt_ice_compat+set}" = set; then
11480 echo $ECHO_N "(cached) $ECHO_C" >&6
11483 cat >conftest.$ac_ext <<_ACEOF
11484 #line 11484 "configure"
11485 #include "confdefs.h"
11487 #include <X11/Shell.h>
11492 int num = IceConnectionNumber(0)
11498 rm -f conftest.$ac_objext conftest$ac_exeext
11499 if { (eval echo "$as_me:11499: \"$ac_link\"") >&5
11500 (eval $ac_link) 2>&5
11502 echo "$as_me:11502: \$? = $ac_status" >&5
11503 (exit $ac_status); } &&
11504 { ac_try='test -s conftest$ac_exeext'
11505 { (eval echo "$as_me:11505: \"$ac_try\"") >&5
11506 (eval $ac_try) 2>&5
11508 echo "$as_me:11508: \$? = $ac_status" >&5
11509 (exit $ac_status); }; }; then
11510 cf_cv_xt_ice_compat=yes
11512 echo "$as_me: failed program was:" >&5
11513 cat conftest.$ac_ext >&5
11514 cf_cv_xt_ice_compat=no
11516 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11518 echo "$as_me:11518: result: $cf_cv_xt_ice_compat" >&5
11519 echo "${ECHO_T}$cf_cv_xt_ice_compat" >&6
11521 if test "$cf_cv_xt_ice_compat" = no
11523 # workaround for broken ".pc" files used for X Toolkit.
11524 case "x$X_PRE_LIBS" in #(vi
11526 case "x$LIBS" in #(vi
11530 test -n "$verbose" && echo " work around broken ICE dependency" 1>&6
11532 echo "${as_me:-configure}:11532: testing work around broken ICE dependency ..." 1>&5
11534 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists ice; then
11535 test -n "$verbose" && echo " found package ice" 1>&6
11537 echo "${as_me:-configure}:11537: testing found package ice ..." 1>&5
11539 cf_pkgconfig_incs="`$PKG_CONFIG --cflags ice 2>/dev/null`"
11540 cf_pkgconfig_libs="`$PKG_CONFIG --libs ice 2>/dev/null`"
11541 test -n "$verbose" && echo " package ice CFLAGS: $cf_pkgconfig_incs" 1>&6
11543 echo "${as_me:-configure}:11543: testing package ice CFLAGS: $cf_pkgconfig_incs ..." 1>&5
11545 test -n "$verbose" && echo " package ice LIBS: $cf_pkgconfig_libs" 1>&6
11547 echo "${as_me:-configure}:11547: testing package ice LIBS: $cf_pkgconfig_libs ..." 1>&5
11552 cf_new_extra_cppflags=
11554 for cf_add_cflags in $cf_pkgconfig_incs
11556 case $cf_fix_cppflags in
11558 case $cf_add_cflags in #(vi
11559 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
11560 case $cf_add_cflags in
11562 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11564 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11565 && test -z "${cf_tst_cflags}" \
11566 && cf_fix_cppflags=yes
11568 if test $cf_fix_cppflags = yes ; then
11569 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11571 elif test "${cf_tst_cflags}" = "\"'" ; then
11572 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11577 case "$CPPFLAGS" in
11578 *$cf_add_cflags) #(vi
11581 case $cf_add_cflags in #(vi
11583 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11585 CPPFLAGS=`echo "$CPPFLAGS" | \
11586 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11587 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11591 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
11596 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
11601 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11603 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11605 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11606 && test -z "${cf_tst_cflags}" \
11607 && cf_fix_cppflags=no
11612 if test -n "$cf_new_cflags" ; then
11614 CFLAGS="$CFLAGS $cf_new_cflags"
11617 if test -n "$cf_new_cppflags" ; then
11619 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
11622 if test -n "$cf_new_extra_cppflags" ; then
11624 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
11627 cf_add_libs="$cf_pkgconfig_libs"
11628 # Filter out duplicates - this happens with badly-designed ".pc" files...
11629 for cf_add_1lib in $LIBS
11631 for cf_add_2lib in $cf_add_libs
11633 if test "x$cf_add_1lib" = "x$cf_add_2lib"
11639 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
11641 LIBS="$cf_add_libs"
11643 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists sm; then
11644 test -n "$verbose" && echo " found package sm" 1>&6
11646 echo "${as_me:-configure}:11646: testing found package sm ..." 1>&5
11648 cf_pkgconfig_incs="`$PKG_CONFIG --cflags sm 2>/dev/null`"
11649 cf_pkgconfig_libs="`$PKG_CONFIG --libs sm 2>/dev/null`"
11650 test -n "$verbose" && echo " package sm CFLAGS: $cf_pkgconfig_incs" 1>&6
11652 echo "${as_me:-configure}:11652: testing package sm CFLAGS: $cf_pkgconfig_incs ..." 1>&5
11654 test -n "$verbose" && echo " package sm LIBS: $cf_pkgconfig_libs" 1>&6
11656 echo "${as_me:-configure}:11656: testing package sm LIBS: $cf_pkgconfig_libs ..." 1>&5
11661 cf_new_extra_cppflags=
11663 for cf_add_cflags in $cf_pkgconfig_incs
11665 case $cf_fix_cppflags in
11667 case $cf_add_cflags in #(vi
11668 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
11669 case $cf_add_cflags in
11671 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11673 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11674 && test -z "${cf_tst_cflags}" \
11675 && cf_fix_cppflags=yes
11677 if test $cf_fix_cppflags = yes ; then
11678 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11680 elif test "${cf_tst_cflags}" = "\"'" ; then
11681 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11686 case "$CPPFLAGS" in
11687 *$cf_add_cflags) #(vi
11690 case $cf_add_cflags in #(vi
11692 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11694 CPPFLAGS=`echo "$CPPFLAGS" | \
11695 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11696 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11700 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
11705 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
11710 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11712 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11714 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11715 && test -z "${cf_tst_cflags}" \
11716 && cf_fix_cppflags=no
11721 if test -n "$cf_new_cflags" ; then
11723 CFLAGS="$CFLAGS $cf_new_cflags"
11726 if test -n "$cf_new_cppflags" ; then
11728 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
11731 if test -n "$cf_new_extra_cppflags" ; then
11733 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
11736 cf_add_libs="$cf_pkgconfig_libs"
11737 # Filter out duplicates - this happens with badly-designed ".pc" files...
11738 for cf_add_1lib in $LIBS
11740 for cf_add_2lib in $cf_add_libs
11742 if test "x$cf_add_1lib" = "x$cf_add_2lib"
11748 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
11750 LIBS="$cf_add_libs"
11763 test -n "$verbose" && echo " ...before $LIBS" 1>&6
11765 echo "${as_me:-configure}:11765: testing ...before $LIBS ..." 1>&5
11767 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%-lXt %-lXt $X_PRE_LIBS %" -e 's% % %g'`
11768 test -n "$verbose" && echo " ...after $LIBS" 1>&6
11770 echo "${as_me:-configure}:11770: testing ...after $LIBS ..." 1>&5
11786 LDFLAGS="$X_LIBS $LDFLAGS"
11788 test -n "$verbose" && echo " checking additions to CFLAGS" 1>&6
11790 echo "${as_me:-configure}:11790: testing checking additions to CFLAGS ..." 1>&5
11792 cf_check_cflags="$CFLAGS"
11793 cf_check_cppflags="$CPPFLAGS"
11798 cf_new_extra_cppflags=
11800 for cf_add_cflags in $X_CFLAGS
11802 case $cf_fix_cppflags in
11804 case $cf_add_cflags in #(vi
11805 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
11806 case $cf_add_cflags in
11808 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11810 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11811 && test -z "${cf_tst_cflags}" \
11812 && cf_fix_cppflags=yes
11814 if test $cf_fix_cppflags = yes ; then
11815 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11817 elif test "${cf_tst_cflags}" = "\"'" ; then
11818 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11823 case "$CPPFLAGS" in
11824 *$cf_add_cflags) #(vi
11827 case $cf_add_cflags in #(vi
11829 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11831 CPPFLAGS=`echo "$CPPFLAGS" | \
11832 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11833 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11837 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
11842 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
11847 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11849 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11851 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11852 && test -z "${cf_tst_cflags}" \
11853 && cf_fix_cppflags=no
11858 if test -n "$cf_new_cflags" ; then
11859 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
11861 echo "${as_me:-configure}:11861: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
11863 CFLAGS="$CFLAGS $cf_new_cflags"
11866 if test -n "$cf_new_cppflags" ; then
11867 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
11869 echo "${as_me:-configure}:11869: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
11871 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
11874 if test -n "$cf_new_extra_cppflags" ; then
11875 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
11877 echo "${as_me:-configure}:11877: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
11879 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
11882 if test "$cf_check_cflags" != "$CFLAGS" ; then
11883 cat >conftest.$ac_ext <<_ACEOF
11884 #line 11884 "configure"
11885 #include "confdefs.h"
11890 printf("Hello world");
11895 rm -f conftest.$ac_objext conftest$ac_exeext
11896 if { (eval echo "$as_me:11896: \"$ac_link\"") >&5
11897 (eval $ac_link) 2>&5
11899 echo "$as_me:11899: \$? = $ac_status" >&5
11900 (exit $ac_status); } &&
11901 { ac_try='test -s conftest$ac_exeext'
11902 { (eval echo "$as_me:11902: \"$ac_try\"") >&5
11903 (eval $ac_try) 2>&5
11905 echo "$as_me:11905: \$? = $ac_status" >&5
11906 (exit $ac_status); }; }; then
11909 echo "$as_me: failed program was:" >&5
11910 cat conftest.$ac_ext >&5
11911 test -n "$verbose" && echo " test-compile failed. Undoing change to \$CFLAGS" 1>&6
11913 echo "${as_me:-configure}:11913: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5
11915 if test "$cf_check_cppflags" != "$CPPFLAGS" ; then
11916 test -n "$verbose" && echo " but keeping change to \$CPPFLAGS" 1>&6
11918 echo "${as_me:-configure}:11918: testing but keeping change to \$CPPFLAGS ..." 1>&5
11921 CFLAGS="$cf_check_flags"
11923 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11926 echo "$as_me:11926: checking for XOpenDisplay" >&5
11927 echo $ECHO_N "checking for XOpenDisplay... $ECHO_C" >&6
11928 if test "${ac_cv_func_XOpenDisplay+set}" = set; then
11929 echo $ECHO_N "(cached) $ECHO_C" >&6
11931 cat >conftest.$ac_ext <<_ACEOF
11932 #line 11932 "configure"
11933 #include "confdefs.h"
11934 /* System header to define __stub macros and hopefully few prototypes,
11935 which can conflict with char XOpenDisplay (); below. */
11936 #include <assert.h>
11937 /* Override any gcc2 internal prototype to avoid an error. */
11941 /* We use char because int might match the return type of a gcc2
11942 builtin and then its argument prototype would still apply. */
11943 char XOpenDisplay ();
11949 /* The GNU C library defines this for functions which it implements
11950 to always fail with ENOSYS. Some functions are actually named
11951 something starting with __ and the normal name is an alias. */
11952 #if defined (__stub_XOpenDisplay) || defined (__stub___XOpenDisplay)
11955 f = XOpenDisplay; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
11962 rm -f conftest.$ac_objext conftest$ac_exeext
11963 if { (eval echo "$as_me:11963: \"$ac_link\"") >&5
11964 (eval $ac_link) 2>&5
11966 echo "$as_me:11966: \$? = $ac_status" >&5
11967 (exit $ac_status); } &&
11968 { ac_try='test -s conftest$ac_exeext'
11969 { (eval echo "$as_me:11969: \"$ac_try\"") >&5
11970 (eval $ac_try) 2>&5
11972 echo "$as_me:11972: \$? = $ac_status" >&5
11973 (exit $ac_status); }; }; then
11974 ac_cv_func_XOpenDisplay=yes
11976 echo "$as_me: failed program was:" >&5
11977 cat conftest.$ac_ext >&5
11978 ac_cv_func_XOpenDisplay=no
11980 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11982 echo "$as_me:11982: result: $ac_cv_func_XOpenDisplay" >&5
11983 echo "${ECHO_T}$ac_cv_func_XOpenDisplay" >&6
11984 if test $ac_cv_func_XOpenDisplay = yes; then
11988 echo "$as_me:11988: checking for XOpenDisplay in -lX11" >&5
11989 echo $ECHO_N "checking for XOpenDisplay in -lX11... $ECHO_C" >&6
11990 if test "${ac_cv_lib_X11_XOpenDisplay+set}" = set; then
11991 echo $ECHO_N "(cached) $ECHO_C" >&6
11993 ac_check_lib_save_LIBS=$LIBS
11994 LIBS="-lX11 $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
11995 cat >conftest.$ac_ext <<_ACEOF
11996 #line 11996 "configure"
11997 #include "confdefs.h"
11999 /* Override any gcc2 internal prototype to avoid an error. */
12003 /* We use char because int might match the return type of a gcc2
12004 builtin and then its argument prototype would still apply. */
12005 char XOpenDisplay ();
12014 rm -f conftest.$ac_objext conftest$ac_exeext
12015 if { (eval echo "$as_me:12015: \"$ac_link\"") >&5
12016 (eval $ac_link) 2>&5
12018 echo "$as_me:12018: \$? = $ac_status" >&5
12019 (exit $ac_status); } &&
12020 { ac_try='test -s conftest$ac_exeext'
12021 { (eval echo "$as_me:12021: \"$ac_try\"") >&5
12022 (eval $ac_try) 2>&5
12024 echo "$as_me:12024: \$? = $ac_status" >&5
12025 (exit $ac_status); }; }; then
12026 ac_cv_lib_X11_XOpenDisplay=yes
12028 echo "$as_me: failed program was:" >&5
12029 cat conftest.$ac_ext >&5
12030 ac_cv_lib_X11_XOpenDisplay=no
12032 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12033 LIBS=$ac_check_lib_save_LIBS
12035 echo "$as_me:12035: result: $ac_cv_lib_X11_XOpenDisplay" >&5
12036 echo "${ECHO_T}$ac_cv_lib_X11_XOpenDisplay" >&6
12037 if test $ac_cv_lib_X11_XOpenDisplay = yes; then
12039 cf_add_libs="-lX11"
12040 # Filter out duplicates - this happens with badly-designed ".pc" files...
12041 for cf_add_1lib in $LIBS
12043 for cf_add_2lib in $cf_add_libs
12045 if test "x$cf_add_1lib" = "x$cf_add_2lib"
12051 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
12053 LIBS="$cf_add_libs"
12059 echo "$as_me:12059: checking for XtAppInitialize" >&5
12060 echo $ECHO_N "checking for XtAppInitialize... $ECHO_C" >&6
12061 if test "${ac_cv_func_XtAppInitialize+set}" = set; then
12062 echo $ECHO_N "(cached) $ECHO_C" >&6
12064 cat >conftest.$ac_ext <<_ACEOF
12065 #line 12065 "configure"
12066 #include "confdefs.h"
12067 /* System header to define __stub macros and hopefully few prototypes,
12068 which can conflict with char XtAppInitialize (); below. */
12069 #include <assert.h>
12070 /* Override any gcc2 internal prototype to avoid an error. */
12074 /* We use char because int might match the return type of a gcc2
12075 builtin and then its argument prototype would still apply. */
12076 char XtAppInitialize ();
12082 /* The GNU C library defines this for functions which it implements
12083 to always fail with ENOSYS. Some functions are actually named
12084 something starting with __ and the normal name is an alias. */
12085 #if defined (__stub_XtAppInitialize) || defined (__stub___XtAppInitialize)
12088 f = XtAppInitialize; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
12095 rm -f conftest.$ac_objext conftest$ac_exeext
12096 if { (eval echo "$as_me:12096: \"$ac_link\"") >&5
12097 (eval $ac_link) 2>&5
12099 echo "$as_me:12099: \$? = $ac_status" >&5
12100 (exit $ac_status); } &&
12101 { ac_try='test -s conftest$ac_exeext'
12102 { (eval echo "$as_me:12102: \"$ac_try\"") >&5
12103 (eval $ac_try) 2>&5
12105 echo "$as_me:12105: \$? = $ac_status" >&5
12106 (exit $ac_status); }; }; then
12107 ac_cv_func_XtAppInitialize=yes
12109 echo "$as_me: failed program was:" >&5
12110 cat conftest.$ac_ext >&5
12111 ac_cv_func_XtAppInitialize=no
12113 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12115 echo "$as_me:12115: result: $ac_cv_func_XtAppInitialize" >&5
12116 echo "${ECHO_T}$ac_cv_func_XtAppInitialize" >&6
12117 if test $ac_cv_func_XtAppInitialize = yes; then
12121 echo "$as_me:12121: checking for XtAppInitialize in -lXt" >&5
12122 echo $ECHO_N "checking for XtAppInitialize in -lXt... $ECHO_C" >&6
12123 if test "${ac_cv_lib_Xt_XtAppInitialize+set}" = set; then
12124 echo $ECHO_N "(cached) $ECHO_C" >&6
12126 ac_check_lib_save_LIBS=$LIBS
12127 LIBS="-lXt $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
12128 cat >conftest.$ac_ext <<_ACEOF
12129 #line 12129 "configure"
12130 #include "confdefs.h"
12132 /* Override any gcc2 internal prototype to avoid an error. */
12136 /* We use char because int might match the return type of a gcc2
12137 builtin and then its argument prototype would still apply. */
12138 char XtAppInitialize ();
12142 XtAppInitialize ();
12147 rm -f conftest.$ac_objext conftest$ac_exeext
12148 if { (eval echo "$as_me:12148: \"$ac_link\"") >&5
12149 (eval $ac_link) 2>&5
12151 echo "$as_me:12151: \$? = $ac_status" >&5
12152 (exit $ac_status); } &&
12153 { ac_try='test -s conftest$ac_exeext'
12154 { (eval echo "$as_me:12154: \"$ac_try\"") >&5
12155 (eval $ac_try) 2>&5
12157 echo "$as_me:12157: \$? = $ac_status" >&5
12158 (exit $ac_status); }; }; then
12159 ac_cv_lib_Xt_XtAppInitialize=yes
12161 echo "$as_me: failed program was:" >&5
12162 cat conftest.$ac_ext >&5
12163 ac_cv_lib_Xt_XtAppInitialize=no
12165 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12166 LIBS=$ac_check_lib_save_LIBS
12168 echo "$as_me:12168: result: $ac_cv_lib_Xt_XtAppInitialize" >&5
12169 echo "${ECHO_T}$ac_cv_lib_Xt_XtAppInitialize" >&6
12170 if test $ac_cv_lib_Xt_XtAppInitialize = yes; then
12172 cat >>confdefs.h <<\EOF
12173 #define HAVE_LIBXT 1
12177 LIBS="-lXt $X_PRE_LIBS $LIBS $X_EXTRA_LIBS"
12184 if test $cf_have_X_LIBS = no ; then
12185 { echo "$as_me:12185: WARNING: Unable to successfully link X Toolkit library (-lXt) with
12186 test program. You will have to check and add the proper libraries by hand
12188 echo "$as_me: WARNING: Unable to successfully link X Toolkit library (-lXt) with
12189 test program. You will have to check and add the proper libraries by hand
12190 to makefile." >&2;}
12193 cf_x_athena_root=$cf_x_athena
12196 for cf_path in default \
12197 /usr/contrib/X11R6 \
12198 /usr/contrib/X11R5 \
12202 if test -z "$cf_x_athena_inc" ; then
12203 cf_save="$CPPFLAGS"
12204 cf_test=X11/$cf_x_athena_root/SimpleMenu.h
12205 if test $cf_path != default ; then
12206 CPPFLAGS="$cf_save -I$cf_path/include"
12207 echo "$as_me:12207: checking for $cf_test in $cf_path" >&5
12208 echo $ECHO_N "checking for $cf_test in $cf_path... $ECHO_C" >&6
12210 echo "$as_me:12210: checking for $cf_test" >&5
12211 echo $ECHO_N "checking for $cf_test... $ECHO_C" >&6
12213 cat >conftest.$ac_ext <<_ACEOF
12214 #line 12214 "configure"
12215 #include "confdefs.h"
12217 #include <X11/Intrinsic.h>
12218 #include <$cf_test>
12227 rm -f conftest.$ac_objext
12228 if { (eval echo "$as_me:12228: \"$ac_compile\"") >&5
12229 (eval $ac_compile) 2>&5
12231 echo "$as_me:12231: \$? = $ac_status" >&5
12232 (exit $ac_status); } &&
12233 { ac_try='test -s conftest.$ac_objext'
12234 { (eval echo "$as_me:12234: \"$ac_try\"") >&5
12235 (eval $ac_try) 2>&5
12237 echo "$as_me:12237: \$? = $ac_status" >&5
12238 (exit $ac_status); }; }; then
12241 echo "$as_me: failed program was:" >&5
12242 cat conftest.$ac_ext >&5
12245 rm -f conftest.$ac_objext conftest.$ac_ext
12246 echo "$as_me:12246: result: $cf_result" >&5
12247 echo "${ECHO_T}$cf_result" >&6
12248 if test "$cf_result" = yes ; then
12249 cf_x_athena_inc=$cf_path
12252 CPPFLAGS="$cf_save"
12257 if test -z "$cf_x_athena_inc" ; then
12258 { echo "$as_me:12258: WARNING: Unable to successfully find Athena header files with test program" >&5
12259 echo "$as_me: WARNING: Unable to successfully find Athena header files with test program" >&2;}
12260 elif test "$cf_x_athena_inc" != default ; then
12261 CPPFLAGS="$CPPFLAGS -I$cf_x_athena_inc"
12264 cf_x_athena_root=$cf_x_athena
12267 for cf_path in default \
12268 /usr/contrib/X11R6 \
12269 /usr/contrib/X11R5 \
12274 ${cf_x_athena_root} \
12275 ${cf_x_athena_root}7 \
12276 ${cf_x_athena_root}6
12279 "-l$cf_lib -lXmu" \
12280 "-l$cf_lib -lXpm -lXmu" \
12281 "-l${cf_lib}_s -lXmu_s"
12283 if test -z "$cf_x_athena_lib" ; then
12285 cf_test=XawSimpleMenuAddGlobalActions
12286 if test $cf_path != default ; then
12288 cf_add_libs="-L$cf_path/lib $cf_libs"
12289 # Filter out duplicates - this happens with badly-designed ".pc" files...
12290 for cf_add_1lib in $LIBS
12292 for cf_add_2lib in $cf_add_libs
12294 if test "x$cf_add_1lib" = "x$cf_add_2lib"
12300 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
12302 LIBS="$cf_add_libs"
12304 echo "$as_me:12304: checking for $cf_libs in $cf_path" >&5
12305 echo $ECHO_N "checking for $cf_libs in $cf_path... $ECHO_C" >&6
12308 cf_add_libs="$cf_libs"
12309 # Filter out duplicates - this happens with badly-designed ".pc" files...
12310 for cf_add_1lib in $LIBS
12312 for cf_add_2lib in $cf_add_libs
12314 if test "x$cf_add_1lib" = "x$cf_add_2lib"
12320 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
12322 LIBS="$cf_add_libs"
12324 echo "$as_me:12324: checking for $cf_test in $cf_libs" >&5
12325 echo $ECHO_N "checking for $cf_test in $cf_libs... $ECHO_C" >&6
12327 cat >conftest.$ac_ext <<_ACEOF
12328 #line 12328 "configure"
12329 #include "confdefs.h"
12331 #include <X11/Intrinsic.h>
12332 #include <X11/$cf_x_athena_root/SimpleMenu.h>
12338 $cf_test((XtAppContext) 0)
12343 rm -f conftest.$ac_objext conftest$ac_exeext
12344 if { (eval echo "$as_me:12344: \"$ac_link\"") >&5
12345 (eval $ac_link) 2>&5
12347 echo "$as_me:12347: \$? = $ac_status" >&5
12348 (exit $ac_status); } &&
12349 { ac_try='test -s conftest$ac_exeext'
12350 { (eval echo "$as_me:12350: \"$ac_try\"") >&5
12351 (eval $ac_try) 2>&5
12353 echo "$as_me:12353: \$? = $ac_status" >&5
12354 (exit $ac_status); }; }; then
12357 echo "$as_me: failed program was:" >&5
12358 cat conftest.$ac_ext >&5
12361 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12362 echo "$as_me:12362: result: $cf_result" >&5
12363 echo "${ECHO_T}$cf_result" >&6
12364 if test "$cf_result" = yes ; then
12365 cf_x_athena_lib="$cf_libs"
12371 test -n "$cf_x_athena_lib" && break
12375 if test -z "$cf_x_athena_lib" ; then
12376 { { echo "$as_me:12376: error: Unable to successfully link Athena library (-l$cf_x_athena_root) with test program" >&5
12377 echo "$as_me: error: Unable to successfully link Athena library (-l$cf_x_athena_root) with test program" >&2;}
12378 { (exit 1); exit 1; }; }
12381 cf_x_athena_LIBS=`echo "HAVE_LIB_$cf_x_athena" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
12383 cat >>confdefs.h <<EOF
12384 #define $cf_x_athena_LIBS 1
12389 if test -n "$ac_tool_prefix"; then
12390 for ac_prog in xcurses-config
12392 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
12393 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
12394 echo "$as_me:12394: checking for $ac_word" >&5
12395 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
12396 if test "${ac_cv_prog_XCURSES_CONFIG+set}" = set; then
12397 echo $ECHO_N "(cached) $ECHO_C" >&6
12399 if test -n "$XCURSES_CONFIG"; then
12400 ac_cv_prog_XCURSES_CONFIG="$XCURSES_CONFIG" # Let the user override the test.
12402 ac_save_IFS=$IFS; IFS=$ac_path_separator
12404 for ac_dir in $ac_dummy; do
12406 test -z "$ac_dir" && ac_dir=.
12407 $as_executable_p "$ac_dir/$ac_word" || continue
12408 ac_cv_prog_XCURSES_CONFIG="$ac_tool_prefix$ac_prog"
12409 echo "$as_me:12409: found $ac_dir/$ac_word" >&5
12415 XCURSES_CONFIG=$ac_cv_prog_XCURSES_CONFIG
12416 if test -n "$XCURSES_CONFIG"; then
12417 echo "$as_me:12417: result: $XCURSES_CONFIG" >&5
12418 echo "${ECHO_T}$XCURSES_CONFIG" >&6
12420 echo "$as_me:12420: result: no" >&5
12421 echo "${ECHO_T}no" >&6
12424 test -n "$XCURSES_CONFIG" && break
12427 if test -z "$XCURSES_CONFIG"; then
12428 ac_ct_XCURSES_CONFIG=$XCURSES_CONFIG
12429 for ac_prog in xcurses-config
12431 # Extract the first word of "$ac_prog", so it can be a program name with args.
12432 set dummy $ac_prog; ac_word=$2
12433 echo "$as_me:12433: checking for $ac_word" >&5
12434 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
12435 if test "${ac_cv_prog_ac_ct_XCURSES_CONFIG+set}" = set; then
12436 echo $ECHO_N "(cached) $ECHO_C" >&6
12438 if test -n "$ac_ct_XCURSES_CONFIG"; then
12439 ac_cv_prog_ac_ct_XCURSES_CONFIG="$ac_ct_XCURSES_CONFIG" # Let the user override the test.
12441 ac_save_IFS=$IFS; IFS=$ac_path_separator
12443 for ac_dir in $ac_dummy; do
12445 test -z "$ac_dir" && ac_dir=.
12446 $as_executable_p "$ac_dir/$ac_word" || continue
12447 ac_cv_prog_ac_ct_XCURSES_CONFIG="$ac_prog"
12448 echo "$as_me:12448: found $ac_dir/$ac_word" >&5
12454 ac_ct_XCURSES_CONFIG=$ac_cv_prog_ac_ct_XCURSES_CONFIG
12455 if test -n "$ac_ct_XCURSES_CONFIG"; then
12456 echo "$as_me:12456: result: $ac_ct_XCURSES_CONFIG" >&5
12457 echo "${ECHO_T}$ac_ct_XCURSES_CONFIG" >&6
12459 echo "$as_me:12459: result: no" >&5
12460 echo "${ECHO_T}no" >&6
12463 test -n "$ac_ct_XCURSES_CONFIG" && break
12465 test -n "$ac_ct_XCURSES_CONFIG" || ac_ct_XCURSES_CONFIG="none"
12467 XCURSES_CONFIG=$ac_ct_XCURSES_CONFIG
12470 if test "$XCURSES_CONFIG" != none ; then
12472 CPPFLAGS="$CPPFLAGS `$XCURSES_CONFIG --cflags`"
12474 cf_add_libs="`$XCURSES_CONFIG --libs`"
12475 # Filter out duplicates - this happens with badly-designed ".pc" files...
12476 for cf_add_1lib in $LIBS
12478 for cf_add_2lib in $cf_add_libs
12480 if test "x$cf_add_1lib" = "x$cf_add_2lib"
12486 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
12488 LIBS="$cf_add_libs"
12490 cf_cv_lib_XCurses=yes
12494 LDFLAGS="$LDFLAGS $X_LIBS"
12496 test -n "$verbose" && echo " checking additions to CFLAGS" 1>&6
12498 echo "${as_me:-configure}:12498: testing checking additions to CFLAGS ..." 1>&5
12500 cf_check_cflags="$CFLAGS"
12501 cf_check_cppflags="$CPPFLAGS"
12506 cf_new_extra_cppflags=
12508 for cf_add_cflags in $X_CFLAGS
12510 case $cf_fix_cppflags in
12512 case $cf_add_cflags in #(vi
12513 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
12514 case $cf_add_cflags in
12516 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
12518 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
12519 && test -z "${cf_tst_cflags}" \
12520 && cf_fix_cppflags=yes
12522 if test $cf_fix_cppflags = yes ; then
12523 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
12525 elif test "${cf_tst_cflags}" = "\"'" ; then
12526 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
12531 case "$CPPFLAGS" in
12532 *$cf_add_cflags) #(vi
12535 case $cf_add_cflags in #(vi
12537 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12539 CPPFLAGS=`echo "$CPPFLAGS" | \
12540 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12541 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12545 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
12550 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
12555 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
12557 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
12559 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
12560 && test -z "${cf_tst_cflags}" \
12561 && cf_fix_cppflags=no
12566 if test -n "$cf_new_cflags" ; then
12567 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
12569 echo "${as_me:-configure}:12569: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
12571 CFLAGS="$CFLAGS $cf_new_cflags"
12574 if test -n "$cf_new_cppflags" ; then
12575 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
12577 echo "${as_me:-configure}:12577: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
12579 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
12582 if test -n "$cf_new_extra_cppflags" ; then
12583 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
12585 echo "${as_me:-configure}:12585: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
12587 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
12590 if test "$cf_check_cflags" != "$CFLAGS" ; then
12591 cat >conftest.$ac_ext <<_ACEOF
12592 #line 12592 "configure"
12593 #include "confdefs.h"
12598 printf("Hello world");
12603 rm -f conftest.$ac_objext conftest$ac_exeext
12604 if { (eval echo "$as_me:12604: \"$ac_link\"") >&5
12605 (eval $ac_link) 2>&5
12607 echo "$as_me:12607: \$? = $ac_status" >&5
12608 (exit $ac_status); } &&
12609 { ac_try='test -s conftest$ac_exeext'
12610 { (eval echo "$as_me:12610: \"$ac_try\"") >&5
12611 (eval $ac_try) 2>&5
12613 echo "$as_me:12613: \$? = $ac_status" >&5
12614 (exit $ac_status); }; }; then
12617 echo "$as_me: failed program was:" >&5
12618 cat conftest.$ac_ext >&5
12619 test -n "$verbose" && echo " test-compile failed. Undoing change to \$CFLAGS" 1>&6
12621 echo "${as_me:-configure}:12621: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5
12623 if test "$cf_check_cppflags" != "$CPPFLAGS" ; then
12624 test -n "$verbose" && echo " but keeping change to \$CPPFLAGS" 1>&6
12626 echo "${as_me:-configure}:12626: testing but keeping change to \$CPPFLAGS ..." 1>&5
12629 CFLAGS="$cf_check_flags"
12631 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12634 echo "$as_me:12634: checking for XOpenDisplay in -lX11" >&5
12635 echo $ECHO_N "checking for XOpenDisplay in -lX11... $ECHO_C" >&6
12636 if test "${ac_cv_lib_X11_XOpenDisplay+set}" = set; then
12637 echo $ECHO_N "(cached) $ECHO_C" >&6
12639 ac_check_lib_save_LIBS=$LIBS
12640 LIBS="-lX11 $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
12641 cat >conftest.$ac_ext <<_ACEOF
12642 #line 12642 "configure"
12643 #include "confdefs.h"
12645 /* Override any gcc2 internal prototype to avoid an error. */
12649 /* We use char because int might match the return type of a gcc2
12650 builtin and then its argument prototype would still apply. */
12651 char XOpenDisplay ();
12660 rm -f conftest.$ac_objext conftest$ac_exeext
12661 if { (eval echo "$as_me:12661: \"$ac_link\"") >&5
12662 (eval $ac_link) 2>&5
12664 echo "$as_me:12664: \$? = $ac_status" >&5
12665 (exit $ac_status); } &&
12666 { ac_try='test -s conftest$ac_exeext'
12667 { (eval echo "$as_me:12667: \"$ac_try\"") >&5
12668 (eval $ac_try) 2>&5
12670 echo "$as_me:12670: \$? = $ac_status" >&5
12671 (exit $ac_status); }; }; then
12672 ac_cv_lib_X11_XOpenDisplay=yes
12674 echo "$as_me: failed program was:" >&5
12675 cat conftest.$ac_ext >&5
12676 ac_cv_lib_X11_XOpenDisplay=no
12678 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12679 LIBS=$ac_check_lib_save_LIBS
12681 echo "$as_me:12681: result: $ac_cv_lib_X11_XOpenDisplay" >&5
12682 echo "${ECHO_T}$ac_cv_lib_X11_XOpenDisplay" >&6
12683 if test $ac_cv_lib_X11_XOpenDisplay = yes; then
12685 cf_add_libs="-lX11"
12686 # Filter out duplicates - this happens with badly-designed ".pc" files...
12687 for cf_add_1lib in $LIBS
12689 for cf_add_2lib in $cf_add_libs
12691 if test "x$cf_add_1lib" = "x$cf_add_2lib"
12697 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
12699 LIBS="$cf_add_libs"
12703 echo "$as_me:12703: checking for XCurses library" >&5
12704 echo $ECHO_N "checking for XCurses library... $ECHO_C" >&6
12705 if test "${cf_cv_lib_XCurses+set}" = set; then
12706 echo $ECHO_N "(cached) $ECHO_C" >&6
12709 cf_add_libs="-lXCurses"
12710 # Filter out duplicates - this happens with badly-designed ".pc" files...
12711 for cf_add_1lib in $LIBS
12713 for cf_add_2lib in $cf_add_libs
12715 if test "x$cf_add_1lib" = "x$cf_add_2lib"
12721 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
12723 LIBS="$cf_add_libs"
12725 cat >conftest.$ac_ext <<_ACEOF
12726 #line 12726 "configure"
12727 #include "confdefs.h"
12729 #include <xcurses.h>
12730 char *XCursesProgramName = "test";
12740 rm -f conftest.$ac_objext conftest$ac_exeext
12741 if { (eval echo "$as_me:12741: \"$ac_link\"") >&5
12742 (eval $ac_link) 2>&5
12744 echo "$as_me:12744: \$? = $ac_status" >&5
12745 (exit $ac_status); } &&
12746 { ac_try='test -s conftest$ac_exeext'
12747 { (eval echo "$as_me:12747: \"$ac_try\"") >&5
12748 (eval $ac_try) 2>&5
12750 echo "$as_me:12750: \$? = $ac_status" >&5
12751 (exit $ac_status); }; }; then
12752 cf_cv_lib_XCurses=yes
12754 echo "$as_me: failed program was:" >&5
12755 cat conftest.$ac_ext >&5
12756 cf_cv_lib_XCurses=no
12758 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12761 echo "$as_me:12761: result: $cf_cv_lib_XCurses" >&5
12762 echo "${ECHO_T}$cf_cv_lib_XCurses" >&6
12766 if test $cf_cv_lib_XCurses = yes ; then
12768 cat >>confdefs.h <<\EOF
12772 cat >>confdefs.h <<\EOF
12776 echo "$as_me:12776: checking for xcurses.h" >&5
12777 echo $ECHO_N "checking for xcurses.h... $ECHO_C" >&6
12778 if test "${ac_cv_header_xcurses_h+set}" = set; then
12779 echo $ECHO_N "(cached) $ECHO_C" >&6
12781 cat >conftest.$ac_ext <<_ACEOF
12782 #line 12782 "configure"
12783 #include "confdefs.h"
12784 #include <xcurses.h>
12786 if { (eval echo "$as_me:12786: \"$ac_cpp conftest.$ac_ext\"") >&5
12787 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12789 egrep -v '^ *\+' conftest.er1 >conftest.err
12791 cat conftest.err >&5
12792 echo "$as_me:12792: \$? = $ac_status" >&5
12793 (exit $ac_status); } >/dev/null; then
12794 if test -s conftest.err; then
12795 ac_cpp_err=$ac_c_preproc_warn_flag
12802 if test -z "$ac_cpp_err"; then
12803 ac_cv_header_xcurses_h=yes
12805 echo "$as_me: failed program was:" >&5
12806 cat conftest.$ac_ext >&5
12807 ac_cv_header_xcurses_h=no
12809 rm -f conftest.err conftest.$ac_ext
12811 echo "$as_me:12811: result: $ac_cv_header_xcurses_h" >&5
12812 echo "${ECHO_T}$ac_cv_header_xcurses_h" >&6
12813 if test $ac_cv_header_xcurses_h = yes; then
12815 cat >>confdefs.h <<\EOF
12816 #define HAVE_XCURSES 1
12822 { { echo "$as_me:12822: error: Cannot link with XCurses" >&5
12823 echo "$as_me: error: Cannot link with XCurses" >&2;}
12824 { (exit 1); exit 1; }; }
12830 case $cf_cv_screen in
12833 echo "$as_me:12833: checking for NetBSD form.h" >&5
12834 echo $ECHO_N "checking for NetBSD form.h... $ECHO_C" >&6
12835 if test "${cf_cv_netbsd_form_h+set}" = set; then
12836 echo $ECHO_N "(cached) $ECHO_C" >&6
12839 cat >conftest.$ac_ext <<_ACEOF
12840 #line 12840 "configure"
12841 #include "confdefs.h"
12843 #include <${cf_cv_ncurses_header:-curses.h}>
12851 int y = current_field(form)->cursor_ypos;
12852 int x = current_field(form)->cursor_xpos;
12858 rm -f conftest.$ac_objext
12859 if { (eval echo "$as_me:12859: \"$ac_compile\"") >&5
12860 (eval $ac_compile) 2>&5
12862 echo "$as_me:12862: \$? = $ac_status" >&5
12863 (exit $ac_status); } &&
12864 { ac_try='test -s conftest.$ac_objext'
12865 { (eval echo "$as_me:12865: \"$ac_try\"") >&5
12866 (eval $ac_try) 2>&5
12868 echo "$as_me:12868: \$? = $ac_status" >&5
12869 (exit $ac_status); }; }; then
12870 cf_cv_netbsd_form_h=yes
12873 echo "$as_me: failed program was:" >&5
12874 cat conftest.$ac_ext >&5
12875 cf_cv_netbsd_form_h=no
12877 rm -f conftest.$ac_objext conftest.$ac_ext
12880 echo "$as_me:12880: result: $cf_cv_netbsd_form_h" >&5
12881 echo "${ECHO_T}$cf_cv_netbsd_form_h" >&6
12883 test "$cf_cv_netbsd_form_h" = yes &&
12884 cat >>confdefs.h <<\EOF
12885 #define HAVE_NETBSD_FORM_H 1
12888 echo "$as_me:12888: checking for NetBSD menu.h" >&5
12889 echo $ECHO_N "checking for NetBSD menu.h... $ECHO_C" >&6
12890 if test "${cf_cv_netbsd_menu_h+set}" = set; then
12891 echo $ECHO_N "(cached) $ECHO_C" >&6
12894 cat >conftest.$ac_ext <<_ACEOF
12895 #line 12895 "configure"
12896 #include "confdefs.h"
12898 #include <${cf_cv_ncurses_header:-curses.h}>
12906 int y = menu->max_item_width;
12912 rm -f conftest.$ac_objext
12913 if { (eval echo "$as_me:12913: \"$ac_compile\"") >&5
12914 (eval $ac_compile) 2>&5
12916 echo "$as_me:12916: \$? = $ac_status" >&5
12917 (exit $ac_status); } &&
12918 { ac_try='test -s conftest.$ac_objext'
12919 { (eval echo "$as_me:12919: \"$ac_try\"") >&5
12920 (eval $ac_try) 2>&5
12922 echo "$as_me:12922: \$? = $ac_status" >&5
12923 (exit $ac_status); }; }; then
12924 cf_cv_netbsd_menu_h=yes
12927 echo "$as_me: failed program was:" >&5
12928 cat conftest.$ac_ext >&5
12929 cf_cv_netbsd_menu_h=no
12931 rm -f conftest.$ac_objext conftest.$ac_ext
12934 echo "$as_me:12934: result: $cf_cv_netbsd_menu_h" >&5
12935 echo "${ECHO_T}$cf_cv_netbsd_menu_h" >&6
12937 test "$cf_cv_netbsd_menu_h" = yes &&
12938 cat >>confdefs.h <<\EOF
12939 #define HAVE_NETBSD_MENU_H 1
12948 case $cf_cv_screen in #(vi
12952 # look for curses-related libraries
12953 : ${cf_panel_lib:=panel}
12954 : ${cf_menu_lib:=menu}
12955 : ${cf_form_lib:=form}
12957 as_ac_Lib=`echo "ac_cv_lib_$cf_panel_lib$cf_cv_libtype''_new_panel" | $as_tr_sh`
12958 echo "$as_me:12958: checking for new_panel in -l$cf_panel_lib$cf_cv_libtype" >&5
12959 echo $ECHO_N "checking for new_panel in -l$cf_panel_lib$cf_cv_libtype... $ECHO_C" >&6
12960 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
12961 echo $ECHO_N "(cached) $ECHO_C" >&6
12963 ac_check_lib_save_LIBS=$LIBS
12964 LIBS="-l$cf_panel_lib$cf_cv_libtype $LIBS"
12965 cat >conftest.$ac_ext <<_ACEOF
12966 #line 12966 "configure"
12967 #include "confdefs.h"
12969 /* Override any gcc2 internal prototype to avoid an error. */
12973 /* We use char because int might match the return type of a gcc2
12974 builtin and then its argument prototype would still apply. */
12984 rm -f conftest.$ac_objext conftest$ac_exeext
12985 if { (eval echo "$as_me:12985: \"$ac_link\"") >&5
12986 (eval $ac_link) 2>&5
12988 echo "$as_me:12988: \$? = $ac_status" >&5
12989 (exit $ac_status); } &&
12990 { ac_try='test -s conftest$ac_exeext'
12991 { (eval echo "$as_me:12991: \"$ac_try\"") >&5
12992 (eval $ac_try) 2>&5
12994 echo "$as_me:12994: \$? = $ac_status" >&5
12995 (exit $ac_status); }; }; then
12996 eval "$as_ac_Lib=yes"
12998 echo "$as_me: failed program was:" >&5
12999 cat conftest.$ac_ext >&5
13000 eval "$as_ac_Lib=no"
13002 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13003 LIBS=$ac_check_lib_save_LIBS
13005 echo "$as_me:13005: result: `eval echo '${'$as_ac_Lib'}'`" >&5
13006 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
13007 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
13008 cat >>confdefs.h <<EOF
13009 #define `echo "HAVE_LIB$cf_panel_lib$cf_cv_libtype" | $as_tr_cpp` 1
13012 LIBS="-l$cf_panel_lib$cf_cv_libtype $LIBS"
13016 as_ac_Lib=`echo "ac_cv_lib_$cf_menu_lib$cf_cv_libtype''_menu_driver" | $as_tr_sh`
13017 echo "$as_me:13017: checking for menu_driver in -l$cf_menu_lib$cf_cv_libtype" >&5
13018 echo $ECHO_N "checking for menu_driver in -l$cf_menu_lib$cf_cv_libtype... $ECHO_C" >&6
13019 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
13020 echo $ECHO_N "(cached) $ECHO_C" >&6
13022 ac_check_lib_save_LIBS=$LIBS
13023 LIBS="-l$cf_menu_lib$cf_cv_libtype $LIBS"
13024 cat >conftest.$ac_ext <<_ACEOF
13025 #line 13025 "configure"
13026 #include "confdefs.h"
13028 /* Override any gcc2 internal prototype to avoid an error. */
13032 /* We use char because int might match the return type of a gcc2
13033 builtin and then its argument prototype would still apply. */
13034 char menu_driver ();
13043 rm -f conftest.$ac_objext conftest$ac_exeext
13044 if { (eval echo "$as_me:13044: \"$ac_link\"") >&5
13045 (eval $ac_link) 2>&5
13047 echo "$as_me:13047: \$? = $ac_status" >&5
13048 (exit $ac_status); } &&
13049 { ac_try='test -s conftest$ac_exeext'
13050 { (eval echo "$as_me:13050: \"$ac_try\"") >&5
13051 (eval $ac_try) 2>&5
13053 echo "$as_me:13053: \$? = $ac_status" >&5
13054 (exit $ac_status); }; }; then
13055 eval "$as_ac_Lib=yes"
13057 echo "$as_me: failed program was:" >&5
13058 cat conftest.$ac_ext >&5
13059 eval "$as_ac_Lib=no"
13061 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13062 LIBS=$ac_check_lib_save_LIBS
13064 echo "$as_me:13064: result: `eval echo '${'$as_ac_Lib'}'`" >&5
13065 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
13066 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
13067 cat >>confdefs.h <<EOF
13068 #define `echo "HAVE_LIB$cf_menu_lib$cf_cv_libtype" | $as_tr_cpp` 1
13071 LIBS="-l$cf_menu_lib$cf_cv_libtype $LIBS"
13075 as_ac_Lib=`echo "ac_cv_lib_$cf_form_lib$cf_cv_libtype''_form_driver" | $as_tr_sh`
13076 echo "$as_me:13076: checking for form_driver in -l$cf_form_lib$cf_cv_libtype" >&5
13077 echo $ECHO_N "checking for form_driver in -l$cf_form_lib$cf_cv_libtype... $ECHO_C" >&6
13078 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
13079 echo $ECHO_N "(cached) $ECHO_C" >&6
13081 ac_check_lib_save_LIBS=$LIBS
13082 LIBS="-l$cf_form_lib$cf_cv_libtype $LIBS"
13083 cat >conftest.$ac_ext <<_ACEOF
13084 #line 13084 "configure"
13085 #include "confdefs.h"
13087 /* Override any gcc2 internal prototype to avoid an error. */
13091 /* We use char because int might match the return type of a gcc2
13092 builtin and then its argument prototype would still apply. */
13093 char form_driver ();
13102 rm -f conftest.$ac_objext conftest$ac_exeext
13103 if { (eval echo "$as_me:13103: \"$ac_link\"") >&5
13104 (eval $ac_link) 2>&5
13106 echo "$as_me:13106: \$? = $ac_status" >&5
13107 (exit $ac_status); } &&
13108 { ac_try='test -s conftest$ac_exeext'
13109 { (eval echo "$as_me:13109: \"$ac_try\"") >&5
13110 (eval $ac_try) 2>&5
13112 echo "$as_me:13112: \$? = $ac_status" >&5
13113 (exit $ac_status); }; }; then
13114 eval "$as_ac_Lib=yes"
13116 echo "$as_me: failed program was:" >&5
13117 cat conftest.$ac_ext >&5
13118 eval "$as_ac_Lib=no"
13120 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13121 LIBS=$ac_check_lib_save_LIBS
13123 echo "$as_me:13123: result: `eval echo '${'$as_ac_Lib'}'`" >&5
13124 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
13125 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
13126 cat >>confdefs.h <<EOF
13127 #define `echo "HAVE_LIB$cf_form_lib$cf_cv_libtype" | $as_tr_cpp` 1
13130 LIBS="-l$cf_form_lib$cf_cv_libtype $LIBS"
13134 # look for curses-related headers
13145 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
13146 echo "$as_me:13146: checking for $ac_header" >&5
13147 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13148 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13149 echo $ECHO_N "(cached) $ECHO_C" >&6
13151 cat >conftest.$ac_ext <<_ACEOF
13152 #line 13152 "configure"
13153 #include "confdefs.h"
13154 #include <$ac_header>
13156 if { (eval echo "$as_me:13156: \"$ac_cpp conftest.$ac_ext\"") >&5
13157 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13159 egrep -v '^ *\+' conftest.er1 >conftest.err
13161 cat conftest.err >&5
13162 echo "$as_me:13162: \$? = $ac_status" >&5
13163 (exit $ac_status); } >/dev/null; then
13164 if test -s conftest.err; then
13165 ac_cpp_err=$ac_c_preproc_warn_flag
13172 if test -z "$ac_cpp_err"; then
13173 eval "$as_ac_Header=yes"
13175 echo "$as_me: failed program was:" >&5
13176 cat conftest.$ac_ext >&5
13177 eval "$as_ac_Header=no"
13179 rm -f conftest.err conftest.$ac_ext
13181 echo "$as_me:13181: result: `eval echo '${'$as_ac_Header'}'`" >&5
13182 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13183 if test `eval echo '${'$as_ac_Header'}'` = yes; then
13184 cat >>confdefs.h <<EOF
13185 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
13194 echo "$as_me:13194: checking for ANSI C header files" >&5
13195 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
13196 if test "${ac_cv_header_stdc+set}" = set; then
13197 echo $ECHO_N "(cached) $ECHO_C" >&6
13199 cat >conftest.$ac_ext <<_ACEOF
13200 #line 13200 "configure"
13201 #include "confdefs.h"
13202 #include <stdlib.h>
13203 #include <stdarg.h>
13204 #include <string.h>
13208 if { (eval echo "$as_me:13208: \"$ac_cpp conftest.$ac_ext\"") >&5
13209 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13211 egrep -v '^ *\+' conftest.er1 >conftest.err
13213 cat conftest.err >&5
13214 echo "$as_me:13214: \$? = $ac_status" >&5
13215 (exit $ac_status); } >/dev/null; then
13216 if test -s conftest.err; then
13217 ac_cpp_err=$ac_c_preproc_warn_flag
13224 if test -z "$ac_cpp_err"; then
13225 ac_cv_header_stdc=yes
13227 echo "$as_me: failed program was:" >&5
13228 cat conftest.$ac_ext >&5
13229 ac_cv_header_stdc=no
13231 rm -f conftest.err conftest.$ac_ext
13233 if test $ac_cv_header_stdc = yes; then
13234 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
13235 cat >conftest.$ac_ext <<_ACEOF
13236 #line 13236 "configure"
13237 #include "confdefs.h"
13238 #include <string.h>
13241 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13242 egrep "memchr" >/dev/null 2>&1; then
13245 ac_cv_header_stdc=no
13251 if test $ac_cv_header_stdc = yes; then
13252 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
13253 cat >conftest.$ac_ext <<_ACEOF
13254 #line 13254 "configure"
13255 #include "confdefs.h"
13256 #include <stdlib.h>
13259 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13260 egrep "free" >/dev/null 2>&1; then
13263 ac_cv_header_stdc=no
13269 if test $ac_cv_header_stdc = yes; then
13270 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
13271 if test "$cross_compiling" = yes; then
13274 cat >conftest.$ac_ext <<_ACEOF
13275 #line 13275 "configure"
13276 #include "confdefs.h"
13278 #if ((' ' & 0x0FF) == 0x020)
13279 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
13280 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
13282 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
13283 || ('j' <= (c) && (c) <= 'r') \
13284 || ('s' <= (c) && (c) <= 'z'))
13285 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
13288 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
13293 for (i = 0; i < 256; i++)
13294 if (XOR (islower (i), ISLOWER (i))
13295 || toupper (i) != TOUPPER (i))
13296 $ac_main_return(2);
13297 $ac_main_return (0);
13300 rm -f conftest$ac_exeext
13301 if { (eval echo "$as_me:13301: \"$ac_link\"") >&5
13302 (eval $ac_link) 2>&5
13304 echo "$as_me:13304: \$? = $ac_status" >&5
13305 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13306 { (eval echo "$as_me:13306: \"$ac_try\"") >&5
13307 (eval $ac_try) 2>&5
13309 echo "$as_me:13309: \$? = $ac_status" >&5
13310 (exit $ac_status); }; }; then
13313 echo "$as_me: program exited with status $ac_status" >&5
13314 echo "$as_me: failed program was:" >&5
13315 cat conftest.$ac_ext >&5
13316 ac_cv_header_stdc=no
13318 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13322 echo "$as_me:13322: result: $ac_cv_header_stdc" >&5
13323 echo "${ECHO_T}$ac_cv_header_stdc" >&6
13324 if test $ac_cv_header_stdc = yes; then
13326 cat >>confdefs.h <<\EOF
13327 #define STDC_HEADERS 1
13332 echo "$as_me:13332: checking whether time.h and sys/time.h may both be included" >&5
13333 echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
13334 if test "${ac_cv_header_time+set}" = set; then
13335 echo $ECHO_N "(cached) $ECHO_C" >&6
13337 cat >conftest.$ac_ext <<_ACEOF
13338 #line 13338 "configure"
13339 #include "confdefs.h"
13340 #include <sys/types.h>
13341 #include <sys/time.h>
13347 if ((struct tm *) 0)
13353 rm -f conftest.$ac_objext
13354 if { (eval echo "$as_me:13354: \"$ac_compile\"") >&5
13355 (eval $ac_compile) 2>&5
13357 echo "$as_me:13357: \$? = $ac_status" >&5
13358 (exit $ac_status); } &&
13359 { ac_try='test -s conftest.$ac_objext'
13360 { (eval echo "$as_me:13360: \"$ac_try\"") >&5
13361 (eval $ac_try) 2>&5
13363 echo "$as_me:13363: \$? = $ac_status" >&5
13364 (exit $ac_status); }; }; then
13365 ac_cv_header_time=yes
13367 echo "$as_me: failed program was:" >&5
13368 cat conftest.$ac_ext >&5
13369 ac_cv_header_time=no
13371 rm -f conftest.$ac_objext conftest.$ac_ext
13373 echo "$as_me:13373: result: $ac_cv_header_time" >&5
13374 echo "${ECHO_T}$ac_cv_header_time" >&6
13375 if test $ac_cv_header_time = yes; then
13377 cat >>confdefs.h <<\EOF
13378 #define TIME_WITH_SYS_TIME 1
13395 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
13396 echo "$as_me:13396: checking for $ac_header" >&5
13397 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13398 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13399 echo $ECHO_N "(cached) $ECHO_C" >&6
13401 cat >conftest.$ac_ext <<_ACEOF
13402 #line 13402 "configure"
13403 #include "confdefs.h"
13404 #include <$ac_header>
13406 if { (eval echo "$as_me:13406: \"$ac_cpp conftest.$ac_ext\"") >&5
13407 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13409 egrep -v '^ *\+' conftest.er1 >conftest.err
13411 cat conftest.err >&5
13412 echo "$as_me:13412: \$? = $ac_status" >&5
13413 (exit $ac_status); } >/dev/null; then
13414 if test -s conftest.err; then
13415 ac_cpp_err=$ac_c_preproc_warn_flag
13422 if test -z "$ac_cpp_err"; then
13423 eval "$as_ac_Header=yes"
13425 echo "$as_me: failed program was:" >&5
13426 cat conftest.$ac_ext >&5
13427 eval "$as_ac_Header=no"
13429 rm -f conftest.err conftest.$ac_ext
13431 echo "$as_me:13431: result: `eval echo '${'$as_ac_Header'}'`" >&5
13432 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13433 if test `eval echo '${'$as_ac_Header'}'` = yes; then
13434 cat >>confdefs.h <<EOF
13435 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
13441 for ac_header in unistd.h getopt.h
13443 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
13444 echo "$as_me:13444: checking for $ac_header" >&5
13445 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13446 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13447 echo $ECHO_N "(cached) $ECHO_C" >&6
13449 cat >conftest.$ac_ext <<_ACEOF
13450 #line 13450 "configure"
13451 #include "confdefs.h"
13452 #include <$ac_header>
13454 if { (eval echo "$as_me:13454: \"$ac_cpp conftest.$ac_ext\"") >&5
13455 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13457 egrep -v '^ *\+' conftest.er1 >conftest.err
13459 cat conftest.err >&5
13460 echo "$as_me:13460: \$? = $ac_status" >&5
13461 (exit $ac_status); } >/dev/null; then
13462 if test -s conftest.err; then
13463 ac_cpp_err=$ac_c_preproc_warn_flag
13470 if test -z "$ac_cpp_err"; then
13471 eval "$as_ac_Header=yes"
13473 echo "$as_me: failed program was:" >&5
13474 cat conftest.$ac_ext >&5
13475 eval "$as_ac_Header=no"
13477 rm -f conftest.err conftest.$ac_ext
13479 echo "$as_me:13479: result: `eval echo '${'$as_ac_Header'}'`" >&5
13480 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13481 if test `eval echo '${'$as_ac_Header'}'` = yes; then
13482 cat >>confdefs.h <<EOF
13483 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
13489 echo "$as_me:13489: checking for header declaring getopt variables" >&5
13490 echo $ECHO_N "checking for header declaring getopt variables... $ECHO_C" >&6
13491 if test "${cf_cv_getopt_header+set}" = set; then
13492 echo $ECHO_N "(cached) $ECHO_C" >&6
13495 cf_cv_getopt_header=none
13496 for cf_header in stdio.h stdlib.h unistd.h getopt.h
13498 cat >conftest.$ac_ext <<_ACEOF
13499 #line 13499 "configure"
13500 #include "confdefs.h"
13502 #include <$cf_header>
13506 int x = optind; char *y = optarg
13511 rm -f conftest.$ac_objext
13512 if { (eval echo "$as_me:13512: \"$ac_compile\"") >&5
13513 (eval $ac_compile) 2>&5
13515 echo "$as_me:13515: \$? = $ac_status" >&5
13516 (exit $ac_status); } &&
13517 { ac_try='test -s conftest.$ac_objext'
13518 { (eval echo "$as_me:13518: \"$ac_try\"") >&5
13519 (eval $ac_try) 2>&5
13521 echo "$as_me:13521: \$? = $ac_status" >&5
13522 (exit $ac_status); }; }; then
13523 cf_cv_getopt_header=$cf_header
13526 echo "$as_me: failed program was:" >&5
13527 cat conftest.$ac_ext >&5
13529 rm -f conftest.$ac_objext conftest.$ac_ext
13533 echo "$as_me:13533: result: $cf_cv_getopt_header" >&5
13534 echo "${ECHO_T}$cf_cv_getopt_header" >&6
13535 if test $cf_cv_getopt_header != none ; then
13537 cat >>confdefs.h <<\EOF
13538 #define HAVE_GETOPT_HEADER 1
13547 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13548 echo "$as_me:13548: checking for $ac_func" >&5
13549 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13550 if eval "test \"\${$as_ac_var+set}\" = set"; then
13551 echo $ECHO_N "(cached) $ECHO_C" >&6
13553 cat >conftest.$ac_ext <<_ACEOF
13554 #line 13554 "configure"
13555 #include "confdefs.h"
13556 /* System header to define __stub macros and hopefully few prototypes,
13557 which can conflict with char $ac_func (); below. */
13558 #include <assert.h>
13559 /* Override any gcc2 internal prototype to avoid an error. */
13563 /* We use char because int might match the return type of a gcc2
13564 builtin and then its argument prototype would still apply. */
13571 /* The GNU C library defines this for functions which it implements
13572 to always fail with ENOSYS. Some functions are actually named
13573 something starting with __ and the normal name is an alias. */
13574 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13577 f = $ac_func; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
13584 rm -f conftest.$ac_objext conftest$ac_exeext
13585 if { (eval echo "$as_me:13585: \"$ac_link\"") >&5
13586 (eval $ac_link) 2>&5
13588 echo "$as_me:13588: \$? = $ac_status" >&5
13589 (exit $ac_status); } &&
13590 { ac_try='test -s conftest$ac_exeext'
13591 { (eval echo "$as_me:13591: \"$ac_try\"") >&5
13592 (eval $ac_try) 2>&5
13594 echo "$as_me:13594: \$? = $ac_status" >&5
13595 (exit $ac_status); }; }; then
13596 eval "$as_ac_var=yes"
13598 echo "$as_me: failed program was:" >&5
13599 cat conftest.$ac_ext >&5
13600 eval "$as_ac_var=no"
13602 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13604 echo "$as_me:13604: result: `eval echo '${'$as_ac_var'}'`" >&5
13605 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13606 if test `eval echo '${'$as_ac_var'}'` = yes; then
13607 cat >>confdefs.h <<EOF
13608 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13614 if test "$cf_enable_widec" = yes; then
13627 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13628 echo "$as_me:13628: checking for $ac_func" >&5
13629 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13630 if eval "test \"\${$as_ac_var+set}\" = set"; then
13631 echo $ECHO_N "(cached) $ECHO_C" >&6
13633 cat >conftest.$ac_ext <<_ACEOF
13634 #line 13634 "configure"
13635 #include "confdefs.h"
13636 /* System header to define __stub macros and hopefully few prototypes,
13637 which can conflict with char $ac_func (); below. */
13638 #include <assert.h>
13639 /* Override any gcc2 internal prototype to avoid an error. */
13643 /* We use char because int might match the return type of a gcc2
13644 builtin and then its argument prototype would still apply. */
13651 /* The GNU C library defines this for functions which it implements
13652 to always fail with ENOSYS. Some functions are actually named
13653 something starting with __ and the normal name is an alias. */
13654 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13657 f = $ac_func; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
13664 rm -f conftest.$ac_objext conftest$ac_exeext
13665 if { (eval echo "$as_me:13665: \"$ac_link\"") >&5
13666 (eval $ac_link) 2>&5
13668 echo "$as_me:13668: \$? = $ac_status" >&5
13669 (exit $ac_status); } &&
13670 { ac_try='test -s conftest$ac_exeext'
13671 { (eval echo "$as_me:13671: \"$ac_try\"") >&5
13672 (eval $ac_try) 2>&5
13674 echo "$as_me:13674: \$? = $ac_status" >&5
13675 (exit $ac_status); }; }; then
13676 eval "$as_ac_var=yes"
13678 echo "$as_me: failed program was:" >&5
13679 cat conftest.$ac_ext >&5
13680 eval "$as_ac_var=no"
13682 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13684 echo "$as_me:13684: result: `eval echo '${'$as_ac_var'}'`" >&5
13685 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13686 if test `eval echo '${'$as_ac_var'}'` = yes; then
13687 cat >>confdefs.h <<EOF
13688 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13696 echo "$as_me:13696: checking if we must define _XOPEN_SOURCE_EXTENDED" >&5
13697 echo $ECHO_N "checking if we must define _XOPEN_SOURCE_EXTENDED... $ECHO_C" >&6
13698 if test "${cf_cv_need_xopen_extension+set}" = set; then
13699 echo $ECHO_N "(cached) $ECHO_C" >&6
13702 cat >conftest.$ac_ext <<_ACEOF
13703 #line 13703 "configure"
13704 #include "confdefs.h"
13706 #include <stdlib.h>
13707 #include <${cf_cv_ncurses_header:-curses.h}>
13712 #if defined(NCURSES_VERSION_PATCH)
13713 #if (NCURSES_VERSION_PATCH < 20100501) && (NCURSES_VERSION_PATCH >= 20100403)
13717 long x = winnstr(stdscr, "", 0);
13719 getbegyx(stdscr, y1, x1)
13724 rm -f conftest.$ac_objext conftest$ac_exeext
13725 if { (eval echo "$as_me:13725: \"$ac_link\"") >&5
13726 (eval $ac_link) 2>&5
13728 echo "$as_me:13728: \$? = $ac_status" >&5
13729 (exit $ac_status); } &&
13730 { ac_try='test -s conftest$ac_exeext'
13731 { (eval echo "$as_me:13731: \"$ac_try\"") >&5
13732 (eval $ac_try) 2>&5
13734 echo "$as_me:13734: \$? = $ac_status" >&5
13735 (exit $ac_status); }; }; then
13736 cf_cv_need_xopen_extension=no
13738 echo "$as_me: failed program was:" >&5
13739 cat conftest.$ac_ext >&5
13740 cat >conftest.$ac_ext <<_ACEOF
13741 #line 13741 "configure"
13742 #include "confdefs.h"
13744 #define _XOPEN_SOURCE_EXTENDED
13745 #include <stdlib.h>
13746 #include <${cf_cv_ncurses_header:-curses.h}>
13751 #ifdef NCURSES_VERSION
13753 int check2 = curs_set((int)sizeof(check));
13755 long x = winnstr(stdscr, "", 0);
13757 getbegyx(stdscr, y1, x1)
13762 rm -f conftest.$ac_objext conftest$ac_exeext
13763 if { (eval echo "$as_me:13763: \"$ac_link\"") >&5
13764 (eval $ac_link) 2>&5
13766 echo "$as_me:13766: \$? = $ac_status" >&5
13767 (exit $ac_status); } &&
13768 { ac_try='test -s conftest$ac_exeext'
13769 { (eval echo "$as_me:13769: \"$ac_try\"") >&5
13770 (eval $ac_try) 2>&5
13772 echo "$as_me:13772: \$? = $ac_status" >&5
13773 (exit $ac_status); }; }; then
13774 cf_cv_need_xopen_extension=yes
13776 echo "$as_me: failed program was:" >&5
13777 cat conftest.$ac_ext >&5
13778 cf_cv_need_xopen_extension=unknown
13780 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13782 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13784 echo "$as_me:13784: result: $cf_cv_need_xopen_extension" >&5
13785 echo "${ECHO_T}$cf_cv_need_xopen_extension" >&6
13786 test $cf_cv_need_xopen_extension = yes && CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE_EXTENDED"
13788 echo "$as_me:13788: checking for term.h" >&5
13789 echo $ECHO_N "checking for term.h... $ECHO_C" >&6
13790 if test "${cf_cv_term_header+set}" = set; then
13791 echo $ECHO_N "(cached) $ECHO_C" >&6
13794 # If we found <ncurses/curses.h>, look for <ncurses/term.h>, but always look
13795 # for <term.h> if we do not find the variant.
13797 cf_header_list="term.h ncurses/term.h ncursesw/term.h"
13799 case ${cf_cv_ncurses_header:-curses.h} in #(vi
13801 cf_header_item=`echo ${cf_cv_ncurses_header:-curses.h} | sed -e 's%\..*%%' -e 's%/.*%/%'`term.h
13802 cf_header_list="$cf_header_item $cf_header_list"
13806 for cf_header in $cf_header_list
13808 cat >conftest.$ac_ext <<_ACEOF
13809 #line 13809 "configure"
13810 #include "confdefs.h"
13812 #include <${cf_cv_ncurses_header:-curses.h}>
13813 #include <${cf_header}>
13822 rm -f conftest.$ac_objext
13823 if { (eval echo "$as_me:13823: \"$ac_compile\"") >&5
13824 (eval $ac_compile) 2>&5
13826 echo "$as_me:13826: \$? = $ac_status" >&5
13827 (exit $ac_status); } &&
13828 { ac_try='test -s conftest.$ac_objext'
13829 { (eval echo "$as_me:13829: \"$ac_try\"") >&5
13830 (eval $ac_try) 2>&5
13832 echo "$as_me:13832: \$? = $ac_status" >&5
13833 (exit $ac_status); }; }; then
13834 cf_cv_term_header=$cf_header
13837 echo "$as_me: failed program was:" >&5
13838 cat conftest.$ac_ext >&5
13839 cf_cv_term_header=no
13841 rm -f conftest.$ac_objext conftest.$ac_ext
13844 case $cf_cv_term_header in #(vi
13846 # If curses is ncurses, some packagers still mess it up by trying to make
13847 # us use GNU termcap. This handles the most common case.
13848 for cf_header in ncurses/term.h ncursesw/term.h
13850 cat >conftest.$ac_ext <<_ACEOF
13851 #line 13851 "configure"
13852 #include "confdefs.h"
13854 #include <${cf_cv_ncurses_header:-curses.h}>
13855 #ifdef NCURSES_VERSION
13856 #include <${cf_header}>
13868 rm -f conftest.$ac_objext
13869 if { (eval echo "$as_me:13869: \"$ac_compile\"") >&5
13870 (eval $ac_compile) 2>&5
13872 echo "$as_me:13872: \$? = $ac_status" >&5
13873 (exit $ac_status); } &&
13874 { ac_try='test -s conftest.$ac_objext'
13875 { (eval echo "$as_me:13875: \"$ac_try\"") >&5
13876 (eval $ac_try) 2>&5
13878 echo "$as_me:13878: \$? = $ac_status" >&5
13879 (exit $ac_status); }; }; then
13880 cf_cv_term_header=$cf_header
13883 echo "$as_me: failed program was:" >&5
13884 cat conftest.$ac_ext >&5
13885 cf_cv_term_header=no
13887 rm -f conftest.$ac_objext conftest.$ac_ext
13893 echo "$as_me:13893: result: $cf_cv_term_header" >&5
13894 echo "${ECHO_T}$cf_cv_term_header" >&6
13896 case $cf_cv_term_header in #(vi
13899 cat >>confdefs.h <<\EOF
13900 #define HAVE_TERM_H 1
13904 ncurses/term.h) #(vi
13906 cat >>confdefs.h <<\EOF
13907 #define HAVE_NCURSES_TERM_H 1
13913 cat >>confdefs.h <<\EOF
13914 #define HAVE_NCURSESW_TERM_H 1
13920 echo "$as_me:13920: checking for unctrl.h" >&5
13921 echo $ECHO_N "checking for unctrl.h... $ECHO_C" >&6
13922 if test "${cf_cv_unctrl_header+set}" = set; then
13923 echo $ECHO_N "(cached) $ECHO_C" >&6
13926 # If we found <ncurses/curses.h>, look for <ncurses/unctrl.h>, but always look
13927 # for <unctrl.h> if we do not find the variant.
13929 cf_header_list="unctrl.h ncurses/unctrl.h ncursesw/unctrl.h"
13931 case ${cf_cv_ncurses_header:-curses.h} in #(vi
13933 cf_header_item=`echo ${cf_cv_ncurses_header:-curses.h} | sed -e 's%\..*%%' -e 's%/.*%/%'`unctrl.h
13934 cf_header_list="$cf_header_item $cf_header_list"
13938 for cf_header in $cf_header_list
13940 cat >conftest.$ac_ext <<_ACEOF
13941 #line 13941 "configure"
13942 #include "confdefs.h"
13944 #include <${cf_cv_ncurses_header:-curses.h}>
13945 #include <${cf_header}>
13954 rm -f conftest.$ac_objext
13955 if { (eval echo "$as_me:13955: \"$ac_compile\"") >&5
13956 (eval $ac_compile) 2>&5
13958 echo "$as_me:13958: \$? = $ac_status" >&5
13959 (exit $ac_status); } &&
13960 { ac_try='test -s conftest.$ac_objext'
13961 { (eval echo "$as_me:13961: \"$ac_try\"") >&5
13962 (eval $ac_try) 2>&5
13964 echo "$as_me:13964: \$? = $ac_status" >&5
13965 (exit $ac_status); }; }; then
13966 cf_cv_unctrl_header=$cf_header
13969 echo "$as_me: failed program was:" >&5
13970 cat conftest.$ac_ext >&5
13971 cf_cv_unctrl_header=no
13973 rm -f conftest.$ac_objext conftest.$ac_ext
13977 echo "$as_me:13977: result: $cf_cv_unctrl_header" >&5
13978 echo "${ECHO_T}$cf_cv_unctrl_header" >&6
13980 case $cf_cv_unctrl_header in #(vi
13982 { echo "$as_me:13982: WARNING: unctrl.h header not found" >&5
13983 echo "$as_me: WARNING: unctrl.h header not found" >&2;}
13987 case $cf_cv_unctrl_header in #(vi
13990 cat >>confdefs.h <<\EOF
13991 #define HAVE_UNCTRL_H 1
13995 ncurses/unctrl.h) #(vi
13997 cat >>confdefs.h <<\EOF
13998 #define HAVE_NCURSES_UNCTRL_H 1
14004 cat >>confdefs.h <<\EOF
14005 #define HAVE_NCURSESW_UNCTRL_H 1
14012 assume_default_colors \
14039 use_default_colors \
14051 cf_tr_func=`echo "$cf_func" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14053 echo "$as_me:14053: checking for ${cf_func}" >&5
14054 echo $ECHO_N "checking for ${cf_func}... $ECHO_C" >&6
14056 echo "${as_me:-configure}:14056: testing ${cf_func} ..." 1>&5
14058 if eval "test \"\${cf_cv_func_$cf_func+set}\" = set"; then
14059 echo $ECHO_N "(cached) $ECHO_C" >&6
14062 eval cf_result='$ac_cv_func_'$cf_func
14063 if test ".$cf_result" != ".no"; then
14064 cat >conftest.$ac_ext <<_ACEOF
14065 #line 14065 "configure"
14066 #include "confdefs.h"
14068 #ifdef HAVE_XCURSES
14069 #include <xcurses.h>
14070 char * XCursesProgramName = "test";
14072 #include <${cf_cv_ncurses_header:-curses.h}>
14073 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
14074 #include <ncursesw/term.h>
14075 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
14076 #include <ncurses/term.h>
14077 #elif defined(HAVE_TERM_H)
14087 long foo = (long)(&${cf_func});
14088 fprintf(stderr, "testing linkage of $cf_func:%p\n", foo);
14089 if (foo + 1234 > 5678)
14090 ${cf_cv_main_return:-return}(foo);
14097 rm -f conftest.$ac_objext conftest$ac_exeext
14098 if { (eval echo "$as_me:14098: \"$ac_link\"") >&5
14099 (eval $ac_link) 2>&5
14101 echo "$as_me:14101: \$? = $ac_status" >&5
14102 (exit $ac_status); } &&
14103 { ac_try='test -s conftest$ac_exeext'
14104 { (eval echo "$as_me:14104: \"$ac_try\"") >&5
14105 (eval $ac_try) 2>&5
14107 echo "$as_me:14107: \$? = $ac_status" >&5
14108 (exit $ac_status); }; }; then
14111 echo "$as_me: failed program was:" >&5
14112 cat conftest.$ac_ext >&5
14115 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14117 eval 'cf_cv_func_'$cf_func'=$cf_result'
14121 # use the computed/retrieved cache-value:
14122 eval 'cf_result=$cf_cv_func_'$cf_func
14123 echo "$as_me:14123: result: $cf_result" >&5
14124 echo "${ECHO_T}$cf_result" >&6
14125 if test $cf_result != no; then
14126 cat >>confdefs.h <<EOF
14127 #define HAVE_${cf_tr_func} 1
14133 for cf_func in tputs
14136 cf_tr_func=`echo "$cf_func" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14138 echo "$as_me:14138: checking for ${cf_func}" >&5
14139 echo $ECHO_N "checking for ${cf_func}... $ECHO_C" >&6
14141 echo "${as_me:-configure}:14141: testing ${cf_func} ..." 1>&5
14143 if eval "test \"\${cf_cv_func_$cf_func+set}\" = set"; then
14144 echo $ECHO_N "(cached) $ECHO_C" >&6
14147 eval cf_result='$ac_cv_func_'$cf_func
14148 if test ".$cf_result" != ".no"; then
14149 cat >conftest.$ac_ext <<_ACEOF
14150 #line 14150 "configure"
14151 #include "confdefs.h"
14153 #ifdef HAVE_XCURSES
14154 #include <xcurses.h>
14155 char * XCursesProgramName = "test";
14157 #include <${cf_cv_ncurses_header:-curses.h}>
14158 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
14159 #include <ncursesw/term.h>
14160 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
14161 #include <ncurses/term.h>
14162 #elif defined(HAVE_TERM_H)
14172 long foo = (long)(&${cf_func});
14173 fprintf(stderr, "testing linkage of $cf_func:%p\n", foo);
14174 if (foo + 1234 > 5678)
14175 ${cf_cv_main_return:-return}(foo);
14182 rm -f conftest.$ac_objext conftest$ac_exeext
14183 if { (eval echo "$as_me:14183: \"$ac_link\"") >&5
14184 (eval $ac_link) 2>&5
14186 echo "$as_me:14186: \$? = $ac_status" >&5
14187 (exit $ac_status); } &&
14188 { ac_try='test -s conftest$ac_exeext'
14189 { (eval echo "$as_me:14189: \"$ac_try\"") >&5
14190 (eval $ac_try) 2>&5
14192 echo "$as_me:14192: \$? = $ac_status" >&5
14193 (exit $ac_status); }; }; then
14196 echo "$as_me: failed program was:" >&5
14197 cat conftest.$ac_ext >&5
14200 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14202 eval 'cf_cv_func_'$cf_func'=$cf_result'
14206 # use the computed/retrieved cache-value:
14207 eval 'cf_result=$cf_cv_func_'$cf_func
14208 echo "$as_me:14208: result: $cf_result" >&5
14209 echo "${ECHO_T}$cf_result" >&6
14210 if test $cf_result != no; then
14211 cat >>confdefs.h <<EOF
14212 #define HAVE_${cf_tr_func} 1
14218 if test x$cf_cv_func_tputs = xyes
14221 for cf_arg in int char
14223 for cf_ret in int void
14225 if test $cf_ret = void
14227 cf_return="/* nothing */"
14229 cf_return="return value"
14231 cat >conftest.$ac_ext <<_ACEOF
14232 #line 14232 "configure"
14233 #include "confdefs.h"
14235 #include <${cf_cv_ncurses_header:-curses.h}>
14236 #include <$cf_cv_term_header>
14238 static $cf_ret outc($cf_arg value) { $cf_return; }
14244 tputs("hello", 0, outc);
14245 ${cf_cv_main_return:-return}(0);
14251 rm -f conftest.$ac_objext
14252 if { (eval echo "$as_me:14252: \"$ac_compile\"") >&5
14253 (eval $ac_compile) 2>&5
14255 echo "$as_me:14255: \$? = $ac_status" >&5
14256 (exit $ac_status); } &&
14257 { ac_try='test -s conftest.$ac_objext'
14258 { (eval echo "$as_me:14258: \"$ac_try\"") >&5
14259 (eval $ac_try) 2>&5
14261 echo "$as_me:14261: \$? = $ac_status" >&5
14262 (exit $ac_status); }; }; then
14264 test -n "$verbose" && echo " prototype $cf_ret func($cf_arg value)" 1>&6
14266 echo "${as_me:-configure}:14266: testing prototype $cf_ret func($cf_arg value) ..." 1>&5
14268 cat >>confdefs.h <<EOF
14269 #define TPUTS_ARG $cf_arg
14270 #define TPUTS_PROTO(func,value) $cf_ret func(TPUTS_ARG value)
14271 #define TPUTS_RETURN(value) $cf_return
14277 echo "$as_me: failed program was:" >&5
14278 cat conftest.$ac_ext >&5
14280 rm -f conftest.$ac_objext conftest.$ac_ext
14282 test $cf_done = yes && break
14286 echo "$as_me:14286: checking for ncurses extended functions" >&5
14287 echo $ECHO_N "checking for ncurses extended functions... $ECHO_C" >&6
14288 if test "${cf_cv_ncurses_ext_funcs+set}" = set; then
14289 echo $ECHO_N "(cached) $ECHO_C" >&6
14292 cat >conftest.$ac_ext <<_ACEOF
14293 #line 14293 "configure"
14294 #include "confdefs.h"
14296 #include <${cf_cv_ncurses_header:-curses.h}>
14301 int x = NCURSES_EXT_FUNCS
14307 rm -f conftest.$ac_objext
14308 if { (eval echo "$as_me:14308: \"$ac_compile\"") >&5
14309 (eval $ac_compile) 2>&5
14311 echo "$as_me:14311: \$? = $ac_status" >&5
14312 (exit $ac_status); } &&
14313 { ac_try='test -s conftest.$ac_objext'
14314 { (eval echo "$as_me:14314: \"$ac_try\"") >&5
14315 (eval $ac_try) 2>&5
14317 echo "$as_me:14317: \$? = $ac_status" >&5
14318 (exit $ac_status); }; }; then
14319 cf_cv_ncurses_ext_funcs=defined
14321 echo "$as_me: failed program was:" >&5
14322 cat conftest.$ac_ext >&5
14324 cat >conftest.$ac_ext <<_ACEOF
14325 #line 14325 "configure"
14326 #include "confdefs.h"
14328 #include <${cf_cv_ncurses_header:-curses.h}>
14333 (void) assume_default_colors (0, 0);
14334 (void) curses_version ();
14335 (void) define_key (0, 0);
14336 (void) is_term_resized (0, 0);
14337 (void) key_defined (0);
14338 (void) keybound (0, 0);
14339 (void) keyok (0, 0);
14340 (void) resize_term (0, 0);
14341 (void) resizeterm (0, 0);
14342 (void) use_default_colors ();
14343 (void) use_extended_names (0);
14344 (void) wresize (0, 0, 0);
14349 rm -f conftest.$ac_objext conftest$ac_exeext
14350 if { (eval echo "$as_me:14350: \"$ac_link\"") >&5
14351 (eval $ac_link) 2>&5
14353 echo "$as_me:14353: \$? = $ac_status" >&5
14354 (exit $ac_status); } &&
14355 { ac_try='test -s conftest$ac_exeext'
14356 { (eval echo "$as_me:14356: \"$ac_try\"") >&5
14357 (eval $ac_try) 2>&5
14359 echo "$as_me:14359: \$? = $ac_status" >&5
14360 (exit $ac_status); }; }; then
14361 cf_cv_ncurses_ext_funcs=yes
14363 echo "$as_me: failed program was:" >&5
14364 cat conftest.$ac_ext >&5
14365 cf_cv_ncurses_ext_funcs=no
14367 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14370 rm -f conftest.$ac_objext conftest.$ac_ext
14373 echo "$as_me:14373: result: $cf_cv_ncurses_ext_funcs" >&5
14374 echo "${ECHO_T}$cf_cv_ncurses_ext_funcs" >&6
14375 test "$cf_cv_ncurses_ext_funcs" = yes &&
14376 cat >>confdefs.h <<\EOF
14377 #define NCURSES_EXT_FUNCS 1
14380 if test "$cf_enable_widec" = yes
14382 # workaround for systems with ncurses before 20111029, due to change of
14383 # feature test macro from _XPG5 to _XOPEN_SOURCE
14384 if test -n "$cf_cv_ncurses_version" && test "x$cf_cv_ncurses_version" != xno
14387 echo "$as_me:14387: checking if _XPG5 should be defined to enable wide-characters" >&5
14388 echo $ECHO_N "checking if _XPG5 should be defined to enable wide-characters... $ECHO_C" >&6
14390 cat >conftest.$ac_ext <<_ACEOF
14391 #line 14391 "configure"
14392 #include "confdefs.h"
14394 #include <${cf_cv_ncurses_header:-curses.h}>
14403 rm -f conftest.$ac_objext
14404 if { (eval echo "$as_me:14404: \"$ac_compile\"") >&5
14405 (eval $ac_compile) 2>&5
14407 echo "$as_me:14407: \$? = $ac_status" >&5
14408 (exit $ac_status); } &&
14409 { ac_try='test -s conftest.$ac_objext'
14410 { (eval echo "$as_me:14410: \"$ac_try\"") >&5
14411 (eval $ac_try) 2>&5
14413 echo "$as_me:14413: \$? = $ac_status" >&5
14414 (exit $ac_status); }; }; then
14417 echo "$as_me: failed program was:" >&5
14418 cat conftest.$ac_ext >&5
14419 cf_save_cppflags="$CPPFLAGS"
14420 CPPFLAGS="$CPPFLAGS -D_XPG5"
14421 cat >conftest.$ac_ext <<_ACEOF
14422 #line 14422 "configure"
14423 #include "confdefs.h"
14425 #include <${cf_cv_ncurses_header:-curses.h}>
14434 rm -f conftest.$ac_objext
14435 if { (eval echo "$as_me:14435: \"$ac_compile\"") >&5
14436 (eval $ac_compile) 2>&5
14438 echo "$as_me:14438: \$? = $ac_status" >&5
14439 (exit $ac_status); } &&
14440 { ac_try='test -s conftest.$ac_objext'
14441 { (eval echo "$as_me:14441: \"$ac_try\"") >&5
14442 (eval $ac_try) 2>&5
14444 echo "$as_me:14444: \$? = $ac_status" >&5
14445 (exit $ac_status); }; }; then
14448 echo "$as_me: failed program was:" >&5
14449 cat conftest.$ac_ext >&5
14451 rm -f conftest.$ac_objext conftest.$ac_ext
14452 CPPFLAGS="$cf_save_cppflags"
14454 rm -f conftest.$ac_objext conftest.$ac_ext
14455 echo "$as_me:14455: result: $cf_define_xpg5" >&5
14456 echo "${ECHO_T}$cf_define_xpg5" >&6
14458 if test "$cf_define_xpg5" = yes
14460 CPPFLAGS="$CPPFLAGS -D_XPG5"
14464 echo "$as_me:14464: checking for wide-character functions" >&5
14465 echo $ECHO_N "checking for wide-character functions... $ECHO_C" >&6
14466 if test "${cf_cv_widechar_funcs+set}" = set; then
14467 echo $ECHO_N "(cached) $ECHO_C" >&6
14470 cat >conftest.$ac_ext <<_ACEOF
14471 #line 14471 "configure"
14472 #include "confdefs.h"
14474 #include <${cf_cv_ncurses_header:-curses.h}>
14479 static wchar_t src_wchar[2];
14480 static cchar_t dst_cchar;
14481 setcchar(&dst_cchar, src_wchar, A_NORMAL, 0, (void *) 0);
14487 rm -f conftest.$ac_objext conftest$ac_exeext
14488 if { (eval echo "$as_me:14488: \"$ac_link\"") >&5
14489 (eval $ac_link) 2>&5
14491 echo "$as_me:14491: \$? = $ac_status" >&5
14492 (exit $ac_status); } &&
14493 { ac_try='test -s conftest$ac_exeext'
14494 { (eval echo "$as_me:14494: \"$ac_try\"") >&5
14495 (eval $ac_try) 2>&5
14497 echo "$as_me:14497: \$? = $ac_status" >&5
14498 (exit $ac_status); }; }; then
14499 cf_cv_widechar_funcs=yes
14501 echo "$as_me: failed program was:" >&5
14502 cat conftest.$ac_ext >&5
14503 cf_cv_widechar_funcs=no
14505 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14508 echo "$as_me:14508: result: $cf_cv_widechar_funcs" >&5
14509 echo "${ECHO_T}$cf_cv_widechar_funcs" >&6
14510 if test "$cf_cv_widechar_funcs" != no ; then
14512 cat >>confdefs.h <<\EOF
14513 #define USE_WIDEC_SUPPORT 1
14517 cat >>confdefs.h <<\EOF
14518 #define USE_WIDEC_SUPPORT 0
14523 cat >>confdefs.h <<\EOF
14524 #define USE_WIDEC_SUPPORT 0
14529 echo "$as_me:14529: checking if sys/time.h works with sys/select.h" >&5
14530 echo $ECHO_N "checking if sys/time.h works with sys/select.h... $ECHO_C" >&6
14531 if test "${cf_cv_sys_time_select+set}" = set; then
14532 echo $ECHO_N "(cached) $ECHO_C" >&6
14535 cat >conftest.$ac_ext <<_ACEOF
14536 #line 14536 "configure"
14537 #include "confdefs.h"
14539 #include <sys/types.h>
14540 #ifdef HAVE_SYS_TIME_H
14541 #include <sys/time.h>
14543 #ifdef HAVE_SYS_SELECT_H
14544 #include <sys/select.h>
14555 rm -f conftest.$ac_objext
14556 if { (eval echo "$as_me:14556: \"$ac_compile\"") >&5
14557 (eval $ac_compile) 2>&5
14559 echo "$as_me:14559: \$? = $ac_status" >&5
14560 (exit $ac_status); } &&
14561 { ac_try='test -s conftest.$ac_objext'
14562 { (eval echo "$as_me:14562: \"$ac_try\"") >&5
14563 (eval $ac_try) 2>&5
14565 echo "$as_me:14565: \$? = $ac_status" >&5
14566 (exit $ac_status); }; }; then
14567 cf_cv_sys_time_select=yes
14569 echo "$as_me: failed program was:" >&5
14570 cat conftest.$ac_ext >&5
14571 cf_cv_sys_time_select=no
14573 rm -f conftest.$ac_objext conftest.$ac_ext
14577 echo "$as_me:14577: result: $cf_cv_sys_time_select" >&5
14578 echo "${ECHO_T}$cf_cv_sys_time_select" >&6
14579 test "$cf_cv_sys_time_select" = yes &&
14580 cat >>confdefs.h <<\EOF
14581 #define HAVE_SYS_TIME_SELECT 1
14584 echo "$as_me:14584: checking for function curses_version" >&5
14585 echo $ECHO_N "checking for function curses_version... $ECHO_C" >&6
14586 if test "${cf_cv_func_curses_version+set}" = set; then
14587 echo $ECHO_N "(cached) $ECHO_C" >&6
14590 if test "$cross_compiling" = yes; then
14591 cf_cv_func_curses_version=unknown
14593 cat >conftest.$ac_ext <<_ACEOF
14594 #line 14594 "configure"
14595 #include "confdefs.h"
14597 #include <${cf_cv_ncurses_header:-curses.h}>
14601 sprintf(temp, "%s\n", curses_version());
14602 ${cf_cv_main_return:-return}(0);
14606 rm -f conftest$ac_exeext
14607 if { (eval echo "$as_me:14607: \"$ac_link\"") >&5
14608 (eval $ac_link) 2>&5
14610 echo "$as_me:14610: \$? = $ac_status" >&5
14611 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14612 { (eval echo "$as_me:14612: \"$ac_try\"") >&5
14613 (eval $ac_try) 2>&5
14615 echo "$as_me:14615: \$? = $ac_status" >&5
14616 (exit $ac_status); }; }; then
14617 cf_cv_func_curses_version=yes
14620 echo "$as_me: program exited with status $ac_status" >&5
14621 echo "$as_me: failed program was:" >&5
14622 cat conftest.$ac_ext >&5
14623 cf_cv_func_curses_version=no
14626 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14630 echo "$as_me:14630: result: $cf_cv_func_curses_version" >&5
14631 echo "${ECHO_T}$cf_cv_func_curses_version" >&6
14632 test "$cf_cv_func_curses_version" = yes &&
14633 cat >>confdefs.h <<\EOF
14634 #define HAVE_CURSES_VERSION 1
14637 echo "$as_me:14637: checking for alternate character set array" >&5
14638 echo $ECHO_N "checking for alternate character set array... $ECHO_C" >&6
14639 if test "${cf_cv_curses_acs_map+set}" = set; then
14640 echo $ECHO_N "(cached) $ECHO_C" >&6
14643 cf_cv_curses_acs_map=unknown
14644 for name in acs_map _acs_map __acs_map ${NCURSES_WRAP_PREFIX}acs_map
14646 cat >conftest.$ac_ext <<_ACEOF
14647 #line 14647 "configure"
14648 #include "confdefs.h"
14650 #include <${cf_cv_ncurses_header:-curses.h}>
14656 $name['k'] = ACS_PLUS
14662 rm -f conftest.$ac_objext conftest$ac_exeext
14663 if { (eval echo "$as_me:14663: \"$ac_link\"") >&5
14664 (eval $ac_link) 2>&5
14666 echo "$as_me:14666: \$? = $ac_status" >&5
14667 (exit $ac_status); } &&
14668 { ac_try='test -s conftest$ac_exeext'
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_curses_acs_map=$name; break
14676 echo "$as_me: failed program was:" >&5
14677 cat conftest.$ac_ext >&5
14679 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14683 echo "$as_me:14683: result: $cf_cv_curses_acs_map" >&5
14684 echo "${ECHO_T}$cf_cv_curses_acs_map" >&6
14686 test "$cf_cv_curses_acs_map" != unknown &&
14687 cat >>confdefs.h <<EOF
14688 #define CURSES_ACS_ARRAY $cf_cv_curses_acs_map
14691 if test "$cf_enable_widec" = yes; then
14693 echo "$as_me:14693: checking for wide alternate character set array" >&5
14694 echo $ECHO_N "checking for wide alternate character set array... $ECHO_C" >&6
14695 if test "${cf_cv_curses_wacs_map+set}" = set; then
14696 echo $ECHO_N "(cached) $ECHO_C" >&6
14699 cf_cv_curses_wacs_map=unknown
14700 for name in wacs_map _wacs_map __wacs_map _nc_wacs _wacs_char
14702 cat >conftest.$ac_ext <<_ACEOF
14703 #line 14703 "configure"
14704 #include "confdefs.h"
14706 #ifndef _XOPEN_SOURCE_EXTENDED
14707 #define _XOPEN_SOURCE_EXTENDED
14709 #include <${cf_cv_ncurses_header:-curses.h}>
14713 void *foo = &($name['k'])
14718 rm -f conftest.$ac_objext conftest$ac_exeext
14719 if { (eval echo "$as_me:14719: \"$ac_link\"") >&5
14720 (eval $ac_link) 2>&5
14722 echo "$as_me:14722: \$? = $ac_status" >&5
14723 (exit $ac_status); } &&
14724 { ac_try='test -s conftest$ac_exeext'
14725 { (eval echo "$as_me:14725: \"$ac_try\"") >&5
14726 (eval $ac_try) 2>&5
14728 echo "$as_me:14728: \$? = $ac_status" >&5
14729 (exit $ac_status); }; }; then
14730 cf_cv_curses_wacs_map=$name
14733 echo "$as_me: failed program was:" >&5
14734 cat conftest.$ac_ext >&5
14736 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14739 echo "$as_me:14739: result: $cf_cv_curses_wacs_map" >&5
14740 echo "${ECHO_T}$cf_cv_curses_wacs_map" >&6
14742 test "$cf_cv_curses_wacs_map" != unknown &&
14743 cat >>confdefs.h <<EOF
14744 #define CURSES_WACS_ARRAY $cf_cv_curses_wacs_map
14747 echo "$as_me:14747: checking for wide alternate character constants" >&5
14748 echo $ECHO_N "checking for wide alternate character constants... $ECHO_C" >&6
14749 if test "${cf_cv_curses_wacs_symbols+set}" = set; then
14750 echo $ECHO_N "(cached) $ECHO_C" >&6
14753 cf_cv_curses_wacs_symbols=no
14754 if test "$cf_cv_curses_wacs_map" != unknown
14756 cat >conftest.$ac_ext <<_ACEOF
14757 #line 14757 "configure"
14758 #include "confdefs.h"
14760 #ifndef _XOPEN_SOURCE_EXTENDED
14761 #define _XOPEN_SOURCE_EXTENDED
14763 #include <${cf_cv_ncurses_header:-curses.h}>
14767 cchar_t *foo = WACS_PLUS;
14768 $cf_cv_curses_wacs_map['k'] = *WACS_PLUS
14773 rm -f conftest.$ac_objext conftest$ac_exeext
14774 if { (eval echo "$as_me:14774: \"$ac_link\"") >&5
14775 (eval $ac_link) 2>&5
14777 echo "$as_me:14777: \$? = $ac_status" >&5
14778 (exit $ac_status); } &&
14779 { ac_try='test -s conftest$ac_exeext'
14780 { (eval echo "$as_me:14780: \"$ac_try\"") >&5
14781 (eval $ac_try) 2>&5
14783 echo "$as_me:14783: \$? = $ac_status" >&5
14784 (exit $ac_status); }; }; then
14785 cf_cv_curses_wacs_symbols=yes
14787 echo "$as_me: failed program was:" >&5
14788 cat conftest.$ac_ext >&5
14790 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14792 cat >conftest.$ac_ext <<_ACEOF
14793 #line 14793 "configure"
14794 #include "confdefs.h"
14796 #ifndef _XOPEN_SOURCE_EXTENDED
14797 #define _XOPEN_SOURCE_EXTENDED
14799 #include <${cf_cv_ncurses_header:-curses.h}>
14803 cchar_t *foo = WACS_PLUS
14808 rm -f conftest.$ac_objext conftest$ac_exeext
14809 if { (eval echo "$as_me:14809: \"$ac_link\"") >&5
14810 (eval $ac_link) 2>&5
14812 echo "$as_me:14812: \$? = $ac_status" >&5
14813 (exit $ac_status); } &&
14814 { ac_try='test -s conftest$ac_exeext'
14815 { (eval echo "$as_me:14815: \"$ac_try\"") >&5
14816 (eval $ac_try) 2>&5
14818 echo "$as_me:14818: \$? = $ac_status" >&5
14819 (exit $ac_status); }; }; then
14820 cf_cv_curses_wacs_symbols=yes
14822 echo "$as_me: failed program was:" >&5
14823 cat conftest.$ac_ext >&5
14825 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14829 echo "$as_me:14829: result: $cf_cv_curses_wacs_symbols" >&5
14830 echo "${ECHO_T}$cf_cv_curses_wacs_symbols" >&6
14832 test "$cf_cv_curses_wacs_symbols" != no &&
14833 cat >>confdefs.h <<\EOF
14834 #define CURSES_WACS_SYMBOLS 1
14839 echo "$as_me:14839: checking for type attr_t in ${cf_cv_ncurses_header:-curses.h}" >&5
14840 echo $ECHO_N "checking for type attr_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
14841 cat >conftest.$ac_ext <<_ACEOF
14842 #line 14842 "configure"
14843 #include "confdefs.h"
14845 #ifndef _XOPEN_SOURCE_EXTENDED
14846 #define _XOPEN_SOURCE_EXTENDED
14848 #include <${cf_cv_ncurses_header:-curses.h}>
14859 rm -f conftest.$ac_objext
14860 if { (eval echo "$as_me:14860: \"$ac_compile\"") >&5
14861 (eval $ac_compile) 2>&5
14863 echo "$as_me:14863: \$? = $ac_status" >&5
14864 (exit $ac_status); } &&
14865 { ac_try='test -s conftest.$ac_objext'
14866 { (eval echo "$as_me:14866: \"$ac_try\"") >&5
14867 (eval $ac_try) 2>&5
14869 echo "$as_me:14869: \$? = $ac_status" >&5
14870 (exit $ac_status); }; }; then
14873 echo "$as_me: failed program was:" >&5
14874 cat conftest.$ac_ext >&5
14877 rm -f conftest.$ac_objext conftest.$ac_ext
14878 echo "$as_me:14878: result: $cf_result" >&5
14879 echo "${ECHO_T}$cf_result" >&6
14880 if test $cf_result = yes ; then
14882 cf_result=`echo "have_type_attr_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14884 cat >>confdefs.h <<EOF
14885 #define $cf_result 1
14890 cat >>confdefs.h <<EOF
14891 #define attr_t long
14896 if test "$cf_enable_widec" = yes; then
14898 # This is needed on Tru64 5.0 to declare mbstate_t
14899 echo "$as_me:14899: checking if we must include wchar.h to declare mbstate_t" >&5
14900 echo $ECHO_N "checking if we must include wchar.h to declare mbstate_t... $ECHO_C" >&6
14901 if test "${cf_cv_mbstate_t+set}" = set; then
14902 echo $ECHO_N "(cached) $ECHO_C" >&6
14905 cat >conftest.$ac_ext <<_ACEOF
14906 #line 14906 "configure"
14907 #include "confdefs.h"
14909 #include <stdlib.h>
14910 #include <stdarg.h>
14912 #ifdef HAVE_LIBUTF8_H
14913 #include <libutf8.h>
14923 rm -f conftest.$ac_objext
14924 if { (eval echo "$as_me:14924: \"$ac_compile\"") >&5
14925 (eval $ac_compile) 2>&5
14927 echo "$as_me:14927: \$? = $ac_status" >&5
14928 (exit $ac_status); } &&
14929 { ac_try='test -s conftest.$ac_objext'
14930 { (eval echo "$as_me:14930: \"$ac_try\"") >&5
14931 (eval $ac_try) 2>&5
14933 echo "$as_me:14933: \$? = $ac_status" >&5
14934 (exit $ac_status); }; }; then
14937 echo "$as_me: failed program was:" >&5
14938 cat conftest.$ac_ext >&5
14939 cat >conftest.$ac_ext <<_ACEOF
14940 #line 14940 "configure"
14941 #include "confdefs.h"
14943 #include <stdlib.h>
14944 #include <stdarg.h>
14947 #ifdef HAVE_LIBUTF8_H
14948 #include <libutf8.h>
14958 rm -f conftest.$ac_objext
14959 if { (eval echo "$as_me:14959: \"$ac_compile\"") >&5
14960 (eval $ac_compile) 2>&5
14962 echo "$as_me:14962: \$? = $ac_status" >&5
14963 (exit $ac_status); } &&
14964 { ac_try='test -s conftest.$ac_objext'
14965 { (eval echo "$as_me:14965: \"$ac_try\"") >&5
14966 (eval $ac_try) 2>&5
14968 echo "$as_me:14968: \$? = $ac_status" >&5
14969 (exit $ac_status); }; }; then
14970 cf_cv_mbstate_t=yes
14972 echo "$as_me: failed program was:" >&5
14973 cat conftest.$ac_ext >&5
14974 cf_cv_mbstate_t=unknown
14976 rm -f conftest.$ac_objext conftest.$ac_ext
14978 rm -f conftest.$ac_objext conftest.$ac_ext
14980 echo "$as_me:14980: result: $cf_cv_mbstate_t" >&5
14981 echo "${ECHO_T}$cf_cv_mbstate_t" >&6
14983 if test "$cf_cv_mbstate_t" = yes ; then
14985 cat >>confdefs.h <<\EOF
14986 #define NEED_WCHAR_H 1
14992 # if we do not find mbstate_t in either place, use substitution to provide a fallback.
14993 if test "$cf_cv_mbstate_t" = unknown ; then
14994 NCURSES_MBSTATE_T=1
14997 # if we find mbstate_t in either place, use substitution to provide a fallback.
14998 if test "$cf_cv_mbstate_t" != unknown ; then
14999 NCURSES_OK_MBSTATE_T=1
15002 # This is needed on Tru64 5.0 to declare wchar_t
15003 echo "$as_me:15003: checking if we must include wchar.h to declare wchar_t" >&5
15004 echo $ECHO_N "checking if we must include wchar.h to declare wchar_t... $ECHO_C" >&6
15005 if test "${cf_cv_wchar_t+set}" = set; then
15006 echo $ECHO_N "(cached) $ECHO_C" >&6
15009 cat >conftest.$ac_ext <<_ACEOF
15010 #line 15010 "configure"
15011 #include "confdefs.h"
15013 #include <stdlib.h>
15014 #include <stdarg.h>
15016 #ifdef HAVE_LIBUTF8_H
15017 #include <libutf8.h>
15027 rm -f conftest.$ac_objext
15028 if { (eval echo "$as_me:15028: \"$ac_compile\"") >&5
15029 (eval $ac_compile) 2>&5
15031 echo "$as_me:15031: \$? = $ac_status" >&5
15032 (exit $ac_status); } &&
15033 { ac_try='test -s conftest.$ac_objext'
15034 { (eval echo "$as_me:15034: \"$ac_try\"") >&5
15035 (eval $ac_try) 2>&5
15037 echo "$as_me:15037: \$? = $ac_status" >&5
15038 (exit $ac_status); }; }; then
15041 echo "$as_me: failed program was:" >&5
15042 cat conftest.$ac_ext >&5
15043 cat >conftest.$ac_ext <<_ACEOF
15044 #line 15044 "configure"
15045 #include "confdefs.h"
15047 #include <stdlib.h>
15048 #include <stdarg.h>
15051 #ifdef HAVE_LIBUTF8_H
15052 #include <libutf8.h>
15062 rm -f conftest.$ac_objext
15063 if { (eval echo "$as_me:15063: \"$ac_compile\"") >&5
15064 (eval $ac_compile) 2>&5
15066 echo "$as_me:15066: \$? = $ac_status" >&5
15067 (exit $ac_status); } &&
15068 { ac_try='test -s conftest.$ac_objext'
15069 { (eval echo "$as_me:15069: \"$ac_try\"") >&5
15070 (eval $ac_try) 2>&5
15072 echo "$as_me:15072: \$? = $ac_status" >&5
15073 (exit $ac_status); }; }; then
15076 echo "$as_me: failed program was:" >&5
15077 cat conftest.$ac_ext >&5
15078 cf_cv_wchar_t=unknown
15080 rm -f conftest.$ac_objext conftest.$ac_ext
15082 rm -f conftest.$ac_objext conftest.$ac_ext
15084 echo "$as_me:15084: result: $cf_cv_wchar_t" >&5
15085 echo "${ECHO_T}$cf_cv_wchar_t" >&6
15087 if test "$cf_cv_wchar_t" = yes ; then
15089 cat >>confdefs.h <<\EOF
15090 #define NEED_WCHAR_H 1
15096 # if we do not find wchar_t in either place, use substitution to provide a fallback.
15097 if test "$cf_cv_wchar_t" = unknown ; then
15101 # if we find wchar_t in either place, use substitution to provide a fallback.
15102 if test "$cf_cv_wchar_t" != unknown ; then
15103 NCURSES_OK_WCHAR_T=1
15106 # This is needed on Tru64 5.0 to declare wint_t
15107 echo "$as_me:15107: checking if we must include wchar.h to declare wint_t" >&5
15108 echo $ECHO_N "checking if we must include wchar.h to declare wint_t... $ECHO_C" >&6
15109 if test "${cf_cv_wint_t+set}" = set; then
15110 echo $ECHO_N "(cached) $ECHO_C" >&6
15113 cat >conftest.$ac_ext <<_ACEOF
15114 #line 15114 "configure"
15115 #include "confdefs.h"
15117 #include <stdlib.h>
15118 #include <stdarg.h>
15120 #ifdef HAVE_LIBUTF8_H
15121 #include <libutf8.h>
15131 rm -f conftest.$ac_objext
15132 if { (eval echo "$as_me:15132: \"$ac_compile\"") >&5
15133 (eval $ac_compile) 2>&5
15135 echo "$as_me:15135: \$? = $ac_status" >&5
15136 (exit $ac_status); } &&
15137 { ac_try='test -s conftest.$ac_objext'
15138 { (eval echo "$as_me:15138: \"$ac_try\"") >&5
15139 (eval $ac_try) 2>&5
15141 echo "$as_me:15141: \$? = $ac_status" >&5
15142 (exit $ac_status); }; }; then
15145 echo "$as_me: failed program was:" >&5
15146 cat conftest.$ac_ext >&5
15147 cat >conftest.$ac_ext <<_ACEOF
15148 #line 15148 "configure"
15149 #include "confdefs.h"
15151 #include <stdlib.h>
15152 #include <stdarg.h>
15155 #ifdef HAVE_LIBUTF8_H
15156 #include <libutf8.h>
15166 rm -f conftest.$ac_objext
15167 if { (eval echo "$as_me:15167: \"$ac_compile\"") >&5
15168 (eval $ac_compile) 2>&5
15170 echo "$as_me:15170: \$? = $ac_status" >&5
15171 (exit $ac_status); } &&
15172 { ac_try='test -s conftest.$ac_objext'
15173 { (eval echo "$as_me:15173: \"$ac_try\"") >&5
15174 (eval $ac_try) 2>&5
15176 echo "$as_me:15176: \$? = $ac_status" >&5
15177 (exit $ac_status); }; }; then
15180 echo "$as_me: failed program was:" >&5
15181 cat conftest.$ac_ext >&5
15182 cf_cv_wint_t=unknown
15184 rm -f conftest.$ac_objext conftest.$ac_ext
15186 rm -f conftest.$ac_objext conftest.$ac_ext
15188 echo "$as_me:15188: result: $cf_cv_wint_t" >&5
15189 echo "${ECHO_T}$cf_cv_wint_t" >&6
15191 if test "$cf_cv_wint_t" = yes ; then
15193 cat >>confdefs.h <<\EOF
15194 #define NEED_WCHAR_H 1
15200 # if we do not find wint_t in either place, use substitution to provide a fallback.
15201 if test "$cf_cv_wint_t" = unknown ; then
15205 # if we find wint_t in either place, use substitution to provide a fallback.
15206 if test "$cf_cv_wint_t" != unknown ; then
15207 NCURSES_OK_WINT_T=1
15210 if test "$NCURSES_OK_MBSTATE_T" = 0 ; then
15212 echo "$as_me:15212: checking for type mbstate_t in ${cf_cv_ncurses_header:-curses.h}" >&5
15213 echo $ECHO_N "checking for type mbstate_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
15214 cat >conftest.$ac_ext <<_ACEOF
15215 #line 15215 "configure"
15216 #include "confdefs.h"
15218 #ifndef _XOPEN_SOURCE_EXTENDED
15219 #define _XOPEN_SOURCE_EXTENDED
15221 #include <${cf_cv_ncurses_header:-curses.h}>
15232 rm -f conftest.$ac_objext
15233 if { (eval echo "$as_me:15233: \"$ac_compile\"") >&5
15234 (eval $ac_compile) 2>&5
15236 echo "$as_me:15236: \$? = $ac_status" >&5
15237 (exit $ac_status); } &&
15238 { ac_try='test -s conftest.$ac_objext'
15239 { (eval echo "$as_me:15239: \"$ac_try\"") >&5
15240 (eval $ac_try) 2>&5
15242 echo "$as_me:15242: \$? = $ac_status" >&5
15243 (exit $ac_status); }; }; then
15246 echo "$as_me: failed program was:" >&5
15247 cat conftest.$ac_ext >&5
15250 rm -f conftest.$ac_objext conftest.$ac_ext
15251 echo "$as_me:15251: result: $cf_result" >&5
15252 echo "${ECHO_T}$cf_result" >&6
15253 if test $cf_result = yes ; then
15255 cf_result=`echo "have_type_mbstate_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
15257 cat >>confdefs.h <<EOF
15258 #define $cf_result 1
15263 cat >>confdefs.h <<EOF
15264 #define mbstate_t long
15271 if test "$NCURSES_OK_WCHAR_T" = 0 ; then
15273 echo "$as_me:15273: checking for type wchar_t in ${cf_cv_ncurses_header:-curses.h}" >&5
15274 echo $ECHO_N "checking for type wchar_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
15275 cat >conftest.$ac_ext <<_ACEOF
15276 #line 15276 "configure"
15277 #include "confdefs.h"
15279 #ifndef _XOPEN_SOURCE_EXTENDED
15280 #define _XOPEN_SOURCE_EXTENDED
15282 #include <${cf_cv_ncurses_header:-curses.h}>
15293 rm -f conftest.$ac_objext
15294 if { (eval echo "$as_me:15294: \"$ac_compile\"") >&5
15295 (eval $ac_compile) 2>&5
15297 echo "$as_me:15297: \$? = $ac_status" >&5
15298 (exit $ac_status); } &&
15299 { ac_try='test -s conftest.$ac_objext'
15300 { (eval echo "$as_me:15300: \"$ac_try\"") >&5
15301 (eval $ac_try) 2>&5
15303 echo "$as_me:15303: \$? = $ac_status" >&5
15304 (exit $ac_status); }; }; then
15307 echo "$as_me: failed program was:" >&5
15308 cat conftest.$ac_ext >&5
15311 rm -f conftest.$ac_objext conftest.$ac_ext
15312 echo "$as_me:15312: result: $cf_result" >&5
15313 echo "${ECHO_T}$cf_result" >&6
15314 if test $cf_result = yes ; then
15316 cf_result=`echo "have_type_wchar_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
15318 cat >>confdefs.h <<EOF
15319 #define $cf_result 1
15324 cat >>confdefs.h <<EOF
15325 #define wchar_t long
15332 if test "$NCURSES_OK_WINT_T" = 0 ; then
15334 echo "$as_me:15334: checking for type wint_t in ${cf_cv_ncurses_header:-curses.h}" >&5
15335 echo $ECHO_N "checking for type wint_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
15336 cat >conftest.$ac_ext <<_ACEOF
15337 #line 15337 "configure"
15338 #include "confdefs.h"
15340 #ifndef _XOPEN_SOURCE_EXTENDED
15341 #define _XOPEN_SOURCE_EXTENDED
15343 #include <${cf_cv_ncurses_header:-curses.h}>
15354 rm -f conftest.$ac_objext
15355 if { (eval echo "$as_me:15355: \"$ac_compile\"") >&5
15356 (eval $ac_compile) 2>&5
15358 echo "$as_me:15358: \$? = $ac_status" >&5
15359 (exit $ac_status); } &&
15360 { ac_try='test -s conftest.$ac_objext'
15361 { (eval echo "$as_me:15361: \"$ac_try\"") >&5
15362 (eval $ac_try) 2>&5
15364 echo "$as_me:15364: \$? = $ac_status" >&5
15365 (exit $ac_status); }; }; then
15368 echo "$as_me: failed program was:" >&5
15369 cat conftest.$ac_ext >&5
15372 rm -f conftest.$ac_objext conftest.$ac_ext
15373 echo "$as_me:15373: result: $cf_result" >&5
15374 echo "${ECHO_T}$cf_result" >&6
15375 if test $cf_result = yes ; then
15377 cf_result=`echo "have_type_wint_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
15379 cat >>confdefs.h <<EOF
15380 #define $cf_result 1
15385 cat >>confdefs.h <<EOF
15386 #define wint_t long
15394 echo "$as_me:15394: checking for data boolnames declaration in ${cf_cv_ncurses_header:-curses.h}" >&5
15395 echo $ECHO_N "checking for data boolnames declaration in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
15397 cat >conftest.$ac_ext <<_ACEOF
15398 #line 15398 "configure"
15399 #include "confdefs.h"
15401 #ifdef HAVE_XCURSES
15402 #include <xcurses.h>
15403 char * XCursesProgramName = "test";
15405 #include <${cf_cv_ncurses_header:-curses.h}>
15406 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
15407 #include <ncursesw/term.h>
15408 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
15409 #include <ncurses/term.h>
15410 #elif defined(HAVE_TERM_H)
15419 void *foo = &(boolnames)
15425 rm -f conftest.$ac_objext
15426 if { (eval echo "$as_me:15426: \"$ac_compile\"") >&5
15427 (eval $ac_compile) 2>&5
15429 echo "$as_me:15429: \$? = $ac_status" >&5
15430 (exit $ac_status); } &&
15431 { ac_try='test -s conftest.$ac_objext'
15432 { (eval echo "$as_me:15432: \"$ac_try\"") >&5
15433 (eval $ac_try) 2>&5
15435 echo "$as_me:15435: \$? = $ac_status" >&5
15436 (exit $ac_status); }; }; then
15439 echo "$as_me: failed program was:" >&5
15440 cat conftest.$ac_ext >&5
15443 rm -f conftest.$ac_objext conftest.$ac_ext
15444 echo "$as_me:15444: result: $cf_result" >&5
15445 echo "${ECHO_T}$cf_result" >&6
15447 if test $cf_result = yes ; then
15449 cf_result=`echo "have_curses_data_boolnames" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
15451 cat >>confdefs.h <<EOF
15452 #define $cf_result 1
15456 echo "$as_me:15456: checking for data boolnames in library" >&5
15457 echo $ECHO_N "checking for data boolnames in library... $ECHO_C" >&6
15458 # BSD linkers insist on making weak linkage, but resolve at runtime.
15459 if test "$cross_compiling" = yes; then
15462 cat >conftest.$ac_ext <<_ACEOF
15463 #line 15463 "configure"
15464 #include "confdefs.h"
15466 #ifdef HAVE_XCURSES
15467 #include <xcurses.h>
15468 char * XCursesProgramName = "test";
15470 #include <${cf_cv_ncurses_header:-curses.h}>
15471 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
15472 #include <ncursesw/term.h>
15473 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
15474 #include <ncurses/term.h>
15475 #elif defined(HAVE_TERM_H)
15480 extern char boolnames;
15486 void *foo = &(boolnames);
15487 fprintf(stderr, "testing linkage of boolnames:%p\n", foo);
15488 ${cf_cv_main_return:-return}(foo == 0);
15495 rm -f conftest.$ac_objext conftest$ac_exeext
15496 if { (eval echo "$as_me:15496: \"$ac_link\"") >&5
15497 (eval $ac_link) 2>&5
15499 echo "$as_me:15499: \$? = $ac_status" >&5
15500 (exit $ac_status); } &&
15501 { ac_try='test -s conftest$ac_exeext'
15502 { (eval echo "$as_me:15502: \"$ac_try\"") >&5
15503 (eval $ac_try) 2>&5
15505 echo "$as_me:15505: \$? = $ac_status" >&5
15506 (exit $ac_status); }; }; then
15509 echo "$as_me: failed program was:" >&5
15510 cat conftest.$ac_ext >&5
15513 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15516 cat >conftest.$ac_ext <<_ACEOF
15517 #line 15517 "configure"
15518 #include "confdefs.h"
15520 #ifdef HAVE_XCURSES
15521 #include <xcurses.h>
15522 char * XCursesProgramName = "test";
15524 #include <${cf_cv_ncurses_header:-curses.h}>
15525 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
15526 #include <ncursesw/term.h>
15527 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
15528 #include <ncurses/term.h>
15529 #elif defined(HAVE_TERM_H)
15534 extern char boolnames;
15537 void *foo = &(boolnames);
15538 fprintf(stderr, "testing linkage of boolnames:%p\n", foo);
15539 ${cf_cv_main_return:-return}(foo == 0);
15542 rm -f conftest$ac_exeext
15543 if { (eval echo "$as_me:15543: \"$ac_link\"") >&5
15544 (eval $ac_link) 2>&5
15546 echo "$as_me:15546: \$? = $ac_status" >&5
15547 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15548 { (eval echo "$as_me:15548: \"$ac_try\"") >&5
15549 (eval $ac_try) 2>&5
15551 echo "$as_me:15551: \$? = $ac_status" >&5
15552 (exit $ac_status); }; }; then
15555 echo "$as_me: program exited with status $ac_status" >&5
15556 echo "$as_me: failed program was:" >&5
15557 cat conftest.$ac_ext >&5
15560 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15562 echo "$as_me:15562: result: $cf_result" >&5
15563 echo "${ECHO_T}$cf_result" >&6
15564 if test $cf_result = yes ; then
15566 cf_result=`echo "decl_curses_data_boolnames" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
15568 cat >>confdefs.h <<EOF
15569 #define $cf_result 1
15575 echo "$as_me:15575: checking for data boolfnames declaration in ${cf_cv_ncurses_header:-curses.h}" >&5
15576 echo $ECHO_N "checking for data boolfnames declaration in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
15578 cat >conftest.$ac_ext <<_ACEOF
15579 #line 15579 "configure"
15580 #include "confdefs.h"
15582 #ifdef HAVE_XCURSES
15583 #include <xcurses.h>
15584 char * XCursesProgramName = "test";
15586 #include <${cf_cv_ncurses_header:-curses.h}>
15587 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
15588 #include <ncursesw/term.h>
15589 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
15590 #include <ncurses/term.h>
15591 #elif defined(HAVE_TERM_H)
15600 void *foo = &(boolfnames)
15606 rm -f conftest.$ac_objext
15607 if { (eval echo "$as_me:15607: \"$ac_compile\"") >&5
15608 (eval $ac_compile) 2>&5
15610 echo "$as_me:15610: \$? = $ac_status" >&5
15611 (exit $ac_status); } &&
15612 { ac_try='test -s conftest.$ac_objext'
15613 { (eval echo "$as_me:15613: \"$ac_try\"") >&5
15614 (eval $ac_try) 2>&5
15616 echo "$as_me:15616: \$? = $ac_status" >&5
15617 (exit $ac_status); }; }; then
15620 echo "$as_me: failed program was:" >&5
15621 cat conftest.$ac_ext >&5
15624 rm -f conftest.$ac_objext conftest.$ac_ext
15625 echo "$as_me:15625: result: $cf_result" >&5
15626 echo "${ECHO_T}$cf_result" >&6
15628 if test $cf_result = yes ; then
15630 cf_result=`echo "have_curses_data_boolfnames" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
15632 cat >>confdefs.h <<EOF
15633 #define $cf_result 1
15637 echo "$as_me:15637: checking for data boolfnames in library" >&5
15638 echo $ECHO_N "checking for data boolfnames in library... $ECHO_C" >&6
15639 # BSD linkers insist on making weak linkage, but resolve at runtime.
15640 if test "$cross_compiling" = yes; then
15643 cat >conftest.$ac_ext <<_ACEOF
15644 #line 15644 "configure"
15645 #include "confdefs.h"
15647 #ifdef HAVE_XCURSES
15648 #include <xcurses.h>
15649 char * XCursesProgramName = "test";
15651 #include <${cf_cv_ncurses_header:-curses.h}>
15652 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
15653 #include <ncursesw/term.h>
15654 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
15655 #include <ncurses/term.h>
15656 #elif defined(HAVE_TERM_H)
15661 extern char boolfnames;
15667 void *foo = &(boolfnames);
15668 fprintf(stderr, "testing linkage of boolfnames:%p\n", foo);
15669 ${cf_cv_main_return:-return}(foo == 0);
15676 rm -f conftest.$ac_objext conftest$ac_exeext
15677 if { (eval echo "$as_me:15677: \"$ac_link\"") >&5
15678 (eval $ac_link) 2>&5
15680 echo "$as_me:15680: \$? = $ac_status" >&5
15681 (exit $ac_status); } &&
15682 { ac_try='test -s conftest$ac_exeext'
15683 { (eval echo "$as_me:15683: \"$ac_try\"") >&5
15684 (eval $ac_try) 2>&5
15686 echo "$as_me:15686: \$? = $ac_status" >&5
15687 (exit $ac_status); }; }; then
15690 echo "$as_me: failed program was:" >&5
15691 cat conftest.$ac_ext >&5
15694 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15697 cat >conftest.$ac_ext <<_ACEOF
15698 #line 15698 "configure"
15699 #include "confdefs.h"
15701 #ifdef HAVE_XCURSES
15702 #include <xcurses.h>
15703 char * XCursesProgramName = "test";
15705 #include <${cf_cv_ncurses_header:-curses.h}>
15706 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
15707 #include <ncursesw/term.h>
15708 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
15709 #include <ncurses/term.h>
15710 #elif defined(HAVE_TERM_H)
15715 extern char boolfnames;
15718 void *foo = &(boolfnames);
15719 fprintf(stderr, "testing linkage of boolfnames:%p\n", foo);
15720 ${cf_cv_main_return:-return}(foo == 0);
15723 rm -f conftest$ac_exeext
15724 if { (eval echo "$as_me:15724: \"$ac_link\"") >&5
15725 (eval $ac_link) 2>&5
15727 echo "$as_me:15727: \$? = $ac_status" >&5
15728 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15729 { (eval echo "$as_me:15729: \"$ac_try\"") >&5
15730 (eval $ac_try) 2>&5
15732 echo "$as_me:15732: \$? = $ac_status" >&5
15733 (exit $ac_status); }; }; then
15736 echo "$as_me: program exited with status $ac_status" >&5
15737 echo "$as_me: failed program was:" >&5
15738 cat conftest.$ac_ext >&5
15741 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15743 echo "$as_me:15743: result: $cf_result" >&5
15744 echo "${ECHO_T}$cf_result" >&6
15745 if test $cf_result = yes ; then
15747 cf_result=`echo "decl_curses_data_boolfnames" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
15749 cat >>confdefs.h <<EOF
15750 #define $cf_result 1
15756 if ( test "$GCC" = yes || test "$GXX" = yes )
15758 echo "$as_me:15758: checking if you want to turn on gcc warnings" >&5
15759 echo $ECHO_N "checking if you want to turn on gcc warnings... $ECHO_C" >&6
15761 # Check whether --enable-warnings or --disable-warnings was given.
15762 if test "${enable_warnings+set}" = set; then
15763 enableval="$enable_warnings"
15764 test "$enableval" != yes && enableval=no
15765 if test "$enableval" != "no" ; then
15775 echo "$as_me:15775: result: $with_warnings" >&5
15776 echo "${ECHO_T}$with_warnings" >&6
15777 if test "$with_warnings" = "yes"
15780 if test "$GCC" = yes
15782 cat > conftest.i <<EOF
15784 #define GCC_PRINTF 0
15787 #define GCC_SCANF 0
15789 #ifndef GCC_NORETURN
15790 #define GCC_NORETURN /* nothing */
15793 #define GCC_UNUSED /* nothing */
15796 if test "$GCC" = yes
15798 { echo "$as_me:15798: checking for $CC __attribute__ directives..." >&5
15799 echo "$as_me: checking for $CC __attribute__ directives..." >&6;}
15800 cat > conftest.$ac_ext <<EOF
15801 #line 15801 "${as_me:-configure}"
15802 #include "confdefs.h"
15803 #include "conftest.h"
15804 #include "conftest.i"
15806 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
15808 #define GCC_PRINTFLIKE(fmt,var) /*nothing*/
15811 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
15813 #define GCC_SCANFLIKE(fmt,var) /*nothing*/
15815 extern void wow(char *,...) GCC_SCANFLIKE(1,2);
15816 extern void oops(char *,...) GCC_PRINTFLIKE(1,2) GCC_NORETURN;
15817 extern void foo(void) GCC_NORETURN;
15818 int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { return 0; }
15820 cf_printf_attribute=no
15821 cf_scanf_attribute=no
15822 for cf_attribute in scanf printf unused noreturn
15825 cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
15827 cf_directive="__attribute__(($cf_attribute))"
15828 echo "checking for $CC $cf_directive" 1>&5
15830 case $cf_attribute in #(vi
15832 cf_printf_attribute=yes
15833 cat >conftest.h <<EOF
15834 #define GCC_$cf_ATTRIBUTE 1
15838 cf_scanf_attribute=yes
15839 cat >conftest.h <<EOF
15840 #define GCC_$cf_ATTRIBUTE 1
15844 cat >conftest.h <<EOF
15845 #define GCC_$cf_ATTRIBUTE $cf_directive
15850 if { (eval echo "$as_me:15850: \"$ac_compile\"") >&5
15851 (eval $ac_compile) 2>&5
15853 echo "$as_me:15853: \$? = $ac_status" >&5
15854 (exit $ac_status); }; then
15855 test -n "$verbose" && echo "$as_me:15855: result: ... $cf_attribute" >&5
15856 echo "${ECHO_T}... $cf_attribute" >&6
15857 cat conftest.h >>confdefs.h
15858 case $cf_attribute in #(vi
15861 cat >>confdefs.h <<EOF
15862 #define GCC_NORETURN $cf_directive
15867 cf_value='/* nothing */'
15868 if test "$cf_printf_attribute" != no ; then
15869 cf_value='__attribute__((format(printf,fmt,var)))'
15871 cat >>confdefs.h <<\EOF
15872 #define GCC_PRINTF 1
15877 cat >>confdefs.h <<EOF
15878 #define GCC_PRINTFLIKE(fmt,var) $cf_value
15883 cf_value='/* nothing */'
15884 if test "$cf_scanf_attribute" != no ; then
15885 cf_value='__attribute__((format(scanf,fmt,var)))'
15887 cat >>confdefs.h <<\EOF
15888 #define GCC_SCANF 1
15893 cat >>confdefs.h <<EOF
15894 #define GCC_SCANFLIKE(fmt,var) $cf_value
15900 cat >>confdefs.h <<EOF
15901 #define GCC_UNUSED $cf_directive
15909 fgrep define conftest.i >>confdefs.h
15916 if test "$GCC" = yes ; then
15919 echo "$as_me:15919: checking if this is really Intel C compiler" >&5
15920 echo $ECHO_N "checking if this is really Intel C compiler... $ECHO_C" >&6
15921 cf_save_CFLAGS="$CFLAGS"
15922 CFLAGS="$CFLAGS -no-gcc"
15923 cat >conftest.$ac_ext <<_ACEOF
15924 #line 15924 "configure"
15925 #include "confdefs.h"
15931 #ifdef __INTEL_COMPILER
15940 rm -f conftest.$ac_objext
15941 if { (eval echo "$as_me:15941: \"$ac_compile\"") >&5
15942 (eval $ac_compile) 2>&5
15944 echo "$as_me:15944: \$? = $ac_status" >&5
15945 (exit $ac_status); } &&
15946 { ac_try='test -s conftest.$ac_objext'
15947 { (eval echo "$as_me:15947: \"$ac_try\"") >&5
15948 (eval $ac_try) 2>&5
15950 echo "$as_me:15950: \$? = $ac_status" >&5
15951 (exit $ac_status); }; }; then
15953 cf_save_CFLAGS="$cf_save_CFLAGS -we147"
15956 echo "$as_me: failed program was:" >&5
15957 cat conftest.$ac_ext >&5
15959 rm -f conftest.$ac_objext conftest.$ac_ext
15960 CFLAGS="$cf_save_CFLAGS"
15961 echo "$as_me:15961: result: $INTEL_COMPILER" >&5
15962 echo "${ECHO_T}$INTEL_COMPILER" >&6
15969 if test "$GCC" = yes ; then
15970 echo "$as_me:15970: checking if this is really Clang C compiler" >&5
15971 echo $ECHO_N "checking if this is really Clang C compiler... $ECHO_C" >&6
15972 cf_save_CFLAGS="$CFLAGS"
15973 CFLAGS="$CFLAGS -Qunused-arguments"
15974 cat >conftest.$ac_ext <<_ACEOF
15975 #line 15975 "configure"
15976 #include "confdefs.h"
15991 rm -f conftest.$ac_objext
15992 if { (eval echo "$as_me:15992: \"$ac_compile\"") >&5
15993 (eval $ac_compile) 2>&5
15995 echo "$as_me:15995: \$? = $ac_status" >&5
15996 (exit $ac_status); } &&
15997 { ac_try='test -s conftest.$ac_objext'
15998 { (eval echo "$as_me:15998: \"$ac_try\"") >&5
15999 (eval $ac_try) 2>&5
16001 echo "$as_me:16001: \$? = $ac_status" >&5
16002 (exit $ac_status); }; }; then
16004 cf_save_CFLAGS="$cf_save_CFLAGS -Qunused-arguments"
16007 echo "$as_me: failed program was:" >&5
16008 cat conftest.$ac_ext >&5
16010 rm -f conftest.$ac_objext conftest.$ac_ext
16011 CFLAGS="$cf_save_CFLAGS"
16012 echo "$as_me:16012: result: $CLANG_COMPILER" >&5
16013 echo "${ECHO_T}$CLANG_COMPILER" >&6
16016 cat > conftest.$ac_ext <<EOF
16017 #line 16017 "${as_me:-configure}"
16018 int main(int argc, char *argv[]) { return (argv[argc-1] == 0) ; }
16021 if test "$INTEL_COMPILER" = yes
16023 # The "-wdXXX" options suppress warnings:
16024 # remark #1419: external declaration in primary source file
16025 # remark #1683: explicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem)
16026 # remark #1684: conversion from pointer to same-sized integral type (potential portability problem)
16027 # remark #193: zero used for undefined preprocessing identifier
16028 # remark #593: variable "curs_sb_left_arrow" was set but never used
16029 # remark #810: conversion from "int" to "Dimension={unsigned short}" may lose significant bits
16030 # remark #869: parameter "tw" was never referenced
16031 # remark #981: operands are evaluated in unspecified order
16032 # warning #279: controlling expression is constant
16034 { echo "$as_me:16034: checking for $CC warning options..." >&5
16035 echo "$as_me: checking for $CC warning options..." >&6;}
16036 cf_save_CFLAGS="$CFLAGS"
16037 EXTRA_CFLAGS="-Wall"
16049 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
16050 if { (eval echo "$as_me:16050: \"$ac_compile\"") >&5
16051 (eval $ac_compile) 2>&5
16053 echo "$as_me:16053: \$? = $ac_status" >&5
16054 (exit $ac_status); }; then
16055 test -n "$verbose" && echo "$as_me:16055: result: ... -$cf_opt" >&5
16056 echo "${ECHO_T}... -$cf_opt" >&6
16057 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
16060 CFLAGS="$cf_save_CFLAGS"
16062 elif test "$GCC" = yes
16064 { echo "$as_me:16064: checking for $CC warning options..." >&5
16065 echo "$as_me: checking for $CC warning options..." >&6;}
16066 cf_save_CFLAGS="$CFLAGS"
16069 test "$with_ext_const" = yes && cf_warn_CONST="Wwrite-strings"
16070 cf_gcc_warnings="Wignored-qualifiers Wlogical-op Wvarargs"
16071 test "x$CLANG_COMPILER" = xyes && cf_gcc_warnings=
16072 for cf_opt in W Wall \
16073 Wbad-function-cast \
16076 Wdeclaration-after-statement \
16079 Wmissing-declarations \
16080 Wmissing-prototypes \
16084 Wstrict-prototypes \
16085 Wundef $cf_gcc_warnings $cf_warn_CONST
16087 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
16088 if { (eval echo "$as_me:16088: \"$ac_compile\"") >&5
16089 (eval $ac_compile) 2>&5
16091 echo "$as_me:16091: \$? = $ac_status" >&5
16092 (exit $ac_status); }; then
16093 test -n "$verbose" && echo "$as_me:16093: result: ... -$cf_opt" >&5
16094 echo "${ECHO_T}... -$cf_opt" >&6
16095 case $cf_opt in #(vi
16097 CPPFLAGS="$CPPFLAGS -DXTSTRINGDEFINES"
16100 case $GCC_VERSION in
16102 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
16104 echo "${as_me:-configure}:16104: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
16109 Wpointer-arith) #(vi
16110 case $GCC_VERSION in
16112 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
16114 echo "${as_me:-configure}:16114: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
16120 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
16123 CFLAGS="$cf_save_CFLAGS"
16130 echo "$as_me:16130: checking if you want to use dmalloc for testing" >&5
16131 echo $ECHO_N "checking if you want to use dmalloc for testing... $ECHO_C" >&6
16133 # Check whether --with-dmalloc or --without-dmalloc was given.
16134 if test "${with_dmalloc+set}" = set; then
16135 withval="$with_dmalloc"
16137 cat >>confdefs.h <<EOF
16138 #define USE_DMALLOC 1
16141 : ${with_cflags:=-g}
16142 : ${with_no_leaks:=yes}
16147 echo "$as_me:16147: result: ${with_dmalloc:-no}" >&5
16148 echo "${ECHO_T}${with_dmalloc:-no}" >&6
16150 case .$with_cflags in #(vi
16152 case .$CFLAGS in #(vi
16160 cf_new_extra_cppflags=
16162 for cf_add_cflags in -g
16164 case $cf_fix_cppflags in
16166 case $cf_add_cflags in #(vi
16167 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
16168 case $cf_add_cflags in
16170 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
16172 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
16173 && test -z "${cf_tst_cflags}" \
16174 && cf_fix_cppflags=yes
16176 if test $cf_fix_cppflags = yes ; then
16177 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
16179 elif test "${cf_tst_cflags}" = "\"'" ; then
16180 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
16185 case "$CPPFLAGS" in
16186 *$cf_add_cflags) #(vi
16189 case $cf_add_cflags in #(vi
16191 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
16193 CPPFLAGS=`echo "$CPPFLAGS" | \
16194 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
16195 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
16199 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
16204 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
16209 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
16211 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
16213 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
16214 && test -z "${cf_tst_cflags}" \
16215 && cf_fix_cppflags=no
16220 if test -n "$cf_new_cflags" ; then
16222 CFLAGS="$CFLAGS $cf_new_cflags"
16225 if test -n "$cf_new_cppflags" ; then
16227 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
16230 if test -n "$cf_new_extra_cppflags" ; then
16232 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
16240 if test "$with_dmalloc" = yes ; then
16241 echo "$as_me:16241: checking for dmalloc.h" >&5
16242 echo $ECHO_N "checking for dmalloc.h... $ECHO_C" >&6
16243 if test "${ac_cv_header_dmalloc_h+set}" = set; then
16244 echo $ECHO_N "(cached) $ECHO_C" >&6
16246 cat >conftest.$ac_ext <<_ACEOF
16247 #line 16247 "configure"
16248 #include "confdefs.h"
16249 #include <dmalloc.h>
16251 if { (eval echo "$as_me:16251: \"$ac_cpp conftest.$ac_ext\"") >&5
16252 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
16254 egrep -v '^ *\+' conftest.er1 >conftest.err
16256 cat conftest.err >&5
16257 echo "$as_me:16257: \$? = $ac_status" >&5
16258 (exit $ac_status); } >/dev/null; then
16259 if test -s conftest.err; then
16260 ac_cpp_err=$ac_c_preproc_warn_flag
16267 if test -z "$ac_cpp_err"; then
16268 ac_cv_header_dmalloc_h=yes
16270 echo "$as_me: failed program was:" >&5
16271 cat conftest.$ac_ext >&5
16272 ac_cv_header_dmalloc_h=no
16274 rm -f conftest.err conftest.$ac_ext
16276 echo "$as_me:16276: result: $ac_cv_header_dmalloc_h" >&5
16277 echo "${ECHO_T}$ac_cv_header_dmalloc_h" >&6
16278 if test $ac_cv_header_dmalloc_h = yes; then
16280 echo "$as_me:16280: checking for dmalloc_debug in -ldmalloc" >&5
16281 echo $ECHO_N "checking for dmalloc_debug in -ldmalloc... $ECHO_C" >&6
16282 if test "${ac_cv_lib_dmalloc_dmalloc_debug+set}" = set; then
16283 echo $ECHO_N "(cached) $ECHO_C" >&6
16285 ac_check_lib_save_LIBS=$LIBS
16286 LIBS="-ldmalloc $LIBS"
16287 cat >conftest.$ac_ext <<_ACEOF
16288 #line 16288 "configure"
16289 #include "confdefs.h"
16291 /* Override any gcc2 internal prototype to avoid an error. */
16295 /* We use char because int might match the return type of a gcc2
16296 builtin and then its argument prototype would still apply. */
16297 char dmalloc_debug ();
16306 rm -f conftest.$ac_objext conftest$ac_exeext
16307 if { (eval echo "$as_me:16307: \"$ac_link\"") >&5
16308 (eval $ac_link) 2>&5
16310 echo "$as_me:16310: \$? = $ac_status" >&5
16311 (exit $ac_status); } &&
16312 { ac_try='test -s conftest$ac_exeext'
16313 { (eval echo "$as_me:16313: \"$ac_try\"") >&5
16314 (eval $ac_try) 2>&5
16316 echo "$as_me:16316: \$? = $ac_status" >&5
16317 (exit $ac_status); }; }; then
16318 ac_cv_lib_dmalloc_dmalloc_debug=yes
16320 echo "$as_me: failed program was:" >&5
16321 cat conftest.$ac_ext >&5
16322 ac_cv_lib_dmalloc_dmalloc_debug=no
16324 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16325 LIBS=$ac_check_lib_save_LIBS
16327 echo "$as_me:16327: result: $ac_cv_lib_dmalloc_dmalloc_debug" >&5
16328 echo "${ECHO_T}$ac_cv_lib_dmalloc_dmalloc_debug" >&6
16329 if test $ac_cv_lib_dmalloc_dmalloc_debug = yes; then
16330 cat >>confdefs.h <<EOF
16331 #define HAVE_LIBDMALLOC 1
16334 LIBS="-ldmalloc $LIBS"
16342 echo "$as_me:16342: checking if you want to use dbmalloc for testing" >&5
16343 echo $ECHO_N "checking if you want to use dbmalloc for testing... $ECHO_C" >&6
16345 # Check whether --with-dbmalloc or --without-dbmalloc was given.
16346 if test "${with_dbmalloc+set}" = set; then
16347 withval="$with_dbmalloc"
16349 cat >>confdefs.h <<EOF
16350 #define USE_DBMALLOC 1
16353 : ${with_cflags:=-g}
16354 : ${with_no_leaks:=yes}
16359 echo "$as_me:16359: result: ${with_dbmalloc:-no}" >&5
16360 echo "${ECHO_T}${with_dbmalloc:-no}" >&6
16362 case .$with_cflags in #(vi
16364 case .$CFLAGS in #(vi
16372 cf_new_extra_cppflags=
16374 for cf_add_cflags in -g
16376 case $cf_fix_cppflags in
16378 case $cf_add_cflags in #(vi
16379 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
16380 case $cf_add_cflags in
16382 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
16384 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
16385 && test -z "${cf_tst_cflags}" \
16386 && cf_fix_cppflags=yes
16388 if test $cf_fix_cppflags = yes ; then
16389 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
16391 elif test "${cf_tst_cflags}" = "\"'" ; then
16392 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
16397 case "$CPPFLAGS" in
16398 *$cf_add_cflags) #(vi
16401 case $cf_add_cflags in #(vi
16403 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
16405 CPPFLAGS=`echo "$CPPFLAGS" | \
16406 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
16407 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
16411 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
16416 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
16421 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
16423 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
16425 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
16426 && test -z "${cf_tst_cflags}" \
16427 && cf_fix_cppflags=no
16432 if test -n "$cf_new_cflags" ; then
16434 CFLAGS="$CFLAGS $cf_new_cflags"
16437 if test -n "$cf_new_cppflags" ; then
16439 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
16442 if test -n "$cf_new_extra_cppflags" ; then
16444 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
16452 if test "$with_dbmalloc" = yes ; then
16453 echo "$as_me:16453: checking for dbmalloc.h" >&5
16454 echo $ECHO_N "checking for dbmalloc.h... $ECHO_C" >&6
16455 if test "${ac_cv_header_dbmalloc_h+set}" = set; then
16456 echo $ECHO_N "(cached) $ECHO_C" >&6
16458 cat >conftest.$ac_ext <<_ACEOF
16459 #line 16459 "configure"
16460 #include "confdefs.h"
16461 #include <dbmalloc.h>
16463 if { (eval echo "$as_me:16463: \"$ac_cpp conftest.$ac_ext\"") >&5
16464 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
16466 egrep -v '^ *\+' conftest.er1 >conftest.err
16468 cat conftest.err >&5
16469 echo "$as_me:16469: \$? = $ac_status" >&5
16470 (exit $ac_status); } >/dev/null; then
16471 if test -s conftest.err; then
16472 ac_cpp_err=$ac_c_preproc_warn_flag
16479 if test -z "$ac_cpp_err"; then
16480 ac_cv_header_dbmalloc_h=yes
16482 echo "$as_me: failed program was:" >&5
16483 cat conftest.$ac_ext >&5
16484 ac_cv_header_dbmalloc_h=no
16486 rm -f conftest.err conftest.$ac_ext
16488 echo "$as_me:16488: result: $ac_cv_header_dbmalloc_h" >&5
16489 echo "${ECHO_T}$ac_cv_header_dbmalloc_h" >&6
16490 if test $ac_cv_header_dbmalloc_h = yes; then
16492 echo "$as_me:16492: checking for debug_malloc in -ldbmalloc" >&5
16493 echo $ECHO_N "checking for debug_malloc in -ldbmalloc... $ECHO_C" >&6
16494 if test "${ac_cv_lib_dbmalloc_debug_malloc+set}" = set; then
16495 echo $ECHO_N "(cached) $ECHO_C" >&6
16497 ac_check_lib_save_LIBS=$LIBS
16498 LIBS="-ldbmalloc $LIBS"
16499 cat >conftest.$ac_ext <<_ACEOF
16500 #line 16500 "configure"
16501 #include "confdefs.h"
16503 /* Override any gcc2 internal prototype to avoid an error. */
16507 /* We use char because int might match the return type of a gcc2
16508 builtin and then its argument prototype would still apply. */
16509 char debug_malloc ();
16518 rm -f conftest.$ac_objext conftest$ac_exeext
16519 if { (eval echo "$as_me:16519: \"$ac_link\"") >&5
16520 (eval $ac_link) 2>&5
16522 echo "$as_me:16522: \$? = $ac_status" >&5
16523 (exit $ac_status); } &&
16524 { ac_try='test -s conftest$ac_exeext'
16525 { (eval echo "$as_me:16525: \"$ac_try\"") >&5
16526 (eval $ac_try) 2>&5
16528 echo "$as_me:16528: \$? = $ac_status" >&5
16529 (exit $ac_status); }; }; then
16530 ac_cv_lib_dbmalloc_debug_malloc=yes
16532 echo "$as_me: failed program was:" >&5
16533 cat conftest.$ac_ext >&5
16534 ac_cv_lib_dbmalloc_debug_malloc=no
16536 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16537 LIBS=$ac_check_lib_save_LIBS
16539 echo "$as_me:16539: result: $ac_cv_lib_dbmalloc_debug_malloc" >&5
16540 echo "${ECHO_T}$ac_cv_lib_dbmalloc_debug_malloc" >&6
16541 if test $ac_cv_lib_dbmalloc_debug_malloc = yes; then
16542 cat >>confdefs.h <<EOF
16543 #define HAVE_LIBDBMALLOC 1
16546 LIBS="-ldbmalloc $LIBS"
16554 echo "$as_me:16554: checking if you want to use valgrind for testing" >&5
16555 echo $ECHO_N "checking if you want to use valgrind for testing... $ECHO_C" >&6
16557 # Check whether --with-valgrind or --without-valgrind was given.
16558 if test "${with_valgrind+set}" = set; then
16559 withval="$with_valgrind"
16561 cat >>confdefs.h <<EOF
16562 #define USE_VALGRIND 1
16565 : ${with_cflags:=-g}
16566 : ${with_no_leaks:=yes}
16571 echo "$as_me:16571: result: ${with_valgrind:-no}" >&5
16572 echo "${ECHO_T}${with_valgrind:-no}" >&6
16574 case .$with_cflags in #(vi
16576 case .$CFLAGS in #(vi
16584 cf_new_extra_cppflags=
16586 for cf_add_cflags in -g
16588 case $cf_fix_cppflags in
16590 case $cf_add_cflags in #(vi
16591 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
16592 case $cf_add_cflags in
16594 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
16596 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
16597 && test -z "${cf_tst_cflags}" \
16598 && cf_fix_cppflags=yes
16600 if test $cf_fix_cppflags = yes ; then
16601 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
16603 elif test "${cf_tst_cflags}" = "\"'" ; then
16604 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
16609 case "$CPPFLAGS" in
16610 *$cf_add_cflags) #(vi
16613 case $cf_add_cflags in #(vi
16615 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
16617 CPPFLAGS=`echo "$CPPFLAGS" | \
16618 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
16619 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
16623 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
16628 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
16633 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
16635 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
16637 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
16638 && test -z "${cf_tst_cflags}" \
16639 && cf_fix_cppflags=no
16644 if test -n "$cf_new_cflags" ; then
16646 CFLAGS="$CFLAGS $cf_new_cflags"
16649 if test -n "$cf_new_cppflags" ; then
16651 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
16654 if test -n "$cf_new_extra_cppflags" ; then
16656 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
16664 echo "$as_me:16664: checking if you want to perform memory-leak testing" >&5
16665 echo $ECHO_N "checking if you want to perform memory-leak testing... $ECHO_C" >&6
16667 # Check whether --enable-leaks or --disable-leaks was given.
16668 if test "${enable_leaks+set}" = set; then
16669 enableval="$enable_leaks"
16670 if test "x$enableval" = xno; then with_no_leaks=yes; else with_no_leaks=no; fi
16672 : ${with_no_leaks:=no}
16674 echo "$as_me:16674: result: $with_no_leaks" >&5
16675 echo "${ECHO_T}$with_no_leaks" >&6
16677 if test "$with_no_leaks" = yes ; then
16679 cat >>confdefs.h <<\EOF
16683 cat >>confdefs.h <<\EOF
16684 #define YY_NO_LEAKS 1
16690 echo "$as_me:16690: checking for an rpath option" >&5
16691 echo $ECHO_N "checking for an rpath option... $ECHO_C" >&6
16692 case $cf_cv_system_name in #(vi
16694 if test "$GCC" = yes; then
16695 LD_RPATH_OPT="-Wl,-rpath,"
16697 LD_RPATH_OPT="-rpath "
16700 linux*|gnu*|k*bsd*-gnu) #(vi
16701 LD_RPATH_OPT="-Wl,-rpath,"
16703 openbsd[2-9].*|mirbsd*) #(vi
16704 LD_RPATH_OPT="-Wl,-rpath,"
16706 dragonfly*|freebsd*) #(vi
16707 LD_RPATH_OPT="-rpath "
16710 LD_RPATH_OPT="-Wl,-rpath,"
16713 LD_RPATH_OPT="-rpath "
16721 echo "$as_me:16721: result: $LD_RPATH_OPT" >&5
16722 echo "${ECHO_T}$LD_RPATH_OPT" >&6
16724 case "x$LD_RPATH_OPT" in #(vi
16726 echo "$as_me:16726: checking if we need a space after rpath option" >&5
16727 echo $ECHO_N "checking if we need a space after rpath option... $ECHO_C" >&6
16728 cf_save_LIBS="$LIBS"
16730 cf_add_libs="${LD_RPATH_OPT}$libdir"
16731 # Filter out duplicates - this happens with badly-designed ".pc" files...
16732 for cf_add_1lib in $LIBS
16734 for cf_add_2lib in $cf_add_libs
16736 if test "x$cf_add_1lib" = "x$cf_add_2lib"
16742 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
16744 LIBS="$cf_add_libs"
16746 cat >conftest.$ac_ext <<_ACEOF
16747 #line 16747 "configure"
16748 #include "confdefs.h"
16758 rm -f conftest.$ac_objext conftest$ac_exeext
16759 if { (eval echo "$as_me:16759: \"$ac_link\"") >&5
16760 (eval $ac_link) 2>&5
16762 echo "$as_me:16762: \$? = $ac_status" >&5
16763 (exit $ac_status); } &&
16764 { ac_try='test -s conftest$ac_exeext'
16765 { (eval echo "$as_me:16765: \"$ac_try\"") >&5
16766 (eval $ac_try) 2>&5
16768 echo "$as_me:16768: \$? = $ac_status" >&5
16769 (exit $ac_status); }; }; then
16772 echo "$as_me: failed program was:" >&5
16773 cat conftest.$ac_ext >&5
16776 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16777 LIBS="$cf_save_LIBS"
16778 echo "$as_me:16778: result: $cf_rpath_space" >&5
16779 echo "${ECHO_T}$cf_rpath_space" >&6
16780 test "$cf_rpath_space" = yes && LD_RPATH_OPT="$LD_RPATH_OPT "
16784 echo "$as_me:16784: checking if rpath-hack should be disabled" >&5
16785 echo $ECHO_N "checking if rpath-hack should be disabled... $ECHO_C" >&6
16787 # Check whether --enable-rpath-hack or --disable-rpath-hack was given.
16788 if test "${enable_rpath_hack+set}" = set; then
16789 enableval="$enable_rpath_hack"
16790 test "$enableval" != no && enableval=yes
16791 if test "$enableval" != "yes" ; then
16792 cf_disable_rpath_hack=yes
16794 cf_disable_rpath_hack=no
16798 cf_disable_rpath_hack=no
16801 echo "$as_me:16801: result: $cf_disable_rpath_hack" >&5
16802 echo "${ECHO_T}$cf_disable_rpath_hack" >&6
16803 if test "$cf_disable_rpath_hack" = no ; then
16805 echo "$as_me:16805: checking for updated LDFLAGS" >&5
16806 echo $ECHO_N "checking for updated LDFLAGS... $ECHO_C" >&6
16807 if test -n "$LD_RPATH_OPT" ; then
16808 echo "$as_me:16808: result: maybe" >&5
16809 echo "${ECHO_T}maybe" >&6
16813 # Extract the first word of "$ac_prog", so it can be a program name with args.
16814 set dummy $ac_prog; ac_word=$2
16815 echo "$as_me:16815: checking for $ac_word" >&5
16816 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
16817 if test "${ac_cv_prog_cf_ldd_prog+set}" = set; then
16818 echo $ECHO_N "(cached) $ECHO_C" >&6
16820 if test -n "$cf_ldd_prog"; then
16821 ac_cv_prog_cf_ldd_prog="$cf_ldd_prog" # Let the user override the test.
16823 ac_save_IFS=$IFS; IFS=$ac_path_separator
16825 for ac_dir in $ac_dummy; do
16827 test -z "$ac_dir" && ac_dir=.
16828 $as_executable_p "$ac_dir/$ac_word" || continue
16829 ac_cv_prog_cf_ldd_prog="$ac_prog"
16830 echo "$as_me:16830: found $ac_dir/$ac_word" >&5
16836 cf_ldd_prog=$ac_cv_prog_cf_ldd_prog
16837 if test -n "$cf_ldd_prog"; then
16838 echo "$as_me:16838: result: $cf_ldd_prog" >&5
16839 echo "${ECHO_T}$cf_ldd_prog" >&6
16841 echo "$as_me:16841: result: no" >&5
16842 echo "${ECHO_T}no" >&6
16845 test -n "$cf_ldd_prog" && break
16847 test -n "$cf_ldd_prog" || cf_ldd_prog="no"
16849 cf_rpath_list="/usr/lib /lib"
16850 if test "$cf_ldd_prog" != no
16854 cat >conftest.$ac_ext <<_ACEOF
16855 #line 16855 "configure"
16856 #include "confdefs.h"
16866 rm -f conftest.$ac_objext conftest$ac_exeext
16867 if { (eval echo "$as_me:16867: \"$ac_link\"") >&5
16868 (eval $ac_link) 2>&5
16870 echo "$as_me:16870: \$? = $ac_status" >&5
16871 (exit $ac_status); } &&
16872 { ac_try='test -s conftest$ac_exeext'
16873 { (eval echo "$as_me:16873: \"$ac_try\"") >&5
16874 (eval $ac_try) 2>&5
16876 echo "$as_me:16876: \$? = $ac_status" >&5
16877 (exit $ac_status); }; }; then
16878 cf_rpath_oops=`$cf_ldd_prog conftest$ac_exeext | fgrep ' not found' | sed -e 's% =>.*$%%' |sort | uniq`
16879 cf_rpath_list=`$cf_ldd_prog conftest$ac_exeext | fgrep / | sed -e 's%^.*[ ]/%/%' -e 's%/[^/][^/]*$%%' |sort | uniq`
16881 echo "$as_me: failed program was:" >&5
16882 cat conftest.$ac_ext >&5
16884 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16886 # If we passed the link-test, but get a "not found" on a given library,
16887 # this could be due to inept reconfiguration of gcc to make it only
16888 # partly honor /usr/local/lib (or whatever). Sometimes this behavior
16889 # is intentional, e.g., installing gcc in /usr/bin and suppressing the
16890 # /usr/local libraries.
16891 if test -n "$cf_rpath_oops"
16893 for cf_rpath_src in $cf_rpath_oops
16895 for cf_rpath_dir in \
16900 if test -f $cf_rpath_dir/lib/$cf_rpath_src
16902 test -n "$verbose" && echo " ...adding -L$cf_rpath_dir/lib to LDFLAGS for $cf_rpath_src" 1>&6
16904 echo "${as_me:-configure}:16904: testing ...adding -L$cf_rpath_dir/lib to LDFLAGS for $cf_rpath_src ..." 1>&5
16906 LDFLAGS="$LDFLAGS -L$cf_rpath_dir/lib"
16914 test -n "$verbose" && echo " ...checking EXTRA_LDFLAGS $EXTRA_LDFLAGS" 1>&6
16916 echo "${as_me:-configure}:16916: testing ...checking EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5
16918 test -n "$verbose" && echo " ...checking LDFLAGS $LDFLAGS" 1>&6
16920 echo "${as_me:-configure}:16920: testing ...checking LDFLAGS $LDFLAGS ..." 1>&5
16923 for cf_rpath_src in $LDFLAGS
16925 case $cf_rpath_src in #(vi
16928 # check if this refers to a directory which we will ignore
16930 if test -n "$cf_rpath_list"
16932 for cf_rpath_item in $cf_rpath_list
16934 if test "x$cf_rpath_src" = "x-L$cf_rpath_item"
16942 if test "$cf_rpath_skip" = no
16944 # transform the option
16945 if test "$LD_RPATH_OPT" = "-R " ; then
16946 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%-R %"`
16948 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%$LD_RPATH_OPT%"`
16951 # if we have not already added this, add it now
16952 cf_rpath_tst=`echo "$EXTRA_LDFLAGS" | sed -e "s%$cf_rpath_tmp %%"`
16953 if test "x$cf_rpath_tst" = "x$EXTRA_LDFLAGS"
16955 test -n "$verbose" && echo " ...Filter $cf_rpath_src ->$cf_rpath_tmp" 1>&6
16957 echo "${as_me:-configure}:16957: testing ...Filter $cf_rpath_src ->$cf_rpath_tmp ..." 1>&5
16959 EXTRA_LDFLAGS="$cf_rpath_tmp $EXTRA_LDFLAGS"
16964 cf_rpath_dst="$cf_rpath_dst $cf_rpath_src"
16966 LDFLAGS=$cf_rpath_dst
16968 test -n "$verbose" && echo " ...checked LDFLAGS $LDFLAGS" 1>&6
16970 echo "${as_me:-configure}:16970: testing ...checked LDFLAGS $LDFLAGS ..." 1>&5
16972 test -n "$verbose" && echo " ...checking LIBS $LIBS" 1>&6
16974 echo "${as_me:-configure}:16974: testing ...checking LIBS $LIBS ..." 1>&5
16977 for cf_rpath_src in $LIBS
16979 case $cf_rpath_src in #(vi
16982 # check if this refers to a directory which we will ignore
16984 if test -n "$cf_rpath_list"
16986 for cf_rpath_item in $cf_rpath_list
16988 if test "x$cf_rpath_src" = "x-L$cf_rpath_item"
16996 if test "$cf_rpath_skip" = no
16998 # transform the option
16999 if test "$LD_RPATH_OPT" = "-R " ; then
17000 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%-R %"`
17002 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%$LD_RPATH_OPT%"`
17005 # if we have not already added this, add it now
17006 cf_rpath_tst=`echo "$EXTRA_LDFLAGS" | sed -e "s%$cf_rpath_tmp %%"`
17007 if test "x$cf_rpath_tst" = "x$EXTRA_LDFLAGS"
17009 test -n "$verbose" && echo " ...Filter $cf_rpath_src ->$cf_rpath_tmp" 1>&6
17011 echo "${as_me:-configure}:17011: testing ...Filter $cf_rpath_src ->$cf_rpath_tmp ..." 1>&5
17013 EXTRA_LDFLAGS="$cf_rpath_tmp $EXTRA_LDFLAGS"
17018 cf_rpath_dst="$cf_rpath_dst $cf_rpath_src"
17022 test -n "$verbose" && echo " ...checked LIBS $LIBS" 1>&6
17024 echo "${as_me:-configure}:17024: testing ...checked LIBS $LIBS ..." 1>&5
17026 test -n "$verbose" && echo " ...checked EXTRA_LDFLAGS $EXTRA_LDFLAGS" 1>&6
17028 echo "${as_me:-configure}:17028: testing ...checked EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5
17031 echo "$as_me:17031: result: no" >&5
17032 echo "${ECHO_T}no" >&6
17040 ac_config_files="$ac_config_files Makefile"
17041 ac_config_commands="$ac_config_commands default"
17042 cat >confcache <<\_ACEOF
17043 # This file is a shell script that caches the results of configure
17044 # tests run on this system so they can be shared between configure
17045 # scripts and configure runs, see configure's option --config-cache.
17046 # It is not useful on other systems. If it contains results you don't
17047 # want to keep, you may remove or edit it.
17049 # config.status only pays attention to the cache file if you give it
17050 # the --recheck option to rerun configure.
17052 # `ac_cv_env_foo' variables (set or unset) will be overriden when
17053 # loading this file, other *unset* `ac_cv_foo' will be assigned the
17054 # following values.
17058 # The following way of writing the cache mishandles newlines in values,
17059 # but we know of no workaround that is simple, portable, and efficient.
17060 # So, don't put newlines in cache variables' values.
17061 # Ultrix sh set writes to stderr and can't be redirected directly,
17062 # and sets the high bit in the cache file unless we assign to the vars.
17065 case `(ac_space=' '; set | grep ac_space) 2>&1` in
17067 # `set' does not quote correctly, so add quotes (double-quote
17068 # substitution turns \\\\ into \\, and sed turns \\ into \).
17071 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
17074 # `set' quotes correctly as required by POSIX, so do not add quotes.
17076 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
17083 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
17085 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
17087 if cmp -s $cache_file confcache; then :; else
17088 if test -w $cache_file; then
17089 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
17090 cat confcache >$cache_file
17092 echo "not updating unwritable cache $cache_file"
17097 test "x$prefix" = xNONE && prefix=$ac_default_prefix
17098 # Let make expand exec_prefix.
17099 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
17101 # VPATH may cause trouble with some makes, so we remove $(srcdir),
17102 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
17103 # trailing colons and then remove the whole line if VPATH becomes empty
17104 # (actually we leave an empty line to preserve line numbers).
17105 if test "x$srcdir" = x.; then
17106 ac_vpsub='/^[ ]*VPATH[ ]*=/{
17107 s/:*\$(srcdir):*/:/;
17108 s/:*\${srcdir}:*/:/;
17110 s/^\([^=]*=[ ]*\):*/\1/;
17116 DEFS=-DHAVE_CONFIG_H
17118 : ${CONFIG_STATUS=./config.status}
17119 ac_clean_files_save=$ac_clean_files
17120 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
17121 { echo "$as_me:17121: creating $CONFIG_STATUS" >&5
17122 echo "$as_me: creating $CONFIG_STATUS" >&6;}
17123 cat >$CONFIG_STATUS <<_ACEOF
17125 # Generated automatically by configure.
17126 # Run this file to recreate the current configuration.
17127 # Compiler output produced by configure, useful for debugging
17128 # configure, is in config.log if it exists.
17131 SHELL=\${CONFIG_SHELL-$SHELL}
17132 ac_cs_invocation="\$0 \$@"
17136 cat >>$CONFIG_STATUS <<\_ACEOF
17137 # Be Bourne compatible
17138 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
17141 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
17145 # Name of the executable.
17146 as_me=`echo "$0" |sed 's,.*[\\/],,'`
17148 if expr a : '\(a\)' >/dev/null 2>&1; then
17154 rm -f conf$$ conf$$.exe conf$$.file
17156 if ln -s conf$$.file conf$$ 2>/dev/null; then
17157 # We could just check for DJGPP; but this test a) works b) is more generic
17158 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
17159 if test -f conf$$.exe; then
17160 # Don't use ln at all; we don't have any links
17165 elif ln conf$$.file conf$$ 2>/dev/null; then
17170 rm -f conf$$ conf$$.exe conf$$.file
17172 as_executable_p="test -f"
17174 # Support unset when possible.
17175 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
17182 $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
17183 $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
17184 $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
17185 $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
17186 $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
17187 $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
17188 $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
17189 $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
17192 # We need space, tab and new line, in precisely that order.
17198 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
17204 # Files that config.status was made for.
17205 if test -n "$ac_config_files"; then
17206 echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
17209 if test -n "$ac_config_headers"; then
17210 echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
17213 if test -n "$ac_config_links"; then
17214 echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
17217 if test -n "$ac_config_commands"; then
17218 echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
17221 cat >>$CONFIG_STATUS <<\EOF
17224 \`$as_me' instantiates files from templates according to the
17225 current configuration.
17227 Usage: $0 [OPTIONS] [FILE]...
17229 -h, --help print this help, then exit
17230 -V, --version print version number, then exit
17231 -d, --debug don't remove temporary files
17232 --recheck update $as_me by reconfiguring in the same conditions
17233 --file=FILE[:TEMPLATE]
17234 instantiate the configuration file FILE
17235 --header=FILE[:TEMPLATE]
17236 instantiate the configuration header FILE
17238 Configuration files:
17241 Configuration headers:
17244 Configuration commands:
17247 Report bugs to <dickey@invisible-island.net>."
17250 cat >>$CONFIG_STATUS <<EOF
17253 configured by $0, generated by GNU Autoconf 2.52.20121002,
17254 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
17256 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
17257 Free Software Foundation, Inc.
17258 This config.status script is free software; the Free Software Foundation
17259 gives unlimited permission to copy, distribute and modify it."
17264 cat >>$CONFIG_STATUS <<\EOF
17265 # If no file are specified by the user, then we need to provide default
17266 # value. By we need to know if files were specified by the user.
17272 ac_option=`expr "x$1" : 'x\([^=]*\)='`
17273 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
17275 set dummy "$ac_option" "$ac_optarg" ${1+"$@"}
17279 *) # This is not an option, so the user has probably given explicit
17281 ac_need_defaults=false;;
17285 # Handling of the options.
17287 cat >>$CONFIG_STATUS <<EOF
17288 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
17289 echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion"
17290 exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;;
17292 cat >>$CONFIG_STATUS <<\EOF
17293 --version | --vers* | -V )
17294 echo "$ac_cs_version"; exit 0 ;;
17296 # Conflict between --help and --header
17297 { { echo "$as_me:17297: error: ambiguous option: $1
17298 Try \`$0 --help' for more information." >&5
17299 echo "$as_me: error: ambiguous option: $1
17300 Try \`$0 --help' for more information." >&2;}
17301 { (exit 1); exit 1; }; };;
17302 --help | --hel | -h )
17303 echo "$ac_cs_usage"; exit 0 ;;
17304 --debug | --d* | -d )
17306 --file | --fil | --fi | --f )
17308 CONFIG_FILES="$CONFIG_FILES $1"
17309 ac_need_defaults=false;;
17310 --header | --heade | --head | --hea )
17312 CONFIG_HEADERS="$CONFIG_HEADERS $1"
17313 ac_need_defaults=false;;
17315 # This is an error.
17316 -*) { { echo "$as_me:17316: error: unrecognized option: $1
17317 Try \`$0 --help' for more information." >&5
17318 echo "$as_me: error: unrecognized option: $1
17319 Try \`$0 --help' for more information." >&2;}
17320 { (exit 1); exit 1; }; } ;;
17322 *) ac_config_targets="$ac_config_targets $1" ;;
17331 ## ----------------------- ##
17332 ## Running config.status. ##
17333 ## ----------------------- ##
17335 This file was extended by $as_me 2.52.20121002, executed with
17336 CONFIG_FILES = $CONFIG_FILES
17337 CONFIG_HEADERS = $CONFIG_HEADERS
17338 CONFIG_LINKS = $CONFIG_LINKS
17339 CONFIG_COMMANDS = $CONFIG_COMMANDS
17340 > $ac_cs_invocation
17341 on `(hostname || uname -n) 2>/dev/null | sed 1q`
17346 cat >>$CONFIG_STATUS <<EOF
17348 # INIT-COMMANDS section.
17358 cat >>$CONFIG_STATUS <<\EOF
17359 for ac_config_target in $ac_config_targets
17361 case "$ac_config_target" in
17362 # Handling of arguments.
17363 "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
17364 "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
17365 "ncurses_cfg.h" ) CONFIG_HEADERS="$CONFIG_HEADERS ncurses_cfg.h:ncurses_tst.hin" ;;
17366 *) { { echo "$as_me:17366: error: invalid argument: $ac_config_target" >&5
17367 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
17368 { (exit 1); exit 1; }; };;
17372 # If the user did not use the arguments to specify the items to instantiate,
17373 # then the envvar interface is used. Set only those that are not.
17374 # We use the long form for the default assignment because of an extremely
17375 # bizarre bug on SunOS 4.1.3.
17376 if $ac_need_defaults; then
17377 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
17378 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
17379 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
17382 # Create a temporary directory, and hook for its removal unless debugging.
17385 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
17386 trap '{ (exit 1); exit 1; }' 1 2 13 15
17389 # Create a (secure) tmp directory for tmp files.
17392 tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` &&
17393 test -n "$tmp" && test -d "$tmp"
17396 tmp=$TMPDIR/cs$$-$RANDOM
17397 (umask 077 && mkdir $tmp)
17400 echo "$me: cannot create a temporary directory in $TMPDIR" >&2
17401 { (exit 1); exit 1; }
17406 cat >>$CONFIG_STATUS <<EOF
17409 # CONFIG_FILES section.
17412 # No need to generate the scripts if there are no CONFIG_FILES.
17413 # This happens for instance when ./config.status config.h
17414 if test -n "\$CONFIG_FILES"; then
17415 # Protect against being on the right side of a sed subst in config.status.
17416 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
17417 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
17418 s,@SHELL@,$SHELL,;t t
17419 s,@exec_prefix@,$exec_prefix,;t t
17420 s,@prefix@,$prefix,;t t
17421 s,@program_transform_name@,$program_transform_name,;t t
17422 s,@bindir@,$bindir,;t t
17423 s,@sbindir@,$sbindir,;t t
17424 s,@libexecdir@,$libexecdir,;t t
17425 s,@datarootdir@,$datarootdir,;t t
17426 s,@datadir@,$datadir,;t t
17427 s,@sysconfdir@,$sysconfdir,;t t
17428 s,@sharedstatedir@,$sharedstatedir,;t t
17429 s,@localstatedir@,$localstatedir,;t t
17430 s,@libdir@,$libdir,;t t
17431 s,@includedir@,$includedir,;t t
17432 s,@oldincludedir@,$oldincludedir,;t t
17433 s,@infodir@,$infodir,;t t
17434 s,@mandir@,$mandir,;t t
17435 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
17436 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
17437 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
17438 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
17439 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
17440 s,@build_alias@,$build_alias,;t t
17441 s,@host_alias@,$host_alias,;t t
17442 s,@target_alias@,$target_alias,;t t
17443 s,@ECHO_C@,$ECHO_C,;t t
17444 s,@ECHO_N@,$ECHO_N,;t t
17445 s,@ECHO_T@,$ECHO_T,;t t
17446 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
17447 s,@DEFS@,$DEFS,;t t
17448 s,@LIBS@,$LIBS,;t t
17449 s,@build@,$build,;t t
17450 s,@build_cpu@,$build_cpu,;t t
17451 s,@build_vendor@,$build_vendor,;t t
17452 s,@build_os@,$build_os,;t t
17453 s,@host@,$host,;t t
17454 s,@host_cpu@,$host_cpu,;t t
17455 s,@host_vendor@,$host_vendor,;t t
17456 s,@host_os@,$host_os,;t t
17457 s,@SET_MAKE@,$SET_MAKE,;t t
17459 s,@CFLAGS@,$CFLAGS,;t t
17460 s,@LDFLAGS@,$LDFLAGS,;t t
17461 s,@CPPFLAGS@,$CPPFLAGS,;t t
17462 s,@ac_ct_CC@,$ac_ct_CC,;t t
17463 s,@EXEEXT@,$EXEEXT,;t t
17464 s,@OBJEXT@,$OBJEXT,;t t
17465 s,@EXTRA_CPPFLAGS@,$EXTRA_CPPFLAGS,;t t
17468 s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
17469 s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
17470 s,@INSTALL_DATA@,$INSTALL_DATA,;t t
17471 s,@LINT@,$LINT,;t t
17472 s,@LINT_OPTS@,$LINT_OPTS,;t t
17473 s,@CTAGS@,$CTAGS,;t t
17474 s,@ETAGS@,$ETAGS,;t t
17475 s,@MAKE_LOWER_TAGS@,$MAKE_LOWER_TAGS,;t t
17476 s,@MAKE_UPPER_TAGS@,$MAKE_UPPER_TAGS,;t t
17477 s,@MATH_LIB@,$MATH_LIB,;t t
17478 s,@top_builddir@,$top_builddir,;t t
17479 s,@CC_G_OPT@,$CC_G_OPT,;t t
17480 s,@CC_SHARED_OPTS@,$CC_SHARED_OPTS,;t t
17481 s,@DFT_DEP_SUFFIX@,$DFT_DEP_SUFFIX,;t t
17482 s,@DFT_OBJ_SUBDIR@,$DFT_OBJ_SUBDIR,;t t
17483 s,@DFT_UPR_MODEL@,$DFT_UPR_MODEL,;t t
17485 s,@LDFLAGS_SHARED@,$LDFLAGS_SHARED,;t t
17486 s,@LDFLAGS_STATIC@,$LDFLAGS_STATIC,;t t
17487 s,@LD_MODEL@,$LD_MODEL,;t t
17488 s,@LD_SHARED_OPTS@,$LD_SHARED_OPTS,;t t
17489 s,@LIBTOOL@,$LIBTOOL,;t t
17490 s,@LIB_CLEAN@,$LIB_CLEAN,;t t
17491 s,@LIB_COMPILE@,$LIB_COMPILE,;t t
17492 s,@LIB_LINK@,$LIB_LINK,;t t
17493 s,@LINK_TESTS@,$LINK_TESTS,;t t
17494 s,@LOCAL_LDFLAGS@,$LOCAL_LDFLAGS,;t t
17495 s,@PTHREAD@,$PTHREAD,;t t
17496 s,@TEST_ARGS@,$TEST_ARGS,;t t
17497 s,@TEST_DEPS@,$TEST_DEPS,;t t
17498 s,@TEST_LIBS@,$TEST_LIBS,;t t
17499 s,@TINFO_LDFLAGS@,$TINFO_LDFLAGS,;t t
17500 s,@TINFO_LIBS@,$TINFO_LIBS,;t t
17501 s,@cf_cv_abi_version@,$cf_cv_abi_version,;t t
17502 s,@cf_cv_rel_version@,$cf_cv_rel_version,;t t
17503 s,@includesubdir@,$includesubdir,;t t
17504 s,@PKG_CONFIG@,$PKG_CONFIG,;t t
17505 s,@ac_pt_PKG_CONFIG@,$ac_pt_PKG_CONFIG,;t t
17506 s,@ECHO_LT@,$ECHO_LT,;t t
17507 s,@ECHO_LD@,$ECHO_LD,;t t
17508 s,@RULE_CC@,$RULE_CC,;t t
17509 s,@SHOW_CC@,$SHOW_CC,;t t
17510 s,@ECHO_CC@,$ECHO_CC,;t t
17511 s,@NCURSES_WRAP_PREFIX@,$NCURSES_WRAP_PREFIX,;t t
17512 s,@NCURSES_CONFIG@,$NCURSES_CONFIG,;t t
17513 s,@ac_ct_NCURSES_CONFIG@,$ac_ct_NCURSES_CONFIG,;t t
17514 s,@X_CFLAGS@,$X_CFLAGS,;t t
17515 s,@X_PRE_LIBS@,$X_PRE_LIBS,;t t
17516 s,@X_LIBS@,$X_LIBS,;t t
17517 s,@X_EXTRA_LIBS@,$X_EXTRA_LIBS,;t t
17518 s,@XCURSES_CONFIG@,$XCURSES_CONFIG,;t t
17519 s,@ac_ct_XCURSES_CONFIG@,$ac_ct_XCURSES_CONFIG,;t t
17520 s,@EXTRA_CFLAGS@,$EXTRA_CFLAGS,;t t
17521 s,@cf_ldd_prog@,$cf_ldd_prog,;t t
17522 s,@EXTRA_LDFLAGS@,$EXTRA_LDFLAGS,;t t
17527 cat >>$CONFIG_STATUS <<\EOF
17528 # Split the substitutions into bite-sized pieces for seds with
17529 # small command number limits, like on Digital OSF/1 and HP-UX.
17530 ac_max_sed_lines=48
17531 ac_sed_frag=1 # Number of current file.
17532 ac_beg=1 # First line for current file.
17533 ac_end=$ac_max_sed_lines # Line after last line for current file.
17536 while $ac_more_lines; do
17537 if test $ac_beg -gt 1; then
17538 sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
17540 sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
17542 if test ! -s $tmp/subs.frag; then
17543 ac_more_lines=false
17545 # The purpose of the label and of the branching condition is to
17546 # speed up the sed processing (if there are no `@' at all, there
17547 # is no need to browse any of the substitutions).
17548 # These are the two extra sed commands mentioned above.
17550 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
17551 if test -z "$ac_sed_cmds"; then
17552 ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
17554 ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
17556 ac_sed_frag=`expr $ac_sed_frag + 1`
17558 ac_end=`expr $ac_end + $ac_max_sed_lines`
17561 if test -z "$ac_sed_cmds"; then
17564 fi # test -n "$CONFIG_FILES"
17567 cat >>$CONFIG_STATUS <<\EOF
17568 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
17569 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
17571 - | *:- | *:-:* ) # input from stdin
17573 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
17574 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
17575 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
17576 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
17577 * ) ac_file_in=$ac_file.in ;;
17580 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
17581 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
17582 X"$ac_file" : 'X\(//\)[^/]' \| \
17583 X"$ac_file" : 'X\(//\)$' \| \
17584 X"$ac_file" : 'X\(/\)' \| \
17585 . : '\(.\)' 2>/dev/null ||
17587 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
17588 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
17589 /^X\(\/\/\)$/{ s//\1/; q; }
17590 /^X\(\/\).*/{ s//\1/; q; }
17592 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
17593 { case "$ac_dir" in
17594 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
17598 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
17599 case $as_mkdir_dir in
17600 # Skip DOS drivespec
17601 ?:) as_incr_dir=$as_mkdir_dir ;;
17603 as_incr_dir=$as_incr_dir/$as_mkdir_dir
17604 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
17609 ac_dir_suffix="/`echo $ac_dir|sed 's,^\./,,'`"
17610 # A "../" for each directory in $ac_dir_suffix.
17611 ac_dots=`echo "$ac_dir_suffix" | sed 's,/[^/]*,../,g'`
17613 ac_dir_suffix= ac_dots=
17618 if test -z "$ac_dots"; then
17621 ac_top_srcdir=`echo $ac_dots | sed 's,/$,,'`
17623 [\\/]* | ?:[\\/]* )
17624 ac_srcdir=$srcdir$ac_dir_suffix;
17625 ac_top_srcdir=$srcdir ;;
17626 *) # Relative path.
17627 ac_srcdir=$ac_dots$srcdir$ac_dir_suffix
17628 ac_top_srcdir=$ac_dots$srcdir ;;
17632 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
17633 *) ac_INSTALL=$ac_dots$INSTALL ;;
17636 if test x"$ac_file" != x-; then
17637 { echo "$as_me:17637: creating $ac_file" >&5
17638 echo "$as_me: creating $ac_file" >&6;}
17641 # Let's still pretend it is `configure' which instantiates (i.e., don't
17642 # use $as_me), people would be surprised to read:
17643 # /* config.h. Generated automatically by config.status. */
17644 configure_input="Generated automatically from `echo $ac_file_in |
17645 sed 's,.*/,,'` by configure."
17647 # First look for the input files in the build tree, otherwise in the
17649 ac_file_inputs=`IFS=:
17650 for f in $ac_file_in; do
17652 -) echo $tmp/stdin ;;
17654 # Absolute (can't be DOS-style, as IFS=:)
17655 test -f "$f" || { { echo "$as_me:17655: error: cannot find input file: $f" >&5
17656 echo "$as_me: error: cannot find input file: $f" >&2;}
17657 { (exit 1); exit 1; }; }
17660 if test -f "$f"; then
17663 elif test -f "$srcdir/$f"; then
17668 { { echo "$as_me:17668: error: cannot find input file: $f" >&5
17669 echo "$as_me: error: cannot find input file: $f" >&2;}
17670 { (exit 1); exit 1; }; }
17673 done` || { (exit 1); exit 1; }
17675 cat >>$CONFIG_STATUS <<\EOF
17676 ac_warn_datarootdir=no
17677 if test x"$ac_file" != x-; then
17678 for ac_item in $ac_file_inputs
17680 ac_seen=`grep '@\(datadir\|mandir\|infodir\)@' $ac_item`
17681 if test -n "$ac_seen"; then
17682 ac_used=`grep '@datarootdir@' $ac_item`
17683 if test -z "$ac_used"; then
17684 { echo "$as_me:17684: WARNING: datarootdir was used implicitly but not set:
17686 echo "$as_me: WARNING: datarootdir was used implicitly but not set:
17688 ac_warn_datarootdir=yes
17691 ac_seen=`grep '${datarootdir}' $ac_item`
17692 if test -n "$ac_seen"; then
17693 { echo "$as_me:17693: WARNING: datarootdir was used explicitly but not set:
17695 echo "$as_me: WARNING: datarootdir was used explicitly but not set:
17697 ac_warn_datarootdir=yes
17702 if test "x$ac_warn_datarootdir" = xyes; then
17703 ac_sed_cmds="$ac_sed_cmds | sed -e 's,@datarootdir@,\${prefix}/share,g' -e 's,\${datarootdir},\${prefix}/share,g'"
17707 cat >>$CONFIG_STATUS <<EOF
17711 cat >>$CONFIG_STATUS <<\EOF
17713 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
17714 s,@configure_input@,$configure_input,;t t
17715 s,@srcdir@,$ac_srcdir,;t t
17716 s,@top_srcdir@,$ac_top_srcdir,;t t
17717 s,@INSTALL@,$ac_INSTALL,;t t
17718 " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
17720 if test x"$ac_file" != x-; then
17721 cp $tmp/out $ac_file
17723 for ac_name in prefix exec_prefix datarootdir
17725 ac_seen=`fgrep -n '${'$ac_name'[:=].*}' $ac_file`
17726 if test -n "$ac_seen"; then
17727 ac_init=`egrep '[ ]*'$ac_name'[ ]*=' $ac_file`
17728 if test -z "$ac_init"; then
17729 ac_seen=`echo "$ac_seen" |sed -e 's,^,'$ac_file':,'`
17730 { echo "$as_me:17730: WARNING: Variable $ac_name is used but was not set:
17732 echo "$as_me: WARNING: Variable $ac_name is used but was not set:
17737 egrep -n '@[a-z_][a-z_0-9]+@' $ac_file >$tmp/out
17738 egrep -n '@[A-Z_][A-Z_0-9]+@' $ac_file >>$tmp/out
17739 if test -s $tmp/out; then
17740 ac_seen=`sed -e 's,^,'$ac_file':,' < $tmp/out`
17741 { echo "$as_me:17741: WARNING: Some variables may not be substituted:
17743 echo "$as_me: WARNING: Some variables may not be substituted:
17753 cat >>$CONFIG_STATUS <<\EOF
17756 # CONFIG_HEADER section.
17759 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
17760 # NAME is the cpp macro being defined and VALUE is the value it is being given.
17762 # ac_d sets the value in "#define NAME VALUE" lines.
17763 ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
17764 ac_dB='[ ].*$,\1#\2'
17767 # ac_i turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
17768 ac_iA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
17769 ac_iB='\([ ]\),\1#\2define\3'
17772 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
17773 ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
17774 ac_uB='$,\1#\2define\3'
17778 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
17779 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
17781 - | *:- | *:-:* ) # input from stdin
17783 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
17784 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
17785 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
17786 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
17787 * ) ac_file_in=$ac_file.in ;;
17790 test x"$ac_file" != x- && { echo "$as_me:17790: creating $ac_file" >&5
17791 echo "$as_me: creating $ac_file" >&6;}
17793 # First look for the input files in the build tree, otherwise in the
17795 ac_file_inputs=`IFS=:
17796 for f in $ac_file_in; do
17798 -) echo $tmp/stdin ;;
17800 # Absolute (can't be DOS-style, as IFS=:)
17801 test -f "$f" || { { echo "$as_me:17801: error: cannot find input file: $f" >&5
17802 echo "$as_me: error: cannot find input file: $f" >&2;}
17803 { (exit 1); exit 1; }; }
17806 if test -f "$f"; then
17809 elif test -f "$srcdir/$f"; then
17814 { { echo "$as_me:17814: error: cannot find input file: $f" >&5
17815 echo "$as_me: error: cannot find input file: $f" >&2;}
17816 { (exit 1); exit 1; }; }
17819 done` || { (exit 1); exit 1; }
17820 # Remove the trailing spaces.
17821 sed 's/[ ]*$//' $ac_file_inputs >$tmp/in
17825 # Transform confdefs.h into a list of #define's. We won't use it as a sed
17826 # script, but as data to insert where we see @DEFS@. We expect AC_SAVE_DEFS to
17827 # be either 'cat' or 'sort'.
17828 cat confdefs.h | uniq >conftest.vals
17830 # Break up conftest.vals because some shells have a limit on
17831 # the size of here documents, and old seds have small limits too.
17833 rm -f conftest.tail
17834 echo ' rm -f conftest.frag' >> $CONFIG_STATUS
17835 while grep . conftest.vals >/dev/null
17837 # Write chunks of a limited-size here document to conftest.frag.
17838 echo ' cat >> conftest.frag <<CEOF' >> $CONFIG_STATUS
17839 sed ${ac_max_here_lines}q conftest.vals | sed -e 's/#ifdef.*/#if 0/' >> $CONFIG_STATUS
17840 echo 'CEOF' >> $CONFIG_STATUS
17841 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
17842 rm -f conftest.vals
17843 mv conftest.tail conftest.vals
17845 rm -f conftest.vals
17847 # Run sed to substitute the contents of conftest.frag into $tmp/in at the
17849 echo ' cat >> conftest.edit <<CEOF
17850 /@DEFS@/r conftest.frag
17853 sed -f conftest.edit $tmp/in > $tmp/out
17855 mv $tmp/out $tmp/in
17856 rm -f conftest.edit conftest.frag
17857 ' >> $CONFIG_STATUS
17859 cat >>$CONFIG_STATUS <<\EOF
17860 # Let's still pretend it is `configure' which instantiates (i.e., don't
17861 # use $as_me), people would be surprised to read:
17862 # /* config.h. Generated automatically by config.status. */
17863 if test x"$ac_file" = x-; then
17864 echo "/* Generated automatically by configure. */" >$tmp/config.h
17866 echo "/* $ac_file. Generated automatically by configure. */" >$tmp/config.h
17868 cat $tmp/in >>$tmp/config.h
17870 if test x"$ac_file" != x-; then
17871 if cmp -s $ac_file $tmp/config.h 2>/dev/null; then
17872 { echo "$as_me:17872: $ac_file is unchanged" >&5
17873 echo "$as_me: $ac_file is unchanged" >&6;}
17875 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
17876 X"$ac_file" : 'X\(//\)[^/]' \| \
17877 X"$ac_file" : 'X\(//\)$' \| \
17878 X"$ac_file" : 'X\(/\)' \| \
17879 . : '\(.\)' 2>/dev/null ||
17881 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
17882 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
17883 /^X\(\/\/\)$/{ s//\1/; q; }
17884 /^X\(\/\).*/{ s//\1/; q; }
17886 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
17887 { case "$ac_dir" in
17888 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
17892 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
17893 case $as_mkdir_dir in
17894 # Skip DOS drivespec
17895 ?:) as_incr_dir=$as_mkdir_dir ;;
17897 as_incr_dir=$as_incr_dir/$as_mkdir_dir
17898 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
17905 mv $tmp/config.h $ac_file
17909 rm -f $tmp/config.h
17913 cat >>$CONFIG_STATUS <<\EOF
17915 # CONFIG_COMMANDS section.
17917 for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
17918 ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
17919 ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
17926 if test ! -d $srcdir/$cf_dir; then
17928 elif test -f $srcdir/$cf_dir/programs; then
17929 $AWK -f $srcdir/mk-test.awk INSTALL=yes ECHO_LINK="$ECHO_LD" $srcdir/$cf_dir/programs >>$cf_dir/Makefile
17933 cat >>Makefile <<TEST_EOF
17935 # These rules are generated so we do not rely on suffix rules, which do not
17936 # work consistently for different make-programs (the '\$(MODEL)/' confuses
17937 # some, and the '\$x' confuses others).
17940 LIST=`sed -e 's/[ ].*//' -e '/^[#@]/d' $srcdir/modules`
17943 cat >>Makefile <<TEST_EOF
17945 \$(MODEL)/$N.o : \$(srcdir)/$N.c \\
17946 \$(srcdir)/test.priv.h \\
17949 $ECHO_CC\$(CC) -c \$(CFLAGS_DEFAULT) \$(srcdir)/$N.c
17953 if test -f ../config.guess && test -f ../config.sub
17955 cat >>Makefile <<TEST_EOF
17957 # if we used CF_INHERIT for getting these files, we can remove them
17959 rm -f config.guess config.sub
17967 cat >>$CONFIG_STATUS <<\EOF
17969 { (exit 0); exit 0; }
17971 chmod +x $CONFIG_STATUS
17972 ac_clean_files=$ac_clean_files_save
17974 # configure is writing to config.log, and then calls config.status.
17975 # config.status does its own redirection, appending to config.log.
17976 # Unfortunately, on DOS this fails, as config.log is still kept open
17977 # by configure, so config.status won't be able to write to it; its
17978 # output is simply discarded. So we exec the FD to /dev/null,
17979 # effectively closing config.log, so it can be properly (re)opened and
17980 # appended to by config.status. When coming back to configure, we
17981 # need to make the FD available again.
17982 if test "$no_create" != yes; then
17985 $SHELL $CONFIG_STATUS || ac_cs_success=false
17987 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
17988 # would make configure fail if this is the last instruction.
17989 $ac_cs_success || { (exit 1); exit 1; }