2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by Autoconf 2.52.20101002.
5 # Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
6 # Free Software Foundation, Inc.
7 # This configure script is free software; the Free Software Foundation
8 # gives unlimited permission to copy, distribute and modify it.
10 # Avoid depending upon Character Ranges.
11 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
12 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
13 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
14 as_cr_digits='0123456789'
15 as_cr_alnum=$as_cr_Letters$as_cr_digits
17 # Sed expression to map a string onto a valid variable name.
18 as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
20 # Sed expression to map a string onto a valid CPP name.
21 as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
23 # Be Bourne compatible
24 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
27 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
31 # Name of the executable.
32 as_me=`echo "$0" |sed 's,.*[\\/],,'`
34 if expr a : '\(a\)' >/dev/null 2>&1; then
40 rm -f conf$$ conf$$.exe conf$$.file
42 if ln -s conf$$.file conf$$ 2>/dev/null; then
43 # We could just check for DJGPP; but this test a) works b) is more generic
44 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
45 if test -f conf$$.exe; then
46 # Don't use ln at all; we don't have any links
51 elif ln conf$$.file conf$$ 2>/dev/null; then
56 rm -f conf$$ conf$$.exe conf$$.file
58 as_executable_p="test -f"
60 # Support unset when possible.
61 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
68 $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
69 $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
70 $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
71 $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
72 $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
73 $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
74 $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
75 $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
78 # We need space, tab and new line, in precisely that order.
84 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
87 # hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
88 # so uname gets run too.
89 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
96 ac_default_prefix=/usr/local
100 SHELL=${CONFIG_SHELL-/bin/sh}
102 # Maximum number of lines to put in a shell here document.
103 # This variable seems obsolete. It should probably be removed, and
104 # only ac_max_sed_lines should be used.
105 : ${ac_max_here_lines=38}
107 ac_unique_file="ncurses.c"
109 # Initialize some variables set by options.
111 ac_init_version=false
112 # The variables have the same names as the options, with
113 # dashes changed to underlines.
121 program_transform_name=s,x,x,
129 # Installation directory options.
130 # These are left unexpanded so users can "make install exec_prefix=/foo"
131 # and all the variables that are supposed to be based on exec_prefix
132 # by default will actually change.
133 # Use braces instead of parens because sh, perl, etc. also accept them.
134 bindir='${exec_prefix}/bin'
135 sbindir='${exec_prefix}/sbin'
136 libexecdir='${exec_prefix}/libexec'
137 datadir='${prefix}/share'
138 sysconfdir='${prefix}/etc'
139 sharedstatedir='${prefix}/com'
140 localstatedir='${prefix}/var'
141 libdir='${exec_prefix}/lib'
142 includedir='${prefix}/include'
143 oldincludedir='/usr/include'
144 infodir='${prefix}/info'
145 mandir='${prefix}/man'
147 # Identity of this package.
157 # If the previous option needs an argument, assign it.
158 if test -n "$ac_prev"; then
159 eval "$ac_prev=\$ac_option"
164 ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
166 # Accept the important Cygnus configure options, so we can diagnose typos.
170 -bindir | --bindir | --bindi | --bind | --bin | --bi)
172 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
175 -build | --build | --buil | --bui | --bu)
176 ac_prev=build_alias ;;
177 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
178 build_alias=$ac_optarg ;;
180 -cache-file | --cache-file | --cache-fil | --cache-fi \
181 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
182 ac_prev=cache_file ;;
183 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
184 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
185 cache_file=$ac_optarg ;;
188 cache_file=config.cache ;;
190 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
192 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
194 datadir=$ac_optarg ;;
196 -disable-* | --disable-*)
197 ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
198 # Reject names that are not valid shell variable names.
199 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
200 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
201 { (exit 1); exit 1; }; }
202 ac_feature=`echo $ac_feature | sed 's/-/_/g'`
203 eval "enable_$ac_feature=no" ;;
205 -enable-* | --enable-*)
206 ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
207 # Reject names that are not valid shell variable names.
208 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
209 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
210 { (exit 1); exit 1; }; }
211 ac_feature=`echo $ac_feature | sed 's/-/_/g'`
213 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
216 eval "enable_$ac_feature='$ac_optarg'" ;;
218 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
219 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
220 | --exec | --exe | --ex)
221 ac_prev=exec_prefix ;;
222 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
223 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
224 | --exec=* | --exe=* | --ex=*)
225 exec_prefix=$ac_optarg ;;
227 -gas | --gas | --ga | --g)
228 # Obsolete; use --with-gas.
231 -help | --help | --hel | --he | -h)
233 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
234 ac_init_help=recursive ;;
235 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
236 ac_init_help=short ;;
238 -host | --host | --hos | --ho)
239 ac_prev=host_alias ;;
240 -host=* | --host=* | --hos=* | --ho=*)
241 host_alias=$ac_optarg ;;
243 -includedir | --includedir | --includedi | --included | --include \
244 | --includ | --inclu | --incl | --inc)
245 ac_prev=includedir ;;
246 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
247 | --includ=* | --inclu=* | --incl=* | --inc=*)
248 includedir=$ac_optarg ;;
250 -infodir | --infodir | --infodi | --infod | --info | --inf)
252 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
253 infodir=$ac_optarg ;;
255 -libdir | --libdir | --libdi | --libd)
257 -libdir=* | --libdir=* | --libdi=* | --libd=*)
260 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
261 | --libexe | --libex | --libe)
262 ac_prev=libexecdir ;;
263 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
264 | --libexe=* | --libex=* | --libe=*)
265 libexecdir=$ac_optarg ;;
267 -localstatedir | --localstatedir | --localstatedi | --localstated \
268 | --localstate | --localstat | --localsta | --localst \
269 | --locals | --local | --loca | --loc | --lo)
270 ac_prev=localstatedir ;;
271 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
272 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
273 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
274 localstatedir=$ac_optarg ;;
276 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
278 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
282 # Obsolete; use --without-fp.
285 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
289 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
290 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
293 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
294 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
295 | --oldin | --oldi | --old | --ol | --o)
296 ac_prev=oldincludedir ;;
297 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
298 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
299 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
300 oldincludedir=$ac_optarg ;;
302 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
304 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
307 -program-prefix | --program-prefix | --program-prefi | --program-pref \
308 | --program-pre | --program-pr | --program-p)
309 ac_prev=program_prefix ;;
310 -program-prefix=* | --program-prefix=* | --program-prefi=* \
311 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
312 program_prefix=$ac_optarg ;;
314 -program-suffix | --program-suffix | --program-suffi | --program-suff \
315 | --program-suf | --program-su | --program-s)
316 ac_prev=program_suffix ;;
317 -program-suffix=* | --program-suffix=* | --program-suffi=* \
318 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
319 program_suffix=$ac_optarg ;;
321 -program-transform-name | --program-transform-name \
322 | --program-transform-nam | --program-transform-na \
323 | --program-transform-n | --program-transform- \
324 | --program-transform | --program-transfor \
325 | --program-transfo | --program-transf \
326 | --program-trans | --program-tran \
327 | --progr-tra | --program-tr | --program-t)
328 ac_prev=program_transform_name ;;
329 -program-transform-name=* | --program-transform-name=* \
330 | --program-transform-nam=* | --program-transform-na=* \
331 | --program-transform-n=* | --program-transform-=* \
332 | --program-transform=* | --program-transfor=* \
333 | --program-transfo=* | --program-transf=* \
334 | --program-trans=* | --program-tran=* \
335 | --progr-tra=* | --program-tr=* | --program-t=*)
336 program_transform_name=$ac_optarg ;;
338 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
339 | -silent | --silent | --silen | --sile | --sil)
342 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
344 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
346 sbindir=$ac_optarg ;;
348 -sharedstatedir | --sharedstatedir | --sharedstatedi \
349 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
350 | --sharedst | --shareds | --shared | --share | --shar \
352 ac_prev=sharedstatedir ;;
353 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
354 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
355 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
357 sharedstatedir=$ac_optarg ;;
359 -site | --site | --sit)
361 -site=* | --site=* | --sit=*)
364 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
366 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
369 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
370 | --syscon | --sysco | --sysc | --sys | --sy)
371 ac_prev=sysconfdir ;;
372 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
373 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
374 sysconfdir=$ac_optarg ;;
376 -target | --target | --targe | --targ | --tar | --ta | --t)
377 ac_prev=target_alias ;;
378 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
379 target_alias=$ac_optarg ;;
381 -v | -verbose | --verbose | --verbos | --verbo | --verb)
384 -version | --version | --versio | --versi | --vers | -V)
388 ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
389 # Reject names that are not valid shell variable names.
390 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
391 { echo "$as_me: error: invalid package name: $ac_package" >&2
392 { (exit 1); exit 1; }; }
393 ac_package=`echo $ac_package| sed 's/-/_/g'`
395 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
398 eval "with_$ac_package='$ac_optarg'" ;;
400 -without-* | --without-*)
401 ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
402 # Reject names that are not valid shell variable names.
403 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
404 { echo "$as_me: error: invalid package name: $ac_package" >&2
405 { (exit 1); exit 1; }; }
406 ac_package=`echo $ac_package | sed 's/-/_/g'`
407 eval "with_$ac_package=no" ;;
410 # Obsolete; use --with-x.
413 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
414 | --x-incl | --x-inc | --x-in | --x-i)
415 ac_prev=x_includes ;;
416 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
417 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
418 x_includes=$ac_optarg ;;
420 -x-libraries | --x-libraries | --x-librarie | --x-librari \
421 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
422 ac_prev=x_libraries ;;
423 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
424 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
425 x_libraries=$ac_optarg ;;
427 -*) { echo "$as_me: error: unrecognized option: $ac_option
428 Try \`$0 --help' for more information." >&2
429 { (exit 1); exit 1; }; }
433 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
434 # Reject names that are not valid shell variable names.
435 expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
436 { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
437 { (exit 1); exit 1; }; }
438 ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
439 eval "$ac_envvar='$ac_optarg'"
443 # FIXME: should be removed in autoconf 3.0.
444 echo "$as_me: WARNING: you should use --build, --host, --target" >&2
445 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
446 echo "$as_me: WARNING: invalid host type: $ac_option" >&2
447 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
453 if test -n "$ac_prev"; then
454 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
455 { echo "$as_me: error: missing argument to $ac_option" >&2
456 { (exit 1); exit 1; }; }
459 # Be sure to have absolute paths.
460 for ac_var in exec_prefix prefix
462 eval ac_val=$`echo $ac_var`
464 [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
465 *) { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
466 { (exit 1); exit 1; }; };;
470 # Be sure to have absolute paths.
471 for ac_var in bindir sbindir libexecdir datadir sysconfdir sharedstatedir \
472 localstatedir libdir includedir oldincludedir infodir mandir
474 eval ac_val=$`echo $ac_var`
476 [\\/$]* | ?:[\\/]* ) ;;
477 *) { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
478 { (exit 1); exit 1; }; };;
482 # There might be people who depend on the old broken behavior: `$host'
483 # used to hold the argument of --host etc.
488 # FIXME: should be removed in autoconf 3.0.
489 if test "x$host_alias" != x; then
490 if test "x$build_alias" = x; then
491 cross_compiling=maybe
492 echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
493 If a cross compiler is detected then cross compile mode will be used." >&2
494 elif test "x$build_alias" != "x$host_alias"; then
500 test -n "$host_alias" && ac_tool_prefix=$host_alias-
502 test "$silent" = yes && exec 6>/dev/null
504 # Find the source files, if location was not specified.
505 if test -z "$srcdir"; then
506 ac_srcdir_defaulted=yes
507 # Try the directory containing this script, then its parent.
509 ac_confdir=`echo "$ac_prog" | sed 's%[\\/][^\\/][^\\/]*$%%'`
510 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
512 if test ! -r $srcdir/$ac_unique_file; then
516 ac_srcdir_defaulted=no
518 if test ! -r $srcdir/$ac_unique_file; then
519 if test "$ac_srcdir_defaulted" = yes; then
520 { echo "$as_me: error: cannot find sources in $ac_confdir or .." >&2
521 { (exit 1); exit 1; }; }
523 { echo "$as_me: error: cannot find sources in $srcdir" >&2
524 { (exit 1); exit 1; }; }
527 srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
528 ac_env_build_alias_set=${build_alias+set}
529 ac_env_build_alias_value=$build_alias
530 ac_cv_env_build_alias_set=${build_alias+set}
531 ac_cv_env_build_alias_value=$build_alias
532 ac_env_host_alias_set=${host_alias+set}
533 ac_env_host_alias_value=$host_alias
534 ac_cv_env_host_alias_set=${host_alias+set}
535 ac_cv_env_host_alias_value=$host_alias
536 ac_env_target_alias_set=${target_alias+set}
537 ac_env_target_alias_value=$target_alias
538 ac_cv_env_target_alias_set=${target_alias+set}
539 ac_cv_env_target_alias_value=$target_alias
540 ac_env_CC_set=${CC+set}
542 ac_cv_env_CC_set=${CC+set}
543 ac_cv_env_CC_value=$CC
544 ac_env_CFLAGS_set=${CFLAGS+set}
545 ac_env_CFLAGS_value=$CFLAGS
546 ac_cv_env_CFLAGS_set=${CFLAGS+set}
547 ac_cv_env_CFLAGS_value=$CFLAGS
548 ac_env_LDFLAGS_set=${LDFLAGS+set}
549 ac_env_LDFLAGS_value=$LDFLAGS
550 ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
551 ac_cv_env_LDFLAGS_value=$LDFLAGS
552 ac_env_CPPFLAGS_set=${CPPFLAGS+set}
553 ac_env_CPPFLAGS_value=$CPPFLAGS
554 ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
555 ac_cv_env_CPPFLAGS_value=$CPPFLAGS
556 ac_env_CPP_set=${CPP+set}
557 ac_env_CPP_value=$CPP
558 ac_cv_env_CPP_set=${CPP+set}
559 ac_cv_env_CPP_value=$CPP
562 # Report the --help message.
564 if test "$ac_init_help" = "long"; then
565 # Omit some internal or obsolete options to make the list less imposing.
566 # This message is too long to be a string in the A/UX 3.1 sh.
568 \`configure' configures this package to adapt to many kinds of systems.
570 Usage: $0 [OPTION]... [VAR=VALUE]...
572 To assign environment variables (e.g., CC, CFLAGS...), specify them as
573 VAR=VALUE. See below for descriptions of some of the useful variables.
575 Defaults for the options are specified in brackets.
578 -h, --help display this help and exit
579 --help=short display options specific to this package
580 --help=recursive display the short help of all the included packages
581 -V, --version display version information and exit
582 -q, --quiet, --silent do not print \`checking...' messages
583 --cache-file=FILE cache test results in FILE [disabled]
584 -C, --config-cache alias for \`--cache-file=config.cache'
585 -n, --no-create do not create output files
586 --srcdir=DIR find the sources in DIR [configure dir or \`..']
591 Installation directories:
592 --prefix=PREFIX install architecture-independent files in PREFIX
594 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
597 By default, \`make install' will install all the files in
598 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
599 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
600 for instance \`--prefix=\$HOME'.
602 For better control, use the options below.
604 Fine tuning of the installation directories:
605 --bindir=DIR user executables [EPREFIX/bin]
606 --sbindir=DIR system admin executables [EPREFIX/sbin]
607 --libexecdir=DIR program executables [EPREFIX/libexec]
608 --datadir=DIR read-only architecture-independent data [PREFIX/share]
609 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
610 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
611 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
612 --libdir=DIR object code libraries [EPREFIX/lib]
613 --includedir=DIR C header files [PREFIX/include]
614 --oldincludedir=DIR C header files for non-gcc [/usr/include]
615 --infodir=DIR info documentation [PREFIX/info]
616 --mandir=DIR man documentation [PREFIX/man]
622 --program-prefix=PREFIX prepend PREFIX to installed program names
623 --program-suffix=SUFFIX append SUFFIX to installed program names
624 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
627 --x-includes=DIR X include files are in DIR
628 --x-libraries=DIR X library files are in DIR
631 --build=BUILD configure for building on BUILD [guessed]
632 --host=HOST build programs to run on HOST [BUILD]
636 if test -n "$ac_init_help"; then
641 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
642 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
645 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
646 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
648 --disable-echo display "compiling" commands
649 --enable-warnings test: turn on gcc compiler warnings
650 --with-dmalloc test: use Gray Watson's dmalloc library
651 --with-dbmalloc test: use Conor Cahill's dbmalloc library
652 --with-valgrind test: use valgrind
653 --disable-leaks test: free permanent memory, analyze leaks
654 --disable-widec disable checks for wide-character functions
655 --with-curses-dir=DIR directory in which (n)curses is installed
656 --with-ncursesw use wide ncurses-libraries (installed)
657 --with-ncurses use ncurses-libraries (installed)
658 --with-pdcurses compile/link with pdcurses X11 library
659 --with-curses-colr compile/link with HPUX 10.x color-curses
660 --with-curses-5lib compile/link with SunOS 5lib curses
661 --with-Xaw3d link with Xaw 3d library
662 --with-neXtaw link with neXT Athena library
663 --with-XawPlus link with Athena-Plus library
664 --with-pkg-config{=path} enable/disable use of pkg-config
665 --with-x use the X Window System
666 --with-ncurses-wrap-prefix naming-prefix for ncurses wrapped-variables
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"
2927 freebsd*|dragonfly*) #(vi
2928 # 5.x headers associate
2929 # _XOPEN_SOURCE=600 with _POSIX_C_SOURCE=200112L
2930 # _XOPEN_SOURCE=500 with _POSIX_C_SOURCE=199506L
2931 cf_POSIX_C_SOURCE=200112L
2933 cf_xopen_source="-D_BSD_TYPES -D__BSD_VISIBLE -D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
2936 cf_xopen_source="-D_HPUX_SOURCE -D_XOPEN_SOURCE=500"
2939 cf_xopen_source="-D_HPUX_SOURCE"
2942 cf_xopen_source="-D_SGI_SOURCE"
2944 linux*|gnu*|mint*|k*bsd*-gnu) #(vi
2946 echo "$as_me:2946: checking if we must define _GNU_SOURCE" >&5
2947 echo $ECHO_N "checking if we must define _GNU_SOURCE... $ECHO_C" >&6
2948 if test "${cf_cv_gnu_source+set}" = set; then
2949 echo $ECHO_N "(cached) $ECHO_C" >&6
2952 cat >conftest.$ac_ext <<_ACEOF
2953 #line 2953 "configure"
2954 #include "confdefs.h"
2955 #include <sys/types.h>
2960 #ifndef _XOPEN_SOURCE
2967 rm -f conftest.$ac_objext
2968 if { (eval echo "$as_me:2968: \"$ac_compile\"") >&5
2969 (eval $ac_compile) 2>&5
2971 echo "$as_me:2971: \$? = $ac_status" >&5
2972 (exit $ac_status); } &&
2973 { ac_try='test -s conftest.$ac_objext'
2974 { (eval echo "$as_me:2974: \"$ac_try\"") >&5
2977 echo "$as_me:2977: \$? = $ac_status" >&5
2978 (exit $ac_status); }; }; then
2981 echo "$as_me: failed program was:" >&5
2982 cat conftest.$ac_ext >&5
2984 CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE"
2985 cat >conftest.$ac_ext <<_ACEOF
2986 #line 2986 "configure"
2987 #include "confdefs.h"
2988 #include <sys/types.h>
2993 #ifdef _XOPEN_SOURCE
3000 rm -f conftest.$ac_objext
3001 if { (eval echo "$as_me:3001: \"$ac_compile\"") >&5
3002 (eval $ac_compile) 2>&5
3004 echo "$as_me:3004: \$? = $ac_status" >&5
3005 (exit $ac_status); } &&
3006 { ac_try='test -s conftest.$ac_objext'
3007 { (eval echo "$as_me:3007: \"$ac_try\"") >&5
3010 echo "$as_me:3010: \$? = $ac_status" >&5
3011 (exit $ac_status); }; }; then
3014 echo "$as_me: failed program was:" >&5
3015 cat conftest.$ac_ext >&5
3016 cf_cv_gnu_source=yes
3018 rm -f conftest.$ac_objext conftest.$ac_ext
3022 rm -f conftest.$ac_objext conftest.$ac_ext
3025 echo "$as_me:3025: result: $cf_cv_gnu_source" >&5
3026 echo "${ECHO_T}$cf_cv_gnu_source" >&6
3027 test "$cf_cv_gnu_source" = yes && CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE"
3031 # setting _XOPEN_SOURCE or _POSIX_SOURCE breaks <sys/select.h> and other headers which use u_int / u_short types
3034 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
3036 cf_save_CFLAGS="$CFLAGS"
3037 cf_save_CPPFLAGS="$CPPFLAGS"
3039 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
3040 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3041 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
3043 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
3044 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3045 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
3047 echo "$as_me:3047: checking if we should define _POSIX_C_SOURCE" >&5
3048 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
3049 if test "${cf_cv_posix_c_source+set}" = set; then
3050 echo $ECHO_N "(cached) $ECHO_C" >&6
3053 echo "${as_me:-configure}:3053: testing if the symbol is already defined go no further ..." 1>&5
3055 cat >conftest.$ac_ext <<_ACEOF
3056 #line 3056 "configure"
3057 #include "confdefs.h"
3058 #include <sys/types.h>
3063 #ifndef _POSIX_C_SOURCE
3070 rm -f conftest.$ac_objext
3071 if { (eval echo "$as_me:3071: \"$ac_compile\"") >&5
3072 (eval $ac_compile) 2>&5
3074 echo "$as_me:3074: \$? = $ac_status" >&5
3075 (exit $ac_status); } &&
3076 { ac_try='test -s conftest.$ac_objext'
3077 { (eval echo "$as_me:3077: \"$ac_try\"") >&5
3080 echo "$as_me:3080: \$? = $ac_status" >&5
3081 (exit $ac_status); }; }; then
3082 cf_cv_posix_c_source=no
3084 echo "$as_me: failed program was:" >&5
3085 cat conftest.$ac_ext >&5
3086 cf_want_posix_source=no
3087 case .$cf_POSIX_C_SOURCE in #(vi
3089 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
3092 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
3093 cf_want_posix_source=yes
3096 cf_want_posix_source=yes
3099 if test "$cf_want_posix_source" = yes ; then
3100 cat >conftest.$ac_ext <<_ACEOF
3101 #line 3101 "configure"
3102 #include "confdefs.h"
3103 #include <sys/types.h>
3108 #ifdef _POSIX_SOURCE
3115 rm -f conftest.$ac_objext
3116 if { (eval echo "$as_me:3116: \"$ac_compile\"") >&5
3117 (eval $ac_compile) 2>&5
3119 echo "$as_me:3119: \$? = $ac_status" >&5
3120 (exit $ac_status); } &&
3121 { ac_try='test -s conftest.$ac_objext'
3122 { (eval echo "$as_me:3122: \"$ac_try\"") >&5
3125 echo "$as_me:3125: \$? = $ac_status" >&5
3126 (exit $ac_status); }; }; then
3129 echo "$as_me: failed program was:" >&5
3130 cat conftest.$ac_ext >&5
3131 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
3133 rm -f conftest.$ac_objext conftest.$ac_ext
3136 echo "${as_me:-configure}:3136: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
3138 CFLAGS="$cf_trim_CFLAGS"
3139 CPPFLAGS="$cf_trim_CPPFLAGS $cf_cv_posix_c_source"
3141 echo "${as_me:-configure}:3141: testing if the second compile does not leave our definition intact error ..." 1>&5
3143 cat >conftest.$ac_ext <<_ACEOF
3144 #line 3144 "configure"
3145 #include "confdefs.h"
3146 #include <sys/types.h>
3151 #ifndef _POSIX_C_SOURCE
3158 rm -f conftest.$ac_objext
3159 if { (eval echo "$as_me:3159: \"$ac_compile\"") >&5
3160 (eval $ac_compile) 2>&5
3162 echo "$as_me:3162: \$? = $ac_status" >&5
3163 (exit $ac_status); } &&
3164 { ac_try='test -s conftest.$ac_objext'
3165 { (eval echo "$as_me:3165: \"$ac_try\"") >&5
3168 echo "$as_me:3168: \$? = $ac_status" >&5
3169 (exit $ac_status); }; }; then
3172 echo "$as_me: failed program was:" >&5
3173 cat conftest.$ac_ext >&5
3174 cf_cv_posix_c_source=no
3176 rm -f conftest.$ac_objext conftest.$ac_ext
3177 CFLAGS="$cf_save_CFLAGS"
3178 CPPFLAGS="$cf_save_CPPFLAGS"
3181 rm -f conftest.$ac_objext conftest.$ac_ext
3184 echo "$as_me:3184: result: $cf_cv_posix_c_source" >&5
3185 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
3187 if test "$cf_cv_posix_c_source" != no ; then
3188 CFLAGS="$cf_trim_CFLAGS"
3189 CPPFLAGS="$cf_trim_CPPFLAGS"
3194 cf_new_extra_cppflags=
3196 for cf_add_cflags in $cf_cv_posix_c_source
3198 case $cf_fix_cppflags in
3200 case $cf_add_cflags in #(vi
3201 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
3202 case $cf_add_cflags in
3204 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3206 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3207 && test -z "${cf_tst_cflags}" \
3208 && cf_fix_cppflags=yes
3210 if test $cf_fix_cppflags = yes ; then
3211 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3213 elif test "${cf_tst_cflags}" = "\"'" ; then
3214 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3220 *$cf_add_cflags) #(vi
3223 case $cf_add_cflags in #(vi
3225 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3227 CPPFLAGS=`echo "$CPPFLAGS" | \
3228 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3229 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3233 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
3238 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
3243 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3245 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
3247 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3248 && test -z "${cf_tst_cflags}" \
3249 && cf_fix_cppflags=no
3254 if test -n "$cf_new_cflags" ; then
3256 CFLAGS="$CFLAGS $cf_new_cflags"
3259 if test -n "$cf_new_cppflags" ; then
3261 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
3264 if test -n "$cf_new_extra_cppflags" ; then
3266 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
3273 cf_xopen_source="-D_NETBSD_SOURCE" # setting _XOPEN_SOURCE breaks IPv6 for lynx on NetBSD 1.6, breaks xterm, is not needed for ncursesw
3276 # setting _XOPEN_SOURCE lower than 500 breaks g++ compile with wchar.h, needed for ncursesw
3280 # setting _XOPEN_SOURCE breaks xterm on OpenBSD 2.8, is not needed for ncursesw
3283 cf_xopen_source="-D_OSF_SOURCE"
3286 cf_xopen_source="-D_QNX_SOURCE"
3289 # setting _XOPEN_SOURCE breaks Lynx on SCO Unix / OpenServer
3292 cf_xopen_source="-D__EXTENSIONS__"
3296 echo "$as_me:3296: checking if we should define _XOPEN_SOURCE" >&5
3297 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
3298 if test "${cf_cv_xopen_source+set}" = set; then
3299 echo $ECHO_N "(cached) $ECHO_C" >&6
3302 cat >conftest.$ac_ext <<_ACEOF
3303 #line 3303 "configure"
3304 #include "confdefs.h"
3308 #include <sys/types.h>
3314 #ifndef _XOPEN_SOURCE
3321 rm -f conftest.$ac_objext
3322 if { (eval echo "$as_me:3322: \"$ac_compile\"") >&5
3323 (eval $ac_compile) 2>&5
3325 echo "$as_me:3325: \$? = $ac_status" >&5
3326 (exit $ac_status); } &&
3327 { ac_try='test -s conftest.$ac_objext'
3328 { (eval echo "$as_me:3328: \"$ac_try\"") >&5
3331 echo "$as_me:3331: \$? = $ac_status" >&5
3332 (exit $ac_status); }; }; then
3333 cf_cv_xopen_source=no
3335 echo "$as_me: failed program was:" >&5
3336 cat conftest.$ac_ext >&5
3338 CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
3339 cat >conftest.$ac_ext <<_ACEOF
3340 #line 3340 "configure"
3341 #include "confdefs.h"
3345 #include <sys/types.h>
3351 #ifdef _XOPEN_SOURCE
3358 rm -f conftest.$ac_objext
3359 if { (eval echo "$as_me:3359: \"$ac_compile\"") >&5
3360 (eval $ac_compile) 2>&5
3362 echo "$as_me:3362: \$? = $ac_status" >&5
3363 (exit $ac_status); } &&
3364 { ac_try='test -s conftest.$ac_objext'
3365 { (eval echo "$as_me:3365: \"$ac_try\"") >&5
3368 echo "$as_me:3368: \$? = $ac_status" >&5
3369 (exit $ac_status); }; }; then
3370 cf_cv_xopen_source=no
3372 echo "$as_me: failed program was:" >&5
3373 cat conftest.$ac_ext >&5
3374 cf_cv_xopen_source=$cf_XOPEN_SOURCE
3376 rm -f conftest.$ac_objext conftest.$ac_ext
3380 rm -f conftest.$ac_objext conftest.$ac_ext
3383 echo "$as_me:3383: result: $cf_cv_xopen_source" >&5
3384 echo "${ECHO_T}$cf_cv_xopen_source" >&6
3386 if test "$cf_cv_xopen_source" != no ; then
3388 CFLAGS=`echo "$CFLAGS" | \
3389 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3390 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
3392 CPPFLAGS=`echo "$CPPFLAGS" | \
3393 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3394 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
3396 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
3401 cf_new_extra_cppflags=
3403 for cf_add_cflags in $cf_temp_xopen_source
3405 case $cf_fix_cppflags in
3407 case $cf_add_cflags in #(vi
3408 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
3409 case $cf_add_cflags in
3411 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3413 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3414 && test -z "${cf_tst_cflags}" \
3415 && cf_fix_cppflags=yes
3417 if test $cf_fix_cppflags = yes ; then
3418 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3420 elif test "${cf_tst_cflags}" = "\"'" ; then
3421 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3427 *$cf_add_cflags) #(vi
3430 case $cf_add_cflags in #(vi
3432 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3434 CPPFLAGS=`echo "$CPPFLAGS" | \
3435 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3436 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3440 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
3445 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
3450 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3452 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
3454 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3455 && test -z "${cf_tst_cflags}" \
3456 && cf_fix_cppflags=no
3461 if test -n "$cf_new_cflags" ; then
3463 CFLAGS="$CFLAGS $cf_new_cflags"
3466 if test -n "$cf_new_cppflags" ; then
3468 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
3471 if test -n "$cf_new_extra_cppflags" ; then
3473 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
3478 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
3480 cf_save_CFLAGS="$CFLAGS"
3481 cf_save_CPPFLAGS="$CPPFLAGS"
3483 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
3484 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3485 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
3487 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
3488 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3489 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
3491 echo "$as_me:3491: checking if we should define _POSIX_C_SOURCE" >&5
3492 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
3493 if test "${cf_cv_posix_c_source+set}" = set; then
3494 echo $ECHO_N "(cached) $ECHO_C" >&6
3497 echo "${as_me:-configure}:3497: testing if the symbol is already defined go no further ..." 1>&5
3499 cat >conftest.$ac_ext <<_ACEOF
3500 #line 3500 "configure"
3501 #include "confdefs.h"
3502 #include <sys/types.h>
3507 #ifndef _POSIX_C_SOURCE
3514 rm -f conftest.$ac_objext
3515 if { (eval echo "$as_me:3515: \"$ac_compile\"") >&5
3516 (eval $ac_compile) 2>&5
3518 echo "$as_me:3518: \$? = $ac_status" >&5
3519 (exit $ac_status); } &&
3520 { ac_try='test -s conftest.$ac_objext'
3521 { (eval echo "$as_me:3521: \"$ac_try\"") >&5
3524 echo "$as_me:3524: \$? = $ac_status" >&5
3525 (exit $ac_status); }; }; then
3526 cf_cv_posix_c_source=no
3528 echo "$as_me: failed program was:" >&5
3529 cat conftest.$ac_ext >&5
3530 cf_want_posix_source=no
3531 case .$cf_POSIX_C_SOURCE in #(vi
3533 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
3536 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
3537 cf_want_posix_source=yes
3540 cf_want_posix_source=yes
3543 if test "$cf_want_posix_source" = yes ; then
3544 cat >conftest.$ac_ext <<_ACEOF
3545 #line 3545 "configure"
3546 #include "confdefs.h"
3547 #include <sys/types.h>
3552 #ifdef _POSIX_SOURCE
3559 rm -f conftest.$ac_objext
3560 if { (eval echo "$as_me:3560: \"$ac_compile\"") >&5
3561 (eval $ac_compile) 2>&5
3563 echo "$as_me:3563: \$? = $ac_status" >&5
3564 (exit $ac_status); } &&
3565 { ac_try='test -s conftest.$ac_objext'
3566 { (eval echo "$as_me:3566: \"$ac_try\"") >&5
3569 echo "$as_me:3569: \$? = $ac_status" >&5
3570 (exit $ac_status); }; }; then
3573 echo "$as_me: failed program was:" >&5
3574 cat conftest.$ac_ext >&5
3575 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
3577 rm -f conftest.$ac_objext conftest.$ac_ext
3580 echo "${as_me:-configure}:3580: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
3582 CFLAGS="$cf_trim_CFLAGS"
3583 CPPFLAGS="$cf_trim_CPPFLAGS $cf_cv_posix_c_source"
3585 echo "${as_me:-configure}:3585: testing if the second compile does not leave our definition intact error ..." 1>&5
3587 cat >conftest.$ac_ext <<_ACEOF
3588 #line 3588 "configure"
3589 #include "confdefs.h"
3590 #include <sys/types.h>
3595 #ifndef _POSIX_C_SOURCE
3602 rm -f conftest.$ac_objext
3603 if { (eval echo "$as_me:3603: \"$ac_compile\"") >&5
3604 (eval $ac_compile) 2>&5
3606 echo "$as_me:3606: \$? = $ac_status" >&5
3607 (exit $ac_status); } &&
3608 { ac_try='test -s conftest.$ac_objext'
3609 { (eval echo "$as_me:3609: \"$ac_try\"") >&5
3612 echo "$as_me:3612: \$? = $ac_status" >&5
3613 (exit $ac_status); }; }; then
3616 echo "$as_me: failed program was:" >&5
3617 cat conftest.$ac_ext >&5
3618 cf_cv_posix_c_source=no
3620 rm -f conftest.$ac_objext conftest.$ac_ext
3621 CFLAGS="$cf_save_CFLAGS"
3622 CPPFLAGS="$cf_save_CPPFLAGS"
3625 rm -f conftest.$ac_objext conftest.$ac_ext
3628 echo "$as_me:3628: result: $cf_cv_posix_c_source" >&5
3629 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
3631 if test "$cf_cv_posix_c_source" != no ; then
3632 CFLAGS="$cf_trim_CFLAGS"
3633 CPPFLAGS="$cf_trim_CPPFLAGS"
3638 cf_new_extra_cppflags=
3640 for cf_add_cflags in $cf_cv_posix_c_source
3642 case $cf_fix_cppflags in
3644 case $cf_add_cflags in #(vi
3645 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
3646 case $cf_add_cflags in
3648 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3650 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3651 && test -z "${cf_tst_cflags}" \
3652 && cf_fix_cppflags=yes
3654 if test $cf_fix_cppflags = yes ; then
3655 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3657 elif test "${cf_tst_cflags}" = "\"'" ; then
3658 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3664 *$cf_add_cflags) #(vi
3667 case $cf_add_cflags in #(vi
3669 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3671 CPPFLAGS=`echo "$CPPFLAGS" | \
3672 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3673 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3677 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
3682 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
3687 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3689 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
3691 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3692 && test -z "${cf_tst_cflags}" \
3693 && cf_fix_cppflags=no
3698 if test -n "$cf_new_cflags" ; then
3700 CFLAGS="$CFLAGS $cf_new_cflags"
3703 if test -n "$cf_new_cppflags" ; then
3705 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
3708 if test -n "$cf_new_extra_cppflags" ; then
3710 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
3718 if test -n "$cf_xopen_source" ; then
3723 cf_new_extra_cppflags=
3725 for cf_add_cflags in $cf_xopen_source
3727 case $cf_fix_cppflags in
3729 case $cf_add_cflags in #(vi
3730 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
3731 case $cf_add_cflags in
3733 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3735 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3736 && test -z "${cf_tst_cflags}" \
3737 && cf_fix_cppflags=yes
3739 if test $cf_fix_cppflags = yes ; then
3740 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3742 elif test "${cf_tst_cflags}" = "\"'" ; then
3743 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3749 *$cf_add_cflags) #(vi
3752 case $cf_add_cflags in #(vi
3754 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3756 CPPFLAGS=`echo "$CPPFLAGS" | \
3757 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3758 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3762 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
3767 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
3772 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
3774 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
3776 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
3777 && test -z "${cf_tst_cflags}" \
3778 && cf_fix_cppflags=no
3783 if test -n "$cf_new_cflags" ; then
3785 CFLAGS="$CFLAGS $cf_new_cflags"
3788 if test -n "$cf_new_cppflags" ; then
3790 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
3793 if test -n "$cf_new_extra_cppflags" ; then
3795 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
3800 if test -n "$cf_XOPEN_SOURCE" && test -z "$cf_cv_xopen_source" ; then
3801 echo "$as_me:3801: checking if _XOPEN_SOURCE really is set" >&5
3802 echo $ECHO_N "checking if _XOPEN_SOURCE really is set... $ECHO_C" >&6
3803 cat >conftest.$ac_ext <<_ACEOF
3804 #line 3804 "configure"
3805 #include "confdefs.h"
3811 #ifndef _XOPEN_SOURCE
3818 rm -f conftest.$ac_objext
3819 if { (eval echo "$as_me:3819: \"$ac_compile\"") >&5
3820 (eval $ac_compile) 2>&5
3822 echo "$as_me:3822: \$? = $ac_status" >&5
3823 (exit $ac_status); } &&
3824 { ac_try='test -s conftest.$ac_objext'
3825 { (eval echo "$as_me:3825: \"$ac_try\"") >&5
3828 echo "$as_me:3828: \$? = $ac_status" >&5
3829 (exit $ac_status); }; }; then
3830 cf_XOPEN_SOURCE_set=yes
3832 echo "$as_me: failed program was:" >&5
3833 cat conftest.$ac_ext >&5
3834 cf_XOPEN_SOURCE_set=no
3836 rm -f conftest.$ac_objext conftest.$ac_ext
3837 echo "$as_me:3837: result: $cf_XOPEN_SOURCE_set" >&5
3838 echo "${ECHO_T}$cf_XOPEN_SOURCE_set" >&6
3839 if test $cf_XOPEN_SOURCE_set = yes
3841 cat >conftest.$ac_ext <<_ACEOF
3842 #line 3842 "configure"
3843 #include "confdefs.h"
3849 #if (_XOPEN_SOURCE - 0) < $cf_XOPEN_SOURCE
3856 rm -f conftest.$ac_objext
3857 if { (eval echo "$as_me:3857: \"$ac_compile\"") >&5
3858 (eval $ac_compile) 2>&5
3860 echo "$as_me:3860: \$? = $ac_status" >&5
3861 (exit $ac_status); } &&
3862 { ac_try='test -s conftest.$ac_objext'
3863 { (eval echo "$as_me:3863: \"$ac_try\"") >&5
3866 echo "$as_me:3866: \$? = $ac_status" >&5
3867 (exit $ac_status); }; }; then
3868 cf_XOPEN_SOURCE_set_ok=yes
3870 echo "$as_me: failed program was:" >&5
3871 cat conftest.$ac_ext >&5
3872 cf_XOPEN_SOURCE_set_ok=no
3874 rm -f conftest.$ac_objext conftest.$ac_ext
3875 if test $cf_XOPEN_SOURCE_set_ok = no
3877 { echo "$as_me:3877: WARNING: _XOPEN_SOURCE is lower than requested" >&5
3878 echo "$as_me: WARNING: _XOPEN_SOURCE is lower than requested" >&2;}
3882 echo "$as_me:3882: checking if we should define _XOPEN_SOURCE" >&5
3883 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
3884 if test "${cf_cv_xopen_source+set}" = set; then
3885 echo $ECHO_N "(cached) $ECHO_C" >&6
3888 cat >conftest.$ac_ext <<_ACEOF
3889 #line 3889 "configure"
3890 #include "confdefs.h"
3894 #include <sys/types.h>
3900 #ifndef _XOPEN_SOURCE
3907 rm -f conftest.$ac_objext
3908 if { (eval echo "$as_me:3908: \"$ac_compile\"") >&5
3909 (eval $ac_compile) 2>&5
3911 echo "$as_me:3911: \$? = $ac_status" >&5
3912 (exit $ac_status); } &&
3913 { ac_try='test -s conftest.$ac_objext'
3914 { (eval echo "$as_me:3914: \"$ac_try\"") >&5
3917 echo "$as_me:3917: \$? = $ac_status" >&5
3918 (exit $ac_status); }; }; then
3919 cf_cv_xopen_source=no
3921 echo "$as_me: failed program was:" >&5
3922 cat conftest.$ac_ext >&5
3924 CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
3925 cat >conftest.$ac_ext <<_ACEOF
3926 #line 3926 "configure"
3927 #include "confdefs.h"
3931 #include <sys/types.h>
3937 #ifdef _XOPEN_SOURCE
3944 rm -f conftest.$ac_objext
3945 if { (eval echo "$as_me:3945: \"$ac_compile\"") >&5
3946 (eval $ac_compile) 2>&5
3948 echo "$as_me:3948: \$? = $ac_status" >&5
3949 (exit $ac_status); } &&
3950 { ac_try='test -s conftest.$ac_objext'
3951 { (eval echo "$as_me:3951: \"$ac_try\"") >&5
3954 echo "$as_me:3954: \$? = $ac_status" >&5
3955 (exit $ac_status); }; }; then
3956 cf_cv_xopen_source=no
3958 echo "$as_me: failed program was:" >&5
3959 cat conftest.$ac_ext >&5
3960 cf_cv_xopen_source=$cf_XOPEN_SOURCE
3962 rm -f conftest.$ac_objext conftest.$ac_ext
3966 rm -f conftest.$ac_objext conftest.$ac_ext
3969 echo "$as_me:3969: result: $cf_cv_xopen_source" >&5
3970 echo "${ECHO_T}$cf_cv_xopen_source" >&6
3972 if test "$cf_cv_xopen_source" != no ; then
3974 CFLAGS=`echo "$CFLAGS" | \
3975 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3976 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
3978 CPPFLAGS=`echo "$CPPFLAGS" | \
3979 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3980 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
3982 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
3987 cf_new_extra_cppflags=
3989 for cf_add_cflags in $cf_temp_xopen_source
3991 case $cf_fix_cppflags in
3993 case $cf_add_cflags in #(vi
3994 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
3995 case $cf_add_cflags in
3997 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3999 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
4000 && test -z "${cf_tst_cflags}" \
4001 && cf_fix_cppflags=yes
4003 if test $cf_fix_cppflags = yes ; then
4004 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4006 elif test "${cf_tst_cflags}" = "\"'" ; then
4007 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4013 *$cf_add_cflags) #(vi
4016 case $cf_add_cflags in #(vi
4018 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4020 CPPFLAGS=`echo "$CPPFLAGS" | \
4021 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4022 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4026 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
4031 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
4036 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4038 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
4040 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
4041 && test -z "${cf_tst_cflags}" \
4042 && cf_fix_cppflags=no
4047 if test -n "$cf_new_cflags" ; then
4049 CFLAGS="$CFLAGS $cf_new_cflags"
4052 if test -n "$cf_new_cppflags" ; then
4054 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
4057 if test -n "$cf_new_extra_cppflags" ; then
4059 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
4067 echo "$as_me:4067: checking for $CC option to accept ANSI C" >&5
4068 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
4069 if test "${ac_cv_prog_cc_stdc+set}" = set; then
4070 echo $ECHO_N "(cached) $ECHO_C" >&6
4072 ac_cv_prog_cc_stdc=no
4074 cat >conftest.$ac_ext <<_ACEOF
4075 #line 4075 "configure"
4076 #include "confdefs.h"
4079 #include <sys/types.h>
4080 #include <sys/stat.h>
4081 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
4082 struct buf { int x; };
4083 FILE * (*rcsopen) (struct buf *, struct stat *, int);
4084 static char *e (p, i)
4090 static char *f (char * (*g) (char **, int), char **p, ...)
4095 s = g (p, va_arg (v,int));
4099 int test (int i, double x);
4100 struct s1 {int (*f) (int a);};
4101 struct s2 {int (*f) (double a);};
4102 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
4108 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
4113 # Don't try gcc -ansi; that turns off useful extensions and
4114 # breaks some systems' header files.
4115 # AIX -qlanglvl=ansi
4116 # Ultrix and OSF/1 -std1
4117 # HP-UX 10.20 and later -Ae
4118 # HP-UX older versions -Aa -D_HPUX_SOURCE
4119 # SVR4 -Xc -D__EXTENSIONS__
4120 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
4122 CC="$ac_save_CC $ac_arg"
4123 rm -f conftest.$ac_objext
4124 if { (eval echo "$as_me:4124: \"$ac_compile\"") >&5
4125 (eval $ac_compile) 2>&5
4127 echo "$as_me:4127: \$? = $ac_status" >&5
4128 (exit $ac_status); } &&
4129 { ac_try='test -s conftest.$ac_objext'
4130 { (eval echo "$as_me:4130: \"$ac_try\"") >&5
4133 echo "$as_me:4133: \$? = $ac_status" >&5
4134 (exit $ac_status); }; }; then
4135 ac_cv_prog_cc_stdc=$ac_arg
4138 echo "$as_me: failed program was:" >&5
4139 cat conftest.$ac_ext >&5
4141 rm -f conftest.$ac_objext
4143 rm -f conftest.$ac_ext conftest.$ac_objext
4148 case "x$ac_cv_prog_cc_stdc" in
4150 echo "$as_me:4150: result: none needed" >&5
4151 echo "${ECHO_T}none needed" >&6 ;;
4153 echo "$as_me:4153: result: $ac_cv_prog_cc_stdc" >&5
4154 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
4155 CC="$CC $ac_cv_prog_cc_stdc" ;;
4158 echo "$as_me:4158: checking for an ANSI C-conforming const" >&5
4159 echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
4160 if test "${ac_cv_c_const+set}" = set; then
4161 echo $ECHO_N "(cached) $ECHO_C" >&6
4163 cat >conftest.$ac_ext <<_ACEOF
4164 #line 4164 "configure"
4165 #include "confdefs.h"
4170 /* FIXME: Include the comments suggested by Paul. */
4172 /* Ultrix mips cc rejects this. */
4173 typedef int charset[2];
4175 /* SunOS 4.1.1 cc rejects this. */
4176 char const *const *ccp;
4178 /* NEC SVR4.0.2 mips cc rejects this. */
4179 struct point {int x, y;};
4180 static struct point const zero = {0,0};
4181 /* AIX XL C 1.02.0.0 rejects this.
4182 It does not let you subtract one const X* pointer from another in
4183 an arm of an if-expression whose if-part is not a constant
4185 const char *g = "string";
4186 ccp = &g + (g ? g-g : 0);
4187 /* HPUX 7.0 cc rejects these. */
4190 ccp = (char const *const *) p;
4191 { /* SCO 3.2v4 cc rejects this. */
4193 char const *s = 0 ? (char *) 0 : (char const *) 0;
4197 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
4199 const int *foo = &x[0];
4202 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
4203 typedef const int *iptr;
4207 { /* AIX XL C 1.02.0.0 rejects this saying
4208 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
4209 struct s { int j; const int *ap[3]; };
4210 struct s *b; b->j = 5;
4212 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
4221 rm -f conftest.$ac_objext
4222 if { (eval echo "$as_me:4222: \"$ac_compile\"") >&5
4223 (eval $ac_compile) 2>&5
4225 echo "$as_me:4225: \$? = $ac_status" >&5
4226 (exit $ac_status); } &&
4227 { ac_try='test -s conftest.$ac_objext'
4228 { (eval echo "$as_me:4228: \"$ac_try\"") >&5
4231 echo "$as_me:4231: \$? = $ac_status" >&5
4232 (exit $ac_status); }; }; then
4235 echo "$as_me: failed program was:" >&5
4236 cat conftest.$ac_ext >&5
4239 rm -f conftest.$ac_objext conftest.$ac_ext
4241 echo "$as_me:4241: result: $ac_cv_c_const" >&5
4242 echo "${ECHO_T}$ac_cv_c_const" >&6
4243 if test $ac_cv_c_const = no; then
4245 cat >>confdefs.h <<\EOF
4251 echo "$as_me:4251: checking for signal global datatype" >&5
4252 echo $ECHO_N "checking for signal global datatype... $ECHO_C" >&6
4253 if test "${cf_cv_sig_atomic_t+set}" = set; then
4254 echo $ECHO_N "(cached) $ECHO_C" >&6
4258 "volatile sig_atomic_t" \
4262 cat >conftest.$ac_ext <<_ACEOF
4263 #line 4263 "configure"
4264 #include "confdefs.h"
4266 #include <sys/types.h>
4272 static void handler(int sig)
4279 signal(SIGINT, handler);
4285 rm -f conftest.$ac_objext
4286 if { (eval echo "$as_me:4286: \"$ac_compile\"") >&5
4287 (eval $ac_compile) 2>&5
4289 echo "$as_me:4289: \$? = $ac_status" >&5
4290 (exit $ac_status); } &&
4291 { ac_try='test -s conftest.$ac_objext'
4292 { (eval echo "$as_me:4292: \"$ac_try\"") >&5
4295 echo "$as_me:4295: \$? = $ac_status" >&5
4296 (exit $ac_status); }; }; then
4297 cf_cv_sig_atomic_t=$cf_type
4299 echo "$as_me: failed program was:" >&5
4300 cat conftest.$ac_ext >&5
4301 cf_cv_sig_atomic_t=no
4303 rm -f conftest.$ac_objext conftest.$ac_ext
4304 test "$cf_cv_sig_atomic_t" != no && break
4309 echo "$as_me:4309: result: $cf_cv_sig_atomic_t" >&5
4310 echo "${ECHO_T}$cf_cv_sig_atomic_t" >&6
4311 test "$cf_cv_sig_atomic_t" != no && cat >>confdefs.h <<EOF
4312 #define SIG_ATOMIC_T $cf_cv_sig_atomic_t
4315 echo "$as_me:4315: checking if you want to see long compiling messages" >&5
4316 echo $ECHO_N "checking if you want to see long compiling messages... $ECHO_C" >&6
4318 # Check whether --enable-echo or --disable-echo was given.
4319 if test "${enable_echo+set}" = set; then
4320 enableval="$enable_echo"
4321 test "$enableval" != no && enableval=yes
4322 if test "$enableval" != "yes" ; then
4325 ECHO_LD='@echo linking $@;'
4326 RULE_CC='@echo compiling $<'
4327 SHOW_CC='@echo compiling $@'
4349 echo "$as_me:4349: result: $enableval" >&5
4350 echo "${ECHO_T}$enableval" >&6
4353 if test "$GCC" = yes ; then
4354 echo "$as_me:4354: checking version of $CC" >&5
4355 echo $ECHO_N "checking version of $CC... $ECHO_C" >&6
4356 GCC_VERSION="`${CC} --version 2>/dev/null | sed -e '2,$d' -e 's/^.*(GCC) //' -e 's/^[^0-9.]*//' -e 's/[^0-9.].*//'`"
4357 test -z "$GCC_VERSION" && GCC_VERSION=unknown
4358 echo "$as_me:4358: result: $GCC_VERSION" >&5
4359 echo "${ECHO_T}$GCC_VERSION" >&6
4362 if ( test "$GCC" = yes || test "$GXX" = yes )
4364 echo "$as_me:4364: checking if you want to turn on gcc warnings" >&5
4365 echo $ECHO_N "checking if you want to turn on gcc warnings... $ECHO_C" >&6
4367 # Check whether --enable-warnings or --disable-warnings was given.
4368 if test "${enable_warnings+set}" = set; then
4369 enableval="$enable_warnings"
4370 test "$enableval" != yes && enableval=no
4371 if test "$enableval" != "no" ; then
4381 echo "$as_me:4381: result: $with_warnings" >&5
4382 echo "${ECHO_T}$with_warnings" >&6
4383 if test "$with_warnings" = "yes"
4386 if test "$GCC" = yes
4388 cat > conftest.i <<EOF
4390 #define GCC_PRINTF 0
4395 #ifndef GCC_NORETURN
4396 #define GCC_NORETURN /* nothing */
4399 #define GCC_UNUSED /* nothing */
4402 if test "$GCC" = yes
4404 { echo "$as_me:4404: checking for $CC __attribute__ directives..." >&5
4405 echo "$as_me: checking for $CC __attribute__ directives..." >&6;}
4406 cat > conftest.$ac_ext <<EOF
4407 #line 4407 "${as_me:-configure}"
4408 #include "confdefs.h"
4409 #include "conftest.h"
4410 #include "conftest.i"
4412 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
4414 #define GCC_PRINTFLIKE(fmt,var) /*nothing*/
4417 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
4419 #define GCC_SCANFLIKE(fmt,var) /*nothing*/
4421 extern void wow(char *,...) GCC_SCANFLIKE(1,2);
4422 extern void oops(char *,...) GCC_PRINTFLIKE(1,2) GCC_NORETURN;
4423 extern void foo(void) GCC_NORETURN;
4424 int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { return 0; }
4426 cf_printf_attribute=no
4427 cf_scanf_attribute=no
4428 for cf_attribute in scanf printf unused noreturn
4431 cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
4433 cf_directive="__attribute__(($cf_attribute))"
4434 echo "checking for $CC $cf_directive" 1>&5
4436 case $cf_attribute in #(vi
4438 cf_printf_attribute=yes
4439 cat >conftest.h <<EOF
4440 #define GCC_$cf_ATTRIBUTE 1
4444 cf_scanf_attribute=yes
4445 cat >conftest.h <<EOF
4446 #define GCC_$cf_ATTRIBUTE 1
4450 cat >conftest.h <<EOF
4451 #define GCC_$cf_ATTRIBUTE $cf_directive
4456 if { (eval echo "$as_me:4456: \"$ac_compile\"") >&5
4457 (eval $ac_compile) 2>&5
4459 echo "$as_me:4459: \$? = $ac_status" >&5
4460 (exit $ac_status); }; then
4461 test -n "$verbose" && echo "$as_me:4461: result: ... $cf_attribute" >&5
4462 echo "${ECHO_T}... $cf_attribute" >&6
4463 cat conftest.h >>confdefs.h
4464 case $cf_attribute in #(vi
4466 if test "$cf_printf_attribute" = no ; then
4467 cat >>confdefs.h <<EOF
4468 #define GCC_PRINTFLIKE(fmt,var) /* nothing */
4471 cat >>confdefs.h <<EOF
4472 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
4477 if test "$cf_scanf_attribute" = no ; then
4478 cat >>confdefs.h <<EOF
4479 #define GCC_SCANFLIKE(fmt,var) /* nothing */
4482 cat >>confdefs.h <<EOF
4483 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
4491 fgrep define conftest.i >>confdefs.h
4498 if test "$GCC" = yes ; then
4501 echo "$as_me:4501: checking if this is really Intel C compiler" >&5
4502 echo $ECHO_N "checking if this is really Intel C compiler... $ECHO_C" >&6
4503 cf_save_CFLAGS="$CFLAGS"
4504 CFLAGS="$CFLAGS -no-gcc"
4505 cat >conftest.$ac_ext <<_ACEOF
4506 #line 4506 "configure"
4507 #include "confdefs.h"
4513 #ifdef __INTEL_COMPILER
4522 rm -f conftest.$ac_objext
4523 if { (eval echo "$as_me:4523: \"$ac_compile\"") >&5
4524 (eval $ac_compile) 2>&5
4526 echo "$as_me:4526: \$? = $ac_status" >&5
4527 (exit $ac_status); } &&
4528 { ac_try='test -s conftest.$ac_objext'
4529 { (eval echo "$as_me:4529: \"$ac_try\"") >&5
4532 echo "$as_me:4532: \$? = $ac_status" >&5
4533 (exit $ac_status); }; }; then
4535 cf_save_CFLAGS="$cf_save_CFLAGS -we147 -no-gcc"
4538 echo "$as_me: failed program was:" >&5
4539 cat conftest.$ac_ext >&5
4541 rm -f conftest.$ac_objext conftest.$ac_ext
4542 CFLAGS="$cf_save_CFLAGS"
4543 echo "$as_me:4543: result: $INTEL_COMPILER" >&5
4544 echo "${ECHO_T}$INTEL_COMPILER" >&6
4549 cat > conftest.$ac_ext <<EOF
4550 #line 4550 "${as_me:-configure}"
4551 int main(int argc, char *argv[]) { return (argv[argc-1] == 0) ; }
4554 if test "$INTEL_COMPILER" = yes
4556 # The "-wdXXX" options suppress warnings:
4557 # remark #1419: external declaration in primary source file
4558 # remark #1683: explicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem)
4559 # remark #1684: conversion from pointer to same-sized integral type (potential portability problem)
4560 # remark #193: zero used for undefined preprocessing identifier
4561 # remark #593: variable "curs_sb_left_arrow" was set but never used
4562 # remark #810: conversion from "int" to "Dimension={unsigned short}" may lose significant bits
4563 # remark #869: parameter "tw" was never referenced
4564 # remark #981: operands are evaluated in unspecified order
4565 # warning #279: controlling expression is constant
4567 { echo "$as_me:4567: checking for $CC warning options..." >&5
4568 echo "$as_me: checking for $CC warning options..." >&6;}
4569 cf_save_CFLAGS="$CFLAGS"
4570 EXTRA_CFLAGS="-Wall"
4582 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
4583 if { (eval echo "$as_me:4583: \"$ac_compile\"") >&5
4584 (eval $ac_compile) 2>&5
4586 echo "$as_me:4586: \$? = $ac_status" >&5
4587 (exit $ac_status); }; then
4588 test -n "$verbose" && echo "$as_me:4588: result: ... -$cf_opt" >&5
4589 echo "${ECHO_T}... -$cf_opt" >&6
4590 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
4593 CFLAGS="$cf_save_CFLAGS"
4595 elif test "$GCC" = yes
4597 { echo "$as_me:4597: checking for $CC warning options..." >&5
4598 echo "$as_me: checking for $CC warning options..." >&6;}
4599 cf_save_CFLAGS="$CFLAGS"
4602 test "$with_ext_const" = yes && cf_warn_CONST="Wwrite-strings"
4603 for cf_opt in W Wall \
4604 Wbad-function-cast \
4608 Wmissing-declarations \
4609 Wmissing-prototypes \
4613 Wstrict-prototypes \
4614 Wundef $cf_warn_CONST
4616 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
4617 if { (eval echo "$as_me:4617: \"$ac_compile\"") >&5
4618 (eval $ac_compile) 2>&5
4620 echo "$as_me:4620: \$? = $ac_status" >&5
4621 (exit $ac_status); }; then
4622 test -n "$verbose" && echo "$as_me:4622: result: ... -$cf_opt" >&5
4623 echo "${ECHO_T}... -$cf_opt" >&6
4624 case $cf_opt in #(vi
4626 CPPFLAGS="$CPPFLAGS -DXTSTRINGDEFINES"
4629 case $GCC_VERSION in
4631 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
4633 echo "${as_me:-configure}:4633: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
4639 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
4642 CFLAGS="$cf_save_CFLAGS"
4649 echo "$as_me:4649: checking if you want to use dmalloc for testing" >&5
4650 echo $ECHO_N "checking if you want to use dmalloc for testing... $ECHO_C" >&6
4652 # Check whether --with-dmalloc or --without-dmalloc was given.
4653 if test "${with_dmalloc+set}" = set; then
4654 withval="$with_dmalloc"
4655 cat >>confdefs.h <<\EOF
4656 #define USE_DMALLOC 1
4659 : ${with_cflags:=-g}
4660 : ${with_no_leaks:=yes}
4665 echo "$as_me:4665: result: ${with_dmalloc:-no}" >&5
4666 echo "${ECHO_T}${with_dmalloc:-no}" >&6
4668 case .$with_cflags in #(vi
4670 case .$CFLAGS in #(vi
4678 cf_new_extra_cppflags=
4680 for cf_add_cflags in -g
4682 case $cf_fix_cppflags in
4684 case $cf_add_cflags in #(vi
4685 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
4686 case $cf_add_cflags in
4688 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4690 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
4691 && test -z "${cf_tst_cflags}" \
4692 && cf_fix_cppflags=yes
4694 if test $cf_fix_cppflags = yes ; then
4695 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4697 elif test "${cf_tst_cflags}" = "\"'" ; then
4698 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4704 *$cf_add_cflags) #(vi
4707 case $cf_add_cflags in #(vi
4709 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4711 CPPFLAGS=`echo "$CPPFLAGS" | \
4712 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4713 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4717 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
4722 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
4727 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4729 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
4731 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
4732 && test -z "${cf_tst_cflags}" \
4733 && cf_fix_cppflags=no
4738 if test -n "$cf_new_cflags" ; then
4740 CFLAGS="$CFLAGS $cf_new_cflags"
4743 if test -n "$cf_new_cppflags" ; then
4745 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
4748 if test -n "$cf_new_extra_cppflags" ; then
4750 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
4758 if test "$with_dmalloc" = yes ; then
4759 echo "$as_me:4759: checking for dmalloc.h" >&5
4760 echo $ECHO_N "checking for dmalloc.h... $ECHO_C" >&6
4761 if test "${ac_cv_header_dmalloc_h+set}" = set; then
4762 echo $ECHO_N "(cached) $ECHO_C" >&6
4764 cat >conftest.$ac_ext <<_ACEOF
4765 #line 4765 "configure"
4766 #include "confdefs.h"
4767 #include <dmalloc.h>
4769 if { (eval echo "$as_me:4769: \"$ac_cpp conftest.$ac_ext\"") >&5
4770 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4772 egrep -v '^ *\+' conftest.er1 >conftest.err
4774 cat conftest.err >&5
4775 echo "$as_me:4775: \$? = $ac_status" >&5
4776 (exit $ac_status); } >/dev/null; then
4777 if test -s conftest.err; then
4778 ac_cpp_err=$ac_c_preproc_warn_flag
4785 if test -z "$ac_cpp_err"; then
4786 ac_cv_header_dmalloc_h=yes
4788 echo "$as_me: failed program was:" >&5
4789 cat conftest.$ac_ext >&5
4790 ac_cv_header_dmalloc_h=no
4792 rm -f conftest.err conftest.$ac_ext
4794 echo "$as_me:4794: result: $ac_cv_header_dmalloc_h" >&5
4795 echo "${ECHO_T}$ac_cv_header_dmalloc_h" >&6
4796 if test $ac_cv_header_dmalloc_h = yes; then
4798 echo "$as_me:4798: checking for dmalloc_debug in -ldmalloc" >&5
4799 echo $ECHO_N "checking for dmalloc_debug in -ldmalloc... $ECHO_C" >&6
4800 if test "${ac_cv_lib_dmalloc_dmalloc_debug+set}" = set; then
4801 echo $ECHO_N "(cached) $ECHO_C" >&6
4803 ac_check_lib_save_LIBS=$LIBS
4804 LIBS="-ldmalloc $LIBS"
4805 cat >conftest.$ac_ext <<_ACEOF
4806 #line 4806 "configure"
4807 #include "confdefs.h"
4809 /* Override any gcc2 internal prototype to avoid an error. */
4813 /* We use char because int might match the return type of a gcc2
4814 builtin and then its argument prototype would still apply. */
4815 char dmalloc_debug ();
4824 rm -f conftest.$ac_objext conftest$ac_exeext
4825 if { (eval echo "$as_me:4825: \"$ac_link\"") >&5
4826 (eval $ac_link) 2>&5
4828 echo "$as_me:4828: \$? = $ac_status" >&5
4829 (exit $ac_status); } &&
4830 { ac_try='test -s conftest$ac_exeext'
4831 { (eval echo "$as_me:4831: \"$ac_try\"") >&5
4834 echo "$as_me:4834: \$? = $ac_status" >&5
4835 (exit $ac_status); }; }; then
4836 ac_cv_lib_dmalloc_dmalloc_debug=yes
4838 echo "$as_me: failed program was:" >&5
4839 cat conftest.$ac_ext >&5
4840 ac_cv_lib_dmalloc_dmalloc_debug=no
4842 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4843 LIBS=$ac_check_lib_save_LIBS
4845 echo "$as_me:4845: result: $ac_cv_lib_dmalloc_dmalloc_debug" >&5
4846 echo "${ECHO_T}$ac_cv_lib_dmalloc_dmalloc_debug" >&6
4847 if test $ac_cv_lib_dmalloc_dmalloc_debug = yes; then
4848 cat >>confdefs.h <<EOF
4849 #define HAVE_LIBDMALLOC 1
4852 LIBS="-ldmalloc $LIBS"
4860 echo "$as_me:4860: checking if you want to use dbmalloc for testing" >&5
4861 echo $ECHO_N "checking if you want to use dbmalloc for testing... $ECHO_C" >&6
4863 # Check whether --with-dbmalloc or --without-dbmalloc was given.
4864 if test "${with_dbmalloc+set}" = set; then
4865 withval="$with_dbmalloc"
4866 cat >>confdefs.h <<\EOF
4867 #define USE_DBMALLOC 1
4870 : ${with_cflags:=-g}
4871 : ${with_no_leaks:=yes}
4876 echo "$as_me:4876: result: ${with_dbmalloc:-no}" >&5
4877 echo "${ECHO_T}${with_dbmalloc:-no}" >&6
4879 case .$with_cflags in #(vi
4881 case .$CFLAGS in #(vi
4889 cf_new_extra_cppflags=
4891 for cf_add_cflags in -g
4893 case $cf_fix_cppflags in
4895 case $cf_add_cflags in #(vi
4896 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
4897 case $cf_add_cflags in
4899 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4901 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
4902 && test -z "${cf_tst_cflags}" \
4903 && cf_fix_cppflags=yes
4905 if test $cf_fix_cppflags = yes ; then
4906 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4908 elif test "${cf_tst_cflags}" = "\"'" ; then
4909 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4915 *$cf_add_cflags) #(vi
4918 case $cf_add_cflags in #(vi
4920 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4922 CPPFLAGS=`echo "$CPPFLAGS" | \
4923 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4924 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4928 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
4933 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
4938 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
4940 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
4942 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
4943 && test -z "${cf_tst_cflags}" \
4944 && cf_fix_cppflags=no
4949 if test -n "$cf_new_cflags" ; then
4951 CFLAGS="$CFLAGS $cf_new_cflags"
4954 if test -n "$cf_new_cppflags" ; then
4956 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
4959 if test -n "$cf_new_extra_cppflags" ; then
4961 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
4969 if test "$with_dbmalloc" = yes ; then
4970 echo "$as_me:4970: checking for dbmalloc.h" >&5
4971 echo $ECHO_N "checking for dbmalloc.h... $ECHO_C" >&6
4972 if test "${ac_cv_header_dbmalloc_h+set}" = set; then
4973 echo $ECHO_N "(cached) $ECHO_C" >&6
4975 cat >conftest.$ac_ext <<_ACEOF
4976 #line 4976 "configure"
4977 #include "confdefs.h"
4978 #include <dbmalloc.h>
4980 if { (eval echo "$as_me:4980: \"$ac_cpp conftest.$ac_ext\"") >&5
4981 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4983 egrep -v '^ *\+' conftest.er1 >conftest.err
4985 cat conftest.err >&5
4986 echo "$as_me:4986: \$? = $ac_status" >&5
4987 (exit $ac_status); } >/dev/null; then
4988 if test -s conftest.err; then
4989 ac_cpp_err=$ac_c_preproc_warn_flag
4996 if test -z "$ac_cpp_err"; then
4997 ac_cv_header_dbmalloc_h=yes
4999 echo "$as_me: failed program was:" >&5
5000 cat conftest.$ac_ext >&5
5001 ac_cv_header_dbmalloc_h=no
5003 rm -f conftest.err conftest.$ac_ext
5005 echo "$as_me:5005: result: $ac_cv_header_dbmalloc_h" >&5
5006 echo "${ECHO_T}$ac_cv_header_dbmalloc_h" >&6
5007 if test $ac_cv_header_dbmalloc_h = yes; then
5009 echo "$as_me:5009: checking for debug_malloc in -ldbmalloc" >&5
5010 echo $ECHO_N "checking for debug_malloc in -ldbmalloc... $ECHO_C" >&6
5011 if test "${ac_cv_lib_dbmalloc_debug_malloc+set}" = set; then
5012 echo $ECHO_N "(cached) $ECHO_C" >&6
5014 ac_check_lib_save_LIBS=$LIBS
5015 LIBS="-ldbmalloc $LIBS"
5016 cat >conftest.$ac_ext <<_ACEOF
5017 #line 5017 "configure"
5018 #include "confdefs.h"
5020 /* Override any gcc2 internal prototype to avoid an error. */
5024 /* We use char because int might match the return type of a gcc2
5025 builtin and then its argument prototype would still apply. */
5026 char debug_malloc ();
5035 rm -f conftest.$ac_objext conftest$ac_exeext
5036 if { (eval echo "$as_me:5036: \"$ac_link\"") >&5
5037 (eval $ac_link) 2>&5
5039 echo "$as_me:5039: \$? = $ac_status" >&5
5040 (exit $ac_status); } &&
5041 { ac_try='test -s conftest$ac_exeext'
5042 { (eval echo "$as_me:5042: \"$ac_try\"") >&5
5045 echo "$as_me:5045: \$? = $ac_status" >&5
5046 (exit $ac_status); }; }; then
5047 ac_cv_lib_dbmalloc_debug_malloc=yes
5049 echo "$as_me: failed program was:" >&5
5050 cat conftest.$ac_ext >&5
5051 ac_cv_lib_dbmalloc_debug_malloc=no
5053 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5054 LIBS=$ac_check_lib_save_LIBS
5056 echo "$as_me:5056: result: $ac_cv_lib_dbmalloc_debug_malloc" >&5
5057 echo "${ECHO_T}$ac_cv_lib_dbmalloc_debug_malloc" >&6
5058 if test $ac_cv_lib_dbmalloc_debug_malloc = yes; then
5059 cat >>confdefs.h <<EOF
5060 #define HAVE_LIBDBMALLOC 1
5063 LIBS="-ldbmalloc $LIBS"
5071 echo "$as_me:5071: checking if you want to use valgrind for testing" >&5
5072 echo $ECHO_N "checking if you want to use valgrind for testing... $ECHO_C" >&6
5074 # Check whether --with-valgrind or --without-valgrind was given.
5075 if test "${with_valgrind+set}" = set; then
5076 withval="$with_valgrind"
5077 cat >>confdefs.h <<\EOF
5078 #define USE_VALGRIND 1
5081 : ${with_cflags:=-g}
5082 : ${with_no_leaks:=yes}
5087 echo "$as_me:5087: result: ${with_valgrind:-no}" >&5
5088 echo "${ECHO_T}${with_valgrind:-no}" >&6
5090 case .$with_cflags in #(vi
5092 case .$CFLAGS in #(vi
5100 cf_new_extra_cppflags=
5102 for cf_add_cflags in -g
5104 case $cf_fix_cppflags in
5106 case $cf_add_cflags in #(vi
5107 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
5108 case $cf_add_cflags in
5110 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
5112 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
5113 && test -z "${cf_tst_cflags}" \
5114 && cf_fix_cppflags=yes
5116 if test $cf_fix_cppflags = yes ; then
5117 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
5119 elif test "${cf_tst_cflags}" = "\"'" ; then
5120 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
5126 *$cf_add_cflags) #(vi
5129 case $cf_add_cflags in #(vi
5131 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
5133 CPPFLAGS=`echo "$CPPFLAGS" | \
5134 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
5135 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
5139 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
5144 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
5149 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
5151 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
5153 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
5154 && test -z "${cf_tst_cflags}" \
5155 && cf_fix_cppflags=no
5160 if test -n "$cf_new_cflags" ; then
5162 CFLAGS="$CFLAGS $cf_new_cflags"
5165 if test -n "$cf_new_cppflags" ; then
5167 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
5170 if test -n "$cf_new_extra_cppflags" ; then
5172 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
5180 echo "$as_me:5180: checking if you want to perform memory-leak testing" >&5
5181 echo $ECHO_N "checking if you want to perform memory-leak testing... $ECHO_C" >&6
5183 # Check whether --enable-leaks or --disable-leaks was given.
5184 if test "${enable_leaks+set}" = set; then
5185 enableval="$enable_leaks"
5186 if test "x$enableval" = xno; then with_no_leaks=yes; else with_no_leaks=no; fi
5188 : ${with_no_leaks:=no}
5190 echo "$as_me:5190: result: $with_no_leaks" >&5
5191 echo "${ECHO_T}$with_no_leaks" >&6
5193 if test "$with_no_leaks" = yes ; then
5194 cat >>confdefs.h <<\EOF
5198 cat >>confdefs.h <<\EOF
5199 #define YY_NO_LEAKS 1
5204 echo "$as_me:5204: checking if you want to check for wide-character functions" >&5
5205 echo $ECHO_N "checking if you want to check for wide-character functions... $ECHO_C" >&6
5207 # Check whether --enable-widec or --disable-widec was given.
5208 if test "${enable_widec+set}" = set; then
5209 enableval="$enable_widec"
5210 test "$enableval" != no && enableval=yes
5211 if test "$enableval" != "yes" ; then
5221 echo "$as_me:5221: result: $cf_enable_widec" >&5
5222 echo "${ECHO_T}$cf_enable_widec" >&6
5224 echo "$as_me:5224: checking for specific curses-directory" >&5
5225 echo $ECHO_N "checking for specific curses-directory... $ECHO_C" >&6
5227 # Check whether --with-curses-dir or --without-curses-dir was given.
5228 if test "${with_curses_dir+set}" = set; then
5229 withval="$with_curses_dir"
5230 cf_cv_curses_dir=$withval
5234 echo "$as_me:5234: result: $cf_cv_curses_dir" >&5
5235 echo "${ECHO_T}$cf_cv_curses_dir" >&6
5237 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
5240 if test "x$prefix" != xNONE; then
5241 cf_path_syntax="$prefix"
5243 cf_path_syntax="$ac_default_prefix"
5246 case ".$withval" in #(vi
5247 .\$\(*\)*|.\'*\'*) #(vi
5251 .[a-zA-Z]:[\\/]*) #(vi OS/2 EMX
5254 eval withval="$withval"
5255 case ".$withval" in #(vi
5257 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
5262 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
5265 { { echo "$as_me:5265: error: expected a pathname, not \"$withval\"" >&5
5266 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
5267 { (exit 1); exit 1; }; }
5271 if test -d "$cf_cv_curses_dir"
5274 if test -n "$cf_cv_curses_dir/include" ; then
5275 for cf_add_incdir in $cf_cv_curses_dir/include
5277 while test $cf_add_incdir != /usr/include
5279 if test -d $cf_add_incdir
5282 if test -n "$CFLAGS$CPPFLAGS" ; then
5283 # a loop is needed to ensure we can add subdirs of existing dirs
5284 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
5285 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
5286 cf_have_incdir=yes; break
5291 if test "$cf_have_incdir" = no ; then
5292 if test "$cf_add_incdir" = /usr/local/include ; then
5293 if test "$GCC" = yes
5295 cf_save_CPPFLAGS=$CPPFLAGS
5296 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
5297 cat >conftest.$ac_ext <<_ACEOF
5298 #line 5298 "configure"
5299 #include "confdefs.h"
5309 rm -f conftest.$ac_objext
5310 if { (eval echo "$as_me:5310: \"$ac_compile\"") >&5
5311 (eval $ac_compile) 2>&5
5313 echo "$as_me:5313: \$? = $ac_status" >&5
5314 (exit $ac_status); } &&
5315 { ac_try='test -s conftest.$ac_objext'
5316 { (eval echo "$as_me:5316: \"$ac_try\"") >&5
5319 echo "$as_me:5319: \$? = $ac_status" >&5
5320 (exit $ac_status); }; }; then
5323 echo "$as_me: failed program was:" >&5
5324 cat conftest.$ac_ext >&5
5327 rm -f conftest.$ac_objext conftest.$ac_ext
5328 CPPFLAGS=$cf_save_CPPFLAGS
5333 if test "$cf_have_incdir" = no ; then
5334 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
5336 echo "${as_me:-configure}:5336: testing adding $cf_add_incdir to include-path ..." 1>&5
5338 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
5340 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
5341 test "$cf_top_incdir" = "$cf_add_incdir" && break
5342 cf_add_incdir="$cf_top_incdir"
5351 if test -n "$cf_cv_curses_dir/lib" ; then
5352 for cf_add_libdir in $cf_cv_curses_dir/lib
5354 if test $cf_add_libdir = /usr/lib ; then
5356 elif test -d $cf_add_libdir
5359 if test -n "$LDFLAGS$LIBS" ; then
5360 # a loop is needed to ensure we can add subdirs of existing dirs
5361 for cf_test_libdir in $LDFLAGS $LIBS ; do
5362 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
5363 cf_have_libdir=yes; break
5367 if test "$cf_have_libdir" = no ; then
5368 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
5370 echo "${as_me:-configure}:5370: testing adding $cf_add_libdir to library-path ..." 1>&5
5372 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
5381 echo "$as_me:5381: checking for specified curses library type" >&5
5382 echo $ECHO_N "checking for specified curses library type... $ECHO_C" >&6
5384 # Check whether --with-ncursesw or --without-ncursesw was given.
5385 if test "${with_ncursesw+set}" = set; then
5386 withval="$with_ncursesw"
5387 cf_cv_screen=ncursesw
5390 # Check whether --with-ncurses or --without-ncurses was given.
5391 if test "${with_ncurses+set}" = set; then
5392 withval="$with_ncurses"
5393 cf_cv_screen=ncurses
5396 # Check whether --with-pdcurses or --without-pdcurses was given.
5397 if test "${with_pdcurses+set}" = set; then
5398 withval="$with_pdcurses"
5399 cf_cv_screen=pdcurses
5402 # Check whether --with-curses-colr or --without-curses-colr was given.
5403 if test "${with_curses_colr+set}" = set; then
5404 withval="$with_curses_colr"
5405 cf_cv_screen=curses_colr
5408 # Check whether --with-curses-5lib or --without-curses-5lib was given.
5409 if test "${with_curses_5lib+set}" = set; then
5410 withval="$with_curses_5lib"
5411 cf_cv_screen=curses_5lib
5418 echo "$as_me:5418: result: $cf_cv_screen" >&5
5419 echo "${ECHO_T}$cf_cv_screen" >&6
5421 case $cf_cv_screen in
5424 echo "$as_me:5424: checking for extra include directories" >&5
5425 echo $ECHO_N "checking for extra include directories... $ECHO_C" >&6
5426 if test "${cf_cv_curses_incdir+set}" = set; then
5427 echo $ECHO_N "(cached) $ECHO_C" >&6
5430 cf_cv_curses_incdir=no
5431 case $host_os in #(vi
5433 if test "x$cf_cv_screen" = "xcurses_colr"
5435 test -d /usr/include/curses_colr && \
5436 cf_cv_curses_incdir="-I/usr/include/curses_colr"
5440 if test "x$cf_cv_screen" = "xcurses_5lib"
5442 test -d /usr/5lib && \
5443 test -d /usr/5include && \
5444 cf_cv_curses_incdir="-I/usr/5include"
5450 echo "$as_me:5450: result: $cf_cv_curses_incdir" >&5
5451 echo "${ECHO_T}$cf_cv_curses_incdir" >&6
5452 test "$cf_cv_curses_incdir" != no && CPPFLAGS="$CPPFLAGS $cf_cv_curses_incdir"
5454 echo "$as_me:5454: checking if we have identified curses headers" >&5
5455 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
5456 if test "${cf_cv_ncurses_header+set}" = set; then
5457 echo $ECHO_N "(cached) $ECHO_C" >&6
5460 cf_cv_ncurses_header=none
5463 curses.h ncurses/ncurses.h ncurses/curses.h
5465 cat >conftest.$ac_ext <<_ACEOF
5466 #line 5466 "configure"
5467 #include "confdefs.h"
5468 #include <${cf_header}>
5472 initscr(); tgoto("?", 0,0)
5477 rm -f conftest.$ac_objext
5478 if { (eval echo "$as_me:5478: \"$ac_compile\"") >&5
5479 (eval $ac_compile) 2>&5
5481 echo "$as_me:5481: \$? = $ac_status" >&5
5482 (exit $ac_status); } &&
5483 { ac_try='test -s conftest.$ac_objext'
5484 { (eval echo "$as_me:5484: \"$ac_try\"") >&5
5487 echo "$as_me:5487: \$? = $ac_status" >&5
5488 (exit $ac_status); }; }; then
5489 cf_cv_ncurses_header=$cf_header; break
5491 echo "$as_me: failed program was:" >&5
5492 cat conftest.$ac_ext >&5
5494 rm -f conftest.$ac_objext conftest.$ac_ext
5498 echo "$as_me:5498: result: $cf_cv_ncurses_header" >&5
5499 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
5501 if test "$cf_cv_ncurses_header" = none ; then
5502 { { echo "$as_me:5502: error: No curses header-files found" >&5
5503 echo "$as_me: error: No curses header-files found" >&2;}
5504 { (exit 1); exit 1; }; }
5507 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
5509 for ac_header in $cf_cv_ncurses_header
5511 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
5512 echo "$as_me:5512: checking for $ac_header" >&5
5513 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5514 if eval "test \"\${$as_ac_Header+set}\" = set"; then
5515 echo $ECHO_N "(cached) $ECHO_C" >&6
5517 cat >conftest.$ac_ext <<_ACEOF
5518 #line 5518 "configure"
5519 #include "confdefs.h"
5520 #include <$ac_header>
5522 if { (eval echo "$as_me:5522: \"$ac_cpp conftest.$ac_ext\"") >&5
5523 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
5525 egrep -v '^ *\+' conftest.er1 >conftest.err
5527 cat conftest.err >&5
5528 echo "$as_me:5528: \$? = $ac_status" >&5
5529 (exit $ac_status); } >/dev/null; then
5530 if test -s conftest.err; then
5531 ac_cpp_err=$ac_c_preproc_warn_flag
5538 if test -z "$ac_cpp_err"; then
5539 eval "$as_ac_Header=yes"
5541 echo "$as_me: failed program was:" >&5
5542 cat conftest.$ac_ext >&5
5543 eval "$as_ac_Header=no"
5545 rm -f conftest.err conftest.$ac_ext
5547 echo "$as_me:5547: result: `eval echo '${'$as_ac_Header'}'`" >&5
5548 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
5549 if test `eval echo '${'$as_ac_Header'}'` = yes; then
5550 cat >>confdefs.h <<EOF
5551 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
5557 echo "$as_me:5557: checking for terminfo header" >&5
5558 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
5559 if test "${cf_cv_term_header+set}" = set; then
5560 echo $ECHO_N "(cached) $ECHO_C" >&6
5563 case ${cf_cv_ncurses_header} in #(vi
5564 */ncurses.h|*/ncursesw.h) #(vi
5565 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
5568 cf_term_header=term.h
5572 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
5574 cat >conftest.$ac_ext <<_ACEOF
5575 #line 5575 "configure"
5576 #include "confdefs.h"
5578 #include <${cf_cv_ncurses_header:-curses.h}>
5584 int x = auto_left_margin
5589 rm -f conftest.$ac_objext
5590 if { (eval echo "$as_me:5590: \"$ac_compile\"") >&5
5591 (eval $ac_compile) 2>&5
5593 echo "$as_me:5593: \$? = $ac_status" >&5
5594 (exit $ac_status); } &&
5595 { ac_try='test -s conftest.$ac_objext'
5596 { (eval echo "$as_me:5596: \"$ac_try\"") >&5
5599 echo "$as_me:5599: \$? = $ac_status" >&5
5600 (exit $ac_status); }; }; then
5602 cf_cv_term_header="$cf_test"
5604 echo "$as_me: failed program was:" >&5
5605 cat conftest.$ac_ext >&5
5607 cf_cv_term_header=unknown
5610 rm -f conftest.$ac_objext conftest.$ac_ext
5611 test "$cf_cv_term_header" != unknown && break
5615 echo "$as_me:5615: result: $cf_cv_term_header" >&5
5616 echo "${ECHO_T}$cf_cv_term_header" >&6
5618 # Set definitions to allow ifdef'ing to accommodate subdirectories
5620 case $cf_cv_term_header in # (vi
5622 cat >>confdefs.h <<\EOF
5623 #define HAVE_TERM_H 1
5629 case $cf_cv_term_header in # (vi
5630 ncurses/term.h) #(vi
5631 cat >>confdefs.h <<\EOF
5632 #define HAVE_NCURSES_TERM_H 1
5637 cat >>confdefs.h <<\EOF
5638 #define HAVE_NCURSESW_TERM_H 1
5644 echo "$as_me:5644: checking for ncurses version" >&5
5645 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
5646 if test "${cf_cv_ncurses_version+set}" = set; then
5647 echo $ECHO_N "(cached) $ECHO_C" >&6
5650 cf_cv_ncurses_version=no
5653 if test "$cross_compiling" = yes; then
5655 # This will not work if the preprocessor splits the line after the
5656 # Autoconf token. The 'unproto' program does that.
5657 cat > conftest.$ac_ext <<EOF
5658 #include <${cf_cv_ncurses_header:-curses.h}>
5660 #ifdef NCURSES_VERSION
5661 Autoconf NCURSES_VERSION
5669 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
5670 { (eval echo "$as_me:5670: \"$cf_try\"") >&5
5673 echo "$as_me:5673: \$? = $ac_status" >&5
5674 (exit $ac_status); }
5675 if test -f conftest.out ; then
5676 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
5677 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
5682 cat >conftest.$ac_ext <<_ACEOF
5683 #line 5683 "configure"
5684 #include "confdefs.h"
5686 #include <${cf_cv_ncurses_header:-curses.h}>
5690 FILE *fp = fopen("$cf_tempfile", "w");
5691 #ifdef NCURSES_VERSION
5692 # ifdef NCURSES_VERSION_PATCH
5693 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
5695 fprintf(fp, "%s\n", NCURSES_VERSION);
5699 fprintf(fp, "old\n");
5704 ${cf_cv_main_return:-return}(0);
5707 rm -f conftest$ac_exeext
5708 if { (eval echo "$as_me:5708: \"$ac_link\"") >&5
5709 (eval $ac_link) 2>&5
5711 echo "$as_me:5711: \$? = $ac_status" >&5
5712 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5713 { (eval echo "$as_me:5713: \"$ac_try\"") >&5
5716 echo "$as_me:5716: \$? = $ac_status" >&5
5717 (exit $ac_status); }; }; then
5719 cf_cv_ncurses_version=`cat $cf_tempfile`
5721 echo "$as_me: program exited with status $ac_status" >&5
5722 echo "$as_me: failed program was:" >&5
5723 cat conftest.$ac_ext >&5
5725 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
5730 echo "$as_me:5730: result: $cf_cv_ncurses_version" >&5
5731 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
5732 test "$cf_cv_ncurses_version" = no || cat >>confdefs.h <<\EOF
5736 echo "$as_me:5736: checking if we have identified curses libraries" >&5
5737 echo $ECHO_N "checking if we have identified curses libraries... $ECHO_C" >&6
5738 cat >conftest.$ac_ext <<_ACEOF
5739 #line 5739 "configure"
5740 #include "confdefs.h"
5741 #include <${cf_cv_ncurses_header:-curses.h}>
5745 initscr(); tgoto("?", 0,0)
5750 rm -f conftest.$ac_objext conftest$ac_exeext
5751 if { (eval echo "$as_me:5751: \"$ac_link\"") >&5
5752 (eval $ac_link) 2>&5
5754 echo "$as_me:5754: \$? = $ac_status" >&5
5755 (exit $ac_status); } &&
5756 { ac_try='test -s conftest$ac_exeext'
5757 { (eval echo "$as_me:5757: \"$ac_try\"") >&5
5760 echo "$as_me:5760: \$? = $ac_status" >&5
5761 (exit $ac_status); }; }; then
5764 echo "$as_me: failed program was:" >&5
5765 cat conftest.$ac_ext >&5
5768 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5769 echo "$as_me:5769: result: $cf_result" >&5
5770 echo "${ECHO_T}$cf_result" >&6
5772 if test "$cf_result" = no ; then
5773 case $host_os in #(vi
5775 echo "$as_me:5775: checking for tgoto in -lmytinfo" >&5
5776 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
5777 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
5778 echo $ECHO_N "(cached) $ECHO_C" >&6
5780 ac_check_lib_save_LIBS=$LIBS
5781 LIBS="-lmytinfo $LIBS"
5782 cat >conftest.$ac_ext <<_ACEOF
5783 #line 5783 "configure"
5784 #include "confdefs.h"
5786 /* Override any gcc2 internal prototype to avoid an error. */
5790 /* We use char because int might match the return type of a gcc2
5791 builtin and then its argument prototype would still apply. */
5801 rm -f conftest.$ac_objext conftest$ac_exeext
5802 if { (eval echo "$as_me:5802: \"$ac_link\"") >&5
5803 (eval $ac_link) 2>&5
5805 echo "$as_me:5805: \$? = $ac_status" >&5
5806 (exit $ac_status); } &&
5807 { ac_try='test -s conftest$ac_exeext'
5808 { (eval echo "$as_me:5808: \"$ac_try\"") >&5
5811 echo "$as_me:5811: \$? = $ac_status" >&5
5812 (exit $ac_status); }; }; then
5813 ac_cv_lib_mytinfo_tgoto=yes
5815 echo "$as_me: failed program was:" >&5
5816 cat conftest.$ac_ext >&5
5817 ac_cv_lib_mytinfo_tgoto=no
5819 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5820 LIBS=$ac_check_lib_save_LIBS
5822 echo "$as_me:5822: result: $ac_cv_lib_mytinfo_tgoto" >&5
5823 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
5824 if test $ac_cv_lib_mytinfo_tgoto = yes; then
5825 LIBS="-lmytinfo $LIBS"
5830 # Looking at HPUX 10.20, the Hcurses library is the oldest (1997), cur_colr
5831 # next (1998), and xcurses "newer" (2000). There is no header file for
5832 # Hcurses; the subdirectory curses_colr has the headers (curses.h and
5833 # term.h) for cur_colr
5834 if test "x$cf_cv_screen" = "xcurses_colr"
5836 echo "$as_me:5836: checking for initscr in -lcur_colr" >&5
5837 echo $ECHO_N "checking for initscr in -lcur_colr... $ECHO_C" >&6
5838 if test "${ac_cv_lib_cur_colr_initscr+set}" = set; then
5839 echo $ECHO_N "(cached) $ECHO_C" >&6
5841 ac_check_lib_save_LIBS=$LIBS
5842 LIBS="-lcur_colr $LIBS"
5843 cat >conftest.$ac_ext <<_ACEOF
5844 #line 5844 "configure"
5845 #include "confdefs.h"
5847 /* Override any gcc2 internal prototype to avoid an error. */
5851 /* We use char because int might match the return type of a gcc2
5852 builtin and then its argument prototype would still apply. */
5862 rm -f conftest.$ac_objext conftest$ac_exeext
5863 if { (eval echo "$as_me:5863: \"$ac_link\"") >&5
5864 (eval $ac_link) 2>&5
5866 echo "$as_me:5866: \$? = $ac_status" >&5
5867 (exit $ac_status); } &&
5868 { ac_try='test -s conftest$ac_exeext'
5869 { (eval echo "$as_me:5869: \"$ac_try\"") >&5
5872 echo "$as_me:5872: \$? = $ac_status" >&5
5873 (exit $ac_status); }; }; then
5874 ac_cv_lib_cur_colr_initscr=yes
5876 echo "$as_me: failed program was:" >&5
5877 cat conftest.$ac_ext >&5
5878 ac_cv_lib_cur_colr_initscr=no
5880 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5881 LIBS=$ac_check_lib_save_LIBS
5883 echo "$as_me:5883: result: $ac_cv_lib_cur_colr_initscr" >&5
5884 echo "${ECHO_T}$ac_cv_lib_cur_colr_initscr" >&6
5885 if test $ac_cv_lib_cur_colr_initscr = yes; then
5887 LIBS="-lcur_colr $LIBS"
5888 ac_cv_func_initscr=yes
5892 echo "$as_me:5892: checking for initscr in -lHcurses" >&5
5893 echo $ECHO_N "checking for initscr in -lHcurses... $ECHO_C" >&6
5894 if test "${ac_cv_lib_Hcurses_initscr+set}" = set; then
5895 echo $ECHO_N "(cached) $ECHO_C" >&6
5897 ac_check_lib_save_LIBS=$LIBS
5898 LIBS="-lHcurses $LIBS"
5899 cat >conftest.$ac_ext <<_ACEOF
5900 #line 5900 "configure"
5901 #include "confdefs.h"
5903 /* Override any gcc2 internal prototype to avoid an error. */
5907 /* We use char because int might match the return type of a gcc2
5908 builtin and then its argument prototype would still apply. */
5918 rm -f conftest.$ac_objext conftest$ac_exeext
5919 if { (eval echo "$as_me:5919: \"$ac_link\"") >&5
5920 (eval $ac_link) 2>&5
5922 echo "$as_me:5922: \$? = $ac_status" >&5
5923 (exit $ac_status); } &&
5924 { ac_try='test -s conftest$ac_exeext'
5925 { (eval echo "$as_me:5925: \"$ac_try\"") >&5
5928 echo "$as_me:5928: \$? = $ac_status" >&5
5929 (exit $ac_status); }; }; then
5930 ac_cv_lib_Hcurses_initscr=yes
5932 echo "$as_me: failed program was:" >&5
5933 cat conftest.$ac_ext >&5
5934 ac_cv_lib_Hcurses_initscr=no
5936 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5937 LIBS=$ac_check_lib_save_LIBS
5939 echo "$as_me:5939: result: $ac_cv_lib_Hcurses_initscr" >&5
5940 echo "${ECHO_T}$ac_cv_lib_Hcurses_initscr" >&6
5941 if test $ac_cv_lib_Hcurses_initscr = yes; then
5943 # HP's header uses __HP_CURSES, but user claims _HP_CURSES.
5944 LIBS="-lHcurses $LIBS"
5945 CPPFLAGS="$CPPFLAGS -D__HP_CURSES -D_HP_CURSES"
5946 ac_cv_func_initscr=yes
5955 case `arch 2>/dev/null` in
5960 if test -n "/lib64" ; then
5961 for cf_add_libdir in /lib64
5963 if test $cf_add_libdir = /usr/lib ; then
5965 elif test -d $cf_add_libdir
5968 if test -n "$LDFLAGS$LIBS" ; then
5969 # a loop is needed to ensure we can add subdirs of existing dirs
5970 for cf_test_libdir in $LDFLAGS $LIBS ; do
5971 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
5972 cf_have_libdir=yes; break
5976 if test "$cf_have_libdir" = no ; then
5977 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
5979 echo "${as_me:-configure}:5979: testing adding $cf_add_libdir to library-path ..." 1>&5
5981 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
5989 if test -n "/lib" ; then
5990 for cf_add_libdir in /lib
5992 if test $cf_add_libdir = /usr/lib ; then
5994 elif test -d $cf_add_libdir
5997 if test -n "$LDFLAGS$LIBS" ; then
5998 # a loop is needed to ensure we can add subdirs of existing dirs
5999 for cf_test_libdir in $LDFLAGS $LIBS ; do
6000 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
6001 cf_have_libdir=yes; break
6005 if test "$cf_have_libdir" = no ; then
6006 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
6008 echo "${as_me:-configure}:6008: testing adding $cf_add_libdir to library-path ..." 1>&5
6010 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
6020 if test -n "/lib" ; then
6021 for cf_add_libdir in /lib
6023 if test $cf_add_libdir = /usr/lib ; then
6025 elif test -d $cf_add_libdir
6028 if test -n "$LDFLAGS$LIBS" ; then
6029 # a loop is needed to ensure we can add subdirs of existing dirs
6030 for cf_test_libdir in $LDFLAGS $LIBS ; do
6031 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
6032 cf_have_libdir=yes; break
6036 if test "$cf_have_libdir" = no ; then
6037 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
6039 echo "${as_me:-configure}:6039: testing adding $cf_add_libdir to library-path ..." 1>&5
6041 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
6051 if test "x$cf_cv_screen" = "xcurses_5lib"
6053 if test -d /usr/5lib ; then
6055 if test -n "/usr/5lib" ; then
6056 for cf_add_libdir in /usr/5lib
6058 if test $cf_add_libdir = /usr/lib ; then
6060 elif test -d $cf_add_libdir
6063 if test -n "$LDFLAGS$LIBS" ; then
6064 # a loop is needed to ensure we can add subdirs of existing dirs
6065 for cf_test_libdir in $LDFLAGS $LIBS ; do
6066 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
6067 cf_have_libdir=yes; break
6071 if test "$cf_have_libdir" = no ; then
6072 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
6074 echo "${as_me:-configure}:6074: testing adding $cf_add_libdir to library-path ..." 1>&5
6076 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
6082 LIBS="-lcurses -ltermcap $LIBS"
6085 ac_cv_func_initscr=yes
6089 if test ".$ac_cv_func_initscr" != .yes ; then
6090 cf_save_LIBS="$LIBS"
6094 if test ".${cf_cv_ncurses_version:-no}" != .no
6096 cf_check_list="ncurses curses cursesX"
6098 cf_check_list="cursesX curses ncurses"
6101 # Check for library containing tgoto. Do this before curses library
6102 # because it may be needed to link the test-case for initscr.
6103 echo "$as_me:6103: checking for tgoto" >&5
6104 echo $ECHO_N "checking for tgoto... $ECHO_C" >&6
6105 if test "${ac_cv_func_tgoto+set}" = set; then
6106 echo $ECHO_N "(cached) $ECHO_C" >&6
6108 cat >conftest.$ac_ext <<_ACEOF
6109 #line 6109 "configure"
6110 #include "confdefs.h"
6111 /* System header to define __stub macros and hopefully few prototypes,
6112 which can conflict with char tgoto (); below. */
6114 /* Override any gcc2 internal prototype to avoid an error. */
6118 /* We use char because int might match the return type of a gcc2
6119 builtin and then its argument prototype would still apply. */
6126 /* The GNU C library defines this for functions which it implements
6127 to always fail with ENOSYS. Some functions are actually named
6128 something starting with __ and the normal name is an alias. */
6129 #if defined (__stub_tgoto) || defined (__stub___tgoto)
6139 rm -f conftest.$ac_objext conftest$ac_exeext
6140 if { (eval echo "$as_me:6140: \"$ac_link\"") >&5
6141 (eval $ac_link) 2>&5
6143 echo "$as_me:6143: \$? = $ac_status" >&5
6144 (exit $ac_status); } &&
6145 { ac_try='test -s conftest$ac_exeext'
6146 { (eval echo "$as_me:6146: \"$ac_try\"") >&5
6149 echo "$as_me:6149: \$? = $ac_status" >&5
6150 (exit $ac_status); }; }; then
6151 ac_cv_func_tgoto=yes
6153 echo "$as_me: failed program was:" >&5
6154 cat conftest.$ac_ext >&5
6157 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6159 echo "$as_me:6159: result: $ac_cv_func_tgoto" >&5
6160 echo "${ECHO_T}$ac_cv_func_tgoto" >&6
6161 if test $ac_cv_func_tgoto = yes; then
6162 cf_term_lib=predefined
6165 for cf_term_lib in $cf_check_list otermcap termcap termlib unknown
6167 as_ac_Lib=`echo "ac_cv_lib_$cf_term_lib''_tgoto" | $as_tr_sh`
6168 echo "$as_me:6168: checking for tgoto in -l$cf_term_lib" >&5
6169 echo $ECHO_N "checking for tgoto in -l$cf_term_lib... $ECHO_C" >&6
6170 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
6171 echo $ECHO_N "(cached) $ECHO_C" >&6
6173 ac_check_lib_save_LIBS=$LIBS
6174 LIBS="-l$cf_term_lib $LIBS"
6175 cat >conftest.$ac_ext <<_ACEOF
6176 #line 6176 "configure"
6177 #include "confdefs.h"
6179 /* Override any gcc2 internal prototype to avoid an error. */
6183 /* We use char because int might match the return type of a gcc2
6184 builtin and then its argument prototype would still apply. */
6194 rm -f conftest.$ac_objext conftest$ac_exeext
6195 if { (eval echo "$as_me:6195: \"$ac_link\"") >&5
6196 (eval $ac_link) 2>&5
6198 echo "$as_me:6198: \$? = $ac_status" >&5
6199 (exit $ac_status); } &&
6200 { ac_try='test -s conftest$ac_exeext'
6201 { (eval echo "$as_me:6201: \"$ac_try\"") >&5
6204 echo "$as_me:6204: \$? = $ac_status" >&5
6205 (exit $ac_status); }; }; then
6206 eval "$as_ac_Lib=yes"
6208 echo "$as_me: failed program was:" >&5
6209 cat conftest.$ac_ext >&5
6210 eval "$as_ac_Lib=no"
6212 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6213 LIBS=$ac_check_lib_save_LIBS
6215 echo "$as_me:6215: result: `eval echo '${'$as_ac_Lib'}'`" >&5
6216 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
6217 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
6225 # Check for library containing initscr
6226 test "$cf_term_lib" != predefined && test "$cf_term_lib" != unknown && LIBS="-l$cf_term_lib $cf_save_LIBS"
6227 for cf_curs_lib in $cf_check_list xcurses jcurses pdcurses unknown
6229 as_ac_Lib=`echo "ac_cv_lib_$cf_curs_lib''_initscr" | $as_tr_sh`
6230 echo "$as_me:6230: checking for initscr in -l$cf_curs_lib" >&5
6231 echo $ECHO_N "checking for initscr in -l$cf_curs_lib... $ECHO_C" >&6
6232 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
6233 echo $ECHO_N "(cached) $ECHO_C" >&6
6235 ac_check_lib_save_LIBS=$LIBS
6236 LIBS="-l$cf_curs_lib $LIBS"
6237 cat >conftest.$ac_ext <<_ACEOF
6238 #line 6238 "configure"
6239 #include "confdefs.h"
6241 /* Override any gcc2 internal prototype to avoid an error. */
6245 /* We use char because int might match the return type of a gcc2
6246 builtin and then its argument prototype would still apply. */
6256 rm -f conftest.$ac_objext conftest$ac_exeext
6257 if { (eval echo "$as_me:6257: \"$ac_link\"") >&5
6258 (eval $ac_link) 2>&5
6260 echo "$as_me:6260: \$? = $ac_status" >&5
6261 (exit $ac_status); } &&
6262 { ac_try='test -s conftest$ac_exeext'
6263 { (eval echo "$as_me:6263: \"$ac_try\"") >&5
6266 echo "$as_me:6266: \$? = $ac_status" >&5
6267 (exit $ac_status); }; }; then
6268 eval "$as_ac_Lib=yes"
6270 echo "$as_me: failed program was:" >&5
6271 cat conftest.$ac_ext >&5
6272 eval "$as_ac_Lib=no"
6274 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6275 LIBS=$ac_check_lib_save_LIBS
6277 echo "$as_me:6277: result: `eval echo '${'$as_ac_Lib'}'`" >&5
6278 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
6279 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
6284 test $cf_curs_lib = unknown && { { echo "$as_me:6284: error: no curses library found" >&5
6285 echo "$as_me: error: no curses library found" >&2;}
6286 { (exit 1); exit 1; }; }
6288 LIBS="-l$cf_curs_lib $cf_save_LIBS"
6289 if test "$cf_term_lib" = unknown ; then
6290 echo "$as_me:6290: checking if we can link with $cf_curs_lib library" >&5
6291 echo $ECHO_N "checking if we can link with $cf_curs_lib library... $ECHO_C" >&6
6292 cat >conftest.$ac_ext <<_ACEOF
6293 #line 6293 "configure"
6294 #include "confdefs.h"
6295 #include <${cf_cv_ncurses_header:-curses.h}>
6304 rm -f conftest.$ac_objext conftest$ac_exeext
6305 if { (eval echo "$as_me:6305: \"$ac_link\"") >&5
6306 (eval $ac_link) 2>&5
6308 echo "$as_me:6308: \$? = $ac_status" >&5
6309 (exit $ac_status); } &&
6310 { ac_try='test -s conftest$ac_exeext'
6311 { (eval echo "$as_me:6311: \"$ac_try\"") >&5
6314 echo "$as_me:6314: \$? = $ac_status" >&5
6315 (exit $ac_status); }; }; then
6318 echo "$as_me: failed program was:" >&5
6319 cat conftest.$ac_ext >&5
6322 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6323 echo "$as_me:6323: result: $cf_result" >&5
6324 echo "${ECHO_T}$cf_result" >&6
6325 test $cf_result = no && { { echo "$as_me:6325: error: Cannot link curses library" >&5
6326 echo "$as_me: error: Cannot link curses library" >&2;}
6327 { (exit 1); exit 1; }; }
6328 elif test "$cf_curs_lib" = "$cf_term_lib" ; then
6330 elif test "$cf_term_lib" != predefined ; then
6331 echo "$as_me:6331: checking if we need both $cf_curs_lib and $cf_term_lib libraries" >&5
6332 echo $ECHO_N "checking if we need both $cf_curs_lib and $cf_term_lib libraries... $ECHO_C" >&6
6333 cat >conftest.$ac_ext <<_ACEOF
6334 #line 6334 "configure"
6335 #include "confdefs.h"
6336 #include <${cf_cv_ncurses_header:-curses.h}>
6340 initscr(); tgoto((char *)0, 0, 0);
6345 rm -f conftest.$ac_objext conftest$ac_exeext
6346 if { (eval echo "$as_me:6346: \"$ac_link\"") >&5
6347 (eval $ac_link) 2>&5
6349 echo "$as_me:6349: \$? = $ac_status" >&5
6350 (exit $ac_status); } &&
6351 { ac_try='test -s conftest$ac_exeext'
6352 { (eval echo "$as_me:6352: \"$ac_try\"") >&5
6355 echo "$as_me:6355: \$? = $ac_status" >&5
6356 (exit $ac_status); }; }; then
6359 echo "$as_me: failed program was:" >&5
6360 cat conftest.$ac_ext >&5
6362 LIBS="-l$cf_curs_lib -l$cf_term_lib $cf_save_LIBS"
6363 cat >conftest.$ac_ext <<_ACEOF
6364 #line 6364 "configure"
6365 #include "confdefs.h"
6366 #include <${cf_cv_ncurses_header:-curses.h}>
6375 rm -f conftest.$ac_objext conftest$ac_exeext
6376 if { (eval echo "$as_me:6376: \"$ac_link\"") >&5
6377 (eval $ac_link) 2>&5
6379 echo "$as_me:6379: \$? = $ac_status" >&5
6380 (exit $ac_status); } &&
6381 { ac_try='test -s conftest$ac_exeext'
6382 { (eval echo "$as_me:6382: \"$ac_try\"") >&5
6385 echo "$as_me:6385: \$? = $ac_status" >&5
6386 (exit $ac_status); }; }; then
6389 echo "$as_me: failed program was:" >&5
6390 cat conftest.$ac_ext >&5
6393 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6396 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6397 echo "$as_me:6397: result: $cf_result" >&5
6398 echo "${ECHO_T}$cf_result" >&6
6403 echo "$as_me:6403: checking for NetBSD form.h" >&5
6404 echo $ECHO_N "checking for NetBSD form.h... $ECHO_C" >&6
6405 if test "${cf_cv_netbsd_form_h+set}" = set; then
6406 echo $ECHO_N "(cached) $ECHO_C" >&6
6409 cat >conftest.$ac_ext <<_ACEOF
6410 #line 6410 "configure"
6411 #include "confdefs.h"
6413 #include <${cf_cv_ncurses_header:-curses.h}>
6421 int y = current_field(form)->cursor_ypos;
6422 int x = current_field(form)->cursor_xpos;
6428 rm -f conftest.$ac_objext
6429 if { (eval echo "$as_me:6429: \"$ac_compile\"") >&5
6430 (eval $ac_compile) 2>&5
6432 echo "$as_me:6432: \$? = $ac_status" >&5
6433 (exit $ac_status); } &&
6434 { ac_try='test -s conftest.$ac_objext'
6435 { (eval echo "$as_me:6435: \"$ac_try\"") >&5
6438 echo "$as_me:6438: \$? = $ac_status" >&5
6439 (exit $ac_status); }; }; then
6440 cf_cv_netbsd_form_h=yes
6443 echo "$as_me: failed program was:" >&5
6444 cat conftest.$ac_ext >&5
6445 cf_cv_netbsd_form_h=no
6447 rm -f conftest.$ac_objext conftest.$ac_ext
6450 echo "$as_me:6450: result: $cf_cv_netbsd_form_h" >&5
6451 echo "${ECHO_T}$cf_cv_netbsd_form_h" >&6
6453 test "$cf_cv_netbsd_form_h" = yes && cat >>confdefs.h <<\EOF
6454 #define HAVE_NETBSD_FORM_H 1
6457 echo "$as_me:6457: checking for NetBSD menu.h" >&5
6458 echo $ECHO_N "checking for NetBSD menu.h... $ECHO_C" >&6
6459 if test "${cf_cv_netbsd_menu_h+set}" = set; then
6460 echo $ECHO_N "(cached) $ECHO_C" >&6
6463 cat >conftest.$ac_ext <<_ACEOF
6464 #line 6464 "configure"
6465 #include "confdefs.h"
6467 #include <${cf_cv_ncurses_header:-curses.h}>
6475 int y = menu->max_item_width;
6481 rm -f conftest.$ac_objext
6482 if { (eval echo "$as_me:6482: \"$ac_compile\"") >&5
6483 (eval $ac_compile) 2>&5
6485 echo "$as_me:6485: \$? = $ac_status" >&5
6486 (exit $ac_status); } &&
6487 { ac_try='test -s conftest.$ac_objext'
6488 { (eval echo "$as_me:6488: \"$ac_try\"") >&5
6491 echo "$as_me:6491: \$? = $ac_status" >&5
6492 (exit $ac_status); }; }; then
6493 cf_cv_netbsd_menu_h=yes
6496 echo "$as_me: failed program was:" >&5
6497 cat conftest.$ac_ext >&5
6498 cf_cv_netbsd_menu_h=no
6500 rm -f conftest.$ac_objext conftest.$ac_ext
6503 echo "$as_me:6503: result: $cf_cv_netbsd_menu_h" >&5
6504 echo "${ECHO_T}$cf_cv_netbsd_menu_h" >&6
6506 test "$cf_cv_netbsd_menu_h" = yes && cat >>confdefs.h <<\EOF
6507 #define HAVE_NETBSD_MENU_H 1
6513 cf_ncuconfig_root=ncurses
6515 echo "Looking for ${cf_ncuconfig_root}-config"
6516 for ac_prog in ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
6518 # Extract the first word of "$ac_prog", so it can be a program name with args.
6519 set dummy $ac_prog; ac_word=$2
6520 echo "$as_me:6520: checking for $ac_word" >&5
6521 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
6522 if test "${ac_cv_path_NCURSES_CONFIG+set}" = set; then
6523 echo $ECHO_N "(cached) $ECHO_C" >&6
6525 case $NCURSES_CONFIG in
6527 ac_cv_path_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test with a path.
6530 ac_save_IFS=$IFS; IFS=$ac_path_separator
6532 for ac_dir in $ac_dummy; do
6534 test -z "$ac_dir" && ac_dir=.
6535 if $as_executable_p "$ac_dir/$ac_word"; then
6536 ac_cv_path_NCURSES_CONFIG="$ac_dir/$ac_word"
6537 echo "$as_me:6537: found $ac_dir/$ac_word" >&5
6545 NCURSES_CONFIG=$ac_cv_path_NCURSES_CONFIG
6547 if test -n "$NCURSES_CONFIG"; then
6548 echo "$as_me:6548: result: $NCURSES_CONFIG" >&5
6549 echo "${ECHO_T}$NCURSES_CONFIG" >&6
6551 echo "$as_me:6551: result: no" >&5
6552 echo "${ECHO_T}no" >&6
6555 test -n "$NCURSES_CONFIG" && break
6557 test -n "$NCURSES_CONFIG" || NCURSES_CONFIG="none"
6559 if test "$NCURSES_CONFIG" != none ; then
6561 CPPFLAGS="$CPPFLAGS `$NCURSES_CONFIG --cflags`"
6562 LIBS="`$NCURSES_CONFIG --libs` $LIBS"
6564 # even with config script, some packages use no-override for curses.h
6566 echo "$as_me:6566: checking if we have identified curses headers" >&5
6567 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
6568 if test "${cf_cv_ncurses_header+set}" = set; then
6569 echo $ECHO_N "(cached) $ECHO_C" >&6
6572 cf_cv_ncurses_header=none
6579 cat >conftest.$ac_ext <<_ACEOF
6580 #line 6580 "configure"
6581 #include "confdefs.h"
6582 #include <${cf_header}>
6586 initscr(); tgoto("?", 0,0)
6591 rm -f conftest.$ac_objext
6592 if { (eval echo "$as_me:6592: \"$ac_compile\"") >&5
6593 (eval $ac_compile) 2>&5
6595 echo "$as_me:6595: \$? = $ac_status" >&5
6596 (exit $ac_status); } &&
6597 { ac_try='test -s conftest.$ac_objext'
6598 { (eval echo "$as_me:6598: \"$ac_try\"") >&5
6601 echo "$as_me:6601: \$? = $ac_status" >&5
6602 (exit $ac_status); }; }; then
6603 cf_cv_ncurses_header=$cf_header; break
6605 echo "$as_me: failed program was:" >&5
6606 cat conftest.$ac_ext >&5
6608 rm -f conftest.$ac_objext conftest.$ac_ext
6612 echo "$as_me:6612: result: $cf_cv_ncurses_header" >&5
6613 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
6615 if test "$cf_cv_ncurses_header" = none ; then
6616 { { echo "$as_me:6616: error: No curses header-files found" >&5
6617 echo "$as_me: error: No curses header-files found" >&2;}
6618 { (exit 1); exit 1; }; }
6621 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
6623 for ac_header in $cf_cv_ncurses_header
6625 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6626 echo "$as_me:6626: checking for $ac_header" >&5
6627 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6628 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6629 echo $ECHO_N "(cached) $ECHO_C" >&6
6631 cat >conftest.$ac_ext <<_ACEOF
6632 #line 6632 "configure"
6633 #include "confdefs.h"
6634 #include <$ac_header>
6636 if { (eval echo "$as_me:6636: \"$ac_cpp conftest.$ac_ext\"") >&5
6637 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6639 egrep -v '^ *\+' conftest.er1 >conftest.err
6641 cat conftest.err >&5
6642 echo "$as_me:6642: \$? = $ac_status" >&5
6643 (exit $ac_status); } >/dev/null; then
6644 if test -s conftest.err; then
6645 ac_cpp_err=$ac_c_preproc_warn_flag
6652 if test -z "$ac_cpp_err"; then
6653 eval "$as_ac_Header=yes"
6655 echo "$as_me: failed program was:" >&5
6656 cat conftest.$ac_ext >&5
6657 eval "$as_ac_Header=no"
6659 rm -f conftest.err conftest.$ac_ext
6661 echo "$as_me:6661: result: `eval echo '${'$as_ac_Header'}'`" >&5
6662 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6663 if test `eval echo '${'$as_ac_Header'}'` = yes; then
6664 cat >>confdefs.h <<EOF
6665 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6671 cat >>confdefs.h <<\EOF
6675 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
6677 cat >>confdefs.h <<EOF
6678 #define $cf_nculib_ROOT 1
6681 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
6685 cf_ncuhdr_root=ncurses
6687 test -n "$cf_cv_curses_dir" && \
6688 test "$cf_cv_curses_dir" != "no" && { \
6690 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
6691 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
6693 while test $cf_add_incdir != /usr/include
6695 if test -d $cf_add_incdir
6698 if test -n "$CFLAGS$CPPFLAGS" ; then
6699 # a loop is needed to ensure we can add subdirs of existing dirs
6700 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
6701 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
6702 cf_have_incdir=yes; break
6707 if test "$cf_have_incdir" = no ; then
6708 if test "$cf_add_incdir" = /usr/local/include ; then
6709 if test "$GCC" = yes
6711 cf_save_CPPFLAGS=$CPPFLAGS
6712 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6713 cat >conftest.$ac_ext <<_ACEOF
6714 #line 6714 "configure"
6715 #include "confdefs.h"
6725 rm -f conftest.$ac_objext
6726 if { (eval echo "$as_me:6726: \"$ac_compile\"") >&5
6727 (eval $ac_compile) 2>&5
6729 echo "$as_me:6729: \$? = $ac_status" >&5
6730 (exit $ac_status); } &&
6731 { ac_try='test -s conftest.$ac_objext'
6732 { (eval echo "$as_me:6732: \"$ac_try\"") >&5
6735 echo "$as_me:6735: \$? = $ac_status" >&5
6736 (exit $ac_status); }; }; then
6739 echo "$as_me: failed program was:" >&5
6740 cat conftest.$ac_ext >&5
6743 rm -f conftest.$ac_objext conftest.$ac_ext
6744 CPPFLAGS=$cf_save_CPPFLAGS
6749 if test "$cf_have_incdir" = no ; then
6750 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
6752 echo "${as_me:-configure}:6752: testing adding $cf_add_incdir to include-path ..." 1>&5
6754 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6756 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
6757 test "$cf_top_incdir" = "$cf_add_incdir" && break
6758 cf_add_incdir="$cf_top_incdir"
6769 echo "$as_me:6769: checking for $cf_ncuhdr_root header in include-path" >&5
6770 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
6771 if test "${cf_cv_ncurses_h+set}" = set; then
6772 echo $ECHO_N "(cached) $ECHO_C" >&6
6775 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
6776 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
6777 for cf_header in $cf_header_list
6780 cat >conftest.$ac_ext <<_ACEOF
6781 #line 6781 "configure"
6782 #include "confdefs.h"
6784 #include <$cf_header>
6789 #ifdef NCURSES_VERSION
6791 printf("%s\n", NCURSES_VERSION);
6804 rm -f conftest.$ac_objext
6805 if { (eval echo "$as_me:6805: \"$ac_compile\"") >&5
6806 (eval $ac_compile) 2>&5
6808 echo "$as_me:6808: \$? = $ac_status" >&5
6809 (exit $ac_status); } &&
6810 { ac_try='test -s conftest.$ac_objext'
6811 { (eval echo "$as_me:6811: \"$ac_try\"") >&5
6814 echo "$as_me:6814: \$? = $ac_status" >&5
6815 (exit $ac_status); }; }; then
6816 cf_cv_ncurses_h=$cf_header
6819 echo "$as_me: failed program was:" >&5
6820 cat conftest.$ac_ext >&5
6823 rm -f conftest.$ac_objext conftest.$ac_ext
6825 test "$cf_cv_ncurses_h" != no && break
6829 echo "$as_me:6829: result: $cf_cv_ncurses_h" >&5
6830 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
6832 if test "$cf_cv_ncurses_h" != no ; then
6833 cf_cv_ncurses_header=$cf_cv_ncurses_h
6836 echo "$as_me:6836: checking for $cf_ncuhdr_root include-path" >&5
6837 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
6838 if test "${cf_cv_ncurses_h2+set}" = set; then
6839 echo $ECHO_N "(cached) $ECHO_C" >&6
6842 test -n "$verbose" && echo
6846 # collect the current set of include-directories from compiler flags
6847 cf_header_path_list=""
6848 if test -n "${CFLAGS}${CPPFLAGS}" ; then
6849 for cf_header_path in $CPPFLAGS $CFLAGS
6851 case $cf_header_path in #(vi
6853 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
6855 test "$cf_header_path" != "NONE" && \
6856 test -d "$cf_header_path" && \
6858 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
6859 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
6860 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
6861 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
6862 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
6863 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"
6866 cf_header_path_list="$cf_header_path_list $cf_search"
6872 # add the variations for the package we are looking for
6876 test "/usr" != "$prefix" && \
6878 (test $prefix = NONE || test "/usr" != "$prefix") && {
6879 test -n "$verbose" && echo " ... testing for include-directories under /usr"
6880 test -d /usr/include && cf_search="$cf_search /usr/include"
6881 test -d /usr/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/include/$cf_ncuhdr_root"
6882 test -d /usr/include/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/include/$cf_ncuhdr_root/include"
6883 test -d /usr/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/$cf_ncuhdr_root/include"
6884 test -d /usr/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
6887 test "$prefix" != "NONE" && \
6888 test -d "$prefix" && \
6890 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
6891 test -d $prefix/include && cf_search="$cf_search $prefix/include"
6892 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
6893 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
6894 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
6895 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
6898 test "/usr/local" != "$prefix" && \
6899 test -d "/usr/local" && \
6900 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
6901 test -n "$verbose" && echo " ... testing for include-directories under /usr/local"
6902 test -d /usr/local/include && cf_search="$cf_search /usr/local/include"
6903 test -d /usr/local/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/local/include/$cf_ncuhdr_root"
6904 test -d /usr/local/include/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/local/include/$cf_ncuhdr_root/include"
6905 test -d /usr/local/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/local/$cf_ncuhdr_root/include"
6906 test -d /usr/local/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/local/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
6909 test "/opt" != "$prefix" && \
6911 (test $prefix = NONE || test "/opt" != "$prefix") && {
6912 test -n "$verbose" && echo " ... testing for include-directories under /opt"
6913 test -d /opt/include && cf_search="$cf_search /opt/include"
6914 test -d /opt/include/$cf_ncuhdr_root && cf_search="$cf_search /opt/include/$cf_ncuhdr_root"
6915 test -d /opt/include/$cf_ncuhdr_root/include && cf_search="$cf_search /opt/include/$cf_ncuhdr_root/include"
6916 test -d /opt/$cf_ncuhdr_root/include && cf_search="$cf_search /opt/$cf_ncuhdr_root/include"
6917 test -d /opt/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /opt/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
6920 test "$HOME" != "$prefix" && \
6921 test -d "$HOME" && \
6922 (test $prefix = NONE || test "$HOME" != "$prefix") && {
6923 test -n "$verbose" && echo " ... testing for include-directories under $HOME"
6924 test -d $HOME/include && cf_search="$cf_search $HOME/include"
6925 test -d $HOME/include/$cf_ncuhdr_root && cf_search="$cf_search $HOME/include/$cf_ncuhdr_root"
6926 test -d $HOME/include/$cf_ncuhdr_root/include && cf_search="$cf_search $HOME/include/$cf_ncuhdr_root/include"
6927 test -d $HOME/$cf_ncuhdr_root/include && cf_search="$cf_search $HOME/$cf_ncuhdr_root/include"
6928 test -d $HOME/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $HOME/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
6931 test "$includedir" != NONE && \
6932 test "$includedir" != "/usr/include" && \
6933 test -d "$includedir" && {
6934 test -d $includedir && cf_search="$cf_search $includedir"
6935 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
6938 test "$oldincludedir" != NONE && \
6939 test "$oldincludedir" != "/usr/include" && \
6940 test -d "$oldincludedir" && {
6941 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
6942 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
6945 cf_search="$cf_search $cf_header_path_list"
6947 test -n "$verbose" && echo search path $cf_search
6948 cf_save2_CPPFLAGS="$CPPFLAGS"
6949 for cf_incdir in $cf_search
6952 if test -n "$cf_incdir" ; then
6953 for cf_add_incdir in $cf_incdir
6955 while test $cf_add_incdir != /usr/include
6957 if test -d $cf_add_incdir
6960 if test -n "$CFLAGS$CPPFLAGS" ; then
6961 # a loop is needed to ensure we can add subdirs of existing dirs
6962 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
6963 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
6964 cf_have_incdir=yes; break
6969 if test "$cf_have_incdir" = no ; then
6970 if test "$cf_add_incdir" = /usr/local/include ; then
6971 if test "$GCC" = yes
6973 cf_save_CPPFLAGS=$CPPFLAGS
6974 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6975 cat >conftest.$ac_ext <<_ACEOF
6976 #line 6976 "configure"
6977 #include "confdefs.h"
6987 rm -f conftest.$ac_objext
6988 if { (eval echo "$as_me:6988: \"$ac_compile\"") >&5
6989 (eval $ac_compile) 2>&5
6991 echo "$as_me:6991: \$? = $ac_status" >&5
6992 (exit $ac_status); } &&
6993 { ac_try='test -s conftest.$ac_objext'
6994 { (eval echo "$as_me:6994: \"$ac_try\"") >&5
6997 echo "$as_me:6997: \$? = $ac_status" >&5
6998 (exit $ac_status); }; }; then
7001 echo "$as_me: failed program was:" >&5
7002 cat conftest.$ac_ext >&5
7005 rm -f conftest.$ac_objext conftest.$ac_ext
7006 CPPFLAGS=$cf_save_CPPFLAGS
7011 if test "$cf_have_incdir" = no ; then
7012 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
7014 echo "${as_me:-configure}:7014: testing adding $cf_add_incdir to include-path ..." 1>&5
7016 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7018 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
7019 test "$cf_top_incdir" = "$cf_add_incdir" && break
7020 cf_add_incdir="$cf_top_incdir"
7034 cat >conftest.$ac_ext <<_ACEOF
7035 #line 7035 "configure"
7036 #include "confdefs.h"
7038 #include <$cf_header>
7043 #ifdef NCURSES_VERSION
7045 printf("%s\n", NCURSES_VERSION);
7058 rm -f conftest.$ac_objext
7059 if { (eval echo "$as_me:7059: \"$ac_compile\"") >&5
7060 (eval $ac_compile) 2>&5
7062 echo "$as_me:7062: \$? = $ac_status" >&5
7063 (exit $ac_status); } &&
7064 { ac_try='test -s conftest.$ac_objext'
7065 { (eval echo "$as_me:7065: \"$ac_try\"") >&5
7068 echo "$as_me:7068: \$? = $ac_status" >&5
7069 (exit $ac_status); }; }; then
7070 cf_cv_ncurses_h2=$cf_header
7073 echo "$as_me: failed program was:" >&5
7074 cat conftest.$ac_ext >&5
7077 rm -f conftest.$ac_objext conftest.$ac_ext
7079 if test "$cf_cv_ncurses_h2" != no ; then
7080 cf_cv_ncurses_h2=$cf_incdir/$cf_header
7081 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
7084 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
7086 CPPFLAGS="$cf_save2_CPPFLAGS"
7087 test "$cf_cv_ncurses_h2" != no && break
7089 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:7089: error: not found" >&5
7090 echo "$as_me: error: not found" >&2;}
7091 { (exit 1); exit 1; }; }
7094 echo "$as_me:7094: result: $cf_cv_ncurses_h2" >&5
7095 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
7097 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
7098 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
7099 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
7100 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
7103 if test -n "$cf_1st_incdir" ; then
7104 for cf_add_incdir in $cf_1st_incdir
7106 while test $cf_add_incdir != /usr/include
7108 if test -d $cf_add_incdir
7111 if test -n "$CFLAGS$CPPFLAGS" ; then
7112 # a loop is needed to ensure we can add subdirs of existing dirs
7113 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
7114 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
7115 cf_have_incdir=yes; break
7120 if test "$cf_have_incdir" = no ; then
7121 if test "$cf_add_incdir" = /usr/local/include ; then
7122 if test "$GCC" = yes
7124 cf_save_CPPFLAGS=$CPPFLAGS
7125 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7126 cat >conftest.$ac_ext <<_ACEOF
7127 #line 7127 "configure"
7128 #include "confdefs.h"
7138 rm -f conftest.$ac_objext
7139 if { (eval echo "$as_me:7139: \"$ac_compile\"") >&5
7140 (eval $ac_compile) 2>&5
7142 echo "$as_me:7142: \$? = $ac_status" >&5
7143 (exit $ac_status); } &&
7144 { ac_try='test -s conftest.$ac_objext'
7145 { (eval echo "$as_me:7145: \"$ac_try\"") >&5
7148 echo "$as_me:7148: \$? = $ac_status" >&5
7149 (exit $ac_status); }; }; then
7152 echo "$as_me: failed program was:" >&5
7153 cat conftest.$ac_ext >&5
7156 rm -f conftest.$ac_objext conftest.$ac_ext
7157 CPPFLAGS=$cf_save_CPPFLAGS
7162 if test "$cf_have_incdir" = no ; then
7163 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
7165 echo "${as_me:-configure}:7165: testing adding $cf_add_incdir to include-path ..." 1>&5
7167 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7169 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
7170 test "$cf_top_incdir" = "$cf_add_incdir" && break
7171 cf_add_incdir="$cf_top_incdir"
7182 # Set definitions to allow ifdef'ing for ncurses.h
7184 case $cf_cv_ncurses_header in # (vi
7186 cat >>confdefs.h <<\EOF
7187 #define HAVE_NCURSES_H 1
7193 case $cf_cv_ncurses_header in # (vi
7194 ncurses/curses.h|ncurses/ncurses.h)
7195 cat >>confdefs.h <<\EOF
7196 #define HAVE_NCURSES_NCURSES_H 1
7200 ncursesw/curses.h|ncursesw/ncurses.h)
7201 cat >>confdefs.h <<\EOF
7202 #define HAVE_NCURSESW_NCURSES_H 1
7208 echo "$as_me:7208: checking for terminfo header" >&5
7209 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
7210 if test "${cf_cv_term_header+set}" = set; then
7211 echo $ECHO_N "(cached) $ECHO_C" >&6
7214 case ${cf_cv_ncurses_header} in #(vi
7215 */ncurses.h|*/ncursesw.h) #(vi
7216 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
7219 cf_term_header=term.h
7223 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
7225 cat >conftest.$ac_ext <<_ACEOF
7226 #line 7226 "configure"
7227 #include "confdefs.h"
7229 #include <${cf_cv_ncurses_header:-curses.h}>
7235 int x = auto_left_margin
7240 rm -f conftest.$ac_objext
7241 if { (eval echo "$as_me:7241: \"$ac_compile\"") >&5
7242 (eval $ac_compile) 2>&5
7244 echo "$as_me:7244: \$? = $ac_status" >&5
7245 (exit $ac_status); } &&
7246 { ac_try='test -s conftest.$ac_objext'
7247 { (eval echo "$as_me:7247: \"$ac_try\"") >&5
7250 echo "$as_me:7250: \$? = $ac_status" >&5
7251 (exit $ac_status); }; }; then
7253 cf_cv_term_header="$cf_test"
7255 echo "$as_me: failed program was:" >&5
7256 cat conftest.$ac_ext >&5
7258 cf_cv_term_header=unknown
7261 rm -f conftest.$ac_objext conftest.$ac_ext
7262 test "$cf_cv_term_header" != unknown && break
7266 echo "$as_me:7266: result: $cf_cv_term_header" >&5
7267 echo "${ECHO_T}$cf_cv_term_header" >&6
7269 # Set definitions to allow ifdef'ing to accommodate subdirectories
7271 case $cf_cv_term_header in # (vi
7273 cat >>confdefs.h <<\EOF
7274 #define HAVE_TERM_H 1
7280 case $cf_cv_term_header in # (vi
7281 ncurses/term.h) #(vi
7282 cat >>confdefs.h <<\EOF
7283 #define HAVE_NCURSES_TERM_H 1
7288 cat >>confdefs.h <<\EOF
7289 #define HAVE_NCURSESW_TERM_H 1
7295 # some applications need this, but should check for NCURSES_VERSION
7296 cat >>confdefs.h <<\EOF
7300 echo "$as_me:7300: checking for ncurses version" >&5
7301 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
7302 if test "${cf_cv_ncurses_version+set}" = set; then
7303 echo $ECHO_N "(cached) $ECHO_C" >&6
7306 cf_cv_ncurses_version=no
7309 if test "$cross_compiling" = yes; then
7311 # This will not work if the preprocessor splits the line after the
7312 # Autoconf token. The 'unproto' program does that.
7313 cat > conftest.$ac_ext <<EOF
7314 #include <${cf_cv_ncurses_header:-curses.h}>
7316 #ifdef NCURSES_VERSION
7317 Autoconf NCURSES_VERSION
7325 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
7326 { (eval echo "$as_me:7326: \"$cf_try\"") >&5
7329 echo "$as_me:7329: \$? = $ac_status" >&5
7330 (exit $ac_status); }
7331 if test -f conftest.out ; then
7332 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
7333 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
7338 cat >conftest.$ac_ext <<_ACEOF
7339 #line 7339 "configure"
7340 #include "confdefs.h"
7342 #include <${cf_cv_ncurses_header:-curses.h}>
7346 FILE *fp = fopen("$cf_tempfile", "w");
7347 #ifdef NCURSES_VERSION
7348 # ifdef NCURSES_VERSION_PATCH
7349 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
7351 fprintf(fp, "%s\n", NCURSES_VERSION);
7355 fprintf(fp, "old\n");
7360 ${cf_cv_main_return:-return}(0);
7363 rm -f conftest$ac_exeext
7364 if { (eval echo "$as_me:7364: \"$ac_link\"") >&5
7365 (eval $ac_link) 2>&5
7367 echo "$as_me:7367: \$? = $ac_status" >&5
7368 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
7369 { (eval echo "$as_me:7369: \"$ac_try\"") >&5
7372 echo "$as_me:7372: \$? = $ac_status" >&5
7373 (exit $ac_status); }; }; then
7375 cf_cv_ncurses_version=`cat $cf_tempfile`
7377 echo "$as_me: program exited with status $ac_status" >&5
7378 echo "$as_me: failed program was:" >&5
7379 cat conftest.$ac_ext >&5
7381 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
7386 echo "$as_me:7386: result: $cf_cv_ncurses_version" >&5
7387 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
7388 test "$cf_cv_ncurses_version" = no || cat >>confdefs.h <<\EOF
7392 cf_nculib_root=ncurses
7393 # This works, except for the special case where we find gpm, but
7394 # ncurses is in a nonstandard location via $LIBS, and we really want
7397 cf_ncurses_SAVE="$LIBS"
7398 echo "$as_me:7398: checking for Gpm_Open in -lgpm" >&5
7399 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
7400 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
7401 echo $ECHO_N "(cached) $ECHO_C" >&6
7403 ac_check_lib_save_LIBS=$LIBS
7405 cat >conftest.$ac_ext <<_ACEOF
7406 #line 7406 "configure"
7407 #include "confdefs.h"
7409 /* Override any gcc2 internal prototype to avoid an error. */
7413 /* We use char because int might match the return type of a gcc2
7414 builtin and then its argument prototype would still apply. */
7424 rm -f conftest.$ac_objext conftest$ac_exeext
7425 if { (eval echo "$as_me:7425: \"$ac_link\"") >&5
7426 (eval $ac_link) 2>&5
7428 echo "$as_me:7428: \$? = $ac_status" >&5
7429 (exit $ac_status); } &&
7430 { ac_try='test -s conftest$ac_exeext'
7431 { (eval echo "$as_me:7431: \"$ac_try\"") >&5
7434 echo "$as_me:7434: \$? = $ac_status" >&5
7435 (exit $ac_status); }; }; then
7436 ac_cv_lib_gpm_Gpm_Open=yes
7438 echo "$as_me: failed program was:" >&5
7439 cat conftest.$ac_ext >&5
7440 ac_cv_lib_gpm_Gpm_Open=no
7442 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7443 LIBS=$ac_check_lib_save_LIBS
7445 echo "$as_me:7445: result: $ac_cv_lib_gpm_Gpm_Open" >&5
7446 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
7447 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
7448 echo "$as_me:7448: checking for initscr in -lgpm" >&5
7449 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
7450 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
7451 echo $ECHO_N "(cached) $ECHO_C" >&6
7453 ac_check_lib_save_LIBS=$LIBS
7455 cat >conftest.$ac_ext <<_ACEOF
7456 #line 7456 "configure"
7457 #include "confdefs.h"
7459 /* Override any gcc2 internal prototype to avoid an error. */
7463 /* We use char because int might match the return type of a gcc2
7464 builtin and then its argument prototype would still apply. */
7474 rm -f conftest.$ac_objext conftest$ac_exeext
7475 if { (eval echo "$as_me:7475: \"$ac_link\"") >&5
7476 (eval $ac_link) 2>&5
7478 echo "$as_me:7478: \$? = $ac_status" >&5
7479 (exit $ac_status); } &&
7480 { ac_try='test -s conftest$ac_exeext'
7481 { (eval echo "$as_me:7481: \"$ac_try\"") >&5
7484 echo "$as_me:7484: \$? = $ac_status" >&5
7485 (exit $ac_status); }; }; then
7486 ac_cv_lib_gpm_initscr=yes
7488 echo "$as_me: failed program was:" >&5
7489 cat conftest.$ac_ext >&5
7490 ac_cv_lib_gpm_initscr=no
7492 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7493 LIBS=$ac_check_lib_save_LIBS
7495 echo "$as_me:7495: result: $ac_cv_lib_gpm_initscr" >&5
7496 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
7497 if test $ac_cv_lib_gpm_initscr = yes; then
7498 LIBS="$cf_ncurses_SAVE"
7500 cf_ncurses_LIBS="-lgpm"
7505 case $host_os in #(vi
7507 # This is only necessary if you are linking against an obsolete
7508 # version of ncurses (but it should do no harm, since it's static).
7509 if test "$cf_nculib_root" = ncurses ; then
7510 echo "$as_me:7510: checking for tgoto in -lmytinfo" >&5
7511 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
7512 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
7513 echo $ECHO_N "(cached) $ECHO_C" >&6
7515 ac_check_lib_save_LIBS=$LIBS
7516 LIBS="-lmytinfo $LIBS"
7517 cat >conftest.$ac_ext <<_ACEOF
7518 #line 7518 "configure"
7519 #include "confdefs.h"
7521 /* Override any gcc2 internal prototype to avoid an error. */
7525 /* We use char because int might match the return type of a gcc2
7526 builtin and then its argument prototype would still apply. */
7536 rm -f conftest.$ac_objext conftest$ac_exeext
7537 if { (eval echo "$as_me:7537: \"$ac_link\"") >&5
7538 (eval $ac_link) 2>&5
7540 echo "$as_me:7540: \$? = $ac_status" >&5
7541 (exit $ac_status); } &&
7542 { ac_try='test -s conftest$ac_exeext'
7543 { (eval echo "$as_me:7543: \"$ac_try\"") >&5
7546 echo "$as_me:7546: \$? = $ac_status" >&5
7547 (exit $ac_status); }; }; then
7548 ac_cv_lib_mytinfo_tgoto=yes
7550 echo "$as_me: failed program was:" >&5
7551 cat conftest.$ac_ext >&5
7552 ac_cv_lib_mytinfo_tgoto=no
7554 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7555 LIBS=$ac_check_lib_save_LIBS
7557 echo "$as_me:7557: result: $ac_cv_lib_mytinfo_tgoto" >&5
7558 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
7559 if test $ac_cv_lib_mytinfo_tgoto = yes; then
7560 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
7567 LIBS="$cf_ncurses_LIBS $LIBS"
7569 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
7571 LIBS="-l$cf_nculib_root $LIBS"
7574 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
7576 echo "$as_me:7576: checking for initscr" >&5
7577 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
7578 if test "${ac_cv_func_initscr+set}" = set; then
7579 echo $ECHO_N "(cached) $ECHO_C" >&6
7581 cat >conftest.$ac_ext <<_ACEOF
7582 #line 7582 "configure"
7583 #include "confdefs.h"
7584 /* System header to define __stub macros and hopefully few prototypes,
7585 which can conflict with char initscr (); below. */
7587 /* Override any gcc2 internal prototype to avoid an error. */
7591 /* We use char because int might match the return type of a gcc2
7592 builtin and then its argument prototype would still apply. */
7599 /* The GNU C library defines this for functions which it implements
7600 to always fail with ENOSYS. Some functions are actually named
7601 something starting with __ and the normal name is an alias. */
7602 #if defined (__stub_initscr) || defined (__stub___initscr)
7612 rm -f conftest.$ac_objext conftest$ac_exeext
7613 if { (eval echo "$as_me:7613: \"$ac_link\"") >&5
7614 (eval $ac_link) 2>&5
7616 echo "$as_me:7616: \$? = $ac_status" >&5
7617 (exit $ac_status); } &&
7618 { ac_try='test -s conftest$ac_exeext'
7619 { (eval echo "$as_me:7619: \"$ac_try\"") >&5
7622 echo "$as_me:7622: \$? = $ac_status" >&5
7623 (exit $ac_status); }; }; then
7624 ac_cv_func_initscr=yes
7626 echo "$as_me: failed program was:" >&5
7627 cat conftest.$ac_ext >&5
7628 ac_cv_func_initscr=no
7630 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7632 echo "$as_me:7632: result: $ac_cv_func_initscr" >&5
7633 echo "${ECHO_T}$ac_cv_func_initscr" >&6
7634 if test $ac_cv_func_initscr = yes; then
7635 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
7638 cf_save_LIBS="$LIBS"
7639 echo "$as_me:7639: checking for initscr in -l$cf_nculib_root" >&5
7640 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
7641 LIBS="-l$cf_nculib_root $LIBS"
7642 cat >conftest.$ac_ext <<_ACEOF
7643 #line 7643 "configure"
7644 #include "confdefs.h"
7645 #include <${cf_cv_ncurses_header:-curses.h}>
7654 rm -f conftest.$ac_objext conftest$ac_exeext
7655 if { (eval echo "$as_me:7655: \"$ac_link\"") >&5
7656 (eval $ac_link) 2>&5
7658 echo "$as_me:7658: \$? = $ac_status" >&5
7659 (exit $ac_status); } &&
7660 { ac_try='test -s conftest$ac_exeext'
7661 { (eval echo "$as_me:7661: \"$ac_try\"") >&5
7664 echo "$as_me:7664: \$? = $ac_status" >&5
7665 (exit $ac_status); }; }; then
7666 echo "$as_me:7666: result: yes" >&5
7667 echo "${ECHO_T}yes" >&6
7668 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
7671 echo "$as_me: failed program was:" >&5
7672 cat conftest.$ac_ext >&5
7673 echo "$as_me:7673: result: no" >&5
7674 echo "${ECHO_T}no" >&6
7677 cf_library_path_list=""
7678 if test -n "${LDFLAGS}${LIBS}" ; then
7679 for cf_library_path in $LDFLAGS $LIBS
7681 case $cf_library_path in #(vi
7683 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
7685 test "$cf_library_path" != "NONE" && \
7686 test -d "$cf_library_path" && \
7688 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
7689 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
7690 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
7691 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
7692 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
7693 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"
7696 cf_library_path_list="$cf_library_path_list $cf_search"
7704 test "/usr" != "$prefix" && \
7706 (test $prefix = NONE || test "/usr" != "$prefix") && {
7707 test -n "$verbose" && echo " ... testing for lib-directories under /usr"
7708 test -d /usr/lib && cf_search="$cf_search /usr/lib"
7709 test -d /usr/lib/$cf_nculib_root && cf_search="$cf_search /usr/lib/$cf_nculib_root"
7710 test -d /usr/lib/$cf_nculib_root/lib && cf_search="$cf_search /usr/lib/$cf_nculib_root/lib"
7711 test -d /usr/$cf_nculib_root/lib && cf_search="$cf_search /usr/$cf_nculib_root/lib"
7712 test -d /usr/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /usr/$cf_nculib_root/lib/$cf_nculib_root"
7715 test "$prefix" != "NONE" && \
7716 test -d "$prefix" && \
7718 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
7719 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
7720 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
7721 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
7722 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
7723 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
7726 test "/usr/local" != "$prefix" && \
7727 test -d "/usr/local" && \
7728 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
7729 test -n "$verbose" && echo " ... testing for lib-directories under /usr/local"
7730 test -d /usr/local/lib && cf_search="$cf_search /usr/local/lib"
7731 test -d /usr/local/lib/$cf_nculib_root && cf_search="$cf_search /usr/local/lib/$cf_nculib_root"
7732 test -d /usr/local/lib/$cf_nculib_root/lib && cf_search="$cf_search /usr/local/lib/$cf_nculib_root/lib"
7733 test -d /usr/local/$cf_nculib_root/lib && cf_search="$cf_search /usr/local/$cf_nculib_root/lib"
7734 test -d /usr/local/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /usr/local/$cf_nculib_root/lib/$cf_nculib_root"
7737 test "/opt" != "$prefix" && \
7739 (test $prefix = NONE || test "/opt" != "$prefix") && {
7740 test -n "$verbose" && echo " ... testing for lib-directories under /opt"
7741 test -d /opt/lib && cf_search="$cf_search /opt/lib"
7742 test -d /opt/lib/$cf_nculib_root && cf_search="$cf_search /opt/lib/$cf_nculib_root"
7743 test -d /opt/lib/$cf_nculib_root/lib && cf_search="$cf_search /opt/lib/$cf_nculib_root/lib"
7744 test -d /opt/$cf_nculib_root/lib && cf_search="$cf_search /opt/$cf_nculib_root/lib"
7745 test -d /opt/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /opt/$cf_nculib_root/lib/$cf_nculib_root"
7748 test "$HOME" != "$prefix" && \
7749 test -d "$HOME" && \
7750 (test $prefix = NONE || test "$HOME" != "$prefix") && {
7751 test -n "$verbose" && echo " ... testing for lib-directories under $HOME"
7752 test -d $HOME/lib && cf_search="$cf_search $HOME/lib"
7753 test -d $HOME/lib/$cf_nculib_root && cf_search="$cf_search $HOME/lib/$cf_nculib_root"
7754 test -d $HOME/lib/$cf_nculib_root/lib && cf_search="$cf_search $HOME/lib/$cf_nculib_root/lib"
7755 test -d $HOME/$cf_nculib_root/lib && cf_search="$cf_search $HOME/$cf_nculib_root/lib"
7756 test -d $HOME/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $HOME/$cf_nculib_root/lib/$cf_nculib_root"
7759 cf_search="$cf_library_path_list $cf_search"
7761 for cf_libdir in $cf_search
7763 echo "$as_me:7763: checking for -l$cf_nculib_root in $cf_libdir" >&5
7764 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
7765 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
7766 cat >conftest.$ac_ext <<_ACEOF
7767 #line 7767 "configure"
7768 #include "confdefs.h"
7769 #include <${cf_cv_ncurses_header:-curses.h}>
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
7792 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
7795 echo "$as_me: failed program was:" >&5
7796 cat conftest.$ac_ext >&5
7797 echo "$as_me:7797: result: no" >&5
7798 echo "${ECHO_T}no" >&6
7799 LIBS="$cf_save_LIBS"
7801 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7805 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7809 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
7811 if test $cf_found_library = no ; then
7812 { { echo "$as_me:7812: error: Cannot link $cf_nculib_root library" >&5
7813 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
7814 { (exit 1); exit 1; }; }
7819 if test -n "$cf_ncurses_LIBS" ; then
7820 echo "$as_me:7820: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
7821 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
7822 cf_ncurses_SAVE="$LIBS"
7823 for p in $cf_ncurses_LIBS ; do
7824 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
7825 if test "$q" != "$LIBS" ; then
7829 cat >conftest.$ac_ext <<_ACEOF
7830 #line 7830 "configure"
7831 #include "confdefs.h"
7832 #include <${cf_cv_ncurses_header:-curses.h}>
7836 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
7841 rm -f conftest.$ac_objext conftest$ac_exeext
7842 if { (eval echo "$as_me:7842: \"$ac_link\"") >&5
7843 (eval $ac_link) 2>&5
7845 echo "$as_me:7845: \$? = $ac_status" >&5
7846 (exit $ac_status); } &&
7847 { ac_try='test -s conftest$ac_exeext'
7848 { (eval echo "$as_me:7848: \"$ac_try\"") >&5
7851 echo "$as_me:7851: \$? = $ac_status" >&5
7852 (exit $ac_status); }; }; then
7853 echo "$as_me:7853: result: yes" >&5
7854 echo "${ECHO_T}yes" >&6
7856 echo "$as_me: failed program was:" >&5
7857 cat conftest.$ac_ext >&5
7858 echo "$as_me:7858: result: no" >&5
7859 echo "${ECHO_T}no" >&6
7860 LIBS="$cf_ncurses_SAVE"
7862 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7865 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
7867 cat >>confdefs.h <<EOF
7868 #define $cf_nculib_ROOT 1
7877 echo "$as_me:7877: checking for multibyte character support" >&5
7878 echo $ECHO_N "checking for multibyte character support... $ECHO_C" >&6
7879 if test "${cf_cv_utf8_lib+set}" = set; then
7880 echo $ECHO_N "(cached) $ECHO_C" >&6
7883 cf_save_LIBS="$LIBS"
7884 cat >conftest.$ac_ext <<_ACEOF
7885 #line 7885 "configure"
7886 #include "confdefs.h"
7897 rm -f conftest.$ac_objext conftest$ac_exeext
7898 if { (eval echo "$as_me:7898: \"$ac_link\"") >&5
7899 (eval $ac_link) 2>&5
7901 echo "$as_me:7901: \$? = $ac_status" >&5
7902 (exit $ac_status); } &&
7903 { ac_try='test -s conftest$ac_exeext'
7904 { (eval echo "$as_me:7904: \"$ac_try\"") >&5
7907 echo "$as_me:7907: \$? = $ac_status" >&5
7908 (exit $ac_status); }; }; then
7911 echo "$as_me: failed program was:" >&5
7912 cat conftest.$ac_ext >&5
7914 # If the linkage is not already in the $CPPFLAGS/$LDFLAGS configuration, these
7915 # will be set on completion of the AC_TRY_LINK below.
7916 cf_cv_header_path_utf8=
7917 cf_cv_library_path_utf8=
7919 echo "${as_me:-configure}:7919: testing Starting FIND_LINKAGE(utf8,) ..." 1>&5
7921 cf_save_LIBS="$LIBS"
7923 cat >conftest.$ac_ext <<_ACEOF
7924 #line 7924 "configure"
7925 #include "confdefs.h"
7927 #include <libutf8.h>
7936 rm -f conftest.$ac_objext conftest$ac_exeext
7937 if { (eval echo "$as_me:7937: \"$ac_link\"") >&5
7938 (eval $ac_link) 2>&5
7940 echo "$as_me:7940: \$? = $ac_status" >&5
7941 (exit $ac_status); } &&
7942 { ac_try='test -s conftest$ac_exeext'
7943 { (eval echo "$as_me:7943: \"$ac_try\"") >&5
7946 echo "$as_me:7946: \$? = $ac_status" >&5
7947 (exit $ac_status); }; }; then
7949 cf_cv_find_linkage_utf8=yes
7950 cf_cv_header_path_utf8=/usr/include
7951 cf_cv_library_path_utf8=/usr/lib
7954 echo "$as_me: failed program was:" >&5
7955 cat conftest.$ac_ext >&5
7957 LIBS="-lutf8 $cf_save_LIBS"
7959 cat >conftest.$ac_ext <<_ACEOF
7960 #line 7960 "configure"
7961 #include "confdefs.h"
7963 #include <libutf8.h>
7972 rm -f conftest.$ac_objext conftest$ac_exeext
7973 if { (eval echo "$as_me:7973: \"$ac_link\"") >&5
7974 (eval $ac_link) 2>&5
7976 echo "$as_me:7976: \$? = $ac_status" >&5
7977 (exit $ac_status); } &&
7978 { ac_try='test -s conftest$ac_exeext'
7979 { (eval echo "$as_me:7979: \"$ac_try\"") >&5
7982 echo "$as_me:7982: \$? = $ac_status" >&5
7983 (exit $ac_status); }; }; then
7985 cf_cv_find_linkage_utf8=yes
7986 cf_cv_header_path_utf8=/usr/include
7987 cf_cv_library_path_utf8=/usr/lib
7988 cf_cv_library_file_utf8="-lutf8"
7991 echo "$as_me: failed program was:" >&5
7992 cat conftest.$ac_ext >&5
7994 cf_cv_find_linkage_utf8=no
7995 LIBS="$cf_save_LIBS"
7997 test -n "$verbose" && echo " find linkage for utf8 library" 1>&6
7999 echo "${as_me:-configure}:7999: testing find linkage for utf8 library ..." 1>&5
8001 echo "${as_me:-configure}:8001: testing Searching for headers in FIND_LINKAGE(utf8,) ..." 1>&5
8003 cf_save_CPPFLAGS="$CPPFLAGS"
8004 cf_test_CPPFLAGS="$CPPFLAGS"
8008 # collect the current set of include-directories from compiler flags
8009 cf_header_path_list=""
8010 if test -n "${CFLAGS}${CPPFLAGS}" ; then
8011 for cf_header_path in $CPPFLAGS $CFLAGS
8013 case $cf_header_path in #(vi
8015 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
8017 test "$cf_header_path" != "NONE" && \
8018 test -d "$cf_header_path" && \
8020 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
8021 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
8022 test -d $cf_header_path/include/utf8 && cf_search="$cf_search $cf_header_path/include/utf8"
8023 test -d $cf_header_path/include/utf8/include && cf_search="$cf_search $cf_header_path/include/utf8/include"
8024 test -d $cf_header_path/utf8/include && cf_search="$cf_search $cf_header_path/utf8/include"
8025 test -d $cf_header_path/utf8/include/utf8 && cf_search="$cf_search $cf_header_path/utf8/include/utf8"
8028 cf_header_path_list="$cf_header_path_list $cf_search"
8034 # add the variations for the package we are looking for
8038 test "/usr" != "$prefix" && \
8040 (test $prefix = NONE || test "/usr" != "$prefix") && {
8041 test -n "$verbose" && echo " ... testing for include-directories under /usr"
8042 test -d /usr/include && cf_search="$cf_search /usr/include"
8043 test -d /usr/include/utf8 && cf_search="$cf_search /usr/include/utf8"
8044 test -d /usr/include/utf8/include && cf_search="$cf_search /usr/include/utf8/include"
8045 test -d /usr/utf8/include && cf_search="$cf_search /usr/utf8/include"
8046 test -d /usr/utf8/include/utf8 && cf_search="$cf_search /usr/utf8/include/utf8"
8049 test "$prefix" != "NONE" && \
8050 test -d "$prefix" && \
8052 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
8053 test -d $prefix/include && cf_search="$cf_search $prefix/include"
8054 test -d $prefix/include/utf8 && cf_search="$cf_search $prefix/include/utf8"
8055 test -d $prefix/include/utf8/include && cf_search="$cf_search $prefix/include/utf8/include"
8056 test -d $prefix/utf8/include && cf_search="$cf_search $prefix/utf8/include"
8057 test -d $prefix/utf8/include/utf8 && cf_search="$cf_search $prefix/utf8/include/utf8"
8060 test "/usr/local" != "$prefix" && \
8061 test -d "/usr/local" && \
8062 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
8063 test -n "$verbose" && echo " ... testing for include-directories under /usr/local"
8064 test -d /usr/local/include && cf_search="$cf_search /usr/local/include"
8065 test -d /usr/local/include/utf8 && cf_search="$cf_search /usr/local/include/utf8"
8066 test -d /usr/local/include/utf8/include && cf_search="$cf_search /usr/local/include/utf8/include"
8067 test -d /usr/local/utf8/include && cf_search="$cf_search /usr/local/utf8/include"
8068 test -d /usr/local/utf8/include/utf8 && cf_search="$cf_search /usr/local/utf8/include/utf8"
8071 test "/opt" != "$prefix" && \
8073 (test $prefix = NONE || test "/opt" != "$prefix") && {
8074 test -n "$verbose" && echo " ... testing for include-directories under /opt"
8075 test -d /opt/include && cf_search="$cf_search /opt/include"
8076 test -d /opt/include/utf8 && cf_search="$cf_search /opt/include/utf8"
8077 test -d /opt/include/utf8/include && cf_search="$cf_search /opt/include/utf8/include"
8078 test -d /opt/utf8/include && cf_search="$cf_search /opt/utf8/include"
8079 test -d /opt/utf8/include/utf8 && cf_search="$cf_search /opt/utf8/include/utf8"
8082 test "$HOME" != "$prefix" && \
8083 test -d "$HOME" && \
8084 (test $prefix = NONE || test "$HOME" != "$prefix") && {
8085 test -n "$verbose" && echo " ... testing for include-directories under $HOME"
8086 test -d $HOME/include && cf_search="$cf_search $HOME/include"
8087 test -d $HOME/include/utf8 && cf_search="$cf_search $HOME/include/utf8"
8088 test -d $HOME/include/utf8/include && cf_search="$cf_search $HOME/include/utf8/include"
8089 test -d $HOME/utf8/include && cf_search="$cf_search $HOME/utf8/include"
8090 test -d $HOME/utf8/include/utf8 && cf_search="$cf_search $HOME/utf8/include/utf8"
8093 test "$includedir" != NONE && \
8094 test "$includedir" != "/usr/include" && \
8095 test -d "$includedir" && {
8096 test -d $includedir && cf_search="$cf_search $includedir"
8097 test -d $includedir/utf8 && cf_search="$cf_search $includedir/utf8"
8100 test "$oldincludedir" != NONE && \
8101 test "$oldincludedir" != "/usr/include" && \
8102 test -d "$oldincludedir" && {
8103 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
8104 test -d $oldincludedir/utf8 && cf_search="$cf_search $oldincludedir/utf8"
8107 cf_search="$cf_search $cf_header_path_list"
8109 for cf_cv_header_path_utf8 in $cf_search
8111 if test -d $cf_cv_header_path_utf8 ; then
8112 test -n "$verbose" && echo " ... testing $cf_cv_header_path_utf8" 1>&6
8114 echo "${as_me:-configure}:8114: testing ... testing $cf_cv_header_path_utf8 ..." 1>&5
8116 CPPFLAGS="$cf_save_CPPFLAGS -I$cf_cv_header_path_utf8"
8117 cat >conftest.$ac_ext <<_ACEOF
8118 #line 8118 "configure"
8119 #include "confdefs.h"
8121 #include <libutf8.h>
8130 rm -f conftest.$ac_objext
8131 if { (eval echo "$as_me:8131: \"$ac_compile\"") >&5
8132 (eval $ac_compile) 2>&5
8134 echo "$as_me:8134: \$? = $ac_status" >&5
8135 (exit $ac_status); } &&
8136 { ac_try='test -s conftest.$ac_objext'
8137 { (eval echo "$as_me:8137: \"$ac_try\"") >&5
8140 echo "$as_me:8140: \$? = $ac_status" >&5
8141 (exit $ac_status); }; }; then
8143 test -n "$verbose" && echo " ... found utf8 headers in $cf_cv_header_path_utf8" 1>&6
8145 echo "${as_me:-configure}:8145: testing ... found utf8 headers in $cf_cv_header_path_utf8 ..." 1>&5
8147 cf_cv_find_linkage_utf8=maybe
8148 cf_test_CPPFLAGS="$CPPFLAGS"
8151 echo "$as_me: failed program was:" >&5
8152 cat conftest.$ac_ext >&5
8154 CPPFLAGS="$cf_save_CPPFLAGS"
8157 rm -f conftest.$ac_objext conftest.$ac_ext
8161 if test "$cf_cv_find_linkage_utf8" = maybe ; then
8163 echo "${as_me:-configure}:8163: testing Searching for utf8 library in FIND_LINKAGE(utf8,) ..." 1>&5
8165 cf_save_LIBS="$LIBS"
8166 cf_save_LDFLAGS="$LDFLAGS"
8168 if test "$cf_cv_find_linkage_utf8" != yes ; then
8171 cf_library_path_list=""
8172 if test -n "${LDFLAGS}${LIBS}" ; then
8173 for cf_library_path in $LDFLAGS $LIBS
8175 case $cf_library_path in #(vi
8177 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
8179 test "$cf_library_path" != "NONE" && \
8180 test -d "$cf_library_path" && \
8182 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
8183 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
8184 test -d $cf_library_path/lib/utf8 && cf_search="$cf_search $cf_library_path/lib/utf8"
8185 test -d $cf_library_path/lib/utf8/lib && cf_search="$cf_search $cf_library_path/lib/utf8/lib"
8186 test -d $cf_library_path/utf8/lib && cf_search="$cf_search $cf_library_path/utf8/lib"
8187 test -d $cf_library_path/utf8/lib/utf8 && cf_search="$cf_search $cf_library_path/utf8/lib/utf8"
8190 cf_library_path_list="$cf_library_path_list $cf_search"
8198 test "/usr" != "$prefix" && \
8200 (test $prefix = NONE || test "/usr" != "$prefix") && {
8201 test -n "$verbose" && echo " ... testing for lib-directories under /usr"
8202 test -d /usr/lib && cf_search="$cf_search /usr/lib"
8203 test -d /usr/lib/utf8 && cf_search="$cf_search /usr/lib/utf8"
8204 test -d /usr/lib/utf8/lib && cf_search="$cf_search /usr/lib/utf8/lib"
8205 test -d /usr/utf8/lib && cf_search="$cf_search /usr/utf8/lib"
8206 test -d /usr/utf8/lib/utf8 && cf_search="$cf_search /usr/utf8/lib/utf8"
8209 test "$prefix" != "NONE" && \
8210 test -d "$prefix" && \
8212 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
8213 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
8214 test -d $prefix/lib/utf8 && cf_search="$cf_search $prefix/lib/utf8"
8215 test -d $prefix/lib/utf8/lib && cf_search="$cf_search $prefix/lib/utf8/lib"
8216 test -d $prefix/utf8/lib && cf_search="$cf_search $prefix/utf8/lib"
8217 test -d $prefix/utf8/lib/utf8 && cf_search="$cf_search $prefix/utf8/lib/utf8"
8220 test "/usr/local" != "$prefix" && \
8221 test -d "/usr/local" && \
8222 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
8223 test -n "$verbose" && echo " ... testing for lib-directories under /usr/local"
8224 test -d /usr/local/lib && cf_search="$cf_search /usr/local/lib"
8225 test -d /usr/local/lib/utf8 && cf_search="$cf_search /usr/local/lib/utf8"
8226 test -d /usr/local/lib/utf8/lib && cf_search="$cf_search /usr/local/lib/utf8/lib"
8227 test -d /usr/local/utf8/lib && cf_search="$cf_search /usr/local/utf8/lib"
8228 test -d /usr/local/utf8/lib/utf8 && cf_search="$cf_search /usr/local/utf8/lib/utf8"
8231 test "/opt" != "$prefix" && \
8233 (test $prefix = NONE || test "/opt" != "$prefix") && {
8234 test -n "$verbose" && echo " ... testing for lib-directories under /opt"
8235 test -d /opt/lib && cf_search="$cf_search /opt/lib"
8236 test -d /opt/lib/utf8 && cf_search="$cf_search /opt/lib/utf8"
8237 test -d /opt/lib/utf8/lib && cf_search="$cf_search /opt/lib/utf8/lib"
8238 test -d /opt/utf8/lib && cf_search="$cf_search /opt/utf8/lib"
8239 test -d /opt/utf8/lib/utf8 && cf_search="$cf_search /opt/utf8/lib/utf8"
8242 test "$HOME" != "$prefix" && \
8243 test -d "$HOME" && \
8244 (test $prefix = NONE || test "$HOME" != "$prefix") && {
8245 test -n "$verbose" && echo " ... testing for lib-directories under $HOME"
8246 test -d $HOME/lib && cf_search="$cf_search $HOME/lib"
8247 test -d $HOME/lib/utf8 && cf_search="$cf_search $HOME/lib/utf8"
8248 test -d $HOME/lib/utf8/lib && cf_search="$cf_search $HOME/lib/utf8/lib"
8249 test -d $HOME/utf8/lib && cf_search="$cf_search $HOME/utf8/lib"
8250 test -d $HOME/utf8/lib/utf8 && cf_search="$cf_search $HOME/utf8/lib/utf8"
8253 cf_search="$cf_library_path_list $cf_search"
8255 for cf_cv_library_path_utf8 in $cf_search
8257 if test -d $cf_cv_library_path_utf8 ; then
8258 test -n "$verbose" && echo " ... testing $cf_cv_library_path_utf8" 1>&6
8260 echo "${as_me:-configure}:8260: testing ... testing $cf_cv_library_path_utf8 ..." 1>&5
8262 CPPFLAGS="$cf_test_CPPFLAGS"
8263 LIBS="-lutf8 $cf_save_LIBS"
8264 LDFLAGS="$cf_save_LDFLAGS -L$cf_cv_library_path_utf8"
8265 cat >conftest.$ac_ext <<_ACEOF
8266 #line 8266 "configure"
8267 #include "confdefs.h"
8269 #include <libutf8.h>
8278 rm -f conftest.$ac_objext conftest$ac_exeext
8279 if { (eval echo "$as_me:8279: \"$ac_link\"") >&5
8280 (eval $ac_link) 2>&5
8282 echo "$as_me:8282: \$? = $ac_status" >&5
8283 (exit $ac_status); } &&
8284 { ac_try='test -s conftest$ac_exeext'
8285 { (eval echo "$as_me:8285: \"$ac_try\"") >&5
8288 echo "$as_me:8288: \$? = $ac_status" >&5
8289 (exit $ac_status); }; }; then
8291 test -n "$verbose" && echo " ... found utf8 library in $cf_cv_library_path_utf8" 1>&6
8293 echo "${as_me:-configure}:8293: testing ... found utf8 library in $cf_cv_library_path_utf8 ..." 1>&5
8295 cf_cv_find_linkage_utf8=yes
8296 cf_cv_library_file_utf8="-lutf8"
8299 echo "$as_me: failed program was:" >&5
8300 cat conftest.$ac_ext >&5
8302 CPPFLAGS="$cf_save_CPPFLAGS"
8303 LIBS="$cf_save_LIBS"
8304 LDFLAGS="$cf_save_LDFLAGS"
8307 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8310 CPPFLAGS="$cf_save_CPPFLAGS"
8311 LDFLAGS="$cf_save_LDFLAGS"
8315 cf_cv_find_linkage_utf8=no
8319 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8322 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8324 LIBS="$cf_save_LIBS"
8326 if test "$cf_cv_find_linkage_utf8" = yes ; then
8327 cf_cv_utf8_lib=add-on
8333 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8335 echo "$as_me:8335: result: $cf_cv_utf8_lib" >&5
8336 echo "${ECHO_T}$cf_cv_utf8_lib" >&6
8338 # HAVE_LIBUTF8_H is used by ncurses if curses.h is shared between
8340 if test "$cf_cv_utf8_lib" = "add-on" ; then
8341 cat >>confdefs.h <<\EOF
8342 #define HAVE_LIBUTF8_H 1
8345 if test -n "$cf_cv_header_path_utf8" ; then
8346 for cf_add_incdir in $cf_cv_header_path_utf8
8348 while test $cf_add_incdir != /usr/include
8350 if test -d $cf_add_incdir
8353 if test -n "$CFLAGS$CPPFLAGS" ; then
8354 # a loop is needed to ensure we can add subdirs of existing dirs
8355 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
8356 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
8357 cf_have_incdir=yes; break
8362 if test "$cf_have_incdir" = no ; then
8363 if test "$cf_add_incdir" = /usr/local/include ; then
8364 if test "$GCC" = yes
8366 cf_save_CPPFLAGS=$CPPFLAGS
8367 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8368 cat >conftest.$ac_ext <<_ACEOF
8369 #line 8369 "configure"
8370 #include "confdefs.h"
8380 rm -f conftest.$ac_objext
8381 if { (eval echo "$as_me:8381: \"$ac_compile\"") >&5
8382 (eval $ac_compile) 2>&5
8384 echo "$as_me:8384: \$? = $ac_status" >&5
8385 (exit $ac_status); } &&
8386 { ac_try='test -s conftest.$ac_objext'
8387 { (eval echo "$as_me:8387: \"$ac_try\"") >&5
8390 echo "$as_me:8390: \$? = $ac_status" >&5
8391 (exit $ac_status); }; }; then
8394 echo "$as_me: failed program was:" >&5
8395 cat conftest.$ac_ext >&5
8398 rm -f conftest.$ac_objext conftest.$ac_ext
8399 CPPFLAGS=$cf_save_CPPFLAGS
8404 if test "$cf_have_incdir" = no ; then
8405 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
8407 echo "${as_me:-configure}:8407: testing adding $cf_add_incdir to include-path ..." 1>&5
8409 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8411 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
8412 test "$cf_top_incdir" = "$cf_add_incdir" && break
8413 cf_add_incdir="$cf_top_incdir"
8422 if test -n "$cf_cv_library_path_utf8" ; then
8423 for cf_add_libdir in $cf_cv_library_path_utf8
8425 if test $cf_add_libdir = /usr/lib ; then
8427 elif test -d $cf_add_libdir
8430 if test -n "$LDFLAGS$LIBS" ; then
8431 # a loop is needed to ensure we can add subdirs of existing dirs
8432 for cf_test_libdir in $LDFLAGS $LIBS ; do
8433 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
8434 cf_have_libdir=yes; break
8438 if test "$cf_have_libdir" = no ; then
8439 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
8441 echo "${as_me:-configure}:8441: testing adding $cf_add_libdir to library-path ..." 1>&5
8443 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
8449 LIBS="$cf_cv_library_file_utf8 $LIBS"
8452 cf_ncuconfig_root=ncursesw
8454 echo "Looking for ${cf_ncuconfig_root}-config"
8455 for ac_prog in ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
8457 # Extract the first word of "$ac_prog", so it can be a program name with args.
8458 set dummy $ac_prog; ac_word=$2
8459 echo "$as_me:8459: checking for $ac_word" >&5
8460 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
8461 if test "${ac_cv_path_NCURSES_CONFIG+set}" = set; then
8462 echo $ECHO_N "(cached) $ECHO_C" >&6
8464 case $NCURSES_CONFIG in
8466 ac_cv_path_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test with a path.
8469 ac_save_IFS=$IFS; IFS=$ac_path_separator
8471 for ac_dir in $ac_dummy; do
8473 test -z "$ac_dir" && ac_dir=.
8474 if $as_executable_p "$ac_dir/$ac_word"; then
8475 ac_cv_path_NCURSES_CONFIG="$ac_dir/$ac_word"
8476 echo "$as_me:8476: found $ac_dir/$ac_word" >&5
8484 NCURSES_CONFIG=$ac_cv_path_NCURSES_CONFIG
8486 if test -n "$NCURSES_CONFIG"; then
8487 echo "$as_me:8487: result: $NCURSES_CONFIG" >&5
8488 echo "${ECHO_T}$NCURSES_CONFIG" >&6
8490 echo "$as_me:8490: result: no" >&5
8491 echo "${ECHO_T}no" >&6
8494 test -n "$NCURSES_CONFIG" && break
8496 test -n "$NCURSES_CONFIG" || NCURSES_CONFIG="none"
8498 if test "$NCURSES_CONFIG" != none ; then
8500 CPPFLAGS="$CPPFLAGS `$NCURSES_CONFIG --cflags`"
8501 LIBS="`$NCURSES_CONFIG --libs` $LIBS"
8503 # even with config script, some packages use no-override for curses.h
8505 echo "$as_me:8505: checking if we have identified curses headers" >&5
8506 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
8507 if test "${cf_cv_ncurses_header+set}" = set; then
8508 echo $ECHO_N "(cached) $ECHO_C" >&6
8511 cf_cv_ncurses_header=none
8513 ncursesw/ncurses.h \
8518 cat >conftest.$ac_ext <<_ACEOF
8519 #line 8519 "configure"
8520 #include "confdefs.h"
8521 #include <${cf_header}>
8525 initscr(); tgoto("?", 0,0)
8530 rm -f conftest.$ac_objext
8531 if { (eval echo "$as_me:8531: \"$ac_compile\"") >&5
8532 (eval $ac_compile) 2>&5
8534 echo "$as_me:8534: \$? = $ac_status" >&5
8535 (exit $ac_status); } &&
8536 { ac_try='test -s conftest.$ac_objext'
8537 { (eval echo "$as_me:8537: \"$ac_try\"") >&5
8540 echo "$as_me:8540: \$? = $ac_status" >&5
8541 (exit $ac_status); }; }; then
8542 cf_cv_ncurses_header=$cf_header; break
8544 echo "$as_me: failed program was:" >&5
8545 cat conftest.$ac_ext >&5
8547 rm -f conftest.$ac_objext conftest.$ac_ext
8551 echo "$as_me:8551: result: $cf_cv_ncurses_header" >&5
8552 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
8554 if test "$cf_cv_ncurses_header" = none ; then
8555 { { echo "$as_me:8555: error: No curses header-files found" >&5
8556 echo "$as_me: error: No curses header-files found" >&2;}
8557 { (exit 1); exit 1; }; }
8560 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
8562 for ac_header in $cf_cv_ncurses_header
8564 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8565 echo "$as_me:8565: checking for $ac_header" >&5
8566 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8567 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8568 echo $ECHO_N "(cached) $ECHO_C" >&6
8570 cat >conftest.$ac_ext <<_ACEOF
8571 #line 8571 "configure"
8572 #include "confdefs.h"
8573 #include <$ac_header>
8575 if { (eval echo "$as_me:8575: \"$ac_cpp conftest.$ac_ext\"") >&5
8576 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8578 egrep -v '^ *\+' conftest.er1 >conftest.err
8580 cat conftest.err >&5
8581 echo "$as_me:8581: \$? = $ac_status" >&5
8582 (exit $ac_status); } >/dev/null; then
8583 if test -s conftest.err; then
8584 ac_cpp_err=$ac_c_preproc_warn_flag
8591 if test -z "$ac_cpp_err"; then
8592 eval "$as_ac_Header=yes"
8594 echo "$as_me: failed program was:" >&5
8595 cat conftest.$ac_ext >&5
8596 eval "$as_ac_Header=no"
8598 rm -f conftest.err conftest.$ac_ext
8600 echo "$as_me:8600: result: `eval echo '${'$as_ac_Header'}'`" >&5
8601 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8602 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8603 cat >>confdefs.h <<EOF
8604 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8610 cat >>confdefs.h <<\EOF
8614 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
8616 cat >>confdefs.h <<EOF
8617 #define $cf_nculib_ROOT 1
8620 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
8624 cf_ncuhdr_root=ncursesw
8626 test -n "$cf_cv_curses_dir" && \
8627 test "$cf_cv_curses_dir" != "no" && { \
8629 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
8630 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
8632 while test $cf_add_incdir != /usr/include
8634 if test -d $cf_add_incdir
8637 if test -n "$CFLAGS$CPPFLAGS" ; then
8638 # a loop is needed to ensure we can add subdirs of existing dirs
8639 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
8640 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
8641 cf_have_incdir=yes; break
8646 if test "$cf_have_incdir" = no ; then
8647 if test "$cf_add_incdir" = /usr/local/include ; then
8648 if test "$GCC" = yes
8650 cf_save_CPPFLAGS=$CPPFLAGS
8651 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8652 cat >conftest.$ac_ext <<_ACEOF
8653 #line 8653 "configure"
8654 #include "confdefs.h"
8664 rm -f conftest.$ac_objext
8665 if { (eval echo "$as_me:8665: \"$ac_compile\"") >&5
8666 (eval $ac_compile) 2>&5
8668 echo "$as_me:8668: \$? = $ac_status" >&5
8669 (exit $ac_status); } &&
8670 { ac_try='test -s conftest.$ac_objext'
8671 { (eval echo "$as_me:8671: \"$ac_try\"") >&5
8674 echo "$as_me:8674: \$? = $ac_status" >&5
8675 (exit $ac_status); }; }; then
8678 echo "$as_me: failed program was:" >&5
8679 cat conftest.$ac_ext >&5
8682 rm -f conftest.$ac_objext conftest.$ac_ext
8683 CPPFLAGS=$cf_save_CPPFLAGS
8688 if test "$cf_have_incdir" = no ; then
8689 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
8691 echo "${as_me:-configure}:8691: testing adding $cf_add_incdir to include-path ..." 1>&5
8693 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8695 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
8696 test "$cf_top_incdir" = "$cf_add_incdir" && break
8697 cf_add_incdir="$cf_top_incdir"
8708 echo "$as_me:8708: checking for $cf_ncuhdr_root header in include-path" >&5
8709 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
8710 if test "${cf_cv_ncurses_h+set}" = set; then
8711 echo $ECHO_N "(cached) $ECHO_C" >&6
8714 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
8715 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
8716 for cf_header in $cf_header_list
8719 cat >conftest.$ac_ext <<_ACEOF
8720 #line 8720 "configure"
8721 #include "confdefs.h"
8723 #define _XOPEN_SOURCE_EXTENDED
8724 #undef HAVE_LIBUTF8_H /* in case we used CF_UTF8_LIB */
8725 #define HAVE_LIBUTF8_H /* to force ncurses' header file to use cchar_t */
8727 #include <$cf_header>
8732 #ifdef NCURSES_VERSION
8738 printf("%s\n", NCURSES_VERSION);
8751 rm -f conftest.$ac_objext
8752 if { (eval echo "$as_me:8752: \"$ac_compile\"") >&5
8753 (eval $ac_compile) 2>&5
8755 echo "$as_me:8755: \$? = $ac_status" >&5
8756 (exit $ac_status); } &&
8757 { ac_try='test -s conftest.$ac_objext'
8758 { (eval echo "$as_me:8758: \"$ac_try\"") >&5
8761 echo "$as_me:8761: \$? = $ac_status" >&5
8762 (exit $ac_status); }; }; then
8763 cf_cv_ncurses_h=$cf_header
8766 echo "$as_me: failed program was:" >&5
8767 cat conftest.$ac_ext >&5
8770 rm -f conftest.$ac_objext conftest.$ac_ext
8772 test "$cf_cv_ncurses_h" != no && break
8776 echo "$as_me:8776: result: $cf_cv_ncurses_h" >&5
8777 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
8779 if test "$cf_cv_ncurses_h" != no ; then
8780 cf_cv_ncurses_header=$cf_cv_ncurses_h
8783 echo "$as_me:8783: checking for $cf_ncuhdr_root include-path" >&5
8784 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
8785 if test "${cf_cv_ncurses_h2+set}" = set; then
8786 echo $ECHO_N "(cached) $ECHO_C" >&6
8789 test -n "$verbose" && echo
8793 # collect the current set of include-directories from compiler flags
8794 cf_header_path_list=""
8795 if test -n "${CFLAGS}${CPPFLAGS}" ; then
8796 for cf_header_path in $CPPFLAGS $CFLAGS
8798 case $cf_header_path in #(vi
8800 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
8802 test "$cf_header_path" != "NONE" && \
8803 test -d "$cf_header_path" && \
8805 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
8806 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
8807 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
8808 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
8809 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
8810 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"
8813 cf_header_path_list="$cf_header_path_list $cf_search"
8819 # add the variations for the package we are looking for
8823 test "/usr" != "$prefix" && \
8825 (test $prefix = NONE || test "/usr" != "$prefix") && {
8826 test -n "$verbose" && echo " ... testing for include-directories under /usr"
8827 test -d /usr/include && cf_search="$cf_search /usr/include"
8828 test -d /usr/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/include/$cf_ncuhdr_root"
8829 test -d /usr/include/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/include/$cf_ncuhdr_root/include"
8830 test -d /usr/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/$cf_ncuhdr_root/include"
8831 test -d /usr/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
8834 test "$prefix" != "NONE" && \
8835 test -d "$prefix" && \
8837 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
8838 test -d $prefix/include && cf_search="$cf_search $prefix/include"
8839 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
8840 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
8841 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
8842 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
8845 test "/usr/local" != "$prefix" && \
8846 test -d "/usr/local" && \
8847 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
8848 test -n "$verbose" && echo " ... testing for include-directories under /usr/local"
8849 test -d /usr/local/include && cf_search="$cf_search /usr/local/include"
8850 test -d /usr/local/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/local/include/$cf_ncuhdr_root"
8851 test -d /usr/local/include/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/local/include/$cf_ncuhdr_root/include"
8852 test -d /usr/local/$cf_ncuhdr_root/include && cf_search="$cf_search /usr/local/$cf_ncuhdr_root/include"
8853 test -d /usr/local/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /usr/local/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
8856 test "/opt" != "$prefix" && \
8858 (test $prefix = NONE || test "/opt" != "$prefix") && {
8859 test -n "$verbose" && echo " ... testing for include-directories under /opt"
8860 test -d /opt/include && cf_search="$cf_search /opt/include"
8861 test -d /opt/include/$cf_ncuhdr_root && cf_search="$cf_search /opt/include/$cf_ncuhdr_root"
8862 test -d /opt/include/$cf_ncuhdr_root/include && cf_search="$cf_search /opt/include/$cf_ncuhdr_root/include"
8863 test -d /opt/$cf_ncuhdr_root/include && cf_search="$cf_search /opt/$cf_ncuhdr_root/include"
8864 test -d /opt/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search /opt/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
8867 test "$HOME" != "$prefix" && \
8868 test -d "$HOME" && \
8869 (test $prefix = NONE || test "$HOME" != "$prefix") && {
8870 test -n "$verbose" && echo " ... testing for include-directories under $HOME"
8871 test -d $HOME/include && cf_search="$cf_search $HOME/include"
8872 test -d $HOME/include/$cf_ncuhdr_root && cf_search="$cf_search $HOME/include/$cf_ncuhdr_root"
8873 test -d $HOME/include/$cf_ncuhdr_root/include && cf_search="$cf_search $HOME/include/$cf_ncuhdr_root/include"
8874 test -d $HOME/$cf_ncuhdr_root/include && cf_search="$cf_search $HOME/$cf_ncuhdr_root/include"
8875 test -d $HOME/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $HOME/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
8878 test "$includedir" != NONE && \
8879 test "$includedir" != "/usr/include" && \
8880 test -d "$includedir" && {
8881 test -d $includedir && cf_search="$cf_search $includedir"
8882 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
8885 test "$oldincludedir" != NONE && \
8886 test "$oldincludedir" != "/usr/include" && \
8887 test -d "$oldincludedir" && {
8888 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
8889 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
8892 cf_search="$cf_search $cf_header_path_list"
8894 test -n "$verbose" && echo search path $cf_search
8895 cf_save2_CPPFLAGS="$CPPFLAGS"
8896 for cf_incdir in $cf_search
8899 if test -n "$cf_incdir" ; then
8900 for cf_add_incdir in $cf_incdir
8902 while test $cf_add_incdir != /usr/include
8904 if test -d $cf_add_incdir
8907 if test -n "$CFLAGS$CPPFLAGS" ; then
8908 # a loop is needed to ensure we can add subdirs of existing dirs
8909 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
8910 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
8911 cf_have_incdir=yes; break
8916 if test "$cf_have_incdir" = no ; then
8917 if test "$cf_add_incdir" = /usr/local/include ; then
8918 if test "$GCC" = yes
8920 cf_save_CPPFLAGS=$CPPFLAGS
8921 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8922 cat >conftest.$ac_ext <<_ACEOF
8923 #line 8923 "configure"
8924 #include "confdefs.h"
8934 rm -f conftest.$ac_objext
8935 if { (eval echo "$as_me:8935: \"$ac_compile\"") >&5
8936 (eval $ac_compile) 2>&5
8938 echo "$as_me:8938: \$? = $ac_status" >&5
8939 (exit $ac_status); } &&
8940 { ac_try='test -s conftest.$ac_objext'
8941 { (eval echo "$as_me:8941: \"$ac_try\"") >&5
8944 echo "$as_me:8944: \$? = $ac_status" >&5
8945 (exit $ac_status); }; }; then
8948 echo "$as_me: failed program was:" >&5
8949 cat conftest.$ac_ext >&5
8952 rm -f conftest.$ac_objext conftest.$ac_ext
8953 CPPFLAGS=$cf_save_CPPFLAGS
8958 if test "$cf_have_incdir" = no ; then
8959 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
8961 echo "${as_me:-configure}:8961: testing adding $cf_add_incdir to include-path ..." 1>&5
8963 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8965 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
8966 test "$cf_top_incdir" = "$cf_add_incdir" && break
8967 cf_add_incdir="$cf_top_incdir"
8981 cat >conftest.$ac_ext <<_ACEOF
8982 #line 8982 "configure"
8983 #include "confdefs.h"
8985 #include <$cf_header>
8990 #ifdef NCURSES_VERSION
8992 printf("%s\n", NCURSES_VERSION);
9005 rm -f conftest.$ac_objext
9006 if { (eval echo "$as_me:9006: \"$ac_compile\"") >&5
9007 (eval $ac_compile) 2>&5
9009 echo "$as_me:9009: \$? = $ac_status" >&5
9010 (exit $ac_status); } &&
9011 { ac_try='test -s conftest.$ac_objext'
9012 { (eval echo "$as_me:9012: \"$ac_try\"") >&5
9015 echo "$as_me:9015: \$? = $ac_status" >&5
9016 (exit $ac_status); }; }; then
9017 cf_cv_ncurses_h2=$cf_header
9020 echo "$as_me: failed program was:" >&5
9021 cat conftest.$ac_ext >&5
9024 rm -f conftest.$ac_objext conftest.$ac_ext
9026 if test "$cf_cv_ncurses_h2" != no ; then
9027 cf_cv_ncurses_h2=$cf_incdir/$cf_header
9028 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
9031 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
9033 CPPFLAGS="$cf_save2_CPPFLAGS"
9034 test "$cf_cv_ncurses_h2" != no && break
9036 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:9036: error: not found" >&5
9037 echo "$as_me: error: not found" >&2;}
9038 { (exit 1); exit 1; }; }
9041 echo "$as_me:9041: result: $cf_cv_ncurses_h2" >&5
9042 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
9044 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
9045 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
9046 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
9047 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
9050 if test -n "$cf_1st_incdir" ; then
9051 for cf_add_incdir in $cf_1st_incdir
9053 while test $cf_add_incdir != /usr/include
9055 if test -d $cf_add_incdir
9058 if test -n "$CFLAGS$CPPFLAGS" ; then
9059 # a loop is needed to ensure we can add subdirs of existing dirs
9060 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
9061 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
9062 cf_have_incdir=yes; break
9067 if test "$cf_have_incdir" = no ; then
9068 if test "$cf_add_incdir" = /usr/local/include ; then
9069 if test "$GCC" = yes
9071 cf_save_CPPFLAGS=$CPPFLAGS
9072 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
9073 cat >conftest.$ac_ext <<_ACEOF
9074 #line 9074 "configure"
9075 #include "confdefs.h"
9085 rm -f conftest.$ac_objext
9086 if { (eval echo "$as_me:9086: \"$ac_compile\"") >&5
9087 (eval $ac_compile) 2>&5
9089 echo "$as_me:9089: \$? = $ac_status" >&5
9090 (exit $ac_status); } &&
9091 { ac_try='test -s conftest.$ac_objext'
9092 { (eval echo "$as_me:9092: \"$ac_try\"") >&5
9095 echo "$as_me:9095: \$? = $ac_status" >&5
9096 (exit $ac_status); }; }; then
9099 echo "$as_me: failed program was:" >&5
9100 cat conftest.$ac_ext >&5
9103 rm -f conftest.$ac_objext conftest.$ac_ext
9104 CPPFLAGS=$cf_save_CPPFLAGS
9109 if test "$cf_have_incdir" = no ; then
9110 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
9112 echo "${as_me:-configure}:9112: testing adding $cf_add_incdir to include-path ..." 1>&5
9114 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
9116 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
9117 test "$cf_top_incdir" = "$cf_add_incdir" && break
9118 cf_add_incdir="$cf_top_incdir"
9129 # Set definitions to allow ifdef'ing for ncurses.h
9131 case $cf_cv_ncurses_header in # (vi
9133 cat >>confdefs.h <<\EOF
9134 #define HAVE_NCURSES_H 1
9140 case $cf_cv_ncurses_header in # (vi
9141 ncurses/curses.h|ncurses/ncurses.h)
9142 cat >>confdefs.h <<\EOF
9143 #define HAVE_NCURSES_NCURSES_H 1
9147 ncursesw/curses.h|ncursesw/ncurses.h)
9148 cat >>confdefs.h <<\EOF
9149 #define HAVE_NCURSESW_NCURSES_H 1
9155 echo "$as_me:9155: checking for terminfo header" >&5
9156 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
9157 if test "${cf_cv_term_header+set}" = set; then
9158 echo $ECHO_N "(cached) $ECHO_C" >&6
9161 case ${cf_cv_ncurses_header} in #(vi
9162 */ncurses.h|*/ncursesw.h) #(vi
9163 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
9166 cf_term_header=term.h
9170 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
9172 cat >conftest.$ac_ext <<_ACEOF
9173 #line 9173 "configure"
9174 #include "confdefs.h"
9176 #include <${cf_cv_ncurses_header:-curses.h}>
9182 int x = auto_left_margin
9187 rm -f conftest.$ac_objext
9188 if { (eval echo "$as_me:9188: \"$ac_compile\"") >&5
9189 (eval $ac_compile) 2>&5
9191 echo "$as_me:9191: \$? = $ac_status" >&5
9192 (exit $ac_status); } &&
9193 { ac_try='test -s conftest.$ac_objext'
9194 { (eval echo "$as_me:9194: \"$ac_try\"") >&5
9197 echo "$as_me:9197: \$? = $ac_status" >&5
9198 (exit $ac_status); }; }; then
9200 cf_cv_term_header="$cf_test"
9202 echo "$as_me: failed program was:" >&5
9203 cat conftest.$ac_ext >&5
9205 cf_cv_term_header=unknown
9208 rm -f conftest.$ac_objext conftest.$ac_ext
9209 test "$cf_cv_term_header" != unknown && break
9213 echo "$as_me:9213: result: $cf_cv_term_header" >&5
9214 echo "${ECHO_T}$cf_cv_term_header" >&6
9216 # Set definitions to allow ifdef'ing to accommodate subdirectories
9218 case $cf_cv_term_header in # (vi
9220 cat >>confdefs.h <<\EOF
9221 #define HAVE_TERM_H 1
9227 case $cf_cv_term_header in # (vi
9228 ncurses/term.h) #(vi
9229 cat >>confdefs.h <<\EOF
9230 #define HAVE_NCURSES_TERM_H 1
9235 cat >>confdefs.h <<\EOF
9236 #define HAVE_NCURSESW_TERM_H 1
9242 # some applications need this, but should check for NCURSES_VERSION
9243 cat >>confdefs.h <<\EOF
9247 echo "$as_me:9247: checking for ncurses version" >&5
9248 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
9249 if test "${cf_cv_ncurses_version+set}" = set; then
9250 echo $ECHO_N "(cached) $ECHO_C" >&6
9253 cf_cv_ncurses_version=no
9256 if test "$cross_compiling" = yes; then
9258 # This will not work if the preprocessor splits the line after the
9259 # Autoconf token. The 'unproto' program does that.
9260 cat > conftest.$ac_ext <<EOF
9261 #include <${cf_cv_ncurses_header:-curses.h}>
9263 #ifdef NCURSES_VERSION
9264 Autoconf NCURSES_VERSION
9272 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
9273 { (eval echo "$as_me:9273: \"$cf_try\"") >&5
9276 echo "$as_me:9276: \$? = $ac_status" >&5
9277 (exit $ac_status); }
9278 if test -f conftest.out ; then
9279 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
9280 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
9285 cat >conftest.$ac_ext <<_ACEOF
9286 #line 9286 "configure"
9287 #include "confdefs.h"
9289 #include <${cf_cv_ncurses_header:-curses.h}>
9293 FILE *fp = fopen("$cf_tempfile", "w");
9294 #ifdef NCURSES_VERSION
9295 # ifdef NCURSES_VERSION_PATCH
9296 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
9298 fprintf(fp, "%s\n", NCURSES_VERSION);
9302 fprintf(fp, "old\n");
9307 ${cf_cv_main_return:-return}(0);
9310 rm -f conftest$ac_exeext
9311 if { (eval echo "$as_me:9311: \"$ac_link\"") >&5
9312 (eval $ac_link) 2>&5
9314 echo "$as_me:9314: \$? = $ac_status" >&5
9315 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
9316 { (eval echo "$as_me:9316: \"$ac_try\"") >&5
9319 echo "$as_me:9319: \$? = $ac_status" >&5
9320 (exit $ac_status); }; }; then
9322 cf_cv_ncurses_version=`cat $cf_tempfile`
9324 echo "$as_me: program exited with status $ac_status" >&5
9325 echo "$as_me: failed program was:" >&5
9326 cat conftest.$ac_ext >&5
9328 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
9333 echo "$as_me:9333: result: $cf_cv_ncurses_version" >&5
9334 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
9335 test "$cf_cv_ncurses_version" = no || cat >>confdefs.h <<\EOF
9339 cf_nculib_root=ncursesw
9340 # This works, except for the special case where we find gpm, but
9341 # ncurses is in a nonstandard location via $LIBS, and we really want
9344 cf_ncurses_SAVE="$LIBS"
9345 echo "$as_me:9345: checking for Gpm_Open in -lgpm" >&5
9346 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
9347 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
9348 echo $ECHO_N "(cached) $ECHO_C" >&6
9350 ac_check_lib_save_LIBS=$LIBS
9352 cat >conftest.$ac_ext <<_ACEOF
9353 #line 9353 "configure"
9354 #include "confdefs.h"
9356 /* Override any gcc2 internal prototype to avoid an error. */
9360 /* We use char because int might match the return type of a gcc2
9361 builtin and then its argument prototype would still apply. */
9371 rm -f conftest.$ac_objext conftest$ac_exeext
9372 if { (eval echo "$as_me:9372: \"$ac_link\"") >&5
9373 (eval $ac_link) 2>&5
9375 echo "$as_me:9375: \$? = $ac_status" >&5
9376 (exit $ac_status); } &&
9377 { ac_try='test -s conftest$ac_exeext'
9378 { (eval echo "$as_me:9378: \"$ac_try\"") >&5
9381 echo "$as_me:9381: \$? = $ac_status" >&5
9382 (exit $ac_status); }; }; then
9383 ac_cv_lib_gpm_Gpm_Open=yes
9385 echo "$as_me: failed program was:" >&5
9386 cat conftest.$ac_ext >&5
9387 ac_cv_lib_gpm_Gpm_Open=no
9389 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9390 LIBS=$ac_check_lib_save_LIBS
9392 echo "$as_me:9392: result: $ac_cv_lib_gpm_Gpm_Open" >&5
9393 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
9394 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
9395 echo "$as_me:9395: checking for initscr in -lgpm" >&5
9396 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
9397 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
9398 echo $ECHO_N "(cached) $ECHO_C" >&6
9400 ac_check_lib_save_LIBS=$LIBS
9402 cat >conftest.$ac_ext <<_ACEOF
9403 #line 9403 "configure"
9404 #include "confdefs.h"
9406 /* Override any gcc2 internal prototype to avoid an error. */
9410 /* We use char because int might match the return type of a gcc2
9411 builtin and then its argument prototype would still apply. */
9421 rm -f conftest.$ac_objext conftest$ac_exeext
9422 if { (eval echo "$as_me:9422: \"$ac_link\"") >&5
9423 (eval $ac_link) 2>&5
9425 echo "$as_me:9425: \$? = $ac_status" >&5
9426 (exit $ac_status); } &&
9427 { ac_try='test -s conftest$ac_exeext'
9428 { (eval echo "$as_me:9428: \"$ac_try\"") >&5
9431 echo "$as_me:9431: \$? = $ac_status" >&5
9432 (exit $ac_status); }; }; then
9433 ac_cv_lib_gpm_initscr=yes
9435 echo "$as_me: failed program was:" >&5
9436 cat conftest.$ac_ext >&5
9437 ac_cv_lib_gpm_initscr=no
9439 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9440 LIBS=$ac_check_lib_save_LIBS
9442 echo "$as_me:9442: result: $ac_cv_lib_gpm_initscr" >&5
9443 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
9444 if test $ac_cv_lib_gpm_initscr = yes; then
9445 LIBS="$cf_ncurses_SAVE"
9447 cf_ncurses_LIBS="-lgpm"
9452 case $host_os in #(vi
9454 # This is only necessary if you are linking against an obsolete
9455 # version of ncurses (but it should do no harm, since it's static).
9456 if test "$cf_nculib_root" = ncurses ; then
9457 echo "$as_me:9457: checking for tgoto in -lmytinfo" >&5
9458 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
9459 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
9460 echo $ECHO_N "(cached) $ECHO_C" >&6
9462 ac_check_lib_save_LIBS=$LIBS
9463 LIBS="-lmytinfo $LIBS"
9464 cat >conftest.$ac_ext <<_ACEOF
9465 #line 9465 "configure"
9466 #include "confdefs.h"
9468 /* Override any gcc2 internal prototype to avoid an error. */
9472 /* We use char because int might match the return type of a gcc2
9473 builtin and then its argument prototype would still apply. */
9483 rm -f conftest.$ac_objext conftest$ac_exeext
9484 if { (eval echo "$as_me:9484: \"$ac_link\"") >&5
9485 (eval $ac_link) 2>&5
9487 echo "$as_me:9487: \$? = $ac_status" >&5
9488 (exit $ac_status); } &&
9489 { ac_try='test -s conftest$ac_exeext'
9490 { (eval echo "$as_me:9490: \"$ac_try\"") >&5
9493 echo "$as_me:9493: \$? = $ac_status" >&5
9494 (exit $ac_status); }; }; then
9495 ac_cv_lib_mytinfo_tgoto=yes
9497 echo "$as_me: failed program was:" >&5
9498 cat conftest.$ac_ext >&5
9499 ac_cv_lib_mytinfo_tgoto=no
9501 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9502 LIBS=$ac_check_lib_save_LIBS
9504 echo "$as_me:9504: result: $ac_cv_lib_mytinfo_tgoto" >&5
9505 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
9506 if test $ac_cv_lib_mytinfo_tgoto = yes; then
9507 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
9514 LIBS="$cf_ncurses_LIBS $LIBS"
9516 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
9518 LIBS="-l$cf_nculib_root $LIBS"
9521 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
9523 echo "$as_me:9523: checking for initscr" >&5
9524 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
9525 if test "${ac_cv_func_initscr+set}" = set; then
9526 echo $ECHO_N "(cached) $ECHO_C" >&6
9528 cat >conftest.$ac_ext <<_ACEOF
9529 #line 9529 "configure"
9530 #include "confdefs.h"
9531 /* System header to define __stub macros and hopefully few prototypes,
9532 which can conflict with char initscr (); below. */
9534 /* Override any gcc2 internal prototype to avoid an error. */
9538 /* We use char because int might match the return type of a gcc2
9539 builtin and then its argument prototype would still apply. */
9546 /* The GNU C library defines this for functions which it implements
9547 to always fail with ENOSYS. Some functions are actually named
9548 something starting with __ and the normal name is an alias. */
9549 #if defined (__stub_initscr) || defined (__stub___initscr)
9559 rm -f conftest.$ac_objext conftest$ac_exeext
9560 if { (eval echo "$as_me:9560: \"$ac_link\"") >&5
9561 (eval $ac_link) 2>&5
9563 echo "$as_me:9563: \$? = $ac_status" >&5
9564 (exit $ac_status); } &&
9565 { ac_try='test -s conftest$ac_exeext'
9566 { (eval echo "$as_me:9566: \"$ac_try\"") >&5
9569 echo "$as_me:9569: \$? = $ac_status" >&5
9570 (exit $ac_status); }; }; then
9571 ac_cv_func_initscr=yes
9573 echo "$as_me: failed program was:" >&5
9574 cat conftest.$ac_ext >&5
9575 ac_cv_func_initscr=no
9577 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9579 echo "$as_me:9579: result: $ac_cv_func_initscr" >&5
9580 echo "${ECHO_T}$ac_cv_func_initscr" >&6
9581 if test $ac_cv_func_initscr = yes; then
9582 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
9585 cf_save_LIBS="$LIBS"
9586 echo "$as_me:9586: checking for initscr in -l$cf_nculib_root" >&5
9587 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
9588 LIBS="-l$cf_nculib_root $LIBS"
9589 cat >conftest.$ac_ext <<_ACEOF
9590 #line 9590 "configure"
9591 #include "confdefs.h"
9592 #include <${cf_cv_ncurses_header:-curses.h}>
9601 rm -f conftest.$ac_objext conftest$ac_exeext
9602 if { (eval echo "$as_me:9602: \"$ac_link\"") >&5
9603 (eval $ac_link) 2>&5
9605 echo "$as_me:9605: \$? = $ac_status" >&5
9606 (exit $ac_status); } &&
9607 { ac_try='test -s conftest$ac_exeext'
9608 { (eval echo "$as_me:9608: \"$ac_try\"") >&5
9611 echo "$as_me:9611: \$? = $ac_status" >&5
9612 (exit $ac_status); }; }; then
9613 echo "$as_me:9613: result: yes" >&5
9614 echo "${ECHO_T}yes" >&6
9615 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
9618 echo "$as_me: failed program was:" >&5
9619 cat conftest.$ac_ext >&5
9620 echo "$as_me:9620: result: no" >&5
9621 echo "${ECHO_T}no" >&6
9624 cf_library_path_list=""
9625 if test -n "${LDFLAGS}${LIBS}" ; then
9626 for cf_library_path in $LDFLAGS $LIBS
9628 case $cf_library_path in #(vi
9630 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
9632 test "$cf_library_path" != "NONE" && \
9633 test -d "$cf_library_path" && \
9635 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
9636 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
9637 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
9638 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
9639 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
9640 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"
9643 cf_library_path_list="$cf_library_path_list $cf_search"
9651 test "/usr" != "$prefix" && \
9653 (test $prefix = NONE || test "/usr" != "$prefix") && {
9654 test -n "$verbose" && echo " ... testing for lib-directories under /usr"
9655 test -d /usr/lib && cf_search="$cf_search /usr/lib"
9656 test -d /usr/lib/$cf_nculib_root && cf_search="$cf_search /usr/lib/$cf_nculib_root"
9657 test -d /usr/lib/$cf_nculib_root/lib && cf_search="$cf_search /usr/lib/$cf_nculib_root/lib"
9658 test -d /usr/$cf_nculib_root/lib && cf_search="$cf_search /usr/$cf_nculib_root/lib"
9659 test -d /usr/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /usr/$cf_nculib_root/lib/$cf_nculib_root"
9662 test "$prefix" != "NONE" && \
9663 test -d "$prefix" && \
9665 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
9666 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
9667 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
9668 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
9669 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
9670 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
9673 test "/usr/local" != "$prefix" && \
9674 test -d "/usr/local" && \
9675 (test $prefix = NONE || test "/usr/local" != "$prefix") && {
9676 test -n "$verbose" && echo " ... testing for lib-directories under /usr/local"
9677 test -d /usr/local/lib && cf_search="$cf_search /usr/local/lib"
9678 test -d /usr/local/lib/$cf_nculib_root && cf_search="$cf_search /usr/local/lib/$cf_nculib_root"
9679 test -d /usr/local/lib/$cf_nculib_root/lib && cf_search="$cf_search /usr/local/lib/$cf_nculib_root/lib"
9680 test -d /usr/local/$cf_nculib_root/lib && cf_search="$cf_search /usr/local/$cf_nculib_root/lib"
9681 test -d /usr/local/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /usr/local/$cf_nculib_root/lib/$cf_nculib_root"
9684 test "/opt" != "$prefix" && \
9686 (test $prefix = NONE || test "/opt" != "$prefix") && {
9687 test -n "$verbose" && echo " ... testing for lib-directories under /opt"
9688 test -d /opt/lib && cf_search="$cf_search /opt/lib"
9689 test -d /opt/lib/$cf_nculib_root && cf_search="$cf_search /opt/lib/$cf_nculib_root"
9690 test -d /opt/lib/$cf_nculib_root/lib && cf_search="$cf_search /opt/lib/$cf_nculib_root/lib"
9691 test -d /opt/$cf_nculib_root/lib && cf_search="$cf_search /opt/$cf_nculib_root/lib"
9692 test -d /opt/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search /opt/$cf_nculib_root/lib/$cf_nculib_root"
9695 test "$HOME" != "$prefix" && \
9696 test -d "$HOME" && \
9697 (test $prefix = NONE || test "$HOME" != "$prefix") && {
9698 test -n "$verbose" && echo " ... testing for lib-directories under $HOME"
9699 test -d $HOME/lib && cf_search="$cf_search $HOME/lib"
9700 test -d $HOME/lib/$cf_nculib_root && cf_search="$cf_search $HOME/lib/$cf_nculib_root"
9701 test -d $HOME/lib/$cf_nculib_root/lib && cf_search="$cf_search $HOME/lib/$cf_nculib_root/lib"
9702 test -d $HOME/$cf_nculib_root/lib && cf_search="$cf_search $HOME/$cf_nculib_root/lib"
9703 test -d $HOME/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $HOME/$cf_nculib_root/lib/$cf_nculib_root"
9706 cf_search="$cf_library_path_list $cf_search"
9708 for cf_libdir in $cf_search
9710 echo "$as_me:9710: checking for -l$cf_nculib_root in $cf_libdir" >&5
9711 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
9712 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
9713 cat >conftest.$ac_ext <<_ACEOF
9714 #line 9714 "configure"
9715 #include "confdefs.h"
9716 #include <${cf_cv_ncurses_header:-curses.h}>
9725 rm -f conftest.$ac_objext conftest$ac_exeext
9726 if { (eval echo "$as_me:9726: \"$ac_link\"") >&5
9727 (eval $ac_link) 2>&5
9729 echo "$as_me:9729: \$? = $ac_status" >&5
9730 (exit $ac_status); } &&
9731 { ac_try='test -s conftest$ac_exeext'
9732 { (eval echo "$as_me:9732: \"$ac_try\"") >&5
9735 echo "$as_me:9735: \$? = $ac_status" >&5
9736 (exit $ac_status); }; }; then
9737 echo "$as_me:9737: result: yes" >&5
9738 echo "${ECHO_T}yes" >&6
9739 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
9742 echo "$as_me: failed program was:" >&5
9743 cat conftest.$ac_ext >&5
9744 echo "$as_me:9744: result: no" >&5
9745 echo "${ECHO_T}no" >&6
9746 LIBS="$cf_save_LIBS"
9748 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9752 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9756 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
9758 if test $cf_found_library = no ; then
9759 { { echo "$as_me:9759: error: Cannot link $cf_nculib_root library" >&5
9760 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
9761 { (exit 1); exit 1; }; }
9766 if test -n "$cf_ncurses_LIBS" ; then
9767 echo "$as_me:9767: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
9768 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
9769 cf_ncurses_SAVE="$LIBS"
9770 for p in $cf_ncurses_LIBS ; do
9771 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
9772 if test "$q" != "$LIBS" ; then
9776 cat >conftest.$ac_ext <<_ACEOF
9777 #line 9777 "configure"
9778 #include "confdefs.h"
9779 #include <${cf_cv_ncurses_header:-curses.h}>
9783 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
9788 rm -f conftest.$ac_objext conftest$ac_exeext
9789 if { (eval echo "$as_me:9789: \"$ac_link\"") >&5
9790 (eval $ac_link) 2>&5
9792 echo "$as_me:9792: \$? = $ac_status" >&5
9793 (exit $ac_status); } &&
9794 { ac_try='test -s conftest$ac_exeext'
9795 { (eval echo "$as_me:9795: \"$ac_try\"") >&5
9798 echo "$as_me:9798: \$? = $ac_status" >&5
9799 (exit $ac_status); }; }; then
9800 echo "$as_me:9800: result: yes" >&5
9801 echo "${ECHO_T}yes" >&6
9803 echo "$as_me: failed program was:" >&5
9804 cat conftest.$ac_ext >&5
9805 echo "$as_me:9805: result: no" >&5
9806 echo "${ECHO_T}no" >&6
9807 LIBS="$cf_ncurses_SAVE"
9809 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9812 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
9814 cat >>confdefs.h <<EOF
9815 #define $cf_nculib_ROOT 1
9823 echo "$as_me:9823: checking if you want to use pkg-config" >&5
9824 echo $ECHO_N "checking if you want to use pkg-config... $ECHO_C" >&6
9826 # Check whether --with-pkg-config or --without-pkg-config was given.
9827 if test "${with_pkg_config+set}" = set; then
9828 withval="$with_pkg_config"
9829 cf_pkg_config=$withval
9833 echo "$as_me:9833: result: $cf_pkg_config" >&5
9834 echo "${ECHO_T}$cf_pkg_config" >&6
9836 case $cf_pkg_config in #(vi
9842 if test -n "$ac_tool_prefix"; then
9843 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
9844 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
9845 echo "$as_me:9845: checking for $ac_word" >&5
9846 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
9847 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then
9848 echo $ECHO_N "(cached) $ECHO_C" >&6
9852 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
9855 ac_save_IFS=$IFS; IFS=$ac_path_separator
9857 for ac_dir in $ac_dummy; do
9859 test -z "$ac_dir" && ac_dir=.
9860 if $as_executable_p "$ac_dir/$ac_word"; then
9861 ac_cv_path_PKG_CONFIG="$ac_dir/$ac_word"
9862 echo "$as_me:9862: found $ac_dir/$ac_word" >&5
9870 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
9872 if test -n "$PKG_CONFIG"; then
9873 echo "$as_me:9873: result: $PKG_CONFIG" >&5
9874 echo "${ECHO_T}$PKG_CONFIG" >&6
9876 echo "$as_me:9876: result: no" >&5
9877 echo "${ECHO_T}no" >&6
9881 if test -z "$ac_cv_path_PKG_CONFIG"; then
9882 ac_pt_PKG_CONFIG=$PKG_CONFIG
9883 # Extract the first word of "pkg-config", so it can be a program name with args.
9884 set dummy pkg-config; ac_word=$2
9885 echo "$as_me:9885: checking for $ac_word" >&5
9886 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
9887 if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then
9888 echo $ECHO_N "(cached) $ECHO_C" >&6
9890 case $ac_pt_PKG_CONFIG in
9892 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
9895 ac_save_IFS=$IFS; IFS=$ac_path_separator
9897 for ac_dir in $ac_dummy; do
9899 test -z "$ac_dir" && ac_dir=.
9900 if $as_executable_p "$ac_dir/$ac_word"; then
9901 ac_cv_path_ac_pt_PKG_CONFIG="$ac_dir/$ac_word"
9902 echo "$as_me:9902: found $ac_dir/$ac_word" >&5
9907 test -z "$ac_cv_path_ac_pt_PKG_CONFIG" && ac_cv_path_ac_pt_PKG_CONFIG="none"
9911 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
9913 if test -n "$ac_pt_PKG_CONFIG"; then
9914 echo "$as_me:9914: result: $ac_pt_PKG_CONFIG" >&5
9915 echo "${ECHO_T}$ac_pt_PKG_CONFIG" >&6
9917 echo "$as_me:9917: result: no" >&5
9918 echo "${ECHO_T}no" >&6
9921 PKG_CONFIG=$ac_pt_PKG_CONFIG
9923 PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
9932 test -z "$PKG_CONFIG" && PKG_CONFIG=none
9933 if test "$PKG_CONFIG" != none ; then
9935 if test "x$prefix" != xNONE; then
9936 cf_path_syntax="$prefix"
9938 cf_path_syntax="$ac_default_prefix"
9941 case ".$PKG_CONFIG" in #(vi
9942 .\$\(*\)*|.\'*\'*) #(vi
9946 .[a-zA-Z]:[\\/]*) #(vi OS/2 EMX
9949 eval PKG_CONFIG="$PKG_CONFIG"
9950 case ".$PKG_CONFIG" in #(vi
9952 PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
9957 PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
9960 { { echo "$as_me:9960: error: expected a pathname, not \"$PKG_CONFIG\"" >&5
9961 echo "$as_me: error: expected a pathname, not \"$PKG_CONFIG\"" >&2;}
9962 { (exit 1); exit 1; }; }
9968 echo "$as_me:9968: checking for X" >&5
9969 echo $ECHO_N "checking for X... $ECHO_C" >&6
9971 # Check whether --with-x or --without-x was given.
9972 if test "${with_x+set}" = set; then
9976 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
9977 if test "x$with_x" = xno; then
9978 # The user explicitly disabled X.
9981 if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
9982 # Both variables are already set.
9985 if test "${ac_cv_have_x+set}" = set; then
9986 echo $ECHO_N "(cached) $ECHO_C" >&6
9988 # One or both of the vars are not set, and there is no cached value.
9989 ac_x_includes=no ac_x_libraries=no
9991 if mkdir conftest.dir; then
9993 # Make sure to not put "make" in the Imakefile rules, since we grep it out.
9994 cat >Imakefile <<'EOF'
9996 @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
9998 if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
9999 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
10000 eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
10001 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
10002 for ac_extension in a so sl dylib dll; do
10003 if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
10004 test -f $ac_im_libdir/libX11.$ac_extension; then
10005 ac_im_usrlibdir=$ac_im_libdir; break
10008 # Screen out bogus values from the imake configuration. They are
10009 # bogus both because they are the default anyway, and because
10010 # using them would break gcc on systems where it needs fixed includes.
10011 case $ac_im_incroot in
10013 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
10015 case $ac_im_usrlibdir in
10016 /usr/lib | /lib) ;;
10017 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
10021 rm -fr conftest.dir
10024 # Standard set of common directories for X headers.
10025 # Check X11 before X11Rn because it is often a symlink to the current release.
10037 /usr/local/X11/include
10038 /usr/local/X11R6/include
10039 /usr/local/X11R5/include
10040 /usr/local/X11R4/include
10042 /usr/local/include/X11
10043 /usr/local/include/X11R6
10044 /usr/local/include/X11R5
10045 /usr/local/include/X11R4
10049 /usr/XFree86/include/X11
10053 /usr/unsupported/include
10054 /usr/athena/include
10055 /usr/local/x11r5/include
10056 /usr/lpp/Xamples/include
10058 /usr/openwin/include
10059 /usr/openwin/share/include'
10061 if test "$ac_x_includes" = no; then
10062 # Guess where to find include files, by looking for Intrinsic.h.
10063 # First, try using that file with no special directory specified.
10064 cat >conftest.$ac_ext <<_ACEOF
10065 #line 10065 "configure"
10066 #include "confdefs.h"
10067 #include <X11/Intrinsic.h>
10069 if { (eval echo "$as_me:10069: \"$ac_cpp conftest.$ac_ext\"") >&5
10070 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10072 egrep -v '^ *\+' conftest.er1 >conftest.err
10074 cat conftest.err >&5
10075 echo "$as_me:10075: \$? = $ac_status" >&5
10076 (exit $ac_status); } >/dev/null; then
10077 if test -s conftest.err; then
10078 ac_cpp_err=$ac_c_preproc_warn_flag
10085 if test -z "$ac_cpp_err"; then
10086 # We can compile using X headers with no special include directory.
10089 echo "$as_me: failed program was:" >&5
10090 cat conftest.$ac_ext >&5
10091 for ac_dir in $ac_x_header_dirs; do
10092 if test -r "$ac_dir/X11/Intrinsic.h"; then
10093 ac_x_includes=$ac_dir
10098 rm -f conftest.err conftest.$ac_ext
10099 fi # $ac_x_includes = no
10101 if test "$ac_x_libraries" = no; then
10102 # Check for the libraries.
10103 # See if we find them without any special options.
10104 # Don't add to $LIBS permanently.
10107 cat >conftest.$ac_ext <<_ACEOF
10108 #line 10108 "configure"
10109 #include "confdefs.h"
10110 #include <X11/Intrinsic.h>
10119 rm -f conftest.$ac_objext conftest$ac_exeext
10120 if { (eval echo "$as_me:10120: \"$ac_link\"") >&5
10121 (eval $ac_link) 2>&5
10123 echo "$as_me:10123: \$? = $ac_status" >&5
10124 (exit $ac_status); } &&
10125 { ac_try='test -s conftest$ac_exeext'
10126 { (eval echo "$as_me:10126: \"$ac_try\"") >&5
10127 (eval $ac_try) 2>&5
10129 echo "$as_me:10129: \$? = $ac_status" >&5
10130 (exit $ac_status); }; }; then
10132 # We can link X programs with no special library path.
10135 echo "$as_me: failed program was:" >&5
10136 cat conftest.$ac_ext >&5
10138 for ac_dir in `echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
10140 # Don't even attempt the hair of trying to link an X program!
10141 for ac_extension in a so sl dylib dll; do
10142 if test -r $ac_dir/libXt.$ac_extension; then
10143 ac_x_libraries=$ac_dir
10149 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10150 fi # $ac_x_libraries = no
10152 if test "$ac_x_includes" = no || test "$ac_x_libraries" = no; then
10153 # Didn't find X anywhere. Cache the known absence of X.
10154 ac_cv_have_x="have_x=no"
10156 # Record where we found X for the cache.
10157 ac_cv_have_x="have_x=yes \
10158 ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
10163 eval "$ac_cv_have_x"
10166 if test "$have_x" != yes; then
10167 echo "$as_me:10167: result: $have_x" >&5
10168 echo "${ECHO_T}$have_x" >&6
10171 # If each of the values was on the command line, it overrides each guess.
10172 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
10173 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
10174 # Update the cache value to reflect the command line values.
10175 ac_cv_have_x="have_x=yes \
10176 ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
10177 echo "$as_me:10177: result: libraries $x_libraries, headers $x_includes" >&5
10178 echo "${ECHO_T}libraries $x_libraries, headers $x_includes" >&6
10181 if test "$no_x" = yes; then
10182 # Not all programs may use this symbol, but it does not hurt to define it.
10184 cat >>confdefs.h <<\EOF
10185 #define X_DISPLAY_MISSING 1
10188 X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS=
10190 if test -n "$x_includes"; then
10191 X_CFLAGS="$X_CFLAGS -I$x_includes"
10194 # It would also be nice to do this for all -L options, not just this one.
10195 if test -n "$x_libraries"; then
10196 X_LIBS="$X_LIBS -L$x_libraries"
10197 # For Solaris; some versions of Sun CC require a space after -R and
10198 # others require no space. Words are not sufficient . . . .
10199 case `(uname -sr) 2>/dev/null` in
10201 echo "$as_me:10201: checking whether -R must be followed by a space" >&5
10202 echo $ECHO_N "checking whether -R must be followed by a space... $ECHO_C" >&6
10203 ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries"
10204 cat >conftest.$ac_ext <<_ACEOF
10205 #line 10205 "configure"
10206 #include "confdefs.h"
10216 rm -f conftest.$ac_objext conftest$ac_exeext
10217 if { (eval echo "$as_me:10217: \"$ac_link\"") >&5
10218 (eval $ac_link) 2>&5
10220 echo "$as_me:10220: \$? = $ac_status" >&5
10221 (exit $ac_status); } &&
10222 { ac_try='test -s conftest$ac_exeext'
10223 { (eval echo "$as_me:10223: \"$ac_try\"") >&5
10224 (eval $ac_try) 2>&5
10226 echo "$as_me:10226: \$? = $ac_status" >&5
10227 (exit $ac_status); }; }; then
10230 echo "$as_me: failed program was:" >&5
10231 cat conftest.$ac_ext >&5
10234 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10235 if test $ac_R_nospace = yes; then
10236 echo "$as_me:10236: result: no" >&5
10237 echo "${ECHO_T}no" >&6
10238 X_LIBS="$X_LIBS -R$x_libraries"
10240 LIBS="$ac_xsave_LIBS -R $x_libraries"
10241 cat >conftest.$ac_ext <<_ACEOF
10242 #line 10242 "configure"
10243 #include "confdefs.h"
10253 rm -f conftest.$ac_objext conftest$ac_exeext
10254 if { (eval echo "$as_me:10254: \"$ac_link\"") >&5
10255 (eval $ac_link) 2>&5
10257 echo "$as_me:10257: \$? = $ac_status" >&5
10258 (exit $ac_status); } &&
10259 { ac_try='test -s conftest$ac_exeext'
10260 { (eval echo "$as_me:10260: \"$ac_try\"") >&5
10261 (eval $ac_try) 2>&5
10263 echo "$as_me:10263: \$? = $ac_status" >&5
10264 (exit $ac_status); }; }; then
10267 echo "$as_me: failed program was:" >&5
10268 cat conftest.$ac_ext >&5
10271 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10272 if test $ac_R_space = yes; then
10273 echo "$as_me:10273: result: yes" >&5
10274 echo "${ECHO_T}yes" >&6
10275 X_LIBS="$X_LIBS -R $x_libraries"
10277 echo "$as_me:10277: result: neither works" >&5
10278 echo "${ECHO_T}neither works" >&6
10281 LIBS=$ac_xsave_LIBS
10285 # Check for system-dependent libraries X programs must link with.
10286 # Do this before checking for the system-independent R6 libraries
10287 # (-lICE), since we may need -lsocket or whatever for X linking.
10289 if test "$ISC" = yes; then
10290 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
10292 # Martyn Johnson says this is needed for Ultrix, if the X
10293 # libraries were built with DECnet support. And Karl Berry says
10294 # the Alpha needs dnet_stub (dnet does not exist).
10295 ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11"
10296 cat >conftest.$ac_ext <<_ACEOF
10297 #line 10297 "configure"
10298 #include "confdefs.h"
10300 /* Override any gcc2 internal prototype to avoid an error. */
10304 /* We use char because int might match the return type of a gcc2
10305 builtin and then its argument prototype would still apply. */
10306 char XOpenDisplay ();
10315 rm -f conftest.$ac_objext conftest$ac_exeext
10316 if { (eval echo "$as_me:10316: \"$ac_link\"") >&5
10317 (eval $ac_link) 2>&5
10319 echo "$as_me:10319: \$? = $ac_status" >&5
10320 (exit $ac_status); } &&
10321 { ac_try='test -s conftest$ac_exeext'
10322 { (eval echo "$as_me:10322: \"$ac_try\"") >&5
10323 (eval $ac_try) 2>&5
10325 echo "$as_me:10325: \$? = $ac_status" >&5
10326 (exit $ac_status); }; }; then
10329 echo "$as_me: failed program was:" >&5
10330 cat conftest.$ac_ext >&5
10331 echo "$as_me:10331: checking for dnet_ntoa in -ldnet" >&5
10332 echo $ECHO_N "checking for dnet_ntoa in -ldnet... $ECHO_C" >&6
10333 if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then
10334 echo $ECHO_N "(cached) $ECHO_C" >&6
10336 ac_check_lib_save_LIBS=$LIBS
10337 LIBS="-ldnet $LIBS"
10338 cat >conftest.$ac_ext <<_ACEOF
10339 #line 10339 "configure"
10340 #include "confdefs.h"
10342 /* Override any gcc2 internal prototype to avoid an error. */
10346 /* We use char because int might match the return type of a gcc2
10347 builtin and then its argument prototype would still apply. */
10357 rm -f conftest.$ac_objext conftest$ac_exeext
10358 if { (eval echo "$as_me:10358: \"$ac_link\"") >&5
10359 (eval $ac_link) 2>&5
10361 echo "$as_me:10361: \$? = $ac_status" >&5
10362 (exit $ac_status); } &&
10363 { ac_try='test -s conftest$ac_exeext'
10364 { (eval echo "$as_me:10364: \"$ac_try\"") >&5
10365 (eval $ac_try) 2>&5
10367 echo "$as_me:10367: \$? = $ac_status" >&5
10368 (exit $ac_status); }; }; then
10369 ac_cv_lib_dnet_dnet_ntoa=yes
10371 echo "$as_me: failed program was:" >&5
10372 cat conftest.$ac_ext >&5
10373 ac_cv_lib_dnet_dnet_ntoa=no
10375 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10376 LIBS=$ac_check_lib_save_LIBS
10378 echo "$as_me:10378: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
10379 echo "${ECHO_T}$ac_cv_lib_dnet_dnet_ntoa" >&6
10380 if test $ac_cv_lib_dnet_dnet_ntoa = yes; then
10381 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
10384 if test $ac_cv_lib_dnet_dnet_ntoa = no; then
10385 echo "$as_me:10385: checking for dnet_ntoa in -ldnet_stub" >&5
10386 echo $ECHO_N "checking for dnet_ntoa in -ldnet_stub... $ECHO_C" >&6
10387 if test "${ac_cv_lib_dnet_stub_dnet_ntoa+set}" = set; then
10388 echo $ECHO_N "(cached) $ECHO_C" >&6
10390 ac_check_lib_save_LIBS=$LIBS
10391 LIBS="-ldnet_stub $LIBS"
10392 cat >conftest.$ac_ext <<_ACEOF
10393 #line 10393 "configure"
10394 #include "confdefs.h"
10396 /* Override any gcc2 internal prototype to avoid an error. */
10400 /* We use char because int might match the return type of a gcc2
10401 builtin and then its argument prototype would still apply. */
10411 rm -f conftest.$ac_objext conftest$ac_exeext
10412 if { (eval echo "$as_me:10412: \"$ac_link\"") >&5
10413 (eval $ac_link) 2>&5
10415 echo "$as_me:10415: \$? = $ac_status" >&5
10416 (exit $ac_status); } &&
10417 { ac_try='test -s conftest$ac_exeext'
10418 { (eval echo "$as_me:10418: \"$ac_try\"") >&5
10419 (eval $ac_try) 2>&5
10421 echo "$as_me:10421: \$? = $ac_status" >&5
10422 (exit $ac_status); }; }; then
10423 ac_cv_lib_dnet_stub_dnet_ntoa=yes
10425 echo "$as_me: failed program was:" >&5
10426 cat conftest.$ac_ext >&5
10427 ac_cv_lib_dnet_stub_dnet_ntoa=no
10429 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10430 LIBS=$ac_check_lib_save_LIBS
10432 echo "$as_me:10432: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5
10433 echo "${ECHO_T}$ac_cv_lib_dnet_stub_dnet_ntoa" >&6
10434 if test $ac_cv_lib_dnet_stub_dnet_ntoa = yes; then
10435 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
10440 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10441 LIBS="$ac_xsave_LIBS"
10443 # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT,
10444 # to get the SysV transport functions.
10445 # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4)
10447 # The nsl library prevents programs from opening the X display
10448 # on Irix 5.2, according to T.E. Dickey.
10449 # The functions gethostbyname, getservbyname, and inet_addr are
10450 # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking.
10451 echo "$as_me:10451: checking for gethostbyname" >&5
10452 echo $ECHO_N "checking for gethostbyname... $ECHO_C" >&6
10453 if test "${ac_cv_func_gethostbyname+set}" = set; then
10454 echo $ECHO_N "(cached) $ECHO_C" >&6
10456 cat >conftest.$ac_ext <<_ACEOF
10457 #line 10457 "configure"
10458 #include "confdefs.h"
10459 /* System header to define __stub macros and hopefully few prototypes,
10460 which can conflict with char gethostbyname (); below. */
10461 #include <assert.h>
10462 /* Override any gcc2 internal prototype to avoid an error. */
10466 /* We use char because int might match the return type of a gcc2
10467 builtin and then its argument prototype would still apply. */
10468 char gethostbyname ();
10474 /* The GNU C library defines this for functions which it implements
10475 to always fail with ENOSYS. Some functions are actually named
10476 something starting with __ and the normal name is an alias. */
10477 #if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
10487 rm -f conftest.$ac_objext conftest$ac_exeext
10488 if { (eval echo "$as_me:10488: \"$ac_link\"") >&5
10489 (eval $ac_link) 2>&5
10491 echo "$as_me:10491: \$? = $ac_status" >&5
10492 (exit $ac_status); } &&
10493 { ac_try='test -s conftest$ac_exeext'
10494 { (eval echo "$as_me:10494: \"$ac_try\"") >&5
10495 (eval $ac_try) 2>&5
10497 echo "$as_me:10497: \$? = $ac_status" >&5
10498 (exit $ac_status); }; }; then
10499 ac_cv_func_gethostbyname=yes
10501 echo "$as_me: failed program was:" >&5
10502 cat conftest.$ac_ext >&5
10503 ac_cv_func_gethostbyname=no
10505 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10507 echo "$as_me:10507: result: $ac_cv_func_gethostbyname" >&5
10508 echo "${ECHO_T}$ac_cv_func_gethostbyname" >&6
10510 if test $ac_cv_func_gethostbyname = no; then
10511 echo "$as_me:10511: checking for gethostbyname in -lnsl" >&5
10512 echo $ECHO_N "checking for gethostbyname in -lnsl... $ECHO_C" >&6
10513 if test "${ac_cv_lib_nsl_gethostbyname+set}" = set; then
10514 echo $ECHO_N "(cached) $ECHO_C" >&6
10516 ac_check_lib_save_LIBS=$LIBS
10518 cat >conftest.$ac_ext <<_ACEOF
10519 #line 10519 "configure"
10520 #include "confdefs.h"
10522 /* Override any gcc2 internal prototype to avoid an error. */
10526 /* We use char because int might match the return type of a gcc2
10527 builtin and then its argument prototype would still apply. */
10528 char gethostbyname ();
10537 rm -f conftest.$ac_objext conftest$ac_exeext
10538 if { (eval echo "$as_me:10538: \"$ac_link\"") >&5
10539 (eval $ac_link) 2>&5
10541 echo "$as_me:10541: \$? = $ac_status" >&5
10542 (exit $ac_status); } &&
10543 { ac_try='test -s conftest$ac_exeext'
10544 { (eval echo "$as_me:10544: \"$ac_try\"") >&5
10545 (eval $ac_try) 2>&5
10547 echo "$as_me:10547: \$? = $ac_status" >&5
10548 (exit $ac_status); }; }; then
10549 ac_cv_lib_nsl_gethostbyname=yes
10551 echo "$as_me: failed program was:" >&5
10552 cat conftest.$ac_ext >&5
10553 ac_cv_lib_nsl_gethostbyname=no
10555 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10556 LIBS=$ac_check_lib_save_LIBS
10558 echo "$as_me:10558: result: $ac_cv_lib_nsl_gethostbyname" >&5
10559 echo "${ECHO_T}$ac_cv_lib_nsl_gethostbyname" >&6
10560 if test $ac_cv_lib_nsl_gethostbyname = yes; then
10561 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
10564 if test $ac_cv_lib_nsl_gethostbyname = no; then
10565 echo "$as_me:10565: checking for gethostbyname in -lbsd" >&5
10566 echo $ECHO_N "checking for gethostbyname in -lbsd... $ECHO_C" >&6
10567 if test "${ac_cv_lib_bsd_gethostbyname+set}" = set; then
10568 echo $ECHO_N "(cached) $ECHO_C" >&6
10570 ac_check_lib_save_LIBS=$LIBS
10572 cat >conftest.$ac_ext <<_ACEOF
10573 #line 10573 "configure"
10574 #include "confdefs.h"
10576 /* Override any gcc2 internal prototype to avoid an error. */
10580 /* We use char because int might match the return type of a gcc2
10581 builtin and then its argument prototype would still apply. */
10582 char gethostbyname ();
10591 rm -f conftest.$ac_objext conftest$ac_exeext
10592 if { (eval echo "$as_me:10592: \"$ac_link\"") >&5
10593 (eval $ac_link) 2>&5
10595 echo "$as_me:10595: \$? = $ac_status" >&5
10596 (exit $ac_status); } &&
10597 { ac_try='test -s conftest$ac_exeext'
10598 { (eval echo "$as_me:10598: \"$ac_try\"") >&5
10599 (eval $ac_try) 2>&5
10601 echo "$as_me:10601: \$? = $ac_status" >&5
10602 (exit $ac_status); }; }; then
10603 ac_cv_lib_bsd_gethostbyname=yes
10605 echo "$as_me: failed program was:" >&5
10606 cat conftest.$ac_ext >&5
10607 ac_cv_lib_bsd_gethostbyname=no
10609 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10610 LIBS=$ac_check_lib_save_LIBS
10612 echo "$as_me:10612: result: $ac_cv_lib_bsd_gethostbyname" >&5
10613 echo "${ECHO_T}$ac_cv_lib_bsd_gethostbyname" >&6
10614 if test $ac_cv_lib_bsd_gethostbyname = yes; then
10615 X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd"
10621 # lieder@skyler.mavd.honeywell.com says without -lsocket,
10622 # socket/setsockopt and other routines are undefined under SCO ODT
10623 # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary
10624 # on later versions), says Simon Leinen: it contains gethostby*
10625 # variants that don't use the nameserver (or something). -lsocket
10626 # must be given before -lnsl if both are needed. We assume that
10627 # if connect needs -lnsl, so does gethostbyname.
10628 echo "$as_me:10628: checking for connect" >&5
10629 echo $ECHO_N "checking for connect... $ECHO_C" >&6
10630 if test "${ac_cv_func_connect+set}" = set; then
10631 echo $ECHO_N "(cached) $ECHO_C" >&6
10633 cat >conftest.$ac_ext <<_ACEOF
10634 #line 10634 "configure"
10635 #include "confdefs.h"
10636 /* System header to define __stub macros and hopefully few prototypes,
10637 which can conflict with char connect (); below. */
10638 #include <assert.h>
10639 /* Override any gcc2 internal prototype to avoid an error. */
10643 /* We use char because int might match the return type of a gcc2
10644 builtin and then its argument prototype would still apply. */
10651 /* The GNU C library defines this for functions which it implements
10652 to always fail with ENOSYS. Some functions are actually named
10653 something starting with __ and the normal name is an alias. */
10654 #if defined (__stub_connect) || defined (__stub___connect)
10664 rm -f conftest.$ac_objext conftest$ac_exeext
10665 if { (eval echo "$as_me:10665: \"$ac_link\"") >&5
10666 (eval $ac_link) 2>&5
10668 echo "$as_me:10668: \$? = $ac_status" >&5
10669 (exit $ac_status); } &&
10670 { ac_try='test -s conftest$ac_exeext'
10671 { (eval echo "$as_me:10671: \"$ac_try\"") >&5
10672 (eval $ac_try) 2>&5
10674 echo "$as_me:10674: \$? = $ac_status" >&5
10675 (exit $ac_status); }; }; then
10676 ac_cv_func_connect=yes
10678 echo "$as_me: failed program was:" >&5
10679 cat conftest.$ac_ext >&5
10680 ac_cv_func_connect=no
10682 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10684 echo "$as_me:10684: result: $ac_cv_func_connect" >&5
10685 echo "${ECHO_T}$ac_cv_func_connect" >&6
10687 if test $ac_cv_func_connect = no; then
10688 echo "$as_me:10688: checking for connect in -lsocket" >&5
10689 echo $ECHO_N "checking for connect in -lsocket... $ECHO_C" >&6
10690 if test "${ac_cv_lib_socket_connect+set}" = set; then
10691 echo $ECHO_N "(cached) $ECHO_C" >&6
10693 ac_check_lib_save_LIBS=$LIBS
10694 LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
10695 cat >conftest.$ac_ext <<_ACEOF
10696 #line 10696 "configure"
10697 #include "confdefs.h"
10699 /* Override any gcc2 internal prototype to avoid an error. */
10703 /* We use char because int might match the return type of a gcc2
10704 builtin and then its argument prototype would still apply. */
10714 rm -f conftest.$ac_objext conftest$ac_exeext
10715 if { (eval echo "$as_me:10715: \"$ac_link\"") >&5
10716 (eval $ac_link) 2>&5
10718 echo "$as_me:10718: \$? = $ac_status" >&5
10719 (exit $ac_status); } &&
10720 { ac_try='test -s conftest$ac_exeext'
10721 { (eval echo "$as_me:10721: \"$ac_try\"") >&5
10722 (eval $ac_try) 2>&5
10724 echo "$as_me:10724: \$? = $ac_status" >&5
10725 (exit $ac_status); }; }; then
10726 ac_cv_lib_socket_connect=yes
10728 echo "$as_me: failed program was:" >&5
10729 cat conftest.$ac_ext >&5
10730 ac_cv_lib_socket_connect=no
10732 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10733 LIBS=$ac_check_lib_save_LIBS
10735 echo "$as_me:10735: result: $ac_cv_lib_socket_connect" >&5
10736 echo "${ECHO_T}$ac_cv_lib_socket_connect" >&6
10737 if test $ac_cv_lib_socket_connect = yes; then
10738 X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS"
10743 # Guillermo Gomez says -lposix is necessary on A/UX.
10744 echo "$as_me:10744: checking for remove" >&5
10745 echo $ECHO_N "checking for remove... $ECHO_C" >&6
10746 if test "${ac_cv_func_remove+set}" = set; then
10747 echo $ECHO_N "(cached) $ECHO_C" >&6
10749 cat >conftest.$ac_ext <<_ACEOF
10750 #line 10750 "configure"
10751 #include "confdefs.h"
10752 /* System header to define __stub macros and hopefully few prototypes,
10753 which can conflict with char remove (); below. */
10754 #include <assert.h>
10755 /* Override any gcc2 internal prototype to avoid an error. */
10759 /* We use char because int might match the return type of a gcc2
10760 builtin and then its argument prototype would still apply. */
10767 /* The GNU C library defines this for functions which it implements
10768 to always fail with ENOSYS. Some functions are actually named
10769 something starting with __ and the normal name is an alias. */
10770 #if defined (__stub_remove) || defined (__stub___remove)
10780 rm -f conftest.$ac_objext conftest$ac_exeext
10781 if { (eval echo "$as_me:10781: \"$ac_link\"") >&5
10782 (eval $ac_link) 2>&5
10784 echo "$as_me:10784: \$? = $ac_status" >&5
10785 (exit $ac_status); } &&
10786 { ac_try='test -s conftest$ac_exeext'
10787 { (eval echo "$as_me:10787: \"$ac_try\"") >&5
10788 (eval $ac_try) 2>&5
10790 echo "$as_me:10790: \$? = $ac_status" >&5
10791 (exit $ac_status); }; }; then
10792 ac_cv_func_remove=yes
10794 echo "$as_me: failed program was:" >&5
10795 cat conftest.$ac_ext >&5
10796 ac_cv_func_remove=no
10798 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10800 echo "$as_me:10800: result: $ac_cv_func_remove" >&5
10801 echo "${ECHO_T}$ac_cv_func_remove" >&6
10803 if test $ac_cv_func_remove = no; then
10804 echo "$as_me:10804: checking for remove in -lposix" >&5
10805 echo $ECHO_N "checking for remove in -lposix... $ECHO_C" >&6
10806 if test "${ac_cv_lib_posix_remove+set}" = set; then
10807 echo $ECHO_N "(cached) $ECHO_C" >&6
10809 ac_check_lib_save_LIBS=$LIBS
10810 LIBS="-lposix $LIBS"
10811 cat >conftest.$ac_ext <<_ACEOF
10812 #line 10812 "configure"
10813 #include "confdefs.h"
10815 /* Override any gcc2 internal prototype to avoid an error. */
10819 /* We use char because int might match the return type of a gcc2
10820 builtin and then its argument prototype would still apply. */
10830 rm -f conftest.$ac_objext conftest$ac_exeext
10831 if { (eval echo "$as_me:10831: \"$ac_link\"") >&5
10832 (eval $ac_link) 2>&5
10834 echo "$as_me:10834: \$? = $ac_status" >&5
10835 (exit $ac_status); } &&
10836 { ac_try='test -s conftest$ac_exeext'
10837 { (eval echo "$as_me:10837: \"$ac_try\"") >&5
10838 (eval $ac_try) 2>&5
10840 echo "$as_me:10840: \$? = $ac_status" >&5
10841 (exit $ac_status); }; }; then
10842 ac_cv_lib_posix_remove=yes
10844 echo "$as_me: failed program was:" >&5
10845 cat conftest.$ac_ext >&5
10846 ac_cv_lib_posix_remove=no
10848 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10849 LIBS=$ac_check_lib_save_LIBS
10851 echo "$as_me:10851: result: $ac_cv_lib_posix_remove" >&5
10852 echo "${ECHO_T}$ac_cv_lib_posix_remove" >&6
10853 if test $ac_cv_lib_posix_remove = yes; then
10854 X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix"
10859 # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
10860 echo "$as_me:10860: checking for shmat" >&5
10861 echo $ECHO_N "checking for shmat... $ECHO_C" >&6
10862 if test "${ac_cv_func_shmat+set}" = set; then
10863 echo $ECHO_N "(cached) $ECHO_C" >&6
10865 cat >conftest.$ac_ext <<_ACEOF
10866 #line 10866 "configure"
10867 #include "confdefs.h"
10868 /* System header to define __stub macros and hopefully few prototypes,
10869 which can conflict with char shmat (); below. */
10870 #include <assert.h>
10871 /* Override any gcc2 internal prototype to avoid an error. */
10875 /* We use char because int might match the return type of a gcc2
10876 builtin and then its argument prototype would still apply. */
10883 /* The GNU C library defines this for functions which it implements
10884 to always fail with ENOSYS. Some functions are actually named
10885 something starting with __ and the normal name is an alias. */
10886 #if defined (__stub_shmat) || defined (__stub___shmat)
10896 rm -f conftest.$ac_objext conftest$ac_exeext
10897 if { (eval echo "$as_me:10897: \"$ac_link\"") >&5
10898 (eval $ac_link) 2>&5
10900 echo "$as_me:10900: \$? = $ac_status" >&5
10901 (exit $ac_status); } &&
10902 { ac_try='test -s conftest$ac_exeext'
10903 { (eval echo "$as_me:10903: \"$ac_try\"") >&5
10904 (eval $ac_try) 2>&5
10906 echo "$as_me:10906: \$? = $ac_status" >&5
10907 (exit $ac_status); }; }; then
10908 ac_cv_func_shmat=yes
10910 echo "$as_me: failed program was:" >&5
10911 cat conftest.$ac_ext >&5
10912 ac_cv_func_shmat=no
10914 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10916 echo "$as_me:10916: result: $ac_cv_func_shmat" >&5
10917 echo "${ECHO_T}$ac_cv_func_shmat" >&6
10919 if test $ac_cv_func_shmat = no; then
10920 echo "$as_me:10920: checking for shmat in -lipc" >&5
10921 echo $ECHO_N "checking for shmat in -lipc... $ECHO_C" >&6
10922 if test "${ac_cv_lib_ipc_shmat+set}" = set; then
10923 echo $ECHO_N "(cached) $ECHO_C" >&6
10925 ac_check_lib_save_LIBS=$LIBS
10927 cat >conftest.$ac_ext <<_ACEOF
10928 #line 10928 "configure"
10929 #include "confdefs.h"
10931 /* Override any gcc2 internal prototype to avoid an error. */
10935 /* We use char because int might match the return type of a gcc2
10936 builtin and then its argument prototype would still apply. */
10946 rm -f conftest.$ac_objext conftest$ac_exeext
10947 if { (eval echo "$as_me:10947: \"$ac_link\"") >&5
10948 (eval $ac_link) 2>&5
10950 echo "$as_me:10950: \$? = $ac_status" >&5
10951 (exit $ac_status); } &&
10952 { ac_try='test -s conftest$ac_exeext'
10953 { (eval echo "$as_me:10953: \"$ac_try\"") >&5
10954 (eval $ac_try) 2>&5
10956 echo "$as_me:10956: \$? = $ac_status" >&5
10957 (exit $ac_status); }; }; then
10958 ac_cv_lib_ipc_shmat=yes
10960 echo "$as_me: failed program was:" >&5
10961 cat conftest.$ac_ext >&5
10962 ac_cv_lib_ipc_shmat=no
10964 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10965 LIBS=$ac_check_lib_save_LIBS
10967 echo "$as_me:10967: result: $ac_cv_lib_ipc_shmat" >&5
10968 echo "${ECHO_T}$ac_cv_lib_ipc_shmat" >&6
10969 if test $ac_cv_lib_ipc_shmat = yes; then
10970 X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc"
10976 # Check for libraries that X11R6 Xt/Xaw programs need.
10977 ac_save_LDFLAGS=$LDFLAGS
10978 test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries"
10979 # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
10980 # check for ICE first), but we must link in the order -lSM -lICE or
10981 # we get undefined symbols. So assume we have SM if we have ICE.
10982 # These have to be linked with before -lX11, unlike the other
10983 # libraries we check for below, so use a different variable.
10984 # John Interrante, Karl Berry
10985 echo "$as_me:10985: checking for IceConnectionNumber in -lICE" >&5
10986 echo $ECHO_N "checking for IceConnectionNumber in -lICE... $ECHO_C" >&6
10987 if test "${ac_cv_lib_ICE_IceConnectionNumber+set}" = set; then
10988 echo $ECHO_N "(cached) $ECHO_C" >&6
10990 ac_check_lib_save_LIBS=$LIBS
10991 LIBS="-lICE $X_EXTRA_LIBS $LIBS"
10992 cat >conftest.$ac_ext <<_ACEOF
10993 #line 10993 "configure"
10994 #include "confdefs.h"
10996 /* Override any gcc2 internal prototype to avoid an error. */
11000 /* We use char because int might match the return type of a gcc2
11001 builtin and then its argument prototype would still apply. */
11002 char IceConnectionNumber ();
11006 IceConnectionNumber ();
11011 rm -f conftest.$ac_objext conftest$ac_exeext
11012 if { (eval echo "$as_me:11012: \"$ac_link\"") >&5
11013 (eval $ac_link) 2>&5
11015 echo "$as_me:11015: \$? = $ac_status" >&5
11016 (exit $ac_status); } &&
11017 { ac_try='test -s conftest$ac_exeext'
11018 { (eval echo "$as_me:11018: \"$ac_try\"") >&5
11019 (eval $ac_try) 2>&5
11021 echo "$as_me:11021: \$? = $ac_status" >&5
11022 (exit $ac_status); }; }; then
11023 ac_cv_lib_ICE_IceConnectionNumber=yes
11025 echo "$as_me: failed program was:" >&5
11026 cat conftest.$ac_ext >&5
11027 ac_cv_lib_ICE_IceConnectionNumber=no
11029 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11030 LIBS=$ac_check_lib_save_LIBS
11032 echo "$as_me:11032: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5
11033 echo "${ECHO_T}$ac_cv_lib_ICE_IceConnectionNumber" >&6
11034 if test $ac_cv_lib_ICE_IceConnectionNumber = yes; then
11035 X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
11038 LDFLAGS=$ac_save_LDFLAGS
11042 cf_x_athena=${cf_x_athena:-Xaw}
11044 echo "$as_me:11044: checking if you want to link with Xaw 3d library" >&5
11045 echo $ECHO_N "checking if you want to link with Xaw 3d library... $ECHO_C" >&6
11048 # Check whether --with-Xaw3d or --without-Xaw3d was given.
11049 if test "${with_Xaw3d+set}" = set; then
11050 withval="$with_Xaw3d"
11053 if test "$withval" = yes ; then
11055 echo "$as_me:11055: result: yes" >&5
11056 echo "${ECHO_T}yes" >&6
11058 echo "$as_me:11058: result: no" >&5
11059 echo "${ECHO_T}no" >&6
11062 echo "$as_me:11062: checking if you want to link with neXT Athena library" >&5
11063 echo $ECHO_N "checking if you want to link with neXT Athena library... $ECHO_C" >&6
11066 # Check whether --with-neXtaw or --without-neXtaw was given.
11067 if test "${with_neXtaw+set}" = set; then
11068 withval="$with_neXtaw"
11071 if test "$withval" = yes ; then
11073 echo "$as_me:11073: result: yes" >&5
11074 echo "${ECHO_T}yes" >&6
11076 echo "$as_me:11076: result: no" >&5
11077 echo "${ECHO_T}no" >&6
11080 echo "$as_me:11080: checking if you want to link with Athena-Plus library" >&5
11081 echo $ECHO_N "checking if you want to link with Athena-Plus library... $ECHO_C" >&6
11084 # Check whether --with-XawPlus or --without-XawPlus was given.
11085 if test "${with_XawPlus+set}" = set; then
11086 withval="$with_XawPlus"
11089 if test "$withval" = yes ; then
11090 cf_x_athena=XawPlus
11091 echo "$as_me:11091: result: yes" >&5
11092 echo "${ECHO_T}yes" >&6
11094 echo "$as_me:11094: result: no" >&5
11095 echo "${ECHO_T}no" >&6
11100 if test "$PKG_CONFIG" != none ; then
11102 test "$cf_x_athena" = Xaw && cf_athena_list="xaw8 xaw7 xaw6"
11103 for cf_athena_pkg in \
11106 ${cf_x_athena}-devel \
11107 lib${cf_x_athena} \
11108 lib${cf_x_athena}-devel
11111 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists $cf_athena_pkg; then
11112 test -n "$verbose" && echo " found package $cf_athena_pkg" 1>&6
11114 echo "${as_me:-configure}:11114: testing found package $cf_athena_pkg ..." 1>&5
11116 cf_pkgconfig_incs="`$PKG_CONFIG --cflags $cf_athena_pkg 2>/dev/null`"
11117 cf_pkgconfig_libs="`$PKG_CONFIG --libs $cf_athena_pkg 2>/dev/null`"
11118 test -n "$verbose" && echo " package $cf_athena_pkg CFLAGS: $cf_pkgconfig_incs" 1>&6
11120 echo "${as_me:-configure}:11120: testing package $cf_athena_pkg CFLAGS: $cf_pkgconfig_incs ..." 1>&5
11122 test -n "$verbose" && echo " package $cf_athena_pkg LIBS: $cf_pkgconfig_libs" 1>&6
11124 echo "${as_me:-configure}:11124: testing package $cf_athena_pkg LIBS: $cf_pkgconfig_libs ..." 1>&5
11129 cf_new_extra_cppflags=
11131 for cf_add_cflags in $cf_pkgconfig_incs
11133 case $cf_fix_cppflags in
11135 case $cf_add_cflags in #(vi
11136 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
11137 case $cf_add_cflags in
11139 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11141 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11142 && test -z "${cf_tst_cflags}" \
11143 && cf_fix_cppflags=yes
11145 if test $cf_fix_cppflags = yes ; then
11146 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11148 elif test "${cf_tst_cflags}" = "\"'" ; then
11149 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11154 case "$CPPFLAGS" in
11155 *$cf_add_cflags) #(vi
11158 case $cf_add_cflags in #(vi
11160 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11162 CPPFLAGS=`echo "$CPPFLAGS" | \
11163 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11164 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11168 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
11173 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
11178 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11180 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11182 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11183 && test -z "${cf_tst_cflags}" \
11184 && cf_fix_cppflags=no
11189 if test -n "$cf_new_cflags" ; then
11191 CFLAGS="$CFLAGS $cf_new_cflags"
11194 if test -n "$cf_new_cppflags" ; then
11196 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
11199 if test -n "$cf_new_extra_cppflags" ; then
11201 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
11204 LIBS="$cf_pkgconfig_libs $LIBS"
11206 cf_x_athena_lib="$cf_pkgconfig_libs"
11208 cf_x_athena_LIBS=`echo "HAVE_LIB_$cf_x_athena" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
11210 cat >>confdefs.h <<EOF
11211 #define $cf_x_athena_LIBS 1
11214 echo "$as_me:11214: checking for usable $cf_x_athena/Xmu package" >&5
11215 echo $ECHO_N "checking for usable $cf_x_athena/Xmu package... $ECHO_C" >&6
11216 if test "${cf_cv_xaw_compat+set}" = set; then
11217 echo $ECHO_N "(cached) $ECHO_C" >&6
11220 cat >conftest.$ac_ext <<_ACEOF
11221 #line 11221 "configure"
11222 #include "confdefs.h"
11224 #include <X11/Xmu/CharSet.h>
11230 int check = XmuCompareISOLatin1("big", "small")
11236 rm -f conftest.$ac_objext conftest$ac_exeext
11237 if { (eval echo "$as_me:11237: \"$ac_link\"") >&5
11238 (eval $ac_link) 2>&5
11240 echo "$as_me:11240: \$? = $ac_status" >&5
11241 (exit $ac_status); } &&
11242 { ac_try='test -s conftest$ac_exeext'
11243 { (eval echo "$as_me:11243: \"$ac_try\"") >&5
11244 (eval $ac_try) 2>&5
11246 echo "$as_me:11246: \$? = $ac_status" >&5
11247 (exit $ac_status); }; }; then
11248 cf_cv_xaw_compat=yes
11250 echo "$as_me: failed program was:" >&5
11251 cat conftest.$ac_ext >&5
11252 cf_cv_xaw_compat=no
11254 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11256 echo "$as_me:11256: result: $cf_cv_xaw_compat" >&5
11257 echo "${ECHO_T}$cf_cv_xaw_compat" >&6
11259 if test "$cf_cv_xaw_compat" = no
11261 # workaround for broken ".pc" files...
11262 case "$cf_x_athena_lib" in #(vi
11266 test -n "$verbose" && echo " work around broken package" 1>&6
11268 echo "${as_me:-configure}:11268: testing work around broken package ..." 1>&5
11270 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xmu; then
11271 test -n "$verbose" && echo " found package xmu" 1>&6
11273 echo "${as_me:-configure}:11273: testing found package xmu ..." 1>&5
11275 cf_pkgconfig_incs="`$PKG_CONFIG --cflags xmu 2>/dev/null`"
11276 cf_pkgconfig_libs="`$PKG_CONFIG --libs xmu 2>/dev/null`"
11277 test -n "$verbose" && echo " package xmu CFLAGS: $cf_pkgconfig_incs" 1>&6
11279 echo "${as_me:-configure}:11279: testing package xmu CFLAGS: $cf_pkgconfig_incs ..." 1>&5
11281 test -n "$verbose" && echo " package xmu LIBS: $cf_pkgconfig_libs" 1>&6
11283 echo "${as_me:-configure}:11283: testing package xmu LIBS: $cf_pkgconfig_libs ..." 1>&5
11288 cf_new_extra_cppflags=
11290 for cf_add_cflags in $cf_pkgconfig_incs
11292 case $cf_fix_cppflags in
11294 case $cf_add_cflags in #(vi
11295 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
11296 case $cf_add_cflags in
11298 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11300 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11301 && test -z "${cf_tst_cflags}" \
11302 && cf_fix_cppflags=yes
11304 if test $cf_fix_cppflags = yes ; then
11305 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11307 elif test "${cf_tst_cflags}" = "\"'" ; then
11308 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11313 case "$CPPFLAGS" in
11314 *$cf_add_cflags) #(vi
11317 case $cf_add_cflags in #(vi
11319 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11321 CPPFLAGS=`echo "$CPPFLAGS" | \
11322 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11323 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11327 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
11332 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
11337 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11339 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11341 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11342 && test -z "${cf_tst_cflags}" \
11343 && cf_fix_cppflags=no
11348 if test -n "$cf_new_cflags" ; then
11350 CFLAGS="$CFLAGS $cf_new_cflags"
11353 if test -n "$cf_new_cppflags" ; then
11355 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
11358 if test -n "$cf_new_extra_cppflags" ; then
11360 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
11363 LIBS="$cf_pkgconfig_libs $LIBS"
11367 test -n "$verbose" && echo " ...before $LIBS" 1>&6
11369 echo "${as_me:-configure}:11369: testing ...before $LIBS ..." 1>&5
11371 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s,-lXt ,-lXt -lXmu ," -e 's/ / /g'`
11372 test -n "$verbose" && echo " ...after $LIBS" 1>&6
11374 echo "${as_me:-configure}:11374: testing ...after $LIBS ..." 1>&5
11390 if test -z "$cf_x_athena_lib" ; then
11392 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists Xext; then
11393 test -n "$verbose" && echo " found package Xext" 1>&6
11395 echo "${as_me:-configure}:11395: testing found package Xext ..." 1>&5
11397 cf_pkgconfig_incs="`$PKG_CONFIG --cflags Xext 2>/dev/null`"
11398 cf_pkgconfig_libs="`$PKG_CONFIG --libs Xext 2>/dev/null`"
11399 test -n "$verbose" && echo " package Xext CFLAGS: $cf_pkgconfig_incs" 1>&6
11401 echo "${as_me:-configure}:11401: testing package Xext CFLAGS: $cf_pkgconfig_incs ..." 1>&5
11403 test -n "$verbose" && echo " package Xext LIBS: $cf_pkgconfig_libs" 1>&6
11405 echo "${as_me:-configure}:11405: testing package Xext LIBS: $cf_pkgconfig_libs ..." 1>&5
11410 cf_new_extra_cppflags=
11412 for cf_add_cflags in $cf_pkgconfig_incs
11414 case $cf_fix_cppflags in
11416 case $cf_add_cflags in #(vi
11417 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
11418 case $cf_add_cflags in
11420 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11422 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11423 && test -z "${cf_tst_cflags}" \
11424 && cf_fix_cppflags=yes
11426 if test $cf_fix_cppflags = yes ; then
11427 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11429 elif test "${cf_tst_cflags}" = "\"'" ; then
11430 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11435 case "$CPPFLAGS" in
11436 *$cf_add_cflags) #(vi
11439 case $cf_add_cflags in #(vi
11441 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11443 CPPFLAGS=`echo "$CPPFLAGS" | \
11444 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11445 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11449 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
11454 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
11459 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11461 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11463 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11464 && test -z "${cf_tst_cflags}" \
11465 && cf_fix_cppflags=no
11470 if test -n "$cf_new_cflags" ; then
11472 CFLAGS="$CFLAGS $cf_new_cflags"
11475 if test -n "$cf_new_cppflags" ; then
11477 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
11480 if test -n "$cf_new_extra_cppflags" ; then
11482 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
11485 LIBS="$cf_pkgconfig_libs $LIBS"
11489 echo "$as_me:11489: checking for XextCreateExtension in -lXext" >&5
11490 echo $ECHO_N "checking for XextCreateExtension in -lXext... $ECHO_C" >&6
11491 if test "${ac_cv_lib_Xext_XextCreateExtension+set}" = set; then
11492 echo $ECHO_N "(cached) $ECHO_C" >&6
11494 ac_check_lib_save_LIBS=$LIBS
11495 LIBS="-lXext $LIBS"
11496 cat >conftest.$ac_ext <<_ACEOF
11497 #line 11497 "configure"
11498 #include "confdefs.h"
11500 /* Override any gcc2 internal prototype to avoid an error. */
11504 /* We use char because int might match the return type of a gcc2
11505 builtin and then its argument prototype would still apply. */
11506 char XextCreateExtension ();
11510 XextCreateExtension ();
11515 rm -f conftest.$ac_objext conftest$ac_exeext
11516 if { (eval echo "$as_me:11516: \"$ac_link\"") >&5
11517 (eval $ac_link) 2>&5
11519 echo "$as_me:11519: \$? = $ac_status" >&5
11520 (exit $ac_status); } &&
11521 { ac_try='test -s conftest$ac_exeext'
11522 { (eval echo "$as_me:11522: \"$ac_try\"") >&5
11523 (eval $ac_try) 2>&5
11525 echo "$as_me:11525: \$? = $ac_status" >&5
11526 (exit $ac_status); }; }; then
11527 ac_cv_lib_Xext_XextCreateExtension=yes
11529 echo "$as_me: failed program was:" >&5
11530 cat conftest.$ac_ext >&5
11531 ac_cv_lib_Xext_XextCreateExtension=no
11533 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11534 LIBS=$ac_check_lib_save_LIBS
11536 echo "$as_me:11536: result: $ac_cv_lib_Xext_XextCreateExtension" >&5
11537 echo "${ECHO_T}$ac_cv_lib_Xext_XextCreateExtension" >&6
11538 if test $ac_cv_lib_Xext_XextCreateExtension = yes; then
11539 LIBS="-lXext $LIBS"
11546 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xt; then
11547 test -n "$verbose" && echo " found package xt" 1>&6
11549 echo "${as_me:-configure}:11549: testing found package xt ..." 1>&5
11551 cf_pkgconfig_incs="`$PKG_CONFIG --cflags xt 2>/dev/null`"
11552 cf_pkgconfig_libs="`$PKG_CONFIG --libs xt 2>/dev/null`"
11553 test -n "$verbose" && echo " package xt CFLAGS: $cf_pkgconfig_incs" 1>&6
11555 echo "${as_me:-configure}:11555: testing package xt CFLAGS: $cf_pkgconfig_incs ..." 1>&5
11557 test -n "$verbose" && echo " package xt LIBS: $cf_pkgconfig_libs" 1>&6
11559 echo "${as_me:-configure}:11559: testing package xt LIBS: $cf_pkgconfig_libs ..." 1>&5
11564 cf_new_extra_cppflags=
11566 for cf_add_cflags in $cf_pkgconfig_incs
11568 case $cf_fix_cppflags in
11570 case $cf_add_cflags in #(vi
11571 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
11572 case $cf_add_cflags in
11574 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11576 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11577 && test -z "${cf_tst_cflags}" \
11578 && cf_fix_cppflags=yes
11580 if test $cf_fix_cppflags = yes ; then
11581 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11583 elif test "${cf_tst_cflags}" = "\"'" ; then
11584 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11589 case "$CPPFLAGS" in
11590 *$cf_add_cflags) #(vi
11593 case $cf_add_cflags in #(vi
11595 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11597 CPPFLAGS=`echo "$CPPFLAGS" | \
11598 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11599 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11603 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
11608 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
11613 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11615 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11617 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11618 && test -z "${cf_tst_cflags}" \
11619 && cf_fix_cppflags=no
11624 if test -n "$cf_new_cflags" ; then
11626 CFLAGS="$CFLAGS $cf_new_cflags"
11629 if test -n "$cf_new_cppflags" ; then
11631 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
11634 if test -n "$cf_new_extra_cppflags" ; then
11636 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
11639 LIBS="$cf_pkgconfig_libs $LIBS"
11641 case "x$LIBS" in #(vi
11645 # we have an "xt" package, but it may omit Xt's dependency on X11
11646 echo "$as_me:11646: checking for usable X dependency" >&5
11647 echo $ECHO_N "checking for usable X dependency... $ECHO_C" >&6
11648 if test "${cf_cv_xt_x11_compat+set}" = set; then
11649 echo $ECHO_N "(cached) $ECHO_C" >&6
11652 cat >conftest.$ac_ext <<_ACEOF
11653 #line 11653 "configure"
11654 #include "confdefs.h"
11656 #include <X11/Xlib.h>
11662 int rc1 = XDrawLine((Display*) 0, (Drawable) 0, (GC) 0, 0, 0, 0, 0);
11663 int rc2 = XClearWindow((Display*) 0, (Window) 0);
11664 int rc3 = XMoveWindow((Display*) 0, (Window) 0, 0, 0);
11665 int rc4 = XMoveResizeWindow((Display*)0, (Window)0, 0, 0, 0, 0);
11671 rm -f conftest.$ac_objext conftest$ac_exeext
11672 if { (eval echo "$as_me:11672: \"$ac_link\"") >&5
11673 (eval $ac_link) 2>&5
11675 echo "$as_me:11675: \$? = $ac_status" >&5
11676 (exit $ac_status); } &&
11677 { ac_try='test -s conftest$ac_exeext'
11678 { (eval echo "$as_me:11678: \"$ac_try\"") >&5
11679 (eval $ac_try) 2>&5
11681 echo "$as_me:11681: \$? = $ac_status" >&5
11682 (exit $ac_status); }; }; then
11683 cf_cv_xt_x11_compat=yes
11685 echo "$as_me: failed program was:" >&5
11686 cat conftest.$ac_ext >&5
11687 cf_cv_xt_x11_compat=no
11689 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11691 echo "$as_me:11691: result: $cf_cv_xt_x11_compat" >&5
11692 echo "${ECHO_T}$cf_cv_xt_x11_compat" >&6
11693 if test "$cf_cv_xt_x11_compat" = no
11695 test -n "$verbose" && echo " work around broken X11 dependency" 1>&6
11697 echo "${as_me:-configure}:11697: testing work around broken X11 dependency ..." 1>&5
11699 # 2010/11/19 - good enough until a working Xt on Xcb is delivered.
11701 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists x11; then
11702 test -n "$verbose" && echo " found package x11" 1>&6
11704 echo "${as_me:-configure}:11704: testing found package x11 ..." 1>&5
11706 cf_pkgconfig_incs="`$PKG_CONFIG --cflags x11 2>/dev/null`"
11707 cf_pkgconfig_libs="`$PKG_CONFIG --libs x11 2>/dev/null`"
11708 test -n "$verbose" && echo " package x11 CFLAGS: $cf_pkgconfig_incs" 1>&6
11710 echo "${as_me:-configure}:11710: testing package x11 CFLAGS: $cf_pkgconfig_incs ..." 1>&5
11712 test -n "$verbose" && echo " package x11 LIBS: $cf_pkgconfig_libs" 1>&6
11714 echo "${as_me:-configure}:11714: testing package x11 LIBS: $cf_pkgconfig_libs ..." 1>&5
11719 cf_new_extra_cppflags=
11721 for cf_add_cflags in $cf_pkgconfig_incs
11723 case $cf_fix_cppflags in
11725 case $cf_add_cflags in #(vi
11726 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
11727 case $cf_add_cflags in
11729 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11731 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11732 && test -z "${cf_tst_cflags}" \
11733 && cf_fix_cppflags=yes
11735 if test $cf_fix_cppflags = yes ; then
11736 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11738 elif test "${cf_tst_cflags}" = "\"'" ; then
11739 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11744 case "$CPPFLAGS" in
11745 *$cf_add_cflags) #(vi
11748 case $cf_add_cflags in #(vi
11750 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11752 CPPFLAGS=`echo "$CPPFLAGS" | \
11753 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11754 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11758 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
11763 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
11768 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11770 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11772 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11773 && test -z "${cf_tst_cflags}" \
11774 && cf_fix_cppflags=no
11779 if test -n "$cf_new_cflags" ; then
11781 CFLAGS="$CFLAGS $cf_new_cflags"
11784 if test -n "$cf_new_cppflags" ; then
11786 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
11789 if test -n "$cf_new_extra_cppflags" ; then
11791 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
11794 LIBS="$cf_pkgconfig_libs $LIBS"
11798 test -n "$verbose" && echo " ...before $LIBS" 1>&6
11800 echo "${as_me:-configure}:11800: testing ...before $LIBS ..." 1>&5
11802 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s,-lXt ,-lXt -lX11 ," -e 's/ / /g'`
11803 test -n "$verbose" && echo " ...after $LIBS" 1>&6
11805 echo "${as_me:-configure}:11805: testing ...after $LIBS ..." 1>&5
11813 echo "$as_me:11813: checking for usable X Toolkit package" >&5
11814 echo $ECHO_N "checking for usable X Toolkit package... $ECHO_C" >&6
11815 if test "${cf_cv_xt_ice_compat+set}" = set; then
11816 echo $ECHO_N "(cached) $ECHO_C" >&6
11819 cat >conftest.$ac_ext <<_ACEOF
11820 #line 11820 "configure"
11821 #include "confdefs.h"
11823 #include <X11/Shell.h>
11828 int num = IceConnectionNumber(0)
11834 rm -f conftest.$ac_objext conftest$ac_exeext
11835 if { (eval echo "$as_me:11835: \"$ac_link\"") >&5
11836 (eval $ac_link) 2>&5
11838 echo "$as_me:11838: \$? = $ac_status" >&5
11839 (exit $ac_status); } &&
11840 { ac_try='test -s conftest$ac_exeext'
11841 { (eval echo "$as_me:11841: \"$ac_try\"") >&5
11842 (eval $ac_try) 2>&5
11844 echo "$as_me:11844: \$? = $ac_status" >&5
11845 (exit $ac_status); }; }; then
11846 cf_cv_xt_ice_compat=yes
11848 echo "$as_me: failed program was:" >&5
11849 cat conftest.$ac_ext >&5
11850 cf_cv_xt_ice_compat=no
11852 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11854 echo "$as_me:11854: result: $cf_cv_xt_ice_compat" >&5
11855 echo "${ECHO_T}$cf_cv_xt_ice_compat" >&6
11857 if test "$cf_cv_xt_ice_compat" = no
11859 # workaround for broken ".pc" files used for X Toolkit.
11860 case "x$X_PRE_LIBS" in #(vi
11862 case "x$LIBS" in #(vi
11866 test -n "$verbose" && echo " work around broken ICE dependency" 1>&6
11868 echo "${as_me:-configure}:11868: testing work around broken ICE dependency ..." 1>&5
11870 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists ice; then
11871 test -n "$verbose" && echo " found package ice" 1>&6
11873 echo "${as_me:-configure}:11873: testing found package ice ..." 1>&5
11875 cf_pkgconfig_incs="`$PKG_CONFIG --cflags ice 2>/dev/null`"
11876 cf_pkgconfig_libs="`$PKG_CONFIG --libs ice 2>/dev/null`"
11877 test -n "$verbose" && echo " package ice CFLAGS: $cf_pkgconfig_incs" 1>&6
11879 echo "${as_me:-configure}:11879: testing package ice CFLAGS: $cf_pkgconfig_incs ..." 1>&5
11881 test -n "$verbose" && echo " package ice LIBS: $cf_pkgconfig_libs" 1>&6
11883 echo "${as_me:-configure}:11883: testing package ice LIBS: $cf_pkgconfig_libs ..." 1>&5
11888 cf_new_extra_cppflags=
11890 for cf_add_cflags in $cf_pkgconfig_incs
11892 case $cf_fix_cppflags in
11894 case $cf_add_cflags in #(vi
11895 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
11896 case $cf_add_cflags in
11898 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11900 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11901 && test -z "${cf_tst_cflags}" \
11902 && cf_fix_cppflags=yes
11904 if test $cf_fix_cppflags = yes ; then
11905 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11907 elif test "${cf_tst_cflags}" = "\"'" ; then
11908 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11913 case "$CPPFLAGS" in
11914 *$cf_add_cflags) #(vi
11917 case $cf_add_cflags in #(vi
11919 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11921 CPPFLAGS=`echo "$CPPFLAGS" | \
11922 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11923 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11927 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
11932 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
11937 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
11939 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11941 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11942 && test -z "${cf_tst_cflags}" \
11943 && cf_fix_cppflags=no
11948 if test -n "$cf_new_cflags" ; then
11950 CFLAGS="$CFLAGS $cf_new_cflags"
11953 if test -n "$cf_new_cppflags" ; then
11955 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
11958 if test -n "$cf_new_extra_cppflags" ; then
11960 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
11963 LIBS="$cf_pkgconfig_libs $LIBS"
11965 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists sm; then
11966 test -n "$verbose" && echo " found package sm" 1>&6
11968 echo "${as_me:-configure}:11968: testing found package sm ..." 1>&5
11970 cf_pkgconfig_incs="`$PKG_CONFIG --cflags sm 2>/dev/null`"
11971 cf_pkgconfig_libs="`$PKG_CONFIG --libs sm 2>/dev/null`"
11972 test -n "$verbose" && echo " package sm CFLAGS: $cf_pkgconfig_incs" 1>&6
11974 echo "${as_me:-configure}:11974: testing package sm CFLAGS: $cf_pkgconfig_incs ..." 1>&5
11976 test -n "$verbose" && echo " package sm LIBS: $cf_pkgconfig_libs" 1>&6
11978 echo "${as_me:-configure}:11978: testing package sm LIBS: $cf_pkgconfig_libs ..." 1>&5
11983 cf_new_extra_cppflags=
11985 for cf_add_cflags in $cf_pkgconfig_incs
11987 case $cf_fix_cppflags in
11989 case $cf_add_cflags in #(vi
11990 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
11991 case $cf_add_cflags in
11993 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11995 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
11996 && test -z "${cf_tst_cflags}" \
11997 && cf_fix_cppflags=yes
11999 if test $cf_fix_cppflags = yes ; then
12000 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
12002 elif test "${cf_tst_cflags}" = "\"'" ; then
12003 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
12008 case "$CPPFLAGS" in
12009 *$cf_add_cflags) #(vi
12012 case $cf_add_cflags in #(vi
12014 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12016 CPPFLAGS=`echo "$CPPFLAGS" | \
12017 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12018 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12022 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
12027 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
12032 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
12034 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
12036 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
12037 && test -z "${cf_tst_cflags}" \
12038 && cf_fix_cppflags=no
12043 if test -n "$cf_new_cflags" ; then
12045 CFLAGS="$CFLAGS $cf_new_cflags"
12048 if test -n "$cf_new_cppflags" ; then
12050 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
12053 if test -n "$cf_new_extra_cppflags" ; then
12055 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
12058 LIBS="$cf_pkgconfig_libs $LIBS"
12066 test -n "$verbose" && echo " ...before $LIBS" 1>&6
12068 echo "${as_me:-configure}:12068: testing ...before $LIBS ..." 1>&5
12070 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s,-lXt ,-lXt $X_PRE_LIBS ," -e 's/ / /g'`
12071 test -n "$verbose" && echo " ...after $LIBS" 1>&6
12073 echo "${as_me:-configure}:12073: testing ...after $LIBS ..." 1>&5
12087 LDFLAGS="$X_LIBS $LDFLAGS"
12089 test -n "$verbose" && echo " checking additions to CFLAGS" 1>&6
12091 echo "${as_me:-configure}:12091: testing checking additions to CFLAGS ..." 1>&5
12093 cf_check_cflags="$CFLAGS"
12094 cf_check_cppflags="$CPPFLAGS"
12099 cf_new_extra_cppflags=
12101 for cf_add_cflags in $X_CFLAGS
12103 case $cf_fix_cppflags in
12105 case $cf_add_cflags in #(vi
12106 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
12107 case $cf_add_cflags in
12109 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
12111 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
12112 && test -z "${cf_tst_cflags}" \
12113 && cf_fix_cppflags=yes
12115 if test $cf_fix_cppflags = yes ; then
12116 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
12118 elif test "${cf_tst_cflags}" = "\"'" ; then
12119 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
12124 case "$CPPFLAGS" in
12125 *$cf_add_cflags) #(vi
12128 case $cf_add_cflags in #(vi
12130 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12132 CPPFLAGS=`echo "$CPPFLAGS" | \
12133 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12134 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12138 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
12143 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
12148 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
12150 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
12152 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
12153 && test -z "${cf_tst_cflags}" \
12154 && cf_fix_cppflags=no
12159 if test -n "$cf_new_cflags" ; then
12160 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
12162 echo "${as_me:-configure}:12162: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
12164 CFLAGS="$CFLAGS $cf_new_cflags"
12167 if test -n "$cf_new_cppflags" ; then
12168 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
12170 echo "${as_me:-configure}:12170: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
12172 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
12175 if test -n "$cf_new_extra_cppflags" ; then
12176 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
12178 echo "${as_me:-configure}:12178: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
12180 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
12183 if test "$cf_check_cflags" != "$CFLAGS" ; then
12184 cat >conftest.$ac_ext <<_ACEOF
12185 #line 12185 "configure"
12186 #include "confdefs.h"
12191 printf("Hello world");
12196 rm -f conftest.$ac_objext conftest$ac_exeext
12197 if { (eval echo "$as_me:12197: \"$ac_link\"") >&5
12198 (eval $ac_link) 2>&5
12200 echo "$as_me:12200: \$? = $ac_status" >&5
12201 (exit $ac_status); } &&
12202 { ac_try='test -s conftest$ac_exeext'
12203 { (eval echo "$as_me:12203: \"$ac_try\"") >&5
12204 (eval $ac_try) 2>&5
12206 echo "$as_me:12206: \$? = $ac_status" >&5
12207 (exit $ac_status); }; }; then
12210 echo "$as_me: failed program was:" >&5
12211 cat conftest.$ac_ext >&5
12212 test -n "$verbose" && echo " test-compile failed. Undoing change to \$CFLAGS" 1>&6
12214 echo "${as_me:-configure}:12214: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5
12216 if test "$cf_check_cppflags" != "$CPPFLAGS" ; then
12217 test -n "$verbose" && echo " but keeping change to \$CPPFLAGS" 1>&6
12219 echo "${as_me:-configure}:12219: testing but keeping change to \$CPPFLAGS ..." 1>&5
12222 CFLAGS="$cf_check_flags"
12224 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12227 echo "$as_me:12227: checking for XOpenDisplay" >&5
12228 echo $ECHO_N "checking for XOpenDisplay... $ECHO_C" >&6
12229 if test "${ac_cv_func_XOpenDisplay+set}" = set; then
12230 echo $ECHO_N "(cached) $ECHO_C" >&6
12232 cat >conftest.$ac_ext <<_ACEOF
12233 #line 12233 "configure"
12234 #include "confdefs.h"
12235 /* System header to define __stub macros and hopefully few prototypes,
12236 which can conflict with char XOpenDisplay (); below. */
12237 #include <assert.h>
12238 /* Override any gcc2 internal prototype to avoid an error. */
12242 /* We use char because int might match the return type of a gcc2
12243 builtin and then its argument prototype would still apply. */
12244 char XOpenDisplay ();
12250 /* The GNU C library defines this for functions which it implements
12251 to always fail with ENOSYS. Some functions are actually named
12252 something starting with __ and the normal name is an alias. */
12253 #if defined (__stub_XOpenDisplay) || defined (__stub___XOpenDisplay)
12263 rm -f conftest.$ac_objext conftest$ac_exeext
12264 if { (eval echo "$as_me:12264: \"$ac_link\"") >&5
12265 (eval $ac_link) 2>&5
12267 echo "$as_me:12267: \$? = $ac_status" >&5
12268 (exit $ac_status); } &&
12269 { ac_try='test -s conftest$ac_exeext'
12270 { (eval echo "$as_me:12270: \"$ac_try\"") >&5
12271 (eval $ac_try) 2>&5
12273 echo "$as_me:12273: \$? = $ac_status" >&5
12274 (exit $ac_status); }; }; then
12275 ac_cv_func_XOpenDisplay=yes
12277 echo "$as_me: failed program was:" >&5
12278 cat conftest.$ac_ext >&5
12279 ac_cv_func_XOpenDisplay=no
12281 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12283 echo "$as_me:12283: result: $ac_cv_func_XOpenDisplay" >&5
12284 echo "${ECHO_T}$ac_cv_func_XOpenDisplay" >&6
12285 if test $ac_cv_func_XOpenDisplay = yes; then
12289 echo "$as_me:12289: checking for XOpenDisplay in -lX11" >&5
12290 echo $ECHO_N "checking for XOpenDisplay in -lX11... $ECHO_C" >&6
12291 if test "${ac_cv_lib_X11_XOpenDisplay+set}" = set; then
12292 echo $ECHO_N "(cached) $ECHO_C" >&6
12294 ac_check_lib_save_LIBS=$LIBS
12295 LIBS="-lX11 $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
12296 cat >conftest.$ac_ext <<_ACEOF
12297 #line 12297 "configure"
12298 #include "confdefs.h"
12300 /* Override any gcc2 internal prototype to avoid an error. */
12304 /* We use char because int might match the return type of a gcc2
12305 builtin and then its argument prototype would still apply. */
12306 char XOpenDisplay ();
12315 rm -f conftest.$ac_objext conftest$ac_exeext
12316 if { (eval echo "$as_me:12316: \"$ac_link\"") >&5
12317 (eval $ac_link) 2>&5
12319 echo "$as_me:12319: \$? = $ac_status" >&5
12320 (exit $ac_status); } &&
12321 { ac_try='test -s conftest$ac_exeext'
12322 { (eval echo "$as_me:12322: \"$ac_try\"") >&5
12323 (eval $ac_try) 2>&5
12325 echo "$as_me:12325: \$? = $ac_status" >&5
12326 (exit $ac_status); }; }; then
12327 ac_cv_lib_X11_XOpenDisplay=yes
12329 echo "$as_me: failed program was:" >&5
12330 cat conftest.$ac_ext >&5
12331 ac_cv_lib_X11_XOpenDisplay=no
12333 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12334 LIBS=$ac_check_lib_save_LIBS
12336 echo "$as_me:12336: result: $ac_cv_lib_X11_XOpenDisplay" >&5
12337 echo "${ECHO_T}$ac_cv_lib_X11_XOpenDisplay" >&6
12338 if test $ac_cv_lib_X11_XOpenDisplay = yes; then
12344 echo "$as_me:12344: checking for XtAppInitialize" >&5
12345 echo $ECHO_N "checking for XtAppInitialize... $ECHO_C" >&6
12346 if test "${ac_cv_func_XtAppInitialize+set}" = set; then
12347 echo $ECHO_N "(cached) $ECHO_C" >&6
12349 cat >conftest.$ac_ext <<_ACEOF
12350 #line 12350 "configure"
12351 #include "confdefs.h"
12352 /* System header to define __stub macros and hopefully few prototypes,
12353 which can conflict with char XtAppInitialize (); below. */
12354 #include <assert.h>
12355 /* Override any gcc2 internal prototype to avoid an error. */
12359 /* We use char because int might match the return type of a gcc2
12360 builtin and then its argument prototype would still apply. */
12361 char XtAppInitialize ();
12367 /* The GNU C library defines this for functions which it implements
12368 to always fail with ENOSYS. Some functions are actually named
12369 something starting with __ and the normal name is an alias. */
12370 #if defined (__stub_XtAppInitialize) || defined (__stub___XtAppInitialize)
12373 f = XtAppInitialize;
12380 rm -f conftest.$ac_objext conftest$ac_exeext
12381 if { (eval echo "$as_me:12381: \"$ac_link\"") >&5
12382 (eval $ac_link) 2>&5
12384 echo "$as_me:12384: \$? = $ac_status" >&5
12385 (exit $ac_status); } &&
12386 { ac_try='test -s conftest$ac_exeext'
12387 { (eval echo "$as_me:12387: \"$ac_try\"") >&5
12388 (eval $ac_try) 2>&5
12390 echo "$as_me:12390: \$? = $ac_status" >&5
12391 (exit $ac_status); }; }; then
12392 ac_cv_func_XtAppInitialize=yes
12394 echo "$as_me: failed program was:" >&5
12395 cat conftest.$ac_ext >&5
12396 ac_cv_func_XtAppInitialize=no
12398 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12400 echo "$as_me:12400: result: $ac_cv_func_XtAppInitialize" >&5
12401 echo "${ECHO_T}$ac_cv_func_XtAppInitialize" >&6
12402 if test $ac_cv_func_XtAppInitialize = yes; then
12406 echo "$as_me:12406: checking for XtAppInitialize in -lXt" >&5
12407 echo $ECHO_N "checking for XtAppInitialize in -lXt... $ECHO_C" >&6
12408 if test "${ac_cv_lib_Xt_XtAppInitialize+set}" = set; then
12409 echo $ECHO_N "(cached) $ECHO_C" >&6
12411 ac_check_lib_save_LIBS=$LIBS
12412 LIBS="-lXt $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
12413 cat >conftest.$ac_ext <<_ACEOF
12414 #line 12414 "configure"
12415 #include "confdefs.h"
12417 /* Override any gcc2 internal prototype to avoid an error. */
12421 /* We use char because int might match the return type of a gcc2
12422 builtin and then its argument prototype would still apply. */
12423 char XtAppInitialize ();
12427 XtAppInitialize ();
12432 rm -f conftest.$ac_objext conftest$ac_exeext
12433 if { (eval echo "$as_me:12433: \"$ac_link\"") >&5
12434 (eval $ac_link) 2>&5
12436 echo "$as_me:12436: \$? = $ac_status" >&5
12437 (exit $ac_status); } &&
12438 { ac_try='test -s conftest$ac_exeext'
12439 { (eval echo "$as_me:12439: \"$ac_try\"") >&5
12440 (eval $ac_try) 2>&5
12442 echo "$as_me:12442: \$? = $ac_status" >&5
12443 (exit $ac_status); }; }; then
12444 ac_cv_lib_Xt_XtAppInitialize=yes
12446 echo "$as_me: failed program was:" >&5
12447 cat conftest.$ac_ext >&5
12448 ac_cv_lib_Xt_XtAppInitialize=no
12450 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12451 LIBS=$ac_check_lib_save_LIBS
12453 echo "$as_me:12453: result: $ac_cv_lib_Xt_XtAppInitialize" >&5
12454 echo "${ECHO_T}$ac_cv_lib_Xt_XtAppInitialize" >&6
12455 if test $ac_cv_lib_Xt_XtAppInitialize = yes; then
12456 cat >>confdefs.h <<\EOF
12457 #define HAVE_LIBXT 1
12461 LIBS="-lXt $X_PRE_LIBS $LIBS $X_EXTRA_LIBS"
12468 if test $cf_have_X_LIBS = no ; then
12469 { echo "$as_me:12469: WARNING: Unable to successfully link X Toolkit library (-lXt) with
12470 test program. You will have to check and add the proper libraries by hand
12472 echo "$as_me: WARNING: Unable to successfully link X Toolkit library (-lXt) with
12473 test program. You will have to check and add the proper libraries by hand
12474 to makefile." >&2;}
12477 cf_x_athena_root=$cf_x_athena
12480 for cf_path in default \
12481 /usr/contrib/X11R6 \
12482 /usr/contrib/X11R5 \
12486 if test -z "$cf_x_athena_inc" ; then
12487 cf_save="$CPPFLAGS"
12488 cf_test=X11/$cf_x_athena_root/SimpleMenu.h
12489 if test $cf_path != default ; then
12490 CPPFLAGS="$cf_save -I$cf_path/include"
12491 echo "$as_me:12491: checking for $cf_test in $cf_path" >&5
12492 echo $ECHO_N "checking for $cf_test in $cf_path... $ECHO_C" >&6
12494 echo "$as_me:12494: checking for $cf_test" >&5
12495 echo $ECHO_N "checking for $cf_test... $ECHO_C" >&6
12497 cat >conftest.$ac_ext <<_ACEOF
12498 #line 12498 "configure"
12499 #include "confdefs.h"
12501 #include <X11/Intrinsic.h>
12502 #include <$cf_test>
12511 rm -f conftest.$ac_objext
12512 if { (eval echo "$as_me:12512: \"$ac_compile\"") >&5
12513 (eval $ac_compile) 2>&5
12515 echo "$as_me:12515: \$? = $ac_status" >&5
12516 (exit $ac_status); } &&
12517 { ac_try='test -s conftest.$ac_objext'
12518 { (eval echo "$as_me:12518: \"$ac_try\"") >&5
12519 (eval $ac_try) 2>&5
12521 echo "$as_me:12521: \$? = $ac_status" >&5
12522 (exit $ac_status); }; }; then
12525 echo "$as_me: failed program was:" >&5
12526 cat conftest.$ac_ext >&5
12529 rm -f conftest.$ac_objext conftest.$ac_ext
12530 echo "$as_me:12530: result: $cf_result" >&5
12531 echo "${ECHO_T}$cf_result" >&6
12532 if test "$cf_result" = yes ; then
12533 cf_x_athena_inc=$cf_path
12536 CPPFLAGS="$cf_save"
12541 if test -z "$cf_x_athena_inc" ; then
12542 { echo "$as_me:12542: WARNING: Unable to successfully find Athena header files with test program" >&5
12543 echo "$as_me: WARNING: Unable to successfully find Athena header files with test program" >&2;}
12544 elif test "$cf_x_athena_inc" != default ; then
12545 CPPFLAGS="$CPPFLAGS -I$cf_x_athena_inc"
12548 cf_x_athena_root=$cf_x_athena
12551 for cf_path in default \
12552 /usr/contrib/X11R6 \
12553 /usr/contrib/X11R5 \
12558 ${cf_x_athena_root} \
12559 ${cf_x_athena_root}7 \
12560 ${cf_x_athena_root}6
12563 "-l$cf_lib -lXmu" \
12564 "-l$cf_lib -lXpm -lXmu" \
12565 "-l${cf_lib}_s -lXmu_s"
12567 if test -z "$cf_x_athena_lib" ; then
12569 cf_test=XawSimpleMenuAddGlobalActions
12570 if test $cf_path != default ; then
12571 LIBS="-L$cf_path/lib $cf_libs $LIBS"
12572 echo "$as_me:12572: checking for $cf_libs in $cf_path" >&5
12573 echo $ECHO_N "checking for $cf_libs in $cf_path... $ECHO_C" >&6
12575 LIBS="$cf_libs $LIBS"
12576 echo "$as_me:12576: checking for $cf_test in $cf_libs" >&5
12577 echo $ECHO_N "checking for $cf_test in $cf_libs... $ECHO_C" >&6
12579 cat >conftest.$ac_ext <<_ACEOF
12580 #line 12580 "configure"
12581 #include "confdefs.h"
12583 #include <X11/Intrinsic.h>
12584 #include <X11/$cf_x_athena_root/SimpleMenu.h>
12590 $cf_test((XtAppContext) 0)
12595 rm -f conftest.$ac_objext conftest$ac_exeext
12596 if { (eval echo "$as_me:12596: \"$ac_link\"") >&5
12597 (eval $ac_link) 2>&5
12599 echo "$as_me:12599: \$? = $ac_status" >&5
12600 (exit $ac_status); } &&
12601 { ac_try='test -s conftest$ac_exeext'
12602 { (eval echo "$as_me:12602: \"$ac_try\"") >&5
12603 (eval $ac_try) 2>&5
12605 echo "$as_me:12605: \$? = $ac_status" >&5
12606 (exit $ac_status); }; }; then
12609 echo "$as_me: failed program was:" >&5
12610 cat conftest.$ac_ext >&5
12613 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12614 echo "$as_me:12614: result: $cf_result" >&5
12615 echo "${ECHO_T}$cf_result" >&6
12616 if test "$cf_result" = yes ; then
12617 cf_x_athena_lib="$cf_libs"
12623 test -n "$cf_x_athena_lib" && break
12627 if test -z "$cf_x_athena_lib" ; then
12628 { { echo "$as_me:12628: error: Unable to successfully link Athena library (-l$cf_x_athena_root) with test program" >&5
12629 echo "$as_me: error: Unable to successfully link Athena library (-l$cf_x_athena_root) with test program" >&2;}
12630 { (exit 1); exit 1; }; }
12633 cf_x_athena_LIBS=`echo "HAVE_LIB_$cf_x_athena" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
12635 cat >>confdefs.h <<EOF
12636 #define $cf_x_athena_LIBS 1
12641 for ac_prog in xcurses-config
12643 # Extract the first word of "$ac_prog", so it can be a program name with args.
12644 set dummy $ac_prog; ac_word=$2
12645 echo "$as_me:12645: checking for $ac_word" >&5
12646 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
12647 if test "${ac_cv_path_XCURSES_CONFIG+set}" = set; then
12648 echo $ECHO_N "(cached) $ECHO_C" >&6
12650 case $XCURSES_CONFIG in
12652 ac_cv_path_XCURSES_CONFIG="$XCURSES_CONFIG" # Let the user override the test with a path.
12655 ac_save_IFS=$IFS; IFS=$ac_path_separator
12657 for ac_dir in $ac_dummy; do
12659 test -z "$ac_dir" && ac_dir=.
12660 if $as_executable_p "$ac_dir/$ac_word"; then
12661 ac_cv_path_XCURSES_CONFIG="$ac_dir/$ac_word"
12662 echo "$as_me:12662: found $ac_dir/$ac_word" >&5
12670 XCURSES_CONFIG=$ac_cv_path_XCURSES_CONFIG
12672 if test -n "$XCURSES_CONFIG"; then
12673 echo "$as_me:12673: result: $XCURSES_CONFIG" >&5
12674 echo "${ECHO_T}$XCURSES_CONFIG" >&6
12676 echo "$as_me:12676: result: no" >&5
12677 echo "${ECHO_T}no" >&6
12680 test -n "$XCURSES_CONFIG" && break
12682 test -n "$XCURSES_CONFIG" || XCURSES_CONFIG="none"
12684 if test "$XCURSES_CONFIG" != none ; then
12686 CPPFLAGS="$CPPFLAGS `$XCURSES_CONFIG --cflags`"
12687 LIBS="`$XCURSES_CONFIG --libs` $LIBS"
12689 cf_cv_lib_XCurses=yes
12693 LDFLAGS="$LDFLAGS $X_LIBS"
12695 test -n "$verbose" && echo " checking additions to CFLAGS" 1>&6
12697 echo "${as_me:-configure}:12697: testing checking additions to CFLAGS ..." 1>&5
12699 cf_check_cflags="$CFLAGS"
12700 cf_check_cppflags="$CPPFLAGS"
12705 cf_new_extra_cppflags=
12707 for cf_add_cflags in $X_CFLAGS
12709 case $cf_fix_cppflags in
12711 case $cf_add_cflags in #(vi
12712 -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi
12713 case $cf_add_cflags in
12715 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
12717 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
12718 && test -z "${cf_tst_cflags}" \
12719 && cf_fix_cppflags=yes
12721 if test $cf_fix_cppflags = yes ; then
12722 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
12724 elif test "${cf_tst_cflags}" = "\"'" ; then
12725 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
12730 case "$CPPFLAGS" in
12731 *$cf_add_cflags) #(vi
12734 case $cf_add_cflags in #(vi
12736 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12738 CPPFLAGS=`echo "$CPPFLAGS" | \
12739 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12740 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12744 cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
12749 cf_new_cflags="$cf_new_cflags $cf_add_cflags"
12754 cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
12756 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
12758 test "${cf_add_cflags}" != "${cf_tst_cflags}" \
12759 && test -z "${cf_tst_cflags}" \
12760 && cf_fix_cppflags=no
12765 if test -n "$cf_new_cflags" ; then
12766 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
12768 echo "${as_me:-configure}:12768: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
12770 CFLAGS="$CFLAGS $cf_new_cflags"
12773 if test -n "$cf_new_cppflags" ; then
12774 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
12776 echo "${as_me:-configure}:12776: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
12778 CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
12781 if test -n "$cf_new_extra_cppflags" ; then
12782 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
12784 echo "${as_me:-configure}:12784: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
12786 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
12789 if test "$cf_check_cflags" != "$CFLAGS" ; then
12790 cat >conftest.$ac_ext <<_ACEOF
12791 #line 12791 "configure"
12792 #include "confdefs.h"
12797 printf("Hello world");
12802 rm -f conftest.$ac_objext conftest$ac_exeext
12803 if { (eval echo "$as_me:12803: \"$ac_link\"") >&5
12804 (eval $ac_link) 2>&5
12806 echo "$as_me:12806: \$? = $ac_status" >&5
12807 (exit $ac_status); } &&
12808 { ac_try='test -s conftest$ac_exeext'
12809 { (eval echo "$as_me:12809: \"$ac_try\"") >&5
12810 (eval $ac_try) 2>&5
12812 echo "$as_me:12812: \$? = $ac_status" >&5
12813 (exit $ac_status); }; }; then
12816 echo "$as_me: failed program was:" >&5
12817 cat conftest.$ac_ext >&5
12818 test -n "$verbose" && echo " test-compile failed. Undoing change to \$CFLAGS" 1>&6
12820 echo "${as_me:-configure}:12820: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5
12822 if test "$cf_check_cppflags" != "$CPPFLAGS" ; then
12823 test -n "$verbose" && echo " but keeping change to \$CPPFLAGS" 1>&6
12825 echo "${as_me:-configure}:12825: testing but keeping change to \$CPPFLAGS ..." 1>&5
12828 CFLAGS="$cf_check_flags"
12830 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12833 echo "$as_me:12833: checking for XOpenDisplay in -lX11" >&5
12834 echo $ECHO_N "checking for XOpenDisplay in -lX11... $ECHO_C" >&6
12835 if test "${ac_cv_lib_X11_XOpenDisplay+set}" = set; then
12836 echo $ECHO_N "(cached) $ECHO_C" >&6
12838 ac_check_lib_save_LIBS=$LIBS
12839 LIBS="-lX11 $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
12840 cat >conftest.$ac_ext <<_ACEOF
12841 #line 12841 "configure"
12842 #include "confdefs.h"
12844 /* Override any gcc2 internal prototype to avoid an error. */
12848 /* We use char because int might match the return type of a gcc2
12849 builtin and then its argument prototype would still apply. */
12850 char XOpenDisplay ();
12859 rm -f conftest.$ac_objext conftest$ac_exeext
12860 if { (eval echo "$as_me:12860: \"$ac_link\"") >&5
12861 (eval $ac_link) 2>&5
12863 echo "$as_me:12863: \$? = $ac_status" >&5
12864 (exit $ac_status); } &&
12865 { ac_try='test -s conftest$ac_exeext'
12866 { (eval echo "$as_me:12866: \"$ac_try\"") >&5
12867 (eval $ac_try) 2>&5
12869 echo "$as_me:12869: \$? = $ac_status" >&5
12870 (exit $ac_status); }; }; then
12871 ac_cv_lib_X11_XOpenDisplay=yes
12873 echo "$as_me: failed program was:" >&5
12874 cat conftest.$ac_ext >&5
12875 ac_cv_lib_X11_XOpenDisplay=no
12877 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12878 LIBS=$ac_check_lib_save_LIBS
12880 echo "$as_me:12880: result: $ac_cv_lib_X11_XOpenDisplay" >&5
12881 echo "${ECHO_T}$ac_cv_lib_X11_XOpenDisplay" >&6
12882 if test $ac_cv_lib_X11_XOpenDisplay = yes; then
12886 echo "$as_me:12886: checking for XCurses library" >&5
12887 echo $ECHO_N "checking for XCurses library... $ECHO_C" >&6
12888 if test "${cf_cv_lib_XCurses+set}" = set; then
12889 echo $ECHO_N "(cached) $ECHO_C" >&6
12892 LIBS="-lXCurses $LIBS"
12893 cat >conftest.$ac_ext <<_ACEOF
12894 #line 12894 "configure"
12895 #include "confdefs.h"
12897 #include <xcurses.h>
12898 char *XCursesProgramName = "test";
12908 rm -f conftest.$ac_objext conftest$ac_exeext
12909 if { (eval echo "$as_me:12909: \"$ac_link\"") >&5
12910 (eval $ac_link) 2>&5
12912 echo "$as_me:12912: \$? = $ac_status" >&5
12913 (exit $ac_status); } &&
12914 { ac_try='test -s conftest$ac_exeext'
12915 { (eval echo "$as_me:12915: \"$ac_try\"") >&5
12916 (eval $ac_try) 2>&5
12918 echo "$as_me:12918: \$? = $ac_status" >&5
12919 (exit $ac_status); }; }; then
12920 cf_cv_lib_XCurses=yes
12922 echo "$as_me: failed program was:" >&5
12923 cat conftest.$ac_ext >&5
12924 cf_cv_lib_XCurses=no
12926 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12929 echo "$as_me:12929: result: $cf_cv_lib_XCurses" >&5
12930 echo "${ECHO_T}$cf_cv_lib_XCurses" >&6
12934 if test $cf_cv_lib_XCurses = yes ; then
12935 cat >>confdefs.h <<\EOF
12939 cat >>confdefs.h <<\EOF
12943 echo "$as_me:12943: checking for xcurses.h" >&5
12944 echo $ECHO_N "checking for xcurses.h... $ECHO_C" >&6
12945 if test "${ac_cv_header_xcurses_h+set}" = set; then
12946 echo $ECHO_N "(cached) $ECHO_C" >&6
12948 cat >conftest.$ac_ext <<_ACEOF
12949 #line 12949 "configure"
12950 #include "confdefs.h"
12951 #include <xcurses.h>
12953 if { (eval echo "$as_me:12953: \"$ac_cpp conftest.$ac_ext\"") >&5
12954 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12956 egrep -v '^ *\+' conftest.er1 >conftest.err
12958 cat conftest.err >&5
12959 echo "$as_me:12959: \$? = $ac_status" >&5
12960 (exit $ac_status); } >/dev/null; then
12961 if test -s conftest.err; then
12962 ac_cpp_err=$ac_c_preproc_warn_flag
12969 if test -z "$ac_cpp_err"; then
12970 ac_cv_header_xcurses_h=yes
12972 echo "$as_me: failed program was:" >&5
12973 cat conftest.$ac_ext >&5
12974 ac_cv_header_xcurses_h=no
12976 rm -f conftest.err conftest.$ac_ext
12978 echo "$as_me:12978: result: $ac_cv_header_xcurses_h" >&5
12979 echo "${ECHO_T}$ac_cv_header_xcurses_h" >&6
12980 if test $ac_cv_header_xcurses_h = yes; then
12981 cat >>confdefs.h <<\EOF
12982 #define HAVE_XCURSES 1
12988 { { echo "$as_me:12988: error: Cannot link with XCurses" >&5
12989 echo "$as_me: error: Cannot link with XCurses" >&2;}
12990 { (exit 1); exit 1; }; }
12996 case $cf_cv_screen in #(vi
13000 # look for curses-related libraries
13002 as_ac_Lib=`echo "ac_cv_lib_panel$cf_cv_libtype''_new_panel" | $as_tr_sh`
13003 echo "$as_me:13003: checking for new_panel in -lpanel$cf_cv_libtype" >&5
13004 echo $ECHO_N "checking for new_panel in -lpanel$cf_cv_libtype... $ECHO_C" >&6
13005 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
13006 echo $ECHO_N "(cached) $ECHO_C" >&6
13008 ac_check_lib_save_LIBS=$LIBS
13009 LIBS="-lpanel$cf_cv_libtype $LIBS"
13010 cat >conftest.$ac_ext <<_ACEOF
13011 #line 13011 "configure"
13012 #include "confdefs.h"
13014 /* Override any gcc2 internal prototype to avoid an error. */
13018 /* We use char because int might match the return type of a gcc2
13019 builtin and then its argument prototype would still apply. */
13029 rm -f conftest.$ac_objext conftest$ac_exeext
13030 if { (eval echo "$as_me:13030: \"$ac_link\"") >&5
13031 (eval $ac_link) 2>&5
13033 echo "$as_me:13033: \$? = $ac_status" >&5
13034 (exit $ac_status); } &&
13035 { ac_try='test -s conftest$ac_exeext'
13036 { (eval echo "$as_me:13036: \"$ac_try\"") >&5
13037 (eval $ac_try) 2>&5
13039 echo "$as_me:13039: \$? = $ac_status" >&5
13040 (exit $ac_status); }; }; then
13041 eval "$as_ac_Lib=yes"
13043 echo "$as_me: failed program was:" >&5
13044 cat conftest.$ac_ext >&5
13045 eval "$as_ac_Lib=no"
13047 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13048 LIBS=$ac_check_lib_save_LIBS
13050 echo "$as_me:13050: result: `eval echo '${'$as_ac_Lib'}'`" >&5
13051 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
13052 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
13053 cat >>confdefs.h <<EOF
13054 #define `echo "HAVE_LIBpanel$cf_cv_libtype" | $as_tr_cpp` 1
13057 LIBS="-lpanel$cf_cv_libtype $LIBS"
13061 as_ac_Lib=`echo "ac_cv_lib_menu$cf_cv_libtype''_menu_driver" | $as_tr_sh`
13062 echo "$as_me:13062: checking for menu_driver in -lmenu$cf_cv_libtype" >&5
13063 echo $ECHO_N "checking for menu_driver in -lmenu$cf_cv_libtype... $ECHO_C" >&6
13064 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
13065 echo $ECHO_N "(cached) $ECHO_C" >&6
13067 ac_check_lib_save_LIBS=$LIBS
13068 LIBS="-lmenu$cf_cv_libtype $LIBS"
13069 cat >conftest.$ac_ext <<_ACEOF
13070 #line 13070 "configure"
13071 #include "confdefs.h"
13073 /* Override any gcc2 internal prototype to avoid an error. */
13077 /* We use char because int might match the return type of a gcc2
13078 builtin and then its argument prototype would still apply. */
13079 char menu_driver ();
13088 rm -f conftest.$ac_objext conftest$ac_exeext
13089 if { (eval echo "$as_me:13089: \"$ac_link\"") >&5
13090 (eval $ac_link) 2>&5
13092 echo "$as_me:13092: \$? = $ac_status" >&5
13093 (exit $ac_status); } &&
13094 { ac_try='test -s conftest$ac_exeext'
13095 { (eval echo "$as_me:13095: \"$ac_try\"") >&5
13096 (eval $ac_try) 2>&5
13098 echo "$as_me:13098: \$? = $ac_status" >&5
13099 (exit $ac_status); }; }; then
13100 eval "$as_ac_Lib=yes"
13102 echo "$as_me: failed program was:" >&5
13103 cat conftest.$ac_ext >&5
13104 eval "$as_ac_Lib=no"
13106 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13107 LIBS=$ac_check_lib_save_LIBS
13109 echo "$as_me:13109: result: `eval echo '${'$as_ac_Lib'}'`" >&5
13110 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
13111 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
13112 cat >>confdefs.h <<EOF
13113 #define `echo "HAVE_LIBmenu$cf_cv_libtype" | $as_tr_cpp` 1
13116 LIBS="-lmenu$cf_cv_libtype $LIBS"
13120 as_ac_Lib=`echo "ac_cv_lib_form$cf_cv_libtype''_form_driver" | $as_tr_sh`
13121 echo "$as_me:13121: checking for form_driver in -lform$cf_cv_libtype" >&5
13122 echo $ECHO_N "checking for form_driver in -lform$cf_cv_libtype... $ECHO_C" >&6
13123 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
13124 echo $ECHO_N "(cached) $ECHO_C" >&6
13126 ac_check_lib_save_LIBS=$LIBS
13127 LIBS="-lform$cf_cv_libtype $LIBS"
13128 cat >conftest.$ac_ext <<_ACEOF
13129 #line 13129 "configure"
13130 #include "confdefs.h"
13132 /* Override any gcc2 internal prototype to avoid an error. */
13136 /* We use char because int might match the return type of a gcc2
13137 builtin and then its argument prototype would still apply. */
13138 char form_driver ();
13147 rm -f conftest.$ac_objext conftest$ac_exeext
13148 if { (eval echo "$as_me:13148: \"$ac_link\"") >&5
13149 (eval $ac_link) 2>&5
13151 echo "$as_me:13151: \$? = $ac_status" >&5
13152 (exit $ac_status); } &&
13153 { ac_try='test -s conftest$ac_exeext'
13154 { (eval echo "$as_me:13154: \"$ac_try\"") >&5
13155 (eval $ac_try) 2>&5
13157 echo "$as_me:13157: \$? = $ac_status" >&5
13158 (exit $ac_status); }; }; then
13159 eval "$as_ac_Lib=yes"
13161 echo "$as_me: failed program was:" >&5
13162 cat conftest.$ac_ext >&5
13163 eval "$as_ac_Lib=no"
13165 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13166 LIBS=$ac_check_lib_save_LIBS
13168 echo "$as_me:13168: result: `eval echo '${'$as_ac_Lib'}'`" >&5
13169 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
13170 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
13171 cat >>confdefs.h <<EOF
13172 #define `echo "HAVE_LIBform$cf_cv_libtype" | $as_tr_cpp` 1
13175 LIBS="-lform$cf_cv_libtype $LIBS"
13179 # look for curses-related headers
13190 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
13191 echo "$as_me:13191: checking for $ac_header" >&5
13192 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13193 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13194 echo $ECHO_N "(cached) $ECHO_C" >&6
13196 cat >conftest.$ac_ext <<_ACEOF
13197 #line 13197 "configure"
13198 #include "confdefs.h"
13199 #include <$ac_header>
13201 if { (eval echo "$as_me:13201: \"$ac_cpp conftest.$ac_ext\"") >&5
13202 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13204 egrep -v '^ *\+' conftest.er1 >conftest.err
13206 cat conftest.err >&5
13207 echo "$as_me:13207: \$? = $ac_status" >&5
13208 (exit $ac_status); } >/dev/null; then
13209 if test -s conftest.err; then
13210 ac_cpp_err=$ac_c_preproc_warn_flag
13217 if test -z "$ac_cpp_err"; then
13218 eval "$as_ac_Header=yes"
13220 echo "$as_me: failed program was:" >&5
13221 cat conftest.$ac_ext >&5
13222 eval "$as_ac_Header=no"
13224 rm -f conftest.err conftest.$ac_ext
13226 echo "$as_me:13226: result: `eval echo '${'$as_ac_Header'}'`" >&5
13227 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13228 if test `eval echo '${'$as_ac_Header'}'` = yes; then
13229 cat >>confdefs.h <<EOF
13230 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
13239 echo "$as_me:13239: checking return type of signal handlers" >&5
13240 echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6
13241 if test "${ac_cv_type_signal+set}" = set; then
13242 echo $ECHO_N "(cached) $ECHO_C" >&6
13244 cat >conftest.$ac_ext <<_ACEOF
13245 #line 13245 "configure"
13246 #include "confdefs.h"
13247 #include <sys/types.h>
13248 #include <signal.h>
13253 extern "C" void (*signal (int, void (*)(int)))(int);
13255 void (*signal ()) ();
13266 rm -f conftest.$ac_objext
13267 if { (eval echo "$as_me:13267: \"$ac_compile\"") >&5
13268 (eval $ac_compile) 2>&5
13270 echo "$as_me:13270: \$? = $ac_status" >&5
13271 (exit $ac_status); } &&
13272 { ac_try='test -s conftest.$ac_objext'
13273 { (eval echo "$as_me:13273: \"$ac_try\"") >&5
13274 (eval $ac_try) 2>&5
13276 echo "$as_me:13276: \$? = $ac_status" >&5
13277 (exit $ac_status); }; }; then
13278 ac_cv_type_signal=void
13280 echo "$as_me: failed program was:" >&5
13281 cat conftest.$ac_ext >&5
13282 ac_cv_type_signal=int
13284 rm -f conftest.$ac_objext conftest.$ac_ext
13286 echo "$as_me:13286: result: $ac_cv_type_signal" >&5
13287 echo "${ECHO_T}$ac_cv_type_signal" >&6
13289 cat >>confdefs.h <<EOF
13290 #define RETSIGTYPE $ac_cv_type_signal
13293 echo "$as_me:13293: checking for ANSI C header files" >&5
13294 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
13295 if test "${ac_cv_header_stdc+set}" = set; then
13296 echo $ECHO_N "(cached) $ECHO_C" >&6
13298 cat >conftest.$ac_ext <<_ACEOF
13299 #line 13299 "configure"
13300 #include "confdefs.h"
13301 #include <stdlib.h>
13302 #include <stdarg.h>
13303 #include <string.h>
13307 if { (eval echo "$as_me:13307: \"$ac_cpp conftest.$ac_ext\"") >&5
13308 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13310 egrep -v '^ *\+' conftest.er1 >conftest.err
13312 cat conftest.err >&5
13313 echo "$as_me:13313: \$? = $ac_status" >&5
13314 (exit $ac_status); } >/dev/null; then
13315 if test -s conftest.err; then
13316 ac_cpp_err=$ac_c_preproc_warn_flag
13323 if test -z "$ac_cpp_err"; then
13324 ac_cv_header_stdc=yes
13326 echo "$as_me: failed program was:" >&5
13327 cat conftest.$ac_ext >&5
13328 ac_cv_header_stdc=no
13330 rm -f conftest.err conftest.$ac_ext
13332 if test $ac_cv_header_stdc = yes; then
13333 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
13334 cat >conftest.$ac_ext <<_ACEOF
13335 #line 13335 "configure"
13336 #include "confdefs.h"
13337 #include <string.h>
13340 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13341 egrep "memchr" >/dev/null 2>&1; then
13344 ac_cv_header_stdc=no
13350 if test $ac_cv_header_stdc = yes; then
13351 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
13352 cat >conftest.$ac_ext <<_ACEOF
13353 #line 13353 "configure"
13354 #include "confdefs.h"
13355 #include <stdlib.h>
13358 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13359 egrep "free" >/dev/null 2>&1; then
13362 ac_cv_header_stdc=no
13368 if test $ac_cv_header_stdc = yes; then
13369 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
13370 if test "$cross_compiling" = yes; then
13373 cat >conftest.$ac_ext <<_ACEOF
13374 #line 13374 "configure"
13375 #include "confdefs.h"
13377 #if ((' ' & 0x0FF) == 0x020)
13378 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
13379 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
13381 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
13382 || ('j' <= (c) && (c) <= 'r') \
13383 || ('s' <= (c) && (c) <= 'z'))
13384 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
13387 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
13392 for (i = 0; i < 256; i++)
13393 if (XOR (islower (i), ISLOWER (i))
13394 || toupper (i) != TOUPPER (i))
13395 $ac_main_return(2);
13396 $ac_main_return (0);
13399 rm -f conftest$ac_exeext
13400 if { (eval echo "$as_me:13400: \"$ac_link\"") >&5
13401 (eval $ac_link) 2>&5
13403 echo "$as_me:13403: \$? = $ac_status" >&5
13404 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13405 { (eval echo "$as_me:13405: \"$ac_try\"") >&5
13406 (eval $ac_try) 2>&5
13408 echo "$as_me:13408: \$? = $ac_status" >&5
13409 (exit $ac_status); }; }; then
13412 echo "$as_me: program exited with status $ac_status" >&5
13413 echo "$as_me: failed program was:" >&5
13414 cat conftest.$ac_ext >&5
13415 ac_cv_header_stdc=no
13417 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13421 echo "$as_me:13421: result: $ac_cv_header_stdc" >&5
13422 echo "${ECHO_T}$ac_cv_header_stdc" >&6
13423 if test $ac_cv_header_stdc = yes; then
13425 cat >>confdefs.h <<\EOF
13426 #define STDC_HEADERS 1
13431 echo "$as_me:13431: checking whether time.h and sys/time.h may both be included" >&5
13432 echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
13433 if test "${ac_cv_header_time+set}" = set; then
13434 echo $ECHO_N "(cached) $ECHO_C" >&6
13436 cat >conftest.$ac_ext <<_ACEOF
13437 #line 13437 "configure"
13438 #include "confdefs.h"
13439 #include <sys/types.h>
13440 #include <sys/time.h>
13446 if ((struct tm *) 0)
13452 rm -f conftest.$ac_objext
13453 if { (eval echo "$as_me:13453: \"$ac_compile\"") >&5
13454 (eval $ac_compile) 2>&5
13456 echo "$as_me:13456: \$? = $ac_status" >&5
13457 (exit $ac_status); } &&
13458 { ac_try='test -s conftest.$ac_objext'
13459 { (eval echo "$as_me:13459: \"$ac_try\"") >&5
13460 (eval $ac_try) 2>&5
13462 echo "$as_me:13462: \$? = $ac_status" >&5
13463 (exit $ac_status); }; }; then
13464 ac_cv_header_time=yes
13466 echo "$as_me: failed program was:" >&5
13467 cat conftest.$ac_ext >&5
13468 ac_cv_header_time=no
13470 rm -f conftest.$ac_objext conftest.$ac_ext
13472 echo "$as_me:13472: result: $ac_cv_header_time" >&5
13473 echo "${ECHO_T}$ac_cv_header_time" >&6
13474 if test $ac_cv_header_time = yes; then
13476 cat >>confdefs.h <<\EOF
13477 #define TIME_WITH_SYS_TIME 1
13494 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
13495 echo "$as_me:13495: checking for $ac_header" >&5
13496 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13497 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13498 echo $ECHO_N "(cached) $ECHO_C" >&6
13500 cat >conftest.$ac_ext <<_ACEOF
13501 #line 13501 "configure"
13502 #include "confdefs.h"
13503 #include <$ac_header>
13505 if { (eval echo "$as_me:13505: \"$ac_cpp conftest.$ac_ext\"") >&5
13506 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13508 egrep -v '^ *\+' conftest.er1 >conftest.err
13510 cat conftest.err >&5
13511 echo "$as_me:13511: \$? = $ac_status" >&5
13512 (exit $ac_status); } >/dev/null; then
13513 if test -s conftest.err; then
13514 ac_cpp_err=$ac_c_preproc_warn_flag
13521 if test -z "$ac_cpp_err"; then
13522 eval "$as_ac_Header=yes"
13524 echo "$as_me: failed program was:" >&5
13525 cat conftest.$ac_ext >&5
13526 eval "$as_ac_Header=no"
13528 rm -f conftest.err conftest.$ac_ext
13530 echo "$as_me:13530: result: `eval echo '${'$as_ac_Header'}'`" >&5
13531 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13532 if test `eval echo '${'$as_ac_Header'}'` = yes; then
13533 cat >>confdefs.h <<EOF
13534 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
13540 for ac_header in unistd.h getopt.h
13542 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
13543 echo "$as_me:13543: checking for $ac_header" >&5
13544 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13545 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13546 echo $ECHO_N "(cached) $ECHO_C" >&6
13548 cat >conftest.$ac_ext <<_ACEOF
13549 #line 13549 "configure"
13550 #include "confdefs.h"
13551 #include <$ac_header>
13553 if { (eval echo "$as_me:13553: \"$ac_cpp conftest.$ac_ext\"") >&5
13554 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13556 egrep -v '^ *\+' conftest.er1 >conftest.err
13558 cat conftest.err >&5
13559 echo "$as_me:13559: \$? = $ac_status" >&5
13560 (exit $ac_status); } >/dev/null; then
13561 if test -s conftest.err; then
13562 ac_cpp_err=$ac_c_preproc_warn_flag
13569 if test -z "$ac_cpp_err"; then
13570 eval "$as_ac_Header=yes"
13572 echo "$as_me: failed program was:" >&5
13573 cat conftest.$ac_ext >&5
13574 eval "$as_ac_Header=no"
13576 rm -f conftest.err conftest.$ac_ext
13578 echo "$as_me:13578: result: `eval echo '${'$as_ac_Header'}'`" >&5
13579 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13580 if test `eval echo '${'$as_ac_Header'}'` = yes; then
13581 cat >>confdefs.h <<EOF
13582 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
13588 echo "$as_me:13588: checking for header declaring getopt variables" >&5
13589 echo $ECHO_N "checking for header declaring getopt variables... $ECHO_C" >&6
13590 if test "${cf_cv_getopt_header+set}" = set; then
13591 echo $ECHO_N "(cached) $ECHO_C" >&6
13594 cf_cv_getopt_header=none
13595 for cf_header in stdio.h stdlib.h unistd.h getopt.h
13597 cat >conftest.$ac_ext <<_ACEOF
13598 #line 13598 "configure"
13599 #include "confdefs.h"
13601 #include <$cf_header>
13605 int x = optind; char *y = optarg
13610 rm -f conftest.$ac_objext
13611 if { (eval echo "$as_me:13611: \"$ac_compile\"") >&5
13612 (eval $ac_compile) 2>&5
13614 echo "$as_me:13614: \$? = $ac_status" >&5
13615 (exit $ac_status); } &&
13616 { ac_try='test -s conftest.$ac_objext'
13617 { (eval echo "$as_me:13617: \"$ac_try\"") >&5
13618 (eval $ac_try) 2>&5
13620 echo "$as_me:13620: \$? = $ac_status" >&5
13621 (exit $ac_status); }; }; then
13622 cf_cv_getopt_header=$cf_header
13625 echo "$as_me: failed program was:" >&5
13626 cat conftest.$ac_ext >&5
13628 rm -f conftest.$ac_objext conftest.$ac_ext
13632 echo "$as_me:13632: result: $cf_cv_getopt_header" >&5
13633 echo "${ECHO_T}$cf_cv_getopt_header" >&6
13634 if test $cf_cv_getopt_header != none ; then
13635 cat >>confdefs.h <<\EOF
13636 #define HAVE_GETOPT_HEADER 1
13646 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13647 echo "$as_me:13647: checking for $ac_func" >&5
13648 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13649 if eval "test \"\${$as_ac_var+set}\" = set"; then
13650 echo $ECHO_N "(cached) $ECHO_C" >&6
13652 cat >conftest.$ac_ext <<_ACEOF
13653 #line 13653 "configure"
13654 #include "confdefs.h"
13655 /* System header to define __stub macros and hopefully few prototypes,
13656 which can conflict with char $ac_func (); below. */
13657 #include <assert.h>
13658 /* Override any gcc2 internal prototype to avoid an error. */
13662 /* We use char because int might match the return type of a gcc2
13663 builtin and then its argument prototype would still apply. */
13670 /* The GNU C library defines this for functions which it implements
13671 to always fail with ENOSYS. Some functions are actually named
13672 something starting with __ and the normal name is an alias. */
13673 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13683 rm -f conftest.$ac_objext conftest$ac_exeext
13684 if { (eval echo "$as_me:13684: \"$ac_link\"") >&5
13685 (eval $ac_link) 2>&5
13687 echo "$as_me:13687: \$? = $ac_status" >&5
13688 (exit $ac_status); } &&
13689 { ac_try='test -s conftest$ac_exeext'
13690 { (eval echo "$as_me:13690: \"$ac_try\"") >&5
13691 (eval $ac_try) 2>&5
13693 echo "$as_me:13693: \$? = $ac_status" >&5
13694 (exit $ac_status); }; }; then
13695 eval "$as_ac_var=yes"
13697 echo "$as_me: failed program was:" >&5
13698 cat conftest.$ac_ext >&5
13699 eval "$as_ac_var=no"
13701 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13703 echo "$as_me:13703: result: `eval echo '${'$as_ac_var'}'`" >&5
13704 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13705 if test `eval echo '${'$as_ac_var'}'` = yes; then
13706 cat >>confdefs.h <<EOF
13707 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13713 if test "$cf_enable_widec" = yes; then
13726 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13727 echo "$as_me:13727: checking for $ac_func" >&5
13728 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13729 if eval "test \"\${$as_ac_var+set}\" = set"; then
13730 echo $ECHO_N "(cached) $ECHO_C" >&6
13732 cat >conftest.$ac_ext <<_ACEOF
13733 #line 13733 "configure"
13734 #include "confdefs.h"
13735 /* System header to define __stub macros and hopefully few prototypes,
13736 which can conflict with char $ac_func (); below. */
13737 #include <assert.h>
13738 /* Override any gcc2 internal prototype to avoid an error. */
13742 /* We use char because int might match the return type of a gcc2
13743 builtin and then its argument prototype would still apply. */
13750 /* The GNU C library defines this for functions which it implements
13751 to always fail with ENOSYS. Some functions are actually named
13752 something starting with __ and the normal name is an alias. */
13753 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13763 rm -f conftest.$ac_objext conftest$ac_exeext
13764 if { (eval echo "$as_me:13764: \"$ac_link\"") >&5
13765 (eval $ac_link) 2>&5
13767 echo "$as_me:13767: \$? = $ac_status" >&5
13768 (exit $ac_status); } &&
13769 { ac_try='test -s conftest$ac_exeext'
13770 { (eval echo "$as_me:13770: \"$ac_try\"") >&5
13771 (eval $ac_try) 2>&5
13773 echo "$as_me:13773: \$? = $ac_status" >&5
13774 (exit $ac_status); }; }; then
13775 eval "$as_ac_var=yes"
13777 echo "$as_me: failed program was:" >&5
13778 cat conftest.$ac_ext >&5
13779 eval "$as_ac_var=no"
13781 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13783 echo "$as_me:13783: result: `eval echo '${'$as_ac_var'}'`" >&5
13784 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13785 if test `eval echo '${'$as_ac_var'}'` = yes; then
13786 cat >>confdefs.h <<EOF
13787 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13795 echo "$as_me:13795: checking if we must define _XOPEN_SOURCE_EXTENDED" >&5
13796 echo $ECHO_N "checking if we must define _XOPEN_SOURCE_EXTENDED... $ECHO_C" >&6
13797 if test "${cf_cv_need_xopen_extension+set}" = set; then
13798 echo $ECHO_N "(cached) $ECHO_C" >&6
13801 cat >conftest.$ac_ext <<_ACEOF
13802 #line 13802 "configure"
13803 #include "confdefs.h"
13805 #include <stdlib.h>
13806 #include <${cf_cv_ncurses_header:-curses.h}>
13811 #if defined(NCURSES_VERSION_PATCH)
13812 #if (NCURSES_VERSION_PATCH < 20100501) && (NCURSES_VERSION_PATCH >= 20100403)
13816 long x = winnstr(stdscr, "", 0);
13818 getbegyx(stdscr, y1, x1)
13823 rm -f conftest.$ac_objext conftest$ac_exeext
13824 if { (eval echo "$as_me:13824: \"$ac_link\"") >&5
13825 (eval $ac_link) 2>&5
13827 echo "$as_me:13827: \$? = $ac_status" >&5
13828 (exit $ac_status); } &&
13829 { ac_try='test -s conftest$ac_exeext'
13830 { (eval echo "$as_me:13830: \"$ac_try\"") >&5
13831 (eval $ac_try) 2>&5
13833 echo "$as_me:13833: \$? = $ac_status" >&5
13834 (exit $ac_status); }; }; then
13835 cf_cv_need_xopen_extension=no
13837 echo "$as_me: failed program was:" >&5
13838 cat conftest.$ac_ext >&5
13839 cat >conftest.$ac_ext <<_ACEOF
13840 #line 13840 "configure"
13841 #include "confdefs.h"
13843 #define _XOPEN_SOURCE_EXTENDED
13844 #include <stdlib.h>
13845 #include <${cf_cv_ncurses_header:-curses.h}>
13850 #ifdef NCURSES_VERSION
13852 int check2 = curs_set((int)sizeof(check));
13854 long x = winnstr(stdscr, "", 0);
13856 getbegyx(stdscr, y1, x1)
13861 rm -f conftest.$ac_objext conftest$ac_exeext
13862 if { (eval echo "$as_me:13862: \"$ac_link\"") >&5
13863 (eval $ac_link) 2>&5
13865 echo "$as_me:13865: \$? = $ac_status" >&5
13866 (exit $ac_status); } &&
13867 { ac_try='test -s conftest$ac_exeext'
13868 { (eval echo "$as_me:13868: \"$ac_try\"") >&5
13869 (eval $ac_try) 2>&5
13871 echo "$as_me:13871: \$? = $ac_status" >&5
13872 (exit $ac_status); }; }; then
13873 cf_cv_need_xopen_extension=yes
13875 echo "$as_me: failed program was:" >&5
13876 cat conftest.$ac_ext >&5
13877 cf_cv_need_xopen_extension=unknown
13879 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13881 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13883 echo "$as_me:13883: result: $cf_cv_need_xopen_extension" >&5
13884 echo "${ECHO_T}$cf_cv_need_xopen_extension" >&6
13885 test $cf_cv_need_xopen_extension = yes && CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE_EXTENDED"
13887 echo "$as_me:13887: checking for term.h" >&5
13888 echo $ECHO_N "checking for term.h... $ECHO_C" >&6
13889 if test "${cf_cv_term_header+set}" = set; then
13890 echo $ECHO_N "(cached) $ECHO_C" >&6
13893 # If we found <ncurses/curses.h>, look for <ncurses/term.h>, but always look
13894 # for <term.h> if we do not find the variant.
13896 cf_header_list="term.h ncurses/term.h ncursesw/term.h"
13898 case ${cf_cv_ncurses_header:-curses.h} in #(vi
13900 cf_header_item=`echo ${cf_cv_ncurses_header:-curses.h} | sed -e 's%\..*%%' -e 's%/.*%/%'`term.h
13901 cf_header_list="$cf_header_item $cf_header_list"
13905 for cf_header in $cf_header_list
13907 cat >conftest.$ac_ext <<_ACEOF
13908 #line 13908 "configure"
13909 #include "confdefs.h"
13911 #include <${cf_cv_ncurses_header:-curses.h}>
13912 #include <${cf_header}>
13921 rm -f conftest.$ac_objext
13922 if { (eval echo "$as_me:13922: \"$ac_compile\"") >&5
13923 (eval $ac_compile) 2>&5
13925 echo "$as_me:13925: \$? = $ac_status" >&5
13926 (exit $ac_status); } &&
13927 { ac_try='test -s conftest.$ac_objext'
13928 { (eval echo "$as_me:13928: \"$ac_try\"") >&5
13929 (eval $ac_try) 2>&5
13931 echo "$as_me:13931: \$? = $ac_status" >&5
13932 (exit $ac_status); }; }; then
13933 cf_cv_term_header=$cf_header
13936 echo "$as_me: failed program was:" >&5
13937 cat conftest.$ac_ext >&5
13938 cf_cv_term_header=no
13940 rm -f conftest.$ac_objext conftest.$ac_ext
13943 case $cf_cv_term_header in #(vi
13945 # If curses is ncurses, some packagers still mess it up by trying to make
13946 # us use GNU termcap. This handles the most common case.
13947 for cf_header in ncurses/term.h ncursesw/term.h
13949 cat >conftest.$ac_ext <<_ACEOF
13950 #line 13950 "configure"
13951 #include "confdefs.h"
13953 #include <${cf_cv_ncurses_header:-curses.h}>
13954 #ifdef NCURSES_VERSION
13955 #include <${cf_header}>
13967 rm -f conftest.$ac_objext
13968 if { (eval echo "$as_me:13968: \"$ac_compile\"") >&5
13969 (eval $ac_compile) 2>&5
13971 echo "$as_me:13971: \$? = $ac_status" >&5
13972 (exit $ac_status); } &&
13973 { ac_try='test -s conftest.$ac_objext'
13974 { (eval echo "$as_me:13974: \"$ac_try\"") >&5
13975 (eval $ac_try) 2>&5
13977 echo "$as_me:13977: \$? = $ac_status" >&5
13978 (exit $ac_status); }; }; then
13979 cf_cv_term_header=$cf_header
13982 echo "$as_me: failed program was:" >&5
13983 cat conftest.$ac_ext >&5
13984 cf_cv_term_header=no
13986 rm -f conftest.$ac_objext conftest.$ac_ext
13992 echo "$as_me:13992: result: $cf_cv_term_header" >&5
13993 echo "${ECHO_T}$cf_cv_term_header" >&6
13995 case $cf_cv_term_header in #(vi
13997 cat >>confdefs.h <<\EOF
13998 #define HAVE_TERM_H 1
14002 ncurses/term.h) #(vi
14003 cat >>confdefs.h <<\EOF
14004 #define HAVE_NCURSES_TERM_H 1
14009 cat >>confdefs.h <<\EOF
14010 #define HAVE_NCURSESW_TERM_H 1
14016 echo "$as_me:14016: checking for unctrl.h" >&5
14017 echo $ECHO_N "checking for unctrl.h... $ECHO_C" >&6
14018 if test "${cf_cv_unctrl_header+set}" = set; then
14019 echo $ECHO_N "(cached) $ECHO_C" >&6
14022 # If we found <ncurses/curses.h>, look for <ncurses/unctrl.h>, but always look
14023 # for <unctrl.h> if we do not find the variant.
14025 cf_header_list="unctrl.h ncurses/unctrl.h ncursesw/unctrl.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%/.*%/%'`unctrl.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_unctrl_header=$cf_header
14065 echo "$as_me: failed program was:" >&5
14066 cat conftest.$ac_ext >&5
14067 cf_cv_unctrl_header=no
14069 rm -f conftest.$ac_objext conftest.$ac_ext
14072 case $cf_cv_unctrl_header in #(vi
14074 { echo "$as_me:14074: WARNING: unctrl.h header not found" >&5
14075 echo "$as_me: WARNING: unctrl.h header not found" >&2;}
14080 echo "$as_me:14080: result: $cf_cv_unctrl_header" >&5
14081 echo "${ECHO_T}$cf_cv_unctrl_header" >&6
14083 case $cf_cv_unctrl_header in #(vi
14085 cat >>confdefs.h <<\EOF
14086 #define HAVE_UNCTRL_H 1
14090 ncurses/unctrl.h) #(vi
14091 cat >>confdefs.h <<\EOF
14092 #define HAVE_NCURSES_UNCTRL_H 1
14097 cat >>confdefs.h <<\EOF
14098 #define HAVE_NCURSESW_UNCTRL_H 1
14105 assume_default_colors \
14131 use_default_colors \
14143 cf_tr_func=`echo "$cf_func" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14145 echo "$as_me:14145: checking for ${cf_func}" >&5
14146 echo $ECHO_N "checking for ${cf_func}... $ECHO_C" >&6
14148 echo "${as_me:-configure}:14148: testing ${cf_func} ..." 1>&5
14150 if eval "test \"\${cf_cv_func_$cf_func+set}\" = set"; then
14151 echo $ECHO_N "(cached) $ECHO_C" >&6
14154 eval cf_result='$ac_cv_func_'$cf_func
14155 if test ".$cf_result" != ".no"; then
14156 cat >conftest.$ac_ext <<_ACEOF
14157 #line 14157 "configure"
14158 #include "confdefs.h"
14160 #ifdef HAVE_XCURSES
14161 #include <xcurses.h>
14162 char * XCursesProgramName = "test";
14164 #include <${cf_cv_ncurses_header:-curses.h}>
14165 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
14166 #include <ncursesw/term.h>
14167 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
14168 #include <ncurses/term.h>
14169 #elif defined(HAVE_TERM_H)
14179 long foo = (long)(&${cf_func});
14180 if (foo + 1234 > 5678)
14181 ${cf_cv_main_return:-return}(foo);
14188 rm -f conftest.$ac_objext conftest$ac_exeext
14189 if { (eval echo "$as_me:14189: \"$ac_link\"") >&5
14190 (eval $ac_link) 2>&5
14192 echo "$as_me:14192: \$? = $ac_status" >&5
14193 (exit $ac_status); } &&
14194 { ac_try='test -s conftest$ac_exeext'
14195 { (eval echo "$as_me:14195: \"$ac_try\"") >&5
14196 (eval $ac_try) 2>&5
14198 echo "$as_me:14198: \$? = $ac_status" >&5
14199 (exit $ac_status); }; }; then
14202 echo "$as_me: failed program was:" >&5
14203 cat conftest.$ac_ext >&5
14206 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14208 eval 'cf_cv_func_'$cf_func'=$cf_result'
14212 # use the computed/retrieved cache-value:
14213 eval 'cf_result=$cf_cv_func_'$cf_func
14214 echo "$as_me:14214: result: $cf_result" >&5
14215 echo "${ECHO_T}$cf_result" >&6
14216 if test $cf_result != no; then
14217 cat >>confdefs.h <<EOF
14218 #define HAVE_${cf_tr_func} 1
14224 for cf_func in tputs
14227 cf_tr_func=`echo "$cf_func" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14229 echo "$as_me:14229: checking for ${cf_func}" >&5
14230 echo $ECHO_N "checking for ${cf_func}... $ECHO_C" >&6
14232 echo "${as_me:-configure}:14232: testing ${cf_func} ..." 1>&5
14234 if eval "test \"\${cf_cv_func_$cf_func+set}\" = set"; then
14235 echo $ECHO_N "(cached) $ECHO_C" >&6
14238 eval cf_result='$ac_cv_func_'$cf_func
14239 if test ".$cf_result" != ".no"; then
14240 cat >conftest.$ac_ext <<_ACEOF
14241 #line 14241 "configure"
14242 #include "confdefs.h"
14244 #ifdef HAVE_XCURSES
14245 #include <xcurses.h>
14246 char * XCursesProgramName = "test";
14248 #include <${cf_cv_ncurses_header:-curses.h}>
14249 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
14250 #include <ncursesw/term.h>
14251 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
14252 #include <ncurses/term.h>
14253 #elif defined(HAVE_TERM_H)
14263 long foo = (long)(&${cf_func});
14264 if (foo + 1234 > 5678)
14265 ${cf_cv_main_return:-return}(foo);
14272 rm -f conftest.$ac_objext conftest$ac_exeext
14273 if { (eval echo "$as_me:14273: \"$ac_link\"") >&5
14274 (eval $ac_link) 2>&5
14276 echo "$as_me:14276: \$? = $ac_status" >&5
14277 (exit $ac_status); } &&
14278 { ac_try='test -s conftest$ac_exeext'
14279 { (eval echo "$as_me:14279: \"$ac_try\"") >&5
14280 (eval $ac_try) 2>&5
14282 echo "$as_me:14282: \$? = $ac_status" >&5
14283 (exit $ac_status); }; }; then
14286 echo "$as_me: failed program was:" >&5
14287 cat conftest.$ac_ext >&5
14290 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14292 eval 'cf_cv_func_'$cf_func'=$cf_result'
14296 # use the computed/retrieved cache-value:
14297 eval 'cf_result=$cf_cv_func_'$cf_func
14298 echo "$as_me:14298: result: $cf_result" >&5
14299 echo "${ECHO_T}$cf_result" >&6
14300 if test $cf_result != no; then
14301 cat >>confdefs.h <<EOF
14302 #define HAVE_${cf_tr_func} 1
14308 if test x$cf_cv_func_tputs = xyes
14311 for cf_arg in int char
14313 for cf_ret in int void
14315 if test $cf_ret = void
14317 cf_return="/* nothing */"
14319 cf_return="return value"
14321 cat >conftest.$ac_ext <<_ACEOF
14322 #line 14322 "configure"
14323 #include "confdefs.h"
14325 #include <${cf_cv_ncurses_header:-curses.h}>
14326 #include <$cf_cv_term_header>
14328 static $cf_ret outc($cf_arg value) { $cf_return; }
14334 tputs("hello", 0, outc);
14335 ${cf_cv_main_return:-return}(0);
14341 rm -f conftest.$ac_objext
14342 if { (eval echo "$as_me:14342: \"$ac_compile\"") >&5
14343 (eval $ac_compile) 2>&5
14345 echo "$as_me:14345: \$? = $ac_status" >&5
14346 (exit $ac_status); } &&
14347 { ac_try='test -s conftest.$ac_objext'
14348 { (eval echo "$as_me:14348: \"$ac_try\"") >&5
14349 (eval $ac_try) 2>&5
14351 echo "$as_me:14351: \$? = $ac_status" >&5
14352 (exit $ac_status); }; }; then
14354 test -n "$verbose" && echo " prototype $cf_ret func($cf_arg value)" 1>&6
14356 echo "${as_me:-configure}:14356: testing prototype $cf_ret func($cf_arg value) ..." 1>&5
14358 cat >>confdefs.h <<EOF
14359 #define TPUTS_ARG $cf_arg
14360 #define TPUTS_PROTO(func,value) $cf_ret func(TPUTS_ARG value)
14361 #define TPUTS_RETURN(value) $cf_return
14367 echo "$as_me: failed program was:" >&5
14368 cat conftest.$ac_ext >&5
14370 rm -f conftest.$ac_objext conftest.$ac_ext
14372 test $cf_done = yes && break
14376 echo "$as_me:14376: checking for ncurses extended functions" >&5
14377 echo $ECHO_N "checking for ncurses extended functions... $ECHO_C" >&6
14378 if test "${cf_cv_ncurses_ext_funcs+set}" = set; then
14379 echo $ECHO_N "(cached) $ECHO_C" >&6
14382 cat >conftest.$ac_ext <<_ACEOF
14383 #line 14383 "configure"
14384 #include "confdefs.h"
14386 #include <${cf_cv_ncurses_header:-curses.h}>
14391 int x = NCURSES_EXT_FUNCS
14397 rm -f conftest.$ac_objext
14398 if { (eval echo "$as_me:14398: \"$ac_compile\"") >&5
14399 (eval $ac_compile) 2>&5
14401 echo "$as_me:14401: \$? = $ac_status" >&5
14402 (exit $ac_status); } &&
14403 { ac_try='test -s conftest.$ac_objext'
14404 { (eval echo "$as_me:14404: \"$ac_try\"") >&5
14405 (eval $ac_try) 2>&5
14407 echo "$as_me:14407: \$? = $ac_status" >&5
14408 (exit $ac_status); }; }; then
14409 cf_cv_ncurses_ext_funcs=defined
14411 echo "$as_me: failed program was:" >&5
14412 cat conftest.$ac_ext >&5
14414 cat >conftest.$ac_ext <<_ACEOF
14415 #line 14415 "configure"
14416 #include "confdefs.h"
14418 #include <${cf_cv_ncurses_header:-curses.h}>
14423 (void) assume_default_colors (0, 0);
14424 (void) curses_version ();
14425 (void) define_key (0, 0);
14426 (void) is_term_resized (0, 0);
14427 (void) key_defined (0);
14428 (void) keybound (0, 0);
14429 (void) keyok (0, 0);
14430 (void) resize_term (0, 0);
14431 (void) resizeterm (0, 0);
14432 (void) use_default_colors ();
14433 (void) use_extended_names (0);
14434 (void) wresize (0, 0, 0);
14439 rm -f conftest.$ac_objext conftest$ac_exeext
14440 if { (eval echo "$as_me:14440: \"$ac_link\"") >&5
14441 (eval $ac_link) 2>&5
14443 echo "$as_me:14443: \$? = $ac_status" >&5
14444 (exit $ac_status); } &&
14445 { ac_try='test -s conftest$ac_exeext'
14446 { (eval echo "$as_me:14446: \"$ac_try\"") >&5
14447 (eval $ac_try) 2>&5
14449 echo "$as_me:14449: \$? = $ac_status" >&5
14450 (exit $ac_status); }; }; then
14451 cf_cv_ncurses_ext_funcs=yes
14453 echo "$as_me: failed program was:" >&5
14454 cat conftest.$ac_ext >&5
14455 cf_cv_ncurses_ext_funcs=no
14457 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14460 rm -f conftest.$ac_objext conftest.$ac_ext
14463 echo "$as_me:14463: result: $cf_cv_ncurses_ext_funcs" >&5
14464 echo "${ECHO_T}$cf_cv_ncurses_ext_funcs" >&6
14465 test "$cf_cv_ncurses_ext_funcs" = yes && cat >>confdefs.h <<\EOF
14466 #define NCURSES_EXT_FUNCS 1
14469 if test "$cf_enable_widec" = yes
14471 # workaround for systems with ncurses before 20111029, due to change of
14472 # feature test macro from _XPG5 to _XOPEN_SOURCE
14473 if test -n "$cf_cv_ncurses_version" && test "x$cf_cv_ncurses_version" != xno
14476 echo "$as_me:14476: checking if _XPG5 should be defined to enable wide-characters" >&5
14477 echo $ECHO_N "checking if _XPG5 should be defined to enable wide-characters... $ECHO_C" >&6
14479 cat >conftest.$ac_ext <<_ACEOF
14480 #line 14480 "configure"
14481 #include "confdefs.h"
14483 #include <${cf_cv_ncurses_header:-curses.h}>
14492 rm -f conftest.$ac_objext
14493 if { (eval echo "$as_me:14493: \"$ac_compile\"") >&5
14494 (eval $ac_compile) 2>&5
14496 echo "$as_me:14496: \$? = $ac_status" >&5
14497 (exit $ac_status); } &&
14498 { ac_try='test -s conftest.$ac_objext'
14499 { (eval echo "$as_me:14499: \"$ac_try\"") >&5
14500 (eval $ac_try) 2>&5
14502 echo "$as_me:14502: \$? = $ac_status" >&5
14503 (exit $ac_status); }; }; then
14506 echo "$as_me: failed program was:" >&5
14507 cat conftest.$ac_ext >&5
14508 cf_save_cppflags="$CPPFLAGS"
14509 CPPFLAGS="$CPPFLAGS -D_XPG5"
14510 cat >conftest.$ac_ext <<_ACEOF
14511 #line 14511 "configure"
14512 #include "confdefs.h"
14514 #include <${cf_cv_ncurses_header:-curses.h}>
14523 rm -f conftest.$ac_objext
14524 if { (eval echo "$as_me:14524: \"$ac_compile\"") >&5
14525 (eval $ac_compile) 2>&5
14527 echo "$as_me:14527: \$? = $ac_status" >&5
14528 (exit $ac_status); } &&
14529 { ac_try='test -s conftest.$ac_objext'
14530 { (eval echo "$as_me:14530: \"$ac_try\"") >&5
14531 (eval $ac_try) 2>&5
14533 echo "$as_me:14533: \$? = $ac_status" >&5
14534 (exit $ac_status); }; }; then
14537 echo "$as_me: failed program was:" >&5
14538 cat conftest.$ac_ext >&5
14540 rm -f conftest.$ac_objext conftest.$ac_ext
14541 CPPFLAGS="$cf_save_cppflags"
14543 rm -f conftest.$ac_objext conftest.$ac_ext
14544 echo "$as_me:14544: result: $cf_define_xpg5" >&5
14545 echo "${ECHO_T}$cf_define_xpg5" >&6
14547 if test "$cf_define_xpg5" = yes
14549 CPPFLAGS="$CPPFLAGS -D_XPG5"
14553 echo "$as_me:14553: checking for wide-character functions" >&5
14554 echo $ECHO_N "checking for wide-character functions... $ECHO_C" >&6
14555 if test "${cf_cv_widechar_funcs+set}" = set; then
14556 echo $ECHO_N "(cached) $ECHO_C" >&6
14559 cat >conftest.$ac_ext <<_ACEOF
14560 #line 14560 "configure"
14561 #include "confdefs.h"
14563 #include <${cf_cv_ncurses_header:-curses.h}>
14568 static wchar_t src_wchar[2];
14569 static cchar_t dst_cchar;
14570 setcchar(&dst_cchar, src_wchar, A_NORMAL, 0, (void *) 0);
14576 rm -f conftest.$ac_objext conftest$ac_exeext
14577 if { (eval echo "$as_me:14577: \"$ac_link\"") >&5
14578 (eval $ac_link) 2>&5
14580 echo "$as_me:14580: \$? = $ac_status" >&5
14581 (exit $ac_status); } &&
14582 { ac_try='test -s conftest$ac_exeext'
14583 { (eval echo "$as_me:14583: \"$ac_try\"") >&5
14584 (eval $ac_try) 2>&5
14586 echo "$as_me:14586: \$? = $ac_status" >&5
14587 (exit $ac_status); }; }; then
14588 cf_cv_widechar_funcs=yes
14590 echo "$as_me: failed program was:" >&5
14591 cat conftest.$ac_ext >&5
14592 cf_cv_widechar_funcs=no
14594 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14597 echo "$as_me:14597: result: $cf_cv_widechar_funcs" >&5
14598 echo "${ECHO_T}$cf_cv_widechar_funcs" >&6
14599 if test "$cf_cv_widechar_funcs" != no ; then
14600 cat >>confdefs.h <<\EOF
14601 #define USE_WIDEC_SUPPORT 1
14605 cat >>confdefs.h <<\EOF
14606 #define USE_WIDEC_SUPPORT 0
14611 cat >>confdefs.h <<\EOF
14612 #define USE_WIDEC_SUPPORT 0
14617 echo "$as_me:14617: checking if sys/time.h works with sys/select.h" >&5
14618 echo $ECHO_N "checking if sys/time.h works with sys/select.h... $ECHO_C" >&6
14619 if test "${cf_cv_sys_time_select+set}" = set; then
14620 echo $ECHO_N "(cached) $ECHO_C" >&6
14623 cat >conftest.$ac_ext <<_ACEOF
14624 #line 14624 "configure"
14625 #include "confdefs.h"
14627 #include <sys/types.h>
14628 #ifdef HAVE_SYS_TIME_H
14629 #include <sys/time.h>
14631 #ifdef HAVE_SYS_SELECT_H
14632 #include <sys/select.h>
14643 rm -f conftest.$ac_objext
14644 if { (eval echo "$as_me:14644: \"$ac_compile\"") >&5
14645 (eval $ac_compile) 2>&5
14647 echo "$as_me:14647: \$? = $ac_status" >&5
14648 (exit $ac_status); } &&
14649 { ac_try='test -s conftest.$ac_objext'
14650 { (eval echo "$as_me:14650: \"$ac_try\"") >&5
14651 (eval $ac_try) 2>&5
14653 echo "$as_me:14653: \$? = $ac_status" >&5
14654 (exit $ac_status); }; }; then
14655 cf_cv_sys_time_select=yes
14657 echo "$as_me: failed program was:" >&5
14658 cat conftest.$ac_ext >&5
14659 cf_cv_sys_time_select=no
14661 rm -f conftest.$ac_objext conftest.$ac_ext
14665 echo "$as_me:14665: result: $cf_cv_sys_time_select" >&5
14666 echo "${ECHO_T}$cf_cv_sys_time_select" >&6
14667 test "$cf_cv_sys_time_select" = yes && cat >>confdefs.h <<\EOF
14668 #define HAVE_SYS_TIME_SELECT 1
14671 echo "$as_me:14671: checking for function curses_version" >&5
14672 echo $ECHO_N "checking for function curses_version... $ECHO_C" >&6
14673 if test "${cf_cv_func_curses_version+set}" = set; then
14674 echo $ECHO_N "(cached) $ECHO_C" >&6
14677 if test "$cross_compiling" = yes; then
14678 cf_cv_func_curses_version=unknown
14680 cat >conftest.$ac_ext <<_ACEOF
14681 #line 14681 "configure"
14682 #include "confdefs.h"
14684 #include <${cf_cv_ncurses_header:-curses.h}>
14688 sprintf(temp, "%s\n", curses_version());
14689 ${cf_cv_main_return:-return}(0);
14693 rm -f conftest$ac_exeext
14694 if { (eval echo "$as_me:14694: \"$ac_link\"") >&5
14695 (eval $ac_link) 2>&5
14697 echo "$as_me:14697: \$? = $ac_status" >&5
14698 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14699 { (eval echo "$as_me:14699: \"$ac_try\"") >&5
14700 (eval $ac_try) 2>&5
14702 echo "$as_me:14702: \$? = $ac_status" >&5
14703 (exit $ac_status); }; }; then
14704 cf_cv_func_curses_version=yes
14707 echo "$as_me: program exited with status $ac_status" >&5
14708 echo "$as_me: failed program was:" >&5
14709 cat conftest.$ac_ext >&5
14710 cf_cv_func_curses_version=no
14713 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14717 echo "$as_me:14717: result: $cf_cv_func_curses_version" >&5
14718 echo "${ECHO_T}$cf_cv_func_curses_version" >&6
14719 test "$cf_cv_func_curses_version" = yes && cat >>confdefs.h <<\EOF
14720 #define HAVE_CURSES_VERSION 1
14723 echo "$as_me:14723: checking for ncurses wrap-prefix" >&5
14724 echo $ECHO_N "checking for ncurses wrap-prefix... $ECHO_C" >&6
14726 # Check whether --with-ncurses-wrap-prefix or --without-ncurses-wrap-prefix was given.
14727 if test "${with_ncurses_wrap_prefix+set}" = set; then
14728 withval="$with_ncurses_wrap_prefix"
14729 NCURSES_WRAP_PREFIX=$withval
14731 NCURSES_WRAP_PREFIX=_nc_
14733 echo "$as_me:14733: result: $NCURSES_WRAP_PREFIX" >&5
14734 echo "${ECHO_T}$NCURSES_WRAP_PREFIX" >&6
14736 echo "$as_me:14736: checking for alternate character set array" >&5
14737 echo $ECHO_N "checking for alternate character set array... $ECHO_C" >&6
14738 if test "${cf_cv_curses_acs_map+set}" = set; then
14739 echo $ECHO_N "(cached) $ECHO_C" >&6
14742 cf_cv_curses_acs_map=unknown
14743 for name in acs_map _acs_map __acs_map ${NCURSES_WRAP_PREFIX}acs_map
14745 cat >conftest.$ac_ext <<_ACEOF
14746 #line 14746 "configure"
14747 #include "confdefs.h"
14749 #include <${cf_cv_ncurses_header:-curses.h}>
14755 $name['k'] = ACS_PLUS
14761 rm -f conftest.$ac_objext conftest$ac_exeext
14762 if { (eval echo "$as_me:14762: \"$ac_link\"") >&5
14763 (eval $ac_link) 2>&5
14765 echo "$as_me:14765: \$? = $ac_status" >&5
14766 (exit $ac_status); } &&
14767 { ac_try='test -s conftest$ac_exeext'
14768 { (eval echo "$as_me:14768: \"$ac_try\"") >&5
14769 (eval $ac_try) 2>&5
14771 echo "$as_me:14771: \$? = $ac_status" >&5
14772 (exit $ac_status); }; }; then
14773 cf_cv_curses_acs_map=$name; break
14775 echo "$as_me: failed program was:" >&5
14776 cat conftest.$ac_ext >&5
14778 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14782 echo "$as_me:14782: result: $cf_cv_curses_acs_map" >&5
14783 echo "${ECHO_T}$cf_cv_curses_acs_map" >&6
14785 test "$cf_cv_curses_acs_map" != unknown && cat >>confdefs.h <<EOF
14786 #define CURSES_ACS_ARRAY $cf_cv_curses_acs_map
14789 if test "$cf_enable_widec" = yes; then
14791 echo "$as_me:14791: checking for wide alternate character set array" >&5
14792 echo $ECHO_N "checking for wide alternate character set array... $ECHO_C" >&6
14793 if test "${cf_cv_curses_wacs_map+set}" = set; then
14794 echo $ECHO_N "(cached) $ECHO_C" >&6
14797 cf_cv_curses_wacs_map=unknown
14798 for name in wacs_map _wacs_map __wacs_map _nc_wacs _wacs_char
14800 cat >conftest.$ac_ext <<_ACEOF
14801 #line 14801 "configure"
14802 #include "confdefs.h"
14804 #ifndef _XOPEN_SOURCE_EXTENDED
14805 #define _XOPEN_SOURCE_EXTENDED
14807 #include <${cf_cv_ncurses_header:-curses.h}>
14811 void *foo = &($name['k'])
14816 rm -f conftest.$ac_objext conftest$ac_exeext
14817 if { (eval echo "$as_me:14817: \"$ac_link\"") >&5
14818 (eval $ac_link) 2>&5
14820 echo "$as_me:14820: \$? = $ac_status" >&5
14821 (exit $ac_status); } &&
14822 { ac_try='test -s conftest$ac_exeext'
14823 { (eval echo "$as_me:14823: \"$ac_try\"") >&5
14824 (eval $ac_try) 2>&5
14826 echo "$as_me:14826: \$? = $ac_status" >&5
14827 (exit $ac_status); }; }; then
14828 cf_cv_curses_wacs_map=$name
14831 echo "$as_me: failed program was:" >&5
14832 cat conftest.$ac_ext >&5
14834 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14837 echo "$as_me:14837: result: $cf_cv_curses_wacs_map" >&5
14838 echo "${ECHO_T}$cf_cv_curses_wacs_map" >&6
14840 test "$cf_cv_curses_wacs_map" != unknown && cat >>confdefs.h <<EOF
14841 #define CURSES_WACS_ARRAY $cf_cv_curses_wacs_map
14844 echo "$as_me:14844: checking for wide alternate character constants" >&5
14845 echo $ECHO_N "checking for wide alternate character constants... $ECHO_C" >&6
14846 if test "${cf_cv_curses_wacs_symbols+set}" = set; then
14847 echo $ECHO_N "(cached) $ECHO_C" >&6
14850 cf_cv_curses_wacs_symbols=no
14851 if test "$cf_cv_curses_wacs_map" != unknown
14853 cat >conftest.$ac_ext <<_ACEOF
14854 #line 14854 "configure"
14855 #include "confdefs.h"
14857 #ifndef _XOPEN_SOURCE_EXTENDED
14858 #define _XOPEN_SOURCE_EXTENDED
14860 #include <${cf_cv_ncurses_header:-curses.h}>
14864 cchar_t *foo = WACS_PLUS;
14865 $cf_cv_curses_wacs_map['k'] = *WACS_PLUS
14870 rm -f conftest.$ac_objext conftest$ac_exeext
14871 if { (eval echo "$as_me:14871: \"$ac_link\"") >&5
14872 (eval $ac_link) 2>&5
14874 echo "$as_me:14874: \$? = $ac_status" >&5
14875 (exit $ac_status); } &&
14876 { ac_try='test -s conftest$ac_exeext'
14877 { (eval echo "$as_me:14877: \"$ac_try\"") >&5
14878 (eval $ac_try) 2>&5
14880 echo "$as_me:14880: \$? = $ac_status" >&5
14881 (exit $ac_status); }; }; then
14882 cf_cv_curses_wacs_symbols=yes
14884 echo "$as_me: failed program was:" >&5
14885 cat conftest.$ac_ext >&5
14887 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14889 cat >conftest.$ac_ext <<_ACEOF
14890 #line 14890 "configure"
14891 #include "confdefs.h"
14893 #ifndef _XOPEN_SOURCE_EXTENDED
14894 #define _XOPEN_SOURCE_EXTENDED
14896 #include <${cf_cv_ncurses_header:-curses.h}>
14900 cchar_t *foo = WACS_PLUS
14905 rm -f conftest.$ac_objext conftest$ac_exeext
14906 if { (eval echo "$as_me:14906: \"$ac_link\"") >&5
14907 (eval $ac_link) 2>&5
14909 echo "$as_me:14909: \$? = $ac_status" >&5
14910 (exit $ac_status); } &&
14911 { ac_try='test -s conftest$ac_exeext'
14912 { (eval echo "$as_me:14912: \"$ac_try\"") >&5
14913 (eval $ac_try) 2>&5
14915 echo "$as_me:14915: \$? = $ac_status" >&5
14916 (exit $ac_status); }; }; then
14917 cf_cv_curses_wacs_symbols=yes
14919 echo "$as_me: failed program was:" >&5
14920 cat conftest.$ac_ext >&5
14922 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14926 echo "$as_me:14926: result: $cf_cv_curses_wacs_symbols" >&5
14927 echo "${ECHO_T}$cf_cv_curses_wacs_symbols" >&6
14929 test "$cf_cv_curses_wacs_symbols" != no && cat >>confdefs.h <<\EOF
14930 #define CURSES_WACS_SYMBOLS 1
14935 echo "$as_me:14935: checking for type attr_t in ${cf_cv_ncurses_header:-curses.h}" >&5
14936 echo $ECHO_N "checking for type attr_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
14937 cat >conftest.$ac_ext <<_ACEOF
14938 #line 14938 "configure"
14939 #include "confdefs.h"
14941 #ifndef _XOPEN_SOURCE_EXTENDED
14942 #define _XOPEN_SOURCE_EXTENDED
14944 #include <${cf_cv_ncurses_header:-curses.h}>
14955 rm -f conftest.$ac_objext
14956 if { (eval echo "$as_me:14956: \"$ac_compile\"") >&5
14957 (eval $ac_compile) 2>&5
14959 echo "$as_me:14959: \$? = $ac_status" >&5
14960 (exit $ac_status); } &&
14961 { ac_try='test -s conftest.$ac_objext'
14962 { (eval echo "$as_me:14962: \"$ac_try\"") >&5
14963 (eval $ac_try) 2>&5
14965 echo "$as_me:14965: \$? = $ac_status" >&5
14966 (exit $ac_status); }; }; then
14969 echo "$as_me: failed program was:" >&5
14970 cat conftest.$ac_ext >&5
14973 rm -f conftest.$ac_objext conftest.$ac_ext
14974 echo "$as_me:14974: result: $cf_result" >&5
14975 echo "${ECHO_T}$cf_result" >&6
14976 if test $cf_result = yes ; then
14978 cf_result=`echo "have_type_attr_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14980 cat >>confdefs.h <<EOF
14981 #define $cf_result 1
14985 cat >>confdefs.h <<EOF
14986 #define attr_t long
14991 if test "$cf_enable_widec" = yes; then
14993 # This is needed on Tru64 5.0 to declare mbstate_t
14994 echo "$as_me:14994: checking if we must include wchar.h to declare mbstate_t" >&5
14995 echo $ECHO_N "checking if we must include wchar.h to declare mbstate_t... $ECHO_C" >&6
14996 if test "${cf_cv_mbstate_t+set}" = set; then
14997 echo $ECHO_N "(cached) $ECHO_C" >&6
15000 cat >conftest.$ac_ext <<_ACEOF
15001 #line 15001 "configure"
15002 #include "confdefs.h"
15004 #include <stdlib.h>
15005 #include <stdarg.h>
15007 #ifdef HAVE_LIBUTF8_H
15008 #include <libutf8.h>
15018 rm -f conftest.$ac_objext
15019 if { (eval echo "$as_me:15019: \"$ac_compile\"") >&5
15020 (eval $ac_compile) 2>&5
15022 echo "$as_me:15022: \$? = $ac_status" >&5
15023 (exit $ac_status); } &&
15024 { ac_try='test -s conftest.$ac_objext'
15025 { (eval echo "$as_me:15025: \"$ac_try\"") >&5
15026 (eval $ac_try) 2>&5
15028 echo "$as_me:15028: \$? = $ac_status" >&5
15029 (exit $ac_status); }; }; then
15032 echo "$as_me: failed program was:" >&5
15033 cat conftest.$ac_ext >&5
15034 cat >conftest.$ac_ext <<_ACEOF
15035 #line 15035 "configure"
15036 #include "confdefs.h"
15038 #include <stdlib.h>
15039 #include <stdarg.h>
15042 #ifdef HAVE_LIBUTF8_H
15043 #include <libutf8.h>
15053 rm -f conftest.$ac_objext
15054 if { (eval echo "$as_me:15054: \"$ac_compile\"") >&5
15055 (eval $ac_compile) 2>&5
15057 echo "$as_me:15057: \$? = $ac_status" >&5
15058 (exit $ac_status); } &&
15059 { ac_try='test -s conftest.$ac_objext'
15060 { (eval echo "$as_me:15060: \"$ac_try\"") >&5
15061 (eval $ac_try) 2>&5
15063 echo "$as_me:15063: \$? = $ac_status" >&5
15064 (exit $ac_status); }; }; then
15065 cf_cv_mbstate_t=yes
15067 echo "$as_me: failed program was:" >&5
15068 cat conftest.$ac_ext >&5
15069 cf_cv_mbstate_t=unknown
15071 rm -f conftest.$ac_objext conftest.$ac_ext
15073 rm -f conftest.$ac_objext conftest.$ac_ext
15075 echo "$as_me:15075: result: $cf_cv_mbstate_t" >&5
15076 echo "${ECHO_T}$cf_cv_mbstate_t" >&6
15078 if test "$cf_cv_mbstate_t" = yes ; then
15079 cat >>confdefs.h <<\EOF
15080 #define NEED_WCHAR_H 1
15086 # if we do not find mbstate_t in either place, use substitution to provide a fallback.
15087 if test "$cf_cv_mbstate_t" = unknown ; then
15088 NCURSES_MBSTATE_T=1
15091 # if we find mbstate_t in either place, use substitution to provide a fallback.
15092 if test "$cf_cv_mbstate_t" != unknown ; then
15093 NCURSES_OK_MBSTATE_T=1
15096 # This is needed on Tru64 5.0 to declare wchar_t
15097 echo "$as_me:15097: checking if we must include wchar.h to declare wchar_t" >&5
15098 echo $ECHO_N "checking if we must include wchar.h to declare wchar_t... $ECHO_C" >&6
15099 if test "${cf_cv_wchar_t+set}" = set; then
15100 echo $ECHO_N "(cached) $ECHO_C" >&6
15103 cat >conftest.$ac_ext <<_ACEOF
15104 #line 15104 "configure"
15105 #include "confdefs.h"
15107 #include <stdlib.h>
15108 #include <stdarg.h>
15110 #ifdef HAVE_LIBUTF8_H
15111 #include <libutf8.h>
15121 rm -f conftest.$ac_objext
15122 if { (eval echo "$as_me:15122: \"$ac_compile\"") >&5
15123 (eval $ac_compile) 2>&5
15125 echo "$as_me:15125: \$? = $ac_status" >&5
15126 (exit $ac_status); } &&
15127 { ac_try='test -s conftest.$ac_objext'
15128 { (eval echo "$as_me:15128: \"$ac_try\"") >&5
15129 (eval $ac_try) 2>&5
15131 echo "$as_me:15131: \$? = $ac_status" >&5
15132 (exit $ac_status); }; }; then
15135 echo "$as_me: failed program was:" >&5
15136 cat conftest.$ac_ext >&5
15137 cat >conftest.$ac_ext <<_ACEOF
15138 #line 15138 "configure"
15139 #include "confdefs.h"
15141 #include <stdlib.h>
15142 #include <stdarg.h>
15145 #ifdef HAVE_LIBUTF8_H
15146 #include <libutf8.h>
15156 rm -f conftest.$ac_objext
15157 if { (eval echo "$as_me:15157: \"$ac_compile\"") >&5
15158 (eval $ac_compile) 2>&5
15160 echo "$as_me:15160: \$? = $ac_status" >&5
15161 (exit $ac_status); } &&
15162 { ac_try='test -s conftest.$ac_objext'
15163 { (eval echo "$as_me:15163: \"$ac_try\"") >&5
15164 (eval $ac_try) 2>&5
15166 echo "$as_me:15166: \$? = $ac_status" >&5
15167 (exit $ac_status); }; }; then
15170 echo "$as_me: failed program was:" >&5
15171 cat conftest.$ac_ext >&5
15172 cf_cv_wchar_t=unknown
15174 rm -f conftest.$ac_objext conftest.$ac_ext
15176 rm -f conftest.$ac_objext conftest.$ac_ext
15178 echo "$as_me:15178: result: $cf_cv_wchar_t" >&5
15179 echo "${ECHO_T}$cf_cv_wchar_t" >&6
15181 if test "$cf_cv_wchar_t" = yes ; then
15182 cat >>confdefs.h <<\EOF
15183 #define NEED_WCHAR_H 1
15189 # if we do not find wchar_t in either place, use substitution to provide a fallback.
15190 if test "$cf_cv_wchar_t" = unknown ; then
15194 # if we find wchar_t in either place, use substitution to provide a fallback.
15195 if test "$cf_cv_wchar_t" != unknown ; then
15196 NCURSES_OK_WCHAR_T=1
15199 # This is needed on Tru64 5.0 to declare wint_t
15200 echo "$as_me:15200: checking if we must include wchar.h to declare wint_t" >&5
15201 echo $ECHO_N "checking if we must include wchar.h to declare wint_t... $ECHO_C" >&6
15202 if test "${cf_cv_wint_t+set}" = set; then
15203 echo $ECHO_N "(cached) $ECHO_C" >&6
15206 cat >conftest.$ac_ext <<_ACEOF
15207 #line 15207 "configure"
15208 #include "confdefs.h"
15210 #include <stdlib.h>
15211 #include <stdarg.h>
15213 #ifdef HAVE_LIBUTF8_H
15214 #include <libutf8.h>
15224 rm -f conftest.$ac_objext
15225 if { (eval echo "$as_me:15225: \"$ac_compile\"") >&5
15226 (eval $ac_compile) 2>&5
15228 echo "$as_me:15228: \$? = $ac_status" >&5
15229 (exit $ac_status); } &&
15230 { ac_try='test -s conftest.$ac_objext'
15231 { (eval echo "$as_me:15231: \"$ac_try\"") >&5
15232 (eval $ac_try) 2>&5
15234 echo "$as_me:15234: \$? = $ac_status" >&5
15235 (exit $ac_status); }; }; then
15238 echo "$as_me: failed program was:" >&5
15239 cat conftest.$ac_ext >&5
15240 cat >conftest.$ac_ext <<_ACEOF
15241 #line 15241 "configure"
15242 #include "confdefs.h"
15244 #include <stdlib.h>
15245 #include <stdarg.h>
15248 #ifdef HAVE_LIBUTF8_H
15249 #include <libutf8.h>
15259 rm -f conftest.$ac_objext
15260 if { (eval echo "$as_me:15260: \"$ac_compile\"") >&5
15261 (eval $ac_compile) 2>&5
15263 echo "$as_me:15263: \$? = $ac_status" >&5
15264 (exit $ac_status); } &&
15265 { ac_try='test -s conftest.$ac_objext'
15266 { (eval echo "$as_me:15266: \"$ac_try\"") >&5
15267 (eval $ac_try) 2>&5
15269 echo "$as_me:15269: \$? = $ac_status" >&5
15270 (exit $ac_status); }; }; then
15273 echo "$as_me: failed program was:" >&5
15274 cat conftest.$ac_ext >&5
15275 cf_cv_wint_t=unknown
15277 rm -f conftest.$ac_objext conftest.$ac_ext
15279 rm -f conftest.$ac_objext conftest.$ac_ext
15281 echo "$as_me:15281: result: $cf_cv_wint_t" >&5
15282 echo "${ECHO_T}$cf_cv_wint_t" >&6
15284 if test "$cf_cv_wint_t" = yes ; then
15285 cat >>confdefs.h <<\EOF
15286 #define NEED_WCHAR_H 1
15292 # if we do not find wint_t in either place, use substitution to provide a fallback.
15293 if test "$cf_cv_wint_t" = unknown ; then
15297 # if we find wint_t in either place, use substitution to provide a fallback.
15298 if test "$cf_cv_wint_t" != unknown ; then
15299 NCURSES_OK_WINT_T=1
15302 if test "$NCURSES_OK_MBSTATE_T" = 0 ; then
15304 echo "$as_me:15304: checking for type mbstate_t in ${cf_cv_ncurses_header:-curses.h}" >&5
15305 echo $ECHO_N "checking for type mbstate_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
15306 cat >conftest.$ac_ext <<_ACEOF
15307 #line 15307 "configure"
15308 #include "confdefs.h"
15310 #ifndef _XOPEN_SOURCE_EXTENDED
15311 #define _XOPEN_SOURCE_EXTENDED
15313 #include <${cf_cv_ncurses_header:-curses.h}>
15324 rm -f conftest.$ac_objext
15325 if { (eval echo "$as_me:15325: \"$ac_compile\"") >&5
15326 (eval $ac_compile) 2>&5
15328 echo "$as_me:15328: \$? = $ac_status" >&5
15329 (exit $ac_status); } &&
15330 { ac_try='test -s conftest.$ac_objext'
15331 { (eval echo "$as_me:15331: \"$ac_try\"") >&5
15332 (eval $ac_try) 2>&5
15334 echo "$as_me:15334: \$? = $ac_status" >&5
15335 (exit $ac_status); }; }; then
15338 echo "$as_me: failed program was:" >&5
15339 cat conftest.$ac_ext >&5
15342 rm -f conftest.$ac_objext conftest.$ac_ext
15343 echo "$as_me:15343: result: $cf_result" >&5
15344 echo "${ECHO_T}$cf_result" >&6
15345 if test $cf_result = yes ; then
15347 cf_result=`echo "have_type_mbstate_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
15349 cat >>confdefs.h <<EOF
15350 #define $cf_result 1
15354 cat >>confdefs.h <<EOF
15355 #define mbstate_t long
15362 if test "$NCURSES_OK_WCHAR_T" = 0 ; then
15364 echo "$as_me:15364: checking for type wchar_t in ${cf_cv_ncurses_header:-curses.h}" >&5
15365 echo $ECHO_N "checking for type wchar_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
15366 cat >conftest.$ac_ext <<_ACEOF
15367 #line 15367 "configure"
15368 #include "confdefs.h"
15370 #ifndef _XOPEN_SOURCE_EXTENDED
15371 #define _XOPEN_SOURCE_EXTENDED
15373 #include <${cf_cv_ncurses_header:-curses.h}>
15384 rm -f conftest.$ac_objext
15385 if { (eval echo "$as_me:15385: \"$ac_compile\"") >&5
15386 (eval $ac_compile) 2>&5
15388 echo "$as_me:15388: \$? = $ac_status" >&5
15389 (exit $ac_status); } &&
15390 { ac_try='test -s conftest.$ac_objext'
15391 { (eval echo "$as_me:15391: \"$ac_try\"") >&5
15392 (eval $ac_try) 2>&5
15394 echo "$as_me:15394: \$? = $ac_status" >&5
15395 (exit $ac_status); }; }; then
15398 echo "$as_me: failed program was:" >&5
15399 cat conftest.$ac_ext >&5
15402 rm -f conftest.$ac_objext conftest.$ac_ext
15403 echo "$as_me:15403: result: $cf_result" >&5
15404 echo "${ECHO_T}$cf_result" >&6
15405 if test $cf_result = yes ; then
15407 cf_result=`echo "have_type_wchar_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
15409 cat >>confdefs.h <<EOF
15410 #define $cf_result 1
15414 cat >>confdefs.h <<EOF
15415 #define wchar_t long
15422 if test "$NCURSES_OK_WINT_T" = 0 ; then
15424 echo "$as_me:15424: checking for type wint_t in ${cf_cv_ncurses_header:-curses.h}" >&5
15425 echo $ECHO_N "checking for type wint_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
15426 cat >conftest.$ac_ext <<_ACEOF
15427 #line 15427 "configure"
15428 #include "confdefs.h"
15430 #ifndef _XOPEN_SOURCE_EXTENDED
15431 #define _XOPEN_SOURCE_EXTENDED
15433 #include <${cf_cv_ncurses_header:-curses.h}>
15444 rm -f conftest.$ac_objext
15445 if { (eval echo "$as_me:15445: \"$ac_compile\"") >&5
15446 (eval $ac_compile) 2>&5
15448 echo "$as_me:15448: \$? = $ac_status" >&5
15449 (exit $ac_status); } &&
15450 { ac_try='test -s conftest.$ac_objext'
15451 { (eval echo "$as_me:15451: \"$ac_try\"") >&5
15452 (eval $ac_try) 2>&5
15454 echo "$as_me:15454: \$? = $ac_status" >&5
15455 (exit $ac_status); }; }; then
15458 echo "$as_me: failed program was:" >&5
15459 cat conftest.$ac_ext >&5
15462 rm -f conftest.$ac_objext conftest.$ac_ext
15463 echo "$as_me:15463: result: $cf_result" >&5
15464 echo "${ECHO_T}$cf_result" >&6
15465 if test $cf_result = yes ; then
15467 cf_result=`echo "have_type_wint_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
15469 cat >>confdefs.h <<EOF
15470 #define $cf_result 1
15474 cat >>confdefs.h <<EOF
15475 #define wint_t long
15483 echo "$as_me:15483: checking for data boolnames declaration in ${cf_cv_ncurses_header:-curses.h}" >&5
15484 echo $ECHO_N "checking for data boolnames declaration in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
15486 cat >conftest.$ac_ext <<_ACEOF
15487 #line 15487 "configure"
15488 #include "confdefs.h"
15490 #ifdef HAVE_XCURSES
15491 #include <xcurses.h>
15492 char * XCursesProgramName = "test";
15494 #include <${cf_cv_ncurses_header:-curses.h}>
15495 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
15496 #include <ncursesw/term.h>
15497 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
15498 #include <ncurses/term.h>
15499 #elif defined(HAVE_TERM_H)
15508 void *foo = &(boolnames)
15514 rm -f conftest.$ac_objext
15515 if { (eval echo "$as_me:15515: \"$ac_compile\"") >&5
15516 (eval $ac_compile) 2>&5
15518 echo "$as_me:15518: \$? = $ac_status" >&5
15519 (exit $ac_status); } &&
15520 { ac_try='test -s conftest.$ac_objext'
15521 { (eval echo "$as_me:15521: \"$ac_try\"") >&5
15522 (eval $ac_try) 2>&5
15524 echo "$as_me:15524: \$? = $ac_status" >&5
15525 (exit $ac_status); }; }; then
15528 echo "$as_me: failed program was:" >&5
15529 cat conftest.$ac_ext >&5
15532 rm -f conftest.$ac_objext conftest.$ac_ext
15533 echo "$as_me:15533: result: $cf_result" >&5
15534 echo "${ECHO_T}$cf_result" >&6
15536 if test $cf_result = yes ; then
15538 cf_result=`echo "have_curses_data_boolnames" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
15540 cat >>confdefs.h <<EOF
15541 #define $cf_result 1
15545 echo "$as_me:15545: checking for data boolnames in library" >&5
15546 echo $ECHO_N "checking for data boolnames in library... $ECHO_C" >&6
15547 # BSD linkers insist on making weak linkage, but resolve at runtime.
15548 if test "$cross_compiling" = yes; then
15551 cat >conftest.$ac_ext <<_ACEOF
15552 #line 15552 "configure"
15553 #include "confdefs.h"
15555 #ifdef HAVE_XCURSES
15556 #include <xcurses.h>
15557 char * XCursesProgramName = "test";
15559 #include <${cf_cv_ncurses_header:-curses.h}>
15560 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
15561 #include <ncursesw/term.h>
15562 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
15563 #include <ncurses/term.h>
15564 #elif defined(HAVE_TERM_H)
15569 extern char boolnames;
15575 void *foo = &(boolnames);
15576 ${cf_cv_main_return:-return}(foo == 0);
15583 rm -f conftest.$ac_objext conftest$ac_exeext
15584 if { (eval echo "$as_me:15584: \"$ac_link\"") >&5
15585 (eval $ac_link) 2>&5
15587 echo "$as_me:15587: \$? = $ac_status" >&5
15588 (exit $ac_status); } &&
15589 { ac_try='test -s conftest$ac_exeext'
15590 { (eval echo "$as_me:15590: \"$ac_try\"") >&5
15591 (eval $ac_try) 2>&5
15593 echo "$as_me:15593: \$? = $ac_status" >&5
15594 (exit $ac_status); }; }; then
15597 echo "$as_me: failed program was:" >&5
15598 cat conftest.$ac_ext >&5
15601 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15604 cat >conftest.$ac_ext <<_ACEOF
15605 #line 15605 "configure"
15606 #include "confdefs.h"
15608 #ifdef HAVE_XCURSES
15609 #include <xcurses.h>
15610 char * XCursesProgramName = "test";
15612 #include <${cf_cv_ncurses_header:-curses.h}>
15613 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
15614 #include <ncursesw/term.h>
15615 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
15616 #include <ncurses/term.h>
15617 #elif defined(HAVE_TERM_H)
15622 extern char boolnames;
15625 void *foo = &(boolnames);
15626 ${cf_cv_main_return:-return}(foo == 0);
15629 rm -f conftest$ac_exeext
15630 if { (eval echo "$as_me:15630: \"$ac_link\"") >&5
15631 (eval $ac_link) 2>&5
15633 echo "$as_me:15633: \$? = $ac_status" >&5
15634 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15635 { (eval echo "$as_me:15635: \"$ac_try\"") >&5
15636 (eval $ac_try) 2>&5
15638 echo "$as_me:15638: \$? = $ac_status" >&5
15639 (exit $ac_status); }; }; then
15642 echo "$as_me: program exited with status $ac_status" >&5
15643 echo "$as_me: failed program was:" >&5
15644 cat conftest.$ac_ext >&5
15647 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15649 echo "$as_me:15649: result: $cf_result" >&5
15650 echo "${ECHO_T}$cf_result" >&6
15651 if test $cf_result = yes ; then
15653 cf_result=`echo "decl_curses_data_boolnames" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
15655 cat >>confdefs.h <<EOF
15656 #define $cf_result 1
15662 echo "$as_me:15662: checking for data boolfnames declaration in ${cf_cv_ncurses_header:-curses.h}" >&5
15663 echo $ECHO_N "checking for data boolfnames declaration in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
15665 cat >conftest.$ac_ext <<_ACEOF
15666 #line 15666 "configure"
15667 #include "confdefs.h"
15669 #ifdef HAVE_XCURSES
15670 #include <xcurses.h>
15671 char * XCursesProgramName = "test";
15673 #include <${cf_cv_ncurses_header:-curses.h}>
15674 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
15675 #include <ncursesw/term.h>
15676 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
15677 #include <ncurses/term.h>
15678 #elif defined(HAVE_TERM_H)
15687 void *foo = &(boolfnames)
15693 rm -f conftest.$ac_objext
15694 if { (eval echo "$as_me:15694: \"$ac_compile\"") >&5
15695 (eval $ac_compile) 2>&5
15697 echo "$as_me:15697: \$? = $ac_status" >&5
15698 (exit $ac_status); } &&
15699 { ac_try='test -s conftest.$ac_objext'
15700 { (eval echo "$as_me:15700: \"$ac_try\"") >&5
15701 (eval $ac_try) 2>&5
15703 echo "$as_me:15703: \$? = $ac_status" >&5
15704 (exit $ac_status); }; }; then
15707 echo "$as_me: failed program was:" >&5
15708 cat conftest.$ac_ext >&5
15711 rm -f conftest.$ac_objext conftest.$ac_ext
15712 echo "$as_me:15712: result: $cf_result" >&5
15713 echo "${ECHO_T}$cf_result" >&6
15715 if test $cf_result = yes ; then
15717 cf_result=`echo "have_curses_data_boolfnames" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
15719 cat >>confdefs.h <<EOF
15720 #define $cf_result 1
15724 echo "$as_me:15724: checking for data boolfnames in library" >&5
15725 echo $ECHO_N "checking for data boolfnames in library... $ECHO_C" >&6
15726 # BSD linkers insist on making weak linkage, but resolve at runtime.
15727 if test "$cross_compiling" = yes; then
15730 cat >conftest.$ac_ext <<_ACEOF
15731 #line 15731 "configure"
15732 #include "confdefs.h"
15734 #ifdef HAVE_XCURSES
15735 #include <xcurses.h>
15736 char * XCursesProgramName = "test";
15738 #include <${cf_cv_ncurses_header:-curses.h}>
15739 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
15740 #include <ncursesw/term.h>
15741 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
15742 #include <ncurses/term.h>
15743 #elif defined(HAVE_TERM_H)
15748 extern char boolfnames;
15754 void *foo = &(boolfnames);
15755 ${cf_cv_main_return:-return}(foo == 0);
15762 rm -f conftest.$ac_objext conftest$ac_exeext
15763 if { (eval echo "$as_me:15763: \"$ac_link\"") >&5
15764 (eval $ac_link) 2>&5
15766 echo "$as_me:15766: \$? = $ac_status" >&5
15767 (exit $ac_status); } &&
15768 { ac_try='test -s conftest$ac_exeext'
15769 { (eval echo "$as_me:15769: \"$ac_try\"") >&5
15770 (eval $ac_try) 2>&5
15772 echo "$as_me:15772: \$? = $ac_status" >&5
15773 (exit $ac_status); }; }; then
15776 echo "$as_me: failed program was:" >&5
15777 cat conftest.$ac_ext >&5
15780 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15783 cat >conftest.$ac_ext <<_ACEOF
15784 #line 15784 "configure"
15785 #include "confdefs.h"
15787 #ifdef HAVE_XCURSES
15788 #include <xcurses.h>
15789 char * XCursesProgramName = "test";
15791 #include <${cf_cv_ncurses_header:-curses.h}>
15792 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
15793 #include <ncursesw/term.h>
15794 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
15795 #include <ncurses/term.h>
15796 #elif defined(HAVE_TERM_H)
15801 extern char boolfnames;
15804 void *foo = &(boolfnames);
15805 ${cf_cv_main_return:-return}(foo == 0);
15808 rm -f conftest$ac_exeext
15809 if { (eval echo "$as_me:15809: \"$ac_link\"") >&5
15810 (eval $ac_link) 2>&5
15812 echo "$as_me:15812: \$? = $ac_status" >&5
15813 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15814 { (eval echo "$as_me:15814: \"$ac_try\"") >&5
15815 (eval $ac_try) 2>&5
15817 echo "$as_me:15817: \$? = $ac_status" >&5
15818 (exit $ac_status); }; }; then
15821 echo "$as_me: program exited with status $ac_status" >&5
15822 echo "$as_me: failed program was:" >&5
15823 cat conftest.$ac_ext >&5
15826 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15828 echo "$as_me:15828: result: $cf_result" >&5
15829 echo "${ECHO_T}$cf_result" >&6
15830 if test $cf_result = yes ; then
15832 cf_result=`echo "decl_curses_data_boolfnames" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
15834 cat >>confdefs.h <<EOF
15835 #define $cf_result 1
15842 echo "$as_me:15842: checking for an rpath option" >&5
15843 echo $ECHO_N "checking for an rpath option... $ECHO_C" >&6
15844 case $cf_cv_system_name in #(vi
15846 if test "$GCC" = yes; then
15847 LD_RPATH_OPT="-Wl,-rpath,"
15849 LD_RPATH_OPT="-rpath "
15852 linux*|gnu*|k*bsd*-gnu) #(vi
15853 LD_RPATH_OPT="-Wl,-rpath,"
15855 openbsd[2-9].*|mirbsd*) #(vi
15856 LD_RPATH_OPT="-Wl,-rpath,"
15858 dragonfly*|freebsd*) #(vi
15859 LD_RPATH_OPT="-rpath "
15862 LD_RPATH_OPT="-Wl,-rpath,"
15865 LD_RPATH_OPT="-rpath "
15873 echo "$as_me:15873: result: $LD_RPATH_OPT" >&5
15874 echo "${ECHO_T}$LD_RPATH_OPT" >&6
15876 case "x$LD_RPATH_OPT" in #(vi
15878 echo "$as_me:15878: checking if we need a space after rpath option" >&5
15879 echo $ECHO_N "checking if we need a space after rpath option... $ECHO_C" >&6
15880 cf_save_LIBS="$LIBS"
15881 LIBS="${LD_RPATH_OPT}$libdir $LIBS"
15882 cat >conftest.$ac_ext <<_ACEOF
15883 #line 15883 "configure"
15884 #include "confdefs.h"
15894 rm -f conftest.$ac_objext conftest$ac_exeext
15895 if { (eval echo "$as_me:15895: \"$ac_link\"") >&5
15896 (eval $ac_link) 2>&5
15898 echo "$as_me:15898: \$? = $ac_status" >&5
15899 (exit $ac_status); } &&
15900 { ac_try='test -s conftest$ac_exeext'
15901 { (eval echo "$as_me:15901: \"$ac_try\"") >&5
15902 (eval $ac_try) 2>&5
15904 echo "$as_me:15904: \$? = $ac_status" >&5
15905 (exit $ac_status); }; }; then
15908 echo "$as_me: failed program was:" >&5
15909 cat conftest.$ac_ext >&5
15912 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15913 LIBS="$cf_save_LIBS"
15914 echo "$as_me:15914: result: $cf_rpath_space" >&5
15915 echo "${ECHO_T}$cf_rpath_space" >&6
15916 test "$cf_rpath_space" = yes && LD_RPATH_OPT="$LD_RPATH_OPT "
15920 echo "$as_me:15920: checking if rpath-hack should be disabled" >&5
15921 echo $ECHO_N "checking if rpath-hack should be disabled... $ECHO_C" >&6
15923 # Check whether --enable-rpath-hack or --disable-rpath-hack was given.
15924 if test "${enable_rpath_hack+set}" = set; then
15925 enableval="$enable_rpath_hack"
15926 test "$enableval" != no && enableval=yes
15927 if test "$enableval" != "yes" ; then
15928 cf_disable_rpath_hack=yes
15930 cf_disable_rpath_hack=no
15934 cf_disable_rpath_hack=no
15937 echo "$as_me:15937: result: $cf_disable_rpath_hack" >&5
15938 echo "${ECHO_T}$cf_disable_rpath_hack" >&6
15939 if test "$cf_disable_rpath_hack" = no ; then
15941 echo "$as_me:15941: checking for updated LDFLAGS" >&5
15942 echo $ECHO_N "checking for updated LDFLAGS... $ECHO_C" >&6
15943 if test -n "$LD_RPATH_OPT" ; then
15944 echo "$as_me:15944: result: maybe" >&5
15945 echo "${ECHO_T}maybe" >&6
15949 # Extract the first word of "$ac_prog", so it can be a program name with args.
15950 set dummy $ac_prog; ac_word=$2
15951 echo "$as_me:15951: checking for $ac_word" >&5
15952 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
15953 if test "${ac_cv_prog_cf_ldd_prog+set}" = set; then
15954 echo $ECHO_N "(cached) $ECHO_C" >&6
15956 if test -n "$cf_ldd_prog"; then
15957 ac_cv_prog_cf_ldd_prog="$cf_ldd_prog" # Let the user override the test.
15959 ac_save_IFS=$IFS; IFS=$ac_path_separator
15961 for ac_dir in $ac_dummy; do
15963 test -z "$ac_dir" && ac_dir=.
15964 $as_executable_p "$ac_dir/$ac_word" || continue
15965 ac_cv_prog_cf_ldd_prog="$ac_prog"
15966 echo "$as_me:15966: found $ac_dir/$ac_word" >&5
15972 cf_ldd_prog=$ac_cv_prog_cf_ldd_prog
15973 if test -n "$cf_ldd_prog"; then
15974 echo "$as_me:15974: result: $cf_ldd_prog" >&5
15975 echo "${ECHO_T}$cf_ldd_prog" >&6
15977 echo "$as_me:15977: result: no" >&5
15978 echo "${ECHO_T}no" >&6
15981 test -n "$cf_ldd_prog" && break
15983 test -n "$cf_ldd_prog" || cf_ldd_prog="no"
15985 cf_rpath_list="/usr/lib /lib"
15986 if test "$cf_ldd_prog" != no
15990 cat >conftest.$ac_ext <<_ACEOF
15991 #line 15991 "configure"
15992 #include "confdefs.h"
16002 rm -f conftest.$ac_objext conftest$ac_exeext
16003 if { (eval echo "$as_me:16003: \"$ac_link\"") >&5
16004 (eval $ac_link) 2>&5
16006 echo "$as_me:16006: \$? = $ac_status" >&5
16007 (exit $ac_status); } &&
16008 { ac_try='test -s conftest$ac_exeext'
16009 { (eval echo "$as_me:16009: \"$ac_try\"") >&5
16010 (eval $ac_try) 2>&5
16012 echo "$as_me:16012: \$? = $ac_status" >&5
16013 (exit $ac_status); }; }; then
16014 cf_rpath_oops=`$cf_ldd_prog conftest$ac_exeext | fgrep ' not found' | sed -e 's% =>.*$%%' |sort -u`
16015 cf_rpath_list=`$cf_ldd_prog conftest$ac_exeext | fgrep / | sed -e 's%^.*[ ]/%/%' -e 's%/[^/][^/]*$%%' |sort -u`
16017 echo "$as_me: failed program was:" >&5
16018 cat conftest.$ac_ext >&5
16020 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16022 # If we passed the link-test, but get a "not found" on a given library,
16023 # this could be due to inept reconfiguration of gcc to make it only
16024 # partly honor /usr/local/lib (or whatever). Sometimes this behavior
16025 # is intentional, e.g., installing gcc in /usr/bin and suppressing the
16026 # /usr/local libraries.
16027 if test -n "$cf_rpath_oops"
16029 for cf_rpath_src in $cf_rpath_oops
16031 for cf_rpath_dir in \
16036 if test -f $cf_rpath_dir/lib/$cf_rpath_src
16038 test -n "$verbose" && echo " ...adding -L$cf_rpath_dir/lib to LDFLAGS for $cf_rpath_src" 1>&6
16040 echo "${as_me:-configure}:16040: testing ...adding -L$cf_rpath_dir/lib to LDFLAGS for $cf_rpath_src ..." 1>&5
16042 LDFLAGS="$LDFLAGS -L$cf_rpath_dir/lib"
16050 test -n "$verbose" && echo " ...checking EXTRA_LDFLAGS $EXTRA_LDFLAGS" 1>&6
16052 echo "${as_me:-configure}:16052: testing ...checking EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5
16054 test -n "$verbose" && echo " ...checking LDFLAGS $LDFLAGS" 1>&6
16056 echo "${as_me:-configure}:16056: testing ...checking LDFLAGS $LDFLAGS ..." 1>&5
16059 for cf_rpath_src in $LDFLAGS
16061 case $cf_rpath_src in #(vi
16064 # check if this refers to a directory which we will ignore
16066 if test -n "$cf_rpath_list"
16068 for cf_rpath_item in $cf_rpath_list
16070 if test "x$cf_rpath_src" = "x-L$cf_rpath_item"
16078 if test "$cf_rpath_skip" = no
16080 # transform the option
16081 if test "$LD_RPATH_OPT" = "-R " ; then
16082 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%-R %"`
16084 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%$LD_RPATH_OPT%"`
16087 # if we have not already added this, add it now
16088 cf_rpath_tst=`echo "$EXTRA_LDFLAGS" | sed -e "s%$cf_rpath_tmp %%"`
16089 if test "x$cf_rpath_tst" = "x$EXTRA_LDFLAGS"
16091 test -n "$verbose" && echo " ...Filter $cf_rpath_src ->$cf_rpath_tmp" 1>&6
16093 echo "${as_me:-configure}:16093: testing ...Filter $cf_rpath_src ->$cf_rpath_tmp ..." 1>&5
16095 EXTRA_LDFLAGS="$cf_rpath_tmp $EXTRA_LDFLAGS"
16100 cf_rpath_dst="$cf_rpath_dst $cf_rpath_src"
16102 LDFLAGS=$cf_rpath_dst
16104 test -n "$verbose" && echo " ...checked LDFLAGS $LDFLAGS" 1>&6
16106 echo "${as_me:-configure}:16106: testing ...checked LDFLAGS $LDFLAGS ..." 1>&5
16108 test -n "$verbose" && echo " ...checking LIBS $LIBS" 1>&6
16110 echo "${as_me:-configure}:16110: testing ...checking LIBS $LIBS ..." 1>&5
16113 for cf_rpath_src in $LIBS
16115 case $cf_rpath_src in #(vi
16118 # check if this refers to a directory which we will ignore
16120 if test -n "$cf_rpath_list"
16122 for cf_rpath_item in $cf_rpath_list
16124 if test "x$cf_rpath_src" = "x-L$cf_rpath_item"
16132 if test "$cf_rpath_skip" = no
16134 # transform the option
16135 if test "$LD_RPATH_OPT" = "-R " ; then
16136 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%-R %"`
16138 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%$LD_RPATH_OPT%"`
16141 # if we have not already added this, add it now
16142 cf_rpath_tst=`echo "$EXTRA_LDFLAGS" | sed -e "s%$cf_rpath_tmp %%"`
16143 if test "x$cf_rpath_tst" = "x$EXTRA_LDFLAGS"
16145 test -n "$verbose" && echo " ...Filter $cf_rpath_src ->$cf_rpath_tmp" 1>&6
16147 echo "${as_me:-configure}:16147: testing ...Filter $cf_rpath_src ->$cf_rpath_tmp ..." 1>&5
16149 EXTRA_LDFLAGS="$cf_rpath_tmp $EXTRA_LDFLAGS"
16154 cf_rpath_dst="$cf_rpath_dst $cf_rpath_src"
16158 test -n "$verbose" && echo " ...checked LIBS $LIBS" 1>&6
16160 echo "${as_me:-configure}:16160: testing ...checked LIBS $LIBS ..." 1>&5
16162 test -n "$verbose" && echo " ...checked EXTRA_LDFLAGS $EXTRA_LDFLAGS" 1>&6
16164 echo "${as_me:-configure}:16164: testing ...checked EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5
16173 ac_config_files="$ac_config_files Makefile"
16174 ac_config_commands="$ac_config_commands default"
16175 cat >confcache <<\_ACEOF
16176 # This file is a shell script that caches the results of configure
16177 # tests run on this system so they can be shared between configure
16178 # scripts and configure runs, see configure's option --config-cache.
16179 # It is not useful on other systems. If it contains results you don't
16180 # want to keep, you may remove or edit it.
16182 # config.status only pays attention to the cache file if you give it
16183 # the --recheck option to rerun configure.
16185 # `ac_cv_env_foo' variables (set or unset) will be overriden when
16186 # loading this file, other *unset* `ac_cv_foo' will be assigned the
16187 # following values.
16191 # The following way of writing the cache mishandles newlines in values,
16192 # but we know of no workaround that is simple, portable, and efficient.
16193 # So, don't put newlines in cache variables' values.
16194 # Ultrix sh set writes to stderr and can't be redirected directly,
16195 # and sets the high bit in the cache file unless we assign to the vars.
16198 case `(ac_space=' '; set | grep ac_space) 2>&1` in
16200 # `set' does not quote correctly, so add quotes (double-quote
16201 # substitution turns \\\\ into \\, and sed turns \\ into \).
16204 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
16207 # `set' quotes correctly as required by POSIX, so do not add quotes.
16209 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
16216 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
16218 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
16220 if cmp -s $cache_file confcache; then :; else
16221 if test -w $cache_file; then
16222 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
16223 cat confcache >$cache_file
16225 echo "not updating unwritable cache $cache_file"
16230 test "x$prefix" = xNONE && prefix=$ac_default_prefix
16231 # Let make expand exec_prefix.
16232 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
16234 # VPATH may cause trouble with some makes, so we remove $(srcdir),
16235 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
16236 # trailing colons and then remove the whole line if VPATH becomes empty
16237 # (actually we leave an empty line to preserve line numbers).
16238 if test "x$srcdir" = x.; then
16239 ac_vpsub='/^[ ]*VPATH[ ]*=/{
16240 s/:*\$(srcdir):*/:/;
16241 s/:*\${srcdir}:*/:/;
16243 s/^\([^=]*=[ ]*\):*/\1/;
16249 DEFS=-DHAVE_CONFIG_H
16251 : ${CONFIG_STATUS=./config.status}
16252 ac_clean_files_save=$ac_clean_files
16253 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
16254 { echo "$as_me:16254: creating $CONFIG_STATUS" >&5
16255 echo "$as_me: creating $CONFIG_STATUS" >&6;}
16256 cat >$CONFIG_STATUS <<_ACEOF
16258 # Generated automatically by configure.
16259 # Run this file to recreate the current configuration.
16260 # Compiler output produced by configure, useful for debugging
16261 # configure, is in config.log if it exists.
16264 SHELL=\${CONFIG_SHELL-$SHELL}
16265 ac_cs_invocation="\$0 \$@"
16269 cat >>$CONFIG_STATUS <<\_ACEOF
16270 # Be Bourne compatible
16271 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
16274 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
16278 # Name of the executable.
16279 as_me=`echo "$0" |sed 's,.*[\\/],,'`
16281 if expr a : '\(a\)' >/dev/null 2>&1; then
16287 rm -f conf$$ conf$$.exe conf$$.file
16289 if ln -s conf$$.file conf$$ 2>/dev/null; then
16290 # We could just check for DJGPP; but this test a) works b) is more generic
16291 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
16292 if test -f conf$$.exe; then
16293 # Don't use ln at all; we don't have any links
16298 elif ln conf$$.file conf$$ 2>/dev/null; then
16303 rm -f conf$$ conf$$.exe conf$$.file
16305 as_executable_p="test -f"
16307 # Support unset when possible.
16308 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
16315 $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
16316 $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
16317 $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
16318 $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
16319 $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
16320 $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
16321 $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
16322 $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
16325 # We need space, tab and new line, in precisely that order.
16331 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
16337 # Files that config.status was made for.
16338 if test -n "$ac_config_files"; then
16339 echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
16342 if test -n "$ac_config_headers"; then
16343 echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
16346 if test -n "$ac_config_links"; then
16347 echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
16350 if test -n "$ac_config_commands"; then
16351 echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
16354 cat >>$CONFIG_STATUS <<\EOF
16357 \`$as_me' instantiates files from templates according to the
16358 current configuration.
16360 Usage: $0 [OPTIONS] [FILE]...
16362 -h, --help print this help, then exit
16363 -V, --version print version number, then exit
16364 -d, --debug don't remove temporary files
16365 --recheck update $as_me by reconfiguring in the same conditions
16366 --file=FILE[:TEMPLATE]
16367 instantiate the configuration file FILE
16368 --header=FILE[:TEMPLATE]
16369 instantiate the configuration header FILE
16371 Configuration files:
16374 Configuration headers:
16377 Configuration commands:
16380 Report bugs to <dickey@invisible-island.net>."
16383 cat >>$CONFIG_STATUS <<EOF
16386 configured by $0, generated by GNU Autoconf 2.52.20101002,
16387 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
16389 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
16390 Free Software Foundation, Inc.
16391 This config.status script is free software; the Free Software Foundation
16392 gives unlimited permission to copy, distribute and modify it."
16397 cat >>$CONFIG_STATUS <<\EOF
16398 # If no file are specified by the user, then we need to provide default
16399 # value. By we need to know if files were specified by the user.
16405 ac_option=`expr "x$1" : 'x\([^=]*\)='`
16406 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
16408 set dummy "$ac_option" "$ac_optarg" ${1+"$@"}
16412 *) # This is not an option, so the user has probably given explicit
16414 ac_need_defaults=false;;
16418 # Handling of the options.
16420 cat >>$CONFIG_STATUS <<EOF
16421 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
16422 echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion"
16423 exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;;
16425 cat >>$CONFIG_STATUS <<\EOF
16426 --version | --vers* | -V )
16427 echo "$ac_cs_version"; exit 0 ;;
16429 # Conflict between --help and --header
16430 { { echo "$as_me:16430: error: ambiguous option: $1
16431 Try \`$0 --help' for more information." >&5
16432 echo "$as_me: error: ambiguous option: $1
16433 Try \`$0 --help' for more information." >&2;}
16434 { (exit 1); exit 1; }; };;
16435 --help | --hel | -h )
16436 echo "$ac_cs_usage"; exit 0 ;;
16437 --debug | --d* | -d )
16439 --file | --fil | --fi | --f )
16441 CONFIG_FILES="$CONFIG_FILES $1"
16442 ac_need_defaults=false;;
16443 --header | --heade | --head | --hea )
16445 CONFIG_HEADERS="$CONFIG_HEADERS $1"
16446 ac_need_defaults=false;;
16448 # This is an error.
16449 -*) { { echo "$as_me:16449: error: unrecognized option: $1
16450 Try \`$0 --help' for more information." >&5
16451 echo "$as_me: error: unrecognized option: $1
16452 Try \`$0 --help' for more information." >&2;}
16453 { (exit 1); exit 1; }; } ;;
16455 *) ac_config_targets="$ac_config_targets $1" ;;
16464 ## ----------------------- ##
16465 ## Running config.status. ##
16466 ## ----------------------- ##
16468 This file was extended by $as_me 2.52.20101002, executed with
16469 CONFIG_FILES = $CONFIG_FILES
16470 CONFIG_HEADERS = $CONFIG_HEADERS
16471 CONFIG_LINKS = $CONFIG_LINKS
16472 CONFIG_COMMANDS = $CONFIG_COMMANDS
16473 > $ac_cs_invocation
16474 on `(hostname || uname -n) 2>/dev/null | sed 1q`
16479 cat >>$CONFIG_STATUS <<EOF
16481 # INIT-COMMANDS section.
16489 cat >>$CONFIG_STATUS <<\EOF
16490 for ac_config_target in $ac_config_targets
16492 case "$ac_config_target" in
16493 # Handling of arguments.
16494 "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
16495 "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
16496 "ncurses_cfg.h" ) CONFIG_HEADERS="$CONFIG_HEADERS ncurses_cfg.h:ncurses_tst.hin" ;;
16497 *) { { echo "$as_me:16497: error: invalid argument: $ac_config_target" >&5
16498 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
16499 { (exit 1); exit 1; }; };;
16503 # If the user did not use the arguments to specify the items to instantiate,
16504 # then the envvar interface is used. Set only those that are not.
16505 # We use the long form for the default assignment because of an extremely
16506 # bizarre bug on SunOS 4.1.3.
16507 if $ac_need_defaults; then
16508 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
16509 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
16510 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
16513 # Create a temporary directory, and hook for its removal unless debugging.
16516 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
16517 trap '{ (exit 1); exit 1; }' 1 2 13 15
16520 # Create a (secure) tmp directory for tmp files.
16523 tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` &&
16524 test -n "$tmp" && test -d "$tmp"
16527 tmp=$TMPDIR/cs$$-$RANDOM
16528 (umask 077 && mkdir $tmp)
16531 echo "$me: cannot create a temporary directory in $TMPDIR" >&2
16532 { (exit 1); exit 1; }
16537 cat >>$CONFIG_STATUS <<EOF
16540 # CONFIG_FILES section.
16543 # No need to generate the scripts if there are no CONFIG_FILES.
16544 # This happens for instance when ./config.status config.h
16545 if test -n "\$CONFIG_FILES"; then
16546 # Protect against being on the right side of a sed subst in config.status.
16547 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
16548 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
16549 s,@SHELL@,$SHELL,;t t
16550 s,@exec_prefix@,$exec_prefix,;t t
16551 s,@prefix@,$prefix,;t t
16552 s,@program_transform_name@,$program_transform_name,;t t
16553 s,@bindir@,$bindir,;t t
16554 s,@sbindir@,$sbindir,;t t
16555 s,@libexecdir@,$libexecdir,;t t
16556 s,@datadir@,$datadir,;t t
16557 s,@sysconfdir@,$sysconfdir,;t t
16558 s,@sharedstatedir@,$sharedstatedir,;t t
16559 s,@localstatedir@,$localstatedir,;t t
16560 s,@libdir@,$libdir,;t t
16561 s,@includedir@,$includedir,;t t
16562 s,@oldincludedir@,$oldincludedir,;t t
16563 s,@infodir@,$infodir,;t t
16564 s,@mandir@,$mandir,;t t
16565 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
16566 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
16567 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
16568 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
16569 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
16570 s,@build_alias@,$build_alias,;t t
16571 s,@host_alias@,$host_alias,;t t
16572 s,@target_alias@,$target_alias,;t t
16573 s,@ECHO_C@,$ECHO_C,;t t
16574 s,@ECHO_N@,$ECHO_N,;t t
16575 s,@ECHO_T@,$ECHO_T,;t t
16576 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
16577 s,@DEFS@,$DEFS,;t t
16578 s,@LIBS@,$LIBS,;t t
16579 s,@build@,$build,;t t
16580 s,@build_cpu@,$build_cpu,;t t
16581 s,@build_vendor@,$build_vendor,;t t
16582 s,@build_os@,$build_os,;t t
16583 s,@host@,$host,;t t
16584 s,@host_cpu@,$host_cpu,;t t
16585 s,@host_vendor@,$host_vendor,;t t
16586 s,@host_os@,$host_os,;t t
16587 s,@SET_MAKE@,$SET_MAKE,;t t
16589 s,@CFLAGS@,$CFLAGS,;t t
16590 s,@LDFLAGS@,$LDFLAGS,;t t
16591 s,@CPPFLAGS@,$CPPFLAGS,;t t
16592 s,@ac_ct_CC@,$ac_ct_CC,;t t
16593 s,@EXEEXT@,$EXEEXT,;t t
16594 s,@OBJEXT@,$OBJEXT,;t t
16597 s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
16598 s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
16599 s,@INSTALL_DATA@,$INSTALL_DATA,;t t
16600 s,@LINT@,$LINT,;t t
16601 s,@LINT_OPTS@,$LINT_OPTS,;t t
16602 s,@CTAGS@,$CTAGS,;t t
16603 s,@ETAGS@,$ETAGS,;t t
16604 s,@MAKE_LOWER_TAGS@,$MAKE_LOWER_TAGS,;t t
16605 s,@MAKE_UPPER_TAGS@,$MAKE_UPPER_TAGS,;t t
16606 s,@MATH_LIB@,$MATH_LIB,;t t
16607 s,@top_builddir@,$top_builddir,;t t
16608 s,@CC_G_OPT@,$CC_G_OPT,;t t
16609 s,@CC_SHARED_OPTS@,$CC_SHARED_OPTS,;t t
16610 s,@DFT_DEP_SUFFIX@,$DFT_DEP_SUFFIX,;t t
16611 s,@DFT_OBJ_SUBDIR@,$DFT_OBJ_SUBDIR,;t t
16612 s,@DFT_UPR_MODEL@,$DFT_UPR_MODEL,;t t
16614 s,@LDFLAGS_SHARED@,$LDFLAGS_SHARED,;t t
16615 s,@LDFLAGS_STATIC@,$LDFLAGS_STATIC,;t t
16616 s,@LD_MODEL@,$LD_MODEL,;t t
16617 s,@LD_SHARED_OPTS@,$LD_SHARED_OPTS,;t t
16618 s,@LIBTOOL@,$LIBTOOL,;t t
16619 s,@LIB_CLEAN@,$LIB_CLEAN,;t t
16620 s,@LIB_COMPILE@,$LIB_COMPILE,;t t
16621 s,@LIB_LINK@,$LIB_LINK,;t t
16622 s,@LINK_TESTS@,$LINK_TESTS,;t t
16623 s,@LOCAL_LDFLAGS@,$LOCAL_LDFLAGS,;t t
16624 s,@PTHREAD@,$PTHREAD,;t t
16625 s,@TEST_ARGS@,$TEST_ARGS,;t t
16626 s,@TEST_DEPS@,$TEST_DEPS,;t t
16627 s,@TEST_LIBS@,$TEST_LIBS,;t t
16628 s,@TINFO_LDFLAGS@,$TINFO_LDFLAGS,;t t
16629 s,@TINFO_LIBS@,$TINFO_LIBS,;t t
16630 s,@cf_cv_abi_version@,$cf_cv_abi_version,;t t
16631 s,@cf_cv_rel_version@,$cf_cv_rel_version,;t t
16632 s,@EXTRA_CPPFLAGS@,$EXTRA_CPPFLAGS,;t t
16633 s,@ECHO_LT@,$ECHO_LT,;t t
16634 s,@ECHO_LD@,$ECHO_LD,;t t
16635 s,@RULE_CC@,$RULE_CC,;t t
16636 s,@SHOW_CC@,$SHOW_CC,;t t
16637 s,@ECHO_CC@,$ECHO_CC,;t t
16638 s,@EXTRA_CFLAGS@,$EXTRA_CFLAGS,;t t
16639 s,@NCURSES_CONFIG@,$NCURSES_CONFIG,;t t
16640 s,@PKG_CONFIG@,$PKG_CONFIG,;t t
16641 s,@ac_pt_PKG_CONFIG@,$ac_pt_PKG_CONFIG,;t t
16642 s,@X_CFLAGS@,$X_CFLAGS,;t t
16643 s,@X_PRE_LIBS@,$X_PRE_LIBS,;t t
16644 s,@X_LIBS@,$X_LIBS,;t t
16645 s,@X_EXTRA_LIBS@,$X_EXTRA_LIBS,;t t
16646 s,@XCURSES_CONFIG@,$XCURSES_CONFIG,;t t
16647 s,@NCURSES_WRAP_PREFIX@,$NCURSES_WRAP_PREFIX,;t t
16648 s,@cf_ldd_prog@,$cf_ldd_prog,;t t
16649 s,@EXTRA_LDFLAGS@,$EXTRA_LDFLAGS,;t t
16654 cat >>$CONFIG_STATUS <<\EOF
16655 # Split the substitutions into bite-sized pieces for seds with
16656 # small command number limits, like on Digital OSF/1 and HP-UX.
16657 ac_max_sed_lines=48
16658 ac_sed_frag=1 # Number of current file.
16659 ac_beg=1 # First line for current file.
16660 ac_end=$ac_max_sed_lines # Line after last line for current file.
16663 while $ac_more_lines; do
16664 if test $ac_beg -gt 1; then
16665 sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
16667 sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
16669 if test ! -s $tmp/subs.frag; then
16670 ac_more_lines=false
16672 # The purpose of the label and of the branching condition is to
16673 # speed up the sed processing (if there are no `@' at all, there
16674 # is no need to browse any of the substitutions).
16675 # These are the two extra sed commands mentioned above.
16677 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
16678 if test -z "$ac_sed_cmds"; then
16679 ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
16681 ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
16683 ac_sed_frag=`expr $ac_sed_frag + 1`
16685 ac_end=`expr $ac_end + $ac_max_sed_lines`
16688 if test -z "$ac_sed_cmds"; then
16691 fi # test -n "$CONFIG_FILES"
16694 cat >>$CONFIG_STATUS <<\EOF
16695 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
16696 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
16698 - | *:- | *:-:* ) # input from stdin
16700 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
16701 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
16702 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
16703 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
16704 * ) ac_file_in=$ac_file.in ;;
16707 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
16708 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
16709 X"$ac_file" : 'X\(//\)[^/]' \| \
16710 X"$ac_file" : 'X\(//\)$' \| \
16711 X"$ac_file" : 'X\(/\)' \| \
16712 . : '\(.\)' 2>/dev/null ||
16714 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
16715 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
16716 /^X\(\/\/\)$/{ s//\1/; q; }
16717 /^X\(\/\).*/{ s//\1/; q; }
16719 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
16720 { case "$ac_dir" in
16721 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
16725 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
16726 case $as_mkdir_dir in
16727 # Skip DOS drivespec
16728 ?:) as_incr_dir=$as_mkdir_dir ;;
16730 as_incr_dir=$as_incr_dir/$as_mkdir_dir
16731 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
16736 ac_dir_suffix="/`echo $ac_dir|sed 's,^\./,,'`"
16737 # A "../" for each directory in $ac_dir_suffix.
16738 ac_dots=`echo "$ac_dir_suffix" | sed 's,/[^/]*,../,g'`
16740 ac_dir_suffix= ac_dots=
16745 if test -z "$ac_dots"; then
16748 ac_top_srcdir=`echo $ac_dots | sed 's,/$,,'`
16750 [\\/]* | ?:[\\/]* )
16751 ac_srcdir=$srcdir$ac_dir_suffix;
16752 ac_top_srcdir=$srcdir ;;
16753 *) # Relative path.
16754 ac_srcdir=$ac_dots$srcdir$ac_dir_suffix
16755 ac_top_srcdir=$ac_dots$srcdir ;;
16759 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
16760 *) ac_INSTALL=$ac_dots$INSTALL ;;
16763 if test x"$ac_file" != x-; then
16764 { echo "$as_me:16764: creating $ac_file" >&5
16765 echo "$as_me: creating $ac_file" >&6;}
16768 # Let's still pretend it is `configure' which instantiates (i.e., don't
16769 # use $as_me), people would be surprised to read:
16770 # /* config.h. Generated automatically by config.status. */
16771 configure_input="Generated automatically from `echo $ac_file_in |
16772 sed 's,.*/,,'` by configure."
16774 # First look for the input files in the build tree, otherwise in the
16776 ac_file_inputs=`IFS=:
16777 for f in $ac_file_in; do
16779 -) echo $tmp/stdin ;;
16781 # Absolute (can't be DOS-style, as IFS=:)
16782 test -f "$f" || { { echo "$as_me:16782: error: cannot find input file: $f" >&5
16783 echo "$as_me: error: cannot find input file: $f" >&2;}
16784 { (exit 1); exit 1; }; }
16787 if test -f "$f"; then
16790 elif test -f "$srcdir/$f"; then
16795 { { echo "$as_me:16795: error: cannot find input file: $f" >&5
16796 echo "$as_me: error: cannot find input file: $f" >&2;}
16797 { (exit 1); exit 1; }; }
16800 done` || { (exit 1); exit 1; }
16802 cat >>$CONFIG_STATUS <<EOF
16806 cat >>$CONFIG_STATUS <<\EOF
16808 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
16809 s,@configure_input@,$configure_input,;t t
16810 s,@srcdir@,$ac_srcdir,;t t
16811 s,@top_srcdir@,$ac_top_srcdir,;t t
16812 s,@INSTALL@,$ac_INSTALL,;t t
16813 " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
16815 if test x"$ac_file" != x-; then
16816 mv $tmp/out $ac_file
16824 cat >>$CONFIG_STATUS <<\EOF
16827 # CONFIG_HEADER section.
16830 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
16831 # NAME is the cpp macro being defined and VALUE is the value it is being given.
16833 # ac_d sets the value in "#define NAME VALUE" lines.
16834 ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
16835 ac_dB='[ ].*$,\1#\2'
16838 # ac_i turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
16839 ac_iA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
16840 ac_iB='\([ ]\),\1#\2define\3'
16843 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
16844 ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
16845 ac_uB='$,\1#\2define\3'
16849 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
16850 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
16852 - | *:- | *:-:* ) # input from stdin
16854 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
16855 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
16856 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
16857 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
16858 * ) ac_file_in=$ac_file.in ;;
16861 test x"$ac_file" != x- && { echo "$as_me:16861: creating $ac_file" >&5
16862 echo "$as_me: creating $ac_file" >&6;}
16864 # First look for the input files in the build tree, otherwise in the
16866 ac_file_inputs=`IFS=:
16867 for f in $ac_file_in; do
16869 -) echo $tmp/stdin ;;
16871 # Absolute (can't be DOS-style, as IFS=:)
16872 test -f "$f" || { { echo "$as_me:16872: error: cannot find input file: $f" >&5
16873 echo "$as_me: error: cannot find input file: $f" >&2;}
16874 { (exit 1); exit 1; }; }
16877 if test -f "$f"; then
16880 elif test -f "$srcdir/$f"; then
16885 { { echo "$as_me:16885: error: cannot find input file: $f" >&5
16886 echo "$as_me: error: cannot find input file: $f" >&2;}
16887 { (exit 1); exit 1; }; }
16890 done` || { (exit 1); exit 1; }
16891 # Remove the trailing spaces.
16892 sed 's/[ ]*$//' $ac_file_inputs >$tmp/in
16896 # Transform confdefs.h into a list of #define's. We won't use it as a sed
16897 # script, but as data to insert where we see @DEFS@. We expect AC_SAVE_DEFS to
16898 # be either 'cat' or 'sort'.
16899 cat confdefs.h | uniq >conftest.vals
16901 # Break up conftest.vals because some shells have a limit on
16902 # the size of here documents, and old seds have small limits too.
16904 rm -f conftest.tail
16905 echo ' rm -f conftest.frag' >> $CONFIG_STATUS
16906 while grep . conftest.vals >/dev/null
16908 # Write chunks of a limited-size here document to conftest.frag.
16909 echo ' cat >> conftest.frag <<CEOF' >> $CONFIG_STATUS
16910 sed ${ac_max_here_lines}q conftest.vals | sed -e 's/#ifdef.*/#if 0/' >> $CONFIG_STATUS
16911 echo 'CEOF' >> $CONFIG_STATUS
16912 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
16913 rm -f conftest.vals
16914 mv conftest.tail conftest.vals
16916 rm -f conftest.vals
16918 # Run sed to substitute the contents of conftest.frag into $tmp/in at the
16920 echo ' cat >> conftest.edit <<CEOF
16921 /@DEFS@/r conftest.frag
16924 sed -f conftest.edit $tmp/in > $tmp/out
16926 mv $tmp/out $tmp/in
16927 rm -f conftest.edit conftest.frag
16928 ' >> $CONFIG_STATUS
16930 cat >>$CONFIG_STATUS <<\EOF
16931 # Let's still pretend it is `configure' which instantiates (i.e., don't
16932 # use $as_me), people would be surprised to read:
16933 # /* config.h. Generated automatically by config.status. */
16934 if test x"$ac_file" = x-; then
16935 echo "/* Generated automatically by configure. */" >$tmp/config.h
16937 echo "/* $ac_file. Generated automatically by configure. */" >$tmp/config.h
16939 cat $tmp/in >>$tmp/config.h
16941 if test x"$ac_file" != x-; then
16942 if cmp -s $ac_file $tmp/config.h 2>/dev/null; then
16943 { echo "$as_me:16943: $ac_file is unchanged" >&5
16944 echo "$as_me: $ac_file is unchanged" >&6;}
16946 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
16947 X"$ac_file" : 'X\(//\)[^/]' \| \
16948 X"$ac_file" : 'X\(//\)$' \| \
16949 X"$ac_file" : 'X\(/\)' \| \
16950 . : '\(.\)' 2>/dev/null ||
16952 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
16953 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
16954 /^X\(\/\/\)$/{ s//\1/; q; }
16955 /^X\(\/\).*/{ s//\1/; q; }
16957 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
16958 { case "$ac_dir" in
16959 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
16963 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
16964 case $as_mkdir_dir in
16965 # Skip DOS drivespec
16966 ?:) as_incr_dir=$as_mkdir_dir ;;
16968 as_incr_dir=$as_incr_dir/$as_mkdir_dir
16969 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
16976 mv $tmp/config.h $ac_file
16980 rm -f $tmp/config.h
16984 cat >>$CONFIG_STATUS <<\EOF
16986 # CONFIG_COMMANDS section.
16988 for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
16989 ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
16990 ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
16997 if test ! -d $srcdir/$cf_dir; then
16999 elif test -f $srcdir/$cf_dir/programs; then
17000 $AWK -f $srcdir/mk-test.awk INSTALL=yes ECHO_LINK="$ECHO_LD" $srcdir/$cf_dir/programs >>$cf_dir/Makefile
17004 cat >>Makefile <<TEST_EOF
17006 # These rules are generated so we do not rely on suffix rules, which do not
17007 # work consistently for different make-programs (the '\$(MODEL)/' confuses
17008 # some, and the '\$x' confuses others).
17011 LIST=`sed -e 's/[ ].*//' -e '/^[#@]/d' $srcdir/modules`
17014 cat >>Makefile <<TEST_EOF
17016 \$(MODEL)/$N.o : \$(srcdir)/$N.c \\
17017 \$(srcdir)/test.priv.h \\
17019 @echo compiling $N; \$(CC) -c \$(CFLAGS_DEFAULT) \$(srcdir)/$N.c
17023 if test -f ../config.guess && test -f ../config.sub
17025 cat >>Makefile <<TEST_EOF
17027 # if we used CF_INHERIT for getting these files, we can remove them
17029 rm -f config.guess config.sub
17037 cat >>$CONFIG_STATUS <<\EOF
17039 { (exit 0); exit 0; }
17041 chmod +x $CONFIG_STATUS
17042 ac_clean_files=$ac_clean_files_save
17044 # configure is writing to config.log, and then calls config.status.
17045 # config.status does its own redirection, appending to config.log.
17046 # Unfortunately, on DOS this fails, as config.log is still kept open
17047 # by configure, so config.status won't be able to write to it; its
17048 # output is simply discarded. So we exec the FD to /dev/null,
17049 # effectively closing config.log, so it can be properly (re)opened and
17050 # appended to by config.status. When coming back to configure, we
17051 # need to make the FD available again.
17052 if test "$no_create" != yes; then
17055 $SHELL $CONFIG_STATUS || ac_cs_success=false
17057 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
17058 # would make configure fail if this is the last instruction.
17059 $ac_cs_success || { (exit 1); exit 1; }