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-neXtaw link with neXT Athena library
671 --with-XawPlus link with Athena-Plus library
672 --with-x use the X Window System
673 Testing/development Options:
674 --enable-warnings test: turn on gcc compiler warnings
675 --with-dmalloc test: use Gray Watson's dmalloc library
676 --with-dbmalloc test: use Conor Cahill's dbmalloc library
677 --with-valgrind test: use valgrind
678 --disable-leaks test: free permanent memory, analyze leaks
679 --disable-rpath-hack don't add rpath options for additional libraries
681 Some influential environment variables:
682 CC C compiler command
683 CFLAGS C compiler flags
684 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
685 nonstandard directory <lib dir>
686 CPPFLAGS C/C++ preprocessor flags, e.g. -I<include dir> if you have
687 headers in a nonstandard directory <include dir>
690 Use these variables to override the choices made by `configure' or to help
691 it to find libraries and programs with nonstandard names/locations.
696 if test "$ac_init_help" = "recursive"; then
697 # If there are subdirs, report their specific --help.
699 for ac_subdir in : $ac_subdirs_all; do test "x$ac_subdir" = x: && continue
701 # A "../" for each directory in /$ac_subdir.
702 ac_dots=`echo $ac_subdir |
703 sed 's,^\./,,;s,[^/]$,&/,;s,[^/]*/,../,g'`
706 .) # No --srcdir option. We are building in place.
707 ac_sub_srcdir=$srcdir ;;
708 [\\/]* | ?:[\\/]* ) # Absolute path.
709 ac_sub_srcdir=$srcdir/$ac_subdir ;;
711 ac_sub_srcdir=$ac_dots$srcdir/$ac_subdir ;;
714 # Check for guested configure; otherwise get Cygnus style configure.
715 if test -f $ac_sub_srcdir/configure.gnu; then
717 $SHELL $ac_sub_srcdir/configure.gnu --help=recursive
718 elif test -f $ac_sub_srcdir/configure; then
720 $SHELL $ac_sub_srcdir/configure --help=recursive
721 elif test -f $ac_sub_srcdir/configure.ac ||
722 test -f $ac_sub_srcdir/configure.in; then
726 echo "$as_me: WARNING: no configuration information is in $ac_subdir" >&2
732 test -n "$ac_init_help" && exit 0
733 if $ac_init_version; then
736 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
737 Free Software Foundation, Inc.
738 This configure script is free software; the Free Software Foundation
739 gives unlimited permission to copy, distribute and modify it.
745 This file contains any messages produced by compilers while
746 running configure, to aid debugging if configure makes a mistake.
748 It was created by $as_me, which was
749 generated by GNU Autoconf 2.52.20121002. Invocation command line was
760 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
761 uname -m = `(uname -m) 2>/dev/null || echo unknown`
762 uname -r = `(uname -r) 2>/dev/null || echo unknown`
763 uname -s = `(uname -s) 2>/dev/null || echo unknown`
764 uname -v = `(uname -v) 2>/dev/null || echo unknown`
766 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
767 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
769 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
770 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
771 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
772 hostinfo = `(hostinfo) 2>/dev/null || echo unknown`
773 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
774 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
775 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
789 # Keep a trace of the command line.
790 # Strip out --no-create and --no-recursion so they do not pile up.
791 # Also quote any args containing shell meta-characters.
797 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
798 | --no-cr | --no-c) ;;
799 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
800 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
801 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
802 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"`
803 ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
805 *) ac_configure_args="$ac_configure_args$ac_sep$ac_arg"
808 # Get rid of the leading space.
811 # When interrupted or exit'd, cleanup temporary files, and complete
812 # config.log. We remove comments because anyway the quotes in there
813 # would cause problems or look ugly.
815 # Save into config.log some information that might help in debugging.
817 echo "## ----------------- ##" >&5
818 echo "## Cache variables. ##" >&5
819 echo "## ----------------- ##" >&5
821 # The following way of writing the cache mishandles newlines in values,
824 case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
827 "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
828 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
832 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
836 sed "/^$/d" confdefs.h >conftest.log
837 if test -s conftest.log; then
839 echo "## ------------ ##" >&5
840 echo "## confdefs.h. ##" >&5
841 echo "## ------------ ##" >&5
846 test "$ac_signal" != 0 &&
847 echo "$as_me: caught signal $ac_signal" >&5
848 echo "$as_me: exit $exit_status" >&5
849 rm -rf conftest* confdefs* core core.* *.core conf$$* $ac_clean_files &&
852 for ac_signal in 1 2 13 15; do
853 trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
857 # confdefs.h avoids OS command line length limits that DEFS can exceed.
858 rm -rf conftest* confdefs.h
859 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
862 # Let the site file select an alternate cache file if it wants to.
863 # Prefer explicitly selected file to automatically selected ones.
864 if test -z "$CONFIG_SITE"; then
865 if test "x$prefix" != xNONE; then
866 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
868 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
871 for ac_site_file in $CONFIG_SITE; do
872 if test -r "$ac_site_file"; then
873 { echo "$as_me:873: loading site script $ac_site_file" >&5
874 echo "$as_me: loading site script $ac_site_file" >&6;}
875 cat "$ac_site_file" >&5
880 if test -r "$cache_file"; then
881 # Some versions of bash will fail to source /dev/null (special
882 # files actually), so we avoid doing that.
883 if test -f "$cache_file"; then
884 { echo "$as_me:884: loading cache $cache_file" >&5
885 echo "$as_me: loading cache $cache_file" >&6;}
887 [\\/]* | ?:[\\/]* ) . $cache_file;;
892 { echo "$as_me:892: creating cache $cache_file" >&5
893 echo "$as_me: creating cache $cache_file" >&6;}
897 # Check that the precious variables saved in the cache have kept the same
899 ac_cache_corrupted=false
900 for ac_var in `(set) 2>&1 |
901 sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
902 eval ac_old_set=\$ac_cv_env_${ac_var}_set
903 eval ac_new_set=\$ac_env_${ac_var}_set
904 eval ac_old_val="\$ac_cv_env_${ac_var}_value"
905 eval ac_new_val="\$ac_env_${ac_var}_value"
906 case $ac_old_set,$ac_new_set in
908 { echo "$as_me:908: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
909 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
910 ac_cache_corrupted=: ;;
912 { echo "$as_me:912: error: \`$ac_var' was not set in the previous run" >&5
913 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
914 ac_cache_corrupted=: ;;
917 if test "x$ac_old_val" != "x$ac_new_val"; then
918 { echo "$as_me:918: error: \`$ac_var' has changed since the previous run:" >&5
919 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
920 { echo "$as_me:920: former value: $ac_old_val" >&5
921 echo "$as_me: former value: $ac_old_val" >&2;}
922 { echo "$as_me:922: current value: $ac_new_val" >&5
923 echo "$as_me: current value: $ac_new_val" >&2;}
927 # Pass precious variables to config.status. It doesn't matter if
928 # we pass some twice (in addition to the command line arguments).
929 if test "$ac_new_set" = set; then
931 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
932 ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"`
933 ac_configure_args="$ac_configure_args '$ac_arg'"
935 *) ac_configure_args="$ac_configure_args $ac_var=$ac_new_val"
940 if $ac_cache_corrupted; then
941 { echo "$as_me:941: error: changes in the environment can compromise the build" >&5
942 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
943 { { echo "$as_me:943: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
944 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
945 { (exit 1); exit 1; }; }
949 ac_cpp='$CPP $CPPFLAGS'
950 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
951 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
952 ac_compiler_gnu=$ac_cv_c_compiler_gnu
953 ac_main_return=return
955 case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
956 *c*,-n*) ECHO_N= ECHO_C='
958 *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
959 *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
961 echo "#! $SHELL" >conftest.sh
962 echo "exit 0" >>conftest.sh
964 if { (echo "$as_me:964: PATH=\".;.\"; conftest.sh") >&5
965 (PATH=".;."; conftest.sh) 2>&5
967 echo "$as_me:967: \$? = $ac_status" >&5
968 (exit $ac_status); }; then
969 ac_path_separator=';'
973 PATH_SEPARATOR="$ac_path_separator"
976 ac_config_headers="$ac_config_headers ncurses_cfg.h:ncurses_tst.hin"
978 test -f config.guess || ( test -f ../config.guess && cp ../config.guess ./ )
980 test -f config.sub || ( test -f ../config.sub && cp ../config.sub ./ )
983 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
984 if test -f $ac_dir/install-sh; then
986 ac_install_sh="$ac_aux_dir/install-sh -c"
988 elif test -f $ac_dir/install.sh; then
990 ac_install_sh="$ac_aux_dir/install.sh -c"
992 elif test -f $ac_dir/shtool; then
994 ac_install_sh="$ac_aux_dir/shtool install -c"
998 if test -z "$ac_aux_dir"; then
999 { { echo "$as_me:999: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
1000 echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
1001 { (exit 1); exit 1; }; }
1003 ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1004 ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1005 ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
1007 # Make sure we can run config.sub.
1008 $ac_config_sub sun4 >/dev/null 2>&1 ||
1009 { { echo "$as_me:1009: error: cannot run $ac_config_sub" >&5
1010 echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1011 { (exit 1); exit 1; }; }
1013 echo "$as_me:1013: checking build system type" >&5
1014 echo $ECHO_N "checking build system type... $ECHO_C" >&6
1015 if test "${ac_cv_build+set}" = set; then
1016 echo $ECHO_N "(cached) $ECHO_C" >&6
1018 ac_cv_build_alias=$build_alias
1019 test -z "$ac_cv_build_alias" &&
1020 ac_cv_build_alias=`$ac_config_guess`
1021 test -z "$ac_cv_build_alias" &&
1022 { { echo "$as_me:1022: error: cannot guess build type; you must specify one" >&5
1023 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1024 { (exit 1); exit 1; }; }
1025 ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
1026 { { echo "$as_me:1026: error: $ac_config_sub $ac_cv_build_alias failed." >&5
1027 echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed." >&2;}
1028 { (exit 1); exit 1; }; }
1031 echo "$as_me:1031: result: $ac_cv_build" >&5
1032 echo "${ECHO_T}$ac_cv_build" >&6
1034 build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1035 build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1036 build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1038 if test -f $srcdir/config.guess || test -f $ac_aux_dir/config.guess ; then
1039 echo "$as_me:1039: checking host system type" >&5
1040 echo $ECHO_N "checking host system type... $ECHO_C" >&6
1041 if test "${ac_cv_host+set}" = set; then
1042 echo $ECHO_N "(cached) $ECHO_C" >&6
1044 ac_cv_host_alias=$host_alias
1045 test -z "$ac_cv_host_alias" &&
1046 ac_cv_host_alias=$ac_cv_build_alias
1047 ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
1048 { { echo "$as_me:1048: error: $ac_config_sub $ac_cv_host_alias failed" >&5
1049 echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1050 { (exit 1); exit 1; }; }
1053 echo "$as_me:1053: result: $ac_cv_host" >&5
1054 echo "${ECHO_T}$ac_cv_host" >&6
1056 host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1057 host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1058 host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1060 system_name="$host_os"
1062 system_name="`(uname -s -r) 2>/dev/null`"
1063 if test -z "$system_name" ; then
1064 system_name="`(hostname) 2>/dev/null`"
1067 test -n "$system_name" &&
1068 cat >>confdefs.h <<EOF
1069 #define SYSTEM_NAME "$system_name"
1072 if test "${cf_cv_system_name+set}" = set; then
1073 echo $ECHO_N "(cached) $ECHO_C" >&6
1075 cf_cv_system_name="$system_name"
1078 test -z "$system_name" && system_name="$cf_cv_system_name"
1079 test -n "$cf_cv_system_name" && echo "$as_me:1079: result: Configuring for $cf_cv_system_name" >&5
1080 echo "${ECHO_T}Configuring for $cf_cv_system_name" >&6
1082 if test ".$system_name" != ".$cf_cv_system_name" ; then
1083 echo "$as_me:1083: result: Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&5
1084 echo "${ECHO_T}Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&6
1085 { { echo "$as_me:1085: error: \"Please remove config.cache and try again.\"" >&5
1086 echo "$as_me: error: \"Please remove config.cache and try again.\"" >&2;}
1087 { (exit 1); exit 1; }; }
1090 test "$program_prefix" != NONE &&
1091 program_transform_name="s,^,$program_prefix,;$program_transform_name"
1092 # Use a double $ so make ignores it.
1093 test "$program_suffix" != NONE &&
1094 program_transform_name="s,\$,$program_suffix,;$program_transform_name"
1095 # Double any \ or $. echo might interpret backslashes.
1096 # By default was `s,x,x', remove it if useless.
1097 cat <<\_ACEOF >conftest.sed
1098 s/[\\$]/&&/g;s/;s,x,x,$//
1100 program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
1103 echo "$as_me:1103: checking whether ${MAKE-make} sets \${MAKE}" >&5
1104 echo $ECHO_N "checking whether ${MAKE-make} sets \${MAKE}... $ECHO_C" >&6
1105 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,./+-,__p_,'`
1106 if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
1107 echo $ECHO_N "(cached) $ECHO_C" >&6
1109 cat >conftest.make <<\EOF
1111 @echo 'ac_maketemp="${MAKE}"'
1113 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1114 eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
1115 if test -n "$ac_maketemp"; then
1116 eval ac_cv_prog_make_${ac_make}_set=yes
1118 eval ac_cv_prog_make_${ac_make}_set=no
1122 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
1123 echo "$as_me:1123: result: yes" >&5
1124 echo "${ECHO_T}yes" >&6
1127 echo "$as_me:1127: result: no" >&5
1128 echo "${ECHO_T}no" >&6
1129 SET_MAKE="MAKE=${MAKE-make}"
1133 ac_cpp='$CPP $CPPFLAGS'
1134 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1135 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1136 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1137 ac_main_return=return
1138 if test -n "$ac_tool_prefix"; then
1139 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
1140 set dummy ${ac_tool_prefix}gcc; ac_word=$2
1141 echo "$as_me:1141: checking for $ac_word" >&5
1142 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1143 if test "${ac_cv_prog_CC+set}" = set; then
1144 echo $ECHO_N "(cached) $ECHO_C" >&6
1146 if test -n "$CC"; then
1147 ac_cv_prog_CC="$CC" # Let the user override the test.
1149 ac_save_IFS=$IFS; IFS=$ac_path_separator
1151 for ac_dir in $ac_dummy; do
1153 test -z "$ac_dir" && ac_dir=.
1154 $as_executable_p "$ac_dir/$ac_word" || continue
1155 ac_cv_prog_CC="${ac_tool_prefix}gcc"
1156 echo "$as_me:1156: found $ac_dir/$ac_word" >&5
1163 if test -n "$CC"; then
1164 echo "$as_me:1164: result: $CC" >&5
1165 echo "${ECHO_T}$CC" >&6
1167 echo "$as_me:1167: result: no" >&5
1168 echo "${ECHO_T}no" >&6
1172 if test -z "$ac_cv_prog_CC"; then
1174 # Extract the first word of "gcc", so it can be a program name with args.
1175 set dummy gcc; ac_word=$2
1176 echo "$as_me:1176: checking for $ac_word" >&5
1177 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1178 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1179 echo $ECHO_N "(cached) $ECHO_C" >&6
1181 if test -n "$ac_ct_CC"; then
1182 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1184 ac_save_IFS=$IFS; IFS=$ac_path_separator
1186 for ac_dir in $ac_dummy; do
1188 test -z "$ac_dir" && ac_dir=.
1189 $as_executable_p "$ac_dir/$ac_word" || continue
1190 ac_cv_prog_ac_ct_CC="gcc"
1191 echo "$as_me:1191: found $ac_dir/$ac_word" >&5
1197 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1198 if test -n "$ac_ct_CC"; then
1199 echo "$as_me:1199: result: $ac_ct_CC" >&5
1200 echo "${ECHO_T}$ac_ct_CC" >&6
1202 echo "$as_me:1202: result: no" >&5
1203 echo "${ECHO_T}no" >&6
1211 if test -z "$CC"; then
1212 if test -n "$ac_tool_prefix"; then
1213 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
1214 set dummy ${ac_tool_prefix}cc; ac_word=$2
1215 echo "$as_me:1215: checking for $ac_word" >&5
1216 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1217 if test "${ac_cv_prog_CC+set}" = set; then
1218 echo $ECHO_N "(cached) $ECHO_C" >&6
1220 if test -n "$CC"; then
1221 ac_cv_prog_CC="$CC" # Let the user override the test.
1223 ac_save_IFS=$IFS; IFS=$ac_path_separator
1225 for ac_dir in $ac_dummy; do
1227 test -z "$ac_dir" && ac_dir=.
1228 $as_executable_p "$ac_dir/$ac_word" || continue
1229 ac_cv_prog_CC="${ac_tool_prefix}cc"
1230 echo "$as_me:1230: found $ac_dir/$ac_word" >&5
1237 if test -n "$CC"; then
1238 echo "$as_me:1238: result: $CC" >&5
1239 echo "${ECHO_T}$CC" >&6
1241 echo "$as_me:1241: result: no" >&5
1242 echo "${ECHO_T}no" >&6
1246 if test -z "$ac_cv_prog_CC"; then
1248 # Extract the first word of "cc", so it can be a program name with args.
1249 set dummy cc; ac_word=$2
1250 echo "$as_me:1250: checking for $ac_word" >&5
1251 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1252 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1253 echo $ECHO_N "(cached) $ECHO_C" >&6
1255 if test -n "$ac_ct_CC"; then
1256 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1258 ac_save_IFS=$IFS; IFS=$ac_path_separator
1260 for ac_dir in $ac_dummy; do
1262 test -z "$ac_dir" && ac_dir=.
1263 $as_executable_p "$ac_dir/$ac_word" || continue
1264 ac_cv_prog_ac_ct_CC="cc"
1265 echo "$as_me:1265: found $ac_dir/$ac_word" >&5
1271 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1272 if test -n "$ac_ct_CC"; then
1273 echo "$as_me:1273: result: $ac_ct_CC" >&5
1274 echo "${ECHO_T}$ac_ct_CC" >&6
1276 echo "$as_me:1276: result: no" >&5
1277 echo "${ECHO_T}no" >&6
1286 if test -z "$CC"; then
1287 # Extract the first word of "cc", so it can be a program name with args.
1288 set dummy cc; ac_word=$2
1289 echo "$as_me:1289: checking for $ac_word" >&5
1290 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1291 if test "${ac_cv_prog_CC+set}" = set; then
1292 echo $ECHO_N "(cached) $ECHO_C" >&6
1294 if test -n "$CC"; then
1295 ac_cv_prog_CC="$CC" # Let the user override the test.
1298 ac_save_IFS=$IFS; IFS=$ac_path_separator
1300 for ac_dir in $ac_dummy; do
1302 test -z "$ac_dir" && ac_dir=.
1303 $as_executable_p "$ac_dir/$ac_word" || continue
1304 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
1305 ac_prog_rejected=yes
1309 echo "$as_me:1309: found $ac_dir/$ac_word" >&5
1313 if test $ac_prog_rejected = yes; then
1314 # We found a bogon in the path, so make sure we never use it.
1315 set dummy $ac_cv_prog_CC
1317 if test $# != 0; then
1318 # We chose a different compiler from the bogus one.
1319 # However, it has the same basename, so the bogon will be chosen
1320 # first if we set CC to just the basename; use the full file name.
1322 set dummy "$ac_dir/$ac_word" ${1+"$@"}
1330 if test -n "$CC"; then
1331 echo "$as_me:1331: result: $CC" >&5
1332 echo "${ECHO_T}$CC" >&6
1334 echo "$as_me:1334: result: no" >&5
1335 echo "${ECHO_T}no" >&6
1339 if test -z "$CC"; then
1340 if test -n "$ac_tool_prefix"; then
1343 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
1344 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
1345 echo "$as_me:1345: checking for $ac_word" >&5
1346 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1347 if test "${ac_cv_prog_CC+set}" = set; then
1348 echo $ECHO_N "(cached) $ECHO_C" >&6
1350 if test -n "$CC"; then
1351 ac_cv_prog_CC="$CC" # Let the user override the test.
1353 ac_save_IFS=$IFS; IFS=$ac_path_separator
1355 for ac_dir in $ac_dummy; do
1357 test -z "$ac_dir" && ac_dir=.
1358 $as_executable_p "$ac_dir/$ac_word" || continue
1359 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
1360 echo "$as_me:1360: found $ac_dir/$ac_word" >&5
1367 if test -n "$CC"; then
1368 echo "$as_me:1368: result: $CC" >&5
1369 echo "${ECHO_T}$CC" >&6
1371 echo "$as_me:1371: result: no" >&5
1372 echo "${ECHO_T}no" >&6
1375 test -n "$CC" && break
1378 if test -z "$CC"; then
1382 # Extract the first word of "$ac_prog", so it can be a program name with args.
1383 set dummy $ac_prog; ac_word=$2
1384 echo "$as_me:1384: checking for $ac_word" >&5
1385 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1386 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1387 echo $ECHO_N "(cached) $ECHO_C" >&6
1389 if test -n "$ac_ct_CC"; then
1390 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1392 ac_save_IFS=$IFS; IFS=$ac_path_separator
1394 for ac_dir in $ac_dummy; do
1396 test -z "$ac_dir" && ac_dir=.
1397 $as_executable_p "$ac_dir/$ac_word" || continue
1398 ac_cv_prog_ac_ct_CC="$ac_prog"
1399 echo "$as_me:1399: found $ac_dir/$ac_word" >&5
1405 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1406 if test -n "$ac_ct_CC"; then
1407 echo "$as_me:1407: result: $ac_ct_CC" >&5
1408 echo "${ECHO_T}$ac_ct_CC" >&6
1410 echo "$as_me:1410: result: no" >&5
1411 echo "${ECHO_T}no" >&6
1414 test -n "$ac_ct_CC" && break
1422 test -z "$CC" && { { echo "$as_me:1422: error: no acceptable cc found in \$PATH" >&5
1423 echo "$as_me: error: no acceptable cc found in \$PATH" >&2;}
1424 { (exit 1); exit 1; }; }
1426 # Provide some information about the compiler.
1427 echo "$as_me:1427:" \
1428 "checking for C compiler version" >&5
1429 ac_compiler=`set X $ac_compile; echo $2`
1430 { (eval echo "$as_me:1430: \"$ac_compiler --version </dev/null >&5\"") >&5
1431 (eval $ac_compiler --version </dev/null >&5) 2>&5
1433 echo "$as_me:1433: \$? = $ac_status" >&5
1434 (exit $ac_status); }
1435 { (eval echo "$as_me:1435: \"$ac_compiler -v </dev/null >&5\"") >&5
1436 (eval $ac_compiler -v </dev/null >&5) 2>&5
1438 echo "$as_me:1438: \$? = $ac_status" >&5
1439 (exit $ac_status); }
1440 { (eval echo "$as_me:1440: \"$ac_compiler -V </dev/null >&5\"") >&5
1441 (eval $ac_compiler -V </dev/null >&5) 2>&5
1443 echo "$as_me:1443: \$? = $ac_status" >&5
1444 (exit $ac_status); }
1446 cat >conftest.$ac_ext <<_ACEOF
1447 #line 1447 "configure"
1448 #include "confdefs.h"
1458 ac_clean_files_save=$ac_clean_files
1459 ac_clean_files="$ac_clean_files a.out a.exe"
1460 # Try to create an executable without -o first, disregard a.out.
1461 # It will help us diagnose broken compilers, and finding out an intuition
1463 echo "$as_me:1463: checking for C compiler default output" >&5
1464 echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
1465 ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
1466 if { (eval echo "$as_me:1466: \"$ac_link_default\"") >&5
1467 (eval $ac_link_default) 2>&5
1469 echo "$as_me:1469: \$? = $ac_status" >&5
1470 (exit $ac_status); }; then
1471 # Find the output, starting from the most likely. This scheme is
1472 # not robust to junk in `.', hence go to wildcards (a.*) only as a last
1474 for ac_file in `ls a.exe conftest.exe 2>/dev/null;
1475 ls a.out conftest 2>/dev/null;
1476 ls a.* conftest.* 2>/dev/null`; do
1478 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1479 a.out ) # We found the default executable, but exeext='' is most
1482 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1483 # FIXME: I believe we export ac_cv_exeext for Libtool --akim.
1490 echo "$as_me: failed program was:" >&5
1491 cat conftest.$ac_ext >&5
1492 { { echo "$as_me:1492: error: C compiler cannot create executables" >&5
1493 echo "$as_me: error: C compiler cannot create executables" >&2;}
1494 { (exit 77); exit 77; }; }
1497 ac_exeext=$ac_cv_exeext
1498 echo "$as_me:1498: result: $ac_file" >&5
1499 echo "${ECHO_T}$ac_file" >&6
1501 # Check the compiler produces executables we can run. If not, either
1502 # the compiler is broken, or we cross compile.
1503 echo "$as_me:1503: checking whether the C compiler works" >&5
1504 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
1505 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
1506 # If not cross compiling, check that we can run a simple program.
1507 if test "$cross_compiling" != yes; then
1508 if { ac_try='./$ac_file'
1509 { (eval echo "$as_me:1509: \"$ac_try\"") >&5
1512 echo "$as_me:1512: \$? = $ac_status" >&5
1513 (exit $ac_status); }; }; then
1516 if test "$cross_compiling" = maybe; then
1519 { { echo "$as_me:1519: error: cannot run C compiled programs.
1520 If you meant to cross compile, use \`--host'." >&5
1521 echo "$as_me: error: cannot run C compiled programs.
1522 If you meant to cross compile, use \`--host'." >&2;}
1523 { (exit 1); exit 1; }; }
1527 echo "$as_me:1527: result: yes" >&5
1528 echo "${ECHO_T}yes" >&6
1530 rm -f a.out a.exe conftest$ac_cv_exeext
1531 ac_clean_files=$ac_clean_files_save
1532 # Check the compiler produces executables we can run. If not, either
1533 # the compiler is broken, or we cross compile.
1534 echo "$as_me:1534: checking whether we are cross compiling" >&5
1535 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
1536 echo "$as_me:1536: result: $cross_compiling" >&5
1537 echo "${ECHO_T}$cross_compiling" >&6
1539 echo "$as_me:1539: checking for executable suffix" >&5
1540 echo $ECHO_N "checking for executable suffix... $ECHO_C" >&6
1541 if { (eval echo "$as_me:1541: \"$ac_link\"") >&5
1542 (eval $ac_link) 2>&5
1544 echo "$as_me:1544: \$? = $ac_status" >&5
1545 (exit $ac_status); }; then
1546 # If both `conftest.exe' and `conftest' are `present' (well, observable)
1547 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
1548 # work properly (i.e., refer to `conftest.exe'), while it won't with
1550 for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do
1552 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1553 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1560 { { echo "$as_me:1560: error: cannot compute EXEEXT: cannot compile and link" >&5
1561 echo "$as_me: error: cannot compute EXEEXT: cannot compile and link" >&2;}
1562 { (exit 1); exit 1; }; }
1565 rm -f conftest$ac_cv_exeext
1566 echo "$as_me:1566: result: $ac_cv_exeext" >&5
1567 echo "${ECHO_T}$ac_cv_exeext" >&6
1569 rm -f conftest.$ac_ext
1570 EXEEXT=$ac_cv_exeext
1572 echo "$as_me:1572: checking for object suffix" >&5
1573 echo $ECHO_N "checking for object suffix... $ECHO_C" >&6
1574 if test "${ac_cv_objext+set}" = set; then
1575 echo $ECHO_N "(cached) $ECHO_C" >&6
1577 cat >conftest.$ac_ext <<_ACEOF
1578 #line 1578 "configure"
1579 #include "confdefs.h"
1589 rm -f conftest.o conftest.obj
1590 if { (eval echo "$as_me:1590: \"$ac_compile\"") >&5
1591 (eval $ac_compile) 2>&5
1593 echo "$as_me:1593: \$? = $ac_status" >&5
1594 (exit $ac_status); }; then
1595 for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
1597 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.map | *.inf ) ;;
1598 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
1603 echo "$as_me: failed program was:" >&5
1604 cat conftest.$ac_ext >&5
1605 { { echo "$as_me:1605: error: cannot compute OBJEXT: cannot compile" >&5
1606 echo "$as_me: error: cannot compute OBJEXT: cannot compile" >&2;}
1607 { (exit 1); exit 1; }; }
1610 rm -f conftest.$ac_cv_objext conftest.$ac_ext
1612 echo "$as_me:1612: result: $ac_cv_objext" >&5
1613 echo "${ECHO_T}$ac_cv_objext" >&6
1614 OBJEXT=$ac_cv_objext
1616 echo "$as_me:1616: checking whether we are using the GNU C compiler" >&5
1617 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
1618 if test "${ac_cv_c_compiler_gnu+set}" = set; then
1619 echo $ECHO_N "(cached) $ECHO_C" >&6
1621 cat >conftest.$ac_ext <<_ACEOF
1622 #line 1622 "configure"
1623 #include "confdefs.h"
1636 rm -f conftest.$ac_objext
1637 if { (eval echo "$as_me:1637: \"$ac_compile\"") >&5
1638 (eval $ac_compile) 2>&5
1640 echo "$as_me:1640: \$? = $ac_status" >&5
1641 (exit $ac_status); } &&
1642 { ac_try='test -s conftest.$ac_objext'
1643 { (eval echo "$as_me:1643: \"$ac_try\"") >&5
1646 echo "$as_me:1646: \$? = $ac_status" >&5
1647 (exit $ac_status); }; }; then
1650 echo "$as_me: failed program was:" >&5
1651 cat conftest.$ac_ext >&5
1654 rm -f conftest.$ac_objext conftest.$ac_ext
1655 ac_cv_c_compiler_gnu=$ac_compiler_gnu
1658 echo "$as_me:1658: result: $ac_cv_c_compiler_gnu" >&5
1659 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
1660 GCC=`test $ac_compiler_gnu = yes && echo yes`
1661 ac_test_CFLAGS=${CFLAGS+set}
1662 ac_save_CFLAGS=$CFLAGS
1664 echo "$as_me:1664: checking whether $CC accepts -g" >&5
1665 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
1666 if test "${ac_cv_prog_cc_g+set}" = set; then
1667 echo $ECHO_N "(cached) $ECHO_C" >&6
1669 cat >conftest.$ac_ext <<_ACEOF
1670 #line 1670 "configure"
1671 #include "confdefs.h"
1681 rm -f conftest.$ac_objext
1682 if { (eval echo "$as_me:1682: \"$ac_compile\"") >&5
1683 (eval $ac_compile) 2>&5
1685 echo "$as_me:1685: \$? = $ac_status" >&5
1686 (exit $ac_status); } &&
1687 { ac_try='test -s conftest.$ac_objext'
1688 { (eval echo "$as_me:1688: \"$ac_try\"") >&5
1691 echo "$as_me:1691: \$? = $ac_status" >&5
1692 (exit $ac_status); }; }; then
1695 echo "$as_me: failed program was:" >&5
1696 cat conftest.$ac_ext >&5
1699 rm -f conftest.$ac_objext conftest.$ac_ext
1701 echo "$as_me:1701: result: $ac_cv_prog_cc_g" >&5
1702 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
1703 if test "$ac_test_CFLAGS" = set; then
1704 CFLAGS=$ac_save_CFLAGS
1705 elif test $ac_cv_prog_cc_g = yes; then
1706 if test "$GCC" = yes; then
1712 if test "$GCC" = yes; then
1718 # Some people use a C++ compiler to compile C. Since we use `exit',
1719 # in C++ we need to declare it. In case someone uses the same compiler
1720 # for both compiling C and C++ we need to have the C++ compiler decide
1721 # the declaration of exit, since it's the most demanding environment.
1722 cat >conftest.$ac_ext <<_ACEOF
1727 rm -f conftest.$ac_objext
1728 if { (eval echo "$as_me:1728: \"$ac_compile\"") >&5
1729 (eval $ac_compile) 2>&5
1731 echo "$as_me:1731: \$? = $ac_status" >&5
1732 (exit $ac_status); } &&
1733 { ac_try='test -s conftest.$ac_objext'
1734 { (eval echo "$as_me:1734: \"$ac_try\"") >&5
1737 echo "$as_me:1737: \$? = $ac_status" >&5
1738 (exit $ac_status); }; }; then
1739 for ac_declaration in \
1741 '#include <stdlib.h>' \
1742 'extern "C" void std::exit (int) throw (); using std::exit;' \
1743 'extern "C" void std::exit (int); using std::exit;' \
1744 'extern "C" void exit (int) throw ();' \
1745 'extern "C" void exit (int);' \
1748 cat >conftest.$ac_ext <<_ACEOF
1749 #line 1749 "configure"
1750 #include "confdefs.h"
1761 rm -f conftest.$ac_objext
1762 if { (eval echo "$as_me:1762: \"$ac_compile\"") >&5
1763 (eval $ac_compile) 2>&5
1765 echo "$as_me:1765: \$? = $ac_status" >&5
1766 (exit $ac_status); } &&
1767 { ac_try='test -s conftest.$ac_objext'
1768 { (eval echo "$as_me:1768: \"$ac_try\"") >&5
1771 echo "$as_me:1771: \$? = $ac_status" >&5
1772 (exit $ac_status); }; }; then
1775 echo "$as_me: failed program was:" >&5
1776 cat conftest.$ac_ext >&5
1779 rm -f conftest.$ac_objext conftest.$ac_ext
1780 cat >conftest.$ac_ext <<_ACEOF
1781 #line 1781 "configure"
1782 #include "confdefs.h"
1792 rm -f conftest.$ac_objext
1793 if { (eval echo "$as_me:1793: \"$ac_compile\"") >&5
1794 (eval $ac_compile) 2>&5
1796 echo "$as_me:1796: \$? = $ac_status" >&5
1797 (exit $ac_status); } &&
1798 { ac_try='test -s conftest.$ac_objext'
1799 { (eval echo "$as_me:1799: \"$ac_try\"") >&5
1802 echo "$as_me:1802: \$? = $ac_status" >&5
1803 (exit $ac_status); }; }; then
1806 echo "$as_me: failed program was:" >&5
1807 cat conftest.$ac_ext >&5
1809 rm -f conftest.$ac_objext conftest.$ac_ext
1812 if test -n "$ac_declaration"; then
1813 echo '#ifdef __cplusplus' >>confdefs.h
1814 echo $ac_declaration >>confdefs.h
1815 echo '#endif' >>confdefs.h
1819 echo "$as_me: failed program was:" >&5
1820 cat conftest.$ac_ext >&5
1822 rm -f conftest.$ac_objext conftest.$ac_ext
1824 ac_cpp='$CPP $CPPFLAGS'
1825 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1826 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1827 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1828 ac_main_return=return
1831 if test "$GCC" = yes ; then
1832 echo "$as_me:1832: checking version of $CC" >&5
1833 echo $ECHO_N "checking version of $CC... $ECHO_C" >&6
1834 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.].*//'`"
1835 test -z "$GCC_VERSION" && GCC_VERSION=unknown
1836 echo "$as_me:1836: result: $GCC_VERSION" >&5
1837 echo "${ECHO_T}$GCC_VERSION" >&6
1840 echo "$as_me:1840: checking for $CC option to accept ANSI C" >&5
1841 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
1842 if test "${ac_cv_prog_cc_stdc+set}" = set; then
1843 echo $ECHO_N "(cached) $ECHO_C" >&6
1845 ac_cv_prog_cc_stdc=no
1847 cat >conftest.$ac_ext <<_ACEOF
1848 #line 1848 "configure"
1849 #include "confdefs.h"
1852 #include <sys/types.h>
1853 #include <sys/stat.h>
1854 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
1855 struct buf { int x; };
1856 FILE * (*rcsopen) (struct buf *, struct stat *, int);
1857 static char *e (p, i)
1863 static char *f (char * (*g) (char **, int), char **p, ...)
1868 s = g (p, va_arg (v,int));
1872 int test (int i, double x);
1873 struct s1 {int (*f) (int a);};
1874 struct s2 {int (*f) (double a);};
1875 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
1881 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
1886 # Don't try gcc -ansi; that turns off useful extensions and
1887 # breaks some systems' header files.
1888 # AIX -qlanglvl=ansi
1889 # Ultrix and OSF/1 -std1
1890 # HP-UX 10.20 and later -Ae
1891 # HP-UX older versions -Aa -D_HPUX_SOURCE
1892 # SVR4 -Xc -D__EXTENSIONS__
1893 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
1895 CC="$ac_save_CC $ac_arg"
1896 rm -f conftest.$ac_objext
1897 if { (eval echo "$as_me:1897: \"$ac_compile\"") >&5
1898 (eval $ac_compile) 2>&5
1900 echo "$as_me:1900: \$? = $ac_status" >&5
1901 (exit $ac_status); } &&
1902 { ac_try='test -s conftest.$ac_objext'
1903 { (eval echo "$as_me:1903: \"$ac_try\"") >&5
1906 echo "$as_me:1906: \$? = $ac_status" >&5
1907 (exit $ac_status); }; }; then
1908 ac_cv_prog_cc_stdc=$ac_arg
1911 echo "$as_me: failed program was:" >&5
1912 cat conftest.$ac_ext >&5
1914 rm -f conftest.$ac_objext
1916 rm -f conftest.$ac_ext conftest.$ac_objext
1921 case "x$ac_cv_prog_cc_stdc" in
1923 echo "$as_me:1923: result: none needed" >&5
1924 echo "${ECHO_T}none needed" >&6 ;;
1926 echo "$as_me:1926: result: $ac_cv_prog_cc_stdc" >&5
1927 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
1928 CC="$CC $ac_cv_prog_cc_stdc" ;;
1931 # This should have been defined by AC_PROG_CC
1934 echo "$as_me:1934: checking \$CC variable" >&5
1935 echo $ECHO_N "checking \$CC variable... $ECHO_C" >&6
1938 echo "$as_me:1938: result: broken" >&5
1939 echo "${ECHO_T}broken" >&6
1940 { echo "$as_me:1940: WARNING: your environment misuses the CC variable to hold CFLAGS/CPPFLAGS options" >&5
1941 echo "$as_me: WARNING: your environment misuses the CC variable to hold CFLAGS/CPPFLAGS options" >&2;}
1943 cf_flags=`echo "$CC" | sed -e 's/^[^ ]*[ ]//'`
1944 CC=`echo "$CC" | sed -e 's/[ ].*//'`
1949 cf_new_extra_cppflags=
1951 for cf_add_cflags in $cf_flags
1953 case $cf_fix_cppflags in
1955 case $cf_add_cflags in #(vi
1956 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
1957 case $cf_add_cflags in
1959 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
1961 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
1962 && test -z "${cf_tst_cflags}" \
1963 && cf_fix_cppflags=yes
1965 if test $cf_fix_cppflags = yes ; then
1966 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
1968 elif test "${cf_tst_cflags}" = "\"'" ; then
1969 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
1975 *$cf_add_cflags) #(vi
1978 case $cf_add_cflags in #(vi
1980 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
1982 CPPFLAGS=`echo "$CPPFLAGS" | \
1983 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
1984 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
1988 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
1993 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
1998 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2000 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
2002 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
2003 && test -z "${cf_tst_cflags}" \
2004 && cf_fix_cppflags=no
2009 if test -n "$cf_new_cflags" ; then
2011 CFLAGS="$CFLAGS $cf_new_cflags"
2014 if test -n "$cf_new_cppflags" ; then
2016 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
2019 if test -n "$cf_new_extra_cppflags" ; then
2021 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
2026 echo "$as_me:2026: result: ok" >&5
2027 echo "${ECHO_T}ok" >&6
2032 ac_cpp='$CPP $CPPFLAGS'
2033 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2034 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2035 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2036 ac_main_return=return
2037 echo "$as_me:2037: checking how to run the C preprocessor" >&5
2038 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
2039 # On Suns, sometimes $CPP names a directory.
2040 if test -n "$CPP" && test -d "$CPP"; then
2043 if test -z "$CPP"; then
2044 if test "${ac_cv_prog_CPP+set}" = set; then
2045 echo $ECHO_N "(cached) $ECHO_C" >&6
2047 # Double quotes because CPP needs to be expanded
2048 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
2051 for ac_c_preproc_warn_flag in '' yes
2053 # Use a header file that comes with gcc, so configuring glibc
2054 # with a fresh cross-compiler works.
2055 # On the NeXT, cc -E runs the code through the compiler's parser,
2056 # not just through cpp. "Syntax error" is here to catch this case.
2057 cat >conftest.$ac_ext <<_ACEOF
2058 #line 2058 "configure"
2059 #include "confdefs.h"
2063 if { (eval echo "$as_me:2063: \"$ac_cpp conftest.$ac_ext\"") >&5
2064 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2066 egrep -v '^ *\+' conftest.er1 >conftest.err
2068 cat conftest.err >&5
2069 echo "$as_me:2069: \$? = $ac_status" >&5
2070 (exit $ac_status); } >/dev/null; then
2071 if test -s conftest.err; then
2072 ac_cpp_err=$ac_c_preproc_warn_flag
2079 if test -z "$ac_cpp_err"; then
2082 echo "$as_me: failed program was:" >&5
2083 cat conftest.$ac_ext >&5
2084 # Broken: fails on valid input.
2087 rm -f conftest.err conftest.$ac_ext
2089 # OK, works on sane cases. Now check whether non-existent headers
2090 # can be detected and how.
2091 cat >conftest.$ac_ext <<_ACEOF
2092 #line 2092 "configure"
2093 #include "confdefs.h"
2094 #include <ac_nonexistent.h>
2096 if { (eval echo "$as_me:2096: \"$ac_cpp conftest.$ac_ext\"") >&5
2097 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2099 egrep -v '^ *\+' conftest.er1 >conftest.err
2101 cat conftest.err >&5
2102 echo "$as_me:2102: \$? = $ac_status" >&5
2103 (exit $ac_status); } >/dev/null; then
2104 if test -s conftest.err; then
2105 ac_cpp_err=$ac_c_preproc_warn_flag
2112 if test -z "$ac_cpp_err"; then
2113 # Broken: success on invalid input.
2116 echo "$as_me: failed program was:" >&5
2117 cat conftest.$ac_ext >&5
2118 # Passes both tests.
2122 rm -f conftest.err conftest.$ac_ext
2125 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2126 rm -f conftest.err conftest.$ac_ext
2127 if $ac_preproc_ok; then
2139 echo "$as_me:2139: result: $CPP" >&5
2140 echo "${ECHO_T}$CPP" >&6
2142 for ac_c_preproc_warn_flag in '' yes
2144 # Use a header file that comes with gcc, so configuring glibc
2145 # with a fresh cross-compiler works.
2146 # On the NeXT, cc -E runs the code through the compiler's parser,
2147 # not just through cpp. "Syntax error" is here to catch this case.
2148 cat >conftest.$ac_ext <<_ACEOF
2149 #line 2149 "configure"
2150 #include "confdefs.h"
2154 if { (eval echo "$as_me:2154: \"$ac_cpp conftest.$ac_ext\"") >&5
2155 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2157 egrep -v '^ *\+' conftest.er1 >conftest.err
2159 cat conftest.err >&5
2160 echo "$as_me:2160: \$? = $ac_status" >&5
2161 (exit $ac_status); } >/dev/null; then
2162 if test -s conftest.err; then
2163 ac_cpp_err=$ac_c_preproc_warn_flag
2170 if test -z "$ac_cpp_err"; then
2173 echo "$as_me: failed program was:" >&5
2174 cat conftest.$ac_ext >&5
2175 # Broken: fails on valid input.
2178 rm -f conftest.err conftest.$ac_ext
2180 # OK, works on sane cases. Now check whether non-existent headers
2181 # can be detected and how.
2182 cat >conftest.$ac_ext <<_ACEOF
2183 #line 2183 "configure"
2184 #include "confdefs.h"
2185 #include <ac_nonexistent.h>
2187 if { (eval echo "$as_me:2187: \"$ac_cpp conftest.$ac_ext\"") >&5
2188 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2190 egrep -v '^ *\+' conftest.er1 >conftest.err
2192 cat conftest.err >&5
2193 echo "$as_me:2193: \$? = $ac_status" >&5
2194 (exit $ac_status); } >/dev/null; then
2195 if test -s conftest.err; then
2196 ac_cpp_err=$ac_c_preproc_warn_flag
2203 if test -z "$ac_cpp_err"; then
2204 # Broken: success on invalid input.
2207 echo "$as_me: failed program was:" >&5
2208 cat conftest.$ac_ext >&5
2209 # Passes both tests.
2213 rm -f conftest.err conftest.$ac_ext
2216 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2217 rm -f conftest.err conftest.$ac_ext
2218 if $ac_preproc_ok; then
2221 { { echo "$as_me:2221: error: C preprocessor \"$CPP\" fails sanity check" >&5
2222 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;}
2223 { (exit 1); exit 1; }; }
2227 ac_cpp='$CPP $CPPFLAGS'
2228 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2229 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2230 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2231 ac_main_return=return
2233 for ac_prog in mawk gawk nawk awk
2235 # Extract the first word of "$ac_prog", so it can be a program name with args.
2236 set dummy $ac_prog; ac_word=$2
2237 echo "$as_me:2237: checking for $ac_word" >&5
2238 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2239 if test "${ac_cv_prog_AWK+set}" = set; then
2240 echo $ECHO_N "(cached) $ECHO_C" >&6
2242 if test -n "$AWK"; then
2243 ac_cv_prog_AWK="$AWK" # Let the user override the test.
2245 ac_save_IFS=$IFS; IFS=$ac_path_separator
2247 for ac_dir in $ac_dummy; do
2249 test -z "$ac_dir" && ac_dir=.
2250 $as_executable_p "$ac_dir/$ac_word" || continue
2251 ac_cv_prog_AWK="$ac_prog"
2252 echo "$as_me:2252: found $ac_dir/$ac_word" >&5
2259 if test -n "$AWK"; then
2260 echo "$as_me:2260: result: $AWK" >&5
2261 echo "${ECHO_T}$AWK" >&6
2263 echo "$as_me:2263: result: no" >&5
2264 echo "${ECHO_T}no" >&6
2267 test -n "$AWK" && break
2270 # Find a good install program. We prefer a C program (faster),
2271 # so one script is as good as another. But avoid the broken or
2272 # incompatible versions:
2273 # SysV /etc/install, /usr/sbin/install
2274 # SunOS /usr/etc/install
2275 # IRIX /sbin/install
2277 # AmigaOS /C/install, which installs bootblocks on floppy discs
2278 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
2279 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
2280 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
2281 # ./install, which can be erroneously created by make from ./install.sh.
2282 echo "$as_me:2282: checking for a BSD compatible install" >&5
2283 echo $ECHO_N "checking for a BSD compatible install... $ECHO_C" >&6
2284 if test -z "$INSTALL"; then
2285 if test "${ac_cv_path_install+set}" = set; then
2286 echo $ECHO_N "(cached) $ECHO_C" >&6
2288 ac_save_IFS=$IFS; IFS=$ac_path_separator
2289 for ac_dir in $PATH; do
2291 # Account for people who put trailing slashes in PATH elements.
2293 / | ./ | .// | /cC/* \
2294 | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* \
2297 # OSF1 and SCO ODT 3.0 have their own names for install.
2298 # Don't use installbsd from OSF since it installs stuff as root
2300 for ac_prog in ginstall scoinst install; do
2301 if $as_executable_p "$ac_dir/$ac_prog"; then
2302 if test $ac_prog = install &&
2303 grep dspmsg "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2304 # AIX install. It has an incompatible calling convention.
2306 elif test $ac_prog = install &&
2307 grep pwplus "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2308 # program-specific install script used by HP pwplus--don't use.
2311 ac_cv_path_install="$ac_dir/$ac_prog -c"
2321 if test "${ac_cv_path_install+set}" = set; then
2322 INSTALL=$ac_cv_path_install
2324 # As a last resort, use the slow shell script. We don't cache a
2325 # path for INSTALL within a source directory, because that will
2326 # break other packages using the cache if that directory is
2327 # removed, or if the path is relative.
2328 INSTALL=$ac_install_sh
2331 echo "$as_me:2331: result: $INSTALL" >&5
2332 echo "${ECHO_T}$INSTALL" >&6
2334 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
2335 # It thinks the first close brace ends the variable substitution.
2336 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
2338 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
2340 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
2346 cf_dir=`echo $INSTALL | sed -e 's%/[^/]*$%%'`
2347 test -z "$cf_dir" && cf_dir=.
2348 INSTALL=`cd $cf_dir && pwd`/`echo $INSTALL | sed -e 's%^.*/%%'`
2352 for ac_prog in tdlint lint alint splint lclint
2354 # Extract the first word of "$ac_prog", so it can be a program name with args.
2355 set dummy $ac_prog; ac_word=$2
2356 echo "$as_me:2356: checking for $ac_word" >&5
2357 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2358 if test "${ac_cv_prog_LINT+set}" = set; then
2359 echo $ECHO_N "(cached) $ECHO_C" >&6
2361 if test -n "$LINT"; then
2362 ac_cv_prog_LINT="$LINT" # Let the user override the test.
2364 ac_save_IFS=$IFS; IFS=$ac_path_separator
2366 for ac_dir in $ac_dummy; do
2368 test -z "$ac_dir" && ac_dir=.
2369 $as_executable_p "$ac_dir/$ac_word" || continue
2370 ac_cv_prog_LINT="$ac_prog"
2371 echo "$as_me:2371: found $ac_dir/$ac_word" >&5
2377 LINT=$ac_cv_prog_LINT
2378 if test -n "$LINT"; then
2379 echo "$as_me:2379: result: $LINT" >&5
2380 echo "${ECHO_T}$LINT" >&6
2382 echo "$as_me:2382: result: no" >&5
2383 echo "${ECHO_T}no" >&6
2386 test -n "$LINT" && break
2389 echo "$as_me:2389: checking if filesystem supports mixed-case filenames" >&5
2390 echo $ECHO_N "checking if filesystem supports mixed-case filenames... $ECHO_C" >&6
2391 if test "${cf_cv_mixedcase+set}" = set; then
2392 echo $ECHO_N "(cached) $ECHO_C" >&6
2395 if test "$cross_compiling" = yes ; then
2396 case $target_alias in #(vi
2397 *-os2-emx*|*-msdosdjgpp*|*-cygwin*|*-msys*|*-mingw32*|*-uwin*) #(vi
2405 rm -f conftest CONFTEST
2407 if test -f CONFTEST ; then
2412 rm -f conftest CONFTEST
2416 echo "$as_me:2416: result: $cf_cv_mixedcase" >&5
2417 echo "${ECHO_T}$cf_cv_mixedcase" >&6
2418 test "$cf_cv_mixedcase" = yes &&
2419 cat >>confdefs.h <<\EOF
2420 #define MIXEDCASE_FILENAMES 1
2423 for ac_prog in exctags ctags
2425 # Extract the first word of "$ac_prog", so it can be a program name with args.
2426 set dummy $ac_prog; ac_word=$2
2427 echo "$as_me:2427: checking for $ac_word" >&5
2428 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2429 if test "${ac_cv_prog_CTAGS+set}" = set; then
2430 echo $ECHO_N "(cached) $ECHO_C" >&6
2432 if test -n "$CTAGS"; then
2433 ac_cv_prog_CTAGS="$CTAGS" # Let the user override the test.
2435 ac_save_IFS=$IFS; IFS=$ac_path_separator
2437 for ac_dir in $ac_dummy; do
2439 test -z "$ac_dir" && ac_dir=.
2440 $as_executable_p "$ac_dir/$ac_word" || continue
2441 ac_cv_prog_CTAGS="$ac_prog"
2442 echo "$as_me:2442: found $ac_dir/$ac_word" >&5
2448 CTAGS=$ac_cv_prog_CTAGS
2449 if test -n "$CTAGS"; then
2450 echo "$as_me:2450: result: $CTAGS" >&5
2451 echo "${ECHO_T}$CTAGS" >&6
2453 echo "$as_me:2453: result: no" >&5
2454 echo "${ECHO_T}no" >&6
2457 test -n "$CTAGS" && break
2460 for ac_prog in exetags etags
2462 # Extract the first word of "$ac_prog", so it can be a program name with args.
2463 set dummy $ac_prog; ac_word=$2
2464 echo "$as_me:2464: checking for $ac_word" >&5
2465 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2466 if test "${ac_cv_prog_ETAGS+set}" = set; then
2467 echo $ECHO_N "(cached) $ECHO_C" >&6
2469 if test -n "$ETAGS"; then
2470 ac_cv_prog_ETAGS="$ETAGS" # Let the user override the test.
2472 ac_save_IFS=$IFS; IFS=$ac_path_separator
2474 for ac_dir in $ac_dummy; do
2476 test -z "$ac_dir" && ac_dir=.
2477 $as_executable_p "$ac_dir/$ac_word" || continue
2478 ac_cv_prog_ETAGS="$ac_prog"
2479 echo "$as_me:2479: found $ac_dir/$ac_word" >&5
2485 ETAGS=$ac_cv_prog_ETAGS
2486 if test -n "$ETAGS"; then
2487 echo "$as_me:2487: result: $ETAGS" >&5
2488 echo "${ECHO_T}$ETAGS" >&6
2490 echo "$as_me:2490: result: no" >&5
2491 echo "${ECHO_T}no" >&6
2494 test -n "$ETAGS" && break
2497 # Extract the first word of "${CTAGS:-ctags}", so it can be a program name with args.
2498 set dummy ${CTAGS:-ctags}; ac_word=$2
2499 echo "$as_me:2499: checking for $ac_word" >&5
2500 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2501 if test "${ac_cv_prog_MAKE_LOWER_TAGS+set}" = set; then
2502 echo $ECHO_N "(cached) $ECHO_C" >&6
2504 if test -n "$MAKE_LOWER_TAGS"; then
2505 ac_cv_prog_MAKE_LOWER_TAGS="$MAKE_LOWER_TAGS" # Let the user override the test.
2507 ac_save_IFS=$IFS; IFS=$ac_path_separator
2509 for ac_dir in $ac_dummy; do
2511 test -z "$ac_dir" && ac_dir=.
2512 $as_executable_p "$ac_dir/$ac_word" || continue
2513 ac_cv_prog_MAKE_LOWER_TAGS="yes"
2514 echo "$as_me:2514: found $ac_dir/$ac_word" >&5
2518 test -z "$ac_cv_prog_MAKE_LOWER_TAGS" && ac_cv_prog_MAKE_LOWER_TAGS="no"
2521 MAKE_LOWER_TAGS=$ac_cv_prog_MAKE_LOWER_TAGS
2522 if test -n "$MAKE_LOWER_TAGS"; then
2523 echo "$as_me:2523: result: $MAKE_LOWER_TAGS" >&5
2524 echo "${ECHO_T}$MAKE_LOWER_TAGS" >&6
2526 echo "$as_me:2526: result: no" >&5
2527 echo "${ECHO_T}no" >&6
2530 if test "$cf_cv_mixedcase" = yes ; then
2531 # Extract the first word of "${ETAGS:-etags}", so it can be a program name with args.
2532 set dummy ${ETAGS:-etags}; ac_word=$2
2533 echo "$as_me:2533: checking for $ac_word" >&5
2534 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2535 if test "${ac_cv_prog_MAKE_UPPER_TAGS+set}" = set; then
2536 echo $ECHO_N "(cached) $ECHO_C" >&6
2538 if test -n "$MAKE_UPPER_TAGS"; then
2539 ac_cv_prog_MAKE_UPPER_TAGS="$MAKE_UPPER_TAGS" # Let the user override the test.
2541 ac_save_IFS=$IFS; IFS=$ac_path_separator
2543 for ac_dir in $ac_dummy; do
2545 test -z "$ac_dir" && ac_dir=.
2546 $as_executable_p "$ac_dir/$ac_word" || continue
2547 ac_cv_prog_MAKE_UPPER_TAGS="yes"
2548 echo "$as_me:2548: found $ac_dir/$ac_word" >&5
2552 test -z "$ac_cv_prog_MAKE_UPPER_TAGS" && ac_cv_prog_MAKE_UPPER_TAGS="no"
2555 MAKE_UPPER_TAGS=$ac_cv_prog_MAKE_UPPER_TAGS
2556 if test -n "$MAKE_UPPER_TAGS"; then
2557 echo "$as_me:2557: result: $MAKE_UPPER_TAGS" >&5
2558 echo "${ECHO_T}$MAKE_UPPER_TAGS" >&6
2560 echo "$as_me:2560: result: no" >&5
2561 echo "${ECHO_T}no" >&6
2568 if test "$MAKE_UPPER_TAGS" = yes ; then
2574 if test "$MAKE_LOWER_TAGS" = yes ; then
2580 echo "$as_me:2580: checking if -lm needed for math functions" >&5
2581 echo $ECHO_N "checking if -lm needed for math functions... $ECHO_C" >&6
2582 if test "${cf_cv_need_libm+set}" = set; then
2583 echo $ECHO_N "(cached) $ECHO_C" >&6
2586 cat >conftest.$ac_ext <<_ACEOF
2587 #line 2587 "configure"
2588 #include "confdefs.h"
2596 double x = rand(); printf("result = %g\n", pow(sin(x),x))
2601 rm -f conftest.$ac_objext conftest$ac_exeext
2602 if { (eval echo "$as_me:2602: \"$ac_link\"") >&5
2603 (eval $ac_link) 2>&5
2605 echo "$as_me:2605: \$? = $ac_status" >&5
2606 (exit $ac_status); } &&
2607 { ac_try='test -s conftest$ac_exeext'
2608 { (eval echo "$as_me:2608: \"$ac_try\"") >&5
2611 echo "$as_me:2611: \$? = $ac_status" >&5
2612 (exit $ac_status); }; }; then
2615 echo "$as_me: failed program was:" >&5
2616 cat conftest.$ac_ext >&5
2619 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
2621 echo "$as_me:2621: result: $cf_cv_need_libm" >&5
2622 echo "${ECHO_T}$cf_cv_need_libm" >&6
2623 if test "$cf_cv_need_libm" = yes
2631 CC_SHARED_OPTS=unknown
2632 CPPFLAGS="$CPPFLAGS"
2634 DFT_OBJ_SUBDIR=`pwd|sed -e's:.*/::'`
2635 DFT_UPR_MODEL="NORMAL"
2652 TINFO_LIBS='$(LIBS_CURSES)'
2653 cf_cv_abi_version=""
2654 cf_cv_rel_version=""
2659 if test "$GCC" = yes
2661 cat > conftest.i <<EOF
2663 #define GCC_PRINTF 0
2668 #ifndef GCC_NORETURN
2669 #define GCC_NORETURN /* nothing */
2672 #define GCC_UNUSED /* nothing */
2675 if test "$GCC" = yes
2677 { echo "$as_me:2677: checking for $CC __attribute__ directives..." >&5
2678 echo "$as_me: checking for $CC __attribute__ directives..." >&6;}
2679 cat > conftest.$ac_ext <<EOF
2680 #line 2680 "${as_me:-configure}"
2681 #include "confdefs.h"
2682 #include "conftest.h"
2683 #include "conftest.i"
2685 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
2687 #define GCC_PRINTFLIKE(fmt,var) /*nothing*/
2690 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
2692 #define GCC_SCANFLIKE(fmt,var) /*nothing*/
2694 extern void wow(char *,...) GCC_SCANFLIKE(1,2);
2695 extern void oops(char *,...) GCC_PRINTFLIKE(1,2) GCC_NORETURN;
2696 extern void foo(void) GCC_NORETURN;
2697 int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { return 0; }
2699 cf_printf_attribute=no
2700 cf_scanf_attribute=no
2701 for cf_attribute in scanf printf unused noreturn
2704 cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
2706 cf_directive="__attribute__(($cf_attribute))"
2707 echo "checking for $CC $cf_directive" 1>&5
2709 case $cf_attribute in #(vi
2711 cf_printf_attribute=yes
2712 cat >conftest.h <<EOF
2713 #define GCC_$cf_ATTRIBUTE 1
2717 cf_scanf_attribute=yes
2718 cat >conftest.h <<EOF
2719 #define GCC_$cf_ATTRIBUTE 1
2723 cat >conftest.h <<EOF
2724 #define GCC_$cf_ATTRIBUTE $cf_directive
2729 if { (eval echo "$as_me:2729: \"$ac_compile\"") >&5
2730 (eval $ac_compile) 2>&5
2732 echo "$as_me:2732: \$? = $ac_status" >&5
2733 (exit $ac_status); }; then
2734 test -n "$verbose" && echo "$as_me:2734: result: ... $cf_attribute" >&5
2735 echo "${ECHO_T}... $cf_attribute" >&6
2736 cat conftest.h >>confdefs.h
2737 case $cf_attribute in #(vi
2740 cat >>confdefs.h <<EOF
2741 #define GCC_NORETURN $cf_directive
2746 cf_value='/* nothing */'
2747 if test "$cf_printf_attribute" != no ; then
2748 cf_value='__attribute__((format(printf,fmt,var)))'
2750 cat >>confdefs.h <<\EOF
2751 #define GCC_PRINTF 1
2756 cat >>confdefs.h <<EOF
2757 #define GCC_PRINTFLIKE(fmt,var) $cf_value
2762 cf_value='/* nothing */'
2763 if test "$cf_scanf_attribute" != no ; then
2764 cf_value='__attribute__((format(scanf,fmt,var)))'
2766 cat >>confdefs.h <<\EOF
2772 cat >>confdefs.h <<EOF
2773 #define GCC_SCANFLIKE(fmt,var) $cf_value
2779 cat >>confdefs.h <<EOF
2780 #define GCC_UNUSED $cf_directive
2788 fgrep define conftest.i >>confdefs.h
2794 cf_POSIX_C_SOURCE=199506L
2797 case $host_os in #(vi
2799 cf_xopen_source="-D_ALL_SOURCE"
2805 cf_xopen_source="-D_APPLE_C_SOURCE"
2808 cf_xopen_source="-D_DARWIN_C_SOURCE"
2811 freebsd*|dragonfly*) #(vi
2812 # 5.x headers associate
2813 # _XOPEN_SOURCE=600 with _POSIX_C_SOURCE=200112L
2814 # _XOPEN_SOURCE=500 with _POSIX_C_SOURCE=199506L
2815 cf_POSIX_C_SOURCE=200112L
2817 cf_xopen_source="-D_BSD_TYPES -D__BSD_VISIBLE -D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
2820 cf_xopen_source="-D_HPUX_SOURCE -D_XOPEN_SOURCE=500"
2823 cf_xopen_source="-D_HPUX_SOURCE"
2826 cf_xopen_source="-D_SGI_SOURCE"
2829 linux*|gnu*|mint*|k*bsd*-gnu) #(vi
2831 echo "$as_me:2831: checking if we must define _GNU_SOURCE" >&5
2832 echo $ECHO_N "checking if we must define _GNU_SOURCE... $ECHO_C" >&6
2833 if test "${cf_cv_gnu_source+set}" = set; then
2834 echo $ECHO_N "(cached) $ECHO_C" >&6
2837 cat >conftest.$ac_ext <<_ACEOF
2838 #line 2838 "configure"
2839 #include "confdefs.h"
2840 #include <sys/types.h>
2845 #ifndef _XOPEN_SOURCE
2852 rm -f conftest.$ac_objext
2853 if { (eval echo "$as_me:2853: \"$ac_compile\"") >&5
2854 (eval $ac_compile) 2>&5
2856 echo "$as_me:2856: \$? = $ac_status" >&5
2857 (exit $ac_status); } &&
2858 { ac_try='test -s conftest.$ac_objext'
2859 { (eval echo "$as_me:2859: \"$ac_try\"") >&5
2862 echo "$as_me:2862: \$? = $ac_status" >&5
2863 (exit $ac_status); }; }; then
2866 echo "$as_me: failed program was:" >&5
2867 cat conftest.$ac_ext >&5
2869 CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE"
2870 cat >conftest.$ac_ext <<_ACEOF
2871 #line 2871 "configure"
2872 #include "confdefs.h"
2873 #include <sys/types.h>
2878 #ifdef _XOPEN_SOURCE
2885 rm -f conftest.$ac_objext
2886 if { (eval echo "$as_me:2886: \"$ac_compile\"") >&5
2887 (eval $ac_compile) 2>&5
2889 echo "$as_me:2889: \$? = $ac_status" >&5
2890 (exit $ac_status); } &&
2891 { ac_try='test -s conftest.$ac_objext'
2892 { (eval echo "$as_me:2892: \"$ac_try\"") >&5
2895 echo "$as_me:2895: \$? = $ac_status" >&5
2896 (exit $ac_status); }; }; then
2899 echo "$as_me: failed program was:" >&5
2900 cat conftest.$ac_ext >&5
2901 cf_cv_gnu_source=yes
2903 rm -f conftest.$ac_objext conftest.$ac_ext
2907 rm -f conftest.$ac_objext conftest.$ac_ext
2910 echo "$as_me:2910: result: $cf_cv_gnu_source" >&5
2911 echo "${ECHO_T}$cf_cv_gnu_source" >&6
2912 test "$cf_cv_gnu_source" = yes && CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE"
2916 # setting _XOPEN_SOURCE or _POSIX_SOURCE breaks <sys/select.h> and other headers which use u_int / u_short types
2919 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
2921 cf_save_CFLAGS="$CFLAGS"
2922 cf_save_CPPFLAGS="$CPPFLAGS"
2924 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
2925 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
2926 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
2928 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
2929 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
2930 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
2932 echo "$as_me:2932: checking if we should define _POSIX_C_SOURCE" >&5
2933 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
2934 if test "${cf_cv_posix_c_source+set}" = set; then
2935 echo $ECHO_N "(cached) $ECHO_C" >&6
2938 echo "${as_me:-configure}:2938: testing if the symbol is already defined go no further ..." 1>&5
2940 cat >conftest.$ac_ext <<_ACEOF
2941 #line 2941 "configure"
2942 #include "confdefs.h"
2943 #include <sys/types.h>
2948 #ifndef _POSIX_C_SOURCE
2955 rm -f conftest.$ac_objext
2956 if { (eval echo "$as_me:2956: \"$ac_compile\"") >&5
2957 (eval $ac_compile) 2>&5
2959 echo "$as_me:2959: \$? = $ac_status" >&5
2960 (exit $ac_status); } &&
2961 { ac_try='test -s conftest.$ac_objext'
2962 { (eval echo "$as_me:2962: \"$ac_try\"") >&5
2965 echo "$as_me:2965: \$? = $ac_status" >&5
2966 (exit $ac_status); }; }; then
2967 cf_cv_posix_c_source=no
2969 echo "$as_me: failed program was:" >&5
2970 cat conftest.$ac_ext >&5
2971 cf_want_posix_source=no
2972 case .$cf_POSIX_C_SOURCE in #(vi
2974 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
2977 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
2978 cf_want_posix_source=yes
2981 cf_want_posix_source=yes
2984 if test "$cf_want_posix_source" = yes ; then
2985 cat >conftest.$ac_ext <<_ACEOF
2986 #line 2986 "configure"
2987 #include "confdefs.h"
2988 #include <sys/types.h>
2993 #ifdef _POSIX_SOURCE
3000 rm -f conftest.$ac_objext
3001 if { (eval echo "$as_me:3001: \"$ac_compile\"") >&5
3002 (eval $ac_compile) 2>&5
3004 echo "$as_me:3004: \$? = $ac_status" >&5
3005 (exit $ac_status); } &&
3006 { ac_try='test -s conftest.$ac_objext'
3007 { (eval echo "$as_me:3007: \"$ac_try\"") >&5
3010 echo "$as_me:3010: \$? = $ac_status" >&5
3011 (exit $ac_status); }; }; then
3014 echo "$as_me: failed program was:" >&5
3015 cat conftest.$ac_ext >&5
3016 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
3018 rm -f conftest.$ac_objext conftest.$ac_ext
3021 echo "${as_me:-configure}:3021: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
3023 CFLAGS="$cf_trim_CFLAGS"
3024 CPPFLAGS="$cf_trim_CPPFLAGS $cf_cv_posix_c_source"
3026 echo "${as_me:-configure}:3026: testing if the second compile does not leave our definition intact error ..." 1>&5
3028 cat >conftest.$ac_ext <<_ACEOF
3029 #line 3029 "configure"
3030 #include "confdefs.h"
3031 #include <sys/types.h>
3036 #ifndef _POSIX_C_SOURCE
3043 rm -f conftest.$ac_objext
3044 if { (eval echo "$as_me:3044: \"$ac_compile\"") >&5
3045 (eval $ac_compile) 2>&5
3047 echo "$as_me:3047: \$? = $ac_status" >&5
3048 (exit $ac_status); } &&
3049 { ac_try='test -s conftest.$ac_objext'
3050 { (eval echo "$as_me:3050: \"$ac_try\"") >&5
3053 echo "$as_me:3053: \$? = $ac_status" >&5
3054 (exit $ac_status); }; }; then
3057 echo "$as_me: failed program was:" >&5
3058 cat conftest.$ac_ext >&5
3059 cf_cv_posix_c_source=no
3061 rm -f conftest.$ac_objext conftest.$ac_ext
3062 CFLAGS="$cf_save_CFLAGS"
3063 CPPFLAGS="$cf_save_CPPFLAGS"
3066 rm -f conftest.$ac_objext conftest.$ac_ext
3069 echo "$as_me:3069: result: $cf_cv_posix_c_source" >&5
3070 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
3072 if test "$cf_cv_posix_c_source" != no ; then
3073 CFLAGS="$cf_trim_CFLAGS"
3074 CPPFLAGS="$cf_trim_CPPFLAGS"
3079 cf_new_extra_cppflags=
3081 for cf_add_cflags in $cf_cv_posix_c_source
3083 case $cf_fix_cppflags in
3085 case $cf_add_cflags in #(vi
3086 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
3087 case $cf_add_cflags in
3089 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3091 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3092 && test -z "${cf_tst_cflags}" \
3093 && cf_fix_cppflags=yes
3095 if test $cf_fix_cppflags = yes ; then
3096 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3098 elif test "${cf_tst_cflags}" = "\"'" ; then
3099 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3105 *$cf_add_cflags) #(vi
3108 case $cf_add_cflags in #(vi
3110 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3112 CPPFLAGS=`echo "$CPPFLAGS" | \
3113 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3114 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3118 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
3123 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
3128 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3130 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
3132 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3133 && test -z "${cf_tst_cflags}" \
3134 && cf_fix_cppflags=no
3139 if test -n "$cf_new_cflags" ; then
3141 CFLAGS="$CFLAGS $cf_new_cflags"
3144 if test -n "$cf_new_cppflags" ; then
3146 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
3149 if test -n "$cf_new_extra_cppflags" ; then
3151 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
3158 cf_xopen_source="-D_NETBSD_SOURCE" # setting _XOPEN_SOURCE breaks IPv6 for lynx on NetBSD 1.6, breaks xterm, is not needed for ncursesw
3161 # setting _XOPEN_SOURCE lower than 500 breaks g++ compile with wchar.h, needed for ncursesw
3162 cf_xopen_source="-D_BSD_SOURCE"
3166 # setting _XOPEN_SOURCE breaks xterm on OpenBSD 2.8, is not needed for ncursesw
3169 cf_xopen_source="-D_OSF_SOURCE"
3172 cf_xopen_source="-D_QNX_SOURCE"
3175 # setting _XOPEN_SOURCE breaks Lynx on SCO Unix / OpenServer
3178 cf_xopen_source="-D__EXTENSIONS__"
3182 echo "$as_me:3182: checking if we should define _XOPEN_SOURCE" >&5
3183 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
3184 if test "${cf_cv_xopen_source+set}" = set; then
3185 echo $ECHO_N "(cached) $ECHO_C" >&6
3188 cat >conftest.$ac_ext <<_ACEOF
3189 #line 3189 "configure"
3190 #include "confdefs.h"
3194 #include <sys/types.h>
3200 #ifndef _XOPEN_SOURCE
3207 rm -f conftest.$ac_objext
3208 if { (eval echo "$as_me:3208: \"$ac_compile\"") >&5
3209 (eval $ac_compile) 2>&5
3211 echo "$as_me:3211: \$? = $ac_status" >&5
3212 (exit $ac_status); } &&
3213 { ac_try='test -s conftest.$ac_objext'
3214 { (eval echo "$as_me:3214: \"$ac_try\"") >&5
3217 echo "$as_me:3217: \$? = $ac_status" >&5
3218 (exit $ac_status); }; }; then
3219 cf_cv_xopen_source=no
3221 echo "$as_me: failed program was:" >&5
3222 cat conftest.$ac_ext >&5
3224 CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
3225 cat >conftest.$ac_ext <<_ACEOF
3226 #line 3226 "configure"
3227 #include "confdefs.h"
3231 #include <sys/types.h>
3237 #ifdef _XOPEN_SOURCE
3244 rm -f conftest.$ac_objext
3245 if { (eval echo "$as_me:3245: \"$ac_compile\"") >&5
3246 (eval $ac_compile) 2>&5
3248 echo "$as_me:3248: \$? = $ac_status" >&5
3249 (exit $ac_status); } &&
3250 { ac_try='test -s conftest.$ac_objext'
3251 { (eval echo "$as_me:3251: \"$ac_try\"") >&5
3254 echo "$as_me:3254: \$? = $ac_status" >&5
3255 (exit $ac_status); }; }; then
3256 cf_cv_xopen_source=no
3258 echo "$as_me: failed program was:" >&5
3259 cat conftest.$ac_ext >&5
3260 cf_cv_xopen_source=$cf_XOPEN_SOURCE
3262 rm -f conftest.$ac_objext conftest.$ac_ext
3266 rm -f conftest.$ac_objext conftest.$ac_ext
3269 echo "$as_me:3269: result: $cf_cv_xopen_source" >&5
3270 echo "${ECHO_T}$cf_cv_xopen_source" >&6
3272 if test "$cf_cv_xopen_source" != no ; then
3274 CFLAGS=`echo "$CFLAGS" | \
3275 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3276 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
3278 CPPFLAGS=`echo "$CPPFLAGS" | \
3279 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3280 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
3282 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
3287 cf_new_extra_cppflags=
3289 for cf_add_cflags in $cf_temp_xopen_source
3291 case $cf_fix_cppflags in
3293 case $cf_add_cflags in #(vi
3294 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
3295 case $cf_add_cflags in
3297 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3299 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3300 && test -z "${cf_tst_cflags}" \
3301 && cf_fix_cppflags=yes
3303 if test $cf_fix_cppflags = yes ; then
3304 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3306 elif test "${cf_tst_cflags}" = "\"'" ; then
3307 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3313 *$cf_add_cflags) #(vi
3316 case $cf_add_cflags in #(vi
3318 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3320 CPPFLAGS=`echo "$CPPFLAGS" | \
3321 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3322 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3326 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
3331 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
3336 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3338 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
3340 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3341 && test -z "${cf_tst_cflags}" \
3342 && cf_fix_cppflags=no
3347 if test -n "$cf_new_cflags" ; then
3349 CFLAGS="$CFLAGS $cf_new_cflags"
3352 if test -n "$cf_new_cppflags" ; then
3354 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
3357 if test -n "$cf_new_extra_cppflags" ; then
3359 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
3364 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
3366 cf_save_CFLAGS="$CFLAGS"
3367 cf_save_CPPFLAGS="$CPPFLAGS"
3369 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
3370 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3371 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
3373 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
3374 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3375 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
3377 echo "$as_me:3377: checking if we should define _POSIX_C_SOURCE" >&5
3378 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
3379 if test "${cf_cv_posix_c_source+set}" = set; then
3380 echo $ECHO_N "(cached) $ECHO_C" >&6
3383 echo "${as_me:-configure}:3383: testing if the symbol is already defined go no further ..." 1>&5
3385 cat >conftest.$ac_ext <<_ACEOF
3386 #line 3386 "configure"
3387 #include "confdefs.h"
3388 #include <sys/types.h>
3393 #ifndef _POSIX_C_SOURCE
3400 rm -f conftest.$ac_objext
3401 if { (eval echo "$as_me:3401: \"$ac_compile\"") >&5
3402 (eval $ac_compile) 2>&5
3404 echo "$as_me:3404: \$? = $ac_status" >&5
3405 (exit $ac_status); } &&
3406 { ac_try='test -s conftest.$ac_objext'
3407 { (eval echo "$as_me:3407: \"$ac_try\"") >&5
3410 echo "$as_me:3410: \$? = $ac_status" >&5
3411 (exit $ac_status); }; }; then
3412 cf_cv_posix_c_source=no
3414 echo "$as_me: failed program was:" >&5
3415 cat conftest.$ac_ext >&5
3416 cf_want_posix_source=no
3417 case .$cf_POSIX_C_SOURCE in #(vi
3419 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
3422 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
3423 cf_want_posix_source=yes
3426 cf_want_posix_source=yes
3429 if test "$cf_want_posix_source" = yes ; then
3430 cat >conftest.$ac_ext <<_ACEOF
3431 #line 3431 "configure"
3432 #include "confdefs.h"
3433 #include <sys/types.h>
3438 #ifdef _POSIX_SOURCE
3445 rm -f conftest.$ac_objext
3446 if { (eval echo "$as_me:3446: \"$ac_compile\"") >&5
3447 (eval $ac_compile) 2>&5
3449 echo "$as_me:3449: \$? = $ac_status" >&5
3450 (exit $ac_status); } &&
3451 { ac_try='test -s conftest.$ac_objext'
3452 { (eval echo "$as_me:3452: \"$ac_try\"") >&5
3455 echo "$as_me:3455: \$? = $ac_status" >&5
3456 (exit $ac_status); }; }; then
3459 echo "$as_me: failed program was:" >&5
3460 cat conftest.$ac_ext >&5
3461 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
3463 rm -f conftest.$ac_objext conftest.$ac_ext
3466 echo "${as_me:-configure}:3466: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
3468 CFLAGS="$cf_trim_CFLAGS"
3469 CPPFLAGS="$cf_trim_CPPFLAGS $cf_cv_posix_c_source"
3471 echo "${as_me:-configure}:3471: testing if the second compile does not leave our definition intact error ..." 1>&5
3473 cat >conftest.$ac_ext <<_ACEOF
3474 #line 3474 "configure"
3475 #include "confdefs.h"
3476 #include <sys/types.h>
3481 #ifndef _POSIX_C_SOURCE
3488 rm -f conftest.$ac_objext
3489 if { (eval echo "$as_me:3489: \"$ac_compile\"") >&5
3490 (eval $ac_compile) 2>&5
3492 echo "$as_me:3492: \$? = $ac_status" >&5
3493 (exit $ac_status); } &&
3494 { ac_try='test -s conftest.$ac_objext'
3495 { (eval echo "$as_me:3495: \"$ac_try\"") >&5
3498 echo "$as_me:3498: \$? = $ac_status" >&5
3499 (exit $ac_status); }; }; then
3502 echo "$as_me: failed program was:" >&5
3503 cat conftest.$ac_ext >&5
3504 cf_cv_posix_c_source=no
3506 rm -f conftest.$ac_objext conftest.$ac_ext
3507 CFLAGS="$cf_save_CFLAGS"
3508 CPPFLAGS="$cf_save_CPPFLAGS"
3511 rm -f conftest.$ac_objext conftest.$ac_ext
3514 echo "$as_me:3514: result: $cf_cv_posix_c_source" >&5
3515 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
3517 if test "$cf_cv_posix_c_source" != no ; then
3518 CFLAGS="$cf_trim_CFLAGS"
3519 CPPFLAGS="$cf_trim_CPPFLAGS"
3524 cf_new_extra_cppflags=
3526 for cf_add_cflags in $cf_cv_posix_c_source
3528 case $cf_fix_cppflags in
3530 case $cf_add_cflags in #(vi
3531 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
3532 case $cf_add_cflags in
3534 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3536 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3537 && test -z "${cf_tst_cflags}" \
3538 && cf_fix_cppflags=yes
3540 if test $cf_fix_cppflags = yes ; then
3541 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3543 elif test "${cf_tst_cflags}" = "\"'" ; then
3544 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3550 *$cf_add_cflags) #(vi
3553 case $cf_add_cflags in #(vi
3555 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3557 CPPFLAGS=`echo "$CPPFLAGS" | \
3558 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3559 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3563 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
3568 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
3573 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3575 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
3577 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3578 && test -z "${cf_tst_cflags}" \
3579 && cf_fix_cppflags=no
3584 if test -n "$cf_new_cflags" ; then
3586 CFLAGS="$CFLAGS $cf_new_cflags"
3589 if test -n "$cf_new_cppflags" ; then
3591 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
3594 if test -n "$cf_new_extra_cppflags" ; then
3596 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
3604 if test -n "$cf_xopen_source" ; then
3609 cf_new_extra_cppflags=
3611 for cf_add_cflags in $cf_xopen_source
3613 case $cf_fix_cppflags in
3615 case $cf_add_cflags in #(vi
3616 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
3617 case $cf_add_cflags in
3619 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3621 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3622 && test -z "${cf_tst_cflags}" \
3623 && cf_fix_cppflags=yes
3625 if test $cf_fix_cppflags = yes ; then
3626 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3628 elif test "${cf_tst_cflags}" = "\"'" ; then
3629 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3635 *$cf_add_cflags) #(vi
3638 case $cf_add_cflags in #(vi
3640 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3642 CPPFLAGS=`echo "$CPPFLAGS" | \
3643 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3644 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3648 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
3653 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
3658 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3660 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
3662 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3663 && test -z "${cf_tst_cflags}" \
3664 && cf_fix_cppflags=no
3669 if test -n "$cf_new_cflags" ; then
3671 CFLAGS="$CFLAGS $cf_new_cflags"
3674 if test -n "$cf_new_cppflags" ; then
3676 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
3679 if test -n "$cf_new_extra_cppflags" ; then
3681 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
3686 if test -n "$cf_XOPEN_SOURCE" && test -z "$cf_cv_xopen_source" ; then
3687 echo "$as_me:3687: checking if _XOPEN_SOURCE really is set" >&5
3688 echo $ECHO_N "checking if _XOPEN_SOURCE really is set... $ECHO_C" >&6
3689 cat >conftest.$ac_ext <<_ACEOF
3690 #line 3690 "configure"
3691 #include "confdefs.h"
3697 #ifndef _XOPEN_SOURCE
3704 rm -f conftest.$ac_objext
3705 if { (eval echo "$as_me:3705: \"$ac_compile\"") >&5
3706 (eval $ac_compile) 2>&5
3708 echo "$as_me:3708: \$? = $ac_status" >&5
3709 (exit $ac_status); } &&
3710 { ac_try='test -s conftest.$ac_objext'
3711 { (eval echo "$as_me:3711: \"$ac_try\"") >&5
3714 echo "$as_me:3714: \$? = $ac_status" >&5
3715 (exit $ac_status); }; }; then
3716 cf_XOPEN_SOURCE_set=yes
3718 echo "$as_me: failed program was:" >&5
3719 cat conftest.$ac_ext >&5
3720 cf_XOPEN_SOURCE_set=no
3722 rm -f conftest.$ac_objext conftest.$ac_ext
3723 echo "$as_me:3723: result: $cf_XOPEN_SOURCE_set" >&5
3724 echo "${ECHO_T}$cf_XOPEN_SOURCE_set" >&6
3725 if test $cf_XOPEN_SOURCE_set = yes
3727 cat >conftest.$ac_ext <<_ACEOF
3728 #line 3728 "configure"
3729 #include "confdefs.h"
3735 #if (_XOPEN_SOURCE - 0) < $cf_XOPEN_SOURCE
3742 rm -f conftest.$ac_objext
3743 if { (eval echo "$as_me:3743: \"$ac_compile\"") >&5
3744 (eval $ac_compile) 2>&5
3746 echo "$as_me:3746: \$? = $ac_status" >&5
3747 (exit $ac_status); } &&
3748 { ac_try='test -s conftest.$ac_objext'
3749 { (eval echo "$as_me:3749: \"$ac_try\"") >&5
3752 echo "$as_me:3752: \$? = $ac_status" >&5
3753 (exit $ac_status); }; }; then
3754 cf_XOPEN_SOURCE_set_ok=yes
3756 echo "$as_me: failed program was:" >&5
3757 cat conftest.$ac_ext >&5
3758 cf_XOPEN_SOURCE_set_ok=no
3760 rm -f conftest.$ac_objext conftest.$ac_ext
3761 if test $cf_XOPEN_SOURCE_set_ok = no
3763 { echo "$as_me:3763: WARNING: _XOPEN_SOURCE is lower than requested" >&5
3764 echo "$as_me: WARNING: _XOPEN_SOURCE is lower than requested" >&2;}
3768 echo "$as_me:3768: checking if we should define _XOPEN_SOURCE" >&5
3769 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
3770 if test "${cf_cv_xopen_source+set}" = set; then
3771 echo $ECHO_N "(cached) $ECHO_C" >&6
3774 cat >conftest.$ac_ext <<_ACEOF
3775 #line 3775 "configure"
3776 #include "confdefs.h"
3780 #include <sys/types.h>
3786 #ifndef _XOPEN_SOURCE
3793 rm -f conftest.$ac_objext
3794 if { (eval echo "$as_me:3794: \"$ac_compile\"") >&5
3795 (eval $ac_compile) 2>&5
3797 echo "$as_me:3797: \$? = $ac_status" >&5
3798 (exit $ac_status); } &&
3799 { ac_try='test -s conftest.$ac_objext'
3800 { (eval echo "$as_me:3800: \"$ac_try\"") >&5
3803 echo "$as_me:3803: \$? = $ac_status" >&5
3804 (exit $ac_status); }; }; then
3805 cf_cv_xopen_source=no
3807 echo "$as_me: failed program was:" >&5
3808 cat conftest.$ac_ext >&5
3810 CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
3811 cat >conftest.$ac_ext <<_ACEOF
3812 #line 3812 "configure"
3813 #include "confdefs.h"
3817 #include <sys/types.h>
3823 #ifdef _XOPEN_SOURCE
3830 rm -f conftest.$ac_objext
3831 if { (eval echo "$as_me:3831: \"$ac_compile\"") >&5
3832 (eval $ac_compile) 2>&5
3834 echo "$as_me:3834: \$? = $ac_status" >&5
3835 (exit $ac_status); } &&
3836 { ac_try='test -s conftest.$ac_objext'
3837 { (eval echo "$as_me:3837: \"$ac_try\"") >&5
3840 echo "$as_me:3840: \$? = $ac_status" >&5
3841 (exit $ac_status); }; }; then
3842 cf_cv_xopen_source=no
3844 echo "$as_me: failed program was:" >&5
3845 cat conftest.$ac_ext >&5
3846 cf_cv_xopen_source=$cf_XOPEN_SOURCE
3848 rm -f conftest.$ac_objext conftest.$ac_ext
3852 rm -f conftest.$ac_objext conftest.$ac_ext
3855 echo "$as_me:3855: result: $cf_cv_xopen_source" >&5
3856 echo "${ECHO_T}$cf_cv_xopen_source" >&6
3858 if test "$cf_cv_xopen_source" != no ; then
3860 CFLAGS=`echo "$CFLAGS" | \
3861 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3862 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
3864 CPPFLAGS=`echo "$CPPFLAGS" | \
3865 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3866 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
3868 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
3873 cf_new_extra_cppflags=
3875 for cf_add_cflags in $cf_temp_xopen_source
3877 case $cf_fix_cppflags in
3879 case $cf_add_cflags in #(vi
3880 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
3881 case $cf_add_cflags in
3883 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3885 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3886 && test -z "${cf_tst_cflags}" \
3887 && cf_fix_cppflags=yes
3889 if test $cf_fix_cppflags = yes ; then
3890 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3892 elif test "${cf_tst_cflags}" = "\"'" ; then
3893 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3899 *$cf_add_cflags) #(vi
3902 case $cf_add_cflags in #(vi
3904 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3906 CPPFLAGS=`echo "$CPPFLAGS" | \
3907 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3908 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3912 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
3917 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
3922 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3924 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
3926 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3927 && test -z "${cf_tst_cflags}" \
3928 && cf_fix_cppflags=no
3933 if test -n "$cf_new_cflags" ; then
3935 CFLAGS="$CFLAGS $cf_new_cflags"
3938 if test -n "$cf_new_cppflags" ; then
3940 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
3943 if test -n "$cf_new_extra_cppflags" ; then
3945 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
3953 echo "$as_me:3953: checking for signal global datatype" >&5
3954 echo $ECHO_N "checking for signal global datatype... $ECHO_C" >&6
3955 if test "${cf_cv_sig_atomic_t+set}" = set; then
3956 echo $ECHO_N "(cached) $ECHO_C" >&6
3960 "volatile sig_atomic_t" \
3964 cat >conftest.$ac_ext <<_ACEOF
3965 #line 3965 "configure"
3966 #include "confdefs.h"
3968 #include <sys/types.h>
3974 static void handler(int sig)
3981 signal(SIGINT, handler);
3987 rm -f conftest.$ac_objext
3988 if { (eval echo "$as_me:3988: \"$ac_compile\"") >&5
3989 (eval $ac_compile) 2>&5
3991 echo "$as_me:3991: \$? = $ac_status" >&5
3992 (exit $ac_status); } &&
3993 { ac_try='test -s conftest.$ac_objext'
3994 { (eval echo "$as_me:3994: \"$ac_try\"") >&5
3997 echo "$as_me:3997: \$? = $ac_status" >&5
3998 (exit $ac_status); }; }; then
3999 cf_cv_sig_atomic_t=$cf_type
4001 echo "$as_me: failed program was:" >&5
4002 cat conftest.$ac_ext >&5
4003 cf_cv_sig_atomic_t=no
4005 rm -f conftest.$ac_objext conftest.$ac_ext
4006 test "$cf_cv_sig_atomic_t" != no && break
4011 echo "$as_me:4011: result: $cf_cv_sig_atomic_t" >&5
4012 echo "${ECHO_T}$cf_cv_sig_atomic_t" >&6
4013 test "$cf_cv_sig_atomic_t" != no &&
4014 cat >>confdefs.h <<EOF
4015 #define SIG_ATOMIC_T $cf_cv_sig_atomic_t
4018 echo "$as_me:4018: checking if you want to use pkg-config" >&5
4019 echo $ECHO_N "checking if you want to use pkg-config... $ECHO_C" >&6
4021 # Check whether --with-pkg-config or --without-pkg-config was given.
4022 if test "${with_pkg_config+set}" = set; then
4023 withval="$with_pkg_config"
4024 cf_pkg_config=$withval
4028 echo "$as_me:4028: result: $cf_pkg_config" >&5
4029 echo "${ECHO_T}$cf_pkg_config" >&6
4031 case $cf_pkg_config in #(vi
4037 if test -n "$ac_tool_prefix"; then
4038 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
4039 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
4040 echo "$as_me:4040: checking for $ac_word" >&5
4041 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4042 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then
4043 echo $ECHO_N "(cached) $ECHO_C" >&6
4047 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
4050 ac_save_IFS=$IFS; IFS=$ac_path_separator
4052 for ac_dir in $ac_dummy; do
4054 test -z "$ac_dir" && ac_dir=.
4055 if $as_executable_p "$ac_dir/$ac_word"; then
4056 ac_cv_path_PKG_CONFIG="$ac_dir/$ac_word"
4057 echo "$as_me:4057: found $ac_dir/$ac_word" >&5
4065 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
4067 if test -n "$PKG_CONFIG"; then
4068 echo "$as_me:4068: result: $PKG_CONFIG" >&5
4069 echo "${ECHO_T}$PKG_CONFIG" >&6
4071 echo "$as_me:4071: result: no" >&5
4072 echo "${ECHO_T}no" >&6
4076 if test -z "$ac_cv_path_PKG_CONFIG"; then
4077 ac_pt_PKG_CONFIG=$PKG_CONFIG
4078 # Extract the first word of "pkg-config", so it can be a program name with args.
4079 set dummy pkg-config; ac_word=$2
4080 echo "$as_me:4080: checking for $ac_word" >&5
4081 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4082 if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then
4083 echo $ECHO_N "(cached) $ECHO_C" >&6
4085 case $ac_pt_PKG_CONFIG in
4087 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
4090 ac_save_IFS=$IFS; IFS=$ac_path_separator
4092 for ac_dir in $ac_dummy; do
4094 test -z "$ac_dir" && ac_dir=.
4095 if $as_executable_p "$ac_dir/$ac_word"; then
4096 ac_cv_path_ac_pt_PKG_CONFIG="$ac_dir/$ac_word"
4097 echo "$as_me:4097: found $ac_dir/$ac_word" >&5
4102 test -z "$ac_cv_path_ac_pt_PKG_CONFIG" && ac_cv_path_ac_pt_PKG_CONFIG="none"
4106 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
4108 if test -n "$ac_pt_PKG_CONFIG"; then
4109 echo "$as_me:4109: result: $ac_pt_PKG_CONFIG" >&5
4110 echo "${ECHO_T}$ac_pt_PKG_CONFIG" >&6
4112 echo "$as_me:4112: result: no" >&5
4113 echo "${ECHO_T}no" >&6
4116 PKG_CONFIG=$ac_pt_PKG_CONFIG
4118 PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
4127 test -z "$PKG_CONFIG" && PKG_CONFIG=none
4128 if test "$PKG_CONFIG" != none ; then
4130 if test "x$prefix" != xNONE; then
4131 cf_path_syntax="$prefix"
4133 cf_path_syntax="$ac_default_prefix"
4136 case ".$PKG_CONFIG" in #(vi
4137 .\$\(*\)*|.\'*\'*) #(vi
4141 .[a-zA-Z]:[\\/]*) #(vi OS/2 EMX
4143 .\${*prefix}*|.\${*dir}*) #(vi
4144 eval PKG_CONFIG="$PKG_CONFIG"
4145 case ".$PKG_CONFIG" in #(vi
4147 PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
4152 PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
4155 { { echo "$as_me:4155: error: expected a pathname, not \"$PKG_CONFIG\"" >&5
4156 echo "$as_me: error: expected a pathname, not \"$PKG_CONFIG\"" >&2;}
4157 { (exit 1); exit 1; }; }
4163 echo "$as_me:4163: checking if you want to see long compiling messages" >&5
4164 echo $ECHO_N "checking if you want to see long compiling messages... $ECHO_C" >&6
4166 # Check whether --enable-echo or --disable-echo was given.
4167 if test "${enable_echo+set}" = set; then
4168 enableval="$enable_echo"
4169 test "$enableval" != no && enableval=yes
4170 if test "$enableval" != "yes" ; then
4173 ECHO_LD='@echo linking $@;'
4174 RULE_CC='@echo compiling $<'
4175 SHOW_CC='@echo compiling $@'
4197 echo "$as_me:4197: result: $enableval" >&5
4198 echo "${ECHO_T}$enableval" >&6
4200 echo "$as_me:4200: checking for ncurses wrap-prefix" >&5
4201 echo $ECHO_N "checking for ncurses wrap-prefix... $ECHO_C" >&6
4203 # Check whether --with-ncurses-wrap-prefix or --without-ncurses-wrap-prefix was given.
4204 if test "${with_ncurses_wrap_prefix+set}" = set; then
4205 withval="$with_ncurses_wrap_prefix"
4206 NCURSES_WRAP_PREFIX=$withval
4208 NCURSES_WRAP_PREFIX=_nc_
4210 echo "$as_me:4210: result: $NCURSES_WRAP_PREFIX" >&5
4211 echo "${ECHO_T}$NCURSES_WRAP_PREFIX" >&6
4213 echo "$as_me:4213: checking if you want to check for wide-character functions" >&5
4214 echo $ECHO_N "checking if you want to check for wide-character functions... $ECHO_C" >&6
4216 # Check whether --enable-widec or --disable-widec was given.
4217 if test "${enable_widec+set}" = set; then
4218 enableval="$enable_widec"
4219 test "$enableval" != no && enableval=yes
4220 if test "$enableval" != "yes" ; then
4230 echo "$as_me:4230: result: $cf_enable_widec" >&5
4231 echo "${ECHO_T}$cf_enable_widec" >&6
4233 echo "$as_me:4233: checking for specific curses-directory" >&5
4234 echo $ECHO_N "checking for specific curses-directory... $ECHO_C" >&6
4236 # Check whether --with-curses-dir or --without-curses-dir was given.
4237 if test "${with_curses_dir+set}" = set; then
4238 withval="$with_curses_dir"
4239 cf_cv_curses_dir=$withval
4243 echo "$as_me:4243: result: $cf_cv_curses_dir" >&5
4244 echo "${ECHO_T}$cf_cv_curses_dir" >&6
4246 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
4249 if test "x$prefix" != xNONE; then
4250 cf_path_syntax="$prefix"
4252 cf_path_syntax="$ac_default_prefix"
4255 case ".$withval" in #(vi
4256 .\$\(*\)*|.\'*\'*) #(vi
4260 .[a-zA-Z]:[\\/]*) #(vi OS/2 EMX
4262 .\${*prefix}*|.\${*dir}*) #(vi
4263 eval withval="$withval"
4264 case ".$withval" in #(vi
4266 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
4271 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
4274 { { echo "$as_me:4274: error: expected a pathname, not \"$withval\"" >&5
4275 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
4276 { (exit 1); exit 1; }; }
4280 if test -d "$cf_cv_curses_dir"
4283 if test -n "$cf_cv_curses_dir/include" ; then
4284 for cf_add_incdir in $cf_cv_curses_dir/include
4286 while test $cf_add_incdir != /usr/include
4288 if test -d $cf_add_incdir
4291 if test -n "$CFLAGS$CPPFLAGS" ; then
4292 # a loop is needed to ensure we can add subdirs of existing dirs
4293 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
4294 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
4295 cf_have_incdir=yes; break
4300 if test "$cf_have_incdir" = no ; then
4301 if test "$cf_add_incdir" = /usr/local/include ; then
4302 if test "$GCC" = yes
4304 cf_save_CPPFLAGS=$CPPFLAGS
4305 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
4306 cat >conftest.$ac_ext <<_ACEOF
4307 #line 4307 "configure"
4308 #include "confdefs.h"
4318 rm -f conftest.$ac_objext
4319 if { (eval echo "$as_me:4319: \"$ac_compile\"") >&5
4320 (eval $ac_compile) 2>&5
4322 echo "$as_me:4322: \$? = $ac_status" >&5
4323 (exit $ac_status); } &&
4324 { ac_try='test -s conftest.$ac_objext'
4325 { (eval echo "$as_me:4325: \"$ac_try\"") >&5
4328 echo "$as_me:4328: \$? = $ac_status" >&5
4329 (exit $ac_status); }; }; then
4332 echo "$as_me: failed program was:" >&5
4333 cat conftest.$ac_ext >&5
4336 rm -f conftest.$ac_objext conftest.$ac_ext
4337 CPPFLAGS=$cf_save_CPPFLAGS
4342 if test "$cf_have_incdir" = no ; then
4343 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
4345 echo "${as_me:-configure}:4345: testing adding $cf_add_incdir to include-path ..." 1>&5
4347 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
4349 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
4350 test "$cf_top_incdir" = "$cf_add_incdir" && break
4351 cf_add_incdir="$cf_top_incdir"
4360 if test -n "$cf_cv_curses_dir/lib" ; then
4361 for cf_add_libdir in $cf_cv_curses_dir/lib
4363 if test $cf_add_libdir = /usr/lib ; then
4365 elif test -d $cf_add_libdir
4368 if test -n "$LDFLAGS$LIBS" ; then
4369 # a loop is needed to ensure we can add subdirs of existing dirs
4370 for cf_test_libdir in $LDFLAGS $LIBS ; do
4371 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
4372 cf_have_libdir=yes; break
4376 if test "$cf_have_libdir" = no ; then
4377 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
4379 echo "${as_me:-configure}:4379: testing adding $cf_add_libdir to library-path ..." 1>&5
4381 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
4392 echo "$as_me:4392: checking for specified curses library type" >&5
4393 echo $ECHO_N "checking for specified curses library type... $ECHO_C" >&6
4395 # Check whether --with-ncursesw or --without-ncursesw was given.
4396 if test "${with_ncursesw+set}" = set; then
4397 withval="$with_ncursesw"
4398 cf_cv_screen=ncursesw
4401 # Check whether --with-ncurses or --without-ncurses was given.
4402 if test "${with_ncurses+set}" = set; then
4403 withval="$with_ncurses"
4404 cf_cv_screen=ncurses
4407 # Check whether --with-pdcurses or --without-pdcurses was given.
4408 if test "${with_pdcurses+set}" = set; then
4409 withval="$with_pdcurses"
4410 cf_cv_screen=pdcurses
4413 # Check whether --with-curses-colr or --without-curses-colr was given.
4414 if test "${with_curses_colr+set}" = set; then
4415 withval="$with_curses_colr"
4416 cf_cv_screen=curses_colr
4419 # Check whether --with-curses-5lib or --without-curses-5lib was given.
4420 if test "${with_curses_5lib+set}" = set; then
4421 withval="$with_curses_5lib"
4422 cf_cv_screen=curses_5lib
4429 echo "$as_me:4429: result: $cf_cv_screen" >&5
4430 echo "${ECHO_T}$cf_cv_screen" >&6
4432 case $cf_cv_screen in #(vi
4433 curses|curses_*) #(vi
4435 echo "$as_me:4435: checking for extra include directories" >&5
4436 echo $ECHO_N "checking for extra include directories... $ECHO_C" >&6
4437 if test "${cf_cv_curses_incdir+set}" = set; then
4438 echo $ECHO_N "(cached) $ECHO_C" >&6
4441 cf_cv_curses_incdir=no
4442 case $host_os in #(vi
4444 if test "x$cf_cv_screen" = "xcurses_colr"
4446 test -d /usr/include/curses_colr && \
4447 cf_cv_curses_incdir="-I/usr/include/curses_colr"
4451 if test "x$cf_cv_screen" = "xcurses_5lib"
4453 test -d /usr/5lib && \
4454 test -d /usr/5include && \
4455 cf_cv_curses_incdir="-I/usr/5include"
4461 echo "$as_me:4461: result: $cf_cv_curses_incdir" >&5
4462 echo "${ECHO_T}$cf_cv_curses_incdir" >&6
4463 test "$cf_cv_curses_incdir" != no && CPPFLAGS="$CPPFLAGS $cf_cv_curses_incdir"
4465 echo "$as_me:4465: checking if we have identified curses headers" >&5
4466 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
4467 if test "${cf_cv_ncurses_header+set}" = set; then
4468 echo $ECHO_N "(cached) $ECHO_C" >&6
4471 cf_cv_ncurses_header=none
4474 curses.h ncurses/ncurses.h ncurses/curses.h
4476 cat >conftest.$ac_ext <<_ACEOF
4477 #line 4477 "configure"
4478 #include "confdefs.h"
4479 #include <${cf_header}>
4483 initscr(); tgoto("?", 0,0)
4488 rm -f conftest.$ac_objext
4489 if { (eval echo "$as_me:4489: \"$ac_compile\"") >&5
4490 (eval $ac_compile) 2>&5
4492 echo "$as_me:4492: \$? = $ac_status" >&5
4493 (exit $ac_status); } &&
4494 { ac_try='test -s conftest.$ac_objext'
4495 { (eval echo "$as_me:4495: \"$ac_try\"") >&5
4498 echo "$as_me:4498: \$? = $ac_status" >&5
4499 (exit $ac_status); }; }; then
4500 cf_cv_ncurses_header=$cf_header; break
4502 echo "$as_me: failed program was:" >&5
4503 cat conftest.$ac_ext >&5
4505 rm -f conftest.$ac_objext conftest.$ac_ext
4509 echo "$as_me:4509: result: $cf_cv_ncurses_header" >&5
4510 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
4512 if test "$cf_cv_ncurses_header" = none ; then
4513 { { echo "$as_me:4513: error: No curses header-files found" >&5
4514 echo "$as_me: error: No curses header-files found" >&2;}
4515 { (exit 1); exit 1; }; }
4518 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
4520 for ac_header in $cf_cv_ncurses_header
4522 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
4523 echo "$as_me:4523: checking for $ac_header" >&5
4524 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4525 if eval "test \"\${$as_ac_Header+set}\" = set"; then
4526 echo $ECHO_N "(cached) $ECHO_C" >&6
4528 cat >conftest.$ac_ext <<_ACEOF
4529 #line 4529 "configure"
4530 #include "confdefs.h"
4531 #include <$ac_header>
4533 if { (eval echo "$as_me:4533: \"$ac_cpp conftest.$ac_ext\"") >&5
4534 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4536 egrep -v '^ *\+' conftest.er1 >conftest.err
4538 cat conftest.err >&5
4539 echo "$as_me:4539: \$? = $ac_status" >&5
4540 (exit $ac_status); } >/dev/null; then
4541 if test -s conftest.err; then
4542 ac_cpp_err=$ac_c_preproc_warn_flag
4549 if test -z "$ac_cpp_err"; then
4550 eval "$as_ac_Header=yes"
4552 echo "$as_me: failed program was:" >&5
4553 cat conftest.$ac_ext >&5
4554 eval "$as_ac_Header=no"
4556 rm -f conftest.err conftest.$ac_ext
4558 echo "$as_me:4558: result: `eval echo '${'$as_ac_Header'}'`" >&5
4559 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4560 if test `eval echo '${'$as_ac_Header'}'` = yes; then
4561 cat >>confdefs.h <<EOF
4562 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
4568 echo "$as_me:4568: checking for terminfo header" >&5
4569 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
4570 if test "${cf_cv_term_header+set}" = set; then
4571 echo $ECHO_N "(cached) $ECHO_C" >&6
4574 case ${cf_cv_ncurses_header} in #(vi
4575 */ncurses.h|*/ncursesw.h) #(vi
4576 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
4579 cf_term_header=term.h
4583 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
4585 cat >conftest.$ac_ext <<_ACEOF
4586 #line 4586 "configure"
4587 #include "confdefs.h"
4589 #include <${cf_cv_ncurses_header:-curses.h}>
4595 int x = auto_left_margin
4600 rm -f conftest.$ac_objext
4601 if { (eval echo "$as_me:4601: \"$ac_compile\"") >&5
4602 (eval $ac_compile) 2>&5
4604 echo "$as_me:4604: \$? = $ac_status" >&5
4605 (exit $ac_status); } &&
4606 { ac_try='test -s conftest.$ac_objext'
4607 { (eval echo "$as_me:4607: \"$ac_try\"") >&5
4610 echo "$as_me:4610: \$? = $ac_status" >&5
4611 (exit $ac_status); }; }; then
4613 cf_cv_term_header="$cf_test"
4615 echo "$as_me: failed program was:" >&5
4616 cat conftest.$ac_ext >&5
4618 cf_cv_term_header=unknown
4621 rm -f conftest.$ac_objext conftest.$ac_ext
4622 test "$cf_cv_term_header" != unknown && break
4626 echo "$as_me:4626: result: $cf_cv_term_header" >&5
4627 echo "${ECHO_T}$cf_cv_term_header" >&6
4629 # Set definitions to allow ifdef'ing to accommodate subdirectories
4631 case $cf_cv_term_header in # (vi
4634 cat >>confdefs.h <<\EOF
4635 #define HAVE_TERM_H 1
4641 case $cf_cv_term_header in # (vi
4642 ncurses/term.h) #(vi
4644 cat >>confdefs.h <<\EOF
4645 #define HAVE_NCURSES_TERM_H 1
4651 cat >>confdefs.h <<\EOF
4652 #define HAVE_NCURSESW_TERM_H 1
4658 echo "$as_me:4658: checking for ncurses version" >&5
4659 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
4660 if test "${cf_cv_ncurses_version+set}" = set; then
4661 echo $ECHO_N "(cached) $ECHO_C" >&6
4664 cf_cv_ncurses_version=no
4667 if test "$cross_compiling" = yes; then
4669 # This will not work if the preprocessor splits the line after the
4670 # Autoconf token. The 'unproto' program does that.
4671 cat > conftest.$ac_ext <<EOF
4672 #include <${cf_cv_ncurses_header:-curses.h}>
4674 #ifdef NCURSES_VERSION
4675 Autoconf NCURSES_VERSION
4683 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
4684 { (eval echo "$as_me:4684: \"$cf_try\"") >&5
4687 echo "$as_me:4687: \$? = $ac_status" >&5
4688 (exit $ac_status); }
4689 if test -f conftest.out ; then
4690 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
4691 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
4696 cat >conftest.$ac_ext <<_ACEOF
4697 #line 4697 "configure"
4698 #include "confdefs.h"
4700 #include <${cf_cv_ncurses_header:-curses.h}>
4704 FILE *fp = fopen("$cf_tempfile", "w");
4705 #ifdef NCURSES_VERSION
4706 # ifdef NCURSES_VERSION_PATCH
4707 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
4709 fprintf(fp, "%s\n", NCURSES_VERSION);
4713 fprintf(fp, "old\n");
4718 ${cf_cv_main_return:-return}(0);
4721 rm -f conftest$ac_exeext
4722 if { (eval echo "$as_me:4722: \"$ac_link\"") >&5
4723 (eval $ac_link) 2>&5
4725 echo "$as_me:4725: \$? = $ac_status" >&5
4726 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4727 { (eval echo "$as_me:4727: \"$ac_try\"") >&5
4730 echo "$as_me:4730: \$? = $ac_status" >&5
4731 (exit $ac_status); }; }; then
4733 cf_cv_ncurses_version=`cat $cf_tempfile`
4735 echo "$as_me: program exited with status $ac_status" >&5
4736 echo "$as_me: failed program was:" >&5
4737 cat conftest.$ac_ext >&5
4739 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
4744 echo "$as_me:4744: result: $cf_cv_ncurses_version" >&5
4745 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
4746 test "$cf_cv_ncurses_version" = no ||
4747 cat >>confdefs.h <<\EOF
4751 echo "$as_me:4751: checking if we have identified curses libraries" >&5
4752 echo $ECHO_N "checking if we have identified curses libraries... $ECHO_C" >&6
4753 cat >conftest.$ac_ext <<_ACEOF
4754 #line 4754 "configure"
4755 #include "confdefs.h"
4756 #include <${cf_cv_ncurses_header:-curses.h}>
4760 initscr(); tgoto("?", 0,0)
4765 rm -f conftest.$ac_objext conftest$ac_exeext
4766 if { (eval echo "$as_me:4766: \"$ac_link\"") >&5
4767 (eval $ac_link) 2>&5
4769 echo "$as_me:4769: \$? = $ac_status" >&5
4770 (exit $ac_status); } &&
4771 { ac_try='test -s conftest$ac_exeext'
4772 { (eval echo "$as_me:4772: \"$ac_try\"") >&5
4775 echo "$as_me:4775: \$? = $ac_status" >&5
4776 (exit $ac_status); }; }; then
4779 echo "$as_me: failed program was:" >&5
4780 cat conftest.$ac_ext >&5
4783 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4784 echo "$as_me:4784: result: $cf_result" >&5
4785 echo "${ECHO_T}$cf_result" >&6
4787 if test "$cf_result" = no ; then
4788 case $host_os in #(vi
4790 echo "$as_me:4790: checking for tgoto in -lmytinfo" >&5
4791 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
4792 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
4793 echo $ECHO_N "(cached) $ECHO_C" >&6
4795 ac_check_lib_save_LIBS=$LIBS
4796 LIBS="-lmytinfo $LIBS"
4797 cat >conftest.$ac_ext <<_ACEOF
4798 #line 4798 "configure"
4799 #include "confdefs.h"
4801 /* Override any gcc2 internal prototype to avoid an error. */
4805 /* We use char because int might match the return type of a gcc2
4806 builtin and then its argument prototype would still apply. */
4816 rm -f conftest.$ac_objext conftest$ac_exeext
4817 if { (eval echo "$as_me:4817: \"$ac_link\"") >&5
4818 (eval $ac_link) 2>&5
4820 echo "$as_me:4820: \$? = $ac_status" >&5
4821 (exit $ac_status); } &&
4822 { ac_try='test -s conftest$ac_exeext'
4823 { (eval echo "$as_me:4823: \"$ac_try\"") >&5
4826 echo "$as_me:4826: \$? = $ac_status" >&5
4827 (exit $ac_status); }; }; then
4828 ac_cv_lib_mytinfo_tgoto=yes
4830 echo "$as_me: failed program was:" >&5
4831 cat conftest.$ac_ext >&5
4832 ac_cv_lib_mytinfo_tgoto=no
4834 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4835 LIBS=$ac_check_lib_save_LIBS
4837 echo "$as_me:4837: result: $ac_cv_lib_mytinfo_tgoto" >&5
4838 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
4839 if test $ac_cv_lib_mytinfo_tgoto = yes; then
4840 LIBS="-lmytinfo $LIBS"
4845 # Looking at HPUX 10.20, the Hcurses library is the oldest (1997), cur_colr
4846 # next (1998), and xcurses "newer" (2000). There is no header file for
4847 # Hcurses; the subdirectory curses_colr has the headers (curses.h and
4848 # term.h) for cur_colr
4849 if test "x$cf_cv_screen" = "xcurses_colr"
4851 echo "$as_me:4851: checking for initscr in -lcur_colr" >&5
4852 echo $ECHO_N "checking for initscr in -lcur_colr... $ECHO_C" >&6
4853 if test "${ac_cv_lib_cur_colr_initscr+set}" = set; then
4854 echo $ECHO_N "(cached) $ECHO_C" >&6
4856 ac_check_lib_save_LIBS=$LIBS
4857 LIBS="-lcur_colr $LIBS"
4858 cat >conftest.$ac_ext <<_ACEOF
4859 #line 4859 "configure"
4860 #include "confdefs.h"
4862 /* Override any gcc2 internal prototype to avoid an error. */
4866 /* We use char because int might match the return type of a gcc2
4867 builtin and then its argument prototype would still apply. */
4877 rm -f conftest.$ac_objext conftest$ac_exeext
4878 if { (eval echo "$as_me:4878: \"$ac_link\"") >&5
4879 (eval $ac_link) 2>&5
4881 echo "$as_me:4881: \$? = $ac_status" >&5
4882 (exit $ac_status); } &&
4883 { ac_try='test -s conftest$ac_exeext'
4884 { (eval echo "$as_me:4884: \"$ac_try\"") >&5
4887 echo "$as_me:4887: \$? = $ac_status" >&5
4888 (exit $ac_status); }; }; then
4889 ac_cv_lib_cur_colr_initscr=yes
4891 echo "$as_me: failed program was:" >&5
4892 cat conftest.$ac_ext >&5
4893 ac_cv_lib_cur_colr_initscr=no
4895 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4896 LIBS=$ac_check_lib_save_LIBS
4898 echo "$as_me:4898: result: $ac_cv_lib_cur_colr_initscr" >&5
4899 echo "${ECHO_T}$ac_cv_lib_cur_colr_initscr" >&6
4900 if test $ac_cv_lib_cur_colr_initscr = yes; then
4902 LIBS="-lcur_colr $LIBS"
4903 ac_cv_func_initscr=yes
4907 echo "$as_me:4907: checking for initscr in -lHcurses" >&5
4908 echo $ECHO_N "checking for initscr in -lHcurses... $ECHO_C" >&6
4909 if test "${ac_cv_lib_Hcurses_initscr+set}" = set; then
4910 echo $ECHO_N "(cached) $ECHO_C" >&6
4912 ac_check_lib_save_LIBS=$LIBS
4913 LIBS="-lHcurses $LIBS"
4914 cat >conftest.$ac_ext <<_ACEOF
4915 #line 4915 "configure"
4916 #include "confdefs.h"
4918 /* Override any gcc2 internal prototype to avoid an error. */
4922 /* We use char because int might match the return type of a gcc2
4923 builtin and then its argument prototype would still apply. */
4933 rm -f conftest.$ac_objext conftest$ac_exeext
4934 if { (eval echo "$as_me:4934: \"$ac_link\"") >&5
4935 (eval $ac_link) 2>&5
4937 echo "$as_me:4937: \$? = $ac_status" >&5
4938 (exit $ac_status); } &&
4939 { ac_try='test -s conftest$ac_exeext'
4940 { (eval echo "$as_me:4940: \"$ac_try\"") >&5
4943 echo "$as_me:4943: \$? = $ac_status" >&5
4944 (exit $ac_status); }; }; then
4945 ac_cv_lib_Hcurses_initscr=yes
4947 echo "$as_me: failed program was:" >&5
4948 cat conftest.$ac_ext >&5
4949 ac_cv_lib_Hcurses_initscr=no
4951 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4952 LIBS=$ac_check_lib_save_LIBS
4954 echo "$as_me:4954: result: $ac_cv_lib_Hcurses_initscr" >&5
4955 echo "${ECHO_T}$ac_cv_lib_Hcurses_initscr" >&6
4956 if test $ac_cv_lib_Hcurses_initscr = yes; then
4958 # HP's header uses __HP_CURSES, but user claims _HP_CURSES.
4959 LIBS="-lHcurses $LIBS"
4960 CPPFLAGS="$CPPFLAGS -D__HP_CURSES -D_HP_CURSES"
4961 ac_cv_func_initscr=yes
4970 case `arch 2>/dev/null` in
4975 if test -n "/lib64" ; then
4976 for cf_add_libdir in /lib64
4978 if test $cf_add_libdir = /usr/lib ; then
4980 elif test -d $cf_add_libdir
4983 if test -n "$LDFLAGS$LIBS" ; then
4984 # a loop is needed to ensure we can add subdirs of existing dirs
4985 for cf_test_libdir in $LDFLAGS $LIBS ; do
4986 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
4987 cf_have_libdir=yes; break
4991 if test "$cf_have_libdir" = no ; then
4992 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
4994 echo "${as_me:-configure}:4994: testing adding $cf_add_libdir to library-path ..." 1>&5
4996 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
5004 if test -n "/lib" ; then
5005 for cf_add_libdir in /lib
5007 if test $cf_add_libdir = /usr/lib ; then
5009 elif test -d $cf_add_libdir
5012 if test -n "$LDFLAGS$LIBS" ; then
5013 # a loop is needed to ensure we can add subdirs of existing dirs
5014 for cf_test_libdir in $LDFLAGS $LIBS ; do
5015 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
5016 cf_have_libdir=yes; break
5020 if test "$cf_have_libdir" = no ; then
5021 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
5023 echo "${as_me:-configure}:5023: testing adding $cf_add_libdir to library-path ..." 1>&5
5025 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
5035 if test -n "/lib" ; then
5036 for cf_add_libdir in /lib
5038 if test $cf_add_libdir = /usr/lib ; then
5040 elif test -d $cf_add_libdir
5043 if test -n "$LDFLAGS$LIBS" ; then
5044 # a loop is needed to ensure we can add subdirs of existing dirs
5045 for cf_test_libdir in $LDFLAGS $LIBS ; do
5046 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
5047 cf_have_libdir=yes; break
5051 if test "$cf_have_libdir" = no ; then
5052 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
5054 echo "${as_me:-configure}:5054: testing adding $cf_add_libdir to library-path ..." 1>&5
5056 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
5066 if test "x$cf_cv_screen" = "xcurses_5lib"
5068 if test -d /usr/5lib ; then
5070 if test -n "/usr/5lib" ; then
5071 for cf_add_libdir in /usr/5lib
5073 if test $cf_add_libdir = /usr/lib ; then
5075 elif test -d $cf_add_libdir
5078 if test -n "$LDFLAGS$LIBS" ; then
5079 # a loop is needed to ensure we can add subdirs of existing dirs
5080 for cf_test_libdir in $LDFLAGS $LIBS ; do
5081 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
5082 cf_have_libdir=yes; break
5086 if test "$cf_have_libdir" = no ; then
5087 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
5089 echo "${as_me:-configure}:5089: testing adding $cf_add_libdir to library-path ..." 1>&5
5091 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
5097 LIBS="-lcurses -ltermcap $LIBS"
5100 ac_cv_func_initscr=yes
5104 if test ".$ac_cv_func_initscr" != .yes ; then
5105 cf_save_LIBS="$LIBS"
5107 if test ".${cf_cv_ncurses_version:-no}" != .no
5109 cf_check_list="ncurses curses cursesX"
5111 cf_check_list="cursesX curses ncurses"
5114 # Check for library containing tgoto. Do this before curses library
5115 # because it may be needed to link the test-case for initscr.
5116 if test "x$cf_term_lib" = x
5118 echo "$as_me:5118: checking for tgoto" >&5
5119 echo $ECHO_N "checking for tgoto... $ECHO_C" >&6
5120 if test "${ac_cv_func_tgoto+set}" = set; then
5121 echo $ECHO_N "(cached) $ECHO_C" >&6
5123 cat >conftest.$ac_ext <<_ACEOF
5124 #line 5124 "configure"
5125 #include "confdefs.h"
5126 /* System header to define __stub macros and hopefully few prototypes,
5127 which can conflict with char tgoto (); below. */
5129 /* Override any gcc2 internal prototype to avoid an error. */
5133 /* We use char because int might match the return type of a gcc2
5134 builtin and then its argument prototype would still apply. */
5141 /* The GNU C library defines this for functions which it implements
5142 to always fail with ENOSYS. Some functions are actually named
5143 something starting with __ and the normal name is an alias. */
5144 #if defined (__stub_tgoto) || defined (__stub___tgoto)
5147 f = tgoto; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
5154 rm -f conftest.$ac_objext conftest$ac_exeext
5155 if { (eval echo "$as_me:5155: \"$ac_link\"") >&5
5156 (eval $ac_link) 2>&5
5158 echo "$as_me:5158: \$? = $ac_status" >&5
5159 (exit $ac_status); } &&
5160 { ac_try='test -s conftest$ac_exeext'
5161 { (eval echo "$as_me:5161: \"$ac_try\"") >&5
5164 echo "$as_me:5164: \$? = $ac_status" >&5
5165 (exit $ac_status); }; }; then
5166 ac_cv_func_tgoto=yes
5168 echo "$as_me: failed program was:" >&5
5169 cat conftest.$ac_ext >&5
5172 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5174 echo "$as_me:5174: result: $ac_cv_func_tgoto" >&5
5175 echo "${ECHO_T}$ac_cv_func_tgoto" >&6
5176 if test $ac_cv_func_tgoto = yes; then
5177 cf_term_lib=predefined
5180 for cf_term_lib in $cf_check_list otermcap termcap tinfo termlib unknown
5182 as_ac_Lib=`echo "ac_cv_lib_$cf_term_lib''_tgoto" | $as_tr_sh`
5183 echo "$as_me:5183: checking for tgoto in -l$cf_term_lib" >&5
5184 echo $ECHO_N "checking for tgoto in -l$cf_term_lib... $ECHO_C" >&6
5185 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
5186 echo $ECHO_N "(cached) $ECHO_C" >&6
5188 ac_check_lib_save_LIBS=$LIBS
5189 LIBS="-l$cf_term_lib $LIBS"
5190 cat >conftest.$ac_ext <<_ACEOF
5191 #line 5191 "configure"
5192 #include "confdefs.h"
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. */
5209 rm -f conftest.$ac_objext conftest$ac_exeext
5210 if { (eval echo "$as_me:5210: \"$ac_link\"") >&5
5211 (eval $ac_link) 2>&5
5213 echo "$as_me:5213: \$? = $ac_status" >&5
5214 (exit $ac_status); } &&
5215 { ac_try='test -s conftest$ac_exeext'
5216 { (eval echo "$as_me:5216: \"$ac_try\"") >&5
5219 echo "$as_me:5219: \$? = $ac_status" >&5
5220 (exit $ac_status); }; }; then
5221 eval "$as_ac_Lib=yes"
5223 echo "$as_me: failed program was:" >&5
5224 cat conftest.$ac_ext >&5
5225 eval "$as_ac_Lib=no"
5227 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5228 LIBS=$ac_check_lib_save_LIBS
5230 echo "$as_me:5230: result: `eval echo '${'$as_ac_Lib'}'`" >&5
5231 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
5232 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
5242 # Check for library containing initscr
5243 test "$cf_term_lib" != predefined && test "$cf_term_lib" != unknown && LIBS="-l$cf_term_lib $cf_save_LIBS"
5244 if test "x$cf_curs_lib" = x
5246 for cf_curs_lib in $cf_check_list xcurses jcurses pdcurses unknown
5248 as_ac_Lib=`echo "ac_cv_lib_$cf_curs_lib''_initscr" | $as_tr_sh`
5249 echo "$as_me:5249: checking for initscr in -l$cf_curs_lib" >&5
5250 echo $ECHO_N "checking for initscr in -l$cf_curs_lib... $ECHO_C" >&6
5251 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
5252 echo $ECHO_N "(cached) $ECHO_C" >&6
5254 ac_check_lib_save_LIBS=$LIBS
5255 LIBS="-l$cf_curs_lib $LIBS"
5256 cat >conftest.$ac_ext <<_ACEOF
5257 #line 5257 "configure"
5258 #include "confdefs.h"
5260 /* Override any gcc2 internal prototype to avoid an error. */
5264 /* We use char because int might match the return type of a gcc2
5265 builtin and then its argument prototype would still apply. */
5275 rm -f conftest.$ac_objext conftest$ac_exeext
5276 if { (eval echo "$as_me:5276: \"$ac_link\"") >&5
5277 (eval $ac_link) 2>&5
5279 echo "$as_me:5279: \$? = $ac_status" >&5
5280 (exit $ac_status); } &&
5281 { ac_try='test -s conftest$ac_exeext'
5282 { (eval echo "$as_me:5282: \"$ac_try\"") >&5
5285 echo "$as_me:5285: \$? = $ac_status" >&5
5286 (exit $ac_status); }; }; then
5287 eval "$as_ac_Lib=yes"
5289 echo "$as_me: failed program was:" >&5
5290 cat conftest.$ac_ext >&5
5291 eval "$as_ac_Lib=no"
5293 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5294 LIBS=$ac_check_lib_save_LIBS
5296 echo "$as_me:5296: result: `eval echo '${'$as_ac_Lib'}'`" >&5
5297 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
5298 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
5304 test $cf_curs_lib = unknown && { { echo "$as_me:5304: error: no curses library found" >&5
5305 echo "$as_me: error: no curses library found" >&2;}
5306 { (exit 1); exit 1; }; }
5308 LIBS="-l$cf_curs_lib $cf_save_LIBS"
5309 if test "$cf_term_lib" = unknown ; then
5310 echo "$as_me:5310: checking if we can link with $cf_curs_lib library" >&5
5311 echo $ECHO_N "checking if we can link with $cf_curs_lib library... $ECHO_C" >&6
5312 cat >conftest.$ac_ext <<_ACEOF
5313 #line 5313 "configure"
5314 #include "confdefs.h"
5315 #include <${cf_cv_ncurses_header:-curses.h}>
5324 rm -f conftest.$ac_objext conftest$ac_exeext
5325 if { (eval echo "$as_me:5325: \"$ac_link\"") >&5
5326 (eval $ac_link) 2>&5
5328 echo "$as_me:5328: \$? = $ac_status" >&5
5329 (exit $ac_status); } &&
5330 { ac_try='test -s conftest$ac_exeext'
5331 { (eval echo "$as_me:5331: \"$ac_try\"") >&5
5334 echo "$as_me:5334: \$? = $ac_status" >&5
5335 (exit $ac_status); }; }; then
5338 echo "$as_me: failed program was:" >&5
5339 cat conftest.$ac_ext >&5
5342 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5343 echo "$as_me:5343: result: $cf_result" >&5
5344 echo "${ECHO_T}$cf_result" >&6
5345 test $cf_result = no && { { echo "$as_me:5345: error: Cannot link curses library" >&5
5346 echo "$as_me: error: Cannot link curses library" >&2;}
5347 { (exit 1); exit 1; }; }
5348 elif test "$cf_curs_lib" = "$cf_term_lib" ; then
5350 elif test "$cf_term_lib" != predefined ; then
5351 echo "$as_me:5351: checking if we need both $cf_curs_lib and $cf_term_lib libraries" >&5
5352 echo $ECHO_N "checking if we need both $cf_curs_lib and $cf_term_lib libraries... $ECHO_C" >&6
5353 cat >conftest.$ac_ext <<_ACEOF
5354 #line 5354 "configure"
5355 #include "confdefs.h"
5356 #include <${cf_cv_ncurses_header:-curses.h}>
5360 initscr(); tgoto((char *)0, 0, 0);
5365 rm -f conftest.$ac_objext conftest$ac_exeext
5366 if { (eval echo "$as_me:5366: \"$ac_link\"") >&5
5367 (eval $ac_link) 2>&5
5369 echo "$as_me:5369: \$? = $ac_status" >&5
5370 (exit $ac_status); } &&
5371 { ac_try='test -s conftest$ac_exeext'
5372 { (eval echo "$as_me:5372: \"$ac_try\"") >&5
5375 echo "$as_me:5375: \$? = $ac_status" >&5
5376 (exit $ac_status); }; }; then
5379 echo "$as_me: failed program was:" >&5
5380 cat conftest.$ac_ext >&5
5382 LIBS="-l$cf_curs_lib -l$cf_term_lib $cf_save_LIBS"
5383 cat >conftest.$ac_ext <<_ACEOF
5384 #line 5384 "configure"
5385 #include "confdefs.h"
5386 #include <${cf_cv_ncurses_header:-curses.h}>
5395 rm -f conftest.$ac_objext conftest$ac_exeext
5396 if { (eval echo "$as_me:5396: \"$ac_link\"") >&5
5397 (eval $ac_link) 2>&5
5399 echo "$as_me:5399: \$? = $ac_status" >&5
5400 (exit $ac_status); } &&
5401 { ac_try='test -s conftest$ac_exeext'
5402 { (eval echo "$as_me:5402: \"$ac_try\"") >&5
5405 echo "$as_me:5405: \$? = $ac_status" >&5
5406 (exit $ac_status); }; }; then
5409 echo "$as_me: failed program was:" >&5
5410 cat conftest.$ac_ext >&5
5413 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5416 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5417 echo "$as_me:5417: result: $cf_result" >&5
5418 echo "${ECHO_T}$cf_result" >&6
5426 cf_ncuconfig_root=ncurses
5428 echo "Looking for ${cf_ncuconfig_root}-config"
5430 if test -n "$ac_tool_prefix"; then
5431 for ac_prog in ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
5433 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
5434 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
5435 echo "$as_me:5435: checking for $ac_word" >&5
5436 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5437 if test "${ac_cv_prog_NCURSES_CONFIG+set}" = set; then
5438 echo $ECHO_N "(cached) $ECHO_C" >&6
5440 if test -n "$NCURSES_CONFIG"; then
5441 ac_cv_prog_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test.
5443 ac_save_IFS=$IFS; IFS=$ac_path_separator
5445 for ac_dir in $ac_dummy; do
5447 test -z "$ac_dir" && ac_dir=.
5448 $as_executable_p "$ac_dir/$ac_word" || continue
5449 ac_cv_prog_NCURSES_CONFIG="$ac_tool_prefix$ac_prog"
5450 echo "$as_me:5450: found $ac_dir/$ac_word" >&5
5456 NCURSES_CONFIG=$ac_cv_prog_NCURSES_CONFIG
5457 if test -n "$NCURSES_CONFIG"; then
5458 echo "$as_me:5458: result: $NCURSES_CONFIG" >&5
5459 echo "${ECHO_T}$NCURSES_CONFIG" >&6
5461 echo "$as_me:5461: result: no" >&5
5462 echo "${ECHO_T}no" >&6
5465 test -n "$NCURSES_CONFIG" && break
5468 if test -z "$NCURSES_CONFIG"; then
5469 ac_ct_NCURSES_CONFIG=$NCURSES_CONFIG
5470 for ac_prog in ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
5472 # Extract the first word of "$ac_prog", so it can be a program name with args.
5473 set dummy $ac_prog; ac_word=$2
5474 echo "$as_me:5474: checking for $ac_word" >&5
5475 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5476 if test "${ac_cv_prog_ac_ct_NCURSES_CONFIG+set}" = set; then
5477 echo $ECHO_N "(cached) $ECHO_C" >&6
5479 if test -n "$ac_ct_NCURSES_CONFIG"; then
5480 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_ct_NCURSES_CONFIG" # Let the user override the test.
5482 ac_save_IFS=$IFS; IFS=$ac_path_separator
5484 for ac_dir in $ac_dummy; do
5486 test -z "$ac_dir" && ac_dir=.
5487 $as_executable_p "$ac_dir/$ac_word" || continue
5488 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_prog"
5489 echo "$as_me:5489: found $ac_dir/$ac_word" >&5
5495 ac_ct_NCURSES_CONFIG=$ac_cv_prog_ac_ct_NCURSES_CONFIG
5496 if test -n "$ac_ct_NCURSES_CONFIG"; then
5497 echo "$as_me:5497: result: $ac_ct_NCURSES_CONFIG" >&5
5498 echo "${ECHO_T}$ac_ct_NCURSES_CONFIG" >&6
5500 echo "$as_me:5500: result: no" >&5
5501 echo "${ECHO_T}no" >&6
5504 test -n "$ac_ct_NCURSES_CONFIG" && break
5506 test -n "$ac_ct_NCURSES_CONFIG" || ac_ct_NCURSES_CONFIG="none"
5508 NCURSES_CONFIG=$ac_ct_NCURSES_CONFIG
5511 if test "$NCURSES_CONFIG" != none ; then
5513 CPPFLAGS="$CPPFLAGS `$NCURSES_CONFIG --cflags`"
5514 LIBS="`$NCURSES_CONFIG --libs` $LIBS"
5516 # even with config script, some packages use no-override for curses.h
5518 echo "$as_me:5518: checking if we have identified curses headers" >&5
5519 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
5520 if test "${cf_cv_ncurses_header+set}" = set; then
5521 echo $ECHO_N "(cached) $ECHO_C" >&6
5524 cf_cv_ncurses_header=none
5531 cat >conftest.$ac_ext <<_ACEOF
5532 #line 5532 "configure"
5533 #include "confdefs.h"
5534 #include <${cf_header}>
5538 initscr(); tgoto("?", 0,0)
5543 rm -f conftest.$ac_objext
5544 if { (eval echo "$as_me:5544: \"$ac_compile\"") >&5
5545 (eval $ac_compile) 2>&5
5547 echo "$as_me:5547: \$? = $ac_status" >&5
5548 (exit $ac_status); } &&
5549 { ac_try='test -s conftest.$ac_objext'
5550 { (eval echo "$as_me:5550: \"$ac_try\"") >&5
5553 echo "$as_me:5553: \$? = $ac_status" >&5
5554 (exit $ac_status); }; }; then
5555 cf_cv_ncurses_header=$cf_header; break
5557 echo "$as_me: failed program was:" >&5
5558 cat conftest.$ac_ext >&5
5560 rm -f conftest.$ac_objext conftest.$ac_ext
5564 echo "$as_me:5564: result: $cf_cv_ncurses_header" >&5
5565 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
5567 if test "$cf_cv_ncurses_header" = none ; then
5568 { { echo "$as_me:5568: error: No curses header-files found" >&5
5569 echo "$as_me: error: No curses header-files found" >&2;}
5570 { (exit 1); exit 1; }; }
5573 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
5575 for ac_header in $cf_cv_ncurses_header
5577 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
5578 echo "$as_me:5578: checking for $ac_header" >&5
5579 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5580 if eval "test \"\${$as_ac_Header+set}\" = set"; then
5581 echo $ECHO_N "(cached) $ECHO_C" >&6
5583 cat >conftest.$ac_ext <<_ACEOF
5584 #line 5584 "configure"
5585 #include "confdefs.h"
5586 #include <$ac_header>
5588 if { (eval echo "$as_me:5588: \"$ac_cpp conftest.$ac_ext\"") >&5
5589 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
5591 egrep -v '^ *\+' conftest.er1 >conftest.err
5593 cat conftest.err >&5
5594 echo "$as_me:5594: \$? = $ac_status" >&5
5595 (exit $ac_status); } >/dev/null; then
5596 if test -s conftest.err; then
5597 ac_cpp_err=$ac_c_preproc_warn_flag
5604 if test -z "$ac_cpp_err"; then
5605 eval "$as_ac_Header=yes"
5607 echo "$as_me: failed program was:" >&5
5608 cat conftest.$ac_ext >&5
5609 eval "$as_ac_Header=no"
5611 rm -f conftest.err conftest.$ac_ext
5613 echo "$as_me:5613: result: `eval echo '${'$as_ac_Header'}'`" >&5
5614 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
5615 if test `eval echo '${'$as_ac_Header'}'` = yes; then
5616 cat >>confdefs.h <<EOF
5617 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
5623 cat >>confdefs.h <<\EOF
5627 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
5629 cat >>confdefs.h <<EOF
5630 #define $cf_nculib_ROOT 1
5633 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
5637 cf_ncuhdr_root=ncurses
5639 test -n "$cf_cv_curses_dir" && \
5640 test "$cf_cv_curses_dir" != "no" && { \
5642 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
5643 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
5645 while test $cf_add_incdir != /usr/include
5647 if test -d $cf_add_incdir
5650 if test -n "$CFLAGS$CPPFLAGS" ; then
5651 # a loop is needed to ensure we can add subdirs of existing dirs
5652 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
5653 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
5654 cf_have_incdir=yes; break
5659 if test "$cf_have_incdir" = no ; then
5660 if test "$cf_add_incdir" = /usr/local/include ; then
5661 if test "$GCC" = yes
5663 cf_save_CPPFLAGS=$CPPFLAGS
5664 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
5665 cat >conftest.$ac_ext <<_ACEOF
5666 #line 5666 "configure"
5667 #include "confdefs.h"
5677 rm -f conftest.$ac_objext
5678 if { (eval echo "$as_me:5678: \"$ac_compile\"") >&5
5679 (eval $ac_compile) 2>&5
5681 echo "$as_me:5681: \$? = $ac_status" >&5
5682 (exit $ac_status); } &&
5683 { ac_try='test -s conftest.$ac_objext'
5684 { (eval echo "$as_me:5684: \"$ac_try\"") >&5
5687 echo "$as_me:5687: \$? = $ac_status" >&5
5688 (exit $ac_status); }; }; then
5691 echo "$as_me: failed program was:" >&5
5692 cat conftest.$ac_ext >&5
5695 rm -f conftest.$ac_objext conftest.$ac_ext
5696 CPPFLAGS=$cf_save_CPPFLAGS
5701 if test "$cf_have_incdir" = no ; then
5702 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
5704 echo "${as_me:-configure}:5704: testing adding $cf_add_incdir to include-path ..." 1>&5
5706 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
5708 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
5709 test "$cf_top_incdir" = "$cf_add_incdir" && break
5710 cf_add_incdir="$cf_top_incdir"
5721 echo "$as_me:5721: checking for $cf_ncuhdr_root header in include-path" >&5
5722 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
5723 if test "${cf_cv_ncurses_h+set}" = set; then
5724 echo $ECHO_N "(cached) $ECHO_C" >&6
5727 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
5728 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
5729 for cf_header in $cf_header_list
5732 cat >conftest.$ac_ext <<_ACEOF
5733 #line 5733 "configure"
5734 #include "confdefs.h"
5736 #include <$cf_header>
5741 #ifdef NCURSES_VERSION
5743 printf("%s\n", NCURSES_VERSION);
5756 rm -f conftest.$ac_objext
5757 if { (eval echo "$as_me:5757: \"$ac_compile\"") >&5
5758 (eval $ac_compile) 2>&5
5760 echo "$as_me:5760: \$? = $ac_status" >&5
5761 (exit $ac_status); } &&
5762 { ac_try='test -s conftest.$ac_objext'
5763 { (eval echo "$as_me:5763: \"$ac_try\"") >&5
5766 echo "$as_me:5766: \$? = $ac_status" >&5
5767 (exit $ac_status); }; }; then
5768 cf_cv_ncurses_h=$cf_header
5771 echo "$as_me: failed program was:" >&5
5772 cat conftest.$ac_ext >&5
5775 rm -f conftest.$ac_objext conftest.$ac_ext
5777 test "$cf_cv_ncurses_h" != no && break
5781 echo "$as_me:5781: result: $cf_cv_ncurses_h" >&5
5782 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
5784 if test "$cf_cv_ncurses_h" != no ; then
5785 cf_cv_ncurses_header=$cf_cv_ncurses_h
5788 echo "$as_me:5788: checking for $cf_ncuhdr_root include-path" >&5
5789 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
5790 if test "${cf_cv_ncurses_h2+set}" = set; then
5791 echo $ECHO_N "(cached) $ECHO_C" >&6
5794 test -n "$verbose" && echo
5798 # collect the current set of include-directories from compiler flags
5799 cf_header_path_list=""
5800 if test -n "${CFLAGS}${CPPFLAGS}" ; then
5801 for cf_header_path in $CPPFLAGS $CFLAGS
5803 case $cf_header_path in #(vi
5805 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
5807 test "$cf_header_path" != "NONE" && \
5808 test -d "$cf_header_path" && \
5810 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
5811 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
5812 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
5813 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
5814 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
5815 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"
5818 cf_header_path_list="$cf_header_path_list $cf_search"
5824 # add the variations for the package we are looking for
5828 test "/usr" != "$prefix" && \
5830 (test $prefix = NONE || test "/usr" != "$prefix") && {
5831 test -n "$verbose" && echo " ... testing for include-directories under /usr"
5832 test -d /usr/include && cf_search="$cf_search /usr/include"
5833 test -d /usr/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/include/$cf_ncuhdr_root"
5834 test -d /usr/include/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/include/$cf_ncuhdr_root/include"
5835 test -d /usr/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/$cf_ncuhdr_root/include"
5836 test -d /usr/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
5839 test "$prefix" != "NONE" && \
5840 test -d "$prefix" && \
5842 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
5843 test -d $prefix/include && cf_search="$cf_search $prefix/include"
5844 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
5845 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
5846 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
5847 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
5850 test "/usr/local" != "$prefix" && \
5851 test -d "/usr/local" && \
5852 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
5853 test -n "$verbose" && echo " ... testing for include-directories under /usr/local"
5854 test -d /usr/local/include && cf_search="$cf_search /usr/local/include"
5855 test -d /usr/local/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/local/include/$cf_ncuhdr_root"
5856 test -d /usr/local/include/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/local/include/$cf_ncuhdr_root/include"
5857 test -d /usr/local/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/local/$cf_ncuhdr_root/include"
5858 test -d /usr/local/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/local/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
5861 test "/opt" != "$prefix" && \
5863 (test $prefix = NONE || test "/opt" != "$prefix") && {
5864 test -n "$verbose" && echo " ... testing for include-directories under /opt"
5865 test -d /opt/include && cf_search="$cf_search /opt/include"
5866 test -d /opt/include/$cf_ncuhdr_root && cf_search="$cf_search /opt/include/$cf_ncuhdr_root"
5867 test -d /opt/include/$cf_ncuhdr_root/include && cf_search="$cf_search /opt/include/$cf_ncuhdr_root/include"
5868 test -d /opt/$cf_ncuhdr_root/include && cf_search="$cf_search /opt/$cf_ncuhdr_root/include"
5869 test -d /opt/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /opt/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
5872 test "$HOME" != "$prefix" && \
5873 test -d "$HOME" && \
5874 (test $prefix = NONE || test "$HOME" != "$prefix") && {
5875 test -n "$verbose" && echo " ... testing for include-directories under $HOME"
5876 test -d $HOME/include && cf_search="$cf_search $HOME/include"
5877 test -d $HOME/include/$cf_ncuhdr_root && cf_search="$cf_search $HOME/include/$cf_ncuhdr_root"
5878 test -d $HOME/include/$cf_ncuhdr_root/include && cf_search="$cf_search $HOME/include/$cf_ncuhdr_root/include"
5879 test -d $HOME/$cf_ncuhdr_root/include && cf_search="$cf_search $HOME/$cf_ncuhdr_root/include"
5880 test -d $HOME/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $HOME/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
5883 test "$includedir" != NONE && \
5884 test "$includedir" != "/usr/include" && \
5885 test -d "$includedir" && {
5886 test -d $includedir && cf_search="$cf_search $includedir"
5887 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
5890 test "$oldincludedir" != NONE && \
5891 test "$oldincludedir" != "/usr/include" && \
5892 test -d "$oldincludedir" && {
5893 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
5894 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
5897 cf_search="$cf_search $cf_header_path_list"
5899 test -n "$verbose" && echo search path $cf_search
5900 cf_save2_CPPFLAGS="$CPPFLAGS"
5901 for cf_incdir in $cf_search
5904 if test -n "$cf_incdir" ; then
5905 for cf_add_incdir in $cf_incdir
5907 while test $cf_add_incdir != /usr/include
5909 if test -d $cf_add_incdir
5912 if test -n "$CFLAGS$CPPFLAGS" ; then
5913 # a loop is needed to ensure we can add subdirs of existing dirs
5914 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
5915 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
5916 cf_have_incdir=yes; break
5921 if test "$cf_have_incdir" = no ; then
5922 if test "$cf_add_incdir" = /usr/local/include ; then
5923 if test "$GCC" = yes
5925 cf_save_CPPFLAGS=$CPPFLAGS
5926 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
5927 cat >conftest.$ac_ext <<_ACEOF
5928 #line 5928 "configure"
5929 #include "confdefs.h"
5939 rm -f conftest.$ac_objext
5940 if { (eval echo "$as_me:5940: \"$ac_compile\"") >&5
5941 (eval $ac_compile) 2>&5
5943 echo "$as_me:5943: \$? = $ac_status" >&5
5944 (exit $ac_status); } &&
5945 { ac_try='test -s conftest.$ac_objext'
5946 { (eval echo "$as_me:5946: \"$ac_try\"") >&5
5949 echo "$as_me:5949: \$? = $ac_status" >&5
5950 (exit $ac_status); }; }; then
5953 echo "$as_me: failed program was:" >&5
5954 cat conftest.$ac_ext >&5
5957 rm -f conftest.$ac_objext conftest.$ac_ext
5958 CPPFLAGS=$cf_save_CPPFLAGS
5963 if test "$cf_have_incdir" = no ; then
5964 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
5966 echo "${as_me:-configure}:5966: testing adding $cf_add_incdir to include-path ..." 1>&5
5968 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
5970 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
5971 test "$cf_top_incdir" = "$cf_add_incdir" && break
5972 cf_add_incdir="$cf_top_incdir"
5986 cat >conftest.$ac_ext <<_ACEOF
5987 #line 5987 "configure"
5988 #include "confdefs.h"
5990 #include <$cf_header>
5995 #ifdef NCURSES_VERSION
5997 printf("%s\n", NCURSES_VERSION);
6010 rm -f conftest.$ac_objext
6011 if { (eval echo "$as_me:6011: \"$ac_compile\"") >&5
6012 (eval $ac_compile) 2>&5
6014 echo "$as_me:6014: \$? = $ac_status" >&5
6015 (exit $ac_status); } &&
6016 { ac_try='test -s conftest.$ac_objext'
6017 { (eval echo "$as_me:6017: \"$ac_try\"") >&5
6020 echo "$as_me:6020: \$? = $ac_status" >&5
6021 (exit $ac_status); }; }; then
6022 cf_cv_ncurses_h2=$cf_header
6025 echo "$as_me: failed program was:" >&5
6026 cat conftest.$ac_ext >&5
6029 rm -f conftest.$ac_objext conftest.$ac_ext
6031 if test "$cf_cv_ncurses_h2" != no ; then
6032 cf_cv_ncurses_h2=$cf_incdir/$cf_header
6033 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
6036 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
6038 CPPFLAGS="$cf_save2_CPPFLAGS"
6039 test "$cf_cv_ncurses_h2" != no && break
6041 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:6041: error: not found" >&5
6042 echo "$as_me: error: not found" >&2;}
6043 { (exit 1); exit 1; }; }
6046 echo "$as_me:6046: result: $cf_cv_ncurses_h2" >&5
6047 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
6049 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
6050 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
6051 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
6052 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
6055 if test -n "$cf_1st_incdir" ; then
6056 for cf_add_incdir in $cf_1st_incdir
6058 while test $cf_add_incdir != /usr/include
6060 if test -d $cf_add_incdir
6063 if test -n "$CFLAGS$CPPFLAGS" ; then
6064 # a loop is needed to ensure we can add subdirs of existing dirs
6065 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
6066 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
6067 cf_have_incdir=yes; break
6072 if test "$cf_have_incdir" = no ; then
6073 if test "$cf_add_incdir" = /usr/local/include ; then
6074 if test "$GCC" = yes
6076 cf_save_CPPFLAGS=$CPPFLAGS
6077 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6078 cat >conftest.$ac_ext <<_ACEOF
6079 #line 6079 "configure"
6080 #include "confdefs.h"
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
6104 echo "$as_me: failed program was:" >&5
6105 cat conftest.$ac_ext >&5
6108 rm -f conftest.$ac_objext conftest.$ac_ext
6109 CPPFLAGS=$cf_save_CPPFLAGS
6114 if test "$cf_have_incdir" = no ; then
6115 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
6117 echo "${as_me:-configure}:6117: testing adding $cf_add_incdir to include-path ..." 1>&5
6119 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6121 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
6122 test "$cf_top_incdir" = "$cf_add_incdir" && break
6123 cf_add_incdir="$cf_top_incdir"
6134 # Set definitions to allow ifdef'ing for ncurses.h
6136 case $cf_cv_ncurses_header in # (vi
6139 cat >>confdefs.h <<\EOF
6140 #define HAVE_NCURSES_H 1
6146 case $cf_cv_ncurses_header in # (vi
6147 ncurses/curses.h|ncurses/ncurses.h)
6149 cat >>confdefs.h <<\EOF
6150 #define HAVE_NCURSES_NCURSES_H 1
6154 ncursesw/curses.h|ncursesw/ncurses.h)
6156 cat >>confdefs.h <<\EOF
6157 #define HAVE_NCURSESW_NCURSES_H 1
6163 echo "$as_me:6163: checking for terminfo header" >&5
6164 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
6165 if test "${cf_cv_term_header+set}" = set; then
6166 echo $ECHO_N "(cached) $ECHO_C" >&6
6169 case ${cf_cv_ncurses_header} in #(vi
6170 */ncurses.h|*/ncursesw.h) #(vi
6171 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
6174 cf_term_header=term.h
6178 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
6180 cat >conftest.$ac_ext <<_ACEOF
6181 #line 6181 "configure"
6182 #include "confdefs.h"
6184 #include <${cf_cv_ncurses_header:-curses.h}>
6190 int x = auto_left_margin
6195 rm -f conftest.$ac_objext
6196 if { (eval echo "$as_me:6196: \"$ac_compile\"") >&5
6197 (eval $ac_compile) 2>&5
6199 echo "$as_me:6199: \$? = $ac_status" >&5
6200 (exit $ac_status); } &&
6201 { ac_try='test -s conftest.$ac_objext'
6202 { (eval echo "$as_me:6202: \"$ac_try\"") >&5
6205 echo "$as_me:6205: \$? = $ac_status" >&5
6206 (exit $ac_status); }; }; then
6208 cf_cv_term_header="$cf_test"
6210 echo "$as_me: failed program was:" >&5
6211 cat conftest.$ac_ext >&5
6213 cf_cv_term_header=unknown
6216 rm -f conftest.$ac_objext conftest.$ac_ext
6217 test "$cf_cv_term_header" != unknown && break
6221 echo "$as_me:6221: result: $cf_cv_term_header" >&5
6222 echo "${ECHO_T}$cf_cv_term_header" >&6
6224 # Set definitions to allow ifdef'ing to accommodate subdirectories
6226 case $cf_cv_term_header in # (vi
6229 cat >>confdefs.h <<\EOF
6230 #define HAVE_TERM_H 1
6236 case $cf_cv_term_header in # (vi
6237 ncurses/term.h) #(vi
6239 cat >>confdefs.h <<\EOF
6240 #define HAVE_NCURSES_TERM_H 1
6246 cat >>confdefs.h <<\EOF
6247 #define HAVE_NCURSESW_TERM_H 1
6253 # some applications need this, but should check for NCURSES_VERSION
6255 cat >>confdefs.h <<\EOF
6259 echo "$as_me:6259: checking for ncurses version" >&5
6260 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
6261 if test "${cf_cv_ncurses_version+set}" = set; then
6262 echo $ECHO_N "(cached) $ECHO_C" >&6
6265 cf_cv_ncurses_version=no
6268 if test "$cross_compiling" = yes; then
6270 # This will not work if the preprocessor splits the line after the
6271 # Autoconf token. The 'unproto' program does that.
6272 cat > conftest.$ac_ext <<EOF
6273 #include <${cf_cv_ncurses_header:-curses.h}>
6275 #ifdef NCURSES_VERSION
6276 Autoconf NCURSES_VERSION
6284 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
6285 { (eval echo "$as_me:6285: \"$cf_try\"") >&5
6288 echo "$as_me:6288: \$? = $ac_status" >&5
6289 (exit $ac_status); }
6290 if test -f conftest.out ; then
6291 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
6292 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
6297 cat >conftest.$ac_ext <<_ACEOF
6298 #line 6298 "configure"
6299 #include "confdefs.h"
6301 #include <${cf_cv_ncurses_header:-curses.h}>
6305 FILE *fp = fopen("$cf_tempfile", "w");
6306 #ifdef NCURSES_VERSION
6307 # ifdef NCURSES_VERSION_PATCH
6308 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
6310 fprintf(fp, "%s\n", NCURSES_VERSION);
6314 fprintf(fp, "old\n");
6319 ${cf_cv_main_return:-return}(0);
6322 rm -f conftest$ac_exeext
6323 if { (eval echo "$as_me:6323: \"$ac_link\"") >&5
6324 (eval $ac_link) 2>&5
6326 echo "$as_me:6326: \$? = $ac_status" >&5
6327 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
6328 { (eval echo "$as_me:6328: \"$ac_try\"") >&5
6331 echo "$as_me:6331: \$? = $ac_status" >&5
6332 (exit $ac_status); }; }; then
6334 cf_cv_ncurses_version=`cat $cf_tempfile`
6336 echo "$as_me: program exited with status $ac_status" >&5
6337 echo "$as_me: failed program was:" >&5
6338 cat conftest.$ac_ext >&5
6340 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6345 echo "$as_me:6345: result: $cf_cv_ncurses_version" >&5
6346 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
6347 test "$cf_cv_ncurses_version" = no ||
6348 cat >>confdefs.h <<\EOF
6352 cf_nculib_root=ncurses
6353 # This works, except for the special case where we find gpm, but
6354 # ncurses is in a nonstandard location via $LIBS, and we really want
6357 cf_ncurses_SAVE="$LIBS"
6358 echo "$as_me:6358: checking for Gpm_Open in -lgpm" >&5
6359 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
6360 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
6361 echo $ECHO_N "(cached) $ECHO_C" >&6
6363 ac_check_lib_save_LIBS=$LIBS
6365 cat >conftest.$ac_ext <<_ACEOF
6366 #line 6366 "configure"
6367 #include "confdefs.h"
6369 /* Override any gcc2 internal prototype to avoid an error. */
6373 /* We use char because int might match the return type of a gcc2
6374 builtin and then its argument prototype would still apply. */
6384 rm -f conftest.$ac_objext conftest$ac_exeext
6385 if { (eval echo "$as_me:6385: \"$ac_link\"") >&5
6386 (eval $ac_link) 2>&5
6388 echo "$as_me:6388: \$? = $ac_status" >&5
6389 (exit $ac_status); } &&
6390 { ac_try='test -s conftest$ac_exeext'
6391 { (eval echo "$as_me:6391: \"$ac_try\"") >&5
6394 echo "$as_me:6394: \$? = $ac_status" >&5
6395 (exit $ac_status); }; }; then
6396 ac_cv_lib_gpm_Gpm_Open=yes
6398 echo "$as_me: failed program was:" >&5
6399 cat conftest.$ac_ext >&5
6400 ac_cv_lib_gpm_Gpm_Open=no
6402 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6403 LIBS=$ac_check_lib_save_LIBS
6405 echo "$as_me:6405: result: $ac_cv_lib_gpm_Gpm_Open" >&5
6406 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
6407 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
6408 echo "$as_me:6408: checking for initscr in -lgpm" >&5
6409 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
6410 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
6411 echo $ECHO_N "(cached) $ECHO_C" >&6
6413 ac_check_lib_save_LIBS=$LIBS
6415 cat >conftest.$ac_ext <<_ACEOF
6416 #line 6416 "configure"
6417 #include "confdefs.h"
6419 /* Override any gcc2 internal prototype to avoid an error. */
6423 /* We use char because int might match the return type of a gcc2
6424 builtin and then its argument prototype would still apply. */
6434 rm -f conftest.$ac_objext conftest$ac_exeext
6435 if { (eval echo "$as_me:6435: \"$ac_link\"") >&5
6436 (eval $ac_link) 2>&5
6438 echo "$as_me:6438: \$? = $ac_status" >&5
6439 (exit $ac_status); } &&
6440 { ac_try='test -s conftest$ac_exeext'
6441 { (eval echo "$as_me:6441: \"$ac_try\"") >&5
6444 echo "$as_me:6444: \$? = $ac_status" >&5
6445 (exit $ac_status); }; }; then
6446 ac_cv_lib_gpm_initscr=yes
6448 echo "$as_me: failed program was:" >&5
6449 cat conftest.$ac_ext >&5
6450 ac_cv_lib_gpm_initscr=no
6452 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6453 LIBS=$ac_check_lib_save_LIBS
6455 echo "$as_me:6455: result: $ac_cv_lib_gpm_initscr" >&5
6456 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
6457 if test $ac_cv_lib_gpm_initscr = yes; then
6458 LIBS="$cf_ncurses_SAVE"
6460 cf_ncurses_LIBS="-lgpm"
6465 case $host_os in #(vi
6467 # This is only necessary if you are linking against an obsolete
6468 # version of ncurses (but it should do no harm, since it's static).
6469 if test "$cf_nculib_root" = ncurses ; then
6470 echo "$as_me:6470: checking for tgoto in -lmytinfo" >&5
6471 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
6472 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
6473 echo $ECHO_N "(cached) $ECHO_C" >&6
6475 ac_check_lib_save_LIBS=$LIBS
6476 LIBS="-lmytinfo $LIBS"
6477 cat >conftest.$ac_ext <<_ACEOF
6478 #line 6478 "configure"
6479 #include "confdefs.h"
6481 /* Override any gcc2 internal prototype to avoid an error. */
6485 /* We use char because int might match the return type of a gcc2
6486 builtin and then its argument prototype would still apply. */
6496 rm -f conftest.$ac_objext conftest$ac_exeext
6497 if { (eval echo "$as_me:6497: \"$ac_link\"") >&5
6498 (eval $ac_link) 2>&5
6500 echo "$as_me:6500: \$? = $ac_status" >&5
6501 (exit $ac_status); } &&
6502 { ac_try='test -s conftest$ac_exeext'
6503 { (eval echo "$as_me:6503: \"$ac_try\"") >&5
6506 echo "$as_me:6506: \$? = $ac_status" >&5
6507 (exit $ac_status); }; }; then
6508 ac_cv_lib_mytinfo_tgoto=yes
6510 echo "$as_me: failed program was:" >&5
6511 cat conftest.$ac_ext >&5
6512 ac_cv_lib_mytinfo_tgoto=no
6514 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6515 LIBS=$ac_check_lib_save_LIBS
6517 echo "$as_me:6517: result: $ac_cv_lib_mytinfo_tgoto" >&5
6518 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
6519 if test $ac_cv_lib_mytinfo_tgoto = yes; then
6520 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
6527 LIBS="$cf_ncurses_LIBS $LIBS"
6529 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
6531 LIBS="-l$cf_nculib_root $LIBS"
6534 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
6536 echo "$as_me:6536: checking for initscr" >&5
6537 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
6538 if test "${ac_cv_func_initscr+set}" = set; then
6539 echo $ECHO_N "(cached) $ECHO_C" >&6
6541 cat >conftest.$ac_ext <<_ACEOF
6542 #line 6542 "configure"
6543 #include "confdefs.h"
6544 /* System header to define __stub macros and hopefully few prototypes,
6545 which can conflict with char initscr (); below. */
6547 /* Override any gcc2 internal prototype to avoid an error. */
6551 /* We use char because int might match the return type of a gcc2
6552 builtin and then its argument prototype would still apply. */
6559 /* The GNU C library defines this for functions which it implements
6560 to always fail with ENOSYS. Some functions are actually named
6561 something starting with __ and the normal name is an alias. */
6562 #if defined (__stub_initscr) || defined (__stub___initscr)
6565 f = initscr; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
6572 rm -f conftest.$ac_objext conftest$ac_exeext
6573 if { (eval echo "$as_me:6573: \"$ac_link\"") >&5
6574 (eval $ac_link) 2>&5
6576 echo "$as_me:6576: \$? = $ac_status" >&5
6577 (exit $ac_status); } &&
6578 { ac_try='test -s conftest$ac_exeext'
6579 { (eval echo "$as_me:6579: \"$ac_try\"") >&5
6582 echo "$as_me:6582: \$? = $ac_status" >&5
6583 (exit $ac_status); }; }; then
6584 ac_cv_func_initscr=yes
6586 echo "$as_me: failed program was:" >&5
6587 cat conftest.$ac_ext >&5
6588 ac_cv_func_initscr=no
6590 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6592 echo "$as_me:6592: result: $ac_cv_func_initscr" >&5
6593 echo "${ECHO_T}$ac_cv_func_initscr" >&6
6594 if test $ac_cv_func_initscr = yes; then
6595 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
6598 cf_save_LIBS="$LIBS"
6599 echo "$as_me:6599: checking for initscr in -l$cf_nculib_root" >&5
6600 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
6601 LIBS="-l$cf_nculib_root $LIBS"
6602 cat >conftest.$ac_ext <<_ACEOF
6603 #line 6603 "configure"
6604 #include "confdefs.h"
6605 #include <${cf_cv_ncurses_header:-curses.h}>
6614 rm -f conftest.$ac_objext conftest$ac_exeext
6615 if { (eval echo "$as_me:6615: \"$ac_link\"") >&5
6616 (eval $ac_link) 2>&5
6618 echo "$as_me:6618: \$? = $ac_status" >&5
6619 (exit $ac_status); } &&
6620 { ac_try='test -s conftest$ac_exeext'
6621 { (eval echo "$as_me:6621: \"$ac_try\"") >&5
6624 echo "$as_me:6624: \$? = $ac_status" >&5
6625 (exit $ac_status); }; }; then
6626 echo "$as_me:6626: result: yes" >&5
6627 echo "${ECHO_T}yes" >&6
6628 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
6631 echo "$as_me: failed program was:" >&5
6632 cat conftest.$ac_ext >&5
6633 echo "$as_me:6633: result: no" >&5
6634 echo "${ECHO_T}no" >&6
6637 cf_library_path_list=""
6638 if test -n "${LDFLAGS}${LIBS}" ; then
6639 for cf_library_path in $LDFLAGS $LIBS
6641 case $cf_library_path in #(vi
6643 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
6645 test "$cf_library_path" != "NONE" && \
6646 test -d "$cf_library_path" && \
6648 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
6649 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
6650 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
6651 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
6652 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
6653 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"
6656 cf_library_path_list="$cf_library_path_list $cf_search"
6664 test "/usr" != "$prefix" && \
6666 (test $prefix = NONE || test "/usr" != "$prefix") && {
6667 test -n "$verbose" && echo " ... testing for lib-directories under /usr"
6668 test -d /usr/lib && cf_search="$cf_search /usr/lib"
6669 test -d /usr/lib/$cf_nculib_root && cf_search="$cf_search /usr/lib/$cf_nculib_root"
6670 test -d /usr/lib/$cf_nculib_root/lib && cf_search="$cf_search /usr/lib/$cf_nculib_root/lib"
6671 test -d /usr/$cf_nculib_root/lib && cf_search="$cf_search /usr/$cf_nculib_root/lib"
6672 test -d /usr/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /usr/$cf_nculib_root/lib/$cf_nculib_root"
6675 test "$prefix" != "NONE" && \
6676 test -d "$prefix" && \
6678 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
6679 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
6680 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
6681 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
6682 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
6683 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
6686 test "/usr/local" != "$prefix" && \
6687 test -d "/usr/local" && \
6688 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
6689 test -n "$verbose" && echo " ... testing for lib-directories under /usr/local"
6690 test -d /usr/local/lib && cf_search="$cf_search /usr/local/lib"
6691 test -d /usr/local/lib/$cf_nculib_root && cf_search="$cf_search /usr/local/lib/$cf_nculib_root"
6692 test -d /usr/local/lib/$cf_nculib_root/lib && cf_search="$cf_search /usr/local/lib/$cf_nculib_root/lib"
6693 test -d /usr/local/$cf_nculib_root/lib && cf_search="$cf_search /usr/local/$cf_nculib_root/lib"
6694 test -d /usr/local/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /usr/local/$cf_nculib_root/lib/$cf_nculib_root"
6697 test "/opt" != "$prefix" && \
6699 (test $prefix = NONE || test "/opt" != "$prefix") && {
6700 test -n "$verbose" && echo " ... testing for lib-directories under /opt"
6701 test -d /opt/lib && cf_search="$cf_search /opt/lib"
6702 test -d /opt/lib/$cf_nculib_root && cf_search="$cf_search /opt/lib/$cf_nculib_root"
6703 test -d /opt/lib/$cf_nculib_root/lib && cf_search="$cf_search /opt/lib/$cf_nculib_root/lib"
6704 test -d /opt/$cf_nculib_root/lib && cf_search="$cf_search /opt/$cf_nculib_root/lib"
6705 test -d /opt/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /opt/$cf_nculib_root/lib/$cf_nculib_root"
6708 test "$HOME" != "$prefix" && \
6709 test -d "$HOME" && \
6710 (test $prefix = NONE || test "$HOME" != "$prefix") && {
6711 test -n "$verbose" && echo " ... testing for lib-directories under $HOME"
6712 test -d $HOME/lib && cf_search="$cf_search $HOME/lib"
6713 test -d $HOME/lib/$cf_nculib_root && cf_search="$cf_search $HOME/lib/$cf_nculib_root"
6714 test -d $HOME/lib/$cf_nculib_root/lib && cf_search="$cf_search $HOME/lib/$cf_nculib_root/lib"
6715 test -d $HOME/$cf_nculib_root/lib && cf_search="$cf_search $HOME/$cf_nculib_root/lib"
6716 test -d $HOME/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $HOME/$cf_nculib_root/lib/$cf_nculib_root"
6719 cf_search="$cf_library_path_list $cf_search"
6721 for cf_libdir in $cf_search
6723 echo "$as_me:6723: checking for -l$cf_nculib_root in $cf_libdir" >&5
6724 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
6725 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
6726 cat >conftest.$ac_ext <<_ACEOF
6727 #line 6727 "configure"
6728 #include "confdefs.h"
6729 #include <${cf_cv_ncurses_header:-curses.h}>
6738 rm -f conftest.$ac_objext conftest$ac_exeext
6739 if { (eval echo "$as_me:6739: \"$ac_link\"") >&5
6740 (eval $ac_link) 2>&5
6742 echo "$as_me:6742: \$? = $ac_status" >&5
6743 (exit $ac_status); } &&
6744 { ac_try='test -s conftest$ac_exeext'
6745 { (eval echo "$as_me:6745: \"$ac_try\"") >&5
6748 echo "$as_me:6748: \$? = $ac_status" >&5
6749 (exit $ac_status); }; }; then
6750 echo "$as_me:6750: result: yes" >&5
6751 echo "${ECHO_T}yes" >&6
6752 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
6755 echo "$as_me: failed program was:" >&5
6756 cat conftest.$ac_ext >&5
6757 echo "$as_me:6757: result: no" >&5
6758 echo "${ECHO_T}no" >&6
6759 LIBS="$cf_save_LIBS"
6761 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6765 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6769 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
6771 if test $cf_found_library = no ; then
6772 { { echo "$as_me:6772: error: Cannot link $cf_nculib_root library" >&5
6773 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
6774 { (exit 1); exit 1; }; }
6779 if test -n "$cf_ncurses_LIBS" ; then
6780 echo "$as_me:6780: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
6781 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
6782 cf_ncurses_SAVE="$LIBS"
6783 for p in $cf_ncurses_LIBS ; do
6784 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
6785 if test "$q" != "$LIBS" ; then
6789 cat >conftest.$ac_ext <<_ACEOF
6790 #line 6790 "configure"
6791 #include "confdefs.h"
6792 #include <${cf_cv_ncurses_header:-curses.h}>
6796 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
6801 rm -f conftest.$ac_objext conftest$ac_exeext
6802 if { (eval echo "$as_me:6802: \"$ac_link\"") >&5
6803 (eval $ac_link) 2>&5
6805 echo "$as_me:6805: \$? = $ac_status" >&5
6806 (exit $ac_status); } &&
6807 { ac_try='test -s conftest$ac_exeext'
6808 { (eval echo "$as_me:6808: \"$ac_try\"") >&5
6811 echo "$as_me:6811: \$? = $ac_status" >&5
6812 (exit $ac_status); }; }; then
6813 echo "$as_me:6813: result: yes" >&5
6814 echo "${ECHO_T}yes" >&6
6816 echo "$as_me: failed program was:" >&5
6817 cat conftest.$ac_ext >&5
6818 echo "$as_me:6818: result: no" >&5
6819 echo "${ECHO_T}no" >&6
6820 LIBS="$cf_ncurses_SAVE"
6822 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6825 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
6827 cat >>confdefs.h <<EOF
6828 #define $cf_nculib_ROOT 1
6836 echo "$as_me:6836: checking for multibyte character support" >&5
6837 echo $ECHO_N "checking for multibyte character support... $ECHO_C" >&6
6838 if test "${cf_cv_utf8_lib+set}" = set; then
6839 echo $ECHO_N "(cached) $ECHO_C" >&6
6842 cf_save_LIBS="$LIBS"
6843 cat >conftest.$ac_ext <<_ACEOF
6844 #line 6844 "configure"
6845 #include "confdefs.h"
6856 rm -f conftest.$ac_objext conftest$ac_exeext
6857 if { (eval echo "$as_me:6857: \"$ac_link\"") >&5
6858 (eval $ac_link) 2>&5
6860 echo "$as_me:6860: \$? = $ac_status" >&5
6861 (exit $ac_status); } &&
6862 { ac_try='test -s conftest$ac_exeext'
6863 { (eval echo "$as_me:6863: \"$ac_try\"") >&5
6866 echo "$as_me:6866: \$? = $ac_status" >&5
6867 (exit $ac_status); }; }; then
6870 echo "$as_me: failed program was:" >&5
6871 cat conftest.$ac_ext >&5
6873 # If the linkage is not already in the $CPPFLAGS/$LDFLAGS configuration, these
6874 # will be set on completion of the AC_TRY_LINK below.
6875 cf_cv_header_path_utf8=
6876 cf_cv_library_path_utf8=
6878 echo "${as_me:-configure}:6878: testing Starting FIND_LINKAGE(utf8,) ..." 1>&5
6880 cf_save_LIBS="$LIBS"
6882 cat >conftest.$ac_ext <<_ACEOF
6883 #line 6883 "configure"
6884 #include "confdefs.h"
6886 #include <libutf8.h>
6895 rm -f conftest.$ac_objext conftest$ac_exeext
6896 if { (eval echo "$as_me:6896: \"$ac_link\"") >&5
6897 (eval $ac_link) 2>&5
6899 echo "$as_me:6899: \$? = $ac_status" >&5
6900 (exit $ac_status); } &&
6901 { ac_try='test -s conftest$ac_exeext'
6902 { (eval echo "$as_me:6902: \"$ac_try\"") >&5
6905 echo "$as_me:6905: \$? = $ac_status" >&5
6906 (exit $ac_status); }; }; then
6908 cf_cv_find_linkage_utf8=yes
6909 cf_cv_header_path_utf8=/usr/include
6910 cf_cv_library_path_utf8=/usr/lib
6913 echo "$as_me: failed program was:" >&5
6914 cat conftest.$ac_ext >&5
6916 LIBS="-lutf8 $cf_save_LIBS"
6918 cat >conftest.$ac_ext <<_ACEOF
6919 #line 6919 "configure"
6920 #include "confdefs.h"
6922 #include <libutf8.h>
6931 rm -f conftest.$ac_objext conftest$ac_exeext
6932 if { (eval echo "$as_me:6932: \"$ac_link\"") >&5
6933 (eval $ac_link) 2>&5
6935 echo "$as_me:6935: \$? = $ac_status" >&5
6936 (exit $ac_status); } &&
6937 { ac_try='test -s conftest$ac_exeext'
6938 { (eval echo "$as_me:6938: \"$ac_try\"") >&5
6941 echo "$as_me:6941: \$? = $ac_status" >&5
6942 (exit $ac_status); }; }; then
6944 cf_cv_find_linkage_utf8=yes
6945 cf_cv_header_path_utf8=/usr/include
6946 cf_cv_library_path_utf8=/usr/lib
6947 cf_cv_library_file_utf8="-lutf8"
6950 echo "$as_me: failed program was:" >&5
6951 cat conftest.$ac_ext >&5
6953 cf_cv_find_linkage_utf8=no
6954 LIBS="$cf_save_LIBS"
6956 test -n "$verbose" && echo " find linkage for utf8 library" 1>&6
6958 echo "${as_me:-configure}:6958: testing find linkage for utf8 library ..." 1>&5
6960 echo "${as_me:-configure}:6960: testing Searching for headers in FIND_LINKAGE(utf8,) ..." 1>&5
6962 cf_save_CPPFLAGS="$CPPFLAGS"
6963 cf_test_CPPFLAGS="$CPPFLAGS"
6967 # collect the current set of include-directories from compiler flags
6968 cf_header_path_list=""
6969 if test -n "${CFLAGS}${CPPFLAGS}" ; then
6970 for cf_header_path in $CPPFLAGS $CFLAGS
6972 case $cf_header_path in #(vi
6974 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
6976 test "$cf_header_path" != "NONE" && \
6977 test -d "$cf_header_path" && \
6979 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
6980 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
6981 test -d $cf_header_path/include/utf8 && cf_search="$cf_search $cf_header_path/include/utf8"
6982 test -d $cf_header_path/include/utf8/include && cf_search="$cf_search $cf_header_path/include/utf8/include"
6983 test -d $cf_header_path/utf8/include && cf_search="$cf_search $cf_header_path/utf8/include"
6984 test -d $cf_header_path/utf8/include/utf8 && cf_search="$cf_search $cf_header_path/utf8/include/utf8"
6987 cf_header_path_list="$cf_header_path_list $cf_search"
6993 # add the variations for the package we are looking for
6997 test "/usr" != "$prefix" && \
6999 (test $prefix = NONE || test "/usr" != "$prefix") && {
7000 test -n "$verbose" && echo " ... testing for include-directories under /usr"
7001 test -d /usr/include && cf_search="$cf_search /usr/include"
7002 test -d /usr/include/utf8 && cf_search="$cf_search /usr/include/utf8"
7003 test -d /usr/include/utf8/include && cf_search="$cf_search /usr/include/utf8/include"
7004 test -d /usr/utf8/include && cf_search="$cf_search /usr/utf8/include"
7005 test -d /usr/utf8/include/utf8 && cf_search="$cf_search /usr/utf8/include/utf8"
7008 test "$prefix" != "NONE" && \
7009 test -d "$prefix" && \
7011 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
7012 test -d $prefix/include && cf_search="$cf_search $prefix/include"
7013 test -d $prefix/include/utf8 && cf_search="$cf_search $prefix/include/utf8"
7014 test -d $prefix/include/utf8/include && cf_search="$cf_search $prefix/include/utf8/include"
7015 test -d $prefix/utf8/include && cf_search="$cf_search $prefix/utf8/include"
7016 test -d $prefix/utf8/include/utf8 && cf_search="$cf_search $prefix/utf8/include/utf8"
7019 test "/usr/local" != "$prefix" && \
7020 test -d "/usr/local" && \
7021 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
7022 test -n "$verbose" && echo " ... testing for include-directories under /usr/local"
7023 test -d /usr/local/include && cf_search="$cf_search /usr/local/include"
7024 test -d /usr/local/include/utf8 && cf_search="$cf_search /usr/local/include/utf8"
7025 test -d /usr/local/include/utf8/include && cf_search="$cf_search /usr/local/include/utf8/include"
7026 test -d /usr/local/utf8/include && cf_search="$cf_search /usr/local/utf8/include"
7027 test -d /usr/local/utf8/include/utf8 && cf_search="$cf_search /usr/local/utf8/include/utf8"
7030 test "/opt" != "$prefix" && \
7032 (test $prefix = NONE || test "/opt" != "$prefix") && {
7033 test -n "$verbose" && echo " ... testing for include-directories under /opt"
7034 test -d /opt/include && cf_search="$cf_search /opt/include"
7035 test -d /opt/include/utf8 && cf_search="$cf_search /opt/include/utf8"
7036 test -d /opt/include/utf8/include && cf_search="$cf_search /opt/include/utf8/include"
7037 test -d /opt/utf8/include && cf_search="$cf_search /opt/utf8/include"
7038 test -d /opt/utf8/include/utf8 && cf_search="$cf_search /opt/utf8/include/utf8"
7041 test "$HOME" != "$prefix" && \
7042 test -d "$HOME" && \
7043 (test $prefix = NONE || test "$HOME" != "$prefix") && {
7044 test -n "$verbose" && echo " ... testing for include-directories under $HOME"
7045 test -d $HOME/include && cf_search="$cf_search $HOME/include"
7046 test -d $HOME/include/utf8 && cf_search="$cf_search $HOME/include/utf8"
7047 test -d $HOME/include/utf8/include && cf_search="$cf_search $HOME/include/utf8/include"
7048 test -d $HOME/utf8/include && cf_search="$cf_search $HOME/utf8/include"
7049 test -d $HOME/utf8/include/utf8 && cf_search="$cf_search $HOME/utf8/include/utf8"
7052 test "$includedir" != NONE && \
7053 test "$includedir" != "/usr/include" && \
7054 test -d "$includedir" && {
7055 test -d $includedir && cf_search="$cf_search $includedir"
7056 test -d $includedir/utf8 && cf_search="$cf_search $includedir/utf8"
7059 test "$oldincludedir" != NONE && \
7060 test "$oldincludedir" != "/usr/include" && \
7061 test -d "$oldincludedir" && {
7062 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
7063 test -d $oldincludedir/utf8 && cf_search="$cf_search $oldincludedir/utf8"
7066 cf_search="$cf_search $cf_header_path_list"
7068 for cf_cv_header_path_utf8 in $cf_search
7070 if test -d $cf_cv_header_path_utf8 ; then
7071 test -n "$verbose" && echo " ... testing $cf_cv_header_path_utf8" 1>&6
7073 echo "${as_me:-configure}:7073: testing ... testing $cf_cv_header_path_utf8 ..." 1>&5
7075 CPPFLAGS="$cf_save_CPPFLAGS -I$cf_cv_header_path_utf8"
7076 cat >conftest.$ac_ext <<_ACEOF
7077 #line 7077 "configure"
7078 #include "confdefs.h"
7080 #include <libutf8.h>
7089 rm -f conftest.$ac_objext
7090 if { (eval echo "$as_me:7090: \"$ac_compile\"") >&5
7091 (eval $ac_compile) 2>&5
7093 echo "$as_me:7093: \$? = $ac_status" >&5
7094 (exit $ac_status); } &&
7095 { ac_try='test -s conftest.$ac_objext'
7096 { (eval echo "$as_me:7096: \"$ac_try\"") >&5
7099 echo "$as_me:7099: \$? = $ac_status" >&5
7100 (exit $ac_status); }; }; then
7102 test -n "$verbose" && echo " ... found utf8 headers in $cf_cv_header_path_utf8" 1>&6
7104 echo "${as_me:-configure}:7104: testing ... found utf8 headers in $cf_cv_header_path_utf8 ..." 1>&5
7106 cf_cv_find_linkage_utf8=maybe
7107 cf_test_CPPFLAGS="$CPPFLAGS"
7110 echo "$as_me: failed program was:" >&5
7111 cat conftest.$ac_ext >&5
7113 CPPFLAGS="$cf_save_CPPFLAGS"
7116 rm -f conftest.$ac_objext conftest.$ac_ext
7120 if test "$cf_cv_find_linkage_utf8" = maybe ; then
7122 echo "${as_me:-configure}:7122: testing Searching for utf8 library in FIND_LINKAGE(utf8,) ..." 1>&5
7124 cf_save_LIBS="$LIBS"
7125 cf_save_LDFLAGS="$LDFLAGS"
7127 if test "$cf_cv_find_linkage_utf8" != yes ; then
7130 cf_library_path_list=""
7131 if test -n "${LDFLAGS}${LIBS}" ; then
7132 for cf_library_path in $LDFLAGS $LIBS
7134 case $cf_library_path in #(vi
7136 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
7138 test "$cf_library_path" != "NONE" && \
7139 test -d "$cf_library_path" && \
7141 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
7142 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
7143 test -d $cf_library_path/lib/utf8 && cf_search="$cf_search $cf_library_path/lib/utf8"
7144 test -d $cf_library_path/lib/utf8/lib && cf_search="$cf_search $cf_library_path/lib/utf8/lib"
7145 test -d $cf_library_path/utf8/lib && cf_search="$cf_search $cf_library_path/utf8/lib"
7146 test -d $cf_library_path/utf8/lib/utf8 && cf_search="$cf_search $cf_library_path/utf8/lib/utf8"
7149 cf_library_path_list="$cf_library_path_list $cf_search"
7157 test "/usr" != "$prefix" && \
7159 (test $prefix = NONE || test "/usr" != "$prefix") && {
7160 test -n "$verbose" && echo " ... testing for lib-directories under /usr"
7161 test -d /usr/lib && cf_search="$cf_search /usr/lib"
7162 test -d /usr/lib/utf8 && cf_search="$cf_search /usr/lib/utf8"
7163 test -d /usr/lib/utf8/lib && cf_search="$cf_search /usr/lib/utf8/lib"
7164 test -d /usr/utf8/lib && cf_search="$cf_search /usr/utf8/lib"
7165 test -d /usr/utf8/lib/utf8 && cf_search="$cf_search /usr/utf8/lib/utf8"
7168 test "$prefix" != "NONE" && \
7169 test -d "$prefix" && \
7171 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
7172 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
7173 test -d $prefix/lib/utf8 && cf_search="$cf_search $prefix/lib/utf8"
7174 test -d $prefix/lib/utf8/lib && cf_search="$cf_search $prefix/lib/utf8/lib"
7175 test -d $prefix/utf8/lib && cf_search="$cf_search $prefix/utf8/lib"
7176 test -d $prefix/utf8/lib/utf8 && cf_search="$cf_search $prefix/utf8/lib/utf8"
7179 test "/usr/local" != "$prefix" && \
7180 test -d "/usr/local" && \
7181 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
7182 test -n "$verbose" && echo " ... testing for lib-directories under /usr/local"
7183 test -d /usr/local/lib && cf_search="$cf_search /usr/local/lib"
7184 test -d /usr/local/lib/utf8 && cf_search="$cf_search /usr/local/lib/utf8"
7185 test -d /usr/local/lib/utf8/lib && cf_search="$cf_search /usr/local/lib/utf8/lib"
7186 test -d /usr/local/utf8/lib && cf_search="$cf_search /usr/local/utf8/lib"
7187 test -d /usr/local/utf8/lib/utf8 && cf_search="$cf_search /usr/local/utf8/lib/utf8"
7190 test "/opt" != "$prefix" && \
7192 (test $prefix = NONE || test "/opt" != "$prefix") && {
7193 test -n "$verbose" && echo " ... testing for lib-directories under /opt"
7194 test -d /opt/lib && cf_search="$cf_search /opt/lib"
7195 test -d /opt/lib/utf8 && cf_search="$cf_search /opt/lib/utf8"
7196 test -d /opt/lib/utf8/lib && cf_search="$cf_search /opt/lib/utf8/lib"
7197 test -d /opt/utf8/lib && cf_search="$cf_search /opt/utf8/lib"
7198 test -d /opt/utf8/lib/utf8 && cf_search="$cf_search /opt/utf8/lib/utf8"
7201 test "$HOME" != "$prefix" && \
7202 test -d "$HOME" && \
7203 (test $prefix = NONE || test "$HOME" != "$prefix") && {
7204 test -n "$verbose" && echo " ... testing for lib-directories under $HOME"
7205 test -d $HOME/lib && cf_search="$cf_search $HOME/lib"
7206 test -d $HOME/lib/utf8 && cf_search="$cf_search $HOME/lib/utf8"
7207 test -d $HOME/lib/utf8/lib && cf_search="$cf_search $HOME/lib/utf8/lib"
7208 test -d $HOME/utf8/lib && cf_search="$cf_search $HOME/utf8/lib"
7209 test -d $HOME/utf8/lib/utf8 && cf_search="$cf_search $HOME/utf8/lib/utf8"
7212 cf_search="$cf_library_path_list $cf_search"
7214 for cf_cv_library_path_utf8 in $cf_search
7216 if test -d $cf_cv_library_path_utf8 ; then
7217 test -n "$verbose" && echo " ... testing $cf_cv_library_path_utf8" 1>&6
7219 echo "${as_me:-configure}:7219: testing ... testing $cf_cv_library_path_utf8 ..." 1>&5
7221 CPPFLAGS="$cf_test_CPPFLAGS"
7222 LIBS="-lutf8 $cf_save_LIBS"
7223 LDFLAGS="$cf_save_LDFLAGS -L$cf_cv_library_path_utf8"
7224 cat >conftest.$ac_ext <<_ACEOF
7225 #line 7225 "configure"
7226 #include "confdefs.h"
7228 #include <libutf8.h>
7237 rm -f conftest.$ac_objext conftest$ac_exeext
7238 if { (eval echo "$as_me:7238: \"$ac_link\"") >&5
7239 (eval $ac_link) 2>&5
7241 echo "$as_me:7241: \$? = $ac_status" >&5
7242 (exit $ac_status); } &&
7243 { ac_try='test -s conftest$ac_exeext'
7244 { (eval echo "$as_me:7244: \"$ac_try\"") >&5
7247 echo "$as_me:7247: \$? = $ac_status" >&5
7248 (exit $ac_status); }; }; then
7250 test -n "$verbose" && echo " ... found utf8 library in $cf_cv_library_path_utf8" 1>&6
7252 echo "${as_me:-configure}:7252: testing ... found utf8 library in $cf_cv_library_path_utf8 ..." 1>&5
7254 cf_cv_find_linkage_utf8=yes
7255 cf_cv_library_file_utf8="-lutf8"
7258 echo "$as_me: failed program was:" >&5
7259 cat conftest.$ac_ext >&5
7261 CPPFLAGS="$cf_save_CPPFLAGS"
7262 LIBS="$cf_save_LIBS"
7263 LDFLAGS="$cf_save_LDFLAGS"
7266 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7269 CPPFLAGS="$cf_save_CPPFLAGS"
7270 LDFLAGS="$cf_save_LDFLAGS"
7274 cf_cv_find_linkage_utf8=no
7278 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7281 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7283 LIBS="$cf_save_LIBS"
7285 if test "$cf_cv_find_linkage_utf8" = yes ; then
7286 cf_cv_utf8_lib=add-on
7292 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7294 echo "$as_me:7294: result: $cf_cv_utf8_lib" >&5
7295 echo "${ECHO_T}$cf_cv_utf8_lib" >&6
7297 # HAVE_LIBUTF8_H is used by ncurses if curses.h is shared between
7299 if test "$cf_cv_utf8_lib" = "add-on" ; then
7301 cat >>confdefs.h <<\EOF
7302 #define HAVE_LIBUTF8_H 1
7305 if test -n "$cf_cv_header_path_utf8" ; then
7306 for cf_add_incdir in $cf_cv_header_path_utf8
7308 while test $cf_add_incdir != /usr/include
7310 if test -d $cf_add_incdir
7313 if test -n "$CFLAGS$CPPFLAGS" ; then
7314 # a loop is needed to ensure we can add subdirs of existing dirs
7315 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
7316 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
7317 cf_have_incdir=yes; break
7322 if test "$cf_have_incdir" = no ; then
7323 if test "$cf_add_incdir" = /usr/local/include ; then
7324 if test "$GCC" = yes
7326 cf_save_CPPFLAGS=$CPPFLAGS
7327 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7328 cat >conftest.$ac_ext <<_ACEOF
7329 #line 7329 "configure"
7330 #include "confdefs.h"
7340 rm -f conftest.$ac_objext
7341 if { (eval echo "$as_me:7341: \"$ac_compile\"") >&5
7342 (eval $ac_compile) 2>&5
7344 echo "$as_me:7344: \$? = $ac_status" >&5
7345 (exit $ac_status); } &&
7346 { ac_try='test -s conftest.$ac_objext'
7347 { (eval echo "$as_me:7347: \"$ac_try\"") >&5
7350 echo "$as_me:7350: \$? = $ac_status" >&5
7351 (exit $ac_status); }; }; then
7354 echo "$as_me: failed program was:" >&5
7355 cat conftest.$ac_ext >&5
7358 rm -f conftest.$ac_objext conftest.$ac_ext
7359 CPPFLAGS=$cf_save_CPPFLAGS
7364 if test "$cf_have_incdir" = no ; then
7365 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
7367 echo "${as_me:-configure}:7367: testing adding $cf_add_incdir to include-path ..." 1>&5
7369 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7371 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
7372 test "$cf_top_incdir" = "$cf_add_incdir" && break
7373 cf_add_incdir="$cf_top_incdir"
7382 if test -n "$cf_cv_library_path_utf8" ; then
7383 for cf_add_libdir in $cf_cv_library_path_utf8
7385 if test $cf_add_libdir = /usr/lib ; then
7387 elif test -d $cf_add_libdir
7390 if test -n "$LDFLAGS$LIBS" ; then
7391 # a loop is needed to ensure we can add subdirs of existing dirs
7392 for cf_test_libdir in $LDFLAGS $LIBS ; do
7393 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
7394 cf_have_libdir=yes; break
7398 if test "$cf_have_libdir" = no ; then
7399 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
7401 echo "${as_me:-configure}:7401: testing adding $cf_add_libdir to library-path ..." 1>&5
7403 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
7409 LIBS="$cf_cv_library_file_utf8 $LIBS"
7412 cf_ncuconfig_root=ncursesw
7414 echo "Looking for ${cf_ncuconfig_root}-config"
7416 if test -n "$ac_tool_prefix"; then
7417 for ac_prog in ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
7419 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
7420 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
7421 echo "$as_me:7421: checking for $ac_word" >&5
7422 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7423 if test "${ac_cv_prog_NCURSES_CONFIG+set}" = set; then
7424 echo $ECHO_N "(cached) $ECHO_C" >&6
7426 if test -n "$NCURSES_CONFIG"; then
7427 ac_cv_prog_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test.
7429 ac_save_IFS=$IFS; IFS=$ac_path_separator
7431 for ac_dir in $ac_dummy; do
7433 test -z "$ac_dir" && ac_dir=.
7434 $as_executable_p "$ac_dir/$ac_word" || continue
7435 ac_cv_prog_NCURSES_CONFIG="$ac_tool_prefix$ac_prog"
7436 echo "$as_me:7436: found $ac_dir/$ac_word" >&5
7442 NCURSES_CONFIG=$ac_cv_prog_NCURSES_CONFIG
7443 if test -n "$NCURSES_CONFIG"; then
7444 echo "$as_me:7444: result: $NCURSES_CONFIG" >&5
7445 echo "${ECHO_T}$NCURSES_CONFIG" >&6
7447 echo "$as_me:7447: result: no" >&5
7448 echo "${ECHO_T}no" >&6
7451 test -n "$NCURSES_CONFIG" && break
7454 if test -z "$NCURSES_CONFIG"; then
7455 ac_ct_NCURSES_CONFIG=$NCURSES_CONFIG
7456 for ac_prog in ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
7458 # Extract the first word of "$ac_prog", so it can be a program name with args.
7459 set dummy $ac_prog; ac_word=$2
7460 echo "$as_me:7460: checking for $ac_word" >&5
7461 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7462 if test "${ac_cv_prog_ac_ct_NCURSES_CONFIG+set}" = set; then
7463 echo $ECHO_N "(cached) $ECHO_C" >&6
7465 if test -n "$ac_ct_NCURSES_CONFIG"; then
7466 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_ct_NCURSES_CONFIG" # Let the user override the test.
7468 ac_save_IFS=$IFS; IFS=$ac_path_separator
7470 for ac_dir in $ac_dummy; do
7472 test -z "$ac_dir" && ac_dir=.
7473 $as_executable_p "$ac_dir/$ac_word" || continue
7474 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_prog"
7475 echo "$as_me:7475: found $ac_dir/$ac_word" >&5
7481 ac_ct_NCURSES_CONFIG=$ac_cv_prog_ac_ct_NCURSES_CONFIG
7482 if test -n "$ac_ct_NCURSES_CONFIG"; then
7483 echo "$as_me:7483: result: $ac_ct_NCURSES_CONFIG" >&5
7484 echo "${ECHO_T}$ac_ct_NCURSES_CONFIG" >&6
7486 echo "$as_me:7486: result: no" >&5
7487 echo "${ECHO_T}no" >&6
7490 test -n "$ac_ct_NCURSES_CONFIG" && break
7492 test -n "$ac_ct_NCURSES_CONFIG" || ac_ct_NCURSES_CONFIG="none"
7494 NCURSES_CONFIG=$ac_ct_NCURSES_CONFIG
7497 if test "$NCURSES_CONFIG" != none ; then
7499 CPPFLAGS="$CPPFLAGS `$NCURSES_CONFIG --cflags`"
7500 LIBS="`$NCURSES_CONFIG --libs` $LIBS"
7502 # even with config script, some packages use no-override for curses.h
7504 echo "$as_me:7504: checking if we have identified curses headers" >&5
7505 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
7506 if test "${cf_cv_ncurses_header+set}" = set; then
7507 echo $ECHO_N "(cached) $ECHO_C" >&6
7510 cf_cv_ncurses_header=none
7512 ncursesw/ncurses.h \
7517 cat >conftest.$ac_ext <<_ACEOF
7518 #line 7518 "configure"
7519 #include "confdefs.h"
7520 #include <${cf_header}>
7524 initscr(); tgoto("?", 0,0)
7529 rm -f conftest.$ac_objext
7530 if { (eval echo "$as_me:7530: \"$ac_compile\"") >&5
7531 (eval $ac_compile) 2>&5
7533 echo "$as_me:7533: \$? = $ac_status" >&5
7534 (exit $ac_status); } &&
7535 { ac_try='test -s conftest.$ac_objext'
7536 { (eval echo "$as_me:7536: \"$ac_try\"") >&5
7539 echo "$as_me:7539: \$? = $ac_status" >&5
7540 (exit $ac_status); }; }; then
7541 cf_cv_ncurses_header=$cf_header; break
7543 echo "$as_me: failed program was:" >&5
7544 cat conftest.$ac_ext >&5
7546 rm -f conftest.$ac_objext conftest.$ac_ext
7550 echo "$as_me:7550: result: $cf_cv_ncurses_header" >&5
7551 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
7553 if test "$cf_cv_ncurses_header" = none ; then
7554 { { echo "$as_me:7554: error: No curses header-files found" >&5
7555 echo "$as_me: error: No curses header-files found" >&2;}
7556 { (exit 1); exit 1; }; }
7559 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
7561 for ac_header in $cf_cv_ncurses_header
7563 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7564 echo "$as_me:7564: checking for $ac_header" >&5
7565 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7566 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7567 echo $ECHO_N "(cached) $ECHO_C" >&6
7569 cat >conftest.$ac_ext <<_ACEOF
7570 #line 7570 "configure"
7571 #include "confdefs.h"
7572 #include <$ac_header>
7574 if { (eval echo "$as_me:7574: \"$ac_cpp conftest.$ac_ext\"") >&5
7575 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7577 egrep -v '^ *\+' conftest.er1 >conftest.err
7579 cat conftest.err >&5
7580 echo "$as_me:7580: \$? = $ac_status" >&5
7581 (exit $ac_status); } >/dev/null; then
7582 if test -s conftest.err; then
7583 ac_cpp_err=$ac_c_preproc_warn_flag
7590 if test -z "$ac_cpp_err"; then
7591 eval "$as_ac_Header=yes"
7593 echo "$as_me: failed program was:" >&5
7594 cat conftest.$ac_ext >&5
7595 eval "$as_ac_Header=no"
7597 rm -f conftest.err conftest.$ac_ext
7599 echo "$as_me:7599: result: `eval echo '${'$as_ac_Header'}'`" >&5
7600 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7601 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7602 cat >>confdefs.h <<EOF
7603 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7609 cat >>confdefs.h <<\EOF
7613 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
7615 cat >>confdefs.h <<EOF
7616 #define $cf_nculib_ROOT 1
7619 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
7623 cf_ncuhdr_root=ncursesw
7625 test -n "$cf_cv_curses_dir" && \
7626 test "$cf_cv_curses_dir" != "no" && { \
7628 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
7629 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
7631 while test $cf_add_incdir != /usr/include
7633 if test -d $cf_add_incdir
7636 if test -n "$CFLAGS$CPPFLAGS" ; then
7637 # a loop is needed to ensure we can add subdirs of existing dirs
7638 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
7639 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
7640 cf_have_incdir=yes; break
7645 if test "$cf_have_incdir" = no ; then
7646 if test "$cf_add_incdir" = /usr/local/include ; then
7647 if test "$GCC" = yes
7649 cf_save_CPPFLAGS=$CPPFLAGS
7650 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7651 cat >conftest.$ac_ext <<_ACEOF
7652 #line 7652 "configure"
7653 #include "confdefs.h"
7663 rm -f conftest.$ac_objext
7664 if { (eval echo "$as_me:7664: \"$ac_compile\"") >&5
7665 (eval $ac_compile) 2>&5
7667 echo "$as_me:7667: \$? = $ac_status" >&5
7668 (exit $ac_status); } &&
7669 { ac_try='test -s conftest.$ac_objext'
7670 { (eval echo "$as_me:7670: \"$ac_try\"") >&5
7673 echo "$as_me:7673: \$? = $ac_status" >&5
7674 (exit $ac_status); }; }; then
7677 echo "$as_me: failed program was:" >&5
7678 cat conftest.$ac_ext >&5
7681 rm -f conftest.$ac_objext conftest.$ac_ext
7682 CPPFLAGS=$cf_save_CPPFLAGS
7687 if test "$cf_have_incdir" = no ; then
7688 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
7690 echo "${as_me:-configure}:7690: testing adding $cf_add_incdir to include-path ..." 1>&5
7692 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7694 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
7695 test "$cf_top_incdir" = "$cf_add_incdir" && break
7696 cf_add_incdir="$cf_top_incdir"
7707 echo "$as_me:7707: checking for $cf_ncuhdr_root header in include-path" >&5
7708 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
7709 if test "${cf_cv_ncurses_h+set}" = set; then
7710 echo $ECHO_N "(cached) $ECHO_C" >&6
7713 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
7714 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
7715 for cf_header in $cf_header_list
7718 cat >conftest.$ac_ext <<_ACEOF
7719 #line 7719 "configure"
7720 #include "confdefs.h"
7722 #define _XOPEN_SOURCE_EXTENDED
7723 #undef HAVE_LIBUTF8_H /* in case we used CF_UTF8_LIB */
7724 #define HAVE_LIBUTF8_H /* to force ncurses' header file to use cchar_t */
7726 #include <$cf_header>
7731 #ifdef NCURSES_VERSION
7737 printf("%s\n", NCURSES_VERSION);
7750 rm -f conftest.$ac_objext
7751 if { (eval echo "$as_me:7751: \"$ac_compile\"") >&5
7752 (eval $ac_compile) 2>&5
7754 echo "$as_me:7754: \$? = $ac_status" >&5
7755 (exit $ac_status); } &&
7756 { ac_try='test -s conftest.$ac_objext'
7757 { (eval echo "$as_me:7757: \"$ac_try\"") >&5
7760 echo "$as_me:7760: \$? = $ac_status" >&5
7761 (exit $ac_status); }; }; then
7762 cf_cv_ncurses_h=$cf_header
7765 echo "$as_me: failed program was:" >&5
7766 cat conftest.$ac_ext >&5
7769 rm -f conftest.$ac_objext conftest.$ac_ext
7771 test "$cf_cv_ncurses_h" != no && break
7775 echo "$as_me:7775: result: $cf_cv_ncurses_h" >&5
7776 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
7778 if test "$cf_cv_ncurses_h" != no ; then
7779 cf_cv_ncurses_header=$cf_cv_ncurses_h
7782 echo "$as_me:7782: checking for $cf_ncuhdr_root include-path" >&5
7783 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
7784 if test "${cf_cv_ncurses_h2+set}" = set; then
7785 echo $ECHO_N "(cached) $ECHO_C" >&6
7788 test -n "$verbose" && echo
7792 # collect the current set of include-directories from compiler flags
7793 cf_header_path_list=""
7794 if test -n "${CFLAGS}${CPPFLAGS}" ; then
7795 for cf_header_path in $CPPFLAGS $CFLAGS
7797 case $cf_header_path in #(vi
7799 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
7801 test "$cf_header_path" != "NONE" && \
7802 test -d "$cf_header_path" && \
7804 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
7805 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
7806 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
7807 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
7808 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
7809 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"
7812 cf_header_path_list="$cf_header_path_list $cf_search"
7818 # add the variations for the package we are looking for
7822 test "/usr" != "$prefix" && \
7824 (test $prefix = NONE || test "/usr" != "$prefix") && {
7825 test -n "$verbose" && echo " ... testing for include-directories under /usr"
7826 test -d /usr/include && cf_search="$cf_search /usr/include"
7827 test -d /usr/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/include/$cf_ncuhdr_root"
7828 test -d /usr/include/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/include/$cf_ncuhdr_root/include"
7829 test -d /usr/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/$cf_ncuhdr_root/include"
7830 test -d /usr/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
7833 test "$prefix" != "NONE" && \
7834 test -d "$prefix" && \
7836 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
7837 test -d $prefix/include && cf_search="$cf_search $prefix/include"
7838 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
7839 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
7840 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
7841 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
7844 test "/usr/local" != "$prefix" && \
7845 test -d "/usr/local" && \
7846 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
7847 test -n "$verbose" && echo " ... testing for include-directories under /usr/local"
7848 test -d /usr/local/include && cf_search="$cf_search /usr/local/include"
7849 test -d /usr/local/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/local/include/$cf_ncuhdr_root"
7850 test -d /usr/local/include/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/local/include/$cf_ncuhdr_root/include"
7851 test -d /usr/local/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/local/$cf_ncuhdr_root/include"
7852 test -d /usr/local/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/local/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
7855 test "/opt" != "$prefix" && \
7857 (test $prefix = NONE || test "/opt" != "$prefix") && {
7858 test -n "$verbose" && echo " ... testing for include-directories under /opt"
7859 test -d /opt/include && cf_search="$cf_search /opt/include"
7860 test -d /opt/include/$cf_ncuhdr_root && cf_search="$cf_search /opt/include/$cf_ncuhdr_root"
7861 test -d /opt/include/$cf_ncuhdr_root/include && cf_search="$cf_search /opt/include/$cf_ncuhdr_root/include"
7862 test -d /opt/$cf_ncuhdr_root/include && cf_search="$cf_search /opt/$cf_ncuhdr_root/include"
7863 test -d /opt/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /opt/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
7866 test "$HOME" != "$prefix" && \
7867 test -d "$HOME" && \
7868 (test $prefix = NONE || test "$HOME" != "$prefix") && {
7869 test -n "$verbose" && echo " ... testing for include-directories under $HOME"
7870 test -d $HOME/include && cf_search="$cf_search $HOME/include"
7871 test -d $HOME/include/$cf_ncuhdr_root && cf_search="$cf_search $HOME/include/$cf_ncuhdr_root"
7872 test -d $HOME/include/$cf_ncuhdr_root/include && cf_search="$cf_search $HOME/include/$cf_ncuhdr_root/include"
7873 test -d $HOME/$cf_ncuhdr_root/include && cf_search="$cf_search $HOME/$cf_ncuhdr_root/include"
7874 test -d $HOME/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $HOME/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
7877 test "$includedir" != NONE && \
7878 test "$includedir" != "/usr/include" && \
7879 test -d "$includedir" && {
7880 test -d $includedir && cf_search="$cf_search $includedir"
7881 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
7884 test "$oldincludedir" != NONE && \
7885 test "$oldincludedir" != "/usr/include" && \
7886 test -d "$oldincludedir" && {
7887 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
7888 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
7891 cf_search="$cf_search $cf_header_path_list"
7893 test -n "$verbose" && echo search path $cf_search
7894 cf_save2_CPPFLAGS="$CPPFLAGS"
7895 for cf_incdir in $cf_search
7898 if test -n "$cf_incdir" ; then
7899 for cf_add_incdir in $cf_incdir
7901 while test $cf_add_incdir != /usr/include
7903 if test -d $cf_add_incdir
7906 if test -n "$CFLAGS$CPPFLAGS" ; then
7907 # a loop is needed to ensure we can add subdirs of existing dirs
7908 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
7909 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
7910 cf_have_incdir=yes; break
7915 if test "$cf_have_incdir" = no ; then
7916 if test "$cf_add_incdir" = /usr/local/include ; then
7917 if test "$GCC" = yes
7919 cf_save_CPPFLAGS=$CPPFLAGS
7920 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7921 cat >conftest.$ac_ext <<_ACEOF
7922 #line 7922 "configure"
7923 #include "confdefs.h"
7933 rm -f conftest.$ac_objext
7934 if { (eval echo "$as_me:7934: \"$ac_compile\"") >&5
7935 (eval $ac_compile) 2>&5
7937 echo "$as_me:7937: \$? = $ac_status" >&5
7938 (exit $ac_status); } &&
7939 { ac_try='test -s conftest.$ac_objext'
7940 { (eval echo "$as_me:7940: \"$ac_try\"") >&5
7943 echo "$as_me:7943: \$? = $ac_status" >&5
7944 (exit $ac_status); }; }; then
7947 echo "$as_me: failed program was:" >&5
7948 cat conftest.$ac_ext >&5
7951 rm -f conftest.$ac_objext conftest.$ac_ext
7952 CPPFLAGS=$cf_save_CPPFLAGS
7957 if test "$cf_have_incdir" = no ; then
7958 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
7960 echo "${as_me:-configure}:7960: testing adding $cf_add_incdir to include-path ..." 1>&5
7962 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7964 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
7965 test "$cf_top_incdir" = "$cf_add_incdir" && break
7966 cf_add_incdir="$cf_top_incdir"
7980 cat >conftest.$ac_ext <<_ACEOF
7981 #line 7981 "configure"
7982 #include "confdefs.h"
7984 #include <$cf_header>
7989 #ifdef NCURSES_VERSION
7991 printf("%s\n", NCURSES_VERSION);
8004 rm -f conftest.$ac_objext
8005 if { (eval echo "$as_me:8005: \"$ac_compile\"") >&5
8006 (eval $ac_compile) 2>&5
8008 echo "$as_me:8008: \$? = $ac_status" >&5
8009 (exit $ac_status); } &&
8010 { ac_try='test -s conftest.$ac_objext'
8011 { (eval echo "$as_me:8011: \"$ac_try\"") >&5
8014 echo "$as_me:8014: \$? = $ac_status" >&5
8015 (exit $ac_status); }; }; then
8016 cf_cv_ncurses_h2=$cf_header
8019 echo "$as_me: failed program was:" >&5
8020 cat conftest.$ac_ext >&5
8023 rm -f conftest.$ac_objext conftest.$ac_ext
8025 if test "$cf_cv_ncurses_h2" != no ; then
8026 cf_cv_ncurses_h2=$cf_incdir/$cf_header
8027 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
8030 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
8032 CPPFLAGS="$cf_save2_CPPFLAGS"
8033 test "$cf_cv_ncurses_h2" != no && break
8035 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:8035: error: not found" >&5
8036 echo "$as_me: error: not found" >&2;}
8037 { (exit 1); exit 1; }; }
8040 echo "$as_me:8040: result: $cf_cv_ncurses_h2" >&5
8041 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
8043 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
8044 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
8045 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
8046 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
8049 if test -n "$cf_1st_incdir" ; then
8050 for cf_add_incdir in $cf_1st_incdir
8052 while test $cf_add_incdir != /usr/include
8054 if test -d $cf_add_incdir
8057 if test -n "$CFLAGS$CPPFLAGS" ; then
8058 # a loop is needed to ensure we can add subdirs of existing dirs
8059 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
8060 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
8061 cf_have_incdir=yes; break
8066 if test "$cf_have_incdir" = no ; then
8067 if test "$cf_add_incdir" = /usr/local/include ; then
8068 if test "$GCC" = yes
8070 cf_save_CPPFLAGS=$CPPFLAGS
8071 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8072 cat >conftest.$ac_ext <<_ACEOF
8073 #line 8073 "configure"
8074 #include "confdefs.h"
8084 rm -f conftest.$ac_objext
8085 if { (eval echo "$as_me:8085: \"$ac_compile\"") >&5
8086 (eval $ac_compile) 2>&5
8088 echo "$as_me:8088: \$? = $ac_status" >&5
8089 (exit $ac_status); } &&
8090 { ac_try='test -s conftest.$ac_objext'
8091 { (eval echo "$as_me:8091: \"$ac_try\"") >&5
8094 echo "$as_me:8094: \$? = $ac_status" >&5
8095 (exit $ac_status); }; }; then
8098 echo "$as_me: failed program was:" >&5
8099 cat conftest.$ac_ext >&5
8102 rm -f conftest.$ac_objext conftest.$ac_ext
8103 CPPFLAGS=$cf_save_CPPFLAGS
8108 if test "$cf_have_incdir" = no ; then
8109 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
8111 echo "${as_me:-configure}:8111: testing adding $cf_add_incdir to include-path ..." 1>&5
8113 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8115 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
8116 test "$cf_top_incdir" = "$cf_add_incdir" && break
8117 cf_add_incdir="$cf_top_incdir"
8128 # Set definitions to allow ifdef'ing for ncurses.h
8130 case $cf_cv_ncurses_header in # (vi
8133 cat >>confdefs.h <<\EOF
8134 #define HAVE_NCURSES_H 1
8140 case $cf_cv_ncurses_header in # (vi
8141 ncurses/curses.h|ncurses/ncurses.h)
8143 cat >>confdefs.h <<\EOF
8144 #define HAVE_NCURSES_NCURSES_H 1
8148 ncursesw/curses.h|ncursesw/ncurses.h)
8150 cat >>confdefs.h <<\EOF
8151 #define HAVE_NCURSESW_NCURSES_H 1
8157 echo "$as_me:8157: checking for terminfo header" >&5
8158 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
8159 if test "${cf_cv_term_header+set}" = set; then
8160 echo $ECHO_N "(cached) $ECHO_C" >&6
8163 case ${cf_cv_ncurses_header} in #(vi
8164 */ncurses.h|*/ncursesw.h) #(vi
8165 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
8168 cf_term_header=term.h
8172 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
8174 cat >conftest.$ac_ext <<_ACEOF
8175 #line 8175 "configure"
8176 #include "confdefs.h"
8178 #include <${cf_cv_ncurses_header:-curses.h}>
8184 int x = auto_left_margin
8189 rm -f conftest.$ac_objext
8190 if { (eval echo "$as_me:8190: \"$ac_compile\"") >&5
8191 (eval $ac_compile) 2>&5
8193 echo "$as_me:8193: \$? = $ac_status" >&5
8194 (exit $ac_status); } &&
8195 { ac_try='test -s conftest.$ac_objext'
8196 { (eval echo "$as_me:8196: \"$ac_try\"") >&5
8199 echo "$as_me:8199: \$? = $ac_status" >&5
8200 (exit $ac_status); }; }; then
8202 cf_cv_term_header="$cf_test"
8204 echo "$as_me: failed program was:" >&5
8205 cat conftest.$ac_ext >&5
8207 cf_cv_term_header=unknown
8210 rm -f conftest.$ac_objext conftest.$ac_ext
8211 test "$cf_cv_term_header" != unknown && break
8215 echo "$as_me:8215: result: $cf_cv_term_header" >&5
8216 echo "${ECHO_T}$cf_cv_term_header" >&6
8218 # Set definitions to allow ifdef'ing to accommodate subdirectories
8220 case $cf_cv_term_header in # (vi
8223 cat >>confdefs.h <<\EOF
8224 #define HAVE_TERM_H 1
8230 case $cf_cv_term_header in # (vi
8231 ncurses/term.h) #(vi
8233 cat >>confdefs.h <<\EOF
8234 #define HAVE_NCURSES_TERM_H 1
8240 cat >>confdefs.h <<\EOF
8241 #define HAVE_NCURSESW_TERM_H 1
8247 # some applications need this, but should check for NCURSES_VERSION
8249 cat >>confdefs.h <<\EOF
8253 echo "$as_me:8253: checking for ncurses version" >&5
8254 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
8255 if test "${cf_cv_ncurses_version+set}" = set; then
8256 echo $ECHO_N "(cached) $ECHO_C" >&6
8259 cf_cv_ncurses_version=no
8262 if test "$cross_compiling" = yes; then
8264 # This will not work if the preprocessor splits the line after the
8265 # Autoconf token. The 'unproto' program does that.
8266 cat > conftest.$ac_ext <<EOF
8267 #include <${cf_cv_ncurses_header:-curses.h}>
8269 #ifdef NCURSES_VERSION
8270 Autoconf NCURSES_VERSION
8278 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
8279 { (eval echo "$as_me:8279: \"$cf_try\"") >&5
8282 echo "$as_me:8282: \$? = $ac_status" >&5
8283 (exit $ac_status); }
8284 if test -f conftest.out ; then
8285 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
8286 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
8291 cat >conftest.$ac_ext <<_ACEOF
8292 #line 8292 "configure"
8293 #include "confdefs.h"
8295 #include <${cf_cv_ncurses_header:-curses.h}>
8299 FILE *fp = fopen("$cf_tempfile", "w");
8300 #ifdef NCURSES_VERSION
8301 # ifdef NCURSES_VERSION_PATCH
8302 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
8304 fprintf(fp, "%s\n", NCURSES_VERSION);
8308 fprintf(fp, "old\n");
8313 ${cf_cv_main_return:-return}(0);
8316 rm -f conftest$ac_exeext
8317 if { (eval echo "$as_me:8317: \"$ac_link\"") >&5
8318 (eval $ac_link) 2>&5
8320 echo "$as_me:8320: \$? = $ac_status" >&5
8321 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
8322 { (eval echo "$as_me:8322: \"$ac_try\"") >&5
8325 echo "$as_me:8325: \$? = $ac_status" >&5
8326 (exit $ac_status); }; }; then
8328 cf_cv_ncurses_version=`cat $cf_tempfile`
8330 echo "$as_me: program exited with status $ac_status" >&5
8331 echo "$as_me: failed program was:" >&5
8332 cat conftest.$ac_ext >&5
8334 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
8339 echo "$as_me:8339: result: $cf_cv_ncurses_version" >&5
8340 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
8341 test "$cf_cv_ncurses_version" = no ||
8342 cat >>confdefs.h <<\EOF
8346 cf_nculib_root=ncursesw
8347 # This works, except for the special case where we find gpm, but
8348 # ncurses is in a nonstandard location via $LIBS, and we really want
8351 cf_ncurses_SAVE="$LIBS"
8352 echo "$as_me:8352: checking for Gpm_Open in -lgpm" >&5
8353 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
8354 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
8355 echo $ECHO_N "(cached) $ECHO_C" >&6
8357 ac_check_lib_save_LIBS=$LIBS
8359 cat >conftest.$ac_ext <<_ACEOF
8360 #line 8360 "configure"
8361 #include "confdefs.h"
8363 /* Override any gcc2 internal prototype to avoid an error. */
8367 /* We use char because int might match the return type of a gcc2
8368 builtin and then its argument prototype would still apply. */
8378 rm -f conftest.$ac_objext conftest$ac_exeext
8379 if { (eval echo "$as_me:8379: \"$ac_link\"") >&5
8380 (eval $ac_link) 2>&5
8382 echo "$as_me:8382: \$? = $ac_status" >&5
8383 (exit $ac_status); } &&
8384 { ac_try='test -s conftest$ac_exeext'
8385 { (eval echo "$as_me:8385: \"$ac_try\"") >&5
8388 echo "$as_me:8388: \$? = $ac_status" >&5
8389 (exit $ac_status); }; }; then
8390 ac_cv_lib_gpm_Gpm_Open=yes
8392 echo "$as_me: failed program was:" >&5
8393 cat conftest.$ac_ext >&5
8394 ac_cv_lib_gpm_Gpm_Open=no
8396 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8397 LIBS=$ac_check_lib_save_LIBS
8399 echo "$as_me:8399: result: $ac_cv_lib_gpm_Gpm_Open" >&5
8400 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
8401 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
8402 echo "$as_me:8402: checking for initscr in -lgpm" >&5
8403 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
8404 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
8405 echo $ECHO_N "(cached) $ECHO_C" >&6
8407 ac_check_lib_save_LIBS=$LIBS
8409 cat >conftest.$ac_ext <<_ACEOF
8410 #line 8410 "configure"
8411 #include "confdefs.h"
8413 /* Override any gcc2 internal prototype to avoid an error. */
8417 /* We use char because int might match the return type of a gcc2
8418 builtin and then its argument prototype would still apply. */
8428 rm -f conftest.$ac_objext conftest$ac_exeext
8429 if { (eval echo "$as_me:8429: \"$ac_link\"") >&5
8430 (eval $ac_link) 2>&5
8432 echo "$as_me:8432: \$? = $ac_status" >&5
8433 (exit $ac_status); } &&
8434 { ac_try='test -s conftest$ac_exeext'
8435 { (eval echo "$as_me:8435: \"$ac_try\"") >&5
8438 echo "$as_me:8438: \$? = $ac_status" >&5
8439 (exit $ac_status); }; }; then
8440 ac_cv_lib_gpm_initscr=yes
8442 echo "$as_me: failed program was:" >&5
8443 cat conftest.$ac_ext >&5
8444 ac_cv_lib_gpm_initscr=no
8446 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8447 LIBS=$ac_check_lib_save_LIBS
8449 echo "$as_me:8449: result: $ac_cv_lib_gpm_initscr" >&5
8450 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
8451 if test $ac_cv_lib_gpm_initscr = yes; then
8452 LIBS="$cf_ncurses_SAVE"
8454 cf_ncurses_LIBS="-lgpm"
8459 case $host_os in #(vi
8461 # This is only necessary if you are linking against an obsolete
8462 # version of ncurses (but it should do no harm, since it's static).
8463 if test "$cf_nculib_root" = ncurses ; then
8464 echo "$as_me:8464: checking for tgoto in -lmytinfo" >&5
8465 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
8466 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
8467 echo $ECHO_N "(cached) $ECHO_C" >&6
8469 ac_check_lib_save_LIBS=$LIBS
8470 LIBS="-lmytinfo $LIBS"
8471 cat >conftest.$ac_ext <<_ACEOF
8472 #line 8472 "configure"
8473 #include "confdefs.h"
8475 /* Override any gcc2 internal prototype to avoid an error. */
8479 /* We use char because int might match the return type of a gcc2
8480 builtin and then its argument prototype would still apply. */
8490 rm -f conftest.$ac_objext conftest$ac_exeext
8491 if { (eval echo "$as_me:8491: \"$ac_link\"") >&5
8492 (eval $ac_link) 2>&5
8494 echo "$as_me:8494: \$? = $ac_status" >&5
8495 (exit $ac_status); } &&
8496 { ac_try='test -s conftest$ac_exeext'
8497 { (eval echo "$as_me:8497: \"$ac_try\"") >&5
8500 echo "$as_me:8500: \$? = $ac_status" >&5
8501 (exit $ac_status); }; }; then
8502 ac_cv_lib_mytinfo_tgoto=yes
8504 echo "$as_me: failed program was:" >&5
8505 cat conftest.$ac_ext >&5
8506 ac_cv_lib_mytinfo_tgoto=no
8508 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8509 LIBS=$ac_check_lib_save_LIBS
8511 echo "$as_me:8511: result: $ac_cv_lib_mytinfo_tgoto" >&5
8512 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
8513 if test $ac_cv_lib_mytinfo_tgoto = yes; then
8514 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
8521 LIBS="$cf_ncurses_LIBS $LIBS"
8523 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
8525 LIBS="-l$cf_nculib_root $LIBS"
8528 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
8530 echo "$as_me:8530: checking for initscr" >&5
8531 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
8532 if test "${ac_cv_func_initscr+set}" = set; then
8533 echo $ECHO_N "(cached) $ECHO_C" >&6
8535 cat >conftest.$ac_ext <<_ACEOF
8536 #line 8536 "configure"
8537 #include "confdefs.h"
8538 /* System header to define __stub macros and hopefully few prototypes,
8539 which can conflict with char initscr (); below. */
8541 /* Override any gcc2 internal prototype to avoid an error. */
8545 /* We use char because int might match the return type of a gcc2
8546 builtin and then its argument prototype would still apply. */
8553 /* The GNU C library defines this for functions which it implements
8554 to always fail with ENOSYS. Some functions are actually named
8555 something starting with __ and the normal name is an alias. */
8556 #if defined (__stub_initscr) || defined (__stub___initscr)
8559 f = initscr; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
8566 rm -f conftest.$ac_objext conftest$ac_exeext
8567 if { (eval echo "$as_me:8567: \"$ac_link\"") >&5
8568 (eval $ac_link) 2>&5
8570 echo "$as_me:8570: \$? = $ac_status" >&5
8571 (exit $ac_status); } &&
8572 { ac_try='test -s conftest$ac_exeext'
8573 { (eval echo "$as_me:8573: \"$ac_try\"") >&5
8576 echo "$as_me:8576: \$? = $ac_status" >&5
8577 (exit $ac_status); }; }; then
8578 ac_cv_func_initscr=yes
8580 echo "$as_me: failed program was:" >&5
8581 cat conftest.$ac_ext >&5
8582 ac_cv_func_initscr=no
8584 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8586 echo "$as_me:8586: result: $ac_cv_func_initscr" >&5
8587 echo "${ECHO_T}$ac_cv_func_initscr" >&6
8588 if test $ac_cv_func_initscr = yes; then
8589 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
8592 cf_save_LIBS="$LIBS"
8593 echo "$as_me:8593: checking for initscr in -l$cf_nculib_root" >&5
8594 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
8595 LIBS="-l$cf_nculib_root $LIBS"
8596 cat >conftest.$ac_ext <<_ACEOF
8597 #line 8597 "configure"
8598 #include "confdefs.h"
8599 #include <${cf_cv_ncurses_header:-curses.h}>
8608 rm -f conftest.$ac_objext conftest$ac_exeext
8609 if { (eval echo "$as_me:8609: \"$ac_link\"") >&5
8610 (eval $ac_link) 2>&5
8612 echo "$as_me:8612: \$? = $ac_status" >&5
8613 (exit $ac_status); } &&
8614 { ac_try='test -s conftest$ac_exeext'
8615 { (eval echo "$as_me:8615: \"$ac_try\"") >&5
8618 echo "$as_me:8618: \$? = $ac_status" >&5
8619 (exit $ac_status); }; }; then
8620 echo "$as_me:8620: result: yes" >&5
8621 echo "${ECHO_T}yes" >&6
8622 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
8625 echo "$as_me: failed program was:" >&5
8626 cat conftest.$ac_ext >&5
8627 echo "$as_me:8627: result: no" >&5
8628 echo "${ECHO_T}no" >&6
8631 cf_library_path_list=""
8632 if test -n "${LDFLAGS}${LIBS}" ; then
8633 for cf_library_path in $LDFLAGS $LIBS
8635 case $cf_library_path in #(vi
8637 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
8639 test "$cf_library_path" != "NONE" && \
8640 test -d "$cf_library_path" && \
8642 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
8643 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
8644 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
8645 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
8646 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
8647 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"
8650 cf_library_path_list="$cf_library_path_list $cf_search"
8658 test "/usr" != "$prefix" && \
8660 (test $prefix = NONE || test "/usr" != "$prefix") && {
8661 test -n "$verbose" && echo " ... testing for lib-directories under /usr"
8662 test -d /usr/lib && cf_search="$cf_search /usr/lib"
8663 test -d /usr/lib/$cf_nculib_root && cf_search="$cf_search /usr/lib/$cf_nculib_root"
8664 test -d /usr/lib/$cf_nculib_root/lib && cf_search="$cf_search /usr/lib/$cf_nculib_root/lib"
8665 test -d /usr/$cf_nculib_root/lib && cf_search="$cf_search /usr/$cf_nculib_root/lib"
8666 test -d /usr/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /usr/$cf_nculib_root/lib/$cf_nculib_root"
8669 test "$prefix" != "NONE" && \
8670 test -d "$prefix" && \
8672 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
8673 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
8674 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
8675 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
8676 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
8677 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
8680 test "/usr/local" != "$prefix" && \
8681 test -d "/usr/local" && \
8682 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
8683 test -n "$verbose" && echo " ... testing for lib-directories under /usr/local"
8684 test -d /usr/local/lib && cf_search="$cf_search /usr/local/lib"
8685 test -d /usr/local/lib/$cf_nculib_root && cf_search="$cf_search /usr/local/lib/$cf_nculib_root"
8686 test -d /usr/local/lib/$cf_nculib_root/lib && cf_search="$cf_search /usr/local/lib/$cf_nculib_root/lib"
8687 test -d /usr/local/$cf_nculib_root/lib && cf_search="$cf_search /usr/local/$cf_nculib_root/lib"
8688 test -d /usr/local/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /usr/local/$cf_nculib_root/lib/$cf_nculib_root"
8691 test "/opt" != "$prefix" && \
8693 (test $prefix = NONE || test "/opt" != "$prefix") && {
8694 test -n "$verbose" && echo " ... testing for lib-directories under /opt"
8695 test -d /opt/lib && cf_search="$cf_search /opt/lib"
8696 test -d /opt/lib/$cf_nculib_root && cf_search="$cf_search /opt/lib/$cf_nculib_root"
8697 test -d /opt/lib/$cf_nculib_root/lib && cf_search="$cf_search /opt/lib/$cf_nculib_root/lib"
8698 test -d /opt/$cf_nculib_root/lib && cf_search="$cf_search /opt/$cf_nculib_root/lib"
8699 test -d /opt/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /opt/$cf_nculib_root/lib/$cf_nculib_root"
8702 test "$HOME" != "$prefix" && \
8703 test -d "$HOME" && \
8704 (test $prefix = NONE || test "$HOME" != "$prefix") && {
8705 test -n "$verbose" && echo " ... testing for lib-directories under $HOME"
8706 test -d $HOME/lib && cf_search="$cf_search $HOME/lib"
8707 test -d $HOME/lib/$cf_nculib_root && cf_search="$cf_search $HOME/lib/$cf_nculib_root"
8708 test -d $HOME/lib/$cf_nculib_root/lib && cf_search="$cf_search $HOME/lib/$cf_nculib_root/lib"
8709 test -d $HOME/$cf_nculib_root/lib && cf_search="$cf_search $HOME/$cf_nculib_root/lib"
8710 test -d $HOME/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $HOME/$cf_nculib_root/lib/$cf_nculib_root"
8713 cf_search="$cf_library_path_list $cf_search"
8715 for cf_libdir in $cf_search
8717 echo "$as_me:8717: checking for -l$cf_nculib_root in $cf_libdir" >&5
8718 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
8719 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
8720 cat >conftest.$ac_ext <<_ACEOF
8721 #line 8721 "configure"
8722 #include "confdefs.h"
8723 #include <${cf_cv_ncurses_header:-curses.h}>
8732 rm -f conftest.$ac_objext conftest$ac_exeext
8733 if { (eval echo "$as_me:8733: \"$ac_link\"") >&5
8734 (eval $ac_link) 2>&5
8736 echo "$as_me:8736: \$? = $ac_status" >&5
8737 (exit $ac_status); } &&
8738 { ac_try='test -s conftest$ac_exeext'
8739 { (eval echo "$as_me:8739: \"$ac_try\"") >&5
8742 echo "$as_me:8742: \$? = $ac_status" >&5
8743 (exit $ac_status); }; }; then
8744 echo "$as_me:8744: result: yes" >&5
8745 echo "${ECHO_T}yes" >&6
8746 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
8749 echo "$as_me: failed program was:" >&5
8750 cat conftest.$ac_ext >&5
8751 echo "$as_me:8751: result: no" >&5
8752 echo "${ECHO_T}no" >&6
8753 LIBS="$cf_save_LIBS"
8755 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8759 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8763 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
8765 if test $cf_found_library = no ; then
8766 { { echo "$as_me:8766: error: Cannot link $cf_nculib_root library" >&5
8767 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
8768 { (exit 1); exit 1; }; }
8773 if test -n "$cf_ncurses_LIBS" ; then
8774 echo "$as_me:8774: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
8775 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
8776 cf_ncurses_SAVE="$LIBS"
8777 for p in $cf_ncurses_LIBS ; do
8778 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
8779 if test "$q" != "$LIBS" ; then
8783 cat >conftest.$ac_ext <<_ACEOF
8784 #line 8784 "configure"
8785 #include "confdefs.h"
8786 #include <${cf_cv_ncurses_header:-curses.h}>
8790 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
8795 rm -f conftest.$ac_objext conftest$ac_exeext
8796 if { (eval echo "$as_me:8796: \"$ac_link\"") >&5
8797 (eval $ac_link) 2>&5
8799 echo "$as_me:8799: \$? = $ac_status" >&5
8800 (exit $ac_status); } &&
8801 { ac_try='test -s conftest$ac_exeext'
8802 { (eval echo "$as_me:8802: \"$ac_try\"") >&5
8805 echo "$as_me:8805: \$? = $ac_status" >&5
8806 (exit $ac_status); }; }; then
8807 echo "$as_me:8807: result: yes" >&5
8808 echo "${ECHO_T}yes" >&6
8810 echo "$as_me: failed program was:" >&5
8811 cat conftest.$ac_ext >&5
8812 echo "$as_me:8812: result: no" >&5
8813 echo "${ECHO_T}no" >&6
8814 LIBS="$cf_ncurses_SAVE"
8816 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8819 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
8821 cat >>confdefs.h <<EOF
8822 #define $cf_nculib_ROOT 1
8829 echo "$as_me:8829: checking for X" >&5
8830 echo $ECHO_N "checking for X... $ECHO_C" >&6
8832 # Check whether --with-x or --without-x was given.
8833 if test "${with_x+set}" = set; then
8837 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
8838 if test "x$with_x" = xno; then
8839 # The user explicitly disabled X.
8842 if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
8843 # Both variables are already set.
8846 if test "${ac_cv_have_x+set}" = set; then
8847 echo $ECHO_N "(cached) $ECHO_C" >&6
8849 # One or both of the vars are not set, and there is no cached value.
8850 ac_x_includes=no ac_x_libraries=no
8852 if mkdir conftest.dir; then
8854 # Make sure to not put "make" in the Imakefile rules, since we grep it out.
8855 cat >Imakefile <<'EOF'
8857 @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
8859 if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
8860 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
8861 eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
8862 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
8863 for ac_extension in a so sl dylib dll; do
8864 if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
8865 test -f $ac_im_libdir/libX11.$ac_extension; then
8866 ac_im_usrlibdir=$ac_im_libdir; break
8869 # Screen out bogus values from the imake configuration. They are
8870 # bogus both because they are the default anyway, and because
8871 # using them would break gcc on systems where it needs fixed includes.
8872 case $ac_im_incroot in
8874 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
8876 case $ac_im_usrlibdir in
8878 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
8885 # Standard set of common directories for X headers.
8886 # Check X11 before X11Rn because it is often a symlink to the current release.
8898 /usr/local/X11/include
8899 /usr/local/X11R6/include
8900 /usr/local/X11R5/include
8901 /usr/local/X11R4/include
8903 /usr/local/include/X11
8904 /usr/local/include/X11R6
8905 /usr/local/include/X11R5
8906 /usr/local/include/X11R4
8910 /usr/XFree86/include/X11
8914 /usr/unsupported/include
8916 /usr/local/x11r5/include
8917 /usr/lpp/Xamples/include
8919 /usr/openwin/include
8920 /usr/openwin/share/include'
8922 if test "$ac_x_includes" = no; then
8923 # Guess where to find include files, by looking for Intrinsic.h.
8924 # First, try using that file with no special directory specified.
8925 cat >conftest.$ac_ext <<_ACEOF
8926 #line 8926 "configure"
8927 #include "confdefs.h"
8928 #include <X11/Intrinsic.h>
8930 if { (eval echo "$as_me:8930: \"$ac_cpp conftest.$ac_ext\"") >&5
8931 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8933 egrep -v '^ *\+' conftest.er1 >conftest.err
8935 cat conftest.err >&5
8936 echo "$as_me:8936: \$? = $ac_status" >&5
8937 (exit $ac_status); } >/dev/null; then
8938 if test -s conftest.err; then
8939 ac_cpp_err=$ac_c_preproc_warn_flag
8946 if test -z "$ac_cpp_err"; then
8947 # We can compile using X headers with no special include directory.
8950 echo "$as_me: failed program was:" >&5
8951 cat conftest.$ac_ext >&5
8952 for ac_dir in $ac_x_header_dirs; do
8953 if test -r "$ac_dir/X11/Intrinsic.h"; then
8954 ac_x_includes=$ac_dir
8959 rm -f conftest.err conftest.$ac_ext
8960 fi # $ac_x_includes = no
8962 if test "$ac_x_libraries" = no; then
8963 # Check for the libraries.
8964 # See if we find them without any special options.
8965 # Don't add to $LIBS permanently.
8968 cat >conftest.$ac_ext <<_ACEOF
8969 #line 8969 "configure"
8970 #include "confdefs.h"
8971 #include <X11/Intrinsic.h>
8980 rm -f conftest.$ac_objext conftest$ac_exeext
8981 if { (eval echo "$as_me:8981: \"$ac_link\"") >&5
8982 (eval $ac_link) 2>&5
8984 echo "$as_me:8984: \$? = $ac_status" >&5
8985 (exit $ac_status); } &&
8986 { ac_try='test -s conftest$ac_exeext'
8987 { (eval echo "$as_me:8987: \"$ac_try\"") >&5
8990 echo "$as_me:8990: \$? = $ac_status" >&5
8991 (exit $ac_status); }; }; then
8993 # We can link X programs with no special library path.
8996 echo "$as_me: failed program was:" >&5
8997 cat conftest.$ac_ext >&5
8999 for ac_dir in `echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
9001 # Don't even attempt the hair of trying to link an X program!
9002 for ac_extension in a so sl dylib dll; do
9003 if test -r $ac_dir/libXt.$ac_extension; then
9004 ac_x_libraries=$ac_dir
9010 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9011 fi # $ac_x_libraries = no
9013 if test "$ac_x_includes" = no || test "$ac_x_libraries" = no; then
9014 # Didn't find X anywhere. Cache the known absence of X.
9015 ac_cv_have_x="have_x=no"
9017 # Record where we found X for the cache.
9018 ac_cv_have_x="have_x=yes \
9019 ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
9024 eval "$ac_cv_have_x"
9027 if test "$have_x" != yes; then
9028 echo "$as_me:9028: result: $have_x" >&5
9029 echo "${ECHO_T}$have_x" >&6
9032 # If each of the values was on the command line, it overrides each guess.
9033 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
9034 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
9035 # Update the cache value to reflect the command line values.
9036 ac_cv_have_x="have_x=yes \
9037 ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
9038 echo "$as_me:9038: result: libraries $x_libraries, headers $x_includes" >&5
9039 echo "${ECHO_T}libraries $x_libraries, headers $x_includes" >&6
9042 if test "$no_x" = yes; then
9043 # Not all programs may use this symbol, but it does not hurt to define it.
9045 cat >>confdefs.h <<\EOF
9046 #define X_DISPLAY_MISSING 1
9049 X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS=
9051 if test -n "$x_includes"; then
9052 X_CFLAGS="$X_CFLAGS -I$x_includes"
9055 # It would also be nice to do this for all -L options, not just this one.
9056 if test -n "$x_libraries"; then
9057 X_LIBS="$X_LIBS -L$x_libraries"
9058 # For Solaris; some versions of Sun CC require a space after -R and
9059 # others require no space. Words are not sufficient . . . .
9060 case `(uname -sr) 2>/dev/null` in
9062 echo "$as_me:9062: checking whether -R must be followed by a space" >&5
9063 echo $ECHO_N "checking whether -R must be followed by a space... $ECHO_C" >&6
9064 ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries"
9065 cat >conftest.$ac_ext <<_ACEOF
9066 #line 9066 "configure"
9067 #include "confdefs.h"
9077 rm -f conftest.$ac_objext conftest$ac_exeext
9078 if { (eval echo "$as_me:9078: \"$ac_link\"") >&5
9079 (eval $ac_link) 2>&5
9081 echo "$as_me:9081: \$? = $ac_status" >&5
9082 (exit $ac_status); } &&
9083 { ac_try='test -s conftest$ac_exeext'
9084 { (eval echo "$as_me:9084: \"$ac_try\"") >&5
9087 echo "$as_me:9087: \$? = $ac_status" >&5
9088 (exit $ac_status); }; }; then
9091 echo "$as_me: failed program was:" >&5
9092 cat conftest.$ac_ext >&5
9095 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9096 if test $ac_R_nospace = yes; then
9097 echo "$as_me:9097: result: no" >&5
9098 echo "${ECHO_T}no" >&6
9099 X_LIBS="$X_LIBS -R$x_libraries"
9101 LIBS="$ac_xsave_LIBS -R $x_libraries"
9102 cat >conftest.$ac_ext <<_ACEOF
9103 #line 9103 "configure"
9104 #include "confdefs.h"
9114 rm -f conftest.$ac_objext conftest$ac_exeext
9115 if { (eval echo "$as_me:9115: \"$ac_link\"") >&5
9116 (eval $ac_link) 2>&5
9118 echo "$as_me:9118: \$? = $ac_status" >&5
9119 (exit $ac_status); } &&
9120 { ac_try='test -s conftest$ac_exeext'
9121 { (eval echo "$as_me:9121: \"$ac_try\"") >&5
9124 echo "$as_me:9124: \$? = $ac_status" >&5
9125 (exit $ac_status); }; }; then
9128 echo "$as_me: failed program was:" >&5
9129 cat conftest.$ac_ext >&5
9132 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9133 if test $ac_R_space = yes; then
9134 echo "$as_me:9134: result: yes" >&5
9135 echo "${ECHO_T}yes" >&6
9136 X_LIBS="$X_LIBS -R $x_libraries"
9138 echo "$as_me:9138: result: neither works" >&5
9139 echo "${ECHO_T}neither works" >&6
9146 # Check for system-dependent libraries X programs must link with.
9147 # Do this before checking for the system-independent R6 libraries
9148 # (-lICE), since we may need -lsocket or whatever for X linking.
9150 if test "$ISC" = yes; then
9151 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
9153 # Martyn Johnson says this is needed for Ultrix, if the X
9154 # libraries were built with DECnet support. And Karl Berry says
9155 # the Alpha needs dnet_stub (dnet does not exist).
9156 ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11"
9157 cat >conftest.$ac_ext <<_ACEOF
9158 #line 9158 "configure"
9159 #include "confdefs.h"
9161 /* Override any gcc2 internal prototype to avoid an error. */
9165 /* We use char because int might match the return type of a gcc2
9166 builtin and then its argument prototype would still apply. */
9167 char XOpenDisplay ();
9176 rm -f conftest.$ac_objext conftest$ac_exeext
9177 if { (eval echo "$as_me:9177: \"$ac_link\"") >&5
9178 (eval $ac_link) 2>&5
9180 echo "$as_me:9180: \$? = $ac_status" >&5
9181 (exit $ac_status); } &&
9182 { ac_try='test -s conftest$ac_exeext'
9183 { (eval echo "$as_me:9183: \"$ac_try\"") >&5
9186 echo "$as_me:9186: \$? = $ac_status" >&5
9187 (exit $ac_status); }; }; then
9190 echo "$as_me: failed program was:" >&5
9191 cat conftest.$ac_ext >&5
9192 echo "$as_me:9192: checking for dnet_ntoa in -ldnet" >&5
9193 echo $ECHO_N "checking for dnet_ntoa in -ldnet... $ECHO_C" >&6
9194 if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then
9195 echo $ECHO_N "(cached) $ECHO_C" >&6
9197 ac_check_lib_save_LIBS=$LIBS
9199 cat >conftest.$ac_ext <<_ACEOF
9200 #line 9200 "configure"
9201 #include "confdefs.h"
9203 /* Override any gcc2 internal prototype to avoid an error. */
9207 /* We use char because int might match the return type of a gcc2
9208 builtin and then its argument prototype would still apply. */
9218 rm -f conftest.$ac_objext conftest$ac_exeext
9219 if { (eval echo "$as_me:9219: \"$ac_link\"") >&5
9220 (eval $ac_link) 2>&5
9222 echo "$as_me:9222: \$? = $ac_status" >&5
9223 (exit $ac_status); } &&
9224 { ac_try='test -s conftest$ac_exeext'
9225 { (eval echo "$as_me:9225: \"$ac_try\"") >&5
9228 echo "$as_me:9228: \$? = $ac_status" >&5
9229 (exit $ac_status); }; }; then
9230 ac_cv_lib_dnet_dnet_ntoa=yes
9232 echo "$as_me: failed program was:" >&5
9233 cat conftest.$ac_ext >&5
9234 ac_cv_lib_dnet_dnet_ntoa=no
9236 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9237 LIBS=$ac_check_lib_save_LIBS
9239 echo "$as_me:9239: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
9240 echo "${ECHO_T}$ac_cv_lib_dnet_dnet_ntoa" >&6
9241 if test $ac_cv_lib_dnet_dnet_ntoa = yes; then
9242 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
9245 if test $ac_cv_lib_dnet_dnet_ntoa = no; then
9246 echo "$as_me:9246: checking for dnet_ntoa in -ldnet_stub" >&5
9247 echo $ECHO_N "checking for dnet_ntoa in -ldnet_stub... $ECHO_C" >&6
9248 if test "${ac_cv_lib_dnet_stub_dnet_ntoa+set}" = set; then
9249 echo $ECHO_N "(cached) $ECHO_C" >&6
9251 ac_check_lib_save_LIBS=$LIBS
9252 LIBS="-ldnet_stub $LIBS"
9253 cat >conftest.$ac_ext <<_ACEOF
9254 #line 9254 "configure"
9255 #include "confdefs.h"
9257 /* Override any gcc2 internal prototype to avoid an error. */
9261 /* We use char because int might match the return type of a gcc2
9262 builtin and then its argument prototype would still apply. */
9272 rm -f conftest.$ac_objext conftest$ac_exeext
9273 if { (eval echo "$as_me:9273: \"$ac_link\"") >&5
9274 (eval $ac_link) 2>&5
9276 echo "$as_me:9276: \$? = $ac_status" >&5
9277 (exit $ac_status); } &&
9278 { ac_try='test -s conftest$ac_exeext'
9279 { (eval echo "$as_me:9279: \"$ac_try\"") >&5
9282 echo "$as_me:9282: \$? = $ac_status" >&5
9283 (exit $ac_status); }; }; then
9284 ac_cv_lib_dnet_stub_dnet_ntoa=yes
9286 echo "$as_me: failed program was:" >&5
9287 cat conftest.$ac_ext >&5
9288 ac_cv_lib_dnet_stub_dnet_ntoa=no
9290 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9291 LIBS=$ac_check_lib_save_LIBS
9293 echo "$as_me:9293: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5
9294 echo "${ECHO_T}$ac_cv_lib_dnet_stub_dnet_ntoa" >&6
9295 if test $ac_cv_lib_dnet_stub_dnet_ntoa = yes; then
9296 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
9301 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9302 LIBS="$ac_xsave_LIBS"
9304 # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT,
9305 # to get the SysV transport functions.
9306 # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4)
9308 # The nsl library prevents programs from opening the X display
9309 # on Irix 5.2, according to T.E. Dickey.
9310 # The functions gethostbyname, getservbyname, and inet_addr are
9311 # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking.
9312 echo "$as_me:9312: checking for gethostbyname" >&5
9313 echo $ECHO_N "checking for gethostbyname... $ECHO_C" >&6
9314 if test "${ac_cv_func_gethostbyname+set}" = set; then
9315 echo $ECHO_N "(cached) $ECHO_C" >&6
9317 cat >conftest.$ac_ext <<_ACEOF
9318 #line 9318 "configure"
9319 #include "confdefs.h"
9320 /* System header to define __stub macros and hopefully few prototypes,
9321 which can conflict with char gethostbyname (); below. */
9323 /* Override any gcc2 internal prototype to avoid an error. */
9327 /* We use char because int might match the return type of a gcc2
9328 builtin and then its argument prototype would still apply. */
9329 char gethostbyname ();
9335 /* The GNU C library defines this for functions which it implements
9336 to always fail with ENOSYS. Some functions are actually named
9337 something starting with __ and the normal name is an alias. */
9338 #if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
9341 f = gethostbyname; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
9348 rm -f conftest.$ac_objext conftest$ac_exeext
9349 if { (eval echo "$as_me:9349: \"$ac_link\"") >&5
9350 (eval $ac_link) 2>&5
9352 echo "$as_me:9352: \$? = $ac_status" >&5
9353 (exit $ac_status); } &&
9354 { ac_try='test -s conftest$ac_exeext'
9355 { (eval echo "$as_me:9355: \"$ac_try\"") >&5
9358 echo "$as_me:9358: \$? = $ac_status" >&5
9359 (exit $ac_status); }; }; then
9360 ac_cv_func_gethostbyname=yes
9362 echo "$as_me: failed program was:" >&5
9363 cat conftest.$ac_ext >&5
9364 ac_cv_func_gethostbyname=no
9366 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9368 echo "$as_me:9368: result: $ac_cv_func_gethostbyname" >&5
9369 echo "${ECHO_T}$ac_cv_func_gethostbyname" >&6
9371 if test $ac_cv_func_gethostbyname = no; then
9372 echo "$as_me:9372: checking for gethostbyname in -lnsl" >&5
9373 echo $ECHO_N "checking for gethostbyname in -lnsl... $ECHO_C" >&6
9374 if test "${ac_cv_lib_nsl_gethostbyname+set}" = set; then
9375 echo $ECHO_N "(cached) $ECHO_C" >&6
9377 ac_check_lib_save_LIBS=$LIBS
9379 cat >conftest.$ac_ext <<_ACEOF
9380 #line 9380 "configure"
9381 #include "confdefs.h"
9383 /* Override any gcc2 internal prototype to avoid an error. */
9387 /* We use char because int might match the return type of a gcc2
9388 builtin and then its argument prototype would still apply. */
9389 char gethostbyname ();
9398 rm -f conftest.$ac_objext conftest$ac_exeext
9399 if { (eval echo "$as_me:9399: \"$ac_link\"") >&5
9400 (eval $ac_link) 2>&5
9402 echo "$as_me:9402: \$? = $ac_status" >&5
9403 (exit $ac_status); } &&
9404 { ac_try='test -s conftest$ac_exeext'
9405 { (eval echo "$as_me:9405: \"$ac_try\"") >&5
9408 echo "$as_me:9408: \$? = $ac_status" >&5
9409 (exit $ac_status); }; }; then
9410 ac_cv_lib_nsl_gethostbyname=yes
9412 echo "$as_me: failed program was:" >&5
9413 cat conftest.$ac_ext >&5
9414 ac_cv_lib_nsl_gethostbyname=no
9416 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9417 LIBS=$ac_check_lib_save_LIBS
9419 echo "$as_me:9419: result: $ac_cv_lib_nsl_gethostbyname" >&5
9420 echo "${ECHO_T}$ac_cv_lib_nsl_gethostbyname" >&6
9421 if test $ac_cv_lib_nsl_gethostbyname = yes; then
9422 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
9425 if test $ac_cv_lib_nsl_gethostbyname = no; then
9426 echo "$as_me:9426: checking for gethostbyname in -lbsd" >&5
9427 echo $ECHO_N "checking for gethostbyname in -lbsd... $ECHO_C" >&6
9428 if test "${ac_cv_lib_bsd_gethostbyname+set}" = set; then
9429 echo $ECHO_N "(cached) $ECHO_C" >&6
9431 ac_check_lib_save_LIBS=$LIBS
9433 cat >conftest.$ac_ext <<_ACEOF
9434 #line 9434 "configure"
9435 #include "confdefs.h"
9437 /* Override any gcc2 internal prototype to avoid an error. */
9441 /* We use char because int might match the return type of a gcc2
9442 builtin and then its argument prototype would still apply. */
9443 char gethostbyname ();
9452 rm -f conftest.$ac_objext conftest$ac_exeext
9453 if { (eval echo "$as_me:9453: \"$ac_link\"") >&5
9454 (eval $ac_link) 2>&5
9456 echo "$as_me:9456: \$? = $ac_status" >&5
9457 (exit $ac_status); } &&
9458 { ac_try='test -s conftest$ac_exeext'
9459 { (eval echo "$as_me:9459: \"$ac_try\"") >&5
9462 echo "$as_me:9462: \$? = $ac_status" >&5
9463 (exit $ac_status); }; }; then
9464 ac_cv_lib_bsd_gethostbyname=yes
9466 echo "$as_me: failed program was:" >&5
9467 cat conftest.$ac_ext >&5
9468 ac_cv_lib_bsd_gethostbyname=no
9470 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9471 LIBS=$ac_check_lib_save_LIBS
9473 echo "$as_me:9473: result: $ac_cv_lib_bsd_gethostbyname" >&5
9474 echo "${ECHO_T}$ac_cv_lib_bsd_gethostbyname" >&6
9475 if test $ac_cv_lib_bsd_gethostbyname = yes; then
9476 X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd"
9482 # lieder@skyler.mavd.honeywell.com says without -lsocket,
9483 # socket/setsockopt and other routines are undefined under SCO ODT
9484 # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary
9485 # on later versions), says Simon Leinen: it contains gethostby*
9486 # variants that don't use the nameserver (or something). -lsocket
9487 # must be given before -lnsl if both are needed. We assume that
9488 # if connect needs -lnsl, so does gethostbyname.
9489 echo "$as_me:9489: checking for connect" >&5
9490 echo $ECHO_N "checking for connect... $ECHO_C" >&6
9491 if test "${ac_cv_func_connect+set}" = set; then
9492 echo $ECHO_N "(cached) $ECHO_C" >&6
9494 cat >conftest.$ac_ext <<_ACEOF
9495 #line 9495 "configure"
9496 #include "confdefs.h"
9497 /* System header to define __stub macros and hopefully few prototypes,
9498 which can conflict with char connect (); below. */
9500 /* Override any gcc2 internal prototype to avoid an error. */
9504 /* We use char because int might match the return type of a gcc2
9505 builtin and then its argument prototype would still apply. */
9512 /* The GNU C library defines this for functions which it implements
9513 to always fail with ENOSYS. Some functions are actually named
9514 something starting with __ and the normal name is an alias. */
9515 #if defined (__stub_connect) || defined (__stub___connect)
9518 f = connect; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
9525 rm -f conftest.$ac_objext conftest$ac_exeext
9526 if { (eval echo "$as_me:9526: \"$ac_link\"") >&5
9527 (eval $ac_link) 2>&5
9529 echo "$as_me:9529: \$? = $ac_status" >&5
9530 (exit $ac_status); } &&
9531 { ac_try='test -s conftest$ac_exeext'
9532 { (eval echo "$as_me:9532: \"$ac_try\"") >&5
9535 echo "$as_me:9535: \$? = $ac_status" >&5
9536 (exit $ac_status); }; }; then
9537 ac_cv_func_connect=yes
9539 echo "$as_me: failed program was:" >&5
9540 cat conftest.$ac_ext >&5
9541 ac_cv_func_connect=no
9543 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9545 echo "$as_me:9545: result: $ac_cv_func_connect" >&5
9546 echo "${ECHO_T}$ac_cv_func_connect" >&6
9548 if test $ac_cv_func_connect = no; then
9549 echo "$as_me:9549: checking for connect in -lsocket" >&5
9550 echo $ECHO_N "checking for connect in -lsocket... $ECHO_C" >&6
9551 if test "${ac_cv_lib_socket_connect+set}" = set; then
9552 echo $ECHO_N "(cached) $ECHO_C" >&6
9554 ac_check_lib_save_LIBS=$LIBS
9555 LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
9556 cat >conftest.$ac_ext <<_ACEOF
9557 #line 9557 "configure"
9558 #include "confdefs.h"
9560 /* Override any gcc2 internal prototype to avoid an error. */
9564 /* We use char because int might match the return type of a gcc2
9565 builtin and then its argument prototype would still apply. */
9575 rm -f conftest.$ac_objext conftest$ac_exeext
9576 if { (eval echo "$as_me:9576: \"$ac_link\"") >&5
9577 (eval $ac_link) 2>&5
9579 echo "$as_me:9579: \$? = $ac_status" >&5
9580 (exit $ac_status); } &&
9581 { ac_try='test -s conftest$ac_exeext'
9582 { (eval echo "$as_me:9582: \"$ac_try\"") >&5
9585 echo "$as_me:9585: \$? = $ac_status" >&5
9586 (exit $ac_status); }; }; then
9587 ac_cv_lib_socket_connect=yes
9589 echo "$as_me: failed program was:" >&5
9590 cat conftest.$ac_ext >&5
9591 ac_cv_lib_socket_connect=no
9593 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9594 LIBS=$ac_check_lib_save_LIBS
9596 echo "$as_me:9596: result: $ac_cv_lib_socket_connect" >&5
9597 echo "${ECHO_T}$ac_cv_lib_socket_connect" >&6
9598 if test $ac_cv_lib_socket_connect = yes; then
9599 X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS"
9604 # Guillermo Gomez says -lposix is necessary on A/UX.
9605 echo "$as_me:9605: checking for remove" >&5
9606 echo $ECHO_N "checking for remove... $ECHO_C" >&6
9607 if test "${ac_cv_func_remove+set}" = set; then
9608 echo $ECHO_N "(cached) $ECHO_C" >&6
9610 cat >conftest.$ac_ext <<_ACEOF
9611 #line 9611 "configure"
9612 #include "confdefs.h"
9613 /* System header to define __stub macros and hopefully few prototypes,
9614 which can conflict with char remove (); below. */
9616 /* Override any gcc2 internal prototype to avoid an error. */
9620 /* We use char because int might match the return type of a gcc2
9621 builtin and then its argument prototype would still apply. */
9628 /* The GNU C library defines this for functions which it implements
9629 to always fail with ENOSYS. Some functions are actually named
9630 something starting with __ and the normal name is an alias. */
9631 #if defined (__stub_remove) || defined (__stub___remove)
9634 f = remove; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
9641 rm -f conftest.$ac_objext conftest$ac_exeext
9642 if { (eval echo "$as_me:9642: \"$ac_link\"") >&5
9643 (eval $ac_link) 2>&5
9645 echo "$as_me:9645: \$? = $ac_status" >&5
9646 (exit $ac_status); } &&
9647 { ac_try='test -s conftest$ac_exeext'
9648 { (eval echo "$as_me:9648: \"$ac_try\"") >&5
9651 echo "$as_me:9651: \$? = $ac_status" >&5
9652 (exit $ac_status); }; }; then
9653 ac_cv_func_remove=yes
9655 echo "$as_me: failed program was:" >&5
9656 cat conftest.$ac_ext >&5
9657 ac_cv_func_remove=no
9659 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9661 echo "$as_me:9661: result: $ac_cv_func_remove" >&5
9662 echo "${ECHO_T}$ac_cv_func_remove" >&6
9664 if test $ac_cv_func_remove = no; then
9665 echo "$as_me:9665: checking for remove in -lposix" >&5
9666 echo $ECHO_N "checking for remove in -lposix... $ECHO_C" >&6
9667 if test "${ac_cv_lib_posix_remove+set}" = set; then
9668 echo $ECHO_N "(cached) $ECHO_C" >&6
9670 ac_check_lib_save_LIBS=$LIBS
9671 LIBS="-lposix $LIBS"
9672 cat >conftest.$ac_ext <<_ACEOF
9673 #line 9673 "configure"
9674 #include "confdefs.h"
9676 /* Override any gcc2 internal prototype to avoid an error. */
9680 /* We use char because int might match the return type of a gcc2
9681 builtin and then its argument prototype would still apply. */
9691 rm -f conftest.$ac_objext conftest$ac_exeext
9692 if { (eval echo "$as_me:9692: \"$ac_link\"") >&5
9693 (eval $ac_link) 2>&5
9695 echo "$as_me:9695: \$? = $ac_status" >&5
9696 (exit $ac_status); } &&
9697 { ac_try='test -s conftest$ac_exeext'
9698 { (eval echo "$as_me:9698: \"$ac_try\"") >&5
9701 echo "$as_me:9701: \$? = $ac_status" >&5
9702 (exit $ac_status); }; }; then
9703 ac_cv_lib_posix_remove=yes
9705 echo "$as_me: failed program was:" >&5
9706 cat conftest.$ac_ext >&5
9707 ac_cv_lib_posix_remove=no
9709 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9710 LIBS=$ac_check_lib_save_LIBS
9712 echo "$as_me:9712: result: $ac_cv_lib_posix_remove" >&5
9713 echo "${ECHO_T}$ac_cv_lib_posix_remove" >&6
9714 if test $ac_cv_lib_posix_remove = yes; then
9715 X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix"
9720 # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
9721 echo "$as_me:9721: checking for shmat" >&5
9722 echo $ECHO_N "checking for shmat... $ECHO_C" >&6
9723 if test "${ac_cv_func_shmat+set}" = set; then
9724 echo $ECHO_N "(cached) $ECHO_C" >&6
9726 cat >conftest.$ac_ext <<_ACEOF
9727 #line 9727 "configure"
9728 #include "confdefs.h"
9729 /* System header to define __stub macros and hopefully few prototypes,
9730 which can conflict with char shmat (); below. */
9732 /* Override any gcc2 internal prototype to avoid an error. */
9736 /* We use char because int might match the return type of a gcc2
9737 builtin and then its argument prototype would still apply. */
9744 /* The GNU C library defines this for functions which it implements
9745 to always fail with ENOSYS. Some functions are actually named
9746 something starting with __ and the normal name is an alias. */
9747 #if defined (__stub_shmat) || defined (__stub___shmat)
9750 f = shmat; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
9757 rm -f conftest.$ac_objext conftest$ac_exeext
9758 if { (eval echo "$as_me:9758: \"$ac_link\"") >&5
9759 (eval $ac_link) 2>&5
9761 echo "$as_me:9761: \$? = $ac_status" >&5
9762 (exit $ac_status); } &&
9763 { ac_try='test -s conftest$ac_exeext'
9764 { (eval echo "$as_me:9764: \"$ac_try\"") >&5
9767 echo "$as_me:9767: \$? = $ac_status" >&5
9768 (exit $ac_status); }; }; then
9769 ac_cv_func_shmat=yes
9771 echo "$as_me: failed program was:" >&5
9772 cat conftest.$ac_ext >&5
9775 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9777 echo "$as_me:9777: result: $ac_cv_func_shmat" >&5
9778 echo "${ECHO_T}$ac_cv_func_shmat" >&6
9780 if test $ac_cv_func_shmat = no; then
9781 echo "$as_me:9781: checking for shmat in -lipc" >&5
9782 echo $ECHO_N "checking for shmat in -lipc... $ECHO_C" >&6
9783 if test "${ac_cv_lib_ipc_shmat+set}" = set; then
9784 echo $ECHO_N "(cached) $ECHO_C" >&6
9786 ac_check_lib_save_LIBS=$LIBS
9788 cat >conftest.$ac_ext <<_ACEOF
9789 #line 9789 "configure"
9790 #include "confdefs.h"
9792 /* Override any gcc2 internal prototype to avoid an error. */
9796 /* We use char because int might match the return type of a gcc2
9797 builtin and then its argument prototype would still apply. */
9807 rm -f conftest.$ac_objext conftest$ac_exeext
9808 if { (eval echo "$as_me:9808: \"$ac_link\"") >&5
9809 (eval $ac_link) 2>&5
9811 echo "$as_me:9811: \$? = $ac_status" >&5
9812 (exit $ac_status); } &&
9813 { ac_try='test -s conftest$ac_exeext'
9814 { (eval echo "$as_me:9814: \"$ac_try\"") >&5
9817 echo "$as_me:9817: \$? = $ac_status" >&5
9818 (exit $ac_status); }; }; then
9819 ac_cv_lib_ipc_shmat=yes
9821 echo "$as_me: failed program was:" >&5
9822 cat conftest.$ac_ext >&5
9823 ac_cv_lib_ipc_shmat=no
9825 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9826 LIBS=$ac_check_lib_save_LIBS
9828 echo "$as_me:9828: result: $ac_cv_lib_ipc_shmat" >&5
9829 echo "${ECHO_T}$ac_cv_lib_ipc_shmat" >&6
9830 if test $ac_cv_lib_ipc_shmat = yes; then
9831 X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc"
9837 # Check for libraries that X11R6 Xt/Xaw programs need.
9838 ac_save_LDFLAGS=$LDFLAGS
9839 test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries"
9840 # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
9841 # check for ICE first), but we must link in the order -lSM -lICE or
9842 # we get undefined symbols. So assume we have SM if we have ICE.
9843 # These have to be linked with before -lX11, unlike the other
9844 # libraries we check for below, so use a different variable.
9845 # John Interrante, Karl Berry
9846 echo "$as_me:9846: checking for IceConnectionNumber in -lICE" >&5
9847 echo $ECHO_N "checking for IceConnectionNumber in -lICE... $ECHO_C" >&6
9848 if test "${ac_cv_lib_ICE_IceConnectionNumber+set}" = set; then
9849 echo $ECHO_N "(cached) $ECHO_C" >&6
9851 ac_check_lib_save_LIBS=$LIBS
9852 LIBS="-lICE $X_EXTRA_LIBS $LIBS"
9853 cat >conftest.$ac_ext <<_ACEOF
9854 #line 9854 "configure"
9855 #include "confdefs.h"
9857 /* Override any gcc2 internal prototype to avoid an error. */
9861 /* We use char because int might match the return type of a gcc2
9862 builtin and then its argument prototype would still apply. */
9863 char IceConnectionNumber ();
9867 IceConnectionNumber ();
9872 rm -f conftest.$ac_objext conftest$ac_exeext
9873 if { (eval echo "$as_me:9873: \"$ac_link\"") >&5
9874 (eval $ac_link) 2>&5
9876 echo "$as_me:9876: \$? = $ac_status" >&5
9877 (exit $ac_status); } &&
9878 { ac_try='test -s conftest$ac_exeext'
9879 { (eval echo "$as_me:9879: \"$ac_try\"") >&5
9882 echo "$as_me:9882: \$? = $ac_status" >&5
9883 (exit $ac_status); }; }; then
9884 ac_cv_lib_ICE_IceConnectionNumber=yes
9886 echo "$as_me: failed program was:" >&5
9887 cat conftest.$ac_ext >&5
9888 ac_cv_lib_ICE_IceConnectionNumber=no
9890 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9891 LIBS=$ac_check_lib_save_LIBS
9893 echo "$as_me:9893: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5
9894 echo "${ECHO_T}$ac_cv_lib_ICE_IceConnectionNumber" >&6
9895 if test $ac_cv_lib_ICE_IceConnectionNumber = yes; then
9896 X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
9899 LDFLAGS=$ac_save_LDFLAGS
9903 cf_x_athena=${cf_x_athena:-Xaw}
9905 echo "$as_me:9905: checking if you want to link with Xaw 3d library" >&5
9906 echo $ECHO_N "checking if you want to link with Xaw 3d library... $ECHO_C" >&6
9909 # Check whether --with-Xaw3d or --without-Xaw3d was given.
9910 if test "${with_Xaw3d+set}" = set; then
9911 withval="$with_Xaw3d"
9914 if test "$withval" = yes ; then
9916 echo "$as_me:9916: result: yes" >&5
9917 echo "${ECHO_T}yes" >&6
9919 echo "$as_me:9919: result: no" >&5
9920 echo "${ECHO_T}no" >&6
9923 echo "$as_me:9923: checking if you want to link with neXT Athena library" >&5
9924 echo $ECHO_N "checking if you want to link with neXT Athena library... $ECHO_C" >&6
9927 # Check whether --with-neXtaw or --without-neXtaw was given.
9928 if test "${with_neXtaw+set}" = set; then
9929 withval="$with_neXtaw"
9932 if test "$withval" = yes ; then
9934 echo "$as_me:9934: result: yes" >&5
9935 echo "${ECHO_T}yes" >&6
9937 echo "$as_me:9937: result: no" >&5
9938 echo "${ECHO_T}no" >&6
9941 echo "$as_me:9941: checking if you want to link with Athena-Plus library" >&5
9942 echo $ECHO_N "checking if you want to link with Athena-Plus library... $ECHO_C" >&6
9945 # Check whether --with-XawPlus or --without-XawPlus was given.
9946 if test "${with_XawPlus+set}" = set; then
9947 withval="$with_XawPlus"
9950 if test "$withval" = yes ; then
9952 echo "$as_me:9952: result: yes" >&5
9953 echo "${ECHO_T}yes" >&6
9955 echo "$as_me:9955: result: no" >&5
9956 echo "${ECHO_T}no" >&6
9961 if test "$PKG_CONFIG" != none ; then
9963 test "$cf_x_athena" = Xaw && cf_athena_list="xaw8 xaw7 xaw6"
9964 for cf_athena_pkg in \
9967 ${cf_x_athena}-devel \
9969 lib${cf_x_athena}-devel
9972 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists $cf_athena_pkg; then
9973 test -n "$verbose" && echo " found package $cf_athena_pkg" 1>&6
9975 echo "${as_me:-configure}:9975: testing found package $cf_athena_pkg ..." 1>&5
9977 cf_pkgconfig_incs="`$PKG_CONFIG --cflags $cf_athena_pkg 2>/dev/null`"
9978 cf_pkgconfig_libs="`$PKG_CONFIG --libs $cf_athena_pkg 2>/dev/null`"
9979 test -n "$verbose" && echo " package $cf_athena_pkg CFLAGS: $cf_pkgconfig_incs" 1>&6
9981 echo "${as_me:-configure}:9981: testing package $cf_athena_pkg CFLAGS: $cf_pkgconfig_incs ..." 1>&5
9983 test -n "$verbose" && echo " package $cf_athena_pkg LIBS: $cf_pkgconfig_libs" 1>&6
9985 echo "${as_me:-configure}:9985: testing package $cf_athena_pkg LIBS: $cf_pkgconfig_libs ..." 1>&5
9990 cf_new_extra_cppflags=
9992 for cf_add_cflags in $cf_pkgconfig_incs
9994 case $cf_fix_cppflags in
9996 case $cf_add_cflags in #(vi
9997 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
9998 case $cf_add_cflags in
10000 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10002 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10003 && test -z "${cf_tst_cflags}" \
10004 && cf_fix_cppflags=yes
10006 if test $cf_fix_cppflags = yes ; then
10007 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10009 elif test "${cf_tst_cflags}" = "\"'" ; then
10010 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10015 case "$CPPFLAGS" in
10016 *$cf_add_cflags) #(vi
10019 case $cf_add_cflags in #(vi
10021 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10023 CPPFLAGS=`echo "$CPPFLAGS" | \
10024 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10025 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10029 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
10034 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
10039 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10041 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10043 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10044 && test -z "${cf_tst_cflags}" \
10045 && cf_fix_cppflags=no
10050 if test -n "$cf_new_cflags" ; then
10052 CFLAGS="$CFLAGS $cf_new_cflags"
10055 if test -n "$cf_new_cppflags" ; then
10057 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
10060 if test -n "$cf_new_extra_cppflags" ; then
10062 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
10065 LIBS="$cf_pkgconfig_libs $LIBS"
10067 cf_x_athena_lib="$cf_pkgconfig_libs"
10069 cf_x_athena_LIBS=`echo "HAVE_LIB_$cf_x_athena" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
10071 cat >>confdefs.h <<EOF
10072 #define $cf_x_athena_LIBS 1
10075 for cf_trim_lib in Xmu Xt X11
10078 *-l$cf_trim_lib\ *-l$cf_trim_lib*)
10079 LIBS=`echo "$LIBS " | sed -e 's/ / /g' -e 's%-l'"$cf_trim_lib"' %%' -e 's/ $//'`
10080 test -n "$verbose" && echo " ..trimmed $LIBS" 1>&6
10082 echo "${as_me:-configure}:10082: testing ..trimmed $LIBS ..." 1>&5
10088 echo "$as_me:10088: checking for usable $cf_x_athena/Xmu package" >&5
10089 echo $ECHO_N "checking for usable $cf_x_athena/Xmu package... $ECHO_C" >&6
10090 if test "${cf_cv_xaw_compat+set}" = set; then
10091 echo $ECHO_N "(cached) $ECHO_C" >&6
10094 cat >conftest.$ac_ext <<_ACEOF
10095 #line 10095 "configure"
10096 #include "confdefs.h"
10098 #include <X11/Xmu/CharSet.h>
10104 int check = XmuCompareISOLatin1("big", "small")
10110 rm -f conftest.$ac_objext conftest$ac_exeext
10111 if { (eval echo "$as_me:10111: \"$ac_link\"") >&5
10112 (eval $ac_link) 2>&5
10114 echo "$as_me:10114: \$? = $ac_status" >&5
10115 (exit $ac_status); } &&
10116 { ac_try='test -s conftest$ac_exeext'
10117 { (eval echo "$as_me:10117: \"$ac_try\"") >&5
10118 (eval $ac_try) 2>&5
10120 echo "$as_me:10120: \$? = $ac_status" >&5
10121 (exit $ac_status); }; }; then
10122 cf_cv_xaw_compat=yes
10124 echo "$as_me: failed program was:" >&5
10125 cat conftest.$ac_ext >&5
10126 cf_cv_xaw_compat=no
10128 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10130 echo "$as_me:10130: result: $cf_cv_xaw_compat" >&5
10131 echo "${ECHO_T}$cf_cv_xaw_compat" >&6
10133 if test "$cf_cv_xaw_compat" = no
10135 # workaround for broken ".pc" files...
10136 case "$cf_x_athena_lib" in #(vi
10140 test -n "$verbose" && echo " work around broken package" 1>&6
10142 echo "${as_me:-configure}:10142: testing work around broken package ..." 1>&5
10144 cf_save_xmu="$LIBS"
10145 cf_first_lib=`echo "$cf_save_xmu" | sed -e 's/^ *//' -e 's/ .*//'`
10147 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xmu; then
10148 test -n "$verbose" && echo " found package xmu" 1>&6
10150 echo "${as_me:-configure}:10150: testing found package xmu ..." 1>&5
10152 cf_pkgconfig_incs="`$PKG_CONFIG --cflags xmu 2>/dev/null`"
10153 cf_pkgconfig_libs="`$PKG_CONFIG --libs xmu 2>/dev/null`"
10154 test -n "$verbose" && echo " package xmu CFLAGS: $cf_pkgconfig_incs" 1>&6
10156 echo "${as_me:-configure}:10156: testing package xmu CFLAGS: $cf_pkgconfig_incs ..." 1>&5
10158 test -n "$verbose" && echo " package xmu LIBS: $cf_pkgconfig_libs" 1>&6
10160 echo "${as_me:-configure}:10160: testing package xmu LIBS: $cf_pkgconfig_libs ..." 1>&5
10165 cf_new_extra_cppflags=
10167 for cf_add_cflags in $cf_pkgconfig_incs
10169 case $cf_fix_cppflags in
10171 case $cf_add_cflags in #(vi
10172 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
10173 case $cf_add_cflags in
10175 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10177 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10178 && test -z "${cf_tst_cflags}" \
10179 && cf_fix_cppflags=yes
10181 if test $cf_fix_cppflags = yes ; then
10182 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10184 elif test "${cf_tst_cflags}" = "\"'" ; then
10185 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10190 case "$CPPFLAGS" in
10191 *$cf_add_cflags) #(vi
10194 case $cf_add_cflags in #(vi
10196 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10198 CPPFLAGS=`echo "$CPPFLAGS" | \
10199 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10200 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10204 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
10209 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
10214 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10216 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10218 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10219 && test -z "${cf_tst_cflags}" \
10220 && cf_fix_cppflags=no
10225 if test -n "$cf_new_cflags" ; then
10227 CFLAGS="$CFLAGS $cf_new_cflags"
10230 if test -n "$cf_new_cppflags" ; then
10232 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
10235 if test -n "$cf_new_extra_cppflags" ; then
10237 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
10240 LIBS="$cf_pkgconfig_libs $LIBS"
10242 LIBS="$cf_save_xmu"
10244 test -n "$verbose" && echo " ...before $LIBS" 1>&6
10246 echo "${as_me:-configure}:10246: testing ...before $LIBS ..." 1>&5
10248 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%$cf_first_lib %$cf_first_lib $cf_pkgconfig_libs %" -e 's% % %g'`
10249 test -n "$verbose" && echo " ...after $LIBS" 1>&6
10251 echo "${as_me:-configure}:10251: testing ...after $LIBS ..." 1>&5
10257 test -n "$verbose" && echo " ...before $LIBS" 1>&6
10259 echo "${as_me:-configure}:10259: testing ...before $LIBS ..." 1>&5
10261 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%$cf_first_lib %$cf_first_lib -lXmu %" -e 's% % %g'`
10262 test -n "$verbose" && echo " ...after $LIBS" 1>&6
10264 echo "${as_me:-configure}:10264: testing ...after $LIBS ..." 1>&5
10268 for cf_trim_lib in Xmu Xt X11
10271 *-l$cf_trim_lib\ *-l$cf_trim_lib*)
10272 LIBS=`echo "$LIBS " | sed -e 's/ / /g' -e 's%-l'"$cf_trim_lib"' %%' -e 's/ $//'`
10273 test -n "$verbose" && echo " ..trimmed $LIBS" 1>&6
10275 echo "${as_me:-configure}:10275: testing ..trimmed $LIBS ..." 1>&5
10295 if test -z "$cf_x_athena_lib" ; then
10297 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists Xext; then
10298 test -n "$verbose" && echo " found package Xext" 1>&6
10300 echo "${as_me:-configure}:10300: testing found package Xext ..." 1>&5
10302 cf_pkgconfig_incs="`$PKG_CONFIG --cflags Xext 2>/dev/null`"
10303 cf_pkgconfig_libs="`$PKG_CONFIG --libs Xext 2>/dev/null`"
10304 test -n "$verbose" && echo " package Xext CFLAGS: $cf_pkgconfig_incs" 1>&6
10306 echo "${as_me:-configure}:10306: testing package Xext CFLAGS: $cf_pkgconfig_incs ..." 1>&5
10308 test -n "$verbose" && echo " package Xext LIBS: $cf_pkgconfig_libs" 1>&6
10310 echo "${as_me:-configure}:10310: testing package Xext LIBS: $cf_pkgconfig_libs ..." 1>&5
10315 cf_new_extra_cppflags=
10317 for cf_add_cflags in $cf_pkgconfig_incs
10319 case $cf_fix_cppflags in
10321 case $cf_add_cflags in #(vi
10322 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
10323 case $cf_add_cflags in
10325 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10327 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10328 && test -z "${cf_tst_cflags}" \
10329 && cf_fix_cppflags=yes
10331 if test $cf_fix_cppflags = yes ; then
10332 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10334 elif test "${cf_tst_cflags}" = "\"'" ; then
10335 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10340 case "$CPPFLAGS" in
10341 *$cf_add_cflags) #(vi
10344 case $cf_add_cflags in #(vi
10346 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10348 CPPFLAGS=`echo "$CPPFLAGS" | \
10349 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10350 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10354 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
10359 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
10364 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10366 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10368 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10369 && test -z "${cf_tst_cflags}" \
10370 && cf_fix_cppflags=no
10375 if test -n "$cf_new_cflags" ; then
10377 CFLAGS="$CFLAGS $cf_new_cflags"
10380 if test -n "$cf_new_cppflags" ; then
10382 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
10385 if test -n "$cf_new_extra_cppflags" ; then
10387 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
10390 LIBS="$cf_pkgconfig_libs $LIBS"
10396 echo "$as_me:10396: checking for XextCreateExtension in -lXext" >&5
10397 echo $ECHO_N "checking for XextCreateExtension in -lXext... $ECHO_C" >&6
10398 if test "${ac_cv_lib_Xext_XextCreateExtension+set}" = set; then
10399 echo $ECHO_N "(cached) $ECHO_C" >&6
10401 ac_check_lib_save_LIBS=$LIBS
10402 LIBS="-lXext $LIBS"
10403 cat >conftest.$ac_ext <<_ACEOF
10404 #line 10404 "configure"
10405 #include "confdefs.h"
10407 /* Override any gcc2 internal prototype to avoid an error. */
10411 /* We use char because int might match the return type of a gcc2
10412 builtin and then its argument prototype would still apply. */
10413 char XextCreateExtension ();
10417 XextCreateExtension ();
10422 rm -f conftest.$ac_objext conftest$ac_exeext
10423 if { (eval echo "$as_me:10423: \"$ac_link\"") >&5
10424 (eval $ac_link) 2>&5
10426 echo "$as_me:10426: \$? = $ac_status" >&5
10427 (exit $ac_status); } &&
10428 { ac_try='test -s conftest$ac_exeext'
10429 { (eval echo "$as_me:10429: \"$ac_try\"") >&5
10430 (eval $ac_try) 2>&5
10432 echo "$as_me:10432: \$? = $ac_status" >&5
10433 (exit $ac_status); }; }; then
10434 ac_cv_lib_Xext_XextCreateExtension=yes
10436 echo "$as_me: failed program was:" >&5
10437 cat conftest.$ac_ext >&5
10438 ac_cv_lib_Xext_XextCreateExtension=no
10440 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10441 LIBS=$ac_check_lib_save_LIBS
10443 echo "$as_me:10443: result: $ac_cv_lib_Xext_XextCreateExtension" >&5
10444 echo "${ECHO_T}$ac_cv_lib_Xext_XextCreateExtension" >&6
10445 if test $ac_cv_lib_Xext_XextCreateExtension = yes; then
10446 LIBS="-lXext $LIBS"
10453 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xt; then
10454 test -n "$verbose" && echo " found package xt" 1>&6
10456 echo "${as_me:-configure}:10456: testing found package xt ..." 1>&5
10458 cf_pkgconfig_incs="`$PKG_CONFIG --cflags xt 2>/dev/null`"
10459 cf_pkgconfig_libs="`$PKG_CONFIG --libs xt 2>/dev/null`"
10460 test -n "$verbose" && echo " package xt CFLAGS: $cf_pkgconfig_incs" 1>&6
10462 echo "${as_me:-configure}:10462: testing package xt CFLAGS: $cf_pkgconfig_incs ..." 1>&5
10464 test -n "$verbose" && echo " package xt LIBS: $cf_pkgconfig_libs" 1>&6
10466 echo "${as_me:-configure}:10466: testing package xt LIBS: $cf_pkgconfig_libs ..." 1>&5
10471 cf_new_extra_cppflags=
10473 for cf_add_cflags in $cf_pkgconfig_incs
10475 case $cf_fix_cppflags in
10477 case $cf_add_cflags in #(vi
10478 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
10479 case $cf_add_cflags in
10481 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10483 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10484 && test -z "${cf_tst_cflags}" \
10485 && cf_fix_cppflags=yes
10487 if test $cf_fix_cppflags = yes ; then
10488 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10490 elif test "${cf_tst_cflags}" = "\"'" ; then
10491 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10496 case "$CPPFLAGS" in
10497 *$cf_add_cflags) #(vi
10500 case $cf_add_cflags in #(vi
10502 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10504 CPPFLAGS=`echo "$CPPFLAGS" | \
10505 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10506 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10510 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
10515 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
10520 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10522 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10524 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10525 && test -z "${cf_tst_cflags}" \
10526 && cf_fix_cppflags=no
10531 if test -n "$cf_new_cflags" ; then
10533 CFLAGS="$CFLAGS $cf_new_cflags"
10536 if test -n "$cf_new_cppflags" ; then
10538 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
10541 if test -n "$cf_new_extra_cppflags" ; then
10543 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
10546 LIBS="$cf_pkgconfig_libs $LIBS"
10548 case "x$LIBS" in #(vi
10552 # we have an "xt" package, but it may omit Xt's dependency on X11
10553 echo "$as_me:10553: checking for usable X dependency" >&5
10554 echo $ECHO_N "checking for usable X dependency... $ECHO_C" >&6
10555 if test "${cf_cv_xt_x11_compat+set}" = set; then
10556 echo $ECHO_N "(cached) $ECHO_C" >&6
10559 cat >conftest.$ac_ext <<_ACEOF
10560 #line 10560 "configure"
10561 #include "confdefs.h"
10563 #include <X11/Xlib.h>
10569 int rc1 = XDrawLine((Display*) 0, (Drawable) 0, (GC) 0, 0, 0, 0, 0);
10570 int rc2 = XClearWindow((Display*) 0, (Window) 0);
10571 int rc3 = XMoveWindow((Display*) 0, (Window) 0, 0, 0);
10572 int rc4 = XMoveResizeWindow((Display*)0, (Window)0, 0, 0, 0, 0);
10578 rm -f conftest.$ac_objext conftest$ac_exeext
10579 if { (eval echo "$as_me:10579: \"$ac_link\"") >&5
10580 (eval $ac_link) 2>&5
10582 echo "$as_me:10582: \$? = $ac_status" >&5
10583 (exit $ac_status); } &&
10584 { ac_try='test -s conftest$ac_exeext'
10585 { (eval echo "$as_me:10585: \"$ac_try\"") >&5
10586 (eval $ac_try) 2>&5
10588 echo "$as_me:10588: \$? = $ac_status" >&5
10589 (exit $ac_status); }; }; then
10590 cf_cv_xt_x11_compat=yes
10592 echo "$as_me: failed program was:" >&5
10593 cat conftest.$ac_ext >&5
10594 cf_cv_xt_x11_compat=no
10596 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10598 echo "$as_me:10598: result: $cf_cv_xt_x11_compat" >&5
10599 echo "${ECHO_T}$cf_cv_xt_x11_compat" >&6
10600 if test "$cf_cv_xt_x11_compat" = no
10602 test -n "$verbose" && echo " work around broken X11 dependency" 1>&6
10604 echo "${as_me:-configure}:10604: testing work around broken X11 dependency ..." 1>&5
10606 # 2010/11/19 - good enough until a working Xt on Xcb is delivered.
10608 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists x11; then
10609 test -n "$verbose" && echo " found package x11" 1>&6
10611 echo "${as_me:-configure}:10611: testing found package x11 ..." 1>&5
10613 cf_pkgconfig_incs="`$PKG_CONFIG --cflags x11 2>/dev/null`"
10614 cf_pkgconfig_libs="`$PKG_CONFIG --libs x11 2>/dev/null`"
10615 test -n "$verbose" && echo " package x11 CFLAGS: $cf_pkgconfig_incs" 1>&6
10617 echo "${as_me:-configure}:10617: testing package x11 CFLAGS: $cf_pkgconfig_incs ..." 1>&5
10619 test -n "$verbose" && echo " package x11 LIBS: $cf_pkgconfig_libs" 1>&6
10621 echo "${as_me:-configure}:10621: testing package x11 LIBS: $cf_pkgconfig_libs ..." 1>&5
10626 cf_new_extra_cppflags=
10628 for cf_add_cflags in $cf_pkgconfig_incs
10630 case $cf_fix_cppflags in
10632 case $cf_add_cflags in #(vi
10633 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
10634 case $cf_add_cflags in
10636 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10638 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10639 && test -z "${cf_tst_cflags}" \
10640 && cf_fix_cppflags=yes
10642 if test $cf_fix_cppflags = yes ; then
10643 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10645 elif test "${cf_tst_cflags}" = "\"'" ; then
10646 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10651 case "$CPPFLAGS" in
10652 *$cf_add_cflags) #(vi
10655 case $cf_add_cflags in #(vi
10657 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10659 CPPFLAGS=`echo "$CPPFLAGS" | \
10660 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10661 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10665 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
10670 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
10675 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10677 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10679 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10680 && test -z "${cf_tst_cflags}" \
10681 && cf_fix_cppflags=no
10686 if test -n "$cf_new_cflags" ; then
10688 CFLAGS="$CFLAGS $cf_new_cflags"
10691 if test -n "$cf_new_cppflags" ; then
10693 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
10696 if test -n "$cf_new_extra_cppflags" ; then
10698 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
10701 LIBS="$cf_pkgconfig_libs $LIBS"
10707 test -n "$verbose" && echo " ...before $LIBS" 1>&6
10709 echo "${as_me:-configure}:10709: testing ...before $LIBS ..." 1>&5
10711 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%-lXt %-lXt -lX11 %" -e 's% % %g'`
10712 test -n "$verbose" && echo " ...after $LIBS" 1>&6
10714 echo "${as_me:-configure}:10714: testing ...after $LIBS ..." 1>&5
10722 echo "$as_me:10722: checking for usable X Toolkit package" >&5
10723 echo $ECHO_N "checking for usable X Toolkit package... $ECHO_C" >&6
10724 if test "${cf_cv_xt_ice_compat+set}" = set; then
10725 echo $ECHO_N "(cached) $ECHO_C" >&6
10728 cat >conftest.$ac_ext <<_ACEOF
10729 #line 10729 "configure"
10730 #include "confdefs.h"
10732 #include <X11/Shell.h>
10737 int num = IceConnectionNumber(0)
10743 rm -f conftest.$ac_objext conftest$ac_exeext
10744 if { (eval echo "$as_me:10744: \"$ac_link\"") >&5
10745 (eval $ac_link) 2>&5
10747 echo "$as_me:10747: \$? = $ac_status" >&5
10748 (exit $ac_status); } &&
10749 { ac_try='test -s conftest$ac_exeext'
10750 { (eval echo "$as_me:10750: \"$ac_try\"") >&5
10751 (eval $ac_try) 2>&5
10753 echo "$as_me:10753: \$? = $ac_status" >&5
10754 (exit $ac_status); }; }; then
10755 cf_cv_xt_ice_compat=yes
10757 echo "$as_me: failed program was:" >&5
10758 cat conftest.$ac_ext >&5
10759 cf_cv_xt_ice_compat=no
10761 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10763 echo "$as_me:10763: result: $cf_cv_xt_ice_compat" >&5
10764 echo "${ECHO_T}$cf_cv_xt_ice_compat" >&6
10766 if test "$cf_cv_xt_ice_compat" = no
10768 # workaround for broken ".pc" files used for X Toolkit.
10769 case "x$X_PRE_LIBS" in #(vi
10771 case "x$LIBS" in #(vi
10775 test -n "$verbose" && echo " work around broken ICE dependency" 1>&6
10777 echo "${as_me:-configure}:10777: testing work around broken ICE dependency ..." 1>&5
10779 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists ice; then
10780 test -n "$verbose" && echo " found package ice" 1>&6
10782 echo "${as_me:-configure}:10782: testing found package ice ..." 1>&5
10784 cf_pkgconfig_incs="`$PKG_CONFIG --cflags ice 2>/dev/null`"
10785 cf_pkgconfig_libs="`$PKG_CONFIG --libs ice 2>/dev/null`"
10786 test -n "$verbose" && echo " package ice CFLAGS: $cf_pkgconfig_incs" 1>&6
10788 echo "${as_me:-configure}:10788: testing package ice CFLAGS: $cf_pkgconfig_incs ..." 1>&5
10790 test -n "$verbose" && echo " package ice LIBS: $cf_pkgconfig_libs" 1>&6
10792 echo "${as_me:-configure}:10792: testing package ice LIBS: $cf_pkgconfig_libs ..." 1>&5
10797 cf_new_extra_cppflags=
10799 for cf_add_cflags in $cf_pkgconfig_incs
10801 case $cf_fix_cppflags in
10803 case $cf_add_cflags in #(vi
10804 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
10805 case $cf_add_cflags in
10807 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10809 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10810 && test -z "${cf_tst_cflags}" \
10811 && cf_fix_cppflags=yes
10813 if test $cf_fix_cppflags = yes ; then
10814 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10816 elif test "${cf_tst_cflags}" = "\"'" ; then
10817 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10822 case "$CPPFLAGS" in
10823 *$cf_add_cflags) #(vi
10826 case $cf_add_cflags in #(vi
10828 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10830 CPPFLAGS=`echo "$CPPFLAGS" | \
10831 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10832 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10836 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
10841 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
10846 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10848 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10850 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10851 && test -z "${cf_tst_cflags}" \
10852 && cf_fix_cppflags=no
10857 if test -n "$cf_new_cflags" ; then
10859 CFLAGS="$CFLAGS $cf_new_cflags"
10862 if test -n "$cf_new_cppflags" ; then
10864 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
10867 if test -n "$cf_new_extra_cppflags" ; then
10869 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
10872 LIBS="$cf_pkgconfig_libs $LIBS"
10874 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists sm; then
10875 test -n "$verbose" && echo " found package sm" 1>&6
10877 echo "${as_me:-configure}:10877: testing found package sm ..." 1>&5
10879 cf_pkgconfig_incs="`$PKG_CONFIG --cflags sm 2>/dev/null`"
10880 cf_pkgconfig_libs="`$PKG_CONFIG --libs sm 2>/dev/null`"
10881 test -n "$verbose" && echo " package sm CFLAGS: $cf_pkgconfig_incs" 1>&6
10883 echo "${as_me:-configure}:10883: testing package sm CFLAGS: $cf_pkgconfig_incs ..." 1>&5
10885 test -n "$verbose" && echo " package sm LIBS: $cf_pkgconfig_libs" 1>&6
10887 echo "${as_me:-configure}:10887: testing package sm LIBS: $cf_pkgconfig_libs ..." 1>&5
10892 cf_new_extra_cppflags=
10894 for cf_add_cflags in $cf_pkgconfig_incs
10896 case $cf_fix_cppflags in
10898 case $cf_add_cflags in #(vi
10899 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
10900 case $cf_add_cflags in
10902 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10904 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10905 && test -z "${cf_tst_cflags}" \
10906 && cf_fix_cppflags=yes
10908 if test $cf_fix_cppflags = yes ; then
10909 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10911 elif test "${cf_tst_cflags}" = "\"'" ; then
10912 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10917 case "$CPPFLAGS" in
10918 *$cf_add_cflags) #(vi
10921 case $cf_add_cflags in #(vi
10923 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10925 CPPFLAGS=`echo "$CPPFLAGS" | \
10926 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10927 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10931 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
10936 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
10941 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10943 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10945 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10946 && test -z "${cf_tst_cflags}" \
10947 && cf_fix_cppflags=no
10952 if test -n "$cf_new_cflags" ; then
10954 CFLAGS="$CFLAGS $cf_new_cflags"
10957 if test -n "$cf_new_cppflags" ; then
10959 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
10962 if test -n "$cf_new_extra_cppflags" ; then
10964 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
10967 LIBS="$cf_pkgconfig_libs $LIBS"
10979 test -n "$verbose" && echo " ...before $LIBS" 1>&6
10981 echo "${as_me:-configure}:10981: testing ...before $LIBS ..." 1>&5
10983 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%-lXt %-lXt $X_PRE_LIBS %" -e 's% % %g'`
10984 test -n "$verbose" && echo " ...after $LIBS" 1>&6
10986 echo "${as_me:-configure}:10986: testing ...after $LIBS ..." 1>&5
11002 LDFLAGS="$X_LIBS $LDFLAGS"
11004 test -n "$verbose" && echo " checking additions to CFLAGS" 1>&6
11006 echo "${as_me:-configure}:11006: testing checking additions to CFLAGS ..." 1>&5
11008 cf_check_cflags="$CFLAGS"
11009 cf_check_cppflags="$CPPFLAGS"
11014 cf_new_extra_cppflags=
11016 for cf_add_cflags in $X_CFLAGS
11018 case $cf_fix_cppflags in
11020 case $cf_add_cflags in #(vi
11021 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
11022 case $cf_add_cflags in
11024 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11026 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11027 && test -z "${cf_tst_cflags}" \
11028 && cf_fix_cppflags=yes
11030 if test $cf_fix_cppflags = yes ; then
11031 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11033 elif test "${cf_tst_cflags}" = "\"'" ; then
11034 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11039 case "$CPPFLAGS" in
11040 *$cf_add_cflags) #(vi
11043 case $cf_add_cflags in #(vi
11045 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11047 CPPFLAGS=`echo "$CPPFLAGS" | \
11048 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11049 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11053 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
11058 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
11063 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11065 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11067 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11068 && test -z "${cf_tst_cflags}" \
11069 && cf_fix_cppflags=no
11074 if test -n "$cf_new_cflags" ; then
11075 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
11077 echo "${as_me:-configure}:11077: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
11079 CFLAGS="$CFLAGS $cf_new_cflags"
11082 if test -n "$cf_new_cppflags" ; then
11083 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
11085 echo "${as_me:-configure}:11085: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
11087 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
11090 if test -n "$cf_new_extra_cppflags" ; then
11091 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
11093 echo "${as_me:-configure}:11093: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
11095 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
11098 if test "$cf_check_cflags" != "$CFLAGS" ; then
11099 cat >conftest.$ac_ext <<_ACEOF
11100 #line 11100 "configure"
11101 #include "confdefs.h"
11106 printf("Hello world");
11111 rm -f conftest.$ac_objext conftest$ac_exeext
11112 if { (eval echo "$as_me:11112: \"$ac_link\"") >&5
11113 (eval $ac_link) 2>&5
11115 echo "$as_me:11115: \$? = $ac_status" >&5
11116 (exit $ac_status); } &&
11117 { ac_try='test -s conftest$ac_exeext'
11118 { (eval echo "$as_me:11118: \"$ac_try\"") >&5
11119 (eval $ac_try) 2>&5
11121 echo "$as_me:11121: \$? = $ac_status" >&5
11122 (exit $ac_status); }; }; then
11125 echo "$as_me: failed program was:" >&5
11126 cat conftest.$ac_ext >&5
11127 test -n "$verbose" && echo " test-compile failed. Undoing change to \$CFLAGS" 1>&6
11129 echo "${as_me:-configure}:11129: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5
11131 if test "$cf_check_cppflags" != "$CPPFLAGS" ; then
11132 test -n "$verbose" && echo " but keeping change to \$CPPFLAGS" 1>&6
11134 echo "${as_me:-configure}:11134: testing but keeping change to \$CPPFLAGS ..." 1>&5
11137 CFLAGS="$cf_check_flags"
11139 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11142 echo "$as_me:11142: checking for XOpenDisplay" >&5
11143 echo $ECHO_N "checking for XOpenDisplay... $ECHO_C" >&6
11144 if test "${ac_cv_func_XOpenDisplay+set}" = set; then
11145 echo $ECHO_N "(cached) $ECHO_C" >&6
11147 cat >conftest.$ac_ext <<_ACEOF
11148 #line 11148 "configure"
11149 #include "confdefs.h"
11150 /* System header to define __stub macros and hopefully few prototypes,
11151 which can conflict with char XOpenDisplay (); below. */
11152 #include <assert.h>
11153 /* Override any gcc2 internal prototype to avoid an error. */
11157 /* We use char because int might match the return type of a gcc2
11158 builtin and then its argument prototype would still apply. */
11159 char XOpenDisplay ();
11165 /* The GNU C library defines this for functions which it implements
11166 to always fail with ENOSYS. Some functions are actually named
11167 something starting with __ and the normal name is an alias. */
11168 #if defined (__stub_XOpenDisplay) || defined (__stub___XOpenDisplay)
11171 f = XOpenDisplay; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
11178 rm -f conftest.$ac_objext conftest$ac_exeext
11179 if { (eval echo "$as_me:11179: \"$ac_link\"") >&5
11180 (eval $ac_link) 2>&5
11182 echo "$as_me:11182: \$? = $ac_status" >&5
11183 (exit $ac_status); } &&
11184 { ac_try='test -s conftest$ac_exeext'
11185 { (eval echo "$as_me:11185: \"$ac_try\"") >&5
11186 (eval $ac_try) 2>&5
11188 echo "$as_me:11188: \$? = $ac_status" >&5
11189 (exit $ac_status); }; }; then
11190 ac_cv_func_XOpenDisplay=yes
11192 echo "$as_me: failed program was:" >&5
11193 cat conftest.$ac_ext >&5
11194 ac_cv_func_XOpenDisplay=no
11196 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11198 echo "$as_me:11198: result: $ac_cv_func_XOpenDisplay" >&5
11199 echo "${ECHO_T}$ac_cv_func_XOpenDisplay" >&6
11200 if test $ac_cv_func_XOpenDisplay = yes; then
11204 echo "$as_me:11204: checking for XOpenDisplay in -lX11" >&5
11205 echo $ECHO_N "checking for XOpenDisplay in -lX11... $ECHO_C" >&6
11206 if test "${ac_cv_lib_X11_XOpenDisplay+set}" = set; then
11207 echo $ECHO_N "(cached) $ECHO_C" >&6
11209 ac_check_lib_save_LIBS=$LIBS
11210 LIBS="-lX11 $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
11211 cat >conftest.$ac_ext <<_ACEOF
11212 #line 11212 "configure"
11213 #include "confdefs.h"
11215 /* Override any gcc2 internal prototype to avoid an error. */
11219 /* We use char because int might match the return type of a gcc2
11220 builtin and then its argument prototype would still apply. */
11221 char XOpenDisplay ();
11230 rm -f conftest.$ac_objext conftest$ac_exeext
11231 if { (eval echo "$as_me:11231: \"$ac_link\"") >&5
11232 (eval $ac_link) 2>&5
11234 echo "$as_me:11234: \$? = $ac_status" >&5
11235 (exit $ac_status); } &&
11236 { ac_try='test -s conftest$ac_exeext'
11237 { (eval echo "$as_me:11237: \"$ac_try\"") >&5
11238 (eval $ac_try) 2>&5
11240 echo "$as_me:11240: \$? = $ac_status" >&5
11241 (exit $ac_status); }; }; then
11242 ac_cv_lib_X11_XOpenDisplay=yes
11244 echo "$as_me: failed program was:" >&5
11245 cat conftest.$ac_ext >&5
11246 ac_cv_lib_X11_XOpenDisplay=no
11248 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11249 LIBS=$ac_check_lib_save_LIBS
11251 echo "$as_me:11251: result: $ac_cv_lib_X11_XOpenDisplay" >&5
11252 echo "${ECHO_T}$ac_cv_lib_X11_XOpenDisplay" >&6
11253 if test $ac_cv_lib_X11_XOpenDisplay = yes; then
11259 echo "$as_me:11259: checking for XtAppInitialize" >&5
11260 echo $ECHO_N "checking for XtAppInitialize... $ECHO_C" >&6
11261 if test "${ac_cv_func_XtAppInitialize+set}" = set; then
11262 echo $ECHO_N "(cached) $ECHO_C" >&6
11264 cat >conftest.$ac_ext <<_ACEOF
11265 #line 11265 "configure"
11266 #include "confdefs.h"
11267 /* System header to define __stub macros and hopefully few prototypes,
11268 which can conflict with char XtAppInitialize (); below. */
11269 #include <assert.h>
11270 /* Override any gcc2 internal prototype to avoid an error. */
11274 /* We use char because int might match the return type of a gcc2
11275 builtin and then its argument prototype would still apply. */
11276 char XtAppInitialize ();
11282 /* The GNU C library defines this for functions which it implements
11283 to always fail with ENOSYS. Some functions are actually named
11284 something starting with __ and the normal name is an alias. */
11285 #if defined (__stub_XtAppInitialize) || defined (__stub___XtAppInitialize)
11288 f = XtAppInitialize; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
11295 rm -f conftest.$ac_objext conftest$ac_exeext
11296 if { (eval echo "$as_me:11296: \"$ac_link\"") >&5
11297 (eval $ac_link) 2>&5
11299 echo "$as_me:11299: \$? = $ac_status" >&5
11300 (exit $ac_status); } &&
11301 { ac_try='test -s conftest$ac_exeext'
11302 { (eval echo "$as_me:11302: \"$ac_try\"") >&5
11303 (eval $ac_try) 2>&5
11305 echo "$as_me:11305: \$? = $ac_status" >&5
11306 (exit $ac_status); }; }; then
11307 ac_cv_func_XtAppInitialize=yes
11309 echo "$as_me: failed program was:" >&5
11310 cat conftest.$ac_ext >&5
11311 ac_cv_func_XtAppInitialize=no
11313 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11315 echo "$as_me:11315: result: $ac_cv_func_XtAppInitialize" >&5
11316 echo "${ECHO_T}$ac_cv_func_XtAppInitialize" >&6
11317 if test $ac_cv_func_XtAppInitialize = yes; then
11321 echo "$as_me:11321: checking for XtAppInitialize in -lXt" >&5
11322 echo $ECHO_N "checking for XtAppInitialize in -lXt... $ECHO_C" >&6
11323 if test "${ac_cv_lib_Xt_XtAppInitialize+set}" = set; then
11324 echo $ECHO_N "(cached) $ECHO_C" >&6
11326 ac_check_lib_save_LIBS=$LIBS
11327 LIBS="-lXt $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
11328 cat >conftest.$ac_ext <<_ACEOF
11329 #line 11329 "configure"
11330 #include "confdefs.h"
11332 /* Override any gcc2 internal prototype to avoid an error. */
11336 /* We use char because int might match the return type of a gcc2
11337 builtin and then its argument prototype would still apply. */
11338 char XtAppInitialize ();
11342 XtAppInitialize ();
11347 rm -f conftest.$ac_objext conftest$ac_exeext
11348 if { (eval echo "$as_me:11348: \"$ac_link\"") >&5
11349 (eval $ac_link) 2>&5
11351 echo "$as_me:11351: \$? = $ac_status" >&5
11352 (exit $ac_status); } &&
11353 { ac_try='test -s conftest$ac_exeext'
11354 { (eval echo "$as_me:11354: \"$ac_try\"") >&5
11355 (eval $ac_try) 2>&5
11357 echo "$as_me:11357: \$? = $ac_status" >&5
11358 (exit $ac_status); }; }; then
11359 ac_cv_lib_Xt_XtAppInitialize=yes
11361 echo "$as_me: failed program was:" >&5
11362 cat conftest.$ac_ext >&5
11363 ac_cv_lib_Xt_XtAppInitialize=no
11365 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11366 LIBS=$ac_check_lib_save_LIBS
11368 echo "$as_me:11368: result: $ac_cv_lib_Xt_XtAppInitialize" >&5
11369 echo "${ECHO_T}$ac_cv_lib_Xt_XtAppInitialize" >&6
11370 if test $ac_cv_lib_Xt_XtAppInitialize = yes; then
11372 cat >>confdefs.h <<\EOF
11373 #define HAVE_LIBXT 1
11377 LIBS="-lXt $X_PRE_LIBS $LIBS $X_EXTRA_LIBS"
11384 if test $cf_have_X_LIBS = no ; then
11385 { echo "$as_me:11385: WARNING: Unable to successfully link X Toolkit library (-lXt) with
11386 test program. You will have to check and add the proper libraries by hand
11388 echo "$as_me: WARNING: Unable to successfully link X Toolkit library (-lXt) with
11389 test program. You will have to check and add the proper libraries by hand
11390 to makefile." >&2;}
11393 cf_x_athena_root=$cf_x_athena
11396 for cf_path in default \
11397 /usr/contrib/X11R6 \
11398 /usr/contrib/X11R5 \
11402 if test -z "$cf_x_athena_inc" ; then
11403 cf_save="$CPPFLAGS"
11404 cf_test=X11/$cf_x_athena_root/SimpleMenu.h
11405 if test $cf_path != default ; then
11406 CPPFLAGS="$cf_save -I$cf_path/include"
11407 echo "$as_me:11407: checking for $cf_test in $cf_path" >&5
11408 echo $ECHO_N "checking for $cf_test in $cf_path... $ECHO_C" >&6
11410 echo "$as_me:11410: checking for $cf_test" >&5
11411 echo $ECHO_N "checking for $cf_test... $ECHO_C" >&6
11413 cat >conftest.$ac_ext <<_ACEOF
11414 #line 11414 "configure"
11415 #include "confdefs.h"
11417 #include <X11/Intrinsic.h>
11418 #include <$cf_test>
11427 rm -f conftest.$ac_objext
11428 if { (eval echo "$as_me:11428: \"$ac_compile\"") >&5
11429 (eval $ac_compile) 2>&5
11431 echo "$as_me:11431: \$? = $ac_status" >&5
11432 (exit $ac_status); } &&
11433 { ac_try='test -s conftest.$ac_objext'
11434 { (eval echo "$as_me:11434: \"$ac_try\"") >&5
11435 (eval $ac_try) 2>&5
11437 echo "$as_me:11437: \$? = $ac_status" >&5
11438 (exit $ac_status); }; }; then
11441 echo "$as_me: failed program was:" >&5
11442 cat conftest.$ac_ext >&5
11445 rm -f conftest.$ac_objext conftest.$ac_ext
11446 echo "$as_me:11446: result: $cf_result" >&5
11447 echo "${ECHO_T}$cf_result" >&6
11448 if test "$cf_result" = yes ; then
11449 cf_x_athena_inc=$cf_path
11452 CPPFLAGS="$cf_save"
11457 if test -z "$cf_x_athena_inc" ; then
11458 { echo "$as_me:11458: WARNING: Unable to successfully find Athena header files with test program" >&5
11459 echo "$as_me: WARNING: Unable to successfully find Athena header files with test program" >&2;}
11460 elif test "$cf_x_athena_inc" != default ; then
11461 CPPFLAGS="$CPPFLAGS -I$cf_x_athena_inc"
11464 cf_x_athena_root=$cf_x_athena
11467 for cf_path in default \
11468 /usr/contrib/X11R6 \
11469 /usr/contrib/X11R5 \
11474 ${cf_x_athena_root} \
11475 ${cf_x_athena_root}7 \
11476 ${cf_x_athena_root}6
11479 "-l$cf_lib -lXmu" \
11480 "-l$cf_lib -lXpm -lXmu" \
11481 "-l${cf_lib}_s -lXmu_s"
11483 if test -z "$cf_x_athena_lib" ; then
11485 cf_test=XawSimpleMenuAddGlobalActions
11486 if test $cf_path != default ; then
11487 LIBS="-L$cf_path/lib $cf_libs $LIBS"
11488 echo "$as_me:11488: checking for $cf_libs in $cf_path" >&5
11489 echo $ECHO_N "checking for $cf_libs in $cf_path... $ECHO_C" >&6
11491 LIBS="$cf_libs $LIBS"
11492 echo "$as_me:11492: checking for $cf_test in $cf_libs" >&5
11493 echo $ECHO_N "checking for $cf_test in $cf_libs... $ECHO_C" >&6
11495 cat >conftest.$ac_ext <<_ACEOF
11496 #line 11496 "configure"
11497 #include "confdefs.h"
11499 #include <X11/Intrinsic.h>
11500 #include <X11/$cf_x_athena_root/SimpleMenu.h>
11506 $cf_test((XtAppContext) 0)
11511 rm -f conftest.$ac_objext conftest$ac_exeext
11512 if { (eval echo "$as_me:11512: \"$ac_link\"") >&5
11513 (eval $ac_link) 2>&5
11515 echo "$as_me:11515: \$? = $ac_status" >&5
11516 (exit $ac_status); } &&
11517 { ac_try='test -s conftest$ac_exeext'
11518 { (eval echo "$as_me:11518: \"$ac_try\"") >&5
11519 (eval $ac_try) 2>&5
11521 echo "$as_me:11521: \$? = $ac_status" >&5
11522 (exit $ac_status); }; }; then
11525 echo "$as_me: failed program was:" >&5
11526 cat conftest.$ac_ext >&5
11529 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11530 echo "$as_me:11530: result: $cf_result" >&5
11531 echo "${ECHO_T}$cf_result" >&6
11532 if test "$cf_result" = yes ; then
11533 cf_x_athena_lib="$cf_libs"
11539 test -n "$cf_x_athena_lib" && break
11543 if test -z "$cf_x_athena_lib" ; then
11544 { { echo "$as_me:11544: error: Unable to successfully link Athena library (-l$cf_x_athena_root) with test program" >&5
11545 echo "$as_me: error: Unable to successfully link Athena library (-l$cf_x_athena_root) with test program" >&2;}
11546 { (exit 1); exit 1; }; }
11549 cf_x_athena_LIBS=`echo "HAVE_LIB_$cf_x_athena" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
11551 cat >>confdefs.h <<EOF
11552 #define $cf_x_athena_LIBS 1
11557 if test -n "$ac_tool_prefix"; then
11558 for ac_prog in xcurses-config
11560 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
11561 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
11562 echo "$as_me:11562: checking for $ac_word" >&5
11563 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
11564 if test "${ac_cv_prog_XCURSES_CONFIG+set}" = set; then
11565 echo $ECHO_N "(cached) $ECHO_C" >&6
11567 if test -n "$XCURSES_CONFIG"; then
11568 ac_cv_prog_XCURSES_CONFIG="$XCURSES_CONFIG" # Let the user override the test.
11570 ac_save_IFS=$IFS; IFS=$ac_path_separator
11572 for ac_dir in $ac_dummy; do
11574 test -z "$ac_dir" && ac_dir=.
11575 $as_executable_p "$ac_dir/$ac_word" || continue
11576 ac_cv_prog_XCURSES_CONFIG="$ac_tool_prefix$ac_prog"
11577 echo "$as_me:11577: found $ac_dir/$ac_word" >&5
11583 XCURSES_CONFIG=$ac_cv_prog_XCURSES_CONFIG
11584 if test -n "$XCURSES_CONFIG"; then
11585 echo "$as_me:11585: result: $XCURSES_CONFIG" >&5
11586 echo "${ECHO_T}$XCURSES_CONFIG" >&6
11588 echo "$as_me:11588: result: no" >&5
11589 echo "${ECHO_T}no" >&6
11592 test -n "$XCURSES_CONFIG" && break
11595 if test -z "$XCURSES_CONFIG"; then
11596 ac_ct_XCURSES_CONFIG=$XCURSES_CONFIG
11597 for ac_prog in xcurses-config
11599 # Extract the first word of "$ac_prog", so it can be a program name with args.
11600 set dummy $ac_prog; ac_word=$2
11601 echo "$as_me:11601: checking for $ac_word" >&5
11602 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
11603 if test "${ac_cv_prog_ac_ct_XCURSES_CONFIG+set}" = set; then
11604 echo $ECHO_N "(cached) $ECHO_C" >&6
11606 if test -n "$ac_ct_XCURSES_CONFIG"; then
11607 ac_cv_prog_ac_ct_XCURSES_CONFIG="$ac_ct_XCURSES_CONFIG" # Let the user override the test.
11609 ac_save_IFS=$IFS; IFS=$ac_path_separator
11611 for ac_dir in $ac_dummy; do
11613 test -z "$ac_dir" && ac_dir=.
11614 $as_executable_p "$ac_dir/$ac_word" || continue
11615 ac_cv_prog_ac_ct_XCURSES_CONFIG="$ac_prog"
11616 echo "$as_me:11616: found $ac_dir/$ac_word" >&5
11622 ac_ct_XCURSES_CONFIG=$ac_cv_prog_ac_ct_XCURSES_CONFIG
11623 if test -n "$ac_ct_XCURSES_CONFIG"; then
11624 echo "$as_me:11624: result: $ac_ct_XCURSES_CONFIG" >&5
11625 echo "${ECHO_T}$ac_ct_XCURSES_CONFIG" >&6
11627 echo "$as_me:11627: result: no" >&5
11628 echo "${ECHO_T}no" >&6
11631 test -n "$ac_ct_XCURSES_CONFIG" && break
11633 test -n "$ac_ct_XCURSES_CONFIG" || ac_ct_XCURSES_CONFIG="none"
11635 XCURSES_CONFIG=$ac_ct_XCURSES_CONFIG
11638 if test "$XCURSES_CONFIG" != none ; then
11640 CPPFLAGS="$CPPFLAGS `$XCURSES_CONFIG --cflags`"
11641 LIBS="`$XCURSES_CONFIG --libs` $LIBS"
11643 cf_cv_lib_XCurses=yes
11647 LDFLAGS="$LDFLAGS $X_LIBS"
11649 test -n "$verbose" && echo " checking additions to CFLAGS" 1>&6
11651 echo "${as_me:-configure}:11651: testing checking additions to CFLAGS ..." 1>&5
11653 cf_check_cflags="$CFLAGS"
11654 cf_check_cppflags="$CPPFLAGS"
11659 cf_new_extra_cppflags=
11661 for cf_add_cflags in $X_CFLAGS
11663 case $cf_fix_cppflags in
11665 case $cf_add_cflags in #(vi
11666 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
11667 case $cf_add_cflags in
11669 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11671 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11672 && test -z "${cf_tst_cflags}" \
11673 && cf_fix_cppflags=yes
11675 if test $cf_fix_cppflags = yes ; then
11676 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11678 elif test "${cf_tst_cflags}" = "\"'" ; then
11679 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11684 case "$CPPFLAGS" in
11685 *$cf_add_cflags) #(vi
11688 case $cf_add_cflags in #(vi
11690 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11692 CPPFLAGS=`echo "$CPPFLAGS" | \
11693 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11694 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11698 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
11703 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
11708 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11710 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11712 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11713 && test -z "${cf_tst_cflags}" \
11714 && cf_fix_cppflags=no
11719 if test -n "$cf_new_cflags" ; then
11720 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
11722 echo "${as_me:-configure}:11722: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
11724 CFLAGS="$CFLAGS $cf_new_cflags"
11727 if test -n "$cf_new_cppflags" ; then
11728 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
11730 echo "${as_me:-configure}:11730: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
11732 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
11735 if test -n "$cf_new_extra_cppflags" ; then
11736 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
11738 echo "${as_me:-configure}:11738: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
11740 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
11743 if test "$cf_check_cflags" != "$CFLAGS" ; then
11744 cat >conftest.$ac_ext <<_ACEOF
11745 #line 11745 "configure"
11746 #include "confdefs.h"
11751 printf("Hello world");
11756 rm -f conftest.$ac_objext conftest$ac_exeext
11757 if { (eval echo "$as_me:11757: \"$ac_link\"") >&5
11758 (eval $ac_link) 2>&5
11760 echo "$as_me:11760: \$? = $ac_status" >&5
11761 (exit $ac_status); } &&
11762 { ac_try='test -s conftest$ac_exeext'
11763 { (eval echo "$as_me:11763: \"$ac_try\"") >&5
11764 (eval $ac_try) 2>&5
11766 echo "$as_me:11766: \$? = $ac_status" >&5
11767 (exit $ac_status); }; }; then
11770 echo "$as_me: failed program was:" >&5
11771 cat conftest.$ac_ext >&5
11772 test -n "$verbose" && echo " test-compile failed. Undoing change to \$CFLAGS" 1>&6
11774 echo "${as_me:-configure}:11774: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5
11776 if test "$cf_check_cppflags" != "$CPPFLAGS" ; then
11777 test -n "$verbose" && echo " but keeping change to \$CPPFLAGS" 1>&6
11779 echo "${as_me:-configure}:11779: testing but keeping change to \$CPPFLAGS ..." 1>&5
11782 CFLAGS="$cf_check_flags"
11784 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11787 echo "$as_me:11787: checking for XOpenDisplay in -lX11" >&5
11788 echo $ECHO_N "checking for XOpenDisplay in -lX11... $ECHO_C" >&6
11789 if test "${ac_cv_lib_X11_XOpenDisplay+set}" = set; then
11790 echo $ECHO_N "(cached) $ECHO_C" >&6
11792 ac_check_lib_save_LIBS=$LIBS
11793 LIBS="-lX11 $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
11794 cat >conftest.$ac_ext <<_ACEOF
11795 #line 11795 "configure"
11796 #include "confdefs.h"
11798 /* Override any gcc2 internal prototype to avoid an error. */
11802 /* We use char because int might match the return type of a gcc2
11803 builtin and then its argument prototype would still apply. */
11804 char XOpenDisplay ();
11813 rm -f conftest.$ac_objext conftest$ac_exeext
11814 if { (eval echo "$as_me:11814: \"$ac_link\"") >&5
11815 (eval $ac_link) 2>&5
11817 echo "$as_me:11817: \$? = $ac_status" >&5
11818 (exit $ac_status); } &&
11819 { ac_try='test -s conftest$ac_exeext'
11820 { (eval echo "$as_me:11820: \"$ac_try\"") >&5
11821 (eval $ac_try) 2>&5
11823 echo "$as_me:11823: \$? = $ac_status" >&5
11824 (exit $ac_status); }; }; then
11825 ac_cv_lib_X11_XOpenDisplay=yes
11827 echo "$as_me: failed program was:" >&5
11828 cat conftest.$ac_ext >&5
11829 ac_cv_lib_X11_XOpenDisplay=no
11831 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11832 LIBS=$ac_check_lib_save_LIBS
11834 echo "$as_me:11834: result: $ac_cv_lib_X11_XOpenDisplay" >&5
11835 echo "${ECHO_T}$ac_cv_lib_X11_XOpenDisplay" >&6
11836 if test $ac_cv_lib_X11_XOpenDisplay = yes; then
11840 echo "$as_me:11840: checking for XCurses library" >&5
11841 echo $ECHO_N "checking for XCurses library... $ECHO_C" >&6
11842 if test "${cf_cv_lib_XCurses+set}" = set; then
11843 echo $ECHO_N "(cached) $ECHO_C" >&6
11846 LIBS="-lXCurses $LIBS"
11847 cat >conftest.$ac_ext <<_ACEOF
11848 #line 11848 "configure"
11849 #include "confdefs.h"
11851 #include <xcurses.h>
11852 char *XCursesProgramName = "test";
11862 rm -f conftest.$ac_objext conftest$ac_exeext
11863 if { (eval echo "$as_me:11863: \"$ac_link\"") >&5
11864 (eval $ac_link) 2>&5
11866 echo "$as_me:11866: \$? = $ac_status" >&5
11867 (exit $ac_status); } &&
11868 { ac_try='test -s conftest$ac_exeext'
11869 { (eval echo "$as_me:11869: \"$ac_try\"") >&5
11870 (eval $ac_try) 2>&5
11872 echo "$as_me:11872: \$? = $ac_status" >&5
11873 (exit $ac_status); }; }; then
11874 cf_cv_lib_XCurses=yes
11876 echo "$as_me: failed program was:" >&5
11877 cat conftest.$ac_ext >&5
11878 cf_cv_lib_XCurses=no
11880 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11883 echo "$as_me:11883: result: $cf_cv_lib_XCurses" >&5
11884 echo "${ECHO_T}$cf_cv_lib_XCurses" >&6
11888 if test $cf_cv_lib_XCurses = yes ; then
11890 cat >>confdefs.h <<\EOF
11894 cat >>confdefs.h <<\EOF
11898 echo "$as_me:11898: checking for xcurses.h" >&5
11899 echo $ECHO_N "checking for xcurses.h... $ECHO_C" >&6
11900 if test "${ac_cv_header_xcurses_h+set}" = set; then
11901 echo $ECHO_N "(cached) $ECHO_C" >&6
11903 cat >conftest.$ac_ext <<_ACEOF
11904 #line 11904 "configure"
11905 #include "confdefs.h"
11906 #include <xcurses.h>
11908 if { (eval echo "$as_me:11908: \"$ac_cpp conftest.$ac_ext\"") >&5
11909 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11911 egrep -v '^ *\+' conftest.er1 >conftest.err
11913 cat conftest.err >&5
11914 echo "$as_me:11914: \$? = $ac_status" >&5
11915 (exit $ac_status); } >/dev/null; then
11916 if test -s conftest.err; then
11917 ac_cpp_err=$ac_c_preproc_warn_flag
11924 if test -z "$ac_cpp_err"; then
11925 ac_cv_header_xcurses_h=yes
11927 echo "$as_me: failed program was:" >&5
11928 cat conftest.$ac_ext >&5
11929 ac_cv_header_xcurses_h=no
11931 rm -f conftest.err conftest.$ac_ext
11933 echo "$as_me:11933: result: $ac_cv_header_xcurses_h" >&5
11934 echo "${ECHO_T}$ac_cv_header_xcurses_h" >&6
11935 if test $ac_cv_header_xcurses_h = yes; then
11937 cat >>confdefs.h <<\EOF
11938 #define HAVE_XCURSES 1
11944 { { echo "$as_me:11944: error: Cannot link with XCurses" >&5
11945 echo "$as_me: error: Cannot link with XCurses" >&2;}
11946 { (exit 1); exit 1; }; }
11952 case $cf_cv_screen in
11955 echo "$as_me:11955: checking for NetBSD form.h" >&5
11956 echo $ECHO_N "checking for NetBSD form.h... $ECHO_C" >&6
11957 if test "${cf_cv_netbsd_form_h+set}" = set; then
11958 echo $ECHO_N "(cached) $ECHO_C" >&6
11961 cat >conftest.$ac_ext <<_ACEOF
11962 #line 11962 "configure"
11963 #include "confdefs.h"
11965 #include <${cf_cv_ncurses_header:-curses.h}>
11973 int y = current_field(form)->cursor_ypos;
11974 int x = current_field(form)->cursor_xpos;
11980 rm -f conftest.$ac_objext
11981 if { (eval echo "$as_me:11981: \"$ac_compile\"") >&5
11982 (eval $ac_compile) 2>&5
11984 echo "$as_me:11984: \$? = $ac_status" >&5
11985 (exit $ac_status); } &&
11986 { ac_try='test -s conftest.$ac_objext'
11987 { (eval echo "$as_me:11987: \"$ac_try\"") >&5
11988 (eval $ac_try) 2>&5
11990 echo "$as_me:11990: \$? = $ac_status" >&5
11991 (exit $ac_status); }; }; then
11992 cf_cv_netbsd_form_h=yes
11995 echo "$as_me: failed program was:" >&5
11996 cat conftest.$ac_ext >&5
11997 cf_cv_netbsd_form_h=no
11999 rm -f conftest.$ac_objext conftest.$ac_ext
12002 echo "$as_me:12002: result: $cf_cv_netbsd_form_h" >&5
12003 echo "${ECHO_T}$cf_cv_netbsd_form_h" >&6
12005 test "$cf_cv_netbsd_form_h" = yes &&
12006 cat >>confdefs.h <<\EOF
12007 #define HAVE_NETBSD_FORM_H 1
12010 echo "$as_me:12010: checking for NetBSD menu.h" >&5
12011 echo $ECHO_N "checking for NetBSD menu.h... $ECHO_C" >&6
12012 if test "${cf_cv_netbsd_menu_h+set}" = set; then
12013 echo $ECHO_N "(cached) $ECHO_C" >&6
12016 cat >conftest.$ac_ext <<_ACEOF
12017 #line 12017 "configure"
12018 #include "confdefs.h"
12020 #include <${cf_cv_ncurses_header:-curses.h}>
12028 int y = menu->max_item_width;
12034 rm -f conftest.$ac_objext
12035 if { (eval echo "$as_me:12035: \"$ac_compile\"") >&5
12036 (eval $ac_compile) 2>&5
12038 echo "$as_me:12038: \$? = $ac_status" >&5
12039 (exit $ac_status); } &&
12040 { ac_try='test -s conftest.$ac_objext'
12041 { (eval echo "$as_me:12041: \"$ac_try\"") >&5
12042 (eval $ac_try) 2>&5
12044 echo "$as_me:12044: \$? = $ac_status" >&5
12045 (exit $ac_status); }; }; then
12046 cf_cv_netbsd_menu_h=yes
12049 echo "$as_me: failed program was:" >&5
12050 cat conftest.$ac_ext >&5
12051 cf_cv_netbsd_menu_h=no
12053 rm -f conftest.$ac_objext conftest.$ac_ext
12056 echo "$as_me:12056: result: $cf_cv_netbsd_menu_h" >&5
12057 echo "${ECHO_T}$cf_cv_netbsd_menu_h" >&6
12059 test "$cf_cv_netbsd_menu_h" = yes &&
12060 cat >>confdefs.h <<\EOF
12061 #define HAVE_NETBSD_MENU_H 1
12070 case $cf_cv_screen in #(vi
12074 # look for curses-related libraries
12075 : ${cf_panel_lib:=panel}
12076 : ${cf_menu_lib:=menu}
12077 : ${cf_form_lib:=form}
12079 as_ac_Lib=`echo "ac_cv_lib_$cf_panel_lib$cf_cv_libtype''_new_panel" | $as_tr_sh`
12080 echo "$as_me:12080: checking for new_panel in -l$cf_panel_lib$cf_cv_libtype" >&5
12081 echo $ECHO_N "checking for new_panel in -l$cf_panel_lib$cf_cv_libtype... $ECHO_C" >&6
12082 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
12083 echo $ECHO_N "(cached) $ECHO_C" >&6
12085 ac_check_lib_save_LIBS=$LIBS
12086 LIBS="-l$cf_panel_lib$cf_cv_libtype $LIBS"
12087 cat >conftest.$ac_ext <<_ACEOF
12088 #line 12088 "configure"
12089 #include "confdefs.h"
12091 /* Override any gcc2 internal prototype to avoid an error. */
12095 /* We use char because int might match the return type of a gcc2
12096 builtin and then its argument prototype would still apply. */
12106 rm -f conftest.$ac_objext conftest$ac_exeext
12107 if { (eval echo "$as_me:12107: \"$ac_link\"") >&5
12108 (eval $ac_link) 2>&5
12110 echo "$as_me:12110: \$? = $ac_status" >&5
12111 (exit $ac_status); } &&
12112 { ac_try='test -s conftest$ac_exeext'
12113 { (eval echo "$as_me:12113: \"$ac_try\"") >&5
12114 (eval $ac_try) 2>&5
12116 echo "$as_me:12116: \$? = $ac_status" >&5
12117 (exit $ac_status); }; }; then
12118 eval "$as_ac_Lib=yes"
12120 echo "$as_me: failed program was:" >&5
12121 cat conftest.$ac_ext >&5
12122 eval "$as_ac_Lib=no"
12124 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12125 LIBS=$ac_check_lib_save_LIBS
12127 echo "$as_me:12127: result: `eval echo '${'$as_ac_Lib'}'`" >&5
12128 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
12129 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
12130 cat >>confdefs.h <<EOF
12131 #define `echo "HAVE_LIB$cf_panel_lib$cf_cv_libtype" | $as_tr_cpp` 1
12134 LIBS="-l$cf_panel_lib$cf_cv_libtype $LIBS"
12138 as_ac_Lib=`echo "ac_cv_lib_$cf_menu_lib$cf_cv_libtype''_menu_driver" | $as_tr_sh`
12139 echo "$as_me:12139: checking for menu_driver in -l$cf_menu_lib$cf_cv_libtype" >&5
12140 echo $ECHO_N "checking for menu_driver in -l$cf_menu_lib$cf_cv_libtype... $ECHO_C" >&6
12141 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
12142 echo $ECHO_N "(cached) $ECHO_C" >&6
12144 ac_check_lib_save_LIBS=$LIBS
12145 LIBS="-l$cf_menu_lib$cf_cv_libtype $LIBS"
12146 cat >conftest.$ac_ext <<_ACEOF
12147 #line 12147 "configure"
12148 #include "confdefs.h"
12150 /* Override any gcc2 internal prototype to avoid an error. */
12154 /* We use char because int might match the return type of a gcc2
12155 builtin and then its argument prototype would still apply. */
12156 char menu_driver ();
12165 rm -f conftest.$ac_objext conftest$ac_exeext
12166 if { (eval echo "$as_me:12166: \"$ac_link\"") >&5
12167 (eval $ac_link) 2>&5
12169 echo "$as_me:12169: \$? = $ac_status" >&5
12170 (exit $ac_status); } &&
12171 { ac_try='test -s conftest$ac_exeext'
12172 { (eval echo "$as_me:12172: \"$ac_try\"") >&5
12173 (eval $ac_try) 2>&5
12175 echo "$as_me:12175: \$? = $ac_status" >&5
12176 (exit $ac_status); }; }; then
12177 eval "$as_ac_Lib=yes"
12179 echo "$as_me: failed program was:" >&5
12180 cat conftest.$ac_ext >&5
12181 eval "$as_ac_Lib=no"
12183 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12184 LIBS=$ac_check_lib_save_LIBS
12186 echo "$as_me:12186: result: `eval echo '${'$as_ac_Lib'}'`" >&5
12187 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
12188 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
12189 cat >>confdefs.h <<EOF
12190 #define `echo "HAVE_LIB$cf_menu_lib$cf_cv_libtype" | $as_tr_cpp` 1
12193 LIBS="-l$cf_menu_lib$cf_cv_libtype $LIBS"
12197 as_ac_Lib=`echo "ac_cv_lib_$cf_form_lib$cf_cv_libtype''_form_driver" | $as_tr_sh`
12198 echo "$as_me:12198: checking for form_driver in -l$cf_form_lib$cf_cv_libtype" >&5
12199 echo $ECHO_N "checking for form_driver in -l$cf_form_lib$cf_cv_libtype... $ECHO_C" >&6
12200 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
12201 echo $ECHO_N "(cached) $ECHO_C" >&6
12203 ac_check_lib_save_LIBS=$LIBS
12204 LIBS="-l$cf_form_lib$cf_cv_libtype $LIBS"
12205 cat >conftest.$ac_ext <<_ACEOF
12206 #line 12206 "configure"
12207 #include "confdefs.h"
12209 /* Override any gcc2 internal prototype to avoid an error. */
12213 /* We use char because int might match the return type of a gcc2
12214 builtin and then its argument prototype would still apply. */
12215 char form_driver ();
12224 rm -f conftest.$ac_objext conftest$ac_exeext
12225 if { (eval echo "$as_me:12225: \"$ac_link\"") >&5
12226 (eval $ac_link) 2>&5
12228 echo "$as_me:12228: \$? = $ac_status" >&5
12229 (exit $ac_status); } &&
12230 { ac_try='test -s conftest$ac_exeext'
12231 { (eval echo "$as_me:12231: \"$ac_try\"") >&5
12232 (eval $ac_try) 2>&5
12234 echo "$as_me:12234: \$? = $ac_status" >&5
12235 (exit $ac_status); }; }; then
12236 eval "$as_ac_Lib=yes"
12238 echo "$as_me: failed program was:" >&5
12239 cat conftest.$ac_ext >&5
12240 eval "$as_ac_Lib=no"
12242 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12243 LIBS=$ac_check_lib_save_LIBS
12245 echo "$as_me:12245: result: `eval echo '${'$as_ac_Lib'}'`" >&5
12246 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
12247 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
12248 cat >>confdefs.h <<EOF
12249 #define `echo "HAVE_LIB$cf_form_lib$cf_cv_libtype" | $as_tr_cpp` 1
12252 LIBS="-l$cf_form_lib$cf_cv_libtype $LIBS"
12256 # look for curses-related headers
12267 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12268 echo "$as_me:12268: checking for $ac_header" >&5
12269 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12270 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12271 echo $ECHO_N "(cached) $ECHO_C" >&6
12273 cat >conftest.$ac_ext <<_ACEOF
12274 #line 12274 "configure"
12275 #include "confdefs.h"
12276 #include <$ac_header>
12278 if { (eval echo "$as_me:12278: \"$ac_cpp conftest.$ac_ext\"") >&5
12279 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12281 egrep -v '^ *\+' conftest.er1 >conftest.err
12283 cat conftest.err >&5
12284 echo "$as_me:12284: \$? = $ac_status" >&5
12285 (exit $ac_status); } >/dev/null; then
12286 if test -s conftest.err; then
12287 ac_cpp_err=$ac_c_preproc_warn_flag
12294 if test -z "$ac_cpp_err"; then
12295 eval "$as_ac_Header=yes"
12297 echo "$as_me: failed program was:" >&5
12298 cat conftest.$ac_ext >&5
12299 eval "$as_ac_Header=no"
12301 rm -f conftest.err conftest.$ac_ext
12303 echo "$as_me:12303: result: `eval echo '${'$as_ac_Header'}'`" >&5
12304 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12305 if test `eval echo '${'$as_ac_Header'}'` = yes; then
12306 cat >>confdefs.h <<EOF
12307 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12316 echo "$as_me:12316: checking for ANSI C header files" >&5
12317 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
12318 if test "${ac_cv_header_stdc+set}" = set; then
12319 echo $ECHO_N "(cached) $ECHO_C" >&6
12321 cat >conftest.$ac_ext <<_ACEOF
12322 #line 12322 "configure"
12323 #include "confdefs.h"
12324 #include <stdlib.h>
12325 #include <stdarg.h>
12326 #include <string.h>
12330 if { (eval echo "$as_me:12330: \"$ac_cpp conftest.$ac_ext\"") >&5
12331 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12333 egrep -v '^ *\+' conftest.er1 >conftest.err
12335 cat conftest.err >&5
12336 echo "$as_me:12336: \$? = $ac_status" >&5
12337 (exit $ac_status); } >/dev/null; then
12338 if test -s conftest.err; then
12339 ac_cpp_err=$ac_c_preproc_warn_flag
12346 if test -z "$ac_cpp_err"; then
12347 ac_cv_header_stdc=yes
12349 echo "$as_me: failed program was:" >&5
12350 cat conftest.$ac_ext >&5
12351 ac_cv_header_stdc=no
12353 rm -f conftest.err conftest.$ac_ext
12355 if test $ac_cv_header_stdc = yes; then
12356 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
12357 cat >conftest.$ac_ext <<_ACEOF
12358 #line 12358 "configure"
12359 #include "confdefs.h"
12360 #include <string.h>
12363 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12364 egrep "memchr" >/dev/null 2>&1; then
12367 ac_cv_header_stdc=no
12373 if test $ac_cv_header_stdc = yes; then
12374 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
12375 cat >conftest.$ac_ext <<_ACEOF
12376 #line 12376 "configure"
12377 #include "confdefs.h"
12378 #include <stdlib.h>
12381 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12382 egrep "free" >/dev/null 2>&1; then
12385 ac_cv_header_stdc=no
12391 if test $ac_cv_header_stdc = yes; then
12392 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
12393 if test "$cross_compiling" = yes; then
12396 cat >conftest.$ac_ext <<_ACEOF
12397 #line 12397 "configure"
12398 #include "confdefs.h"
12400 #if ((' ' & 0x0FF) == 0x020)
12401 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
12402 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
12404 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
12405 || ('j' <= (c) && (c) <= 'r') \
12406 || ('s' <= (c) && (c) <= 'z'))
12407 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
12410 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
12415 for (i = 0; i < 256; i++)
12416 if (XOR (islower (i), ISLOWER (i))
12417 || toupper (i) != TOUPPER (i))
12418 $ac_main_return(2);
12419 $ac_main_return (0);
12422 rm -f conftest$ac_exeext
12423 if { (eval echo "$as_me:12423: \"$ac_link\"") >&5
12424 (eval $ac_link) 2>&5
12426 echo "$as_me:12426: \$? = $ac_status" >&5
12427 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
12428 { (eval echo "$as_me:12428: \"$ac_try\"") >&5
12429 (eval $ac_try) 2>&5
12431 echo "$as_me:12431: \$? = $ac_status" >&5
12432 (exit $ac_status); }; }; then
12435 echo "$as_me: program exited with status $ac_status" >&5
12436 echo "$as_me: failed program was:" >&5
12437 cat conftest.$ac_ext >&5
12438 ac_cv_header_stdc=no
12440 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
12444 echo "$as_me:12444: result: $ac_cv_header_stdc" >&5
12445 echo "${ECHO_T}$ac_cv_header_stdc" >&6
12446 if test $ac_cv_header_stdc = yes; then
12448 cat >>confdefs.h <<\EOF
12449 #define STDC_HEADERS 1
12454 echo "$as_me:12454: checking whether time.h and sys/time.h may both be included" >&5
12455 echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
12456 if test "${ac_cv_header_time+set}" = set; then
12457 echo $ECHO_N "(cached) $ECHO_C" >&6
12459 cat >conftest.$ac_ext <<_ACEOF
12460 #line 12460 "configure"
12461 #include "confdefs.h"
12462 #include <sys/types.h>
12463 #include <sys/time.h>
12469 if ((struct tm *) 0)
12475 rm -f conftest.$ac_objext
12476 if { (eval echo "$as_me:12476: \"$ac_compile\"") >&5
12477 (eval $ac_compile) 2>&5
12479 echo "$as_me:12479: \$? = $ac_status" >&5
12480 (exit $ac_status); } &&
12481 { ac_try='test -s conftest.$ac_objext'
12482 { (eval echo "$as_me:12482: \"$ac_try\"") >&5
12483 (eval $ac_try) 2>&5
12485 echo "$as_me:12485: \$? = $ac_status" >&5
12486 (exit $ac_status); }; }; then
12487 ac_cv_header_time=yes
12489 echo "$as_me: failed program was:" >&5
12490 cat conftest.$ac_ext >&5
12491 ac_cv_header_time=no
12493 rm -f conftest.$ac_objext conftest.$ac_ext
12495 echo "$as_me:12495: result: $ac_cv_header_time" >&5
12496 echo "${ECHO_T}$ac_cv_header_time" >&6
12497 if test $ac_cv_header_time = yes; then
12499 cat >>confdefs.h <<\EOF
12500 #define TIME_WITH_SYS_TIME 1
12517 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12518 echo "$as_me:12518: checking for $ac_header" >&5
12519 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12520 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12521 echo $ECHO_N "(cached) $ECHO_C" >&6
12523 cat >conftest.$ac_ext <<_ACEOF
12524 #line 12524 "configure"
12525 #include "confdefs.h"
12526 #include <$ac_header>
12528 if { (eval echo "$as_me:12528: \"$ac_cpp conftest.$ac_ext\"") >&5
12529 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12531 egrep -v '^ *\+' conftest.er1 >conftest.err
12533 cat conftest.err >&5
12534 echo "$as_me:12534: \$? = $ac_status" >&5
12535 (exit $ac_status); } >/dev/null; then
12536 if test -s conftest.err; then
12537 ac_cpp_err=$ac_c_preproc_warn_flag
12544 if test -z "$ac_cpp_err"; then
12545 eval "$as_ac_Header=yes"
12547 echo "$as_me: failed program was:" >&5
12548 cat conftest.$ac_ext >&5
12549 eval "$as_ac_Header=no"
12551 rm -f conftest.err conftest.$ac_ext
12553 echo "$as_me:12553: result: `eval echo '${'$as_ac_Header'}'`" >&5
12554 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12555 if test `eval echo '${'$as_ac_Header'}'` = yes; then
12556 cat >>confdefs.h <<EOF
12557 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12563 for ac_header in unistd.h getopt.h
12565 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12566 echo "$as_me:12566: checking for $ac_header" >&5
12567 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12568 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12569 echo $ECHO_N "(cached) $ECHO_C" >&6
12571 cat >conftest.$ac_ext <<_ACEOF
12572 #line 12572 "configure"
12573 #include "confdefs.h"
12574 #include <$ac_header>
12576 if { (eval echo "$as_me:12576: \"$ac_cpp conftest.$ac_ext\"") >&5
12577 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12579 egrep -v '^ *\+' conftest.er1 >conftest.err
12581 cat conftest.err >&5
12582 echo "$as_me:12582: \$? = $ac_status" >&5
12583 (exit $ac_status); } >/dev/null; then
12584 if test -s conftest.err; then
12585 ac_cpp_err=$ac_c_preproc_warn_flag
12592 if test -z "$ac_cpp_err"; then
12593 eval "$as_ac_Header=yes"
12595 echo "$as_me: failed program was:" >&5
12596 cat conftest.$ac_ext >&5
12597 eval "$as_ac_Header=no"
12599 rm -f conftest.err conftest.$ac_ext
12601 echo "$as_me:12601: result: `eval echo '${'$as_ac_Header'}'`" >&5
12602 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12603 if test `eval echo '${'$as_ac_Header'}'` = yes; then
12604 cat >>confdefs.h <<EOF
12605 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12611 echo "$as_me:12611: checking for header declaring getopt variables" >&5
12612 echo $ECHO_N "checking for header declaring getopt variables... $ECHO_C" >&6
12613 if test "${cf_cv_getopt_header+set}" = set; then
12614 echo $ECHO_N "(cached) $ECHO_C" >&6
12617 cf_cv_getopt_header=none
12618 for cf_header in stdio.h stdlib.h unistd.h getopt.h
12620 cat >conftest.$ac_ext <<_ACEOF
12621 #line 12621 "configure"
12622 #include "confdefs.h"
12624 #include <$cf_header>
12628 int x = optind; char *y = optarg
12633 rm -f conftest.$ac_objext
12634 if { (eval echo "$as_me:12634: \"$ac_compile\"") >&5
12635 (eval $ac_compile) 2>&5
12637 echo "$as_me:12637: \$? = $ac_status" >&5
12638 (exit $ac_status); } &&
12639 { ac_try='test -s conftest.$ac_objext'
12640 { (eval echo "$as_me:12640: \"$ac_try\"") >&5
12641 (eval $ac_try) 2>&5
12643 echo "$as_me:12643: \$? = $ac_status" >&5
12644 (exit $ac_status); }; }; then
12645 cf_cv_getopt_header=$cf_header
12648 echo "$as_me: failed program was:" >&5
12649 cat conftest.$ac_ext >&5
12651 rm -f conftest.$ac_objext conftest.$ac_ext
12655 echo "$as_me:12655: result: $cf_cv_getopt_header" >&5
12656 echo "${ECHO_T}$cf_cv_getopt_header" >&6
12657 if test $cf_cv_getopt_header != none ; then
12659 cat >>confdefs.h <<\EOF
12660 #define HAVE_GETOPT_HEADER 1
12669 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12670 echo "$as_me:12670: checking for $ac_func" >&5
12671 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12672 if eval "test \"\${$as_ac_var+set}\" = set"; then
12673 echo $ECHO_N "(cached) $ECHO_C" >&6
12675 cat >conftest.$ac_ext <<_ACEOF
12676 #line 12676 "configure"
12677 #include "confdefs.h"
12678 /* System header to define __stub macros and hopefully few prototypes,
12679 which can conflict with char $ac_func (); below. */
12680 #include <assert.h>
12681 /* Override any gcc2 internal prototype to avoid an error. */
12685 /* We use char because int might match the return type of a gcc2
12686 builtin and then its argument prototype would still apply. */
12693 /* The GNU C library defines this for functions which it implements
12694 to always fail with ENOSYS. Some functions are actually named
12695 something starting with __ and the normal name is an alias. */
12696 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12699 f = $ac_func; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
12706 rm -f conftest.$ac_objext conftest$ac_exeext
12707 if { (eval echo "$as_me:12707: \"$ac_link\"") >&5
12708 (eval $ac_link) 2>&5
12710 echo "$as_me:12710: \$? = $ac_status" >&5
12711 (exit $ac_status); } &&
12712 { ac_try='test -s conftest$ac_exeext'
12713 { (eval echo "$as_me:12713: \"$ac_try\"") >&5
12714 (eval $ac_try) 2>&5
12716 echo "$as_me:12716: \$? = $ac_status" >&5
12717 (exit $ac_status); }; }; then
12718 eval "$as_ac_var=yes"
12720 echo "$as_me: failed program was:" >&5
12721 cat conftest.$ac_ext >&5
12722 eval "$as_ac_var=no"
12724 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12726 echo "$as_me:12726: result: `eval echo '${'$as_ac_var'}'`" >&5
12727 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12728 if test `eval echo '${'$as_ac_var'}'` = yes; then
12729 cat >>confdefs.h <<EOF
12730 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12736 if test "$cf_enable_widec" = yes; then
12749 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12750 echo "$as_me:12750: checking for $ac_func" >&5
12751 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12752 if eval "test \"\${$as_ac_var+set}\" = set"; then
12753 echo $ECHO_N "(cached) $ECHO_C" >&6
12755 cat >conftest.$ac_ext <<_ACEOF
12756 #line 12756 "configure"
12757 #include "confdefs.h"
12758 /* System header to define __stub macros and hopefully few prototypes,
12759 which can conflict with char $ac_func (); below. */
12760 #include <assert.h>
12761 /* Override any gcc2 internal prototype to avoid an error. */
12765 /* We use char because int might match the return type of a gcc2
12766 builtin and then its argument prototype would still apply. */
12773 /* The GNU C library defines this for functions which it implements
12774 to always fail with ENOSYS. Some functions are actually named
12775 something starting with __ and the normal name is an alias. */
12776 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12779 f = $ac_func; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
12786 rm -f conftest.$ac_objext conftest$ac_exeext
12787 if { (eval echo "$as_me:12787: \"$ac_link\"") >&5
12788 (eval $ac_link) 2>&5
12790 echo "$as_me:12790: \$? = $ac_status" >&5
12791 (exit $ac_status); } &&
12792 { ac_try='test -s conftest$ac_exeext'
12793 { (eval echo "$as_me:12793: \"$ac_try\"") >&5
12794 (eval $ac_try) 2>&5
12796 echo "$as_me:12796: \$? = $ac_status" >&5
12797 (exit $ac_status); }; }; then
12798 eval "$as_ac_var=yes"
12800 echo "$as_me: failed program was:" >&5
12801 cat conftest.$ac_ext >&5
12802 eval "$as_ac_var=no"
12804 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12806 echo "$as_me:12806: result: `eval echo '${'$as_ac_var'}'`" >&5
12807 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12808 if test `eval echo '${'$as_ac_var'}'` = yes; then
12809 cat >>confdefs.h <<EOF
12810 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12818 echo "$as_me:12818: checking if we must define _XOPEN_SOURCE_EXTENDED" >&5
12819 echo $ECHO_N "checking if we must define _XOPEN_SOURCE_EXTENDED... $ECHO_C" >&6
12820 if test "${cf_cv_need_xopen_extension+set}" = set; then
12821 echo $ECHO_N "(cached) $ECHO_C" >&6
12824 cat >conftest.$ac_ext <<_ACEOF
12825 #line 12825 "configure"
12826 #include "confdefs.h"
12828 #include <stdlib.h>
12829 #include <${cf_cv_ncurses_header:-curses.h}>
12834 #if defined(NCURSES_VERSION_PATCH)
12835 #if (NCURSES_VERSION_PATCH < 20100501) && (NCURSES_VERSION_PATCH >= 20100403)
12839 long x = winnstr(stdscr, "", 0);
12841 getbegyx(stdscr, y1, x1)
12846 rm -f conftest.$ac_objext conftest$ac_exeext
12847 if { (eval echo "$as_me:12847: \"$ac_link\"") >&5
12848 (eval $ac_link) 2>&5
12850 echo "$as_me:12850: \$? = $ac_status" >&5
12851 (exit $ac_status); } &&
12852 { ac_try='test -s conftest$ac_exeext'
12853 { (eval echo "$as_me:12853: \"$ac_try\"") >&5
12854 (eval $ac_try) 2>&5
12856 echo "$as_me:12856: \$? = $ac_status" >&5
12857 (exit $ac_status); }; }; then
12858 cf_cv_need_xopen_extension=no
12860 echo "$as_me: failed program was:" >&5
12861 cat conftest.$ac_ext >&5
12862 cat >conftest.$ac_ext <<_ACEOF
12863 #line 12863 "configure"
12864 #include "confdefs.h"
12866 #define _XOPEN_SOURCE_EXTENDED
12867 #include <stdlib.h>
12868 #include <${cf_cv_ncurses_header:-curses.h}>
12873 #ifdef NCURSES_VERSION
12875 int check2 = curs_set((int)sizeof(check));
12877 long x = winnstr(stdscr, "", 0);
12879 getbegyx(stdscr, y1, x1)
12884 rm -f conftest.$ac_objext conftest$ac_exeext
12885 if { (eval echo "$as_me:12885: \"$ac_link\"") >&5
12886 (eval $ac_link) 2>&5
12888 echo "$as_me:12888: \$? = $ac_status" >&5
12889 (exit $ac_status); } &&
12890 { ac_try='test -s conftest$ac_exeext'
12891 { (eval echo "$as_me:12891: \"$ac_try\"") >&5
12892 (eval $ac_try) 2>&5
12894 echo "$as_me:12894: \$? = $ac_status" >&5
12895 (exit $ac_status); }; }; then
12896 cf_cv_need_xopen_extension=yes
12898 echo "$as_me: failed program was:" >&5
12899 cat conftest.$ac_ext >&5
12900 cf_cv_need_xopen_extension=unknown
12902 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12904 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12906 echo "$as_me:12906: result: $cf_cv_need_xopen_extension" >&5
12907 echo "${ECHO_T}$cf_cv_need_xopen_extension" >&6
12908 test $cf_cv_need_xopen_extension = yes && CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE_EXTENDED"
12910 echo "$as_me:12910: checking for term.h" >&5
12911 echo $ECHO_N "checking for term.h... $ECHO_C" >&6
12912 if test "${cf_cv_term_header+set}" = set; then
12913 echo $ECHO_N "(cached) $ECHO_C" >&6
12916 # If we found <ncurses/curses.h>, look for <ncurses/term.h>, but always look
12917 # for <term.h> if we do not find the variant.
12919 cf_header_list="term.h ncurses/term.h ncursesw/term.h"
12921 case ${cf_cv_ncurses_header:-curses.h} in #(vi
12923 cf_header_item=`echo ${cf_cv_ncurses_header:-curses.h} | sed -e 's%\..*%%' -e 's%/.*%/%'`term.h
12924 cf_header_list="$cf_header_item $cf_header_list"
12928 for cf_header in $cf_header_list
12930 cat >conftest.$ac_ext <<_ACEOF
12931 #line 12931 "configure"
12932 #include "confdefs.h"
12934 #include <${cf_cv_ncurses_header:-curses.h}>
12935 #include <${cf_header}>
12944 rm -f conftest.$ac_objext
12945 if { (eval echo "$as_me:12945: \"$ac_compile\"") >&5
12946 (eval $ac_compile) 2>&5
12948 echo "$as_me:12948: \$? = $ac_status" >&5
12949 (exit $ac_status); } &&
12950 { ac_try='test -s conftest.$ac_objext'
12951 { (eval echo "$as_me:12951: \"$ac_try\"") >&5
12952 (eval $ac_try) 2>&5
12954 echo "$as_me:12954: \$? = $ac_status" >&5
12955 (exit $ac_status); }; }; then
12956 cf_cv_term_header=$cf_header
12959 echo "$as_me: failed program was:" >&5
12960 cat conftest.$ac_ext >&5
12961 cf_cv_term_header=no
12963 rm -f conftest.$ac_objext conftest.$ac_ext
12966 case $cf_cv_term_header in #(vi
12968 # If curses is ncurses, some packagers still mess it up by trying to make
12969 # us use GNU termcap. This handles the most common case.
12970 for cf_header in ncurses/term.h ncursesw/term.h
12972 cat >conftest.$ac_ext <<_ACEOF
12973 #line 12973 "configure"
12974 #include "confdefs.h"
12976 #include <${cf_cv_ncurses_header:-curses.h}>
12977 #ifdef NCURSES_VERSION
12978 #include <${cf_header}>
12990 rm -f conftest.$ac_objext
12991 if { (eval echo "$as_me:12991: \"$ac_compile\"") >&5
12992 (eval $ac_compile) 2>&5
12994 echo "$as_me:12994: \$? = $ac_status" >&5
12995 (exit $ac_status); } &&
12996 { ac_try='test -s conftest.$ac_objext'
12997 { (eval echo "$as_me:12997: \"$ac_try\"") >&5
12998 (eval $ac_try) 2>&5
13000 echo "$as_me:13000: \$? = $ac_status" >&5
13001 (exit $ac_status); }; }; then
13002 cf_cv_term_header=$cf_header
13005 echo "$as_me: failed program was:" >&5
13006 cat conftest.$ac_ext >&5
13007 cf_cv_term_header=no
13009 rm -f conftest.$ac_objext conftest.$ac_ext
13015 echo "$as_me:13015: result: $cf_cv_term_header" >&5
13016 echo "${ECHO_T}$cf_cv_term_header" >&6
13018 case $cf_cv_term_header in #(vi
13021 cat >>confdefs.h <<\EOF
13022 #define HAVE_TERM_H 1
13026 ncurses/term.h) #(vi
13028 cat >>confdefs.h <<\EOF
13029 #define HAVE_NCURSES_TERM_H 1
13035 cat >>confdefs.h <<\EOF
13036 #define HAVE_NCURSESW_TERM_H 1
13042 echo "$as_me:13042: checking for unctrl.h" >&5
13043 echo $ECHO_N "checking for unctrl.h... $ECHO_C" >&6
13044 if test "${cf_cv_unctrl_header+set}" = set; then
13045 echo $ECHO_N "(cached) $ECHO_C" >&6
13048 # If we found <ncurses/curses.h>, look for <ncurses/unctrl.h>, but always look
13049 # for <unctrl.h> if we do not find the variant.
13051 cf_header_list="unctrl.h ncurses/unctrl.h ncursesw/unctrl.h"
13053 case ${cf_cv_ncurses_header:-curses.h} in #(vi
13055 cf_header_item=`echo ${cf_cv_ncurses_header:-curses.h} | sed -e 's%\..*%%' -e 's%/.*%/%'`unctrl.h
13056 cf_header_list="$cf_header_item $cf_header_list"
13060 for cf_header in $cf_header_list
13062 cat >conftest.$ac_ext <<_ACEOF
13063 #line 13063 "configure"
13064 #include "confdefs.h"
13066 #include <${cf_cv_ncurses_header:-curses.h}>
13067 #include <${cf_header}>
13076 rm -f conftest.$ac_objext
13077 if { (eval echo "$as_me:13077: \"$ac_compile\"") >&5
13078 (eval $ac_compile) 2>&5
13080 echo "$as_me:13080: \$? = $ac_status" >&5
13081 (exit $ac_status); } &&
13082 { ac_try='test -s conftest.$ac_objext'
13083 { (eval echo "$as_me:13083: \"$ac_try\"") >&5
13084 (eval $ac_try) 2>&5
13086 echo "$as_me:13086: \$? = $ac_status" >&5
13087 (exit $ac_status); }; }; then
13088 cf_cv_unctrl_header=$cf_header
13091 echo "$as_me: failed program was:" >&5
13092 cat conftest.$ac_ext >&5
13093 cf_cv_unctrl_header=no
13095 rm -f conftest.$ac_objext conftest.$ac_ext
13098 case $cf_cv_unctrl_header in #(vi
13100 { echo "$as_me:13100: WARNING: unctrl.h header not found" >&5
13101 echo "$as_me: WARNING: unctrl.h header not found" >&2;}
13106 echo "$as_me:13106: result: $cf_cv_unctrl_header" >&5
13107 echo "${ECHO_T}$cf_cv_unctrl_header" >&6
13109 case $cf_cv_unctrl_header in #(vi
13112 cat >>confdefs.h <<\EOF
13113 #define HAVE_UNCTRL_H 1
13117 ncurses/unctrl.h) #(vi
13119 cat >>confdefs.h <<\EOF
13120 #define HAVE_NCURSES_UNCTRL_H 1
13126 cat >>confdefs.h <<\EOF
13127 #define HAVE_NCURSESW_UNCTRL_H 1
13134 assume_default_colors \
13160 use_default_colors \
13172 cf_tr_func=`echo "$cf_func" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
13174 echo "$as_me:13174: checking for ${cf_func}" >&5
13175 echo $ECHO_N "checking for ${cf_func}... $ECHO_C" >&6
13177 echo "${as_me:-configure}:13177: testing ${cf_func} ..." 1>&5
13179 if eval "test \"\${cf_cv_func_$cf_func+set}\" = set"; then
13180 echo $ECHO_N "(cached) $ECHO_C" >&6
13183 eval cf_result='$ac_cv_func_'$cf_func
13184 if test ".$cf_result" != ".no"; then
13185 cat >conftest.$ac_ext <<_ACEOF
13186 #line 13186 "configure"
13187 #include "confdefs.h"
13189 #ifdef HAVE_XCURSES
13190 #include <xcurses.h>
13191 char * XCursesProgramName = "test";
13193 #include <${cf_cv_ncurses_header:-curses.h}>
13194 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
13195 #include <ncursesw/term.h>
13196 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
13197 #include <ncurses/term.h>
13198 #elif defined(HAVE_TERM_H)
13208 long foo = (long)(&${cf_func});
13209 if (foo + 1234 > 5678)
13210 ${cf_cv_main_return:-return}(foo);
13217 rm -f conftest.$ac_objext conftest$ac_exeext
13218 if { (eval echo "$as_me:13218: \"$ac_link\"") >&5
13219 (eval $ac_link) 2>&5
13221 echo "$as_me:13221: \$? = $ac_status" >&5
13222 (exit $ac_status); } &&
13223 { ac_try='test -s conftest$ac_exeext'
13224 { (eval echo "$as_me:13224: \"$ac_try\"") >&5
13225 (eval $ac_try) 2>&5
13227 echo "$as_me:13227: \$? = $ac_status" >&5
13228 (exit $ac_status); }; }; then
13231 echo "$as_me: failed program was:" >&5
13232 cat conftest.$ac_ext >&5
13235 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13237 eval 'cf_cv_func_'$cf_func'=$cf_result'
13241 # use the computed/retrieved cache-value:
13242 eval 'cf_result=$cf_cv_func_'$cf_func
13243 echo "$as_me:13243: result: $cf_result" >&5
13244 echo "${ECHO_T}$cf_result" >&6
13245 if test $cf_result != no; then
13246 cat >>confdefs.h <<EOF
13247 #define HAVE_${cf_tr_func} 1
13253 for cf_func in tputs
13256 cf_tr_func=`echo "$cf_func" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
13258 echo "$as_me:13258: checking for ${cf_func}" >&5
13259 echo $ECHO_N "checking for ${cf_func}... $ECHO_C" >&6
13261 echo "${as_me:-configure}:13261: testing ${cf_func} ..." 1>&5
13263 if eval "test \"\${cf_cv_func_$cf_func+set}\" = set"; then
13264 echo $ECHO_N "(cached) $ECHO_C" >&6
13267 eval cf_result='$ac_cv_func_'$cf_func
13268 if test ".$cf_result" != ".no"; then
13269 cat >conftest.$ac_ext <<_ACEOF
13270 #line 13270 "configure"
13271 #include "confdefs.h"
13273 #ifdef HAVE_XCURSES
13274 #include <xcurses.h>
13275 char * XCursesProgramName = "test";
13277 #include <${cf_cv_ncurses_header:-curses.h}>
13278 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
13279 #include <ncursesw/term.h>
13280 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
13281 #include <ncurses/term.h>
13282 #elif defined(HAVE_TERM_H)
13292 long foo = (long)(&${cf_func});
13293 if (foo + 1234 > 5678)
13294 ${cf_cv_main_return:-return}(foo);
13301 rm -f conftest.$ac_objext conftest$ac_exeext
13302 if { (eval echo "$as_me:13302: \"$ac_link\"") >&5
13303 (eval $ac_link) 2>&5
13305 echo "$as_me:13305: \$? = $ac_status" >&5
13306 (exit $ac_status); } &&
13307 { ac_try='test -s conftest$ac_exeext'
13308 { (eval echo "$as_me:13308: \"$ac_try\"") >&5
13309 (eval $ac_try) 2>&5
13311 echo "$as_me:13311: \$? = $ac_status" >&5
13312 (exit $ac_status); }; }; then
13315 echo "$as_me: failed program was:" >&5
13316 cat conftest.$ac_ext >&5
13319 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13321 eval 'cf_cv_func_'$cf_func'=$cf_result'
13325 # use the computed/retrieved cache-value:
13326 eval 'cf_result=$cf_cv_func_'$cf_func
13327 echo "$as_me:13327: result: $cf_result" >&5
13328 echo "${ECHO_T}$cf_result" >&6
13329 if test $cf_result != no; then
13330 cat >>confdefs.h <<EOF
13331 #define HAVE_${cf_tr_func} 1
13337 if test x$cf_cv_func_tputs = xyes
13340 for cf_arg in int char
13342 for cf_ret in int void
13344 if test $cf_ret = void
13346 cf_return="/* nothing */"
13348 cf_return="return value"
13350 cat >conftest.$ac_ext <<_ACEOF
13351 #line 13351 "configure"
13352 #include "confdefs.h"
13354 #include <${cf_cv_ncurses_header:-curses.h}>
13355 #include <$cf_cv_term_header>
13357 static $cf_ret outc($cf_arg value) { $cf_return; }
13363 tputs("hello", 0, outc);
13364 ${cf_cv_main_return:-return}(0);
13370 rm -f conftest.$ac_objext
13371 if { (eval echo "$as_me:13371: \"$ac_compile\"") >&5
13372 (eval $ac_compile) 2>&5
13374 echo "$as_me:13374: \$? = $ac_status" >&5
13375 (exit $ac_status); } &&
13376 { ac_try='test -s conftest.$ac_objext'
13377 { (eval echo "$as_me:13377: \"$ac_try\"") >&5
13378 (eval $ac_try) 2>&5
13380 echo "$as_me:13380: \$? = $ac_status" >&5
13381 (exit $ac_status); }; }; then
13383 test -n "$verbose" && echo " prototype $cf_ret func($cf_arg value)" 1>&6
13385 echo "${as_me:-configure}:13385: testing prototype $cf_ret func($cf_arg value) ..." 1>&5
13387 cat >>confdefs.h <<EOF
13388 #define TPUTS_ARG $cf_arg
13389 #define TPUTS_PROTO(func,value) $cf_ret func(TPUTS_ARG value)
13390 #define TPUTS_RETURN(value) $cf_return
13396 echo "$as_me: failed program was:" >&5
13397 cat conftest.$ac_ext >&5
13399 rm -f conftest.$ac_objext conftest.$ac_ext
13401 test $cf_done = yes && break
13405 echo "$as_me:13405: checking for ncurses extended functions" >&5
13406 echo $ECHO_N "checking for ncurses extended functions... $ECHO_C" >&6
13407 if test "${cf_cv_ncurses_ext_funcs+set}" = set; then
13408 echo $ECHO_N "(cached) $ECHO_C" >&6
13411 cat >conftest.$ac_ext <<_ACEOF
13412 #line 13412 "configure"
13413 #include "confdefs.h"
13415 #include <${cf_cv_ncurses_header:-curses.h}>
13420 int x = NCURSES_EXT_FUNCS
13426 rm -f conftest.$ac_objext
13427 if { (eval echo "$as_me:13427: \"$ac_compile\"") >&5
13428 (eval $ac_compile) 2>&5
13430 echo "$as_me:13430: \$? = $ac_status" >&5
13431 (exit $ac_status); } &&
13432 { ac_try='test -s conftest.$ac_objext'
13433 { (eval echo "$as_me:13433: \"$ac_try\"") >&5
13434 (eval $ac_try) 2>&5
13436 echo "$as_me:13436: \$? = $ac_status" >&5
13437 (exit $ac_status); }; }; then
13438 cf_cv_ncurses_ext_funcs=defined
13440 echo "$as_me: failed program was:" >&5
13441 cat conftest.$ac_ext >&5
13443 cat >conftest.$ac_ext <<_ACEOF
13444 #line 13444 "configure"
13445 #include "confdefs.h"
13447 #include <${cf_cv_ncurses_header:-curses.h}>
13452 (void) assume_default_colors (0, 0);
13453 (void) curses_version ();
13454 (void) define_key (0, 0);
13455 (void) is_term_resized (0, 0);
13456 (void) key_defined (0);
13457 (void) keybound (0, 0);
13458 (void) keyok (0, 0);
13459 (void) resize_term (0, 0);
13460 (void) resizeterm (0, 0);
13461 (void) use_default_colors ();
13462 (void) use_extended_names (0);
13463 (void) wresize (0, 0, 0);
13468 rm -f conftest.$ac_objext conftest$ac_exeext
13469 if { (eval echo "$as_me:13469: \"$ac_link\"") >&5
13470 (eval $ac_link) 2>&5
13472 echo "$as_me:13472: \$? = $ac_status" >&5
13473 (exit $ac_status); } &&
13474 { ac_try='test -s conftest$ac_exeext'
13475 { (eval echo "$as_me:13475: \"$ac_try\"") >&5
13476 (eval $ac_try) 2>&5
13478 echo "$as_me:13478: \$? = $ac_status" >&5
13479 (exit $ac_status); }; }; then
13480 cf_cv_ncurses_ext_funcs=yes
13482 echo "$as_me: failed program was:" >&5
13483 cat conftest.$ac_ext >&5
13484 cf_cv_ncurses_ext_funcs=no
13486 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13489 rm -f conftest.$ac_objext conftest.$ac_ext
13492 echo "$as_me:13492: result: $cf_cv_ncurses_ext_funcs" >&5
13493 echo "${ECHO_T}$cf_cv_ncurses_ext_funcs" >&6
13494 test "$cf_cv_ncurses_ext_funcs" = yes &&
13495 cat >>confdefs.h <<\EOF
13496 #define NCURSES_EXT_FUNCS 1
13499 if test "$cf_enable_widec" = yes
13501 # workaround for systems with ncurses before 20111029, due to change of
13502 # feature test macro from _XPG5 to _XOPEN_SOURCE
13503 if test -n "$cf_cv_ncurses_version" && test "x$cf_cv_ncurses_version" != xno
13506 echo "$as_me:13506: checking if _XPG5 should be defined to enable wide-characters" >&5
13507 echo $ECHO_N "checking if _XPG5 should be defined to enable wide-characters... $ECHO_C" >&6
13509 cat >conftest.$ac_ext <<_ACEOF
13510 #line 13510 "configure"
13511 #include "confdefs.h"
13513 #include <${cf_cv_ncurses_header:-curses.h}>
13522 rm -f conftest.$ac_objext
13523 if { (eval echo "$as_me:13523: \"$ac_compile\"") >&5
13524 (eval $ac_compile) 2>&5
13526 echo "$as_me:13526: \$? = $ac_status" >&5
13527 (exit $ac_status); } &&
13528 { ac_try='test -s conftest.$ac_objext'
13529 { (eval echo "$as_me:13529: \"$ac_try\"") >&5
13530 (eval $ac_try) 2>&5
13532 echo "$as_me:13532: \$? = $ac_status" >&5
13533 (exit $ac_status); }; }; then
13536 echo "$as_me: failed program was:" >&5
13537 cat conftest.$ac_ext >&5
13538 cf_save_cppflags="$CPPFLAGS"
13539 CPPFLAGS="$CPPFLAGS -D_XPG5"
13540 cat >conftest.$ac_ext <<_ACEOF
13541 #line 13541 "configure"
13542 #include "confdefs.h"
13544 #include <${cf_cv_ncurses_header:-curses.h}>
13553 rm -f conftest.$ac_objext
13554 if { (eval echo "$as_me:13554: \"$ac_compile\"") >&5
13555 (eval $ac_compile) 2>&5
13557 echo "$as_me:13557: \$? = $ac_status" >&5
13558 (exit $ac_status); } &&
13559 { ac_try='test -s conftest.$ac_objext'
13560 { (eval echo "$as_me:13560: \"$ac_try\"") >&5
13561 (eval $ac_try) 2>&5
13563 echo "$as_me:13563: \$? = $ac_status" >&5
13564 (exit $ac_status); }; }; then
13567 echo "$as_me: failed program was:" >&5
13568 cat conftest.$ac_ext >&5
13570 rm -f conftest.$ac_objext conftest.$ac_ext
13571 CPPFLAGS="$cf_save_cppflags"
13573 rm -f conftest.$ac_objext conftest.$ac_ext
13574 echo "$as_me:13574: result: $cf_define_xpg5" >&5
13575 echo "${ECHO_T}$cf_define_xpg5" >&6
13577 if test "$cf_define_xpg5" = yes
13579 CPPFLAGS="$CPPFLAGS -D_XPG5"
13583 echo "$as_me:13583: checking for wide-character functions" >&5
13584 echo $ECHO_N "checking for wide-character functions... $ECHO_C" >&6
13585 if test "${cf_cv_widechar_funcs+set}" = set; then
13586 echo $ECHO_N "(cached) $ECHO_C" >&6
13589 cat >conftest.$ac_ext <<_ACEOF
13590 #line 13590 "configure"
13591 #include "confdefs.h"
13593 #include <${cf_cv_ncurses_header:-curses.h}>
13598 static wchar_t src_wchar[2];
13599 static cchar_t dst_cchar;
13600 setcchar(&dst_cchar, src_wchar, A_NORMAL, 0, (void *) 0);
13606 rm -f conftest.$ac_objext conftest$ac_exeext
13607 if { (eval echo "$as_me:13607: \"$ac_link\"") >&5
13608 (eval $ac_link) 2>&5
13610 echo "$as_me:13610: \$? = $ac_status" >&5
13611 (exit $ac_status); } &&
13612 { ac_try='test -s conftest$ac_exeext'
13613 { (eval echo "$as_me:13613: \"$ac_try\"") >&5
13614 (eval $ac_try) 2>&5
13616 echo "$as_me:13616: \$? = $ac_status" >&5
13617 (exit $ac_status); }; }; then
13618 cf_cv_widechar_funcs=yes
13620 echo "$as_me: failed program was:" >&5
13621 cat conftest.$ac_ext >&5
13622 cf_cv_widechar_funcs=no
13624 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13627 echo "$as_me:13627: result: $cf_cv_widechar_funcs" >&5
13628 echo "${ECHO_T}$cf_cv_widechar_funcs" >&6
13629 if test "$cf_cv_widechar_funcs" != no ; then
13631 cat >>confdefs.h <<\EOF
13632 #define USE_WIDEC_SUPPORT 1
13636 cat >>confdefs.h <<\EOF
13637 #define USE_WIDEC_SUPPORT 0
13642 cat >>confdefs.h <<\EOF
13643 #define USE_WIDEC_SUPPORT 0
13648 echo "$as_me:13648: checking if sys/time.h works with sys/select.h" >&5
13649 echo $ECHO_N "checking if sys/time.h works with sys/select.h... $ECHO_C" >&6
13650 if test "${cf_cv_sys_time_select+set}" = set; then
13651 echo $ECHO_N "(cached) $ECHO_C" >&6
13654 cat >conftest.$ac_ext <<_ACEOF
13655 #line 13655 "configure"
13656 #include "confdefs.h"
13658 #include <sys/types.h>
13659 #ifdef HAVE_SYS_TIME_H
13660 #include <sys/time.h>
13662 #ifdef HAVE_SYS_SELECT_H
13663 #include <sys/select.h>
13674 rm -f conftest.$ac_objext
13675 if { (eval echo "$as_me:13675: \"$ac_compile\"") >&5
13676 (eval $ac_compile) 2>&5
13678 echo "$as_me:13678: \$? = $ac_status" >&5
13679 (exit $ac_status); } &&
13680 { ac_try='test -s conftest.$ac_objext'
13681 { (eval echo "$as_me:13681: \"$ac_try\"") >&5
13682 (eval $ac_try) 2>&5
13684 echo "$as_me:13684: \$? = $ac_status" >&5
13685 (exit $ac_status); }; }; then
13686 cf_cv_sys_time_select=yes
13688 echo "$as_me: failed program was:" >&5
13689 cat conftest.$ac_ext >&5
13690 cf_cv_sys_time_select=no
13692 rm -f conftest.$ac_objext conftest.$ac_ext
13696 echo "$as_me:13696: result: $cf_cv_sys_time_select" >&5
13697 echo "${ECHO_T}$cf_cv_sys_time_select" >&6
13698 test "$cf_cv_sys_time_select" = yes &&
13699 cat >>confdefs.h <<\EOF
13700 #define HAVE_SYS_TIME_SELECT 1
13703 echo "$as_me:13703: checking for function curses_version" >&5
13704 echo $ECHO_N "checking for function curses_version... $ECHO_C" >&6
13705 if test "${cf_cv_func_curses_version+set}" = set; then
13706 echo $ECHO_N "(cached) $ECHO_C" >&6
13709 if test "$cross_compiling" = yes; then
13710 cf_cv_func_curses_version=unknown
13712 cat >conftest.$ac_ext <<_ACEOF
13713 #line 13713 "configure"
13714 #include "confdefs.h"
13716 #include <${cf_cv_ncurses_header:-curses.h}>
13720 sprintf(temp, "%s\n", curses_version());
13721 ${cf_cv_main_return:-return}(0);
13725 rm -f conftest$ac_exeext
13726 if { (eval echo "$as_me:13726: \"$ac_link\"") >&5
13727 (eval $ac_link) 2>&5
13729 echo "$as_me:13729: \$? = $ac_status" >&5
13730 (exit $ac_status); } && { ac_try='./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_func_curses_version=yes
13739 echo "$as_me: program exited with status $ac_status" >&5
13740 echo "$as_me: failed program was:" >&5
13741 cat conftest.$ac_ext >&5
13742 cf_cv_func_curses_version=no
13745 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13749 echo "$as_me:13749: result: $cf_cv_func_curses_version" >&5
13750 echo "${ECHO_T}$cf_cv_func_curses_version" >&6
13751 test "$cf_cv_func_curses_version" = yes &&
13752 cat >>confdefs.h <<\EOF
13753 #define HAVE_CURSES_VERSION 1
13756 echo "$as_me:13756: checking for alternate character set array" >&5
13757 echo $ECHO_N "checking for alternate character set array... $ECHO_C" >&6
13758 if test "${cf_cv_curses_acs_map+set}" = set; then
13759 echo $ECHO_N "(cached) $ECHO_C" >&6
13762 cf_cv_curses_acs_map=unknown
13763 for name in acs_map _acs_map __acs_map ${NCURSES_WRAP_PREFIX}acs_map
13765 cat >conftest.$ac_ext <<_ACEOF
13766 #line 13766 "configure"
13767 #include "confdefs.h"
13769 #include <${cf_cv_ncurses_header:-curses.h}>
13775 $name['k'] = ACS_PLUS
13781 rm -f conftest.$ac_objext conftest$ac_exeext
13782 if { (eval echo "$as_me:13782: \"$ac_link\"") >&5
13783 (eval $ac_link) 2>&5
13785 echo "$as_me:13785: \$? = $ac_status" >&5
13786 (exit $ac_status); } &&
13787 { ac_try='test -s conftest$ac_exeext'
13788 { (eval echo "$as_me:13788: \"$ac_try\"") >&5
13789 (eval $ac_try) 2>&5
13791 echo "$as_me:13791: \$? = $ac_status" >&5
13792 (exit $ac_status); }; }; then
13793 cf_cv_curses_acs_map=$name; break
13795 echo "$as_me: failed program was:" >&5
13796 cat conftest.$ac_ext >&5
13798 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13802 echo "$as_me:13802: result: $cf_cv_curses_acs_map" >&5
13803 echo "${ECHO_T}$cf_cv_curses_acs_map" >&6
13805 test "$cf_cv_curses_acs_map" != unknown &&
13806 cat >>confdefs.h <<EOF
13807 #define CURSES_ACS_ARRAY $cf_cv_curses_acs_map
13810 if test "$cf_enable_widec" = yes; then
13812 echo "$as_me:13812: checking for wide alternate character set array" >&5
13813 echo $ECHO_N "checking for wide alternate character set array... $ECHO_C" >&6
13814 if test "${cf_cv_curses_wacs_map+set}" = set; then
13815 echo $ECHO_N "(cached) $ECHO_C" >&6
13818 cf_cv_curses_wacs_map=unknown
13819 for name in wacs_map _wacs_map __wacs_map _nc_wacs _wacs_char
13821 cat >conftest.$ac_ext <<_ACEOF
13822 #line 13822 "configure"
13823 #include "confdefs.h"
13825 #ifndef _XOPEN_SOURCE_EXTENDED
13826 #define _XOPEN_SOURCE_EXTENDED
13828 #include <${cf_cv_ncurses_header:-curses.h}>
13832 void *foo = &($name['k'])
13837 rm -f conftest.$ac_objext conftest$ac_exeext
13838 if { (eval echo "$as_me:13838: \"$ac_link\"") >&5
13839 (eval $ac_link) 2>&5
13841 echo "$as_me:13841: \$? = $ac_status" >&5
13842 (exit $ac_status); } &&
13843 { ac_try='test -s conftest$ac_exeext'
13844 { (eval echo "$as_me:13844: \"$ac_try\"") >&5
13845 (eval $ac_try) 2>&5
13847 echo "$as_me:13847: \$? = $ac_status" >&5
13848 (exit $ac_status); }; }; then
13849 cf_cv_curses_wacs_map=$name
13852 echo "$as_me: failed program was:" >&5
13853 cat conftest.$ac_ext >&5
13855 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13858 echo "$as_me:13858: result: $cf_cv_curses_wacs_map" >&5
13859 echo "${ECHO_T}$cf_cv_curses_wacs_map" >&6
13861 test "$cf_cv_curses_wacs_map" != unknown &&
13862 cat >>confdefs.h <<EOF
13863 #define CURSES_WACS_ARRAY $cf_cv_curses_wacs_map
13866 echo "$as_me:13866: checking for wide alternate character constants" >&5
13867 echo $ECHO_N "checking for wide alternate character constants... $ECHO_C" >&6
13868 if test "${cf_cv_curses_wacs_symbols+set}" = set; then
13869 echo $ECHO_N "(cached) $ECHO_C" >&6
13872 cf_cv_curses_wacs_symbols=no
13873 if test "$cf_cv_curses_wacs_map" != unknown
13875 cat >conftest.$ac_ext <<_ACEOF
13876 #line 13876 "configure"
13877 #include "confdefs.h"
13879 #ifndef _XOPEN_SOURCE_EXTENDED
13880 #define _XOPEN_SOURCE_EXTENDED
13882 #include <${cf_cv_ncurses_header:-curses.h}>
13886 cchar_t *foo = WACS_PLUS;
13887 $cf_cv_curses_wacs_map['k'] = *WACS_PLUS
13892 rm -f conftest.$ac_objext conftest$ac_exeext
13893 if { (eval echo "$as_me:13893: \"$ac_link\"") >&5
13894 (eval $ac_link) 2>&5
13896 echo "$as_me:13896: \$? = $ac_status" >&5
13897 (exit $ac_status); } &&
13898 { ac_try='test -s conftest$ac_exeext'
13899 { (eval echo "$as_me:13899: \"$ac_try\"") >&5
13900 (eval $ac_try) 2>&5
13902 echo "$as_me:13902: \$? = $ac_status" >&5
13903 (exit $ac_status); }; }; then
13904 cf_cv_curses_wacs_symbols=yes
13906 echo "$as_me: failed program was:" >&5
13907 cat conftest.$ac_ext >&5
13909 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13911 cat >conftest.$ac_ext <<_ACEOF
13912 #line 13912 "configure"
13913 #include "confdefs.h"
13915 #ifndef _XOPEN_SOURCE_EXTENDED
13916 #define _XOPEN_SOURCE_EXTENDED
13918 #include <${cf_cv_ncurses_header:-curses.h}>
13922 cchar_t *foo = WACS_PLUS
13927 rm -f conftest.$ac_objext conftest$ac_exeext
13928 if { (eval echo "$as_me:13928: \"$ac_link\"") >&5
13929 (eval $ac_link) 2>&5
13931 echo "$as_me:13931: \$? = $ac_status" >&5
13932 (exit $ac_status); } &&
13933 { ac_try='test -s conftest$ac_exeext'
13934 { (eval echo "$as_me:13934: \"$ac_try\"") >&5
13935 (eval $ac_try) 2>&5
13937 echo "$as_me:13937: \$? = $ac_status" >&5
13938 (exit $ac_status); }; }; then
13939 cf_cv_curses_wacs_symbols=yes
13941 echo "$as_me: failed program was:" >&5
13942 cat conftest.$ac_ext >&5
13944 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13948 echo "$as_me:13948: result: $cf_cv_curses_wacs_symbols" >&5
13949 echo "${ECHO_T}$cf_cv_curses_wacs_symbols" >&6
13951 test "$cf_cv_curses_wacs_symbols" != no &&
13952 cat >>confdefs.h <<\EOF
13953 #define CURSES_WACS_SYMBOLS 1
13958 echo "$as_me:13958: checking for type attr_t in ${cf_cv_ncurses_header:-curses.h}" >&5
13959 echo $ECHO_N "checking for type attr_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
13960 cat >conftest.$ac_ext <<_ACEOF
13961 #line 13961 "configure"
13962 #include "confdefs.h"
13964 #ifndef _XOPEN_SOURCE_EXTENDED
13965 #define _XOPEN_SOURCE_EXTENDED
13967 #include <${cf_cv_ncurses_header:-curses.h}>
13978 rm -f conftest.$ac_objext
13979 if { (eval echo "$as_me:13979: \"$ac_compile\"") >&5
13980 (eval $ac_compile) 2>&5
13982 echo "$as_me:13982: \$? = $ac_status" >&5
13983 (exit $ac_status); } &&
13984 { ac_try='test -s conftest.$ac_objext'
13985 { (eval echo "$as_me:13985: \"$ac_try\"") >&5
13986 (eval $ac_try) 2>&5
13988 echo "$as_me:13988: \$? = $ac_status" >&5
13989 (exit $ac_status); }; }; then
13992 echo "$as_me: failed program was:" >&5
13993 cat conftest.$ac_ext >&5
13996 rm -f conftest.$ac_objext conftest.$ac_ext
13997 echo "$as_me:13997: result: $cf_result" >&5
13998 echo "${ECHO_T}$cf_result" >&6
13999 if test $cf_result = yes ; then
14001 cf_result=`echo "have_type_attr_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14003 cat >>confdefs.h <<EOF
14004 #define $cf_result 1
14009 cat >>confdefs.h <<EOF
14010 #define attr_t long
14015 if test "$cf_enable_widec" = yes; then
14017 # This is needed on Tru64 5.0 to declare mbstate_t
14018 echo "$as_me:14018: checking if we must include wchar.h to declare mbstate_t" >&5
14019 echo $ECHO_N "checking if we must include wchar.h to declare mbstate_t... $ECHO_C" >&6
14020 if test "${cf_cv_mbstate_t+set}" = set; then
14021 echo $ECHO_N "(cached) $ECHO_C" >&6
14024 cat >conftest.$ac_ext <<_ACEOF
14025 #line 14025 "configure"
14026 #include "confdefs.h"
14028 #include <stdlib.h>
14029 #include <stdarg.h>
14031 #ifdef HAVE_LIBUTF8_H
14032 #include <libutf8.h>
14042 rm -f conftest.$ac_objext
14043 if { (eval echo "$as_me:14043: \"$ac_compile\"") >&5
14044 (eval $ac_compile) 2>&5
14046 echo "$as_me:14046: \$? = $ac_status" >&5
14047 (exit $ac_status); } &&
14048 { ac_try='test -s conftest.$ac_objext'
14049 { (eval echo "$as_me:14049: \"$ac_try\"") >&5
14050 (eval $ac_try) 2>&5
14052 echo "$as_me:14052: \$? = $ac_status" >&5
14053 (exit $ac_status); }; }; then
14056 echo "$as_me: failed program was:" >&5
14057 cat conftest.$ac_ext >&5
14058 cat >conftest.$ac_ext <<_ACEOF
14059 #line 14059 "configure"
14060 #include "confdefs.h"
14062 #include <stdlib.h>
14063 #include <stdarg.h>
14066 #ifdef HAVE_LIBUTF8_H
14067 #include <libutf8.h>
14077 rm -f conftest.$ac_objext
14078 if { (eval echo "$as_me:14078: \"$ac_compile\"") >&5
14079 (eval $ac_compile) 2>&5
14081 echo "$as_me:14081: \$? = $ac_status" >&5
14082 (exit $ac_status); } &&
14083 { ac_try='test -s conftest.$ac_objext'
14084 { (eval echo "$as_me:14084: \"$ac_try\"") >&5
14085 (eval $ac_try) 2>&5
14087 echo "$as_me:14087: \$? = $ac_status" >&5
14088 (exit $ac_status); }; }; then
14089 cf_cv_mbstate_t=yes
14091 echo "$as_me: failed program was:" >&5
14092 cat conftest.$ac_ext >&5
14093 cf_cv_mbstate_t=unknown
14095 rm -f conftest.$ac_objext conftest.$ac_ext
14097 rm -f conftest.$ac_objext conftest.$ac_ext
14099 echo "$as_me:14099: result: $cf_cv_mbstate_t" >&5
14100 echo "${ECHO_T}$cf_cv_mbstate_t" >&6
14102 if test "$cf_cv_mbstate_t" = yes ; then
14104 cat >>confdefs.h <<\EOF
14105 #define NEED_WCHAR_H 1
14111 # if we do not find mbstate_t in either place, use substitution to provide a fallback.
14112 if test "$cf_cv_mbstate_t" = unknown ; then
14113 NCURSES_MBSTATE_T=1
14116 # if we find mbstate_t in either place, use substitution to provide a fallback.
14117 if test "$cf_cv_mbstate_t" != unknown ; then
14118 NCURSES_OK_MBSTATE_T=1
14121 # This is needed on Tru64 5.0 to declare wchar_t
14122 echo "$as_me:14122: checking if we must include wchar.h to declare wchar_t" >&5
14123 echo $ECHO_N "checking if we must include wchar.h to declare wchar_t... $ECHO_C" >&6
14124 if test "${cf_cv_wchar_t+set}" = set; then
14125 echo $ECHO_N "(cached) $ECHO_C" >&6
14128 cat >conftest.$ac_ext <<_ACEOF
14129 #line 14129 "configure"
14130 #include "confdefs.h"
14132 #include <stdlib.h>
14133 #include <stdarg.h>
14135 #ifdef HAVE_LIBUTF8_H
14136 #include <libutf8.h>
14146 rm -f conftest.$ac_objext
14147 if { (eval echo "$as_me:14147: \"$ac_compile\"") >&5
14148 (eval $ac_compile) 2>&5
14150 echo "$as_me:14150: \$? = $ac_status" >&5
14151 (exit $ac_status); } &&
14152 { ac_try='test -s conftest.$ac_objext'
14153 { (eval echo "$as_me:14153: \"$ac_try\"") >&5
14154 (eval $ac_try) 2>&5
14156 echo "$as_me:14156: \$? = $ac_status" >&5
14157 (exit $ac_status); }; }; then
14160 echo "$as_me: failed program was:" >&5
14161 cat conftest.$ac_ext >&5
14162 cat >conftest.$ac_ext <<_ACEOF
14163 #line 14163 "configure"
14164 #include "confdefs.h"
14166 #include <stdlib.h>
14167 #include <stdarg.h>
14170 #ifdef HAVE_LIBUTF8_H
14171 #include <libutf8.h>
14181 rm -f conftest.$ac_objext
14182 if { (eval echo "$as_me:14182: \"$ac_compile\"") >&5
14183 (eval $ac_compile) 2>&5
14185 echo "$as_me:14185: \$? = $ac_status" >&5
14186 (exit $ac_status); } &&
14187 { ac_try='test -s conftest.$ac_objext'
14188 { (eval echo "$as_me:14188: \"$ac_try\"") >&5
14189 (eval $ac_try) 2>&5
14191 echo "$as_me:14191: \$? = $ac_status" >&5
14192 (exit $ac_status); }; }; then
14195 echo "$as_me: failed program was:" >&5
14196 cat conftest.$ac_ext >&5
14197 cf_cv_wchar_t=unknown
14199 rm -f conftest.$ac_objext conftest.$ac_ext
14201 rm -f conftest.$ac_objext conftest.$ac_ext
14203 echo "$as_me:14203: result: $cf_cv_wchar_t" >&5
14204 echo "${ECHO_T}$cf_cv_wchar_t" >&6
14206 if test "$cf_cv_wchar_t" = yes ; then
14208 cat >>confdefs.h <<\EOF
14209 #define NEED_WCHAR_H 1
14215 # if we do not find wchar_t in either place, use substitution to provide a fallback.
14216 if test "$cf_cv_wchar_t" = unknown ; then
14220 # if we find wchar_t in either place, use substitution to provide a fallback.
14221 if test "$cf_cv_wchar_t" != unknown ; then
14222 NCURSES_OK_WCHAR_T=1
14225 # This is needed on Tru64 5.0 to declare wint_t
14226 echo "$as_me:14226: checking if we must include wchar.h to declare wint_t" >&5
14227 echo $ECHO_N "checking if we must include wchar.h to declare wint_t... $ECHO_C" >&6
14228 if test "${cf_cv_wint_t+set}" = set; then
14229 echo $ECHO_N "(cached) $ECHO_C" >&6
14232 cat >conftest.$ac_ext <<_ACEOF
14233 #line 14233 "configure"
14234 #include "confdefs.h"
14236 #include <stdlib.h>
14237 #include <stdarg.h>
14239 #ifdef HAVE_LIBUTF8_H
14240 #include <libutf8.h>
14250 rm -f conftest.$ac_objext
14251 if { (eval echo "$as_me:14251: \"$ac_compile\"") >&5
14252 (eval $ac_compile) 2>&5
14254 echo "$as_me:14254: \$? = $ac_status" >&5
14255 (exit $ac_status); } &&
14256 { ac_try='test -s conftest.$ac_objext'
14257 { (eval echo "$as_me:14257: \"$ac_try\"") >&5
14258 (eval $ac_try) 2>&5
14260 echo "$as_me:14260: \$? = $ac_status" >&5
14261 (exit $ac_status); }; }; then
14264 echo "$as_me: failed program was:" >&5
14265 cat conftest.$ac_ext >&5
14266 cat >conftest.$ac_ext <<_ACEOF
14267 #line 14267 "configure"
14268 #include "confdefs.h"
14270 #include <stdlib.h>
14271 #include <stdarg.h>
14274 #ifdef HAVE_LIBUTF8_H
14275 #include <libutf8.h>
14285 rm -f conftest.$ac_objext
14286 if { (eval echo "$as_me:14286: \"$ac_compile\"") >&5
14287 (eval $ac_compile) 2>&5
14289 echo "$as_me:14289: \$? = $ac_status" >&5
14290 (exit $ac_status); } &&
14291 { ac_try='test -s conftest.$ac_objext'
14292 { (eval echo "$as_me:14292: \"$ac_try\"") >&5
14293 (eval $ac_try) 2>&5
14295 echo "$as_me:14295: \$? = $ac_status" >&5
14296 (exit $ac_status); }; }; then
14299 echo "$as_me: failed program was:" >&5
14300 cat conftest.$ac_ext >&5
14301 cf_cv_wint_t=unknown
14303 rm -f conftest.$ac_objext conftest.$ac_ext
14305 rm -f conftest.$ac_objext conftest.$ac_ext
14307 echo "$as_me:14307: result: $cf_cv_wint_t" >&5
14308 echo "${ECHO_T}$cf_cv_wint_t" >&6
14310 if test "$cf_cv_wint_t" = yes ; then
14312 cat >>confdefs.h <<\EOF
14313 #define NEED_WCHAR_H 1
14319 # if we do not find wint_t in either place, use substitution to provide a fallback.
14320 if test "$cf_cv_wint_t" = unknown ; then
14324 # if we find wint_t in either place, use substitution to provide a fallback.
14325 if test "$cf_cv_wint_t" != unknown ; then
14326 NCURSES_OK_WINT_T=1
14329 if test "$NCURSES_OK_MBSTATE_T" = 0 ; then
14331 echo "$as_me:14331: checking for type mbstate_t in ${cf_cv_ncurses_header:-curses.h}" >&5
14332 echo $ECHO_N "checking for type mbstate_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
14333 cat >conftest.$ac_ext <<_ACEOF
14334 #line 14334 "configure"
14335 #include "confdefs.h"
14337 #ifndef _XOPEN_SOURCE_EXTENDED
14338 #define _XOPEN_SOURCE_EXTENDED
14340 #include <${cf_cv_ncurses_header:-curses.h}>
14351 rm -f conftest.$ac_objext
14352 if { (eval echo "$as_me:14352: \"$ac_compile\"") >&5
14353 (eval $ac_compile) 2>&5
14355 echo "$as_me:14355: \$? = $ac_status" >&5
14356 (exit $ac_status); } &&
14357 { ac_try='test -s conftest.$ac_objext'
14358 { (eval echo "$as_me:14358: \"$ac_try\"") >&5
14359 (eval $ac_try) 2>&5
14361 echo "$as_me:14361: \$? = $ac_status" >&5
14362 (exit $ac_status); }; }; then
14365 echo "$as_me: failed program was:" >&5
14366 cat conftest.$ac_ext >&5
14369 rm -f conftest.$ac_objext conftest.$ac_ext
14370 echo "$as_me:14370: result: $cf_result" >&5
14371 echo "${ECHO_T}$cf_result" >&6
14372 if test $cf_result = yes ; then
14374 cf_result=`echo "have_type_mbstate_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14376 cat >>confdefs.h <<EOF
14377 #define $cf_result 1
14382 cat >>confdefs.h <<EOF
14383 #define mbstate_t long
14390 if test "$NCURSES_OK_WCHAR_T" = 0 ; then
14392 echo "$as_me:14392: checking for type wchar_t in ${cf_cv_ncurses_header:-curses.h}" >&5
14393 echo $ECHO_N "checking for type wchar_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
14394 cat >conftest.$ac_ext <<_ACEOF
14395 #line 14395 "configure"
14396 #include "confdefs.h"
14398 #ifndef _XOPEN_SOURCE_EXTENDED
14399 #define _XOPEN_SOURCE_EXTENDED
14401 #include <${cf_cv_ncurses_header:-curses.h}>
14412 rm -f conftest.$ac_objext
14413 if { (eval echo "$as_me:14413: \"$ac_compile\"") >&5
14414 (eval $ac_compile) 2>&5
14416 echo "$as_me:14416: \$? = $ac_status" >&5
14417 (exit $ac_status); } &&
14418 { ac_try='test -s conftest.$ac_objext'
14419 { (eval echo "$as_me:14419: \"$ac_try\"") >&5
14420 (eval $ac_try) 2>&5
14422 echo "$as_me:14422: \$? = $ac_status" >&5
14423 (exit $ac_status); }; }; then
14426 echo "$as_me: failed program was:" >&5
14427 cat conftest.$ac_ext >&5
14430 rm -f conftest.$ac_objext conftest.$ac_ext
14431 echo "$as_me:14431: result: $cf_result" >&5
14432 echo "${ECHO_T}$cf_result" >&6
14433 if test $cf_result = yes ; then
14435 cf_result=`echo "have_type_wchar_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14437 cat >>confdefs.h <<EOF
14438 #define $cf_result 1
14443 cat >>confdefs.h <<EOF
14444 #define wchar_t long
14451 if test "$NCURSES_OK_WINT_T" = 0 ; then
14453 echo "$as_me:14453: checking for type wint_t in ${cf_cv_ncurses_header:-curses.h}" >&5
14454 echo $ECHO_N "checking for type wint_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
14455 cat >conftest.$ac_ext <<_ACEOF
14456 #line 14456 "configure"
14457 #include "confdefs.h"
14459 #ifndef _XOPEN_SOURCE_EXTENDED
14460 #define _XOPEN_SOURCE_EXTENDED
14462 #include <${cf_cv_ncurses_header:-curses.h}>
14473 rm -f conftest.$ac_objext
14474 if { (eval echo "$as_me:14474: \"$ac_compile\"") >&5
14475 (eval $ac_compile) 2>&5
14477 echo "$as_me:14477: \$? = $ac_status" >&5
14478 (exit $ac_status); } &&
14479 { ac_try='test -s conftest.$ac_objext'
14480 { (eval echo "$as_me:14480: \"$ac_try\"") >&5
14481 (eval $ac_try) 2>&5
14483 echo "$as_me:14483: \$? = $ac_status" >&5
14484 (exit $ac_status); }; }; then
14487 echo "$as_me: failed program was:" >&5
14488 cat conftest.$ac_ext >&5
14491 rm -f conftest.$ac_objext conftest.$ac_ext
14492 echo "$as_me:14492: result: $cf_result" >&5
14493 echo "${ECHO_T}$cf_result" >&6
14494 if test $cf_result = yes ; then
14496 cf_result=`echo "have_type_wint_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14498 cat >>confdefs.h <<EOF
14499 #define $cf_result 1
14504 cat >>confdefs.h <<EOF
14505 #define wint_t long
14513 echo "$as_me:14513: checking for data boolnames declaration in ${cf_cv_ncurses_header:-curses.h}" >&5
14514 echo $ECHO_N "checking for data boolnames declaration in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
14516 cat >conftest.$ac_ext <<_ACEOF
14517 #line 14517 "configure"
14518 #include "confdefs.h"
14520 #ifdef HAVE_XCURSES
14521 #include <xcurses.h>
14522 char * XCursesProgramName = "test";
14524 #include <${cf_cv_ncurses_header:-curses.h}>
14525 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
14526 #include <ncursesw/term.h>
14527 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
14528 #include <ncurses/term.h>
14529 #elif defined(HAVE_TERM_H)
14538 void *foo = &(boolnames)
14544 rm -f conftest.$ac_objext
14545 if { (eval echo "$as_me:14545: \"$ac_compile\"") >&5
14546 (eval $ac_compile) 2>&5
14548 echo "$as_me:14548: \$? = $ac_status" >&5
14549 (exit $ac_status); } &&
14550 { ac_try='test -s conftest.$ac_objext'
14551 { (eval echo "$as_me:14551: \"$ac_try\"") >&5
14552 (eval $ac_try) 2>&5
14554 echo "$as_me:14554: \$? = $ac_status" >&5
14555 (exit $ac_status); }; }; then
14558 echo "$as_me: failed program was:" >&5
14559 cat conftest.$ac_ext >&5
14562 rm -f conftest.$ac_objext conftest.$ac_ext
14563 echo "$as_me:14563: result: $cf_result" >&5
14564 echo "${ECHO_T}$cf_result" >&6
14566 if test $cf_result = yes ; then
14568 cf_result=`echo "have_curses_data_boolnames" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14570 cat >>confdefs.h <<EOF
14571 #define $cf_result 1
14575 echo "$as_me:14575: checking for data boolnames in library" >&5
14576 echo $ECHO_N "checking for data boolnames in library... $ECHO_C" >&6
14577 # BSD linkers insist on making weak linkage, but resolve at runtime.
14578 if test "$cross_compiling" = yes; then
14581 cat >conftest.$ac_ext <<_ACEOF
14582 #line 14582 "configure"
14583 #include "confdefs.h"
14585 #ifdef HAVE_XCURSES
14586 #include <xcurses.h>
14587 char * XCursesProgramName = "test";
14589 #include <${cf_cv_ncurses_header:-curses.h}>
14590 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
14591 #include <ncursesw/term.h>
14592 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
14593 #include <ncurses/term.h>
14594 #elif defined(HAVE_TERM_H)
14599 extern char boolnames;
14605 void *foo = &(boolnames);
14606 ${cf_cv_main_return:-return}(foo == 0);
14613 rm -f conftest.$ac_objext conftest$ac_exeext
14614 if { (eval echo "$as_me:14614: \"$ac_link\"") >&5
14615 (eval $ac_link) 2>&5
14617 echo "$as_me:14617: \$? = $ac_status" >&5
14618 (exit $ac_status); } &&
14619 { ac_try='test -s conftest$ac_exeext'
14620 { (eval echo "$as_me:14620: \"$ac_try\"") >&5
14621 (eval $ac_try) 2>&5
14623 echo "$as_me:14623: \$? = $ac_status" >&5
14624 (exit $ac_status); }; }; then
14627 echo "$as_me: failed program was:" >&5
14628 cat conftest.$ac_ext >&5
14631 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14634 cat >conftest.$ac_ext <<_ACEOF
14635 #line 14635 "configure"
14636 #include "confdefs.h"
14638 #ifdef HAVE_XCURSES
14639 #include <xcurses.h>
14640 char * XCursesProgramName = "test";
14642 #include <${cf_cv_ncurses_header:-curses.h}>
14643 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
14644 #include <ncursesw/term.h>
14645 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
14646 #include <ncurses/term.h>
14647 #elif defined(HAVE_TERM_H)
14652 extern char boolnames;
14655 void *foo = &(boolnames);
14656 ${cf_cv_main_return:-return}(foo == 0);
14659 rm -f conftest$ac_exeext
14660 if { (eval echo "$as_me:14660: \"$ac_link\"") >&5
14661 (eval $ac_link) 2>&5
14663 echo "$as_me:14663: \$? = $ac_status" >&5
14664 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14665 { (eval echo "$as_me:14665: \"$ac_try\"") >&5
14666 (eval $ac_try) 2>&5
14668 echo "$as_me:14668: \$? = $ac_status" >&5
14669 (exit $ac_status); }; }; then
14672 echo "$as_me: program exited with status $ac_status" >&5
14673 echo "$as_me: failed program was:" >&5
14674 cat conftest.$ac_ext >&5
14677 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14679 echo "$as_me:14679: result: $cf_result" >&5
14680 echo "${ECHO_T}$cf_result" >&6
14681 if test $cf_result = yes ; then
14683 cf_result=`echo "decl_curses_data_boolnames" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14685 cat >>confdefs.h <<EOF
14686 #define $cf_result 1
14692 echo "$as_me:14692: checking for data boolfnames declaration in ${cf_cv_ncurses_header:-curses.h}" >&5
14693 echo $ECHO_N "checking for data boolfnames declaration in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
14695 cat >conftest.$ac_ext <<_ACEOF
14696 #line 14696 "configure"
14697 #include "confdefs.h"
14699 #ifdef HAVE_XCURSES
14700 #include <xcurses.h>
14701 char * XCursesProgramName = "test";
14703 #include <${cf_cv_ncurses_header:-curses.h}>
14704 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
14705 #include <ncursesw/term.h>
14706 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
14707 #include <ncurses/term.h>
14708 #elif defined(HAVE_TERM_H)
14717 void *foo = &(boolfnames)
14723 rm -f conftest.$ac_objext
14724 if { (eval echo "$as_me:14724: \"$ac_compile\"") >&5
14725 (eval $ac_compile) 2>&5
14727 echo "$as_me:14727: \$? = $ac_status" >&5
14728 (exit $ac_status); } &&
14729 { ac_try='test -s conftest.$ac_objext'
14730 { (eval echo "$as_me:14730: \"$ac_try\"") >&5
14731 (eval $ac_try) 2>&5
14733 echo "$as_me:14733: \$? = $ac_status" >&5
14734 (exit $ac_status); }; }; then
14737 echo "$as_me: failed program was:" >&5
14738 cat conftest.$ac_ext >&5
14741 rm -f conftest.$ac_objext conftest.$ac_ext
14742 echo "$as_me:14742: result: $cf_result" >&5
14743 echo "${ECHO_T}$cf_result" >&6
14745 if test $cf_result = yes ; then
14747 cf_result=`echo "have_curses_data_boolfnames" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14749 cat >>confdefs.h <<EOF
14750 #define $cf_result 1
14754 echo "$as_me:14754: checking for data boolfnames in library" >&5
14755 echo $ECHO_N "checking for data boolfnames in library... $ECHO_C" >&6
14756 # BSD linkers insist on making weak linkage, but resolve at runtime.
14757 if test "$cross_compiling" = yes; then
14760 cat >conftest.$ac_ext <<_ACEOF
14761 #line 14761 "configure"
14762 #include "confdefs.h"
14764 #ifdef HAVE_XCURSES
14765 #include <xcurses.h>
14766 char * XCursesProgramName = "test";
14768 #include <${cf_cv_ncurses_header:-curses.h}>
14769 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
14770 #include <ncursesw/term.h>
14771 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
14772 #include <ncurses/term.h>
14773 #elif defined(HAVE_TERM_H)
14778 extern char boolfnames;
14784 void *foo = &(boolfnames);
14785 ${cf_cv_main_return:-return}(foo == 0);
14792 rm -f conftest.$ac_objext conftest$ac_exeext
14793 if { (eval echo "$as_me:14793: \"$ac_link\"") >&5
14794 (eval $ac_link) 2>&5
14796 echo "$as_me:14796: \$? = $ac_status" >&5
14797 (exit $ac_status); } &&
14798 { ac_try='test -s conftest$ac_exeext'
14799 { (eval echo "$as_me:14799: \"$ac_try\"") >&5
14800 (eval $ac_try) 2>&5
14802 echo "$as_me:14802: \$? = $ac_status" >&5
14803 (exit $ac_status); }; }; then
14806 echo "$as_me: failed program was:" >&5
14807 cat conftest.$ac_ext >&5
14810 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14813 cat >conftest.$ac_ext <<_ACEOF
14814 #line 14814 "configure"
14815 #include "confdefs.h"
14817 #ifdef HAVE_XCURSES
14818 #include <xcurses.h>
14819 char * XCursesProgramName = "test";
14821 #include <${cf_cv_ncurses_header:-curses.h}>
14822 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
14823 #include <ncursesw/term.h>
14824 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
14825 #include <ncurses/term.h>
14826 #elif defined(HAVE_TERM_H)
14831 extern char boolfnames;
14834 void *foo = &(boolfnames);
14835 ${cf_cv_main_return:-return}(foo == 0);
14838 rm -f conftest$ac_exeext
14839 if { (eval echo "$as_me:14839: \"$ac_link\"") >&5
14840 (eval $ac_link) 2>&5
14842 echo "$as_me:14842: \$? = $ac_status" >&5
14843 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14844 { (eval echo "$as_me:14844: \"$ac_try\"") >&5
14845 (eval $ac_try) 2>&5
14847 echo "$as_me:14847: \$? = $ac_status" >&5
14848 (exit $ac_status); }; }; then
14851 echo "$as_me: program exited with status $ac_status" >&5
14852 echo "$as_me: failed program was:" >&5
14853 cat conftest.$ac_ext >&5
14856 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14858 echo "$as_me:14858: result: $cf_result" >&5
14859 echo "${ECHO_T}$cf_result" >&6
14860 if test $cf_result = yes ; then
14862 cf_result=`echo "decl_curses_data_boolfnames" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14864 cat >>confdefs.h <<EOF
14865 #define $cf_result 1
14871 if ( test "$GCC" = yes || test "$GXX" = yes )
14873 echo "$as_me:14873: checking if you want to turn on gcc warnings" >&5
14874 echo $ECHO_N "checking if you want to turn on gcc warnings... $ECHO_C" >&6
14876 # Check whether --enable-warnings or --disable-warnings was given.
14877 if test "${enable_warnings+set}" = set; then
14878 enableval="$enable_warnings"
14879 test "$enableval" != yes && enableval=no
14880 if test "$enableval" != "no" ; then
14890 echo "$as_me:14890: result: $with_warnings" >&5
14891 echo "${ECHO_T}$with_warnings" >&6
14892 if test "$with_warnings" = "yes"
14895 if test "$GCC" = yes
14897 cat > conftest.i <<EOF
14899 #define GCC_PRINTF 0
14902 #define GCC_SCANF 0
14904 #ifndef GCC_NORETURN
14905 #define GCC_NORETURN /* nothing */
14908 #define GCC_UNUSED /* nothing */
14911 if test "$GCC" = yes
14913 { echo "$as_me:14913: checking for $CC __attribute__ directives..." >&5
14914 echo "$as_me: checking for $CC __attribute__ directives..." >&6;}
14915 cat > conftest.$ac_ext <<EOF
14916 #line 14916 "${as_me:-configure}"
14917 #include "confdefs.h"
14918 #include "conftest.h"
14919 #include "conftest.i"
14921 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
14923 #define GCC_PRINTFLIKE(fmt,var) /*nothing*/
14926 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
14928 #define GCC_SCANFLIKE(fmt,var) /*nothing*/
14930 extern void wow(char *,...) GCC_SCANFLIKE(1,2);
14931 extern void oops(char *,...) GCC_PRINTFLIKE(1,2) GCC_NORETURN;
14932 extern void foo(void) GCC_NORETURN;
14933 int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { return 0; }
14935 cf_printf_attribute=no
14936 cf_scanf_attribute=no
14937 for cf_attribute in scanf printf unused noreturn
14940 cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14942 cf_directive="__attribute__(($cf_attribute))"
14943 echo "checking for $CC $cf_directive" 1>&5
14945 case $cf_attribute in #(vi
14947 cf_printf_attribute=yes
14948 cat >conftest.h <<EOF
14949 #define GCC_$cf_ATTRIBUTE 1
14953 cf_scanf_attribute=yes
14954 cat >conftest.h <<EOF
14955 #define GCC_$cf_ATTRIBUTE 1
14959 cat >conftest.h <<EOF
14960 #define GCC_$cf_ATTRIBUTE $cf_directive
14965 if { (eval echo "$as_me:14965: \"$ac_compile\"") >&5
14966 (eval $ac_compile) 2>&5
14968 echo "$as_me:14968: \$? = $ac_status" >&5
14969 (exit $ac_status); }; then
14970 test -n "$verbose" && echo "$as_me:14970: result: ... $cf_attribute" >&5
14971 echo "${ECHO_T}... $cf_attribute" >&6
14972 cat conftest.h >>confdefs.h
14973 case $cf_attribute in #(vi
14976 cat >>confdefs.h <<EOF
14977 #define GCC_NORETURN $cf_directive
14982 cf_value='/* nothing */'
14983 if test "$cf_printf_attribute" != no ; then
14984 cf_value='__attribute__((format(printf,fmt,var)))'
14986 cat >>confdefs.h <<\EOF
14987 #define GCC_PRINTF 1
14992 cat >>confdefs.h <<EOF
14993 #define GCC_PRINTFLIKE(fmt,var) $cf_value
14998 cf_value='/* nothing */'
14999 if test "$cf_scanf_attribute" != no ; then
15000 cf_value='__attribute__((format(scanf,fmt,var)))'
15002 cat >>confdefs.h <<\EOF
15003 #define GCC_SCANF 1
15008 cat >>confdefs.h <<EOF
15009 #define GCC_SCANFLIKE(fmt,var) $cf_value
15015 cat >>confdefs.h <<EOF
15016 #define GCC_UNUSED $cf_directive
15024 fgrep define conftest.i >>confdefs.h
15031 if test "$GCC" = yes ; then
15034 echo "$as_me:15034: checking if this is really Intel C compiler" >&5
15035 echo $ECHO_N "checking if this is really Intel C compiler... $ECHO_C" >&6
15036 cf_save_CFLAGS="$CFLAGS"
15037 CFLAGS="$CFLAGS -no-gcc"
15038 cat >conftest.$ac_ext <<_ACEOF
15039 #line 15039 "configure"
15040 #include "confdefs.h"
15046 #ifdef __INTEL_COMPILER
15055 rm -f conftest.$ac_objext
15056 if { (eval echo "$as_me:15056: \"$ac_compile\"") >&5
15057 (eval $ac_compile) 2>&5
15059 echo "$as_me:15059: \$? = $ac_status" >&5
15060 (exit $ac_status); } &&
15061 { ac_try='test -s conftest.$ac_objext'
15062 { (eval echo "$as_me:15062: \"$ac_try\"") >&5
15063 (eval $ac_try) 2>&5
15065 echo "$as_me:15065: \$? = $ac_status" >&5
15066 (exit $ac_status); }; }; then
15068 cf_save_CFLAGS="$cf_save_CFLAGS -we147 -no-gcc"
15071 echo "$as_me: failed program was:" >&5
15072 cat conftest.$ac_ext >&5
15074 rm -f conftest.$ac_objext conftest.$ac_ext
15075 CFLAGS="$cf_save_CFLAGS"
15076 echo "$as_me:15076: result: $INTEL_COMPILER" >&5
15077 echo "${ECHO_T}$INTEL_COMPILER" >&6
15084 if test "$GCC" = yes ; then
15085 echo "$as_me:15085: checking if this is really Clang C compiler" >&5
15086 echo $ECHO_N "checking if this is really Clang C compiler... $ECHO_C" >&6
15087 cf_save_CFLAGS="$CFLAGS"
15088 CFLAGS="$CFLAGS -Qunused-arguments"
15089 cat >conftest.$ac_ext <<_ACEOF
15090 #line 15090 "configure"
15091 #include "confdefs.h"
15106 rm -f conftest.$ac_objext
15107 if { (eval echo "$as_me:15107: \"$ac_compile\"") >&5
15108 (eval $ac_compile) 2>&5
15110 echo "$as_me:15110: \$? = $ac_status" >&5
15111 (exit $ac_status); } &&
15112 { ac_try='test -s conftest.$ac_objext'
15113 { (eval echo "$as_me:15113: \"$ac_try\"") >&5
15114 (eval $ac_try) 2>&5
15116 echo "$as_me:15116: \$? = $ac_status" >&5
15117 (exit $ac_status); }; }; then
15119 cf_save_CFLAGS="$cf_save_CFLAGS -Qunused-arguments"
15122 echo "$as_me: failed program was:" >&5
15123 cat conftest.$ac_ext >&5
15125 rm -f conftest.$ac_objext conftest.$ac_ext
15126 CFLAGS="$cf_save_CFLAGS"
15127 echo "$as_me:15127: result: $CLANG_COMPILER" >&5
15128 echo "${ECHO_T}$CLANG_COMPILER" >&6
15131 cat > conftest.$ac_ext <<EOF
15132 #line 15132 "${as_me:-configure}"
15133 int main(int argc, char *argv[]) { return (argv[argc-1] == 0) ; }
15136 if test "$INTEL_COMPILER" = yes
15138 # The "-wdXXX" options suppress warnings:
15139 # remark #1419: external declaration in primary source file
15140 # remark #1683: explicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem)
15141 # remark #1684: conversion from pointer to same-sized integral type (potential portability problem)
15142 # remark #193: zero used for undefined preprocessing identifier
15143 # remark #593: variable "curs_sb_left_arrow" was set but never used
15144 # remark #810: conversion from "int" to "Dimension={unsigned short}" may lose significant bits
15145 # remark #869: parameter "tw" was never referenced
15146 # remark #981: operands are evaluated in unspecified order
15147 # warning #279: controlling expression is constant
15149 { echo "$as_me:15149: checking for $CC warning options..." >&5
15150 echo "$as_me: checking for $CC warning options..." >&6;}
15151 cf_save_CFLAGS="$CFLAGS"
15152 EXTRA_CFLAGS="-Wall"
15164 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
15165 if { (eval echo "$as_me:15165: \"$ac_compile\"") >&5
15166 (eval $ac_compile) 2>&5
15168 echo "$as_me:15168: \$? = $ac_status" >&5
15169 (exit $ac_status); }; then
15170 test -n "$verbose" && echo "$as_me:15170: result: ... -$cf_opt" >&5
15171 echo "${ECHO_T}... -$cf_opt" >&6
15172 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
15175 CFLAGS="$cf_save_CFLAGS"
15177 elif test "$GCC" = yes
15179 { echo "$as_me:15179: checking for $CC warning options..." >&5
15180 echo "$as_me: checking for $CC warning options..." >&6;}
15181 cf_save_CFLAGS="$CFLAGS"
15184 test "$with_ext_const" = yes && cf_warn_CONST="Wwrite-strings"
15185 for cf_opt in W Wall \
15186 Wbad-function-cast \
15190 Wmissing-declarations \
15191 Wmissing-prototypes \
15195 Wstrict-prototypes \
15196 Wundef $cf_warn_CONST
15198 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
15199 if { (eval echo "$as_me:15199: \"$ac_compile\"") >&5
15200 (eval $ac_compile) 2>&5
15202 echo "$as_me:15202: \$? = $ac_status" >&5
15203 (exit $ac_status); }; then
15204 test -n "$verbose" && echo "$as_me:15204: result: ... -$cf_opt" >&5
15205 echo "${ECHO_T}... -$cf_opt" >&6
15206 case $cf_opt in #(vi
15208 CPPFLAGS="$CPPFLAGS -DXTSTRINGDEFINES"
15211 case $GCC_VERSION in
15213 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
15215 echo "${as_me:-configure}:15215: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
15220 Wpointer-arith) #(vi
15221 case $GCC_VERSION in
15223 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
15225 echo "${as_me:-configure}:15225: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
15231 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
15234 CFLAGS="$cf_save_CFLAGS"
15241 echo "$as_me:15241: checking if you want to use dmalloc for testing" >&5
15242 echo $ECHO_N "checking if you want to use dmalloc for testing... $ECHO_C" >&6
15244 # Check whether --with-dmalloc or --without-dmalloc was given.
15245 if test "${with_dmalloc+set}" = set; then
15246 withval="$with_dmalloc"
15248 cat >>confdefs.h <<EOF
15249 #define USE_DMALLOC 1
15252 : ${with_cflags:=-g}
15253 : ${with_no_leaks:=yes}
15258 echo "$as_me:15258: result: ${with_dmalloc:-no}" >&5
15259 echo "${ECHO_T}${with_dmalloc:-no}" >&6
15261 case .$with_cflags in #(vi
15263 case .$CFLAGS in #(vi
15271 cf_new_extra_cppflags=
15273 for cf_add_cflags in -g
15275 case $cf_fix_cppflags in
15277 case $cf_add_cflags in #(vi
15278 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
15279 case $cf_add_cflags in
15281 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
15283 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
15284 && test -z "${cf_tst_cflags}" \
15285 && cf_fix_cppflags=yes
15287 if test $cf_fix_cppflags = yes ; then
15288 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
15290 elif test "${cf_tst_cflags}" = "\"'" ; then
15291 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
15296 case "$CPPFLAGS" in
15297 *$cf_add_cflags) #(vi
15300 case $cf_add_cflags in #(vi
15302 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
15304 CPPFLAGS=`echo "$CPPFLAGS" | \
15305 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
15306 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
15310 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
15315 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
15320 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
15322 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
15324 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
15325 && test -z "${cf_tst_cflags}" \
15326 && cf_fix_cppflags=no
15331 if test -n "$cf_new_cflags" ; then
15333 CFLAGS="$CFLAGS $cf_new_cflags"
15336 if test -n "$cf_new_cppflags" ; then
15338 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
15341 if test -n "$cf_new_extra_cppflags" ; then
15343 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
15351 if test "$with_dmalloc" = yes ; then
15352 echo "$as_me:15352: checking for dmalloc.h" >&5
15353 echo $ECHO_N "checking for dmalloc.h... $ECHO_C" >&6
15354 if test "${ac_cv_header_dmalloc_h+set}" = set; then
15355 echo $ECHO_N "(cached) $ECHO_C" >&6
15357 cat >conftest.$ac_ext <<_ACEOF
15358 #line 15358 "configure"
15359 #include "confdefs.h"
15360 #include <dmalloc.h>
15362 if { (eval echo "$as_me:15362: \"$ac_cpp conftest.$ac_ext\"") >&5
15363 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15365 egrep -v '^ *\+' conftest.er1 >conftest.err
15367 cat conftest.err >&5
15368 echo "$as_me:15368: \$? = $ac_status" >&5
15369 (exit $ac_status); } >/dev/null; then
15370 if test -s conftest.err; then
15371 ac_cpp_err=$ac_c_preproc_warn_flag
15378 if test -z "$ac_cpp_err"; then
15379 ac_cv_header_dmalloc_h=yes
15381 echo "$as_me: failed program was:" >&5
15382 cat conftest.$ac_ext >&5
15383 ac_cv_header_dmalloc_h=no
15385 rm -f conftest.err conftest.$ac_ext
15387 echo "$as_me:15387: result: $ac_cv_header_dmalloc_h" >&5
15388 echo "${ECHO_T}$ac_cv_header_dmalloc_h" >&6
15389 if test $ac_cv_header_dmalloc_h = yes; then
15391 echo "$as_me:15391: checking for dmalloc_debug in -ldmalloc" >&5
15392 echo $ECHO_N "checking for dmalloc_debug in -ldmalloc... $ECHO_C" >&6
15393 if test "${ac_cv_lib_dmalloc_dmalloc_debug+set}" = set; then
15394 echo $ECHO_N "(cached) $ECHO_C" >&6
15396 ac_check_lib_save_LIBS=$LIBS
15397 LIBS="-ldmalloc $LIBS"
15398 cat >conftest.$ac_ext <<_ACEOF
15399 #line 15399 "configure"
15400 #include "confdefs.h"
15402 /* Override any gcc2 internal prototype to avoid an error. */
15406 /* We use char because int might match the return type of a gcc2
15407 builtin and then its argument prototype would still apply. */
15408 char dmalloc_debug ();
15417 rm -f conftest.$ac_objext conftest$ac_exeext
15418 if { (eval echo "$as_me:15418: \"$ac_link\"") >&5
15419 (eval $ac_link) 2>&5
15421 echo "$as_me:15421: \$? = $ac_status" >&5
15422 (exit $ac_status); } &&
15423 { ac_try='test -s conftest$ac_exeext'
15424 { (eval echo "$as_me:15424: \"$ac_try\"") >&5
15425 (eval $ac_try) 2>&5
15427 echo "$as_me:15427: \$? = $ac_status" >&5
15428 (exit $ac_status); }; }; then
15429 ac_cv_lib_dmalloc_dmalloc_debug=yes
15431 echo "$as_me: failed program was:" >&5
15432 cat conftest.$ac_ext >&5
15433 ac_cv_lib_dmalloc_dmalloc_debug=no
15435 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15436 LIBS=$ac_check_lib_save_LIBS
15438 echo "$as_me:15438: result: $ac_cv_lib_dmalloc_dmalloc_debug" >&5
15439 echo "${ECHO_T}$ac_cv_lib_dmalloc_dmalloc_debug" >&6
15440 if test $ac_cv_lib_dmalloc_dmalloc_debug = yes; then
15441 cat >>confdefs.h <<EOF
15442 #define HAVE_LIBDMALLOC 1
15445 LIBS="-ldmalloc $LIBS"
15453 echo "$as_me:15453: checking if you want to use dbmalloc for testing" >&5
15454 echo $ECHO_N "checking if you want to use dbmalloc for testing... $ECHO_C" >&6
15456 # Check whether --with-dbmalloc or --without-dbmalloc was given.
15457 if test "${with_dbmalloc+set}" = set; then
15458 withval="$with_dbmalloc"
15460 cat >>confdefs.h <<EOF
15461 #define USE_DBMALLOC 1
15464 : ${with_cflags:=-g}
15465 : ${with_no_leaks:=yes}
15470 echo "$as_me:15470: result: ${with_dbmalloc:-no}" >&5
15471 echo "${ECHO_T}${with_dbmalloc:-no}" >&6
15473 case .$with_cflags in #(vi
15475 case .$CFLAGS in #(vi
15483 cf_new_extra_cppflags=
15485 for cf_add_cflags in -g
15487 case $cf_fix_cppflags in
15489 case $cf_add_cflags in #(vi
15490 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
15491 case $cf_add_cflags in
15493 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
15495 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
15496 && test -z "${cf_tst_cflags}" \
15497 && cf_fix_cppflags=yes
15499 if test $cf_fix_cppflags = yes ; then
15500 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
15502 elif test "${cf_tst_cflags}" = "\"'" ; then
15503 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
15508 case "$CPPFLAGS" in
15509 *$cf_add_cflags) #(vi
15512 case $cf_add_cflags in #(vi
15514 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
15516 CPPFLAGS=`echo "$CPPFLAGS" | \
15517 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
15518 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
15522 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
15527 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
15532 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
15534 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
15536 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
15537 && test -z "${cf_tst_cflags}" \
15538 && cf_fix_cppflags=no
15543 if test -n "$cf_new_cflags" ; then
15545 CFLAGS="$CFLAGS $cf_new_cflags"
15548 if test -n "$cf_new_cppflags" ; then
15550 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
15553 if test -n "$cf_new_extra_cppflags" ; then
15555 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
15563 if test "$with_dbmalloc" = yes ; then
15564 echo "$as_me:15564: checking for dbmalloc.h" >&5
15565 echo $ECHO_N "checking for dbmalloc.h... $ECHO_C" >&6
15566 if test "${ac_cv_header_dbmalloc_h+set}" = set; then
15567 echo $ECHO_N "(cached) $ECHO_C" >&6
15569 cat >conftest.$ac_ext <<_ACEOF
15570 #line 15570 "configure"
15571 #include "confdefs.h"
15572 #include <dbmalloc.h>
15574 if { (eval echo "$as_me:15574: \"$ac_cpp conftest.$ac_ext\"") >&5
15575 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15577 egrep -v '^ *\+' conftest.er1 >conftest.err
15579 cat conftest.err >&5
15580 echo "$as_me:15580: \$? = $ac_status" >&5
15581 (exit $ac_status); } >/dev/null; then
15582 if test -s conftest.err; then
15583 ac_cpp_err=$ac_c_preproc_warn_flag
15590 if test -z "$ac_cpp_err"; then
15591 ac_cv_header_dbmalloc_h=yes
15593 echo "$as_me: failed program was:" >&5
15594 cat conftest.$ac_ext >&5
15595 ac_cv_header_dbmalloc_h=no
15597 rm -f conftest.err conftest.$ac_ext
15599 echo "$as_me:15599: result: $ac_cv_header_dbmalloc_h" >&5
15600 echo "${ECHO_T}$ac_cv_header_dbmalloc_h" >&6
15601 if test $ac_cv_header_dbmalloc_h = yes; then
15603 echo "$as_me:15603: checking for debug_malloc in -ldbmalloc" >&5
15604 echo $ECHO_N "checking for debug_malloc in -ldbmalloc... $ECHO_C" >&6
15605 if test "${ac_cv_lib_dbmalloc_debug_malloc+set}" = set; then
15606 echo $ECHO_N "(cached) $ECHO_C" >&6
15608 ac_check_lib_save_LIBS=$LIBS
15609 LIBS="-ldbmalloc $LIBS"
15610 cat >conftest.$ac_ext <<_ACEOF
15611 #line 15611 "configure"
15612 #include "confdefs.h"
15614 /* Override any gcc2 internal prototype to avoid an error. */
15618 /* We use char because int might match the return type of a gcc2
15619 builtin and then its argument prototype would still apply. */
15620 char debug_malloc ();
15629 rm -f conftest.$ac_objext conftest$ac_exeext
15630 if { (eval echo "$as_me:15630: \"$ac_link\"") >&5
15631 (eval $ac_link) 2>&5
15633 echo "$as_me:15633: \$? = $ac_status" >&5
15634 (exit $ac_status); } &&
15635 { ac_try='test -s conftest$ac_exeext'
15636 { (eval echo "$as_me:15636: \"$ac_try\"") >&5
15637 (eval $ac_try) 2>&5
15639 echo "$as_me:15639: \$? = $ac_status" >&5
15640 (exit $ac_status); }; }; then
15641 ac_cv_lib_dbmalloc_debug_malloc=yes
15643 echo "$as_me: failed program was:" >&5
15644 cat conftest.$ac_ext >&5
15645 ac_cv_lib_dbmalloc_debug_malloc=no
15647 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15648 LIBS=$ac_check_lib_save_LIBS
15650 echo "$as_me:15650: result: $ac_cv_lib_dbmalloc_debug_malloc" >&5
15651 echo "${ECHO_T}$ac_cv_lib_dbmalloc_debug_malloc" >&6
15652 if test $ac_cv_lib_dbmalloc_debug_malloc = yes; then
15653 cat >>confdefs.h <<EOF
15654 #define HAVE_LIBDBMALLOC 1
15657 LIBS="-ldbmalloc $LIBS"
15665 echo "$as_me:15665: checking if you want to use valgrind for testing" >&5
15666 echo $ECHO_N "checking if you want to use valgrind for testing... $ECHO_C" >&6
15668 # Check whether --with-valgrind or --without-valgrind was given.
15669 if test "${with_valgrind+set}" = set; then
15670 withval="$with_valgrind"
15672 cat >>confdefs.h <<EOF
15673 #define USE_VALGRIND 1
15676 : ${with_cflags:=-g}
15677 : ${with_no_leaks:=yes}
15682 echo "$as_me:15682: result: ${with_valgrind:-no}" >&5
15683 echo "${ECHO_T}${with_valgrind:-no}" >&6
15685 case .$with_cflags in #(vi
15687 case .$CFLAGS in #(vi
15695 cf_new_extra_cppflags=
15697 for cf_add_cflags in -g
15699 case $cf_fix_cppflags in
15701 case $cf_add_cflags in #(vi
15702 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
15703 case $cf_add_cflags in
15705 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
15707 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
15708 && test -z "${cf_tst_cflags}" \
15709 && cf_fix_cppflags=yes
15711 if test $cf_fix_cppflags = yes ; then
15712 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
15714 elif test "${cf_tst_cflags}" = "\"'" ; then
15715 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
15720 case "$CPPFLAGS" in
15721 *$cf_add_cflags) #(vi
15724 case $cf_add_cflags in #(vi
15726 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
15728 CPPFLAGS=`echo "$CPPFLAGS" | \
15729 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
15730 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
15734 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
15739 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
15744 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
15746 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
15748 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
15749 && test -z "${cf_tst_cflags}" \
15750 && cf_fix_cppflags=no
15755 if test -n "$cf_new_cflags" ; then
15757 CFLAGS="$CFLAGS $cf_new_cflags"
15760 if test -n "$cf_new_cppflags" ; then
15762 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
15765 if test -n "$cf_new_extra_cppflags" ; then
15767 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
15775 echo "$as_me:15775: checking if you want to perform memory-leak testing" >&5
15776 echo $ECHO_N "checking if you want to perform memory-leak testing... $ECHO_C" >&6
15778 # Check whether --enable-leaks or --disable-leaks was given.
15779 if test "${enable_leaks+set}" = set; then
15780 enableval="$enable_leaks"
15781 if test "x$enableval" = xno; then with_no_leaks=yes; else with_no_leaks=no; fi
15783 : ${with_no_leaks:=no}
15785 echo "$as_me:15785: result: $with_no_leaks" >&5
15786 echo "${ECHO_T}$with_no_leaks" >&6
15788 if test "$with_no_leaks" = yes ; then
15790 cat >>confdefs.h <<\EOF
15794 cat >>confdefs.h <<\EOF
15795 #define YY_NO_LEAKS 1
15801 echo "$as_me:15801: checking for an rpath option" >&5
15802 echo $ECHO_N "checking for an rpath option... $ECHO_C" >&6
15803 case $cf_cv_system_name in #(vi
15805 if test "$GCC" = yes; then
15806 LD_RPATH_OPT="-Wl,-rpath,"
15808 LD_RPATH_OPT="-rpath "
15811 linux*|gnu*|k*bsd*-gnu) #(vi
15812 LD_RPATH_OPT="-Wl,-rpath,"
15814 openbsd[2-9].*|mirbsd*) #(vi
15815 LD_RPATH_OPT="-Wl,-rpath,"
15817 dragonfly*|freebsd*) #(vi
15818 LD_RPATH_OPT="-rpath "
15821 LD_RPATH_OPT="-Wl,-rpath,"
15824 LD_RPATH_OPT="-rpath "
15832 echo "$as_me:15832: result: $LD_RPATH_OPT" >&5
15833 echo "${ECHO_T}$LD_RPATH_OPT" >&6
15835 case "x$LD_RPATH_OPT" in #(vi
15837 echo "$as_me:15837: checking if we need a space after rpath option" >&5
15838 echo $ECHO_N "checking if we need a space after rpath option... $ECHO_C" >&6
15839 cf_save_LIBS="$LIBS"
15840 LIBS="${LD_RPATH_OPT}$libdir $LIBS"
15841 cat >conftest.$ac_ext <<_ACEOF
15842 #line 15842 "configure"
15843 #include "confdefs.h"
15853 rm -f conftest.$ac_objext conftest$ac_exeext
15854 if { (eval echo "$as_me:15854: \"$ac_link\"") >&5
15855 (eval $ac_link) 2>&5
15857 echo "$as_me:15857: \$? = $ac_status" >&5
15858 (exit $ac_status); } &&
15859 { ac_try='test -s conftest$ac_exeext'
15860 { (eval echo "$as_me:15860: \"$ac_try\"") >&5
15861 (eval $ac_try) 2>&5
15863 echo "$as_me:15863: \$? = $ac_status" >&5
15864 (exit $ac_status); }; }; then
15867 echo "$as_me: failed program was:" >&5
15868 cat conftest.$ac_ext >&5
15871 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15872 LIBS="$cf_save_LIBS"
15873 echo "$as_me:15873: result: $cf_rpath_space" >&5
15874 echo "${ECHO_T}$cf_rpath_space" >&6
15875 test "$cf_rpath_space" = yes && LD_RPATH_OPT="$LD_RPATH_OPT "
15879 echo "$as_me:15879: checking if rpath-hack should be disabled" >&5
15880 echo $ECHO_N "checking if rpath-hack should be disabled... $ECHO_C" >&6
15882 # Check whether --enable-rpath-hack or --disable-rpath-hack was given.
15883 if test "${enable_rpath_hack+set}" = set; then
15884 enableval="$enable_rpath_hack"
15885 test "$enableval" != no && enableval=yes
15886 if test "$enableval" != "yes" ; then
15887 cf_disable_rpath_hack=yes
15889 cf_disable_rpath_hack=no
15893 cf_disable_rpath_hack=no
15896 echo "$as_me:15896: result: $cf_disable_rpath_hack" >&5
15897 echo "${ECHO_T}$cf_disable_rpath_hack" >&6
15898 if test "$cf_disable_rpath_hack" = no ; then
15900 echo "$as_me:15900: checking for updated LDFLAGS" >&5
15901 echo $ECHO_N "checking for updated LDFLAGS... $ECHO_C" >&6
15902 if test -n "$LD_RPATH_OPT" ; then
15903 echo "$as_me:15903: result: maybe" >&5
15904 echo "${ECHO_T}maybe" >&6
15908 # Extract the first word of "$ac_prog", so it can be a program name with args.
15909 set dummy $ac_prog; ac_word=$2
15910 echo "$as_me:15910: checking for $ac_word" >&5
15911 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
15912 if test "${ac_cv_prog_cf_ldd_prog+set}" = set; then
15913 echo $ECHO_N "(cached) $ECHO_C" >&6
15915 if test -n "$cf_ldd_prog"; then
15916 ac_cv_prog_cf_ldd_prog="$cf_ldd_prog" # Let the user override the test.
15918 ac_save_IFS=$IFS; IFS=$ac_path_separator
15920 for ac_dir in $ac_dummy; do
15922 test -z "$ac_dir" && ac_dir=.
15923 $as_executable_p "$ac_dir/$ac_word" || continue
15924 ac_cv_prog_cf_ldd_prog="$ac_prog"
15925 echo "$as_me:15925: found $ac_dir/$ac_word" >&5
15931 cf_ldd_prog=$ac_cv_prog_cf_ldd_prog
15932 if test -n "$cf_ldd_prog"; then
15933 echo "$as_me:15933: result: $cf_ldd_prog" >&5
15934 echo "${ECHO_T}$cf_ldd_prog" >&6
15936 echo "$as_me:15936: result: no" >&5
15937 echo "${ECHO_T}no" >&6
15940 test -n "$cf_ldd_prog" && break
15942 test -n "$cf_ldd_prog" || cf_ldd_prog="no"
15944 cf_rpath_list="/usr/lib /lib"
15945 if test "$cf_ldd_prog" != no
15949 cat >conftest.$ac_ext <<_ACEOF
15950 #line 15950 "configure"
15951 #include "confdefs.h"
15961 rm -f conftest.$ac_objext conftest$ac_exeext
15962 if { (eval echo "$as_me:15962: \"$ac_link\"") >&5
15963 (eval $ac_link) 2>&5
15965 echo "$as_me:15965: \$? = $ac_status" >&5
15966 (exit $ac_status); } &&
15967 { ac_try='test -s conftest$ac_exeext'
15968 { (eval echo "$as_me:15968: \"$ac_try\"") >&5
15969 (eval $ac_try) 2>&5
15971 echo "$as_me:15971: \$? = $ac_status" >&5
15972 (exit $ac_status); }; }; then
15973 cf_rpath_oops=`$cf_ldd_prog conftest$ac_exeext | fgrep ' not found' | sed -e 's% =>.*$%%' |sort | uniq`
15974 cf_rpath_list=`$cf_ldd_prog conftest$ac_exeext | fgrep / | sed -e 's%^.*[ ]/%/%' -e 's%/[^/][^/]*$%%' |sort | uniq`
15976 echo "$as_me: failed program was:" >&5
15977 cat conftest.$ac_ext >&5
15979 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15981 # If we passed the link-test, but get a "not found" on a given library,
15982 # this could be due to inept reconfiguration of gcc to make it only
15983 # partly honor /usr/local/lib (or whatever). Sometimes this behavior
15984 # is intentional, e.g., installing gcc in /usr/bin and suppressing the
15985 # /usr/local libraries.
15986 if test -n "$cf_rpath_oops"
15988 for cf_rpath_src in $cf_rpath_oops
15990 for cf_rpath_dir in \
15995 if test -f $cf_rpath_dir/lib/$cf_rpath_src
15997 test -n "$verbose" && echo " ...adding -L$cf_rpath_dir/lib to LDFLAGS for $cf_rpath_src" 1>&6
15999 echo "${as_me:-configure}:15999: testing ...adding -L$cf_rpath_dir/lib to LDFLAGS for $cf_rpath_src ..." 1>&5
16001 LDFLAGS="$LDFLAGS -L$cf_rpath_dir/lib"
16009 test -n "$verbose" && echo " ...checking EXTRA_LDFLAGS $EXTRA_LDFLAGS" 1>&6
16011 echo "${as_me:-configure}:16011: testing ...checking EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5
16013 test -n "$verbose" && echo " ...checking LDFLAGS $LDFLAGS" 1>&6
16015 echo "${as_me:-configure}:16015: testing ...checking LDFLAGS $LDFLAGS ..." 1>&5
16018 for cf_rpath_src in $LDFLAGS
16020 case $cf_rpath_src in #(vi
16023 # check if this refers to a directory which we will ignore
16025 if test -n "$cf_rpath_list"
16027 for cf_rpath_item in $cf_rpath_list
16029 if test "x$cf_rpath_src" = "x-L$cf_rpath_item"
16037 if test "$cf_rpath_skip" = no
16039 # transform the option
16040 if test "$LD_RPATH_OPT" = "-R " ; then
16041 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%-R %"`
16043 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%$LD_RPATH_OPT%"`
16046 # if we have not already added this, add it now
16047 cf_rpath_tst=`echo "$EXTRA_LDFLAGS" | sed -e "s%$cf_rpath_tmp %%"`
16048 if test "x$cf_rpath_tst" = "x$EXTRA_LDFLAGS"
16050 test -n "$verbose" && echo " ...Filter $cf_rpath_src ->$cf_rpath_tmp" 1>&6
16052 echo "${as_me:-configure}:16052: testing ...Filter $cf_rpath_src ->$cf_rpath_tmp ..." 1>&5
16054 EXTRA_LDFLAGS="$cf_rpath_tmp $EXTRA_LDFLAGS"
16059 cf_rpath_dst="$cf_rpath_dst $cf_rpath_src"
16061 LDFLAGS=$cf_rpath_dst
16063 test -n "$verbose" && echo " ...checked LDFLAGS $LDFLAGS" 1>&6
16065 echo "${as_me:-configure}:16065: testing ...checked LDFLAGS $LDFLAGS ..." 1>&5
16067 test -n "$verbose" && echo " ...checking LIBS $LIBS" 1>&6
16069 echo "${as_me:-configure}:16069: testing ...checking LIBS $LIBS ..." 1>&5
16072 for cf_rpath_src in $LIBS
16074 case $cf_rpath_src in #(vi
16077 # check if this refers to a directory which we will ignore
16079 if test -n "$cf_rpath_list"
16081 for cf_rpath_item in $cf_rpath_list
16083 if test "x$cf_rpath_src" = "x-L$cf_rpath_item"
16091 if test "$cf_rpath_skip" = no
16093 # transform the option
16094 if test "$LD_RPATH_OPT" = "-R " ; then
16095 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%-R %"`
16097 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%$LD_RPATH_OPT%"`
16100 # if we have not already added this, add it now
16101 cf_rpath_tst=`echo "$EXTRA_LDFLAGS" | sed -e "s%$cf_rpath_tmp %%"`
16102 if test "x$cf_rpath_tst" = "x$EXTRA_LDFLAGS"
16104 test -n "$verbose" && echo " ...Filter $cf_rpath_src ->$cf_rpath_tmp" 1>&6
16106 echo "${as_me:-configure}:16106: testing ...Filter $cf_rpath_src ->$cf_rpath_tmp ..." 1>&5
16108 EXTRA_LDFLAGS="$cf_rpath_tmp $EXTRA_LDFLAGS"
16113 cf_rpath_dst="$cf_rpath_dst $cf_rpath_src"
16117 test -n "$verbose" && echo " ...checked LIBS $LIBS" 1>&6
16119 echo "${as_me:-configure}:16119: testing ...checked LIBS $LIBS ..." 1>&5
16121 test -n "$verbose" && echo " ...checked EXTRA_LDFLAGS $EXTRA_LDFLAGS" 1>&6
16123 echo "${as_me:-configure}:16123: testing ...checked EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5
16126 echo "$as_me:16126: result: no" >&5
16127 echo "${ECHO_T}no" >&6
16135 ac_config_files="$ac_config_files Makefile"
16136 ac_config_commands="$ac_config_commands default"
16137 cat >confcache <<\_ACEOF
16138 # This file is a shell script that caches the results of configure
16139 # tests run on this system so they can be shared between configure
16140 # scripts and configure runs, see configure's option --config-cache.
16141 # It is not useful on other systems. If it contains results you don't
16142 # want to keep, you may remove or edit it.
16144 # config.status only pays attention to the cache file if you give it
16145 # the --recheck option to rerun configure.
16147 # `ac_cv_env_foo' variables (set or unset) will be overriden when
16148 # loading this file, other *unset* `ac_cv_foo' will be assigned the
16149 # following values.
16153 # The following way of writing the cache mishandles newlines in values,
16154 # but we know of no workaround that is simple, portable, and efficient.
16155 # So, don't put newlines in cache variables' values.
16156 # Ultrix sh set writes to stderr and can't be redirected directly,
16157 # and sets the high bit in the cache file unless we assign to the vars.
16160 case `(ac_space=' '; set | grep ac_space) 2>&1` in
16162 # `set' does not quote correctly, so add quotes (double-quote
16163 # substitution turns \\\\ into \\, and sed turns \\ into \).
16166 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
16169 # `set' quotes correctly as required by POSIX, so do not add quotes.
16171 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
16178 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
16180 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
16182 if cmp -s $cache_file confcache; then :; else
16183 if test -w $cache_file; then
16184 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
16185 cat confcache >$cache_file
16187 echo "not updating unwritable cache $cache_file"
16192 test "x$prefix" = xNONE && prefix=$ac_default_prefix
16193 # Let make expand exec_prefix.
16194 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
16196 # VPATH may cause trouble with some makes, so we remove $(srcdir),
16197 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
16198 # trailing colons and then remove the whole line if VPATH becomes empty
16199 # (actually we leave an empty line to preserve line numbers).
16200 if test "x$srcdir" = x.; then
16201 ac_vpsub='/^[ ]*VPATH[ ]*=/{
16202 s/:*\$(srcdir):*/:/;
16203 s/:*\${srcdir}:*/:/;
16205 s/^\([^=]*=[ ]*\):*/\1/;
16211 DEFS=-DHAVE_CONFIG_H
16213 : ${CONFIG_STATUS=./config.status}
16214 ac_clean_files_save=$ac_clean_files
16215 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
16216 { echo "$as_me:16216: creating $CONFIG_STATUS" >&5
16217 echo "$as_me: creating $CONFIG_STATUS" >&6;}
16218 cat >$CONFIG_STATUS <<_ACEOF
16220 # Generated automatically by configure.
16221 # Run this file to recreate the current configuration.
16222 # Compiler output produced by configure, useful for debugging
16223 # configure, is in config.log if it exists.
16226 SHELL=\${CONFIG_SHELL-$SHELL}
16227 ac_cs_invocation="\$0 \$@"
16231 cat >>$CONFIG_STATUS <<\_ACEOF
16232 # Be Bourne compatible
16233 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
16236 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
16240 # Name of the executable.
16241 as_me=`echo "$0" |sed 's,.*[\\/],,'`
16243 if expr a : '\(a\)' >/dev/null 2>&1; then
16249 rm -f conf$$ conf$$.exe conf$$.file
16251 if ln -s conf$$.file conf$$ 2>/dev/null; then
16252 # We could just check for DJGPP; but this test a) works b) is more generic
16253 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
16254 if test -f conf$$.exe; then
16255 # Don't use ln at all; we don't have any links
16260 elif ln conf$$.file conf$$ 2>/dev/null; then
16265 rm -f conf$$ conf$$.exe conf$$.file
16267 as_executable_p="test -f"
16269 # Support unset when possible.
16270 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
16277 $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
16278 $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
16279 $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
16280 $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
16281 $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
16282 $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
16283 $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
16284 $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
16287 # We need space, tab and new line, in precisely that order.
16293 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
16299 # Files that config.status was made for.
16300 if test -n "$ac_config_files"; then
16301 echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
16304 if test -n "$ac_config_headers"; then
16305 echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
16308 if test -n "$ac_config_links"; then
16309 echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
16312 if test -n "$ac_config_commands"; then
16313 echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
16316 cat >>$CONFIG_STATUS <<\EOF
16319 \`$as_me' instantiates files from templates according to the
16320 current configuration.
16322 Usage: $0 [OPTIONS] [FILE]...
16324 -h, --help print this help, then exit
16325 -V, --version print version number, then exit
16326 -d, --debug don't remove temporary files
16327 --recheck update $as_me by reconfiguring in the same conditions
16328 --file=FILE[:TEMPLATE]
16329 instantiate the configuration file FILE
16330 --header=FILE[:TEMPLATE]
16331 instantiate the configuration header FILE
16333 Configuration files:
16336 Configuration headers:
16339 Configuration commands:
16342 Report bugs to <dickey@invisible-island.net>."
16345 cat >>$CONFIG_STATUS <<EOF
16348 configured by $0, generated by GNU Autoconf 2.52.20121002,
16349 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
16351 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
16352 Free Software Foundation, Inc.
16353 This config.status script is free software; the Free Software Foundation
16354 gives unlimited permission to copy, distribute and modify it."
16359 cat >>$CONFIG_STATUS <<\EOF
16360 # If no file are specified by the user, then we need to provide default
16361 # value. By we need to know if files were specified by the user.
16367 ac_option=`expr "x$1" : 'x\([^=]*\)='`
16368 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
16370 set dummy "$ac_option" "$ac_optarg" ${1+"$@"}
16374 *) # This is not an option, so the user has probably given explicit
16376 ac_need_defaults=false;;
16380 # Handling of the options.
16382 cat >>$CONFIG_STATUS <<EOF
16383 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
16384 echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion"
16385 exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;;
16387 cat >>$CONFIG_STATUS <<\EOF
16388 --version | --vers* | -V )
16389 echo "$ac_cs_version"; exit 0 ;;
16391 # Conflict between --help and --header
16392 { { echo "$as_me:16392: error: ambiguous option: $1
16393 Try \`$0 --help' for more information." >&5
16394 echo "$as_me: error: ambiguous option: $1
16395 Try \`$0 --help' for more information." >&2;}
16396 { (exit 1); exit 1; }; };;
16397 --help | --hel | -h )
16398 echo "$ac_cs_usage"; exit 0 ;;
16399 --debug | --d* | -d )
16401 --file | --fil | --fi | --f )
16403 CONFIG_FILES="$CONFIG_FILES $1"
16404 ac_need_defaults=false;;
16405 --header | --heade | --head | --hea )
16407 CONFIG_HEADERS="$CONFIG_HEADERS $1"
16408 ac_need_defaults=false;;
16410 # This is an error.
16411 -*) { { echo "$as_me:16411: error: unrecognized option: $1
16412 Try \`$0 --help' for more information." >&5
16413 echo "$as_me: error: unrecognized option: $1
16414 Try \`$0 --help' for more information." >&2;}
16415 { (exit 1); exit 1; }; } ;;
16417 *) ac_config_targets="$ac_config_targets $1" ;;
16426 ## ----------------------- ##
16427 ## Running config.status. ##
16428 ## ----------------------- ##
16430 This file was extended by $as_me 2.52.20121002, executed with
16431 CONFIG_FILES = $CONFIG_FILES
16432 CONFIG_HEADERS = $CONFIG_HEADERS
16433 CONFIG_LINKS = $CONFIG_LINKS
16434 CONFIG_COMMANDS = $CONFIG_COMMANDS
16435 > $ac_cs_invocation
16436 on `(hostname || uname -n) 2>/dev/null | sed 1q`
16441 cat >>$CONFIG_STATUS <<EOF
16443 # INIT-COMMANDS section.
16453 cat >>$CONFIG_STATUS <<\EOF
16454 for ac_config_target in $ac_config_targets
16456 case "$ac_config_target" in
16457 # Handling of arguments.
16458 "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
16459 "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
16460 "ncurses_cfg.h" ) CONFIG_HEADERS="$CONFIG_HEADERS ncurses_cfg.h:ncurses_tst.hin" ;;
16461 *) { { echo "$as_me:16461: error: invalid argument: $ac_config_target" >&5
16462 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
16463 { (exit 1); exit 1; }; };;
16467 # If the user did not use the arguments to specify the items to instantiate,
16468 # then the envvar interface is used. Set only those that are not.
16469 # We use the long form for the default assignment because of an extremely
16470 # bizarre bug on SunOS 4.1.3.
16471 if $ac_need_defaults; then
16472 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
16473 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
16474 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
16477 # Create a temporary directory, and hook for its removal unless debugging.
16480 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
16481 trap '{ (exit 1); exit 1; }' 1 2 13 15
16484 # Create a (secure) tmp directory for tmp files.
16487 tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` &&
16488 test -n "$tmp" && test -d "$tmp"
16491 tmp=$TMPDIR/cs$$-$RANDOM
16492 (umask 077 && mkdir $tmp)
16495 echo "$me: cannot create a temporary directory in $TMPDIR" >&2
16496 { (exit 1); exit 1; }
16501 cat >>$CONFIG_STATUS <<EOF
16504 # CONFIG_FILES section.
16507 # No need to generate the scripts if there are no CONFIG_FILES.
16508 # This happens for instance when ./config.status config.h
16509 if test -n "\$CONFIG_FILES"; then
16510 # Protect against being on the right side of a sed subst in config.status.
16511 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
16512 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
16513 s,@SHELL@,$SHELL,;t t
16514 s,@exec_prefix@,$exec_prefix,;t t
16515 s,@prefix@,$prefix,;t t
16516 s,@program_transform_name@,$program_transform_name,;t t
16517 s,@bindir@,$bindir,;t t
16518 s,@sbindir@,$sbindir,;t t
16519 s,@libexecdir@,$libexecdir,;t t
16520 s,@datarootdir@,$datarootdir,;t t
16521 s,@datadir@,$datadir,;t t
16522 s,@sysconfdir@,$sysconfdir,;t t
16523 s,@sharedstatedir@,$sharedstatedir,;t t
16524 s,@localstatedir@,$localstatedir,;t t
16525 s,@libdir@,$libdir,;t t
16526 s,@includedir@,$includedir,;t t
16527 s,@oldincludedir@,$oldincludedir,;t t
16528 s,@infodir@,$infodir,;t t
16529 s,@mandir@,$mandir,;t t
16530 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
16531 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
16532 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
16533 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
16534 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
16535 s,@build_alias@,$build_alias,;t t
16536 s,@host_alias@,$host_alias,;t t
16537 s,@target_alias@,$target_alias,;t t
16538 s,@ECHO_C@,$ECHO_C,;t t
16539 s,@ECHO_N@,$ECHO_N,;t t
16540 s,@ECHO_T@,$ECHO_T,;t t
16541 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
16542 s,@DEFS@,$DEFS,;t t
16543 s,@LIBS@,$LIBS,;t t
16544 s,@build@,$build,;t t
16545 s,@build_cpu@,$build_cpu,;t t
16546 s,@build_vendor@,$build_vendor,;t t
16547 s,@build_os@,$build_os,;t t
16548 s,@host@,$host,;t t
16549 s,@host_cpu@,$host_cpu,;t t
16550 s,@host_vendor@,$host_vendor,;t t
16551 s,@host_os@,$host_os,;t t
16552 s,@SET_MAKE@,$SET_MAKE,;t t
16554 s,@CFLAGS@,$CFLAGS,;t t
16555 s,@LDFLAGS@,$LDFLAGS,;t t
16556 s,@CPPFLAGS@,$CPPFLAGS,;t t
16557 s,@ac_ct_CC@,$ac_ct_CC,;t t
16558 s,@EXEEXT@,$EXEEXT,;t t
16559 s,@OBJEXT@,$OBJEXT,;t t
16560 s,@EXTRA_CPPFLAGS@,$EXTRA_CPPFLAGS,;t t
16563 s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
16564 s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
16565 s,@INSTALL_DATA@,$INSTALL_DATA,;t t
16566 s,@LINT@,$LINT,;t t
16567 s,@LINT_OPTS@,$LINT_OPTS,;t t
16568 s,@CTAGS@,$CTAGS,;t t
16569 s,@ETAGS@,$ETAGS,;t t
16570 s,@MAKE_LOWER_TAGS@,$MAKE_LOWER_TAGS,;t t
16571 s,@MAKE_UPPER_TAGS@,$MAKE_UPPER_TAGS,;t t
16572 s,@MATH_LIB@,$MATH_LIB,;t t
16573 s,@top_builddir@,$top_builddir,;t t
16574 s,@CC_G_OPT@,$CC_G_OPT,;t t
16575 s,@CC_SHARED_OPTS@,$CC_SHARED_OPTS,;t t
16576 s,@DFT_DEP_SUFFIX@,$DFT_DEP_SUFFIX,;t t
16577 s,@DFT_OBJ_SUBDIR@,$DFT_OBJ_SUBDIR,;t t
16578 s,@DFT_UPR_MODEL@,$DFT_UPR_MODEL,;t t
16580 s,@LDFLAGS_SHARED@,$LDFLAGS_SHARED,;t t
16581 s,@LDFLAGS_STATIC@,$LDFLAGS_STATIC,;t t
16582 s,@LD_MODEL@,$LD_MODEL,;t t
16583 s,@LD_SHARED_OPTS@,$LD_SHARED_OPTS,;t t
16584 s,@LIBTOOL@,$LIBTOOL,;t t
16585 s,@LIB_CLEAN@,$LIB_CLEAN,;t t
16586 s,@LIB_COMPILE@,$LIB_COMPILE,;t t
16587 s,@LIB_LINK@,$LIB_LINK,;t t
16588 s,@LINK_TESTS@,$LINK_TESTS,;t t
16589 s,@LOCAL_LDFLAGS@,$LOCAL_LDFLAGS,;t t
16590 s,@PTHREAD@,$PTHREAD,;t t
16591 s,@TEST_ARGS@,$TEST_ARGS,;t t
16592 s,@TEST_DEPS@,$TEST_DEPS,;t t
16593 s,@TEST_LIBS@,$TEST_LIBS,;t t
16594 s,@TINFO_LDFLAGS@,$TINFO_LDFLAGS,;t t
16595 s,@TINFO_LIBS@,$TINFO_LIBS,;t t
16596 s,@cf_cv_abi_version@,$cf_cv_abi_version,;t t
16597 s,@cf_cv_rel_version@,$cf_cv_rel_version,;t t
16598 s,@PKG_CONFIG@,$PKG_CONFIG,;t t
16599 s,@ac_pt_PKG_CONFIG@,$ac_pt_PKG_CONFIG,;t t
16600 s,@ECHO_LT@,$ECHO_LT,;t t
16601 s,@ECHO_LD@,$ECHO_LD,;t t
16602 s,@RULE_CC@,$RULE_CC,;t t
16603 s,@SHOW_CC@,$SHOW_CC,;t t
16604 s,@ECHO_CC@,$ECHO_CC,;t t
16605 s,@NCURSES_WRAP_PREFIX@,$NCURSES_WRAP_PREFIX,;t t
16606 s,@NCURSES_CONFIG@,$NCURSES_CONFIG,;t t
16607 s,@ac_ct_NCURSES_CONFIG@,$ac_ct_NCURSES_CONFIG,;t t
16608 s,@X_CFLAGS@,$X_CFLAGS,;t t
16609 s,@X_PRE_LIBS@,$X_PRE_LIBS,;t t
16610 s,@X_LIBS@,$X_LIBS,;t t
16611 s,@X_EXTRA_LIBS@,$X_EXTRA_LIBS,;t t
16612 s,@XCURSES_CONFIG@,$XCURSES_CONFIG,;t t
16613 s,@ac_ct_XCURSES_CONFIG@,$ac_ct_XCURSES_CONFIG,;t t
16614 s,@EXTRA_CFLAGS@,$EXTRA_CFLAGS,;t t
16615 s,@cf_ldd_prog@,$cf_ldd_prog,;t t
16616 s,@EXTRA_LDFLAGS@,$EXTRA_LDFLAGS,;t t
16621 cat >>$CONFIG_STATUS <<\EOF
16622 # Split the substitutions into bite-sized pieces for seds with
16623 # small command number limits, like on Digital OSF/1 and HP-UX.
16624 ac_max_sed_lines=48
16625 ac_sed_frag=1 # Number of current file.
16626 ac_beg=1 # First line for current file.
16627 ac_end=$ac_max_sed_lines # Line after last line for current file.
16630 while $ac_more_lines; do
16631 if test $ac_beg -gt 1; then
16632 sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
16634 sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
16636 if test ! -s $tmp/subs.frag; then
16637 ac_more_lines=false
16639 # The purpose of the label and of the branching condition is to
16640 # speed up the sed processing (if there are no `@' at all, there
16641 # is no need to browse any of the substitutions).
16642 # These are the two extra sed commands mentioned above.
16644 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
16645 if test -z "$ac_sed_cmds"; then
16646 ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
16648 ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
16650 ac_sed_frag=`expr $ac_sed_frag + 1`
16652 ac_end=`expr $ac_end + $ac_max_sed_lines`
16655 if test -z "$ac_sed_cmds"; then
16658 fi # test -n "$CONFIG_FILES"
16661 cat >>$CONFIG_STATUS <<\EOF
16662 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
16663 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
16665 - | *:- | *:-:* ) # input from stdin
16667 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
16668 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
16669 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
16670 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
16671 * ) ac_file_in=$ac_file.in ;;
16674 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
16675 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
16676 X"$ac_file" : 'X\(//\)[^/]' \| \
16677 X"$ac_file" : 'X\(//\)$' \| \
16678 X"$ac_file" : 'X\(/\)' \| \
16679 . : '\(.\)' 2>/dev/null ||
16681 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
16682 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
16683 /^X\(\/\/\)$/{ s//\1/; q; }
16684 /^X\(\/\).*/{ s//\1/; q; }
16686 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
16687 { case "$ac_dir" in
16688 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
16692 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
16693 case $as_mkdir_dir in
16694 # Skip DOS drivespec
16695 ?:) as_incr_dir=$as_mkdir_dir ;;
16697 as_incr_dir=$as_incr_dir/$as_mkdir_dir
16698 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
16703 ac_dir_suffix="/`echo $ac_dir|sed 's,^\./,,'`"
16704 # A "../" for each directory in $ac_dir_suffix.
16705 ac_dots=`echo "$ac_dir_suffix" | sed 's,/[^/]*,../,g'`
16707 ac_dir_suffix= ac_dots=
16712 if test -z "$ac_dots"; then
16715 ac_top_srcdir=`echo $ac_dots | sed 's,/$,,'`
16717 [\\/]* | ?:[\\/]* )
16718 ac_srcdir=$srcdir$ac_dir_suffix;
16719 ac_top_srcdir=$srcdir ;;
16720 *) # Relative path.
16721 ac_srcdir=$ac_dots$srcdir$ac_dir_suffix
16722 ac_top_srcdir=$ac_dots$srcdir ;;
16726 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
16727 *) ac_INSTALL=$ac_dots$INSTALL ;;
16730 if test x"$ac_file" != x-; then
16731 { echo "$as_me:16731: creating $ac_file" >&5
16732 echo "$as_me: creating $ac_file" >&6;}
16735 # Let's still pretend it is `configure' which instantiates (i.e., don't
16736 # use $as_me), people would be surprised to read:
16737 # /* config.h. Generated automatically by config.status. */
16738 configure_input="Generated automatically from `echo $ac_file_in |
16739 sed 's,.*/,,'` by configure."
16741 # First look for the input files in the build tree, otherwise in the
16743 ac_file_inputs=`IFS=:
16744 for f in $ac_file_in; do
16746 -) echo $tmp/stdin ;;
16748 # Absolute (can't be DOS-style, as IFS=:)
16749 test -f "$f" || { { echo "$as_me:16749: error: cannot find input file: $f" >&5
16750 echo "$as_me: error: cannot find input file: $f" >&2;}
16751 { (exit 1); exit 1; }; }
16754 if test -f "$f"; then
16757 elif test -f "$srcdir/$f"; then
16762 { { echo "$as_me:16762: error: cannot find input file: $f" >&5
16763 echo "$as_me: error: cannot find input file: $f" >&2;}
16764 { (exit 1); exit 1; }; }
16767 done` || { (exit 1); exit 1; }
16769 cat >>$CONFIG_STATUS <<\EOF
16770 ac_warn_datarootdir=no
16771 if test x"$ac_file" != x-; then
16772 for ac_item in $ac_file_inputs
16774 ac_seen=`grep '@\(datadir\|mandir\|infodir\)@' $ac_item`
16775 if test -n "$ac_seen"; then
16776 ac_used=`grep '@datarootdir@' $ac_item`
16777 if test -z "$ac_used"; then
16778 { echo "$as_me:16778: WARNING: datarootdir was used implicitly but not set:
16780 echo "$as_me: WARNING: datarootdir was used implicitly but not set:
16782 ac_warn_datarootdir=yes
16785 ac_seen=`grep '${datarootdir}' $ac_item`
16786 if test -n "$ac_seen"; then
16787 { echo "$as_me:16787: WARNING: datarootdir was used explicitly but not set:
16789 echo "$as_me: WARNING: datarootdir was used explicitly but not set:
16791 ac_warn_datarootdir=yes
16796 if test "x$ac_warn_datarootdir" = xyes; then
16797 ac_sed_cmds="$ac_sed_cmds | sed -e 's,@datarootdir@,\${prefix}/share,g' -e 's,\${datarootdir},\${prefix}/share,g'"
16801 cat >>$CONFIG_STATUS <<EOF
16805 cat >>$CONFIG_STATUS <<\EOF
16807 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
16808 s,@configure_input@,$configure_input,;t t
16809 s,@srcdir@,$ac_srcdir,;t t
16810 s,@top_srcdir@,$ac_top_srcdir,;t t
16811 s,@INSTALL@,$ac_INSTALL,;t t
16812 " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
16814 if test x"$ac_file" != x-; then
16815 cp $tmp/out $ac_file
16817 for ac_name in prefix exec_prefix datarootdir
16819 ac_seen=`fgrep -n '${'$ac_name'[:=].*}' $ac_file`
16820 if test -n "$ac_seen"; then
16821 ac_init=`egrep '[ ]*'$ac_name'[ ]*=' $ac_file`
16822 if test -z "$ac_init"; then
16823 ac_seen=`echo "$ac_seen" |sed -e 's,^,'$ac_file':,'`
16824 { echo "$as_me:16824: WARNING: Variable $ac_name is used but was not set:
16826 echo "$as_me: WARNING: Variable $ac_name is used but was not set:
16831 egrep -n '@[a-z_][a-z_0-9]+@' $ac_file >$tmp/out
16832 egrep -n '@[A-Z_][A-Z_0-9]+@' $ac_file >>$tmp/out
16833 if test -s $tmp/out; then
16834 ac_seen=`sed -e 's,^,'$ac_file':,' < $tmp/out`
16835 { echo "$as_me:16835: WARNING: Some variables may not be substituted:
16837 echo "$as_me: WARNING: Some variables may not be substituted:
16847 cat >>$CONFIG_STATUS <<\EOF
16850 # CONFIG_HEADER section.
16853 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
16854 # NAME is the cpp macro being defined and VALUE is the value it is being given.
16856 # ac_d sets the value in "#define NAME VALUE" lines.
16857 ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
16858 ac_dB='[ ].*$,\1#\2'
16861 # ac_i turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
16862 ac_iA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
16863 ac_iB='\([ ]\),\1#\2define\3'
16866 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
16867 ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
16868 ac_uB='$,\1#\2define\3'
16872 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
16873 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
16875 - | *:- | *:-:* ) # input from stdin
16877 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
16878 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
16879 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
16880 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
16881 * ) ac_file_in=$ac_file.in ;;
16884 test x"$ac_file" != x- && { echo "$as_me:16884: creating $ac_file" >&5
16885 echo "$as_me: creating $ac_file" >&6;}
16887 # First look for the input files in the build tree, otherwise in the
16889 ac_file_inputs=`IFS=:
16890 for f in $ac_file_in; do
16892 -) echo $tmp/stdin ;;
16894 # Absolute (can't be DOS-style, as IFS=:)
16895 test -f "$f" || { { echo "$as_me:16895: error: cannot find input file: $f" >&5
16896 echo "$as_me: error: cannot find input file: $f" >&2;}
16897 { (exit 1); exit 1; }; }
16900 if test -f "$f"; then
16903 elif test -f "$srcdir/$f"; then
16908 { { echo "$as_me:16908: error: cannot find input file: $f" >&5
16909 echo "$as_me: error: cannot find input file: $f" >&2;}
16910 { (exit 1); exit 1; }; }
16913 done` || { (exit 1); exit 1; }
16914 # Remove the trailing spaces.
16915 sed 's/[ ]*$//' $ac_file_inputs >$tmp/in
16919 # Transform confdefs.h into a list of #define's. We won't use it as a sed
16920 # script, but as data to insert where we see @DEFS@. We expect AC_SAVE_DEFS to
16921 # be either 'cat' or 'sort'.
16922 cat confdefs.h | uniq >conftest.vals
16924 # Break up conftest.vals because some shells have a limit on
16925 # the size of here documents, and old seds have small limits too.
16927 rm -f conftest.tail
16928 echo ' rm -f conftest.frag' >> $CONFIG_STATUS
16929 while grep . conftest.vals >/dev/null
16931 # Write chunks of a limited-size here document to conftest.frag.
16932 echo ' cat >> conftest.frag <<CEOF' >> $CONFIG_STATUS
16933 sed ${ac_max_here_lines}q conftest.vals | sed -e 's/#ifdef.*/#if 0/' >> $CONFIG_STATUS
16934 echo 'CEOF' >> $CONFIG_STATUS
16935 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
16936 rm -f conftest.vals
16937 mv conftest.tail conftest.vals
16939 rm -f conftest.vals
16941 # Run sed to substitute the contents of conftest.frag into $tmp/in at the
16943 echo ' cat >> conftest.edit <<CEOF
16944 /@DEFS@/r conftest.frag
16947 sed -f conftest.edit $tmp/in > $tmp/out
16949 mv $tmp/out $tmp/in
16950 rm -f conftest.edit conftest.frag
16951 ' >> $CONFIG_STATUS
16953 cat >>$CONFIG_STATUS <<\EOF
16954 # Let's still pretend it is `configure' which instantiates (i.e., don't
16955 # use $as_me), people would be surprised to read:
16956 # /* config.h. Generated automatically by config.status. */
16957 if test x"$ac_file" = x-; then
16958 echo "/* Generated automatically by configure. */" >$tmp/config.h
16960 echo "/* $ac_file. Generated automatically by configure. */" >$tmp/config.h
16962 cat $tmp/in >>$tmp/config.h
16964 if test x"$ac_file" != x-; then
16965 if cmp -s $ac_file $tmp/config.h 2>/dev/null; then
16966 { echo "$as_me:16966: $ac_file is unchanged" >&5
16967 echo "$as_me: $ac_file is unchanged" >&6;}
16969 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
16970 X"$ac_file" : 'X\(//\)[^/]' \| \
16971 X"$ac_file" : 'X\(//\)$' \| \
16972 X"$ac_file" : 'X\(/\)' \| \
16973 . : '\(.\)' 2>/dev/null ||
16975 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
16976 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
16977 /^X\(\/\/\)$/{ s//\1/; q; }
16978 /^X\(\/\).*/{ s//\1/; q; }
16980 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
16981 { case "$ac_dir" in
16982 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
16986 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
16987 case $as_mkdir_dir in
16988 # Skip DOS drivespec
16989 ?:) as_incr_dir=$as_mkdir_dir ;;
16991 as_incr_dir=$as_incr_dir/$as_mkdir_dir
16992 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
16999 mv $tmp/config.h $ac_file
17003 rm -f $tmp/config.h
17007 cat >>$CONFIG_STATUS <<\EOF
17009 # CONFIG_COMMANDS section.
17011 for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
17012 ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
17013 ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
17020 if test ! -d $srcdir/$cf_dir; then
17022 elif test -f $srcdir/$cf_dir/programs; then
17023 $AWK -f $srcdir/mk-test.awk INSTALL=yes ECHO_LINK="$ECHO_LD" $srcdir/$cf_dir/programs >>$cf_dir/Makefile
17027 cat >>Makefile <<TEST_EOF
17029 # These rules are generated so we do not rely on suffix rules, which do not
17030 # work consistently for different make-programs (the '\$(MODEL)/' confuses
17031 # some, and the '\$x' confuses others).
17034 LIST=`sed -e 's/[ ].*//' -e '/^[#@]/d' $srcdir/modules`
17037 cat >>Makefile <<TEST_EOF
17039 \$(MODEL)/$N.o : \$(srcdir)/$N.c \\
17040 \$(srcdir)/test.priv.h \\
17043 $ECHO_CC\$(CC) -c \$(CFLAGS_DEFAULT) \$(srcdir)/$N.c
17047 if test -f ../config.guess && test -f ../config.sub
17049 cat >>Makefile <<TEST_EOF
17051 # if we used CF_INHERIT for getting these files, we can remove them
17053 rm -f config.guess config.sub
17061 cat >>$CONFIG_STATUS <<\EOF
17063 { (exit 0); exit 0; }
17065 chmod +x $CONFIG_STATUS
17066 ac_clean_files=$ac_clean_files_save
17068 # configure is writing to config.log, and then calls config.status.
17069 # config.status does its own redirection, appending to config.log.
17070 # Unfortunately, on DOS this fails, as config.log is still kept open
17071 # by configure, so config.status won't be able to write to it; its
17072 # output is simply discarded. So we exec the FD to /dev/null,
17073 # effectively closing config.log, so it can be properly (re)opened and
17074 # appended to by config.status. When coming back to configure, we
17075 # need to make the FD available again.
17076 if test "$no_create" != yes; then
17079 $SHELL $CONFIG_STATUS || ac_cs_success=false
17081 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
17082 # would make configure fail if this is the last instruction.
17083 $ac_cs_success || { (exit 1); exit 1; }