2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by Autoconf 2.52.20101002.
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 datadir='${prefix}/share'
138 sysconfdir='${prefix}/etc'
139 sharedstatedir='${prefix}/com'
140 localstatedir='${prefix}/var'
141 libdir='${exec_prefix}/lib'
142 includedir='${prefix}/include'
143 oldincludedir='/usr/include'
144 infodir='${prefix}/info'
145 mandir='${prefix}/man'
147 # Identity of this package.
157 # If the previous option needs an argument, assign it.
158 if test -n "$ac_prev"; then
159 eval "$ac_prev=\$ac_option"
164 ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
166 # Accept the important Cygnus configure options, so we can diagnose typos.
170 -bindir | --bindir | --bindi | --bind | --bin | --bi)
172 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
175 -build | --build | --buil | --bui | --bu)
176 ac_prev=build_alias ;;
177 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
178 build_alias=$ac_optarg ;;
180 -cache-file | --cache-file | --cache-fil | --cache-fi \
181 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
182 ac_prev=cache_file ;;
183 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
184 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
185 cache_file=$ac_optarg ;;
188 cache_file=config.cache ;;
190 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
192 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
194 datadir=$ac_optarg ;;
196 -disable-* | --disable-*)
197 ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
198 # Reject names that are not valid shell variable names.
199 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
200 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
201 { (exit 1); exit 1; }; }
202 ac_feature=`echo $ac_feature | sed 's/-/_/g'`
203 eval "enable_$ac_feature=no" ;;
205 -enable-* | --enable-*)
206 ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
207 # Reject names that are not valid shell variable names.
208 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
209 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
210 { (exit 1); exit 1; }; }
211 ac_feature=`echo $ac_feature | sed 's/-/_/g'`
213 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
216 eval "enable_$ac_feature='$ac_optarg'" ;;
218 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
219 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
220 | --exec | --exe | --ex)
221 ac_prev=exec_prefix ;;
222 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
223 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
224 | --exec=* | --exe=* | --ex=*)
225 exec_prefix=$ac_optarg ;;
227 -gas | --gas | --ga | --g)
228 # Obsolete; use --with-gas.
231 -help | --help | --hel | --he | -h)
233 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
234 ac_init_help=recursive ;;
235 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
236 ac_init_help=short ;;
238 -host | --host | --hos | --ho)
239 ac_prev=host_alias ;;
240 -host=* | --host=* | --hos=* | --ho=*)
241 host_alias=$ac_optarg ;;
243 -includedir | --includedir | --includedi | --included | --include \
244 | --includ | --inclu | --incl | --inc)
245 ac_prev=includedir ;;
246 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
247 | --includ=* | --inclu=* | --incl=* | --inc=*)
248 includedir=$ac_optarg ;;
250 -infodir | --infodir | --infodi | --infod | --info | --inf)
252 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
253 infodir=$ac_optarg ;;
255 -libdir | --libdir | --libdi | --libd)
257 -libdir=* | --libdir=* | --libdi=* | --libd=*)
260 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
261 | --libexe | --libex | --libe)
262 ac_prev=libexecdir ;;
263 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
264 | --libexe=* | --libex=* | --libe=*)
265 libexecdir=$ac_optarg ;;
267 -localstatedir | --localstatedir | --localstatedi | --localstated \
268 | --localstate | --localstat | --localsta | --localst \
269 | --locals | --local | --loca | --loc | --lo)
270 ac_prev=localstatedir ;;
271 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
272 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
273 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
274 localstatedir=$ac_optarg ;;
276 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
278 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
282 # Obsolete; use --without-fp.
285 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
289 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
290 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
293 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
294 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
295 | --oldin | --oldi | --old | --ol | --o)
296 ac_prev=oldincludedir ;;
297 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
298 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
299 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
300 oldincludedir=$ac_optarg ;;
302 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
304 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
307 -program-prefix | --program-prefix | --program-prefi | --program-pref \
308 | --program-pre | --program-pr | --program-p)
309 ac_prev=program_prefix ;;
310 -program-prefix=* | --program-prefix=* | --program-prefi=* \
311 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
312 program_prefix=$ac_optarg ;;
314 -program-suffix | --program-suffix | --program-suffi | --program-suff \
315 | --program-suf | --program-su | --program-s)
316 ac_prev=program_suffix ;;
317 -program-suffix=* | --program-suffix=* | --program-suffi=* \
318 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
319 program_suffix=$ac_optarg ;;
321 -program-transform-name | --program-transform-name \
322 | --program-transform-nam | --program-transform-na \
323 | --program-transform-n | --program-transform- \
324 | --program-transform | --program-transfor \
325 | --program-transfo | --program-transf \
326 | --program-trans | --program-tran \
327 | --progr-tra | --program-tr | --program-t)
328 ac_prev=program_transform_name ;;
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 program_transform_name=$ac_optarg ;;
338 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
339 | -silent | --silent | --silen | --sile | --sil)
342 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
344 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
346 sbindir=$ac_optarg ;;
348 -sharedstatedir | --sharedstatedir | --sharedstatedi \
349 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
350 | --sharedst | --shareds | --shared | --share | --shar \
352 ac_prev=sharedstatedir ;;
353 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
354 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
355 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
357 sharedstatedir=$ac_optarg ;;
359 -site | --site | --sit)
361 -site=* | --site=* | --sit=*)
364 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
366 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
369 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
370 | --syscon | --sysco | --sysc | --sys | --sy)
371 ac_prev=sysconfdir ;;
372 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
373 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
374 sysconfdir=$ac_optarg ;;
376 -target | --target | --targe | --targ | --tar | --ta | --t)
377 ac_prev=target_alias ;;
378 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
379 target_alias=$ac_optarg ;;
381 -v | -verbose | --verbose | --verbos | --verbo | --verb)
384 -version | --version | --versio | --versi | --vers | -V)
388 ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
389 # Reject names that are not valid shell variable names.
390 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
391 { echo "$as_me: error: invalid package name: $ac_package" >&2
392 { (exit 1); exit 1; }; }
393 ac_package=`echo $ac_package| sed 's/-/_/g'`
395 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
398 eval "with_$ac_package='$ac_optarg'" ;;
400 -without-* | --without-*)
401 ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
402 # Reject names that are not valid shell variable names.
403 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
404 { echo "$as_me: error: invalid package name: $ac_package" >&2
405 { (exit 1); exit 1; }; }
406 ac_package=`echo $ac_package | sed 's/-/_/g'`
407 eval "with_$ac_package=no" ;;
410 # Obsolete; use --with-x.
413 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
414 | --x-incl | --x-inc | --x-in | --x-i)
415 ac_prev=x_includes ;;
416 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
417 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
418 x_includes=$ac_optarg ;;
420 -x-libraries | --x-libraries | --x-librarie | --x-librari \
421 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
422 ac_prev=x_libraries ;;
423 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
424 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
425 x_libraries=$ac_optarg ;;
427 -*) { echo "$as_me: error: unrecognized option: $ac_option
428 Try \`$0 --help' for more information." >&2
429 { (exit 1); exit 1; }; }
433 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
434 # Reject names that are not valid shell variable names.
435 expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
436 { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
437 { (exit 1); exit 1; }; }
438 ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
439 eval "$ac_envvar='$ac_optarg'"
443 # FIXME: should be removed in autoconf 3.0.
444 echo "$as_me: WARNING: you should use --build, --host, --target" >&2
445 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
446 echo "$as_me: WARNING: invalid host type: $ac_option" >&2
447 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
453 if test -n "$ac_prev"; then
454 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
455 { echo "$as_me: error: missing argument to $ac_option" >&2
456 { (exit 1); exit 1; }; }
459 # Be sure to have absolute paths.
460 for ac_var in exec_prefix prefix
462 eval ac_val=$`echo $ac_var`
464 [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
465 *) { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
466 { (exit 1); exit 1; }; };;
470 # Be sure to have absolute paths.
471 for ac_var in bindir sbindir libexecdir datadir sysconfdir sharedstatedir \
472 localstatedir libdir includedir oldincludedir infodir mandir
474 eval ac_val=$`echo $ac_var`
476 [\\/$]* | ?:[\\/]* ) ;;
477 *) { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
478 { (exit 1); exit 1; }; };;
482 # There might be people who depend on the old broken behavior: `$host'
483 # used to hold the argument of --host etc.
488 # FIXME: should be removed in autoconf 3.0.
489 if test "x$host_alias" != x; then
490 if test "x$build_alias" = x; then
491 cross_compiling=maybe
492 echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
493 If a cross compiler is detected then cross compile mode will be used." >&2
494 elif test "x$build_alias" != "x$host_alias"; then
500 test -n "$host_alias" && ac_tool_prefix=$host_alias-
502 test "$silent" = yes && exec 6>/dev/null
504 # Find the source files, if location was not specified.
505 if test -z "$srcdir"; then
506 ac_srcdir_defaulted=yes
507 # Try the directory containing this script, then its parent.
509 ac_confdir=`echo "$ac_prog" | sed 's%[\\/][^\\/][^\\/]*$%%'`
510 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
512 if test ! -r $srcdir/$ac_unique_file; then
516 ac_srcdir_defaulted=no
518 if test ! -r $srcdir/$ac_unique_file; then
519 if test "$ac_srcdir_defaulted" = yes; then
520 { echo "$as_me: error: cannot find sources in $ac_confdir or .." >&2
521 { (exit 1); exit 1; }; }
523 { echo "$as_me: error: cannot find sources in $srcdir" >&2
524 { (exit 1); exit 1; }; }
527 srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
528 ac_env_build_alias_set=${build_alias+set}
529 ac_env_build_alias_value=$build_alias
530 ac_cv_env_build_alias_set=${build_alias+set}
531 ac_cv_env_build_alias_value=$build_alias
532 ac_env_host_alias_set=${host_alias+set}
533 ac_env_host_alias_value=$host_alias
534 ac_cv_env_host_alias_set=${host_alias+set}
535 ac_cv_env_host_alias_value=$host_alias
536 ac_env_target_alias_set=${target_alias+set}
537 ac_env_target_alias_value=$target_alias
538 ac_cv_env_target_alias_set=${target_alias+set}
539 ac_cv_env_target_alias_value=$target_alias
540 ac_env_CC_set=${CC+set}
542 ac_cv_env_CC_set=${CC+set}
543 ac_cv_env_CC_value=$CC
544 ac_env_CFLAGS_set=${CFLAGS+set}
545 ac_env_CFLAGS_value=$CFLAGS
546 ac_cv_env_CFLAGS_set=${CFLAGS+set}
547 ac_cv_env_CFLAGS_value=$CFLAGS
548 ac_env_LDFLAGS_set=${LDFLAGS+set}
549 ac_env_LDFLAGS_value=$LDFLAGS
550 ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
551 ac_cv_env_LDFLAGS_value=$LDFLAGS
552 ac_env_CPPFLAGS_set=${CPPFLAGS+set}
553 ac_env_CPPFLAGS_value=$CPPFLAGS
554 ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
555 ac_cv_env_CPPFLAGS_value=$CPPFLAGS
556 ac_env_CPP_set=${CPP+set}
557 ac_env_CPP_value=$CPP
558 ac_cv_env_CPP_set=${CPP+set}
559 ac_cv_env_CPP_value=$CPP
562 # Report the --help message.
564 if test "$ac_init_help" = "long"; then
565 # Omit some internal or obsolete options to make the list less imposing.
566 # This message is too long to be a string in the A/UX 3.1 sh.
568 \`configure' configures this package to adapt to many kinds of systems.
570 Usage: $0 [OPTION]... [VAR=VALUE]...
572 To assign environment variables (e.g., CC, CFLAGS...), specify them as
573 VAR=VALUE. See below for descriptions of some of the useful variables.
575 Defaults for the options are specified in brackets.
578 -h, --help display this help and exit
579 --help=short display options specific to this package
580 --help=recursive display the short help of all the included packages
581 -V, --version display version information and exit
582 -q, --quiet, --silent do not print \`checking...' messages
583 --cache-file=FILE cache test results in FILE [disabled]
584 -C, --config-cache alias for \`--cache-file=config.cache'
585 -n, --no-create do not create output files
586 --srcdir=DIR find the sources in DIR [configure dir or \`..']
591 Installation directories:
592 --prefix=PREFIX install architecture-independent files in PREFIX
594 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
597 By default, \`make install' will install all the files in
598 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
599 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
600 for instance \`--prefix=\$HOME'.
602 For better control, use the options below.
604 Fine tuning of the installation directories:
605 --bindir=DIR user executables [EPREFIX/bin]
606 --sbindir=DIR system admin executables [EPREFIX/sbin]
607 --libexecdir=DIR program executables [EPREFIX/libexec]
608 --datadir=DIR read-only architecture-independent data [PREFIX/share]
609 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
610 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
611 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
612 --libdir=DIR object code libraries [EPREFIX/lib]
613 --includedir=DIR C header files [PREFIX/include]
614 --oldincludedir=DIR C header files for non-gcc [/usr/include]
615 --infodir=DIR info documentation [PREFIX/info]
616 --mandir=DIR man documentation [PREFIX/man]
622 --program-prefix=PREFIX prepend PREFIX to installed program names
623 --program-suffix=SUFFIX append SUFFIX to installed program names
624 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
627 --x-includes=DIR X include files are in DIR
628 --x-libraries=DIR X library files are in DIR
631 --build=BUILD configure for building on BUILD [guessed]
632 --host=HOST build programs to run on HOST [BUILD]
636 if test -n "$ac_init_help"; then
641 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
642 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
645 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
646 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
648 --disable-echo display "compiling" commands
649 --enable-warnings test: turn on gcc compiler warnings
650 --with-dmalloc test: use Gray Watson's dmalloc library
651 --with-dbmalloc test: use Conor Cahill's dbmalloc library
652 --with-valgrind test: use valgrind
653 --disable-leaks test: free permanent memory, analyze leaks
654 --disable-widec disable checks for wide-character functions
655 --with-curses-dir=DIR directory in which (n)curses is installed
656 --with-ncursesw use wide ncurses-libraries (installed)
657 --with-ncurses use ncurses-libraries (installed)
658 --with-pdcurses compile/link with pdcurses X11 library
659 --with-curses-colr compile/link with HPUX 10.x color-curses
660 --with-curses-5lib compile/link with SunOS 5lib curses
661 --with-Xaw3d link with Xaw 3d library
662 --with-neXtaw link with neXT Athena library
663 --with-XawPlus link with Athena-Plus library
664 --with-pkg-config{=path} enable/disable use of pkg-config
665 --with-x use the X Window System
666 --with-ncurses-wrap-prefix naming-prefix for ncurses wrapped-variables
668 Some influential environment variables:
669 CC C compiler command
670 CFLAGS C compiler flags
671 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
672 nonstandard directory <lib dir>
673 CPPFLAGS C/C++ preprocessor flags, e.g. -I<include dir> if you have
674 headers in a nonstandard directory <include dir>
677 Use these variables to override the choices made by `configure' or to help
678 it to find libraries and programs with nonstandard names/locations.
683 if test "$ac_init_help" = "recursive"; then
684 # If there are subdirs, report their specific --help.
686 for ac_subdir in : $ac_subdirs_all; do test "x$ac_subdir" = x: && continue
688 # A "../" for each directory in /$ac_subdir.
689 ac_dots=`echo $ac_subdir |
690 sed 's,^\./,,;s,[^/]$,&/,;s,[^/]*/,../,g'`
693 .) # No --srcdir option. We are building in place.
694 ac_sub_srcdir=$srcdir ;;
695 [\\/]* | ?:[\\/]* ) # Absolute path.
696 ac_sub_srcdir=$srcdir/$ac_subdir ;;
698 ac_sub_srcdir=$ac_dots$srcdir/$ac_subdir ;;
701 # Check for guested configure; otherwise get Cygnus style configure.
702 if test -f $ac_sub_srcdir/configure.gnu; then
704 $SHELL $ac_sub_srcdir/configure.gnu --help=recursive
705 elif test -f $ac_sub_srcdir/configure; then
707 $SHELL $ac_sub_srcdir/configure --help=recursive
708 elif test -f $ac_sub_srcdir/configure.ac ||
709 test -f $ac_sub_srcdir/configure.in; then
713 echo "$as_me: WARNING: no configuration information is in $ac_subdir" >&2
719 test -n "$ac_init_help" && exit 0
720 if $ac_init_version; then
723 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
724 Free Software Foundation, Inc.
725 This configure script is free software; the Free Software Foundation
726 gives unlimited permission to copy, distribute and modify it.
732 This file contains any messages produced by compilers while
733 running configure, to aid debugging if configure makes a mistake.
735 It was created by $as_me, which was
736 generated by GNU Autoconf 2.52.20101002. Invocation command line was
747 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
748 uname -m = `(uname -m) 2>/dev/null || echo unknown`
749 uname -r = `(uname -r) 2>/dev/null || echo unknown`
750 uname -s = `(uname -s) 2>/dev/null || echo unknown`
751 uname -v = `(uname -v) 2>/dev/null || echo unknown`
753 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
754 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
756 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
757 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
758 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
759 hostinfo = `(hostinfo) 2>/dev/null || echo unknown`
760 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
761 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
762 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
776 # Keep a trace of the command line.
777 # Strip out --no-create and --no-recursion so they do not pile up.
778 # Also quote any args containing shell meta-characters.
784 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
785 | --no-cr | --no-c) ;;
786 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
787 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
788 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
789 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"`
790 ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
792 *) ac_configure_args="$ac_configure_args$ac_sep$ac_arg"
795 # Get rid of the leading space.
798 # When interrupted or exit'd, cleanup temporary files, and complete
799 # config.log. We remove comments because anyway the quotes in there
800 # would cause problems or look ugly.
802 # Save into config.log some information that might help in debugging.
804 echo "## ----------------- ##" >&5
805 echo "## Cache variables. ##" >&5
806 echo "## ----------------- ##" >&5
808 # The following way of writing the cache mishandles newlines in values,
811 case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
814 "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
815 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
819 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
823 sed "/^$/d" confdefs.h >conftest.log
824 if test -s conftest.log; then
826 echo "## ------------ ##" >&5
827 echo "## confdefs.h. ##" >&5
828 echo "## ------------ ##" >&5
833 test "$ac_signal" != 0 &&
834 echo "$as_me: caught signal $ac_signal" >&5
835 echo "$as_me: exit $exit_status" >&5
836 rm -rf conftest* confdefs* core core.* *.core conf$$* $ac_clean_files &&
839 for ac_signal in 1 2 13 15; do
840 trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
844 # confdefs.h avoids OS command line length limits that DEFS can exceed.
845 rm -rf conftest* confdefs.h
846 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
849 # Let the site file select an alternate cache file if it wants to.
850 # Prefer explicitly selected file to automatically selected ones.
851 if test -z "$CONFIG_SITE"; then
852 if test "x$prefix" != xNONE; then
853 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
855 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
858 for ac_site_file in $CONFIG_SITE; do
859 if test -r "$ac_site_file"; then
860 { echo "$as_me:860: loading site script $ac_site_file" >&5
861 echo "$as_me: loading site script $ac_site_file" >&6;}
862 cat "$ac_site_file" >&5
867 if test -r "$cache_file"; then
868 # Some versions of bash will fail to source /dev/null (special
869 # files actually), so we avoid doing that.
870 if test -f "$cache_file"; then
871 { echo "$as_me:871: loading cache $cache_file" >&5
872 echo "$as_me: loading cache $cache_file" >&6;}
874 [\\/]* | ?:[\\/]* ) . $cache_file;;
879 { echo "$as_me:879: creating cache $cache_file" >&5
880 echo "$as_me: creating cache $cache_file" >&6;}
884 # Check that the precious variables saved in the cache have kept the same
886 ac_cache_corrupted=false
887 for ac_var in `(set) 2>&1 |
888 sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
889 eval ac_old_set=\$ac_cv_env_${ac_var}_set
890 eval ac_new_set=\$ac_env_${ac_var}_set
891 eval ac_old_val="\$ac_cv_env_${ac_var}_value"
892 eval ac_new_val="\$ac_env_${ac_var}_value"
893 case $ac_old_set,$ac_new_set in
895 { echo "$as_me:895: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
896 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
897 ac_cache_corrupted=: ;;
899 { echo "$as_me:899: error: \`$ac_var' was not set in the previous run" >&5
900 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
901 ac_cache_corrupted=: ;;
904 if test "x$ac_old_val" != "x$ac_new_val"; then
905 { echo "$as_me:905: error: \`$ac_var' has changed since the previous run:" >&5
906 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
907 { echo "$as_me:907: former value: $ac_old_val" >&5
908 echo "$as_me: former value: $ac_old_val" >&2;}
909 { echo "$as_me:909: current value: $ac_new_val" >&5
910 echo "$as_me: current value: $ac_new_val" >&2;}
914 # Pass precious variables to config.status. It doesn't matter if
915 # we pass some twice (in addition to the command line arguments).
916 if test "$ac_new_set" = set; then
918 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
919 ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"`
920 ac_configure_args="$ac_configure_args '$ac_arg'"
922 *) ac_configure_args="$ac_configure_args $ac_var=$ac_new_val"
927 if $ac_cache_corrupted; then
928 { echo "$as_me:928: error: changes in the environment can compromise the build" >&5
929 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
930 { { echo "$as_me:930: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
931 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
932 { (exit 1); exit 1; }; }
936 ac_cpp='$CPP $CPPFLAGS'
937 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
938 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
939 ac_compiler_gnu=$ac_cv_c_compiler_gnu
940 ac_main_return=return
942 case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
943 *c*,-n*) ECHO_N= ECHO_C='
945 *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
946 *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
948 echo "#! $SHELL" >conftest.sh
949 echo "exit 0" >>conftest.sh
951 if { (echo "$as_me:951: PATH=\".;.\"; conftest.sh") >&5
952 (PATH=".;."; conftest.sh) 2>&5
954 echo "$as_me:954: \$? = $ac_status" >&5
955 (exit $ac_status); }; then
956 ac_path_separator=';'
960 PATH_SEPARATOR="$ac_path_separator"
963 ac_config_headers="$ac_config_headers ncurses_cfg.h:ncurses_tst.hin"
965 test -f config.guess || ( test -f ../config.guess && cp ../config.guess ./ )
967 test -f config.sub || ( test -f ../config.sub && cp ../config.sub ./ )
970 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
971 if test -f $ac_dir/install-sh; then
973 ac_install_sh="$ac_aux_dir/install-sh -c"
975 elif test -f $ac_dir/install.sh; then
977 ac_install_sh="$ac_aux_dir/install.sh -c"
979 elif test -f $ac_dir/shtool; then
981 ac_install_sh="$ac_aux_dir/shtool install -c"
985 if test -z "$ac_aux_dir"; then
986 { { echo "$as_me:986: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
987 echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
988 { (exit 1); exit 1; }; }
990 ac_config_guess="$SHELL $ac_aux_dir/config.guess"
991 ac_config_sub="$SHELL $ac_aux_dir/config.sub"
992 ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
994 # Make sure we can run config.sub.
995 $ac_config_sub sun4 >/dev/null 2>&1 ||
996 { { echo "$as_me:996: error: cannot run $ac_config_sub" >&5
997 echo "$as_me: error: cannot run $ac_config_sub" >&2;}
998 { (exit 1); exit 1; }; }
1000 echo "$as_me:1000: checking build system type" >&5
1001 echo $ECHO_N "checking build system type... $ECHO_C" >&6
1002 if test "${ac_cv_build+set}" = set; then
1003 echo $ECHO_N "(cached) $ECHO_C" >&6
1005 ac_cv_build_alias=$build_alias
1006 test -z "$ac_cv_build_alias" &&
1007 ac_cv_build_alias=`$ac_config_guess`
1008 test -z "$ac_cv_build_alias" &&
1009 { { echo "$as_me:1009: error: cannot guess build type; you must specify one" >&5
1010 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1011 { (exit 1); exit 1; }; }
1012 ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
1013 { { echo "$as_me:1013: error: $ac_config_sub $ac_cv_build_alias failed." >&5
1014 echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed." >&2;}
1015 { (exit 1); exit 1; }; }
1018 echo "$as_me:1018: result: $ac_cv_build" >&5
1019 echo "${ECHO_T}$ac_cv_build" >&6
1021 build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1022 build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1023 build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1025 if test -f $srcdir/config.guess || test -f $ac_aux_dir/config.guess ; then
1026 echo "$as_me:1026: checking host system type" >&5
1027 echo $ECHO_N "checking host system type... $ECHO_C" >&6
1028 if test "${ac_cv_host+set}" = set; then
1029 echo $ECHO_N "(cached) $ECHO_C" >&6
1031 ac_cv_host_alias=$host_alias
1032 test -z "$ac_cv_host_alias" &&
1033 ac_cv_host_alias=$ac_cv_build_alias
1034 ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
1035 { { echo "$as_me:1035: error: $ac_config_sub $ac_cv_host_alias failed" >&5
1036 echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1037 { (exit 1); exit 1; }; }
1040 echo "$as_me:1040: result: $ac_cv_host" >&5
1041 echo "${ECHO_T}$ac_cv_host" >&6
1043 host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1044 host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1045 host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1047 system_name="$host_os"
1049 system_name="`(uname -s -r) 2>/dev/null`"
1050 if test -z "$system_name" ; then
1051 system_name="`(hostname) 2>/dev/null`"
1054 test -n "$system_name" && cat >>confdefs.h <<EOF
1055 #define SYSTEM_NAME "$system_name"
1058 if test "${cf_cv_system_name+set}" = set; then
1059 echo $ECHO_N "(cached) $ECHO_C" >&6
1061 cf_cv_system_name="$system_name"
1064 test -z "$system_name" && system_name="$cf_cv_system_name"
1065 test -n "$cf_cv_system_name" && echo "$as_me:1065: result: Configuring for $cf_cv_system_name" >&5
1066 echo "${ECHO_T}Configuring for $cf_cv_system_name" >&6
1068 if test ".$system_name" != ".$cf_cv_system_name" ; then
1069 echo "$as_me:1069: result: Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&5
1070 echo "${ECHO_T}Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&6
1071 { { echo "$as_me:1071: error: \"Please remove config.cache and try again.\"" >&5
1072 echo "$as_me: error: \"Please remove config.cache and try again.\"" >&2;}
1073 { (exit 1); exit 1; }; }
1076 test "$program_prefix" != NONE &&
1077 program_transform_name="s,^,$program_prefix,;$program_transform_name"
1078 # Use a double $ so make ignores it.
1079 test "$program_suffix" != NONE &&
1080 program_transform_name="s,\$,$program_suffix,;$program_transform_name"
1081 # Double any \ or $. echo might interpret backslashes.
1082 # By default was `s,x,x', remove it if useless.
1083 cat <<\_ACEOF >conftest.sed
1084 s/[\\$]/&&/g;s/;s,x,x,$//
1086 program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
1089 echo "$as_me:1089: checking whether ${MAKE-make} sets \${MAKE}" >&5
1090 echo $ECHO_N "checking whether ${MAKE-make} sets \${MAKE}... $ECHO_C" >&6
1091 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,./+-,__p_,'`
1092 if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
1093 echo $ECHO_N "(cached) $ECHO_C" >&6
1095 cat >conftest.make <<\EOF
1097 @echo 'ac_maketemp="${MAKE}"'
1099 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1100 eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
1101 if test -n "$ac_maketemp"; then
1102 eval ac_cv_prog_make_${ac_make}_set=yes
1104 eval ac_cv_prog_make_${ac_make}_set=no
1108 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
1109 echo "$as_me:1109: result: yes" >&5
1110 echo "${ECHO_T}yes" >&6
1113 echo "$as_me:1113: result: no" >&5
1114 echo "${ECHO_T}no" >&6
1115 SET_MAKE="MAKE=${MAKE-make}"
1119 ac_cpp='$CPP $CPPFLAGS'
1120 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1121 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1122 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1123 ac_main_return=return
1124 if test -n "$ac_tool_prefix"; then
1125 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
1126 set dummy ${ac_tool_prefix}gcc; ac_word=$2
1127 echo "$as_me:1127: checking for $ac_word" >&5
1128 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1129 if test "${ac_cv_prog_CC+set}" = set; then
1130 echo $ECHO_N "(cached) $ECHO_C" >&6
1132 if test -n "$CC"; then
1133 ac_cv_prog_CC="$CC" # Let the user override the test.
1135 ac_save_IFS=$IFS; IFS=$ac_path_separator
1137 for ac_dir in $ac_dummy; do
1139 test -z "$ac_dir" && ac_dir=.
1140 $as_executable_p "$ac_dir/$ac_word" || continue
1141 ac_cv_prog_CC="${ac_tool_prefix}gcc"
1142 echo "$as_me:1142: found $ac_dir/$ac_word" >&5
1149 if test -n "$CC"; then
1150 echo "$as_me:1150: result: $CC" >&5
1151 echo "${ECHO_T}$CC" >&6
1153 echo "$as_me:1153: result: no" >&5
1154 echo "${ECHO_T}no" >&6
1158 if test -z "$ac_cv_prog_CC"; then
1160 # Extract the first word of "gcc", so it can be a program name with args.
1161 set dummy gcc; ac_word=$2
1162 echo "$as_me:1162: checking for $ac_word" >&5
1163 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1164 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1165 echo $ECHO_N "(cached) $ECHO_C" >&6
1167 if test -n "$ac_ct_CC"; then
1168 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1170 ac_save_IFS=$IFS; IFS=$ac_path_separator
1172 for ac_dir in $ac_dummy; do
1174 test -z "$ac_dir" && ac_dir=.
1175 $as_executable_p "$ac_dir/$ac_word" || continue
1176 ac_cv_prog_ac_ct_CC="gcc"
1177 echo "$as_me:1177: found $ac_dir/$ac_word" >&5
1183 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1184 if test -n "$ac_ct_CC"; then
1185 echo "$as_me:1185: result: $ac_ct_CC" >&5
1186 echo "${ECHO_T}$ac_ct_CC" >&6
1188 echo "$as_me:1188: result: no" >&5
1189 echo "${ECHO_T}no" >&6
1197 if test -z "$CC"; then
1198 if test -n "$ac_tool_prefix"; then
1199 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
1200 set dummy ${ac_tool_prefix}cc; ac_word=$2
1201 echo "$as_me:1201: checking for $ac_word" >&5
1202 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1203 if test "${ac_cv_prog_CC+set}" = set; then
1204 echo $ECHO_N "(cached) $ECHO_C" >&6
1206 if test -n "$CC"; then
1207 ac_cv_prog_CC="$CC" # Let the user override the test.
1209 ac_save_IFS=$IFS; IFS=$ac_path_separator
1211 for ac_dir in $ac_dummy; do
1213 test -z "$ac_dir" && ac_dir=.
1214 $as_executable_p "$ac_dir/$ac_word" || continue
1215 ac_cv_prog_CC="${ac_tool_prefix}cc"
1216 echo "$as_me:1216: found $ac_dir/$ac_word" >&5
1223 if test -n "$CC"; then
1224 echo "$as_me:1224: result: $CC" >&5
1225 echo "${ECHO_T}$CC" >&6
1227 echo "$as_me:1227: result: no" >&5
1228 echo "${ECHO_T}no" >&6
1232 if test -z "$ac_cv_prog_CC"; then
1234 # Extract the first word of "cc", so it can be a program name with args.
1235 set dummy cc; ac_word=$2
1236 echo "$as_me:1236: checking for $ac_word" >&5
1237 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1238 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1239 echo $ECHO_N "(cached) $ECHO_C" >&6
1241 if test -n "$ac_ct_CC"; then
1242 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1244 ac_save_IFS=$IFS; IFS=$ac_path_separator
1246 for ac_dir in $ac_dummy; do
1248 test -z "$ac_dir" && ac_dir=.
1249 $as_executable_p "$ac_dir/$ac_word" || continue
1250 ac_cv_prog_ac_ct_CC="cc"
1251 echo "$as_me:1251: found $ac_dir/$ac_word" >&5
1257 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1258 if test -n "$ac_ct_CC"; then
1259 echo "$as_me:1259: result: $ac_ct_CC" >&5
1260 echo "${ECHO_T}$ac_ct_CC" >&6
1262 echo "$as_me:1262: result: no" >&5
1263 echo "${ECHO_T}no" >&6
1272 if test -z "$CC"; then
1273 # Extract the first word of "cc", so it can be a program name with args.
1274 set dummy cc; ac_word=$2
1275 echo "$as_me:1275: checking for $ac_word" >&5
1276 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1277 if test "${ac_cv_prog_CC+set}" = set; then
1278 echo $ECHO_N "(cached) $ECHO_C" >&6
1280 if test -n "$CC"; then
1281 ac_cv_prog_CC="$CC" # Let the user override the test.
1284 ac_save_IFS=$IFS; IFS=$ac_path_separator
1286 for ac_dir in $ac_dummy; do
1288 test -z "$ac_dir" && ac_dir=.
1289 $as_executable_p "$ac_dir/$ac_word" || continue
1290 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
1291 ac_prog_rejected=yes
1295 echo "$as_me:1295: found $ac_dir/$ac_word" >&5
1299 if test $ac_prog_rejected = yes; then
1300 # We found a bogon in the path, so make sure we never use it.
1301 set dummy $ac_cv_prog_CC
1303 if test $# != 0; then
1304 # We chose a different compiler from the bogus one.
1305 # However, it has the same basename, so the bogon will be chosen
1306 # first if we set CC to just the basename; use the full file name.
1308 set dummy "$ac_dir/$ac_word" ${1+"$@"}
1316 if test -n "$CC"; then
1317 echo "$as_me:1317: result: $CC" >&5
1318 echo "${ECHO_T}$CC" >&6
1320 echo "$as_me:1320: result: no" >&5
1321 echo "${ECHO_T}no" >&6
1325 if test -z "$CC"; then
1326 if test -n "$ac_tool_prefix"; then
1329 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
1330 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
1331 echo "$as_me:1331: checking for $ac_word" >&5
1332 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1333 if test "${ac_cv_prog_CC+set}" = set; then
1334 echo $ECHO_N "(cached) $ECHO_C" >&6
1336 if test -n "$CC"; then
1337 ac_cv_prog_CC="$CC" # Let the user override the test.
1339 ac_save_IFS=$IFS; IFS=$ac_path_separator
1341 for ac_dir in $ac_dummy; do
1343 test -z "$ac_dir" && ac_dir=.
1344 $as_executable_p "$ac_dir/$ac_word" || continue
1345 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
1346 echo "$as_me:1346: found $ac_dir/$ac_word" >&5
1353 if test -n "$CC"; then
1354 echo "$as_me:1354: result: $CC" >&5
1355 echo "${ECHO_T}$CC" >&6
1357 echo "$as_me:1357: result: no" >&5
1358 echo "${ECHO_T}no" >&6
1361 test -n "$CC" && break
1364 if test -z "$CC"; then
1368 # Extract the first word of "$ac_prog", so it can be a program name with args.
1369 set dummy $ac_prog; ac_word=$2
1370 echo "$as_me:1370: checking for $ac_word" >&5
1371 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1372 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1373 echo $ECHO_N "(cached) $ECHO_C" >&6
1375 if test -n "$ac_ct_CC"; then
1376 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1378 ac_save_IFS=$IFS; IFS=$ac_path_separator
1380 for ac_dir in $ac_dummy; do
1382 test -z "$ac_dir" && ac_dir=.
1383 $as_executable_p "$ac_dir/$ac_word" || continue
1384 ac_cv_prog_ac_ct_CC="$ac_prog"
1385 echo "$as_me:1385: found $ac_dir/$ac_word" >&5
1391 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1392 if test -n "$ac_ct_CC"; then
1393 echo "$as_me:1393: result: $ac_ct_CC" >&5
1394 echo "${ECHO_T}$ac_ct_CC" >&6
1396 echo "$as_me:1396: result: no" >&5
1397 echo "${ECHO_T}no" >&6
1400 test -n "$ac_ct_CC" && break
1408 test -z "$CC" && { { echo "$as_me:1408: error: no acceptable cc found in \$PATH" >&5
1409 echo "$as_me: error: no acceptable cc found in \$PATH" >&2;}
1410 { (exit 1); exit 1; }; }
1412 # Provide some information about the compiler.
1413 echo "$as_me:1413:" \
1414 "checking for C compiler version" >&5
1415 ac_compiler=`set X $ac_compile; echo $2`
1416 { (eval echo "$as_me:1416: \"$ac_compiler --version </dev/null >&5\"") >&5
1417 (eval $ac_compiler --version </dev/null >&5) 2>&5
1419 echo "$as_me:1419: \$? = $ac_status" >&5
1420 (exit $ac_status); }
1421 { (eval echo "$as_me:1421: \"$ac_compiler -v </dev/null >&5\"") >&5
1422 (eval $ac_compiler -v </dev/null >&5) 2>&5
1424 echo "$as_me:1424: \$? = $ac_status" >&5
1425 (exit $ac_status); }
1426 { (eval echo "$as_me:1426: \"$ac_compiler -V </dev/null >&5\"") >&5
1427 (eval $ac_compiler -V </dev/null >&5) 2>&5
1429 echo "$as_me:1429: \$? = $ac_status" >&5
1430 (exit $ac_status); }
1432 cat >conftest.$ac_ext <<_ACEOF
1433 #line 1433 "configure"
1434 #include "confdefs.h"
1444 ac_clean_files_save=$ac_clean_files
1445 ac_clean_files="$ac_clean_files a.out a.exe"
1446 # Try to create an executable without -o first, disregard a.out.
1447 # It will help us diagnose broken compilers, and finding out an intuition
1449 echo "$as_me:1449: checking for C compiler default output" >&5
1450 echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
1451 ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
1452 if { (eval echo "$as_me:1452: \"$ac_link_default\"") >&5
1453 (eval $ac_link_default) 2>&5
1455 echo "$as_me:1455: \$? = $ac_status" >&5
1456 (exit $ac_status); }; then
1457 # Find the output, starting from the most likely. This scheme is
1458 # not robust to junk in `.', hence go to wildcards (a.*) only as a last
1460 for ac_file in `ls a.exe conftest.exe 2>/dev/null;
1461 ls a.out conftest 2>/dev/null;
1462 ls a.* conftest.* 2>/dev/null`; do
1464 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1465 a.out ) # We found the default executable, but exeext='' is most
1468 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1469 # FIXME: I believe we export ac_cv_exeext for Libtool --akim.
1476 echo "$as_me: failed program was:" >&5
1477 cat conftest.$ac_ext >&5
1478 { { echo "$as_me:1478: error: C compiler cannot create executables" >&5
1479 echo "$as_me: error: C compiler cannot create executables" >&2;}
1480 { (exit 77); exit 77; }; }
1483 ac_exeext=$ac_cv_exeext
1484 echo "$as_me:1484: result: $ac_file" >&5
1485 echo "${ECHO_T}$ac_file" >&6
1487 # Check the compiler produces executables we can run. If not, either
1488 # the compiler is broken, or we cross compile.
1489 echo "$as_me:1489: checking whether the C compiler works" >&5
1490 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
1491 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
1492 # If not cross compiling, check that we can run a simple program.
1493 if test "$cross_compiling" != yes; then
1494 if { ac_try='./$ac_file'
1495 { (eval echo "$as_me:1495: \"$ac_try\"") >&5
1498 echo "$as_me:1498: \$? = $ac_status" >&5
1499 (exit $ac_status); }; }; then
1502 if test "$cross_compiling" = maybe; then
1505 { { echo "$as_me:1505: error: cannot run C compiled programs.
1506 If you meant to cross compile, use \`--host'." >&5
1507 echo "$as_me: error: cannot run C compiled programs.
1508 If you meant to cross compile, use \`--host'." >&2;}
1509 { (exit 1); exit 1; }; }
1513 echo "$as_me:1513: result: yes" >&5
1514 echo "${ECHO_T}yes" >&6
1516 rm -f a.out a.exe conftest$ac_cv_exeext
1517 ac_clean_files=$ac_clean_files_save
1518 # Check the compiler produces executables we can run. If not, either
1519 # the compiler is broken, or we cross compile.
1520 echo "$as_me:1520: checking whether we are cross compiling" >&5
1521 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
1522 echo "$as_me:1522: result: $cross_compiling" >&5
1523 echo "${ECHO_T}$cross_compiling" >&6
1525 echo "$as_me:1525: checking for executable suffix" >&5
1526 echo $ECHO_N "checking for executable suffix... $ECHO_C" >&6
1527 if { (eval echo "$as_me:1527: \"$ac_link\"") >&5
1528 (eval $ac_link) 2>&5
1530 echo "$as_me:1530: \$? = $ac_status" >&5
1531 (exit $ac_status); }; then
1532 # If both `conftest.exe' and `conftest' are `present' (well, observable)
1533 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
1534 # work properly (i.e., refer to `conftest.exe'), while it won't with
1536 for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do
1538 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1539 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1546 { { echo "$as_me:1546: error: cannot compute EXEEXT: cannot compile and link" >&5
1547 echo "$as_me: error: cannot compute EXEEXT: cannot compile and link" >&2;}
1548 { (exit 1); exit 1; }; }
1551 rm -f conftest$ac_cv_exeext
1552 echo "$as_me:1552: result: $ac_cv_exeext" >&5
1553 echo "${ECHO_T}$ac_cv_exeext" >&6
1555 rm -f conftest.$ac_ext
1556 EXEEXT=$ac_cv_exeext
1558 echo "$as_me:1558: checking for object suffix" >&5
1559 echo $ECHO_N "checking for object suffix... $ECHO_C" >&6
1560 if test "${ac_cv_objext+set}" = set; then
1561 echo $ECHO_N "(cached) $ECHO_C" >&6
1563 cat >conftest.$ac_ext <<_ACEOF
1564 #line 1564 "configure"
1565 #include "confdefs.h"
1575 rm -f conftest.o conftest.obj
1576 if { (eval echo "$as_me:1576: \"$ac_compile\"") >&5
1577 (eval $ac_compile) 2>&5
1579 echo "$as_me:1579: \$? = $ac_status" >&5
1580 (exit $ac_status); }; then
1581 for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
1583 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.map | *.inf ) ;;
1584 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
1589 echo "$as_me: failed program was:" >&5
1590 cat conftest.$ac_ext >&5
1591 { { echo "$as_me:1591: error: cannot compute OBJEXT: cannot compile" >&5
1592 echo "$as_me: error: cannot compute OBJEXT: cannot compile" >&2;}
1593 { (exit 1); exit 1; }; }
1596 rm -f conftest.$ac_cv_objext conftest.$ac_ext
1598 echo "$as_me:1598: result: $ac_cv_objext" >&5
1599 echo "${ECHO_T}$ac_cv_objext" >&6
1600 OBJEXT=$ac_cv_objext
1602 echo "$as_me:1602: checking whether we are using the GNU C compiler" >&5
1603 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
1604 if test "${ac_cv_c_compiler_gnu+set}" = set; then
1605 echo $ECHO_N "(cached) $ECHO_C" >&6
1607 cat >conftest.$ac_ext <<_ACEOF
1608 #line 1608 "configure"
1609 #include "confdefs.h"
1622 rm -f conftest.$ac_objext
1623 if { (eval echo "$as_me:1623: \"$ac_compile\"") >&5
1624 (eval $ac_compile) 2>&5
1626 echo "$as_me:1626: \$? = $ac_status" >&5
1627 (exit $ac_status); } &&
1628 { ac_try='test -s conftest.$ac_objext'
1629 { (eval echo "$as_me:1629: \"$ac_try\"") >&5
1632 echo "$as_me:1632: \$? = $ac_status" >&5
1633 (exit $ac_status); }; }; then
1636 echo "$as_me: failed program was:" >&5
1637 cat conftest.$ac_ext >&5
1640 rm -f conftest.$ac_objext conftest.$ac_ext
1641 ac_cv_c_compiler_gnu=$ac_compiler_gnu
1644 echo "$as_me:1644: result: $ac_cv_c_compiler_gnu" >&5
1645 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
1646 GCC=`test $ac_compiler_gnu = yes && echo yes`
1647 ac_test_CFLAGS=${CFLAGS+set}
1648 ac_save_CFLAGS=$CFLAGS
1650 echo "$as_me:1650: checking whether $CC accepts -g" >&5
1651 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
1652 if test "${ac_cv_prog_cc_g+set}" = set; then
1653 echo $ECHO_N "(cached) $ECHO_C" >&6
1655 cat >conftest.$ac_ext <<_ACEOF
1656 #line 1656 "configure"
1657 #include "confdefs.h"
1667 rm -f conftest.$ac_objext
1668 if { (eval echo "$as_me:1668: \"$ac_compile\"") >&5
1669 (eval $ac_compile) 2>&5
1671 echo "$as_me:1671: \$? = $ac_status" >&5
1672 (exit $ac_status); } &&
1673 { ac_try='test -s conftest.$ac_objext'
1674 { (eval echo "$as_me:1674: \"$ac_try\"") >&5
1677 echo "$as_me:1677: \$? = $ac_status" >&5
1678 (exit $ac_status); }; }; then
1681 echo "$as_me: failed program was:" >&5
1682 cat conftest.$ac_ext >&5
1685 rm -f conftest.$ac_objext conftest.$ac_ext
1687 echo "$as_me:1687: result: $ac_cv_prog_cc_g" >&5
1688 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
1689 if test "$ac_test_CFLAGS" = set; then
1690 CFLAGS=$ac_save_CFLAGS
1691 elif test $ac_cv_prog_cc_g = yes; then
1692 if test "$GCC" = yes; then
1698 if test "$GCC" = yes; then
1704 # Some people use a C++ compiler to compile C. Since we use `exit',
1705 # in C++ we need to declare it. In case someone uses the same compiler
1706 # for both compiling C and C++ we need to have the C++ compiler decide
1707 # the declaration of exit, since it's the most demanding environment.
1708 cat >conftest.$ac_ext <<_ACEOF
1713 rm -f conftest.$ac_objext
1714 if { (eval echo "$as_me:1714: \"$ac_compile\"") >&5
1715 (eval $ac_compile) 2>&5
1717 echo "$as_me:1717: \$? = $ac_status" >&5
1718 (exit $ac_status); } &&
1719 { ac_try='test -s conftest.$ac_objext'
1720 { (eval echo "$as_me:1720: \"$ac_try\"") >&5
1723 echo "$as_me:1723: \$? = $ac_status" >&5
1724 (exit $ac_status); }; }; then
1725 for ac_declaration in \
1727 '#include <stdlib.h>' \
1728 'extern "C" void std::exit (int) throw (); using std::exit;' \
1729 'extern "C" void std::exit (int); using std::exit;' \
1730 'extern "C" void exit (int) throw ();' \
1731 'extern "C" void exit (int);' \
1734 cat >conftest.$ac_ext <<_ACEOF
1735 #line 1735 "configure"
1736 #include "confdefs.h"
1747 rm -f conftest.$ac_objext
1748 if { (eval echo "$as_me:1748: \"$ac_compile\"") >&5
1749 (eval $ac_compile) 2>&5
1751 echo "$as_me:1751: \$? = $ac_status" >&5
1752 (exit $ac_status); } &&
1753 { ac_try='test -s conftest.$ac_objext'
1754 { (eval echo "$as_me:1754: \"$ac_try\"") >&5
1757 echo "$as_me:1757: \$? = $ac_status" >&5
1758 (exit $ac_status); }; }; then
1761 echo "$as_me: failed program was:" >&5
1762 cat conftest.$ac_ext >&5
1765 rm -f conftest.$ac_objext conftest.$ac_ext
1766 cat >conftest.$ac_ext <<_ACEOF
1767 #line 1767 "configure"
1768 #include "confdefs.h"
1778 rm -f conftest.$ac_objext
1779 if { (eval echo "$as_me:1779: \"$ac_compile\"") >&5
1780 (eval $ac_compile) 2>&5
1782 echo "$as_me:1782: \$? = $ac_status" >&5
1783 (exit $ac_status); } &&
1784 { ac_try='test -s conftest.$ac_objext'
1785 { (eval echo "$as_me:1785: \"$ac_try\"") >&5
1788 echo "$as_me:1788: \$? = $ac_status" >&5
1789 (exit $ac_status); }; }; then
1792 echo "$as_me: failed program was:" >&5
1793 cat conftest.$ac_ext >&5
1795 rm -f conftest.$ac_objext conftest.$ac_ext
1798 if test -n "$ac_declaration"; then
1799 echo '#ifdef __cplusplus' >>confdefs.h
1800 echo $ac_declaration >>confdefs.h
1801 echo '#endif' >>confdefs.h
1805 echo "$as_me: failed program was:" >&5
1806 cat conftest.$ac_ext >&5
1808 rm -f conftest.$ac_objext conftest.$ac_ext
1810 ac_cpp='$CPP $CPPFLAGS'
1811 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1812 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1813 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1814 ac_main_return=return
1817 ac_cpp='$CPP $CPPFLAGS'
1818 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1819 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1820 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1821 ac_main_return=return
1822 echo "$as_me:1822: checking how to run the C preprocessor" >&5
1823 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
1824 # On Suns, sometimes $CPP names a directory.
1825 if test -n "$CPP" && test -d "$CPP"; then
1828 if test -z "$CPP"; then
1829 if test "${ac_cv_prog_CPP+set}" = set; then
1830 echo $ECHO_N "(cached) $ECHO_C" >&6
1832 # Double quotes because CPP needs to be expanded
1833 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
1836 for ac_c_preproc_warn_flag in '' yes
1838 # Use a header file that comes with gcc, so configuring glibc
1839 # with a fresh cross-compiler works.
1840 # On the NeXT, cc -E runs the code through the compiler's parser,
1841 # not just through cpp. "Syntax error" is here to catch this case.
1842 cat >conftest.$ac_ext <<_ACEOF
1843 #line 1843 "configure"
1844 #include "confdefs.h"
1848 if { (eval echo "$as_me:1848: \"$ac_cpp conftest.$ac_ext\"") >&5
1849 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
1851 egrep -v '^ *\+' conftest.er1 >conftest.err
1853 cat conftest.err >&5
1854 echo "$as_me:1854: \$? = $ac_status" >&5
1855 (exit $ac_status); } >/dev/null; then
1856 if test -s conftest.err; then
1857 ac_cpp_err=$ac_c_preproc_warn_flag
1864 if test -z "$ac_cpp_err"; then
1867 echo "$as_me: failed program was:" >&5
1868 cat conftest.$ac_ext >&5
1869 # Broken: fails on valid input.
1872 rm -f conftest.err conftest.$ac_ext
1874 # OK, works on sane cases. Now check whether non-existent headers
1875 # can be detected and how.
1876 cat >conftest.$ac_ext <<_ACEOF
1877 #line 1877 "configure"
1878 #include "confdefs.h"
1879 #include <ac_nonexistent.h>
1881 if { (eval echo "$as_me:1881: \"$ac_cpp conftest.$ac_ext\"") >&5
1882 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
1884 egrep -v '^ *\+' conftest.er1 >conftest.err
1886 cat conftest.err >&5
1887 echo "$as_me:1887: \$? = $ac_status" >&5
1888 (exit $ac_status); } >/dev/null; then
1889 if test -s conftest.err; then
1890 ac_cpp_err=$ac_c_preproc_warn_flag
1897 if test -z "$ac_cpp_err"; then
1898 # Broken: success on invalid input.
1901 echo "$as_me: failed program was:" >&5
1902 cat conftest.$ac_ext >&5
1903 # Passes both tests.
1907 rm -f conftest.err conftest.$ac_ext
1910 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
1911 rm -f conftest.err conftest.$ac_ext
1912 if $ac_preproc_ok; then
1924 echo "$as_me:1924: result: $CPP" >&5
1925 echo "${ECHO_T}$CPP" >&6
1927 for ac_c_preproc_warn_flag in '' yes
1929 # Use a header file that comes with gcc, so configuring glibc
1930 # with a fresh cross-compiler works.
1931 # On the NeXT, cc -E runs the code through the compiler's parser,
1932 # not just through cpp. "Syntax error" is here to catch this case.
1933 cat >conftest.$ac_ext <<_ACEOF
1934 #line 1934 "configure"
1935 #include "confdefs.h"
1939 if { (eval echo "$as_me:1939: \"$ac_cpp conftest.$ac_ext\"") >&5
1940 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
1942 egrep -v '^ *\+' conftest.er1 >conftest.err
1944 cat conftest.err >&5
1945 echo "$as_me:1945: \$? = $ac_status" >&5
1946 (exit $ac_status); } >/dev/null; then
1947 if test -s conftest.err; then
1948 ac_cpp_err=$ac_c_preproc_warn_flag
1955 if test -z "$ac_cpp_err"; then
1958 echo "$as_me: failed program was:" >&5
1959 cat conftest.$ac_ext >&5
1960 # Broken: fails on valid input.
1963 rm -f conftest.err conftest.$ac_ext
1965 # OK, works on sane cases. Now check whether non-existent headers
1966 # can be detected and how.
1967 cat >conftest.$ac_ext <<_ACEOF
1968 #line 1968 "configure"
1969 #include "confdefs.h"
1970 #include <ac_nonexistent.h>
1972 if { (eval echo "$as_me:1972: \"$ac_cpp conftest.$ac_ext\"") >&5
1973 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
1975 egrep -v '^ *\+' conftest.er1 >conftest.err
1977 cat conftest.err >&5
1978 echo "$as_me:1978: \$? = $ac_status" >&5
1979 (exit $ac_status); } >/dev/null; then
1980 if test -s conftest.err; then
1981 ac_cpp_err=$ac_c_preproc_warn_flag
1988 if test -z "$ac_cpp_err"; then
1989 # Broken: success on invalid input.
1992 echo "$as_me: failed program was:" >&5
1993 cat conftest.$ac_ext >&5
1994 # Passes both tests.
1998 rm -f conftest.err conftest.$ac_ext
2001 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2002 rm -f conftest.err conftest.$ac_ext
2003 if $ac_preproc_ok; then
2006 { { echo "$as_me:2006: error: C preprocessor \"$CPP\" fails sanity check" >&5
2007 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;}
2008 { (exit 1); exit 1; }; }
2012 ac_cpp='$CPP $CPPFLAGS'
2013 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2014 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2015 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2016 ac_main_return=return
2018 for ac_prog in mawk gawk nawk awk
2020 # Extract the first word of "$ac_prog", so it can be a program name with args.
2021 set dummy $ac_prog; ac_word=$2
2022 echo "$as_me:2022: checking for $ac_word" >&5
2023 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2024 if test "${ac_cv_prog_AWK+set}" = set; then
2025 echo $ECHO_N "(cached) $ECHO_C" >&6
2027 if test -n "$AWK"; then
2028 ac_cv_prog_AWK="$AWK" # Let the user override the test.
2030 ac_save_IFS=$IFS; IFS=$ac_path_separator
2032 for ac_dir in $ac_dummy; do
2034 test -z "$ac_dir" && ac_dir=.
2035 $as_executable_p "$ac_dir/$ac_word" || continue
2036 ac_cv_prog_AWK="$ac_prog"
2037 echo "$as_me:2037: found $ac_dir/$ac_word" >&5
2044 if test -n "$AWK"; then
2045 echo "$as_me:2045: result: $AWK" >&5
2046 echo "${ECHO_T}$AWK" >&6
2048 echo "$as_me:2048: result: no" >&5
2049 echo "${ECHO_T}no" >&6
2052 test -n "$AWK" && break
2055 # Find a good install program. We prefer a C program (faster),
2056 # so one script is as good as another. But avoid the broken or
2057 # incompatible versions:
2058 # SysV /etc/install, /usr/sbin/install
2059 # SunOS /usr/etc/install
2060 # IRIX /sbin/install
2062 # AmigaOS /C/install, which installs bootblocks on floppy discs
2063 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
2064 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
2065 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
2066 # ./install, which can be erroneously created by make from ./install.sh.
2067 echo "$as_me:2067: checking for a BSD compatible install" >&5
2068 echo $ECHO_N "checking for a BSD compatible install... $ECHO_C" >&6
2069 if test -z "$INSTALL"; then
2070 if test "${ac_cv_path_install+set}" = set; then
2071 echo $ECHO_N "(cached) $ECHO_C" >&6
2073 ac_save_IFS=$IFS; IFS=$ac_path_separator
2074 for ac_dir in $PATH; do
2076 # Account for people who put trailing slashes in PATH elements.
2078 / | ./ | .// | /cC/* \
2079 | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* \
2082 # OSF1 and SCO ODT 3.0 have their own names for install.
2083 # Don't use installbsd from OSF since it installs stuff as root
2085 for ac_prog in ginstall scoinst install; do
2086 if $as_executable_p "$ac_dir/$ac_prog"; then
2087 if test $ac_prog = install &&
2088 grep dspmsg "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2089 # AIX install. It has an incompatible calling convention.
2091 elif test $ac_prog = install &&
2092 grep pwplus "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2093 # program-specific install script used by HP pwplus--don't use.
2096 ac_cv_path_install="$ac_dir/$ac_prog -c"
2106 if test "${ac_cv_path_install+set}" = set; then
2107 INSTALL=$ac_cv_path_install
2109 # As a last resort, use the slow shell script. We don't cache a
2110 # path for INSTALL within a source directory, because that will
2111 # break other packages using the cache if that directory is
2112 # removed, or if the path is relative.
2113 INSTALL=$ac_install_sh
2116 echo "$as_me:2116: result: $INSTALL" >&5
2117 echo "${ECHO_T}$INSTALL" >&6
2119 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
2120 # It thinks the first close brace ends the variable substitution.
2121 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
2123 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
2125 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
2131 cf_dir=`echo $INSTALL | sed -e 's%/[^/]*$%%'`
2132 test -z "$cf_dir" && cf_dir=.
2133 INSTALL=`cd $cf_dir && pwd`/`echo $INSTALL | sed -e 's%^.*/%%'`
2137 for ac_prog in tdlint lint alint splint lclint
2139 # Extract the first word of "$ac_prog", so it can be a program name with args.
2140 set dummy $ac_prog; ac_word=$2
2141 echo "$as_me:2141: checking for $ac_word" >&5
2142 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2143 if test "${ac_cv_prog_LINT+set}" = set; then
2144 echo $ECHO_N "(cached) $ECHO_C" >&6
2146 if test -n "$LINT"; then
2147 ac_cv_prog_LINT="$LINT" # Let the user override the test.
2149 ac_save_IFS=$IFS; IFS=$ac_path_separator
2151 for ac_dir in $ac_dummy; do
2153 test -z "$ac_dir" && ac_dir=.
2154 $as_executable_p "$ac_dir/$ac_word" || continue
2155 ac_cv_prog_LINT="$ac_prog"
2156 echo "$as_me:2156: found $ac_dir/$ac_word" >&5
2162 LINT=$ac_cv_prog_LINT
2163 if test -n "$LINT"; then
2164 echo "$as_me:2164: result: $LINT" >&5
2165 echo "${ECHO_T}$LINT" >&6
2167 echo "$as_me:2167: result: no" >&5
2168 echo "${ECHO_T}no" >&6
2171 test -n "$LINT" && break
2174 echo "$as_me:2174: checking if filesystem supports mixed-case filenames" >&5
2175 echo $ECHO_N "checking if filesystem supports mixed-case filenames... $ECHO_C" >&6
2176 if test "${cf_cv_mixedcase+set}" = set; then
2177 echo $ECHO_N "(cached) $ECHO_C" >&6
2180 if test "$cross_compiling" = yes ; then
2181 case $target_alias in #(vi
2182 *-os2-emx*|*-msdosdjgpp*|*-cygwin*|*-mingw32*|*-uwin*) #(vi
2190 rm -f conftest CONFTEST
2192 if test -f CONFTEST ; then
2197 rm -f conftest CONFTEST
2201 echo "$as_me:2201: result: $cf_cv_mixedcase" >&5
2202 echo "${ECHO_T}$cf_cv_mixedcase" >&6
2203 test "$cf_cv_mixedcase" = yes && cat >>confdefs.h <<\EOF
2204 #define MIXEDCASE_FILENAMES 1
2207 for ac_prog in exctags ctags
2209 # Extract the first word of "$ac_prog", so it can be a program name with args.
2210 set dummy $ac_prog; ac_word=$2
2211 echo "$as_me:2211: checking for $ac_word" >&5
2212 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2213 if test "${ac_cv_prog_CTAGS+set}" = set; then
2214 echo $ECHO_N "(cached) $ECHO_C" >&6
2216 if test -n "$CTAGS"; then
2217 ac_cv_prog_CTAGS="$CTAGS" # Let the user override the test.
2219 ac_save_IFS=$IFS; IFS=$ac_path_separator
2221 for ac_dir in $ac_dummy; do
2223 test -z "$ac_dir" && ac_dir=.
2224 $as_executable_p "$ac_dir/$ac_word" || continue
2225 ac_cv_prog_CTAGS="$ac_prog"
2226 echo "$as_me:2226: found $ac_dir/$ac_word" >&5
2232 CTAGS=$ac_cv_prog_CTAGS
2233 if test -n "$CTAGS"; then
2234 echo "$as_me:2234: result: $CTAGS" >&5
2235 echo "${ECHO_T}$CTAGS" >&6
2237 echo "$as_me:2237: result: no" >&5
2238 echo "${ECHO_T}no" >&6
2241 test -n "$CTAGS" && break
2244 for ac_prog in exetags etags
2246 # Extract the first word of "$ac_prog", so it can be a program name with args.
2247 set dummy $ac_prog; ac_word=$2
2248 echo "$as_me:2248: checking for $ac_word" >&5
2249 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2250 if test "${ac_cv_prog_ETAGS+set}" = set; then
2251 echo $ECHO_N "(cached) $ECHO_C" >&6
2253 if test -n "$ETAGS"; then
2254 ac_cv_prog_ETAGS="$ETAGS" # Let the user override the test.
2256 ac_save_IFS=$IFS; IFS=$ac_path_separator
2258 for ac_dir in $ac_dummy; do
2260 test -z "$ac_dir" && ac_dir=.
2261 $as_executable_p "$ac_dir/$ac_word" || continue
2262 ac_cv_prog_ETAGS="$ac_prog"
2263 echo "$as_me:2263: found $ac_dir/$ac_word" >&5
2269 ETAGS=$ac_cv_prog_ETAGS
2270 if test -n "$ETAGS"; then
2271 echo "$as_me:2271: result: $ETAGS" >&5
2272 echo "${ECHO_T}$ETAGS" >&6
2274 echo "$as_me:2274: result: no" >&5
2275 echo "${ECHO_T}no" >&6
2278 test -n "$ETAGS" && break
2281 # Extract the first word of "${CTAGS:-ctags}", so it can be a program name with args.
2282 set dummy ${CTAGS:-ctags}; ac_word=$2
2283 echo "$as_me:2283: checking for $ac_word" >&5
2284 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2285 if test "${ac_cv_prog_MAKE_LOWER_TAGS+set}" = set; then
2286 echo $ECHO_N "(cached) $ECHO_C" >&6
2288 if test -n "$MAKE_LOWER_TAGS"; then
2289 ac_cv_prog_MAKE_LOWER_TAGS="$MAKE_LOWER_TAGS" # Let the user override the test.
2291 ac_save_IFS=$IFS; IFS=$ac_path_separator
2293 for ac_dir in $ac_dummy; do
2295 test -z "$ac_dir" && ac_dir=.
2296 $as_executable_p "$ac_dir/$ac_word" || continue
2297 ac_cv_prog_MAKE_LOWER_TAGS="yes"
2298 echo "$as_me:2298: found $ac_dir/$ac_word" >&5
2302 test -z "$ac_cv_prog_MAKE_LOWER_TAGS" && ac_cv_prog_MAKE_LOWER_TAGS="no"
2305 MAKE_LOWER_TAGS=$ac_cv_prog_MAKE_LOWER_TAGS
2306 if test -n "$MAKE_LOWER_TAGS"; then
2307 echo "$as_me:2307: result: $MAKE_LOWER_TAGS" >&5
2308 echo "${ECHO_T}$MAKE_LOWER_TAGS" >&6
2310 echo "$as_me:2310: result: no" >&5
2311 echo "${ECHO_T}no" >&6
2314 if test "$cf_cv_mixedcase" = yes ; then
2315 # Extract the first word of "${ETAGS:-etags}", so it can be a program name with args.
2316 set dummy ${ETAGS:-etags}; ac_word=$2
2317 echo "$as_me:2317: checking for $ac_word" >&5
2318 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2319 if test "${ac_cv_prog_MAKE_UPPER_TAGS+set}" = set; then
2320 echo $ECHO_N "(cached) $ECHO_C" >&6
2322 if test -n "$MAKE_UPPER_TAGS"; then
2323 ac_cv_prog_MAKE_UPPER_TAGS="$MAKE_UPPER_TAGS" # Let the user override the test.
2325 ac_save_IFS=$IFS; IFS=$ac_path_separator
2327 for ac_dir in $ac_dummy; do
2329 test -z "$ac_dir" && ac_dir=.
2330 $as_executable_p "$ac_dir/$ac_word" || continue
2331 ac_cv_prog_MAKE_UPPER_TAGS="yes"
2332 echo "$as_me:2332: found $ac_dir/$ac_word" >&5
2336 test -z "$ac_cv_prog_MAKE_UPPER_TAGS" && ac_cv_prog_MAKE_UPPER_TAGS="no"
2339 MAKE_UPPER_TAGS=$ac_cv_prog_MAKE_UPPER_TAGS
2340 if test -n "$MAKE_UPPER_TAGS"; then
2341 echo "$as_me:2341: result: $MAKE_UPPER_TAGS" >&5
2342 echo "${ECHO_T}$MAKE_UPPER_TAGS" >&6
2344 echo "$as_me:2344: result: no" >&5
2345 echo "${ECHO_T}no" >&6
2352 if test "$MAKE_UPPER_TAGS" = yes ; then
2358 if test "$MAKE_LOWER_TAGS" = yes ; then
2364 echo "$as_me:2364: checking if -lm needed for math functions" >&5
2365 echo $ECHO_N "checking if -lm needed for math functions... $ECHO_C" >&6
2366 if test "${cf_cv_need_libm+set}" = set; then
2367 echo $ECHO_N "(cached) $ECHO_C" >&6
2370 cat >conftest.$ac_ext <<_ACEOF
2371 #line 2371 "configure"
2372 #include "confdefs.h"
2380 double x = rand(); printf("result = %g\n", sin(x))
2385 rm -f conftest.$ac_objext conftest$ac_exeext
2386 if { (eval echo "$as_me:2386: \"$ac_link\"") >&5
2387 (eval $ac_link) 2>&5
2389 echo "$as_me:2389: \$? = $ac_status" >&5
2390 (exit $ac_status); } &&
2391 { ac_try='test -s conftest$ac_exeext'
2392 { (eval echo "$as_me:2392: \"$ac_try\"") >&5
2395 echo "$as_me:2395: \$? = $ac_status" >&5
2396 (exit $ac_status); }; }; then
2399 echo "$as_me: failed program was:" >&5
2400 cat conftest.$ac_ext >&5
2403 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
2405 echo "$as_me:2405: result: $cf_cv_need_libm" >&5
2406 echo "${ECHO_T}$cf_cv_need_libm" >&6
2407 if test "$cf_cv_need_libm" = yes
2413 CC_SHARED_OPTS=unknown
2414 CPPFLAGS="$CPPFLAGS"
2416 DFT_OBJ_SUBDIR=`pwd|sed -e's:.*/::'`
2417 DFT_UPR_MODEL="NORMAL"
2433 TINFO_ARGS='$(LIBS_CURSES)'
2434 cf_cv_abi_version=""
2435 cf_cv_rel_version=""
2440 echo "$as_me:2440: checking for ${CC:-cc} option to accept ANSI C" >&5
2441 echo $ECHO_N "checking for ${CC:-cc} option to accept ANSI C... $ECHO_C" >&6
2442 if test "${cf_cv_ansi_cc+set}" = set; then
2443 echo $ECHO_N "(cached) $ECHO_C" >&6
2447 cf_save_CFLAGS="$CFLAGS"
2448 cf_save_CPPFLAGS="$CPPFLAGS"
2449 # Don't try gcc -ansi; that turns off useful extensions and
2450 # breaks some systems' header files.
2451 # AIX -qlanglvl=ansi
2452 # Ultrix and OSF/1 -std1
2453 # HP-UX -Aa -D_HPUX_SOURCE
2455 # UnixWare 1.2 (cannot use -Xc, since ANSI/POSIX clashes)
2456 for cf_arg in "-DCC_HAS_PROTOS" \
2461 "-Aa -D_HPUX_SOURCE" \
2468 cf_new_extra_cppflags=
2470 for cf_add_cflags in $cf_arg
2472 case $cf_fix_cppflags in
2474 case $cf_add_cflags in #(vi
2475 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
2476 case $cf_add_cflags in
2478 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
2480 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
2481 && test -z "${cf_tst_cflags}" \
2482 && cf_fix_cppflags=yes
2484 if test $cf_fix_cppflags = yes ; then
2485 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2487 elif test "${cf_tst_cflags}" = "\"'" ; then
2488 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2494 *$cf_add_cflags) #(vi
2497 case $cf_add_cflags in #(vi
2499 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
2501 CPPFLAGS=`echo "$CPPFLAGS" | \
2502 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
2503 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
2507 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
2512 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
2517 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2519 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
2521 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
2522 && test -z "${cf_tst_cflags}" \
2523 && cf_fix_cppflags=no
2528 if test -n "$cf_new_cflags" ; then
2530 CFLAGS="$CFLAGS $cf_new_cflags"
2533 if test -n "$cf_new_cppflags" ; then
2535 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
2538 if test -n "$cf_new_extra_cppflags" ; then
2540 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
2543 cat >conftest.$ac_ext <<_ACEOF
2544 #line 2544 "configure"
2545 #include "confdefs.h"
2547 #ifndef CC_HAS_PROTOS
2548 #if !defined(__STDC__) || (__STDC__ != 1)
2557 int test (int i, double x);
2558 struct s1 {int (*f) (int a);};
2559 struct s2 {int (*f) (double a);};
2564 rm -f conftest.$ac_objext
2565 if { (eval echo "$as_me:2565: \"$ac_compile\"") >&5
2566 (eval $ac_compile) 2>&5
2568 echo "$as_me:2568: \$? = $ac_status" >&5
2569 (exit $ac_status); } &&
2570 { ac_try='test -s conftest.$ac_objext'
2571 { (eval echo "$as_me:2571: \"$ac_try\"") >&5
2574 echo "$as_me:2574: \$? = $ac_status" >&5
2575 (exit $ac_status); }; }; then
2576 cf_cv_ansi_cc="$cf_arg"; break
2578 echo "$as_me: failed program was:" >&5
2579 cat conftest.$ac_ext >&5
2581 rm -f conftest.$ac_objext conftest.$ac_ext
2583 CFLAGS="$cf_save_CFLAGS"
2584 CPPFLAGS="$cf_save_CPPFLAGS"
2587 echo "$as_me:2587: result: $cf_cv_ansi_cc" >&5
2588 echo "${ECHO_T}$cf_cv_ansi_cc" >&6
2590 if test "$cf_cv_ansi_cc" != "no"; then
2591 if test ".$cf_cv_ansi_cc" != ".-DCC_HAS_PROTOS"; then
2596 cf_new_extra_cppflags=
2598 for cf_add_cflags in $cf_cv_ansi_cc
2600 case $cf_fix_cppflags in
2602 case $cf_add_cflags in #(vi
2603 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
2604 case $cf_add_cflags in
2606 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
2608 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
2609 && test -z "${cf_tst_cflags}" \
2610 && cf_fix_cppflags=yes
2612 if test $cf_fix_cppflags = yes ; then
2613 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2615 elif test "${cf_tst_cflags}" = "\"'" ; then
2616 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2622 *$cf_add_cflags) #(vi
2625 case $cf_add_cflags in #(vi
2627 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
2629 CPPFLAGS=`echo "$CPPFLAGS" | \
2630 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
2631 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
2635 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
2640 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
2645 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2647 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
2649 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
2650 && test -z "${cf_tst_cflags}" \
2651 && cf_fix_cppflags=no
2656 if test -n "$cf_new_cflags" ; then
2658 CFLAGS="$CFLAGS $cf_new_cflags"
2661 if test -n "$cf_new_cppflags" ; then
2663 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
2666 if test -n "$cf_new_extra_cppflags" ; then
2668 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
2672 cat >>confdefs.h <<\EOF
2673 #define CC_HAS_PROTOS 1
2679 if test "$cf_cv_ansi_cc" = "no"; then
2680 { { echo "$as_me:2680: error: Your compiler does not appear to recognize prototypes.
2681 You have the following choices:
2682 a. adjust your compiler options
2683 b. get an up-to-date compiler
2684 c. use a wrapper such as unproto" >&5
2685 echo "$as_me: error: Your compiler does not appear to recognize prototypes.
2686 You have the following choices:
2687 a. adjust your compiler options
2688 b. get an up-to-date compiler
2689 c. use a wrapper such as unproto" >&2;}
2690 { (exit 1); exit 1; }; }
2693 if test "$GCC" = yes
2695 cat > conftest.i <<EOF
2697 #define GCC_PRINTF 0
2702 #ifndef GCC_NORETURN
2703 #define GCC_NORETURN /* nothing */
2706 #define GCC_UNUSED /* nothing */
2709 if test "$GCC" = yes
2711 { echo "$as_me:2711: checking for $CC __attribute__ directives..." >&5
2712 echo "$as_me: checking for $CC __attribute__ directives..." >&6;}
2713 cat > conftest.$ac_ext <<EOF
2714 #line 2714 "${as_me:-configure}"
2715 #include "confdefs.h"
2716 #include "conftest.h"
2717 #include "conftest.i"
2719 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
2721 #define GCC_PRINTFLIKE(fmt,var) /*nothing*/
2724 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
2726 #define GCC_SCANFLIKE(fmt,var) /*nothing*/
2728 extern void wow(char *,...) GCC_SCANFLIKE(1,2);
2729 extern void oops(char *,...) GCC_PRINTFLIKE(1,2) GCC_NORETURN;
2730 extern void foo(void) GCC_NORETURN;
2731 int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { return 0; }
2733 cf_printf_attribute=no
2734 cf_scanf_attribute=no
2735 for cf_attribute in scanf printf unused noreturn
2738 cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
2740 cf_directive="__attribute__(($cf_attribute))"
2741 echo "checking for $CC $cf_directive" 1>&5
2743 case $cf_attribute in #(vi
2745 cf_printf_attribute=yes
2746 cat >conftest.h <<EOF
2747 #define GCC_$cf_ATTRIBUTE 1
2751 cf_scanf_attribute=yes
2752 cat >conftest.h <<EOF
2753 #define GCC_$cf_ATTRIBUTE 1
2757 cat >conftest.h <<EOF
2758 #define GCC_$cf_ATTRIBUTE $cf_directive
2763 if { (eval echo "$as_me:2763: \"$ac_compile\"") >&5
2764 (eval $ac_compile) 2>&5
2766 echo "$as_me:2766: \$? = $ac_status" >&5
2767 (exit $ac_status); }; then
2768 test -n "$verbose" && echo "$as_me:2768: result: ... $cf_attribute" >&5
2769 echo "${ECHO_T}... $cf_attribute" >&6
2770 cat conftest.h >>confdefs.h
2771 case $cf_attribute in #(vi
2773 if test "$cf_printf_attribute" = no ; then
2774 cat >>confdefs.h <<EOF
2775 #define GCC_PRINTFLIKE(fmt,var) /* nothing */
2778 cat >>confdefs.h <<EOF
2779 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
2784 if test "$cf_scanf_attribute" = no ; then
2785 cat >>confdefs.h <<EOF
2786 #define GCC_SCANFLIKE(fmt,var) /* nothing */
2789 cat >>confdefs.h <<EOF
2790 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
2798 fgrep define conftest.i >>confdefs.h
2804 cf_POSIX_C_SOURCE=199506L
2807 case $host_os in #(vi
2809 cf_xopen_source="-D_ALL_SOURCE"
2815 cf_xopen_source="-D_APPLE_C_SOURCE"
2818 cf_xopen_source="-D_DARWIN_C_SOURCE"
2820 freebsd*|dragonfly*) #(vi
2821 # 5.x headers associate
2822 # _XOPEN_SOURCE=600 with _POSIX_C_SOURCE=200112L
2823 # _XOPEN_SOURCE=500 with _POSIX_C_SOURCE=199506L
2824 cf_POSIX_C_SOURCE=200112L
2826 cf_xopen_source="-D_BSD_TYPES -D__BSD_VISIBLE -D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
2829 cf_xopen_source="-D_HPUX_SOURCE -D_XOPEN_SOURCE=500"
2832 cf_xopen_source="-D_HPUX_SOURCE"
2835 cf_xopen_source="-D_SGI_SOURCE"
2837 linux*|gnu*|mint*|k*bsd*-gnu) #(vi
2839 echo "$as_me:2839: checking if we must define _GNU_SOURCE" >&5
2840 echo $ECHO_N "checking if we must define _GNU_SOURCE... $ECHO_C" >&6
2841 if test "${cf_cv_gnu_source+set}" = set; then
2842 echo $ECHO_N "(cached) $ECHO_C" >&6
2845 cat >conftest.$ac_ext <<_ACEOF
2846 #line 2846 "configure"
2847 #include "confdefs.h"
2848 #include <sys/types.h>
2853 #ifndef _XOPEN_SOURCE
2860 rm -f conftest.$ac_objext
2861 if { (eval echo "$as_me:2861: \"$ac_compile\"") >&5
2862 (eval $ac_compile) 2>&5
2864 echo "$as_me:2864: \$? = $ac_status" >&5
2865 (exit $ac_status); } &&
2866 { ac_try='test -s conftest.$ac_objext'
2867 { (eval echo "$as_me:2867: \"$ac_try\"") >&5
2870 echo "$as_me:2870: \$? = $ac_status" >&5
2871 (exit $ac_status); }; }; then
2874 echo "$as_me: failed program was:" >&5
2875 cat conftest.$ac_ext >&5
2877 CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE"
2878 cat >conftest.$ac_ext <<_ACEOF
2879 #line 2879 "configure"
2880 #include "confdefs.h"
2881 #include <sys/types.h>
2886 #ifdef _XOPEN_SOURCE
2893 rm -f conftest.$ac_objext
2894 if { (eval echo "$as_me:2894: \"$ac_compile\"") >&5
2895 (eval $ac_compile) 2>&5
2897 echo "$as_me:2897: \$? = $ac_status" >&5
2898 (exit $ac_status); } &&
2899 { ac_try='test -s conftest.$ac_objext'
2900 { (eval echo "$as_me:2900: \"$ac_try\"") >&5
2903 echo "$as_me:2903: \$? = $ac_status" >&5
2904 (exit $ac_status); }; }; then
2907 echo "$as_me: failed program was:" >&5
2908 cat conftest.$ac_ext >&5
2909 cf_cv_gnu_source=yes
2911 rm -f conftest.$ac_objext conftest.$ac_ext
2915 rm -f conftest.$ac_objext conftest.$ac_ext
2918 echo "$as_me:2918: result: $cf_cv_gnu_source" >&5
2919 echo "${ECHO_T}$cf_cv_gnu_source" >&6
2920 test "$cf_cv_gnu_source" = yes && CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE"
2924 # setting _XOPEN_SOURCE or _POSIX_SOURCE breaks <arpa/inet.h>
2927 # setting _XOPEN_SOURCE breaks IPv6 for lynx on NetBSD 1.6, breaks xterm, is not needed for ncursesw
2930 # setting _XOPEN_SOURCE breaks xterm on OpenBSD 2.8, is not needed for ncursesw
2933 cf_xopen_source="-D_OSF_SOURCE"
2936 cf_xopen_source="-D_QNX_SOURCE"
2939 # setting _XOPEN_SOURCE breaks Lynx on SCO Unix / OpenServer
2941 solaris2.1[0-9]) #(vi
2942 cf_xopen_source="-D__EXTENSIONS__ -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
2944 solaris2.[1-9]) #(vi
2945 cf_xopen_source="-D__EXTENSIONS__"
2948 echo "$as_me:2948: checking if we should define _XOPEN_SOURCE" >&5
2949 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
2950 if test "${cf_cv_xopen_source+set}" = set; then
2951 echo $ECHO_N "(cached) $ECHO_C" >&6
2954 cat >conftest.$ac_ext <<_ACEOF
2955 #line 2955 "configure"
2956 #include "confdefs.h"
2957 #include <sys/types.h>
2962 #ifndef _XOPEN_SOURCE
2969 rm -f conftest.$ac_objext
2970 if { (eval echo "$as_me:2970: \"$ac_compile\"") >&5
2971 (eval $ac_compile) 2>&5
2973 echo "$as_me:2973: \$? = $ac_status" >&5
2974 (exit $ac_status); } &&
2975 { ac_try='test -s conftest.$ac_objext'
2976 { (eval echo "$as_me:2976: \"$ac_try\"") >&5
2979 echo "$as_me:2979: \$? = $ac_status" >&5
2980 (exit $ac_status); }; }; then
2981 cf_cv_xopen_source=no
2983 echo "$as_me: failed program was:" >&5
2984 cat conftest.$ac_ext >&5
2986 CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
2987 cat >conftest.$ac_ext <<_ACEOF
2988 #line 2988 "configure"
2989 #include "confdefs.h"
2990 #include <sys/types.h>
2995 #ifdef _XOPEN_SOURCE
3002 rm -f conftest.$ac_objext
3003 if { (eval echo "$as_me:3003: \"$ac_compile\"") >&5
3004 (eval $ac_compile) 2>&5
3006 echo "$as_me:3006: \$? = $ac_status" >&5
3007 (exit $ac_status); } &&
3008 { ac_try='test -s conftest.$ac_objext'
3009 { (eval echo "$as_me:3009: \"$ac_try\"") >&5
3012 echo "$as_me:3012: \$? = $ac_status" >&5
3013 (exit $ac_status); }; }; then
3014 cf_cv_xopen_source=no
3016 echo "$as_me: failed program was:" >&5
3017 cat conftest.$ac_ext >&5
3018 cf_cv_xopen_source=$cf_XOPEN_SOURCE
3020 rm -f conftest.$ac_objext conftest.$ac_ext
3024 rm -f conftest.$ac_objext conftest.$ac_ext
3027 echo "$as_me:3027: result: $cf_cv_xopen_source" >&5
3028 echo "${ECHO_T}$cf_cv_xopen_source" >&6
3029 if test "$cf_cv_xopen_source" != no ; then
3031 CFLAGS=`echo "$CFLAGS" | \
3032 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3033 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
3035 CPPFLAGS=`echo "$CPPFLAGS" | \
3036 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3037 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
3039 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
3044 cf_new_extra_cppflags=
3046 for cf_add_cflags in $cf_temp_xopen_source
3048 case $cf_fix_cppflags in
3050 case $cf_add_cflags in #(vi
3051 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
3052 case $cf_add_cflags in
3054 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3056 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3057 && test -z "${cf_tst_cflags}" \
3058 && cf_fix_cppflags=yes
3060 if test $cf_fix_cppflags = yes ; then
3061 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3063 elif test "${cf_tst_cflags}" = "\"'" ; then
3064 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3070 *$cf_add_cflags) #(vi
3073 case $cf_add_cflags in #(vi
3075 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3077 CPPFLAGS=`echo "$CPPFLAGS" | \
3078 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3079 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3083 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
3088 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
3093 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3095 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
3097 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3098 && test -z "${cf_tst_cflags}" \
3099 && cf_fix_cppflags=no
3104 if test -n "$cf_new_cflags" ; then
3106 CFLAGS="$CFLAGS $cf_new_cflags"
3109 if test -n "$cf_new_cppflags" ; then
3111 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
3114 if test -n "$cf_new_extra_cppflags" ; then
3116 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
3121 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
3123 cf_save_CFLAGS="$CFLAGS"
3124 cf_save_CPPFLAGS="$CPPFLAGS"
3126 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
3127 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3128 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
3130 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
3131 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3132 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
3134 echo "$as_me:3134: checking if we should define _POSIX_C_SOURCE" >&5
3135 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
3136 if test "${cf_cv_posix_c_source+set}" = set; then
3137 echo $ECHO_N "(cached) $ECHO_C" >&6
3140 echo "${as_me:-configure}:3140: testing if the symbol is already defined go no further ..." 1>&5
3142 cat >conftest.$ac_ext <<_ACEOF
3143 #line 3143 "configure"
3144 #include "confdefs.h"
3145 #include <sys/types.h>
3150 #ifndef _POSIX_C_SOURCE
3157 rm -f conftest.$ac_objext
3158 if { (eval echo "$as_me:3158: \"$ac_compile\"") >&5
3159 (eval $ac_compile) 2>&5
3161 echo "$as_me:3161: \$? = $ac_status" >&5
3162 (exit $ac_status); } &&
3163 { ac_try='test -s conftest.$ac_objext'
3164 { (eval echo "$as_me:3164: \"$ac_try\"") >&5
3167 echo "$as_me:3167: \$? = $ac_status" >&5
3168 (exit $ac_status); }; }; then
3169 cf_cv_posix_c_source=no
3171 echo "$as_me: failed program was:" >&5
3172 cat conftest.$ac_ext >&5
3173 cf_want_posix_source=no
3174 case .$cf_POSIX_C_SOURCE in #(vi
3176 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
3179 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
3180 cf_want_posix_source=yes
3183 cf_want_posix_source=yes
3186 if test "$cf_want_posix_source" = yes ; then
3187 cat >conftest.$ac_ext <<_ACEOF
3188 #line 3188 "configure"
3189 #include "confdefs.h"
3190 #include <sys/types.h>
3195 #ifdef _POSIX_SOURCE
3202 rm -f conftest.$ac_objext
3203 if { (eval echo "$as_me:3203: \"$ac_compile\"") >&5
3204 (eval $ac_compile) 2>&5
3206 echo "$as_me:3206: \$? = $ac_status" >&5
3207 (exit $ac_status); } &&
3208 { ac_try='test -s conftest.$ac_objext'
3209 { (eval echo "$as_me:3209: \"$ac_try\"") >&5
3212 echo "$as_me:3212: \$? = $ac_status" >&5
3213 (exit $ac_status); }; }; then
3216 echo "$as_me: failed program was:" >&5
3217 cat conftest.$ac_ext >&5
3218 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
3220 rm -f conftest.$ac_objext conftest.$ac_ext
3223 echo "${as_me:-configure}:3223: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
3225 CFLAGS="$cf_trim_CFLAGS"
3226 CPPFLAGS="$cf_trim_CPPFLAGS $cf_cv_posix_c_source"
3228 echo "${as_me:-configure}:3228: testing if the second compile does not leave our definition intact error ..." 1>&5
3230 cat >conftest.$ac_ext <<_ACEOF
3231 #line 3231 "configure"
3232 #include "confdefs.h"
3233 #include <sys/types.h>
3238 #ifndef _POSIX_C_SOURCE
3245 rm -f conftest.$ac_objext
3246 if { (eval echo "$as_me:3246: \"$ac_compile\"") >&5
3247 (eval $ac_compile) 2>&5
3249 echo "$as_me:3249: \$? = $ac_status" >&5
3250 (exit $ac_status); } &&
3251 { ac_try='test -s conftest.$ac_objext'
3252 { (eval echo "$as_me:3252: \"$ac_try\"") >&5
3255 echo "$as_me:3255: \$? = $ac_status" >&5
3256 (exit $ac_status); }; }; then
3259 echo "$as_me: failed program was:" >&5
3260 cat conftest.$ac_ext >&5
3261 cf_cv_posix_c_source=no
3263 rm -f conftest.$ac_objext conftest.$ac_ext
3264 CFLAGS="$cf_save_CFLAGS"
3265 CPPFLAGS="$cf_save_CPPFLAGS"
3268 rm -f conftest.$ac_objext conftest.$ac_ext
3271 echo "$as_me:3271: result: $cf_cv_posix_c_source" >&5
3272 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
3274 if test "$cf_cv_posix_c_source" != no ; then
3275 CFLAGS="$cf_trim_CFLAGS"
3276 CPPFLAGS="$cf_trim_CPPFLAGS"
3281 cf_new_extra_cppflags=
3283 for cf_add_cflags in $cf_cv_posix_c_source
3285 case $cf_fix_cppflags in
3287 case $cf_add_cflags in #(vi
3288 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
3289 case $cf_add_cflags in
3291 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3293 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3294 && test -z "${cf_tst_cflags}" \
3295 && cf_fix_cppflags=yes
3297 if test $cf_fix_cppflags = yes ; then
3298 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3300 elif test "${cf_tst_cflags}" = "\"'" ; then
3301 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3307 *$cf_add_cflags) #(vi
3310 case $cf_add_cflags in #(vi
3312 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3314 CPPFLAGS=`echo "$CPPFLAGS" | \
3315 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3316 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3320 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
3325 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
3330 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3332 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
3334 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3335 && test -z "${cf_tst_cflags}" \
3336 && cf_fix_cppflags=no
3341 if test -n "$cf_new_cflags" ; then
3343 CFLAGS="$CFLAGS $cf_new_cflags"
3346 if test -n "$cf_new_cppflags" ; then
3348 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
3351 if test -n "$cf_new_extra_cppflags" ; then
3353 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
3361 if test -n "$cf_xopen_source" ; then
3366 cf_new_extra_cppflags=
3368 for cf_add_cflags in $cf_xopen_source
3370 case $cf_fix_cppflags in
3372 case $cf_add_cflags in #(vi
3373 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
3374 case $cf_add_cflags in
3376 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3378 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3379 && test -z "${cf_tst_cflags}" \
3380 && cf_fix_cppflags=yes
3382 if test $cf_fix_cppflags = yes ; then
3383 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3385 elif test "${cf_tst_cflags}" = "\"'" ; then
3386 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3392 *$cf_add_cflags) #(vi
3395 case $cf_add_cflags in #(vi
3397 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3399 CPPFLAGS=`echo "$CPPFLAGS" | \
3400 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3401 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3405 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
3410 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
3415 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3417 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
3419 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3420 && test -z "${cf_tst_cflags}" \
3421 && cf_fix_cppflags=no
3426 if test -n "$cf_new_cflags" ; then
3428 CFLAGS="$CFLAGS $cf_new_cflags"
3431 if test -n "$cf_new_cppflags" ; then
3433 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
3436 if test -n "$cf_new_extra_cppflags" ; then
3438 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
3443 echo "$as_me:3443: checking for $CC option to accept ANSI C" >&5
3444 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
3445 if test "${ac_cv_prog_cc_stdc+set}" = set; then
3446 echo $ECHO_N "(cached) $ECHO_C" >&6
3448 ac_cv_prog_cc_stdc=no
3450 cat >conftest.$ac_ext <<_ACEOF
3451 #line 3451 "configure"
3452 #include "confdefs.h"
3455 #include <sys/types.h>
3456 #include <sys/stat.h>
3457 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
3458 struct buf { int x; };
3459 FILE * (*rcsopen) (struct buf *, struct stat *, int);
3460 static char *e (p, i)
3466 static char *f (char * (*g) (char **, int), char **p, ...)
3471 s = g (p, va_arg (v,int));
3475 int test (int i, double x);
3476 struct s1 {int (*f) (int a);};
3477 struct s2 {int (*f) (double a);};
3478 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3484 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
3489 # Don't try gcc -ansi; that turns off useful extensions and
3490 # breaks some systems' header files.
3491 # AIX -qlanglvl=ansi
3492 # Ultrix and OSF/1 -std1
3493 # HP-UX 10.20 and later -Ae
3494 # HP-UX older versions -Aa -D_HPUX_SOURCE
3495 # SVR4 -Xc -D__EXTENSIONS__
3496 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3498 CC="$ac_save_CC $ac_arg"
3499 rm -f conftest.$ac_objext
3500 if { (eval echo "$as_me:3500: \"$ac_compile\"") >&5
3501 (eval $ac_compile) 2>&5
3503 echo "$as_me:3503: \$? = $ac_status" >&5
3504 (exit $ac_status); } &&
3505 { ac_try='test -s conftest.$ac_objext'
3506 { (eval echo "$as_me:3506: \"$ac_try\"") >&5
3509 echo "$as_me:3509: \$? = $ac_status" >&5
3510 (exit $ac_status); }; }; then
3511 ac_cv_prog_cc_stdc=$ac_arg
3514 echo "$as_me: failed program was:" >&5
3515 cat conftest.$ac_ext >&5
3517 rm -f conftest.$ac_objext
3519 rm -f conftest.$ac_ext conftest.$ac_objext
3524 case "x$ac_cv_prog_cc_stdc" in
3526 echo "$as_me:3526: result: none needed" >&5
3527 echo "${ECHO_T}none needed" >&6 ;;
3529 echo "$as_me:3529: result: $ac_cv_prog_cc_stdc" >&5
3530 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
3531 CC="$CC $ac_cv_prog_cc_stdc" ;;
3534 echo "$as_me:3534: checking for an ANSI C-conforming const" >&5
3535 echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
3536 if test "${ac_cv_c_const+set}" = set; then
3537 echo $ECHO_N "(cached) $ECHO_C" >&6
3539 cat >conftest.$ac_ext <<_ACEOF
3540 #line 3540 "configure"
3541 #include "confdefs.h"
3546 /* FIXME: Include the comments suggested by Paul. */
3548 /* Ultrix mips cc rejects this. */
3549 typedef int charset[2];
3551 /* SunOS 4.1.1 cc rejects this. */
3552 char const *const *ccp;
3554 /* NEC SVR4.0.2 mips cc rejects this. */
3555 struct point {int x, y;};
3556 static struct point const zero = {0,0};
3557 /* AIX XL C 1.02.0.0 rejects this.
3558 It does not let you subtract one const X* pointer from another in
3559 an arm of an if-expression whose if-part is not a constant
3561 const char *g = "string";
3562 ccp = &g + (g ? g-g : 0);
3563 /* HPUX 7.0 cc rejects these. */
3566 ccp = (char const *const *) p;
3567 { /* SCO 3.2v4 cc rejects this. */
3569 char const *s = 0 ? (char *) 0 : (char const *) 0;
3573 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
3575 const int *foo = &x[0];
3578 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
3579 typedef const int *iptr;
3583 { /* AIX XL C 1.02.0.0 rejects this saying
3584 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
3585 struct s { int j; const int *ap[3]; };
3586 struct s *b; b->j = 5;
3588 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
3597 rm -f conftest.$ac_objext
3598 if { (eval echo "$as_me:3598: \"$ac_compile\"") >&5
3599 (eval $ac_compile) 2>&5
3601 echo "$as_me:3601: \$? = $ac_status" >&5
3602 (exit $ac_status); } &&
3603 { ac_try='test -s conftest.$ac_objext'
3604 { (eval echo "$as_me:3604: \"$ac_try\"") >&5
3607 echo "$as_me:3607: \$? = $ac_status" >&5
3608 (exit $ac_status); }; }; then
3611 echo "$as_me: failed program was:" >&5
3612 cat conftest.$ac_ext >&5
3615 rm -f conftest.$ac_objext conftest.$ac_ext
3617 echo "$as_me:3617: result: $ac_cv_c_const" >&5
3618 echo "${ECHO_T}$ac_cv_c_const" >&6
3619 if test $ac_cv_c_const = no; then
3621 cat >>confdefs.h <<\EOF
3627 echo "$as_me:3627: checking for signal global datatype" >&5
3628 echo $ECHO_N "checking for signal global datatype... $ECHO_C" >&6
3629 if test "${cf_cv_sig_atomic_t+set}" = set; then
3630 echo $ECHO_N "(cached) $ECHO_C" >&6
3634 "volatile sig_atomic_t" \
3638 cat >conftest.$ac_ext <<_ACEOF
3639 #line 3639 "configure"
3640 #include "confdefs.h"
3642 #include <sys/types.h>
3648 static void handler(int sig)
3655 signal(SIGINT, handler);
3661 rm -f conftest.$ac_objext
3662 if { (eval echo "$as_me:3662: \"$ac_compile\"") >&5
3663 (eval $ac_compile) 2>&5
3665 echo "$as_me:3665: \$? = $ac_status" >&5
3666 (exit $ac_status); } &&
3667 { ac_try='test -s conftest.$ac_objext'
3668 { (eval echo "$as_me:3668: \"$ac_try\"") >&5
3671 echo "$as_me:3671: \$? = $ac_status" >&5
3672 (exit $ac_status); }; }; then
3673 cf_cv_sig_atomic_t=$cf_type
3675 echo "$as_me: failed program was:" >&5
3676 cat conftest.$ac_ext >&5
3677 cf_cv_sig_atomic_t=no
3679 rm -f conftest.$ac_objext conftest.$ac_ext
3680 test "$cf_cv_sig_atomic_t" != no && break
3685 echo "$as_me:3685: result: $cf_cv_sig_atomic_t" >&5
3686 echo "${ECHO_T}$cf_cv_sig_atomic_t" >&6
3687 test "$cf_cv_sig_atomic_t" != no && cat >>confdefs.h <<EOF
3688 #define SIG_ATOMIC_T $cf_cv_sig_atomic_t
3691 echo "$as_me:3691: checking if you want to see long compiling messages" >&5
3692 echo $ECHO_N "checking if you want to see long compiling messages... $ECHO_C" >&6
3694 # Check whether --enable-echo or --disable-echo was given.
3695 if test "${enable_echo+set}" = set; then
3696 enableval="$enable_echo"
3697 test "$enableval" != no && enableval=yes
3698 if test "$enableval" != "yes" ; then
3701 ECHO_LD='@echo linking $@;'
3702 RULE_CC='@echo compiling $<'
3703 SHOW_CC='@echo compiling $@'
3725 echo "$as_me:3725: result: $enableval" >&5
3726 echo "${ECHO_T}$enableval" >&6
3729 if test "$GCC" = yes ; then
3730 echo "$as_me:3730: checking version of $CC" >&5
3731 echo $ECHO_N "checking version of $CC... $ECHO_C" >&6
3732 GCC_VERSION="`${CC} --version 2>/dev/null | sed -e '2,$d' -e 's/^.*(GCC) //' -e 's/^[^0-9.]*//' -e 's/[^0-9.].*//'`"
3733 test -z "$GCC_VERSION" && GCC_VERSION=unknown
3734 echo "$as_me:3734: result: $GCC_VERSION" >&5
3735 echo "${ECHO_T}$GCC_VERSION" >&6
3738 if ( test "$GCC" = yes || test "$GXX" = yes )
3740 echo "$as_me:3740: checking if you want to turn on gcc warnings" >&5
3741 echo $ECHO_N "checking if you want to turn on gcc warnings... $ECHO_C" >&6
3743 # Check whether --enable-warnings or --disable-warnings was given.
3744 if test "${enable_warnings+set}" = set; then
3745 enableval="$enable_warnings"
3746 test "$enableval" != yes && enableval=no
3747 if test "$enableval" != "no" ; then
3757 echo "$as_me:3757: result: $with_warnings" >&5
3758 echo "${ECHO_T}$with_warnings" >&6
3759 if test "$with_warnings" = "yes"
3762 if test "$GCC" = yes
3764 cat > conftest.i <<EOF
3766 #define GCC_PRINTF 0
3771 #ifndef GCC_NORETURN
3772 #define GCC_NORETURN /* nothing */
3775 #define GCC_UNUSED /* nothing */
3778 if test "$GCC" = yes
3780 { echo "$as_me:3780: checking for $CC __attribute__ directives..." >&5
3781 echo "$as_me: checking for $CC __attribute__ directives..." >&6;}
3782 cat > conftest.$ac_ext <<EOF
3783 #line 3783 "${as_me:-configure}"
3784 #include "confdefs.h"
3785 #include "conftest.h"
3786 #include "conftest.i"
3788 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
3790 #define GCC_PRINTFLIKE(fmt,var) /*nothing*/
3793 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
3795 #define GCC_SCANFLIKE(fmt,var) /*nothing*/
3797 extern void wow(char *,...) GCC_SCANFLIKE(1,2);
3798 extern void oops(char *,...) GCC_PRINTFLIKE(1,2) GCC_NORETURN;
3799 extern void foo(void) GCC_NORETURN;
3800 int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { return 0; }
3802 cf_printf_attribute=no
3803 cf_scanf_attribute=no
3804 for cf_attribute in scanf printf unused noreturn
3807 cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
3809 cf_directive="__attribute__(($cf_attribute))"
3810 echo "checking for $CC $cf_directive" 1>&5
3812 case $cf_attribute in #(vi
3814 cf_printf_attribute=yes
3815 cat >conftest.h <<EOF
3816 #define GCC_$cf_ATTRIBUTE 1
3820 cf_scanf_attribute=yes
3821 cat >conftest.h <<EOF
3822 #define GCC_$cf_ATTRIBUTE 1
3826 cat >conftest.h <<EOF
3827 #define GCC_$cf_ATTRIBUTE $cf_directive
3832 if { (eval echo "$as_me:3832: \"$ac_compile\"") >&5
3833 (eval $ac_compile) 2>&5
3835 echo "$as_me:3835: \$? = $ac_status" >&5
3836 (exit $ac_status); }; then
3837 test -n "$verbose" && echo "$as_me:3837: result: ... $cf_attribute" >&5
3838 echo "${ECHO_T}... $cf_attribute" >&6
3839 cat conftest.h >>confdefs.h
3840 case $cf_attribute in #(vi
3842 if test "$cf_printf_attribute" = no ; then
3843 cat >>confdefs.h <<EOF
3844 #define GCC_PRINTFLIKE(fmt,var) /* nothing */
3847 cat >>confdefs.h <<EOF
3848 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
3853 if test "$cf_scanf_attribute" = no ; then
3854 cat >>confdefs.h <<EOF
3855 #define GCC_SCANFLIKE(fmt,var) /* nothing */
3858 cat >>confdefs.h <<EOF
3859 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
3867 fgrep define conftest.i >>confdefs.h
3874 if test "$GCC" = yes ; then
3877 echo "$as_me:3877: checking if this is really Intel C compiler" >&5
3878 echo $ECHO_N "checking if this is really Intel C compiler... $ECHO_C" >&6
3879 cf_save_CFLAGS="$CFLAGS"
3880 CFLAGS="$CFLAGS -no-gcc"
3881 cat >conftest.$ac_ext <<_ACEOF
3882 #line 3882 "configure"
3883 #include "confdefs.h"
3889 #ifdef __INTEL_COMPILER
3898 rm -f conftest.$ac_objext
3899 if { (eval echo "$as_me:3899: \"$ac_compile\"") >&5
3900 (eval $ac_compile) 2>&5
3902 echo "$as_me:3902: \$? = $ac_status" >&5
3903 (exit $ac_status); } &&
3904 { ac_try='test -s conftest.$ac_objext'
3905 { (eval echo "$as_me:3905: \"$ac_try\"") >&5
3908 echo "$as_me:3908: \$? = $ac_status" >&5
3909 (exit $ac_status); }; }; then
3911 cf_save_CFLAGS="$cf_save_CFLAGS -we147 -no-gcc"
3914 echo "$as_me: failed program was:" >&5
3915 cat conftest.$ac_ext >&5
3917 rm -f conftest.$ac_objext conftest.$ac_ext
3918 CFLAGS="$cf_save_CFLAGS"
3919 echo "$as_me:3919: result: $INTEL_COMPILER" >&5
3920 echo "${ECHO_T}$INTEL_COMPILER" >&6
3925 cat > conftest.$ac_ext <<EOF
3926 #line 3926 "${as_me:-configure}"
3927 int main(int argc, char *argv[]) { return (argv[argc-1] == 0) ; }
3930 if test "$INTEL_COMPILER" = yes
3932 # The "-wdXXX" options suppress warnings:
3933 # remark #1419: external declaration in primary source file
3934 # remark #1683: explicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem)
3935 # remark #1684: conversion from pointer to same-sized integral type (potential portability problem)
3936 # remark #193: zero used for undefined preprocessing identifier
3937 # remark #593: variable "curs_sb_left_arrow" was set but never used
3938 # remark #810: conversion from "int" to "Dimension={unsigned short}" may lose significant bits
3939 # remark #869: parameter "tw" was never referenced
3940 # remark #981: operands are evaluated in unspecified order
3941 # warning #279: controlling expression is constant
3943 { echo "$as_me:3943: checking for $CC warning options..." >&5
3944 echo "$as_me: checking for $CC warning options..." >&6;}
3945 cf_save_CFLAGS="$CFLAGS"
3946 EXTRA_CFLAGS="-Wall"
3958 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
3959 if { (eval echo "$as_me:3959: \"$ac_compile\"") >&5
3960 (eval $ac_compile) 2>&5
3962 echo "$as_me:3962: \$? = $ac_status" >&5
3963 (exit $ac_status); }; then
3964 test -n "$verbose" && echo "$as_me:3964: result: ... -$cf_opt" >&5
3965 echo "${ECHO_T}... -$cf_opt" >&6
3966 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
3969 CFLAGS="$cf_save_CFLAGS"
3971 elif test "$GCC" = yes
3973 { echo "$as_me:3973: checking for $CC warning options..." >&5
3974 echo "$as_me: checking for $CC warning options..." >&6;}
3975 cf_save_CFLAGS="$CFLAGS"
3978 test "$with_ext_const" = yes && cf_warn_CONST="Wwrite-strings"
3979 for cf_opt in W Wall \
3980 Wbad-function-cast \
3984 Wmissing-declarations \
3985 Wmissing-prototypes \
3989 Wstrict-prototypes \
3990 Wundef $cf_warn_CONST
3992 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
3993 if { (eval echo "$as_me:3993: \"$ac_compile\"") >&5
3994 (eval $ac_compile) 2>&5
3996 echo "$as_me:3996: \$? = $ac_status" >&5
3997 (exit $ac_status); }; then
3998 test -n "$verbose" && echo "$as_me:3998: result: ... -$cf_opt" >&5
3999 echo "${ECHO_T}... -$cf_opt" >&6
4000 case $cf_opt in #(vi
4002 CPPFLAGS="$CPPFLAGS -DXTSTRINGDEFINES"
4005 case $GCC_VERSION in
4007 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
4009 echo "${as_me:-configure}:4009: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
4015 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
4018 CFLAGS="$cf_save_CFLAGS"
4025 echo "$as_me:4025: checking if you want to use dmalloc for testing" >&5
4026 echo $ECHO_N "checking if you want to use dmalloc for testing... $ECHO_C" >&6
4028 # Check whether --with-dmalloc or --without-dmalloc was given.
4029 if test "${with_dmalloc+set}" = set; then
4030 withval="$with_dmalloc"
4031 cat >>confdefs.h <<\EOF
4032 #define USE_DMALLOC 1
4035 : ${with_cflags:=-g}
4036 : ${with_no_leaks:=yes}
4041 echo "$as_me:4041: result: ${with_dmalloc:-no}" >&5
4042 echo "${ECHO_T}${with_dmalloc:-no}" >&6
4044 case .$with_cflags in #(vi
4046 case .$CFLAGS in #(vi
4054 cf_new_extra_cppflags=
4056 for cf_add_cflags in -g
4058 case $cf_fix_cppflags in
4060 case $cf_add_cflags in #(vi
4061 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
4062 case $cf_add_cflags in
4064 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4066 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
4067 && test -z "${cf_tst_cflags}" \
4068 && cf_fix_cppflags=yes
4070 if test $cf_fix_cppflags = yes ; then
4071 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4073 elif test "${cf_tst_cflags}" = "\"'" ; then
4074 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4080 *$cf_add_cflags) #(vi
4083 case $cf_add_cflags in #(vi
4085 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4087 CPPFLAGS=`echo "$CPPFLAGS" | \
4088 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4089 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4093 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
4098 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
4103 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4105 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
4107 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
4108 && test -z "${cf_tst_cflags}" \
4109 && cf_fix_cppflags=no
4114 if test -n "$cf_new_cflags" ; then
4116 CFLAGS="$CFLAGS $cf_new_cflags"
4119 if test -n "$cf_new_cppflags" ; then
4121 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
4124 if test -n "$cf_new_extra_cppflags" ; then
4126 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
4134 if test "$with_dmalloc" = yes ; then
4135 echo "$as_me:4135: checking for dmalloc.h" >&5
4136 echo $ECHO_N "checking for dmalloc.h... $ECHO_C" >&6
4137 if test "${ac_cv_header_dmalloc_h+set}" = set; then
4138 echo $ECHO_N "(cached) $ECHO_C" >&6
4140 cat >conftest.$ac_ext <<_ACEOF
4141 #line 4141 "configure"
4142 #include "confdefs.h"
4143 #include <dmalloc.h>
4145 if { (eval echo "$as_me:4145: \"$ac_cpp conftest.$ac_ext\"") >&5
4146 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4148 egrep -v '^ *\+' conftest.er1 >conftest.err
4150 cat conftest.err >&5
4151 echo "$as_me:4151: \$? = $ac_status" >&5
4152 (exit $ac_status); } >/dev/null; then
4153 if test -s conftest.err; then
4154 ac_cpp_err=$ac_c_preproc_warn_flag
4161 if test -z "$ac_cpp_err"; then
4162 ac_cv_header_dmalloc_h=yes
4164 echo "$as_me: failed program was:" >&5
4165 cat conftest.$ac_ext >&5
4166 ac_cv_header_dmalloc_h=no
4168 rm -f conftest.err conftest.$ac_ext
4170 echo "$as_me:4170: result: $ac_cv_header_dmalloc_h" >&5
4171 echo "${ECHO_T}$ac_cv_header_dmalloc_h" >&6
4172 if test $ac_cv_header_dmalloc_h = yes; then
4174 echo "$as_me:4174: checking for dmalloc_debug in -ldmalloc" >&5
4175 echo $ECHO_N "checking for dmalloc_debug in -ldmalloc... $ECHO_C" >&6
4176 if test "${ac_cv_lib_dmalloc_dmalloc_debug+set}" = set; then
4177 echo $ECHO_N "(cached) $ECHO_C" >&6
4179 ac_check_lib_save_LIBS=$LIBS
4180 LIBS="-ldmalloc $LIBS"
4181 cat >conftest.$ac_ext <<_ACEOF
4182 #line 4182 "configure"
4183 #include "confdefs.h"
4185 /* Override any gcc2 internal prototype to avoid an error. */
4189 /* We use char because int might match the return type of a gcc2
4190 builtin and then its argument prototype would still apply. */
4191 char dmalloc_debug ();
4200 rm -f conftest.$ac_objext conftest$ac_exeext
4201 if { (eval echo "$as_me:4201: \"$ac_link\"") >&5
4202 (eval $ac_link) 2>&5
4204 echo "$as_me:4204: \$? = $ac_status" >&5
4205 (exit $ac_status); } &&
4206 { ac_try='test -s conftest$ac_exeext'
4207 { (eval echo "$as_me:4207: \"$ac_try\"") >&5
4210 echo "$as_me:4210: \$? = $ac_status" >&5
4211 (exit $ac_status); }; }; then
4212 ac_cv_lib_dmalloc_dmalloc_debug=yes
4214 echo "$as_me: failed program was:" >&5
4215 cat conftest.$ac_ext >&5
4216 ac_cv_lib_dmalloc_dmalloc_debug=no
4218 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4219 LIBS=$ac_check_lib_save_LIBS
4221 echo "$as_me:4221: result: $ac_cv_lib_dmalloc_dmalloc_debug" >&5
4222 echo "${ECHO_T}$ac_cv_lib_dmalloc_dmalloc_debug" >&6
4223 if test $ac_cv_lib_dmalloc_dmalloc_debug = yes; then
4224 cat >>confdefs.h <<EOF
4225 #define HAVE_LIBDMALLOC 1
4228 LIBS="-ldmalloc $LIBS"
4236 echo "$as_me:4236: checking if you want to use dbmalloc for testing" >&5
4237 echo $ECHO_N "checking if you want to use dbmalloc for testing... $ECHO_C" >&6
4239 # Check whether --with-dbmalloc or --without-dbmalloc was given.
4240 if test "${with_dbmalloc+set}" = set; then
4241 withval="$with_dbmalloc"
4242 cat >>confdefs.h <<\EOF
4243 #define USE_DBMALLOC 1
4246 : ${with_cflags:=-g}
4247 : ${with_no_leaks:=yes}
4252 echo "$as_me:4252: result: ${with_dbmalloc:-no}" >&5
4253 echo "${ECHO_T}${with_dbmalloc:-no}" >&6
4255 case .$with_cflags in #(vi
4257 case .$CFLAGS in #(vi
4265 cf_new_extra_cppflags=
4267 for cf_add_cflags in -g
4269 case $cf_fix_cppflags in
4271 case $cf_add_cflags in #(vi
4272 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
4273 case $cf_add_cflags in
4275 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4277 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
4278 && test -z "${cf_tst_cflags}" \
4279 && cf_fix_cppflags=yes
4281 if test $cf_fix_cppflags = yes ; then
4282 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4284 elif test "${cf_tst_cflags}" = "\"'" ; then
4285 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4291 *$cf_add_cflags) #(vi
4294 case $cf_add_cflags in #(vi
4296 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4298 CPPFLAGS=`echo "$CPPFLAGS" | \
4299 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4300 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4304 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
4309 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
4314 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4316 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
4318 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
4319 && test -z "${cf_tst_cflags}" \
4320 && cf_fix_cppflags=no
4325 if test -n "$cf_new_cflags" ; then
4327 CFLAGS="$CFLAGS $cf_new_cflags"
4330 if test -n "$cf_new_cppflags" ; then
4332 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
4335 if test -n "$cf_new_extra_cppflags" ; then
4337 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
4345 if test "$with_dbmalloc" = yes ; then
4346 echo "$as_me:4346: checking for dbmalloc.h" >&5
4347 echo $ECHO_N "checking for dbmalloc.h... $ECHO_C" >&6
4348 if test "${ac_cv_header_dbmalloc_h+set}" = set; then
4349 echo $ECHO_N "(cached) $ECHO_C" >&6
4351 cat >conftest.$ac_ext <<_ACEOF
4352 #line 4352 "configure"
4353 #include "confdefs.h"
4354 #include <dbmalloc.h>
4356 if { (eval echo "$as_me:4356: \"$ac_cpp conftest.$ac_ext\"") >&5
4357 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4359 egrep -v '^ *\+' conftest.er1 >conftest.err
4361 cat conftest.err >&5
4362 echo "$as_me:4362: \$? = $ac_status" >&5
4363 (exit $ac_status); } >/dev/null; then
4364 if test -s conftest.err; then
4365 ac_cpp_err=$ac_c_preproc_warn_flag
4372 if test -z "$ac_cpp_err"; then
4373 ac_cv_header_dbmalloc_h=yes
4375 echo "$as_me: failed program was:" >&5
4376 cat conftest.$ac_ext >&5
4377 ac_cv_header_dbmalloc_h=no
4379 rm -f conftest.err conftest.$ac_ext
4381 echo "$as_me:4381: result: $ac_cv_header_dbmalloc_h" >&5
4382 echo "${ECHO_T}$ac_cv_header_dbmalloc_h" >&6
4383 if test $ac_cv_header_dbmalloc_h = yes; then
4385 echo "$as_me:4385: checking for debug_malloc in -ldbmalloc" >&5
4386 echo $ECHO_N "checking for debug_malloc in -ldbmalloc... $ECHO_C" >&6
4387 if test "${ac_cv_lib_dbmalloc_debug_malloc+set}" = set; then
4388 echo $ECHO_N "(cached) $ECHO_C" >&6
4390 ac_check_lib_save_LIBS=$LIBS
4391 LIBS="-ldbmalloc $LIBS"
4392 cat >conftest.$ac_ext <<_ACEOF
4393 #line 4393 "configure"
4394 #include "confdefs.h"
4396 /* Override any gcc2 internal prototype to avoid an error. */
4400 /* We use char because int might match the return type of a gcc2
4401 builtin and then its argument prototype would still apply. */
4402 char debug_malloc ();
4411 rm -f conftest.$ac_objext conftest$ac_exeext
4412 if { (eval echo "$as_me:4412: \"$ac_link\"") >&5
4413 (eval $ac_link) 2>&5
4415 echo "$as_me:4415: \$? = $ac_status" >&5
4416 (exit $ac_status); } &&
4417 { ac_try='test -s conftest$ac_exeext'
4418 { (eval echo "$as_me:4418: \"$ac_try\"") >&5
4421 echo "$as_me:4421: \$? = $ac_status" >&5
4422 (exit $ac_status); }; }; then
4423 ac_cv_lib_dbmalloc_debug_malloc=yes
4425 echo "$as_me: failed program was:" >&5
4426 cat conftest.$ac_ext >&5
4427 ac_cv_lib_dbmalloc_debug_malloc=no
4429 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4430 LIBS=$ac_check_lib_save_LIBS
4432 echo "$as_me:4432: result: $ac_cv_lib_dbmalloc_debug_malloc" >&5
4433 echo "${ECHO_T}$ac_cv_lib_dbmalloc_debug_malloc" >&6
4434 if test $ac_cv_lib_dbmalloc_debug_malloc = yes; then
4435 cat >>confdefs.h <<EOF
4436 #define HAVE_LIBDBMALLOC 1
4439 LIBS="-ldbmalloc $LIBS"
4447 echo "$as_me:4447: checking if you want to use valgrind for testing" >&5
4448 echo $ECHO_N "checking if you want to use valgrind for testing... $ECHO_C" >&6
4450 # Check whether --with-valgrind or --without-valgrind was given.
4451 if test "${with_valgrind+set}" = set; then
4452 withval="$with_valgrind"
4453 cat >>confdefs.h <<\EOF
4454 #define USE_VALGRIND 1
4457 : ${with_cflags:=-g}
4458 : ${with_no_leaks:=yes}
4463 echo "$as_me:4463: result: ${with_valgrind:-no}" >&5
4464 echo "${ECHO_T}${with_valgrind:-no}" >&6
4466 case .$with_cflags in #(vi
4468 case .$CFLAGS in #(vi
4476 cf_new_extra_cppflags=
4478 for cf_add_cflags in -g
4480 case $cf_fix_cppflags in
4482 case $cf_add_cflags in #(vi
4483 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
4484 case $cf_add_cflags in
4486 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4488 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
4489 && test -z "${cf_tst_cflags}" \
4490 && cf_fix_cppflags=yes
4492 if test $cf_fix_cppflags = yes ; then
4493 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4495 elif test "${cf_tst_cflags}" = "\"'" ; then
4496 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4502 *$cf_add_cflags) #(vi
4505 case $cf_add_cflags in #(vi
4507 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4509 CPPFLAGS=`echo "$CPPFLAGS" | \
4510 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4511 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4515 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
4520 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
4525 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4527 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
4529 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
4530 && test -z "${cf_tst_cflags}" \
4531 && cf_fix_cppflags=no
4536 if test -n "$cf_new_cflags" ; then
4538 CFLAGS="$CFLAGS $cf_new_cflags"
4541 if test -n "$cf_new_cppflags" ; then
4543 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
4546 if test -n "$cf_new_extra_cppflags" ; then
4548 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
4556 echo "$as_me:4556: checking if you want to perform memory-leak testing" >&5
4557 echo $ECHO_N "checking if you want to perform memory-leak testing... $ECHO_C" >&6
4559 # Check whether --enable-leaks or --disable-leaks was given.
4560 if test "${enable_leaks+set}" = set; then
4561 enableval="$enable_leaks"
4562 if test "x$enableval" = xno; then with_no_leaks=yes; else with_no_leaks=no; fi
4564 : ${with_no_leaks:=no}
4566 echo "$as_me:4566: result: $with_no_leaks" >&5
4567 echo "${ECHO_T}$with_no_leaks" >&6
4569 if test "$with_no_leaks" = yes ; then
4570 cat >>confdefs.h <<\EOF
4574 cat >>confdefs.h <<\EOF
4575 #define YY_NO_LEAKS 1
4580 echo "$as_me:4580: checking if you want to check for wide-character functions" >&5
4581 echo $ECHO_N "checking if you want to check for wide-character functions... $ECHO_C" >&6
4583 # Check whether --enable-widec or --disable-widec was given.
4584 if test "${enable_widec+set}" = set; then
4585 enableval="$enable_widec"
4586 test "$enableval" != no && enableval=yes
4587 if test "$enableval" != "yes" ; then
4597 echo "$as_me:4597: result: $cf_enable_widec" >&5
4598 echo "${ECHO_T}$cf_enable_widec" >&6
4600 echo "$as_me:4600: checking for specific curses-directory" >&5
4601 echo $ECHO_N "checking for specific curses-directory... $ECHO_C" >&6
4603 # Check whether --with-curses-dir or --without-curses-dir was given.
4604 if test "${with_curses_dir+set}" = set; then
4605 withval="$with_curses_dir"
4606 cf_cv_curses_dir=$withval
4610 echo "$as_me:4610: result: $cf_cv_curses_dir" >&5
4611 echo "${ECHO_T}$cf_cv_curses_dir" >&6
4613 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
4616 if test "x$prefix" != xNONE; then
4617 cf_path_syntax="$prefix"
4619 cf_path_syntax="$ac_default_prefix"
4622 case ".$withval" in #(vi
4623 .\$\(*\)*|.\'*\'*) #(vi
4627 .[a-zA-Z]:[\\/]*) #(vi OS/2 EMX
4630 eval withval="$withval"
4631 case ".$withval" in #(vi
4633 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
4638 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
4641 { { echo "$as_me:4641: error: expected a pathname, not \"$withval\"" >&5
4642 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
4643 { (exit 1); exit 1; }; }
4647 if test -d "$cf_cv_curses_dir"
4650 if test -n "$cf_cv_curses_dir/include" ; then
4651 for cf_add_incdir in $cf_cv_curses_dir/include
4653 while test $cf_add_incdir != /usr/include
4655 if test -d $cf_add_incdir
4658 if test -n "$CFLAGS$CPPFLAGS" ; then
4659 # a loop is needed to ensure we can add subdirs of existing dirs
4660 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
4661 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
4662 cf_have_incdir=yes; break
4667 if test "$cf_have_incdir" = no ; then
4668 if test "$cf_add_incdir" = /usr/local/include ; then
4669 if test "$GCC" = yes
4671 cf_save_CPPFLAGS=$CPPFLAGS
4672 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
4673 cat >conftest.$ac_ext <<_ACEOF
4674 #line 4674 "configure"
4675 #include "confdefs.h"
4685 rm -f conftest.$ac_objext
4686 if { (eval echo "$as_me:4686: \"$ac_compile\"") >&5
4687 (eval $ac_compile) 2>&5
4689 echo "$as_me:4689: \$? = $ac_status" >&5
4690 (exit $ac_status); } &&
4691 { ac_try='test -s conftest.$ac_objext'
4692 { (eval echo "$as_me:4692: \"$ac_try\"") >&5
4695 echo "$as_me:4695: \$? = $ac_status" >&5
4696 (exit $ac_status); }; }; then
4699 echo "$as_me: failed program was:" >&5
4700 cat conftest.$ac_ext >&5
4703 rm -f conftest.$ac_objext conftest.$ac_ext
4704 CPPFLAGS=$cf_save_CPPFLAGS
4709 if test "$cf_have_incdir" = no ; then
4710 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
4712 echo "${as_me:-configure}:4712: testing adding $cf_add_incdir to include-path ..." 1>&5
4714 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
4716 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
4717 test "$cf_top_incdir" = "$cf_add_incdir" && break
4718 cf_add_incdir="$cf_top_incdir"
4727 if test -n "$cf_cv_curses_dir/lib" ; then
4728 for cf_add_libdir in $cf_cv_curses_dir/lib
4730 if test $cf_add_libdir = /usr/lib ; then
4732 elif test -d $cf_add_libdir
4735 if test -n "$LDFLAGS$LIBS" ; then
4736 # a loop is needed to ensure we can add subdirs of existing dirs
4737 for cf_test_libdir in $LDFLAGS $LIBS ; do
4738 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
4739 cf_have_libdir=yes; break
4743 if test "$cf_have_libdir" = no ; then
4744 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
4746 echo "${as_me:-configure}:4746: testing adding $cf_add_libdir to library-path ..." 1>&5
4748 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
4757 echo "$as_me:4757: checking for specified curses library type" >&5
4758 echo $ECHO_N "checking for specified curses library type... $ECHO_C" >&6
4760 # Check whether --with-ncursesw or --without-ncursesw was given.
4761 if test "${with_ncursesw+set}" = set; then
4762 withval="$with_ncursesw"
4763 cf_cv_screen=ncursesw
4766 # Check whether --with-ncurses or --without-ncurses was given.
4767 if test "${with_ncurses+set}" = set; then
4768 withval="$with_ncurses"
4769 cf_cv_screen=ncurses
4772 # Check whether --with-pdcurses or --without-pdcurses was given.
4773 if test "${with_pdcurses+set}" = set; then
4774 withval="$with_pdcurses"
4775 cf_cv_screen=pdcurses
4778 # Check whether --with-curses-colr or --without-curses-colr was given.
4779 if test "${with_curses_colr+set}" = set; then
4780 withval="$with_curses_colr"
4781 cf_cv_screen=curses_colr
4784 # Check whether --with-curses-5lib or --without-curses-5lib was given.
4785 if test "${with_curses_5lib+set}" = set; then
4786 withval="$with_curses_5lib"
4787 cf_cv_screen=curses_5lib
4794 echo "$as_me:4794: result: $cf_cv_screen" >&5
4795 echo "${ECHO_T}$cf_cv_screen" >&6
4797 case $cf_cv_screen in
4800 echo "$as_me:4800: checking for extra include directories" >&5
4801 echo $ECHO_N "checking for extra include directories... $ECHO_C" >&6
4802 if test "${cf_cv_curses_incdir+set}" = set; then
4803 echo $ECHO_N "(cached) $ECHO_C" >&6
4806 cf_cv_curses_incdir=no
4807 case $host_os in #(vi
4809 if test "x$cf_cv_screen" = "xcurses_colr"
4811 test -d /usr/include/curses_colr && \
4812 cf_cv_curses_incdir="-I/usr/include/curses_colr"
4816 if test "x$cf_cv_screen" = "xcurses_5lib"
4818 test -d /usr/5lib && \
4819 test -d /usr/5include && \
4820 cf_cv_curses_incdir="-I/usr/5include"
4826 echo "$as_me:4826: result: $cf_cv_curses_incdir" >&5
4827 echo "${ECHO_T}$cf_cv_curses_incdir" >&6
4828 test "$cf_cv_curses_incdir" != no && CPPFLAGS="$CPPFLAGS $cf_cv_curses_incdir"
4830 echo "$as_me:4830: checking if we have identified curses headers" >&5
4831 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
4832 if test "${cf_cv_ncurses_header+set}" = set; then
4833 echo $ECHO_N "(cached) $ECHO_C" >&6
4836 cf_cv_ncurses_header=none
4839 ncurses.h ncurses/curses.h ncurses/ncurses.h
4841 cat >conftest.$ac_ext <<_ACEOF
4842 #line 4842 "configure"
4843 #include "confdefs.h"
4844 #include <${cf_header}>
4848 initscr(); tgoto("?", 0,0)
4853 rm -f conftest.$ac_objext
4854 if { (eval echo "$as_me:4854: \"$ac_compile\"") >&5
4855 (eval $ac_compile) 2>&5
4857 echo "$as_me:4857: \$? = $ac_status" >&5
4858 (exit $ac_status); } &&
4859 { ac_try='test -s conftest.$ac_objext'
4860 { (eval echo "$as_me:4860: \"$ac_try\"") >&5
4863 echo "$as_me:4863: \$? = $ac_status" >&5
4864 (exit $ac_status); }; }; then
4865 cf_cv_ncurses_header=$cf_header; break
4867 echo "$as_me: failed program was:" >&5
4868 cat conftest.$ac_ext >&5
4870 rm -f conftest.$ac_objext conftest.$ac_ext
4874 echo "$as_me:4874: result: $cf_cv_ncurses_header" >&5
4875 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
4877 if test "$cf_cv_ncurses_header" = none ; then
4878 { { echo "$as_me:4878: error: No curses header-files found" >&5
4879 echo "$as_me: error: No curses header-files found" >&2;}
4880 { (exit 1); exit 1; }; }
4883 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
4885 for ac_header in $cf_cv_ncurses_header
4887 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
4888 echo "$as_me:4888: checking for $ac_header" >&5
4889 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4890 if eval "test \"\${$as_ac_Header+set}\" = set"; then
4891 echo $ECHO_N "(cached) $ECHO_C" >&6
4893 cat >conftest.$ac_ext <<_ACEOF
4894 #line 4894 "configure"
4895 #include "confdefs.h"
4896 #include <$ac_header>
4898 if { (eval echo "$as_me:4898: \"$ac_cpp conftest.$ac_ext\"") >&5
4899 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4901 egrep -v '^ *\+' conftest.er1 >conftest.err
4903 cat conftest.err >&5
4904 echo "$as_me:4904: \$? = $ac_status" >&5
4905 (exit $ac_status); } >/dev/null; then
4906 if test -s conftest.err; then
4907 ac_cpp_err=$ac_c_preproc_warn_flag
4914 if test -z "$ac_cpp_err"; then
4915 eval "$as_ac_Header=yes"
4917 echo "$as_me: failed program was:" >&5
4918 cat conftest.$ac_ext >&5
4919 eval "$as_ac_Header=no"
4921 rm -f conftest.err conftest.$ac_ext
4923 echo "$as_me:4923: result: `eval echo '${'$as_ac_Header'}'`" >&5
4924 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4925 if test `eval echo '${'$as_ac_Header'}'` = yes; then
4926 cat >>confdefs.h <<EOF
4927 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
4933 echo "$as_me:4933: checking for terminfo header" >&5
4934 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
4935 if test "${cf_cv_term_header+set}" = set; then
4936 echo $ECHO_N "(cached) $ECHO_C" >&6
4939 case ${cf_cv_ncurses_header} in #(vi
4940 */ncurses.h|*/ncursesw.h) #(vi
4941 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
4944 cf_term_header=term.h
4948 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
4950 cat >conftest.$ac_ext <<_ACEOF
4951 #line 4951 "configure"
4952 #include "confdefs.h"
4954 #include <${cf_cv_ncurses_header:-curses.h}>
4960 int x = auto_left_margin
4965 rm -f conftest.$ac_objext
4966 if { (eval echo "$as_me:4966: \"$ac_compile\"") >&5
4967 (eval $ac_compile) 2>&5
4969 echo "$as_me:4969: \$? = $ac_status" >&5
4970 (exit $ac_status); } &&
4971 { ac_try='test -s conftest.$ac_objext'
4972 { (eval echo "$as_me:4972: \"$ac_try\"") >&5
4975 echo "$as_me:4975: \$? = $ac_status" >&5
4976 (exit $ac_status); }; }; then
4978 cf_cv_term_header="$cf_test"
4980 echo "$as_me: failed program was:" >&5
4981 cat conftest.$ac_ext >&5
4983 cf_cv_term_header=unknown
4986 rm -f conftest.$ac_objext conftest.$ac_ext
4987 test "$cf_cv_term_header" != unknown && break
4991 echo "$as_me:4991: result: $cf_cv_term_header" >&5
4992 echo "${ECHO_T}$cf_cv_term_header" >&6
4994 # Set definitions to allow ifdef'ing to accommodate subdirectories
4996 case $cf_cv_term_header in # (vi
4998 cat >>confdefs.h <<\EOF
4999 #define HAVE_TERM_H 1
5005 case $cf_cv_term_header in # (vi
5006 ncurses/term.h) #(vi
5007 cat >>confdefs.h <<\EOF
5008 #define HAVE_NCURSES_TERM_H 1
5013 cat >>confdefs.h <<\EOF
5014 #define HAVE_NCURSESW_TERM_H 1
5020 echo "$as_me:5020: checking for ncurses version" >&5
5021 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
5022 if test "${cf_cv_ncurses_version+set}" = set; then
5023 echo $ECHO_N "(cached) $ECHO_C" >&6
5026 cf_cv_ncurses_version=no
5029 if test "$cross_compiling" = yes; then
5031 # This will not work if the preprocessor splits the line after the
5032 # Autoconf token. The 'unproto' program does that.
5033 cat > conftest.$ac_ext <<EOF
5034 #include <${cf_cv_ncurses_header:-curses.h}>
5036 #ifdef NCURSES_VERSION
5037 Autoconf NCURSES_VERSION
5045 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
5046 { (eval echo "$as_me:5046: \"$cf_try\"") >&5
5049 echo "$as_me:5049: \$? = $ac_status" >&5
5050 (exit $ac_status); }
5051 if test -f conftest.out ; then
5052 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
5053 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
5058 cat >conftest.$ac_ext <<_ACEOF
5059 #line 5059 "configure"
5060 #include "confdefs.h"
5062 #include <${cf_cv_ncurses_header:-curses.h}>
5066 FILE *fp = fopen("$cf_tempfile", "w");
5067 #ifdef NCURSES_VERSION
5068 # ifdef NCURSES_VERSION_PATCH
5069 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
5071 fprintf(fp, "%s\n", NCURSES_VERSION);
5075 fprintf(fp, "old\n");
5080 ${cf_cv_main_return:-return}(0);
5083 rm -f conftest$ac_exeext
5084 if { (eval echo "$as_me:5084: \"$ac_link\"") >&5
5085 (eval $ac_link) 2>&5
5087 echo "$as_me:5087: \$? = $ac_status" >&5
5088 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5089 { (eval echo "$as_me:5089: \"$ac_try\"") >&5
5092 echo "$as_me:5092: \$? = $ac_status" >&5
5093 (exit $ac_status); }; }; then
5095 cf_cv_ncurses_version=`cat $cf_tempfile`
5097 echo "$as_me: program exited with status $ac_status" >&5
5098 echo "$as_me: failed program was:" >&5
5099 cat conftest.$ac_ext >&5
5101 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
5106 echo "$as_me:5106: result: $cf_cv_ncurses_version" >&5
5107 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
5108 test "$cf_cv_ncurses_version" = no || cat >>confdefs.h <<\EOF
5112 echo "$as_me:5112: checking if we have identified curses libraries" >&5
5113 echo $ECHO_N "checking if we have identified curses libraries... $ECHO_C" >&6
5114 cat >conftest.$ac_ext <<_ACEOF
5115 #line 5115 "configure"
5116 #include "confdefs.h"
5117 #include <${cf_cv_ncurses_header:-curses.h}>
5121 initscr(); tgoto("?", 0,0)
5126 rm -f conftest.$ac_objext conftest$ac_exeext
5127 if { (eval echo "$as_me:5127: \"$ac_link\"") >&5
5128 (eval $ac_link) 2>&5
5130 echo "$as_me:5130: \$? = $ac_status" >&5
5131 (exit $ac_status); } &&
5132 { ac_try='test -s conftest$ac_exeext'
5133 { (eval echo "$as_me:5133: \"$ac_try\"") >&5
5136 echo "$as_me:5136: \$? = $ac_status" >&5
5137 (exit $ac_status); }; }; then
5140 echo "$as_me: failed program was:" >&5
5141 cat conftest.$ac_ext >&5
5144 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5145 echo "$as_me:5145: result: $cf_result" >&5
5146 echo "${ECHO_T}$cf_result" >&6
5148 if test "$cf_result" = no ; then
5149 case $host_os in #(vi
5151 echo "$as_me:5151: checking for tgoto in -lmytinfo" >&5
5152 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
5153 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
5154 echo $ECHO_N "(cached) $ECHO_C" >&6
5156 ac_check_lib_save_LIBS=$LIBS
5157 LIBS="-lmytinfo $LIBS"
5158 cat >conftest.$ac_ext <<_ACEOF
5159 #line 5159 "configure"
5160 #include "confdefs.h"
5162 /* Override any gcc2 internal prototype to avoid an error. */
5166 /* We use char because int might match the return type of a gcc2
5167 builtin and then its argument prototype would still apply. */
5177 rm -f conftest.$ac_objext conftest$ac_exeext
5178 if { (eval echo "$as_me:5178: \"$ac_link\"") >&5
5179 (eval $ac_link) 2>&5
5181 echo "$as_me:5181: \$? = $ac_status" >&5
5182 (exit $ac_status); } &&
5183 { ac_try='test -s conftest$ac_exeext'
5184 { (eval echo "$as_me:5184: \"$ac_try\"") >&5
5187 echo "$as_me:5187: \$? = $ac_status" >&5
5188 (exit $ac_status); }; }; then
5189 ac_cv_lib_mytinfo_tgoto=yes
5191 echo "$as_me: failed program was:" >&5
5192 cat conftest.$ac_ext >&5
5193 ac_cv_lib_mytinfo_tgoto=no
5195 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5196 LIBS=$ac_check_lib_save_LIBS
5198 echo "$as_me:5198: result: $ac_cv_lib_mytinfo_tgoto" >&5
5199 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
5200 if test $ac_cv_lib_mytinfo_tgoto = yes; then
5201 LIBS="-lmytinfo $LIBS"
5206 # Looking at HPUX 10.20, the Hcurses library is the oldest (1997), cur_colr
5207 # next (1998), and xcurses "newer" (2000). There is no header file for
5208 # Hcurses; the subdirectory curses_colr has the headers (curses.h and
5209 # term.h) for cur_colr
5210 if test "x$cf_cv_screen" = "xcurses_colr"
5212 echo "$as_me:5212: checking for initscr in -lcur_colr" >&5
5213 echo $ECHO_N "checking for initscr in -lcur_colr... $ECHO_C" >&6
5214 if test "${ac_cv_lib_cur_colr_initscr+set}" = set; then
5215 echo $ECHO_N "(cached) $ECHO_C" >&6
5217 ac_check_lib_save_LIBS=$LIBS
5218 LIBS="-lcur_colr $LIBS"
5219 cat >conftest.$ac_ext <<_ACEOF
5220 #line 5220 "configure"
5221 #include "confdefs.h"
5223 /* Override any gcc2 internal prototype to avoid an error. */
5227 /* We use char because int might match the return type of a gcc2
5228 builtin and then its argument prototype would still apply. */
5238 rm -f conftest.$ac_objext conftest$ac_exeext
5239 if { (eval echo "$as_me:5239: \"$ac_link\"") >&5
5240 (eval $ac_link) 2>&5
5242 echo "$as_me:5242: \$? = $ac_status" >&5
5243 (exit $ac_status); } &&
5244 { ac_try='test -s conftest$ac_exeext'
5245 { (eval echo "$as_me:5245: \"$ac_try\"") >&5
5248 echo "$as_me:5248: \$? = $ac_status" >&5
5249 (exit $ac_status); }; }; then
5250 ac_cv_lib_cur_colr_initscr=yes
5252 echo "$as_me: failed program was:" >&5
5253 cat conftest.$ac_ext >&5
5254 ac_cv_lib_cur_colr_initscr=no
5256 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5257 LIBS=$ac_check_lib_save_LIBS
5259 echo "$as_me:5259: result: $ac_cv_lib_cur_colr_initscr" >&5
5260 echo "${ECHO_T}$ac_cv_lib_cur_colr_initscr" >&6
5261 if test $ac_cv_lib_cur_colr_initscr = yes; then
5263 LIBS="-lcur_colr $LIBS"
5264 ac_cv_func_initscr=yes
5268 echo "$as_me:5268: checking for initscr in -lHcurses" >&5
5269 echo $ECHO_N "checking for initscr in -lHcurses... $ECHO_C" >&6
5270 if test "${ac_cv_lib_Hcurses_initscr+set}" = set; then
5271 echo $ECHO_N "(cached) $ECHO_C" >&6
5273 ac_check_lib_save_LIBS=$LIBS
5274 LIBS="-lHcurses $LIBS"
5275 cat >conftest.$ac_ext <<_ACEOF
5276 #line 5276 "configure"
5277 #include "confdefs.h"
5279 /* Override any gcc2 internal prototype to avoid an error. */
5283 /* We use char because int might match the return type of a gcc2
5284 builtin and then its argument prototype would still apply. */
5294 rm -f conftest.$ac_objext conftest$ac_exeext
5295 if { (eval echo "$as_me:5295: \"$ac_link\"") >&5
5296 (eval $ac_link) 2>&5
5298 echo "$as_me:5298: \$? = $ac_status" >&5
5299 (exit $ac_status); } &&
5300 { ac_try='test -s conftest$ac_exeext'
5301 { (eval echo "$as_me:5301: \"$ac_try\"") >&5
5304 echo "$as_me:5304: \$? = $ac_status" >&5
5305 (exit $ac_status); }; }; then
5306 ac_cv_lib_Hcurses_initscr=yes
5308 echo "$as_me: failed program was:" >&5
5309 cat conftest.$ac_ext >&5
5310 ac_cv_lib_Hcurses_initscr=no
5312 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5313 LIBS=$ac_check_lib_save_LIBS
5315 echo "$as_me:5315: result: $ac_cv_lib_Hcurses_initscr" >&5
5316 echo "${ECHO_T}$ac_cv_lib_Hcurses_initscr" >&6
5317 if test $ac_cv_lib_Hcurses_initscr = yes; then
5319 # HP's header uses __HP_CURSES, but user claims _HP_CURSES.
5320 LIBS="-lHcurses $LIBS"
5321 CPPFLAGS="$CPPFLAGS -D__HP_CURSES -D_HP_CURSES"
5322 ac_cv_func_initscr=yes
5331 case `arch 2>/dev/null` in
5336 if test -n "/lib64" ; then
5337 for cf_add_libdir in /lib64
5339 if test $cf_add_libdir = /usr/lib ; then
5341 elif test -d $cf_add_libdir
5344 if test -n "$LDFLAGS$LIBS" ; then
5345 # a loop is needed to ensure we can add subdirs of existing dirs
5346 for cf_test_libdir in $LDFLAGS $LIBS ; do
5347 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
5348 cf_have_libdir=yes; break
5352 if test "$cf_have_libdir" = no ; then
5353 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
5355 echo "${as_me:-configure}:5355: testing adding $cf_add_libdir to library-path ..." 1>&5
5357 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
5365 if test -n "/lib" ; then
5366 for cf_add_libdir in /lib
5368 if test $cf_add_libdir = /usr/lib ; then
5370 elif test -d $cf_add_libdir
5373 if test -n "$LDFLAGS$LIBS" ; then
5374 # a loop is needed to ensure we can add subdirs of existing dirs
5375 for cf_test_libdir in $LDFLAGS $LIBS ; do
5376 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
5377 cf_have_libdir=yes; break
5381 if test "$cf_have_libdir" = no ; then
5382 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
5384 echo "${as_me:-configure}:5384: testing adding $cf_add_libdir to library-path ..." 1>&5
5386 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
5396 if test -n "/lib" ; then
5397 for cf_add_libdir in /lib
5399 if test $cf_add_libdir = /usr/lib ; then
5401 elif test -d $cf_add_libdir
5404 if test -n "$LDFLAGS$LIBS" ; then
5405 # a loop is needed to ensure we can add subdirs of existing dirs
5406 for cf_test_libdir in $LDFLAGS $LIBS ; do
5407 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
5408 cf_have_libdir=yes; break
5412 if test "$cf_have_libdir" = no ; then
5413 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
5415 echo "${as_me:-configure}:5415: testing adding $cf_add_libdir to library-path ..." 1>&5
5417 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
5427 if test "x$cf_cv_screen" = "xcurses_5lib"
5429 if test -d /usr/5lib ; then
5431 if test -n "/usr/5lib" ; then
5432 for cf_add_libdir in /usr/5lib
5434 if test $cf_add_libdir = /usr/lib ; then
5436 elif test -d $cf_add_libdir
5439 if test -n "$LDFLAGS$LIBS" ; then
5440 # a loop is needed to ensure we can add subdirs of existing dirs
5441 for cf_test_libdir in $LDFLAGS $LIBS ; do
5442 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
5443 cf_have_libdir=yes; break
5447 if test "$cf_have_libdir" = no ; then
5448 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
5450 echo "${as_me:-configure}:5450: testing adding $cf_add_libdir to library-path ..." 1>&5
5452 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
5458 LIBS="-lcurses -ltermcap $LIBS"
5461 ac_cv_func_initscr=yes
5465 if test ".$ac_cv_func_initscr" != .yes ; then
5466 cf_save_LIBS="$LIBS"
5470 if test ".${cf_cv_ncurses_version:-no}" != .no
5472 cf_check_list="ncurses curses cursesX"
5474 cf_check_list="cursesX curses ncurses"
5477 # Check for library containing tgoto. Do this before curses library
5478 # because it may be needed to link the test-case for initscr.
5479 echo "$as_me:5479: checking for tgoto" >&5
5480 echo $ECHO_N "checking for tgoto... $ECHO_C" >&6
5481 if test "${ac_cv_func_tgoto+set}" = set; then
5482 echo $ECHO_N "(cached) $ECHO_C" >&6
5484 cat >conftest.$ac_ext <<_ACEOF
5485 #line 5485 "configure"
5486 #include "confdefs.h"
5487 /* System header to define __stub macros and hopefully few prototypes,
5488 which can conflict with char tgoto (); below. */
5490 /* Override any gcc2 internal prototype to avoid an error. */
5494 /* We use char because int might match the return type of a gcc2
5495 builtin and then its argument prototype would still apply. */
5502 /* The GNU C library defines this for functions which it implements
5503 to always fail with ENOSYS. Some functions are actually named
5504 something starting with __ and the normal name is an alias. */
5505 #if defined (__stub_tgoto) || defined (__stub___tgoto)
5515 rm -f conftest.$ac_objext conftest$ac_exeext
5516 if { (eval echo "$as_me:5516: \"$ac_link\"") >&5
5517 (eval $ac_link) 2>&5
5519 echo "$as_me:5519: \$? = $ac_status" >&5
5520 (exit $ac_status); } &&
5521 { ac_try='test -s conftest$ac_exeext'
5522 { (eval echo "$as_me:5522: \"$ac_try\"") >&5
5525 echo "$as_me:5525: \$? = $ac_status" >&5
5526 (exit $ac_status); }; }; then
5527 ac_cv_func_tgoto=yes
5529 echo "$as_me: failed program was:" >&5
5530 cat conftest.$ac_ext >&5
5533 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5535 echo "$as_me:5535: result: $ac_cv_func_tgoto" >&5
5536 echo "${ECHO_T}$ac_cv_func_tgoto" >&6
5537 if test $ac_cv_func_tgoto = yes; then
5538 cf_term_lib=predefined
5541 for cf_term_lib in $cf_check_list termcap termlib unknown
5543 as_ac_Lib=`echo "ac_cv_lib_$cf_term_lib''_tgoto" | $as_tr_sh`
5544 echo "$as_me:5544: checking for tgoto in -l$cf_term_lib" >&5
5545 echo $ECHO_N "checking for tgoto in -l$cf_term_lib... $ECHO_C" >&6
5546 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
5547 echo $ECHO_N "(cached) $ECHO_C" >&6
5549 ac_check_lib_save_LIBS=$LIBS
5550 LIBS="-l$cf_term_lib $LIBS"
5551 cat >conftest.$ac_ext <<_ACEOF
5552 #line 5552 "configure"
5553 #include "confdefs.h"
5555 /* Override any gcc2 internal prototype to avoid an error. */
5559 /* We use char because int might match the return type of a gcc2
5560 builtin and then its argument prototype would still apply. */
5570 rm -f conftest.$ac_objext conftest$ac_exeext
5571 if { (eval echo "$as_me:5571: \"$ac_link\"") >&5
5572 (eval $ac_link) 2>&5
5574 echo "$as_me:5574: \$? = $ac_status" >&5
5575 (exit $ac_status); } &&
5576 { ac_try='test -s conftest$ac_exeext'
5577 { (eval echo "$as_me:5577: \"$ac_try\"") >&5
5580 echo "$as_me:5580: \$? = $ac_status" >&5
5581 (exit $ac_status); }; }; then
5582 eval "$as_ac_Lib=yes"
5584 echo "$as_me: failed program was:" >&5
5585 cat conftest.$ac_ext >&5
5586 eval "$as_ac_Lib=no"
5588 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5589 LIBS=$ac_check_lib_save_LIBS
5591 echo "$as_me:5591: result: `eval echo '${'$as_ac_Lib'}'`" >&5
5592 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
5593 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
5601 # Check for library containing initscr
5602 test "$cf_term_lib" != predefined && test "$cf_term_lib" != unknown && LIBS="-l$cf_term_lib $cf_save_LIBS"
5603 for cf_curs_lib in $cf_check_list xcurses jcurses pdcurses unknown
5605 as_ac_Lib=`echo "ac_cv_lib_$cf_curs_lib''_initscr" | $as_tr_sh`
5606 echo "$as_me:5606: checking for initscr in -l$cf_curs_lib" >&5
5607 echo $ECHO_N "checking for initscr in -l$cf_curs_lib... $ECHO_C" >&6
5608 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
5609 echo $ECHO_N "(cached) $ECHO_C" >&6
5611 ac_check_lib_save_LIBS=$LIBS
5612 LIBS="-l$cf_curs_lib $LIBS"
5613 cat >conftest.$ac_ext <<_ACEOF
5614 #line 5614 "configure"
5615 #include "confdefs.h"
5617 /* Override any gcc2 internal prototype to avoid an error. */
5621 /* We use char because int might match the return type of a gcc2
5622 builtin and then its argument prototype would still apply. */
5632 rm -f conftest.$ac_objext conftest$ac_exeext
5633 if { (eval echo "$as_me:5633: \"$ac_link\"") >&5
5634 (eval $ac_link) 2>&5
5636 echo "$as_me:5636: \$? = $ac_status" >&5
5637 (exit $ac_status); } &&
5638 { ac_try='test -s conftest$ac_exeext'
5639 { (eval echo "$as_me:5639: \"$ac_try\"") >&5
5642 echo "$as_me:5642: \$? = $ac_status" >&5
5643 (exit $ac_status); }; }; then
5644 eval "$as_ac_Lib=yes"
5646 echo "$as_me: failed program was:" >&5
5647 cat conftest.$ac_ext >&5
5648 eval "$as_ac_Lib=no"
5650 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5651 LIBS=$ac_check_lib_save_LIBS
5653 echo "$as_me:5653: result: `eval echo '${'$as_ac_Lib'}'`" >&5
5654 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
5655 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
5660 test $cf_curs_lib = unknown && { { echo "$as_me:5660: error: no curses library found" >&5
5661 echo "$as_me: error: no curses library found" >&2;}
5662 { (exit 1); exit 1; }; }
5664 LIBS="-l$cf_curs_lib $cf_save_LIBS"
5665 if test "$cf_term_lib" = unknown ; then
5666 echo "$as_me:5666: checking if we can link with $cf_curs_lib library" >&5
5667 echo $ECHO_N "checking if we can link with $cf_curs_lib library... $ECHO_C" >&6
5668 cat >conftest.$ac_ext <<_ACEOF
5669 #line 5669 "configure"
5670 #include "confdefs.h"
5671 #include <${cf_cv_ncurses_header:-curses.h}>
5680 rm -f conftest.$ac_objext conftest$ac_exeext
5681 if { (eval echo "$as_me:5681: \"$ac_link\"") >&5
5682 (eval $ac_link) 2>&5
5684 echo "$as_me:5684: \$? = $ac_status" >&5
5685 (exit $ac_status); } &&
5686 { ac_try='test -s conftest$ac_exeext'
5687 { (eval echo "$as_me:5687: \"$ac_try\"") >&5
5690 echo "$as_me:5690: \$? = $ac_status" >&5
5691 (exit $ac_status); }; }; then
5694 echo "$as_me: failed program was:" >&5
5695 cat conftest.$ac_ext >&5
5698 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5699 echo "$as_me:5699: result: $cf_result" >&5
5700 echo "${ECHO_T}$cf_result" >&6
5701 test $cf_result = no && { { echo "$as_me:5701: error: Cannot link curses library" >&5
5702 echo "$as_me: error: Cannot link curses library" >&2;}
5703 { (exit 1); exit 1; }; }
5704 elif test "$cf_curs_lib" = "$cf_term_lib" ; then
5706 elif test "$cf_term_lib" != predefined ; then
5707 echo "$as_me:5707: checking if we need both $cf_curs_lib and $cf_term_lib libraries" >&5
5708 echo $ECHO_N "checking if we need both $cf_curs_lib and $cf_term_lib libraries... $ECHO_C" >&6
5709 cat >conftest.$ac_ext <<_ACEOF
5710 #line 5710 "configure"
5711 #include "confdefs.h"
5712 #include <${cf_cv_ncurses_header:-curses.h}>
5716 initscr(); tgoto((char *)0, 0, 0);
5721 rm -f conftest.$ac_objext conftest$ac_exeext
5722 if { (eval echo "$as_me:5722: \"$ac_link\"") >&5
5723 (eval $ac_link) 2>&5
5725 echo "$as_me:5725: \$? = $ac_status" >&5
5726 (exit $ac_status); } &&
5727 { ac_try='test -s conftest$ac_exeext'
5728 { (eval echo "$as_me:5728: \"$ac_try\"") >&5
5731 echo "$as_me:5731: \$? = $ac_status" >&5
5732 (exit $ac_status); }; }; then
5735 echo "$as_me: failed program was:" >&5
5736 cat conftest.$ac_ext >&5
5738 LIBS="-l$cf_curs_lib -l$cf_term_lib $cf_save_LIBS"
5739 cat >conftest.$ac_ext <<_ACEOF
5740 #line 5740 "configure"
5741 #include "confdefs.h"
5742 #include <${cf_cv_ncurses_header:-curses.h}>
5751 rm -f conftest.$ac_objext conftest$ac_exeext
5752 if { (eval echo "$as_me:5752: \"$ac_link\"") >&5
5753 (eval $ac_link) 2>&5
5755 echo "$as_me:5755: \$? = $ac_status" >&5
5756 (exit $ac_status); } &&
5757 { ac_try='test -s conftest$ac_exeext'
5758 { (eval echo "$as_me:5758: \"$ac_try\"") >&5
5761 echo "$as_me:5761: \$? = $ac_status" >&5
5762 (exit $ac_status); }; }; then
5765 echo "$as_me: failed program was:" >&5
5766 cat conftest.$ac_ext >&5
5769 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5772 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5773 echo "$as_me:5773: result: $cf_result" >&5
5774 echo "${ECHO_T}$cf_result" >&6
5779 echo "$as_me:5779: checking for NetBSD form.h" >&5
5780 echo $ECHO_N "checking for NetBSD form.h... $ECHO_C" >&6
5781 if test "${cf_cv_netbsd_form_h+set}" = set; then
5782 echo $ECHO_N "(cached) $ECHO_C" >&6
5785 cat >conftest.$ac_ext <<_ACEOF
5786 #line 5786 "configure"
5787 #include "confdefs.h"
5789 #include <${cf_cv_ncurses_header:-curses.h}>
5797 int y = current_field(form)->cursor_ypos;
5798 int x = current_field(form)->cursor_xpos;
5804 rm -f conftest.$ac_objext
5805 if { (eval echo "$as_me:5805: \"$ac_compile\"") >&5
5806 (eval $ac_compile) 2>&5
5808 echo "$as_me:5808: \$? = $ac_status" >&5
5809 (exit $ac_status); } &&
5810 { ac_try='test -s conftest.$ac_objext'
5811 { (eval echo "$as_me:5811: \"$ac_try\"") >&5
5814 echo "$as_me:5814: \$? = $ac_status" >&5
5815 (exit $ac_status); }; }; then
5816 cf_cv_netbsd_form_h=yes
5819 echo "$as_me: failed program was:" >&5
5820 cat conftest.$ac_ext >&5
5821 cf_cv_netbsd_form_h=no
5823 rm -f conftest.$ac_objext conftest.$ac_ext
5826 echo "$as_me:5826: result: $cf_cv_netbsd_form_h" >&5
5827 echo "${ECHO_T}$cf_cv_netbsd_form_h" >&6
5829 test "$cf_cv_netbsd_form_h" = yes && cat >>confdefs.h <<\EOF
5830 #define HAVE_NETBSD_FORM_H 1
5833 echo "$as_me:5833: checking for NetBSD menu.h" >&5
5834 echo $ECHO_N "checking for NetBSD menu.h... $ECHO_C" >&6
5835 if test "${cf_cv_netbsd_menu_h+set}" = set; then
5836 echo $ECHO_N "(cached) $ECHO_C" >&6
5839 cat >conftest.$ac_ext <<_ACEOF
5840 #line 5840 "configure"
5841 #include "confdefs.h"
5843 #include <${cf_cv_ncurses_header:-curses.h}>
5851 int y = menu->max_item_width;
5857 rm -f conftest.$ac_objext
5858 if { (eval echo "$as_me:5858: \"$ac_compile\"") >&5
5859 (eval $ac_compile) 2>&5
5861 echo "$as_me:5861: \$? = $ac_status" >&5
5862 (exit $ac_status); } &&
5863 { ac_try='test -s conftest.$ac_objext'
5864 { (eval echo "$as_me:5864: \"$ac_try\"") >&5
5867 echo "$as_me:5867: \$? = $ac_status" >&5
5868 (exit $ac_status); }; }; then
5869 cf_cv_netbsd_menu_h=yes
5872 echo "$as_me: failed program was:" >&5
5873 cat conftest.$ac_ext >&5
5874 cf_cv_netbsd_menu_h=no
5876 rm -f conftest.$ac_objext conftest.$ac_ext
5879 echo "$as_me:5879: result: $cf_cv_netbsd_menu_h" >&5
5880 echo "${ECHO_T}$cf_cv_netbsd_menu_h" >&6
5882 test "$cf_cv_netbsd_menu_h" = yes && cat >>confdefs.h <<\EOF
5883 #define HAVE_NETBSD_MENU_H 1
5889 cf_ncuconfig_root=ncurses
5891 echo "Looking for ${cf_ncuconfig_root}-config"
5892 for ac_prog in ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
5894 # Extract the first word of "$ac_prog", so it can be a program name with args.
5895 set dummy $ac_prog; ac_word=$2
5896 echo "$as_me:5896: checking for $ac_word" >&5
5897 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5898 if test "${ac_cv_path_NCURSES_CONFIG+set}" = set; then
5899 echo $ECHO_N "(cached) $ECHO_C" >&6
5901 case $NCURSES_CONFIG in
5903 ac_cv_path_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test with a path.
5906 ac_save_IFS=$IFS; IFS=$ac_path_separator
5908 for ac_dir in $ac_dummy; do
5910 test -z "$ac_dir" && ac_dir=.
5911 if $as_executable_p "$ac_dir/$ac_word"; then
5912 ac_cv_path_NCURSES_CONFIG="$ac_dir/$ac_word"
5913 echo "$as_me:5913: found $ac_dir/$ac_word" >&5
5921 NCURSES_CONFIG=$ac_cv_path_NCURSES_CONFIG
5923 if test -n "$NCURSES_CONFIG"; then
5924 echo "$as_me:5924: result: $NCURSES_CONFIG" >&5
5925 echo "${ECHO_T}$NCURSES_CONFIG" >&6
5927 echo "$as_me:5927: result: no" >&5
5928 echo "${ECHO_T}no" >&6
5931 test -n "$NCURSES_CONFIG" && break
5933 test -n "$NCURSES_CONFIG" || NCURSES_CONFIG="none"
5935 if test "$NCURSES_CONFIG" != none ; then
5937 CPPFLAGS="$CPPFLAGS `$NCURSES_CONFIG --cflags`"
5938 LIBS="`$NCURSES_CONFIG --libs` $LIBS"
5940 # even with config script, some packages use no-override for curses.h
5942 echo "$as_me:5942: checking if we have identified curses headers" >&5
5943 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
5944 if test "${cf_cv_ncurses_header+set}" = set; then
5945 echo $ECHO_N "(cached) $ECHO_C" >&6
5948 cf_cv_ncurses_header=none
5955 cat >conftest.$ac_ext <<_ACEOF
5956 #line 5956 "configure"
5957 #include "confdefs.h"
5958 #include <${cf_header}>
5962 initscr(); tgoto("?", 0,0)
5967 rm -f conftest.$ac_objext
5968 if { (eval echo "$as_me:5968: \"$ac_compile\"") >&5
5969 (eval $ac_compile) 2>&5
5971 echo "$as_me:5971: \$? = $ac_status" >&5
5972 (exit $ac_status); } &&
5973 { ac_try='test -s conftest.$ac_objext'
5974 { (eval echo "$as_me:5974: \"$ac_try\"") >&5
5977 echo "$as_me:5977: \$? = $ac_status" >&5
5978 (exit $ac_status); }; }; then
5979 cf_cv_ncurses_header=$cf_header; break
5981 echo "$as_me: failed program was:" >&5
5982 cat conftest.$ac_ext >&5
5984 rm -f conftest.$ac_objext conftest.$ac_ext
5988 echo "$as_me:5988: result: $cf_cv_ncurses_header" >&5
5989 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
5991 if test "$cf_cv_ncurses_header" = none ; then
5992 { { echo "$as_me:5992: error: No curses header-files found" >&5
5993 echo "$as_me: error: No curses header-files found" >&2;}
5994 { (exit 1); exit 1; }; }
5997 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
5999 for ac_header in $cf_cv_ncurses_header
6001 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6002 echo "$as_me:6002: checking for $ac_header" >&5
6003 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6004 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6005 echo $ECHO_N "(cached) $ECHO_C" >&6
6007 cat >conftest.$ac_ext <<_ACEOF
6008 #line 6008 "configure"
6009 #include "confdefs.h"
6010 #include <$ac_header>
6012 if { (eval echo "$as_me:6012: \"$ac_cpp conftest.$ac_ext\"") >&5
6013 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6015 egrep -v '^ *\+' conftest.er1 >conftest.err
6017 cat conftest.err >&5
6018 echo "$as_me:6018: \$? = $ac_status" >&5
6019 (exit $ac_status); } >/dev/null; then
6020 if test -s conftest.err; then
6021 ac_cpp_err=$ac_c_preproc_warn_flag
6028 if test -z "$ac_cpp_err"; then
6029 eval "$as_ac_Header=yes"
6031 echo "$as_me: failed program was:" >&5
6032 cat conftest.$ac_ext >&5
6033 eval "$as_ac_Header=no"
6035 rm -f conftest.err conftest.$ac_ext
6037 echo "$as_me:6037: result: `eval echo '${'$as_ac_Header'}'`" >&5
6038 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6039 if test `eval echo '${'$as_ac_Header'}'` = yes; then
6040 cat >>confdefs.h <<EOF
6041 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6047 cat >>confdefs.h <<\EOF
6051 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
6053 cat >>confdefs.h <<EOF
6054 #define $cf_nculib_ROOT 1
6057 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
6061 cf_ncuhdr_root=ncurses
6063 test -n "$cf_cv_curses_dir" && \
6064 test "$cf_cv_curses_dir" != "no" && { \
6066 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
6067 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
6069 while test $cf_add_incdir != /usr/include
6071 if test -d $cf_add_incdir
6074 if test -n "$CFLAGS$CPPFLAGS" ; then
6075 # a loop is needed to ensure we can add subdirs of existing dirs
6076 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
6077 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
6078 cf_have_incdir=yes; break
6083 if test "$cf_have_incdir" = no ; then
6084 if test "$cf_add_incdir" = /usr/local/include ; then
6085 if test "$GCC" = yes
6087 cf_save_CPPFLAGS=$CPPFLAGS
6088 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6089 cat >conftest.$ac_ext <<_ACEOF
6090 #line 6090 "configure"
6091 #include "confdefs.h"
6101 rm -f conftest.$ac_objext
6102 if { (eval echo "$as_me:6102: \"$ac_compile\"") >&5
6103 (eval $ac_compile) 2>&5
6105 echo "$as_me:6105: \$? = $ac_status" >&5
6106 (exit $ac_status); } &&
6107 { ac_try='test -s conftest.$ac_objext'
6108 { (eval echo "$as_me:6108: \"$ac_try\"") >&5
6111 echo "$as_me:6111: \$? = $ac_status" >&5
6112 (exit $ac_status); }; }; then
6115 echo "$as_me: failed program was:" >&5
6116 cat conftest.$ac_ext >&5
6119 rm -f conftest.$ac_objext conftest.$ac_ext
6120 CPPFLAGS=$cf_save_CPPFLAGS
6125 if test "$cf_have_incdir" = no ; then
6126 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
6128 echo "${as_me:-configure}:6128: testing adding $cf_add_incdir to include-path ..." 1>&5
6130 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6132 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
6133 test "$cf_top_incdir" = "$cf_add_incdir" && break
6134 cf_add_incdir="$cf_top_incdir"
6145 echo "$as_me:6145: checking for $cf_ncuhdr_root header in include-path" >&5
6146 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
6147 if test "${cf_cv_ncurses_h+set}" = set; then
6148 echo $ECHO_N "(cached) $ECHO_C" >&6
6151 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
6152 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
6153 for cf_header in $cf_header_list
6156 cat >conftest.$ac_ext <<_ACEOF
6157 #line 6157 "configure"
6158 #include "confdefs.h"
6160 #include <$cf_header>
6165 #ifdef NCURSES_VERSION
6167 printf("%s\n", NCURSES_VERSION);
6180 rm -f conftest.$ac_objext
6181 if { (eval echo "$as_me:6181: \"$ac_compile\"") >&5
6182 (eval $ac_compile) 2>&5
6184 echo "$as_me:6184: \$? = $ac_status" >&5
6185 (exit $ac_status); } &&
6186 { ac_try='test -s conftest.$ac_objext'
6187 { (eval echo "$as_me:6187: \"$ac_try\"") >&5
6190 echo "$as_me:6190: \$? = $ac_status" >&5
6191 (exit $ac_status); }; }; then
6192 cf_cv_ncurses_h=$cf_header
6195 echo "$as_me: failed program was:" >&5
6196 cat conftest.$ac_ext >&5
6199 rm -f conftest.$ac_objext conftest.$ac_ext
6201 test "$cf_cv_ncurses_h" != no && break
6205 echo "$as_me:6205: result: $cf_cv_ncurses_h" >&5
6206 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
6208 if test "$cf_cv_ncurses_h" != no ; then
6209 cf_cv_ncurses_header=$cf_cv_ncurses_h
6212 echo "$as_me:6212: checking for $cf_ncuhdr_root include-path" >&5
6213 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
6214 if test "${cf_cv_ncurses_h2+set}" = set; then
6215 echo $ECHO_N "(cached) $ECHO_C" >&6
6218 test -n "$verbose" && echo
6222 # collect the current set of include-directories from compiler flags
6223 cf_header_path_list=""
6224 if test -n "${CFLAGS}${CPPFLAGS}" ; then
6225 for cf_header_path in $CPPFLAGS $CFLAGS
6227 case $cf_header_path in #(vi
6229 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
6231 test "$cf_header_path" != "NONE" && \
6232 test -d "$cf_header_path" && \
6234 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
6235 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
6236 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
6237 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
6238 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
6239 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"
6242 cf_header_path_list="$cf_header_path_list $cf_search"
6248 # add the variations for the package we are looking for
6252 test "/usr" != "$prefix" && \
6254 (test $prefix = NONE || test "/usr" != "$prefix") && {
6255 test -n "$verbose" && echo " ... testing for include-directories under /usr"
6256 test -d /usr/include && cf_search="$cf_search /usr/include"
6257 test -d /usr/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/include/$cf_ncuhdr_root"
6258 test -d /usr/include/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/include/$cf_ncuhdr_root/include"
6259 test -d /usr/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/$cf_ncuhdr_root/include"
6260 test -d /usr/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
6263 test "$prefix" != "NONE" && \
6264 test -d "$prefix" && \
6266 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
6267 test -d $prefix/include && cf_search="$cf_search $prefix/include"
6268 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
6269 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
6270 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
6271 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
6274 test "/usr/local" != "$prefix" && \
6275 test -d "/usr/local" && \
6276 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
6277 test -n "$verbose" && echo " ... testing for include-directories under /usr/local"
6278 test -d /usr/local/include && cf_search="$cf_search /usr/local/include"
6279 test -d /usr/local/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/local/include/$cf_ncuhdr_root"
6280 test -d /usr/local/include/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/local/include/$cf_ncuhdr_root/include"
6281 test -d /usr/local/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/local/$cf_ncuhdr_root/include"
6282 test -d /usr/local/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/local/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
6285 test "/opt" != "$prefix" && \
6287 (test $prefix = NONE || test "/opt" != "$prefix") && {
6288 test -n "$verbose" && echo " ... testing for include-directories under /opt"
6289 test -d /opt/include && cf_search="$cf_search /opt/include"
6290 test -d /opt/include/$cf_ncuhdr_root && cf_search="$cf_search /opt/include/$cf_ncuhdr_root"
6291 test -d /opt/include/$cf_ncuhdr_root/include && cf_search="$cf_search /opt/include/$cf_ncuhdr_root/include"
6292 test -d /opt/$cf_ncuhdr_root/include && cf_search="$cf_search /opt/$cf_ncuhdr_root/include"
6293 test -d /opt/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /opt/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
6296 test "$HOME" != "$prefix" && \
6297 test -d "$HOME" && \
6298 (test $prefix = NONE || test "$HOME" != "$prefix") && {
6299 test -n "$verbose" && echo " ... testing for include-directories under $HOME"
6300 test -d $HOME/include && cf_search="$cf_search $HOME/include"
6301 test -d $HOME/include/$cf_ncuhdr_root && cf_search="$cf_search $HOME/include/$cf_ncuhdr_root"
6302 test -d $HOME/include/$cf_ncuhdr_root/include && cf_search="$cf_search $HOME/include/$cf_ncuhdr_root/include"
6303 test -d $HOME/$cf_ncuhdr_root/include && cf_search="$cf_search $HOME/$cf_ncuhdr_root/include"
6304 test -d $HOME/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $HOME/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
6307 test "$includedir" != NONE && \
6308 test "$includedir" != "/usr/include" && \
6309 test -d "$includedir" && {
6310 test -d $includedir && cf_search="$cf_search $includedir"
6311 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
6314 test "$oldincludedir" != NONE && \
6315 test "$oldincludedir" != "/usr/include" && \
6316 test -d "$oldincludedir" && {
6317 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
6318 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
6321 cf_search="$cf_search $cf_header_path_list"
6323 test -n "$verbose" && echo search path $cf_search
6324 cf_save2_CPPFLAGS="$CPPFLAGS"
6325 for cf_incdir in $cf_search
6328 if test -n "$cf_incdir" ; then
6329 for cf_add_incdir in $cf_incdir
6331 while test $cf_add_incdir != /usr/include
6333 if test -d $cf_add_incdir
6336 if test -n "$CFLAGS$CPPFLAGS" ; then
6337 # a loop is needed to ensure we can add subdirs of existing dirs
6338 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
6339 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
6340 cf_have_incdir=yes; break
6345 if test "$cf_have_incdir" = no ; then
6346 if test "$cf_add_incdir" = /usr/local/include ; then
6347 if test "$GCC" = yes
6349 cf_save_CPPFLAGS=$CPPFLAGS
6350 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6351 cat >conftest.$ac_ext <<_ACEOF
6352 #line 6352 "configure"
6353 #include "confdefs.h"
6363 rm -f conftest.$ac_objext
6364 if { (eval echo "$as_me:6364: \"$ac_compile\"") >&5
6365 (eval $ac_compile) 2>&5
6367 echo "$as_me:6367: \$? = $ac_status" >&5
6368 (exit $ac_status); } &&
6369 { ac_try='test -s conftest.$ac_objext'
6370 { (eval echo "$as_me:6370: \"$ac_try\"") >&5
6373 echo "$as_me:6373: \$? = $ac_status" >&5
6374 (exit $ac_status); }; }; then
6377 echo "$as_me: failed program was:" >&5
6378 cat conftest.$ac_ext >&5
6381 rm -f conftest.$ac_objext conftest.$ac_ext
6382 CPPFLAGS=$cf_save_CPPFLAGS
6387 if test "$cf_have_incdir" = no ; then
6388 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
6390 echo "${as_me:-configure}:6390: testing adding $cf_add_incdir to include-path ..." 1>&5
6392 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6394 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
6395 test "$cf_top_incdir" = "$cf_add_incdir" && break
6396 cf_add_incdir="$cf_top_incdir"
6410 cat >conftest.$ac_ext <<_ACEOF
6411 #line 6411 "configure"
6412 #include "confdefs.h"
6414 #include <$cf_header>
6419 #ifdef NCURSES_VERSION
6421 printf("%s\n", NCURSES_VERSION);
6434 rm -f conftest.$ac_objext
6435 if { (eval echo "$as_me:6435: \"$ac_compile\"") >&5
6436 (eval $ac_compile) 2>&5
6438 echo "$as_me:6438: \$? = $ac_status" >&5
6439 (exit $ac_status); } &&
6440 { ac_try='test -s conftest.$ac_objext'
6441 { (eval echo "$as_me:6441: \"$ac_try\"") >&5
6444 echo "$as_me:6444: \$? = $ac_status" >&5
6445 (exit $ac_status); }; }; then
6446 cf_cv_ncurses_h2=$cf_header
6449 echo "$as_me: failed program was:" >&5
6450 cat conftest.$ac_ext >&5
6453 rm -f conftest.$ac_objext conftest.$ac_ext
6455 if test "$cf_cv_ncurses_h2" != no ; then
6456 cf_cv_ncurses_h2=$cf_incdir/$cf_header
6457 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
6460 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
6462 CPPFLAGS="$cf_save2_CPPFLAGS"
6463 test "$cf_cv_ncurses_h2" != no && break
6465 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:6465: error: not found" >&5
6466 echo "$as_me: error: not found" >&2;}
6467 { (exit 1); exit 1; }; }
6470 echo "$as_me:6470: result: $cf_cv_ncurses_h2" >&5
6471 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
6473 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
6474 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
6475 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
6476 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
6479 if test -n "$cf_1st_incdir" ; then
6480 for cf_add_incdir in $cf_1st_incdir
6482 while test $cf_add_incdir != /usr/include
6484 if test -d $cf_add_incdir
6487 if test -n "$CFLAGS$CPPFLAGS" ; then
6488 # a loop is needed to ensure we can add subdirs of existing dirs
6489 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
6490 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
6491 cf_have_incdir=yes; break
6496 if test "$cf_have_incdir" = no ; then
6497 if test "$cf_add_incdir" = /usr/local/include ; then
6498 if test "$GCC" = yes
6500 cf_save_CPPFLAGS=$CPPFLAGS
6501 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6502 cat >conftest.$ac_ext <<_ACEOF
6503 #line 6503 "configure"
6504 #include "confdefs.h"
6514 rm -f conftest.$ac_objext
6515 if { (eval echo "$as_me:6515: \"$ac_compile\"") >&5
6516 (eval $ac_compile) 2>&5
6518 echo "$as_me:6518: \$? = $ac_status" >&5
6519 (exit $ac_status); } &&
6520 { ac_try='test -s conftest.$ac_objext'
6521 { (eval echo "$as_me:6521: \"$ac_try\"") >&5
6524 echo "$as_me:6524: \$? = $ac_status" >&5
6525 (exit $ac_status); }; }; then
6528 echo "$as_me: failed program was:" >&5
6529 cat conftest.$ac_ext >&5
6532 rm -f conftest.$ac_objext conftest.$ac_ext
6533 CPPFLAGS=$cf_save_CPPFLAGS
6538 if test "$cf_have_incdir" = no ; then
6539 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
6541 echo "${as_me:-configure}:6541: testing adding $cf_add_incdir to include-path ..." 1>&5
6543 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6545 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
6546 test "$cf_top_incdir" = "$cf_add_incdir" && break
6547 cf_add_incdir="$cf_top_incdir"
6558 # Set definitions to allow ifdef'ing for ncurses.h
6560 case $cf_cv_ncurses_header in # (vi
6562 cat >>confdefs.h <<\EOF
6563 #define HAVE_NCURSES_H 1
6569 case $cf_cv_ncurses_header in # (vi
6570 ncurses/curses.h|ncurses/ncurses.h)
6571 cat >>confdefs.h <<\EOF
6572 #define HAVE_NCURSES_NCURSES_H 1
6576 ncursesw/curses.h|ncursesw/ncurses.h)
6577 cat >>confdefs.h <<\EOF
6578 #define HAVE_NCURSESW_NCURSES_H 1
6584 echo "$as_me:6584: checking for terminfo header" >&5
6585 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
6586 if test "${cf_cv_term_header+set}" = set; then
6587 echo $ECHO_N "(cached) $ECHO_C" >&6
6590 case ${cf_cv_ncurses_header} in #(vi
6591 */ncurses.h|*/ncursesw.h) #(vi
6592 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
6595 cf_term_header=term.h
6599 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
6601 cat >conftest.$ac_ext <<_ACEOF
6602 #line 6602 "configure"
6603 #include "confdefs.h"
6605 #include <${cf_cv_ncurses_header:-curses.h}>
6611 int x = auto_left_margin
6616 rm -f conftest.$ac_objext
6617 if { (eval echo "$as_me:6617: \"$ac_compile\"") >&5
6618 (eval $ac_compile) 2>&5
6620 echo "$as_me:6620: \$? = $ac_status" >&5
6621 (exit $ac_status); } &&
6622 { ac_try='test -s conftest.$ac_objext'
6623 { (eval echo "$as_me:6623: \"$ac_try\"") >&5
6626 echo "$as_me:6626: \$? = $ac_status" >&5
6627 (exit $ac_status); }; }; then
6629 cf_cv_term_header="$cf_test"
6631 echo "$as_me: failed program was:" >&5
6632 cat conftest.$ac_ext >&5
6634 cf_cv_term_header=unknown
6637 rm -f conftest.$ac_objext conftest.$ac_ext
6638 test "$cf_cv_term_header" != unknown && break
6642 echo "$as_me:6642: result: $cf_cv_term_header" >&5
6643 echo "${ECHO_T}$cf_cv_term_header" >&6
6645 # Set definitions to allow ifdef'ing to accommodate subdirectories
6647 case $cf_cv_term_header in # (vi
6649 cat >>confdefs.h <<\EOF
6650 #define HAVE_TERM_H 1
6656 case $cf_cv_term_header in # (vi
6657 ncurses/term.h) #(vi
6658 cat >>confdefs.h <<\EOF
6659 #define HAVE_NCURSES_TERM_H 1
6664 cat >>confdefs.h <<\EOF
6665 #define HAVE_NCURSESW_TERM_H 1
6671 # some applications need this, but should check for NCURSES_VERSION
6672 cat >>confdefs.h <<\EOF
6676 echo "$as_me:6676: checking for ncurses version" >&5
6677 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
6678 if test "${cf_cv_ncurses_version+set}" = set; then
6679 echo $ECHO_N "(cached) $ECHO_C" >&6
6682 cf_cv_ncurses_version=no
6685 if test "$cross_compiling" = yes; then
6687 # This will not work if the preprocessor splits the line after the
6688 # Autoconf token. The 'unproto' program does that.
6689 cat > conftest.$ac_ext <<EOF
6690 #include <${cf_cv_ncurses_header:-curses.h}>
6692 #ifdef NCURSES_VERSION
6693 Autoconf NCURSES_VERSION
6701 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
6702 { (eval echo "$as_me:6702: \"$cf_try\"") >&5
6705 echo "$as_me:6705: \$? = $ac_status" >&5
6706 (exit $ac_status); }
6707 if test -f conftest.out ; then
6708 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
6709 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
6714 cat >conftest.$ac_ext <<_ACEOF
6715 #line 6715 "configure"
6716 #include "confdefs.h"
6718 #include <${cf_cv_ncurses_header:-curses.h}>
6722 FILE *fp = fopen("$cf_tempfile", "w");
6723 #ifdef NCURSES_VERSION
6724 # ifdef NCURSES_VERSION_PATCH
6725 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
6727 fprintf(fp, "%s\n", NCURSES_VERSION);
6731 fprintf(fp, "old\n");
6736 ${cf_cv_main_return:-return}(0);
6739 rm -f conftest$ac_exeext
6740 if { (eval echo "$as_me:6740: \"$ac_link\"") >&5
6741 (eval $ac_link) 2>&5
6743 echo "$as_me:6743: \$? = $ac_status" >&5
6744 (exit $ac_status); } && { ac_try='./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
6751 cf_cv_ncurses_version=`cat $cf_tempfile`
6753 echo "$as_me: program exited with status $ac_status" >&5
6754 echo "$as_me: failed program was:" >&5
6755 cat conftest.$ac_ext >&5
6757 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6762 echo "$as_me:6762: result: $cf_cv_ncurses_version" >&5
6763 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
6764 test "$cf_cv_ncurses_version" = no || cat >>confdefs.h <<\EOF
6768 cf_nculib_root=ncurses
6769 # This works, except for the special case where we find gpm, but
6770 # ncurses is in a nonstandard location via $LIBS, and we really want
6773 cf_ncurses_SAVE="$LIBS"
6774 echo "$as_me:6774: checking for Gpm_Open in -lgpm" >&5
6775 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
6776 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
6777 echo $ECHO_N "(cached) $ECHO_C" >&6
6779 ac_check_lib_save_LIBS=$LIBS
6781 cat >conftest.$ac_ext <<_ACEOF
6782 #line 6782 "configure"
6783 #include "confdefs.h"
6785 /* Override any gcc2 internal prototype to avoid an error. */
6789 /* We use char because int might match the return type of a gcc2
6790 builtin and then its argument prototype would still apply. */
6800 rm -f conftest.$ac_objext conftest$ac_exeext
6801 if { (eval echo "$as_me:6801: \"$ac_link\"") >&5
6802 (eval $ac_link) 2>&5
6804 echo "$as_me:6804: \$? = $ac_status" >&5
6805 (exit $ac_status); } &&
6806 { ac_try='test -s conftest$ac_exeext'
6807 { (eval echo "$as_me:6807: \"$ac_try\"") >&5
6810 echo "$as_me:6810: \$? = $ac_status" >&5
6811 (exit $ac_status); }; }; then
6812 ac_cv_lib_gpm_Gpm_Open=yes
6814 echo "$as_me: failed program was:" >&5
6815 cat conftest.$ac_ext >&5
6816 ac_cv_lib_gpm_Gpm_Open=no
6818 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6819 LIBS=$ac_check_lib_save_LIBS
6821 echo "$as_me:6821: result: $ac_cv_lib_gpm_Gpm_Open" >&5
6822 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
6823 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
6824 echo "$as_me:6824: checking for initscr in -lgpm" >&5
6825 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
6826 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
6827 echo $ECHO_N "(cached) $ECHO_C" >&6
6829 ac_check_lib_save_LIBS=$LIBS
6831 cat >conftest.$ac_ext <<_ACEOF
6832 #line 6832 "configure"
6833 #include "confdefs.h"
6835 /* Override any gcc2 internal prototype to avoid an error. */
6839 /* We use char because int might match the return type of a gcc2
6840 builtin and then its argument prototype would still apply. */
6850 rm -f conftest.$ac_objext conftest$ac_exeext
6851 if { (eval echo "$as_me:6851: \"$ac_link\"") >&5
6852 (eval $ac_link) 2>&5
6854 echo "$as_me:6854: \$? = $ac_status" >&5
6855 (exit $ac_status); } &&
6856 { ac_try='test -s conftest$ac_exeext'
6857 { (eval echo "$as_me:6857: \"$ac_try\"") >&5
6860 echo "$as_me:6860: \$? = $ac_status" >&5
6861 (exit $ac_status); }; }; then
6862 ac_cv_lib_gpm_initscr=yes
6864 echo "$as_me: failed program was:" >&5
6865 cat conftest.$ac_ext >&5
6866 ac_cv_lib_gpm_initscr=no
6868 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6869 LIBS=$ac_check_lib_save_LIBS
6871 echo "$as_me:6871: result: $ac_cv_lib_gpm_initscr" >&5
6872 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
6873 if test $ac_cv_lib_gpm_initscr = yes; then
6874 LIBS="$cf_ncurses_SAVE"
6876 cf_ncurses_LIBS="-lgpm"
6881 case $host_os in #(vi
6883 # This is only necessary if you are linking against an obsolete
6884 # version of ncurses (but it should do no harm, since it's static).
6885 if test "$cf_nculib_root" = ncurses ; then
6886 echo "$as_me:6886: checking for tgoto in -lmytinfo" >&5
6887 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
6888 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
6889 echo $ECHO_N "(cached) $ECHO_C" >&6
6891 ac_check_lib_save_LIBS=$LIBS
6892 LIBS="-lmytinfo $LIBS"
6893 cat >conftest.$ac_ext <<_ACEOF
6894 #line 6894 "configure"
6895 #include "confdefs.h"
6897 /* Override any gcc2 internal prototype to avoid an error. */
6901 /* We use char because int might match the return type of a gcc2
6902 builtin and then its argument prototype would still apply. */
6912 rm -f conftest.$ac_objext conftest$ac_exeext
6913 if { (eval echo "$as_me:6913: \"$ac_link\"") >&5
6914 (eval $ac_link) 2>&5
6916 echo "$as_me:6916: \$? = $ac_status" >&5
6917 (exit $ac_status); } &&
6918 { ac_try='test -s conftest$ac_exeext'
6919 { (eval echo "$as_me:6919: \"$ac_try\"") >&5
6922 echo "$as_me:6922: \$? = $ac_status" >&5
6923 (exit $ac_status); }; }; then
6924 ac_cv_lib_mytinfo_tgoto=yes
6926 echo "$as_me: failed program was:" >&5
6927 cat conftest.$ac_ext >&5
6928 ac_cv_lib_mytinfo_tgoto=no
6930 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6931 LIBS=$ac_check_lib_save_LIBS
6933 echo "$as_me:6933: result: $ac_cv_lib_mytinfo_tgoto" >&5
6934 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
6935 if test $ac_cv_lib_mytinfo_tgoto = yes; then
6936 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
6943 LIBS="$cf_ncurses_LIBS $LIBS"
6945 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
6947 LIBS="-l$cf_nculib_root $LIBS"
6950 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
6952 echo "$as_me:6952: checking for initscr" >&5
6953 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
6954 if test "${ac_cv_func_initscr+set}" = set; then
6955 echo $ECHO_N "(cached) $ECHO_C" >&6
6957 cat >conftest.$ac_ext <<_ACEOF
6958 #line 6958 "configure"
6959 #include "confdefs.h"
6960 /* System header to define __stub macros and hopefully few prototypes,
6961 which can conflict with char initscr (); below. */
6963 /* Override any gcc2 internal prototype to avoid an error. */
6967 /* We use char because int might match the return type of a gcc2
6968 builtin and then its argument prototype would still apply. */
6975 /* The GNU C library defines this for functions which it implements
6976 to always fail with ENOSYS. Some functions are actually named
6977 something starting with __ and the normal name is an alias. */
6978 #if defined (__stub_initscr) || defined (__stub___initscr)
6988 rm -f conftest.$ac_objext conftest$ac_exeext
6989 if { (eval echo "$as_me:6989: \"$ac_link\"") >&5
6990 (eval $ac_link) 2>&5
6992 echo "$as_me:6992: \$? = $ac_status" >&5
6993 (exit $ac_status); } &&
6994 { ac_try='test -s conftest$ac_exeext'
6995 { (eval echo "$as_me:6995: \"$ac_try\"") >&5
6998 echo "$as_me:6998: \$? = $ac_status" >&5
6999 (exit $ac_status); }; }; then
7000 ac_cv_func_initscr=yes
7002 echo "$as_me: failed program was:" >&5
7003 cat conftest.$ac_ext >&5
7004 ac_cv_func_initscr=no
7006 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7008 echo "$as_me:7008: result: $ac_cv_func_initscr" >&5
7009 echo "${ECHO_T}$ac_cv_func_initscr" >&6
7010 if test $ac_cv_func_initscr = yes; then
7011 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
7014 cf_save_LIBS="$LIBS"
7015 echo "$as_me:7015: checking for initscr in -l$cf_nculib_root" >&5
7016 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
7017 LIBS="-l$cf_nculib_root $LIBS"
7018 cat >conftest.$ac_ext <<_ACEOF
7019 #line 7019 "configure"
7020 #include "confdefs.h"
7021 #include <${cf_cv_ncurses_header:-curses.h}>
7030 rm -f conftest.$ac_objext conftest$ac_exeext
7031 if { (eval echo "$as_me:7031: \"$ac_link\"") >&5
7032 (eval $ac_link) 2>&5
7034 echo "$as_me:7034: \$? = $ac_status" >&5
7035 (exit $ac_status); } &&
7036 { ac_try='test -s conftest$ac_exeext'
7037 { (eval echo "$as_me:7037: \"$ac_try\"") >&5
7040 echo "$as_me:7040: \$? = $ac_status" >&5
7041 (exit $ac_status); }; }; then
7042 echo "$as_me:7042: result: yes" >&5
7043 echo "${ECHO_T}yes" >&6
7044 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
7047 echo "$as_me: failed program was:" >&5
7048 cat conftest.$ac_ext >&5
7049 echo "$as_me:7049: result: no" >&5
7050 echo "${ECHO_T}no" >&6
7053 cf_library_path_list=""
7054 if test -n "${LDFLAGS}${LIBS}" ; then
7055 for cf_library_path in $LDFLAGS $LIBS
7057 case $cf_library_path in #(vi
7059 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
7061 test "$cf_library_path" != "NONE" && \
7062 test -d "$cf_library_path" && \
7064 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
7065 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
7066 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
7067 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
7068 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
7069 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"
7072 cf_library_path_list="$cf_library_path_list $cf_search"
7080 test "/usr" != "$prefix" && \
7082 (test $prefix = NONE || test "/usr" != "$prefix") && {
7083 test -n "$verbose" && echo " ... testing for lib-directories under /usr"
7084 test -d /usr/lib && cf_search="$cf_search /usr/lib"
7085 test -d /usr/lib/$cf_nculib_root && cf_search="$cf_search /usr/lib/$cf_nculib_root"
7086 test -d /usr/lib/$cf_nculib_root/lib && cf_search="$cf_search /usr/lib/$cf_nculib_root/lib"
7087 test -d /usr/$cf_nculib_root/lib && cf_search="$cf_search /usr/$cf_nculib_root/lib"
7088 test -d /usr/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /usr/$cf_nculib_root/lib/$cf_nculib_root"
7091 test "$prefix" != "NONE" && \
7092 test -d "$prefix" && \
7094 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
7095 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
7096 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
7097 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
7098 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
7099 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
7102 test "/usr/local" != "$prefix" && \
7103 test -d "/usr/local" && \
7104 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
7105 test -n "$verbose" && echo " ... testing for lib-directories under /usr/local"
7106 test -d /usr/local/lib && cf_search="$cf_search /usr/local/lib"
7107 test -d /usr/local/lib/$cf_nculib_root && cf_search="$cf_search /usr/local/lib/$cf_nculib_root"
7108 test -d /usr/local/lib/$cf_nculib_root/lib && cf_search="$cf_search /usr/local/lib/$cf_nculib_root/lib"
7109 test -d /usr/local/$cf_nculib_root/lib && cf_search="$cf_search /usr/local/$cf_nculib_root/lib"
7110 test -d /usr/local/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /usr/local/$cf_nculib_root/lib/$cf_nculib_root"
7113 test "/opt" != "$prefix" && \
7115 (test $prefix = NONE || test "/opt" != "$prefix") && {
7116 test -n "$verbose" && echo " ... testing for lib-directories under /opt"
7117 test -d /opt/lib && cf_search="$cf_search /opt/lib"
7118 test -d /opt/lib/$cf_nculib_root && cf_search="$cf_search /opt/lib/$cf_nculib_root"
7119 test -d /opt/lib/$cf_nculib_root/lib && cf_search="$cf_search /opt/lib/$cf_nculib_root/lib"
7120 test -d /opt/$cf_nculib_root/lib && cf_search="$cf_search /opt/$cf_nculib_root/lib"
7121 test -d /opt/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /opt/$cf_nculib_root/lib/$cf_nculib_root"
7124 test "$HOME" != "$prefix" && \
7125 test -d "$HOME" && \
7126 (test $prefix = NONE || test "$HOME" != "$prefix") && {
7127 test -n "$verbose" && echo " ... testing for lib-directories under $HOME"
7128 test -d $HOME/lib && cf_search="$cf_search $HOME/lib"
7129 test -d $HOME/lib/$cf_nculib_root && cf_search="$cf_search $HOME/lib/$cf_nculib_root"
7130 test -d $HOME/lib/$cf_nculib_root/lib && cf_search="$cf_search $HOME/lib/$cf_nculib_root/lib"
7131 test -d $HOME/$cf_nculib_root/lib && cf_search="$cf_search $HOME/$cf_nculib_root/lib"
7132 test -d $HOME/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $HOME/$cf_nculib_root/lib/$cf_nculib_root"
7135 cf_search="$cf_library_path_list $cf_search"
7137 for cf_libdir in $cf_search
7139 echo "$as_me:7139: checking for -l$cf_nculib_root in $cf_libdir" >&5
7140 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
7141 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
7142 cat >conftest.$ac_ext <<_ACEOF
7143 #line 7143 "configure"
7144 #include "confdefs.h"
7145 #include <${cf_cv_ncurses_header:-curses.h}>
7154 rm -f conftest.$ac_objext conftest$ac_exeext
7155 if { (eval echo "$as_me:7155: \"$ac_link\"") >&5
7156 (eval $ac_link) 2>&5
7158 echo "$as_me:7158: \$? = $ac_status" >&5
7159 (exit $ac_status); } &&
7160 { ac_try='test -s conftest$ac_exeext'
7161 { (eval echo "$as_me:7161: \"$ac_try\"") >&5
7164 echo "$as_me:7164: \$? = $ac_status" >&5
7165 (exit $ac_status); }; }; then
7166 echo "$as_me:7166: result: yes" >&5
7167 echo "${ECHO_T}yes" >&6
7168 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
7171 echo "$as_me: failed program was:" >&5
7172 cat conftest.$ac_ext >&5
7173 echo "$as_me:7173: result: no" >&5
7174 echo "${ECHO_T}no" >&6
7175 LIBS="$cf_save_LIBS"
7177 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7181 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7185 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
7187 if test $cf_found_library = no ; then
7188 { { echo "$as_me:7188: error: Cannot link $cf_nculib_root library" >&5
7189 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
7190 { (exit 1); exit 1; }; }
7195 if test -n "$cf_ncurses_LIBS" ; then
7196 echo "$as_me:7196: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
7197 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
7198 cf_ncurses_SAVE="$LIBS"
7199 for p in $cf_ncurses_LIBS ; do
7200 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
7201 if test "$q" != "$LIBS" ; then
7205 cat >conftest.$ac_ext <<_ACEOF
7206 #line 7206 "configure"
7207 #include "confdefs.h"
7208 #include <${cf_cv_ncurses_header:-curses.h}>
7212 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
7217 rm -f conftest.$ac_objext conftest$ac_exeext
7218 if { (eval echo "$as_me:7218: \"$ac_link\"") >&5
7219 (eval $ac_link) 2>&5
7221 echo "$as_me:7221: \$? = $ac_status" >&5
7222 (exit $ac_status); } &&
7223 { ac_try='test -s conftest$ac_exeext'
7224 { (eval echo "$as_me:7224: \"$ac_try\"") >&5
7227 echo "$as_me:7227: \$? = $ac_status" >&5
7228 (exit $ac_status); }; }; then
7229 echo "$as_me:7229: result: yes" >&5
7230 echo "${ECHO_T}yes" >&6
7232 echo "$as_me: failed program was:" >&5
7233 cat conftest.$ac_ext >&5
7234 echo "$as_me:7234: result: no" >&5
7235 echo "${ECHO_T}no" >&6
7236 LIBS="$cf_ncurses_SAVE"
7238 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7241 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
7243 cat >>confdefs.h <<EOF
7244 #define $cf_nculib_ROOT 1
7253 echo "$as_me:7253: checking for multibyte character support" >&5
7254 echo $ECHO_N "checking for multibyte character support... $ECHO_C" >&6
7255 if test "${cf_cv_utf8_lib+set}" = set; then
7256 echo $ECHO_N "(cached) $ECHO_C" >&6
7259 cf_save_LIBS="$LIBS"
7260 cat >conftest.$ac_ext <<_ACEOF
7261 #line 7261 "configure"
7262 #include "confdefs.h"
7273 rm -f conftest.$ac_objext conftest$ac_exeext
7274 if { (eval echo "$as_me:7274: \"$ac_link\"") >&5
7275 (eval $ac_link) 2>&5
7277 echo "$as_me:7277: \$? = $ac_status" >&5
7278 (exit $ac_status); } &&
7279 { ac_try='test -s conftest$ac_exeext'
7280 { (eval echo "$as_me:7280: \"$ac_try\"") >&5
7283 echo "$as_me:7283: \$? = $ac_status" >&5
7284 (exit $ac_status); }; }; then
7287 echo "$as_me: failed program was:" >&5
7288 cat conftest.$ac_ext >&5
7290 # If the linkage is not already in the $CPPFLAGS/$LDFLAGS configuration, these
7291 # will be set on completion of the AC_TRY_LINK below.
7292 cf_cv_header_path_utf8=
7293 cf_cv_library_path_utf8=
7295 echo "${as_me:-configure}:7295: testing Starting FIND_LINKAGE(utf8,) ..." 1>&5
7297 cf_save_LIBS="$LIBS"
7299 cat >conftest.$ac_ext <<_ACEOF
7300 #line 7300 "configure"
7301 #include "confdefs.h"
7303 #include <libutf8.h>
7312 rm -f conftest.$ac_objext conftest$ac_exeext
7313 if { (eval echo "$as_me:7313: \"$ac_link\"") >&5
7314 (eval $ac_link) 2>&5
7316 echo "$as_me:7316: \$? = $ac_status" >&5
7317 (exit $ac_status); } &&
7318 { ac_try='test -s conftest$ac_exeext'
7319 { (eval echo "$as_me:7319: \"$ac_try\"") >&5
7322 echo "$as_me:7322: \$? = $ac_status" >&5
7323 (exit $ac_status); }; }; then
7325 cf_cv_find_linkage_utf8=yes
7326 cf_cv_header_path_utf8=/usr/include
7327 cf_cv_library_path_utf8=/usr/lib
7330 echo "$as_me: failed program was:" >&5
7331 cat conftest.$ac_ext >&5
7333 LIBS="-lutf8 $cf_save_LIBS"
7335 cat >conftest.$ac_ext <<_ACEOF
7336 #line 7336 "configure"
7337 #include "confdefs.h"
7339 #include <libutf8.h>
7348 rm -f conftest.$ac_objext conftest$ac_exeext
7349 if { (eval echo "$as_me:7349: \"$ac_link\"") >&5
7350 (eval $ac_link) 2>&5
7352 echo "$as_me:7352: \$? = $ac_status" >&5
7353 (exit $ac_status); } &&
7354 { ac_try='test -s conftest$ac_exeext'
7355 { (eval echo "$as_me:7355: \"$ac_try\"") >&5
7358 echo "$as_me:7358: \$? = $ac_status" >&5
7359 (exit $ac_status); }; }; then
7361 cf_cv_find_linkage_utf8=yes
7362 cf_cv_header_path_utf8=/usr/include
7363 cf_cv_library_path_utf8=/usr/lib
7364 cf_cv_library_file_utf8="-lutf8"
7367 echo "$as_me: failed program was:" >&5
7368 cat conftest.$ac_ext >&5
7370 cf_cv_find_linkage_utf8=no
7371 LIBS="$cf_save_LIBS"
7373 test -n "$verbose" && echo " find linkage for utf8 library" 1>&6
7375 echo "${as_me:-configure}:7375: testing find linkage for utf8 library ..." 1>&5
7377 echo "${as_me:-configure}:7377: testing Searching for headers in FIND_LINKAGE(utf8,) ..." 1>&5
7379 cf_save_CPPFLAGS="$CPPFLAGS"
7380 cf_test_CPPFLAGS="$CPPFLAGS"
7384 # collect the current set of include-directories from compiler flags
7385 cf_header_path_list=""
7386 if test -n "${CFLAGS}${CPPFLAGS}" ; then
7387 for cf_header_path in $CPPFLAGS $CFLAGS
7389 case $cf_header_path in #(vi
7391 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
7393 test "$cf_header_path" != "NONE" && \
7394 test -d "$cf_header_path" && \
7396 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
7397 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
7398 test -d $cf_header_path/include/utf8 && cf_search="$cf_search $cf_header_path/include/utf8"
7399 test -d $cf_header_path/include/utf8/include && cf_search="$cf_search $cf_header_path/include/utf8/include"
7400 test -d $cf_header_path/utf8/include && cf_search="$cf_search $cf_header_path/utf8/include"
7401 test -d $cf_header_path/utf8/include/utf8 && cf_search="$cf_search $cf_header_path/utf8/include/utf8"
7404 cf_header_path_list="$cf_header_path_list $cf_search"
7410 # add the variations for the package we are looking for
7414 test "/usr" != "$prefix" && \
7416 (test $prefix = NONE || test "/usr" != "$prefix") && {
7417 test -n "$verbose" && echo " ... testing for include-directories under /usr"
7418 test -d /usr/include && cf_search="$cf_search /usr/include"
7419 test -d /usr/include/utf8 && cf_search="$cf_search /usr/include/utf8"
7420 test -d /usr/include/utf8/include && cf_search="$cf_search /usr/include/utf8/include"
7421 test -d /usr/utf8/include && cf_search="$cf_search /usr/utf8/include"
7422 test -d /usr/utf8/include/utf8 && cf_search="$cf_search /usr/utf8/include/utf8"
7425 test "$prefix" != "NONE" && \
7426 test -d "$prefix" && \
7428 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
7429 test -d $prefix/include && cf_search="$cf_search $prefix/include"
7430 test -d $prefix/include/utf8 && cf_search="$cf_search $prefix/include/utf8"
7431 test -d $prefix/include/utf8/include && cf_search="$cf_search $prefix/include/utf8/include"
7432 test -d $prefix/utf8/include && cf_search="$cf_search $prefix/utf8/include"
7433 test -d $prefix/utf8/include/utf8 && cf_search="$cf_search $prefix/utf8/include/utf8"
7436 test "/usr/local" != "$prefix" && \
7437 test -d "/usr/local" && \
7438 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
7439 test -n "$verbose" && echo " ... testing for include-directories under /usr/local"
7440 test -d /usr/local/include && cf_search="$cf_search /usr/local/include"
7441 test -d /usr/local/include/utf8 && cf_search="$cf_search /usr/local/include/utf8"
7442 test -d /usr/local/include/utf8/include && cf_search="$cf_search /usr/local/include/utf8/include"
7443 test -d /usr/local/utf8/include && cf_search="$cf_search /usr/local/utf8/include"
7444 test -d /usr/local/utf8/include/utf8 && cf_search="$cf_search /usr/local/utf8/include/utf8"
7447 test "/opt" != "$prefix" && \
7449 (test $prefix = NONE || test "/opt" != "$prefix") && {
7450 test -n "$verbose" && echo " ... testing for include-directories under /opt"
7451 test -d /opt/include && cf_search="$cf_search /opt/include"
7452 test -d /opt/include/utf8 && cf_search="$cf_search /opt/include/utf8"
7453 test -d /opt/include/utf8/include && cf_search="$cf_search /opt/include/utf8/include"
7454 test -d /opt/utf8/include && cf_search="$cf_search /opt/utf8/include"
7455 test -d /opt/utf8/include/utf8 && cf_search="$cf_search /opt/utf8/include/utf8"
7458 test "$HOME" != "$prefix" && \
7459 test -d "$HOME" && \
7460 (test $prefix = NONE || test "$HOME" != "$prefix") && {
7461 test -n "$verbose" && echo " ... testing for include-directories under $HOME"
7462 test -d $HOME/include && cf_search="$cf_search $HOME/include"
7463 test -d $HOME/include/utf8 && cf_search="$cf_search $HOME/include/utf8"
7464 test -d $HOME/include/utf8/include && cf_search="$cf_search $HOME/include/utf8/include"
7465 test -d $HOME/utf8/include && cf_search="$cf_search $HOME/utf8/include"
7466 test -d $HOME/utf8/include/utf8 && cf_search="$cf_search $HOME/utf8/include/utf8"
7469 test "$includedir" != NONE && \
7470 test "$includedir" != "/usr/include" && \
7471 test -d "$includedir" && {
7472 test -d $includedir && cf_search="$cf_search $includedir"
7473 test -d $includedir/utf8 && cf_search="$cf_search $includedir/utf8"
7476 test "$oldincludedir" != NONE && \
7477 test "$oldincludedir" != "/usr/include" && \
7478 test -d "$oldincludedir" && {
7479 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
7480 test -d $oldincludedir/utf8 && cf_search="$cf_search $oldincludedir/utf8"
7483 cf_search="$cf_search $cf_header_path_list"
7485 for cf_cv_header_path_utf8 in $cf_search
7487 if test -d $cf_cv_header_path_utf8 ; then
7488 test -n "$verbose" && echo " ... testing $cf_cv_header_path_utf8" 1>&6
7490 echo "${as_me:-configure}:7490: testing ... testing $cf_cv_header_path_utf8 ..." 1>&5
7492 CPPFLAGS="$cf_save_CPPFLAGS -I$cf_cv_header_path_utf8"
7493 cat >conftest.$ac_ext <<_ACEOF
7494 #line 7494 "configure"
7495 #include "confdefs.h"
7497 #include <libutf8.h>
7506 rm -f conftest.$ac_objext
7507 if { (eval echo "$as_me:7507: \"$ac_compile\"") >&5
7508 (eval $ac_compile) 2>&5
7510 echo "$as_me:7510: \$? = $ac_status" >&5
7511 (exit $ac_status); } &&
7512 { ac_try='test -s conftest.$ac_objext'
7513 { (eval echo "$as_me:7513: \"$ac_try\"") >&5
7516 echo "$as_me:7516: \$? = $ac_status" >&5
7517 (exit $ac_status); }; }; then
7519 test -n "$verbose" && echo " ... found utf8 headers in $cf_cv_header_path_utf8" 1>&6
7521 echo "${as_me:-configure}:7521: testing ... found utf8 headers in $cf_cv_header_path_utf8 ..." 1>&5
7523 cf_cv_find_linkage_utf8=maybe
7524 cf_test_CPPFLAGS="$CPPFLAGS"
7527 echo "$as_me: failed program was:" >&5
7528 cat conftest.$ac_ext >&5
7530 CPPFLAGS="$cf_save_CPPFLAGS"
7533 rm -f conftest.$ac_objext conftest.$ac_ext
7537 if test "$cf_cv_find_linkage_utf8" = maybe ; then
7539 echo "${as_me:-configure}:7539: testing Searching for utf8 library in FIND_LINKAGE(utf8,) ..." 1>&5
7541 cf_save_LIBS="$LIBS"
7542 cf_save_LDFLAGS="$LDFLAGS"
7544 if test "$cf_cv_find_linkage_utf8" != yes ; then
7547 cf_library_path_list=""
7548 if test -n "${LDFLAGS}${LIBS}" ; then
7549 for cf_library_path in $LDFLAGS $LIBS
7551 case $cf_library_path in #(vi
7553 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
7555 test "$cf_library_path" != "NONE" && \
7556 test -d "$cf_library_path" && \
7558 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
7559 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
7560 test -d $cf_library_path/lib/utf8 && cf_search="$cf_search $cf_library_path/lib/utf8"
7561 test -d $cf_library_path/lib/utf8/lib && cf_search="$cf_search $cf_library_path/lib/utf8/lib"
7562 test -d $cf_library_path/utf8/lib && cf_search="$cf_search $cf_library_path/utf8/lib"
7563 test -d $cf_library_path/utf8/lib/utf8 && cf_search="$cf_search $cf_library_path/utf8/lib/utf8"
7566 cf_library_path_list="$cf_library_path_list $cf_search"
7574 test "/usr" != "$prefix" && \
7576 (test $prefix = NONE || test "/usr" != "$prefix") && {
7577 test -n "$verbose" && echo " ... testing for lib-directories under /usr"
7578 test -d /usr/lib && cf_search="$cf_search /usr/lib"
7579 test -d /usr/lib/utf8 && cf_search="$cf_search /usr/lib/utf8"
7580 test -d /usr/lib/utf8/lib && cf_search="$cf_search /usr/lib/utf8/lib"
7581 test -d /usr/utf8/lib && cf_search="$cf_search /usr/utf8/lib"
7582 test -d /usr/utf8/lib/utf8 && cf_search="$cf_search /usr/utf8/lib/utf8"
7585 test "$prefix" != "NONE" && \
7586 test -d "$prefix" && \
7588 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
7589 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
7590 test -d $prefix/lib/utf8 && cf_search="$cf_search $prefix/lib/utf8"
7591 test -d $prefix/lib/utf8/lib && cf_search="$cf_search $prefix/lib/utf8/lib"
7592 test -d $prefix/utf8/lib && cf_search="$cf_search $prefix/utf8/lib"
7593 test -d $prefix/utf8/lib/utf8 && cf_search="$cf_search $prefix/utf8/lib/utf8"
7596 test "/usr/local" != "$prefix" && \
7597 test -d "/usr/local" && \
7598 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
7599 test -n "$verbose" && echo " ... testing for lib-directories under /usr/local"
7600 test -d /usr/local/lib && cf_search="$cf_search /usr/local/lib"
7601 test -d /usr/local/lib/utf8 && cf_search="$cf_search /usr/local/lib/utf8"
7602 test -d /usr/local/lib/utf8/lib && cf_search="$cf_search /usr/local/lib/utf8/lib"
7603 test -d /usr/local/utf8/lib && cf_search="$cf_search /usr/local/utf8/lib"
7604 test -d /usr/local/utf8/lib/utf8 && cf_search="$cf_search /usr/local/utf8/lib/utf8"
7607 test "/opt" != "$prefix" && \
7609 (test $prefix = NONE || test "/opt" != "$prefix") && {
7610 test -n "$verbose" && echo " ... testing for lib-directories under /opt"
7611 test -d /opt/lib && cf_search="$cf_search /opt/lib"
7612 test -d /opt/lib/utf8 && cf_search="$cf_search /opt/lib/utf8"
7613 test -d /opt/lib/utf8/lib && cf_search="$cf_search /opt/lib/utf8/lib"
7614 test -d /opt/utf8/lib && cf_search="$cf_search /opt/utf8/lib"
7615 test -d /opt/utf8/lib/utf8 && cf_search="$cf_search /opt/utf8/lib/utf8"
7618 test "$HOME" != "$prefix" && \
7619 test -d "$HOME" && \
7620 (test $prefix = NONE || test "$HOME" != "$prefix") && {
7621 test -n "$verbose" && echo " ... testing for lib-directories under $HOME"
7622 test -d $HOME/lib && cf_search="$cf_search $HOME/lib"
7623 test -d $HOME/lib/utf8 && cf_search="$cf_search $HOME/lib/utf8"
7624 test -d $HOME/lib/utf8/lib && cf_search="$cf_search $HOME/lib/utf8/lib"
7625 test -d $HOME/utf8/lib && cf_search="$cf_search $HOME/utf8/lib"
7626 test -d $HOME/utf8/lib/utf8 && cf_search="$cf_search $HOME/utf8/lib/utf8"
7629 cf_search="$cf_library_path_list $cf_search"
7631 for cf_cv_library_path_utf8 in $cf_search
7633 if test -d $cf_cv_library_path_utf8 ; then
7634 test -n "$verbose" && echo " ... testing $cf_cv_library_path_utf8" 1>&6
7636 echo "${as_me:-configure}:7636: testing ... testing $cf_cv_library_path_utf8 ..." 1>&5
7638 CPPFLAGS="$cf_test_CPPFLAGS"
7639 LIBS="-lutf8 $cf_save_LIBS"
7640 LDFLAGS="$cf_save_LDFLAGS -L$cf_cv_library_path_utf8"
7641 cat >conftest.$ac_ext <<_ACEOF
7642 #line 7642 "configure"
7643 #include "confdefs.h"
7645 #include <libutf8.h>
7654 rm -f conftest.$ac_objext conftest$ac_exeext
7655 if { (eval echo "$as_me:7655: \"$ac_link\"") >&5
7656 (eval $ac_link) 2>&5
7658 echo "$as_me:7658: \$? = $ac_status" >&5
7659 (exit $ac_status); } &&
7660 { ac_try='test -s conftest$ac_exeext'
7661 { (eval echo "$as_me:7661: \"$ac_try\"") >&5
7664 echo "$as_me:7664: \$? = $ac_status" >&5
7665 (exit $ac_status); }; }; then
7667 test -n "$verbose" && echo " ... found utf8 library in $cf_cv_library_path_utf8" 1>&6
7669 echo "${as_me:-configure}:7669: testing ... found utf8 library in $cf_cv_library_path_utf8 ..." 1>&5
7671 cf_cv_find_linkage_utf8=yes
7672 cf_cv_library_file_utf8="-lutf8"
7675 echo "$as_me: failed program was:" >&5
7676 cat conftest.$ac_ext >&5
7678 CPPFLAGS="$cf_save_CPPFLAGS"
7679 LIBS="$cf_save_LIBS"
7680 LDFLAGS="$cf_save_LDFLAGS"
7683 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7686 CPPFLAGS="$cf_save_CPPFLAGS"
7687 LDFLAGS="$cf_save_LDFLAGS"
7691 cf_cv_find_linkage_utf8=no
7695 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7698 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7700 LIBS="$cf_save_LIBS"
7702 if test "$cf_cv_find_linkage_utf8" = yes ; then
7703 cf_cv_utf8_lib=add-on
7709 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7711 echo "$as_me:7711: result: $cf_cv_utf8_lib" >&5
7712 echo "${ECHO_T}$cf_cv_utf8_lib" >&6
7714 # HAVE_LIBUTF8_H is used by ncurses if curses.h is shared between
7716 if test "$cf_cv_utf8_lib" = "add-on" ; then
7717 cat >>confdefs.h <<\EOF
7718 #define HAVE_LIBUTF8_H 1
7721 if test -n "$cf_cv_header_path_utf8" ; then
7722 for cf_add_incdir in $cf_cv_header_path_utf8
7724 while test $cf_add_incdir != /usr/include
7726 if test -d $cf_add_incdir
7729 if test -n "$CFLAGS$CPPFLAGS" ; then
7730 # a loop is needed to ensure we can add subdirs of existing dirs
7731 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
7732 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
7733 cf_have_incdir=yes; break
7738 if test "$cf_have_incdir" = no ; then
7739 if test "$cf_add_incdir" = /usr/local/include ; then
7740 if test "$GCC" = yes
7742 cf_save_CPPFLAGS=$CPPFLAGS
7743 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7744 cat >conftest.$ac_ext <<_ACEOF
7745 #line 7745 "configure"
7746 #include "confdefs.h"
7756 rm -f conftest.$ac_objext
7757 if { (eval echo "$as_me:7757: \"$ac_compile\"") >&5
7758 (eval $ac_compile) 2>&5
7760 echo "$as_me:7760: \$? = $ac_status" >&5
7761 (exit $ac_status); } &&
7762 { ac_try='test -s conftest.$ac_objext'
7763 { (eval echo "$as_me:7763: \"$ac_try\"") >&5
7766 echo "$as_me:7766: \$? = $ac_status" >&5
7767 (exit $ac_status); }; }; then
7770 echo "$as_me: failed program was:" >&5
7771 cat conftest.$ac_ext >&5
7774 rm -f conftest.$ac_objext conftest.$ac_ext
7775 CPPFLAGS=$cf_save_CPPFLAGS
7780 if test "$cf_have_incdir" = no ; then
7781 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
7783 echo "${as_me:-configure}:7783: testing adding $cf_add_incdir to include-path ..." 1>&5
7785 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7787 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
7788 test "$cf_top_incdir" = "$cf_add_incdir" && break
7789 cf_add_incdir="$cf_top_incdir"
7798 if test -n "$cf_cv_library_path_utf8" ; then
7799 for cf_add_libdir in $cf_cv_library_path_utf8
7801 if test $cf_add_libdir = /usr/lib ; then
7803 elif test -d $cf_add_libdir
7806 if test -n "$LDFLAGS$LIBS" ; then
7807 # a loop is needed to ensure we can add subdirs of existing dirs
7808 for cf_test_libdir in $LDFLAGS $LIBS ; do
7809 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
7810 cf_have_libdir=yes; break
7814 if test "$cf_have_libdir" = no ; then
7815 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
7817 echo "${as_me:-configure}:7817: testing adding $cf_add_libdir to library-path ..." 1>&5
7819 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
7825 LIBS="$cf_cv_library_file_utf8 $LIBS"
7828 cf_ncuconfig_root=ncursesw
7830 echo "Looking for ${cf_ncuconfig_root}-config"
7831 for ac_prog in ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
7833 # Extract the first word of "$ac_prog", so it can be a program name with args.
7834 set dummy $ac_prog; ac_word=$2
7835 echo "$as_me:7835: checking for $ac_word" >&5
7836 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7837 if test "${ac_cv_path_NCURSES_CONFIG+set}" = set; then
7838 echo $ECHO_N "(cached) $ECHO_C" >&6
7840 case $NCURSES_CONFIG in
7842 ac_cv_path_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test with a path.
7845 ac_save_IFS=$IFS; IFS=$ac_path_separator
7847 for ac_dir in $ac_dummy; do
7849 test -z "$ac_dir" && ac_dir=.
7850 if $as_executable_p "$ac_dir/$ac_word"; then
7851 ac_cv_path_NCURSES_CONFIG="$ac_dir/$ac_word"
7852 echo "$as_me:7852: found $ac_dir/$ac_word" >&5
7860 NCURSES_CONFIG=$ac_cv_path_NCURSES_CONFIG
7862 if test -n "$NCURSES_CONFIG"; then
7863 echo "$as_me:7863: result: $NCURSES_CONFIG" >&5
7864 echo "${ECHO_T}$NCURSES_CONFIG" >&6
7866 echo "$as_me:7866: result: no" >&5
7867 echo "${ECHO_T}no" >&6
7870 test -n "$NCURSES_CONFIG" && break
7872 test -n "$NCURSES_CONFIG" || NCURSES_CONFIG="none"
7874 if test "$NCURSES_CONFIG" != none ; then
7876 CPPFLAGS="$CPPFLAGS `$NCURSES_CONFIG --cflags`"
7877 LIBS="`$NCURSES_CONFIG --libs` $LIBS"
7879 # even with config script, some packages use no-override for curses.h
7881 echo "$as_me:7881: checking if we have identified curses headers" >&5
7882 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
7883 if test "${cf_cv_ncurses_header+set}" = set; then
7884 echo $ECHO_N "(cached) $ECHO_C" >&6
7887 cf_cv_ncurses_header=none
7890 ncursesw/ncurses.h \
7894 cat >conftest.$ac_ext <<_ACEOF
7895 #line 7895 "configure"
7896 #include "confdefs.h"
7897 #include <${cf_header}>
7901 initscr(); tgoto("?", 0,0)
7906 rm -f conftest.$ac_objext
7907 if { (eval echo "$as_me:7907: \"$ac_compile\"") >&5
7908 (eval $ac_compile) 2>&5
7910 echo "$as_me:7910: \$? = $ac_status" >&5
7911 (exit $ac_status); } &&
7912 { ac_try='test -s conftest.$ac_objext'
7913 { (eval echo "$as_me:7913: \"$ac_try\"") >&5
7916 echo "$as_me:7916: \$? = $ac_status" >&5
7917 (exit $ac_status); }; }; then
7918 cf_cv_ncurses_header=$cf_header; break
7920 echo "$as_me: failed program was:" >&5
7921 cat conftest.$ac_ext >&5
7923 rm -f conftest.$ac_objext conftest.$ac_ext
7927 echo "$as_me:7927: result: $cf_cv_ncurses_header" >&5
7928 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
7930 if test "$cf_cv_ncurses_header" = none ; then
7931 { { echo "$as_me:7931: error: No curses header-files found" >&5
7932 echo "$as_me: error: No curses header-files found" >&2;}
7933 { (exit 1); exit 1; }; }
7936 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
7938 for ac_header in $cf_cv_ncurses_header
7940 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7941 echo "$as_me:7941: checking for $ac_header" >&5
7942 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7943 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7944 echo $ECHO_N "(cached) $ECHO_C" >&6
7946 cat >conftest.$ac_ext <<_ACEOF
7947 #line 7947 "configure"
7948 #include "confdefs.h"
7949 #include <$ac_header>
7951 if { (eval echo "$as_me:7951: \"$ac_cpp conftest.$ac_ext\"") >&5
7952 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7954 egrep -v '^ *\+' conftest.er1 >conftest.err
7956 cat conftest.err >&5
7957 echo "$as_me:7957: \$? = $ac_status" >&5
7958 (exit $ac_status); } >/dev/null; then
7959 if test -s conftest.err; then
7960 ac_cpp_err=$ac_c_preproc_warn_flag
7967 if test -z "$ac_cpp_err"; then
7968 eval "$as_ac_Header=yes"
7970 echo "$as_me: failed program was:" >&5
7971 cat conftest.$ac_ext >&5
7972 eval "$as_ac_Header=no"
7974 rm -f conftest.err conftest.$ac_ext
7976 echo "$as_me:7976: result: `eval echo '${'$as_ac_Header'}'`" >&5
7977 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7978 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7979 cat >>confdefs.h <<EOF
7980 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7986 cat >>confdefs.h <<\EOF
7990 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
7992 cat >>confdefs.h <<EOF
7993 #define $cf_nculib_ROOT 1
7996 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
8000 cf_ncuhdr_root=ncursesw
8002 test -n "$cf_cv_curses_dir" && \
8003 test "$cf_cv_curses_dir" != "no" && { \
8005 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
8006 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
8008 while test $cf_add_incdir != /usr/include
8010 if test -d $cf_add_incdir
8013 if test -n "$CFLAGS$CPPFLAGS" ; then
8014 # a loop is needed to ensure we can add subdirs of existing dirs
8015 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
8016 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
8017 cf_have_incdir=yes; break
8022 if test "$cf_have_incdir" = no ; then
8023 if test "$cf_add_incdir" = /usr/local/include ; then
8024 if test "$GCC" = yes
8026 cf_save_CPPFLAGS=$CPPFLAGS
8027 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8028 cat >conftest.$ac_ext <<_ACEOF
8029 #line 8029 "configure"
8030 #include "confdefs.h"
8040 rm -f conftest.$ac_objext
8041 if { (eval echo "$as_me:8041: \"$ac_compile\"") >&5
8042 (eval $ac_compile) 2>&5
8044 echo "$as_me:8044: \$? = $ac_status" >&5
8045 (exit $ac_status); } &&
8046 { ac_try='test -s conftest.$ac_objext'
8047 { (eval echo "$as_me:8047: \"$ac_try\"") >&5
8050 echo "$as_me:8050: \$? = $ac_status" >&5
8051 (exit $ac_status); }; }; then
8054 echo "$as_me: failed program was:" >&5
8055 cat conftest.$ac_ext >&5
8058 rm -f conftest.$ac_objext conftest.$ac_ext
8059 CPPFLAGS=$cf_save_CPPFLAGS
8064 if test "$cf_have_incdir" = no ; then
8065 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
8067 echo "${as_me:-configure}:8067: testing adding $cf_add_incdir to include-path ..." 1>&5
8069 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8071 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
8072 test "$cf_top_incdir" = "$cf_add_incdir" && break
8073 cf_add_incdir="$cf_top_incdir"
8084 echo "$as_me:8084: checking for $cf_ncuhdr_root header in include-path" >&5
8085 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
8086 if test "${cf_cv_ncurses_h+set}" = set; then
8087 echo $ECHO_N "(cached) $ECHO_C" >&6
8090 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
8091 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
8092 for cf_header in $cf_header_list
8095 cat >conftest.$ac_ext <<_ACEOF
8096 #line 8096 "configure"
8097 #include "confdefs.h"
8099 #define _XOPEN_SOURCE_EXTENDED
8100 #undef HAVE_LIBUTF8_H /* in case we used CF_UTF8_LIB */
8101 #define HAVE_LIBUTF8_H /* to force ncurses' header file to use cchar_t */
8103 #include <$cf_header>
8108 #ifdef NCURSES_VERSION
8114 printf("%s\n", NCURSES_VERSION);
8127 rm -f conftest.$ac_objext
8128 if { (eval echo "$as_me:8128: \"$ac_compile\"") >&5
8129 (eval $ac_compile) 2>&5
8131 echo "$as_me:8131: \$? = $ac_status" >&5
8132 (exit $ac_status); } &&
8133 { ac_try='test -s conftest.$ac_objext'
8134 { (eval echo "$as_me:8134: \"$ac_try\"") >&5
8137 echo "$as_me:8137: \$? = $ac_status" >&5
8138 (exit $ac_status); }; }; then
8139 cf_cv_ncurses_h=$cf_header
8142 echo "$as_me: failed program was:" >&5
8143 cat conftest.$ac_ext >&5
8146 rm -f conftest.$ac_objext conftest.$ac_ext
8148 test "$cf_cv_ncurses_h" != no && break
8152 echo "$as_me:8152: result: $cf_cv_ncurses_h" >&5
8153 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
8155 if test "$cf_cv_ncurses_h" != no ; then
8156 cf_cv_ncurses_header=$cf_cv_ncurses_h
8159 echo "$as_me:8159: checking for $cf_ncuhdr_root include-path" >&5
8160 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
8161 if test "${cf_cv_ncurses_h2+set}" = set; then
8162 echo $ECHO_N "(cached) $ECHO_C" >&6
8165 test -n "$verbose" && echo
8169 # collect the current set of include-directories from compiler flags
8170 cf_header_path_list=""
8171 if test -n "${CFLAGS}${CPPFLAGS}" ; then
8172 for cf_header_path in $CPPFLAGS $CFLAGS
8174 case $cf_header_path in #(vi
8176 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
8178 test "$cf_header_path" != "NONE" && \
8179 test -d "$cf_header_path" && \
8181 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
8182 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
8183 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
8184 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
8185 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
8186 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"
8189 cf_header_path_list="$cf_header_path_list $cf_search"
8195 # add the variations for the package we are looking for
8199 test "/usr" != "$prefix" && \
8201 (test $prefix = NONE || test "/usr" != "$prefix") && {
8202 test -n "$verbose" && echo " ... testing for include-directories under /usr"
8203 test -d /usr/include && cf_search="$cf_search /usr/include"
8204 test -d /usr/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/include/$cf_ncuhdr_root"
8205 test -d /usr/include/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/include/$cf_ncuhdr_root/include"
8206 test -d /usr/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/$cf_ncuhdr_root/include"
8207 test -d /usr/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
8210 test "$prefix" != "NONE" && \
8211 test -d "$prefix" && \
8213 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
8214 test -d $prefix/include && cf_search="$cf_search $prefix/include"
8215 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
8216 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
8217 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
8218 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
8221 test "/usr/local" != "$prefix" && \
8222 test -d "/usr/local" && \
8223 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
8224 test -n "$verbose" && echo " ... testing for include-directories under /usr/local"
8225 test -d /usr/local/include && cf_search="$cf_search /usr/local/include"
8226 test -d /usr/local/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/local/include/$cf_ncuhdr_root"
8227 test -d /usr/local/include/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/local/include/$cf_ncuhdr_root/include"
8228 test -d /usr/local/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/local/$cf_ncuhdr_root/include"
8229 test -d /usr/local/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/local/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
8232 test "/opt" != "$prefix" && \
8234 (test $prefix = NONE || test "/opt" != "$prefix") && {
8235 test -n "$verbose" && echo " ... testing for include-directories under /opt"
8236 test -d /opt/include && cf_search="$cf_search /opt/include"
8237 test -d /opt/include/$cf_ncuhdr_root && cf_search="$cf_search /opt/include/$cf_ncuhdr_root"
8238 test -d /opt/include/$cf_ncuhdr_root/include && cf_search="$cf_search /opt/include/$cf_ncuhdr_root/include"
8239 test -d /opt/$cf_ncuhdr_root/include && cf_search="$cf_search /opt/$cf_ncuhdr_root/include"
8240 test -d /opt/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /opt/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
8243 test "$HOME" != "$prefix" && \
8244 test -d "$HOME" && \
8245 (test $prefix = NONE || test "$HOME" != "$prefix") && {
8246 test -n "$verbose" && echo " ... testing for include-directories under $HOME"
8247 test -d $HOME/include && cf_search="$cf_search $HOME/include"
8248 test -d $HOME/include/$cf_ncuhdr_root && cf_search="$cf_search $HOME/include/$cf_ncuhdr_root"
8249 test -d $HOME/include/$cf_ncuhdr_root/include && cf_search="$cf_search $HOME/include/$cf_ncuhdr_root/include"
8250 test -d $HOME/$cf_ncuhdr_root/include && cf_search="$cf_search $HOME/$cf_ncuhdr_root/include"
8251 test -d $HOME/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $HOME/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
8254 test "$includedir" != NONE && \
8255 test "$includedir" != "/usr/include" && \
8256 test -d "$includedir" && {
8257 test -d $includedir && cf_search="$cf_search $includedir"
8258 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
8261 test "$oldincludedir" != NONE && \
8262 test "$oldincludedir" != "/usr/include" && \
8263 test -d "$oldincludedir" && {
8264 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
8265 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
8268 cf_search="$cf_search $cf_header_path_list"
8270 test -n "$verbose" && echo search path $cf_search
8271 cf_save2_CPPFLAGS="$CPPFLAGS"
8272 for cf_incdir in $cf_search
8275 if test -n "$cf_incdir" ; then
8276 for cf_add_incdir in $cf_incdir
8278 while test $cf_add_incdir != /usr/include
8280 if test -d $cf_add_incdir
8283 if test -n "$CFLAGS$CPPFLAGS" ; then
8284 # a loop is needed to ensure we can add subdirs of existing dirs
8285 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
8286 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
8287 cf_have_incdir=yes; break
8292 if test "$cf_have_incdir" = no ; then
8293 if test "$cf_add_incdir" = /usr/local/include ; then
8294 if test "$GCC" = yes
8296 cf_save_CPPFLAGS=$CPPFLAGS
8297 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8298 cat >conftest.$ac_ext <<_ACEOF
8299 #line 8299 "configure"
8300 #include "confdefs.h"
8310 rm -f conftest.$ac_objext
8311 if { (eval echo "$as_me:8311: \"$ac_compile\"") >&5
8312 (eval $ac_compile) 2>&5
8314 echo "$as_me:8314: \$? = $ac_status" >&5
8315 (exit $ac_status); } &&
8316 { ac_try='test -s conftest.$ac_objext'
8317 { (eval echo "$as_me:8317: \"$ac_try\"") >&5
8320 echo "$as_me:8320: \$? = $ac_status" >&5
8321 (exit $ac_status); }; }; then
8324 echo "$as_me: failed program was:" >&5
8325 cat conftest.$ac_ext >&5
8328 rm -f conftest.$ac_objext conftest.$ac_ext
8329 CPPFLAGS=$cf_save_CPPFLAGS
8334 if test "$cf_have_incdir" = no ; then
8335 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
8337 echo "${as_me:-configure}:8337: testing adding $cf_add_incdir to include-path ..." 1>&5
8339 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8341 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
8342 test "$cf_top_incdir" = "$cf_add_incdir" && break
8343 cf_add_incdir="$cf_top_incdir"
8357 cat >conftest.$ac_ext <<_ACEOF
8358 #line 8358 "configure"
8359 #include "confdefs.h"
8361 #include <$cf_header>
8366 #ifdef NCURSES_VERSION
8368 printf("%s\n", NCURSES_VERSION);
8381 rm -f conftest.$ac_objext
8382 if { (eval echo "$as_me:8382: \"$ac_compile\"") >&5
8383 (eval $ac_compile) 2>&5
8385 echo "$as_me:8385: \$? = $ac_status" >&5
8386 (exit $ac_status); } &&
8387 { ac_try='test -s conftest.$ac_objext'
8388 { (eval echo "$as_me:8388: \"$ac_try\"") >&5
8391 echo "$as_me:8391: \$? = $ac_status" >&5
8392 (exit $ac_status); }; }; then
8393 cf_cv_ncurses_h2=$cf_header
8396 echo "$as_me: failed program was:" >&5
8397 cat conftest.$ac_ext >&5
8400 rm -f conftest.$ac_objext conftest.$ac_ext
8402 if test "$cf_cv_ncurses_h2" != no ; then
8403 cf_cv_ncurses_h2=$cf_incdir/$cf_header
8404 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
8407 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
8409 CPPFLAGS="$cf_save2_CPPFLAGS"
8410 test "$cf_cv_ncurses_h2" != no && break
8412 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:8412: error: not found" >&5
8413 echo "$as_me: error: not found" >&2;}
8414 { (exit 1); exit 1; }; }
8417 echo "$as_me:8417: result: $cf_cv_ncurses_h2" >&5
8418 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
8420 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
8421 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
8422 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
8423 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
8426 if test -n "$cf_1st_incdir" ; then
8427 for cf_add_incdir in $cf_1st_incdir
8429 while test $cf_add_incdir != /usr/include
8431 if test -d $cf_add_incdir
8434 if test -n "$CFLAGS$CPPFLAGS" ; then
8435 # a loop is needed to ensure we can add subdirs of existing dirs
8436 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
8437 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
8438 cf_have_incdir=yes; break
8443 if test "$cf_have_incdir" = no ; then
8444 if test "$cf_add_incdir" = /usr/local/include ; then
8445 if test "$GCC" = yes
8447 cf_save_CPPFLAGS=$CPPFLAGS
8448 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8449 cat >conftest.$ac_ext <<_ACEOF
8450 #line 8450 "configure"
8451 #include "confdefs.h"
8461 rm -f conftest.$ac_objext
8462 if { (eval echo "$as_me:8462: \"$ac_compile\"") >&5
8463 (eval $ac_compile) 2>&5
8465 echo "$as_me:8465: \$? = $ac_status" >&5
8466 (exit $ac_status); } &&
8467 { ac_try='test -s conftest.$ac_objext'
8468 { (eval echo "$as_me:8468: \"$ac_try\"") >&5
8471 echo "$as_me:8471: \$? = $ac_status" >&5
8472 (exit $ac_status); }; }; then
8475 echo "$as_me: failed program was:" >&5
8476 cat conftest.$ac_ext >&5
8479 rm -f conftest.$ac_objext conftest.$ac_ext
8480 CPPFLAGS=$cf_save_CPPFLAGS
8485 if test "$cf_have_incdir" = no ; then
8486 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
8488 echo "${as_me:-configure}:8488: testing adding $cf_add_incdir to include-path ..." 1>&5
8490 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8492 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
8493 test "$cf_top_incdir" = "$cf_add_incdir" && break
8494 cf_add_incdir="$cf_top_incdir"
8505 # Set definitions to allow ifdef'ing for ncurses.h
8507 case $cf_cv_ncurses_header in # (vi
8509 cat >>confdefs.h <<\EOF
8510 #define HAVE_NCURSES_H 1
8516 case $cf_cv_ncurses_header in # (vi
8517 ncurses/curses.h|ncurses/ncurses.h)
8518 cat >>confdefs.h <<\EOF
8519 #define HAVE_NCURSES_NCURSES_H 1
8523 ncursesw/curses.h|ncursesw/ncurses.h)
8524 cat >>confdefs.h <<\EOF
8525 #define HAVE_NCURSESW_NCURSES_H 1
8531 echo "$as_me:8531: checking for terminfo header" >&5
8532 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
8533 if test "${cf_cv_term_header+set}" = set; then
8534 echo $ECHO_N "(cached) $ECHO_C" >&6
8537 case ${cf_cv_ncurses_header} in #(vi
8538 */ncurses.h|*/ncursesw.h) #(vi
8539 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
8542 cf_term_header=term.h
8546 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
8548 cat >conftest.$ac_ext <<_ACEOF
8549 #line 8549 "configure"
8550 #include "confdefs.h"
8552 #include <${cf_cv_ncurses_header:-curses.h}>
8558 int x = auto_left_margin
8563 rm -f conftest.$ac_objext
8564 if { (eval echo "$as_me:8564: \"$ac_compile\"") >&5
8565 (eval $ac_compile) 2>&5
8567 echo "$as_me:8567: \$? = $ac_status" >&5
8568 (exit $ac_status); } &&
8569 { ac_try='test -s conftest.$ac_objext'
8570 { (eval echo "$as_me:8570: \"$ac_try\"") >&5
8573 echo "$as_me:8573: \$? = $ac_status" >&5
8574 (exit $ac_status); }; }; then
8576 cf_cv_term_header="$cf_test"
8578 echo "$as_me: failed program was:" >&5
8579 cat conftest.$ac_ext >&5
8581 cf_cv_term_header=unknown
8584 rm -f conftest.$ac_objext conftest.$ac_ext
8585 test "$cf_cv_term_header" != unknown && break
8589 echo "$as_me:8589: result: $cf_cv_term_header" >&5
8590 echo "${ECHO_T}$cf_cv_term_header" >&6
8592 # Set definitions to allow ifdef'ing to accommodate subdirectories
8594 case $cf_cv_term_header in # (vi
8596 cat >>confdefs.h <<\EOF
8597 #define HAVE_TERM_H 1
8603 case $cf_cv_term_header in # (vi
8604 ncurses/term.h) #(vi
8605 cat >>confdefs.h <<\EOF
8606 #define HAVE_NCURSES_TERM_H 1
8611 cat >>confdefs.h <<\EOF
8612 #define HAVE_NCURSESW_TERM_H 1
8618 # some applications need this, but should check for NCURSES_VERSION
8619 cat >>confdefs.h <<\EOF
8623 echo "$as_me:8623: checking for ncurses version" >&5
8624 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
8625 if test "${cf_cv_ncurses_version+set}" = set; then
8626 echo $ECHO_N "(cached) $ECHO_C" >&6
8629 cf_cv_ncurses_version=no
8632 if test "$cross_compiling" = yes; then
8634 # This will not work if the preprocessor splits the line after the
8635 # Autoconf token. The 'unproto' program does that.
8636 cat > conftest.$ac_ext <<EOF
8637 #include <${cf_cv_ncurses_header:-curses.h}>
8639 #ifdef NCURSES_VERSION
8640 Autoconf NCURSES_VERSION
8648 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
8649 { (eval echo "$as_me:8649: \"$cf_try\"") >&5
8652 echo "$as_me:8652: \$? = $ac_status" >&5
8653 (exit $ac_status); }
8654 if test -f conftest.out ; then
8655 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
8656 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
8661 cat >conftest.$ac_ext <<_ACEOF
8662 #line 8662 "configure"
8663 #include "confdefs.h"
8665 #include <${cf_cv_ncurses_header:-curses.h}>
8669 FILE *fp = fopen("$cf_tempfile", "w");
8670 #ifdef NCURSES_VERSION
8671 # ifdef NCURSES_VERSION_PATCH
8672 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
8674 fprintf(fp, "%s\n", NCURSES_VERSION);
8678 fprintf(fp, "old\n");
8683 ${cf_cv_main_return:-return}(0);
8686 rm -f conftest$ac_exeext
8687 if { (eval echo "$as_me:8687: \"$ac_link\"") >&5
8688 (eval $ac_link) 2>&5
8690 echo "$as_me:8690: \$? = $ac_status" >&5
8691 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
8692 { (eval echo "$as_me:8692: \"$ac_try\"") >&5
8695 echo "$as_me:8695: \$? = $ac_status" >&5
8696 (exit $ac_status); }; }; then
8698 cf_cv_ncurses_version=`cat $cf_tempfile`
8700 echo "$as_me: program exited with status $ac_status" >&5
8701 echo "$as_me: failed program was:" >&5
8702 cat conftest.$ac_ext >&5
8704 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
8709 echo "$as_me:8709: result: $cf_cv_ncurses_version" >&5
8710 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
8711 test "$cf_cv_ncurses_version" = no || cat >>confdefs.h <<\EOF
8715 cf_nculib_root=ncursesw
8716 # This works, except for the special case where we find gpm, but
8717 # ncurses is in a nonstandard location via $LIBS, and we really want
8720 cf_ncurses_SAVE="$LIBS"
8721 echo "$as_me:8721: checking for Gpm_Open in -lgpm" >&5
8722 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
8723 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
8724 echo $ECHO_N "(cached) $ECHO_C" >&6
8726 ac_check_lib_save_LIBS=$LIBS
8728 cat >conftest.$ac_ext <<_ACEOF
8729 #line 8729 "configure"
8730 #include "confdefs.h"
8732 /* Override any gcc2 internal prototype to avoid an error. */
8736 /* We use char because int might match the return type of a gcc2
8737 builtin and then its argument prototype would still apply. */
8747 rm -f conftest.$ac_objext conftest$ac_exeext
8748 if { (eval echo "$as_me:8748: \"$ac_link\"") >&5
8749 (eval $ac_link) 2>&5
8751 echo "$as_me:8751: \$? = $ac_status" >&5
8752 (exit $ac_status); } &&
8753 { ac_try='test -s conftest$ac_exeext'
8754 { (eval echo "$as_me:8754: \"$ac_try\"") >&5
8757 echo "$as_me:8757: \$? = $ac_status" >&5
8758 (exit $ac_status); }; }; then
8759 ac_cv_lib_gpm_Gpm_Open=yes
8761 echo "$as_me: failed program was:" >&5
8762 cat conftest.$ac_ext >&5
8763 ac_cv_lib_gpm_Gpm_Open=no
8765 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8766 LIBS=$ac_check_lib_save_LIBS
8768 echo "$as_me:8768: result: $ac_cv_lib_gpm_Gpm_Open" >&5
8769 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
8770 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
8771 echo "$as_me:8771: checking for initscr in -lgpm" >&5
8772 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
8773 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
8774 echo $ECHO_N "(cached) $ECHO_C" >&6
8776 ac_check_lib_save_LIBS=$LIBS
8778 cat >conftest.$ac_ext <<_ACEOF
8779 #line 8779 "configure"
8780 #include "confdefs.h"
8782 /* Override any gcc2 internal prototype to avoid an error. */
8786 /* We use char because int might match the return type of a gcc2
8787 builtin and then its argument prototype would still apply. */
8797 rm -f conftest.$ac_objext conftest$ac_exeext
8798 if { (eval echo "$as_me:8798: \"$ac_link\"") >&5
8799 (eval $ac_link) 2>&5
8801 echo "$as_me:8801: \$? = $ac_status" >&5
8802 (exit $ac_status); } &&
8803 { ac_try='test -s conftest$ac_exeext'
8804 { (eval echo "$as_me:8804: \"$ac_try\"") >&5
8807 echo "$as_me:8807: \$? = $ac_status" >&5
8808 (exit $ac_status); }; }; then
8809 ac_cv_lib_gpm_initscr=yes
8811 echo "$as_me: failed program was:" >&5
8812 cat conftest.$ac_ext >&5
8813 ac_cv_lib_gpm_initscr=no
8815 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8816 LIBS=$ac_check_lib_save_LIBS
8818 echo "$as_me:8818: result: $ac_cv_lib_gpm_initscr" >&5
8819 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
8820 if test $ac_cv_lib_gpm_initscr = yes; then
8821 LIBS="$cf_ncurses_SAVE"
8823 cf_ncurses_LIBS="-lgpm"
8828 case $host_os in #(vi
8830 # This is only necessary if you are linking against an obsolete
8831 # version of ncurses (but it should do no harm, since it's static).
8832 if test "$cf_nculib_root" = ncurses ; then
8833 echo "$as_me:8833: checking for tgoto in -lmytinfo" >&5
8834 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
8835 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
8836 echo $ECHO_N "(cached) $ECHO_C" >&6
8838 ac_check_lib_save_LIBS=$LIBS
8839 LIBS="-lmytinfo $LIBS"
8840 cat >conftest.$ac_ext <<_ACEOF
8841 #line 8841 "configure"
8842 #include "confdefs.h"
8844 /* Override any gcc2 internal prototype to avoid an error. */
8848 /* We use char because int might match the return type of a gcc2
8849 builtin and then its argument prototype would still apply. */
8859 rm -f conftest.$ac_objext conftest$ac_exeext
8860 if { (eval echo "$as_me:8860: \"$ac_link\"") >&5
8861 (eval $ac_link) 2>&5
8863 echo "$as_me:8863: \$? = $ac_status" >&5
8864 (exit $ac_status); } &&
8865 { ac_try='test -s conftest$ac_exeext'
8866 { (eval echo "$as_me:8866: \"$ac_try\"") >&5
8869 echo "$as_me:8869: \$? = $ac_status" >&5
8870 (exit $ac_status); }; }; then
8871 ac_cv_lib_mytinfo_tgoto=yes
8873 echo "$as_me: failed program was:" >&5
8874 cat conftest.$ac_ext >&5
8875 ac_cv_lib_mytinfo_tgoto=no
8877 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8878 LIBS=$ac_check_lib_save_LIBS
8880 echo "$as_me:8880: result: $ac_cv_lib_mytinfo_tgoto" >&5
8881 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
8882 if test $ac_cv_lib_mytinfo_tgoto = yes; then
8883 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
8890 LIBS="$cf_ncurses_LIBS $LIBS"
8892 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
8894 LIBS="-l$cf_nculib_root $LIBS"
8897 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
8899 echo "$as_me:8899: checking for initscr" >&5
8900 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
8901 if test "${ac_cv_func_initscr+set}" = set; then
8902 echo $ECHO_N "(cached) $ECHO_C" >&6
8904 cat >conftest.$ac_ext <<_ACEOF
8905 #line 8905 "configure"
8906 #include "confdefs.h"
8907 /* System header to define __stub macros and hopefully few prototypes,
8908 which can conflict with char initscr (); below. */
8910 /* Override any gcc2 internal prototype to avoid an error. */
8914 /* We use char because int might match the return type of a gcc2
8915 builtin and then its argument prototype would still apply. */
8922 /* The GNU C library defines this for functions which it implements
8923 to always fail with ENOSYS. Some functions are actually named
8924 something starting with __ and the normal name is an alias. */
8925 #if defined (__stub_initscr) || defined (__stub___initscr)
8935 rm -f conftest.$ac_objext conftest$ac_exeext
8936 if { (eval echo "$as_me:8936: \"$ac_link\"") >&5
8937 (eval $ac_link) 2>&5
8939 echo "$as_me:8939: \$? = $ac_status" >&5
8940 (exit $ac_status); } &&
8941 { ac_try='test -s conftest$ac_exeext'
8942 { (eval echo "$as_me:8942: \"$ac_try\"") >&5
8945 echo "$as_me:8945: \$? = $ac_status" >&5
8946 (exit $ac_status); }; }; then
8947 ac_cv_func_initscr=yes
8949 echo "$as_me: failed program was:" >&5
8950 cat conftest.$ac_ext >&5
8951 ac_cv_func_initscr=no
8953 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8955 echo "$as_me:8955: result: $ac_cv_func_initscr" >&5
8956 echo "${ECHO_T}$ac_cv_func_initscr" >&6
8957 if test $ac_cv_func_initscr = yes; then
8958 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
8961 cf_save_LIBS="$LIBS"
8962 echo "$as_me:8962: checking for initscr in -l$cf_nculib_root" >&5
8963 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
8964 LIBS="-l$cf_nculib_root $LIBS"
8965 cat >conftest.$ac_ext <<_ACEOF
8966 #line 8966 "configure"
8967 #include "confdefs.h"
8968 #include <${cf_cv_ncurses_header:-curses.h}>
8977 rm -f conftest.$ac_objext conftest$ac_exeext
8978 if { (eval echo "$as_me:8978: \"$ac_link\"") >&5
8979 (eval $ac_link) 2>&5
8981 echo "$as_me:8981: \$? = $ac_status" >&5
8982 (exit $ac_status); } &&
8983 { ac_try='test -s conftest$ac_exeext'
8984 { (eval echo "$as_me:8984: \"$ac_try\"") >&5
8987 echo "$as_me:8987: \$? = $ac_status" >&5
8988 (exit $ac_status); }; }; then
8989 echo "$as_me:8989: result: yes" >&5
8990 echo "${ECHO_T}yes" >&6
8991 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
8994 echo "$as_me: failed program was:" >&5
8995 cat conftest.$ac_ext >&5
8996 echo "$as_me:8996: result: no" >&5
8997 echo "${ECHO_T}no" >&6
9000 cf_library_path_list=""
9001 if test -n "${LDFLAGS}${LIBS}" ; then
9002 for cf_library_path in $LDFLAGS $LIBS
9004 case $cf_library_path in #(vi
9006 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
9008 test "$cf_library_path" != "NONE" && \
9009 test -d "$cf_library_path" && \
9011 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
9012 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
9013 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
9014 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
9015 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
9016 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"
9019 cf_library_path_list="$cf_library_path_list $cf_search"
9027 test "/usr" != "$prefix" && \
9029 (test $prefix = NONE || test "/usr" != "$prefix") && {
9030 test -n "$verbose" && echo " ... testing for lib-directories under /usr"
9031 test -d /usr/lib && cf_search="$cf_search /usr/lib"
9032 test -d /usr/lib/$cf_nculib_root && cf_search="$cf_search /usr/lib/$cf_nculib_root"
9033 test -d /usr/lib/$cf_nculib_root/lib && cf_search="$cf_search /usr/lib/$cf_nculib_root/lib"
9034 test -d /usr/$cf_nculib_root/lib && cf_search="$cf_search /usr/$cf_nculib_root/lib"
9035 test -d /usr/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /usr/$cf_nculib_root/lib/$cf_nculib_root"
9038 test "$prefix" != "NONE" && \
9039 test -d "$prefix" && \
9041 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
9042 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
9043 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
9044 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
9045 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
9046 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
9049 test "/usr/local" != "$prefix" && \
9050 test -d "/usr/local" && \
9051 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
9052 test -n "$verbose" && echo " ... testing for lib-directories under /usr/local"
9053 test -d /usr/local/lib && cf_search="$cf_search /usr/local/lib"
9054 test -d /usr/local/lib/$cf_nculib_root && cf_search="$cf_search /usr/local/lib/$cf_nculib_root"
9055 test -d /usr/local/lib/$cf_nculib_root/lib && cf_search="$cf_search /usr/local/lib/$cf_nculib_root/lib"
9056 test -d /usr/local/$cf_nculib_root/lib && cf_search="$cf_search /usr/local/$cf_nculib_root/lib"
9057 test -d /usr/local/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /usr/local/$cf_nculib_root/lib/$cf_nculib_root"
9060 test "/opt" != "$prefix" && \
9062 (test $prefix = NONE || test "/opt" != "$prefix") && {
9063 test -n "$verbose" && echo " ... testing for lib-directories under /opt"
9064 test -d /opt/lib && cf_search="$cf_search /opt/lib"
9065 test -d /opt/lib/$cf_nculib_root && cf_search="$cf_search /opt/lib/$cf_nculib_root"
9066 test -d /opt/lib/$cf_nculib_root/lib && cf_search="$cf_search /opt/lib/$cf_nculib_root/lib"
9067 test -d /opt/$cf_nculib_root/lib && cf_search="$cf_search /opt/$cf_nculib_root/lib"
9068 test -d /opt/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /opt/$cf_nculib_root/lib/$cf_nculib_root"
9071 test "$HOME" != "$prefix" && \
9072 test -d "$HOME" && \
9073 (test $prefix = NONE || test "$HOME" != "$prefix") && {
9074 test -n "$verbose" && echo " ... testing for lib-directories under $HOME"
9075 test -d $HOME/lib && cf_search="$cf_search $HOME/lib"
9076 test -d $HOME/lib/$cf_nculib_root && cf_search="$cf_search $HOME/lib/$cf_nculib_root"
9077 test -d $HOME/lib/$cf_nculib_root/lib && cf_search="$cf_search $HOME/lib/$cf_nculib_root/lib"
9078 test -d $HOME/$cf_nculib_root/lib && cf_search="$cf_search $HOME/$cf_nculib_root/lib"
9079 test -d $HOME/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $HOME/$cf_nculib_root/lib/$cf_nculib_root"
9082 cf_search="$cf_library_path_list $cf_search"
9084 for cf_libdir in $cf_search
9086 echo "$as_me:9086: checking for -l$cf_nculib_root in $cf_libdir" >&5
9087 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
9088 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
9089 cat >conftest.$ac_ext <<_ACEOF
9090 #line 9090 "configure"
9091 #include "confdefs.h"
9092 #include <${cf_cv_ncurses_header:-curses.h}>
9101 rm -f conftest.$ac_objext conftest$ac_exeext
9102 if { (eval echo "$as_me:9102: \"$ac_link\"") >&5
9103 (eval $ac_link) 2>&5
9105 echo "$as_me:9105: \$? = $ac_status" >&5
9106 (exit $ac_status); } &&
9107 { ac_try='test -s conftest$ac_exeext'
9108 { (eval echo "$as_me:9108: \"$ac_try\"") >&5
9111 echo "$as_me:9111: \$? = $ac_status" >&5
9112 (exit $ac_status); }; }; then
9113 echo "$as_me:9113: result: yes" >&5
9114 echo "${ECHO_T}yes" >&6
9115 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
9118 echo "$as_me: failed program was:" >&5
9119 cat conftest.$ac_ext >&5
9120 echo "$as_me:9120: result: no" >&5
9121 echo "${ECHO_T}no" >&6
9122 LIBS="$cf_save_LIBS"
9124 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9128 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9132 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
9134 if test $cf_found_library = no ; then
9135 { { echo "$as_me:9135: error: Cannot link $cf_nculib_root library" >&5
9136 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
9137 { (exit 1); exit 1; }; }
9142 if test -n "$cf_ncurses_LIBS" ; then
9143 echo "$as_me:9143: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
9144 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
9145 cf_ncurses_SAVE="$LIBS"
9146 for p in $cf_ncurses_LIBS ; do
9147 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
9148 if test "$q" != "$LIBS" ; then
9152 cat >conftest.$ac_ext <<_ACEOF
9153 #line 9153 "configure"
9154 #include "confdefs.h"
9155 #include <${cf_cv_ncurses_header:-curses.h}>
9159 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
9164 rm -f conftest.$ac_objext conftest$ac_exeext
9165 if { (eval echo "$as_me:9165: \"$ac_link\"") >&5
9166 (eval $ac_link) 2>&5
9168 echo "$as_me:9168: \$? = $ac_status" >&5
9169 (exit $ac_status); } &&
9170 { ac_try='test -s conftest$ac_exeext'
9171 { (eval echo "$as_me:9171: \"$ac_try\"") >&5
9174 echo "$as_me:9174: \$? = $ac_status" >&5
9175 (exit $ac_status); }; }; then
9176 echo "$as_me:9176: result: yes" >&5
9177 echo "${ECHO_T}yes" >&6
9179 echo "$as_me: failed program was:" >&5
9180 cat conftest.$ac_ext >&5
9181 echo "$as_me:9181: result: no" >&5
9182 echo "${ECHO_T}no" >&6
9183 LIBS="$cf_ncurses_SAVE"
9185 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9188 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
9190 cat >>confdefs.h <<EOF
9191 #define $cf_nculib_ROOT 1
9199 echo "$as_me:9199: checking if you want to use pkg-config" >&5
9200 echo $ECHO_N "checking if you want to use pkg-config... $ECHO_C" >&6
9202 # Check whether --with-pkg-config or --without-pkg-config was given.
9203 if test "${with_pkg_config+set}" = set; then
9204 withval="$with_pkg_config"
9205 cf_pkg_config=$withval
9209 echo "$as_me:9209: result: $cf_pkg_config" >&5
9210 echo "${ECHO_T}$cf_pkg_config" >&6
9212 case $cf_pkg_config in #(vi
9217 if test -n "$ac_tool_prefix"; then
9218 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
9219 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
9220 echo "$as_me:9220: checking for $ac_word" >&5
9221 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
9222 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then
9223 echo $ECHO_N "(cached) $ECHO_C" >&6
9227 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
9230 ac_save_IFS=$IFS; IFS=$ac_path_separator
9232 for ac_dir in $ac_dummy; do
9234 test -z "$ac_dir" && ac_dir=.
9235 if $as_executable_p "$ac_dir/$ac_word"; then
9236 ac_cv_path_PKG_CONFIG="$ac_dir/$ac_word"
9237 echo "$as_me:9237: found $ac_dir/$ac_word" >&5
9245 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
9247 if test -n "$PKG_CONFIG"; then
9248 echo "$as_me:9248: result: $PKG_CONFIG" >&5
9249 echo "${ECHO_T}$PKG_CONFIG" >&6
9251 echo "$as_me:9251: result: no" >&5
9252 echo "${ECHO_T}no" >&6
9256 if test -z "$ac_cv_path_PKG_CONFIG"; then
9257 ac_pt_PKG_CONFIG=$PKG_CONFIG
9258 # Extract the first word of "pkg-config", so it can be a program name with args.
9259 set dummy pkg-config; ac_word=$2
9260 echo "$as_me:9260: checking for $ac_word" >&5
9261 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
9262 if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then
9263 echo $ECHO_N "(cached) $ECHO_C" >&6
9265 case $ac_pt_PKG_CONFIG in
9267 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
9270 ac_save_IFS=$IFS; IFS=$ac_path_separator
9272 for ac_dir in $ac_dummy; do
9274 test -z "$ac_dir" && ac_dir=.
9275 if $as_executable_p "$ac_dir/$ac_word"; then
9276 ac_cv_path_ac_pt_PKG_CONFIG="$ac_dir/$ac_word"
9277 echo "$as_me:9277: found $ac_dir/$ac_word" >&5
9282 test -z "$ac_cv_path_ac_pt_PKG_CONFIG" && ac_cv_path_ac_pt_PKG_CONFIG="none"
9286 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
9288 if test -n "$ac_pt_PKG_CONFIG"; then
9289 echo "$as_me:9289: result: $ac_pt_PKG_CONFIG" >&5
9290 echo "${ECHO_T}$ac_pt_PKG_CONFIG" >&6
9292 echo "$as_me:9292: result: no" >&5
9293 echo "${ECHO_T}no" >&6
9296 PKG_CONFIG=$ac_pt_PKG_CONFIG
9298 PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
9307 test -z "$PKG_CONFIG" && PKG_CONFIG=none
9308 if test "$PKG_CONFIG" != none ; then
9310 if test "x$prefix" != xNONE; then
9311 cf_path_syntax="$prefix"
9313 cf_path_syntax="$ac_default_prefix"
9316 case ".$PKG_CONFIG" in #(vi
9317 .\$\(*\)*|.\'*\'*) #(vi
9321 .[a-zA-Z]:[\\/]*) #(vi OS/2 EMX
9324 eval PKG_CONFIG="$PKG_CONFIG"
9325 case ".$PKG_CONFIG" in #(vi
9327 PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
9332 PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
9335 { { echo "$as_me:9335: error: expected a pathname, not \"$PKG_CONFIG\"" >&5
9336 echo "$as_me: error: expected a pathname, not \"$PKG_CONFIG\"" >&2;}
9337 { (exit 1); exit 1; }; }
9343 echo "$as_me:9343: checking for X" >&5
9344 echo $ECHO_N "checking for X... $ECHO_C" >&6
9346 # Check whether --with-x or --without-x was given.
9347 if test "${with_x+set}" = set; then
9351 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
9352 if test "x$with_x" = xno; then
9353 # The user explicitly disabled X.
9356 if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
9357 # Both variables are already set.
9360 if test "${ac_cv_have_x+set}" = set; then
9361 echo $ECHO_N "(cached) $ECHO_C" >&6
9363 # One or both of the vars are not set, and there is no cached value.
9364 ac_x_includes=no ac_x_libraries=no
9366 if mkdir conftest.dir; then
9368 # Make sure to not put "make" in the Imakefile rules, since we grep it out.
9369 cat >Imakefile <<'EOF'
9371 @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
9373 if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
9374 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
9375 eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
9376 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
9377 for ac_extension in a so sl dylib dll; do
9378 if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
9379 test -f $ac_im_libdir/libX11.$ac_extension; then
9380 ac_im_usrlibdir=$ac_im_libdir; break
9383 # Screen out bogus values from the imake configuration. They are
9384 # bogus both because they are the default anyway, and because
9385 # using them would break gcc on systems where it needs fixed includes.
9386 case $ac_im_incroot in
9388 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
9390 case $ac_im_usrlibdir in
9392 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
9399 # Standard set of common directories for X headers.
9400 # Check X11 before X11Rn because it is often a symlink to the current release.
9412 /usr/local/X11/include
9413 /usr/local/X11R6/include
9414 /usr/local/X11R5/include
9415 /usr/local/X11R4/include
9417 /usr/local/include/X11
9418 /usr/local/include/X11R6
9419 /usr/local/include/X11R5
9420 /usr/local/include/X11R4
9424 /usr/XFree86/include/X11
9428 /usr/unsupported/include
9430 /usr/local/x11r5/include
9431 /usr/lpp/Xamples/include
9433 /usr/openwin/include
9434 /usr/openwin/share/include'
9436 if test "$ac_x_includes" = no; then
9437 # Guess where to find include files, by looking for Intrinsic.h.
9438 # First, try using that file with no special directory specified.
9439 cat >conftest.$ac_ext <<_ACEOF
9440 #line 9440 "configure"
9441 #include "confdefs.h"
9442 #include <X11/Intrinsic.h>
9444 if { (eval echo "$as_me:9444: \"$ac_cpp conftest.$ac_ext\"") >&5
9445 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9447 egrep -v '^ *\+' conftest.er1 >conftest.err
9449 cat conftest.err >&5
9450 echo "$as_me:9450: \$? = $ac_status" >&5
9451 (exit $ac_status); } >/dev/null; then
9452 if test -s conftest.err; then
9453 ac_cpp_err=$ac_c_preproc_warn_flag
9460 if test -z "$ac_cpp_err"; then
9461 # We can compile using X headers with no special include directory.
9464 echo "$as_me: failed program was:" >&5
9465 cat conftest.$ac_ext >&5
9466 for ac_dir in $ac_x_header_dirs; do
9467 if test -r "$ac_dir/X11/Intrinsic.h"; then
9468 ac_x_includes=$ac_dir
9473 rm -f conftest.err conftest.$ac_ext
9474 fi # $ac_x_includes = no
9476 if test "$ac_x_libraries" = no; then
9477 # Check for the libraries.
9478 # See if we find them without any special options.
9479 # Don't add to $LIBS permanently.
9482 cat >conftest.$ac_ext <<_ACEOF
9483 #line 9483 "configure"
9484 #include "confdefs.h"
9485 #include <X11/Intrinsic.h>
9494 rm -f conftest.$ac_objext conftest$ac_exeext
9495 if { (eval echo "$as_me:9495: \"$ac_link\"") >&5
9496 (eval $ac_link) 2>&5
9498 echo "$as_me:9498: \$? = $ac_status" >&5
9499 (exit $ac_status); } &&
9500 { ac_try='test -s conftest$ac_exeext'
9501 { (eval echo "$as_me:9501: \"$ac_try\"") >&5
9504 echo "$as_me:9504: \$? = $ac_status" >&5
9505 (exit $ac_status); }; }; then
9507 # We can link X programs with no special library path.
9510 echo "$as_me: failed program was:" >&5
9511 cat conftest.$ac_ext >&5
9513 for ac_dir in `echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
9515 # Don't even attempt the hair of trying to link an X program!
9516 for ac_extension in a so sl dylib dll; do
9517 if test -r $ac_dir/libXt.$ac_extension; then
9518 ac_x_libraries=$ac_dir
9524 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9525 fi # $ac_x_libraries = no
9527 if test "$ac_x_includes" = no || test "$ac_x_libraries" = no; then
9528 # Didn't find X anywhere. Cache the known absence of X.
9529 ac_cv_have_x="have_x=no"
9531 # Record where we found X for the cache.
9532 ac_cv_have_x="have_x=yes \
9533 ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
9538 eval "$ac_cv_have_x"
9541 if test "$have_x" != yes; then
9542 echo "$as_me:9542: result: $have_x" >&5
9543 echo "${ECHO_T}$have_x" >&6
9546 # If each of the values was on the command line, it overrides each guess.
9547 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
9548 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
9549 # Update the cache value to reflect the command line values.
9550 ac_cv_have_x="have_x=yes \
9551 ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
9552 echo "$as_me:9552: result: libraries $x_libraries, headers $x_includes" >&5
9553 echo "${ECHO_T}libraries $x_libraries, headers $x_includes" >&6
9556 if test "$no_x" = yes; then
9557 # Not all programs may use this symbol, but it does not hurt to define it.
9559 cat >>confdefs.h <<\EOF
9560 #define X_DISPLAY_MISSING 1
9563 X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS=
9565 if test -n "$x_includes"; then
9566 X_CFLAGS="$X_CFLAGS -I$x_includes"
9569 # It would also be nice to do this for all -L options, not just this one.
9570 if test -n "$x_libraries"; then
9571 X_LIBS="$X_LIBS -L$x_libraries"
9572 # For Solaris; some versions of Sun CC require a space after -R and
9573 # others require no space. Words are not sufficient . . . .
9574 case `(uname -sr) 2>/dev/null` in
9576 echo "$as_me:9576: checking whether -R must be followed by a space" >&5
9577 echo $ECHO_N "checking whether -R must be followed by a space... $ECHO_C" >&6
9578 ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries"
9579 cat >conftest.$ac_ext <<_ACEOF
9580 #line 9580 "configure"
9581 #include "confdefs.h"
9591 rm -f conftest.$ac_objext conftest$ac_exeext
9592 if { (eval echo "$as_me:9592: \"$ac_link\"") >&5
9593 (eval $ac_link) 2>&5
9595 echo "$as_me:9595: \$? = $ac_status" >&5
9596 (exit $ac_status); } &&
9597 { ac_try='test -s conftest$ac_exeext'
9598 { (eval echo "$as_me:9598: \"$ac_try\"") >&5
9601 echo "$as_me:9601: \$? = $ac_status" >&5
9602 (exit $ac_status); }; }; then
9605 echo "$as_me: failed program was:" >&5
9606 cat conftest.$ac_ext >&5
9609 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9610 if test $ac_R_nospace = yes; then
9611 echo "$as_me:9611: result: no" >&5
9612 echo "${ECHO_T}no" >&6
9613 X_LIBS="$X_LIBS -R$x_libraries"
9615 LIBS="$ac_xsave_LIBS -R $x_libraries"
9616 cat >conftest.$ac_ext <<_ACEOF
9617 #line 9617 "configure"
9618 #include "confdefs.h"
9628 rm -f conftest.$ac_objext conftest$ac_exeext
9629 if { (eval echo "$as_me:9629: \"$ac_link\"") >&5
9630 (eval $ac_link) 2>&5
9632 echo "$as_me:9632: \$? = $ac_status" >&5
9633 (exit $ac_status); } &&
9634 { ac_try='test -s conftest$ac_exeext'
9635 { (eval echo "$as_me:9635: \"$ac_try\"") >&5
9638 echo "$as_me:9638: \$? = $ac_status" >&5
9639 (exit $ac_status); }; }; then
9642 echo "$as_me: failed program was:" >&5
9643 cat conftest.$ac_ext >&5
9646 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9647 if test $ac_R_space = yes; then
9648 echo "$as_me:9648: result: yes" >&5
9649 echo "${ECHO_T}yes" >&6
9650 X_LIBS="$X_LIBS -R $x_libraries"
9652 echo "$as_me:9652: result: neither works" >&5
9653 echo "${ECHO_T}neither works" >&6
9660 # Check for system-dependent libraries X programs must link with.
9661 # Do this before checking for the system-independent R6 libraries
9662 # (-lICE), since we may need -lsocket or whatever for X linking.
9664 if test "$ISC" = yes; then
9665 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
9667 # Martyn Johnson says this is needed for Ultrix, if the X
9668 # libraries were built with DECnet support. And Karl Berry says
9669 # the Alpha needs dnet_stub (dnet does not exist).
9670 ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11"
9671 cat >conftest.$ac_ext <<_ACEOF
9672 #line 9672 "configure"
9673 #include "confdefs.h"
9675 /* Override any gcc2 internal prototype to avoid an error. */
9679 /* We use char because int might match the return type of a gcc2
9680 builtin and then its argument prototype would still apply. */
9681 char XOpenDisplay ();
9690 rm -f conftest.$ac_objext conftest$ac_exeext
9691 if { (eval echo "$as_me:9691: \"$ac_link\"") >&5
9692 (eval $ac_link) 2>&5
9694 echo "$as_me:9694: \$? = $ac_status" >&5
9695 (exit $ac_status); } &&
9696 { ac_try='test -s conftest$ac_exeext'
9697 { (eval echo "$as_me:9697: \"$ac_try\"") >&5
9700 echo "$as_me:9700: \$? = $ac_status" >&5
9701 (exit $ac_status); }; }; then
9704 echo "$as_me: failed program was:" >&5
9705 cat conftest.$ac_ext >&5
9706 echo "$as_me:9706: checking for dnet_ntoa in -ldnet" >&5
9707 echo $ECHO_N "checking for dnet_ntoa in -ldnet... $ECHO_C" >&6
9708 if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then
9709 echo $ECHO_N "(cached) $ECHO_C" >&6
9711 ac_check_lib_save_LIBS=$LIBS
9713 cat >conftest.$ac_ext <<_ACEOF
9714 #line 9714 "configure"
9715 #include "confdefs.h"
9717 /* Override any gcc2 internal prototype to avoid an error. */
9721 /* We use char because int might match the return type of a gcc2
9722 builtin and then its argument prototype would still apply. */
9732 rm -f conftest.$ac_objext conftest$ac_exeext
9733 if { (eval echo "$as_me:9733: \"$ac_link\"") >&5
9734 (eval $ac_link) 2>&5
9736 echo "$as_me:9736: \$? = $ac_status" >&5
9737 (exit $ac_status); } &&
9738 { ac_try='test -s conftest$ac_exeext'
9739 { (eval echo "$as_me:9739: \"$ac_try\"") >&5
9742 echo "$as_me:9742: \$? = $ac_status" >&5
9743 (exit $ac_status); }; }; then
9744 ac_cv_lib_dnet_dnet_ntoa=yes
9746 echo "$as_me: failed program was:" >&5
9747 cat conftest.$ac_ext >&5
9748 ac_cv_lib_dnet_dnet_ntoa=no
9750 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9751 LIBS=$ac_check_lib_save_LIBS
9753 echo "$as_me:9753: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
9754 echo "${ECHO_T}$ac_cv_lib_dnet_dnet_ntoa" >&6
9755 if test $ac_cv_lib_dnet_dnet_ntoa = yes; then
9756 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
9759 if test $ac_cv_lib_dnet_dnet_ntoa = no; then
9760 echo "$as_me:9760: checking for dnet_ntoa in -ldnet_stub" >&5
9761 echo $ECHO_N "checking for dnet_ntoa in -ldnet_stub... $ECHO_C" >&6
9762 if test "${ac_cv_lib_dnet_stub_dnet_ntoa+set}" = set; then
9763 echo $ECHO_N "(cached) $ECHO_C" >&6
9765 ac_check_lib_save_LIBS=$LIBS
9766 LIBS="-ldnet_stub $LIBS"
9767 cat >conftest.$ac_ext <<_ACEOF
9768 #line 9768 "configure"
9769 #include "confdefs.h"
9771 /* Override any gcc2 internal prototype to avoid an error. */
9775 /* We use char because int might match the return type of a gcc2
9776 builtin and then its argument prototype would still apply. */
9786 rm -f conftest.$ac_objext conftest$ac_exeext
9787 if { (eval echo "$as_me:9787: \"$ac_link\"") >&5
9788 (eval $ac_link) 2>&5
9790 echo "$as_me:9790: \$? = $ac_status" >&5
9791 (exit $ac_status); } &&
9792 { ac_try='test -s conftest$ac_exeext'
9793 { (eval echo "$as_me:9793: \"$ac_try\"") >&5
9796 echo "$as_me:9796: \$? = $ac_status" >&5
9797 (exit $ac_status); }; }; then
9798 ac_cv_lib_dnet_stub_dnet_ntoa=yes
9800 echo "$as_me: failed program was:" >&5
9801 cat conftest.$ac_ext >&5
9802 ac_cv_lib_dnet_stub_dnet_ntoa=no
9804 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9805 LIBS=$ac_check_lib_save_LIBS
9807 echo "$as_me:9807: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5
9808 echo "${ECHO_T}$ac_cv_lib_dnet_stub_dnet_ntoa" >&6
9809 if test $ac_cv_lib_dnet_stub_dnet_ntoa = yes; then
9810 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
9815 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9816 LIBS="$ac_xsave_LIBS"
9818 # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT,
9819 # to get the SysV transport functions.
9820 # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4)
9822 # The nsl library prevents programs from opening the X display
9823 # on Irix 5.2, according to T.E. Dickey.
9824 # The functions gethostbyname, getservbyname, and inet_addr are
9825 # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking.
9826 echo "$as_me:9826: checking for gethostbyname" >&5
9827 echo $ECHO_N "checking for gethostbyname... $ECHO_C" >&6
9828 if test "${ac_cv_func_gethostbyname+set}" = set; then
9829 echo $ECHO_N "(cached) $ECHO_C" >&6
9831 cat >conftest.$ac_ext <<_ACEOF
9832 #line 9832 "configure"
9833 #include "confdefs.h"
9834 /* System header to define __stub macros and hopefully few prototypes,
9835 which can conflict with char gethostbyname (); below. */
9837 /* Override any gcc2 internal prototype to avoid an error. */
9841 /* We use char because int might match the return type of a gcc2
9842 builtin and then its argument prototype would still apply. */
9843 char gethostbyname ();
9849 /* The GNU C library defines this for functions which it implements
9850 to always fail with ENOSYS. Some functions are actually named
9851 something starting with __ and the normal name is an alias. */
9852 #if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
9862 rm -f conftest.$ac_objext conftest$ac_exeext
9863 if { (eval echo "$as_me:9863: \"$ac_link\"") >&5
9864 (eval $ac_link) 2>&5
9866 echo "$as_me:9866: \$? = $ac_status" >&5
9867 (exit $ac_status); } &&
9868 { ac_try='test -s conftest$ac_exeext'
9869 { (eval echo "$as_me:9869: \"$ac_try\"") >&5
9872 echo "$as_me:9872: \$? = $ac_status" >&5
9873 (exit $ac_status); }; }; then
9874 ac_cv_func_gethostbyname=yes
9876 echo "$as_me: failed program was:" >&5
9877 cat conftest.$ac_ext >&5
9878 ac_cv_func_gethostbyname=no
9880 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9882 echo "$as_me:9882: result: $ac_cv_func_gethostbyname" >&5
9883 echo "${ECHO_T}$ac_cv_func_gethostbyname" >&6
9885 if test $ac_cv_func_gethostbyname = no; then
9886 echo "$as_me:9886: checking for gethostbyname in -lnsl" >&5
9887 echo $ECHO_N "checking for gethostbyname in -lnsl... $ECHO_C" >&6
9888 if test "${ac_cv_lib_nsl_gethostbyname+set}" = set; then
9889 echo $ECHO_N "(cached) $ECHO_C" >&6
9891 ac_check_lib_save_LIBS=$LIBS
9893 cat >conftest.$ac_ext <<_ACEOF
9894 #line 9894 "configure"
9895 #include "confdefs.h"
9897 /* Override any gcc2 internal prototype to avoid an error. */
9901 /* We use char because int might match the return type of a gcc2
9902 builtin and then its argument prototype would still apply. */
9903 char gethostbyname ();
9912 rm -f conftest.$ac_objext conftest$ac_exeext
9913 if { (eval echo "$as_me:9913: \"$ac_link\"") >&5
9914 (eval $ac_link) 2>&5
9916 echo "$as_me:9916: \$? = $ac_status" >&5
9917 (exit $ac_status); } &&
9918 { ac_try='test -s conftest$ac_exeext'
9919 { (eval echo "$as_me:9919: \"$ac_try\"") >&5
9922 echo "$as_me:9922: \$? = $ac_status" >&5
9923 (exit $ac_status); }; }; then
9924 ac_cv_lib_nsl_gethostbyname=yes
9926 echo "$as_me: failed program was:" >&5
9927 cat conftest.$ac_ext >&5
9928 ac_cv_lib_nsl_gethostbyname=no
9930 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9931 LIBS=$ac_check_lib_save_LIBS
9933 echo "$as_me:9933: result: $ac_cv_lib_nsl_gethostbyname" >&5
9934 echo "${ECHO_T}$ac_cv_lib_nsl_gethostbyname" >&6
9935 if test $ac_cv_lib_nsl_gethostbyname = yes; then
9936 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
9939 if test $ac_cv_lib_nsl_gethostbyname = no; then
9940 echo "$as_me:9940: checking for gethostbyname in -lbsd" >&5
9941 echo $ECHO_N "checking for gethostbyname in -lbsd... $ECHO_C" >&6
9942 if test "${ac_cv_lib_bsd_gethostbyname+set}" = set; then
9943 echo $ECHO_N "(cached) $ECHO_C" >&6
9945 ac_check_lib_save_LIBS=$LIBS
9947 cat >conftest.$ac_ext <<_ACEOF
9948 #line 9948 "configure"
9949 #include "confdefs.h"
9951 /* Override any gcc2 internal prototype to avoid an error. */
9955 /* We use char because int might match the return type of a gcc2
9956 builtin and then its argument prototype would still apply. */
9957 char gethostbyname ();
9966 rm -f conftest.$ac_objext conftest$ac_exeext
9967 if { (eval echo "$as_me:9967: \"$ac_link\"") >&5
9968 (eval $ac_link) 2>&5
9970 echo "$as_me:9970: \$? = $ac_status" >&5
9971 (exit $ac_status); } &&
9972 { ac_try='test -s conftest$ac_exeext'
9973 { (eval echo "$as_me:9973: \"$ac_try\"") >&5
9976 echo "$as_me:9976: \$? = $ac_status" >&5
9977 (exit $ac_status); }; }; then
9978 ac_cv_lib_bsd_gethostbyname=yes
9980 echo "$as_me: failed program was:" >&5
9981 cat conftest.$ac_ext >&5
9982 ac_cv_lib_bsd_gethostbyname=no
9984 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9985 LIBS=$ac_check_lib_save_LIBS
9987 echo "$as_me:9987: result: $ac_cv_lib_bsd_gethostbyname" >&5
9988 echo "${ECHO_T}$ac_cv_lib_bsd_gethostbyname" >&6
9989 if test $ac_cv_lib_bsd_gethostbyname = yes; then
9990 X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd"
9996 # lieder@skyler.mavd.honeywell.com says without -lsocket,
9997 # socket/setsockopt and other routines are undefined under SCO ODT
9998 # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary
9999 # on later versions), says Simon Leinen: it contains gethostby*
10000 # variants that don't use the nameserver (or something). -lsocket
10001 # must be given before -lnsl if both are needed. We assume that
10002 # if connect needs -lnsl, so does gethostbyname.
10003 echo "$as_me:10003: checking for connect" >&5
10004 echo $ECHO_N "checking for connect... $ECHO_C" >&6
10005 if test "${ac_cv_func_connect+set}" = set; then
10006 echo $ECHO_N "(cached) $ECHO_C" >&6
10008 cat >conftest.$ac_ext <<_ACEOF
10009 #line 10009 "configure"
10010 #include "confdefs.h"
10011 /* System header to define __stub macros and hopefully few prototypes,
10012 which can conflict with char connect (); below. */
10013 #include <assert.h>
10014 /* Override any gcc2 internal prototype to avoid an error. */
10018 /* We use char because int might match the return type of a gcc2
10019 builtin and then its argument prototype would still apply. */
10026 /* The GNU C library defines this for functions which it implements
10027 to always fail with ENOSYS. Some functions are actually named
10028 something starting with __ and the normal name is an alias. */
10029 #if defined (__stub_connect) || defined (__stub___connect)
10039 rm -f conftest.$ac_objext conftest$ac_exeext
10040 if { (eval echo "$as_me:10040: \"$ac_link\"") >&5
10041 (eval $ac_link) 2>&5
10043 echo "$as_me:10043: \$? = $ac_status" >&5
10044 (exit $ac_status); } &&
10045 { ac_try='test -s conftest$ac_exeext'
10046 { (eval echo "$as_me:10046: \"$ac_try\"") >&5
10047 (eval $ac_try) 2>&5
10049 echo "$as_me:10049: \$? = $ac_status" >&5
10050 (exit $ac_status); }; }; then
10051 ac_cv_func_connect=yes
10053 echo "$as_me: failed program was:" >&5
10054 cat conftest.$ac_ext >&5
10055 ac_cv_func_connect=no
10057 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10059 echo "$as_me:10059: result: $ac_cv_func_connect" >&5
10060 echo "${ECHO_T}$ac_cv_func_connect" >&6
10062 if test $ac_cv_func_connect = no; then
10063 echo "$as_me:10063: checking for connect in -lsocket" >&5
10064 echo $ECHO_N "checking for connect in -lsocket... $ECHO_C" >&6
10065 if test "${ac_cv_lib_socket_connect+set}" = set; then
10066 echo $ECHO_N "(cached) $ECHO_C" >&6
10068 ac_check_lib_save_LIBS=$LIBS
10069 LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
10070 cat >conftest.$ac_ext <<_ACEOF
10071 #line 10071 "configure"
10072 #include "confdefs.h"
10074 /* Override any gcc2 internal prototype to avoid an error. */
10078 /* We use char because int might match the return type of a gcc2
10079 builtin and then its argument prototype would still apply. */
10089 rm -f conftest.$ac_objext conftest$ac_exeext
10090 if { (eval echo "$as_me:10090: \"$ac_link\"") >&5
10091 (eval $ac_link) 2>&5
10093 echo "$as_me:10093: \$? = $ac_status" >&5
10094 (exit $ac_status); } &&
10095 { ac_try='test -s conftest$ac_exeext'
10096 { (eval echo "$as_me:10096: \"$ac_try\"") >&5
10097 (eval $ac_try) 2>&5
10099 echo "$as_me:10099: \$? = $ac_status" >&5
10100 (exit $ac_status); }; }; then
10101 ac_cv_lib_socket_connect=yes
10103 echo "$as_me: failed program was:" >&5
10104 cat conftest.$ac_ext >&5
10105 ac_cv_lib_socket_connect=no
10107 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10108 LIBS=$ac_check_lib_save_LIBS
10110 echo "$as_me:10110: result: $ac_cv_lib_socket_connect" >&5
10111 echo "${ECHO_T}$ac_cv_lib_socket_connect" >&6
10112 if test $ac_cv_lib_socket_connect = yes; then
10113 X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS"
10118 # Guillermo Gomez says -lposix is necessary on A/UX.
10119 echo "$as_me:10119: checking for remove" >&5
10120 echo $ECHO_N "checking for remove... $ECHO_C" >&6
10121 if test "${ac_cv_func_remove+set}" = set; then
10122 echo $ECHO_N "(cached) $ECHO_C" >&6
10124 cat >conftest.$ac_ext <<_ACEOF
10125 #line 10125 "configure"
10126 #include "confdefs.h"
10127 /* System header to define __stub macros and hopefully few prototypes,
10128 which can conflict with char remove (); below. */
10129 #include <assert.h>
10130 /* Override any gcc2 internal prototype to avoid an error. */
10134 /* We use char because int might match the return type of a gcc2
10135 builtin and then its argument prototype would still apply. */
10142 /* The GNU C library defines this for functions which it implements
10143 to always fail with ENOSYS. Some functions are actually named
10144 something starting with __ and the normal name is an alias. */
10145 #if defined (__stub_remove) || defined (__stub___remove)
10155 rm -f conftest.$ac_objext conftest$ac_exeext
10156 if { (eval echo "$as_me:10156: \"$ac_link\"") >&5
10157 (eval $ac_link) 2>&5
10159 echo "$as_me:10159: \$? = $ac_status" >&5
10160 (exit $ac_status); } &&
10161 { ac_try='test -s conftest$ac_exeext'
10162 { (eval echo "$as_me:10162: \"$ac_try\"") >&5
10163 (eval $ac_try) 2>&5
10165 echo "$as_me:10165: \$? = $ac_status" >&5
10166 (exit $ac_status); }; }; then
10167 ac_cv_func_remove=yes
10169 echo "$as_me: failed program was:" >&5
10170 cat conftest.$ac_ext >&5
10171 ac_cv_func_remove=no
10173 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10175 echo "$as_me:10175: result: $ac_cv_func_remove" >&5
10176 echo "${ECHO_T}$ac_cv_func_remove" >&6
10178 if test $ac_cv_func_remove = no; then
10179 echo "$as_me:10179: checking for remove in -lposix" >&5
10180 echo $ECHO_N "checking for remove in -lposix... $ECHO_C" >&6
10181 if test "${ac_cv_lib_posix_remove+set}" = set; then
10182 echo $ECHO_N "(cached) $ECHO_C" >&6
10184 ac_check_lib_save_LIBS=$LIBS
10185 LIBS="-lposix $LIBS"
10186 cat >conftest.$ac_ext <<_ACEOF
10187 #line 10187 "configure"
10188 #include "confdefs.h"
10190 /* Override any gcc2 internal prototype to avoid an error. */
10194 /* We use char because int might match the return type of a gcc2
10195 builtin and then its argument prototype would still apply. */
10205 rm -f conftest.$ac_objext conftest$ac_exeext
10206 if { (eval echo "$as_me:10206: \"$ac_link\"") >&5
10207 (eval $ac_link) 2>&5
10209 echo "$as_me:10209: \$? = $ac_status" >&5
10210 (exit $ac_status); } &&
10211 { ac_try='test -s conftest$ac_exeext'
10212 { (eval echo "$as_me:10212: \"$ac_try\"") >&5
10213 (eval $ac_try) 2>&5
10215 echo "$as_me:10215: \$? = $ac_status" >&5
10216 (exit $ac_status); }; }; then
10217 ac_cv_lib_posix_remove=yes
10219 echo "$as_me: failed program was:" >&5
10220 cat conftest.$ac_ext >&5
10221 ac_cv_lib_posix_remove=no
10223 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10224 LIBS=$ac_check_lib_save_LIBS
10226 echo "$as_me:10226: result: $ac_cv_lib_posix_remove" >&5
10227 echo "${ECHO_T}$ac_cv_lib_posix_remove" >&6
10228 if test $ac_cv_lib_posix_remove = yes; then
10229 X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix"
10234 # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
10235 echo "$as_me:10235: checking for shmat" >&5
10236 echo $ECHO_N "checking for shmat... $ECHO_C" >&6
10237 if test "${ac_cv_func_shmat+set}" = set; then
10238 echo $ECHO_N "(cached) $ECHO_C" >&6
10240 cat >conftest.$ac_ext <<_ACEOF
10241 #line 10241 "configure"
10242 #include "confdefs.h"
10243 /* System header to define __stub macros and hopefully few prototypes,
10244 which can conflict with char shmat (); below. */
10245 #include <assert.h>
10246 /* Override any gcc2 internal prototype to avoid an error. */
10250 /* We use char because int might match the return type of a gcc2
10251 builtin and then its argument prototype would still apply. */
10258 /* The GNU C library defines this for functions which it implements
10259 to always fail with ENOSYS. Some functions are actually named
10260 something starting with __ and the normal name is an alias. */
10261 #if defined (__stub_shmat) || defined (__stub___shmat)
10271 rm -f conftest.$ac_objext conftest$ac_exeext
10272 if { (eval echo "$as_me:10272: \"$ac_link\"") >&5
10273 (eval $ac_link) 2>&5
10275 echo "$as_me:10275: \$? = $ac_status" >&5
10276 (exit $ac_status); } &&
10277 { ac_try='test -s conftest$ac_exeext'
10278 { (eval echo "$as_me:10278: \"$ac_try\"") >&5
10279 (eval $ac_try) 2>&5
10281 echo "$as_me:10281: \$? = $ac_status" >&5
10282 (exit $ac_status); }; }; then
10283 ac_cv_func_shmat=yes
10285 echo "$as_me: failed program was:" >&5
10286 cat conftest.$ac_ext >&5
10287 ac_cv_func_shmat=no
10289 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10291 echo "$as_me:10291: result: $ac_cv_func_shmat" >&5
10292 echo "${ECHO_T}$ac_cv_func_shmat" >&6
10294 if test $ac_cv_func_shmat = no; then
10295 echo "$as_me:10295: checking for shmat in -lipc" >&5
10296 echo $ECHO_N "checking for shmat in -lipc... $ECHO_C" >&6
10297 if test "${ac_cv_lib_ipc_shmat+set}" = set; then
10298 echo $ECHO_N "(cached) $ECHO_C" >&6
10300 ac_check_lib_save_LIBS=$LIBS
10302 cat >conftest.$ac_ext <<_ACEOF
10303 #line 10303 "configure"
10304 #include "confdefs.h"
10306 /* Override any gcc2 internal prototype to avoid an error. */
10310 /* We use char because int might match the return type of a gcc2
10311 builtin and then its argument prototype would still apply. */
10321 rm -f conftest.$ac_objext conftest$ac_exeext
10322 if { (eval echo "$as_me:10322: \"$ac_link\"") >&5
10323 (eval $ac_link) 2>&5
10325 echo "$as_me:10325: \$? = $ac_status" >&5
10326 (exit $ac_status); } &&
10327 { ac_try='test -s conftest$ac_exeext'
10328 { (eval echo "$as_me:10328: \"$ac_try\"") >&5
10329 (eval $ac_try) 2>&5
10331 echo "$as_me:10331: \$? = $ac_status" >&5
10332 (exit $ac_status); }; }; then
10333 ac_cv_lib_ipc_shmat=yes
10335 echo "$as_me: failed program was:" >&5
10336 cat conftest.$ac_ext >&5
10337 ac_cv_lib_ipc_shmat=no
10339 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10340 LIBS=$ac_check_lib_save_LIBS
10342 echo "$as_me:10342: result: $ac_cv_lib_ipc_shmat" >&5
10343 echo "${ECHO_T}$ac_cv_lib_ipc_shmat" >&6
10344 if test $ac_cv_lib_ipc_shmat = yes; then
10345 X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc"
10351 # Check for libraries that X11R6 Xt/Xaw programs need.
10352 ac_save_LDFLAGS=$LDFLAGS
10353 test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries"
10354 # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
10355 # check for ICE first), but we must link in the order -lSM -lICE or
10356 # we get undefined symbols. So assume we have SM if we have ICE.
10357 # These have to be linked with before -lX11, unlike the other
10358 # libraries we check for below, so use a different variable.
10359 # John Interrante, Karl Berry
10360 echo "$as_me:10360: checking for IceConnectionNumber in -lICE" >&5
10361 echo $ECHO_N "checking for IceConnectionNumber in -lICE... $ECHO_C" >&6
10362 if test "${ac_cv_lib_ICE_IceConnectionNumber+set}" = set; then
10363 echo $ECHO_N "(cached) $ECHO_C" >&6
10365 ac_check_lib_save_LIBS=$LIBS
10366 LIBS="-lICE $X_EXTRA_LIBS $LIBS"
10367 cat >conftest.$ac_ext <<_ACEOF
10368 #line 10368 "configure"
10369 #include "confdefs.h"
10371 /* Override any gcc2 internal prototype to avoid an error. */
10375 /* We use char because int might match the return type of a gcc2
10376 builtin and then its argument prototype would still apply. */
10377 char IceConnectionNumber ();
10381 IceConnectionNumber ();
10386 rm -f conftest.$ac_objext conftest$ac_exeext
10387 if { (eval echo "$as_me:10387: \"$ac_link\"") >&5
10388 (eval $ac_link) 2>&5
10390 echo "$as_me:10390: \$? = $ac_status" >&5
10391 (exit $ac_status); } &&
10392 { ac_try='test -s conftest$ac_exeext'
10393 { (eval echo "$as_me:10393: \"$ac_try\"") >&5
10394 (eval $ac_try) 2>&5
10396 echo "$as_me:10396: \$? = $ac_status" >&5
10397 (exit $ac_status); }; }; then
10398 ac_cv_lib_ICE_IceConnectionNumber=yes
10400 echo "$as_me: failed program was:" >&5
10401 cat conftest.$ac_ext >&5
10402 ac_cv_lib_ICE_IceConnectionNumber=no
10404 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10405 LIBS=$ac_check_lib_save_LIBS
10407 echo "$as_me:10407: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5
10408 echo "${ECHO_T}$ac_cv_lib_ICE_IceConnectionNumber" >&6
10409 if test $ac_cv_lib_ICE_IceConnectionNumber = yes; then
10410 X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
10413 LDFLAGS=$ac_save_LDFLAGS
10417 cf_x_athena=${cf_x_athena:-Xaw}
10419 echo "$as_me:10419: checking if you want to link with Xaw 3d library" >&5
10420 echo $ECHO_N "checking if you want to link with Xaw 3d library... $ECHO_C" >&6
10423 # Check whether --with-Xaw3d or --without-Xaw3d was given.
10424 if test "${with_Xaw3d+set}" = set; then
10425 withval="$with_Xaw3d"
10428 if test "$withval" = yes ; then
10430 echo "$as_me:10430: result: yes" >&5
10431 echo "${ECHO_T}yes" >&6
10433 echo "$as_me:10433: result: no" >&5
10434 echo "${ECHO_T}no" >&6
10437 echo "$as_me:10437: checking if you want to link with neXT Athena library" >&5
10438 echo $ECHO_N "checking if you want to link with neXT Athena library... $ECHO_C" >&6
10441 # Check whether --with-neXtaw or --without-neXtaw was given.
10442 if test "${with_neXtaw+set}" = set; then
10443 withval="$with_neXtaw"
10446 if test "$withval" = yes ; then
10448 echo "$as_me:10448: result: yes" >&5
10449 echo "${ECHO_T}yes" >&6
10451 echo "$as_me:10451: result: no" >&5
10452 echo "${ECHO_T}no" >&6
10455 echo "$as_me:10455: checking if you want to link with Athena-Plus library" >&5
10456 echo $ECHO_N "checking if you want to link with Athena-Plus library... $ECHO_C" >&6
10459 # Check whether --with-XawPlus or --without-XawPlus was given.
10460 if test "${with_XawPlus+set}" = set; then
10461 withval="$with_XawPlus"
10464 if test "$withval" = yes ; then
10465 cf_x_athena=XawPlus
10466 echo "$as_me:10466: result: yes" >&5
10467 echo "${ECHO_T}yes" >&6
10469 echo "$as_me:10469: result: no" >&5
10470 echo "${ECHO_T}no" >&6
10475 if test "$PKG_CONFIG" != none ; then
10477 test "$cf_x_athena" = Xaw && cf_athena_list="xaw8 xaw7 xaw6"
10478 for cf_athena_pkg in \
10481 ${cf_x_athena}-devel \
10482 lib${cf_x_athena} \
10483 lib${cf_x_athena}-devel
10486 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists $cf_athena_pkg; then
10487 test -n "$verbose" && echo " found package $cf_athena_pkg" 1>&6
10489 echo "${as_me:-configure}:10489: testing found package $cf_athena_pkg ..." 1>&5
10491 cf_pkgconfig_incs="`$PKG_CONFIG --cflags $cf_athena_pkg 2>/dev/null`"
10492 cf_pkgconfig_libs="`$PKG_CONFIG --libs $cf_athena_pkg 2>/dev/null`"
10493 test -n "$verbose" && echo " package $cf_athena_pkg CFLAGS: $cf_pkgconfig_incs" 1>&6
10495 echo "${as_me:-configure}:10495: testing package $cf_athena_pkg CFLAGS: $cf_pkgconfig_incs ..." 1>&5
10497 test -n "$verbose" && echo " package $cf_athena_pkg LIBS: $cf_pkgconfig_libs" 1>&6
10499 echo "${as_me:-configure}:10499: testing package $cf_athena_pkg LIBS: $cf_pkgconfig_libs ..." 1>&5
10504 cf_new_extra_cppflags=
10506 for cf_add_cflags in $cf_pkgconfig_incs
10508 case $cf_fix_cppflags in
10510 case $cf_add_cflags in #(vi
10511 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
10512 case $cf_add_cflags in
10514 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10516 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10517 && test -z "${cf_tst_cflags}" \
10518 && cf_fix_cppflags=yes
10520 if test $cf_fix_cppflags = yes ; then
10521 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10523 elif test "${cf_tst_cflags}" = "\"'" ; then
10524 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10529 case "$CPPFLAGS" in
10530 *$cf_add_cflags) #(vi
10533 case $cf_add_cflags in #(vi
10535 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10537 CPPFLAGS=`echo "$CPPFLAGS" | \
10538 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10539 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10543 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
10548 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
10553 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10555 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10557 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10558 && test -z "${cf_tst_cflags}" \
10559 && cf_fix_cppflags=no
10564 if test -n "$cf_new_cflags" ; then
10566 CFLAGS="$CFLAGS $cf_new_cflags"
10569 if test -n "$cf_new_cppflags" ; then
10571 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
10574 if test -n "$cf_new_extra_cppflags" ; then
10576 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
10579 LIBS="$cf_pkgconfig_libs $LIBS"
10581 cf_x_athena_lib="$cf_pkgconfig_libs"
10583 cf_x_athena_LIBS=`echo "HAVE_LIB_$cf_x_athena" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
10585 cat >>confdefs.h <<EOF
10586 #define $cf_x_athena_LIBS 1
10589 echo "$as_me:10589: checking for usable $cf_x_athena/Xmu package" >&5
10590 echo $ECHO_N "checking for usable $cf_x_athena/Xmu package... $ECHO_C" >&6
10591 if test "${cf_cv_xaw_compat+set}" = set; then
10592 echo $ECHO_N "(cached) $ECHO_C" >&6
10595 cat >conftest.$ac_ext <<_ACEOF
10596 #line 10596 "configure"
10597 #include "confdefs.h"
10599 #include <X11/Xmu/CharSet.h>
10605 int check = XmuCompareISOLatin1("big", "small")
10611 rm -f conftest.$ac_objext conftest$ac_exeext
10612 if { (eval echo "$as_me:10612: \"$ac_link\"") >&5
10613 (eval $ac_link) 2>&5
10615 echo "$as_me:10615: \$? = $ac_status" >&5
10616 (exit $ac_status); } &&
10617 { ac_try='test -s conftest$ac_exeext'
10618 { (eval echo "$as_me:10618: \"$ac_try\"") >&5
10619 (eval $ac_try) 2>&5
10621 echo "$as_me:10621: \$? = $ac_status" >&5
10622 (exit $ac_status); }; }; then
10623 cf_cv_xaw_compat=yes
10625 echo "$as_me: failed program was:" >&5
10626 cat conftest.$ac_ext >&5
10627 cf_cv_xaw_compat=no
10629 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10631 echo "$as_me:10631: result: $cf_cv_xaw_compat" >&5
10632 echo "${ECHO_T}$cf_cv_xaw_compat" >&6
10634 if test "$cf_cv_xaw_compat" = no
10636 # workaround for broken ".pc" files...
10637 case "$cf_x_athena_lib" in #(vi
10641 test -n "$verbose" && echo " work around broken package" 1>&6
10643 echo "${as_me:-configure}:10643: testing work around broken package ..." 1>&5
10645 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xmu; then
10646 test -n "$verbose" && echo " found package xmu" 1>&6
10648 echo "${as_me:-configure}:10648: testing found package xmu ..." 1>&5
10650 cf_pkgconfig_incs="`$PKG_CONFIG --cflags xmu 2>/dev/null`"
10651 cf_pkgconfig_libs="`$PKG_CONFIG --libs xmu 2>/dev/null`"
10652 test -n "$verbose" && echo " package xmu CFLAGS: $cf_pkgconfig_incs" 1>&6
10654 echo "${as_me:-configure}:10654: testing package xmu CFLAGS: $cf_pkgconfig_incs ..." 1>&5
10656 test -n "$verbose" && echo " package xmu LIBS: $cf_pkgconfig_libs" 1>&6
10658 echo "${as_me:-configure}:10658: testing package xmu LIBS: $cf_pkgconfig_libs ..." 1>&5
10663 cf_new_extra_cppflags=
10665 for cf_add_cflags in $cf_pkgconfig_incs
10667 case $cf_fix_cppflags in
10669 case $cf_add_cflags in #(vi
10670 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
10671 case $cf_add_cflags in
10673 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10675 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10676 && test -z "${cf_tst_cflags}" \
10677 && cf_fix_cppflags=yes
10679 if test $cf_fix_cppflags = yes ; then
10680 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10682 elif test "${cf_tst_cflags}" = "\"'" ; then
10683 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10688 case "$CPPFLAGS" in
10689 *$cf_add_cflags) #(vi
10692 case $cf_add_cflags in #(vi
10694 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10696 CPPFLAGS=`echo "$CPPFLAGS" | \
10697 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10698 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10702 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
10707 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
10712 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10714 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10716 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10717 && test -z "${cf_tst_cflags}" \
10718 && cf_fix_cppflags=no
10723 if test -n "$cf_new_cflags" ; then
10725 CFLAGS="$CFLAGS $cf_new_cflags"
10728 if test -n "$cf_new_cppflags" ; then
10730 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
10733 if test -n "$cf_new_extra_cppflags" ; then
10735 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
10738 LIBS="$cf_pkgconfig_libs $LIBS"
10742 test -n "$verbose" && echo " ...before $LIBS" 1>&6
10744 echo "${as_me:-configure}:10744: testing ...before $LIBS ..." 1>&5
10746 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s,-lXt ,-lXt -lXmu ," -e 's/ / /g'`
10747 test -n "$verbose" && echo " ...after $LIBS" 1>&6
10749 echo "${as_me:-configure}:10749: testing ...after $LIBS ..." 1>&5
10765 if test -z "$cf_x_athena_lib" ; then
10767 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists Xext; then
10768 test -n "$verbose" && echo " found package Xext" 1>&6
10770 echo "${as_me:-configure}:10770: testing found package Xext ..." 1>&5
10772 cf_pkgconfig_incs="`$PKG_CONFIG --cflags Xext 2>/dev/null`"
10773 cf_pkgconfig_libs="`$PKG_CONFIG --libs Xext 2>/dev/null`"
10774 test -n "$verbose" && echo " package Xext CFLAGS: $cf_pkgconfig_incs" 1>&6
10776 echo "${as_me:-configure}:10776: testing package Xext CFLAGS: $cf_pkgconfig_incs ..." 1>&5
10778 test -n "$verbose" && echo " package Xext LIBS: $cf_pkgconfig_libs" 1>&6
10780 echo "${as_me:-configure}:10780: testing package Xext LIBS: $cf_pkgconfig_libs ..." 1>&5
10785 cf_new_extra_cppflags=
10787 for cf_add_cflags in $cf_pkgconfig_incs
10789 case $cf_fix_cppflags in
10791 case $cf_add_cflags in #(vi
10792 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
10793 case $cf_add_cflags in
10795 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10797 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10798 && test -z "${cf_tst_cflags}" \
10799 && cf_fix_cppflags=yes
10801 if test $cf_fix_cppflags = yes ; then
10802 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10804 elif test "${cf_tst_cflags}" = "\"'" ; then
10805 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10810 case "$CPPFLAGS" in
10811 *$cf_add_cflags) #(vi
10814 case $cf_add_cflags in #(vi
10816 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10818 CPPFLAGS=`echo "$CPPFLAGS" | \
10819 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10820 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10824 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
10829 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
10834 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10836 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10838 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10839 && test -z "${cf_tst_cflags}" \
10840 && cf_fix_cppflags=no
10845 if test -n "$cf_new_cflags" ; then
10847 CFLAGS="$CFLAGS $cf_new_cflags"
10850 if test -n "$cf_new_cppflags" ; then
10852 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
10855 if test -n "$cf_new_extra_cppflags" ; then
10857 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
10860 LIBS="$cf_pkgconfig_libs $LIBS"
10864 echo "$as_me:10864: checking for XextCreateExtension in -lXext" >&5
10865 echo $ECHO_N "checking for XextCreateExtension in -lXext... $ECHO_C" >&6
10866 if test "${ac_cv_lib_Xext_XextCreateExtension+set}" = set; then
10867 echo $ECHO_N "(cached) $ECHO_C" >&6
10869 ac_check_lib_save_LIBS=$LIBS
10870 LIBS="-lXext $LIBS"
10871 cat >conftest.$ac_ext <<_ACEOF
10872 #line 10872 "configure"
10873 #include "confdefs.h"
10875 /* Override any gcc2 internal prototype to avoid an error. */
10879 /* We use char because int might match the return type of a gcc2
10880 builtin and then its argument prototype would still apply. */
10881 char XextCreateExtension ();
10885 XextCreateExtension ();
10890 rm -f conftest.$ac_objext conftest$ac_exeext
10891 if { (eval echo "$as_me:10891: \"$ac_link\"") >&5
10892 (eval $ac_link) 2>&5
10894 echo "$as_me:10894: \$? = $ac_status" >&5
10895 (exit $ac_status); } &&
10896 { ac_try='test -s conftest$ac_exeext'
10897 { (eval echo "$as_me:10897: \"$ac_try\"") >&5
10898 (eval $ac_try) 2>&5
10900 echo "$as_me:10900: \$? = $ac_status" >&5
10901 (exit $ac_status); }; }; then
10902 ac_cv_lib_Xext_XextCreateExtension=yes
10904 echo "$as_me: failed program was:" >&5
10905 cat conftest.$ac_ext >&5
10906 ac_cv_lib_Xext_XextCreateExtension=no
10908 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10909 LIBS=$ac_check_lib_save_LIBS
10911 echo "$as_me:10911: result: $ac_cv_lib_Xext_XextCreateExtension" >&5
10912 echo "${ECHO_T}$ac_cv_lib_Xext_XextCreateExtension" >&6
10913 if test $ac_cv_lib_Xext_XextCreateExtension = yes; then
10914 LIBS="-lXext $LIBS"
10921 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xt; then
10922 test -n "$verbose" && echo " found package xt" 1>&6
10924 echo "${as_me:-configure}:10924: testing found package xt ..." 1>&5
10926 cf_pkgconfig_incs="`$PKG_CONFIG --cflags xt 2>/dev/null`"
10927 cf_pkgconfig_libs="`$PKG_CONFIG --libs xt 2>/dev/null`"
10928 test -n "$verbose" && echo " package xt CFLAGS: $cf_pkgconfig_incs" 1>&6
10930 echo "${as_me:-configure}:10930: testing package xt CFLAGS: $cf_pkgconfig_incs ..." 1>&5
10932 test -n "$verbose" && echo " package xt LIBS: $cf_pkgconfig_libs" 1>&6
10934 echo "${as_me:-configure}:10934: testing package xt LIBS: $cf_pkgconfig_libs ..." 1>&5
10939 cf_new_extra_cppflags=
10941 for cf_add_cflags in $cf_pkgconfig_incs
10943 case $cf_fix_cppflags in
10945 case $cf_add_cflags in #(vi
10946 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
10947 case $cf_add_cflags in
10949 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10951 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10952 && test -z "${cf_tst_cflags}" \
10953 && cf_fix_cppflags=yes
10955 if test $cf_fix_cppflags = yes ; then
10956 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10958 elif test "${cf_tst_cflags}" = "\"'" ; then
10959 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10964 case "$CPPFLAGS" in
10965 *$cf_add_cflags) #(vi
10968 case $cf_add_cflags in #(vi
10970 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10972 CPPFLAGS=`echo "$CPPFLAGS" | \
10973 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10974 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10978 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
10983 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
10988 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
10990 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10992 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
10993 && test -z "${cf_tst_cflags}" \
10994 && cf_fix_cppflags=no
10999 if test -n "$cf_new_cflags" ; then
11001 CFLAGS="$CFLAGS $cf_new_cflags"
11004 if test -n "$cf_new_cppflags" ; then
11006 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
11009 if test -n "$cf_new_extra_cppflags" ; then
11011 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
11014 LIBS="$cf_pkgconfig_libs $LIBS"
11016 case "x$LIBS" in #(vi
11020 # we have an "xt" package, but it may omit Xt's dependency on X11
11021 echo "$as_me:11021: checking for usable X dependency" >&5
11022 echo $ECHO_N "checking for usable X dependency... $ECHO_C" >&6
11023 if test "${cf_cv_xt_x11_compat+set}" = set; then
11024 echo $ECHO_N "(cached) $ECHO_C" >&6
11027 cat >conftest.$ac_ext <<_ACEOF
11028 #line 11028 "configure"
11029 #include "confdefs.h"
11031 #include <X11/Xlib.h>
11037 int rc1 = XDrawLine((Display*) 0, (Drawable) 0, (GC) 0, 0, 0, 0, 0);
11038 int rc2 = XClearWindow((Display*) 0, (Window) 0);
11039 int rc3 = XMoveWindow((Display*) 0, (Window) 0, 0, 0);
11040 int rc4 = XMoveResizeWindow((Display*)0, (Window)0, 0, 0, 0, 0);
11046 rm -f conftest.$ac_objext conftest$ac_exeext
11047 if { (eval echo "$as_me:11047: \"$ac_link\"") >&5
11048 (eval $ac_link) 2>&5
11050 echo "$as_me:11050: \$? = $ac_status" >&5
11051 (exit $ac_status); } &&
11052 { ac_try='test -s conftest$ac_exeext'
11053 { (eval echo "$as_me:11053: \"$ac_try\"") >&5
11054 (eval $ac_try) 2>&5
11056 echo "$as_me:11056: \$? = $ac_status" >&5
11057 (exit $ac_status); }; }; then
11058 cf_cv_xt_x11_compat=yes
11060 echo "$as_me: failed program was:" >&5
11061 cat conftest.$ac_ext >&5
11062 cf_cv_xt_x11_compat=no
11064 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11066 echo "$as_me:11066: result: $cf_cv_xt_x11_compat" >&5
11067 echo "${ECHO_T}$cf_cv_xt_x11_compat" >&6
11068 if test "$cf_cv_xt_x11_compat" = no
11070 test -n "$verbose" && echo " work around broken X11 dependency" 1>&6
11072 echo "${as_me:-configure}:11072: testing work around broken X11 dependency ..." 1>&5
11074 # 2010/11/19 - good enough until a working Xt on Xcb is delivered.
11076 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists x11; then
11077 test -n "$verbose" && echo " found package x11" 1>&6
11079 echo "${as_me:-configure}:11079: testing found package x11 ..." 1>&5
11081 cf_pkgconfig_incs="`$PKG_CONFIG --cflags x11 2>/dev/null`"
11082 cf_pkgconfig_libs="`$PKG_CONFIG --libs x11 2>/dev/null`"
11083 test -n "$verbose" && echo " package x11 CFLAGS: $cf_pkgconfig_incs" 1>&6
11085 echo "${as_me:-configure}:11085: testing package x11 CFLAGS: $cf_pkgconfig_incs ..." 1>&5
11087 test -n "$verbose" && echo " package x11 LIBS: $cf_pkgconfig_libs" 1>&6
11089 echo "${as_me:-configure}:11089: testing package x11 LIBS: $cf_pkgconfig_libs ..." 1>&5
11094 cf_new_extra_cppflags=
11096 for cf_add_cflags in $cf_pkgconfig_incs
11098 case $cf_fix_cppflags in
11100 case $cf_add_cflags in #(vi
11101 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
11102 case $cf_add_cflags in
11104 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11106 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11107 && test -z "${cf_tst_cflags}" \
11108 && cf_fix_cppflags=yes
11110 if test $cf_fix_cppflags = yes ; then
11111 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11113 elif test "${cf_tst_cflags}" = "\"'" ; then
11114 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11119 case "$CPPFLAGS" in
11120 *$cf_add_cflags) #(vi
11123 case $cf_add_cflags in #(vi
11125 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11127 CPPFLAGS=`echo "$CPPFLAGS" | \
11128 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11129 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11133 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
11138 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
11143 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11145 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11147 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11148 && test -z "${cf_tst_cflags}" \
11149 && cf_fix_cppflags=no
11154 if test -n "$cf_new_cflags" ; then
11156 CFLAGS="$CFLAGS $cf_new_cflags"
11159 if test -n "$cf_new_cppflags" ; then
11161 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
11164 if test -n "$cf_new_extra_cppflags" ; then
11166 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
11169 LIBS="$cf_pkgconfig_libs $LIBS"
11173 test -n "$verbose" && echo " ...before $LIBS" 1>&6
11175 echo "${as_me:-configure}:11175: testing ...before $LIBS ..." 1>&5
11177 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s,-lXt ,-lXt -lX11 ," -e 's/ / /g'`
11178 test -n "$verbose" && echo " ...after $LIBS" 1>&6
11180 echo "${as_me:-configure}:11180: testing ...after $LIBS ..." 1>&5
11188 echo "$as_me:11188: checking for usable X Toolkit package" >&5
11189 echo $ECHO_N "checking for usable X Toolkit package... $ECHO_C" >&6
11190 if test "${cf_cv_xt_ice_compat+set}" = set; then
11191 echo $ECHO_N "(cached) $ECHO_C" >&6
11194 cat >conftest.$ac_ext <<_ACEOF
11195 #line 11195 "configure"
11196 #include "confdefs.h"
11198 #include <X11/Shell.h>
11203 int num = IceConnectionNumber(0)
11209 rm -f conftest.$ac_objext conftest$ac_exeext
11210 if { (eval echo "$as_me:11210: \"$ac_link\"") >&5
11211 (eval $ac_link) 2>&5
11213 echo "$as_me:11213: \$? = $ac_status" >&5
11214 (exit $ac_status); } &&
11215 { ac_try='test -s conftest$ac_exeext'
11216 { (eval echo "$as_me:11216: \"$ac_try\"") >&5
11217 (eval $ac_try) 2>&5
11219 echo "$as_me:11219: \$? = $ac_status" >&5
11220 (exit $ac_status); }; }; then
11221 cf_cv_xt_ice_compat=yes
11223 echo "$as_me: failed program was:" >&5
11224 cat conftest.$ac_ext >&5
11225 cf_cv_xt_ice_compat=no
11227 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11229 echo "$as_me:11229: result: $cf_cv_xt_ice_compat" >&5
11230 echo "${ECHO_T}$cf_cv_xt_ice_compat" >&6
11232 if test "$cf_cv_xt_ice_compat" = no
11234 # workaround for broken ".pc" files used for X Toolkit.
11235 case "x$X_PRE_LIBS" in #(vi
11237 case "x$LIBS" in #(vi
11241 test -n "$verbose" && echo " work around broken ICE dependency" 1>&6
11243 echo "${as_me:-configure}:11243: testing work around broken ICE dependency ..." 1>&5
11245 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists ice; then
11246 test -n "$verbose" && echo " found package ice" 1>&6
11248 echo "${as_me:-configure}:11248: testing found package ice ..." 1>&5
11250 cf_pkgconfig_incs="`$PKG_CONFIG --cflags ice 2>/dev/null`"
11251 cf_pkgconfig_libs="`$PKG_CONFIG --libs ice 2>/dev/null`"
11252 test -n "$verbose" && echo " package ice CFLAGS: $cf_pkgconfig_incs" 1>&6
11254 echo "${as_me:-configure}:11254: testing package ice CFLAGS: $cf_pkgconfig_incs ..." 1>&5
11256 test -n "$verbose" && echo " package ice LIBS: $cf_pkgconfig_libs" 1>&6
11258 echo "${as_me:-configure}:11258: testing package ice LIBS: $cf_pkgconfig_libs ..." 1>&5
11263 cf_new_extra_cppflags=
11265 for cf_add_cflags in $cf_pkgconfig_incs
11267 case $cf_fix_cppflags in
11269 case $cf_add_cflags in #(vi
11270 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
11271 case $cf_add_cflags in
11273 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11275 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11276 && test -z "${cf_tst_cflags}" \
11277 && cf_fix_cppflags=yes
11279 if test $cf_fix_cppflags = yes ; then
11280 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11282 elif test "${cf_tst_cflags}" = "\"'" ; then
11283 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11288 case "$CPPFLAGS" in
11289 *$cf_add_cflags) #(vi
11292 case $cf_add_cflags in #(vi
11294 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11296 CPPFLAGS=`echo "$CPPFLAGS" | \
11297 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11298 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11302 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
11307 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
11312 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11314 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11316 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11317 && test -z "${cf_tst_cflags}" \
11318 && cf_fix_cppflags=no
11323 if test -n "$cf_new_cflags" ; then
11325 CFLAGS="$CFLAGS $cf_new_cflags"
11328 if test -n "$cf_new_cppflags" ; then
11330 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
11333 if test -n "$cf_new_extra_cppflags" ; then
11335 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
11338 LIBS="$cf_pkgconfig_libs $LIBS"
11340 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists sm; then
11341 test -n "$verbose" && echo " found package sm" 1>&6
11343 echo "${as_me:-configure}:11343: testing found package sm ..." 1>&5
11345 cf_pkgconfig_incs="`$PKG_CONFIG --cflags sm 2>/dev/null`"
11346 cf_pkgconfig_libs="`$PKG_CONFIG --libs sm 2>/dev/null`"
11347 test -n "$verbose" && echo " package sm CFLAGS: $cf_pkgconfig_incs" 1>&6
11349 echo "${as_me:-configure}:11349: testing package sm CFLAGS: $cf_pkgconfig_incs ..." 1>&5
11351 test -n "$verbose" && echo " package sm LIBS: $cf_pkgconfig_libs" 1>&6
11353 echo "${as_me:-configure}:11353: testing package sm LIBS: $cf_pkgconfig_libs ..." 1>&5
11358 cf_new_extra_cppflags=
11360 for cf_add_cflags in $cf_pkgconfig_incs
11362 case $cf_fix_cppflags in
11364 case $cf_add_cflags in #(vi
11365 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
11366 case $cf_add_cflags in
11368 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11370 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11371 && test -z "${cf_tst_cflags}" \
11372 && cf_fix_cppflags=yes
11374 if test $cf_fix_cppflags = yes ; then
11375 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11377 elif test "${cf_tst_cflags}" = "\"'" ; then
11378 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11383 case "$CPPFLAGS" in
11384 *$cf_add_cflags) #(vi
11387 case $cf_add_cflags in #(vi
11389 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11391 CPPFLAGS=`echo "$CPPFLAGS" | \
11392 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11393 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11397 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
11402 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
11407 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11409 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11411 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11412 && test -z "${cf_tst_cflags}" \
11413 && cf_fix_cppflags=no
11418 if test -n "$cf_new_cflags" ; then
11420 CFLAGS="$CFLAGS $cf_new_cflags"
11423 if test -n "$cf_new_cppflags" ; then
11425 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
11428 if test -n "$cf_new_extra_cppflags" ; then
11430 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
11433 LIBS="$cf_pkgconfig_libs $LIBS"
11441 test -n "$verbose" && echo " ...before $LIBS" 1>&6
11443 echo "${as_me:-configure}:11443: testing ...before $LIBS ..." 1>&5
11445 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s,-lXt ,-lXt $X_PRE_LIBS ," -e 's/ / /g'`
11446 test -n "$verbose" && echo " ...after $LIBS" 1>&6
11448 echo "${as_me:-configure}:11448: testing ...after $LIBS ..." 1>&5
11462 LDFLAGS="$X_LIBS $LDFLAGS"
11464 test -n "$verbose" && echo " checking additions to CFLAGS" 1>&6
11466 echo "${as_me:-configure}:11466: testing checking additions to CFLAGS ..." 1>&5
11468 cf_check_cflags="$CFLAGS"
11469 cf_check_cppflags="$CPPFLAGS"
11474 cf_new_extra_cppflags=
11476 for cf_add_cflags in $X_CFLAGS
11478 case $cf_fix_cppflags in
11480 case $cf_add_cflags in #(vi
11481 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
11482 case $cf_add_cflags in
11484 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11486 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11487 && test -z "${cf_tst_cflags}" \
11488 && cf_fix_cppflags=yes
11490 if test $cf_fix_cppflags = yes ; then
11491 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11493 elif test "${cf_tst_cflags}" = "\"'" ; then
11494 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11499 case "$CPPFLAGS" in
11500 *$cf_add_cflags) #(vi
11503 case $cf_add_cflags in #(vi
11505 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11507 CPPFLAGS=`echo "$CPPFLAGS" | \
11508 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11509 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11513 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
11518 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
11523 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11525 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11527 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11528 && test -z "${cf_tst_cflags}" \
11529 && cf_fix_cppflags=no
11534 if test -n "$cf_new_cflags" ; then
11535 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
11537 echo "${as_me:-configure}:11537: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
11539 CFLAGS="$CFLAGS $cf_new_cflags"
11542 if test -n "$cf_new_cppflags" ; then
11543 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
11545 echo "${as_me:-configure}:11545: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
11547 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
11550 if test -n "$cf_new_extra_cppflags" ; then
11551 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
11553 echo "${as_me:-configure}:11553: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
11555 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
11558 if test "$cf_check_cflags" != "$CFLAGS" ; then
11559 cat >conftest.$ac_ext <<_ACEOF
11560 #line 11560 "configure"
11561 #include "confdefs.h"
11566 printf("Hello world");
11571 rm -f conftest.$ac_objext conftest$ac_exeext
11572 if { (eval echo "$as_me:11572: \"$ac_link\"") >&5
11573 (eval $ac_link) 2>&5
11575 echo "$as_me:11575: \$? = $ac_status" >&5
11576 (exit $ac_status); } &&
11577 { ac_try='test -s conftest$ac_exeext'
11578 { (eval echo "$as_me:11578: \"$ac_try\"") >&5
11579 (eval $ac_try) 2>&5
11581 echo "$as_me:11581: \$? = $ac_status" >&5
11582 (exit $ac_status); }; }; then
11585 echo "$as_me: failed program was:" >&5
11586 cat conftest.$ac_ext >&5
11587 test -n "$verbose" && echo " test-compile failed. Undoing change to \$CFLAGS" 1>&6
11589 echo "${as_me:-configure}:11589: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5
11591 if test "$cf_check_cppflags" != "$CPPFLAGS" ; then
11592 test -n "$verbose" && echo " but keeping change to \$CPPFLAGS" 1>&6
11594 echo "${as_me:-configure}:11594: testing but keeping change to \$CPPFLAGS ..." 1>&5
11597 CFLAGS="$cf_check_flags"
11599 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11602 echo "$as_me:11602: checking for XOpenDisplay" >&5
11603 echo $ECHO_N "checking for XOpenDisplay... $ECHO_C" >&6
11604 if test "${ac_cv_func_XOpenDisplay+set}" = set; then
11605 echo $ECHO_N "(cached) $ECHO_C" >&6
11607 cat >conftest.$ac_ext <<_ACEOF
11608 #line 11608 "configure"
11609 #include "confdefs.h"
11610 /* System header to define __stub macros and hopefully few prototypes,
11611 which can conflict with char XOpenDisplay (); below. */
11612 #include <assert.h>
11613 /* Override any gcc2 internal prototype to avoid an error. */
11617 /* We use char because int might match the return type of a gcc2
11618 builtin and then its argument prototype would still apply. */
11619 char XOpenDisplay ();
11625 /* The GNU C library defines this for functions which it implements
11626 to always fail with ENOSYS. Some functions are actually named
11627 something starting with __ and the normal name is an alias. */
11628 #if defined (__stub_XOpenDisplay) || defined (__stub___XOpenDisplay)
11638 rm -f conftest.$ac_objext conftest$ac_exeext
11639 if { (eval echo "$as_me:11639: \"$ac_link\"") >&5
11640 (eval $ac_link) 2>&5
11642 echo "$as_me:11642: \$? = $ac_status" >&5
11643 (exit $ac_status); } &&
11644 { ac_try='test -s conftest$ac_exeext'
11645 { (eval echo "$as_me:11645: \"$ac_try\"") >&5
11646 (eval $ac_try) 2>&5
11648 echo "$as_me:11648: \$? = $ac_status" >&5
11649 (exit $ac_status); }; }; then
11650 ac_cv_func_XOpenDisplay=yes
11652 echo "$as_me: failed program was:" >&5
11653 cat conftest.$ac_ext >&5
11654 ac_cv_func_XOpenDisplay=no
11656 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11658 echo "$as_me:11658: result: $ac_cv_func_XOpenDisplay" >&5
11659 echo "${ECHO_T}$ac_cv_func_XOpenDisplay" >&6
11660 if test $ac_cv_func_XOpenDisplay = yes; then
11664 echo "$as_me:11664: checking for XOpenDisplay in -lX11" >&5
11665 echo $ECHO_N "checking for XOpenDisplay in -lX11... $ECHO_C" >&6
11666 if test "${ac_cv_lib_X11_XOpenDisplay+set}" = set; then
11667 echo $ECHO_N "(cached) $ECHO_C" >&6
11669 ac_check_lib_save_LIBS=$LIBS
11670 LIBS="-lX11 $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
11671 cat >conftest.$ac_ext <<_ACEOF
11672 #line 11672 "configure"
11673 #include "confdefs.h"
11675 /* Override any gcc2 internal prototype to avoid an error. */
11679 /* We use char because int might match the return type of a gcc2
11680 builtin and then its argument prototype would still apply. */
11681 char XOpenDisplay ();
11690 rm -f conftest.$ac_objext conftest$ac_exeext
11691 if { (eval echo "$as_me:11691: \"$ac_link\"") >&5
11692 (eval $ac_link) 2>&5
11694 echo "$as_me:11694: \$? = $ac_status" >&5
11695 (exit $ac_status); } &&
11696 { ac_try='test -s conftest$ac_exeext'
11697 { (eval echo "$as_me:11697: \"$ac_try\"") >&5
11698 (eval $ac_try) 2>&5
11700 echo "$as_me:11700: \$? = $ac_status" >&5
11701 (exit $ac_status); }; }; then
11702 ac_cv_lib_X11_XOpenDisplay=yes
11704 echo "$as_me: failed program was:" >&5
11705 cat conftest.$ac_ext >&5
11706 ac_cv_lib_X11_XOpenDisplay=no
11708 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11709 LIBS=$ac_check_lib_save_LIBS
11711 echo "$as_me:11711: result: $ac_cv_lib_X11_XOpenDisplay" >&5
11712 echo "${ECHO_T}$ac_cv_lib_X11_XOpenDisplay" >&6
11713 if test $ac_cv_lib_X11_XOpenDisplay = yes; then
11719 echo "$as_me:11719: checking for XtAppInitialize" >&5
11720 echo $ECHO_N "checking for XtAppInitialize... $ECHO_C" >&6
11721 if test "${ac_cv_func_XtAppInitialize+set}" = set; then
11722 echo $ECHO_N "(cached) $ECHO_C" >&6
11724 cat >conftest.$ac_ext <<_ACEOF
11725 #line 11725 "configure"
11726 #include "confdefs.h"
11727 /* System header to define __stub macros and hopefully few prototypes,
11728 which can conflict with char XtAppInitialize (); below. */
11729 #include <assert.h>
11730 /* Override any gcc2 internal prototype to avoid an error. */
11734 /* We use char because int might match the return type of a gcc2
11735 builtin and then its argument prototype would still apply. */
11736 char XtAppInitialize ();
11742 /* The GNU C library defines this for functions which it implements
11743 to always fail with ENOSYS. Some functions are actually named
11744 something starting with __ and the normal name is an alias. */
11745 #if defined (__stub_XtAppInitialize) || defined (__stub___XtAppInitialize)
11748 f = XtAppInitialize;
11755 rm -f conftest.$ac_objext conftest$ac_exeext
11756 if { (eval echo "$as_me:11756: \"$ac_link\"") >&5
11757 (eval $ac_link) 2>&5
11759 echo "$as_me:11759: \$? = $ac_status" >&5
11760 (exit $ac_status); } &&
11761 { ac_try='test -s conftest$ac_exeext'
11762 { (eval echo "$as_me:11762: \"$ac_try\"") >&5
11763 (eval $ac_try) 2>&5
11765 echo "$as_me:11765: \$? = $ac_status" >&5
11766 (exit $ac_status); }; }; then
11767 ac_cv_func_XtAppInitialize=yes
11769 echo "$as_me: failed program was:" >&5
11770 cat conftest.$ac_ext >&5
11771 ac_cv_func_XtAppInitialize=no
11773 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11775 echo "$as_me:11775: result: $ac_cv_func_XtAppInitialize" >&5
11776 echo "${ECHO_T}$ac_cv_func_XtAppInitialize" >&6
11777 if test $ac_cv_func_XtAppInitialize = yes; then
11781 echo "$as_me:11781: checking for XtAppInitialize in -lXt" >&5
11782 echo $ECHO_N "checking for XtAppInitialize in -lXt... $ECHO_C" >&6
11783 if test "${ac_cv_lib_Xt_XtAppInitialize+set}" = set; then
11784 echo $ECHO_N "(cached) $ECHO_C" >&6
11786 ac_check_lib_save_LIBS=$LIBS
11787 LIBS="-lXt $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
11788 cat >conftest.$ac_ext <<_ACEOF
11789 #line 11789 "configure"
11790 #include "confdefs.h"
11792 /* Override any gcc2 internal prototype to avoid an error. */
11796 /* We use char because int might match the return type of a gcc2
11797 builtin and then its argument prototype would still apply. */
11798 char XtAppInitialize ();
11802 XtAppInitialize ();
11807 rm -f conftest.$ac_objext conftest$ac_exeext
11808 if { (eval echo "$as_me:11808: \"$ac_link\"") >&5
11809 (eval $ac_link) 2>&5
11811 echo "$as_me:11811: \$? = $ac_status" >&5
11812 (exit $ac_status); } &&
11813 { ac_try='test -s conftest$ac_exeext'
11814 { (eval echo "$as_me:11814: \"$ac_try\"") >&5
11815 (eval $ac_try) 2>&5
11817 echo "$as_me:11817: \$? = $ac_status" >&5
11818 (exit $ac_status); }; }; then
11819 ac_cv_lib_Xt_XtAppInitialize=yes
11821 echo "$as_me: failed program was:" >&5
11822 cat conftest.$ac_ext >&5
11823 ac_cv_lib_Xt_XtAppInitialize=no
11825 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11826 LIBS=$ac_check_lib_save_LIBS
11828 echo "$as_me:11828: result: $ac_cv_lib_Xt_XtAppInitialize" >&5
11829 echo "${ECHO_T}$ac_cv_lib_Xt_XtAppInitialize" >&6
11830 if test $ac_cv_lib_Xt_XtAppInitialize = yes; then
11831 cat >>confdefs.h <<\EOF
11832 #define HAVE_LIBXT 1
11836 LIBS="-lXt $X_PRE_LIBS $LIBS $X_EXTRA_LIBS"
11843 if test $cf_have_X_LIBS = no ; then
11844 { echo "$as_me:11844: WARNING: Unable to successfully link X Toolkit library (-lXt) with
11845 test program. You will have to check and add the proper libraries by hand
11847 echo "$as_me: WARNING: Unable to successfully link X Toolkit library (-lXt) with
11848 test program. You will have to check and add the proper libraries by hand
11849 to makefile." >&2;}
11852 cf_x_athena_root=$cf_x_athena
11855 for cf_path in default \
11856 /usr/contrib/X11R6 \
11857 /usr/contrib/X11R5 \
11861 if test -z "$cf_x_athena_inc" ; then
11862 cf_save="$CPPFLAGS"
11863 cf_test=X11/$cf_x_athena_root/SimpleMenu.h
11864 if test $cf_path != default ; then
11865 CPPFLAGS="$cf_save -I$cf_path/include"
11866 echo "$as_me:11866: checking for $cf_test in $cf_path" >&5
11867 echo $ECHO_N "checking for $cf_test in $cf_path... $ECHO_C" >&6
11869 echo "$as_me:11869: checking for $cf_test" >&5
11870 echo $ECHO_N "checking for $cf_test... $ECHO_C" >&6
11872 cat >conftest.$ac_ext <<_ACEOF
11873 #line 11873 "configure"
11874 #include "confdefs.h"
11876 #include <X11/Intrinsic.h>
11877 #include <$cf_test>
11886 rm -f conftest.$ac_objext
11887 if { (eval echo "$as_me:11887: \"$ac_compile\"") >&5
11888 (eval $ac_compile) 2>&5
11890 echo "$as_me:11890: \$? = $ac_status" >&5
11891 (exit $ac_status); } &&
11892 { ac_try='test -s conftest.$ac_objext'
11893 { (eval echo "$as_me:11893: \"$ac_try\"") >&5
11894 (eval $ac_try) 2>&5
11896 echo "$as_me:11896: \$? = $ac_status" >&5
11897 (exit $ac_status); }; }; then
11900 echo "$as_me: failed program was:" >&5
11901 cat conftest.$ac_ext >&5
11904 rm -f conftest.$ac_objext conftest.$ac_ext
11905 echo "$as_me:11905: result: $cf_result" >&5
11906 echo "${ECHO_T}$cf_result" >&6
11907 if test "$cf_result" = yes ; then
11908 cf_x_athena_inc=$cf_path
11911 CPPFLAGS="$cf_save"
11916 if test -z "$cf_x_athena_inc" ; then
11917 { echo "$as_me:11917: WARNING: Unable to successfully find Athena header files with test program" >&5
11918 echo "$as_me: WARNING: Unable to successfully find Athena header files with test program" >&2;}
11919 elif test "$cf_x_athena_inc" != default ; then
11920 CPPFLAGS="$CPPFLAGS -I$cf_x_athena_inc"
11923 cf_x_athena_root=$cf_x_athena
11926 for cf_path in default \
11927 /usr/contrib/X11R6 \
11928 /usr/contrib/X11R5 \
11933 "-l$cf_x_athena_root -lXmu" \
11934 "-l$cf_x_athena_root -lXpm -lXmu" \
11935 "-l${cf_x_athena_root}_s -lXmu_s"
11937 if test -z "$cf_x_athena_lib" ; then
11939 cf_test=XawSimpleMenuAddGlobalActions
11940 if test $cf_path != default ; then
11941 LIBS="-L$cf_path/lib $cf_lib $LIBS"
11942 echo "$as_me:11942: checking for $cf_lib in $cf_path" >&5
11943 echo $ECHO_N "checking for $cf_lib in $cf_path... $ECHO_C" >&6
11945 LIBS="$cf_lib $LIBS"
11946 echo "$as_me:11946: checking for $cf_test in $cf_lib" >&5
11947 echo $ECHO_N "checking for $cf_test in $cf_lib... $ECHO_C" >&6
11949 cat >conftest.$ac_ext <<_ACEOF
11950 #line 11950 "configure"
11951 #include "confdefs.h"
11953 #include <X11/Intrinsic.h>
11954 #include <X11/$cf_x_athena_root/SimpleMenu.h>
11960 $cf_test((XtAppContext) 0)
11965 rm -f conftest.$ac_objext conftest$ac_exeext
11966 if { (eval echo "$as_me:11966: \"$ac_link\"") >&5
11967 (eval $ac_link) 2>&5
11969 echo "$as_me:11969: \$? = $ac_status" >&5
11970 (exit $ac_status); } &&
11971 { ac_try='test -s conftest$ac_exeext'
11972 { (eval echo "$as_me:11972: \"$ac_try\"") >&5
11973 (eval $ac_try) 2>&5
11975 echo "$as_me:11975: \$? = $ac_status" >&5
11976 (exit $ac_status); }; }; then
11979 echo "$as_me: failed program was:" >&5
11980 cat conftest.$ac_ext >&5
11983 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11984 echo "$as_me:11984: result: $cf_result" >&5
11985 echo "${ECHO_T}$cf_result" >&6
11986 if test "$cf_result" = yes ; then
11987 cf_x_athena_lib="$cf_lib"
11995 if test -z "$cf_x_athena_lib" ; then
11996 { { echo "$as_me:11996: error: Unable to successfully link Athena library (-l$cf_x_athena_root) with test program" >&5
11997 echo "$as_me: error: Unable to successfully link Athena library (-l$cf_x_athena_root) with test program" >&2;}
11998 { (exit 1); exit 1; }; }
12001 cf_x_athena_LIBS=`echo "HAVE_LIB_$cf_x_athena" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
12003 cat >>confdefs.h <<EOF
12004 #define $cf_x_athena_LIBS 1
12009 for ac_prog in xcurses-config
12011 # Extract the first word of "$ac_prog", so it can be a program name with args.
12012 set dummy $ac_prog; ac_word=$2
12013 echo "$as_me:12013: checking for $ac_word" >&5
12014 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
12015 if test "${ac_cv_path_XCURSES_CONFIG+set}" = set; then
12016 echo $ECHO_N "(cached) $ECHO_C" >&6
12018 case $XCURSES_CONFIG in
12020 ac_cv_path_XCURSES_CONFIG="$XCURSES_CONFIG" # Let the user override the test with a path.
12023 ac_save_IFS=$IFS; IFS=$ac_path_separator
12025 for ac_dir in $ac_dummy; do
12027 test -z "$ac_dir" && ac_dir=.
12028 if $as_executable_p "$ac_dir/$ac_word"; then
12029 ac_cv_path_XCURSES_CONFIG="$ac_dir/$ac_word"
12030 echo "$as_me:12030: found $ac_dir/$ac_word" >&5
12038 XCURSES_CONFIG=$ac_cv_path_XCURSES_CONFIG
12040 if test -n "$XCURSES_CONFIG"; then
12041 echo "$as_me:12041: result: $XCURSES_CONFIG" >&5
12042 echo "${ECHO_T}$XCURSES_CONFIG" >&6
12044 echo "$as_me:12044: result: no" >&5
12045 echo "${ECHO_T}no" >&6
12048 test -n "$XCURSES_CONFIG" && break
12050 test -n "$XCURSES_CONFIG" || XCURSES_CONFIG="none"
12052 if test "$XCURSES_CONFIG" != none ; then
12054 CPPFLAGS="$CPPFLAGS `$XCURSES_CONFIG --cflags`"
12055 LIBS="`$XCURSES_CONFIG --libs` $LIBS"
12057 cf_cv_lib_XCurses=yes
12061 LDFLAGS="$LDFLAGS $X_LIBS"
12063 test -n "$verbose" && echo " checking additions to CFLAGS" 1>&6
12065 echo "${as_me:-configure}:12065: testing checking additions to CFLAGS ..." 1>&5
12067 cf_check_cflags="$CFLAGS"
12068 cf_check_cppflags="$CPPFLAGS"
12073 cf_new_extra_cppflags=
12075 for cf_add_cflags in $X_CFLAGS
12077 case $cf_fix_cppflags in
12079 case $cf_add_cflags in #(vi
12080 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
12081 case $cf_add_cflags in
12083 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
12085 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
12086 && test -z "${cf_tst_cflags}" \
12087 && cf_fix_cppflags=yes
12089 if test $cf_fix_cppflags = yes ; then
12090 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
12092 elif test "${cf_tst_cflags}" = "\"'" ; then
12093 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
12098 case "$CPPFLAGS" in
12099 *$cf_add_cflags) #(vi
12102 case $cf_add_cflags in #(vi
12104 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12106 CPPFLAGS=`echo "$CPPFLAGS" | \
12107 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12108 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12112 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
12117 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
12122 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
12124 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
12126 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
12127 && test -z "${cf_tst_cflags}" \
12128 && cf_fix_cppflags=no
12133 if test -n "$cf_new_cflags" ; then
12134 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
12136 echo "${as_me:-configure}:12136: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
12138 CFLAGS="$CFLAGS $cf_new_cflags"
12141 if test -n "$cf_new_cppflags" ; then
12142 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
12144 echo "${as_me:-configure}:12144: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
12146 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
12149 if test -n "$cf_new_extra_cppflags" ; then
12150 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
12152 echo "${as_me:-configure}:12152: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
12154 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
12157 if test "$cf_check_cflags" != "$CFLAGS" ; then
12158 cat >conftest.$ac_ext <<_ACEOF
12159 #line 12159 "configure"
12160 #include "confdefs.h"
12165 printf("Hello world");
12170 rm -f conftest.$ac_objext conftest$ac_exeext
12171 if { (eval echo "$as_me:12171: \"$ac_link\"") >&5
12172 (eval $ac_link) 2>&5
12174 echo "$as_me:12174: \$? = $ac_status" >&5
12175 (exit $ac_status); } &&
12176 { ac_try='test -s conftest$ac_exeext'
12177 { (eval echo "$as_me:12177: \"$ac_try\"") >&5
12178 (eval $ac_try) 2>&5
12180 echo "$as_me:12180: \$? = $ac_status" >&5
12181 (exit $ac_status); }; }; then
12184 echo "$as_me: failed program was:" >&5
12185 cat conftest.$ac_ext >&5
12186 test -n "$verbose" && echo " test-compile failed. Undoing change to \$CFLAGS" 1>&6
12188 echo "${as_me:-configure}:12188: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5
12190 if test "$cf_check_cppflags" != "$CPPFLAGS" ; then
12191 test -n "$verbose" && echo " but keeping change to \$CPPFLAGS" 1>&6
12193 echo "${as_me:-configure}:12193: testing but keeping change to \$CPPFLAGS ..." 1>&5
12196 CFLAGS="$cf_check_flags"
12198 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12201 echo "$as_me:12201: checking for XOpenDisplay in -lX11" >&5
12202 echo $ECHO_N "checking for XOpenDisplay in -lX11... $ECHO_C" >&6
12203 if test "${ac_cv_lib_X11_XOpenDisplay+set}" = set; then
12204 echo $ECHO_N "(cached) $ECHO_C" >&6
12206 ac_check_lib_save_LIBS=$LIBS
12207 LIBS="-lX11 $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
12208 cat >conftest.$ac_ext <<_ACEOF
12209 #line 12209 "configure"
12210 #include "confdefs.h"
12212 /* Override any gcc2 internal prototype to avoid an error. */
12216 /* We use char because int might match the return type of a gcc2
12217 builtin and then its argument prototype would still apply. */
12218 char XOpenDisplay ();
12227 rm -f conftest.$ac_objext conftest$ac_exeext
12228 if { (eval echo "$as_me:12228: \"$ac_link\"") >&5
12229 (eval $ac_link) 2>&5
12231 echo "$as_me:12231: \$? = $ac_status" >&5
12232 (exit $ac_status); } &&
12233 { ac_try='test -s conftest$ac_exeext'
12234 { (eval echo "$as_me:12234: \"$ac_try\"") >&5
12235 (eval $ac_try) 2>&5
12237 echo "$as_me:12237: \$? = $ac_status" >&5
12238 (exit $ac_status); }; }; then
12239 ac_cv_lib_X11_XOpenDisplay=yes
12241 echo "$as_me: failed program was:" >&5
12242 cat conftest.$ac_ext >&5
12243 ac_cv_lib_X11_XOpenDisplay=no
12245 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12246 LIBS=$ac_check_lib_save_LIBS
12248 echo "$as_me:12248: result: $ac_cv_lib_X11_XOpenDisplay" >&5
12249 echo "${ECHO_T}$ac_cv_lib_X11_XOpenDisplay" >&6
12250 if test $ac_cv_lib_X11_XOpenDisplay = yes; then
12254 echo "$as_me:12254: checking for XCurses library" >&5
12255 echo $ECHO_N "checking for XCurses library... $ECHO_C" >&6
12256 if test "${cf_cv_lib_XCurses+set}" = set; then
12257 echo $ECHO_N "(cached) $ECHO_C" >&6
12260 LIBS="-lXCurses $LIBS"
12261 cat >conftest.$ac_ext <<_ACEOF
12262 #line 12262 "configure"
12263 #include "confdefs.h"
12265 #include <xcurses.h>
12266 char *XCursesProgramName = "test";
12276 rm -f conftest.$ac_objext conftest$ac_exeext
12277 if { (eval echo "$as_me:12277: \"$ac_link\"") >&5
12278 (eval $ac_link) 2>&5
12280 echo "$as_me:12280: \$? = $ac_status" >&5
12281 (exit $ac_status); } &&
12282 { ac_try='test -s conftest$ac_exeext'
12283 { (eval echo "$as_me:12283: \"$ac_try\"") >&5
12284 (eval $ac_try) 2>&5
12286 echo "$as_me:12286: \$? = $ac_status" >&5
12287 (exit $ac_status); }; }; then
12288 cf_cv_lib_XCurses=yes
12290 echo "$as_me: failed program was:" >&5
12291 cat conftest.$ac_ext >&5
12292 cf_cv_lib_XCurses=no
12294 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12297 echo "$as_me:12297: result: $cf_cv_lib_XCurses" >&5
12298 echo "${ECHO_T}$cf_cv_lib_XCurses" >&6
12302 if test $cf_cv_lib_XCurses = yes ; then
12303 cat >>confdefs.h <<\EOF
12307 cat >>confdefs.h <<\EOF
12311 echo "$as_me:12311: checking for xcurses.h" >&5
12312 echo $ECHO_N "checking for xcurses.h... $ECHO_C" >&6
12313 if test "${ac_cv_header_xcurses_h+set}" = set; then
12314 echo $ECHO_N "(cached) $ECHO_C" >&6
12316 cat >conftest.$ac_ext <<_ACEOF
12317 #line 12317 "configure"
12318 #include "confdefs.h"
12319 #include <xcurses.h>
12321 if { (eval echo "$as_me:12321: \"$ac_cpp conftest.$ac_ext\"") >&5
12322 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12324 egrep -v '^ *\+' conftest.er1 >conftest.err
12326 cat conftest.err >&5
12327 echo "$as_me:12327: \$? = $ac_status" >&5
12328 (exit $ac_status); } >/dev/null; then
12329 if test -s conftest.err; then
12330 ac_cpp_err=$ac_c_preproc_warn_flag
12337 if test -z "$ac_cpp_err"; then
12338 ac_cv_header_xcurses_h=yes
12340 echo "$as_me: failed program was:" >&5
12341 cat conftest.$ac_ext >&5
12342 ac_cv_header_xcurses_h=no
12344 rm -f conftest.err conftest.$ac_ext
12346 echo "$as_me:12346: result: $ac_cv_header_xcurses_h" >&5
12347 echo "${ECHO_T}$ac_cv_header_xcurses_h" >&6
12348 if test $ac_cv_header_xcurses_h = yes; then
12349 cat >>confdefs.h <<\EOF
12350 #define HAVE_XCURSES 1
12356 { { echo "$as_me:12356: error: Cannot link with XCurses" >&5
12357 echo "$as_me: error: Cannot link with XCurses" >&2;}
12358 { (exit 1); exit 1; }; }
12364 case $cf_cv_screen in #(vi
12368 # look for curses-related libraries
12370 as_ac_Lib=`echo "ac_cv_lib_panel$cf_cv_libtype''_new_panel" | $as_tr_sh`
12371 echo "$as_me:12371: checking for new_panel in -lpanel$cf_cv_libtype" >&5
12372 echo $ECHO_N "checking for new_panel in -lpanel$cf_cv_libtype... $ECHO_C" >&6
12373 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
12374 echo $ECHO_N "(cached) $ECHO_C" >&6
12376 ac_check_lib_save_LIBS=$LIBS
12377 LIBS="-lpanel$cf_cv_libtype $LIBS"
12378 cat >conftest.$ac_ext <<_ACEOF
12379 #line 12379 "configure"
12380 #include "confdefs.h"
12382 /* Override any gcc2 internal prototype to avoid an error. */
12386 /* We use char because int might match the return type of a gcc2
12387 builtin and then its argument prototype would still apply. */
12397 rm -f conftest.$ac_objext conftest$ac_exeext
12398 if { (eval echo "$as_me:12398: \"$ac_link\"") >&5
12399 (eval $ac_link) 2>&5
12401 echo "$as_me:12401: \$? = $ac_status" >&5
12402 (exit $ac_status); } &&
12403 { ac_try='test -s conftest$ac_exeext'
12404 { (eval echo "$as_me:12404: \"$ac_try\"") >&5
12405 (eval $ac_try) 2>&5
12407 echo "$as_me:12407: \$? = $ac_status" >&5
12408 (exit $ac_status); }; }; then
12409 eval "$as_ac_Lib=yes"
12411 echo "$as_me: failed program was:" >&5
12412 cat conftest.$ac_ext >&5
12413 eval "$as_ac_Lib=no"
12415 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12416 LIBS=$ac_check_lib_save_LIBS
12418 echo "$as_me:12418: result: `eval echo '${'$as_ac_Lib'}'`" >&5
12419 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
12420 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
12421 cat >>confdefs.h <<EOF
12422 #define `echo "HAVE_LIBpanel$cf_cv_libtype" | $as_tr_cpp` 1
12425 LIBS="-lpanel$cf_cv_libtype $LIBS"
12429 as_ac_Lib=`echo "ac_cv_lib_menu$cf_cv_libtype''_menu_driver" | $as_tr_sh`
12430 echo "$as_me:12430: checking for menu_driver in -lmenu$cf_cv_libtype" >&5
12431 echo $ECHO_N "checking for menu_driver in -lmenu$cf_cv_libtype... $ECHO_C" >&6
12432 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
12433 echo $ECHO_N "(cached) $ECHO_C" >&6
12435 ac_check_lib_save_LIBS=$LIBS
12436 LIBS="-lmenu$cf_cv_libtype $LIBS"
12437 cat >conftest.$ac_ext <<_ACEOF
12438 #line 12438 "configure"
12439 #include "confdefs.h"
12441 /* Override any gcc2 internal prototype to avoid an error. */
12445 /* We use char because int might match the return type of a gcc2
12446 builtin and then its argument prototype would still apply. */
12447 char menu_driver ();
12456 rm -f conftest.$ac_objext conftest$ac_exeext
12457 if { (eval echo "$as_me:12457: \"$ac_link\"") >&5
12458 (eval $ac_link) 2>&5
12460 echo "$as_me:12460: \$? = $ac_status" >&5
12461 (exit $ac_status); } &&
12462 { ac_try='test -s conftest$ac_exeext'
12463 { (eval echo "$as_me:12463: \"$ac_try\"") >&5
12464 (eval $ac_try) 2>&5
12466 echo "$as_me:12466: \$? = $ac_status" >&5
12467 (exit $ac_status); }; }; then
12468 eval "$as_ac_Lib=yes"
12470 echo "$as_me: failed program was:" >&5
12471 cat conftest.$ac_ext >&5
12472 eval "$as_ac_Lib=no"
12474 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12475 LIBS=$ac_check_lib_save_LIBS
12477 echo "$as_me:12477: result: `eval echo '${'$as_ac_Lib'}'`" >&5
12478 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
12479 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
12480 cat >>confdefs.h <<EOF
12481 #define `echo "HAVE_LIBmenu$cf_cv_libtype" | $as_tr_cpp` 1
12484 LIBS="-lmenu$cf_cv_libtype $LIBS"
12488 as_ac_Lib=`echo "ac_cv_lib_form$cf_cv_libtype''_form_driver" | $as_tr_sh`
12489 echo "$as_me:12489: checking for form_driver in -lform$cf_cv_libtype" >&5
12490 echo $ECHO_N "checking for form_driver in -lform$cf_cv_libtype... $ECHO_C" >&6
12491 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
12492 echo $ECHO_N "(cached) $ECHO_C" >&6
12494 ac_check_lib_save_LIBS=$LIBS
12495 LIBS="-lform$cf_cv_libtype $LIBS"
12496 cat >conftest.$ac_ext <<_ACEOF
12497 #line 12497 "configure"
12498 #include "confdefs.h"
12500 /* Override any gcc2 internal prototype to avoid an error. */
12504 /* We use char because int might match the return type of a gcc2
12505 builtin and then its argument prototype would still apply. */
12506 char form_driver ();
12515 rm -f conftest.$ac_objext conftest$ac_exeext
12516 if { (eval echo "$as_me:12516: \"$ac_link\"") >&5
12517 (eval $ac_link) 2>&5
12519 echo "$as_me:12519: \$? = $ac_status" >&5
12520 (exit $ac_status); } &&
12521 { ac_try='test -s conftest$ac_exeext'
12522 { (eval echo "$as_me:12522: \"$ac_try\"") >&5
12523 (eval $ac_try) 2>&5
12525 echo "$as_me:12525: \$? = $ac_status" >&5
12526 (exit $ac_status); }; }; then
12527 eval "$as_ac_Lib=yes"
12529 echo "$as_me: failed program was:" >&5
12530 cat conftest.$ac_ext >&5
12531 eval "$as_ac_Lib=no"
12533 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12534 LIBS=$ac_check_lib_save_LIBS
12536 echo "$as_me:12536: result: `eval echo '${'$as_ac_Lib'}'`" >&5
12537 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
12538 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
12539 cat >>confdefs.h <<EOF
12540 #define `echo "HAVE_LIBform$cf_cv_libtype" | $as_tr_cpp` 1
12543 LIBS="-lform$cf_cv_libtype $LIBS"
12547 # look for curses-related headers
12558 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12559 echo "$as_me:12559: checking for $ac_header" >&5
12560 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12561 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12562 echo $ECHO_N "(cached) $ECHO_C" >&6
12564 cat >conftest.$ac_ext <<_ACEOF
12565 #line 12565 "configure"
12566 #include "confdefs.h"
12567 #include <$ac_header>
12569 if { (eval echo "$as_me:12569: \"$ac_cpp conftest.$ac_ext\"") >&5
12570 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12572 egrep -v '^ *\+' conftest.er1 >conftest.err
12574 cat conftest.err >&5
12575 echo "$as_me:12575: \$? = $ac_status" >&5
12576 (exit $ac_status); } >/dev/null; then
12577 if test -s conftest.err; then
12578 ac_cpp_err=$ac_c_preproc_warn_flag
12585 if test -z "$ac_cpp_err"; then
12586 eval "$as_ac_Header=yes"
12588 echo "$as_me: failed program was:" >&5
12589 cat conftest.$ac_ext >&5
12590 eval "$as_ac_Header=no"
12592 rm -f conftest.err conftest.$ac_ext
12594 echo "$as_me:12594: result: `eval echo '${'$as_ac_Header'}'`" >&5
12595 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12596 if test `eval echo '${'$as_ac_Header'}'` = yes; then
12597 cat >>confdefs.h <<EOF
12598 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12607 echo "$as_me:12607: checking return type of signal handlers" >&5
12608 echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6
12609 if test "${ac_cv_type_signal+set}" = set; then
12610 echo $ECHO_N "(cached) $ECHO_C" >&6
12612 cat >conftest.$ac_ext <<_ACEOF
12613 #line 12613 "configure"
12614 #include "confdefs.h"
12615 #include <sys/types.h>
12616 #include <signal.h>
12621 extern "C" void (*signal (int, void (*)(int)))(int);
12623 void (*signal ()) ();
12634 rm -f conftest.$ac_objext
12635 if { (eval echo "$as_me:12635: \"$ac_compile\"") >&5
12636 (eval $ac_compile) 2>&5
12638 echo "$as_me:12638: \$? = $ac_status" >&5
12639 (exit $ac_status); } &&
12640 { ac_try='test -s conftest.$ac_objext'
12641 { (eval echo "$as_me:12641: \"$ac_try\"") >&5
12642 (eval $ac_try) 2>&5
12644 echo "$as_me:12644: \$? = $ac_status" >&5
12645 (exit $ac_status); }; }; then
12646 ac_cv_type_signal=void
12648 echo "$as_me: failed program was:" >&5
12649 cat conftest.$ac_ext >&5
12650 ac_cv_type_signal=int
12652 rm -f conftest.$ac_objext conftest.$ac_ext
12654 echo "$as_me:12654: result: $ac_cv_type_signal" >&5
12655 echo "${ECHO_T}$ac_cv_type_signal" >&6
12657 cat >>confdefs.h <<EOF
12658 #define RETSIGTYPE $ac_cv_type_signal
12661 echo "$as_me:12661: checking for ANSI C header files" >&5
12662 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
12663 if test "${ac_cv_header_stdc+set}" = set; then
12664 echo $ECHO_N "(cached) $ECHO_C" >&6
12666 cat >conftest.$ac_ext <<_ACEOF
12667 #line 12667 "configure"
12668 #include "confdefs.h"
12669 #include <stdlib.h>
12670 #include <stdarg.h>
12671 #include <string.h>
12675 if { (eval echo "$as_me:12675: \"$ac_cpp conftest.$ac_ext\"") >&5
12676 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12678 egrep -v '^ *\+' conftest.er1 >conftest.err
12680 cat conftest.err >&5
12681 echo "$as_me:12681: \$? = $ac_status" >&5
12682 (exit $ac_status); } >/dev/null; then
12683 if test -s conftest.err; then
12684 ac_cpp_err=$ac_c_preproc_warn_flag
12691 if test -z "$ac_cpp_err"; then
12692 ac_cv_header_stdc=yes
12694 echo "$as_me: failed program was:" >&5
12695 cat conftest.$ac_ext >&5
12696 ac_cv_header_stdc=no
12698 rm -f conftest.err conftest.$ac_ext
12700 if test $ac_cv_header_stdc = yes; then
12701 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
12702 cat >conftest.$ac_ext <<_ACEOF
12703 #line 12703 "configure"
12704 #include "confdefs.h"
12705 #include <string.h>
12708 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12709 egrep "memchr" >/dev/null 2>&1; then
12712 ac_cv_header_stdc=no
12718 if test $ac_cv_header_stdc = yes; then
12719 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
12720 cat >conftest.$ac_ext <<_ACEOF
12721 #line 12721 "configure"
12722 #include "confdefs.h"
12723 #include <stdlib.h>
12726 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12727 egrep "free" >/dev/null 2>&1; then
12730 ac_cv_header_stdc=no
12736 if test $ac_cv_header_stdc = yes; then
12737 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
12738 if test "$cross_compiling" = yes; then
12741 cat >conftest.$ac_ext <<_ACEOF
12742 #line 12742 "configure"
12743 #include "confdefs.h"
12745 #if ((' ' & 0x0FF) == 0x020)
12746 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
12747 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
12749 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
12750 || ('j' <= (c) && (c) <= 'r') \
12751 || ('s' <= (c) && (c) <= 'z'))
12752 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
12755 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
12760 for (i = 0; i < 256; i++)
12761 if (XOR (islower (i), ISLOWER (i))
12762 || toupper (i) != TOUPPER (i))
12763 $ac_main_return(2);
12764 $ac_main_return (0);
12767 rm -f conftest$ac_exeext
12768 if { (eval echo "$as_me:12768: \"$ac_link\"") >&5
12769 (eval $ac_link) 2>&5
12771 echo "$as_me:12771: \$? = $ac_status" >&5
12772 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
12773 { (eval echo "$as_me:12773: \"$ac_try\"") >&5
12774 (eval $ac_try) 2>&5
12776 echo "$as_me:12776: \$? = $ac_status" >&5
12777 (exit $ac_status); }; }; then
12780 echo "$as_me: program exited with status $ac_status" >&5
12781 echo "$as_me: failed program was:" >&5
12782 cat conftest.$ac_ext >&5
12783 ac_cv_header_stdc=no
12785 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
12789 echo "$as_me:12789: result: $ac_cv_header_stdc" >&5
12790 echo "${ECHO_T}$ac_cv_header_stdc" >&6
12791 if test $ac_cv_header_stdc = yes; then
12793 cat >>confdefs.h <<\EOF
12794 #define STDC_HEADERS 1
12799 echo "$as_me:12799: checking whether time.h and sys/time.h may both be included" >&5
12800 echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
12801 if test "${ac_cv_header_time+set}" = set; then
12802 echo $ECHO_N "(cached) $ECHO_C" >&6
12804 cat >conftest.$ac_ext <<_ACEOF
12805 #line 12805 "configure"
12806 #include "confdefs.h"
12807 #include <sys/types.h>
12808 #include <sys/time.h>
12814 if ((struct tm *) 0)
12820 rm -f conftest.$ac_objext
12821 if { (eval echo "$as_me:12821: \"$ac_compile\"") >&5
12822 (eval $ac_compile) 2>&5
12824 echo "$as_me:12824: \$? = $ac_status" >&5
12825 (exit $ac_status); } &&
12826 { ac_try='test -s conftest.$ac_objext'
12827 { (eval echo "$as_me:12827: \"$ac_try\"") >&5
12828 (eval $ac_try) 2>&5
12830 echo "$as_me:12830: \$? = $ac_status" >&5
12831 (exit $ac_status); }; }; then
12832 ac_cv_header_time=yes
12834 echo "$as_me: failed program was:" >&5
12835 cat conftest.$ac_ext >&5
12836 ac_cv_header_time=no
12838 rm -f conftest.$ac_objext conftest.$ac_ext
12840 echo "$as_me:12840: result: $ac_cv_header_time" >&5
12841 echo "${ECHO_T}$ac_cv_header_time" >&6
12842 if test $ac_cv_header_time = yes; then
12844 cat >>confdefs.h <<\EOF
12845 #define TIME_WITH_SYS_TIME 1
12862 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12863 echo "$as_me:12863: checking for $ac_header" >&5
12864 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12865 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12866 echo $ECHO_N "(cached) $ECHO_C" >&6
12868 cat >conftest.$ac_ext <<_ACEOF
12869 #line 12869 "configure"
12870 #include "confdefs.h"
12871 #include <$ac_header>
12873 if { (eval echo "$as_me:12873: \"$ac_cpp conftest.$ac_ext\"") >&5
12874 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12876 egrep -v '^ *\+' conftest.er1 >conftest.err
12878 cat conftest.err >&5
12879 echo "$as_me:12879: \$? = $ac_status" >&5
12880 (exit $ac_status); } >/dev/null; then
12881 if test -s conftest.err; then
12882 ac_cpp_err=$ac_c_preproc_warn_flag
12889 if test -z "$ac_cpp_err"; then
12890 eval "$as_ac_Header=yes"
12892 echo "$as_me: failed program was:" >&5
12893 cat conftest.$ac_ext >&5
12894 eval "$as_ac_Header=no"
12896 rm -f conftest.err conftest.$ac_ext
12898 echo "$as_me:12898: result: `eval echo '${'$as_ac_Header'}'`" >&5
12899 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12900 if test `eval echo '${'$as_ac_Header'}'` = yes; then
12901 cat >>confdefs.h <<EOF
12902 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12913 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12914 echo "$as_me:12914: checking for $ac_func" >&5
12915 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12916 if eval "test \"\${$as_ac_var+set}\" = set"; then
12917 echo $ECHO_N "(cached) $ECHO_C" >&6
12919 cat >conftest.$ac_ext <<_ACEOF
12920 #line 12920 "configure"
12921 #include "confdefs.h"
12922 /* System header to define __stub macros and hopefully few prototypes,
12923 which can conflict with char $ac_func (); below. */
12924 #include <assert.h>
12925 /* Override any gcc2 internal prototype to avoid an error. */
12929 /* We use char because int might match the return type of a gcc2
12930 builtin and then its argument prototype would still apply. */
12937 /* The GNU C library defines this for functions which it implements
12938 to always fail with ENOSYS. Some functions are actually named
12939 something starting with __ and the normal name is an alias. */
12940 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12950 rm -f conftest.$ac_objext conftest$ac_exeext
12951 if { (eval echo "$as_me:12951: \"$ac_link\"") >&5
12952 (eval $ac_link) 2>&5
12954 echo "$as_me:12954: \$? = $ac_status" >&5
12955 (exit $ac_status); } &&
12956 { ac_try='test -s conftest$ac_exeext'
12957 { (eval echo "$as_me:12957: \"$ac_try\"") >&5
12958 (eval $ac_try) 2>&5
12960 echo "$as_me:12960: \$? = $ac_status" >&5
12961 (exit $ac_status); }; }; then
12962 eval "$as_ac_var=yes"
12964 echo "$as_me: failed program was:" >&5
12965 cat conftest.$ac_ext >&5
12966 eval "$as_ac_var=no"
12968 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12970 echo "$as_me:12970: result: `eval echo '${'$as_ac_var'}'`" >&5
12971 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12972 if test `eval echo '${'$as_ac_var'}'` = yes; then
12973 cat >>confdefs.h <<EOF
12974 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12980 if test "$cf_enable_widec" = yes; then
12993 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12994 echo "$as_me:12994: checking for $ac_func" >&5
12995 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12996 if eval "test \"\${$as_ac_var+set}\" = set"; then
12997 echo $ECHO_N "(cached) $ECHO_C" >&6
12999 cat >conftest.$ac_ext <<_ACEOF
13000 #line 13000 "configure"
13001 #include "confdefs.h"
13002 /* System header to define __stub macros and hopefully few prototypes,
13003 which can conflict with char $ac_func (); below. */
13004 #include <assert.h>
13005 /* Override any gcc2 internal prototype to avoid an error. */
13009 /* We use char because int might match the return type of a gcc2
13010 builtin and then its argument prototype would still apply. */
13017 /* The GNU C library defines this for functions which it implements
13018 to always fail with ENOSYS. Some functions are actually named
13019 something starting with __ and the normal name is an alias. */
13020 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13030 rm -f conftest.$ac_objext conftest$ac_exeext
13031 if { (eval echo "$as_me:13031: \"$ac_link\"") >&5
13032 (eval $ac_link) 2>&5
13034 echo "$as_me:13034: \$? = $ac_status" >&5
13035 (exit $ac_status); } &&
13036 { ac_try='test -s conftest$ac_exeext'
13037 { (eval echo "$as_me:13037: \"$ac_try\"") >&5
13038 (eval $ac_try) 2>&5
13040 echo "$as_me:13040: \$? = $ac_status" >&5
13041 (exit $ac_status); }; }; then
13042 eval "$as_ac_var=yes"
13044 echo "$as_me: failed program was:" >&5
13045 cat conftest.$ac_ext >&5
13046 eval "$as_ac_var=no"
13048 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13050 echo "$as_me:13050: result: `eval echo '${'$as_ac_var'}'`" >&5
13051 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13052 if test `eval echo '${'$as_ac_var'}'` = yes; then
13053 cat >>confdefs.h <<EOF
13054 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13062 echo "$as_me:13062: checking if we must define _XOPEN_SOURCE_EXTENDED" >&5
13063 echo $ECHO_N "checking if we must define _XOPEN_SOURCE_EXTENDED... $ECHO_C" >&6
13064 if test "${cf_cv_need_xopen_extension+set}" = set; then
13065 echo $ECHO_N "(cached) $ECHO_C" >&6
13068 cat >conftest.$ac_ext <<_ACEOF
13069 #line 13069 "configure"
13070 #include "confdefs.h"
13072 #include <stdlib.h>
13073 #include <${cf_cv_ncurses_header:-curses.h}>
13078 #if defined(NCURSES_VERSION_PATCH)
13079 #if (NCURSES_VERSION_PATCH < 20100501) && (NCURSES_VERSION_PATCH >= 20100403)
13083 long x = winnstr(stdscr, "", 0);
13085 getbegyx(stdscr, y1, x1)
13090 rm -f conftest.$ac_objext conftest$ac_exeext
13091 if { (eval echo "$as_me:13091: \"$ac_link\"") >&5
13092 (eval $ac_link) 2>&5
13094 echo "$as_me:13094: \$? = $ac_status" >&5
13095 (exit $ac_status); } &&
13096 { ac_try='test -s conftest$ac_exeext'
13097 { (eval echo "$as_me:13097: \"$ac_try\"") >&5
13098 (eval $ac_try) 2>&5
13100 echo "$as_me:13100: \$? = $ac_status" >&5
13101 (exit $ac_status); }; }; then
13102 cf_cv_need_xopen_extension=no
13104 echo "$as_me: failed program was:" >&5
13105 cat conftest.$ac_ext >&5
13106 cat >conftest.$ac_ext <<_ACEOF
13107 #line 13107 "configure"
13108 #include "confdefs.h"
13110 #define _XOPEN_SOURCE_EXTENDED
13111 #include <stdlib.h>
13112 #include <${cf_cv_ncurses_header:-curses.h}>
13117 #ifdef NCURSES_VERSION
13119 int check2 = curs_set((int)sizeof(check));
13121 long x = winnstr(stdscr, "", 0);
13123 getbegyx(stdscr, y1, x1)
13128 rm -f conftest.$ac_objext conftest$ac_exeext
13129 if { (eval echo "$as_me:13129: \"$ac_link\"") >&5
13130 (eval $ac_link) 2>&5
13132 echo "$as_me:13132: \$? = $ac_status" >&5
13133 (exit $ac_status); } &&
13134 { ac_try='test -s conftest$ac_exeext'
13135 { (eval echo "$as_me:13135: \"$ac_try\"") >&5
13136 (eval $ac_try) 2>&5
13138 echo "$as_me:13138: \$? = $ac_status" >&5
13139 (exit $ac_status); }; }; then
13140 cf_cv_need_xopen_extension=yes
13142 echo "$as_me: failed program was:" >&5
13143 cat conftest.$ac_ext >&5
13144 cf_cv_need_xopen_extension=unknown
13146 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13148 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13150 echo "$as_me:13150: result: $cf_cv_need_xopen_extension" >&5
13151 echo "${ECHO_T}$cf_cv_need_xopen_extension" >&6
13152 test $cf_cv_need_xopen_extension = yes && CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE_EXTENDED"
13154 echo "$as_me:13154: checking for term.h" >&5
13155 echo $ECHO_N "checking for term.h... $ECHO_C" >&6
13156 if test "${cf_cv_term_header+set}" = set; then
13157 echo $ECHO_N "(cached) $ECHO_C" >&6
13160 # If we found <ncurses/curses.h>, look for <ncurses/term.h>, but always look
13161 # for <term.h> if we do not find the variant.
13163 cf_header_list="term.h ncurses/term.h ncursesw/term.h"
13165 case ${cf_cv_ncurses_header:-curses.h} in #(vi
13167 cf_header_item=`echo ${cf_cv_ncurses_header:-curses.h} | sed -e 's%\..*%%' -e 's%/.*%/%'`term.h
13168 cf_header_list="$cf_header_item $cf_header_list"
13172 for cf_header in $cf_header_list
13174 cat >conftest.$ac_ext <<_ACEOF
13175 #line 13175 "configure"
13176 #include "confdefs.h"
13178 #include <${cf_cv_ncurses_header:-curses.h}>
13179 #include <${cf_header}>
13188 rm -f conftest.$ac_objext
13189 if { (eval echo "$as_me:13189: \"$ac_compile\"") >&5
13190 (eval $ac_compile) 2>&5
13192 echo "$as_me:13192: \$? = $ac_status" >&5
13193 (exit $ac_status); } &&
13194 { ac_try='test -s conftest.$ac_objext'
13195 { (eval echo "$as_me:13195: \"$ac_try\"") >&5
13196 (eval $ac_try) 2>&5
13198 echo "$as_me:13198: \$? = $ac_status" >&5
13199 (exit $ac_status); }; }; then
13200 cf_cv_term_header=$cf_header
13203 echo "$as_me: failed program was:" >&5
13204 cat conftest.$ac_ext >&5
13205 cf_cv_term_header=no
13207 rm -f conftest.$ac_objext conftest.$ac_ext
13210 case $cf_cv_term_header in #(vi
13212 # If curses is ncurses, some packagers still mess it up by trying to make
13213 # us use GNU termcap. This handles the most common case.
13214 for cf_header in ncurses/term.h ncursesw/term.h
13216 cat >conftest.$ac_ext <<_ACEOF
13217 #line 13217 "configure"
13218 #include "confdefs.h"
13220 #include <${cf_cv_ncurses_header:-curses.h}>
13221 #ifdef NCURSES_VERSION
13222 #include <${cf_header}>
13234 rm -f conftest.$ac_objext
13235 if { (eval echo "$as_me:13235: \"$ac_compile\"") >&5
13236 (eval $ac_compile) 2>&5
13238 echo "$as_me:13238: \$? = $ac_status" >&5
13239 (exit $ac_status); } &&
13240 { ac_try='test -s conftest.$ac_objext'
13241 { (eval echo "$as_me:13241: \"$ac_try\"") >&5
13242 (eval $ac_try) 2>&5
13244 echo "$as_me:13244: \$? = $ac_status" >&5
13245 (exit $ac_status); }; }; then
13246 cf_cv_term_header=$cf_header
13249 echo "$as_me: failed program was:" >&5
13250 cat conftest.$ac_ext >&5
13251 cf_cv_term_header=no
13253 rm -f conftest.$ac_objext conftest.$ac_ext
13259 echo "$as_me:13259: result: $cf_cv_term_header" >&5
13260 echo "${ECHO_T}$cf_cv_term_header" >&6
13262 case $cf_cv_term_header in #(vi
13264 cat >>confdefs.h <<\EOF
13265 #define HAVE_TERM_H 1
13269 ncurses/term.h) #(vi
13270 cat >>confdefs.h <<\EOF
13271 #define HAVE_NCURSES_TERM_H 1
13276 cat >>confdefs.h <<\EOF
13277 #define HAVE_NCURSESW_TERM_H 1
13283 echo "$as_me:13283: checking for unctrl.h" >&5
13284 echo $ECHO_N "checking for unctrl.h... $ECHO_C" >&6
13285 if test "${cf_cv_unctrl_header+set}" = set; then
13286 echo $ECHO_N "(cached) $ECHO_C" >&6
13289 # If we found <ncurses/curses.h>, look for <ncurses/unctrl.h>, but always look
13290 # for <unctrl.h> if we do not find the variant.
13292 cf_header_list="unctrl.h ncurses/unctrl.h ncursesw/unctrl.h"
13294 case ${cf_cv_ncurses_header:-curses.h} in #(vi
13296 cf_header_item=`echo ${cf_cv_ncurses_header:-curses.h} | sed -e 's%\..*%%' -e 's%/.*%/%'`unctrl.h
13297 cf_header_list="$cf_header_item $cf_header_list"
13301 for cf_header in $cf_header_list
13303 cat >conftest.$ac_ext <<_ACEOF
13304 #line 13304 "configure"
13305 #include "confdefs.h"
13307 #include <${cf_cv_ncurses_header:-curses.h}>
13308 #include <${cf_header}>
13317 rm -f conftest.$ac_objext
13318 if { (eval echo "$as_me:13318: \"$ac_compile\"") >&5
13319 (eval $ac_compile) 2>&5
13321 echo "$as_me:13321: \$? = $ac_status" >&5
13322 (exit $ac_status); } &&
13323 { ac_try='test -s conftest.$ac_objext'
13324 { (eval echo "$as_me:13324: \"$ac_try\"") >&5
13325 (eval $ac_try) 2>&5
13327 echo "$as_me:13327: \$? = $ac_status" >&5
13328 (exit $ac_status); }; }; then
13329 cf_cv_unctrl_header=$cf_header
13332 echo "$as_me: failed program was:" >&5
13333 cat conftest.$ac_ext >&5
13334 cf_cv_unctrl_header=no
13336 rm -f conftest.$ac_objext conftest.$ac_ext
13339 case $cf_cv_unctrl_header in #(vi
13341 { echo "$as_me:13341: WARNING: unctrl.h header not found" >&5
13342 echo "$as_me: WARNING: unctrl.h header not found" >&2;}
13347 echo "$as_me:13347: result: $cf_cv_unctrl_header" >&5
13348 echo "${ECHO_T}$cf_cv_unctrl_header" >&6
13350 case $cf_cv_unctrl_header in #(vi
13352 cat >>confdefs.h <<\EOF
13353 #define HAVE_UNCTRL_H 1
13357 ncurses/unctrl.h) #(vi
13358 cat >>confdefs.h <<\EOF
13359 #define HAVE_NCURSES_UNCTRL_H 1
13364 cat >>confdefs.h <<\EOF
13365 #define HAVE_NCURSESW_UNCTRL_H 1
13397 use_default_colors \
13407 cf_tr_func=`echo "$cf_func" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
13409 echo "$as_me:13409: checking for ${cf_func}" >&5
13410 echo $ECHO_N "checking for ${cf_func}... $ECHO_C" >&6
13412 echo "${as_me:-configure}:13412: testing ${cf_func} ..." 1>&5
13414 if eval "test \"\${cf_cv_func_$cf_func+set}\" = set"; then
13415 echo $ECHO_N "(cached) $ECHO_C" >&6
13418 eval cf_result='$ac_cv_func_'$cf_func
13419 if test ".$cf_result" != ".no"; then
13420 cat >conftest.$ac_ext <<_ACEOF
13421 #line 13421 "configure"
13422 #include "confdefs.h"
13424 #ifdef HAVE_XCURSES
13425 #include <xcurses.h>
13426 char * XCursesProgramName = "test";
13428 #include <${cf_cv_ncurses_header:-curses.h}>
13429 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
13430 #include <ncursesw/term.h>
13431 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
13432 #include <ncurses/term.h>
13433 #elif defined(HAVE_TERM_H)
13443 long foo = (long)(&${cf_func});
13444 ${cf_cv_main_return:-return}(foo == 0);
13451 rm -f conftest.$ac_objext conftest$ac_exeext
13452 if { (eval echo "$as_me:13452: \"$ac_link\"") >&5
13453 (eval $ac_link) 2>&5
13455 echo "$as_me:13455: \$? = $ac_status" >&5
13456 (exit $ac_status); } &&
13457 { ac_try='test -s conftest$ac_exeext'
13458 { (eval echo "$as_me:13458: \"$ac_try\"") >&5
13459 (eval $ac_try) 2>&5
13461 echo "$as_me:13461: \$? = $ac_status" >&5
13462 (exit $ac_status); }; }; then
13465 echo "$as_me: failed program was:" >&5
13466 cat conftest.$ac_ext >&5
13469 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13471 eval 'cf_cv_func_'$cf_func'=$cf_result'
13475 # use the computed/retrieved cache-value:
13476 eval 'cf_result=$cf_cv_func_'$cf_func
13477 echo "$as_me:13477: result: $cf_result" >&5
13478 echo "${ECHO_T}$cf_result" >&6
13479 if test $cf_result != no; then
13480 cat >>confdefs.h <<EOF
13481 #define HAVE_${cf_tr_func} 1
13487 echo "$as_me:13487: checking for ncurses extended functions" >&5
13488 echo $ECHO_N "checking for ncurses extended functions... $ECHO_C" >&6
13489 if test "${cf_cv_ncurses_ext_funcs+set}" = set; then
13490 echo $ECHO_N "(cached) $ECHO_C" >&6
13493 cat >conftest.$ac_ext <<_ACEOF
13494 #line 13494 "configure"
13495 #include "confdefs.h"
13497 #include <${cf_cv_ncurses_header:-curses.h}>
13502 int x = NCURSES_EXT_FUNCS
13508 rm -f conftest.$ac_objext
13509 if { (eval echo "$as_me:13509: \"$ac_compile\"") >&5
13510 (eval $ac_compile) 2>&5
13512 echo "$as_me:13512: \$? = $ac_status" >&5
13513 (exit $ac_status); } &&
13514 { ac_try='test -s conftest.$ac_objext'
13515 { (eval echo "$as_me:13515: \"$ac_try\"") >&5
13516 (eval $ac_try) 2>&5
13518 echo "$as_me:13518: \$? = $ac_status" >&5
13519 (exit $ac_status); }; }; then
13520 cf_cv_ncurses_ext_funcs=defined
13522 echo "$as_me: failed program was:" >&5
13523 cat conftest.$ac_ext >&5
13525 cat >conftest.$ac_ext <<_ACEOF
13526 #line 13526 "configure"
13527 #include "confdefs.h"
13529 #include <${cf_cv_ncurses_header:-curses.h}>
13534 (void) assume_default_colors (0, 0);
13535 (void) curses_version ();
13536 (void) define_key (0, 0);
13537 (void) is_term_resized (0, 0);
13538 (void) key_defined (0);
13539 (void) keybound (0, 0);
13540 (void) keyok (0, 0);
13541 (void) resize_term (0, 0);
13542 (void) resizeterm (0, 0);
13543 (void) use_default_colors ();
13544 (void) use_extended_names (0);
13545 (void) wresize (0, 0, 0);
13550 rm -f conftest.$ac_objext conftest$ac_exeext
13551 if { (eval echo "$as_me:13551: \"$ac_link\"") >&5
13552 (eval $ac_link) 2>&5
13554 echo "$as_me:13554: \$? = $ac_status" >&5
13555 (exit $ac_status); } &&
13556 { ac_try='test -s conftest$ac_exeext'
13557 { (eval echo "$as_me:13557: \"$ac_try\"") >&5
13558 (eval $ac_try) 2>&5
13560 echo "$as_me:13560: \$? = $ac_status" >&5
13561 (exit $ac_status); }; }; then
13562 cf_cv_ncurses_ext_funcs=yes
13564 echo "$as_me: failed program was:" >&5
13565 cat conftest.$ac_ext >&5
13566 cf_cv_ncurses_ext_funcs=no
13568 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13571 rm -f conftest.$ac_objext conftest.$ac_ext
13574 echo "$as_me:13574: result: $cf_cv_ncurses_ext_funcs" >&5
13575 echo "${ECHO_T}$cf_cv_ncurses_ext_funcs" >&6
13576 test "$cf_cv_ncurses_ext_funcs" = yes && cat >>confdefs.h <<\EOF
13577 #define NCURSES_EXT_FUNCS 1
13580 if test "$cf_enable_widec" = yes
13582 echo "$as_me:13582: checking for wide-character functions" >&5
13583 echo $ECHO_N "checking for wide-character functions... $ECHO_C" >&6
13584 if test "${cf_cv_widechar_funcs+set}" = set; then
13585 echo $ECHO_N "(cached) $ECHO_C" >&6
13588 cat >conftest.$ac_ext <<_ACEOF
13589 #line 13589 "configure"
13590 #include "confdefs.h"
13592 #include <${cf_cv_ncurses_header:-curses.h}>
13597 static wchar_t src_wchar[2];
13598 static cchar_t dst_cchar;
13599 setcchar(&dst_cchar, src_wchar, A_NORMAL, 0, (void *) 0);
13605 rm -f conftest.$ac_objext conftest$ac_exeext
13606 if { (eval echo "$as_me:13606: \"$ac_link\"") >&5
13607 (eval $ac_link) 2>&5
13609 echo "$as_me:13609: \$? = $ac_status" >&5
13610 (exit $ac_status); } &&
13611 { ac_try='test -s conftest$ac_exeext'
13612 { (eval echo "$as_me:13612: \"$ac_try\"") >&5
13613 (eval $ac_try) 2>&5
13615 echo "$as_me:13615: \$? = $ac_status" >&5
13616 (exit $ac_status); }; }; then
13617 cf_cv_widechar_funcs=yes
13619 echo "$as_me: failed program was:" >&5
13620 cat conftest.$ac_ext >&5
13621 cf_cv_widechar_funcs=no
13623 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13626 echo "$as_me:13626: result: $cf_cv_widechar_funcs" >&5
13627 echo "${ECHO_T}$cf_cv_widechar_funcs" >&6
13628 if test "$cf_cv_widechar_funcs" != no ; then
13629 cat >>confdefs.h <<\EOF
13630 #define USE_WIDEC_SUPPORT 1
13634 cat >>confdefs.h <<\EOF
13635 #define USE_WIDEC_SUPPORT 0
13640 cat >>confdefs.h <<\EOF
13641 #define USE_WIDEC_SUPPORT 0
13646 echo "$as_me:13646: checking if sys/time.h works with sys/select.h" >&5
13647 echo $ECHO_N "checking if sys/time.h works with sys/select.h... $ECHO_C" >&6
13648 if test "${cf_cv_sys_time_select+set}" = set; then
13649 echo $ECHO_N "(cached) $ECHO_C" >&6
13652 cat >conftest.$ac_ext <<_ACEOF
13653 #line 13653 "configure"
13654 #include "confdefs.h"
13656 #include <sys/types.h>
13657 #ifdef HAVE_SYS_TIME_H
13658 #include <sys/time.h>
13660 #ifdef HAVE_SYS_SELECT_H
13661 #include <sys/select.h>
13672 rm -f conftest.$ac_objext
13673 if { (eval echo "$as_me:13673: \"$ac_compile\"") >&5
13674 (eval $ac_compile) 2>&5
13676 echo "$as_me:13676: \$? = $ac_status" >&5
13677 (exit $ac_status); } &&
13678 { ac_try='test -s conftest.$ac_objext'
13679 { (eval echo "$as_me:13679: \"$ac_try\"") >&5
13680 (eval $ac_try) 2>&5
13682 echo "$as_me:13682: \$? = $ac_status" >&5
13683 (exit $ac_status); }; }; then
13684 cf_cv_sys_time_select=yes
13686 echo "$as_me: failed program was:" >&5
13687 cat conftest.$ac_ext >&5
13688 cf_cv_sys_time_select=no
13690 rm -f conftest.$ac_objext conftest.$ac_ext
13694 echo "$as_me:13694: result: $cf_cv_sys_time_select" >&5
13695 echo "${ECHO_T}$cf_cv_sys_time_select" >&6
13696 test "$cf_cv_sys_time_select" = yes && cat >>confdefs.h <<\EOF
13697 #define HAVE_SYS_TIME_SELECT 1
13700 echo "$as_me:13700: checking for function curses_version" >&5
13701 echo $ECHO_N "checking for function curses_version... $ECHO_C" >&6
13702 if test "${cf_cv_func_curses_version+set}" = set; then
13703 echo $ECHO_N "(cached) $ECHO_C" >&6
13706 if test "$cross_compiling" = yes; then
13707 cf_cv_func_curses_version=unknown
13709 cat >conftest.$ac_ext <<_ACEOF
13710 #line 13710 "configure"
13711 #include "confdefs.h"
13713 #include <${cf_cv_ncurses_header:-curses.h}>
13717 sprintf(temp, "%s\n", curses_version());
13718 ${cf_cv_main_return:-return}(0);
13722 rm -f conftest$ac_exeext
13723 if { (eval echo "$as_me:13723: \"$ac_link\"") >&5
13724 (eval $ac_link) 2>&5
13726 echo "$as_me:13726: \$? = $ac_status" >&5
13727 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13728 { (eval echo "$as_me:13728: \"$ac_try\"") >&5
13729 (eval $ac_try) 2>&5
13731 echo "$as_me:13731: \$? = $ac_status" >&5
13732 (exit $ac_status); }; }; then
13733 cf_cv_func_curses_version=yes
13736 echo "$as_me: program exited with status $ac_status" >&5
13737 echo "$as_me: failed program was:" >&5
13738 cat conftest.$ac_ext >&5
13739 cf_cv_func_curses_version=no
13742 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13746 echo "$as_me:13746: result: $cf_cv_func_curses_version" >&5
13747 echo "${ECHO_T}$cf_cv_func_curses_version" >&6
13748 test "$cf_cv_func_curses_version" = yes && cat >>confdefs.h <<\EOF
13749 #define HAVE_CURSES_VERSION 1
13752 echo "$as_me:13752: checking for ncurses wrap-prefix" >&5
13753 echo $ECHO_N "checking for ncurses wrap-prefix... $ECHO_C" >&6
13755 # Check whether --with-ncurses-wrap-prefix or --without-ncurses-wrap-prefix was given.
13756 if test "${with_ncurses_wrap_prefix+set}" = set; then
13757 withval="$with_ncurses_wrap_prefix"
13758 NCURSES_WRAP_PREFIX=$withval
13760 NCURSES_WRAP_PREFIX=_nc_
13762 echo "$as_me:13762: result: $NCURSES_WRAP_PREFIX" >&5
13763 echo "${ECHO_T}$NCURSES_WRAP_PREFIX" >&6
13765 echo "$as_me:13765: checking for alternate character set array" >&5
13766 echo $ECHO_N "checking for alternate character set array... $ECHO_C" >&6
13767 if test "${cf_cv_curses_acs_map+set}" = set; then
13768 echo $ECHO_N "(cached) $ECHO_C" >&6
13771 cf_cv_curses_acs_map=unknown
13772 for name in acs_map _acs_map __acs_map ${NCURSES_WRAP_PREFIX}acs_map
13774 cat >conftest.$ac_ext <<_ACEOF
13775 #line 13775 "configure"
13776 #include "confdefs.h"
13778 #include <${cf_cv_ncurses_header:-curses.h}>
13784 $name['k'] = ACS_PLUS
13790 rm -f conftest.$ac_objext conftest$ac_exeext
13791 if { (eval echo "$as_me:13791: \"$ac_link\"") >&5
13792 (eval $ac_link) 2>&5
13794 echo "$as_me:13794: \$? = $ac_status" >&5
13795 (exit $ac_status); } &&
13796 { ac_try='test -s conftest$ac_exeext'
13797 { (eval echo "$as_me:13797: \"$ac_try\"") >&5
13798 (eval $ac_try) 2>&5
13800 echo "$as_me:13800: \$? = $ac_status" >&5
13801 (exit $ac_status); }; }; then
13802 cf_cv_curses_acs_map=$name; break
13804 echo "$as_me: failed program was:" >&5
13805 cat conftest.$ac_ext >&5
13807 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13811 echo "$as_me:13811: result: $cf_cv_curses_acs_map" >&5
13812 echo "${ECHO_T}$cf_cv_curses_acs_map" >&6
13814 test "$cf_cv_curses_acs_map" != unknown && cat >>confdefs.h <<EOF
13815 #define CURSES_ACS_ARRAY $cf_cv_curses_acs_map
13818 if test "$cf_enable_widec" = yes; then
13820 echo "$as_me:13820: checking for wide alternate character set array" >&5
13821 echo $ECHO_N "checking for wide alternate character set array... $ECHO_C" >&6
13822 if test "${cf_cv_curses_wacs_map+set}" = set; then
13823 echo $ECHO_N "(cached) $ECHO_C" >&6
13826 cf_cv_curses_wacs_map=unknown
13827 for name in wacs_map _wacs_map __wacs_map _nc_wacs _wacs_char
13829 cat >conftest.$ac_ext <<_ACEOF
13830 #line 13830 "configure"
13831 #include "confdefs.h"
13833 #ifndef _XOPEN_SOURCE_EXTENDED
13834 #define _XOPEN_SOURCE_EXTENDED
13836 #include <${cf_cv_ncurses_header:-curses.h}>
13840 void *foo = &($name['k'])
13845 rm -f conftest.$ac_objext conftest$ac_exeext
13846 if { (eval echo "$as_me:13846: \"$ac_link\"") >&5
13847 (eval $ac_link) 2>&5
13849 echo "$as_me:13849: \$? = $ac_status" >&5
13850 (exit $ac_status); } &&
13851 { ac_try='test -s conftest$ac_exeext'
13852 { (eval echo "$as_me:13852: \"$ac_try\"") >&5
13853 (eval $ac_try) 2>&5
13855 echo "$as_me:13855: \$? = $ac_status" >&5
13856 (exit $ac_status); }; }; then
13857 cf_cv_curses_wacs_map=$name
13860 echo "$as_me: failed program was:" >&5
13861 cat conftest.$ac_ext >&5
13863 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13866 echo "$as_me:13866: result: $cf_cv_curses_wacs_map" >&5
13867 echo "${ECHO_T}$cf_cv_curses_wacs_map" >&6
13869 test "$cf_cv_curses_wacs_map" != unknown && cat >>confdefs.h <<EOF
13870 #define CURSES_WACS_ARRAY $cf_cv_curses_wacs_map
13873 echo "$as_me:13873: checking for wide alternate character constants" >&5
13874 echo $ECHO_N "checking for wide alternate character constants... $ECHO_C" >&6
13875 if test "${cf_cv_curses_wacs_symbols+set}" = set; then
13876 echo $ECHO_N "(cached) $ECHO_C" >&6
13879 cf_cv_curses_wacs_symbols=no
13880 if test "$cf_cv_curses_wacs_map" != unknown
13882 cat >conftest.$ac_ext <<_ACEOF
13883 #line 13883 "configure"
13884 #include "confdefs.h"
13886 #ifndef _XOPEN_SOURCE_EXTENDED
13887 #define _XOPEN_SOURCE_EXTENDED
13889 #include <${cf_cv_ncurses_header:-curses.h}>
13893 cchar_t *foo = WACS_PLUS;
13894 $cf_cv_curses_wacs_map['k'] = *WACS_PLUS
13899 rm -f conftest.$ac_objext conftest$ac_exeext
13900 if { (eval echo "$as_me:13900: \"$ac_link\"") >&5
13901 (eval $ac_link) 2>&5
13903 echo "$as_me:13903: \$? = $ac_status" >&5
13904 (exit $ac_status); } &&
13905 { ac_try='test -s conftest$ac_exeext'
13906 { (eval echo "$as_me:13906: \"$ac_try\"") >&5
13907 (eval $ac_try) 2>&5
13909 echo "$as_me:13909: \$? = $ac_status" >&5
13910 (exit $ac_status); }; }; then
13911 cf_cv_curses_wacs_symbols=yes
13913 echo "$as_me: failed program was:" >&5
13914 cat conftest.$ac_ext >&5
13916 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13918 cat >conftest.$ac_ext <<_ACEOF
13919 #line 13919 "configure"
13920 #include "confdefs.h"
13922 #ifndef _XOPEN_SOURCE_EXTENDED
13923 #define _XOPEN_SOURCE_EXTENDED
13925 #include <${cf_cv_ncurses_header:-curses.h}>
13929 cchar_t *foo = WACS_PLUS
13934 rm -f conftest.$ac_objext conftest$ac_exeext
13935 if { (eval echo "$as_me:13935: \"$ac_link\"") >&5
13936 (eval $ac_link) 2>&5
13938 echo "$as_me:13938: \$? = $ac_status" >&5
13939 (exit $ac_status); } &&
13940 { ac_try='test -s conftest$ac_exeext'
13941 { (eval echo "$as_me:13941: \"$ac_try\"") >&5
13942 (eval $ac_try) 2>&5
13944 echo "$as_me:13944: \$? = $ac_status" >&5
13945 (exit $ac_status); }; }; then
13946 cf_cv_curses_wacs_symbols=yes
13948 echo "$as_me: failed program was:" >&5
13949 cat conftest.$ac_ext >&5
13951 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13955 echo "$as_me:13955: result: $cf_cv_curses_wacs_symbols" >&5
13956 echo "${ECHO_T}$cf_cv_curses_wacs_symbols" >&6
13958 test "$cf_cv_curses_wacs_symbols" != no && cat >>confdefs.h <<\EOF
13959 #define CURSES_WACS_SYMBOLS 1
13964 echo "$as_me:13964: checking for type attr_t in ${cf_cv_ncurses_header:-curses.h}" >&5
13965 echo $ECHO_N "checking for type attr_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
13966 cat >conftest.$ac_ext <<_ACEOF
13967 #line 13967 "configure"
13968 #include "confdefs.h"
13970 #ifndef _XOPEN_SOURCE_EXTENDED
13971 #define _XOPEN_SOURCE_EXTENDED
13973 #include <${cf_cv_ncurses_header:-curses.h}>
13984 rm -f conftest.$ac_objext
13985 if { (eval echo "$as_me:13985: \"$ac_compile\"") >&5
13986 (eval $ac_compile) 2>&5
13988 echo "$as_me:13988: \$? = $ac_status" >&5
13989 (exit $ac_status); } &&
13990 { ac_try='test -s conftest.$ac_objext'
13991 { (eval echo "$as_me:13991: \"$ac_try\"") >&5
13992 (eval $ac_try) 2>&5
13994 echo "$as_me:13994: \$? = $ac_status" >&5
13995 (exit $ac_status); }; }; then
13998 echo "$as_me: failed program was:" >&5
13999 cat conftest.$ac_ext >&5
14002 rm -f conftest.$ac_objext conftest.$ac_ext
14003 echo "$as_me:14003: result: $cf_result" >&5
14004 echo "${ECHO_T}$cf_result" >&6
14005 if test $cf_result = yes ; then
14007 cf_result=`echo "have_type_attr_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14009 cat >>confdefs.h <<EOF
14010 #define $cf_result 1
14014 cat >>confdefs.h <<EOF
14015 #define attr_t long
14020 if test "$cf_enable_widec" = yes; then
14022 # This is needed on Tru64 5.0 to declare mbstate_t
14023 echo "$as_me:14023: checking if we must include wchar.h to declare mbstate_t" >&5
14024 echo $ECHO_N "checking if we must include wchar.h to declare mbstate_t... $ECHO_C" >&6
14025 if test "${cf_cv_mbstate_t+set}" = set; then
14026 echo $ECHO_N "(cached) $ECHO_C" >&6
14029 cat >conftest.$ac_ext <<_ACEOF
14030 #line 14030 "configure"
14031 #include "confdefs.h"
14033 #include <stdlib.h>
14034 #include <stdarg.h>
14036 #ifdef HAVE_LIBUTF8_H
14037 #include <libutf8.h>
14047 rm -f conftest.$ac_objext
14048 if { (eval echo "$as_me:14048: \"$ac_compile\"") >&5
14049 (eval $ac_compile) 2>&5
14051 echo "$as_me:14051: \$? = $ac_status" >&5
14052 (exit $ac_status); } &&
14053 { ac_try='test -s conftest.$ac_objext'
14054 { (eval echo "$as_me:14054: \"$ac_try\"") >&5
14055 (eval $ac_try) 2>&5
14057 echo "$as_me:14057: \$? = $ac_status" >&5
14058 (exit $ac_status); }; }; then
14061 echo "$as_me: failed program was:" >&5
14062 cat conftest.$ac_ext >&5
14063 cat >conftest.$ac_ext <<_ACEOF
14064 #line 14064 "configure"
14065 #include "confdefs.h"
14067 #include <stdlib.h>
14068 #include <stdarg.h>
14071 #ifdef HAVE_LIBUTF8_H
14072 #include <libutf8.h>
14082 rm -f conftest.$ac_objext
14083 if { (eval echo "$as_me:14083: \"$ac_compile\"") >&5
14084 (eval $ac_compile) 2>&5
14086 echo "$as_me:14086: \$? = $ac_status" >&5
14087 (exit $ac_status); } &&
14088 { ac_try='test -s conftest.$ac_objext'
14089 { (eval echo "$as_me:14089: \"$ac_try\"") >&5
14090 (eval $ac_try) 2>&5
14092 echo "$as_me:14092: \$? = $ac_status" >&5
14093 (exit $ac_status); }; }; then
14094 cf_cv_mbstate_t=yes
14096 echo "$as_me: failed program was:" >&5
14097 cat conftest.$ac_ext >&5
14098 cf_cv_mbstate_t=unknown
14100 rm -f conftest.$ac_objext conftest.$ac_ext
14102 rm -f conftest.$ac_objext conftest.$ac_ext
14104 echo "$as_me:14104: result: $cf_cv_mbstate_t" >&5
14105 echo "${ECHO_T}$cf_cv_mbstate_t" >&6
14107 if test "$cf_cv_mbstate_t" = yes ; then
14108 cat >>confdefs.h <<\EOF
14109 #define NEED_WCHAR_H 1
14115 # if we do not find mbstate_t in either place, use substitution to provide a fallback.
14116 if test "$cf_cv_mbstate_t" = unknown ; then
14117 NCURSES_MBSTATE_T=1
14120 # if we find mbstate_t in either place, use substitution to provide a fallback.
14121 if test "$cf_cv_mbstate_t" != unknown ; then
14122 NCURSES_OK_MBSTATE_T=1
14125 # This is needed on Tru64 5.0 to declare wchar_t
14126 echo "$as_me:14126: checking if we must include wchar.h to declare wchar_t" >&5
14127 echo $ECHO_N "checking if we must include wchar.h to declare wchar_t... $ECHO_C" >&6
14128 if test "${cf_cv_wchar_t+set}" = set; then
14129 echo $ECHO_N "(cached) $ECHO_C" >&6
14132 cat >conftest.$ac_ext <<_ACEOF
14133 #line 14133 "configure"
14134 #include "confdefs.h"
14136 #include <stdlib.h>
14137 #include <stdarg.h>
14139 #ifdef HAVE_LIBUTF8_H
14140 #include <libutf8.h>
14150 rm -f conftest.$ac_objext
14151 if { (eval echo "$as_me:14151: \"$ac_compile\"") >&5
14152 (eval $ac_compile) 2>&5
14154 echo "$as_me:14154: \$? = $ac_status" >&5
14155 (exit $ac_status); } &&
14156 { ac_try='test -s conftest.$ac_objext'
14157 { (eval echo "$as_me:14157: \"$ac_try\"") >&5
14158 (eval $ac_try) 2>&5
14160 echo "$as_me:14160: \$? = $ac_status" >&5
14161 (exit $ac_status); }; }; then
14164 echo "$as_me: failed program was:" >&5
14165 cat conftest.$ac_ext >&5
14166 cat >conftest.$ac_ext <<_ACEOF
14167 #line 14167 "configure"
14168 #include "confdefs.h"
14170 #include <stdlib.h>
14171 #include <stdarg.h>
14174 #ifdef HAVE_LIBUTF8_H
14175 #include <libutf8.h>
14185 rm -f conftest.$ac_objext
14186 if { (eval echo "$as_me:14186: \"$ac_compile\"") >&5
14187 (eval $ac_compile) 2>&5
14189 echo "$as_me:14189: \$? = $ac_status" >&5
14190 (exit $ac_status); } &&
14191 { ac_try='test -s conftest.$ac_objext'
14192 { (eval echo "$as_me:14192: \"$ac_try\"") >&5
14193 (eval $ac_try) 2>&5
14195 echo "$as_me:14195: \$? = $ac_status" >&5
14196 (exit $ac_status); }; }; then
14199 echo "$as_me: failed program was:" >&5
14200 cat conftest.$ac_ext >&5
14201 cf_cv_wchar_t=unknown
14203 rm -f conftest.$ac_objext conftest.$ac_ext
14205 rm -f conftest.$ac_objext conftest.$ac_ext
14207 echo "$as_me:14207: result: $cf_cv_wchar_t" >&5
14208 echo "${ECHO_T}$cf_cv_wchar_t" >&6
14210 if test "$cf_cv_wchar_t" = yes ; then
14211 cat >>confdefs.h <<\EOF
14212 #define NEED_WCHAR_H 1
14218 # if we do not find wchar_t in either place, use substitution to provide a fallback.
14219 if test "$cf_cv_wchar_t" = unknown ; then
14223 # if we find wchar_t in either place, use substitution to provide a fallback.
14224 if test "$cf_cv_wchar_t" != unknown ; then
14225 NCURSES_OK_WCHAR_T=1
14228 # This is needed on Tru64 5.0 to declare wint_t
14229 echo "$as_me:14229: checking if we must include wchar.h to declare wint_t" >&5
14230 echo $ECHO_N "checking if we must include wchar.h to declare wint_t... $ECHO_C" >&6
14231 if test "${cf_cv_wint_t+set}" = set; then
14232 echo $ECHO_N "(cached) $ECHO_C" >&6
14235 cat >conftest.$ac_ext <<_ACEOF
14236 #line 14236 "configure"
14237 #include "confdefs.h"
14239 #include <stdlib.h>
14240 #include <stdarg.h>
14242 #ifdef HAVE_LIBUTF8_H
14243 #include <libutf8.h>
14253 rm -f conftest.$ac_objext
14254 if { (eval echo "$as_me:14254: \"$ac_compile\"") >&5
14255 (eval $ac_compile) 2>&5
14257 echo "$as_me:14257: \$? = $ac_status" >&5
14258 (exit $ac_status); } &&
14259 { ac_try='test -s conftest.$ac_objext'
14260 { (eval echo "$as_me:14260: \"$ac_try\"") >&5
14261 (eval $ac_try) 2>&5
14263 echo "$as_me:14263: \$? = $ac_status" >&5
14264 (exit $ac_status); }; }; then
14267 echo "$as_me: failed program was:" >&5
14268 cat conftest.$ac_ext >&5
14269 cat >conftest.$ac_ext <<_ACEOF
14270 #line 14270 "configure"
14271 #include "confdefs.h"
14273 #include <stdlib.h>
14274 #include <stdarg.h>
14277 #ifdef HAVE_LIBUTF8_H
14278 #include <libutf8.h>
14288 rm -f conftest.$ac_objext
14289 if { (eval echo "$as_me:14289: \"$ac_compile\"") >&5
14290 (eval $ac_compile) 2>&5
14292 echo "$as_me:14292: \$? = $ac_status" >&5
14293 (exit $ac_status); } &&
14294 { ac_try='test -s conftest.$ac_objext'
14295 { (eval echo "$as_me:14295: \"$ac_try\"") >&5
14296 (eval $ac_try) 2>&5
14298 echo "$as_me:14298: \$? = $ac_status" >&5
14299 (exit $ac_status); }; }; then
14302 echo "$as_me: failed program was:" >&5
14303 cat conftest.$ac_ext >&5
14304 cf_cv_wint_t=unknown
14306 rm -f conftest.$ac_objext conftest.$ac_ext
14308 rm -f conftest.$ac_objext conftest.$ac_ext
14310 echo "$as_me:14310: result: $cf_cv_wint_t" >&5
14311 echo "${ECHO_T}$cf_cv_wint_t" >&6
14313 if test "$cf_cv_wint_t" = yes ; then
14314 cat >>confdefs.h <<\EOF
14315 #define NEED_WCHAR_H 1
14321 # if we do not find wint_t in either place, use substitution to provide a fallback.
14322 if test "$cf_cv_wint_t" = unknown ; then
14326 # if we find wint_t in either place, use substitution to provide a fallback.
14327 if test "$cf_cv_wint_t" != unknown ; then
14328 NCURSES_OK_WINT_T=1
14331 if test "$NCURSES_OK_MBSTATE_T" = 0 ; then
14333 echo "$as_me:14333: checking for type mbstate_t in ${cf_cv_ncurses_header:-curses.h}" >&5
14334 echo $ECHO_N "checking for type mbstate_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
14335 cat >conftest.$ac_ext <<_ACEOF
14336 #line 14336 "configure"
14337 #include "confdefs.h"
14339 #ifndef _XOPEN_SOURCE_EXTENDED
14340 #define _XOPEN_SOURCE_EXTENDED
14342 #include <${cf_cv_ncurses_header:-curses.h}>
14353 rm -f conftest.$ac_objext
14354 if { (eval echo "$as_me:14354: \"$ac_compile\"") >&5
14355 (eval $ac_compile) 2>&5
14357 echo "$as_me:14357: \$? = $ac_status" >&5
14358 (exit $ac_status); } &&
14359 { ac_try='test -s conftest.$ac_objext'
14360 { (eval echo "$as_me:14360: \"$ac_try\"") >&5
14361 (eval $ac_try) 2>&5
14363 echo "$as_me:14363: \$? = $ac_status" >&5
14364 (exit $ac_status); }; }; then
14367 echo "$as_me: failed program was:" >&5
14368 cat conftest.$ac_ext >&5
14371 rm -f conftest.$ac_objext conftest.$ac_ext
14372 echo "$as_me:14372: result: $cf_result" >&5
14373 echo "${ECHO_T}$cf_result" >&6
14374 if test $cf_result = yes ; then
14376 cf_result=`echo "have_type_mbstate_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14378 cat >>confdefs.h <<EOF
14379 #define $cf_result 1
14383 cat >>confdefs.h <<EOF
14384 #define mbstate_t long
14391 if test "$NCURSES_OK_WCHAR_T" = 0 ; then
14393 echo "$as_me:14393: checking for type wchar_t in ${cf_cv_ncurses_header:-curses.h}" >&5
14394 echo $ECHO_N "checking for type wchar_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
14395 cat >conftest.$ac_ext <<_ACEOF
14396 #line 14396 "configure"
14397 #include "confdefs.h"
14399 #ifndef _XOPEN_SOURCE_EXTENDED
14400 #define _XOPEN_SOURCE_EXTENDED
14402 #include <${cf_cv_ncurses_header:-curses.h}>
14413 rm -f conftest.$ac_objext
14414 if { (eval echo "$as_me:14414: \"$ac_compile\"") >&5
14415 (eval $ac_compile) 2>&5
14417 echo "$as_me:14417: \$? = $ac_status" >&5
14418 (exit $ac_status); } &&
14419 { ac_try='test -s conftest.$ac_objext'
14420 { (eval echo "$as_me:14420: \"$ac_try\"") >&5
14421 (eval $ac_try) 2>&5
14423 echo "$as_me:14423: \$? = $ac_status" >&5
14424 (exit $ac_status); }; }; then
14427 echo "$as_me: failed program was:" >&5
14428 cat conftest.$ac_ext >&5
14431 rm -f conftest.$ac_objext conftest.$ac_ext
14432 echo "$as_me:14432: result: $cf_result" >&5
14433 echo "${ECHO_T}$cf_result" >&6
14434 if test $cf_result = yes ; then
14436 cf_result=`echo "have_type_wchar_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14438 cat >>confdefs.h <<EOF
14439 #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
14503 cat >>confdefs.h <<EOF
14504 #define wint_t long
14512 echo "$as_me:14512: checking for data boolnames declaration in ${cf_cv_ncurses_header:-curses.h}" >&5
14513 echo $ECHO_N "checking for data boolnames declaration in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
14515 cat >conftest.$ac_ext <<_ACEOF
14516 #line 14516 "configure"
14517 #include "confdefs.h"
14519 #ifdef HAVE_XCURSES
14520 #include <xcurses.h>
14521 char * XCursesProgramName = "test";
14523 #include <${cf_cv_ncurses_header:-curses.h}>
14524 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
14525 #include <ncursesw/term.h>
14526 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
14527 #include <ncurses/term.h>
14528 #elif defined(HAVE_TERM_H)
14537 void *foo = &(boolnames)
14543 rm -f conftest.$ac_objext
14544 if { (eval echo "$as_me:14544: \"$ac_compile\"") >&5
14545 (eval $ac_compile) 2>&5
14547 echo "$as_me:14547: \$? = $ac_status" >&5
14548 (exit $ac_status); } &&
14549 { ac_try='test -s conftest.$ac_objext'
14550 { (eval echo "$as_me:14550: \"$ac_try\"") >&5
14551 (eval $ac_try) 2>&5
14553 echo "$as_me:14553: \$? = $ac_status" >&5
14554 (exit $ac_status); }; }; then
14557 echo "$as_me: failed program was:" >&5
14558 cat conftest.$ac_ext >&5
14561 rm -f conftest.$ac_objext conftest.$ac_ext
14562 echo "$as_me:14562: result: $cf_result" >&5
14563 echo "${ECHO_T}$cf_result" >&6
14565 if test $cf_result = yes ; then
14567 cf_result=`echo "have_curses_data_boolnames" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14569 cat >>confdefs.h <<EOF
14570 #define $cf_result 1
14574 echo "$as_me:14574: checking for data boolnames in library" >&5
14575 echo $ECHO_N "checking for data boolnames in library... $ECHO_C" >&6
14576 # BSD linkers insist on making weak linkage, but resolve at runtime.
14577 if test "$cross_compiling" = yes; then
14580 cat >conftest.$ac_ext <<_ACEOF
14581 #line 14581 "configure"
14582 #include "confdefs.h"
14584 #ifdef HAVE_XCURSES
14585 #include <xcurses.h>
14586 char * XCursesProgramName = "test";
14588 #include <${cf_cv_ncurses_header:-curses.h}>
14589 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
14590 #include <ncursesw/term.h>
14591 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
14592 #include <ncurses/term.h>
14593 #elif defined(HAVE_TERM_H)
14598 extern char boolnames;
14604 void *foo = &(boolnames);
14605 ${cf_cv_main_return:-return}(foo == 0);
14612 rm -f conftest.$ac_objext conftest$ac_exeext
14613 if { (eval echo "$as_me:14613: \"$ac_link\"") >&5
14614 (eval $ac_link) 2>&5
14616 echo "$as_me:14616: \$? = $ac_status" >&5
14617 (exit $ac_status); } &&
14618 { ac_try='test -s conftest$ac_exeext'
14619 { (eval echo "$as_me:14619: \"$ac_try\"") >&5
14620 (eval $ac_try) 2>&5
14622 echo "$as_me:14622: \$? = $ac_status" >&5
14623 (exit $ac_status); }; }; then
14626 echo "$as_me: failed program was:" >&5
14627 cat conftest.$ac_ext >&5
14630 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14633 cat >conftest.$ac_ext <<_ACEOF
14634 #line 14634 "configure"
14635 #include "confdefs.h"
14637 #ifdef HAVE_XCURSES
14638 #include <xcurses.h>
14639 char * XCursesProgramName = "test";
14641 #include <${cf_cv_ncurses_header:-curses.h}>
14642 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
14643 #include <ncursesw/term.h>
14644 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
14645 #include <ncurses/term.h>
14646 #elif defined(HAVE_TERM_H)
14651 extern char boolnames;
14654 void *foo = &(boolnames);
14655 ${cf_cv_main_return:-return}(foo == 0);
14658 rm -f conftest$ac_exeext
14659 if { (eval echo "$as_me:14659: \"$ac_link\"") >&5
14660 (eval $ac_link) 2>&5
14662 echo "$as_me:14662: \$? = $ac_status" >&5
14663 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14664 { (eval echo "$as_me:14664: \"$ac_try\"") >&5
14665 (eval $ac_try) 2>&5
14667 echo "$as_me:14667: \$? = $ac_status" >&5
14668 (exit $ac_status); }; }; then
14671 echo "$as_me: program exited with status $ac_status" >&5
14672 echo "$as_me: failed program was:" >&5
14673 cat conftest.$ac_ext >&5
14676 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14678 echo "$as_me:14678: result: $cf_result" >&5
14679 echo "${ECHO_T}$cf_result" >&6
14680 if test $cf_result = yes ; then
14682 cf_result=`echo "decl_curses_data_boolnames" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14684 cat >>confdefs.h <<EOF
14685 #define $cf_result 1
14691 echo "$as_me:14691: checking for data boolfnames declaration in ${cf_cv_ncurses_header:-curses.h}" >&5
14692 echo $ECHO_N "checking for data boolfnames declaration in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
14694 cat >conftest.$ac_ext <<_ACEOF
14695 #line 14695 "configure"
14696 #include "confdefs.h"
14698 #ifdef HAVE_XCURSES
14699 #include <xcurses.h>
14700 char * XCursesProgramName = "test";
14702 #include <${cf_cv_ncurses_header:-curses.h}>
14703 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
14704 #include <ncursesw/term.h>
14705 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
14706 #include <ncurses/term.h>
14707 #elif defined(HAVE_TERM_H)
14716 void *foo = &(boolfnames)
14722 rm -f conftest.$ac_objext
14723 if { (eval echo "$as_me:14723: \"$ac_compile\"") >&5
14724 (eval $ac_compile) 2>&5
14726 echo "$as_me:14726: \$? = $ac_status" >&5
14727 (exit $ac_status); } &&
14728 { ac_try='test -s conftest.$ac_objext'
14729 { (eval echo "$as_me:14729: \"$ac_try\"") >&5
14730 (eval $ac_try) 2>&5
14732 echo "$as_me:14732: \$? = $ac_status" >&5
14733 (exit $ac_status); }; }; then
14736 echo "$as_me: failed program was:" >&5
14737 cat conftest.$ac_ext >&5
14740 rm -f conftest.$ac_objext conftest.$ac_ext
14741 echo "$as_me:14741: result: $cf_result" >&5
14742 echo "${ECHO_T}$cf_result" >&6
14744 if test $cf_result = yes ; then
14746 cf_result=`echo "have_curses_data_boolfnames" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14748 cat >>confdefs.h <<EOF
14749 #define $cf_result 1
14753 echo "$as_me:14753: checking for data boolfnames in library" >&5
14754 echo $ECHO_N "checking for data boolfnames in library... $ECHO_C" >&6
14755 # BSD linkers insist on making weak linkage, but resolve at runtime.
14756 if test "$cross_compiling" = yes; then
14759 cat >conftest.$ac_ext <<_ACEOF
14760 #line 14760 "configure"
14761 #include "confdefs.h"
14763 #ifdef HAVE_XCURSES
14764 #include <xcurses.h>
14765 char * XCursesProgramName = "test";
14767 #include <${cf_cv_ncurses_header:-curses.h}>
14768 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
14769 #include <ncursesw/term.h>
14770 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
14771 #include <ncurses/term.h>
14772 #elif defined(HAVE_TERM_H)
14777 extern char boolfnames;
14783 void *foo = &(boolfnames);
14784 ${cf_cv_main_return:-return}(foo == 0);
14791 rm -f conftest.$ac_objext conftest$ac_exeext
14792 if { (eval echo "$as_me:14792: \"$ac_link\"") >&5
14793 (eval $ac_link) 2>&5
14795 echo "$as_me:14795: \$? = $ac_status" >&5
14796 (exit $ac_status); } &&
14797 { ac_try='test -s conftest$ac_exeext'
14798 { (eval echo "$as_me:14798: \"$ac_try\"") >&5
14799 (eval $ac_try) 2>&5
14801 echo "$as_me:14801: \$? = $ac_status" >&5
14802 (exit $ac_status); }; }; then
14805 echo "$as_me: failed program was:" >&5
14806 cat conftest.$ac_ext >&5
14809 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14812 cat >conftest.$ac_ext <<_ACEOF
14813 #line 14813 "configure"
14814 #include "confdefs.h"
14816 #ifdef HAVE_XCURSES
14817 #include <xcurses.h>
14818 char * XCursesProgramName = "test";
14820 #include <${cf_cv_ncurses_header:-curses.h}>
14821 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
14822 #include <ncursesw/term.h>
14823 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
14824 #include <ncurses/term.h>
14825 #elif defined(HAVE_TERM_H)
14830 extern char boolfnames;
14833 void *foo = &(boolfnames);
14834 ${cf_cv_main_return:-return}(foo == 0);
14837 rm -f conftest$ac_exeext
14838 if { (eval echo "$as_me:14838: \"$ac_link\"") >&5
14839 (eval $ac_link) 2>&5
14841 echo "$as_me:14841: \$? = $ac_status" >&5
14842 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14843 { (eval echo "$as_me:14843: \"$ac_try\"") >&5
14844 (eval $ac_try) 2>&5
14846 echo "$as_me:14846: \$? = $ac_status" >&5
14847 (exit $ac_status); }; }; then
14850 echo "$as_me: program exited with status $ac_status" >&5
14851 echo "$as_me: failed program was:" >&5
14852 cat conftest.$ac_ext >&5
14855 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14857 echo "$as_me:14857: result: $cf_result" >&5
14858 echo "${ECHO_T}$cf_result" >&6
14859 if test $cf_result = yes ; then
14861 cf_result=`echo "decl_curses_data_boolfnames" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14863 cat >>confdefs.h <<EOF
14864 #define $cf_result 1
14873 ac_config_files="$ac_config_files Makefile"
14874 ac_config_commands="$ac_config_commands default"
14875 cat >confcache <<\_ACEOF
14876 # This file is a shell script that caches the results of configure
14877 # tests run on this system so they can be shared between configure
14878 # scripts and configure runs, see configure's option --config-cache.
14879 # It is not useful on other systems. If it contains results you don't
14880 # want to keep, you may remove or edit it.
14882 # config.status only pays attention to the cache file if you give it
14883 # the --recheck option to rerun configure.
14885 # `ac_cv_env_foo' variables (set or unset) will be overriden when
14886 # loading this file, other *unset* `ac_cv_foo' will be assigned the
14887 # following values.
14891 # The following way of writing the cache mishandles newlines in values,
14892 # but we know of no workaround that is simple, portable, and efficient.
14893 # So, don't put newlines in cache variables' values.
14894 # Ultrix sh set writes to stderr and can't be redirected directly,
14895 # and sets the high bit in the cache file unless we assign to the vars.
14898 case `(ac_space=' '; set | grep ac_space) 2>&1` in
14900 # `set' does not quote correctly, so add quotes (double-quote
14901 # substitution turns \\\\ into \\, and sed turns \\ into \).
14904 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
14907 # `set' quotes correctly as required by POSIX, so do not add quotes.
14909 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
14916 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
14918 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
14920 if cmp -s $cache_file confcache; then :; else
14921 if test -w $cache_file; then
14922 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
14923 cat confcache >$cache_file
14925 echo "not updating unwritable cache $cache_file"
14930 test "x$prefix" = xNONE && prefix=$ac_default_prefix
14931 # Let make expand exec_prefix.
14932 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
14934 # VPATH may cause trouble with some makes, so we remove $(srcdir),
14935 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
14936 # trailing colons and then remove the whole line if VPATH becomes empty
14937 # (actually we leave an empty line to preserve line numbers).
14938 if test "x$srcdir" = x.; then
14939 ac_vpsub='/^[ ]*VPATH[ ]*=/{
14940 s/:*\$(srcdir):*/:/;
14941 s/:*\${srcdir}:*/:/;
14943 s/^\([^=]*=[ ]*\):*/\1/;
14949 DEFS=-DHAVE_CONFIG_H
14951 : ${CONFIG_STATUS=./config.status}
14952 ac_clean_files_save=$ac_clean_files
14953 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
14954 { echo "$as_me:14954: creating $CONFIG_STATUS" >&5
14955 echo "$as_me: creating $CONFIG_STATUS" >&6;}
14956 cat >$CONFIG_STATUS <<_ACEOF
14958 # Generated automatically by configure.
14959 # Run this file to recreate the current configuration.
14960 # Compiler output produced by configure, useful for debugging
14961 # configure, is in config.log if it exists.
14964 SHELL=\${CONFIG_SHELL-$SHELL}
14965 ac_cs_invocation="\$0 \$@"
14969 cat >>$CONFIG_STATUS <<\_ACEOF
14970 # Be Bourne compatible
14971 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
14974 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
14978 # Name of the executable.
14979 as_me=`echo "$0" |sed 's,.*[\\/],,'`
14981 if expr a : '\(a\)' >/dev/null 2>&1; then
14987 rm -f conf$$ conf$$.exe conf$$.file
14989 if ln -s conf$$.file conf$$ 2>/dev/null; then
14990 # We could just check for DJGPP; but this test a) works b) is more generic
14991 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
14992 if test -f conf$$.exe; then
14993 # Don't use ln at all; we don't have any links
14998 elif ln conf$$.file conf$$ 2>/dev/null; then
15003 rm -f conf$$ conf$$.exe conf$$.file
15005 as_executable_p="test -f"
15007 # Support unset when possible.
15008 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
15015 $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
15016 $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
15017 $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
15018 $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
15019 $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
15020 $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
15021 $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
15022 $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
15025 # We need space, tab and new line, in precisely that order.
15031 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
15037 # Files that config.status was made for.
15038 if test -n "$ac_config_files"; then
15039 echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
15042 if test -n "$ac_config_headers"; then
15043 echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
15046 if test -n "$ac_config_links"; then
15047 echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
15050 if test -n "$ac_config_commands"; then
15051 echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
15054 cat >>$CONFIG_STATUS <<\EOF
15057 \`$as_me' instantiates files from templates according to the
15058 current configuration.
15060 Usage: $0 [OPTIONS] [FILE]...
15062 -h, --help print this help, then exit
15063 -V, --version print version number, then exit
15064 -d, --debug don't remove temporary files
15065 --recheck update $as_me by reconfiguring in the same conditions
15066 --file=FILE[:TEMPLATE]
15067 instantiate the configuration file FILE
15068 --header=FILE[:TEMPLATE]
15069 instantiate the configuration header FILE
15071 Configuration files:
15074 Configuration headers:
15077 Configuration commands:
15080 Report bugs to <dickey@invisible-island.net>."
15083 cat >>$CONFIG_STATUS <<EOF
15086 configured by $0, generated by GNU Autoconf 2.52.20101002,
15087 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
15089 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
15090 Free Software Foundation, Inc.
15091 This config.status script is free software; the Free Software Foundation
15092 gives unlimited permission to copy, distribute and modify it."
15097 cat >>$CONFIG_STATUS <<\EOF
15098 # If no file are specified by the user, then we need to provide default
15099 # value. By we need to know if files were specified by the user.
15105 ac_option=`expr "x$1" : 'x\([^=]*\)='`
15106 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
15108 set dummy "$ac_option" "$ac_optarg" ${1+"$@"}
15112 *) # This is not an option, so the user has probably given explicit
15114 ac_need_defaults=false;;
15118 # Handling of the options.
15120 cat >>$CONFIG_STATUS <<EOF
15121 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
15122 echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion"
15123 exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;;
15125 cat >>$CONFIG_STATUS <<\EOF
15126 --version | --vers* | -V )
15127 echo "$ac_cs_version"; exit 0 ;;
15129 # Conflict between --help and --header
15130 { { echo "$as_me:15130: error: ambiguous option: $1
15131 Try \`$0 --help' for more information." >&5
15132 echo "$as_me: error: ambiguous option: $1
15133 Try \`$0 --help' for more information." >&2;}
15134 { (exit 1); exit 1; }; };;
15135 --help | --hel | -h )
15136 echo "$ac_cs_usage"; exit 0 ;;
15137 --debug | --d* | -d )
15139 --file | --fil | --fi | --f )
15141 CONFIG_FILES="$CONFIG_FILES $1"
15142 ac_need_defaults=false;;
15143 --header | --heade | --head | --hea )
15145 CONFIG_HEADERS="$CONFIG_HEADERS $1"
15146 ac_need_defaults=false;;
15148 # This is an error.
15149 -*) { { echo "$as_me:15149: error: unrecognized option: $1
15150 Try \`$0 --help' for more information." >&5
15151 echo "$as_me: error: unrecognized option: $1
15152 Try \`$0 --help' for more information." >&2;}
15153 { (exit 1); exit 1; }; } ;;
15155 *) ac_config_targets="$ac_config_targets $1" ;;
15164 ## ----------------------- ##
15165 ## Running config.status. ##
15166 ## ----------------------- ##
15168 This file was extended by $as_me 2.52.20101002, executed with
15169 CONFIG_FILES = $CONFIG_FILES
15170 CONFIG_HEADERS = $CONFIG_HEADERS
15171 CONFIG_LINKS = $CONFIG_LINKS
15172 CONFIG_COMMANDS = $CONFIG_COMMANDS
15173 > $ac_cs_invocation
15174 on `(hostname || uname -n) 2>/dev/null | sed 1q`
15179 cat >>$CONFIG_STATUS <<EOF
15181 # INIT-COMMANDS section.
15189 cat >>$CONFIG_STATUS <<\EOF
15190 for ac_config_target in $ac_config_targets
15192 case "$ac_config_target" in
15193 # Handling of arguments.
15194 "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
15195 "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
15196 "ncurses_cfg.h" ) CONFIG_HEADERS="$CONFIG_HEADERS ncurses_cfg.h:ncurses_tst.hin" ;;
15197 *) { { echo "$as_me:15197: error: invalid argument: $ac_config_target" >&5
15198 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
15199 { (exit 1); exit 1; }; };;
15203 # If the user did not use the arguments to specify the items to instantiate,
15204 # then the envvar interface is used. Set only those that are not.
15205 # We use the long form for the default assignment because of an extremely
15206 # bizarre bug on SunOS 4.1.3.
15207 if $ac_need_defaults; then
15208 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
15209 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
15210 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
15213 # Create a temporary directory, and hook for its removal unless debugging.
15216 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
15217 trap '{ (exit 1); exit 1; }' 1 2 13 15
15220 # Create a (secure) tmp directory for tmp files.
15223 tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` &&
15224 test -n "$tmp" && test -d "$tmp"
15227 tmp=$TMPDIR/cs$$-$RANDOM
15228 (umask 077 && mkdir $tmp)
15231 echo "$me: cannot create a temporary directory in $TMPDIR" >&2
15232 { (exit 1); exit 1; }
15237 cat >>$CONFIG_STATUS <<EOF
15240 # CONFIG_FILES section.
15243 # No need to generate the scripts if there are no CONFIG_FILES.
15244 # This happens for instance when ./config.status config.h
15245 if test -n "\$CONFIG_FILES"; then
15246 # Protect against being on the right side of a sed subst in config.status.
15247 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
15248 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
15249 s,@SHELL@,$SHELL,;t t
15250 s,@exec_prefix@,$exec_prefix,;t t
15251 s,@prefix@,$prefix,;t t
15252 s,@program_transform_name@,$program_transform_name,;t t
15253 s,@bindir@,$bindir,;t t
15254 s,@sbindir@,$sbindir,;t t
15255 s,@libexecdir@,$libexecdir,;t t
15256 s,@datadir@,$datadir,;t t
15257 s,@sysconfdir@,$sysconfdir,;t t
15258 s,@sharedstatedir@,$sharedstatedir,;t t
15259 s,@localstatedir@,$localstatedir,;t t
15260 s,@libdir@,$libdir,;t t
15261 s,@includedir@,$includedir,;t t
15262 s,@oldincludedir@,$oldincludedir,;t t
15263 s,@infodir@,$infodir,;t t
15264 s,@mandir@,$mandir,;t t
15265 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
15266 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
15267 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
15268 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
15269 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
15270 s,@build_alias@,$build_alias,;t t
15271 s,@host_alias@,$host_alias,;t t
15272 s,@target_alias@,$target_alias,;t t
15273 s,@ECHO_C@,$ECHO_C,;t t
15274 s,@ECHO_N@,$ECHO_N,;t t
15275 s,@ECHO_T@,$ECHO_T,;t t
15276 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
15277 s,@DEFS@,$DEFS,;t t
15278 s,@LIBS@,$LIBS,;t t
15279 s,@build@,$build,;t t
15280 s,@build_cpu@,$build_cpu,;t t
15281 s,@build_vendor@,$build_vendor,;t t
15282 s,@build_os@,$build_os,;t t
15283 s,@host@,$host,;t t
15284 s,@host_cpu@,$host_cpu,;t t
15285 s,@host_vendor@,$host_vendor,;t t
15286 s,@host_os@,$host_os,;t t
15287 s,@SET_MAKE@,$SET_MAKE,;t t
15289 s,@CFLAGS@,$CFLAGS,;t t
15290 s,@LDFLAGS@,$LDFLAGS,;t t
15291 s,@CPPFLAGS@,$CPPFLAGS,;t t
15292 s,@ac_ct_CC@,$ac_ct_CC,;t t
15293 s,@EXEEXT@,$EXEEXT,;t t
15294 s,@OBJEXT@,$OBJEXT,;t t
15297 s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
15298 s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
15299 s,@INSTALL_DATA@,$INSTALL_DATA,;t t
15300 s,@LINT@,$LINT,;t t
15301 s,@LINT_OPTS@,$LINT_OPTS,;t t
15302 s,@CTAGS@,$CTAGS,;t t
15303 s,@ETAGS@,$ETAGS,;t t
15304 s,@MAKE_LOWER_TAGS@,$MAKE_LOWER_TAGS,;t t
15305 s,@MAKE_UPPER_TAGS@,$MAKE_UPPER_TAGS,;t t
15306 s,@MATH_LIB@,$MATH_LIB,;t t
15307 s,@CC_G_OPT@,$CC_G_OPT,;t t
15308 s,@CC_SHARED_OPTS@,$CC_SHARED_OPTS,;t t
15309 s,@DFT_DEP_SUFFIX@,$DFT_DEP_SUFFIX,;t t
15310 s,@DFT_OBJ_SUBDIR@,$DFT_OBJ_SUBDIR,;t t
15311 s,@DFT_UPR_MODEL@,$DFT_UPR_MODEL,;t t
15313 s,@LDFLAGS_SHARED@,$LDFLAGS_SHARED,;t t
15314 s,@LDFLAGS_STATIC@,$LDFLAGS_STATIC,;t t
15315 s,@LD_MODEL@,$LD_MODEL,;t t
15316 s,@LD_SHARED_OPTS@,$LD_SHARED_OPTS,;t t
15317 s,@LIBTOOL@,$LIBTOOL,;t t
15318 s,@LIB_CLEAN@,$LIB_CLEAN,;t t
15319 s,@LIB_COMPILE@,$LIB_COMPILE,;t t
15320 s,@LIB_LINK@,$LIB_LINK,;t t
15321 s,@LINK_TESTS@,$LINK_TESTS,;t t
15322 s,@LOCAL_LDFLAGS@,$LOCAL_LDFLAGS,;t t
15323 s,@PTHREAD@,$PTHREAD,;t t
15324 s,@TEST_ARGS@,$TEST_ARGS,;t t
15325 s,@TEST_DEPS@,$TEST_DEPS,;t t
15326 s,@TEST_LIBS@,$TEST_LIBS,;t t
15327 s,@TINFO_ARGS@,$TINFO_ARGS,;t t
15328 s,@cf_cv_abi_version@,$cf_cv_abi_version,;t t
15329 s,@cf_cv_rel_version@,$cf_cv_rel_version,;t t
15330 s,@EXTRA_CPPFLAGS@,$EXTRA_CPPFLAGS,;t t
15331 s,@ECHO_LT@,$ECHO_LT,;t t
15332 s,@ECHO_LD@,$ECHO_LD,;t t
15333 s,@RULE_CC@,$RULE_CC,;t t
15334 s,@SHOW_CC@,$SHOW_CC,;t t
15335 s,@ECHO_CC@,$ECHO_CC,;t t
15336 s,@EXTRA_CFLAGS@,$EXTRA_CFLAGS,;t t
15337 s,@NCURSES_CONFIG@,$NCURSES_CONFIG,;t t
15338 s,@PKG_CONFIG@,$PKG_CONFIG,;t t
15339 s,@ac_pt_PKG_CONFIG@,$ac_pt_PKG_CONFIG,;t t
15340 s,@X_CFLAGS@,$X_CFLAGS,;t t
15341 s,@X_PRE_LIBS@,$X_PRE_LIBS,;t t
15342 s,@X_LIBS@,$X_LIBS,;t t
15343 s,@X_EXTRA_LIBS@,$X_EXTRA_LIBS,;t t
15344 s,@XCURSES_CONFIG@,$XCURSES_CONFIG,;t t
15345 s,@NCURSES_WRAP_PREFIX@,$NCURSES_WRAP_PREFIX,;t t
15350 cat >>$CONFIG_STATUS <<\EOF
15351 # Split the substitutions into bite-sized pieces for seds with
15352 # small command number limits, like on Digital OSF/1 and HP-UX.
15353 ac_max_sed_lines=48
15354 ac_sed_frag=1 # Number of current file.
15355 ac_beg=1 # First line for current file.
15356 ac_end=$ac_max_sed_lines # Line after last line for current file.
15359 while $ac_more_lines; do
15360 if test $ac_beg -gt 1; then
15361 sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
15363 sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
15365 if test ! -s $tmp/subs.frag; then
15366 ac_more_lines=false
15368 # The purpose of the label and of the branching condition is to
15369 # speed up the sed processing (if there are no `@' at all, there
15370 # is no need to browse any of the substitutions).
15371 # These are the two extra sed commands mentioned above.
15373 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
15374 if test -z "$ac_sed_cmds"; then
15375 ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
15377 ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
15379 ac_sed_frag=`expr $ac_sed_frag + 1`
15381 ac_end=`expr $ac_end + $ac_max_sed_lines`
15384 if test -z "$ac_sed_cmds"; then
15387 fi # test -n "$CONFIG_FILES"
15390 cat >>$CONFIG_STATUS <<\EOF
15391 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
15392 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
15394 - | *:- | *:-:* ) # input from stdin
15396 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
15397 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
15398 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
15399 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
15400 * ) ac_file_in=$ac_file.in ;;
15403 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
15404 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
15405 X"$ac_file" : 'X\(//\)[^/]' \| \
15406 X"$ac_file" : 'X\(//\)$' \| \
15407 X"$ac_file" : 'X\(/\)' \| \
15408 . : '\(.\)' 2>/dev/null ||
15410 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
15411 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
15412 /^X\(\/\/\)$/{ s//\1/; q; }
15413 /^X\(\/\).*/{ s//\1/; q; }
15415 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
15416 { case "$ac_dir" in
15417 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
15421 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
15422 case $as_mkdir_dir in
15423 # Skip DOS drivespec
15424 ?:) as_incr_dir=$as_mkdir_dir ;;
15426 as_incr_dir=$as_incr_dir/$as_mkdir_dir
15427 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
15432 ac_dir_suffix="/`echo $ac_dir|sed 's,^\./,,'`"
15433 # A "../" for each directory in $ac_dir_suffix.
15434 ac_dots=`echo "$ac_dir_suffix" | sed 's,/[^/]*,../,g'`
15436 ac_dir_suffix= ac_dots=
15441 if test -z "$ac_dots"; then
15444 ac_top_srcdir=`echo $ac_dots | sed 's,/$,,'`
15446 [\\/]* | ?:[\\/]* )
15447 ac_srcdir=$srcdir$ac_dir_suffix;
15448 ac_top_srcdir=$srcdir ;;
15449 *) # Relative path.
15450 ac_srcdir=$ac_dots$srcdir$ac_dir_suffix
15451 ac_top_srcdir=$ac_dots$srcdir ;;
15455 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
15456 *) ac_INSTALL=$ac_dots$INSTALL ;;
15459 if test x"$ac_file" != x-; then
15460 { echo "$as_me:15460: creating $ac_file" >&5
15461 echo "$as_me: creating $ac_file" >&6;}
15464 # Let's still pretend it is `configure' which instantiates (i.e., don't
15465 # use $as_me), people would be surprised to read:
15466 # /* config.h. Generated automatically by config.status. */
15467 configure_input="Generated automatically from `echo $ac_file_in |
15468 sed 's,.*/,,'` by configure."
15470 # First look for the input files in the build tree, otherwise in the
15472 ac_file_inputs=`IFS=:
15473 for f in $ac_file_in; do
15475 -) echo $tmp/stdin ;;
15477 # Absolute (can't be DOS-style, as IFS=:)
15478 test -f "$f" || { { echo "$as_me:15478: error: cannot find input file: $f" >&5
15479 echo "$as_me: error: cannot find input file: $f" >&2;}
15480 { (exit 1); exit 1; }; }
15483 if test -f "$f"; then
15486 elif test -f "$srcdir/$f"; then
15491 { { echo "$as_me:15491: error: cannot find input file: $f" >&5
15492 echo "$as_me: error: cannot find input file: $f" >&2;}
15493 { (exit 1); exit 1; }; }
15496 done` || { (exit 1); exit 1; }
15498 cat >>$CONFIG_STATUS <<EOF
15502 cat >>$CONFIG_STATUS <<\EOF
15504 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
15505 s,@configure_input@,$configure_input,;t t
15506 s,@srcdir@,$ac_srcdir,;t t
15507 s,@top_srcdir@,$ac_top_srcdir,;t t
15508 s,@INSTALL@,$ac_INSTALL,;t t
15509 " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
15511 if test x"$ac_file" != x-; then
15512 mv $tmp/out $ac_file
15520 cat >>$CONFIG_STATUS <<\EOF
15523 # CONFIG_HEADER section.
15526 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
15527 # NAME is the cpp macro being defined and VALUE is the value it is being given.
15529 # ac_d sets the value in "#define NAME VALUE" lines.
15530 ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
15531 ac_dB='[ ].*$,\1#\2'
15534 # ac_i turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
15535 ac_iA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
15536 ac_iB='\([ ]\),\1#\2define\3'
15539 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
15540 ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
15541 ac_uB='$,\1#\2define\3'
15545 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
15546 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
15548 - | *:- | *:-:* ) # input from stdin
15550 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
15551 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
15552 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
15553 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
15554 * ) ac_file_in=$ac_file.in ;;
15557 test x"$ac_file" != x- && { echo "$as_me:15557: creating $ac_file" >&5
15558 echo "$as_me: creating $ac_file" >&6;}
15560 # First look for the input files in the build tree, otherwise in the
15562 ac_file_inputs=`IFS=:
15563 for f in $ac_file_in; do
15565 -) echo $tmp/stdin ;;
15567 # Absolute (can't be DOS-style, as IFS=:)
15568 test -f "$f" || { { echo "$as_me:15568: error: cannot find input file: $f" >&5
15569 echo "$as_me: error: cannot find input file: $f" >&2;}
15570 { (exit 1); exit 1; }; }
15573 if test -f "$f"; then
15576 elif test -f "$srcdir/$f"; then
15581 { { echo "$as_me:15581: error: cannot find input file: $f" >&5
15582 echo "$as_me: error: cannot find input file: $f" >&2;}
15583 { (exit 1); exit 1; }; }
15586 done` || { (exit 1); exit 1; }
15587 # Remove the trailing spaces.
15588 sed 's/[ ]*$//' $ac_file_inputs >$tmp/in
15592 # Transform confdefs.h into a list of #define's. We won't use it as a sed
15593 # script, but as data to insert where we see @DEFS@. We expect AC_SAVE_DEFS to
15594 # be either 'cat' or 'sort'.
15595 cat confdefs.h | uniq >conftest.vals
15597 # Break up conftest.vals because some shells have a limit on
15598 # the size of here documents, and old seds have small limits too.
15600 rm -f conftest.tail
15601 echo ' rm -f conftest.frag' >> $CONFIG_STATUS
15602 while grep . conftest.vals >/dev/null
15604 # Write chunks of a limited-size here document to conftest.frag.
15605 echo ' cat >> conftest.frag <<CEOF' >> $CONFIG_STATUS
15606 sed ${ac_max_here_lines}q conftest.vals | sed -e 's/#ifdef.*/#if 0/' >> $CONFIG_STATUS
15607 echo 'CEOF' >> $CONFIG_STATUS
15608 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
15609 rm -f conftest.vals
15610 mv conftest.tail conftest.vals
15612 rm -f conftest.vals
15614 # Run sed to substitute the contents of conftest.frag into $tmp/in at the
15616 echo ' cat >> conftest.edit <<CEOF
15617 /@DEFS@/r conftest.frag
15620 sed -f conftest.edit $tmp/in > $tmp/out
15622 mv $tmp/out $tmp/in
15623 rm -f conftest.edit conftest.frag
15624 ' >> $CONFIG_STATUS
15626 cat >>$CONFIG_STATUS <<\EOF
15627 # Let's still pretend it is `configure' which instantiates (i.e., don't
15628 # use $as_me), people would be surprised to read:
15629 # /* config.h. Generated automatically by config.status. */
15630 if test x"$ac_file" = x-; then
15631 echo "/* Generated automatically by configure. */" >$tmp/config.h
15633 echo "/* $ac_file. Generated automatically by configure. */" >$tmp/config.h
15635 cat $tmp/in >>$tmp/config.h
15637 if test x"$ac_file" != x-; then
15638 if cmp -s $ac_file $tmp/config.h 2>/dev/null; then
15639 { echo "$as_me:15639: $ac_file is unchanged" >&5
15640 echo "$as_me: $ac_file is unchanged" >&6;}
15642 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
15643 X"$ac_file" : 'X\(//\)[^/]' \| \
15644 X"$ac_file" : 'X\(//\)$' \| \
15645 X"$ac_file" : 'X\(/\)' \| \
15646 . : '\(.\)' 2>/dev/null ||
15648 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
15649 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
15650 /^X\(\/\/\)$/{ s//\1/; q; }
15651 /^X\(\/\).*/{ s//\1/; q; }
15653 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
15654 { case "$ac_dir" in
15655 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
15659 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
15660 case $as_mkdir_dir in
15661 # Skip DOS drivespec
15662 ?:) as_incr_dir=$as_mkdir_dir ;;
15664 as_incr_dir=$as_incr_dir/$as_mkdir_dir
15665 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
15672 mv $tmp/config.h $ac_file
15676 rm -f $tmp/config.h
15680 cat >>$CONFIG_STATUS <<\EOF
15682 # CONFIG_COMMANDS section.
15684 for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
15685 ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
15686 ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
15693 if test ! -d $srcdir/$cf_dir; then
15695 elif test -f $srcdir/$cf_dir/programs; then
15696 $AWK -f $srcdir/mk-test.awk INSTALL=yes ECHO_LINK="$ECHO_LD" $srcdir/$cf_dir/programs >>$cf_dir/Makefile
15700 cat >>Makefile <<TEST_EOF
15702 # These rules are generated so we do not rely on suffix rules, which do not
15703 # work consistently for different make-programs (the '\$(MODEL)/' confuses
15704 # some, and the '\$x' confuses others).
15707 LIST=`sed -e 's/[ ].*//' -e '/^[#@]/d' $srcdir/modules`
15710 cat >>Makefile <<TEST_EOF
15712 \$(MODEL)/$N.o : \$(srcdir)/$N.c \\
15713 \$(srcdir)/test.priv.h \\
15715 @echo compiling $N; \$(CC) -c \$(CFLAGS_DEFAULT) \$(srcdir)/$N.c
15719 if test -f ../config.guess && test -f ../config.sub
15721 cat >>Makefile <<TEST_EOF
15723 # if we used CF_INHERIT for getting these files, we can remove them
15725 rm -f config.guess config.sub
15733 cat >>$CONFIG_STATUS <<\EOF
15735 { (exit 0); exit 0; }
15737 chmod +x $CONFIG_STATUS
15738 ac_clean_files=$ac_clean_files_save
15740 # configure is writing to config.log, and then calls config.status.
15741 # config.status does its own redirection, appending to config.log.
15742 # Unfortunately, on DOS this fails, as config.log is still kept open
15743 # by configure, so config.status won't be able to write to it; its
15744 # output is simply discarded. So we exec the FD to /dev/null,
15745 # effectively closing config.log, so it can be properly (re)opened and
15746 # appended to by config.status. When coming back to configure, we
15747 # need to make the FD available again.
15748 if test "$no_create" != yes; then
15751 $SHELL $CONFIG_STATUS || ac_cs_success=false
15753 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
15754 # would make configure fail if this is the last instruction.
15755 $ac_cs_success || { (exit 1); exit 1; }