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
657 --with-ncurses use ncurses-libraries
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
667 --disable-rpath-hack don't add rpath options for additional libraries
669 Some influential environment variables:
670 CC C compiler command
671 CFLAGS C compiler flags
672 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
673 nonstandard directory <lib dir>
674 CPPFLAGS C/C++ preprocessor flags, e.g. -I<include dir> if you have
675 headers in a nonstandard directory <include dir>
678 Use these variables to override the choices made by `configure' or to help
679 it to find libraries and programs with nonstandard names/locations.
684 if test "$ac_init_help" = "recursive"; then
685 # If there are subdirs, report their specific --help.
687 for ac_subdir in : $ac_subdirs_all; do test "x$ac_subdir" = x: && continue
689 # A "../" for each directory in /$ac_subdir.
690 ac_dots=`echo $ac_subdir |
691 sed 's,^\./,,;s,[^/]$,&/,;s,[^/]*/,../,g'`
694 .) # No --srcdir option. We are building in place.
695 ac_sub_srcdir=$srcdir ;;
696 [\\/]* | ?:[\\/]* ) # Absolute path.
697 ac_sub_srcdir=$srcdir/$ac_subdir ;;
699 ac_sub_srcdir=$ac_dots$srcdir/$ac_subdir ;;
702 # Check for guested configure; otherwise get Cygnus style configure.
703 if test -f $ac_sub_srcdir/configure.gnu; then
705 $SHELL $ac_sub_srcdir/configure.gnu --help=recursive
706 elif test -f $ac_sub_srcdir/configure; then
708 $SHELL $ac_sub_srcdir/configure --help=recursive
709 elif test -f $ac_sub_srcdir/configure.ac ||
710 test -f $ac_sub_srcdir/configure.in; then
714 echo "$as_me: WARNING: no configuration information is in $ac_subdir" >&2
720 test -n "$ac_init_help" && exit 0
721 if $ac_init_version; then
724 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
725 Free Software Foundation, Inc.
726 This configure script is free software; the Free Software Foundation
727 gives unlimited permission to copy, distribute and modify it.
733 This file contains any messages produced by compilers while
734 running configure, to aid debugging if configure makes a mistake.
736 It was created by $as_me, which was
737 generated by GNU Autoconf 2.52.20101002. Invocation command line was
748 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
749 uname -m = `(uname -m) 2>/dev/null || echo unknown`
750 uname -r = `(uname -r) 2>/dev/null || echo unknown`
751 uname -s = `(uname -s) 2>/dev/null || echo unknown`
752 uname -v = `(uname -v) 2>/dev/null || echo unknown`
754 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
755 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
757 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
758 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
759 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
760 hostinfo = `(hostinfo) 2>/dev/null || echo unknown`
761 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
762 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
763 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
777 # Keep a trace of the command line.
778 # Strip out --no-create and --no-recursion so they do not pile up.
779 # Also quote any args containing shell meta-characters.
785 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
786 | --no-cr | --no-c) ;;
787 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
788 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
789 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
790 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"`
791 ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
793 *) ac_configure_args="$ac_configure_args$ac_sep$ac_arg"
796 # Get rid of the leading space.
799 # When interrupted or exit'd, cleanup temporary files, and complete
800 # config.log. We remove comments because anyway the quotes in there
801 # would cause problems or look ugly.
803 # Save into config.log some information that might help in debugging.
805 echo "## ----------------- ##" >&5
806 echo "## Cache variables. ##" >&5
807 echo "## ----------------- ##" >&5
809 # The following way of writing the cache mishandles newlines in values,
812 case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
815 "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
816 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
820 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
824 sed "/^$/d" confdefs.h >conftest.log
825 if test -s conftest.log; then
827 echo "## ------------ ##" >&5
828 echo "## confdefs.h. ##" >&5
829 echo "## ------------ ##" >&5
834 test "$ac_signal" != 0 &&
835 echo "$as_me: caught signal $ac_signal" >&5
836 echo "$as_me: exit $exit_status" >&5
837 rm -rf conftest* confdefs* core core.* *.core conf$$* $ac_clean_files &&
840 for ac_signal in 1 2 13 15; do
841 trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
845 # confdefs.h avoids OS command line length limits that DEFS can exceed.
846 rm -rf conftest* confdefs.h
847 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
850 # Let the site file select an alternate cache file if it wants to.
851 # Prefer explicitly selected file to automatically selected ones.
852 if test -z "$CONFIG_SITE"; then
853 if test "x$prefix" != xNONE; then
854 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
856 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
859 for ac_site_file in $CONFIG_SITE; do
860 if test -r "$ac_site_file"; then
861 { echo "$as_me:861: loading site script $ac_site_file" >&5
862 echo "$as_me: loading site script $ac_site_file" >&6;}
863 cat "$ac_site_file" >&5
868 if test -r "$cache_file"; then
869 # Some versions of bash will fail to source /dev/null (special
870 # files actually), so we avoid doing that.
871 if test -f "$cache_file"; then
872 { echo "$as_me:872: loading cache $cache_file" >&5
873 echo "$as_me: loading cache $cache_file" >&6;}
875 [\\/]* | ?:[\\/]* ) . $cache_file;;
880 { echo "$as_me:880: creating cache $cache_file" >&5
881 echo "$as_me: creating cache $cache_file" >&6;}
885 # Check that the precious variables saved in the cache have kept the same
887 ac_cache_corrupted=false
888 for ac_var in `(set) 2>&1 |
889 sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
890 eval ac_old_set=\$ac_cv_env_${ac_var}_set
891 eval ac_new_set=\$ac_env_${ac_var}_set
892 eval ac_old_val="\$ac_cv_env_${ac_var}_value"
893 eval ac_new_val="\$ac_env_${ac_var}_value"
894 case $ac_old_set,$ac_new_set in
896 { echo "$as_me:896: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
897 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
898 ac_cache_corrupted=: ;;
900 { echo "$as_me:900: error: \`$ac_var' was not set in the previous run" >&5
901 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
902 ac_cache_corrupted=: ;;
905 if test "x$ac_old_val" != "x$ac_new_val"; then
906 { echo "$as_me:906: error: \`$ac_var' has changed since the previous run:" >&5
907 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
908 { echo "$as_me:908: former value: $ac_old_val" >&5
909 echo "$as_me: former value: $ac_old_val" >&2;}
910 { echo "$as_me:910: current value: $ac_new_val" >&5
911 echo "$as_me: current value: $ac_new_val" >&2;}
915 # Pass precious variables to config.status. It doesn't matter if
916 # we pass some twice (in addition to the command line arguments).
917 if test "$ac_new_set" = set; then
919 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
920 ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"`
921 ac_configure_args="$ac_configure_args '$ac_arg'"
923 *) ac_configure_args="$ac_configure_args $ac_var=$ac_new_val"
928 if $ac_cache_corrupted; then
929 { echo "$as_me:929: error: changes in the environment can compromise the build" >&5
930 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
931 { { echo "$as_me:931: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
932 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
933 { (exit 1); exit 1; }; }
937 ac_cpp='$CPP $CPPFLAGS'
938 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
939 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
940 ac_compiler_gnu=$ac_cv_c_compiler_gnu
941 ac_main_return=return
943 case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
944 *c*,-n*) ECHO_N= ECHO_C='
946 *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
947 *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
949 echo "#! $SHELL" >conftest.sh
950 echo "exit 0" >>conftest.sh
952 if { (echo "$as_me:952: PATH=\".;.\"; conftest.sh") >&5
953 (PATH=".;."; conftest.sh) 2>&5
955 echo "$as_me:955: \$? = $ac_status" >&5
956 (exit $ac_status); }; then
957 ac_path_separator=';'
961 PATH_SEPARATOR="$ac_path_separator"
964 ac_config_headers="$ac_config_headers ncurses_cfg.h:ncurses_tst.hin"
966 test -f config.guess || ( test -f ../config.guess && cp ../config.guess ./ )
968 test -f config.sub || ( test -f ../config.sub && cp ../config.sub ./ )
971 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
972 if test -f $ac_dir/install-sh; then
974 ac_install_sh="$ac_aux_dir/install-sh -c"
976 elif test -f $ac_dir/install.sh; then
978 ac_install_sh="$ac_aux_dir/install.sh -c"
980 elif test -f $ac_dir/shtool; then
982 ac_install_sh="$ac_aux_dir/shtool install -c"
986 if test -z "$ac_aux_dir"; then
987 { { echo "$as_me:987: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
988 echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
989 { (exit 1); exit 1; }; }
991 ac_config_guess="$SHELL $ac_aux_dir/config.guess"
992 ac_config_sub="$SHELL $ac_aux_dir/config.sub"
993 ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
995 # Make sure we can run config.sub.
996 $ac_config_sub sun4 >/dev/null 2>&1 ||
997 { { echo "$as_me:997: error: cannot run $ac_config_sub" >&5
998 echo "$as_me: error: cannot run $ac_config_sub" >&2;}
999 { (exit 1); exit 1; }; }
1001 echo "$as_me:1001: checking build system type" >&5
1002 echo $ECHO_N "checking build system type... $ECHO_C" >&6
1003 if test "${ac_cv_build+set}" = set; then
1004 echo $ECHO_N "(cached) $ECHO_C" >&6
1006 ac_cv_build_alias=$build_alias
1007 test -z "$ac_cv_build_alias" &&
1008 ac_cv_build_alias=`$ac_config_guess`
1009 test -z "$ac_cv_build_alias" &&
1010 { { echo "$as_me:1010: error: cannot guess build type; you must specify one" >&5
1011 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1012 { (exit 1); exit 1; }; }
1013 ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
1014 { { echo "$as_me:1014: error: $ac_config_sub $ac_cv_build_alias failed." >&5
1015 echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed." >&2;}
1016 { (exit 1); exit 1; }; }
1019 echo "$as_me:1019: result: $ac_cv_build" >&5
1020 echo "${ECHO_T}$ac_cv_build" >&6
1022 build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1023 build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1024 build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1026 if test -f $srcdir/config.guess || test -f $ac_aux_dir/config.guess ; then
1027 echo "$as_me:1027: checking host system type" >&5
1028 echo $ECHO_N "checking host system type... $ECHO_C" >&6
1029 if test "${ac_cv_host+set}" = set; then
1030 echo $ECHO_N "(cached) $ECHO_C" >&6
1032 ac_cv_host_alias=$host_alias
1033 test -z "$ac_cv_host_alias" &&
1034 ac_cv_host_alias=$ac_cv_build_alias
1035 ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
1036 { { echo "$as_me:1036: error: $ac_config_sub $ac_cv_host_alias failed" >&5
1037 echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1038 { (exit 1); exit 1; }; }
1041 echo "$as_me:1041: result: $ac_cv_host" >&5
1042 echo "${ECHO_T}$ac_cv_host" >&6
1044 host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1045 host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1046 host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1048 system_name="$host_os"
1050 system_name="`(uname -s -r) 2>/dev/null`"
1051 if test -z "$system_name" ; then
1052 system_name="`(hostname) 2>/dev/null`"
1055 test -n "$system_name" && cat >>confdefs.h <<EOF
1056 #define SYSTEM_NAME "$system_name"
1059 if test "${cf_cv_system_name+set}" = set; then
1060 echo $ECHO_N "(cached) $ECHO_C" >&6
1062 cf_cv_system_name="$system_name"
1065 test -z "$system_name" && system_name="$cf_cv_system_name"
1066 test -n "$cf_cv_system_name" && echo "$as_me:1066: result: Configuring for $cf_cv_system_name" >&5
1067 echo "${ECHO_T}Configuring for $cf_cv_system_name" >&6
1069 if test ".$system_name" != ".$cf_cv_system_name" ; then
1070 echo "$as_me:1070: result: Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&5
1071 echo "${ECHO_T}Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&6
1072 { { echo "$as_me:1072: error: \"Please remove config.cache and try again.\"" >&5
1073 echo "$as_me: error: \"Please remove config.cache and try again.\"" >&2;}
1074 { (exit 1); exit 1; }; }
1077 test "$program_prefix" != NONE &&
1078 program_transform_name="s,^,$program_prefix,;$program_transform_name"
1079 # Use a double $ so make ignores it.
1080 test "$program_suffix" != NONE &&
1081 program_transform_name="s,\$,$program_suffix,;$program_transform_name"
1082 # Double any \ or $. echo might interpret backslashes.
1083 # By default was `s,x,x', remove it if useless.
1084 cat <<\_ACEOF >conftest.sed
1085 s/[\\$]/&&/g;s/;s,x,x,$//
1087 program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
1090 echo "$as_me:1090: checking whether ${MAKE-make} sets \${MAKE}" >&5
1091 echo $ECHO_N "checking whether ${MAKE-make} sets \${MAKE}... $ECHO_C" >&6
1092 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,./+-,__p_,'`
1093 if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
1094 echo $ECHO_N "(cached) $ECHO_C" >&6
1096 cat >conftest.make <<\EOF
1098 @echo 'ac_maketemp="${MAKE}"'
1100 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1101 eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
1102 if test -n "$ac_maketemp"; then
1103 eval ac_cv_prog_make_${ac_make}_set=yes
1105 eval ac_cv_prog_make_${ac_make}_set=no
1109 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
1110 echo "$as_me:1110: result: yes" >&5
1111 echo "${ECHO_T}yes" >&6
1114 echo "$as_me:1114: result: no" >&5
1115 echo "${ECHO_T}no" >&6
1116 SET_MAKE="MAKE=${MAKE-make}"
1120 ac_cpp='$CPP $CPPFLAGS'
1121 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1122 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1123 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1124 ac_main_return=return
1125 if test -n "$ac_tool_prefix"; then
1126 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
1127 set dummy ${ac_tool_prefix}gcc; ac_word=$2
1128 echo "$as_me:1128: checking for $ac_word" >&5
1129 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1130 if test "${ac_cv_prog_CC+set}" = set; then
1131 echo $ECHO_N "(cached) $ECHO_C" >&6
1133 if test -n "$CC"; then
1134 ac_cv_prog_CC="$CC" # Let the user override the test.
1136 ac_save_IFS=$IFS; IFS=$ac_path_separator
1138 for ac_dir in $ac_dummy; do
1140 test -z "$ac_dir" && ac_dir=.
1141 $as_executable_p "$ac_dir/$ac_word" || continue
1142 ac_cv_prog_CC="${ac_tool_prefix}gcc"
1143 echo "$as_me:1143: found $ac_dir/$ac_word" >&5
1150 if test -n "$CC"; then
1151 echo "$as_me:1151: result: $CC" >&5
1152 echo "${ECHO_T}$CC" >&6
1154 echo "$as_me:1154: result: no" >&5
1155 echo "${ECHO_T}no" >&6
1159 if test -z "$ac_cv_prog_CC"; then
1161 # Extract the first word of "gcc", so it can be a program name with args.
1162 set dummy gcc; ac_word=$2
1163 echo "$as_me:1163: checking for $ac_word" >&5
1164 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1165 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1166 echo $ECHO_N "(cached) $ECHO_C" >&6
1168 if test -n "$ac_ct_CC"; then
1169 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1171 ac_save_IFS=$IFS; IFS=$ac_path_separator
1173 for ac_dir in $ac_dummy; do
1175 test -z "$ac_dir" && ac_dir=.
1176 $as_executable_p "$ac_dir/$ac_word" || continue
1177 ac_cv_prog_ac_ct_CC="gcc"
1178 echo "$as_me:1178: found $ac_dir/$ac_word" >&5
1184 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1185 if test -n "$ac_ct_CC"; then
1186 echo "$as_me:1186: result: $ac_ct_CC" >&5
1187 echo "${ECHO_T}$ac_ct_CC" >&6
1189 echo "$as_me:1189: result: no" >&5
1190 echo "${ECHO_T}no" >&6
1198 if test -z "$CC"; then
1199 if test -n "$ac_tool_prefix"; then
1200 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
1201 set dummy ${ac_tool_prefix}cc; ac_word=$2
1202 echo "$as_me:1202: checking for $ac_word" >&5
1203 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1204 if test "${ac_cv_prog_CC+set}" = set; then
1205 echo $ECHO_N "(cached) $ECHO_C" >&6
1207 if test -n "$CC"; then
1208 ac_cv_prog_CC="$CC" # Let the user override the test.
1210 ac_save_IFS=$IFS; IFS=$ac_path_separator
1212 for ac_dir in $ac_dummy; do
1214 test -z "$ac_dir" && ac_dir=.
1215 $as_executable_p "$ac_dir/$ac_word" || continue
1216 ac_cv_prog_CC="${ac_tool_prefix}cc"
1217 echo "$as_me:1217: found $ac_dir/$ac_word" >&5
1224 if test -n "$CC"; then
1225 echo "$as_me:1225: result: $CC" >&5
1226 echo "${ECHO_T}$CC" >&6
1228 echo "$as_me:1228: result: no" >&5
1229 echo "${ECHO_T}no" >&6
1233 if test -z "$ac_cv_prog_CC"; then
1235 # Extract the first word of "cc", so it can be a program name with args.
1236 set dummy cc; ac_word=$2
1237 echo "$as_me:1237: checking for $ac_word" >&5
1238 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1239 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1240 echo $ECHO_N "(cached) $ECHO_C" >&6
1242 if test -n "$ac_ct_CC"; then
1243 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1245 ac_save_IFS=$IFS; IFS=$ac_path_separator
1247 for ac_dir in $ac_dummy; do
1249 test -z "$ac_dir" && ac_dir=.
1250 $as_executable_p "$ac_dir/$ac_word" || continue
1251 ac_cv_prog_ac_ct_CC="cc"
1252 echo "$as_me:1252: found $ac_dir/$ac_word" >&5
1258 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1259 if test -n "$ac_ct_CC"; then
1260 echo "$as_me:1260: result: $ac_ct_CC" >&5
1261 echo "${ECHO_T}$ac_ct_CC" >&6
1263 echo "$as_me:1263: result: no" >&5
1264 echo "${ECHO_T}no" >&6
1273 if test -z "$CC"; then
1274 # Extract the first word of "cc", so it can be a program name with args.
1275 set dummy cc; ac_word=$2
1276 echo "$as_me:1276: checking for $ac_word" >&5
1277 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1278 if test "${ac_cv_prog_CC+set}" = set; then
1279 echo $ECHO_N "(cached) $ECHO_C" >&6
1281 if test -n "$CC"; then
1282 ac_cv_prog_CC="$CC" # Let the user override the test.
1285 ac_save_IFS=$IFS; IFS=$ac_path_separator
1287 for ac_dir in $ac_dummy; do
1289 test -z "$ac_dir" && ac_dir=.
1290 $as_executable_p "$ac_dir/$ac_word" || continue
1291 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
1292 ac_prog_rejected=yes
1296 echo "$as_me:1296: found $ac_dir/$ac_word" >&5
1300 if test $ac_prog_rejected = yes; then
1301 # We found a bogon in the path, so make sure we never use it.
1302 set dummy $ac_cv_prog_CC
1304 if test $# != 0; then
1305 # We chose a different compiler from the bogus one.
1306 # However, it has the same basename, so the bogon will be chosen
1307 # first if we set CC to just the basename; use the full file name.
1309 set dummy "$ac_dir/$ac_word" ${1+"$@"}
1317 if test -n "$CC"; then
1318 echo "$as_me:1318: result: $CC" >&5
1319 echo "${ECHO_T}$CC" >&6
1321 echo "$as_me:1321: result: no" >&5
1322 echo "${ECHO_T}no" >&6
1326 if test -z "$CC"; then
1327 if test -n "$ac_tool_prefix"; then
1330 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
1331 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
1332 echo "$as_me:1332: checking for $ac_word" >&5
1333 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1334 if test "${ac_cv_prog_CC+set}" = set; then
1335 echo $ECHO_N "(cached) $ECHO_C" >&6
1337 if test -n "$CC"; then
1338 ac_cv_prog_CC="$CC" # Let the user override the test.
1340 ac_save_IFS=$IFS; IFS=$ac_path_separator
1342 for ac_dir in $ac_dummy; do
1344 test -z "$ac_dir" && ac_dir=.
1345 $as_executable_p "$ac_dir/$ac_word" || continue
1346 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
1347 echo "$as_me:1347: found $ac_dir/$ac_word" >&5
1354 if test -n "$CC"; then
1355 echo "$as_me:1355: result: $CC" >&5
1356 echo "${ECHO_T}$CC" >&6
1358 echo "$as_me:1358: result: no" >&5
1359 echo "${ECHO_T}no" >&6
1362 test -n "$CC" && break
1365 if test -z "$CC"; then
1369 # Extract the first word of "$ac_prog", so it can be a program name with args.
1370 set dummy $ac_prog; ac_word=$2
1371 echo "$as_me:1371: checking for $ac_word" >&5
1372 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1373 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1374 echo $ECHO_N "(cached) $ECHO_C" >&6
1376 if test -n "$ac_ct_CC"; then
1377 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1379 ac_save_IFS=$IFS; IFS=$ac_path_separator
1381 for ac_dir in $ac_dummy; do
1383 test -z "$ac_dir" && ac_dir=.
1384 $as_executable_p "$ac_dir/$ac_word" || continue
1385 ac_cv_prog_ac_ct_CC="$ac_prog"
1386 echo "$as_me:1386: found $ac_dir/$ac_word" >&5
1392 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1393 if test -n "$ac_ct_CC"; then
1394 echo "$as_me:1394: result: $ac_ct_CC" >&5
1395 echo "${ECHO_T}$ac_ct_CC" >&6
1397 echo "$as_me:1397: result: no" >&5
1398 echo "${ECHO_T}no" >&6
1401 test -n "$ac_ct_CC" && break
1409 test -z "$CC" && { { echo "$as_me:1409: error: no acceptable cc found in \$PATH" >&5
1410 echo "$as_me: error: no acceptable cc found in \$PATH" >&2;}
1411 { (exit 1); exit 1; }; }
1413 # Provide some information about the compiler.
1414 echo "$as_me:1414:" \
1415 "checking for C compiler version" >&5
1416 ac_compiler=`set X $ac_compile; echo $2`
1417 { (eval echo "$as_me:1417: \"$ac_compiler --version </dev/null >&5\"") >&5
1418 (eval $ac_compiler --version </dev/null >&5) 2>&5
1420 echo "$as_me:1420: \$? = $ac_status" >&5
1421 (exit $ac_status); }
1422 { (eval echo "$as_me:1422: \"$ac_compiler -v </dev/null >&5\"") >&5
1423 (eval $ac_compiler -v </dev/null >&5) 2>&5
1425 echo "$as_me:1425: \$? = $ac_status" >&5
1426 (exit $ac_status); }
1427 { (eval echo "$as_me:1427: \"$ac_compiler -V </dev/null >&5\"") >&5
1428 (eval $ac_compiler -V </dev/null >&5) 2>&5
1430 echo "$as_me:1430: \$? = $ac_status" >&5
1431 (exit $ac_status); }
1433 cat >conftest.$ac_ext <<_ACEOF
1434 #line 1434 "configure"
1435 #include "confdefs.h"
1445 ac_clean_files_save=$ac_clean_files
1446 ac_clean_files="$ac_clean_files a.out a.exe"
1447 # Try to create an executable without -o first, disregard a.out.
1448 # It will help us diagnose broken compilers, and finding out an intuition
1450 echo "$as_me:1450: checking for C compiler default output" >&5
1451 echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
1452 ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
1453 if { (eval echo "$as_me:1453: \"$ac_link_default\"") >&5
1454 (eval $ac_link_default) 2>&5
1456 echo "$as_me:1456: \$? = $ac_status" >&5
1457 (exit $ac_status); }; then
1458 # Find the output, starting from the most likely. This scheme is
1459 # not robust to junk in `.', hence go to wildcards (a.*) only as a last
1461 for ac_file in `ls a.exe conftest.exe 2>/dev/null;
1462 ls a.out conftest 2>/dev/null;
1463 ls a.* conftest.* 2>/dev/null`; do
1465 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1466 a.out ) # We found the default executable, but exeext='' is most
1469 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1470 # FIXME: I believe we export ac_cv_exeext for Libtool --akim.
1477 echo "$as_me: failed program was:" >&5
1478 cat conftest.$ac_ext >&5
1479 { { echo "$as_me:1479: error: C compiler cannot create executables" >&5
1480 echo "$as_me: error: C compiler cannot create executables" >&2;}
1481 { (exit 77); exit 77; }; }
1484 ac_exeext=$ac_cv_exeext
1485 echo "$as_me:1485: result: $ac_file" >&5
1486 echo "${ECHO_T}$ac_file" >&6
1488 # Check the compiler produces executables we can run. If not, either
1489 # the compiler is broken, or we cross compile.
1490 echo "$as_me:1490: checking whether the C compiler works" >&5
1491 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
1492 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
1493 # If not cross compiling, check that we can run a simple program.
1494 if test "$cross_compiling" != yes; then
1495 if { ac_try='./$ac_file'
1496 { (eval echo "$as_me:1496: \"$ac_try\"") >&5
1499 echo "$as_me:1499: \$? = $ac_status" >&5
1500 (exit $ac_status); }; }; then
1503 if test "$cross_compiling" = maybe; then
1506 { { echo "$as_me:1506: error: cannot run C compiled programs.
1507 If you meant to cross compile, use \`--host'." >&5
1508 echo "$as_me: error: cannot run C compiled programs.
1509 If you meant to cross compile, use \`--host'." >&2;}
1510 { (exit 1); exit 1; }; }
1514 echo "$as_me:1514: result: yes" >&5
1515 echo "${ECHO_T}yes" >&6
1517 rm -f a.out a.exe conftest$ac_cv_exeext
1518 ac_clean_files=$ac_clean_files_save
1519 # Check the compiler produces executables we can run. If not, either
1520 # the compiler is broken, or we cross compile.
1521 echo "$as_me:1521: checking whether we are cross compiling" >&5
1522 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
1523 echo "$as_me:1523: result: $cross_compiling" >&5
1524 echo "${ECHO_T}$cross_compiling" >&6
1526 echo "$as_me:1526: checking for executable suffix" >&5
1527 echo $ECHO_N "checking for executable suffix... $ECHO_C" >&6
1528 if { (eval echo "$as_me:1528: \"$ac_link\"") >&5
1529 (eval $ac_link) 2>&5
1531 echo "$as_me:1531: \$? = $ac_status" >&5
1532 (exit $ac_status); }; then
1533 # If both `conftest.exe' and `conftest' are `present' (well, observable)
1534 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
1535 # work properly (i.e., refer to `conftest.exe'), while it won't with
1537 for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do
1539 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1540 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1547 { { echo "$as_me:1547: error: cannot compute EXEEXT: cannot compile and link" >&5
1548 echo "$as_me: error: cannot compute EXEEXT: cannot compile and link" >&2;}
1549 { (exit 1); exit 1; }; }
1552 rm -f conftest$ac_cv_exeext
1553 echo "$as_me:1553: result: $ac_cv_exeext" >&5
1554 echo "${ECHO_T}$ac_cv_exeext" >&6
1556 rm -f conftest.$ac_ext
1557 EXEEXT=$ac_cv_exeext
1559 echo "$as_me:1559: checking for object suffix" >&5
1560 echo $ECHO_N "checking for object suffix... $ECHO_C" >&6
1561 if test "${ac_cv_objext+set}" = set; then
1562 echo $ECHO_N "(cached) $ECHO_C" >&6
1564 cat >conftest.$ac_ext <<_ACEOF
1565 #line 1565 "configure"
1566 #include "confdefs.h"
1576 rm -f conftest.o conftest.obj
1577 if { (eval echo "$as_me:1577: \"$ac_compile\"") >&5
1578 (eval $ac_compile) 2>&5
1580 echo "$as_me:1580: \$? = $ac_status" >&5
1581 (exit $ac_status); }; then
1582 for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
1584 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.map | *.inf ) ;;
1585 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
1590 echo "$as_me: failed program was:" >&5
1591 cat conftest.$ac_ext >&5
1592 { { echo "$as_me:1592: error: cannot compute OBJEXT: cannot compile" >&5
1593 echo "$as_me: error: cannot compute OBJEXT: cannot compile" >&2;}
1594 { (exit 1); exit 1; }; }
1597 rm -f conftest.$ac_cv_objext conftest.$ac_ext
1599 echo "$as_me:1599: result: $ac_cv_objext" >&5
1600 echo "${ECHO_T}$ac_cv_objext" >&6
1601 OBJEXT=$ac_cv_objext
1603 echo "$as_me:1603: checking whether we are using the GNU C compiler" >&5
1604 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
1605 if test "${ac_cv_c_compiler_gnu+set}" = set; then
1606 echo $ECHO_N "(cached) $ECHO_C" >&6
1608 cat >conftest.$ac_ext <<_ACEOF
1609 #line 1609 "configure"
1610 #include "confdefs.h"
1623 rm -f conftest.$ac_objext
1624 if { (eval echo "$as_me:1624: \"$ac_compile\"") >&5
1625 (eval $ac_compile) 2>&5
1627 echo "$as_me:1627: \$? = $ac_status" >&5
1628 (exit $ac_status); } &&
1629 { ac_try='test -s conftest.$ac_objext'
1630 { (eval echo "$as_me:1630: \"$ac_try\"") >&5
1633 echo "$as_me:1633: \$? = $ac_status" >&5
1634 (exit $ac_status); }; }; then
1637 echo "$as_me: failed program was:" >&5
1638 cat conftest.$ac_ext >&5
1641 rm -f conftest.$ac_objext conftest.$ac_ext
1642 ac_cv_c_compiler_gnu=$ac_compiler_gnu
1645 echo "$as_me:1645: result: $ac_cv_c_compiler_gnu" >&5
1646 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
1647 GCC=`test $ac_compiler_gnu = yes && echo yes`
1648 ac_test_CFLAGS=${CFLAGS+set}
1649 ac_save_CFLAGS=$CFLAGS
1651 echo "$as_me:1651: checking whether $CC accepts -g" >&5
1652 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
1653 if test "${ac_cv_prog_cc_g+set}" = set; then
1654 echo $ECHO_N "(cached) $ECHO_C" >&6
1656 cat >conftest.$ac_ext <<_ACEOF
1657 #line 1657 "configure"
1658 #include "confdefs.h"
1668 rm -f conftest.$ac_objext
1669 if { (eval echo "$as_me:1669: \"$ac_compile\"") >&5
1670 (eval $ac_compile) 2>&5
1672 echo "$as_me:1672: \$? = $ac_status" >&5
1673 (exit $ac_status); } &&
1674 { ac_try='test -s conftest.$ac_objext'
1675 { (eval echo "$as_me:1675: \"$ac_try\"") >&5
1678 echo "$as_me:1678: \$? = $ac_status" >&5
1679 (exit $ac_status); }; }; then
1682 echo "$as_me: failed program was:" >&5
1683 cat conftest.$ac_ext >&5
1686 rm -f conftest.$ac_objext conftest.$ac_ext
1688 echo "$as_me:1688: result: $ac_cv_prog_cc_g" >&5
1689 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
1690 if test "$ac_test_CFLAGS" = set; then
1691 CFLAGS=$ac_save_CFLAGS
1692 elif test $ac_cv_prog_cc_g = yes; then
1693 if test "$GCC" = yes; then
1699 if test "$GCC" = yes; then
1705 # Some people use a C++ compiler to compile C. Since we use `exit',
1706 # in C++ we need to declare it. In case someone uses the same compiler
1707 # for both compiling C and C++ we need to have the C++ compiler decide
1708 # the declaration of exit, since it's the most demanding environment.
1709 cat >conftest.$ac_ext <<_ACEOF
1714 rm -f conftest.$ac_objext
1715 if { (eval echo "$as_me:1715: \"$ac_compile\"") >&5
1716 (eval $ac_compile) 2>&5
1718 echo "$as_me:1718: \$? = $ac_status" >&5
1719 (exit $ac_status); } &&
1720 { ac_try='test -s conftest.$ac_objext'
1721 { (eval echo "$as_me:1721: \"$ac_try\"") >&5
1724 echo "$as_me:1724: \$? = $ac_status" >&5
1725 (exit $ac_status); }; }; then
1726 for ac_declaration in \
1728 '#include <stdlib.h>' \
1729 'extern "C" void std::exit (int) throw (); using std::exit;' \
1730 'extern "C" void std::exit (int); using std::exit;' \
1731 'extern "C" void exit (int) throw ();' \
1732 'extern "C" void exit (int);' \
1735 cat >conftest.$ac_ext <<_ACEOF
1736 #line 1736 "configure"
1737 #include "confdefs.h"
1748 rm -f conftest.$ac_objext
1749 if { (eval echo "$as_me:1749: \"$ac_compile\"") >&5
1750 (eval $ac_compile) 2>&5
1752 echo "$as_me:1752: \$? = $ac_status" >&5
1753 (exit $ac_status); } &&
1754 { ac_try='test -s conftest.$ac_objext'
1755 { (eval echo "$as_me:1755: \"$ac_try\"") >&5
1758 echo "$as_me:1758: \$? = $ac_status" >&5
1759 (exit $ac_status); }; }; then
1762 echo "$as_me: failed program was:" >&5
1763 cat conftest.$ac_ext >&5
1766 rm -f conftest.$ac_objext conftest.$ac_ext
1767 cat >conftest.$ac_ext <<_ACEOF
1768 #line 1768 "configure"
1769 #include "confdefs.h"
1779 rm -f conftest.$ac_objext
1780 if { (eval echo "$as_me:1780: \"$ac_compile\"") >&5
1781 (eval $ac_compile) 2>&5
1783 echo "$as_me:1783: \$? = $ac_status" >&5
1784 (exit $ac_status); } &&
1785 { ac_try='test -s conftest.$ac_objext'
1786 { (eval echo "$as_me:1786: \"$ac_try\"") >&5
1789 echo "$as_me:1789: \$? = $ac_status" >&5
1790 (exit $ac_status); }; }; then
1793 echo "$as_me: failed program was:" >&5
1794 cat conftest.$ac_ext >&5
1796 rm -f conftest.$ac_objext conftest.$ac_ext
1799 if test -n "$ac_declaration"; then
1800 echo '#ifdef __cplusplus' >>confdefs.h
1801 echo $ac_declaration >>confdefs.h
1802 echo '#endif' >>confdefs.h
1806 echo "$as_me: failed program was:" >&5
1807 cat conftest.$ac_ext >&5
1809 rm -f conftest.$ac_objext conftest.$ac_ext
1811 ac_cpp='$CPP $CPPFLAGS'
1812 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1813 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1814 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1815 ac_main_return=return
1818 ac_cpp='$CPP $CPPFLAGS'
1819 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1820 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1821 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1822 ac_main_return=return
1823 echo "$as_me:1823: checking how to run the C preprocessor" >&5
1824 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
1825 # On Suns, sometimes $CPP names a directory.
1826 if test -n "$CPP" && test -d "$CPP"; then
1829 if test -z "$CPP"; then
1830 if test "${ac_cv_prog_CPP+set}" = set; then
1831 echo $ECHO_N "(cached) $ECHO_C" >&6
1833 # Double quotes because CPP needs to be expanded
1834 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
1837 for ac_c_preproc_warn_flag in '' yes
1839 # Use a header file that comes with gcc, so configuring glibc
1840 # with a fresh cross-compiler works.
1841 # On the NeXT, cc -E runs the code through the compiler's parser,
1842 # not just through cpp. "Syntax error" is here to catch this case.
1843 cat >conftest.$ac_ext <<_ACEOF
1844 #line 1844 "configure"
1845 #include "confdefs.h"
1849 if { (eval echo "$as_me:1849: \"$ac_cpp conftest.$ac_ext\"") >&5
1850 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
1852 egrep -v '^ *\+' conftest.er1 >conftest.err
1854 cat conftest.err >&5
1855 echo "$as_me:1855: \$? = $ac_status" >&5
1856 (exit $ac_status); } >/dev/null; then
1857 if test -s conftest.err; then
1858 ac_cpp_err=$ac_c_preproc_warn_flag
1865 if test -z "$ac_cpp_err"; then
1868 echo "$as_me: failed program was:" >&5
1869 cat conftest.$ac_ext >&5
1870 # Broken: fails on valid input.
1873 rm -f conftest.err conftest.$ac_ext
1875 # OK, works on sane cases. Now check whether non-existent headers
1876 # can be detected and how.
1877 cat >conftest.$ac_ext <<_ACEOF
1878 #line 1878 "configure"
1879 #include "confdefs.h"
1880 #include <ac_nonexistent.h>
1882 if { (eval echo "$as_me:1882: \"$ac_cpp conftest.$ac_ext\"") >&5
1883 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
1885 egrep -v '^ *\+' conftest.er1 >conftest.err
1887 cat conftest.err >&5
1888 echo "$as_me:1888: \$? = $ac_status" >&5
1889 (exit $ac_status); } >/dev/null; then
1890 if test -s conftest.err; then
1891 ac_cpp_err=$ac_c_preproc_warn_flag
1898 if test -z "$ac_cpp_err"; then
1899 # Broken: success on invalid input.
1902 echo "$as_me: failed program was:" >&5
1903 cat conftest.$ac_ext >&5
1904 # Passes both tests.
1908 rm -f conftest.err conftest.$ac_ext
1911 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
1912 rm -f conftest.err conftest.$ac_ext
1913 if $ac_preproc_ok; then
1925 echo "$as_me:1925: result: $CPP" >&5
1926 echo "${ECHO_T}$CPP" >&6
1928 for ac_c_preproc_warn_flag in '' yes
1930 # Use a header file that comes with gcc, so configuring glibc
1931 # with a fresh cross-compiler works.
1932 # On the NeXT, cc -E runs the code through the compiler's parser,
1933 # not just through cpp. "Syntax error" is here to catch this case.
1934 cat >conftest.$ac_ext <<_ACEOF
1935 #line 1935 "configure"
1936 #include "confdefs.h"
1940 if { (eval echo "$as_me:1940: \"$ac_cpp conftest.$ac_ext\"") >&5
1941 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
1943 egrep -v '^ *\+' conftest.er1 >conftest.err
1945 cat conftest.err >&5
1946 echo "$as_me:1946: \$? = $ac_status" >&5
1947 (exit $ac_status); } >/dev/null; then
1948 if test -s conftest.err; then
1949 ac_cpp_err=$ac_c_preproc_warn_flag
1956 if test -z "$ac_cpp_err"; then
1959 echo "$as_me: failed program was:" >&5
1960 cat conftest.$ac_ext >&5
1961 # Broken: fails on valid input.
1964 rm -f conftest.err conftest.$ac_ext
1966 # OK, works on sane cases. Now check whether non-existent headers
1967 # can be detected and how.
1968 cat >conftest.$ac_ext <<_ACEOF
1969 #line 1969 "configure"
1970 #include "confdefs.h"
1971 #include <ac_nonexistent.h>
1973 if { (eval echo "$as_me:1973: \"$ac_cpp conftest.$ac_ext\"") >&5
1974 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
1976 egrep -v '^ *\+' conftest.er1 >conftest.err
1978 cat conftest.err >&5
1979 echo "$as_me:1979: \$? = $ac_status" >&5
1980 (exit $ac_status); } >/dev/null; then
1981 if test -s conftest.err; then
1982 ac_cpp_err=$ac_c_preproc_warn_flag
1989 if test -z "$ac_cpp_err"; then
1990 # Broken: success on invalid input.
1993 echo "$as_me: failed program was:" >&5
1994 cat conftest.$ac_ext >&5
1995 # Passes both tests.
1999 rm -f conftest.err conftest.$ac_ext
2002 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2003 rm -f conftest.err conftest.$ac_ext
2004 if $ac_preproc_ok; then
2007 { { echo "$as_me:2007: error: C preprocessor \"$CPP\" fails sanity check" >&5
2008 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;}
2009 { (exit 1); exit 1; }; }
2013 ac_cpp='$CPP $CPPFLAGS'
2014 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2015 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2016 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2017 ac_main_return=return
2019 for ac_prog in mawk gawk nawk awk
2021 # Extract the first word of "$ac_prog", so it can be a program name with args.
2022 set dummy $ac_prog; ac_word=$2
2023 echo "$as_me:2023: checking for $ac_word" >&5
2024 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2025 if test "${ac_cv_prog_AWK+set}" = set; then
2026 echo $ECHO_N "(cached) $ECHO_C" >&6
2028 if test -n "$AWK"; then
2029 ac_cv_prog_AWK="$AWK" # Let the user override the test.
2031 ac_save_IFS=$IFS; IFS=$ac_path_separator
2033 for ac_dir in $ac_dummy; do
2035 test -z "$ac_dir" && ac_dir=.
2036 $as_executable_p "$ac_dir/$ac_word" || continue
2037 ac_cv_prog_AWK="$ac_prog"
2038 echo "$as_me:2038: found $ac_dir/$ac_word" >&5
2045 if test -n "$AWK"; then
2046 echo "$as_me:2046: result: $AWK" >&5
2047 echo "${ECHO_T}$AWK" >&6
2049 echo "$as_me:2049: result: no" >&5
2050 echo "${ECHO_T}no" >&6
2053 test -n "$AWK" && break
2056 # Find a good install program. We prefer a C program (faster),
2057 # so one script is as good as another. But avoid the broken or
2058 # incompatible versions:
2059 # SysV /etc/install, /usr/sbin/install
2060 # SunOS /usr/etc/install
2061 # IRIX /sbin/install
2063 # AmigaOS /C/install, which installs bootblocks on floppy discs
2064 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
2065 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
2066 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
2067 # ./install, which can be erroneously created by make from ./install.sh.
2068 echo "$as_me:2068: checking for a BSD compatible install" >&5
2069 echo $ECHO_N "checking for a BSD compatible install... $ECHO_C" >&6
2070 if test -z "$INSTALL"; then
2071 if test "${ac_cv_path_install+set}" = set; then
2072 echo $ECHO_N "(cached) $ECHO_C" >&6
2074 ac_save_IFS=$IFS; IFS=$ac_path_separator
2075 for ac_dir in $PATH; do
2077 # Account for people who put trailing slashes in PATH elements.
2079 / | ./ | .// | /cC/* \
2080 | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* \
2083 # OSF1 and SCO ODT 3.0 have their own names for install.
2084 # Don't use installbsd from OSF since it installs stuff as root
2086 for ac_prog in ginstall scoinst install; do
2087 if $as_executable_p "$ac_dir/$ac_prog"; then
2088 if test $ac_prog = install &&
2089 grep dspmsg "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2090 # AIX install. It has an incompatible calling convention.
2092 elif test $ac_prog = install &&
2093 grep pwplus "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2094 # program-specific install script used by HP pwplus--don't use.
2097 ac_cv_path_install="$ac_dir/$ac_prog -c"
2107 if test "${ac_cv_path_install+set}" = set; then
2108 INSTALL=$ac_cv_path_install
2110 # As a last resort, use the slow shell script. We don't cache a
2111 # path for INSTALL within a source directory, because that will
2112 # break other packages using the cache if that directory is
2113 # removed, or if the path is relative.
2114 INSTALL=$ac_install_sh
2117 echo "$as_me:2117: result: $INSTALL" >&5
2118 echo "${ECHO_T}$INSTALL" >&6
2120 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
2121 # It thinks the first close brace ends the variable substitution.
2122 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
2124 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
2126 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
2132 cf_dir=`echo $INSTALL | sed -e 's%/[^/]*$%%'`
2133 test -z "$cf_dir" && cf_dir=.
2134 INSTALL=`cd $cf_dir && pwd`/`echo $INSTALL | sed -e 's%^.*/%%'`
2138 for ac_prog in tdlint lint alint splint lclint
2140 # Extract the first word of "$ac_prog", so it can be a program name with args.
2141 set dummy $ac_prog; ac_word=$2
2142 echo "$as_me:2142: checking for $ac_word" >&5
2143 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2144 if test "${ac_cv_prog_LINT+set}" = set; then
2145 echo $ECHO_N "(cached) $ECHO_C" >&6
2147 if test -n "$LINT"; then
2148 ac_cv_prog_LINT="$LINT" # Let the user override the test.
2150 ac_save_IFS=$IFS; IFS=$ac_path_separator
2152 for ac_dir in $ac_dummy; do
2154 test -z "$ac_dir" && ac_dir=.
2155 $as_executable_p "$ac_dir/$ac_word" || continue
2156 ac_cv_prog_LINT="$ac_prog"
2157 echo "$as_me:2157: found $ac_dir/$ac_word" >&5
2163 LINT=$ac_cv_prog_LINT
2164 if test -n "$LINT"; then
2165 echo "$as_me:2165: result: $LINT" >&5
2166 echo "${ECHO_T}$LINT" >&6
2168 echo "$as_me:2168: result: no" >&5
2169 echo "${ECHO_T}no" >&6
2172 test -n "$LINT" && break
2175 echo "$as_me:2175: checking if filesystem supports mixed-case filenames" >&5
2176 echo $ECHO_N "checking if filesystem supports mixed-case filenames... $ECHO_C" >&6
2177 if test "${cf_cv_mixedcase+set}" = set; then
2178 echo $ECHO_N "(cached) $ECHO_C" >&6
2181 if test "$cross_compiling" = yes ; then
2182 case $target_alias in #(vi
2183 *-os2-emx*|*-msdosdjgpp*|*-cygwin*|*-mingw32*|*-uwin*) #(vi
2191 rm -f conftest CONFTEST
2193 if test -f CONFTEST ; then
2198 rm -f conftest CONFTEST
2202 echo "$as_me:2202: result: $cf_cv_mixedcase" >&5
2203 echo "${ECHO_T}$cf_cv_mixedcase" >&6
2204 test "$cf_cv_mixedcase" = yes && cat >>confdefs.h <<\EOF
2205 #define MIXEDCASE_FILENAMES 1
2208 for ac_prog in exctags ctags
2210 # Extract the first word of "$ac_prog", so it can be a program name with args.
2211 set dummy $ac_prog; ac_word=$2
2212 echo "$as_me:2212: checking for $ac_word" >&5
2213 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2214 if test "${ac_cv_prog_CTAGS+set}" = set; then
2215 echo $ECHO_N "(cached) $ECHO_C" >&6
2217 if test -n "$CTAGS"; then
2218 ac_cv_prog_CTAGS="$CTAGS" # Let the user override the test.
2220 ac_save_IFS=$IFS; IFS=$ac_path_separator
2222 for ac_dir in $ac_dummy; do
2224 test -z "$ac_dir" && ac_dir=.
2225 $as_executable_p "$ac_dir/$ac_word" || continue
2226 ac_cv_prog_CTAGS="$ac_prog"
2227 echo "$as_me:2227: found $ac_dir/$ac_word" >&5
2233 CTAGS=$ac_cv_prog_CTAGS
2234 if test -n "$CTAGS"; then
2235 echo "$as_me:2235: result: $CTAGS" >&5
2236 echo "${ECHO_T}$CTAGS" >&6
2238 echo "$as_me:2238: result: no" >&5
2239 echo "${ECHO_T}no" >&6
2242 test -n "$CTAGS" && break
2245 for ac_prog in exetags etags
2247 # Extract the first word of "$ac_prog", so it can be a program name with args.
2248 set dummy $ac_prog; ac_word=$2
2249 echo "$as_me:2249: checking for $ac_word" >&5
2250 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2251 if test "${ac_cv_prog_ETAGS+set}" = set; then
2252 echo $ECHO_N "(cached) $ECHO_C" >&6
2254 if test -n "$ETAGS"; then
2255 ac_cv_prog_ETAGS="$ETAGS" # Let the user override the test.
2257 ac_save_IFS=$IFS; IFS=$ac_path_separator
2259 for ac_dir in $ac_dummy; do
2261 test -z "$ac_dir" && ac_dir=.
2262 $as_executable_p "$ac_dir/$ac_word" || continue
2263 ac_cv_prog_ETAGS="$ac_prog"
2264 echo "$as_me:2264: found $ac_dir/$ac_word" >&5
2270 ETAGS=$ac_cv_prog_ETAGS
2271 if test -n "$ETAGS"; then
2272 echo "$as_me:2272: result: $ETAGS" >&5
2273 echo "${ECHO_T}$ETAGS" >&6
2275 echo "$as_me:2275: result: no" >&5
2276 echo "${ECHO_T}no" >&6
2279 test -n "$ETAGS" && break
2282 # Extract the first word of "${CTAGS:-ctags}", so it can be a program name with args.
2283 set dummy ${CTAGS:-ctags}; ac_word=$2
2284 echo "$as_me:2284: checking for $ac_word" >&5
2285 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2286 if test "${ac_cv_prog_MAKE_LOWER_TAGS+set}" = set; then
2287 echo $ECHO_N "(cached) $ECHO_C" >&6
2289 if test -n "$MAKE_LOWER_TAGS"; then
2290 ac_cv_prog_MAKE_LOWER_TAGS="$MAKE_LOWER_TAGS" # Let the user override the test.
2292 ac_save_IFS=$IFS; IFS=$ac_path_separator
2294 for ac_dir in $ac_dummy; do
2296 test -z "$ac_dir" && ac_dir=.
2297 $as_executable_p "$ac_dir/$ac_word" || continue
2298 ac_cv_prog_MAKE_LOWER_TAGS="yes"
2299 echo "$as_me:2299: found $ac_dir/$ac_word" >&5
2303 test -z "$ac_cv_prog_MAKE_LOWER_TAGS" && ac_cv_prog_MAKE_LOWER_TAGS="no"
2306 MAKE_LOWER_TAGS=$ac_cv_prog_MAKE_LOWER_TAGS
2307 if test -n "$MAKE_LOWER_TAGS"; then
2308 echo "$as_me:2308: result: $MAKE_LOWER_TAGS" >&5
2309 echo "${ECHO_T}$MAKE_LOWER_TAGS" >&6
2311 echo "$as_me:2311: result: no" >&5
2312 echo "${ECHO_T}no" >&6
2315 if test "$cf_cv_mixedcase" = yes ; then
2316 # Extract the first word of "${ETAGS:-etags}", so it can be a program name with args.
2317 set dummy ${ETAGS:-etags}; ac_word=$2
2318 echo "$as_me:2318: checking for $ac_word" >&5
2319 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2320 if test "${ac_cv_prog_MAKE_UPPER_TAGS+set}" = set; then
2321 echo $ECHO_N "(cached) $ECHO_C" >&6
2323 if test -n "$MAKE_UPPER_TAGS"; then
2324 ac_cv_prog_MAKE_UPPER_TAGS="$MAKE_UPPER_TAGS" # Let the user override the test.
2326 ac_save_IFS=$IFS; IFS=$ac_path_separator
2328 for ac_dir in $ac_dummy; do
2330 test -z "$ac_dir" && ac_dir=.
2331 $as_executable_p "$ac_dir/$ac_word" || continue
2332 ac_cv_prog_MAKE_UPPER_TAGS="yes"
2333 echo "$as_me:2333: found $ac_dir/$ac_word" >&5
2337 test -z "$ac_cv_prog_MAKE_UPPER_TAGS" && ac_cv_prog_MAKE_UPPER_TAGS="no"
2340 MAKE_UPPER_TAGS=$ac_cv_prog_MAKE_UPPER_TAGS
2341 if test -n "$MAKE_UPPER_TAGS"; then
2342 echo "$as_me:2342: result: $MAKE_UPPER_TAGS" >&5
2343 echo "${ECHO_T}$MAKE_UPPER_TAGS" >&6
2345 echo "$as_me:2345: result: no" >&5
2346 echo "${ECHO_T}no" >&6
2353 if test "$MAKE_UPPER_TAGS" = yes ; then
2359 if test "$MAKE_LOWER_TAGS" = yes ; then
2365 echo "$as_me:2365: checking if -lm needed for math functions" >&5
2366 echo $ECHO_N "checking if -lm needed for math functions... $ECHO_C" >&6
2367 if test "${cf_cv_need_libm+set}" = set; then
2368 echo $ECHO_N "(cached) $ECHO_C" >&6
2371 cat >conftest.$ac_ext <<_ACEOF
2372 #line 2372 "configure"
2373 #include "confdefs.h"
2381 double x = rand(); printf("result = %g\n", sin(x))
2386 rm -f conftest.$ac_objext conftest$ac_exeext
2387 if { (eval echo "$as_me:2387: \"$ac_link\"") >&5
2388 (eval $ac_link) 2>&5
2390 echo "$as_me:2390: \$? = $ac_status" >&5
2391 (exit $ac_status); } &&
2392 { ac_try='test -s conftest$ac_exeext'
2393 { (eval echo "$as_me:2393: \"$ac_try\"") >&5
2396 echo "$as_me:2396: \$? = $ac_status" >&5
2397 (exit $ac_status); }; }; then
2400 echo "$as_me: failed program was:" >&5
2401 cat conftest.$ac_ext >&5
2404 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
2406 echo "$as_me:2406: result: $cf_cv_need_libm" >&5
2407 echo "${ECHO_T}$cf_cv_need_libm" >&6
2408 if test "$cf_cv_need_libm" = yes
2416 CC_SHARED_OPTS=unknown
2417 CPPFLAGS="$CPPFLAGS"
2419 DFT_OBJ_SUBDIR=`pwd|sed -e's:.*/::'`
2420 DFT_UPR_MODEL="NORMAL"
2437 TINFO_LIBS='$(LIBS_CURSES)'
2438 cf_cv_abi_version=""
2439 cf_cv_rel_version=""
2444 # This should have been defined by AC_PROG_CC
2447 # Check for user's environment-breakage by stuffing CFLAGS/CPPFLAGS content
2448 # into CC. This will not help with broken scripts that wrap the compiler with
2449 # options, but eliminates a more common category of user confusion.
2450 echo "$as_me:2450: checking \$CC variable" >&5
2451 echo $ECHO_N "checking \$CC variable... $ECHO_C" >&6
2454 echo "$as_me:2454: result: broken" >&5
2455 echo "${ECHO_T}broken" >&6
2456 { echo "$as_me:2456: WARNING: your environment misuses the CC variable to hold CFLAGS/CPPFLAGS options" >&5
2457 echo "$as_me: WARNING: your environment misuses the CC variable to hold CFLAGS/CPPFLAGS options" >&2;}
2459 cf_flags=`echo "$CC" | sed -e 's/^[^ ]*[ ]//'`
2460 CC=`echo "$CC" | sed -e 's/[ ].*//'`
2465 cf_new_extra_cppflags=
2467 for cf_add_cflags in $cf_flags
2469 case $cf_fix_cppflags in
2471 case $cf_add_cflags in #(vi
2472 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
2473 case $cf_add_cflags in
2475 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
2477 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
2478 && test -z "${cf_tst_cflags}" \
2479 && cf_fix_cppflags=yes
2481 if test $cf_fix_cppflags = yes ; then
2482 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2484 elif test "${cf_tst_cflags}" = "\"'" ; then
2485 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2491 *$cf_add_cflags) #(vi
2494 case $cf_add_cflags in #(vi
2496 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
2498 CPPFLAGS=`echo "$CPPFLAGS" | \
2499 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
2500 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
2504 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
2509 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
2514 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2516 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
2518 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
2519 && test -z "${cf_tst_cflags}" \
2520 && cf_fix_cppflags=no
2525 if test -n "$cf_new_cflags" ; then
2527 CFLAGS="$CFLAGS $cf_new_cflags"
2530 if test -n "$cf_new_cppflags" ; then
2532 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
2535 if test -n "$cf_new_extra_cppflags" ; then
2537 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
2542 echo "$as_me:2542: result: ok" >&5
2543 echo "${ECHO_T}ok" >&6
2547 echo "$as_me:2547: checking for ${CC:-cc} option to accept ANSI C" >&5
2548 echo $ECHO_N "checking for ${CC:-cc} option to accept ANSI C... $ECHO_C" >&6
2549 if test "${cf_cv_ansi_cc+set}" = set; then
2550 echo $ECHO_N "(cached) $ECHO_C" >&6
2554 cf_save_CFLAGS="$CFLAGS"
2555 cf_save_CPPFLAGS="$CPPFLAGS"
2556 # Don't try gcc -ansi; that turns off useful extensions and
2557 # breaks some systems' header files.
2558 # AIX -qlanglvl=ansi
2559 # Ultrix and OSF/1 -std1
2560 # HP-UX -Aa -D_HPUX_SOURCE
2562 # UnixWare 1.2 (cannot use -Xc, since ANSI/POSIX clashes)
2563 for cf_arg in "-DCC_HAS_PROTOS" \
2568 "-Aa -D_HPUX_SOURCE" \
2575 cf_new_extra_cppflags=
2577 for cf_add_cflags in $cf_arg
2579 case $cf_fix_cppflags in
2581 case $cf_add_cflags in #(vi
2582 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
2583 case $cf_add_cflags in
2585 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
2587 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
2588 && test -z "${cf_tst_cflags}" \
2589 && cf_fix_cppflags=yes
2591 if test $cf_fix_cppflags = yes ; then
2592 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2594 elif test "${cf_tst_cflags}" = "\"'" ; then
2595 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2601 *$cf_add_cflags) #(vi
2604 case $cf_add_cflags in #(vi
2606 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
2608 CPPFLAGS=`echo "$CPPFLAGS" | \
2609 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
2610 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
2614 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
2619 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
2624 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2626 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
2628 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
2629 && test -z "${cf_tst_cflags}" \
2630 && cf_fix_cppflags=no
2635 if test -n "$cf_new_cflags" ; then
2637 CFLAGS="$CFLAGS $cf_new_cflags"
2640 if test -n "$cf_new_cppflags" ; then
2642 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
2645 if test -n "$cf_new_extra_cppflags" ; then
2647 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
2650 cat >conftest.$ac_ext <<_ACEOF
2651 #line 2651 "configure"
2652 #include "confdefs.h"
2654 #ifndef CC_HAS_PROTOS
2655 #if !defined(__STDC__) || (__STDC__ != 1)
2664 int test (int i, double x);
2665 struct s1 {int (*f) (int a);};
2666 struct s2 {int (*f) (double a);};
2671 rm -f conftest.$ac_objext
2672 if { (eval echo "$as_me:2672: \"$ac_compile\"") >&5
2673 (eval $ac_compile) 2>&5
2675 echo "$as_me:2675: \$? = $ac_status" >&5
2676 (exit $ac_status); } &&
2677 { ac_try='test -s conftest.$ac_objext'
2678 { (eval echo "$as_me:2678: \"$ac_try\"") >&5
2681 echo "$as_me:2681: \$? = $ac_status" >&5
2682 (exit $ac_status); }; }; then
2683 cf_cv_ansi_cc="$cf_arg"; break
2685 echo "$as_me: failed program was:" >&5
2686 cat conftest.$ac_ext >&5
2688 rm -f conftest.$ac_objext conftest.$ac_ext
2690 CFLAGS="$cf_save_CFLAGS"
2691 CPPFLAGS="$cf_save_CPPFLAGS"
2694 echo "$as_me:2694: result: $cf_cv_ansi_cc" >&5
2695 echo "${ECHO_T}$cf_cv_ansi_cc" >&6
2697 if test "$cf_cv_ansi_cc" != "no"; then
2698 if test ".$cf_cv_ansi_cc" != ".-DCC_HAS_PROTOS"; then
2703 cf_new_extra_cppflags=
2705 for cf_add_cflags in $cf_cv_ansi_cc
2707 case $cf_fix_cppflags in
2709 case $cf_add_cflags in #(vi
2710 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
2711 case $cf_add_cflags in
2713 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
2715 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
2716 && test -z "${cf_tst_cflags}" \
2717 && cf_fix_cppflags=yes
2719 if test $cf_fix_cppflags = yes ; then
2720 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2722 elif test "${cf_tst_cflags}" = "\"'" ; then
2723 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2729 *$cf_add_cflags) #(vi
2732 case $cf_add_cflags in #(vi
2734 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
2736 CPPFLAGS=`echo "$CPPFLAGS" | \
2737 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
2738 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
2742 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
2747 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
2752 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
2754 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
2756 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
2757 && test -z "${cf_tst_cflags}" \
2758 && cf_fix_cppflags=no
2763 if test -n "$cf_new_cflags" ; then
2765 CFLAGS="$CFLAGS $cf_new_cflags"
2768 if test -n "$cf_new_cppflags" ; then
2770 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
2773 if test -n "$cf_new_extra_cppflags" ; then
2775 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
2779 cat >>confdefs.h <<\EOF
2780 #define CC_HAS_PROTOS 1
2786 if test "$cf_cv_ansi_cc" = "no"; then
2787 { { echo "$as_me:2787: error: Your compiler does not appear to recognize prototypes.
2788 You have the following choices:
2789 a. adjust your compiler options
2790 b. get an up-to-date compiler
2791 c. use a wrapper such as unproto" >&5
2792 echo "$as_me: error: Your compiler does not appear to recognize prototypes.
2793 You have the following choices:
2794 a. adjust your compiler options
2795 b. get an up-to-date compiler
2796 c. use a wrapper such as unproto" >&2;}
2797 { (exit 1); exit 1; }; }
2800 if test "$GCC" = yes
2802 cat > conftest.i <<EOF
2804 #define GCC_PRINTF 0
2809 #ifndef GCC_NORETURN
2810 #define GCC_NORETURN /* nothing */
2813 #define GCC_UNUSED /* nothing */
2816 if test "$GCC" = yes
2818 { echo "$as_me:2818: checking for $CC __attribute__ directives..." >&5
2819 echo "$as_me: checking for $CC __attribute__ directives..." >&6;}
2820 cat > conftest.$ac_ext <<EOF
2821 #line 2821 "${as_me:-configure}"
2822 #include "confdefs.h"
2823 #include "conftest.h"
2824 #include "conftest.i"
2826 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
2828 #define GCC_PRINTFLIKE(fmt,var) /*nothing*/
2831 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
2833 #define GCC_SCANFLIKE(fmt,var) /*nothing*/
2835 extern void wow(char *,...) GCC_SCANFLIKE(1,2);
2836 extern void oops(char *,...) GCC_PRINTFLIKE(1,2) GCC_NORETURN;
2837 extern void foo(void) GCC_NORETURN;
2838 int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { return 0; }
2840 cf_printf_attribute=no
2841 cf_scanf_attribute=no
2842 for cf_attribute in scanf printf unused noreturn
2845 cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
2847 cf_directive="__attribute__(($cf_attribute))"
2848 echo "checking for $CC $cf_directive" 1>&5
2850 case $cf_attribute in #(vi
2852 cf_printf_attribute=yes
2853 cat >conftest.h <<EOF
2854 #define GCC_$cf_ATTRIBUTE 1
2858 cf_scanf_attribute=yes
2859 cat >conftest.h <<EOF
2860 #define GCC_$cf_ATTRIBUTE 1
2864 cat >conftest.h <<EOF
2865 #define GCC_$cf_ATTRIBUTE $cf_directive
2870 if { (eval echo "$as_me:2870: \"$ac_compile\"") >&5
2871 (eval $ac_compile) 2>&5
2873 echo "$as_me:2873: \$? = $ac_status" >&5
2874 (exit $ac_status); }; then
2875 test -n "$verbose" && echo "$as_me:2875: result: ... $cf_attribute" >&5
2876 echo "${ECHO_T}... $cf_attribute" >&6
2877 cat conftest.h >>confdefs.h
2878 case $cf_attribute in #(vi
2880 if test "$cf_printf_attribute" = no ; then
2881 cat >>confdefs.h <<EOF
2882 #define GCC_PRINTFLIKE(fmt,var) /* nothing */
2885 cat >>confdefs.h <<EOF
2886 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
2891 if test "$cf_scanf_attribute" = no ; then
2892 cat >>confdefs.h <<EOF
2893 #define GCC_SCANFLIKE(fmt,var) /* nothing */
2896 cat >>confdefs.h <<EOF
2897 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
2905 fgrep define conftest.i >>confdefs.h
2911 cf_POSIX_C_SOURCE=199506L
2914 case $host_os in #(vi
2916 cf_xopen_source="-D_ALL_SOURCE"
2922 cf_xopen_source="-D_APPLE_C_SOURCE"
2925 cf_xopen_source="-D_DARWIN_C_SOURCE"
2928 freebsd*|dragonfly*) #(vi
2929 # 5.x headers associate
2930 # _XOPEN_SOURCE=600 with _POSIX_C_SOURCE=200112L
2931 # _XOPEN_SOURCE=500 with _POSIX_C_SOURCE=199506L
2932 cf_POSIX_C_SOURCE=200112L
2934 cf_xopen_source="-D_BSD_TYPES -D__BSD_VISIBLE -D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
2937 cf_xopen_source="-D_HPUX_SOURCE -D_XOPEN_SOURCE=500"
2940 cf_xopen_source="-D_HPUX_SOURCE"
2943 cf_xopen_source="-D_SGI_SOURCE"
2946 linux*|gnu*|mint*|k*bsd*-gnu) #(vi
2948 echo "$as_me:2948: checking if we must define _GNU_SOURCE" >&5
2949 echo $ECHO_N "checking if we must define _GNU_SOURCE... $ECHO_C" >&6
2950 if test "${cf_cv_gnu_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
2983 echo "$as_me: failed program was:" >&5
2984 cat conftest.$ac_ext >&5
2986 CPPFLAGS="$CPPFLAGS -D_GNU_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
3016 echo "$as_me: failed program was:" >&5
3017 cat conftest.$ac_ext >&5
3018 cf_cv_gnu_source=yes
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_gnu_source" >&5
3028 echo "${ECHO_T}$cf_cv_gnu_source" >&6
3029 test "$cf_cv_gnu_source" = yes && CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE"
3033 # setting _XOPEN_SOURCE or _POSIX_SOURCE breaks <sys/select.h> and other headers which use u_int / u_short types
3036 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
3038 cf_save_CFLAGS="$CFLAGS"
3039 cf_save_CPPFLAGS="$CPPFLAGS"
3041 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
3042 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3043 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
3045 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
3046 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3047 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
3049 echo "$as_me:3049: checking if we should define _POSIX_C_SOURCE" >&5
3050 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
3051 if test "${cf_cv_posix_c_source+set}" = set; then
3052 echo $ECHO_N "(cached) $ECHO_C" >&6
3055 echo "${as_me:-configure}:3055: testing if the symbol is already defined go no further ..." 1>&5
3057 cat >conftest.$ac_ext <<_ACEOF
3058 #line 3058 "configure"
3059 #include "confdefs.h"
3060 #include <sys/types.h>
3065 #ifndef _POSIX_C_SOURCE
3072 rm -f conftest.$ac_objext
3073 if { (eval echo "$as_me:3073: \"$ac_compile\"") >&5
3074 (eval $ac_compile) 2>&5
3076 echo "$as_me:3076: \$? = $ac_status" >&5
3077 (exit $ac_status); } &&
3078 { ac_try='test -s conftest.$ac_objext'
3079 { (eval echo "$as_me:3079: \"$ac_try\"") >&5
3082 echo "$as_me:3082: \$? = $ac_status" >&5
3083 (exit $ac_status); }; }; then
3084 cf_cv_posix_c_source=no
3086 echo "$as_me: failed program was:" >&5
3087 cat conftest.$ac_ext >&5
3088 cf_want_posix_source=no
3089 case .$cf_POSIX_C_SOURCE in #(vi
3091 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
3094 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
3095 cf_want_posix_source=yes
3098 cf_want_posix_source=yes
3101 if test "$cf_want_posix_source" = yes ; then
3102 cat >conftest.$ac_ext <<_ACEOF
3103 #line 3103 "configure"
3104 #include "confdefs.h"
3105 #include <sys/types.h>
3110 #ifdef _POSIX_SOURCE
3117 rm -f conftest.$ac_objext
3118 if { (eval echo "$as_me:3118: \"$ac_compile\"") >&5
3119 (eval $ac_compile) 2>&5
3121 echo "$as_me:3121: \$? = $ac_status" >&5
3122 (exit $ac_status); } &&
3123 { ac_try='test -s conftest.$ac_objext'
3124 { (eval echo "$as_me:3124: \"$ac_try\"") >&5
3127 echo "$as_me:3127: \$? = $ac_status" >&5
3128 (exit $ac_status); }; }; then
3131 echo "$as_me: failed program was:" >&5
3132 cat conftest.$ac_ext >&5
3133 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
3135 rm -f conftest.$ac_objext conftest.$ac_ext
3138 echo "${as_me:-configure}:3138: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
3140 CFLAGS="$cf_trim_CFLAGS"
3141 CPPFLAGS="$cf_trim_CPPFLAGS $cf_cv_posix_c_source"
3143 echo "${as_me:-configure}:3143: testing if the second compile does not leave our definition intact error ..." 1>&5
3145 cat >conftest.$ac_ext <<_ACEOF
3146 #line 3146 "configure"
3147 #include "confdefs.h"
3148 #include <sys/types.h>
3153 #ifndef _POSIX_C_SOURCE
3160 rm -f conftest.$ac_objext
3161 if { (eval echo "$as_me:3161: \"$ac_compile\"") >&5
3162 (eval $ac_compile) 2>&5
3164 echo "$as_me:3164: \$? = $ac_status" >&5
3165 (exit $ac_status); } &&
3166 { ac_try='test -s conftest.$ac_objext'
3167 { (eval echo "$as_me:3167: \"$ac_try\"") >&5
3170 echo "$as_me:3170: \$? = $ac_status" >&5
3171 (exit $ac_status); }; }; then
3174 echo "$as_me: failed program was:" >&5
3175 cat conftest.$ac_ext >&5
3176 cf_cv_posix_c_source=no
3178 rm -f conftest.$ac_objext conftest.$ac_ext
3179 CFLAGS="$cf_save_CFLAGS"
3180 CPPFLAGS="$cf_save_CPPFLAGS"
3183 rm -f conftest.$ac_objext conftest.$ac_ext
3186 echo "$as_me:3186: result: $cf_cv_posix_c_source" >&5
3187 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
3189 if test "$cf_cv_posix_c_source" != no ; then
3190 CFLAGS="$cf_trim_CFLAGS"
3191 CPPFLAGS="$cf_trim_CPPFLAGS"
3196 cf_new_extra_cppflags=
3198 for cf_add_cflags in $cf_cv_posix_c_source
3200 case $cf_fix_cppflags in
3202 case $cf_add_cflags in #(vi
3203 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
3204 case $cf_add_cflags in
3206 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3208 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3209 && test -z "${cf_tst_cflags}" \
3210 && cf_fix_cppflags=yes
3212 if test $cf_fix_cppflags = yes ; then
3213 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3215 elif test "${cf_tst_cflags}" = "\"'" ; then
3216 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3222 *$cf_add_cflags) #(vi
3225 case $cf_add_cflags in #(vi
3227 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3229 CPPFLAGS=`echo "$CPPFLAGS" | \
3230 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3231 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3235 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
3240 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
3245 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3247 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
3249 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3250 && test -z "${cf_tst_cflags}" \
3251 && cf_fix_cppflags=no
3256 if test -n "$cf_new_cflags" ; then
3258 CFLAGS="$CFLAGS $cf_new_cflags"
3261 if test -n "$cf_new_cppflags" ; then
3263 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
3266 if test -n "$cf_new_extra_cppflags" ; then
3268 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
3275 cf_xopen_source="-D_NETBSD_SOURCE" # setting _XOPEN_SOURCE breaks IPv6 for lynx on NetBSD 1.6, breaks xterm, is not needed for ncursesw
3278 # setting _XOPEN_SOURCE lower than 500 breaks g++ compile with wchar.h, needed for ncursesw
3279 cf_xopen_source="-D_BSD_SOURCE"
3283 # setting _XOPEN_SOURCE breaks xterm on OpenBSD 2.8, is not needed for ncursesw
3286 cf_xopen_source="-D_OSF_SOURCE"
3289 cf_xopen_source="-D_QNX_SOURCE"
3292 # setting _XOPEN_SOURCE breaks Lynx on SCO Unix / OpenServer
3295 cf_xopen_source="-D__EXTENSIONS__"
3299 echo "$as_me:3299: checking if we should define _XOPEN_SOURCE" >&5
3300 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
3301 if test "${cf_cv_xopen_source+set}" = set; then
3302 echo $ECHO_N "(cached) $ECHO_C" >&6
3305 cat >conftest.$ac_ext <<_ACEOF
3306 #line 3306 "configure"
3307 #include "confdefs.h"
3311 #include <sys/types.h>
3317 #ifndef _XOPEN_SOURCE
3324 rm -f conftest.$ac_objext
3325 if { (eval echo "$as_me:3325: \"$ac_compile\"") >&5
3326 (eval $ac_compile) 2>&5
3328 echo "$as_me:3328: \$? = $ac_status" >&5
3329 (exit $ac_status); } &&
3330 { ac_try='test -s conftest.$ac_objext'
3331 { (eval echo "$as_me:3331: \"$ac_try\"") >&5
3334 echo "$as_me:3334: \$? = $ac_status" >&5
3335 (exit $ac_status); }; }; then
3336 cf_cv_xopen_source=no
3338 echo "$as_me: failed program was:" >&5
3339 cat conftest.$ac_ext >&5
3341 CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
3342 cat >conftest.$ac_ext <<_ACEOF
3343 #line 3343 "configure"
3344 #include "confdefs.h"
3348 #include <sys/types.h>
3354 #ifdef _XOPEN_SOURCE
3361 rm -f conftest.$ac_objext
3362 if { (eval echo "$as_me:3362: \"$ac_compile\"") >&5
3363 (eval $ac_compile) 2>&5
3365 echo "$as_me:3365: \$? = $ac_status" >&5
3366 (exit $ac_status); } &&
3367 { ac_try='test -s conftest.$ac_objext'
3368 { (eval echo "$as_me:3368: \"$ac_try\"") >&5
3371 echo "$as_me:3371: \$? = $ac_status" >&5
3372 (exit $ac_status); }; }; then
3373 cf_cv_xopen_source=no
3375 echo "$as_me: failed program was:" >&5
3376 cat conftest.$ac_ext >&5
3377 cf_cv_xopen_source=$cf_XOPEN_SOURCE
3379 rm -f conftest.$ac_objext conftest.$ac_ext
3383 rm -f conftest.$ac_objext conftest.$ac_ext
3386 echo "$as_me:3386: result: $cf_cv_xopen_source" >&5
3387 echo "${ECHO_T}$cf_cv_xopen_source" >&6
3389 if test "$cf_cv_xopen_source" != no ; then
3391 CFLAGS=`echo "$CFLAGS" | \
3392 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3393 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
3395 CPPFLAGS=`echo "$CPPFLAGS" | \
3396 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3397 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
3399 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
3404 cf_new_extra_cppflags=
3406 for cf_add_cflags in $cf_temp_xopen_source
3408 case $cf_fix_cppflags in
3410 case $cf_add_cflags in #(vi
3411 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
3412 case $cf_add_cflags in
3414 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3416 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3417 && test -z "${cf_tst_cflags}" \
3418 && cf_fix_cppflags=yes
3420 if test $cf_fix_cppflags = yes ; then
3421 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3423 elif test "${cf_tst_cflags}" = "\"'" ; then
3424 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3430 *$cf_add_cflags) #(vi
3433 case $cf_add_cflags in #(vi
3435 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3437 CPPFLAGS=`echo "$CPPFLAGS" | \
3438 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3439 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3443 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
3448 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
3453 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3455 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
3457 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3458 && test -z "${cf_tst_cflags}" \
3459 && cf_fix_cppflags=no
3464 if test -n "$cf_new_cflags" ; then
3466 CFLAGS="$CFLAGS $cf_new_cflags"
3469 if test -n "$cf_new_cppflags" ; then
3471 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
3474 if test -n "$cf_new_extra_cppflags" ; then
3476 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
3481 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
3483 cf_save_CFLAGS="$CFLAGS"
3484 cf_save_CPPFLAGS="$CPPFLAGS"
3486 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
3487 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3488 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
3490 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
3491 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3492 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
3494 echo "$as_me:3494: checking if we should define _POSIX_C_SOURCE" >&5
3495 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
3496 if test "${cf_cv_posix_c_source+set}" = set; then
3497 echo $ECHO_N "(cached) $ECHO_C" >&6
3500 echo "${as_me:-configure}:3500: testing if the symbol is already defined go no further ..." 1>&5
3502 cat >conftest.$ac_ext <<_ACEOF
3503 #line 3503 "configure"
3504 #include "confdefs.h"
3505 #include <sys/types.h>
3510 #ifndef _POSIX_C_SOURCE
3517 rm -f conftest.$ac_objext
3518 if { (eval echo "$as_me:3518: \"$ac_compile\"") >&5
3519 (eval $ac_compile) 2>&5
3521 echo "$as_me:3521: \$? = $ac_status" >&5
3522 (exit $ac_status); } &&
3523 { ac_try='test -s conftest.$ac_objext'
3524 { (eval echo "$as_me:3524: \"$ac_try\"") >&5
3527 echo "$as_me:3527: \$? = $ac_status" >&5
3528 (exit $ac_status); }; }; then
3529 cf_cv_posix_c_source=no
3531 echo "$as_me: failed program was:" >&5
3532 cat conftest.$ac_ext >&5
3533 cf_want_posix_source=no
3534 case .$cf_POSIX_C_SOURCE in #(vi
3536 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
3539 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
3540 cf_want_posix_source=yes
3543 cf_want_posix_source=yes
3546 if test "$cf_want_posix_source" = yes ; then
3547 cat >conftest.$ac_ext <<_ACEOF
3548 #line 3548 "configure"
3549 #include "confdefs.h"
3550 #include <sys/types.h>
3555 #ifdef _POSIX_SOURCE
3562 rm -f conftest.$ac_objext
3563 if { (eval echo "$as_me:3563: \"$ac_compile\"") >&5
3564 (eval $ac_compile) 2>&5
3566 echo "$as_me:3566: \$? = $ac_status" >&5
3567 (exit $ac_status); } &&
3568 { ac_try='test -s conftest.$ac_objext'
3569 { (eval echo "$as_me:3569: \"$ac_try\"") >&5
3572 echo "$as_me:3572: \$? = $ac_status" >&5
3573 (exit $ac_status); }; }; then
3576 echo "$as_me: failed program was:" >&5
3577 cat conftest.$ac_ext >&5
3578 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
3580 rm -f conftest.$ac_objext conftest.$ac_ext
3583 echo "${as_me:-configure}:3583: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
3585 CFLAGS="$cf_trim_CFLAGS"
3586 CPPFLAGS="$cf_trim_CPPFLAGS $cf_cv_posix_c_source"
3588 echo "${as_me:-configure}:3588: testing if the second compile does not leave our definition intact error ..." 1>&5
3590 cat >conftest.$ac_ext <<_ACEOF
3591 #line 3591 "configure"
3592 #include "confdefs.h"
3593 #include <sys/types.h>
3598 #ifndef _POSIX_C_SOURCE
3605 rm -f conftest.$ac_objext
3606 if { (eval echo "$as_me:3606: \"$ac_compile\"") >&5
3607 (eval $ac_compile) 2>&5
3609 echo "$as_me:3609: \$? = $ac_status" >&5
3610 (exit $ac_status); } &&
3611 { ac_try='test -s conftest.$ac_objext'
3612 { (eval echo "$as_me:3612: \"$ac_try\"") >&5
3615 echo "$as_me:3615: \$? = $ac_status" >&5
3616 (exit $ac_status); }; }; then
3619 echo "$as_me: failed program was:" >&5
3620 cat conftest.$ac_ext >&5
3621 cf_cv_posix_c_source=no
3623 rm -f conftest.$ac_objext conftest.$ac_ext
3624 CFLAGS="$cf_save_CFLAGS"
3625 CPPFLAGS="$cf_save_CPPFLAGS"
3628 rm -f conftest.$ac_objext conftest.$ac_ext
3631 echo "$as_me:3631: result: $cf_cv_posix_c_source" >&5
3632 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
3634 if test "$cf_cv_posix_c_source" != no ; then
3635 CFLAGS="$cf_trim_CFLAGS"
3636 CPPFLAGS="$cf_trim_CPPFLAGS"
3641 cf_new_extra_cppflags=
3643 for cf_add_cflags in $cf_cv_posix_c_source
3645 case $cf_fix_cppflags in
3647 case $cf_add_cflags in #(vi
3648 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
3649 case $cf_add_cflags in
3651 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3653 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3654 && test -z "${cf_tst_cflags}" \
3655 && cf_fix_cppflags=yes
3657 if test $cf_fix_cppflags = yes ; then
3658 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3660 elif test "${cf_tst_cflags}" = "\"'" ; then
3661 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3667 *$cf_add_cflags) #(vi
3670 case $cf_add_cflags in #(vi
3672 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3674 CPPFLAGS=`echo "$CPPFLAGS" | \
3675 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3676 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3680 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
3685 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
3690 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3692 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
3694 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3695 && test -z "${cf_tst_cflags}" \
3696 && cf_fix_cppflags=no
3701 if test -n "$cf_new_cflags" ; then
3703 CFLAGS="$CFLAGS $cf_new_cflags"
3706 if test -n "$cf_new_cppflags" ; then
3708 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
3711 if test -n "$cf_new_extra_cppflags" ; then
3713 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
3721 if test -n "$cf_xopen_source" ; then
3726 cf_new_extra_cppflags=
3728 for cf_add_cflags in $cf_xopen_source
3730 case $cf_fix_cppflags in
3732 case $cf_add_cflags in #(vi
3733 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
3734 case $cf_add_cflags in
3736 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3738 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3739 && test -z "${cf_tst_cflags}" \
3740 && cf_fix_cppflags=yes
3742 if test $cf_fix_cppflags = yes ; then
3743 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3745 elif test "${cf_tst_cflags}" = "\"'" ; then
3746 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3752 *$cf_add_cflags) #(vi
3755 case $cf_add_cflags in #(vi
3757 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3759 CPPFLAGS=`echo "$CPPFLAGS" | \
3760 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3761 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3765 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
3770 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
3775 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3777 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
3779 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3780 && test -z "${cf_tst_cflags}" \
3781 && cf_fix_cppflags=no
3786 if test -n "$cf_new_cflags" ; then
3788 CFLAGS="$CFLAGS $cf_new_cflags"
3791 if test -n "$cf_new_cppflags" ; then
3793 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
3796 if test -n "$cf_new_extra_cppflags" ; then
3798 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
3803 if test -n "$cf_XOPEN_SOURCE" && test -z "$cf_cv_xopen_source" ; then
3804 echo "$as_me:3804: checking if _XOPEN_SOURCE really is set" >&5
3805 echo $ECHO_N "checking if _XOPEN_SOURCE really is set... $ECHO_C" >&6
3806 cat >conftest.$ac_ext <<_ACEOF
3807 #line 3807 "configure"
3808 #include "confdefs.h"
3814 #ifndef _XOPEN_SOURCE
3821 rm -f conftest.$ac_objext
3822 if { (eval echo "$as_me:3822: \"$ac_compile\"") >&5
3823 (eval $ac_compile) 2>&5
3825 echo "$as_me:3825: \$? = $ac_status" >&5
3826 (exit $ac_status); } &&
3827 { ac_try='test -s conftest.$ac_objext'
3828 { (eval echo "$as_me:3828: \"$ac_try\"") >&5
3831 echo "$as_me:3831: \$? = $ac_status" >&5
3832 (exit $ac_status); }; }; then
3833 cf_XOPEN_SOURCE_set=yes
3835 echo "$as_me: failed program was:" >&5
3836 cat conftest.$ac_ext >&5
3837 cf_XOPEN_SOURCE_set=no
3839 rm -f conftest.$ac_objext conftest.$ac_ext
3840 echo "$as_me:3840: result: $cf_XOPEN_SOURCE_set" >&5
3841 echo "${ECHO_T}$cf_XOPEN_SOURCE_set" >&6
3842 if test $cf_XOPEN_SOURCE_set = yes
3844 cat >conftest.$ac_ext <<_ACEOF
3845 #line 3845 "configure"
3846 #include "confdefs.h"
3852 #if (_XOPEN_SOURCE - 0) < $cf_XOPEN_SOURCE
3859 rm -f conftest.$ac_objext
3860 if { (eval echo "$as_me:3860: \"$ac_compile\"") >&5
3861 (eval $ac_compile) 2>&5
3863 echo "$as_me:3863: \$? = $ac_status" >&5
3864 (exit $ac_status); } &&
3865 { ac_try='test -s conftest.$ac_objext'
3866 { (eval echo "$as_me:3866: \"$ac_try\"") >&5
3869 echo "$as_me:3869: \$? = $ac_status" >&5
3870 (exit $ac_status); }; }; then
3871 cf_XOPEN_SOURCE_set_ok=yes
3873 echo "$as_me: failed program was:" >&5
3874 cat conftest.$ac_ext >&5
3875 cf_XOPEN_SOURCE_set_ok=no
3877 rm -f conftest.$ac_objext conftest.$ac_ext
3878 if test $cf_XOPEN_SOURCE_set_ok = no
3880 { echo "$as_me:3880: WARNING: _XOPEN_SOURCE is lower than requested" >&5
3881 echo "$as_me: WARNING: _XOPEN_SOURCE is lower than requested" >&2;}
3885 echo "$as_me:3885: checking if we should define _XOPEN_SOURCE" >&5
3886 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
3887 if test "${cf_cv_xopen_source+set}" = set; then
3888 echo $ECHO_N "(cached) $ECHO_C" >&6
3891 cat >conftest.$ac_ext <<_ACEOF
3892 #line 3892 "configure"
3893 #include "confdefs.h"
3897 #include <sys/types.h>
3903 #ifndef _XOPEN_SOURCE
3910 rm -f conftest.$ac_objext
3911 if { (eval echo "$as_me:3911: \"$ac_compile\"") >&5
3912 (eval $ac_compile) 2>&5
3914 echo "$as_me:3914: \$? = $ac_status" >&5
3915 (exit $ac_status); } &&
3916 { ac_try='test -s conftest.$ac_objext'
3917 { (eval echo "$as_me:3917: \"$ac_try\"") >&5
3920 echo "$as_me:3920: \$? = $ac_status" >&5
3921 (exit $ac_status); }; }; then
3922 cf_cv_xopen_source=no
3924 echo "$as_me: failed program was:" >&5
3925 cat conftest.$ac_ext >&5
3927 CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
3928 cat >conftest.$ac_ext <<_ACEOF
3929 #line 3929 "configure"
3930 #include "confdefs.h"
3934 #include <sys/types.h>
3940 #ifdef _XOPEN_SOURCE
3947 rm -f conftest.$ac_objext
3948 if { (eval echo "$as_me:3948: \"$ac_compile\"") >&5
3949 (eval $ac_compile) 2>&5
3951 echo "$as_me:3951: \$? = $ac_status" >&5
3952 (exit $ac_status); } &&
3953 { ac_try='test -s conftest.$ac_objext'
3954 { (eval echo "$as_me:3954: \"$ac_try\"") >&5
3957 echo "$as_me:3957: \$? = $ac_status" >&5
3958 (exit $ac_status); }; }; then
3959 cf_cv_xopen_source=no
3961 echo "$as_me: failed program was:" >&5
3962 cat conftest.$ac_ext >&5
3963 cf_cv_xopen_source=$cf_XOPEN_SOURCE
3965 rm -f conftest.$ac_objext conftest.$ac_ext
3969 rm -f conftest.$ac_objext conftest.$ac_ext
3972 echo "$as_me:3972: result: $cf_cv_xopen_source" >&5
3973 echo "${ECHO_T}$cf_cv_xopen_source" >&6
3975 if test "$cf_cv_xopen_source" != no ; then
3977 CFLAGS=`echo "$CFLAGS" | \
3978 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3979 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
3981 CPPFLAGS=`echo "$CPPFLAGS" | \
3982 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3983 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
3985 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
3990 cf_new_extra_cppflags=
3992 for cf_add_cflags in $cf_temp_xopen_source
3994 case $cf_fix_cppflags in
3996 case $cf_add_cflags in #(vi
3997 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
3998 case $cf_add_cflags in
4000 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4002 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
4003 && test -z "${cf_tst_cflags}" \
4004 && cf_fix_cppflags=yes
4006 if test $cf_fix_cppflags = yes ; then
4007 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4009 elif test "${cf_tst_cflags}" = "\"'" ; then
4010 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4016 *$cf_add_cflags) #(vi
4019 case $cf_add_cflags in #(vi
4021 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4023 CPPFLAGS=`echo "$CPPFLAGS" | \
4024 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4025 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4029 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
4034 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
4039 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4041 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
4043 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
4044 && test -z "${cf_tst_cflags}" \
4045 && cf_fix_cppflags=no
4050 if test -n "$cf_new_cflags" ; then
4052 CFLAGS="$CFLAGS $cf_new_cflags"
4055 if test -n "$cf_new_cppflags" ; then
4057 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
4060 if test -n "$cf_new_extra_cppflags" ; then
4062 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
4070 echo "$as_me:4070: checking for $CC option to accept ANSI C" >&5
4071 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
4072 if test "${ac_cv_prog_cc_stdc+set}" = set; then
4073 echo $ECHO_N "(cached) $ECHO_C" >&6
4075 ac_cv_prog_cc_stdc=no
4077 cat >conftest.$ac_ext <<_ACEOF
4078 #line 4078 "configure"
4079 #include "confdefs.h"
4082 #include <sys/types.h>
4083 #include <sys/stat.h>
4084 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
4085 struct buf { int x; };
4086 FILE * (*rcsopen) (struct buf *, struct stat *, int);
4087 static char *e (p, i)
4093 static char *f (char * (*g) (char **, int), char **p, ...)
4098 s = g (p, va_arg (v,int));
4102 int test (int i, double x);
4103 struct s1 {int (*f) (int a);};
4104 struct s2 {int (*f) (double a);};
4105 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
4111 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
4116 # Don't try gcc -ansi; that turns off useful extensions and
4117 # breaks some systems' header files.
4118 # AIX -qlanglvl=ansi
4119 # Ultrix and OSF/1 -std1
4120 # HP-UX 10.20 and later -Ae
4121 # HP-UX older versions -Aa -D_HPUX_SOURCE
4122 # SVR4 -Xc -D__EXTENSIONS__
4123 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
4125 CC="$ac_save_CC $ac_arg"
4126 rm -f conftest.$ac_objext
4127 if { (eval echo "$as_me:4127: \"$ac_compile\"") >&5
4128 (eval $ac_compile) 2>&5
4130 echo "$as_me:4130: \$? = $ac_status" >&5
4131 (exit $ac_status); } &&
4132 { ac_try='test -s conftest.$ac_objext'
4133 { (eval echo "$as_me:4133: \"$ac_try\"") >&5
4136 echo "$as_me:4136: \$? = $ac_status" >&5
4137 (exit $ac_status); }; }; then
4138 ac_cv_prog_cc_stdc=$ac_arg
4141 echo "$as_me: failed program was:" >&5
4142 cat conftest.$ac_ext >&5
4144 rm -f conftest.$ac_objext
4146 rm -f conftest.$ac_ext conftest.$ac_objext
4151 case "x$ac_cv_prog_cc_stdc" in
4153 echo "$as_me:4153: result: none needed" >&5
4154 echo "${ECHO_T}none needed" >&6 ;;
4156 echo "$as_me:4156: result: $ac_cv_prog_cc_stdc" >&5
4157 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
4158 CC="$CC $ac_cv_prog_cc_stdc" ;;
4161 echo "$as_me:4161: checking for an ANSI C-conforming const" >&5
4162 echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
4163 if test "${ac_cv_c_const+set}" = set; then
4164 echo $ECHO_N "(cached) $ECHO_C" >&6
4166 cat >conftest.$ac_ext <<_ACEOF
4167 #line 4167 "configure"
4168 #include "confdefs.h"
4173 /* FIXME: Include the comments suggested by Paul. */
4175 /* Ultrix mips cc rejects this. */
4176 typedef int charset[2];
4178 /* SunOS 4.1.1 cc rejects this. */
4179 char const *const *ccp;
4181 /* NEC SVR4.0.2 mips cc rejects this. */
4182 struct point {int x, y;};
4183 static struct point const zero = {0,0};
4184 /* AIX XL C 1.02.0.0 rejects this.
4185 It does not let you subtract one const X* pointer from another in
4186 an arm of an if-expression whose if-part is not a constant
4188 const char *g = "string";
4189 ccp = &g + (g ? g-g : 0);
4190 /* HPUX 7.0 cc rejects these. */
4193 ccp = (char const *const *) p;
4194 { /* SCO 3.2v4 cc rejects this. */
4196 char const *s = 0 ? (char *) 0 : (char const *) 0;
4200 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
4202 const int *foo = &x[0];
4205 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
4206 typedef const int *iptr;
4210 { /* AIX XL C 1.02.0.0 rejects this saying
4211 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
4212 struct s { int j; const int *ap[3]; };
4213 struct s *b; b->j = 5;
4215 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
4224 rm -f conftest.$ac_objext
4225 if { (eval echo "$as_me:4225: \"$ac_compile\"") >&5
4226 (eval $ac_compile) 2>&5
4228 echo "$as_me:4228: \$? = $ac_status" >&5
4229 (exit $ac_status); } &&
4230 { ac_try='test -s conftest.$ac_objext'
4231 { (eval echo "$as_me:4231: \"$ac_try\"") >&5
4234 echo "$as_me:4234: \$? = $ac_status" >&5
4235 (exit $ac_status); }; }; then
4238 echo "$as_me: failed program was:" >&5
4239 cat conftest.$ac_ext >&5
4242 rm -f conftest.$ac_objext conftest.$ac_ext
4244 echo "$as_me:4244: result: $ac_cv_c_const" >&5
4245 echo "${ECHO_T}$ac_cv_c_const" >&6
4246 if test $ac_cv_c_const = no; then
4248 cat >>confdefs.h <<\EOF
4254 echo "$as_me:4254: checking for signal global datatype" >&5
4255 echo $ECHO_N "checking for signal global datatype... $ECHO_C" >&6
4256 if test "${cf_cv_sig_atomic_t+set}" = set; then
4257 echo $ECHO_N "(cached) $ECHO_C" >&6
4261 "volatile sig_atomic_t" \
4265 cat >conftest.$ac_ext <<_ACEOF
4266 #line 4266 "configure"
4267 #include "confdefs.h"
4269 #include <sys/types.h>
4275 static void handler(int sig)
4282 signal(SIGINT, handler);
4288 rm -f conftest.$ac_objext
4289 if { (eval echo "$as_me:4289: \"$ac_compile\"") >&5
4290 (eval $ac_compile) 2>&5
4292 echo "$as_me:4292: \$? = $ac_status" >&5
4293 (exit $ac_status); } &&
4294 { ac_try='test -s conftest.$ac_objext'
4295 { (eval echo "$as_me:4295: \"$ac_try\"") >&5
4298 echo "$as_me:4298: \$? = $ac_status" >&5
4299 (exit $ac_status); }; }; then
4300 cf_cv_sig_atomic_t=$cf_type
4302 echo "$as_me: failed program was:" >&5
4303 cat conftest.$ac_ext >&5
4304 cf_cv_sig_atomic_t=no
4306 rm -f conftest.$ac_objext conftest.$ac_ext
4307 test "$cf_cv_sig_atomic_t" != no && break
4312 echo "$as_me:4312: result: $cf_cv_sig_atomic_t" >&5
4313 echo "${ECHO_T}$cf_cv_sig_atomic_t" >&6
4314 test "$cf_cv_sig_atomic_t" != no && cat >>confdefs.h <<EOF
4315 #define SIG_ATOMIC_T $cf_cv_sig_atomic_t
4318 echo "$as_me:4318: checking if you want to see long compiling messages" >&5
4319 echo $ECHO_N "checking if you want to see long compiling messages... $ECHO_C" >&6
4321 # Check whether --enable-echo or --disable-echo was given.
4322 if test "${enable_echo+set}" = set; then
4323 enableval="$enable_echo"
4324 test "$enableval" != no && enableval=yes
4325 if test "$enableval" != "yes" ; then
4328 ECHO_LD='@echo linking $@;'
4329 RULE_CC='@echo compiling $<'
4330 SHOW_CC='@echo compiling $@'
4352 echo "$as_me:4352: result: $enableval" >&5
4353 echo "${ECHO_T}$enableval" >&6
4356 if test "$GCC" = yes ; then
4357 echo "$as_me:4357: checking version of $CC" >&5
4358 echo $ECHO_N "checking version of $CC... $ECHO_C" >&6
4359 GCC_VERSION="`${CC} --version 2>/dev/null | sed -e '2,$d' -e 's/^.*(GCC) //' -e 's/^[^0-9.]*//' -e 's/[^0-9.].*//'`"
4360 test -z "$GCC_VERSION" && GCC_VERSION=unknown
4361 echo "$as_me:4361: result: $GCC_VERSION" >&5
4362 echo "${ECHO_T}$GCC_VERSION" >&6
4365 if ( test "$GCC" = yes || test "$GXX" = yes )
4367 echo "$as_me:4367: checking if you want to turn on gcc warnings" >&5
4368 echo $ECHO_N "checking if you want to turn on gcc warnings... $ECHO_C" >&6
4370 # Check whether --enable-warnings or --disable-warnings was given.
4371 if test "${enable_warnings+set}" = set; then
4372 enableval="$enable_warnings"
4373 test "$enableval" != yes && enableval=no
4374 if test "$enableval" != "no" ; then
4384 echo "$as_me:4384: result: $with_warnings" >&5
4385 echo "${ECHO_T}$with_warnings" >&6
4386 if test "$with_warnings" = "yes"
4389 if test "$GCC" = yes
4391 cat > conftest.i <<EOF
4393 #define GCC_PRINTF 0
4398 #ifndef GCC_NORETURN
4399 #define GCC_NORETURN /* nothing */
4402 #define GCC_UNUSED /* nothing */
4405 if test "$GCC" = yes
4407 { echo "$as_me:4407: checking for $CC __attribute__ directives..." >&5
4408 echo "$as_me: checking for $CC __attribute__ directives..." >&6;}
4409 cat > conftest.$ac_ext <<EOF
4410 #line 4410 "${as_me:-configure}"
4411 #include "confdefs.h"
4412 #include "conftest.h"
4413 #include "conftest.i"
4415 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
4417 #define GCC_PRINTFLIKE(fmt,var) /*nothing*/
4420 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
4422 #define GCC_SCANFLIKE(fmt,var) /*nothing*/
4424 extern void wow(char *,...) GCC_SCANFLIKE(1,2);
4425 extern void oops(char *,...) GCC_PRINTFLIKE(1,2) GCC_NORETURN;
4426 extern void foo(void) GCC_NORETURN;
4427 int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { return 0; }
4429 cf_printf_attribute=no
4430 cf_scanf_attribute=no
4431 for cf_attribute in scanf printf unused noreturn
4434 cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
4436 cf_directive="__attribute__(($cf_attribute))"
4437 echo "checking for $CC $cf_directive" 1>&5
4439 case $cf_attribute in #(vi
4441 cf_printf_attribute=yes
4442 cat >conftest.h <<EOF
4443 #define GCC_$cf_ATTRIBUTE 1
4447 cf_scanf_attribute=yes
4448 cat >conftest.h <<EOF
4449 #define GCC_$cf_ATTRIBUTE 1
4453 cat >conftest.h <<EOF
4454 #define GCC_$cf_ATTRIBUTE $cf_directive
4459 if { (eval echo "$as_me:4459: \"$ac_compile\"") >&5
4460 (eval $ac_compile) 2>&5
4462 echo "$as_me:4462: \$? = $ac_status" >&5
4463 (exit $ac_status); }; then
4464 test -n "$verbose" && echo "$as_me:4464: result: ... $cf_attribute" >&5
4465 echo "${ECHO_T}... $cf_attribute" >&6
4466 cat conftest.h >>confdefs.h
4467 case $cf_attribute in #(vi
4469 if test "$cf_printf_attribute" = no ; then
4470 cat >>confdefs.h <<EOF
4471 #define GCC_PRINTFLIKE(fmt,var) /* nothing */
4474 cat >>confdefs.h <<EOF
4475 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
4480 if test "$cf_scanf_attribute" = no ; then
4481 cat >>confdefs.h <<EOF
4482 #define GCC_SCANFLIKE(fmt,var) /* nothing */
4485 cat >>confdefs.h <<EOF
4486 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
4494 fgrep define conftest.i >>confdefs.h
4501 if test "$GCC" = yes ; then
4504 echo "$as_me:4504: checking if this is really Intel C compiler" >&5
4505 echo $ECHO_N "checking if this is really Intel C compiler... $ECHO_C" >&6
4506 cf_save_CFLAGS="$CFLAGS"
4507 CFLAGS="$CFLAGS -no-gcc"
4508 cat >conftest.$ac_ext <<_ACEOF
4509 #line 4509 "configure"
4510 #include "confdefs.h"
4516 #ifdef __INTEL_COMPILER
4525 rm -f conftest.$ac_objext
4526 if { (eval echo "$as_me:4526: \"$ac_compile\"") >&5
4527 (eval $ac_compile) 2>&5
4529 echo "$as_me:4529: \$? = $ac_status" >&5
4530 (exit $ac_status); } &&
4531 { ac_try='test -s conftest.$ac_objext'
4532 { (eval echo "$as_me:4532: \"$ac_try\"") >&5
4535 echo "$as_me:4535: \$? = $ac_status" >&5
4536 (exit $ac_status); }; }; then
4538 cf_save_CFLAGS="$cf_save_CFLAGS -we147 -no-gcc"
4541 echo "$as_me: failed program was:" >&5
4542 cat conftest.$ac_ext >&5
4544 rm -f conftest.$ac_objext conftest.$ac_ext
4545 CFLAGS="$cf_save_CFLAGS"
4546 echo "$as_me:4546: result: $INTEL_COMPILER" >&5
4547 echo "${ECHO_T}$INTEL_COMPILER" >&6
4552 cat > conftest.$ac_ext <<EOF
4553 #line 4553 "${as_me:-configure}"
4554 int main(int argc, char *argv[]) { return (argv[argc-1] == 0) ; }
4557 if test "$INTEL_COMPILER" = yes
4559 # The "-wdXXX" options suppress warnings:
4560 # remark #1419: external declaration in primary source file
4561 # remark #1683: explicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem)
4562 # remark #1684: conversion from pointer to same-sized integral type (potential portability problem)
4563 # remark #193: zero used for undefined preprocessing identifier
4564 # remark #593: variable "curs_sb_left_arrow" was set but never used
4565 # remark #810: conversion from "int" to "Dimension={unsigned short}" may lose significant bits
4566 # remark #869: parameter "tw" was never referenced
4567 # remark #981: operands are evaluated in unspecified order
4568 # warning #279: controlling expression is constant
4570 { echo "$as_me:4570: checking for $CC warning options..." >&5
4571 echo "$as_me: checking for $CC warning options..." >&6;}
4572 cf_save_CFLAGS="$CFLAGS"
4573 EXTRA_CFLAGS="-Wall"
4585 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
4586 if { (eval echo "$as_me:4586: \"$ac_compile\"") >&5
4587 (eval $ac_compile) 2>&5
4589 echo "$as_me:4589: \$? = $ac_status" >&5
4590 (exit $ac_status); }; then
4591 test -n "$verbose" && echo "$as_me:4591: result: ... -$cf_opt" >&5
4592 echo "${ECHO_T}... -$cf_opt" >&6
4593 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
4596 CFLAGS="$cf_save_CFLAGS"
4598 elif test "$GCC" = yes
4600 { echo "$as_me:4600: checking for $CC warning options..." >&5
4601 echo "$as_me: checking for $CC warning options..." >&6;}
4602 cf_save_CFLAGS="$CFLAGS"
4605 test "$with_ext_const" = yes && cf_warn_CONST="Wwrite-strings"
4606 for cf_opt in W Wall \
4607 Wbad-function-cast \
4611 Wmissing-declarations \
4612 Wmissing-prototypes \
4616 Wstrict-prototypes \
4617 Wundef $cf_warn_CONST
4619 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
4620 if { (eval echo "$as_me:4620: \"$ac_compile\"") >&5
4621 (eval $ac_compile) 2>&5
4623 echo "$as_me:4623: \$? = $ac_status" >&5
4624 (exit $ac_status); }; then
4625 test -n "$verbose" && echo "$as_me:4625: result: ... -$cf_opt" >&5
4626 echo "${ECHO_T}... -$cf_opt" >&6
4627 case $cf_opt in #(vi
4629 CPPFLAGS="$CPPFLAGS -DXTSTRINGDEFINES"
4632 case $GCC_VERSION in
4634 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
4636 echo "${as_me:-configure}:4636: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
4642 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
4645 CFLAGS="$cf_save_CFLAGS"
4652 echo "$as_me:4652: checking if you want to use dmalloc for testing" >&5
4653 echo $ECHO_N "checking if you want to use dmalloc for testing... $ECHO_C" >&6
4655 # Check whether --with-dmalloc or --without-dmalloc was given.
4656 if test "${with_dmalloc+set}" = set; then
4657 withval="$with_dmalloc"
4658 cat >>confdefs.h <<\EOF
4659 #define USE_DMALLOC 1
4662 : ${with_cflags:=-g}
4663 : ${with_no_leaks:=yes}
4668 echo "$as_me:4668: result: ${with_dmalloc:-no}" >&5
4669 echo "${ECHO_T}${with_dmalloc:-no}" >&6
4671 case .$with_cflags in #(vi
4673 case .$CFLAGS in #(vi
4681 cf_new_extra_cppflags=
4683 for cf_add_cflags in -g
4685 case $cf_fix_cppflags in
4687 case $cf_add_cflags in #(vi
4688 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
4689 case $cf_add_cflags in
4691 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4693 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
4694 && test -z "${cf_tst_cflags}" \
4695 && cf_fix_cppflags=yes
4697 if test $cf_fix_cppflags = yes ; then
4698 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4700 elif test "${cf_tst_cflags}" = "\"'" ; then
4701 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4707 *$cf_add_cflags) #(vi
4710 case $cf_add_cflags in #(vi
4712 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4714 CPPFLAGS=`echo "$CPPFLAGS" | \
4715 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4716 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4720 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
4725 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
4730 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4732 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
4734 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
4735 && test -z "${cf_tst_cflags}" \
4736 && cf_fix_cppflags=no
4741 if test -n "$cf_new_cflags" ; then
4743 CFLAGS="$CFLAGS $cf_new_cflags"
4746 if test -n "$cf_new_cppflags" ; then
4748 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
4751 if test -n "$cf_new_extra_cppflags" ; then
4753 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
4761 if test "$with_dmalloc" = yes ; then
4762 echo "$as_me:4762: checking for dmalloc.h" >&5
4763 echo $ECHO_N "checking for dmalloc.h... $ECHO_C" >&6
4764 if test "${ac_cv_header_dmalloc_h+set}" = set; then
4765 echo $ECHO_N "(cached) $ECHO_C" >&6
4767 cat >conftest.$ac_ext <<_ACEOF
4768 #line 4768 "configure"
4769 #include "confdefs.h"
4770 #include <dmalloc.h>
4772 if { (eval echo "$as_me:4772: \"$ac_cpp conftest.$ac_ext\"") >&5
4773 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4775 egrep -v '^ *\+' conftest.er1 >conftest.err
4777 cat conftest.err >&5
4778 echo "$as_me:4778: \$? = $ac_status" >&5
4779 (exit $ac_status); } >/dev/null; then
4780 if test -s conftest.err; then
4781 ac_cpp_err=$ac_c_preproc_warn_flag
4788 if test -z "$ac_cpp_err"; then
4789 ac_cv_header_dmalloc_h=yes
4791 echo "$as_me: failed program was:" >&5
4792 cat conftest.$ac_ext >&5
4793 ac_cv_header_dmalloc_h=no
4795 rm -f conftest.err conftest.$ac_ext
4797 echo "$as_me:4797: result: $ac_cv_header_dmalloc_h" >&5
4798 echo "${ECHO_T}$ac_cv_header_dmalloc_h" >&6
4799 if test $ac_cv_header_dmalloc_h = yes; then
4801 echo "$as_me:4801: checking for dmalloc_debug in -ldmalloc" >&5
4802 echo $ECHO_N "checking for dmalloc_debug in -ldmalloc... $ECHO_C" >&6
4803 if test "${ac_cv_lib_dmalloc_dmalloc_debug+set}" = set; then
4804 echo $ECHO_N "(cached) $ECHO_C" >&6
4806 ac_check_lib_save_LIBS=$LIBS
4807 LIBS="-ldmalloc $LIBS"
4808 cat >conftest.$ac_ext <<_ACEOF
4809 #line 4809 "configure"
4810 #include "confdefs.h"
4812 /* Override any gcc2 internal prototype to avoid an error. */
4816 /* We use char because int might match the return type of a gcc2
4817 builtin and then its argument prototype would still apply. */
4818 char dmalloc_debug ();
4827 rm -f conftest.$ac_objext conftest$ac_exeext
4828 if { (eval echo "$as_me:4828: \"$ac_link\"") >&5
4829 (eval $ac_link) 2>&5
4831 echo "$as_me:4831: \$? = $ac_status" >&5
4832 (exit $ac_status); } &&
4833 { ac_try='test -s conftest$ac_exeext'
4834 { (eval echo "$as_me:4834: \"$ac_try\"") >&5
4837 echo "$as_me:4837: \$? = $ac_status" >&5
4838 (exit $ac_status); }; }; then
4839 ac_cv_lib_dmalloc_dmalloc_debug=yes
4841 echo "$as_me: failed program was:" >&5
4842 cat conftest.$ac_ext >&5
4843 ac_cv_lib_dmalloc_dmalloc_debug=no
4845 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4846 LIBS=$ac_check_lib_save_LIBS
4848 echo "$as_me:4848: result: $ac_cv_lib_dmalloc_dmalloc_debug" >&5
4849 echo "${ECHO_T}$ac_cv_lib_dmalloc_dmalloc_debug" >&6
4850 if test $ac_cv_lib_dmalloc_dmalloc_debug = yes; then
4851 cat >>confdefs.h <<EOF
4852 #define HAVE_LIBDMALLOC 1
4855 LIBS="-ldmalloc $LIBS"
4863 echo "$as_me:4863: checking if you want to use dbmalloc for testing" >&5
4864 echo $ECHO_N "checking if you want to use dbmalloc for testing... $ECHO_C" >&6
4866 # Check whether --with-dbmalloc or --without-dbmalloc was given.
4867 if test "${with_dbmalloc+set}" = set; then
4868 withval="$with_dbmalloc"
4869 cat >>confdefs.h <<\EOF
4870 #define USE_DBMALLOC 1
4873 : ${with_cflags:=-g}
4874 : ${with_no_leaks:=yes}
4879 echo "$as_me:4879: result: ${with_dbmalloc:-no}" >&5
4880 echo "${ECHO_T}${with_dbmalloc:-no}" >&6
4882 case .$with_cflags in #(vi
4884 case .$CFLAGS in #(vi
4892 cf_new_extra_cppflags=
4894 for cf_add_cflags in -g
4896 case $cf_fix_cppflags in
4898 case $cf_add_cflags in #(vi
4899 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
4900 case $cf_add_cflags in
4902 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4904 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
4905 && test -z "${cf_tst_cflags}" \
4906 && cf_fix_cppflags=yes
4908 if test $cf_fix_cppflags = yes ; then
4909 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4911 elif test "${cf_tst_cflags}" = "\"'" ; then
4912 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4918 *$cf_add_cflags) #(vi
4921 case $cf_add_cflags in #(vi
4923 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4925 CPPFLAGS=`echo "$CPPFLAGS" | \
4926 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4927 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4931 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
4936 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
4941 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4943 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
4945 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
4946 && test -z "${cf_tst_cflags}" \
4947 && cf_fix_cppflags=no
4952 if test -n "$cf_new_cflags" ; then
4954 CFLAGS="$CFLAGS $cf_new_cflags"
4957 if test -n "$cf_new_cppflags" ; then
4959 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
4962 if test -n "$cf_new_extra_cppflags" ; then
4964 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
4972 if test "$with_dbmalloc" = yes ; then
4973 echo "$as_me:4973: checking for dbmalloc.h" >&5
4974 echo $ECHO_N "checking for dbmalloc.h... $ECHO_C" >&6
4975 if test "${ac_cv_header_dbmalloc_h+set}" = set; then
4976 echo $ECHO_N "(cached) $ECHO_C" >&6
4978 cat >conftest.$ac_ext <<_ACEOF
4979 #line 4979 "configure"
4980 #include "confdefs.h"
4981 #include <dbmalloc.h>
4983 if { (eval echo "$as_me:4983: \"$ac_cpp conftest.$ac_ext\"") >&5
4984 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4986 egrep -v '^ *\+' conftest.er1 >conftest.err
4988 cat conftest.err >&5
4989 echo "$as_me:4989: \$? = $ac_status" >&5
4990 (exit $ac_status); } >/dev/null; then
4991 if test -s conftest.err; then
4992 ac_cpp_err=$ac_c_preproc_warn_flag
4999 if test -z "$ac_cpp_err"; then
5000 ac_cv_header_dbmalloc_h=yes
5002 echo "$as_me: failed program was:" >&5
5003 cat conftest.$ac_ext >&5
5004 ac_cv_header_dbmalloc_h=no
5006 rm -f conftest.err conftest.$ac_ext
5008 echo "$as_me:5008: result: $ac_cv_header_dbmalloc_h" >&5
5009 echo "${ECHO_T}$ac_cv_header_dbmalloc_h" >&6
5010 if test $ac_cv_header_dbmalloc_h = yes; then
5012 echo "$as_me:5012: checking for debug_malloc in -ldbmalloc" >&5
5013 echo $ECHO_N "checking for debug_malloc in -ldbmalloc... $ECHO_C" >&6
5014 if test "${ac_cv_lib_dbmalloc_debug_malloc+set}" = set; then
5015 echo $ECHO_N "(cached) $ECHO_C" >&6
5017 ac_check_lib_save_LIBS=$LIBS
5018 LIBS="-ldbmalloc $LIBS"
5019 cat >conftest.$ac_ext <<_ACEOF
5020 #line 5020 "configure"
5021 #include "confdefs.h"
5023 /* Override any gcc2 internal prototype to avoid an error. */
5027 /* We use char because int might match the return type of a gcc2
5028 builtin and then its argument prototype would still apply. */
5029 char debug_malloc ();
5038 rm -f conftest.$ac_objext conftest$ac_exeext
5039 if { (eval echo "$as_me:5039: \"$ac_link\"") >&5
5040 (eval $ac_link) 2>&5
5042 echo "$as_me:5042: \$? = $ac_status" >&5
5043 (exit $ac_status); } &&
5044 { ac_try='test -s conftest$ac_exeext'
5045 { (eval echo "$as_me:5045: \"$ac_try\"") >&5
5048 echo "$as_me:5048: \$? = $ac_status" >&5
5049 (exit $ac_status); }; }; then
5050 ac_cv_lib_dbmalloc_debug_malloc=yes
5052 echo "$as_me: failed program was:" >&5
5053 cat conftest.$ac_ext >&5
5054 ac_cv_lib_dbmalloc_debug_malloc=no
5056 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5057 LIBS=$ac_check_lib_save_LIBS
5059 echo "$as_me:5059: result: $ac_cv_lib_dbmalloc_debug_malloc" >&5
5060 echo "${ECHO_T}$ac_cv_lib_dbmalloc_debug_malloc" >&6
5061 if test $ac_cv_lib_dbmalloc_debug_malloc = yes; then
5062 cat >>confdefs.h <<EOF
5063 #define HAVE_LIBDBMALLOC 1
5066 LIBS="-ldbmalloc $LIBS"
5074 echo "$as_me:5074: checking if you want to use valgrind for testing" >&5
5075 echo $ECHO_N "checking if you want to use valgrind for testing... $ECHO_C" >&6
5077 # Check whether --with-valgrind or --without-valgrind was given.
5078 if test "${with_valgrind+set}" = set; then
5079 withval="$with_valgrind"
5080 cat >>confdefs.h <<\EOF
5081 #define USE_VALGRIND 1
5084 : ${with_cflags:=-g}
5085 : ${with_no_leaks:=yes}
5090 echo "$as_me:5090: result: ${with_valgrind:-no}" >&5
5091 echo "${ECHO_T}${with_valgrind:-no}" >&6
5093 case .$with_cflags in #(vi
5095 case .$CFLAGS in #(vi
5103 cf_new_extra_cppflags=
5105 for cf_add_cflags in -g
5107 case $cf_fix_cppflags in
5109 case $cf_add_cflags in #(vi
5110 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
5111 case $cf_add_cflags in
5113 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
5115 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
5116 && test -z "${cf_tst_cflags}" \
5117 && cf_fix_cppflags=yes
5119 if test $cf_fix_cppflags = yes ; then
5120 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
5122 elif test "${cf_tst_cflags}" = "\"'" ; then
5123 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
5129 *$cf_add_cflags) #(vi
5132 case $cf_add_cflags in #(vi
5134 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
5136 CPPFLAGS=`echo "$CPPFLAGS" | \
5137 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
5138 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
5142 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
5147 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
5152 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
5154 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
5156 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
5157 && test -z "${cf_tst_cflags}" \
5158 && cf_fix_cppflags=no
5163 if test -n "$cf_new_cflags" ; then
5165 CFLAGS="$CFLAGS $cf_new_cflags"
5168 if test -n "$cf_new_cppflags" ; then
5170 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
5173 if test -n "$cf_new_extra_cppflags" ; then
5175 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
5183 echo "$as_me:5183: checking if you want to perform memory-leak testing" >&5
5184 echo $ECHO_N "checking if you want to perform memory-leak testing... $ECHO_C" >&6
5186 # Check whether --enable-leaks or --disable-leaks was given.
5187 if test "${enable_leaks+set}" = set; then
5188 enableval="$enable_leaks"
5189 if test "x$enableval" = xno; then with_no_leaks=yes; else with_no_leaks=no; fi
5191 : ${with_no_leaks:=no}
5193 echo "$as_me:5193: result: $with_no_leaks" >&5
5194 echo "${ECHO_T}$with_no_leaks" >&6
5196 if test "$with_no_leaks" = yes ; then
5197 cat >>confdefs.h <<\EOF
5201 cat >>confdefs.h <<\EOF
5202 #define YY_NO_LEAKS 1
5207 echo "$as_me:5207: checking if you want to check for wide-character functions" >&5
5208 echo $ECHO_N "checking if you want to check for wide-character functions... $ECHO_C" >&6
5210 # Check whether --enable-widec or --disable-widec was given.
5211 if test "${enable_widec+set}" = set; then
5212 enableval="$enable_widec"
5213 test "$enableval" != no && enableval=yes
5214 if test "$enableval" != "yes" ; then
5224 echo "$as_me:5224: result: $cf_enable_widec" >&5
5225 echo "${ECHO_T}$cf_enable_widec" >&6
5227 echo "$as_me:5227: checking for specific curses-directory" >&5
5228 echo $ECHO_N "checking for specific curses-directory... $ECHO_C" >&6
5230 # Check whether --with-curses-dir or --without-curses-dir was given.
5231 if test "${with_curses_dir+set}" = set; then
5232 withval="$with_curses_dir"
5233 cf_cv_curses_dir=$withval
5237 echo "$as_me:5237: result: $cf_cv_curses_dir" >&5
5238 echo "${ECHO_T}$cf_cv_curses_dir" >&6
5240 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
5243 if test "x$prefix" != xNONE; then
5244 cf_path_syntax="$prefix"
5246 cf_path_syntax="$ac_default_prefix"
5249 case ".$withval" in #(vi
5250 .\$\(*\)*|.\'*\'*) #(vi
5254 .[a-zA-Z]:[\\/]*) #(vi OS/2 EMX
5257 eval withval="$withval"
5258 case ".$withval" in #(vi
5260 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
5265 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
5268 { { echo "$as_me:5268: error: expected a pathname, not \"$withval\"" >&5
5269 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
5270 { (exit 1); exit 1; }; }
5274 if test -d "$cf_cv_curses_dir"
5277 if test -n "$cf_cv_curses_dir/include" ; then
5278 for cf_add_incdir in $cf_cv_curses_dir/include
5280 while test $cf_add_incdir != /usr/include
5282 if test -d $cf_add_incdir
5285 if test -n "$CFLAGS$CPPFLAGS" ; then
5286 # a loop is needed to ensure we can add subdirs of existing dirs
5287 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
5288 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
5289 cf_have_incdir=yes; break
5294 if test "$cf_have_incdir" = no ; then
5295 if test "$cf_add_incdir" = /usr/local/include ; then
5296 if test "$GCC" = yes
5298 cf_save_CPPFLAGS=$CPPFLAGS
5299 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
5300 cat >conftest.$ac_ext <<_ACEOF
5301 #line 5301 "configure"
5302 #include "confdefs.h"
5312 rm -f conftest.$ac_objext
5313 if { (eval echo "$as_me:5313: \"$ac_compile\"") >&5
5314 (eval $ac_compile) 2>&5
5316 echo "$as_me:5316: \$? = $ac_status" >&5
5317 (exit $ac_status); } &&
5318 { ac_try='test -s conftest.$ac_objext'
5319 { (eval echo "$as_me:5319: \"$ac_try\"") >&5
5322 echo "$as_me:5322: \$? = $ac_status" >&5
5323 (exit $ac_status); }; }; then
5326 echo "$as_me: failed program was:" >&5
5327 cat conftest.$ac_ext >&5
5330 rm -f conftest.$ac_objext conftest.$ac_ext
5331 CPPFLAGS=$cf_save_CPPFLAGS
5336 if test "$cf_have_incdir" = no ; then
5337 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
5339 echo "${as_me:-configure}:5339: testing adding $cf_add_incdir to include-path ..." 1>&5
5341 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
5343 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
5344 test "$cf_top_incdir" = "$cf_add_incdir" && break
5345 cf_add_incdir="$cf_top_incdir"
5354 if test -n "$cf_cv_curses_dir/lib" ; then
5355 for cf_add_libdir in $cf_cv_curses_dir/lib
5357 if test $cf_add_libdir = /usr/lib ; then
5359 elif test -d $cf_add_libdir
5362 if test -n "$LDFLAGS$LIBS" ; then
5363 # a loop is needed to ensure we can add subdirs of existing dirs
5364 for cf_test_libdir in $LDFLAGS $LIBS ; do
5365 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
5366 cf_have_libdir=yes; break
5370 if test "$cf_have_libdir" = no ; then
5371 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
5373 echo "${as_me:-configure}:5373: testing adding $cf_add_libdir to library-path ..." 1>&5
5375 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
5386 echo "$as_me:5386: checking for specified curses library type" >&5
5387 echo $ECHO_N "checking for specified curses library type... $ECHO_C" >&6
5389 # Check whether --with-ncursesw or --without-ncursesw was given.
5390 if test "${with_ncursesw+set}" = set; then
5391 withval="$with_ncursesw"
5392 cf_cv_screen=ncursesw
5395 # Check whether --with-ncurses or --without-ncurses was given.
5396 if test "${with_ncurses+set}" = set; then
5397 withval="$with_ncurses"
5398 cf_cv_screen=ncurses
5401 # Check whether --with-pdcurses or --without-pdcurses was given.
5402 if test "${with_pdcurses+set}" = set; then
5403 withval="$with_pdcurses"
5404 cf_cv_screen=pdcurses
5407 # Check whether --with-curses-colr or --without-curses-colr was given.
5408 if test "${with_curses_colr+set}" = set; then
5409 withval="$with_curses_colr"
5410 cf_cv_screen=curses_colr
5413 # Check whether --with-curses-5lib or --without-curses-5lib was given.
5414 if test "${with_curses_5lib+set}" = set; then
5415 withval="$with_curses_5lib"
5416 cf_cv_screen=curses_5lib
5423 echo "$as_me:5423: result: $cf_cv_screen" >&5
5424 echo "${ECHO_T}$cf_cv_screen" >&6
5426 case $cf_cv_screen in #(vi
5427 curses|curses_*) #(vi
5429 echo "$as_me:5429: checking for extra include directories" >&5
5430 echo $ECHO_N "checking for extra include directories... $ECHO_C" >&6
5431 if test "${cf_cv_curses_incdir+set}" = set; then
5432 echo $ECHO_N "(cached) $ECHO_C" >&6
5435 cf_cv_curses_incdir=no
5436 case $host_os in #(vi
5438 if test "x$cf_cv_screen" = "xcurses_colr"
5440 test -d /usr/include/curses_colr && \
5441 cf_cv_curses_incdir="-I/usr/include/curses_colr"
5445 if test "x$cf_cv_screen" = "xcurses_5lib"
5447 test -d /usr/5lib && \
5448 test -d /usr/5include && \
5449 cf_cv_curses_incdir="-I/usr/5include"
5455 echo "$as_me:5455: result: $cf_cv_curses_incdir" >&5
5456 echo "${ECHO_T}$cf_cv_curses_incdir" >&6
5457 test "$cf_cv_curses_incdir" != no && CPPFLAGS="$CPPFLAGS $cf_cv_curses_incdir"
5459 echo "$as_me:5459: checking if we have identified curses headers" >&5
5460 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
5461 if test "${cf_cv_ncurses_header+set}" = set; then
5462 echo $ECHO_N "(cached) $ECHO_C" >&6
5465 cf_cv_ncurses_header=none
5468 curses.h ncurses/ncurses.h ncurses/curses.h
5470 cat >conftest.$ac_ext <<_ACEOF
5471 #line 5471 "configure"
5472 #include "confdefs.h"
5473 #include <${cf_header}>
5477 initscr(); tgoto("?", 0,0)
5482 rm -f conftest.$ac_objext
5483 if { (eval echo "$as_me:5483: \"$ac_compile\"") >&5
5484 (eval $ac_compile) 2>&5
5486 echo "$as_me:5486: \$? = $ac_status" >&5
5487 (exit $ac_status); } &&
5488 { ac_try='test -s conftest.$ac_objext'
5489 { (eval echo "$as_me:5489: \"$ac_try\"") >&5
5492 echo "$as_me:5492: \$? = $ac_status" >&5
5493 (exit $ac_status); }; }; then
5494 cf_cv_ncurses_header=$cf_header; break
5496 echo "$as_me: failed program was:" >&5
5497 cat conftest.$ac_ext >&5
5499 rm -f conftest.$ac_objext conftest.$ac_ext
5503 echo "$as_me:5503: result: $cf_cv_ncurses_header" >&5
5504 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
5506 if test "$cf_cv_ncurses_header" = none ; then
5507 { { echo "$as_me:5507: error: No curses header-files found" >&5
5508 echo "$as_me: error: No curses header-files found" >&2;}
5509 { (exit 1); exit 1; }; }
5512 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
5514 for ac_header in $cf_cv_ncurses_header
5516 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
5517 echo "$as_me:5517: checking for $ac_header" >&5
5518 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5519 if eval "test \"\${$as_ac_Header+set}\" = set"; then
5520 echo $ECHO_N "(cached) $ECHO_C" >&6
5522 cat >conftest.$ac_ext <<_ACEOF
5523 #line 5523 "configure"
5524 #include "confdefs.h"
5525 #include <$ac_header>
5527 if { (eval echo "$as_me:5527: \"$ac_cpp conftest.$ac_ext\"") >&5
5528 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
5530 egrep -v '^ *\+' conftest.er1 >conftest.err
5532 cat conftest.err >&5
5533 echo "$as_me:5533: \$? = $ac_status" >&5
5534 (exit $ac_status); } >/dev/null; then
5535 if test -s conftest.err; then
5536 ac_cpp_err=$ac_c_preproc_warn_flag
5543 if test -z "$ac_cpp_err"; then
5544 eval "$as_ac_Header=yes"
5546 echo "$as_me: failed program was:" >&5
5547 cat conftest.$ac_ext >&5
5548 eval "$as_ac_Header=no"
5550 rm -f conftest.err conftest.$ac_ext
5552 echo "$as_me:5552: result: `eval echo '${'$as_ac_Header'}'`" >&5
5553 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
5554 if test `eval echo '${'$as_ac_Header'}'` = yes; then
5555 cat >>confdefs.h <<EOF
5556 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
5562 echo "$as_me:5562: checking for terminfo header" >&5
5563 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
5564 if test "${cf_cv_term_header+set}" = set; then
5565 echo $ECHO_N "(cached) $ECHO_C" >&6
5568 case ${cf_cv_ncurses_header} in #(vi
5569 */ncurses.h|*/ncursesw.h) #(vi
5570 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
5573 cf_term_header=term.h
5577 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
5579 cat >conftest.$ac_ext <<_ACEOF
5580 #line 5580 "configure"
5581 #include "confdefs.h"
5583 #include <${cf_cv_ncurses_header:-curses.h}>
5589 int x = auto_left_margin
5594 rm -f conftest.$ac_objext
5595 if { (eval echo "$as_me:5595: \"$ac_compile\"") >&5
5596 (eval $ac_compile) 2>&5
5598 echo "$as_me:5598: \$? = $ac_status" >&5
5599 (exit $ac_status); } &&
5600 { ac_try='test -s conftest.$ac_objext'
5601 { (eval echo "$as_me:5601: \"$ac_try\"") >&5
5604 echo "$as_me:5604: \$? = $ac_status" >&5
5605 (exit $ac_status); }; }; then
5607 cf_cv_term_header="$cf_test"
5609 echo "$as_me: failed program was:" >&5
5610 cat conftest.$ac_ext >&5
5612 cf_cv_term_header=unknown
5615 rm -f conftest.$ac_objext conftest.$ac_ext
5616 test "$cf_cv_term_header" != unknown && break
5620 echo "$as_me:5620: result: $cf_cv_term_header" >&5
5621 echo "${ECHO_T}$cf_cv_term_header" >&6
5623 # Set definitions to allow ifdef'ing to accommodate subdirectories
5625 case $cf_cv_term_header in # (vi
5627 cat >>confdefs.h <<\EOF
5628 #define HAVE_TERM_H 1
5634 case $cf_cv_term_header in # (vi
5635 ncurses/term.h) #(vi
5636 cat >>confdefs.h <<\EOF
5637 #define HAVE_NCURSES_TERM_H 1
5642 cat >>confdefs.h <<\EOF
5643 #define HAVE_NCURSESW_TERM_H 1
5649 echo "$as_me:5649: checking for ncurses version" >&5
5650 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
5651 if test "${cf_cv_ncurses_version+set}" = set; then
5652 echo $ECHO_N "(cached) $ECHO_C" >&6
5655 cf_cv_ncurses_version=no
5658 if test "$cross_compiling" = yes; then
5660 # This will not work if the preprocessor splits the line after the
5661 # Autoconf token. The 'unproto' program does that.
5662 cat > conftest.$ac_ext <<EOF
5663 #include <${cf_cv_ncurses_header:-curses.h}>
5665 #ifdef NCURSES_VERSION
5666 Autoconf NCURSES_VERSION
5674 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
5675 { (eval echo "$as_me:5675: \"$cf_try\"") >&5
5678 echo "$as_me:5678: \$? = $ac_status" >&5
5679 (exit $ac_status); }
5680 if test -f conftest.out ; then
5681 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
5682 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
5687 cat >conftest.$ac_ext <<_ACEOF
5688 #line 5688 "configure"
5689 #include "confdefs.h"
5691 #include <${cf_cv_ncurses_header:-curses.h}>
5695 FILE *fp = fopen("$cf_tempfile", "w");
5696 #ifdef NCURSES_VERSION
5697 # ifdef NCURSES_VERSION_PATCH
5698 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
5700 fprintf(fp, "%s\n", NCURSES_VERSION);
5704 fprintf(fp, "old\n");
5709 ${cf_cv_main_return:-return}(0);
5712 rm -f conftest$ac_exeext
5713 if { (eval echo "$as_me:5713: \"$ac_link\"") >&5
5714 (eval $ac_link) 2>&5
5716 echo "$as_me:5716: \$? = $ac_status" >&5
5717 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5718 { (eval echo "$as_me:5718: \"$ac_try\"") >&5
5721 echo "$as_me:5721: \$? = $ac_status" >&5
5722 (exit $ac_status); }; }; then
5724 cf_cv_ncurses_version=`cat $cf_tempfile`
5726 echo "$as_me: program exited with status $ac_status" >&5
5727 echo "$as_me: failed program was:" >&5
5728 cat conftest.$ac_ext >&5
5730 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
5735 echo "$as_me:5735: result: $cf_cv_ncurses_version" >&5
5736 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
5737 test "$cf_cv_ncurses_version" = no || cat >>confdefs.h <<\EOF
5741 echo "$as_me:5741: checking if we have identified curses libraries" >&5
5742 echo $ECHO_N "checking if we have identified curses libraries... $ECHO_C" >&6
5743 cat >conftest.$ac_ext <<_ACEOF
5744 #line 5744 "configure"
5745 #include "confdefs.h"
5746 #include <${cf_cv_ncurses_header:-curses.h}>
5750 initscr(); tgoto("?", 0,0)
5755 rm -f conftest.$ac_objext conftest$ac_exeext
5756 if { (eval echo "$as_me:5756: \"$ac_link\"") >&5
5757 (eval $ac_link) 2>&5
5759 echo "$as_me:5759: \$? = $ac_status" >&5
5760 (exit $ac_status); } &&
5761 { ac_try='test -s conftest$ac_exeext'
5762 { (eval echo "$as_me:5762: \"$ac_try\"") >&5
5765 echo "$as_me:5765: \$? = $ac_status" >&5
5766 (exit $ac_status); }; }; then
5769 echo "$as_me: failed program was:" >&5
5770 cat conftest.$ac_ext >&5
5773 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5774 echo "$as_me:5774: result: $cf_result" >&5
5775 echo "${ECHO_T}$cf_result" >&6
5777 if test "$cf_result" = no ; then
5778 case $host_os in #(vi
5780 echo "$as_me:5780: checking for tgoto in -lmytinfo" >&5
5781 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
5782 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
5783 echo $ECHO_N "(cached) $ECHO_C" >&6
5785 ac_check_lib_save_LIBS=$LIBS
5786 LIBS="-lmytinfo $LIBS"
5787 cat >conftest.$ac_ext <<_ACEOF
5788 #line 5788 "configure"
5789 #include "confdefs.h"
5791 /* Override any gcc2 internal prototype to avoid an error. */
5795 /* We use char because int might match the return type of a gcc2
5796 builtin and then its argument prototype would still apply. */
5806 rm -f conftest.$ac_objext conftest$ac_exeext
5807 if { (eval echo "$as_me:5807: \"$ac_link\"") >&5
5808 (eval $ac_link) 2>&5
5810 echo "$as_me:5810: \$? = $ac_status" >&5
5811 (exit $ac_status); } &&
5812 { ac_try='test -s conftest$ac_exeext'
5813 { (eval echo "$as_me:5813: \"$ac_try\"") >&5
5816 echo "$as_me:5816: \$? = $ac_status" >&5
5817 (exit $ac_status); }; }; then
5818 ac_cv_lib_mytinfo_tgoto=yes
5820 echo "$as_me: failed program was:" >&5
5821 cat conftest.$ac_ext >&5
5822 ac_cv_lib_mytinfo_tgoto=no
5824 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5825 LIBS=$ac_check_lib_save_LIBS
5827 echo "$as_me:5827: result: $ac_cv_lib_mytinfo_tgoto" >&5
5828 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
5829 if test $ac_cv_lib_mytinfo_tgoto = yes; then
5830 LIBS="-lmytinfo $LIBS"
5835 # Looking at HPUX 10.20, the Hcurses library is the oldest (1997), cur_colr
5836 # next (1998), and xcurses "newer" (2000). There is no header file for
5837 # Hcurses; the subdirectory curses_colr has the headers (curses.h and
5838 # term.h) for cur_colr
5839 if test "x$cf_cv_screen" = "xcurses_colr"
5841 echo "$as_me:5841: checking for initscr in -lcur_colr" >&5
5842 echo $ECHO_N "checking for initscr in -lcur_colr... $ECHO_C" >&6
5843 if test "${ac_cv_lib_cur_colr_initscr+set}" = set; then
5844 echo $ECHO_N "(cached) $ECHO_C" >&6
5846 ac_check_lib_save_LIBS=$LIBS
5847 LIBS="-lcur_colr $LIBS"
5848 cat >conftest.$ac_ext <<_ACEOF
5849 #line 5849 "configure"
5850 #include "confdefs.h"
5852 /* Override any gcc2 internal prototype to avoid an error. */
5856 /* We use char because int might match the return type of a gcc2
5857 builtin and then its argument prototype would still apply. */
5867 rm -f conftest.$ac_objext conftest$ac_exeext
5868 if { (eval echo "$as_me:5868: \"$ac_link\"") >&5
5869 (eval $ac_link) 2>&5
5871 echo "$as_me:5871: \$? = $ac_status" >&5
5872 (exit $ac_status); } &&
5873 { ac_try='test -s conftest$ac_exeext'
5874 { (eval echo "$as_me:5874: \"$ac_try\"") >&5
5877 echo "$as_me:5877: \$? = $ac_status" >&5
5878 (exit $ac_status); }; }; then
5879 ac_cv_lib_cur_colr_initscr=yes
5881 echo "$as_me: failed program was:" >&5
5882 cat conftest.$ac_ext >&5
5883 ac_cv_lib_cur_colr_initscr=no
5885 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5886 LIBS=$ac_check_lib_save_LIBS
5888 echo "$as_me:5888: result: $ac_cv_lib_cur_colr_initscr" >&5
5889 echo "${ECHO_T}$ac_cv_lib_cur_colr_initscr" >&6
5890 if test $ac_cv_lib_cur_colr_initscr = yes; then
5892 LIBS="-lcur_colr $LIBS"
5893 ac_cv_func_initscr=yes
5897 echo "$as_me:5897: checking for initscr in -lHcurses" >&5
5898 echo $ECHO_N "checking for initscr in -lHcurses... $ECHO_C" >&6
5899 if test "${ac_cv_lib_Hcurses_initscr+set}" = set; then
5900 echo $ECHO_N "(cached) $ECHO_C" >&6
5902 ac_check_lib_save_LIBS=$LIBS
5903 LIBS="-lHcurses $LIBS"
5904 cat >conftest.$ac_ext <<_ACEOF
5905 #line 5905 "configure"
5906 #include "confdefs.h"
5908 /* Override any gcc2 internal prototype to avoid an error. */
5912 /* We use char because int might match the return type of a gcc2
5913 builtin and then its argument prototype would still apply. */
5923 rm -f conftest.$ac_objext conftest$ac_exeext
5924 if { (eval echo "$as_me:5924: \"$ac_link\"") >&5
5925 (eval $ac_link) 2>&5
5927 echo "$as_me:5927: \$? = $ac_status" >&5
5928 (exit $ac_status); } &&
5929 { ac_try='test -s conftest$ac_exeext'
5930 { (eval echo "$as_me:5930: \"$ac_try\"") >&5
5933 echo "$as_me:5933: \$? = $ac_status" >&5
5934 (exit $ac_status); }; }; then
5935 ac_cv_lib_Hcurses_initscr=yes
5937 echo "$as_me: failed program was:" >&5
5938 cat conftest.$ac_ext >&5
5939 ac_cv_lib_Hcurses_initscr=no
5941 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5942 LIBS=$ac_check_lib_save_LIBS
5944 echo "$as_me:5944: result: $ac_cv_lib_Hcurses_initscr" >&5
5945 echo "${ECHO_T}$ac_cv_lib_Hcurses_initscr" >&6
5946 if test $ac_cv_lib_Hcurses_initscr = yes; then
5948 # HP's header uses __HP_CURSES, but user claims _HP_CURSES.
5949 LIBS="-lHcurses $LIBS"
5950 CPPFLAGS="$CPPFLAGS -D__HP_CURSES -D_HP_CURSES"
5951 ac_cv_func_initscr=yes
5960 case `arch 2>/dev/null` in
5965 if test -n "/lib64" ; then
5966 for cf_add_libdir in /lib64
5968 if test $cf_add_libdir = /usr/lib ; then
5970 elif test -d $cf_add_libdir
5973 if test -n "$LDFLAGS$LIBS" ; then
5974 # a loop is needed to ensure we can add subdirs of existing dirs
5975 for cf_test_libdir in $LDFLAGS $LIBS ; do
5976 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
5977 cf_have_libdir=yes; break
5981 if test "$cf_have_libdir" = no ; then
5982 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
5984 echo "${as_me:-configure}:5984: testing adding $cf_add_libdir to library-path ..." 1>&5
5986 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
5994 if test -n "/lib" ; then
5995 for cf_add_libdir in /lib
5997 if test $cf_add_libdir = /usr/lib ; then
5999 elif test -d $cf_add_libdir
6002 if test -n "$LDFLAGS$LIBS" ; then
6003 # a loop is needed to ensure we can add subdirs of existing dirs
6004 for cf_test_libdir in $LDFLAGS $LIBS ; do
6005 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
6006 cf_have_libdir=yes; break
6010 if test "$cf_have_libdir" = no ; then
6011 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
6013 echo "${as_me:-configure}:6013: testing adding $cf_add_libdir to library-path ..." 1>&5
6015 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
6025 if test -n "/lib" ; then
6026 for cf_add_libdir in /lib
6028 if test $cf_add_libdir = /usr/lib ; then
6030 elif test -d $cf_add_libdir
6033 if test -n "$LDFLAGS$LIBS" ; then
6034 # a loop is needed to ensure we can add subdirs of existing dirs
6035 for cf_test_libdir in $LDFLAGS $LIBS ; do
6036 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
6037 cf_have_libdir=yes; break
6041 if test "$cf_have_libdir" = no ; then
6042 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
6044 echo "${as_me:-configure}:6044: testing adding $cf_add_libdir to library-path ..." 1>&5
6046 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
6056 if test "x$cf_cv_screen" = "xcurses_5lib"
6058 if test -d /usr/5lib ; then
6060 if test -n "/usr/5lib" ; then
6061 for cf_add_libdir in /usr/5lib
6063 if test $cf_add_libdir = /usr/lib ; then
6065 elif test -d $cf_add_libdir
6068 if test -n "$LDFLAGS$LIBS" ; then
6069 # a loop is needed to ensure we can add subdirs of existing dirs
6070 for cf_test_libdir in $LDFLAGS $LIBS ; do
6071 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
6072 cf_have_libdir=yes; break
6076 if test "$cf_have_libdir" = no ; then
6077 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
6079 echo "${as_me:-configure}:6079: testing adding $cf_add_libdir to library-path ..." 1>&5
6081 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
6087 LIBS="-lcurses -ltermcap $LIBS"
6090 ac_cv_func_initscr=yes
6094 if test ".$ac_cv_func_initscr" != .yes ; then
6095 cf_save_LIBS="$LIBS"
6099 if test ".${cf_cv_ncurses_version:-no}" != .no
6101 cf_check_list="ncurses curses cursesX"
6103 cf_check_list="cursesX curses ncurses"
6106 # Check for library containing tgoto. Do this before curses library
6107 # because it may be needed to link the test-case for initscr.
6108 echo "$as_me:6108: checking for tgoto" >&5
6109 echo $ECHO_N "checking for tgoto... $ECHO_C" >&6
6110 if test "${ac_cv_func_tgoto+set}" = set; then
6111 echo $ECHO_N "(cached) $ECHO_C" >&6
6113 cat >conftest.$ac_ext <<_ACEOF
6114 #line 6114 "configure"
6115 #include "confdefs.h"
6116 /* System header to define __stub macros and hopefully few prototypes,
6117 which can conflict with char tgoto (); below. */
6119 /* Override any gcc2 internal prototype to avoid an error. */
6123 /* We use char because int might match the return type of a gcc2
6124 builtin and then its argument prototype would still apply. */
6131 /* The GNU C library defines this for functions which it implements
6132 to always fail with ENOSYS. Some functions are actually named
6133 something starting with __ and the normal name is an alias. */
6134 #if defined (__stub_tgoto) || defined (__stub___tgoto)
6144 rm -f conftest.$ac_objext conftest$ac_exeext
6145 if { (eval echo "$as_me:6145: \"$ac_link\"") >&5
6146 (eval $ac_link) 2>&5
6148 echo "$as_me:6148: \$? = $ac_status" >&5
6149 (exit $ac_status); } &&
6150 { ac_try='test -s conftest$ac_exeext'
6151 { (eval echo "$as_me:6151: \"$ac_try\"") >&5
6154 echo "$as_me:6154: \$? = $ac_status" >&5
6155 (exit $ac_status); }; }; then
6156 ac_cv_func_tgoto=yes
6158 echo "$as_me: failed program was:" >&5
6159 cat conftest.$ac_ext >&5
6162 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6164 echo "$as_me:6164: result: $ac_cv_func_tgoto" >&5
6165 echo "${ECHO_T}$ac_cv_func_tgoto" >&6
6166 if test $ac_cv_func_tgoto = yes; then
6167 cf_term_lib=predefined
6170 for cf_term_lib in $cf_check_list otermcap termcap termlib unknown
6172 as_ac_Lib=`echo "ac_cv_lib_$cf_term_lib''_tgoto" | $as_tr_sh`
6173 echo "$as_me:6173: checking for tgoto in -l$cf_term_lib" >&5
6174 echo $ECHO_N "checking for tgoto in -l$cf_term_lib... $ECHO_C" >&6
6175 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
6176 echo $ECHO_N "(cached) $ECHO_C" >&6
6178 ac_check_lib_save_LIBS=$LIBS
6179 LIBS="-l$cf_term_lib $LIBS"
6180 cat >conftest.$ac_ext <<_ACEOF
6181 #line 6181 "configure"
6182 #include "confdefs.h"
6184 /* Override any gcc2 internal prototype to avoid an error. */
6188 /* We use char because int might match the return type of a gcc2
6189 builtin and then its argument prototype would still apply. */
6199 rm -f conftest.$ac_objext conftest$ac_exeext
6200 if { (eval echo "$as_me:6200: \"$ac_link\"") >&5
6201 (eval $ac_link) 2>&5
6203 echo "$as_me:6203: \$? = $ac_status" >&5
6204 (exit $ac_status); } &&
6205 { ac_try='test -s conftest$ac_exeext'
6206 { (eval echo "$as_me:6206: \"$ac_try\"") >&5
6209 echo "$as_me:6209: \$? = $ac_status" >&5
6210 (exit $ac_status); }; }; then
6211 eval "$as_ac_Lib=yes"
6213 echo "$as_me: failed program was:" >&5
6214 cat conftest.$ac_ext >&5
6215 eval "$as_ac_Lib=no"
6217 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6218 LIBS=$ac_check_lib_save_LIBS
6220 echo "$as_me:6220: result: `eval echo '${'$as_ac_Lib'}'`" >&5
6221 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
6222 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
6230 # Check for library containing initscr
6231 test "$cf_term_lib" != predefined && test "$cf_term_lib" != unknown && LIBS="-l$cf_term_lib $cf_save_LIBS"
6232 for cf_curs_lib in $cf_check_list xcurses jcurses pdcurses unknown
6234 as_ac_Lib=`echo "ac_cv_lib_$cf_curs_lib''_initscr" | $as_tr_sh`
6235 echo "$as_me:6235: checking for initscr in -l$cf_curs_lib" >&5
6236 echo $ECHO_N "checking for initscr in -l$cf_curs_lib... $ECHO_C" >&6
6237 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
6238 echo $ECHO_N "(cached) $ECHO_C" >&6
6240 ac_check_lib_save_LIBS=$LIBS
6241 LIBS="-l$cf_curs_lib $LIBS"
6242 cat >conftest.$ac_ext <<_ACEOF
6243 #line 6243 "configure"
6244 #include "confdefs.h"
6246 /* Override any gcc2 internal prototype to avoid an error. */
6250 /* We use char because int might match the return type of a gcc2
6251 builtin and then its argument prototype would still apply. */
6261 rm -f conftest.$ac_objext conftest$ac_exeext
6262 if { (eval echo "$as_me:6262: \"$ac_link\"") >&5
6263 (eval $ac_link) 2>&5
6265 echo "$as_me:6265: \$? = $ac_status" >&5
6266 (exit $ac_status); } &&
6267 { ac_try='test -s conftest$ac_exeext'
6268 { (eval echo "$as_me:6268: \"$ac_try\"") >&5
6271 echo "$as_me:6271: \$? = $ac_status" >&5
6272 (exit $ac_status); }; }; then
6273 eval "$as_ac_Lib=yes"
6275 echo "$as_me: failed program was:" >&5
6276 cat conftest.$ac_ext >&5
6277 eval "$as_ac_Lib=no"
6279 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6280 LIBS=$ac_check_lib_save_LIBS
6282 echo "$as_me:6282: result: `eval echo '${'$as_ac_Lib'}'`" >&5
6283 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
6284 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
6289 test $cf_curs_lib = unknown && { { echo "$as_me:6289: error: no curses library found" >&5
6290 echo "$as_me: error: no curses library found" >&2;}
6291 { (exit 1); exit 1; }; }
6293 LIBS="-l$cf_curs_lib $cf_save_LIBS"
6294 if test "$cf_term_lib" = unknown ; then
6295 echo "$as_me:6295: checking if we can link with $cf_curs_lib library" >&5
6296 echo $ECHO_N "checking if we can link with $cf_curs_lib library... $ECHO_C" >&6
6297 cat >conftest.$ac_ext <<_ACEOF
6298 #line 6298 "configure"
6299 #include "confdefs.h"
6300 #include <${cf_cv_ncurses_header:-curses.h}>
6309 rm -f conftest.$ac_objext conftest$ac_exeext
6310 if { (eval echo "$as_me:6310: \"$ac_link\"") >&5
6311 (eval $ac_link) 2>&5
6313 echo "$as_me:6313: \$? = $ac_status" >&5
6314 (exit $ac_status); } &&
6315 { ac_try='test -s conftest$ac_exeext'
6316 { (eval echo "$as_me:6316: \"$ac_try\"") >&5
6319 echo "$as_me:6319: \$? = $ac_status" >&5
6320 (exit $ac_status); }; }; then
6323 echo "$as_me: failed program was:" >&5
6324 cat conftest.$ac_ext >&5
6327 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6328 echo "$as_me:6328: result: $cf_result" >&5
6329 echo "${ECHO_T}$cf_result" >&6
6330 test $cf_result = no && { { echo "$as_me:6330: error: Cannot link curses library" >&5
6331 echo "$as_me: error: Cannot link curses library" >&2;}
6332 { (exit 1); exit 1; }; }
6333 elif test "$cf_curs_lib" = "$cf_term_lib" ; then
6335 elif test "$cf_term_lib" != predefined ; then
6336 echo "$as_me:6336: checking if we need both $cf_curs_lib and $cf_term_lib libraries" >&5
6337 echo $ECHO_N "checking if we need both $cf_curs_lib and $cf_term_lib libraries... $ECHO_C" >&6
6338 cat >conftest.$ac_ext <<_ACEOF
6339 #line 6339 "configure"
6340 #include "confdefs.h"
6341 #include <${cf_cv_ncurses_header:-curses.h}>
6345 initscr(); tgoto((char *)0, 0, 0);
6350 rm -f conftest.$ac_objext conftest$ac_exeext
6351 if { (eval echo "$as_me:6351: \"$ac_link\"") >&5
6352 (eval $ac_link) 2>&5
6354 echo "$as_me:6354: \$? = $ac_status" >&5
6355 (exit $ac_status); } &&
6356 { ac_try='test -s conftest$ac_exeext'
6357 { (eval echo "$as_me:6357: \"$ac_try\"") >&5
6360 echo "$as_me:6360: \$? = $ac_status" >&5
6361 (exit $ac_status); }; }; then
6364 echo "$as_me: failed program was:" >&5
6365 cat conftest.$ac_ext >&5
6367 LIBS="-l$cf_curs_lib -l$cf_term_lib $cf_save_LIBS"
6368 cat >conftest.$ac_ext <<_ACEOF
6369 #line 6369 "configure"
6370 #include "confdefs.h"
6371 #include <${cf_cv_ncurses_header:-curses.h}>
6380 rm -f conftest.$ac_objext conftest$ac_exeext
6381 if { (eval echo "$as_me:6381: \"$ac_link\"") >&5
6382 (eval $ac_link) 2>&5
6384 echo "$as_me:6384: \$? = $ac_status" >&5
6385 (exit $ac_status); } &&
6386 { ac_try='test -s conftest$ac_exeext'
6387 { (eval echo "$as_me:6387: \"$ac_try\"") >&5
6390 echo "$as_me:6390: \$? = $ac_status" >&5
6391 (exit $ac_status); }; }; then
6394 echo "$as_me: failed program was:" >&5
6395 cat conftest.$ac_ext >&5
6398 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6401 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6402 echo "$as_me:6402: result: $cf_result" >&5
6403 echo "${ECHO_T}$cf_result" >&6
6411 cf_ncuconfig_root=ncurses
6413 echo "Looking for ${cf_ncuconfig_root}-config"
6415 if test -n "$ac_tool_prefix"; then
6416 for ac_prog in ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
6418 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
6419 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
6420 echo "$as_me:6420: checking for $ac_word" >&5
6421 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
6422 if test "${ac_cv_prog_NCURSES_CONFIG+set}" = set; then
6423 echo $ECHO_N "(cached) $ECHO_C" >&6
6425 if test -n "$NCURSES_CONFIG"; then
6426 ac_cv_prog_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test.
6428 ac_save_IFS=$IFS; IFS=$ac_path_separator
6430 for ac_dir in $ac_dummy; do
6432 test -z "$ac_dir" && ac_dir=.
6433 $as_executable_p "$ac_dir/$ac_word" || continue
6434 ac_cv_prog_NCURSES_CONFIG="$ac_tool_prefix$ac_prog"
6435 echo "$as_me:6435: found $ac_dir/$ac_word" >&5
6441 NCURSES_CONFIG=$ac_cv_prog_NCURSES_CONFIG
6442 if test -n "$NCURSES_CONFIG"; then
6443 echo "$as_me:6443: result: $NCURSES_CONFIG" >&5
6444 echo "${ECHO_T}$NCURSES_CONFIG" >&6
6446 echo "$as_me:6446: result: no" >&5
6447 echo "${ECHO_T}no" >&6
6450 test -n "$NCURSES_CONFIG" && break
6453 if test -z "$NCURSES_CONFIG"; then
6454 ac_ct_NCURSES_CONFIG=$NCURSES_CONFIG
6455 for ac_prog in ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
6457 # Extract the first word of "$ac_prog", so it can be a program name with args.
6458 set dummy $ac_prog; ac_word=$2
6459 echo "$as_me:6459: checking for $ac_word" >&5
6460 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
6461 if test "${ac_cv_prog_ac_ct_NCURSES_CONFIG+set}" = set; then
6462 echo $ECHO_N "(cached) $ECHO_C" >&6
6464 if test -n "$ac_ct_NCURSES_CONFIG"; then
6465 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_ct_NCURSES_CONFIG" # Let the user override the test.
6467 ac_save_IFS=$IFS; IFS=$ac_path_separator
6469 for ac_dir in $ac_dummy; do
6471 test -z "$ac_dir" && ac_dir=.
6472 $as_executable_p "$ac_dir/$ac_word" || continue
6473 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_prog"
6474 echo "$as_me:6474: found $ac_dir/$ac_word" >&5
6480 ac_ct_NCURSES_CONFIG=$ac_cv_prog_ac_ct_NCURSES_CONFIG
6481 if test -n "$ac_ct_NCURSES_CONFIG"; then
6482 echo "$as_me:6482: result: $ac_ct_NCURSES_CONFIG" >&5
6483 echo "${ECHO_T}$ac_ct_NCURSES_CONFIG" >&6
6485 echo "$as_me:6485: result: no" >&5
6486 echo "${ECHO_T}no" >&6
6489 test -n "$ac_ct_NCURSES_CONFIG" && break
6491 test -n "$ac_ct_NCURSES_CONFIG" || ac_ct_NCURSES_CONFIG="none"
6493 NCURSES_CONFIG=$ac_ct_NCURSES_CONFIG
6496 if test "$NCURSES_CONFIG" != none ; then
6498 CPPFLAGS="$CPPFLAGS `$NCURSES_CONFIG --cflags`"
6499 LIBS="`$NCURSES_CONFIG --libs` $LIBS"
6501 # even with config script, some packages use no-override for curses.h
6503 echo "$as_me:6503: checking if we have identified curses headers" >&5
6504 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
6505 if test "${cf_cv_ncurses_header+set}" = set; then
6506 echo $ECHO_N "(cached) $ECHO_C" >&6
6509 cf_cv_ncurses_header=none
6516 cat >conftest.$ac_ext <<_ACEOF
6517 #line 6517 "configure"
6518 #include "confdefs.h"
6519 #include <${cf_header}>
6523 initscr(); tgoto("?", 0,0)
6528 rm -f conftest.$ac_objext
6529 if { (eval echo "$as_me:6529: \"$ac_compile\"") >&5
6530 (eval $ac_compile) 2>&5
6532 echo "$as_me:6532: \$? = $ac_status" >&5
6533 (exit $ac_status); } &&
6534 { ac_try='test -s conftest.$ac_objext'
6535 { (eval echo "$as_me:6535: \"$ac_try\"") >&5
6538 echo "$as_me:6538: \$? = $ac_status" >&5
6539 (exit $ac_status); }; }; then
6540 cf_cv_ncurses_header=$cf_header; break
6542 echo "$as_me: failed program was:" >&5
6543 cat conftest.$ac_ext >&5
6545 rm -f conftest.$ac_objext conftest.$ac_ext
6549 echo "$as_me:6549: result: $cf_cv_ncurses_header" >&5
6550 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
6552 if test "$cf_cv_ncurses_header" = none ; then
6553 { { echo "$as_me:6553: error: No curses header-files found" >&5
6554 echo "$as_me: error: No curses header-files found" >&2;}
6555 { (exit 1); exit 1; }; }
6558 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
6560 for ac_header in $cf_cv_ncurses_header
6562 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6563 echo "$as_me:6563: checking for $ac_header" >&5
6564 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6565 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6566 echo $ECHO_N "(cached) $ECHO_C" >&6
6568 cat >conftest.$ac_ext <<_ACEOF
6569 #line 6569 "configure"
6570 #include "confdefs.h"
6571 #include <$ac_header>
6573 if { (eval echo "$as_me:6573: \"$ac_cpp conftest.$ac_ext\"") >&5
6574 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6576 egrep -v '^ *\+' conftest.er1 >conftest.err
6578 cat conftest.err >&5
6579 echo "$as_me:6579: \$? = $ac_status" >&5
6580 (exit $ac_status); } >/dev/null; then
6581 if test -s conftest.err; then
6582 ac_cpp_err=$ac_c_preproc_warn_flag
6589 if test -z "$ac_cpp_err"; then
6590 eval "$as_ac_Header=yes"
6592 echo "$as_me: failed program was:" >&5
6593 cat conftest.$ac_ext >&5
6594 eval "$as_ac_Header=no"
6596 rm -f conftest.err conftest.$ac_ext
6598 echo "$as_me:6598: result: `eval echo '${'$as_ac_Header'}'`" >&5
6599 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6600 if test `eval echo '${'$as_ac_Header'}'` = yes; then
6601 cat >>confdefs.h <<EOF
6602 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6608 cat >>confdefs.h <<\EOF
6612 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
6614 cat >>confdefs.h <<EOF
6615 #define $cf_nculib_ROOT 1
6618 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
6622 cf_ncuhdr_root=ncurses
6624 test -n "$cf_cv_curses_dir" && \
6625 test "$cf_cv_curses_dir" != "no" && { \
6627 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
6628 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
6630 while test $cf_add_incdir != /usr/include
6632 if test -d $cf_add_incdir
6635 if test -n "$CFLAGS$CPPFLAGS" ; then
6636 # a loop is needed to ensure we can add subdirs of existing dirs
6637 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
6638 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
6639 cf_have_incdir=yes; break
6644 if test "$cf_have_incdir" = no ; then
6645 if test "$cf_add_incdir" = /usr/local/include ; then
6646 if test "$GCC" = yes
6648 cf_save_CPPFLAGS=$CPPFLAGS
6649 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6650 cat >conftest.$ac_ext <<_ACEOF
6651 #line 6651 "configure"
6652 #include "confdefs.h"
6662 rm -f conftest.$ac_objext
6663 if { (eval echo "$as_me:6663: \"$ac_compile\"") >&5
6664 (eval $ac_compile) 2>&5
6666 echo "$as_me:6666: \$? = $ac_status" >&5
6667 (exit $ac_status); } &&
6668 { ac_try='test -s conftest.$ac_objext'
6669 { (eval echo "$as_me:6669: \"$ac_try\"") >&5
6672 echo "$as_me:6672: \$? = $ac_status" >&5
6673 (exit $ac_status); }; }; then
6676 echo "$as_me: failed program was:" >&5
6677 cat conftest.$ac_ext >&5
6680 rm -f conftest.$ac_objext conftest.$ac_ext
6681 CPPFLAGS=$cf_save_CPPFLAGS
6686 if test "$cf_have_incdir" = no ; then
6687 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
6689 echo "${as_me:-configure}:6689: testing adding $cf_add_incdir to include-path ..." 1>&5
6691 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6693 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
6694 test "$cf_top_incdir" = "$cf_add_incdir" && break
6695 cf_add_incdir="$cf_top_incdir"
6706 echo "$as_me:6706: checking for $cf_ncuhdr_root header in include-path" >&5
6707 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
6708 if test "${cf_cv_ncurses_h+set}" = set; then
6709 echo $ECHO_N "(cached) $ECHO_C" >&6
6712 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
6713 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
6714 for cf_header in $cf_header_list
6717 cat >conftest.$ac_ext <<_ACEOF
6718 #line 6718 "configure"
6719 #include "confdefs.h"
6721 #include <$cf_header>
6726 #ifdef NCURSES_VERSION
6728 printf("%s\n", NCURSES_VERSION);
6741 rm -f conftest.$ac_objext
6742 if { (eval echo "$as_me:6742: \"$ac_compile\"") >&5
6743 (eval $ac_compile) 2>&5
6745 echo "$as_me:6745: \$? = $ac_status" >&5
6746 (exit $ac_status); } &&
6747 { ac_try='test -s conftest.$ac_objext'
6748 { (eval echo "$as_me:6748: \"$ac_try\"") >&5
6751 echo "$as_me:6751: \$? = $ac_status" >&5
6752 (exit $ac_status); }; }; then
6753 cf_cv_ncurses_h=$cf_header
6756 echo "$as_me: failed program was:" >&5
6757 cat conftest.$ac_ext >&5
6760 rm -f conftest.$ac_objext conftest.$ac_ext
6762 test "$cf_cv_ncurses_h" != no && break
6766 echo "$as_me:6766: result: $cf_cv_ncurses_h" >&5
6767 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
6769 if test "$cf_cv_ncurses_h" != no ; then
6770 cf_cv_ncurses_header=$cf_cv_ncurses_h
6773 echo "$as_me:6773: checking for $cf_ncuhdr_root include-path" >&5
6774 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
6775 if test "${cf_cv_ncurses_h2+set}" = set; then
6776 echo $ECHO_N "(cached) $ECHO_C" >&6
6779 test -n "$verbose" && echo
6783 # collect the current set of include-directories from compiler flags
6784 cf_header_path_list=""
6785 if test -n "${CFLAGS}${CPPFLAGS}" ; then
6786 for cf_header_path in $CPPFLAGS $CFLAGS
6788 case $cf_header_path in #(vi
6790 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
6792 test "$cf_header_path" != "NONE" && \
6793 test -d "$cf_header_path" && \
6795 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
6796 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
6797 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
6798 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
6799 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
6800 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"
6803 cf_header_path_list="$cf_header_path_list $cf_search"
6809 # add the variations for the package we are looking for
6813 test "/usr" != "$prefix" && \
6815 (test $prefix = NONE || test "/usr" != "$prefix") && {
6816 test -n "$verbose" && echo " ... testing for include-directories under /usr"
6817 test -d /usr/include && cf_search="$cf_search /usr/include"
6818 test -d /usr/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/include/$cf_ncuhdr_root"
6819 test -d /usr/include/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/include/$cf_ncuhdr_root/include"
6820 test -d /usr/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/$cf_ncuhdr_root/include"
6821 test -d /usr/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
6824 test "$prefix" != "NONE" && \
6825 test -d "$prefix" && \
6827 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
6828 test -d $prefix/include && cf_search="$cf_search $prefix/include"
6829 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
6830 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
6831 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
6832 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
6835 test "/usr/local" != "$prefix" && \
6836 test -d "/usr/local" && \
6837 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
6838 test -n "$verbose" && echo " ... testing for include-directories under /usr/local"
6839 test -d /usr/local/include && cf_search="$cf_search /usr/local/include"
6840 test -d /usr/local/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/local/include/$cf_ncuhdr_root"
6841 test -d /usr/local/include/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/local/include/$cf_ncuhdr_root/include"
6842 test -d /usr/local/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/local/$cf_ncuhdr_root/include"
6843 test -d /usr/local/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/local/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
6846 test "/opt" != "$prefix" && \
6848 (test $prefix = NONE || test "/opt" != "$prefix") && {
6849 test -n "$verbose" && echo " ... testing for include-directories under /opt"
6850 test -d /opt/include && cf_search="$cf_search /opt/include"
6851 test -d /opt/include/$cf_ncuhdr_root && cf_search="$cf_search /opt/include/$cf_ncuhdr_root"
6852 test -d /opt/include/$cf_ncuhdr_root/include && cf_search="$cf_search /opt/include/$cf_ncuhdr_root/include"
6853 test -d /opt/$cf_ncuhdr_root/include && cf_search="$cf_search /opt/$cf_ncuhdr_root/include"
6854 test -d /opt/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /opt/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
6857 test "$HOME" != "$prefix" && \
6858 test -d "$HOME" && \
6859 (test $prefix = NONE || test "$HOME" != "$prefix") && {
6860 test -n "$verbose" && echo " ... testing for include-directories under $HOME"
6861 test -d $HOME/include && cf_search="$cf_search $HOME/include"
6862 test -d $HOME/include/$cf_ncuhdr_root && cf_search="$cf_search $HOME/include/$cf_ncuhdr_root"
6863 test -d $HOME/include/$cf_ncuhdr_root/include && cf_search="$cf_search $HOME/include/$cf_ncuhdr_root/include"
6864 test -d $HOME/$cf_ncuhdr_root/include && cf_search="$cf_search $HOME/$cf_ncuhdr_root/include"
6865 test -d $HOME/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $HOME/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
6868 test "$includedir" != NONE && \
6869 test "$includedir" != "/usr/include" && \
6870 test -d "$includedir" && {
6871 test -d $includedir && cf_search="$cf_search $includedir"
6872 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
6875 test "$oldincludedir" != NONE && \
6876 test "$oldincludedir" != "/usr/include" && \
6877 test -d "$oldincludedir" && {
6878 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
6879 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
6882 cf_search="$cf_search $cf_header_path_list"
6884 test -n "$verbose" && echo search path $cf_search
6885 cf_save2_CPPFLAGS="$CPPFLAGS"
6886 for cf_incdir in $cf_search
6889 if test -n "$cf_incdir" ; then
6890 for cf_add_incdir in $cf_incdir
6892 while test $cf_add_incdir != /usr/include
6894 if test -d $cf_add_incdir
6897 if test -n "$CFLAGS$CPPFLAGS" ; then
6898 # a loop is needed to ensure we can add subdirs of existing dirs
6899 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
6900 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
6901 cf_have_incdir=yes; break
6906 if test "$cf_have_incdir" = no ; then
6907 if test "$cf_add_incdir" = /usr/local/include ; then
6908 if test "$GCC" = yes
6910 cf_save_CPPFLAGS=$CPPFLAGS
6911 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6912 cat >conftest.$ac_ext <<_ACEOF
6913 #line 6913 "configure"
6914 #include "confdefs.h"
6924 rm -f conftest.$ac_objext
6925 if { (eval echo "$as_me:6925: \"$ac_compile\"") >&5
6926 (eval $ac_compile) 2>&5
6928 echo "$as_me:6928: \$? = $ac_status" >&5
6929 (exit $ac_status); } &&
6930 { ac_try='test -s conftest.$ac_objext'
6931 { (eval echo "$as_me:6931: \"$ac_try\"") >&5
6934 echo "$as_me:6934: \$? = $ac_status" >&5
6935 (exit $ac_status); }; }; then
6938 echo "$as_me: failed program was:" >&5
6939 cat conftest.$ac_ext >&5
6942 rm -f conftest.$ac_objext conftest.$ac_ext
6943 CPPFLAGS=$cf_save_CPPFLAGS
6948 if test "$cf_have_incdir" = no ; then
6949 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
6951 echo "${as_me:-configure}:6951: testing adding $cf_add_incdir to include-path ..." 1>&5
6953 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6955 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
6956 test "$cf_top_incdir" = "$cf_add_incdir" && break
6957 cf_add_incdir="$cf_top_incdir"
6971 cat >conftest.$ac_ext <<_ACEOF
6972 #line 6972 "configure"
6973 #include "confdefs.h"
6975 #include <$cf_header>
6980 #ifdef NCURSES_VERSION
6982 printf("%s\n", NCURSES_VERSION);
6995 rm -f conftest.$ac_objext
6996 if { (eval echo "$as_me:6996: \"$ac_compile\"") >&5
6997 (eval $ac_compile) 2>&5
6999 echo "$as_me:6999: \$? = $ac_status" >&5
7000 (exit $ac_status); } &&
7001 { ac_try='test -s conftest.$ac_objext'
7002 { (eval echo "$as_me:7002: \"$ac_try\"") >&5
7005 echo "$as_me:7005: \$? = $ac_status" >&5
7006 (exit $ac_status); }; }; then
7007 cf_cv_ncurses_h2=$cf_header
7010 echo "$as_me: failed program was:" >&5
7011 cat conftest.$ac_ext >&5
7014 rm -f conftest.$ac_objext conftest.$ac_ext
7016 if test "$cf_cv_ncurses_h2" != no ; then
7017 cf_cv_ncurses_h2=$cf_incdir/$cf_header
7018 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
7021 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
7023 CPPFLAGS="$cf_save2_CPPFLAGS"
7024 test "$cf_cv_ncurses_h2" != no && break
7026 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:7026: error: not found" >&5
7027 echo "$as_me: error: not found" >&2;}
7028 { (exit 1); exit 1; }; }
7031 echo "$as_me:7031: result: $cf_cv_ncurses_h2" >&5
7032 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
7034 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
7035 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
7036 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
7037 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
7040 if test -n "$cf_1st_incdir" ; then
7041 for cf_add_incdir in $cf_1st_incdir
7043 while test $cf_add_incdir != /usr/include
7045 if test -d $cf_add_incdir
7048 if test -n "$CFLAGS$CPPFLAGS" ; then
7049 # a loop is needed to ensure we can add subdirs of existing dirs
7050 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
7051 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
7052 cf_have_incdir=yes; break
7057 if test "$cf_have_incdir" = no ; then
7058 if test "$cf_add_incdir" = /usr/local/include ; then
7059 if test "$GCC" = yes
7061 cf_save_CPPFLAGS=$CPPFLAGS
7062 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7063 cat >conftest.$ac_ext <<_ACEOF
7064 #line 7064 "configure"
7065 #include "confdefs.h"
7075 rm -f conftest.$ac_objext
7076 if { (eval echo "$as_me:7076: \"$ac_compile\"") >&5
7077 (eval $ac_compile) 2>&5
7079 echo "$as_me:7079: \$? = $ac_status" >&5
7080 (exit $ac_status); } &&
7081 { ac_try='test -s conftest.$ac_objext'
7082 { (eval echo "$as_me:7082: \"$ac_try\"") >&5
7085 echo "$as_me:7085: \$? = $ac_status" >&5
7086 (exit $ac_status); }; }; then
7089 echo "$as_me: failed program was:" >&5
7090 cat conftest.$ac_ext >&5
7093 rm -f conftest.$ac_objext conftest.$ac_ext
7094 CPPFLAGS=$cf_save_CPPFLAGS
7099 if test "$cf_have_incdir" = no ; then
7100 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
7102 echo "${as_me:-configure}:7102: testing adding $cf_add_incdir to include-path ..." 1>&5
7104 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7106 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
7107 test "$cf_top_incdir" = "$cf_add_incdir" && break
7108 cf_add_incdir="$cf_top_incdir"
7119 # Set definitions to allow ifdef'ing for ncurses.h
7121 case $cf_cv_ncurses_header in # (vi
7123 cat >>confdefs.h <<\EOF
7124 #define HAVE_NCURSES_H 1
7130 case $cf_cv_ncurses_header in # (vi
7131 ncurses/curses.h|ncurses/ncurses.h)
7132 cat >>confdefs.h <<\EOF
7133 #define HAVE_NCURSES_NCURSES_H 1
7137 ncursesw/curses.h|ncursesw/ncurses.h)
7138 cat >>confdefs.h <<\EOF
7139 #define HAVE_NCURSESW_NCURSES_H 1
7145 echo "$as_me:7145: checking for terminfo header" >&5
7146 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
7147 if test "${cf_cv_term_header+set}" = set; then
7148 echo $ECHO_N "(cached) $ECHO_C" >&6
7151 case ${cf_cv_ncurses_header} in #(vi
7152 */ncurses.h|*/ncursesw.h) #(vi
7153 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
7156 cf_term_header=term.h
7160 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
7162 cat >conftest.$ac_ext <<_ACEOF
7163 #line 7163 "configure"
7164 #include "confdefs.h"
7166 #include <${cf_cv_ncurses_header:-curses.h}>
7172 int x = auto_left_margin
7177 rm -f conftest.$ac_objext
7178 if { (eval echo "$as_me:7178: \"$ac_compile\"") >&5
7179 (eval $ac_compile) 2>&5
7181 echo "$as_me:7181: \$? = $ac_status" >&5
7182 (exit $ac_status); } &&
7183 { ac_try='test -s conftest.$ac_objext'
7184 { (eval echo "$as_me:7184: \"$ac_try\"") >&5
7187 echo "$as_me:7187: \$? = $ac_status" >&5
7188 (exit $ac_status); }; }; then
7190 cf_cv_term_header="$cf_test"
7192 echo "$as_me: failed program was:" >&5
7193 cat conftest.$ac_ext >&5
7195 cf_cv_term_header=unknown
7198 rm -f conftest.$ac_objext conftest.$ac_ext
7199 test "$cf_cv_term_header" != unknown && break
7203 echo "$as_me:7203: result: $cf_cv_term_header" >&5
7204 echo "${ECHO_T}$cf_cv_term_header" >&6
7206 # Set definitions to allow ifdef'ing to accommodate subdirectories
7208 case $cf_cv_term_header in # (vi
7210 cat >>confdefs.h <<\EOF
7211 #define HAVE_TERM_H 1
7217 case $cf_cv_term_header in # (vi
7218 ncurses/term.h) #(vi
7219 cat >>confdefs.h <<\EOF
7220 #define HAVE_NCURSES_TERM_H 1
7225 cat >>confdefs.h <<\EOF
7226 #define HAVE_NCURSESW_TERM_H 1
7232 # some applications need this, but should check for NCURSES_VERSION
7233 cat >>confdefs.h <<\EOF
7237 echo "$as_me:7237: checking for ncurses version" >&5
7238 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
7239 if test "${cf_cv_ncurses_version+set}" = set; then
7240 echo $ECHO_N "(cached) $ECHO_C" >&6
7243 cf_cv_ncurses_version=no
7246 if test "$cross_compiling" = yes; then
7248 # This will not work if the preprocessor splits the line after the
7249 # Autoconf token. The 'unproto' program does that.
7250 cat > conftest.$ac_ext <<EOF
7251 #include <${cf_cv_ncurses_header:-curses.h}>
7253 #ifdef NCURSES_VERSION
7254 Autoconf NCURSES_VERSION
7262 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
7263 { (eval echo "$as_me:7263: \"$cf_try\"") >&5
7266 echo "$as_me:7266: \$? = $ac_status" >&5
7267 (exit $ac_status); }
7268 if test -f conftest.out ; then
7269 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
7270 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
7275 cat >conftest.$ac_ext <<_ACEOF
7276 #line 7276 "configure"
7277 #include "confdefs.h"
7279 #include <${cf_cv_ncurses_header:-curses.h}>
7283 FILE *fp = fopen("$cf_tempfile", "w");
7284 #ifdef NCURSES_VERSION
7285 # ifdef NCURSES_VERSION_PATCH
7286 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
7288 fprintf(fp, "%s\n", NCURSES_VERSION);
7292 fprintf(fp, "old\n");
7297 ${cf_cv_main_return:-return}(0);
7300 rm -f conftest$ac_exeext
7301 if { (eval echo "$as_me:7301: \"$ac_link\"") >&5
7302 (eval $ac_link) 2>&5
7304 echo "$as_me:7304: \$? = $ac_status" >&5
7305 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
7306 { (eval echo "$as_me:7306: \"$ac_try\"") >&5
7309 echo "$as_me:7309: \$? = $ac_status" >&5
7310 (exit $ac_status); }; }; then
7312 cf_cv_ncurses_version=`cat $cf_tempfile`
7314 echo "$as_me: program exited with status $ac_status" >&5
7315 echo "$as_me: failed program was:" >&5
7316 cat conftest.$ac_ext >&5
7318 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
7323 echo "$as_me:7323: result: $cf_cv_ncurses_version" >&5
7324 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
7325 test "$cf_cv_ncurses_version" = no || cat >>confdefs.h <<\EOF
7329 cf_nculib_root=ncurses
7330 # This works, except for the special case where we find gpm, but
7331 # ncurses is in a nonstandard location via $LIBS, and we really want
7334 cf_ncurses_SAVE="$LIBS"
7335 echo "$as_me:7335: checking for Gpm_Open in -lgpm" >&5
7336 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
7337 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
7338 echo $ECHO_N "(cached) $ECHO_C" >&6
7340 ac_check_lib_save_LIBS=$LIBS
7342 cat >conftest.$ac_ext <<_ACEOF
7343 #line 7343 "configure"
7344 #include "confdefs.h"
7346 /* Override any gcc2 internal prototype to avoid an error. */
7350 /* We use char because int might match the return type of a gcc2
7351 builtin and then its argument prototype would still apply. */
7361 rm -f conftest.$ac_objext conftest$ac_exeext
7362 if { (eval echo "$as_me:7362: \"$ac_link\"") >&5
7363 (eval $ac_link) 2>&5
7365 echo "$as_me:7365: \$? = $ac_status" >&5
7366 (exit $ac_status); } &&
7367 { ac_try='test -s conftest$ac_exeext'
7368 { (eval echo "$as_me:7368: \"$ac_try\"") >&5
7371 echo "$as_me:7371: \$? = $ac_status" >&5
7372 (exit $ac_status); }; }; then
7373 ac_cv_lib_gpm_Gpm_Open=yes
7375 echo "$as_me: failed program was:" >&5
7376 cat conftest.$ac_ext >&5
7377 ac_cv_lib_gpm_Gpm_Open=no
7379 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7380 LIBS=$ac_check_lib_save_LIBS
7382 echo "$as_me:7382: result: $ac_cv_lib_gpm_Gpm_Open" >&5
7383 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
7384 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
7385 echo "$as_me:7385: checking for initscr in -lgpm" >&5
7386 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
7387 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
7388 echo $ECHO_N "(cached) $ECHO_C" >&6
7390 ac_check_lib_save_LIBS=$LIBS
7392 cat >conftest.$ac_ext <<_ACEOF
7393 #line 7393 "configure"
7394 #include "confdefs.h"
7396 /* Override any gcc2 internal prototype to avoid an error. */
7400 /* We use char because int might match the return type of a gcc2
7401 builtin and then its argument prototype would still apply. */
7411 rm -f conftest.$ac_objext conftest$ac_exeext
7412 if { (eval echo "$as_me:7412: \"$ac_link\"") >&5
7413 (eval $ac_link) 2>&5
7415 echo "$as_me:7415: \$? = $ac_status" >&5
7416 (exit $ac_status); } &&
7417 { ac_try='test -s conftest$ac_exeext'
7418 { (eval echo "$as_me:7418: \"$ac_try\"") >&5
7421 echo "$as_me:7421: \$? = $ac_status" >&5
7422 (exit $ac_status); }; }; then
7423 ac_cv_lib_gpm_initscr=yes
7425 echo "$as_me: failed program was:" >&5
7426 cat conftest.$ac_ext >&5
7427 ac_cv_lib_gpm_initscr=no
7429 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7430 LIBS=$ac_check_lib_save_LIBS
7432 echo "$as_me:7432: result: $ac_cv_lib_gpm_initscr" >&5
7433 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
7434 if test $ac_cv_lib_gpm_initscr = yes; then
7435 LIBS="$cf_ncurses_SAVE"
7437 cf_ncurses_LIBS="-lgpm"
7442 case $host_os in #(vi
7444 # This is only necessary if you are linking against an obsolete
7445 # version of ncurses (but it should do no harm, since it's static).
7446 if test "$cf_nculib_root" = ncurses ; then
7447 echo "$as_me:7447: checking for tgoto in -lmytinfo" >&5
7448 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
7449 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
7450 echo $ECHO_N "(cached) $ECHO_C" >&6
7452 ac_check_lib_save_LIBS=$LIBS
7453 LIBS="-lmytinfo $LIBS"
7454 cat >conftest.$ac_ext <<_ACEOF
7455 #line 7455 "configure"
7456 #include "confdefs.h"
7458 /* Override any gcc2 internal prototype to avoid an error. */
7462 /* We use char because int might match the return type of a gcc2
7463 builtin and then its argument prototype would still apply. */
7473 rm -f conftest.$ac_objext conftest$ac_exeext
7474 if { (eval echo "$as_me:7474: \"$ac_link\"") >&5
7475 (eval $ac_link) 2>&5
7477 echo "$as_me:7477: \$? = $ac_status" >&5
7478 (exit $ac_status); } &&
7479 { ac_try='test -s conftest$ac_exeext'
7480 { (eval echo "$as_me:7480: \"$ac_try\"") >&5
7483 echo "$as_me:7483: \$? = $ac_status" >&5
7484 (exit $ac_status); }; }; then
7485 ac_cv_lib_mytinfo_tgoto=yes
7487 echo "$as_me: failed program was:" >&5
7488 cat conftest.$ac_ext >&5
7489 ac_cv_lib_mytinfo_tgoto=no
7491 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7492 LIBS=$ac_check_lib_save_LIBS
7494 echo "$as_me:7494: result: $ac_cv_lib_mytinfo_tgoto" >&5
7495 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
7496 if test $ac_cv_lib_mytinfo_tgoto = yes; then
7497 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
7504 LIBS="$cf_ncurses_LIBS $LIBS"
7506 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
7508 LIBS="-l$cf_nculib_root $LIBS"
7511 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
7513 echo "$as_me:7513: checking for initscr" >&5
7514 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
7515 if test "${ac_cv_func_initscr+set}" = set; then
7516 echo $ECHO_N "(cached) $ECHO_C" >&6
7518 cat >conftest.$ac_ext <<_ACEOF
7519 #line 7519 "configure"
7520 #include "confdefs.h"
7521 /* System header to define __stub macros and hopefully few prototypes,
7522 which can conflict with char initscr (); below. */
7524 /* Override any gcc2 internal prototype to avoid an error. */
7528 /* We use char because int might match the return type of a gcc2
7529 builtin and then its argument prototype would still apply. */
7536 /* The GNU C library defines this for functions which it implements
7537 to always fail with ENOSYS. Some functions are actually named
7538 something starting with __ and the normal name is an alias. */
7539 #if defined (__stub_initscr) || defined (__stub___initscr)
7549 rm -f conftest.$ac_objext conftest$ac_exeext
7550 if { (eval echo "$as_me:7550: \"$ac_link\"") >&5
7551 (eval $ac_link) 2>&5
7553 echo "$as_me:7553: \$? = $ac_status" >&5
7554 (exit $ac_status); } &&
7555 { ac_try='test -s conftest$ac_exeext'
7556 { (eval echo "$as_me:7556: \"$ac_try\"") >&5
7559 echo "$as_me:7559: \$? = $ac_status" >&5
7560 (exit $ac_status); }; }; then
7561 ac_cv_func_initscr=yes
7563 echo "$as_me: failed program was:" >&5
7564 cat conftest.$ac_ext >&5
7565 ac_cv_func_initscr=no
7567 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7569 echo "$as_me:7569: result: $ac_cv_func_initscr" >&5
7570 echo "${ECHO_T}$ac_cv_func_initscr" >&6
7571 if test $ac_cv_func_initscr = yes; then
7572 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
7575 cf_save_LIBS="$LIBS"
7576 echo "$as_me:7576: checking for initscr in -l$cf_nculib_root" >&5
7577 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
7578 LIBS="-l$cf_nculib_root $LIBS"
7579 cat >conftest.$ac_ext <<_ACEOF
7580 #line 7580 "configure"
7581 #include "confdefs.h"
7582 #include <${cf_cv_ncurses_header:-curses.h}>
7591 rm -f conftest.$ac_objext conftest$ac_exeext
7592 if { (eval echo "$as_me:7592: \"$ac_link\"") >&5
7593 (eval $ac_link) 2>&5
7595 echo "$as_me:7595: \$? = $ac_status" >&5
7596 (exit $ac_status); } &&
7597 { ac_try='test -s conftest$ac_exeext'
7598 { (eval echo "$as_me:7598: \"$ac_try\"") >&5
7601 echo "$as_me:7601: \$? = $ac_status" >&5
7602 (exit $ac_status); }; }; then
7603 echo "$as_me:7603: result: yes" >&5
7604 echo "${ECHO_T}yes" >&6
7605 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
7608 echo "$as_me: failed program was:" >&5
7609 cat conftest.$ac_ext >&5
7610 echo "$as_me:7610: result: no" >&5
7611 echo "${ECHO_T}no" >&6
7614 cf_library_path_list=""
7615 if test -n "${LDFLAGS}${LIBS}" ; then
7616 for cf_library_path in $LDFLAGS $LIBS
7618 case $cf_library_path in #(vi
7620 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
7622 test "$cf_library_path" != "NONE" && \
7623 test -d "$cf_library_path" && \
7625 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
7626 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
7627 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
7628 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
7629 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
7630 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"
7633 cf_library_path_list="$cf_library_path_list $cf_search"
7641 test "/usr" != "$prefix" && \
7643 (test $prefix = NONE || test "/usr" != "$prefix") && {
7644 test -n "$verbose" && echo " ... testing for lib-directories under /usr"
7645 test -d /usr/lib && cf_search="$cf_search /usr/lib"
7646 test -d /usr/lib/$cf_nculib_root && cf_search="$cf_search /usr/lib/$cf_nculib_root"
7647 test -d /usr/lib/$cf_nculib_root/lib && cf_search="$cf_search /usr/lib/$cf_nculib_root/lib"
7648 test -d /usr/$cf_nculib_root/lib && cf_search="$cf_search /usr/$cf_nculib_root/lib"
7649 test -d /usr/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /usr/$cf_nculib_root/lib/$cf_nculib_root"
7652 test "$prefix" != "NONE" && \
7653 test -d "$prefix" && \
7655 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
7656 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
7657 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
7658 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
7659 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
7660 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
7663 test "/usr/local" != "$prefix" && \
7664 test -d "/usr/local" && \
7665 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
7666 test -n "$verbose" && echo " ... testing for lib-directories under /usr/local"
7667 test -d /usr/local/lib && cf_search="$cf_search /usr/local/lib"
7668 test -d /usr/local/lib/$cf_nculib_root && cf_search="$cf_search /usr/local/lib/$cf_nculib_root"
7669 test -d /usr/local/lib/$cf_nculib_root/lib && cf_search="$cf_search /usr/local/lib/$cf_nculib_root/lib"
7670 test -d /usr/local/$cf_nculib_root/lib && cf_search="$cf_search /usr/local/$cf_nculib_root/lib"
7671 test -d /usr/local/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /usr/local/$cf_nculib_root/lib/$cf_nculib_root"
7674 test "/opt" != "$prefix" && \
7676 (test $prefix = NONE || test "/opt" != "$prefix") && {
7677 test -n "$verbose" && echo " ... testing for lib-directories under /opt"
7678 test -d /opt/lib && cf_search="$cf_search /opt/lib"
7679 test -d /opt/lib/$cf_nculib_root && cf_search="$cf_search /opt/lib/$cf_nculib_root"
7680 test -d /opt/lib/$cf_nculib_root/lib && cf_search="$cf_search /opt/lib/$cf_nculib_root/lib"
7681 test -d /opt/$cf_nculib_root/lib && cf_search="$cf_search /opt/$cf_nculib_root/lib"
7682 test -d /opt/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /opt/$cf_nculib_root/lib/$cf_nculib_root"
7685 test "$HOME" != "$prefix" && \
7686 test -d "$HOME" && \
7687 (test $prefix = NONE || test "$HOME" != "$prefix") && {
7688 test -n "$verbose" && echo " ... testing for lib-directories under $HOME"
7689 test -d $HOME/lib && cf_search="$cf_search $HOME/lib"
7690 test -d $HOME/lib/$cf_nculib_root && cf_search="$cf_search $HOME/lib/$cf_nculib_root"
7691 test -d $HOME/lib/$cf_nculib_root/lib && cf_search="$cf_search $HOME/lib/$cf_nculib_root/lib"
7692 test -d $HOME/$cf_nculib_root/lib && cf_search="$cf_search $HOME/$cf_nculib_root/lib"
7693 test -d $HOME/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $HOME/$cf_nculib_root/lib/$cf_nculib_root"
7696 cf_search="$cf_library_path_list $cf_search"
7698 for cf_libdir in $cf_search
7700 echo "$as_me:7700: checking for -l$cf_nculib_root in $cf_libdir" >&5
7701 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
7702 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
7703 cat >conftest.$ac_ext <<_ACEOF
7704 #line 7704 "configure"
7705 #include "confdefs.h"
7706 #include <${cf_cv_ncurses_header:-curses.h}>
7715 rm -f conftest.$ac_objext conftest$ac_exeext
7716 if { (eval echo "$as_me:7716: \"$ac_link\"") >&5
7717 (eval $ac_link) 2>&5
7719 echo "$as_me:7719: \$? = $ac_status" >&5
7720 (exit $ac_status); } &&
7721 { ac_try='test -s conftest$ac_exeext'
7722 { (eval echo "$as_me:7722: \"$ac_try\"") >&5
7725 echo "$as_me:7725: \$? = $ac_status" >&5
7726 (exit $ac_status); }; }; then
7727 echo "$as_me:7727: result: yes" >&5
7728 echo "${ECHO_T}yes" >&6
7729 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
7732 echo "$as_me: failed program was:" >&5
7733 cat conftest.$ac_ext >&5
7734 echo "$as_me:7734: result: no" >&5
7735 echo "${ECHO_T}no" >&6
7736 LIBS="$cf_save_LIBS"
7738 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7742 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7746 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
7748 if test $cf_found_library = no ; then
7749 { { echo "$as_me:7749: error: Cannot link $cf_nculib_root library" >&5
7750 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
7751 { (exit 1); exit 1; }; }
7756 if test -n "$cf_ncurses_LIBS" ; then
7757 echo "$as_me:7757: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
7758 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
7759 cf_ncurses_SAVE="$LIBS"
7760 for p in $cf_ncurses_LIBS ; do
7761 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
7762 if test "$q" != "$LIBS" ; then
7766 cat >conftest.$ac_ext <<_ACEOF
7767 #line 7767 "configure"
7768 #include "confdefs.h"
7769 #include <${cf_cv_ncurses_header:-curses.h}>
7773 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
7778 rm -f conftest.$ac_objext conftest$ac_exeext
7779 if { (eval echo "$as_me:7779: \"$ac_link\"") >&5
7780 (eval $ac_link) 2>&5
7782 echo "$as_me:7782: \$? = $ac_status" >&5
7783 (exit $ac_status); } &&
7784 { ac_try='test -s conftest$ac_exeext'
7785 { (eval echo "$as_me:7785: \"$ac_try\"") >&5
7788 echo "$as_me:7788: \$? = $ac_status" >&5
7789 (exit $ac_status); }; }; then
7790 echo "$as_me:7790: result: yes" >&5
7791 echo "${ECHO_T}yes" >&6
7793 echo "$as_me: failed program was:" >&5
7794 cat conftest.$ac_ext >&5
7795 echo "$as_me:7795: result: no" >&5
7796 echo "${ECHO_T}no" >&6
7797 LIBS="$cf_ncurses_SAVE"
7799 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7802 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
7804 cat >>confdefs.h <<EOF
7805 #define $cf_nculib_ROOT 1
7813 echo "$as_me:7813: checking for multibyte character support" >&5
7814 echo $ECHO_N "checking for multibyte character support... $ECHO_C" >&6
7815 if test "${cf_cv_utf8_lib+set}" = set; then
7816 echo $ECHO_N "(cached) $ECHO_C" >&6
7819 cf_save_LIBS="$LIBS"
7820 cat >conftest.$ac_ext <<_ACEOF
7821 #line 7821 "configure"
7822 #include "confdefs.h"
7833 rm -f conftest.$ac_objext conftest$ac_exeext
7834 if { (eval echo "$as_me:7834: \"$ac_link\"") >&5
7835 (eval $ac_link) 2>&5
7837 echo "$as_me:7837: \$? = $ac_status" >&5
7838 (exit $ac_status); } &&
7839 { ac_try='test -s conftest$ac_exeext'
7840 { (eval echo "$as_me:7840: \"$ac_try\"") >&5
7843 echo "$as_me:7843: \$? = $ac_status" >&5
7844 (exit $ac_status); }; }; then
7847 echo "$as_me: failed program was:" >&5
7848 cat conftest.$ac_ext >&5
7850 # If the linkage is not already in the $CPPFLAGS/$LDFLAGS configuration, these
7851 # will be set on completion of the AC_TRY_LINK below.
7852 cf_cv_header_path_utf8=
7853 cf_cv_library_path_utf8=
7855 echo "${as_me:-configure}:7855: testing Starting FIND_LINKAGE(utf8,) ..." 1>&5
7857 cf_save_LIBS="$LIBS"
7859 cat >conftest.$ac_ext <<_ACEOF
7860 #line 7860 "configure"
7861 #include "confdefs.h"
7863 #include <libutf8.h>
7872 rm -f conftest.$ac_objext conftest$ac_exeext
7873 if { (eval echo "$as_me:7873: \"$ac_link\"") >&5
7874 (eval $ac_link) 2>&5
7876 echo "$as_me:7876: \$? = $ac_status" >&5
7877 (exit $ac_status); } &&
7878 { ac_try='test -s conftest$ac_exeext'
7879 { (eval echo "$as_me:7879: \"$ac_try\"") >&5
7882 echo "$as_me:7882: \$? = $ac_status" >&5
7883 (exit $ac_status); }; }; then
7885 cf_cv_find_linkage_utf8=yes
7886 cf_cv_header_path_utf8=/usr/include
7887 cf_cv_library_path_utf8=/usr/lib
7890 echo "$as_me: failed program was:" >&5
7891 cat conftest.$ac_ext >&5
7893 LIBS="-lutf8 $cf_save_LIBS"
7895 cat >conftest.$ac_ext <<_ACEOF
7896 #line 7896 "configure"
7897 #include "confdefs.h"
7899 #include <libutf8.h>
7908 rm -f conftest.$ac_objext conftest$ac_exeext
7909 if { (eval echo "$as_me:7909: \"$ac_link\"") >&5
7910 (eval $ac_link) 2>&5
7912 echo "$as_me:7912: \$? = $ac_status" >&5
7913 (exit $ac_status); } &&
7914 { ac_try='test -s conftest$ac_exeext'
7915 { (eval echo "$as_me:7915: \"$ac_try\"") >&5
7918 echo "$as_me:7918: \$? = $ac_status" >&5
7919 (exit $ac_status); }; }; then
7921 cf_cv_find_linkage_utf8=yes
7922 cf_cv_header_path_utf8=/usr/include
7923 cf_cv_library_path_utf8=/usr/lib
7924 cf_cv_library_file_utf8="-lutf8"
7927 echo "$as_me: failed program was:" >&5
7928 cat conftest.$ac_ext >&5
7930 cf_cv_find_linkage_utf8=no
7931 LIBS="$cf_save_LIBS"
7933 test -n "$verbose" && echo " find linkage for utf8 library" 1>&6
7935 echo "${as_me:-configure}:7935: testing find linkage for utf8 library ..." 1>&5
7937 echo "${as_me:-configure}:7937: testing Searching for headers in FIND_LINKAGE(utf8,) ..." 1>&5
7939 cf_save_CPPFLAGS="$CPPFLAGS"
7940 cf_test_CPPFLAGS="$CPPFLAGS"
7944 # collect the current set of include-directories from compiler flags
7945 cf_header_path_list=""
7946 if test -n "${CFLAGS}${CPPFLAGS}" ; then
7947 for cf_header_path in $CPPFLAGS $CFLAGS
7949 case $cf_header_path in #(vi
7951 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
7953 test "$cf_header_path" != "NONE" && \
7954 test -d "$cf_header_path" && \
7956 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
7957 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
7958 test -d $cf_header_path/include/utf8 && cf_search="$cf_search $cf_header_path/include/utf8"
7959 test -d $cf_header_path/include/utf8/include && cf_search="$cf_search $cf_header_path/include/utf8/include"
7960 test -d $cf_header_path/utf8/include && cf_search="$cf_search $cf_header_path/utf8/include"
7961 test -d $cf_header_path/utf8/include/utf8 && cf_search="$cf_search $cf_header_path/utf8/include/utf8"
7964 cf_header_path_list="$cf_header_path_list $cf_search"
7970 # add the variations for the package we are looking for
7974 test "/usr" != "$prefix" && \
7976 (test $prefix = NONE || test "/usr" != "$prefix") && {
7977 test -n "$verbose" && echo " ... testing for include-directories under /usr"
7978 test -d /usr/include && cf_search="$cf_search /usr/include"
7979 test -d /usr/include/utf8 && cf_search="$cf_search /usr/include/utf8"
7980 test -d /usr/include/utf8/include && cf_search="$cf_search /usr/include/utf8/include"
7981 test -d /usr/utf8/include && cf_search="$cf_search /usr/utf8/include"
7982 test -d /usr/utf8/include/utf8 && cf_search="$cf_search /usr/utf8/include/utf8"
7985 test "$prefix" != "NONE" && \
7986 test -d "$prefix" && \
7988 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
7989 test -d $prefix/include && cf_search="$cf_search $prefix/include"
7990 test -d $prefix/include/utf8 && cf_search="$cf_search $prefix/include/utf8"
7991 test -d $prefix/include/utf8/include && cf_search="$cf_search $prefix/include/utf8/include"
7992 test -d $prefix/utf8/include && cf_search="$cf_search $prefix/utf8/include"
7993 test -d $prefix/utf8/include/utf8 && cf_search="$cf_search $prefix/utf8/include/utf8"
7996 test "/usr/local" != "$prefix" && \
7997 test -d "/usr/local" && \
7998 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
7999 test -n "$verbose" && echo " ... testing for include-directories under /usr/local"
8000 test -d /usr/local/include && cf_search="$cf_search /usr/local/include"
8001 test -d /usr/local/include/utf8 && cf_search="$cf_search /usr/local/include/utf8"
8002 test -d /usr/local/include/utf8/include && cf_search="$cf_search /usr/local/include/utf8/include"
8003 test -d /usr/local/utf8/include && cf_search="$cf_search /usr/local/utf8/include"
8004 test -d /usr/local/utf8/include/utf8 && cf_search="$cf_search /usr/local/utf8/include/utf8"
8007 test "/opt" != "$prefix" && \
8009 (test $prefix = NONE || test "/opt" != "$prefix") && {
8010 test -n "$verbose" && echo " ... testing for include-directories under /opt"
8011 test -d /opt/include && cf_search="$cf_search /opt/include"
8012 test -d /opt/include/utf8 && cf_search="$cf_search /opt/include/utf8"
8013 test -d /opt/include/utf8/include && cf_search="$cf_search /opt/include/utf8/include"
8014 test -d /opt/utf8/include && cf_search="$cf_search /opt/utf8/include"
8015 test -d /opt/utf8/include/utf8 && cf_search="$cf_search /opt/utf8/include/utf8"
8018 test "$HOME" != "$prefix" && \
8019 test -d "$HOME" && \
8020 (test $prefix = NONE || test "$HOME" != "$prefix") && {
8021 test -n "$verbose" && echo " ... testing for include-directories under $HOME"
8022 test -d $HOME/include && cf_search="$cf_search $HOME/include"
8023 test -d $HOME/include/utf8 && cf_search="$cf_search $HOME/include/utf8"
8024 test -d $HOME/include/utf8/include && cf_search="$cf_search $HOME/include/utf8/include"
8025 test -d $HOME/utf8/include && cf_search="$cf_search $HOME/utf8/include"
8026 test -d $HOME/utf8/include/utf8 && cf_search="$cf_search $HOME/utf8/include/utf8"
8029 test "$includedir" != NONE && \
8030 test "$includedir" != "/usr/include" && \
8031 test -d "$includedir" && {
8032 test -d $includedir && cf_search="$cf_search $includedir"
8033 test -d $includedir/utf8 && cf_search="$cf_search $includedir/utf8"
8036 test "$oldincludedir" != NONE && \
8037 test "$oldincludedir" != "/usr/include" && \
8038 test -d "$oldincludedir" && {
8039 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
8040 test -d $oldincludedir/utf8 && cf_search="$cf_search $oldincludedir/utf8"
8043 cf_search="$cf_search $cf_header_path_list"
8045 for cf_cv_header_path_utf8 in $cf_search
8047 if test -d $cf_cv_header_path_utf8 ; then
8048 test -n "$verbose" && echo " ... testing $cf_cv_header_path_utf8" 1>&6
8050 echo "${as_me:-configure}:8050: testing ... testing $cf_cv_header_path_utf8 ..." 1>&5
8052 CPPFLAGS="$cf_save_CPPFLAGS -I$cf_cv_header_path_utf8"
8053 cat >conftest.$ac_ext <<_ACEOF
8054 #line 8054 "configure"
8055 #include "confdefs.h"
8057 #include <libutf8.h>
8066 rm -f conftest.$ac_objext
8067 if { (eval echo "$as_me:8067: \"$ac_compile\"") >&5
8068 (eval $ac_compile) 2>&5
8070 echo "$as_me:8070: \$? = $ac_status" >&5
8071 (exit $ac_status); } &&
8072 { ac_try='test -s conftest.$ac_objext'
8073 { (eval echo "$as_me:8073: \"$ac_try\"") >&5
8076 echo "$as_me:8076: \$? = $ac_status" >&5
8077 (exit $ac_status); }; }; then
8079 test -n "$verbose" && echo " ... found utf8 headers in $cf_cv_header_path_utf8" 1>&6
8081 echo "${as_me:-configure}:8081: testing ... found utf8 headers in $cf_cv_header_path_utf8 ..." 1>&5
8083 cf_cv_find_linkage_utf8=maybe
8084 cf_test_CPPFLAGS="$CPPFLAGS"
8087 echo "$as_me: failed program was:" >&5
8088 cat conftest.$ac_ext >&5
8090 CPPFLAGS="$cf_save_CPPFLAGS"
8093 rm -f conftest.$ac_objext conftest.$ac_ext
8097 if test "$cf_cv_find_linkage_utf8" = maybe ; then
8099 echo "${as_me:-configure}:8099: testing Searching for utf8 library in FIND_LINKAGE(utf8,) ..." 1>&5
8101 cf_save_LIBS="$LIBS"
8102 cf_save_LDFLAGS="$LDFLAGS"
8104 if test "$cf_cv_find_linkage_utf8" != yes ; then
8107 cf_library_path_list=""
8108 if test -n "${LDFLAGS}${LIBS}" ; then
8109 for cf_library_path in $LDFLAGS $LIBS
8111 case $cf_library_path in #(vi
8113 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
8115 test "$cf_library_path" != "NONE" && \
8116 test -d "$cf_library_path" && \
8118 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
8119 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
8120 test -d $cf_library_path/lib/utf8 && cf_search="$cf_search $cf_library_path/lib/utf8"
8121 test -d $cf_library_path/lib/utf8/lib && cf_search="$cf_search $cf_library_path/lib/utf8/lib"
8122 test -d $cf_library_path/utf8/lib && cf_search="$cf_search $cf_library_path/utf8/lib"
8123 test -d $cf_library_path/utf8/lib/utf8 && cf_search="$cf_search $cf_library_path/utf8/lib/utf8"
8126 cf_library_path_list="$cf_library_path_list $cf_search"
8134 test "/usr" != "$prefix" && \
8136 (test $prefix = NONE || test "/usr" != "$prefix") && {
8137 test -n "$verbose" && echo " ... testing for lib-directories under /usr"
8138 test -d /usr/lib && cf_search="$cf_search /usr/lib"
8139 test -d /usr/lib/utf8 && cf_search="$cf_search /usr/lib/utf8"
8140 test -d /usr/lib/utf8/lib && cf_search="$cf_search /usr/lib/utf8/lib"
8141 test -d /usr/utf8/lib && cf_search="$cf_search /usr/utf8/lib"
8142 test -d /usr/utf8/lib/utf8 && cf_search="$cf_search /usr/utf8/lib/utf8"
8145 test "$prefix" != "NONE" && \
8146 test -d "$prefix" && \
8148 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
8149 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
8150 test -d $prefix/lib/utf8 && cf_search="$cf_search $prefix/lib/utf8"
8151 test -d $prefix/lib/utf8/lib && cf_search="$cf_search $prefix/lib/utf8/lib"
8152 test -d $prefix/utf8/lib && cf_search="$cf_search $prefix/utf8/lib"
8153 test -d $prefix/utf8/lib/utf8 && cf_search="$cf_search $prefix/utf8/lib/utf8"
8156 test "/usr/local" != "$prefix" && \
8157 test -d "/usr/local" && \
8158 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
8159 test -n "$verbose" && echo " ... testing for lib-directories under /usr/local"
8160 test -d /usr/local/lib && cf_search="$cf_search /usr/local/lib"
8161 test -d /usr/local/lib/utf8 && cf_search="$cf_search /usr/local/lib/utf8"
8162 test -d /usr/local/lib/utf8/lib && cf_search="$cf_search /usr/local/lib/utf8/lib"
8163 test -d /usr/local/utf8/lib && cf_search="$cf_search /usr/local/utf8/lib"
8164 test -d /usr/local/utf8/lib/utf8 && cf_search="$cf_search /usr/local/utf8/lib/utf8"
8167 test "/opt" != "$prefix" && \
8169 (test $prefix = NONE || test "/opt" != "$prefix") && {
8170 test -n "$verbose" && echo " ... testing for lib-directories under /opt"
8171 test -d /opt/lib && cf_search="$cf_search /opt/lib"
8172 test -d /opt/lib/utf8 && cf_search="$cf_search /opt/lib/utf8"
8173 test -d /opt/lib/utf8/lib && cf_search="$cf_search /opt/lib/utf8/lib"
8174 test -d /opt/utf8/lib && cf_search="$cf_search /opt/utf8/lib"
8175 test -d /opt/utf8/lib/utf8 && cf_search="$cf_search /opt/utf8/lib/utf8"
8178 test "$HOME" != "$prefix" && \
8179 test -d "$HOME" && \
8180 (test $prefix = NONE || test "$HOME" != "$prefix") && {
8181 test -n "$verbose" && echo " ... testing for lib-directories under $HOME"
8182 test -d $HOME/lib && cf_search="$cf_search $HOME/lib"
8183 test -d $HOME/lib/utf8 && cf_search="$cf_search $HOME/lib/utf8"
8184 test -d $HOME/lib/utf8/lib && cf_search="$cf_search $HOME/lib/utf8/lib"
8185 test -d $HOME/utf8/lib && cf_search="$cf_search $HOME/utf8/lib"
8186 test -d $HOME/utf8/lib/utf8 && cf_search="$cf_search $HOME/utf8/lib/utf8"
8189 cf_search="$cf_library_path_list $cf_search"
8191 for cf_cv_library_path_utf8 in $cf_search
8193 if test -d $cf_cv_library_path_utf8 ; then
8194 test -n "$verbose" && echo " ... testing $cf_cv_library_path_utf8" 1>&6
8196 echo "${as_me:-configure}:8196: testing ... testing $cf_cv_library_path_utf8 ..." 1>&5
8198 CPPFLAGS="$cf_test_CPPFLAGS"
8199 LIBS="-lutf8 $cf_save_LIBS"
8200 LDFLAGS="$cf_save_LDFLAGS -L$cf_cv_library_path_utf8"
8201 cat >conftest.$ac_ext <<_ACEOF
8202 #line 8202 "configure"
8203 #include "confdefs.h"
8205 #include <libutf8.h>
8214 rm -f conftest.$ac_objext conftest$ac_exeext
8215 if { (eval echo "$as_me:8215: \"$ac_link\"") >&5
8216 (eval $ac_link) 2>&5
8218 echo "$as_me:8218: \$? = $ac_status" >&5
8219 (exit $ac_status); } &&
8220 { ac_try='test -s conftest$ac_exeext'
8221 { (eval echo "$as_me:8221: \"$ac_try\"") >&5
8224 echo "$as_me:8224: \$? = $ac_status" >&5
8225 (exit $ac_status); }; }; then
8227 test -n "$verbose" && echo " ... found utf8 library in $cf_cv_library_path_utf8" 1>&6
8229 echo "${as_me:-configure}:8229: testing ... found utf8 library in $cf_cv_library_path_utf8 ..." 1>&5
8231 cf_cv_find_linkage_utf8=yes
8232 cf_cv_library_file_utf8="-lutf8"
8235 echo "$as_me: failed program was:" >&5
8236 cat conftest.$ac_ext >&5
8238 CPPFLAGS="$cf_save_CPPFLAGS"
8239 LIBS="$cf_save_LIBS"
8240 LDFLAGS="$cf_save_LDFLAGS"
8243 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8246 CPPFLAGS="$cf_save_CPPFLAGS"
8247 LDFLAGS="$cf_save_LDFLAGS"
8251 cf_cv_find_linkage_utf8=no
8255 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8258 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8260 LIBS="$cf_save_LIBS"
8262 if test "$cf_cv_find_linkage_utf8" = yes ; then
8263 cf_cv_utf8_lib=add-on
8269 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8271 echo "$as_me:8271: result: $cf_cv_utf8_lib" >&5
8272 echo "${ECHO_T}$cf_cv_utf8_lib" >&6
8274 # HAVE_LIBUTF8_H is used by ncurses if curses.h is shared between
8276 if test "$cf_cv_utf8_lib" = "add-on" ; then
8277 cat >>confdefs.h <<\EOF
8278 #define HAVE_LIBUTF8_H 1
8281 if test -n "$cf_cv_header_path_utf8" ; then
8282 for cf_add_incdir in $cf_cv_header_path_utf8
8284 while test $cf_add_incdir != /usr/include
8286 if test -d $cf_add_incdir
8289 if test -n "$CFLAGS$CPPFLAGS" ; then
8290 # a loop is needed to ensure we can add subdirs of existing dirs
8291 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
8292 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
8293 cf_have_incdir=yes; break
8298 if test "$cf_have_incdir" = no ; then
8299 if test "$cf_add_incdir" = /usr/local/include ; then
8300 if test "$GCC" = yes
8302 cf_save_CPPFLAGS=$CPPFLAGS
8303 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8304 cat >conftest.$ac_ext <<_ACEOF
8305 #line 8305 "configure"
8306 #include "confdefs.h"
8316 rm -f conftest.$ac_objext
8317 if { (eval echo "$as_me:8317: \"$ac_compile\"") >&5
8318 (eval $ac_compile) 2>&5
8320 echo "$as_me:8320: \$? = $ac_status" >&5
8321 (exit $ac_status); } &&
8322 { ac_try='test -s conftest.$ac_objext'
8323 { (eval echo "$as_me:8323: \"$ac_try\"") >&5
8326 echo "$as_me:8326: \$? = $ac_status" >&5
8327 (exit $ac_status); }; }; then
8330 echo "$as_me: failed program was:" >&5
8331 cat conftest.$ac_ext >&5
8334 rm -f conftest.$ac_objext conftest.$ac_ext
8335 CPPFLAGS=$cf_save_CPPFLAGS
8340 if test "$cf_have_incdir" = no ; then
8341 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
8343 echo "${as_me:-configure}:8343: testing adding $cf_add_incdir to include-path ..." 1>&5
8345 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8347 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
8348 test "$cf_top_incdir" = "$cf_add_incdir" && break
8349 cf_add_incdir="$cf_top_incdir"
8358 if test -n "$cf_cv_library_path_utf8" ; then
8359 for cf_add_libdir in $cf_cv_library_path_utf8
8361 if test $cf_add_libdir = /usr/lib ; then
8363 elif test -d $cf_add_libdir
8366 if test -n "$LDFLAGS$LIBS" ; then
8367 # a loop is needed to ensure we can add subdirs of existing dirs
8368 for cf_test_libdir in $LDFLAGS $LIBS ; do
8369 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
8370 cf_have_libdir=yes; break
8374 if test "$cf_have_libdir" = no ; then
8375 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
8377 echo "${as_me:-configure}:8377: testing adding $cf_add_libdir to library-path ..." 1>&5
8379 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
8385 LIBS="$cf_cv_library_file_utf8 $LIBS"
8388 cf_ncuconfig_root=ncursesw
8390 echo "Looking for ${cf_ncuconfig_root}-config"
8392 if test -n "$ac_tool_prefix"; then
8393 for ac_prog in ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
8395 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
8396 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
8397 echo "$as_me:8397: checking for $ac_word" >&5
8398 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
8399 if test "${ac_cv_prog_NCURSES_CONFIG+set}" = set; then
8400 echo $ECHO_N "(cached) $ECHO_C" >&6
8402 if test -n "$NCURSES_CONFIG"; then
8403 ac_cv_prog_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test.
8405 ac_save_IFS=$IFS; IFS=$ac_path_separator
8407 for ac_dir in $ac_dummy; do
8409 test -z "$ac_dir" && ac_dir=.
8410 $as_executable_p "$ac_dir/$ac_word" || continue
8411 ac_cv_prog_NCURSES_CONFIG="$ac_tool_prefix$ac_prog"
8412 echo "$as_me:8412: found $ac_dir/$ac_word" >&5
8418 NCURSES_CONFIG=$ac_cv_prog_NCURSES_CONFIG
8419 if test -n "$NCURSES_CONFIG"; then
8420 echo "$as_me:8420: result: $NCURSES_CONFIG" >&5
8421 echo "${ECHO_T}$NCURSES_CONFIG" >&6
8423 echo "$as_me:8423: result: no" >&5
8424 echo "${ECHO_T}no" >&6
8427 test -n "$NCURSES_CONFIG" && break
8430 if test -z "$NCURSES_CONFIG"; then
8431 ac_ct_NCURSES_CONFIG=$NCURSES_CONFIG
8432 for ac_prog in ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
8434 # Extract the first word of "$ac_prog", so it can be a program name with args.
8435 set dummy $ac_prog; ac_word=$2
8436 echo "$as_me:8436: checking for $ac_word" >&5
8437 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
8438 if test "${ac_cv_prog_ac_ct_NCURSES_CONFIG+set}" = set; then
8439 echo $ECHO_N "(cached) $ECHO_C" >&6
8441 if test -n "$ac_ct_NCURSES_CONFIG"; then
8442 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_ct_NCURSES_CONFIG" # Let the user override the test.
8444 ac_save_IFS=$IFS; IFS=$ac_path_separator
8446 for ac_dir in $ac_dummy; do
8448 test -z "$ac_dir" && ac_dir=.
8449 $as_executable_p "$ac_dir/$ac_word" || continue
8450 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_prog"
8451 echo "$as_me:8451: found $ac_dir/$ac_word" >&5
8457 ac_ct_NCURSES_CONFIG=$ac_cv_prog_ac_ct_NCURSES_CONFIG
8458 if test -n "$ac_ct_NCURSES_CONFIG"; then
8459 echo "$as_me:8459: result: $ac_ct_NCURSES_CONFIG" >&5
8460 echo "${ECHO_T}$ac_ct_NCURSES_CONFIG" >&6
8462 echo "$as_me:8462: result: no" >&5
8463 echo "${ECHO_T}no" >&6
8466 test -n "$ac_ct_NCURSES_CONFIG" && break
8468 test -n "$ac_ct_NCURSES_CONFIG" || ac_ct_NCURSES_CONFIG="none"
8470 NCURSES_CONFIG=$ac_ct_NCURSES_CONFIG
8473 if test "$NCURSES_CONFIG" != none ; then
8475 CPPFLAGS="$CPPFLAGS `$NCURSES_CONFIG --cflags`"
8476 LIBS="`$NCURSES_CONFIG --libs` $LIBS"
8478 # even with config script, some packages use no-override for curses.h
8480 echo "$as_me:8480: checking if we have identified curses headers" >&5
8481 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
8482 if test "${cf_cv_ncurses_header+set}" = set; then
8483 echo $ECHO_N "(cached) $ECHO_C" >&6
8486 cf_cv_ncurses_header=none
8488 ncursesw/ncurses.h \
8493 cat >conftest.$ac_ext <<_ACEOF
8494 #line 8494 "configure"
8495 #include "confdefs.h"
8496 #include <${cf_header}>
8500 initscr(); tgoto("?", 0,0)
8505 rm -f conftest.$ac_objext
8506 if { (eval echo "$as_me:8506: \"$ac_compile\"") >&5
8507 (eval $ac_compile) 2>&5
8509 echo "$as_me:8509: \$? = $ac_status" >&5
8510 (exit $ac_status); } &&
8511 { ac_try='test -s conftest.$ac_objext'
8512 { (eval echo "$as_me:8512: \"$ac_try\"") >&5
8515 echo "$as_me:8515: \$? = $ac_status" >&5
8516 (exit $ac_status); }; }; then
8517 cf_cv_ncurses_header=$cf_header; break
8519 echo "$as_me: failed program was:" >&5
8520 cat conftest.$ac_ext >&5
8522 rm -f conftest.$ac_objext conftest.$ac_ext
8526 echo "$as_me:8526: result: $cf_cv_ncurses_header" >&5
8527 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
8529 if test "$cf_cv_ncurses_header" = none ; then
8530 { { echo "$as_me:8530: error: No curses header-files found" >&5
8531 echo "$as_me: error: No curses header-files found" >&2;}
8532 { (exit 1); exit 1; }; }
8535 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
8537 for ac_header in $cf_cv_ncurses_header
8539 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8540 echo "$as_me:8540: checking for $ac_header" >&5
8541 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8542 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8543 echo $ECHO_N "(cached) $ECHO_C" >&6
8545 cat >conftest.$ac_ext <<_ACEOF
8546 #line 8546 "configure"
8547 #include "confdefs.h"
8548 #include <$ac_header>
8550 if { (eval echo "$as_me:8550: \"$ac_cpp conftest.$ac_ext\"") >&5
8551 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8553 egrep -v '^ *\+' conftest.er1 >conftest.err
8555 cat conftest.err >&5
8556 echo "$as_me:8556: \$? = $ac_status" >&5
8557 (exit $ac_status); } >/dev/null; then
8558 if test -s conftest.err; then
8559 ac_cpp_err=$ac_c_preproc_warn_flag
8566 if test -z "$ac_cpp_err"; then
8567 eval "$as_ac_Header=yes"
8569 echo "$as_me: failed program was:" >&5
8570 cat conftest.$ac_ext >&5
8571 eval "$as_ac_Header=no"
8573 rm -f conftest.err conftest.$ac_ext
8575 echo "$as_me:8575: result: `eval echo '${'$as_ac_Header'}'`" >&5
8576 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8577 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8578 cat >>confdefs.h <<EOF
8579 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8585 cat >>confdefs.h <<\EOF
8589 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
8591 cat >>confdefs.h <<EOF
8592 #define $cf_nculib_ROOT 1
8595 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
8599 cf_ncuhdr_root=ncursesw
8601 test -n "$cf_cv_curses_dir" && \
8602 test "$cf_cv_curses_dir" != "no" && { \
8604 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
8605 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
8607 while test $cf_add_incdir != /usr/include
8609 if test -d $cf_add_incdir
8612 if test -n "$CFLAGS$CPPFLAGS" ; then
8613 # a loop is needed to ensure we can add subdirs of existing dirs
8614 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
8615 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
8616 cf_have_incdir=yes; break
8621 if test "$cf_have_incdir" = no ; then
8622 if test "$cf_add_incdir" = /usr/local/include ; then
8623 if test "$GCC" = yes
8625 cf_save_CPPFLAGS=$CPPFLAGS
8626 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8627 cat >conftest.$ac_ext <<_ACEOF
8628 #line 8628 "configure"
8629 #include "confdefs.h"
8639 rm -f conftest.$ac_objext
8640 if { (eval echo "$as_me:8640: \"$ac_compile\"") >&5
8641 (eval $ac_compile) 2>&5
8643 echo "$as_me:8643: \$? = $ac_status" >&5
8644 (exit $ac_status); } &&
8645 { ac_try='test -s conftest.$ac_objext'
8646 { (eval echo "$as_me:8646: \"$ac_try\"") >&5
8649 echo "$as_me:8649: \$? = $ac_status" >&5
8650 (exit $ac_status); }; }; then
8653 echo "$as_me: failed program was:" >&5
8654 cat conftest.$ac_ext >&5
8657 rm -f conftest.$ac_objext conftest.$ac_ext
8658 CPPFLAGS=$cf_save_CPPFLAGS
8663 if test "$cf_have_incdir" = no ; then
8664 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
8666 echo "${as_me:-configure}:8666: testing adding $cf_add_incdir to include-path ..." 1>&5
8668 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8670 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
8671 test "$cf_top_incdir" = "$cf_add_incdir" && break
8672 cf_add_incdir="$cf_top_incdir"
8683 echo "$as_me:8683: checking for $cf_ncuhdr_root header in include-path" >&5
8684 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
8685 if test "${cf_cv_ncurses_h+set}" = set; then
8686 echo $ECHO_N "(cached) $ECHO_C" >&6
8689 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
8690 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
8691 for cf_header in $cf_header_list
8694 cat >conftest.$ac_ext <<_ACEOF
8695 #line 8695 "configure"
8696 #include "confdefs.h"
8698 #define _XOPEN_SOURCE_EXTENDED
8699 #undef HAVE_LIBUTF8_H /* in case we used CF_UTF8_LIB */
8700 #define HAVE_LIBUTF8_H /* to force ncurses' header file to use cchar_t */
8702 #include <$cf_header>
8707 #ifdef NCURSES_VERSION
8713 printf("%s\n", NCURSES_VERSION);
8726 rm -f conftest.$ac_objext
8727 if { (eval echo "$as_me:8727: \"$ac_compile\"") >&5
8728 (eval $ac_compile) 2>&5
8730 echo "$as_me:8730: \$? = $ac_status" >&5
8731 (exit $ac_status); } &&
8732 { ac_try='test -s conftest.$ac_objext'
8733 { (eval echo "$as_me:8733: \"$ac_try\"") >&5
8736 echo "$as_me:8736: \$? = $ac_status" >&5
8737 (exit $ac_status); }; }; then
8738 cf_cv_ncurses_h=$cf_header
8741 echo "$as_me: failed program was:" >&5
8742 cat conftest.$ac_ext >&5
8745 rm -f conftest.$ac_objext conftest.$ac_ext
8747 test "$cf_cv_ncurses_h" != no && break
8751 echo "$as_me:8751: result: $cf_cv_ncurses_h" >&5
8752 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
8754 if test "$cf_cv_ncurses_h" != no ; then
8755 cf_cv_ncurses_header=$cf_cv_ncurses_h
8758 echo "$as_me:8758: checking for $cf_ncuhdr_root include-path" >&5
8759 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
8760 if test "${cf_cv_ncurses_h2+set}" = set; then
8761 echo $ECHO_N "(cached) $ECHO_C" >&6
8764 test -n "$verbose" && echo
8768 # collect the current set of include-directories from compiler flags
8769 cf_header_path_list=""
8770 if test -n "${CFLAGS}${CPPFLAGS}" ; then
8771 for cf_header_path in $CPPFLAGS $CFLAGS
8773 case $cf_header_path in #(vi
8775 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
8777 test "$cf_header_path" != "NONE" && \
8778 test -d "$cf_header_path" && \
8780 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
8781 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
8782 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
8783 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
8784 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
8785 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"
8788 cf_header_path_list="$cf_header_path_list $cf_search"
8794 # add the variations for the package we are looking for
8798 test "/usr" != "$prefix" && \
8800 (test $prefix = NONE || test "/usr" != "$prefix") && {
8801 test -n "$verbose" && echo " ... testing for include-directories under /usr"
8802 test -d /usr/include && cf_search="$cf_search /usr/include"
8803 test -d /usr/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/include/$cf_ncuhdr_root"
8804 test -d /usr/include/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/include/$cf_ncuhdr_root/include"
8805 test -d /usr/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/$cf_ncuhdr_root/include"
8806 test -d /usr/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
8809 test "$prefix" != "NONE" && \
8810 test -d "$prefix" && \
8812 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
8813 test -d $prefix/include && cf_search="$cf_search $prefix/include"
8814 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
8815 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
8816 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
8817 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
8820 test "/usr/local" != "$prefix" && \
8821 test -d "/usr/local" && \
8822 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
8823 test -n "$verbose" && echo " ... testing for include-directories under /usr/local"
8824 test -d /usr/local/include && cf_search="$cf_search /usr/local/include"
8825 test -d /usr/local/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/local/include/$cf_ncuhdr_root"
8826 test -d /usr/local/include/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/local/include/$cf_ncuhdr_root/include"
8827 test -d /usr/local/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/local/$cf_ncuhdr_root/include"
8828 test -d /usr/local/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/local/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
8831 test "/opt" != "$prefix" && \
8833 (test $prefix = NONE || test "/opt" != "$prefix") && {
8834 test -n "$verbose" && echo " ... testing for include-directories under /opt"
8835 test -d /opt/include && cf_search="$cf_search /opt/include"
8836 test -d /opt/include/$cf_ncuhdr_root && cf_search="$cf_search /opt/include/$cf_ncuhdr_root"
8837 test -d /opt/include/$cf_ncuhdr_root/include && cf_search="$cf_search /opt/include/$cf_ncuhdr_root/include"
8838 test -d /opt/$cf_ncuhdr_root/include && cf_search="$cf_search /opt/$cf_ncuhdr_root/include"
8839 test -d /opt/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /opt/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
8842 test "$HOME" != "$prefix" && \
8843 test -d "$HOME" && \
8844 (test $prefix = NONE || test "$HOME" != "$prefix") && {
8845 test -n "$verbose" && echo " ... testing for include-directories under $HOME"
8846 test -d $HOME/include && cf_search="$cf_search $HOME/include"
8847 test -d $HOME/include/$cf_ncuhdr_root && cf_search="$cf_search $HOME/include/$cf_ncuhdr_root"
8848 test -d $HOME/include/$cf_ncuhdr_root/include && cf_search="$cf_search $HOME/include/$cf_ncuhdr_root/include"
8849 test -d $HOME/$cf_ncuhdr_root/include && cf_search="$cf_search $HOME/$cf_ncuhdr_root/include"
8850 test -d $HOME/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $HOME/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
8853 test "$includedir" != NONE && \
8854 test "$includedir" != "/usr/include" && \
8855 test -d "$includedir" && {
8856 test -d $includedir && cf_search="$cf_search $includedir"
8857 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
8860 test "$oldincludedir" != NONE && \
8861 test "$oldincludedir" != "/usr/include" && \
8862 test -d "$oldincludedir" && {
8863 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
8864 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
8867 cf_search="$cf_search $cf_header_path_list"
8869 test -n "$verbose" && echo search path $cf_search
8870 cf_save2_CPPFLAGS="$CPPFLAGS"
8871 for cf_incdir in $cf_search
8874 if test -n "$cf_incdir" ; then
8875 for cf_add_incdir in $cf_incdir
8877 while test $cf_add_incdir != /usr/include
8879 if test -d $cf_add_incdir
8882 if test -n "$CFLAGS$CPPFLAGS" ; then
8883 # a loop is needed to ensure we can add subdirs of existing dirs
8884 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
8885 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
8886 cf_have_incdir=yes; break
8891 if test "$cf_have_incdir" = no ; then
8892 if test "$cf_add_incdir" = /usr/local/include ; then
8893 if test "$GCC" = yes
8895 cf_save_CPPFLAGS=$CPPFLAGS
8896 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8897 cat >conftest.$ac_ext <<_ACEOF
8898 #line 8898 "configure"
8899 #include "confdefs.h"
8909 rm -f conftest.$ac_objext
8910 if { (eval echo "$as_me:8910: \"$ac_compile\"") >&5
8911 (eval $ac_compile) 2>&5
8913 echo "$as_me:8913: \$? = $ac_status" >&5
8914 (exit $ac_status); } &&
8915 { ac_try='test -s conftest.$ac_objext'
8916 { (eval echo "$as_me:8916: \"$ac_try\"") >&5
8919 echo "$as_me:8919: \$? = $ac_status" >&5
8920 (exit $ac_status); }; }; then
8923 echo "$as_me: failed program was:" >&5
8924 cat conftest.$ac_ext >&5
8927 rm -f conftest.$ac_objext conftest.$ac_ext
8928 CPPFLAGS=$cf_save_CPPFLAGS
8933 if test "$cf_have_incdir" = no ; then
8934 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
8936 echo "${as_me:-configure}:8936: testing adding $cf_add_incdir to include-path ..." 1>&5
8938 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8940 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
8941 test "$cf_top_incdir" = "$cf_add_incdir" && break
8942 cf_add_incdir="$cf_top_incdir"
8956 cat >conftest.$ac_ext <<_ACEOF
8957 #line 8957 "configure"
8958 #include "confdefs.h"
8960 #include <$cf_header>
8965 #ifdef NCURSES_VERSION
8967 printf("%s\n", NCURSES_VERSION);
8980 rm -f conftest.$ac_objext
8981 if { (eval echo "$as_me:8981: \"$ac_compile\"") >&5
8982 (eval $ac_compile) 2>&5
8984 echo "$as_me:8984: \$? = $ac_status" >&5
8985 (exit $ac_status); } &&
8986 { ac_try='test -s conftest.$ac_objext'
8987 { (eval echo "$as_me:8987: \"$ac_try\"") >&5
8990 echo "$as_me:8990: \$? = $ac_status" >&5
8991 (exit $ac_status); }; }; then
8992 cf_cv_ncurses_h2=$cf_header
8995 echo "$as_me: failed program was:" >&5
8996 cat conftest.$ac_ext >&5
8999 rm -f conftest.$ac_objext conftest.$ac_ext
9001 if test "$cf_cv_ncurses_h2" != no ; then
9002 cf_cv_ncurses_h2=$cf_incdir/$cf_header
9003 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
9006 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
9008 CPPFLAGS="$cf_save2_CPPFLAGS"
9009 test "$cf_cv_ncurses_h2" != no && break
9011 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:9011: error: not found" >&5
9012 echo "$as_me: error: not found" >&2;}
9013 { (exit 1); exit 1; }; }
9016 echo "$as_me:9016: result: $cf_cv_ncurses_h2" >&5
9017 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
9019 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
9020 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
9021 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
9022 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
9025 if test -n "$cf_1st_incdir" ; then
9026 for cf_add_incdir in $cf_1st_incdir
9028 while test $cf_add_incdir != /usr/include
9030 if test -d $cf_add_incdir
9033 if test -n "$CFLAGS$CPPFLAGS" ; then
9034 # a loop is needed to ensure we can add subdirs of existing dirs
9035 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
9036 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
9037 cf_have_incdir=yes; break
9042 if test "$cf_have_incdir" = no ; then
9043 if test "$cf_add_incdir" = /usr/local/include ; then
9044 if test "$GCC" = yes
9046 cf_save_CPPFLAGS=$CPPFLAGS
9047 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
9048 cat >conftest.$ac_ext <<_ACEOF
9049 #line 9049 "configure"
9050 #include "confdefs.h"
9060 rm -f conftest.$ac_objext
9061 if { (eval echo "$as_me:9061: \"$ac_compile\"") >&5
9062 (eval $ac_compile) 2>&5
9064 echo "$as_me:9064: \$? = $ac_status" >&5
9065 (exit $ac_status); } &&
9066 { ac_try='test -s conftest.$ac_objext'
9067 { (eval echo "$as_me:9067: \"$ac_try\"") >&5
9070 echo "$as_me:9070: \$? = $ac_status" >&5
9071 (exit $ac_status); }; }; then
9074 echo "$as_me: failed program was:" >&5
9075 cat conftest.$ac_ext >&5
9078 rm -f conftest.$ac_objext conftest.$ac_ext
9079 CPPFLAGS=$cf_save_CPPFLAGS
9084 if test "$cf_have_incdir" = no ; then
9085 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
9087 echo "${as_me:-configure}:9087: testing adding $cf_add_incdir to include-path ..." 1>&5
9089 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
9091 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
9092 test "$cf_top_incdir" = "$cf_add_incdir" && break
9093 cf_add_incdir="$cf_top_incdir"
9104 # Set definitions to allow ifdef'ing for ncurses.h
9106 case $cf_cv_ncurses_header in # (vi
9108 cat >>confdefs.h <<\EOF
9109 #define HAVE_NCURSES_H 1
9115 case $cf_cv_ncurses_header in # (vi
9116 ncurses/curses.h|ncurses/ncurses.h)
9117 cat >>confdefs.h <<\EOF
9118 #define HAVE_NCURSES_NCURSES_H 1
9122 ncursesw/curses.h|ncursesw/ncurses.h)
9123 cat >>confdefs.h <<\EOF
9124 #define HAVE_NCURSESW_NCURSES_H 1
9130 echo "$as_me:9130: checking for terminfo header" >&5
9131 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
9132 if test "${cf_cv_term_header+set}" = set; then
9133 echo $ECHO_N "(cached) $ECHO_C" >&6
9136 case ${cf_cv_ncurses_header} in #(vi
9137 */ncurses.h|*/ncursesw.h) #(vi
9138 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
9141 cf_term_header=term.h
9145 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
9147 cat >conftest.$ac_ext <<_ACEOF
9148 #line 9148 "configure"
9149 #include "confdefs.h"
9151 #include <${cf_cv_ncurses_header:-curses.h}>
9157 int x = auto_left_margin
9162 rm -f conftest.$ac_objext
9163 if { (eval echo "$as_me:9163: \"$ac_compile\"") >&5
9164 (eval $ac_compile) 2>&5
9166 echo "$as_me:9166: \$? = $ac_status" >&5
9167 (exit $ac_status); } &&
9168 { ac_try='test -s conftest.$ac_objext'
9169 { (eval echo "$as_me:9169: \"$ac_try\"") >&5
9172 echo "$as_me:9172: \$? = $ac_status" >&5
9173 (exit $ac_status); }; }; then
9175 cf_cv_term_header="$cf_test"
9177 echo "$as_me: failed program was:" >&5
9178 cat conftest.$ac_ext >&5
9180 cf_cv_term_header=unknown
9183 rm -f conftest.$ac_objext conftest.$ac_ext
9184 test "$cf_cv_term_header" != unknown && break
9188 echo "$as_me:9188: result: $cf_cv_term_header" >&5
9189 echo "${ECHO_T}$cf_cv_term_header" >&6
9191 # Set definitions to allow ifdef'ing to accommodate subdirectories
9193 case $cf_cv_term_header in # (vi
9195 cat >>confdefs.h <<\EOF
9196 #define HAVE_TERM_H 1
9202 case $cf_cv_term_header in # (vi
9203 ncurses/term.h) #(vi
9204 cat >>confdefs.h <<\EOF
9205 #define HAVE_NCURSES_TERM_H 1
9210 cat >>confdefs.h <<\EOF
9211 #define HAVE_NCURSESW_TERM_H 1
9217 # some applications need this, but should check for NCURSES_VERSION
9218 cat >>confdefs.h <<\EOF
9222 echo "$as_me:9222: checking for ncurses version" >&5
9223 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
9224 if test "${cf_cv_ncurses_version+set}" = set; then
9225 echo $ECHO_N "(cached) $ECHO_C" >&6
9228 cf_cv_ncurses_version=no
9231 if test "$cross_compiling" = yes; then
9233 # This will not work if the preprocessor splits the line after the
9234 # Autoconf token. The 'unproto' program does that.
9235 cat > conftest.$ac_ext <<EOF
9236 #include <${cf_cv_ncurses_header:-curses.h}>
9238 #ifdef NCURSES_VERSION
9239 Autoconf NCURSES_VERSION
9247 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
9248 { (eval echo "$as_me:9248: \"$cf_try\"") >&5
9251 echo "$as_me:9251: \$? = $ac_status" >&5
9252 (exit $ac_status); }
9253 if test -f conftest.out ; then
9254 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
9255 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
9260 cat >conftest.$ac_ext <<_ACEOF
9261 #line 9261 "configure"
9262 #include "confdefs.h"
9264 #include <${cf_cv_ncurses_header:-curses.h}>
9268 FILE *fp = fopen("$cf_tempfile", "w");
9269 #ifdef NCURSES_VERSION
9270 # ifdef NCURSES_VERSION_PATCH
9271 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
9273 fprintf(fp, "%s\n", NCURSES_VERSION);
9277 fprintf(fp, "old\n");
9282 ${cf_cv_main_return:-return}(0);
9285 rm -f conftest$ac_exeext
9286 if { (eval echo "$as_me:9286: \"$ac_link\"") >&5
9287 (eval $ac_link) 2>&5
9289 echo "$as_me:9289: \$? = $ac_status" >&5
9290 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
9291 { (eval echo "$as_me:9291: \"$ac_try\"") >&5
9294 echo "$as_me:9294: \$? = $ac_status" >&5
9295 (exit $ac_status); }; }; then
9297 cf_cv_ncurses_version=`cat $cf_tempfile`
9299 echo "$as_me: program exited with status $ac_status" >&5
9300 echo "$as_me: failed program was:" >&5
9301 cat conftest.$ac_ext >&5
9303 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
9308 echo "$as_me:9308: result: $cf_cv_ncurses_version" >&5
9309 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
9310 test "$cf_cv_ncurses_version" = no || cat >>confdefs.h <<\EOF
9314 cf_nculib_root=ncursesw
9315 # This works, except for the special case where we find gpm, but
9316 # ncurses is in a nonstandard location via $LIBS, and we really want
9319 cf_ncurses_SAVE="$LIBS"
9320 echo "$as_me:9320: checking for Gpm_Open in -lgpm" >&5
9321 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
9322 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
9323 echo $ECHO_N "(cached) $ECHO_C" >&6
9325 ac_check_lib_save_LIBS=$LIBS
9327 cat >conftest.$ac_ext <<_ACEOF
9328 #line 9328 "configure"
9329 #include "confdefs.h"
9331 /* Override any gcc2 internal prototype to avoid an error. */
9335 /* We use char because int might match the return type of a gcc2
9336 builtin and then its argument prototype would still apply. */
9346 rm -f conftest.$ac_objext conftest$ac_exeext
9347 if { (eval echo "$as_me:9347: \"$ac_link\"") >&5
9348 (eval $ac_link) 2>&5
9350 echo "$as_me:9350: \$? = $ac_status" >&5
9351 (exit $ac_status); } &&
9352 { ac_try='test -s conftest$ac_exeext'
9353 { (eval echo "$as_me:9353: \"$ac_try\"") >&5
9356 echo "$as_me:9356: \$? = $ac_status" >&5
9357 (exit $ac_status); }; }; then
9358 ac_cv_lib_gpm_Gpm_Open=yes
9360 echo "$as_me: failed program was:" >&5
9361 cat conftest.$ac_ext >&5
9362 ac_cv_lib_gpm_Gpm_Open=no
9364 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9365 LIBS=$ac_check_lib_save_LIBS
9367 echo "$as_me:9367: result: $ac_cv_lib_gpm_Gpm_Open" >&5
9368 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
9369 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
9370 echo "$as_me:9370: checking for initscr in -lgpm" >&5
9371 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
9372 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
9373 echo $ECHO_N "(cached) $ECHO_C" >&6
9375 ac_check_lib_save_LIBS=$LIBS
9377 cat >conftest.$ac_ext <<_ACEOF
9378 #line 9378 "configure"
9379 #include "confdefs.h"
9381 /* Override any gcc2 internal prototype to avoid an error. */
9385 /* We use char because int might match the return type of a gcc2
9386 builtin and then its argument prototype would still apply. */
9396 rm -f conftest.$ac_objext conftest$ac_exeext
9397 if { (eval echo "$as_me:9397: \"$ac_link\"") >&5
9398 (eval $ac_link) 2>&5
9400 echo "$as_me:9400: \$? = $ac_status" >&5
9401 (exit $ac_status); } &&
9402 { ac_try='test -s conftest$ac_exeext'
9403 { (eval echo "$as_me:9403: \"$ac_try\"") >&5
9406 echo "$as_me:9406: \$? = $ac_status" >&5
9407 (exit $ac_status); }; }; then
9408 ac_cv_lib_gpm_initscr=yes
9410 echo "$as_me: failed program was:" >&5
9411 cat conftest.$ac_ext >&5
9412 ac_cv_lib_gpm_initscr=no
9414 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9415 LIBS=$ac_check_lib_save_LIBS
9417 echo "$as_me:9417: result: $ac_cv_lib_gpm_initscr" >&5
9418 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
9419 if test $ac_cv_lib_gpm_initscr = yes; then
9420 LIBS="$cf_ncurses_SAVE"
9422 cf_ncurses_LIBS="-lgpm"
9427 case $host_os in #(vi
9429 # This is only necessary if you are linking against an obsolete
9430 # version of ncurses (but it should do no harm, since it's static).
9431 if test "$cf_nculib_root" = ncurses ; then
9432 echo "$as_me:9432: checking for tgoto in -lmytinfo" >&5
9433 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
9434 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
9435 echo $ECHO_N "(cached) $ECHO_C" >&6
9437 ac_check_lib_save_LIBS=$LIBS
9438 LIBS="-lmytinfo $LIBS"
9439 cat >conftest.$ac_ext <<_ACEOF
9440 #line 9440 "configure"
9441 #include "confdefs.h"
9443 /* Override any gcc2 internal prototype to avoid an error. */
9447 /* We use char because int might match the return type of a gcc2
9448 builtin and then its argument prototype would still apply. */
9458 rm -f conftest.$ac_objext conftest$ac_exeext
9459 if { (eval echo "$as_me:9459: \"$ac_link\"") >&5
9460 (eval $ac_link) 2>&5
9462 echo "$as_me:9462: \$? = $ac_status" >&5
9463 (exit $ac_status); } &&
9464 { ac_try='test -s conftest$ac_exeext'
9465 { (eval echo "$as_me:9465: \"$ac_try\"") >&5
9468 echo "$as_me:9468: \$? = $ac_status" >&5
9469 (exit $ac_status); }; }; then
9470 ac_cv_lib_mytinfo_tgoto=yes
9472 echo "$as_me: failed program was:" >&5
9473 cat conftest.$ac_ext >&5
9474 ac_cv_lib_mytinfo_tgoto=no
9476 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9477 LIBS=$ac_check_lib_save_LIBS
9479 echo "$as_me:9479: result: $ac_cv_lib_mytinfo_tgoto" >&5
9480 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
9481 if test $ac_cv_lib_mytinfo_tgoto = yes; then
9482 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
9489 LIBS="$cf_ncurses_LIBS $LIBS"
9491 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
9493 LIBS="-l$cf_nculib_root $LIBS"
9496 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
9498 echo "$as_me:9498: checking for initscr" >&5
9499 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
9500 if test "${ac_cv_func_initscr+set}" = set; then
9501 echo $ECHO_N "(cached) $ECHO_C" >&6
9503 cat >conftest.$ac_ext <<_ACEOF
9504 #line 9504 "configure"
9505 #include "confdefs.h"
9506 /* System header to define __stub macros and hopefully few prototypes,
9507 which can conflict with char initscr (); below. */
9509 /* Override any gcc2 internal prototype to avoid an error. */
9513 /* We use char because int might match the return type of a gcc2
9514 builtin and then its argument prototype would still apply. */
9521 /* The GNU C library defines this for functions which it implements
9522 to always fail with ENOSYS. Some functions are actually named
9523 something starting with __ and the normal name is an alias. */
9524 #if defined (__stub_initscr) || defined (__stub___initscr)
9534 rm -f conftest.$ac_objext conftest$ac_exeext
9535 if { (eval echo "$as_me:9535: \"$ac_link\"") >&5
9536 (eval $ac_link) 2>&5
9538 echo "$as_me:9538: \$? = $ac_status" >&5
9539 (exit $ac_status); } &&
9540 { ac_try='test -s conftest$ac_exeext'
9541 { (eval echo "$as_me:9541: \"$ac_try\"") >&5
9544 echo "$as_me:9544: \$? = $ac_status" >&5
9545 (exit $ac_status); }; }; then
9546 ac_cv_func_initscr=yes
9548 echo "$as_me: failed program was:" >&5
9549 cat conftest.$ac_ext >&5
9550 ac_cv_func_initscr=no
9552 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9554 echo "$as_me:9554: result: $ac_cv_func_initscr" >&5
9555 echo "${ECHO_T}$ac_cv_func_initscr" >&6
9556 if test $ac_cv_func_initscr = yes; then
9557 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
9560 cf_save_LIBS="$LIBS"
9561 echo "$as_me:9561: checking for initscr in -l$cf_nculib_root" >&5
9562 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
9563 LIBS="-l$cf_nculib_root $LIBS"
9564 cat >conftest.$ac_ext <<_ACEOF
9565 #line 9565 "configure"
9566 #include "confdefs.h"
9567 #include <${cf_cv_ncurses_header:-curses.h}>
9576 rm -f conftest.$ac_objext conftest$ac_exeext
9577 if { (eval echo "$as_me:9577: \"$ac_link\"") >&5
9578 (eval $ac_link) 2>&5
9580 echo "$as_me:9580: \$? = $ac_status" >&5
9581 (exit $ac_status); } &&
9582 { ac_try='test -s conftest$ac_exeext'
9583 { (eval echo "$as_me:9583: \"$ac_try\"") >&5
9586 echo "$as_me:9586: \$? = $ac_status" >&5
9587 (exit $ac_status); }; }; then
9588 echo "$as_me:9588: result: yes" >&5
9589 echo "${ECHO_T}yes" >&6
9590 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
9593 echo "$as_me: failed program was:" >&5
9594 cat conftest.$ac_ext >&5
9595 echo "$as_me:9595: result: no" >&5
9596 echo "${ECHO_T}no" >&6
9599 cf_library_path_list=""
9600 if test -n "${LDFLAGS}${LIBS}" ; then
9601 for cf_library_path in $LDFLAGS $LIBS
9603 case $cf_library_path in #(vi
9605 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
9607 test "$cf_library_path" != "NONE" && \
9608 test -d "$cf_library_path" && \
9610 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
9611 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
9612 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
9613 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
9614 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
9615 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"
9618 cf_library_path_list="$cf_library_path_list $cf_search"
9626 test "/usr" != "$prefix" && \
9628 (test $prefix = NONE || test "/usr" != "$prefix") && {
9629 test -n "$verbose" && echo " ... testing for lib-directories under /usr"
9630 test -d /usr/lib && cf_search="$cf_search /usr/lib"
9631 test -d /usr/lib/$cf_nculib_root && cf_search="$cf_search /usr/lib/$cf_nculib_root"
9632 test -d /usr/lib/$cf_nculib_root/lib && cf_search="$cf_search /usr/lib/$cf_nculib_root/lib"
9633 test -d /usr/$cf_nculib_root/lib && cf_search="$cf_search /usr/$cf_nculib_root/lib"
9634 test -d /usr/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /usr/$cf_nculib_root/lib/$cf_nculib_root"
9637 test "$prefix" != "NONE" && \
9638 test -d "$prefix" && \
9640 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
9641 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
9642 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
9643 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
9644 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
9645 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
9648 test "/usr/local" != "$prefix" && \
9649 test -d "/usr/local" && \
9650 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
9651 test -n "$verbose" && echo " ... testing for lib-directories under /usr/local"
9652 test -d /usr/local/lib && cf_search="$cf_search /usr/local/lib"
9653 test -d /usr/local/lib/$cf_nculib_root && cf_search="$cf_search /usr/local/lib/$cf_nculib_root"
9654 test -d /usr/local/lib/$cf_nculib_root/lib && cf_search="$cf_search /usr/local/lib/$cf_nculib_root/lib"
9655 test -d /usr/local/$cf_nculib_root/lib && cf_search="$cf_search /usr/local/$cf_nculib_root/lib"
9656 test -d /usr/local/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /usr/local/$cf_nculib_root/lib/$cf_nculib_root"
9659 test "/opt" != "$prefix" && \
9661 (test $prefix = NONE || test "/opt" != "$prefix") && {
9662 test -n "$verbose" && echo " ... testing for lib-directories under /opt"
9663 test -d /opt/lib && cf_search="$cf_search /opt/lib"
9664 test -d /opt/lib/$cf_nculib_root && cf_search="$cf_search /opt/lib/$cf_nculib_root"
9665 test -d /opt/lib/$cf_nculib_root/lib && cf_search="$cf_search /opt/lib/$cf_nculib_root/lib"
9666 test -d /opt/$cf_nculib_root/lib && cf_search="$cf_search /opt/$cf_nculib_root/lib"
9667 test -d /opt/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /opt/$cf_nculib_root/lib/$cf_nculib_root"
9670 test "$HOME" != "$prefix" && \
9671 test -d "$HOME" && \
9672 (test $prefix = NONE || test "$HOME" != "$prefix") && {
9673 test -n "$verbose" && echo " ... testing for lib-directories under $HOME"
9674 test -d $HOME/lib && cf_search="$cf_search $HOME/lib"
9675 test -d $HOME/lib/$cf_nculib_root && cf_search="$cf_search $HOME/lib/$cf_nculib_root"
9676 test -d $HOME/lib/$cf_nculib_root/lib && cf_search="$cf_search $HOME/lib/$cf_nculib_root/lib"
9677 test -d $HOME/$cf_nculib_root/lib && cf_search="$cf_search $HOME/$cf_nculib_root/lib"
9678 test -d $HOME/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $HOME/$cf_nculib_root/lib/$cf_nculib_root"
9681 cf_search="$cf_library_path_list $cf_search"
9683 for cf_libdir in $cf_search
9685 echo "$as_me:9685: checking for -l$cf_nculib_root in $cf_libdir" >&5
9686 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
9687 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
9688 cat >conftest.$ac_ext <<_ACEOF
9689 #line 9689 "configure"
9690 #include "confdefs.h"
9691 #include <${cf_cv_ncurses_header:-curses.h}>
9700 rm -f conftest.$ac_objext conftest$ac_exeext
9701 if { (eval echo "$as_me:9701: \"$ac_link\"") >&5
9702 (eval $ac_link) 2>&5
9704 echo "$as_me:9704: \$? = $ac_status" >&5
9705 (exit $ac_status); } &&
9706 { ac_try='test -s conftest$ac_exeext'
9707 { (eval echo "$as_me:9707: \"$ac_try\"") >&5
9710 echo "$as_me:9710: \$? = $ac_status" >&5
9711 (exit $ac_status); }; }; then
9712 echo "$as_me:9712: result: yes" >&5
9713 echo "${ECHO_T}yes" >&6
9714 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
9717 echo "$as_me: failed program was:" >&5
9718 cat conftest.$ac_ext >&5
9719 echo "$as_me:9719: result: no" >&5
9720 echo "${ECHO_T}no" >&6
9721 LIBS="$cf_save_LIBS"
9723 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9727 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9731 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
9733 if test $cf_found_library = no ; then
9734 { { echo "$as_me:9734: error: Cannot link $cf_nculib_root library" >&5
9735 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
9736 { (exit 1); exit 1; }; }
9741 if test -n "$cf_ncurses_LIBS" ; then
9742 echo "$as_me:9742: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
9743 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
9744 cf_ncurses_SAVE="$LIBS"
9745 for p in $cf_ncurses_LIBS ; do
9746 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
9747 if test "$q" != "$LIBS" ; then
9751 cat >conftest.$ac_ext <<_ACEOF
9752 #line 9752 "configure"
9753 #include "confdefs.h"
9754 #include <${cf_cv_ncurses_header:-curses.h}>
9758 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
9763 rm -f conftest.$ac_objext conftest$ac_exeext
9764 if { (eval echo "$as_me:9764: \"$ac_link\"") >&5
9765 (eval $ac_link) 2>&5
9767 echo "$as_me:9767: \$? = $ac_status" >&5
9768 (exit $ac_status); } &&
9769 { ac_try='test -s conftest$ac_exeext'
9770 { (eval echo "$as_me:9770: \"$ac_try\"") >&5
9773 echo "$as_me:9773: \$? = $ac_status" >&5
9774 (exit $ac_status); }; }; then
9775 echo "$as_me:9775: result: yes" >&5
9776 echo "${ECHO_T}yes" >&6
9778 echo "$as_me: failed program was:" >&5
9779 cat conftest.$ac_ext >&5
9780 echo "$as_me:9780: result: no" >&5
9781 echo "${ECHO_T}no" >&6
9782 LIBS="$cf_ncurses_SAVE"
9784 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9787 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
9789 cat >>confdefs.h <<EOF
9790 #define $cf_nculib_ROOT 1
9798 echo "$as_me:9798: checking if you want to use pkg-config" >&5
9799 echo $ECHO_N "checking if you want to use pkg-config... $ECHO_C" >&6
9801 # Check whether --with-pkg-config or --without-pkg-config was given.
9802 if test "${with_pkg_config+set}" = set; then
9803 withval="$with_pkg_config"
9804 cf_pkg_config=$withval
9808 echo "$as_me:9808: result: $cf_pkg_config" >&5
9809 echo "${ECHO_T}$cf_pkg_config" >&6
9811 case $cf_pkg_config in #(vi
9817 if test -n "$ac_tool_prefix"; then
9818 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
9819 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
9820 echo "$as_me:9820: checking for $ac_word" >&5
9821 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
9822 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then
9823 echo $ECHO_N "(cached) $ECHO_C" >&6
9827 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
9830 ac_save_IFS=$IFS; IFS=$ac_path_separator
9832 for ac_dir in $ac_dummy; do
9834 test -z "$ac_dir" && ac_dir=.
9835 if $as_executable_p "$ac_dir/$ac_word"; then
9836 ac_cv_path_PKG_CONFIG="$ac_dir/$ac_word"
9837 echo "$as_me:9837: found $ac_dir/$ac_word" >&5
9845 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
9847 if test -n "$PKG_CONFIG"; then
9848 echo "$as_me:9848: result: $PKG_CONFIG" >&5
9849 echo "${ECHO_T}$PKG_CONFIG" >&6
9851 echo "$as_me:9851: result: no" >&5
9852 echo "${ECHO_T}no" >&6
9856 if test -z "$ac_cv_path_PKG_CONFIG"; then
9857 ac_pt_PKG_CONFIG=$PKG_CONFIG
9858 # Extract the first word of "pkg-config", so it can be a program name with args.
9859 set dummy pkg-config; ac_word=$2
9860 echo "$as_me:9860: checking for $ac_word" >&5
9861 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
9862 if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then
9863 echo $ECHO_N "(cached) $ECHO_C" >&6
9865 case $ac_pt_PKG_CONFIG in
9867 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
9870 ac_save_IFS=$IFS; IFS=$ac_path_separator
9872 for ac_dir in $ac_dummy; do
9874 test -z "$ac_dir" && ac_dir=.
9875 if $as_executable_p "$ac_dir/$ac_word"; then
9876 ac_cv_path_ac_pt_PKG_CONFIG="$ac_dir/$ac_word"
9877 echo "$as_me:9877: found $ac_dir/$ac_word" >&5
9882 test -z "$ac_cv_path_ac_pt_PKG_CONFIG" && ac_cv_path_ac_pt_PKG_CONFIG="none"
9886 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
9888 if test -n "$ac_pt_PKG_CONFIG"; then
9889 echo "$as_me:9889: result: $ac_pt_PKG_CONFIG" >&5
9890 echo "${ECHO_T}$ac_pt_PKG_CONFIG" >&6
9892 echo "$as_me:9892: result: no" >&5
9893 echo "${ECHO_T}no" >&6
9896 PKG_CONFIG=$ac_pt_PKG_CONFIG
9898 PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
9907 test -z "$PKG_CONFIG" && PKG_CONFIG=none
9908 if test "$PKG_CONFIG" != none ; then
9910 if test "x$prefix" != xNONE; then
9911 cf_path_syntax="$prefix"
9913 cf_path_syntax="$ac_default_prefix"
9916 case ".$PKG_CONFIG" in #(vi
9917 .\$\(*\)*|.\'*\'*) #(vi
9921 .[a-zA-Z]:[\\/]*) #(vi OS/2 EMX
9924 eval PKG_CONFIG="$PKG_CONFIG"
9925 case ".$PKG_CONFIG" in #(vi
9927 PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
9932 PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
9935 { { echo "$as_me:9935: error: expected a pathname, not \"$PKG_CONFIG\"" >&5
9936 echo "$as_me: error: expected a pathname, not \"$PKG_CONFIG\"" >&2;}
9937 { (exit 1); exit 1; }; }
9943 echo "$as_me:9943: checking for X" >&5
9944 echo $ECHO_N "checking for X... $ECHO_C" >&6
9946 # Check whether --with-x or --without-x was given.
9947 if test "${with_x+set}" = set; then
9951 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
9952 if test "x$with_x" = xno; then
9953 # The user explicitly disabled X.
9956 if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
9957 # Both variables are already set.
9960 if test "${ac_cv_have_x+set}" = set; then
9961 echo $ECHO_N "(cached) $ECHO_C" >&6
9963 # One or both of the vars are not set, and there is no cached value.
9964 ac_x_includes=no ac_x_libraries=no
9966 if mkdir conftest.dir; then
9968 # Make sure to not put "make" in the Imakefile rules, since we grep it out.
9969 cat >Imakefile <<'EOF'
9971 @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
9973 if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
9974 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
9975 eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
9976 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
9977 for ac_extension in a so sl dylib dll; do
9978 if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
9979 test -f $ac_im_libdir/libX11.$ac_extension; then
9980 ac_im_usrlibdir=$ac_im_libdir; break
9983 # Screen out bogus values from the imake configuration. They are
9984 # bogus both because they are the default anyway, and because
9985 # using them would break gcc on systems where it needs fixed includes.
9986 case $ac_im_incroot in
9988 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
9990 case $ac_im_usrlibdir in
9992 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
9999 # Standard set of common directories for X headers.
10000 # Check X11 before X11Rn because it is often a symlink to the current release.
10012 /usr/local/X11/include
10013 /usr/local/X11R6/include
10014 /usr/local/X11R5/include
10015 /usr/local/X11R4/include
10017 /usr/local/include/X11
10018 /usr/local/include/X11R6
10019 /usr/local/include/X11R5
10020 /usr/local/include/X11R4
10024 /usr/XFree86/include/X11
10028 /usr/unsupported/include
10029 /usr/athena/include
10030 /usr/local/x11r5/include
10031 /usr/lpp/Xamples/include
10033 /usr/openwin/include
10034 /usr/openwin/share/include'
10036 if test "$ac_x_includes" = no; then
10037 # Guess where to find include files, by looking for Intrinsic.h.
10038 # First, try using that file with no special directory specified.
10039 cat >conftest.$ac_ext <<_ACEOF
10040 #line 10040 "configure"
10041 #include "confdefs.h"
10042 #include <X11/Intrinsic.h>
10044 if { (eval echo "$as_me:10044: \"$ac_cpp conftest.$ac_ext\"") >&5
10045 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10047 egrep -v '^ *\+' conftest.er1 >conftest.err
10049 cat conftest.err >&5
10050 echo "$as_me:10050: \$? = $ac_status" >&5
10051 (exit $ac_status); } >/dev/null; then
10052 if test -s conftest.err; then
10053 ac_cpp_err=$ac_c_preproc_warn_flag
10060 if test -z "$ac_cpp_err"; then
10061 # We can compile using X headers with no special include directory.
10064 echo "$as_me: failed program was:" >&5
10065 cat conftest.$ac_ext >&5
10066 for ac_dir in $ac_x_header_dirs; do
10067 if test -r "$ac_dir/X11/Intrinsic.h"; then
10068 ac_x_includes=$ac_dir
10073 rm -f conftest.err conftest.$ac_ext
10074 fi # $ac_x_includes = no
10076 if test "$ac_x_libraries" = no; then
10077 # Check for the libraries.
10078 # See if we find them without any special options.
10079 # Don't add to $LIBS permanently.
10082 cat >conftest.$ac_ext <<_ACEOF
10083 #line 10083 "configure"
10084 #include "confdefs.h"
10085 #include <X11/Intrinsic.h>
10094 rm -f conftest.$ac_objext conftest$ac_exeext
10095 if { (eval echo "$as_me:10095: \"$ac_link\"") >&5
10096 (eval $ac_link) 2>&5
10098 echo "$as_me:10098: \$? = $ac_status" >&5
10099 (exit $ac_status); } &&
10100 { ac_try='test -s conftest$ac_exeext'
10101 { (eval echo "$as_me:10101: \"$ac_try\"") >&5
10102 (eval $ac_try) 2>&5
10104 echo "$as_me:10104: \$? = $ac_status" >&5
10105 (exit $ac_status); }; }; then
10107 # We can link X programs with no special library path.
10110 echo "$as_me: failed program was:" >&5
10111 cat conftest.$ac_ext >&5
10113 for ac_dir in `echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
10115 # Don't even attempt the hair of trying to link an X program!
10116 for ac_extension in a so sl dylib dll; do
10117 if test -r $ac_dir/libXt.$ac_extension; then
10118 ac_x_libraries=$ac_dir
10124 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10125 fi # $ac_x_libraries = no
10127 if test "$ac_x_includes" = no || test "$ac_x_libraries" = no; then
10128 # Didn't find X anywhere. Cache the known absence of X.
10129 ac_cv_have_x="have_x=no"
10131 # Record where we found X for the cache.
10132 ac_cv_have_x="have_x=yes \
10133 ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
10138 eval "$ac_cv_have_x"
10141 if test "$have_x" != yes; then
10142 echo "$as_me:10142: result: $have_x" >&5
10143 echo "${ECHO_T}$have_x" >&6
10146 # If each of the values was on the command line, it overrides each guess.
10147 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
10148 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
10149 # Update the cache value to reflect the command line values.
10150 ac_cv_have_x="have_x=yes \
10151 ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
10152 echo "$as_me:10152: result: libraries $x_libraries, headers $x_includes" >&5
10153 echo "${ECHO_T}libraries $x_libraries, headers $x_includes" >&6
10156 if test "$no_x" = yes; then
10157 # Not all programs may use this symbol, but it does not hurt to define it.
10159 cat >>confdefs.h <<\EOF
10160 #define X_DISPLAY_MISSING 1
10163 X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS=
10165 if test -n "$x_includes"; then
10166 X_CFLAGS="$X_CFLAGS -I$x_includes"
10169 # It would also be nice to do this for all -L options, not just this one.
10170 if test -n "$x_libraries"; then
10171 X_LIBS="$X_LIBS -L$x_libraries"
10172 # For Solaris; some versions of Sun CC require a space after -R and
10173 # others require no space. Words are not sufficient . . . .
10174 case `(uname -sr) 2>/dev/null` in
10176 echo "$as_me:10176: checking whether -R must be followed by a space" >&5
10177 echo $ECHO_N "checking whether -R must be followed by a space... $ECHO_C" >&6
10178 ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries"
10179 cat >conftest.$ac_ext <<_ACEOF
10180 #line 10180 "configure"
10181 #include "confdefs.h"
10191 rm -f conftest.$ac_objext conftest$ac_exeext
10192 if { (eval echo "$as_me:10192: \"$ac_link\"") >&5
10193 (eval $ac_link) 2>&5
10195 echo "$as_me:10195: \$? = $ac_status" >&5
10196 (exit $ac_status); } &&
10197 { ac_try='test -s conftest$ac_exeext'
10198 { (eval echo "$as_me:10198: \"$ac_try\"") >&5
10199 (eval $ac_try) 2>&5
10201 echo "$as_me:10201: \$? = $ac_status" >&5
10202 (exit $ac_status); }; }; then
10205 echo "$as_me: failed program was:" >&5
10206 cat conftest.$ac_ext >&5
10209 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10210 if test $ac_R_nospace = yes; then
10211 echo "$as_me:10211: result: no" >&5
10212 echo "${ECHO_T}no" >&6
10213 X_LIBS="$X_LIBS -R$x_libraries"
10215 LIBS="$ac_xsave_LIBS -R $x_libraries"
10216 cat >conftest.$ac_ext <<_ACEOF
10217 #line 10217 "configure"
10218 #include "confdefs.h"
10228 rm -f conftest.$ac_objext conftest$ac_exeext
10229 if { (eval echo "$as_me:10229: \"$ac_link\"") >&5
10230 (eval $ac_link) 2>&5
10232 echo "$as_me:10232: \$? = $ac_status" >&5
10233 (exit $ac_status); } &&
10234 { ac_try='test -s conftest$ac_exeext'
10235 { (eval echo "$as_me:10235: \"$ac_try\"") >&5
10236 (eval $ac_try) 2>&5
10238 echo "$as_me:10238: \$? = $ac_status" >&5
10239 (exit $ac_status); }; }; then
10242 echo "$as_me: failed program was:" >&5
10243 cat conftest.$ac_ext >&5
10246 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10247 if test $ac_R_space = yes; then
10248 echo "$as_me:10248: result: yes" >&5
10249 echo "${ECHO_T}yes" >&6
10250 X_LIBS="$X_LIBS -R $x_libraries"
10252 echo "$as_me:10252: result: neither works" >&5
10253 echo "${ECHO_T}neither works" >&6
10256 LIBS=$ac_xsave_LIBS
10260 # Check for system-dependent libraries X programs must link with.
10261 # Do this before checking for the system-independent R6 libraries
10262 # (-lICE), since we may need -lsocket or whatever for X linking.
10264 if test "$ISC" = yes; then
10265 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
10267 # Martyn Johnson says this is needed for Ultrix, if the X
10268 # libraries were built with DECnet support. And Karl Berry says
10269 # the Alpha needs dnet_stub (dnet does not exist).
10270 ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11"
10271 cat >conftest.$ac_ext <<_ACEOF
10272 #line 10272 "configure"
10273 #include "confdefs.h"
10275 /* Override any gcc2 internal prototype to avoid an error. */
10279 /* We use char because int might match the return type of a gcc2
10280 builtin and then its argument prototype would still apply. */
10281 char XOpenDisplay ();
10290 rm -f conftest.$ac_objext conftest$ac_exeext
10291 if { (eval echo "$as_me:10291: \"$ac_link\"") >&5
10292 (eval $ac_link) 2>&5
10294 echo "$as_me:10294: \$? = $ac_status" >&5
10295 (exit $ac_status); } &&
10296 { ac_try='test -s conftest$ac_exeext'
10297 { (eval echo "$as_me:10297: \"$ac_try\"") >&5
10298 (eval $ac_try) 2>&5
10300 echo "$as_me:10300: \$? = $ac_status" >&5
10301 (exit $ac_status); }; }; then
10304 echo "$as_me: failed program was:" >&5
10305 cat conftest.$ac_ext >&5
10306 echo "$as_me:10306: checking for dnet_ntoa in -ldnet" >&5
10307 echo $ECHO_N "checking for dnet_ntoa in -ldnet... $ECHO_C" >&6
10308 if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then
10309 echo $ECHO_N "(cached) $ECHO_C" >&6
10311 ac_check_lib_save_LIBS=$LIBS
10312 LIBS="-ldnet $LIBS"
10313 cat >conftest.$ac_ext <<_ACEOF
10314 #line 10314 "configure"
10315 #include "confdefs.h"
10317 /* Override any gcc2 internal prototype to avoid an error. */
10321 /* We use char because int might match the return type of a gcc2
10322 builtin and then its argument prototype would still apply. */
10332 rm -f conftest.$ac_objext conftest$ac_exeext
10333 if { (eval echo "$as_me:10333: \"$ac_link\"") >&5
10334 (eval $ac_link) 2>&5
10336 echo "$as_me:10336: \$? = $ac_status" >&5
10337 (exit $ac_status); } &&
10338 { ac_try='test -s conftest$ac_exeext'
10339 { (eval echo "$as_me:10339: \"$ac_try\"") >&5
10340 (eval $ac_try) 2>&5
10342 echo "$as_me:10342: \$? = $ac_status" >&5
10343 (exit $ac_status); }; }; then
10344 ac_cv_lib_dnet_dnet_ntoa=yes
10346 echo "$as_me: failed program was:" >&5
10347 cat conftest.$ac_ext >&5
10348 ac_cv_lib_dnet_dnet_ntoa=no
10350 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10351 LIBS=$ac_check_lib_save_LIBS
10353 echo "$as_me:10353: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
10354 echo "${ECHO_T}$ac_cv_lib_dnet_dnet_ntoa" >&6
10355 if test $ac_cv_lib_dnet_dnet_ntoa = yes; then
10356 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
10359 if test $ac_cv_lib_dnet_dnet_ntoa = no; then
10360 echo "$as_me:10360: checking for dnet_ntoa in -ldnet_stub" >&5
10361 echo $ECHO_N "checking for dnet_ntoa in -ldnet_stub... $ECHO_C" >&6
10362 if test "${ac_cv_lib_dnet_stub_dnet_ntoa+set}" = set; then
10363 echo $ECHO_N "(cached) $ECHO_C" >&6
10365 ac_check_lib_save_LIBS=$LIBS
10366 LIBS="-ldnet_stub $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. */
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_dnet_stub_dnet_ntoa=yes
10400 echo "$as_me: failed program was:" >&5
10401 cat conftest.$ac_ext >&5
10402 ac_cv_lib_dnet_stub_dnet_ntoa=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_dnet_stub_dnet_ntoa" >&5
10408 echo "${ECHO_T}$ac_cv_lib_dnet_stub_dnet_ntoa" >&6
10409 if test $ac_cv_lib_dnet_stub_dnet_ntoa = yes; then
10410 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
10415 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10416 LIBS="$ac_xsave_LIBS"
10418 # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT,
10419 # to get the SysV transport functions.
10420 # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4)
10422 # The nsl library prevents programs from opening the X display
10423 # on Irix 5.2, according to T.E. Dickey.
10424 # The functions gethostbyname, getservbyname, and inet_addr are
10425 # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking.
10426 echo "$as_me:10426: checking for gethostbyname" >&5
10427 echo $ECHO_N "checking for gethostbyname... $ECHO_C" >&6
10428 if test "${ac_cv_func_gethostbyname+set}" = set; then
10429 echo $ECHO_N "(cached) $ECHO_C" >&6
10431 cat >conftest.$ac_ext <<_ACEOF
10432 #line 10432 "configure"
10433 #include "confdefs.h"
10434 /* System header to define __stub macros and hopefully few prototypes,
10435 which can conflict with char gethostbyname (); below. */
10436 #include <assert.h>
10437 /* Override any gcc2 internal prototype to avoid an error. */
10441 /* We use char because int might match the return type of a gcc2
10442 builtin and then its argument prototype would still apply. */
10443 char gethostbyname ();
10449 /* The GNU C library defines this for functions which it implements
10450 to always fail with ENOSYS. Some functions are actually named
10451 something starting with __ and the normal name is an alias. */
10452 #if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
10462 rm -f conftest.$ac_objext conftest$ac_exeext
10463 if { (eval echo "$as_me:10463: \"$ac_link\"") >&5
10464 (eval $ac_link) 2>&5
10466 echo "$as_me:10466: \$? = $ac_status" >&5
10467 (exit $ac_status); } &&
10468 { ac_try='test -s conftest$ac_exeext'
10469 { (eval echo "$as_me:10469: \"$ac_try\"") >&5
10470 (eval $ac_try) 2>&5
10472 echo "$as_me:10472: \$? = $ac_status" >&5
10473 (exit $ac_status); }; }; then
10474 ac_cv_func_gethostbyname=yes
10476 echo "$as_me: failed program was:" >&5
10477 cat conftest.$ac_ext >&5
10478 ac_cv_func_gethostbyname=no
10480 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10482 echo "$as_me:10482: result: $ac_cv_func_gethostbyname" >&5
10483 echo "${ECHO_T}$ac_cv_func_gethostbyname" >&6
10485 if test $ac_cv_func_gethostbyname = no; then
10486 echo "$as_me:10486: checking for gethostbyname in -lnsl" >&5
10487 echo $ECHO_N "checking for gethostbyname in -lnsl... $ECHO_C" >&6
10488 if test "${ac_cv_lib_nsl_gethostbyname+set}" = set; then
10489 echo $ECHO_N "(cached) $ECHO_C" >&6
10491 ac_check_lib_save_LIBS=$LIBS
10493 cat >conftest.$ac_ext <<_ACEOF
10494 #line 10494 "configure"
10495 #include "confdefs.h"
10497 /* Override any gcc2 internal prototype to avoid an error. */
10501 /* We use char because int might match the return type of a gcc2
10502 builtin and then its argument prototype would still apply. */
10503 char gethostbyname ();
10512 rm -f conftest.$ac_objext conftest$ac_exeext
10513 if { (eval echo "$as_me:10513: \"$ac_link\"") >&5
10514 (eval $ac_link) 2>&5
10516 echo "$as_me:10516: \$? = $ac_status" >&5
10517 (exit $ac_status); } &&
10518 { ac_try='test -s conftest$ac_exeext'
10519 { (eval echo "$as_me:10519: \"$ac_try\"") >&5
10520 (eval $ac_try) 2>&5
10522 echo "$as_me:10522: \$? = $ac_status" >&5
10523 (exit $ac_status); }; }; then
10524 ac_cv_lib_nsl_gethostbyname=yes
10526 echo "$as_me: failed program was:" >&5
10527 cat conftest.$ac_ext >&5
10528 ac_cv_lib_nsl_gethostbyname=no
10530 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10531 LIBS=$ac_check_lib_save_LIBS
10533 echo "$as_me:10533: result: $ac_cv_lib_nsl_gethostbyname" >&5
10534 echo "${ECHO_T}$ac_cv_lib_nsl_gethostbyname" >&6
10535 if test $ac_cv_lib_nsl_gethostbyname = yes; then
10536 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
10539 if test $ac_cv_lib_nsl_gethostbyname = no; then
10540 echo "$as_me:10540: checking for gethostbyname in -lbsd" >&5
10541 echo $ECHO_N "checking for gethostbyname in -lbsd... $ECHO_C" >&6
10542 if test "${ac_cv_lib_bsd_gethostbyname+set}" = set; then
10543 echo $ECHO_N "(cached) $ECHO_C" >&6
10545 ac_check_lib_save_LIBS=$LIBS
10547 cat >conftest.$ac_ext <<_ACEOF
10548 #line 10548 "configure"
10549 #include "confdefs.h"
10551 /* Override any gcc2 internal prototype to avoid an error. */
10555 /* We use char because int might match the return type of a gcc2
10556 builtin and then its argument prototype would still apply. */
10557 char gethostbyname ();
10566 rm -f conftest.$ac_objext conftest$ac_exeext
10567 if { (eval echo "$as_me:10567: \"$ac_link\"") >&5
10568 (eval $ac_link) 2>&5
10570 echo "$as_me:10570: \$? = $ac_status" >&5
10571 (exit $ac_status); } &&
10572 { ac_try='test -s conftest$ac_exeext'
10573 { (eval echo "$as_me:10573: \"$ac_try\"") >&5
10574 (eval $ac_try) 2>&5
10576 echo "$as_me:10576: \$? = $ac_status" >&5
10577 (exit $ac_status); }; }; then
10578 ac_cv_lib_bsd_gethostbyname=yes
10580 echo "$as_me: failed program was:" >&5
10581 cat conftest.$ac_ext >&5
10582 ac_cv_lib_bsd_gethostbyname=no
10584 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10585 LIBS=$ac_check_lib_save_LIBS
10587 echo "$as_me:10587: result: $ac_cv_lib_bsd_gethostbyname" >&5
10588 echo "${ECHO_T}$ac_cv_lib_bsd_gethostbyname" >&6
10589 if test $ac_cv_lib_bsd_gethostbyname = yes; then
10590 X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd"
10596 # lieder@skyler.mavd.honeywell.com says without -lsocket,
10597 # socket/setsockopt and other routines are undefined under SCO ODT
10598 # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary
10599 # on later versions), says Simon Leinen: it contains gethostby*
10600 # variants that don't use the nameserver (or something). -lsocket
10601 # must be given before -lnsl if both are needed. We assume that
10602 # if connect needs -lnsl, so does gethostbyname.
10603 echo "$as_me:10603: checking for connect" >&5
10604 echo $ECHO_N "checking for connect... $ECHO_C" >&6
10605 if test "${ac_cv_func_connect+set}" = set; then
10606 echo $ECHO_N "(cached) $ECHO_C" >&6
10608 cat >conftest.$ac_ext <<_ACEOF
10609 #line 10609 "configure"
10610 #include "confdefs.h"
10611 /* System header to define __stub macros and hopefully few prototypes,
10612 which can conflict with char connect (); below. */
10613 #include <assert.h>
10614 /* Override any gcc2 internal prototype to avoid an error. */
10618 /* We use char because int might match the return type of a gcc2
10619 builtin and then its argument prototype would still apply. */
10626 /* The GNU C library defines this for functions which it implements
10627 to always fail with ENOSYS. Some functions are actually named
10628 something starting with __ and the normal name is an alias. */
10629 #if defined (__stub_connect) || defined (__stub___connect)
10639 rm -f conftest.$ac_objext conftest$ac_exeext
10640 if { (eval echo "$as_me:10640: \"$ac_link\"") >&5
10641 (eval $ac_link) 2>&5
10643 echo "$as_me:10643: \$? = $ac_status" >&5
10644 (exit $ac_status); } &&
10645 { ac_try='test -s conftest$ac_exeext'
10646 { (eval echo "$as_me:10646: \"$ac_try\"") >&5
10647 (eval $ac_try) 2>&5
10649 echo "$as_me:10649: \$? = $ac_status" >&5
10650 (exit $ac_status); }; }; then
10651 ac_cv_func_connect=yes
10653 echo "$as_me: failed program was:" >&5
10654 cat conftest.$ac_ext >&5
10655 ac_cv_func_connect=no
10657 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10659 echo "$as_me:10659: result: $ac_cv_func_connect" >&5
10660 echo "${ECHO_T}$ac_cv_func_connect" >&6
10662 if test $ac_cv_func_connect = no; then
10663 echo "$as_me:10663: checking for connect in -lsocket" >&5
10664 echo $ECHO_N "checking for connect in -lsocket... $ECHO_C" >&6
10665 if test "${ac_cv_lib_socket_connect+set}" = set; then
10666 echo $ECHO_N "(cached) $ECHO_C" >&6
10668 ac_check_lib_save_LIBS=$LIBS
10669 LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
10670 cat >conftest.$ac_ext <<_ACEOF
10671 #line 10671 "configure"
10672 #include "confdefs.h"
10674 /* Override any gcc2 internal prototype to avoid an error. */
10678 /* We use char because int might match the return type of a gcc2
10679 builtin and then its argument prototype would still apply. */
10689 rm -f conftest.$ac_objext conftest$ac_exeext
10690 if { (eval echo "$as_me:10690: \"$ac_link\"") >&5
10691 (eval $ac_link) 2>&5
10693 echo "$as_me:10693: \$? = $ac_status" >&5
10694 (exit $ac_status); } &&
10695 { ac_try='test -s conftest$ac_exeext'
10696 { (eval echo "$as_me:10696: \"$ac_try\"") >&5
10697 (eval $ac_try) 2>&5
10699 echo "$as_me:10699: \$? = $ac_status" >&5
10700 (exit $ac_status); }; }; then
10701 ac_cv_lib_socket_connect=yes
10703 echo "$as_me: failed program was:" >&5
10704 cat conftest.$ac_ext >&5
10705 ac_cv_lib_socket_connect=no
10707 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10708 LIBS=$ac_check_lib_save_LIBS
10710 echo "$as_me:10710: result: $ac_cv_lib_socket_connect" >&5
10711 echo "${ECHO_T}$ac_cv_lib_socket_connect" >&6
10712 if test $ac_cv_lib_socket_connect = yes; then
10713 X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS"
10718 # Guillermo Gomez says -lposix is necessary on A/UX.
10719 echo "$as_me:10719: checking for remove" >&5
10720 echo $ECHO_N "checking for remove... $ECHO_C" >&6
10721 if test "${ac_cv_func_remove+set}" = set; then
10722 echo $ECHO_N "(cached) $ECHO_C" >&6
10724 cat >conftest.$ac_ext <<_ACEOF
10725 #line 10725 "configure"
10726 #include "confdefs.h"
10727 /* System header to define __stub macros and hopefully few prototypes,
10728 which can conflict with char remove (); below. */
10729 #include <assert.h>
10730 /* Override any gcc2 internal prototype to avoid an error. */
10734 /* We use char because int might match the return type of a gcc2
10735 builtin and then its argument prototype would still apply. */
10742 /* The GNU C library defines this for functions which it implements
10743 to always fail with ENOSYS. Some functions are actually named
10744 something starting with __ and the normal name is an alias. */
10745 #if defined (__stub_remove) || defined (__stub___remove)
10755 rm -f conftest.$ac_objext conftest$ac_exeext
10756 if { (eval echo "$as_me:10756: \"$ac_link\"") >&5
10757 (eval $ac_link) 2>&5
10759 echo "$as_me:10759: \$? = $ac_status" >&5
10760 (exit $ac_status); } &&
10761 { ac_try='test -s conftest$ac_exeext'
10762 { (eval echo "$as_me:10762: \"$ac_try\"") >&5
10763 (eval $ac_try) 2>&5
10765 echo "$as_me:10765: \$? = $ac_status" >&5
10766 (exit $ac_status); }; }; then
10767 ac_cv_func_remove=yes
10769 echo "$as_me: failed program was:" >&5
10770 cat conftest.$ac_ext >&5
10771 ac_cv_func_remove=no
10773 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10775 echo "$as_me:10775: result: $ac_cv_func_remove" >&5
10776 echo "${ECHO_T}$ac_cv_func_remove" >&6
10778 if test $ac_cv_func_remove = no; then
10779 echo "$as_me:10779: checking for remove in -lposix" >&5
10780 echo $ECHO_N "checking for remove in -lposix... $ECHO_C" >&6
10781 if test "${ac_cv_lib_posix_remove+set}" = set; then
10782 echo $ECHO_N "(cached) $ECHO_C" >&6
10784 ac_check_lib_save_LIBS=$LIBS
10785 LIBS="-lposix $LIBS"
10786 cat >conftest.$ac_ext <<_ACEOF
10787 #line 10787 "configure"
10788 #include "confdefs.h"
10790 /* Override any gcc2 internal prototype to avoid an error. */
10794 /* We use char because int might match the return type of a gcc2
10795 builtin and then its argument prototype would still apply. */
10805 rm -f conftest.$ac_objext conftest$ac_exeext
10806 if { (eval echo "$as_me:10806: \"$ac_link\"") >&5
10807 (eval $ac_link) 2>&5
10809 echo "$as_me:10809: \$? = $ac_status" >&5
10810 (exit $ac_status); } &&
10811 { ac_try='test -s conftest$ac_exeext'
10812 { (eval echo "$as_me:10812: \"$ac_try\"") >&5
10813 (eval $ac_try) 2>&5
10815 echo "$as_me:10815: \$? = $ac_status" >&5
10816 (exit $ac_status); }; }; then
10817 ac_cv_lib_posix_remove=yes
10819 echo "$as_me: failed program was:" >&5
10820 cat conftest.$ac_ext >&5
10821 ac_cv_lib_posix_remove=no
10823 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10824 LIBS=$ac_check_lib_save_LIBS
10826 echo "$as_me:10826: result: $ac_cv_lib_posix_remove" >&5
10827 echo "${ECHO_T}$ac_cv_lib_posix_remove" >&6
10828 if test $ac_cv_lib_posix_remove = yes; then
10829 X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix"
10834 # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
10835 echo "$as_me:10835: checking for shmat" >&5
10836 echo $ECHO_N "checking for shmat... $ECHO_C" >&6
10837 if test "${ac_cv_func_shmat+set}" = set; then
10838 echo $ECHO_N "(cached) $ECHO_C" >&6
10840 cat >conftest.$ac_ext <<_ACEOF
10841 #line 10841 "configure"
10842 #include "confdefs.h"
10843 /* System header to define __stub macros and hopefully few prototypes,
10844 which can conflict with char shmat (); below. */
10845 #include <assert.h>
10846 /* Override any gcc2 internal prototype to avoid an error. */
10850 /* We use char because int might match the return type of a gcc2
10851 builtin and then its argument prototype would still apply. */
10858 /* The GNU C library defines this for functions which it implements
10859 to always fail with ENOSYS. Some functions are actually named
10860 something starting with __ and the normal name is an alias. */
10861 #if defined (__stub_shmat) || defined (__stub___shmat)
10871 rm -f conftest.$ac_objext conftest$ac_exeext
10872 if { (eval echo "$as_me:10872: \"$ac_link\"") >&5
10873 (eval $ac_link) 2>&5
10875 echo "$as_me:10875: \$? = $ac_status" >&5
10876 (exit $ac_status); } &&
10877 { ac_try='test -s conftest$ac_exeext'
10878 { (eval echo "$as_me:10878: \"$ac_try\"") >&5
10879 (eval $ac_try) 2>&5
10881 echo "$as_me:10881: \$? = $ac_status" >&5
10882 (exit $ac_status); }; }; then
10883 ac_cv_func_shmat=yes
10885 echo "$as_me: failed program was:" >&5
10886 cat conftest.$ac_ext >&5
10887 ac_cv_func_shmat=no
10889 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10891 echo "$as_me:10891: result: $ac_cv_func_shmat" >&5
10892 echo "${ECHO_T}$ac_cv_func_shmat" >&6
10894 if test $ac_cv_func_shmat = no; then
10895 echo "$as_me:10895: checking for shmat in -lipc" >&5
10896 echo $ECHO_N "checking for shmat in -lipc... $ECHO_C" >&6
10897 if test "${ac_cv_lib_ipc_shmat+set}" = set; then
10898 echo $ECHO_N "(cached) $ECHO_C" >&6
10900 ac_check_lib_save_LIBS=$LIBS
10902 cat >conftest.$ac_ext <<_ACEOF
10903 #line 10903 "configure"
10904 #include "confdefs.h"
10906 /* Override any gcc2 internal prototype to avoid an error. */
10910 /* We use char because int might match the return type of a gcc2
10911 builtin and then its argument prototype would still apply. */
10921 rm -f conftest.$ac_objext conftest$ac_exeext
10922 if { (eval echo "$as_me:10922: \"$ac_link\"") >&5
10923 (eval $ac_link) 2>&5
10925 echo "$as_me:10925: \$? = $ac_status" >&5
10926 (exit $ac_status); } &&
10927 { ac_try='test -s conftest$ac_exeext'
10928 { (eval echo "$as_me:10928: \"$ac_try\"") >&5
10929 (eval $ac_try) 2>&5
10931 echo "$as_me:10931: \$? = $ac_status" >&5
10932 (exit $ac_status); }; }; then
10933 ac_cv_lib_ipc_shmat=yes
10935 echo "$as_me: failed program was:" >&5
10936 cat conftest.$ac_ext >&5
10937 ac_cv_lib_ipc_shmat=no
10939 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10940 LIBS=$ac_check_lib_save_LIBS
10942 echo "$as_me:10942: result: $ac_cv_lib_ipc_shmat" >&5
10943 echo "${ECHO_T}$ac_cv_lib_ipc_shmat" >&6
10944 if test $ac_cv_lib_ipc_shmat = yes; then
10945 X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc"
10951 # Check for libraries that X11R6 Xt/Xaw programs need.
10952 ac_save_LDFLAGS=$LDFLAGS
10953 test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries"
10954 # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
10955 # check for ICE first), but we must link in the order -lSM -lICE or
10956 # we get undefined symbols. So assume we have SM if we have ICE.
10957 # These have to be linked with before -lX11, unlike the other
10958 # libraries we check for below, so use a different variable.
10959 # John Interrante, Karl Berry
10960 echo "$as_me:10960: checking for IceConnectionNumber in -lICE" >&5
10961 echo $ECHO_N "checking for IceConnectionNumber in -lICE... $ECHO_C" >&6
10962 if test "${ac_cv_lib_ICE_IceConnectionNumber+set}" = set; then
10963 echo $ECHO_N "(cached) $ECHO_C" >&6
10965 ac_check_lib_save_LIBS=$LIBS
10966 LIBS="-lICE $X_EXTRA_LIBS $LIBS"
10967 cat >conftest.$ac_ext <<_ACEOF
10968 #line 10968 "configure"
10969 #include "confdefs.h"
10971 /* Override any gcc2 internal prototype to avoid an error. */
10975 /* We use char because int might match the return type of a gcc2
10976 builtin and then its argument prototype would still apply. */
10977 char IceConnectionNumber ();
10981 IceConnectionNumber ();
10986 rm -f conftest.$ac_objext conftest$ac_exeext
10987 if { (eval echo "$as_me:10987: \"$ac_link\"") >&5
10988 (eval $ac_link) 2>&5
10990 echo "$as_me:10990: \$? = $ac_status" >&5
10991 (exit $ac_status); } &&
10992 { ac_try='test -s conftest$ac_exeext'
10993 { (eval echo "$as_me:10993: \"$ac_try\"") >&5
10994 (eval $ac_try) 2>&5
10996 echo "$as_me:10996: \$? = $ac_status" >&5
10997 (exit $ac_status); }; }; then
10998 ac_cv_lib_ICE_IceConnectionNumber=yes
11000 echo "$as_me: failed program was:" >&5
11001 cat conftest.$ac_ext >&5
11002 ac_cv_lib_ICE_IceConnectionNumber=no
11004 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11005 LIBS=$ac_check_lib_save_LIBS
11007 echo "$as_me:11007: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5
11008 echo "${ECHO_T}$ac_cv_lib_ICE_IceConnectionNumber" >&6
11009 if test $ac_cv_lib_ICE_IceConnectionNumber = yes; then
11010 X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
11013 LDFLAGS=$ac_save_LDFLAGS
11017 cf_x_athena=${cf_x_athena:-Xaw}
11019 echo "$as_me:11019: checking if you want to link with Xaw 3d library" >&5
11020 echo $ECHO_N "checking if you want to link with Xaw 3d library... $ECHO_C" >&6
11023 # Check whether --with-Xaw3d or --without-Xaw3d was given.
11024 if test "${with_Xaw3d+set}" = set; then
11025 withval="$with_Xaw3d"
11028 if test "$withval" = yes ; then
11030 echo "$as_me:11030: result: yes" >&5
11031 echo "${ECHO_T}yes" >&6
11033 echo "$as_me:11033: result: no" >&5
11034 echo "${ECHO_T}no" >&6
11037 echo "$as_me:11037: checking if you want to link with neXT Athena library" >&5
11038 echo $ECHO_N "checking if you want to link with neXT Athena library... $ECHO_C" >&6
11041 # Check whether --with-neXtaw or --without-neXtaw was given.
11042 if test "${with_neXtaw+set}" = set; then
11043 withval="$with_neXtaw"
11046 if test "$withval" = yes ; then
11048 echo "$as_me:11048: result: yes" >&5
11049 echo "${ECHO_T}yes" >&6
11051 echo "$as_me:11051: result: no" >&5
11052 echo "${ECHO_T}no" >&6
11055 echo "$as_me:11055: checking if you want to link with Athena-Plus library" >&5
11056 echo $ECHO_N "checking if you want to link with Athena-Plus library... $ECHO_C" >&6
11059 # Check whether --with-XawPlus or --without-XawPlus was given.
11060 if test "${with_XawPlus+set}" = set; then
11061 withval="$with_XawPlus"
11064 if test "$withval" = yes ; then
11065 cf_x_athena=XawPlus
11066 echo "$as_me:11066: result: yes" >&5
11067 echo "${ECHO_T}yes" >&6
11069 echo "$as_me:11069: result: no" >&5
11070 echo "${ECHO_T}no" >&6
11075 if test "$PKG_CONFIG" != none ; then
11077 test "$cf_x_athena" = Xaw && cf_athena_list="xaw8 xaw7 xaw6"
11078 for cf_athena_pkg in \
11081 ${cf_x_athena}-devel \
11082 lib${cf_x_athena} \
11083 lib${cf_x_athena}-devel
11086 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists $cf_athena_pkg; then
11087 test -n "$verbose" && echo " found package $cf_athena_pkg" 1>&6
11089 echo "${as_me:-configure}:11089: testing found package $cf_athena_pkg ..." 1>&5
11091 cf_pkgconfig_incs="`$PKG_CONFIG --cflags $cf_athena_pkg 2>/dev/null`"
11092 cf_pkgconfig_libs="`$PKG_CONFIG --libs $cf_athena_pkg 2>/dev/null`"
11093 test -n "$verbose" && echo " package $cf_athena_pkg CFLAGS: $cf_pkgconfig_incs" 1>&6
11095 echo "${as_me:-configure}:11095: testing package $cf_athena_pkg CFLAGS: $cf_pkgconfig_incs ..." 1>&5
11097 test -n "$verbose" && echo " package $cf_athena_pkg LIBS: $cf_pkgconfig_libs" 1>&6
11099 echo "${as_me:-configure}:11099: testing package $cf_athena_pkg LIBS: $cf_pkgconfig_libs ..." 1>&5
11104 cf_new_extra_cppflags=
11106 for cf_add_cflags in $cf_pkgconfig_incs
11108 case $cf_fix_cppflags in
11110 case $cf_add_cflags in #(vi
11111 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
11112 case $cf_add_cflags in
11114 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11116 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11117 && test -z "${cf_tst_cflags}" \
11118 && cf_fix_cppflags=yes
11120 if test $cf_fix_cppflags = yes ; then
11121 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11123 elif test "${cf_tst_cflags}" = "\"'" ; then
11124 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11129 case "$CPPFLAGS" in
11130 *$cf_add_cflags) #(vi
11133 case $cf_add_cflags in #(vi
11135 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11137 CPPFLAGS=`echo "$CPPFLAGS" | \
11138 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11139 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11143 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
11148 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
11153 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11155 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11157 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11158 && test -z "${cf_tst_cflags}" \
11159 && cf_fix_cppflags=no
11164 if test -n "$cf_new_cflags" ; then
11166 CFLAGS="$CFLAGS $cf_new_cflags"
11169 if test -n "$cf_new_cppflags" ; then
11171 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
11174 if test -n "$cf_new_extra_cppflags" ; then
11176 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
11179 LIBS="$cf_pkgconfig_libs $LIBS"
11181 cf_x_athena_lib="$cf_pkgconfig_libs"
11183 cf_x_athena_LIBS=`echo "HAVE_LIB_$cf_x_athena" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
11185 cat >>confdefs.h <<EOF
11186 #define $cf_x_athena_LIBS 1
11189 echo "$as_me:11189: checking for usable $cf_x_athena/Xmu package" >&5
11190 echo $ECHO_N "checking for usable $cf_x_athena/Xmu package... $ECHO_C" >&6
11191 if test "${cf_cv_xaw_compat+set}" = set; then
11192 echo $ECHO_N "(cached) $ECHO_C" >&6
11195 cat >conftest.$ac_ext <<_ACEOF
11196 #line 11196 "configure"
11197 #include "confdefs.h"
11199 #include <X11/Xmu/CharSet.h>
11205 int check = XmuCompareISOLatin1("big", "small")
11211 rm -f conftest.$ac_objext conftest$ac_exeext
11212 if { (eval echo "$as_me:11212: \"$ac_link\"") >&5
11213 (eval $ac_link) 2>&5
11215 echo "$as_me:11215: \$? = $ac_status" >&5
11216 (exit $ac_status); } &&
11217 { ac_try='test -s conftest$ac_exeext'
11218 { (eval echo "$as_me:11218: \"$ac_try\"") >&5
11219 (eval $ac_try) 2>&5
11221 echo "$as_me:11221: \$? = $ac_status" >&5
11222 (exit $ac_status); }; }; then
11223 cf_cv_xaw_compat=yes
11225 echo "$as_me: failed program was:" >&5
11226 cat conftest.$ac_ext >&5
11227 cf_cv_xaw_compat=no
11229 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11231 echo "$as_me:11231: result: $cf_cv_xaw_compat" >&5
11232 echo "${ECHO_T}$cf_cv_xaw_compat" >&6
11234 if test "$cf_cv_xaw_compat" = no
11236 # workaround for broken ".pc" files...
11237 case "$cf_x_athena_lib" in #(vi
11241 test -n "$verbose" && echo " work around broken package" 1>&6
11243 echo "${as_me:-configure}:11243: testing work around broken package ..." 1>&5
11245 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xmu; then
11246 test -n "$verbose" && echo " found package xmu" 1>&6
11248 echo "${as_me:-configure}:11248: testing found package xmu ..." 1>&5
11250 cf_pkgconfig_incs="`$PKG_CONFIG --cflags xmu 2>/dev/null`"
11251 cf_pkgconfig_libs="`$PKG_CONFIG --libs xmu 2>/dev/null`"
11252 test -n "$verbose" && echo " package xmu CFLAGS: $cf_pkgconfig_incs" 1>&6
11254 echo "${as_me:-configure}:11254: testing package xmu CFLAGS: $cf_pkgconfig_incs ..." 1>&5
11256 test -n "$verbose" && echo " package xmu LIBS: $cf_pkgconfig_libs" 1>&6
11258 echo "${as_me:-configure}:11258: testing package xmu 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"
11342 test -n "$verbose" && echo " ...before $LIBS" 1>&6
11344 echo "${as_me:-configure}:11344: testing ...before $LIBS ..." 1>&5
11346 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s,-lXt ,-lXt -lXmu ," -e 's/ / /g'`
11347 test -n "$verbose" && echo " ...after $LIBS" 1>&6
11349 echo "${as_me:-configure}:11349: testing ...after $LIBS ..." 1>&5
11365 if test -z "$cf_x_athena_lib" ; then
11367 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists Xext; then
11368 test -n "$verbose" && echo " found package Xext" 1>&6
11370 echo "${as_me:-configure}:11370: testing found package Xext ..." 1>&5
11372 cf_pkgconfig_incs="`$PKG_CONFIG --cflags Xext 2>/dev/null`"
11373 cf_pkgconfig_libs="`$PKG_CONFIG --libs Xext 2>/dev/null`"
11374 test -n "$verbose" && echo " package Xext CFLAGS: $cf_pkgconfig_incs" 1>&6
11376 echo "${as_me:-configure}:11376: testing package Xext CFLAGS: $cf_pkgconfig_incs ..." 1>&5
11378 test -n "$verbose" && echo " package Xext LIBS: $cf_pkgconfig_libs" 1>&6
11380 echo "${as_me:-configure}:11380: testing package Xext LIBS: $cf_pkgconfig_libs ..." 1>&5
11385 cf_new_extra_cppflags=
11387 for cf_add_cflags in $cf_pkgconfig_incs
11389 case $cf_fix_cppflags in
11391 case $cf_add_cflags in #(vi
11392 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
11393 case $cf_add_cflags in
11395 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11397 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11398 && test -z "${cf_tst_cflags}" \
11399 && cf_fix_cppflags=yes
11401 if test $cf_fix_cppflags = yes ; then
11402 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11404 elif test "${cf_tst_cflags}" = "\"'" ; then
11405 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11410 case "$CPPFLAGS" in
11411 *$cf_add_cflags) #(vi
11414 case $cf_add_cflags in #(vi
11416 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11418 CPPFLAGS=`echo "$CPPFLAGS" | \
11419 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11420 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11424 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
11429 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
11434 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11436 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11438 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11439 && test -z "${cf_tst_cflags}" \
11440 && cf_fix_cppflags=no
11445 if test -n "$cf_new_cflags" ; then
11447 CFLAGS="$CFLAGS $cf_new_cflags"
11450 if test -n "$cf_new_cppflags" ; then
11452 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
11455 if test -n "$cf_new_extra_cppflags" ; then
11457 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
11460 LIBS="$cf_pkgconfig_libs $LIBS"
11464 echo "$as_me:11464: checking for XextCreateExtension in -lXext" >&5
11465 echo $ECHO_N "checking for XextCreateExtension in -lXext... $ECHO_C" >&6
11466 if test "${ac_cv_lib_Xext_XextCreateExtension+set}" = set; then
11467 echo $ECHO_N "(cached) $ECHO_C" >&6
11469 ac_check_lib_save_LIBS=$LIBS
11470 LIBS="-lXext $LIBS"
11471 cat >conftest.$ac_ext <<_ACEOF
11472 #line 11472 "configure"
11473 #include "confdefs.h"
11475 /* Override any gcc2 internal prototype to avoid an error. */
11479 /* We use char because int might match the return type of a gcc2
11480 builtin and then its argument prototype would still apply. */
11481 char XextCreateExtension ();
11485 XextCreateExtension ();
11490 rm -f conftest.$ac_objext conftest$ac_exeext
11491 if { (eval echo "$as_me:11491: \"$ac_link\"") >&5
11492 (eval $ac_link) 2>&5
11494 echo "$as_me:11494: \$? = $ac_status" >&5
11495 (exit $ac_status); } &&
11496 { ac_try='test -s conftest$ac_exeext'
11497 { (eval echo "$as_me:11497: \"$ac_try\"") >&5
11498 (eval $ac_try) 2>&5
11500 echo "$as_me:11500: \$? = $ac_status" >&5
11501 (exit $ac_status); }; }; then
11502 ac_cv_lib_Xext_XextCreateExtension=yes
11504 echo "$as_me: failed program was:" >&5
11505 cat conftest.$ac_ext >&5
11506 ac_cv_lib_Xext_XextCreateExtension=no
11508 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11509 LIBS=$ac_check_lib_save_LIBS
11511 echo "$as_me:11511: result: $ac_cv_lib_Xext_XextCreateExtension" >&5
11512 echo "${ECHO_T}$ac_cv_lib_Xext_XextCreateExtension" >&6
11513 if test $ac_cv_lib_Xext_XextCreateExtension = yes; then
11514 LIBS="-lXext $LIBS"
11521 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xt; then
11522 test -n "$verbose" && echo " found package xt" 1>&6
11524 echo "${as_me:-configure}:11524: testing found package xt ..." 1>&5
11526 cf_pkgconfig_incs="`$PKG_CONFIG --cflags xt 2>/dev/null`"
11527 cf_pkgconfig_libs="`$PKG_CONFIG --libs xt 2>/dev/null`"
11528 test -n "$verbose" && echo " package xt CFLAGS: $cf_pkgconfig_incs" 1>&6
11530 echo "${as_me:-configure}:11530: testing package xt CFLAGS: $cf_pkgconfig_incs ..." 1>&5
11532 test -n "$verbose" && echo " package xt LIBS: $cf_pkgconfig_libs" 1>&6
11534 echo "${as_me:-configure}:11534: testing package xt LIBS: $cf_pkgconfig_libs ..." 1>&5
11539 cf_new_extra_cppflags=
11541 for cf_add_cflags in $cf_pkgconfig_incs
11543 case $cf_fix_cppflags in
11545 case $cf_add_cflags in #(vi
11546 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
11547 case $cf_add_cflags in
11549 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11551 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11552 && test -z "${cf_tst_cflags}" \
11553 && cf_fix_cppflags=yes
11555 if test $cf_fix_cppflags = yes ; then
11556 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11558 elif test "${cf_tst_cflags}" = "\"'" ; then
11559 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11564 case "$CPPFLAGS" in
11565 *$cf_add_cflags) #(vi
11568 case $cf_add_cflags in #(vi
11570 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11572 CPPFLAGS=`echo "$CPPFLAGS" | \
11573 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11574 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11578 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
11583 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
11588 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11590 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11592 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11593 && test -z "${cf_tst_cflags}" \
11594 && cf_fix_cppflags=no
11599 if test -n "$cf_new_cflags" ; then
11601 CFLAGS="$CFLAGS $cf_new_cflags"
11604 if test -n "$cf_new_cppflags" ; then
11606 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
11609 if test -n "$cf_new_extra_cppflags" ; then
11611 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
11614 LIBS="$cf_pkgconfig_libs $LIBS"
11616 case "x$LIBS" in #(vi
11620 # we have an "xt" package, but it may omit Xt's dependency on X11
11621 echo "$as_me:11621: checking for usable X dependency" >&5
11622 echo $ECHO_N "checking for usable X dependency... $ECHO_C" >&6
11623 if test "${cf_cv_xt_x11_compat+set}" = set; then
11624 echo $ECHO_N "(cached) $ECHO_C" >&6
11627 cat >conftest.$ac_ext <<_ACEOF
11628 #line 11628 "configure"
11629 #include "confdefs.h"
11631 #include <X11/Xlib.h>
11637 int rc1 = XDrawLine((Display*) 0, (Drawable) 0, (GC) 0, 0, 0, 0, 0);
11638 int rc2 = XClearWindow((Display*) 0, (Window) 0);
11639 int rc3 = XMoveWindow((Display*) 0, (Window) 0, 0, 0);
11640 int rc4 = XMoveResizeWindow((Display*)0, (Window)0, 0, 0, 0, 0);
11646 rm -f conftest.$ac_objext conftest$ac_exeext
11647 if { (eval echo "$as_me:11647: \"$ac_link\"") >&5
11648 (eval $ac_link) 2>&5
11650 echo "$as_me:11650: \$? = $ac_status" >&5
11651 (exit $ac_status); } &&
11652 { ac_try='test -s conftest$ac_exeext'
11653 { (eval echo "$as_me:11653: \"$ac_try\"") >&5
11654 (eval $ac_try) 2>&5
11656 echo "$as_me:11656: \$? = $ac_status" >&5
11657 (exit $ac_status); }; }; then
11658 cf_cv_xt_x11_compat=yes
11660 echo "$as_me: failed program was:" >&5
11661 cat conftest.$ac_ext >&5
11662 cf_cv_xt_x11_compat=no
11664 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11666 echo "$as_me:11666: result: $cf_cv_xt_x11_compat" >&5
11667 echo "${ECHO_T}$cf_cv_xt_x11_compat" >&6
11668 if test "$cf_cv_xt_x11_compat" = no
11670 test -n "$verbose" && echo " work around broken X11 dependency" 1>&6
11672 echo "${as_me:-configure}:11672: testing work around broken X11 dependency ..." 1>&5
11674 # 2010/11/19 - good enough until a working Xt on Xcb is delivered.
11676 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists x11; then
11677 test -n "$verbose" && echo " found package x11" 1>&6
11679 echo "${as_me:-configure}:11679: testing found package x11 ..." 1>&5
11681 cf_pkgconfig_incs="`$PKG_CONFIG --cflags x11 2>/dev/null`"
11682 cf_pkgconfig_libs="`$PKG_CONFIG --libs x11 2>/dev/null`"
11683 test -n "$verbose" && echo " package x11 CFLAGS: $cf_pkgconfig_incs" 1>&6
11685 echo "${as_me:-configure}:11685: testing package x11 CFLAGS: $cf_pkgconfig_incs ..." 1>&5
11687 test -n "$verbose" && echo " package x11 LIBS: $cf_pkgconfig_libs" 1>&6
11689 echo "${as_me:-configure}:11689: testing package x11 LIBS: $cf_pkgconfig_libs ..." 1>&5
11694 cf_new_extra_cppflags=
11696 for cf_add_cflags in $cf_pkgconfig_incs
11698 case $cf_fix_cppflags in
11700 case $cf_add_cflags in #(vi
11701 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
11702 case $cf_add_cflags in
11704 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11706 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11707 && test -z "${cf_tst_cflags}" \
11708 && cf_fix_cppflags=yes
11710 if test $cf_fix_cppflags = yes ; then
11711 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11713 elif test "${cf_tst_cflags}" = "\"'" ; then
11714 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11719 case "$CPPFLAGS" in
11720 *$cf_add_cflags) #(vi
11723 case $cf_add_cflags in #(vi
11725 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11727 CPPFLAGS=`echo "$CPPFLAGS" | \
11728 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11729 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11733 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
11738 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
11743 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11745 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11747 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11748 && test -z "${cf_tst_cflags}" \
11749 && cf_fix_cppflags=no
11754 if test -n "$cf_new_cflags" ; then
11756 CFLAGS="$CFLAGS $cf_new_cflags"
11759 if test -n "$cf_new_cppflags" ; then
11761 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
11764 if test -n "$cf_new_extra_cppflags" ; then
11766 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
11769 LIBS="$cf_pkgconfig_libs $LIBS"
11773 test -n "$verbose" && echo " ...before $LIBS" 1>&6
11775 echo "${as_me:-configure}:11775: testing ...before $LIBS ..." 1>&5
11777 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s,-lXt ,-lXt -lX11 ," -e 's/ / /g'`
11778 test -n "$verbose" && echo " ...after $LIBS" 1>&6
11780 echo "${as_me:-configure}:11780: testing ...after $LIBS ..." 1>&5
11788 echo "$as_me:11788: checking for usable X Toolkit package" >&5
11789 echo $ECHO_N "checking for usable X Toolkit package... $ECHO_C" >&6
11790 if test "${cf_cv_xt_ice_compat+set}" = set; then
11791 echo $ECHO_N "(cached) $ECHO_C" >&6
11794 cat >conftest.$ac_ext <<_ACEOF
11795 #line 11795 "configure"
11796 #include "confdefs.h"
11798 #include <X11/Shell.h>
11803 int num = IceConnectionNumber(0)
11809 rm -f conftest.$ac_objext conftest$ac_exeext
11810 if { (eval echo "$as_me:11810: \"$ac_link\"") >&5
11811 (eval $ac_link) 2>&5
11813 echo "$as_me:11813: \$? = $ac_status" >&5
11814 (exit $ac_status); } &&
11815 { ac_try='test -s conftest$ac_exeext'
11816 { (eval echo "$as_me:11816: \"$ac_try\"") >&5
11817 (eval $ac_try) 2>&5
11819 echo "$as_me:11819: \$? = $ac_status" >&5
11820 (exit $ac_status); }; }; then
11821 cf_cv_xt_ice_compat=yes
11823 echo "$as_me: failed program was:" >&5
11824 cat conftest.$ac_ext >&5
11825 cf_cv_xt_ice_compat=no
11827 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11829 echo "$as_me:11829: result: $cf_cv_xt_ice_compat" >&5
11830 echo "${ECHO_T}$cf_cv_xt_ice_compat" >&6
11832 if test "$cf_cv_xt_ice_compat" = no
11834 # workaround for broken ".pc" files used for X Toolkit.
11835 case "x$X_PRE_LIBS" in #(vi
11837 case "x$LIBS" in #(vi
11841 test -n "$verbose" && echo " work around broken ICE dependency" 1>&6
11843 echo "${as_me:-configure}:11843: testing work around broken ICE dependency ..." 1>&5
11845 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists ice; then
11846 test -n "$verbose" && echo " found package ice" 1>&6
11848 echo "${as_me:-configure}:11848: testing found package ice ..." 1>&5
11850 cf_pkgconfig_incs="`$PKG_CONFIG --cflags ice 2>/dev/null`"
11851 cf_pkgconfig_libs="`$PKG_CONFIG --libs ice 2>/dev/null`"
11852 test -n "$verbose" && echo " package ice CFLAGS: $cf_pkgconfig_incs" 1>&6
11854 echo "${as_me:-configure}:11854: testing package ice CFLAGS: $cf_pkgconfig_incs ..." 1>&5
11856 test -n "$verbose" && echo " package ice LIBS: $cf_pkgconfig_libs" 1>&6
11858 echo "${as_me:-configure}:11858: testing package ice LIBS: $cf_pkgconfig_libs ..." 1>&5
11863 cf_new_extra_cppflags=
11865 for cf_add_cflags in $cf_pkgconfig_incs
11867 case $cf_fix_cppflags in
11869 case $cf_add_cflags in #(vi
11870 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
11871 case $cf_add_cflags in
11873 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11875 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11876 && test -z "${cf_tst_cflags}" \
11877 && cf_fix_cppflags=yes
11879 if test $cf_fix_cppflags = yes ; then
11880 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11882 elif test "${cf_tst_cflags}" = "\"'" ; then
11883 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11888 case "$CPPFLAGS" in
11889 *$cf_add_cflags) #(vi
11892 case $cf_add_cflags in #(vi
11894 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11896 CPPFLAGS=`echo "$CPPFLAGS" | \
11897 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11898 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11902 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
11907 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
11912 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11914 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11916 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11917 && test -z "${cf_tst_cflags}" \
11918 && cf_fix_cppflags=no
11923 if test -n "$cf_new_cflags" ; then
11925 CFLAGS="$CFLAGS $cf_new_cflags"
11928 if test -n "$cf_new_cppflags" ; then
11930 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
11933 if test -n "$cf_new_extra_cppflags" ; then
11935 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
11938 LIBS="$cf_pkgconfig_libs $LIBS"
11940 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists sm; then
11941 test -n "$verbose" && echo " found package sm" 1>&6
11943 echo "${as_me:-configure}:11943: testing found package sm ..." 1>&5
11945 cf_pkgconfig_incs="`$PKG_CONFIG --cflags sm 2>/dev/null`"
11946 cf_pkgconfig_libs="`$PKG_CONFIG --libs sm 2>/dev/null`"
11947 test -n "$verbose" && echo " package sm CFLAGS: $cf_pkgconfig_incs" 1>&6
11949 echo "${as_me:-configure}:11949: testing package sm CFLAGS: $cf_pkgconfig_incs ..." 1>&5
11951 test -n "$verbose" && echo " package sm LIBS: $cf_pkgconfig_libs" 1>&6
11953 echo "${as_me:-configure}:11953: testing package sm LIBS: $cf_pkgconfig_libs ..." 1>&5
11958 cf_new_extra_cppflags=
11960 for cf_add_cflags in $cf_pkgconfig_incs
11962 case $cf_fix_cppflags in
11964 case $cf_add_cflags in #(vi
11965 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
11966 case $cf_add_cflags in
11968 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11970 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11971 && test -z "${cf_tst_cflags}" \
11972 && cf_fix_cppflags=yes
11974 if test $cf_fix_cppflags = yes ; then
11975 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11977 elif test "${cf_tst_cflags}" = "\"'" ; then
11978 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11983 case "$CPPFLAGS" in
11984 *$cf_add_cflags) #(vi
11987 case $cf_add_cflags in #(vi
11989 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11991 CPPFLAGS=`echo "$CPPFLAGS" | \
11992 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11993 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11997 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
12002 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
12007 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
12009 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
12011 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
12012 && test -z "${cf_tst_cflags}" \
12013 && cf_fix_cppflags=no
12018 if test -n "$cf_new_cflags" ; then
12020 CFLAGS="$CFLAGS $cf_new_cflags"
12023 if test -n "$cf_new_cppflags" ; then
12025 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
12028 if test -n "$cf_new_extra_cppflags" ; then
12030 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
12033 LIBS="$cf_pkgconfig_libs $LIBS"
12041 test -n "$verbose" && echo " ...before $LIBS" 1>&6
12043 echo "${as_me:-configure}:12043: testing ...before $LIBS ..." 1>&5
12045 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s,-lXt ,-lXt $X_PRE_LIBS ," -e 's/ / /g'`
12046 test -n "$verbose" && echo " ...after $LIBS" 1>&6
12048 echo "${as_me:-configure}:12048: testing ...after $LIBS ..." 1>&5
12062 LDFLAGS="$X_LIBS $LDFLAGS"
12064 test -n "$verbose" && echo " checking additions to CFLAGS" 1>&6
12066 echo "${as_me:-configure}:12066: testing checking additions to CFLAGS ..." 1>&5
12068 cf_check_cflags="$CFLAGS"
12069 cf_check_cppflags="$CPPFLAGS"
12074 cf_new_extra_cppflags=
12076 for cf_add_cflags in $X_CFLAGS
12078 case $cf_fix_cppflags in
12080 case $cf_add_cflags in #(vi
12081 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
12082 case $cf_add_cflags in
12084 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
12086 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
12087 && test -z "${cf_tst_cflags}" \
12088 && cf_fix_cppflags=yes
12090 if test $cf_fix_cppflags = yes ; then
12091 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
12093 elif test "${cf_tst_cflags}" = "\"'" ; then
12094 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
12099 case "$CPPFLAGS" in
12100 *$cf_add_cflags) #(vi
12103 case $cf_add_cflags in #(vi
12105 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12107 CPPFLAGS=`echo "$CPPFLAGS" | \
12108 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12109 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12113 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
12118 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
12123 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
12125 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
12127 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
12128 && test -z "${cf_tst_cflags}" \
12129 && cf_fix_cppflags=no
12134 if test -n "$cf_new_cflags" ; then
12135 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
12137 echo "${as_me:-configure}:12137: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
12139 CFLAGS="$CFLAGS $cf_new_cflags"
12142 if test -n "$cf_new_cppflags" ; then
12143 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
12145 echo "${as_me:-configure}:12145: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
12147 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
12150 if test -n "$cf_new_extra_cppflags" ; then
12151 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
12153 echo "${as_me:-configure}:12153: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
12155 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
12158 if test "$cf_check_cflags" != "$CFLAGS" ; then
12159 cat >conftest.$ac_ext <<_ACEOF
12160 #line 12160 "configure"
12161 #include "confdefs.h"
12166 printf("Hello world");
12171 rm -f conftest.$ac_objext conftest$ac_exeext
12172 if { (eval echo "$as_me:12172: \"$ac_link\"") >&5
12173 (eval $ac_link) 2>&5
12175 echo "$as_me:12175: \$? = $ac_status" >&5
12176 (exit $ac_status); } &&
12177 { ac_try='test -s conftest$ac_exeext'
12178 { (eval echo "$as_me:12178: \"$ac_try\"") >&5
12179 (eval $ac_try) 2>&5
12181 echo "$as_me:12181: \$? = $ac_status" >&5
12182 (exit $ac_status); }; }; then
12185 echo "$as_me: failed program was:" >&5
12186 cat conftest.$ac_ext >&5
12187 test -n "$verbose" && echo " test-compile failed. Undoing change to \$CFLAGS" 1>&6
12189 echo "${as_me:-configure}:12189: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5
12191 if test "$cf_check_cppflags" != "$CPPFLAGS" ; then
12192 test -n "$verbose" && echo " but keeping change to \$CPPFLAGS" 1>&6
12194 echo "${as_me:-configure}:12194: testing but keeping change to \$CPPFLAGS ..." 1>&5
12197 CFLAGS="$cf_check_flags"
12199 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12202 echo "$as_me:12202: checking for XOpenDisplay" >&5
12203 echo $ECHO_N "checking for XOpenDisplay... $ECHO_C" >&6
12204 if test "${ac_cv_func_XOpenDisplay+set}" = set; then
12205 echo $ECHO_N "(cached) $ECHO_C" >&6
12207 cat >conftest.$ac_ext <<_ACEOF
12208 #line 12208 "configure"
12209 #include "confdefs.h"
12210 /* System header to define __stub macros and hopefully few prototypes,
12211 which can conflict with char XOpenDisplay (); below. */
12212 #include <assert.h>
12213 /* Override any gcc2 internal prototype to avoid an error. */
12217 /* We use char because int might match the return type of a gcc2
12218 builtin and then its argument prototype would still apply. */
12219 char XOpenDisplay ();
12225 /* The GNU C library defines this for functions which it implements
12226 to always fail with ENOSYS. Some functions are actually named
12227 something starting with __ and the normal name is an alias. */
12228 #if defined (__stub_XOpenDisplay) || defined (__stub___XOpenDisplay)
12238 rm -f conftest.$ac_objext conftest$ac_exeext
12239 if { (eval echo "$as_me:12239: \"$ac_link\"") >&5
12240 (eval $ac_link) 2>&5
12242 echo "$as_me:12242: \$? = $ac_status" >&5
12243 (exit $ac_status); } &&
12244 { ac_try='test -s conftest$ac_exeext'
12245 { (eval echo "$as_me:12245: \"$ac_try\"") >&5
12246 (eval $ac_try) 2>&5
12248 echo "$as_me:12248: \$? = $ac_status" >&5
12249 (exit $ac_status); }; }; then
12250 ac_cv_func_XOpenDisplay=yes
12252 echo "$as_me: failed program was:" >&5
12253 cat conftest.$ac_ext >&5
12254 ac_cv_func_XOpenDisplay=no
12256 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12258 echo "$as_me:12258: result: $ac_cv_func_XOpenDisplay" >&5
12259 echo "${ECHO_T}$ac_cv_func_XOpenDisplay" >&6
12260 if test $ac_cv_func_XOpenDisplay = yes; then
12264 echo "$as_me:12264: checking for XOpenDisplay in -lX11" >&5
12265 echo $ECHO_N "checking for XOpenDisplay in -lX11... $ECHO_C" >&6
12266 if test "${ac_cv_lib_X11_XOpenDisplay+set}" = set; then
12267 echo $ECHO_N "(cached) $ECHO_C" >&6
12269 ac_check_lib_save_LIBS=$LIBS
12270 LIBS="-lX11 $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
12271 cat >conftest.$ac_ext <<_ACEOF
12272 #line 12272 "configure"
12273 #include "confdefs.h"
12275 /* Override any gcc2 internal prototype to avoid an error. */
12279 /* We use char because int might match the return type of a gcc2
12280 builtin and then its argument prototype would still apply. */
12281 char XOpenDisplay ();
12290 rm -f conftest.$ac_objext conftest$ac_exeext
12291 if { (eval echo "$as_me:12291: \"$ac_link\"") >&5
12292 (eval $ac_link) 2>&5
12294 echo "$as_me:12294: \$? = $ac_status" >&5
12295 (exit $ac_status); } &&
12296 { ac_try='test -s conftest$ac_exeext'
12297 { (eval echo "$as_me:12297: \"$ac_try\"") >&5
12298 (eval $ac_try) 2>&5
12300 echo "$as_me:12300: \$? = $ac_status" >&5
12301 (exit $ac_status); }; }; then
12302 ac_cv_lib_X11_XOpenDisplay=yes
12304 echo "$as_me: failed program was:" >&5
12305 cat conftest.$ac_ext >&5
12306 ac_cv_lib_X11_XOpenDisplay=no
12308 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12309 LIBS=$ac_check_lib_save_LIBS
12311 echo "$as_me:12311: result: $ac_cv_lib_X11_XOpenDisplay" >&5
12312 echo "${ECHO_T}$ac_cv_lib_X11_XOpenDisplay" >&6
12313 if test $ac_cv_lib_X11_XOpenDisplay = yes; then
12319 echo "$as_me:12319: checking for XtAppInitialize" >&5
12320 echo $ECHO_N "checking for XtAppInitialize... $ECHO_C" >&6
12321 if test "${ac_cv_func_XtAppInitialize+set}" = set; then
12322 echo $ECHO_N "(cached) $ECHO_C" >&6
12324 cat >conftest.$ac_ext <<_ACEOF
12325 #line 12325 "configure"
12326 #include "confdefs.h"
12327 /* System header to define __stub macros and hopefully few prototypes,
12328 which can conflict with char XtAppInitialize (); below. */
12329 #include <assert.h>
12330 /* Override any gcc2 internal prototype to avoid an error. */
12334 /* We use char because int might match the return type of a gcc2
12335 builtin and then its argument prototype would still apply. */
12336 char XtAppInitialize ();
12342 /* The GNU C library defines this for functions which it implements
12343 to always fail with ENOSYS. Some functions are actually named
12344 something starting with __ and the normal name is an alias. */
12345 #if defined (__stub_XtAppInitialize) || defined (__stub___XtAppInitialize)
12348 f = XtAppInitialize;
12355 rm -f conftest.$ac_objext conftest$ac_exeext
12356 if { (eval echo "$as_me:12356: \"$ac_link\"") >&5
12357 (eval $ac_link) 2>&5
12359 echo "$as_me:12359: \$? = $ac_status" >&5
12360 (exit $ac_status); } &&
12361 { ac_try='test -s conftest$ac_exeext'
12362 { (eval echo "$as_me:12362: \"$ac_try\"") >&5
12363 (eval $ac_try) 2>&5
12365 echo "$as_me:12365: \$? = $ac_status" >&5
12366 (exit $ac_status); }; }; then
12367 ac_cv_func_XtAppInitialize=yes
12369 echo "$as_me: failed program was:" >&5
12370 cat conftest.$ac_ext >&5
12371 ac_cv_func_XtAppInitialize=no
12373 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12375 echo "$as_me:12375: result: $ac_cv_func_XtAppInitialize" >&5
12376 echo "${ECHO_T}$ac_cv_func_XtAppInitialize" >&6
12377 if test $ac_cv_func_XtAppInitialize = yes; then
12381 echo "$as_me:12381: checking for XtAppInitialize in -lXt" >&5
12382 echo $ECHO_N "checking for XtAppInitialize in -lXt... $ECHO_C" >&6
12383 if test "${ac_cv_lib_Xt_XtAppInitialize+set}" = set; then
12384 echo $ECHO_N "(cached) $ECHO_C" >&6
12386 ac_check_lib_save_LIBS=$LIBS
12387 LIBS="-lXt $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
12388 cat >conftest.$ac_ext <<_ACEOF
12389 #line 12389 "configure"
12390 #include "confdefs.h"
12392 /* Override any gcc2 internal prototype to avoid an error. */
12396 /* We use char because int might match the return type of a gcc2
12397 builtin and then its argument prototype would still apply. */
12398 char XtAppInitialize ();
12402 XtAppInitialize ();
12407 rm -f conftest.$ac_objext conftest$ac_exeext
12408 if { (eval echo "$as_me:12408: \"$ac_link\"") >&5
12409 (eval $ac_link) 2>&5
12411 echo "$as_me:12411: \$? = $ac_status" >&5
12412 (exit $ac_status); } &&
12413 { ac_try='test -s conftest$ac_exeext'
12414 { (eval echo "$as_me:12414: \"$ac_try\"") >&5
12415 (eval $ac_try) 2>&5
12417 echo "$as_me:12417: \$? = $ac_status" >&5
12418 (exit $ac_status); }; }; then
12419 ac_cv_lib_Xt_XtAppInitialize=yes
12421 echo "$as_me: failed program was:" >&5
12422 cat conftest.$ac_ext >&5
12423 ac_cv_lib_Xt_XtAppInitialize=no
12425 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12426 LIBS=$ac_check_lib_save_LIBS
12428 echo "$as_me:12428: result: $ac_cv_lib_Xt_XtAppInitialize" >&5
12429 echo "${ECHO_T}$ac_cv_lib_Xt_XtAppInitialize" >&6
12430 if test $ac_cv_lib_Xt_XtAppInitialize = yes; then
12431 cat >>confdefs.h <<\EOF
12432 #define HAVE_LIBXT 1
12436 LIBS="-lXt $X_PRE_LIBS $LIBS $X_EXTRA_LIBS"
12443 if test $cf_have_X_LIBS = no ; then
12444 { echo "$as_me:12444: WARNING: Unable to successfully link X Toolkit library (-lXt) with
12445 test program. You will have to check and add the proper libraries by hand
12447 echo "$as_me: WARNING: Unable to successfully link X Toolkit library (-lXt) with
12448 test program. You will have to check and add the proper libraries by hand
12449 to makefile." >&2;}
12452 cf_x_athena_root=$cf_x_athena
12455 for cf_path in default \
12456 /usr/contrib/X11R6 \
12457 /usr/contrib/X11R5 \
12461 if test -z "$cf_x_athena_inc" ; then
12462 cf_save="$CPPFLAGS"
12463 cf_test=X11/$cf_x_athena_root/SimpleMenu.h
12464 if test $cf_path != default ; then
12465 CPPFLAGS="$cf_save -I$cf_path/include"
12466 echo "$as_me:12466: checking for $cf_test in $cf_path" >&5
12467 echo $ECHO_N "checking for $cf_test in $cf_path... $ECHO_C" >&6
12469 echo "$as_me:12469: checking for $cf_test" >&5
12470 echo $ECHO_N "checking for $cf_test... $ECHO_C" >&6
12472 cat >conftest.$ac_ext <<_ACEOF
12473 #line 12473 "configure"
12474 #include "confdefs.h"
12476 #include <X11/Intrinsic.h>
12477 #include <$cf_test>
12486 rm -f conftest.$ac_objext
12487 if { (eval echo "$as_me:12487: \"$ac_compile\"") >&5
12488 (eval $ac_compile) 2>&5
12490 echo "$as_me:12490: \$? = $ac_status" >&5
12491 (exit $ac_status); } &&
12492 { ac_try='test -s conftest.$ac_objext'
12493 { (eval echo "$as_me:12493: \"$ac_try\"") >&5
12494 (eval $ac_try) 2>&5
12496 echo "$as_me:12496: \$? = $ac_status" >&5
12497 (exit $ac_status); }; }; then
12500 echo "$as_me: failed program was:" >&5
12501 cat conftest.$ac_ext >&5
12504 rm -f conftest.$ac_objext conftest.$ac_ext
12505 echo "$as_me:12505: result: $cf_result" >&5
12506 echo "${ECHO_T}$cf_result" >&6
12507 if test "$cf_result" = yes ; then
12508 cf_x_athena_inc=$cf_path
12511 CPPFLAGS="$cf_save"
12516 if test -z "$cf_x_athena_inc" ; then
12517 { echo "$as_me:12517: WARNING: Unable to successfully find Athena header files with test program" >&5
12518 echo "$as_me: WARNING: Unable to successfully find Athena header files with test program" >&2;}
12519 elif test "$cf_x_athena_inc" != default ; then
12520 CPPFLAGS="$CPPFLAGS -I$cf_x_athena_inc"
12523 cf_x_athena_root=$cf_x_athena
12526 for cf_path in default \
12527 /usr/contrib/X11R6 \
12528 /usr/contrib/X11R5 \
12533 ${cf_x_athena_root} \
12534 ${cf_x_athena_root}7 \
12535 ${cf_x_athena_root}6
12538 "-l$cf_lib -lXmu" \
12539 "-l$cf_lib -lXpm -lXmu" \
12540 "-l${cf_lib}_s -lXmu_s"
12542 if test -z "$cf_x_athena_lib" ; then
12544 cf_test=XawSimpleMenuAddGlobalActions
12545 if test $cf_path != default ; then
12546 LIBS="-L$cf_path/lib $cf_libs $LIBS"
12547 echo "$as_me:12547: checking for $cf_libs in $cf_path" >&5
12548 echo $ECHO_N "checking for $cf_libs in $cf_path... $ECHO_C" >&6
12550 LIBS="$cf_libs $LIBS"
12551 echo "$as_me:12551: checking for $cf_test in $cf_libs" >&5
12552 echo $ECHO_N "checking for $cf_test in $cf_libs... $ECHO_C" >&6
12554 cat >conftest.$ac_ext <<_ACEOF
12555 #line 12555 "configure"
12556 #include "confdefs.h"
12558 #include <X11/Intrinsic.h>
12559 #include <X11/$cf_x_athena_root/SimpleMenu.h>
12565 $cf_test((XtAppContext) 0)
12570 rm -f conftest.$ac_objext conftest$ac_exeext
12571 if { (eval echo "$as_me:12571: \"$ac_link\"") >&5
12572 (eval $ac_link) 2>&5
12574 echo "$as_me:12574: \$? = $ac_status" >&5
12575 (exit $ac_status); } &&
12576 { ac_try='test -s conftest$ac_exeext'
12577 { (eval echo "$as_me:12577: \"$ac_try\"") >&5
12578 (eval $ac_try) 2>&5
12580 echo "$as_me:12580: \$? = $ac_status" >&5
12581 (exit $ac_status); }; }; then
12584 echo "$as_me: failed program was:" >&5
12585 cat conftest.$ac_ext >&5
12588 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12589 echo "$as_me:12589: result: $cf_result" >&5
12590 echo "${ECHO_T}$cf_result" >&6
12591 if test "$cf_result" = yes ; then
12592 cf_x_athena_lib="$cf_libs"
12598 test -n "$cf_x_athena_lib" && break
12602 if test -z "$cf_x_athena_lib" ; then
12603 { { echo "$as_me:12603: error: Unable to successfully link Athena library (-l$cf_x_athena_root) with test program" >&5
12604 echo "$as_me: error: Unable to successfully link Athena library (-l$cf_x_athena_root) with test program" >&2;}
12605 { (exit 1); exit 1; }; }
12608 cf_x_athena_LIBS=`echo "HAVE_LIB_$cf_x_athena" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
12610 cat >>confdefs.h <<EOF
12611 #define $cf_x_athena_LIBS 1
12616 if test -n "$ac_tool_prefix"; then
12617 for ac_prog in xcurses-config
12619 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
12620 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
12621 echo "$as_me:12621: checking for $ac_word" >&5
12622 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
12623 if test "${ac_cv_prog_XCURSES_CONFIG+set}" = set; then
12624 echo $ECHO_N "(cached) $ECHO_C" >&6
12626 if test -n "$XCURSES_CONFIG"; then
12627 ac_cv_prog_XCURSES_CONFIG="$XCURSES_CONFIG" # Let the user override the test.
12629 ac_save_IFS=$IFS; IFS=$ac_path_separator
12631 for ac_dir in $ac_dummy; do
12633 test -z "$ac_dir" && ac_dir=.
12634 $as_executable_p "$ac_dir/$ac_word" || continue
12635 ac_cv_prog_XCURSES_CONFIG="$ac_tool_prefix$ac_prog"
12636 echo "$as_me:12636: found $ac_dir/$ac_word" >&5
12642 XCURSES_CONFIG=$ac_cv_prog_XCURSES_CONFIG
12643 if test -n "$XCURSES_CONFIG"; then
12644 echo "$as_me:12644: result: $XCURSES_CONFIG" >&5
12645 echo "${ECHO_T}$XCURSES_CONFIG" >&6
12647 echo "$as_me:12647: result: no" >&5
12648 echo "${ECHO_T}no" >&6
12651 test -n "$XCURSES_CONFIG" && break
12654 if test -z "$XCURSES_CONFIG"; then
12655 ac_ct_XCURSES_CONFIG=$XCURSES_CONFIG
12656 for ac_prog in xcurses-config
12658 # Extract the first word of "$ac_prog", so it can be a program name with args.
12659 set dummy $ac_prog; ac_word=$2
12660 echo "$as_me:12660: checking for $ac_word" >&5
12661 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
12662 if test "${ac_cv_prog_ac_ct_XCURSES_CONFIG+set}" = set; then
12663 echo $ECHO_N "(cached) $ECHO_C" >&6
12665 if test -n "$ac_ct_XCURSES_CONFIG"; then
12666 ac_cv_prog_ac_ct_XCURSES_CONFIG="$ac_ct_XCURSES_CONFIG" # Let the user override the test.
12668 ac_save_IFS=$IFS; IFS=$ac_path_separator
12670 for ac_dir in $ac_dummy; do
12672 test -z "$ac_dir" && ac_dir=.
12673 $as_executable_p "$ac_dir/$ac_word" || continue
12674 ac_cv_prog_ac_ct_XCURSES_CONFIG="$ac_prog"
12675 echo "$as_me:12675: found $ac_dir/$ac_word" >&5
12681 ac_ct_XCURSES_CONFIG=$ac_cv_prog_ac_ct_XCURSES_CONFIG
12682 if test -n "$ac_ct_XCURSES_CONFIG"; then
12683 echo "$as_me:12683: result: $ac_ct_XCURSES_CONFIG" >&5
12684 echo "${ECHO_T}$ac_ct_XCURSES_CONFIG" >&6
12686 echo "$as_me:12686: result: no" >&5
12687 echo "${ECHO_T}no" >&6
12690 test -n "$ac_ct_XCURSES_CONFIG" && break
12692 test -n "$ac_ct_XCURSES_CONFIG" || ac_ct_XCURSES_CONFIG="none"
12694 XCURSES_CONFIG=$ac_ct_XCURSES_CONFIG
12697 if test "$XCURSES_CONFIG" != none ; then
12699 CPPFLAGS="$CPPFLAGS `$XCURSES_CONFIG --cflags`"
12700 LIBS="`$XCURSES_CONFIG --libs` $LIBS"
12702 cf_cv_lib_XCurses=yes
12706 LDFLAGS="$LDFLAGS $X_LIBS"
12708 test -n "$verbose" && echo " checking additions to CFLAGS" 1>&6
12710 echo "${as_me:-configure}:12710: testing checking additions to CFLAGS ..." 1>&5
12712 cf_check_cflags="$CFLAGS"
12713 cf_check_cppflags="$CPPFLAGS"
12718 cf_new_extra_cppflags=
12720 for cf_add_cflags in $X_CFLAGS
12722 case $cf_fix_cppflags in
12724 case $cf_add_cflags in #(vi
12725 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
12726 case $cf_add_cflags in
12728 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
12730 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
12731 && test -z "${cf_tst_cflags}" \
12732 && cf_fix_cppflags=yes
12734 if test $cf_fix_cppflags = yes ; then
12735 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
12737 elif test "${cf_tst_cflags}" = "\"'" ; then
12738 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
12743 case "$CPPFLAGS" in
12744 *$cf_add_cflags) #(vi
12747 case $cf_add_cflags in #(vi
12749 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12751 CPPFLAGS=`echo "$CPPFLAGS" | \
12752 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12753 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12757 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
12762 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
12767 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
12769 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
12771 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
12772 && test -z "${cf_tst_cflags}" \
12773 && cf_fix_cppflags=no
12778 if test -n "$cf_new_cflags" ; then
12779 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
12781 echo "${as_me:-configure}:12781: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
12783 CFLAGS="$CFLAGS $cf_new_cflags"
12786 if test -n "$cf_new_cppflags" ; then
12787 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
12789 echo "${as_me:-configure}:12789: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
12791 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
12794 if test -n "$cf_new_extra_cppflags" ; then
12795 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
12797 echo "${as_me:-configure}:12797: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
12799 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
12802 if test "$cf_check_cflags" != "$CFLAGS" ; then
12803 cat >conftest.$ac_ext <<_ACEOF
12804 #line 12804 "configure"
12805 #include "confdefs.h"
12810 printf("Hello world");
12815 rm -f conftest.$ac_objext conftest$ac_exeext
12816 if { (eval echo "$as_me:12816: \"$ac_link\"") >&5
12817 (eval $ac_link) 2>&5
12819 echo "$as_me:12819: \$? = $ac_status" >&5
12820 (exit $ac_status); } &&
12821 { ac_try='test -s conftest$ac_exeext'
12822 { (eval echo "$as_me:12822: \"$ac_try\"") >&5
12823 (eval $ac_try) 2>&5
12825 echo "$as_me:12825: \$? = $ac_status" >&5
12826 (exit $ac_status); }; }; then
12829 echo "$as_me: failed program was:" >&5
12830 cat conftest.$ac_ext >&5
12831 test -n "$verbose" && echo " test-compile failed. Undoing change to \$CFLAGS" 1>&6
12833 echo "${as_me:-configure}:12833: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5
12835 if test "$cf_check_cppflags" != "$CPPFLAGS" ; then
12836 test -n "$verbose" && echo " but keeping change to \$CPPFLAGS" 1>&6
12838 echo "${as_me:-configure}:12838: testing but keeping change to \$CPPFLAGS ..." 1>&5
12841 CFLAGS="$cf_check_flags"
12843 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12846 echo "$as_me:12846: checking for XOpenDisplay in -lX11" >&5
12847 echo $ECHO_N "checking for XOpenDisplay in -lX11... $ECHO_C" >&6
12848 if test "${ac_cv_lib_X11_XOpenDisplay+set}" = set; then
12849 echo $ECHO_N "(cached) $ECHO_C" >&6
12851 ac_check_lib_save_LIBS=$LIBS
12852 LIBS="-lX11 $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
12853 cat >conftest.$ac_ext <<_ACEOF
12854 #line 12854 "configure"
12855 #include "confdefs.h"
12857 /* Override any gcc2 internal prototype to avoid an error. */
12861 /* We use char because int might match the return type of a gcc2
12862 builtin and then its argument prototype would still apply. */
12863 char XOpenDisplay ();
12872 rm -f conftest.$ac_objext conftest$ac_exeext
12873 if { (eval echo "$as_me:12873: \"$ac_link\"") >&5
12874 (eval $ac_link) 2>&5
12876 echo "$as_me:12876: \$? = $ac_status" >&5
12877 (exit $ac_status); } &&
12878 { ac_try='test -s conftest$ac_exeext'
12879 { (eval echo "$as_me:12879: \"$ac_try\"") >&5
12880 (eval $ac_try) 2>&5
12882 echo "$as_me:12882: \$? = $ac_status" >&5
12883 (exit $ac_status); }; }; then
12884 ac_cv_lib_X11_XOpenDisplay=yes
12886 echo "$as_me: failed program was:" >&5
12887 cat conftest.$ac_ext >&5
12888 ac_cv_lib_X11_XOpenDisplay=no
12890 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12891 LIBS=$ac_check_lib_save_LIBS
12893 echo "$as_me:12893: result: $ac_cv_lib_X11_XOpenDisplay" >&5
12894 echo "${ECHO_T}$ac_cv_lib_X11_XOpenDisplay" >&6
12895 if test $ac_cv_lib_X11_XOpenDisplay = yes; then
12899 echo "$as_me:12899: checking for XCurses library" >&5
12900 echo $ECHO_N "checking for XCurses library... $ECHO_C" >&6
12901 if test "${cf_cv_lib_XCurses+set}" = set; then
12902 echo $ECHO_N "(cached) $ECHO_C" >&6
12905 LIBS="-lXCurses $LIBS"
12906 cat >conftest.$ac_ext <<_ACEOF
12907 #line 12907 "configure"
12908 #include "confdefs.h"
12910 #include <xcurses.h>
12911 char *XCursesProgramName = "test";
12921 rm -f conftest.$ac_objext conftest$ac_exeext
12922 if { (eval echo "$as_me:12922: \"$ac_link\"") >&5
12923 (eval $ac_link) 2>&5
12925 echo "$as_me:12925: \$? = $ac_status" >&5
12926 (exit $ac_status); } &&
12927 { ac_try='test -s conftest$ac_exeext'
12928 { (eval echo "$as_me:12928: \"$ac_try\"") >&5
12929 (eval $ac_try) 2>&5
12931 echo "$as_me:12931: \$? = $ac_status" >&5
12932 (exit $ac_status); }; }; then
12933 cf_cv_lib_XCurses=yes
12935 echo "$as_me: failed program was:" >&5
12936 cat conftest.$ac_ext >&5
12937 cf_cv_lib_XCurses=no
12939 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12942 echo "$as_me:12942: result: $cf_cv_lib_XCurses" >&5
12943 echo "${ECHO_T}$cf_cv_lib_XCurses" >&6
12947 if test $cf_cv_lib_XCurses = yes ; then
12948 cat >>confdefs.h <<\EOF
12952 cat >>confdefs.h <<\EOF
12956 echo "$as_me:12956: checking for xcurses.h" >&5
12957 echo $ECHO_N "checking for xcurses.h... $ECHO_C" >&6
12958 if test "${ac_cv_header_xcurses_h+set}" = set; then
12959 echo $ECHO_N "(cached) $ECHO_C" >&6
12961 cat >conftest.$ac_ext <<_ACEOF
12962 #line 12962 "configure"
12963 #include "confdefs.h"
12964 #include <xcurses.h>
12966 if { (eval echo "$as_me:12966: \"$ac_cpp conftest.$ac_ext\"") >&5
12967 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12969 egrep -v '^ *\+' conftest.er1 >conftest.err
12971 cat conftest.err >&5
12972 echo "$as_me:12972: \$? = $ac_status" >&5
12973 (exit $ac_status); } >/dev/null; then
12974 if test -s conftest.err; then
12975 ac_cpp_err=$ac_c_preproc_warn_flag
12982 if test -z "$ac_cpp_err"; then
12983 ac_cv_header_xcurses_h=yes
12985 echo "$as_me: failed program was:" >&5
12986 cat conftest.$ac_ext >&5
12987 ac_cv_header_xcurses_h=no
12989 rm -f conftest.err conftest.$ac_ext
12991 echo "$as_me:12991: result: $ac_cv_header_xcurses_h" >&5
12992 echo "${ECHO_T}$ac_cv_header_xcurses_h" >&6
12993 if test $ac_cv_header_xcurses_h = yes; then
12994 cat >>confdefs.h <<\EOF
12995 #define HAVE_XCURSES 1
13001 { { echo "$as_me:13001: error: Cannot link with XCurses" >&5
13002 echo "$as_me: error: Cannot link with XCurses" >&2;}
13003 { (exit 1); exit 1; }; }
13009 case $cf_cv_screen in
13012 echo "$as_me:13012: checking for NetBSD form.h" >&5
13013 echo $ECHO_N "checking for NetBSD form.h... $ECHO_C" >&6
13014 if test "${cf_cv_netbsd_form_h+set}" = set; then
13015 echo $ECHO_N "(cached) $ECHO_C" >&6
13018 cat >conftest.$ac_ext <<_ACEOF
13019 #line 13019 "configure"
13020 #include "confdefs.h"
13022 #include <${cf_cv_ncurses_header:-curses.h}>
13030 int y = current_field(form)->cursor_ypos;
13031 int x = current_field(form)->cursor_xpos;
13037 rm -f conftest.$ac_objext
13038 if { (eval echo "$as_me:13038: \"$ac_compile\"") >&5
13039 (eval $ac_compile) 2>&5
13041 echo "$as_me:13041: \$? = $ac_status" >&5
13042 (exit $ac_status); } &&
13043 { ac_try='test -s conftest.$ac_objext'
13044 { (eval echo "$as_me:13044: \"$ac_try\"") >&5
13045 (eval $ac_try) 2>&5
13047 echo "$as_me:13047: \$? = $ac_status" >&5
13048 (exit $ac_status); }; }; then
13049 cf_cv_netbsd_form_h=yes
13052 echo "$as_me: failed program was:" >&5
13053 cat conftest.$ac_ext >&5
13054 cf_cv_netbsd_form_h=no
13056 rm -f conftest.$ac_objext conftest.$ac_ext
13059 echo "$as_me:13059: result: $cf_cv_netbsd_form_h" >&5
13060 echo "${ECHO_T}$cf_cv_netbsd_form_h" >&6
13062 test "$cf_cv_netbsd_form_h" = yes && cat >>confdefs.h <<\EOF
13063 #define HAVE_NETBSD_FORM_H 1
13066 echo "$as_me:13066: checking for NetBSD menu.h" >&5
13067 echo $ECHO_N "checking for NetBSD menu.h... $ECHO_C" >&6
13068 if test "${cf_cv_netbsd_menu_h+set}" = set; then
13069 echo $ECHO_N "(cached) $ECHO_C" >&6
13072 cat >conftest.$ac_ext <<_ACEOF
13073 #line 13073 "configure"
13074 #include "confdefs.h"
13076 #include <${cf_cv_ncurses_header:-curses.h}>
13084 int y = menu->max_item_width;
13090 rm -f conftest.$ac_objext
13091 if { (eval echo "$as_me:13091: \"$ac_compile\"") >&5
13092 (eval $ac_compile) 2>&5
13094 echo "$as_me:13094: \$? = $ac_status" >&5
13095 (exit $ac_status); } &&
13096 { ac_try='test -s conftest.$ac_objext'
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_netbsd_menu_h=yes
13105 echo "$as_me: failed program was:" >&5
13106 cat conftest.$ac_ext >&5
13107 cf_cv_netbsd_menu_h=no
13109 rm -f conftest.$ac_objext conftest.$ac_ext
13112 echo "$as_me:13112: result: $cf_cv_netbsd_menu_h" >&5
13113 echo "${ECHO_T}$cf_cv_netbsd_menu_h" >&6
13115 test "$cf_cv_netbsd_menu_h" = yes && cat >>confdefs.h <<\EOF
13116 #define HAVE_NETBSD_MENU_H 1
13125 case $cf_cv_screen in #(vi
13129 # look for curses-related libraries
13131 as_ac_Lib=`echo "ac_cv_lib_panel$cf_cv_libtype''_new_panel" | $as_tr_sh`
13132 echo "$as_me:13132: checking for new_panel in -lpanel$cf_cv_libtype" >&5
13133 echo $ECHO_N "checking for new_panel in -lpanel$cf_cv_libtype... $ECHO_C" >&6
13134 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
13135 echo $ECHO_N "(cached) $ECHO_C" >&6
13137 ac_check_lib_save_LIBS=$LIBS
13138 LIBS="-lpanel$cf_cv_libtype $LIBS"
13139 cat >conftest.$ac_ext <<_ACEOF
13140 #line 13140 "configure"
13141 #include "confdefs.h"
13143 /* Override any gcc2 internal prototype to avoid an error. */
13147 /* We use char because int might match the return type of a gcc2
13148 builtin and then its argument prototype would still apply. */
13158 rm -f conftest.$ac_objext conftest$ac_exeext
13159 if { (eval echo "$as_me:13159: \"$ac_link\"") >&5
13160 (eval $ac_link) 2>&5
13162 echo "$as_me:13162: \$? = $ac_status" >&5
13163 (exit $ac_status); } &&
13164 { ac_try='test -s conftest$ac_exeext'
13165 { (eval echo "$as_me:13165: \"$ac_try\"") >&5
13166 (eval $ac_try) 2>&5
13168 echo "$as_me:13168: \$? = $ac_status" >&5
13169 (exit $ac_status); }; }; then
13170 eval "$as_ac_Lib=yes"
13172 echo "$as_me: failed program was:" >&5
13173 cat conftest.$ac_ext >&5
13174 eval "$as_ac_Lib=no"
13176 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13177 LIBS=$ac_check_lib_save_LIBS
13179 echo "$as_me:13179: result: `eval echo '${'$as_ac_Lib'}'`" >&5
13180 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
13181 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
13182 cat >>confdefs.h <<EOF
13183 #define `echo "HAVE_LIBpanel$cf_cv_libtype" | $as_tr_cpp` 1
13186 LIBS="-lpanel$cf_cv_libtype $LIBS"
13190 as_ac_Lib=`echo "ac_cv_lib_menu$cf_cv_libtype''_menu_driver" | $as_tr_sh`
13191 echo "$as_me:13191: checking for menu_driver in -lmenu$cf_cv_libtype" >&5
13192 echo $ECHO_N "checking for menu_driver in -lmenu$cf_cv_libtype... $ECHO_C" >&6
13193 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
13194 echo $ECHO_N "(cached) $ECHO_C" >&6
13196 ac_check_lib_save_LIBS=$LIBS
13197 LIBS="-lmenu$cf_cv_libtype $LIBS"
13198 cat >conftest.$ac_ext <<_ACEOF
13199 #line 13199 "configure"
13200 #include "confdefs.h"
13202 /* Override any gcc2 internal prototype to avoid an error. */
13206 /* We use char because int might match the return type of a gcc2
13207 builtin and then its argument prototype would still apply. */
13208 char menu_driver ();
13217 rm -f conftest.$ac_objext conftest$ac_exeext
13218 if { (eval echo "$as_me:13218: \"$ac_link\"") >&5
13219 (eval $ac_link) 2>&5
13221 echo "$as_me:13221: \$? = $ac_status" >&5
13222 (exit $ac_status); } &&
13223 { ac_try='test -s conftest$ac_exeext'
13224 { (eval echo "$as_me:13224: \"$ac_try\"") >&5
13225 (eval $ac_try) 2>&5
13227 echo "$as_me:13227: \$? = $ac_status" >&5
13228 (exit $ac_status); }; }; then
13229 eval "$as_ac_Lib=yes"
13231 echo "$as_me: failed program was:" >&5
13232 cat conftest.$ac_ext >&5
13233 eval "$as_ac_Lib=no"
13235 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13236 LIBS=$ac_check_lib_save_LIBS
13238 echo "$as_me:13238: result: `eval echo '${'$as_ac_Lib'}'`" >&5
13239 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
13240 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
13241 cat >>confdefs.h <<EOF
13242 #define `echo "HAVE_LIBmenu$cf_cv_libtype" | $as_tr_cpp` 1
13245 LIBS="-lmenu$cf_cv_libtype $LIBS"
13249 as_ac_Lib=`echo "ac_cv_lib_form$cf_cv_libtype''_form_driver" | $as_tr_sh`
13250 echo "$as_me:13250: checking for form_driver in -lform$cf_cv_libtype" >&5
13251 echo $ECHO_N "checking for form_driver in -lform$cf_cv_libtype... $ECHO_C" >&6
13252 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
13253 echo $ECHO_N "(cached) $ECHO_C" >&6
13255 ac_check_lib_save_LIBS=$LIBS
13256 LIBS="-lform$cf_cv_libtype $LIBS"
13257 cat >conftest.$ac_ext <<_ACEOF
13258 #line 13258 "configure"
13259 #include "confdefs.h"
13261 /* Override any gcc2 internal prototype to avoid an error. */
13265 /* We use char because int might match the return type of a gcc2
13266 builtin and then its argument prototype would still apply. */
13267 char form_driver ();
13276 rm -f conftest.$ac_objext conftest$ac_exeext
13277 if { (eval echo "$as_me:13277: \"$ac_link\"") >&5
13278 (eval $ac_link) 2>&5
13280 echo "$as_me:13280: \$? = $ac_status" >&5
13281 (exit $ac_status); } &&
13282 { ac_try='test -s conftest$ac_exeext'
13283 { (eval echo "$as_me:13283: \"$ac_try\"") >&5
13284 (eval $ac_try) 2>&5
13286 echo "$as_me:13286: \$? = $ac_status" >&5
13287 (exit $ac_status); }; }; then
13288 eval "$as_ac_Lib=yes"
13290 echo "$as_me: failed program was:" >&5
13291 cat conftest.$ac_ext >&5
13292 eval "$as_ac_Lib=no"
13294 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13295 LIBS=$ac_check_lib_save_LIBS
13297 echo "$as_me:13297: result: `eval echo '${'$as_ac_Lib'}'`" >&5
13298 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
13299 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
13300 cat >>confdefs.h <<EOF
13301 #define `echo "HAVE_LIBform$cf_cv_libtype" | $as_tr_cpp` 1
13304 LIBS="-lform$cf_cv_libtype $LIBS"
13308 # look for curses-related headers
13319 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
13320 echo "$as_me:13320: checking for $ac_header" >&5
13321 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13322 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13323 echo $ECHO_N "(cached) $ECHO_C" >&6
13325 cat >conftest.$ac_ext <<_ACEOF
13326 #line 13326 "configure"
13327 #include "confdefs.h"
13328 #include <$ac_header>
13330 if { (eval echo "$as_me:13330: \"$ac_cpp conftest.$ac_ext\"") >&5
13331 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13333 egrep -v '^ *\+' conftest.er1 >conftest.err
13335 cat conftest.err >&5
13336 echo "$as_me:13336: \$? = $ac_status" >&5
13337 (exit $ac_status); } >/dev/null; then
13338 if test -s conftest.err; then
13339 ac_cpp_err=$ac_c_preproc_warn_flag
13346 if test -z "$ac_cpp_err"; then
13347 eval "$as_ac_Header=yes"
13349 echo "$as_me: failed program was:" >&5
13350 cat conftest.$ac_ext >&5
13351 eval "$as_ac_Header=no"
13353 rm -f conftest.err conftest.$ac_ext
13355 echo "$as_me:13355: result: `eval echo '${'$as_ac_Header'}'`" >&5
13356 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13357 if test `eval echo '${'$as_ac_Header'}'` = yes; then
13358 cat >>confdefs.h <<EOF
13359 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
13368 echo "$as_me:13368: checking return type of signal handlers" >&5
13369 echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6
13370 if test "${ac_cv_type_signal+set}" = set; then
13371 echo $ECHO_N "(cached) $ECHO_C" >&6
13373 cat >conftest.$ac_ext <<_ACEOF
13374 #line 13374 "configure"
13375 #include "confdefs.h"
13376 #include <sys/types.h>
13377 #include <signal.h>
13382 extern "C" void (*signal (int, void (*)(int)))(int);
13384 void (*signal ()) ();
13395 rm -f conftest.$ac_objext
13396 if { (eval echo "$as_me:13396: \"$ac_compile\"") >&5
13397 (eval $ac_compile) 2>&5
13399 echo "$as_me:13399: \$? = $ac_status" >&5
13400 (exit $ac_status); } &&
13401 { ac_try='test -s conftest.$ac_objext'
13402 { (eval echo "$as_me:13402: \"$ac_try\"") >&5
13403 (eval $ac_try) 2>&5
13405 echo "$as_me:13405: \$? = $ac_status" >&5
13406 (exit $ac_status); }; }; then
13407 ac_cv_type_signal=void
13409 echo "$as_me: failed program was:" >&5
13410 cat conftest.$ac_ext >&5
13411 ac_cv_type_signal=int
13413 rm -f conftest.$ac_objext conftest.$ac_ext
13415 echo "$as_me:13415: result: $ac_cv_type_signal" >&5
13416 echo "${ECHO_T}$ac_cv_type_signal" >&6
13418 cat >>confdefs.h <<EOF
13419 #define RETSIGTYPE $ac_cv_type_signal
13422 echo "$as_me:13422: checking for ANSI C header files" >&5
13423 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
13424 if test "${ac_cv_header_stdc+set}" = set; then
13425 echo $ECHO_N "(cached) $ECHO_C" >&6
13427 cat >conftest.$ac_ext <<_ACEOF
13428 #line 13428 "configure"
13429 #include "confdefs.h"
13430 #include <stdlib.h>
13431 #include <stdarg.h>
13432 #include <string.h>
13436 if { (eval echo "$as_me:13436: \"$ac_cpp conftest.$ac_ext\"") >&5
13437 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13439 egrep -v '^ *\+' conftest.er1 >conftest.err
13441 cat conftest.err >&5
13442 echo "$as_me:13442: \$? = $ac_status" >&5
13443 (exit $ac_status); } >/dev/null; then
13444 if test -s conftest.err; then
13445 ac_cpp_err=$ac_c_preproc_warn_flag
13452 if test -z "$ac_cpp_err"; then
13453 ac_cv_header_stdc=yes
13455 echo "$as_me: failed program was:" >&5
13456 cat conftest.$ac_ext >&5
13457 ac_cv_header_stdc=no
13459 rm -f conftest.err conftest.$ac_ext
13461 if test $ac_cv_header_stdc = yes; then
13462 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
13463 cat >conftest.$ac_ext <<_ACEOF
13464 #line 13464 "configure"
13465 #include "confdefs.h"
13466 #include <string.h>
13469 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13470 egrep "memchr" >/dev/null 2>&1; then
13473 ac_cv_header_stdc=no
13479 if test $ac_cv_header_stdc = yes; then
13480 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
13481 cat >conftest.$ac_ext <<_ACEOF
13482 #line 13482 "configure"
13483 #include "confdefs.h"
13484 #include <stdlib.h>
13487 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13488 egrep "free" >/dev/null 2>&1; then
13491 ac_cv_header_stdc=no
13497 if test $ac_cv_header_stdc = yes; then
13498 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
13499 if test "$cross_compiling" = yes; then
13502 cat >conftest.$ac_ext <<_ACEOF
13503 #line 13503 "configure"
13504 #include "confdefs.h"
13506 #if ((' ' & 0x0FF) == 0x020)
13507 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
13508 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
13510 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
13511 || ('j' <= (c) && (c) <= 'r') \
13512 || ('s' <= (c) && (c) <= 'z'))
13513 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
13516 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
13521 for (i = 0; i < 256; i++)
13522 if (XOR (islower (i), ISLOWER (i))
13523 || toupper (i) != TOUPPER (i))
13524 $ac_main_return(2);
13525 $ac_main_return (0);
13528 rm -f conftest$ac_exeext
13529 if { (eval echo "$as_me:13529: \"$ac_link\"") >&5
13530 (eval $ac_link) 2>&5
13532 echo "$as_me:13532: \$? = $ac_status" >&5
13533 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13534 { (eval echo "$as_me:13534: \"$ac_try\"") >&5
13535 (eval $ac_try) 2>&5
13537 echo "$as_me:13537: \$? = $ac_status" >&5
13538 (exit $ac_status); }; }; then
13541 echo "$as_me: program exited with status $ac_status" >&5
13542 echo "$as_me: failed program was:" >&5
13543 cat conftest.$ac_ext >&5
13544 ac_cv_header_stdc=no
13546 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13550 echo "$as_me:13550: result: $ac_cv_header_stdc" >&5
13551 echo "${ECHO_T}$ac_cv_header_stdc" >&6
13552 if test $ac_cv_header_stdc = yes; then
13554 cat >>confdefs.h <<\EOF
13555 #define STDC_HEADERS 1
13560 echo "$as_me:13560: checking whether time.h and sys/time.h may both be included" >&5
13561 echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
13562 if test "${ac_cv_header_time+set}" = set; then
13563 echo $ECHO_N "(cached) $ECHO_C" >&6
13565 cat >conftest.$ac_ext <<_ACEOF
13566 #line 13566 "configure"
13567 #include "confdefs.h"
13568 #include <sys/types.h>
13569 #include <sys/time.h>
13575 if ((struct tm *) 0)
13581 rm -f conftest.$ac_objext
13582 if { (eval echo "$as_me:13582: \"$ac_compile\"") >&5
13583 (eval $ac_compile) 2>&5
13585 echo "$as_me:13585: \$? = $ac_status" >&5
13586 (exit $ac_status); } &&
13587 { ac_try='test -s conftest.$ac_objext'
13588 { (eval echo "$as_me:13588: \"$ac_try\"") >&5
13589 (eval $ac_try) 2>&5
13591 echo "$as_me:13591: \$? = $ac_status" >&5
13592 (exit $ac_status); }; }; then
13593 ac_cv_header_time=yes
13595 echo "$as_me: failed program was:" >&5
13596 cat conftest.$ac_ext >&5
13597 ac_cv_header_time=no
13599 rm -f conftest.$ac_objext conftest.$ac_ext
13601 echo "$as_me:13601: result: $ac_cv_header_time" >&5
13602 echo "${ECHO_T}$ac_cv_header_time" >&6
13603 if test $ac_cv_header_time = yes; then
13605 cat >>confdefs.h <<\EOF
13606 #define TIME_WITH_SYS_TIME 1
13623 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
13624 echo "$as_me:13624: checking for $ac_header" >&5
13625 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13626 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13627 echo $ECHO_N "(cached) $ECHO_C" >&6
13629 cat >conftest.$ac_ext <<_ACEOF
13630 #line 13630 "configure"
13631 #include "confdefs.h"
13632 #include <$ac_header>
13634 if { (eval echo "$as_me:13634: \"$ac_cpp conftest.$ac_ext\"") >&5
13635 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13637 egrep -v '^ *\+' conftest.er1 >conftest.err
13639 cat conftest.err >&5
13640 echo "$as_me:13640: \$? = $ac_status" >&5
13641 (exit $ac_status); } >/dev/null; then
13642 if test -s conftest.err; then
13643 ac_cpp_err=$ac_c_preproc_warn_flag
13650 if test -z "$ac_cpp_err"; then
13651 eval "$as_ac_Header=yes"
13653 echo "$as_me: failed program was:" >&5
13654 cat conftest.$ac_ext >&5
13655 eval "$as_ac_Header=no"
13657 rm -f conftest.err conftest.$ac_ext
13659 echo "$as_me:13659: result: `eval echo '${'$as_ac_Header'}'`" >&5
13660 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13661 if test `eval echo '${'$as_ac_Header'}'` = yes; then
13662 cat >>confdefs.h <<EOF
13663 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
13669 for ac_header in unistd.h getopt.h
13671 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
13672 echo "$as_me:13672: checking for $ac_header" >&5
13673 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13674 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13675 echo $ECHO_N "(cached) $ECHO_C" >&6
13677 cat >conftest.$ac_ext <<_ACEOF
13678 #line 13678 "configure"
13679 #include "confdefs.h"
13680 #include <$ac_header>
13682 if { (eval echo "$as_me:13682: \"$ac_cpp conftest.$ac_ext\"") >&5
13683 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13685 egrep -v '^ *\+' conftest.er1 >conftest.err
13687 cat conftest.err >&5
13688 echo "$as_me:13688: \$? = $ac_status" >&5
13689 (exit $ac_status); } >/dev/null; then
13690 if test -s conftest.err; then
13691 ac_cpp_err=$ac_c_preproc_warn_flag
13698 if test -z "$ac_cpp_err"; then
13699 eval "$as_ac_Header=yes"
13701 echo "$as_me: failed program was:" >&5
13702 cat conftest.$ac_ext >&5
13703 eval "$as_ac_Header=no"
13705 rm -f conftest.err conftest.$ac_ext
13707 echo "$as_me:13707: result: `eval echo '${'$as_ac_Header'}'`" >&5
13708 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13709 if test `eval echo '${'$as_ac_Header'}'` = yes; then
13710 cat >>confdefs.h <<EOF
13711 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
13717 echo "$as_me:13717: checking for header declaring getopt variables" >&5
13718 echo $ECHO_N "checking for header declaring getopt variables... $ECHO_C" >&6
13719 if test "${cf_cv_getopt_header+set}" = set; then
13720 echo $ECHO_N "(cached) $ECHO_C" >&6
13723 cf_cv_getopt_header=none
13724 for cf_header in stdio.h stdlib.h unistd.h getopt.h
13726 cat >conftest.$ac_ext <<_ACEOF
13727 #line 13727 "configure"
13728 #include "confdefs.h"
13730 #include <$cf_header>
13734 int x = optind; char *y = optarg
13739 rm -f conftest.$ac_objext
13740 if { (eval echo "$as_me:13740: \"$ac_compile\"") >&5
13741 (eval $ac_compile) 2>&5
13743 echo "$as_me:13743: \$? = $ac_status" >&5
13744 (exit $ac_status); } &&
13745 { ac_try='test -s conftest.$ac_objext'
13746 { (eval echo "$as_me:13746: \"$ac_try\"") >&5
13747 (eval $ac_try) 2>&5
13749 echo "$as_me:13749: \$? = $ac_status" >&5
13750 (exit $ac_status); }; }; then
13751 cf_cv_getopt_header=$cf_header
13754 echo "$as_me: failed program was:" >&5
13755 cat conftest.$ac_ext >&5
13757 rm -f conftest.$ac_objext conftest.$ac_ext
13761 echo "$as_me:13761: result: $cf_cv_getopt_header" >&5
13762 echo "${ECHO_T}$cf_cv_getopt_header" >&6
13763 if test $cf_cv_getopt_header != none ; then
13764 cat >>confdefs.h <<\EOF
13765 #define HAVE_GETOPT_HEADER 1
13775 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13776 echo "$as_me:13776: checking for $ac_func" >&5
13777 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13778 if eval "test \"\${$as_ac_var+set}\" = set"; then
13779 echo $ECHO_N "(cached) $ECHO_C" >&6
13781 cat >conftest.$ac_ext <<_ACEOF
13782 #line 13782 "configure"
13783 #include "confdefs.h"
13784 /* System header to define __stub macros and hopefully few prototypes,
13785 which can conflict with char $ac_func (); below. */
13786 #include <assert.h>
13787 /* Override any gcc2 internal prototype to avoid an error. */
13791 /* We use char because int might match the return type of a gcc2
13792 builtin and then its argument prototype would still apply. */
13799 /* The GNU C library defines this for functions which it implements
13800 to always fail with ENOSYS. Some functions are actually named
13801 something starting with __ and the normal name is an alias. */
13802 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13812 rm -f conftest.$ac_objext conftest$ac_exeext
13813 if { (eval echo "$as_me:13813: \"$ac_link\"") >&5
13814 (eval $ac_link) 2>&5
13816 echo "$as_me:13816: \$? = $ac_status" >&5
13817 (exit $ac_status); } &&
13818 { ac_try='test -s conftest$ac_exeext'
13819 { (eval echo "$as_me:13819: \"$ac_try\"") >&5
13820 (eval $ac_try) 2>&5
13822 echo "$as_me:13822: \$? = $ac_status" >&5
13823 (exit $ac_status); }; }; then
13824 eval "$as_ac_var=yes"
13826 echo "$as_me: failed program was:" >&5
13827 cat conftest.$ac_ext >&5
13828 eval "$as_ac_var=no"
13830 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13832 echo "$as_me:13832: result: `eval echo '${'$as_ac_var'}'`" >&5
13833 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13834 if test `eval echo '${'$as_ac_var'}'` = yes; then
13835 cat >>confdefs.h <<EOF
13836 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13842 if test "$cf_enable_widec" = yes; then
13855 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13856 echo "$as_me:13856: checking for $ac_func" >&5
13857 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13858 if eval "test \"\${$as_ac_var+set}\" = set"; then
13859 echo $ECHO_N "(cached) $ECHO_C" >&6
13861 cat >conftest.$ac_ext <<_ACEOF
13862 #line 13862 "configure"
13863 #include "confdefs.h"
13864 /* System header to define __stub macros and hopefully few prototypes,
13865 which can conflict with char $ac_func (); below. */
13866 #include <assert.h>
13867 /* Override any gcc2 internal prototype to avoid an error. */
13871 /* We use char because int might match the return type of a gcc2
13872 builtin and then its argument prototype would still apply. */
13879 /* The GNU C library defines this for functions which it implements
13880 to always fail with ENOSYS. Some functions are actually named
13881 something starting with __ and the normal name is an alias. */
13882 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13892 rm -f conftest.$ac_objext conftest$ac_exeext
13893 if { (eval echo "$as_me:13893: \"$ac_link\"") >&5
13894 (eval $ac_link) 2>&5
13896 echo "$as_me:13896: \$? = $ac_status" >&5
13897 (exit $ac_status); } &&
13898 { ac_try='test -s conftest$ac_exeext'
13899 { (eval echo "$as_me:13899: \"$ac_try\"") >&5
13900 (eval $ac_try) 2>&5
13902 echo "$as_me:13902: \$? = $ac_status" >&5
13903 (exit $ac_status); }; }; then
13904 eval "$as_ac_var=yes"
13906 echo "$as_me: failed program was:" >&5
13907 cat conftest.$ac_ext >&5
13908 eval "$as_ac_var=no"
13910 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13912 echo "$as_me:13912: result: `eval echo '${'$as_ac_var'}'`" >&5
13913 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13914 if test `eval echo '${'$as_ac_var'}'` = yes; then
13915 cat >>confdefs.h <<EOF
13916 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13924 echo "$as_me:13924: checking if we must define _XOPEN_SOURCE_EXTENDED" >&5
13925 echo $ECHO_N "checking if we must define _XOPEN_SOURCE_EXTENDED... $ECHO_C" >&6
13926 if test "${cf_cv_need_xopen_extension+set}" = set; then
13927 echo $ECHO_N "(cached) $ECHO_C" >&6
13930 cat >conftest.$ac_ext <<_ACEOF
13931 #line 13931 "configure"
13932 #include "confdefs.h"
13934 #include <stdlib.h>
13935 #include <${cf_cv_ncurses_header:-curses.h}>
13940 #if defined(NCURSES_VERSION_PATCH)
13941 #if (NCURSES_VERSION_PATCH < 20100501) && (NCURSES_VERSION_PATCH >= 20100403)
13945 long x = winnstr(stdscr, "", 0);
13947 getbegyx(stdscr, y1, x1)
13952 rm -f conftest.$ac_objext conftest$ac_exeext
13953 if { (eval echo "$as_me:13953: \"$ac_link\"") >&5
13954 (eval $ac_link) 2>&5
13956 echo "$as_me:13956: \$? = $ac_status" >&5
13957 (exit $ac_status); } &&
13958 { ac_try='test -s conftest$ac_exeext'
13959 { (eval echo "$as_me:13959: \"$ac_try\"") >&5
13960 (eval $ac_try) 2>&5
13962 echo "$as_me:13962: \$? = $ac_status" >&5
13963 (exit $ac_status); }; }; then
13964 cf_cv_need_xopen_extension=no
13966 echo "$as_me: failed program was:" >&5
13967 cat conftest.$ac_ext >&5
13968 cat >conftest.$ac_ext <<_ACEOF
13969 #line 13969 "configure"
13970 #include "confdefs.h"
13972 #define _XOPEN_SOURCE_EXTENDED
13973 #include <stdlib.h>
13974 #include <${cf_cv_ncurses_header:-curses.h}>
13979 #ifdef NCURSES_VERSION
13981 int check2 = curs_set((int)sizeof(check));
13983 long x = winnstr(stdscr, "", 0);
13985 getbegyx(stdscr, y1, x1)
13990 rm -f conftest.$ac_objext conftest$ac_exeext
13991 if { (eval echo "$as_me:13991: \"$ac_link\"") >&5
13992 (eval $ac_link) 2>&5
13994 echo "$as_me:13994: \$? = $ac_status" >&5
13995 (exit $ac_status); } &&
13996 { ac_try='test -s conftest$ac_exeext'
13997 { (eval echo "$as_me:13997: \"$ac_try\"") >&5
13998 (eval $ac_try) 2>&5
14000 echo "$as_me:14000: \$? = $ac_status" >&5
14001 (exit $ac_status); }; }; then
14002 cf_cv_need_xopen_extension=yes
14004 echo "$as_me: failed program was:" >&5
14005 cat conftest.$ac_ext >&5
14006 cf_cv_need_xopen_extension=unknown
14008 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14010 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14012 echo "$as_me:14012: result: $cf_cv_need_xopen_extension" >&5
14013 echo "${ECHO_T}$cf_cv_need_xopen_extension" >&6
14014 test $cf_cv_need_xopen_extension = yes && CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE_EXTENDED"
14016 echo "$as_me:14016: checking for term.h" >&5
14017 echo $ECHO_N "checking for term.h... $ECHO_C" >&6
14018 if test "${cf_cv_term_header+set}" = set; then
14019 echo $ECHO_N "(cached) $ECHO_C" >&6
14022 # If we found <ncurses/curses.h>, look for <ncurses/term.h>, but always look
14023 # for <term.h> if we do not find the variant.
14025 cf_header_list="term.h ncurses/term.h ncursesw/term.h"
14027 case ${cf_cv_ncurses_header:-curses.h} in #(vi
14029 cf_header_item=`echo ${cf_cv_ncurses_header:-curses.h} | sed -e 's%\..*%%' -e 's%/.*%/%'`term.h
14030 cf_header_list="$cf_header_item $cf_header_list"
14034 for cf_header in $cf_header_list
14036 cat >conftest.$ac_ext <<_ACEOF
14037 #line 14037 "configure"
14038 #include "confdefs.h"
14040 #include <${cf_cv_ncurses_header:-curses.h}>
14041 #include <${cf_header}>
14050 rm -f conftest.$ac_objext
14051 if { (eval echo "$as_me:14051: \"$ac_compile\"") >&5
14052 (eval $ac_compile) 2>&5
14054 echo "$as_me:14054: \$? = $ac_status" >&5
14055 (exit $ac_status); } &&
14056 { ac_try='test -s conftest.$ac_objext'
14057 { (eval echo "$as_me:14057: \"$ac_try\"") >&5
14058 (eval $ac_try) 2>&5
14060 echo "$as_me:14060: \$? = $ac_status" >&5
14061 (exit $ac_status); }; }; then
14062 cf_cv_term_header=$cf_header
14065 echo "$as_me: failed program was:" >&5
14066 cat conftest.$ac_ext >&5
14067 cf_cv_term_header=no
14069 rm -f conftest.$ac_objext conftest.$ac_ext
14072 case $cf_cv_term_header in #(vi
14074 # If curses is ncurses, some packagers still mess it up by trying to make
14075 # us use GNU termcap. This handles the most common case.
14076 for cf_header in ncurses/term.h ncursesw/term.h
14078 cat >conftest.$ac_ext <<_ACEOF
14079 #line 14079 "configure"
14080 #include "confdefs.h"
14082 #include <${cf_cv_ncurses_header:-curses.h}>
14083 #ifdef NCURSES_VERSION
14084 #include <${cf_header}>
14096 rm -f conftest.$ac_objext
14097 if { (eval echo "$as_me:14097: \"$ac_compile\"") >&5
14098 (eval $ac_compile) 2>&5
14100 echo "$as_me:14100: \$? = $ac_status" >&5
14101 (exit $ac_status); } &&
14102 { ac_try='test -s conftest.$ac_objext'
14103 { (eval echo "$as_me:14103: \"$ac_try\"") >&5
14104 (eval $ac_try) 2>&5
14106 echo "$as_me:14106: \$? = $ac_status" >&5
14107 (exit $ac_status); }; }; then
14108 cf_cv_term_header=$cf_header
14111 echo "$as_me: failed program was:" >&5
14112 cat conftest.$ac_ext >&5
14113 cf_cv_term_header=no
14115 rm -f conftest.$ac_objext conftest.$ac_ext
14121 echo "$as_me:14121: result: $cf_cv_term_header" >&5
14122 echo "${ECHO_T}$cf_cv_term_header" >&6
14124 case $cf_cv_term_header in #(vi
14126 cat >>confdefs.h <<\EOF
14127 #define HAVE_TERM_H 1
14131 ncurses/term.h) #(vi
14132 cat >>confdefs.h <<\EOF
14133 #define HAVE_NCURSES_TERM_H 1
14138 cat >>confdefs.h <<\EOF
14139 #define HAVE_NCURSESW_TERM_H 1
14145 echo "$as_me:14145: checking for unctrl.h" >&5
14146 echo $ECHO_N "checking for unctrl.h... $ECHO_C" >&6
14147 if test "${cf_cv_unctrl_header+set}" = set; then
14148 echo $ECHO_N "(cached) $ECHO_C" >&6
14151 # If we found <ncurses/curses.h>, look for <ncurses/unctrl.h>, but always look
14152 # for <unctrl.h> if we do not find the variant.
14154 cf_header_list="unctrl.h ncurses/unctrl.h ncursesw/unctrl.h"
14156 case ${cf_cv_ncurses_header:-curses.h} in #(vi
14158 cf_header_item=`echo ${cf_cv_ncurses_header:-curses.h} | sed -e 's%\..*%%' -e 's%/.*%/%'`unctrl.h
14159 cf_header_list="$cf_header_item $cf_header_list"
14163 for cf_header in $cf_header_list
14165 cat >conftest.$ac_ext <<_ACEOF
14166 #line 14166 "configure"
14167 #include "confdefs.h"
14169 #include <${cf_cv_ncurses_header:-curses.h}>
14170 #include <${cf_header}>
14179 rm -f conftest.$ac_objext
14180 if { (eval echo "$as_me:14180: \"$ac_compile\"") >&5
14181 (eval $ac_compile) 2>&5
14183 echo "$as_me:14183: \$? = $ac_status" >&5
14184 (exit $ac_status); } &&
14185 { ac_try='test -s conftest.$ac_objext'
14186 { (eval echo "$as_me:14186: \"$ac_try\"") >&5
14187 (eval $ac_try) 2>&5
14189 echo "$as_me:14189: \$? = $ac_status" >&5
14190 (exit $ac_status); }; }; then
14191 cf_cv_unctrl_header=$cf_header
14194 echo "$as_me: failed program was:" >&5
14195 cat conftest.$ac_ext >&5
14196 cf_cv_unctrl_header=no
14198 rm -f conftest.$ac_objext conftest.$ac_ext
14201 case $cf_cv_unctrl_header in #(vi
14203 { echo "$as_me:14203: WARNING: unctrl.h header not found" >&5
14204 echo "$as_me: WARNING: unctrl.h header not found" >&2;}
14209 echo "$as_me:14209: result: $cf_cv_unctrl_header" >&5
14210 echo "${ECHO_T}$cf_cv_unctrl_header" >&6
14212 case $cf_cv_unctrl_header in #(vi
14214 cat >>confdefs.h <<\EOF
14215 #define HAVE_UNCTRL_H 1
14219 ncurses/unctrl.h) #(vi
14220 cat >>confdefs.h <<\EOF
14221 #define HAVE_NCURSES_UNCTRL_H 1
14226 cat >>confdefs.h <<\EOF
14227 #define HAVE_NCURSESW_UNCTRL_H 1
14234 assume_default_colors \
14260 use_default_colors \
14272 cf_tr_func=`echo "$cf_func" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14274 echo "$as_me:14274: checking for ${cf_func}" >&5
14275 echo $ECHO_N "checking for ${cf_func}... $ECHO_C" >&6
14277 echo "${as_me:-configure}:14277: testing ${cf_func} ..." 1>&5
14279 if eval "test \"\${cf_cv_func_$cf_func+set}\" = set"; then
14280 echo $ECHO_N "(cached) $ECHO_C" >&6
14283 eval cf_result='$ac_cv_func_'$cf_func
14284 if test ".$cf_result" != ".no"; then
14285 cat >conftest.$ac_ext <<_ACEOF
14286 #line 14286 "configure"
14287 #include "confdefs.h"
14289 #ifdef HAVE_XCURSES
14290 #include <xcurses.h>
14291 char * XCursesProgramName = "test";
14293 #include <${cf_cv_ncurses_header:-curses.h}>
14294 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
14295 #include <ncursesw/term.h>
14296 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
14297 #include <ncurses/term.h>
14298 #elif defined(HAVE_TERM_H)
14308 long foo = (long)(&${cf_func});
14309 if (foo + 1234 > 5678)
14310 ${cf_cv_main_return:-return}(foo);
14317 rm -f conftest.$ac_objext conftest$ac_exeext
14318 if { (eval echo "$as_me:14318: \"$ac_link\"") >&5
14319 (eval $ac_link) 2>&5
14321 echo "$as_me:14321: \$? = $ac_status" >&5
14322 (exit $ac_status); } &&
14323 { ac_try='test -s conftest$ac_exeext'
14324 { (eval echo "$as_me:14324: \"$ac_try\"") >&5
14325 (eval $ac_try) 2>&5
14327 echo "$as_me:14327: \$? = $ac_status" >&5
14328 (exit $ac_status); }; }; then
14331 echo "$as_me: failed program was:" >&5
14332 cat conftest.$ac_ext >&5
14335 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14337 eval 'cf_cv_func_'$cf_func'=$cf_result'
14341 # use the computed/retrieved cache-value:
14342 eval 'cf_result=$cf_cv_func_'$cf_func
14343 echo "$as_me:14343: result: $cf_result" >&5
14344 echo "${ECHO_T}$cf_result" >&6
14345 if test $cf_result != no; then
14346 cat >>confdefs.h <<EOF
14347 #define HAVE_${cf_tr_func} 1
14353 for cf_func in tputs
14356 cf_tr_func=`echo "$cf_func" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14358 echo "$as_me:14358: checking for ${cf_func}" >&5
14359 echo $ECHO_N "checking for ${cf_func}... $ECHO_C" >&6
14361 echo "${as_me:-configure}:14361: testing ${cf_func} ..." 1>&5
14363 if eval "test \"\${cf_cv_func_$cf_func+set}\" = set"; then
14364 echo $ECHO_N "(cached) $ECHO_C" >&6
14367 eval cf_result='$ac_cv_func_'$cf_func
14368 if test ".$cf_result" != ".no"; then
14369 cat >conftest.$ac_ext <<_ACEOF
14370 #line 14370 "configure"
14371 #include "confdefs.h"
14373 #ifdef HAVE_XCURSES
14374 #include <xcurses.h>
14375 char * XCursesProgramName = "test";
14377 #include <${cf_cv_ncurses_header:-curses.h}>
14378 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
14379 #include <ncursesw/term.h>
14380 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
14381 #include <ncurses/term.h>
14382 #elif defined(HAVE_TERM_H)
14392 long foo = (long)(&${cf_func});
14393 if (foo + 1234 > 5678)
14394 ${cf_cv_main_return:-return}(foo);
14401 rm -f conftest.$ac_objext conftest$ac_exeext
14402 if { (eval echo "$as_me:14402: \"$ac_link\"") >&5
14403 (eval $ac_link) 2>&5
14405 echo "$as_me:14405: \$? = $ac_status" >&5
14406 (exit $ac_status); } &&
14407 { ac_try='test -s conftest$ac_exeext'
14408 { (eval echo "$as_me:14408: \"$ac_try\"") >&5
14409 (eval $ac_try) 2>&5
14411 echo "$as_me:14411: \$? = $ac_status" >&5
14412 (exit $ac_status); }; }; then
14415 echo "$as_me: failed program was:" >&5
14416 cat conftest.$ac_ext >&5
14419 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14421 eval 'cf_cv_func_'$cf_func'=$cf_result'
14425 # use the computed/retrieved cache-value:
14426 eval 'cf_result=$cf_cv_func_'$cf_func
14427 echo "$as_me:14427: result: $cf_result" >&5
14428 echo "${ECHO_T}$cf_result" >&6
14429 if test $cf_result != no; then
14430 cat >>confdefs.h <<EOF
14431 #define HAVE_${cf_tr_func} 1
14437 if test x$cf_cv_func_tputs = xyes
14440 for cf_arg in int char
14442 for cf_ret in int void
14444 if test $cf_ret = void
14446 cf_return="/* nothing */"
14448 cf_return="return value"
14450 cat >conftest.$ac_ext <<_ACEOF
14451 #line 14451 "configure"
14452 #include "confdefs.h"
14454 #include <${cf_cv_ncurses_header:-curses.h}>
14455 #include <$cf_cv_term_header>
14457 static $cf_ret outc($cf_arg value) { $cf_return; }
14463 tputs("hello", 0, outc);
14464 ${cf_cv_main_return:-return}(0);
14470 rm -f conftest.$ac_objext
14471 if { (eval echo "$as_me:14471: \"$ac_compile\"") >&5
14472 (eval $ac_compile) 2>&5
14474 echo "$as_me:14474: \$? = $ac_status" >&5
14475 (exit $ac_status); } &&
14476 { ac_try='test -s conftest.$ac_objext'
14477 { (eval echo "$as_me:14477: \"$ac_try\"") >&5
14478 (eval $ac_try) 2>&5
14480 echo "$as_me:14480: \$? = $ac_status" >&5
14481 (exit $ac_status); }; }; then
14483 test -n "$verbose" && echo " prototype $cf_ret func($cf_arg value)" 1>&6
14485 echo "${as_me:-configure}:14485: testing prototype $cf_ret func($cf_arg value) ..." 1>&5
14487 cat >>confdefs.h <<EOF
14488 #define TPUTS_ARG $cf_arg
14489 #define TPUTS_PROTO(func,value) $cf_ret func(TPUTS_ARG value)
14490 #define TPUTS_RETURN(value) $cf_return
14496 echo "$as_me: failed program was:" >&5
14497 cat conftest.$ac_ext >&5
14499 rm -f conftest.$ac_objext conftest.$ac_ext
14501 test $cf_done = yes && break
14505 echo "$as_me:14505: checking for ncurses extended functions" >&5
14506 echo $ECHO_N "checking for ncurses extended functions... $ECHO_C" >&6
14507 if test "${cf_cv_ncurses_ext_funcs+set}" = set; then
14508 echo $ECHO_N "(cached) $ECHO_C" >&6
14511 cat >conftest.$ac_ext <<_ACEOF
14512 #line 14512 "configure"
14513 #include "confdefs.h"
14515 #include <${cf_cv_ncurses_header:-curses.h}>
14520 int x = NCURSES_EXT_FUNCS
14526 rm -f conftest.$ac_objext
14527 if { (eval echo "$as_me:14527: \"$ac_compile\"") >&5
14528 (eval $ac_compile) 2>&5
14530 echo "$as_me:14530: \$? = $ac_status" >&5
14531 (exit $ac_status); } &&
14532 { ac_try='test -s conftest.$ac_objext'
14533 { (eval echo "$as_me:14533: \"$ac_try\"") >&5
14534 (eval $ac_try) 2>&5
14536 echo "$as_me:14536: \$? = $ac_status" >&5
14537 (exit $ac_status); }; }; then
14538 cf_cv_ncurses_ext_funcs=defined
14540 echo "$as_me: failed program was:" >&5
14541 cat conftest.$ac_ext >&5
14543 cat >conftest.$ac_ext <<_ACEOF
14544 #line 14544 "configure"
14545 #include "confdefs.h"
14547 #include <${cf_cv_ncurses_header:-curses.h}>
14552 (void) assume_default_colors (0, 0);
14553 (void) curses_version ();
14554 (void) define_key (0, 0);
14555 (void) is_term_resized (0, 0);
14556 (void) key_defined (0);
14557 (void) keybound (0, 0);
14558 (void) keyok (0, 0);
14559 (void) resize_term (0, 0);
14560 (void) resizeterm (0, 0);
14561 (void) use_default_colors ();
14562 (void) use_extended_names (0);
14563 (void) wresize (0, 0, 0);
14568 rm -f conftest.$ac_objext conftest$ac_exeext
14569 if { (eval echo "$as_me:14569: \"$ac_link\"") >&5
14570 (eval $ac_link) 2>&5
14572 echo "$as_me:14572: \$? = $ac_status" >&5
14573 (exit $ac_status); } &&
14574 { ac_try='test -s conftest$ac_exeext'
14575 { (eval echo "$as_me:14575: \"$ac_try\"") >&5
14576 (eval $ac_try) 2>&5
14578 echo "$as_me:14578: \$? = $ac_status" >&5
14579 (exit $ac_status); }; }; then
14580 cf_cv_ncurses_ext_funcs=yes
14582 echo "$as_me: failed program was:" >&5
14583 cat conftest.$ac_ext >&5
14584 cf_cv_ncurses_ext_funcs=no
14586 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14589 rm -f conftest.$ac_objext conftest.$ac_ext
14592 echo "$as_me:14592: result: $cf_cv_ncurses_ext_funcs" >&5
14593 echo "${ECHO_T}$cf_cv_ncurses_ext_funcs" >&6
14594 test "$cf_cv_ncurses_ext_funcs" = yes && cat >>confdefs.h <<\EOF
14595 #define NCURSES_EXT_FUNCS 1
14598 if test "$cf_enable_widec" = yes
14600 # workaround for systems with ncurses before 20111029, due to change of
14601 # feature test macro from _XPG5 to _XOPEN_SOURCE
14602 if test -n "$cf_cv_ncurses_version" && test "x$cf_cv_ncurses_version" != xno
14605 echo "$as_me:14605: checking if _XPG5 should be defined to enable wide-characters" >&5
14606 echo $ECHO_N "checking if _XPG5 should be defined to enable wide-characters... $ECHO_C" >&6
14608 cat >conftest.$ac_ext <<_ACEOF
14609 #line 14609 "configure"
14610 #include "confdefs.h"
14612 #include <${cf_cv_ncurses_header:-curses.h}>
14621 rm -f conftest.$ac_objext
14622 if { (eval echo "$as_me:14622: \"$ac_compile\"") >&5
14623 (eval $ac_compile) 2>&5
14625 echo "$as_me:14625: \$? = $ac_status" >&5
14626 (exit $ac_status); } &&
14627 { ac_try='test -s conftest.$ac_objext'
14628 { (eval echo "$as_me:14628: \"$ac_try\"") >&5
14629 (eval $ac_try) 2>&5
14631 echo "$as_me:14631: \$? = $ac_status" >&5
14632 (exit $ac_status); }; }; then
14635 echo "$as_me: failed program was:" >&5
14636 cat conftest.$ac_ext >&5
14637 cf_save_cppflags="$CPPFLAGS"
14638 CPPFLAGS="$CPPFLAGS -D_XPG5"
14639 cat >conftest.$ac_ext <<_ACEOF
14640 #line 14640 "configure"
14641 #include "confdefs.h"
14643 #include <${cf_cv_ncurses_header:-curses.h}>
14652 rm -f conftest.$ac_objext
14653 if { (eval echo "$as_me:14653: \"$ac_compile\"") >&5
14654 (eval $ac_compile) 2>&5
14656 echo "$as_me:14656: \$? = $ac_status" >&5
14657 (exit $ac_status); } &&
14658 { ac_try='test -s conftest.$ac_objext'
14659 { (eval echo "$as_me:14659: \"$ac_try\"") >&5
14660 (eval $ac_try) 2>&5
14662 echo "$as_me:14662: \$? = $ac_status" >&5
14663 (exit $ac_status); }; }; then
14666 echo "$as_me: failed program was:" >&5
14667 cat conftest.$ac_ext >&5
14669 rm -f conftest.$ac_objext conftest.$ac_ext
14670 CPPFLAGS="$cf_save_cppflags"
14672 rm -f conftest.$ac_objext conftest.$ac_ext
14673 echo "$as_me:14673: result: $cf_define_xpg5" >&5
14674 echo "${ECHO_T}$cf_define_xpg5" >&6
14676 if test "$cf_define_xpg5" = yes
14678 CPPFLAGS="$CPPFLAGS -D_XPG5"
14682 echo "$as_me:14682: checking for wide-character functions" >&5
14683 echo $ECHO_N "checking for wide-character functions... $ECHO_C" >&6
14684 if test "${cf_cv_widechar_funcs+set}" = set; then
14685 echo $ECHO_N "(cached) $ECHO_C" >&6
14688 cat >conftest.$ac_ext <<_ACEOF
14689 #line 14689 "configure"
14690 #include "confdefs.h"
14692 #include <${cf_cv_ncurses_header:-curses.h}>
14697 static wchar_t src_wchar[2];
14698 static cchar_t dst_cchar;
14699 setcchar(&dst_cchar, src_wchar, A_NORMAL, 0, (void *) 0);
14705 rm -f conftest.$ac_objext conftest$ac_exeext
14706 if { (eval echo "$as_me:14706: \"$ac_link\"") >&5
14707 (eval $ac_link) 2>&5
14709 echo "$as_me:14709: \$? = $ac_status" >&5
14710 (exit $ac_status); } &&
14711 { ac_try='test -s conftest$ac_exeext'
14712 { (eval echo "$as_me:14712: \"$ac_try\"") >&5
14713 (eval $ac_try) 2>&5
14715 echo "$as_me:14715: \$? = $ac_status" >&5
14716 (exit $ac_status); }; }; then
14717 cf_cv_widechar_funcs=yes
14719 echo "$as_me: failed program was:" >&5
14720 cat conftest.$ac_ext >&5
14721 cf_cv_widechar_funcs=no
14723 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14726 echo "$as_me:14726: result: $cf_cv_widechar_funcs" >&5
14727 echo "${ECHO_T}$cf_cv_widechar_funcs" >&6
14728 if test "$cf_cv_widechar_funcs" != no ; then
14729 cat >>confdefs.h <<\EOF
14730 #define USE_WIDEC_SUPPORT 1
14734 cat >>confdefs.h <<\EOF
14735 #define USE_WIDEC_SUPPORT 0
14740 cat >>confdefs.h <<\EOF
14741 #define USE_WIDEC_SUPPORT 0
14746 echo "$as_me:14746: checking if sys/time.h works with sys/select.h" >&5
14747 echo $ECHO_N "checking if sys/time.h works with sys/select.h... $ECHO_C" >&6
14748 if test "${cf_cv_sys_time_select+set}" = set; then
14749 echo $ECHO_N "(cached) $ECHO_C" >&6
14752 cat >conftest.$ac_ext <<_ACEOF
14753 #line 14753 "configure"
14754 #include "confdefs.h"
14756 #include <sys/types.h>
14757 #ifdef HAVE_SYS_TIME_H
14758 #include <sys/time.h>
14760 #ifdef HAVE_SYS_SELECT_H
14761 #include <sys/select.h>
14772 rm -f conftest.$ac_objext
14773 if { (eval echo "$as_me:14773: \"$ac_compile\"") >&5
14774 (eval $ac_compile) 2>&5
14776 echo "$as_me:14776: \$? = $ac_status" >&5
14777 (exit $ac_status); } &&
14778 { ac_try='test -s conftest.$ac_objext'
14779 { (eval echo "$as_me:14779: \"$ac_try\"") >&5
14780 (eval $ac_try) 2>&5
14782 echo "$as_me:14782: \$? = $ac_status" >&5
14783 (exit $ac_status); }; }; then
14784 cf_cv_sys_time_select=yes
14786 echo "$as_me: failed program was:" >&5
14787 cat conftest.$ac_ext >&5
14788 cf_cv_sys_time_select=no
14790 rm -f conftest.$ac_objext conftest.$ac_ext
14794 echo "$as_me:14794: result: $cf_cv_sys_time_select" >&5
14795 echo "${ECHO_T}$cf_cv_sys_time_select" >&6
14796 test "$cf_cv_sys_time_select" = yes && cat >>confdefs.h <<\EOF
14797 #define HAVE_SYS_TIME_SELECT 1
14800 echo "$as_me:14800: checking for function curses_version" >&5
14801 echo $ECHO_N "checking for function curses_version... $ECHO_C" >&6
14802 if test "${cf_cv_func_curses_version+set}" = set; then
14803 echo $ECHO_N "(cached) $ECHO_C" >&6
14806 if test "$cross_compiling" = yes; then
14807 cf_cv_func_curses_version=unknown
14809 cat >conftest.$ac_ext <<_ACEOF
14810 #line 14810 "configure"
14811 #include "confdefs.h"
14813 #include <${cf_cv_ncurses_header:-curses.h}>
14817 sprintf(temp, "%s\n", curses_version());
14818 ${cf_cv_main_return:-return}(0);
14822 rm -f conftest$ac_exeext
14823 if { (eval echo "$as_me:14823: \"$ac_link\"") >&5
14824 (eval $ac_link) 2>&5
14826 echo "$as_me:14826: \$? = $ac_status" >&5
14827 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14828 { (eval echo "$as_me:14828: \"$ac_try\"") >&5
14829 (eval $ac_try) 2>&5
14831 echo "$as_me:14831: \$? = $ac_status" >&5
14832 (exit $ac_status); }; }; then
14833 cf_cv_func_curses_version=yes
14836 echo "$as_me: program exited with status $ac_status" >&5
14837 echo "$as_me: failed program was:" >&5
14838 cat conftest.$ac_ext >&5
14839 cf_cv_func_curses_version=no
14842 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14846 echo "$as_me:14846: result: $cf_cv_func_curses_version" >&5
14847 echo "${ECHO_T}$cf_cv_func_curses_version" >&6
14848 test "$cf_cv_func_curses_version" = yes && cat >>confdefs.h <<\EOF
14849 #define HAVE_CURSES_VERSION 1
14852 echo "$as_me:14852: checking for ncurses wrap-prefix" >&5
14853 echo $ECHO_N "checking for ncurses wrap-prefix... $ECHO_C" >&6
14855 # Check whether --with-ncurses-wrap-prefix or --without-ncurses-wrap-prefix was given.
14856 if test "${with_ncurses_wrap_prefix+set}" = set; then
14857 withval="$with_ncurses_wrap_prefix"
14858 NCURSES_WRAP_PREFIX=$withval
14860 NCURSES_WRAP_PREFIX=_nc_
14862 echo "$as_me:14862: result: $NCURSES_WRAP_PREFIX" >&5
14863 echo "${ECHO_T}$NCURSES_WRAP_PREFIX" >&6
14865 echo "$as_me:14865: checking for alternate character set array" >&5
14866 echo $ECHO_N "checking for alternate character set array... $ECHO_C" >&6
14867 if test "${cf_cv_curses_acs_map+set}" = set; then
14868 echo $ECHO_N "(cached) $ECHO_C" >&6
14871 cf_cv_curses_acs_map=unknown
14872 for name in acs_map _acs_map __acs_map ${NCURSES_WRAP_PREFIX}acs_map
14874 cat >conftest.$ac_ext <<_ACEOF
14875 #line 14875 "configure"
14876 #include "confdefs.h"
14878 #include <${cf_cv_ncurses_header:-curses.h}>
14884 $name['k'] = ACS_PLUS
14890 rm -f conftest.$ac_objext conftest$ac_exeext
14891 if { (eval echo "$as_me:14891: \"$ac_link\"") >&5
14892 (eval $ac_link) 2>&5
14894 echo "$as_me:14894: \$? = $ac_status" >&5
14895 (exit $ac_status); } &&
14896 { ac_try='test -s conftest$ac_exeext'
14897 { (eval echo "$as_me:14897: \"$ac_try\"") >&5
14898 (eval $ac_try) 2>&5
14900 echo "$as_me:14900: \$? = $ac_status" >&5
14901 (exit $ac_status); }; }; then
14902 cf_cv_curses_acs_map=$name; break
14904 echo "$as_me: failed program was:" >&5
14905 cat conftest.$ac_ext >&5
14907 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14911 echo "$as_me:14911: result: $cf_cv_curses_acs_map" >&5
14912 echo "${ECHO_T}$cf_cv_curses_acs_map" >&6
14914 test "$cf_cv_curses_acs_map" != unknown && cat >>confdefs.h <<EOF
14915 #define CURSES_ACS_ARRAY $cf_cv_curses_acs_map
14918 if test "$cf_enable_widec" = yes; then
14920 echo "$as_me:14920: checking for wide alternate character set array" >&5
14921 echo $ECHO_N "checking for wide alternate character set array... $ECHO_C" >&6
14922 if test "${cf_cv_curses_wacs_map+set}" = set; then
14923 echo $ECHO_N "(cached) $ECHO_C" >&6
14926 cf_cv_curses_wacs_map=unknown
14927 for name in wacs_map _wacs_map __wacs_map _nc_wacs _wacs_char
14929 cat >conftest.$ac_ext <<_ACEOF
14930 #line 14930 "configure"
14931 #include "confdefs.h"
14933 #ifndef _XOPEN_SOURCE_EXTENDED
14934 #define _XOPEN_SOURCE_EXTENDED
14936 #include <${cf_cv_ncurses_header:-curses.h}>
14940 void *foo = &($name['k'])
14945 rm -f conftest.$ac_objext conftest$ac_exeext
14946 if { (eval echo "$as_me:14946: \"$ac_link\"") >&5
14947 (eval $ac_link) 2>&5
14949 echo "$as_me:14949: \$? = $ac_status" >&5
14950 (exit $ac_status); } &&
14951 { ac_try='test -s conftest$ac_exeext'
14952 { (eval echo "$as_me:14952: \"$ac_try\"") >&5
14953 (eval $ac_try) 2>&5
14955 echo "$as_me:14955: \$? = $ac_status" >&5
14956 (exit $ac_status); }; }; then
14957 cf_cv_curses_wacs_map=$name
14960 echo "$as_me: failed program was:" >&5
14961 cat conftest.$ac_ext >&5
14963 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14966 echo "$as_me:14966: result: $cf_cv_curses_wacs_map" >&5
14967 echo "${ECHO_T}$cf_cv_curses_wacs_map" >&6
14969 test "$cf_cv_curses_wacs_map" != unknown && cat >>confdefs.h <<EOF
14970 #define CURSES_WACS_ARRAY $cf_cv_curses_wacs_map
14973 echo "$as_me:14973: checking for wide alternate character constants" >&5
14974 echo $ECHO_N "checking for wide alternate character constants... $ECHO_C" >&6
14975 if test "${cf_cv_curses_wacs_symbols+set}" = set; then
14976 echo $ECHO_N "(cached) $ECHO_C" >&6
14979 cf_cv_curses_wacs_symbols=no
14980 if test "$cf_cv_curses_wacs_map" != unknown
14982 cat >conftest.$ac_ext <<_ACEOF
14983 #line 14983 "configure"
14984 #include "confdefs.h"
14986 #ifndef _XOPEN_SOURCE_EXTENDED
14987 #define _XOPEN_SOURCE_EXTENDED
14989 #include <${cf_cv_ncurses_header:-curses.h}>
14993 cchar_t *foo = WACS_PLUS;
14994 $cf_cv_curses_wacs_map['k'] = *WACS_PLUS
14999 rm -f conftest.$ac_objext conftest$ac_exeext
15000 if { (eval echo "$as_me:15000: \"$ac_link\"") >&5
15001 (eval $ac_link) 2>&5
15003 echo "$as_me:15003: \$? = $ac_status" >&5
15004 (exit $ac_status); } &&
15005 { ac_try='test -s conftest$ac_exeext'
15006 { (eval echo "$as_me:15006: \"$ac_try\"") >&5
15007 (eval $ac_try) 2>&5
15009 echo "$as_me:15009: \$? = $ac_status" >&5
15010 (exit $ac_status); }; }; then
15011 cf_cv_curses_wacs_symbols=yes
15013 echo "$as_me: failed program was:" >&5
15014 cat conftest.$ac_ext >&5
15016 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15018 cat >conftest.$ac_ext <<_ACEOF
15019 #line 15019 "configure"
15020 #include "confdefs.h"
15022 #ifndef _XOPEN_SOURCE_EXTENDED
15023 #define _XOPEN_SOURCE_EXTENDED
15025 #include <${cf_cv_ncurses_header:-curses.h}>
15029 cchar_t *foo = WACS_PLUS
15034 rm -f conftest.$ac_objext conftest$ac_exeext
15035 if { (eval echo "$as_me:15035: \"$ac_link\"") >&5
15036 (eval $ac_link) 2>&5
15038 echo "$as_me:15038: \$? = $ac_status" >&5
15039 (exit $ac_status); } &&
15040 { ac_try='test -s conftest$ac_exeext'
15041 { (eval echo "$as_me:15041: \"$ac_try\"") >&5
15042 (eval $ac_try) 2>&5
15044 echo "$as_me:15044: \$? = $ac_status" >&5
15045 (exit $ac_status); }; }; then
15046 cf_cv_curses_wacs_symbols=yes
15048 echo "$as_me: failed program was:" >&5
15049 cat conftest.$ac_ext >&5
15051 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15055 echo "$as_me:15055: result: $cf_cv_curses_wacs_symbols" >&5
15056 echo "${ECHO_T}$cf_cv_curses_wacs_symbols" >&6
15058 test "$cf_cv_curses_wacs_symbols" != no && cat >>confdefs.h <<\EOF
15059 #define CURSES_WACS_SYMBOLS 1
15064 echo "$as_me:15064: checking for type attr_t in ${cf_cv_ncurses_header:-curses.h}" >&5
15065 echo $ECHO_N "checking for type attr_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
15066 cat >conftest.$ac_ext <<_ACEOF
15067 #line 15067 "configure"
15068 #include "confdefs.h"
15070 #ifndef _XOPEN_SOURCE_EXTENDED
15071 #define _XOPEN_SOURCE_EXTENDED
15073 #include <${cf_cv_ncurses_header:-curses.h}>
15084 rm -f conftest.$ac_objext
15085 if { (eval echo "$as_me:15085: \"$ac_compile\"") >&5
15086 (eval $ac_compile) 2>&5
15088 echo "$as_me:15088: \$? = $ac_status" >&5
15089 (exit $ac_status); } &&
15090 { ac_try='test -s conftest.$ac_objext'
15091 { (eval echo "$as_me:15091: \"$ac_try\"") >&5
15092 (eval $ac_try) 2>&5
15094 echo "$as_me:15094: \$? = $ac_status" >&5
15095 (exit $ac_status); }; }; then
15098 echo "$as_me: failed program was:" >&5
15099 cat conftest.$ac_ext >&5
15102 rm -f conftest.$ac_objext conftest.$ac_ext
15103 echo "$as_me:15103: result: $cf_result" >&5
15104 echo "${ECHO_T}$cf_result" >&6
15105 if test $cf_result = yes ; then
15107 cf_result=`echo "have_type_attr_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
15109 cat >>confdefs.h <<EOF
15110 #define $cf_result 1
15114 cat >>confdefs.h <<EOF
15115 #define attr_t long
15120 if test "$cf_enable_widec" = yes; then
15122 # This is needed on Tru64 5.0 to declare mbstate_t
15123 echo "$as_me:15123: checking if we must include wchar.h to declare mbstate_t" >&5
15124 echo $ECHO_N "checking if we must include wchar.h to declare mbstate_t... $ECHO_C" >&6
15125 if test "${cf_cv_mbstate_t+set}" = set; then
15126 echo $ECHO_N "(cached) $ECHO_C" >&6
15129 cat >conftest.$ac_ext <<_ACEOF
15130 #line 15130 "configure"
15131 #include "confdefs.h"
15133 #include <stdlib.h>
15134 #include <stdarg.h>
15136 #ifdef HAVE_LIBUTF8_H
15137 #include <libutf8.h>
15147 rm -f conftest.$ac_objext
15148 if { (eval echo "$as_me:15148: \"$ac_compile\"") >&5
15149 (eval $ac_compile) 2>&5
15151 echo "$as_me:15151: \$? = $ac_status" >&5
15152 (exit $ac_status); } &&
15153 { ac_try='test -s conftest.$ac_objext'
15154 { (eval echo "$as_me:15154: \"$ac_try\"") >&5
15155 (eval $ac_try) 2>&5
15157 echo "$as_me:15157: \$? = $ac_status" >&5
15158 (exit $ac_status); }; }; then
15161 echo "$as_me: failed program was:" >&5
15162 cat conftest.$ac_ext >&5
15163 cat >conftest.$ac_ext <<_ACEOF
15164 #line 15164 "configure"
15165 #include "confdefs.h"
15167 #include <stdlib.h>
15168 #include <stdarg.h>
15171 #ifdef HAVE_LIBUTF8_H
15172 #include <libutf8.h>
15182 rm -f conftest.$ac_objext
15183 if { (eval echo "$as_me:15183: \"$ac_compile\"") >&5
15184 (eval $ac_compile) 2>&5
15186 echo "$as_me:15186: \$? = $ac_status" >&5
15187 (exit $ac_status); } &&
15188 { ac_try='test -s conftest.$ac_objext'
15189 { (eval echo "$as_me:15189: \"$ac_try\"") >&5
15190 (eval $ac_try) 2>&5
15192 echo "$as_me:15192: \$? = $ac_status" >&5
15193 (exit $ac_status); }; }; then
15194 cf_cv_mbstate_t=yes
15196 echo "$as_me: failed program was:" >&5
15197 cat conftest.$ac_ext >&5
15198 cf_cv_mbstate_t=unknown
15200 rm -f conftest.$ac_objext conftest.$ac_ext
15202 rm -f conftest.$ac_objext conftest.$ac_ext
15204 echo "$as_me:15204: result: $cf_cv_mbstate_t" >&5
15205 echo "${ECHO_T}$cf_cv_mbstate_t" >&6
15207 if test "$cf_cv_mbstate_t" = yes ; then
15208 cat >>confdefs.h <<\EOF
15209 #define NEED_WCHAR_H 1
15215 # if we do not find mbstate_t in either place, use substitution to provide a fallback.
15216 if test "$cf_cv_mbstate_t" = unknown ; then
15217 NCURSES_MBSTATE_T=1
15220 # if we find mbstate_t in either place, use substitution to provide a fallback.
15221 if test "$cf_cv_mbstate_t" != unknown ; then
15222 NCURSES_OK_MBSTATE_T=1
15225 # This is needed on Tru64 5.0 to declare wchar_t
15226 echo "$as_me:15226: checking if we must include wchar.h to declare wchar_t" >&5
15227 echo $ECHO_N "checking if we must include wchar.h to declare wchar_t... $ECHO_C" >&6
15228 if test "${cf_cv_wchar_t+set}" = set; then
15229 echo $ECHO_N "(cached) $ECHO_C" >&6
15232 cat >conftest.$ac_ext <<_ACEOF
15233 #line 15233 "configure"
15234 #include "confdefs.h"
15236 #include <stdlib.h>
15237 #include <stdarg.h>
15239 #ifdef HAVE_LIBUTF8_H
15240 #include <libutf8.h>
15250 rm -f conftest.$ac_objext
15251 if { (eval echo "$as_me:15251: \"$ac_compile\"") >&5
15252 (eval $ac_compile) 2>&5
15254 echo "$as_me:15254: \$? = $ac_status" >&5
15255 (exit $ac_status); } &&
15256 { ac_try='test -s conftest.$ac_objext'
15257 { (eval echo "$as_me:15257: \"$ac_try\"") >&5
15258 (eval $ac_try) 2>&5
15260 echo "$as_me:15260: \$? = $ac_status" >&5
15261 (exit $ac_status); }; }; then
15264 echo "$as_me: failed program was:" >&5
15265 cat conftest.$ac_ext >&5
15266 cat >conftest.$ac_ext <<_ACEOF
15267 #line 15267 "configure"
15268 #include "confdefs.h"
15270 #include <stdlib.h>
15271 #include <stdarg.h>
15274 #ifdef HAVE_LIBUTF8_H
15275 #include <libutf8.h>
15285 rm -f conftest.$ac_objext
15286 if { (eval echo "$as_me:15286: \"$ac_compile\"") >&5
15287 (eval $ac_compile) 2>&5
15289 echo "$as_me:15289: \$? = $ac_status" >&5
15290 (exit $ac_status); } &&
15291 { ac_try='test -s conftest.$ac_objext'
15292 { (eval echo "$as_me:15292: \"$ac_try\"") >&5
15293 (eval $ac_try) 2>&5
15295 echo "$as_me:15295: \$? = $ac_status" >&5
15296 (exit $ac_status); }; }; then
15299 echo "$as_me: failed program was:" >&5
15300 cat conftest.$ac_ext >&5
15301 cf_cv_wchar_t=unknown
15303 rm -f conftest.$ac_objext conftest.$ac_ext
15305 rm -f conftest.$ac_objext conftest.$ac_ext
15307 echo "$as_me:15307: result: $cf_cv_wchar_t" >&5
15308 echo "${ECHO_T}$cf_cv_wchar_t" >&6
15310 if test "$cf_cv_wchar_t" = yes ; then
15311 cat >>confdefs.h <<\EOF
15312 #define NEED_WCHAR_H 1
15318 # if we do not find wchar_t in either place, use substitution to provide a fallback.
15319 if test "$cf_cv_wchar_t" = unknown ; then
15323 # if we find wchar_t in either place, use substitution to provide a fallback.
15324 if test "$cf_cv_wchar_t" != unknown ; then
15325 NCURSES_OK_WCHAR_T=1
15328 # This is needed on Tru64 5.0 to declare wint_t
15329 echo "$as_me:15329: checking if we must include wchar.h to declare wint_t" >&5
15330 echo $ECHO_N "checking if we must include wchar.h to declare wint_t... $ECHO_C" >&6
15331 if test "${cf_cv_wint_t+set}" = set; then
15332 echo $ECHO_N "(cached) $ECHO_C" >&6
15335 cat >conftest.$ac_ext <<_ACEOF
15336 #line 15336 "configure"
15337 #include "confdefs.h"
15339 #include <stdlib.h>
15340 #include <stdarg.h>
15342 #ifdef HAVE_LIBUTF8_H
15343 #include <libutf8.h>
15353 rm -f conftest.$ac_objext
15354 if { (eval echo "$as_me:15354: \"$ac_compile\"") >&5
15355 (eval $ac_compile) 2>&5
15357 echo "$as_me:15357: \$? = $ac_status" >&5
15358 (exit $ac_status); } &&
15359 { ac_try='test -s conftest.$ac_objext'
15360 { (eval echo "$as_me:15360: \"$ac_try\"") >&5
15361 (eval $ac_try) 2>&5
15363 echo "$as_me:15363: \$? = $ac_status" >&5
15364 (exit $ac_status); }; }; then
15367 echo "$as_me: failed program was:" >&5
15368 cat conftest.$ac_ext >&5
15369 cat >conftest.$ac_ext <<_ACEOF
15370 #line 15370 "configure"
15371 #include "confdefs.h"
15373 #include <stdlib.h>
15374 #include <stdarg.h>
15377 #ifdef HAVE_LIBUTF8_H
15378 #include <libutf8.h>
15388 rm -f conftest.$ac_objext
15389 if { (eval echo "$as_me:15389: \"$ac_compile\"") >&5
15390 (eval $ac_compile) 2>&5
15392 echo "$as_me:15392: \$? = $ac_status" >&5
15393 (exit $ac_status); } &&
15394 { ac_try='test -s conftest.$ac_objext'
15395 { (eval echo "$as_me:15395: \"$ac_try\"") >&5
15396 (eval $ac_try) 2>&5
15398 echo "$as_me:15398: \$? = $ac_status" >&5
15399 (exit $ac_status); }; }; then
15402 echo "$as_me: failed program was:" >&5
15403 cat conftest.$ac_ext >&5
15404 cf_cv_wint_t=unknown
15406 rm -f conftest.$ac_objext conftest.$ac_ext
15408 rm -f conftest.$ac_objext conftest.$ac_ext
15410 echo "$as_me:15410: result: $cf_cv_wint_t" >&5
15411 echo "${ECHO_T}$cf_cv_wint_t" >&6
15413 if test "$cf_cv_wint_t" = yes ; then
15414 cat >>confdefs.h <<\EOF
15415 #define NEED_WCHAR_H 1
15421 # if we do not find wint_t in either place, use substitution to provide a fallback.
15422 if test "$cf_cv_wint_t" = unknown ; then
15426 # if we find wint_t in either place, use substitution to provide a fallback.
15427 if test "$cf_cv_wint_t" != unknown ; then
15428 NCURSES_OK_WINT_T=1
15431 if test "$NCURSES_OK_MBSTATE_T" = 0 ; then
15433 echo "$as_me:15433: checking for type mbstate_t in ${cf_cv_ncurses_header:-curses.h}" >&5
15434 echo $ECHO_N "checking for type mbstate_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
15435 cat >conftest.$ac_ext <<_ACEOF
15436 #line 15436 "configure"
15437 #include "confdefs.h"
15439 #ifndef _XOPEN_SOURCE_EXTENDED
15440 #define _XOPEN_SOURCE_EXTENDED
15442 #include <${cf_cv_ncurses_header:-curses.h}>
15453 rm -f conftest.$ac_objext
15454 if { (eval echo "$as_me:15454: \"$ac_compile\"") >&5
15455 (eval $ac_compile) 2>&5
15457 echo "$as_me:15457: \$? = $ac_status" >&5
15458 (exit $ac_status); } &&
15459 { ac_try='test -s conftest.$ac_objext'
15460 { (eval echo "$as_me:15460: \"$ac_try\"") >&5
15461 (eval $ac_try) 2>&5
15463 echo "$as_me:15463: \$? = $ac_status" >&5
15464 (exit $ac_status); }; }; then
15467 echo "$as_me: failed program was:" >&5
15468 cat conftest.$ac_ext >&5
15471 rm -f conftest.$ac_objext conftest.$ac_ext
15472 echo "$as_me:15472: result: $cf_result" >&5
15473 echo "${ECHO_T}$cf_result" >&6
15474 if test $cf_result = yes ; then
15476 cf_result=`echo "have_type_mbstate_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
15478 cat >>confdefs.h <<EOF
15479 #define $cf_result 1
15483 cat >>confdefs.h <<EOF
15484 #define mbstate_t long
15491 if test "$NCURSES_OK_WCHAR_T" = 0 ; then
15493 echo "$as_me:15493: checking for type wchar_t in ${cf_cv_ncurses_header:-curses.h}" >&5
15494 echo $ECHO_N "checking for type wchar_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
15495 cat >conftest.$ac_ext <<_ACEOF
15496 #line 15496 "configure"
15497 #include "confdefs.h"
15499 #ifndef _XOPEN_SOURCE_EXTENDED
15500 #define _XOPEN_SOURCE_EXTENDED
15502 #include <${cf_cv_ncurses_header:-curses.h}>
15513 rm -f conftest.$ac_objext
15514 if { (eval echo "$as_me:15514: \"$ac_compile\"") >&5
15515 (eval $ac_compile) 2>&5
15517 echo "$as_me:15517: \$? = $ac_status" >&5
15518 (exit $ac_status); } &&
15519 { ac_try='test -s conftest.$ac_objext'
15520 { (eval echo "$as_me:15520: \"$ac_try\"") >&5
15521 (eval $ac_try) 2>&5
15523 echo "$as_me:15523: \$? = $ac_status" >&5
15524 (exit $ac_status); }; }; then
15527 echo "$as_me: failed program was:" >&5
15528 cat conftest.$ac_ext >&5
15531 rm -f conftest.$ac_objext conftest.$ac_ext
15532 echo "$as_me:15532: result: $cf_result" >&5
15533 echo "${ECHO_T}$cf_result" >&6
15534 if test $cf_result = yes ; then
15536 cf_result=`echo "have_type_wchar_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
15538 cat >>confdefs.h <<EOF
15539 #define $cf_result 1
15543 cat >>confdefs.h <<EOF
15544 #define wchar_t long
15551 if test "$NCURSES_OK_WINT_T" = 0 ; then
15553 echo "$as_me:15553: checking for type wint_t in ${cf_cv_ncurses_header:-curses.h}" >&5
15554 echo $ECHO_N "checking for type wint_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
15555 cat >conftest.$ac_ext <<_ACEOF
15556 #line 15556 "configure"
15557 #include "confdefs.h"
15559 #ifndef _XOPEN_SOURCE_EXTENDED
15560 #define _XOPEN_SOURCE_EXTENDED
15562 #include <${cf_cv_ncurses_header:-curses.h}>
15573 rm -f conftest.$ac_objext
15574 if { (eval echo "$as_me:15574: \"$ac_compile\"") >&5
15575 (eval $ac_compile) 2>&5
15577 echo "$as_me:15577: \$? = $ac_status" >&5
15578 (exit $ac_status); } &&
15579 { ac_try='test -s conftest.$ac_objext'
15580 { (eval echo "$as_me:15580: \"$ac_try\"") >&5
15581 (eval $ac_try) 2>&5
15583 echo "$as_me:15583: \$? = $ac_status" >&5
15584 (exit $ac_status); }; }; then
15587 echo "$as_me: failed program was:" >&5
15588 cat conftest.$ac_ext >&5
15591 rm -f conftest.$ac_objext conftest.$ac_ext
15592 echo "$as_me:15592: result: $cf_result" >&5
15593 echo "${ECHO_T}$cf_result" >&6
15594 if test $cf_result = yes ; then
15596 cf_result=`echo "have_type_wint_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
15598 cat >>confdefs.h <<EOF
15599 #define $cf_result 1
15603 cat >>confdefs.h <<EOF
15604 #define wint_t long
15612 echo "$as_me:15612: checking for data boolnames declaration in ${cf_cv_ncurses_header:-curses.h}" >&5
15613 echo $ECHO_N "checking for data boolnames declaration in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
15615 cat >conftest.$ac_ext <<_ACEOF
15616 #line 15616 "configure"
15617 #include "confdefs.h"
15619 #ifdef HAVE_XCURSES
15620 #include <xcurses.h>
15621 char * XCursesProgramName = "test";
15623 #include <${cf_cv_ncurses_header:-curses.h}>
15624 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
15625 #include <ncursesw/term.h>
15626 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
15627 #include <ncurses/term.h>
15628 #elif defined(HAVE_TERM_H)
15637 void *foo = &(boolnames)
15643 rm -f conftest.$ac_objext
15644 if { (eval echo "$as_me:15644: \"$ac_compile\"") >&5
15645 (eval $ac_compile) 2>&5
15647 echo "$as_me:15647: \$? = $ac_status" >&5
15648 (exit $ac_status); } &&
15649 { ac_try='test -s conftest.$ac_objext'
15650 { (eval echo "$as_me:15650: \"$ac_try\"") >&5
15651 (eval $ac_try) 2>&5
15653 echo "$as_me:15653: \$? = $ac_status" >&5
15654 (exit $ac_status); }; }; then
15657 echo "$as_me: failed program was:" >&5
15658 cat conftest.$ac_ext >&5
15661 rm -f conftest.$ac_objext conftest.$ac_ext
15662 echo "$as_me:15662: result: $cf_result" >&5
15663 echo "${ECHO_T}$cf_result" >&6
15665 if test $cf_result = yes ; then
15667 cf_result=`echo "have_curses_data_boolnames" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
15669 cat >>confdefs.h <<EOF
15670 #define $cf_result 1
15674 echo "$as_me:15674: checking for data boolnames in library" >&5
15675 echo $ECHO_N "checking for data boolnames in library... $ECHO_C" >&6
15676 # BSD linkers insist on making weak linkage, but resolve at runtime.
15677 if test "$cross_compiling" = yes; then
15680 cat >conftest.$ac_ext <<_ACEOF
15681 #line 15681 "configure"
15682 #include "confdefs.h"
15684 #ifdef HAVE_XCURSES
15685 #include <xcurses.h>
15686 char * XCursesProgramName = "test";
15688 #include <${cf_cv_ncurses_header:-curses.h}>
15689 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
15690 #include <ncursesw/term.h>
15691 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
15692 #include <ncurses/term.h>
15693 #elif defined(HAVE_TERM_H)
15698 extern char boolnames;
15704 void *foo = &(boolnames);
15705 ${cf_cv_main_return:-return}(foo == 0);
15712 rm -f conftest.$ac_objext conftest$ac_exeext
15713 if { (eval echo "$as_me:15713: \"$ac_link\"") >&5
15714 (eval $ac_link) 2>&5
15716 echo "$as_me:15716: \$? = $ac_status" >&5
15717 (exit $ac_status); } &&
15718 { ac_try='test -s conftest$ac_exeext'
15719 { (eval echo "$as_me:15719: \"$ac_try\"") >&5
15720 (eval $ac_try) 2>&5
15722 echo "$as_me:15722: \$? = $ac_status" >&5
15723 (exit $ac_status); }; }; then
15726 echo "$as_me: failed program was:" >&5
15727 cat conftest.$ac_ext >&5
15730 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15733 cat >conftest.$ac_ext <<_ACEOF
15734 #line 15734 "configure"
15735 #include "confdefs.h"
15737 #ifdef HAVE_XCURSES
15738 #include <xcurses.h>
15739 char * XCursesProgramName = "test";
15741 #include <${cf_cv_ncurses_header:-curses.h}>
15742 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
15743 #include <ncursesw/term.h>
15744 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
15745 #include <ncurses/term.h>
15746 #elif defined(HAVE_TERM_H)
15751 extern char boolnames;
15754 void *foo = &(boolnames);
15755 ${cf_cv_main_return:-return}(foo == 0);
15758 rm -f conftest$ac_exeext
15759 if { (eval echo "$as_me:15759: \"$ac_link\"") >&5
15760 (eval $ac_link) 2>&5
15762 echo "$as_me:15762: \$? = $ac_status" >&5
15763 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15764 { (eval echo "$as_me:15764: \"$ac_try\"") >&5
15765 (eval $ac_try) 2>&5
15767 echo "$as_me:15767: \$? = $ac_status" >&5
15768 (exit $ac_status); }; }; then
15771 echo "$as_me: program exited with status $ac_status" >&5
15772 echo "$as_me: failed program was:" >&5
15773 cat conftest.$ac_ext >&5
15776 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15778 echo "$as_me:15778: result: $cf_result" >&5
15779 echo "${ECHO_T}$cf_result" >&6
15780 if test $cf_result = yes ; then
15782 cf_result=`echo "decl_curses_data_boolnames" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
15784 cat >>confdefs.h <<EOF
15785 #define $cf_result 1
15791 echo "$as_me:15791: checking for data boolfnames declaration in ${cf_cv_ncurses_header:-curses.h}" >&5
15792 echo $ECHO_N "checking for data boolfnames declaration in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
15794 cat >conftest.$ac_ext <<_ACEOF
15795 #line 15795 "configure"
15796 #include "confdefs.h"
15798 #ifdef HAVE_XCURSES
15799 #include <xcurses.h>
15800 char * XCursesProgramName = "test";
15802 #include <${cf_cv_ncurses_header:-curses.h}>
15803 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
15804 #include <ncursesw/term.h>
15805 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
15806 #include <ncurses/term.h>
15807 #elif defined(HAVE_TERM_H)
15816 void *foo = &(boolfnames)
15822 rm -f conftest.$ac_objext
15823 if { (eval echo "$as_me:15823: \"$ac_compile\"") >&5
15824 (eval $ac_compile) 2>&5
15826 echo "$as_me:15826: \$? = $ac_status" >&5
15827 (exit $ac_status); } &&
15828 { ac_try='test -s conftest.$ac_objext'
15829 { (eval echo "$as_me:15829: \"$ac_try\"") >&5
15830 (eval $ac_try) 2>&5
15832 echo "$as_me:15832: \$? = $ac_status" >&5
15833 (exit $ac_status); }; }; then
15836 echo "$as_me: failed program was:" >&5
15837 cat conftest.$ac_ext >&5
15840 rm -f conftest.$ac_objext conftest.$ac_ext
15841 echo "$as_me:15841: result: $cf_result" >&5
15842 echo "${ECHO_T}$cf_result" >&6
15844 if test $cf_result = yes ; then
15846 cf_result=`echo "have_curses_data_boolfnames" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
15848 cat >>confdefs.h <<EOF
15849 #define $cf_result 1
15853 echo "$as_me:15853: checking for data boolfnames in library" >&5
15854 echo $ECHO_N "checking for data boolfnames in library... $ECHO_C" >&6
15855 # BSD linkers insist on making weak linkage, but resolve at runtime.
15856 if test "$cross_compiling" = yes; then
15859 cat >conftest.$ac_ext <<_ACEOF
15860 #line 15860 "configure"
15861 #include "confdefs.h"
15863 #ifdef HAVE_XCURSES
15864 #include <xcurses.h>
15865 char * XCursesProgramName = "test";
15867 #include <${cf_cv_ncurses_header:-curses.h}>
15868 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
15869 #include <ncursesw/term.h>
15870 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
15871 #include <ncurses/term.h>
15872 #elif defined(HAVE_TERM_H)
15877 extern char boolfnames;
15883 void *foo = &(boolfnames);
15884 ${cf_cv_main_return:-return}(foo == 0);
15891 rm -f conftest.$ac_objext conftest$ac_exeext
15892 if { (eval echo "$as_me:15892: \"$ac_link\"") >&5
15893 (eval $ac_link) 2>&5
15895 echo "$as_me:15895: \$? = $ac_status" >&5
15896 (exit $ac_status); } &&
15897 { ac_try='test -s conftest$ac_exeext'
15898 { (eval echo "$as_me:15898: \"$ac_try\"") >&5
15899 (eval $ac_try) 2>&5
15901 echo "$as_me:15901: \$? = $ac_status" >&5
15902 (exit $ac_status); }; }; then
15905 echo "$as_me: failed program was:" >&5
15906 cat conftest.$ac_ext >&5
15909 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15912 cat >conftest.$ac_ext <<_ACEOF
15913 #line 15913 "configure"
15914 #include "confdefs.h"
15916 #ifdef HAVE_XCURSES
15917 #include <xcurses.h>
15918 char * XCursesProgramName = "test";
15920 #include <${cf_cv_ncurses_header:-curses.h}>
15921 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
15922 #include <ncursesw/term.h>
15923 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
15924 #include <ncurses/term.h>
15925 #elif defined(HAVE_TERM_H)
15930 extern char boolfnames;
15933 void *foo = &(boolfnames);
15934 ${cf_cv_main_return:-return}(foo == 0);
15937 rm -f conftest$ac_exeext
15938 if { (eval echo "$as_me:15938: \"$ac_link\"") >&5
15939 (eval $ac_link) 2>&5
15941 echo "$as_me:15941: \$? = $ac_status" >&5
15942 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15943 { (eval echo "$as_me:15943: \"$ac_try\"") >&5
15944 (eval $ac_try) 2>&5
15946 echo "$as_me:15946: \$? = $ac_status" >&5
15947 (exit $ac_status); }; }; then
15950 echo "$as_me: program exited with status $ac_status" >&5
15951 echo "$as_me: failed program was:" >&5
15952 cat conftest.$ac_ext >&5
15955 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15957 echo "$as_me:15957: result: $cf_result" >&5
15958 echo "${ECHO_T}$cf_result" >&6
15959 if test $cf_result = yes ; then
15961 cf_result=`echo "decl_curses_data_boolfnames" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
15963 cat >>confdefs.h <<EOF
15964 #define $cf_result 1
15971 echo "$as_me:15971: checking for an rpath option" >&5
15972 echo $ECHO_N "checking for an rpath option... $ECHO_C" >&6
15973 case $cf_cv_system_name in #(vi
15975 if test "$GCC" = yes; then
15976 LD_RPATH_OPT="-Wl,-rpath,"
15978 LD_RPATH_OPT="-rpath "
15981 linux*|gnu*|k*bsd*-gnu) #(vi
15982 LD_RPATH_OPT="-Wl,-rpath,"
15984 openbsd[2-9].*|mirbsd*) #(vi
15985 LD_RPATH_OPT="-Wl,-rpath,"
15987 dragonfly*|freebsd*) #(vi
15988 LD_RPATH_OPT="-rpath "
15991 LD_RPATH_OPT="-Wl,-rpath,"
15994 LD_RPATH_OPT="-rpath "
16002 echo "$as_me:16002: result: $LD_RPATH_OPT" >&5
16003 echo "${ECHO_T}$LD_RPATH_OPT" >&6
16005 case "x$LD_RPATH_OPT" in #(vi
16007 echo "$as_me:16007: checking if we need a space after rpath option" >&5
16008 echo $ECHO_N "checking if we need a space after rpath option... $ECHO_C" >&6
16009 cf_save_LIBS="$LIBS"
16010 LIBS="${LD_RPATH_OPT}$libdir $LIBS"
16011 cat >conftest.$ac_ext <<_ACEOF
16012 #line 16012 "configure"
16013 #include "confdefs.h"
16023 rm -f conftest.$ac_objext conftest$ac_exeext
16024 if { (eval echo "$as_me:16024: \"$ac_link\"") >&5
16025 (eval $ac_link) 2>&5
16027 echo "$as_me:16027: \$? = $ac_status" >&5
16028 (exit $ac_status); } &&
16029 { ac_try='test -s conftest$ac_exeext'
16030 { (eval echo "$as_me:16030: \"$ac_try\"") >&5
16031 (eval $ac_try) 2>&5
16033 echo "$as_me:16033: \$? = $ac_status" >&5
16034 (exit $ac_status); }; }; then
16037 echo "$as_me: failed program was:" >&5
16038 cat conftest.$ac_ext >&5
16041 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16042 LIBS="$cf_save_LIBS"
16043 echo "$as_me:16043: result: $cf_rpath_space" >&5
16044 echo "${ECHO_T}$cf_rpath_space" >&6
16045 test "$cf_rpath_space" = yes && LD_RPATH_OPT="$LD_RPATH_OPT "
16049 echo "$as_me:16049: checking if rpath-hack should be disabled" >&5
16050 echo $ECHO_N "checking if rpath-hack should be disabled... $ECHO_C" >&6
16052 # Check whether --enable-rpath-hack or --disable-rpath-hack was given.
16053 if test "${enable_rpath_hack+set}" = set; then
16054 enableval="$enable_rpath_hack"
16055 test "$enableval" != no && enableval=yes
16056 if test "$enableval" != "yes" ; then
16057 cf_disable_rpath_hack=yes
16059 cf_disable_rpath_hack=no
16063 cf_disable_rpath_hack=no
16066 echo "$as_me:16066: result: $cf_disable_rpath_hack" >&5
16067 echo "${ECHO_T}$cf_disable_rpath_hack" >&6
16068 if test "$cf_disable_rpath_hack" = no ; then
16070 echo "$as_me:16070: checking for updated LDFLAGS" >&5
16071 echo $ECHO_N "checking for updated LDFLAGS... $ECHO_C" >&6
16072 if test -n "$LD_RPATH_OPT" ; then
16073 echo "$as_me:16073: result: maybe" >&5
16074 echo "${ECHO_T}maybe" >&6
16078 # Extract the first word of "$ac_prog", so it can be a program name with args.
16079 set dummy $ac_prog; ac_word=$2
16080 echo "$as_me:16080: checking for $ac_word" >&5
16081 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
16082 if test "${ac_cv_prog_cf_ldd_prog+set}" = set; then
16083 echo $ECHO_N "(cached) $ECHO_C" >&6
16085 if test -n "$cf_ldd_prog"; then
16086 ac_cv_prog_cf_ldd_prog="$cf_ldd_prog" # Let the user override the test.
16088 ac_save_IFS=$IFS; IFS=$ac_path_separator
16090 for ac_dir in $ac_dummy; do
16092 test -z "$ac_dir" && ac_dir=.
16093 $as_executable_p "$ac_dir/$ac_word" || continue
16094 ac_cv_prog_cf_ldd_prog="$ac_prog"
16095 echo "$as_me:16095: found $ac_dir/$ac_word" >&5
16101 cf_ldd_prog=$ac_cv_prog_cf_ldd_prog
16102 if test -n "$cf_ldd_prog"; then
16103 echo "$as_me:16103: result: $cf_ldd_prog" >&5
16104 echo "${ECHO_T}$cf_ldd_prog" >&6
16106 echo "$as_me:16106: result: no" >&5
16107 echo "${ECHO_T}no" >&6
16110 test -n "$cf_ldd_prog" && break
16112 test -n "$cf_ldd_prog" || cf_ldd_prog="no"
16114 cf_rpath_list="/usr/lib /lib"
16115 if test "$cf_ldd_prog" != no
16119 cat >conftest.$ac_ext <<_ACEOF
16120 #line 16120 "configure"
16121 #include "confdefs.h"
16131 rm -f conftest.$ac_objext conftest$ac_exeext
16132 if { (eval echo "$as_me:16132: \"$ac_link\"") >&5
16133 (eval $ac_link) 2>&5
16135 echo "$as_me:16135: \$? = $ac_status" >&5
16136 (exit $ac_status); } &&
16137 { ac_try='test -s conftest$ac_exeext'
16138 { (eval echo "$as_me:16138: \"$ac_try\"") >&5
16139 (eval $ac_try) 2>&5
16141 echo "$as_me:16141: \$? = $ac_status" >&5
16142 (exit $ac_status); }; }; then
16143 cf_rpath_oops=`$cf_ldd_prog conftest$ac_exeext | fgrep ' not found' | sed -e 's% =>.*$%%' |sort -u`
16144 cf_rpath_list=`$cf_ldd_prog conftest$ac_exeext | fgrep / | sed -e 's%^.*[ ]/%/%' -e 's%/[^/][^/]*$%%' |sort -u`
16146 echo "$as_me: failed program was:" >&5
16147 cat conftest.$ac_ext >&5
16149 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16151 # If we passed the link-test, but get a "not found" on a given library,
16152 # this could be due to inept reconfiguration of gcc to make it only
16153 # partly honor /usr/local/lib (or whatever). Sometimes this behavior
16154 # is intentional, e.g., installing gcc in /usr/bin and suppressing the
16155 # /usr/local libraries.
16156 if test -n "$cf_rpath_oops"
16158 for cf_rpath_src in $cf_rpath_oops
16160 for cf_rpath_dir in \
16165 if test -f $cf_rpath_dir/lib/$cf_rpath_src
16167 test -n "$verbose" && echo " ...adding -L$cf_rpath_dir/lib to LDFLAGS for $cf_rpath_src" 1>&6
16169 echo "${as_me:-configure}:16169: testing ...adding -L$cf_rpath_dir/lib to LDFLAGS for $cf_rpath_src ..." 1>&5
16171 LDFLAGS="$LDFLAGS -L$cf_rpath_dir/lib"
16179 test -n "$verbose" && echo " ...checking EXTRA_LDFLAGS $EXTRA_LDFLAGS" 1>&6
16181 echo "${as_me:-configure}:16181: testing ...checking EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5
16183 test -n "$verbose" && echo " ...checking LDFLAGS $LDFLAGS" 1>&6
16185 echo "${as_me:-configure}:16185: testing ...checking LDFLAGS $LDFLAGS ..." 1>&5
16188 for cf_rpath_src in $LDFLAGS
16190 case $cf_rpath_src in #(vi
16193 # check if this refers to a directory which we will ignore
16195 if test -n "$cf_rpath_list"
16197 for cf_rpath_item in $cf_rpath_list
16199 if test "x$cf_rpath_src" = "x-L$cf_rpath_item"
16207 if test "$cf_rpath_skip" = no
16209 # transform the option
16210 if test "$LD_RPATH_OPT" = "-R " ; then
16211 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%-R %"`
16213 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%$LD_RPATH_OPT%"`
16216 # if we have not already added this, add it now
16217 cf_rpath_tst=`echo "$EXTRA_LDFLAGS" | sed -e "s%$cf_rpath_tmp %%"`
16218 if test "x$cf_rpath_tst" = "x$EXTRA_LDFLAGS"
16220 test -n "$verbose" && echo " ...Filter $cf_rpath_src ->$cf_rpath_tmp" 1>&6
16222 echo "${as_me:-configure}:16222: testing ...Filter $cf_rpath_src ->$cf_rpath_tmp ..." 1>&5
16224 EXTRA_LDFLAGS="$cf_rpath_tmp $EXTRA_LDFLAGS"
16229 cf_rpath_dst="$cf_rpath_dst $cf_rpath_src"
16231 LDFLAGS=$cf_rpath_dst
16233 test -n "$verbose" && echo " ...checked LDFLAGS $LDFLAGS" 1>&6
16235 echo "${as_me:-configure}:16235: testing ...checked LDFLAGS $LDFLAGS ..." 1>&5
16237 test -n "$verbose" && echo " ...checking LIBS $LIBS" 1>&6
16239 echo "${as_me:-configure}:16239: testing ...checking LIBS $LIBS ..." 1>&5
16242 for cf_rpath_src in $LIBS
16244 case $cf_rpath_src in #(vi
16247 # check if this refers to a directory which we will ignore
16249 if test -n "$cf_rpath_list"
16251 for cf_rpath_item in $cf_rpath_list
16253 if test "x$cf_rpath_src" = "x-L$cf_rpath_item"
16261 if test "$cf_rpath_skip" = no
16263 # transform the option
16264 if test "$LD_RPATH_OPT" = "-R " ; then
16265 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%-R %"`
16267 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%$LD_RPATH_OPT%"`
16270 # if we have not already added this, add it now
16271 cf_rpath_tst=`echo "$EXTRA_LDFLAGS" | sed -e "s%$cf_rpath_tmp %%"`
16272 if test "x$cf_rpath_tst" = "x$EXTRA_LDFLAGS"
16274 test -n "$verbose" && echo " ...Filter $cf_rpath_src ->$cf_rpath_tmp" 1>&6
16276 echo "${as_me:-configure}:16276: testing ...Filter $cf_rpath_src ->$cf_rpath_tmp ..." 1>&5
16278 EXTRA_LDFLAGS="$cf_rpath_tmp $EXTRA_LDFLAGS"
16283 cf_rpath_dst="$cf_rpath_dst $cf_rpath_src"
16287 test -n "$verbose" && echo " ...checked LIBS $LIBS" 1>&6
16289 echo "${as_me:-configure}:16289: testing ...checked LIBS $LIBS ..." 1>&5
16291 test -n "$verbose" && echo " ...checked EXTRA_LDFLAGS $EXTRA_LDFLAGS" 1>&6
16293 echo "${as_me:-configure}:16293: testing ...checked EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5
16302 ac_config_files="$ac_config_files Makefile"
16303 ac_config_commands="$ac_config_commands default"
16304 cat >confcache <<\_ACEOF
16305 # This file is a shell script that caches the results of configure
16306 # tests run on this system so they can be shared between configure
16307 # scripts and configure runs, see configure's option --config-cache.
16308 # It is not useful on other systems. If it contains results you don't
16309 # want to keep, you may remove or edit it.
16311 # config.status only pays attention to the cache file if you give it
16312 # the --recheck option to rerun configure.
16314 # `ac_cv_env_foo' variables (set or unset) will be overriden when
16315 # loading this file, other *unset* `ac_cv_foo' will be assigned the
16316 # following values.
16320 # The following way of writing the cache mishandles newlines in values,
16321 # but we know of no workaround that is simple, portable, and efficient.
16322 # So, don't put newlines in cache variables' values.
16323 # Ultrix sh set writes to stderr and can't be redirected directly,
16324 # and sets the high bit in the cache file unless we assign to the vars.
16327 case `(ac_space=' '; set | grep ac_space) 2>&1` in
16329 # `set' does not quote correctly, so add quotes (double-quote
16330 # substitution turns \\\\ into \\, and sed turns \\ into \).
16333 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
16336 # `set' quotes correctly as required by POSIX, so do not add quotes.
16338 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
16345 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
16347 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
16349 if cmp -s $cache_file confcache; then :; else
16350 if test -w $cache_file; then
16351 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
16352 cat confcache >$cache_file
16354 echo "not updating unwritable cache $cache_file"
16359 test "x$prefix" = xNONE && prefix=$ac_default_prefix
16360 # Let make expand exec_prefix.
16361 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
16363 # VPATH may cause trouble with some makes, so we remove $(srcdir),
16364 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
16365 # trailing colons and then remove the whole line if VPATH becomes empty
16366 # (actually we leave an empty line to preserve line numbers).
16367 if test "x$srcdir" = x.; then
16368 ac_vpsub='/^[ ]*VPATH[ ]*=/{
16369 s/:*\$(srcdir):*/:/;
16370 s/:*\${srcdir}:*/:/;
16372 s/^\([^=]*=[ ]*\):*/\1/;
16378 DEFS=-DHAVE_CONFIG_H
16380 : ${CONFIG_STATUS=./config.status}
16381 ac_clean_files_save=$ac_clean_files
16382 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
16383 { echo "$as_me:16383: creating $CONFIG_STATUS" >&5
16384 echo "$as_me: creating $CONFIG_STATUS" >&6;}
16385 cat >$CONFIG_STATUS <<_ACEOF
16387 # Generated automatically by configure.
16388 # Run this file to recreate the current configuration.
16389 # Compiler output produced by configure, useful for debugging
16390 # configure, is in config.log if it exists.
16393 SHELL=\${CONFIG_SHELL-$SHELL}
16394 ac_cs_invocation="\$0 \$@"
16398 cat >>$CONFIG_STATUS <<\_ACEOF
16399 # Be Bourne compatible
16400 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
16403 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
16407 # Name of the executable.
16408 as_me=`echo "$0" |sed 's,.*[\\/],,'`
16410 if expr a : '\(a\)' >/dev/null 2>&1; then
16416 rm -f conf$$ conf$$.exe conf$$.file
16418 if ln -s conf$$.file conf$$ 2>/dev/null; then
16419 # We could just check for DJGPP; but this test a) works b) is more generic
16420 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
16421 if test -f conf$$.exe; then
16422 # Don't use ln at all; we don't have any links
16427 elif ln conf$$.file conf$$ 2>/dev/null; then
16432 rm -f conf$$ conf$$.exe conf$$.file
16434 as_executable_p="test -f"
16436 # Support unset when possible.
16437 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
16444 $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
16445 $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
16446 $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
16447 $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
16448 $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
16449 $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
16450 $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
16451 $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
16454 # We need space, tab and new line, in precisely that order.
16460 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
16466 # Files that config.status was made for.
16467 if test -n "$ac_config_files"; then
16468 echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
16471 if test -n "$ac_config_headers"; then
16472 echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
16475 if test -n "$ac_config_links"; then
16476 echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
16479 if test -n "$ac_config_commands"; then
16480 echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
16483 cat >>$CONFIG_STATUS <<\EOF
16486 \`$as_me' instantiates files from templates according to the
16487 current configuration.
16489 Usage: $0 [OPTIONS] [FILE]...
16491 -h, --help print this help, then exit
16492 -V, --version print version number, then exit
16493 -d, --debug don't remove temporary files
16494 --recheck update $as_me by reconfiguring in the same conditions
16495 --file=FILE[:TEMPLATE]
16496 instantiate the configuration file FILE
16497 --header=FILE[:TEMPLATE]
16498 instantiate the configuration header FILE
16500 Configuration files:
16503 Configuration headers:
16506 Configuration commands:
16509 Report bugs to <dickey@invisible-island.net>."
16512 cat >>$CONFIG_STATUS <<EOF
16515 configured by $0, generated by GNU Autoconf 2.52.20101002,
16516 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
16518 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
16519 Free Software Foundation, Inc.
16520 This config.status script is free software; the Free Software Foundation
16521 gives unlimited permission to copy, distribute and modify it."
16526 cat >>$CONFIG_STATUS <<\EOF
16527 # If no file are specified by the user, then we need to provide default
16528 # value. By we need to know if files were specified by the user.
16534 ac_option=`expr "x$1" : 'x\([^=]*\)='`
16535 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
16537 set dummy "$ac_option" "$ac_optarg" ${1+"$@"}
16541 *) # This is not an option, so the user has probably given explicit
16543 ac_need_defaults=false;;
16547 # Handling of the options.
16549 cat >>$CONFIG_STATUS <<EOF
16550 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
16551 echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion"
16552 exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;;
16554 cat >>$CONFIG_STATUS <<\EOF
16555 --version | --vers* | -V )
16556 echo "$ac_cs_version"; exit 0 ;;
16558 # Conflict between --help and --header
16559 { { echo "$as_me:16559: error: ambiguous option: $1
16560 Try \`$0 --help' for more information." >&5
16561 echo "$as_me: error: ambiguous option: $1
16562 Try \`$0 --help' for more information." >&2;}
16563 { (exit 1); exit 1; }; };;
16564 --help | --hel | -h )
16565 echo "$ac_cs_usage"; exit 0 ;;
16566 --debug | --d* | -d )
16568 --file | --fil | --fi | --f )
16570 CONFIG_FILES="$CONFIG_FILES $1"
16571 ac_need_defaults=false;;
16572 --header | --heade | --head | --hea )
16574 CONFIG_HEADERS="$CONFIG_HEADERS $1"
16575 ac_need_defaults=false;;
16577 # This is an error.
16578 -*) { { echo "$as_me:16578: error: unrecognized option: $1
16579 Try \`$0 --help' for more information." >&5
16580 echo "$as_me: error: unrecognized option: $1
16581 Try \`$0 --help' for more information." >&2;}
16582 { (exit 1); exit 1; }; } ;;
16584 *) ac_config_targets="$ac_config_targets $1" ;;
16593 ## ----------------------- ##
16594 ## Running config.status. ##
16595 ## ----------------------- ##
16597 This file was extended by $as_me 2.52.20101002, executed with
16598 CONFIG_FILES = $CONFIG_FILES
16599 CONFIG_HEADERS = $CONFIG_HEADERS
16600 CONFIG_LINKS = $CONFIG_LINKS
16601 CONFIG_COMMANDS = $CONFIG_COMMANDS
16602 > $ac_cs_invocation
16603 on `(hostname || uname -n) 2>/dev/null | sed 1q`
16608 cat >>$CONFIG_STATUS <<EOF
16610 # INIT-COMMANDS section.
16618 cat >>$CONFIG_STATUS <<\EOF
16619 for ac_config_target in $ac_config_targets
16621 case "$ac_config_target" in
16622 # Handling of arguments.
16623 "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
16624 "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
16625 "ncurses_cfg.h" ) CONFIG_HEADERS="$CONFIG_HEADERS ncurses_cfg.h:ncurses_tst.hin" ;;
16626 *) { { echo "$as_me:16626: error: invalid argument: $ac_config_target" >&5
16627 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
16628 { (exit 1); exit 1; }; };;
16632 # If the user did not use the arguments to specify the items to instantiate,
16633 # then the envvar interface is used. Set only those that are not.
16634 # We use the long form for the default assignment because of an extremely
16635 # bizarre bug on SunOS 4.1.3.
16636 if $ac_need_defaults; then
16637 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
16638 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
16639 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
16642 # Create a temporary directory, and hook for its removal unless debugging.
16645 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
16646 trap '{ (exit 1); exit 1; }' 1 2 13 15
16649 # Create a (secure) tmp directory for tmp files.
16652 tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` &&
16653 test -n "$tmp" && test -d "$tmp"
16656 tmp=$TMPDIR/cs$$-$RANDOM
16657 (umask 077 && mkdir $tmp)
16660 echo "$me: cannot create a temporary directory in $TMPDIR" >&2
16661 { (exit 1); exit 1; }
16666 cat >>$CONFIG_STATUS <<EOF
16669 # CONFIG_FILES section.
16672 # No need to generate the scripts if there are no CONFIG_FILES.
16673 # This happens for instance when ./config.status config.h
16674 if test -n "\$CONFIG_FILES"; then
16675 # Protect against being on the right side of a sed subst in config.status.
16676 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
16677 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
16678 s,@SHELL@,$SHELL,;t t
16679 s,@exec_prefix@,$exec_prefix,;t t
16680 s,@prefix@,$prefix,;t t
16681 s,@program_transform_name@,$program_transform_name,;t t
16682 s,@bindir@,$bindir,;t t
16683 s,@sbindir@,$sbindir,;t t
16684 s,@libexecdir@,$libexecdir,;t t
16685 s,@datadir@,$datadir,;t t
16686 s,@sysconfdir@,$sysconfdir,;t t
16687 s,@sharedstatedir@,$sharedstatedir,;t t
16688 s,@localstatedir@,$localstatedir,;t t
16689 s,@libdir@,$libdir,;t t
16690 s,@includedir@,$includedir,;t t
16691 s,@oldincludedir@,$oldincludedir,;t t
16692 s,@infodir@,$infodir,;t t
16693 s,@mandir@,$mandir,;t t
16694 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
16695 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
16696 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
16697 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
16698 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
16699 s,@build_alias@,$build_alias,;t t
16700 s,@host_alias@,$host_alias,;t t
16701 s,@target_alias@,$target_alias,;t t
16702 s,@ECHO_C@,$ECHO_C,;t t
16703 s,@ECHO_N@,$ECHO_N,;t t
16704 s,@ECHO_T@,$ECHO_T,;t t
16705 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
16706 s,@DEFS@,$DEFS,;t t
16707 s,@LIBS@,$LIBS,;t t
16708 s,@build@,$build,;t t
16709 s,@build_cpu@,$build_cpu,;t t
16710 s,@build_vendor@,$build_vendor,;t t
16711 s,@build_os@,$build_os,;t t
16712 s,@host@,$host,;t t
16713 s,@host_cpu@,$host_cpu,;t t
16714 s,@host_vendor@,$host_vendor,;t t
16715 s,@host_os@,$host_os,;t t
16716 s,@SET_MAKE@,$SET_MAKE,;t t
16718 s,@CFLAGS@,$CFLAGS,;t t
16719 s,@LDFLAGS@,$LDFLAGS,;t t
16720 s,@CPPFLAGS@,$CPPFLAGS,;t t
16721 s,@ac_ct_CC@,$ac_ct_CC,;t t
16722 s,@EXEEXT@,$EXEEXT,;t t
16723 s,@OBJEXT@,$OBJEXT,;t t
16726 s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
16727 s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
16728 s,@INSTALL_DATA@,$INSTALL_DATA,;t t
16729 s,@LINT@,$LINT,;t t
16730 s,@LINT_OPTS@,$LINT_OPTS,;t t
16731 s,@CTAGS@,$CTAGS,;t t
16732 s,@ETAGS@,$ETAGS,;t t
16733 s,@MAKE_LOWER_TAGS@,$MAKE_LOWER_TAGS,;t t
16734 s,@MAKE_UPPER_TAGS@,$MAKE_UPPER_TAGS,;t t
16735 s,@MATH_LIB@,$MATH_LIB,;t t
16736 s,@top_builddir@,$top_builddir,;t t
16737 s,@CC_G_OPT@,$CC_G_OPT,;t t
16738 s,@CC_SHARED_OPTS@,$CC_SHARED_OPTS,;t t
16739 s,@DFT_DEP_SUFFIX@,$DFT_DEP_SUFFIX,;t t
16740 s,@DFT_OBJ_SUBDIR@,$DFT_OBJ_SUBDIR,;t t
16741 s,@DFT_UPR_MODEL@,$DFT_UPR_MODEL,;t t
16743 s,@LDFLAGS_SHARED@,$LDFLAGS_SHARED,;t t
16744 s,@LDFLAGS_STATIC@,$LDFLAGS_STATIC,;t t
16745 s,@LD_MODEL@,$LD_MODEL,;t t
16746 s,@LD_SHARED_OPTS@,$LD_SHARED_OPTS,;t t
16747 s,@LIBTOOL@,$LIBTOOL,;t t
16748 s,@LIB_CLEAN@,$LIB_CLEAN,;t t
16749 s,@LIB_COMPILE@,$LIB_COMPILE,;t t
16750 s,@LIB_LINK@,$LIB_LINK,;t t
16751 s,@LINK_TESTS@,$LINK_TESTS,;t t
16752 s,@LOCAL_LDFLAGS@,$LOCAL_LDFLAGS,;t t
16753 s,@PTHREAD@,$PTHREAD,;t t
16754 s,@TEST_ARGS@,$TEST_ARGS,;t t
16755 s,@TEST_DEPS@,$TEST_DEPS,;t t
16756 s,@TEST_LIBS@,$TEST_LIBS,;t t
16757 s,@TINFO_LDFLAGS@,$TINFO_LDFLAGS,;t t
16758 s,@TINFO_LIBS@,$TINFO_LIBS,;t t
16759 s,@cf_cv_abi_version@,$cf_cv_abi_version,;t t
16760 s,@cf_cv_rel_version@,$cf_cv_rel_version,;t t
16761 s,@EXTRA_CPPFLAGS@,$EXTRA_CPPFLAGS,;t t
16762 s,@ECHO_LT@,$ECHO_LT,;t t
16763 s,@ECHO_LD@,$ECHO_LD,;t t
16764 s,@RULE_CC@,$RULE_CC,;t t
16765 s,@SHOW_CC@,$SHOW_CC,;t t
16766 s,@ECHO_CC@,$ECHO_CC,;t t
16767 s,@EXTRA_CFLAGS@,$EXTRA_CFLAGS,;t t
16768 s,@NCURSES_CONFIG@,$NCURSES_CONFIG,;t t
16769 s,@ac_ct_NCURSES_CONFIG@,$ac_ct_NCURSES_CONFIG,;t t
16770 s,@PKG_CONFIG@,$PKG_CONFIG,;t t
16771 s,@ac_pt_PKG_CONFIG@,$ac_pt_PKG_CONFIG,;t t
16772 s,@X_CFLAGS@,$X_CFLAGS,;t t
16773 s,@X_PRE_LIBS@,$X_PRE_LIBS,;t t
16774 s,@X_LIBS@,$X_LIBS,;t t
16775 s,@X_EXTRA_LIBS@,$X_EXTRA_LIBS,;t t
16776 s,@XCURSES_CONFIG@,$XCURSES_CONFIG,;t t
16777 s,@ac_ct_XCURSES_CONFIG@,$ac_ct_XCURSES_CONFIG,;t t
16778 s,@NCURSES_WRAP_PREFIX@,$NCURSES_WRAP_PREFIX,;t t
16779 s,@cf_ldd_prog@,$cf_ldd_prog,;t t
16780 s,@EXTRA_LDFLAGS@,$EXTRA_LDFLAGS,;t t
16785 cat >>$CONFIG_STATUS <<\EOF
16786 # Split the substitutions into bite-sized pieces for seds with
16787 # small command number limits, like on Digital OSF/1 and HP-UX.
16788 ac_max_sed_lines=48
16789 ac_sed_frag=1 # Number of current file.
16790 ac_beg=1 # First line for current file.
16791 ac_end=$ac_max_sed_lines # Line after last line for current file.
16794 while $ac_more_lines; do
16795 if test $ac_beg -gt 1; then
16796 sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
16798 sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
16800 if test ! -s $tmp/subs.frag; then
16801 ac_more_lines=false
16803 # The purpose of the label and of the branching condition is to
16804 # speed up the sed processing (if there are no `@' at all, there
16805 # is no need to browse any of the substitutions).
16806 # These are the two extra sed commands mentioned above.
16808 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
16809 if test -z "$ac_sed_cmds"; then
16810 ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
16812 ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
16814 ac_sed_frag=`expr $ac_sed_frag + 1`
16816 ac_end=`expr $ac_end + $ac_max_sed_lines`
16819 if test -z "$ac_sed_cmds"; then
16822 fi # test -n "$CONFIG_FILES"
16825 cat >>$CONFIG_STATUS <<\EOF
16826 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
16827 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
16829 - | *:- | *:-:* ) # input from stdin
16831 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
16832 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
16833 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
16834 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
16835 * ) ac_file_in=$ac_file.in ;;
16838 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
16839 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
16840 X"$ac_file" : 'X\(//\)[^/]' \| \
16841 X"$ac_file" : 'X\(//\)$' \| \
16842 X"$ac_file" : 'X\(/\)' \| \
16843 . : '\(.\)' 2>/dev/null ||
16845 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
16846 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
16847 /^X\(\/\/\)$/{ s//\1/; q; }
16848 /^X\(\/\).*/{ s//\1/; q; }
16850 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
16851 { case "$ac_dir" in
16852 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
16856 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
16857 case $as_mkdir_dir in
16858 # Skip DOS drivespec
16859 ?:) as_incr_dir=$as_mkdir_dir ;;
16861 as_incr_dir=$as_incr_dir/$as_mkdir_dir
16862 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
16867 ac_dir_suffix="/`echo $ac_dir|sed 's,^\./,,'`"
16868 # A "../" for each directory in $ac_dir_suffix.
16869 ac_dots=`echo "$ac_dir_suffix" | sed 's,/[^/]*,../,g'`
16871 ac_dir_suffix= ac_dots=
16876 if test -z "$ac_dots"; then
16879 ac_top_srcdir=`echo $ac_dots | sed 's,/$,,'`
16881 [\\/]* | ?:[\\/]* )
16882 ac_srcdir=$srcdir$ac_dir_suffix;
16883 ac_top_srcdir=$srcdir ;;
16884 *) # Relative path.
16885 ac_srcdir=$ac_dots$srcdir$ac_dir_suffix
16886 ac_top_srcdir=$ac_dots$srcdir ;;
16890 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
16891 *) ac_INSTALL=$ac_dots$INSTALL ;;
16894 if test x"$ac_file" != x-; then
16895 { echo "$as_me:16895: creating $ac_file" >&5
16896 echo "$as_me: creating $ac_file" >&6;}
16899 # Let's still pretend it is `configure' which instantiates (i.e., don't
16900 # use $as_me), people would be surprised to read:
16901 # /* config.h. Generated automatically by config.status. */
16902 configure_input="Generated automatically from `echo $ac_file_in |
16903 sed 's,.*/,,'` by configure."
16905 # First look for the input files in the build tree, otherwise in the
16907 ac_file_inputs=`IFS=:
16908 for f in $ac_file_in; do
16910 -) echo $tmp/stdin ;;
16912 # Absolute (can't be DOS-style, as IFS=:)
16913 test -f "$f" || { { echo "$as_me:16913: error: cannot find input file: $f" >&5
16914 echo "$as_me: error: cannot find input file: $f" >&2;}
16915 { (exit 1); exit 1; }; }
16918 if test -f "$f"; then
16921 elif test -f "$srcdir/$f"; then
16926 { { echo "$as_me:16926: error: cannot find input file: $f" >&5
16927 echo "$as_me: error: cannot find input file: $f" >&2;}
16928 { (exit 1); exit 1; }; }
16931 done` || { (exit 1); exit 1; }
16933 cat >>$CONFIG_STATUS <<EOF
16937 cat >>$CONFIG_STATUS <<\EOF
16939 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
16940 s,@configure_input@,$configure_input,;t t
16941 s,@srcdir@,$ac_srcdir,;t t
16942 s,@top_srcdir@,$ac_top_srcdir,;t t
16943 s,@INSTALL@,$ac_INSTALL,;t t
16944 " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
16946 if test x"$ac_file" != x-; then
16947 mv $tmp/out $ac_file
16955 cat >>$CONFIG_STATUS <<\EOF
16958 # CONFIG_HEADER section.
16961 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
16962 # NAME is the cpp macro being defined and VALUE is the value it is being given.
16964 # ac_d sets the value in "#define NAME VALUE" lines.
16965 ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
16966 ac_dB='[ ].*$,\1#\2'
16969 # ac_i turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
16970 ac_iA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
16971 ac_iB='\([ ]\),\1#\2define\3'
16974 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
16975 ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
16976 ac_uB='$,\1#\2define\3'
16980 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
16981 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
16983 - | *:- | *:-:* ) # input from stdin
16985 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
16986 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
16987 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
16988 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
16989 * ) ac_file_in=$ac_file.in ;;
16992 test x"$ac_file" != x- && { echo "$as_me:16992: creating $ac_file" >&5
16993 echo "$as_me: creating $ac_file" >&6;}
16995 # First look for the input files in the build tree, otherwise in the
16997 ac_file_inputs=`IFS=:
16998 for f in $ac_file_in; do
17000 -) echo $tmp/stdin ;;
17002 # Absolute (can't be DOS-style, as IFS=:)
17003 test -f "$f" || { { echo "$as_me:17003: error: cannot find input file: $f" >&5
17004 echo "$as_me: error: cannot find input file: $f" >&2;}
17005 { (exit 1); exit 1; }; }
17008 if test -f "$f"; then
17011 elif test -f "$srcdir/$f"; then
17016 { { echo "$as_me:17016: error: cannot find input file: $f" >&5
17017 echo "$as_me: error: cannot find input file: $f" >&2;}
17018 { (exit 1); exit 1; }; }
17021 done` || { (exit 1); exit 1; }
17022 # Remove the trailing spaces.
17023 sed 's/[ ]*$//' $ac_file_inputs >$tmp/in
17027 # Transform confdefs.h into a list of #define's. We won't use it as a sed
17028 # script, but as data to insert where we see @DEFS@. We expect AC_SAVE_DEFS to
17029 # be either 'cat' or 'sort'.
17030 cat confdefs.h | uniq >conftest.vals
17032 # Break up conftest.vals because some shells have a limit on
17033 # the size of here documents, and old seds have small limits too.
17035 rm -f conftest.tail
17036 echo ' rm -f conftest.frag' >> $CONFIG_STATUS
17037 while grep . conftest.vals >/dev/null
17039 # Write chunks of a limited-size here document to conftest.frag.
17040 echo ' cat >> conftest.frag <<CEOF' >> $CONFIG_STATUS
17041 sed ${ac_max_here_lines}q conftest.vals | sed -e 's/#ifdef.*/#if 0/' >> $CONFIG_STATUS
17042 echo 'CEOF' >> $CONFIG_STATUS
17043 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
17044 rm -f conftest.vals
17045 mv conftest.tail conftest.vals
17047 rm -f conftest.vals
17049 # Run sed to substitute the contents of conftest.frag into $tmp/in at the
17051 echo ' cat >> conftest.edit <<CEOF
17052 /@DEFS@/r conftest.frag
17055 sed -f conftest.edit $tmp/in > $tmp/out
17057 mv $tmp/out $tmp/in
17058 rm -f conftest.edit conftest.frag
17059 ' >> $CONFIG_STATUS
17061 cat >>$CONFIG_STATUS <<\EOF
17062 # Let's still pretend it is `configure' which instantiates (i.e., don't
17063 # use $as_me), people would be surprised to read:
17064 # /* config.h. Generated automatically by config.status. */
17065 if test x"$ac_file" = x-; then
17066 echo "/* Generated automatically by configure. */" >$tmp/config.h
17068 echo "/* $ac_file. Generated automatically by configure. */" >$tmp/config.h
17070 cat $tmp/in >>$tmp/config.h
17072 if test x"$ac_file" != x-; then
17073 if cmp -s $ac_file $tmp/config.h 2>/dev/null; then
17074 { echo "$as_me:17074: $ac_file is unchanged" >&5
17075 echo "$as_me: $ac_file is unchanged" >&6;}
17077 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
17078 X"$ac_file" : 'X\(//\)[^/]' \| \
17079 X"$ac_file" : 'X\(//\)$' \| \
17080 X"$ac_file" : 'X\(/\)' \| \
17081 . : '\(.\)' 2>/dev/null ||
17083 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
17084 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
17085 /^X\(\/\/\)$/{ s//\1/; q; }
17086 /^X\(\/\).*/{ s//\1/; q; }
17088 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
17089 { case "$ac_dir" in
17090 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
17094 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
17095 case $as_mkdir_dir in
17096 # Skip DOS drivespec
17097 ?:) as_incr_dir=$as_mkdir_dir ;;
17099 as_incr_dir=$as_incr_dir/$as_mkdir_dir
17100 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
17107 mv $tmp/config.h $ac_file
17111 rm -f $tmp/config.h
17115 cat >>$CONFIG_STATUS <<\EOF
17117 # CONFIG_COMMANDS section.
17119 for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
17120 ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
17121 ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
17128 if test ! -d $srcdir/$cf_dir; then
17130 elif test -f $srcdir/$cf_dir/programs; then
17131 $AWK -f $srcdir/mk-test.awk INSTALL=yes ECHO_LINK="$ECHO_LD" $srcdir/$cf_dir/programs >>$cf_dir/Makefile
17135 cat >>Makefile <<TEST_EOF
17137 # These rules are generated so we do not rely on suffix rules, which do not
17138 # work consistently for different make-programs (the '\$(MODEL)/' confuses
17139 # some, and the '\$x' confuses others).
17142 LIST=`sed -e 's/[ ].*//' -e '/^[#@]/d' $srcdir/modules`
17145 cat >>Makefile <<TEST_EOF
17147 \$(MODEL)/$N.o : \$(srcdir)/$N.c \\
17148 \$(srcdir)/test.priv.h \\
17150 @echo compiling $N; \$(CC) -c \$(CFLAGS_DEFAULT) \$(srcdir)/$N.c
17154 if test -f ../config.guess && test -f ../config.sub
17156 cat >>Makefile <<TEST_EOF
17158 # if we used CF_INHERIT for getting these files, we can remove them
17160 rm -f config.guess config.sub
17168 cat >>$CONFIG_STATUS <<\EOF
17170 { (exit 0); exit 0; }
17172 chmod +x $CONFIG_STATUS
17173 ac_clean_files=$ac_clean_files_save
17175 # configure is writing to config.log, and then calls config.status.
17176 # config.status does its own redirection, appending to config.log.
17177 # Unfortunately, on DOS this fails, as config.log is still kept open
17178 # by configure, so config.status won't be able to write to it; its
17179 # output is simply discarded. So we exec the FD to /dev/null,
17180 # effectively closing config.log, so it can be properly (re)opened and
17181 # appended to by config.status. When coming back to configure, we
17182 # need to make the FD available again.
17183 if test "$no_create" != yes; then
17186 $SHELL $CONFIG_STATUS || ac_cs_success=false
17188 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
17189 # would make configure fail if this is the last instruction.
17190 $ac_cs_success || { (exit 1); exit 1; }