2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by Autoconf 2.52.20200802.
5 # Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
6 # Free Software Foundation, Inc.
7 # This configure script is free software; the Free Software Foundation
8 # gives unlimited permission to copy, distribute and modify it.
10 # Avoid depending upon Character Ranges.
11 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
12 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
13 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
14 as_cr_digits='0123456789'
15 as_cr_alnum=$as_cr_Letters$as_cr_digits
17 # Sed expression to map a string onto a valid variable name.
18 as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
20 # Sed expression to map a string onto a valid CPP name.
21 as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
23 # Be Bourne compatible
24 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
27 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
31 # Name of the executable.
32 as_me=`echo "$0" |sed 's,.*[\\/],,'`
34 if expr a : '\(a\)' >/dev/null 2>&1; then
40 rm -f conf$$ conf$$.exe conf$$.file
42 if ln -s conf$$.file conf$$ 2>/dev/null; then
43 # We could just check for DJGPP; but this test a) works b) is more generic
44 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
45 if test -f conf$$.exe; then
46 # Don't use ln at all; we don't have any links
51 elif ln conf$$.file conf$$ 2>/dev/null; then
56 rm -f conf$$ conf$$.exe conf$$.file
58 as_executable_p="test -f"
60 # Support unset when possible.
61 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
68 $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
69 $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
70 $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
71 $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
72 $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
73 $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
74 $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
75 $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
78 # We need space, tab and new line, in precisely that order.
84 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
87 # hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
88 # so uname gets run too.
89 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
96 ac_default_prefix=/usr/local
100 SHELL=${CONFIG_SHELL-/bin/sh}
102 # Maximum number of lines to put in a shell here document.
103 # This variable seems obsolete. It should probably be removed, and
104 # only ac_max_sed_lines should be used.
105 : ${ac_max_here_lines=38}
107 ac_unique_file="ncurses.c"
109 # Initialize some variables set by options.
111 ac_init_version=false
112 # The variables have the same names as the options, with
113 # dashes changed to underlines.
121 program_transform_name=s,x,x,
129 # Installation directory options.
130 # These are left unexpanded so users can "make install exec_prefix=/foo"
131 # and all the variables that are supposed to be based on exec_prefix
132 # by default will actually change.
133 # Use braces instead of parens because sh, perl, etc. also accept them.
134 bindir='${exec_prefix}/bin'
135 sbindir='${exec_prefix}/sbin'
136 libexecdir='${exec_prefix}/libexec'
137 datarootdir='${prefix}/share'
138 datadir='${datarootdir}'
139 sysconfdir='${prefix}/etc'
140 sharedstatedir='${prefix}/com'
141 localstatedir='${prefix}/var'
142 runstatedir='${localstatedir}/run'
143 libdir='${exec_prefix}/lib'
144 includedir='${prefix}/include'
145 oldincludedir='/usr/include'
146 infodir='${datarootdir}/info'
147 mandir='${datarootdir}/man'
149 # Identity of this package.
159 # If the previous option needs an argument, assign it.
160 if test -n "$ac_prev"; then
161 eval "$ac_prev=\$ac_option"
166 ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
168 # Accept the important Cygnus configure options, so we can diagnose typos.
172 -bindir | --bindir | --bindi | --bind | --bin | --bi)
174 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
177 -build | --build | --buil | --bui | --bu)
178 ac_prev=build_alias ;;
179 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
180 build_alias=$ac_optarg ;;
182 -cache-file | --cache-file | --cache-fil | --cache-fi \
183 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
184 ac_prev=cache_file ;;
185 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
186 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
187 cache_file=$ac_optarg ;;
190 cache_file=config.cache ;;
192 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
194 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
196 datadir=$ac_optarg ;;
198 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
199 | --dataroo | --dataro | --datar)
200 ac_prev=datarootdir ;;
201 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
202 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
203 datarootdir=$ac_optarg ;;
205 -disable-* | --disable-*)
206 ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
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'`
212 eval "enable_$ac_feature=no" ;;
214 -enable-* | --enable-*)
215 ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
216 # Reject names that are not valid shell variable names.
217 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
218 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
219 { (exit 1); exit 1; }; }
220 ac_feature=`echo $ac_feature | sed 's/-/_/g'`
222 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
225 eval "enable_$ac_feature='$ac_optarg'" ;;
227 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
228 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
229 | --exec | --exe | --ex)
230 ac_prev=exec_prefix ;;
231 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
232 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
233 | --exec=* | --exe=* | --ex=*)
234 exec_prefix=$ac_optarg ;;
236 -gas | --gas | --ga | --g)
237 # Obsolete; use --with-gas.
240 -help | --help | --hel | --he | -h)
242 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
243 ac_init_help=recursive ;;
244 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
245 ac_init_help=short ;;
247 -host | --host | --hos | --ho)
248 ac_prev=host_alias ;;
249 -host=* | --host=* | --hos=* | --ho=*)
250 host_alias=$ac_optarg ;;
252 -includedir | --includedir | --includedi | --included | --include \
253 | --includ | --inclu | --incl | --inc)
254 ac_prev=includedir ;;
255 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
256 | --includ=* | --inclu=* | --incl=* | --inc=*)
257 includedir=$ac_optarg ;;
259 -infodir | --infodir | --infodi | --infod | --info | --inf)
261 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
262 infodir=$ac_optarg ;;
264 -libdir | --libdir | --libdi | --libd)
266 -libdir=* | --libdir=* | --libdi=* | --libd=*)
269 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
270 | --libexe | --libex | --libe)
271 ac_prev=libexecdir ;;
272 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
273 | --libexe=* | --libex=* | --libe=*)
274 libexecdir=$ac_optarg ;;
276 -localstatedir | --localstatedir | --localstatedi | --localstated \
277 | --localstate | --localstat | --localsta | --localst \
278 | --locals | --local | --loca | --loc | --lo)
279 ac_prev=localstatedir ;;
280 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
281 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
282 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
283 localstatedir=$ac_optarg ;;
285 -runstatedir | --runstatedir | --runstatedi | --runstated \
286 | --runstate | --runstat | --runsta | --runst \
287 | --runs | --run | --ru)
288 ac_prev=runstatedir ;;
289 -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \
290 | --runstate=* | --runstat=* | --runsta=* | --runst=* \
291 | --runs=* | --run=* | --ru=*)
292 runstatedir=$ac_optarg ;;
294 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
296 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
300 # Obsolete; use --without-fp.
303 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
307 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
308 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
311 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
312 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
313 | --oldin | --oldi | --old | --ol | --o)
314 ac_prev=oldincludedir ;;
315 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
316 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
317 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
318 oldincludedir=$ac_optarg ;;
320 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
322 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
325 -program-prefix | --program-prefix | --program-prefi | --program-pref \
326 | --program-pre | --program-pr | --program-p)
327 ac_prev=program_prefix ;;
328 -program-prefix=* | --program-prefix=* | --program-prefi=* \
329 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
330 program_prefix=$ac_optarg ;;
332 -program-suffix | --program-suffix | --program-suffi | --program-suff \
333 | --program-suf | --program-su | --program-s)
334 ac_prev=program_suffix ;;
335 -program-suffix=* | --program-suffix=* | --program-suffi=* \
336 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
337 program_suffix=$ac_optarg ;;
339 -program-transform-name | --program-transform-name \
340 | --program-transform-nam | --program-transform-na \
341 | --program-transform-n | --program-transform- \
342 | --program-transform | --program-transfor \
343 | --program-transfo | --program-transf \
344 | --program-trans | --program-tran \
345 | --progr-tra | --program-tr | --program-t)
346 ac_prev=program_transform_name ;;
347 -program-transform-name=* | --program-transform-name=* \
348 | --program-transform-nam=* | --program-transform-na=* \
349 | --program-transform-n=* | --program-transform-=* \
350 | --program-transform=* | --program-transfor=* \
351 | --program-transfo=* | --program-transf=* \
352 | --program-trans=* | --program-tran=* \
353 | --progr-tra=* | --program-tr=* | --program-t=*)
354 program_transform_name=$ac_optarg ;;
356 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
357 | -silent | --silent | --silen | --sile | --sil)
360 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
362 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
364 sbindir=$ac_optarg ;;
366 -sharedstatedir | --sharedstatedir | --sharedstatedi \
367 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
368 | --sharedst | --shareds | --shared | --share | --shar \
370 ac_prev=sharedstatedir ;;
371 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
372 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
373 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
375 sharedstatedir=$ac_optarg ;;
377 -site | --site | --sit)
379 -site=* | --site=* | --sit=*)
382 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
384 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
387 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
388 | --syscon | --sysco | --sysc | --sys | --sy)
389 ac_prev=sysconfdir ;;
390 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
391 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
392 sysconfdir=$ac_optarg ;;
394 -target | --target | --targe | --targ | --tar | --ta | --t)
395 ac_prev=target_alias ;;
396 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
397 target_alias=$ac_optarg ;;
399 -v | -verbose | --verbose | --verbos | --verbo | --verb)
402 -version | --version | --versio | --versi | --vers | -V)
406 ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
407 # Reject names that are not valid shell variable names.
408 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
409 { echo "$as_me: error: invalid package name: $ac_package" >&2
410 { (exit 1); exit 1; }; }
411 ac_package=`echo $ac_package| sed 's/-/_/g'`
413 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
416 eval "with_$ac_package='$ac_optarg'" ;;
418 -without-* | --without-*)
419 ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
420 # Reject names that are not valid shell variable names.
421 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
422 { echo "$as_me: error: invalid package name: $ac_package" >&2
423 { (exit 1); exit 1; }; }
424 ac_package=`echo $ac_package | sed 's/-/_/g'`
425 eval "with_$ac_package=no" ;;
428 # Obsolete; use --with-x.
431 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
432 | --x-incl | --x-inc | --x-in | --x-i)
433 ac_prev=x_includes ;;
434 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
435 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
436 x_includes=$ac_optarg ;;
438 -x-libraries | --x-libraries | --x-librarie | --x-librari \
439 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
440 ac_prev=x_libraries ;;
441 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
442 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
443 x_libraries=$ac_optarg ;;
445 -*) { echo "$as_me: error: unrecognized option: $ac_option
446 Try \`$0 --help' for more information." >&2
447 { (exit 1); exit 1; }; }
451 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
452 # Reject names that are not valid shell variable names.
453 expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
454 { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
455 { (exit 1); exit 1; }; }
456 ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
457 eval "$ac_envvar='$ac_optarg'"
461 # FIXME: should be removed in autoconf 3.0.
462 echo "$as_me: WARNING: you should use --build, --host, --target" >&2
463 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
464 echo "$as_me: WARNING: invalid host type: $ac_option" >&2
465 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
471 if test -n "$ac_prev"; then
472 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
473 { echo "$as_me: error: missing argument to $ac_option" >&2
474 { (exit 1); exit 1; }; }
477 # Be sure to have absolute paths.
478 for ac_var in exec_prefix prefix
480 eval ac_val=$`echo $ac_var`
482 [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
483 *) { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
484 { (exit 1); exit 1; }; };;
488 # Be sure to have absolute paths.
489 for ac_var in bindir sbindir libexecdir datarootdir datadir sysconfdir sharedstatedir \
490 localstatedir libdir includedir oldincludedir infodir mandir
492 eval ac_val=$`echo $ac_var`
494 [\\/$]* | ?:[\\/]* ) ;;
495 *) { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
496 { (exit 1); exit 1; }; };;
500 # There might be people who depend on the old broken behavior: `$host'
501 # used to hold the argument of --host etc.
506 # FIXME: should be removed in autoconf 3.0.
507 if test "x$host_alias" != x; then
508 if test "x$build_alias" = x; then
509 cross_compiling=maybe
510 echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
511 If a cross compiler is detected then cross compile mode will be used." >&2
512 elif test "x$build_alias" != "x$host_alias"; then
518 test -n "$host_alias" && ac_tool_prefix=$host_alias-
520 test "$silent" = yes && exec 6>/dev/null
522 # Find the source files, if location was not specified.
523 if test -z "$srcdir"; then
524 ac_srcdir_defaulted=yes
525 # Try the directory containing this script, then its parent.
527 ac_confdir=`echo "$ac_prog" | sed 's%[\\/][^\\/][^\\/]*$%%'`
528 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
530 if test ! -r $srcdir/$ac_unique_file; then
534 ac_srcdir_defaulted=no
536 if test ! -r $srcdir/$ac_unique_file; then
537 if test "$ac_srcdir_defaulted" = yes; then
538 { echo "$as_me: error: cannot find sources in $ac_confdir or .." >&2
539 { (exit 1); exit 1; }; }
541 { echo "$as_me: error: cannot find sources in $srcdir" >&2
542 { (exit 1); exit 1; }; }
545 srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
546 ac_env_build_alias_set=${build_alias+set}
547 ac_env_build_alias_value=$build_alias
548 ac_cv_env_build_alias_set=${build_alias+set}
549 ac_cv_env_build_alias_value=$build_alias
550 ac_env_host_alias_set=${host_alias+set}
551 ac_env_host_alias_value=$host_alias
552 ac_cv_env_host_alias_set=${host_alias+set}
553 ac_cv_env_host_alias_value=$host_alias
554 ac_env_target_alias_set=${target_alias+set}
555 ac_env_target_alias_value=$target_alias
556 ac_cv_env_target_alias_set=${target_alias+set}
557 ac_cv_env_target_alias_value=$target_alias
558 ac_env_CC_set=${CC+set}
560 ac_cv_env_CC_set=${CC+set}
561 ac_cv_env_CC_value=$CC
562 ac_env_CFLAGS_set=${CFLAGS+set}
563 ac_env_CFLAGS_value=$CFLAGS
564 ac_cv_env_CFLAGS_set=${CFLAGS+set}
565 ac_cv_env_CFLAGS_value=$CFLAGS
566 ac_env_LDFLAGS_set=${LDFLAGS+set}
567 ac_env_LDFLAGS_value=$LDFLAGS
568 ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
569 ac_cv_env_LDFLAGS_value=$LDFLAGS
570 ac_env_CPPFLAGS_set=${CPPFLAGS+set}
571 ac_env_CPPFLAGS_value=$CPPFLAGS
572 ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
573 ac_cv_env_CPPFLAGS_value=$CPPFLAGS
574 ac_env_CPP_set=${CPP+set}
575 ac_env_CPP_value=$CPP
576 ac_cv_env_CPP_set=${CPP+set}
577 ac_cv_env_CPP_value=$CPP
580 # Report the --help message.
582 if test "$ac_init_help" = "long"; then
583 # Omit some internal or obsolete options to make the list less imposing.
584 # This message is too long to be a string in the A/UX 3.1 sh.
586 \`configure' configures this package to adapt to many kinds of systems.
588 Usage: $0 [OPTION]... [VAR=VALUE]...
590 To assign environment variables (e.g., CC, CFLAGS...), specify them as
591 VAR=VALUE. See below for descriptions of some of the useful variables.
593 Defaults for the options are specified in brackets.
596 -h, --help display this help and exit
597 --help=short display options specific to this package
598 --help=recursive display the short help of all the included packages
599 -V, --version display version information and exit
600 -q, --quiet, --silent do not print \`checking...' messages
601 --cache-file=FILE cache test results in FILE [disabled]
602 -C, --config-cache alias for \`--cache-file=config.cache'
603 -n, --no-create do not create output files
604 --srcdir=DIR find the sources in DIR [configure dir or \`..']
609 Installation directories:
610 --prefix=PREFIX install architecture-independent files in PREFIX
612 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
615 By default, \`make install' will install all the files in
616 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
617 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
618 for instance \`--prefix=\$HOME'.
620 For better control, use the options below.
622 Fine tuning of the installation directories:
623 --bindir=DIR user executables [EPREFIX/bin]
624 --sbindir=DIR system admin executables [EPREFIX/sbin]
625 --libexecdir=DIR program executables [EPREFIX/libexec]
626 --datarootdir=DIR read-only architecture-independent data [PREFIX/share]
627 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
628 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
629 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
630 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
631 --runstatedir=DIR extra definition of runtime data [LOCALSTATEDIR/run]
632 --libdir=DIR object code libraries [EPREFIX/lib]
633 --includedir=DIR C header files [PREFIX/include]
634 --oldincludedir=DIR C header files for non-gcc [/usr/include]
635 --infodir=DIR info documentation [DATAROOTDIR/info]
636 --mandir=DIR man documentation [DATAROOTDIR/man]
642 --program-prefix=PREFIX prepend PREFIX to installed program names
643 --program-suffix=SUFFIX append SUFFIX to installed program names
644 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
647 --x-includes=DIR X include files are in DIR
648 --x-libraries=DIR X library files are in DIR
651 --build=BUILD configure for building on BUILD [guessed]
652 --host=HOST build programs to run on HOST [BUILD]
656 if test -n "$ac_init_help"; then
661 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
662 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
665 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
666 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
669 --disable-stripping do not strip (debug info) installed executables
670 --enable-string-hacks work around bogus compiler/loader warnings
671 --with-pkg-config{=path} enable/disable use of pkg-config
672 --disable-echo do not display "compiling" commands
673 Curses Version-dependent Options:
674 --with-ncurses-wrap-prefix naming-prefix for ncurses wrapped-variables
675 --disable-widec disable checks for wide-character functions
676 --with-curses-dir=DIR directory in which (n)curses is installed
677 --with-screen=XXX use specified curses-libraries
678 --with-ncursesw use wide ncurses-libraries
679 --with-ncurses use ncurses-libraries
680 --with-pdcurses compile/link with pdcurses X11 library
681 --with-curses-colr compile/link with HPUX 10.x color-curses
682 --with-curses-5lib compile/link with SunOS 5lib curses
683 --with-Xaw3d link with Xaw 3d library
684 --with-Xaw3dxft link with Xaw 3d xft library
685 --with-neXtaw link with neXT Athena library
686 --with-XawPlus link with Athena-Plus library
687 --with-x use the X Window System
688 --with-x11-rgb=FILE file containing X11 rgb information (EPREFIX/lib/X11/rgb.txt)
689 --with-form-libname=XXX override form basename of library
690 --with-menu-libname=XXX override menu basename of library
691 --with-panel-libname=XXX override panel basename of library
692 --disable-panel disable checks for panel functions
693 --disable-menu disable checks for menu functions
694 --disable-form disable checks for form functions
695 Testing/development Options:
696 --enable-warnings test: turn on gcc compiler warnings
697 --with-dmalloc test: use Gray Watson's dmalloc library
698 --with-dbmalloc test: use Conor Cahill's dbmalloc library
699 --with-valgrind test: use valgrind
700 --disable-leaks test: free permanent memory, analyze leaks
701 --disable-rpath-hack don't add rpath options for additional libraries
703 Some influential environment variables:
704 CC C compiler command
705 CFLAGS C compiler flags
706 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
707 nonstandard directory <lib dir>
708 CPPFLAGS C/C++ preprocessor flags, e.g. -I<include dir> if you have
709 headers in a nonstandard directory <include dir>
712 Use these variables to override the choices made by `configure' or to help
713 it to find libraries and programs with nonstandard names/locations.
718 if test "$ac_init_help" = "recursive"; then
719 # If there are subdirs, report their specific --help.
721 for ac_subdir in : $ac_subdirs_all; do test "x$ac_subdir" = x: && continue
723 # A "../" for each directory in /$ac_subdir.
724 ac_dots=`echo $ac_subdir |
725 sed 's,^\./,,;s,[^/]$,&/,;s,[^/]*/,../,g'`
728 .) # No --srcdir option. We are building in place.
729 ac_sub_srcdir=$srcdir ;;
730 [\\/]* | ?:[\\/]* ) # Absolute path.
731 ac_sub_srcdir=$srcdir/$ac_subdir ;;
733 ac_sub_srcdir=$ac_dots$srcdir/$ac_subdir ;;
736 # Check for guested configure; otherwise get Cygnus style configure.
737 if test -f $ac_sub_srcdir/configure.gnu; then
739 $SHELL $ac_sub_srcdir/configure.gnu --help=recursive
740 elif test -f $ac_sub_srcdir/configure; then
742 $SHELL $ac_sub_srcdir/configure --help=recursive
743 elif test -f $ac_sub_srcdir/configure.ac ||
744 test -f $ac_sub_srcdir/configure.in; then
748 echo "$as_me: WARNING: no configuration information is in $ac_subdir" >&2
754 test -n "$ac_init_help" && exit 0
755 if $ac_init_version; then
758 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
759 Free Software Foundation, Inc.
760 This configure script is free software; the Free Software Foundation
761 gives unlimited permission to copy, distribute and modify it.
767 This file contains any messages produced by compilers while
768 running configure, to aid debugging if configure makes a mistake.
770 It was created by $as_me, which was
771 generated by GNU Autoconf 2.52.20200802. Invocation command line was
782 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
783 uname -m = `(uname -m) 2>/dev/null || echo unknown`
784 uname -r = `(uname -r) 2>/dev/null || echo unknown`
785 uname -s = `(uname -s) 2>/dev/null || echo unknown`
786 uname -v = `(uname -v) 2>/dev/null || echo unknown`
788 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
789 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
791 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
792 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
793 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
794 hostinfo = `(hostinfo) 2>/dev/null || echo unknown`
795 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
796 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
797 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
811 # Keep a trace of the command line.
812 # Strip out --no-create and --no-recursion so they do not pile up.
813 # Also quote any args containing shell meta-characters.
819 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
820 | --no-cr | --no-c) ;;
821 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
822 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
823 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
824 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"`
825 ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
827 *) ac_configure_args="$ac_configure_args$ac_sep$ac_arg"
830 # Get rid of the leading space.
833 # When interrupted or exit'd, cleanup temporary files, and complete
834 # config.log. We remove comments because anyway the quotes in there
835 # would cause problems or look ugly.
837 # Save into config.log some information that might help in debugging.
839 echo "## ----------------- ##" >&5
840 echo "## Cache variables. ##" >&5
841 echo "## ----------------- ##" >&5
843 # The following way of writing the cache mishandles newlines in values,
846 case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
849 "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
850 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
854 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
858 sed "/^$/d" confdefs.h >conftest.log
859 if test -s conftest.log; then
861 echo "## ------------ ##" >&5
862 echo "## confdefs.h. ##" >&5
863 echo "## ------------ ##" >&5
868 test "$ac_signal" != 0 &&
869 echo "$as_me: caught signal $ac_signal" >&5
870 echo "$as_me: exit $exit_status" >&5
871 rm -rf conftest* confdefs* core core.* *.core conf$$* $ac_clean_files &&
874 for ac_signal in 1 2 13 15; do
875 trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
879 # confdefs.h avoids OS command line length limits that DEFS can exceed.
880 rm -rf conftest* confdefs.h
881 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
884 # Let the site file select an alternate cache file if it wants to.
885 # Prefer explicitly selected file to automatically selected ones.
886 if test -z "$CONFIG_SITE"; then
887 if test "x$prefix" != xNONE; then
888 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
890 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
893 for ac_site_file in $CONFIG_SITE; do
894 if test -r "$ac_site_file"; then
895 { echo "$as_me:895: loading site script $ac_site_file" >&5
896 echo "$as_me: loading site script $ac_site_file" >&6;}
897 cat "$ac_site_file" >&5
902 if test -r "$cache_file"; then
903 # Some versions of bash will fail to source /dev/null (special
904 # files actually), so we avoid doing that.
905 if test -f "$cache_file"; then
906 { echo "$as_me:906: loading cache $cache_file" >&5
907 echo "$as_me: loading cache $cache_file" >&6;}
909 [\\/]* | ?:[\\/]* ) . $cache_file;;
914 { echo "$as_me:914: creating cache $cache_file" >&5
915 echo "$as_me: creating cache $cache_file" >&6;}
919 # Check that the precious variables saved in the cache have kept the same
921 ac_cache_corrupted=false
922 for ac_var in `(set) 2>&1 |
923 sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
924 eval ac_old_set=\$ac_cv_env_${ac_var}_set
925 eval ac_new_set=\$ac_env_${ac_var}_set
926 eval ac_old_val="\$ac_cv_env_${ac_var}_value"
927 eval ac_new_val="\$ac_env_${ac_var}_value"
928 case $ac_old_set,$ac_new_set in
930 { echo "$as_me:930: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
931 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
932 ac_cache_corrupted=: ;;
934 { echo "$as_me:934: error: \`$ac_var' was not set in the previous run" >&5
935 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
936 ac_cache_corrupted=: ;;
939 if test "x$ac_old_val" != "x$ac_new_val"; then
940 { echo "$as_me:940: error: \`$ac_var' has changed since the previous run:" >&5
941 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
942 { echo "$as_me:942: former value: $ac_old_val" >&5
943 echo "$as_me: former value: $ac_old_val" >&2;}
944 { echo "$as_me:944: current value: $ac_new_val" >&5
945 echo "$as_me: current value: $ac_new_val" >&2;}
949 # Pass precious variables to config.status. It doesn't matter if
950 # we pass some twice (in addition to the command line arguments).
951 if test "$ac_new_set" = set; then
953 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
954 ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"`
955 ac_configure_args="$ac_configure_args '$ac_arg'"
957 *) ac_configure_args="$ac_configure_args $ac_var=$ac_new_val"
962 if $ac_cache_corrupted; then
963 { echo "$as_me:963: error: changes in the environment can compromise the build" >&5
964 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
965 { { echo "$as_me:965: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
966 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
967 { (exit 1); exit 1; }; }
971 ac_cpp='$CPP $CPPFLAGS'
972 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
973 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
974 ac_compiler_gnu=$ac_cv_c_compiler_gnu
975 ac_main_return=return
977 case `echo "testing\c" 2>/dev/null; echo 1,2,3`,`echo -n testing 2>/dev/null; echo 1,2,3` in
978 *c*,-n*) ECHO_N= ECHO_C= # newlines do not sed ;-) only broken shells would use this case anyway
980 *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
981 *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
983 echo "#! $SHELL" >conftest.sh
984 echo "exit 0" >>conftest.sh
986 if { (echo "$as_me:986: PATH=\".;.\"; conftest.sh") >&5
987 (PATH=".;."; conftest.sh) 2>&5
989 echo "$as_me:989: \$? = $ac_status" >&5
990 (exit $ac_status); }; then
991 ac_path_separator=';'
995 PATH_SEPARATOR="$ac_path_separator"
998 ac_config_headers="$ac_config_headers ncurses_cfg.h:ncurses_tst.hin"
1000 test -f config.guess || ( test -f ../config.guess && cp ../config.guess ./ )
1002 test -f config.sub || ( test -f ../config.sub && cp ../config.sub ./ )
1005 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
1006 if test -f $ac_dir/install-sh; then
1008 ac_install_sh="$ac_aux_dir/install-sh -c"
1010 elif test -f $ac_dir/install.sh; then
1012 ac_install_sh="$ac_aux_dir/install.sh -c"
1014 elif test -f $ac_dir/shtool; then
1016 ac_install_sh="$ac_aux_dir/shtool install -c"
1020 if test -z "$ac_aux_dir"; then
1021 { { echo "$as_me:1021: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
1022 echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
1023 { (exit 1); exit 1; }; }
1025 ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1026 ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1027 ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
1029 # Make sure we can run config.sub.
1030 $ac_config_sub sun4 >/dev/null 2>&1 ||
1031 { { echo "$as_me:1031: error: cannot run $ac_config_sub" >&5
1032 echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1033 { (exit 1); exit 1; }; }
1035 echo "$as_me:1035: checking build system type" >&5
1036 echo $ECHO_N "checking build system type... $ECHO_C" >&6
1037 if test "${ac_cv_build+set}" = set; then
1038 echo $ECHO_N "(cached) $ECHO_C" >&6
1040 ac_cv_build_alias=$build_alias
1041 test -z "$ac_cv_build_alias" &&
1042 ac_cv_build_alias=`$ac_config_guess`
1043 test -z "$ac_cv_build_alias" &&
1044 { { echo "$as_me:1044: error: cannot guess build type; you must specify one" >&5
1045 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1046 { (exit 1); exit 1; }; }
1047 ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
1048 { { echo "$as_me:1048: error: $ac_config_sub $ac_cv_build_alias failed." >&5
1049 echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed." >&2;}
1050 { (exit 1); exit 1; }; }
1053 echo "$as_me:1053: result: $ac_cv_build" >&5
1054 echo "${ECHO_T}$ac_cv_build" >&6
1056 build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1057 build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1058 build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1060 if test -f $srcdir/config.guess || test -f $ac_aux_dir/config.guess ; then
1061 echo "$as_me:1061: checking host system type" >&5
1062 echo $ECHO_N "checking host system type... $ECHO_C" >&6
1063 if test "${ac_cv_host+set}" = set; then
1064 echo $ECHO_N "(cached) $ECHO_C" >&6
1066 ac_cv_host_alias=$host_alias
1067 test -z "$ac_cv_host_alias" &&
1068 ac_cv_host_alias=$ac_cv_build_alias
1069 ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
1070 { { echo "$as_me:1070: error: $ac_config_sub $ac_cv_host_alias failed" >&5
1071 echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1072 { (exit 1); exit 1; }; }
1075 echo "$as_me:1075: result: $ac_cv_host" >&5
1076 echo "${ECHO_T}$ac_cv_host" >&6
1078 host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1079 host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1080 host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1082 system_name="$host_os"
1084 system_name="`(uname -s -r) 2>/dev/null`"
1085 if test -z "$system_name" ; then
1086 system_name="`(hostname) 2>/dev/null`"
1089 test -n "$system_name" &&
1090 cat >>confdefs.h <<EOF
1091 #define SYSTEM_NAME "$system_name"
1094 if test "${cf_cv_system_name+set}" = set; then
1095 echo $ECHO_N "(cached) $ECHO_C" >&6
1097 cf_cv_system_name="$system_name"
1100 test -z "$system_name" && system_name="$cf_cv_system_name"
1101 test -n "$cf_cv_system_name" && echo "$as_me:1101: result: Configuring for $cf_cv_system_name" >&5
1102 echo "${ECHO_T}Configuring for $cf_cv_system_name" >&6
1104 if test ".$system_name" != ".$cf_cv_system_name" ; then
1105 echo "$as_me:1105: result: Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&5
1106 echo "${ECHO_T}Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&6
1107 { { echo "$as_me:1107: error: \"Please remove config.cache and try again.\"" >&5
1108 echo "$as_me: error: \"Please remove config.cache and try again.\"" >&2;}
1109 { (exit 1); exit 1; }; }
1112 test "$program_prefix" != NONE &&
1113 program_transform_name="s,^,$program_prefix,;$program_transform_name"
1114 # Use a double $ so make ignores it.
1115 test "$program_suffix" != NONE &&
1116 program_transform_name="s,\$,$program_suffix,;$program_transform_name"
1117 # Double any \ or $. echo might interpret backslashes.
1118 # By default was `s,x,x', remove it if useless.
1119 cat <<\_ACEOF >conftest.sed
1120 s/[\\$]/&&/g;s/;s,x,x,$//
1122 program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
1125 echo "$as_me:1125: checking whether ${MAKE-make} sets \${MAKE}" >&5
1126 echo $ECHO_N "checking whether ${MAKE-make} sets \${MAKE}... $ECHO_C" >&6
1127 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,./+-,__p_,'`
1128 if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
1129 echo $ECHO_N "(cached) $ECHO_C" >&6
1131 cat >conftest.make <<\EOF
1133 @echo 'ac_maketemp="${MAKE}"'
1135 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1136 eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
1137 if test -n "$ac_maketemp"; then
1138 eval ac_cv_prog_make_${ac_make}_set=yes
1140 eval ac_cv_prog_make_${ac_make}_set=no
1144 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
1145 echo "$as_me:1145: result: yes" >&5
1146 echo "${ECHO_T}yes" >&6
1149 echo "$as_me:1149: result: no" >&5
1150 echo "${ECHO_T}no" >&6
1151 SET_MAKE="MAKE=${MAKE-make}"
1155 ac_cpp='$CPP $CPPFLAGS'
1156 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1157 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1158 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1159 ac_main_return=return
1160 if test -n "$ac_tool_prefix"; then
1161 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
1162 set dummy ${ac_tool_prefix}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_CC+set}" = set; then
1166 echo $ECHO_N "(cached) $ECHO_C" >&6
1168 if test -n "$CC"; then
1169 ac_cv_prog_CC="$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_CC="${ac_tool_prefix}gcc"
1178 echo "$as_me:1178: found $ac_dir/$ac_word" >&5
1185 if test -n "$CC"; then
1186 echo "$as_me:1186: result: $CC" >&5
1187 echo "${ECHO_T}$CC" >&6
1189 echo "$as_me:1189: result: no" >&5
1190 echo "${ECHO_T}no" >&6
1194 if test -z "$ac_cv_prog_CC"; then
1196 # Extract the first word of "gcc", so it can be a program name with args.
1197 set dummy gcc; ac_word=$2
1198 echo "$as_me:1198: checking for $ac_word" >&5
1199 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1200 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1201 echo $ECHO_N "(cached) $ECHO_C" >&6
1203 if test -n "$ac_ct_CC"; then
1204 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1206 ac_save_IFS=$IFS; IFS=$ac_path_separator
1208 for ac_dir in $ac_dummy; do
1210 test -z "$ac_dir" && ac_dir=.
1211 $as_executable_p "$ac_dir/$ac_word" || continue
1212 ac_cv_prog_ac_ct_CC="gcc"
1213 echo "$as_me:1213: found $ac_dir/$ac_word" >&5
1219 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1220 if test -n "$ac_ct_CC"; then
1221 echo "$as_me:1221: result: $ac_ct_CC" >&5
1222 echo "${ECHO_T}$ac_ct_CC" >&6
1224 echo "$as_me:1224: result: no" >&5
1225 echo "${ECHO_T}no" >&6
1233 if test -z "$CC"; then
1234 if test -n "$ac_tool_prefix"; then
1235 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
1236 set dummy ${ac_tool_prefix}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_CC+set}" = set; then
1240 echo $ECHO_N "(cached) $ECHO_C" >&6
1242 if test -n "$CC"; then
1243 ac_cv_prog_CC="$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_CC="${ac_tool_prefix}cc"
1252 echo "$as_me:1252: found $ac_dir/$ac_word" >&5
1259 if test -n "$CC"; then
1260 echo "$as_me:1260: result: $CC" >&5
1261 echo "${ECHO_T}$CC" >&6
1263 echo "$as_me:1263: result: no" >&5
1264 echo "${ECHO_T}no" >&6
1268 if test -z "$ac_cv_prog_CC"; then
1270 # Extract the first word of "cc", so it can be a program name with args.
1271 set dummy cc; ac_word=$2
1272 echo "$as_me:1272: checking for $ac_word" >&5
1273 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1274 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1275 echo $ECHO_N "(cached) $ECHO_C" >&6
1277 if test -n "$ac_ct_CC"; then
1278 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1280 ac_save_IFS=$IFS; IFS=$ac_path_separator
1282 for ac_dir in $ac_dummy; do
1284 test -z "$ac_dir" && ac_dir=.
1285 $as_executable_p "$ac_dir/$ac_word" || continue
1286 ac_cv_prog_ac_ct_CC="cc"
1287 echo "$as_me:1287: found $ac_dir/$ac_word" >&5
1293 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1294 if test -n "$ac_ct_CC"; then
1295 echo "$as_me:1295: result: $ac_ct_CC" >&5
1296 echo "${ECHO_T}$ac_ct_CC" >&6
1298 echo "$as_me:1298: result: no" >&5
1299 echo "${ECHO_T}no" >&6
1308 if test -z "$CC"; then
1309 # Extract the first word of "cc", so it can be a program name with args.
1310 set dummy cc; ac_word=$2
1311 echo "$as_me:1311: checking for $ac_word" >&5
1312 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1313 if test "${ac_cv_prog_CC+set}" = set; then
1314 echo $ECHO_N "(cached) $ECHO_C" >&6
1316 if test -n "$CC"; then
1317 ac_cv_prog_CC="$CC" # Let the user override the test.
1320 ac_save_IFS=$IFS; IFS=$ac_path_separator
1322 for ac_dir in $ac_dummy; do
1324 test -z "$ac_dir" && ac_dir=.
1325 $as_executable_p "$ac_dir/$ac_word" || continue
1326 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
1327 ac_prog_rejected=yes
1331 echo "$as_me:1331: found $ac_dir/$ac_word" >&5
1335 if test $ac_prog_rejected = yes; then
1336 # We found a bogon in the path, so make sure we never use it.
1337 set dummy $ac_cv_prog_CC
1339 if test $# != 0; then
1340 # We chose a different compiler from the bogus one.
1341 # However, it has the same basename, so the bogon will be chosen
1342 # first if we set CC to just the basename; use the full file name.
1344 set dummy "$ac_dir/$ac_word" ${1+"$@"}
1352 if test -n "$CC"; then
1353 echo "$as_me:1353: result: $CC" >&5
1354 echo "${ECHO_T}$CC" >&6
1356 echo "$as_me:1356: result: no" >&5
1357 echo "${ECHO_T}no" >&6
1361 if test -z "$CC"; then
1362 if test -n "$ac_tool_prefix"; then
1365 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
1366 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
1367 echo "$as_me:1367: checking for $ac_word" >&5
1368 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1369 if test "${ac_cv_prog_CC+set}" = set; then
1370 echo $ECHO_N "(cached) $ECHO_C" >&6
1372 if test -n "$CC"; then
1373 ac_cv_prog_CC="$CC" # Let the user override the test.
1375 ac_save_IFS=$IFS; IFS=$ac_path_separator
1377 for ac_dir in $ac_dummy; do
1379 test -z "$ac_dir" && ac_dir=.
1380 $as_executable_p "$ac_dir/$ac_word" || continue
1381 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
1382 echo "$as_me:1382: found $ac_dir/$ac_word" >&5
1389 if test -n "$CC"; then
1390 echo "$as_me:1390: result: $CC" >&5
1391 echo "${ECHO_T}$CC" >&6
1393 echo "$as_me:1393: result: no" >&5
1394 echo "${ECHO_T}no" >&6
1397 test -n "$CC" && break
1400 if test -z "$CC"; then
1404 # Extract the first word of "$ac_prog", so it can be a program name with args.
1405 set dummy $ac_prog; ac_word=$2
1406 echo "$as_me:1406: checking for $ac_word" >&5
1407 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1408 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1409 echo $ECHO_N "(cached) $ECHO_C" >&6
1411 if test -n "$ac_ct_CC"; then
1412 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1414 ac_save_IFS=$IFS; IFS=$ac_path_separator
1416 for ac_dir in $ac_dummy; do
1418 test -z "$ac_dir" && ac_dir=.
1419 $as_executable_p "$ac_dir/$ac_word" || continue
1420 ac_cv_prog_ac_ct_CC="$ac_prog"
1421 echo "$as_me:1421: found $ac_dir/$ac_word" >&5
1427 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1428 if test -n "$ac_ct_CC"; then
1429 echo "$as_me:1429: result: $ac_ct_CC" >&5
1430 echo "${ECHO_T}$ac_ct_CC" >&6
1432 echo "$as_me:1432: result: no" >&5
1433 echo "${ECHO_T}no" >&6
1436 test -n "$ac_ct_CC" && break
1444 test -z "$CC" && { { echo "$as_me:1444: error: no acceptable cc found in \$PATH" >&5
1445 echo "$as_me: error: no acceptable cc found in \$PATH" >&2;}
1446 { (exit 1); exit 1; }; }
1448 # Provide some information about the compiler.
1449 echo "$as_me:1449:" \
1450 "checking for C compiler version" >&5
1451 ac_compiler=`set X $ac_compile; echo $2`
1452 { (eval echo "$as_me:1452: \"$ac_compiler --version </dev/null >&5\"") >&5
1453 (eval $ac_compiler --version </dev/null >&5) 2>&5
1455 echo "$as_me:1455: \$? = $ac_status" >&5
1456 (exit $ac_status); }
1457 { (eval echo "$as_me:1457: \"$ac_compiler -v </dev/null >&5\"") >&5
1458 (eval $ac_compiler -v </dev/null >&5) 2>&5
1460 echo "$as_me:1460: \$? = $ac_status" >&5
1461 (exit $ac_status); }
1462 { (eval echo "$as_me:1462: \"$ac_compiler -V </dev/null >&5\"") >&5
1463 (eval $ac_compiler -V </dev/null >&5) 2>&5
1465 echo "$as_me:1465: \$? = $ac_status" >&5
1466 (exit $ac_status); }
1468 cat >conftest.$ac_ext <<_ACEOF
1469 #line 1469 "configure"
1470 #include "confdefs.h"
1480 ac_clean_files_save=$ac_clean_files
1481 ac_clean_files="$ac_clean_files a.out a.exe"
1482 # Try to create an executable without -o first, disregard a.out.
1483 # It will help us diagnose broken compilers, and finding out an intuition
1485 echo "$as_me:1485: checking for C compiler default output" >&5
1486 echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
1487 ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
1488 if { (eval echo "$as_me:1488: \"$ac_link_default\"") >&5
1489 (eval $ac_link_default) 2>&5
1491 echo "$as_me:1491: \$? = $ac_status" >&5
1492 (exit $ac_status); }; then
1493 # Find the output, starting from the most likely. This scheme is
1494 # not robust to junk in `.', hence go to wildcards (a.*) only as a last
1496 for ac_file in `ls a.exe conftest.exe 2>/dev/null;
1497 ls a.out conftest 2>/dev/null;
1498 ls a.* conftest.* 2>/dev/null`; do
1500 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1501 a.out ) # We found the default executable, but exeext='' is most
1504 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1505 # FIXME: I believe we export ac_cv_exeext for Libtool --akim.
1512 echo "$as_me: failed program was:" >&5
1513 cat conftest.$ac_ext >&5
1514 { { echo "$as_me:1514: error: C compiler cannot create executables" >&5
1515 echo "$as_me: error: C compiler cannot create executables" >&2;}
1516 { (exit 77); exit 77; }; }
1519 ac_exeext=$ac_cv_exeext
1520 echo "$as_me:1520: result: $ac_file" >&5
1521 echo "${ECHO_T}$ac_file" >&6
1523 # Check the compiler produces executables we can run. If not, either
1524 # the compiler is broken, or we cross compile.
1525 echo "$as_me:1525: checking whether the C compiler works" >&5
1526 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
1527 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
1528 # If not cross compiling, check that we can run a simple program.
1529 if test "$cross_compiling" != yes; then
1530 if { ac_try='./$ac_file'
1531 { (eval echo "$as_me:1531: \"$ac_try\"") >&5
1534 echo "$as_me:1534: \$? = $ac_status" >&5
1535 (exit $ac_status); }; }; then
1538 if test "$cross_compiling" = maybe; then
1541 { { echo "$as_me:1541: error: cannot run C compiled programs.
1542 If you meant to cross compile, use \`--host'." >&5
1543 echo "$as_me: error: cannot run C compiled programs.
1544 If you meant to cross compile, use \`--host'." >&2;}
1545 { (exit 1); exit 1; }; }
1549 echo "$as_me:1549: result: yes" >&5
1550 echo "${ECHO_T}yes" >&6
1552 rm -f a.out a.exe conftest$ac_cv_exeext
1553 ac_clean_files=$ac_clean_files_save
1554 # Check the compiler produces executables we can run. If not, either
1555 # the compiler is broken, or we cross compile.
1556 echo "$as_me:1556: checking whether we are cross compiling" >&5
1557 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
1558 echo "$as_me:1558: result: $cross_compiling" >&5
1559 echo "${ECHO_T}$cross_compiling" >&6
1561 echo "$as_me:1561: checking for executable suffix" >&5
1562 echo $ECHO_N "checking for executable suffix... $ECHO_C" >&6
1563 if { (eval echo "$as_me:1563: \"$ac_link\"") >&5
1564 (eval $ac_link) 2>&5
1566 echo "$as_me:1566: \$? = $ac_status" >&5
1567 (exit $ac_status); }; then
1568 # If both `conftest.exe' and `conftest' are `present' (well, observable)
1569 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
1570 # work properly (i.e., refer to `conftest.exe'), while it won't with
1572 for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do
1574 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1575 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1582 { { echo "$as_me:1582: error: cannot compute EXEEXT: cannot compile and link" >&5
1583 echo "$as_me: error: cannot compute EXEEXT: cannot compile and link" >&2;}
1584 { (exit 1); exit 1; }; }
1587 rm -f conftest$ac_cv_exeext
1588 echo "$as_me:1588: result: $ac_cv_exeext" >&5
1589 echo "${ECHO_T}$ac_cv_exeext" >&6
1591 rm -f conftest.$ac_ext
1592 EXEEXT=$ac_cv_exeext
1594 echo "$as_me:1594: checking for object suffix" >&5
1595 echo $ECHO_N "checking for object suffix... $ECHO_C" >&6
1596 if test "${ac_cv_objext+set}" = set; then
1597 echo $ECHO_N "(cached) $ECHO_C" >&6
1599 cat >conftest.$ac_ext <<_ACEOF
1600 #line 1600 "configure"
1601 #include "confdefs.h"
1611 rm -f conftest.o conftest.obj
1612 if { (eval echo "$as_me:1612: \"$ac_compile\"") >&5
1613 (eval $ac_compile) 2>&5
1615 echo "$as_me:1615: \$? = $ac_status" >&5
1616 (exit $ac_status); }; then
1617 for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
1619 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.map | *.inf ) ;;
1620 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
1625 echo "$as_me: failed program was:" >&5
1626 cat conftest.$ac_ext >&5
1627 { { echo "$as_me:1627: error: cannot compute OBJEXT: cannot compile" >&5
1628 echo "$as_me: error: cannot compute OBJEXT: cannot compile" >&2;}
1629 { (exit 1); exit 1; }; }
1632 rm -f conftest.$ac_cv_objext conftest.$ac_ext
1634 echo "$as_me:1634: result: $ac_cv_objext" >&5
1635 echo "${ECHO_T}$ac_cv_objext" >&6
1636 OBJEXT=$ac_cv_objext
1638 echo "$as_me:1638: checking whether we are using the GNU C compiler" >&5
1639 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
1640 if test "${ac_cv_c_compiler_gnu+set}" = set; then
1641 echo $ECHO_N "(cached) $ECHO_C" >&6
1643 cat >conftest.$ac_ext <<_ACEOF
1644 #line 1644 "configure"
1645 #include "confdefs.h"
1658 rm -f conftest.$ac_objext
1659 if { (eval echo "$as_me:1659: \"$ac_compile\"") >&5
1660 (eval $ac_compile) 2>&5
1662 echo "$as_me:1662: \$? = $ac_status" >&5
1663 (exit $ac_status); } &&
1664 { ac_try='test -s conftest.$ac_objext'
1665 { (eval echo "$as_me:1665: \"$ac_try\"") >&5
1668 echo "$as_me:1668: \$? = $ac_status" >&5
1669 (exit $ac_status); }; }; then
1672 echo "$as_me: failed program was:" >&5
1673 cat conftest.$ac_ext >&5
1676 rm -f conftest.$ac_objext conftest.$ac_ext
1677 ac_cv_c_compiler_gnu=$ac_compiler_gnu
1680 echo "$as_me:1680: result: $ac_cv_c_compiler_gnu" >&5
1681 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
1682 GCC=`test $ac_compiler_gnu = yes && echo yes`
1683 ac_test_CFLAGS=${CFLAGS+set}
1684 ac_save_CFLAGS=$CFLAGS
1686 echo "$as_me:1686: checking whether $CC accepts -g" >&5
1687 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
1688 if test "${ac_cv_prog_cc_g+set}" = set; then
1689 echo $ECHO_N "(cached) $ECHO_C" >&6
1691 cat >conftest.$ac_ext <<_ACEOF
1692 #line 1692 "configure"
1693 #include "confdefs.h"
1703 rm -f conftest.$ac_objext
1704 if { (eval echo "$as_me:1704: \"$ac_compile\"") >&5
1705 (eval $ac_compile) 2>&5
1707 echo "$as_me:1707: \$? = $ac_status" >&5
1708 (exit $ac_status); } &&
1709 { ac_try='test -s conftest.$ac_objext'
1710 { (eval echo "$as_me:1710: \"$ac_try\"") >&5
1713 echo "$as_me:1713: \$? = $ac_status" >&5
1714 (exit $ac_status); }; }; then
1717 echo "$as_me: failed program was:" >&5
1718 cat conftest.$ac_ext >&5
1721 rm -f conftest.$ac_objext conftest.$ac_ext
1723 echo "$as_me:1723: result: $ac_cv_prog_cc_g" >&5
1724 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
1725 if test "$ac_test_CFLAGS" = set; then
1726 CFLAGS=$ac_save_CFLAGS
1727 elif test $ac_cv_prog_cc_g = yes; then
1728 if test "$GCC" = yes; then
1734 if test "$GCC" = yes; then
1740 # Some people use a C++ compiler to compile C. Since we use `exit',
1741 # in C++ we need to declare it. In case someone uses the same compiler
1742 # for both compiling C and C++ we need to have the C++ compiler decide
1743 # the declaration of exit, since it's the most demanding environment.
1744 cat >conftest.$ac_ext <<_ACEOF
1749 rm -f conftest.$ac_objext
1750 if { (eval echo "$as_me:1750: \"$ac_compile\"") >&5
1751 (eval $ac_compile) 2>&5
1753 echo "$as_me:1753: \$? = $ac_status" >&5
1754 (exit $ac_status); } &&
1755 { ac_try='test -s conftest.$ac_objext'
1756 { (eval echo "$as_me:1756: \"$ac_try\"") >&5
1759 echo "$as_me:1759: \$? = $ac_status" >&5
1760 (exit $ac_status); }; }; then
1761 for ac_declaration in \
1763 '#include <stdlib.h>' \
1764 'extern "C" void std::exit (int) throw (); using std::exit;' \
1765 'extern "C" void std::exit (int); using std::exit;' \
1766 'extern "C" void exit (int) throw ();' \
1767 'extern "C" void exit (int);' \
1770 cat >conftest.$ac_ext <<_ACEOF
1771 #line 1771 "configure"
1772 #include "confdefs.h"
1783 rm -f conftest.$ac_objext
1784 if { (eval echo "$as_me:1784: \"$ac_compile\"") >&5
1785 (eval $ac_compile) 2>&5
1787 echo "$as_me:1787: \$? = $ac_status" >&5
1788 (exit $ac_status); } &&
1789 { ac_try='test -s conftest.$ac_objext'
1790 { (eval echo "$as_me:1790: \"$ac_try\"") >&5
1793 echo "$as_me:1793: \$? = $ac_status" >&5
1794 (exit $ac_status); }; }; then
1797 echo "$as_me: failed program was:" >&5
1798 cat conftest.$ac_ext >&5
1801 rm -f conftest.$ac_objext conftest.$ac_ext
1802 cat >conftest.$ac_ext <<_ACEOF
1803 #line 1803 "configure"
1804 #include "confdefs.h"
1814 rm -f conftest.$ac_objext
1815 if { (eval echo "$as_me:1815: \"$ac_compile\"") >&5
1816 (eval $ac_compile) 2>&5
1818 echo "$as_me:1818: \$? = $ac_status" >&5
1819 (exit $ac_status); } &&
1820 { ac_try='test -s conftest.$ac_objext'
1821 { (eval echo "$as_me:1821: \"$ac_try\"") >&5
1824 echo "$as_me:1824: \$? = $ac_status" >&5
1825 (exit $ac_status); }; }; then
1828 echo "$as_me: failed program was:" >&5
1829 cat conftest.$ac_ext >&5
1831 rm -f conftest.$ac_objext conftest.$ac_ext
1834 if test -n "$ac_declaration"; then
1835 echo '#ifdef __cplusplus' >>confdefs.h
1836 echo $ac_declaration >>confdefs.h
1837 echo '#endif' >>confdefs.h
1841 echo "$as_me: failed program was:" >&5
1842 cat conftest.$ac_ext >&5
1844 rm -f conftest.$ac_objext conftest.$ac_ext
1846 ac_cpp='$CPP $CPPFLAGS'
1847 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1848 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1849 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1850 ac_main_return=return
1853 if test "$GCC" = yes ; then
1854 echo "$as_me:1854: checking version of $CC" >&5
1855 echo $ECHO_N "checking version of $CC... $ECHO_C" >&6
1856 GCC_VERSION="`${CC} --version 2>/dev/null | sed -e '2,$d' -e 's/^.*(GCC[^)]*) //' -e 's/^.*(Debian[^)]*) //' -e 's/^[^0-9.]*//' -e 's/[^0-9.].*//'`"
1857 test -z "$GCC_VERSION" && GCC_VERSION=unknown
1858 echo "$as_me:1858: result: $GCC_VERSION" >&5
1859 echo "${ECHO_T}$GCC_VERSION" >&6
1864 if test "$GCC" = yes ; then
1867 echo "$as_me:1867: checking if this is really Intel C compiler" >&5
1868 echo $ECHO_N "checking if this is really Intel C compiler... $ECHO_C" >&6
1869 cf_save_CFLAGS="$CFLAGS"
1870 CFLAGS="$CFLAGS -no-gcc"
1871 cat >conftest.$ac_ext <<_ACEOF
1872 #line 1872 "configure"
1873 #include "confdefs.h"
1879 #ifdef __INTEL_COMPILER
1888 rm -f conftest.$ac_objext
1889 if { (eval echo "$as_me:1889: \"$ac_compile\"") >&5
1890 (eval $ac_compile) 2>&5
1892 echo "$as_me:1892: \$? = $ac_status" >&5
1893 (exit $ac_status); } &&
1894 { ac_try='test -s conftest.$ac_objext'
1895 { (eval echo "$as_me:1895: \"$ac_try\"") >&5
1898 echo "$as_me:1898: \$? = $ac_status" >&5
1899 (exit $ac_status); }; }; then
1901 cf_save_CFLAGS="$cf_save_CFLAGS -we147"
1904 echo "$as_me: failed program was:" >&5
1905 cat conftest.$ac_ext >&5
1907 rm -f conftest.$ac_objext conftest.$ac_ext
1908 CFLAGS="$cf_save_CFLAGS"
1909 echo "$as_me:1909: result: $INTEL_COMPILER" >&5
1910 echo "${ECHO_T}$INTEL_COMPILER" >&6
1917 if test "$GCC" = yes ; then
1918 echo "$as_me:1918: checking if this is really Clang C compiler" >&5
1919 echo $ECHO_N "checking if this is really Clang C compiler... $ECHO_C" >&6
1920 cf_save_CFLAGS="$CFLAGS"
1921 cat >conftest.$ac_ext <<_ACEOF
1922 #line 1922 "configure"
1923 #include "confdefs.h"
1938 rm -f conftest.$ac_objext
1939 if { (eval echo "$as_me:1939: \"$ac_compile\"") >&5
1940 (eval $ac_compile) 2>&5
1942 echo "$as_me:1942: \$? = $ac_status" >&5
1943 (exit $ac_status); } &&
1944 { ac_try='test -s conftest.$ac_objext'
1945 { (eval echo "$as_me:1945: \"$ac_try\"") >&5
1948 echo "$as_me:1948: \$? = $ac_status" >&5
1949 (exit $ac_status); }; }; then
1953 echo "$as_me: failed program was:" >&5
1954 cat conftest.$ac_ext >&5
1956 rm -f conftest.$ac_objext conftest.$ac_ext
1957 CFLAGS="$cf_save_CFLAGS"
1958 echo "$as_me:1958: result: $CLANG_COMPILER" >&5
1959 echo "${ECHO_T}$CLANG_COMPILER" >&6
1964 if test "x$CLANG_COMPILER" = "xyes" ; then
1966 (c[1-9][0-9]|*/c[1-9][0-9])
1967 { echo "$as_me:1967: WARNING: replacing broken compiler alias $CC" >&5
1968 echo "$as_me: WARNING: replacing broken compiler alias $CC" >&2;}
1969 CFLAGS="$CFLAGS -std=`echo "$CC" | sed -e 's%.*/%%'`"
1974 echo "$as_me:1974: checking version of $CC" >&5
1975 echo $ECHO_N "checking version of $CC... $ECHO_C" >&6
1976 CLANG_VERSION="`$CC --version 2>/dev/null | sed -e '2,$d' -e 's/^.*(CLANG[^)]*) //' -e 's/^.*(Debian[^)]*) //' -e 's/^[^0-9.]*//' -e 's/[^0-9.].*//'`"
1977 test -z "$CLANG_VERSION" && CLANG_VERSION=unknown
1978 echo "$as_me:1978: result: $CLANG_VERSION" >&5
1979 echo "${ECHO_T}$CLANG_VERSION" >&6
1981 for cf_clang_opt in \
1982 -Qunused-arguments \
1983 -Wno-error=implicit-function-declaration
1985 echo "$as_me:1985: checking if option $cf_clang_opt works" >&5
1986 echo $ECHO_N "checking if option $cf_clang_opt works... $ECHO_C" >&6
1987 cf_save_CFLAGS="$CFLAGS"
1988 CFLAGS="$CFLAGS $cf_clang_opt"
1989 cat >conftest.$ac_ext <<_ACEOF
1990 #line 1990 "configure"
1991 #include "confdefs.h"
2003 rm -f conftest.$ac_objext conftest$ac_exeext
2004 if { (eval echo "$as_me:2004: \"$ac_link\"") >&5
2005 (eval $ac_link) 2>&5
2007 echo "$as_me:2007: \$? = $ac_status" >&5
2008 (exit $ac_status); } &&
2009 { ac_try='test -s conftest$ac_exeext'
2010 { (eval echo "$as_me:2010: \"$ac_try\"") >&5
2013 echo "$as_me:2013: \$? = $ac_status" >&5
2014 (exit $ac_status); }; }; then
2018 echo "$as_me: failed program was:" >&5
2019 cat conftest.$ac_ext >&5
2023 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
2024 echo "$as_me:2024: result: $cf_clang_optok" >&5
2025 echo "${ECHO_T}$cf_clang_optok" >&6
2026 CFLAGS="$cf_save_CFLAGS"
2027 if test $cf_clang_optok = yes; then
2028 test -n "$verbose" && echo " adding option $cf_clang_opt" 1>&6
2030 echo "${as_me:-configure}:2030: testing adding option $cf_clang_opt ..." 1>&5
2032 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
2033 CFLAGS="${CFLAGS}$cf_clang_opt"
2039 echo "$as_me:2039: checking for $CC option to accept ANSI C" >&5
2040 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
2041 if test "${ac_cv_prog_cc_stdc+set}" = set; then
2042 echo $ECHO_N "(cached) $ECHO_C" >&6
2044 ac_cv_prog_cc_stdc=no
2046 cat >conftest.$ac_ext <<_ACEOF
2047 #line 2047 "configure"
2048 #include "confdefs.h"
2051 #include <sys/types.h>
2052 #include <sys/stat.h>
2053 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
2054 struct buf { int x; };
2055 FILE * (*rcsopen) (struct buf *, struct stat *, int);
2056 static char *e (p, i)
2062 static char *f (char * (*g) (char **, int), char **p, ...)
2067 s = g (p, va_arg (v,int));
2071 int test (int i, double x);
2072 struct s1 {int (*f) (int a);};
2073 struct s2 {int (*f) (double a);};
2074 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
2080 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
2085 # Don't try gcc -ansi; that turns off useful extensions and
2086 # breaks some systems' header files.
2087 # AIX -qlanglvl=ansi
2088 # Ultrix and OSF/1 -std1
2089 # HP-UX 10.20 and later -Ae
2090 # HP-UX older versions -Aa -D_HPUX_SOURCE
2091 # SVR4 -Xc -D__EXTENSIONS__
2092 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
2094 CC="$ac_save_CC $ac_arg"
2095 rm -f conftest.$ac_objext
2096 if { (eval echo "$as_me:2096: \"$ac_compile\"") >&5
2097 (eval $ac_compile) 2>&5
2099 echo "$as_me:2099: \$? = $ac_status" >&5
2100 (exit $ac_status); } &&
2101 { ac_try='test -s conftest.$ac_objext'
2102 { (eval echo "$as_me:2102: \"$ac_try\"") >&5
2105 echo "$as_me:2105: \$? = $ac_status" >&5
2106 (exit $ac_status); }; }; then
2107 ac_cv_prog_cc_stdc=$ac_arg
2110 echo "$as_me: failed program was:" >&5
2111 cat conftest.$ac_ext >&5
2113 rm -f conftest.$ac_objext
2115 rm -f conftest.$ac_ext conftest.$ac_objext
2120 case "x$ac_cv_prog_cc_stdc" in
2122 echo "$as_me:2122: result: none needed" >&5
2123 echo "${ECHO_T}none needed" >&6 ;;
2125 echo "$as_me:2125: result: $ac_cv_prog_cc_stdc" >&5
2126 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
2127 CC="$CC $ac_cv_prog_cc_stdc" ;;
2130 # This should have been defined by AC_PROG_CC
2133 echo "$as_me:2133: checking \$CFLAGS variable" >&5
2134 echo $ECHO_N "checking \$CFLAGS variable... $ECHO_C" >&6
2137 echo "$as_me:2137: result: broken" >&5
2138 echo "${ECHO_T}broken" >&6
2139 { echo "$as_me:2139: WARNING: your environment uses the CFLAGS variable to hold CPPFLAGS options" >&5
2140 echo "$as_me: WARNING: your environment uses the CFLAGS variable to hold CPPFLAGS options" >&2;}
2143 for cf_arg in $cf_flags
2149 cf_new_extra_cppflags=
2151 for cf_add_cflags in $cf_arg
2153 case $cf_fix_cppflags in
2155 case $cf_add_cflags in
2156 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
2157 case $cf_add_cflags in
2159 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
2161 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2162 && test -z "${cf_tst_cflags}" \
2163 && cf_fix_cppflags=yes
2165 if test $cf_fix_cppflags = yes ; then
2167 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2168 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2171 elif test "${cf_tst_cflags}" = "\"'" ; then
2173 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2174 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2184 case $cf_add_cflags in
2186 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
2188 CPPFLAGS=`echo "$CPPFLAGS" | \
2189 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
2190 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
2195 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
2196 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
2203 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
2204 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
2211 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2212 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2214 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
2216 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2217 && test -z "${cf_tst_cflags}" \
2218 && cf_fix_cppflags=no
2223 if test -n "$cf_new_cflags" ; then
2225 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
2226 CFLAGS="${CFLAGS}$cf_new_cflags"
2230 if test -n "$cf_new_cppflags" ; then
2232 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
2233 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
2237 if test -n "$cf_new_extra_cppflags" ; then
2239 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
2240 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
2247 echo "$as_me:2247: result: ok" >&5
2248 echo "${ECHO_T}ok" >&6
2252 echo "$as_me:2252: checking \$CC variable" >&5
2253 echo $ECHO_N "checking \$CC variable... $ECHO_C" >&6
2256 echo "$as_me:2256: result: broken" >&5
2257 echo "${ECHO_T}broken" >&6
2258 { echo "$as_me:2258: WARNING: your environment uses the CC variable to hold CFLAGS/CPPFLAGS options" >&5
2259 echo "$as_me: WARNING: your environment uses the CC variable to hold CFLAGS/CPPFLAGS options" >&2;}
2261 cf_prog=`echo "$CC" | sed -e 's/ / /g' -e 's/[ ]* / /g' -e 's/[ ]*[ ]-[^ ].*//'`
2262 cf_flags=`echo "$CC" | ${AWK:-awk} -v prog="$cf_prog" '{ printf("%s", substr($0,1+length(prog))); }'`
2264 for cf_arg in $cf_flags
2272 cf_new_extra_cppflags=
2274 for cf_add_cflags in $cf_arg
2276 case $cf_fix_cppflags in
2278 case $cf_add_cflags in
2279 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
2280 case $cf_add_cflags in
2282 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
2284 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2285 && test -z "${cf_tst_cflags}" \
2286 && cf_fix_cppflags=yes
2288 if test $cf_fix_cppflags = yes ; then
2290 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2291 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2294 elif test "${cf_tst_cflags}" = "\"'" ; then
2296 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2297 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2307 case $cf_add_cflags in
2309 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
2311 CPPFLAGS=`echo "$CPPFLAGS" | \
2312 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
2313 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
2318 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
2319 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
2326 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
2327 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
2334 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2335 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2337 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
2339 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2340 && test -z "${cf_tst_cflags}" \
2341 && cf_fix_cppflags=no
2346 if test -n "$cf_new_cflags" ; then
2348 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
2349 CFLAGS="${CFLAGS}$cf_new_cflags"
2353 if test -n "$cf_new_cppflags" ; then
2355 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
2356 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
2360 if test -n "$cf_new_extra_cppflags" ; then
2362 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
2363 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
2373 test -n "$verbose" && echo " resulting CC: '$CC'" 1>&6
2375 echo "${as_me:-configure}:2375: testing resulting CC: '$CC' ..." 1>&5
2377 test -n "$verbose" && echo " resulting CFLAGS: '$CFLAGS'" 1>&6
2379 echo "${as_me:-configure}:2379: testing resulting CFLAGS: '$CFLAGS' ..." 1>&5
2381 test -n "$verbose" && echo " resulting CPPFLAGS: '$CPPFLAGS'" 1>&6
2383 echo "${as_me:-configure}:2383: testing resulting CPPFLAGS: '$CPPFLAGS' ..." 1>&5
2387 echo "$as_me:2387: result: ok" >&5
2388 echo "${ECHO_T}ok" >&6
2392 echo "$as_me:2392: checking for inline" >&5
2393 echo $ECHO_N "checking for inline... $ECHO_C" >&6
2394 if test "${ac_cv_c_inline+set}" = set; then
2395 echo $ECHO_N "(cached) $ECHO_C" >&6
2398 for ac_kw in inline __inline__ __inline; do
2399 cat >conftest.$ac_ext <<_ACEOF
2400 #line 2400 "configure"
2401 #include "confdefs.h"
2403 static $ac_kw int static_foo () {return 0; }
2404 $ac_kw int foo () {return 0; }
2408 rm -f conftest.$ac_objext
2409 if { (eval echo "$as_me:2409: \"$ac_compile\"") >&5
2410 (eval $ac_compile) 2>&5
2412 echo "$as_me:2412: \$? = $ac_status" >&5
2413 (exit $ac_status); } &&
2414 { ac_try='test -s conftest.$ac_objext'
2415 { (eval echo "$as_me:2415: \"$ac_try\"") >&5
2418 echo "$as_me:2418: \$? = $ac_status" >&5
2419 (exit $ac_status); }; }; then
2420 ac_cv_c_inline=$ac_kw; break
2422 echo "$as_me: failed program was:" >&5
2423 cat conftest.$ac_ext >&5
2425 rm -f conftest.$ac_objext conftest.$ac_ext
2429 echo "$as_me:2429: result: $ac_cv_c_inline" >&5
2430 echo "${ECHO_T}$ac_cv_c_inline" >&6
2431 case $ac_cv_c_inline in
2434 cat >>confdefs.h <<\EOF
2438 *) cat >>confdefs.h <<EOF
2439 #define inline $ac_cv_c_inline
2445 ac_cpp='$CPP $CPPFLAGS'
2446 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2447 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2448 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2449 ac_main_return=return
2450 echo "$as_me:2450: checking how to run the C preprocessor" >&5
2451 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
2452 # On Suns, sometimes $CPP names a directory.
2453 if test -n "$CPP" && test -d "$CPP"; then
2456 if test -z "$CPP"; then
2457 if test "${ac_cv_prog_CPP+set}" = set; then
2458 echo $ECHO_N "(cached) $ECHO_C" >&6
2460 # Double quotes because CPP needs to be expanded
2461 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
2464 for ac_c_preproc_warn_flag in '' yes
2466 # Use a header file that comes with gcc, so configuring glibc
2467 # with a fresh cross-compiler works.
2468 # On the NeXT, cc -E runs the code through the compiler's parser,
2469 # not just through cpp. "Syntax error" is here to catch this case.
2470 cat >conftest.$ac_ext <<_ACEOF
2471 #line 2471 "configure"
2472 #include "confdefs.h"
2476 if { (eval echo "$as_me:2476: \"$ac_cpp conftest.$ac_ext\"") >&5
2477 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2479 egrep -v '^ *\+' conftest.er1 >conftest.err
2481 cat conftest.err >&5
2482 echo "$as_me:2482: \$? = $ac_status" >&5
2483 (exit $ac_status); } >/dev/null; then
2484 if test -s conftest.err; then
2485 ac_cpp_err=$ac_c_preproc_warn_flag
2492 if test -z "$ac_cpp_err"; then
2495 echo "$as_me: failed program was:" >&5
2496 cat conftest.$ac_ext >&5
2497 # Broken: fails on valid input.
2500 rm -f conftest.err conftest.$ac_ext
2502 # OK, works on sane cases. Now check whether non-existent headers
2503 # can be detected and how.
2504 cat >conftest.$ac_ext <<_ACEOF
2505 #line 2505 "configure"
2506 #include "confdefs.h"
2507 #include <ac_nonexistent.h>
2509 if { (eval echo "$as_me:2509: \"$ac_cpp conftest.$ac_ext\"") >&5
2510 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2512 egrep -v '^ *\+' conftest.er1 >conftest.err
2514 cat conftest.err >&5
2515 echo "$as_me:2515: \$? = $ac_status" >&5
2516 (exit $ac_status); } >/dev/null; then
2517 if test -s conftest.err; then
2518 ac_cpp_err=$ac_c_preproc_warn_flag
2525 if test -z "$ac_cpp_err"; then
2526 # Broken: success on invalid input.
2529 echo "$as_me: failed program was:" >&5
2530 cat conftest.$ac_ext >&5
2531 # Passes both tests.
2535 rm -f conftest.err conftest.$ac_ext
2538 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2539 rm -f conftest.err conftest.$ac_ext
2540 if $ac_preproc_ok; then
2552 echo "$as_me:2552: result: $CPP" >&5
2553 echo "${ECHO_T}$CPP" >&6
2555 for ac_c_preproc_warn_flag in '' yes
2557 # Use a header file that comes with gcc, so configuring glibc
2558 # with a fresh cross-compiler works.
2559 # On the NeXT, cc -E runs the code through the compiler's parser,
2560 # not just through cpp. "Syntax error" is here to catch this case.
2561 cat >conftest.$ac_ext <<_ACEOF
2562 #line 2562 "configure"
2563 #include "confdefs.h"
2567 if { (eval echo "$as_me:2567: \"$ac_cpp conftest.$ac_ext\"") >&5
2568 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2570 egrep -v '^ *\+' conftest.er1 >conftest.err
2572 cat conftest.err >&5
2573 echo "$as_me:2573: \$? = $ac_status" >&5
2574 (exit $ac_status); } >/dev/null; then
2575 if test -s conftest.err; then
2576 ac_cpp_err=$ac_c_preproc_warn_flag
2583 if test -z "$ac_cpp_err"; then
2586 echo "$as_me: failed program was:" >&5
2587 cat conftest.$ac_ext >&5
2588 # Broken: fails on valid input.
2591 rm -f conftest.err conftest.$ac_ext
2593 # OK, works on sane cases. Now check whether non-existent headers
2594 # can be detected and how.
2595 cat >conftest.$ac_ext <<_ACEOF
2596 #line 2596 "configure"
2597 #include "confdefs.h"
2598 #include <ac_nonexistent.h>
2600 if { (eval echo "$as_me:2600: \"$ac_cpp conftest.$ac_ext\"") >&5
2601 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2603 egrep -v '^ *\+' conftest.er1 >conftest.err
2605 cat conftest.err >&5
2606 echo "$as_me:2606: \$? = $ac_status" >&5
2607 (exit $ac_status); } >/dev/null; then
2608 if test -s conftest.err; then
2609 ac_cpp_err=$ac_c_preproc_warn_flag
2616 if test -z "$ac_cpp_err"; then
2617 # Broken: success on invalid input.
2620 echo "$as_me: failed program was:" >&5
2621 cat conftest.$ac_ext >&5
2622 # Passes both tests.
2626 rm -f conftest.err conftest.$ac_ext
2629 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2630 rm -f conftest.err conftest.$ac_ext
2631 if $ac_preproc_ok; then
2634 { { echo "$as_me:2634: error: C preprocessor \"$CPP\" fails sanity check" >&5
2635 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;}
2636 { (exit 1); exit 1; }; }
2640 ac_cpp='$CPP $CPPFLAGS'
2641 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2642 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2643 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2644 ac_main_return=return
2646 for ac_prog in mawk gawk nawk awk
2648 # Extract the first word of "$ac_prog", so it can be a program name with args.
2649 set dummy $ac_prog; ac_word=$2
2650 echo "$as_me:2650: checking for $ac_word" >&5
2651 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2652 if test "${ac_cv_prog_AWK+set}" = set; then
2653 echo $ECHO_N "(cached) $ECHO_C" >&6
2655 if test -n "$AWK"; then
2656 ac_cv_prog_AWK="$AWK" # Let the user override the test.
2658 ac_save_IFS=$IFS; IFS=$ac_path_separator
2660 for ac_dir in $ac_dummy; do
2662 test -z "$ac_dir" && ac_dir=.
2663 $as_executable_p "$ac_dir/$ac_word" || continue
2664 ac_cv_prog_AWK="$ac_prog"
2665 echo "$as_me:2665: found $ac_dir/$ac_word" >&5
2672 if test -n "$AWK"; then
2673 echo "$as_me:2673: result: $AWK" >&5
2674 echo "${ECHO_T}$AWK" >&6
2676 echo "$as_me:2676: result: no" >&5
2677 echo "${ECHO_T}no" >&6
2680 test -n "$AWK" && break
2683 # Find a good install program. We prefer a C program (faster),
2684 # so one script is as good as another. But avoid the broken or
2685 # incompatible versions:
2686 # SysV /etc/install, /usr/sbin/install
2687 # SunOS /usr/etc/install
2688 # IRIX /sbin/install
2690 # AmigaOS /C/install, which installs bootblocks on floppy discs
2691 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
2692 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
2693 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
2694 # ./install, which can be erroneously created by make from ./install.sh.
2695 echo "$as_me:2695: checking for a BSD compatible install" >&5
2696 echo $ECHO_N "checking for a BSD compatible install... $ECHO_C" >&6
2697 if test -z "$INSTALL"; then
2698 if test "${ac_cv_path_install+set}" = set; then
2699 echo $ECHO_N "(cached) $ECHO_C" >&6
2701 ac_save_IFS=$IFS; IFS=$ac_path_separator
2702 for ac_dir in $PATH; do
2704 # Account for people who put trailing slashes in PATH elements.
2706 / | ./ | .// | /cC/* \
2707 | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* \
2710 # OSF1 and SCO ODT 3.0 have their own names for install.
2711 # Don't use installbsd from OSF since it installs stuff as root
2713 for ac_prog in ginstall scoinst install; do
2714 if $as_executable_p "$ac_dir/$ac_prog"; then
2715 if test $ac_prog = install &&
2716 grep dspmsg "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2717 # AIX install. It has an incompatible calling convention.
2719 elif test $ac_prog = install &&
2720 grep pwplus "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2721 # program-specific install script used by HP pwplus--don't use.
2724 ac_cv_path_install="$ac_dir/$ac_prog -c"
2734 if test "${ac_cv_path_install+set}" = set; then
2735 INSTALL=$ac_cv_path_install
2737 # As a last resort, use the slow shell script. We don't cache a
2738 # path for INSTALL within a source directory, because that will
2739 # break other packages using the cache if that directory is
2740 # removed, or if the path is relative.
2741 INSTALL=$ac_install_sh
2744 echo "$as_me:2744: result: $INSTALL" >&5
2745 echo "${ECHO_T}$INSTALL" >&6
2747 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
2748 # It thinks the first close brace ends the variable substitution.
2749 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
2751 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
2753 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
2759 cf_dir=`echo $INSTALL | sed -e 's%/[^/]*$%%'`
2760 test -z "$cf_dir" && cf_dir=.
2761 INSTALL=`cd $cf_dir && pwd`/`echo $INSTALL | sed -e 's%^.*/%%'`
2765 echo "$as_me:2765: checking if you want to install stripped executables" >&5
2766 echo $ECHO_N "checking if you want to install stripped executables... $ECHO_C" >&6
2768 # Check whether --enable-stripping or --disable-stripping was given.
2769 if test "${enable_stripping+set}" = set; then
2770 enableval="$enable_stripping"
2771 test "$enableval" != no && enableval=yes
2772 if test "$enableval" != "yes" ; then
2782 echo "$as_me:2782: result: $with_stripping" >&5
2783 echo "${ECHO_T}$with_stripping" >&6
2785 if test "$with_stripping" = yes
2792 : ${INSTALL:=install}
2793 echo "$as_me:2793: checking if install accepts -p option" >&5
2794 echo $ECHO_N "checking if install accepts -p option... $ECHO_C" >&6
2795 if test "${cf_cv_install_p+set}" = set; then
2796 echo $ECHO_N "(cached) $ECHO_C" >&6
2803 if $INSTALL -p conftest.in conftest.out 2>/dev/null
2805 if test -f conftest.out/conftest.in
2807 test conftest.in -nt conftest.out/conftest.in 2>conftest.err && \
2808 test conftest.out/conftest.in -nt conftest.in 2>conftest.err
2809 if test -s conftest.err
2824 echo "$as_me:2824: result: $cf_cv_install_p" >&5
2825 echo "${ECHO_T}$cf_cv_install_p" >&6
2827 echo "$as_me:2827: checking if install needs to be told about ownership" >&5
2828 echo $ECHO_N "checking if install needs to be told about ownership... $ECHO_C" >&6
2829 case `$ac_config_guess` in
2838 echo "$as_me:2838: result: $with_install_o" >&5
2839 echo "${ECHO_T}$with_install_o" >&6
2840 if test "x$with_install_o" = xyes
2842 INSTALL_OPT_O=`id root|sed -e 's/uid=[0-9]*(/ -o /' -e 's/gid=[0-9]*(/ -g /' -e 's/ [^=[:space:]][^=[:space:]]*=.*/ /' -e 's/)//g'`
2847 for ac_prog in lint cppcheck splint
2849 # Extract the first word of "$ac_prog", so it can be a program name with args.
2850 set dummy $ac_prog; ac_word=$2
2851 echo "$as_me:2851: checking for $ac_word" >&5
2852 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2853 if test "${ac_cv_prog_LINT+set}" = set; then
2854 echo $ECHO_N "(cached) $ECHO_C" >&6
2856 if test -n "$LINT"; then
2857 ac_cv_prog_LINT="$LINT" # Let the user override the test.
2859 ac_save_IFS=$IFS; IFS=$ac_path_separator
2861 for ac_dir in $ac_dummy; do
2863 test -z "$ac_dir" && ac_dir=.
2864 $as_executable_p "$ac_dir/$ac_word" || continue
2865 ac_cv_prog_LINT="$ac_prog"
2866 echo "$as_me:2866: found $ac_dir/$ac_word" >&5
2872 LINT=$ac_cv_prog_LINT
2873 if test -n "$LINT"; then
2874 echo "$as_me:2874: result: $LINT" >&5
2875 echo "${ECHO_T}$LINT" >&6
2877 echo "$as_me:2877: result: no" >&5
2878 echo "${ECHO_T}no" >&6
2881 test -n "$LINT" && break
2885 (xcppcheck|x*/cppcheck)
2886 test -z "$LINT_OPTS" && LINT_OPTS="--enable=all"
2890 echo "$as_me:2890: checking if filesystem supports mixed-case filenames" >&5
2891 echo $ECHO_N "checking if filesystem supports mixed-case filenames... $ECHO_C" >&6
2892 if test "${cf_cv_mixedcase+set}" = set; then
2893 echo $ECHO_N "(cached) $ECHO_C" >&6
2896 if test "$cross_compiling" = yes ; then
2897 case $target_alias in
2898 (*-os2-emx*|*-msdosdjgpp*|*-cygwin*|*-msys*|*-mingw*|*-uwin*|darwin*)
2906 rm -f conftest CONFTEST
2908 if test -f CONFTEST ; then
2913 rm -f conftest CONFTEST
2917 echo "$as_me:2917: result: $cf_cv_mixedcase" >&5
2918 echo "${ECHO_T}$cf_cv_mixedcase" >&6
2919 test "$cf_cv_mixedcase" = yes &&
2920 cat >>confdefs.h <<\EOF
2921 #define MIXEDCASE_FILENAMES 1
2924 for ac_prog in exctags ctags
2926 # Extract the first word of "$ac_prog", so it can be a program name with args.
2927 set dummy $ac_prog; ac_word=$2
2928 echo "$as_me:2928: checking for $ac_word" >&5
2929 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2930 if test "${ac_cv_prog_CTAGS+set}" = set; then
2931 echo $ECHO_N "(cached) $ECHO_C" >&6
2933 if test -n "$CTAGS"; then
2934 ac_cv_prog_CTAGS="$CTAGS" # Let the user override the test.
2936 ac_save_IFS=$IFS; IFS=$ac_path_separator
2938 for ac_dir in $ac_dummy; do
2940 test -z "$ac_dir" && ac_dir=.
2941 $as_executable_p "$ac_dir/$ac_word" || continue
2942 ac_cv_prog_CTAGS="$ac_prog"
2943 echo "$as_me:2943: found $ac_dir/$ac_word" >&5
2949 CTAGS=$ac_cv_prog_CTAGS
2950 if test -n "$CTAGS"; then
2951 echo "$as_me:2951: result: $CTAGS" >&5
2952 echo "${ECHO_T}$CTAGS" >&6
2954 echo "$as_me:2954: result: no" >&5
2955 echo "${ECHO_T}no" >&6
2958 test -n "$CTAGS" && break
2961 for ac_prog in exetags etags
2963 # Extract the first word of "$ac_prog", so it can be a program name with args.
2964 set dummy $ac_prog; ac_word=$2
2965 echo "$as_me:2965: checking for $ac_word" >&5
2966 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2967 if test "${ac_cv_prog_ETAGS+set}" = set; then
2968 echo $ECHO_N "(cached) $ECHO_C" >&6
2970 if test -n "$ETAGS"; then
2971 ac_cv_prog_ETAGS="$ETAGS" # Let the user override the test.
2973 ac_save_IFS=$IFS; IFS=$ac_path_separator
2975 for ac_dir in $ac_dummy; do
2977 test -z "$ac_dir" && ac_dir=.
2978 $as_executable_p "$ac_dir/$ac_word" || continue
2979 ac_cv_prog_ETAGS="$ac_prog"
2980 echo "$as_me:2980: found $ac_dir/$ac_word" >&5
2986 ETAGS=$ac_cv_prog_ETAGS
2987 if test -n "$ETAGS"; then
2988 echo "$as_me:2988: result: $ETAGS" >&5
2989 echo "${ECHO_T}$ETAGS" >&6
2991 echo "$as_me:2991: result: no" >&5
2992 echo "${ECHO_T}no" >&6
2995 test -n "$ETAGS" && break
2998 # Extract the first word of "${CTAGS:-ctags}", so it can be a program name with args.
2999 set dummy ${CTAGS:-ctags}; ac_word=$2
3000 echo "$as_me:3000: checking for $ac_word" >&5
3001 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3002 if test "${ac_cv_prog_MAKE_LOWER_TAGS+set}" = set; then
3003 echo $ECHO_N "(cached) $ECHO_C" >&6
3005 if test -n "$MAKE_LOWER_TAGS"; then
3006 ac_cv_prog_MAKE_LOWER_TAGS="$MAKE_LOWER_TAGS" # Let the user override the test.
3008 ac_save_IFS=$IFS; IFS=$ac_path_separator
3010 for ac_dir in $ac_dummy; do
3012 test -z "$ac_dir" && ac_dir=.
3013 $as_executable_p "$ac_dir/$ac_word" || continue
3014 ac_cv_prog_MAKE_LOWER_TAGS="yes"
3015 echo "$as_me:3015: found $ac_dir/$ac_word" >&5
3019 test -z "$ac_cv_prog_MAKE_LOWER_TAGS" && ac_cv_prog_MAKE_LOWER_TAGS="no"
3022 MAKE_LOWER_TAGS=$ac_cv_prog_MAKE_LOWER_TAGS
3023 if test -n "$MAKE_LOWER_TAGS"; then
3024 echo "$as_me:3024: result: $MAKE_LOWER_TAGS" >&5
3025 echo "${ECHO_T}$MAKE_LOWER_TAGS" >&6
3027 echo "$as_me:3027: result: no" >&5
3028 echo "${ECHO_T}no" >&6
3031 if test "$cf_cv_mixedcase" = yes ; then
3032 # Extract the first word of "${ETAGS:-etags}", so it can be a program name with args.
3033 set dummy ${ETAGS:-etags}; ac_word=$2
3034 echo "$as_me:3034: checking for $ac_word" >&5
3035 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3036 if test "${ac_cv_prog_MAKE_UPPER_TAGS+set}" = set; then
3037 echo $ECHO_N "(cached) $ECHO_C" >&6
3039 if test -n "$MAKE_UPPER_TAGS"; then
3040 ac_cv_prog_MAKE_UPPER_TAGS="$MAKE_UPPER_TAGS" # Let the user override the test.
3042 ac_save_IFS=$IFS; IFS=$ac_path_separator
3044 for ac_dir in $ac_dummy; do
3046 test -z "$ac_dir" && ac_dir=.
3047 $as_executable_p "$ac_dir/$ac_word" || continue
3048 ac_cv_prog_MAKE_UPPER_TAGS="yes"
3049 echo "$as_me:3049: found $ac_dir/$ac_word" >&5
3053 test -z "$ac_cv_prog_MAKE_UPPER_TAGS" && ac_cv_prog_MAKE_UPPER_TAGS="no"
3056 MAKE_UPPER_TAGS=$ac_cv_prog_MAKE_UPPER_TAGS
3057 if test -n "$MAKE_UPPER_TAGS"; then
3058 echo "$as_me:3058: result: $MAKE_UPPER_TAGS" >&5
3059 echo "${ECHO_T}$MAKE_UPPER_TAGS" >&6
3061 echo "$as_me:3061: result: no" >&5
3062 echo "${ECHO_T}no" >&6
3069 if test "$MAKE_UPPER_TAGS" = yes ; then
3075 if test "$MAKE_LOWER_TAGS" = yes ; then
3081 echo "$as_me:3081: checking if -lm needed for math functions" >&5
3082 echo $ECHO_N "checking if -lm needed for math functions... $ECHO_C" >&6
3083 if test "${cf_cv_need_libm+set}" = set; then
3084 echo $ECHO_N "(cached) $ECHO_C" >&6
3087 cat >conftest.$ac_ext <<_ACEOF
3088 #line 3088 "configure"
3089 #include "confdefs.h"
3098 double x = rand(); printf("result = %g\n", pow(sin(x),x))
3103 rm -f conftest.$ac_objext conftest$ac_exeext
3104 if { (eval echo "$as_me:3104: \"$ac_link\"") >&5
3105 (eval $ac_link) 2>&5
3107 echo "$as_me:3107: \$? = $ac_status" >&5
3108 (exit $ac_status); } &&
3109 { ac_try='test -s conftest$ac_exeext'
3110 { (eval echo "$as_me:3110: \"$ac_try\"") >&5
3113 echo "$as_me:3113: \$? = $ac_status" >&5
3114 (exit $ac_status); }; }; then
3117 echo "$as_me: failed program was:" >&5
3118 cat conftest.$ac_ext >&5
3121 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
3123 echo "$as_me:3123: result: $cf_cv_need_libm" >&5
3124 echo "${ECHO_T}$cf_cv_need_libm" >&6
3125 if test "$cf_cv_need_libm" = yes
3133 CC_SHARED_OPTS=unknown
3134 CPPFLAGS="$CPPFLAGS"
3136 DFT_OBJ_SUBDIR=`pwd|sed -e's:.*/::'`
3137 DFT_UPR_MODEL="NORMAL"
3150 PACKAGE="ncurses-examples"
3156 TINFO_LIBS='$(LIBS_CURSES)'
3157 cf_cv_abi_version=""
3158 cf_cv_rel_version=""
3164 if ( test "$GCC" = yes || test "$GXX" = yes )
3166 cat > conftest.i <<EOF
3168 #define GCC_PRINTF 0
3173 #ifndef GCC_NORETURN
3174 #define GCC_NORETURN /* nothing */
3177 #define GCC_UNUSED /* nothing */
3180 if test "$GCC" = yes
3182 { echo "$as_me:3182: checking for $CC __attribute__ directives..." >&5
3183 echo "$as_me: checking for $CC __attribute__ directives..." >&6;}
3184 cat > conftest.$ac_ext <<EOF
3185 #line 3185 "${as_me:-configure}"
3186 #include "confdefs.h"
3187 #include "conftest.h"
3188 #include "conftest.i"
3190 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
3192 #define GCC_PRINTFLIKE(fmt,var) /*nothing*/
3195 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
3197 #define GCC_SCANFLIKE(fmt,var) /*nothing*/
3199 extern void wow(char *,...) GCC_SCANFLIKE(1,2);
3200 extern void oops(char *,...) GCC_PRINTFLIKE(1,2) GCC_NORETURN;
3201 extern void foo(void) GCC_NORETURN;
3202 int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { (void)argc; (void)argv; return 0; }
3204 cf_printf_attribute=no
3205 cf_scanf_attribute=no
3206 for cf_attribute in scanf printf unused noreturn
3209 cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
3211 cf_directive="__attribute__(($cf_attribute))"
3212 echo "checking for $CC $cf_directive" 1>&5
3214 case $cf_attribute in
3216 cf_printf_attribute=yes
3217 cat >conftest.h <<EOF
3218 #define GCC_$cf_ATTRIBUTE 1
3222 cf_scanf_attribute=yes
3223 cat >conftest.h <<EOF
3224 #define GCC_$cf_ATTRIBUTE 1
3228 cat >conftest.h <<EOF
3229 #define GCC_$cf_ATTRIBUTE $cf_directive
3234 if { (eval echo "$as_me:3234: \"$ac_compile\"") >&5
3235 (eval $ac_compile) 2>&5
3237 echo "$as_me:3237: \$? = $ac_status" >&5
3238 (exit $ac_status); }; then
3239 test -n "$verbose" && echo "$as_me:3239: result: ... $cf_attribute" >&5
3240 echo "${ECHO_T}... $cf_attribute" >&6
3241 cat conftest.h >>confdefs.h
3242 case $cf_attribute in
3245 cat >>confdefs.h <<EOF
3246 #define GCC_NORETURN $cf_directive
3251 cf_value='/* nothing */'
3252 if test "$cf_printf_attribute" != no ; then
3253 cf_value='__attribute__((format(printf,fmt,var)))'
3255 cat >>confdefs.h <<\EOF
3256 #define GCC_PRINTF 1
3261 cat >>confdefs.h <<EOF
3262 #define GCC_PRINTFLIKE(fmt,var) $cf_value
3267 cf_value='/* nothing */'
3268 if test "$cf_scanf_attribute" != no ; then
3269 cf_value='__attribute__((format(scanf,fmt,var)))'
3271 cat >>confdefs.h <<\EOF
3277 cat >>confdefs.h <<EOF
3278 #define GCC_SCANFLIKE(fmt,var) $cf_value
3284 cat >>confdefs.h <<EOF
3285 #define GCC_UNUSED $cf_directive
3293 fgrep define conftest.i >>confdefs.h
3298 echo "$as_me:3298: checking if you want to work around bogus compiler/loader warnings" >&5
3299 echo $ECHO_N "checking if you want to work around bogus compiler/loader warnings... $ECHO_C" >&6
3301 # Check whether --enable-string-hacks or --disable-string-hacks was given.
3302 if test "${enable_string_hacks+set}" = set; then
3303 enableval="$enable_string_hacks"
3304 with_string_hacks=$enableval
3306 with_string_hacks=no
3308 echo "$as_me:3308: result: $with_string_hacks" >&5
3309 echo "${ECHO_T}$with_string_hacks" >&6
3311 if test "x$with_string_hacks" = "xyes"; then
3313 cat >>confdefs.h <<\EOF
3314 #define USE_STRING_HACKS 1
3317 { echo "$as_me:3317: WARNING: enabling string-hacks to work around bogus compiler/loader warnings" >&5
3318 echo "$as_me: WARNING: enabling string-hacks to work around bogus compiler/loader warnings" >&2;}
3319 echo "$as_me:3319: checking for strlcat" >&5
3320 echo $ECHO_N "checking for strlcat... $ECHO_C" >&6
3321 if test "${ac_cv_func_strlcat+set}" = set; then
3322 echo $ECHO_N "(cached) $ECHO_C" >&6
3324 cat >conftest.$ac_ext <<_ACEOF
3325 #line 3325 "configure"
3326 #include "confdefs.h"
3327 #define strlcat autoconf_temporary
3328 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
3335 /* We use char because int might match the return type of a gcc2
3336 builtin and then its argument prototype would still apply. */
3337 char strlcat (void);
3343 /* The GNU C library defines stubs for functions which it implements
3344 to always fail with ENOSYS. Some functions are actually named
3345 something starting with __ and the normal name is an alias. */
3346 #if defined (__stub_strlcat) || defined (__stub___strlcat)
3347 #error found stub for strlcat
3355 rm -f conftest.$ac_objext conftest$ac_exeext
3356 if { (eval echo "$as_me:3356: \"$ac_link\"") >&5
3357 (eval $ac_link) 2>&5
3359 echo "$as_me:3359: \$? = $ac_status" >&5
3360 (exit $ac_status); } &&
3361 { ac_try='test -s conftest$ac_exeext'
3362 { (eval echo "$as_me:3362: \"$ac_try\"") >&5
3365 echo "$as_me:3365: \$? = $ac_status" >&5
3366 (exit $ac_status); }; }; then
3367 ac_cv_func_strlcat=yes
3369 echo "$as_me: failed program was:" >&5
3370 cat conftest.$ac_ext >&5
3371 ac_cv_func_strlcat=no
3373 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
3375 echo "$as_me:3375: result: $ac_cv_func_strlcat" >&5
3376 echo "${ECHO_T}$ac_cv_func_strlcat" >&6
3377 if test $ac_cv_func_strlcat = yes; then
3379 cat >>confdefs.h <<\EOF
3380 #define HAVE_STRLCAT 1
3385 echo "$as_me:3385: checking for strlcat in -lbsd" >&5
3386 echo $ECHO_N "checking for strlcat in -lbsd... $ECHO_C" >&6
3387 if test "${ac_cv_lib_bsd_strlcat+set}" = set; then
3388 echo $ECHO_N "(cached) $ECHO_C" >&6
3390 ac_check_lib_save_LIBS=$LIBS
3392 cat >conftest.$ac_ext <<_ACEOF
3393 #line 3393 "configure"
3394 #include "confdefs.h"
3396 /* Override any gcc2 internal prototype to avoid an error. */
3400 /* We use char because int might match the return type of a gcc2
3401 builtin and then its argument prototype would still apply. */
3411 rm -f conftest.$ac_objext conftest$ac_exeext
3412 if { (eval echo "$as_me:3412: \"$ac_link\"") >&5
3413 (eval $ac_link) 2>&5
3415 echo "$as_me:3415: \$? = $ac_status" >&5
3416 (exit $ac_status); } &&
3417 { ac_try='test -s conftest$ac_exeext'
3418 { (eval echo "$as_me:3418: \"$ac_try\"") >&5
3421 echo "$as_me:3421: \$? = $ac_status" >&5
3422 (exit $ac_status); }; }; then
3423 ac_cv_lib_bsd_strlcat=yes
3425 echo "$as_me: failed program was:" >&5
3426 cat conftest.$ac_ext >&5
3427 ac_cv_lib_bsd_strlcat=no
3429 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
3430 LIBS=$ac_check_lib_save_LIBS
3432 echo "$as_me:3432: result: $ac_cv_lib_bsd_strlcat" >&5
3433 echo "${ECHO_T}$ac_cv_lib_bsd_strlcat" >&6
3434 if test $ac_cv_lib_bsd_strlcat = yes; then
3439 for cf_add_1lib in -lbsd; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
3441 for cf_add_1lib in $cf_add_0lib; do
3442 for cf_add_2lib in $cf_add_libs; do
3443 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
3448 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
3452 for ac_header in bsd/string.h
3454 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
3455 echo "$as_me:3455: checking for $ac_header" >&5
3456 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3457 if eval "test \"\${$as_ac_Header+set}\" = set"; then
3458 echo $ECHO_N "(cached) $ECHO_C" >&6
3460 cat >conftest.$ac_ext <<_ACEOF
3461 #line 3461 "configure"
3462 #include "confdefs.h"
3463 #include <$ac_header>
3465 if { (eval echo "$as_me:3465: \"$ac_cpp conftest.$ac_ext\"") >&5
3466 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3468 egrep -v '^ *\+' conftest.er1 >conftest.err
3470 cat conftest.err >&5
3471 echo "$as_me:3471: \$? = $ac_status" >&5
3472 (exit $ac_status); } >/dev/null; then
3473 if test -s conftest.err; then
3474 ac_cpp_err=$ac_c_preproc_warn_flag
3481 if test -z "$ac_cpp_err"; then
3482 eval "$as_ac_Header=yes"
3484 echo "$as_me: failed program was:" >&5
3485 cat conftest.$ac_ext >&5
3486 eval "$as_ac_Header=no"
3488 rm -f conftest.err conftest.$ac_ext
3490 echo "$as_me:3490: result: `eval echo '${'$as_ac_Header'}'`" >&5
3491 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
3492 if test `eval echo '${'$as_ac_Header'}'` = yes; then
3493 cat >>confdefs.h <<EOF
3494 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
3500 cat >>confdefs.h <<\EOF
3501 #define HAVE_STRLCAT 1
3508 for ac_func in strlcpy snprintf
3510 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
3511 echo "$as_me:3511: checking for $ac_func" >&5
3512 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
3513 if eval "test \"\${$as_ac_var+set}\" = set"; then
3514 echo $ECHO_N "(cached) $ECHO_C" >&6
3516 cat >conftest.$ac_ext <<_ACEOF
3517 #line 3517 "configure"
3518 #include "confdefs.h"
3519 #define $ac_func autoconf_temporary
3520 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
3527 /* We use char because int might match the return type of a gcc2
3528 builtin and then its argument prototype would still apply. */
3529 char $ac_func (void);
3535 /* The GNU C library defines stubs for functions which it implements
3536 to always fail with ENOSYS. Some functions are actually named
3537 something starting with __ and the normal name is an alias. */
3538 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3539 #error found stub for $ac_func
3547 rm -f conftest.$ac_objext conftest$ac_exeext
3548 if { (eval echo "$as_me:3548: \"$ac_link\"") >&5
3549 (eval $ac_link) 2>&5
3551 echo "$as_me:3551: \$? = $ac_status" >&5
3552 (exit $ac_status); } &&
3553 { ac_try='test -s conftest$ac_exeext'
3554 { (eval echo "$as_me:3554: \"$ac_try\"") >&5
3557 echo "$as_me:3557: \$? = $ac_status" >&5
3558 (exit $ac_status); }; }; then
3559 eval "$as_ac_var=yes"
3561 echo "$as_me: failed program was:" >&5
3562 cat conftest.$ac_ext >&5
3563 eval "$as_ac_var=no"
3565 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
3567 echo "$as_me:3567: result: `eval echo '${'$as_ac_var'}'`" >&5
3568 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
3569 if test `eval echo '${'$as_ac_var'}'` = yes; then
3570 cat >>confdefs.h <<EOF
3571 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
3579 echo "$as_me:3579: checking if the POSIX test-macros are already defined" >&5
3580 echo $ECHO_N "checking if the POSIX test-macros are already defined... $ECHO_C" >&6
3581 if test "${cf_cv_posix_visible+set}" = set; then
3582 echo $ECHO_N "(cached) $ECHO_C" >&6
3585 cat >conftest.$ac_ext <<_ACEOF
3586 #line 3586 "configure"
3587 #include "confdefs.h"
3593 #if defined(__POSIX_VISIBLE) && ((__POSIX_VISIBLE - 0L) > 0) \
3594 && defined(__XSI_VISIBLE) && ((__XSI_VISIBLE - 0L) > 0) \
3595 && defined(__BSD_VISIBLE) && ((__BSD_VISIBLE - 0L) > 0) \
3596 && defined(__ISO_C_VISIBLE) && ((__ISO_C_VISIBLE - 0L) > 0)
3597 #error conflicting symbols found
3604 rm -f conftest.$ac_objext
3605 if { (eval echo "$as_me:3605: \"$ac_compile\"") >&5
3606 (eval $ac_compile) 2>&5
3608 echo "$as_me:3608: \$? = $ac_status" >&5
3609 (exit $ac_status); } &&
3610 { ac_try='test -s conftest.$ac_objext'
3611 { (eval echo "$as_me:3611: \"$ac_try\"") >&5
3614 echo "$as_me:3614: \$? = $ac_status" >&5
3615 (exit $ac_status); }; }; then
3616 cf_cv_posix_visible=no
3618 echo "$as_me: failed program was:" >&5
3619 cat conftest.$ac_ext >&5
3620 cf_cv_posix_visible=yes
3622 rm -f conftest.$ac_objext conftest.$ac_ext
3625 echo "$as_me:3625: result: $cf_cv_posix_visible" >&5
3626 echo "${ECHO_T}$cf_cv_posix_visible" >&6
3628 if test "$cf_cv_posix_visible" = no; then
3631 cf_POSIX_C_SOURCE=199506L
3636 cf_xopen_source="-D_ALL_SOURCE"
3642 cf_xopen_source="-D_APPLE_C_SOURCE"
3645 cf_xopen_source="-D_DARWIN_C_SOURCE"
3648 (freebsd*|dragonfly*|midnightbsd*)
3649 # 5.x headers associate
3650 # _XOPEN_SOURCE=600 with _POSIX_C_SOURCE=200112L
3651 # _XOPEN_SOURCE=500 with _POSIX_C_SOURCE=199506L
3652 cf_POSIX_C_SOURCE=200112L
3654 cf_xopen_source="-D_BSD_TYPES -D__BSD_VISIBLE -D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
3657 cf_xopen_source="-D_HPUX_SOURCE -D_XOPEN_SOURCE=500"
3660 cf_xopen_source="-D_HPUX_SOURCE"
3663 cf_xopen_source="-D_SGI_SOURCE"
3666 (linux*|uclinux*|gnu*|mint*|k*bsd*-gnu|cygwin)
3668 cf_gnu_xopen_source=$cf_XOPEN_SOURCE
3670 echo "$as_me:3670: checking if this is the GNU C library" >&5
3671 echo $ECHO_N "checking if this is the GNU C library... $ECHO_C" >&6
3672 if test "${cf_cv_gnu_library+set}" = set; then
3673 echo $ECHO_N "(cached) $ECHO_C" >&6
3676 cat >conftest.$ac_ext <<_ACEOF
3677 #line 3677 "configure"
3678 #include "confdefs.h"
3679 #include <sys/types.h>
3684 #if __GLIBC__ > 0 && __GLIBC_MINOR__ >= 0
3686 #elif __NEWLIB__ > 0 && __NEWLIB_MINOR__ >= 0
3689 # error not GNU C library
3695 rm -f conftest.$ac_objext
3696 if { (eval echo "$as_me:3696: \"$ac_compile\"") >&5
3697 (eval $ac_compile) 2>&5
3699 echo "$as_me:3699: \$? = $ac_status" >&5
3700 (exit $ac_status); } &&
3701 { ac_try='test -s conftest.$ac_objext'
3702 { (eval echo "$as_me:3702: \"$ac_try\"") >&5
3705 echo "$as_me:3705: \$? = $ac_status" >&5
3706 (exit $ac_status); }; }; then
3707 cf_cv_gnu_library=yes
3709 echo "$as_me: failed program was:" >&5
3710 cat conftest.$ac_ext >&5
3711 cf_cv_gnu_library=no
3713 rm -f conftest.$ac_objext conftest.$ac_ext
3716 echo "$as_me:3716: result: $cf_cv_gnu_library" >&5
3717 echo "${ECHO_T}$cf_cv_gnu_library" >&6
3719 if test x$cf_cv_gnu_library = xyes; then
3721 # With glibc 2.19 (13 years after this check was begun), _DEFAULT_SOURCE
3722 # was changed to help a little. newlib incorporated the change about 4
3724 echo "$as_me:3724: checking if _DEFAULT_SOURCE can be used as a basis" >&5
3725 echo $ECHO_N "checking if _DEFAULT_SOURCE can be used as a basis... $ECHO_C" >&6
3726 if test "${cf_cv_gnu_library_219+set}" = set; then
3727 echo $ECHO_N "(cached) $ECHO_C" >&6
3732 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
3733 CPPFLAGS="${CPPFLAGS}-D_DEFAULT_SOURCE"
3735 cat >conftest.$ac_ext <<_ACEOF
3736 #line 3736 "configure"
3737 #include "confdefs.h"
3738 #include <sys/types.h>
3743 #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 19) || (__GLIBC__ > 2)
3745 #elif (__NEWLIB__ == 2 && __NEWLIB_MINOR__ >= 4) || (__GLIBC__ > 3)
3748 # error GNU C library __GLIBC__.__GLIBC_MINOR__ is too old
3754 rm -f conftest.$ac_objext
3755 if { (eval echo "$as_me:3755: \"$ac_compile\"") >&5
3756 (eval $ac_compile) 2>&5
3758 echo "$as_me:3758: \$? = $ac_status" >&5
3759 (exit $ac_status); } &&
3760 { ac_try='test -s conftest.$ac_objext'
3761 { (eval echo "$as_me:3761: \"$ac_try\"") >&5
3764 echo "$as_me:3764: \$? = $ac_status" >&5
3765 (exit $ac_status); }; }; then
3766 cf_cv_gnu_library_219=yes
3768 echo "$as_me: failed program was:" >&5
3769 cat conftest.$ac_ext >&5
3770 cf_cv_gnu_library_219=no
3772 rm -f conftest.$ac_objext conftest.$ac_ext
3776 echo "$as_me:3776: result: $cf_cv_gnu_library_219" >&5
3777 echo "${ECHO_T}$cf_cv_gnu_library_219" >&6
3779 if test "x$cf_cv_gnu_library_219" = xyes; then
3781 echo "$as_me:3781: checking if _XOPEN_SOURCE=$cf_gnu_xopen_source works with _DEFAULT_SOURCE" >&5
3782 echo $ECHO_N "checking if _XOPEN_SOURCE=$cf_gnu_xopen_source works with _DEFAULT_SOURCE... $ECHO_C" >&6
3783 if test "${cf_cv_gnu_dftsrc_219+set}" = set; then
3784 echo $ECHO_N "(cached) $ECHO_C" >&6
3790 cf_new_extra_cppflags=
3792 for cf_add_cflags in -D_DEFAULT_SOURCE -D_XOPEN_SOURCE=$cf_gnu_xopen_source
3794 case $cf_fix_cppflags in
3796 case $cf_add_cflags in
3797 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
3798 case $cf_add_cflags in
3800 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3802 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
3803 && test -z "${cf_tst_cflags}" \
3804 && cf_fix_cppflags=yes
3806 if test $cf_fix_cppflags = yes ; then
3808 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3809 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3812 elif test "${cf_tst_cflags}" = "\"'" ; then
3814 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3815 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3825 case $cf_add_cflags in
3827 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3829 CPPFLAGS=`echo "$CPPFLAGS" | \
3830 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3831 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3836 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
3837 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
3844 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
3845 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
3852 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3853 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3855 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
3857 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
3858 && test -z "${cf_tst_cflags}" \
3859 && cf_fix_cppflags=no
3864 if test -n "$cf_new_cflags" ; then
3866 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
3867 CFLAGS="${CFLAGS}$cf_new_cflags"
3871 if test -n "$cf_new_cppflags" ; then
3873 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
3874 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
3878 if test -n "$cf_new_extra_cppflags" ; then
3880 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
3881 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
3885 cat >conftest.$ac_ext <<_ACEOF
3886 #line 3886 "configure"
3887 #include "confdefs.h"
3890 #include <sys/types.h>
3896 #if (_XOPEN_SOURCE >= $cf_gnu_xopen_source) && (MB_LEN_MAX > 1)
3899 # error GNU C library is too old
3905 rm -f conftest.$ac_objext
3906 if { (eval echo "$as_me:3906: \"$ac_compile\"") >&5
3907 (eval $ac_compile) 2>&5
3909 echo "$as_me:3909: \$? = $ac_status" >&5
3910 (exit $ac_status); } &&
3911 { ac_try='test -s conftest.$ac_objext'
3912 { (eval echo "$as_me:3912: \"$ac_try\"") >&5
3915 echo "$as_me:3915: \$? = $ac_status" >&5
3916 (exit $ac_status); }; }; then
3917 cf_cv_gnu_dftsrc_219=yes
3919 echo "$as_me: failed program was:" >&5
3920 cat conftest.$ac_ext >&5
3921 cf_cv_gnu_dftsrc_219=no
3923 rm -f conftest.$ac_objext conftest.$ac_ext
3926 echo "$as_me:3926: result: $cf_cv_gnu_dftsrc_219" >&5
3927 echo "${ECHO_T}$cf_cv_gnu_dftsrc_219" >&6
3928 test "x$cf_cv_gnu_dftsrc_219" = "xyes" || CPPFLAGS="$cf_save"
3930 cf_cv_gnu_dftsrc_219=maybe
3933 if test "x$cf_cv_gnu_dftsrc_219" != xyes; then
3935 echo "$as_me:3935: checking if we must define _GNU_SOURCE" >&5
3936 echo $ECHO_N "checking if we must define _GNU_SOURCE... $ECHO_C" >&6
3937 if test "${cf_cv_gnu_source+set}" = set; then
3938 echo $ECHO_N "(cached) $ECHO_C" >&6
3941 cat >conftest.$ac_ext <<_ACEOF
3942 #line 3942 "configure"
3943 #include "confdefs.h"
3944 #include <sys/types.h>
3949 #ifndef _XOPEN_SOURCE
3950 #error expected _XOPEN_SOURCE to be defined
3956 rm -f conftest.$ac_objext
3957 if { (eval echo "$as_me:3957: \"$ac_compile\"") >&5
3958 (eval $ac_compile) 2>&5
3960 echo "$as_me:3960: \$? = $ac_status" >&5
3961 (exit $ac_status); } &&
3962 { ac_try='test -s conftest.$ac_objext'
3963 { (eval echo "$as_me:3963: \"$ac_try\"") >&5
3966 echo "$as_me:3966: \$? = $ac_status" >&5
3967 (exit $ac_status); }; }; then
3970 echo "$as_me: failed program was:" >&5
3971 cat conftest.$ac_ext >&5
3977 cf_new_extra_cppflags=
3979 for cf_add_cflags in -D_GNU_SOURCE
3981 case $cf_fix_cppflags in
3983 case $cf_add_cflags in
3984 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
3985 case $cf_add_cflags in
3987 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3989 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
3990 && test -z "${cf_tst_cflags}" \
3991 && cf_fix_cppflags=yes
3993 if test $cf_fix_cppflags = yes ; then
3995 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3996 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3999 elif test "${cf_tst_cflags}" = "\"'" ; then
4001 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4002 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4012 case $cf_add_cflags in
4014 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4016 CPPFLAGS=`echo "$CPPFLAGS" | \
4017 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4018 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4023 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4024 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4031 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4032 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4039 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4040 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4042 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
4044 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4045 && test -z "${cf_tst_cflags}" \
4046 && cf_fix_cppflags=no
4051 if test -n "$cf_new_cflags" ; then
4053 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4054 CFLAGS="${CFLAGS}$cf_new_cflags"
4058 if test -n "$cf_new_cppflags" ; then
4060 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4061 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4065 if test -n "$cf_new_extra_cppflags" ; then
4067 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4068 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4072 cat >conftest.$ac_ext <<_ACEOF
4073 #line 4073 "configure"
4074 #include "confdefs.h"
4075 #include <sys/types.h>
4080 #ifdef _XOPEN_SOURCE
4081 #error expected _XOPEN_SOURCE to be undefined
4087 rm -f conftest.$ac_objext
4088 if { (eval echo "$as_me:4088: \"$ac_compile\"") >&5
4089 (eval $ac_compile) 2>&5
4091 echo "$as_me:4091: \$? = $ac_status" >&5
4092 (exit $ac_status); } &&
4093 { ac_try='test -s conftest.$ac_objext'
4094 { (eval echo "$as_me:4094: \"$ac_try\"") >&5
4097 echo "$as_me:4097: \$? = $ac_status" >&5
4098 (exit $ac_status); }; }; then
4101 echo "$as_me: failed program was:" >&5
4102 cat conftest.$ac_ext >&5
4103 cf_cv_gnu_source=yes
4105 rm -f conftest.$ac_objext conftest.$ac_ext
4109 rm -f conftest.$ac_objext conftest.$ac_ext
4112 echo "$as_me:4112: result: $cf_cv_gnu_source" >&5
4113 echo "${ECHO_T}$cf_cv_gnu_source" >&6
4115 if test "$cf_cv_gnu_source" = yes
4117 echo "$as_me:4117: checking if we should also define _DEFAULT_SOURCE" >&5
4118 echo $ECHO_N "checking if we should also define _DEFAULT_SOURCE... $ECHO_C" >&6
4119 if test "${cf_cv_default_source+set}" = set; then
4120 echo $ECHO_N "(cached) $ECHO_C" >&6
4123 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4124 CPPFLAGS="${CPPFLAGS}-D_GNU_SOURCE"
4126 cat >conftest.$ac_ext <<_ACEOF
4127 #line 4127 "configure"
4128 #include "confdefs.h"
4129 #include <sys/types.h>
4134 #ifdef _DEFAULT_SOURCE
4135 #error expected _DEFAULT_SOURCE to be undefined
4141 rm -f conftest.$ac_objext
4142 if { (eval echo "$as_me:4142: \"$ac_compile\"") >&5
4143 (eval $ac_compile) 2>&5
4145 echo "$as_me:4145: \$? = $ac_status" >&5
4146 (exit $ac_status); } &&
4147 { ac_try='test -s conftest.$ac_objext'
4148 { (eval echo "$as_me:4148: \"$ac_try\"") >&5
4151 echo "$as_me:4151: \$? = $ac_status" >&5
4152 (exit $ac_status); }; }; then
4153 cf_cv_default_source=no
4155 echo "$as_me: failed program was:" >&5
4156 cat conftest.$ac_ext >&5
4157 cf_cv_default_source=yes
4159 rm -f conftest.$ac_objext conftest.$ac_ext
4162 echo "$as_me:4162: result: $cf_cv_default_source" >&5
4163 echo "${ECHO_T}$cf_cv_default_source" >&6
4164 if test "$cf_cv_default_source" = yes
4167 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4168 CPPFLAGS="${CPPFLAGS}-D_DEFAULT_SOURCE"
4178 cf_xopen_source="-D_NETBSD_SOURCE" # POSIX.1-2001 features are ifdef'd with this...
4181 # setting _XOPEN_SOURCE or _POSIX_SOURCE breaks <sys/select.h> and other headers which use u_int / u_short types
4184 if test "$cf_cv_posix_visible" = no; then
4186 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
4188 cf_save_CFLAGS="$CFLAGS"
4189 cf_save_CPPFLAGS="$CPPFLAGS"
4191 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
4192 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
4193 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
4195 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
4196 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
4197 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
4199 echo "$as_me:4199: checking if we should define _POSIX_C_SOURCE" >&5
4200 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
4201 if test "${cf_cv_posix_c_source+set}" = set; then
4202 echo $ECHO_N "(cached) $ECHO_C" >&6
4205 echo "${as_me:-configure}:4205: testing if the symbol is already defined go no further ..." 1>&5
4207 cat >conftest.$ac_ext <<_ACEOF
4208 #line 4208 "configure"
4209 #include "confdefs.h"
4210 #include <sys/types.h>
4215 #ifndef _POSIX_C_SOURCE
4222 rm -f conftest.$ac_objext
4223 if { (eval echo "$as_me:4223: \"$ac_compile\"") >&5
4224 (eval $ac_compile) 2>&5
4226 echo "$as_me:4226: \$? = $ac_status" >&5
4227 (exit $ac_status); } &&
4228 { ac_try='test -s conftest.$ac_objext'
4229 { (eval echo "$as_me:4229: \"$ac_try\"") >&5
4232 echo "$as_me:4232: \$? = $ac_status" >&5
4233 (exit $ac_status); }; }; then
4234 cf_cv_posix_c_source=no
4236 echo "$as_me: failed program was:" >&5
4237 cat conftest.$ac_ext >&5
4238 cf_want_posix_source=no
4239 case .$cf_POSIX_C_SOURCE in
4241 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
4244 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
4245 cf_want_posix_source=yes
4248 cf_want_posix_source=yes
4251 if test "$cf_want_posix_source" = yes ; then
4252 cat >conftest.$ac_ext <<_ACEOF
4253 #line 4253 "configure"
4254 #include "confdefs.h"
4255 #include <sys/types.h>
4260 #ifdef _POSIX_SOURCE
4267 rm -f conftest.$ac_objext
4268 if { (eval echo "$as_me:4268: \"$ac_compile\"") >&5
4269 (eval $ac_compile) 2>&5
4271 echo "$as_me:4271: \$? = $ac_status" >&5
4272 (exit $ac_status); } &&
4273 { ac_try='test -s conftest.$ac_objext'
4274 { (eval echo "$as_me:4274: \"$ac_try\"") >&5
4277 echo "$as_me:4277: \$? = $ac_status" >&5
4278 (exit $ac_status); }; }; then
4281 echo "$as_me: failed program was:" >&5
4282 cat conftest.$ac_ext >&5
4283 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
4285 rm -f conftest.$ac_objext conftest.$ac_ext
4288 echo "${as_me:-configure}:4288: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
4290 CFLAGS="$cf_trim_CFLAGS"
4291 CPPFLAGS="$cf_trim_CPPFLAGS"
4293 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4294 CPPFLAGS="${CPPFLAGS}$cf_cv_posix_c_source"
4296 echo "${as_me:-configure}:4296: testing if the second compile does not leave our definition intact error ..." 1>&5
4298 cat >conftest.$ac_ext <<_ACEOF
4299 #line 4299 "configure"
4300 #include "confdefs.h"
4301 #include <sys/types.h>
4306 #ifndef _POSIX_C_SOURCE
4313 rm -f conftest.$ac_objext
4314 if { (eval echo "$as_me:4314: \"$ac_compile\"") >&5
4315 (eval $ac_compile) 2>&5
4317 echo "$as_me:4317: \$? = $ac_status" >&5
4318 (exit $ac_status); } &&
4319 { ac_try='test -s conftest.$ac_objext'
4320 { (eval echo "$as_me:4320: \"$ac_try\"") >&5
4323 echo "$as_me:4323: \$? = $ac_status" >&5
4324 (exit $ac_status); }; }; then
4327 echo "$as_me: failed program was:" >&5
4328 cat conftest.$ac_ext >&5
4329 cf_cv_posix_c_source=no
4331 rm -f conftest.$ac_objext conftest.$ac_ext
4332 CFLAGS="$cf_save_CFLAGS"
4333 CPPFLAGS="$cf_save_CPPFLAGS"
4336 rm -f conftest.$ac_objext conftest.$ac_ext
4339 echo "$as_me:4339: result: $cf_cv_posix_c_source" >&5
4340 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
4342 if test "$cf_cv_posix_c_source" != no ; then
4343 CFLAGS="$cf_trim_CFLAGS"
4344 CPPFLAGS="$cf_trim_CPPFLAGS"
4349 cf_new_extra_cppflags=
4351 for cf_add_cflags in $cf_cv_posix_c_source
4353 case $cf_fix_cppflags in
4355 case $cf_add_cflags in
4356 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4357 case $cf_add_cflags in
4359 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4361 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4362 && test -z "${cf_tst_cflags}" \
4363 && cf_fix_cppflags=yes
4365 if test $cf_fix_cppflags = yes ; then
4367 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4368 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4371 elif test "${cf_tst_cflags}" = "\"'" ; then
4373 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4374 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4384 case $cf_add_cflags in
4386 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4388 CPPFLAGS=`echo "$CPPFLAGS" | \
4389 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4390 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4395 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4396 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4403 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4404 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4411 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4412 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4414 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
4416 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4417 && test -z "${cf_tst_cflags}" \
4418 && cf_fix_cppflags=no
4423 if test -n "$cf_new_cflags" ; then
4425 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4426 CFLAGS="${CFLAGS}$cf_new_cflags"
4430 if test -n "$cf_new_cppflags" ; then
4432 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4433 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4437 if test -n "$cf_new_extra_cppflags" ; then
4439 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4440 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4446 fi # cf_cv_posix_visible
4450 cf_xopen_source="-D_NETBSD_SOURCE" # setting _XOPEN_SOURCE breaks IPv6 for lynx on NetBSD 1.6, breaks xterm, is not needed for ncursesw
4453 # setting _XOPEN_SOURCE lower than 500 breaks g++ compile with wchar.h, needed for ncursesw
4454 cf_xopen_source="-D_BSD_SOURCE"
4458 # setting _XOPEN_SOURCE breaks xterm on OpenBSD 2.8, is not needed for ncursesw
4461 cf_xopen_source="-D_OSF_SOURCE"
4464 cf_xopen_source="-D_QNX_SOURCE"
4467 # setting _XOPEN_SOURCE breaks Lynx on SCO Unix / OpenServer
4470 cf_xopen_source="-D__EXTENSIONS__"
4471 cf_cv_xopen_source=broken
4473 (sysv4.2uw2.*) # Novell/SCO UnixWare 2.x (tested on 2.1.2)
4479 echo "$as_me:4479: checking if we should define _XOPEN_SOURCE" >&5
4480 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
4481 if test "${cf_cv_xopen_source+set}" = set; then
4482 echo $ECHO_N "(cached) $ECHO_C" >&6
4485 cat >conftest.$ac_ext <<_ACEOF
4486 #line 4486 "configure"
4487 #include "confdefs.h"
4491 #include <sys/types.h>
4497 #ifndef _XOPEN_SOURCE
4504 rm -f conftest.$ac_objext
4505 if { (eval echo "$as_me:4505: \"$ac_compile\"") >&5
4506 (eval $ac_compile) 2>&5
4508 echo "$as_me:4508: \$? = $ac_status" >&5
4509 (exit $ac_status); } &&
4510 { ac_try='test -s conftest.$ac_objext'
4511 { (eval echo "$as_me:4511: \"$ac_try\"") >&5
4514 echo "$as_me:4514: \$? = $ac_status" >&5
4515 (exit $ac_status); }; }; then
4516 cf_cv_xopen_source=no
4518 echo "$as_me: failed program was:" >&5
4519 cat conftest.$ac_ext >&5
4522 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4523 CPPFLAGS="${CPPFLAGS}-D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
4525 cat >conftest.$ac_ext <<_ACEOF
4526 #line 4526 "configure"
4527 #include "confdefs.h"
4531 #include <sys/types.h>
4537 #ifdef _XOPEN_SOURCE
4544 rm -f conftest.$ac_objext
4545 if { (eval echo "$as_me:4545: \"$ac_compile\"") >&5
4546 (eval $ac_compile) 2>&5
4548 echo "$as_me:4548: \$? = $ac_status" >&5
4549 (exit $ac_status); } &&
4550 { ac_try='test -s conftest.$ac_objext'
4551 { (eval echo "$as_me:4551: \"$ac_try\"") >&5
4554 echo "$as_me:4554: \$? = $ac_status" >&5
4555 (exit $ac_status); }; }; then
4556 cf_cv_xopen_source=no
4558 echo "$as_me: failed program was:" >&5
4559 cat conftest.$ac_ext >&5
4560 cf_cv_xopen_source=$cf_XOPEN_SOURCE
4562 rm -f conftest.$ac_objext conftest.$ac_ext
4566 rm -f conftest.$ac_objext conftest.$ac_ext
4569 echo "$as_me:4569: result: $cf_cv_xopen_source" >&5
4570 echo "${ECHO_T}$cf_cv_xopen_source" >&6
4572 if test "$cf_cv_xopen_source" != no ; then
4574 CFLAGS=`echo "$CFLAGS" | \
4575 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
4576 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
4578 CPPFLAGS=`echo "$CPPFLAGS" | \
4579 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
4580 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
4582 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
4587 cf_new_extra_cppflags=
4589 for cf_add_cflags in $cf_temp_xopen_source
4591 case $cf_fix_cppflags in
4593 case $cf_add_cflags in
4594 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4595 case $cf_add_cflags in
4597 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4599 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4600 && test -z "${cf_tst_cflags}" \
4601 && cf_fix_cppflags=yes
4603 if test $cf_fix_cppflags = yes ; then
4605 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4606 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4609 elif test "${cf_tst_cflags}" = "\"'" ; then
4611 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4612 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4622 case $cf_add_cflags in
4624 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4626 CPPFLAGS=`echo "$CPPFLAGS" | \
4627 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4628 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4633 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4634 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4641 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4642 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4649 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4650 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4652 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
4654 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4655 && test -z "${cf_tst_cflags}" \
4656 && cf_fix_cppflags=no
4661 if test -n "$cf_new_cflags" ; then
4663 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4664 CFLAGS="${CFLAGS}$cf_new_cflags"
4668 if test -n "$cf_new_cppflags" ; then
4670 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4671 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4675 if test -n "$cf_new_extra_cppflags" ; then
4677 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4678 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4684 if test "$cf_cv_posix_visible" = no; then
4686 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
4688 cf_save_CFLAGS="$CFLAGS"
4689 cf_save_CPPFLAGS="$CPPFLAGS"
4691 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
4692 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
4693 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
4695 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
4696 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
4697 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
4699 echo "$as_me:4699: checking if we should define _POSIX_C_SOURCE" >&5
4700 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
4701 if test "${cf_cv_posix_c_source+set}" = set; then
4702 echo $ECHO_N "(cached) $ECHO_C" >&6
4705 echo "${as_me:-configure}:4705: testing if the symbol is already defined go no further ..." 1>&5
4707 cat >conftest.$ac_ext <<_ACEOF
4708 #line 4708 "configure"
4709 #include "confdefs.h"
4710 #include <sys/types.h>
4715 #ifndef _POSIX_C_SOURCE
4722 rm -f conftest.$ac_objext
4723 if { (eval echo "$as_me:4723: \"$ac_compile\"") >&5
4724 (eval $ac_compile) 2>&5
4726 echo "$as_me:4726: \$? = $ac_status" >&5
4727 (exit $ac_status); } &&
4728 { ac_try='test -s conftest.$ac_objext'
4729 { (eval echo "$as_me:4729: \"$ac_try\"") >&5
4732 echo "$as_me:4732: \$? = $ac_status" >&5
4733 (exit $ac_status); }; }; then
4734 cf_cv_posix_c_source=no
4736 echo "$as_me: failed program was:" >&5
4737 cat conftest.$ac_ext >&5
4738 cf_want_posix_source=no
4739 case .$cf_POSIX_C_SOURCE in
4741 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
4744 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
4745 cf_want_posix_source=yes
4748 cf_want_posix_source=yes
4751 if test "$cf_want_posix_source" = yes ; then
4752 cat >conftest.$ac_ext <<_ACEOF
4753 #line 4753 "configure"
4754 #include "confdefs.h"
4755 #include <sys/types.h>
4760 #ifdef _POSIX_SOURCE
4767 rm -f conftest.$ac_objext
4768 if { (eval echo "$as_me:4768: \"$ac_compile\"") >&5
4769 (eval $ac_compile) 2>&5
4771 echo "$as_me:4771: \$? = $ac_status" >&5
4772 (exit $ac_status); } &&
4773 { ac_try='test -s conftest.$ac_objext'
4774 { (eval echo "$as_me:4774: \"$ac_try\"") >&5
4777 echo "$as_me:4777: \$? = $ac_status" >&5
4778 (exit $ac_status); }; }; then
4781 echo "$as_me: failed program was:" >&5
4782 cat conftest.$ac_ext >&5
4783 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
4785 rm -f conftest.$ac_objext conftest.$ac_ext
4788 echo "${as_me:-configure}:4788: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
4790 CFLAGS="$cf_trim_CFLAGS"
4791 CPPFLAGS="$cf_trim_CPPFLAGS"
4793 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4794 CPPFLAGS="${CPPFLAGS}$cf_cv_posix_c_source"
4796 echo "${as_me:-configure}:4796: testing if the second compile does not leave our definition intact error ..." 1>&5
4798 cat >conftest.$ac_ext <<_ACEOF
4799 #line 4799 "configure"
4800 #include "confdefs.h"
4801 #include <sys/types.h>
4806 #ifndef _POSIX_C_SOURCE
4813 rm -f conftest.$ac_objext
4814 if { (eval echo "$as_me:4814: \"$ac_compile\"") >&5
4815 (eval $ac_compile) 2>&5
4817 echo "$as_me:4817: \$? = $ac_status" >&5
4818 (exit $ac_status); } &&
4819 { ac_try='test -s conftest.$ac_objext'
4820 { (eval echo "$as_me:4820: \"$ac_try\"") >&5
4823 echo "$as_me:4823: \$? = $ac_status" >&5
4824 (exit $ac_status); }; }; then
4827 echo "$as_me: failed program was:" >&5
4828 cat conftest.$ac_ext >&5
4829 cf_cv_posix_c_source=no
4831 rm -f conftest.$ac_objext conftest.$ac_ext
4832 CFLAGS="$cf_save_CFLAGS"
4833 CPPFLAGS="$cf_save_CPPFLAGS"
4836 rm -f conftest.$ac_objext conftest.$ac_ext
4839 echo "$as_me:4839: result: $cf_cv_posix_c_source" >&5
4840 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
4842 if test "$cf_cv_posix_c_source" != no ; then
4843 CFLAGS="$cf_trim_CFLAGS"
4844 CPPFLAGS="$cf_trim_CPPFLAGS"
4849 cf_new_extra_cppflags=
4851 for cf_add_cflags in $cf_cv_posix_c_source
4853 case $cf_fix_cppflags in
4855 case $cf_add_cflags in
4856 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4857 case $cf_add_cflags in
4859 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4861 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4862 && test -z "${cf_tst_cflags}" \
4863 && cf_fix_cppflags=yes
4865 if test $cf_fix_cppflags = yes ; then
4867 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4868 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4871 elif test "${cf_tst_cflags}" = "\"'" ; then
4873 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4874 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4884 case $cf_add_cflags in
4886 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4888 CPPFLAGS=`echo "$CPPFLAGS" | \
4889 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4890 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4895 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4896 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4903 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4904 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4911 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4912 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4914 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
4916 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4917 && test -z "${cf_tst_cflags}" \
4918 && cf_fix_cppflags=no
4923 if test -n "$cf_new_cflags" ; then
4925 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4926 CFLAGS="${CFLAGS}$cf_new_cflags"
4930 if test -n "$cf_new_cppflags" ; then
4932 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4933 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4937 if test -n "$cf_new_extra_cppflags" ; then
4939 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4940 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4946 fi # cf_cv_posix_visible
4951 if test -n "$cf_xopen_source" ; then
4956 cf_new_extra_cppflags=
4958 for cf_add_cflags in $cf_xopen_source
4960 case $cf_fix_cppflags in
4962 case $cf_add_cflags in
4963 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4964 case $cf_add_cflags in
4966 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4968 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4969 && test -z "${cf_tst_cflags}" \
4970 && cf_fix_cppflags=yes
4972 if test $cf_fix_cppflags = yes ; then
4974 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4975 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4978 elif test "${cf_tst_cflags}" = "\"'" ; then
4980 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4981 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4991 case $cf_add_cflags in
4993 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4995 CPPFLAGS=`echo "$CPPFLAGS" | \
4996 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4997 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
5002 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
5003 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
5010 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
5011 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
5018 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5019 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5021 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
5023 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
5024 && test -z "${cf_tst_cflags}" \
5025 && cf_fix_cppflags=no
5030 if test -n "$cf_new_cflags" ; then
5031 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
5033 echo "${as_me:-configure}:5033: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
5035 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
5036 CFLAGS="${CFLAGS}$cf_new_cflags"
5040 if test -n "$cf_new_cppflags" ; then
5041 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
5043 echo "${as_me:-configure}:5043: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
5045 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5046 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
5050 if test -n "$cf_new_extra_cppflags" ; then
5051 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
5053 echo "${as_me:-configure}:5053: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
5055 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
5056 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
5062 if test -n "$cf_XOPEN_SOURCE" && test -z "$cf_cv_xopen_source" ; then
5063 echo "$as_me:5063: checking if _XOPEN_SOURCE really is set" >&5
5064 echo $ECHO_N "checking if _XOPEN_SOURCE really is set... $ECHO_C" >&6
5065 cat >conftest.$ac_ext <<_ACEOF
5066 #line 5066 "configure"
5067 #include "confdefs.h"
5073 #ifndef _XOPEN_SOURCE
5080 rm -f conftest.$ac_objext
5081 if { (eval echo "$as_me:5081: \"$ac_compile\"") >&5
5082 (eval $ac_compile) 2>&5
5084 echo "$as_me:5084: \$? = $ac_status" >&5
5085 (exit $ac_status); } &&
5086 { ac_try='test -s conftest.$ac_objext'
5087 { (eval echo "$as_me:5087: \"$ac_try\"") >&5
5090 echo "$as_me:5090: \$? = $ac_status" >&5
5091 (exit $ac_status); }; }; then
5092 cf_XOPEN_SOURCE_set=yes
5094 echo "$as_me: failed program was:" >&5
5095 cat conftest.$ac_ext >&5
5096 cf_XOPEN_SOURCE_set=no
5098 rm -f conftest.$ac_objext conftest.$ac_ext
5099 echo "$as_me:5099: result: $cf_XOPEN_SOURCE_set" >&5
5100 echo "${ECHO_T}$cf_XOPEN_SOURCE_set" >&6
5101 if test $cf_XOPEN_SOURCE_set = yes
5103 cat >conftest.$ac_ext <<_ACEOF
5104 #line 5104 "configure"
5105 #include "confdefs.h"
5111 #if (_XOPEN_SOURCE - 0) < $cf_XOPEN_SOURCE
5118 rm -f conftest.$ac_objext
5119 if { (eval echo "$as_me:5119: \"$ac_compile\"") >&5
5120 (eval $ac_compile) 2>&5
5122 echo "$as_me:5122: \$? = $ac_status" >&5
5123 (exit $ac_status); } &&
5124 { ac_try='test -s conftest.$ac_objext'
5125 { (eval echo "$as_me:5125: \"$ac_try\"") >&5
5128 echo "$as_me:5128: \$? = $ac_status" >&5
5129 (exit $ac_status); }; }; then
5130 cf_XOPEN_SOURCE_set_ok=yes
5132 echo "$as_me: failed program was:" >&5
5133 cat conftest.$ac_ext >&5
5134 cf_XOPEN_SOURCE_set_ok=no
5136 rm -f conftest.$ac_objext conftest.$ac_ext
5137 if test $cf_XOPEN_SOURCE_set_ok = no
5139 { echo "$as_me:5139: WARNING: _XOPEN_SOURCE is lower than requested" >&5
5140 echo "$as_me: WARNING: _XOPEN_SOURCE is lower than requested" >&2;}
5144 echo "$as_me:5144: checking if we should define _XOPEN_SOURCE" >&5
5145 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
5146 if test "${cf_cv_xopen_source+set}" = set; then
5147 echo $ECHO_N "(cached) $ECHO_C" >&6
5150 cat >conftest.$ac_ext <<_ACEOF
5151 #line 5151 "configure"
5152 #include "confdefs.h"
5156 #include <sys/types.h>
5162 #ifndef _XOPEN_SOURCE
5169 rm -f conftest.$ac_objext
5170 if { (eval echo "$as_me:5170: \"$ac_compile\"") >&5
5171 (eval $ac_compile) 2>&5
5173 echo "$as_me:5173: \$? = $ac_status" >&5
5174 (exit $ac_status); } &&
5175 { ac_try='test -s conftest.$ac_objext'
5176 { (eval echo "$as_me:5176: \"$ac_try\"") >&5
5179 echo "$as_me:5179: \$? = $ac_status" >&5
5180 (exit $ac_status); }; }; then
5181 cf_cv_xopen_source=no
5183 echo "$as_me: failed program was:" >&5
5184 cat conftest.$ac_ext >&5
5187 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5188 CPPFLAGS="${CPPFLAGS}-D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
5190 cat >conftest.$ac_ext <<_ACEOF
5191 #line 5191 "configure"
5192 #include "confdefs.h"
5196 #include <sys/types.h>
5202 #ifdef _XOPEN_SOURCE
5209 rm -f conftest.$ac_objext
5210 if { (eval echo "$as_me:5210: \"$ac_compile\"") >&5
5211 (eval $ac_compile) 2>&5
5213 echo "$as_me:5213: \$? = $ac_status" >&5
5214 (exit $ac_status); } &&
5215 { ac_try='test -s conftest.$ac_objext'
5216 { (eval echo "$as_me:5216: \"$ac_try\"") >&5
5219 echo "$as_me:5219: \$? = $ac_status" >&5
5220 (exit $ac_status); }; }; then
5221 cf_cv_xopen_source=no
5223 echo "$as_me: failed program was:" >&5
5224 cat conftest.$ac_ext >&5
5225 cf_cv_xopen_source=$cf_XOPEN_SOURCE
5227 rm -f conftest.$ac_objext conftest.$ac_ext
5231 rm -f conftest.$ac_objext conftest.$ac_ext
5234 echo "$as_me:5234: result: $cf_cv_xopen_source" >&5
5235 echo "${ECHO_T}$cf_cv_xopen_source" >&6
5237 if test "$cf_cv_xopen_source" != no ; then
5239 CFLAGS=`echo "$CFLAGS" | \
5240 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
5241 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
5243 CPPFLAGS=`echo "$CPPFLAGS" | \
5244 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
5245 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
5247 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
5252 cf_new_extra_cppflags=
5254 for cf_add_cflags in $cf_temp_xopen_source
5256 case $cf_fix_cppflags in
5258 case $cf_add_cflags in
5259 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
5260 case $cf_add_cflags in
5262 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
5264 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
5265 && test -z "${cf_tst_cflags}" \
5266 && cf_fix_cppflags=yes
5268 if test $cf_fix_cppflags = yes ; then
5270 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5271 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5274 elif test "${cf_tst_cflags}" = "\"'" ; then
5276 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5277 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5287 case $cf_add_cflags in
5289 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
5291 CPPFLAGS=`echo "$CPPFLAGS" | \
5292 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
5293 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
5298 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
5299 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
5306 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
5307 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
5314 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5315 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5317 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
5319 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
5320 && test -z "${cf_tst_cflags}" \
5321 && cf_fix_cppflags=no
5326 if test -n "$cf_new_cflags" ; then
5328 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
5329 CFLAGS="${CFLAGS}$cf_new_cflags"
5333 if test -n "$cf_new_cppflags" ; then
5335 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5336 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
5340 if test -n "$cf_new_extra_cppflags" ; then
5342 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
5343 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
5351 fi # cf_cv_posix_visible
5353 echo "$as_me:5353: checking for signal global datatype" >&5
5354 echo $ECHO_N "checking for signal global datatype... $ECHO_C" >&6
5355 if test "${cf_cv_sig_atomic_t+set}" = set; then
5356 echo $ECHO_N "(cached) $ECHO_C" >&6
5360 "volatile sig_atomic_t" \
5364 cat >conftest.$ac_ext <<_ACEOF
5365 #line 5365 "configure"
5366 #include "confdefs.h"
5368 #include <sys/types.h>
5374 static void handler(int sig)
5382 signal(SIGINT, handler);
5388 rm -f conftest.$ac_objext
5389 if { (eval echo "$as_me:5389: \"$ac_compile\"") >&5
5390 (eval $ac_compile) 2>&5
5392 echo "$as_me:5392: \$? = $ac_status" >&5
5393 (exit $ac_status); } &&
5394 { ac_try='test -s conftest.$ac_objext'
5395 { (eval echo "$as_me:5395: \"$ac_try\"") >&5
5398 echo "$as_me:5398: \$? = $ac_status" >&5
5399 (exit $ac_status); }; }; then
5400 cf_cv_sig_atomic_t=$cf_type
5402 echo "$as_me: failed program was:" >&5
5403 cat conftest.$ac_ext >&5
5404 cf_cv_sig_atomic_t=no
5406 rm -f conftest.$ac_objext conftest.$ac_ext
5407 test "$cf_cv_sig_atomic_t" != no && break
5412 echo "$as_me:5412: result: $cf_cv_sig_atomic_t" >&5
5413 echo "${ECHO_T}$cf_cv_sig_atomic_t" >&6
5414 test "$cf_cv_sig_atomic_t" != no &&
5415 cat >>confdefs.h <<EOF
5416 #define SIG_ATOMIC_T $cf_cv_sig_atomic_t
5419 # Work around breakage on OS X
5421 echo "$as_me:5421: checking if SIGWINCH is defined" >&5
5422 echo $ECHO_N "checking if SIGWINCH is defined... $ECHO_C" >&6
5423 if test "${cf_cv_define_sigwinch+set}" = set; then
5424 echo $ECHO_N "(cached) $ECHO_C" >&6
5427 cat >conftest.$ac_ext <<_ACEOF
5428 #line 5428 "configure"
5429 #include "confdefs.h"
5431 #include <sys/types.h>
5432 #include <sys/signal.h>
5437 int x = SIGWINCH; (void)x
5442 rm -f conftest.$ac_objext
5443 if { (eval echo "$as_me:5443: \"$ac_compile\"") >&5
5444 (eval $ac_compile) 2>&5
5446 echo "$as_me:5446: \$? = $ac_status" >&5
5447 (exit $ac_status); } &&
5448 { ac_try='test -s conftest.$ac_objext'
5449 { (eval echo "$as_me:5449: \"$ac_try\"") >&5
5452 echo "$as_me:5452: \$? = $ac_status" >&5
5453 (exit $ac_status); }; }; then
5454 cf_cv_define_sigwinch=yes
5456 echo "$as_me: failed program was:" >&5
5457 cat conftest.$ac_ext >&5
5458 cat >conftest.$ac_ext <<_ACEOF
5459 #line 5459 "configure"
5460 #include "confdefs.h"
5462 #undef _XOPEN_SOURCE
5463 #undef _POSIX_SOURCE
5464 #undef _POSIX_C_SOURCE
5465 #include <sys/types.h>
5466 #include <sys/signal.h>
5471 int x = SIGWINCH; (void)x
5476 rm -f conftest.$ac_objext
5477 if { (eval echo "$as_me:5477: \"$ac_compile\"") >&5
5478 (eval $ac_compile) 2>&5
5480 echo "$as_me:5480: \$? = $ac_status" >&5
5481 (exit $ac_status); } &&
5482 { ac_try='test -s conftest.$ac_objext'
5483 { (eval echo "$as_me:5483: \"$ac_try\"") >&5
5486 echo "$as_me:5486: \$? = $ac_status" >&5
5487 (exit $ac_status); }; }; then
5488 cf_cv_define_sigwinch=maybe
5490 echo "$as_me: failed program was:" >&5
5491 cat conftest.$ac_ext >&5
5492 cf_cv_define_sigwinch=no
5494 rm -f conftest.$ac_objext conftest.$ac_ext
5497 rm -f conftest.$ac_objext conftest.$ac_ext
5500 echo "$as_me:5500: result: $cf_cv_define_sigwinch" >&5
5501 echo "${ECHO_T}$cf_cv_define_sigwinch" >&6
5503 if test "$cf_cv_define_sigwinch" = maybe ; then
5504 echo "$as_me:5504: checking for actual SIGWINCH definition" >&5
5505 echo $ECHO_N "checking for actual SIGWINCH definition... $ECHO_C" >&6
5506 if test "${cf_cv_fixup_sigwinch+set}" = set; then
5507 echo $ECHO_N "(cached) $ECHO_C" >&6
5510 cf_cv_fixup_sigwinch=unknown
5512 while test $cf_sigwinch != 1
5514 cat >conftest.$ac_ext <<_ACEOF
5515 #line 5515 "configure"
5516 #include "confdefs.h"
5518 #undef _XOPEN_SOURCE
5519 #undef _POSIX_SOURCE
5520 #undef _POSIX_C_SOURCE
5521 #include <sys/types.h>
5522 #include <sys/signal.h>
5528 #if SIGWINCH != $cf_sigwinch
5531 int x = SIGWINCH; (void)x
5536 rm -f conftest.$ac_objext
5537 if { (eval echo "$as_me:5537: \"$ac_compile\"") >&5
5538 (eval $ac_compile) 2>&5
5540 echo "$as_me:5540: \$? = $ac_status" >&5
5541 (exit $ac_status); } &&
5542 { ac_try='test -s conftest.$ac_objext'
5543 { (eval echo "$as_me:5543: \"$ac_try\"") >&5
5546 echo "$as_me:5546: \$? = $ac_status" >&5
5547 (exit $ac_status); }; }; then
5548 cf_cv_fixup_sigwinch=$cf_sigwinch
5551 echo "$as_me: failed program was:" >&5
5552 cat conftest.$ac_ext >&5
5554 rm -f conftest.$ac_objext conftest.$ac_ext
5556 cf_sigwinch=`expr $cf_sigwinch - 1`
5560 echo "$as_me:5560: result: $cf_cv_fixup_sigwinch" >&5
5561 echo "${ECHO_T}$cf_cv_fixup_sigwinch" >&6
5563 if test "$cf_cv_fixup_sigwinch" != unknown ; then
5564 CPPFLAGS="$CPPFLAGS -DSIGWINCH=$cf_cv_fixup_sigwinch"
5568 # Checks for CODESET support.
5570 echo "$as_me:5570: checking for nl_langinfo and CODESET" >&5
5571 echo $ECHO_N "checking for nl_langinfo and CODESET... $ECHO_C" >&6
5572 if test "${am_cv_langinfo_codeset+set}" = set; then
5573 echo $ECHO_N "(cached) $ECHO_C" >&6
5575 cat >conftest.$ac_ext <<_ACEOF
5576 #line 5576 "configure"
5577 #include "confdefs.h"
5578 #include <langinfo.h>
5582 char* cs = nl_langinfo(CODESET); (void)cs
5587 rm -f conftest.$ac_objext conftest$ac_exeext
5588 if { (eval echo "$as_me:5588: \"$ac_link\"") >&5
5589 (eval $ac_link) 2>&5
5591 echo "$as_me:5591: \$? = $ac_status" >&5
5592 (exit $ac_status); } &&
5593 { ac_try='test -s conftest$ac_exeext'
5594 { (eval echo "$as_me:5594: \"$ac_try\"") >&5
5597 echo "$as_me:5597: \$? = $ac_status" >&5
5598 (exit $ac_status); }; }; then
5599 am_cv_langinfo_codeset=yes
5601 echo "$as_me: failed program was:" >&5
5602 cat conftest.$ac_ext >&5
5603 am_cv_langinfo_codeset=no
5605 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5608 echo "$as_me:5608: result: $am_cv_langinfo_codeset" >&5
5609 echo "${ECHO_T}$am_cv_langinfo_codeset" >&6
5610 if test $am_cv_langinfo_codeset = yes; then
5612 cat >>confdefs.h <<\EOF
5613 #define HAVE_LANGINFO_CODESET 1
5618 echo "$as_me:5618: checking if you want to use pkg-config" >&5
5619 echo $ECHO_N "checking if you want to use pkg-config... $ECHO_C" >&6
5621 # Check whether --with-pkg-config or --without-pkg-config was given.
5622 if test "${with_pkg_config+set}" = set; then
5623 withval="$with_pkg_config"
5624 cf_pkg_config=$withval
5628 echo "$as_me:5628: result: $cf_pkg_config" >&5
5629 echo "${ECHO_T}$cf_pkg_config" >&6
5631 case $cf_pkg_config in
5637 if test -n "$ac_tool_prefix"; then
5638 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
5639 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
5640 echo "$as_me:5640: checking for $ac_word" >&5
5641 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5642 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then
5643 echo $ECHO_N "(cached) $ECHO_C" >&6
5647 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
5650 ac_save_IFS=$IFS; IFS=$ac_path_separator
5652 for ac_dir in $ac_dummy; do
5654 test -z "$ac_dir" && ac_dir=.
5655 if $as_executable_p "$ac_dir/$ac_word"; then
5656 ac_cv_path_PKG_CONFIG="$ac_dir/$ac_word"
5657 echo "$as_me:5657: found $ac_dir/$ac_word" >&5
5665 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
5667 if test -n "$PKG_CONFIG"; then
5668 echo "$as_me:5668: result: $PKG_CONFIG" >&5
5669 echo "${ECHO_T}$PKG_CONFIG" >&6
5671 echo "$as_me:5671: result: no" >&5
5672 echo "${ECHO_T}no" >&6
5676 if test -z "$ac_cv_path_PKG_CONFIG"; then
5677 ac_pt_PKG_CONFIG=$PKG_CONFIG
5678 # Extract the first word of "pkg-config", so it can be a program name with args.
5679 set dummy pkg-config; ac_word=$2
5680 echo "$as_me:5680: checking for $ac_word" >&5
5681 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5682 if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then
5683 echo $ECHO_N "(cached) $ECHO_C" >&6
5685 case $ac_pt_PKG_CONFIG in
5687 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
5690 ac_save_IFS=$IFS; IFS=$ac_path_separator
5692 for ac_dir in $ac_dummy; do
5694 test -z "$ac_dir" && ac_dir=.
5695 if $as_executable_p "$ac_dir/$ac_word"; then
5696 ac_cv_path_ac_pt_PKG_CONFIG="$ac_dir/$ac_word"
5697 echo "$as_me:5697: found $ac_dir/$ac_word" >&5
5702 test -z "$ac_cv_path_ac_pt_PKG_CONFIG" && ac_cv_path_ac_pt_PKG_CONFIG="none"
5706 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
5708 if test -n "$ac_pt_PKG_CONFIG"; then
5709 echo "$as_me:5709: result: $ac_pt_PKG_CONFIG" >&5
5710 echo "${ECHO_T}$ac_pt_PKG_CONFIG" >&6
5712 echo "$as_me:5712: result: no" >&5
5713 echo "${ECHO_T}no" >&6
5716 PKG_CONFIG=$ac_pt_PKG_CONFIG
5718 PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
5727 test -z "$PKG_CONFIG" && PKG_CONFIG=none
5728 if test "$PKG_CONFIG" != none ; then
5730 if test "x$prefix" != xNONE; then
5731 cf_path_syntax="$prefix"
5733 cf_path_syntax="$ac_default_prefix"
5736 case ".$PKG_CONFIG" in
5741 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
5743 (.\${*prefix}*|.\${*dir}*)
5744 eval PKG_CONFIG="$PKG_CONFIG"
5745 case ".$PKG_CONFIG" in
5747 PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
5752 PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
5755 { { echo "$as_me:5755: error: expected a pathname, not \"$PKG_CONFIG\"" >&5
5756 echo "$as_me: error: expected a pathname, not \"$PKG_CONFIG\"" >&2;}
5757 { (exit 1); exit 1; }; }
5761 elif test "x$cf_pkg_config" != xno ; then
5762 { echo "$as_me:5762: WARNING: pkg-config is not installed" >&5
5763 echo "$as_me: WARNING: pkg-config is not installed" >&2;}
5766 echo "$as_me:5766: checking if you want to see long compiling messages" >&5
5767 echo $ECHO_N "checking if you want to see long compiling messages... $ECHO_C" >&6
5769 # Check whether --enable-echo or --disable-echo was given.
5770 if test "${enable_echo+set}" = set; then
5771 enableval="$enable_echo"
5772 test "$enableval" != no && enableval=yes
5773 if test "$enableval" != "yes" ; then
5776 ECHO_LD='@echo linking $@;'
5777 RULE_CC='@echo compiling $<'
5778 SHOW_CC='@echo compiling $@'
5800 echo "$as_me:5800: result: $enableval" >&5
5801 echo "${ECHO_T}$enableval" >&6
5803 echo "$as_me:5803: checking for ncurses wrap-prefix" >&5
5804 echo $ECHO_N "checking for ncurses wrap-prefix... $ECHO_C" >&6
5806 # Check whether --with-ncurses-wrap-prefix or --without-ncurses-wrap-prefix was given.
5807 if test "${with_ncurses_wrap_prefix+set}" = set; then
5808 withval="$with_ncurses_wrap_prefix"
5809 NCURSES_WRAP_PREFIX=$withval
5811 NCURSES_WRAP_PREFIX=_nc_
5813 echo "$as_me:5813: result: $NCURSES_WRAP_PREFIX" >&5
5814 echo "${ECHO_T}$NCURSES_WRAP_PREFIX" >&6
5816 echo "$as_me:5816: checking if you want to check for wide-character functions" >&5
5817 echo $ECHO_N "checking if you want to check for wide-character functions... $ECHO_C" >&6
5819 # Check whether --enable-widec or --disable-widec was given.
5820 if test "${enable_widec+set}" = set; then
5821 enableval="$enable_widec"
5822 test "$enableval" != no && enableval=yes
5823 if test "$enableval" != "yes" ; then
5833 echo "$as_me:5833: result: $cf_enable_widec" >&5
5834 echo "${ECHO_T}$cf_enable_widec" >&6
5836 echo "$as_me:5836: checking for specific curses-directory" >&5
5837 echo $ECHO_N "checking for specific curses-directory... $ECHO_C" >&6
5839 # Check whether --with-curses-dir or --without-curses-dir was given.
5840 if test "${with_curses_dir+set}" = set; then
5841 withval="$with_curses_dir"
5842 cf_cv_curses_dir=$withval
5846 echo "$as_me:5846: result: $cf_cv_curses_dir" >&5
5847 echo "${ECHO_T}$cf_cv_curses_dir" >&6
5849 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
5852 if test "x$prefix" != xNONE; then
5853 cf_path_syntax="$prefix"
5855 cf_path_syntax="$ac_default_prefix"
5863 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
5865 (.\${*prefix}*|.\${*dir}*)
5866 eval withval="$withval"
5869 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
5874 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
5877 { { echo "$as_me:5877: error: expected a pathname, not \"$withval\"" >&5
5878 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
5879 { (exit 1); exit 1; }; }
5883 if test -d "$cf_cv_curses_dir"
5886 if test -n "$cf_cv_curses_dir/include" ; then
5887 for cf_add_incdir in $cf_cv_curses_dir/include
5889 while test $cf_add_incdir != /usr/include
5891 if test -d $cf_add_incdir
5894 if test -n "$CFLAGS$CPPFLAGS" ; then
5895 # a loop is needed to ensure we can add subdirs of existing dirs
5896 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
5897 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
5898 cf_have_incdir=yes; break
5903 if test "$cf_have_incdir" = no ; then
5904 if test "$cf_add_incdir" = /usr/local/include ; then
5905 if test "$GCC" = yes
5907 cf_save_CPPFLAGS=$CPPFLAGS
5909 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5910 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
5912 cat >conftest.$ac_ext <<_ACEOF
5913 #line 5913 "configure"
5914 #include "confdefs.h"
5924 rm -f conftest.$ac_objext
5925 if { (eval echo "$as_me:5925: \"$ac_compile\"") >&5
5926 (eval $ac_compile) 2>&5
5928 echo "$as_me:5928: \$? = $ac_status" >&5
5929 (exit $ac_status); } &&
5930 { ac_try='test -s conftest.$ac_objext'
5931 { (eval echo "$as_me:5931: \"$ac_try\"") >&5
5934 echo "$as_me:5934: \$? = $ac_status" >&5
5935 (exit $ac_status); }; }; then
5938 echo "$as_me: failed program was:" >&5
5939 cat conftest.$ac_ext >&5
5942 rm -f conftest.$ac_objext conftest.$ac_ext
5943 CPPFLAGS=$cf_save_CPPFLAGS
5948 if test "$cf_have_incdir" = no ; then
5949 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
5951 echo "${as_me:-configure}:5951: testing adding $cf_add_incdir to include-path ..." 1>&5
5953 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
5955 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
5956 test "$cf_top_incdir" = "$cf_add_incdir" && break
5957 cf_add_incdir="$cf_top_incdir"
5968 if test -n "$cf_cv_curses_dir/lib" ; then
5969 for cf_add_libdir in $cf_cv_curses_dir/lib
5971 if test $cf_add_libdir = /usr/lib ; then
5973 elif test -d $cf_add_libdir
5976 if test -n "$LDFLAGS$LIBS" ; then
5977 # a loop is needed to ensure we can add subdirs of existing dirs
5978 for cf_test_libdir in $LDFLAGS $LIBS ; do
5979 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
5980 cf_have_libdir=yes; break
5984 if test "$cf_have_libdir" = no ; then
5985 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
5987 echo "${as_me:-configure}:5987: testing adding $cf_add_libdir to library-path ..." 1>&5
5989 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
6000 echo "$as_me:6000: checking for specified curses library type" >&5
6001 echo $ECHO_N "checking for specified curses library type... $ECHO_C" >&6
6003 # Check whether --with-screen or --without-screen was given.
6004 if test "${with_screen+set}" = set; then
6005 withval="$with_screen"
6006 cf_cv_screen=$withval
6009 # Check whether --with-ncursesw or --without-ncursesw was given.
6010 if test "${with_ncursesw+set}" = set; then
6011 withval="$with_ncursesw"
6012 cf_cv_screen=ncursesw
6015 # Check whether --with-ncurses or --without-ncurses was given.
6016 if test "${with_ncurses+set}" = set; then
6017 withval="$with_ncurses"
6018 cf_cv_screen=ncurses
6021 # Check whether --with-pdcurses or --without-pdcurses was given.
6022 if test "${with_pdcurses+set}" = set; then
6023 withval="$with_pdcurses"
6024 cf_cv_screen=pdcurses
6027 # Check whether --with-curses-colr or --without-curses-colr was given.
6028 if test "${with_curses_colr+set}" = set; then
6029 withval="$with_curses_colr"
6030 cf_cv_screen=curses_colr
6033 # Check whether --with-curses-5lib or --without-curses-5lib was given.
6034 if test "${with_curses_5lib+set}" = set; then
6035 withval="$with_curses_5lib"
6036 cf_cv_screen=curses_5lib
6044 echo "$as_me:6044: result: $cf_cv_screen" >&5
6045 echo "${ECHO_T}$cf_cv_screen" >&6
6047 case $cf_cv_screen in
6050 echo "$as_me:6050: checking for extra include directories" >&5
6051 echo $ECHO_N "checking for extra include directories... $ECHO_C" >&6
6052 if test "${cf_cv_curses_incdir+set}" = set; then
6053 echo $ECHO_N "(cached) $ECHO_C" >&6
6056 cf_cv_curses_incdir=no
6059 if test "x$cf_cv_screen" = "xcurses_colr"
6061 test -d /usr/include/curses_colr && \
6062 cf_cv_curses_incdir="-I/usr/include/curses_colr"
6066 if test "x$cf_cv_screen" = "xcurses_5lib"
6068 test -d /usr/5lib && \
6069 test -d /usr/5include && \
6070 cf_cv_curses_incdir="-I/usr/5include"
6076 echo "$as_me:6076: result: $cf_cv_curses_incdir" >&5
6077 echo "${ECHO_T}$cf_cv_curses_incdir" >&6
6078 if test "$cf_cv_curses_incdir" != no
6081 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
6082 CPPFLAGS="${CPPFLAGS}$cf_cv_curses_incdir"
6086 echo "$as_me:6086: checking if we have identified curses headers" >&5
6087 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
6088 if test "${cf_cv_ncurses_header+set}" = set; then
6089 echo $ECHO_N "(cached) $ECHO_C" >&6
6092 cf_cv_ncurses_header=none
6095 curses.h ncurses/ncurses.h ncurses/curses.h
6097 cat >conftest.$ac_ext <<_ACEOF
6098 #line 6098 "configure"
6099 #include "confdefs.h"
6100 #include <${cf_header}>
6104 initscr(); tgoto("?", 0,0)
6109 rm -f conftest.$ac_objext
6110 if { (eval echo "$as_me:6110: \"$ac_compile\"") >&5
6111 (eval $ac_compile) 2>&5
6113 echo "$as_me:6113: \$? = $ac_status" >&5
6114 (exit $ac_status); } &&
6115 { ac_try='test -s conftest.$ac_objext'
6116 { (eval echo "$as_me:6116: \"$ac_try\"") >&5
6119 echo "$as_me:6119: \$? = $ac_status" >&5
6120 (exit $ac_status); }; }; then
6121 cf_cv_ncurses_header=$cf_header; break
6123 echo "$as_me: failed program was:" >&5
6124 cat conftest.$ac_ext >&5
6126 rm -f conftest.$ac_objext conftest.$ac_ext
6130 echo "$as_me:6130: result: $cf_cv_ncurses_header" >&5
6131 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
6133 if test "$cf_cv_ncurses_header" = none ; then
6134 { { echo "$as_me:6134: error: No curses header-files found" >&5
6135 echo "$as_me: error: No curses header-files found" >&2;}
6136 { (exit 1); exit 1; }; }
6139 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
6141 for ac_header in $cf_cv_ncurses_header
6143 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6144 echo "$as_me:6144: checking for $ac_header" >&5
6145 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6146 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6147 echo $ECHO_N "(cached) $ECHO_C" >&6
6149 cat >conftest.$ac_ext <<_ACEOF
6150 #line 6150 "configure"
6151 #include "confdefs.h"
6152 #include <$ac_header>
6154 if { (eval echo "$as_me:6154: \"$ac_cpp conftest.$ac_ext\"") >&5
6155 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6157 egrep -v '^ *\+' conftest.er1 >conftest.err
6159 cat conftest.err >&5
6160 echo "$as_me:6160: \$? = $ac_status" >&5
6161 (exit $ac_status); } >/dev/null; then
6162 if test -s conftest.err; then
6163 ac_cpp_err=$ac_c_preproc_warn_flag
6170 if test -z "$ac_cpp_err"; then
6171 eval "$as_ac_Header=yes"
6173 echo "$as_me: failed program was:" >&5
6174 cat conftest.$ac_ext >&5
6175 eval "$as_ac_Header=no"
6177 rm -f conftest.err conftest.$ac_ext
6179 echo "$as_me:6179: result: `eval echo '${'$as_ac_Header'}'`" >&5
6180 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6181 if test `eval echo '${'$as_ac_Header'}'` = yes; then
6182 cat >>confdefs.h <<EOF
6183 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6189 echo "$as_me:6189: checking for terminfo header" >&5
6190 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
6191 if test "${cf_cv_term_header+set}" = set; then
6192 echo $ECHO_N "(cached) $ECHO_C" >&6
6195 case ${cf_cv_ncurses_header} in
6196 (*/ncurses.h|*/ncursesw.h)
6197 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
6200 cf_term_header=term.h
6204 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
6206 cat >conftest.$ac_ext <<_ACEOF
6207 #line 6207 "configure"
6208 #include "confdefs.h"
6210 #include <${cf_cv_ncurses_header:-curses.h}>
6216 int x = auto_left_margin; (void)x
6221 rm -f conftest.$ac_objext
6222 if { (eval echo "$as_me:6222: \"$ac_compile\"") >&5
6223 (eval $ac_compile) 2>&5
6225 echo "$as_me:6225: \$? = $ac_status" >&5
6226 (exit $ac_status); } &&
6227 { ac_try='test -s conftest.$ac_objext'
6228 { (eval echo "$as_me:6228: \"$ac_try\"") >&5
6231 echo "$as_me:6231: \$? = $ac_status" >&5
6232 (exit $ac_status); }; }; then
6234 cf_cv_term_header="$cf_test"
6236 echo "$as_me: failed program was:" >&5
6237 cat conftest.$ac_ext >&5
6239 cf_cv_term_header=unknown
6242 rm -f conftest.$ac_objext conftest.$ac_ext
6243 test "$cf_cv_term_header" != unknown && break
6247 echo "$as_me:6247: result: $cf_cv_term_header" >&5
6248 echo "${ECHO_T}$cf_cv_term_header" >&6
6250 # Set definitions to allow ifdef'ing to accommodate subdirectories
6252 case $cf_cv_term_header in
6255 cat >>confdefs.h <<\EOF
6256 #define HAVE_TERM_H 1
6262 case $cf_cv_term_header in
6265 cat >>confdefs.h <<\EOF
6266 #define HAVE_NCURSES_TERM_H 1
6272 cat >>confdefs.h <<\EOF
6273 #define HAVE_NCURSESW_TERM_H 1
6279 echo "$as_me:6279: checking for ncurses version" >&5
6280 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
6281 if test "${cf_cv_ncurses_version+set}" = set; then
6282 echo $ECHO_N "(cached) $ECHO_C" >&6
6285 cf_cv_ncurses_version=no
6288 if test "$cross_compiling" = yes; then
6290 # This will not work if the preprocessor splits the line after the
6291 # Autoconf token. The 'unproto' program does that.
6292 cat > conftest.$ac_ext <<EOF
6293 #include <${cf_cv_ncurses_header:-curses.h}>
6295 #ifdef NCURSES_VERSION
6296 Autoconf NCURSES_VERSION
6304 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
6305 { (eval echo "$as_me:6305: \"$cf_try\"") >&5
6308 echo "$as_me:6308: \$? = $ac_status" >&5
6309 (exit $ac_status); }
6310 if test -f conftest.out ; then
6311 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
6312 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
6317 cat >conftest.$ac_ext <<_ACEOF
6318 #line 6318 "configure"
6319 #include "confdefs.h"
6321 #include <${cf_cv_ncurses_header:-curses.h}>
6325 FILE *fp = fopen("$cf_tempfile", "w");
6326 #ifdef NCURSES_VERSION
6327 # ifdef NCURSES_VERSION_PATCH
6328 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
6330 fprintf(fp, "%s\n", NCURSES_VERSION);
6334 fprintf(fp, "old\n");
6339 ${cf_cv_main_return:-return}(0);
6342 rm -f conftest$ac_exeext
6343 if { (eval echo "$as_me:6343: \"$ac_link\"") >&5
6344 (eval $ac_link) 2>&5
6346 echo "$as_me:6346: \$? = $ac_status" >&5
6347 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
6348 { (eval echo "$as_me:6348: \"$ac_try\"") >&5
6351 echo "$as_me:6351: \$? = $ac_status" >&5
6352 (exit $ac_status); }; }; then
6354 cf_cv_ncurses_version=`cat $cf_tempfile`
6356 echo "$as_me: program exited with status $ac_status" >&5
6357 echo "$as_me: failed program was:" >&5
6358 cat conftest.$ac_ext >&5
6360 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6365 echo "$as_me:6365: result: $cf_cv_ncurses_version" >&5
6366 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
6367 test "$cf_cv_ncurses_version" = no ||
6368 cat >>confdefs.h <<\EOF
6372 echo "$as_me:6372: checking if we have identified curses libraries" >&5
6373 echo $ECHO_N "checking if we have identified curses libraries... $ECHO_C" >&6
6374 cat >conftest.$ac_ext <<_ACEOF
6375 #line 6375 "configure"
6376 #include "confdefs.h"
6377 #include <${cf_cv_ncurses_header:-curses.h}>
6381 initscr(); tgoto("?", 0,0)
6386 rm -f conftest.$ac_objext conftest$ac_exeext
6387 if { (eval echo "$as_me:6387: \"$ac_link\"") >&5
6388 (eval $ac_link) 2>&5
6390 echo "$as_me:6390: \$? = $ac_status" >&5
6391 (exit $ac_status); } &&
6392 { ac_try='test -s conftest$ac_exeext'
6393 { (eval echo "$as_me:6393: \"$ac_try\"") >&5
6396 echo "$as_me:6396: \$? = $ac_status" >&5
6397 (exit $ac_status); }; }; then
6400 echo "$as_me: failed program was:" >&5
6401 cat conftest.$ac_ext >&5
6404 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6405 echo "$as_me:6405: result: $cf_result" >&5
6406 echo "${ECHO_T}$cf_result" >&6
6408 if test "$cf_result" = no ; then
6411 echo "$as_me:6411: checking for tgoto in -lmytinfo" >&5
6412 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
6413 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
6414 echo $ECHO_N "(cached) $ECHO_C" >&6
6416 ac_check_lib_save_LIBS=$LIBS
6417 LIBS="-lmytinfo $LIBS"
6418 cat >conftest.$ac_ext <<_ACEOF
6419 #line 6419 "configure"
6420 #include "confdefs.h"
6422 /* Override any gcc2 internal prototype to avoid an error. */
6426 /* We use char because int might match the return type of a gcc2
6427 builtin and then its argument prototype would still apply. */
6437 rm -f conftest.$ac_objext conftest$ac_exeext
6438 if { (eval echo "$as_me:6438: \"$ac_link\"") >&5
6439 (eval $ac_link) 2>&5
6441 echo "$as_me:6441: \$? = $ac_status" >&5
6442 (exit $ac_status); } &&
6443 { ac_try='test -s conftest$ac_exeext'
6444 { (eval echo "$as_me:6444: \"$ac_try\"") >&5
6447 echo "$as_me:6447: \$? = $ac_status" >&5
6448 (exit $ac_status); }; }; then
6449 ac_cv_lib_mytinfo_tgoto=yes
6451 echo "$as_me: failed program was:" >&5
6452 cat conftest.$ac_ext >&5
6453 ac_cv_lib_mytinfo_tgoto=no
6455 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6456 LIBS=$ac_check_lib_save_LIBS
6458 echo "$as_me:6458: result: $ac_cv_lib_mytinfo_tgoto" >&5
6459 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
6460 if test $ac_cv_lib_mytinfo_tgoto = yes; then
6465 for cf_add_1lib in -lmytinfo; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
6467 for cf_add_1lib in $cf_add_0lib; do
6468 for cf_add_2lib in $cf_add_libs; do
6469 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
6474 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
6482 # Looking at HPUX 10.20, the Hcurses library is the oldest (1997), cur_colr
6483 # next (1998), and xcurses "newer" (2000). There is no header file for
6484 # Hcurses; the subdirectory curses_colr has the headers (curses.h and
6485 # term.h) for cur_colr
6486 if test "x$cf_cv_screen" = "xcurses_colr"
6488 echo "$as_me:6488: checking for initscr in -lcur_colr" >&5
6489 echo $ECHO_N "checking for initscr in -lcur_colr... $ECHO_C" >&6
6490 if test "${ac_cv_lib_cur_colr_initscr+set}" = set; then
6491 echo $ECHO_N "(cached) $ECHO_C" >&6
6493 ac_check_lib_save_LIBS=$LIBS
6494 LIBS="-lcur_colr $LIBS"
6495 cat >conftest.$ac_ext <<_ACEOF
6496 #line 6496 "configure"
6497 #include "confdefs.h"
6499 /* Override any gcc2 internal prototype to avoid an error. */
6503 /* We use char because int might match the return type of a gcc2
6504 builtin and then its argument prototype would still apply. */
6514 rm -f conftest.$ac_objext conftest$ac_exeext
6515 if { (eval echo "$as_me:6515: \"$ac_link\"") >&5
6516 (eval $ac_link) 2>&5
6518 echo "$as_me:6518: \$? = $ac_status" >&5
6519 (exit $ac_status); } &&
6520 { ac_try='test -s conftest$ac_exeext'
6521 { (eval echo "$as_me:6521: \"$ac_try\"") >&5
6524 echo "$as_me:6524: \$? = $ac_status" >&5
6525 (exit $ac_status); }; }; then
6526 ac_cv_lib_cur_colr_initscr=yes
6528 echo "$as_me: failed program was:" >&5
6529 cat conftest.$ac_ext >&5
6530 ac_cv_lib_cur_colr_initscr=no
6532 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6533 LIBS=$ac_check_lib_save_LIBS
6535 echo "$as_me:6535: result: $ac_cv_lib_cur_colr_initscr" >&5
6536 echo "${ECHO_T}$ac_cv_lib_cur_colr_initscr" >&6
6537 if test $ac_cv_lib_cur_colr_initscr = yes; then
6542 for cf_add_1lib in -lcur_colr; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
6544 for cf_add_1lib in $cf_add_0lib; do
6545 for cf_add_2lib in $cf_add_libs; do
6546 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
6551 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
6555 ac_cv_func_initscr=yes
6559 echo "$as_me:6559: checking for initscr in -lHcurses" >&5
6560 echo $ECHO_N "checking for initscr in -lHcurses... $ECHO_C" >&6
6561 if test "${ac_cv_lib_Hcurses_initscr+set}" = set; then
6562 echo $ECHO_N "(cached) $ECHO_C" >&6
6564 ac_check_lib_save_LIBS=$LIBS
6565 LIBS="-lHcurses $LIBS"
6566 cat >conftest.$ac_ext <<_ACEOF
6567 #line 6567 "configure"
6568 #include "confdefs.h"
6570 /* Override any gcc2 internal prototype to avoid an error. */
6574 /* We use char because int might match the return type of a gcc2
6575 builtin and then its argument prototype would still apply. */
6585 rm -f conftest.$ac_objext conftest$ac_exeext
6586 if { (eval echo "$as_me:6586: \"$ac_link\"") >&5
6587 (eval $ac_link) 2>&5
6589 echo "$as_me:6589: \$? = $ac_status" >&5
6590 (exit $ac_status); } &&
6591 { ac_try='test -s conftest$ac_exeext'
6592 { (eval echo "$as_me:6592: \"$ac_try\"") >&5
6595 echo "$as_me:6595: \$? = $ac_status" >&5
6596 (exit $ac_status); }; }; then
6597 ac_cv_lib_Hcurses_initscr=yes
6599 echo "$as_me: failed program was:" >&5
6600 cat conftest.$ac_ext >&5
6601 ac_cv_lib_Hcurses_initscr=no
6603 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6604 LIBS=$ac_check_lib_save_LIBS
6606 echo "$as_me:6606: result: $ac_cv_lib_Hcurses_initscr" >&5
6607 echo "${ECHO_T}$ac_cv_lib_Hcurses_initscr" >&6
6608 if test $ac_cv_lib_Hcurses_initscr = yes; then
6610 # HP's header uses __HP_CURSES, but user claims _HP_CURSES.
6615 for cf_add_1lib in -lHcurses; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
6617 for cf_add_1lib in $cf_add_0lib; do
6618 for cf_add_2lib in $cf_add_libs; do
6619 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
6624 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
6628 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
6629 CPPFLAGS="${CPPFLAGS}-D__HP_CURSES -D_HP_CURSES"
6631 ac_cv_func_initscr=yes
6640 case `arch 2>/dev/null` in
6645 if test -n "/lib64" ; then
6646 for cf_add_libdir in /lib64
6648 if test $cf_add_libdir = /usr/lib ; then
6650 elif test -d $cf_add_libdir
6653 if test -n "$LDFLAGS$LIBS" ; then
6654 # a loop is needed to ensure we can add subdirs of existing dirs
6655 for cf_test_libdir in $LDFLAGS $LIBS ; do
6656 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
6657 cf_have_libdir=yes; break
6661 if test "$cf_have_libdir" = no ; then
6662 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
6664 echo "${as_me:-configure}:6664: testing adding $cf_add_libdir to library-path ..." 1>&5
6666 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
6674 if test -n "/lib" ; then
6675 for cf_add_libdir in /lib
6677 if test $cf_add_libdir = /usr/lib ; then
6679 elif test -d $cf_add_libdir
6682 if test -n "$LDFLAGS$LIBS" ; then
6683 # a loop is needed to ensure we can add subdirs of existing dirs
6684 for cf_test_libdir in $LDFLAGS $LIBS ; do
6685 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
6686 cf_have_libdir=yes; break
6690 if test "$cf_have_libdir" = no ; then
6691 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
6693 echo "${as_me:-configure}:6693: testing adding $cf_add_libdir to library-path ..." 1>&5
6695 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
6705 if test -n "/lib" ; then
6706 for cf_add_libdir in /lib
6708 if test $cf_add_libdir = /usr/lib ; then
6710 elif test -d $cf_add_libdir
6713 if test -n "$LDFLAGS$LIBS" ; then
6714 # a loop is needed to ensure we can add subdirs of existing dirs
6715 for cf_test_libdir in $LDFLAGS $LIBS ; do
6716 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
6717 cf_have_libdir=yes; break
6721 if test "$cf_have_libdir" = no ; then
6722 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
6724 echo "${as_me:-configure}:6724: testing adding $cf_add_libdir to library-path ..." 1>&5
6726 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
6736 if test "x$cf_cv_screen" = "xcurses_5lib"
6738 if test -d /usr/5lib ; then
6740 if test -n "/usr/5lib" ; then
6741 for cf_add_libdir in /usr/5lib
6743 if test $cf_add_libdir = /usr/lib ; then
6745 elif test -d $cf_add_libdir
6748 if test -n "$LDFLAGS$LIBS" ; then
6749 # a loop is needed to ensure we can add subdirs of existing dirs
6750 for cf_test_libdir in $LDFLAGS $LIBS ; do
6751 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
6752 cf_have_libdir=yes; break
6756 if test "$cf_have_libdir" = no ; then
6757 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
6759 echo "${as_me:-configure}:6759: testing adding $cf_add_libdir to library-path ..." 1>&5
6761 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
6770 for cf_add_1lib in -lcurses -ltermcap; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
6772 for cf_add_1lib in $cf_add_0lib; do
6773 for cf_add_2lib in $cf_add_libs; do
6774 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
6779 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
6785 ac_cv_func_initscr=yes
6789 if test ".$ac_cv_func_initscr" != .yes ; then
6790 cf_save_LIBS="$LIBS"
6792 if test ".${cf_cv_ncurses_version:-no}" != .no
6794 cf_check_list="ncurses curses cursesX"
6796 cf_check_list="cursesX curses ncurses"
6799 # Check for library containing tgoto. Do this before curses library
6800 # because it may be needed to link the test-case for initscr.
6801 if test "x$cf_term_lib" = x
6803 echo "$as_me:6803: checking for tgoto" >&5
6804 echo $ECHO_N "checking for tgoto... $ECHO_C" >&6
6805 if test "${ac_cv_func_tgoto+set}" = set; then
6806 echo $ECHO_N "(cached) $ECHO_C" >&6
6808 cat >conftest.$ac_ext <<_ACEOF
6809 #line 6809 "configure"
6810 #include "confdefs.h"
6811 #define tgoto autoconf_temporary
6812 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
6819 /* We use char because int might match the return type of a gcc2
6820 builtin and then its argument prototype would still apply. */
6827 /* The GNU C library defines stubs for functions which it implements
6828 to always fail with ENOSYS. Some functions are actually named
6829 something starting with __ and the normal name is an alias. */
6830 #if defined (__stub_tgoto) || defined (__stub___tgoto)
6831 #error found stub for tgoto
6839 rm -f conftest.$ac_objext conftest$ac_exeext
6840 if { (eval echo "$as_me:6840: \"$ac_link\"") >&5
6841 (eval $ac_link) 2>&5
6843 echo "$as_me:6843: \$? = $ac_status" >&5
6844 (exit $ac_status); } &&
6845 { ac_try='test -s conftest$ac_exeext'
6846 { (eval echo "$as_me:6846: \"$ac_try\"") >&5
6849 echo "$as_me:6849: \$? = $ac_status" >&5
6850 (exit $ac_status); }; }; then
6851 ac_cv_func_tgoto=yes
6853 echo "$as_me: failed program was:" >&5
6854 cat conftest.$ac_ext >&5
6857 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6859 echo "$as_me:6859: result: $ac_cv_func_tgoto" >&5
6860 echo "${ECHO_T}$ac_cv_func_tgoto" >&6
6861 if test $ac_cv_func_tgoto = yes; then
6862 cf_term_lib=predefined
6865 for cf_term_lib in $cf_check_list otermcap termcap tinfo termlib unknown
6867 as_ac_Lib=`echo "ac_cv_lib_$cf_term_lib''_tgoto" | $as_tr_sh`
6868 echo "$as_me:6868: checking for tgoto in -l$cf_term_lib" >&5
6869 echo $ECHO_N "checking for tgoto in -l$cf_term_lib... $ECHO_C" >&6
6870 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
6871 echo $ECHO_N "(cached) $ECHO_C" >&6
6873 ac_check_lib_save_LIBS=$LIBS
6874 LIBS="-l$cf_term_lib $LIBS"
6875 cat >conftest.$ac_ext <<_ACEOF
6876 #line 6876 "configure"
6877 #include "confdefs.h"
6879 /* Override any gcc2 internal prototype to avoid an error. */
6883 /* We use char because int might match the return type of a gcc2
6884 builtin and then its argument prototype would still apply. */
6894 rm -f conftest.$ac_objext conftest$ac_exeext
6895 if { (eval echo "$as_me:6895: \"$ac_link\"") >&5
6896 (eval $ac_link) 2>&5
6898 echo "$as_me:6898: \$? = $ac_status" >&5
6899 (exit $ac_status); } &&
6900 { ac_try='test -s conftest$ac_exeext'
6901 { (eval echo "$as_me:6901: \"$ac_try\"") >&5
6904 echo "$as_me:6904: \$? = $ac_status" >&5
6905 (exit $ac_status); }; }; then
6906 eval "$as_ac_Lib=yes"
6908 echo "$as_me: failed program was:" >&5
6909 cat conftest.$ac_ext >&5
6910 eval "$as_ac_Lib=no"
6912 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6913 LIBS=$ac_check_lib_save_LIBS
6915 echo "$as_me:6915: result: `eval echo '${'$as_ac_Lib'}'`" >&5
6916 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
6917 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
6919 : ${cf_nculib_root:=$cf_term_lib}
6930 # Check for library containing initscr
6931 test "$cf_term_lib" != predefined && test "$cf_term_lib" != unknown && LIBS="-l$cf_term_lib $cf_save_LIBS"
6932 if test "x$cf_curs_lib" = x
6934 for cf_curs_lib in $cf_check_list xcurses jcurses pdcurses unknown
6936 LIBS="-l$cf_curs_lib $cf_save_LIBS"
6937 if test "$cf_term_lib" = unknown || test "$cf_term_lib" = "$cf_curs_lib" ; then
6938 echo "$as_me:6938: checking if we can link with $cf_curs_lib library" >&5
6939 echo $ECHO_N "checking if we can link with $cf_curs_lib library... $ECHO_C" >&6
6940 cat >conftest.$ac_ext <<_ACEOF
6941 #line 6941 "configure"
6942 #include "confdefs.h"
6943 #include <${cf_cv_ncurses_header:-curses.h}>
6952 rm -f conftest.$ac_objext conftest$ac_exeext
6953 if { (eval echo "$as_me:6953: \"$ac_link\"") >&5
6954 (eval $ac_link) 2>&5
6956 echo "$as_me:6956: \$? = $ac_status" >&5
6957 (exit $ac_status); } &&
6958 { ac_try='test -s conftest$ac_exeext'
6959 { (eval echo "$as_me:6959: \"$ac_try\"") >&5
6962 echo "$as_me:6962: \$? = $ac_status" >&5
6963 (exit $ac_status); }; }; then
6966 echo "$as_me: failed program was:" >&5
6967 cat conftest.$ac_ext >&5
6970 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6971 echo "$as_me:6971: result: $cf_result" >&5
6972 echo "${ECHO_T}$cf_result" >&6
6973 test $cf_result = yes && break
6974 elif test "$cf_curs_lib" = "$cf_term_lib" ; then
6976 elif test "$cf_term_lib" != predefined ; then
6977 echo "$as_me:6977: checking if we need both $cf_curs_lib and $cf_term_lib libraries" >&5
6978 echo $ECHO_N "checking if we need both $cf_curs_lib and $cf_term_lib libraries... $ECHO_C" >&6
6979 cat >conftest.$ac_ext <<_ACEOF
6980 #line 6980 "configure"
6981 #include "confdefs.h"
6982 #include <${cf_cv_ncurses_header:-curses.h}>
6986 initscr(); tgoto((char *)0, 0, 0);
6991 rm -f conftest.$ac_objext conftest$ac_exeext
6992 if { (eval echo "$as_me:6992: \"$ac_link\"") >&5
6993 (eval $ac_link) 2>&5
6995 echo "$as_me:6995: \$? = $ac_status" >&5
6996 (exit $ac_status); } &&
6997 { ac_try='test -s conftest$ac_exeext'
6998 { (eval echo "$as_me:6998: \"$ac_try\"") >&5
7001 echo "$as_me:7001: \$? = $ac_status" >&5
7002 (exit $ac_status); }; }; then
7005 echo "$as_me: failed program was:" >&5
7006 cat conftest.$ac_ext >&5
7008 LIBS="-l$cf_curs_lib -l$cf_term_lib $cf_save_LIBS"
7009 cat >conftest.$ac_ext <<_ACEOF
7010 #line 7010 "configure"
7011 #include "confdefs.h"
7012 #include <${cf_cv_ncurses_header:-curses.h}>
7021 rm -f conftest.$ac_objext conftest$ac_exeext
7022 if { (eval echo "$as_me:7022: \"$ac_link\"") >&5
7023 (eval $ac_link) 2>&5
7025 echo "$as_me:7025: \$? = $ac_status" >&5
7026 (exit $ac_status); } &&
7027 { ac_try='test -s conftest$ac_exeext'
7028 { (eval echo "$as_me:7028: \"$ac_try\"") >&5
7031 echo "$as_me:7031: \$? = $ac_status" >&5
7032 (exit $ac_status); }; }; then
7035 echo "$as_me: failed program was:" >&5
7036 cat conftest.$ac_ext >&5
7039 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7042 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7043 echo "$as_me:7043: result: $cf_result" >&5
7044 echo "${ECHO_T}$cf_result" >&6
7045 test $cf_result != error && break
7049 test $cf_curs_lib = unknown && { { echo "$as_me:7049: error: no curses library found" >&5
7050 echo "$as_me: error: no curses library found" >&2;}
7051 { (exit 1); exit 1; }; }
7058 echo "$as_me:7058: checking for multibyte character support" >&5
7059 echo $ECHO_N "checking for multibyte character support... $ECHO_C" >&6
7060 if test "${cf_cv_utf8_lib+set}" = set; then
7061 echo $ECHO_N "(cached) $ECHO_C" >&6
7064 cf_save_LIBS="$LIBS"
7065 cat >conftest.$ac_ext <<_ACEOF
7066 #line 7066 "configure"
7067 #include "confdefs.h"
7078 rm -f conftest.$ac_objext conftest$ac_exeext
7079 if { (eval echo "$as_me:7079: \"$ac_link\"") >&5
7080 (eval $ac_link) 2>&5
7082 echo "$as_me:7082: \$? = $ac_status" >&5
7083 (exit $ac_status); } &&
7084 { ac_try='test -s conftest$ac_exeext'
7085 { (eval echo "$as_me:7085: \"$ac_try\"") >&5
7088 echo "$as_me:7088: \$? = $ac_status" >&5
7089 (exit $ac_status); }; }; then
7092 echo "$as_me: failed program was:" >&5
7093 cat conftest.$ac_ext >&5
7095 # If the linkage is not already in the $CPPFLAGS/$LDFLAGS configuration, these
7096 # will be set on completion of the AC_TRY_LINK below.
7097 cf_cv_header_path_utf8=
7098 cf_cv_library_path_utf8=
7100 echo "${as_me:-configure}:7100: testing Starting FIND_LINKAGE(utf8,) ..." 1>&5
7102 cf_save_LIBS="$LIBS"
7104 cat >conftest.$ac_ext <<_ACEOF
7105 #line 7105 "configure"
7106 #include "confdefs.h"
7108 #include <libutf8.h>
7117 rm -f conftest.$ac_objext conftest$ac_exeext
7118 if { (eval echo "$as_me:7118: \"$ac_link\"") >&5
7119 (eval $ac_link) 2>&5
7121 echo "$as_me:7121: \$? = $ac_status" >&5
7122 (exit $ac_status); } &&
7123 { ac_try='test -s conftest$ac_exeext'
7124 { (eval echo "$as_me:7124: \"$ac_try\"") >&5
7127 echo "$as_me:7127: \$? = $ac_status" >&5
7128 (exit $ac_status); }; }; then
7130 cf_cv_find_linkage_utf8=yes
7131 cf_cv_header_path_utf8=/usr/include
7132 cf_cv_library_path_utf8=/usr/lib
7135 echo "$as_me: failed program was:" >&5
7136 cat conftest.$ac_ext >&5
7138 LIBS="-lutf8 $cf_save_LIBS"
7140 cat >conftest.$ac_ext <<_ACEOF
7141 #line 7141 "configure"
7142 #include "confdefs.h"
7144 #include <libutf8.h>
7153 rm -f conftest.$ac_objext conftest$ac_exeext
7154 if { (eval echo "$as_me:7154: \"$ac_link\"") >&5
7155 (eval $ac_link) 2>&5
7157 echo "$as_me:7157: \$? = $ac_status" >&5
7158 (exit $ac_status); } &&
7159 { ac_try='test -s conftest$ac_exeext'
7160 { (eval echo "$as_me:7160: \"$ac_try\"") >&5
7163 echo "$as_me:7163: \$? = $ac_status" >&5
7164 (exit $ac_status); }; }; then
7166 cf_cv_find_linkage_utf8=yes
7167 cf_cv_header_path_utf8=/usr/include
7168 cf_cv_library_path_utf8=/usr/lib
7169 cf_cv_library_file_utf8="-lutf8"
7172 echo "$as_me: failed program was:" >&5
7173 cat conftest.$ac_ext >&5
7175 cf_cv_find_linkage_utf8=no
7176 LIBS="$cf_save_LIBS"
7178 test -n "$verbose" && echo " find linkage for utf8 library" 1>&6
7180 echo "${as_me:-configure}:7180: testing find linkage for utf8 library ..." 1>&5
7182 echo "${as_me:-configure}:7182: testing Searching for headers in FIND_LINKAGE(utf8,) ..." 1>&5
7184 cf_save_CPPFLAGS="$CPPFLAGS"
7185 cf_test_CPPFLAGS="$CPPFLAGS"
7189 # collect the current set of include-directories from compiler flags
7190 cf_header_path_list=""
7191 if test -n "${CFLAGS}${CPPFLAGS}" ; then
7192 for cf_header_path in $CPPFLAGS $CFLAGS
7194 case $cf_header_path in
7196 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
7198 test "x$cf_header_path" != "xNONE" && \
7199 test -d "$cf_header_path" && \
7201 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
7202 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
7203 test -d $cf_header_path/include/utf8 && cf_search="$cf_search $cf_header_path/include/utf8"
7204 test -d $cf_header_path/include/utf8/include && cf_search="$cf_search $cf_header_path/include/utf8/include"
7205 test -d $cf_header_path/utf8/include && cf_search="$cf_search $cf_header_path/utf8/include"
7206 test -d $cf_header_path/utf8/include/utf8 && cf_search="$cf_search $cf_header_path/utf8/include/utf8"
7209 cf_header_path_list="$cf_header_path_list $cf_search"
7215 # add the variations for the package we are looking for
7219 test "x$prefix" != "xNONE" && \
7220 test -d "$prefix" && \
7222 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
7223 test -d $prefix/include && cf_search="$cf_search $prefix/include"
7224 test -d $prefix/include/utf8 && cf_search="$cf_search $prefix/include/utf8"
7225 test -d $prefix/include/utf8/include && cf_search="$cf_search $prefix/include/utf8/include"
7226 test -d $prefix/utf8/include && cf_search="$cf_search $prefix/utf8/include"
7227 test -d $prefix/utf8/include/utf8 && cf_search="$cf_search $prefix/utf8/include/utf8"
7230 for cf_subdir_prefix in \
7239 test "x$cf_subdir_prefix" != "x$prefix" && \
7240 test -d "$cf_subdir_prefix" && \
7241 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
7242 test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
7243 test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include"
7244 test -d $cf_subdir_prefix/include/utf8 && cf_search="$cf_search $cf_subdir_prefix/include/utf8"
7245 test -d $cf_subdir_prefix/include/utf8/include && cf_search="$cf_search $cf_subdir_prefix/include/utf8/include"
7246 test -d $cf_subdir_prefix/utf8/include && cf_search="$cf_search $cf_subdir_prefix/utf8/include"
7247 test -d $cf_subdir_prefix/utf8/include/utf8 && cf_search="$cf_search $cf_subdir_prefix/utf8/include/utf8"
7252 test "$includedir" != NONE && \
7253 test "$includedir" != "/usr/include" && \
7254 test -d "$includedir" && {
7255 test -d $includedir && cf_search="$cf_search $includedir"
7256 test -d $includedir/utf8 && cf_search="$cf_search $includedir/utf8"
7259 test "$oldincludedir" != NONE && \
7260 test "$oldincludedir" != "/usr/include" && \
7261 test -d "$oldincludedir" && {
7262 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
7263 test -d $oldincludedir/utf8 && cf_search="$cf_search $oldincludedir/utf8"
7266 cf_search="$cf_search $cf_header_path_list"
7268 for cf_cv_header_path_utf8 in $cf_search
7270 if test -d $cf_cv_header_path_utf8 ; then
7271 test -n "$verbose" && echo " ... testing $cf_cv_header_path_utf8" 1>&6
7273 echo "${as_me:-configure}:7273: testing ... testing $cf_cv_header_path_utf8 ..." 1>&5
7275 CPPFLAGS="$cf_save_CPPFLAGS"
7277 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
7278 CPPFLAGS="${CPPFLAGS}-I$cf_cv_header_path_utf8"
7280 cat >conftest.$ac_ext <<_ACEOF
7281 #line 7281 "configure"
7282 #include "confdefs.h"
7284 #include <libutf8.h>
7293 rm -f conftest.$ac_objext
7294 if { (eval echo "$as_me:7294: \"$ac_compile\"") >&5
7295 (eval $ac_compile) 2>&5
7297 echo "$as_me:7297: \$? = $ac_status" >&5
7298 (exit $ac_status); } &&
7299 { ac_try='test -s conftest.$ac_objext'
7300 { (eval echo "$as_me:7300: \"$ac_try\"") >&5
7303 echo "$as_me:7303: \$? = $ac_status" >&5
7304 (exit $ac_status); }; }; then
7306 test -n "$verbose" && echo " ... found utf8 headers in $cf_cv_header_path_utf8" 1>&6
7308 echo "${as_me:-configure}:7308: testing ... found utf8 headers in $cf_cv_header_path_utf8 ..." 1>&5
7310 cf_cv_find_linkage_utf8=maybe
7311 cf_test_CPPFLAGS="$CPPFLAGS"
7314 echo "$as_me: failed program was:" >&5
7315 cat conftest.$ac_ext >&5
7317 CPPFLAGS="$cf_save_CPPFLAGS"
7320 rm -f conftest.$ac_objext conftest.$ac_ext
7324 if test "$cf_cv_find_linkage_utf8" = maybe ; then
7326 echo "${as_me:-configure}:7326: testing Searching for utf8 library in FIND_LINKAGE(utf8,) ..." 1>&5
7328 cf_save_LIBS="$LIBS"
7329 cf_save_LDFLAGS="$LDFLAGS"
7331 if test "$cf_cv_find_linkage_utf8" != yes ; then
7334 cf_library_path_list=""
7335 if test -n "${LDFLAGS}${LIBS}" ; then
7336 for cf_library_path in $LDFLAGS $LIBS
7338 case $cf_library_path in
7340 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
7342 test "x$cf_library_path" != "xNONE" && \
7343 test -d "$cf_library_path" && \
7345 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
7346 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
7347 test -d $cf_library_path/lib/utf8 && cf_search="$cf_search $cf_library_path/lib/utf8"
7348 test -d $cf_library_path/lib/utf8/lib && cf_search="$cf_search $cf_library_path/lib/utf8/lib"
7349 test -d $cf_library_path/utf8/lib && cf_search="$cf_search $cf_library_path/utf8/lib"
7350 test -d $cf_library_path/utf8/lib/utf8 && cf_search="$cf_search $cf_library_path/utf8/lib/utf8"
7353 cf_library_path_list="$cf_library_path_list $cf_search"
7361 test "x$prefix" != "xNONE" && \
7362 test -d "$prefix" && \
7364 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
7365 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
7366 test -d $prefix/lib/utf8 && cf_search="$cf_search $prefix/lib/utf8"
7367 test -d $prefix/lib/utf8/lib && cf_search="$cf_search $prefix/lib/utf8/lib"
7368 test -d $prefix/utf8/lib && cf_search="$cf_search $prefix/utf8/lib"
7369 test -d $prefix/utf8/lib/utf8 && cf_search="$cf_search $prefix/utf8/lib/utf8"
7372 for cf_subdir_prefix in \
7381 test "x$cf_subdir_prefix" != "x$prefix" && \
7382 test -d "$cf_subdir_prefix" && \
7383 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
7384 test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
7385 test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib"
7386 test -d $cf_subdir_prefix/lib/utf8 && cf_search="$cf_search $cf_subdir_prefix/lib/utf8"
7387 test -d $cf_subdir_prefix/lib/utf8/lib && cf_search="$cf_search $cf_subdir_prefix/lib/utf8/lib"
7388 test -d $cf_subdir_prefix/utf8/lib && cf_search="$cf_search $cf_subdir_prefix/utf8/lib"
7389 test -d $cf_subdir_prefix/utf8/lib/utf8 && cf_search="$cf_search $cf_subdir_prefix/utf8/lib/utf8"
7394 cf_search="$cf_library_path_list $cf_search"
7396 for cf_cv_library_path_utf8 in $cf_search
7398 if test -d $cf_cv_library_path_utf8 ; then
7399 test -n "$verbose" && echo " ... testing $cf_cv_library_path_utf8" 1>&6
7401 echo "${as_me:-configure}:7401: testing ... testing $cf_cv_library_path_utf8 ..." 1>&5
7403 CPPFLAGS="$cf_test_CPPFLAGS"
7404 LIBS="-lutf8 $cf_save_LIBS"
7405 LDFLAGS="$cf_save_LDFLAGS -L$cf_cv_library_path_utf8"
7406 cat >conftest.$ac_ext <<_ACEOF
7407 #line 7407 "configure"
7408 #include "confdefs.h"
7410 #include <libutf8.h>
7419 rm -f conftest.$ac_objext conftest$ac_exeext
7420 if { (eval echo "$as_me:7420: \"$ac_link\"") >&5
7421 (eval $ac_link) 2>&5
7423 echo "$as_me:7423: \$? = $ac_status" >&5
7424 (exit $ac_status); } &&
7425 { ac_try='test -s conftest$ac_exeext'
7426 { (eval echo "$as_me:7426: \"$ac_try\"") >&5
7429 echo "$as_me:7429: \$? = $ac_status" >&5
7430 (exit $ac_status); }; }; then
7432 test -n "$verbose" && echo " ... found utf8 library in $cf_cv_library_path_utf8" 1>&6
7434 echo "${as_me:-configure}:7434: testing ... found utf8 library in $cf_cv_library_path_utf8 ..." 1>&5
7436 cf_cv_find_linkage_utf8=yes
7437 cf_cv_library_file_utf8="-lutf8"
7440 echo "$as_me: failed program was:" >&5
7441 cat conftest.$ac_ext >&5
7443 CPPFLAGS="$cf_save_CPPFLAGS"
7444 LIBS="$cf_save_LIBS"
7445 LDFLAGS="$cf_save_LDFLAGS"
7448 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7451 CPPFLAGS="$cf_save_CPPFLAGS"
7452 LDFLAGS="$cf_save_LDFLAGS"
7456 cf_cv_find_linkage_utf8=no
7460 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7463 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7465 LIBS="$cf_save_LIBS"
7467 if test "$cf_cv_find_linkage_utf8" = yes ; then
7468 cf_cv_utf8_lib=add-on
7474 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7476 echo "$as_me:7476: result: $cf_cv_utf8_lib" >&5
7477 echo "${ECHO_T}$cf_cv_utf8_lib" >&6
7479 # HAVE_LIBUTF8_H is used by ncurses if curses.h is shared between
7481 if test "$cf_cv_utf8_lib" = "add-on" ; then
7483 cat >>confdefs.h <<\EOF
7484 #define HAVE_LIBUTF8_H 1
7487 if test -n "$cf_cv_header_path_utf8" ; then
7488 for cf_add_incdir in $cf_cv_header_path_utf8
7490 while test $cf_add_incdir != /usr/include
7492 if test -d $cf_add_incdir
7495 if test -n "$CFLAGS$CPPFLAGS" ; then
7496 # a loop is needed to ensure we can add subdirs of existing dirs
7497 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
7498 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
7499 cf_have_incdir=yes; break
7504 if test "$cf_have_incdir" = no ; then
7505 if test "$cf_add_incdir" = /usr/local/include ; then
7506 if test "$GCC" = yes
7508 cf_save_CPPFLAGS=$CPPFLAGS
7510 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
7511 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
7513 cat >conftest.$ac_ext <<_ACEOF
7514 #line 7514 "configure"
7515 #include "confdefs.h"
7525 rm -f conftest.$ac_objext
7526 if { (eval echo "$as_me:7526: \"$ac_compile\"") >&5
7527 (eval $ac_compile) 2>&5
7529 echo "$as_me:7529: \$? = $ac_status" >&5
7530 (exit $ac_status); } &&
7531 { ac_try='test -s conftest.$ac_objext'
7532 { (eval echo "$as_me:7532: \"$ac_try\"") >&5
7535 echo "$as_me:7535: \$? = $ac_status" >&5
7536 (exit $ac_status); }; }; then
7539 echo "$as_me: failed program was:" >&5
7540 cat conftest.$ac_ext >&5
7543 rm -f conftest.$ac_objext conftest.$ac_ext
7544 CPPFLAGS=$cf_save_CPPFLAGS
7549 if test "$cf_have_incdir" = no ; then
7550 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
7552 echo "${as_me:-configure}:7552: testing adding $cf_add_incdir to include-path ..." 1>&5
7554 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7556 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
7557 test "$cf_top_incdir" = "$cf_add_incdir" && break
7558 cf_add_incdir="$cf_top_incdir"
7569 if test -n "$cf_cv_library_path_utf8" ; then
7570 for cf_add_libdir in $cf_cv_library_path_utf8
7572 if test $cf_add_libdir = /usr/lib ; then
7574 elif test -d $cf_add_libdir
7577 if test -n "$LDFLAGS$LIBS" ; then
7578 # a loop is needed to ensure we can add subdirs of existing dirs
7579 for cf_test_libdir in $LDFLAGS $LIBS ; do
7580 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
7581 cf_have_libdir=yes; break
7585 if test "$cf_have_libdir" = no ; then
7586 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
7588 echo "${as_me:-configure}:7588: testing adding $cf_add_libdir to library-path ..." 1>&5
7590 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
7599 for cf_add_1lib in $cf_cv_library_file_utf8; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
7601 for cf_add_1lib in $cf_add_0lib; do
7602 for cf_add_2lib in $cf_add_libs; do
7603 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
7608 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
7614 cf_ncuconfig_root=$cf_cv_screen
7615 cf_have_ncuconfig=no
7617 if test "x${PKG_CONFIG:=none}" != xnone; then
7618 echo "$as_me:7618: checking pkg-config for $cf_ncuconfig_root" >&5
7619 echo $ECHO_N "checking pkg-config for $cf_ncuconfig_root... $ECHO_C" >&6
7620 if "$PKG_CONFIG" --exists $cf_ncuconfig_root ; then
7621 echo "$as_me:7621: result: yes" >&5
7622 echo "${ECHO_T}yes" >&6
7624 echo "$as_me:7624: checking if the $cf_ncuconfig_root package files work" >&5
7625 echo $ECHO_N "checking if the $cf_ncuconfig_root package files work... $ECHO_C" >&6
7626 cf_have_ncuconfig=unknown
7628 cf_save_CFLAGS="$CFLAGS"
7629 cf_save_CPPFLAGS="$CPPFLAGS"
7630 cf_save_LIBS="$LIBS"
7632 cf_pkg_cflags=`$PKG_CONFIG --cflags $cf_ncuconfig_root`
7633 cf_pkg_libs=`$PKG_CONFIG --libs $cf_ncuconfig_root`
7635 # while -W for passing linker flags is prevalent, it is not "standard".
7636 # At least one wrapper for c89/c99 (in Apple's xcode) has its own
7637 # incompatible _and_ non-standard -W option which gives an error. Work
7638 # around that pitfall.
7639 case "x${CC}@@${cf_pkg_libs}@${cf_pkg_cflags}" in
7645 cf_new_extra_cppflags=
7647 for cf_add_cflags in $cf_pkg_cflags
7649 case $cf_fix_cppflags in
7651 case $cf_add_cflags in
7652 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
7653 case $cf_add_cflags in
7655 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
7657 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
7658 && test -z "${cf_tst_cflags}" \
7659 && cf_fix_cppflags=yes
7661 if test $cf_fix_cppflags = yes ; then
7663 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
7664 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
7667 elif test "${cf_tst_cflags}" = "\"'" ; then
7669 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
7670 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
7680 case $cf_add_cflags in
7682 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
7684 CPPFLAGS=`echo "$CPPFLAGS" | \
7685 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
7686 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
7691 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
7692 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
7699 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
7700 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
7707 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
7708 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
7710 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
7712 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
7713 && test -z "${cf_tst_cflags}" \
7714 && cf_fix_cppflags=no
7719 if test -n "$cf_new_cflags" ; then
7721 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
7722 CFLAGS="${CFLAGS}$cf_new_cflags"
7726 if test -n "$cf_new_cppflags" ; then
7728 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
7729 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
7733 if test -n "$cf_new_extra_cppflags" ; then
7735 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
7736 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
7743 for cf_add_1lib in $cf_pkg_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
7745 for cf_add_1lib in $cf_add_0lib; do
7746 for cf_add_2lib in $cf_add_libs; do
7747 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
7752 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
7756 cat >conftest.$ac_ext <<_ACEOF
7757 #line 7757 "configure"
7758 #include "confdefs.h"
7759 #include <${cf_cv_ncurses_header:-curses.h}>
7763 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
7768 rm -f conftest.$ac_objext conftest$ac_exeext
7769 if { (eval echo "$as_me:7769: \"$ac_link\"") >&5
7770 (eval $ac_link) 2>&5
7772 echo "$as_me:7772: \$? = $ac_status" >&5
7773 (exit $ac_status); } &&
7774 { ac_try='test -s conftest$ac_exeext'
7775 { (eval echo "$as_me:7775: \"$ac_try\"") >&5
7778 echo "$as_me:7778: \$? = $ac_status" >&5
7779 (exit $ac_status); }; }; then
7780 if test "$cross_compiling" = yes; then
7781 cf_test_ncuconfig=maybe
7783 cat >conftest.$ac_ext <<_ACEOF
7784 #line 7784 "configure"
7785 #include "confdefs.h"
7786 #include <${cf_cv_ncurses_header:-curses.h}>
7788 { char *xx = curses_version(); return (xx == 0); }
7790 rm -f conftest$ac_exeext
7791 if { (eval echo "$as_me:7791: \"$ac_link\"") >&5
7792 (eval $ac_link) 2>&5
7794 echo "$as_me:7794: \$? = $ac_status" >&5
7795 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
7796 { (eval echo "$as_me:7796: \"$ac_try\"") >&5
7799 echo "$as_me:7799: \$? = $ac_status" >&5
7800 (exit $ac_status); }; }; then
7801 cf_test_ncuconfig=yes
7803 echo "$as_me: program exited with status $ac_status" >&5
7804 echo "$as_me: failed program was:" >&5
7805 cat conftest.$ac_ext >&5
7806 cf_test_ncuconfig=no
7808 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
7811 echo "$as_me: failed program was:" >&5
7812 cat conftest.$ac_ext >&5
7813 cf_test_ncuconfig=no
7815 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7817 CFLAGS="$cf_save_CFLAGS"
7818 CPPFLAGS="$cf_save_CPPFLAGS"
7819 LIBS="$cf_save_LIBS"
7821 if test "x$cf_test_ncuconfig" != xyes; then
7822 cf_temp=`echo "x$cf_pkg_cflags" | sed -e s/^x// -e 's/-W[^ ]*//g'`
7823 cf_pkg_cflags="$cf_temp"
7824 cf_temp=`echo "x$cf_pkg_libs" | sed -e s/^x// -e 's/-W[^ ]*//g'`
7825 cf_pkg_libs="$cf_temp"
7833 cf_new_extra_cppflags=
7835 for cf_add_cflags in $cf_pkg_cflags
7837 case $cf_fix_cppflags in
7839 case $cf_add_cflags in
7840 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
7841 case $cf_add_cflags in
7843 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
7845 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
7846 && test -z "${cf_tst_cflags}" \
7847 && cf_fix_cppflags=yes
7849 if test $cf_fix_cppflags = yes ; then
7851 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
7852 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
7855 elif test "${cf_tst_cflags}" = "\"'" ; then
7857 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
7858 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
7868 case $cf_add_cflags in
7870 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
7872 CPPFLAGS=`echo "$CPPFLAGS" | \
7873 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
7874 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
7879 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
7880 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
7887 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
7888 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
7895 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
7896 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
7898 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
7900 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
7901 && test -z "${cf_tst_cflags}" \
7902 && cf_fix_cppflags=no
7907 if test -n "$cf_new_cflags" ; then
7909 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
7910 CFLAGS="${CFLAGS}$cf_new_cflags"
7914 if test -n "$cf_new_cppflags" ; then
7916 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
7917 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
7921 if test -n "$cf_new_extra_cppflags" ; then
7923 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
7924 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
7931 for cf_add_1lib in $cf_pkg_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
7933 for cf_add_1lib in $cf_add_0lib; do
7934 for cf_add_2lib in $cf_add_libs; do
7935 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
7940 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
7944 cat >conftest.$ac_ext <<_ACEOF
7945 #line 7945 "configure"
7946 #include "confdefs.h"
7947 #include <${cf_cv_ncurses_header:-curses.h}>
7951 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
7956 rm -f conftest.$ac_objext conftest$ac_exeext
7957 if { (eval echo "$as_me:7957: \"$ac_link\"") >&5
7958 (eval $ac_link) 2>&5
7960 echo "$as_me:7960: \$? = $ac_status" >&5
7961 (exit $ac_status); } &&
7962 { ac_try='test -s conftest$ac_exeext'
7963 { (eval echo "$as_me:7963: \"$ac_try\"") >&5
7966 echo "$as_me:7966: \$? = $ac_status" >&5
7967 (exit $ac_status); }; }; then
7968 if test "$cross_compiling" = yes; then
7969 cf_have_ncuconfig=maybe
7971 cat >conftest.$ac_ext <<_ACEOF
7972 #line 7972 "configure"
7973 #include "confdefs.h"
7974 #include <${cf_cv_ncurses_header:-curses.h}>
7976 { char *xx = curses_version(); return (xx == 0); }
7978 rm -f conftest$ac_exeext
7979 if { (eval echo "$as_me:7979: \"$ac_link\"") >&5
7980 (eval $ac_link) 2>&5
7982 echo "$as_me:7982: \$? = $ac_status" >&5
7983 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
7984 { (eval echo "$as_me:7984: \"$ac_try\"") >&5
7987 echo "$as_me:7987: \$? = $ac_status" >&5
7988 (exit $ac_status); }; }; then
7989 cf_have_ncuconfig=yes
7991 echo "$as_me: program exited with status $ac_status" >&5
7992 echo "$as_me: failed program was:" >&5
7993 cat conftest.$ac_ext >&5
7994 cf_have_ncuconfig=no
7996 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
7999 echo "$as_me: failed program was:" >&5
8000 cat conftest.$ac_ext >&5
8001 cf_have_ncuconfig=no
8003 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8004 echo "$as_me:8004: result: $cf_have_ncuconfig" >&5
8005 echo "${ECHO_T}$cf_have_ncuconfig" >&6
8006 test "$cf_have_ncuconfig" = maybe && cf_have_ncuconfig=yes
8007 if test "$cf_have_ncuconfig" != "yes"
8009 CPPFLAGS="$cf_save_CPPFLAGS"
8010 LIBS="$cf_save_LIBS"
8011 NCURSES_CONFIG_PKG=none
8014 cat >>confdefs.h <<\EOF
8018 NCURSES_CONFIG_PKG=$cf_ncuconfig_root
8020 echo "$as_me:8020: checking for terminfo header" >&5
8021 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
8022 if test "${cf_cv_term_header+set}" = set; then
8023 echo $ECHO_N "(cached) $ECHO_C" >&6
8026 case ${cf_cv_ncurses_header} in
8027 (*/ncurses.h|*/ncursesw.h)
8028 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
8031 cf_term_header=term.h
8035 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
8037 cat >conftest.$ac_ext <<_ACEOF
8038 #line 8038 "configure"
8039 #include "confdefs.h"
8041 #include <${cf_cv_ncurses_header:-curses.h}>
8047 int x = auto_left_margin; (void)x
8052 rm -f conftest.$ac_objext
8053 if { (eval echo "$as_me:8053: \"$ac_compile\"") >&5
8054 (eval $ac_compile) 2>&5
8056 echo "$as_me:8056: \$? = $ac_status" >&5
8057 (exit $ac_status); } &&
8058 { ac_try='test -s conftest.$ac_objext'
8059 { (eval echo "$as_me:8059: \"$ac_try\"") >&5
8062 echo "$as_me:8062: \$? = $ac_status" >&5
8063 (exit $ac_status); }; }; then
8065 cf_cv_term_header="$cf_test"
8067 echo "$as_me: failed program was:" >&5
8068 cat conftest.$ac_ext >&5
8070 cf_cv_term_header=unknown
8073 rm -f conftest.$ac_objext conftest.$ac_ext
8074 test "$cf_cv_term_header" != unknown && break
8078 echo "$as_me:8078: result: $cf_cv_term_header" >&5
8079 echo "${ECHO_T}$cf_cv_term_header" >&6
8081 # Set definitions to allow ifdef'ing to accommodate subdirectories
8083 case $cf_cv_term_header in
8086 cat >>confdefs.h <<\EOF
8087 #define HAVE_TERM_H 1
8093 case $cf_cv_term_header in
8096 cat >>confdefs.h <<\EOF
8097 #define HAVE_NCURSES_TERM_H 1
8103 cat >>confdefs.h <<\EOF
8104 #define HAVE_NCURSESW_TERM_H 1
8113 echo "$as_me:8113: result: no" >&5
8114 echo "${ECHO_T}no" >&6
8115 NCURSES_CONFIG_PKG=none
8118 NCURSES_CONFIG_PKG=none
8121 if test "x$cf_have_ncuconfig" = "xno"; then
8122 cf_ncurses_config="${cf_ncuconfig_root}${NCURSES_CONFIG_SUFFIX}-config"; echo "Looking for ${cf_ncurses_config}"
8124 if test -n "$ac_tool_prefix"; then
8125 for ac_prog in ${cf_ncurses_config} ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
8127 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
8128 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
8129 echo "$as_me:8129: checking for $ac_word" >&5
8130 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
8131 if test "${ac_cv_prog_NCURSES_CONFIG+set}" = set; then
8132 echo $ECHO_N "(cached) $ECHO_C" >&6
8134 if test -n "$NCURSES_CONFIG"; then
8135 ac_cv_prog_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test.
8137 ac_save_IFS=$IFS; IFS=$ac_path_separator
8139 for ac_dir in $ac_dummy; do
8141 test -z "$ac_dir" && ac_dir=.
8142 $as_executable_p "$ac_dir/$ac_word" || continue
8143 ac_cv_prog_NCURSES_CONFIG="$ac_tool_prefix$ac_prog"
8144 echo "$as_me:8144: found $ac_dir/$ac_word" >&5
8150 NCURSES_CONFIG=$ac_cv_prog_NCURSES_CONFIG
8151 if test -n "$NCURSES_CONFIG"; then
8152 echo "$as_me:8152: result: $NCURSES_CONFIG" >&5
8153 echo "${ECHO_T}$NCURSES_CONFIG" >&6
8155 echo "$as_me:8155: result: no" >&5
8156 echo "${ECHO_T}no" >&6
8159 test -n "$NCURSES_CONFIG" && break
8162 if test -z "$NCURSES_CONFIG"; then
8163 ac_ct_NCURSES_CONFIG=$NCURSES_CONFIG
8164 for ac_prog in ${cf_ncurses_config} ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
8166 # Extract the first word of "$ac_prog", so it can be a program name with args.
8167 set dummy $ac_prog; ac_word=$2
8168 echo "$as_me:8168: checking for $ac_word" >&5
8169 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
8170 if test "${ac_cv_prog_ac_ct_NCURSES_CONFIG+set}" = set; then
8171 echo $ECHO_N "(cached) $ECHO_C" >&6
8173 if test -n "$ac_ct_NCURSES_CONFIG"; then
8174 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_ct_NCURSES_CONFIG" # Let the user override the test.
8176 ac_save_IFS=$IFS; IFS=$ac_path_separator
8178 for ac_dir in $ac_dummy; do
8180 test -z "$ac_dir" && ac_dir=.
8181 $as_executable_p "$ac_dir/$ac_word" || continue
8182 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_prog"
8183 echo "$as_me:8183: found $ac_dir/$ac_word" >&5
8189 ac_ct_NCURSES_CONFIG=$ac_cv_prog_ac_ct_NCURSES_CONFIG
8190 if test -n "$ac_ct_NCURSES_CONFIG"; then
8191 echo "$as_me:8191: result: $ac_ct_NCURSES_CONFIG" >&5
8192 echo "${ECHO_T}$ac_ct_NCURSES_CONFIG" >&6
8194 echo "$as_me:8194: result: no" >&5
8195 echo "${ECHO_T}no" >&6
8198 test -n "$ac_ct_NCURSES_CONFIG" && break
8200 test -n "$ac_ct_NCURSES_CONFIG" || ac_ct_NCURSES_CONFIG="none"
8202 NCURSES_CONFIG=$ac_ct_NCURSES_CONFIG
8205 if test "$NCURSES_CONFIG" != none ; then
8210 cf_new_extra_cppflags=
8212 for cf_add_cflags in `$NCURSES_CONFIG --cflags`
8214 case $cf_fix_cppflags in
8216 case $cf_add_cflags in
8217 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
8218 case $cf_add_cflags in
8220 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
8222 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
8223 && test -z "${cf_tst_cflags}" \
8224 && cf_fix_cppflags=yes
8226 if test $cf_fix_cppflags = yes ; then
8228 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
8229 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
8232 elif test "${cf_tst_cflags}" = "\"'" ; then
8234 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
8235 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
8245 case $cf_add_cflags in
8247 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
8249 CPPFLAGS=`echo "$CPPFLAGS" | \
8250 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
8251 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
8256 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
8257 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
8264 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
8265 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
8272 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
8273 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
8275 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
8277 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
8278 && test -z "${cf_tst_cflags}" \
8279 && cf_fix_cppflags=no
8284 if test -n "$cf_new_cflags" ; then
8286 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
8287 CFLAGS="${CFLAGS}$cf_new_cflags"
8291 if test -n "$cf_new_cppflags" ; then
8293 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
8294 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
8298 if test -n "$cf_new_extra_cppflags" ; then
8300 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
8301 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
8308 for cf_add_1lib in `$NCURSES_CONFIG --libs`; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
8310 for cf_add_1lib in $cf_add_0lib; do
8311 for cf_add_2lib in $cf_add_libs; do
8312 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
8317 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
8321 # even with config script, some packages use no-override for curses.h
8323 echo "$as_me:8323: checking if we have identified curses headers" >&5
8324 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
8325 if test "${cf_cv_ncurses_header+set}" = set; then
8326 echo $ECHO_N "(cached) $ECHO_C" >&6
8329 cf_cv_ncurses_header=none
8331 ncurses.h $cf_cv_screen/ncurses.h \
8332 curses.h $cf_cv_screen/curses.h
8334 cat >conftest.$ac_ext <<_ACEOF
8335 #line 8335 "configure"
8336 #include "confdefs.h"
8337 #include <${cf_header}>
8341 initscr(); tgoto("?", 0,0)
8346 rm -f conftest.$ac_objext
8347 if { (eval echo "$as_me:8347: \"$ac_compile\"") >&5
8348 (eval $ac_compile) 2>&5
8350 echo "$as_me:8350: \$? = $ac_status" >&5
8351 (exit $ac_status); } &&
8352 { ac_try='test -s conftest.$ac_objext'
8353 { (eval echo "$as_me:8353: \"$ac_try\"") >&5
8356 echo "$as_me:8356: \$? = $ac_status" >&5
8357 (exit $ac_status); }; }; then
8358 cf_cv_ncurses_header=$cf_header; break
8360 echo "$as_me: failed program was:" >&5
8361 cat conftest.$ac_ext >&5
8363 rm -f conftest.$ac_objext conftest.$ac_ext
8367 echo "$as_me:8367: result: $cf_cv_ncurses_header" >&5
8368 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
8370 if test "$cf_cv_ncurses_header" = none ; then
8371 { { echo "$as_me:8371: error: No curses header-files found" >&5
8372 echo "$as_me: error: No curses header-files found" >&2;}
8373 { (exit 1); exit 1; }; }
8376 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
8378 for ac_header in $cf_cv_ncurses_header
8380 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8381 echo "$as_me:8381: checking for $ac_header" >&5
8382 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8383 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8384 echo $ECHO_N "(cached) $ECHO_C" >&6
8386 cat >conftest.$ac_ext <<_ACEOF
8387 #line 8387 "configure"
8388 #include "confdefs.h"
8389 #include <$ac_header>
8391 if { (eval echo "$as_me:8391: \"$ac_cpp conftest.$ac_ext\"") >&5
8392 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8394 egrep -v '^ *\+' conftest.er1 >conftest.err
8396 cat conftest.err >&5
8397 echo "$as_me:8397: \$? = $ac_status" >&5
8398 (exit $ac_status); } >/dev/null; then
8399 if test -s conftest.err; then
8400 ac_cpp_err=$ac_c_preproc_warn_flag
8407 if test -z "$ac_cpp_err"; then
8408 eval "$as_ac_Header=yes"
8410 echo "$as_me: failed program was:" >&5
8411 cat conftest.$ac_ext >&5
8412 eval "$as_ac_Header=no"
8414 rm -f conftest.err conftest.$ac_ext
8416 echo "$as_me:8416: result: `eval echo '${'$as_ac_Header'}'`" >&5
8417 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8418 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8419 cat >>confdefs.h <<EOF
8420 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8426 cat >>confdefs.h <<\EOF
8430 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
8432 cat >>confdefs.h <<EOF
8433 #define $cf_nculib_ROOT 1
8436 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
8440 cf_ncuhdr_root=$cf_cv_screen
8442 test -n "$cf_cv_curses_dir" && \
8443 test "$cf_cv_curses_dir" != "no" && { \
8445 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
8446 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
8448 while test $cf_add_incdir != /usr/include
8450 if test -d $cf_add_incdir
8453 if test -n "$CFLAGS$CPPFLAGS" ; then
8454 # a loop is needed to ensure we can add subdirs of existing dirs
8455 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
8456 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
8457 cf_have_incdir=yes; break
8462 if test "$cf_have_incdir" = no ; then
8463 if test "$cf_add_incdir" = /usr/local/include ; then
8464 if test "$GCC" = yes
8466 cf_save_CPPFLAGS=$CPPFLAGS
8468 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
8469 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
8471 cat >conftest.$ac_ext <<_ACEOF
8472 #line 8472 "configure"
8473 #include "confdefs.h"
8483 rm -f conftest.$ac_objext
8484 if { (eval echo "$as_me:8484: \"$ac_compile\"") >&5
8485 (eval $ac_compile) 2>&5
8487 echo "$as_me:8487: \$? = $ac_status" >&5
8488 (exit $ac_status); } &&
8489 { ac_try='test -s conftest.$ac_objext'
8490 { (eval echo "$as_me:8490: \"$ac_try\"") >&5
8493 echo "$as_me:8493: \$? = $ac_status" >&5
8494 (exit $ac_status); }; }; then
8497 echo "$as_me: failed program was:" >&5
8498 cat conftest.$ac_ext >&5
8501 rm -f conftest.$ac_objext conftest.$ac_ext
8502 CPPFLAGS=$cf_save_CPPFLAGS
8507 if test "$cf_have_incdir" = no ; then
8508 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
8510 echo "${as_me:-configure}:8510: testing adding $cf_add_incdir to include-path ..." 1>&5
8512 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8514 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
8515 test "$cf_top_incdir" = "$cf_add_incdir" && break
8516 cf_add_incdir="$cf_top_incdir"
8529 echo "$as_me:8529: checking for $cf_ncuhdr_root header in include-path" >&5
8530 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
8531 if test "${cf_cv_ncurses_h+set}" = set; then
8532 echo $ECHO_N "(cached) $ECHO_C" >&6
8535 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
8536 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
8537 for cf_header in $cf_header_list
8540 cat >conftest.$ac_ext <<_ACEOF
8541 #line 8541 "configure"
8542 #include "confdefs.h"
8544 #include <$cf_header>
8549 #ifdef NCURSES_VERSION
8551 printf("%s\n", NCURSES_VERSION);
8564 rm -f conftest.$ac_objext
8565 if { (eval echo "$as_me:8565: \"$ac_compile\"") >&5
8566 (eval $ac_compile) 2>&5
8568 echo "$as_me:8568: \$? = $ac_status" >&5
8569 (exit $ac_status); } &&
8570 { ac_try='test -s conftest.$ac_objext'
8571 { (eval echo "$as_me:8571: \"$ac_try\"") >&5
8574 echo "$as_me:8574: \$? = $ac_status" >&5
8575 (exit $ac_status); }; }; then
8576 cf_cv_ncurses_h=$cf_header
8579 echo "$as_me: failed program was:" >&5
8580 cat conftest.$ac_ext >&5
8583 rm -f conftest.$ac_objext conftest.$ac_ext
8585 test "$cf_cv_ncurses_h" != no && break
8589 echo "$as_me:8589: result: $cf_cv_ncurses_h" >&5
8590 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
8592 if test "$cf_cv_ncurses_h" != no ; then
8593 cf_cv_ncurses_header=$cf_cv_ncurses_h
8596 echo "$as_me:8596: checking for $cf_ncuhdr_root include-path" >&5
8597 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
8598 if test "${cf_cv_ncurses_h2+set}" = set; then
8599 echo $ECHO_N "(cached) $ECHO_C" >&6
8602 test -n "$verbose" && echo
8606 # collect the current set of include-directories from compiler flags
8607 cf_header_path_list=""
8608 if test -n "${CFLAGS}${CPPFLAGS}" ; then
8609 for cf_header_path in $CPPFLAGS $CFLAGS
8611 case $cf_header_path in
8613 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
8615 test "x$cf_header_path" != "xNONE" && \
8616 test -d "$cf_header_path" && \
8618 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
8619 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
8620 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
8621 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
8622 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
8623 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"
8626 cf_header_path_list="$cf_header_path_list $cf_search"
8632 # add the variations for the package we are looking for
8636 test "x$prefix" != "xNONE" && \
8637 test -d "$prefix" && \
8639 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
8640 test -d $prefix/include && cf_search="$cf_search $prefix/include"
8641 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
8642 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
8643 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
8644 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
8647 for cf_subdir_prefix in \
8656 test "x$cf_subdir_prefix" != "x$prefix" && \
8657 test -d "$cf_subdir_prefix" && \
8658 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
8659 test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
8660 test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include"
8661 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root"
8662 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root/include"
8663 test -d $cf_subdir_prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include"
8664 test -d $cf_subdir_prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
8669 test "$includedir" != NONE && \
8670 test "$includedir" != "/usr/include" && \
8671 test -d "$includedir" && {
8672 test -d $includedir && cf_search="$cf_search $includedir"
8673 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
8676 test "$oldincludedir" != NONE && \
8677 test "$oldincludedir" != "/usr/include" && \
8678 test -d "$oldincludedir" && {
8679 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
8680 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
8683 cf_search="$cf_search $cf_header_path_list"
8685 test -n "$verbose" && echo search path $cf_search
8686 cf_save2_CPPFLAGS="$CPPFLAGS"
8687 for cf_incdir in $cf_search
8690 if test -n "$cf_incdir" ; then
8691 for cf_add_incdir in $cf_incdir
8693 while test $cf_add_incdir != /usr/include
8695 if test -d $cf_add_incdir
8698 if test -n "$CFLAGS$CPPFLAGS" ; then
8699 # a loop is needed to ensure we can add subdirs of existing dirs
8700 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
8701 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
8702 cf_have_incdir=yes; break
8707 if test "$cf_have_incdir" = no ; then
8708 if test "$cf_add_incdir" = /usr/local/include ; then
8709 if test "$GCC" = yes
8711 cf_save_CPPFLAGS=$CPPFLAGS
8713 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
8714 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
8716 cat >conftest.$ac_ext <<_ACEOF
8717 #line 8717 "configure"
8718 #include "confdefs.h"
8728 rm -f conftest.$ac_objext
8729 if { (eval echo "$as_me:8729: \"$ac_compile\"") >&5
8730 (eval $ac_compile) 2>&5
8732 echo "$as_me:8732: \$? = $ac_status" >&5
8733 (exit $ac_status); } &&
8734 { ac_try='test -s conftest.$ac_objext'
8735 { (eval echo "$as_me:8735: \"$ac_try\"") >&5
8738 echo "$as_me:8738: \$? = $ac_status" >&5
8739 (exit $ac_status); }; }; then
8742 echo "$as_me: failed program was:" >&5
8743 cat conftest.$ac_ext >&5
8746 rm -f conftest.$ac_objext conftest.$ac_ext
8747 CPPFLAGS=$cf_save_CPPFLAGS
8752 if test "$cf_have_incdir" = no ; then
8753 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
8755 echo "${as_me:-configure}:8755: testing adding $cf_add_incdir to include-path ..." 1>&5
8757 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8759 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
8760 test "$cf_top_incdir" = "$cf_add_incdir" && break
8761 cf_add_incdir="$cf_top_incdir"
8777 cat >conftest.$ac_ext <<_ACEOF
8778 #line 8778 "configure"
8779 #include "confdefs.h"
8781 #include <$cf_header>
8786 #ifdef NCURSES_VERSION
8788 printf("%s\n", NCURSES_VERSION);
8801 rm -f conftest.$ac_objext
8802 if { (eval echo "$as_me:8802: \"$ac_compile\"") >&5
8803 (eval $ac_compile) 2>&5
8805 echo "$as_me:8805: \$? = $ac_status" >&5
8806 (exit $ac_status); } &&
8807 { ac_try='test -s conftest.$ac_objext'
8808 { (eval echo "$as_me:8808: \"$ac_try\"") >&5
8811 echo "$as_me:8811: \$? = $ac_status" >&5
8812 (exit $ac_status); }; }; then
8813 cf_cv_ncurses_h2=$cf_header
8816 echo "$as_me: failed program was:" >&5
8817 cat conftest.$ac_ext >&5
8820 rm -f conftest.$ac_objext conftest.$ac_ext
8822 if test "$cf_cv_ncurses_h2" != no ; then
8823 cf_cv_ncurses_h2=$cf_incdir/$cf_header
8824 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
8827 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
8829 CPPFLAGS="$cf_save2_CPPFLAGS"
8830 test "$cf_cv_ncurses_h2" != no && break
8832 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:8832: error: not found" >&5
8833 echo "$as_me: error: not found" >&2;}
8834 { (exit 1); exit 1; }; }
8837 echo "$as_me:8837: result: $cf_cv_ncurses_h2" >&5
8838 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
8840 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
8841 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
8842 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
8843 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
8846 if test -n "$cf_1st_incdir" ; then
8847 for cf_add_incdir in $cf_1st_incdir
8849 while test $cf_add_incdir != /usr/include
8851 if test -d $cf_add_incdir
8854 if test -n "$CFLAGS$CPPFLAGS" ; then
8855 # a loop is needed to ensure we can add subdirs of existing dirs
8856 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
8857 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
8858 cf_have_incdir=yes; break
8863 if test "$cf_have_incdir" = no ; then
8864 if test "$cf_add_incdir" = /usr/local/include ; then
8865 if test "$GCC" = yes
8867 cf_save_CPPFLAGS=$CPPFLAGS
8869 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
8870 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
8872 cat >conftest.$ac_ext <<_ACEOF
8873 #line 8873 "configure"
8874 #include "confdefs.h"
8884 rm -f conftest.$ac_objext
8885 if { (eval echo "$as_me:8885: \"$ac_compile\"") >&5
8886 (eval $ac_compile) 2>&5
8888 echo "$as_me:8888: \$? = $ac_status" >&5
8889 (exit $ac_status); } &&
8890 { ac_try='test -s conftest.$ac_objext'
8891 { (eval echo "$as_me:8891: \"$ac_try\"") >&5
8894 echo "$as_me:8894: \$? = $ac_status" >&5
8895 (exit $ac_status); }; }; then
8898 echo "$as_me: failed program was:" >&5
8899 cat conftest.$ac_ext >&5
8902 rm -f conftest.$ac_objext conftest.$ac_ext
8903 CPPFLAGS=$cf_save_CPPFLAGS
8908 if test "$cf_have_incdir" = no ; then
8909 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
8911 echo "${as_me:-configure}:8911: testing adding $cf_add_incdir to include-path ..." 1>&5
8913 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8915 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
8916 test "$cf_top_incdir" = "$cf_add_incdir" && break
8917 cf_add_incdir="$cf_top_incdir"
8930 # Set definitions to allow ifdef'ing for ncurses.h
8932 case $cf_cv_ncurses_header in
8935 cat >>confdefs.h <<\EOF
8936 #define HAVE_NCURSES_H 1
8942 case $cf_cv_ncurses_header in
8943 (ncurses/curses.h|ncurses/ncurses.h)
8945 cat >>confdefs.h <<\EOF
8946 #define HAVE_NCURSES_NCURSES_H 1
8950 (ncursesw/curses.h|ncursesw/ncurses.h)
8952 cat >>confdefs.h <<\EOF
8953 #define HAVE_NCURSESW_NCURSES_H 1
8959 echo "$as_me:8959: checking for terminfo header" >&5
8960 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
8961 if test "${cf_cv_term_header+set}" = set; then
8962 echo $ECHO_N "(cached) $ECHO_C" >&6
8965 case ${cf_cv_ncurses_header} in
8966 (*/ncurses.h|*/ncursesw.h)
8967 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
8970 cf_term_header=term.h
8974 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
8976 cat >conftest.$ac_ext <<_ACEOF
8977 #line 8977 "configure"
8978 #include "confdefs.h"
8980 #include <${cf_cv_ncurses_header:-curses.h}>
8986 int x = auto_left_margin; (void)x
8991 rm -f conftest.$ac_objext
8992 if { (eval echo "$as_me:8992: \"$ac_compile\"") >&5
8993 (eval $ac_compile) 2>&5
8995 echo "$as_me:8995: \$? = $ac_status" >&5
8996 (exit $ac_status); } &&
8997 { ac_try='test -s conftest.$ac_objext'
8998 { (eval echo "$as_me:8998: \"$ac_try\"") >&5
9001 echo "$as_me:9001: \$? = $ac_status" >&5
9002 (exit $ac_status); }; }; then
9004 cf_cv_term_header="$cf_test"
9006 echo "$as_me: failed program was:" >&5
9007 cat conftest.$ac_ext >&5
9009 cf_cv_term_header=unknown
9012 rm -f conftest.$ac_objext conftest.$ac_ext
9013 test "$cf_cv_term_header" != unknown && break
9017 echo "$as_me:9017: result: $cf_cv_term_header" >&5
9018 echo "${ECHO_T}$cf_cv_term_header" >&6
9020 # Set definitions to allow ifdef'ing to accommodate subdirectories
9022 case $cf_cv_term_header in
9025 cat >>confdefs.h <<\EOF
9026 #define HAVE_TERM_H 1
9032 case $cf_cv_term_header in
9035 cat >>confdefs.h <<\EOF
9036 #define HAVE_NCURSES_TERM_H 1
9042 cat >>confdefs.h <<\EOF
9043 #define HAVE_NCURSESW_TERM_H 1
9049 # some applications need this, but should check for NCURSES_VERSION
9051 cat >>confdefs.h <<\EOF
9055 echo "$as_me:9055: checking for ncurses version" >&5
9056 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
9057 if test "${cf_cv_ncurses_version+set}" = set; then
9058 echo $ECHO_N "(cached) $ECHO_C" >&6
9061 cf_cv_ncurses_version=no
9064 if test "$cross_compiling" = yes; then
9066 # This will not work if the preprocessor splits the line after the
9067 # Autoconf token. The 'unproto' program does that.
9068 cat > conftest.$ac_ext <<EOF
9069 #include <${cf_cv_ncurses_header:-curses.h}>
9071 #ifdef NCURSES_VERSION
9072 Autoconf NCURSES_VERSION
9080 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
9081 { (eval echo "$as_me:9081: \"$cf_try\"") >&5
9084 echo "$as_me:9084: \$? = $ac_status" >&5
9085 (exit $ac_status); }
9086 if test -f conftest.out ; then
9087 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
9088 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
9093 cat >conftest.$ac_ext <<_ACEOF
9094 #line 9094 "configure"
9095 #include "confdefs.h"
9097 #include <${cf_cv_ncurses_header:-curses.h}>
9101 FILE *fp = fopen("$cf_tempfile", "w");
9102 #ifdef NCURSES_VERSION
9103 # ifdef NCURSES_VERSION_PATCH
9104 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
9106 fprintf(fp, "%s\n", NCURSES_VERSION);
9110 fprintf(fp, "old\n");
9115 ${cf_cv_main_return:-return}(0);
9118 rm -f conftest$ac_exeext
9119 if { (eval echo "$as_me:9119: \"$ac_link\"") >&5
9120 (eval $ac_link) 2>&5
9122 echo "$as_me:9122: \$? = $ac_status" >&5
9123 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
9124 { (eval echo "$as_me:9124: \"$ac_try\"") >&5
9127 echo "$as_me:9127: \$? = $ac_status" >&5
9128 (exit $ac_status); }; }; then
9130 cf_cv_ncurses_version=`cat $cf_tempfile`
9132 echo "$as_me: program exited with status $ac_status" >&5
9133 echo "$as_me: failed program was:" >&5
9134 cat conftest.$ac_ext >&5
9136 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
9141 echo "$as_me:9141: result: $cf_cv_ncurses_version" >&5
9142 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
9143 test "$cf_cv_ncurses_version" = no ||
9144 cat >>confdefs.h <<\EOF
9148 cf_nculib_root=$cf_cv_screen
9149 # This works, except for the special case where we find gpm, but
9150 # ncurses is in a nonstandard location via $LIBS, and we really want
9153 cf_ncurses_SAVE="$LIBS"
9154 echo "$as_me:9154: checking for Gpm_Open in -lgpm" >&5
9155 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
9156 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
9157 echo $ECHO_N "(cached) $ECHO_C" >&6
9159 ac_check_lib_save_LIBS=$LIBS
9161 cat >conftest.$ac_ext <<_ACEOF
9162 #line 9162 "configure"
9163 #include "confdefs.h"
9165 /* Override any gcc2 internal prototype to avoid an error. */
9169 /* We use char because int might match the return type of a gcc2
9170 builtin and then its argument prototype would still apply. */
9180 rm -f conftest.$ac_objext conftest$ac_exeext
9181 if { (eval echo "$as_me:9181: \"$ac_link\"") >&5
9182 (eval $ac_link) 2>&5
9184 echo "$as_me:9184: \$? = $ac_status" >&5
9185 (exit $ac_status); } &&
9186 { ac_try='test -s conftest$ac_exeext'
9187 { (eval echo "$as_me:9187: \"$ac_try\"") >&5
9190 echo "$as_me:9190: \$? = $ac_status" >&5
9191 (exit $ac_status); }; }; then
9192 ac_cv_lib_gpm_Gpm_Open=yes
9194 echo "$as_me: failed program was:" >&5
9195 cat conftest.$ac_ext >&5
9196 ac_cv_lib_gpm_Gpm_Open=no
9198 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9199 LIBS=$ac_check_lib_save_LIBS
9201 echo "$as_me:9201: result: $ac_cv_lib_gpm_Gpm_Open" >&5
9202 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
9203 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
9204 echo "$as_me:9204: checking for initscr in -lgpm" >&5
9205 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
9206 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
9207 echo $ECHO_N "(cached) $ECHO_C" >&6
9209 ac_check_lib_save_LIBS=$LIBS
9211 cat >conftest.$ac_ext <<_ACEOF
9212 #line 9212 "configure"
9213 #include "confdefs.h"
9215 /* Override any gcc2 internal prototype to avoid an error. */
9219 /* We use char because int might match the return type of a gcc2
9220 builtin and then its argument prototype would still apply. */
9230 rm -f conftest.$ac_objext conftest$ac_exeext
9231 if { (eval echo "$as_me:9231: \"$ac_link\"") >&5
9232 (eval $ac_link) 2>&5
9234 echo "$as_me:9234: \$? = $ac_status" >&5
9235 (exit $ac_status); } &&
9236 { ac_try='test -s conftest$ac_exeext'
9237 { (eval echo "$as_me:9237: \"$ac_try\"") >&5
9240 echo "$as_me:9240: \$? = $ac_status" >&5
9241 (exit $ac_status); }; }; then
9242 ac_cv_lib_gpm_initscr=yes
9244 echo "$as_me: failed program was:" >&5
9245 cat conftest.$ac_ext >&5
9246 ac_cv_lib_gpm_initscr=no
9248 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9249 LIBS=$ac_check_lib_save_LIBS
9251 echo "$as_me:9251: result: $ac_cv_lib_gpm_initscr" >&5
9252 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
9253 if test $ac_cv_lib_gpm_initscr = yes; then
9254 LIBS="$cf_ncurses_SAVE"
9256 cf_ncurses_LIBS="-lgpm"
9263 # This is only necessary if you are linking against an obsolete
9264 # version of ncurses (but it should do no harm, since it's static).
9265 if test "$cf_nculib_root" = ncurses ; then
9266 echo "$as_me:9266: checking for tgoto in -lmytinfo" >&5
9267 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
9268 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
9269 echo $ECHO_N "(cached) $ECHO_C" >&6
9271 ac_check_lib_save_LIBS=$LIBS
9272 LIBS="-lmytinfo $LIBS"
9273 cat >conftest.$ac_ext <<_ACEOF
9274 #line 9274 "configure"
9275 #include "confdefs.h"
9277 /* Override any gcc2 internal prototype to avoid an error. */
9281 /* We use char because int might match the return type of a gcc2
9282 builtin and then its argument prototype would still apply. */
9292 rm -f conftest.$ac_objext conftest$ac_exeext
9293 if { (eval echo "$as_me:9293: \"$ac_link\"") >&5
9294 (eval $ac_link) 2>&5
9296 echo "$as_me:9296: \$? = $ac_status" >&5
9297 (exit $ac_status); } &&
9298 { ac_try='test -s conftest$ac_exeext'
9299 { (eval echo "$as_me:9299: \"$ac_try\"") >&5
9302 echo "$as_me:9302: \$? = $ac_status" >&5
9303 (exit $ac_status); }; }; then
9304 ac_cv_lib_mytinfo_tgoto=yes
9306 echo "$as_me: failed program was:" >&5
9307 cat conftest.$ac_ext >&5
9308 ac_cv_lib_mytinfo_tgoto=no
9310 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9311 LIBS=$ac_check_lib_save_LIBS
9313 echo "$as_me:9313: result: $ac_cv_lib_mytinfo_tgoto" >&5
9314 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
9315 if test $ac_cv_lib_mytinfo_tgoto = yes; then
9316 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
9326 for cf_add_1lib in $cf_ncurses_LIBS; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
9328 for cf_add_1lib in $cf_add_0lib; do
9329 for cf_add_2lib in $cf_add_libs; do
9330 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
9335 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
9339 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
9345 for cf_add_1lib in -l$cf_nculib_root; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
9347 for cf_add_1lib in $cf_add_0lib; do
9348 for cf_add_2lib in $cf_add_libs; do
9349 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
9354 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
9360 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
9362 echo "$as_me:9362: checking for initscr" >&5
9363 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
9364 if test "${ac_cv_func_initscr+set}" = set; then
9365 echo $ECHO_N "(cached) $ECHO_C" >&6
9367 cat >conftest.$ac_ext <<_ACEOF
9368 #line 9368 "configure"
9369 #include "confdefs.h"
9370 #define initscr autoconf_temporary
9371 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
9378 /* We use char because int might match the return type of a gcc2
9379 builtin and then its argument prototype would still apply. */
9380 char initscr (void);
9386 /* The GNU C library defines stubs for functions which it implements
9387 to always fail with ENOSYS. Some functions are actually named
9388 something starting with __ and the normal name is an alias. */
9389 #if defined (__stub_initscr) || defined (__stub___initscr)
9390 #error found stub for initscr
9398 rm -f conftest.$ac_objext conftest$ac_exeext
9399 if { (eval echo "$as_me:9399: \"$ac_link\"") >&5
9400 (eval $ac_link) 2>&5
9402 echo "$as_me:9402: \$? = $ac_status" >&5
9403 (exit $ac_status); } &&
9404 { ac_try='test -s conftest$ac_exeext'
9405 { (eval echo "$as_me:9405: \"$ac_try\"") >&5
9408 echo "$as_me:9408: \$? = $ac_status" >&5
9409 (exit $ac_status); }; }; then
9410 ac_cv_func_initscr=yes
9412 echo "$as_me: failed program was:" >&5
9413 cat conftest.$ac_ext >&5
9414 ac_cv_func_initscr=no
9416 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9418 echo "$as_me:9418: result: $ac_cv_func_initscr" >&5
9419 echo "${ECHO_T}$ac_cv_func_initscr" >&6
9420 if test $ac_cv_func_initscr = yes; then
9421 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
9424 cf_save_LIBS="$LIBS"
9425 echo "$as_me:9425: checking for initscr in -l$cf_nculib_root" >&5
9426 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
9427 LIBS="-l$cf_nculib_root $LIBS"
9428 cat >conftest.$ac_ext <<_ACEOF
9429 #line 9429 "configure"
9430 #include "confdefs.h"
9431 #include <${cf_cv_ncurses_header:-curses.h}>
9440 rm -f conftest.$ac_objext conftest$ac_exeext
9441 if { (eval echo "$as_me:9441: \"$ac_link\"") >&5
9442 (eval $ac_link) 2>&5
9444 echo "$as_me:9444: \$? = $ac_status" >&5
9445 (exit $ac_status); } &&
9446 { ac_try='test -s conftest$ac_exeext'
9447 { (eval echo "$as_me:9447: \"$ac_try\"") >&5
9450 echo "$as_me:9450: \$? = $ac_status" >&5
9451 (exit $ac_status); }; }; then
9452 echo "$as_me:9452: result: yes" >&5
9453 echo "${ECHO_T}yes" >&6
9454 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
9457 echo "$as_me: failed program was:" >&5
9458 cat conftest.$ac_ext >&5
9459 echo "$as_me:9459: result: no" >&5
9460 echo "${ECHO_T}no" >&6
9463 cf_library_path_list=""
9464 if test -n "${LDFLAGS}${LIBS}" ; then
9465 for cf_library_path in $LDFLAGS $LIBS
9467 case $cf_library_path in
9469 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
9471 test "x$cf_library_path" != "xNONE" && \
9472 test -d "$cf_library_path" && \
9474 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
9475 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
9476 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
9477 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
9478 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
9479 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"
9482 cf_library_path_list="$cf_library_path_list $cf_search"
9490 test "x$prefix" != "xNONE" && \
9491 test -d "$prefix" && \
9493 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
9494 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
9495 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
9496 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
9497 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
9498 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
9501 for cf_subdir_prefix in \
9510 test "x$cf_subdir_prefix" != "x$prefix" && \
9511 test -d "$cf_subdir_prefix" && \
9512 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
9513 test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
9514 test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib"
9515 test -d $cf_subdir_prefix/lib/$cf_nculib_root && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root"
9516 test -d $cf_subdir_prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root/lib"
9517 test -d $cf_subdir_prefix/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib"
9518 test -d $cf_subdir_prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib/$cf_nculib_root"
9523 cf_search="$cf_library_path_list $cf_search"
9525 for cf_libdir in $cf_search
9527 echo "$as_me:9527: checking for -l$cf_nculib_root in $cf_libdir" >&5
9528 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
9529 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
9530 cat >conftest.$ac_ext <<_ACEOF
9531 #line 9531 "configure"
9532 #include "confdefs.h"
9533 #include <${cf_cv_ncurses_header:-curses.h}>
9542 rm -f conftest.$ac_objext conftest$ac_exeext
9543 if { (eval echo "$as_me:9543: \"$ac_link\"") >&5
9544 (eval $ac_link) 2>&5
9546 echo "$as_me:9546: \$? = $ac_status" >&5
9547 (exit $ac_status); } &&
9548 { ac_try='test -s conftest$ac_exeext'
9549 { (eval echo "$as_me:9549: \"$ac_try\"") >&5
9552 echo "$as_me:9552: \$? = $ac_status" >&5
9553 (exit $ac_status); }; }; then
9554 echo "$as_me:9554: result: yes" >&5
9555 echo "${ECHO_T}yes" >&6
9556 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
9559 echo "$as_me: failed program was:" >&5
9560 cat conftest.$ac_ext >&5
9561 echo "$as_me:9561: result: no" >&5
9562 echo "${ECHO_T}no" >&6
9563 LIBS="$cf_save_LIBS"
9565 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9569 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9573 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
9575 if test $cf_found_library = no ; then
9576 { { echo "$as_me:9576: error: Cannot link $cf_nculib_root library" >&5
9577 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
9578 { (exit 1); exit 1; }; }
9583 if test -n "$cf_ncurses_LIBS" ; then
9584 echo "$as_me:9584: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
9585 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
9586 cf_ncurses_SAVE="$LIBS"
9587 for p in $cf_ncurses_LIBS ; do
9588 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
9589 if test "$q" != "$LIBS" ; then
9593 cat >conftest.$ac_ext <<_ACEOF
9594 #line 9594 "configure"
9595 #include "confdefs.h"
9596 #include <${cf_cv_ncurses_header:-curses.h}>
9600 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
9605 rm -f conftest.$ac_objext conftest$ac_exeext
9606 if { (eval echo "$as_me:9606: \"$ac_link\"") >&5
9607 (eval $ac_link) 2>&5
9609 echo "$as_me:9609: \$? = $ac_status" >&5
9610 (exit $ac_status); } &&
9611 { ac_try='test -s conftest$ac_exeext'
9612 { (eval echo "$as_me:9612: \"$ac_try\"") >&5
9615 echo "$as_me:9615: \$? = $ac_status" >&5
9616 (exit $ac_status); }; }; then
9617 echo "$as_me:9617: result: yes" >&5
9618 echo "${ECHO_T}yes" >&6
9620 echo "$as_me: failed program was:" >&5
9621 cat conftest.$ac_ext >&5
9622 echo "$as_me:9622: result: no" >&5
9623 echo "${ECHO_T}no" >&6
9624 LIBS="$cf_ncurses_SAVE"
9626 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9629 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
9631 cat >>confdefs.h <<EOF
9632 #define $cf_nculib_ROOT 1
9643 cf_ncuconfig_root=$cf_cv_screen
9644 cf_have_ncuconfig=no
9646 if test "x${PKG_CONFIG:=none}" != xnone; then
9647 echo "$as_me:9647: checking pkg-config for $cf_ncuconfig_root" >&5
9648 echo $ECHO_N "checking pkg-config for $cf_ncuconfig_root... $ECHO_C" >&6
9649 if "$PKG_CONFIG" --exists $cf_ncuconfig_root ; then
9650 echo "$as_me:9650: result: yes" >&5
9651 echo "${ECHO_T}yes" >&6
9653 echo "$as_me:9653: checking if the $cf_ncuconfig_root package files work" >&5
9654 echo $ECHO_N "checking if the $cf_ncuconfig_root package files work... $ECHO_C" >&6
9655 cf_have_ncuconfig=unknown
9657 cf_save_CFLAGS="$CFLAGS"
9658 cf_save_CPPFLAGS="$CPPFLAGS"
9659 cf_save_LIBS="$LIBS"
9661 cf_pkg_cflags=`$PKG_CONFIG --cflags $cf_ncuconfig_root`
9662 cf_pkg_libs=`$PKG_CONFIG --libs $cf_ncuconfig_root`
9664 # while -W for passing linker flags is prevalent, it is not "standard".
9665 # At least one wrapper for c89/c99 (in Apple's xcode) has its own
9666 # incompatible _and_ non-standard -W option which gives an error. Work
9667 # around that pitfall.
9668 case "x${CC}@@${cf_pkg_libs}@${cf_pkg_cflags}" in
9674 cf_new_extra_cppflags=
9676 for cf_add_cflags in $cf_pkg_cflags
9678 case $cf_fix_cppflags in
9680 case $cf_add_cflags in
9681 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
9682 case $cf_add_cflags in
9684 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
9686 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
9687 && test -z "${cf_tst_cflags}" \
9688 && cf_fix_cppflags=yes
9690 if test $cf_fix_cppflags = yes ; then
9692 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9693 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9696 elif test "${cf_tst_cflags}" = "\"'" ; then
9698 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9699 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9709 case $cf_add_cflags in
9711 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
9713 CPPFLAGS=`echo "$CPPFLAGS" | \
9714 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
9715 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
9720 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
9721 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
9728 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
9729 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
9736 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9737 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9739 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
9741 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
9742 && test -z "${cf_tst_cflags}" \
9743 && cf_fix_cppflags=no
9748 if test -n "$cf_new_cflags" ; then
9750 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
9751 CFLAGS="${CFLAGS}$cf_new_cflags"
9755 if test -n "$cf_new_cppflags" ; then
9757 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
9758 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
9762 if test -n "$cf_new_extra_cppflags" ; then
9764 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
9765 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
9772 for cf_add_1lib in $cf_pkg_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
9774 for cf_add_1lib in $cf_add_0lib; do
9775 for cf_add_2lib in $cf_add_libs; do
9776 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
9781 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
9785 cat >conftest.$ac_ext <<_ACEOF
9786 #line 9786 "configure"
9787 #include "confdefs.h"
9788 #include <${cf_cv_ncurses_header:-curses.h}>
9792 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
9797 rm -f conftest.$ac_objext conftest$ac_exeext
9798 if { (eval echo "$as_me:9798: \"$ac_link\"") >&5
9799 (eval $ac_link) 2>&5
9801 echo "$as_me:9801: \$? = $ac_status" >&5
9802 (exit $ac_status); } &&
9803 { ac_try='test -s conftest$ac_exeext'
9804 { (eval echo "$as_me:9804: \"$ac_try\"") >&5
9807 echo "$as_me:9807: \$? = $ac_status" >&5
9808 (exit $ac_status); }; }; then
9809 if test "$cross_compiling" = yes; then
9810 cf_test_ncuconfig=maybe
9812 cat >conftest.$ac_ext <<_ACEOF
9813 #line 9813 "configure"
9814 #include "confdefs.h"
9815 #include <${cf_cv_ncurses_header:-curses.h}>
9817 { char *xx = curses_version(); return (xx == 0); }
9819 rm -f conftest$ac_exeext
9820 if { (eval echo "$as_me:9820: \"$ac_link\"") >&5
9821 (eval $ac_link) 2>&5
9823 echo "$as_me:9823: \$? = $ac_status" >&5
9824 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
9825 { (eval echo "$as_me:9825: \"$ac_try\"") >&5
9828 echo "$as_me:9828: \$? = $ac_status" >&5
9829 (exit $ac_status); }; }; then
9830 cf_test_ncuconfig=yes
9832 echo "$as_me: program exited with status $ac_status" >&5
9833 echo "$as_me: failed program was:" >&5
9834 cat conftest.$ac_ext >&5
9835 cf_test_ncuconfig=no
9837 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
9840 echo "$as_me: failed program was:" >&5
9841 cat conftest.$ac_ext >&5
9842 cf_test_ncuconfig=no
9844 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9846 CFLAGS="$cf_save_CFLAGS"
9847 CPPFLAGS="$cf_save_CPPFLAGS"
9848 LIBS="$cf_save_LIBS"
9850 if test "x$cf_test_ncuconfig" != xyes; then
9851 cf_temp=`echo "x$cf_pkg_cflags" | sed -e s/^x// -e 's/-W[^ ]*//g'`
9852 cf_pkg_cflags="$cf_temp"
9853 cf_temp=`echo "x$cf_pkg_libs" | sed -e s/^x// -e 's/-W[^ ]*//g'`
9854 cf_pkg_libs="$cf_temp"
9862 cf_new_extra_cppflags=
9864 for cf_add_cflags in $cf_pkg_cflags
9866 case $cf_fix_cppflags in
9868 case $cf_add_cflags in
9869 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
9870 case $cf_add_cflags in
9872 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
9874 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
9875 && test -z "${cf_tst_cflags}" \
9876 && cf_fix_cppflags=yes
9878 if test $cf_fix_cppflags = yes ; then
9880 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9881 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9884 elif test "${cf_tst_cflags}" = "\"'" ; then
9886 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9887 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9897 case $cf_add_cflags in
9899 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
9901 CPPFLAGS=`echo "$CPPFLAGS" | \
9902 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
9903 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
9908 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
9909 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
9916 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
9917 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
9924 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9925 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9927 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
9929 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
9930 && test -z "${cf_tst_cflags}" \
9931 && cf_fix_cppflags=no
9936 if test -n "$cf_new_cflags" ; then
9938 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
9939 CFLAGS="${CFLAGS}$cf_new_cflags"
9943 if test -n "$cf_new_cppflags" ; then
9945 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
9946 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
9950 if test -n "$cf_new_extra_cppflags" ; then
9952 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
9953 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
9960 for cf_add_1lib in $cf_pkg_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
9962 for cf_add_1lib in $cf_add_0lib; do
9963 for cf_add_2lib in $cf_add_libs; do
9964 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
9969 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
9973 cat >conftest.$ac_ext <<_ACEOF
9974 #line 9974 "configure"
9975 #include "confdefs.h"
9976 #include <${cf_cv_ncurses_header:-curses.h}>
9980 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
9985 rm -f conftest.$ac_objext conftest$ac_exeext
9986 if { (eval echo "$as_me:9986: \"$ac_link\"") >&5
9987 (eval $ac_link) 2>&5
9989 echo "$as_me:9989: \$? = $ac_status" >&5
9990 (exit $ac_status); } &&
9991 { ac_try='test -s conftest$ac_exeext'
9992 { (eval echo "$as_me:9992: \"$ac_try\"") >&5
9995 echo "$as_me:9995: \$? = $ac_status" >&5
9996 (exit $ac_status); }; }; then
9997 if test "$cross_compiling" = yes; then
9998 cf_have_ncuconfig=maybe
10000 cat >conftest.$ac_ext <<_ACEOF
10001 #line 10001 "configure"
10002 #include "confdefs.h"
10003 #include <${cf_cv_ncurses_header:-curses.h}>
10005 { char *xx = curses_version(); return (xx == 0); }
10007 rm -f conftest$ac_exeext
10008 if { (eval echo "$as_me:10008: \"$ac_link\"") >&5
10009 (eval $ac_link) 2>&5
10011 echo "$as_me:10011: \$? = $ac_status" >&5
10012 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
10013 { (eval echo "$as_me:10013: \"$ac_try\"") >&5
10014 (eval $ac_try) 2>&5
10016 echo "$as_me:10016: \$? = $ac_status" >&5
10017 (exit $ac_status); }; }; then
10018 cf_have_ncuconfig=yes
10020 echo "$as_me: program exited with status $ac_status" >&5
10021 echo "$as_me: failed program was:" >&5
10022 cat conftest.$ac_ext >&5
10023 cf_have_ncuconfig=no
10025 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
10028 echo "$as_me: failed program was:" >&5
10029 cat conftest.$ac_ext >&5
10030 cf_have_ncuconfig=no
10032 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10033 echo "$as_me:10033: result: $cf_have_ncuconfig" >&5
10034 echo "${ECHO_T}$cf_have_ncuconfig" >&6
10035 test "$cf_have_ncuconfig" = maybe && cf_have_ncuconfig=yes
10036 if test "$cf_have_ncuconfig" != "yes"
10038 CPPFLAGS="$cf_save_CPPFLAGS"
10039 LIBS="$cf_save_LIBS"
10040 NCURSES_CONFIG_PKG=none
10043 cat >>confdefs.h <<\EOF
10047 NCURSES_CONFIG_PKG=$cf_ncuconfig_root
10049 echo "$as_me:10049: checking for terminfo header" >&5
10050 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
10051 if test "${cf_cv_term_header+set}" = set; then
10052 echo $ECHO_N "(cached) $ECHO_C" >&6
10055 case ${cf_cv_ncurses_header} in
10056 (*/ncurses.h|*/ncursesw.h)
10057 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
10060 cf_term_header=term.h
10064 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
10066 cat >conftest.$ac_ext <<_ACEOF
10067 #line 10067 "configure"
10068 #include "confdefs.h"
10070 #include <${cf_cv_ncurses_header:-curses.h}>
10071 #include <$cf_test>
10076 int x = auto_left_margin; (void)x
10081 rm -f conftest.$ac_objext
10082 if { (eval echo "$as_me:10082: \"$ac_compile\"") >&5
10083 (eval $ac_compile) 2>&5
10085 echo "$as_me:10085: \$? = $ac_status" >&5
10086 (exit $ac_status); } &&
10087 { ac_try='test -s conftest.$ac_objext'
10088 { (eval echo "$as_me:10088: \"$ac_try\"") >&5
10089 (eval $ac_try) 2>&5
10091 echo "$as_me:10091: \$? = $ac_status" >&5
10092 (exit $ac_status); }; }; then
10094 cf_cv_term_header="$cf_test"
10096 echo "$as_me: failed program was:" >&5
10097 cat conftest.$ac_ext >&5
10099 cf_cv_term_header=unknown
10102 rm -f conftest.$ac_objext conftest.$ac_ext
10103 test "$cf_cv_term_header" != unknown && break
10107 echo "$as_me:10107: result: $cf_cv_term_header" >&5
10108 echo "${ECHO_T}$cf_cv_term_header" >&6
10110 # Set definitions to allow ifdef'ing to accommodate subdirectories
10112 case $cf_cv_term_header in
10115 cat >>confdefs.h <<\EOF
10116 #define HAVE_TERM_H 1
10122 case $cf_cv_term_header in
10125 cat >>confdefs.h <<\EOF
10126 #define HAVE_NCURSES_TERM_H 1
10132 cat >>confdefs.h <<\EOF
10133 #define HAVE_NCURSESW_TERM_H 1
10142 echo "$as_me:10142: result: no" >&5
10143 echo "${ECHO_T}no" >&6
10144 NCURSES_CONFIG_PKG=none
10147 NCURSES_CONFIG_PKG=none
10150 if test "x$cf_have_ncuconfig" = "xno"; then
10151 cf_ncurses_config="${cf_ncuconfig_root}${NCURSES_CONFIG_SUFFIX}-config"; echo "Looking for ${cf_ncurses_config}"
10153 if test -n "$ac_tool_prefix"; then
10154 for ac_prog in ${cf_ncurses_config} ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
10156 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
10157 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
10158 echo "$as_me:10158: checking for $ac_word" >&5
10159 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
10160 if test "${ac_cv_prog_NCURSES_CONFIG+set}" = set; then
10161 echo $ECHO_N "(cached) $ECHO_C" >&6
10163 if test -n "$NCURSES_CONFIG"; then
10164 ac_cv_prog_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test.
10166 ac_save_IFS=$IFS; IFS=$ac_path_separator
10168 for ac_dir in $ac_dummy; do
10170 test -z "$ac_dir" && ac_dir=.
10171 $as_executable_p "$ac_dir/$ac_word" || continue
10172 ac_cv_prog_NCURSES_CONFIG="$ac_tool_prefix$ac_prog"
10173 echo "$as_me:10173: found $ac_dir/$ac_word" >&5
10179 NCURSES_CONFIG=$ac_cv_prog_NCURSES_CONFIG
10180 if test -n "$NCURSES_CONFIG"; then
10181 echo "$as_me:10181: result: $NCURSES_CONFIG" >&5
10182 echo "${ECHO_T}$NCURSES_CONFIG" >&6
10184 echo "$as_me:10184: result: no" >&5
10185 echo "${ECHO_T}no" >&6
10188 test -n "$NCURSES_CONFIG" && break
10191 if test -z "$NCURSES_CONFIG"; then
10192 ac_ct_NCURSES_CONFIG=$NCURSES_CONFIG
10193 for ac_prog in ${cf_ncurses_config} ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
10195 # Extract the first word of "$ac_prog", so it can be a program name with args.
10196 set dummy $ac_prog; ac_word=$2
10197 echo "$as_me:10197: checking for $ac_word" >&5
10198 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
10199 if test "${ac_cv_prog_ac_ct_NCURSES_CONFIG+set}" = set; then
10200 echo $ECHO_N "(cached) $ECHO_C" >&6
10202 if test -n "$ac_ct_NCURSES_CONFIG"; then
10203 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_ct_NCURSES_CONFIG" # Let the user override the test.
10205 ac_save_IFS=$IFS; IFS=$ac_path_separator
10207 for ac_dir in $ac_dummy; do
10209 test -z "$ac_dir" && ac_dir=.
10210 $as_executable_p "$ac_dir/$ac_word" || continue
10211 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_prog"
10212 echo "$as_me:10212: found $ac_dir/$ac_word" >&5
10218 ac_ct_NCURSES_CONFIG=$ac_cv_prog_ac_ct_NCURSES_CONFIG
10219 if test -n "$ac_ct_NCURSES_CONFIG"; then
10220 echo "$as_me:10220: result: $ac_ct_NCURSES_CONFIG" >&5
10221 echo "${ECHO_T}$ac_ct_NCURSES_CONFIG" >&6
10223 echo "$as_me:10223: result: no" >&5
10224 echo "${ECHO_T}no" >&6
10227 test -n "$ac_ct_NCURSES_CONFIG" && break
10229 test -n "$ac_ct_NCURSES_CONFIG" || ac_ct_NCURSES_CONFIG="none"
10231 NCURSES_CONFIG=$ac_ct_NCURSES_CONFIG
10234 if test "$NCURSES_CONFIG" != none ; then
10239 cf_new_extra_cppflags=
10241 for cf_add_cflags in `$NCURSES_CONFIG --cflags`
10243 case $cf_fix_cppflags in
10245 case $cf_add_cflags in
10246 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
10247 case $cf_add_cflags in
10249 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10251 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10252 && test -z "${cf_tst_cflags}" \
10253 && cf_fix_cppflags=yes
10255 if test $cf_fix_cppflags = yes ; then
10257 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10258 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10261 elif test "${cf_tst_cflags}" = "\"'" ; then
10263 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10264 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10270 case "$CPPFLAGS" in
10274 case $cf_add_cflags in
10276 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10278 CPPFLAGS=`echo "$CPPFLAGS" | \
10279 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10280 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10285 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
10286 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
10293 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
10294 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
10301 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10302 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10304 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10306 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10307 && test -z "${cf_tst_cflags}" \
10308 && cf_fix_cppflags=no
10313 if test -n "$cf_new_cflags" ; then
10315 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
10316 CFLAGS="${CFLAGS}$cf_new_cflags"
10320 if test -n "$cf_new_cppflags" ; then
10322 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
10323 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
10327 if test -n "$cf_new_extra_cppflags" ; then
10329 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
10330 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
10334 cf_add_libs="$LIBS"
10337 for cf_add_1lib in `$NCURSES_CONFIG --libs`; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
10338 # filter duplicates
10339 for cf_add_1lib in $cf_add_0lib; do
10340 for cf_add_2lib in $cf_add_libs; do
10341 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
10346 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
10348 LIBS="$cf_add_libs"
10350 # even with config script, some packages use no-override for curses.h
10352 echo "$as_me:10352: checking if we have identified curses headers" >&5
10353 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
10354 if test "${cf_cv_ncurses_header+set}" = set; then
10355 echo $ECHO_N "(cached) $ECHO_C" >&6
10358 cf_cv_ncurses_header=none
10360 ncurses.h $cf_cv_screen/ncurses.h \
10361 curses.h $cf_cv_screen/curses.h
10363 cat >conftest.$ac_ext <<_ACEOF
10364 #line 10364 "configure"
10365 #include "confdefs.h"
10366 #include <${cf_header}>
10370 initscr(); tgoto("?", 0,0)
10375 rm -f conftest.$ac_objext
10376 if { (eval echo "$as_me:10376: \"$ac_compile\"") >&5
10377 (eval $ac_compile) 2>&5
10379 echo "$as_me:10379: \$? = $ac_status" >&5
10380 (exit $ac_status); } &&
10381 { ac_try='test -s conftest.$ac_objext'
10382 { (eval echo "$as_me:10382: \"$ac_try\"") >&5
10383 (eval $ac_try) 2>&5
10385 echo "$as_me:10385: \$? = $ac_status" >&5
10386 (exit $ac_status); }; }; then
10387 cf_cv_ncurses_header=$cf_header; break
10389 echo "$as_me: failed program was:" >&5
10390 cat conftest.$ac_ext >&5
10392 rm -f conftest.$ac_objext conftest.$ac_ext
10396 echo "$as_me:10396: result: $cf_cv_ncurses_header" >&5
10397 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
10399 if test "$cf_cv_ncurses_header" = none ; then
10400 { { echo "$as_me:10400: error: No curses header-files found" >&5
10401 echo "$as_me: error: No curses header-files found" >&2;}
10402 { (exit 1); exit 1; }; }
10405 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
10407 for ac_header in $cf_cv_ncurses_header
10409 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
10410 echo "$as_me:10410: checking for $ac_header" >&5
10411 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
10412 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10413 echo $ECHO_N "(cached) $ECHO_C" >&6
10415 cat >conftest.$ac_ext <<_ACEOF
10416 #line 10416 "configure"
10417 #include "confdefs.h"
10418 #include <$ac_header>
10420 if { (eval echo "$as_me:10420: \"$ac_cpp conftest.$ac_ext\"") >&5
10421 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10423 egrep -v '^ *\+' conftest.er1 >conftest.err
10425 cat conftest.err >&5
10426 echo "$as_me:10426: \$? = $ac_status" >&5
10427 (exit $ac_status); } >/dev/null; then
10428 if test -s conftest.err; then
10429 ac_cpp_err=$ac_c_preproc_warn_flag
10436 if test -z "$ac_cpp_err"; then
10437 eval "$as_ac_Header=yes"
10439 echo "$as_me: failed program was:" >&5
10440 cat conftest.$ac_ext >&5
10441 eval "$as_ac_Header=no"
10443 rm -f conftest.err conftest.$ac_ext
10445 echo "$as_me:10445: result: `eval echo '${'$as_ac_Header'}'`" >&5
10446 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
10447 if test `eval echo '${'$as_ac_Header'}'` = yes; then
10448 cat >>confdefs.h <<EOF
10449 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
10455 cat >>confdefs.h <<\EOF
10459 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
10461 cat >>confdefs.h <<EOF
10462 #define $cf_nculib_ROOT 1
10465 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
10469 cf_ncuhdr_root=$cf_cv_screen
10471 test -n "$cf_cv_curses_dir" && \
10472 test "$cf_cv_curses_dir" != "no" && { \
10474 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
10475 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
10477 while test $cf_add_incdir != /usr/include
10479 if test -d $cf_add_incdir
10482 if test -n "$CFLAGS$CPPFLAGS" ; then
10483 # a loop is needed to ensure we can add subdirs of existing dirs
10484 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
10485 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
10486 cf_have_incdir=yes; break
10491 if test "$cf_have_incdir" = no ; then
10492 if test "$cf_add_incdir" = /usr/local/include ; then
10493 if test "$GCC" = yes
10495 cf_save_CPPFLAGS=$CPPFLAGS
10497 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
10498 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
10500 cat >conftest.$ac_ext <<_ACEOF
10501 #line 10501 "configure"
10502 #include "confdefs.h"
10512 rm -f conftest.$ac_objext
10513 if { (eval echo "$as_me:10513: \"$ac_compile\"") >&5
10514 (eval $ac_compile) 2>&5
10516 echo "$as_me:10516: \$? = $ac_status" >&5
10517 (exit $ac_status); } &&
10518 { ac_try='test -s conftest.$ac_objext'
10519 { (eval echo "$as_me:10519: \"$ac_try\"") >&5
10520 (eval $ac_try) 2>&5
10522 echo "$as_me:10522: \$? = $ac_status" >&5
10523 (exit $ac_status); }; }; then
10526 echo "$as_me: failed program was:" >&5
10527 cat conftest.$ac_ext >&5
10530 rm -f conftest.$ac_objext conftest.$ac_ext
10531 CPPFLAGS=$cf_save_CPPFLAGS
10536 if test "$cf_have_incdir" = no ; then
10537 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
10539 echo "${as_me:-configure}:10539: testing adding $cf_add_incdir to include-path ..." 1>&5
10541 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
10543 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
10544 test "$cf_top_incdir" = "$cf_add_incdir" && break
10545 cf_add_incdir="$cf_top_incdir"
10558 echo "$as_me:10558: checking for $cf_ncuhdr_root header in include-path" >&5
10559 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
10560 if test "${cf_cv_ncurses_h+set}" = set; then
10561 echo $ECHO_N "(cached) $ECHO_C" >&6
10564 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
10565 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
10566 for cf_header in $cf_header_list
10569 cat >conftest.$ac_ext <<_ACEOF
10570 #line 10570 "configure"
10571 #include "confdefs.h"
10573 #include <$cf_header>
10578 #ifdef NCURSES_VERSION
10580 printf("%s\n", NCURSES_VERSION);
10593 rm -f conftest.$ac_objext
10594 if { (eval echo "$as_me:10594: \"$ac_compile\"") >&5
10595 (eval $ac_compile) 2>&5
10597 echo "$as_me:10597: \$? = $ac_status" >&5
10598 (exit $ac_status); } &&
10599 { ac_try='test -s conftest.$ac_objext'
10600 { (eval echo "$as_me:10600: \"$ac_try\"") >&5
10601 (eval $ac_try) 2>&5
10603 echo "$as_me:10603: \$? = $ac_status" >&5
10604 (exit $ac_status); }; }; then
10605 cf_cv_ncurses_h=$cf_header
10608 echo "$as_me: failed program was:" >&5
10609 cat conftest.$ac_ext >&5
10612 rm -f conftest.$ac_objext conftest.$ac_ext
10614 test "$cf_cv_ncurses_h" != no && break
10618 echo "$as_me:10618: result: $cf_cv_ncurses_h" >&5
10619 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
10621 if test "$cf_cv_ncurses_h" != no ; then
10622 cf_cv_ncurses_header=$cf_cv_ncurses_h
10625 echo "$as_me:10625: checking for $cf_ncuhdr_root include-path" >&5
10626 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
10627 if test "${cf_cv_ncurses_h2+set}" = set; then
10628 echo $ECHO_N "(cached) $ECHO_C" >&6
10631 test -n "$verbose" && echo
10635 # collect the current set of include-directories from compiler flags
10636 cf_header_path_list=""
10637 if test -n "${CFLAGS}${CPPFLAGS}" ; then
10638 for cf_header_path in $CPPFLAGS $CFLAGS
10640 case $cf_header_path in
10642 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
10644 test "x$cf_header_path" != "xNONE" && \
10645 test -d "$cf_header_path" && \
10647 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
10648 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
10649 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
10650 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
10651 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
10652 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"
10655 cf_header_path_list="$cf_header_path_list $cf_search"
10661 # add the variations for the package we are looking for
10665 test "x$prefix" != "xNONE" && \
10666 test -d "$prefix" && \
10668 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
10669 test -d $prefix/include && cf_search="$cf_search $prefix/include"
10670 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
10671 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
10672 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
10673 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
10676 for cf_subdir_prefix in \
10685 test "x$cf_subdir_prefix" != "x$prefix" && \
10686 test -d "$cf_subdir_prefix" && \
10687 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
10688 test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
10689 test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include"
10690 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root"
10691 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root/include"
10692 test -d $cf_subdir_prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include"
10693 test -d $cf_subdir_prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
10698 test "$includedir" != NONE && \
10699 test "$includedir" != "/usr/include" && \
10700 test -d "$includedir" && {
10701 test -d $includedir && cf_search="$cf_search $includedir"
10702 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
10705 test "$oldincludedir" != NONE && \
10706 test "$oldincludedir" != "/usr/include" && \
10707 test -d "$oldincludedir" && {
10708 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
10709 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
10712 cf_search="$cf_search $cf_header_path_list"
10714 test -n "$verbose" && echo search path $cf_search
10715 cf_save2_CPPFLAGS="$CPPFLAGS"
10716 for cf_incdir in $cf_search
10719 if test -n "$cf_incdir" ; then
10720 for cf_add_incdir in $cf_incdir
10722 while test $cf_add_incdir != /usr/include
10724 if test -d $cf_add_incdir
10727 if test -n "$CFLAGS$CPPFLAGS" ; then
10728 # a loop is needed to ensure we can add subdirs of existing dirs
10729 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
10730 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
10731 cf_have_incdir=yes; break
10736 if test "$cf_have_incdir" = no ; then
10737 if test "$cf_add_incdir" = /usr/local/include ; then
10738 if test "$GCC" = yes
10740 cf_save_CPPFLAGS=$CPPFLAGS
10742 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
10743 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
10745 cat >conftest.$ac_ext <<_ACEOF
10746 #line 10746 "configure"
10747 #include "confdefs.h"
10757 rm -f conftest.$ac_objext
10758 if { (eval echo "$as_me:10758: \"$ac_compile\"") >&5
10759 (eval $ac_compile) 2>&5
10761 echo "$as_me:10761: \$? = $ac_status" >&5
10762 (exit $ac_status); } &&
10763 { ac_try='test -s conftest.$ac_objext'
10764 { (eval echo "$as_me:10764: \"$ac_try\"") >&5
10765 (eval $ac_try) 2>&5
10767 echo "$as_me:10767: \$? = $ac_status" >&5
10768 (exit $ac_status); }; }; then
10771 echo "$as_me: failed program was:" >&5
10772 cat conftest.$ac_ext >&5
10775 rm -f conftest.$ac_objext conftest.$ac_ext
10776 CPPFLAGS=$cf_save_CPPFLAGS
10781 if test "$cf_have_incdir" = no ; then
10782 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
10784 echo "${as_me:-configure}:10784: testing adding $cf_add_incdir to include-path ..." 1>&5
10786 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
10788 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
10789 test "$cf_top_incdir" = "$cf_add_incdir" && break
10790 cf_add_incdir="$cf_top_incdir"
10806 cat >conftest.$ac_ext <<_ACEOF
10807 #line 10807 "configure"
10808 #include "confdefs.h"
10810 #include <$cf_header>
10815 #ifdef NCURSES_VERSION
10817 printf("%s\n", NCURSES_VERSION);
10830 rm -f conftest.$ac_objext
10831 if { (eval echo "$as_me:10831: \"$ac_compile\"") >&5
10832 (eval $ac_compile) 2>&5
10834 echo "$as_me:10834: \$? = $ac_status" >&5
10835 (exit $ac_status); } &&
10836 { ac_try='test -s conftest.$ac_objext'
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 cf_cv_ncurses_h2=$cf_header
10845 echo "$as_me: failed program was:" >&5
10846 cat conftest.$ac_ext >&5
10847 cf_cv_ncurses_h2=no
10849 rm -f conftest.$ac_objext conftest.$ac_ext
10851 if test "$cf_cv_ncurses_h2" != no ; then
10852 cf_cv_ncurses_h2=$cf_incdir/$cf_header
10853 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
10856 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
10858 CPPFLAGS="$cf_save2_CPPFLAGS"
10859 test "$cf_cv_ncurses_h2" != no && break
10861 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:10861: error: not found" >&5
10862 echo "$as_me: error: not found" >&2;}
10863 { (exit 1); exit 1; }; }
10866 echo "$as_me:10866: result: $cf_cv_ncurses_h2" >&5
10867 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
10869 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
10870 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
10871 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
10872 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
10875 if test -n "$cf_1st_incdir" ; then
10876 for cf_add_incdir in $cf_1st_incdir
10878 while test $cf_add_incdir != /usr/include
10880 if test -d $cf_add_incdir
10883 if test -n "$CFLAGS$CPPFLAGS" ; then
10884 # a loop is needed to ensure we can add subdirs of existing dirs
10885 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
10886 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
10887 cf_have_incdir=yes; break
10892 if test "$cf_have_incdir" = no ; then
10893 if test "$cf_add_incdir" = /usr/local/include ; then
10894 if test "$GCC" = yes
10896 cf_save_CPPFLAGS=$CPPFLAGS
10898 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
10899 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
10901 cat >conftest.$ac_ext <<_ACEOF
10902 #line 10902 "configure"
10903 #include "confdefs.h"
10913 rm -f conftest.$ac_objext
10914 if { (eval echo "$as_me:10914: \"$ac_compile\"") >&5
10915 (eval $ac_compile) 2>&5
10917 echo "$as_me:10917: \$? = $ac_status" >&5
10918 (exit $ac_status); } &&
10919 { ac_try='test -s conftest.$ac_objext'
10920 { (eval echo "$as_me:10920: \"$ac_try\"") >&5
10921 (eval $ac_try) 2>&5
10923 echo "$as_me:10923: \$? = $ac_status" >&5
10924 (exit $ac_status); }; }; then
10927 echo "$as_me: failed program was:" >&5
10928 cat conftest.$ac_ext >&5
10931 rm -f conftest.$ac_objext conftest.$ac_ext
10932 CPPFLAGS=$cf_save_CPPFLAGS
10937 if test "$cf_have_incdir" = no ; then
10938 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
10940 echo "${as_me:-configure}:10940: testing adding $cf_add_incdir to include-path ..." 1>&5
10942 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
10944 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
10945 test "$cf_top_incdir" = "$cf_add_incdir" && break
10946 cf_add_incdir="$cf_top_incdir"
10959 # Set definitions to allow ifdef'ing for ncurses.h
10961 case $cf_cv_ncurses_header in
10964 cat >>confdefs.h <<\EOF
10965 #define HAVE_NCURSES_H 1
10971 case $cf_cv_ncurses_header in
10972 (ncurses/curses.h|ncurses/ncurses.h)
10974 cat >>confdefs.h <<\EOF
10975 #define HAVE_NCURSES_NCURSES_H 1
10979 (ncursesw/curses.h|ncursesw/ncurses.h)
10981 cat >>confdefs.h <<\EOF
10982 #define HAVE_NCURSESW_NCURSES_H 1
10988 echo "$as_me:10988: checking for terminfo header" >&5
10989 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
10990 if test "${cf_cv_term_header+set}" = set; then
10991 echo $ECHO_N "(cached) $ECHO_C" >&6
10994 case ${cf_cv_ncurses_header} in
10995 (*/ncurses.h|*/ncursesw.h)
10996 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
10999 cf_term_header=term.h
11003 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
11005 cat >conftest.$ac_ext <<_ACEOF
11006 #line 11006 "configure"
11007 #include "confdefs.h"
11009 #include <${cf_cv_ncurses_header:-curses.h}>
11010 #include <$cf_test>
11015 int x = auto_left_margin; (void)x
11020 rm -f conftest.$ac_objext
11021 if { (eval echo "$as_me:11021: \"$ac_compile\"") >&5
11022 (eval $ac_compile) 2>&5
11024 echo "$as_me:11024: \$? = $ac_status" >&5
11025 (exit $ac_status); } &&
11026 { ac_try='test -s conftest.$ac_objext'
11027 { (eval echo "$as_me:11027: \"$ac_try\"") >&5
11028 (eval $ac_try) 2>&5
11030 echo "$as_me:11030: \$? = $ac_status" >&5
11031 (exit $ac_status); }; }; then
11033 cf_cv_term_header="$cf_test"
11035 echo "$as_me: failed program was:" >&5
11036 cat conftest.$ac_ext >&5
11038 cf_cv_term_header=unknown
11041 rm -f conftest.$ac_objext conftest.$ac_ext
11042 test "$cf_cv_term_header" != unknown && break
11046 echo "$as_me:11046: result: $cf_cv_term_header" >&5
11047 echo "${ECHO_T}$cf_cv_term_header" >&6
11049 # Set definitions to allow ifdef'ing to accommodate subdirectories
11051 case $cf_cv_term_header in
11054 cat >>confdefs.h <<\EOF
11055 #define HAVE_TERM_H 1
11061 case $cf_cv_term_header in
11064 cat >>confdefs.h <<\EOF
11065 #define HAVE_NCURSES_TERM_H 1
11071 cat >>confdefs.h <<\EOF
11072 #define HAVE_NCURSESW_TERM_H 1
11078 # some applications need this, but should check for NCURSES_VERSION
11080 cat >>confdefs.h <<\EOF
11084 echo "$as_me:11084: checking for ncurses version" >&5
11085 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
11086 if test "${cf_cv_ncurses_version+set}" = set; then
11087 echo $ECHO_N "(cached) $ECHO_C" >&6
11090 cf_cv_ncurses_version=no
11093 if test "$cross_compiling" = yes; then
11095 # This will not work if the preprocessor splits the line after the
11096 # Autoconf token. The 'unproto' program does that.
11097 cat > conftest.$ac_ext <<EOF
11098 #include <${cf_cv_ncurses_header:-curses.h}>
11100 #ifdef NCURSES_VERSION
11101 Autoconf NCURSES_VERSION
11109 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
11110 { (eval echo "$as_me:11110: \"$cf_try\"") >&5
11111 (eval $cf_try) 2>&5
11113 echo "$as_me:11113: \$? = $ac_status" >&5
11114 (exit $ac_status); }
11115 if test -f conftest.out ; then
11116 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
11117 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
11122 cat >conftest.$ac_ext <<_ACEOF
11123 #line 11123 "configure"
11124 #include "confdefs.h"
11126 #include <${cf_cv_ncurses_header:-curses.h}>
11130 FILE *fp = fopen("$cf_tempfile", "w");
11131 #ifdef NCURSES_VERSION
11132 # ifdef NCURSES_VERSION_PATCH
11133 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
11135 fprintf(fp, "%s\n", NCURSES_VERSION);
11138 # ifdef __NCURSES_H
11139 fprintf(fp, "old\n");
11144 ${cf_cv_main_return:-return}(0);
11147 rm -f conftest$ac_exeext
11148 if { (eval echo "$as_me:11148: \"$ac_link\"") >&5
11149 (eval $ac_link) 2>&5
11151 echo "$as_me:11151: \$? = $ac_status" >&5
11152 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
11153 { (eval echo "$as_me:11153: \"$ac_try\"") >&5
11154 (eval $ac_try) 2>&5
11156 echo "$as_me:11156: \$? = $ac_status" >&5
11157 (exit $ac_status); }; }; then
11159 cf_cv_ncurses_version=`cat $cf_tempfile`
11161 echo "$as_me: program exited with status $ac_status" >&5
11162 echo "$as_me: failed program was:" >&5
11163 cat conftest.$ac_ext >&5
11165 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
11170 echo "$as_me:11170: result: $cf_cv_ncurses_version" >&5
11171 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
11172 test "$cf_cv_ncurses_version" = no ||
11173 cat >>confdefs.h <<\EOF
11177 cf_nculib_root=$cf_cv_screen
11178 # This works, except for the special case where we find gpm, but
11179 # ncurses is in a nonstandard location via $LIBS, and we really want
11182 cf_ncurses_SAVE="$LIBS"
11183 echo "$as_me:11183: checking for Gpm_Open in -lgpm" >&5
11184 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
11185 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
11186 echo $ECHO_N "(cached) $ECHO_C" >&6
11188 ac_check_lib_save_LIBS=$LIBS
11190 cat >conftest.$ac_ext <<_ACEOF
11191 #line 11191 "configure"
11192 #include "confdefs.h"
11194 /* Override any gcc2 internal prototype to avoid an error. */
11198 /* We use char because int might match the return type of a gcc2
11199 builtin and then its argument prototype would still apply. */
11209 rm -f conftest.$ac_objext conftest$ac_exeext
11210 if { (eval echo "$as_me:11210: \"$ac_link\"") >&5
11211 (eval $ac_link) 2>&5
11213 echo "$as_me:11213: \$? = $ac_status" >&5
11214 (exit $ac_status); } &&
11215 { ac_try='test -s conftest$ac_exeext'
11216 { (eval echo "$as_me:11216: \"$ac_try\"") >&5
11217 (eval $ac_try) 2>&5
11219 echo "$as_me:11219: \$? = $ac_status" >&5
11220 (exit $ac_status); }; }; then
11221 ac_cv_lib_gpm_Gpm_Open=yes
11223 echo "$as_me: failed program was:" >&5
11224 cat conftest.$ac_ext >&5
11225 ac_cv_lib_gpm_Gpm_Open=no
11227 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11228 LIBS=$ac_check_lib_save_LIBS
11230 echo "$as_me:11230: result: $ac_cv_lib_gpm_Gpm_Open" >&5
11231 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
11232 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
11233 echo "$as_me:11233: checking for initscr in -lgpm" >&5
11234 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
11235 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
11236 echo $ECHO_N "(cached) $ECHO_C" >&6
11238 ac_check_lib_save_LIBS=$LIBS
11240 cat >conftest.$ac_ext <<_ACEOF
11241 #line 11241 "configure"
11242 #include "confdefs.h"
11244 /* Override any gcc2 internal prototype to avoid an error. */
11248 /* We use char because int might match the return type of a gcc2
11249 builtin and then its argument prototype would still apply. */
11259 rm -f conftest.$ac_objext conftest$ac_exeext
11260 if { (eval echo "$as_me:11260: \"$ac_link\"") >&5
11261 (eval $ac_link) 2>&5
11263 echo "$as_me:11263: \$? = $ac_status" >&5
11264 (exit $ac_status); } &&
11265 { ac_try='test -s conftest$ac_exeext'
11266 { (eval echo "$as_me:11266: \"$ac_try\"") >&5
11267 (eval $ac_try) 2>&5
11269 echo "$as_me:11269: \$? = $ac_status" >&5
11270 (exit $ac_status); }; }; then
11271 ac_cv_lib_gpm_initscr=yes
11273 echo "$as_me: failed program was:" >&5
11274 cat conftest.$ac_ext >&5
11275 ac_cv_lib_gpm_initscr=no
11277 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11278 LIBS=$ac_check_lib_save_LIBS
11280 echo "$as_me:11280: result: $ac_cv_lib_gpm_initscr" >&5
11281 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
11282 if test $ac_cv_lib_gpm_initscr = yes; then
11283 LIBS="$cf_ncurses_SAVE"
11285 cf_ncurses_LIBS="-lgpm"
11292 # This is only necessary if you are linking against an obsolete
11293 # version of ncurses (but it should do no harm, since it's static).
11294 if test "$cf_nculib_root" = ncurses ; then
11295 echo "$as_me:11295: checking for tgoto in -lmytinfo" >&5
11296 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
11297 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
11298 echo $ECHO_N "(cached) $ECHO_C" >&6
11300 ac_check_lib_save_LIBS=$LIBS
11301 LIBS="-lmytinfo $LIBS"
11302 cat >conftest.$ac_ext <<_ACEOF
11303 #line 11303 "configure"
11304 #include "confdefs.h"
11306 /* Override any gcc2 internal prototype to avoid an error. */
11310 /* We use char because int might match the return type of a gcc2
11311 builtin and then its argument prototype would still apply. */
11321 rm -f conftest.$ac_objext conftest$ac_exeext
11322 if { (eval echo "$as_me:11322: \"$ac_link\"") >&5
11323 (eval $ac_link) 2>&5
11325 echo "$as_me:11325: \$? = $ac_status" >&5
11326 (exit $ac_status); } &&
11327 { ac_try='test -s conftest$ac_exeext'
11328 { (eval echo "$as_me:11328: \"$ac_try\"") >&5
11329 (eval $ac_try) 2>&5
11331 echo "$as_me:11331: \$? = $ac_status" >&5
11332 (exit $ac_status); }; }; then
11333 ac_cv_lib_mytinfo_tgoto=yes
11335 echo "$as_me: failed program was:" >&5
11336 cat conftest.$ac_ext >&5
11337 ac_cv_lib_mytinfo_tgoto=no
11339 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11340 LIBS=$ac_check_lib_save_LIBS
11342 echo "$as_me:11342: result: $ac_cv_lib_mytinfo_tgoto" >&5
11343 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
11344 if test $ac_cv_lib_mytinfo_tgoto = yes; then
11345 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
11352 cf_add_libs="$LIBS"
11355 for cf_add_1lib in $cf_ncurses_LIBS; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
11356 # filter duplicates
11357 for cf_add_1lib in $cf_add_0lib; do
11358 for cf_add_2lib in $cf_add_libs; do
11359 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
11364 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
11366 LIBS="$cf_add_libs"
11368 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
11371 cf_add_libs="$LIBS"
11374 for cf_add_1lib in -l$cf_nculib_root; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
11375 # filter duplicates
11376 for cf_add_1lib in $cf_add_0lib; do
11377 for cf_add_2lib in $cf_add_libs; do
11378 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
11383 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
11385 LIBS="$cf_add_libs"
11389 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
11391 echo "$as_me:11391: checking for initscr" >&5
11392 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
11393 if test "${ac_cv_func_initscr+set}" = set; then
11394 echo $ECHO_N "(cached) $ECHO_C" >&6
11396 cat >conftest.$ac_ext <<_ACEOF
11397 #line 11397 "configure"
11398 #include "confdefs.h"
11399 #define initscr autoconf_temporary
11400 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
11407 /* We use char because int might match the return type of a gcc2
11408 builtin and then its argument prototype would still apply. */
11409 char initscr (void);
11415 /* The GNU C library defines stubs for functions which it implements
11416 to always fail with ENOSYS. Some functions are actually named
11417 something starting with __ and the normal name is an alias. */
11418 #if defined (__stub_initscr) || defined (__stub___initscr)
11419 #error found stub for initscr
11427 rm -f conftest.$ac_objext conftest$ac_exeext
11428 if { (eval echo "$as_me:11428: \"$ac_link\"") >&5
11429 (eval $ac_link) 2>&5
11431 echo "$as_me:11431: \$? = $ac_status" >&5
11432 (exit $ac_status); } &&
11433 { ac_try='test -s conftest$ac_exeext'
11434 { (eval echo "$as_me:11434: \"$ac_try\"") >&5
11435 (eval $ac_try) 2>&5
11437 echo "$as_me:11437: \$? = $ac_status" >&5
11438 (exit $ac_status); }; }; then
11439 ac_cv_func_initscr=yes
11441 echo "$as_me: failed program was:" >&5
11442 cat conftest.$ac_ext >&5
11443 ac_cv_func_initscr=no
11445 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11447 echo "$as_me:11447: result: $ac_cv_func_initscr" >&5
11448 echo "${ECHO_T}$ac_cv_func_initscr" >&6
11449 if test $ac_cv_func_initscr = yes; then
11450 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
11453 cf_save_LIBS="$LIBS"
11454 echo "$as_me:11454: checking for initscr in -l$cf_nculib_root" >&5
11455 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
11456 LIBS="-l$cf_nculib_root $LIBS"
11457 cat >conftest.$ac_ext <<_ACEOF
11458 #line 11458 "configure"
11459 #include "confdefs.h"
11460 #include <${cf_cv_ncurses_header:-curses.h}>
11469 rm -f conftest.$ac_objext conftest$ac_exeext
11470 if { (eval echo "$as_me:11470: \"$ac_link\"") >&5
11471 (eval $ac_link) 2>&5
11473 echo "$as_me:11473: \$? = $ac_status" >&5
11474 (exit $ac_status); } &&
11475 { ac_try='test -s conftest$ac_exeext'
11476 { (eval echo "$as_me:11476: \"$ac_try\"") >&5
11477 (eval $ac_try) 2>&5
11479 echo "$as_me:11479: \$? = $ac_status" >&5
11480 (exit $ac_status); }; }; then
11481 echo "$as_me:11481: result: yes" >&5
11482 echo "${ECHO_T}yes" >&6
11483 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
11486 echo "$as_me: failed program was:" >&5
11487 cat conftest.$ac_ext >&5
11488 echo "$as_me:11488: result: no" >&5
11489 echo "${ECHO_T}no" >&6
11492 cf_library_path_list=""
11493 if test -n "${LDFLAGS}${LIBS}" ; then
11494 for cf_library_path in $LDFLAGS $LIBS
11496 case $cf_library_path in
11498 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
11500 test "x$cf_library_path" != "xNONE" && \
11501 test -d "$cf_library_path" && \
11503 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
11504 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
11505 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
11506 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
11507 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
11508 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"
11511 cf_library_path_list="$cf_library_path_list $cf_search"
11519 test "x$prefix" != "xNONE" && \
11520 test -d "$prefix" && \
11522 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
11523 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
11524 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
11525 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
11526 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
11527 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
11530 for cf_subdir_prefix in \
11539 test "x$cf_subdir_prefix" != "x$prefix" && \
11540 test -d "$cf_subdir_prefix" && \
11541 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
11542 test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
11543 test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib"
11544 test -d $cf_subdir_prefix/lib/$cf_nculib_root && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root"
11545 test -d $cf_subdir_prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root/lib"
11546 test -d $cf_subdir_prefix/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib"
11547 test -d $cf_subdir_prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib/$cf_nculib_root"
11552 cf_search="$cf_library_path_list $cf_search"
11554 for cf_libdir in $cf_search
11556 echo "$as_me:11556: checking for -l$cf_nculib_root in $cf_libdir" >&5
11557 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
11558 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
11559 cat >conftest.$ac_ext <<_ACEOF
11560 #line 11560 "configure"
11561 #include "confdefs.h"
11562 #include <${cf_cv_ncurses_header:-curses.h}>
11571 rm -f conftest.$ac_objext conftest$ac_exeext
11572 if { (eval echo "$as_me:11572: \"$ac_link\"") >&5
11573 (eval $ac_link) 2>&5
11575 echo "$as_me:11575: \$? = $ac_status" >&5
11576 (exit $ac_status); } &&
11577 { ac_try='test -s conftest$ac_exeext'
11578 { (eval echo "$as_me:11578: \"$ac_try\"") >&5
11579 (eval $ac_try) 2>&5
11581 echo "$as_me:11581: \$? = $ac_status" >&5
11582 (exit $ac_status); }; }; then
11583 echo "$as_me:11583: result: yes" >&5
11584 echo "${ECHO_T}yes" >&6
11585 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
11588 echo "$as_me: failed program was:" >&5
11589 cat conftest.$ac_ext >&5
11590 echo "$as_me:11590: result: no" >&5
11591 echo "${ECHO_T}no" >&6
11592 LIBS="$cf_save_LIBS"
11594 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11598 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11602 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
11604 if test $cf_found_library = no ; then
11605 { { echo "$as_me:11605: error: Cannot link $cf_nculib_root library" >&5
11606 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
11607 { (exit 1); exit 1; }; }
11612 if test -n "$cf_ncurses_LIBS" ; then
11613 echo "$as_me:11613: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
11614 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
11615 cf_ncurses_SAVE="$LIBS"
11616 for p in $cf_ncurses_LIBS ; do
11617 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
11618 if test "$q" != "$LIBS" ; then
11622 cat >conftest.$ac_ext <<_ACEOF
11623 #line 11623 "configure"
11624 #include "confdefs.h"
11625 #include <${cf_cv_ncurses_header:-curses.h}>
11629 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
11634 rm -f conftest.$ac_objext conftest$ac_exeext
11635 if { (eval echo "$as_me:11635: \"$ac_link\"") >&5
11636 (eval $ac_link) 2>&5
11638 echo "$as_me:11638: \$? = $ac_status" >&5
11639 (exit $ac_status); } &&
11640 { ac_try='test -s conftest$ac_exeext'
11641 { (eval echo "$as_me:11641: \"$ac_try\"") >&5
11642 (eval $ac_try) 2>&5
11644 echo "$as_me:11644: \$? = $ac_status" >&5
11645 (exit $ac_status); }; }; then
11646 echo "$as_me:11646: result: yes" >&5
11647 echo "${ECHO_T}yes" >&6
11649 echo "$as_me: failed program was:" >&5
11650 cat conftest.$ac_ext >&5
11651 echo "$as_me:11651: result: no" >&5
11652 echo "${ECHO_T}no" >&6
11653 LIBS="$cf_ncurses_SAVE"
11655 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11658 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
11660 cat >>confdefs.h <<EOF
11661 #define $cf_nculib_ROOT 1
11666 NCURSES_CONFIG=none
11671 echo "$as_me:11671: checking for X" >&5
11672 echo $ECHO_N "checking for X... $ECHO_C" >&6
11674 # Check whether --with-x or --without-x was given.
11675 if test "${with_x+set}" = set; then
11679 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
11680 if test "x$with_x" = xno; then
11681 # The user explicitly disabled X.
11684 if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
11685 # Both variables are already set.
11688 if test "${ac_cv_have_x+set}" = set; then
11689 echo $ECHO_N "(cached) $ECHO_C" >&6
11691 # One or both of the vars are not set, and there is no cached value.
11692 ac_x_includes=no ac_x_libraries=no
11693 rm -fr conftest.dir
11694 if mkdir conftest.dir; then
11696 # Make sure to not put "make" in the Imakefile rules, since we grep it out.
11697 cat >Imakefile <<'EOF'
11699 @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
11701 if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
11702 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
11703 eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
11704 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
11705 for ac_extension in a so sl dylib dll; do
11706 if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
11707 test -f $ac_im_libdir/libX11.$ac_extension; then
11708 ac_im_usrlibdir=$ac_im_libdir; break
11711 # Screen out bogus values from the imake configuration. They are
11712 # bogus both because they are the default anyway, and because
11713 # using them would break gcc on systems where it needs fixed includes.
11714 case $ac_im_incroot in
11716 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
11718 case $ac_im_usrlibdir in
11719 /usr/lib | /lib) ;;
11720 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
11724 rm -fr conftest.dir
11727 # Standard set of common directories for X headers.
11728 # Check X11 before X11Rn because it is often a symlink to the current release.
11745 /usr/local/X11/include
11746 /usr/local/X11R7/include
11747 /usr/local/X11R6/include
11748 /usr/local/X11R5/include
11749 /usr/local/X11R4/include
11751 /usr/local/include/X11
11752 /usr/local/include/X11R7
11753 /usr/local/include/X11R6
11754 /usr/local/include/X11R5
11755 /usr/local/include/X11R4
11759 /usr/XFree86/include/X11
11763 /usr/unsupported/include
11764 /usr/athena/include
11765 /usr/local/x11r5/include
11766 /usr/lpp/Xamples/include
11768 /usr/openwin/include
11769 /usr/openwin/share/include'
11771 if test "$ac_x_includes" = no; then
11772 # Guess where to find include files, by looking for Intrinsic.h.
11773 # First, try using that file with no special directory specified.
11774 cat >conftest.$ac_ext <<_ACEOF
11775 #line 11775 "configure"
11776 #include "confdefs.h"
11777 #include <X11/Intrinsic.h>
11779 if { (eval echo "$as_me:11779: \"$ac_cpp conftest.$ac_ext\"") >&5
11780 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11782 egrep -v '^ *\+' conftest.er1 >conftest.err
11784 cat conftest.err >&5
11785 echo "$as_me:11785: \$? = $ac_status" >&5
11786 (exit $ac_status); } >/dev/null; then
11787 if test -s conftest.err; then
11788 ac_cpp_err=$ac_c_preproc_warn_flag
11795 if test -z "$ac_cpp_err"; then
11796 # We can compile using X headers with no special include directory.
11799 echo "$as_me: failed program was:" >&5
11800 cat conftest.$ac_ext >&5
11801 for ac_dir in $ac_x_header_dirs; do
11802 if test -r "$ac_dir/X11/Intrinsic.h"; then
11803 ac_x_includes=$ac_dir
11808 rm -f conftest.err conftest.$ac_ext
11809 fi # $ac_x_includes = no
11811 if test "$ac_x_libraries" = no; then
11812 # Check for the libraries.
11813 # See if we find them without any special options.
11814 # Don't add to $LIBS permanently.
11817 cat >conftest.$ac_ext <<_ACEOF
11818 #line 11818 "configure"
11819 #include "confdefs.h"
11820 #include <X11/Intrinsic.h>
11829 rm -f conftest.$ac_objext conftest$ac_exeext
11830 if { (eval echo "$as_me:11830: \"$ac_link\"") >&5
11831 (eval $ac_link) 2>&5
11833 echo "$as_me:11833: \$? = $ac_status" >&5
11834 (exit $ac_status); } &&
11835 { ac_try='test -s conftest$ac_exeext'
11836 { (eval echo "$as_me:11836: \"$ac_try\"") >&5
11837 (eval $ac_try) 2>&5
11839 echo "$as_me:11839: \$? = $ac_status" >&5
11840 (exit $ac_status); }; }; then
11842 # We can link X programs with no special library path.
11845 echo "$as_me: failed program was:" >&5
11846 cat conftest.$ac_ext >&5
11848 for ac_dir in `echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
11850 # Don't even attempt the hair of trying to link an X program!
11851 for ac_extension in a so sl dylib dll; do
11852 if test -r $ac_dir/libXt.$ac_extension; then
11853 ac_x_libraries=$ac_dir
11859 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11860 fi # $ac_x_libraries = no
11862 if test "$ac_x_includes" = no || test "$ac_x_libraries" = no; then
11863 # Didn't find X anywhere. Cache the known absence of X.
11864 ac_cv_have_x="have_x=no"
11866 # Record where we found X for the cache.
11867 ac_cv_have_x="have_x=yes \
11868 ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
11873 eval "$ac_cv_have_x"
11876 if test "$have_x" != yes; then
11877 echo "$as_me:11877: result: $have_x" >&5
11878 echo "${ECHO_T}$have_x" >&6
11881 # If each of the values was on the command line, it overrides each guess.
11882 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
11883 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
11884 # Update the cache value to reflect the command line values.
11885 ac_cv_have_x="have_x=yes \
11886 ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
11887 echo "$as_me:11887: result: libraries $x_libraries, headers $x_includes" >&5
11888 echo "${ECHO_T}libraries $x_libraries, headers $x_includes" >&6
11891 if test "$no_x" = yes; then
11892 # Not all programs may use this symbol, but it does not hurt to define it.
11894 cat >>confdefs.h <<\EOF
11895 #define X_DISPLAY_MISSING 1
11898 X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS=
11900 if test -n "$x_includes"; then
11901 X_CFLAGS="$X_CFLAGS -I$x_includes"
11904 # It would also be nice to do this for all -L options, not just this one.
11905 if test -n "$x_libraries"; then
11906 X_LIBS="$X_LIBS -L$x_libraries"
11907 # For Solaris; some versions of Sun CC require a space after -R and
11908 # others require no space. Words are not sufficient . . . .
11909 case `(uname -sr) 2>/dev/null` in
11911 echo "$as_me:11911: checking whether -R must be followed by a space" >&5
11912 echo $ECHO_N "checking whether -R must be followed by a space... $ECHO_C" >&6
11913 ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries"
11914 cat >conftest.$ac_ext <<_ACEOF
11915 #line 11915 "configure"
11916 #include "confdefs.h"
11926 rm -f conftest.$ac_objext conftest$ac_exeext
11927 if { (eval echo "$as_me:11927: \"$ac_link\"") >&5
11928 (eval $ac_link) 2>&5
11930 echo "$as_me:11930: \$? = $ac_status" >&5
11931 (exit $ac_status); } &&
11932 { ac_try='test -s conftest$ac_exeext'
11933 { (eval echo "$as_me:11933: \"$ac_try\"") >&5
11934 (eval $ac_try) 2>&5
11936 echo "$as_me:11936: \$? = $ac_status" >&5
11937 (exit $ac_status); }; }; then
11940 echo "$as_me: failed program was:" >&5
11941 cat conftest.$ac_ext >&5
11944 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11945 if test $ac_R_nospace = yes; then
11946 echo "$as_me:11946: result: no" >&5
11947 echo "${ECHO_T}no" >&6
11948 X_LIBS="$X_LIBS -R$x_libraries"
11950 LIBS="$ac_xsave_LIBS -R $x_libraries"
11951 cat >conftest.$ac_ext <<_ACEOF
11952 #line 11952 "configure"
11953 #include "confdefs.h"
11963 rm -f conftest.$ac_objext conftest$ac_exeext
11964 if { (eval echo "$as_me:11964: \"$ac_link\"") >&5
11965 (eval $ac_link) 2>&5
11967 echo "$as_me:11967: \$? = $ac_status" >&5
11968 (exit $ac_status); } &&
11969 { ac_try='test -s conftest$ac_exeext'
11970 { (eval echo "$as_me:11970: \"$ac_try\"") >&5
11971 (eval $ac_try) 2>&5
11973 echo "$as_me:11973: \$? = $ac_status" >&5
11974 (exit $ac_status); }; }; then
11977 echo "$as_me: failed program was:" >&5
11978 cat conftest.$ac_ext >&5
11981 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11982 if test $ac_R_space = yes; then
11983 echo "$as_me:11983: result: yes" >&5
11984 echo "${ECHO_T}yes" >&6
11985 X_LIBS="$X_LIBS -R $x_libraries"
11987 echo "$as_me:11987: result: neither works" >&5
11988 echo "${ECHO_T}neither works" >&6
11991 LIBS=$ac_xsave_LIBS
11995 # Check for system-dependent libraries X programs must link with.
11996 # Do this before checking for the system-independent R6 libraries
11997 # (-lICE), since we may need -lsocket or whatever for X linking.
11999 if test "$ISC" = yes; then
12000 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
12002 # Martyn Johnson says this is needed for Ultrix, if the X
12003 # libraries were built with DECnet support. And Karl Berry says
12004 # the Alpha needs dnet_stub (dnet does not exist).
12005 ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11"
12006 cat >conftest.$ac_ext <<_ACEOF
12007 #line 12007 "configure"
12008 #include "confdefs.h"
12010 /* Override any gcc2 internal prototype to avoid an error. */
12014 /* We use char because int might match the return type of a gcc2
12015 builtin and then its argument prototype would still apply. */
12016 char XOpenDisplay ();
12025 rm -f conftest.$ac_objext conftest$ac_exeext
12026 if { (eval echo "$as_me:12026: \"$ac_link\"") >&5
12027 (eval $ac_link) 2>&5
12029 echo "$as_me:12029: \$? = $ac_status" >&5
12030 (exit $ac_status); } &&
12031 { ac_try='test -s conftest$ac_exeext'
12032 { (eval echo "$as_me:12032: \"$ac_try\"") >&5
12033 (eval $ac_try) 2>&5
12035 echo "$as_me:12035: \$? = $ac_status" >&5
12036 (exit $ac_status); }; }; then
12039 echo "$as_me: failed program was:" >&5
12040 cat conftest.$ac_ext >&5
12041 echo "$as_me:12041: checking for dnet_ntoa in -ldnet" >&5
12042 echo $ECHO_N "checking for dnet_ntoa in -ldnet... $ECHO_C" >&6
12043 if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then
12044 echo $ECHO_N "(cached) $ECHO_C" >&6
12046 ac_check_lib_save_LIBS=$LIBS
12047 LIBS="-ldnet $LIBS"
12048 cat >conftest.$ac_ext <<_ACEOF
12049 #line 12049 "configure"
12050 #include "confdefs.h"
12052 /* Override any gcc2 internal prototype to avoid an error. */
12056 /* We use char because int might match the return type of a gcc2
12057 builtin and then its argument prototype would still apply. */
12067 rm -f conftest.$ac_objext conftest$ac_exeext
12068 if { (eval echo "$as_me:12068: \"$ac_link\"") >&5
12069 (eval $ac_link) 2>&5
12071 echo "$as_me:12071: \$? = $ac_status" >&5
12072 (exit $ac_status); } &&
12073 { ac_try='test -s conftest$ac_exeext'
12074 { (eval echo "$as_me:12074: \"$ac_try\"") >&5
12075 (eval $ac_try) 2>&5
12077 echo "$as_me:12077: \$? = $ac_status" >&5
12078 (exit $ac_status); }; }; then
12079 ac_cv_lib_dnet_dnet_ntoa=yes
12081 echo "$as_me: failed program was:" >&5
12082 cat conftest.$ac_ext >&5
12083 ac_cv_lib_dnet_dnet_ntoa=no
12085 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12086 LIBS=$ac_check_lib_save_LIBS
12088 echo "$as_me:12088: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
12089 echo "${ECHO_T}$ac_cv_lib_dnet_dnet_ntoa" >&6
12090 if test $ac_cv_lib_dnet_dnet_ntoa = yes; then
12091 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
12094 if test $ac_cv_lib_dnet_dnet_ntoa = no; then
12095 echo "$as_me:12095: checking for dnet_ntoa in -ldnet_stub" >&5
12096 echo $ECHO_N "checking for dnet_ntoa in -ldnet_stub... $ECHO_C" >&6
12097 if test "${ac_cv_lib_dnet_stub_dnet_ntoa+set}" = set; then
12098 echo $ECHO_N "(cached) $ECHO_C" >&6
12100 ac_check_lib_save_LIBS=$LIBS
12101 LIBS="-ldnet_stub $LIBS"
12102 cat >conftest.$ac_ext <<_ACEOF
12103 #line 12103 "configure"
12104 #include "confdefs.h"
12106 /* Override any gcc2 internal prototype to avoid an error. */
12110 /* We use char because int might match the return type of a gcc2
12111 builtin and then its argument prototype would still apply. */
12121 rm -f conftest.$ac_objext conftest$ac_exeext
12122 if { (eval echo "$as_me:12122: \"$ac_link\"") >&5
12123 (eval $ac_link) 2>&5
12125 echo "$as_me:12125: \$? = $ac_status" >&5
12126 (exit $ac_status); } &&
12127 { ac_try='test -s conftest$ac_exeext'
12128 { (eval echo "$as_me:12128: \"$ac_try\"") >&5
12129 (eval $ac_try) 2>&5
12131 echo "$as_me:12131: \$? = $ac_status" >&5
12132 (exit $ac_status); }; }; then
12133 ac_cv_lib_dnet_stub_dnet_ntoa=yes
12135 echo "$as_me: failed program was:" >&5
12136 cat conftest.$ac_ext >&5
12137 ac_cv_lib_dnet_stub_dnet_ntoa=no
12139 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12140 LIBS=$ac_check_lib_save_LIBS
12142 echo "$as_me:12142: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5
12143 echo "${ECHO_T}$ac_cv_lib_dnet_stub_dnet_ntoa" >&6
12144 if test $ac_cv_lib_dnet_stub_dnet_ntoa = yes; then
12145 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
12150 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12151 LIBS="$ac_xsave_LIBS"
12153 # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT,
12154 # to get the SysV transport functions.
12155 # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4)
12157 # The nsl library prevents programs from opening the X display
12158 # on Irix 5.2, according to T.E. Dickey.
12159 # The functions gethostbyname, getservbyname, and inet_addr are
12160 # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking.
12161 echo "$as_me:12161: checking for gethostbyname" >&5
12162 echo $ECHO_N "checking for gethostbyname... $ECHO_C" >&6
12163 if test "${ac_cv_func_gethostbyname+set}" = set; then
12164 echo $ECHO_N "(cached) $ECHO_C" >&6
12166 cat >conftest.$ac_ext <<_ACEOF
12167 #line 12167 "configure"
12168 #include "confdefs.h"
12169 #define gethostbyname autoconf_temporary
12170 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
12171 #undef gethostbyname
12177 /* We use char because int might match the return type of a gcc2
12178 builtin and then its argument prototype would still apply. */
12179 char gethostbyname (void);
12185 /* The GNU C library defines stubs for functions which it implements
12186 to always fail with ENOSYS. Some functions are actually named
12187 something starting with __ and the normal name is an alias. */
12188 #if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
12189 #error found stub for gethostbyname
12192 return gethostbyname ();
12197 rm -f conftest.$ac_objext conftest$ac_exeext
12198 if { (eval echo "$as_me:12198: \"$ac_link\"") >&5
12199 (eval $ac_link) 2>&5
12201 echo "$as_me:12201: \$? = $ac_status" >&5
12202 (exit $ac_status); } &&
12203 { ac_try='test -s conftest$ac_exeext'
12204 { (eval echo "$as_me:12204: \"$ac_try\"") >&5
12205 (eval $ac_try) 2>&5
12207 echo "$as_me:12207: \$? = $ac_status" >&5
12208 (exit $ac_status); }; }; then
12209 ac_cv_func_gethostbyname=yes
12211 echo "$as_me: failed program was:" >&5
12212 cat conftest.$ac_ext >&5
12213 ac_cv_func_gethostbyname=no
12215 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12217 echo "$as_me:12217: result: $ac_cv_func_gethostbyname" >&5
12218 echo "${ECHO_T}$ac_cv_func_gethostbyname" >&6
12220 if test $ac_cv_func_gethostbyname = no; then
12221 echo "$as_me:12221: checking for gethostbyname in -lnsl" >&5
12222 echo $ECHO_N "checking for gethostbyname in -lnsl... $ECHO_C" >&6
12223 if test "${ac_cv_lib_nsl_gethostbyname+set}" = set; then
12224 echo $ECHO_N "(cached) $ECHO_C" >&6
12226 ac_check_lib_save_LIBS=$LIBS
12228 cat >conftest.$ac_ext <<_ACEOF
12229 #line 12229 "configure"
12230 #include "confdefs.h"
12232 /* Override any gcc2 internal prototype to avoid an error. */
12236 /* We use char because int might match the return type of a gcc2
12237 builtin and then its argument prototype would still apply. */
12238 char gethostbyname ();
12247 rm -f conftest.$ac_objext conftest$ac_exeext
12248 if { (eval echo "$as_me:12248: \"$ac_link\"") >&5
12249 (eval $ac_link) 2>&5
12251 echo "$as_me:12251: \$? = $ac_status" >&5
12252 (exit $ac_status); } &&
12253 { ac_try='test -s conftest$ac_exeext'
12254 { (eval echo "$as_me:12254: \"$ac_try\"") >&5
12255 (eval $ac_try) 2>&5
12257 echo "$as_me:12257: \$? = $ac_status" >&5
12258 (exit $ac_status); }; }; then
12259 ac_cv_lib_nsl_gethostbyname=yes
12261 echo "$as_me: failed program was:" >&5
12262 cat conftest.$ac_ext >&5
12263 ac_cv_lib_nsl_gethostbyname=no
12265 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12266 LIBS=$ac_check_lib_save_LIBS
12268 echo "$as_me:12268: result: $ac_cv_lib_nsl_gethostbyname" >&5
12269 echo "${ECHO_T}$ac_cv_lib_nsl_gethostbyname" >&6
12270 if test $ac_cv_lib_nsl_gethostbyname = yes; then
12271 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
12274 if test $ac_cv_lib_nsl_gethostbyname = no; then
12275 echo "$as_me:12275: checking for gethostbyname in -lbsd" >&5
12276 echo $ECHO_N "checking for gethostbyname in -lbsd... $ECHO_C" >&6
12277 if test "${ac_cv_lib_bsd_gethostbyname+set}" = set; then
12278 echo $ECHO_N "(cached) $ECHO_C" >&6
12280 ac_check_lib_save_LIBS=$LIBS
12282 cat >conftest.$ac_ext <<_ACEOF
12283 #line 12283 "configure"
12284 #include "confdefs.h"
12286 /* Override any gcc2 internal prototype to avoid an error. */
12290 /* We use char because int might match the return type of a gcc2
12291 builtin and then its argument prototype would still apply. */
12292 char gethostbyname ();
12301 rm -f conftest.$ac_objext conftest$ac_exeext
12302 if { (eval echo "$as_me:12302: \"$ac_link\"") >&5
12303 (eval $ac_link) 2>&5
12305 echo "$as_me:12305: \$? = $ac_status" >&5
12306 (exit $ac_status); } &&
12307 { ac_try='test -s conftest$ac_exeext'
12308 { (eval echo "$as_me:12308: \"$ac_try\"") >&5
12309 (eval $ac_try) 2>&5
12311 echo "$as_me:12311: \$? = $ac_status" >&5
12312 (exit $ac_status); }; }; then
12313 ac_cv_lib_bsd_gethostbyname=yes
12315 echo "$as_me: failed program was:" >&5
12316 cat conftest.$ac_ext >&5
12317 ac_cv_lib_bsd_gethostbyname=no
12319 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12320 LIBS=$ac_check_lib_save_LIBS
12322 echo "$as_me:12322: result: $ac_cv_lib_bsd_gethostbyname" >&5
12323 echo "${ECHO_T}$ac_cv_lib_bsd_gethostbyname" >&6
12324 if test $ac_cv_lib_bsd_gethostbyname = yes; then
12325 X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd"
12331 # lieder@skyler.mavd.honeywell.com says without -lsocket,
12332 # socket/setsockopt and other routines are undefined under SCO ODT
12333 # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary
12334 # on later versions), says Simon Leinen: it contains gethostby*
12335 # variants that don't use the nameserver (or something). -lsocket
12336 # must be given before -lnsl if both are needed. We assume that
12337 # if connect needs -lnsl, so does gethostbyname.
12338 echo "$as_me:12338: checking for connect" >&5
12339 echo $ECHO_N "checking for connect... $ECHO_C" >&6
12340 if test "${ac_cv_func_connect+set}" = set; then
12341 echo $ECHO_N "(cached) $ECHO_C" >&6
12343 cat >conftest.$ac_ext <<_ACEOF
12344 #line 12344 "configure"
12345 #include "confdefs.h"
12346 #define connect autoconf_temporary
12347 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
12354 /* We use char because int might match the return type of a gcc2
12355 builtin and then its argument prototype would still apply. */
12356 char connect (void);
12362 /* The GNU C library defines stubs for functions which it implements
12363 to always fail with ENOSYS. Some functions are actually named
12364 something starting with __ and the normal name is an alias. */
12365 #if defined (__stub_connect) || defined (__stub___connect)
12366 #error found stub for connect
12374 rm -f conftest.$ac_objext conftest$ac_exeext
12375 if { (eval echo "$as_me:12375: \"$ac_link\"") >&5
12376 (eval $ac_link) 2>&5
12378 echo "$as_me:12378: \$? = $ac_status" >&5
12379 (exit $ac_status); } &&
12380 { ac_try='test -s conftest$ac_exeext'
12381 { (eval echo "$as_me:12381: \"$ac_try\"") >&5
12382 (eval $ac_try) 2>&5
12384 echo "$as_me:12384: \$? = $ac_status" >&5
12385 (exit $ac_status); }; }; then
12386 ac_cv_func_connect=yes
12388 echo "$as_me: failed program was:" >&5
12389 cat conftest.$ac_ext >&5
12390 ac_cv_func_connect=no
12392 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12394 echo "$as_me:12394: result: $ac_cv_func_connect" >&5
12395 echo "${ECHO_T}$ac_cv_func_connect" >&6
12397 if test $ac_cv_func_connect = no; then
12398 echo "$as_me:12398: checking for connect in -lsocket" >&5
12399 echo $ECHO_N "checking for connect in -lsocket... $ECHO_C" >&6
12400 if test "${ac_cv_lib_socket_connect+set}" = set; then
12401 echo $ECHO_N "(cached) $ECHO_C" >&6
12403 ac_check_lib_save_LIBS=$LIBS
12404 LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
12405 cat >conftest.$ac_ext <<_ACEOF
12406 #line 12406 "configure"
12407 #include "confdefs.h"
12409 /* Override any gcc2 internal prototype to avoid an error. */
12413 /* We use char because int might match the return type of a gcc2
12414 builtin and then its argument prototype would still apply. */
12424 rm -f conftest.$ac_objext conftest$ac_exeext
12425 if { (eval echo "$as_me:12425: \"$ac_link\"") >&5
12426 (eval $ac_link) 2>&5
12428 echo "$as_me:12428: \$? = $ac_status" >&5
12429 (exit $ac_status); } &&
12430 { ac_try='test -s conftest$ac_exeext'
12431 { (eval echo "$as_me:12431: \"$ac_try\"") >&5
12432 (eval $ac_try) 2>&5
12434 echo "$as_me:12434: \$? = $ac_status" >&5
12435 (exit $ac_status); }; }; then
12436 ac_cv_lib_socket_connect=yes
12438 echo "$as_me: failed program was:" >&5
12439 cat conftest.$ac_ext >&5
12440 ac_cv_lib_socket_connect=no
12442 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12443 LIBS=$ac_check_lib_save_LIBS
12445 echo "$as_me:12445: result: $ac_cv_lib_socket_connect" >&5
12446 echo "${ECHO_T}$ac_cv_lib_socket_connect" >&6
12447 if test $ac_cv_lib_socket_connect = yes; then
12448 X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS"
12453 # Guillermo Gomez says -lposix is necessary on A/UX.
12454 echo "$as_me:12454: checking for remove" >&5
12455 echo $ECHO_N "checking for remove... $ECHO_C" >&6
12456 if test "${ac_cv_func_remove+set}" = set; then
12457 echo $ECHO_N "(cached) $ECHO_C" >&6
12459 cat >conftest.$ac_ext <<_ACEOF
12460 #line 12460 "configure"
12461 #include "confdefs.h"
12462 #define remove autoconf_temporary
12463 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
12470 /* We use char because int might match the return type of a gcc2
12471 builtin and then its argument prototype would still apply. */
12472 char remove (void);
12478 /* The GNU C library defines stubs for functions which it implements
12479 to always fail with ENOSYS. Some functions are actually named
12480 something starting with __ and the normal name is an alias. */
12481 #if defined (__stub_remove) || defined (__stub___remove)
12482 #error found stub for remove
12490 rm -f conftest.$ac_objext conftest$ac_exeext
12491 if { (eval echo "$as_me:12491: \"$ac_link\"") >&5
12492 (eval $ac_link) 2>&5
12494 echo "$as_me:12494: \$? = $ac_status" >&5
12495 (exit $ac_status); } &&
12496 { ac_try='test -s conftest$ac_exeext'
12497 { (eval echo "$as_me:12497: \"$ac_try\"") >&5
12498 (eval $ac_try) 2>&5
12500 echo "$as_me:12500: \$? = $ac_status" >&5
12501 (exit $ac_status); }; }; then
12502 ac_cv_func_remove=yes
12504 echo "$as_me: failed program was:" >&5
12505 cat conftest.$ac_ext >&5
12506 ac_cv_func_remove=no
12508 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12510 echo "$as_me:12510: result: $ac_cv_func_remove" >&5
12511 echo "${ECHO_T}$ac_cv_func_remove" >&6
12513 if test $ac_cv_func_remove = no; then
12514 echo "$as_me:12514: checking for remove in -lposix" >&5
12515 echo $ECHO_N "checking for remove in -lposix... $ECHO_C" >&6
12516 if test "${ac_cv_lib_posix_remove+set}" = set; then
12517 echo $ECHO_N "(cached) $ECHO_C" >&6
12519 ac_check_lib_save_LIBS=$LIBS
12520 LIBS="-lposix $LIBS"
12521 cat >conftest.$ac_ext <<_ACEOF
12522 #line 12522 "configure"
12523 #include "confdefs.h"
12525 /* Override any gcc2 internal prototype to avoid an error. */
12529 /* We use char because int might match the return type of a gcc2
12530 builtin and then its argument prototype would still apply. */
12540 rm -f conftest.$ac_objext conftest$ac_exeext
12541 if { (eval echo "$as_me:12541: \"$ac_link\"") >&5
12542 (eval $ac_link) 2>&5
12544 echo "$as_me:12544: \$? = $ac_status" >&5
12545 (exit $ac_status); } &&
12546 { ac_try='test -s conftest$ac_exeext'
12547 { (eval echo "$as_me:12547: \"$ac_try\"") >&5
12548 (eval $ac_try) 2>&5
12550 echo "$as_me:12550: \$? = $ac_status" >&5
12551 (exit $ac_status); }; }; then
12552 ac_cv_lib_posix_remove=yes
12554 echo "$as_me: failed program was:" >&5
12555 cat conftest.$ac_ext >&5
12556 ac_cv_lib_posix_remove=no
12558 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12559 LIBS=$ac_check_lib_save_LIBS
12561 echo "$as_me:12561: result: $ac_cv_lib_posix_remove" >&5
12562 echo "${ECHO_T}$ac_cv_lib_posix_remove" >&6
12563 if test $ac_cv_lib_posix_remove = yes; then
12564 X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix"
12569 # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
12570 echo "$as_me:12570: checking for shmat" >&5
12571 echo $ECHO_N "checking for shmat... $ECHO_C" >&6
12572 if test "${ac_cv_func_shmat+set}" = set; then
12573 echo $ECHO_N "(cached) $ECHO_C" >&6
12575 cat >conftest.$ac_ext <<_ACEOF
12576 #line 12576 "configure"
12577 #include "confdefs.h"
12578 #define shmat autoconf_temporary
12579 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
12586 /* We use char because int might match the return type of a gcc2
12587 builtin and then its argument prototype would still apply. */
12594 /* The GNU C library defines stubs for functions which it implements
12595 to always fail with ENOSYS. Some functions are actually named
12596 something starting with __ and the normal name is an alias. */
12597 #if defined (__stub_shmat) || defined (__stub___shmat)
12598 #error found stub for shmat
12606 rm -f conftest.$ac_objext conftest$ac_exeext
12607 if { (eval echo "$as_me:12607: \"$ac_link\"") >&5
12608 (eval $ac_link) 2>&5
12610 echo "$as_me:12610: \$? = $ac_status" >&5
12611 (exit $ac_status); } &&
12612 { ac_try='test -s conftest$ac_exeext'
12613 { (eval echo "$as_me:12613: \"$ac_try\"") >&5
12614 (eval $ac_try) 2>&5
12616 echo "$as_me:12616: \$? = $ac_status" >&5
12617 (exit $ac_status); }; }; then
12618 ac_cv_func_shmat=yes
12620 echo "$as_me: failed program was:" >&5
12621 cat conftest.$ac_ext >&5
12622 ac_cv_func_shmat=no
12624 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12626 echo "$as_me:12626: result: $ac_cv_func_shmat" >&5
12627 echo "${ECHO_T}$ac_cv_func_shmat" >&6
12629 if test $ac_cv_func_shmat = no; then
12630 echo "$as_me:12630: checking for shmat in -lipc" >&5
12631 echo $ECHO_N "checking for shmat in -lipc... $ECHO_C" >&6
12632 if test "${ac_cv_lib_ipc_shmat+set}" = set; then
12633 echo $ECHO_N "(cached) $ECHO_C" >&6
12635 ac_check_lib_save_LIBS=$LIBS
12637 cat >conftest.$ac_ext <<_ACEOF
12638 #line 12638 "configure"
12639 #include "confdefs.h"
12641 /* Override any gcc2 internal prototype to avoid an error. */
12645 /* We use char because int might match the return type of a gcc2
12646 builtin and then its argument prototype would still apply. */
12656 rm -f conftest.$ac_objext conftest$ac_exeext
12657 if { (eval echo "$as_me:12657: \"$ac_link\"") >&5
12658 (eval $ac_link) 2>&5
12660 echo "$as_me:12660: \$? = $ac_status" >&5
12661 (exit $ac_status); } &&
12662 { ac_try='test -s conftest$ac_exeext'
12663 { (eval echo "$as_me:12663: \"$ac_try\"") >&5
12664 (eval $ac_try) 2>&5
12666 echo "$as_me:12666: \$? = $ac_status" >&5
12667 (exit $ac_status); }; }; then
12668 ac_cv_lib_ipc_shmat=yes
12670 echo "$as_me: failed program was:" >&5
12671 cat conftest.$ac_ext >&5
12672 ac_cv_lib_ipc_shmat=no
12674 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12675 LIBS=$ac_check_lib_save_LIBS
12677 echo "$as_me:12677: result: $ac_cv_lib_ipc_shmat" >&5
12678 echo "${ECHO_T}$ac_cv_lib_ipc_shmat" >&6
12679 if test $ac_cv_lib_ipc_shmat = yes; then
12680 X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc"
12686 # Check for libraries that X11R6 Xt/Xaw programs need.
12687 ac_save_LDFLAGS=$LDFLAGS
12688 test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries"
12689 # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
12690 # check for ICE first), but we must link in the order -lSM -lICE or
12691 # we get undefined symbols. So assume we have SM if we have ICE.
12692 # These have to be linked with before -lX11, unlike the other
12693 # libraries we check for below, so use a different variable.
12694 # John Interrante, Karl Berry
12695 echo "$as_me:12695: checking for IceConnectionNumber in -lICE" >&5
12696 echo $ECHO_N "checking for IceConnectionNumber in -lICE... $ECHO_C" >&6
12697 if test "${ac_cv_lib_ICE_IceConnectionNumber+set}" = set; then
12698 echo $ECHO_N "(cached) $ECHO_C" >&6
12700 ac_check_lib_save_LIBS=$LIBS
12701 LIBS="-lICE $X_EXTRA_LIBS $LIBS"
12702 cat >conftest.$ac_ext <<_ACEOF
12703 #line 12703 "configure"
12704 #include "confdefs.h"
12706 /* Override any gcc2 internal prototype to avoid an error. */
12710 /* We use char because int might match the return type of a gcc2
12711 builtin and then its argument prototype would still apply. */
12712 char IceConnectionNumber ();
12716 IceConnectionNumber ();
12721 rm -f conftest.$ac_objext conftest$ac_exeext
12722 if { (eval echo "$as_me:12722: \"$ac_link\"") >&5
12723 (eval $ac_link) 2>&5
12725 echo "$as_me:12725: \$? = $ac_status" >&5
12726 (exit $ac_status); } &&
12727 { ac_try='test -s conftest$ac_exeext'
12728 { (eval echo "$as_me:12728: \"$ac_try\"") >&5
12729 (eval $ac_try) 2>&5
12731 echo "$as_me:12731: \$? = $ac_status" >&5
12732 (exit $ac_status); }; }; then
12733 ac_cv_lib_ICE_IceConnectionNumber=yes
12735 echo "$as_me: failed program was:" >&5
12736 cat conftest.$ac_ext >&5
12737 ac_cv_lib_ICE_IceConnectionNumber=no
12739 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12740 LIBS=$ac_check_lib_save_LIBS
12742 echo "$as_me:12742: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5
12743 echo "${ECHO_T}$ac_cv_lib_ICE_IceConnectionNumber" >&6
12744 if test $ac_cv_lib_ICE_IceConnectionNumber = yes; then
12745 X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
12748 LDFLAGS=$ac_save_LDFLAGS
12752 cf_x_athena=${cf_x_athena:-Xaw}
12754 echo "$as_me:12754: checking if you want to link with Xaw 3d library" >&5
12755 echo $ECHO_N "checking if you want to link with Xaw 3d library... $ECHO_C" >&6
12758 # Check whether --with-Xaw3d or --without-Xaw3d was given.
12759 if test "${with_Xaw3d+set}" = set; then
12760 withval="$with_Xaw3d"
12763 if test "$withval" = yes ; then
12765 echo "$as_me:12765: result: yes" >&5
12766 echo "${ECHO_T}yes" >&6
12768 echo "$as_me:12768: result: no" >&5
12769 echo "${ECHO_T}no" >&6
12772 echo "$as_me:12772: checking if you want to link with Xaw 3d xft library" >&5
12773 echo $ECHO_N "checking if you want to link with Xaw 3d xft library... $ECHO_C" >&6
12776 # Check whether --with-Xaw3dxft or --without-Xaw3dxft was given.
12777 if test "${with_Xaw3dxft+set}" = set; then
12778 withval="$with_Xaw3dxft"
12781 if test "$withval" = yes ; then
12782 cf_x_athena=Xaw3dxft
12783 echo "$as_me:12783: result: yes" >&5
12784 echo "${ECHO_T}yes" >&6
12786 echo "$as_me:12786: result: no" >&5
12787 echo "${ECHO_T}no" >&6
12790 echo "$as_me:12790: checking if you want to link with neXT Athena library" >&5
12791 echo $ECHO_N "checking if you want to link with neXT Athena library... $ECHO_C" >&6
12794 # Check whether --with-neXtaw or --without-neXtaw was given.
12795 if test "${with_neXtaw+set}" = set; then
12796 withval="$with_neXtaw"
12799 if test "$withval" = yes ; then
12801 echo "$as_me:12801: result: yes" >&5
12802 echo "${ECHO_T}yes" >&6
12804 echo "$as_me:12804: result: no" >&5
12805 echo "${ECHO_T}no" >&6
12808 echo "$as_me:12808: checking if you want to link with Athena-Plus library" >&5
12809 echo $ECHO_N "checking if you want to link with Athena-Plus library... $ECHO_C" >&6
12812 # Check whether --with-XawPlus or --without-XawPlus was given.
12813 if test "${with_XawPlus+set}" = set; then
12814 withval="$with_XawPlus"
12817 if test "$withval" = yes ; then
12818 cf_x_athena=XawPlus
12819 echo "$as_me:12819: result: yes" >&5
12820 echo "${ECHO_T}yes" >&6
12822 echo "$as_me:12822: result: no" >&5
12823 echo "${ECHO_T}no" >&6
12828 if test "$PKG_CONFIG" != none ; then
12830 test "$cf_x_athena" = Xaw && cf_athena_list="xaw8 xaw7 xaw6"
12831 for cf_athena_pkg in \
12834 ${cf_x_athena}-devel \
12835 lib${cf_x_athena} \
12836 lib${cf_x_athena}-devel
12839 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists $cf_athena_pkg; then
12840 test -n "$verbose" && echo " found package $cf_athena_pkg" 1>&6
12842 echo "${as_me:-configure}:12842: testing found package $cf_athena_pkg ..." 1>&5
12844 cf_pkgconfig_incs="`$PKG_CONFIG --cflags $cf_athena_pkg 2>/dev/null`"
12845 cf_pkgconfig_libs="`$PKG_CONFIG --libs $cf_athena_pkg 2>/dev/null`"
12846 test -n "$verbose" && echo " package $cf_athena_pkg CFLAGS: $cf_pkgconfig_incs" 1>&6
12848 echo "${as_me:-configure}:12848: testing package $cf_athena_pkg CFLAGS: $cf_pkgconfig_incs ..." 1>&5
12850 test -n "$verbose" && echo " package $cf_athena_pkg LIBS: $cf_pkgconfig_libs" 1>&6
12852 echo "${as_me:-configure}:12852: testing package $cf_athena_pkg LIBS: $cf_pkgconfig_libs ..." 1>&5
12857 cf_new_extra_cppflags=
12859 for cf_add_cflags in $cf_pkgconfig_incs
12861 case $cf_fix_cppflags in
12863 case $cf_add_cflags in
12864 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
12865 case $cf_add_cflags in
12867 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
12869 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12870 && test -z "${cf_tst_cflags}" \
12871 && cf_fix_cppflags=yes
12873 if test $cf_fix_cppflags = yes ; then
12875 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12876 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12879 elif test "${cf_tst_cflags}" = "\"'" ; then
12881 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12882 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12888 case "$CPPFLAGS" in
12892 case $cf_add_cflags in
12894 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12896 CPPFLAGS=`echo "$CPPFLAGS" | \
12897 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12898 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12903 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
12904 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
12911 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
12912 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
12919 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12920 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12922 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
12924 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12925 && test -z "${cf_tst_cflags}" \
12926 && cf_fix_cppflags=no
12931 if test -n "$cf_new_cflags" ; then
12933 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
12934 CFLAGS="${CFLAGS}$cf_new_cflags"
12938 if test -n "$cf_new_cppflags" ; then
12940 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
12941 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
12945 if test -n "$cf_new_extra_cppflags" ; then
12947 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
12948 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
12952 cf_add_libs="$LIBS"
12955 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
12956 # filter duplicates
12957 for cf_add_1lib in $cf_add_0lib; do
12958 for cf_add_2lib in $cf_add_libs; do
12959 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
12964 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
12966 LIBS="$cf_add_libs"
12968 cf_x_athena_lib="$cf_pkgconfig_libs"
12970 cf_x_athena_LIBS=`echo "HAVE_LIB_$cf_x_athena" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
12972 cat >>confdefs.h <<EOF
12973 #define $cf_x_athena_LIBS 1
12976 for cf_trim_lib in Xmu Xt X11
12979 (*-l$cf_trim_lib\ *-l$cf_trim_lib*)
12980 LIBS=`echo "$LIBS " | sed -e 's/ / /g' -e 's%-l'"$cf_trim_lib"' %%' -e 's/ $//'`
12981 test -n "$verbose" && echo " ..trimmed $LIBS" 1>&6
12983 echo "${as_me:-configure}:12983: testing ..trimmed $LIBS ..." 1>&5
12989 echo "$as_me:12989: checking for usable $cf_x_athena/Xmu package" >&5
12990 echo $ECHO_N "checking for usable $cf_x_athena/Xmu package... $ECHO_C" >&6
12991 if test "${cf_cv_xaw_compat+set}" = set; then
12992 echo $ECHO_N "(cached) $ECHO_C" >&6
12995 cat >conftest.$ac_ext <<_ACEOF
12996 #line 12996 "configure"
12997 #include "confdefs.h"
12999 #include <X11/Xmu/CharSet.h>
13005 int check = XmuCompareISOLatin1("big", "small");
13012 rm -f conftest.$ac_objext conftest$ac_exeext
13013 if { (eval echo "$as_me:13013: \"$ac_link\"") >&5
13014 (eval $ac_link) 2>&5
13016 echo "$as_me:13016: \$? = $ac_status" >&5
13017 (exit $ac_status); } &&
13018 { ac_try='test -s conftest$ac_exeext'
13019 { (eval echo "$as_me:13019: \"$ac_try\"") >&5
13020 (eval $ac_try) 2>&5
13022 echo "$as_me:13022: \$? = $ac_status" >&5
13023 (exit $ac_status); }; }; then
13024 cf_cv_xaw_compat=yes
13026 echo "$as_me: failed program was:" >&5
13027 cat conftest.$ac_ext >&5
13028 cf_cv_xaw_compat=no
13030 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13032 echo "$as_me:13032: result: $cf_cv_xaw_compat" >&5
13033 echo "${ECHO_T}$cf_cv_xaw_compat" >&6
13035 if test "$cf_cv_xaw_compat" = no
13037 # workaround for broken ".pc" files...
13038 case "$cf_x_athena_lib" in
13042 test -n "$verbose" && echo " work around broken package" 1>&6
13044 echo "${as_me:-configure}:13044: testing work around broken package ..." 1>&5
13046 cf_save_xmu="$LIBS"
13047 cf_first_lib=`echo "$cf_save_xmu" | sed -e 's/^ *//' -e 's/ .*//'`
13049 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xmu; then
13050 test -n "$verbose" && echo " found package xmu" 1>&6
13052 echo "${as_me:-configure}:13052: testing found package xmu ..." 1>&5
13054 cf_pkgconfig_incs="`$PKG_CONFIG --cflags xmu 2>/dev/null`"
13055 cf_pkgconfig_libs="`$PKG_CONFIG --libs xmu 2>/dev/null`"
13056 test -n "$verbose" && echo " package xmu CFLAGS: $cf_pkgconfig_incs" 1>&6
13058 echo "${as_me:-configure}:13058: testing package xmu CFLAGS: $cf_pkgconfig_incs ..." 1>&5
13060 test -n "$verbose" && echo " package xmu LIBS: $cf_pkgconfig_libs" 1>&6
13062 echo "${as_me:-configure}:13062: testing package xmu LIBS: $cf_pkgconfig_libs ..." 1>&5
13067 cf_new_extra_cppflags=
13069 for cf_add_cflags in $cf_pkgconfig_incs
13071 case $cf_fix_cppflags in
13073 case $cf_add_cflags in
13074 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
13075 case $cf_add_cflags in
13077 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
13079 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13080 && test -z "${cf_tst_cflags}" \
13081 && cf_fix_cppflags=yes
13083 if test $cf_fix_cppflags = yes ; then
13085 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13086 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13089 elif test "${cf_tst_cflags}" = "\"'" ; then
13091 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13092 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13098 case "$CPPFLAGS" in
13102 case $cf_add_cflags in
13104 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
13106 CPPFLAGS=`echo "$CPPFLAGS" | \
13107 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
13108 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
13113 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
13114 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
13121 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
13122 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
13129 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13130 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13132 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
13134 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13135 && test -z "${cf_tst_cflags}" \
13136 && cf_fix_cppflags=no
13141 if test -n "$cf_new_cflags" ; then
13143 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
13144 CFLAGS="${CFLAGS}$cf_new_cflags"
13148 if test -n "$cf_new_cppflags" ; then
13150 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13151 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
13155 if test -n "$cf_new_extra_cppflags" ; then
13157 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
13158 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
13162 cf_add_libs="$LIBS"
13165 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
13166 # filter duplicates
13167 for cf_add_1lib in $cf_add_0lib; do
13168 for cf_add_2lib in $cf_add_libs; do
13169 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
13174 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
13176 LIBS="$cf_add_libs"
13178 LIBS="$cf_save_xmu"
13180 test -n "$verbose" && echo " ...before $LIBS" 1>&6
13182 echo "${as_me:-configure}:13182: testing ...before $LIBS ..." 1>&5
13184 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%$cf_first_lib %$cf_first_lib $cf_pkgconfig_libs %" -e 's% % %g'`
13185 test -n "$verbose" && echo " ...after $LIBS" 1>&6
13187 echo "${as_me:-configure}:13187: testing ...after $LIBS ..." 1>&5
13193 test -n "$verbose" && echo " ...before $LIBS" 1>&6
13195 echo "${as_me:-configure}:13195: testing ...before $LIBS ..." 1>&5
13197 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%$cf_first_lib %$cf_first_lib -lXmu %" -e 's% % %g'`
13198 test -n "$verbose" && echo " ...after $LIBS" 1>&6
13200 echo "${as_me:-configure}:13200: testing ...after $LIBS ..." 1>&5
13204 for cf_trim_lib in Xmu Xt X11
13207 (*-l$cf_trim_lib\ *-l$cf_trim_lib*)
13208 LIBS=`echo "$LIBS " | sed -e 's/ / /g' -e 's%-l'"$cf_trim_lib"' %%' -e 's/ $//'`
13209 test -n "$verbose" && echo " ..trimmed $LIBS" 1>&6
13211 echo "${as_me:-configure}:13211: testing ..trimmed $LIBS ..." 1>&5
13231 if test -z "$cf_x_athena_lib" ; then
13233 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists Xext; then
13234 test -n "$verbose" && echo " found package Xext" 1>&6
13236 echo "${as_me:-configure}:13236: testing found package Xext ..." 1>&5
13238 cf_pkgconfig_incs="`$PKG_CONFIG --cflags Xext 2>/dev/null`"
13239 cf_pkgconfig_libs="`$PKG_CONFIG --libs Xext 2>/dev/null`"
13240 test -n "$verbose" && echo " package Xext CFLAGS: $cf_pkgconfig_incs" 1>&6
13242 echo "${as_me:-configure}:13242: testing package Xext CFLAGS: $cf_pkgconfig_incs ..." 1>&5
13244 test -n "$verbose" && echo " package Xext LIBS: $cf_pkgconfig_libs" 1>&6
13246 echo "${as_me:-configure}:13246: testing package Xext LIBS: $cf_pkgconfig_libs ..." 1>&5
13251 cf_new_extra_cppflags=
13253 for cf_add_cflags in $cf_pkgconfig_incs
13255 case $cf_fix_cppflags in
13257 case $cf_add_cflags in
13258 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
13259 case $cf_add_cflags in
13261 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
13263 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13264 && test -z "${cf_tst_cflags}" \
13265 && cf_fix_cppflags=yes
13267 if test $cf_fix_cppflags = yes ; then
13269 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13270 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13273 elif test "${cf_tst_cflags}" = "\"'" ; then
13275 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13276 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13282 case "$CPPFLAGS" in
13286 case $cf_add_cflags in
13288 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
13290 CPPFLAGS=`echo "$CPPFLAGS" | \
13291 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
13292 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
13297 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
13298 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
13305 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
13306 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
13313 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13314 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13316 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
13318 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13319 && test -z "${cf_tst_cflags}" \
13320 && cf_fix_cppflags=no
13325 if test -n "$cf_new_cflags" ; then
13327 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
13328 CFLAGS="${CFLAGS}$cf_new_cflags"
13332 if test -n "$cf_new_cppflags" ; then
13334 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13335 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
13339 if test -n "$cf_new_extra_cppflags" ; then
13341 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
13342 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
13346 cf_add_libs="$LIBS"
13349 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
13350 # filter duplicates
13351 for cf_add_1lib in $cf_add_0lib; do
13352 for cf_add_2lib in $cf_add_libs; do
13353 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
13358 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
13360 LIBS="$cf_add_libs"
13367 echo "$as_me:13367: checking for XextCreateExtension in -lXext" >&5
13368 echo $ECHO_N "checking for XextCreateExtension in -lXext... $ECHO_C" >&6
13369 if test "${ac_cv_lib_Xext_XextCreateExtension+set}" = set; then
13370 echo $ECHO_N "(cached) $ECHO_C" >&6
13372 ac_check_lib_save_LIBS=$LIBS
13373 LIBS="-lXext $LIBS"
13374 cat >conftest.$ac_ext <<_ACEOF
13375 #line 13375 "configure"
13376 #include "confdefs.h"
13378 /* Override any gcc2 internal prototype to avoid an error. */
13382 /* We use char because int might match the return type of a gcc2
13383 builtin and then its argument prototype would still apply. */
13384 char XextCreateExtension ();
13388 XextCreateExtension ();
13393 rm -f conftest.$ac_objext conftest$ac_exeext
13394 if { (eval echo "$as_me:13394: \"$ac_link\"") >&5
13395 (eval $ac_link) 2>&5
13397 echo "$as_me:13397: \$? = $ac_status" >&5
13398 (exit $ac_status); } &&
13399 { ac_try='test -s conftest$ac_exeext'
13400 { (eval echo "$as_me:13400: \"$ac_try\"") >&5
13401 (eval $ac_try) 2>&5
13403 echo "$as_me:13403: \$? = $ac_status" >&5
13404 (exit $ac_status); }; }; then
13405 ac_cv_lib_Xext_XextCreateExtension=yes
13407 echo "$as_me: failed program was:" >&5
13408 cat conftest.$ac_ext >&5
13409 ac_cv_lib_Xext_XextCreateExtension=no
13411 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13412 LIBS=$ac_check_lib_save_LIBS
13414 echo "$as_me:13414: result: $ac_cv_lib_Xext_XextCreateExtension" >&5
13415 echo "${ECHO_T}$ac_cv_lib_Xext_XextCreateExtension" >&6
13416 if test $ac_cv_lib_Xext_XextCreateExtension = yes; then
13418 cf_add_libs="$LIBS"
13421 for cf_add_1lib in -lXext; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
13422 # filter duplicates
13423 for cf_add_1lib in $cf_add_0lib; do
13424 for cf_add_2lib in $cf_add_libs; do
13425 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
13430 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
13432 LIBS="$cf_add_libs"
13438 # OSX is schizoid about who owns /usr/X11 (old) versus /opt/X11 (new) (and
13439 # in some cases has installed dummy files in the former, other cases replaced
13440 # it with a link to the new location). This complicates the configure script.
13441 # Check for that pitfall, and recover using pkg-config
13443 # If none of these are set, the configuration is almost certainly broken.
13444 if test -z "${X_CFLAGS}${X_PRE_LIBS}${X_LIBS}${X_EXTRA_LIBS}"
13447 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists x11; then
13448 test -n "$verbose" && echo " found package x11" 1>&6
13450 echo "${as_me:-configure}:13450: testing found package x11 ..." 1>&5
13452 cf_pkgconfig_incs="`$PKG_CONFIG --cflags x11 2>/dev/null`"
13453 cf_pkgconfig_libs="`$PKG_CONFIG --libs x11 2>/dev/null`"
13454 test -n "$verbose" && echo " package x11 CFLAGS: $cf_pkgconfig_incs" 1>&6
13456 echo "${as_me:-configure}:13456: testing package x11 CFLAGS: $cf_pkgconfig_incs ..." 1>&5
13458 test -n "$verbose" && echo " package x11 LIBS: $cf_pkgconfig_libs" 1>&6
13460 echo "${as_me:-configure}:13460: testing package x11 LIBS: $cf_pkgconfig_libs ..." 1>&5
13465 cf_new_extra_cppflags=
13467 for cf_add_cflags in $cf_pkgconfig_incs
13469 case $cf_fix_cppflags in
13471 case $cf_add_cflags in
13472 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
13473 case $cf_add_cflags in
13475 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
13477 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13478 && test -z "${cf_tst_cflags}" \
13479 && cf_fix_cppflags=yes
13481 if test $cf_fix_cppflags = yes ; then
13483 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13484 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13487 elif test "${cf_tst_cflags}" = "\"'" ; then
13489 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13490 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13496 case "$CPPFLAGS" in
13500 case $cf_add_cflags in
13502 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
13504 CPPFLAGS=`echo "$CPPFLAGS" | \
13505 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
13506 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
13511 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
13512 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
13519 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
13520 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
13527 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13528 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13530 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
13532 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13533 && test -z "${cf_tst_cflags}" \
13534 && cf_fix_cppflags=no
13539 if test -n "$cf_new_cflags" ; then
13541 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
13542 CFLAGS="${CFLAGS}$cf_new_cflags"
13546 if test -n "$cf_new_cppflags" ; then
13548 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13549 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
13553 if test -n "$cf_new_extra_cppflags" ; then
13555 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
13556 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
13560 cf_add_libs="$LIBS"
13563 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
13564 # filter duplicates
13565 for cf_add_1lib in $cf_add_0lib; do
13566 for cf_add_2lib in $cf_add_libs; do
13567 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
13572 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
13574 LIBS="$cf_add_libs"
13580 { echo "$as_me:13580: WARNING: unable to find X11 library" >&5
13581 echo "$as_me: WARNING: unable to find X11 library" >&2;}
13584 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists ice; then
13585 test -n "$verbose" && echo " found package ice" 1>&6
13587 echo "${as_me:-configure}:13587: testing found package ice ..." 1>&5
13589 cf_pkgconfig_incs="`$PKG_CONFIG --cflags ice 2>/dev/null`"
13590 cf_pkgconfig_libs="`$PKG_CONFIG --libs ice 2>/dev/null`"
13591 test -n "$verbose" && echo " package ice CFLAGS: $cf_pkgconfig_incs" 1>&6
13593 echo "${as_me:-configure}:13593: testing package ice CFLAGS: $cf_pkgconfig_incs ..." 1>&5
13595 test -n "$verbose" && echo " package ice LIBS: $cf_pkgconfig_libs" 1>&6
13597 echo "${as_me:-configure}:13597: testing package ice LIBS: $cf_pkgconfig_libs ..." 1>&5
13602 cf_new_extra_cppflags=
13604 for cf_add_cflags in $cf_pkgconfig_incs
13606 case $cf_fix_cppflags in
13608 case $cf_add_cflags in
13609 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
13610 case $cf_add_cflags in
13612 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
13614 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13615 && test -z "${cf_tst_cflags}" \
13616 && cf_fix_cppflags=yes
13618 if test $cf_fix_cppflags = yes ; then
13620 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13621 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13624 elif test "${cf_tst_cflags}" = "\"'" ; then
13626 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13627 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13633 case "$CPPFLAGS" in
13637 case $cf_add_cflags in
13639 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
13641 CPPFLAGS=`echo "$CPPFLAGS" | \
13642 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
13643 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
13648 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
13649 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
13656 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
13657 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
13664 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13665 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13667 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
13669 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13670 && test -z "${cf_tst_cflags}" \
13671 && cf_fix_cppflags=no
13676 if test -n "$cf_new_cflags" ; then
13678 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
13679 CFLAGS="${CFLAGS}$cf_new_cflags"
13683 if test -n "$cf_new_cppflags" ; then
13685 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13686 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
13690 if test -n "$cf_new_extra_cppflags" ; then
13692 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
13693 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
13697 cf_add_libs="$LIBS"
13700 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
13701 # filter duplicates
13702 for cf_add_1lib in $cf_add_0lib; do
13703 for cf_add_2lib in $cf_add_libs; do
13704 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
13709 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
13711 LIBS="$cf_add_libs"
13717 { echo "$as_me:13717: WARNING: unable to find ICE library" >&5
13718 echo "$as_me: WARNING: unable to find ICE library" >&2;}
13721 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists sm; then
13722 test -n "$verbose" && echo " found package sm" 1>&6
13724 echo "${as_me:-configure}:13724: testing found package sm ..." 1>&5
13726 cf_pkgconfig_incs="`$PKG_CONFIG --cflags sm 2>/dev/null`"
13727 cf_pkgconfig_libs="`$PKG_CONFIG --libs sm 2>/dev/null`"
13728 test -n "$verbose" && echo " package sm CFLAGS: $cf_pkgconfig_incs" 1>&6
13730 echo "${as_me:-configure}:13730: testing package sm CFLAGS: $cf_pkgconfig_incs ..." 1>&5
13732 test -n "$verbose" && echo " package sm LIBS: $cf_pkgconfig_libs" 1>&6
13734 echo "${as_me:-configure}:13734: testing package sm LIBS: $cf_pkgconfig_libs ..." 1>&5
13739 cf_new_extra_cppflags=
13741 for cf_add_cflags in $cf_pkgconfig_incs
13743 case $cf_fix_cppflags in
13745 case $cf_add_cflags in
13746 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
13747 case $cf_add_cflags in
13749 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
13751 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13752 && test -z "${cf_tst_cflags}" \
13753 && cf_fix_cppflags=yes
13755 if test $cf_fix_cppflags = yes ; then
13757 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13758 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13761 elif test "${cf_tst_cflags}" = "\"'" ; then
13763 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13764 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13770 case "$CPPFLAGS" in
13774 case $cf_add_cflags in
13776 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
13778 CPPFLAGS=`echo "$CPPFLAGS" | \
13779 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
13780 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
13785 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
13786 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
13793 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
13794 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
13801 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13802 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13804 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
13806 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13807 && test -z "${cf_tst_cflags}" \
13808 && cf_fix_cppflags=no
13813 if test -n "$cf_new_cflags" ; then
13815 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
13816 CFLAGS="${CFLAGS}$cf_new_cflags"
13820 if test -n "$cf_new_cppflags" ; then
13822 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13823 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
13827 if test -n "$cf_new_extra_cppflags" ; then
13829 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
13830 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
13834 cf_add_libs="$LIBS"
13837 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
13838 # filter duplicates
13839 for cf_add_1lib in $cf_add_0lib; do
13840 for cf_add_2lib in $cf_add_libs; do
13841 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
13846 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
13848 LIBS="$cf_add_libs"
13854 { echo "$as_me:13854: WARNING: unable to find SM library" >&5
13855 echo "$as_me: WARNING: unable to find SM library" >&2;}
13858 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xt; then
13859 test -n "$verbose" && echo " found package xt" 1>&6
13861 echo "${as_me:-configure}:13861: testing found package xt ..." 1>&5
13863 cf_pkgconfig_incs="`$PKG_CONFIG --cflags xt 2>/dev/null`"
13864 cf_pkgconfig_libs="`$PKG_CONFIG --libs xt 2>/dev/null`"
13865 test -n "$verbose" && echo " package xt CFLAGS: $cf_pkgconfig_incs" 1>&6
13867 echo "${as_me:-configure}:13867: testing package xt CFLAGS: $cf_pkgconfig_incs ..." 1>&5
13869 test -n "$verbose" && echo " package xt LIBS: $cf_pkgconfig_libs" 1>&6
13871 echo "${as_me:-configure}:13871: testing package xt LIBS: $cf_pkgconfig_libs ..." 1>&5
13876 cf_new_extra_cppflags=
13878 for cf_add_cflags in $cf_pkgconfig_incs
13880 case $cf_fix_cppflags in
13882 case $cf_add_cflags in
13883 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
13884 case $cf_add_cflags in
13886 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
13888 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13889 && test -z "${cf_tst_cflags}" \
13890 && cf_fix_cppflags=yes
13892 if test $cf_fix_cppflags = yes ; then
13894 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13895 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13898 elif test "${cf_tst_cflags}" = "\"'" ; then
13900 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13901 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13907 case "$CPPFLAGS" in
13911 case $cf_add_cflags in
13913 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
13915 CPPFLAGS=`echo "$CPPFLAGS" | \
13916 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
13917 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
13922 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
13923 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
13930 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
13931 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
13938 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13939 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13941 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
13943 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13944 && test -z "${cf_tst_cflags}" \
13945 && cf_fix_cppflags=no
13950 if test -n "$cf_new_cflags" ; then
13952 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
13953 CFLAGS="${CFLAGS}$cf_new_cflags"
13957 if test -n "$cf_new_cppflags" ; then
13959 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13960 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
13964 if test -n "$cf_new_extra_cppflags" ; then
13966 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
13967 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
13971 cf_add_libs="$LIBS"
13974 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
13975 # filter duplicates
13976 for cf_add_1lib in $cf_add_0lib; do
13977 for cf_add_2lib in $cf_add_libs; do
13978 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
13983 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
13985 LIBS="$cf_add_libs"
13991 { echo "$as_me:13991: WARNING: unable to find Xt library" >&5
13992 echo "$as_me: WARNING: unable to find Xt library" >&2;}
13996 LIBS="$X_PRE_LIBS $LIBS $X_EXTRA_LIBS"
14001 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xt; then
14002 test -n "$verbose" && echo " found package xt" 1>&6
14004 echo "${as_me:-configure}:14004: testing found package xt ..." 1>&5
14006 cf_pkgconfig_incs="`$PKG_CONFIG --cflags xt 2>/dev/null`"
14007 cf_pkgconfig_libs="`$PKG_CONFIG --libs xt 2>/dev/null`"
14008 test -n "$verbose" && echo " package xt CFLAGS: $cf_pkgconfig_incs" 1>&6
14010 echo "${as_me:-configure}:14010: testing package xt CFLAGS: $cf_pkgconfig_incs ..." 1>&5
14012 test -n "$verbose" && echo " package xt LIBS: $cf_pkgconfig_libs" 1>&6
14014 echo "${as_me:-configure}:14014: testing package xt LIBS: $cf_pkgconfig_libs ..." 1>&5
14019 cf_new_extra_cppflags=
14021 for cf_add_cflags in $cf_pkgconfig_incs
14023 case $cf_fix_cppflags in
14025 case $cf_add_cflags in
14026 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
14027 case $cf_add_cflags in
14029 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
14031 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14032 && test -z "${cf_tst_cflags}" \
14033 && cf_fix_cppflags=yes
14035 if test $cf_fix_cppflags = yes ; then
14037 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14038 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14041 elif test "${cf_tst_cflags}" = "\"'" ; then
14043 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14044 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14050 case "$CPPFLAGS" in
14054 case $cf_add_cflags in
14056 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
14058 CPPFLAGS=`echo "$CPPFLAGS" | \
14059 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
14060 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
14065 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
14066 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
14073 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
14074 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
14081 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14082 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14084 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
14086 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14087 && test -z "${cf_tst_cflags}" \
14088 && cf_fix_cppflags=no
14093 if test -n "$cf_new_cflags" ; then
14095 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
14096 CFLAGS="${CFLAGS}$cf_new_cflags"
14100 if test -n "$cf_new_cppflags" ; then
14102 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
14103 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
14107 if test -n "$cf_new_extra_cppflags" ; then
14109 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
14110 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
14114 cf_add_libs="$LIBS"
14117 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
14118 # filter duplicates
14119 for cf_add_1lib in $cf_add_0lib; do
14120 for cf_add_2lib in $cf_add_libs; do
14121 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
14126 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
14128 LIBS="$cf_add_libs"
14134 # we have an "xt" package, but it may omit Xt's dependency on X11
14135 echo "$as_me:14135: checking for usable X dependency" >&5
14136 echo $ECHO_N "checking for usable X dependency... $ECHO_C" >&6
14137 if test "${cf_cv_xt_x11_compat+set}" = set; then
14138 echo $ECHO_N "(cached) $ECHO_C" >&6
14141 cat >conftest.$ac_ext <<_ACEOF
14142 #line 14142 "configure"
14143 #include "confdefs.h"
14145 #include <X11/Xlib.h>
14151 int rc1 = XDrawLine((Display*) 0, (Drawable) 0, (GC) 0, 0, 0, 0, 0);
14152 int rc2 = XClearWindow((Display*) 0, (Window) 0);
14153 int rc3 = XMoveWindow((Display*) 0, (Window) 0, 0, 0);
14154 int rc4 = XMoveResizeWindow((Display*)0, (Window)0, 0, 0, 0, 0);
14160 rm -f conftest.$ac_objext conftest$ac_exeext
14161 if { (eval echo "$as_me:14161: \"$ac_link\"") >&5
14162 (eval $ac_link) 2>&5
14164 echo "$as_me:14164: \$? = $ac_status" >&5
14165 (exit $ac_status); } &&
14166 { ac_try='test -s conftest$ac_exeext'
14167 { (eval echo "$as_me:14167: \"$ac_try\"") >&5
14168 (eval $ac_try) 2>&5
14170 echo "$as_me:14170: \$? = $ac_status" >&5
14171 (exit $ac_status); }; }; then
14172 cf_cv_xt_x11_compat=yes
14174 echo "$as_me: failed program was:" >&5
14175 cat conftest.$ac_ext >&5
14176 cf_cv_xt_x11_compat=no
14178 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14180 echo "$as_me:14180: result: $cf_cv_xt_x11_compat" >&5
14181 echo "${ECHO_T}$cf_cv_xt_x11_compat" >&6
14182 if test "$cf_cv_xt_x11_compat" = no
14184 test -n "$verbose" && echo " work around broken X11 dependency" 1>&6
14186 echo "${as_me:-configure}:14186: testing work around broken X11 dependency ..." 1>&5
14188 # 2010/11/19 - good enough until a working Xt on Xcb is delivered.
14190 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists x11; then
14191 test -n "$verbose" && echo " found package x11" 1>&6
14193 echo "${as_me:-configure}:14193: testing found package x11 ..." 1>&5
14195 cf_pkgconfig_incs="`$PKG_CONFIG --cflags x11 2>/dev/null`"
14196 cf_pkgconfig_libs="`$PKG_CONFIG --libs x11 2>/dev/null`"
14197 test -n "$verbose" && echo " package x11 CFLAGS: $cf_pkgconfig_incs" 1>&6
14199 echo "${as_me:-configure}:14199: testing package x11 CFLAGS: $cf_pkgconfig_incs ..." 1>&5
14201 test -n "$verbose" && echo " package x11 LIBS: $cf_pkgconfig_libs" 1>&6
14203 echo "${as_me:-configure}:14203: testing package x11 LIBS: $cf_pkgconfig_libs ..." 1>&5
14208 cf_new_extra_cppflags=
14210 for cf_add_cflags in $cf_pkgconfig_incs
14212 case $cf_fix_cppflags in
14214 case $cf_add_cflags in
14215 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
14216 case $cf_add_cflags in
14218 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
14220 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14221 && test -z "${cf_tst_cflags}" \
14222 && cf_fix_cppflags=yes
14224 if test $cf_fix_cppflags = yes ; then
14226 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14227 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14230 elif test "${cf_tst_cflags}" = "\"'" ; then
14232 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14233 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14239 case "$CPPFLAGS" in
14243 case $cf_add_cflags in
14245 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
14247 CPPFLAGS=`echo "$CPPFLAGS" | \
14248 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
14249 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
14254 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
14255 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
14262 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
14263 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
14270 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14271 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14273 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
14275 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14276 && test -z "${cf_tst_cflags}" \
14277 && cf_fix_cppflags=no
14282 if test -n "$cf_new_cflags" ; then
14284 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
14285 CFLAGS="${CFLAGS}$cf_new_cflags"
14289 if test -n "$cf_new_cppflags" ; then
14291 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
14292 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
14296 if test -n "$cf_new_extra_cppflags" ; then
14298 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
14299 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
14303 cf_add_libs="$LIBS"
14306 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
14307 # filter duplicates
14308 for cf_add_1lib in $cf_add_0lib; do
14309 for cf_add_2lib in $cf_add_libs; do
14310 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
14315 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
14317 LIBS="$cf_add_libs"
14324 test -n "$verbose" && echo " ...before $LIBS" 1>&6
14326 echo "${as_me:-configure}:14326: testing ...before $LIBS ..." 1>&5
14328 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%-lXt %-lXt -lX11 %" -e 's% % %g'`
14329 test -n "$verbose" && echo " ...after $LIBS" 1>&6
14331 echo "${as_me:-configure}:14331: testing ...after $LIBS ..." 1>&5
14339 echo "$as_me:14339: checking for usable X Toolkit package" >&5
14340 echo $ECHO_N "checking for usable X Toolkit package... $ECHO_C" >&6
14341 if test "${cf_cv_xt_ice_compat+set}" = set; then
14342 echo $ECHO_N "(cached) $ECHO_C" >&6
14345 cat >conftest.$ac_ext <<_ACEOF
14346 #line 14346 "configure"
14347 #include "confdefs.h"
14349 #include <X11/Shell.h>
14354 int num = IceConnectionNumber(0); (void) num
14360 rm -f conftest.$ac_objext conftest$ac_exeext
14361 if { (eval echo "$as_me:14361: \"$ac_link\"") >&5
14362 (eval $ac_link) 2>&5
14364 echo "$as_me:14364: \$? = $ac_status" >&5
14365 (exit $ac_status); } &&
14366 { ac_try='test -s conftest$ac_exeext'
14367 { (eval echo "$as_me:14367: \"$ac_try\"") >&5
14368 (eval $ac_try) 2>&5
14370 echo "$as_me:14370: \$? = $ac_status" >&5
14371 (exit $ac_status); }; }; then
14372 cf_cv_xt_ice_compat=yes
14374 echo "$as_me: failed program was:" >&5
14375 cat conftest.$ac_ext >&5
14376 cf_cv_xt_ice_compat=no
14378 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14380 echo "$as_me:14380: result: $cf_cv_xt_ice_compat" >&5
14381 echo "${ECHO_T}$cf_cv_xt_ice_compat" >&6
14383 if test "$cf_cv_xt_ice_compat" = no
14385 # workaround for broken ".pc" files used for X Toolkit.
14386 case "x$X_PRE_LIBS" in
14392 test -n "$verbose" && echo " work around broken ICE dependency" 1>&6
14394 echo "${as_me:-configure}:14394: testing work around broken ICE dependency ..." 1>&5
14396 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists ice; then
14397 test -n "$verbose" && echo " found package ice" 1>&6
14399 echo "${as_me:-configure}:14399: testing found package ice ..." 1>&5
14401 cf_pkgconfig_incs="`$PKG_CONFIG --cflags ice 2>/dev/null`"
14402 cf_pkgconfig_libs="`$PKG_CONFIG --libs ice 2>/dev/null`"
14403 test -n "$verbose" && echo " package ice CFLAGS: $cf_pkgconfig_incs" 1>&6
14405 echo "${as_me:-configure}:14405: testing package ice CFLAGS: $cf_pkgconfig_incs ..." 1>&5
14407 test -n "$verbose" && echo " package ice LIBS: $cf_pkgconfig_libs" 1>&6
14409 echo "${as_me:-configure}:14409: testing package ice LIBS: $cf_pkgconfig_libs ..." 1>&5
14414 cf_new_extra_cppflags=
14416 for cf_add_cflags in $cf_pkgconfig_incs
14418 case $cf_fix_cppflags in
14420 case $cf_add_cflags in
14421 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
14422 case $cf_add_cflags in
14424 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
14426 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14427 && test -z "${cf_tst_cflags}" \
14428 && cf_fix_cppflags=yes
14430 if test $cf_fix_cppflags = yes ; then
14432 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14433 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14436 elif test "${cf_tst_cflags}" = "\"'" ; then
14438 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14439 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14445 case "$CPPFLAGS" in
14449 case $cf_add_cflags in
14451 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
14453 CPPFLAGS=`echo "$CPPFLAGS" | \
14454 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
14455 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
14460 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
14461 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
14468 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
14469 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
14476 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14477 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14479 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
14481 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14482 && test -z "${cf_tst_cflags}" \
14483 && cf_fix_cppflags=no
14488 if test -n "$cf_new_cflags" ; then
14490 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
14491 CFLAGS="${CFLAGS}$cf_new_cflags"
14495 if test -n "$cf_new_cppflags" ; then
14497 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
14498 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
14502 if test -n "$cf_new_extra_cppflags" ; then
14504 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
14505 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
14509 cf_add_libs="$LIBS"
14512 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
14513 # filter duplicates
14514 for cf_add_1lib in $cf_add_0lib; do
14515 for cf_add_2lib in $cf_add_libs; do
14516 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
14521 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
14523 LIBS="$cf_add_libs"
14525 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists sm; then
14526 test -n "$verbose" && echo " found package sm" 1>&6
14528 echo "${as_me:-configure}:14528: testing found package sm ..." 1>&5
14530 cf_pkgconfig_incs="`$PKG_CONFIG --cflags sm 2>/dev/null`"
14531 cf_pkgconfig_libs="`$PKG_CONFIG --libs sm 2>/dev/null`"
14532 test -n "$verbose" && echo " package sm CFLAGS: $cf_pkgconfig_incs" 1>&6
14534 echo "${as_me:-configure}:14534: testing package sm CFLAGS: $cf_pkgconfig_incs ..." 1>&5
14536 test -n "$verbose" && echo " package sm LIBS: $cf_pkgconfig_libs" 1>&6
14538 echo "${as_me:-configure}:14538: testing package sm LIBS: $cf_pkgconfig_libs ..." 1>&5
14543 cf_new_extra_cppflags=
14545 for cf_add_cflags in $cf_pkgconfig_incs
14547 case $cf_fix_cppflags in
14549 case $cf_add_cflags in
14550 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
14551 case $cf_add_cflags in
14553 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
14555 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14556 && test -z "${cf_tst_cflags}" \
14557 && cf_fix_cppflags=yes
14559 if test $cf_fix_cppflags = yes ; then
14561 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14562 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14565 elif test "${cf_tst_cflags}" = "\"'" ; then
14567 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14568 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14574 case "$CPPFLAGS" in
14578 case $cf_add_cflags in
14580 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
14582 CPPFLAGS=`echo "$CPPFLAGS" | \
14583 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
14584 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
14589 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
14590 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
14597 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
14598 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
14605 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14606 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14608 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
14610 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14611 && test -z "${cf_tst_cflags}" \
14612 && cf_fix_cppflags=no
14617 if test -n "$cf_new_cflags" ; then
14619 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
14620 CFLAGS="${CFLAGS}$cf_new_cflags"
14624 if test -n "$cf_new_cppflags" ; then
14626 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
14627 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
14631 if test -n "$cf_new_extra_cppflags" ; then
14633 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
14634 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
14638 cf_add_libs="$LIBS"
14641 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
14642 # filter duplicates
14643 for cf_add_1lib in $cf_add_0lib; do
14644 for cf_add_2lib in $cf_add_libs; do
14645 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
14650 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
14652 LIBS="$cf_add_libs"
14665 test -n "$verbose" && echo " ...before $LIBS" 1>&6
14667 echo "${as_me:-configure}:14667: testing ...before $LIBS ..." 1>&5
14669 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%-lXt %-lXt $X_PRE_LIBS %" -e 's% % %g'`
14670 test -n "$verbose" && echo " ...after $LIBS" 1>&6
14672 echo "${as_me:-configure}:14672: testing ...after $LIBS ..." 1>&5
14688 LDFLAGS="$X_LIBS $LDFLAGS"
14690 test -n "$verbose" && echo " checking additions to CFLAGS" 1>&6
14692 echo "${as_me:-configure}:14692: testing checking additions to CFLAGS ..." 1>&5
14694 cf_check_cflags="$CFLAGS"
14695 cf_check_cppflags="$CPPFLAGS"
14700 cf_new_extra_cppflags=
14702 for cf_add_cflags in $X_CFLAGS
14704 case $cf_fix_cppflags in
14706 case $cf_add_cflags in
14707 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
14708 case $cf_add_cflags in
14710 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
14712 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14713 && test -z "${cf_tst_cflags}" \
14714 && cf_fix_cppflags=yes
14716 if test $cf_fix_cppflags = yes ; then
14718 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14719 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14722 elif test "${cf_tst_cflags}" = "\"'" ; then
14724 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14725 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14731 case "$CPPFLAGS" in
14735 case $cf_add_cflags in
14737 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
14739 CPPFLAGS=`echo "$CPPFLAGS" | \
14740 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
14741 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
14746 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
14747 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
14754 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
14755 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
14762 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14763 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14765 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
14767 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14768 && test -z "${cf_tst_cflags}" \
14769 && cf_fix_cppflags=no
14774 if test -n "$cf_new_cflags" ; then
14775 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
14777 echo "${as_me:-configure}:14777: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
14779 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
14780 CFLAGS="${CFLAGS}$cf_new_cflags"
14784 if test -n "$cf_new_cppflags" ; then
14785 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
14787 echo "${as_me:-configure}:14787: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
14789 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
14790 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
14794 if test -n "$cf_new_extra_cppflags" ; then
14795 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
14797 echo "${as_me:-configure}:14797: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
14799 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
14800 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
14804 if test "x$cf_check_cflags" != "x$CFLAGS" ; then
14805 cat >conftest.$ac_ext <<_ACEOF
14806 #line 14806 "configure"
14807 #include "confdefs.h"
14812 printf("Hello world");
14817 rm -f conftest.$ac_objext conftest$ac_exeext
14818 if { (eval echo "$as_me:14818: \"$ac_link\"") >&5
14819 (eval $ac_link) 2>&5
14821 echo "$as_me:14821: \$? = $ac_status" >&5
14822 (exit $ac_status); } &&
14823 { ac_try='test -s conftest$ac_exeext'
14824 { (eval echo "$as_me:14824: \"$ac_try\"") >&5
14825 (eval $ac_try) 2>&5
14827 echo "$as_me:14827: \$? = $ac_status" >&5
14828 (exit $ac_status); }; }; then
14831 echo "$as_me: failed program was:" >&5
14832 cat conftest.$ac_ext >&5
14833 test -n "$verbose" && echo " test-compile failed. Undoing change to \$CFLAGS" 1>&6
14835 echo "${as_me:-configure}:14835: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5
14837 if test "x$cf_check_cppflags" != "x$CPPFLAGS" ; then
14838 test -n "$verbose" && echo " but keeping change to \$CPPFLAGS" 1>&6
14840 echo "${as_me:-configure}:14840: testing but keeping change to \$CPPFLAGS ..." 1>&5
14843 CFLAGS="$cf_check_flags"
14845 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14848 echo "$as_me:14848: checking for XOpenDisplay" >&5
14849 echo $ECHO_N "checking for XOpenDisplay... $ECHO_C" >&6
14850 if test "${ac_cv_func_XOpenDisplay+set}" = set; then
14851 echo $ECHO_N "(cached) $ECHO_C" >&6
14853 cat >conftest.$ac_ext <<_ACEOF
14854 #line 14854 "configure"
14855 #include "confdefs.h"
14856 #define XOpenDisplay autoconf_temporary
14857 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
14858 #undef XOpenDisplay
14864 /* We use char because int might match the return type of a gcc2
14865 builtin and then its argument prototype would still apply. */
14866 char XOpenDisplay (void);
14872 /* The GNU C library defines stubs for functions which it implements
14873 to always fail with ENOSYS. Some functions are actually named
14874 something starting with __ and the normal name is an alias. */
14875 #if defined (__stub_XOpenDisplay) || defined (__stub___XOpenDisplay)
14876 #error found stub for XOpenDisplay
14879 return XOpenDisplay ();
14884 rm -f conftest.$ac_objext conftest$ac_exeext
14885 if { (eval echo "$as_me:14885: \"$ac_link\"") >&5
14886 (eval $ac_link) 2>&5
14888 echo "$as_me:14888: \$? = $ac_status" >&5
14889 (exit $ac_status); } &&
14890 { ac_try='test -s conftest$ac_exeext'
14891 { (eval echo "$as_me:14891: \"$ac_try\"") >&5
14892 (eval $ac_try) 2>&5
14894 echo "$as_me:14894: \$? = $ac_status" >&5
14895 (exit $ac_status); }; }; then
14896 ac_cv_func_XOpenDisplay=yes
14898 echo "$as_me: failed program was:" >&5
14899 cat conftest.$ac_ext >&5
14900 ac_cv_func_XOpenDisplay=no
14902 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14904 echo "$as_me:14904: result: $ac_cv_func_XOpenDisplay" >&5
14905 echo "${ECHO_T}$ac_cv_func_XOpenDisplay" >&6
14906 if test $ac_cv_func_XOpenDisplay = yes; then
14910 echo "$as_me:14910: checking for XOpenDisplay in -lX11" >&5
14911 echo $ECHO_N "checking for XOpenDisplay in -lX11... $ECHO_C" >&6
14912 if test "${ac_cv_lib_X11_XOpenDisplay+set}" = set; then
14913 echo $ECHO_N "(cached) $ECHO_C" >&6
14915 ac_check_lib_save_LIBS=$LIBS
14917 cat >conftest.$ac_ext <<_ACEOF
14918 #line 14918 "configure"
14919 #include "confdefs.h"
14921 /* Override any gcc2 internal prototype to avoid an error. */
14925 /* We use char because int might match the return type of a gcc2
14926 builtin and then its argument prototype would still apply. */
14927 char XOpenDisplay ();
14936 rm -f conftest.$ac_objext conftest$ac_exeext
14937 if { (eval echo "$as_me:14937: \"$ac_link\"") >&5
14938 (eval $ac_link) 2>&5
14940 echo "$as_me:14940: \$? = $ac_status" >&5
14941 (exit $ac_status); } &&
14942 { ac_try='test -s conftest$ac_exeext'
14943 { (eval echo "$as_me:14943: \"$ac_try\"") >&5
14944 (eval $ac_try) 2>&5
14946 echo "$as_me:14946: \$? = $ac_status" >&5
14947 (exit $ac_status); }; }; then
14948 ac_cv_lib_X11_XOpenDisplay=yes
14950 echo "$as_me: failed program was:" >&5
14951 cat conftest.$ac_ext >&5
14952 ac_cv_lib_X11_XOpenDisplay=no
14954 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14955 LIBS=$ac_check_lib_save_LIBS
14957 echo "$as_me:14957: result: $ac_cv_lib_X11_XOpenDisplay" >&5
14958 echo "${ECHO_T}$ac_cv_lib_X11_XOpenDisplay" >&6
14959 if test $ac_cv_lib_X11_XOpenDisplay = yes; then
14961 cf_add_libs="$LIBS"
14964 for cf_add_1lib in -lX11; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
14965 # filter duplicates
14966 for cf_add_1lib in $cf_add_0lib; do
14967 for cf_add_2lib in $cf_add_libs; do
14968 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
14973 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
14975 LIBS="$cf_add_libs"
14981 echo "$as_me:14981: checking for XtAppInitialize" >&5
14982 echo $ECHO_N "checking for XtAppInitialize... $ECHO_C" >&6
14983 if test "${ac_cv_func_XtAppInitialize+set}" = set; then
14984 echo $ECHO_N "(cached) $ECHO_C" >&6
14986 cat >conftest.$ac_ext <<_ACEOF
14987 #line 14987 "configure"
14988 #include "confdefs.h"
14989 #define XtAppInitialize autoconf_temporary
14990 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
14991 #undef XtAppInitialize
14997 /* We use char because int might match the return type of a gcc2
14998 builtin and then its argument prototype would still apply. */
14999 char XtAppInitialize (void);
15005 /* The GNU C library defines stubs for functions which it implements
15006 to always fail with ENOSYS. Some functions are actually named
15007 something starting with __ and the normal name is an alias. */
15008 #if defined (__stub_XtAppInitialize) || defined (__stub___XtAppInitialize)
15009 #error found stub for XtAppInitialize
15012 return XtAppInitialize ();
15017 rm -f conftest.$ac_objext conftest$ac_exeext
15018 if { (eval echo "$as_me:15018: \"$ac_link\"") >&5
15019 (eval $ac_link) 2>&5
15021 echo "$as_me:15021: \$? = $ac_status" >&5
15022 (exit $ac_status); } &&
15023 { ac_try='test -s conftest$ac_exeext'
15024 { (eval echo "$as_me:15024: \"$ac_try\"") >&5
15025 (eval $ac_try) 2>&5
15027 echo "$as_me:15027: \$? = $ac_status" >&5
15028 (exit $ac_status); }; }; then
15029 ac_cv_func_XtAppInitialize=yes
15031 echo "$as_me: failed program was:" >&5
15032 cat conftest.$ac_ext >&5
15033 ac_cv_func_XtAppInitialize=no
15035 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15037 echo "$as_me:15037: result: $ac_cv_func_XtAppInitialize" >&5
15038 echo "${ECHO_T}$ac_cv_func_XtAppInitialize" >&6
15039 if test $ac_cv_func_XtAppInitialize = yes; then
15043 echo "$as_me:15043: checking for XtAppInitialize in -lXt" >&5
15044 echo $ECHO_N "checking for XtAppInitialize in -lXt... $ECHO_C" >&6
15045 if test "${ac_cv_lib_Xt_XtAppInitialize+set}" = set; then
15046 echo $ECHO_N "(cached) $ECHO_C" >&6
15048 ac_check_lib_save_LIBS=$LIBS
15050 cat >conftest.$ac_ext <<_ACEOF
15051 #line 15051 "configure"
15052 #include "confdefs.h"
15054 /* Override any gcc2 internal prototype to avoid an error. */
15058 /* We use char because int might match the return type of a gcc2
15059 builtin and then its argument prototype would still apply. */
15060 char XtAppInitialize ();
15064 XtAppInitialize ();
15069 rm -f conftest.$ac_objext conftest$ac_exeext
15070 if { (eval echo "$as_me:15070: \"$ac_link\"") >&5
15071 (eval $ac_link) 2>&5
15073 echo "$as_me:15073: \$? = $ac_status" >&5
15074 (exit $ac_status); } &&
15075 { ac_try='test -s conftest$ac_exeext'
15076 { (eval echo "$as_me:15076: \"$ac_try\"") >&5
15077 (eval $ac_try) 2>&5
15079 echo "$as_me:15079: \$? = $ac_status" >&5
15080 (exit $ac_status); }; }; then
15081 ac_cv_lib_Xt_XtAppInitialize=yes
15083 echo "$as_me: failed program was:" >&5
15084 cat conftest.$ac_ext >&5
15085 ac_cv_lib_Xt_XtAppInitialize=no
15087 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15088 LIBS=$ac_check_lib_save_LIBS
15090 echo "$as_me:15090: result: $ac_cv_lib_Xt_XtAppInitialize" >&5
15091 echo "${ECHO_T}$ac_cv_lib_Xt_XtAppInitialize" >&6
15092 if test $ac_cv_lib_Xt_XtAppInitialize = yes; then
15094 cat >>confdefs.h <<\EOF
15095 #define HAVE_LIBXT 1
15106 if test $cf_have_X_LIBS = no ; then
15107 { echo "$as_me:15107: WARNING: Unable to successfully link X Toolkit library (-lXt) with
15108 test program. You will have to check and add the proper libraries by hand
15110 echo "$as_me: WARNING: Unable to successfully link X Toolkit library (-lXt) with
15111 test program. You will have to check and add the proper libraries by hand
15112 to makefile." >&2;}
15115 cf_x_athena_root=$cf_x_athena
15118 for cf_path in default \
15119 /usr/contrib/X11R6 \
15120 /usr/contrib/X11R5 \
15124 if test -z "$cf_x_athena_inc" ; then
15126 cf_save_LIBS_CF_X_ATHENA_CPPFLAGS="$LIBS"
15127 cf_save_CFLAGS_CF_X_ATHENA_CPPFLAGS="$CFLAGS"
15128 cf_save_CPPFLAGS_CF_X_ATHENA_CPPFLAGS="$CPPFLAGS"
15129 LIBS="$LIBS ${X_PRE_LIBS} ${X_LIBS} ${X_EXTRA_LIBS}"
15130 for cf_X_CFLAGS in $X_CFLAGS
15132 case "x$cf_X_CFLAGS" in
15134 CPPFLAGS="$CPPFLAGS $cf_X_CFLAGS"
15137 CFLAGS="$CFLAGS $cf_X_CFLAGS"
15142 cf_test=X11/$cf_x_athena_root/SimpleMenu.h
15143 if test $cf_path != default ; then
15145 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
15146 CPPFLAGS="${CPPFLAGS}-I$cf_path/include"
15148 echo "$as_me:15148: checking for $cf_test in $cf_path" >&5
15149 echo $ECHO_N "checking for $cf_test in $cf_path... $ECHO_C" >&6
15151 echo "$as_me:15151: checking for $cf_test" >&5
15152 echo $ECHO_N "checking for $cf_test... $ECHO_C" >&6
15154 cat >conftest.$ac_ext <<_ACEOF
15155 #line 15155 "configure"
15156 #include "confdefs.h"
15158 #include <X11/Intrinsic.h>
15159 #include <$cf_test>
15168 rm -f conftest.$ac_objext
15169 if { (eval echo "$as_me:15169: \"$ac_compile\"") >&5
15170 (eval $ac_compile) 2>&5
15172 echo "$as_me:15172: \$? = $ac_status" >&5
15173 (exit $ac_status); } &&
15174 { ac_try='test -s conftest.$ac_objext'
15175 { (eval echo "$as_me:15175: \"$ac_try\"") >&5
15176 (eval $ac_try) 2>&5
15178 echo "$as_me:15178: \$? = $ac_status" >&5
15179 (exit $ac_status); }; }; then
15182 echo "$as_me: failed program was:" >&5
15183 cat conftest.$ac_ext >&5
15186 rm -f conftest.$ac_objext conftest.$ac_ext
15187 echo "$as_me:15187: result: $cf_result" >&5
15188 echo "${ECHO_T}$cf_result" >&6
15190 LIBS="$cf_save_LIBS_CF_X_ATHENA_CPPFLAGS"
15191 CFLAGS="$cf_save_CFLAGS_CF_X_ATHENA_CPPFLAGS"
15192 CPPFLAGS="$cf_save_CPPFLAGS_CF_X_ATHENA_CPPFLAGS"
15194 if test "$cf_result" = yes ; then
15195 test "$cf_path" = default && cf_x_athena_inc=default
15196 test "$cf_path" != default && cf_x_athena_inc=$cf_path/include
15202 if test -z "$cf_x_athena_inc" ; then
15203 { echo "$as_me:15203: WARNING: Unable to find Athena header files" >&5
15204 echo "$as_me: WARNING: Unable to find Athena header files" >&2;}
15205 elif test "$cf_x_athena_inc" != default ; then
15207 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
15208 CPPFLAGS="${CPPFLAGS}-I$cf_x_athena_inc"
15212 cf_x_athena_root=$cf_x_athena
15215 for cf_path in default \
15216 /usr/contrib/X11R6 \
15217 /usr/contrib/X11R5 \
15222 ${cf_x_athena_root} \
15223 ${cf_x_athena_root}7 \
15224 ${cf_x_athena_root}6
15227 "-l$cf_lib -lXmu" \
15228 "-l$cf_lib -lXpm -lXmu" \
15229 "-l${cf_lib}_s -lXmu_s"
15231 test -n "$cf_x_athena_lib" && break
15233 cf_save_LIBS_CF_X_ATHENA_LIBS="$LIBS"
15234 cf_save_CFLAGS_CF_X_ATHENA_LIBS="$CFLAGS"
15235 cf_save_CPPFLAGS_CF_X_ATHENA_LIBS="$CPPFLAGS"
15236 LIBS="$LIBS ${X_PRE_LIBS} ${X_LIBS} ${X_EXTRA_LIBS}"
15237 for cf_X_CFLAGS in $X_CFLAGS
15239 case "x$cf_X_CFLAGS" in
15241 CPPFLAGS="$CPPFLAGS $cf_X_CFLAGS"
15244 CFLAGS="$CFLAGS $cf_X_CFLAGS"
15249 cf_test=XawSimpleMenuAddGlobalActions
15250 test "$cf_path" != default && cf_libs="-L$cf_path/lib $cf_libs"
15252 cf_add_libs="$LIBS"
15255 for cf_add_1lib in $cf_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
15256 # filter duplicates
15257 for cf_add_1lib in $cf_add_0lib; do
15258 for cf_add_2lib in $cf_add_libs; do
15259 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
15264 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
15266 LIBS="$cf_add_libs"
15268 echo "$as_me:15268: checking for $cf_test in $cf_libs" >&5
15269 echo $ECHO_N "checking for $cf_test in $cf_libs... $ECHO_C" >&6
15270 cat >conftest.$ac_ext <<_ACEOF
15271 #line 15271 "configure"
15272 #include "confdefs.h"
15274 #include <X11/Intrinsic.h>
15275 #include <X11/$cf_x_athena_root/SimpleMenu.h>
15281 $cf_test((XtAppContext) 0)
15286 rm -f conftest.$ac_objext conftest$ac_exeext
15287 if { (eval echo "$as_me:15287: \"$ac_link\"") >&5
15288 (eval $ac_link) 2>&5
15290 echo "$as_me:15290: \$? = $ac_status" >&5
15291 (exit $ac_status); } &&
15292 { ac_try='test -s conftest$ac_exeext'
15293 { (eval echo "$as_me:15293: \"$ac_try\"") >&5
15294 (eval $ac_try) 2>&5
15296 echo "$as_me:15296: \$? = $ac_status" >&5
15297 (exit $ac_status); }; }; then
15300 echo "$as_me: failed program was:" >&5
15301 cat conftest.$ac_ext >&5
15304 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15305 echo "$as_me:15305: result: $cf_result" >&5
15306 echo "${ECHO_T}$cf_result" >&6
15308 LIBS="$cf_save_LIBS_CF_X_ATHENA_LIBS"
15309 CFLAGS="$cf_save_CFLAGS_CF_X_ATHENA_LIBS"
15310 CPPFLAGS="$cf_save_CPPFLAGS_CF_X_ATHENA_LIBS"
15312 if test "$cf_result" = yes ; then
15313 cf_x_athena_lib="$cf_libs"
15317 test -n "$cf_x_athena_lib" && break
15321 if test -z "$cf_x_athena_lib" ; then
15322 { { echo "$as_me:15322: error: Unable to successfully link Athena library (-l$cf_x_athena_root) with test program" >&5
15323 echo "$as_me: error: Unable to successfully link Athena library (-l$cf_x_athena_root) with test program" >&2;}
15324 { (exit 1); exit 1; }; }
15327 cf_add_libs="$LIBS"
15330 for cf_add_1lib in $cf_x_athena_lib; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
15331 # filter duplicates
15332 for cf_add_1lib in $cf_add_0lib; do
15333 for cf_add_2lib in $cf_add_libs; do
15334 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
15339 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
15341 LIBS="$cf_add_libs"
15343 cf_x_athena_LIBS=`echo "HAVE_LIB_$cf_x_athena" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
15345 cat >>confdefs.h <<EOF
15346 #define $cf_x_athena_LIBS 1
15351 if test -n "$ac_tool_prefix"; then
15352 for ac_prog in xcurses-config
15354 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
15355 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
15356 echo "$as_me:15356: checking for $ac_word" >&5
15357 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
15358 if test "${ac_cv_prog_XCURSES_CONFIG+set}" = set; then
15359 echo $ECHO_N "(cached) $ECHO_C" >&6
15361 if test -n "$XCURSES_CONFIG"; then
15362 ac_cv_prog_XCURSES_CONFIG="$XCURSES_CONFIG" # Let the user override the test.
15364 ac_save_IFS=$IFS; IFS=$ac_path_separator
15366 for ac_dir in $ac_dummy; do
15368 test -z "$ac_dir" && ac_dir=.
15369 $as_executable_p "$ac_dir/$ac_word" || continue
15370 ac_cv_prog_XCURSES_CONFIG="$ac_tool_prefix$ac_prog"
15371 echo "$as_me:15371: found $ac_dir/$ac_word" >&5
15377 XCURSES_CONFIG=$ac_cv_prog_XCURSES_CONFIG
15378 if test -n "$XCURSES_CONFIG"; then
15379 echo "$as_me:15379: result: $XCURSES_CONFIG" >&5
15380 echo "${ECHO_T}$XCURSES_CONFIG" >&6
15382 echo "$as_me:15382: result: no" >&5
15383 echo "${ECHO_T}no" >&6
15386 test -n "$XCURSES_CONFIG" && break
15389 if test -z "$XCURSES_CONFIG"; then
15390 ac_ct_XCURSES_CONFIG=$XCURSES_CONFIG
15391 for ac_prog in xcurses-config
15393 # Extract the first word of "$ac_prog", so it can be a program name with args.
15394 set dummy $ac_prog; ac_word=$2
15395 echo "$as_me:15395: checking for $ac_word" >&5
15396 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
15397 if test "${ac_cv_prog_ac_ct_XCURSES_CONFIG+set}" = set; then
15398 echo $ECHO_N "(cached) $ECHO_C" >&6
15400 if test -n "$ac_ct_XCURSES_CONFIG"; then
15401 ac_cv_prog_ac_ct_XCURSES_CONFIG="$ac_ct_XCURSES_CONFIG" # Let the user override the test.
15403 ac_save_IFS=$IFS; IFS=$ac_path_separator
15405 for ac_dir in $ac_dummy; do
15407 test -z "$ac_dir" && ac_dir=.
15408 $as_executable_p "$ac_dir/$ac_word" || continue
15409 ac_cv_prog_ac_ct_XCURSES_CONFIG="$ac_prog"
15410 echo "$as_me:15410: found $ac_dir/$ac_word" >&5
15416 ac_ct_XCURSES_CONFIG=$ac_cv_prog_ac_ct_XCURSES_CONFIG
15417 if test -n "$ac_ct_XCURSES_CONFIG"; then
15418 echo "$as_me:15418: result: $ac_ct_XCURSES_CONFIG" >&5
15419 echo "${ECHO_T}$ac_ct_XCURSES_CONFIG" >&6
15421 echo "$as_me:15421: result: no" >&5
15422 echo "${ECHO_T}no" >&6
15425 test -n "$ac_ct_XCURSES_CONFIG" && break
15427 test -n "$ac_ct_XCURSES_CONFIG" || ac_ct_XCURSES_CONFIG="none"
15429 XCURSES_CONFIG=$ac_ct_XCURSES_CONFIG
15432 if test "$XCURSES_CONFIG" != none ; then
15437 cf_new_extra_cppflags=
15439 for cf_add_cflags in `$XCURSES_CONFIG --cflags`
15441 case $cf_fix_cppflags in
15443 case $cf_add_cflags in
15444 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
15445 case $cf_add_cflags in
15447 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
15449 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15450 && test -z "${cf_tst_cflags}" \
15451 && cf_fix_cppflags=yes
15453 if test $cf_fix_cppflags = yes ; then
15455 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15456 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15459 elif test "${cf_tst_cflags}" = "\"'" ; then
15461 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15462 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15468 case "$CPPFLAGS" in
15472 case $cf_add_cflags in
15474 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
15476 CPPFLAGS=`echo "$CPPFLAGS" | \
15477 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
15478 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
15483 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
15484 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
15491 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
15492 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
15499 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15500 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15502 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
15504 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15505 && test -z "${cf_tst_cflags}" \
15506 && cf_fix_cppflags=no
15511 if test -n "$cf_new_cflags" ; then
15513 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
15514 CFLAGS="${CFLAGS}$cf_new_cflags"
15518 if test -n "$cf_new_cppflags" ; then
15520 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
15521 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
15525 if test -n "$cf_new_extra_cppflags" ; then
15527 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
15528 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
15532 cf_add_libs="$LIBS"
15535 for cf_add_1lib in `$XCURSES_CONFIG --libs`; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
15536 # filter duplicates
15537 for cf_add_1lib in $cf_add_0lib; do
15538 for cf_add_2lib in $cf_add_libs; do
15539 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
15544 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
15546 LIBS="$cf_add_libs"
15548 cf_cv_lib_XCurses=yes
15552 LDFLAGS="$LDFLAGS $X_LIBS"
15554 test -n "$verbose" && echo " checking additions to CFLAGS" 1>&6
15556 echo "${as_me:-configure}:15556: testing checking additions to CFLAGS ..." 1>&5
15558 cf_check_cflags="$CFLAGS"
15559 cf_check_cppflags="$CPPFLAGS"
15564 cf_new_extra_cppflags=
15566 for cf_add_cflags in $X_CFLAGS
15568 case $cf_fix_cppflags in
15570 case $cf_add_cflags in
15571 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
15572 case $cf_add_cflags in
15574 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
15576 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15577 && test -z "${cf_tst_cflags}" \
15578 && cf_fix_cppflags=yes
15580 if test $cf_fix_cppflags = yes ; then
15582 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15583 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15586 elif test "${cf_tst_cflags}" = "\"'" ; then
15588 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15589 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15595 case "$CPPFLAGS" in
15599 case $cf_add_cflags in
15601 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
15603 CPPFLAGS=`echo "$CPPFLAGS" | \
15604 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
15605 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
15610 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
15611 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
15618 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
15619 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
15626 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15627 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15629 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
15631 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15632 && test -z "${cf_tst_cflags}" \
15633 && cf_fix_cppflags=no
15638 if test -n "$cf_new_cflags" ; then
15639 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
15641 echo "${as_me:-configure}:15641: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
15643 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
15644 CFLAGS="${CFLAGS}$cf_new_cflags"
15648 if test -n "$cf_new_cppflags" ; then
15649 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
15651 echo "${as_me:-configure}:15651: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
15653 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
15654 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
15658 if test -n "$cf_new_extra_cppflags" ; then
15659 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
15661 echo "${as_me:-configure}:15661: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
15663 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
15664 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
15668 if test "x$cf_check_cflags" != "x$CFLAGS" ; then
15669 cat >conftest.$ac_ext <<_ACEOF
15670 #line 15670 "configure"
15671 #include "confdefs.h"
15676 printf("Hello world");
15681 rm -f conftest.$ac_objext conftest$ac_exeext
15682 if { (eval echo "$as_me:15682: \"$ac_link\"") >&5
15683 (eval $ac_link) 2>&5
15685 echo "$as_me:15685: \$? = $ac_status" >&5
15686 (exit $ac_status); } &&
15687 { ac_try='test -s conftest$ac_exeext'
15688 { (eval echo "$as_me:15688: \"$ac_try\"") >&5
15689 (eval $ac_try) 2>&5
15691 echo "$as_me:15691: \$? = $ac_status" >&5
15692 (exit $ac_status); }; }; then
15695 echo "$as_me: failed program was:" >&5
15696 cat conftest.$ac_ext >&5
15697 test -n "$verbose" && echo " test-compile failed. Undoing change to \$CFLAGS" 1>&6
15699 echo "${as_me:-configure}:15699: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5
15701 if test "x$cf_check_cppflags" != "x$CPPFLAGS" ; then
15702 test -n "$verbose" && echo " but keeping change to \$CPPFLAGS" 1>&6
15704 echo "${as_me:-configure}:15704: testing but keeping change to \$CPPFLAGS ..." 1>&5
15707 CFLAGS="$cf_check_flags"
15709 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15712 echo "$as_me:15712: checking for XOpenDisplay in -lX11" >&5
15713 echo $ECHO_N "checking for XOpenDisplay in -lX11... $ECHO_C" >&6
15714 if test "${ac_cv_lib_X11_XOpenDisplay+set}" = set; then
15715 echo $ECHO_N "(cached) $ECHO_C" >&6
15717 ac_check_lib_save_LIBS=$LIBS
15718 LIBS="-lX11 $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
15719 cat >conftest.$ac_ext <<_ACEOF
15720 #line 15720 "configure"
15721 #include "confdefs.h"
15723 /* Override any gcc2 internal prototype to avoid an error. */
15727 /* We use char because int might match the return type of a gcc2
15728 builtin and then its argument prototype would still apply. */
15729 char XOpenDisplay ();
15738 rm -f conftest.$ac_objext conftest$ac_exeext
15739 if { (eval echo "$as_me:15739: \"$ac_link\"") >&5
15740 (eval $ac_link) 2>&5
15742 echo "$as_me:15742: \$? = $ac_status" >&5
15743 (exit $ac_status); } &&
15744 { ac_try='test -s conftest$ac_exeext'
15745 { (eval echo "$as_me:15745: \"$ac_try\"") >&5
15746 (eval $ac_try) 2>&5
15748 echo "$as_me:15748: \$? = $ac_status" >&5
15749 (exit $ac_status); }; }; then
15750 ac_cv_lib_X11_XOpenDisplay=yes
15752 echo "$as_me: failed program was:" >&5
15753 cat conftest.$ac_ext >&5
15754 ac_cv_lib_X11_XOpenDisplay=no
15756 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15757 LIBS=$ac_check_lib_save_LIBS
15759 echo "$as_me:15759: result: $ac_cv_lib_X11_XOpenDisplay" >&5
15760 echo "${ECHO_T}$ac_cv_lib_X11_XOpenDisplay" >&6
15761 if test $ac_cv_lib_X11_XOpenDisplay = yes; then
15763 cf_add_libs="$LIBS"
15766 for cf_add_1lib in -lX11; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
15767 # filter duplicates
15768 for cf_add_1lib in $cf_add_0lib; do
15769 for cf_add_2lib in $cf_add_libs; do
15770 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
15775 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
15777 LIBS="$cf_add_libs"
15781 echo "$as_me:15781: checking for XCurses library" >&5
15782 echo $ECHO_N "checking for XCurses library... $ECHO_C" >&6
15783 if test "${cf_cv_lib_XCurses+set}" = set; then
15784 echo $ECHO_N "(cached) $ECHO_C" >&6
15787 cf_add_libs="$LIBS"
15790 for cf_add_1lib in -lXCurses; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
15791 # filter duplicates
15792 for cf_add_1lib in $cf_add_0lib; do
15793 for cf_add_2lib in $cf_add_libs; do
15794 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
15799 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
15801 LIBS="$cf_add_libs"
15803 cat >conftest.$ac_ext <<_ACEOF
15804 #line 15804 "configure"
15805 #include "confdefs.h"
15807 #include <xcurses.h>
15808 char *XCursesProgramName = "test";
15818 rm -f conftest.$ac_objext conftest$ac_exeext
15819 if { (eval echo "$as_me:15819: \"$ac_link\"") >&5
15820 (eval $ac_link) 2>&5
15822 echo "$as_me:15822: \$? = $ac_status" >&5
15823 (exit $ac_status); } &&
15824 { ac_try='test -s conftest$ac_exeext'
15825 { (eval echo "$as_me:15825: \"$ac_try\"") >&5
15826 (eval $ac_try) 2>&5
15828 echo "$as_me:15828: \$? = $ac_status" >&5
15829 (exit $ac_status); }; }; then
15830 cf_cv_lib_XCurses=yes
15832 echo "$as_me: failed program was:" >&5
15833 cat conftest.$ac_ext >&5
15834 cf_cv_lib_XCurses=no
15836 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15839 echo "$as_me:15839: result: $cf_cv_lib_XCurses" >&5
15840 echo "${ECHO_T}$cf_cv_lib_XCurses" >&6
15844 if test $cf_cv_lib_XCurses = yes ; then
15846 cat >>confdefs.h <<\EOF
15850 cat >>confdefs.h <<\EOF
15854 echo "$as_me:15854: checking for xcurses.h" >&5
15855 echo $ECHO_N "checking for xcurses.h... $ECHO_C" >&6
15856 if test "${ac_cv_header_xcurses_h+set}" = set; then
15857 echo $ECHO_N "(cached) $ECHO_C" >&6
15859 cat >conftest.$ac_ext <<_ACEOF
15860 #line 15860 "configure"
15861 #include "confdefs.h"
15862 #include <xcurses.h>
15864 if { (eval echo "$as_me:15864: \"$ac_cpp conftest.$ac_ext\"") >&5
15865 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15867 egrep -v '^ *\+' conftest.er1 >conftest.err
15869 cat conftest.err >&5
15870 echo "$as_me:15870: \$? = $ac_status" >&5
15871 (exit $ac_status); } >/dev/null; then
15872 if test -s conftest.err; then
15873 ac_cpp_err=$ac_c_preproc_warn_flag
15880 if test -z "$ac_cpp_err"; then
15881 ac_cv_header_xcurses_h=yes
15883 echo "$as_me: failed program was:" >&5
15884 cat conftest.$ac_ext >&5
15885 ac_cv_header_xcurses_h=no
15887 rm -f conftest.err conftest.$ac_ext
15889 echo "$as_me:15889: result: $ac_cv_header_xcurses_h" >&5
15890 echo "${ECHO_T}$ac_cv_header_xcurses_h" >&6
15891 if test $ac_cv_header_xcurses_h = yes; then
15893 cat >>confdefs.h <<\EOF
15894 #define HAVE_XCURSES 1
15900 { { echo "$as_me:15900: error: Cannot link with XCurses" >&5
15901 echo "$as_me: error: Cannot link with XCurses" >&2;}
15902 { (exit 1); exit 1; }; }
15907 { { echo "$as_me:15907: error: unexpected screen-value: $cf_cv_screen" >&5
15908 echo "$as_me: error: unexpected screen-value: $cf_cv_screen" >&2;}
15909 { (exit 1); exit 1; }; }
15913 : ${cf_nculib_root:=$cf_cv_screen}
15914 as_ac_Lib=`echo "ac_cv_lib_$cf_nculib_root''__nc_init_pthreads" | $as_tr_sh`
15915 echo "$as_me:15915: checking for _nc_init_pthreads in -l$cf_nculib_root" >&5
15916 echo $ECHO_N "checking for _nc_init_pthreads in -l$cf_nculib_root... $ECHO_C" >&6
15917 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
15918 echo $ECHO_N "(cached) $ECHO_C" >&6
15920 ac_check_lib_save_LIBS=$LIBS
15921 LIBS="-l$cf_nculib_root $LIBS"
15922 cat >conftest.$ac_ext <<_ACEOF
15923 #line 15923 "configure"
15924 #include "confdefs.h"
15926 /* Override any gcc2 internal prototype to avoid an error. */
15930 /* We use char because int might match the return type of a gcc2
15931 builtin and then its argument prototype would still apply. */
15932 char _nc_init_pthreads ();
15936 _nc_init_pthreads ();
15941 rm -f conftest.$ac_objext conftest$ac_exeext
15942 if { (eval echo "$as_me:15942: \"$ac_link\"") >&5
15943 (eval $ac_link) 2>&5
15945 echo "$as_me:15945: \$? = $ac_status" >&5
15946 (exit $ac_status); } &&
15947 { ac_try='test -s conftest$ac_exeext'
15948 { (eval echo "$as_me:15948: \"$ac_try\"") >&5
15949 (eval $ac_try) 2>&5
15951 echo "$as_me:15951: \$? = $ac_status" >&5
15952 (exit $ac_status); }; }; then
15953 eval "$as_ac_Lib=yes"
15955 echo "$as_me: failed program was:" >&5
15956 cat conftest.$ac_ext >&5
15957 eval "$as_ac_Lib=no"
15959 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15960 LIBS=$ac_check_lib_save_LIBS
15962 echo "$as_me:15962: result: `eval echo '${'$as_ac_Lib'}'`" >&5
15963 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
15964 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
15965 cf_cv_ncurses_pthreads=yes
15967 cf_cv_ncurses_pthreads=no
15970 if test "$cf_cv_ncurses_pthreads" = yes
15973 cf_add_libs="$LIBS"
15976 for cf_add_1lib in -lpthread; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
15977 # filter duplicates
15978 for cf_add_1lib in $cf_add_0lib; do
15979 for cf_add_2lib in $cf_add_libs; do
15980 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
15985 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
15987 LIBS="$cf_add_libs"
15991 case $cf_cv_screen in
15993 cf_cv_libtype=`echo "$cf_cv_screen" | sed -e 's/^ncurses//'`
15997 echo "$as_me:15997: checking for X11 rgb file" >&5
15998 echo $ECHO_N "checking for X11 rgb file... $ECHO_C" >&6
16000 # Check whether --with-x11-rgb or --without-x11-rgb was given.
16001 if test "${with_x11_rgb+set}" = set; then
16002 withval="$with_x11_rgb"
16008 if test "x$RGB_PATH" = xauto
16010 RGB_PATH='${exec_prefix}/lib/X11/rgb.txt'
16012 /opt/local/share/X11/rgb.txt \
16013 /opt/X11/share/X11/rgb.txt \
16014 /usr/share/X11/rgb.txt \
16015 /usr/X11/share/X11/rgb.txt \
16016 /usr/X11/lib/X11/rgb.txt \
16017 /usr/lib/X11/rgb.txt \
16019 /usr/pkg/lib/X11/rgb.txt \
16020 /usr/X11R7/lib/X11/rgb.txt \
16021 /usr/X11R6/lib/X11/rgb.txt \
16022 /usr/X11R5/lib/X11/rgb.txt \
16023 /usr/X11R4/lib/X11/rgb.txt \
16024 /usr/local/lib/X11/rgb.txt \
16025 /usr/local/share/X11/rgb.txt \
16026 /usr/lib64/X11/rgb.txt
16028 if test -f "$cf_path" ; then
16029 RGB_PATH="$cf_path"
16036 if test "x$prefix" != xNONE; then
16037 cf_path_syntax="$prefix"
16039 cf_path_syntax="$ac_default_prefix"
16042 case ".$cf_path" in
16043 (.\$\(*\)*|.\'*\'*)
16047 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
16049 (.\${*prefix}*|.\${*dir}*)
16050 eval cf_path="$cf_path"
16051 case ".$cf_path" in
16053 cf_path=`echo $cf_path | sed -e s%NONE%$cf_path_syntax%`
16058 cf_path=`echo $cf_path | sed -e s%NONE%$cf_path_syntax%`
16061 { { echo "$as_me:16061: error: expected a pathname, not \"$cf_path\"" >&5
16062 echo "$as_me: error: expected a pathname, not \"$cf_path\"" >&2;}
16063 { (exit 1); exit 1; }; }
16069 echo "$as_me:16069: result: $RGB_PATH" >&5
16070 echo "${ECHO_T}$RGB_PATH" >&6
16072 cat >>confdefs.h <<EOF
16073 #define RGB_PATH "$cf_path"
16077 if test "$RGB_PATH" = no
16084 case $cf_cv_screen in
16086 cf_default_panel=no
16089 cf_default_tinfo=no
16091 (xcurses|bsdcurses)
16092 cf_default_panel=no
16095 cf_default_tinfo=yes
16098 cf_default_panel=yes
16099 cf_default_form=yes
16100 cf_default_menu=yes
16101 cf_default_tinfo=yes
16102 case $cf_cv_screen in
16104 cf_curses_headers="nc_alloc.h nomacros.h term_entry.h"
16110 echo "$as_me:16110: checking for desired basename for form library" >&5
16111 echo $ECHO_N "checking for desired basename for form library... $ECHO_C" >&6
16113 # Check whether --with-form-libname or --without-form-libname was given.
16114 if test "${with_form_libname+set}" = set; then
16115 withval="$with_form_libname"
16116 with_lib_basename=$withval
16118 with_lib_basename=form
16120 FORM_NAME="$with_lib_basename"
16122 case "x$FORM_NAME" in
16130 echo "$as_me:16130: result: $FORM_NAME" >&5
16131 echo "${ECHO_T}$FORM_NAME" >&6
16133 echo "$as_me:16133: checking for desired basename for menu library" >&5
16134 echo $ECHO_N "checking for desired basename for menu library... $ECHO_C" >&6
16136 # Check whether --with-menu-libname or --without-menu-libname was given.
16137 if test "${with_menu_libname+set}" = set; then
16138 withval="$with_menu_libname"
16139 with_lib_basename=$withval
16141 with_lib_basename=menu
16143 MENU_NAME="$with_lib_basename"
16145 case "x$MENU_NAME" in
16153 echo "$as_me:16153: result: $MENU_NAME" >&5
16154 echo "${ECHO_T}$MENU_NAME" >&6
16156 echo "$as_me:16156: checking for desired basename for panel library" >&5
16157 echo $ECHO_N "checking for desired basename for panel library... $ECHO_C" >&6
16159 # Check whether --with-panel-libname or --without-panel-libname was given.
16160 if test "${with_panel_libname+set}" = set; then
16161 withval="$with_panel_libname"
16162 with_lib_basename=$withval
16164 with_lib_basename=panel
16166 PANEL_NAME="$with_lib_basename"
16168 case "x$PANEL_NAME" in
16176 echo "$as_me:16176: result: $PANEL_NAME" >&5
16177 echo "${ECHO_T}$PANEL_NAME" >&6
16179 echo "$as_me:16179: checking if you want to check for panel functions" >&5
16180 echo $ECHO_N "checking if you want to check for panel functions... $ECHO_C" >&6
16182 # Check whether --enable-panel or --disable-panel was given.
16183 if test "${enable_panel+set}" = set; then
16184 enableval="$enable_panel"
16185 test "$enableval" != no && enableval=yes
16186 if test "$enableval" != "yes" ; then
16189 cf_enable_panel=$cf_default_panel
16193 cf_enable_panel=$cf_default_panel
16196 echo "$as_me:16196: result: $cf_enable_panel" >&5
16197 echo "${ECHO_T}$cf_enable_panel" >&6
16198 if test $cf_enable_panel = yes
16201 cf_have_curses_lib=no
16203 : ${NCURSES_CONFIG_PKG:=none}
16204 if test "x${NCURSES_CONFIG_PKG}" = xnone; then
16206 elif test "x${PKG_CONFIG:=none}" != xnone; then
16207 echo "$as_me:16207: checking pkg-config for $PANEL_NAME$cf_cv_libtype" >&5
16208 echo $ECHO_N "checking pkg-config for $PANEL_NAME$cf_cv_libtype... $ECHO_C" >&6
16209 if "$PKG_CONFIG" --exists $PANEL_NAME$cf_cv_libtype ; then
16210 echo "$as_me:16210: result: yes" >&5
16211 echo "${ECHO_T}yes" >&6
16213 echo "$as_me:16213: checking if the $PANEL_NAME$cf_cv_libtype package files work" >&5
16214 echo $ECHO_N "checking if the $PANEL_NAME$cf_cv_libtype package files work... $ECHO_C" >&6
16216 cf_save_CPPFLAGS="$CPPFLAGS"
16217 cf_save_LIBS="$LIBS"
16222 cf_new_extra_cppflags=
16224 for cf_add_cflags in `$PKG_CONFIG --cflags $PANEL_NAME$cf_cv_libtype`
16226 case $cf_fix_cppflags in
16228 case $cf_add_cflags in
16229 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
16230 case $cf_add_cflags in
16232 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
16234 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
16235 && test -z "${cf_tst_cflags}" \
16236 && cf_fix_cppflags=yes
16238 if test $cf_fix_cppflags = yes ; then
16240 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
16241 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
16244 elif test "${cf_tst_cflags}" = "\"'" ; then
16246 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
16247 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
16253 case "$CPPFLAGS" in
16257 case $cf_add_cflags in
16259 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
16261 CPPFLAGS=`echo "$CPPFLAGS" | \
16262 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
16263 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
16268 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
16269 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
16276 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
16277 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
16284 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
16285 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
16287 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
16289 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
16290 && test -z "${cf_tst_cflags}" \
16291 && cf_fix_cppflags=no
16296 if test -n "$cf_new_cflags" ; then
16298 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
16299 CFLAGS="${CFLAGS}$cf_new_cflags"
16303 if test -n "$cf_new_cppflags" ; then
16305 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
16306 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
16310 if test -n "$cf_new_extra_cppflags" ; then
16312 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
16313 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
16317 cf_add_libs="$LIBS"
16320 for cf_add_1lib in `$PKG_CONFIG --libs $PANEL_NAME$cf_cv_libtype`; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
16321 # filter duplicates
16322 for cf_add_1lib in $cf_add_0lib; do
16323 for cf_add_2lib in $cf_add_libs; do
16324 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
16329 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
16331 LIBS="$cf_add_libs"
16333 cat >conftest.$ac_ext <<_ACEOF
16334 #line 16334 "configure"
16335 #include "confdefs.h"
16336 #include <$PANEL_NAME.h>
16340 (void) new_panel ( 0 );
16345 rm -f conftest.$ac_objext conftest$ac_exeext
16346 if { (eval echo "$as_me:16346: \"$ac_link\"") >&5
16347 (eval $ac_link) 2>&5
16349 echo "$as_me:16349: \$? = $ac_status" >&5
16350 (exit $ac_status); } &&
16351 { ac_try='test -s conftest$ac_exeext'
16352 { (eval echo "$as_me:16352: \"$ac_try\"") >&5
16353 (eval $ac_try) 2>&5
16355 echo "$as_me:16355: \$? = $ac_status" >&5
16356 (exit $ac_status); }; }; then
16357 if test "$cross_compiling" = yes; then
16358 cf_have_curses_lib=maybe
16360 cat >conftest.$ac_ext <<_ACEOF
16361 #line 16361 "configure"
16362 #include "confdefs.h"
16363 #include <$PANEL_NAME.h>
16365 { (void) new_panel ( 0 ); return 0; }
16367 rm -f conftest$ac_exeext
16368 if { (eval echo "$as_me:16368: \"$ac_link\"") >&5
16369 (eval $ac_link) 2>&5
16371 echo "$as_me:16371: \$? = $ac_status" >&5
16372 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16373 { (eval echo "$as_me:16373: \"$ac_try\"") >&5
16374 (eval $ac_try) 2>&5
16376 echo "$as_me:16376: \$? = $ac_status" >&5
16377 (exit $ac_status); }; }; then
16378 cf_have_curses_lib=yes
16380 echo "$as_me: program exited with status $ac_status" >&5
16381 echo "$as_me: failed program was:" >&5
16382 cat conftest.$ac_ext >&5
16383 cf_have_curses_lib=no
16385 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16388 echo "$as_me: failed program was:" >&5
16389 cat conftest.$ac_ext >&5
16390 cf_have_curses_lib=no
16392 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16393 echo "$as_me:16393: result: $cf_have_curses_lib" >&5
16394 echo "${ECHO_T}$cf_have_curses_lib" >&6
16395 test "$cf_have_curses_lib" = maybe && cf_have_curses_lib=yes
16396 if test "$cf_have_curses_lib" != "yes"
16398 CPPFLAGS="$cf_save_CPPFLAGS"
16399 LIBS="$cf_save_LIBS"
16402 cf_upper=`echo "have_lib$PANEL_NAME" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
16404 cat >>confdefs.h <<EOF
16405 #define $cf_upper 1
16411 if test "$cf_have_curses_lib" = no; then
16412 as_ac_Lib=`echo "ac_cv_lib_$PANEL_NAME$cf_cv_libtype''_new_panel" | $as_tr_sh`
16413 echo "$as_me:16413: checking for new_panel in -l$PANEL_NAME$cf_cv_libtype" >&5
16414 echo $ECHO_N "checking for new_panel in -l$PANEL_NAME$cf_cv_libtype... $ECHO_C" >&6
16415 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
16416 echo $ECHO_N "(cached) $ECHO_C" >&6
16418 ac_check_lib_save_LIBS=$LIBS
16419 LIBS="-l$PANEL_NAME$cf_cv_libtype $LIBS"
16420 cat >conftest.$ac_ext <<_ACEOF
16421 #line 16421 "configure"
16422 #include "confdefs.h"
16424 /* Override any gcc2 internal prototype to avoid an error. */
16428 /* We use char because int might match the return type of a gcc2
16429 builtin and then its argument prototype would still apply. */
16439 rm -f conftest.$ac_objext conftest$ac_exeext
16440 if { (eval echo "$as_me:16440: \"$ac_link\"") >&5
16441 (eval $ac_link) 2>&5
16443 echo "$as_me:16443: \$? = $ac_status" >&5
16444 (exit $ac_status); } &&
16445 { ac_try='test -s conftest$ac_exeext'
16446 { (eval echo "$as_me:16446: \"$ac_try\"") >&5
16447 (eval $ac_try) 2>&5
16449 echo "$as_me:16449: \$? = $ac_status" >&5
16450 (exit $ac_status); }; }; then
16451 eval "$as_ac_Lib=yes"
16453 echo "$as_me: failed program was:" >&5
16454 cat conftest.$ac_ext >&5
16455 eval "$as_ac_Lib=no"
16457 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16458 LIBS=$ac_check_lib_save_LIBS
16460 echo "$as_me:16460: result: `eval echo '${'$as_ac_Lib'}'`" >&5
16461 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
16462 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
16464 cf_upper=`echo "have_lib$PANEL_NAME" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
16466 cf_add_libs="$LIBS"
16469 for cf_add_1lib in -l$PANEL_NAME$cf_cv_libtype; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
16470 # filter duplicates
16471 for cf_add_1lib in $cf_add_0lib; do
16472 for cf_add_2lib in $cf_add_libs; do
16473 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
16478 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
16480 LIBS="$cf_add_libs"
16482 cat >>confdefs.h <<EOF
16483 #define $cf_upper 1
16490 cf_curses_headers="$cf_curses_headers panel.h"
16493 echo "$as_me:16493: checking if you want to check for menu functions" >&5
16494 echo $ECHO_N "checking if you want to check for menu functions... $ECHO_C" >&6
16496 # Check whether --enable-menu or --disable-menu was given.
16497 if test "${enable_menu+set}" = set; then
16498 enableval="$enable_menu"
16499 test "$enableval" != no && enableval=yes
16500 if test "$enableval" != "yes" ; then
16503 cf_enable_menu=$cf_default_menu
16507 cf_enable_menu=$cf_default_menu
16510 echo "$as_me:16510: result: $cf_enable_menu" >&5
16511 echo "${ECHO_T}$cf_enable_menu" >&6
16512 if test $cf_enable_menu = yes
16514 case $cf_cv_screen in
16519 echo "$as_me:16519: checking for NetBSD menu.h" >&5
16520 echo $ECHO_N "checking for NetBSD menu.h... $ECHO_C" >&6
16521 if test "${cf_cv_netbsd_menu_h+set}" = set; then
16522 echo $ECHO_N "(cached) $ECHO_C" >&6
16525 cat >conftest.$ac_ext <<_ACEOF
16526 #line 16526 "configure"
16527 #include "confdefs.h"
16529 #include <${cf_cv_ncurses_header:-curses.h}>
16537 int y = menu->max_item_width;
16543 rm -f conftest.$ac_objext
16544 if { (eval echo "$as_me:16544: \"$ac_compile\"") >&5
16545 (eval $ac_compile) 2>&5
16547 echo "$as_me:16547: \$? = $ac_status" >&5
16548 (exit $ac_status); } &&
16549 { ac_try='test -s conftest.$ac_objext'
16550 { (eval echo "$as_me:16550: \"$ac_try\"") >&5
16551 (eval $ac_try) 2>&5
16553 echo "$as_me:16553: \$? = $ac_status" >&5
16554 (exit $ac_status); }; }; then
16555 cf_cv_netbsd_menu_h=yes
16558 echo "$as_me: failed program was:" >&5
16559 cat conftest.$ac_ext >&5
16560 cf_cv_netbsd_menu_h=no
16562 rm -f conftest.$ac_objext conftest.$ac_ext
16565 echo "$as_me:16565: result: $cf_cv_netbsd_menu_h" >&5
16566 echo "${ECHO_T}$cf_cv_netbsd_menu_h" >&6
16568 test "$cf_cv_netbsd_menu_h" = yes &&
16569 cat >>confdefs.h <<\EOF
16570 #define HAVE_NETBSD_MENU_H 1
16576 cf_have_curses_lib=no
16578 : ${NCURSES_CONFIG_PKG:=none}
16579 if test "x${NCURSES_CONFIG_PKG}" = xnone; then
16581 elif test "x${PKG_CONFIG:=none}" != xnone; then
16582 echo "$as_me:16582: checking pkg-config for $MENU_NAME$cf_cv_libtype" >&5
16583 echo $ECHO_N "checking pkg-config for $MENU_NAME$cf_cv_libtype... $ECHO_C" >&6
16584 if "$PKG_CONFIG" --exists $MENU_NAME$cf_cv_libtype ; then
16585 echo "$as_me:16585: result: yes" >&5
16586 echo "${ECHO_T}yes" >&6
16588 echo "$as_me:16588: checking if the $MENU_NAME$cf_cv_libtype package files work" >&5
16589 echo $ECHO_N "checking if the $MENU_NAME$cf_cv_libtype package files work... $ECHO_C" >&6
16591 cf_save_CPPFLAGS="$CPPFLAGS"
16592 cf_save_LIBS="$LIBS"
16597 cf_new_extra_cppflags=
16599 for cf_add_cflags in `$PKG_CONFIG --cflags $MENU_NAME$cf_cv_libtype`
16601 case $cf_fix_cppflags in
16603 case $cf_add_cflags in
16604 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
16605 case $cf_add_cflags in
16607 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
16609 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
16610 && test -z "${cf_tst_cflags}" \
16611 && cf_fix_cppflags=yes
16613 if test $cf_fix_cppflags = yes ; then
16615 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
16616 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
16619 elif test "${cf_tst_cflags}" = "\"'" ; then
16621 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
16622 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
16628 case "$CPPFLAGS" in
16632 case $cf_add_cflags in
16634 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
16636 CPPFLAGS=`echo "$CPPFLAGS" | \
16637 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
16638 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
16643 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
16644 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
16651 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
16652 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
16659 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
16660 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
16662 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
16664 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
16665 && test -z "${cf_tst_cflags}" \
16666 && cf_fix_cppflags=no
16671 if test -n "$cf_new_cflags" ; then
16673 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
16674 CFLAGS="${CFLAGS}$cf_new_cflags"
16678 if test -n "$cf_new_cppflags" ; then
16680 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
16681 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
16685 if test -n "$cf_new_extra_cppflags" ; then
16687 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
16688 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
16692 cf_add_libs="$LIBS"
16695 for cf_add_1lib in `$PKG_CONFIG --libs $MENU_NAME$cf_cv_libtype`; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
16696 # filter duplicates
16697 for cf_add_1lib in $cf_add_0lib; do
16698 for cf_add_2lib in $cf_add_libs; do
16699 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
16704 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
16706 LIBS="$cf_add_libs"
16708 cat >conftest.$ac_ext <<_ACEOF
16709 #line 16709 "configure"
16710 #include "confdefs.h"
16711 #include <$MENU_NAME.h>
16715 (void) menu_driver ( 0,0 );
16720 rm -f conftest.$ac_objext conftest$ac_exeext
16721 if { (eval echo "$as_me:16721: \"$ac_link\"") >&5
16722 (eval $ac_link) 2>&5
16724 echo "$as_me:16724: \$? = $ac_status" >&5
16725 (exit $ac_status); } &&
16726 { ac_try='test -s conftest$ac_exeext'
16727 { (eval echo "$as_me:16727: \"$ac_try\"") >&5
16728 (eval $ac_try) 2>&5
16730 echo "$as_me:16730: \$? = $ac_status" >&5
16731 (exit $ac_status); }; }; then
16732 if test "$cross_compiling" = yes; then
16733 cf_have_curses_lib=maybe
16735 cat >conftest.$ac_ext <<_ACEOF
16736 #line 16736 "configure"
16737 #include "confdefs.h"
16738 #include <$MENU_NAME.h>
16740 { (void) menu_driver ( 0,0 ); return 0; }
16742 rm -f conftest$ac_exeext
16743 if { (eval echo "$as_me:16743: \"$ac_link\"") >&5
16744 (eval $ac_link) 2>&5
16746 echo "$as_me:16746: \$? = $ac_status" >&5
16747 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16748 { (eval echo "$as_me:16748: \"$ac_try\"") >&5
16749 (eval $ac_try) 2>&5
16751 echo "$as_me:16751: \$? = $ac_status" >&5
16752 (exit $ac_status); }; }; then
16753 cf_have_curses_lib=yes
16755 echo "$as_me: program exited with status $ac_status" >&5
16756 echo "$as_me: failed program was:" >&5
16757 cat conftest.$ac_ext >&5
16758 cf_have_curses_lib=no
16760 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16763 echo "$as_me: failed program was:" >&5
16764 cat conftest.$ac_ext >&5
16765 cf_have_curses_lib=no
16767 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16768 echo "$as_me:16768: result: $cf_have_curses_lib" >&5
16769 echo "${ECHO_T}$cf_have_curses_lib" >&6
16770 test "$cf_have_curses_lib" = maybe && cf_have_curses_lib=yes
16771 if test "$cf_have_curses_lib" != "yes"
16773 CPPFLAGS="$cf_save_CPPFLAGS"
16774 LIBS="$cf_save_LIBS"
16777 cf_upper=`echo "have_lib$MENU_NAME" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
16779 cat >>confdefs.h <<EOF
16780 #define $cf_upper 1
16786 if test "$cf_have_curses_lib" = no; then
16787 as_ac_Lib=`echo "ac_cv_lib_$MENU_NAME$cf_cv_libtype''_menu_driver" | $as_tr_sh`
16788 echo "$as_me:16788: checking for menu_driver in -l$MENU_NAME$cf_cv_libtype" >&5
16789 echo $ECHO_N "checking for menu_driver in -l$MENU_NAME$cf_cv_libtype... $ECHO_C" >&6
16790 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
16791 echo $ECHO_N "(cached) $ECHO_C" >&6
16793 ac_check_lib_save_LIBS=$LIBS
16794 LIBS="-l$MENU_NAME$cf_cv_libtype $LIBS"
16795 cat >conftest.$ac_ext <<_ACEOF
16796 #line 16796 "configure"
16797 #include "confdefs.h"
16799 /* Override any gcc2 internal prototype to avoid an error. */
16803 /* We use char because int might match the return type of a gcc2
16804 builtin and then its argument prototype would still apply. */
16805 char menu_driver ();
16814 rm -f conftest.$ac_objext conftest$ac_exeext
16815 if { (eval echo "$as_me:16815: \"$ac_link\"") >&5
16816 (eval $ac_link) 2>&5
16818 echo "$as_me:16818: \$? = $ac_status" >&5
16819 (exit $ac_status); } &&
16820 { ac_try='test -s conftest$ac_exeext'
16821 { (eval echo "$as_me:16821: \"$ac_try\"") >&5
16822 (eval $ac_try) 2>&5
16824 echo "$as_me:16824: \$? = $ac_status" >&5
16825 (exit $ac_status); }; }; then
16826 eval "$as_ac_Lib=yes"
16828 echo "$as_me: failed program was:" >&5
16829 cat conftest.$ac_ext >&5
16830 eval "$as_ac_Lib=no"
16832 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16833 LIBS=$ac_check_lib_save_LIBS
16835 echo "$as_me:16835: result: `eval echo '${'$as_ac_Lib'}'`" >&5
16836 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
16837 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
16839 cf_upper=`echo "have_lib$MENU_NAME" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
16841 cf_add_libs="$LIBS"
16844 for cf_add_1lib in -l$MENU_NAME$cf_cv_libtype; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
16845 # filter duplicates
16846 for cf_add_1lib in $cf_add_0lib; do
16847 for cf_add_2lib in $cf_add_libs; do
16848 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
16853 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
16855 LIBS="$cf_add_libs"
16857 cat >>confdefs.h <<EOF
16858 #define $cf_upper 1
16865 cf_curses_headers="$cf_curses_headers menu.h"
16868 echo "$as_me:16868: checking if you want to check for form functions" >&5
16869 echo $ECHO_N "checking if you want to check for form functions... $ECHO_C" >&6
16871 # Check whether --enable-form or --disable-form was given.
16872 if test "${enable_form+set}" = set; then
16873 enableval="$enable_form"
16874 test "$enableval" != no && enableval=yes
16875 if test "$enableval" != "yes" ; then
16878 cf_enable_form=$cf_default_form
16882 cf_enable_form=$cf_default_form
16885 echo "$as_me:16885: result: $cf_enable_form" >&5
16886 echo "${ECHO_T}$cf_enable_form" >&6
16887 if test $cf_enable_form = yes
16889 case $cf_cv_screen in
16894 echo "$as_me:16894: checking for NetBSD form.h" >&5
16895 echo $ECHO_N "checking for NetBSD form.h... $ECHO_C" >&6
16896 if test "${cf_cv_netbsd_form_h+set}" = set; then
16897 echo $ECHO_N "(cached) $ECHO_C" >&6
16900 cat >conftest.$ac_ext <<_ACEOF
16901 #line 16901 "configure"
16902 #include "confdefs.h"
16904 #include <${cf_cv_ncurses_header:-curses.h}>
16912 int y = current_field(form)->cursor_ypos;
16913 int x = current_field(form)->cursor_xpos;
16919 rm -f conftest.$ac_objext
16920 if { (eval echo "$as_me:16920: \"$ac_compile\"") >&5
16921 (eval $ac_compile) 2>&5
16923 echo "$as_me:16923: \$? = $ac_status" >&5
16924 (exit $ac_status); } &&
16925 { ac_try='test -s conftest.$ac_objext'
16926 { (eval echo "$as_me:16926: \"$ac_try\"") >&5
16927 (eval $ac_try) 2>&5
16929 echo "$as_me:16929: \$? = $ac_status" >&5
16930 (exit $ac_status); }; }; then
16931 cf_cv_netbsd_form_h=yes
16934 echo "$as_me: failed program was:" >&5
16935 cat conftest.$ac_ext >&5
16936 cf_cv_netbsd_form_h=no
16938 rm -f conftest.$ac_objext conftest.$ac_ext
16941 echo "$as_me:16941: result: $cf_cv_netbsd_form_h" >&5
16942 echo "${ECHO_T}$cf_cv_netbsd_form_h" >&6
16944 test "$cf_cv_netbsd_form_h" = yes &&
16945 cat >>confdefs.h <<\EOF
16946 #define HAVE_NETBSD_FORM_H 1
16952 cf_have_curses_lib=no
16954 : ${NCURSES_CONFIG_PKG:=none}
16955 if test "x${NCURSES_CONFIG_PKG}" = xnone; then
16957 elif test "x${PKG_CONFIG:=none}" != xnone; then
16958 echo "$as_me:16958: checking pkg-config for $FORM_NAME$cf_cv_libtype" >&5
16959 echo $ECHO_N "checking pkg-config for $FORM_NAME$cf_cv_libtype... $ECHO_C" >&6
16960 if "$PKG_CONFIG" --exists $FORM_NAME$cf_cv_libtype ; then
16961 echo "$as_me:16961: result: yes" >&5
16962 echo "${ECHO_T}yes" >&6
16964 echo "$as_me:16964: checking if the $FORM_NAME$cf_cv_libtype package files work" >&5
16965 echo $ECHO_N "checking if the $FORM_NAME$cf_cv_libtype package files work... $ECHO_C" >&6
16967 cf_save_CPPFLAGS="$CPPFLAGS"
16968 cf_save_LIBS="$LIBS"
16973 cf_new_extra_cppflags=
16975 for cf_add_cflags in `$PKG_CONFIG --cflags $FORM_NAME$cf_cv_libtype`
16977 case $cf_fix_cppflags in
16979 case $cf_add_cflags in
16980 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
16981 case $cf_add_cflags in
16983 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
16985 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
16986 && test -z "${cf_tst_cflags}" \
16987 && cf_fix_cppflags=yes
16989 if test $cf_fix_cppflags = yes ; then
16991 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
16992 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
16995 elif test "${cf_tst_cflags}" = "\"'" ; then
16997 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
16998 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
17004 case "$CPPFLAGS" in
17008 case $cf_add_cflags in
17010 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
17012 CPPFLAGS=`echo "$CPPFLAGS" | \
17013 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
17014 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
17019 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
17020 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
17027 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
17028 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
17035 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
17036 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
17038 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
17040 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
17041 && test -z "${cf_tst_cflags}" \
17042 && cf_fix_cppflags=no
17047 if test -n "$cf_new_cflags" ; then
17049 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
17050 CFLAGS="${CFLAGS}$cf_new_cflags"
17054 if test -n "$cf_new_cppflags" ; then
17056 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
17057 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
17061 if test -n "$cf_new_extra_cppflags" ; then
17063 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
17064 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
17068 cf_add_libs="$LIBS"
17071 for cf_add_1lib in `$PKG_CONFIG --libs $FORM_NAME$cf_cv_libtype`; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
17072 # filter duplicates
17073 for cf_add_1lib in $cf_add_0lib; do
17074 for cf_add_2lib in $cf_add_libs; do
17075 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
17080 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
17082 LIBS="$cf_add_libs"
17084 cat >conftest.$ac_ext <<_ACEOF
17085 #line 17085 "configure"
17086 #include "confdefs.h"
17087 #include <$FORM_NAME.h>
17091 (void) form_driver ( 0,0 );
17096 rm -f conftest.$ac_objext conftest$ac_exeext
17097 if { (eval echo "$as_me:17097: \"$ac_link\"") >&5
17098 (eval $ac_link) 2>&5
17100 echo "$as_me:17100: \$? = $ac_status" >&5
17101 (exit $ac_status); } &&
17102 { ac_try='test -s conftest$ac_exeext'
17103 { (eval echo "$as_me:17103: \"$ac_try\"") >&5
17104 (eval $ac_try) 2>&5
17106 echo "$as_me:17106: \$? = $ac_status" >&5
17107 (exit $ac_status); }; }; then
17108 if test "$cross_compiling" = yes; then
17109 cf_have_curses_lib=maybe
17111 cat >conftest.$ac_ext <<_ACEOF
17112 #line 17112 "configure"
17113 #include "confdefs.h"
17114 #include <$FORM_NAME.h>
17116 { (void) form_driver ( 0,0 ); return 0; }
17118 rm -f conftest$ac_exeext
17119 if { (eval echo "$as_me:17119: \"$ac_link\"") >&5
17120 (eval $ac_link) 2>&5
17122 echo "$as_me:17122: \$? = $ac_status" >&5
17123 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17124 { (eval echo "$as_me:17124: \"$ac_try\"") >&5
17125 (eval $ac_try) 2>&5
17127 echo "$as_me:17127: \$? = $ac_status" >&5
17128 (exit $ac_status); }; }; then
17129 cf_have_curses_lib=yes
17131 echo "$as_me: program exited with status $ac_status" >&5
17132 echo "$as_me: failed program was:" >&5
17133 cat conftest.$ac_ext >&5
17134 cf_have_curses_lib=no
17136 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17139 echo "$as_me: failed program was:" >&5
17140 cat conftest.$ac_ext >&5
17141 cf_have_curses_lib=no
17143 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17144 echo "$as_me:17144: result: $cf_have_curses_lib" >&5
17145 echo "${ECHO_T}$cf_have_curses_lib" >&6
17146 test "$cf_have_curses_lib" = maybe && cf_have_curses_lib=yes
17147 if test "$cf_have_curses_lib" != "yes"
17149 CPPFLAGS="$cf_save_CPPFLAGS"
17150 LIBS="$cf_save_LIBS"
17153 cf_upper=`echo "have_lib$FORM_NAME" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
17155 cat >>confdefs.h <<EOF
17156 #define $cf_upper 1
17162 if test "$cf_have_curses_lib" = no; then
17163 as_ac_Lib=`echo "ac_cv_lib_$FORM_NAME$cf_cv_libtype''_form_driver" | $as_tr_sh`
17164 echo "$as_me:17164: checking for form_driver in -l$FORM_NAME$cf_cv_libtype" >&5
17165 echo $ECHO_N "checking for form_driver in -l$FORM_NAME$cf_cv_libtype... $ECHO_C" >&6
17166 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
17167 echo $ECHO_N "(cached) $ECHO_C" >&6
17169 ac_check_lib_save_LIBS=$LIBS
17170 LIBS="-l$FORM_NAME$cf_cv_libtype $LIBS"
17171 cat >conftest.$ac_ext <<_ACEOF
17172 #line 17172 "configure"
17173 #include "confdefs.h"
17175 /* Override any gcc2 internal prototype to avoid an error. */
17179 /* We use char because int might match the return type of a gcc2
17180 builtin and then its argument prototype would still apply. */
17181 char form_driver ();
17190 rm -f conftest.$ac_objext conftest$ac_exeext
17191 if { (eval echo "$as_me:17191: \"$ac_link\"") >&5
17192 (eval $ac_link) 2>&5
17194 echo "$as_me:17194: \$? = $ac_status" >&5
17195 (exit $ac_status); } &&
17196 { ac_try='test -s conftest$ac_exeext'
17197 { (eval echo "$as_me:17197: \"$ac_try\"") >&5
17198 (eval $ac_try) 2>&5
17200 echo "$as_me:17200: \$? = $ac_status" >&5
17201 (exit $ac_status); }; }; then
17202 eval "$as_ac_Lib=yes"
17204 echo "$as_me: failed program was:" >&5
17205 cat conftest.$ac_ext >&5
17206 eval "$as_ac_Lib=no"
17208 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17209 LIBS=$ac_check_lib_save_LIBS
17211 echo "$as_me:17211: result: `eval echo '${'$as_ac_Lib'}'`" >&5
17212 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
17213 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
17215 cf_upper=`echo "have_lib$FORM_NAME" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
17217 cf_add_libs="$LIBS"
17220 for cf_add_1lib in -l$FORM_NAME$cf_cv_libtype; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
17221 # filter duplicates
17222 for cf_add_1lib in $cf_add_0lib; do
17223 for cf_add_2lib in $cf_add_libs; do
17224 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
17229 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
17231 LIBS="$cf_add_libs"
17233 cat >>confdefs.h <<EOF
17234 #define $cf_upper 1
17241 cf_curses_headers="$cf_curses_headers form.h"
17244 # look for curses-related headers
17246 for ac_header in $cf_curses_headers
17248 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
17249 echo "$as_me:17249: checking for $ac_header" >&5
17250 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17251 if eval "test \"\${$as_ac_Header+set}\" = set"; then
17252 echo $ECHO_N "(cached) $ECHO_C" >&6
17254 cat >conftest.$ac_ext <<_ACEOF
17255 #line 17255 "configure"
17256 #include "confdefs.h"
17257 #include <$ac_header>
17259 if { (eval echo "$as_me:17259: \"$ac_cpp conftest.$ac_ext\"") >&5
17260 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
17262 egrep -v '^ *\+' conftest.er1 >conftest.err
17264 cat conftest.err >&5
17265 echo "$as_me:17265: \$? = $ac_status" >&5
17266 (exit $ac_status); } >/dev/null; then
17267 if test -s conftest.err; then
17268 ac_cpp_err=$ac_c_preproc_warn_flag
17275 if test -z "$ac_cpp_err"; then
17276 eval "$as_ac_Header=yes"
17278 echo "$as_me: failed program was:" >&5
17279 cat conftest.$ac_ext >&5
17280 eval "$as_ac_Header=no"
17282 rm -f conftest.err conftest.$ac_ext
17284 echo "$as_me:17284: result: `eval echo '${'$as_ac_Header'}'`" >&5
17285 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
17286 if test `eval echo '${'$as_ac_Header'}'` = yes; then
17287 cat >>confdefs.h <<EOF
17288 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
17294 echo "$as_me:17294: checking for ANSI C header files" >&5
17295 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
17296 if test "${ac_cv_header_stdc+set}" = set; then
17297 echo $ECHO_N "(cached) $ECHO_C" >&6
17299 cat >conftest.$ac_ext <<_ACEOF
17300 #line 17300 "configure"
17301 #include "confdefs.h"
17302 #include <stdlib.h>
17303 #include <stdarg.h>
17304 #include <string.h>
17308 if { (eval echo "$as_me:17308: \"$ac_cpp conftest.$ac_ext\"") >&5
17309 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
17311 egrep -v '^ *\+' conftest.er1 >conftest.err
17313 cat conftest.err >&5
17314 echo "$as_me:17314: \$? = $ac_status" >&5
17315 (exit $ac_status); } >/dev/null; then
17316 if test -s conftest.err; then
17317 ac_cpp_err=$ac_c_preproc_warn_flag
17324 if test -z "$ac_cpp_err"; then
17325 ac_cv_header_stdc=yes
17327 echo "$as_me: failed program was:" >&5
17328 cat conftest.$ac_ext >&5
17329 ac_cv_header_stdc=no
17331 rm -f conftest.err conftest.$ac_ext
17333 if test $ac_cv_header_stdc = yes; then
17334 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
17335 cat >conftest.$ac_ext <<_ACEOF
17336 #line 17336 "configure"
17337 #include "confdefs.h"
17338 #include <string.h>
17341 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17342 egrep "memchr" >/dev/null 2>&1; then
17345 ac_cv_header_stdc=no
17351 if test $ac_cv_header_stdc = yes; then
17352 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
17353 cat >conftest.$ac_ext <<_ACEOF
17354 #line 17354 "configure"
17355 #include "confdefs.h"
17356 #include <stdlib.h>
17359 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17360 egrep "free" >/dev/null 2>&1; then
17363 ac_cv_header_stdc=no
17369 if test $ac_cv_header_stdc = yes; then
17370 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
17371 if test "$cross_compiling" = yes; then
17374 cat >conftest.$ac_ext <<_ACEOF
17375 #line 17375 "configure"
17376 #include "confdefs.h"
17378 #if ((' ' & 0x0FF) == 0x020)
17379 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
17380 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
17382 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
17383 || ('j' <= (c) && (c) <= 'r') \
17384 || ('s' <= (c) && (c) <= 'z'))
17385 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
17388 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
17393 for (i = 0; i < 256; i++)
17394 if (XOR (islower (i), ISLOWER (i))
17395 || toupper (i) != TOUPPER (i))
17396 $ac_main_return(2);
17397 $ac_main_return (0);
17400 rm -f conftest$ac_exeext
17401 if { (eval echo "$as_me:17401: \"$ac_link\"") >&5
17402 (eval $ac_link) 2>&5
17404 echo "$as_me:17404: \$? = $ac_status" >&5
17405 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17406 { (eval echo "$as_me:17406: \"$ac_try\"") >&5
17407 (eval $ac_try) 2>&5
17409 echo "$as_me:17409: \$? = $ac_status" >&5
17410 (exit $ac_status); }; }; then
17413 echo "$as_me: program exited with status $ac_status" >&5
17414 echo "$as_me: failed program was:" >&5
17415 cat conftest.$ac_ext >&5
17416 ac_cv_header_stdc=no
17418 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17422 echo "$as_me:17422: result: $ac_cv_header_stdc" >&5
17423 echo "${ECHO_T}$ac_cv_header_stdc" >&6
17424 if test $ac_cv_header_stdc = yes; then
17426 cat >>confdefs.h <<\EOF
17427 #define STDC_HEADERS 1
17432 echo "$as_me:17432: checking whether time.h and sys/time.h may both be included" >&5
17433 echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
17434 if test "${ac_cv_header_time+set}" = set; then
17435 echo $ECHO_N "(cached) $ECHO_C" >&6
17437 cat >conftest.$ac_ext <<_ACEOF
17438 #line 17438 "configure"
17439 #include "confdefs.h"
17440 #include <sys/types.h>
17441 #include <sys/time.h>
17447 if ((struct tm *) 0)
17453 rm -f conftest.$ac_objext
17454 if { (eval echo "$as_me:17454: \"$ac_compile\"") >&5
17455 (eval $ac_compile) 2>&5
17457 echo "$as_me:17457: \$? = $ac_status" >&5
17458 (exit $ac_status); } &&
17459 { ac_try='test -s conftest.$ac_objext'
17460 { (eval echo "$as_me:17460: \"$ac_try\"") >&5
17461 (eval $ac_try) 2>&5
17463 echo "$as_me:17463: \$? = $ac_status" >&5
17464 (exit $ac_status); }; }; then
17465 ac_cv_header_time=yes
17467 echo "$as_me: failed program was:" >&5
17468 cat conftest.$ac_ext >&5
17469 ac_cv_header_time=no
17471 rm -f conftest.$ac_objext conftest.$ac_ext
17473 echo "$as_me:17473: result: $ac_cv_header_time" >&5
17474 echo "${ECHO_T}$ac_cv_header_time" >&6
17475 if test $ac_cv_header_time = yes; then
17477 cat >>confdefs.h <<\EOF
17478 #define TIME_WITH_SYS_TIME 1
17496 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
17497 echo "$as_me:17497: checking for $ac_header" >&5
17498 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17499 if eval "test \"\${$as_ac_Header+set}\" = set"; then
17500 echo $ECHO_N "(cached) $ECHO_C" >&6
17502 cat >conftest.$ac_ext <<_ACEOF
17503 #line 17503 "configure"
17504 #include "confdefs.h"
17505 #include <$ac_header>
17507 if { (eval echo "$as_me:17507: \"$ac_cpp conftest.$ac_ext\"") >&5
17508 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
17510 egrep -v '^ *\+' conftest.er1 >conftest.err
17512 cat conftest.err >&5
17513 echo "$as_me:17513: \$? = $ac_status" >&5
17514 (exit $ac_status); } >/dev/null; then
17515 if test -s conftest.err; then
17516 ac_cpp_err=$ac_c_preproc_warn_flag
17523 if test -z "$ac_cpp_err"; then
17524 eval "$as_ac_Header=yes"
17526 echo "$as_me: failed program was:" >&5
17527 cat conftest.$ac_ext >&5
17528 eval "$as_ac_Header=no"
17530 rm -f conftest.err conftest.$ac_ext
17532 echo "$as_me:17532: result: `eval echo '${'$as_ac_Header'}'`" >&5
17533 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
17534 if test `eval echo '${'$as_ac_Header'}'` = yes; then
17535 cat >>confdefs.h <<EOF
17536 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
17542 for ac_header in unistd.h getopt.h
17544 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
17545 echo "$as_me:17545: checking for $ac_header" >&5
17546 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17547 if eval "test \"\${$as_ac_Header+set}\" = set"; then
17548 echo $ECHO_N "(cached) $ECHO_C" >&6
17550 cat >conftest.$ac_ext <<_ACEOF
17551 #line 17551 "configure"
17552 #include "confdefs.h"
17553 #include <$ac_header>
17555 if { (eval echo "$as_me:17555: \"$ac_cpp conftest.$ac_ext\"") >&5
17556 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
17558 egrep -v '^ *\+' conftest.er1 >conftest.err
17560 cat conftest.err >&5
17561 echo "$as_me:17561: \$? = $ac_status" >&5
17562 (exit $ac_status); } >/dev/null; then
17563 if test -s conftest.err; then
17564 ac_cpp_err=$ac_c_preproc_warn_flag
17571 if test -z "$ac_cpp_err"; then
17572 eval "$as_ac_Header=yes"
17574 echo "$as_me: failed program was:" >&5
17575 cat conftest.$ac_ext >&5
17576 eval "$as_ac_Header=no"
17578 rm -f conftest.err conftest.$ac_ext
17580 echo "$as_me:17580: result: `eval echo '${'$as_ac_Header'}'`" >&5
17581 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
17582 if test `eval echo '${'$as_ac_Header'}'` = yes; then
17583 cat >>confdefs.h <<EOF
17584 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
17590 echo "$as_me:17590: checking for header declaring getopt variables" >&5
17591 echo $ECHO_N "checking for header declaring getopt variables... $ECHO_C" >&6
17592 if test "${cf_cv_getopt_header+set}" = set; then
17593 echo $ECHO_N "(cached) $ECHO_C" >&6
17596 cf_cv_getopt_header=none
17597 for cf_header in stdio.h stdlib.h unistd.h getopt.h
17599 cat >conftest.$ac_ext <<_ACEOF
17600 #line 17600 "configure"
17601 #include "confdefs.h"
17603 #include <$cf_header>
17607 int x = optind; char *y = optarg
17612 rm -f conftest.$ac_objext
17613 if { (eval echo "$as_me:17613: \"$ac_compile\"") >&5
17614 (eval $ac_compile) 2>&5
17616 echo "$as_me:17616: \$? = $ac_status" >&5
17617 (exit $ac_status); } &&
17618 { ac_try='test -s conftest.$ac_objext'
17619 { (eval echo "$as_me:17619: \"$ac_try\"") >&5
17620 (eval $ac_try) 2>&5
17622 echo "$as_me:17622: \$? = $ac_status" >&5
17623 (exit $ac_status); }; }; then
17624 cf_cv_getopt_header=$cf_header
17627 echo "$as_me: failed program was:" >&5
17628 cat conftest.$ac_ext >&5
17630 rm -f conftest.$ac_objext conftest.$ac_ext
17634 echo "$as_me:17634: result: $cf_cv_getopt_header" >&5
17635 echo "${ECHO_T}$cf_cv_getopt_header" >&6
17636 if test $cf_cv_getopt_header != none ; then
17638 cat >>confdefs.h <<\EOF
17639 #define HAVE_GETOPT_HEADER 1
17643 if test $cf_cv_getopt_header = getopt.h ; then
17645 cat >>confdefs.h <<\EOF
17646 #define NEED_GETOPT_H 1
17660 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
17661 echo "$as_me:17661: checking for $ac_func" >&5
17662 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
17663 if eval "test \"\${$as_ac_var+set}\" = set"; then
17664 echo $ECHO_N "(cached) $ECHO_C" >&6
17666 cat >conftest.$ac_ext <<_ACEOF
17667 #line 17667 "configure"
17668 #include "confdefs.h"
17669 #define $ac_func autoconf_temporary
17670 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
17677 /* We use char because int might match the return type of a gcc2
17678 builtin and then its argument prototype would still apply. */
17679 char $ac_func (void);
17685 /* The GNU C library defines stubs for functions which it implements
17686 to always fail with ENOSYS. Some functions are actually named
17687 something starting with __ and the normal name is an alias. */
17688 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
17689 #error found stub for $ac_func
17692 return $ac_func ();
17697 rm -f conftest.$ac_objext conftest$ac_exeext
17698 if { (eval echo "$as_me:17698: \"$ac_link\"") >&5
17699 (eval $ac_link) 2>&5
17701 echo "$as_me:17701: \$? = $ac_status" >&5
17702 (exit $ac_status); } &&
17703 { ac_try='test -s conftest$ac_exeext'
17704 { (eval echo "$as_me:17704: \"$ac_try\"") >&5
17705 (eval $ac_try) 2>&5
17707 echo "$as_me:17707: \$? = $ac_status" >&5
17708 (exit $ac_status); }; }; then
17709 eval "$as_ac_var=yes"
17711 echo "$as_me: failed program was:" >&5
17712 cat conftest.$ac_ext >&5
17713 eval "$as_ac_var=no"
17715 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17717 echo "$as_me:17717: result: `eval echo '${'$as_ac_var'}'`" >&5
17718 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
17719 if test `eval echo '${'$as_ac_var'}'` = yes; then
17720 cat >>confdefs.h <<EOF
17721 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
17727 # use a compile-check to work with ncurses*-config and subdirectory includes
17728 echo "$as_me:17728: checking if we can use termcap.h" >&5
17729 echo $ECHO_N "checking if we can use termcap.h... $ECHO_C" >&6
17730 if test "${cf_cv_have_termcap_h+set}" = set; then
17731 echo $ECHO_N "(cached) $ECHO_C" >&6
17734 cat >conftest.$ac_ext <<_ACEOF
17735 #line 17735 "configure"
17736 #include "confdefs.h"
17738 #include <curses.h>
17739 #ifdef NCURSES_VERSION
17740 #undef NCURSES_VERSION
17742 #include <termcap.h>
17743 #ifndef NCURSES_VERSION
17744 #error wrong header
17755 rm -f conftest.$ac_objext
17756 if { (eval echo "$as_me:17756: \"$ac_compile\"") >&5
17757 (eval $ac_compile) 2>&5
17759 echo "$as_me:17759: \$? = $ac_status" >&5
17760 (exit $ac_status); } &&
17761 { ac_try='test -s conftest.$ac_objext'
17762 { (eval echo "$as_me:17762: \"$ac_try\"") >&5
17763 (eval $ac_try) 2>&5
17765 echo "$as_me:17765: \$? = $ac_status" >&5
17766 (exit $ac_status); }; }; then
17767 cf_cv_have_termcap_h=yes
17769 echo "$as_me: failed program was:" >&5
17770 cat conftest.$ac_ext >&5
17771 cf_cv_have_termcap_h=no
17773 rm -f conftest.$ac_objext conftest.$ac_ext
17775 echo "$as_me:17775: result: $cf_cv_have_termcap_h" >&5
17776 echo "${ECHO_T}$cf_cv_have_termcap_h" >&6
17777 if test "x$cf_cv_have_termcap_h" = xyes
17780 cat >>confdefs.h <<\EOF
17781 #define HAVE_TERMCAP_H 1
17785 echo "$as_me:17785: checking if we can use ncurses/termcap.h" >&5
17786 echo $ECHO_N "checking if we can use ncurses/termcap.h... $ECHO_C" >&6
17787 if test "${cf_cv_have_ncurses_termcap_h+set}" = set; then
17788 echo $ECHO_N "(cached) $ECHO_C" >&6
17791 cat >conftest.$ac_ext <<_ACEOF
17792 #line 17792 "configure"
17793 #include "confdefs.h"
17795 #include <ncurses/curses.h>
17796 #ifdef NCURSES_VERSION
17797 #undef NCURSES_VERSION
17799 #include <ncurses/termcap.h>
17800 #ifndef NCURSES_VERSION
17801 #error wrong header
17812 rm -f conftest.$ac_objext
17813 if { (eval echo "$as_me:17813: \"$ac_compile\"") >&5
17814 (eval $ac_compile) 2>&5
17816 echo "$as_me:17816: \$? = $ac_status" >&5
17817 (exit $ac_status); } &&
17818 { ac_try='test -s conftest.$ac_objext'
17819 { (eval echo "$as_me:17819: \"$ac_try\"") >&5
17820 (eval $ac_try) 2>&5
17822 echo "$as_me:17822: \$? = $ac_status" >&5
17823 (exit $ac_status); }; }; then
17824 cf_cv_have_ncurses_termcap_h=yes
17826 echo "$as_me: failed program was:" >&5
17827 cat conftest.$ac_ext >&5
17828 cf_cv_have_ncurses_termcap_h=no
17830 rm -f conftest.$ac_objext conftest.$ac_ext
17832 echo "$as_me:17832: result: $cf_cv_have_ncurses_termcap_h" >&5
17833 echo "${ECHO_T}$cf_cv_have_ncurses_termcap_h" >&6
17834 test "x$cf_cv_have_ncurses_termcap_h" = xyes &&
17835 cat >>confdefs.h <<\EOF
17836 #define HAVE_NCURSES_TERMCAP_H 1
17841 if test "x$ac_cv_func_getopt" = xno; then
17842 { { echo "$as_me:17842: error: getopt is required for building programs" >&5
17843 echo "$as_me: error: getopt is required for building programs" >&2;}
17844 { (exit 1); exit 1; }; }
17847 if test "$cf_enable_widec" = yes; then
17860 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
17861 echo "$as_me:17861: checking for $ac_func" >&5
17862 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
17863 if eval "test \"\${$as_ac_var+set}\" = set"; then
17864 echo $ECHO_N "(cached) $ECHO_C" >&6
17866 cat >conftest.$ac_ext <<_ACEOF
17867 #line 17867 "configure"
17868 #include "confdefs.h"
17869 #define $ac_func autoconf_temporary
17870 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
17877 /* We use char because int might match the return type of a gcc2
17878 builtin and then its argument prototype would still apply. */
17879 char $ac_func (void);
17885 /* The GNU C library defines stubs for functions which it implements
17886 to always fail with ENOSYS. Some functions are actually named
17887 something starting with __ and the normal name is an alias. */
17888 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
17889 #error found stub for $ac_func
17892 return $ac_func ();
17897 rm -f conftest.$ac_objext conftest$ac_exeext
17898 if { (eval echo "$as_me:17898: \"$ac_link\"") >&5
17899 (eval $ac_link) 2>&5
17901 echo "$as_me:17901: \$? = $ac_status" >&5
17902 (exit $ac_status); } &&
17903 { ac_try='test -s conftest$ac_exeext'
17904 { (eval echo "$as_me:17904: \"$ac_try\"") >&5
17905 (eval $ac_try) 2>&5
17907 echo "$as_me:17907: \$? = $ac_status" >&5
17908 (exit $ac_status); }; }; then
17909 eval "$as_ac_var=yes"
17911 echo "$as_me: failed program was:" >&5
17912 cat conftest.$ac_ext >&5
17913 eval "$as_ac_var=no"
17915 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17917 echo "$as_me:17917: result: `eval echo '${'$as_ac_var'}'`" >&5
17918 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
17919 if test `eval echo '${'$as_ac_var'}'` = yes; then
17920 cat >>confdefs.h <<EOF
17921 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
17929 echo "$as_me:17929: checking definition to turn on extended curses functions" >&5
17930 echo $ECHO_N "checking definition to turn on extended curses functions... $ECHO_C" >&6
17931 if test "${cf_cv_need_xopen_extension+set}" = set; then
17932 echo $ECHO_N "(cached) $ECHO_C" >&6
17935 cf_cv_need_xopen_extension=unknown
17936 cat >conftest.$ac_ext <<_ACEOF
17937 #line 17937 "configure"
17938 #include "confdefs.h"
17940 #include <stdlib.h>
17941 #include <${cf_cv_ncurses_header:-curses.h}>
17946 #if defined(NCURSES_VERSION_PATCH)
17947 #if (NCURSES_VERSION_PATCH < 20100501) && (NCURSES_VERSION_PATCH >= 20100403)
17951 #ifdef NCURSES_VERSION
17953 int check2 = curs_set((int)sizeof(check));
17955 long x = winnstr(stdscr, "", 0);
17957 #ifdef NCURSES_VERSION
17960 getbegyx(stdscr, y1, x1);
17969 rm -f conftest.$ac_objext conftest$ac_exeext
17970 if { (eval echo "$as_me:17970: \"$ac_link\"") >&5
17971 (eval $ac_link) 2>&5
17973 echo "$as_me:17973: \$? = $ac_status" >&5
17974 (exit $ac_status); } &&
17975 { ac_try='test -s conftest$ac_exeext'
17976 { (eval echo "$as_me:17976: \"$ac_try\"") >&5
17977 (eval $ac_try) 2>&5
17979 echo "$as_me:17979: \$? = $ac_status" >&5
17980 (exit $ac_status); }; }; then
17981 cf_cv_need_xopen_extension=none
17983 echo "$as_me: failed program was:" >&5
17984 cat conftest.$ac_ext >&5
17986 for cf_try_xopen_extension in _XOPEN_SOURCE_EXTENDED NCURSES_WIDECHAR
17988 cat >conftest.$ac_ext <<_ACEOF
17989 #line 17989 "configure"
17990 #include "confdefs.h"
17992 #define $cf_try_xopen_extension 1
17993 #include <stdlib.h>
17994 #include <${cf_cv_ncurses_header:-curses.h}>
17999 #ifdef NCURSES_VERSION
18001 int check2 = curs_set((int)sizeof(check));
18003 long x = winnstr(stdscr, "", 0);
18005 getbegyx(stdscr, y1, x1);
18006 #ifdef NCURSES_VERSION
18017 rm -f conftest.$ac_objext conftest$ac_exeext
18018 if { (eval echo "$as_me:18018: \"$ac_link\"") >&5
18019 (eval $ac_link) 2>&5
18021 echo "$as_me:18021: \$? = $ac_status" >&5
18022 (exit $ac_status); } &&
18023 { ac_try='test -s conftest$ac_exeext'
18024 { (eval echo "$as_me:18024: \"$ac_try\"") >&5
18025 (eval $ac_try) 2>&5
18027 echo "$as_me:18027: \$? = $ac_status" >&5
18028 (exit $ac_status); }; }; then
18029 cf_cv_need_xopen_extension=$cf_try_xopen_extension; break
18031 echo "$as_me: failed program was:" >&5
18032 cat conftest.$ac_ext >&5
18034 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18038 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18041 echo "$as_me:18041: result: $cf_cv_need_xopen_extension" >&5
18042 echo "${ECHO_T}$cf_cv_need_xopen_extension" >&6
18044 case $cf_cv_need_xopen_extension in
18047 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
18048 CPPFLAGS="${CPPFLAGS}-D$cf_cv_need_xopen_extension"
18053 echo "$as_me:18053: checking for term.h" >&5
18054 echo $ECHO_N "checking for term.h... $ECHO_C" >&6
18055 if test "${cf_cv_term_header+set}" = set; then
18056 echo $ECHO_N "(cached) $ECHO_C" >&6
18059 # If we found <ncurses/curses.h>, look for <ncurses/term.h>, but always look
18060 # for <term.h> if we do not find the variant.
18062 cf_header_list="term.h ncurses/term.h ncursesw/term.h"
18064 case ${cf_cv_ncurses_header:-curses.h} in
18066 cf_header_item=`echo ${cf_cv_ncurses_header:-curses.h} | sed -e 's%\..*%%' -e 's%/.*%/%'`term.h
18067 cf_header_list="$cf_header_item $cf_header_list"
18071 for cf_header in $cf_header_list
18073 cat >conftest.$ac_ext <<_ACEOF
18074 #line 18074 "configure"
18075 #include "confdefs.h"
18077 #include <${cf_cv_ncurses_header:-curses.h}>
18078 #include <${cf_header}>
18087 rm -f conftest.$ac_objext
18088 if { (eval echo "$as_me:18088: \"$ac_compile\"") >&5
18089 (eval $ac_compile) 2>&5
18091 echo "$as_me:18091: \$? = $ac_status" >&5
18092 (exit $ac_status); } &&
18093 { ac_try='test -s conftest.$ac_objext'
18094 { (eval echo "$as_me:18094: \"$ac_try\"") >&5
18095 (eval $ac_try) 2>&5
18097 echo "$as_me:18097: \$? = $ac_status" >&5
18098 (exit $ac_status); }; }; then
18099 cf_cv_term_header=$cf_header
18102 echo "$as_me: failed program was:" >&5
18103 cat conftest.$ac_ext >&5
18104 cf_cv_term_header=no
18106 rm -f conftest.$ac_objext conftest.$ac_ext
18109 case $cf_cv_term_header in
18111 # If curses is ncurses, some packagers still mess it up by trying to make
18112 # us use GNU termcap. This handles the most common case.
18113 for cf_header in ncurses/term.h ncursesw/term.h
18115 cat >conftest.$ac_ext <<_ACEOF
18116 #line 18116 "configure"
18117 #include "confdefs.h"
18119 #include <${cf_cv_ncurses_header:-curses.h}>
18120 #ifdef NCURSES_VERSION
18121 #include <${cf_header}>
18133 rm -f conftest.$ac_objext
18134 if { (eval echo "$as_me:18134: \"$ac_compile\"") >&5
18135 (eval $ac_compile) 2>&5
18137 echo "$as_me:18137: \$? = $ac_status" >&5
18138 (exit $ac_status); } &&
18139 { ac_try='test -s conftest.$ac_objext'
18140 { (eval echo "$as_me:18140: \"$ac_try\"") >&5
18141 (eval $ac_try) 2>&5
18143 echo "$as_me:18143: \$? = $ac_status" >&5
18144 (exit $ac_status); }; }; then
18145 cf_cv_term_header=$cf_header
18148 echo "$as_me: failed program was:" >&5
18149 cat conftest.$ac_ext >&5
18150 cf_cv_term_header=no
18152 rm -f conftest.$ac_objext conftest.$ac_ext
18158 echo "$as_me:18158: result: $cf_cv_term_header" >&5
18159 echo "${ECHO_T}$cf_cv_term_header" >&6
18161 case $cf_cv_term_header in
18164 cat >>confdefs.h <<\EOF
18165 #define HAVE_TERM_H 1
18171 cat >>confdefs.h <<\EOF
18172 #define HAVE_NCURSES_TERM_H 1
18178 cat >>confdefs.h <<\EOF
18179 #define HAVE_NCURSESW_TERM_H 1
18185 echo "$as_me:18185: checking for unctrl.h" >&5
18186 echo $ECHO_N "checking for unctrl.h... $ECHO_C" >&6
18187 if test "${cf_cv_unctrl_header+set}" = set; then
18188 echo $ECHO_N "(cached) $ECHO_C" >&6
18191 # If we found <ncurses/curses.h>, look for <ncurses/unctrl.h>, but always look
18192 # for <unctrl.h> if we do not find the variant.
18194 cf_header_list="unctrl.h ncurses/unctrl.h ncursesw/unctrl.h"
18196 case ${cf_cv_ncurses_header:-curses.h} in
18198 cf_header_item=`echo ${cf_cv_ncurses_header:-curses.h} | sed -e 's%\..*%%' -e 's%/.*%/%'`unctrl.h
18199 cf_header_list="$cf_header_item $cf_header_list"
18203 for cf_header in $cf_header_list
18205 cat >conftest.$ac_ext <<_ACEOF
18206 #line 18206 "configure"
18207 #include "confdefs.h"
18209 #include <${cf_cv_ncurses_header:-curses.h}>
18210 #include <${cf_header}>
18219 rm -f conftest.$ac_objext
18220 if { (eval echo "$as_me:18220: \"$ac_compile\"") >&5
18221 (eval $ac_compile) 2>&5
18223 echo "$as_me:18223: \$? = $ac_status" >&5
18224 (exit $ac_status); } &&
18225 { ac_try='test -s conftest.$ac_objext'
18226 { (eval echo "$as_me:18226: \"$ac_try\"") >&5
18227 (eval $ac_try) 2>&5
18229 echo "$as_me:18229: \$? = $ac_status" >&5
18230 (exit $ac_status); }; }; then
18231 cf_cv_unctrl_header=$cf_header
18234 echo "$as_me: failed program was:" >&5
18235 cat conftest.$ac_ext >&5
18236 cf_cv_unctrl_header=no
18238 rm -f conftest.$ac_objext conftest.$ac_ext
18242 echo "$as_me:18242: result: $cf_cv_unctrl_header" >&5
18243 echo "${ECHO_T}$cf_cv_unctrl_header" >&6
18245 case $cf_cv_unctrl_header in
18247 { echo "$as_me:18247: WARNING: unctrl.h header not found" >&5
18248 echo "$as_me: WARNING: unctrl.h header not found" >&2;}
18252 case $cf_cv_unctrl_header in
18255 cat >>confdefs.h <<\EOF
18256 #define HAVE_UNCTRL_H 1
18262 cat >>confdefs.h <<\EOF
18263 #define HAVE_NCURSES_UNCTRL_H 1
18267 (ncursesw/unctrl.h)
18269 cat >>confdefs.h <<\EOF
18270 #define HAVE_NCURSESW_UNCTRL_H 1
18278 assume_default_colors \
18295 init_extended_color \
18303 reset_color_pairs \
18319 use_default_colors \
18321 use_extended_names \
18337 cf_tr_func=`echo "$cf_func" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
18339 echo "$as_me:18339: checking for ${cf_func}" >&5
18340 echo $ECHO_N "checking for ${cf_func}... $ECHO_C" >&6
18342 echo "${as_me:-configure}:18342: testing ${cf_func} ..." 1>&5
18344 if eval "test \"\${cf_cv_func_$cf_func+set}\" = set"; then
18345 echo $ECHO_N "(cached) $ECHO_C" >&6
18348 eval cf_result='$ac_cv_func_'$cf_func
18349 if test ".$cf_result" != ".no"; then
18350 cat >conftest.$ac_ext <<_ACEOF
18351 #line 18351 "configure"
18352 #include "confdefs.h"
18354 #ifdef HAVE_XCURSES
18355 #include <xcurses.h>
18356 char * XCursesProgramName = "test";
18358 #include <${cf_cv_ncurses_header:-curses.h}>
18359 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
18360 #include <ncursesw/term.h>
18361 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
18362 #include <ncurses/term.h>
18363 #elif defined(HAVE_TERM_H)
18373 long foo = (long)(&${cf_func});
18374 fprintf(stderr, "testing linkage of $cf_func:%p\n", (void *)foo);
18375 if (foo + 1234L > 5678L)
18376 ${cf_cv_main_return:-return}(foo != 0);
18383 rm -f conftest.$ac_objext conftest$ac_exeext
18384 if { (eval echo "$as_me:18384: \"$ac_link\"") >&5
18385 (eval $ac_link) 2>&5
18387 echo "$as_me:18387: \$? = $ac_status" >&5
18388 (exit $ac_status); } &&
18389 { ac_try='test -s conftest$ac_exeext'
18390 { (eval echo "$as_me:18390: \"$ac_try\"") >&5
18391 (eval $ac_try) 2>&5
18393 echo "$as_me:18393: \$? = $ac_status" >&5
18394 (exit $ac_status); }; }; then
18397 echo "$as_me: failed program was:" >&5
18398 cat conftest.$ac_ext >&5
18401 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18403 eval 'cf_cv_func_'$cf_func'=$cf_result'
18407 # use the computed/retrieved cache-value:
18408 eval 'cf_result=$cf_cv_func_'$cf_func
18409 echo "$as_me:18409: result: $cf_result" >&5
18410 echo "${ECHO_T}$cf_result" >&6
18411 if test $cf_result != no; then
18412 cat >>confdefs.h <<EOF
18413 #define HAVE_${cf_tr_func} 1
18419 for cf_func in tputs
18422 cf_tr_func=`echo "$cf_func" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
18424 echo "$as_me:18424: checking for ${cf_func}" >&5
18425 echo $ECHO_N "checking for ${cf_func}... $ECHO_C" >&6
18427 echo "${as_me:-configure}:18427: testing ${cf_func} ..." 1>&5
18429 if eval "test \"\${cf_cv_func_$cf_func+set}\" = set"; then
18430 echo $ECHO_N "(cached) $ECHO_C" >&6
18433 eval cf_result='$ac_cv_func_'$cf_func
18434 if test ".$cf_result" != ".no"; then
18435 cat >conftest.$ac_ext <<_ACEOF
18436 #line 18436 "configure"
18437 #include "confdefs.h"
18439 #ifdef HAVE_XCURSES
18440 #include <xcurses.h>
18441 char * XCursesProgramName = "test";
18443 #include <${cf_cv_ncurses_header:-curses.h}>
18444 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
18445 #include <ncursesw/term.h>
18446 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
18447 #include <ncurses/term.h>
18448 #elif defined(HAVE_TERM_H)
18458 long foo = (long)(&${cf_func});
18459 fprintf(stderr, "testing linkage of $cf_func:%p\n", (void *)foo);
18460 if (foo + 1234L > 5678L)
18461 ${cf_cv_main_return:-return}(foo != 0);
18468 rm -f conftest.$ac_objext conftest$ac_exeext
18469 if { (eval echo "$as_me:18469: \"$ac_link\"") >&5
18470 (eval $ac_link) 2>&5
18472 echo "$as_me:18472: \$? = $ac_status" >&5
18473 (exit $ac_status); } &&
18474 { ac_try='test -s conftest$ac_exeext'
18475 { (eval echo "$as_me:18475: \"$ac_try\"") >&5
18476 (eval $ac_try) 2>&5
18478 echo "$as_me:18478: \$? = $ac_status" >&5
18479 (exit $ac_status); }; }; then
18482 echo "$as_me: failed program was:" >&5
18483 cat conftest.$ac_ext >&5
18486 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18488 eval 'cf_cv_func_'$cf_func'=$cf_result'
18492 # use the computed/retrieved cache-value:
18493 eval 'cf_result=$cf_cv_func_'$cf_func
18494 echo "$as_me:18494: result: $cf_result" >&5
18495 echo "${ECHO_T}$cf_result" >&6
18496 if test $cf_result != no; then
18497 cat >>confdefs.h <<EOF
18498 #define HAVE_${cf_tr_func} 1
18504 if test x$cf_cv_func_tputs = xyes
18507 for cf_arg in int char
18509 for cf_ret in int void
18511 if test $cf_ret = void
18513 cf_return="/* nothing */"
18515 cf_return="return value"
18517 cat >conftest.$ac_ext <<_ACEOF
18518 #line 18518 "configure"
18519 #include "confdefs.h"
18521 #include <${cf_cv_ncurses_header:-curses.h}>
18522 #include <$cf_cv_term_header>
18524 static $cf_ret outc($cf_arg value) { $cf_return; }
18530 tputs("hello", 0, outc);
18531 ${cf_cv_main_return:-return}(0);
18537 rm -f conftest.$ac_objext
18538 if { (eval echo "$as_me:18538: \"$ac_compile\"") >&5
18539 (eval $ac_compile) 2>&5
18541 echo "$as_me:18541: \$? = $ac_status" >&5
18542 (exit $ac_status); } &&
18543 { ac_try='test -s conftest.$ac_objext'
18544 { (eval echo "$as_me:18544: \"$ac_try\"") >&5
18545 (eval $ac_try) 2>&5
18547 echo "$as_me:18547: \$? = $ac_status" >&5
18548 (exit $ac_status); }; }; then
18550 test -n "$verbose" && echo " prototype $cf_ret func($cf_arg value)" 1>&6
18552 echo "${as_me:-configure}:18552: testing prototype $cf_ret func($cf_arg value) ..." 1>&5
18554 cat >>confdefs.h <<EOF
18555 #define TPUTS_ARG $cf_arg
18556 #define TPUTS_PROTO(func,value) $cf_ret func(TPUTS_ARG value)
18557 #define TPUTS_RETURN(value) $cf_return
18563 echo "$as_me: failed program was:" >&5
18564 cat conftest.$ac_ext >&5
18566 rm -f conftest.$ac_objext conftest.$ac_ext
18568 test $cf_done = yes && break
18572 echo "$as_me:18572: checking for ncurses extended functions" >&5
18573 echo $ECHO_N "checking for ncurses extended functions... $ECHO_C" >&6
18574 if test "${cf_cv_ncurses_ext_funcs+set}" = set; then
18575 echo $ECHO_N "(cached) $ECHO_C" >&6
18578 cat >conftest.$ac_ext <<_ACEOF
18579 #line 18579 "configure"
18580 #include "confdefs.h"
18582 #include <${cf_cv_ncurses_header:-curses.h}>
18587 int x = NCURSES_EXT_FUNCS
18593 rm -f conftest.$ac_objext
18594 if { (eval echo "$as_me:18594: \"$ac_compile\"") >&5
18595 (eval $ac_compile) 2>&5
18597 echo "$as_me:18597: \$? = $ac_status" >&5
18598 (exit $ac_status); } &&
18599 { ac_try='test -s conftest.$ac_objext'
18600 { (eval echo "$as_me:18600: \"$ac_try\"") >&5
18601 (eval $ac_try) 2>&5
18603 echo "$as_me:18603: \$? = $ac_status" >&5
18604 (exit $ac_status); }; }; then
18605 cf_cv_ncurses_ext_funcs=defined
18607 echo "$as_me: failed program was:" >&5
18608 cat conftest.$ac_ext >&5
18610 cat >conftest.$ac_ext <<_ACEOF
18611 #line 18611 "configure"
18612 #include "confdefs.h"
18614 #include <${cf_cv_ncurses_header:-curses.h}>
18619 (void) assume_default_colors (0, 0);
18620 (void) curses_version ();
18621 (void) define_key (0, 0);
18622 (void) is_term_resized (0, 0);
18623 (void) key_defined (0);
18624 (void) keybound (0, 0);
18625 (void) keyok (0, 0);
18626 (void) resize_term (0, 0);
18627 (void) resizeterm (0, 0);
18628 (void) use_default_colors ();
18629 (void) use_extended_names (0);
18630 (void) wresize (0, 0, 0);
18635 rm -f conftest.$ac_objext conftest$ac_exeext
18636 if { (eval echo "$as_me:18636: \"$ac_link\"") >&5
18637 (eval $ac_link) 2>&5
18639 echo "$as_me:18639: \$? = $ac_status" >&5
18640 (exit $ac_status); } &&
18641 { ac_try='test -s conftest$ac_exeext'
18642 { (eval echo "$as_me:18642: \"$ac_try\"") >&5
18643 (eval $ac_try) 2>&5
18645 echo "$as_me:18645: \$? = $ac_status" >&5
18646 (exit $ac_status); }; }; then
18647 cf_cv_ncurses_ext_funcs=yes
18649 echo "$as_me: failed program was:" >&5
18650 cat conftest.$ac_ext >&5
18651 cf_cv_ncurses_ext_funcs=no
18653 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18656 rm -f conftest.$ac_objext conftest.$ac_ext
18659 echo "$as_me:18659: result: $cf_cv_ncurses_ext_funcs" >&5
18660 echo "${ECHO_T}$cf_cv_ncurses_ext_funcs" >&6
18661 test "$cf_cv_ncurses_ext_funcs" = yes &&
18662 cat >>confdefs.h <<\EOF
18663 #define NCURSES_EXT_FUNCS 1
18666 if test "$cf_enable_widec" = yes
18668 # workaround for systems with ncurses before 20111029, due to change of
18669 # feature test macro from _XPG5 to _XOPEN_SOURCE
18670 if test -n "$cf_cv_ncurses_version" && test "x$cf_cv_ncurses_version" != xno
18673 echo "$as_me:18673: checking if _XPG5 should be defined to enable wide-characters" >&5
18674 echo $ECHO_N "checking if _XPG5 should be defined to enable wide-characters... $ECHO_C" >&6
18676 cat >conftest.$ac_ext <<_ACEOF
18677 #line 18677 "configure"
18678 #include "confdefs.h"
18680 #include <${cf_cv_ncurses_header:-curses.h}>
18689 rm -f conftest.$ac_objext
18690 if { (eval echo "$as_me:18690: \"$ac_compile\"") >&5
18691 (eval $ac_compile) 2>&5
18693 echo "$as_me:18693: \$? = $ac_status" >&5
18694 (exit $ac_status); } &&
18695 { ac_try='test -s conftest.$ac_objext'
18696 { (eval echo "$as_me:18696: \"$ac_try\"") >&5
18697 (eval $ac_try) 2>&5
18699 echo "$as_me:18699: \$? = $ac_status" >&5
18700 (exit $ac_status); }; }; then
18703 echo "$as_me: failed program was:" >&5
18704 cat conftest.$ac_ext >&5
18705 cf_save_cppflags="$CPPFLAGS"
18706 CPPFLAGS="$CPPFLAGS -D_XPG5"
18707 cat >conftest.$ac_ext <<_ACEOF
18708 #line 18708 "configure"
18709 #include "confdefs.h"
18711 #include <${cf_cv_ncurses_header:-curses.h}>
18720 rm -f conftest.$ac_objext
18721 if { (eval echo "$as_me:18721: \"$ac_compile\"") >&5
18722 (eval $ac_compile) 2>&5
18724 echo "$as_me:18724: \$? = $ac_status" >&5
18725 (exit $ac_status); } &&
18726 { ac_try='test -s conftest.$ac_objext'
18727 { (eval echo "$as_me:18727: \"$ac_try\"") >&5
18728 (eval $ac_try) 2>&5
18730 echo "$as_me:18730: \$? = $ac_status" >&5
18731 (exit $ac_status); }; }; then
18734 echo "$as_me: failed program was:" >&5
18735 cat conftest.$ac_ext >&5
18737 rm -f conftest.$ac_objext conftest.$ac_ext
18738 CPPFLAGS="$cf_save_cppflags"
18740 rm -f conftest.$ac_objext conftest.$ac_ext
18741 echo "$as_me:18741: result: $cf_define_xpg5" >&5
18742 echo "${ECHO_T}$cf_define_xpg5" >&6
18744 if test "$cf_define_xpg5" = yes
18746 CPPFLAGS="$CPPFLAGS -D_XPG5"
18750 echo "$as_me:18750: checking for wide-character functions" >&5
18751 echo $ECHO_N "checking for wide-character functions... $ECHO_C" >&6
18752 if test "${cf_cv_widechar_funcs+set}" = set; then
18753 echo $ECHO_N "(cached) $ECHO_C" >&6
18756 cat >conftest.$ac_ext <<_ACEOF
18757 #line 18757 "configure"
18758 #include "confdefs.h"
18760 #include <${cf_cv_ncurses_header:-curses.h}>
18765 static wchar_t src_wchar[2];
18766 static cchar_t dst_cchar;
18767 setcchar(&dst_cchar, src_wchar, A_NORMAL, 0, (void *) 0);
18773 rm -f conftest.$ac_objext conftest$ac_exeext
18774 if { (eval echo "$as_me:18774: \"$ac_link\"") >&5
18775 (eval $ac_link) 2>&5
18777 echo "$as_me:18777: \$? = $ac_status" >&5
18778 (exit $ac_status); } &&
18779 { ac_try='test -s conftest$ac_exeext'
18780 { (eval echo "$as_me:18780: \"$ac_try\"") >&5
18781 (eval $ac_try) 2>&5
18783 echo "$as_me:18783: \$? = $ac_status" >&5
18784 (exit $ac_status); }; }; then
18785 cf_cv_widechar_funcs=yes
18787 echo "$as_me: failed program was:" >&5
18788 cat conftest.$ac_ext >&5
18789 cf_cv_widechar_funcs=no
18791 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18794 echo "$as_me:18794: result: $cf_cv_widechar_funcs" >&5
18795 echo "${ECHO_T}$cf_cv_widechar_funcs" >&6
18796 if test "$cf_cv_widechar_funcs" != no ; then
18798 cat >>confdefs.h <<\EOF
18799 #define USE_WIDEC_SUPPORT 1
18803 cat >>confdefs.h <<\EOF
18804 #define USE_WIDEC_SUPPORT 0
18809 cat >>confdefs.h <<\EOF
18810 #define USE_WIDEC_SUPPORT 0
18815 echo "$as_me:18815: checking if $cf_cv_screen library uses pthreads" >&5
18816 echo $ECHO_N "checking if $cf_cv_screen library uses pthreads... $ECHO_C" >&6
18817 if test "${cf_cv_use_pthreads+set}" = set; then
18818 echo $ECHO_N "(cached) $ECHO_C" >&6
18821 cat >conftest.$ac_ext <<_ACEOF
18822 #line 18822 "configure"
18823 #include "confdefs.h"
18825 #include <${cf_cv_ncurses_header:-curses.h}>
18826 extern void _nc_init_pthreads(void);
18833 _nc_init_pthreads();
18839 rm -f conftest.$ac_objext conftest$ac_exeext
18840 if { (eval echo "$as_me:18840: \"$ac_link\"") >&5
18841 (eval $ac_link) 2>&5
18843 echo "$as_me:18843: \$? = $ac_status" >&5
18844 (exit $ac_status); } &&
18845 { ac_try='test -s conftest$ac_exeext'
18846 { (eval echo "$as_me:18846: \"$ac_try\"") >&5
18847 (eval $ac_try) 2>&5
18849 echo "$as_me:18849: \$? = $ac_status" >&5
18850 (exit $ac_status); }; }; then
18851 cf_cv_use_pthreads=yes
18853 echo "$as_me: failed program was:" >&5
18854 cat conftest.$ac_ext >&5
18855 cf_cv_use_pthreads=no
18857 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18860 echo "$as_me:18860: result: $cf_cv_use_pthreads" >&5
18861 echo "${ECHO_T}$cf_cv_use_pthreads" >&6
18862 test $cf_cv_use_pthreads = yes &&
18863 cat >>confdefs.h <<\EOF
18864 #define USE_PTHREADS 1
18867 echo "$as_me:18867: checking if sys/time.h works with sys/select.h" >&5
18868 echo $ECHO_N "checking if sys/time.h works with sys/select.h... $ECHO_C" >&6
18869 if test "${cf_cv_sys_time_select+set}" = set; then
18870 echo $ECHO_N "(cached) $ECHO_C" >&6
18873 cat >conftest.$ac_ext <<_ACEOF
18874 #line 18874 "configure"
18875 #include "confdefs.h"
18877 #include <sys/types.h>
18878 #ifdef HAVE_SYS_TIME_H
18879 #include <sys/time.h>
18881 #ifdef HAVE_SYS_SELECT_H
18882 #include <sys/select.h>
18893 rm -f conftest.$ac_objext
18894 if { (eval echo "$as_me:18894: \"$ac_compile\"") >&5
18895 (eval $ac_compile) 2>&5
18897 echo "$as_me:18897: \$? = $ac_status" >&5
18898 (exit $ac_status); } &&
18899 { ac_try='test -s conftest.$ac_objext'
18900 { (eval echo "$as_me:18900: \"$ac_try\"") >&5
18901 (eval $ac_try) 2>&5
18903 echo "$as_me:18903: \$? = $ac_status" >&5
18904 (exit $ac_status); }; }; then
18905 cf_cv_sys_time_select=yes
18907 echo "$as_me: failed program was:" >&5
18908 cat conftest.$ac_ext >&5
18909 cf_cv_sys_time_select=no
18911 rm -f conftest.$ac_objext conftest.$ac_ext
18915 echo "$as_me:18915: result: $cf_cv_sys_time_select" >&5
18916 echo "${ECHO_T}$cf_cv_sys_time_select" >&6
18917 test "$cf_cv_sys_time_select" = yes &&
18918 cat >>confdefs.h <<\EOF
18919 #define HAVE_SYS_TIME_SELECT 1
18922 # special check for test/ditto.c
18924 echo "$as_me:18924: checking for openpty in -lutil" >&5
18925 echo $ECHO_N "checking for openpty in -lutil... $ECHO_C" >&6
18926 if test "${ac_cv_lib_util_openpty+set}" = set; then
18927 echo $ECHO_N "(cached) $ECHO_C" >&6
18929 ac_check_lib_save_LIBS=$LIBS
18930 LIBS="-lutil $LIBS"
18931 cat >conftest.$ac_ext <<_ACEOF
18932 #line 18932 "configure"
18933 #include "confdefs.h"
18935 /* Override any gcc2 internal prototype to avoid an error. */
18939 /* We use char because int might match the return type of a gcc2
18940 builtin and then its argument prototype would still apply. */
18950 rm -f conftest.$ac_objext conftest$ac_exeext
18951 if { (eval echo "$as_me:18951: \"$ac_link\"") >&5
18952 (eval $ac_link) 2>&5
18954 echo "$as_me:18954: \$? = $ac_status" >&5
18955 (exit $ac_status); } &&
18956 { ac_try='test -s conftest$ac_exeext'
18957 { (eval echo "$as_me:18957: \"$ac_try\"") >&5
18958 (eval $ac_try) 2>&5
18960 echo "$as_me:18960: \$? = $ac_status" >&5
18961 (exit $ac_status); }; }; then
18962 ac_cv_lib_util_openpty=yes
18964 echo "$as_me: failed program was:" >&5
18965 cat conftest.$ac_ext >&5
18966 ac_cv_lib_util_openpty=no
18968 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18969 LIBS=$ac_check_lib_save_LIBS
18971 echo "$as_me:18971: result: $ac_cv_lib_util_openpty" >&5
18972 echo "${ECHO_T}$ac_cv_lib_util_openpty" >&6
18973 if test $ac_cv_lib_util_openpty = yes; then
18979 echo "$as_me:18979: checking for openpty header" >&5
18980 echo $ECHO_N "checking for openpty header... $ECHO_C" >&6
18981 if test "${cf_cv_func_openpty+set}" = set; then
18982 echo $ECHO_N "(cached) $ECHO_C" >&6
18985 cf_save_LIBS="$LIBS"
18986 test $cf_cv_lib_util = yes && {
18987 cf_add_libs="$LIBS"
18990 for cf_add_1lib in -lutil; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
18991 # filter duplicates
18992 for cf_add_1lib in $cf_add_0lib; do
18993 for cf_add_2lib in $cf_add_libs; do
18994 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
18999 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
19001 LIBS="$cf_add_libs"
19003 for cf_header in pty.h libutil.h util.h
19005 cat >conftest.$ac_ext <<_ACEOF
19006 #line 19006 "configure"
19007 #include "confdefs.h"
19009 #include <$cf_header>
19015 int x = openpty((int *)0, (int *)0, (char *)0,
19016 (struct termios *)0, (struct winsize *)0);
19022 rm -f conftest.$ac_objext conftest$ac_exeext
19023 if { (eval echo "$as_me:19023: \"$ac_link\"") >&5
19024 (eval $ac_link) 2>&5
19026 echo "$as_me:19026: \$? = $ac_status" >&5
19027 (exit $ac_status); } &&
19028 { ac_try='test -s conftest$ac_exeext'
19029 { (eval echo "$as_me:19029: \"$ac_try\"") >&5
19030 (eval $ac_try) 2>&5
19032 echo "$as_me:19032: \$? = $ac_status" >&5
19033 (exit $ac_status); }; }; then
19035 cf_cv_func_openpty=$cf_header
19039 echo "$as_me: failed program was:" >&5
19040 cat conftest.$ac_ext >&5
19042 cf_cv_func_openpty=no
19045 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
19047 LIBS="$cf_save_LIBS"
19050 echo "$as_me:19050: result: $cf_cv_func_openpty" >&5
19051 echo "${ECHO_T}$cf_cv_func_openpty" >&6
19053 if test "$cf_cv_func_openpty" != no ; then
19055 cat >>confdefs.h <<EOF
19056 #define USE_OPENPTY_HEADER <$cf_cv_func_openpty>
19059 cat >>confdefs.h <<\EOF
19060 #define USE_XTERM_PTY 1
19063 if test "x$cf_cv_lib_util" = xyes ; then
19065 cf_add_libs="$TEST_LIBS"
19068 for cf_add_1lib in -lutil; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
19069 # filter duplicates
19070 for cf_add_1lib in $cf_add_0lib; do
19071 for cf_add_2lib in $cf_add_libs; do
19072 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
19077 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
19079 TEST_LIBS="$cf_add_libs"
19084 echo "$as_me:19084: checking for function curses_version" >&5
19085 echo $ECHO_N "checking for function curses_version... $ECHO_C" >&6
19086 if test "${cf_cv_func_curses_version+set}" = set; then
19087 echo $ECHO_N "(cached) $ECHO_C" >&6
19090 if test "$cross_compiling" = yes; then
19091 cf_cv_func_curses_version=unknown
19093 cat >conftest.$ac_ext <<_ACEOF
19094 #line 19094 "configure"
19095 #include "confdefs.h"
19097 #include <${cf_cv_ncurses_header:-curses.h}>
19101 sprintf(temp, "%s\n", curses_version());
19102 ${cf_cv_main_return:-return}(0);
19106 rm -f conftest$ac_exeext
19107 if { (eval echo "$as_me:19107: \"$ac_link\"") >&5
19108 (eval $ac_link) 2>&5
19110 echo "$as_me:19110: \$? = $ac_status" >&5
19111 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19112 { (eval echo "$as_me:19112: \"$ac_try\"") >&5
19113 (eval $ac_try) 2>&5
19115 echo "$as_me:19115: \$? = $ac_status" >&5
19116 (exit $ac_status); }; }; then
19117 cf_cv_func_curses_version=yes
19120 echo "$as_me: program exited with status $ac_status" >&5
19121 echo "$as_me: failed program was:" >&5
19122 cat conftest.$ac_ext >&5
19123 cf_cv_func_curses_version=no
19126 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19130 echo "$as_me:19130: result: $cf_cv_func_curses_version" >&5
19131 echo "${ECHO_T}$cf_cv_func_curses_version" >&6
19132 test "$cf_cv_func_curses_version" = yes &&
19133 cat >>confdefs.h <<\EOF
19134 #define HAVE_CURSES_VERSION 1
19137 echo "$as_me:19137: checking for alternate character set array" >&5
19138 echo $ECHO_N "checking for alternate character set array... $ECHO_C" >&6
19139 if test "${cf_cv_curses_acs_map+set}" = set; then
19140 echo $ECHO_N "(cached) $ECHO_C" >&6
19143 cf_cv_curses_acs_map=unknown
19144 for name in acs_map _acs_map __acs_map ${NCURSES_WRAP_PREFIX}acs_map
19146 cat >conftest.$ac_ext <<_ACEOF
19147 #line 19147 "configure"
19148 #include "confdefs.h"
19150 #include <${cf_cv_ncurses_header:-curses.h}>
19156 $name['k'] = ACS_PLUS
19162 rm -f conftest.$ac_objext conftest$ac_exeext
19163 if { (eval echo "$as_me:19163: \"$ac_link\"") >&5
19164 (eval $ac_link) 2>&5
19166 echo "$as_me:19166: \$? = $ac_status" >&5
19167 (exit $ac_status); } &&
19168 { ac_try='test -s conftest$ac_exeext'
19169 { (eval echo "$as_me:19169: \"$ac_try\"") >&5
19170 (eval $ac_try) 2>&5
19172 echo "$as_me:19172: \$? = $ac_status" >&5
19173 (exit $ac_status); }; }; then
19174 cf_cv_curses_acs_map=$name; break
19176 echo "$as_me: failed program was:" >&5
19177 cat conftest.$ac_ext >&5
19179 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
19183 echo "$as_me:19183: result: $cf_cv_curses_acs_map" >&5
19184 echo "${ECHO_T}$cf_cv_curses_acs_map" >&6
19186 test "$cf_cv_curses_acs_map" != unknown &&
19187 cat >>confdefs.h <<EOF
19188 #define CURSES_ACS_ARRAY $cf_cv_curses_acs_map
19191 if test "$cf_enable_widec" = yes; then
19193 echo "$as_me:19193: checking for wide alternate character set array" >&5
19194 echo $ECHO_N "checking for wide alternate character set array... $ECHO_C" >&6
19195 if test "${cf_cv_curses_wacs_map+set}" = set; then
19196 echo $ECHO_N "(cached) $ECHO_C" >&6
19199 cf_cv_curses_wacs_map=unknown
19200 for name in wacs_map _wacs_map __wacs_map _nc_wacs _wacs_char
19202 cat >conftest.$ac_ext <<_ACEOF
19203 #line 19203 "configure"
19204 #include "confdefs.h"
19206 #ifndef _XOPEN_SOURCE_EXTENDED
19207 #define _XOPEN_SOURCE_EXTENDED
19209 #include <${cf_cv_ncurses_header:-curses.h}>
19213 void *foo = &($name['k']); (void)foo
19218 rm -f conftest.$ac_objext conftest$ac_exeext
19219 if { (eval echo "$as_me:19219: \"$ac_link\"") >&5
19220 (eval $ac_link) 2>&5
19222 echo "$as_me:19222: \$? = $ac_status" >&5
19223 (exit $ac_status); } &&
19224 { ac_try='test -s conftest$ac_exeext'
19225 { (eval echo "$as_me:19225: \"$ac_try\"") >&5
19226 (eval $ac_try) 2>&5
19228 echo "$as_me:19228: \$? = $ac_status" >&5
19229 (exit $ac_status); }; }; then
19230 cf_cv_curses_wacs_map=$name
19233 echo "$as_me: failed program was:" >&5
19234 cat conftest.$ac_ext >&5
19236 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
19239 echo "$as_me:19239: result: $cf_cv_curses_wacs_map" >&5
19240 echo "${ECHO_T}$cf_cv_curses_wacs_map" >&6
19242 test "$cf_cv_curses_wacs_map" != unknown &&
19243 cat >>confdefs.h <<EOF
19244 #define CURSES_WACS_ARRAY $cf_cv_curses_wacs_map
19247 echo "$as_me:19247: checking for wide alternate character constants" >&5
19248 echo $ECHO_N "checking for wide alternate character constants... $ECHO_C" >&6
19249 if test "${cf_cv_curses_wacs_symbols+set}" = set; then
19250 echo $ECHO_N "(cached) $ECHO_C" >&6
19253 cf_cv_curses_wacs_symbols=no
19254 if test "$cf_cv_curses_wacs_map" != unknown
19256 cat >conftest.$ac_ext <<_ACEOF
19257 #line 19257 "configure"
19258 #include "confdefs.h"
19260 #ifndef _XOPEN_SOURCE_EXTENDED
19261 #define _XOPEN_SOURCE_EXTENDED
19263 #include <${cf_cv_ncurses_header:-curses.h}>
19267 cchar_t *foo = WACS_PLUS;
19268 $cf_cv_curses_wacs_map['k'] = *WACS_PLUS; (void)foo
19273 rm -f conftest.$ac_objext conftest$ac_exeext
19274 if { (eval echo "$as_me:19274: \"$ac_link\"") >&5
19275 (eval $ac_link) 2>&5
19277 echo "$as_me:19277: \$? = $ac_status" >&5
19278 (exit $ac_status); } &&
19279 { ac_try='test -s conftest$ac_exeext'
19280 { (eval echo "$as_me:19280: \"$ac_try\"") >&5
19281 (eval $ac_try) 2>&5
19283 echo "$as_me:19283: \$? = $ac_status" >&5
19284 (exit $ac_status); }; }; then
19285 cf_cv_curses_wacs_symbols=yes
19287 echo "$as_me: failed program was:" >&5
19288 cat conftest.$ac_ext >&5
19290 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
19292 cat >conftest.$ac_ext <<_ACEOF
19293 #line 19293 "configure"
19294 #include "confdefs.h"
19296 #ifndef _XOPEN_SOURCE_EXTENDED
19297 #define _XOPEN_SOURCE_EXTENDED
19299 #include <${cf_cv_ncurses_header:-curses.h}>
19303 cchar_t *foo = WACS_PLUS; (void)foo
19308 rm -f conftest.$ac_objext conftest$ac_exeext
19309 if { (eval echo "$as_me:19309: \"$ac_link\"") >&5
19310 (eval $ac_link) 2>&5
19312 echo "$as_me:19312: \$? = $ac_status" >&5
19313 (exit $ac_status); } &&
19314 { ac_try='test -s conftest$ac_exeext'
19315 { (eval echo "$as_me:19315: \"$ac_try\"") >&5
19316 (eval $ac_try) 2>&5
19318 echo "$as_me:19318: \$? = $ac_status" >&5
19319 (exit $ac_status); }; }; then
19320 cf_cv_curses_wacs_symbols=yes
19322 echo "$as_me: failed program was:" >&5
19323 cat conftest.$ac_ext >&5
19325 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
19329 echo "$as_me:19329: result: $cf_cv_curses_wacs_symbols" >&5
19330 echo "${ECHO_T}$cf_cv_curses_wacs_symbols" >&6
19332 test "$cf_cv_curses_wacs_symbols" != no &&
19333 cat >>confdefs.h <<\EOF
19334 #define CURSES_WACS_SYMBOLS 1
19339 echo "$as_me:19339: checking for type attr_t in ${cf_cv_ncurses_header:-curses.h}" >&5
19340 echo $ECHO_N "checking for type attr_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
19341 cat >conftest.$ac_ext <<_ACEOF
19342 #line 19342 "configure"
19343 #include "confdefs.h"
19345 #ifndef _XOPEN_SOURCE_EXTENDED
19346 #define _XOPEN_SOURCE_EXTENDED
19348 #include <${cf_cv_ncurses_header:-curses.h}>
19359 rm -f conftest.$ac_objext
19360 if { (eval echo "$as_me:19360: \"$ac_compile\"") >&5
19361 (eval $ac_compile) 2>&5
19363 echo "$as_me:19363: \$? = $ac_status" >&5
19364 (exit $ac_status); } &&
19365 { ac_try='test -s conftest.$ac_objext'
19366 { (eval echo "$as_me:19366: \"$ac_try\"") >&5
19367 (eval $ac_try) 2>&5
19369 echo "$as_me:19369: \$? = $ac_status" >&5
19370 (exit $ac_status); }; }; then
19373 echo "$as_me: failed program was:" >&5
19374 cat conftest.$ac_ext >&5
19377 rm -f conftest.$ac_objext conftest.$ac_ext
19378 echo "$as_me:19378: result: $cf_result" >&5
19379 echo "${ECHO_T}$cf_result" >&6
19380 if test $cf_result = yes ; then
19382 cf_result=`echo "have_type_attr_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
19384 cat >>confdefs.h <<EOF
19385 #define $cf_result 1
19390 cat >>confdefs.h <<EOF
19391 #define attr_t long
19396 if test "$cf_enable_widec" = yes; then
19398 # This is needed on Tru64 5.0 to declare mbstate_t
19399 echo "$as_me:19399: checking if we must include wchar.h to declare mbstate_t" >&5
19400 echo $ECHO_N "checking if we must include wchar.h to declare mbstate_t... $ECHO_C" >&6
19401 if test "${cf_cv_mbstate_t+set}" = set; then
19402 echo $ECHO_N "(cached) $ECHO_C" >&6
19405 cat >conftest.$ac_ext <<_ACEOF
19406 #line 19406 "configure"
19407 #include "confdefs.h"
19409 #include <stdlib.h>
19410 #include <stdarg.h>
19412 #ifdef HAVE_LIBUTF8_H
19413 #include <libutf8.h>
19423 rm -f conftest.$ac_objext
19424 if { (eval echo "$as_me:19424: \"$ac_compile\"") >&5
19425 (eval $ac_compile) 2>&5
19427 echo "$as_me:19427: \$? = $ac_status" >&5
19428 (exit $ac_status); } &&
19429 { ac_try='test -s conftest.$ac_objext'
19430 { (eval echo "$as_me:19430: \"$ac_try\"") >&5
19431 (eval $ac_try) 2>&5
19433 echo "$as_me:19433: \$? = $ac_status" >&5
19434 (exit $ac_status); }; }; then
19437 echo "$as_me: failed program was:" >&5
19438 cat conftest.$ac_ext >&5
19439 cat >conftest.$ac_ext <<_ACEOF
19440 #line 19440 "configure"
19441 #include "confdefs.h"
19443 #include <stdlib.h>
19444 #include <stdarg.h>
19447 #ifdef HAVE_LIBUTF8_H
19448 #include <libutf8.h>
19458 rm -f conftest.$ac_objext
19459 if { (eval echo "$as_me:19459: \"$ac_compile\"") >&5
19460 (eval $ac_compile) 2>&5
19462 echo "$as_me:19462: \$? = $ac_status" >&5
19463 (exit $ac_status); } &&
19464 { ac_try='test -s conftest.$ac_objext'
19465 { (eval echo "$as_me:19465: \"$ac_try\"") >&5
19466 (eval $ac_try) 2>&5
19468 echo "$as_me:19468: \$? = $ac_status" >&5
19469 (exit $ac_status); }; }; then
19470 cf_cv_mbstate_t=yes
19472 echo "$as_me: failed program was:" >&5
19473 cat conftest.$ac_ext >&5
19474 cf_cv_mbstate_t=unknown
19476 rm -f conftest.$ac_objext conftest.$ac_ext
19478 rm -f conftest.$ac_objext conftest.$ac_ext
19480 echo "$as_me:19480: result: $cf_cv_mbstate_t" >&5
19481 echo "${ECHO_T}$cf_cv_mbstate_t" >&6
19483 if test "$cf_cv_mbstate_t" = yes ; then
19485 cat >>confdefs.h <<\EOF
19486 #define NEED_WCHAR_H 1
19492 # if we do not find mbstate_t in either place, use substitution to provide a fallback.
19493 if test "$cf_cv_mbstate_t" = unknown ; then
19494 NCURSES_MBSTATE_T=1
19497 # if we find mbstate_t in either place, use substitution to provide a fallback.
19498 if test "$cf_cv_mbstate_t" != unknown ; then
19499 NCURSES_OK_MBSTATE_T=1
19502 # This is needed on Tru64 5.0 to declare wchar_t
19503 echo "$as_me:19503: checking if we must include wchar.h to declare wchar_t" >&5
19504 echo $ECHO_N "checking if we must include wchar.h to declare wchar_t... $ECHO_C" >&6
19505 if test "${cf_cv_wchar_t+set}" = set; then
19506 echo $ECHO_N "(cached) $ECHO_C" >&6
19509 cat >conftest.$ac_ext <<_ACEOF
19510 #line 19510 "configure"
19511 #include "confdefs.h"
19513 #include <stdlib.h>
19514 #include <stdarg.h>
19516 #ifdef HAVE_LIBUTF8_H
19517 #include <libutf8.h>
19527 rm -f conftest.$ac_objext
19528 if { (eval echo "$as_me:19528: \"$ac_compile\"") >&5
19529 (eval $ac_compile) 2>&5
19531 echo "$as_me:19531: \$? = $ac_status" >&5
19532 (exit $ac_status); } &&
19533 { ac_try='test -s conftest.$ac_objext'
19534 { (eval echo "$as_me:19534: \"$ac_try\"") >&5
19535 (eval $ac_try) 2>&5
19537 echo "$as_me:19537: \$? = $ac_status" >&5
19538 (exit $ac_status); }; }; then
19541 echo "$as_me: failed program was:" >&5
19542 cat conftest.$ac_ext >&5
19543 cat >conftest.$ac_ext <<_ACEOF
19544 #line 19544 "configure"
19545 #include "confdefs.h"
19547 #include <stdlib.h>
19548 #include <stdarg.h>
19551 #ifdef HAVE_LIBUTF8_H
19552 #include <libutf8.h>
19562 rm -f conftest.$ac_objext
19563 if { (eval echo "$as_me:19563: \"$ac_compile\"") >&5
19564 (eval $ac_compile) 2>&5
19566 echo "$as_me:19566: \$? = $ac_status" >&5
19567 (exit $ac_status); } &&
19568 { ac_try='test -s conftest.$ac_objext'
19569 { (eval echo "$as_me:19569: \"$ac_try\"") >&5
19570 (eval $ac_try) 2>&5
19572 echo "$as_me:19572: \$? = $ac_status" >&5
19573 (exit $ac_status); }; }; then
19576 echo "$as_me: failed program was:" >&5
19577 cat conftest.$ac_ext >&5
19578 cf_cv_wchar_t=unknown
19580 rm -f conftest.$ac_objext conftest.$ac_ext
19582 rm -f conftest.$ac_objext conftest.$ac_ext
19584 echo "$as_me:19584: result: $cf_cv_wchar_t" >&5
19585 echo "${ECHO_T}$cf_cv_wchar_t" >&6
19587 if test "$cf_cv_wchar_t" = yes ; then
19589 cat >>confdefs.h <<\EOF
19590 #define NEED_WCHAR_H 1
19596 # if we do not find wchar_t in either place, use substitution to provide a fallback.
19597 if test "$cf_cv_wchar_t" = unknown ; then
19601 # if we find wchar_t in either place, use substitution to provide a fallback.
19602 if test "$cf_cv_wchar_t" != unknown ; then
19603 NCURSES_OK_WCHAR_T=1
19606 # This is needed on Tru64 5.0 to declare wint_t
19607 echo "$as_me:19607: checking if we must include wchar.h to declare wint_t" >&5
19608 echo $ECHO_N "checking if we must include wchar.h to declare wint_t... $ECHO_C" >&6
19609 if test "${cf_cv_wint_t+set}" = set; then
19610 echo $ECHO_N "(cached) $ECHO_C" >&6
19613 cat >conftest.$ac_ext <<_ACEOF
19614 #line 19614 "configure"
19615 #include "confdefs.h"
19617 #include <stdlib.h>
19618 #include <stdarg.h>
19620 #ifdef HAVE_LIBUTF8_H
19621 #include <libutf8.h>
19631 rm -f conftest.$ac_objext
19632 if { (eval echo "$as_me:19632: \"$ac_compile\"") >&5
19633 (eval $ac_compile) 2>&5
19635 echo "$as_me:19635: \$? = $ac_status" >&5
19636 (exit $ac_status); } &&
19637 { ac_try='test -s conftest.$ac_objext'
19638 { (eval echo "$as_me:19638: \"$ac_try\"") >&5
19639 (eval $ac_try) 2>&5
19641 echo "$as_me:19641: \$? = $ac_status" >&5
19642 (exit $ac_status); }; }; then
19645 echo "$as_me: failed program was:" >&5
19646 cat conftest.$ac_ext >&5
19647 cat >conftest.$ac_ext <<_ACEOF
19648 #line 19648 "configure"
19649 #include "confdefs.h"
19651 #include <stdlib.h>
19652 #include <stdarg.h>
19655 #ifdef HAVE_LIBUTF8_H
19656 #include <libutf8.h>
19666 rm -f conftest.$ac_objext
19667 if { (eval echo "$as_me:19667: \"$ac_compile\"") >&5
19668 (eval $ac_compile) 2>&5
19670 echo "$as_me:19670: \$? = $ac_status" >&5
19671 (exit $ac_status); } &&
19672 { ac_try='test -s conftest.$ac_objext'
19673 { (eval echo "$as_me:19673: \"$ac_try\"") >&5
19674 (eval $ac_try) 2>&5
19676 echo "$as_me:19676: \$? = $ac_status" >&5
19677 (exit $ac_status); }; }; then
19680 echo "$as_me: failed program was:" >&5
19681 cat conftest.$ac_ext >&5
19682 cf_cv_wint_t=unknown
19684 rm -f conftest.$ac_objext conftest.$ac_ext
19686 rm -f conftest.$ac_objext conftest.$ac_ext
19688 echo "$as_me:19688: result: $cf_cv_wint_t" >&5
19689 echo "${ECHO_T}$cf_cv_wint_t" >&6
19691 if test "$cf_cv_wint_t" = yes ; then
19693 cat >>confdefs.h <<\EOF
19694 #define NEED_WCHAR_H 1
19700 # if we do not find wint_t in either place, use substitution to provide a fallback.
19701 if test "$cf_cv_wint_t" = unknown ; then
19705 # if we find wint_t in either place, use substitution to provide a fallback.
19706 if test "$cf_cv_wint_t" != unknown ; then
19707 NCURSES_OK_WINT_T=1
19710 if test "$NCURSES_OK_MBSTATE_T" = 0 ; then
19712 echo "$as_me:19712: checking for type mbstate_t in ${cf_cv_ncurses_header:-curses.h}" >&5
19713 echo $ECHO_N "checking for type mbstate_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
19714 cat >conftest.$ac_ext <<_ACEOF
19715 #line 19715 "configure"
19716 #include "confdefs.h"
19718 #ifndef _XOPEN_SOURCE_EXTENDED
19719 #define _XOPEN_SOURCE_EXTENDED
19721 #include <${cf_cv_ncurses_header:-curses.h}>
19732 rm -f conftest.$ac_objext
19733 if { (eval echo "$as_me:19733: \"$ac_compile\"") >&5
19734 (eval $ac_compile) 2>&5
19736 echo "$as_me:19736: \$? = $ac_status" >&5
19737 (exit $ac_status); } &&
19738 { ac_try='test -s conftest.$ac_objext'
19739 { (eval echo "$as_me:19739: \"$ac_try\"") >&5
19740 (eval $ac_try) 2>&5
19742 echo "$as_me:19742: \$? = $ac_status" >&5
19743 (exit $ac_status); }; }; then
19746 echo "$as_me: failed program was:" >&5
19747 cat conftest.$ac_ext >&5
19750 rm -f conftest.$ac_objext conftest.$ac_ext
19751 echo "$as_me:19751: result: $cf_result" >&5
19752 echo "${ECHO_T}$cf_result" >&6
19753 if test $cf_result = yes ; then
19755 cf_result=`echo "have_type_mbstate_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
19757 cat >>confdefs.h <<EOF
19758 #define $cf_result 1
19763 cat >>confdefs.h <<EOF
19764 #define mbstate_t long
19771 if test "$NCURSES_OK_WCHAR_T" = 0 ; then
19773 echo "$as_me:19773: checking for type wchar_t in ${cf_cv_ncurses_header:-curses.h}" >&5
19774 echo $ECHO_N "checking for type wchar_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
19775 cat >conftest.$ac_ext <<_ACEOF
19776 #line 19776 "configure"
19777 #include "confdefs.h"
19779 #ifndef _XOPEN_SOURCE_EXTENDED
19780 #define _XOPEN_SOURCE_EXTENDED
19782 #include <${cf_cv_ncurses_header:-curses.h}>
19793 rm -f conftest.$ac_objext
19794 if { (eval echo "$as_me:19794: \"$ac_compile\"") >&5
19795 (eval $ac_compile) 2>&5
19797 echo "$as_me:19797: \$? = $ac_status" >&5
19798 (exit $ac_status); } &&
19799 { ac_try='test -s conftest.$ac_objext'
19800 { (eval echo "$as_me:19800: \"$ac_try\"") >&5
19801 (eval $ac_try) 2>&5
19803 echo "$as_me:19803: \$? = $ac_status" >&5
19804 (exit $ac_status); }; }; then
19807 echo "$as_me: failed program was:" >&5
19808 cat conftest.$ac_ext >&5
19811 rm -f conftest.$ac_objext conftest.$ac_ext
19812 echo "$as_me:19812: result: $cf_result" >&5
19813 echo "${ECHO_T}$cf_result" >&6
19814 if test $cf_result = yes ; then
19816 cf_result=`echo "have_type_wchar_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
19818 cat >>confdefs.h <<EOF
19819 #define $cf_result 1
19824 cat >>confdefs.h <<EOF
19825 #define wchar_t long
19832 if test "$NCURSES_OK_WINT_T" = 0 ; then
19834 echo "$as_me:19834: checking for type wint_t in ${cf_cv_ncurses_header:-curses.h}" >&5
19835 echo $ECHO_N "checking for type wint_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
19836 cat >conftest.$ac_ext <<_ACEOF
19837 #line 19837 "configure"
19838 #include "confdefs.h"
19840 #ifndef _XOPEN_SOURCE_EXTENDED
19841 #define _XOPEN_SOURCE_EXTENDED
19843 #include <${cf_cv_ncurses_header:-curses.h}>
19854 rm -f conftest.$ac_objext
19855 if { (eval echo "$as_me:19855: \"$ac_compile\"") >&5
19856 (eval $ac_compile) 2>&5
19858 echo "$as_me:19858: \$? = $ac_status" >&5
19859 (exit $ac_status); } &&
19860 { ac_try='test -s conftest.$ac_objext'
19861 { (eval echo "$as_me:19861: \"$ac_try\"") >&5
19862 (eval $ac_try) 2>&5
19864 echo "$as_me:19864: \$? = $ac_status" >&5
19865 (exit $ac_status); }; }; then
19868 echo "$as_me: failed program was:" >&5
19869 cat conftest.$ac_ext >&5
19872 rm -f conftest.$ac_objext conftest.$ac_ext
19873 echo "$as_me:19873: result: $cf_result" >&5
19874 echo "${ECHO_T}$cf_result" >&6
19875 if test $cf_result = yes ; then
19877 cf_result=`echo "have_type_wint_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
19879 cat >>confdefs.h <<EOF
19880 #define $cf_result 1
19885 cat >>confdefs.h <<EOF
19886 #define wint_t long
19902 echo "$as_me:19902: checking for data $cf_data declaration in ${cf_cv_ncurses_header:-curses.h}" >&5
19903 echo $ECHO_N "checking for data $cf_data declaration in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
19905 cat >conftest.$ac_ext <<_ACEOF
19906 #line 19906 "configure"
19907 #include "confdefs.h"
19909 #ifdef HAVE_XCURSES
19910 #include <xcurses.h>
19911 char * XCursesProgramName = "test";
19913 #include <${cf_cv_ncurses_header:-curses.h}>
19914 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
19915 #include <ncursesw/term.h>
19916 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
19917 #include <ncurses/term.h>
19918 #elif defined(HAVE_TERM_H)
19927 #if defined($cf_data) && ((defined(NCURSES_WRAPPED_VAR) && (NCURSES_VERSION_PATCH < 20200208)) || defined(NCURSES_BROKEN_LINKER) || defined(NCURSES_REENTRANT))
19928 const void *foo = (const void *)($cf_data);
19930 const void *foo = &($cf_data);
19932 fprintf(stderr, "testing linkage of $cf_data:%p\n", (const void *)foo);
19938 rm -f conftest.$ac_objext
19939 if { (eval echo "$as_me:19939: \"$ac_compile\"") >&5
19940 (eval $ac_compile) 2>&5
19942 echo "$as_me:19942: \$? = $ac_status" >&5
19943 (exit $ac_status); } &&
19944 { ac_try='test -s conftest.$ac_objext'
19945 { (eval echo "$as_me:19945: \"$ac_try\"") >&5
19946 (eval $ac_try) 2>&5
19948 echo "$as_me:19948: \$? = $ac_status" >&5
19949 (exit $ac_status); }; }; then
19953 echo "$as_me: failed program was:" >&5
19954 cat conftest.$ac_ext >&5
19957 rm -f conftest.$ac_objext conftest.$ac_ext
19958 echo "$as_me:19958: result: $cf_result" >&5
19959 echo "${ECHO_T}$cf_result" >&6
19961 if test $cf_result = yes ; then
19963 cf_result=`echo "have_curses_data_$cf_data" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
19965 cat >>confdefs.h <<EOF
19966 #define $cf_result 1
19970 echo "$as_me:19970: checking for data $cf_data in library" >&5
19971 echo $ECHO_N "checking for data $cf_data in library... $ECHO_C" >&6
19972 # BSD linkers insist on making weak linkage, but resolve at runtime.
19973 if test "$cross_compiling" = yes; then
19976 cat >conftest.$ac_ext <<_ACEOF
19977 #line 19977 "configure"
19978 #include "confdefs.h"
19980 #ifdef HAVE_XCURSES
19981 #include <xcurses.h>
19982 char * XCursesProgramName = "test";
19984 #include <${cf_cv_ncurses_header:-curses.h}>
19985 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
19986 #include <ncursesw/term.h>
19987 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
19988 #include <ncurses/term.h>
19989 #elif defined(HAVE_TERM_H)
19994 extern char $cf_data;
20001 #if defined($cf_data) && ((defined(NCURSES_WRAPPED_VAR) && (NCURSES_VERSION_PATCH < 20200208)) || defined(NCURSES_BROKEN_LINKER) || defined(NCURSES_REENTRANT))
20002 const void *foo = (const void *)($cf_data);
20004 const void *foo = &($cf_data);
20006 fprintf(stderr, "testing linkage of $cf_data:%p\n", (const void *)foo);
20008 ${cf_cv_main_return:-return}(foo == 0);
20015 rm -f conftest.$ac_objext conftest$ac_exeext
20016 if { (eval echo "$as_me:20016: \"$ac_link\"") >&5
20017 (eval $ac_link) 2>&5
20019 echo "$as_me:20019: \$? = $ac_status" >&5
20020 (exit $ac_status); } &&
20021 { ac_try='test -s conftest$ac_exeext'
20022 { (eval echo "$as_me:20022: \"$ac_try\"") >&5
20023 (eval $ac_try) 2>&5
20025 echo "$as_me:20025: \$? = $ac_status" >&5
20026 (exit $ac_status); }; }; then
20029 echo "$as_me: failed program was:" >&5
20030 cat conftest.$ac_ext >&5
20033 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20036 cat >conftest.$ac_ext <<_ACEOF
20037 #line 20037 "configure"
20038 #include "confdefs.h"
20040 #ifdef HAVE_XCURSES
20041 #include <xcurses.h>
20042 char * XCursesProgramName = "test";
20044 #include <${cf_cv_ncurses_header:-curses.h}>
20045 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
20046 #include <ncursesw/term.h>
20047 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
20048 #include <ncurses/term.h>
20049 #elif defined(HAVE_TERM_H)
20054 extern char $cf_data;
20058 #if defined($cf_data) && ((defined(NCURSES_WRAPPED_VAR) && (NCURSES_VERSION_PATCH < 20200208)) || defined(NCURSES_BROKEN_LINKER) || defined(NCURSES_REENTRANT))
20059 const void *foo = (const void *)($cf_data);
20061 const void *foo = &($cf_data);
20063 fprintf(stderr, "testing linkage of $cf_data:%p\n", (const void *)foo);
20065 ${cf_cv_main_return:-return}(foo == 0);
20068 rm -f conftest$ac_exeext
20069 if { (eval echo "$as_me:20069: \"$ac_link\"") >&5
20070 (eval $ac_link) 2>&5
20072 echo "$as_me:20072: \$? = $ac_status" >&5
20073 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20074 { (eval echo "$as_me:20074: \"$ac_try\"") >&5
20075 (eval $ac_try) 2>&5
20077 echo "$as_me:20077: \$? = $ac_status" >&5
20078 (exit $ac_status); }; }; then
20082 echo "$as_me: program exited with status $ac_status" >&5
20083 echo "$as_me: failed program was:" >&5
20084 cat conftest.$ac_ext >&5
20087 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20089 echo "$as_me:20089: result: $cf_result" >&5
20090 echo "${ECHO_T}$cf_result" >&6
20091 if test $cf_result = yes ; then
20093 cf_result=`echo "decl_curses_data_$cf_data" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
20095 cat >>confdefs.h <<EOF
20096 #define $cf_result 1
20099 # do not exit loop here, since we prefer system's declarations
20104 if test -n "$with_screen" && test "x$with_screen" = "xpdcurses"
20106 echo "$as_me:20106: checking for X" >&5
20107 echo $ECHO_N "checking for X... $ECHO_C" >&6
20109 # Check whether --with-x or --without-x was given.
20110 if test "${with_x+set}" = set; then
20114 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
20115 if test "x$with_x" = xno; then
20116 # The user explicitly disabled X.
20119 if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
20120 # Both variables are already set.
20123 if test "${ac_cv_have_x+set}" = set; then
20124 echo $ECHO_N "(cached) $ECHO_C" >&6
20126 # One or both of the vars are not set, and there is no cached value.
20127 ac_x_includes=no ac_x_libraries=no
20128 rm -fr conftest.dir
20129 if mkdir conftest.dir; then
20131 # Make sure to not put "make" in the Imakefile rules, since we grep it out.
20132 cat >Imakefile <<'EOF'
20134 @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
20136 if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
20137 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
20138 eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
20139 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
20140 for ac_extension in a so sl dylib dll; do
20141 if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
20142 test -f $ac_im_libdir/libX11.$ac_extension; then
20143 ac_im_usrlibdir=$ac_im_libdir; break
20146 # Screen out bogus values from the imake configuration. They are
20147 # bogus both because they are the default anyway, and because
20148 # using them would break gcc on systems where it needs fixed includes.
20149 case $ac_im_incroot in
20151 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
20153 case $ac_im_usrlibdir in
20154 /usr/lib | /lib) ;;
20155 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
20159 rm -fr conftest.dir
20162 # Standard set of common directories for X headers.
20163 # Check X11 before X11Rn because it is often a symlink to the current release.
20180 /usr/local/X11/include
20181 /usr/local/X11R7/include
20182 /usr/local/X11R6/include
20183 /usr/local/X11R5/include
20184 /usr/local/X11R4/include
20186 /usr/local/include/X11
20187 /usr/local/include/X11R7
20188 /usr/local/include/X11R6
20189 /usr/local/include/X11R5
20190 /usr/local/include/X11R4
20194 /usr/XFree86/include/X11
20198 /usr/unsupported/include
20199 /usr/athena/include
20200 /usr/local/x11r5/include
20201 /usr/lpp/Xamples/include
20203 /usr/openwin/include
20204 /usr/openwin/share/include'
20206 if test "$ac_x_includes" = no; then
20207 # Guess where to find include files, by looking for Intrinsic.h.
20208 # First, try using that file with no special directory specified.
20209 cat >conftest.$ac_ext <<_ACEOF
20210 #line 20210 "configure"
20211 #include "confdefs.h"
20212 #include <X11/Intrinsic.h>
20214 if { (eval echo "$as_me:20214: \"$ac_cpp conftest.$ac_ext\"") >&5
20215 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
20217 egrep -v '^ *\+' conftest.er1 >conftest.err
20219 cat conftest.err >&5
20220 echo "$as_me:20220: \$? = $ac_status" >&5
20221 (exit $ac_status); } >/dev/null; then
20222 if test -s conftest.err; then
20223 ac_cpp_err=$ac_c_preproc_warn_flag
20230 if test -z "$ac_cpp_err"; then
20231 # We can compile using X headers with no special include directory.
20234 echo "$as_me: failed program was:" >&5
20235 cat conftest.$ac_ext >&5
20236 for ac_dir in $ac_x_header_dirs; do
20237 if test -r "$ac_dir/X11/Intrinsic.h"; then
20238 ac_x_includes=$ac_dir
20243 rm -f conftest.err conftest.$ac_ext
20244 fi # $ac_x_includes = no
20246 if test "$ac_x_libraries" = no; then
20247 # Check for the libraries.
20248 # See if we find them without any special options.
20249 # Don't add to $LIBS permanently.
20252 cat >conftest.$ac_ext <<_ACEOF
20253 #line 20253 "configure"
20254 #include "confdefs.h"
20255 #include <X11/Intrinsic.h>
20264 rm -f conftest.$ac_objext conftest$ac_exeext
20265 if { (eval echo "$as_me:20265: \"$ac_link\"") >&5
20266 (eval $ac_link) 2>&5
20268 echo "$as_me:20268: \$? = $ac_status" >&5
20269 (exit $ac_status); } &&
20270 { ac_try='test -s conftest$ac_exeext'
20271 { (eval echo "$as_me:20271: \"$ac_try\"") >&5
20272 (eval $ac_try) 2>&5
20274 echo "$as_me:20274: \$? = $ac_status" >&5
20275 (exit $ac_status); }; }; then
20277 # We can link X programs with no special library path.
20280 echo "$as_me: failed program was:" >&5
20281 cat conftest.$ac_ext >&5
20283 for ac_dir in `echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
20285 # Don't even attempt the hair of trying to link an X program!
20286 for ac_extension in a so sl dylib dll; do
20287 if test -r $ac_dir/libXt.$ac_extension; then
20288 ac_x_libraries=$ac_dir
20294 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20295 fi # $ac_x_libraries = no
20297 if test "$ac_x_includes" = no || test "$ac_x_libraries" = no; then
20298 # Didn't find X anywhere. Cache the known absence of X.
20299 ac_cv_have_x="have_x=no"
20301 # Record where we found X for the cache.
20302 ac_cv_have_x="have_x=yes \
20303 ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
20308 eval "$ac_cv_have_x"
20311 if test "$have_x" != yes; then
20312 echo "$as_me:20312: result: $have_x" >&5
20313 echo "${ECHO_T}$have_x" >&6
20316 # If each of the values was on the command line, it overrides each guess.
20317 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
20318 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
20319 # Update the cache value to reflect the command line values.
20320 ac_cv_have_x="have_x=yes \
20321 ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
20322 echo "$as_me:20322: result: libraries $x_libraries, headers $x_includes" >&5
20323 echo "${ECHO_T}libraries $x_libraries, headers $x_includes" >&6
20326 if test "$no_x" = yes; then
20327 # Not all programs may use this symbol, but it does not hurt to define it.
20329 cat >>confdefs.h <<\EOF
20330 #define X_DISPLAY_MISSING 1
20333 X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS=
20335 if test -n "$x_includes"; then
20336 X_CFLAGS="$X_CFLAGS -I$x_includes"
20339 # It would also be nice to do this for all -L options, not just this one.
20340 if test -n "$x_libraries"; then
20341 X_LIBS="$X_LIBS -L$x_libraries"
20342 # For Solaris; some versions of Sun CC require a space after -R and
20343 # others require no space. Words are not sufficient . . . .
20344 case `(uname -sr) 2>/dev/null` in
20346 echo "$as_me:20346: checking whether -R must be followed by a space" >&5
20347 echo $ECHO_N "checking whether -R must be followed by a space... $ECHO_C" >&6
20348 ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries"
20349 cat >conftest.$ac_ext <<_ACEOF
20350 #line 20350 "configure"
20351 #include "confdefs.h"
20361 rm -f conftest.$ac_objext conftest$ac_exeext
20362 if { (eval echo "$as_me:20362: \"$ac_link\"") >&5
20363 (eval $ac_link) 2>&5
20365 echo "$as_me:20365: \$? = $ac_status" >&5
20366 (exit $ac_status); } &&
20367 { ac_try='test -s conftest$ac_exeext'
20368 { (eval echo "$as_me:20368: \"$ac_try\"") >&5
20369 (eval $ac_try) 2>&5
20371 echo "$as_me:20371: \$? = $ac_status" >&5
20372 (exit $ac_status); }; }; then
20375 echo "$as_me: failed program was:" >&5
20376 cat conftest.$ac_ext >&5
20379 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20380 if test $ac_R_nospace = yes; then
20381 echo "$as_me:20381: result: no" >&5
20382 echo "${ECHO_T}no" >&6
20383 X_LIBS="$X_LIBS -R$x_libraries"
20385 LIBS="$ac_xsave_LIBS -R $x_libraries"
20386 cat >conftest.$ac_ext <<_ACEOF
20387 #line 20387 "configure"
20388 #include "confdefs.h"
20398 rm -f conftest.$ac_objext conftest$ac_exeext
20399 if { (eval echo "$as_me:20399: \"$ac_link\"") >&5
20400 (eval $ac_link) 2>&5
20402 echo "$as_me:20402: \$? = $ac_status" >&5
20403 (exit $ac_status); } &&
20404 { ac_try='test -s conftest$ac_exeext'
20405 { (eval echo "$as_me:20405: \"$ac_try\"") >&5
20406 (eval $ac_try) 2>&5
20408 echo "$as_me:20408: \$? = $ac_status" >&5
20409 (exit $ac_status); }; }; then
20412 echo "$as_me: failed program was:" >&5
20413 cat conftest.$ac_ext >&5
20416 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20417 if test $ac_R_space = yes; then
20418 echo "$as_me:20418: result: yes" >&5
20419 echo "${ECHO_T}yes" >&6
20420 X_LIBS="$X_LIBS -R $x_libraries"
20422 echo "$as_me:20422: result: neither works" >&5
20423 echo "${ECHO_T}neither works" >&6
20426 LIBS=$ac_xsave_LIBS
20430 # Check for system-dependent libraries X programs must link with.
20431 # Do this before checking for the system-independent R6 libraries
20432 # (-lICE), since we may need -lsocket or whatever for X linking.
20434 if test "$ISC" = yes; then
20435 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
20437 # Martyn Johnson says this is needed for Ultrix, if the X
20438 # libraries were built with DECnet support. And Karl Berry says
20439 # the Alpha needs dnet_stub (dnet does not exist).
20440 ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11"
20441 cat >conftest.$ac_ext <<_ACEOF
20442 #line 20442 "configure"
20443 #include "confdefs.h"
20445 /* Override any gcc2 internal prototype to avoid an error. */
20449 /* We use char because int might match the return type of a gcc2
20450 builtin and then its argument prototype would still apply. */
20451 char XOpenDisplay ();
20460 rm -f conftest.$ac_objext conftest$ac_exeext
20461 if { (eval echo "$as_me:20461: \"$ac_link\"") >&5
20462 (eval $ac_link) 2>&5
20464 echo "$as_me:20464: \$? = $ac_status" >&5
20465 (exit $ac_status); } &&
20466 { ac_try='test -s conftest$ac_exeext'
20467 { (eval echo "$as_me:20467: \"$ac_try\"") >&5
20468 (eval $ac_try) 2>&5
20470 echo "$as_me:20470: \$? = $ac_status" >&5
20471 (exit $ac_status); }; }; then
20474 echo "$as_me: failed program was:" >&5
20475 cat conftest.$ac_ext >&5
20476 echo "$as_me:20476: checking for dnet_ntoa in -ldnet" >&5
20477 echo $ECHO_N "checking for dnet_ntoa in -ldnet... $ECHO_C" >&6
20478 if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then
20479 echo $ECHO_N "(cached) $ECHO_C" >&6
20481 ac_check_lib_save_LIBS=$LIBS
20482 LIBS="-ldnet $LIBS"
20483 cat >conftest.$ac_ext <<_ACEOF
20484 #line 20484 "configure"
20485 #include "confdefs.h"
20487 /* Override any gcc2 internal prototype to avoid an error. */
20491 /* We use char because int might match the return type of a gcc2
20492 builtin and then its argument prototype would still apply. */
20502 rm -f conftest.$ac_objext conftest$ac_exeext
20503 if { (eval echo "$as_me:20503: \"$ac_link\"") >&5
20504 (eval $ac_link) 2>&5
20506 echo "$as_me:20506: \$? = $ac_status" >&5
20507 (exit $ac_status); } &&
20508 { ac_try='test -s conftest$ac_exeext'
20509 { (eval echo "$as_me:20509: \"$ac_try\"") >&5
20510 (eval $ac_try) 2>&5
20512 echo "$as_me:20512: \$? = $ac_status" >&5
20513 (exit $ac_status); }; }; then
20514 ac_cv_lib_dnet_dnet_ntoa=yes
20516 echo "$as_me: failed program was:" >&5
20517 cat conftest.$ac_ext >&5
20518 ac_cv_lib_dnet_dnet_ntoa=no
20520 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20521 LIBS=$ac_check_lib_save_LIBS
20523 echo "$as_me:20523: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
20524 echo "${ECHO_T}$ac_cv_lib_dnet_dnet_ntoa" >&6
20525 if test $ac_cv_lib_dnet_dnet_ntoa = yes; then
20526 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
20529 if test $ac_cv_lib_dnet_dnet_ntoa = no; then
20530 echo "$as_me:20530: checking for dnet_ntoa in -ldnet_stub" >&5
20531 echo $ECHO_N "checking for dnet_ntoa in -ldnet_stub... $ECHO_C" >&6
20532 if test "${ac_cv_lib_dnet_stub_dnet_ntoa+set}" = set; then
20533 echo $ECHO_N "(cached) $ECHO_C" >&6
20535 ac_check_lib_save_LIBS=$LIBS
20536 LIBS="-ldnet_stub $LIBS"
20537 cat >conftest.$ac_ext <<_ACEOF
20538 #line 20538 "configure"
20539 #include "confdefs.h"
20541 /* Override any gcc2 internal prototype to avoid an error. */
20545 /* We use char because int might match the return type of a gcc2
20546 builtin and then its argument prototype would still apply. */
20556 rm -f conftest.$ac_objext conftest$ac_exeext
20557 if { (eval echo "$as_me:20557: \"$ac_link\"") >&5
20558 (eval $ac_link) 2>&5
20560 echo "$as_me:20560: \$? = $ac_status" >&5
20561 (exit $ac_status); } &&
20562 { ac_try='test -s conftest$ac_exeext'
20563 { (eval echo "$as_me:20563: \"$ac_try\"") >&5
20564 (eval $ac_try) 2>&5
20566 echo "$as_me:20566: \$? = $ac_status" >&5
20567 (exit $ac_status); }; }; then
20568 ac_cv_lib_dnet_stub_dnet_ntoa=yes
20570 echo "$as_me: failed program was:" >&5
20571 cat conftest.$ac_ext >&5
20572 ac_cv_lib_dnet_stub_dnet_ntoa=no
20574 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20575 LIBS=$ac_check_lib_save_LIBS
20577 echo "$as_me:20577: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5
20578 echo "${ECHO_T}$ac_cv_lib_dnet_stub_dnet_ntoa" >&6
20579 if test $ac_cv_lib_dnet_stub_dnet_ntoa = yes; then
20580 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
20585 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20586 LIBS="$ac_xsave_LIBS"
20588 # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT,
20589 # to get the SysV transport functions.
20590 # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4)
20592 # The nsl library prevents programs from opening the X display
20593 # on Irix 5.2, according to T.E. Dickey.
20594 # The functions gethostbyname, getservbyname, and inet_addr are
20595 # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking.
20596 echo "$as_me:20596: checking for gethostbyname" >&5
20597 echo $ECHO_N "checking for gethostbyname... $ECHO_C" >&6
20598 if test "${ac_cv_func_gethostbyname+set}" = set; then
20599 echo $ECHO_N "(cached) $ECHO_C" >&6
20601 cat >conftest.$ac_ext <<_ACEOF
20602 #line 20602 "configure"
20603 #include "confdefs.h"
20604 #define gethostbyname autoconf_temporary
20605 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
20606 #undef gethostbyname
20612 /* We use char because int might match the return type of a gcc2
20613 builtin and then its argument prototype would still apply. */
20614 char gethostbyname (void);
20620 /* The GNU C library defines stubs for functions which it implements
20621 to always fail with ENOSYS. Some functions are actually named
20622 something starting with __ and the normal name is an alias. */
20623 #if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
20624 #error found stub for gethostbyname
20627 return gethostbyname ();
20632 rm -f conftest.$ac_objext conftest$ac_exeext
20633 if { (eval echo "$as_me:20633: \"$ac_link\"") >&5
20634 (eval $ac_link) 2>&5
20636 echo "$as_me:20636: \$? = $ac_status" >&5
20637 (exit $ac_status); } &&
20638 { ac_try='test -s conftest$ac_exeext'
20639 { (eval echo "$as_me:20639: \"$ac_try\"") >&5
20640 (eval $ac_try) 2>&5
20642 echo "$as_me:20642: \$? = $ac_status" >&5
20643 (exit $ac_status); }; }; then
20644 ac_cv_func_gethostbyname=yes
20646 echo "$as_me: failed program was:" >&5
20647 cat conftest.$ac_ext >&5
20648 ac_cv_func_gethostbyname=no
20650 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20652 echo "$as_me:20652: result: $ac_cv_func_gethostbyname" >&5
20653 echo "${ECHO_T}$ac_cv_func_gethostbyname" >&6
20655 if test $ac_cv_func_gethostbyname = no; then
20656 echo "$as_me:20656: checking for gethostbyname in -lnsl" >&5
20657 echo $ECHO_N "checking for gethostbyname in -lnsl... $ECHO_C" >&6
20658 if test "${ac_cv_lib_nsl_gethostbyname+set}" = set; then
20659 echo $ECHO_N "(cached) $ECHO_C" >&6
20661 ac_check_lib_save_LIBS=$LIBS
20663 cat >conftest.$ac_ext <<_ACEOF
20664 #line 20664 "configure"
20665 #include "confdefs.h"
20667 /* Override any gcc2 internal prototype to avoid an error. */
20671 /* We use char because int might match the return type of a gcc2
20672 builtin and then its argument prototype would still apply. */
20673 char gethostbyname ();
20682 rm -f conftest.$ac_objext conftest$ac_exeext
20683 if { (eval echo "$as_me:20683: \"$ac_link\"") >&5
20684 (eval $ac_link) 2>&5
20686 echo "$as_me:20686: \$? = $ac_status" >&5
20687 (exit $ac_status); } &&
20688 { ac_try='test -s conftest$ac_exeext'
20689 { (eval echo "$as_me:20689: \"$ac_try\"") >&5
20690 (eval $ac_try) 2>&5
20692 echo "$as_me:20692: \$? = $ac_status" >&5
20693 (exit $ac_status); }; }; then
20694 ac_cv_lib_nsl_gethostbyname=yes
20696 echo "$as_me: failed program was:" >&5
20697 cat conftest.$ac_ext >&5
20698 ac_cv_lib_nsl_gethostbyname=no
20700 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20701 LIBS=$ac_check_lib_save_LIBS
20703 echo "$as_me:20703: result: $ac_cv_lib_nsl_gethostbyname" >&5
20704 echo "${ECHO_T}$ac_cv_lib_nsl_gethostbyname" >&6
20705 if test $ac_cv_lib_nsl_gethostbyname = yes; then
20706 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
20709 if test $ac_cv_lib_nsl_gethostbyname = no; then
20710 echo "$as_me:20710: checking for gethostbyname in -lbsd" >&5
20711 echo $ECHO_N "checking for gethostbyname in -lbsd... $ECHO_C" >&6
20712 if test "${ac_cv_lib_bsd_gethostbyname+set}" = set; then
20713 echo $ECHO_N "(cached) $ECHO_C" >&6
20715 ac_check_lib_save_LIBS=$LIBS
20717 cat >conftest.$ac_ext <<_ACEOF
20718 #line 20718 "configure"
20719 #include "confdefs.h"
20721 /* Override any gcc2 internal prototype to avoid an error. */
20725 /* We use char because int might match the return type of a gcc2
20726 builtin and then its argument prototype would still apply. */
20727 char gethostbyname ();
20736 rm -f conftest.$ac_objext conftest$ac_exeext
20737 if { (eval echo "$as_me:20737: \"$ac_link\"") >&5
20738 (eval $ac_link) 2>&5
20740 echo "$as_me:20740: \$? = $ac_status" >&5
20741 (exit $ac_status); } &&
20742 { ac_try='test -s conftest$ac_exeext'
20743 { (eval echo "$as_me:20743: \"$ac_try\"") >&5
20744 (eval $ac_try) 2>&5
20746 echo "$as_me:20746: \$? = $ac_status" >&5
20747 (exit $ac_status); }; }; then
20748 ac_cv_lib_bsd_gethostbyname=yes
20750 echo "$as_me: failed program was:" >&5
20751 cat conftest.$ac_ext >&5
20752 ac_cv_lib_bsd_gethostbyname=no
20754 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20755 LIBS=$ac_check_lib_save_LIBS
20757 echo "$as_me:20757: result: $ac_cv_lib_bsd_gethostbyname" >&5
20758 echo "${ECHO_T}$ac_cv_lib_bsd_gethostbyname" >&6
20759 if test $ac_cv_lib_bsd_gethostbyname = yes; then
20760 X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd"
20766 # lieder@skyler.mavd.honeywell.com says without -lsocket,
20767 # socket/setsockopt and other routines are undefined under SCO ODT
20768 # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary
20769 # on later versions), says Simon Leinen: it contains gethostby*
20770 # variants that don't use the nameserver (or something). -lsocket
20771 # must be given before -lnsl if both are needed. We assume that
20772 # if connect needs -lnsl, so does gethostbyname.
20773 echo "$as_me:20773: checking for connect" >&5
20774 echo $ECHO_N "checking for connect... $ECHO_C" >&6
20775 if test "${ac_cv_func_connect+set}" = set; then
20776 echo $ECHO_N "(cached) $ECHO_C" >&6
20778 cat >conftest.$ac_ext <<_ACEOF
20779 #line 20779 "configure"
20780 #include "confdefs.h"
20781 #define connect autoconf_temporary
20782 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
20789 /* We use char because int might match the return type of a gcc2
20790 builtin and then its argument prototype would still apply. */
20791 char connect (void);
20797 /* The GNU C library defines stubs for functions which it implements
20798 to always fail with ENOSYS. Some functions are actually named
20799 something starting with __ and the normal name is an alias. */
20800 #if defined (__stub_connect) || defined (__stub___connect)
20801 #error found stub for connect
20809 rm -f conftest.$ac_objext conftest$ac_exeext
20810 if { (eval echo "$as_me:20810: \"$ac_link\"") >&5
20811 (eval $ac_link) 2>&5
20813 echo "$as_me:20813: \$? = $ac_status" >&5
20814 (exit $ac_status); } &&
20815 { ac_try='test -s conftest$ac_exeext'
20816 { (eval echo "$as_me:20816: \"$ac_try\"") >&5
20817 (eval $ac_try) 2>&5
20819 echo "$as_me:20819: \$? = $ac_status" >&5
20820 (exit $ac_status); }; }; then
20821 ac_cv_func_connect=yes
20823 echo "$as_me: failed program was:" >&5
20824 cat conftest.$ac_ext >&5
20825 ac_cv_func_connect=no
20827 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20829 echo "$as_me:20829: result: $ac_cv_func_connect" >&5
20830 echo "${ECHO_T}$ac_cv_func_connect" >&6
20832 if test $ac_cv_func_connect = no; then
20833 echo "$as_me:20833: checking for connect in -lsocket" >&5
20834 echo $ECHO_N "checking for connect in -lsocket... $ECHO_C" >&6
20835 if test "${ac_cv_lib_socket_connect+set}" = set; then
20836 echo $ECHO_N "(cached) $ECHO_C" >&6
20838 ac_check_lib_save_LIBS=$LIBS
20839 LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
20840 cat >conftest.$ac_ext <<_ACEOF
20841 #line 20841 "configure"
20842 #include "confdefs.h"
20844 /* Override any gcc2 internal prototype to avoid an error. */
20848 /* We use char because int might match the return type of a gcc2
20849 builtin and then its argument prototype would still apply. */
20859 rm -f conftest.$ac_objext conftest$ac_exeext
20860 if { (eval echo "$as_me:20860: \"$ac_link\"") >&5
20861 (eval $ac_link) 2>&5
20863 echo "$as_me:20863: \$? = $ac_status" >&5
20864 (exit $ac_status); } &&
20865 { ac_try='test -s conftest$ac_exeext'
20866 { (eval echo "$as_me:20866: \"$ac_try\"") >&5
20867 (eval $ac_try) 2>&5
20869 echo "$as_me:20869: \$? = $ac_status" >&5
20870 (exit $ac_status); }; }; then
20871 ac_cv_lib_socket_connect=yes
20873 echo "$as_me: failed program was:" >&5
20874 cat conftest.$ac_ext >&5
20875 ac_cv_lib_socket_connect=no
20877 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20878 LIBS=$ac_check_lib_save_LIBS
20880 echo "$as_me:20880: result: $ac_cv_lib_socket_connect" >&5
20881 echo "${ECHO_T}$ac_cv_lib_socket_connect" >&6
20882 if test $ac_cv_lib_socket_connect = yes; then
20883 X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS"
20888 # Guillermo Gomez says -lposix is necessary on A/UX.
20889 echo "$as_me:20889: checking for remove" >&5
20890 echo $ECHO_N "checking for remove... $ECHO_C" >&6
20891 if test "${ac_cv_func_remove+set}" = set; then
20892 echo $ECHO_N "(cached) $ECHO_C" >&6
20894 cat >conftest.$ac_ext <<_ACEOF
20895 #line 20895 "configure"
20896 #include "confdefs.h"
20897 #define remove autoconf_temporary
20898 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
20905 /* We use char because int might match the return type of a gcc2
20906 builtin and then its argument prototype would still apply. */
20907 char remove (void);
20913 /* The GNU C library defines stubs for functions which it implements
20914 to always fail with ENOSYS. Some functions are actually named
20915 something starting with __ and the normal name is an alias. */
20916 #if defined (__stub_remove) || defined (__stub___remove)
20917 #error found stub for remove
20925 rm -f conftest.$ac_objext conftest$ac_exeext
20926 if { (eval echo "$as_me:20926: \"$ac_link\"") >&5
20927 (eval $ac_link) 2>&5
20929 echo "$as_me:20929: \$? = $ac_status" >&5
20930 (exit $ac_status); } &&
20931 { ac_try='test -s conftest$ac_exeext'
20932 { (eval echo "$as_me:20932: \"$ac_try\"") >&5
20933 (eval $ac_try) 2>&5
20935 echo "$as_me:20935: \$? = $ac_status" >&5
20936 (exit $ac_status); }; }; then
20937 ac_cv_func_remove=yes
20939 echo "$as_me: failed program was:" >&5
20940 cat conftest.$ac_ext >&5
20941 ac_cv_func_remove=no
20943 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20945 echo "$as_me:20945: result: $ac_cv_func_remove" >&5
20946 echo "${ECHO_T}$ac_cv_func_remove" >&6
20948 if test $ac_cv_func_remove = no; then
20949 echo "$as_me:20949: checking for remove in -lposix" >&5
20950 echo $ECHO_N "checking for remove in -lposix... $ECHO_C" >&6
20951 if test "${ac_cv_lib_posix_remove+set}" = set; then
20952 echo $ECHO_N "(cached) $ECHO_C" >&6
20954 ac_check_lib_save_LIBS=$LIBS
20955 LIBS="-lposix $LIBS"
20956 cat >conftest.$ac_ext <<_ACEOF
20957 #line 20957 "configure"
20958 #include "confdefs.h"
20960 /* Override any gcc2 internal prototype to avoid an error. */
20964 /* We use char because int might match the return type of a gcc2
20965 builtin and then its argument prototype would still apply. */
20975 rm -f conftest.$ac_objext conftest$ac_exeext
20976 if { (eval echo "$as_me:20976: \"$ac_link\"") >&5
20977 (eval $ac_link) 2>&5
20979 echo "$as_me:20979: \$? = $ac_status" >&5
20980 (exit $ac_status); } &&
20981 { ac_try='test -s conftest$ac_exeext'
20982 { (eval echo "$as_me:20982: \"$ac_try\"") >&5
20983 (eval $ac_try) 2>&5
20985 echo "$as_me:20985: \$? = $ac_status" >&5
20986 (exit $ac_status); }; }; then
20987 ac_cv_lib_posix_remove=yes
20989 echo "$as_me: failed program was:" >&5
20990 cat conftest.$ac_ext >&5
20991 ac_cv_lib_posix_remove=no
20993 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20994 LIBS=$ac_check_lib_save_LIBS
20996 echo "$as_me:20996: result: $ac_cv_lib_posix_remove" >&5
20997 echo "${ECHO_T}$ac_cv_lib_posix_remove" >&6
20998 if test $ac_cv_lib_posix_remove = yes; then
20999 X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix"
21004 # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
21005 echo "$as_me:21005: checking for shmat" >&5
21006 echo $ECHO_N "checking for shmat... $ECHO_C" >&6
21007 if test "${ac_cv_func_shmat+set}" = set; then
21008 echo $ECHO_N "(cached) $ECHO_C" >&6
21010 cat >conftest.$ac_ext <<_ACEOF
21011 #line 21011 "configure"
21012 #include "confdefs.h"
21013 #define shmat autoconf_temporary
21014 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
21021 /* We use char because int might match the return type of a gcc2
21022 builtin and then its argument prototype would still apply. */
21029 /* The GNU C library defines stubs for functions which it implements
21030 to always fail with ENOSYS. Some functions are actually named
21031 something starting with __ and the normal name is an alias. */
21032 #if defined (__stub_shmat) || defined (__stub___shmat)
21033 #error found stub for shmat
21041 rm -f conftest.$ac_objext conftest$ac_exeext
21042 if { (eval echo "$as_me:21042: \"$ac_link\"") >&5
21043 (eval $ac_link) 2>&5
21045 echo "$as_me:21045: \$? = $ac_status" >&5
21046 (exit $ac_status); } &&
21047 { ac_try='test -s conftest$ac_exeext'
21048 { (eval echo "$as_me:21048: \"$ac_try\"") >&5
21049 (eval $ac_try) 2>&5
21051 echo "$as_me:21051: \$? = $ac_status" >&5
21052 (exit $ac_status); }; }; then
21053 ac_cv_func_shmat=yes
21055 echo "$as_me: failed program was:" >&5
21056 cat conftest.$ac_ext >&5
21057 ac_cv_func_shmat=no
21059 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
21061 echo "$as_me:21061: result: $ac_cv_func_shmat" >&5
21062 echo "${ECHO_T}$ac_cv_func_shmat" >&6
21064 if test $ac_cv_func_shmat = no; then
21065 echo "$as_me:21065: checking for shmat in -lipc" >&5
21066 echo $ECHO_N "checking for shmat in -lipc... $ECHO_C" >&6
21067 if test "${ac_cv_lib_ipc_shmat+set}" = set; then
21068 echo $ECHO_N "(cached) $ECHO_C" >&6
21070 ac_check_lib_save_LIBS=$LIBS
21072 cat >conftest.$ac_ext <<_ACEOF
21073 #line 21073 "configure"
21074 #include "confdefs.h"
21076 /* Override any gcc2 internal prototype to avoid an error. */
21080 /* We use char because int might match the return type of a gcc2
21081 builtin and then its argument prototype would still apply. */
21091 rm -f conftest.$ac_objext conftest$ac_exeext
21092 if { (eval echo "$as_me:21092: \"$ac_link\"") >&5
21093 (eval $ac_link) 2>&5
21095 echo "$as_me:21095: \$? = $ac_status" >&5
21096 (exit $ac_status); } &&
21097 { ac_try='test -s conftest$ac_exeext'
21098 { (eval echo "$as_me:21098: \"$ac_try\"") >&5
21099 (eval $ac_try) 2>&5
21101 echo "$as_me:21101: \$? = $ac_status" >&5
21102 (exit $ac_status); }; }; then
21103 ac_cv_lib_ipc_shmat=yes
21105 echo "$as_me: failed program was:" >&5
21106 cat conftest.$ac_ext >&5
21107 ac_cv_lib_ipc_shmat=no
21109 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
21110 LIBS=$ac_check_lib_save_LIBS
21112 echo "$as_me:21112: result: $ac_cv_lib_ipc_shmat" >&5
21113 echo "${ECHO_T}$ac_cv_lib_ipc_shmat" >&6
21114 if test $ac_cv_lib_ipc_shmat = yes; then
21115 X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc"
21121 # Check for libraries that X11R6 Xt/Xaw programs need.
21122 ac_save_LDFLAGS=$LDFLAGS
21123 test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries"
21124 # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
21125 # check for ICE first), but we must link in the order -lSM -lICE or
21126 # we get undefined symbols. So assume we have SM if we have ICE.
21127 # These have to be linked with before -lX11, unlike the other
21128 # libraries we check for below, so use a different variable.
21129 # John Interrante, Karl Berry
21130 echo "$as_me:21130: checking for IceConnectionNumber in -lICE" >&5
21131 echo $ECHO_N "checking for IceConnectionNumber in -lICE... $ECHO_C" >&6
21132 if test "${ac_cv_lib_ICE_IceConnectionNumber+set}" = set; then
21133 echo $ECHO_N "(cached) $ECHO_C" >&6
21135 ac_check_lib_save_LIBS=$LIBS
21136 LIBS="-lICE $X_EXTRA_LIBS $LIBS"
21137 cat >conftest.$ac_ext <<_ACEOF
21138 #line 21138 "configure"
21139 #include "confdefs.h"
21141 /* Override any gcc2 internal prototype to avoid an error. */
21145 /* We use char because int might match the return type of a gcc2
21146 builtin and then its argument prototype would still apply. */
21147 char IceConnectionNumber ();
21151 IceConnectionNumber ();
21156 rm -f conftest.$ac_objext conftest$ac_exeext
21157 if { (eval echo "$as_me:21157: \"$ac_link\"") >&5
21158 (eval $ac_link) 2>&5
21160 echo "$as_me:21160: \$? = $ac_status" >&5
21161 (exit $ac_status); } &&
21162 { ac_try='test -s conftest$ac_exeext'
21163 { (eval echo "$as_me:21163: \"$ac_try\"") >&5
21164 (eval $ac_try) 2>&5
21166 echo "$as_me:21166: \$? = $ac_status" >&5
21167 (exit $ac_status); }; }; then
21168 ac_cv_lib_ICE_IceConnectionNumber=yes
21170 echo "$as_me: failed program was:" >&5
21171 cat conftest.$ac_ext >&5
21172 ac_cv_lib_ICE_IceConnectionNumber=no
21174 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
21175 LIBS=$ac_check_lib_save_LIBS
21177 echo "$as_me:21177: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5
21178 echo "${ECHO_T}$ac_cv_lib_ICE_IceConnectionNumber" >&6
21179 if test $ac_cv_lib_ICE_IceConnectionNumber = yes; then
21180 X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
21183 LDFLAGS=$ac_save_LDFLAGS
21189 if ( test "$GCC" = yes || test "$GXX" = yes )
21192 if ( test "$GCC" = yes || test "$GXX" = yes )
21196 test -n "$verbose" && echo " repairing CFLAGS: $CFLAGS" 1>&6
21198 echo "${as_me:-configure}:21198: testing repairing CFLAGS: $CFLAGS ..." 1>&5
21201 for cf_temp_scan in $CFLAGS
21203 case "x$cf_temp_scan" in
21206 test -n "$EXTRA_CFLAGS" && EXTRA_CFLAGS="$EXTRA_CFLAGS "
21207 EXTRA_CFLAGS="${EXTRA_CFLAGS}"$cf_temp_scan""
21212 test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
21213 cf_temp_flags="${cf_temp_flags}"$cf_temp_scan""
21218 CFLAGS="$cf_temp_flags"
21219 test -n "$verbose" && echo " ... fixed $CFLAGS" 1>&6
21221 echo "${as_me:-configure}:21221: testing ... fixed $CFLAGS ..." 1>&5
21223 test -n "$verbose" && echo " ... extra $EXTRA_CFLAGS" 1>&6
21225 echo "${as_me:-configure}:21225: testing ... extra $EXTRA_CFLAGS ..." 1>&5
21231 if ( test "$GCC" = yes || test "$GXX" = yes )
21235 test -n "$verbose" && echo " repairing CPPFLAGS: $CPPFLAGS" 1>&6
21237 echo "${as_me:-configure}:21237: testing repairing CPPFLAGS: $CPPFLAGS ..." 1>&5
21240 for cf_temp_scan in $CPPFLAGS
21242 case "x$cf_temp_scan" in
21245 test -n "$EXTRA_CFLAGS" && EXTRA_CFLAGS="$EXTRA_CFLAGS "
21246 EXTRA_CFLAGS="${EXTRA_CFLAGS}"$cf_temp_scan""
21251 test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
21252 cf_temp_flags="${cf_temp_flags}"$cf_temp_scan""
21257 CPPFLAGS="$cf_temp_flags"
21258 test -n "$verbose" && echo " ... fixed $CPPFLAGS" 1>&6
21260 echo "${as_me:-configure}:21260: testing ... fixed $CPPFLAGS ..." 1>&5
21262 test -n "$verbose" && echo " ... extra $EXTRA_CFLAGS" 1>&6
21264 echo "${as_me:-configure}:21264: testing ... extra $EXTRA_CFLAGS ..." 1>&5
21270 if ( test "$GCC" = yes || test "$GXX" = yes )
21274 test -n "$verbose" && echo " repairing LDFLAGS: $LDFLAGS" 1>&6
21276 echo "${as_me:-configure}:21276: testing repairing LDFLAGS: $LDFLAGS ..." 1>&5
21279 for cf_temp_scan in $LDFLAGS
21281 case "x$cf_temp_scan" in
21284 test -n "$EXTRA_CFLAGS" && EXTRA_CFLAGS="$EXTRA_CFLAGS "
21285 EXTRA_CFLAGS="${EXTRA_CFLAGS}"$cf_temp_scan""
21290 test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
21291 cf_temp_flags="${cf_temp_flags}"$cf_temp_scan""
21296 LDFLAGS="$cf_temp_flags"
21297 test -n "$verbose" && echo " ... fixed $LDFLAGS" 1>&6
21299 echo "${as_me:-configure}:21299: testing ... fixed $LDFLAGS ..." 1>&5
21301 test -n "$verbose" && echo " ... extra $EXTRA_CFLAGS" 1>&6
21303 echo "${as_me:-configure}:21303: testing ... extra $EXTRA_CFLAGS ..." 1>&5
21309 echo "$as_me:21309: checking if you want to turn on gcc warnings" >&5
21310 echo $ECHO_N "checking if you want to turn on gcc warnings... $ECHO_C" >&6
21312 # Check whether --enable-warnings or --disable-warnings was given.
21313 if test "${enable_warnings+set}" = set; then
21314 enableval="$enable_warnings"
21315 test "$enableval" != yes && enableval=no
21316 if test "$enableval" != "no" ; then
21326 echo "$as_me:21326: result: $with_warnings" >&5
21327 echo "${ECHO_T}$with_warnings" >&6
21328 if test "$with_warnings" = "yes"
21331 if ( test "$GCC" = yes || test "$GXX" = yes )
21333 cat > conftest.i <<EOF
21335 #define GCC_PRINTF 0
21338 #define GCC_SCANF 0
21340 #ifndef GCC_NORETURN
21341 #define GCC_NORETURN /* nothing */
21344 #define GCC_UNUSED /* nothing */
21347 if test "$GCC" = yes
21349 { echo "$as_me:21349: checking for $CC __attribute__ directives..." >&5
21350 echo "$as_me: checking for $CC __attribute__ directives..." >&6;}
21351 cat > conftest.$ac_ext <<EOF
21352 #line 21352 "${as_me:-configure}"
21353 #include "confdefs.h"
21354 #include "conftest.h"
21355 #include "conftest.i"
21357 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
21359 #define GCC_PRINTFLIKE(fmt,var) /*nothing*/
21362 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
21364 #define GCC_SCANFLIKE(fmt,var) /*nothing*/
21366 extern void wow(char *,...) GCC_SCANFLIKE(1,2);
21367 extern void oops(char *,...) GCC_PRINTFLIKE(1,2) GCC_NORETURN;
21368 extern void foo(void) GCC_NORETURN;
21369 int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { (void)argc; (void)argv; return 0; }
21371 cf_printf_attribute=no
21372 cf_scanf_attribute=no
21373 for cf_attribute in scanf printf unused noreturn
21376 cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
21378 cf_directive="__attribute__(($cf_attribute))"
21379 echo "checking for $CC $cf_directive" 1>&5
21381 case $cf_attribute in
21383 cf_printf_attribute=yes
21384 cat >conftest.h <<EOF
21385 #define GCC_$cf_ATTRIBUTE 1
21389 cf_scanf_attribute=yes
21390 cat >conftest.h <<EOF
21391 #define GCC_$cf_ATTRIBUTE 1
21395 cat >conftest.h <<EOF
21396 #define GCC_$cf_ATTRIBUTE $cf_directive
21401 if { (eval echo "$as_me:21401: \"$ac_compile\"") >&5
21402 (eval $ac_compile) 2>&5
21404 echo "$as_me:21404: \$? = $ac_status" >&5
21405 (exit $ac_status); }; then
21406 test -n "$verbose" && echo "$as_me:21406: result: ... $cf_attribute" >&5
21407 echo "${ECHO_T}... $cf_attribute" >&6
21408 cat conftest.h >>confdefs.h
21409 case $cf_attribute in
21412 cat >>confdefs.h <<EOF
21413 #define GCC_NORETURN $cf_directive
21418 cf_value='/* nothing */'
21419 if test "$cf_printf_attribute" != no ; then
21420 cf_value='__attribute__((format(printf,fmt,var)))'
21422 cat >>confdefs.h <<\EOF
21423 #define GCC_PRINTF 1
21428 cat >>confdefs.h <<EOF
21429 #define GCC_PRINTFLIKE(fmt,var) $cf_value
21434 cf_value='/* nothing */'
21435 if test "$cf_scanf_attribute" != no ; then
21436 cf_value='__attribute__((format(scanf,fmt,var)))'
21438 cat >>confdefs.h <<\EOF
21439 #define GCC_SCANF 1
21444 cat >>confdefs.h <<EOF
21445 #define GCC_SCANFLIKE(fmt,var) $cf_value
21451 cat >>confdefs.h <<EOF
21452 #define GCC_UNUSED $cf_directive
21460 fgrep define conftest.i >>confdefs.h
21465 if test "x$have_x" = xyes; then
21467 cf_save_LIBS_CF_CONST_X_STRING="$LIBS"
21468 cf_save_CFLAGS_CF_CONST_X_STRING="$CFLAGS"
21469 cf_save_CPPFLAGS_CF_CONST_X_STRING="$CPPFLAGS"
21470 LIBS="$LIBS ${X_PRE_LIBS} ${X_LIBS} ${X_EXTRA_LIBS}"
21471 for cf_X_CFLAGS in $X_CFLAGS
21473 case "x$cf_X_CFLAGS" in
21475 CPPFLAGS="$CPPFLAGS $cf_X_CFLAGS"
21478 CFLAGS="$CFLAGS $cf_X_CFLAGS"
21483 cat >conftest.$ac_ext <<_ACEOF
21484 #line 21484 "configure"
21485 #include "confdefs.h"
21487 #include <stdlib.h>
21488 #include <X11/Intrinsic.h>
21493 String foo = malloc(1); (void)foo
21498 rm -f conftest.$ac_objext
21499 if { (eval echo "$as_me:21499: \"$ac_compile\"") >&5
21500 (eval $ac_compile) 2>&5
21502 echo "$as_me:21502: \$? = $ac_status" >&5
21503 (exit $ac_status); } &&
21504 { ac_try='test -s conftest.$ac_objext'
21505 { (eval echo "$as_me:21505: \"$ac_try\"") >&5
21506 (eval $ac_try) 2>&5
21508 echo "$as_me:21508: \$? = $ac_status" >&5
21509 (exit $ac_status); }; }; then
21511 echo "$as_me:21511: checking for X11/Xt const-feature" >&5
21512 echo $ECHO_N "checking for X11/Xt const-feature... $ECHO_C" >&6
21513 if test "${cf_cv_const_x_string+set}" = set; then
21514 echo $ECHO_N "(cached) $ECHO_C" >&6
21517 cat >conftest.$ac_ext <<_ACEOF
21518 #line 21518 "configure"
21519 #include "confdefs.h"
21521 #define _CONST_X_STRING /* X11R7.8 (perhaps) */
21522 #undef XTSTRINGDEFINES /* X11R5 and later */
21523 #include <stdlib.h>
21524 #include <X11/Intrinsic.h>
21529 String foo = malloc(1); *foo = 0
21534 rm -f conftest.$ac_objext
21535 if { (eval echo "$as_me:21535: \"$ac_compile\"") >&5
21536 (eval $ac_compile) 2>&5
21538 echo "$as_me:21538: \$? = $ac_status" >&5
21539 (exit $ac_status); } &&
21540 { ac_try='test -s conftest.$ac_objext'
21541 { (eval echo "$as_me:21541: \"$ac_try\"") >&5
21542 (eval $ac_try) 2>&5
21544 echo "$as_me:21544: \$? = $ac_status" >&5
21545 (exit $ac_status); }; }; then
21547 cf_cv_const_x_string=no
21550 echo "$as_me: failed program was:" >&5
21551 cat conftest.$ac_ext >&5
21553 cf_cv_const_x_string=yes
21556 rm -f conftest.$ac_objext conftest.$ac_ext
21559 echo "$as_me:21559: result: $cf_cv_const_x_string" >&5
21560 echo "${ECHO_T}$cf_cv_const_x_string" >&6
21562 LIBS="$cf_save_LIBS_CF_CONST_X_STRING"
21563 CFLAGS="$cf_save_CFLAGS_CF_CONST_X_STRING"
21564 CPPFLAGS="$cf_save_CPPFLAGS_CF_CONST_X_STRING"
21566 case $cf_cv_const_x_string in
21569 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
21570 CPPFLAGS="${CPPFLAGS}-DXTSTRINGDEFINES"
21575 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
21576 CPPFLAGS="${CPPFLAGS}-D_CONST_X_STRING"
21582 echo "$as_me: failed program was:" >&5
21583 cat conftest.$ac_ext >&5
21585 rm -f conftest.$ac_objext conftest.$ac_ext
21587 cat > conftest.$ac_ext <<EOF
21588 #line 21588 "${as_me:-configure}"
21589 int main(int argc, char *argv[]) { return (argv[argc-1] == 0) ; }
21591 if test "$INTEL_COMPILER" = yes
21593 # The "-wdXXX" options suppress warnings:
21594 # remark #1419: external declaration in primary source file
21595 # remark #1683: explicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem)
21596 # remark #1684: conversion from pointer to same-sized integral type (potential portability problem)
21597 # remark #193: zero used for undefined preprocessing identifier
21598 # remark #593: variable "curs_sb_left_arrow" was set but never used
21599 # remark #810: conversion from "int" to "Dimension={unsigned short}" may lose significant bits
21600 # remark #869: parameter "tw" was never referenced
21601 # remark #981: operands are evaluated in unspecified order
21602 # warning #279: controlling expression is constant
21604 { echo "$as_me:21604: checking for $CC warning options..." >&5
21605 echo "$as_me: checking for $CC warning options..." >&6;}
21606 cf_save_CFLAGS="$CFLAGS"
21607 EXTRA_CFLAGS="$EXTRA_CFLAGS -Wall"
21619 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
21620 if { (eval echo "$as_me:21620: \"$ac_compile\"") >&5
21621 (eval $ac_compile) 2>&5
21623 echo "$as_me:21623: \$? = $ac_status" >&5
21624 (exit $ac_status); }; then
21625 test -n "$verbose" && echo "$as_me:21625: result: ... -$cf_opt" >&5
21626 echo "${ECHO_T}... -$cf_opt" >&6
21627 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
21630 CFLAGS="$cf_save_CFLAGS"
21631 elif test "$GCC" = yes && test "$GCC_VERSION" != "unknown"
21633 { echo "$as_me:21633: checking for $CC warning options..." >&5
21634 echo "$as_me: checking for $CC warning options..." >&6;}
21635 cf_save_CFLAGS="$CFLAGS"
21637 test "$with_ext_const" = yes && cf_warn_CONST="Wwrite-strings"
21638 cf_gcc_warnings="Wignored-qualifiers Wlogical-op Wvarargs"
21639 test "x$CLANG_COMPILER" = xyes && cf_gcc_warnings=
21640 for cf_opt in W Wall \
21641 Wbad-function-cast \
21644 Wdeclaration-after-statement \
21647 Wmissing-declarations \
21648 Wmissing-prototypes \
21652 Wstrict-prototypes \
21653 Wundef Wno-inline $cf_gcc_warnings $cf_warn_CONST Wno-unknown-pragmas
21655 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
21656 if { (eval echo "$as_me:21656: \"$ac_compile\"") >&5
21657 (eval $ac_compile) 2>&5
21659 echo "$as_me:21659: \$? = $ac_status" >&5
21660 (exit $ac_status); }; then
21661 test -n "$verbose" && echo "$as_me:21661: result: ... -$cf_opt" >&5
21662 echo "${ECHO_T}... -$cf_opt" >&6
21665 case $GCC_VERSION in
21667 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
21669 echo "${as_me:-configure}:21669: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
21675 case $GCC_VERSION in
21677 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
21679 echo "${as_me:-configure}:21679: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
21685 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
21688 CFLAGS="$cf_save_CFLAGS"
21696 echo "$as_me:21696: checking if you want to use dmalloc for testing" >&5
21697 echo $ECHO_N "checking if you want to use dmalloc for testing... $ECHO_C" >&6
21699 # Check whether --with-dmalloc or --without-dmalloc was given.
21700 if test "${with_dmalloc+set}" = set; then
21701 withval="$with_dmalloc"
21703 cat >>confdefs.h <<EOF
21704 #define USE_DMALLOC 1
21707 : ${with_cflags:=-g}
21708 : ${with_no_leaks:=yes}
21713 echo "$as_me:21713: result: ${with_dmalloc:-no}" >&5
21714 echo "${ECHO_T}${with_dmalloc:-no}" >&6
21716 case .$with_cflags in
21726 cf_new_extra_cppflags=
21728 for cf_add_cflags in -g
21730 case $cf_fix_cppflags in
21732 case $cf_add_cflags in
21733 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
21734 case $cf_add_cflags in
21736 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
21738 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
21739 && test -z "${cf_tst_cflags}" \
21740 && cf_fix_cppflags=yes
21742 if test $cf_fix_cppflags = yes ; then
21744 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
21745 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
21748 elif test "${cf_tst_cflags}" = "\"'" ; then
21750 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
21751 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
21757 case "$CPPFLAGS" in
21761 case $cf_add_cflags in
21763 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
21765 CPPFLAGS=`echo "$CPPFLAGS" | \
21766 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
21767 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
21772 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
21773 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
21780 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
21781 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
21788 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
21789 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
21791 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
21793 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
21794 && test -z "${cf_tst_cflags}" \
21795 && cf_fix_cppflags=no
21800 if test -n "$cf_new_cflags" ; then
21802 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
21803 CFLAGS="${CFLAGS}$cf_new_cflags"
21807 if test -n "$cf_new_cppflags" ; then
21809 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
21810 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
21814 if test -n "$cf_new_extra_cppflags" ; then
21816 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
21817 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
21826 if test "$with_dmalloc" = yes ; then
21827 echo "$as_me:21827: checking for dmalloc.h" >&5
21828 echo $ECHO_N "checking for dmalloc.h... $ECHO_C" >&6
21829 if test "${ac_cv_header_dmalloc_h+set}" = set; then
21830 echo $ECHO_N "(cached) $ECHO_C" >&6
21832 cat >conftest.$ac_ext <<_ACEOF
21833 #line 21833 "configure"
21834 #include "confdefs.h"
21835 #include <dmalloc.h>
21837 if { (eval echo "$as_me:21837: \"$ac_cpp conftest.$ac_ext\"") >&5
21838 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
21840 egrep -v '^ *\+' conftest.er1 >conftest.err
21842 cat conftest.err >&5
21843 echo "$as_me:21843: \$? = $ac_status" >&5
21844 (exit $ac_status); } >/dev/null; then
21845 if test -s conftest.err; then
21846 ac_cpp_err=$ac_c_preproc_warn_flag
21853 if test -z "$ac_cpp_err"; then
21854 ac_cv_header_dmalloc_h=yes
21856 echo "$as_me: failed program was:" >&5
21857 cat conftest.$ac_ext >&5
21858 ac_cv_header_dmalloc_h=no
21860 rm -f conftest.err conftest.$ac_ext
21862 echo "$as_me:21862: result: $ac_cv_header_dmalloc_h" >&5
21863 echo "${ECHO_T}$ac_cv_header_dmalloc_h" >&6
21864 if test $ac_cv_header_dmalloc_h = yes; then
21866 echo "$as_me:21866: checking for dmalloc_debug in -ldmalloc" >&5
21867 echo $ECHO_N "checking for dmalloc_debug in -ldmalloc... $ECHO_C" >&6
21868 if test "${ac_cv_lib_dmalloc_dmalloc_debug+set}" = set; then
21869 echo $ECHO_N "(cached) $ECHO_C" >&6
21871 ac_check_lib_save_LIBS=$LIBS
21872 LIBS="-ldmalloc $LIBS"
21873 cat >conftest.$ac_ext <<_ACEOF
21874 #line 21874 "configure"
21875 #include "confdefs.h"
21877 /* Override any gcc2 internal prototype to avoid an error. */
21881 /* We use char because int might match the return type of a gcc2
21882 builtin and then its argument prototype would still apply. */
21883 char dmalloc_debug ();
21892 rm -f conftest.$ac_objext conftest$ac_exeext
21893 if { (eval echo "$as_me:21893: \"$ac_link\"") >&5
21894 (eval $ac_link) 2>&5
21896 echo "$as_me:21896: \$? = $ac_status" >&5
21897 (exit $ac_status); } &&
21898 { ac_try='test -s conftest$ac_exeext'
21899 { (eval echo "$as_me:21899: \"$ac_try\"") >&5
21900 (eval $ac_try) 2>&5
21902 echo "$as_me:21902: \$? = $ac_status" >&5
21903 (exit $ac_status); }; }; then
21904 ac_cv_lib_dmalloc_dmalloc_debug=yes
21906 echo "$as_me: failed program was:" >&5
21907 cat conftest.$ac_ext >&5
21908 ac_cv_lib_dmalloc_dmalloc_debug=no
21910 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
21911 LIBS=$ac_check_lib_save_LIBS
21913 echo "$as_me:21913: result: $ac_cv_lib_dmalloc_dmalloc_debug" >&5
21914 echo "${ECHO_T}$ac_cv_lib_dmalloc_dmalloc_debug" >&6
21915 if test $ac_cv_lib_dmalloc_dmalloc_debug = yes; then
21916 cat >>confdefs.h <<EOF
21917 #define HAVE_LIBDMALLOC 1
21920 LIBS="-ldmalloc $LIBS"
21928 echo "$as_me:21928: checking if you want to use dbmalloc for testing" >&5
21929 echo $ECHO_N "checking if you want to use dbmalloc for testing... $ECHO_C" >&6
21931 # Check whether --with-dbmalloc or --without-dbmalloc was given.
21932 if test "${with_dbmalloc+set}" = set; then
21933 withval="$with_dbmalloc"
21935 cat >>confdefs.h <<EOF
21936 #define USE_DBMALLOC 1
21939 : ${with_cflags:=-g}
21940 : ${with_no_leaks:=yes}
21945 echo "$as_me:21945: result: ${with_dbmalloc:-no}" >&5
21946 echo "${ECHO_T}${with_dbmalloc:-no}" >&6
21948 case .$with_cflags in
21958 cf_new_extra_cppflags=
21960 for cf_add_cflags in -g
21962 case $cf_fix_cppflags in
21964 case $cf_add_cflags in
21965 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
21966 case $cf_add_cflags in
21968 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
21970 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
21971 && test -z "${cf_tst_cflags}" \
21972 && cf_fix_cppflags=yes
21974 if test $cf_fix_cppflags = yes ; then
21976 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
21977 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
21980 elif test "${cf_tst_cflags}" = "\"'" ; then
21982 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
21983 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
21989 case "$CPPFLAGS" in
21993 case $cf_add_cflags in
21995 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
21997 CPPFLAGS=`echo "$CPPFLAGS" | \
21998 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
21999 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
22004 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
22005 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
22012 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
22013 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
22020 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
22021 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
22023 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
22025 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
22026 && test -z "${cf_tst_cflags}" \
22027 && cf_fix_cppflags=no
22032 if test -n "$cf_new_cflags" ; then
22034 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
22035 CFLAGS="${CFLAGS}$cf_new_cflags"
22039 if test -n "$cf_new_cppflags" ; then
22041 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
22042 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
22046 if test -n "$cf_new_extra_cppflags" ; then
22048 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
22049 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
22058 if test "$with_dbmalloc" = yes ; then
22059 echo "$as_me:22059: checking for dbmalloc.h" >&5
22060 echo $ECHO_N "checking for dbmalloc.h... $ECHO_C" >&6
22061 if test "${ac_cv_header_dbmalloc_h+set}" = set; then
22062 echo $ECHO_N "(cached) $ECHO_C" >&6
22064 cat >conftest.$ac_ext <<_ACEOF
22065 #line 22065 "configure"
22066 #include "confdefs.h"
22067 #include <dbmalloc.h>
22069 if { (eval echo "$as_me:22069: \"$ac_cpp conftest.$ac_ext\"") >&5
22070 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
22072 egrep -v '^ *\+' conftest.er1 >conftest.err
22074 cat conftest.err >&5
22075 echo "$as_me:22075: \$? = $ac_status" >&5
22076 (exit $ac_status); } >/dev/null; then
22077 if test -s conftest.err; then
22078 ac_cpp_err=$ac_c_preproc_warn_flag
22085 if test -z "$ac_cpp_err"; then
22086 ac_cv_header_dbmalloc_h=yes
22088 echo "$as_me: failed program was:" >&5
22089 cat conftest.$ac_ext >&5
22090 ac_cv_header_dbmalloc_h=no
22092 rm -f conftest.err conftest.$ac_ext
22094 echo "$as_me:22094: result: $ac_cv_header_dbmalloc_h" >&5
22095 echo "${ECHO_T}$ac_cv_header_dbmalloc_h" >&6
22096 if test $ac_cv_header_dbmalloc_h = yes; then
22098 echo "$as_me:22098: checking for debug_malloc in -ldbmalloc" >&5
22099 echo $ECHO_N "checking for debug_malloc in -ldbmalloc... $ECHO_C" >&6
22100 if test "${ac_cv_lib_dbmalloc_debug_malloc+set}" = set; then
22101 echo $ECHO_N "(cached) $ECHO_C" >&6
22103 ac_check_lib_save_LIBS=$LIBS
22104 LIBS="-ldbmalloc $LIBS"
22105 cat >conftest.$ac_ext <<_ACEOF
22106 #line 22106 "configure"
22107 #include "confdefs.h"
22109 /* Override any gcc2 internal prototype to avoid an error. */
22113 /* We use char because int might match the return type of a gcc2
22114 builtin and then its argument prototype would still apply. */
22115 char debug_malloc ();
22124 rm -f conftest.$ac_objext conftest$ac_exeext
22125 if { (eval echo "$as_me:22125: \"$ac_link\"") >&5
22126 (eval $ac_link) 2>&5
22128 echo "$as_me:22128: \$? = $ac_status" >&5
22129 (exit $ac_status); } &&
22130 { ac_try='test -s conftest$ac_exeext'
22131 { (eval echo "$as_me:22131: \"$ac_try\"") >&5
22132 (eval $ac_try) 2>&5
22134 echo "$as_me:22134: \$? = $ac_status" >&5
22135 (exit $ac_status); }; }; then
22136 ac_cv_lib_dbmalloc_debug_malloc=yes
22138 echo "$as_me: failed program was:" >&5
22139 cat conftest.$ac_ext >&5
22140 ac_cv_lib_dbmalloc_debug_malloc=no
22142 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
22143 LIBS=$ac_check_lib_save_LIBS
22145 echo "$as_me:22145: result: $ac_cv_lib_dbmalloc_debug_malloc" >&5
22146 echo "${ECHO_T}$ac_cv_lib_dbmalloc_debug_malloc" >&6
22147 if test $ac_cv_lib_dbmalloc_debug_malloc = yes; then
22148 cat >>confdefs.h <<EOF
22149 #define HAVE_LIBDBMALLOC 1
22152 LIBS="-ldbmalloc $LIBS"
22160 echo "$as_me:22160: checking if you want to use valgrind for testing" >&5
22161 echo $ECHO_N "checking if you want to use valgrind for testing... $ECHO_C" >&6
22163 # Check whether --with-valgrind or --without-valgrind was given.
22164 if test "${with_valgrind+set}" = set; then
22165 withval="$with_valgrind"
22167 cat >>confdefs.h <<EOF
22168 #define USE_VALGRIND 1
22171 : ${with_cflags:=-g}
22172 : ${with_no_leaks:=yes}
22177 echo "$as_me:22177: result: ${with_valgrind:-no}" >&5
22178 echo "${ECHO_T}${with_valgrind:-no}" >&6
22180 case .$with_cflags in
22190 cf_new_extra_cppflags=
22192 for cf_add_cflags in -g
22194 case $cf_fix_cppflags in
22196 case $cf_add_cflags in
22197 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
22198 case $cf_add_cflags in
22200 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
22202 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
22203 && test -z "${cf_tst_cflags}" \
22204 && cf_fix_cppflags=yes
22206 if test $cf_fix_cppflags = yes ; then
22208 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
22209 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
22212 elif test "${cf_tst_cflags}" = "\"'" ; then
22214 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
22215 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
22221 case "$CPPFLAGS" in
22225 case $cf_add_cflags in
22227 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
22229 CPPFLAGS=`echo "$CPPFLAGS" | \
22230 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
22231 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
22236 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
22237 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
22244 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
22245 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
22252 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
22253 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
22255 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
22257 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
22258 && test -z "${cf_tst_cflags}" \
22259 && cf_fix_cppflags=no
22264 if test -n "$cf_new_cflags" ; then
22266 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
22267 CFLAGS="${CFLAGS}$cf_new_cflags"
22271 if test -n "$cf_new_cppflags" ; then
22273 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
22274 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
22278 if test -n "$cf_new_extra_cppflags" ; then
22280 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
22281 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
22290 echo "$as_me:22290: checking if you want to perform memory-leak testing" >&5
22291 echo $ECHO_N "checking if you want to perform memory-leak testing... $ECHO_C" >&6
22293 # Check whether --enable-leaks or --disable-leaks was given.
22294 if test "${enable_leaks+set}" = set; then
22295 enableval="$enable_leaks"
22296 if test "x$enableval" = xno; then with_no_leaks=yes; else with_no_leaks=no; fi
22298 : ${with_no_leaks:=no}
22300 echo "$as_me:22300: result: $with_no_leaks" >&5
22301 echo "${ECHO_T}$with_no_leaks" >&6
22303 if test "$with_no_leaks" = yes ; then
22305 cat >>confdefs.h <<\EOF
22309 cat >>confdefs.h <<\EOF
22310 #define YY_NO_LEAKS 1
22316 if test "x$cf_cv_enable_rpath" != xno
22318 echo "$as_me:22318: checking for an rpath option" >&5
22319 echo $ECHO_N "checking for an rpath option... $ECHO_C" >&6
22320 case $cf_cv_system_name in
22322 if test "$GCC" = yes; then
22323 LD_RPATH_OPT="-Wl,-rpath,"
22325 LD_RPATH_OPT="-rpath "
22328 (linux*|gnu*|k*bsd*-gnu|freebsd*)
22329 LD_RPATH_OPT="-Wl,-rpath,"
22331 (openbsd[2-9].*|mirbsd*)
22332 LD_RPATH_OPT="-Wl,-rpath,"
22335 LD_RPATH_OPT="-rpath "
22338 LD_RPATH_OPT="-Wl,-rpath,"
22341 LD_RPATH_OPT="-rpath "
22349 echo "$as_me:22349: result: $LD_RPATH_OPT" >&5
22350 echo "${ECHO_T}$LD_RPATH_OPT" >&6
22352 case "x$LD_RPATH_OPT" in
22354 echo "$as_me:22354: checking if we need a space after rpath option" >&5
22355 echo $ECHO_N "checking if we need a space after rpath option... $ECHO_C" >&6
22356 cf_save_LIBS="$LIBS"
22358 cf_add_libs="$LIBS"
22361 for cf_add_1lib in ${LD_RPATH_OPT}$libdir; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
22362 # filter duplicates
22363 for cf_add_1lib in $cf_add_0lib; do
22364 for cf_add_2lib in $cf_add_libs; do
22365 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
22370 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
22372 LIBS="$cf_add_libs"
22374 cat >conftest.$ac_ext <<_ACEOF
22375 #line 22375 "configure"
22376 #include "confdefs.h"
22386 rm -f conftest.$ac_objext conftest$ac_exeext
22387 if { (eval echo "$as_me:22387: \"$ac_link\"") >&5
22388 (eval $ac_link) 2>&5
22390 echo "$as_me:22390: \$? = $ac_status" >&5
22391 (exit $ac_status); } &&
22392 { ac_try='test -s conftest$ac_exeext'
22393 { (eval echo "$as_me:22393: \"$ac_try\"") >&5
22394 (eval $ac_try) 2>&5
22396 echo "$as_me:22396: \$? = $ac_status" >&5
22397 (exit $ac_status); }; }; then
22400 echo "$as_me: failed program was:" >&5
22401 cat conftest.$ac_ext >&5
22404 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
22405 LIBS="$cf_save_LIBS"
22406 echo "$as_me:22406: result: $cf_rpath_space" >&5
22407 echo "${ECHO_T}$cf_rpath_space" >&6
22408 test "$cf_rpath_space" = yes && LD_RPATH_OPT="$LD_RPATH_OPT "
22413 echo "$as_me:22413: checking if rpath-hack should be disabled" >&5
22414 echo $ECHO_N "checking if rpath-hack should be disabled... $ECHO_C" >&6
22416 # Check whether --enable-rpath-hack or --disable-rpath-hack was given.
22417 if test "${enable_rpath_hack+set}" = set; then
22418 enableval="$enable_rpath_hack"
22419 test "$enableval" != no && enableval=yes
22420 if test "$enableval" != "yes" ; then
22421 cf_disable_rpath_hack=yes
22423 cf_disable_rpath_hack=no
22427 cf_disable_rpath_hack=no
22430 echo "$as_me:22430: result: $cf_disable_rpath_hack" >&5
22431 echo "${ECHO_T}$cf_disable_rpath_hack" >&6
22432 if test "$cf_disable_rpath_hack" = no ; then
22434 echo "$as_me:22434: checking for updated LDFLAGS" >&5
22435 echo $ECHO_N "checking for updated LDFLAGS... $ECHO_C" >&6
22436 if test -n "$LD_RPATH_OPT" ; then
22437 echo "$as_me:22437: result: maybe" >&5
22438 echo "${ECHO_T}maybe" >&6
22442 # Extract the first word of "$ac_prog", so it can be a program name with args.
22443 set dummy $ac_prog; ac_word=$2
22444 echo "$as_me:22444: checking for $ac_word" >&5
22445 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
22446 if test "${ac_cv_prog_cf_ldd_prog+set}" = set; then
22447 echo $ECHO_N "(cached) $ECHO_C" >&6
22449 if test -n "$cf_ldd_prog"; then
22450 ac_cv_prog_cf_ldd_prog="$cf_ldd_prog" # Let the user override the test.
22452 ac_save_IFS=$IFS; IFS=$ac_path_separator
22454 for ac_dir in $ac_dummy; do
22456 test -z "$ac_dir" && ac_dir=.
22457 $as_executable_p "$ac_dir/$ac_word" || continue
22458 ac_cv_prog_cf_ldd_prog="$ac_prog"
22459 echo "$as_me:22459: found $ac_dir/$ac_word" >&5
22465 cf_ldd_prog=$ac_cv_prog_cf_ldd_prog
22466 if test -n "$cf_ldd_prog"; then
22467 echo "$as_me:22467: result: $cf_ldd_prog" >&5
22468 echo "${ECHO_T}$cf_ldd_prog" >&6
22470 echo "$as_me:22470: result: no" >&5
22471 echo "${ECHO_T}no" >&6
22474 test -n "$cf_ldd_prog" && break
22476 test -n "$cf_ldd_prog" || cf_ldd_prog="no"
22478 cf_rpath_list="/usr/lib /lib"
22479 if test "$cf_ldd_prog" != no
22483 cat >conftest.$ac_ext <<_ACEOF
22484 #line 22484 "configure"
22485 #include "confdefs.h"
22495 rm -f conftest.$ac_objext conftest$ac_exeext
22496 if { (eval echo "$as_me:22496: \"$ac_link\"") >&5
22497 (eval $ac_link) 2>&5
22499 echo "$as_me:22499: \$? = $ac_status" >&5
22500 (exit $ac_status); } &&
22501 { ac_try='test -s conftest$ac_exeext'
22502 { (eval echo "$as_me:22502: \"$ac_try\"") >&5
22503 (eval $ac_try) 2>&5
22505 echo "$as_me:22505: \$? = $ac_status" >&5
22506 (exit $ac_status); }; }; then
22507 cf_rpath_oops=`$cf_ldd_prog conftest$ac_exeext | fgrep ' not found' | sed -e 's% =>.*$%%' |sort | uniq`
22508 cf_rpath_list=`$cf_ldd_prog conftest$ac_exeext | fgrep / | sed -e 's%^.*[ ]/%/%' -e 's%/[^/][^/]*$%%' |sort | uniq`
22510 echo "$as_me: failed program was:" >&5
22511 cat conftest.$ac_ext >&5
22513 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
22515 # If we passed the link-test, but get a "not found" on a given library,
22516 # this could be due to inept reconfiguration of gcc to make it only
22517 # partly honor /usr/local/lib (or whatever). Sometimes this behavior
22518 # is intentional, e.g., installing gcc in /usr/bin and suppressing the
22519 # /usr/local libraries.
22520 if test -n "$cf_rpath_oops"
22522 for cf_rpath_src in $cf_rpath_oops
22524 for cf_rpath_dir in \
22529 if test -f $cf_rpath_dir/lib/$cf_rpath_src
22531 test -n "$verbose" && echo " ...adding -L$cf_rpath_dir/lib to LDFLAGS for $cf_rpath_src" 1>&6
22533 echo "${as_me:-configure}:22533: testing ...adding -L$cf_rpath_dir/lib to LDFLAGS for $cf_rpath_src ..." 1>&5
22535 LDFLAGS="$LDFLAGS -L$cf_rpath_dir/lib"
22543 test -n "$verbose" && echo " ...checking EXTRA_LDFLAGS $EXTRA_LDFLAGS" 1>&6
22545 echo "${as_me:-configure}:22545: testing ...checking EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5
22547 test -n "$verbose" && echo " ...checking LDFLAGS $LDFLAGS" 1>&6
22549 echo "${as_me:-configure}:22549: testing ...checking LDFLAGS $LDFLAGS ..." 1>&5
22552 for cf_rpath_src in $LDFLAGS
22554 case $cf_rpath_src in
22557 # check if this refers to a directory which we will ignore
22559 if test -n "$cf_rpath_list"
22561 for cf_rpath_item in $cf_rpath_list
22563 if test "x$cf_rpath_src" = "x-L$cf_rpath_item"
22571 if test "$cf_rpath_skip" = no
22573 # transform the option
22574 if test "$LD_RPATH_OPT" = "-R " ; then
22575 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%-R %"`
22577 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%$LD_RPATH_OPT%"`
22580 # if we have not already added this, add it now
22581 cf_rpath_tst=`echo "$EXTRA_LDFLAGS" | sed -e "s%$cf_rpath_tmp %%"`
22582 if test "x$cf_rpath_tst" = "x$EXTRA_LDFLAGS"
22584 test -n "$verbose" && echo " ...Filter $cf_rpath_src ->$cf_rpath_tmp" 1>&6
22586 echo "${as_me:-configure}:22586: testing ...Filter $cf_rpath_src ->$cf_rpath_tmp ..." 1>&5
22588 EXTRA_LDFLAGS="$cf_rpath_tmp $EXTRA_LDFLAGS"
22593 cf_rpath_dst="$cf_rpath_dst $cf_rpath_src"
22595 LDFLAGS=$cf_rpath_dst
22597 test -n "$verbose" && echo " ...checked LDFLAGS $LDFLAGS" 1>&6
22599 echo "${as_me:-configure}:22599: testing ...checked LDFLAGS $LDFLAGS ..." 1>&5
22601 test -n "$verbose" && echo " ...checking LIBS $LIBS" 1>&6
22603 echo "${as_me:-configure}:22603: testing ...checking LIBS $LIBS ..." 1>&5
22606 for cf_rpath_src in $LIBS
22608 case $cf_rpath_src in
22611 # check if this refers to a directory which we will ignore
22613 if test -n "$cf_rpath_list"
22615 for cf_rpath_item in $cf_rpath_list
22617 if test "x$cf_rpath_src" = "x-L$cf_rpath_item"
22625 if test "$cf_rpath_skip" = no
22627 # transform the option
22628 if test "$LD_RPATH_OPT" = "-R " ; then
22629 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%-R %"`
22631 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%$LD_RPATH_OPT%"`
22634 # if we have not already added this, add it now
22635 cf_rpath_tst=`echo "$EXTRA_LDFLAGS" | sed -e "s%$cf_rpath_tmp %%"`
22636 if test "x$cf_rpath_tst" = "x$EXTRA_LDFLAGS"
22638 test -n "$verbose" && echo " ...Filter $cf_rpath_src ->$cf_rpath_tmp" 1>&6
22640 echo "${as_me:-configure}:22640: testing ...Filter $cf_rpath_src ->$cf_rpath_tmp ..." 1>&5
22642 EXTRA_LDFLAGS="$cf_rpath_tmp $EXTRA_LDFLAGS"
22647 cf_rpath_dst="$cf_rpath_dst $cf_rpath_src"
22651 test -n "$verbose" && echo " ...checked LIBS $LIBS" 1>&6
22653 echo "${as_me:-configure}:22653: testing ...checked LIBS $LIBS ..." 1>&5
22655 test -n "$verbose" && echo " ...checked EXTRA_LDFLAGS $EXTRA_LDFLAGS" 1>&6
22657 echo "${as_me:-configure}:22657: testing ...checked EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5
22660 echo "$as_me:22660: result: no" >&5
22661 echo "${ECHO_T}no" >&6
22669 ac_config_files="$ac_config_files Makefile"
22670 ac_config_commands="$ac_config_commands default"
22671 cat >confcache <<\_ACEOF
22672 # This file is a shell script that caches the results of configure
22673 # tests run on this system so they can be shared between configure
22674 # scripts and configure runs, see configure's option --config-cache.
22675 # It is not useful on other systems. If it contains results you don't
22676 # want to keep, you may remove or edit it.
22678 # config.status only pays attention to the cache file if you give it
22679 # the --recheck option to rerun configure.
22681 # `ac_cv_env_foo' variables (set or unset) will be overriden when
22682 # loading this file, other *unset* `ac_cv_foo' will be assigned the
22683 # following values.
22687 # The following way of writing the cache mishandles newlines in values,
22688 # but we know of no workaround that is simple, portable, and efficient.
22689 # So, don't put newlines in cache variables' values.
22690 # Ultrix sh set writes to stderr and can't be redirected directly,
22691 # and sets the high bit in the cache file unless we assign to the vars.
22694 case `(ac_space=' '; set | grep ac_space) 2>&1` in
22696 # `set' does not quote correctly, so add quotes (double-quote
22697 # substitution turns \\\\ into \\, and sed turns \\ into \).
22700 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
22703 # `set' quotes correctly as required by POSIX, so do not add quotes.
22705 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
22712 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
22714 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
22716 if cmp -s $cache_file confcache; then :; else
22717 if test -w $cache_file; then
22718 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
22719 cat confcache >$cache_file
22721 echo "not updating unwritable cache $cache_file"
22726 test "x$prefix" = xNONE && prefix=$ac_default_prefix
22727 # Let make expand exec_prefix.
22728 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
22730 # VPATH may cause trouble with some makes, so we remove $(srcdir),
22731 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
22732 # trailing colons and then remove the whole line if VPATH becomes empty
22733 # (actually we leave an empty line to preserve line numbers).
22734 if test "x$srcdir" = x.; then
22735 ac_vpsub='/^[ ]*VPATH[ ]*=/{
22736 s/:*\$(srcdir):*/:/;
22737 s/:*\${srcdir}:*/:/;
22739 s/^\([^=]*=[ ]*\):*/\1/;
22745 DEFS=-DHAVE_CONFIG_H
22747 : ${CONFIG_STATUS=./config.status}
22748 ac_clean_files_save=$ac_clean_files
22749 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
22750 { echo "$as_me:22750: creating $CONFIG_STATUS" >&5
22751 echo "$as_me: creating $CONFIG_STATUS" >&6;}
22752 cat >$CONFIG_STATUS <<_ACEOF
22754 # Generated automatically by configure.
22755 # Run this file to recreate the current configuration.
22756 # Compiler output produced by configure, useful for debugging
22757 # configure, is in config.log if it exists.
22760 SHELL=\${CONFIG_SHELL-$SHELL}
22761 ac_cs_invocation="\$0 \$@"
22763 CLICOLOR_FORCE= GREP_OPTIONS=
22764 unset CLICOLOR_FORCE GREP_OPTIONS
22767 cat >>$CONFIG_STATUS <<\_ACEOF
22768 # Be Bourne compatible
22769 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
22772 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
22776 # Name of the executable.
22777 as_me=`echo "$0" |sed 's,.*[\\/],,'`
22779 if expr a : '\(a\)' >/dev/null 2>&1; then
22785 rm -f conf$$ conf$$.exe conf$$.file
22787 if ln -s conf$$.file conf$$ 2>/dev/null; then
22788 # We could just check for DJGPP; but this test a) works b) is more generic
22789 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
22790 if test -f conf$$.exe; then
22791 # Don't use ln at all; we don't have any links
22796 elif ln conf$$.file conf$$ 2>/dev/null; then
22801 rm -f conf$$ conf$$.exe conf$$.file
22803 as_executable_p="test -f"
22805 # Support unset when possible.
22806 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
22813 $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
22814 $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
22815 $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
22816 $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
22817 $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
22818 $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
22819 $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
22820 $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
22823 # We need space, tab and new line, in precisely that order.
22829 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
22835 # Files that config.status was made for.
22836 if test -n "$ac_config_files"; then
22837 echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
22840 if test -n "$ac_config_headers"; then
22841 echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
22844 if test -n "$ac_config_links"; then
22845 echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
22848 if test -n "$ac_config_commands"; then
22849 echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
22852 cat >>$CONFIG_STATUS <<\EOF
22855 \`$as_me' instantiates files from templates according to the
22856 current configuration.
22858 Usage: $0 [OPTIONS] [FILE]...
22860 -h, --help print this help, then exit
22861 -V, --version print version number, then exit
22862 -d, --debug don't remove temporary files
22863 --recheck update $as_me by reconfiguring in the same conditions
22864 --file=FILE[:TEMPLATE]
22865 instantiate the configuration file FILE
22866 --header=FILE[:TEMPLATE]
22867 instantiate the configuration header FILE
22869 Configuration files:
22872 Configuration headers:
22875 Configuration commands:
22878 Report bugs to <dickey@invisible-island.net>."
22881 cat >>$CONFIG_STATUS <<EOF
22884 configured by $0, generated by GNU Autoconf 2.52.20200802,
22885 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
22887 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
22888 Free Software Foundation, Inc.
22889 This config.status script is free software; the Free Software Foundation
22890 gives unlimited permission to copy, distribute and modify it."
22895 cat >>$CONFIG_STATUS <<\EOF
22896 # If no file are specified by the user, then we need to provide default
22897 # value. By we need to know if files were specified by the user.
22903 ac_option=`expr "x$1" : 'x\([^=]*\)='`
22904 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
22906 set dummy "$ac_option" "$ac_optarg" ${1+"$@"}
22910 *) # This is not an option, so the user has probably given explicit
22912 ac_need_defaults=false;;
22916 # Handling of the options.
22918 cat >>$CONFIG_STATUS <<EOF
22919 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
22920 echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion"
22921 exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;;
22923 cat >>$CONFIG_STATUS <<\EOF
22924 --version | --vers* | -V )
22925 echo "$ac_cs_version"; exit 0 ;;
22927 # Conflict between --help and --header
22928 { { echo "$as_me:22928: error: ambiguous option: $1
22929 Try \`$0 --help' for more information." >&5
22930 echo "$as_me: error: ambiguous option: $1
22931 Try \`$0 --help' for more information." >&2;}
22932 { (exit 1); exit 1; }; };;
22933 --help | --hel | -h )
22934 echo "$ac_cs_usage"; exit 0 ;;
22935 --debug | --d* | -d )
22937 --file | --fil | --fi | --f )
22939 CONFIG_FILES="$CONFIG_FILES $1"
22940 ac_need_defaults=false;;
22941 --header | --heade | --head | --hea )
22943 CONFIG_HEADERS="$CONFIG_HEADERS $1"
22944 ac_need_defaults=false;;
22946 # This is an error.
22947 -*) { { echo "$as_me:22947: error: unrecognized option: $1
22948 Try \`$0 --help' for more information." >&5
22949 echo "$as_me: error: unrecognized option: $1
22950 Try \`$0 --help' for more information." >&2;}
22951 { (exit 1); exit 1; }; } ;;
22953 *) ac_config_targets="$ac_config_targets $1" ;;
22962 ## ----------------------- ##
22963 ## Running config.status. ##
22964 ## ----------------------- ##
22966 This file was extended by $as_me 2.52.20200802, executed with
22967 CONFIG_FILES = $CONFIG_FILES
22968 CONFIG_HEADERS = $CONFIG_HEADERS
22969 CONFIG_LINKS = $CONFIG_LINKS
22970 CONFIG_COMMANDS = $CONFIG_COMMANDS
22971 > $ac_cs_invocation
22972 on `(hostname || uname -n) 2>/dev/null | sed 1q`
22977 cat >>$CONFIG_STATUS <<EOF
22979 # INIT-COMMANDS section.
22989 cat >>$CONFIG_STATUS <<\EOF
22990 for ac_config_target in $ac_config_targets
22992 case "$ac_config_target" in
22993 # Handling of arguments.
22994 "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
22995 "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
22996 "ncurses_cfg.h" ) CONFIG_HEADERS="$CONFIG_HEADERS ncurses_cfg.h:ncurses_tst.hin" ;;
22997 *) { { echo "$as_me:22997: error: invalid argument: $ac_config_target" >&5
22998 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
22999 { (exit 1); exit 1; }; };;
23003 # If the user did not use the arguments to specify the items to instantiate,
23004 # then the envvar interface is used. Set only those that are not.
23005 # We use the long form for the default assignment because of an extremely
23006 # bizarre bug on SunOS 4.1.3.
23007 if $ac_need_defaults; then
23008 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
23009 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
23010 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
23013 # Create a temporary directory, and hook for its removal unless debugging.
23016 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
23017 trap '{ (exit 1); exit 1; }' 1 2 13 15
23020 # Create a (secure) tmp directory for tmp files.
23023 tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` &&
23024 test -n "$tmp" && test -d "$tmp"
23027 tmp=$TMPDIR/cs$$-$RANDOM
23028 (umask 077 && mkdir $tmp)
23031 echo "$me: cannot create a temporary directory in $TMPDIR" >&2
23032 { (exit 1); exit 1; }
23037 cat >>$CONFIG_STATUS <<EOF
23040 # CONFIG_FILES section.
23043 # No need to generate the scripts if there are no CONFIG_FILES.
23044 # This happens for instance when ./config.status config.h
23045 if test -n "\$CONFIG_FILES"; then
23046 # Protect against being on the right side of a sed subst in config.status.
23047 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
23048 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
23049 s,@SHELL@,$SHELL,;t t
23050 s,@exec_prefix@,$exec_prefix,;t t
23051 s,@prefix@,$prefix,;t t
23052 s,@program_transform_name@,$program_transform_name,;t t
23053 s,@bindir@,$bindir,;t t
23054 s,@sbindir@,$sbindir,;t t
23055 s,@libexecdir@,$libexecdir,;t t
23056 s,@datarootdir@,$datarootdir,;t t
23057 s,@datadir@,$datadir,;t t
23058 s,@sysconfdir@,$sysconfdir,;t t
23059 s,@sharedstatedir@,$sharedstatedir,;t t
23060 s,@localstatedir@,$localstatedir,;t t
23061 s,@runstatedir@,$runstatedir,;t t
23062 s,@libdir@,$libdir,;t t
23063 s,@includedir@,$includedir,;t t
23064 s,@oldincludedir@,$oldincludedir,;t t
23065 s,@infodir@,$infodir,;t t
23066 s,@mandir@,$mandir,;t t
23067 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
23068 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
23069 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
23070 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
23071 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
23072 s,@build_alias@,$build_alias,;t t
23073 s,@host_alias@,$host_alias,;t t
23074 s,@target_alias@,$target_alias,;t t
23075 s,@ECHO_C@,$ECHO_C,;t t
23076 s,@ECHO_N@,$ECHO_N,;t t
23077 s,@ECHO_T@,$ECHO_T,;t t
23078 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
23079 s,@DEFS@,$DEFS,;t t
23080 s,@LIBS@,$LIBS,;t t
23081 s,@build@,$build,;t t
23082 s,@build_cpu@,$build_cpu,;t t
23083 s,@build_vendor@,$build_vendor,;t t
23084 s,@build_os@,$build_os,;t t
23085 s,@host@,$host,;t t
23086 s,@host_cpu@,$host_cpu,;t t
23087 s,@host_vendor@,$host_vendor,;t t
23088 s,@host_os@,$host_os,;t t
23089 s,@SET_MAKE@,$SET_MAKE,;t t
23091 s,@CFLAGS@,$CFLAGS,;t t
23092 s,@LDFLAGS@,$LDFLAGS,;t t
23093 s,@CPPFLAGS@,$CPPFLAGS,;t t
23094 s,@ac_ct_CC@,$ac_ct_CC,;t t
23095 s,@EXEEXT@,$EXEEXT,;t t
23096 s,@OBJEXT@,$OBJEXT,;t t
23097 s,@EXTRA_CPPFLAGS@,$EXTRA_CPPFLAGS,;t t
23100 s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
23101 s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
23102 s,@INSTALL_DATA@,$INSTALL_DATA,;t t
23103 s,@INSTALL_OPT_S@,$INSTALL_OPT_S,;t t
23104 s,@INSTALL_OPT_O@,$INSTALL_OPT_O,;t t
23105 s,@LINT@,$LINT,;t t
23106 s,@LINT_OPTS@,$LINT_OPTS,;t t
23107 s,@CTAGS@,$CTAGS,;t t
23108 s,@ETAGS@,$ETAGS,;t t
23109 s,@MAKE_LOWER_TAGS@,$MAKE_LOWER_TAGS,;t t
23110 s,@MAKE_UPPER_TAGS@,$MAKE_UPPER_TAGS,;t t
23111 s,@MATH_LIB@,$MATH_LIB,;t t
23112 s,@top_builddir@,$top_builddir,;t t
23113 s,@CC_G_OPT@,$CC_G_OPT,;t t
23114 s,@CC_SHARED_OPTS@,$CC_SHARED_OPTS,;t t
23115 s,@DFT_DEP_SUFFIX@,$DFT_DEP_SUFFIX,;t t
23116 s,@DFT_OBJ_SUBDIR@,$DFT_OBJ_SUBDIR,;t t
23117 s,@DFT_UPR_MODEL@,$DFT_UPR_MODEL,;t t
23119 s,@LDFLAGS_SHARED@,$LDFLAGS_SHARED,;t t
23120 s,@LDFLAGS_STATIC@,$LDFLAGS_STATIC,;t t
23121 s,@LD_MODEL@,$LD_MODEL,;t t
23122 s,@LD_SHARED_OPTS@,$LD_SHARED_OPTS,;t t
23123 s,@LIBTOOL@,$LIBTOOL,;t t
23124 s,@LIBTOOL_OPTS@,$LIBTOOL_OPTS,;t t
23125 s,@LIB_CLEAN@,$LIB_CLEAN,;t t
23126 s,@LIB_COMPILE@,$LIB_COMPILE,;t t
23127 s,@LIB_LINK@,$LIB_LINK,;t t
23128 s,@LINK_TESTS@,$LINK_TESTS,;t t
23129 s,@LOCAL_LDFLAGS@,$LOCAL_LDFLAGS,;t t
23130 s,@PACKAGE@,$PACKAGE,;t t
23131 s,@PTHREAD@,$PTHREAD,;t t
23132 s,@TEST_ARGS@,$TEST_ARGS,;t t
23133 s,@TEST_DEPS@,$TEST_DEPS,;t t
23134 s,@TEST_LIBS@,$TEST_LIBS,;t t
23135 s,@TINFO_LDFLAGS@,$TINFO_LDFLAGS,;t t
23136 s,@TINFO_LIBS@,$TINFO_LIBS,;t t
23137 s,@cf_cv_abi_version@,$cf_cv_abi_version,;t t
23138 s,@cf_cv_rel_version@,$cf_cv_rel_version,;t t
23139 s,@includesubdir@,$includesubdir,;t t
23140 s,@PKG_CONFIG@,$PKG_CONFIG,;t t
23141 s,@ac_pt_PKG_CONFIG@,$ac_pt_PKG_CONFIG,;t t
23142 s,@ECHO_LT@,$ECHO_LT,;t t
23143 s,@ECHO_LD@,$ECHO_LD,;t t
23144 s,@RULE_CC@,$RULE_CC,;t t
23145 s,@SHOW_CC@,$SHOW_CC,;t t
23146 s,@ECHO_CC@,$ECHO_CC,;t t
23147 s,@NCURSES_WRAP_PREFIX@,$NCURSES_WRAP_PREFIX,;t t
23148 s,@NCURSES_CONFIG@,$NCURSES_CONFIG,;t t
23149 s,@ac_ct_NCURSES_CONFIG@,$ac_ct_NCURSES_CONFIG,;t t
23150 s,@X_CFLAGS@,$X_CFLAGS,;t t
23151 s,@X_PRE_LIBS@,$X_PRE_LIBS,;t t
23152 s,@X_LIBS@,$X_LIBS,;t t
23153 s,@X_EXTRA_LIBS@,$X_EXTRA_LIBS,;t t
23154 s,@XCURSES_CONFIG@,$XCURSES_CONFIG,;t t
23155 s,@ac_ct_XCURSES_CONFIG@,$ac_ct_XCURSES_CONFIG,;t t
23156 s,@RGB_PATH@,$RGB_PATH,;t t
23157 s,@no_x11_rgb@,$no_x11_rgb,;t t
23158 s,@FORM_NAME@,$FORM_NAME,;t t
23159 s,@MENU_NAME@,$MENU_NAME,;t t
23160 s,@PANEL_NAME@,$PANEL_NAME,;t t
23161 s,@EXTRA_CFLAGS@,$EXTRA_CFLAGS,;t t
23162 s,@cf_ldd_prog@,$cf_ldd_prog,;t t
23163 s,@EXTRA_LDFLAGS@,$EXTRA_LDFLAGS,;t t
23168 cat >>$CONFIG_STATUS <<\EOF
23169 # Split the substitutions into bite-sized pieces for seds with
23170 # small command number limits, like on Digital OSF/1 and HP-UX.
23171 ac_max_sed_lines=48
23172 ac_sed_frag=1 # Number of current file.
23173 ac_beg=1 # First line for current file.
23174 ac_end=$ac_max_sed_lines # Line after last line for current file.
23177 while $ac_more_lines; do
23178 if test $ac_beg -gt 1; then
23179 sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
23181 sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
23183 if test ! -s $tmp/subs.frag; then
23184 ac_more_lines=false
23186 # The purpose of the label and of the branching condition is to
23187 # speed up the sed processing (if there are no `@' at all, there
23188 # is no need to browse any of the substitutions).
23189 # These are the two extra sed commands mentioned above.
23191 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
23192 # It is possible to make a multiline substitution using escaped newlines.
23193 # Ensure that we do not split the substitution between script fragments.
23195 ac_END=`expr $ac_end + $ac_max_sed_lines`
23196 sed "1,${ac_BEG}d; ${ac_END}p; q" $tmp/subs.sed >$tmp/subs.next
23197 if test -s $tmp/subs.next; then
23198 grep '^s,@[^@,][^@,]*@,.*\\$' $tmp/subs.next >$tmp/subs.edit
23199 if test ! -s $tmp/subs.edit; then
23200 grep "^s,@[^@,][^@,]*@,.*,;t t$" $tmp/subs.next >$tmp/subs.edit
23201 if test ! -s $tmp/subs.edit; then
23202 if test $ac_beg -gt 1; then
23203 ac_end=`expr $ac_end - 1`
23210 if test -z "$ac_sed_cmds"; then
23211 ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
23213 ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
23215 ac_sed_frag=`expr $ac_sed_frag + 1`
23217 ac_end=`expr $ac_end + $ac_max_sed_lines`
23220 if test -z "$ac_sed_cmds"; then
23223 fi # test -n "$CONFIG_FILES"
23226 cat >>$CONFIG_STATUS <<\EOF
23227 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
23228 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
23230 - | *:- | *:-:* ) # input from stdin
23232 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
23233 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
23234 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
23235 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
23236 * ) ac_file_in=$ac_file.in ;;
23239 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
23240 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23241 X"$ac_file" : 'X\(//\)[^/]' \| \
23242 X"$ac_file" : 'X\(//\)$' \| \
23243 X"$ac_file" : 'X\(/\)' \| \
23244 . : '\(.\)' 2>/dev/null ||
23246 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
23247 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
23248 /^X\(\/\/\)$/{ s//\1/; q; }
23249 /^X\(\/\).*/{ s//\1/; q; }
23251 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
23252 { case "$ac_dir" in
23253 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
23257 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
23258 case $as_mkdir_dir in
23259 # Skip DOS drivespec
23260 ?:) as_incr_dir=$as_mkdir_dir ;;
23262 as_incr_dir=$as_incr_dir/$as_mkdir_dir
23263 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
23268 ac_dir_suffix="/`echo $ac_dir|sed 's,^\./,,'`"
23269 # A "../" for each directory in $ac_dir_suffix.
23270 ac_dots=`echo "$ac_dir_suffix" | sed 's,/[^/]*,../,g'`
23272 ac_dir_suffix= ac_dots=
23277 if test -z "$ac_dots"; then
23280 ac_top_srcdir=`echo $ac_dots | sed 's,/$,,'`
23282 [\\/]* | ?:[\\/]* )
23283 ac_srcdir=$srcdir$ac_dir_suffix;
23284 ac_top_srcdir=$srcdir ;;
23285 *) # Relative path.
23286 ac_srcdir=$ac_dots$srcdir$ac_dir_suffix
23287 ac_top_srcdir=$ac_dots$srcdir ;;
23291 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
23292 *) ac_INSTALL=$ac_dots$INSTALL ;;
23295 if test x"$ac_file" != x-; then
23296 { echo "$as_me:23296: creating $ac_file" >&5
23297 echo "$as_me: creating $ac_file" >&6;}
23300 # Let's still pretend it is `configure' which instantiates (i.e., don't
23301 # use $as_me), people would be surprised to read:
23302 # /* config.h. Generated automatically by config.status. */
23303 configure_input="Generated automatically from `echo $ac_file_in |
23304 sed 's,.*/,,'` by configure."
23306 # First look for the input files in the build tree, otherwise in the
23308 ac_file_inputs=`IFS=:
23309 for f in $ac_file_in; do
23311 -) echo $tmp/stdin ;;
23313 # Absolute (can't be DOS-style, as IFS=:)
23314 test -f "$f" || { { echo "$as_me:23314: error: cannot find input file: $f" >&5
23315 echo "$as_me: error: cannot find input file: $f" >&2;}
23316 { (exit 1); exit 1; }; }
23319 if test -f "$f"; then
23322 elif test -f "$srcdir/$f"; then
23327 { { echo "$as_me:23327: error: cannot find input file: $f" >&5
23328 echo "$as_me: error: cannot find input file: $f" >&2;}
23329 { (exit 1); exit 1; }; }
23332 done` || { (exit 1); exit 1; }
23334 cat >>$CONFIG_STATUS <<\EOF
23335 ac_warn_datarootdir=no
23336 if test x"$ac_file" != x-; then
23337 for ac_item in $ac_file_inputs
23339 ac_seen=`grep '@\(datadir\|mandir\|infodir\)@' $ac_item`
23340 if test -n "$ac_seen"; then
23341 ac_used=`grep '@datarootdir@' $ac_item`
23342 if test -z "$ac_used"; then
23343 { echo "$as_me:23343: WARNING: datarootdir was used implicitly but not set:
23345 echo "$as_me: WARNING: datarootdir was used implicitly but not set:
23347 ac_warn_datarootdir=yes
23350 ac_seen=`grep '${datarootdir}' $ac_item`
23351 if test -n "$ac_seen"; then
23352 { echo "$as_me:23352: WARNING: datarootdir was used explicitly but not set:
23354 echo "$as_me: WARNING: datarootdir was used explicitly but not set:
23356 ac_warn_datarootdir=yes
23361 if test "x$ac_warn_datarootdir" = xyes; then
23362 ac_sed_cmds="$ac_sed_cmds | sed -e 's,@datarootdir@,\${prefix}/share,g' -e 's,\${datarootdir},\${prefix}/share,g'"
23366 cat >>$CONFIG_STATUS <<EOF
23370 cat >>$CONFIG_STATUS <<\EOF
23372 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
23373 s,@configure_input@,$configure_input,;t t
23374 s,@srcdir@,$ac_srcdir,;t t
23375 s,@top_srcdir@,$ac_top_srcdir,;t t
23376 s,@INSTALL@,$ac_INSTALL,;t t
23377 " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
23379 if test x"$ac_file" != x-; then
23380 cp $tmp/out $ac_file
23382 for ac_name in prefix exec_prefix datarootdir
23384 ac_seen=`fgrep -n '${'$ac_name'[:=].*}' $ac_file`
23385 if test -n "$ac_seen"; then
23386 ac_init=`egrep '[ ]*'$ac_name'[ ]*=' $ac_file`
23387 if test -z "$ac_init"; then
23388 ac_seen=`echo "$ac_seen" |sed -e 's,^,'$ac_file':,'`
23389 { echo "$as_me:23389: WARNING: Variable $ac_name is used but was not set:
23391 echo "$as_me: WARNING: Variable $ac_name is used but was not set:
23396 egrep -n '@[a-z_][a-z_0-9]+@' $ac_file >$tmp/out
23397 egrep -n '@[A-Z_][A-Z_0-9]+@' $ac_file >>$tmp/out
23398 if test -s $tmp/out; then
23399 ac_seen=`sed -e 's,^,'$ac_file':,' < $tmp/out`
23400 { echo "$as_me:23400: WARNING: Some variables may not be substituted:
23402 echo "$as_me: WARNING: Some variables may not be substituted:
23412 cat >>$CONFIG_STATUS <<\EOF
23415 # CONFIG_HEADER section.
23418 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
23419 # NAME is the cpp macro being defined and VALUE is the value it is being given.
23421 # ac_d sets the value in "#define NAME VALUE" lines.
23422 ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
23423 ac_dB='[ ].*$,\1#\2'
23426 # ac_i turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
23427 ac_iA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
23428 ac_iB='\([ ]\),\1#\2define\3'
23431 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
23432 ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
23433 ac_uB='$,\1#\2define\3'
23437 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
23438 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
23440 - | *:- | *:-:* ) # input from stdin
23442 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
23443 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
23444 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
23445 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
23446 * ) ac_file_in=$ac_file.in ;;
23449 test x"$ac_file" != x- && { echo "$as_me:23449: creating $ac_file" >&5
23450 echo "$as_me: creating $ac_file" >&6;}
23452 # First look for the input files in the build tree, otherwise in the
23454 ac_file_inputs=`IFS=:
23455 for f in $ac_file_in; do
23457 -) echo $tmp/stdin ;;
23459 # Absolute (can't be DOS-style, as IFS=:)
23460 test -f "$f" || { { echo "$as_me:23460: error: cannot find input file: $f" >&5
23461 echo "$as_me: error: cannot find input file: $f" >&2;}
23462 { (exit 1); exit 1; }; }
23465 if test -f "$f"; then
23468 elif test -f "$srcdir/$f"; then
23473 { { echo "$as_me:23473: error: cannot find input file: $f" >&5
23474 echo "$as_me: error: cannot find input file: $f" >&2;}
23475 { (exit 1); exit 1; }; }
23478 done` || { (exit 1); exit 1; }
23479 # Remove the trailing spaces.
23480 sed 's/[ ]*$//' $ac_file_inputs >$tmp/in
23484 # Transform confdefs.h into a list of #define's. We won't use it as a sed
23485 # script, but as data to insert where we see @DEFS@. We expect AC_SAVE_DEFS to
23486 # be either 'cat' or 'sort'.
23487 cat confdefs.h | uniq >conftest.vals
23489 # Break up conftest.vals because some shells have a limit on
23490 # the size of here documents, and old seds have small limits too.
23492 rm -f conftest.tail
23493 echo ' rm -f conftest.frag' >> $CONFIG_STATUS
23494 while grep . conftest.vals >/dev/null
23496 # Write chunks of a limited-size here document to conftest.frag.
23497 echo ' cat >> conftest.frag <<CEOF' >> $CONFIG_STATUS
23498 sed ${ac_max_here_lines}q conftest.vals | sed -e 's/#ifdef.*/#if 0/' >> $CONFIG_STATUS
23499 echo 'CEOF' >> $CONFIG_STATUS
23500 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
23501 rm -f conftest.vals
23502 mv conftest.tail conftest.vals
23504 rm -f conftest.vals
23506 # Run sed to substitute the contents of conftest.frag into $tmp/in at the
23508 echo ' cat >> conftest.edit <<CEOF
23509 /@DEFS@/r conftest.frag
23512 sed -f conftest.edit $tmp/in > $tmp/out
23514 mv $tmp/out $tmp/in
23515 rm -f conftest.edit conftest.frag
23516 ' >> $CONFIG_STATUS
23518 cat >>$CONFIG_STATUS <<\EOF
23519 # Let's still pretend it is `configure' which instantiates (i.e., don't
23520 # use $as_me), people would be surprised to read:
23521 # /* config.h. Generated automatically by config.status. */
23522 if test x"$ac_file" = x-; then
23523 echo "/* Generated automatically by configure. */" >$tmp/config.h
23525 echo "/* $ac_file. Generated automatically by configure. */" >$tmp/config.h
23527 cat $tmp/in >>$tmp/config.h
23529 if test x"$ac_file" != x-; then
23530 if cmp -s $ac_file $tmp/config.h 2>/dev/null; then
23531 { echo "$as_me:23531: $ac_file is unchanged" >&5
23532 echo "$as_me: $ac_file is unchanged" >&6;}
23534 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23535 X"$ac_file" : 'X\(//\)[^/]' \| \
23536 X"$ac_file" : 'X\(//\)$' \| \
23537 X"$ac_file" : 'X\(/\)' \| \
23538 . : '\(.\)' 2>/dev/null ||
23540 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
23541 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
23542 /^X\(\/\/\)$/{ s//\1/; q; }
23543 /^X\(\/\).*/{ s//\1/; q; }
23545 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
23546 { case "$ac_dir" in
23547 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
23551 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
23552 case $as_mkdir_dir in
23553 # Skip DOS drivespec
23554 ?:) as_incr_dir=$as_mkdir_dir ;;
23556 as_incr_dir=$as_incr_dir/$as_mkdir_dir
23557 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
23564 mv $tmp/config.h $ac_file
23568 rm -f $tmp/config.h
23572 cat >>$CONFIG_STATUS <<\EOF
23574 # CONFIG_COMMANDS section.
23576 for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
23577 ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
23578 ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
23585 if test ! -d $srcdir/$cf_dir; then
23587 elif test -f $srcdir/$cf_dir/programs; then
23588 $AWK -f $srcdir/mk-test.awk INSTALL=yes ECHO_LINK="$ECHO_LD" $srcdir/$cf_dir/programs >>$cf_dir/Makefile
23592 cat >>Makefile <<TEST_EOF
23594 # These rules are generated so we do not rely on suffix rules, which do not
23595 # work consistently for different make-programs (the '\$(MODEL)/' confuses
23596 # some, and the '\$x' confuses others).
23599 LIST=`sed -e 's/[ ].*//' -e '/^[#@]/d' $srcdir/modules`
23602 cat >>Makefile <<TEST_EOF
23604 \$(MODEL)/$N.o : \$(srcdir)/$N.c \\
23605 \$(srcdir)/test.priv.h \\
23608 $ECHO_CC\$(CC) -c \$(CFLAGS_DEFAULT) -DMODULE_NAME="$N" \$(srcdir)/$N.c
23612 if test -f ../config.guess && test -f ../config.sub
23614 cat >>Makefile <<TEST_EOF
23616 # if we used CF_INHERIT for getting these files, we can remove them
23618 rm -f config.guess config.sub
23626 cat >>$CONFIG_STATUS <<\EOF
23628 { (exit 0); exit 0; }
23630 chmod +x $CONFIG_STATUS
23631 ac_clean_files=$ac_clean_files_save
23633 # configure is writing to config.log, and then calls config.status.
23634 # config.status does its own redirection, appending to config.log.
23635 # Unfortunately, on DOS this fails, as config.log is still kept open
23636 # by configure, so config.status won't be able to write to it; its
23637 # output is simply discarded. So we exec the FD to /dev/null,
23638 # effectively closing config.log, so it can be properly (re)opened and
23639 # appended to by config.status. When coming back to configure, we
23640 # need to make the FD available again.
23641 if test "$no_create" != yes; then
23644 $SHELL $CONFIG_STATUS || ac_cs_success=false
23646 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
23647 # would make configure fail if this is the last instruction.
23648 $ac_cs_success || { (exit 1); exit 1; }