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
1962 if test "x$CLANG_COMPILER" = "xyes" ; then
1963 for cf_clang_opt in \
1964 -Qunused-arguments \
1965 -Wno-error=implicit-function-declaration
1967 echo "$as_me:1967: checking if option $cf_clang_opt works" >&5
1968 echo $ECHO_N "checking if option $cf_clang_opt works... $ECHO_C" >&6
1969 cf_save_CFLAGS="$CFLAGS"
1970 CFLAGS="$CFLAGS $cf_clang_opt"
1971 cat >conftest.$ac_ext <<_ACEOF
1972 #line 1972 "configure"
1973 #include "confdefs.h"
1985 rm -f conftest.$ac_objext conftest$ac_exeext
1986 if { (eval echo "$as_me:1986: \"$ac_link\"") >&5
1987 (eval $ac_link) 2>&5
1989 echo "$as_me:1989: \$? = $ac_status" >&5
1990 (exit $ac_status); } &&
1991 { ac_try='test -s conftest$ac_exeext'
1992 { (eval echo "$as_me:1992: \"$ac_try\"") >&5
1995 echo "$as_me:1995: \$? = $ac_status" >&5
1996 (exit $ac_status); }; }; then
2000 echo "$as_me: failed program was:" >&5
2001 cat conftest.$ac_ext >&5
2005 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
2006 echo "$as_me:2006: result: $cf_clang_optok" >&5
2007 echo "${ECHO_T}$cf_clang_optok" >&6
2008 CFLAGS="$cf_save_CFLAGS"
2009 if test $cf_clang_optok = yes; then
2010 test -n "$verbose" && echo " adding option $cf_clang_opt" 1>&6
2012 echo "${as_me:-configure}:2012: testing adding option $cf_clang_opt ..." 1>&5
2014 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
2015 CFLAGS="${CFLAGS}$cf_clang_opt"
2021 echo "$as_me:2021: checking for $CC option to accept ANSI C" >&5
2022 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
2023 if test "${ac_cv_prog_cc_stdc+set}" = set; then
2024 echo $ECHO_N "(cached) $ECHO_C" >&6
2026 ac_cv_prog_cc_stdc=no
2028 cat >conftest.$ac_ext <<_ACEOF
2029 #line 2029 "configure"
2030 #include "confdefs.h"
2033 #include <sys/types.h>
2034 #include <sys/stat.h>
2035 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
2036 struct buf { int x; };
2037 FILE * (*rcsopen) (struct buf *, struct stat *, int);
2038 static char *e (p, i)
2044 static char *f (char * (*g) (char **, int), char **p, ...)
2049 s = g (p, va_arg (v,int));
2053 int test (int i, double x);
2054 struct s1 {int (*f) (int a);};
2055 struct s2 {int (*f) (double a);};
2056 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
2062 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
2067 # Don't try gcc -ansi; that turns off useful extensions and
2068 # breaks some systems' header files.
2069 # AIX -qlanglvl=ansi
2070 # Ultrix and OSF/1 -std1
2071 # HP-UX 10.20 and later -Ae
2072 # HP-UX older versions -Aa -D_HPUX_SOURCE
2073 # SVR4 -Xc -D__EXTENSIONS__
2074 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
2076 CC="$ac_save_CC $ac_arg"
2077 rm -f conftest.$ac_objext
2078 if { (eval echo "$as_me:2078: \"$ac_compile\"") >&5
2079 (eval $ac_compile) 2>&5
2081 echo "$as_me:2081: \$? = $ac_status" >&5
2082 (exit $ac_status); } &&
2083 { ac_try='test -s conftest.$ac_objext'
2084 { (eval echo "$as_me:2084: \"$ac_try\"") >&5
2087 echo "$as_me:2087: \$? = $ac_status" >&5
2088 (exit $ac_status); }; }; then
2089 ac_cv_prog_cc_stdc=$ac_arg
2092 echo "$as_me: failed program was:" >&5
2093 cat conftest.$ac_ext >&5
2095 rm -f conftest.$ac_objext
2097 rm -f conftest.$ac_ext conftest.$ac_objext
2102 case "x$ac_cv_prog_cc_stdc" in
2104 echo "$as_me:2104: result: none needed" >&5
2105 echo "${ECHO_T}none needed" >&6 ;;
2107 echo "$as_me:2107: result: $ac_cv_prog_cc_stdc" >&5
2108 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
2109 CC="$CC $ac_cv_prog_cc_stdc" ;;
2112 # This should have been defined by AC_PROG_CC
2115 echo "$as_me:2115: checking \$CFLAGS variable" >&5
2116 echo $ECHO_N "checking \$CFLAGS variable... $ECHO_C" >&6
2119 echo "$as_me:2119: result: broken" >&5
2120 echo "${ECHO_T}broken" >&6
2121 { echo "$as_me:2121: WARNING: your environment uses the CFLAGS variable to hold CPPFLAGS options" >&5
2122 echo "$as_me: WARNING: your environment uses the CFLAGS variable to hold CPPFLAGS options" >&2;}
2125 for cf_arg in $cf_flags
2131 cf_new_extra_cppflags=
2133 for cf_add_cflags in $cf_arg
2135 case $cf_fix_cppflags in
2137 case $cf_add_cflags in
2138 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
2139 case $cf_add_cflags in
2141 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
2143 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2144 && test -z "${cf_tst_cflags}" \
2145 && cf_fix_cppflags=yes
2147 if test $cf_fix_cppflags = yes ; then
2149 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2150 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2153 elif test "${cf_tst_cflags}" = "\"'" ; then
2155 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2156 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2166 case $cf_add_cflags in
2168 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
2170 CPPFLAGS=`echo "$CPPFLAGS" | \
2171 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
2172 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
2177 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
2178 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
2185 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
2186 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
2193 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2194 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2196 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
2198 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2199 && test -z "${cf_tst_cflags}" \
2200 && cf_fix_cppflags=no
2205 if test -n "$cf_new_cflags" ; then
2207 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
2208 CFLAGS="${CFLAGS}$cf_new_cflags"
2212 if test -n "$cf_new_cppflags" ; then
2214 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
2215 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
2219 if test -n "$cf_new_extra_cppflags" ; then
2221 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
2222 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
2229 echo "$as_me:2229: result: ok" >&5
2230 echo "${ECHO_T}ok" >&6
2234 echo "$as_me:2234: checking \$CC variable" >&5
2235 echo $ECHO_N "checking \$CC variable... $ECHO_C" >&6
2238 echo "$as_me:2238: result: broken" >&5
2239 echo "${ECHO_T}broken" >&6
2240 { echo "$as_me:2240: WARNING: your environment uses the CC variable to hold CFLAGS/CPPFLAGS options" >&5
2241 echo "$as_me: WARNING: your environment uses the CC variable to hold CFLAGS/CPPFLAGS options" >&2;}
2243 cf_prog=`echo "$CC" | sed -e 's/ / /g' -e 's/[ ]* / /g' -e 's/[ ]*[ ]-[^ ].*//'`
2244 cf_flags=`echo "$CC" | ${AWK:-awk} -v prog="$cf_prog" '{ printf("%s", substr($0,1+length(prog))); }'`
2246 for cf_arg in $cf_flags
2254 cf_new_extra_cppflags=
2256 for cf_add_cflags in $cf_arg
2258 case $cf_fix_cppflags in
2260 case $cf_add_cflags in
2261 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
2262 case $cf_add_cflags in
2264 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
2266 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2267 && test -z "${cf_tst_cflags}" \
2268 && cf_fix_cppflags=yes
2270 if test $cf_fix_cppflags = yes ; then
2272 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2273 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2276 elif test "${cf_tst_cflags}" = "\"'" ; then
2278 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2279 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2289 case $cf_add_cflags in
2291 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
2293 CPPFLAGS=`echo "$CPPFLAGS" | \
2294 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
2295 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
2300 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
2301 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
2308 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
2309 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
2316 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2317 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2319 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
2321 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2322 && test -z "${cf_tst_cflags}" \
2323 && cf_fix_cppflags=no
2328 if test -n "$cf_new_cflags" ; then
2330 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
2331 CFLAGS="${CFLAGS}$cf_new_cflags"
2335 if test -n "$cf_new_cppflags" ; then
2337 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
2338 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
2342 if test -n "$cf_new_extra_cppflags" ; then
2344 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
2345 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
2355 test -n "$verbose" && echo " resulting CC: '$CC'" 1>&6
2357 echo "${as_me:-configure}:2357: testing resulting CC: '$CC' ..." 1>&5
2359 test -n "$verbose" && echo " resulting CFLAGS: '$CFLAGS'" 1>&6
2361 echo "${as_me:-configure}:2361: testing resulting CFLAGS: '$CFLAGS' ..." 1>&5
2363 test -n "$verbose" && echo " resulting CPPFLAGS: '$CPPFLAGS'" 1>&6
2365 echo "${as_me:-configure}:2365: testing resulting CPPFLAGS: '$CPPFLAGS' ..." 1>&5
2369 echo "$as_me:2369: result: ok" >&5
2370 echo "${ECHO_T}ok" >&6
2374 echo "$as_me:2374: checking for inline" >&5
2375 echo $ECHO_N "checking for inline... $ECHO_C" >&6
2376 if test "${ac_cv_c_inline+set}" = set; then
2377 echo $ECHO_N "(cached) $ECHO_C" >&6
2380 for ac_kw in inline __inline__ __inline; do
2381 cat >conftest.$ac_ext <<_ACEOF
2382 #line 2382 "configure"
2383 #include "confdefs.h"
2385 static $ac_kw int static_foo () {return 0; }
2386 $ac_kw int foo () {return 0; }
2390 rm -f conftest.$ac_objext
2391 if { (eval echo "$as_me:2391: \"$ac_compile\"") >&5
2392 (eval $ac_compile) 2>&5
2394 echo "$as_me:2394: \$? = $ac_status" >&5
2395 (exit $ac_status); } &&
2396 { ac_try='test -s conftest.$ac_objext'
2397 { (eval echo "$as_me:2397: \"$ac_try\"") >&5
2400 echo "$as_me:2400: \$? = $ac_status" >&5
2401 (exit $ac_status); }; }; then
2402 ac_cv_c_inline=$ac_kw; break
2404 echo "$as_me: failed program was:" >&5
2405 cat conftest.$ac_ext >&5
2407 rm -f conftest.$ac_objext conftest.$ac_ext
2411 echo "$as_me:2411: result: $ac_cv_c_inline" >&5
2412 echo "${ECHO_T}$ac_cv_c_inline" >&6
2413 case $ac_cv_c_inline in
2416 cat >>confdefs.h <<\EOF
2420 *) cat >>confdefs.h <<EOF
2421 #define inline $ac_cv_c_inline
2427 ac_cpp='$CPP $CPPFLAGS'
2428 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2429 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2430 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2431 ac_main_return=return
2432 echo "$as_me:2432: checking how to run the C preprocessor" >&5
2433 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
2434 # On Suns, sometimes $CPP names a directory.
2435 if test -n "$CPP" && test -d "$CPP"; then
2438 if test -z "$CPP"; then
2439 if test "${ac_cv_prog_CPP+set}" = set; then
2440 echo $ECHO_N "(cached) $ECHO_C" >&6
2442 # Double quotes because CPP needs to be expanded
2443 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
2446 for ac_c_preproc_warn_flag in '' yes
2448 # Use a header file that comes with gcc, so configuring glibc
2449 # with a fresh cross-compiler works.
2450 # On the NeXT, cc -E runs the code through the compiler's parser,
2451 # not just through cpp. "Syntax error" is here to catch this case.
2452 cat >conftest.$ac_ext <<_ACEOF
2453 #line 2453 "configure"
2454 #include "confdefs.h"
2458 if { (eval echo "$as_me:2458: \"$ac_cpp conftest.$ac_ext\"") >&5
2459 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2461 egrep -v '^ *\+' conftest.er1 >conftest.err
2463 cat conftest.err >&5
2464 echo "$as_me:2464: \$? = $ac_status" >&5
2465 (exit $ac_status); } >/dev/null; then
2466 if test -s conftest.err; then
2467 ac_cpp_err=$ac_c_preproc_warn_flag
2474 if test -z "$ac_cpp_err"; then
2477 echo "$as_me: failed program was:" >&5
2478 cat conftest.$ac_ext >&5
2479 # Broken: fails on valid input.
2482 rm -f conftest.err conftest.$ac_ext
2484 # OK, works on sane cases. Now check whether non-existent headers
2485 # can be detected and how.
2486 cat >conftest.$ac_ext <<_ACEOF
2487 #line 2487 "configure"
2488 #include "confdefs.h"
2489 #include <ac_nonexistent.h>
2491 if { (eval echo "$as_me:2491: \"$ac_cpp conftest.$ac_ext\"") >&5
2492 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2494 egrep -v '^ *\+' conftest.er1 >conftest.err
2496 cat conftest.err >&5
2497 echo "$as_me:2497: \$? = $ac_status" >&5
2498 (exit $ac_status); } >/dev/null; then
2499 if test -s conftest.err; then
2500 ac_cpp_err=$ac_c_preproc_warn_flag
2507 if test -z "$ac_cpp_err"; then
2508 # Broken: success on invalid input.
2511 echo "$as_me: failed program was:" >&5
2512 cat conftest.$ac_ext >&5
2513 # Passes both tests.
2517 rm -f conftest.err conftest.$ac_ext
2520 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2521 rm -f conftest.err conftest.$ac_ext
2522 if $ac_preproc_ok; then
2534 echo "$as_me:2534: result: $CPP" >&5
2535 echo "${ECHO_T}$CPP" >&6
2537 for ac_c_preproc_warn_flag in '' yes
2539 # Use a header file that comes with gcc, so configuring glibc
2540 # with a fresh cross-compiler works.
2541 # On the NeXT, cc -E runs the code through the compiler's parser,
2542 # not just through cpp. "Syntax error" is here to catch this case.
2543 cat >conftest.$ac_ext <<_ACEOF
2544 #line 2544 "configure"
2545 #include "confdefs.h"
2549 if { (eval echo "$as_me:2549: \"$ac_cpp conftest.$ac_ext\"") >&5
2550 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2552 egrep -v '^ *\+' conftest.er1 >conftest.err
2554 cat conftest.err >&5
2555 echo "$as_me:2555: \$? = $ac_status" >&5
2556 (exit $ac_status); } >/dev/null; then
2557 if test -s conftest.err; then
2558 ac_cpp_err=$ac_c_preproc_warn_flag
2565 if test -z "$ac_cpp_err"; then
2568 echo "$as_me: failed program was:" >&5
2569 cat conftest.$ac_ext >&5
2570 # Broken: fails on valid input.
2573 rm -f conftest.err conftest.$ac_ext
2575 # OK, works on sane cases. Now check whether non-existent headers
2576 # can be detected and how.
2577 cat >conftest.$ac_ext <<_ACEOF
2578 #line 2578 "configure"
2579 #include "confdefs.h"
2580 #include <ac_nonexistent.h>
2582 if { (eval echo "$as_me:2582: \"$ac_cpp conftest.$ac_ext\"") >&5
2583 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2585 egrep -v '^ *\+' conftest.er1 >conftest.err
2587 cat conftest.err >&5
2588 echo "$as_me:2588: \$? = $ac_status" >&5
2589 (exit $ac_status); } >/dev/null; then
2590 if test -s conftest.err; then
2591 ac_cpp_err=$ac_c_preproc_warn_flag
2598 if test -z "$ac_cpp_err"; then
2599 # Broken: success on invalid input.
2602 echo "$as_me: failed program was:" >&5
2603 cat conftest.$ac_ext >&5
2604 # Passes both tests.
2608 rm -f conftest.err conftest.$ac_ext
2611 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2612 rm -f conftest.err conftest.$ac_ext
2613 if $ac_preproc_ok; then
2616 { { echo "$as_me:2616: error: C preprocessor \"$CPP\" fails sanity check" >&5
2617 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;}
2618 { (exit 1); exit 1; }; }
2622 ac_cpp='$CPP $CPPFLAGS'
2623 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2624 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2625 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2626 ac_main_return=return
2628 for ac_prog in mawk gawk nawk awk
2630 # Extract the first word of "$ac_prog", so it can be a program name with args.
2631 set dummy $ac_prog; ac_word=$2
2632 echo "$as_me:2632: checking for $ac_word" >&5
2633 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2634 if test "${ac_cv_prog_AWK+set}" = set; then
2635 echo $ECHO_N "(cached) $ECHO_C" >&6
2637 if test -n "$AWK"; then
2638 ac_cv_prog_AWK="$AWK" # Let the user override the test.
2640 ac_save_IFS=$IFS; IFS=$ac_path_separator
2642 for ac_dir in $ac_dummy; do
2644 test -z "$ac_dir" && ac_dir=.
2645 $as_executable_p "$ac_dir/$ac_word" || continue
2646 ac_cv_prog_AWK="$ac_prog"
2647 echo "$as_me:2647: found $ac_dir/$ac_word" >&5
2654 if test -n "$AWK"; then
2655 echo "$as_me:2655: result: $AWK" >&5
2656 echo "${ECHO_T}$AWK" >&6
2658 echo "$as_me:2658: result: no" >&5
2659 echo "${ECHO_T}no" >&6
2662 test -n "$AWK" && break
2665 # Find a good install program. We prefer a C program (faster),
2666 # so one script is as good as another. But avoid the broken or
2667 # incompatible versions:
2668 # SysV /etc/install, /usr/sbin/install
2669 # SunOS /usr/etc/install
2670 # IRIX /sbin/install
2672 # AmigaOS /C/install, which installs bootblocks on floppy discs
2673 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
2674 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
2675 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
2676 # ./install, which can be erroneously created by make from ./install.sh.
2677 echo "$as_me:2677: checking for a BSD compatible install" >&5
2678 echo $ECHO_N "checking for a BSD compatible install... $ECHO_C" >&6
2679 if test -z "$INSTALL"; then
2680 if test "${ac_cv_path_install+set}" = set; then
2681 echo $ECHO_N "(cached) $ECHO_C" >&6
2683 ac_save_IFS=$IFS; IFS=$ac_path_separator
2684 for ac_dir in $PATH; do
2686 # Account for people who put trailing slashes in PATH elements.
2688 / | ./ | .// | /cC/* \
2689 | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* \
2692 # OSF1 and SCO ODT 3.0 have their own names for install.
2693 # Don't use installbsd from OSF since it installs stuff as root
2695 for ac_prog in ginstall scoinst install; do
2696 if $as_executable_p "$ac_dir/$ac_prog"; then
2697 if test $ac_prog = install &&
2698 grep dspmsg "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2699 # AIX install. It has an incompatible calling convention.
2701 elif test $ac_prog = install &&
2702 grep pwplus "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2703 # program-specific install script used by HP pwplus--don't use.
2706 ac_cv_path_install="$ac_dir/$ac_prog -c"
2716 if test "${ac_cv_path_install+set}" = set; then
2717 INSTALL=$ac_cv_path_install
2719 # As a last resort, use the slow shell script. We don't cache a
2720 # path for INSTALL within a source directory, because that will
2721 # break other packages using the cache if that directory is
2722 # removed, or if the path is relative.
2723 INSTALL=$ac_install_sh
2726 echo "$as_me:2726: result: $INSTALL" >&5
2727 echo "${ECHO_T}$INSTALL" >&6
2729 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
2730 # It thinks the first close brace ends the variable substitution.
2731 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
2733 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
2735 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
2741 cf_dir=`echo $INSTALL | sed -e 's%/[^/]*$%%'`
2742 test -z "$cf_dir" && cf_dir=.
2743 INSTALL=`cd $cf_dir && pwd`/`echo $INSTALL | sed -e 's%^.*/%%'`
2747 echo "$as_me:2747: checking if you want to install stripped executables" >&5
2748 echo $ECHO_N "checking if you want to install stripped executables... $ECHO_C" >&6
2750 # Check whether --enable-stripping or --disable-stripping was given.
2751 if test "${enable_stripping+set}" = set; then
2752 enableval="$enable_stripping"
2753 test "$enableval" != no && enableval=yes
2754 if test "$enableval" != "yes" ; then
2764 echo "$as_me:2764: result: $with_stripping" >&5
2765 echo "${ECHO_T}$with_stripping" >&6
2767 if test "$with_stripping" = yes
2774 : ${INSTALL:=install}
2775 echo "$as_me:2775: checking if install accepts -p option" >&5
2776 echo $ECHO_N "checking if install accepts -p option... $ECHO_C" >&6
2777 if test "${cf_cv_install_p+set}" = set; then
2778 echo $ECHO_N "(cached) $ECHO_C" >&6
2785 if $INSTALL -p conftest.in conftest.out 2>/dev/null
2787 if test -f conftest.out/conftest.in
2789 test conftest.in -nt conftest.out/conftest.in 2>conftest.err && \
2790 test conftest.out/conftest.in -nt conftest.in 2>conftest.err
2791 if test -s conftest.err
2806 echo "$as_me:2806: result: $cf_cv_install_p" >&5
2807 echo "${ECHO_T}$cf_cv_install_p" >&6
2809 echo "$as_me:2809: checking if install needs to be told about ownership" >&5
2810 echo $ECHO_N "checking if install needs to be told about ownership... $ECHO_C" >&6
2811 case `$ac_config_guess` in
2820 echo "$as_me:2820: result: $with_install_o" >&5
2821 echo "${ECHO_T}$with_install_o" >&6
2822 if test "x$with_install_o" = xyes
2824 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'`
2829 for ac_prog in lint cppcheck splint
2831 # Extract the first word of "$ac_prog", so it can be a program name with args.
2832 set dummy $ac_prog; ac_word=$2
2833 echo "$as_me:2833: checking for $ac_word" >&5
2834 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2835 if test "${ac_cv_prog_LINT+set}" = set; then
2836 echo $ECHO_N "(cached) $ECHO_C" >&6
2838 if test -n "$LINT"; then
2839 ac_cv_prog_LINT="$LINT" # Let the user override the test.
2841 ac_save_IFS=$IFS; IFS=$ac_path_separator
2843 for ac_dir in $ac_dummy; do
2845 test -z "$ac_dir" && ac_dir=.
2846 $as_executable_p "$ac_dir/$ac_word" || continue
2847 ac_cv_prog_LINT="$ac_prog"
2848 echo "$as_me:2848: found $ac_dir/$ac_word" >&5
2854 LINT=$ac_cv_prog_LINT
2855 if test -n "$LINT"; then
2856 echo "$as_me:2856: result: $LINT" >&5
2857 echo "${ECHO_T}$LINT" >&6
2859 echo "$as_me:2859: result: no" >&5
2860 echo "${ECHO_T}no" >&6
2863 test -n "$LINT" && break
2867 (xcppcheck|x*/cppcheck)
2868 test -z "$LINT_OPTS" && LINT_OPTS="--enable=all"
2872 echo "$as_me:2872: checking if filesystem supports mixed-case filenames" >&5
2873 echo $ECHO_N "checking if filesystem supports mixed-case filenames... $ECHO_C" >&6
2874 if test "${cf_cv_mixedcase+set}" = set; then
2875 echo $ECHO_N "(cached) $ECHO_C" >&6
2878 if test "$cross_compiling" = yes ; then
2879 case $target_alias in
2880 (*-os2-emx*|*-msdosdjgpp*|*-cygwin*|*-msys*|*-mingw*|*-uwin*|darwin*)
2888 rm -f conftest CONFTEST
2890 if test -f CONFTEST ; then
2895 rm -f conftest CONFTEST
2899 echo "$as_me:2899: result: $cf_cv_mixedcase" >&5
2900 echo "${ECHO_T}$cf_cv_mixedcase" >&6
2901 test "$cf_cv_mixedcase" = yes &&
2902 cat >>confdefs.h <<\EOF
2903 #define MIXEDCASE_FILENAMES 1
2906 for ac_prog in exctags ctags
2908 # Extract the first word of "$ac_prog", so it can be a program name with args.
2909 set dummy $ac_prog; ac_word=$2
2910 echo "$as_me:2910: checking for $ac_word" >&5
2911 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2912 if test "${ac_cv_prog_CTAGS+set}" = set; then
2913 echo $ECHO_N "(cached) $ECHO_C" >&6
2915 if test -n "$CTAGS"; then
2916 ac_cv_prog_CTAGS="$CTAGS" # Let the user override the test.
2918 ac_save_IFS=$IFS; IFS=$ac_path_separator
2920 for ac_dir in $ac_dummy; do
2922 test -z "$ac_dir" && ac_dir=.
2923 $as_executable_p "$ac_dir/$ac_word" || continue
2924 ac_cv_prog_CTAGS="$ac_prog"
2925 echo "$as_me:2925: found $ac_dir/$ac_word" >&5
2931 CTAGS=$ac_cv_prog_CTAGS
2932 if test -n "$CTAGS"; then
2933 echo "$as_me:2933: result: $CTAGS" >&5
2934 echo "${ECHO_T}$CTAGS" >&6
2936 echo "$as_me:2936: result: no" >&5
2937 echo "${ECHO_T}no" >&6
2940 test -n "$CTAGS" && break
2943 for ac_prog in exetags etags
2945 # Extract the first word of "$ac_prog", so it can be a program name with args.
2946 set dummy $ac_prog; ac_word=$2
2947 echo "$as_me:2947: checking for $ac_word" >&5
2948 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2949 if test "${ac_cv_prog_ETAGS+set}" = set; then
2950 echo $ECHO_N "(cached) $ECHO_C" >&6
2952 if test -n "$ETAGS"; then
2953 ac_cv_prog_ETAGS="$ETAGS" # Let the user override the test.
2955 ac_save_IFS=$IFS; IFS=$ac_path_separator
2957 for ac_dir in $ac_dummy; do
2959 test -z "$ac_dir" && ac_dir=.
2960 $as_executable_p "$ac_dir/$ac_word" || continue
2961 ac_cv_prog_ETAGS="$ac_prog"
2962 echo "$as_me:2962: found $ac_dir/$ac_word" >&5
2968 ETAGS=$ac_cv_prog_ETAGS
2969 if test -n "$ETAGS"; then
2970 echo "$as_me:2970: result: $ETAGS" >&5
2971 echo "${ECHO_T}$ETAGS" >&6
2973 echo "$as_me:2973: result: no" >&5
2974 echo "${ECHO_T}no" >&6
2977 test -n "$ETAGS" && break
2980 # Extract the first word of "${CTAGS:-ctags}", so it can be a program name with args.
2981 set dummy ${CTAGS:-ctags}; ac_word=$2
2982 echo "$as_me:2982: checking for $ac_word" >&5
2983 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2984 if test "${ac_cv_prog_MAKE_LOWER_TAGS+set}" = set; then
2985 echo $ECHO_N "(cached) $ECHO_C" >&6
2987 if test -n "$MAKE_LOWER_TAGS"; then
2988 ac_cv_prog_MAKE_LOWER_TAGS="$MAKE_LOWER_TAGS" # Let the user override the test.
2990 ac_save_IFS=$IFS; IFS=$ac_path_separator
2992 for ac_dir in $ac_dummy; do
2994 test -z "$ac_dir" && ac_dir=.
2995 $as_executable_p "$ac_dir/$ac_word" || continue
2996 ac_cv_prog_MAKE_LOWER_TAGS="yes"
2997 echo "$as_me:2997: found $ac_dir/$ac_word" >&5
3001 test -z "$ac_cv_prog_MAKE_LOWER_TAGS" && ac_cv_prog_MAKE_LOWER_TAGS="no"
3004 MAKE_LOWER_TAGS=$ac_cv_prog_MAKE_LOWER_TAGS
3005 if test -n "$MAKE_LOWER_TAGS"; then
3006 echo "$as_me:3006: result: $MAKE_LOWER_TAGS" >&5
3007 echo "${ECHO_T}$MAKE_LOWER_TAGS" >&6
3009 echo "$as_me:3009: result: no" >&5
3010 echo "${ECHO_T}no" >&6
3013 if test "$cf_cv_mixedcase" = yes ; then
3014 # Extract the first word of "${ETAGS:-etags}", so it can be a program name with args.
3015 set dummy ${ETAGS:-etags}; ac_word=$2
3016 echo "$as_me:3016: checking for $ac_word" >&5
3017 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3018 if test "${ac_cv_prog_MAKE_UPPER_TAGS+set}" = set; then
3019 echo $ECHO_N "(cached) $ECHO_C" >&6
3021 if test -n "$MAKE_UPPER_TAGS"; then
3022 ac_cv_prog_MAKE_UPPER_TAGS="$MAKE_UPPER_TAGS" # Let the user override the test.
3024 ac_save_IFS=$IFS; IFS=$ac_path_separator
3026 for ac_dir in $ac_dummy; do
3028 test -z "$ac_dir" && ac_dir=.
3029 $as_executable_p "$ac_dir/$ac_word" || continue
3030 ac_cv_prog_MAKE_UPPER_TAGS="yes"
3031 echo "$as_me:3031: found $ac_dir/$ac_word" >&5
3035 test -z "$ac_cv_prog_MAKE_UPPER_TAGS" && ac_cv_prog_MAKE_UPPER_TAGS="no"
3038 MAKE_UPPER_TAGS=$ac_cv_prog_MAKE_UPPER_TAGS
3039 if test -n "$MAKE_UPPER_TAGS"; then
3040 echo "$as_me:3040: result: $MAKE_UPPER_TAGS" >&5
3041 echo "${ECHO_T}$MAKE_UPPER_TAGS" >&6
3043 echo "$as_me:3043: result: no" >&5
3044 echo "${ECHO_T}no" >&6
3051 if test "$MAKE_UPPER_TAGS" = yes ; then
3057 if test "$MAKE_LOWER_TAGS" = yes ; then
3063 echo "$as_me:3063: checking if -lm needed for math functions" >&5
3064 echo $ECHO_N "checking if -lm needed for math functions... $ECHO_C" >&6
3065 if test "${cf_cv_need_libm+set}" = set; then
3066 echo $ECHO_N "(cached) $ECHO_C" >&6
3069 cat >conftest.$ac_ext <<_ACEOF
3070 #line 3070 "configure"
3071 #include "confdefs.h"
3080 double x = rand(); printf("result = %g\n", pow(sin(x),x))
3085 rm -f conftest.$ac_objext conftest$ac_exeext
3086 if { (eval echo "$as_me:3086: \"$ac_link\"") >&5
3087 (eval $ac_link) 2>&5
3089 echo "$as_me:3089: \$? = $ac_status" >&5
3090 (exit $ac_status); } &&
3091 { ac_try='test -s conftest$ac_exeext'
3092 { (eval echo "$as_me:3092: \"$ac_try\"") >&5
3095 echo "$as_me:3095: \$? = $ac_status" >&5
3096 (exit $ac_status); }; }; then
3099 echo "$as_me: failed program was:" >&5
3100 cat conftest.$ac_ext >&5
3103 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
3105 echo "$as_me:3105: result: $cf_cv_need_libm" >&5
3106 echo "${ECHO_T}$cf_cv_need_libm" >&6
3107 if test "$cf_cv_need_libm" = yes
3115 CC_SHARED_OPTS=unknown
3116 CPPFLAGS="$CPPFLAGS"
3118 DFT_OBJ_SUBDIR=`pwd|sed -e's:.*/::'`
3119 DFT_UPR_MODEL="NORMAL"
3132 PACKAGE="ncurses-examples"
3138 TINFO_LIBS='$(LIBS_CURSES)'
3139 cf_cv_abi_version=""
3140 cf_cv_rel_version=""
3146 if ( test "$GCC" = yes || test "$GXX" = yes )
3148 cat > conftest.i <<EOF
3150 #define GCC_PRINTF 0
3155 #ifndef GCC_NORETURN
3156 #define GCC_NORETURN /* nothing */
3159 #define GCC_UNUSED /* nothing */
3162 if test "$GCC" = yes
3164 { echo "$as_me:3164: checking for $CC __attribute__ directives..." >&5
3165 echo "$as_me: checking for $CC __attribute__ directives..." >&6;}
3166 cat > conftest.$ac_ext <<EOF
3167 #line 3167 "${as_me:-configure}"
3168 #include "confdefs.h"
3169 #include "conftest.h"
3170 #include "conftest.i"
3172 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
3174 #define GCC_PRINTFLIKE(fmt,var) /*nothing*/
3177 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
3179 #define GCC_SCANFLIKE(fmt,var) /*nothing*/
3181 extern void wow(char *,...) GCC_SCANFLIKE(1,2);
3182 extern void oops(char *,...) GCC_PRINTFLIKE(1,2) GCC_NORETURN;
3183 extern void foo(void) GCC_NORETURN;
3184 int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { (void)argc; (void)argv; return 0; }
3186 cf_printf_attribute=no
3187 cf_scanf_attribute=no
3188 for cf_attribute in scanf printf unused noreturn
3191 cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
3193 cf_directive="__attribute__(($cf_attribute))"
3194 echo "checking for $CC $cf_directive" 1>&5
3196 case $cf_attribute in
3198 cf_printf_attribute=yes
3199 cat >conftest.h <<EOF
3200 #define GCC_$cf_ATTRIBUTE 1
3204 cf_scanf_attribute=yes
3205 cat >conftest.h <<EOF
3206 #define GCC_$cf_ATTRIBUTE 1
3210 cat >conftest.h <<EOF
3211 #define GCC_$cf_ATTRIBUTE $cf_directive
3216 if { (eval echo "$as_me:3216: \"$ac_compile\"") >&5
3217 (eval $ac_compile) 2>&5
3219 echo "$as_me:3219: \$? = $ac_status" >&5
3220 (exit $ac_status); }; then
3221 test -n "$verbose" && echo "$as_me:3221: result: ... $cf_attribute" >&5
3222 echo "${ECHO_T}... $cf_attribute" >&6
3223 cat conftest.h >>confdefs.h
3224 case $cf_attribute in
3227 cat >>confdefs.h <<EOF
3228 #define GCC_NORETURN $cf_directive
3233 cf_value='/* nothing */'
3234 if test "$cf_printf_attribute" != no ; then
3235 cf_value='__attribute__((format(printf,fmt,var)))'
3237 cat >>confdefs.h <<\EOF
3238 #define GCC_PRINTF 1
3243 cat >>confdefs.h <<EOF
3244 #define GCC_PRINTFLIKE(fmt,var) $cf_value
3249 cf_value='/* nothing */'
3250 if test "$cf_scanf_attribute" != no ; then
3251 cf_value='__attribute__((format(scanf,fmt,var)))'
3253 cat >>confdefs.h <<\EOF
3259 cat >>confdefs.h <<EOF
3260 #define GCC_SCANFLIKE(fmt,var) $cf_value
3266 cat >>confdefs.h <<EOF
3267 #define GCC_UNUSED $cf_directive
3275 fgrep define conftest.i >>confdefs.h
3280 echo "$as_me:3280: checking if you want to work around bogus compiler/loader warnings" >&5
3281 echo $ECHO_N "checking if you want to work around bogus compiler/loader warnings... $ECHO_C" >&6
3283 # Check whether --enable-string-hacks or --disable-string-hacks was given.
3284 if test "${enable_string_hacks+set}" = set; then
3285 enableval="$enable_string_hacks"
3286 with_string_hacks=$enableval
3288 with_string_hacks=no
3290 echo "$as_me:3290: result: $with_string_hacks" >&5
3291 echo "${ECHO_T}$with_string_hacks" >&6
3293 if test "x$with_string_hacks" = "xyes"; then
3295 cat >>confdefs.h <<\EOF
3296 #define USE_STRING_HACKS 1
3299 { echo "$as_me:3299: WARNING: enabling string-hacks to work around bogus compiler/loader warnings" >&5
3300 echo "$as_me: WARNING: enabling string-hacks to work around bogus compiler/loader warnings" >&2;}
3301 echo "$as_me:3301: checking for strlcat" >&5
3302 echo $ECHO_N "checking for strlcat... $ECHO_C" >&6
3303 if test "${ac_cv_func_strlcat+set}" = set; then
3304 echo $ECHO_N "(cached) $ECHO_C" >&6
3306 cat >conftest.$ac_ext <<_ACEOF
3307 #line 3307 "configure"
3308 #include "confdefs.h"
3309 #define strlcat autoconf_temporary
3310 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
3317 /* We use char because int might match the return type of a gcc2
3318 builtin and then its argument prototype would still apply. */
3319 char strlcat (void);
3325 /* The GNU C library defines stubs for functions which it implements
3326 to always fail with ENOSYS. Some functions are actually named
3327 something starting with __ and the normal name is an alias. */
3328 #if defined (__stub_strlcat) || defined (__stub___strlcat)
3329 #error found stub for strlcat
3337 rm -f conftest.$ac_objext conftest$ac_exeext
3338 if { (eval echo "$as_me:3338: \"$ac_link\"") >&5
3339 (eval $ac_link) 2>&5
3341 echo "$as_me:3341: \$? = $ac_status" >&5
3342 (exit $ac_status); } &&
3343 { ac_try='test -s conftest$ac_exeext'
3344 { (eval echo "$as_me:3344: \"$ac_try\"") >&5
3347 echo "$as_me:3347: \$? = $ac_status" >&5
3348 (exit $ac_status); }; }; then
3349 ac_cv_func_strlcat=yes
3351 echo "$as_me: failed program was:" >&5
3352 cat conftest.$ac_ext >&5
3353 ac_cv_func_strlcat=no
3355 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
3357 echo "$as_me:3357: result: $ac_cv_func_strlcat" >&5
3358 echo "${ECHO_T}$ac_cv_func_strlcat" >&6
3359 if test $ac_cv_func_strlcat = yes; then
3361 cat >>confdefs.h <<\EOF
3362 #define HAVE_STRLCAT 1
3367 echo "$as_me:3367: checking for strlcat in -lbsd" >&5
3368 echo $ECHO_N "checking for strlcat in -lbsd... $ECHO_C" >&6
3369 if test "${ac_cv_lib_bsd_strlcat+set}" = set; then
3370 echo $ECHO_N "(cached) $ECHO_C" >&6
3372 ac_check_lib_save_LIBS=$LIBS
3374 cat >conftest.$ac_ext <<_ACEOF
3375 #line 3375 "configure"
3376 #include "confdefs.h"
3378 /* Override any gcc2 internal prototype to avoid an error. */
3382 /* We use char because int might match the return type of a gcc2
3383 builtin and then its argument prototype would still apply. */
3393 rm -f conftest.$ac_objext conftest$ac_exeext
3394 if { (eval echo "$as_me:3394: \"$ac_link\"") >&5
3395 (eval $ac_link) 2>&5
3397 echo "$as_me:3397: \$? = $ac_status" >&5
3398 (exit $ac_status); } &&
3399 { ac_try='test -s conftest$ac_exeext'
3400 { (eval echo "$as_me:3400: \"$ac_try\"") >&5
3403 echo "$as_me:3403: \$? = $ac_status" >&5
3404 (exit $ac_status); }; }; then
3405 ac_cv_lib_bsd_strlcat=yes
3407 echo "$as_me: failed program was:" >&5
3408 cat conftest.$ac_ext >&5
3409 ac_cv_lib_bsd_strlcat=no
3411 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
3412 LIBS=$ac_check_lib_save_LIBS
3414 echo "$as_me:3414: result: $ac_cv_lib_bsd_strlcat" >&5
3415 echo "${ECHO_T}$ac_cv_lib_bsd_strlcat" >&6
3416 if test $ac_cv_lib_bsd_strlcat = yes; then
3421 for cf_add_1lib in -lbsd; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
3423 for cf_add_1lib in $cf_add_0lib; do
3424 for cf_add_2lib in $cf_add_libs; do
3425 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
3430 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
3434 for ac_header in bsd/string.h
3436 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
3437 echo "$as_me:3437: checking for $ac_header" >&5
3438 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3439 if eval "test \"\${$as_ac_Header+set}\" = set"; then
3440 echo $ECHO_N "(cached) $ECHO_C" >&6
3442 cat >conftest.$ac_ext <<_ACEOF
3443 #line 3443 "configure"
3444 #include "confdefs.h"
3445 #include <$ac_header>
3447 if { (eval echo "$as_me:3447: \"$ac_cpp conftest.$ac_ext\"") >&5
3448 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3450 egrep -v '^ *\+' conftest.er1 >conftest.err
3452 cat conftest.err >&5
3453 echo "$as_me:3453: \$? = $ac_status" >&5
3454 (exit $ac_status); } >/dev/null; then
3455 if test -s conftest.err; then
3456 ac_cpp_err=$ac_c_preproc_warn_flag
3463 if test -z "$ac_cpp_err"; then
3464 eval "$as_ac_Header=yes"
3466 echo "$as_me: failed program was:" >&5
3467 cat conftest.$ac_ext >&5
3468 eval "$as_ac_Header=no"
3470 rm -f conftest.err conftest.$ac_ext
3472 echo "$as_me:3472: result: `eval echo '${'$as_ac_Header'}'`" >&5
3473 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
3474 if test `eval echo '${'$as_ac_Header'}'` = yes; then
3475 cat >>confdefs.h <<EOF
3476 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
3482 cat >>confdefs.h <<\EOF
3483 #define HAVE_STRLCAT 1
3490 for ac_func in strlcpy snprintf
3492 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
3493 echo "$as_me:3493: checking for $ac_func" >&5
3494 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
3495 if eval "test \"\${$as_ac_var+set}\" = set"; then
3496 echo $ECHO_N "(cached) $ECHO_C" >&6
3498 cat >conftest.$ac_ext <<_ACEOF
3499 #line 3499 "configure"
3500 #include "confdefs.h"
3501 #define $ac_func autoconf_temporary
3502 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
3509 /* We use char because int might match the return type of a gcc2
3510 builtin and then its argument prototype would still apply. */
3511 char $ac_func (void);
3517 /* The GNU C library defines stubs for functions which it implements
3518 to always fail with ENOSYS. Some functions are actually named
3519 something starting with __ and the normal name is an alias. */
3520 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3521 #error found stub for $ac_func
3529 rm -f conftest.$ac_objext conftest$ac_exeext
3530 if { (eval echo "$as_me:3530: \"$ac_link\"") >&5
3531 (eval $ac_link) 2>&5
3533 echo "$as_me:3533: \$? = $ac_status" >&5
3534 (exit $ac_status); } &&
3535 { ac_try='test -s conftest$ac_exeext'
3536 { (eval echo "$as_me:3536: \"$ac_try\"") >&5
3539 echo "$as_me:3539: \$? = $ac_status" >&5
3540 (exit $ac_status); }; }; then
3541 eval "$as_ac_var=yes"
3543 echo "$as_me: failed program was:" >&5
3544 cat conftest.$ac_ext >&5
3545 eval "$as_ac_var=no"
3547 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
3549 echo "$as_me:3549: result: `eval echo '${'$as_ac_var'}'`" >&5
3550 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
3551 if test `eval echo '${'$as_ac_var'}'` = yes; then
3552 cat >>confdefs.h <<EOF
3553 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
3561 echo "$as_me:3561: checking if the POSIX test-macros are already defined" >&5
3562 echo $ECHO_N "checking if the POSIX test-macros are already defined... $ECHO_C" >&6
3563 if test "${cf_cv_posix_visible+set}" = set; then
3564 echo $ECHO_N "(cached) $ECHO_C" >&6
3567 cat >conftest.$ac_ext <<_ACEOF
3568 #line 3568 "configure"
3569 #include "confdefs.h"
3575 #if defined(__POSIX_VISIBLE) && ((__POSIX_VISIBLE - 0L) > 0) \
3576 && defined(__XSI_VISIBLE) && ((__XSI_VISIBLE - 0L) > 0) \
3577 && defined(__BSD_VISIBLE) && ((__BSD_VISIBLE - 0L) > 0) \
3578 && defined(__ISO_C_VISIBLE) && ((__ISO_C_VISIBLE - 0L) > 0)
3579 #error conflicting symbols found
3586 rm -f conftest.$ac_objext
3587 if { (eval echo "$as_me:3587: \"$ac_compile\"") >&5
3588 (eval $ac_compile) 2>&5
3590 echo "$as_me:3590: \$? = $ac_status" >&5
3591 (exit $ac_status); } &&
3592 { ac_try='test -s conftest.$ac_objext'
3593 { (eval echo "$as_me:3593: \"$ac_try\"") >&5
3596 echo "$as_me:3596: \$? = $ac_status" >&5
3597 (exit $ac_status); }; }; then
3598 cf_cv_posix_visible=no
3600 echo "$as_me: failed program was:" >&5
3601 cat conftest.$ac_ext >&5
3602 cf_cv_posix_visible=yes
3604 rm -f conftest.$ac_objext conftest.$ac_ext
3607 echo "$as_me:3607: result: $cf_cv_posix_visible" >&5
3608 echo "${ECHO_T}$cf_cv_posix_visible" >&6
3610 if test "$cf_cv_posix_visible" = no; then
3613 cf_POSIX_C_SOURCE=199506L
3618 cf_xopen_source="-D_ALL_SOURCE"
3624 cf_xopen_source="-D_APPLE_C_SOURCE"
3627 cf_xopen_source="-D_DARWIN_C_SOURCE"
3630 (freebsd*|dragonfly*|midnightbsd*)
3631 # 5.x headers associate
3632 # _XOPEN_SOURCE=600 with _POSIX_C_SOURCE=200112L
3633 # _XOPEN_SOURCE=500 with _POSIX_C_SOURCE=199506L
3634 cf_POSIX_C_SOURCE=200112L
3636 cf_xopen_source="-D_BSD_TYPES -D__BSD_VISIBLE -D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
3639 cf_xopen_source="-D_HPUX_SOURCE -D_XOPEN_SOURCE=500"
3642 cf_xopen_source="-D_HPUX_SOURCE"
3645 cf_xopen_source="-D_SGI_SOURCE"
3648 (linux*|uclinux*|gnu*|mint*|k*bsd*-gnu|cygwin)
3650 cf_gnu_xopen_source=$cf_XOPEN_SOURCE
3652 echo "$as_me:3652: checking if this is the GNU C library" >&5
3653 echo $ECHO_N "checking if this is the GNU C library... $ECHO_C" >&6
3654 if test "${cf_cv_gnu_library+set}" = set; then
3655 echo $ECHO_N "(cached) $ECHO_C" >&6
3658 cat >conftest.$ac_ext <<_ACEOF
3659 #line 3659 "configure"
3660 #include "confdefs.h"
3661 #include <sys/types.h>
3666 #if __GLIBC__ > 0 && __GLIBC_MINOR__ >= 0
3668 #elif __NEWLIB__ > 0 && __NEWLIB_MINOR__ >= 0
3671 # error not GNU C library
3677 rm -f conftest.$ac_objext
3678 if { (eval echo "$as_me:3678: \"$ac_compile\"") >&5
3679 (eval $ac_compile) 2>&5
3681 echo "$as_me:3681: \$? = $ac_status" >&5
3682 (exit $ac_status); } &&
3683 { ac_try='test -s conftest.$ac_objext'
3684 { (eval echo "$as_me:3684: \"$ac_try\"") >&5
3687 echo "$as_me:3687: \$? = $ac_status" >&5
3688 (exit $ac_status); }; }; then
3689 cf_cv_gnu_library=yes
3691 echo "$as_me: failed program was:" >&5
3692 cat conftest.$ac_ext >&5
3693 cf_cv_gnu_library=no
3695 rm -f conftest.$ac_objext conftest.$ac_ext
3698 echo "$as_me:3698: result: $cf_cv_gnu_library" >&5
3699 echo "${ECHO_T}$cf_cv_gnu_library" >&6
3701 if test x$cf_cv_gnu_library = xyes; then
3703 # With glibc 2.19 (13 years after this check was begun), _DEFAULT_SOURCE
3704 # was changed to help a little. newlib incorporated the change about 4
3706 echo "$as_me:3706: checking if _DEFAULT_SOURCE can be used as a basis" >&5
3707 echo $ECHO_N "checking if _DEFAULT_SOURCE can be used as a basis... $ECHO_C" >&6
3708 if test "${cf_cv_gnu_library_219+set}" = set; then
3709 echo $ECHO_N "(cached) $ECHO_C" >&6
3714 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
3715 CPPFLAGS="${CPPFLAGS}-D_DEFAULT_SOURCE"
3717 cat >conftest.$ac_ext <<_ACEOF
3718 #line 3718 "configure"
3719 #include "confdefs.h"
3720 #include <sys/types.h>
3725 #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 19) || (__GLIBC__ > 2)
3727 #elif (__NEWLIB__ == 2 && __NEWLIB_MINOR__ >= 4) || (__GLIBC__ > 3)
3730 # error GNU C library __GLIBC__.__GLIBC_MINOR__ is too old
3736 rm -f conftest.$ac_objext
3737 if { (eval echo "$as_me:3737: \"$ac_compile\"") >&5
3738 (eval $ac_compile) 2>&5
3740 echo "$as_me:3740: \$? = $ac_status" >&5
3741 (exit $ac_status); } &&
3742 { ac_try='test -s conftest.$ac_objext'
3743 { (eval echo "$as_me:3743: \"$ac_try\"") >&5
3746 echo "$as_me:3746: \$? = $ac_status" >&5
3747 (exit $ac_status); }; }; then
3748 cf_cv_gnu_library_219=yes
3750 echo "$as_me: failed program was:" >&5
3751 cat conftest.$ac_ext >&5
3752 cf_cv_gnu_library_219=no
3754 rm -f conftest.$ac_objext conftest.$ac_ext
3758 echo "$as_me:3758: result: $cf_cv_gnu_library_219" >&5
3759 echo "${ECHO_T}$cf_cv_gnu_library_219" >&6
3761 if test "x$cf_cv_gnu_library_219" = xyes; then
3763 echo "$as_me:3763: checking if _XOPEN_SOURCE=$cf_gnu_xopen_source works with _DEFAULT_SOURCE" >&5
3764 echo $ECHO_N "checking if _XOPEN_SOURCE=$cf_gnu_xopen_source works with _DEFAULT_SOURCE... $ECHO_C" >&6
3765 if test "${cf_cv_gnu_dftsrc_219+set}" = set; then
3766 echo $ECHO_N "(cached) $ECHO_C" >&6
3772 cf_new_extra_cppflags=
3774 for cf_add_cflags in -D_DEFAULT_SOURCE -D_XOPEN_SOURCE=$cf_gnu_xopen_source
3776 case $cf_fix_cppflags in
3778 case $cf_add_cflags in
3779 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
3780 case $cf_add_cflags in
3782 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3784 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
3785 && test -z "${cf_tst_cflags}" \
3786 && cf_fix_cppflags=yes
3788 if test $cf_fix_cppflags = yes ; then
3790 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3791 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3794 elif test "${cf_tst_cflags}" = "\"'" ; then
3796 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3797 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3807 case $cf_add_cflags in
3809 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3811 CPPFLAGS=`echo "$CPPFLAGS" | \
3812 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3813 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3818 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
3819 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
3826 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
3827 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
3834 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3835 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3837 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
3839 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
3840 && test -z "${cf_tst_cflags}" \
3841 && cf_fix_cppflags=no
3846 if test -n "$cf_new_cflags" ; then
3848 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
3849 CFLAGS="${CFLAGS}$cf_new_cflags"
3853 if test -n "$cf_new_cppflags" ; then
3855 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
3856 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
3860 if test -n "$cf_new_extra_cppflags" ; then
3862 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
3863 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
3867 cat >conftest.$ac_ext <<_ACEOF
3868 #line 3868 "configure"
3869 #include "confdefs.h"
3872 #include <sys/types.h>
3878 #if (_XOPEN_SOURCE >= $cf_gnu_xopen_source) && (MB_LEN_MAX > 1)
3881 # error GNU C library is too old
3887 rm -f conftest.$ac_objext
3888 if { (eval echo "$as_me:3888: \"$ac_compile\"") >&5
3889 (eval $ac_compile) 2>&5
3891 echo "$as_me:3891: \$? = $ac_status" >&5
3892 (exit $ac_status); } &&
3893 { ac_try='test -s conftest.$ac_objext'
3894 { (eval echo "$as_me:3894: \"$ac_try\"") >&5
3897 echo "$as_me:3897: \$? = $ac_status" >&5
3898 (exit $ac_status); }; }; then
3899 cf_cv_gnu_dftsrc_219=yes
3901 echo "$as_me: failed program was:" >&5
3902 cat conftest.$ac_ext >&5
3903 cf_cv_gnu_dftsrc_219=no
3905 rm -f conftest.$ac_objext conftest.$ac_ext
3908 echo "$as_me:3908: result: $cf_cv_gnu_dftsrc_219" >&5
3909 echo "${ECHO_T}$cf_cv_gnu_dftsrc_219" >&6
3910 test "x$cf_cv_gnu_dftsrc_219" = "xyes" || CPPFLAGS="$cf_save"
3912 cf_cv_gnu_dftsrc_219=maybe
3915 if test "x$cf_cv_gnu_dftsrc_219" != xyes; then
3917 echo "$as_me:3917: checking if we must define _GNU_SOURCE" >&5
3918 echo $ECHO_N "checking if we must define _GNU_SOURCE... $ECHO_C" >&6
3919 if test "${cf_cv_gnu_source+set}" = set; then
3920 echo $ECHO_N "(cached) $ECHO_C" >&6
3923 cat >conftest.$ac_ext <<_ACEOF
3924 #line 3924 "configure"
3925 #include "confdefs.h"
3926 #include <sys/types.h>
3931 #ifndef _XOPEN_SOURCE
3932 #error expected _XOPEN_SOURCE to be defined
3938 rm -f conftest.$ac_objext
3939 if { (eval echo "$as_me:3939: \"$ac_compile\"") >&5
3940 (eval $ac_compile) 2>&5
3942 echo "$as_me:3942: \$? = $ac_status" >&5
3943 (exit $ac_status); } &&
3944 { ac_try='test -s conftest.$ac_objext'
3945 { (eval echo "$as_me:3945: \"$ac_try\"") >&5
3948 echo "$as_me:3948: \$? = $ac_status" >&5
3949 (exit $ac_status); }; }; then
3952 echo "$as_me: failed program was:" >&5
3953 cat conftest.$ac_ext >&5
3959 cf_new_extra_cppflags=
3961 for cf_add_cflags in -D_GNU_SOURCE
3963 case $cf_fix_cppflags in
3965 case $cf_add_cflags in
3966 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
3967 case $cf_add_cflags in
3969 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3971 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
3972 && test -z "${cf_tst_cflags}" \
3973 && cf_fix_cppflags=yes
3975 if test $cf_fix_cppflags = yes ; then
3977 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3978 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3981 elif test "${cf_tst_cflags}" = "\"'" ; then
3983 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3984 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3994 case $cf_add_cflags in
3996 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3998 CPPFLAGS=`echo "$CPPFLAGS" | \
3999 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4000 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4005 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4006 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4013 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4014 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4021 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4022 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4024 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
4026 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4027 && test -z "${cf_tst_cflags}" \
4028 && cf_fix_cppflags=no
4033 if test -n "$cf_new_cflags" ; then
4035 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4036 CFLAGS="${CFLAGS}$cf_new_cflags"
4040 if test -n "$cf_new_cppflags" ; then
4042 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4043 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4047 if test -n "$cf_new_extra_cppflags" ; then
4049 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4050 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4054 cat >conftest.$ac_ext <<_ACEOF
4055 #line 4055 "configure"
4056 #include "confdefs.h"
4057 #include <sys/types.h>
4062 #ifdef _XOPEN_SOURCE
4063 #error expected _XOPEN_SOURCE to be undefined
4069 rm -f conftest.$ac_objext
4070 if { (eval echo "$as_me:4070: \"$ac_compile\"") >&5
4071 (eval $ac_compile) 2>&5
4073 echo "$as_me:4073: \$? = $ac_status" >&5
4074 (exit $ac_status); } &&
4075 { ac_try='test -s conftest.$ac_objext'
4076 { (eval echo "$as_me:4076: \"$ac_try\"") >&5
4079 echo "$as_me:4079: \$? = $ac_status" >&5
4080 (exit $ac_status); }; }; then
4083 echo "$as_me: failed program was:" >&5
4084 cat conftest.$ac_ext >&5
4085 cf_cv_gnu_source=yes
4087 rm -f conftest.$ac_objext conftest.$ac_ext
4091 rm -f conftest.$ac_objext conftest.$ac_ext
4094 echo "$as_me:4094: result: $cf_cv_gnu_source" >&5
4095 echo "${ECHO_T}$cf_cv_gnu_source" >&6
4097 if test "$cf_cv_gnu_source" = yes
4099 echo "$as_me:4099: checking if we should also define _DEFAULT_SOURCE" >&5
4100 echo $ECHO_N "checking if we should also define _DEFAULT_SOURCE... $ECHO_C" >&6
4101 if test "${cf_cv_default_source+set}" = set; then
4102 echo $ECHO_N "(cached) $ECHO_C" >&6
4105 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4106 CPPFLAGS="${CPPFLAGS}-D_GNU_SOURCE"
4108 cat >conftest.$ac_ext <<_ACEOF
4109 #line 4109 "configure"
4110 #include "confdefs.h"
4111 #include <sys/types.h>
4116 #ifdef _DEFAULT_SOURCE
4117 #error expected _DEFAULT_SOURCE to be undefined
4123 rm -f conftest.$ac_objext
4124 if { (eval echo "$as_me:4124: \"$ac_compile\"") >&5
4125 (eval $ac_compile) 2>&5
4127 echo "$as_me:4127: \$? = $ac_status" >&5
4128 (exit $ac_status); } &&
4129 { ac_try='test -s conftest.$ac_objext'
4130 { (eval echo "$as_me:4130: \"$ac_try\"") >&5
4133 echo "$as_me:4133: \$? = $ac_status" >&5
4134 (exit $ac_status); }; }; then
4135 cf_cv_default_source=no
4137 echo "$as_me: failed program was:" >&5
4138 cat conftest.$ac_ext >&5
4139 cf_cv_default_source=yes
4141 rm -f conftest.$ac_objext conftest.$ac_ext
4144 echo "$as_me:4144: result: $cf_cv_default_source" >&5
4145 echo "${ECHO_T}$cf_cv_default_source" >&6
4146 if test "$cf_cv_default_source" = yes
4149 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4150 CPPFLAGS="${CPPFLAGS}-D_DEFAULT_SOURCE"
4160 cf_xopen_source="-D_NETBSD_SOURCE" # POSIX.1-2001 features are ifdef'd with this...
4163 # setting _XOPEN_SOURCE or _POSIX_SOURCE breaks <sys/select.h> and other headers which use u_int / u_short types
4166 if test "$cf_cv_posix_visible" = no; then
4168 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
4170 cf_save_CFLAGS="$CFLAGS"
4171 cf_save_CPPFLAGS="$CPPFLAGS"
4173 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
4174 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
4175 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
4177 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
4178 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
4179 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
4181 echo "$as_me:4181: checking if we should define _POSIX_C_SOURCE" >&5
4182 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
4183 if test "${cf_cv_posix_c_source+set}" = set; then
4184 echo $ECHO_N "(cached) $ECHO_C" >&6
4187 echo "${as_me:-configure}:4187: testing if the symbol is already defined go no further ..." 1>&5
4189 cat >conftest.$ac_ext <<_ACEOF
4190 #line 4190 "configure"
4191 #include "confdefs.h"
4192 #include <sys/types.h>
4197 #ifndef _POSIX_C_SOURCE
4204 rm -f conftest.$ac_objext
4205 if { (eval echo "$as_me:4205: \"$ac_compile\"") >&5
4206 (eval $ac_compile) 2>&5
4208 echo "$as_me:4208: \$? = $ac_status" >&5
4209 (exit $ac_status); } &&
4210 { ac_try='test -s conftest.$ac_objext'
4211 { (eval echo "$as_me:4211: \"$ac_try\"") >&5
4214 echo "$as_me:4214: \$? = $ac_status" >&5
4215 (exit $ac_status); }; }; then
4216 cf_cv_posix_c_source=no
4218 echo "$as_me: failed program was:" >&5
4219 cat conftest.$ac_ext >&5
4220 cf_want_posix_source=no
4221 case .$cf_POSIX_C_SOURCE in
4223 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
4226 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
4227 cf_want_posix_source=yes
4230 cf_want_posix_source=yes
4233 if test "$cf_want_posix_source" = yes ; then
4234 cat >conftest.$ac_ext <<_ACEOF
4235 #line 4235 "configure"
4236 #include "confdefs.h"
4237 #include <sys/types.h>
4242 #ifdef _POSIX_SOURCE
4249 rm -f conftest.$ac_objext
4250 if { (eval echo "$as_me:4250: \"$ac_compile\"") >&5
4251 (eval $ac_compile) 2>&5
4253 echo "$as_me:4253: \$? = $ac_status" >&5
4254 (exit $ac_status); } &&
4255 { ac_try='test -s conftest.$ac_objext'
4256 { (eval echo "$as_me:4256: \"$ac_try\"") >&5
4259 echo "$as_me:4259: \$? = $ac_status" >&5
4260 (exit $ac_status); }; }; then
4263 echo "$as_me: failed program was:" >&5
4264 cat conftest.$ac_ext >&5
4265 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
4267 rm -f conftest.$ac_objext conftest.$ac_ext
4270 echo "${as_me:-configure}:4270: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
4272 CFLAGS="$cf_trim_CFLAGS"
4273 CPPFLAGS="$cf_trim_CPPFLAGS"
4275 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4276 CPPFLAGS="${CPPFLAGS}$cf_cv_posix_c_source"
4278 echo "${as_me:-configure}:4278: testing if the second compile does not leave our definition intact error ..." 1>&5
4280 cat >conftest.$ac_ext <<_ACEOF
4281 #line 4281 "configure"
4282 #include "confdefs.h"
4283 #include <sys/types.h>
4288 #ifndef _POSIX_C_SOURCE
4295 rm -f conftest.$ac_objext
4296 if { (eval echo "$as_me:4296: \"$ac_compile\"") >&5
4297 (eval $ac_compile) 2>&5
4299 echo "$as_me:4299: \$? = $ac_status" >&5
4300 (exit $ac_status); } &&
4301 { ac_try='test -s conftest.$ac_objext'
4302 { (eval echo "$as_me:4302: \"$ac_try\"") >&5
4305 echo "$as_me:4305: \$? = $ac_status" >&5
4306 (exit $ac_status); }; }; then
4309 echo "$as_me: failed program was:" >&5
4310 cat conftest.$ac_ext >&5
4311 cf_cv_posix_c_source=no
4313 rm -f conftest.$ac_objext conftest.$ac_ext
4314 CFLAGS="$cf_save_CFLAGS"
4315 CPPFLAGS="$cf_save_CPPFLAGS"
4318 rm -f conftest.$ac_objext conftest.$ac_ext
4321 echo "$as_me:4321: result: $cf_cv_posix_c_source" >&5
4322 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
4324 if test "$cf_cv_posix_c_source" != no ; then
4325 CFLAGS="$cf_trim_CFLAGS"
4326 CPPFLAGS="$cf_trim_CPPFLAGS"
4331 cf_new_extra_cppflags=
4333 for cf_add_cflags in $cf_cv_posix_c_source
4335 case $cf_fix_cppflags in
4337 case $cf_add_cflags in
4338 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4339 case $cf_add_cflags in
4341 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4343 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4344 && test -z "${cf_tst_cflags}" \
4345 && cf_fix_cppflags=yes
4347 if test $cf_fix_cppflags = yes ; then
4349 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4350 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4353 elif test "${cf_tst_cflags}" = "\"'" ; then
4355 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4356 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4366 case $cf_add_cflags in
4368 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4370 CPPFLAGS=`echo "$CPPFLAGS" | \
4371 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4372 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4377 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4378 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4385 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4386 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4393 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4394 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4396 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
4398 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4399 && test -z "${cf_tst_cflags}" \
4400 && cf_fix_cppflags=no
4405 if test -n "$cf_new_cflags" ; then
4407 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4408 CFLAGS="${CFLAGS}$cf_new_cflags"
4412 if test -n "$cf_new_cppflags" ; then
4414 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4415 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4419 if test -n "$cf_new_extra_cppflags" ; then
4421 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4422 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4428 fi # cf_cv_posix_visible
4432 cf_xopen_source="-D_NETBSD_SOURCE" # setting _XOPEN_SOURCE breaks IPv6 for lynx on NetBSD 1.6, breaks xterm, is not needed for ncursesw
4435 # setting _XOPEN_SOURCE lower than 500 breaks g++ compile with wchar.h, needed for ncursesw
4436 cf_xopen_source="-D_BSD_SOURCE"
4440 # setting _XOPEN_SOURCE breaks xterm on OpenBSD 2.8, is not needed for ncursesw
4443 cf_xopen_source="-D_OSF_SOURCE"
4446 cf_xopen_source="-D_QNX_SOURCE"
4449 # setting _XOPEN_SOURCE breaks Lynx on SCO Unix / OpenServer
4452 cf_xopen_source="-D__EXTENSIONS__"
4453 cf_cv_xopen_source=broken
4455 (sysv4.2uw2.*) # Novell/SCO UnixWare 2.x (tested on 2.1.2)
4461 echo "$as_me:4461: checking if we should define _XOPEN_SOURCE" >&5
4462 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
4463 if test "${cf_cv_xopen_source+set}" = set; then
4464 echo $ECHO_N "(cached) $ECHO_C" >&6
4467 cat >conftest.$ac_ext <<_ACEOF
4468 #line 4468 "configure"
4469 #include "confdefs.h"
4473 #include <sys/types.h>
4479 #ifndef _XOPEN_SOURCE
4486 rm -f conftest.$ac_objext
4487 if { (eval echo "$as_me:4487: \"$ac_compile\"") >&5
4488 (eval $ac_compile) 2>&5
4490 echo "$as_me:4490: \$? = $ac_status" >&5
4491 (exit $ac_status); } &&
4492 { ac_try='test -s conftest.$ac_objext'
4493 { (eval echo "$as_me:4493: \"$ac_try\"") >&5
4496 echo "$as_me:4496: \$? = $ac_status" >&5
4497 (exit $ac_status); }; }; then
4498 cf_cv_xopen_source=no
4500 echo "$as_me: failed program was:" >&5
4501 cat conftest.$ac_ext >&5
4504 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4505 CPPFLAGS="${CPPFLAGS}-D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
4507 cat >conftest.$ac_ext <<_ACEOF
4508 #line 4508 "configure"
4509 #include "confdefs.h"
4513 #include <sys/types.h>
4519 #ifdef _XOPEN_SOURCE
4526 rm -f conftest.$ac_objext
4527 if { (eval echo "$as_me:4527: \"$ac_compile\"") >&5
4528 (eval $ac_compile) 2>&5
4530 echo "$as_me:4530: \$? = $ac_status" >&5
4531 (exit $ac_status); } &&
4532 { ac_try='test -s conftest.$ac_objext'
4533 { (eval echo "$as_me:4533: \"$ac_try\"") >&5
4536 echo "$as_me:4536: \$? = $ac_status" >&5
4537 (exit $ac_status); }; }; then
4538 cf_cv_xopen_source=no
4540 echo "$as_me: failed program was:" >&5
4541 cat conftest.$ac_ext >&5
4542 cf_cv_xopen_source=$cf_XOPEN_SOURCE
4544 rm -f conftest.$ac_objext conftest.$ac_ext
4548 rm -f conftest.$ac_objext conftest.$ac_ext
4551 echo "$as_me:4551: result: $cf_cv_xopen_source" >&5
4552 echo "${ECHO_T}$cf_cv_xopen_source" >&6
4554 if test "$cf_cv_xopen_source" != no ; then
4556 CFLAGS=`echo "$CFLAGS" | \
4557 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
4558 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
4560 CPPFLAGS=`echo "$CPPFLAGS" | \
4561 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
4562 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
4564 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
4569 cf_new_extra_cppflags=
4571 for cf_add_cflags in $cf_temp_xopen_source
4573 case $cf_fix_cppflags in
4575 case $cf_add_cflags in
4576 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4577 case $cf_add_cflags in
4579 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4581 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4582 && test -z "${cf_tst_cflags}" \
4583 && cf_fix_cppflags=yes
4585 if test $cf_fix_cppflags = yes ; then
4587 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4588 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4591 elif test "${cf_tst_cflags}" = "\"'" ; then
4593 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4594 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4604 case $cf_add_cflags in
4606 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4608 CPPFLAGS=`echo "$CPPFLAGS" | \
4609 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4610 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4615 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4616 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4623 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4624 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4631 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4632 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4634 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
4636 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4637 && test -z "${cf_tst_cflags}" \
4638 && cf_fix_cppflags=no
4643 if test -n "$cf_new_cflags" ; then
4645 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4646 CFLAGS="${CFLAGS}$cf_new_cflags"
4650 if test -n "$cf_new_cppflags" ; then
4652 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4653 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4657 if test -n "$cf_new_extra_cppflags" ; then
4659 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4660 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4666 if test "$cf_cv_posix_visible" = no; then
4668 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
4670 cf_save_CFLAGS="$CFLAGS"
4671 cf_save_CPPFLAGS="$CPPFLAGS"
4673 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
4674 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
4675 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
4677 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
4678 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
4679 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
4681 echo "$as_me:4681: checking if we should define _POSIX_C_SOURCE" >&5
4682 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
4683 if test "${cf_cv_posix_c_source+set}" = set; then
4684 echo $ECHO_N "(cached) $ECHO_C" >&6
4687 echo "${as_me:-configure}:4687: testing if the symbol is already defined go no further ..." 1>&5
4689 cat >conftest.$ac_ext <<_ACEOF
4690 #line 4690 "configure"
4691 #include "confdefs.h"
4692 #include <sys/types.h>
4697 #ifndef _POSIX_C_SOURCE
4704 rm -f conftest.$ac_objext
4705 if { (eval echo "$as_me:4705: \"$ac_compile\"") >&5
4706 (eval $ac_compile) 2>&5
4708 echo "$as_me:4708: \$? = $ac_status" >&5
4709 (exit $ac_status); } &&
4710 { ac_try='test -s conftest.$ac_objext'
4711 { (eval echo "$as_me:4711: \"$ac_try\"") >&5
4714 echo "$as_me:4714: \$? = $ac_status" >&5
4715 (exit $ac_status); }; }; then
4716 cf_cv_posix_c_source=no
4718 echo "$as_me: failed program was:" >&5
4719 cat conftest.$ac_ext >&5
4720 cf_want_posix_source=no
4721 case .$cf_POSIX_C_SOURCE in
4723 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
4726 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
4727 cf_want_posix_source=yes
4730 cf_want_posix_source=yes
4733 if test "$cf_want_posix_source" = yes ; then
4734 cat >conftest.$ac_ext <<_ACEOF
4735 #line 4735 "configure"
4736 #include "confdefs.h"
4737 #include <sys/types.h>
4742 #ifdef _POSIX_SOURCE
4749 rm -f conftest.$ac_objext
4750 if { (eval echo "$as_me:4750: \"$ac_compile\"") >&5
4751 (eval $ac_compile) 2>&5
4753 echo "$as_me:4753: \$? = $ac_status" >&5
4754 (exit $ac_status); } &&
4755 { ac_try='test -s conftest.$ac_objext'
4756 { (eval echo "$as_me:4756: \"$ac_try\"") >&5
4759 echo "$as_me:4759: \$? = $ac_status" >&5
4760 (exit $ac_status); }; }; then
4763 echo "$as_me: failed program was:" >&5
4764 cat conftest.$ac_ext >&5
4765 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
4767 rm -f conftest.$ac_objext conftest.$ac_ext
4770 echo "${as_me:-configure}:4770: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
4772 CFLAGS="$cf_trim_CFLAGS"
4773 CPPFLAGS="$cf_trim_CPPFLAGS"
4775 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4776 CPPFLAGS="${CPPFLAGS}$cf_cv_posix_c_source"
4778 echo "${as_me:-configure}:4778: testing if the second compile does not leave our definition intact error ..." 1>&5
4780 cat >conftest.$ac_ext <<_ACEOF
4781 #line 4781 "configure"
4782 #include "confdefs.h"
4783 #include <sys/types.h>
4788 #ifndef _POSIX_C_SOURCE
4795 rm -f conftest.$ac_objext
4796 if { (eval echo "$as_me:4796: \"$ac_compile\"") >&5
4797 (eval $ac_compile) 2>&5
4799 echo "$as_me:4799: \$? = $ac_status" >&5
4800 (exit $ac_status); } &&
4801 { ac_try='test -s conftest.$ac_objext'
4802 { (eval echo "$as_me:4802: \"$ac_try\"") >&5
4805 echo "$as_me:4805: \$? = $ac_status" >&5
4806 (exit $ac_status); }; }; then
4809 echo "$as_me: failed program was:" >&5
4810 cat conftest.$ac_ext >&5
4811 cf_cv_posix_c_source=no
4813 rm -f conftest.$ac_objext conftest.$ac_ext
4814 CFLAGS="$cf_save_CFLAGS"
4815 CPPFLAGS="$cf_save_CPPFLAGS"
4818 rm -f conftest.$ac_objext conftest.$ac_ext
4821 echo "$as_me:4821: result: $cf_cv_posix_c_source" >&5
4822 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
4824 if test "$cf_cv_posix_c_source" != no ; then
4825 CFLAGS="$cf_trim_CFLAGS"
4826 CPPFLAGS="$cf_trim_CPPFLAGS"
4831 cf_new_extra_cppflags=
4833 for cf_add_cflags in $cf_cv_posix_c_source
4835 case $cf_fix_cppflags in
4837 case $cf_add_cflags in
4838 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4839 case $cf_add_cflags in
4841 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4843 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4844 && test -z "${cf_tst_cflags}" \
4845 && cf_fix_cppflags=yes
4847 if test $cf_fix_cppflags = yes ; then
4849 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4850 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4853 elif test "${cf_tst_cflags}" = "\"'" ; then
4855 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4856 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4866 case $cf_add_cflags in
4868 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4870 CPPFLAGS=`echo "$CPPFLAGS" | \
4871 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4872 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4877 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4878 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4885 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4886 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4893 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4894 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4896 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
4898 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4899 && test -z "${cf_tst_cflags}" \
4900 && cf_fix_cppflags=no
4905 if test -n "$cf_new_cflags" ; then
4907 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4908 CFLAGS="${CFLAGS}$cf_new_cflags"
4912 if test -n "$cf_new_cppflags" ; then
4914 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4915 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4919 if test -n "$cf_new_extra_cppflags" ; then
4921 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4922 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4928 fi # cf_cv_posix_visible
4933 if test -n "$cf_xopen_source" ; then
4938 cf_new_extra_cppflags=
4940 for cf_add_cflags in $cf_xopen_source
4942 case $cf_fix_cppflags in
4944 case $cf_add_cflags in
4945 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4946 case $cf_add_cflags in
4948 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4950 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4951 && test -z "${cf_tst_cflags}" \
4952 && cf_fix_cppflags=yes
4954 if test $cf_fix_cppflags = yes ; then
4956 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4957 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4960 elif test "${cf_tst_cflags}" = "\"'" ; then
4962 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4963 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4973 case $cf_add_cflags in
4975 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4977 CPPFLAGS=`echo "$CPPFLAGS" | \
4978 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4979 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4984 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4985 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4992 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4993 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
5000 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5001 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5003 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
5005 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
5006 && test -z "${cf_tst_cflags}" \
5007 && cf_fix_cppflags=no
5012 if test -n "$cf_new_cflags" ; then
5013 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
5015 echo "${as_me:-configure}:5015: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
5017 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
5018 CFLAGS="${CFLAGS}$cf_new_cflags"
5022 if test -n "$cf_new_cppflags" ; then
5023 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
5025 echo "${as_me:-configure}:5025: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
5027 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5028 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
5032 if test -n "$cf_new_extra_cppflags" ; then
5033 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
5035 echo "${as_me:-configure}:5035: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
5037 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
5038 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
5044 if test -n "$cf_XOPEN_SOURCE" && test -z "$cf_cv_xopen_source" ; then
5045 echo "$as_me:5045: checking if _XOPEN_SOURCE really is set" >&5
5046 echo $ECHO_N "checking if _XOPEN_SOURCE really is set... $ECHO_C" >&6
5047 cat >conftest.$ac_ext <<_ACEOF
5048 #line 5048 "configure"
5049 #include "confdefs.h"
5055 #ifndef _XOPEN_SOURCE
5062 rm -f conftest.$ac_objext
5063 if { (eval echo "$as_me:5063: \"$ac_compile\"") >&5
5064 (eval $ac_compile) 2>&5
5066 echo "$as_me:5066: \$? = $ac_status" >&5
5067 (exit $ac_status); } &&
5068 { ac_try='test -s conftest.$ac_objext'
5069 { (eval echo "$as_me:5069: \"$ac_try\"") >&5
5072 echo "$as_me:5072: \$? = $ac_status" >&5
5073 (exit $ac_status); }; }; then
5074 cf_XOPEN_SOURCE_set=yes
5076 echo "$as_me: failed program was:" >&5
5077 cat conftest.$ac_ext >&5
5078 cf_XOPEN_SOURCE_set=no
5080 rm -f conftest.$ac_objext conftest.$ac_ext
5081 echo "$as_me:5081: result: $cf_XOPEN_SOURCE_set" >&5
5082 echo "${ECHO_T}$cf_XOPEN_SOURCE_set" >&6
5083 if test $cf_XOPEN_SOURCE_set = yes
5085 cat >conftest.$ac_ext <<_ACEOF
5086 #line 5086 "configure"
5087 #include "confdefs.h"
5093 #if (_XOPEN_SOURCE - 0) < $cf_XOPEN_SOURCE
5100 rm -f conftest.$ac_objext
5101 if { (eval echo "$as_me:5101: \"$ac_compile\"") >&5
5102 (eval $ac_compile) 2>&5
5104 echo "$as_me:5104: \$? = $ac_status" >&5
5105 (exit $ac_status); } &&
5106 { ac_try='test -s conftest.$ac_objext'
5107 { (eval echo "$as_me:5107: \"$ac_try\"") >&5
5110 echo "$as_me:5110: \$? = $ac_status" >&5
5111 (exit $ac_status); }; }; then
5112 cf_XOPEN_SOURCE_set_ok=yes
5114 echo "$as_me: failed program was:" >&5
5115 cat conftest.$ac_ext >&5
5116 cf_XOPEN_SOURCE_set_ok=no
5118 rm -f conftest.$ac_objext conftest.$ac_ext
5119 if test $cf_XOPEN_SOURCE_set_ok = no
5121 { echo "$as_me:5121: WARNING: _XOPEN_SOURCE is lower than requested" >&5
5122 echo "$as_me: WARNING: _XOPEN_SOURCE is lower than requested" >&2;}
5126 echo "$as_me:5126: checking if we should define _XOPEN_SOURCE" >&5
5127 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
5128 if test "${cf_cv_xopen_source+set}" = set; then
5129 echo $ECHO_N "(cached) $ECHO_C" >&6
5132 cat >conftest.$ac_ext <<_ACEOF
5133 #line 5133 "configure"
5134 #include "confdefs.h"
5138 #include <sys/types.h>
5144 #ifndef _XOPEN_SOURCE
5151 rm -f conftest.$ac_objext
5152 if { (eval echo "$as_me:5152: \"$ac_compile\"") >&5
5153 (eval $ac_compile) 2>&5
5155 echo "$as_me:5155: \$? = $ac_status" >&5
5156 (exit $ac_status); } &&
5157 { ac_try='test -s conftest.$ac_objext'
5158 { (eval echo "$as_me:5158: \"$ac_try\"") >&5
5161 echo "$as_me:5161: \$? = $ac_status" >&5
5162 (exit $ac_status); }; }; then
5163 cf_cv_xopen_source=no
5165 echo "$as_me: failed program was:" >&5
5166 cat conftest.$ac_ext >&5
5169 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5170 CPPFLAGS="${CPPFLAGS}-D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
5172 cat >conftest.$ac_ext <<_ACEOF
5173 #line 5173 "configure"
5174 #include "confdefs.h"
5178 #include <sys/types.h>
5184 #ifdef _XOPEN_SOURCE
5191 rm -f conftest.$ac_objext
5192 if { (eval echo "$as_me:5192: \"$ac_compile\"") >&5
5193 (eval $ac_compile) 2>&5
5195 echo "$as_me:5195: \$? = $ac_status" >&5
5196 (exit $ac_status); } &&
5197 { ac_try='test -s conftest.$ac_objext'
5198 { (eval echo "$as_me:5198: \"$ac_try\"") >&5
5201 echo "$as_me:5201: \$? = $ac_status" >&5
5202 (exit $ac_status); }; }; then
5203 cf_cv_xopen_source=no
5205 echo "$as_me: failed program was:" >&5
5206 cat conftest.$ac_ext >&5
5207 cf_cv_xopen_source=$cf_XOPEN_SOURCE
5209 rm -f conftest.$ac_objext conftest.$ac_ext
5213 rm -f conftest.$ac_objext conftest.$ac_ext
5216 echo "$as_me:5216: result: $cf_cv_xopen_source" >&5
5217 echo "${ECHO_T}$cf_cv_xopen_source" >&6
5219 if test "$cf_cv_xopen_source" != no ; then
5221 CFLAGS=`echo "$CFLAGS" | \
5222 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
5223 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
5225 CPPFLAGS=`echo "$CPPFLAGS" | \
5226 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
5227 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
5229 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
5234 cf_new_extra_cppflags=
5236 for cf_add_cflags in $cf_temp_xopen_source
5238 case $cf_fix_cppflags in
5240 case $cf_add_cflags in
5241 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
5242 case $cf_add_cflags in
5244 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
5246 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
5247 && test -z "${cf_tst_cflags}" \
5248 && cf_fix_cppflags=yes
5250 if test $cf_fix_cppflags = yes ; then
5252 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5253 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5256 elif test "${cf_tst_cflags}" = "\"'" ; then
5258 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5259 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5269 case $cf_add_cflags in
5271 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
5273 CPPFLAGS=`echo "$CPPFLAGS" | \
5274 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
5275 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
5280 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
5281 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
5288 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
5289 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
5296 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5297 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5299 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
5301 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
5302 && test -z "${cf_tst_cflags}" \
5303 && cf_fix_cppflags=no
5308 if test -n "$cf_new_cflags" ; then
5310 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
5311 CFLAGS="${CFLAGS}$cf_new_cflags"
5315 if test -n "$cf_new_cppflags" ; then
5317 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5318 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
5322 if test -n "$cf_new_extra_cppflags" ; then
5324 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
5325 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
5333 fi # cf_cv_posix_visible
5335 echo "$as_me:5335: checking for signal global datatype" >&5
5336 echo $ECHO_N "checking for signal global datatype... $ECHO_C" >&6
5337 if test "${cf_cv_sig_atomic_t+set}" = set; then
5338 echo $ECHO_N "(cached) $ECHO_C" >&6
5342 "volatile sig_atomic_t" \
5346 cat >conftest.$ac_ext <<_ACEOF
5347 #line 5347 "configure"
5348 #include "confdefs.h"
5350 #include <sys/types.h>
5356 static void handler(int sig)
5364 signal(SIGINT, handler);
5370 rm -f conftest.$ac_objext
5371 if { (eval echo "$as_me:5371: \"$ac_compile\"") >&5
5372 (eval $ac_compile) 2>&5
5374 echo "$as_me:5374: \$? = $ac_status" >&5
5375 (exit $ac_status); } &&
5376 { ac_try='test -s conftest.$ac_objext'
5377 { (eval echo "$as_me:5377: \"$ac_try\"") >&5
5380 echo "$as_me:5380: \$? = $ac_status" >&5
5381 (exit $ac_status); }; }; then
5382 cf_cv_sig_atomic_t=$cf_type
5384 echo "$as_me: failed program was:" >&5
5385 cat conftest.$ac_ext >&5
5386 cf_cv_sig_atomic_t=no
5388 rm -f conftest.$ac_objext conftest.$ac_ext
5389 test "$cf_cv_sig_atomic_t" != no && break
5394 echo "$as_me:5394: result: $cf_cv_sig_atomic_t" >&5
5395 echo "${ECHO_T}$cf_cv_sig_atomic_t" >&6
5396 test "$cf_cv_sig_atomic_t" != no &&
5397 cat >>confdefs.h <<EOF
5398 #define SIG_ATOMIC_T $cf_cv_sig_atomic_t
5401 # Work around breakage on OS X
5403 echo "$as_me:5403: checking if SIGWINCH is defined" >&5
5404 echo $ECHO_N "checking if SIGWINCH is defined... $ECHO_C" >&6
5405 if test "${cf_cv_define_sigwinch+set}" = set; then
5406 echo $ECHO_N "(cached) $ECHO_C" >&6
5409 cat >conftest.$ac_ext <<_ACEOF
5410 #line 5410 "configure"
5411 #include "confdefs.h"
5413 #include <sys/types.h>
5414 #include <sys/signal.h>
5419 int x = SIGWINCH; (void)x
5424 rm -f conftest.$ac_objext
5425 if { (eval echo "$as_me:5425: \"$ac_compile\"") >&5
5426 (eval $ac_compile) 2>&5
5428 echo "$as_me:5428: \$? = $ac_status" >&5
5429 (exit $ac_status); } &&
5430 { ac_try='test -s conftest.$ac_objext'
5431 { (eval echo "$as_me:5431: \"$ac_try\"") >&5
5434 echo "$as_me:5434: \$? = $ac_status" >&5
5435 (exit $ac_status); }; }; then
5436 cf_cv_define_sigwinch=yes
5438 echo "$as_me: failed program was:" >&5
5439 cat conftest.$ac_ext >&5
5440 cat >conftest.$ac_ext <<_ACEOF
5441 #line 5441 "configure"
5442 #include "confdefs.h"
5444 #undef _XOPEN_SOURCE
5445 #undef _POSIX_SOURCE
5446 #undef _POSIX_C_SOURCE
5447 #include <sys/types.h>
5448 #include <sys/signal.h>
5453 int x = SIGWINCH; (void)x
5458 rm -f conftest.$ac_objext
5459 if { (eval echo "$as_me:5459: \"$ac_compile\"") >&5
5460 (eval $ac_compile) 2>&5
5462 echo "$as_me:5462: \$? = $ac_status" >&5
5463 (exit $ac_status); } &&
5464 { ac_try='test -s conftest.$ac_objext'
5465 { (eval echo "$as_me:5465: \"$ac_try\"") >&5
5468 echo "$as_me:5468: \$? = $ac_status" >&5
5469 (exit $ac_status); }; }; then
5470 cf_cv_define_sigwinch=maybe
5472 echo "$as_me: failed program was:" >&5
5473 cat conftest.$ac_ext >&5
5474 cf_cv_define_sigwinch=no
5476 rm -f conftest.$ac_objext conftest.$ac_ext
5479 rm -f conftest.$ac_objext conftest.$ac_ext
5482 echo "$as_me:5482: result: $cf_cv_define_sigwinch" >&5
5483 echo "${ECHO_T}$cf_cv_define_sigwinch" >&6
5485 if test "$cf_cv_define_sigwinch" = maybe ; then
5486 echo "$as_me:5486: checking for actual SIGWINCH definition" >&5
5487 echo $ECHO_N "checking for actual SIGWINCH definition... $ECHO_C" >&6
5488 if test "${cf_cv_fixup_sigwinch+set}" = set; then
5489 echo $ECHO_N "(cached) $ECHO_C" >&6
5492 cf_cv_fixup_sigwinch=unknown
5494 while test $cf_sigwinch != 1
5496 cat >conftest.$ac_ext <<_ACEOF
5497 #line 5497 "configure"
5498 #include "confdefs.h"
5500 #undef _XOPEN_SOURCE
5501 #undef _POSIX_SOURCE
5502 #undef _POSIX_C_SOURCE
5503 #include <sys/types.h>
5504 #include <sys/signal.h>
5510 #if SIGWINCH != $cf_sigwinch
5513 int x = SIGWINCH; (void)x
5518 rm -f conftest.$ac_objext
5519 if { (eval echo "$as_me:5519: \"$ac_compile\"") >&5
5520 (eval $ac_compile) 2>&5
5522 echo "$as_me:5522: \$? = $ac_status" >&5
5523 (exit $ac_status); } &&
5524 { ac_try='test -s conftest.$ac_objext'
5525 { (eval echo "$as_me:5525: \"$ac_try\"") >&5
5528 echo "$as_me:5528: \$? = $ac_status" >&5
5529 (exit $ac_status); }; }; then
5530 cf_cv_fixup_sigwinch=$cf_sigwinch
5533 echo "$as_me: failed program was:" >&5
5534 cat conftest.$ac_ext >&5
5536 rm -f conftest.$ac_objext conftest.$ac_ext
5538 cf_sigwinch=`expr $cf_sigwinch - 1`
5542 echo "$as_me:5542: result: $cf_cv_fixup_sigwinch" >&5
5543 echo "${ECHO_T}$cf_cv_fixup_sigwinch" >&6
5545 if test "$cf_cv_fixup_sigwinch" != unknown ; then
5546 CPPFLAGS="$CPPFLAGS -DSIGWINCH=$cf_cv_fixup_sigwinch"
5550 # Checks for CODESET support.
5552 echo "$as_me:5552: checking for nl_langinfo and CODESET" >&5
5553 echo $ECHO_N "checking for nl_langinfo and CODESET... $ECHO_C" >&6
5554 if test "${am_cv_langinfo_codeset+set}" = set; then
5555 echo $ECHO_N "(cached) $ECHO_C" >&6
5557 cat >conftest.$ac_ext <<_ACEOF
5558 #line 5558 "configure"
5559 #include "confdefs.h"
5560 #include <langinfo.h>
5564 char* cs = nl_langinfo(CODESET); (void)cs
5569 rm -f conftest.$ac_objext conftest$ac_exeext
5570 if { (eval echo "$as_me:5570: \"$ac_link\"") >&5
5571 (eval $ac_link) 2>&5
5573 echo "$as_me:5573: \$? = $ac_status" >&5
5574 (exit $ac_status); } &&
5575 { ac_try='test -s conftest$ac_exeext'
5576 { (eval echo "$as_me:5576: \"$ac_try\"") >&5
5579 echo "$as_me:5579: \$? = $ac_status" >&5
5580 (exit $ac_status); }; }; then
5581 am_cv_langinfo_codeset=yes
5583 echo "$as_me: failed program was:" >&5
5584 cat conftest.$ac_ext >&5
5585 am_cv_langinfo_codeset=no
5587 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5590 echo "$as_me:5590: result: $am_cv_langinfo_codeset" >&5
5591 echo "${ECHO_T}$am_cv_langinfo_codeset" >&6
5592 if test $am_cv_langinfo_codeset = yes; then
5594 cat >>confdefs.h <<\EOF
5595 #define HAVE_LANGINFO_CODESET 1
5600 echo "$as_me:5600: checking if you want to use pkg-config" >&5
5601 echo $ECHO_N "checking if you want to use pkg-config... $ECHO_C" >&6
5603 # Check whether --with-pkg-config or --without-pkg-config was given.
5604 if test "${with_pkg_config+set}" = set; then
5605 withval="$with_pkg_config"
5606 cf_pkg_config=$withval
5610 echo "$as_me:5610: result: $cf_pkg_config" >&5
5611 echo "${ECHO_T}$cf_pkg_config" >&6
5613 case $cf_pkg_config in
5619 if test -n "$ac_tool_prefix"; then
5620 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
5621 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
5622 echo "$as_me:5622: checking for $ac_word" >&5
5623 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5624 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then
5625 echo $ECHO_N "(cached) $ECHO_C" >&6
5629 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
5632 ac_save_IFS=$IFS; IFS=$ac_path_separator
5634 for ac_dir in $ac_dummy; do
5636 test -z "$ac_dir" && ac_dir=.
5637 if $as_executable_p "$ac_dir/$ac_word"; then
5638 ac_cv_path_PKG_CONFIG="$ac_dir/$ac_word"
5639 echo "$as_me:5639: found $ac_dir/$ac_word" >&5
5647 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
5649 if test -n "$PKG_CONFIG"; then
5650 echo "$as_me:5650: result: $PKG_CONFIG" >&5
5651 echo "${ECHO_T}$PKG_CONFIG" >&6
5653 echo "$as_me:5653: result: no" >&5
5654 echo "${ECHO_T}no" >&6
5658 if test -z "$ac_cv_path_PKG_CONFIG"; then
5659 ac_pt_PKG_CONFIG=$PKG_CONFIG
5660 # Extract the first word of "pkg-config", so it can be a program name with args.
5661 set dummy pkg-config; ac_word=$2
5662 echo "$as_me:5662: checking for $ac_word" >&5
5663 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5664 if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then
5665 echo $ECHO_N "(cached) $ECHO_C" >&6
5667 case $ac_pt_PKG_CONFIG in
5669 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
5672 ac_save_IFS=$IFS; IFS=$ac_path_separator
5674 for ac_dir in $ac_dummy; do
5676 test -z "$ac_dir" && ac_dir=.
5677 if $as_executable_p "$ac_dir/$ac_word"; then
5678 ac_cv_path_ac_pt_PKG_CONFIG="$ac_dir/$ac_word"
5679 echo "$as_me:5679: found $ac_dir/$ac_word" >&5
5684 test -z "$ac_cv_path_ac_pt_PKG_CONFIG" && ac_cv_path_ac_pt_PKG_CONFIG="none"
5688 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
5690 if test -n "$ac_pt_PKG_CONFIG"; then
5691 echo "$as_me:5691: result: $ac_pt_PKG_CONFIG" >&5
5692 echo "${ECHO_T}$ac_pt_PKG_CONFIG" >&6
5694 echo "$as_me:5694: result: no" >&5
5695 echo "${ECHO_T}no" >&6
5698 PKG_CONFIG=$ac_pt_PKG_CONFIG
5700 PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
5709 test -z "$PKG_CONFIG" && PKG_CONFIG=none
5710 if test "$PKG_CONFIG" != none ; then
5712 if test "x$prefix" != xNONE; then
5713 cf_path_syntax="$prefix"
5715 cf_path_syntax="$ac_default_prefix"
5718 case ".$PKG_CONFIG" in
5723 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
5725 (.\${*prefix}*|.\${*dir}*)
5726 eval PKG_CONFIG="$PKG_CONFIG"
5727 case ".$PKG_CONFIG" in
5729 PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
5734 PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
5737 { { echo "$as_me:5737: error: expected a pathname, not \"$PKG_CONFIG\"" >&5
5738 echo "$as_me: error: expected a pathname, not \"$PKG_CONFIG\"" >&2;}
5739 { (exit 1); exit 1; }; }
5743 elif test "x$cf_pkg_config" != xno ; then
5744 { echo "$as_me:5744: WARNING: pkg-config is not installed" >&5
5745 echo "$as_me: WARNING: pkg-config is not installed" >&2;}
5748 echo "$as_me:5748: checking if you want to see long compiling messages" >&5
5749 echo $ECHO_N "checking if you want to see long compiling messages... $ECHO_C" >&6
5751 # Check whether --enable-echo or --disable-echo was given.
5752 if test "${enable_echo+set}" = set; then
5753 enableval="$enable_echo"
5754 test "$enableval" != no && enableval=yes
5755 if test "$enableval" != "yes" ; then
5758 ECHO_LD='@echo linking $@;'
5759 RULE_CC='@echo compiling $<'
5760 SHOW_CC='@echo compiling $@'
5782 echo "$as_me:5782: result: $enableval" >&5
5783 echo "${ECHO_T}$enableval" >&6
5785 echo "$as_me:5785: checking for ncurses wrap-prefix" >&5
5786 echo $ECHO_N "checking for ncurses wrap-prefix... $ECHO_C" >&6
5788 # Check whether --with-ncurses-wrap-prefix or --without-ncurses-wrap-prefix was given.
5789 if test "${with_ncurses_wrap_prefix+set}" = set; then
5790 withval="$with_ncurses_wrap_prefix"
5791 NCURSES_WRAP_PREFIX=$withval
5793 NCURSES_WRAP_PREFIX=_nc_
5795 echo "$as_me:5795: result: $NCURSES_WRAP_PREFIX" >&5
5796 echo "${ECHO_T}$NCURSES_WRAP_PREFIX" >&6
5798 echo "$as_me:5798: checking if you want to check for wide-character functions" >&5
5799 echo $ECHO_N "checking if you want to check for wide-character functions... $ECHO_C" >&6
5801 # Check whether --enable-widec or --disable-widec was given.
5802 if test "${enable_widec+set}" = set; then
5803 enableval="$enable_widec"
5804 test "$enableval" != no && enableval=yes
5805 if test "$enableval" != "yes" ; then
5815 echo "$as_me:5815: result: $cf_enable_widec" >&5
5816 echo "${ECHO_T}$cf_enable_widec" >&6
5818 echo "$as_me:5818: checking for specific curses-directory" >&5
5819 echo $ECHO_N "checking for specific curses-directory... $ECHO_C" >&6
5821 # Check whether --with-curses-dir or --without-curses-dir was given.
5822 if test "${with_curses_dir+set}" = set; then
5823 withval="$with_curses_dir"
5824 cf_cv_curses_dir=$withval
5828 echo "$as_me:5828: result: $cf_cv_curses_dir" >&5
5829 echo "${ECHO_T}$cf_cv_curses_dir" >&6
5831 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
5834 if test "x$prefix" != xNONE; then
5835 cf_path_syntax="$prefix"
5837 cf_path_syntax="$ac_default_prefix"
5845 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
5847 (.\${*prefix}*|.\${*dir}*)
5848 eval withval="$withval"
5851 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
5856 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
5859 { { echo "$as_me:5859: error: expected a pathname, not \"$withval\"" >&5
5860 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
5861 { (exit 1); exit 1; }; }
5865 if test -d "$cf_cv_curses_dir"
5868 if test -n "$cf_cv_curses_dir/include" ; then
5869 for cf_add_incdir in $cf_cv_curses_dir/include
5871 while test $cf_add_incdir != /usr/include
5873 if test -d $cf_add_incdir
5876 if test -n "$CFLAGS$CPPFLAGS" ; then
5877 # a loop is needed to ensure we can add subdirs of existing dirs
5878 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
5879 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
5880 cf_have_incdir=yes; break
5885 if test "$cf_have_incdir" = no ; then
5886 if test "$cf_add_incdir" = /usr/local/include ; then
5887 if test "$GCC" = yes
5889 cf_save_CPPFLAGS=$CPPFLAGS
5891 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5892 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
5894 cat >conftest.$ac_ext <<_ACEOF
5895 #line 5895 "configure"
5896 #include "confdefs.h"
5906 rm -f conftest.$ac_objext
5907 if { (eval echo "$as_me:5907: \"$ac_compile\"") >&5
5908 (eval $ac_compile) 2>&5
5910 echo "$as_me:5910: \$? = $ac_status" >&5
5911 (exit $ac_status); } &&
5912 { ac_try='test -s conftest.$ac_objext'
5913 { (eval echo "$as_me:5913: \"$ac_try\"") >&5
5916 echo "$as_me:5916: \$? = $ac_status" >&5
5917 (exit $ac_status); }; }; then
5920 echo "$as_me: failed program was:" >&5
5921 cat conftest.$ac_ext >&5
5924 rm -f conftest.$ac_objext conftest.$ac_ext
5925 CPPFLAGS=$cf_save_CPPFLAGS
5930 if test "$cf_have_incdir" = no ; then
5931 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
5933 echo "${as_me:-configure}:5933: testing adding $cf_add_incdir to include-path ..." 1>&5
5935 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
5937 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
5938 test "$cf_top_incdir" = "$cf_add_incdir" && break
5939 cf_add_incdir="$cf_top_incdir"
5950 if test -n "$cf_cv_curses_dir/lib" ; then
5951 for cf_add_libdir in $cf_cv_curses_dir/lib
5953 if test $cf_add_libdir = /usr/lib ; then
5955 elif test -d $cf_add_libdir
5958 if test -n "$LDFLAGS$LIBS" ; then
5959 # a loop is needed to ensure we can add subdirs of existing dirs
5960 for cf_test_libdir in $LDFLAGS $LIBS ; do
5961 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
5962 cf_have_libdir=yes; break
5966 if test "$cf_have_libdir" = no ; then
5967 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
5969 echo "${as_me:-configure}:5969: testing adding $cf_add_libdir to library-path ..." 1>&5
5971 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
5982 echo "$as_me:5982: checking for specified curses library type" >&5
5983 echo $ECHO_N "checking for specified curses library type... $ECHO_C" >&6
5985 # Check whether --with-screen or --without-screen was given.
5986 if test "${with_screen+set}" = set; then
5987 withval="$with_screen"
5988 cf_cv_screen=$withval
5991 # Check whether --with-ncursesw or --without-ncursesw was given.
5992 if test "${with_ncursesw+set}" = set; then
5993 withval="$with_ncursesw"
5994 cf_cv_screen=ncursesw
5997 # Check whether --with-ncurses or --without-ncurses was given.
5998 if test "${with_ncurses+set}" = set; then
5999 withval="$with_ncurses"
6000 cf_cv_screen=ncurses
6003 # Check whether --with-pdcurses or --without-pdcurses was given.
6004 if test "${with_pdcurses+set}" = set; then
6005 withval="$with_pdcurses"
6006 cf_cv_screen=pdcurses
6009 # Check whether --with-curses-colr or --without-curses-colr was given.
6010 if test "${with_curses_colr+set}" = set; then
6011 withval="$with_curses_colr"
6012 cf_cv_screen=curses_colr
6015 # Check whether --with-curses-5lib or --without-curses-5lib was given.
6016 if test "${with_curses_5lib+set}" = set; then
6017 withval="$with_curses_5lib"
6018 cf_cv_screen=curses_5lib
6026 echo "$as_me:6026: result: $cf_cv_screen" >&5
6027 echo "${ECHO_T}$cf_cv_screen" >&6
6029 case $cf_cv_screen in
6032 echo "$as_me:6032: checking for extra include directories" >&5
6033 echo $ECHO_N "checking for extra include directories... $ECHO_C" >&6
6034 if test "${cf_cv_curses_incdir+set}" = set; then
6035 echo $ECHO_N "(cached) $ECHO_C" >&6
6038 cf_cv_curses_incdir=no
6041 if test "x$cf_cv_screen" = "xcurses_colr"
6043 test -d /usr/include/curses_colr && \
6044 cf_cv_curses_incdir="-I/usr/include/curses_colr"
6048 if test "x$cf_cv_screen" = "xcurses_5lib"
6050 test -d /usr/5lib && \
6051 test -d /usr/5include && \
6052 cf_cv_curses_incdir="-I/usr/5include"
6058 echo "$as_me:6058: result: $cf_cv_curses_incdir" >&5
6059 echo "${ECHO_T}$cf_cv_curses_incdir" >&6
6060 if test "$cf_cv_curses_incdir" != no
6063 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
6064 CPPFLAGS="${CPPFLAGS}$cf_cv_curses_incdir"
6068 echo "$as_me:6068: checking if we have identified curses headers" >&5
6069 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
6070 if test "${cf_cv_ncurses_header+set}" = set; then
6071 echo $ECHO_N "(cached) $ECHO_C" >&6
6074 cf_cv_ncurses_header=none
6077 curses.h ncurses/ncurses.h ncurses/curses.h
6079 cat >conftest.$ac_ext <<_ACEOF
6080 #line 6080 "configure"
6081 #include "confdefs.h"
6082 #include <${cf_header}>
6086 initscr(); tgoto("?", 0,0)
6091 rm -f conftest.$ac_objext
6092 if { (eval echo "$as_me:6092: \"$ac_compile\"") >&5
6093 (eval $ac_compile) 2>&5
6095 echo "$as_me:6095: \$? = $ac_status" >&5
6096 (exit $ac_status); } &&
6097 { ac_try='test -s conftest.$ac_objext'
6098 { (eval echo "$as_me:6098: \"$ac_try\"") >&5
6101 echo "$as_me:6101: \$? = $ac_status" >&5
6102 (exit $ac_status); }; }; then
6103 cf_cv_ncurses_header=$cf_header; break
6105 echo "$as_me: failed program was:" >&5
6106 cat conftest.$ac_ext >&5
6108 rm -f conftest.$ac_objext conftest.$ac_ext
6112 echo "$as_me:6112: result: $cf_cv_ncurses_header" >&5
6113 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
6115 if test "$cf_cv_ncurses_header" = none ; then
6116 { { echo "$as_me:6116: error: No curses header-files found" >&5
6117 echo "$as_me: error: No curses header-files found" >&2;}
6118 { (exit 1); exit 1; }; }
6121 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
6123 for ac_header in $cf_cv_ncurses_header
6125 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6126 echo "$as_me:6126: checking for $ac_header" >&5
6127 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6128 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6129 echo $ECHO_N "(cached) $ECHO_C" >&6
6131 cat >conftest.$ac_ext <<_ACEOF
6132 #line 6132 "configure"
6133 #include "confdefs.h"
6134 #include <$ac_header>
6136 if { (eval echo "$as_me:6136: \"$ac_cpp conftest.$ac_ext\"") >&5
6137 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6139 egrep -v '^ *\+' conftest.er1 >conftest.err
6141 cat conftest.err >&5
6142 echo "$as_me:6142: \$? = $ac_status" >&5
6143 (exit $ac_status); } >/dev/null; then
6144 if test -s conftest.err; then
6145 ac_cpp_err=$ac_c_preproc_warn_flag
6152 if test -z "$ac_cpp_err"; then
6153 eval "$as_ac_Header=yes"
6155 echo "$as_me: failed program was:" >&5
6156 cat conftest.$ac_ext >&5
6157 eval "$as_ac_Header=no"
6159 rm -f conftest.err conftest.$ac_ext
6161 echo "$as_me:6161: result: `eval echo '${'$as_ac_Header'}'`" >&5
6162 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6163 if test `eval echo '${'$as_ac_Header'}'` = yes; then
6164 cat >>confdefs.h <<EOF
6165 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6171 echo "$as_me:6171: checking for terminfo header" >&5
6172 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
6173 if test "${cf_cv_term_header+set}" = set; then
6174 echo $ECHO_N "(cached) $ECHO_C" >&6
6177 case ${cf_cv_ncurses_header} in
6178 (*/ncurses.h|*/ncursesw.h)
6179 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
6182 cf_term_header=term.h
6186 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
6188 cat >conftest.$ac_ext <<_ACEOF
6189 #line 6189 "configure"
6190 #include "confdefs.h"
6192 #include <${cf_cv_ncurses_header:-curses.h}>
6198 int x = auto_left_margin; (void)x
6203 rm -f conftest.$ac_objext
6204 if { (eval echo "$as_me:6204: \"$ac_compile\"") >&5
6205 (eval $ac_compile) 2>&5
6207 echo "$as_me:6207: \$? = $ac_status" >&5
6208 (exit $ac_status); } &&
6209 { ac_try='test -s conftest.$ac_objext'
6210 { (eval echo "$as_me:6210: \"$ac_try\"") >&5
6213 echo "$as_me:6213: \$? = $ac_status" >&5
6214 (exit $ac_status); }; }; then
6216 cf_cv_term_header="$cf_test"
6218 echo "$as_me: failed program was:" >&5
6219 cat conftest.$ac_ext >&5
6221 cf_cv_term_header=unknown
6224 rm -f conftest.$ac_objext conftest.$ac_ext
6225 test "$cf_cv_term_header" != unknown && break
6229 echo "$as_me:6229: result: $cf_cv_term_header" >&5
6230 echo "${ECHO_T}$cf_cv_term_header" >&6
6232 # Set definitions to allow ifdef'ing to accommodate subdirectories
6234 case $cf_cv_term_header in
6237 cat >>confdefs.h <<\EOF
6238 #define HAVE_TERM_H 1
6244 case $cf_cv_term_header in
6247 cat >>confdefs.h <<\EOF
6248 #define HAVE_NCURSES_TERM_H 1
6254 cat >>confdefs.h <<\EOF
6255 #define HAVE_NCURSESW_TERM_H 1
6261 echo "$as_me:6261: checking for ncurses version" >&5
6262 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
6263 if test "${cf_cv_ncurses_version+set}" = set; then
6264 echo $ECHO_N "(cached) $ECHO_C" >&6
6267 cf_cv_ncurses_version=no
6270 if test "$cross_compiling" = yes; then
6272 # This will not work if the preprocessor splits the line after the
6273 # Autoconf token. The 'unproto' program does that.
6274 cat > conftest.$ac_ext <<EOF
6275 #include <${cf_cv_ncurses_header:-curses.h}>
6277 #ifdef NCURSES_VERSION
6278 Autoconf NCURSES_VERSION
6286 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
6287 { (eval echo "$as_me:6287: \"$cf_try\"") >&5
6290 echo "$as_me:6290: \$? = $ac_status" >&5
6291 (exit $ac_status); }
6292 if test -f conftest.out ; then
6293 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
6294 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
6299 cat >conftest.$ac_ext <<_ACEOF
6300 #line 6300 "configure"
6301 #include "confdefs.h"
6303 #include <${cf_cv_ncurses_header:-curses.h}>
6307 FILE *fp = fopen("$cf_tempfile", "w");
6308 #ifdef NCURSES_VERSION
6309 # ifdef NCURSES_VERSION_PATCH
6310 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
6312 fprintf(fp, "%s\n", NCURSES_VERSION);
6316 fprintf(fp, "old\n");
6321 ${cf_cv_main_return:-return}(0);
6324 rm -f conftest$ac_exeext
6325 if { (eval echo "$as_me:6325: \"$ac_link\"") >&5
6326 (eval $ac_link) 2>&5
6328 echo "$as_me:6328: \$? = $ac_status" >&5
6329 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
6330 { (eval echo "$as_me:6330: \"$ac_try\"") >&5
6333 echo "$as_me:6333: \$? = $ac_status" >&5
6334 (exit $ac_status); }; }; then
6336 cf_cv_ncurses_version=`cat $cf_tempfile`
6338 echo "$as_me: program exited with status $ac_status" >&5
6339 echo "$as_me: failed program was:" >&5
6340 cat conftest.$ac_ext >&5
6342 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6347 echo "$as_me:6347: result: $cf_cv_ncurses_version" >&5
6348 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
6349 test "$cf_cv_ncurses_version" = no ||
6350 cat >>confdefs.h <<\EOF
6354 echo "$as_me:6354: checking if we have identified curses libraries" >&5
6355 echo $ECHO_N "checking if we have identified curses libraries... $ECHO_C" >&6
6356 cat >conftest.$ac_ext <<_ACEOF
6357 #line 6357 "configure"
6358 #include "confdefs.h"
6359 #include <${cf_cv_ncurses_header:-curses.h}>
6363 initscr(); tgoto("?", 0,0)
6368 rm -f conftest.$ac_objext conftest$ac_exeext
6369 if { (eval echo "$as_me:6369: \"$ac_link\"") >&5
6370 (eval $ac_link) 2>&5
6372 echo "$as_me:6372: \$? = $ac_status" >&5
6373 (exit $ac_status); } &&
6374 { ac_try='test -s conftest$ac_exeext'
6375 { (eval echo "$as_me:6375: \"$ac_try\"") >&5
6378 echo "$as_me:6378: \$? = $ac_status" >&5
6379 (exit $ac_status); }; }; then
6382 echo "$as_me: failed program was:" >&5
6383 cat conftest.$ac_ext >&5
6386 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6387 echo "$as_me:6387: result: $cf_result" >&5
6388 echo "${ECHO_T}$cf_result" >&6
6390 if test "$cf_result" = no ; then
6393 echo "$as_me:6393: checking for tgoto in -lmytinfo" >&5
6394 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
6395 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
6396 echo $ECHO_N "(cached) $ECHO_C" >&6
6398 ac_check_lib_save_LIBS=$LIBS
6399 LIBS="-lmytinfo $LIBS"
6400 cat >conftest.$ac_ext <<_ACEOF
6401 #line 6401 "configure"
6402 #include "confdefs.h"
6404 /* Override any gcc2 internal prototype to avoid an error. */
6408 /* We use char because int might match the return type of a gcc2
6409 builtin and then its argument prototype would still apply. */
6419 rm -f conftest.$ac_objext conftest$ac_exeext
6420 if { (eval echo "$as_me:6420: \"$ac_link\"") >&5
6421 (eval $ac_link) 2>&5
6423 echo "$as_me:6423: \$? = $ac_status" >&5
6424 (exit $ac_status); } &&
6425 { ac_try='test -s conftest$ac_exeext'
6426 { (eval echo "$as_me:6426: \"$ac_try\"") >&5
6429 echo "$as_me:6429: \$? = $ac_status" >&5
6430 (exit $ac_status); }; }; then
6431 ac_cv_lib_mytinfo_tgoto=yes
6433 echo "$as_me: failed program was:" >&5
6434 cat conftest.$ac_ext >&5
6435 ac_cv_lib_mytinfo_tgoto=no
6437 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6438 LIBS=$ac_check_lib_save_LIBS
6440 echo "$as_me:6440: result: $ac_cv_lib_mytinfo_tgoto" >&5
6441 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
6442 if test $ac_cv_lib_mytinfo_tgoto = yes; then
6447 for cf_add_1lib in -lmytinfo; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
6449 for cf_add_1lib in $cf_add_0lib; do
6450 for cf_add_2lib in $cf_add_libs; do
6451 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
6456 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
6464 # Looking at HPUX 10.20, the Hcurses library is the oldest (1997), cur_colr
6465 # next (1998), and xcurses "newer" (2000). There is no header file for
6466 # Hcurses; the subdirectory curses_colr has the headers (curses.h and
6467 # term.h) for cur_colr
6468 if test "x$cf_cv_screen" = "xcurses_colr"
6470 echo "$as_me:6470: checking for initscr in -lcur_colr" >&5
6471 echo $ECHO_N "checking for initscr in -lcur_colr... $ECHO_C" >&6
6472 if test "${ac_cv_lib_cur_colr_initscr+set}" = set; then
6473 echo $ECHO_N "(cached) $ECHO_C" >&6
6475 ac_check_lib_save_LIBS=$LIBS
6476 LIBS="-lcur_colr $LIBS"
6477 cat >conftest.$ac_ext <<_ACEOF
6478 #line 6478 "configure"
6479 #include "confdefs.h"
6481 /* Override any gcc2 internal prototype to avoid an error. */
6485 /* We use char because int might match the return type of a gcc2
6486 builtin and then its argument prototype would still apply. */
6496 rm -f conftest.$ac_objext conftest$ac_exeext
6497 if { (eval echo "$as_me:6497: \"$ac_link\"") >&5
6498 (eval $ac_link) 2>&5
6500 echo "$as_me:6500: \$? = $ac_status" >&5
6501 (exit $ac_status); } &&
6502 { ac_try='test -s conftest$ac_exeext'
6503 { (eval echo "$as_me:6503: \"$ac_try\"") >&5
6506 echo "$as_me:6506: \$? = $ac_status" >&5
6507 (exit $ac_status); }; }; then
6508 ac_cv_lib_cur_colr_initscr=yes
6510 echo "$as_me: failed program was:" >&5
6511 cat conftest.$ac_ext >&5
6512 ac_cv_lib_cur_colr_initscr=no
6514 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6515 LIBS=$ac_check_lib_save_LIBS
6517 echo "$as_me:6517: result: $ac_cv_lib_cur_colr_initscr" >&5
6518 echo "${ECHO_T}$ac_cv_lib_cur_colr_initscr" >&6
6519 if test $ac_cv_lib_cur_colr_initscr = yes; then
6524 for cf_add_1lib in -lcur_colr; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
6526 for cf_add_1lib in $cf_add_0lib; do
6527 for cf_add_2lib in $cf_add_libs; do
6528 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
6533 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
6537 ac_cv_func_initscr=yes
6541 echo "$as_me:6541: checking for initscr in -lHcurses" >&5
6542 echo $ECHO_N "checking for initscr in -lHcurses... $ECHO_C" >&6
6543 if test "${ac_cv_lib_Hcurses_initscr+set}" = set; then
6544 echo $ECHO_N "(cached) $ECHO_C" >&6
6546 ac_check_lib_save_LIBS=$LIBS
6547 LIBS="-lHcurses $LIBS"
6548 cat >conftest.$ac_ext <<_ACEOF
6549 #line 6549 "configure"
6550 #include "confdefs.h"
6552 /* Override any gcc2 internal prototype to avoid an error. */
6556 /* We use char because int might match the return type of a gcc2
6557 builtin and then its argument prototype would still apply. */
6567 rm -f conftest.$ac_objext conftest$ac_exeext
6568 if { (eval echo "$as_me:6568: \"$ac_link\"") >&5
6569 (eval $ac_link) 2>&5
6571 echo "$as_me:6571: \$? = $ac_status" >&5
6572 (exit $ac_status); } &&
6573 { ac_try='test -s conftest$ac_exeext'
6574 { (eval echo "$as_me:6574: \"$ac_try\"") >&5
6577 echo "$as_me:6577: \$? = $ac_status" >&5
6578 (exit $ac_status); }; }; then
6579 ac_cv_lib_Hcurses_initscr=yes
6581 echo "$as_me: failed program was:" >&5
6582 cat conftest.$ac_ext >&5
6583 ac_cv_lib_Hcurses_initscr=no
6585 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6586 LIBS=$ac_check_lib_save_LIBS
6588 echo "$as_me:6588: result: $ac_cv_lib_Hcurses_initscr" >&5
6589 echo "${ECHO_T}$ac_cv_lib_Hcurses_initscr" >&6
6590 if test $ac_cv_lib_Hcurses_initscr = yes; then
6592 # HP's header uses __HP_CURSES, but user claims _HP_CURSES.
6597 for cf_add_1lib in -lHcurses; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
6599 for cf_add_1lib in $cf_add_0lib; do
6600 for cf_add_2lib in $cf_add_libs; do
6601 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
6606 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
6610 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
6611 CPPFLAGS="${CPPFLAGS}-D__HP_CURSES -D_HP_CURSES"
6613 ac_cv_func_initscr=yes
6622 case `arch 2>/dev/null` in
6627 if test -n "/lib64" ; then
6628 for cf_add_libdir in /lib64
6630 if test $cf_add_libdir = /usr/lib ; then
6632 elif test -d $cf_add_libdir
6635 if test -n "$LDFLAGS$LIBS" ; then
6636 # a loop is needed to ensure we can add subdirs of existing dirs
6637 for cf_test_libdir in $LDFLAGS $LIBS ; do
6638 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
6639 cf_have_libdir=yes; break
6643 if test "$cf_have_libdir" = no ; then
6644 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
6646 echo "${as_me:-configure}:6646: testing adding $cf_add_libdir to library-path ..." 1>&5
6648 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
6656 if test -n "/lib" ; then
6657 for cf_add_libdir in /lib
6659 if test $cf_add_libdir = /usr/lib ; then
6661 elif test -d $cf_add_libdir
6664 if test -n "$LDFLAGS$LIBS" ; then
6665 # a loop is needed to ensure we can add subdirs of existing dirs
6666 for cf_test_libdir in $LDFLAGS $LIBS ; do
6667 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
6668 cf_have_libdir=yes; break
6672 if test "$cf_have_libdir" = no ; then
6673 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
6675 echo "${as_me:-configure}:6675: testing adding $cf_add_libdir to library-path ..." 1>&5
6677 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
6687 if test -n "/lib" ; then
6688 for cf_add_libdir in /lib
6690 if test $cf_add_libdir = /usr/lib ; then
6692 elif test -d $cf_add_libdir
6695 if test -n "$LDFLAGS$LIBS" ; then
6696 # a loop is needed to ensure we can add subdirs of existing dirs
6697 for cf_test_libdir in $LDFLAGS $LIBS ; do
6698 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
6699 cf_have_libdir=yes; break
6703 if test "$cf_have_libdir" = no ; then
6704 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
6706 echo "${as_me:-configure}:6706: testing adding $cf_add_libdir to library-path ..." 1>&5
6708 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
6718 if test "x$cf_cv_screen" = "xcurses_5lib"
6720 if test -d /usr/5lib ; then
6722 if test -n "/usr/5lib" ; then
6723 for cf_add_libdir in /usr/5lib
6725 if test $cf_add_libdir = /usr/lib ; then
6727 elif test -d $cf_add_libdir
6730 if test -n "$LDFLAGS$LIBS" ; then
6731 # a loop is needed to ensure we can add subdirs of existing dirs
6732 for cf_test_libdir in $LDFLAGS $LIBS ; do
6733 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
6734 cf_have_libdir=yes; break
6738 if test "$cf_have_libdir" = no ; then
6739 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
6741 echo "${as_me:-configure}:6741: testing adding $cf_add_libdir to library-path ..." 1>&5
6743 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
6752 for cf_add_1lib in -lcurses -ltermcap; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
6754 for cf_add_1lib in $cf_add_0lib; do
6755 for cf_add_2lib in $cf_add_libs; do
6756 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
6761 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
6767 ac_cv_func_initscr=yes
6771 if test ".$ac_cv_func_initscr" != .yes ; then
6772 cf_save_LIBS="$LIBS"
6774 if test ".${cf_cv_ncurses_version:-no}" != .no
6776 cf_check_list="ncurses curses cursesX"
6778 cf_check_list="cursesX curses ncurses"
6781 # Check for library containing tgoto. Do this before curses library
6782 # because it may be needed to link the test-case for initscr.
6783 if test "x$cf_term_lib" = x
6785 echo "$as_me:6785: checking for tgoto" >&5
6786 echo $ECHO_N "checking for tgoto... $ECHO_C" >&6
6787 if test "${ac_cv_func_tgoto+set}" = set; then
6788 echo $ECHO_N "(cached) $ECHO_C" >&6
6790 cat >conftest.$ac_ext <<_ACEOF
6791 #line 6791 "configure"
6792 #include "confdefs.h"
6793 #define tgoto autoconf_temporary
6794 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
6801 /* We use char because int might match the return type of a gcc2
6802 builtin and then its argument prototype would still apply. */
6809 /* The GNU C library defines stubs for functions which it implements
6810 to always fail with ENOSYS. Some functions are actually named
6811 something starting with __ and the normal name is an alias. */
6812 #if defined (__stub_tgoto) || defined (__stub___tgoto)
6813 #error found stub for tgoto
6821 rm -f conftest.$ac_objext conftest$ac_exeext
6822 if { (eval echo "$as_me:6822: \"$ac_link\"") >&5
6823 (eval $ac_link) 2>&5
6825 echo "$as_me:6825: \$? = $ac_status" >&5
6826 (exit $ac_status); } &&
6827 { ac_try='test -s conftest$ac_exeext'
6828 { (eval echo "$as_me:6828: \"$ac_try\"") >&5
6831 echo "$as_me:6831: \$? = $ac_status" >&5
6832 (exit $ac_status); }; }; then
6833 ac_cv_func_tgoto=yes
6835 echo "$as_me: failed program was:" >&5
6836 cat conftest.$ac_ext >&5
6839 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6841 echo "$as_me:6841: result: $ac_cv_func_tgoto" >&5
6842 echo "${ECHO_T}$ac_cv_func_tgoto" >&6
6843 if test $ac_cv_func_tgoto = yes; then
6844 cf_term_lib=predefined
6847 for cf_term_lib in $cf_check_list otermcap termcap tinfo termlib unknown
6849 as_ac_Lib=`echo "ac_cv_lib_$cf_term_lib''_tgoto" | $as_tr_sh`
6850 echo "$as_me:6850: checking for tgoto in -l$cf_term_lib" >&5
6851 echo $ECHO_N "checking for tgoto in -l$cf_term_lib... $ECHO_C" >&6
6852 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
6853 echo $ECHO_N "(cached) $ECHO_C" >&6
6855 ac_check_lib_save_LIBS=$LIBS
6856 LIBS="-l$cf_term_lib $LIBS"
6857 cat >conftest.$ac_ext <<_ACEOF
6858 #line 6858 "configure"
6859 #include "confdefs.h"
6861 /* Override any gcc2 internal prototype to avoid an error. */
6865 /* We use char because int might match the return type of a gcc2
6866 builtin and then its argument prototype would still apply. */
6876 rm -f conftest.$ac_objext conftest$ac_exeext
6877 if { (eval echo "$as_me:6877: \"$ac_link\"") >&5
6878 (eval $ac_link) 2>&5
6880 echo "$as_me:6880: \$? = $ac_status" >&5
6881 (exit $ac_status); } &&
6882 { ac_try='test -s conftest$ac_exeext'
6883 { (eval echo "$as_me:6883: \"$ac_try\"") >&5
6886 echo "$as_me:6886: \$? = $ac_status" >&5
6887 (exit $ac_status); }; }; then
6888 eval "$as_ac_Lib=yes"
6890 echo "$as_me: failed program was:" >&5
6891 cat conftest.$ac_ext >&5
6892 eval "$as_ac_Lib=no"
6894 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6895 LIBS=$ac_check_lib_save_LIBS
6897 echo "$as_me:6897: result: `eval echo '${'$as_ac_Lib'}'`" >&5
6898 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
6899 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
6901 : ${cf_nculib_root:=$cf_term_lib}
6912 # Check for library containing initscr
6913 test "$cf_term_lib" != predefined && test "$cf_term_lib" != unknown && LIBS="-l$cf_term_lib $cf_save_LIBS"
6914 if test "x$cf_curs_lib" = x
6916 for cf_curs_lib in $cf_check_list xcurses jcurses pdcurses unknown
6918 LIBS="-l$cf_curs_lib $cf_save_LIBS"
6919 if test "$cf_term_lib" = unknown || test "$cf_term_lib" = "$cf_curs_lib" ; then
6920 echo "$as_me:6920: checking if we can link with $cf_curs_lib library" >&5
6921 echo $ECHO_N "checking if we can link with $cf_curs_lib library... $ECHO_C" >&6
6922 cat >conftest.$ac_ext <<_ACEOF
6923 #line 6923 "configure"
6924 #include "confdefs.h"
6925 #include <${cf_cv_ncurses_header:-curses.h}>
6934 rm -f conftest.$ac_objext conftest$ac_exeext
6935 if { (eval echo "$as_me:6935: \"$ac_link\"") >&5
6936 (eval $ac_link) 2>&5
6938 echo "$as_me:6938: \$? = $ac_status" >&5
6939 (exit $ac_status); } &&
6940 { ac_try='test -s conftest$ac_exeext'
6941 { (eval echo "$as_me:6941: \"$ac_try\"") >&5
6944 echo "$as_me:6944: \$? = $ac_status" >&5
6945 (exit $ac_status); }; }; then
6948 echo "$as_me: failed program was:" >&5
6949 cat conftest.$ac_ext >&5
6952 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6953 echo "$as_me:6953: result: $cf_result" >&5
6954 echo "${ECHO_T}$cf_result" >&6
6955 test $cf_result = yes && break
6956 elif test "$cf_curs_lib" = "$cf_term_lib" ; then
6958 elif test "$cf_term_lib" != predefined ; then
6959 echo "$as_me:6959: checking if we need both $cf_curs_lib and $cf_term_lib libraries" >&5
6960 echo $ECHO_N "checking if we need both $cf_curs_lib and $cf_term_lib libraries... $ECHO_C" >&6
6961 cat >conftest.$ac_ext <<_ACEOF
6962 #line 6962 "configure"
6963 #include "confdefs.h"
6964 #include <${cf_cv_ncurses_header:-curses.h}>
6968 initscr(); tgoto((char *)0, 0, 0);
6973 rm -f conftest.$ac_objext conftest$ac_exeext
6974 if { (eval echo "$as_me:6974: \"$ac_link\"") >&5
6975 (eval $ac_link) 2>&5
6977 echo "$as_me:6977: \$? = $ac_status" >&5
6978 (exit $ac_status); } &&
6979 { ac_try='test -s conftest$ac_exeext'
6980 { (eval echo "$as_me:6980: \"$ac_try\"") >&5
6983 echo "$as_me:6983: \$? = $ac_status" >&5
6984 (exit $ac_status); }; }; then
6987 echo "$as_me: failed program was:" >&5
6988 cat conftest.$ac_ext >&5
6990 LIBS="-l$cf_curs_lib -l$cf_term_lib $cf_save_LIBS"
6991 cat >conftest.$ac_ext <<_ACEOF
6992 #line 6992 "configure"
6993 #include "confdefs.h"
6994 #include <${cf_cv_ncurses_header:-curses.h}>
7003 rm -f conftest.$ac_objext conftest$ac_exeext
7004 if { (eval echo "$as_me:7004: \"$ac_link\"") >&5
7005 (eval $ac_link) 2>&5
7007 echo "$as_me:7007: \$? = $ac_status" >&5
7008 (exit $ac_status); } &&
7009 { ac_try='test -s conftest$ac_exeext'
7010 { (eval echo "$as_me:7010: \"$ac_try\"") >&5
7013 echo "$as_me:7013: \$? = $ac_status" >&5
7014 (exit $ac_status); }; }; then
7017 echo "$as_me: failed program was:" >&5
7018 cat conftest.$ac_ext >&5
7021 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7024 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7025 echo "$as_me:7025: result: $cf_result" >&5
7026 echo "${ECHO_T}$cf_result" >&6
7027 test $cf_result != error && break
7031 test $cf_curs_lib = unknown && { { echo "$as_me:7031: error: no curses library found" >&5
7032 echo "$as_me: error: no curses library found" >&2;}
7033 { (exit 1); exit 1; }; }
7040 echo "$as_me:7040: checking for multibyte character support" >&5
7041 echo $ECHO_N "checking for multibyte character support... $ECHO_C" >&6
7042 if test "${cf_cv_utf8_lib+set}" = set; then
7043 echo $ECHO_N "(cached) $ECHO_C" >&6
7046 cf_save_LIBS="$LIBS"
7047 cat >conftest.$ac_ext <<_ACEOF
7048 #line 7048 "configure"
7049 #include "confdefs.h"
7060 rm -f conftest.$ac_objext conftest$ac_exeext
7061 if { (eval echo "$as_me:7061: \"$ac_link\"") >&5
7062 (eval $ac_link) 2>&5
7064 echo "$as_me:7064: \$? = $ac_status" >&5
7065 (exit $ac_status); } &&
7066 { ac_try='test -s conftest$ac_exeext'
7067 { (eval echo "$as_me:7067: \"$ac_try\"") >&5
7070 echo "$as_me:7070: \$? = $ac_status" >&5
7071 (exit $ac_status); }; }; then
7074 echo "$as_me: failed program was:" >&5
7075 cat conftest.$ac_ext >&5
7077 # If the linkage is not already in the $CPPFLAGS/$LDFLAGS configuration, these
7078 # will be set on completion of the AC_TRY_LINK below.
7079 cf_cv_header_path_utf8=
7080 cf_cv_library_path_utf8=
7082 echo "${as_me:-configure}:7082: testing Starting FIND_LINKAGE(utf8,) ..." 1>&5
7084 cf_save_LIBS="$LIBS"
7086 cat >conftest.$ac_ext <<_ACEOF
7087 #line 7087 "configure"
7088 #include "confdefs.h"
7090 #include <libutf8.h>
7099 rm -f conftest.$ac_objext conftest$ac_exeext
7100 if { (eval echo "$as_me:7100: \"$ac_link\"") >&5
7101 (eval $ac_link) 2>&5
7103 echo "$as_me:7103: \$? = $ac_status" >&5
7104 (exit $ac_status); } &&
7105 { ac_try='test -s conftest$ac_exeext'
7106 { (eval echo "$as_me:7106: \"$ac_try\"") >&5
7109 echo "$as_me:7109: \$? = $ac_status" >&5
7110 (exit $ac_status); }; }; then
7112 cf_cv_find_linkage_utf8=yes
7113 cf_cv_header_path_utf8=/usr/include
7114 cf_cv_library_path_utf8=/usr/lib
7117 echo "$as_me: failed program was:" >&5
7118 cat conftest.$ac_ext >&5
7120 LIBS="-lutf8 $cf_save_LIBS"
7122 cat >conftest.$ac_ext <<_ACEOF
7123 #line 7123 "configure"
7124 #include "confdefs.h"
7126 #include <libutf8.h>
7135 rm -f conftest.$ac_objext conftest$ac_exeext
7136 if { (eval echo "$as_me:7136: \"$ac_link\"") >&5
7137 (eval $ac_link) 2>&5
7139 echo "$as_me:7139: \$? = $ac_status" >&5
7140 (exit $ac_status); } &&
7141 { ac_try='test -s conftest$ac_exeext'
7142 { (eval echo "$as_me:7142: \"$ac_try\"") >&5
7145 echo "$as_me:7145: \$? = $ac_status" >&5
7146 (exit $ac_status); }; }; then
7148 cf_cv_find_linkage_utf8=yes
7149 cf_cv_header_path_utf8=/usr/include
7150 cf_cv_library_path_utf8=/usr/lib
7151 cf_cv_library_file_utf8="-lutf8"
7154 echo "$as_me: failed program was:" >&5
7155 cat conftest.$ac_ext >&5
7157 cf_cv_find_linkage_utf8=no
7158 LIBS="$cf_save_LIBS"
7160 test -n "$verbose" && echo " find linkage for utf8 library" 1>&6
7162 echo "${as_me:-configure}:7162: testing find linkage for utf8 library ..." 1>&5
7164 echo "${as_me:-configure}:7164: testing Searching for headers in FIND_LINKAGE(utf8,) ..." 1>&5
7166 cf_save_CPPFLAGS="$CPPFLAGS"
7167 cf_test_CPPFLAGS="$CPPFLAGS"
7171 # collect the current set of include-directories from compiler flags
7172 cf_header_path_list=""
7173 if test -n "${CFLAGS}${CPPFLAGS}" ; then
7174 for cf_header_path in $CPPFLAGS $CFLAGS
7176 case $cf_header_path in
7178 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
7180 test "x$cf_header_path" != "xNONE" && \
7181 test -d "$cf_header_path" && \
7183 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
7184 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
7185 test -d $cf_header_path/include/utf8 && cf_search="$cf_search $cf_header_path/include/utf8"
7186 test -d $cf_header_path/include/utf8/include && cf_search="$cf_search $cf_header_path/include/utf8/include"
7187 test -d $cf_header_path/utf8/include && cf_search="$cf_search $cf_header_path/utf8/include"
7188 test -d $cf_header_path/utf8/include/utf8 && cf_search="$cf_search $cf_header_path/utf8/include/utf8"
7191 cf_header_path_list="$cf_header_path_list $cf_search"
7197 # add the variations for the package we are looking for
7201 test "x$prefix" != "xNONE" && \
7202 test -d "$prefix" && \
7204 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
7205 test -d $prefix/include && cf_search="$cf_search $prefix/include"
7206 test -d $prefix/include/utf8 && cf_search="$cf_search $prefix/include/utf8"
7207 test -d $prefix/include/utf8/include && cf_search="$cf_search $prefix/include/utf8/include"
7208 test -d $prefix/utf8/include && cf_search="$cf_search $prefix/utf8/include"
7209 test -d $prefix/utf8/include/utf8 && cf_search="$cf_search $prefix/utf8/include/utf8"
7212 for cf_subdir_prefix in \
7221 test "x$cf_subdir_prefix" != "x$prefix" && \
7222 test -d "$cf_subdir_prefix" && \
7223 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
7224 test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
7225 test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include"
7226 test -d $cf_subdir_prefix/include/utf8 && cf_search="$cf_search $cf_subdir_prefix/include/utf8"
7227 test -d $cf_subdir_prefix/include/utf8/include && cf_search="$cf_search $cf_subdir_prefix/include/utf8/include"
7228 test -d $cf_subdir_prefix/utf8/include && cf_search="$cf_search $cf_subdir_prefix/utf8/include"
7229 test -d $cf_subdir_prefix/utf8/include/utf8 && cf_search="$cf_search $cf_subdir_prefix/utf8/include/utf8"
7234 test "$includedir" != NONE && \
7235 test "$includedir" != "/usr/include" && \
7236 test -d "$includedir" && {
7237 test -d $includedir && cf_search="$cf_search $includedir"
7238 test -d $includedir/utf8 && cf_search="$cf_search $includedir/utf8"
7241 test "$oldincludedir" != NONE && \
7242 test "$oldincludedir" != "/usr/include" && \
7243 test -d "$oldincludedir" && {
7244 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
7245 test -d $oldincludedir/utf8 && cf_search="$cf_search $oldincludedir/utf8"
7248 cf_search="$cf_search $cf_header_path_list"
7250 for cf_cv_header_path_utf8 in $cf_search
7252 if test -d $cf_cv_header_path_utf8 ; then
7253 test -n "$verbose" && echo " ... testing $cf_cv_header_path_utf8" 1>&6
7255 echo "${as_me:-configure}:7255: testing ... testing $cf_cv_header_path_utf8 ..." 1>&5
7257 CPPFLAGS="$cf_save_CPPFLAGS"
7259 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
7260 CPPFLAGS="${CPPFLAGS}-I$cf_cv_header_path_utf8"
7262 cat >conftest.$ac_ext <<_ACEOF
7263 #line 7263 "configure"
7264 #include "confdefs.h"
7266 #include <libutf8.h>
7275 rm -f conftest.$ac_objext
7276 if { (eval echo "$as_me:7276: \"$ac_compile\"") >&5
7277 (eval $ac_compile) 2>&5
7279 echo "$as_me:7279: \$? = $ac_status" >&5
7280 (exit $ac_status); } &&
7281 { ac_try='test -s conftest.$ac_objext'
7282 { (eval echo "$as_me:7282: \"$ac_try\"") >&5
7285 echo "$as_me:7285: \$? = $ac_status" >&5
7286 (exit $ac_status); }; }; then
7288 test -n "$verbose" && echo " ... found utf8 headers in $cf_cv_header_path_utf8" 1>&6
7290 echo "${as_me:-configure}:7290: testing ... found utf8 headers in $cf_cv_header_path_utf8 ..." 1>&5
7292 cf_cv_find_linkage_utf8=maybe
7293 cf_test_CPPFLAGS="$CPPFLAGS"
7296 echo "$as_me: failed program was:" >&5
7297 cat conftest.$ac_ext >&5
7299 CPPFLAGS="$cf_save_CPPFLAGS"
7302 rm -f conftest.$ac_objext conftest.$ac_ext
7306 if test "$cf_cv_find_linkage_utf8" = maybe ; then
7308 echo "${as_me:-configure}:7308: testing Searching for utf8 library in FIND_LINKAGE(utf8,) ..." 1>&5
7310 cf_save_LIBS="$LIBS"
7311 cf_save_LDFLAGS="$LDFLAGS"
7313 if test "$cf_cv_find_linkage_utf8" != yes ; then
7316 cf_library_path_list=""
7317 if test -n "${LDFLAGS}${LIBS}" ; then
7318 for cf_library_path in $LDFLAGS $LIBS
7320 case $cf_library_path in
7322 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
7324 test "x$cf_library_path" != "xNONE" && \
7325 test -d "$cf_library_path" && \
7327 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
7328 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
7329 test -d $cf_library_path/lib/utf8 && cf_search="$cf_search $cf_library_path/lib/utf8"
7330 test -d $cf_library_path/lib/utf8/lib && cf_search="$cf_search $cf_library_path/lib/utf8/lib"
7331 test -d $cf_library_path/utf8/lib && cf_search="$cf_search $cf_library_path/utf8/lib"
7332 test -d $cf_library_path/utf8/lib/utf8 && cf_search="$cf_search $cf_library_path/utf8/lib/utf8"
7335 cf_library_path_list="$cf_library_path_list $cf_search"
7343 test "x$prefix" != "xNONE" && \
7344 test -d "$prefix" && \
7346 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
7347 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
7348 test -d $prefix/lib/utf8 && cf_search="$cf_search $prefix/lib/utf8"
7349 test -d $prefix/lib/utf8/lib && cf_search="$cf_search $prefix/lib/utf8/lib"
7350 test -d $prefix/utf8/lib && cf_search="$cf_search $prefix/utf8/lib"
7351 test -d $prefix/utf8/lib/utf8 && cf_search="$cf_search $prefix/utf8/lib/utf8"
7354 for cf_subdir_prefix in \
7363 test "x$cf_subdir_prefix" != "x$prefix" && \
7364 test -d "$cf_subdir_prefix" && \
7365 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
7366 test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
7367 test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib"
7368 test -d $cf_subdir_prefix/lib/utf8 && cf_search="$cf_search $cf_subdir_prefix/lib/utf8"
7369 test -d $cf_subdir_prefix/lib/utf8/lib && cf_search="$cf_search $cf_subdir_prefix/lib/utf8/lib"
7370 test -d $cf_subdir_prefix/utf8/lib && cf_search="$cf_search $cf_subdir_prefix/utf8/lib"
7371 test -d $cf_subdir_prefix/utf8/lib/utf8 && cf_search="$cf_search $cf_subdir_prefix/utf8/lib/utf8"
7376 cf_search="$cf_library_path_list $cf_search"
7378 for cf_cv_library_path_utf8 in $cf_search
7380 if test -d $cf_cv_library_path_utf8 ; then
7381 test -n "$verbose" && echo " ... testing $cf_cv_library_path_utf8" 1>&6
7383 echo "${as_me:-configure}:7383: testing ... testing $cf_cv_library_path_utf8 ..." 1>&5
7385 CPPFLAGS="$cf_test_CPPFLAGS"
7386 LIBS="-lutf8 $cf_save_LIBS"
7387 LDFLAGS="$cf_save_LDFLAGS -L$cf_cv_library_path_utf8"
7388 cat >conftest.$ac_ext <<_ACEOF
7389 #line 7389 "configure"
7390 #include "confdefs.h"
7392 #include <libutf8.h>
7401 rm -f conftest.$ac_objext conftest$ac_exeext
7402 if { (eval echo "$as_me:7402: \"$ac_link\"") >&5
7403 (eval $ac_link) 2>&5
7405 echo "$as_me:7405: \$? = $ac_status" >&5
7406 (exit $ac_status); } &&
7407 { ac_try='test -s conftest$ac_exeext'
7408 { (eval echo "$as_me:7408: \"$ac_try\"") >&5
7411 echo "$as_me:7411: \$? = $ac_status" >&5
7412 (exit $ac_status); }; }; then
7414 test -n "$verbose" && echo " ... found utf8 library in $cf_cv_library_path_utf8" 1>&6
7416 echo "${as_me:-configure}:7416: testing ... found utf8 library in $cf_cv_library_path_utf8 ..." 1>&5
7418 cf_cv_find_linkage_utf8=yes
7419 cf_cv_library_file_utf8="-lutf8"
7422 echo "$as_me: failed program was:" >&5
7423 cat conftest.$ac_ext >&5
7425 CPPFLAGS="$cf_save_CPPFLAGS"
7426 LIBS="$cf_save_LIBS"
7427 LDFLAGS="$cf_save_LDFLAGS"
7430 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7433 CPPFLAGS="$cf_save_CPPFLAGS"
7434 LDFLAGS="$cf_save_LDFLAGS"
7438 cf_cv_find_linkage_utf8=no
7442 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7445 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7447 LIBS="$cf_save_LIBS"
7449 if test "$cf_cv_find_linkage_utf8" = yes ; then
7450 cf_cv_utf8_lib=add-on
7456 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7458 echo "$as_me:7458: result: $cf_cv_utf8_lib" >&5
7459 echo "${ECHO_T}$cf_cv_utf8_lib" >&6
7461 # HAVE_LIBUTF8_H is used by ncurses if curses.h is shared between
7463 if test "$cf_cv_utf8_lib" = "add-on" ; then
7465 cat >>confdefs.h <<\EOF
7466 #define HAVE_LIBUTF8_H 1
7469 if test -n "$cf_cv_header_path_utf8" ; then
7470 for cf_add_incdir in $cf_cv_header_path_utf8
7472 while test $cf_add_incdir != /usr/include
7474 if test -d $cf_add_incdir
7477 if test -n "$CFLAGS$CPPFLAGS" ; then
7478 # a loop is needed to ensure we can add subdirs of existing dirs
7479 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
7480 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
7481 cf_have_incdir=yes; break
7486 if test "$cf_have_incdir" = no ; then
7487 if test "$cf_add_incdir" = /usr/local/include ; then
7488 if test "$GCC" = yes
7490 cf_save_CPPFLAGS=$CPPFLAGS
7492 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
7493 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
7495 cat >conftest.$ac_ext <<_ACEOF
7496 #line 7496 "configure"
7497 #include "confdefs.h"
7507 rm -f conftest.$ac_objext
7508 if { (eval echo "$as_me:7508: \"$ac_compile\"") >&5
7509 (eval $ac_compile) 2>&5
7511 echo "$as_me:7511: \$? = $ac_status" >&5
7512 (exit $ac_status); } &&
7513 { ac_try='test -s conftest.$ac_objext'
7514 { (eval echo "$as_me:7514: \"$ac_try\"") >&5
7517 echo "$as_me:7517: \$? = $ac_status" >&5
7518 (exit $ac_status); }; }; then
7521 echo "$as_me: failed program was:" >&5
7522 cat conftest.$ac_ext >&5
7525 rm -f conftest.$ac_objext conftest.$ac_ext
7526 CPPFLAGS=$cf_save_CPPFLAGS
7531 if test "$cf_have_incdir" = no ; then
7532 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
7534 echo "${as_me:-configure}:7534: testing adding $cf_add_incdir to include-path ..." 1>&5
7536 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7538 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
7539 test "$cf_top_incdir" = "$cf_add_incdir" && break
7540 cf_add_incdir="$cf_top_incdir"
7551 if test -n "$cf_cv_library_path_utf8" ; then
7552 for cf_add_libdir in $cf_cv_library_path_utf8
7554 if test $cf_add_libdir = /usr/lib ; then
7556 elif test -d $cf_add_libdir
7559 if test -n "$LDFLAGS$LIBS" ; then
7560 # a loop is needed to ensure we can add subdirs of existing dirs
7561 for cf_test_libdir in $LDFLAGS $LIBS ; do
7562 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
7563 cf_have_libdir=yes; break
7567 if test "$cf_have_libdir" = no ; then
7568 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
7570 echo "${as_me:-configure}:7570: testing adding $cf_add_libdir to library-path ..." 1>&5
7572 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
7581 for cf_add_1lib in $cf_cv_library_file_utf8; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
7583 for cf_add_1lib in $cf_add_0lib; do
7584 for cf_add_2lib in $cf_add_libs; do
7585 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
7590 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
7596 cf_ncuconfig_root=$cf_cv_screen
7597 cf_have_ncuconfig=no
7599 if test "x${PKG_CONFIG:=none}" != xnone; then
7600 echo "$as_me:7600: checking pkg-config for $cf_ncuconfig_root" >&5
7601 echo $ECHO_N "checking pkg-config for $cf_ncuconfig_root... $ECHO_C" >&6
7602 if "$PKG_CONFIG" --exists $cf_ncuconfig_root ; then
7603 echo "$as_me:7603: result: yes" >&5
7604 echo "${ECHO_T}yes" >&6
7606 echo "$as_me:7606: checking if the $cf_ncuconfig_root package files work" >&5
7607 echo $ECHO_N "checking if the $cf_ncuconfig_root package files work... $ECHO_C" >&6
7608 cf_have_ncuconfig=unknown
7610 cf_save_CFLAGS="$CFLAGS"
7611 cf_save_CPPFLAGS="$CPPFLAGS"
7612 cf_save_LIBS="$LIBS"
7614 cf_pkg_cflags=`$PKG_CONFIG --cflags $cf_ncuconfig_root`
7615 cf_pkg_libs=`$PKG_CONFIG --libs $cf_ncuconfig_root`
7617 # while -W for passing linker flags is prevalent, it is not "standard".
7618 # At least one wrapper for c89/c99 (in Apple's xcode) has its own
7619 # incompatible _and_ non-standard -W option which gives an error. Work
7620 # around that pitfall.
7621 case "x${CC}@@${cf_pkg_libs}@${cf_pkg_cflags}" in
7627 cf_new_extra_cppflags=
7629 for cf_add_cflags in $cf_pkg_cflags
7631 case $cf_fix_cppflags in
7633 case $cf_add_cflags in
7634 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
7635 case $cf_add_cflags in
7637 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
7639 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
7640 && test -z "${cf_tst_cflags}" \
7641 && cf_fix_cppflags=yes
7643 if test $cf_fix_cppflags = yes ; then
7645 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
7646 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
7649 elif test "${cf_tst_cflags}" = "\"'" ; then
7651 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
7652 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
7662 case $cf_add_cflags in
7664 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
7666 CPPFLAGS=`echo "$CPPFLAGS" | \
7667 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
7668 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
7673 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
7674 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
7681 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
7682 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
7689 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
7690 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
7692 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
7694 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
7695 && test -z "${cf_tst_cflags}" \
7696 && cf_fix_cppflags=no
7701 if test -n "$cf_new_cflags" ; then
7703 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
7704 CFLAGS="${CFLAGS}$cf_new_cflags"
7708 if test -n "$cf_new_cppflags" ; then
7710 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
7711 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
7715 if test -n "$cf_new_extra_cppflags" ; then
7717 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
7718 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
7725 for cf_add_1lib in $cf_pkg_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
7727 for cf_add_1lib in $cf_add_0lib; do
7728 for cf_add_2lib in $cf_add_libs; do
7729 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
7734 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
7738 cat >conftest.$ac_ext <<_ACEOF
7739 #line 7739 "configure"
7740 #include "confdefs.h"
7741 #include <${cf_cv_ncurses_header:-curses.h}>
7745 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
7750 rm -f conftest.$ac_objext conftest$ac_exeext
7751 if { (eval echo "$as_me:7751: \"$ac_link\"") >&5
7752 (eval $ac_link) 2>&5
7754 echo "$as_me:7754: \$? = $ac_status" >&5
7755 (exit $ac_status); } &&
7756 { ac_try='test -s conftest$ac_exeext'
7757 { (eval echo "$as_me:7757: \"$ac_try\"") >&5
7760 echo "$as_me:7760: \$? = $ac_status" >&5
7761 (exit $ac_status); }; }; then
7762 if test "$cross_compiling" = yes; then
7763 cf_test_ncuconfig=maybe
7765 cat >conftest.$ac_ext <<_ACEOF
7766 #line 7766 "configure"
7767 #include "confdefs.h"
7768 #include <${cf_cv_ncurses_header:-curses.h}>
7770 { char *xx = curses_version(); return (xx == 0); }
7772 rm -f conftest$ac_exeext
7773 if { (eval echo "$as_me:7773: \"$ac_link\"") >&5
7774 (eval $ac_link) 2>&5
7776 echo "$as_me:7776: \$? = $ac_status" >&5
7777 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
7778 { (eval echo "$as_me:7778: \"$ac_try\"") >&5
7781 echo "$as_me:7781: \$? = $ac_status" >&5
7782 (exit $ac_status); }; }; then
7783 cf_test_ncuconfig=yes
7785 echo "$as_me: program exited with status $ac_status" >&5
7786 echo "$as_me: failed program was:" >&5
7787 cat conftest.$ac_ext >&5
7788 cf_test_ncuconfig=no
7790 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
7793 echo "$as_me: failed program was:" >&5
7794 cat conftest.$ac_ext >&5
7795 cf_test_ncuconfig=no
7797 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7799 CFLAGS="$cf_save_CFLAGS"
7800 CPPFLAGS="$cf_save_CPPFLAGS"
7801 LIBS="$cf_save_LIBS"
7803 if test "x$cf_test_ncuconfig" != xyes; then
7804 cf_temp=`echo "x$cf_pkg_cflags" | sed -e s/^x// -e 's/-W[^ ]*//g'`
7805 cf_pkg_cflags="$cf_temp"
7806 cf_temp=`echo "x$cf_pkg_libs" | sed -e s/^x// -e 's/-W[^ ]*//g'`
7807 cf_pkg_libs="$cf_temp"
7815 cf_new_extra_cppflags=
7817 for cf_add_cflags in $cf_pkg_cflags
7819 case $cf_fix_cppflags in
7821 case $cf_add_cflags in
7822 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
7823 case $cf_add_cflags in
7825 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
7827 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
7828 && test -z "${cf_tst_cflags}" \
7829 && cf_fix_cppflags=yes
7831 if test $cf_fix_cppflags = yes ; then
7833 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
7834 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
7837 elif test "${cf_tst_cflags}" = "\"'" ; then
7839 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
7840 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
7850 case $cf_add_cflags in
7852 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
7854 CPPFLAGS=`echo "$CPPFLAGS" | \
7855 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
7856 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
7861 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
7862 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
7869 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
7870 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
7877 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
7878 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
7880 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
7882 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
7883 && test -z "${cf_tst_cflags}" \
7884 && cf_fix_cppflags=no
7889 if test -n "$cf_new_cflags" ; then
7891 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
7892 CFLAGS="${CFLAGS}$cf_new_cflags"
7896 if test -n "$cf_new_cppflags" ; then
7898 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
7899 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
7903 if test -n "$cf_new_extra_cppflags" ; then
7905 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
7906 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
7913 for cf_add_1lib in $cf_pkg_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
7915 for cf_add_1lib in $cf_add_0lib; do
7916 for cf_add_2lib in $cf_add_libs; do
7917 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
7922 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
7926 cat >conftest.$ac_ext <<_ACEOF
7927 #line 7927 "configure"
7928 #include "confdefs.h"
7929 #include <${cf_cv_ncurses_header:-curses.h}>
7933 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
7938 rm -f conftest.$ac_objext conftest$ac_exeext
7939 if { (eval echo "$as_me:7939: \"$ac_link\"") >&5
7940 (eval $ac_link) 2>&5
7942 echo "$as_me:7942: \$? = $ac_status" >&5
7943 (exit $ac_status); } &&
7944 { ac_try='test -s conftest$ac_exeext'
7945 { (eval echo "$as_me:7945: \"$ac_try\"") >&5
7948 echo "$as_me:7948: \$? = $ac_status" >&5
7949 (exit $ac_status); }; }; then
7950 if test "$cross_compiling" = yes; then
7951 cf_have_ncuconfig=maybe
7953 cat >conftest.$ac_ext <<_ACEOF
7954 #line 7954 "configure"
7955 #include "confdefs.h"
7956 #include <${cf_cv_ncurses_header:-curses.h}>
7958 { char *xx = curses_version(); return (xx == 0); }
7960 rm -f conftest$ac_exeext
7961 if { (eval echo "$as_me:7961: \"$ac_link\"") >&5
7962 (eval $ac_link) 2>&5
7964 echo "$as_me:7964: \$? = $ac_status" >&5
7965 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
7966 { (eval echo "$as_me:7966: \"$ac_try\"") >&5
7969 echo "$as_me:7969: \$? = $ac_status" >&5
7970 (exit $ac_status); }; }; then
7971 cf_have_ncuconfig=yes
7973 echo "$as_me: program exited with status $ac_status" >&5
7974 echo "$as_me: failed program was:" >&5
7975 cat conftest.$ac_ext >&5
7976 cf_have_ncuconfig=no
7978 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
7981 echo "$as_me: failed program was:" >&5
7982 cat conftest.$ac_ext >&5
7983 cf_have_ncuconfig=no
7985 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7986 echo "$as_me:7986: result: $cf_have_ncuconfig" >&5
7987 echo "${ECHO_T}$cf_have_ncuconfig" >&6
7988 test "$cf_have_ncuconfig" = maybe && cf_have_ncuconfig=yes
7989 if test "$cf_have_ncuconfig" != "yes"
7991 CPPFLAGS="$cf_save_CPPFLAGS"
7992 LIBS="$cf_save_LIBS"
7993 NCURSES_CONFIG_PKG=none
7996 cat >>confdefs.h <<\EOF
8000 NCURSES_CONFIG_PKG=$cf_ncuconfig_root
8002 echo "$as_me:8002: checking for terminfo header" >&5
8003 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
8004 if test "${cf_cv_term_header+set}" = set; then
8005 echo $ECHO_N "(cached) $ECHO_C" >&6
8008 case ${cf_cv_ncurses_header} in
8009 (*/ncurses.h|*/ncursesw.h)
8010 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
8013 cf_term_header=term.h
8017 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
8019 cat >conftest.$ac_ext <<_ACEOF
8020 #line 8020 "configure"
8021 #include "confdefs.h"
8023 #include <${cf_cv_ncurses_header:-curses.h}>
8029 int x = auto_left_margin; (void)x
8034 rm -f conftest.$ac_objext
8035 if { (eval echo "$as_me:8035: \"$ac_compile\"") >&5
8036 (eval $ac_compile) 2>&5
8038 echo "$as_me:8038: \$? = $ac_status" >&5
8039 (exit $ac_status); } &&
8040 { ac_try='test -s conftest.$ac_objext'
8041 { (eval echo "$as_me:8041: \"$ac_try\"") >&5
8044 echo "$as_me:8044: \$? = $ac_status" >&5
8045 (exit $ac_status); }; }; then
8047 cf_cv_term_header="$cf_test"
8049 echo "$as_me: failed program was:" >&5
8050 cat conftest.$ac_ext >&5
8052 cf_cv_term_header=unknown
8055 rm -f conftest.$ac_objext conftest.$ac_ext
8056 test "$cf_cv_term_header" != unknown && break
8060 echo "$as_me:8060: result: $cf_cv_term_header" >&5
8061 echo "${ECHO_T}$cf_cv_term_header" >&6
8063 # Set definitions to allow ifdef'ing to accommodate subdirectories
8065 case $cf_cv_term_header in
8068 cat >>confdefs.h <<\EOF
8069 #define HAVE_TERM_H 1
8075 case $cf_cv_term_header in
8078 cat >>confdefs.h <<\EOF
8079 #define HAVE_NCURSES_TERM_H 1
8085 cat >>confdefs.h <<\EOF
8086 #define HAVE_NCURSESW_TERM_H 1
8095 echo "$as_me:8095: result: no" >&5
8096 echo "${ECHO_T}no" >&6
8097 NCURSES_CONFIG_PKG=none
8100 NCURSES_CONFIG_PKG=none
8103 if test "x$cf_have_ncuconfig" = "xno"; then
8104 cf_ncurses_config="${cf_ncuconfig_root}${NCURSES_CONFIG_SUFFIX}-config"; echo "Looking for ${cf_ncurses_config}"
8106 if test -n "$ac_tool_prefix"; then
8107 for ac_prog in ${cf_ncurses_config} ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
8109 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
8110 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
8111 echo "$as_me:8111: checking for $ac_word" >&5
8112 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
8113 if test "${ac_cv_prog_NCURSES_CONFIG+set}" = set; then
8114 echo $ECHO_N "(cached) $ECHO_C" >&6
8116 if test -n "$NCURSES_CONFIG"; then
8117 ac_cv_prog_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test.
8119 ac_save_IFS=$IFS; IFS=$ac_path_separator
8121 for ac_dir in $ac_dummy; do
8123 test -z "$ac_dir" && ac_dir=.
8124 $as_executable_p "$ac_dir/$ac_word" || continue
8125 ac_cv_prog_NCURSES_CONFIG="$ac_tool_prefix$ac_prog"
8126 echo "$as_me:8126: found $ac_dir/$ac_word" >&5
8132 NCURSES_CONFIG=$ac_cv_prog_NCURSES_CONFIG
8133 if test -n "$NCURSES_CONFIG"; then
8134 echo "$as_me:8134: result: $NCURSES_CONFIG" >&5
8135 echo "${ECHO_T}$NCURSES_CONFIG" >&6
8137 echo "$as_me:8137: result: no" >&5
8138 echo "${ECHO_T}no" >&6
8141 test -n "$NCURSES_CONFIG" && break
8144 if test -z "$NCURSES_CONFIG"; then
8145 ac_ct_NCURSES_CONFIG=$NCURSES_CONFIG
8146 for ac_prog in ${cf_ncurses_config} ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
8148 # Extract the first word of "$ac_prog", so it can be a program name with args.
8149 set dummy $ac_prog; ac_word=$2
8150 echo "$as_me:8150: checking for $ac_word" >&5
8151 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
8152 if test "${ac_cv_prog_ac_ct_NCURSES_CONFIG+set}" = set; then
8153 echo $ECHO_N "(cached) $ECHO_C" >&6
8155 if test -n "$ac_ct_NCURSES_CONFIG"; then
8156 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_ct_NCURSES_CONFIG" # Let the user override the test.
8158 ac_save_IFS=$IFS; IFS=$ac_path_separator
8160 for ac_dir in $ac_dummy; do
8162 test -z "$ac_dir" && ac_dir=.
8163 $as_executable_p "$ac_dir/$ac_word" || continue
8164 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_prog"
8165 echo "$as_me:8165: found $ac_dir/$ac_word" >&5
8171 ac_ct_NCURSES_CONFIG=$ac_cv_prog_ac_ct_NCURSES_CONFIG
8172 if test -n "$ac_ct_NCURSES_CONFIG"; then
8173 echo "$as_me:8173: result: $ac_ct_NCURSES_CONFIG" >&5
8174 echo "${ECHO_T}$ac_ct_NCURSES_CONFIG" >&6
8176 echo "$as_me:8176: result: no" >&5
8177 echo "${ECHO_T}no" >&6
8180 test -n "$ac_ct_NCURSES_CONFIG" && break
8182 test -n "$ac_ct_NCURSES_CONFIG" || ac_ct_NCURSES_CONFIG="none"
8184 NCURSES_CONFIG=$ac_ct_NCURSES_CONFIG
8187 if test "$NCURSES_CONFIG" != none ; then
8192 cf_new_extra_cppflags=
8194 for cf_add_cflags in `$NCURSES_CONFIG --cflags`
8196 case $cf_fix_cppflags in
8198 case $cf_add_cflags in
8199 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
8200 case $cf_add_cflags in
8202 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
8204 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
8205 && test -z "${cf_tst_cflags}" \
8206 && cf_fix_cppflags=yes
8208 if test $cf_fix_cppflags = yes ; then
8210 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
8211 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
8214 elif test "${cf_tst_cflags}" = "\"'" ; then
8216 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
8217 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
8227 case $cf_add_cflags in
8229 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
8231 CPPFLAGS=`echo "$CPPFLAGS" | \
8232 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
8233 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
8238 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
8239 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
8246 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
8247 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
8254 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
8255 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
8257 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
8259 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
8260 && test -z "${cf_tst_cflags}" \
8261 && cf_fix_cppflags=no
8266 if test -n "$cf_new_cflags" ; then
8268 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
8269 CFLAGS="${CFLAGS}$cf_new_cflags"
8273 if test -n "$cf_new_cppflags" ; then
8275 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
8276 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
8280 if test -n "$cf_new_extra_cppflags" ; then
8282 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
8283 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
8290 for cf_add_1lib in `$NCURSES_CONFIG --libs`; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
8292 for cf_add_1lib in $cf_add_0lib; do
8293 for cf_add_2lib in $cf_add_libs; do
8294 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
8299 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
8303 # even with config script, some packages use no-override for curses.h
8305 echo "$as_me:8305: checking if we have identified curses headers" >&5
8306 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
8307 if test "${cf_cv_ncurses_header+set}" = set; then
8308 echo $ECHO_N "(cached) $ECHO_C" >&6
8311 cf_cv_ncurses_header=none
8313 ncurses.h $cf_cv_screen/ncurses.h \
8314 curses.h $cf_cv_screen/curses.h
8316 cat >conftest.$ac_ext <<_ACEOF
8317 #line 8317 "configure"
8318 #include "confdefs.h"
8319 #include <${cf_header}>
8323 initscr(); tgoto("?", 0,0)
8328 rm -f conftest.$ac_objext
8329 if { (eval echo "$as_me:8329: \"$ac_compile\"") >&5
8330 (eval $ac_compile) 2>&5
8332 echo "$as_me:8332: \$? = $ac_status" >&5
8333 (exit $ac_status); } &&
8334 { ac_try='test -s conftest.$ac_objext'
8335 { (eval echo "$as_me:8335: \"$ac_try\"") >&5
8338 echo "$as_me:8338: \$? = $ac_status" >&5
8339 (exit $ac_status); }; }; then
8340 cf_cv_ncurses_header=$cf_header; break
8342 echo "$as_me: failed program was:" >&5
8343 cat conftest.$ac_ext >&5
8345 rm -f conftest.$ac_objext conftest.$ac_ext
8349 echo "$as_me:8349: result: $cf_cv_ncurses_header" >&5
8350 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
8352 if test "$cf_cv_ncurses_header" = none ; then
8353 { { echo "$as_me:8353: error: No curses header-files found" >&5
8354 echo "$as_me: error: No curses header-files found" >&2;}
8355 { (exit 1); exit 1; }; }
8358 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
8360 for ac_header in $cf_cv_ncurses_header
8362 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8363 echo "$as_me:8363: checking for $ac_header" >&5
8364 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8365 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8366 echo $ECHO_N "(cached) $ECHO_C" >&6
8368 cat >conftest.$ac_ext <<_ACEOF
8369 #line 8369 "configure"
8370 #include "confdefs.h"
8371 #include <$ac_header>
8373 if { (eval echo "$as_me:8373: \"$ac_cpp conftest.$ac_ext\"") >&5
8374 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8376 egrep -v '^ *\+' conftest.er1 >conftest.err
8378 cat conftest.err >&5
8379 echo "$as_me:8379: \$? = $ac_status" >&5
8380 (exit $ac_status); } >/dev/null; then
8381 if test -s conftest.err; then
8382 ac_cpp_err=$ac_c_preproc_warn_flag
8389 if test -z "$ac_cpp_err"; then
8390 eval "$as_ac_Header=yes"
8392 echo "$as_me: failed program was:" >&5
8393 cat conftest.$ac_ext >&5
8394 eval "$as_ac_Header=no"
8396 rm -f conftest.err conftest.$ac_ext
8398 echo "$as_me:8398: result: `eval echo '${'$as_ac_Header'}'`" >&5
8399 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8400 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8401 cat >>confdefs.h <<EOF
8402 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8408 cat >>confdefs.h <<\EOF
8412 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
8414 cat >>confdefs.h <<EOF
8415 #define $cf_nculib_ROOT 1
8418 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
8422 cf_ncuhdr_root=$cf_cv_screen
8424 test -n "$cf_cv_curses_dir" && \
8425 test "$cf_cv_curses_dir" != "no" && { \
8427 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
8428 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
8430 while test $cf_add_incdir != /usr/include
8432 if test -d $cf_add_incdir
8435 if test -n "$CFLAGS$CPPFLAGS" ; then
8436 # a loop is needed to ensure we can add subdirs of existing dirs
8437 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
8438 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
8439 cf_have_incdir=yes; break
8444 if test "$cf_have_incdir" = no ; then
8445 if test "$cf_add_incdir" = /usr/local/include ; then
8446 if test "$GCC" = yes
8448 cf_save_CPPFLAGS=$CPPFLAGS
8450 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
8451 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
8453 cat >conftest.$ac_ext <<_ACEOF
8454 #line 8454 "configure"
8455 #include "confdefs.h"
8465 rm -f conftest.$ac_objext
8466 if { (eval echo "$as_me:8466: \"$ac_compile\"") >&5
8467 (eval $ac_compile) 2>&5
8469 echo "$as_me:8469: \$? = $ac_status" >&5
8470 (exit $ac_status); } &&
8471 { ac_try='test -s conftest.$ac_objext'
8472 { (eval echo "$as_me:8472: \"$ac_try\"") >&5
8475 echo "$as_me:8475: \$? = $ac_status" >&5
8476 (exit $ac_status); }; }; then
8479 echo "$as_me: failed program was:" >&5
8480 cat conftest.$ac_ext >&5
8483 rm -f conftest.$ac_objext conftest.$ac_ext
8484 CPPFLAGS=$cf_save_CPPFLAGS
8489 if test "$cf_have_incdir" = no ; then
8490 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
8492 echo "${as_me:-configure}:8492: testing adding $cf_add_incdir to include-path ..." 1>&5
8494 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8496 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
8497 test "$cf_top_incdir" = "$cf_add_incdir" && break
8498 cf_add_incdir="$cf_top_incdir"
8511 echo "$as_me:8511: checking for $cf_ncuhdr_root header in include-path" >&5
8512 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
8513 if test "${cf_cv_ncurses_h+set}" = set; then
8514 echo $ECHO_N "(cached) $ECHO_C" >&6
8517 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
8518 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
8519 for cf_header in $cf_header_list
8522 cat >conftest.$ac_ext <<_ACEOF
8523 #line 8523 "configure"
8524 #include "confdefs.h"
8526 #include <$cf_header>
8531 #ifdef NCURSES_VERSION
8533 printf("%s\n", NCURSES_VERSION);
8546 rm -f conftest.$ac_objext
8547 if { (eval echo "$as_me:8547: \"$ac_compile\"") >&5
8548 (eval $ac_compile) 2>&5
8550 echo "$as_me:8550: \$? = $ac_status" >&5
8551 (exit $ac_status); } &&
8552 { ac_try='test -s conftest.$ac_objext'
8553 { (eval echo "$as_me:8553: \"$ac_try\"") >&5
8556 echo "$as_me:8556: \$? = $ac_status" >&5
8557 (exit $ac_status); }; }; then
8558 cf_cv_ncurses_h=$cf_header
8561 echo "$as_me: failed program was:" >&5
8562 cat conftest.$ac_ext >&5
8565 rm -f conftest.$ac_objext conftest.$ac_ext
8567 test "$cf_cv_ncurses_h" != no && break
8571 echo "$as_me:8571: result: $cf_cv_ncurses_h" >&5
8572 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
8574 if test "$cf_cv_ncurses_h" != no ; then
8575 cf_cv_ncurses_header=$cf_cv_ncurses_h
8578 echo "$as_me:8578: checking for $cf_ncuhdr_root include-path" >&5
8579 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
8580 if test "${cf_cv_ncurses_h2+set}" = set; then
8581 echo $ECHO_N "(cached) $ECHO_C" >&6
8584 test -n "$verbose" && echo
8588 # collect the current set of include-directories from compiler flags
8589 cf_header_path_list=""
8590 if test -n "${CFLAGS}${CPPFLAGS}" ; then
8591 for cf_header_path in $CPPFLAGS $CFLAGS
8593 case $cf_header_path in
8595 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
8597 test "x$cf_header_path" != "xNONE" && \
8598 test -d "$cf_header_path" && \
8600 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
8601 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
8602 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
8603 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
8604 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
8605 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"
8608 cf_header_path_list="$cf_header_path_list $cf_search"
8614 # add the variations for the package we are looking for
8618 test "x$prefix" != "xNONE" && \
8619 test -d "$prefix" && \
8621 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
8622 test -d $prefix/include && cf_search="$cf_search $prefix/include"
8623 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
8624 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
8625 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
8626 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
8629 for cf_subdir_prefix in \
8638 test "x$cf_subdir_prefix" != "x$prefix" && \
8639 test -d "$cf_subdir_prefix" && \
8640 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
8641 test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
8642 test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include"
8643 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root"
8644 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root/include"
8645 test -d $cf_subdir_prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include"
8646 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"
8651 test "$includedir" != NONE && \
8652 test "$includedir" != "/usr/include" && \
8653 test -d "$includedir" && {
8654 test -d $includedir && cf_search="$cf_search $includedir"
8655 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
8658 test "$oldincludedir" != NONE && \
8659 test "$oldincludedir" != "/usr/include" && \
8660 test -d "$oldincludedir" && {
8661 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
8662 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
8665 cf_search="$cf_search $cf_header_path_list"
8667 test -n "$verbose" && echo search path $cf_search
8668 cf_save2_CPPFLAGS="$CPPFLAGS"
8669 for cf_incdir in $cf_search
8672 if test -n "$cf_incdir" ; then
8673 for cf_add_incdir in $cf_incdir
8675 while test $cf_add_incdir != /usr/include
8677 if test -d $cf_add_incdir
8680 if test -n "$CFLAGS$CPPFLAGS" ; then
8681 # a loop is needed to ensure we can add subdirs of existing dirs
8682 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
8683 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
8684 cf_have_incdir=yes; break
8689 if test "$cf_have_incdir" = no ; then
8690 if test "$cf_add_incdir" = /usr/local/include ; then
8691 if test "$GCC" = yes
8693 cf_save_CPPFLAGS=$CPPFLAGS
8695 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
8696 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
8698 cat >conftest.$ac_ext <<_ACEOF
8699 #line 8699 "configure"
8700 #include "confdefs.h"
8710 rm -f conftest.$ac_objext
8711 if { (eval echo "$as_me:8711: \"$ac_compile\"") >&5
8712 (eval $ac_compile) 2>&5
8714 echo "$as_me:8714: \$? = $ac_status" >&5
8715 (exit $ac_status); } &&
8716 { ac_try='test -s conftest.$ac_objext'
8717 { (eval echo "$as_me:8717: \"$ac_try\"") >&5
8720 echo "$as_me:8720: \$? = $ac_status" >&5
8721 (exit $ac_status); }; }; then
8724 echo "$as_me: failed program was:" >&5
8725 cat conftest.$ac_ext >&5
8728 rm -f conftest.$ac_objext conftest.$ac_ext
8729 CPPFLAGS=$cf_save_CPPFLAGS
8734 if test "$cf_have_incdir" = no ; then
8735 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
8737 echo "${as_me:-configure}:8737: testing adding $cf_add_incdir to include-path ..." 1>&5
8739 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8741 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
8742 test "$cf_top_incdir" = "$cf_add_incdir" && break
8743 cf_add_incdir="$cf_top_incdir"
8759 cat >conftest.$ac_ext <<_ACEOF
8760 #line 8760 "configure"
8761 #include "confdefs.h"
8763 #include <$cf_header>
8768 #ifdef NCURSES_VERSION
8770 printf("%s\n", NCURSES_VERSION);
8783 rm -f conftest.$ac_objext
8784 if { (eval echo "$as_me:8784: \"$ac_compile\"") >&5
8785 (eval $ac_compile) 2>&5
8787 echo "$as_me:8787: \$? = $ac_status" >&5
8788 (exit $ac_status); } &&
8789 { ac_try='test -s conftest.$ac_objext'
8790 { (eval echo "$as_me:8790: \"$ac_try\"") >&5
8793 echo "$as_me:8793: \$? = $ac_status" >&5
8794 (exit $ac_status); }; }; then
8795 cf_cv_ncurses_h2=$cf_header
8798 echo "$as_me: failed program was:" >&5
8799 cat conftest.$ac_ext >&5
8802 rm -f conftest.$ac_objext conftest.$ac_ext
8804 if test "$cf_cv_ncurses_h2" != no ; then
8805 cf_cv_ncurses_h2=$cf_incdir/$cf_header
8806 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
8809 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
8811 CPPFLAGS="$cf_save2_CPPFLAGS"
8812 test "$cf_cv_ncurses_h2" != no && break
8814 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:8814: error: not found" >&5
8815 echo "$as_me: error: not found" >&2;}
8816 { (exit 1); exit 1; }; }
8819 echo "$as_me:8819: result: $cf_cv_ncurses_h2" >&5
8820 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
8822 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
8823 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
8824 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
8825 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
8828 if test -n "$cf_1st_incdir" ; then
8829 for cf_add_incdir in $cf_1st_incdir
8831 while test $cf_add_incdir != /usr/include
8833 if test -d $cf_add_incdir
8836 if test -n "$CFLAGS$CPPFLAGS" ; then
8837 # a loop is needed to ensure we can add subdirs of existing dirs
8838 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
8839 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
8840 cf_have_incdir=yes; break
8845 if test "$cf_have_incdir" = no ; then
8846 if test "$cf_add_incdir" = /usr/local/include ; then
8847 if test "$GCC" = yes
8849 cf_save_CPPFLAGS=$CPPFLAGS
8851 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
8852 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
8854 cat >conftest.$ac_ext <<_ACEOF
8855 #line 8855 "configure"
8856 #include "confdefs.h"
8866 rm -f conftest.$ac_objext
8867 if { (eval echo "$as_me:8867: \"$ac_compile\"") >&5
8868 (eval $ac_compile) 2>&5
8870 echo "$as_me:8870: \$? = $ac_status" >&5
8871 (exit $ac_status); } &&
8872 { ac_try='test -s conftest.$ac_objext'
8873 { (eval echo "$as_me:8873: \"$ac_try\"") >&5
8876 echo "$as_me:8876: \$? = $ac_status" >&5
8877 (exit $ac_status); }; }; then
8880 echo "$as_me: failed program was:" >&5
8881 cat conftest.$ac_ext >&5
8884 rm -f conftest.$ac_objext conftest.$ac_ext
8885 CPPFLAGS=$cf_save_CPPFLAGS
8890 if test "$cf_have_incdir" = no ; then
8891 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
8893 echo "${as_me:-configure}:8893: testing adding $cf_add_incdir to include-path ..." 1>&5
8895 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8897 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
8898 test "$cf_top_incdir" = "$cf_add_incdir" && break
8899 cf_add_incdir="$cf_top_incdir"
8912 # Set definitions to allow ifdef'ing for ncurses.h
8914 case $cf_cv_ncurses_header in
8917 cat >>confdefs.h <<\EOF
8918 #define HAVE_NCURSES_H 1
8924 case $cf_cv_ncurses_header in
8925 (ncurses/curses.h|ncurses/ncurses.h)
8927 cat >>confdefs.h <<\EOF
8928 #define HAVE_NCURSES_NCURSES_H 1
8932 (ncursesw/curses.h|ncursesw/ncurses.h)
8934 cat >>confdefs.h <<\EOF
8935 #define HAVE_NCURSESW_NCURSES_H 1
8941 echo "$as_me:8941: checking for terminfo header" >&5
8942 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
8943 if test "${cf_cv_term_header+set}" = set; then
8944 echo $ECHO_N "(cached) $ECHO_C" >&6
8947 case ${cf_cv_ncurses_header} in
8948 (*/ncurses.h|*/ncursesw.h)
8949 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
8952 cf_term_header=term.h
8956 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
8958 cat >conftest.$ac_ext <<_ACEOF
8959 #line 8959 "configure"
8960 #include "confdefs.h"
8962 #include <${cf_cv_ncurses_header:-curses.h}>
8968 int x = auto_left_margin; (void)x
8973 rm -f conftest.$ac_objext
8974 if { (eval echo "$as_me:8974: \"$ac_compile\"") >&5
8975 (eval $ac_compile) 2>&5
8977 echo "$as_me:8977: \$? = $ac_status" >&5
8978 (exit $ac_status); } &&
8979 { ac_try='test -s conftest.$ac_objext'
8980 { (eval echo "$as_me:8980: \"$ac_try\"") >&5
8983 echo "$as_me:8983: \$? = $ac_status" >&5
8984 (exit $ac_status); }; }; then
8986 cf_cv_term_header="$cf_test"
8988 echo "$as_me: failed program was:" >&5
8989 cat conftest.$ac_ext >&5
8991 cf_cv_term_header=unknown
8994 rm -f conftest.$ac_objext conftest.$ac_ext
8995 test "$cf_cv_term_header" != unknown && break
8999 echo "$as_me:8999: result: $cf_cv_term_header" >&5
9000 echo "${ECHO_T}$cf_cv_term_header" >&6
9002 # Set definitions to allow ifdef'ing to accommodate subdirectories
9004 case $cf_cv_term_header in
9007 cat >>confdefs.h <<\EOF
9008 #define HAVE_TERM_H 1
9014 case $cf_cv_term_header in
9017 cat >>confdefs.h <<\EOF
9018 #define HAVE_NCURSES_TERM_H 1
9024 cat >>confdefs.h <<\EOF
9025 #define HAVE_NCURSESW_TERM_H 1
9031 # some applications need this, but should check for NCURSES_VERSION
9033 cat >>confdefs.h <<\EOF
9037 echo "$as_me:9037: checking for ncurses version" >&5
9038 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
9039 if test "${cf_cv_ncurses_version+set}" = set; then
9040 echo $ECHO_N "(cached) $ECHO_C" >&6
9043 cf_cv_ncurses_version=no
9046 if test "$cross_compiling" = yes; then
9048 # This will not work if the preprocessor splits the line after the
9049 # Autoconf token. The 'unproto' program does that.
9050 cat > conftest.$ac_ext <<EOF
9051 #include <${cf_cv_ncurses_header:-curses.h}>
9053 #ifdef NCURSES_VERSION
9054 Autoconf NCURSES_VERSION
9062 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
9063 { (eval echo "$as_me:9063: \"$cf_try\"") >&5
9066 echo "$as_me:9066: \$? = $ac_status" >&5
9067 (exit $ac_status); }
9068 if test -f conftest.out ; then
9069 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
9070 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
9075 cat >conftest.$ac_ext <<_ACEOF
9076 #line 9076 "configure"
9077 #include "confdefs.h"
9079 #include <${cf_cv_ncurses_header:-curses.h}>
9083 FILE *fp = fopen("$cf_tempfile", "w");
9084 #ifdef NCURSES_VERSION
9085 # ifdef NCURSES_VERSION_PATCH
9086 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
9088 fprintf(fp, "%s\n", NCURSES_VERSION);
9092 fprintf(fp, "old\n");
9097 ${cf_cv_main_return:-return}(0);
9100 rm -f conftest$ac_exeext
9101 if { (eval echo "$as_me:9101: \"$ac_link\"") >&5
9102 (eval $ac_link) 2>&5
9104 echo "$as_me:9104: \$? = $ac_status" >&5
9105 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
9106 { (eval echo "$as_me:9106: \"$ac_try\"") >&5
9109 echo "$as_me:9109: \$? = $ac_status" >&5
9110 (exit $ac_status); }; }; then
9112 cf_cv_ncurses_version=`cat $cf_tempfile`
9114 echo "$as_me: program exited with status $ac_status" >&5
9115 echo "$as_me: failed program was:" >&5
9116 cat conftest.$ac_ext >&5
9118 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
9123 echo "$as_me:9123: result: $cf_cv_ncurses_version" >&5
9124 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
9125 test "$cf_cv_ncurses_version" = no ||
9126 cat >>confdefs.h <<\EOF
9130 cf_nculib_root=$cf_cv_screen
9131 # This works, except for the special case where we find gpm, but
9132 # ncurses is in a nonstandard location via $LIBS, and we really want
9135 cf_ncurses_SAVE="$LIBS"
9136 echo "$as_me:9136: checking for Gpm_Open in -lgpm" >&5
9137 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
9138 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
9139 echo $ECHO_N "(cached) $ECHO_C" >&6
9141 ac_check_lib_save_LIBS=$LIBS
9143 cat >conftest.$ac_ext <<_ACEOF
9144 #line 9144 "configure"
9145 #include "confdefs.h"
9147 /* Override any gcc2 internal prototype to avoid an error. */
9151 /* We use char because int might match the return type of a gcc2
9152 builtin and then its argument prototype would still apply. */
9162 rm -f conftest.$ac_objext conftest$ac_exeext
9163 if { (eval echo "$as_me:9163: \"$ac_link\"") >&5
9164 (eval $ac_link) 2>&5
9166 echo "$as_me:9166: \$? = $ac_status" >&5
9167 (exit $ac_status); } &&
9168 { ac_try='test -s conftest$ac_exeext'
9169 { (eval echo "$as_me:9169: \"$ac_try\"") >&5
9172 echo "$as_me:9172: \$? = $ac_status" >&5
9173 (exit $ac_status); }; }; then
9174 ac_cv_lib_gpm_Gpm_Open=yes
9176 echo "$as_me: failed program was:" >&5
9177 cat conftest.$ac_ext >&5
9178 ac_cv_lib_gpm_Gpm_Open=no
9180 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9181 LIBS=$ac_check_lib_save_LIBS
9183 echo "$as_me:9183: result: $ac_cv_lib_gpm_Gpm_Open" >&5
9184 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
9185 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
9186 echo "$as_me:9186: checking for initscr in -lgpm" >&5
9187 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
9188 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
9189 echo $ECHO_N "(cached) $ECHO_C" >&6
9191 ac_check_lib_save_LIBS=$LIBS
9193 cat >conftest.$ac_ext <<_ACEOF
9194 #line 9194 "configure"
9195 #include "confdefs.h"
9197 /* Override any gcc2 internal prototype to avoid an error. */
9201 /* We use char because int might match the return type of a gcc2
9202 builtin and then its argument prototype would still apply. */
9212 rm -f conftest.$ac_objext conftest$ac_exeext
9213 if { (eval echo "$as_me:9213: \"$ac_link\"") >&5
9214 (eval $ac_link) 2>&5
9216 echo "$as_me:9216: \$? = $ac_status" >&5
9217 (exit $ac_status); } &&
9218 { ac_try='test -s conftest$ac_exeext'
9219 { (eval echo "$as_me:9219: \"$ac_try\"") >&5
9222 echo "$as_me:9222: \$? = $ac_status" >&5
9223 (exit $ac_status); }; }; then
9224 ac_cv_lib_gpm_initscr=yes
9226 echo "$as_me: failed program was:" >&5
9227 cat conftest.$ac_ext >&5
9228 ac_cv_lib_gpm_initscr=no
9230 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9231 LIBS=$ac_check_lib_save_LIBS
9233 echo "$as_me:9233: result: $ac_cv_lib_gpm_initscr" >&5
9234 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
9235 if test $ac_cv_lib_gpm_initscr = yes; then
9236 LIBS="$cf_ncurses_SAVE"
9238 cf_ncurses_LIBS="-lgpm"
9245 # This is only necessary if you are linking against an obsolete
9246 # version of ncurses (but it should do no harm, since it's static).
9247 if test "$cf_nculib_root" = ncurses ; then
9248 echo "$as_me:9248: checking for tgoto in -lmytinfo" >&5
9249 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
9250 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
9251 echo $ECHO_N "(cached) $ECHO_C" >&6
9253 ac_check_lib_save_LIBS=$LIBS
9254 LIBS="-lmytinfo $LIBS"
9255 cat >conftest.$ac_ext <<_ACEOF
9256 #line 9256 "configure"
9257 #include "confdefs.h"
9259 /* Override any gcc2 internal prototype to avoid an error. */
9263 /* We use char because int might match the return type of a gcc2
9264 builtin and then its argument prototype would still apply. */
9274 rm -f conftest.$ac_objext conftest$ac_exeext
9275 if { (eval echo "$as_me:9275: \"$ac_link\"") >&5
9276 (eval $ac_link) 2>&5
9278 echo "$as_me:9278: \$? = $ac_status" >&5
9279 (exit $ac_status); } &&
9280 { ac_try='test -s conftest$ac_exeext'
9281 { (eval echo "$as_me:9281: \"$ac_try\"") >&5
9284 echo "$as_me:9284: \$? = $ac_status" >&5
9285 (exit $ac_status); }; }; then
9286 ac_cv_lib_mytinfo_tgoto=yes
9288 echo "$as_me: failed program was:" >&5
9289 cat conftest.$ac_ext >&5
9290 ac_cv_lib_mytinfo_tgoto=no
9292 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9293 LIBS=$ac_check_lib_save_LIBS
9295 echo "$as_me:9295: result: $ac_cv_lib_mytinfo_tgoto" >&5
9296 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
9297 if test $ac_cv_lib_mytinfo_tgoto = yes; then
9298 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
9308 for cf_add_1lib in $cf_ncurses_LIBS; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
9310 for cf_add_1lib in $cf_add_0lib; do
9311 for cf_add_2lib in $cf_add_libs; do
9312 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
9317 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
9321 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
9327 for cf_add_1lib in -l$cf_nculib_root; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
9329 for cf_add_1lib in $cf_add_0lib; do
9330 for cf_add_2lib in $cf_add_libs; do
9331 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
9336 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
9342 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
9344 echo "$as_me:9344: checking for initscr" >&5
9345 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
9346 if test "${ac_cv_func_initscr+set}" = set; then
9347 echo $ECHO_N "(cached) $ECHO_C" >&6
9349 cat >conftest.$ac_ext <<_ACEOF
9350 #line 9350 "configure"
9351 #include "confdefs.h"
9352 #define initscr autoconf_temporary
9353 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
9360 /* We use char because int might match the return type of a gcc2
9361 builtin and then its argument prototype would still apply. */
9362 char initscr (void);
9368 /* The GNU C library defines stubs for functions which it implements
9369 to always fail with ENOSYS. Some functions are actually named
9370 something starting with __ and the normal name is an alias. */
9371 #if defined (__stub_initscr) || defined (__stub___initscr)
9372 #error found stub for initscr
9380 rm -f conftest.$ac_objext conftest$ac_exeext
9381 if { (eval echo "$as_me:9381: \"$ac_link\"") >&5
9382 (eval $ac_link) 2>&5
9384 echo "$as_me:9384: \$? = $ac_status" >&5
9385 (exit $ac_status); } &&
9386 { ac_try='test -s conftest$ac_exeext'
9387 { (eval echo "$as_me:9387: \"$ac_try\"") >&5
9390 echo "$as_me:9390: \$? = $ac_status" >&5
9391 (exit $ac_status); }; }; then
9392 ac_cv_func_initscr=yes
9394 echo "$as_me: failed program was:" >&5
9395 cat conftest.$ac_ext >&5
9396 ac_cv_func_initscr=no
9398 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9400 echo "$as_me:9400: result: $ac_cv_func_initscr" >&5
9401 echo "${ECHO_T}$ac_cv_func_initscr" >&6
9402 if test $ac_cv_func_initscr = yes; then
9403 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
9406 cf_save_LIBS="$LIBS"
9407 echo "$as_me:9407: checking for initscr in -l$cf_nculib_root" >&5
9408 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
9409 LIBS="-l$cf_nculib_root $LIBS"
9410 cat >conftest.$ac_ext <<_ACEOF
9411 #line 9411 "configure"
9412 #include "confdefs.h"
9413 #include <${cf_cv_ncurses_header:-curses.h}>
9422 rm -f conftest.$ac_objext conftest$ac_exeext
9423 if { (eval echo "$as_me:9423: \"$ac_link\"") >&5
9424 (eval $ac_link) 2>&5
9426 echo "$as_me:9426: \$? = $ac_status" >&5
9427 (exit $ac_status); } &&
9428 { ac_try='test -s conftest$ac_exeext'
9429 { (eval echo "$as_me:9429: \"$ac_try\"") >&5
9432 echo "$as_me:9432: \$? = $ac_status" >&5
9433 (exit $ac_status); }; }; then
9434 echo "$as_me:9434: result: yes" >&5
9435 echo "${ECHO_T}yes" >&6
9436 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
9439 echo "$as_me: failed program was:" >&5
9440 cat conftest.$ac_ext >&5
9441 echo "$as_me:9441: result: no" >&5
9442 echo "${ECHO_T}no" >&6
9445 cf_library_path_list=""
9446 if test -n "${LDFLAGS}${LIBS}" ; then
9447 for cf_library_path in $LDFLAGS $LIBS
9449 case $cf_library_path in
9451 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
9453 test "x$cf_library_path" != "xNONE" && \
9454 test -d "$cf_library_path" && \
9456 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
9457 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
9458 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
9459 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
9460 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
9461 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"
9464 cf_library_path_list="$cf_library_path_list $cf_search"
9472 test "x$prefix" != "xNONE" && \
9473 test -d "$prefix" && \
9475 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
9476 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
9477 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
9478 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
9479 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
9480 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
9483 for cf_subdir_prefix in \
9492 test "x$cf_subdir_prefix" != "x$prefix" && \
9493 test -d "$cf_subdir_prefix" && \
9494 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
9495 test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
9496 test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib"
9497 test -d $cf_subdir_prefix/lib/$cf_nculib_root && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root"
9498 test -d $cf_subdir_prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root/lib"
9499 test -d $cf_subdir_prefix/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib"
9500 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"
9505 cf_search="$cf_library_path_list $cf_search"
9507 for cf_libdir in $cf_search
9509 echo "$as_me:9509: checking for -l$cf_nculib_root in $cf_libdir" >&5
9510 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
9511 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
9512 cat >conftest.$ac_ext <<_ACEOF
9513 #line 9513 "configure"
9514 #include "confdefs.h"
9515 #include <${cf_cv_ncurses_header:-curses.h}>
9524 rm -f conftest.$ac_objext conftest$ac_exeext
9525 if { (eval echo "$as_me:9525: \"$ac_link\"") >&5
9526 (eval $ac_link) 2>&5
9528 echo "$as_me:9528: \$? = $ac_status" >&5
9529 (exit $ac_status); } &&
9530 { ac_try='test -s conftest$ac_exeext'
9531 { (eval echo "$as_me:9531: \"$ac_try\"") >&5
9534 echo "$as_me:9534: \$? = $ac_status" >&5
9535 (exit $ac_status); }; }; then
9536 echo "$as_me:9536: result: yes" >&5
9537 echo "${ECHO_T}yes" >&6
9538 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
9541 echo "$as_me: failed program was:" >&5
9542 cat conftest.$ac_ext >&5
9543 echo "$as_me:9543: result: no" >&5
9544 echo "${ECHO_T}no" >&6
9545 LIBS="$cf_save_LIBS"
9547 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9551 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9555 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
9557 if test $cf_found_library = no ; then
9558 { { echo "$as_me:9558: error: Cannot link $cf_nculib_root library" >&5
9559 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
9560 { (exit 1); exit 1; }; }
9565 if test -n "$cf_ncurses_LIBS" ; then
9566 echo "$as_me:9566: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
9567 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
9568 cf_ncurses_SAVE="$LIBS"
9569 for p in $cf_ncurses_LIBS ; do
9570 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
9571 if test "$q" != "$LIBS" ; then
9575 cat >conftest.$ac_ext <<_ACEOF
9576 #line 9576 "configure"
9577 #include "confdefs.h"
9578 #include <${cf_cv_ncurses_header:-curses.h}>
9582 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
9587 rm -f conftest.$ac_objext conftest$ac_exeext
9588 if { (eval echo "$as_me:9588: \"$ac_link\"") >&5
9589 (eval $ac_link) 2>&5
9591 echo "$as_me:9591: \$? = $ac_status" >&5
9592 (exit $ac_status); } &&
9593 { ac_try='test -s conftest$ac_exeext'
9594 { (eval echo "$as_me:9594: \"$ac_try\"") >&5
9597 echo "$as_me:9597: \$? = $ac_status" >&5
9598 (exit $ac_status); }; }; then
9599 echo "$as_me:9599: result: yes" >&5
9600 echo "${ECHO_T}yes" >&6
9602 echo "$as_me: failed program was:" >&5
9603 cat conftest.$ac_ext >&5
9604 echo "$as_me:9604: result: no" >&5
9605 echo "${ECHO_T}no" >&6
9606 LIBS="$cf_ncurses_SAVE"
9608 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9611 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
9613 cat >>confdefs.h <<EOF
9614 #define $cf_nculib_ROOT 1
9625 cf_ncuconfig_root=$cf_cv_screen
9626 cf_have_ncuconfig=no
9628 if test "x${PKG_CONFIG:=none}" != xnone; then
9629 echo "$as_me:9629: checking pkg-config for $cf_ncuconfig_root" >&5
9630 echo $ECHO_N "checking pkg-config for $cf_ncuconfig_root... $ECHO_C" >&6
9631 if "$PKG_CONFIG" --exists $cf_ncuconfig_root ; then
9632 echo "$as_me:9632: result: yes" >&5
9633 echo "${ECHO_T}yes" >&6
9635 echo "$as_me:9635: checking if the $cf_ncuconfig_root package files work" >&5
9636 echo $ECHO_N "checking if the $cf_ncuconfig_root package files work... $ECHO_C" >&6
9637 cf_have_ncuconfig=unknown
9639 cf_save_CFLAGS="$CFLAGS"
9640 cf_save_CPPFLAGS="$CPPFLAGS"
9641 cf_save_LIBS="$LIBS"
9643 cf_pkg_cflags=`$PKG_CONFIG --cflags $cf_ncuconfig_root`
9644 cf_pkg_libs=`$PKG_CONFIG --libs $cf_ncuconfig_root`
9646 # while -W for passing linker flags is prevalent, it is not "standard".
9647 # At least one wrapper for c89/c99 (in Apple's xcode) has its own
9648 # incompatible _and_ non-standard -W option which gives an error. Work
9649 # around that pitfall.
9650 case "x${CC}@@${cf_pkg_libs}@${cf_pkg_cflags}" in
9656 cf_new_extra_cppflags=
9658 for cf_add_cflags in $cf_pkg_cflags
9660 case $cf_fix_cppflags in
9662 case $cf_add_cflags in
9663 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
9664 case $cf_add_cflags in
9666 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
9668 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
9669 && test -z "${cf_tst_cflags}" \
9670 && cf_fix_cppflags=yes
9672 if test $cf_fix_cppflags = yes ; then
9674 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9675 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9678 elif test "${cf_tst_cflags}" = "\"'" ; then
9680 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9681 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9691 case $cf_add_cflags in
9693 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
9695 CPPFLAGS=`echo "$CPPFLAGS" | \
9696 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
9697 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
9702 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
9703 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
9710 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
9711 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
9718 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9719 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9721 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
9723 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
9724 && test -z "${cf_tst_cflags}" \
9725 && cf_fix_cppflags=no
9730 if test -n "$cf_new_cflags" ; then
9732 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
9733 CFLAGS="${CFLAGS}$cf_new_cflags"
9737 if test -n "$cf_new_cppflags" ; then
9739 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
9740 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
9744 if test -n "$cf_new_extra_cppflags" ; then
9746 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
9747 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
9754 for cf_add_1lib in $cf_pkg_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
9756 for cf_add_1lib in $cf_add_0lib; do
9757 for cf_add_2lib in $cf_add_libs; do
9758 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
9763 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
9767 cat >conftest.$ac_ext <<_ACEOF
9768 #line 9768 "configure"
9769 #include "confdefs.h"
9770 #include <${cf_cv_ncurses_header:-curses.h}>
9774 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
9779 rm -f conftest.$ac_objext conftest$ac_exeext
9780 if { (eval echo "$as_me:9780: \"$ac_link\"") >&5
9781 (eval $ac_link) 2>&5
9783 echo "$as_me:9783: \$? = $ac_status" >&5
9784 (exit $ac_status); } &&
9785 { ac_try='test -s conftest$ac_exeext'
9786 { (eval echo "$as_me:9786: \"$ac_try\"") >&5
9789 echo "$as_me:9789: \$? = $ac_status" >&5
9790 (exit $ac_status); }; }; then
9791 if test "$cross_compiling" = yes; then
9792 cf_test_ncuconfig=maybe
9794 cat >conftest.$ac_ext <<_ACEOF
9795 #line 9795 "configure"
9796 #include "confdefs.h"
9797 #include <${cf_cv_ncurses_header:-curses.h}>
9799 { char *xx = curses_version(); return (xx == 0); }
9801 rm -f conftest$ac_exeext
9802 if { (eval echo "$as_me:9802: \"$ac_link\"") >&5
9803 (eval $ac_link) 2>&5
9805 echo "$as_me:9805: \$? = $ac_status" >&5
9806 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
9807 { (eval echo "$as_me:9807: \"$ac_try\"") >&5
9810 echo "$as_me:9810: \$? = $ac_status" >&5
9811 (exit $ac_status); }; }; then
9812 cf_test_ncuconfig=yes
9814 echo "$as_me: program exited with status $ac_status" >&5
9815 echo "$as_me: failed program was:" >&5
9816 cat conftest.$ac_ext >&5
9817 cf_test_ncuconfig=no
9819 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
9822 echo "$as_me: failed program was:" >&5
9823 cat conftest.$ac_ext >&5
9824 cf_test_ncuconfig=no
9826 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9828 CFLAGS="$cf_save_CFLAGS"
9829 CPPFLAGS="$cf_save_CPPFLAGS"
9830 LIBS="$cf_save_LIBS"
9832 if test "x$cf_test_ncuconfig" != xyes; then
9833 cf_temp=`echo "x$cf_pkg_cflags" | sed -e s/^x// -e 's/-W[^ ]*//g'`
9834 cf_pkg_cflags="$cf_temp"
9835 cf_temp=`echo "x$cf_pkg_libs" | sed -e s/^x// -e 's/-W[^ ]*//g'`
9836 cf_pkg_libs="$cf_temp"
9844 cf_new_extra_cppflags=
9846 for cf_add_cflags in $cf_pkg_cflags
9848 case $cf_fix_cppflags in
9850 case $cf_add_cflags in
9851 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
9852 case $cf_add_cflags in
9854 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
9856 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
9857 && test -z "${cf_tst_cflags}" \
9858 && cf_fix_cppflags=yes
9860 if test $cf_fix_cppflags = yes ; then
9862 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9863 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9866 elif test "${cf_tst_cflags}" = "\"'" ; then
9868 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9869 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9879 case $cf_add_cflags in
9881 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
9883 CPPFLAGS=`echo "$CPPFLAGS" | \
9884 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
9885 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
9890 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
9891 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
9898 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
9899 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
9906 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9907 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9909 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
9911 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
9912 && test -z "${cf_tst_cflags}" \
9913 && cf_fix_cppflags=no
9918 if test -n "$cf_new_cflags" ; then
9920 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
9921 CFLAGS="${CFLAGS}$cf_new_cflags"
9925 if test -n "$cf_new_cppflags" ; then
9927 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
9928 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
9932 if test -n "$cf_new_extra_cppflags" ; then
9934 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
9935 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
9942 for cf_add_1lib in $cf_pkg_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
9944 for cf_add_1lib in $cf_add_0lib; do
9945 for cf_add_2lib in $cf_add_libs; do
9946 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
9951 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
9955 cat >conftest.$ac_ext <<_ACEOF
9956 #line 9956 "configure"
9957 #include "confdefs.h"
9958 #include <${cf_cv_ncurses_header:-curses.h}>
9962 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
9967 rm -f conftest.$ac_objext conftest$ac_exeext
9968 if { (eval echo "$as_me:9968: \"$ac_link\"") >&5
9969 (eval $ac_link) 2>&5
9971 echo "$as_me:9971: \$? = $ac_status" >&5
9972 (exit $ac_status); } &&
9973 { ac_try='test -s conftest$ac_exeext'
9974 { (eval echo "$as_me:9974: \"$ac_try\"") >&5
9977 echo "$as_me:9977: \$? = $ac_status" >&5
9978 (exit $ac_status); }; }; then
9979 if test "$cross_compiling" = yes; then
9980 cf_have_ncuconfig=maybe
9982 cat >conftest.$ac_ext <<_ACEOF
9983 #line 9983 "configure"
9984 #include "confdefs.h"
9985 #include <${cf_cv_ncurses_header:-curses.h}>
9987 { char *xx = curses_version(); return (xx == 0); }
9989 rm -f conftest$ac_exeext
9990 if { (eval echo "$as_me:9990: \"$ac_link\"") >&5
9991 (eval $ac_link) 2>&5
9993 echo "$as_me:9993: \$? = $ac_status" >&5
9994 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
9995 { (eval echo "$as_me:9995: \"$ac_try\"") >&5
9998 echo "$as_me:9998: \$? = $ac_status" >&5
9999 (exit $ac_status); }; }; then
10000 cf_have_ncuconfig=yes
10002 echo "$as_me: program exited with status $ac_status" >&5
10003 echo "$as_me: failed program was:" >&5
10004 cat conftest.$ac_ext >&5
10005 cf_have_ncuconfig=no
10007 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
10010 echo "$as_me: failed program was:" >&5
10011 cat conftest.$ac_ext >&5
10012 cf_have_ncuconfig=no
10014 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10015 echo "$as_me:10015: result: $cf_have_ncuconfig" >&5
10016 echo "${ECHO_T}$cf_have_ncuconfig" >&6
10017 test "$cf_have_ncuconfig" = maybe && cf_have_ncuconfig=yes
10018 if test "$cf_have_ncuconfig" != "yes"
10020 CPPFLAGS="$cf_save_CPPFLAGS"
10021 LIBS="$cf_save_LIBS"
10022 NCURSES_CONFIG_PKG=none
10025 cat >>confdefs.h <<\EOF
10029 NCURSES_CONFIG_PKG=$cf_ncuconfig_root
10031 echo "$as_me:10031: checking for terminfo header" >&5
10032 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
10033 if test "${cf_cv_term_header+set}" = set; then
10034 echo $ECHO_N "(cached) $ECHO_C" >&6
10037 case ${cf_cv_ncurses_header} in
10038 (*/ncurses.h|*/ncursesw.h)
10039 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
10042 cf_term_header=term.h
10046 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
10048 cat >conftest.$ac_ext <<_ACEOF
10049 #line 10049 "configure"
10050 #include "confdefs.h"
10052 #include <${cf_cv_ncurses_header:-curses.h}>
10053 #include <$cf_test>
10058 int x = auto_left_margin; (void)x
10063 rm -f conftest.$ac_objext
10064 if { (eval echo "$as_me:10064: \"$ac_compile\"") >&5
10065 (eval $ac_compile) 2>&5
10067 echo "$as_me:10067: \$? = $ac_status" >&5
10068 (exit $ac_status); } &&
10069 { ac_try='test -s conftest.$ac_objext'
10070 { (eval echo "$as_me:10070: \"$ac_try\"") >&5
10071 (eval $ac_try) 2>&5
10073 echo "$as_me:10073: \$? = $ac_status" >&5
10074 (exit $ac_status); }; }; then
10076 cf_cv_term_header="$cf_test"
10078 echo "$as_me: failed program was:" >&5
10079 cat conftest.$ac_ext >&5
10081 cf_cv_term_header=unknown
10084 rm -f conftest.$ac_objext conftest.$ac_ext
10085 test "$cf_cv_term_header" != unknown && break
10089 echo "$as_me:10089: result: $cf_cv_term_header" >&5
10090 echo "${ECHO_T}$cf_cv_term_header" >&6
10092 # Set definitions to allow ifdef'ing to accommodate subdirectories
10094 case $cf_cv_term_header in
10097 cat >>confdefs.h <<\EOF
10098 #define HAVE_TERM_H 1
10104 case $cf_cv_term_header in
10107 cat >>confdefs.h <<\EOF
10108 #define HAVE_NCURSES_TERM_H 1
10114 cat >>confdefs.h <<\EOF
10115 #define HAVE_NCURSESW_TERM_H 1
10124 echo "$as_me:10124: result: no" >&5
10125 echo "${ECHO_T}no" >&6
10126 NCURSES_CONFIG_PKG=none
10129 NCURSES_CONFIG_PKG=none
10132 if test "x$cf_have_ncuconfig" = "xno"; then
10133 cf_ncurses_config="${cf_ncuconfig_root}${NCURSES_CONFIG_SUFFIX}-config"; echo "Looking for ${cf_ncurses_config}"
10135 if test -n "$ac_tool_prefix"; then
10136 for ac_prog in ${cf_ncurses_config} ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
10138 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
10139 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
10140 echo "$as_me:10140: checking for $ac_word" >&5
10141 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
10142 if test "${ac_cv_prog_NCURSES_CONFIG+set}" = set; then
10143 echo $ECHO_N "(cached) $ECHO_C" >&6
10145 if test -n "$NCURSES_CONFIG"; then
10146 ac_cv_prog_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test.
10148 ac_save_IFS=$IFS; IFS=$ac_path_separator
10150 for ac_dir in $ac_dummy; do
10152 test -z "$ac_dir" && ac_dir=.
10153 $as_executable_p "$ac_dir/$ac_word" || continue
10154 ac_cv_prog_NCURSES_CONFIG="$ac_tool_prefix$ac_prog"
10155 echo "$as_me:10155: found $ac_dir/$ac_word" >&5
10161 NCURSES_CONFIG=$ac_cv_prog_NCURSES_CONFIG
10162 if test -n "$NCURSES_CONFIG"; then
10163 echo "$as_me:10163: result: $NCURSES_CONFIG" >&5
10164 echo "${ECHO_T}$NCURSES_CONFIG" >&6
10166 echo "$as_me:10166: result: no" >&5
10167 echo "${ECHO_T}no" >&6
10170 test -n "$NCURSES_CONFIG" && break
10173 if test -z "$NCURSES_CONFIG"; then
10174 ac_ct_NCURSES_CONFIG=$NCURSES_CONFIG
10175 for ac_prog in ${cf_ncurses_config} ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
10177 # Extract the first word of "$ac_prog", so it can be a program name with args.
10178 set dummy $ac_prog; ac_word=$2
10179 echo "$as_me:10179: checking for $ac_word" >&5
10180 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
10181 if test "${ac_cv_prog_ac_ct_NCURSES_CONFIG+set}" = set; then
10182 echo $ECHO_N "(cached) $ECHO_C" >&6
10184 if test -n "$ac_ct_NCURSES_CONFIG"; then
10185 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_ct_NCURSES_CONFIG" # Let the user override the test.
10187 ac_save_IFS=$IFS; IFS=$ac_path_separator
10189 for ac_dir in $ac_dummy; do
10191 test -z "$ac_dir" && ac_dir=.
10192 $as_executable_p "$ac_dir/$ac_word" || continue
10193 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_prog"
10194 echo "$as_me:10194: found $ac_dir/$ac_word" >&5
10200 ac_ct_NCURSES_CONFIG=$ac_cv_prog_ac_ct_NCURSES_CONFIG
10201 if test -n "$ac_ct_NCURSES_CONFIG"; then
10202 echo "$as_me:10202: result: $ac_ct_NCURSES_CONFIG" >&5
10203 echo "${ECHO_T}$ac_ct_NCURSES_CONFIG" >&6
10205 echo "$as_me:10205: result: no" >&5
10206 echo "${ECHO_T}no" >&6
10209 test -n "$ac_ct_NCURSES_CONFIG" && break
10211 test -n "$ac_ct_NCURSES_CONFIG" || ac_ct_NCURSES_CONFIG="none"
10213 NCURSES_CONFIG=$ac_ct_NCURSES_CONFIG
10216 if test "$NCURSES_CONFIG" != none ; then
10221 cf_new_extra_cppflags=
10223 for cf_add_cflags in `$NCURSES_CONFIG --cflags`
10225 case $cf_fix_cppflags in
10227 case $cf_add_cflags in
10228 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
10229 case $cf_add_cflags in
10231 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10233 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10234 && test -z "${cf_tst_cflags}" \
10235 && cf_fix_cppflags=yes
10237 if test $cf_fix_cppflags = yes ; then
10239 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10240 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10243 elif test "${cf_tst_cflags}" = "\"'" ; then
10245 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10246 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10252 case "$CPPFLAGS" in
10256 case $cf_add_cflags in
10258 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10260 CPPFLAGS=`echo "$CPPFLAGS" | \
10261 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10262 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10267 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
10268 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
10275 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
10276 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
10283 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10284 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10286 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10288 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10289 && test -z "${cf_tst_cflags}" \
10290 && cf_fix_cppflags=no
10295 if test -n "$cf_new_cflags" ; then
10297 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
10298 CFLAGS="${CFLAGS}$cf_new_cflags"
10302 if test -n "$cf_new_cppflags" ; then
10304 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
10305 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
10309 if test -n "$cf_new_extra_cppflags" ; then
10311 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
10312 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
10316 cf_add_libs="$LIBS"
10319 for cf_add_1lib in `$NCURSES_CONFIG --libs`; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
10320 # filter duplicates
10321 for cf_add_1lib in $cf_add_0lib; do
10322 for cf_add_2lib in $cf_add_libs; do
10323 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
10328 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
10330 LIBS="$cf_add_libs"
10332 # even with config script, some packages use no-override for curses.h
10334 echo "$as_me:10334: checking if we have identified curses headers" >&5
10335 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
10336 if test "${cf_cv_ncurses_header+set}" = set; then
10337 echo $ECHO_N "(cached) $ECHO_C" >&6
10340 cf_cv_ncurses_header=none
10342 ncurses.h $cf_cv_screen/ncurses.h \
10343 curses.h $cf_cv_screen/curses.h
10345 cat >conftest.$ac_ext <<_ACEOF
10346 #line 10346 "configure"
10347 #include "confdefs.h"
10348 #include <${cf_header}>
10352 initscr(); tgoto("?", 0,0)
10357 rm -f conftest.$ac_objext
10358 if { (eval echo "$as_me:10358: \"$ac_compile\"") >&5
10359 (eval $ac_compile) 2>&5
10361 echo "$as_me:10361: \$? = $ac_status" >&5
10362 (exit $ac_status); } &&
10363 { ac_try='test -s conftest.$ac_objext'
10364 { (eval echo "$as_me:10364: \"$ac_try\"") >&5
10365 (eval $ac_try) 2>&5
10367 echo "$as_me:10367: \$? = $ac_status" >&5
10368 (exit $ac_status); }; }; then
10369 cf_cv_ncurses_header=$cf_header; break
10371 echo "$as_me: failed program was:" >&5
10372 cat conftest.$ac_ext >&5
10374 rm -f conftest.$ac_objext conftest.$ac_ext
10378 echo "$as_me:10378: result: $cf_cv_ncurses_header" >&5
10379 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
10381 if test "$cf_cv_ncurses_header" = none ; then
10382 { { echo "$as_me:10382: error: No curses header-files found" >&5
10383 echo "$as_me: error: No curses header-files found" >&2;}
10384 { (exit 1); exit 1; }; }
10387 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
10389 for ac_header in $cf_cv_ncurses_header
10391 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
10392 echo "$as_me:10392: checking for $ac_header" >&5
10393 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
10394 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10395 echo $ECHO_N "(cached) $ECHO_C" >&6
10397 cat >conftest.$ac_ext <<_ACEOF
10398 #line 10398 "configure"
10399 #include "confdefs.h"
10400 #include <$ac_header>
10402 if { (eval echo "$as_me:10402: \"$ac_cpp conftest.$ac_ext\"") >&5
10403 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10405 egrep -v '^ *\+' conftest.er1 >conftest.err
10407 cat conftest.err >&5
10408 echo "$as_me:10408: \$? = $ac_status" >&5
10409 (exit $ac_status); } >/dev/null; then
10410 if test -s conftest.err; then
10411 ac_cpp_err=$ac_c_preproc_warn_flag
10418 if test -z "$ac_cpp_err"; then
10419 eval "$as_ac_Header=yes"
10421 echo "$as_me: failed program was:" >&5
10422 cat conftest.$ac_ext >&5
10423 eval "$as_ac_Header=no"
10425 rm -f conftest.err conftest.$ac_ext
10427 echo "$as_me:10427: result: `eval echo '${'$as_ac_Header'}'`" >&5
10428 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
10429 if test `eval echo '${'$as_ac_Header'}'` = yes; then
10430 cat >>confdefs.h <<EOF
10431 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
10437 cat >>confdefs.h <<\EOF
10441 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
10443 cat >>confdefs.h <<EOF
10444 #define $cf_nculib_ROOT 1
10447 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
10451 cf_ncuhdr_root=$cf_cv_screen
10453 test -n "$cf_cv_curses_dir" && \
10454 test "$cf_cv_curses_dir" != "no" && { \
10456 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
10457 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
10459 while test $cf_add_incdir != /usr/include
10461 if test -d $cf_add_incdir
10464 if test -n "$CFLAGS$CPPFLAGS" ; then
10465 # a loop is needed to ensure we can add subdirs of existing dirs
10466 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
10467 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
10468 cf_have_incdir=yes; break
10473 if test "$cf_have_incdir" = no ; then
10474 if test "$cf_add_incdir" = /usr/local/include ; then
10475 if test "$GCC" = yes
10477 cf_save_CPPFLAGS=$CPPFLAGS
10479 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
10480 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
10482 cat >conftest.$ac_ext <<_ACEOF
10483 #line 10483 "configure"
10484 #include "confdefs.h"
10494 rm -f conftest.$ac_objext
10495 if { (eval echo "$as_me:10495: \"$ac_compile\"") >&5
10496 (eval $ac_compile) 2>&5
10498 echo "$as_me:10498: \$? = $ac_status" >&5
10499 (exit $ac_status); } &&
10500 { ac_try='test -s conftest.$ac_objext'
10501 { (eval echo "$as_me:10501: \"$ac_try\"") >&5
10502 (eval $ac_try) 2>&5
10504 echo "$as_me:10504: \$? = $ac_status" >&5
10505 (exit $ac_status); }; }; then
10508 echo "$as_me: failed program was:" >&5
10509 cat conftest.$ac_ext >&5
10512 rm -f conftest.$ac_objext conftest.$ac_ext
10513 CPPFLAGS=$cf_save_CPPFLAGS
10518 if test "$cf_have_incdir" = no ; then
10519 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
10521 echo "${as_me:-configure}:10521: testing adding $cf_add_incdir to include-path ..." 1>&5
10523 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
10525 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
10526 test "$cf_top_incdir" = "$cf_add_incdir" && break
10527 cf_add_incdir="$cf_top_incdir"
10540 echo "$as_me:10540: checking for $cf_ncuhdr_root header in include-path" >&5
10541 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
10542 if test "${cf_cv_ncurses_h+set}" = set; then
10543 echo $ECHO_N "(cached) $ECHO_C" >&6
10546 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
10547 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
10548 for cf_header in $cf_header_list
10551 cat >conftest.$ac_ext <<_ACEOF
10552 #line 10552 "configure"
10553 #include "confdefs.h"
10555 #include <$cf_header>
10560 #ifdef NCURSES_VERSION
10562 printf("%s\n", NCURSES_VERSION);
10575 rm -f conftest.$ac_objext
10576 if { (eval echo "$as_me:10576: \"$ac_compile\"") >&5
10577 (eval $ac_compile) 2>&5
10579 echo "$as_me:10579: \$? = $ac_status" >&5
10580 (exit $ac_status); } &&
10581 { ac_try='test -s conftest.$ac_objext'
10582 { (eval echo "$as_me:10582: \"$ac_try\"") >&5
10583 (eval $ac_try) 2>&5
10585 echo "$as_me:10585: \$? = $ac_status" >&5
10586 (exit $ac_status); }; }; then
10587 cf_cv_ncurses_h=$cf_header
10590 echo "$as_me: failed program was:" >&5
10591 cat conftest.$ac_ext >&5
10594 rm -f conftest.$ac_objext conftest.$ac_ext
10596 test "$cf_cv_ncurses_h" != no && break
10600 echo "$as_me:10600: result: $cf_cv_ncurses_h" >&5
10601 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
10603 if test "$cf_cv_ncurses_h" != no ; then
10604 cf_cv_ncurses_header=$cf_cv_ncurses_h
10607 echo "$as_me:10607: checking for $cf_ncuhdr_root include-path" >&5
10608 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
10609 if test "${cf_cv_ncurses_h2+set}" = set; then
10610 echo $ECHO_N "(cached) $ECHO_C" >&6
10613 test -n "$verbose" && echo
10617 # collect the current set of include-directories from compiler flags
10618 cf_header_path_list=""
10619 if test -n "${CFLAGS}${CPPFLAGS}" ; then
10620 for cf_header_path in $CPPFLAGS $CFLAGS
10622 case $cf_header_path in
10624 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
10626 test "x$cf_header_path" != "xNONE" && \
10627 test -d "$cf_header_path" && \
10629 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
10630 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
10631 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
10632 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
10633 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
10634 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"
10637 cf_header_path_list="$cf_header_path_list $cf_search"
10643 # add the variations for the package we are looking for
10647 test "x$prefix" != "xNONE" && \
10648 test -d "$prefix" && \
10650 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
10651 test -d $prefix/include && cf_search="$cf_search $prefix/include"
10652 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
10653 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
10654 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
10655 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
10658 for cf_subdir_prefix in \
10667 test "x$cf_subdir_prefix" != "x$prefix" && \
10668 test -d "$cf_subdir_prefix" && \
10669 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
10670 test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
10671 test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include"
10672 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root"
10673 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root/include"
10674 test -d $cf_subdir_prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include"
10675 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"
10680 test "$includedir" != NONE && \
10681 test "$includedir" != "/usr/include" && \
10682 test -d "$includedir" && {
10683 test -d $includedir && cf_search="$cf_search $includedir"
10684 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
10687 test "$oldincludedir" != NONE && \
10688 test "$oldincludedir" != "/usr/include" && \
10689 test -d "$oldincludedir" && {
10690 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
10691 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
10694 cf_search="$cf_search $cf_header_path_list"
10696 test -n "$verbose" && echo search path $cf_search
10697 cf_save2_CPPFLAGS="$CPPFLAGS"
10698 for cf_incdir in $cf_search
10701 if test -n "$cf_incdir" ; then
10702 for cf_add_incdir in $cf_incdir
10704 while test $cf_add_incdir != /usr/include
10706 if test -d $cf_add_incdir
10709 if test -n "$CFLAGS$CPPFLAGS" ; then
10710 # a loop is needed to ensure we can add subdirs of existing dirs
10711 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
10712 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
10713 cf_have_incdir=yes; break
10718 if test "$cf_have_incdir" = no ; then
10719 if test "$cf_add_incdir" = /usr/local/include ; then
10720 if test "$GCC" = yes
10722 cf_save_CPPFLAGS=$CPPFLAGS
10724 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
10725 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
10727 cat >conftest.$ac_ext <<_ACEOF
10728 #line 10728 "configure"
10729 #include "confdefs.h"
10739 rm -f conftest.$ac_objext
10740 if { (eval echo "$as_me:10740: \"$ac_compile\"") >&5
10741 (eval $ac_compile) 2>&5
10743 echo "$as_me:10743: \$? = $ac_status" >&5
10744 (exit $ac_status); } &&
10745 { ac_try='test -s conftest.$ac_objext'
10746 { (eval echo "$as_me:10746: \"$ac_try\"") >&5
10747 (eval $ac_try) 2>&5
10749 echo "$as_me:10749: \$? = $ac_status" >&5
10750 (exit $ac_status); }; }; then
10753 echo "$as_me: failed program was:" >&5
10754 cat conftest.$ac_ext >&5
10757 rm -f conftest.$ac_objext conftest.$ac_ext
10758 CPPFLAGS=$cf_save_CPPFLAGS
10763 if test "$cf_have_incdir" = no ; then
10764 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
10766 echo "${as_me:-configure}:10766: testing adding $cf_add_incdir to include-path ..." 1>&5
10768 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
10770 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
10771 test "$cf_top_incdir" = "$cf_add_incdir" && break
10772 cf_add_incdir="$cf_top_incdir"
10788 cat >conftest.$ac_ext <<_ACEOF
10789 #line 10789 "configure"
10790 #include "confdefs.h"
10792 #include <$cf_header>
10797 #ifdef NCURSES_VERSION
10799 printf("%s\n", NCURSES_VERSION);
10812 rm -f conftest.$ac_objext
10813 if { (eval echo "$as_me:10813: \"$ac_compile\"") >&5
10814 (eval $ac_compile) 2>&5
10816 echo "$as_me:10816: \$? = $ac_status" >&5
10817 (exit $ac_status); } &&
10818 { ac_try='test -s conftest.$ac_objext'
10819 { (eval echo "$as_me:10819: \"$ac_try\"") >&5
10820 (eval $ac_try) 2>&5
10822 echo "$as_me:10822: \$? = $ac_status" >&5
10823 (exit $ac_status); }; }; then
10824 cf_cv_ncurses_h2=$cf_header
10827 echo "$as_me: failed program was:" >&5
10828 cat conftest.$ac_ext >&5
10829 cf_cv_ncurses_h2=no
10831 rm -f conftest.$ac_objext conftest.$ac_ext
10833 if test "$cf_cv_ncurses_h2" != no ; then
10834 cf_cv_ncurses_h2=$cf_incdir/$cf_header
10835 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
10838 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
10840 CPPFLAGS="$cf_save2_CPPFLAGS"
10841 test "$cf_cv_ncurses_h2" != no && break
10843 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:10843: error: not found" >&5
10844 echo "$as_me: error: not found" >&2;}
10845 { (exit 1); exit 1; }; }
10848 echo "$as_me:10848: result: $cf_cv_ncurses_h2" >&5
10849 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
10851 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
10852 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
10853 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
10854 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
10857 if test -n "$cf_1st_incdir" ; then
10858 for cf_add_incdir in $cf_1st_incdir
10860 while test $cf_add_incdir != /usr/include
10862 if test -d $cf_add_incdir
10865 if test -n "$CFLAGS$CPPFLAGS" ; then
10866 # a loop is needed to ensure we can add subdirs of existing dirs
10867 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
10868 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
10869 cf_have_incdir=yes; break
10874 if test "$cf_have_incdir" = no ; then
10875 if test "$cf_add_incdir" = /usr/local/include ; then
10876 if test "$GCC" = yes
10878 cf_save_CPPFLAGS=$CPPFLAGS
10880 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
10881 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
10883 cat >conftest.$ac_ext <<_ACEOF
10884 #line 10884 "configure"
10885 #include "confdefs.h"
10895 rm -f conftest.$ac_objext
10896 if { (eval echo "$as_me:10896: \"$ac_compile\"") >&5
10897 (eval $ac_compile) 2>&5
10899 echo "$as_me:10899: \$? = $ac_status" >&5
10900 (exit $ac_status); } &&
10901 { ac_try='test -s conftest.$ac_objext'
10902 { (eval echo "$as_me:10902: \"$ac_try\"") >&5
10903 (eval $ac_try) 2>&5
10905 echo "$as_me:10905: \$? = $ac_status" >&5
10906 (exit $ac_status); }; }; then
10909 echo "$as_me: failed program was:" >&5
10910 cat conftest.$ac_ext >&5
10913 rm -f conftest.$ac_objext conftest.$ac_ext
10914 CPPFLAGS=$cf_save_CPPFLAGS
10919 if test "$cf_have_incdir" = no ; then
10920 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
10922 echo "${as_me:-configure}:10922: testing adding $cf_add_incdir to include-path ..." 1>&5
10924 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
10926 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
10927 test "$cf_top_incdir" = "$cf_add_incdir" && break
10928 cf_add_incdir="$cf_top_incdir"
10941 # Set definitions to allow ifdef'ing for ncurses.h
10943 case $cf_cv_ncurses_header in
10946 cat >>confdefs.h <<\EOF
10947 #define HAVE_NCURSES_H 1
10953 case $cf_cv_ncurses_header in
10954 (ncurses/curses.h|ncurses/ncurses.h)
10956 cat >>confdefs.h <<\EOF
10957 #define HAVE_NCURSES_NCURSES_H 1
10961 (ncursesw/curses.h|ncursesw/ncurses.h)
10963 cat >>confdefs.h <<\EOF
10964 #define HAVE_NCURSESW_NCURSES_H 1
10970 echo "$as_me:10970: checking for terminfo header" >&5
10971 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
10972 if test "${cf_cv_term_header+set}" = set; then
10973 echo $ECHO_N "(cached) $ECHO_C" >&6
10976 case ${cf_cv_ncurses_header} in
10977 (*/ncurses.h|*/ncursesw.h)
10978 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
10981 cf_term_header=term.h
10985 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
10987 cat >conftest.$ac_ext <<_ACEOF
10988 #line 10988 "configure"
10989 #include "confdefs.h"
10991 #include <${cf_cv_ncurses_header:-curses.h}>
10992 #include <$cf_test>
10997 int x = auto_left_margin; (void)x
11002 rm -f conftest.$ac_objext
11003 if { (eval echo "$as_me:11003: \"$ac_compile\"") >&5
11004 (eval $ac_compile) 2>&5
11006 echo "$as_me:11006: \$? = $ac_status" >&5
11007 (exit $ac_status); } &&
11008 { ac_try='test -s conftest.$ac_objext'
11009 { (eval echo "$as_me:11009: \"$ac_try\"") >&5
11010 (eval $ac_try) 2>&5
11012 echo "$as_me:11012: \$? = $ac_status" >&5
11013 (exit $ac_status); }; }; then
11015 cf_cv_term_header="$cf_test"
11017 echo "$as_me: failed program was:" >&5
11018 cat conftest.$ac_ext >&5
11020 cf_cv_term_header=unknown
11023 rm -f conftest.$ac_objext conftest.$ac_ext
11024 test "$cf_cv_term_header" != unknown && break
11028 echo "$as_me:11028: result: $cf_cv_term_header" >&5
11029 echo "${ECHO_T}$cf_cv_term_header" >&6
11031 # Set definitions to allow ifdef'ing to accommodate subdirectories
11033 case $cf_cv_term_header in
11036 cat >>confdefs.h <<\EOF
11037 #define HAVE_TERM_H 1
11043 case $cf_cv_term_header in
11046 cat >>confdefs.h <<\EOF
11047 #define HAVE_NCURSES_TERM_H 1
11053 cat >>confdefs.h <<\EOF
11054 #define HAVE_NCURSESW_TERM_H 1
11060 # some applications need this, but should check for NCURSES_VERSION
11062 cat >>confdefs.h <<\EOF
11066 echo "$as_me:11066: checking for ncurses version" >&5
11067 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
11068 if test "${cf_cv_ncurses_version+set}" = set; then
11069 echo $ECHO_N "(cached) $ECHO_C" >&6
11072 cf_cv_ncurses_version=no
11075 if test "$cross_compiling" = yes; then
11077 # This will not work if the preprocessor splits the line after the
11078 # Autoconf token. The 'unproto' program does that.
11079 cat > conftest.$ac_ext <<EOF
11080 #include <${cf_cv_ncurses_header:-curses.h}>
11082 #ifdef NCURSES_VERSION
11083 Autoconf NCURSES_VERSION
11091 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
11092 { (eval echo "$as_me:11092: \"$cf_try\"") >&5
11093 (eval $cf_try) 2>&5
11095 echo "$as_me:11095: \$? = $ac_status" >&5
11096 (exit $ac_status); }
11097 if test -f conftest.out ; then
11098 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
11099 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
11104 cat >conftest.$ac_ext <<_ACEOF
11105 #line 11105 "configure"
11106 #include "confdefs.h"
11108 #include <${cf_cv_ncurses_header:-curses.h}>
11112 FILE *fp = fopen("$cf_tempfile", "w");
11113 #ifdef NCURSES_VERSION
11114 # ifdef NCURSES_VERSION_PATCH
11115 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
11117 fprintf(fp, "%s\n", NCURSES_VERSION);
11120 # ifdef __NCURSES_H
11121 fprintf(fp, "old\n");
11126 ${cf_cv_main_return:-return}(0);
11129 rm -f conftest$ac_exeext
11130 if { (eval echo "$as_me:11130: \"$ac_link\"") >&5
11131 (eval $ac_link) 2>&5
11133 echo "$as_me:11133: \$? = $ac_status" >&5
11134 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
11135 { (eval echo "$as_me:11135: \"$ac_try\"") >&5
11136 (eval $ac_try) 2>&5
11138 echo "$as_me:11138: \$? = $ac_status" >&5
11139 (exit $ac_status); }; }; then
11141 cf_cv_ncurses_version=`cat $cf_tempfile`
11143 echo "$as_me: program exited with status $ac_status" >&5
11144 echo "$as_me: failed program was:" >&5
11145 cat conftest.$ac_ext >&5
11147 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
11152 echo "$as_me:11152: result: $cf_cv_ncurses_version" >&5
11153 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
11154 test "$cf_cv_ncurses_version" = no ||
11155 cat >>confdefs.h <<\EOF
11159 cf_nculib_root=$cf_cv_screen
11160 # This works, except for the special case where we find gpm, but
11161 # ncurses is in a nonstandard location via $LIBS, and we really want
11164 cf_ncurses_SAVE="$LIBS"
11165 echo "$as_me:11165: checking for Gpm_Open in -lgpm" >&5
11166 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
11167 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
11168 echo $ECHO_N "(cached) $ECHO_C" >&6
11170 ac_check_lib_save_LIBS=$LIBS
11172 cat >conftest.$ac_ext <<_ACEOF
11173 #line 11173 "configure"
11174 #include "confdefs.h"
11176 /* Override any gcc2 internal prototype to avoid an error. */
11180 /* We use char because int might match the return type of a gcc2
11181 builtin and then its argument prototype would still apply. */
11191 rm -f conftest.$ac_objext conftest$ac_exeext
11192 if { (eval echo "$as_me:11192: \"$ac_link\"") >&5
11193 (eval $ac_link) 2>&5
11195 echo "$as_me:11195: \$? = $ac_status" >&5
11196 (exit $ac_status); } &&
11197 { ac_try='test -s conftest$ac_exeext'
11198 { (eval echo "$as_me:11198: \"$ac_try\"") >&5
11199 (eval $ac_try) 2>&5
11201 echo "$as_me:11201: \$? = $ac_status" >&5
11202 (exit $ac_status); }; }; then
11203 ac_cv_lib_gpm_Gpm_Open=yes
11205 echo "$as_me: failed program was:" >&5
11206 cat conftest.$ac_ext >&5
11207 ac_cv_lib_gpm_Gpm_Open=no
11209 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11210 LIBS=$ac_check_lib_save_LIBS
11212 echo "$as_me:11212: result: $ac_cv_lib_gpm_Gpm_Open" >&5
11213 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
11214 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
11215 echo "$as_me:11215: checking for initscr in -lgpm" >&5
11216 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
11217 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
11218 echo $ECHO_N "(cached) $ECHO_C" >&6
11220 ac_check_lib_save_LIBS=$LIBS
11222 cat >conftest.$ac_ext <<_ACEOF
11223 #line 11223 "configure"
11224 #include "confdefs.h"
11226 /* Override any gcc2 internal prototype to avoid an error. */
11230 /* We use char because int might match the return type of a gcc2
11231 builtin and then its argument prototype would still apply. */
11241 rm -f conftest.$ac_objext conftest$ac_exeext
11242 if { (eval echo "$as_me:11242: \"$ac_link\"") >&5
11243 (eval $ac_link) 2>&5
11245 echo "$as_me:11245: \$? = $ac_status" >&5
11246 (exit $ac_status); } &&
11247 { ac_try='test -s conftest$ac_exeext'
11248 { (eval echo "$as_me:11248: \"$ac_try\"") >&5
11249 (eval $ac_try) 2>&5
11251 echo "$as_me:11251: \$? = $ac_status" >&5
11252 (exit $ac_status); }; }; then
11253 ac_cv_lib_gpm_initscr=yes
11255 echo "$as_me: failed program was:" >&5
11256 cat conftest.$ac_ext >&5
11257 ac_cv_lib_gpm_initscr=no
11259 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11260 LIBS=$ac_check_lib_save_LIBS
11262 echo "$as_me:11262: result: $ac_cv_lib_gpm_initscr" >&5
11263 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
11264 if test $ac_cv_lib_gpm_initscr = yes; then
11265 LIBS="$cf_ncurses_SAVE"
11267 cf_ncurses_LIBS="-lgpm"
11274 # This is only necessary if you are linking against an obsolete
11275 # version of ncurses (but it should do no harm, since it's static).
11276 if test "$cf_nculib_root" = ncurses ; then
11277 echo "$as_me:11277: checking for tgoto in -lmytinfo" >&5
11278 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
11279 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
11280 echo $ECHO_N "(cached) $ECHO_C" >&6
11282 ac_check_lib_save_LIBS=$LIBS
11283 LIBS="-lmytinfo $LIBS"
11284 cat >conftest.$ac_ext <<_ACEOF
11285 #line 11285 "configure"
11286 #include "confdefs.h"
11288 /* Override any gcc2 internal prototype to avoid an error. */
11292 /* We use char because int might match the return type of a gcc2
11293 builtin and then its argument prototype would still apply. */
11303 rm -f conftest.$ac_objext conftest$ac_exeext
11304 if { (eval echo "$as_me:11304: \"$ac_link\"") >&5
11305 (eval $ac_link) 2>&5
11307 echo "$as_me:11307: \$? = $ac_status" >&5
11308 (exit $ac_status); } &&
11309 { ac_try='test -s conftest$ac_exeext'
11310 { (eval echo "$as_me:11310: \"$ac_try\"") >&5
11311 (eval $ac_try) 2>&5
11313 echo "$as_me:11313: \$? = $ac_status" >&5
11314 (exit $ac_status); }; }; then
11315 ac_cv_lib_mytinfo_tgoto=yes
11317 echo "$as_me: failed program was:" >&5
11318 cat conftest.$ac_ext >&5
11319 ac_cv_lib_mytinfo_tgoto=no
11321 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11322 LIBS=$ac_check_lib_save_LIBS
11324 echo "$as_me:11324: result: $ac_cv_lib_mytinfo_tgoto" >&5
11325 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
11326 if test $ac_cv_lib_mytinfo_tgoto = yes; then
11327 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
11334 cf_add_libs="$LIBS"
11337 for cf_add_1lib in $cf_ncurses_LIBS; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
11338 # filter duplicates
11339 for cf_add_1lib in $cf_add_0lib; do
11340 for cf_add_2lib in $cf_add_libs; do
11341 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
11346 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
11348 LIBS="$cf_add_libs"
11350 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
11353 cf_add_libs="$LIBS"
11356 for cf_add_1lib in -l$cf_nculib_root; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
11357 # filter duplicates
11358 for cf_add_1lib in $cf_add_0lib; do
11359 for cf_add_2lib in $cf_add_libs; do
11360 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
11365 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
11367 LIBS="$cf_add_libs"
11371 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
11373 echo "$as_me:11373: checking for initscr" >&5
11374 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
11375 if test "${ac_cv_func_initscr+set}" = set; then
11376 echo $ECHO_N "(cached) $ECHO_C" >&6
11378 cat >conftest.$ac_ext <<_ACEOF
11379 #line 11379 "configure"
11380 #include "confdefs.h"
11381 #define initscr autoconf_temporary
11382 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
11389 /* We use char because int might match the return type of a gcc2
11390 builtin and then its argument prototype would still apply. */
11391 char initscr (void);
11397 /* The GNU C library defines stubs for functions which it implements
11398 to always fail with ENOSYS. Some functions are actually named
11399 something starting with __ and the normal name is an alias. */
11400 #if defined (__stub_initscr) || defined (__stub___initscr)
11401 #error found stub for initscr
11409 rm -f conftest.$ac_objext conftest$ac_exeext
11410 if { (eval echo "$as_me:11410: \"$ac_link\"") >&5
11411 (eval $ac_link) 2>&5
11413 echo "$as_me:11413: \$? = $ac_status" >&5
11414 (exit $ac_status); } &&
11415 { ac_try='test -s conftest$ac_exeext'
11416 { (eval echo "$as_me:11416: \"$ac_try\"") >&5
11417 (eval $ac_try) 2>&5
11419 echo "$as_me:11419: \$? = $ac_status" >&5
11420 (exit $ac_status); }; }; then
11421 ac_cv_func_initscr=yes
11423 echo "$as_me: failed program was:" >&5
11424 cat conftest.$ac_ext >&5
11425 ac_cv_func_initscr=no
11427 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11429 echo "$as_me:11429: result: $ac_cv_func_initscr" >&5
11430 echo "${ECHO_T}$ac_cv_func_initscr" >&6
11431 if test $ac_cv_func_initscr = yes; then
11432 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
11435 cf_save_LIBS="$LIBS"
11436 echo "$as_me:11436: checking for initscr in -l$cf_nculib_root" >&5
11437 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
11438 LIBS="-l$cf_nculib_root $LIBS"
11439 cat >conftest.$ac_ext <<_ACEOF
11440 #line 11440 "configure"
11441 #include "confdefs.h"
11442 #include <${cf_cv_ncurses_header:-curses.h}>
11451 rm -f conftest.$ac_objext conftest$ac_exeext
11452 if { (eval echo "$as_me:11452: \"$ac_link\"") >&5
11453 (eval $ac_link) 2>&5
11455 echo "$as_me:11455: \$? = $ac_status" >&5
11456 (exit $ac_status); } &&
11457 { ac_try='test -s conftest$ac_exeext'
11458 { (eval echo "$as_me:11458: \"$ac_try\"") >&5
11459 (eval $ac_try) 2>&5
11461 echo "$as_me:11461: \$? = $ac_status" >&5
11462 (exit $ac_status); }; }; then
11463 echo "$as_me:11463: result: yes" >&5
11464 echo "${ECHO_T}yes" >&6
11465 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
11468 echo "$as_me: failed program was:" >&5
11469 cat conftest.$ac_ext >&5
11470 echo "$as_me:11470: result: no" >&5
11471 echo "${ECHO_T}no" >&6
11474 cf_library_path_list=""
11475 if test -n "${LDFLAGS}${LIBS}" ; then
11476 for cf_library_path in $LDFLAGS $LIBS
11478 case $cf_library_path in
11480 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
11482 test "x$cf_library_path" != "xNONE" && \
11483 test -d "$cf_library_path" && \
11485 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
11486 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
11487 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
11488 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
11489 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
11490 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"
11493 cf_library_path_list="$cf_library_path_list $cf_search"
11501 test "x$prefix" != "xNONE" && \
11502 test -d "$prefix" && \
11504 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
11505 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
11506 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
11507 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
11508 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
11509 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
11512 for cf_subdir_prefix in \
11521 test "x$cf_subdir_prefix" != "x$prefix" && \
11522 test -d "$cf_subdir_prefix" && \
11523 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
11524 test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
11525 test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib"
11526 test -d $cf_subdir_prefix/lib/$cf_nculib_root && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root"
11527 test -d $cf_subdir_prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root/lib"
11528 test -d $cf_subdir_prefix/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib"
11529 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"
11534 cf_search="$cf_library_path_list $cf_search"
11536 for cf_libdir in $cf_search
11538 echo "$as_me:11538: checking for -l$cf_nculib_root in $cf_libdir" >&5
11539 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
11540 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
11541 cat >conftest.$ac_ext <<_ACEOF
11542 #line 11542 "configure"
11543 #include "confdefs.h"
11544 #include <${cf_cv_ncurses_header:-curses.h}>
11553 rm -f conftest.$ac_objext conftest$ac_exeext
11554 if { (eval echo "$as_me:11554: \"$ac_link\"") >&5
11555 (eval $ac_link) 2>&5
11557 echo "$as_me:11557: \$? = $ac_status" >&5
11558 (exit $ac_status); } &&
11559 { ac_try='test -s conftest$ac_exeext'
11560 { (eval echo "$as_me:11560: \"$ac_try\"") >&5
11561 (eval $ac_try) 2>&5
11563 echo "$as_me:11563: \$? = $ac_status" >&5
11564 (exit $ac_status); }; }; then
11565 echo "$as_me:11565: result: yes" >&5
11566 echo "${ECHO_T}yes" >&6
11567 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
11570 echo "$as_me: failed program was:" >&5
11571 cat conftest.$ac_ext >&5
11572 echo "$as_me:11572: result: no" >&5
11573 echo "${ECHO_T}no" >&6
11574 LIBS="$cf_save_LIBS"
11576 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11580 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11584 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
11586 if test $cf_found_library = no ; then
11587 { { echo "$as_me:11587: error: Cannot link $cf_nculib_root library" >&5
11588 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
11589 { (exit 1); exit 1; }; }
11594 if test -n "$cf_ncurses_LIBS" ; then
11595 echo "$as_me:11595: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
11596 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
11597 cf_ncurses_SAVE="$LIBS"
11598 for p in $cf_ncurses_LIBS ; do
11599 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
11600 if test "$q" != "$LIBS" ; then
11604 cat >conftest.$ac_ext <<_ACEOF
11605 #line 11605 "configure"
11606 #include "confdefs.h"
11607 #include <${cf_cv_ncurses_header:-curses.h}>
11611 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
11616 rm -f conftest.$ac_objext conftest$ac_exeext
11617 if { (eval echo "$as_me:11617: \"$ac_link\"") >&5
11618 (eval $ac_link) 2>&5
11620 echo "$as_me:11620: \$? = $ac_status" >&5
11621 (exit $ac_status); } &&
11622 { ac_try='test -s conftest$ac_exeext'
11623 { (eval echo "$as_me:11623: \"$ac_try\"") >&5
11624 (eval $ac_try) 2>&5
11626 echo "$as_me:11626: \$? = $ac_status" >&5
11627 (exit $ac_status); }; }; then
11628 echo "$as_me:11628: result: yes" >&5
11629 echo "${ECHO_T}yes" >&6
11631 echo "$as_me: failed program was:" >&5
11632 cat conftest.$ac_ext >&5
11633 echo "$as_me:11633: result: no" >&5
11634 echo "${ECHO_T}no" >&6
11635 LIBS="$cf_ncurses_SAVE"
11637 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11640 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
11642 cat >>confdefs.h <<EOF
11643 #define $cf_nculib_ROOT 1
11648 NCURSES_CONFIG=none
11653 echo "$as_me:11653: checking for X" >&5
11654 echo $ECHO_N "checking for X... $ECHO_C" >&6
11656 # Check whether --with-x or --without-x was given.
11657 if test "${with_x+set}" = set; then
11661 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
11662 if test "x$with_x" = xno; then
11663 # The user explicitly disabled X.
11666 if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
11667 # Both variables are already set.
11670 if test "${ac_cv_have_x+set}" = set; then
11671 echo $ECHO_N "(cached) $ECHO_C" >&6
11673 # One or both of the vars are not set, and there is no cached value.
11674 ac_x_includes=no ac_x_libraries=no
11675 rm -fr conftest.dir
11676 if mkdir conftest.dir; then
11678 # Make sure to not put "make" in the Imakefile rules, since we grep it out.
11679 cat >Imakefile <<'EOF'
11681 @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
11683 if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
11684 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
11685 eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
11686 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
11687 for ac_extension in a so sl dylib dll; do
11688 if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
11689 test -f $ac_im_libdir/libX11.$ac_extension; then
11690 ac_im_usrlibdir=$ac_im_libdir; break
11693 # Screen out bogus values from the imake configuration. They are
11694 # bogus both because they are the default anyway, and because
11695 # using them would break gcc on systems where it needs fixed includes.
11696 case $ac_im_incroot in
11698 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
11700 case $ac_im_usrlibdir in
11701 /usr/lib | /lib) ;;
11702 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
11706 rm -fr conftest.dir
11709 # Standard set of common directories for X headers.
11710 # Check X11 before X11Rn because it is often a symlink to the current release.
11727 /usr/local/X11/include
11728 /usr/local/X11R7/include
11729 /usr/local/X11R6/include
11730 /usr/local/X11R5/include
11731 /usr/local/X11R4/include
11733 /usr/local/include/X11
11734 /usr/local/include/X11R7
11735 /usr/local/include/X11R6
11736 /usr/local/include/X11R5
11737 /usr/local/include/X11R4
11741 /usr/XFree86/include/X11
11745 /usr/unsupported/include
11746 /usr/athena/include
11747 /usr/local/x11r5/include
11748 /usr/lpp/Xamples/include
11750 /usr/openwin/include
11751 /usr/openwin/share/include'
11753 if test "$ac_x_includes" = no; then
11754 # Guess where to find include files, by looking for Intrinsic.h.
11755 # First, try using that file with no special directory specified.
11756 cat >conftest.$ac_ext <<_ACEOF
11757 #line 11757 "configure"
11758 #include "confdefs.h"
11759 #include <X11/Intrinsic.h>
11761 if { (eval echo "$as_me:11761: \"$ac_cpp conftest.$ac_ext\"") >&5
11762 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11764 egrep -v '^ *\+' conftest.er1 >conftest.err
11766 cat conftest.err >&5
11767 echo "$as_me:11767: \$? = $ac_status" >&5
11768 (exit $ac_status); } >/dev/null; then
11769 if test -s conftest.err; then
11770 ac_cpp_err=$ac_c_preproc_warn_flag
11777 if test -z "$ac_cpp_err"; then
11778 # We can compile using X headers with no special include directory.
11781 echo "$as_me: failed program was:" >&5
11782 cat conftest.$ac_ext >&5
11783 for ac_dir in $ac_x_header_dirs; do
11784 if test -r "$ac_dir/X11/Intrinsic.h"; then
11785 ac_x_includes=$ac_dir
11790 rm -f conftest.err conftest.$ac_ext
11791 fi # $ac_x_includes = no
11793 if test "$ac_x_libraries" = no; then
11794 # Check for the libraries.
11795 # See if we find them without any special options.
11796 # Don't add to $LIBS permanently.
11799 cat >conftest.$ac_ext <<_ACEOF
11800 #line 11800 "configure"
11801 #include "confdefs.h"
11802 #include <X11/Intrinsic.h>
11811 rm -f conftest.$ac_objext conftest$ac_exeext
11812 if { (eval echo "$as_me:11812: \"$ac_link\"") >&5
11813 (eval $ac_link) 2>&5
11815 echo "$as_me:11815: \$? = $ac_status" >&5
11816 (exit $ac_status); } &&
11817 { ac_try='test -s conftest$ac_exeext'
11818 { (eval echo "$as_me:11818: \"$ac_try\"") >&5
11819 (eval $ac_try) 2>&5
11821 echo "$as_me:11821: \$? = $ac_status" >&5
11822 (exit $ac_status); }; }; then
11824 # We can link X programs with no special library path.
11827 echo "$as_me: failed program was:" >&5
11828 cat conftest.$ac_ext >&5
11830 for ac_dir in `echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
11832 # Don't even attempt the hair of trying to link an X program!
11833 for ac_extension in a so sl dylib dll; do
11834 if test -r $ac_dir/libXt.$ac_extension; then
11835 ac_x_libraries=$ac_dir
11841 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11842 fi # $ac_x_libraries = no
11844 if test "$ac_x_includes" = no || test "$ac_x_libraries" = no; then
11845 # Didn't find X anywhere. Cache the known absence of X.
11846 ac_cv_have_x="have_x=no"
11848 # Record where we found X for the cache.
11849 ac_cv_have_x="have_x=yes \
11850 ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
11855 eval "$ac_cv_have_x"
11858 if test "$have_x" != yes; then
11859 echo "$as_me:11859: result: $have_x" >&5
11860 echo "${ECHO_T}$have_x" >&6
11863 # If each of the values was on the command line, it overrides each guess.
11864 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
11865 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
11866 # Update the cache value to reflect the command line values.
11867 ac_cv_have_x="have_x=yes \
11868 ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
11869 echo "$as_me:11869: result: libraries $x_libraries, headers $x_includes" >&5
11870 echo "${ECHO_T}libraries $x_libraries, headers $x_includes" >&6
11873 if test "$no_x" = yes; then
11874 # Not all programs may use this symbol, but it does not hurt to define it.
11876 cat >>confdefs.h <<\EOF
11877 #define X_DISPLAY_MISSING 1
11880 X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS=
11882 if test -n "$x_includes"; then
11883 X_CFLAGS="$X_CFLAGS -I$x_includes"
11886 # It would also be nice to do this for all -L options, not just this one.
11887 if test -n "$x_libraries"; then
11888 X_LIBS="$X_LIBS -L$x_libraries"
11889 # For Solaris; some versions of Sun CC require a space after -R and
11890 # others require no space. Words are not sufficient . . . .
11891 case `(uname -sr) 2>/dev/null` in
11893 echo "$as_me:11893: checking whether -R must be followed by a space" >&5
11894 echo $ECHO_N "checking whether -R must be followed by a space... $ECHO_C" >&6
11895 ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries"
11896 cat >conftest.$ac_ext <<_ACEOF
11897 #line 11897 "configure"
11898 #include "confdefs.h"
11908 rm -f conftest.$ac_objext conftest$ac_exeext
11909 if { (eval echo "$as_me:11909: \"$ac_link\"") >&5
11910 (eval $ac_link) 2>&5
11912 echo "$as_me:11912: \$? = $ac_status" >&5
11913 (exit $ac_status); } &&
11914 { ac_try='test -s conftest$ac_exeext'
11915 { (eval echo "$as_me:11915: \"$ac_try\"") >&5
11916 (eval $ac_try) 2>&5
11918 echo "$as_me:11918: \$? = $ac_status" >&5
11919 (exit $ac_status); }; }; then
11922 echo "$as_me: failed program was:" >&5
11923 cat conftest.$ac_ext >&5
11926 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11927 if test $ac_R_nospace = yes; then
11928 echo "$as_me:11928: result: no" >&5
11929 echo "${ECHO_T}no" >&6
11930 X_LIBS="$X_LIBS -R$x_libraries"
11932 LIBS="$ac_xsave_LIBS -R $x_libraries"
11933 cat >conftest.$ac_ext <<_ACEOF
11934 #line 11934 "configure"
11935 #include "confdefs.h"
11945 rm -f conftest.$ac_objext conftest$ac_exeext
11946 if { (eval echo "$as_me:11946: \"$ac_link\"") >&5
11947 (eval $ac_link) 2>&5
11949 echo "$as_me:11949: \$? = $ac_status" >&5
11950 (exit $ac_status); } &&
11951 { ac_try='test -s conftest$ac_exeext'
11952 { (eval echo "$as_me:11952: \"$ac_try\"") >&5
11953 (eval $ac_try) 2>&5
11955 echo "$as_me:11955: \$? = $ac_status" >&5
11956 (exit $ac_status); }; }; then
11959 echo "$as_me: failed program was:" >&5
11960 cat conftest.$ac_ext >&5
11963 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11964 if test $ac_R_space = yes; then
11965 echo "$as_me:11965: result: yes" >&5
11966 echo "${ECHO_T}yes" >&6
11967 X_LIBS="$X_LIBS -R $x_libraries"
11969 echo "$as_me:11969: result: neither works" >&5
11970 echo "${ECHO_T}neither works" >&6
11973 LIBS=$ac_xsave_LIBS
11977 # Check for system-dependent libraries X programs must link with.
11978 # Do this before checking for the system-independent R6 libraries
11979 # (-lICE), since we may need -lsocket or whatever for X linking.
11981 if test "$ISC" = yes; then
11982 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
11984 # Martyn Johnson says this is needed for Ultrix, if the X
11985 # libraries were built with DECnet support. And Karl Berry says
11986 # the Alpha needs dnet_stub (dnet does not exist).
11987 ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11"
11988 cat >conftest.$ac_ext <<_ACEOF
11989 #line 11989 "configure"
11990 #include "confdefs.h"
11992 /* Override any gcc2 internal prototype to avoid an error. */
11996 /* We use char because int might match the return type of a gcc2
11997 builtin and then its argument prototype would still apply. */
11998 char XOpenDisplay ();
12007 rm -f conftest.$ac_objext conftest$ac_exeext
12008 if { (eval echo "$as_me:12008: \"$ac_link\"") >&5
12009 (eval $ac_link) 2>&5
12011 echo "$as_me:12011: \$? = $ac_status" >&5
12012 (exit $ac_status); } &&
12013 { ac_try='test -s conftest$ac_exeext'
12014 { (eval echo "$as_me:12014: \"$ac_try\"") >&5
12015 (eval $ac_try) 2>&5
12017 echo "$as_me:12017: \$? = $ac_status" >&5
12018 (exit $ac_status); }; }; then
12021 echo "$as_me: failed program was:" >&5
12022 cat conftest.$ac_ext >&5
12023 echo "$as_me:12023: checking for dnet_ntoa in -ldnet" >&5
12024 echo $ECHO_N "checking for dnet_ntoa in -ldnet... $ECHO_C" >&6
12025 if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then
12026 echo $ECHO_N "(cached) $ECHO_C" >&6
12028 ac_check_lib_save_LIBS=$LIBS
12029 LIBS="-ldnet $LIBS"
12030 cat >conftest.$ac_ext <<_ACEOF
12031 #line 12031 "configure"
12032 #include "confdefs.h"
12034 /* Override any gcc2 internal prototype to avoid an error. */
12038 /* We use char because int might match the return type of a gcc2
12039 builtin and then its argument prototype would still apply. */
12049 rm -f conftest.$ac_objext conftest$ac_exeext
12050 if { (eval echo "$as_me:12050: \"$ac_link\"") >&5
12051 (eval $ac_link) 2>&5
12053 echo "$as_me:12053: \$? = $ac_status" >&5
12054 (exit $ac_status); } &&
12055 { ac_try='test -s conftest$ac_exeext'
12056 { (eval echo "$as_me:12056: \"$ac_try\"") >&5
12057 (eval $ac_try) 2>&5
12059 echo "$as_me:12059: \$? = $ac_status" >&5
12060 (exit $ac_status); }; }; then
12061 ac_cv_lib_dnet_dnet_ntoa=yes
12063 echo "$as_me: failed program was:" >&5
12064 cat conftest.$ac_ext >&5
12065 ac_cv_lib_dnet_dnet_ntoa=no
12067 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12068 LIBS=$ac_check_lib_save_LIBS
12070 echo "$as_me:12070: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
12071 echo "${ECHO_T}$ac_cv_lib_dnet_dnet_ntoa" >&6
12072 if test $ac_cv_lib_dnet_dnet_ntoa = yes; then
12073 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
12076 if test $ac_cv_lib_dnet_dnet_ntoa = no; then
12077 echo "$as_me:12077: checking for dnet_ntoa in -ldnet_stub" >&5
12078 echo $ECHO_N "checking for dnet_ntoa in -ldnet_stub... $ECHO_C" >&6
12079 if test "${ac_cv_lib_dnet_stub_dnet_ntoa+set}" = set; then
12080 echo $ECHO_N "(cached) $ECHO_C" >&6
12082 ac_check_lib_save_LIBS=$LIBS
12083 LIBS="-ldnet_stub $LIBS"
12084 cat >conftest.$ac_ext <<_ACEOF
12085 #line 12085 "configure"
12086 #include "confdefs.h"
12088 /* Override any gcc2 internal prototype to avoid an error. */
12092 /* We use char because int might match the return type of a gcc2
12093 builtin and then its argument prototype would still apply. */
12103 rm -f conftest.$ac_objext conftest$ac_exeext
12104 if { (eval echo "$as_me:12104: \"$ac_link\"") >&5
12105 (eval $ac_link) 2>&5
12107 echo "$as_me:12107: \$? = $ac_status" >&5
12108 (exit $ac_status); } &&
12109 { ac_try='test -s conftest$ac_exeext'
12110 { (eval echo "$as_me:12110: \"$ac_try\"") >&5
12111 (eval $ac_try) 2>&5
12113 echo "$as_me:12113: \$? = $ac_status" >&5
12114 (exit $ac_status); }; }; then
12115 ac_cv_lib_dnet_stub_dnet_ntoa=yes
12117 echo "$as_me: failed program was:" >&5
12118 cat conftest.$ac_ext >&5
12119 ac_cv_lib_dnet_stub_dnet_ntoa=no
12121 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12122 LIBS=$ac_check_lib_save_LIBS
12124 echo "$as_me:12124: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5
12125 echo "${ECHO_T}$ac_cv_lib_dnet_stub_dnet_ntoa" >&6
12126 if test $ac_cv_lib_dnet_stub_dnet_ntoa = yes; then
12127 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
12132 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12133 LIBS="$ac_xsave_LIBS"
12135 # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT,
12136 # to get the SysV transport functions.
12137 # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4)
12139 # The nsl library prevents programs from opening the X display
12140 # on Irix 5.2, according to T.E. Dickey.
12141 # The functions gethostbyname, getservbyname, and inet_addr are
12142 # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking.
12143 echo "$as_me:12143: checking for gethostbyname" >&5
12144 echo $ECHO_N "checking for gethostbyname... $ECHO_C" >&6
12145 if test "${ac_cv_func_gethostbyname+set}" = set; then
12146 echo $ECHO_N "(cached) $ECHO_C" >&6
12148 cat >conftest.$ac_ext <<_ACEOF
12149 #line 12149 "configure"
12150 #include "confdefs.h"
12151 #define gethostbyname autoconf_temporary
12152 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
12153 #undef gethostbyname
12159 /* We use char because int might match the return type of a gcc2
12160 builtin and then its argument prototype would still apply. */
12161 char gethostbyname (void);
12167 /* The GNU C library defines stubs for functions which it implements
12168 to always fail with ENOSYS. Some functions are actually named
12169 something starting with __ and the normal name is an alias. */
12170 #if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
12171 #error found stub for gethostbyname
12174 return gethostbyname ();
12179 rm -f conftest.$ac_objext conftest$ac_exeext
12180 if { (eval echo "$as_me:12180: \"$ac_link\"") >&5
12181 (eval $ac_link) 2>&5
12183 echo "$as_me:12183: \$? = $ac_status" >&5
12184 (exit $ac_status); } &&
12185 { ac_try='test -s conftest$ac_exeext'
12186 { (eval echo "$as_me:12186: \"$ac_try\"") >&5
12187 (eval $ac_try) 2>&5
12189 echo "$as_me:12189: \$? = $ac_status" >&5
12190 (exit $ac_status); }; }; then
12191 ac_cv_func_gethostbyname=yes
12193 echo "$as_me: failed program was:" >&5
12194 cat conftest.$ac_ext >&5
12195 ac_cv_func_gethostbyname=no
12197 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12199 echo "$as_me:12199: result: $ac_cv_func_gethostbyname" >&5
12200 echo "${ECHO_T}$ac_cv_func_gethostbyname" >&6
12202 if test $ac_cv_func_gethostbyname = no; then
12203 echo "$as_me:12203: checking for gethostbyname in -lnsl" >&5
12204 echo $ECHO_N "checking for gethostbyname in -lnsl... $ECHO_C" >&6
12205 if test "${ac_cv_lib_nsl_gethostbyname+set}" = set; then
12206 echo $ECHO_N "(cached) $ECHO_C" >&6
12208 ac_check_lib_save_LIBS=$LIBS
12210 cat >conftest.$ac_ext <<_ACEOF
12211 #line 12211 "configure"
12212 #include "confdefs.h"
12214 /* Override any gcc2 internal prototype to avoid an error. */
12218 /* We use char because int might match the return type of a gcc2
12219 builtin and then its argument prototype would still apply. */
12220 char gethostbyname ();
12229 rm -f conftest.$ac_objext conftest$ac_exeext
12230 if { (eval echo "$as_me:12230: \"$ac_link\"") >&5
12231 (eval $ac_link) 2>&5
12233 echo "$as_me:12233: \$? = $ac_status" >&5
12234 (exit $ac_status); } &&
12235 { ac_try='test -s conftest$ac_exeext'
12236 { (eval echo "$as_me:12236: \"$ac_try\"") >&5
12237 (eval $ac_try) 2>&5
12239 echo "$as_me:12239: \$? = $ac_status" >&5
12240 (exit $ac_status); }; }; then
12241 ac_cv_lib_nsl_gethostbyname=yes
12243 echo "$as_me: failed program was:" >&5
12244 cat conftest.$ac_ext >&5
12245 ac_cv_lib_nsl_gethostbyname=no
12247 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12248 LIBS=$ac_check_lib_save_LIBS
12250 echo "$as_me:12250: result: $ac_cv_lib_nsl_gethostbyname" >&5
12251 echo "${ECHO_T}$ac_cv_lib_nsl_gethostbyname" >&6
12252 if test $ac_cv_lib_nsl_gethostbyname = yes; then
12253 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
12256 if test $ac_cv_lib_nsl_gethostbyname = no; then
12257 echo "$as_me:12257: checking for gethostbyname in -lbsd" >&5
12258 echo $ECHO_N "checking for gethostbyname in -lbsd... $ECHO_C" >&6
12259 if test "${ac_cv_lib_bsd_gethostbyname+set}" = set; then
12260 echo $ECHO_N "(cached) $ECHO_C" >&6
12262 ac_check_lib_save_LIBS=$LIBS
12264 cat >conftest.$ac_ext <<_ACEOF
12265 #line 12265 "configure"
12266 #include "confdefs.h"
12268 /* Override any gcc2 internal prototype to avoid an error. */
12272 /* We use char because int might match the return type of a gcc2
12273 builtin and then its argument prototype would still apply. */
12274 char gethostbyname ();
12283 rm -f conftest.$ac_objext conftest$ac_exeext
12284 if { (eval echo "$as_me:12284: \"$ac_link\"") >&5
12285 (eval $ac_link) 2>&5
12287 echo "$as_me:12287: \$? = $ac_status" >&5
12288 (exit $ac_status); } &&
12289 { ac_try='test -s conftest$ac_exeext'
12290 { (eval echo "$as_me:12290: \"$ac_try\"") >&5
12291 (eval $ac_try) 2>&5
12293 echo "$as_me:12293: \$? = $ac_status" >&5
12294 (exit $ac_status); }; }; then
12295 ac_cv_lib_bsd_gethostbyname=yes
12297 echo "$as_me: failed program was:" >&5
12298 cat conftest.$ac_ext >&5
12299 ac_cv_lib_bsd_gethostbyname=no
12301 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12302 LIBS=$ac_check_lib_save_LIBS
12304 echo "$as_me:12304: result: $ac_cv_lib_bsd_gethostbyname" >&5
12305 echo "${ECHO_T}$ac_cv_lib_bsd_gethostbyname" >&6
12306 if test $ac_cv_lib_bsd_gethostbyname = yes; then
12307 X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd"
12313 # lieder@skyler.mavd.honeywell.com says without -lsocket,
12314 # socket/setsockopt and other routines are undefined under SCO ODT
12315 # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary
12316 # on later versions), says Simon Leinen: it contains gethostby*
12317 # variants that don't use the nameserver (or something). -lsocket
12318 # must be given before -lnsl if both are needed. We assume that
12319 # if connect needs -lnsl, so does gethostbyname.
12320 echo "$as_me:12320: checking for connect" >&5
12321 echo $ECHO_N "checking for connect... $ECHO_C" >&6
12322 if test "${ac_cv_func_connect+set}" = set; then
12323 echo $ECHO_N "(cached) $ECHO_C" >&6
12325 cat >conftest.$ac_ext <<_ACEOF
12326 #line 12326 "configure"
12327 #include "confdefs.h"
12328 #define connect autoconf_temporary
12329 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
12336 /* We use char because int might match the return type of a gcc2
12337 builtin and then its argument prototype would still apply. */
12338 char connect (void);
12344 /* The GNU C library defines stubs for functions which it implements
12345 to always fail with ENOSYS. Some functions are actually named
12346 something starting with __ and the normal name is an alias. */
12347 #if defined (__stub_connect) || defined (__stub___connect)
12348 #error found stub for connect
12356 rm -f conftest.$ac_objext conftest$ac_exeext
12357 if { (eval echo "$as_me:12357: \"$ac_link\"") >&5
12358 (eval $ac_link) 2>&5
12360 echo "$as_me:12360: \$? = $ac_status" >&5
12361 (exit $ac_status); } &&
12362 { ac_try='test -s conftest$ac_exeext'
12363 { (eval echo "$as_me:12363: \"$ac_try\"") >&5
12364 (eval $ac_try) 2>&5
12366 echo "$as_me:12366: \$? = $ac_status" >&5
12367 (exit $ac_status); }; }; then
12368 ac_cv_func_connect=yes
12370 echo "$as_me: failed program was:" >&5
12371 cat conftest.$ac_ext >&5
12372 ac_cv_func_connect=no
12374 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12376 echo "$as_me:12376: result: $ac_cv_func_connect" >&5
12377 echo "${ECHO_T}$ac_cv_func_connect" >&6
12379 if test $ac_cv_func_connect = no; then
12380 echo "$as_me:12380: checking for connect in -lsocket" >&5
12381 echo $ECHO_N "checking for connect in -lsocket... $ECHO_C" >&6
12382 if test "${ac_cv_lib_socket_connect+set}" = set; then
12383 echo $ECHO_N "(cached) $ECHO_C" >&6
12385 ac_check_lib_save_LIBS=$LIBS
12386 LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
12387 cat >conftest.$ac_ext <<_ACEOF
12388 #line 12388 "configure"
12389 #include "confdefs.h"
12391 /* Override any gcc2 internal prototype to avoid an error. */
12395 /* We use char because int might match the return type of a gcc2
12396 builtin and then its argument prototype would still apply. */
12406 rm -f conftest.$ac_objext conftest$ac_exeext
12407 if { (eval echo "$as_me:12407: \"$ac_link\"") >&5
12408 (eval $ac_link) 2>&5
12410 echo "$as_me:12410: \$? = $ac_status" >&5
12411 (exit $ac_status); } &&
12412 { ac_try='test -s conftest$ac_exeext'
12413 { (eval echo "$as_me:12413: \"$ac_try\"") >&5
12414 (eval $ac_try) 2>&5
12416 echo "$as_me:12416: \$? = $ac_status" >&5
12417 (exit $ac_status); }; }; then
12418 ac_cv_lib_socket_connect=yes
12420 echo "$as_me: failed program was:" >&5
12421 cat conftest.$ac_ext >&5
12422 ac_cv_lib_socket_connect=no
12424 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12425 LIBS=$ac_check_lib_save_LIBS
12427 echo "$as_me:12427: result: $ac_cv_lib_socket_connect" >&5
12428 echo "${ECHO_T}$ac_cv_lib_socket_connect" >&6
12429 if test $ac_cv_lib_socket_connect = yes; then
12430 X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS"
12435 # Guillermo Gomez says -lposix is necessary on A/UX.
12436 echo "$as_me:12436: checking for remove" >&5
12437 echo $ECHO_N "checking for remove... $ECHO_C" >&6
12438 if test "${ac_cv_func_remove+set}" = set; then
12439 echo $ECHO_N "(cached) $ECHO_C" >&6
12441 cat >conftest.$ac_ext <<_ACEOF
12442 #line 12442 "configure"
12443 #include "confdefs.h"
12444 #define remove autoconf_temporary
12445 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
12452 /* We use char because int might match the return type of a gcc2
12453 builtin and then its argument prototype would still apply. */
12454 char remove (void);
12460 /* The GNU C library defines stubs for functions which it implements
12461 to always fail with ENOSYS. Some functions are actually named
12462 something starting with __ and the normal name is an alias. */
12463 #if defined (__stub_remove) || defined (__stub___remove)
12464 #error found stub for remove
12472 rm -f conftest.$ac_objext conftest$ac_exeext
12473 if { (eval echo "$as_me:12473: \"$ac_link\"") >&5
12474 (eval $ac_link) 2>&5
12476 echo "$as_me:12476: \$? = $ac_status" >&5
12477 (exit $ac_status); } &&
12478 { ac_try='test -s conftest$ac_exeext'
12479 { (eval echo "$as_me:12479: \"$ac_try\"") >&5
12480 (eval $ac_try) 2>&5
12482 echo "$as_me:12482: \$? = $ac_status" >&5
12483 (exit $ac_status); }; }; then
12484 ac_cv_func_remove=yes
12486 echo "$as_me: failed program was:" >&5
12487 cat conftest.$ac_ext >&5
12488 ac_cv_func_remove=no
12490 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12492 echo "$as_me:12492: result: $ac_cv_func_remove" >&5
12493 echo "${ECHO_T}$ac_cv_func_remove" >&6
12495 if test $ac_cv_func_remove = no; then
12496 echo "$as_me:12496: checking for remove in -lposix" >&5
12497 echo $ECHO_N "checking for remove in -lposix... $ECHO_C" >&6
12498 if test "${ac_cv_lib_posix_remove+set}" = set; then
12499 echo $ECHO_N "(cached) $ECHO_C" >&6
12501 ac_check_lib_save_LIBS=$LIBS
12502 LIBS="-lposix $LIBS"
12503 cat >conftest.$ac_ext <<_ACEOF
12504 #line 12504 "configure"
12505 #include "confdefs.h"
12507 /* Override any gcc2 internal prototype to avoid an error. */
12511 /* We use char because int might match the return type of a gcc2
12512 builtin and then its argument prototype would still apply. */
12522 rm -f conftest.$ac_objext conftest$ac_exeext
12523 if { (eval echo "$as_me:12523: \"$ac_link\"") >&5
12524 (eval $ac_link) 2>&5
12526 echo "$as_me:12526: \$? = $ac_status" >&5
12527 (exit $ac_status); } &&
12528 { ac_try='test -s conftest$ac_exeext'
12529 { (eval echo "$as_me:12529: \"$ac_try\"") >&5
12530 (eval $ac_try) 2>&5
12532 echo "$as_me:12532: \$? = $ac_status" >&5
12533 (exit $ac_status); }; }; then
12534 ac_cv_lib_posix_remove=yes
12536 echo "$as_me: failed program was:" >&5
12537 cat conftest.$ac_ext >&5
12538 ac_cv_lib_posix_remove=no
12540 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12541 LIBS=$ac_check_lib_save_LIBS
12543 echo "$as_me:12543: result: $ac_cv_lib_posix_remove" >&5
12544 echo "${ECHO_T}$ac_cv_lib_posix_remove" >&6
12545 if test $ac_cv_lib_posix_remove = yes; then
12546 X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix"
12551 # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
12552 echo "$as_me:12552: checking for shmat" >&5
12553 echo $ECHO_N "checking for shmat... $ECHO_C" >&6
12554 if test "${ac_cv_func_shmat+set}" = set; then
12555 echo $ECHO_N "(cached) $ECHO_C" >&6
12557 cat >conftest.$ac_ext <<_ACEOF
12558 #line 12558 "configure"
12559 #include "confdefs.h"
12560 #define shmat autoconf_temporary
12561 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
12568 /* We use char because int might match the return type of a gcc2
12569 builtin and then its argument prototype would still apply. */
12576 /* The GNU C library defines stubs for functions which it implements
12577 to always fail with ENOSYS. Some functions are actually named
12578 something starting with __ and the normal name is an alias. */
12579 #if defined (__stub_shmat) || defined (__stub___shmat)
12580 #error found stub for shmat
12588 rm -f conftest.$ac_objext conftest$ac_exeext
12589 if { (eval echo "$as_me:12589: \"$ac_link\"") >&5
12590 (eval $ac_link) 2>&5
12592 echo "$as_me:12592: \$? = $ac_status" >&5
12593 (exit $ac_status); } &&
12594 { ac_try='test -s conftest$ac_exeext'
12595 { (eval echo "$as_me:12595: \"$ac_try\"") >&5
12596 (eval $ac_try) 2>&5
12598 echo "$as_me:12598: \$? = $ac_status" >&5
12599 (exit $ac_status); }; }; then
12600 ac_cv_func_shmat=yes
12602 echo "$as_me: failed program was:" >&5
12603 cat conftest.$ac_ext >&5
12604 ac_cv_func_shmat=no
12606 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12608 echo "$as_me:12608: result: $ac_cv_func_shmat" >&5
12609 echo "${ECHO_T}$ac_cv_func_shmat" >&6
12611 if test $ac_cv_func_shmat = no; then
12612 echo "$as_me:12612: checking for shmat in -lipc" >&5
12613 echo $ECHO_N "checking for shmat in -lipc... $ECHO_C" >&6
12614 if test "${ac_cv_lib_ipc_shmat+set}" = set; then
12615 echo $ECHO_N "(cached) $ECHO_C" >&6
12617 ac_check_lib_save_LIBS=$LIBS
12619 cat >conftest.$ac_ext <<_ACEOF
12620 #line 12620 "configure"
12621 #include "confdefs.h"
12623 /* Override any gcc2 internal prototype to avoid an error. */
12627 /* We use char because int might match the return type of a gcc2
12628 builtin and then its argument prototype would still apply. */
12638 rm -f conftest.$ac_objext conftest$ac_exeext
12639 if { (eval echo "$as_me:12639: \"$ac_link\"") >&5
12640 (eval $ac_link) 2>&5
12642 echo "$as_me:12642: \$? = $ac_status" >&5
12643 (exit $ac_status); } &&
12644 { ac_try='test -s conftest$ac_exeext'
12645 { (eval echo "$as_me:12645: \"$ac_try\"") >&5
12646 (eval $ac_try) 2>&5
12648 echo "$as_me:12648: \$? = $ac_status" >&5
12649 (exit $ac_status); }; }; then
12650 ac_cv_lib_ipc_shmat=yes
12652 echo "$as_me: failed program was:" >&5
12653 cat conftest.$ac_ext >&5
12654 ac_cv_lib_ipc_shmat=no
12656 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12657 LIBS=$ac_check_lib_save_LIBS
12659 echo "$as_me:12659: result: $ac_cv_lib_ipc_shmat" >&5
12660 echo "${ECHO_T}$ac_cv_lib_ipc_shmat" >&6
12661 if test $ac_cv_lib_ipc_shmat = yes; then
12662 X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc"
12668 # Check for libraries that X11R6 Xt/Xaw programs need.
12669 ac_save_LDFLAGS=$LDFLAGS
12670 test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries"
12671 # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
12672 # check for ICE first), but we must link in the order -lSM -lICE or
12673 # we get undefined symbols. So assume we have SM if we have ICE.
12674 # These have to be linked with before -lX11, unlike the other
12675 # libraries we check for below, so use a different variable.
12676 # John Interrante, Karl Berry
12677 echo "$as_me:12677: checking for IceConnectionNumber in -lICE" >&5
12678 echo $ECHO_N "checking for IceConnectionNumber in -lICE... $ECHO_C" >&6
12679 if test "${ac_cv_lib_ICE_IceConnectionNumber+set}" = set; then
12680 echo $ECHO_N "(cached) $ECHO_C" >&6
12682 ac_check_lib_save_LIBS=$LIBS
12683 LIBS="-lICE $X_EXTRA_LIBS $LIBS"
12684 cat >conftest.$ac_ext <<_ACEOF
12685 #line 12685 "configure"
12686 #include "confdefs.h"
12688 /* Override any gcc2 internal prototype to avoid an error. */
12692 /* We use char because int might match the return type of a gcc2
12693 builtin and then its argument prototype would still apply. */
12694 char IceConnectionNumber ();
12698 IceConnectionNumber ();
12703 rm -f conftest.$ac_objext conftest$ac_exeext
12704 if { (eval echo "$as_me:12704: \"$ac_link\"") >&5
12705 (eval $ac_link) 2>&5
12707 echo "$as_me:12707: \$? = $ac_status" >&5
12708 (exit $ac_status); } &&
12709 { ac_try='test -s conftest$ac_exeext'
12710 { (eval echo "$as_me:12710: \"$ac_try\"") >&5
12711 (eval $ac_try) 2>&5
12713 echo "$as_me:12713: \$? = $ac_status" >&5
12714 (exit $ac_status); }; }; then
12715 ac_cv_lib_ICE_IceConnectionNumber=yes
12717 echo "$as_me: failed program was:" >&5
12718 cat conftest.$ac_ext >&5
12719 ac_cv_lib_ICE_IceConnectionNumber=no
12721 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12722 LIBS=$ac_check_lib_save_LIBS
12724 echo "$as_me:12724: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5
12725 echo "${ECHO_T}$ac_cv_lib_ICE_IceConnectionNumber" >&6
12726 if test $ac_cv_lib_ICE_IceConnectionNumber = yes; then
12727 X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
12730 LDFLAGS=$ac_save_LDFLAGS
12734 cf_x_athena=${cf_x_athena:-Xaw}
12736 echo "$as_me:12736: checking if you want to link with Xaw 3d library" >&5
12737 echo $ECHO_N "checking if you want to link with Xaw 3d library... $ECHO_C" >&6
12740 # Check whether --with-Xaw3d or --without-Xaw3d was given.
12741 if test "${with_Xaw3d+set}" = set; then
12742 withval="$with_Xaw3d"
12745 if test "$withval" = yes ; then
12747 echo "$as_me:12747: result: yes" >&5
12748 echo "${ECHO_T}yes" >&6
12750 echo "$as_me:12750: result: no" >&5
12751 echo "${ECHO_T}no" >&6
12754 echo "$as_me:12754: checking if you want to link with Xaw 3d xft library" >&5
12755 echo $ECHO_N "checking if you want to link with Xaw 3d xft library... $ECHO_C" >&6
12758 # Check whether --with-Xaw3dxft or --without-Xaw3dxft was given.
12759 if test "${with_Xaw3dxft+set}" = set; then
12760 withval="$with_Xaw3dxft"
12763 if test "$withval" = yes ; then
12764 cf_x_athena=Xaw3dxft
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 neXT Athena library" >&5
12773 echo $ECHO_N "checking if you want to link with neXT Athena library... $ECHO_C" >&6
12776 # Check whether --with-neXtaw or --without-neXtaw was given.
12777 if test "${with_neXtaw+set}" = set; then
12778 withval="$with_neXtaw"
12781 if test "$withval" = yes ; then
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 Athena-Plus library" >&5
12791 echo $ECHO_N "checking if you want to link with Athena-Plus library... $ECHO_C" >&6
12794 # Check whether --with-XawPlus or --without-XawPlus was given.
12795 if test "${with_XawPlus+set}" = set; then
12796 withval="$with_XawPlus"
12799 if test "$withval" = yes ; then
12800 cf_x_athena=XawPlus
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
12810 if test "$PKG_CONFIG" != none ; then
12812 test "$cf_x_athena" = Xaw && cf_athena_list="xaw8 xaw7 xaw6"
12813 for cf_athena_pkg in \
12816 ${cf_x_athena}-devel \
12817 lib${cf_x_athena} \
12818 lib${cf_x_athena}-devel
12821 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists $cf_athena_pkg; then
12822 test -n "$verbose" && echo " found package $cf_athena_pkg" 1>&6
12824 echo "${as_me:-configure}:12824: testing found package $cf_athena_pkg ..." 1>&5
12826 cf_pkgconfig_incs="`$PKG_CONFIG --cflags $cf_athena_pkg 2>/dev/null`"
12827 cf_pkgconfig_libs="`$PKG_CONFIG --libs $cf_athena_pkg 2>/dev/null`"
12828 test -n "$verbose" && echo " package $cf_athena_pkg CFLAGS: $cf_pkgconfig_incs" 1>&6
12830 echo "${as_me:-configure}:12830: testing package $cf_athena_pkg CFLAGS: $cf_pkgconfig_incs ..." 1>&5
12832 test -n "$verbose" && echo " package $cf_athena_pkg LIBS: $cf_pkgconfig_libs" 1>&6
12834 echo "${as_me:-configure}:12834: testing package $cf_athena_pkg LIBS: $cf_pkgconfig_libs ..." 1>&5
12839 cf_new_extra_cppflags=
12841 for cf_add_cflags in $cf_pkgconfig_incs
12843 case $cf_fix_cppflags in
12845 case $cf_add_cflags in
12846 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
12847 case $cf_add_cflags in
12849 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
12851 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12852 && test -z "${cf_tst_cflags}" \
12853 && cf_fix_cppflags=yes
12855 if test $cf_fix_cppflags = yes ; then
12857 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12858 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12861 elif test "${cf_tst_cflags}" = "\"'" ; then
12863 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12864 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12870 case "$CPPFLAGS" in
12874 case $cf_add_cflags in
12876 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12878 CPPFLAGS=`echo "$CPPFLAGS" | \
12879 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12880 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12885 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
12886 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
12893 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
12894 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
12901 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12902 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12904 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
12906 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12907 && test -z "${cf_tst_cflags}" \
12908 && cf_fix_cppflags=no
12913 if test -n "$cf_new_cflags" ; then
12915 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
12916 CFLAGS="${CFLAGS}$cf_new_cflags"
12920 if test -n "$cf_new_cppflags" ; then
12922 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
12923 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
12927 if test -n "$cf_new_extra_cppflags" ; then
12929 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
12930 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
12934 cf_add_libs="$LIBS"
12937 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
12938 # filter duplicates
12939 for cf_add_1lib in $cf_add_0lib; do
12940 for cf_add_2lib in $cf_add_libs; do
12941 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
12946 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
12948 LIBS="$cf_add_libs"
12950 cf_x_athena_lib="$cf_pkgconfig_libs"
12952 cf_x_athena_LIBS=`echo "HAVE_LIB_$cf_x_athena" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
12954 cat >>confdefs.h <<EOF
12955 #define $cf_x_athena_LIBS 1
12958 for cf_trim_lib in Xmu Xt X11
12961 (*-l$cf_trim_lib\ *-l$cf_trim_lib*)
12962 LIBS=`echo "$LIBS " | sed -e 's/ / /g' -e 's%-l'"$cf_trim_lib"' %%' -e 's/ $//'`
12963 test -n "$verbose" && echo " ..trimmed $LIBS" 1>&6
12965 echo "${as_me:-configure}:12965: testing ..trimmed $LIBS ..." 1>&5
12971 echo "$as_me:12971: checking for usable $cf_x_athena/Xmu package" >&5
12972 echo $ECHO_N "checking for usable $cf_x_athena/Xmu package... $ECHO_C" >&6
12973 if test "${cf_cv_xaw_compat+set}" = set; then
12974 echo $ECHO_N "(cached) $ECHO_C" >&6
12977 cat >conftest.$ac_ext <<_ACEOF
12978 #line 12978 "configure"
12979 #include "confdefs.h"
12981 #include <X11/Xmu/CharSet.h>
12987 int check = XmuCompareISOLatin1("big", "small");
12994 rm -f conftest.$ac_objext conftest$ac_exeext
12995 if { (eval echo "$as_me:12995: \"$ac_link\"") >&5
12996 (eval $ac_link) 2>&5
12998 echo "$as_me:12998: \$? = $ac_status" >&5
12999 (exit $ac_status); } &&
13000 { ac_try='test -s conftest$ac_exeext'
13001 { (eval echo "$as_me:13001: \"$ac_try\"") >&5
13002 (eval $ac_try) 2>&5
13004 echo "$as_me:13004: \$? = $ac_status" >&5
13005 (exit $ac_status); }; }; then
13006 cf_cv_xaw_compat=yes
13008 echo "$as_me: failed program was:" >&5
13009 cat conftest.$ac_ext >&5
13010 cf_cv_xaw_compat=no
13012 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13014 echo "$as_me:13014: result: $cf_cv_xaw_compat" >&5
13015 echo "${ECHO_T}$cf_cv_xaw_compat" >&6
13017 if test "$cf_cv_xaw_compat" = no
13019 # workaround for broken ".pc" files...
13020 case "$cf_x_athena_lib" in
13024 test -n "$verbose" && echo " work around broken package" 1>&6
13026 echo "${as_me:-configure}:13026: testing work around broken package ..." 1>&5
13028 cf_save_xmu="$LIBS"
13029 cf_first_lib=`echo "$cf_save_xmu" | sed -e 's/^ *//' -e 's/ .*//'`
13031 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xmu; then
13032 test -n "$verbose" && echo " found package xmu" 1>&6
13034 echo "${as_me:-configure}:13034: testing found package xmu ..." 1>&5
13036 cf_pkgconfig_incs="`$PKG_CONFIG --cflags xmu 2>/dev/null`"
13037 cf_pkgconfig_libs="`$PKG_CONFIG --libs xmu 2>/dev/null`"
13038 test -n "$verbose" && echo " package xmu CFLAGS: $cf_pkgconfig_incs" 1>&6
13040 echo "${as_me:-configure}:13040: testing package xmu CFLAGS: $cf_pkgconfig_incs ..." 1>&5
13042 test -n "$verbose" && echo " package xmu LIBS: $cf_pkgconfig_libs" 1>&6
13044 echo "${as_me:-configure}:13044: testing package xmu LIBS: $cf_pkgconfig_libs ..." 1>&5
13049 cf_new_extra_cppflags=
13051 for cf_add_cflags in $cf_pkgconfig_incs
13053 case $cf_fix_cppflags in
13055 case $cf_add_cflags in
13056 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
13057 case $cf_add_cflags in
13059 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
13061 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13062 && test -z "${cf_tst_cflags}" \
13063 && cf_fix_cppflags=yes
13065 if test $cf_fix_cppflags = yes ; then
13067 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13068 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13071 elif test "${cf_tst_cflags}" = "\"'" ; then
13073 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13074 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13080 case "$CPPFLAGS" in
13084 case $cf_add_cflags in
13086 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
13088 CPPFLAGS=`echo "$CPPFLAGS" | \
13089 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
13090 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
13095 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
13096 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
13103 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
13104 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
13111 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13112 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13114 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
13116 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13117 && test -z "${cf_tst_cflags}" \
13118 && cf_fix_cppflags=no
13123 if test -n "$cf_new_cflags" ; then
13125 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
13126 CFLAGS="${CFLAGS}$cf_new_cflags"
13130 if test -n "$cf_new_cppflags" ; then
13132 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13133 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
13137 if test -n "$cf_new_extra_cppflags" ; then
13139 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
13140 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
13144 cf_add_libs="$LIBS"
13147 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
13148 # filter duplicates
13149 for cf_add_1lib in $cf_add_0lib; do
13150 for cf_add_2lib in $cf_add_libs; do
13151 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
13156 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
13158 LIBS="$cf_add_libs"
13160 LIBS="$cf_save_xmu"
13162 test -n "$verbose" && echo " ...before $LIBS" 1>&6
13164 echo "${as_me:-configure}:13164: testing ...before $LIBS ..." 1>&5
13166 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%$cf_first_lib %$cf_first_lib $cf_pkgconfig_libs %" -e 's% % %g'`
13167 test -n "$verbose" && echo " ...after $LIBS" 1>&6
13169 echo "${as_me:-configure}:13169: testing ...after $LIBS ..." 1>&5
13175 test -n "$verbose" && echo " ...before $LIBS" 1>&6
13177 echo "${as_me:-configure}:13177: testing ...before $LIBS ..." 1>&5
13179 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%$cf_first_lib %$cf_first_lib -lXmu %" -e 's% % %g'`
13180 test -n "$verbose" && echo " ...after $LIBS" 1>&6
13182 echo "${as_me:-configure}:13182: testing ...after $LIBS ..." 1>&5
13186 for cf_trim_lib in Xmu Xt X11
13189 (*-l$cf_trim_lib\ *-l$cf_trim_lib*)
13190 LIBS=`echo "$LIBS " | sed -e 's/ / /g' -e 's%-l'"$cf_trim_lib"' %%' -e 's/ $//'`
13191 test -n "$verbose" && echo " ..trimmed $LIBS" 1>&6
13193 echo "${as_me:-configure}:13193: testing ..trimmed $LIBS ..." 1>&5
13213 if test -z "$cf_x_athena_lib" ; then
13215 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists Xext; then
13216 test -n "$verbose" && echo " found package Xext" 1>&6
13218 echo "${as_me:-configure}:13218: testing found package Xext ..." 1>&5
13220 cf_pkgconfig_incs="`$PKG_CONFIG --cflags Xext 2>/dev/null`"
13221 cf_pkgconfig_libs="`$PKG_CONFIG --libs Xext 2>/dev/null`"
13222 test -n "$verbose" && echo " package Xext CFLAGS: $cf_pkgconfig_incs" 1>&6
13224 echo "${as_me:-configure}:13224: testing package Xext CFLAGS: $cf_pkgconfig_incs ..." 1>&5
13226 test -n "$verbose" && echo " package Xext LIBS: $cf_pkgconfig_libs" 1>&6
13228 echo "${as_me:-configure}:13228: testing package Xext LIBS: $cf_pkgconfig_libs ..." 1>&5
13233 cf_new_extra_cppflags=
13235 for cf_add_cflags in $cf_pkgconfig_incs
13237 case $cf_fix_cppflags in
13239 case $cf_add_cflags in
13240 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
13241 case $cf_add_cflags in
13243 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
13245 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13246 && test -z "${cf_tst_cflags}" \
13247 && cf_fix_cppflags=yes
13249 if test $cf_fix_cppflags = yes ; then
13251 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13252 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13255 elif test "${cf_tst_cflags}" = "\"'" ; then
13257 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13258 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13264 case "$CPPFLAGS" in
13268 case $cf_add_cflags in
13270 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
13272 CPPFLAGS=`echo "$CPPFLAGS" | \
13273 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
13274 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
13279 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
13280 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
13287 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
13288 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
13295 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13296 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13298 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
13300 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13301 && test -z "${cf_tst_cflags}" \
13302 && cf_fix_cppflags=no
13307 if test -n "$cf_new_cflags" ; then
13309 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
13310 CFLAGS="${CFLAGS}$cf_new_cflags"
13314 if test -n "$cf_new_cppflags" ; then
13316 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13317 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
13321 if test -n "$cf_new_extra_cppflags" ; then
13323 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
13324 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
13328 cf_add_libs="$LIBS"
13331 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
13332 # filter duplicates
13333 for cf_add_1lib in $cf_add_0lib; do
13334 for cf_add_2lib in $cf_add_libs; do
13335 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
13340 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
13342 LIBS="$cf_add_libs"
13349 echo "$as_me:13349: checking for XextCreateExtension in -lXext" >&5
13350 echo $ECHO_N "checking for XextCreateExtension in -lXext... $ECHO_C" >&6
13351 if test "${ac_cv_lib_Xext_XextCreateExtension+set}" = set; then
13352 echo $ECHO_N "(cached) $ECHO_C" >&6
13354 ac_check_lib_save_LIBS=$LIBS
13355 LIBS="-lXext $LIBS"
13356 cat >conftest.$ac_ext <<_ACEOF
13357 #line 13357 "configure"
13358 #include "confdefs.h"
13360 /* Override any gcc2 internal prototype to avoid an error. */
13364 /* We use char because int might match the return type of a gcc2
13365 builtin and then its argument prototype would still apply. */
13366 char XextCreateExtension ();
13370 XextCreateExtension ();
13375 rm -f conftest.$ac_objext conftest$ac_exeext
13376 if { (eval echo "$as_me:13376: \"$ac_link\"") >&5
13377 (eval $ac_link) 2>&5
13379 echo "$as_me:13379: \$? = $ac_status" >&5
13380 (exit $ac_status); } &&
13381 { ac_try='test -s conftest$ac_exeext'
13382 { (eval echo "$as_me:13382: \"$ac_try\"") >&5
13383 (eval $ac_try) 2>&5
13385 echo "$as_me:13385: \$? = $ac_status" >&5
13386 (exit $ac_status); }; }; then
13387 ac_cv_lib_Xext_XextCreateExtension=yes
13389 echo "$as_me: failed program was:" >&5
13390 cat conftest.$ac_ext >&5
13391 ac_cv_lib_Xext_XextCreateExtension=no
13393 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13394 LIBS=$ac_check_lib_save_LIBS
13396 echo "$as_me:13396: result: $ac_cv_lib_Xext_XextCreateExtension" >&5
13397 echo "${ECHO_T}$ac_cv_lib_Xext_XextCreateExtension" >&6
13398 if test $ac_cv_lib_Xext_XextCreateExtension = yes; then
13400 cf_add_libs="$LIBS"
13403 for cf_add_1lib in -lXext; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
13404 # filter duplicates
13405 for cf_add_1lib in $cf_add_0lib; do
13406 for cf_add_2lib in $cf_add_libs; do
13407 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
13412 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
13414 LIBS="$cf_add_libs"
13420 # OSX is schizoid about who owns /usr/X11 (old) versus /opt/X11 (new) (and
13421 # in some cases has installed dummy files in the former, other cases replaced
13422 # it with a link to the new location). This complicates the configure script.
13423 # Check for that pitfall, and recover using pkg-config
13425 # If none of these are set, the configuration is almost certainly broken.
13426 if test -z "${X_CFLAGS}${X_PRE_LIBS}${X_LIBS}${X_EXTRA_LIBS}"
13429 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists x11; then
13430 test -n "$verbose" && echo " found package x11" 1>&6
13432 echo "${as_me:-configure}:13432: testing found package x11 ..." 1>&5
13434 cf_pkgconfig_incs="`$PKG_CONFIG --cflags x11 2>/dev/null`"
13435 cf_pkgconfig_libs="`$PKG_CONFIG --libs x11 2>/dev/null`"
13436 test -n "$verbose" && echo " package x11 CFLAGS: $cf_pkgconfig_incs" 1>&6
13438 echo "${as_me:-configure}:13438: testing package x11 CFLAGS: $cf_pkgconfig_incs ..." 1>&5
13440 test -n "$verbose" && echo " package x11 LIBS: $cf_pkgconfig_libs" 1>&6
13442 echo "${as_me:-configure}:13442: testing package x11 LIBS: $cf_pkgconfig_libs ..." 1>&5
13447 cf_new_extra_cppflags=
13449 for cf_add_cflags in $cf_pkgconfig_incs
13451 case $cf_fix_cppflags in
13453 case $cf_add_cflags in
13454 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
13455 case $cf_add_cflags in
13457 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
13459 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13460 && test -z "${cf_tst_cflags}" \
13461 && cf_fix_cppflags=yes
13463 if test $cf_fix_cppflags = yes ; then
13465 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13466 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13469 elif test "${cf_tst_cflags}" = "\"'" ; then
13471 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13472 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13478 case "$CPPFLAGS" in
13482 case $cf_add_cflags in
13484 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
13486 CPPFLAGS=`echo "$CPPFLAGS" | \
13487 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
13488 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
13493 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
13494 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
13501 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
13502 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
13509 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13510 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13512 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
13514 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13515 && test -z "${cf_tst_cflags}" \
13516 && cf_fix_cppflags=no
13521 if test -n "$cf_new_cflags" ; then
13523 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
13524 CFLAGS="${CFLAGS}$cf_new_cflags"
13528 if test -n "$cf_new_cppflags" ; then
13530 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13531 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
13535 if test -n "$cf_new_extra_cppflags" ; then
13537 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
13538 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
13542 cf_add_libs="$LIBS"
13545 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
13546 # filter duplicates
13547 for cf_add_1lib in $cf_add_0lib; do
13548 for cf_add_2lib in $cf_add_libs; do
13549 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
13554 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
13556 LIBS="$cf_add_libs"
13562 { echo "$as_me:13562: WARNING: unable to find X11 library" >&5
13563 echo "$as_me: WARNING: unable to find X11 library" >&2;}
13566 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists ice; then
13567 test -n "$verbose" && echo " found package ice" 1>&6
13569 echo "${as_me:-configure}:13569: testing found package ice ..." 1>&5
13571 cf_pkgconfig_incs="`$PKG_CONFIG --cflags ice 2>/dev/null`"
13572 cf_pkgconfig_libs="`$PKG_CONFIG --libs ice 2>/dev/null`"
13573 test -n "$verbose" && echo " package ice CFLAGS: $cf_pkgconfig_incs" 1>&6
13575 echo "${as_me:-configure}:13575: testing package ice CFLAGS: $cf_pkgconfig_incs ..." 1>&5
13577 test -n "$verbose" && echo " package ice LIBS: $cf_pkgconfig_libs" 1>&6
13579 echo "${as_me:-configure}:13579: testing package ice LIBS: $cf_pkgconfig_libs ..." 1>&5
13584 cf_new_extra_cppflags=
13586 for cf_add_cflags in $cf_pkgconfig_incs
13588 case $cf_fix_cppflags in
13590 case $cf_add_cflags in
13591 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
13592 case $cf_add_cflags in
13594 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
13596 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13597 && test -z "${cf_tst_cflags}" \
13598 && cf_fix_cppflags=yes
13600 if test $cf_fix_cppflags = yes ; then
13602 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13603 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13606 elif test "${cf_tst_cflags}" = "\"'" ; then
13608 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13609 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13615 case "$CPPFLAGS" in
13619 case $cf_add_cflags in
13621 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
13623 CPPFLAGS=`echo "$CPPFLAGS" | \
13624 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
13625 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
13630 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
13631 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
13638 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
13639 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
13646 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13647 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13649 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
13651 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13652 && test -z "${cf_tst_cflags}" \
13653 && cf_fix_cppflags=no
13658 if test -n "$cf_new_cflags" ; then
13660 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
13661 CFLAGS="${CFLAGS}$cf_new_cflags"
13665 if test -n "$cf_new_cppflags" ; then
13667 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13668 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
13672 if test -n "$cf_new_extra_cppflags" ; then
13674 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
13675 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
13679 cf_add_libs="$LIBS"
13682 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
13683 # filter duplicates
13684 for cf_add_1lib in $cf_add_0lib; do
13685 for cf_add_2lib in $cf_add_libs; do
13686 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
13691 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
13693 LIBS="$cf_add_libs"
13699 { echo "$as_me:13699: WARNING: unable to find ICE library" >&5
13700 echo "$as_me: WARNING: unable to find ICE library" >&2;}
13703 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists sm; then
13704 test -n "$verbose" && echo " found package sm" 1>&6
13706 echo "${as_me:-configure}:13706: testing found package sm ..." 1>&5
13708 cf_pkgconfig_incs="`$PKG_CONFIG --cflags sm 2>/dev/null`"
13709 cf_pkgconfig_libs="`$PKG_CONFIG --libs sm 2>/dev/null`"
13710 test -n "$verbose" && echo " package sm CFLAGS: $cf_pkgconfig_incs" 1>&6
13712 echo "${as_me:-configure}:13712: testing package sm CFLAGS: $cf_pkgconfig_incs ..." 1>&5
13714 test -n "$verbose" && echo " package sm LIBS: $cf_pkgconfig_libs" 1>&6
13716 echo "${as_me:-configure}:13716: testing package sm LIBS: $cf_pkgconfig_libs ..." 1>&5
13721 cf_new_extra_cppflags=
13723 for cf_add_cflags in $cf_pkgconfig_incs
13725 case $cf_fix_cppflags in
13727 case $cf_add_cflags in
13728 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
13729 case $cf_add_cflags in
13731 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
13733 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13734 && test -z "${cf_tst_cflags}" \
13735 && cf_fix_cppflags=yes
13737 if test $cf_fix_cppflags = yes ; then
13739 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13740 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13743 elif test "${cf_tst_cflags}" = "\"'" ; then
13745 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13746 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13752 case "$CPPFLAGS" in
13756 case $cf_add_cflags in
13758 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
13760 CPPFLAGS=`echo "$CPPFLAGS" | \
13761 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
13762 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
13767 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
13768 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
13775 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
13776 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
13783 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13784 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13786 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
13788 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13789 && test -z "${cf_tst_cflags}" \
13790 && cf_fix_cppflags=no
13795 if test -n "$cf_new_cflags" ; then
13797 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
13798 CFLAGS="${CFLAGS}$cf_new_cflags"
13802 if test -n "$cf_new_cppflags" ; then
13804 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13805 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
13809 if test -n "$cf_new_extra_cppflags" ; then
13811 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
13812 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
13816 cf_add_libs="$LIBS"
13819 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
13820 # filter duplicates
13821 for cf_add_1lib in $cf_add_0lib; do
13822 for cf_add_2lib in $cf_add_libs; do
13823 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
13828 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
13830 LIBS="$cf_add_libs"
13836 { echo "$as_me:13836: WARNING: unable to find SM library" >&5
13837 echo "$as_me: WARNING: unable to find SM library" >&2;}
13840 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xt; then
13841 test -n "$verbose" && echo " found package xt" 1>&6
13843 echo "${as_me:-configure}:13843: testing found package xt ..." 1>&5
13845 cf_pkgconfig_incs="`$PKG_CONFIG --cflags xt 2>/dev/null`"
13846 cf_pkgconfig_libs="`$PKG_CONFIG --libs xt 2>/dev/null`"
13847 test -n "$verbose" && echo " package xt CFLAGS: $cf_pkgconfig_incs" 1>&6
13849 echo "${as_me:-configure}:13849: testing package xt CFLAGS: $cf_pkgconfig_incs ..." 1>&5
13851 test -n "$verbose" && echo " package xt LIBS: $cf_pkgconfig_libs" 1>&6
13853 echo "${as_me:-configure}:13853: testing package xt LIBS: $cf_pkgconfig_libs ..." 1>&5
13858 cf_new_extra_cppflags=
13860 for cf_add_cflags in $cf_pkgconfig_incs
13862 case $cf_fix_cppflags in
13864 case $cf_add_cflags in
13865 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
13866 case $cf_add_cflags in
13868 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
13870 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13871 && test -z "${cf_tst_cflags}" \
13872 && cf_fix_cppflags=yes
13874 if test $cf_fix_cppflags = yes ; then
13876 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13877 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13880 elif test "${cf_tst_cflags}" = "\"'" ; then
13882 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13883 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13889 case "$CPPFLAGS" in
13893 case $cf_add_cflags in
13895 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
13897 CPPFLAGS=`echo "$CPPFLAGS" | \
13898 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
13899 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
13904 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
13905 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
13912 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
13913 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
13920 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13921 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13923 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
13925 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13926 && test -z "${cf_tst_cflags}" \
13927 && cf_fix_cppflags=no
13932 if test -n "$cf_new_cflags" ; then
13934 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
13935 CFLAGS="${CFLAGS}$cf_new_cflags"
13939 if test -n "$cf_new_cppflags" ; then
13941 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13942 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
13946 if test -n "$cf_new_extra_cppflags" ; then
13948 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
13949 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
13953 cf_add_libs="$LIBS"
13956 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
13957 # filter duplicates
13958 for cf_add_1lib in $cf_add_0lib; do
13959 for cf_add_2lib in $cf_add_libs; do
13960 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
13965 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
13967 LIBS="$cf_add_libs"
13973 { echo "$as_me:13973: WARNING: unable to find Xt library" >&5
13974 echo "$as_me: WARNING: unable to find Xt library" >&2;}
13978 LIBS="$X_PRE_LIBS $LIBS $X_EXTRA_LIBS"
13983 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xt; then
13984 test -n "$verbose" && echo " found package xt" 1>&6
13986 echo "${as_me:-configure}:13986: testing found package xt ..." 1>&5
13988 cf_pkgconfig_incs="`$PKG_CONFIG --cflags xt 2>/dev/null`"
13989 cf_pkgconfig_libs="`$PKG_CONFIG --libs xt 2>/dev/null`"
13990 test -n "$verbose" && echo " package xt CFLAGS: $cf_pkgconfig_incs" 1>&6
13992 echo "${as_me:-configure}:13992: testing package xt CFLAGS: $cf_pkgconfig_incs ..." 1>&5
13994 test -n "$verbose" && echo " package xt LIBS: $cf_pkgconfig_libs" 1>&6
13996 echo "${as_me:-configure}:13996: testing package xt LIBS: $cf_pkgconfig_libs ..." 1>&5
14001 cf_new_extra_cppflags=
14003 for cf_add_cflags in $cf_pkgconfig_incs
14005 case $cf_fix_cppflags in
14007 case $cf_add_cflags in
14008 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
14009 case $cf_add_cflags in
14011 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
14013 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14014 && test -z "${cf_tst_cflags}" \
14015 && cf_fix_cppflags=yes
14017 if test $cf_fix_cppflags = yes ; then
14019 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14020 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14023 elif test "${cf_tst_cflags}" = "\"'" ; then
14025 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14026 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14032 case "$CPPFLAGS" in
14036 case $cf_add_cflags in
14038 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
14040 CPPFLAGS=`echo "$CPPFLAGS" | \
14041 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
14042 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
14047 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
14048 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
14055 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
14056 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
14063 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14064 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14066 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
14068 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14069 && test -z "${cf_tst_cflags}" \
14070 && cf_fix_cppflags=no
14075 if test -n "$cf_new_cflags" ; then
14077 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
14078 CFLAGS="${CFLAGS}$cf_new_cflags"
14082 if test -n "$cf_new_cppflags" ; then
14084 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
14085 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
14089 if test -n "$cf_new_extra_cppflags" ; then
14091 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
14092 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
14096 cf_add_libs="$LIBS"
14099 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
14100 # filter duplicates
14101 for cf_add_1lib in $cf_add_0lib; do
14102 for cf_add_2lib in $cf_add_libs; do
14103 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
14108 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
14110 LIBS="$cf_add_libs"
14116 # we have an "xt" package, but it may omit Xt's dependency on X11
14117 echo "$as_me:14117: checking for usable X dependency" >&5
14118 echo $ECHO_N "checking for usable X dependency... $ECHO_C" >&6
14119 if test "${cf_cv_xt_x11_compat+set}" = set; then
14120 echo $ECHO_N "(cached) $ECHO_C" >&6
14123 cat >conftest.$ac_ext <<_ACEOF
14124 #line 14124 "configure"
14125 #include "confdefs.h"
14127 #include <X11/Xlib.h>
14133 int rc1 = XDrawLine((Display*) 0, (Drawable) 0, (GC) 0, 0, 0, 0, 0);
14134 int rc2 = XClearWindow((Display*) 0, (Window) 0);
14135 int rc3 = XMoveWindow((Display*) 0, (Window) 0, 0, 0);
14136 int rc4 = XMoveResizeWindow((Display*)0, (Window)0, 0, 0, 0, 0);
14142 rm -f conftest.$ac_objext conftest$ac_exeext
14143 if { (eval echo "$as_me:14143: \"$ac_link\"") >&5
14144 (eval $ac_link) 2>&5
14146 echo "$as_me:14146: \$? = $ac_status" >&5
14147 (exit $ac_status); } &&
14148 { ac_try='test -s conftest$ac_exeext'
14149 { (eval echo "$as_me:14149: \"$ac_try\"") >&5
14150 (eval $ac_try) 2>&5
14152 echo "$as_me:14152: \$? = $ac_status" >&5
14153 (exit $ac_status); }; }; then
14154 cf_cv_xt_x11_compat=yes
14156 echo "$as_me: failed program was:" >&5
14157 cat conftest.$ac_ext >&5
14158 cf_cv_xt_x11_compat=no
14160 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14162 echo "$as_me:14162: result: $cf_cv_xt_x11_compat" >&5
14163 echo "${ECHO_T}$cf_cv_xt_x11_compat" >&6
14164 if test "$cf_cv_xt_x11_compat" = no
14166 test -n "$verbose" && echo " work around broken X11 dependency" 1>&6
14168 echo "${as_me:-configure}:14168: testing work around broken X11 dependency ..." 1>&5
14170 # 2010/11/19 - good enough until a working Xt on Xcb is delivered.
14172 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists x11; then
14173 test -n "$verbose" && echo " found package x11" 1>&6
14175 echo "${as_me:-configure}:14175: testing found package x11 ..." 1>&5
14177 cf_pkgconfig_incs="`$PKG_CONFIG --cflags x11 2>/dev/null`"
14178 cf_pkgconfig_libs="`$PKG_CONFIG --libs x11 2>/dev/null`"
14179 test -n "$verbose" && echo " package x11 CFLAGS: $cf_pkgconfig_incs" 1>&6
14181 echo "${as_me:-configure}:14181: testing package x11 CFLAGS: $cf_pkgconfig_incs ..." 1>&5
14183 test -n "$verbose" && echo " package x11 LIBS: $cf_pkgconfig_libs" 1>&6
14185 echo "${as_me:-configure}:14185: testing package x11 LIBS: $cf_pkgconfig_libs ..." 1>&5
14190 cf_new_extra_cppflags=
14192 for cf_add_cflags in $cf_pkgconfig_incs
14194 case $cf_fix_cppflags in
14196 case $cf_add_cflags in
14197 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
14198 case $cf_add_cflags in
14200 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
14202 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14203 && test -z "${cf_tst_cflags}" \
14204 && cf_fix_cppflags=yes
14206 if test $cf_fix_cppflags = yes ; then
14208 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14209 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14212 elif test "${cf_tst_cflags}" = "\"'" ; then
14214 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14215 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14221 case "$CPPFLAGS" in
14225 case $cf_add_cflags in
14227 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
14229 CPPFLAGS=`echo "$CPPFLAGS" | \
14230 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
14231 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
14236 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
14237 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
14244 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
14245 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
14252 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14253 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14255 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
14257 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14258 && test -z "${cf_tst_cflags}" \
14259 && cf_fix_cppflags=no
14264 if test -n "$cf_new_cflags" ; then
14266 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
14267 CFLAGS="${CFLAGS}$cf_new_cflags"
14271 if test -n "$cf_new_cppflags" ; then
14273 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
14274 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
14278 if test -n "$cf_new_extra_cppflags" ; then
14280 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
14281 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
14285 cf_add_libs="$LIBS"
14288 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
14289 # filter duplicates
14290 for cf_add_1lib in $cf_add_0lib; do
14291 for cf_add_2lib in $cf_add_libs; do
14292 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
14297 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
14299 LIBS="$cf_add_libs"
14306 test -n "$verbose" && echo " ...before $LIBS" 1>&6
14308 echo "${as_me:-configure}:14308: testing ...before $LIBS ..." 1>&5
14310 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%-lXt %-lXt -lX11 %" -e 's% % %g'`
14311 test -n "$verbose" && echo " ...after $LIBS" 1>&6
14313 echo "${as_me:-configure}:14313: testing ...after $LIBS ..." 1>&5
14321 echo "$as_me:14321: checking for usable X Toolkit package" >&5
14322 echo $ECHO_N "checking for usable X Toolkit package... $ECHO_C" >&6
14323 if test "${cf_cv_xt_ice_compat+set}" = set; then
14324 echo $ECHO_N "(cached) $ECHO_C" >&6
14327 cat >conftest.$ac_ext <<_ACEOF
14328 #line 14328 "configure"
14329 #include "confdefs.h"
14331 #include <X11/Shell.h>
14336 int num = IceConnectionNumber(0); (void) num
14342 rm -f conftest.$ac_objext conftest$ac_exeext
14343 if { (eval echo "$as_me:14343: \"$ac_link\"") >&5
14344 (eval $ac_link) 2>&5
14346 echo "$as_me:14346: \$? = $ac_status" >&5
14347 (exit $ac_status); } &&
14348 { ac_try='test -s conftest$ac_exeext'
14349 { (eval echo "$as_me:14349: \"$ac_try\"") >&5
14350 (eval $ac_try) 2>&5
14352 echo "$as_me:14352: \$? = $ac_status" >&5
14353 (exit $ac_status); }; }; then
14354 cf_cv_xt_ice_compat=yes
14356 echo "$as_me: failed program was:" >&5
14357 cat conftest.$ac_ext >&5
14358 cf_cv_xt_ice_compat=no
14360 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14362 echo "$as_me:14362: result: $cf_cv_xt_ice_compat" >&5
14363 echo "${ECHO_T}$cf_cv_xt_ice_compat" >&6
14365 if test "$cf_cv_xt_ice_compat" = no
14367 # workaround for broken ".pc" files used for X Toolkit.
14368 case "x$X_PRE_LIBS" in
14374 test -n "$verbose" && echo " work around broken ICE dependency" 1>&6
14376 echo "${as_me:-configure}:14376: testing work around broken ICE dependency ..." 1>&5
14378 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists ice; then
14379 test -n "$verbose" && echo " found package ice" 1>&6
14381 echo "${as_me:-configure}:14381: testing found package ice ..." 1>&5
14383 cf_pkgconfig_incs="`$PKG_CONFIG --cflags ice 2>/dev/null`"
14384 cf_pkgconfig_libs="`$PKG_CONFIG --libs ice 2>/dev/null`"
14385 test -n "$verbose" && echo " package ice CFLAGS: $cf_pkgconfig_incs" 1>&6
14387 echo "${as_me:-configure}:14387: testing package ice CFLAGS: $cf_pkgconfig_incs ..." 1>&5
14389 test -n "$verbose" && echo " package ice LIBS: $cf_pkgconfig_libs" 1>&6
14391 echo "${as_me:-configure}:14391: testing package ice LIBS: $cf_pkgconfig_libs ..." 1>&5
14396 cf_new_extra_cppflags=
14398 for cf_add_cflags in $cf_pkgconfig_incs
14400 case $cf_fix_cppflags in
14402 case $cf_add_cflags in
14403 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
14404 case $cf_add_cflags in
14406 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
14408 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14409 && test -z "${cf_tst_cflags}" \
14410 && cf_fix_cppflags=yes
14412 if test $cf_fix_cppflags = yes ; then
14414 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14415 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14418 elif test "${cf_tst_cflags}" = "\"'" ; then
14420 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14421 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14427 case "$CPPFLAGS" in
14431 case $cf_add_cflags in
14433 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
14435 CPPFLAGS=`echo "$CPPFLAGS" | \
14436 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
14437 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
14442 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
14443 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
14450 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
14451 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
14458 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14459 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14461 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
14463 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14464 && test -z "${cf_tst_cflags}" \
14465 && cf_fix_cppflags=no
14470 if test -n "$cf_new_cflags" ; then
14472 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
14473 CFLAGS="${CFLAGS}$cf_new_cflags"
14477 if test -n "$cf_new_cppflags" ; then
14479 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
14480 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
14484 if test -n "$cf_new_extra_cppflags" ; then
14486 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
14487 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
14491 cf_add_libs="$LIBS"
14494 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
14495 # filter duplicates
14496 for cf_add_1lib in $cf_add_0lib; do
14497 for cf_add_2lib in $cf_add_libs; do
14498 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
14503 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
14505 LIBS="$cf_add_libs"
14507 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists sm; then
14508 test -n "$verbose" && echo " found package sm" 1>&6
14510 echo "${as_me:-configure}:14510: testing found package sm ..." 1>&5
14512 cf_pkgconfig_incs="`$PKG_CONFIG --cflags sm 2>/dev/null`"
14513 cf_pkgconfig_libs="`$PKG_CONFIG --libs sm 2>/dev/null`"
14514 test -n "$verbose" && echo " package sm CFLAGS: $cf_pkgconfig_incs" 1>&6
14516 echo "${as_me:-configure}:14516: testing package sm CFLAGS: $cf_pkgconfig_incs ..." 1>&5
14518 test -n "$verbose" && echo " package sm LIBS: $cf_pkgconfig_libs" 1>&6
14520 echo "${as_me:-configure}:14520: testing package sm LIBS: $cf_pkgconfig_libs ..." 1>&5
14525 cf_new_extra_cppflags=
14527 for cf_add_cflags in $cf_pkgconfig_incs
14529 case $cf_fix_cppflags in
14531 case $cf_add_cflags in
14532 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
14533 case $cf_add_cflags in
14535 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
14537 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14538 && test -z "${cf_tst_cflags}" \
14539 && cf_fix_cppflags=yes
14541 if test $cf_fix_cppflags = yes ; then
14543 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14544 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14547 elif test "${cf_tst_cflags}" = "\"'" ; then
14549 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14550 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14556 case "$CPPFLAGS" in
14560 case $cf_add_cflags in
14562 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
14564 CPPFLAGS=`echo "$CPPFLAGS" | \
14565 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
14566 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
14571 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
14572 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
14579 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
14580 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
14587 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14588 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14590 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
14592 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14593 && test -z "${cf_tst_cflags}" \
14594 && cf_fix_cppflags=no
14599 if test -n "$cf_new_cflags" ; then
14601 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
14602 CFLAGS="${CFLAGS}$cf_new_cflags"
14606 if test -n "$cf_new_cppflags" ; then
14608 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
14609 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
14613 if test -n "$cf_new_extra_cppflags" ; then
14615 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
14616 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
14620 cf_add_libs="$LIBS"
14623 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
14624 # filter duplicates
14625 for cf_add_1lib in $cf_add_0lib; do
14626 for cf_add_2lib in $cf_add_libs; do
14627 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
14632 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
14634 LIBS="$cf_add_libs"
14647 test -n "$verbose" && echo " ...before $LIBS" 1>&6
14649 echo "${as_me:-configure}:14649: testing ...before $LIBS ..." 1>&5
14651 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%-lXt %-lXt $X_PRE_LIBS %" -e 's% % %g'`
14652 test -n "$verbose" && echo " ...after $LIBS" 1>&6
14654 echo "${as_me:-configure}:14654: testing ...after $LIBS ..." 1>&5
14670 LDFLAGS="$X_LIBS $LDFLAGS"
14672 test -n "$verbose" && echo " checking additions to CFLAGS" 1>&6
14674 echo "${as_me:-configure}:14674: testing checking additions to CFLAGS ..." 1>&5
14676 cf_check_cflags="$CFLAGS"
14677 cf_check_cppflags="$CPPFLAGS"
14682 cf_new_extra_cppflags=
14684 for cf_add_cflags in $X_CFLAGS
14686 case $cf_fix_cppflags in
14688 case $cf_add_cflags in
14689 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
14690 case $cf_add_cflags in
14692 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
14694 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14695 && test -z "${cf_tst_cflags}" \
14696 && cf_fix_cppflags=yes
14698 if test $cf_fix_cppflags = yes ; then
14700 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14701 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14704 elif test "${cf_tst_cflags}" = "\"'" ; then
14706 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14707 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14713 case "$CPPFLAGS" in
14717 case $cf_add_cflags in
14719 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
14721 CPPFLAGS=`echo "$CPPFLAGS" | \
14722 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
14723 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
14728 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
14729 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
14736 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
14737 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
14744 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14745 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14747 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
14749 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14750 && test -z "${cf_tst_cflags}" \
14751 && cf_fix_cppflags=no
14756 if test -n "$cf_new_cflags" ; then
14757 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
14759 echo "${as_me:-configure}:14759: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
14761 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
14762 CFLAGS="${CFLAGS}$cf_new_cflags"
14766 if test -n "$cf_new_cppflags" ; then
14767 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
14769 echo "${as_me:-configure}:14769: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
14771 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
14772 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
14776 if test -n "$cf_new_extra_cppflags" ; then
14777 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
14779 echo "${as_me:-configure}:14779: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
14781 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
14782 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
14786 if test "x$cf_check_cflags" != "x$CFLAGS" ; then
14787 cat >conftest.$ac_ext <<_ACEOF
14788 #line 14788 "configure"
14789 #include "confdefs.h"
14794 printf("Hello world");
14799 rm -f conftest.$ac_objext conftest$ac_exeext
14800 if { (eval echo "$as_me:14800: \"$ac_link\"") >&5
14801 (eval $ac_link) 2>&5
14803 echo "$as_me:14803: \$? = $ac_status" >&5
14804 (exit $ac_status); } &&
14805 { ac_try='test -s conftest$ac_exeext'
14806 { (eval echo "$as_me:14806: \"$ac_try\"") >&5
14807 (eval $ac_try) 2>&5
14809 echo "$as_me:14809: \$? = $ac_status" >&5
14810 (exit $ac_status); }; }; then
14813 echo "$as_me: failed program was:" >&5
14814 cat conftest.$ac_ext >&5
14815 test -n "$verbose" && echo " test-compile failed. Undoing change to \$CFLAGS" 1>&6
14817 echo "${as_me:-configure}:14817: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5
14819 if test "x$cf_check_cppflags" != "x$CPPFLAGS" ; then
14820 test -n "$verbose" && echo " but keeping change to \$CPPFLAGS" 1>&6
14822 echo "${as_me:-configure}:14822: testing but keeping change to \$CPPFLAGS ..." 1>&5
14825 CFLAGS="$cf_check_flags"
14827 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14830 echo "$as_me:14830: checking for XOpenDisplay" >&5
14831 echo $ECHO_N "checking for XOpenDisplay... $ECHO_C" >&6
14832 if test "${ac_cv_func_XOpenDisplay+set}" = set; then
14833 echo $ECHO_N "(cached) $ECHO_C" >&6
14835 cat >conftest.$ac_ext <<_ACEOF
14836 #line 14836 "configure"
14837 #include "confdefs.h"
14838 #define XOpenDisplay autoconf_temporary
14839 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
14840 #undef XOpenDisplay
14846 /* We use char because int might match the return type of a gcc2
14847 builtin and then its argument prototype would still apply. */
14848 char XOpenDisplay (void);
14854 /* The GNU C library defines stubs for functions which it implements
14855 to always fail with ENOSYS. Some functions are actually named
14856 something starting with __ and the normal name is an alias. */
14857 #if defined (__stub_XOpenDisplay) || defined (__stub___XOpenDisplay)
14858 #error found stub for XOpenDisplay
14861 return XOpenDisplay ();
14866 rm -f conftest.$ac_objext conftest$ac_exeext
14867 if { (eval echo "$as_me:14867: \"$ac_link\"") >&5
14868 (eval $ac_link) 2>&5
14870 echo "$as_me:14870: \$? = $ac_status" >&5
14871 (exit $ac_status); } &&
14872 { ac_try='test -s conftest$ac_exeext'
14873 { (eval echo "$as_me:14873: \"$ac_try\"") >&5
14874 (eval $ac_try) 2>&5
14876 echo "$as_me:14876: \$? = $ac_status" >&5
14877 (exit $ac_status); }; }; then
14878 ac_cv_func_XOpenDisplay=yes
14880 echo "$as_me: failed program was:" >&5
14881 cat conftest.$ac_ext >&5
14882 ac_cv_func_XOpenDisplay=no
14884 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14886 echo "$as_me:14886: result: $ac_cv_func_XOpenDisplay" >&5
14887 echo "${ECHO_T}$ac_cv_func_XOpenDisplay" >&6
14888 if test $ac_cv_func_XOpenDisplay = yes; then
14892 echo "$as_me:14892: checking for XOpenDisplay in -lX11" >&5
14893 echo $ECHO_N "checking for XOpenDisplay in -lX11... $ECHO_C" >&6
14894 if test "${ac_cv_lib_X11_XOpenDisplay+set}" = set; then
14895 echo $ECHO_N "(cached) $ECHO_C" >&6
14897 ac_check_lib_save_LIBS=$LIBS
14899 cat >conftest.$ac_ext <<_ACEOF
14900 #line 14900 "configure"
14901 #include "confdefs.h"
14903 /* Override any gcc2 internal prototype to avoid an error. */
14907 /* We use char because int might match the return type of a gcc2
14908 builtin and then its argument prototype would still apply. */
14909 char XOpenDisplay ();
14918 rm -f conftest.$ac_objext conftest$ac_exeext
14919 if { (eval echo "$as_me:14919: \"$ac_link\"") >&5
14920 (eval $ac_link) 2>&5
14922 echo "$as_me:14922: \$? = $ac_status" >&5
14923 (exit $ac_status); } &&
14924 { ac_try='test -s conftest$ac_exeext'
14925 { (eval echo "$as_me:14925: \"$ac_try\"") >&5
14926 (eval $ac_try) 2>&5
14928 echo "$as_me:14928: \$? = $ac_status" >&5
14929 (exit $ac_status); }; }; then
14930 ac_cv_lib_X11_XOpenDisplay=yes
14932 echo "$as_me: failed program was:" >&5
14933 cat conftest.$ac_ext >&5
14934 ac_cv_lib_X11_XOpenDisplay=no
14936 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14937 LIBS=$ac_check_lib_save_LIBS
14939 echo "$as_me:14939: result: $ac_cv_lib_X11_XOpenDisplay" >&5
14940 echo "${ECHO_T}$ac_cv_lib_X11_XOpenDisplay" >&6
14941 if test $ac_cv_lib_X11_XOpenDisplay = yes; then
14943 cf_add_libs="$LIBS"
14946 for cf_add_1lib in -lX11; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
14947 # filter duplicates
14948 for cf_add_1lib in $cf_add_0lib; do
14949 for cf_add_2lib in $cf_add_libs; do
14950 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
14955 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
14957 LIBS="$cf_add_libs"
14963 echo "$as_me:14963: checking for XtAppInitialize" >&5
14964 echo $ECHO_N "checking for XtAppInitialize... $ECHO_C" >&6
14965 if test "${ac_cv_func_XtAppInitialize+set}" = set; then
14966 echo $ECHO_N "(cached) $ECHO_C" >&6
14968 cat >conftest.$ac_ext <<_ACEOF
14969 #line 14969 "configure"
14970 #include "confdefs.h"
14971 #define XtAppInitialize autoconf_temporary
14972 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
14973 #undef XtAppInitialize
14979 /* We use char because int might match the return type of a gcc2
14980 builtin and then its argument prototype would still apply. */
14981 char XtAppInitialize (void);
14987 /* The GNU C library defines stubs for functions which it implements
14988 to always fail with ENOSYS. Some functions are actually named
14989 something starting with __ and the normal name is an alias. */
14990 #if defined (__stub_XtAppInitialize) || defined (__stub___XtAppInitialize)
14991 #error found stub for XtAppInitialize
14994 return XtAppInitialize ();
14999 rm -f conftest.$ac_objext conftest$ac_exeext
15000 if { (eval echo "$as_me:15000: \"$ac_link\"") >&5
15001 (eval $ac_link) 2>&5
15003 echo "$as_me:15003: \$? = $ac_status" >&5
15004 (exit $ac_status); } &&
15005 { ac_try='test -s conftest$ac_exeext'
15006 { (eval echo "$as_me:15006: \"$ac_try\"") >&5
15007 (eval $ac_try) 2>&5
15009 echo "$as_me:15009: \$? = $ac_status" >&5
15010 (exit $ac_status); }; }; then
15011 ac_cv_func_XtAppInitialize=yes
15013 echo "$as_me: failed program was:" >&5
15014 cat conftest.$ac_ext >&5
15015 ac_cv_func_XtAppInitialize=no
15017 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15019 echo "$as_me:15019: result: $ac_cv_func_XtAppInitialize" >&5
15020 echo "${ECHO_T}$ac_cv_func_XtAppInitialize" >&6
15021 if test $ac_cv_func_XtAppInitialize = yes; then
15025 echo "$as_me:15025: checking for XtAppInitialize in -lXt" >&5
15026 echo $ECHO_N "checking for XtAppInitialize in -lXt... $ECHO_C" >&6
15027 if test "${ac_cv_lib_Xt_XtAppInitialize+set}" = set; then
15028 echo $ECHO_N "(cached) $ECHO_C" >&6
15030 ac_check_lib_save_LIBS=$LIBS
15032 cat >conftest.$ac_ext <<_ACEOF
15033 #line 15033 "configure"
15034 #include "confdefs.h"
15036 /* Override any gcc2 internal prototype to avoid an error. */
15040 /* We use char because int might match the return type of a gcc2
15041 builtin and then its argument prototype would still apply. */
15042 char XtAppInitialize ();
15046 XtAppInitialize ();
15051 rm -f conftest.$ac_objext conftest$ac_exeext
15052 if { (eval echo "$as_me:15052: \"$ac_link\"") >&5
15053 (eval $ac_link) 2>&5
15055 echo "$as_me:15055: \$? = $ac_status" >&5
15056 (exit $ac_status); } &&
15057 { ac_try='test -s conftest$ac_exeext'
15058 { (eval echo "$as_me:15058: \"$ac_try\"") >&5
15059 (eval $ac_try) 2>&5
15061 echo "$as_me:15061: \$? = $ac_status" >&5
15062 (exit $ac_status); }; }; then
15063 ac_cv_lib_Xt_XtAppInitialize=yes
15065 echo "$as_me: failed program was:" >&5
15066 cat conftest.$ac_ext >&5
15067 ac_cv_lib_Xt_XtAppInitialize=no
15069 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15070 LIBS=$ac_check_lib_save_LIBS
15072 echo "$as_me:15072: result: $ac_cv_lib_Xt_XtAppInitialize" >&5
15073 echo "${ECHO_T}$ac_cv_lib_Xt_XtAppInitialize" >&6
15074 if test $ac_cv_lib_Xt_XtAppInitialize = yes; then
15076 cat >>confdefs.h <<\EOF
15077 #define HAVE_LIBXT 1
15088 if test $cf_have_X_LIBS = no ; then
15089 { echo "$as_me:15089: WARNING: Unable to successfully link X Toolkit library (-lXt) with
15090 test program. You will have to check and add the proper libraries by hand
15092 echo "$as_me: WARNING: Unable to successfully link X Toolkit library (-lXt) with
15093 test program. You will have to check and add the proper libraries by hand
15094 to makefile." >&2;}
15097 cf_x_athena_root=$cf_x_athena
15100 for cf_path in default \
15101 /usr/contrib/X11R6 \
15102 /usr/contrib/X11R5 \
15106 if test -z "$cf_x_athena_inc" ; then
15108 cf_save_LIBS_CF_X_ATHENA_CPPFLAGS="$LIBS"
15109 cf_save_CFLAGS_CF_X_ATHENA_CPPFLAGS="$CFLAGS"
15110 cf_save_CPPFLAGS_CF_X_ATHENA_CPPFLAGS="$CPPFLAGS"
15111 LIBS="$LIBS ${X_PRE_LIBS} ${X_LIBS} ${X_EXTRA_LIBS}"
15112 for cf_X_CFLAGS in $X_CFLAGS
15114 case "x$cf_X_CFLAGS" in
15116 CPPFLAGS="$CPPFLAGS $cf_X_CFLAGS"
15119 CFLAGS="$CFLAGS $cf_X_CFLAGS"
15124 cf_test=X11/$cf_x_athena_root/SimpleMenu.h
15125 if test $cf_path != default ; then
15127 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
15128 CPPFLAGS="${CPPFLAGS}-I$cf_path/include"
15130 echo "$as_me:15130: checking for $cf_test in $cf_path" >&5
15131 echo $ECHO_N "checking for $cf_test in $cf_path... $ECHO_C" >&6
15133 echo "$as_me:15133: checking for $cf_test" >&5
15134 echo $ECHO_N "checking for $cf_test... $ECHO_C" >&6
15136 cat >conftest.$ac_ext <<_ACEOF
15137 #line 15137 "configure"
15138 #include "confdefs.h"
15140 #include <X11/Intrinsic.h>
15141 #include <$cf_test>
15150 rm -f conftest.$ac_objext
15151 if { (eval echo "$as_me:15151: \"$ac_compile\"") >&5
15152 (eval $ac_compile) 2>&5
15154 echo "$as_me:15154: \$? = $ac_status" >&5
15155 (exit $ac_status); } &&
15156 { ac_try='test -s conftest.$ac_objext'
15157 { (eval echo "$as_me:15157: \"$ac_try\"") >&5
15158 (eval $ac_try) 2>&5
15160 echo "$as_me:15160: \$? = $ac_status" >&5
15161 (exit $ac_status); }; }; then
15164 echo "$as_me: failed program was:" >&5
15165 cat conftest.$ac_ext >&5
15168 rm -f conftest.$ac_objext conftest.$ac_ext
15169 echo "$as_me:15169: result: $cf_result" >&5
15170 echo "${ECHO_T}$cf_result" >&6
15172 LIBS="$cf_save_LIBS_CF_X_ATHENA_CPPFLAGS"
15173 CFLAGS="$cf_save_CFLAGS_CF_X_ATHENA_CPPFLAGS"
15174 CPPFLAGS="$cf_save_CPPFLAGS_CF_X_ATHENA_CPPFLAGS"
15176 if test "$cf_result" = yes ; then
15177 test "$cf_path" = default && cf_x_athena_inc=default
15178 test "$cf_path" != default && cf_x_athena_inc=$cf_path/include
15184 if test -z "$cf_x_athena_inc" ; then
15185 { echo "$as_me:15185: WARNING: Unable to find Athena header files" >&5
15186 echo "$as_me: WARNING: Unable to find Athena header files" >&2;}
15187 elif test "$cf_x_athena_inc" != default ; then
15189 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
15190 CPPFLAGS="${CPPFLAGS}-I$cf_x_athena_inc"
15194 cf_x_athena_root=$cf_x_athena
15197 for cf_path in default \
15198 /usr/contrib/X11R6 \
15199 /usr/contrib/X11R5 \
15204 ${cf_x_athena_root} \
15205 ${cf_x_athena_root}7 \
15206 ${cf_x_athena_root}6
15209 "-l$cf_lib -lXmu" \
15210 "-l$cf_lib -lXpm -lXmu" \
15211 "-l${cf_lib}_s -lXmu_s"
15213 test -n "$cf_x_athena_lib" && break
15215 cf_save_LIBS_CF_X_ATHENA_LIBS="$LIBS"
15216 cf_save_CFLAGS_CF_X_ATHENA_LIBS="$CFLAGS"
15217 cf_save_CPPFLAGS_CF_X_ATHENA_LIBS="$CPPFLAGS"
15218 LIBS="$LIBS ${X_PRE_LIBS} ${X_LIBS} ${X_EXTRA_LIBS}"
15219 for cf_X_CFLAGS in $X_CFLAGS
15221 case "x$cf_X_CFLAGS" in
15223 CPPFLAGS="$CPPFLAGS $cf_X_CFLAGS"
15226 CFLAGS="$CFLAGS $cf_X_CFLAGS"
15231 cf_test=XawSimpleMenuAddGlobalActions
15232 test "$cf_path" != default && cf_libs="-L$cf_path/lib $cf_libs"
15234 cf_add_libs="$LIBS"
15237 for cf_add_1lib in $cf_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
15238 # filter duplicates
15239 for cf_add_1lib in $cf_add_0lib; do
15240 for cf_add_2lib in $cf_add_libs; do
15241 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
15246 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
15248 LIBS="$cf_add_libs"
15250 echo "$as_me:15250: checking for $cf_test in $cf_libs" >&5
15251 echo $ECHO_N "checking for $cf_test in $cf_libs... $ECHO_C" >&6
15252 cat >conftest.$ac_ext <<_ACEOF
15253 #line 15253 "configure"
15254 #include "confdefs.h"
15256 #include <X11/Intrinsic.h>
15257 #include <X11/$cf_x_athena_root/SimpleMenu.h>
15263 $cf_test((XtAppContext) 0)
15268 rm -f conftest.$ac_objext conftest$ac_exeext
15269 if { (eval echo "$as_me:15269: \"$ac_link\"") >&5
15270 (eval $ac_link) 2>&5
15272 echo "$as_me:15272: \$? = $ac_status" >&5
15273 (exit $ac_status); } &&
15274 { ac_try='test -s conftest$ac_exeext'
15275 { (eval echo "$as_me:15275: \"$ac_try\"") >&5
15276 (eval $ac_try) 2>&5
15278 echo "$as_me:15278: \$? = $ac_status" >&5
15279 (exit $ac_status); }; }; then
15282 echo "$as_me: failed program was:" >&5
15283 cat conftest.$ac_ext >&5
15286 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15287 echo "$as_me:15287: result: $cf_result" >&5
15288 echo "${ECHO_T}$cf_result" >&6
15290 LIBS="$cf_save_LIBS_CF_X_ATHENA_LIBS"
15291 CFLAGS="$cf_save_CFLAGS_CF_X_ATHENA_LIBS"
15292 CPPFLAGS="$cf_save_CPPFLAGS_CF_X_ATHENA_LIBS"
15294 if test "$cf_result" = yes ; then
15295 cf_x_athena_lib="$cf_libs"
15299 test -n "$cf_x_athena_lib" && break
15303 if test -z "$cf_x_athena_lib" ; then
15304 { { echo "$as_me:15304: error: Unable to successfully link Athena library (-l$cf_x_athena_root) with test program" >&5
15305 echo "$as_me: error: Unable to successfully link Athena library (-l$cf_x_athena_root) with test program" >&2;}
15306 { (exit 1); exit 1; }; }
15309 cf_add_libs="$LIBS"
15312 for cf_add_1lib in $cf_x_athena_lib; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
15313 # filter duplicates
15314 for cf_add_1lib in $cf_add_0lib; do
15315 for cf_add_2lib in $cf_add_libs; do
15316 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
15321 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
15323 LIBS="$cf_add_libs"
15325 cf_x_athena_LIBS=`echo "HAVE_LIB_$cf_x_athena" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
15327 cat >>confdefs.h <<EOF
15328 #define $cf_x_athena_LIBS 1
15333 if test -n "$ac_tool_prefix"; then
15334 for ac_prog in xcurses-config
15336 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
15337 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
15338 echo "$as_me:15338: checking for $ac_word" >&5
15339 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
15340 if test "${ac_cv_prog_XCURSES_CONFIG+set}" = set; then
15341 echo $ECHO_N "(cached) $ECHO_C" >&6
15343 if test -n "$XCURSES_CONFIG"; then
15344 ac_cv_prog_XCURSES_CONFIG="$XCURSES_CONFIG" # Let the user override the test.
15346 ac_save_IFS=$IFS; IFS=$ac_path_separator
15348 for ac_dir in $ac_dummy; do
15350 test -z "$ac_dir" && ac_dir=.
15351 $as_executable_p "$ac_dir/$ac_word" || continue
15352 ac_cv_prog_XCURSES_CONFIG="$ac_tool_prefix$ac_prog"
15353 echo "$as_me:15353: found $ac_dir/$ac_word" >&5
15359 XCURSES_CONFIG=$ac_cv_prog_XCURSES_CONFIG
15360 if test -n "$XCURSES_CONFIG"; then
15361 echo "$as_me:15361: result: $XCURSES_CONFIG" >&5
15362 echo "${ECHO_T}$XCURSES_CONFIG" >&6
15364 echo "$as_me:15364: result: no" >&5
15365 echo "${ECHO_T}no" >&6
15368 test -n "$XCURSES_CONFIG" && break
15371 if test -z "$XCURSES_CONFIG"; then
15372 ac_ct_XCURSES_CONFIG=$XCURSES_CONFIG
15373 for ac_prog in xcurses-config
15375 # Extract the first word of "$ac_prog", so it can be a program name with args.
15376 set dummy $ac_prog; ac_word=$2
15377 echo "$as_me:15377: checking for $ac_word" >&5
15378 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
15379 if test "${ac_cv_prog_ac_ct_XCURSES_CONFIG+set}" = set; then
15380 echo $ECHO_N "(cached) $ECHO_C" >&6
15382 if test -n "$ac_ct_XCURSES_CONFIG"; then
15383 ac_cv_prog_ac_ct_XCURSES_CONFIG="$ac_ct_XCURSES_CONFIG" # Let the user override the test.
15385 ac_save_IFS=$IFS; IFS=$ac_path_separator
15387 for ac_dir in $ac_dummy; do
15389 test -z "$ac_dir" && ac_dir=.
15390 $as_executable_p "$ac_dir/$ac_word" || continue
15391 ac_cv_prog_ac_ct_XCURSES_CONFIG="$ac_prog"
15392 echo "$as_me:15392: found $ac_dir/$ac_word" >&5
15398 ac_ct_XCURSES_CONFIG=$ac_cv_prog_ac_ct_XCURSES_CONFIG
15399 if test -n "$ac_ct_XCURSES_CONFIG"; then
15400 echo "$as_me:15400: result: $ac_ct_XCURSES_CONFIG" >&5
15401 echo "${ECHO_T}$ac_ct_XCURSES_CONFIG" >&6
15403 echo "$as_me:15403: result: no" >&5
15404 echo "${ECHO_T}no" >&6
15407 test -n "$ac_ct_XCURSES_CONFIG" && break
15409 test -n "$ac_ct_XCURSES_CONFIG" || ac_ct_XCURSES_CONFIG="none"
15411 XCURSES_CONFIG=$ac_ct_XCURSES_CONFIG
15414 if test "$XCURSES_CONFIG" != none ; then
15419 cf_new_extra_cppflags=
15421 for cf_add_cflags in `$XCURSES_CONFIG --cflags`
15423 case $cf_fix_cppflags in
15425 case $cf_add_cflags in
15426 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
15427 case $cf_add_cflags in
15429 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
15431 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15432 && test -z "${cf_tst_cflags}" \
15433 && cf_fix_cppflags=yes
15435 if test $cf_fix_cppflags = yes ; then
15437 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15438 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15441 elif test "${cf_tst_cflags}" = "\"'" ; then
15443 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15444 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15450 case "$CPPFLAGS" in
15454 case $cf_add_cflags in
15456 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
15458 CPPFLAGS=`echo "$CPPFLAGS" | \
15459 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
15460 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
15465 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
15466 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
15473 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
15474 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
15481 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15482 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15484 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
15486 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15487 && test -z "${cf_tst_cflags}" \
15488 && cf_fix_cppflags=no
15493 if test -n "$cf_new_cflags" ; then
15495 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
15496 CFLAGS="${CFLAGS}$cf_new_cflags"
15500 if test -n "$cf_new_cppflags" ; then
15502 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
15503 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
15507 if test -n "$cf_new_extra_cppflags" ; then
15509 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
15510 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
15514 cf_add_libs="$LIBS"
15517 for cf_add_1lib in `$XCURSES_CONFIG --libs`; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
15518 # filter duplicates
15519 for cf_add_1lib in $cf_add_0lib; do
15520 for cf_add_2lib in $cf_add_libs; do
15521 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
15526 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
15528 LIBS="$cf_add_libs"
15530 cf_cv_lib_XCurses=yes
15534 LDFLAGS="$LDFLAGS $X_LIBS"
15536 test -n "$verbose" && echo " checking additions to CFLAGS" 1>&6
15538 echo "${as_me:-configure}:15538: testing checking additions to CFLAGS ..." 1>&5
15540 cf_check_cflags="$CFLAGS"
15541 cf_check_cppflags="$CPPFLAGS"
15546 cf_new_extra_cppflags=
15548 for cf_add_cflags in $X_CFLAGS
15550 case $cf_fix_cppflags in
15552 case $cf_add_cflags in
15553 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
15554 case $cf_add_cflags in
15556 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
15558 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15559 && test -z "${cf_tst_cflags}" \
15560 && cf_fix_cppflags=yes
15562 if test $cf_fix_cppflags = yes ; then
15564 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15565 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15568 elif test "${cf_tst_cflags}" = "\"'" ; then
15570 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15571 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15577 case "$CPPFLAGS" in
15581 case $cf_add_cflags in
15583 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
15585 CPPFLAGS=`echo "$CPPFLAGS" | \
15586 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
15587 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
15592 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
15593 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
15600 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
15601 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
15608 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15609 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15611 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
15613 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15614 && test -z "${cf_tst_cflags}" \
15615 && cf_fix_cppflags=no
15620 if test -n "$cf_new_cflags" ; then
15621 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
15623 echo "${as_me:-configure}:15623: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
15625 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
15626 CFLAGS="${CFLAGS}$cf_new_cflags"
15630 if test -n "$cf_new_cppflags" ; then
15631 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
15633 echo "${as_me:-configure}:15633: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
15635 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
15636 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
15640 if test -n "$cf_new_extra_cppflags" ; then
15641 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
15643 echo "${as_me:-configure}:15643: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
15645 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
15646 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
15650 if test "x$cf_check_cflags" != "x$CFLAGS" ; then
15651 cat >conftest.$ac_ext <<_ACEOF
15652 #line 15652 "configure"
15653 #include "confdefs.h"
15658 printf("Hello world");
15663 rm -f conftest.$ac_objext conftest$ac_exeext
15664 if { (eval echo "$as_me:15664: \"$ac_link\"") >&5
15665 (eval $ac_link) 2>&5
15667 echo "$as_me:15667: \$? = $ac_status" >&5
15668 (exit $ac_status); } &&
15669 { ac_try='test -s conftest$ac_exeext'
15670 { (eval echo "$as_me:15670: \"$ac_try\"") >&5
15671 (eval $ac_try) 2>&5
15673 echo "$as_me:15673: \$? = $ac_status" >&5
15674 (exit $ac_status); }; }; then
15677 echo "$as_me: failed program was:" >&5
15678 cat conftest.$ac_ext >&5
15679 test -n "$verbose" && echo " test-compile failed. Undoing change to \$CFLAGS" 1>&6
15681 echo "${as_me:-configure}:15681: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5
15683 if test "x$cf_check_cppflags" != "x$CPPFLAGS" ; then
15684 test -n "$verbose" && echo " but keeping change to \$CPPFLAGS" 1>&6
15686 echo "${as_me:-configure}:15686: testing but keeping change to \$CPPFLAGS ..." 1>&5
15689 CFLAGS="$cf_check_flags"
15691 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15694 echo "$as_me:15694: checking for XOpenDisplay in -lX11" >&5
15695 echo $ECHO_N "checking for XOpenDisplay in -lX11... $ECHO_C" >&6
15696 if test "${ac_cv_lib_X11_XOpenDisplay+set}" = set; then
15697 echo $ECHO_N "(cached) $ECHO_C" >&6
15699 ac_check_lib_save_LIBS=$LIBS
15700 LIBS="-lX11 $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
15701 cat >conftest.$ac_ext <<_ACEOF
15702 #line 15702 "configure"
15703 #include "confdefs.h"
15705 /* Override any gcc2 internal prototype to avoid an error. */
15709 /* We use char because int might match the return type of a gcc2
15710 builtin and then its argument prototype would still apply. */
15711 char XOpenDisplay ();
15720 rm -f conftest.$ac_objext conftest$ac_exeext
15721 if { (eval echo "$as_me:15721: \"$ac_link\"") >&5
15722 (eval $ac_link) 2>&5
15724 echo "$as_me:15724: \$? = $ac_status" >&5
15725 (exit $ac_status); } &&
15726 { ac_try='test -s conftest$ac_exeext'
15727 { (eval echo "$as_me:15727: \"$ac_try\"") >&5
15728 (eval $ac_try) 2>&5
15730 echo "$as_me:15730: \$? = $ac_status" >&5
15731 (exit $ac_status); }; }; then
15732 ac_cv_lib_X11_XOpenDisplay=yes
15734 echo "$as_me: failed program was:" >&5
15735 cat conftest.$ac_ext >&5
15736 ac_cv_lib_X11_XOpenDisplay=no
15738 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15739 LIBS=$ac_check_lib_save_LIBS
15741 echo "$as_me:15741: result: $ac_cv_lib_X11_XOpenDisplay" >&5
15742 echo "${ECHO_T}$ac_cv_lib_X11_XOpenDisplay" >&6
15743 if test $ac_cv_lib_X11_XOpenDisplay = yes; then
15745 cf_add_libs="$LIBS"
15748 for cf_add_1lib in -lX11; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
15749 # filter duplicates
15750 for cf_add_1lib in $cf_add_0lib; do
15751 for cf_add_2lib in $cf_add_libs; do
15752 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
15757 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
15759 LIBS="$cf_add_libs"
15763 echo "$as_me:15763: checking for XCurses library" >&5
15764 echo $ECHO_N "checking for XCurses library... $ECHO_C" >&6
15765 if test "${cf_cv_lib_XCurses+set}" = set; then
15766 echo $ECHO_N "(cached) $ECHO_C" >&6
15769 cf_add_libs="$LIBS"
15772 for cf_add_1lib in -lXCurses; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
15773 # filter duplicates
15774 for cf_add_1lib in $cf_add_0lib; do
15775 for cf_add_2lib in $cf_add_libs; do
15776 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
15781 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
15783 LIBS="$cf_add_libs"
15785 cat >conftest.$ac_ext <<_ACEOF
15786 #line 15786 "configure"
15787 #include "confdefs.h"
15789 #include <xcurses.h>
15790 char *XCursesProgramName = "test";
15800 rm -f conftest.$ac_objext conftest$ac_exeext
15801 if { (eval echo "$as_me:15801: \"$ac_link\"") >&5
15802 (eval $ac_link) 2>&5
15804 echo "$as_me:15804: \$? = $ac_status" >&5
15805 (exit $ac_status); } &&
15806 { ac_try='test -s conftest$ac_exeext'
15807 { (eval echo "$as_me:15807: \"$ac_try\"") >&5
15808 (eval $ac_try) 2>&5
15810 echo "$as_me:15810: \$? = $ac_status" >&5
15811 (exit $ac_status); }; }; then
15812 cf_cv_lib_XCurses=yes
15814 echo "$as_me: failed program was:" >&5
15815 cat conftest.$ac_ext >&5
15816 cf_cv_lib_XCurses=no
15818 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15821 echo "$as_me:15821: result: $cf_cv_lib_XCurses" >&5
15822 echo "${ECHO_T}$cf_cv_lib_XCurses" >&6
15826 if test $cf_cv_lib_XCurses = yes ; then
15828 cat >>confdefs.h <<\EOF
15832 cat >>confdefs.h <<\EOF
15836 echo "$as_me:15836: checking for xcurses.h" >&5
15837 echo $ECHO_N "checking for xcurses.h... $ECHO_C" >&6
15838 if test "${ac_cv_header_xcurses_h+set}" = set; then
15839 echo $ECHO_N "(cached) $ECHO_C" >&6
15841 cat >conftest.$ac_ext <<_ACEOF
15842 #line 15842 "configure"
15843 #include "confdefs.h"
15844 #include <xcurses.h>
15846 if { (eval echo "$as_me:15846: \"$ac_cpp conftest.$ac_ext\"") >&5
15847 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15849 egrep -v '^ *\+' conftest.er1 >conftest.err
15851 cat conftest.err >&5
15852 echo "$as_me:15852: \$? = $ac_status" >&5
15853 (exit $ac_status); } >/dev/null; then
15854 if test -s conftest.err; then
15855 ac_cpp_err=$ac_c_preproc_warn_flag
15862 if test -z "$ac_cpp_err"; then
15863 ac_cv_header_xcurses_h=yes
15865 echo "$as_me: failed program was:" >&5
15866 cat conftest.$ac_ext >&5
15867 ac_cv_header_xcurses_h=no
15869 rm -f conftest.err conftest.$ac_ext
15871 echo "$as_me:15871: result: $ac_cv_header_xcurses_h" >&5
15872 echo "${ECHO_T}$ac_cv_header_xcurses_h" >&6
15873 if test $ac_cv_header_xcurses_h = yes; then
15875 cat >>confdefs.h <<\EOF
15876 #define HAVE_XCURSES 1
15882 { { echo "$as_me:15882: error: Cannot link with XCurses" >&5
15883 echo "$as_me: error: Cannot link with XCurses" >&2;}
15884 { (exit 1); exit 1; }; }
15889 { { echo "$as_me:15889: error: unexpected screen-value: $cf_cv_screen" >&5
15890 echo "$as_me: error: unexpected screen-value: $cf_cv_screen" >&2;}
15891 { (exit 1); exit 1; }; }
15895 : ${cf_nculib_root:=$cf_cv_screen}
15896 as_ac_Lib=`echo "ac_cv_lib_$cf_nculib_root''__nc_init_pthreads" | $as_tr_sh`
15897 echo "$as_me:15897: checking for _nc_init_pthreads in -l$cf_nculib_root" >&5
15898 echo $ECHO_N "checking for _nc_init_pthreads in -l$cf_nculib_root... $ECHO_C" >&6
15899 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
15900 echo $ECHO_N "(cached) $ECHO_C" >&6
15902 ac_check_lib_save_LIBS=$LIBS
15903 LIBS="-l$cf_nculib_root $LIBS"
15904 cat >conftest.$ac_ext <<_ACEOF
15905 #line 15905 "configure"
15906 #include "confdefs.h"
15908 /* Override any gcc2 internal prototype to avoid an error. */
15912 /* We use char because int might match the return type of a gcc2
15913 builtin and then its argument prototype would still apply. */
15914 char _nc_init_pthreads ();
15918 _nc_init_pthreads ();
15923 rm -f conftest.$ac_objext conftest$ac_exeext
15924 if { (eval echo "$as_me:15924: \"$ac_link\"") >&5
15925 (eval $ac_link) 2>&5
15927 echo "$as_me:15927: \$? = $ac_status" >&5
15928 (exit $ac_status); } &&
15929 { ac_try='test -s conftest$ac_exeext'
15930 { (eval echo "$as_me:15930: \"$ac_try\"") >&5
15931 (eval $ac_try) 2>&5
15933 echo "$as_me:15933: \$? = $ac_status" >&5
15934 (exit $ac_status); }; }; then
15935 eval "$as_ac_Lib=yes"
15937 echo "$as_me: failed program was:" >&5
15938 cat conftest.$ac_ext >&5
15939 eval "$as_ac_Lib=no"
15941 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15942 LIBS=$ac_check_lib_save_LIBS
15944 echo "$as_me:15944: result: `eval echo '${'$as_ac_Lib'}'`" >&5
15945 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
15946 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
15947 cf_cv_ncurses_pthreads=yes
15949 cf_cv_ncurses_pthreads=no
15952 if test "$cf_cv_ncurses_pthreads" = yes
15955 cf_add_libs="$LIBS"
15958 for cf_add_1lib in -lpthread; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
15959 # filter duplicates
15960 for cf_add_1lib in $cf_add_0lib; do
15961 for cf_add_2lib in $cf_add_libs; do
15962 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
15967 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
15969 LIBS="$cf_add_libs"
15973 case $cf_cv_screen in
15975 cf_cv_libtype=`echo "$cf_cv_screen" | sed -e 's/^ncurses//'`
15979 echo "$as_me:15979: checking for X11 rgb file" >&5
15980 echo $ECHO_N "checking for X11 rgb file... $ECHO_C" >&6
15982 # Check whether --with-x11-rgb or --without-x11-rgb was given.
15983 if test "${with_x11_rgb+set}" = set; then
15984 withval="$with_x11_rgb"
15990 if test "x$RGB_PATH" = xauto
15992 RGB_PATH='${exec_prefix}/lib/X11/rgb.txt'
15994 /opt/local/share/X11/rgb.txt \
15995 /opt/X11/share/X11/rgb.txt \
15996 /usr/share/X11/rgb.txt \
15997 /usr/X11/share/X11/rgb.txt \
15998 /usr/X11/lib/X11/rgb.txt \
15999 /usr/lib/X11/rgb.txt \
16001 /usr/pkg/lib/X11/rgb.txt \
16002 /usr/X11R7/lib/X11/rgb.txt \
16003 /usr/X11R6/lib/X11/rgb.txt \
16004 /usr/X11R5/lib/X11/rgb.txt \
16005 /usr/X11R4/lib/X11/rgb.txt \
16006 /usr/local/lib/X11/rgb.txt \
16007 /usr/local/share/X11/rgb.txt \
16008 /usr/lib64/X11/rgb.txt
16010 if test -f "$cf_path" ; then
16011 RGB_PATH="$cf_path"
16018 if test "x$prefix" != xNONE; then
16019 cf_path_syntax="$prefix"
16021 cf_path_syntax="$ac_default_prefix"
16024 case ".$cf_path" in
16025 (.\$\(*\)*|.\'*\'*)
16029 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
16031 (.\${*prefix}*|.\${*dir}*)
16032 eval cf_path="$cf_path"
16033 case ".$cf_path" in
16035 cf_path=`echo $cf_path | sed -e s%NONE%$cf_path_syntax%`
16040 cf_path=`echo $cf_path | sed -e s%NONE%$cf_path_syntax%`
16043 { { echo "$as_me:16043: error: expected a pathname, not \"$cf_path\"" >&5
16044 echo "$as_me: error: expected a pathname, not \"$cf_path\"" >&2;}
16045 { (exit 1); exit 1; }; }
16051 echo "$as_me:16051: result: $RGB_PATH" >&5
16052 echo "${ECHO_T}$RGB_PATH" >&6
16054 cat >>confdefs.h <<EOF
16055 #define RGB_PATH "$cf_path"
16059 if test "$RGB_PATH" = no
16066 case $cf_cv_screen in
16068 cf_default_panel=no
16071 cf_default_tinfo=no
16073 (xcurses|bsdcurses)
16074 cf_default_panel=no
16077 cf_default_tinfo=yes
16080 cf_default_panel=yes
16081 cf_default_form=yes
16082 cf_default_menu=yes
16083 cf_default_tinfo=yes
16084 case $cf_cv_screen in
16086 cf_curses_headers="nc_alloc.h nomacros.h term_entry.h"
16092 echo "$as_me:16092: checking for desired basename for form library" >&5
16093 echo $ECHO_N "checking for desired basename for form library... $ECHO_C" >&6
16095 # Check whether --with-form-libname or --without-form-libname was given.
16096 if test "${with_form_libname+set}" = set; then
16097 withval="$with_form_libname"
16098 with_lib_basename=$withval
16100 with_lib_basename=form
16102 FORM_NAME="$with_lib_basename"
16104 case "x$FORM_NAME" in
16112 echo "$as_me:16112: result: $FORM_NAME" >&5
16113 echo "${ECHO_T}$FORM_NAME" >&6
16115 echo "$as_me:16115: checking for desired basename for menu library" >&5
16116 echo $ECHO_N "checking for desired basename for menu library... $ECHO_C" >&6
16118 # Check whether --with-menu-libname or --without-menu-libname was given.
16119 if test "${with_menu_libname+set}" = set; then
16120 withval="$with_menu_libname"
16121 with_lib_basename=$withval
16123 with_lib_basename=menu
16125 MENU_NAME="$with_lib_basename"
16127 case "x$MENU_NAME" in
16135 echo "$as_me:16135: result: $MENU_NAME" >&5
16136 echo "${ECHO_T}$MENU_NAME" >&6
16138 echo "$as_me:16138: checking for desired basename for panel library" >&5
16139 echo $ECHO_N "checking for desired basename for panel library... $ECHO_C" >&6
16141 # Check whether --with-panel-libname or --without-panel-libname was given.
16142 if test "${with_panel_libname+set}" = set; then
16143 withval="$with_panel_libname"
16144 with_lib_basename=$withval
16146 with_lib_basename=panel
16148 PANEL_NAME="$with_lib_basename"
16150 case "x$PANEL_NAME" in
16158 echo "$as_me:16158: result: $PANEL_NAME" >&5
16159 echo "${ECHO_T}$PANEL_NAME" >&6
16161 echo "$as_me:16161: checking if you want to check for panel functions" >&5
16162 echo $ECHO_N "checking if you want to check for panel functions... $ECHO_C" >&6
16164 # Check whether --enable-panel or --disable-panel was given.
16165 if test "${enable_panel+set}" = set; then
16166 enableval="$enable_panel"
16167 test "$enableval" != no && enableval=yes
16168 if test "$enableval" != "yes" ; then
16171 cf_enable_panel=$cf_default_panel
16175 cf_enable_panel=$cf_default_panel
16178 echo "$as_me:16178: result: $cf_enable_panel" >&5
16179 echo "${ECHO_T}$cf_enable_panel" >&6
16180 if test $cf_enable_panel = yes
16183 cf_have_curses_lib=no
16185 : ${NCURSES_CONFIG_PKG:=none}
16186 if test "x${NCURSES_CONFIG_PKG}" = xnone; then
16188 elif test "x${PKG_CONFIG:=none}" != xnone; then
16189 echo "$as_me:16189: checking pkg-config for $PANEL_NAME$cf_cv_libtype" >&5
16190 echo $ECHO_N "checking pkg-config for $PANEL_NAME$cf_cv_libtype... $ECHO_C" >&6
16191 if "$PKG_CONFIG" --exists $PANEL_NAME$cf_cv_libtype ; then
16192 echo "$as_me:16192: result: yes" >&5
16193 echo "${ECHO_T}yes" >&6
16195 echo "$as_me:16195: checking if the $PANEL_NAME$cf_cv_libtype package files work" >&5
16196 echo $ECHO_N "checking if the $PANEL_NAME$cf_cv_libtype package files work... $ECHO_C" >&6
16198 cf_save_CPPFLAGS="$CPPFLAGS"
16199 cf_save_LIBS="$LIBS"
16204 cf_new_extra_cppflags=
16206 for cf_add_cflags in `$PKG_CONFIG --cflags $PANEL_NAME$cf_cv_libtype`
16208 case $cf_fix_cppflags in
16210 case $cf_add_cflags in
16211 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
16212 case $cf_add_cflags in
16214 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
16216 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
16217 && test -z "${cf_tst_cflags}" \
16218 && cf_fix_cppflags=yes
16220 if test $cf_fix_cppflags = yes ; then
16222 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
16223 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
16226 elif test "${cf_tst_cflags}" = "\"'" ; then
16228 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
16229 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
16235 case "$CPPFLAGS" in
16239 case $cf_add_cflags in
16241 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
16243 CPPFLAGS=`echo "$CPPFLAGS" | \
16244 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
16245 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
16250 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
16251 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
16258 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
16259 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
16266 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
16267 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
16269 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
16271 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
16272 && test -z "${cf_tst_cflags}" \
16273 && cf_fix_cppflags=no
16278 if test -n "$cf_new_cflags" ; then
16280 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
16281 CFLAGS="${CFLAGS}$cf_new_cflags"
16285 if test -n "$cf_new_cppflags" ; then
16287 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
16288 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
16292 if test -n "$cf_new_extra_cppflags" ; then
16294 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
16295 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
16299 cf_add_libs="$LIBS"
16302 for cf_add_1lib in `$PKG_CONFIG --libs $PANEL_NAME$cf_cv_libtype`; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
16303 # filter duplicates
16304 for cf_add_1lib in $cf_add_0lib; do
16305 for cf_add_2lib in $cf_add_libs; do
16306 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
16311 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
16313 LIBS="$cf_add_libs"
16315 cat >conftest.$ac_ext <<_ACEOF
16316 #line 16316 "configure"
16317 #include "confdefs.h"
16318 #include <$PANEL_NAME.h>
16322 (void) new_panel ( 0 );
16327 rm -f conftest.$ac_objext conftest$ac_exeext
16328 if { (eval echo "$as_me:16328: \"$ac_link\"") >&5
16329 (eval $ac_link) 2>&5
16331 echo "$as_me:16331: \$? = $ac_status" >&5
16332 (exit $ac_status); } &&
16333 { ac_try='test -s conftest$ac_exeext'
16334 { (eval echo "$as_me:16334: \"$ac_try\"") >&5
16335 (eval $ac_try) 2>&5
16337 echo "$as_me:16337: \$? = $ac_status" >&5
16338 (exit $ac_status); }; }; then
16339 if test "$cross_compiling" = yes; then
16340 cf_have_curses_lib=maybe
16342 cat >conftest.$ac_ext <<_ACEOF
16343 #line 16343 "configure"
16344 #include "confdefs.h"
16345 #include <$PANEL_NAME.h>
16347 { (void) new_panel ( 0 ); return 0; }
16349 rm -f conftest$ac_exeext
16350 if { (eval echo "$as_me:16350: \"$ac_link\"") >&5
16351 (eval $ac_link) 2>&5
16353 echo "$as_me:16353: \$? = $ac_status" >&5
16354 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16355 { (eval echo "$as_me:16355: \"$ac_try\"") >&5
16356 (eval $ac_try) 2>&5
16358 echo "$as_me:16358: \$? = $ac_status" >&5
16359 (exit $ac_status); }; }; then
16360 cf_have_curses_lib=yes
16362 echo "$as_me: program exited with status $ac_status" >&5
16363 echo "$as_me: failed program was:" >&5
16364 cat conftest.$ac_ext >&5
16365 cf_have_curses_lib=no
16367 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16370 echo "$as_me: failed program was:" >&5
16371 cat conftest.$ac_ext >&5
16372 cf_have_curses_lib=no
16374 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16375 echo "$as_me:16375: result: $cf_have_curses_lib" >&5
16376 echo "${ECHO_T}$cf_have_curses_lib" >&6
16377 test "$cf_have_curses_lib" = maybe && cf_have_curses_lib=yes
16378 if test "$cf_have_curses_lib" != "yes"
16380 CPPFLAGS="$cf_save_CPPFLAGS"
16381 LIBS="$cf_save_LIBS"
16384 cf_upper=`echo "have_lib$PANEL_NAME" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
16386 cat >>confdefs.h <<EOF
16387 #define $cf_upper 1
16393 if test "$cf_have_curses_lib" = no; then
16394 as_ac_Lib=`echo "ac_cv_lib_$PANEL_NAME$cf_cv_libtype''_new_panel" | $as_tr_sh`
16395 echo "$as_me:16395: checking for new_panel in -l$PANEL_NAME$cf_cv_libtype" >&5
16396 echo $ECHO_N "checking for new_panel in -l$PANEL_NAME$cf_cv_libtype... $ECHO_C" >&6
16397 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
16398 echo $ECHO_N "(cached) $ECHO_C" >&6
16400 ac_check_lib_save_LIBS=$LIBS
16401 LIBS="-l$PANEL_NAME$cf_cv_libtype $LIBS"
16402 cat >conftest.$ac_ext <<_ACEOF
16403 #line 16403 "configure"
16404 #include "confdefs.h"
16406 /* Override any gcc2 internal prototype to avoid an error. */
16410 /* We use char because int might match the return type of a gcc2
16411 builtin and then its argument prototype would still apply. */
16421 rm -f conftest.$ac_objext conftest$ac_exeext
16422 if { (eval echo "$as_me:16422: \"$ac_link\"") >&5
16423 (eval $ac_link) 2>&5
16425 echo "$as_me:16425: \$? = $ac_status" >&5
16426 (exit $ac_status); } &&
16427 { ac_try='test -s conftest$ac_exeext'
16428 { (eval echo "$as_me:16428: \"$ac_try\"") >&5
16429 (eval $ac_try) 2>&5
16431 echo "$as_me:16431: \$? = $ac_status" >&5
16432 (exit $ac_status); }; }; then
16433 eval "$as_ac_Lib=yes"
16435 echo "$as_me: failed program was:" >&5
16436 cat conftest.$ac_ext >&5
16437 eval "$as_ac_Lib=no"
16439 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16440 LIBS=$ac_check_lib_save_LIBS
16442 echo "$as_me:16442: result: `eval echo '${'$as_ac_Lib'}'`" >&5
16443 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
16444 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
16446 cf_upper=`echo "have_lib$PANEL_NAME" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
16448 cf_add_libs="$LIBS"
16451 for cf_add_1lib in -l$PANEL_NAME$cf_cv_libtype; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
16452 # filter duplicates
16453 for cf_add_1lib in $cf_add_0lib; do
16454 for cf_add_2lib in $cf_add_libs; do
16455 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
16460 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
16462 LIBS="$cf_add_libs"
16464 cat >>confdefs.h <<EOF
16465 #define $cf_upper 1
16472 cf_curses_headers="$cf_curses_headers panel.h"
16475 echo "$as_me:16475: checking if you want to check for menu functions" >&5
16476 echo $ECHO_N "checking if you want to check for menu functions... $ECHO_C" >&6
16478 # Check whether --enable-menu or --disable-menu was given.
16479 if test "${enable_menu+set}" = set; then
16480 enableval="$enable_menu"
16481 test "$enableval" != no && enableval=yes
16482 if test "$enableval" != "yes" ; then
16485 cf_enable_menu=$cf_default_menu
16489 cf_enable_menu=$cf_default_menu
16492 echo "$as_me:16492: result: $cf_enable_menu" >&5
16493 echo "${ECHO_T}$cf_enable_menu" >&6
16494 if test $cf_enable_menu = yes
16496 case $cf_cv_screen in
16501 echo "$as_me:16501: checking for NetBSD menu.h" >&5
16502 echo $ECHO_N "checking for NetBSD menu.h... $ECHO_C" >&6
16503 if test "${cf_cv_netbsd_menu_h+set}" = set; then
16504 echo $ECHO_N "(cached) $ECHO_C" >&6
16507 cat >conftest.$ac_ext <<_ACEOF
16508 #line 16508 "configure"
16509 #include "confdefs.h"
16511 #include <${cf_cv_ncurses_header:-curses.h}>
16519 int y = menu->max_item_width;
16525 rm -f conftest.$ac_objext
16526 if { (eval echo "$as_me:16526: \"$ac_compile\"") >&5
16527 (eval $ac_compile) 2>&5
16529 echo "$as_me:16529: \$? = $ac_status" >&5
16530 (exit $ac_status); } &&
16531 { ac_try='test -s conftest.$ac_objext'
16532 { (eval echo "$as_me:16532: \"$ac_try\"") >&5
16533 (eval $ac_try) 2>&5
16535 echo "$as_me:16535: \$? = $ac_status" >&5
16536 (exit $ac_status); }; }; then
16537 cf_cv_netbsd_menu_h=yes
16540 echo "$as_me: failed program was:" >&5
16541 cat conftest.$ac_ext >&5
16542 cf_cv_netbsd_menu_h=no
16544 rm -f conftest.$ac_objext conftest.$ac_ext
16547 echo "$as_me:16547: result: $cf_cv_netbsd_menu_h" >&5
16548 echo "${ECHO_T}$cf_cv_netbsd_menu_h" >&6
16550 test "$cf_cv_netbsd_menu_h" = yes &&
16551 cat >>confdefs.h <<\EOF
16552 #define HAVE_NETBSD_MENU_H 1
16558 cf_have_curses_lib=no
16560 : ${NCURSES_CONFIG_PKG:=none}
16561 if test "x${NCURSES_CONFIG_PKG}" = xnone; then
16563 elif test "x${PKG_CONFIG:=none}" != xnone; then
16564 echo "$as_me:16564: checking pkg-config for $MENU_NAME$cf_cv_libtype" >&5
16565 echo $ECHO_N "checking pkg-config for $MENU_NAME$cf_cv_libtype... $ECHO_C" >&6
16566 if "$PKG_CONFIG" --exists $MENU_NAME$cf_cv_libtype ; then
16567 echo "$as_me:16567: result: yes" >&5
16568 echo "${ECHO_T}yes" >&6
16570 echo "$as_me:16570: checking if the $MENU_NAME$cf_cv_libtype package files work" >&5
16571 echo $ECHO_N "checking if the $MENU_NAME$cf_cv_libtype package files work... $ECHO_C" >&6
16573 cf_save_CPPFLAGS="$CPPFLAGS"
16574 cf_save_LIBS="$LIBS"
16579 cf_new_extra_cppflags=
16581 for cf_add_cflags in `$PKG_CONFIG --cflags $MENU_NAME$cf_cv_libtype`
16583 case $cf_fix_cppflags in
16585 case $cf_add_cflags in
16586 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
16587 case $cf_add_cflags in
16589 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
16591 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
16592 && test -z "${cf_tst_cflags}" \
16593 && cf_fix_cppflags=yes
16595 if test $cf_fix_cppflags = yes ; then
16597 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
16598 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
16601 elif test "${cf_tst_cflags}" = "\"'" ; then
16603 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
16604 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
16610 case "$CPPFLAGS" in
16614 case $cf_add_cflags in
16616 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
16618 CPPFLAGS=`echo "$CPPFLAGS" | \
16619 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
16620 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
16625 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
16626 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
16633 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
16634 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
16641 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
16642 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
16644 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
16646 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
16647 && test -z "${cf_tst_cflags}" \
16648 && cf_fix_cppflags=no
16653 if test -n "$cf_new_cflags" ; then
16655 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
16656 CFLAGS="${CFLAGS}$cf_new_cflags"
16660 if test -n "$cf_new_cppflags" ; then
16662 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
16663 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
16667 if test -n "$cf_new_extra_cppflags" ; then
16669 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
16670 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
16674 cf_add_libs="$LIBS"
16677 for cf_add_1lib in `$PKG_CONFIG --libs $MENU_NAME$cf_cv_libtype`; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
16678 # filter duplicates
16679 for cf_add_1lib in $cf_add_0lib; do
16680 for cf_add_2lib in $cf_add_libs; do
16681 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
16686 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
16688 LIBS="$cf_add_libs"
16690 cat >conftest.$ac_ext <<_ACEOF
16691 #line 16691 "configure"
16692 #include "confdefs.h"
16693 #include <$MENU_NAME.h>
16697 (void) menu_driver ( 0,0 );
16702 rm -f conftest.$ac_objext conftest$ac_exeext
16703 if { (eval echo "$as_me:16703: \"$ac_link\"") >&5
16704 (eval $ac_link) 2>&5
16706 echo "$as_me:16706: \$? = $ac_status" >&5
16707 (exit $ac_status); } &&
16708 { ac_try='test -s conftest$ac_exeext'
16709 { (eval echo "$as_me:16709: \"$ac_try\"") >&5
16710 (eval $ac_try) 2>&5
16712 echo "$as_me:16712: \$? = $ac_status" >&5
16713 (exit $ac_status); }; }; then
16714 if test "$cross_compiling" = yes; then
16715 cf_have_curses_lib=maybe
16717 cat >conftest.$ac_ext <<_ACEOF
16718 #line 16718 "configure"
16719 #include "confdefs.h"
16720 #include <$MENU_NAME.h>
16722 { (void) menu_driver ( 0,0 ); return 0; }
16724 rm -f conftest$ac_exeext
16725 if { (eval echo "$as_me:16725: \"$ac_link\"") >&5
16726 (eval $ac_link) 2>&5
16728 echo "$as_me:16728: \$? = $ac_status" >&5
16729 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16730 { (eval echo "$as_me:16730: \"$ac_try\"") >&5
16731 (eval $ac_try) 2>&5
16733 echo "$as_me:16733: \$? = $ac_status" >&5
16734 (exit $ac_status); }; }; then
16735 cf_have_curses_lib=yes
16737 echo "$as_me: program exited with status $ac_status" >&5
16738 echo "$as_me: failed program was:" >&5
16739 cat conftest.$ac_ext >&5
16740 cf_have_curses_lib=no
16742 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16745 echo "$as_me: failed program was:" >&5
16746 cat conftest.$ac_ext >&5
16747 cf_have_curses_lib=no
16749 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16750 echo "$as_me:16750: result: $cf_have_curses_lib" >&5
16751 echo "${ECHO_T}$cf_have_curses_lib" >&6
16752 test "$cf_have_curses_lib" = maybe && cf_have_curses_lib=yes
16753 if test "$cf_have_curses_lib" != "yes"
16755 CPPFLAGS="$cf_save_CPPFLAGS"
16756 LIBS="$cf_save_LIBS"
16759 cf_upper=`echo "have_lib$MENU_NAME" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
16761 cat >>confdefs.h <<EOF
16762 #define $cf_upper 1
16768 if test "$cf_have_curses_lib" = no; then
16769 as_ac_Lib=`echo "ac_cv_lib_$MENU_NAME$cf_cv_libtype''_menu_driver" | $as_tr_sh`
16770 echo "$as_me:16770: checking for menu_driver in -l$MENU_NAME$cf_cv_libtype" >&5
16771 echo $ECHO_N "checking for menu_driver in -l$MENU_NAME$cf_cv_libtype... $ECHO_C" >&6
16772 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
16773 echo $ECHO_N "(cached) $ECHO_C" >&6
16775 ac_check_lib_save_LIBS=$LIBS
16776 LIBS="-l$MENU_NAME$cf_cv_libtype $LIBS"
16777 cat >conftest.$ac_ext <<_ACEOF
16778 #line 16778 "configure"
16779 #include "confdefs.h"
16781 /* Override any gcc2 internal prototype to avoid an error. */
16785 /* We use char because int might match the return type of a gcc2
16786 builtin and then its argument prototype would still apply. */
16787 char menu_driver ();
16796 rm -f conftest.$ac_objext conftest$ac_exeext
16797 if { (eval echo "$as_me:16797: \"$ac_link\"") >&5
16798 (eval $ac_link) 2>&5
16800 echo "$as_me:16800: \$? = $ac_status" >&5
16801 (exit $ac_status); } &&
16802 { ac_try='test -s conftest$ac_exeext'
16803 { (eval echo "$as_me:16803: \"$ac_try\"") >&5
16804 (eval $ac_try) 2>&5
16806 echo "$as_me:16806: \$? = $ac_status" >&5
16807 (exit $ac_status); }; }; then
16808 eval "$as_ac_Lib=yes"
16810 echo "$as_me: failed program was:" >&5
16811 cat conftest.$ac_ext >&5
16812 eval "$as_ac_Lib=no"
16814 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16815 LIBS=$ac_check_lib_save_LIBS
16817 echo "$as_me:16817: result: `eval echo '${'$as_ac_Lib'}'`" >&5
16818 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
16819 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
16821 cf_upper=`echo "have_lib$MENU_NAME" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
16823 cf_add_libs="$LIBS"
16826 for cf_add_1lib in -l$MENU_NAME$cf_cv_libtype; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
16827 # filter duplicates
16828 for cf_add_1lib in $cf_add_0lib; do
16829 for cf_add_2lib in $cf_add_libs; do
16830 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
16835 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
16837 LIBS="$cf_add_libs"
16839 cat >>confdefs.h <<EOF
16840 #define $cf_upper 1
16847 cf_curses_headers="$cf_curses_headers menu.h"
16850 echo "$as_me:16850: checking if you want to check for form functions" >&5
16851 echo $ECHO_N "checking if you want to check for form functions... $ECHO_C" >&6
16853 # Check whether --enable-form or --disable-form was given.
16854 if test "${enable_form+set}" = set; then
16855 enableval="$enable_form"
16856 test "$enableval" != no && enableval=yes
16857 if test "$enableval" != "yes" ; then
16860 cf_enable_form=$cf_default_form
16864 cf_enable_form=$cf_default_form
16867 echo "$as_me:16867: result: $cf_enable_form" >&5
16868 echo "${ECHO_T}$cf_enable_form" >&6
16869 if test $cf_enable_form = yes
16871 case $cf_cv_screen in
16876 echo "$as_me:16876: checking for NetBSD form.h" >&5
16877 echo $ECHO_N "checking for NetBSD form.h... $ECHO_C" >&6
16878 if test "${cf_cv_netbsd_form_h+set}" = set; then
16879 echo $ECHO_N "(cached) $ECHO_C" >&6
16882 cat >conftest.$ac_ext <<_ACEOF
16883 #line 16883 "configure"
16884 #include "confdefs.h"
16886 #include <${cf_cv_ncurses_header:-curses.h}>
16894 int y = current_field(form)->cursor_ypos;
16895 int x = current_field(form)->cursor_xpos;
16901 rm -f conftest.$ac_objext
16902 if { (eval echo "$as_me:16902: \"$ac_compile\"") >&5
16903 (eval $ac_compile) 2>&5
16905 echo "$as_me:16905: \$? = $ac_status" >&5
16906 (exit $ac_status); } &&
16907 { ac_try='test -s conftest.$ac_objext'
16908 { (eval echo "$as_me:16908: \"$ac_try\"") >&5
16909 (eval $ac_try) 2>&5
16911 echo "$as_me:16911: \$? = $ac_status" >&5
16912 (exit $ac_status); }; }; then
16913 cf_cv_netbsd_form_h=yes
16916 echo "$as_me: failed program was:" >&5
16917 cat conftest.$ac_ext >&5
16918 cf_cv_netbsd_form_h=no
16920 rm -f conftest.$ac_objext conftest.$ac_ext
16923 echo "$as_me:16923: result: $cf_cv_netbsd_form_h" >&5
16924 echo "${ECHO_T}$cf_cv_netbsd_form_h" >&6
16926 test "$cf_cv_netbsd_form_h" = yes &&
16927 cat >>confdefs.h <<\EOF
16928 #define HAVE_NETBSD_FORM_H 1
16934 cf_have_curses_lib=no
16936 : ${NCURSES_CONFIG_PKG:=none}
16937 if test "x${NCURSES_CONFIG_PKG}" = xnone; then
16939 elif test "x${PKG_CONFIG:=none}" != xnone; then
16940 echo "$as_me:16940: checking pkg-config for $FORM_NAME$cf_cv_libtype" >&5
16941 echo $ECHO_N "checking pkg-config for $FORM_NAME$cf_cv_libtype... $ECHO_C" >&6
16942 if "$PKG_CONFIG" --exists $FORM_NAME$cf_cv_libtype ; then
16943 echo "$as_me:16943: result: yes" >&5
16944 echo "${ECHO_T}yes" >&6
16946 echo "$as_me:16946: checking if the $FORM_NAME$cf_cv_libtype package files work" >&5
16947 echo $ECHO_N "checking if the $FORM_NAME$cf_cv_libtype package files work... $ECHO_C" >&6
16949 cf_save_CPPFLAGS="$CPPFLAGS"
16950 cf_save_LIBS="$LIBS"
16955 cf_new_extra_cppflags=
16957 for cf_add_cflags in `$PKG_CONFIG --cflags $FORM_NAME$cf_cv_libtype`
16959 case $cf_fix_cppflags in
16961 case $cf_add_cflags in
16962 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
16963 case $cf_add_cflags in
16965 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
16967 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
16968 && test -z "${cf_tst_cflags}" \
16969 && cf_fix_cppflags=yes
16971 if test $cf_fix_cppflags = yes ; then
16973 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
16974 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
16977 elif test "${cf_tst_cflags}" = "\"'" ; then
16979 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
16980 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
16986 case "$CPPFLAGS" in
16990 case $cf_add_cflags in
16992 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
16994 CPPFLAGS=`echo "$CPPFLAGS" | \
16995 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
16996 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
17001 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
17002 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
17009 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
17010 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
17017 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
17018 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
17020 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
17022 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
17023 && test -z "${cf_tst_cflags}" \
17024 && cf_fix_cppflags=no
17029 if test -n "$cf_new_cflags" ; then
17031 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
17032 CFLAGS="${CFLAGS}$cf_new_cflags"
17036 if test -n "$cf_new_cppflags" ; then
17038 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
17039 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
17043 if test -n "$cf_new_extra_cppflags" ; then
17045 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
17046 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
17050 cf_add_libs="$LIBS"
17053 for cf_add_1lib in `$PKG_CONFIG --libs $FORM_NAME$cf_cv_libtype`; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
17054 # filter duplicates
17055 for cf_add_1lib in $cf_add_0lib; do
17056 for cf_add_2lib in $cf_add_libs; do
17057 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
17062 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
17064 LIBS="$cf_add_libs"
17066 cat >conftest.$ac_ext <<_ACEOF
17067 #line 17067 "configure"
17068 #include "confdefs.h"
17069 #include <$FORM_NAME.h>
17073 (void) form_driver ( 0,0 );
17078 rm -f conftest.$ac_objext conftest$ac_exeext
17079 if { (eval echo "$as_me:17079: \"$ac_link\"") >&5
17080 (eval $ac_link) 2>&5
17082 echo "$as_me:17082: \$? = $ac_status" >&5
17083 (exit $ac_status); } &&
17084 { ac_try='test -s conftest$ac_exeext'
17085 { (eval echo "$as_me:17085: \"$ac_try\"") >&5
17086 (eval $ac_try) 2>&5
17088 echo "$as_me:17088: \$? = $ac_status" >&5
17089 (exit $ac_status); }; }; then
17090 if test "$cross_compiling" = yes; then
17091 cf_have_curses_lib=maybe
17093 cat >conftest.$ac_ext <<_ACEOF
17094 #line 17094 "configure"
17095 #include "confdefs.h"
17096 #include <$FORM_NAME.h>
17098 { (void) form_driver ( 0,0 ); return 0; }
17100 rm -f conftest$ac_exeext
17101 if { (eval echo "$as_me:17101: \"$ac_link\"") >&5
17102 (eval $ac_link) 2>&5
17104 echo "$as_me:17104: \$? = $ac_status" >&5
17105 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17106 { (eval echo "$as_me:17106: \"$ac_try\"") >&5
17107 (eval $ac_try) 2>&5
17109 echo "$as_me:17109: \$? = $ac_status" >&5
17110 (exit $ac_status); }; }; then
17111 cf_have_curses_lib=yes
17113 echo "$as_me: program exited with status $ac_status" >&5
17114 echo "$as_me: failed program was:" >&5
17115 cat conftest.$ac_ext >&5
17116 cf_have_curses_lib=no
17118 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17121 echo "$as_me: failed program was:" >&5
17122 cat conftest.$ac_ext >&5
17123 cf_have_curses_lib=no
17125 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17126 echo "$as_me:17126: result: $cf_have_curses_lib" >&5
17127 echo "${ECHO_T}$cf_have_curses_lib" >&6
17128 test "$cf_have_curses_lib" = maybe && cf_have_curses_lib=yes
17129 if test "$cf_have_curses_lib" != "yes"
17131 CPPFLAGS="$cf_save_CPPFLAGS"
17132 LIBS="$cf_save_LIBS"
17135 cf_upper=`echo "have_lib$FORM_NAME" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
17137 cat >>confdefs.h <<EOF
17138 #define $cf_upper 1
17144 if test "$cf_have_curses_lib" = no; then
17145 as_ac_Lib=`echo "ac_cv_lib_$FORM_NAME$cf_cv_libtype''_form_driver" | $as_tr_sh`
17146 echo "$as_me:17146: checking for form_driver in -l$FORM_NAME$cf_cv_libtype" >&5
17147 echo $ECHO_N "checking for form_driver in -l$FORM_NAME$cf_cv_libtype... $ECHO_C" >&6
17148 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
17149 echo $ECHO_N "(cached) $ECHO_C" >&6
17151 ac_check_lib_save_LIBS=$LIBS
17152 LIBS="-l$FORM_NAME$cf_cv_libtype $LIBS"
17153 cat >conftest.$ac_ext <<_ACEOF
17154 #line 17154 "configure"
17155 #include "confdefs.h"
17157 /* Override any gcc2 internal prototype to avoid an error. */
17161 /* We use char because int might match the return type of a gcc2
17162 builtin and then its argument prototype would still apply. */
17163 char form_driver ();
17172 rm -f conftest.$ac_objext conftest$ac_exeext
17173 if { (eval echo "$as_me:17173: \"$ac_link\"") >&5
17174 (eval $ac_link) 2>&5
17176 echo "$as_me:17176: \$? = $ac_status" >&5
17177 (exit $ac_status); } &&
17178 { ac_try='test -s conftest$ac_exeext'
17179 { (eval echo "$as_me:17179: \"$ac_try\"") >&5
17180 (eval $ac_try) 2>&5
17182 echo "$as_me:17182: \$? = $ac_status" >&5
17183 (exit $ac_status); }; }; then
17184 eval "$as_ac_Lib=yes"
17186 echo "$as_me: failed program was:" >&5
17187 cat conftest.$ac_ext >&5
17188 eval "$as_ac_Lib=no"
17190 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17191 LIBS=$ac_check_lib_save_LIBS
17193 echo "$as_me:17193: result: `eval echo '${'$as_ac_Lib'}'`" >&5
17194 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
17195 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
17197 cf_upper=`echo "have_lib$FORM_NAME" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
17199 cf_add_libs="$LIBS"
17202 for cf_add_1lib in -l$FORM_NAME$cf_cv_libtype; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
17203 # filter duplicates
17204 for cf_add_1lib in $cf_add_0lib; do
17205 for cf_add_2lib in $cf_add_libs; do
17206 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
17211 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
17213 LIBS="$cf_add_libs"
17215 cat >>confdefs.h <<EOF
17216 #define $cf_upper 1
17223 cf_curses_headers="$cf_curses_headers form.h"
17226 # look for curses-related headers
17228 for ac_header in $cf_curses_headers
17230 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
17231 echo "$as_me:17231: checking for $ac_header" >&5
17232 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17233 if eval "test \"\${$as_ac_Header+set}\" = set"; then
17234 echo $ECHO_N "(cached) $ECHO_C" >&6
17236 cat >conftest.$ac_ext <<_ACEOF
17237 #line 17237 "configure"
17238 #include "confdefs.h"
17239 #include <$ac_header>
17241 if { (eval echo "$as_me:17241: \"$ac_cpp conftest.$ac_ext\"") >&5
17242 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
17244 egrep -v '^ *\+' conftest.er1 >conftest.err
17246 cat conftest.err >&5
17247 echo "$as_me:17247: \$? = $ac_status" >&5
17248 (exit $ac_status); } >/dev/null; then
17249 if test -s conftest.err; then
17250 ac_cpp_err=$ac_c_preproc_warn_flag
17257 if test -z "$ac_cpp_err"; then
17258 eval "$as_ac_Header=yes"
17260 echo "$as_me: failed program was:" >&5
17261 cat conftest.$ac_ext >&5
17262 eval "$as_ac_Header=no"
17264 rm -f conftest.err conftest.$ac_ext
17266 echo "$as_me:17266: result: `eval echo '${'$as_ac_Header'}'`" >&5
17267 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
17268 if test `eval echo '${'$as_ac_Header'}'` = yes; then
17269 cat >>confdefs.h <<EOF
17270 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
17276 echo "$as_me:17276: checking for ANSI C header files" >&5
17277 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
17278 if test "${ac_cv_header_stdc+set}" = set; then
17279 echo $ECHO_N "(cached) $ECHO_C" >&6
17281 cat >conftest.$ac_ext <<_ACEOF
17282 #line 17282 "configure"
17283 #include "confdefs.h"
17284 #include <stdlib.h>
17285 #include <stdarg.h>
17286 #include <string.h>
17290 if { (eval echo "$as_me:17290: \"$ac_cpp conftest.$ac_ext\"") >&5
17291 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
17293 egrep -v '^ *\+' conftest.er1 >conftest.err
17295 cat conftest.err >&5
17296 echo "$as_me:17296: \$? = $ac_status" >&5
17297 (exit $ac_status); } >/dev/null; then
17298 if test -s conftest.err; then
17299 ac_cpp_err=$ac_c_preproc_warn_flag
17306 if test -z "$ac_cpp_err"; then
17307 ac_cv_header_stdc=yes
17309 echo "$as_me: failed program was:" >&5
17310 cat conftest.$ac_ext >&5
17311 ac_cv_header_stdc=no
17313 rm -f conftest.err conftest.$ac_ext
17315 if test $ac_cv_header_stdc = yes; then
17316 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
17317 cat >conftest.$ac_ext <<_ACEOF
17318 #line 17318 "configure"
17319 #include "confdefs.h"
17320 #include <string.h>
17323 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17324 egrep "memchr" >/dev/null 2>&1; then
17327 ac_cv_header_stdc=no
17333 if test $ac_cv_header_stdc = yes; then
17334 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
17335 cat >conftest.$ac_ext <<_ACEOF
17336 #line 17336 "configure"
17337 #include "confdefs.h"
17338 #include <stdlib.h>
17341 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17342 egrep "free" >/dev/null 2>&1; then
17345 ac_cv_header_stdc=no
17351 if test $ac_cv_header_stdc = yes; then
17352 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
17353 if test "$cross_compiling" = yes; then
17356 cat >conftest.$ac_ext <<_ACEOF
17357 #line 17357 "configure"
17358 #include "confdefs.h"
17360 #if ((' ' & 0x0FF) == 0x020)
17361 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
17362 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
17364 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
17365 || ('j' <= (c) && (c) <= 'r') \
17366 || ('s' <= (c) && (c) <= 'z'))
17367 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
17370 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
17375 for (i = 0; i < 256; i++)
17376 if (XOR (islower (i), ISLOWER (i))
17377 || toupper (i) != TOUPPER (i))
17378 $ac_main_return(2);
17379 $ac_main_return (0);
17382 rm -f conftest$ac_exeext
17383 if { (eval echo "$as_me:17383: \"$ac_link\"") >&5
17384 (eval $ac_link) 2>&5
17386 echo "$as_me:17386: \$? = $ac_status" >&5
17387 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17388 { (eval echo "$as_me:17388: \"$ac_try\"") >&5
17389 (eval $ac_try) 2>&5
17391 echo "$as_me:17391: \$? = $ac_status" >&5
17392 (exit $ac_status); }; }; then
17395 echo "$as_me: program exited with status $ac_status" >&5
17396 echo "$as_me: failed program was:" >&5
17397 cat conftest.$ac_ext >&5
17398 ac_cv_header_stdc=no
17400 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17404 echo "$as_me:17404: result: $ac_cv_header_stdc" >&5
17405 echo "${ECHO_T}$ac_cv_header_stdc" >&6
17406 if test $ac_cv_header_stdc = yes; then
17408 cat >>confdefs.h <<\EOF
17409 #define STDC_HEADERS 1
17414 echo "$as_me:17414: checking whether time.h and sys/time.h may both be included" >&5
17415 echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
17416 if test "${ac_cv_header_time+set}" = set; then
17417 echo $ECHO_N "(cached) $ECHO_C" >&6
17419 cat >conftest.$ac_ext <<_ACEOF
17420 #line 17420 "configure"
17421 #include "confdefs.h"
17422 #include <sys/types.h>
17423 #include <sys/time.h>
17429 if ((struct tm *) 0)
17435 rm -f conftest.$ac_objext
17436 if { (eval echo "$as_me:17436: \"$ac_compile\"") >&5
17437 (eval $ac_compile) 2>&5
17439 echo "$as_me:17439: \$? = $ac_status" >&5
17440 (exit $ac_status); } &&
17441 { ac_try='test -s conftest.$ac_objext'
17442 { (eval echo "$as_me:17442: \"$ac_try\"") >&5
17443 (eval $ac_try) 2>&5
17445 echo "$as_me:17445: \$? = $ac_status" >&5
17446 (exit $ac_status); }; }; then
17447 ac_cv_header_time=yes
17449 echo "$as_me: failed program was:" >&5
17450 cat conftest.$ac_ext >&5
17451 ac_cv_header_time=no
17453 rm -f conftest.$ac_objext conftest.$ac_ext
17455 echo "$as_me:17455: result: $ac_cv_header_time" >&5
17456 echo "${ECHO_T}$ac_cv_header_time" >&6
17457 if test $ac_cv_header_time = yes; then
17459 cat >>confdefs.h <<\EOF
17460 #define TIME_WITH_SYS_TIME 1
17478 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
17479 echo "$as_me:17479: checking for $ac_header" >&5
17480 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17481 if eval "test \"\${$as_ac_Header+set}\" = set"; then
17482 echo $ECHO_N "(cached) $ECHO_C" >&6
17484 cat >conftest.$ac_ext <<_ACEOF
17485 #line 17485 "configure"
17486 #include "confdefs.h"
17487 #include <$ac_header>
17489 if { (eval echo "$as_me:17489: \"$ac_cpp conftest.$ac_ext\"") >&5
17490 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
17492 egrep -v '^ *\+' conftest.er1 >conftest.err
17494 cat conftest.err >&5
17495 echo "$as_me:17495: \$? = $ac_status" >&5
17496 (exit $ac_status); } >/dev/null; then
17497 if test -s conftest.err; then
17498 ac_cpp_err=$ac_c_preproc_warn_flag
17505 if test -z "$ac_cpp_err"; then
17506 eval "$as_ac_Header=yes"
17508 echo "$as_me: failed program was:" >&5
17509 cat conftest.$ac_ext >&5
17510 eval "$as_ac_Header=no"
17512 rm -f conftest.err conftest.$ac_ext
17514 echo "$as_me:17514: result: `eval echo '${'$as_ac_Header'}'`" >&5
17515 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
17516 if test `eval echo '${'$as_ac_Header'}'` = yes; then
17517 cat >>confdefs.h <<EOF
17518 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
17524 for ac_header in unistd.h getopt.h
17526 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
17527 echo "$as_me:17527: checking for $ac_header" >&5
17528 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17529 if eval "test \"\${$as_ac_Header+set}\" = set"; then
17530 echo $ECHO_N "(cached) $ECHO_C" >&6
17532 cat >conftest.$ac_ext <<_ACEOF
17533 #line 17533 "configure"
17534 #include "confdefs.h"
17535 #include <$ac_header>
17537 if { (eval echo "$as_me:17537: \"$ac_cpp conftest.$ac_ext\"") >&5
17538 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
17540 egrep -v '^ *\+' conftest.er1 >conftest.err
17542 cat conftest.err >&5
17543 echo "$as_me:17543: \$? = $ac_status" >&5
17544 (exit $ac_status); } >/dev/null; then
17545 if test -s conftest.err; then
17546 ac_cpp_err=$ac_c_preproc_warn_flag
17553 if test -z "$ac_cpp_err"; then
17554 eval "$as_ac_Header=yes"
17556 echo "$as_me: failed program was:" >&5
17557 cat conftest.$ac_ext >&5
17558 eval "$as_ac_Header=no"
17560 rm -f conftest.err conftest.$ac_ext
17562 echo "$as_me:17562: result: `eval echo '${'$as_ac_Header'}'`" >&5
17563 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
17564 if test `eval echo '${'$as_ac_Header'}'` = yes; then
17565 cat >>confdefs.h <<EOF
17566 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
17572 echo "$as_me:17572: checking for header declaring getopt variables" >&5
17573 echo $ECHO_N "checking for header declaring getopt variables... $ECHO_C" >&6
17574 if test "${cf_cv_getopt_header+set}" = set; then
17575 echo $ECHO_N "(cached) $ECHO_C" >&6
17578 cf_cv_getopt_header=none
17579 for cf_header in stdio.h stdlib.h unistd.h getopt.h
17581 cat >conftest.$ac_ext <<_ACEOF
17582 #line 17582 "configure"
17583 #include "confdefs.h"
17585 #include <$cf_header>
17589 int x = optind; char *y = optarg
17594 rm -f conftest.$ac_objext
17595 if { (eval echo "$as_me:17595: \"$ac_compile\"") >&5
17596 (eval $ac_compile) 2>&5
17598 echo "$as_me:17598: \$? = $ac_status" >&5
17599 (exit $ac_status); } &&
17600 { ac_try='test -s conftest.$ac_objext'
17601 { (eval echo "$as_me:17601: \"$ac_try\"") >&5
17602 (eval $ac_try) 2>&5
17604 echo "$as_me:17604: \$? = $ac_status" >&5
17605 (exit $ac_status); }; }; then
17606 cf_cv_getopt_header=$cf_header
17609 echo "$as_me: failed program was:" >&5
17610 cat conftest.$ac_ext >&5
17612 rm -f conftest.$ac_objext conftest.$ac_ext
17616 echo "$as_me:17616: result: $cf_cv_getopt_header" >&5
17617 echo "${ECHO_T}$cf_cv_getopt_header" >&6
17618 if test $cf_cv_getopt_header != none ; then
17620 cat >>confdefs.h <<\EOF
17621 #define HAVE_GETOPT_HEADER 1
17625 if test $cf_cv_getopt_header = getopt.h ; then
17627 cat >>confdefs.h <<\EOF
17628 #define NEED_GETOPT_H 1
17642 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
17643 echo "$as_me:17643: checking for $ac_func" >&5
17644 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
17645 if eval "test \"\${$as_ac_var+set}\" = set"; then
17646 echo $ECHO_N "(cached) $ECHO_C" >&6
17648 cat >conftest.$ac_ext <<_ACEOF
17649 #line 17649 "configure"
17650 #include "confdefs.h"
17651 #define $ac_func autoconf_temporary
17652 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
17659 /* We use char because int might match the return type of a gcc2
17660 builtin and then its argument prototype would still apply. */
17661 char $ac_func (void);
17667 /* The GNU C library defines stubs for functions which it implements
17668 to always fail with ENOSYS. Some functions are actually named
17669 something starting with __ and the normal name is an alias. */
17670 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
17671 #error found stub for $ac_func
17674 return $ac_func ();
17679 rm -f conftest.$ac_objext conftest$ac_exeext
17680 if { (eval echo "$as_me:17680: \"$ac_link\"") >&5
17681 (eval $ac_link) 2>&5
17683 echo "$as_me:17683: \$? = $ac_status" >&5
17684 (exit $ac_status); } &&
17685 { ac_try='test -s conftest$ac_exeext'
17686 { (eval echo "$as_me:17686: \"$ac_try\"") >&5
17687 (eval $ac_try) 2>&5
17689 echo "$as_me:17689: \$? = $ac_status" >&5
17690 (exit $ac_status); }; }; then
17691 eval "$as_ac_var=yes"
17693 echo "$as_me: failed program was:" >&5
17694 cat conftest.$ac_ext >&5
17695 eval "$as_ac_var=no"
17697 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17699 echo "$as_me:17699: result: `eval echo '${'$as_ac_var'}'`" >&5
17700 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
17701 if test `eval echo '${'$as_ac_var'}'` = yes; then
17702 cat >>confdefs.h <<EOF
17703 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
17709 # use a compile-check to work with ncurses*-config and subdirectory includes
17710 echo "$as_me:17710: checking if we can use termcap.h" >&5
17711 echo $ECHO_N "checking if we can use termcap.h... $ECHO_C" >&6
17712 if test "${cf_cv_have_termcap_h+set}" = set; then
17713 echo $ECHO_N "(cached) $ECHO_C" >&6
17716 cat >conftest.$ac_ext <<_ACEOF
17717 #line 17717 "configure"
17718 #include "confdefs.h"
17720 #include <curses.h>
17721 #ifdef NCURSES_VERSION
17722 #undef NCURSES_VERSION
17724 #include <termcap.h>
17725 #ifndef NCURSES_VERSION
17726 #error wrong header
17737 rm -f conftest.$ac_objext
17738 if { (eval echo "$as_me:17738: \"$ac_compile\"") >&5
17739 (eval $ac_compile) 2>&5
17741 echo "$as_me:17741: \$? = $ac_status" >&5
17742 (exit $ac_status); } &&
17743 { ac_try='test -s conftest.$ac_objext'
17744 { (eval echo "$as_me:17744: \"$ac_try\"") >&5
17745 (eval $ac_try) 2>&5
17747 echo "$as_me:17747: \$? = $ac_status" >&5
17748 (exit $ac_status); }; }; then
17749 cf_cv_have_termcap_h=yes
17751 echo "$as_me: failed program was:" >&5
17752 cat conftest.$ac_ext >&5
17753 cf_cv_have_termcap_h=no
17755 rm -f conftest.$ac_objext conftest.$ac_ext
17757 echo "$as_me:17757: result: $cf_cv_have_termcap_h" >&5
17758 echo "${ECHO_T}$cf_cv_have_termcap_h" >&6
17759 if test "x$cf_cv_have_termcap_h" = xyes
17762 cat >>confdefs.h <<\EOF
17763 #define HAVE_TERMCAP_H 1
17767 echo "$as_me:17767: checking if we can use ncurses/termcap.h" >&5
17768 echo $ECHO_N "checking if we can use ncurses/termcap.h... $ECHO_C" >&6
17769 if test "${cf_cv_have_ncurses_termcap_h+set}" = set; then
17770 echo $ECHO_N "(cached) $ECHO_C" >&6
17773 cat >conftest.$ac_ext <<_ACEOF
17774 #line 17774 "configure"
17775 #include "confdefs.h"
17777 #include <ncurses/curses.h>
17778 #ifdef NCURSES_VERSION
17779 #undef NCURSES_VERSION
17781 #include <ncurses/termcap.h>
17782 #ifndef NCURSES_VERSION
17783 #error wrong header
17794 rm -f conftest.$ac_objext
17795 if { (eval echo "$as_me:17795: \"$ac_compile\"") >&5
17796 (eval $ac_compile) 2>&5
17798 echo "$as_me:17798: \$? = $ac_status" >&5
17799 (exit $ac_status); } &&
17800 { ac_try='test -s conftest.$ac_objext'
17801 { (eval echo "$as_me:17801: \"$ac_try\"") >&5
17802 (eval $ac_try) 2>&5
17804 echo "$as_me:17804: \$? = $ac_status" >&5
17805 (exit $ac_status); }; }; then
17806 cf_cv_have_ncurses_termcap_h=yes
17808 echo "$as_me: failed program was:" >&5
17809 cat conftest.$ac_ext >&5
17810 cf_cv_have_ncurses_termcap_h=no
17812 rm -f conftest.$ac_objext conftest.$ac_ext
17814 echo "$as_me:17814: result: $cf_cv_have_ncurses_termcap_h" >&5
17815 echo "${ECHO_T}$cf_cv_have_ncurses_termcap_h" >&6
17816 test "x$cf_cv_have_ncurses_termcap_h" = xyes &&
17817 cat >>confdefs.h <<\EOF
17818 #define HAVE_NCURSES_TERMCAP_H 1
17823 if test "x$ac_cv_func_getopt" = xno; then
17824 { { echo "$as_me:17824: error: getopt is required for building programs" >&5
17825 echo "$as_me: error: getopt is required for building programs" >&2;}
17826 { (exit 1); exit 1; }; }
17829 if test "$cf_enable_widec" = yes; then
17842 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
17843 echo "$as_me:17843: checking for $ac_func" >&5
17844 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
17845 if eval "test \"\${$as_ac_var+set}\" = set"; then
17846 echo $ECHO_N "(cached) $ECHO_C" >&6
17848 cat >conftest.$ac_ext <<_ACEOF
17849 #line 17849 "configure"
17850 #include "confdefs.h"
17851 #define $ac_func autoconf_temporary
17852 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
17859 /* We use char because int might match the return type of a gcc2
17860 builtin and then its argument prototype would still apply. */
17861 char $ac_func (void);
17867 /* The GNU C library defines stubs for functions which it implements
17868 to always fail with ENOSYS. Some functions are actually named
17869 something starting with __ and the normal name is an alias. */
17870 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
17871 #error found stub for $ac_func
17874 return $ac_func ();
17879 rm -f conftest.$ac_objext conftest$ac_exeext
17880 if { (eval echo "$as_me:17880: \"$ac_link\"") >&5
17881 (eval $ac_link) 2>&5
17883 echo "$as_me:17883: \$? = $ac_status" >&5
17884 (exit $ac_status); } &&
17885 { ac_try='test -s conftest$ac_exeext'
17886 { (eval echo "$as_me:17886: \"$ac_try\"") >&5
17887 (eval $ac_try) 2>&5
17889 echo "$as_me:17889: \$? = $ac_status" >&5
17890 (exit $ac_status); }; }; then
17891 eval "$as_ac_var=yes"
17893 echo "$as_me: failed program was:" >&5
17894 cat conftest.$ac_ext >&5
17895 eval "$as_ac_var=no"
17897 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17899 echo "$as_me:17899: result: `eval echo '${'$as_ac_var'}'`" >&5
17900 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
17901 if test `eval echo '${'$as_ac_var'}'` = yes; then
17902 cat >>confdefs.h <<EOF
17903 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
17911 echo "$as_me:17911: checking definition to turn on extended curses functions" >&5
17912 echo $ECHO_N "checking definition to turn on extended curses functions... $ECHO_C" >&6
17913 if test "${cf_cv_need_xopen_extension+set}" = set; then
17914 echo $ECHO_N "(cached) $ECHO_C" >&6
17917 cf_cv_need_xopen_extension=unknown
17918 cat >conftest.$ac_ext <<_ACEOF
17919 #line 17919 "configure"
17920 #include "confdefs.h"
17922 #include <stdlib.h>
17923 #include <${cf_cv_ncurses_header:-curses.h}>
17928 #if defined(NCURSES_VERSION_PATCH)
17929 #if (NCURSES_VERSION_PATCH < 20100501) && (NCURSES_VERSION_PATCH >= 20100403)
17933 #ifdef NCURSES_VERSION
17935 int check2 = curs_set((int)sizeof(check));
17937 long x = winnstr(stdscr, "", 0);
17939 #ifdef NCURSES_VERSION
17942 getbegyx(stdscr, y1, x1);
17951 rm -f conftest.$ac_objext conftest$ac_exeext
17952 if { (eval echo "$as_me:17952: \"$ac_link\"") >&5
17953 (eval $ac_link) 2>&5
17955 echo "$as_me:17955: \$? = $ac_status" >&5
17956 (exit $ac_status); } &&
17957 { ac_try='test -s conftest$ac_exeext'
17958 { (eval echo "$as_me:17958: \"$ac_try\"") >&5
17959 (eval $ac_try) 2>&5
17961 echo "$as_me:17961: \$? = $ac_status" >&5
17962 (exit $ac_status); }; }; then
17963 cf_cv_need_xopen_extension=none
17965 echo "$as_me: failed program was:" >&5
17966 cat conftest.$ac_ext >&5
17968 for cf_try_xopen_extension in _XOPEN_SOURCE_EXTENDED NCURSES_WIDECHAR
17970 cat >conftest.$ac_ext <<_ACEOF
17971 #line 17971 "configure"
17972 #include "confdefs.h"
17974 #define $cf_try_xopen_extension 1
17975 #include <stdlib.h>
17976 #include <${cf_cv_ncurses_header:-curses.h}>
17981 #ifdef NCURSES_VERSION
17983 int check2 = curs_set((int)sizeof(check));
17985 long x = winnstr(stdscr, "", 0);
17987 getbegyx(stdscr, y1, x1);
17988 #ifdef NCURSES_VERSION
17999 rm -f conftest.$ac_objext conftest$ac_exeext
18000 if { (eval echo "$as_me:18000: \"$ac_link\"") >&5
18001 (eval $ac_link) 2>&5
18003 echo "$as_me:18003: \$? = $ac_status" >&5
18004 (exit $ac_status); } &&
18005 { ac_try='test -s conftest$ac_exeext'
18006 { (eval echo "$as_me:18006: \"$ac_try\"") >&5
18007 (eval $ac_try) 2>&5
18009 echo "$as_me:18009: \$? = $ac_status" >&5
18010 (exit $ac_status); }; }; then
18011 cf_cv_need_xopen_extension=$cf_try_xopen_extension; break
18013 echo "$as_me: failed program was:" >&5
18014 cat conftest.$ac_ext >&5
18016 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18020 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18023 echo "$as_me:18023: result: $cf_cv_need_xopen_extension" >&5
18024 echo "${ECHO_T}$cf_cv_need_xopen_extension" >&6
18026 case $cf_cv_need_xopen_extension in
18029 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
18030 CPPFLAGS="${CPPFLAGS}-D$cf_cv_need_xopen_extension"
18035 echo "$as_me:18035: checking for term.h" >&5
18036 echo $ECHO_N "checking for term.h... $ECHO_C" >&6
18037 if test "${cf_cv_term_header+set}" = set; then
18038 echo $ECHO_N "(cached) $ECHO_C" >&6
18041 # If we found <ncurses/curses.h>, look for <ncurses/term.h>, but always look
18042 # for <term.h> if we do not find the variant.
18044 cf_header_list="term.h ncurses/term.h ncursesw/term.h"
18046 case ${cf_cv_ncurses_header:-curses.h} in
18048 cf_header_item=`echo ${cf_cv_ncurses_header:-curses.h} | sed -e 's%\..*%%' -e 's%/.*%/%'`term.h
18049 cf_header_list="$cf_header_item $cf_header_list"
18053 for cf_header in $cf_header_list
18055 cat >conftest.$ac_ext <<_ACEOF
18056 #line 18056 "configure"
18057 #include "confdefs.h"
18059 #include <${cf_cv_ncurses_header:-curses.h}>
18060 #include <${cf_header}>
18069 rm -f conftest.$ac_objext
18070 if { (eval echo "$as_me:18070: \"$ac_compile\"") >&5
18071 (eval $ac_compile) 2>&5
18073 echo "$as_me:18073: \$? = $ac_status" >&5
18074 (exit $ac_status); } &&
18075 { ac_try='test -s conftest.$ac_objext'
18076 { (eval echo "$as_me:18076: \"$ac_try\"") >&5
18077 (eval $ac_try) 2>&5
18079 echo "$as_me:18079: \$? = $ac_status" >&5
18080 (exit $ac_status); }; }; then
18081 cf_cv_term_header=$cf_header
18084 echo "$as_me: failed program was:" >&5
18085 cat conftest.$ac_ext >&5
18086 cf_cv_term_header=no
18088 rm -f conftest.$ac_objext conftest.$ac_ext
18091 case $cf_cv_term_header in
18093 # If curses is ncurses, some packagers still mess it up by trying to make
18094 # us use GNU termcap. This handles the most common case.
18095 for cf_header in ncurses/term.h ncursesw/term.h
18097 cat >conftest.$ac_ext <<_ACEOF
18098 #line 18098 "configure"
18099 #include "confdefs.h"
18101 #include <${cf_cv_ncurses_header:-curses.h}>
18102 #ifdef NCURSES_VERSION
18103 #include <${cf_header}>
18115 rm -f conftest.$ac_objext
18116 if { (eval echo "$as_me:18116: \"$ac_compile\"") >&5
18117 (eval $ac_compile) 2>&5
18119 echo "$as_me:18119: \$? = $ac_status" >&5
18120 (exit $ac_status); } &&
18121 { ac_try='test -s conftest.$ac_objext'
18122 { (eval echo "$as_me:18122: \"$ac_try\"") >&5
18123 (eval $ac_try) 2>&5
18125 echo "$as_me:18125: \$? = $ac_status" >&5
18126 (exit $ac_status); }; }; then
18127 cf_cv_term_header=$cf_header
18130 echo "$as_me: failed program was:" >&5
18131 cat conftest.$ac_ext >&5
18132 cf_cv_term_header=no
18134 rm -f conftest.$ac_objext conftest.$ac_ext
18140 echo "$as_me:18140: result: $cf_cv_term_header" >&5
18141 echo "${ECHO_T}$cf_cv_term_header" >&6
18143 case $cf_cv_term_header in
18146 cat >>confdefs.h <<\EOF
18147 #define HAVE_TERM_H 1
18153 cat >>confdefs.h <<\EOF
18154 #define HAVE_NCURSES_TERM_H 1
18160 cat >>confdefs.h <<\EOF
18161 #define HAVE_NCURSESW_TERM_H 1
18167 echo "$as_me:18167: checking for unctrl.h" >&5
18168 echo $ECHO_N "checking for unctrl.h... $ECHO_C" >&6
18169 if test "${cf_cv_unctrl_header+set}" = set; then
18170 echo $ECHO_N "(cached) $ECHO_C" >&6
18173 # If we found <ncurses/curses.h>, look for <ncurses/unctrl.h>, but always look
18174 # for <unctrl.h> if we do not find the variant.
18176 cf_header_list="unctrl.h ncurses/unctrl.h ncursesw/unctrl.h"
18178 case ${cf_cv_ncurses_header:-curses.h} in
18180 cf_header_item=`echo ${cf_cv_ncurses_header:-curses.h} | sed -e 's%\..*%%' -e 's%/.*%/%'`unctrl.h
18181 cf_header_list="$cf_header_item $cf_header_list"
18185 for cf_header in $cf_header_list
18187 cat >conftest.$ac_ext <<_ACEOF
18188 #line 18188 "configure"
18189 #include "confdefs.h"
18191 #include <${cf_cv_ncurses_header:-curses.h}>
18192 #include <${cf_header}>
18201 rm -f conftest.$ac_objext
18202 if { (eval echo "$as_me:18202: \"$ac_compile\"") >&5
18203 (eval $ac_compile) 2>&5
18205 echo "$as_me:18205: \$? = $ac_status" >&5
18206 (exit $ac_status); } &&
18207 { ac_try='test -s conftest.$ac_objext'
18208 { (eval echo "$as_me:18208: \"$ac_try\"") >&5
18209 (eval $ac_try) 2>&5
18211 echo "$as_me:18211: \$? = $ac_status" >&5
18212 (exit $ac_status); }; }; then
18213 cf_cv_unctrl_header=$cf_header
18216 echo "$as_me: failed program was:" >&5
18217 cat conftest.$ac_ext >&5
18218 cf_cv_unctrl_header=no
18220 rm -f conftest.$ac_objext conftest.$ac_ext
18224 echo "$as_me:18224: result: $cf_cv_unctrl_header" >&5
18225 echo "${ECHO_T}$cf_cv_unctrl_header" >&6
18227 case $cf_cv_unctrl_header in
18229 { echo "$as_me:18229: WARNING: unctrl.h header not found" >&5
18230 echo "$as_me: WARNING: unctrl.h header not found" >&2;}
18234 case $cf_cv_unctrl_header in
18237 cat >>confdefs.h <<\EOF
18238 #define HAVE_UNCTRL_H 1
18244 cat >>confdefs.h <<\EOF
18245 #define HAVE_NCURSES_UNCTRL_H 1
18249 (ncursesw/unctrl.h)
18251 cat >>confdefs.h <<\EOF
18252 #define HAVE_NCURSESW_UNCTRL_H 1
18260 assume_default_colors \
18277 init_extended_color \
18285 reset_color_pairs \
18301 use_default_colors \
18303 use_extended_names \
18319 cf_tr_func=`echo "$cf_func" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
18321 echo "$as_me:18321: checking for ${cf_func}" >&5
18322 echo $ECHO_N "checking for ${cf_func}... $ECHO_C" >&6
18324 echo "${as_me:-configure}:18324: testing ${cf_func} ..." 1>&5
18326 if eval "test \"\${cf_cv_func_$cf_func+set}\" = set"; then
18327 echo $ECHO_N "(cached) $ECHO_C" >&6
18330 eval cf_result='$ac_cv_func_'$cf_func
18331 if test ".$cf_result" != ".no"; then
18332 cat >conftest.$ac_ext <<_ACEOF
18333 #line 18333 "configure"
18334 #include "confdefs.h"
18336 #ifdef HAVE_XCURSES
18337 #include <xcurses.h>
18338 char * XCursesProgramName = "test";
18340 #include <${cf_cv_ncurses_header:-curses.h}>
18341 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
18342 #include <ncursesw/term.h>
18343 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
18344 #include <ncurses/term.h>
18345 #elif defined(HAVE_TERM_H)
18355 long foo = (long)(&${cf_func});
18356 fprintf(stderr, "testing linkage of $cf_func:%p\n", (void *)foo);
18357 if (foo + 1234L > 5678L)
18358 ${cf_cv_main_return:-return}(foo != 0);
18365 rm -f conftest.$ac_objext conftest$ac_exeext
18366 if { (eval echo "$as_me:18366: \"$ac_link\"") >&5
18367 (eval $ac_link) 2>&5
18369 echo "$as_me:18369: \$? = $ac_status" >&5
18370 (exit $ac_status); } &&
18371 { ac_try='test -s conftest$ac_exeext'
18372 { (eval echo "$as_me:18372: \"$ac_try\"") >&5
18373 (eval $ac_try) 2>&5
18375 echo "$as_me:18375: \$? = $ac_status" >&5
18376 (exit $ac_status); }; }; then
18379 echo "$as_me: failed program was:" >&5
18380 cat conftest.$ac_ext >&5
18383 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18385 eval 'cf_cv_func_'$cf_func'=$cf_result'
18389 # use the computed/retrieved cache-value:
18390 eval 'cf_result=$cf_cv_func_'$cf_func
18391 echo "$as_me:18391: result: $cf_result" >&5
18392 echo "${ECHO_T}$cf_result" >&6
18393 if test $cf_result != no; then
18394 cat >>confdefs.h <<EOF
18395 #define HAVE_${cf_tr_func} 1
18401 for cf_func in tputs
18404 cf_tr_func=`echo "$cf_func" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
18406 echo "$as_me:18406: checking for ${cf_func}" >&5
18407 echo $ECHO_N "checking for ${cf_func}... $ECHO_C" >&6
18409 echo "${as_me:-configure}:18409: testing ${cf_func} ..." 1>&5
18411 if eval "test \"\${cf_cv_func_$cf_func+set}\" = set"; then
18412 echo $ECHO_N "(cached) $ECHO_C" >&6
18415 eval cf_result='$ac_cv_func_'$cf_func
18416 if test ".$cf_result" != ".no"; then
18417 cat >conftest.$ac_ext <<_ACEOF
18418 #line 18418 "configure"
18419 #include "confdefs.h"
18421 #ifdef HAVE_XCURSES
18422 #include <xcurses.h>
18423 char * XCursesProgramName = "test";
18425 #include <${cf_cv_ncurses_header:-curses.h}>
18426 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
18427 #include <ncursesw/term.h>
18428 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
18429 #include <ncurses/term.h>
18430 #elif defined(HAVE_TERM_H)
18440 long foo = (long)(&${cf_func});
18441 fprintf(stderr, "testing linkage of $cf_func:%p\n", (void *)foo);
18442 if (foo + 1234L > 5678L)
18443 ${cf_cv_main_return:-return}(foo != 0);
18450 rm -f conftest.$ac_objext conftest$ac_exeext
18451 if { (eval echo "$as_me:18451: \"$ac_link\"") >&5
18452 (eval $ac_link) 2>&5
18454 echo "$as_me:18454: \$? = $ac_status" >&5
18455 (exit $ac_status); } &&
18456 { ac_try='test -s conftest$ac_exeext'
18457 { (eval echo "$as_me:18457: \"$ac_try\"") >&5
18458 (eval $ac_try) 2>&5
18460 echo "$as_me:18460: \$? = $ac_status" >&5
18461 (exit $ac_status); }; }; then
18464 echo "$as_me: failed program was:" >&5
18465 cat conftest.$ac_ext >&5
18468 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18470 eval 'cf_cv_func_'$cf_func'=$cf_result'
18474 # use the computed/retrieved cache-value:
18475 eval 'cf_result=$cf_cv_func_'$cf_func
18476 echo "$as_me:18476: result: $cf_result" >&5
18477 echo "${ECHO_T}$cf_result" >&6
18478 if test $cf_result != no; then
18479 cat >>confdefs.h <<EOF
18480 #define HAVE_${cf_tr_func} 1
18486 if test x$cf_cv_func_tputs = xyes
18489 for cf_arg in int char
18491 for cf_ret in int void
18493 if test $cf_ret = void
18495 cf_return="/* nothing */"
18497 cf_return="return value"
18499 cat >conftest.$ac_ext <<_ACEOF
18500 #line 18500 "configure"
18501 #include "confdefs.h"
18503 #include <${cf_cv_ncurses_header:-curses.h}>
18504 #include <$cf_cv_term_header>
18506 static $cf_ret outc($cf_arg value) { $cf_return; }
18512 tputs("hello", 0, outc);
18513 ${cf_cv_main_return:-return}(0);
18519 rm -f conftest.$ac_objext
18520 if { (eval echo "$as_me:18520: \"$ac_compile\"") >&5
18521 (eval $ac_compile) 2>&5
18523 echo "$as_me:18523: \$? = $ac_status" >&5
18524 (exit $ac_status); } &&
18525 { ac_try='test -s conftest.$ac_objext'
18526 { (eval echo "$as_me:18526: \"$ac_try\"") >&5
18527 (eval $ac_try) 2>&5
18529 echo "$as_me:18529: \$? = $ac_status" >&5
18530 (exit $ac_status); }; }; then
18532 test -n "$verbose" && echo " prototype $cf_ret func($cf_arg value)" 1>&6
18534 echo "${as_me:-configure}:18534: testing prototype $cf_ret func($cf_arg value) ..." 1>&5
18536 cat >>confdefs.h <<EOF
18537 #define TPUTS_ARG $cf_arg
18538 #define TPUTS_PROTO(func,value) $cf_ret func(TPUTS_ARG value)
18539 #define TPUTS_RETURN(value) $cf_return
18545 echo "$as_me: failed program was:" >&5
18546 cat conftest.$ac_ext >&5
18548 rm -f conftest.$ac_objext conftest.$ac_ext
18550 test $cf_done = yes && break
18554 echo "$as_me:18554: checking for ncurses extended functions" >&5
18555 echo $ECHO_N "checking for ncurses extended functions... $ECHO_C" >&6
18556 if test "${cf_cv_ncurses_ext_funcs+set}" = set; then
18557 echo $ECHO_N "(cached) $ECHO_C" >&6
18560 cat >conftest.$ac_ext <<_ACEOF
18561 #line 18561 "configure"
18562 #include "confdefs.h"
18564 #include <${cf_cv_ncurses_header:-curses.h}>
18569 int x = NCURSES_EXT_FUNCS
18575 rm -f conftest.$ac_objext
18576 if { (eval echo "$as_me:18576: \"$ac_compile\"") >&5
18577 (eval $ac_compile) 2>&5
18579 echo "$as_me:18579: \$? = $ac_status" >&5
18580 (exit $ac_status); } &&
18581 { ac_try='test -s conftest.$ac_objext'
18582 { (eval echo "$as_me:18582: \"$ac_try\"") >&5
18583 (eval $ac_try) 2>&5
18585 echo "$as_me:18585: \$? = $ac_status" >&5
18586 (exit $ac_status); }; }; then
18587 cf_cv_ncurses_ext_funcs=defined
18589 echo "$as_me: failed program was:" >&5
18590 cat conftest.$ac_ext >&5
18592 cat >conftest.$ac_ext <<_ACEOF
18593 #line 18593 "configure"
18594 #include "confdefs.h"
18596 #include <${cf_cv_ncurses_header:-curses.h}>
18601 (void) assume_default_colors (0, 0);
18602 (void) curses_version ();
18603 (void) define_key (0, 0);
18604 (void) is_term_resized (0, 0);
18605 (void) key_defined (0);
18606 (void) keybound (0, 0);
18607 (void) keyok (0, 0);
18608 (void) resize_term (0, 0);
18609 (void) resizeterm (0, 0);
18610 (void) use_default_colors ();
18611 (void) use_extended_names (0);
18612 (void) wresize (0, 0, 0);
18617 rm -f conftest.$ac_objext conftest$ac_exeext
18618 if { (eval echo "$as_me:18618: \"$ac_link\"") >&5
18619 (eval $ac_link) 2>&5
18621 echo "$as_me:18621: \$? = $ac_status" >&5
18622 (exit $ac_status); } &&
18623 { ac_try='test -s conftest$ac_exeext'
18624 { (eval echo "$as_me:18624: \"$ac_try\"") >&5
18625 (eval $ac_try) 2>&5
18627 echo "$as_me:18627: \$? = $ac_status" >&5
18628 (exit $ac_status); }; }; then
18629 cf_cv_ncurses_ext_funcs=yes
18631 echo "$as_me: failed program was:" >&5
18632 cat conftest.$ac_ext >&5
18633 cf_cv_ncurses_ext_funcs=no
18635 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18638 rm -f conftest.$ac_objext conftest.$ac_ext
18641 echo "$as_me:18641: result: $cf_cv_ncurses_ext_funcs" >&5
18642 echo "${ECHO_T}$cf_cv_ncurses_ext_funcs" >&6
18643 test "$cf_cv_ncurses_ext_funcs" = yes &&
18644 cat >>confdefs.h <<\EOF
18645 #define NCURSES_EXT_FUNCS 1
18648 if test "$cf_enable_widec" = yes
18650 # workaround for systems with ncurses before 20111029, due to change of
18651 # feature test macro from _XPG5 to _XOPEN_SOURCE
18652 if test -n "$cf_cv_ncurses_version" && test "x$cf_cv_ncurses_version" != xno
18655 echo "$as_me:18655: checking if _XPG5 should be defined to enable wide-characters" >&5
18656 echo $ECHO_N "checking if _XPG5 should be defined to enable wide-characters... $ECHO_C" >&6
18658 cat >conftest.$ac_ext <<_ACEOF
18659 #line 18659 "configure"
18660 #include "confdefs.h"
18662 #include <${cf_cv_ncurses_header:-curses.h}>
18671 rm -f conftest.$ac_objext
18672 if { (eval echo "$as_me:18672: \"$ac_compile\"") >&5
18673 (eval $ac_compile) 2>&5
18675 echo "$as_me:18675: \$? = $ac_status" >&5
18676 (exit $ac_status); } &&
18677 { ac_try='test -s conftest.$ac_objext'
18678 { (eval echo "$as_me:18678: \"$ac_try\"") >&5
18679 (eval $ac_try) 2>&5
18681 echo "$as_me:18681: \$? = $ac_status" >&5
18682 (exit $ac_status); }; }; then
18685 echo "$as_me: failed program was:" >&5
18686 cat conftest.$ac_ext >&5
18687 cf_save_cppflags="$CPPFLAGS"
18688 CPPFLAGS="$CPPFLAGS -D_XPG5"
18689 cat >conftest.$ac_ext <<_ACEOF
18690 #line 18690 "configure"
18691 #include "confdefs.h"
18693 #include <${cf_cv_ncurses_header:-curses.h}>
18702 rm -f conftest.$ac_objext
18703 if { (eval echo "$as_me:18703: \"$ac_compile\"") >&5
18704 (eval $ac_compile) 2>&5
18706 echo "$as_me:18706: \$? = $ac_status" >&5
18707 (exit $ac_status); } &&
18708 { ac_try='test -s conftest.$ac_objext'
18709 { (eval echo "$as_me:18709: \"$ac_try\"") >&5
18710 (eval $ac_try) 2>&5
18712 echo "$as_me:18712: \$? = $ac_status" >&5
18713 (exit $ac_status); }; }; then
18716 echo "$as_me: failed program was:" >&5
18717 cat conftest.$ac_ext >&5
18719 rm -f conftest.$ac_objext conftest.$ac_ext
18720 CPPFLAGS="$cf_save_cppflags"
18722 rm -f conftest.$ac_objext conftest.$ac_ext
18723 echo "$as_me:18723: result: $cf_define_xpg5" >&5
18724 echo "${ECHO_T}$cf_define_xpg5" >&6
18726 if test "$cf_define_xpg5" = yes
18728 CPPFLAGS="$CPPFLAGS -D_XPG5"
18732 echo "$as_me:18732: checking for wide-character functions" >&5
18733 echo $ECHO_N "checking for wide-character functions... $ECHO_C" >&6
18734 if test "${cf_cv_widechar_funcs+set}" = set; then
18735 echo $ECHO_N "(cached) $ECHO_C" >&6
18738 cat >conftest.$ac_ext <<_ACEOF
18739 #line 18739 "configure"
18740 #include "confdefs.h"
18742 #include <${cf_cv_ncurses_header:-curses.h}>
18747 static wchar_t src_wchar[2];
18748 static cchar_t dst_cchar;
18749 setcchar(&dst_cchar, src_wchar, A_NORMAL, 0, (void *) 0);
18755 rm -f conftest.$ac_objext conftest$ac_exeext
18756 if { (eval echo "$as_me:18756: \"$ac_link\"") >&5
18757 (eval $ac_link) 2>&5
18759 echo "$as_me:18759: \$? = $ac_status" >&5
18760 (exit $ac_status); } &&
18761 { ac_try='test -s conftest$ac_exeext'
18762 { (eval echo "$as_me:18762: \"$ac_try\"") >&5
18763 (eval $ac_try) 2>&5
18765 echo "$as_me:18765: \$? = $ac_status" >&5
18766 (exit $ac_status); }; }; then
18767 cf_cv_widechar_funcs=yes
18769 echo "$as_me: failed program was:" >&5
18770 cat conftest.$ac_ext >&5
18771 cf_cv_widechar_funcs=no
18773 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18776 echo "$as_me:18776: result: $cf_cv_widechar_funcs" >&5
18777 echo "${ECHO_T}$cf_cv_widechar_funcs" >&6
18778 if test "$cf_cv_widechar_funcs" != no ; then
18780 cat >>confdefs.h <<\EOF
18781 #define USE_WIDEC_SUPPORT 1
18785 cat >>confdefs.h <<\EOF
18786 #define USE_WIDEC_SUPPORT 0
18791 cat >>confdefs.h <<\EOF
18792 #define USE_WIDEC_SUPPORT 0
18797 echo "$as_me:18797: checking if $cf_cv_screen library uses pthreads" >&5
18798 echo $ECHO_N "checking if $cf_cv_screen library uses pthreads... $ECHO_C" >&6
18799 if test "${cf_cv_use_pthreads+set}" = set; then
18800 echo $ECHO_N "(cached) $ECHO_C" >&6
18803 cat >conftest.$ac_ext <<_ACEOF
18804 #line 18804 "configure"
18805 #include "confdefs.h"
18807 #include <${cf_cv_ncurses_header:-curses.h}>
18808 extern void _nc_init_pthreads(void);
18815 _nc_init_pthreads();
18821 rm -f conftest.$ac_objext conftest$ac_exeext
18822 if { (eval echo "$as_me:18822: \"$ac_link\"") >&5
18823 (eval $ac_link) 2>&5
18825 echo "$as_me:18825: \$? = $ac_status" >&5
18826 (exit $ac_status); } &&
18827 { ac_try='test -s conftest$ac_exeext'
18828 { (eval echo "$as_me:18828: \"$ac_try\"") >&5
18829 (eval $ac_try) 2>&5
18831 echo "$as_me:18831: \$? = $ac_status" >&5
18832 (exit $ac_status); }; }; then
18833 cf_cv_use_pthreads=yes
18835 echo "$as_me: failed program was:" >&5
18836 cat conftest.$ac_ext >&5
18837 cf_cv_use_pthreads=no
18839 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18842 echo "$as_me:18842: result: $cf_cv_use_pthreads" >&5
18843 echo "${ECHO_T}$cf_cv_use_pthreads" >&6
18844 test $cf_cv_use_pthreads = yes &&
18845 cat >>confdefs.h <<\EOF
18846 #define USE_PTHREADS 1
18849 echo "$as_me:18849: checking if sys/time.h works with sys/select.h" >&5
18850 echo $ECHO_N "checking if sys/time.h works with sys/select.h... $ECHO_C" >&6
18851 if test "${cf_cv_sys_time_select+set}" = set; then
18852 echo $ECHO_N "(cached) $ECHO_C" >&6
18855 cat >conftest.$ac_ext <<_ACEOF
18856 #line 18856 "configure"
18857 #include "confdefs.h"
18859 #include <sys/types.h>
18860 #ifdef HAVE_SYS_TIME_H
18861 #include <sys/time.h>
18863 #ifdef HAVE_SYS_SELECT_H
18864 #include <sys/select.h>
18875 rm -f conftest.$ac_objext
18876 if { (eval echo "$as_me:18876: \"$ac_compile\"") >&5
18877 (eval $ac_compile) 2>&5
18879 echo "$as_me:18879: \$? = $ac_status" >&5
18880 (exit $ac_status); } &&
18881 { ac_try='test -s conftest.$ac_objext'
18882 { (eval echo "$as_me:18882: \"$ac_try\"") >&5
18883 (eval $ac_try) 2>&5
18885 echo "$as_me:18885: \$? = $ac_status" >&5
18886 (exit $ac_status); }; }; then
18887 cf_cv_sys_time_select=yes
18889 echo "$as_me: failed program was:" >&5
18890 cat conftest.$ac_ext >&5
18891 cf_cv_sys_time_select=no
18893 rm -f conftest.$ac_objext conftest.$ac_ext
18897 echo "$as_me:18897: result: $cf_cv_sys_time_select" >&5
18898 echo "${ECHO_T}$cf_cv_sys_time_select" >&6
18899 test "$cf_cv_sys_time_select" = yes &&
18900 cat >>confdefs.h <<\EOF
18901 #define HAVE_SYS_TIME_SELECT 1
18904 # special check for test/ditto.c
18906 echo "$as_me:18906: checking for openpty in -lutil" >&5
18907 echo $ECHO_N "checking for openpty in -lutil... $ECHO_C" >&6
18908 if test "${ac_cv_lib_util_openpty+set}" = set; then
18909 echo $ECHO_N "(cached) $ECHO_C" >&6
18911 ac_check_lib_save_LIBS=$LIBS
18912 LIBS="-lutil $LIBS"
18913 cat >conftest.$ac_ext <<_ACEOF
18914 #line 18914 "configure"
18915 #include "confdefs.h"
18917 /* Override any gcc2 internal prototype to avoid an error. */
18921 /* We use char because int might match the return type of a gcc2
18922 builtin and then its argument prototype would still apply. */
18932 rm -f conftest.$ac_objext conftest$ac_exeext
18933 if { (eval echo "$as_me:18933: \"$ac_link\"") >&5
18934 (eval $ac_link) 2>&5
18936 echo "$as_me:18936: \$? = $ac_status" >&5
18937 (exit $ac_status); } &&
18938 { ac_try='test -s conftest$ac_exeext'
18939 { (eval echo "$as_me:18939: \"$ac_try\"") >&5
18940 (eval $ac_try) 2>&5
18942 echo "$as_me:18942: \$? = $ac_status" >&5
18943 (exit $ac_status); }; }; then
18944 ac_cv_lib_util_openpty=yes
18946 echo "$as_me: failed program was:" >&5
18947 cat conftest.$ac_ext >&5
18948 ac_cv_lib_util_openpty=no
18950 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18951 LIBS=$ac_check_lib_save_LIBS
18953 echo "$as_me:18953: result: $ac_cv_lib_util_openpty" >&5
18954 echo "${ECHO_T}$ac_cv_lib_util_openpty" >&6
18955 if test $ac_cv_lib_util_openpty = yes; then
18961 echo "$as_me:18961: checking for openpty header" >&5
18962 echo $ECHO_N "checking for openpty header... $ECHO_C" >&6
18963 if test "${cf_cv_func_openpty+set}" = set; then
18964 echo $ECHO_N "(cached) $ECHO_C" >&6
18967 cf_save_LIBS="$LIBS"
18968 test $cf_cv_lib_util = yes && {
18969 cf_add_libs="$LIBS"
18972 for cf_add_1lib in -lutil; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
18973 # filter duplicates
18974 for cf_add_1lib in $cf_add_0lib; do
18975 for cf_add_2lib in $cf_add_libs; do
18976 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
18981 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
18983 LIBS="$cf_add_libs"
18985 for cf_header in pty.h libutil.h util.h
18987 cat >conftest.$ac_ext <<_ACEOF
18988 #line 18988 "configure"
18989 #include "confdefs.h"
18991 #include <$cf_header>
18997 int x = openpty((int *)0, (int *)0, (char *)0,
18998 (struct termios *)0, (struct winsize *)0);
19004 rm -f conftest.$ac_objext conftest$ac_exeext
19005 if { (eval echo "$as_me:19005: \"$ac_link\"") >&5
19006 (eval $ac_link) 2>&5
19008 echo "$as_me:19008: \$? = $ac_status" >&5
19009 (exit $ac_status); } &&
19010 { ac_try='test -s conftest$ac_exeext'
19011 { (eval echo "$as_me:19011: \"$ac_try\"") >&5
19012 (eval $ac_try) 2>&5
19014 echo "$as_me:19014: \$? = $ac_status" >&5
19015 (exit $ac_status); }; }; then
19017 cf_cv_func_openpty=$cf_header
19021 echo "$as_me: failed program was:" >&5
19022 cat conftest.$ac_ext >&5
19024 cf_cv_func_openpty=no
19027 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
19029 LIBS="$cf_save_LIBS"
19032 echo "$as_me:19032: result: $cf_cv_func_openpty" >&5
19033 echo "${ECHO_T}$cf_cv_func_openpty" >&6
19035 if test "$cf_cv_func_openpty" != no ; then
19037 cat >>confdefs.h <<EOF
19038 #define USE_OPENPTY_HEADER <$cf_cv_func_openpty>
19041 cat >>confdefs.h <<\EOF
19042 #define USE_XTERM_PTY 1
19045 if test "x$cf_cv_lib_util" = xyes ; then
19047 cf_add_libs="$TEST_LIBS"
19050 for cf_add_1lib in -lutil; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
19051 # filter duplicates
19052 for cf_add_1lib in $cf_add_0lib; do
19053 for cf_add_2lib in $cf_add_libs; do
19054 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
19059 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
19061 TEST_LIBS="$cf_add_libs"
19066 echo "$as_me:19066: checking for function curses_version" >&5
19067 echo $ECHO_N "checking for function curses_version... $ECHO_C" >&6
19068 if test "${cf_cv_func_curses_version+set}" = set; then
19069 echo $ECHO_N "(cached) $ECHO_C" >&6
19072 if test "$cross_compiling" = yes; then
19073 cf_cv_func_curses_version=unknown
19075 cat >conftest.$ac_ext <<_ACEOF
19076 #line 19076 "configure"
19077 #include "confdefs.h"
19079 #include <${cf_cv_ncurses_header:-curses.h}>
19083 sprintf(temp, "%s\n", curses_version());
19084 ${cf_cv_main_return:-return}(0);
19088 rm -f conftest$ac_exeext
19089 if { (eval echo "$as_me:19089: \"$ac_link\"") >&5
19090 (eval $ac_link) 2>&5
19092 echo "$as_me:19092: \$? = $ac_status" >&5
19093 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19094 { (eval echo "$as_me:19094: \"$ac_try\"") >&5
19095 (eval $ac_try) 2>&5
19097 echo "$as_me:19097: \$? = $ac_status" >&5
19098 (exit $ac_status); }; }; then
19099 cf_cv_func_curses_version=yes
19102 echo "$as_me: program exited with status $ac_status" >&5
19103 echo "$as_me: failed program was:" >&5
19104 cat conftest.$ac_ext >&5
19105 cf_cv_func_curses_version=no
19108 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19112 echo "$as_me:19112: result: $cf_cv_func_curses_version" >&5
19113 echo "${ECHO_T}$cf_cv_func_curses_version" >&6
19114 test "$cf_cv_func_curses_version" = yes &&
19115 cat >>confdefs.h <<\EOF
19116 #define HAVE_CURSES_VERSION 1
19119 echo "$as_me:19119: checking for alternate character set array" >&5
19120 echo $ECHO_N "checking for alternate character set array... $ECHO_C" >&6
19121 if test "${cf_cv_curses_acs_map+set}" = set; then
19122 echo $ECHO_N "(cached) $ECHO_C" >&6
19125 cf_cv_curses_acs_map=unknown
19126 for name in acs_map _acs_map __acs_map ${NCURSES_WRAP_PREFIX}acs_map
19128 cat >conftest.$ac_ext <<_ACEOF
19129 #line 19129 "configure"
19130 #include "confdefs.h"
19132 #include <${cf_cv_ncurses_header:-curses.h}>
19138 $name['k'] = ACS_PLUS
19144 rm -f conftest.$ac_objext conftest$ac_exeext
19145 if { (eval echo "$as_me:19145: \"$ac_link\"") >&5
19146 (eval $ac_link) 2>&5
19148 echo "$as_me:19148: \$? = $ac_status" >&5
19149 (exit $ac_status); } &&
19150 { ac_try='test -s conftest$ac_exeext'
19151 { (eval echo "$as_me:19151: \"$ac_try\"") >&5
19152 (eval $ac_try) 2>&5
19154 echo "$as_me:19154: \$? = $ac_status" >&5
19155 (exit $ac_status); }; }; then
19156 cf_cv_curses_acs_map=$name; break
19158 echo "$as_me: failed program was:" >&5
19159 cat conftest.$ac_ext >&5
19161 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
19165 echo "$as_me:19165: result: $cf_cv_curses_acs_map" >&5
19166 echo "${ECHO_T}$cf_cv_curses_acs_map" >&6
19168 test "$cf_cv_curses_acs_map" != unknown &&
19169 cat >>confdefs.h <<EOF
19170 #define CURSES_ACS_ARRAY $cf_cv_curses_acs_map
19173 if test "$cf_enable_widec" = yes; then
19175 echo "$as_me:19175: checking for wide alternate character set array" >&5
19176 echo $ECHO_N "checking for wide alternate character set array... $ECHO_C" >&6
19177 if test "${cf_cv_curses_wacs_map+set}" = set; then
19178 echo $ECHO_N "(cached) $ECHO_C" >&6
19181 cf_cv_curses_wacs_map=unknown
19182 for name in wacs_map _wacs_map __wacs_map _nc_wacs _wacs_char
19184 cat >conftest.$ac_ext <<_ACEOF
19185 #line 19185 "configure"
19186 #include "confdefs.h"
19188 #ifndef _XOPEN_SOURCE_EXTENDED
19189 #define _XOPEN_SOURCE_EXTENDED
19191 #include <${cf_cv_ncurses_header:-curses.h}>
19195 void *foo = &($name['k']); (void)foo
19200 rm -f conftest.$ac_objext conftest$ac_exeext
19201 if { (eval echo "$as_me:19201: \"$ac_link\"") >&5
19202 (eval $ac_link) 2>&5
19204 echo "$as_me:19204: \$? = $ac_status" >&5
19205 (exit $ac_status); } &&
19206 { ac_try='test -s conftest$ac_exeext'
19207 { (eval echo "$as_me:19207: \"$ac_try\"") >&5
19208 (eval $ac_try) 2>&5
19210 echo "$as_me:19210: \$? = $ac_status" >&5
19211 (exit $ac_status); }; }; then
19212 cf_cv_curses_wacs_map=$name
19215 echo "$as_me: failed program was:" >&5
19216 cat conftest.$ac_ext >&5
19218 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
19221 echo "$as_me:19221: result: $cf_cv_curses_wacs_map" >&5
19222 echo "${ECHO_T}$cf_cv_curses_wacs_map" >&6
19224 test "$cf_cv_curses_wacs_map" != unknown &&
19225 cat >>confdefs.h <<EOF
19226 #define CURSES_WACS_ARRAY $cf_cv_curses_wacs_map
19229 echo "$as_me:19229: checking for wide alternate character constants" >&5
19230 echo $ECHO_N "checking for wide alternate character constants... $ECHO_C" >&6
19231 if test "${cf_cv_curses_wacs_symbols+set}" = set; then
19232 echo $ECHO_N "(cached) $ECHO_C" >&6
19235 cf_cv_curses_wacs_symbols=no
19236 if test "$cf_cv_curses_wacs_map" != unknown
19238 cat >conftest.$ac_ext <<_ACEOF
19239 #line 19239 "configure"
19240 #include "confdefs.h"
19242 #ifndef _XOPEN_SOURCE_EXTENDED
19243 #define _XOPEN_SOURCE_EXTENDED
19245 #include <${cf_cv_ncurses_header:-curses.h}>
19249 cchar_t *foo = WACS_PLUS;
19250 $cf_cv_curses_wacs_map['k'] = *WACS_PLUS; (void)foo
19255 rm -f conftest.$ac_objext conftest$ac_exeext
19256 if { (eval echo "$as_me:19256: \"$ac_link\"") >&5
19257 (eval $ac_link) 2>&5
19259 echo "$as_me:19259: \$? = $ac_status" >&5
19260 (exit $ac_status); } &&
19261 { ac_try='test -s conftest$ac_exeext'
19262 { (eval echo "$as_me:19262: \"$ac_try\"") >&5
19263 (eval $ac_try) 2>&5
19265 echo "$as_me:19265: \$? = $ac_status" >&5
19266 (exit $ac_status); }; }; then
19267 cf_cv_curses_wacs_symbols=yes
19269 echo "$as_me: failed program was:" >&5
19270 cat conftest.$ac_ext >&5
19272 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
19274 cat >conftest.$ac_ext <<_ACEOF
19275 #line 19275 "configure"
19276 #include "confdefs.h"
19278 #ifndef _XOPEN_SOURCE_EXTENDED
19279 #define _XOPEN_SOURCE_EXTENDED
19281 #include <${cf_cv_ncurses_header:-curses.h}>
19285 cchar_t *foo = WACS_PLUS; (void)foo
19290 rm -f conftest.$ac_objext conftest$ac_exeext
19291 if { (eval echo "$as_me:19291: \"$ac_link\"") >&5
19292 (eval $ac_link) 2>&5
19294 echo "$as_me:19294: \$? = $ac_status" >&5
19295 (exit $ac_status); } &&
19296 { ac_try='test -s conftest$ac_exeext'
19297 { (eval echo "$as_me:19297: \"$ac_try\"") >&5
19298 (eval $ac_try) 2>&5
19300 echo "$as_me:19300: \$? = $ac_status" >&5
19301 (exit $ac_status); }; }; then
19302 cf_cv_curses_wacs_symbols=yes
19304 echo "$as_me: failed program was:" >&5
19305 cat conftest.$ac_ext >&5
19307 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
19311 echo "$as_me:19311: result: $cf_cv_curses_wacs_symbols" >&5
19312 echo "${ECHO_T}$cf_cv_curses_wacs_symbols" >&6
19314 test "$cf_cv_curses_wacs_symbols" != no &&
19315 cat >>confdefs.h <<\EOF
19316 #define CURSES_WACS_SYMBOLS 1
19321 echo "$as_me:19321: checking for type attr_t in ${cf_cv_ncurses_header:-curses.h}" >&5
19322 echo $ECHO_N "checking for type attr_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
19323 cat >conftest.$ac_ext <<_ACEOF
19324 #line 19324 "configure"
19325 #include "confdefs.h"
19327 #ifndef _XOPEN_SOURCE_EXTENDED
19328 #define _XOPEN_SOURCE_EXTENDED
19330 #include <${cf_cv_ncurses_header:-curses.h}>
19341 rm -f conftest.$ac_objext
19342 if { (eval echo "$as_me:19342: \"$ac_compile\"") >&5
19343 (eval $ac_compile) 2>&5
19345 echo "$as_me:19345: \$? = $ac_status" >&5
19346 (exit $ac_status); } &&
19347 { ac_try='test -s conftest.$ac_objext'
19348 { (eval echo "$as_me:19348: \"$ac_try\"") >&5
19349 (eval $ac_try) 2>&5
19351 echo "$as_me:19351: \$? = $ac_status" >&5
19352 (exit $ac_status); }; }; then
19355 echo "$as_me: failed program was:" >&5
19356 cat conftest.$ac_ext >&5
19359 rm -f conftest.$ac_objext conftest.$ac_ext
19360 echo "$as_me:19360: result: $cf_result" >&5
19361 echo "${ECHO_T}$cf_result" >&6
19362 if test $cf_result = yes ; then
19364 cf_result=`echo "have_type_attr_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
19366 cat >>confdefs.h <<EOF
19367 #define $cf_result 1
19372 cat >>confdefs.h <<EOF
19373 #define attr_t long
19378 if test "$cf_enable_widec" = yes; then
19380 # This is needed on Tru64 5.0 to declare mbstate_t
19381 echo "$as_me:19381: checking if we must include wchar.h to declare mbstate_t" >&5
19382 echo $ECHO_N "checking if we must include wchar.h to declare mbstate_t... $ECHO_C" >&6
19383 if test "${cf_cv_mbstate_t+set}" = set; then
19384 echo $ECHO_N "(cached) $ECHO_C" >&6
19387 cat >conftest.$ac_ext <<_ACEOF
19388 #line 19388 "configure"
19389 #include "confdefs.h"
19391 #include <stdlib.h>
19392 #include <stdarg.h>
19394 #ifdef HAVE_LIBUTF8_H
19395 #include <libutf8.h>
19405 rm -f conftest.$ac_objext
19406 if { (eval echo "$as_me:19406: \"$ac_compile\"") >&5
19407 (eval $ac_compile) 2>&5
19409 echo "$as_me:19409: \$? = $ac_status" >&5
19410 (exit $ac_status); } &&
19411 { ac_try='test -s conftest.$ac_objext'
19412 { (eval echo "$as_me:19412: \"$ac_try\"") >&5
19413 (eval $ac_try) 2>&5
19415 echo "$as_me:19415: \$? = $ac_status" >&5
19416 (exit $ac_status); }; }; then
19419 echo "$as_me: failed program was:" >&5
19420 cat conftest.$ac_ext >&5
19421 cat >conftest.$ac_ext <<_ACEOF
19422 #line 19422 "configure"
19423 #include "confdefs.h"
19425 #include <stdlib.h>
19426 #include <stdarg.h>
19429 #ifdef HAVE_LIBUTF8_H
19430 #include <libutf8.h>
19440 rm -f conftest.$ac_objext
19441 if { (eval echo "$as_me:19441: \"$ac_compile\"") >&5
19442 (eval $ac_compile) 2>&5
19444 echo "$as_me:19444: \$? = $ac_status" >&5
19445 (exit $ac_status); } &&
19446 { ac_try='test -s conftest.$ac_objext'
19447 { (eval echo "$as_me:19447: \"$ac_try\"") >&5
19448 (eval $ac_try) 2>&5
19450 echo "$as_me:19450: \$? = $ac_status" >&5
19451 (exit $ac_status); }; }; then
19452 cf_cv_mbstate_t=yes
19454 echo "$as_me: failed program was:" >&5
19455 cat conftest.$ac_ext >&5
19456 cf_cv_mbstate_t=unknown
19458 rm -f conftest.$ac_objext conftest.$ac_ext
19460 rm -f conftest.$ac_objext conftest.$ac_ext
19462 echo "$as_me:19462: result: $cf_cv_mbstate_t" >&5
19463 echo "${ECHO_T}$cf_cv_mbstate_t" >&6
19465 if test "$cf_cv_mbstate_t" = yes ; then
19467 cat >>confdefs.h <<\EOF
19468 #define NEED_WCHAR_H 1
19474 # if we do not find mbstate_t in either place, use substitution to provide a fallback.
19475 if test "$cf_cv_mbstate_t" = unknown ; then
19476 NCURSES_MBSTATE_T=1
19479 # if we find mbstate_t in either place, use substitution to provide a fallback.
19480 if test "$cf_cv_mbstate_t" != unknown ; then
19481 NCURSES_OK_MBSTATE_T=1
19484 # This is needed on Tru64 5.0 to declare wchar_t
19485 echo "$as_me:19485: checking if we must include wchar.h to declare wchar_t" >&5
19486 echo $ECHO_N "checking if we must include wchar.h to declare wchar_t... $ECHO_C" >&6
19487 if test "${cf_cv_wchar_t+set}" = set; then
19488 echo $ECHO_N "(cached) $ECHO_C" >&6
19491 cat >conftest.$ac_ext <<_ACEOF
19492 #line 19492 "configure"
19493 #include "confdefs.h"
19495 #include <stdlib.h>
19496 #include <stdarg.h>
19498 #ifdef HAVE_LIBUTF8_H
19499 #include <libutf8.h>
19509 rm -f conftest.$ac_objext
19510 if { (eval echo "$as_me:19510: \"$ac_compile\"") >&5
19511 (eval $ac_compile) 2>&5
19513 echo "$as_me:19513: \$? = $ac_status" >&5
19514 (exit $ac_status); } &&
19515 { ac_try='test -s conftest.$ac_objext'
19516 { (eval echo "$as_me:19516: \"$ac_try\"") >&5
19517 (eval $ac_try) 2>&5
19519 echo "$as_me:19519: \$? = $ac_status" >&5
19520 (exit $ac_status); }; }; then
19523 echo "$as_me: failed program was:" >&5
19524 cat conftest.$ac_ext >&5
19525 cat >conftest.$ac_ext <<_ACEOF
19526 #line 19526 "configure"
19527 #include "confdefs.h"
19529 #include <stdlib.h>
19530 #include <stdarg.h>
19533 #ifdef HAVE_LIBUTF8_H
19534 #include <libutf8.h>
19544 rm -f conftest.$ac_objext
19545 if { (eval echo "$as_me:19545: \"$ac_compile\"") >&5
19546 (eval $ac_compile) 2>&5
19548 echo "$as_me:19548: \$? = $ac_status" >&5
19549 (exit $ac_status); } &&
19550 { ac_try='test -s conftest.$ac_objext'
19551 { (eval echo "$as_me:19551: \"$ac_try\"") >&5
19552 (eval $ac_try) 2>&5
19554 echo "$as_me:19554: \$? = $ac_status" >&5
19555 (exit $ac_status); }; }; then
19558 echo "$as_me: failed program was:" >&5
19559 cat conftest.$ac_ext >&5
19560 cf_cv_wchar_t=unknown
19562 rm -f conftest.$ac_objext conftest.$ac_ext
19564 rm -f conftest.$ac_objext conftest.$ac_ext
19566 echo "$as_me:19566: result: $cf_cv_wchar_t" >&5
19567 echo "${ECHO_T}$cf_cv_wchar_t" >&6
19569 if test "$cf_cv_wchar_t" = yes ; then
19571 cat >>confdefs.h <<\EOF
19572 #define NEED_WCHAR_H 1
19578 # if we do not find wchar_t in either place, use substitution to provide a fallback.
19579 if test "$cf_cv_wchar_t" = unknown ; then
19583 # if we find wchar_t in either place, use substitution to provide a fallback.
19584 if test "$cf_cv_wchar_t" != unknown ; then
19585 NCURSES_OK_WCHAR_T=1
19588 # This is needed on Tru64 5.0 to declare wint_t
19589 echo "$as_me:19589: checking if we must include wchar.h to declare wint_t" >&5
19590 echo $ECHO_N "checking if we must include wchar.h to declare wint_t... $ECHO_C" >&6
19591 if test "${cf_cv_wint_t+set}" = set; then
19592 echo $ECHO_N "(cached) $ECHO_C" >&6
19595 cat >conftest.$ac_ext <<_ACEOF
19596 #line 19596 "configure"
19597 #include "confdefs.h"
19599 #include <stdlib.h>
19600 #include <stdarg.h>
19602 #ifdef HAVE_LIBUTF8_H
19603 #include <libutf8.h>
19613 rm -f conftest.$ac_objext
19614 if { (eval echo "$as_me:19614: \"$ac_compile\"") >&5
19615 (eval $ac_compile) 2>&5
19617 echo "$as_me:19617: \$? = $ac_status" >&5
19618 (exit $ac_status); } &&
19619 { ac_try='test -s conftest.$ac_objext'
19620 { (eval echo "$as_me:19620: \"$ac_try\"") >&5
19621 (eval $ac_try) 2>&5
19623 echo "$as_me:19623: \$? = $ac_status" >&5
19624 (exit $ac_status); }; }; then
19627 echo "$as_me: failed program was:" >&5
19628 cat conftest.$ac_ext >&5
19629 cat >conftest.$ac_ext <<_ACEOF
19630 #line 19630 "configure"
19631 #include "confdefs.h"
19633 #include <stdlib.h>
19634 #include <stdarg.h>
19637 #ifdef HAVE_LIBUTF8_H
19638 #include <libutf8.h>
19648 rm -f conftest.$ac_objext
19649 if { (eval echo "$as_me:19649: \"$ac_compile\"") >&5
19650 (eval $ac_compile) 2>&5
19652 echo "$as_me:19652: \$? = $ac_status" >&5
19653 (exit $ac_status); } &&
19654 { ac_try='test -s conftest.$ac_objext'
19655 { (eval echo "$as_me:19655: \"$ac_try\"") >&5
19656 (eval $ac_try) 2>&5
19658 echo "$as_me:19658: \$? = $ac_status" >&5
19659 (exit $ac_status); }; }; then
19662 echo "$as_me: failed program was:" >&5
19663 cat conftest.$ac_ext >&5
19664 cf_cv_wint_t=unknown
19666 rm -f conftest.$ac_objext conftest.$ac_ext
19668 rm -f conftest.$ac_objext conftest.$ac_ext
19670 echo "$as_me:19670: result: $cf_cv_wint_t" >&5
19671 echo "${ECHO_T}$cf_cv_wint_t" >&6
19673 if test "$cf_cv_wint_t" = yes ; then
19675 cat >>confdefs.h <<\EOF
19676 #define NEED_WCHAR_H 1
19682 # if we do not find wint_t in either place, use substitution to provide a fallback.
19683 if test "$cf_cv_wint_t" = unknown ; then
19687 # if we find wint_t in either place, use substitution to provide a fallback.
19688 if test "$cf_cv_wint_t" != unknown ; then
19689 NCURSES_OK_WINT_T=1
19692 if test "$NCURSES_OK_MBSTATE_T" = 0 ; then
19694 echo "$as_me:19694: checking for type mbstate_t in ${cf_cv_ncurses_header:-curses.h}" >&5
19695 echo $ECHO_N "checking for type mbstate_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
19696 cat >conftest.$ac_ext <<_ACEOF
19697 #line 19697 "configure"
19698 #include "confdefs.h"
19700 #ifndef _XOPEN_SOURCE_EXTENDED
19701 #define _XOPEN_SOURCE_EXTENDED
19703 #include <${cf_cv_ncurses_header:-curses.h}>
19714 rm -f conftest.$ac_objext
19715 if { (eval echo "$as_me:19715: \"$ac_compile\"") >&5
19716 (eval $ac_compile) 2>&5
19718 echo "$as_me:19718: \$? = $ac_status" >&5
19719 (exit $ac_status); } &&
19720 { ac_try='test -s conftest.$ac_objext'
19721 { (eval echo "$as_me:19721: \"$ac_try\"") >&5
19722 (eval $ac_try) 2>&5
19724 echo "$as_me:19724: \$? = $ac_status" >&5
19725 (exit $ac_status); }; }; then
19728 echo "$as_me: failed program was:" >&5
19729 cat conftest.$ac_ext >&5
19732 rm -f conftest.$ac_objext conftest.$ac_ext
19733 echo "$as_me:19733: result: $cf_result" >&5
19734 echo "${ECHO_T}$cf_result" >&6
19735 if test $cf_result = yes ; then
19737 cf_result=`echo "have_type_mbstate_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
19739 cat >>confdefs.h <<EOF
19740 #define $cf_result 1
19745 cat >>confdefs.h <<EOF
19746 #define mbstate_t long
19753 if test "$NCURSES_OK_WCHAR_T" = 0 ; then
19755 echo "$as_me:19755: checking for type wchar_t in ${cf_cv_ncurses_header:-curses.h}" >&5
19756 echo $ECHO_N "checking for type wchar_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
19757 cat >conftest.$ac_ext <<_ACEOF
19758 #line 19758 "configure"
19759 #include "confdefs.h"
19761 #ifndef _XOPEN_SOURCE_EXTENDED
19762 #define _XOPEN_SOURCE_EXTENDED
19764 #include <${cf_cv_ncurses_header:-curses.h}>
19775 rm -f conftest.$ac_objext
19776 if { (eval echo "$as_me:19776: \"$ac_compile\"") >&5
19777 (eval $ac_compile) 2>&5
19779 echo "$as_me:19779: \$? = $ac_status" >&5
19780 (exit $ac_status); } &&
19781 { ac_try='test -s conftest.$ac_objext'
19782 { (eval echo "$as_me:19782: \"$ac_try\"") >&5
19783 (eval $ac_try) 2>&5
19785 echo "$as_me:19785: \$? = $ac_status" >&5
19786 (exit $ac_status); }; }; then
19789 echo "$as_me: failed program was:" >&5
19790 cat conftest.$ac_ext >&5
19793 rm -f conftest.$ac_objext conftest.$ac_ext
19794 echo "$as_me:19794: result: $cf_result" >&5
19795 echo "${ECHO_T}$cf_result" >&6
19796 if test $cf_result = yes ; then
19798 cf_result=`echo "have_type_wchar_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
19800 cat >>confdefs.h <<EOF
19801 #define $cf_result 1
19806 cat >>confdefs.h <<EOF
19807 #define wchar_t long
19814 if test "$NCURSES_OK_WINT_T" = 0 ; then
19816 echo "$as_me:19816: checking for type wint_t in ${cf_cv_ncurses_header:-curses.h}" >&5
19817 echo $ECHO_N "checking for type wint_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
19818 cat >conftest.$ac_ext <<_ACEOF
19819 #line 19819 "configure"
19820 #include "confdefs.h"
19822 #ifndef _XOPEN_SOURCE_EXTENDED
19823 #define _XOPEN_SOURCE_EXTENDED
19825 #include <${cf_cv_ncurses_header:-curses.h}>
19836 rm -f conftest.$ac_objext
19837 if { (eval echo "$as_me:19837: \"$ac_compile\"") >&5
19838 (eval $ac_compile) 2>&5
19840 echo "$as_me:19840: \$? = $ac_status" >&5
19841 (exit $ac_status); } &&
19842 { ac_try='test -s conftest.$ac_objext'
19843 { (eval echo "$as_me:19843: \"$ac_try\"") >&5
19844 (eval $ac_try) 2>&5
19846 echo "$as_me:19846: \$? = $ac_status" >&5
19847 (exit $ac_status); }; }; then
19850 echo "$as_me: failed program was:" >&5
19851 cat conftest.$ac_ext >&5
19854 rm -f conftest.$ac_objext conftest.$ac_ext
19855 echo "$as_me:19855: result: $cf_result" >&5
19856 echo "${ECHO_T}$cf_result" >&6
19857 if test $cf_result = yes ; then
19859 cf_result=`echo "have_type_wint_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
19861 cat >>confdefs.h <<EOF
19862 #define $cf_result 1
19867 cat >>confdefs.h <<EOF
19868 #define wint_t long
19884 echo "$as_me:19884: checking for data $cf_data declaration in ${cf_cv_ncurses_header:-curses.h}" >&5
19885 echo $ECHO_N "checking for data $cf_data declaration in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
19887 cat >conftest.$ac_ext <<_ACEOF
19888 #line 19888 "configure"
19889 #include "confdefs.h"
19891 #ifdef HAVE_XCURSES
19892 #include <xcurses.h>
19893 char * XCursesProgramName = "test";
19895 #include <${cf_cv_ncurses_header:-curses.h}>
19896 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
19897 #include <ncursesw/term.h>
19898 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
19899 #include <ncurses/term.h>
19900 #elif defined(HAVE_TERM_H)
19909 #if defined($cf_data) && ((defined(NCURSES_WRAPPED_VAR) && (NCURSES_VERSION_PATCH < 20200208)) || defined(NCURSES_BROKEN_LINKER) || defined(NCURSES_REENTRANT))
19910 const void *foo = (const void *)($cf_data);
19912 const void *foo = &($cf_data);
19914 fprintf(stderr, "testing linkage of $cf_data:%p\n", (const void *)foo);
19920 rm -f conftest.$ac_objext
19921 if { (eval echo "$as_me:19921: \"$ac_compile\"") >&5
19922 (eval $ac_compile) 2>&5
19924 echo "$as_me:19924: \$? = $ac_status" >&5
19925 (exit $ac_status); } &&
19926 { ac_try='test -s conftest.$ac_objext'
19927 { (eval echo "$as_me:19927: \"$ac_try\"") >&5
19928 (eval $ac_try) 2>&5
19930 echo "$as_me:19930: \$? = $ac_status" >&5
19931 (exit $ac_status); }; }; then
19935 echo "$as_me: failed program was:" >&5
19936 cat conftest.$ac_ext >&5
19939 rm -f conftest.$ac_objext conftest.$ac_ext
19940 echo "$as_me:19940: result: $cf_result" >&5
19941 echo "${ECHO_T}$cf_result" >&6
19943 if test $cf_result = yes ; then
19945 cf_result=`echo "have_curses_data_$cf_data" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
19947 cat >>confdefs.h <<EOF
19948 #define $cf_result 1
19952 echo "$as_me:19952: checking for data $cf_data in library" >&5
19953 echo $ECHO_N "checking for data $cf_data in library... $ECHO_C" >&6
19954 # BSD linkers insist on making weak linkage, but resolve at runtime.
19955 if test "$cross_compiling" = yes; then
19958 cat >conftest.$ac_ext <<_ACEOF
19959 #line 19959 "configure"
19960 #include "confdefs.h"
19962 #ifdef HAVE_XCURSES
19963 #include <xcurses.h>
19964 char * XCursesProgramName = "test";
19966 #include <${cf_cv_ncurses_header:-curses.h}>
19967 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
19968 #include <ncursesw/term.h>
19969 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
19970 #include <ncurses/term.h>
19971 #elif defined(HAVE_TERM_H)
19976 extern char $cf_data;
19983 #if defined($cf_data) && ((defined(NCURSES_WRAPPED_VAR) && (NCURSES_VERSION_PATCH < 20200208)) || defined(NCURSES_BROKEN_LINKER) || defined(NCURSES_REENTRANT))
19984 const void *foo = (const void *)($cf_data);
19986 const void *foo = &($cf_data);
19988 fprintf(stderr, "testing linkage of $cf_data:%p\n", (const void *)foo);
19990 ${cf_cv_main_return:-return}(foo == 0);
19997 rm -f conftest.$ac_objext conftest$ac_exeext
19998 if { (eval echo "$as_me:19998: \"$ac_link\"") >&5
19999 (eval $ac_link) 2>&5
20001 echo "$as_me:20001: \$? = $ac_status" >&5
20002 (exit $ac_status); } &&
20003 { ac_try='test -s conftest$ac_exeext'
20004 { (eval echo "$as_me:20004: \"$ac_try\"") >&5
20005 (eval $ac_try) 2>&5
20007 echo "$as_me:20007: \$? = $ac_status" >&5
20008 (exit $ac_status); }; }; then
20011 echo "$as_me: failed program was:" >&5
20012 cat conftest.$ac_ext >&5
20015 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20018 cat >conftest.$ac_ext <<_ACEOF
20019 #line 20019 "configure"
20020 #include "confdefs.h"
20022 #ifdef HAVE_XCURSES
20023 #include <xcurses.h>
20024 char * XCursesProgramName = "test";
20026 #include <${cf_cv_ncurses_header:-curses.h}>
20027 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
20028 #include <ncursesw/term.h>
20029 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
20030 #include <ncurses/term.h>
20031 #elif defined(HAVE_TERM_H)
20036 extern char $cf_data;
20040 #if defined($cf_data) && ((defined(NCURSES_WRAPPED_VAR) && (NCURSES_VERSION_PATCH < 20200208)) || defined(NCURSES_BROKEN_LINKER) || defined(NCURSES_REENTRANT))
20041 const void *foo = (const void *)($cf_data);
20043 const void *foo = &($cf_data);
20045 fprintf(stderr, "testing linkage of $cf_data:%p\n", (const void *)foo);
20047 ${cf_cv_main_return:-return}(foo == 0);
20050 rm -f conftest$ac_exeext
20051 if { (eval echo "$as_me:20051: \"$ac_link\"") >&5
20052 (eval $ac_link) 2>&5
20054 echo "$as_me:20054: \$? = $ac_status" >&5
20055 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20056 { (eval echo "$as_me:20056: \"$ac_try\"") >&5
20057 (eval $ac_try) 2>&5
20059 echo "$as_me:20059: \$? = $ac_status" >&5
20060 (exit $ac_status); }; }; then
20064 echo "$as_me: program exited with status $ac_status" >&5
20065 echo "$as_me: failed program was:" >&5
20066 cat conftest.$ac_ext >&5
20069 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20071 echo "$as_me:20071: result: $cf_result" >&5
20072 echo "${ECHO_T}$cf_result" >&6
20073 if test $cf_result = yes ; then
20075 cf_result=`echo "decl_curses_data_$cf_data" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
20077 cat >>confdefs.h <<EOF
20078 #define $cf_result 1
20081 # do not exit loop here, since we prefer system's declarations
20086 if test -n "$with_screen" && test "x$with_screen" = "xpdcurses"
20088 echo "$as_me:20088: checking for X" >&5
20089 echo $ECHO_N "checking for X... $ECHO_C" >&6
20091 # Check whether --with-x or --without-x was given.
20092 if test "${with_x+set}" = set; then
20096 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
20097 if test "x$with_x" = xno; then
20098 # The user explicitly disabled X.
20101 if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
20102 # Both variables are already set.
20105 if test "${ac_cv_have_x+set}" = set; then
20106 echo $ECHO_N "(cached) $ECHO_C" >&6
20108 # One or both of the vars are not set, and there is no cached value.
20109 ac_x_includes=no ac_x_libraries=no
20110 rm -fr conftest.dir
20111 if mkdir conftest.dir; then
20113 # Make sure to not put "make" in the Imakefile rules, since we grep it out.
20114 cat >Imakefile <<'EOF'
20116 @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
20118 if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
20119 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
20120 eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
20121 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
20122 for ac_extension in a so sl dylib dll; do
20123 if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
20124 test -f $ac_im_libdir/libX11.$ac_extension; then
20125 ac_im_usrlibdir=$ac_im_libdir; break
20128 # Screen out bogus values from the imake configuration. They are
20129 # bogus both because they are the default anyway, and because
20130 # using them would break gcc on systems where it needs fixed includes.
20131 case $ac_im_incroot in
20133 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
20135 case $ac_im_usrlibdir in
20136 /usr/lib | /lib) ;;
20137 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
20141 rm -fr conftest.dir
20144 # Standard set of common directories for X headers.
20145 # Check X11 before X11Rn because it is often a symlink to the current release.
20162 /usr/local/X11/include
20163 /usr/local/X11R7/include
20164 /usr/local/X11R6/include
20165 /usr/local/X11R5/include
20166 /usr/local/X11R4/include
20168 /usr/local/include/X11
20169 /usr/local/include/X11R7
20170 /usr/local/include/X11R6
20171 /usr/local/include/X11R5
20172 /usr/local/include/X11R4
20176 /usr/XFree86/include/X11
20180 /usr/unsupported/include
20181 /usr/athena/include
20182 /usr/local/x11r5/include
20183 /usr/lpp/Xamples/include
20185 /usr/openwin/include
20186 /usr/openwin/share/include'
20188 if test "$ac_x_includes" = no; then
20189 # Guess where to find include files, by looking for Intrinsic.h.
20190 # First, try using that file with no special directory specified.
20191 cat >conftest.$ac_ext <<_ACEOF
20192 #line 20192 "configure"
20193 #include "confdefs.h"
20194 #include <X11/Intrinsic.h>
20196 if { (eval echo "$as_me:20196: \"$ac_cpp conftest.$ac_ext\"") >&5
20197 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
20199 egrep -v '^ *\+' conftest.er1 >conftest.err
20201 cat conftest.err >&5
20202 echo "$as_me:20202: \$? = $ac_status" >&5
20203 (exit $ac_status); } >/dev/null; then
20204 if test -s conftest.err; then
20205 ac_cpp_err=$ac_c_preproc_warn_flag
20212 if test -z "$ac_cpp_err"; then
20213 # We can compile using X headers with no special include directory.
20216 echo "$as_me: failed program was:" >&5
20217 cat conftest.$ac_ext >&5
20218 for ac_dir in $ac_x_header_dirs; do
20219 if test -r "$ac_dir/X11/Intrinsic.h"; then
20220 ac_x_includes=$ac_dir
20225 rm -f conftest.err conftest.$ac_ext
20226 fi # $ac_x_includes = no
20228 if test "$ac_x_libraries" = no; then
20229 # Check for the libraries.
20230 # See if we find them without any special options.
20231 # Don't add to $LIBS permanently.
20234 cat >conftest.$ac_ext <<_ACEOF
20235 #line 20235 "configure"
20236 #include "confdefs.h"
20237 #include <X11/Intrinsic.h>
20246 rm -f conftest.$ac_objext conftest$ac_exeext
20247 if { (eval echo "$as_me:20247: \"$ac_link\"") >&5
20248 (eval $ac_link) 2>&5
20250 echo "$as_me:20250: \$? = $ac_status" >&5
20251 (exit $ac_status); } &&
20252 { ac_try='test -s conftest$ac_exeext'
20253 { (eval echo "$as_me:20253: \"$ac_try\"") >&5
20254 (eval $ac_try) 2>&5
20256 echo "$as_me:20256: \$? = $ac_status" >&5
20257 (exit $ac_status); }; }; then
20259 # We can link X programs with no special library path.
20262 echo "$as_me: failed program was:" >&5
20263 cat conftest.$ac_ext >&5
20265 for ac_dir in `echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
20267 # Don't even attempt the hair of trying to link an X program!
20268 for ac_extension in a so sl dylib dll; do
20269 if test -r $ac_dir/libXt.$ac_extension; then
20270 ac_x_libraries=$ac_dir
20276 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20277 fi # $ac_x_libraries = no
20279 if test "$ac_x_includes" = no || test "$ac_x_libraries" = no; then
20280 # Didn't find X anywhere. Cache the known absence of X.
20281 ac_cv_have_x="have_x=no"
20283 # Record where we found X for the cache.
20284 ac_cv_have_x="have_x=yes \
20285 ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
20290 eval "$ac_cv_have_x"
20293 if test "$have_x" != yes; then
20294 echo "$as_me:20294: result: $have_x" >&5
20295 echo "${ECHO_T}$have_x" >&6
20298 # If each of the values was on the command line, it overrides each guess.
20299 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
20300 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
20301 # Update the cache value to reflect the command line values.
20302 ac_cv_have_x="have_x=yes \
20303 ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
20304 echo "$as_me:20304: result: libraries $x_libraries, headers $x_includes" >&5
20305 echo "${ECHO_T}libraries $x_libraries, headers $x_includes" >&6
20308 if test "$no_x" = yes; then
20309 # Not all programs may use this symbol, but it does not hurt to define it.
20311 cat >>confdefs.h <<\EOF
20312 #define X_DISPLAY_MISSING 1
20315 X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS=
20317 if test -n "$x_includes"; then
20318 X_CFLAGS="$X_CFLAGS -I$x_includes"
20321 # It would also be nice to do this for all -L options, not just this one.
20322 if test -n "$x_libraries"; then
20323 X_LIBS="$X_LIBS -L$x_libraries"
20324 # For Solaris; some versions of Sun CC require a space after -R and
20325 # others require no space. Words are not sufficient . . . .
20326 case `(uname -sr) 2>/dev/null` in
20328 echo "$as_me:20328: checking whether -R must be followed by a space" >&5
20329 echo $ECHO_N "checking whether -R must be followed by a space... $ECHO_C" >&6
20330 ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries"
20331 cat >conftest.$ac_ext <<_ACEOF
20332 #line 20332 "configure"
20333 #include "confdefs.h"
20343 rm -f conftest.$ac_objext conftest$ac_exeext
20344 if { (eval echo "$as_me:20344: \"$ac_link\"") >&5
20345 (eval $ac_link) 2>&5
20347 echo "$as_me:20347: \$? = $ac_status" >&5
20348 (exit $ac_status); } &&
20349 { ac_try='test -s conftest$ac_exeext'
20350 { (eval echo "$as_me:20350: \"$ac_try\"") >&5
20351 (eval $ac_try) 2>&5
20353 echo "$as_me:20353: \$? = $ac_status" >&5
20354 (exit $ac_status); }; }; then
20357 echo "$as_me: failed program was:" >&5
20358 cat conftest.$ac_ext >&5
20361 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20362 if test $ac_R_nospace = yes; then
20363 echo "$as_me:20363: result: no" >&5
20364 echo "${ECHO_T}no" >&6
20365 X_LIBS="$X_LIBS -R$x_libraries"
20367 LIBS="$ac_xsave_LIBS -R $x_libraries"
20368 cat >conftest.$ac_ext <<_ACEOF
20369 #line 20369 "configure"
20370 #include "confdefs.h"
20380 rm -f conftest.$ac_objext conftest$ac_exeext
20381 if { (eval echo "$as_me:20381: \"$ac_link\"") >&5
20382 (eval $ac_link) 2>&5
20384 echo "$as_me:20384: \$? = $ac_status" >&5
20385 (exit $ac_status); } &&
20386 { ac_try='test -s conftest$ac_exeext'
20387 { (eval echo "$as_me:20387: \"$ac_try\"") >&5
20388 (eval $ac_try) 2>&5
20390 echo "$as_me:20390: \$? = $ac_status" >&5
20391 (exit $ac_status); }; }; then
20394 echo "$as_me: failed program was:" >&5
20395 cat conftest.$ac_ext >&5
20398 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20399 if test $ac_R_space = yes; then
20400 echo "$as_me:20400: result: yes" >&5
20401 echo "${ECHO_T}yes" >&6
20402 X_LIBS="$X_LIBS -R $x_libraries"
20404 echo "$as_me:20404: result: neither works" >&5
20405 echo "${ECHO_T}neither works" >&6
20408 LIBS=$ac_xsave_LIBS
20412 # Check for system-dependent libraries X programs must link with.
20413 # Do this before checking for the system-independent R6 libraries
20414 # (-lICE), since we may need -lsocket or whatever for X linking.
20416 if test "$ISC" = yes; then
20417 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
20419 # Martyn Johnson says this is needed for Ultrix, if the X
20420 # libraries were built with DECnet support. And Karl Berry says
20421 # the Alpha needs dnet_stub (dnet does not exist).
20422 ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11"
20423 cat >conftest.$ac_ext <<_ACEOF
20424 #line 20424 "configure"
20425 #include "confdefs.h"
20427 /* Override any gcc2 internal prototype to avoid an error. */
20431 /* We use char because int might match the return type of a gcc2
20432 builtin and then its argument prototype would still apply. */
20433 char XOpenDisplay ();
20442 rm -f conftest.$ac_objext conftest$ac_exeext
20443 if { (eval echo "$as_me:20443: \"$ac_link\"") >&5
20444 (eval $ac_link) 2>&5
20446 echo "$as_me:20446: \$? = $ac_status" >&5
20447 (exit $ac_status); } &&
20448 { ac_try='test -s conftest$ac_exeext'
20449 { (eval echo "$as_me:20449: \"$ac_try\"") >&5
20450 (eval $ac_try) 2>&5
20452 echo "$as_me:20452: \$? = $ac_status" >&5
20453 (exit $ac_status); }; }; then
20456 echo "$as_me: failed program was:" >&5
20457 cat conftest.$ac_ext >&5
20458 echo "$as_me:20458: checking for dnet_ntoa in -ldnet" >&5
20459 echo $ECHO_N "checking for dnet_ntoa in -ldnet... $ECHO_C" >&6
20460 if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then
20461 echo $ECHO_N "(cached) $ECHO_C" >&6
20463 ac_check_lib_save_LIBS=$LIBS
20464 LIBS="-ldnet $LIBS"
20465 cat >conftest.$ac_ext <<_ACEOF
20466 #line 20466 "configure"
20467 #include "confdefs.h"
20469 /* Override any gcc2 internal prototype to avoid an error. */
20473 /* We use char because int might match the return type of a gcc2
20474 builtin and then its argument prototype would still apply. */
20484 rm -f conftest.$ac_objext conftest$ac_exeext
20485 if { (eval echo "$as_me:20485: \"$ac_link\"") >&5
20486 (eval $ac_link) 2>&5
20488 echo "$as_me:20488: \$? = $ac_status" >&5
20489 (exit $ac_status); } &&
20490 { ac_try='test -s conftest$ac_exeext'
20491 { (eval echo "$as_me:20491: \"$ac_try\"") >&5
20492 (eval $ac_try) 2>&5
20494 echo "$as_me:20494: \$? = $ac_status" >&5
20495 (exit $ac_status); }; }; then
20496 ac_cv_lib_dnet_dnet_ntoa=yes
20498 echo "$as_me: failed program was:" >&5
20499 cat conftest.$ac_ext >&5
20500 ac_cv_lib_dnet_dnet_ntoa=no
20502 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20503 LIBS=$ac_check_lib_save_LIBS
20505 echo "$as_me:20505: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
20506 echo "${ECHO_T}$ac_cv_lib_dnet_dnet_ntoa" >&6
20507 if test $ac_cv_lib_dnet_dnet_ntoa = yes; then
20508 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
20511 if test $ac_cv_lib_dnet_dnet_ntoa = no; then
20512 echo "$as_me:20512: checking for dnet_ntoa in -ldnet_stub" >&5
20513 echo $ECHO_N "checking for dnet_ntoa in -ldnet_stub... $ECHO_C" >&6
20514 if test "${ac_cv_lib_dnet_stub_dnet_ntoa+set}" = set; then
20515 echo $ECHO_N "(cached) $ECHO_C" >&6
20517 ac_check_lib_save_LIBS=$LIBS
20518 LIBS="-ldnet_stub $LIBS"
20519 cat >conftest.$ac_ext <<_ACEOF
20520 #line 20520 "configure"
20521 #include "confdefs.h"
20523 /* Override any gcc2 internal prototype to avoid an error. */
20527 /* We use char because int might match the return type of a gcc2
20528 builtin and then its argument prototype would still apply. */
20538 rm -f conftest.$ac_objext conftest$ac_exeext
20539 if { (eval echo "$as_me:20539: \"$ac_link\"") >&5
20540 (eval $ac_link) 2>&5
20542 echo "$as_me:20542: \$? = $ac_status" >&5
20543 (exit $ac_status); } &&
20544 { ac_try='test -s conftest$ac_exeext'
20545 { (eval echo "$as_me:20545: \"$ac_try\"") >&5
20546 (eval $ac_try) 2>&5
20548 echo "$as_me:20548: \$? = $ac_status" >&5
20549 (exit $ac_status); }; }; then
20550 ac_cv_lib_dnet_stub_dnet_ntoa=yes
20552 echo "$as_me: failed program was:" >&5
20553 cat conftest.$ac_ext >&5
20554 ac_cv_lib_dnet_stub_dnet_ntoa=no
20556 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20557 LIBS=$ac_check_lib_save_LIBS
20559 echo "$as_me:20559: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5
20560 echo "${ECHO_T}$ac_cv_lib_dnet_stub_dnet_ntoa" >&6
20561 if test $ac_cv_lib_dnet_stub_dnet_ntoa = yes; then
20562 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
20567 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20568 LIBS="$ac_xsave_LIBS"
20570 # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT,
20571 # to get the SysV transport functions.
20572 # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4)
20574 # The nsl library prevents programs from opening the X display
20575 # on Irix 5.2, according to T.E. Dickey.
20576 # The functions gethostbyname, getservbyname, and inet_addr are
20577 # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking.
20578 echo "$as_me:20578: checking for gethostbyname" >&5
20579 echo $ECHO_N "checking for gethostbyname... $ECHO_C" >&6
20580 if test "${ac_cv_func_gethostbyname+set}" = set; then
20581 echo $ECHO_N "(cached) $ECHO_C" >&6
20583 cat >conftest.$ac_ext <<_ACEOF
20584 #line 20584 "configure"
20585 #include "confdefs.h"
20586 #define gethostbyname autoconf_temporary
20587 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
20588 #undef gethostbyname
20594 /* We use char because int might match the return type of a gcc2
20595 builtin and then its argument prototype would still apply. */
20596 char gethostbyname (void);
20602 /* The GNU C library defines stubs for functions which it implements
20603 to always fail with ENOSYS. Some functions are actually named
20604 something starting with __ and the normal name is an alias. */
20605 #if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
20606 #error found stub for gethostbyname
20609 return gethostbyname ();
20614 rm -f conftest.$ac_objext conftest$ac_exeext
20615 if { (eval echo "$as_me:20615: \"$ac_link\"") >&5
20616 (eval $ac_link) 2>&5
20618 echo "$as_me:20618: \$? = $ac_status" >&5
20619 (exit $ac_status); } &&
20620 { ac_try='test -s conftest$ac_exeext'
20621 { (eval echo "$as_me:20621: \"$ac_try\"") >&5
20622 (eval $ac_try) 2>&5
20624 echo "$as_me:20624: \$? = $ac_status" >&5
20625 (exit $ac_status); }; }; then
20626 ac_cv_func_gethostbyname=yes
20628 echo "$as_me: failed program was:" >&5
20629 cat conftest.$ac_ext >&5
20630 ac_cv_func_gethostbyname=no
20632 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20634 echo "$as_me:20634: result: $ac_cv_func_gethostbyname" >&5
20635 echo "${ECHO_T}$ac_cv_func_gethostbyname" >&6
20637 if test $ac_cv_func_gethostbyname = no; then
20638 echo "$as_me:20638: checking for gethostbyname in -lnsl" >&5
20639 echo $ECHO_N "checking for gethostbyname in -lnsl... $ECHO_C" >&6
20640 if test "${ac_cv_lib_nsl_gethostbyname+set}" = set; then
20641 echo $ECHO_N "(cached) $ECHO_C" >&6
20643 ac_check_lib_save_LIBS=$LIBS
20645 cat >conftest.$ac_ext <<_ACEOF
20646 #line 20646 "configure"
20647 #include "confdefs.h"
20649 /* Override any gcc2 internal prototype to avoid an error. */
20653 /* We use char because int might match the return type of a gcc2
20654 builtin and then its argument prototype would still apply. */
20655 char gethostbyname ();
20664 rm -f conftest.$ac_objext conftest$ac_exeext
20665 if { (eval echo "$as_me:20665: \"$ac_link\"") >&5
20666 (eval $ac_link) 2>&5
20668 echo "$as_me:20668: \$? = $ac_status" >&5
20669 (exit $ac_status); } &&
20670 { ac_try='test -s conftest$ac_exeext'
20671 { (eval echo "$as_me:20671: \"$ac_try\"") >&5
20672 (eval $ac_try) 2>&5
20674 echo "$as_me:20674: \$? = $ac_status" >&5
20675 (exit $ac_status); }; }; then
20676 ac_cv_lib_nsl_gethostbyname=yes
20678 echo "$as_me: failed program was:" >&5
20679 cat conftest.$ac_ext >&5
20680 ac_cv_lib_nsl_gethostbyname=no
20682 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20683 LIBS=$ac_check_lib_save_LIBS
20685 echo "$as_me:20685: result: $ac_cv_lib_nsl_gethostbyname" >&5
20686 echo "${ECHO_T}$ac_cv_lib_nsl_gethostbyname" >&6
20687 if test $ac_cv_lib_nsl_gethostbyname = yes; then
20688 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
20691 if test $ac_cv_lib_nsl_gethostbyname = no; then
20692 echo "$as_me:20692: checking for gethostbyname in -lbsd" >&5
20693 echo $ECHO_N "checking for gethostbyname in -lbsd... $ECHO_C" >&6
20694 if test "${ac_cv_lib_bsd_gethostbyname+set}" = set; then
20695 echo $ECHO_N "(cached) $ECHO_C" >&6
20697 ac_check_lib_save_LIBS=$LIBS
20699 cat >conftest.$ac_ext <<_ACEOF
20700 #line 20700 "configure"
20701 #include "confdefs.h"
20703 /* Override any gcc2 internal prototype to avoid an error. */
20707 /* We use char because int might match the return type of a gcc2
20708 builtin and then its argument prototype would still apply. */
20709 char gethostbyname ();
20718 rm -f conftest.$ac_objext conftest$ac_exeext
20719 if { (eval echo "$as_me:20719: \"$ac_link\"") >&5
20720 (eval $ac_link) 2>&5
20722 echo "$as_me:20722: \$? = $ac_status" >&5
20723 (exit $ac_status); } &&
20724 { ac_try='test -s conftest$ac_exeext'
20725 { (eval echo "$as_me:20725: \"$ac_try\"") >&5
20726 (eval $ac_try) 2>&5
20728 echo "$as_me:20728: \$? = $ac_status" >&5
20729 (exit $ac_status); }; }; then
20730 ac_cv_lib_bsd_gethostbyname=yes
20732 echo "$as_me: failed program was:" >&5
20733 cat conftest.$ac_ext >&5
20734 ac_cv_lib_bsd_gethostbyname=no
20736 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20737 LIBS=$ac_check_lib_save_LIBS
20739 echo "$as_me:20739: result: $ac_cv_lib_bsd_gethostbyname" >&5
20740 echo "${ECHO_T}$ac_cv_lib_bsd_gethostbyname" >&6
20741 if test $ac_cv_lib_bsd_gethostbyname = yes; then
20742 X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd"
20748 # lieder@skyler.mavd.honeywell.com says without -lsocket,
20749 # socket/setsockopt and other routines are undefined under SCO ODT
20750 # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary
20751 # on later versions), says Simon Leinen: it contains gethostby*
20752 # variants that don't use the nameserver (or something). -lsocket
20753 # must be given before -lnsl if both are needed. We assume that
20754 # if connect needs -lnsl, so does gethostbyname.
20755 echo "$as_me:20755: checking for connect" >&5
20756 echo $ECHO_N "checking for connect... $ECHO_C" >&6
20757 if test "${ac_cv_func_connect+set}" = set; then
20758 echo $ECHO_N "(cached) $ECHO_C" >&6
20760 cat >conftest.$ac_ext <<_ACEOF
20761 #line 20761 "configure"
20762 #include "confdefs.h"
20763 #define connect autoconf_temporary
20764 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
20771 /* We use char because int might match the return type of a gcc2
20772 builtin and then its argument prototype would still apply. */
20773 char connect (void);
20779 /* The GNU C library defines stubs for functions which it implements
20780 to always fail with ENOSYS. Some functions are actually named
20781 something starting with __ and the normal name is an alias. */
20782 #if defined (__stub_connect) || defined (__stub___connect)
20783 #error found stub for connect
20791 rm -f conftest.$ac_objext conftest$ac_exeext
20792 if { (eval echo "$as_me:20792: \"$ac_link\"") >&5
20793 (eval $ac_link) 2>&5
20795 echo "$as_me:20795: \$? = $ac_status" >&5
20796 (exit $ac_status); } &&
20797 { ac_try='test -s conftest$ac_exeext'
20798 { (eval echo "$as_me:20798: \"$ac_try\"") >&5
20799 (eval $ac_try) 2>&5
20801 echo "$as_me:20801: \$? = $ac_status" >&5
20802 (exit $ac_status); }; }; then
20803 ac_cv_func_connect=yes
20805 echo "$as_me: failed program was:" >&5
20806 cat conftest.$ac_ext >&5
20807 ac_cv_func_connect=no
20809 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20811 echo "$as_me:20811: result: $ac_cv_func_connect" >&5
20812 echo "${ECHO_T}$ac_cv_func_connect" >&6
20814 if test $ac_cv_func_connect = no; then
20815 echo "$as_me:20815: checking for connect in -lsocket" >&5
20816 echo $ECHO_N "checking for connect in -lsocket... $ECHO_C" >&6
20817 if test "${ac_cv_lib_socket_connect+set}" = set; then
20818 echo $ECHO_N "(cached) $ECHO_C" >&6
20820 ac_check_lib_save_LIBS=$LIBS
20821 LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
20822 cat >conftest.$ac_ext <<_ACEOF
20823 #line 20823 "configure"
20824 #include "confdefs.h"
20826 /* Override any gcc2 internal prototype to avoid an error. */
20830 /* We use char because int might match the return type of a gcc2
20831 builtin and then its argument prototype would still apply. */
20841 rm -f conftest.$ac_objext conftest$ac_exeext
20842 if { (eval echo "$as_me:20842: \"$ac_link\"") >&5
20843 (eval $ac_link) 2>&5
20845 echo "$as_me:20845: \$? = $ac_status" >&5
20846 (exit $ac_status); } &&
20847 { ac_try='test -s conftest$ac_exeext'
20848 { (eval echo "$as_me:20848: \"$ac_try\"") >&5
20849 (eval $ac_try) 2>&5
20851 echo "$as_me:20851: \$? = $ac_status" >&5
20852 (exit $ac_status); }; }; then
20853 ac_cv_lib_socket_connect=yes
20855 echo "$as_me: failed program was:" >&5
20856 cat conftest.$ac_ext >&5
20857 ac_cv_lib_socket_connect=no
20859 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20860 LIBS=$ac_check_lib_save_LIBS
20862 echo "$as_me:20862: result: $ac_cv_lib_socket_connect" >&5
20863 echo "${ECHO_T}$ac_cv_lib_socket_connect" >&6
20864 if test $ac_cv_lib_socket_connect = yes; then
20865 X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS"
20870 # Guillermo Gomez says -lposix is necessary on A/UX.
20871 echo "$as_me:20871: checking for remove" >&5
20872 echo $ECHO_N "checking for remove... $ECHO_C" >&6
20873 if test "${ac_cv_func_remove+set}" = set; then
20874 echo $ECHO_N "(cached) $ECHO_C" >&6
20876 cat >conftest.$ac_ext <<_ACEOF
20877 #line 20877 "configure"
20878 #include "confdefs.h"
20879 #define remove autoconf_temporary
20880 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
20887 /* We use char because int might match the return type of a gcc2
20888 builtin and then its argument prototype would still apply. */
20889 char remove (void);
20895 /* The GNU C library defines stubs for functions which it implements
20896 to always fail with ENOSYS. Some functions are actually named
20897 something starting with __ and the normal name is an alias. */
20898 #if defined (__stub_remove) || defined (__stub___remove)
20899 #error found stub for remove
20907 rm -f conftest.$ac_objext conftest$ac_exeext
20908 if { (eval echo "$as_me:20908: \"$ac_link\"") >&5
20909 (eval $ac_link) 2>&5
20911 echo "$as_me:20911: \$? = $ac_status" >&5
20912 (exit $ac_status); } &&
20913 { ac_try='test -s conftest$ac_exeext'
20914 { (eval echo "$as_me:20914: \"$ac_try\"") >&5
20915 (eval $ac_try) 2>&5
20917 echo "$as_me:20917: \$? = $ac_status" >&5
20918 (exit $ac_status); }; }; then
20919 ac_cv_func_remove=yes
20921 echo "$as_me: failed program was:" >&5
20922 cat conftest.$ac_ext >&5
20923 ac_cv_func_remove=no
20925 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20927 echo "$as_me:20927: result: $ac_cv_func_remove" >&5
20928 echo "${ECHO_T}$ac_cv_func_remove" >&6
20930 if test $ac_cv_func_remove = no; then
20931 echo "$as_me:20931: checking for remove in -lposix" >&5
20932 echo $ECHO_N "checking for remove in -lposix... $ECHO_C" >&6
20933 if test "${ac_cv_lib_posix_remove+set}" = set; then
20934 echo $ECHO_N "(cached) $ECHO_C" >&6
20936 ac_check_lib_save_LIBS=$LIBS
20937 LIBS="-lposix $LIBS"
20938 cat >conftest.$ac_ext <<_ACEOF
20939 #line 20939 "configure"
20940 #include "confdefs.h"
20942 /* Override any gcc2 internal prototype to avoid an error. */
20946 /* We use char because int might match the return type of a gcc2
20947 builtin and then its argument prototype would still apply. */
20957 rm -f conftest.$ac_objext conftest$ac_exeext
20958 if { (eval echo "$as_me:20958: \"$ac_link\"") >&5
20959 (eval $ac_link) 2>&5
20961 echo "$as_me:20961: \$? = $ac_status" >&5
20962 (exit $ac_status); } &&
20963 { ac_try='test -s conftest$ac_exeext'
20964 { (eval echo "$as_me:20964: \"$ac_try\"") >&5
20965 (eval $ac_try) 2>&5
20967 echo "$as_me:20967: \$? = $ac_status" >&5
20968 (exit $ac_status); }; }; then
20969 ac_cv_lib_posix_remove=yes
20971 echo "$as_me: failed program was:" >&5
20972 cat conftest.$ac_ext >&5
20973 ac_cv_lib_posix_remove=no
20975 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20976 LIBS=$ac_check_lib_save_LIBS
20978 echo "$as_me:20978: result: $ac_cv_lib_posix_remove" >&5
20979 echo "${ECHO_T}$ac_cv_lib_posix_remove" >&6
20980 if test $ac_cv_lib_posix_remove = yes; then
20981 X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix"
20986 # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
20987 echo "$as_me:20987: checking for shmat" >&5
20988 echo $ECHO_N "checking for shmat... $ECHO_C" >&6
20989 if test "${ac_cv_func_shmat+set}" = set; then
20990 echo $ECHO_N "(cached) $ECHO_C" >&6
20992 cat >conftest.$ac_ext <<_ACEOF
20993 #line 20993 "configure"
20994 #include "confdefs.h"
20995 #define shmat autoconf_temporary
20996 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
21003 /* We use char because int might match the return type of a gcc2
21004 builtin and then its argument prototype would still apply. */
21011 /* The GNU C library defines stubs for functions which it implements
21012 to always fail with ENOSYS. Some functions are actually named
21013 something starting with __ and the normal name is an alias. */
21014 #if defined (__stub_shmat) || defined (__stub___shmat)
21015 #error found stub for shmat
21023 rm -f conftest.$ac_objext conftest$ac_exeext
21024 if { (eval echo "$as_me:21024: \"$ac_link\"") >&5
21025 (eval $ac_link) 2>&5
21027 echo "$as_me:21027: \$? = $ac_status" >&5
21028 (exit $ac_status); } &&
21029 { ac_try='test -s conftest$ac_exeext'
21030 { (eval echo "$as_me:21030: \"$ac_try\"") >&5
21031 (eval $ac_try) 2>&5
21033 echo "$as_me:21033: \$? = $ac_status" >&5
21034 (exit $ac_status); }; }; then
21035 ac_cv_func_shmat=yes
21037 echo "$as_me: failed program was:" >&5
21038 cat conftest.$ac_ext >&5
21039 ac_cv_func_shmat=no
21041 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
21043 echo "$as_me:21043: result: $ac_cv_func_shmat" >&5
21044 echo "${ECHO_T}$ac_cv_func_shmat" >&6
21046 if test $ac_cv_func_shmat = no; then
21047 echo "$as_me:21047: checking for shmat in -lipc" >&5
21048 echo $ECHO_N "checking for shmat in -lipc... $ECHO_C" >&6
21049 if test "${ac_cv_lib_ipc_shmat+set}" = set; then
21050 echo $ECHO_N "(cached) $ECHO_C" >&6
21052 ac_check_lib_save_LIBS=$LIBS
21054 cat >conftest.$ac_ext <<_ACEOF
21055 #line 21055 "configure"
21056 #include "confdefs.h"
21058 /* Override any gcc2 internal prototype to avoid an error. */
21062 /* We use char because int might match the return type of a gcc2
21063 builtin and then its argument prototype would still apply. */
21073 rm -f conftest.$ac_objext conftest$ac_exeext
21074 if { (eval echo "$as_me:21074: \"$ac_link\"") >&5
21075 (eval $ac_link) 2>&5
21077 echo "$as_me:21077: \$? = $ac_status" >&5
21078 (exit $ac_status); } &&
21079 { ac_try='test -s conftest$ac_exeext'
21080 { (eval echo "$as_me:21080: \"$ac_try\"") >&5
21081 (eval $ac_try) 2>&5
21083 echo "$as_me:21083: \$? = $ac_status" >&5
21084 (exit $ac_status); }; }; then
21085 ac_cv_lib_ipc_shmat=yes
21087 echo "$as_me: failed program was:" >&5
21088 cat conftest.$ac_ext >&5
21089 ac_cv_lib_ipc_shmat=no
21091 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
21092 LIBS=$ac_check_lib_save_LIBS
21094 echo "$as_me:21094: result: $ac_cv_lib_ipc_shmat" >&5
21095 echo "${ECHO_T}$ac_cv_lib_ipc_shmat" >&6
21096 if test $ac_cv_lib_ipc_shmat = yes; then
21097 X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc"
21103 # Check for libraries that X11R6 Xt/Xaw programs need.
21104 ac_save_LDFLAGS=$LDFLAGS
21105 test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries"
21106 # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
21107 # check for ICE first), but we must link in the order -lSM -lICE or
21108 # we get undefined symbols. So assume we have SM if we have ICE.
21109 # These have to be linked with before -lX11, unlike the other
21110 # libraries we check for below, so use a different variable.
21111 # John Interrante, Karl Berry
21112 echo "$as_me:21112: checking for IceConnectionNumber in -lICE" >&5
21113 echo $ECHO_N "checking for IceConnectionNumber in -lICE... $ECHO_C" >&6
21114 if test "${ac_cv_lib_ICE_IceConnectionNumber+set}" = set; then
21115 echo $ECHO_N "(cached) $ECHO_C" >&6
21117 ac_check_lib_save_LIBS=$LIBS
21118 LIBS="-lICE $X_EXTRA_LIBS $LIBS"
21119 cat >conftest.$ac_ext <<_ACEOF
21120 #line 21120 "configure"
21121 #include "confdefs.h"
21123 /* Override any gcc2 internal prototype to avoid an error. */
21127 /* We use char because int might match the return type of a gcc2
21128 builtin and then its argument prototype would still apply. */
21129 char IceConnectionNumber ();
21133 IceConnectionNumber ();
21138 rm -f conftest.$ac_objext conftest$ac_exeext
21139 if { (eval echo "$as_me:21139: \"$ac_link\"") >&5
21140 (eval $ac_link) 2>&5
21142 echo "$as_me:21142: \$? = $ac_status" >&5
21143 (exit $ac_status); } &&
21144 { ac_try='test -s conftest$ac_exeext'
21145 { (eval echo "$as_me:21145: \"$ac_try\"") >&5
21146 (eval $ac_try) 2>&5
21148 echo "$as_me:21148: \$? = $ac_status" >&5
21149 (exit $ac_status); }; }; then
21150 ac_cv_lib_ICE_IceConnectionNumber=yes
21152 echo "$as_me: failed program was:" >&5
21153 cat conftest.$ac_ext >&5
21154 ac_cv_lib_ICE_IceConnectionNumber=no
21156 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
21157 LIBS=$ac_check_lib_save_LIBS
21159 echo "$as_me:21159: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5
21160 echo "${ECHO_T}$ac_cv_lib_ICE_IceConnectionNumber" >&6
21161 if test $ac_cv_lib_ICE_IceConnectionNumber = yes; then
21162 X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
21165 LDFLAGS=$ac_save_LDFLAGS
21171 if ( test "$GCC" = yes || test "$GXX" = yes )
21174 if ( test "$GCC" = yes || test "$GXX" = yes )
21178 test -n "$verbose" && echo " repairing CFLAGS: $CFLAGS" 1>&6
21180 echo "${as_me:-configure}:21180: testing repairing CFLAGS: $CFLAGS ..." 1>&5
21183 for cf_temp_scan in $CFLAGS
21185 case "x$cf_temp_scan" in
21188 test -n "$EXTRA_CFLAGS" && EXTRA_CFLAGS="$EXTRA_CFLAGS "
21189 EXTRA_CFLAGS="${EXTRA_CFLAGS}"$cf_temp_scan""
21194 test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
21195 cf_temp_flags="${cf_temp_flags}"$cf_temp_scan""
21200 CFLAGS="$cf_temp_flags"
21201 test -n "$verbose" && echo " ... fixed $CFLAGS" 1>&6
21203 echo "${as_me:-configure}:21203: testing ... fixed $CFLAGS ..." 1>&5
21205 test -n "$verbose" && echo " ... extra $EXTRA_CFLAGS" 1>&6
21207 echo "${as_me:-configure}:21207: testing ... extra $EXTRA_CFLAGS ..." 1>&5
21213 if ( test "$GCC" = yes || test "$GXX" = yes )
21217 test -n "$verbose" && echo " repairing CPPFLAGS: $CPPFLAGS" 1>&6
21219 echo "${as_me:-configure}:21219: testing repairing CPPFLAGS: $CPPFLAGS ..." 1>&5
21222 for cf_temp_scan in $CPPFLAGS
21224 case "x$cf_temp_scan" in
21227 test -n "$EXTRA_CFLAGS" && EXTRA_CFLAGS="$EXTRA_CFLAGS "
21228 EXTRA_CFLAGS="${EXTRA_CFLAGS}"$cf_temp_scan""
21233 test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
21234 cf_temp_flags="${cf_temp_flags}"$cf_temp_scan""
21239 CPPFLAGS="$cf_temp_flags"
21240 test -n "$verbose" && echo " ... fixed $CPPFLAGS" 1>&6
21242 echo "${as_me:-configure}:21242: testing ... fixed $CPPFLAGS ..." 1>&5
21244 test -n "$verbose" && echo " ... extra $EXTRA_CFLAGS" 1>&6
21246 echo "${as_me:-configure}:21246: testing ... extra $EXTRA_CFLAGS ..." 1>&5
21252 if ( test "$GCC" = yes || test "$GXX" = yes )
21256 test -n "$verbose" && echo " repairing LDFLAGS: $LDFLAGS" 1>&6
21258 echo "${as_me:-configure}:21258: testing repairing LDFLAGS: $LDFLAGS ..." 1>&5
21261 for cf_temp_scan in $LDFLAGS
21263 case "x$cf_temp_scan" in
21266 test -n "$EXTRA_CFLAGS" && EXTRA_CFLAGS="$EXTRA_CFLAGS "
21267 EXTRA_CFLAGS="${EXTRA_CFLAGS}"$cf_temp_scan""
21272 test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
21273 cf_temp_flags="${cf_temp_flags}"$cf_temp_scan""
21278 LDFLAGS="$cf_temp_flags"
21279 test -n "$verbose" && echo " ... fixed $LDFLAGS" 1>&6
21281 echo "${as_me:-configure}:21281: testing ... fixed $LDFLAGS ..." 1>&5
21283 test -n "$verbose" && echo " ... extra $EXTRA_CFLAGS" 1>&6
21285 echo "${as_me:-configure}:21285: testing ... extra $EXTRA_CFLAGS ..." 1>&5
21291 echo "$as_me:21291: checking if you want to turn on gcc warnings" >&5
21292 echo $ECHO_N "checking if you want to turn on gcc warnings... $ECHO_C" >&6
21294 # Check whether --enable-warnings or --disable-warnings was given.
21295 if test "${enable_warnings+set}" = set; then
21296 enableval="$enable_warnings"
21297 test "$enableval" != yes && enableval=no
21298 if test "$enableval" != "no" ; then
21308 echo "$as_me:21308: result: $with_warnings" >&5
21309 echo "${ECHO_T}$with_warnings" >&6
21310 if test "$with_warnings" = "yes"
21313 if ( test "$GCC" = yes || test "$GXX" = yes )
21315 cat > conftest.i <<EOF
21317 #define GCC_PRINTF 0
21320 #define GCC_SCANF 0
21322 #ifndef GCC_NORETURN
21323 #define GCC_NORETURN /* nothing */
21326 #define GCC_UNUSED /* nothing */
21329 if test "$GCC" = yes
21331 { echo "$as_me:21331: checking for $CC __attribute__ directives..." >&5
21332 echo "$as_me: checking for $CC __attribute__ directives..." >&6;}
21333 cat > conftest.$ac_ext <<EOF
21334 #line 21334 "${as_me:-configure}"
21335 #include "confdefs.h"
21336 #include "conftest.h"
21337 #include "conftest.i"
21339 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
21341 #define GCC_PRINTFLIKE(fmt,var) /*nothing*/
21344 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
21346 #define GCC_SCANFLIKE(fmt,var) /*nothing*/
21348 extern void wow(char *,...) GCC_SCANFLIKE(1,2);
21349 extern void oops(char *,...) GCC_PRINTFLIKE(1,2) GCC_NORETURN;
21350 extern void foo(void) GCC_NORETURN;
21351 int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { (void)argc; (void)argv; return 0; }
21353 cf_printf_attribute=no
21354 cf_scanf_attribute=no
21355 for cf_attribute in scanf printf unused noreturn
21358 cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
21360 cf_directive="__attribute__(($cf_attribute))"
21361 echo "checking for $CC $cf_directive" 1>&5
21363 case $cf_attribute in
21365 cf_printf_attribute=yes
21366 cat >conftest.h <<EOF
21367 #define GCC_$cf_ATTRIBUTE 1
21371 cf_scanf_attribute=yes
21372 cat >conftest.h <<EOF
21373 #define GCC_$cf_ATTRIBUTE 1
21377 cat >conftest.h <<EOF
21378 #define GCC_$cf_ATTRIBUTE $cf_directive
21383 if { (eval echo "$as_me:21383: \"$ac_compile\"") >&5
21384 (eval $ac_compile) 2>&5
21386 echo "$as_me:21386: \$? = $ac_status" >&5
21387 (exit $ac_status); }; then
21388 test -n "$verbose" && echo "$as_me:21388: result: ... $cf_attribute" >&5
21389 echo "${ECHO_T}... $cf_attribute" >&6
21390 cat conftest.h >>confdefs.h
21391 case $cf_attribute in
21394 cat >>confdefs.h <<EOF
21395 #define GCC_NORETURN $cf_directive
21400 cf_value='/* nothing */'
21401 if test "$cf_printf_attribute" != no ; then
21402 cf_value='__attribute__((format(printf,fmt,var)))'
21404 cat >>confdefs.h <<\EOF
21405 #define GCC_PRINTF 1
21410 cat >>confdefs.h <<EOF
21411 #define GCC_PRINTFLIKE(fmt,var) $cf_value
21416 cf_value='/* nothing */'
21417 if test "$cf_scanf_attribute" != no ; then
21418 cf_value='__attribute__((format(scanf,fmt,var)))'
21420 cat >>confdefs.h <<\EOF
21421 #define GCC_SCANF 1
21426 cat >>confdefs.h <<EOF
21427 #define GCC_SCANFLIKE(fmt,var) $cf_value
21433 cat >>confdefs.h <<EOF
21434 #define GCC_UNUSED $cf_directive
21442 fgrep define conftest.i >>confdefs.h
21447 if test "x$have_x" = xyes; then
21449 cf_save_LIBS_CF_CONST_X_STRING="$LIBS"
21450 cf_save_CFLAGS_CF_CONST_X_STRING="$CFLAGS"
21451 cf_save_CPPFLAGS_CF_CONST_X_STRING="$CPPFLAGS"
21452 LIBS="$LIBS ${X_PRE_LIBS} ${X_LIBS} ${X_EXTRA_LIBS}"
21453 for cf_X_CFLAGS in $X_CFLAGS
21455 case "x$cf_X_CFLAGS" in
21457 CPPFLAGS="$CPPFLAGS $cf_X_CFLAGS"
21460 CFLAGS="$CFLAGS $cf_X_CFLAGS"
21465 cat >conftest.$ac_ext <<_ACEOF
21466 #line 21466 "configure"
21467 #include "confdefs.h"
21469 #include <stdlib.h>
21470 #include <X11/Intrinsic.h>
21475 String foo = malloc(1); (void)foo
21480 rm -f conftest.$ac_objext
21481 if { (eval echo "$as_me:21481: \"$ac_compile\"") >&5
21482 (eval $ac_compile) 2>&5
21484 echo "$as_me:21484: \$? = $ac_status" >&5
21485 (exit $ac_status); } &&
21486 { ac_try='test -s conftest.$ac_objext'
21487 { (eval echo "$as_me:21487: \"$ac_try\"") >&5
21488 (eval $ac_try) 2>&5
21490 echo "$as_me:21490: \$? = $ac_status" >&5
21491 (exit $ac_status); }; }; then
21493 echo "$as_me:21493: checking for X11/Xt const-feature" >&5
21494 echo $ECHO_N "checking for X11/Xt const-feature... $ECHO_C" >&6
21495 if test "${cf_cv_const_x_string+set}" = set; then
21496 echo $ECHO_N "(cached) $ECHO_C" >&6
21499 cat >conftest.$ac_ext <<_ACEOF
21500 #line 21500 "configure"
21501 #include "confdefs.h"
21503 #define _CONST_X_STRING /* X11R7.8 (perhaps) */
21504 #undef XTSTRINGDEFINES /* X11R5 and later */
21505 #include <stdlib.h>
21506 #include <X11/Intrinsic.h>
21511 String foo = malloc(1); *foo = 0
21516 rm -f conftest.$ac_objext
21517 if { (eval echo "$as_me:21517: \"$ac_compile\"") >&5
21518 (eval $ac_compile) 2>&5
21520 echo "$as_me:21520: \$? = $ac_status" >&5
21521 (exit $ac_status); } &&
21522 { ac_try='test -s conftest.$ac_objext'
21523 { (eval echo "$as_me:21523: \"$ac_try\"") >&5
21524 (eval $ac_try) 2>&5
21526 echo "$as_me:21526: \$? = $ac_status" >&5
21527 (exit $ac_status); }; }; then
21529 cf_cv_const_x_string=no
21532 echo "$as_me: failed program was:" >&5
21533 cat conftest.$ac_ext >&5
21535 cf_cv_const_x_string=yes
21538 rm -f conftest.$ac_objext conftest.$ac_ext
21541 echo "$as_me:21541: result: $cf_cv_const_x_string" >&5
21542 echo "${ECHO_T}$cf_cv_const_x_string" >&6
21544 LIBS="$cf_save_LIBS_CF_CONST_X_STRING"
21545 CFLAGS="$cf_save_CFLAGS_CF_CONST_X_STRING"
21546 CPPFLAGS="$cf_save_CPPFLAGS_CF_CONST_X_STRING"
21548 case $cf_cv_const_x_string in
21551 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
21552 CPPFLAGS="${CPPFLAGS}-DXTSTRINGDEFINES"
21557 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
21558 CPPFLAGS="${CPPFLAGS}-D_CONST_X_STRING"
21564 echo "$as_me: failed program was:" >&5
21565 cat conftest.$ac_ext >&5
21567 rm -f conftest.$ac_objext conftest.$ac_ext
21569 cat > conftest.$ac_ext <<EOF
21570 #line 21570 "${as_me:-configure}"
21571 int main(int argc, char *argv[]) { return (argv[argc-1] == 0) ; }
21573 if test "$INTEL_COMPILER" = yes
21575 # The "-wdXXX" options suppress warnings:
21576 # remark #1419: external declaration in primary source file
21577 # remark #1683: explicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem)
21578 # remark #1684: conversion from pointer to same-sized integral type (potential portability problem)
21579 # remark #193: zero used for undefined preprocessing identifier
21580 # remark #593: variable "curs_sb_left_arrow" was set but never used
21581 # remark #810: conversion from "int" to "Dimension={unsigned short}" may lose significant bits
21582 # remark #869: parameter "tw" was never referenced
21583 # remark #981: operands are evaluated in unspecified order
21584 # warning #279: controlling expression is constant
21586 { echo "$as_me:21586: checking for $CC warning options..." >&5
21587 echo "$as_me: checking for $CC warning options..." >&6;}
21588 cf_save_CFLAGS="$CFLAGS"
21589 EXTRA_CFLAGS="$EXTRA_CFLAGS -Wall"
21601 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
21602 if { (eval echo "$as_me:21602: \"$ac_compile\"") >&5
21603 (eval $ac_compile) 2>&5
21605 echo "$as_me:21605: \$? = $ac_status" >&5
21606 (exit $ac_status); }; then
21607 test -n "$verbose" && echo "$as_me:21607: result: ... -$cf_opt" >&5
21608 echo "${ECHO_T}... -$cf_opt" >&6
21609 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
21612 CFLAGS="$cf_save_CFLAGS"
21613 elif test "$GCC" = yes && test "$GCC_VERSION" != "unknown"
21615 { echo "$as_me:21615: checking for $CC warning options..." >&5
21616 echo "$as_me: checking for $CC warning options..." >&6;}
21617 cf_save_CFLAGS="$CFLAGS"
21619 test "$with_ext_const" = yes && cf_warn_CONST="Wwrite-strings"
21620 cf_gcc_warnings="Wignored-qualifiers Wlogical-op Wvarargs"
21621 test "x$CLANG_COMPILER" = xyes && cf_gcc_warnings=
21622 for cf_opt in W Wall \
21623 Wbad-function-cast \
21626 Wdeclaration-after-statement \
21629 Wmissing-declarations \
21630 Wmissing-prototypes \
21634 Wstrict-prototypes \
21635 Wundef Wno-inline $cf_gcc_warnings $cf_warn_CONST Wno-unknown-pragmas
21637 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
21638 if { (eval echo "$as_me:21638: \"$ac_compile\"") >&5
21639 (eval $ac_compile) 2>&5
21641 echo "$as_me:21641: \$? = $ac_status" >&5
21642 (exit $ac_status); }; then
21643 test -n "$verbose" && echo "$as_me:21643: result: ... -$cf_opt" >&5
21644 echo "${ECHO_T}... -$cf_opt" >&6
21647 case $GCC_VERSION in
21649 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
21651 echo "${as_me:-configure}:21651: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
21657 case $GCC_VERSION in
21659 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
21661 echo "${as_me:-configure}:21661: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
21667 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
21670 CFLAGS="$cf_save_CFLAGS"
21678 echo "$as_me:21678: checking if you want to use dmalloc for testing" >&5
21679 echo $ECHO_N "checking if you want to use dmalloc for testing... $ECHO_C" >&6
21681 # Check whether --with-dmalloc or --without-dmalloc was given.
21682 if test "${with_dmalloc+set}" = set; then
21683 withval="$with_dmalloc"
21685 cat >>confdefs.h <<EOF
21686 #define USE_DMALLOC 1
21689 : ${with_cflags:=-g}
21690 : ${with_no_leaks:=yes}
21695 echo "$as_me:21695: result: ${with_dmalloc:-no}" >&5
21696 echo "${ECHO_T}${with_dmalloc:-no}" >&6
21698 case .$with_cflags in
21708 cf_new_extra_cppflags=
21710 for cf_add_cflags in -g
21712 case $cf_fix_cppflags in
21714 case $cf_add_cflags in
21715 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
21716 case $cf_add_cflags in
21718 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
21720 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
21721 && test -z "${cf_tst_cflags}" \
21722 && cf_fix_cppflags=yes
21724 if test $cf_fix_cppflags = yes ; then
21726 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
21727 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
21730 elif test "${cf_tst_cflags}" = "\"'" ; then
21732 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
21733 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
21739 case "$CPPFLAGS" in
21743 case $cf_add_cflags in
21745 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
21747 CPPFLAGS=`echo "$CPPFLAGS" | \
21748 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
21749 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
21754 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
21755 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
21762 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
21763 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
21770 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
21771 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
21773 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
21775 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
21776 && test -z "${cf_tst_cflags}" \
21777 && cf_fix_cppflags=no
21782 if test -n "$cf_new_cflags" ; then
21784 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
21785 CFLAGS="${CFLAGS}$cf_new_cflags"
21789 if test -n "$cf_new_cppflags" ; then
21791 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
21792 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
21796 if test -n "$cf_new_extra_cppflags" ; then
21798 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
21799 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
21808 if test "$with_dmalloc" = yes ; then
21809 echo "$as_me:21809: checking for dmalloc.h" >&5
21810 echo $ECHO_N "checking for dmalloc.h... $ECHO_C" >&6
21811 if test "${ac_cv_header_dmalloc_h+set}" = set; then
21812 echo $ECHO_N "(cached) $ECHO_C" >&6
21814 cat >conftest.$ac_ext <<_ACEOF
21815 #line 21815 "configure"
21816 #include "confdefs.h"
21817 #include <dmalloc.h>
21819 if { (eval echo "$as_me:21819: \"$ac_cpp conftest.$ac_ext\"") >&5
21820 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
21822 egrep -v '^ *\+' conftest.er1 >conftest.err
21824 cat conftest.err >&5
21825 echo "$as_me:21825: \$? = $ac_status" >&5
21826 (exit $ac_status); } >/dev/null; then
21827 if test -s conftest.err; then
21828 ac_cpp_err=$ac_c_preproc_warn_flag
21835 if test -z "$ac_cpp_err"; then
21836 ac_cv_header_dmalloc_h=yes
21838 echo "$as_me: failed program was:" >&5
21839 cat conftest.$ac_ext >&5
21840 ac_cv_header_dmalloc_h=no
21842 rm -f conftest.err conftest.$ac_ext
21844 echo "$as_me:21844: result: $ac_cv_header_dmalloc_h" >&5
21845 echo "${ECHO_T}$ac_cv_header_dmalloc_h" >&6
21846 if test $ac_cv_header_dmalloc_h = yes; then
21848 echo "$as_me:21848: checking for dmalloc_debug in -ldmalloc" >&5
21849 echo $ECHO_N "checking for dmalloc_debug in -ldmalloc... $ECHO_C" >&6
21850 if test "${ac_cv_lib_dmalloc_dmalloc_debug+set}" = set; then
21851 echo $ECHO_N "(cached) $ECHO_C" >&6
21853 ac_check_lib_save_LIBS=$LIBS
21854 LIBS="-ldmalloc $LIBS"
21855 cat >conftest.$ac_ext <<_ACEOF
21856 #line 21856 "configure"
21857 #include "confdefs.h"
21859 /* Override any gcc2 internal prototype to avoid an error. */
21863 /* We use char because int might match the return type of a gcc2
21864 builtin and then its argument prototype would still apply. */
21865 char dmalloc_debug ();
21874 rm -f conftest.$ac_objext conftest$ac_exeext
21875 if { (eval echo "$as_me:21875: \"$ac_link\"") >&5
21876 (eval $ac_link) 2>&5
21878 echo "$as_me:21878: \$? = $ac_status" >&5
21879 (exit $ac_status); } &&
21880 { ac_try='test -s conftest$ac_exeext'
21881 { (eval echo "$as_me:21881: \"$ac_try\"") >&5
21882 (eval $ac_try) 2>&5
21884 echo "$as_me:21884: \$? = $ac_status" >&5
21885 (exit $ac_status); }; }; then
21886 ac_cv_lib_dmalloc_dmalloc_debug=yes
21888 echo "$as_me: failed program was:" >&5
21889 cat conftest.$ac_ext >&5
21890 ac_cv_lib_dmalloc_dmalloc_debug=no
21892 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
21893 LIBS=$ac_check_lib_save_LIBS
21895 echo "$as_me:21895: result: $ac_cv_lib_dmalloc_dmalloc_debug" >&5
21896 echo "${ECHO_T}$ac_cv_lib_dmalloc_dmalloc_debug" >&6
21897 if test $ac_cv_lib_dmalloc_dmalloc_debug = yes; then
21898 cat >>confdefs.h <<EOF
21899 #define HAVE_LIBDMALLOC 1
21902 LIBS="-ldmalloc $LIBS"
21910 echo "$as_me:21910: checking if you want to use dbmalloc for testing" >&5
21911 echo $ECHO_N "checking if you want to use dbmalloc for testing... $ECHO_C" >&6
21913 # Check whether --with-dbmalloc or --without-dbmalloc was given.
21914 if test "${with_dbmalloc+set}" = set; then
21915 withval="$with_dbmalloc"
21917 cat >>confdefs.h <<EOF
21918 #define USE_DBMALLOC 1
21921 : ${with_cflags:=-g}
21922 : ${with_no_leaks:=yes}
21927 echo "$as_me:21927: result: ${with_dbmalloc:-no}" >&5
21928 echo "${ECHO_T}${with_dbmalloc:-no}" >&6
21930 case .$with_cflags in
21940 cf_new_extra_cppflags=
21942 for cf_add_cflags in -g
21944 case $cf_fix_cppflags in
21946 case $cf_add_cflags in
21947 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
21948 case $cf_add_cflags in
21950 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
21952 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
21953 && test -z "${cf_tst_cflags}" \
21954 && cf_fix_cppflags=yes
21956 if test $cf_fix_cppflags = yes ; then
21958 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
21959 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
21962 elif test "${cf_tst_cflags}" = "\"'" ; then
21964 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
21965 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
21971 case "$CPPFLAGS" in
21975 case $cf_add_cflags in
21977 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
21979 CPPFLAGS=`echo "$CPPFLAGS" | \
21980 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
21981 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
21986 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
21987 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
21994 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
21995 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
22002 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
22003 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
22005 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
22007 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
22008 && test -z "${cf_tst_cflags}" \
22009 && cf_fix_cppflags=no
22014 if test -n "$cf_new_cflags" ; then
22016 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
22017 CFLAGS="${CFLAGS}$cf_new_cflags"
22021 if test -n "$cf_new_cppflags" ; then
22023 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
22024 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
22028 if test -n "$cf_new_extra_cppflags" ; then
22030 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
22031 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
22040 if test "$with_dbmalloc" = yes ; then
22041 echo "$as_me:22041: checking for dbmalloc.h" >&5
22042 echo $ECHO_N "checking for dbmalloc.h... $ECHO_C" >&6
22043 if test "${ac_cv_header_dbmalloc_h+set}" = set; then
22044 echo $ECHO_N "(cached) $ECHO_C" >&6
22046 cat >conftest.$ac_ext <<_ACEOF
22047 #line 22047 "configure"
22048 #include "confdefs.h"
22049 #include <dbmalloc.h>
22051 if { (eval echo "$as_me:22051: \"$ac_cpp conftest.$ac_ext\"") >&5
22052 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
22054 egrep -v '^ *\+' conftest.er1 >conftest.err
22056 cat conftest.err >&5
22057 echo "$as_me:22057: \$? = $ac_status" >&5
22058 (exit $ac_status); } >/dev/null; then
22059 if test -s conftest.err; then
22060 ac_cpp_err=$ac_c_preproc_warn_flag
22067 if test -z "$ac_cpp_err"; then
22068 ac_cv_header_dbmalloc_h=yes
22070 echo "$as_me: failed program was:" >&5
22071 cat conftest.$ac_ext >&5
22072 ac_cv_header_dbmalloc_h=no
22074 rm -f conftest.err conftest.$ac_ext
22076 echo "$as_me:22076: result: $ac_cv_header_dbmalloc_h" >&5
22077 echo "${ECHO_T}$ac_cv_header_dbmalloc_h" >&6
22078 if test $ac_cv_header_dbmalloc_h = yes; then
22080 echo "$as_me:22080: checking for debug_malloc in -ldbmalloc" >&5
22081 echo $ECHO_N "checking for debug_malloc in -ldbmalloc... $ECHO_C" >&6
22082 if test "${ac_cv_lib_dbmalloc_debug_malloc+set}" = set; then
22083 echo $ECHO_N "(cached) $ECHO_C" >&6
22085 ac_check_lib_save_LIBS=$LIBS
22086 LIBS="-ldbmalloc $LIBS"
22087 cat >conftest.$ac_ext <<_ACEOF
22088 #line 22088 "configure"
22089 #include "confdefs.h"
22091 /* Override any gcc2 internal prototype to avoid an error. */
22095 /* We use char because int might match the return type of a gcc2
22096 builtin and then its argument prototype would still apply. */
22097 char debug_malloc ();
22106 rm -f conftest.$ac_objext conftest$ac_exeext
22107 if { (eval echo "$as_me:22107: \"$ac_link\"") >&5
22108 (eval $ac_link) 2>&5
22110 echo "$as_me:22110: \$? = $ac_status" >&5
22111 (exit $ac_status); } &&
22112 { ac_try='test -s conftest$ac_exeext'
22113 { (eval echo "$as_me:22113: \"$ac_try\"") >&5
22114 (eval $ac_try) 2>&5
22116 echo "$as_me:22116: \$? = $ac_status" >&5
22117 (exit $ac_status); }; }; then
22118 ac_cv_lib_dbmalloc_debug_malloc=yes
22120 echo "$as_me: failed program was:" >&5
22121 cat conftest.$ac_ext >&5
22122 ac_cv_lib_dbmalloc_debug_malloc=no
22124 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
22125 LIBS=$ac_check_lib_save_LIBS
22127 echo "$as_me:22127: result: $ac_cv_lib_dbmalloc_debug_malloc" >&5
22128 echo "${ECHO_T}$ac_cv_lib_dbmalloc_debug_malloc" >&6
22129 if test $ac_cv_lib_dbmalloc_debug_malloc = yes; then
22130 cat >>confdefs.h <<EOF
22131 #define HAVE_LIBDBMALLOC 1
22134 LIBS="-ldbmalloc $LIBS"
22142 echo "$as_me:22142: checking if you want to use valgrind for testing" >&5
22143 echo $ECHO_N "checking if you want to use valgrind for testing... $ECHO_C" >&6
22145 # Check whether --with-valgrind or --without-valgrind was given.
22146 if test "${with_valgrind+set}" = set; then
22147 withval="$with_valgrind"
22149 cat >>confdefs.h <<EOF
22150 #define USE_VALGRIND 1
22153 : ${with_cflags:=-g}
22154 : ${with_no_leaks:=yes}
22159 echo "$as_me:22159: result: ${with_valgrind:-no}" >&5
22160 echo "${ECHO_T}${with_valgrind:-no}" >&6
22162 case .$with_cflags in
22172 cf_new_extra_cppflags=
22174 for cf_add_cflags in -g
22176 case $cf_fix_cppflags in
22178 case $cf_add_cflags in
22179 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
22180 case $cf_add_cflags in
22182 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
22184 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
22185 && test -z "${cf_tst_cflags}" \
22186 && cf_fix_cppflags=yes
22188 if test $cf_fix_cppflags = yes ; then
22190 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
22191 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
22194 elif test "${cf_tst_cflags}" = "\"'" ; then
22196 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
22197 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
22203 case "$CPPFLAGS" in
22207 case $cf_add_cflags in
22209 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
22211 CPPFLAGS=`echo "$CPPFLAGS" | \
22212 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
22213 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
22218 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
22219 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
22226 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
22227 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
22234 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
22235 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
22237 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
22239 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
22240 && test -z "${cf_tst_cflags}" \
22241 && cf_fix_cppflags=no
22246 if test -n "$cf_new_cflags" ; then
22248 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
22249 CFLAGS="${CFLAGS}$cf_new_cflags"
22253 if test -n "$cf_new_cppflags" ; then
22255 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
22256 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
22260 if test -n "$cf_new_extra_cppflags" ; then
22262 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
22263 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
22272 echo "$as_me:22272: checking if you want to perform memory-leak testing" >&5
22273 echo $ECHO_N "checking if you want to perform memory-leak testing... $ECHO_C" >&6
22275 # Check whether --enable-leaks or --disable-leaks was given.
22276 if test "${enable_leaks+set}" = set; then
22277 enableval="$enable_leaks"
22278 if test "x$enableval" = xno; then with_no_leaks=yes; else with_no_leaks=no; fi
22280 : ${with_no_leaks:=no}
22282 echo "$as_me:22282: result: $with_no_leaks" >&5
22283 echo "${ECHO_T}$with_no_leaks" >&6
22285 if test "$with_no_leaks" = yes ; then
22287 cat >>confdefs.h <<\EOF
22291 cat >>confdefs.h <<\EOF
22292 #define YY_NO_LEAKS 1
22298 if test "x$cf_cv_enable_rpath" != xno
22300 echo "$as_me:22300: checking for an rpath option" >&5
22301 echo $ECHO_N "checking for an rpath option... $ECHO_C" >&6
22302 case $cf_cv_system_name in
22304 if test "$GCC" = yes; then
22305 LD_RPATH_OPT="-Wl,-rpath,"
22307 LD_RPATH_OPT="-rpath "
22310 (linux*|gnu*|k*bsd*-gnu|freebsd*)
22311 LD_RPATH_OPT="-Wl,-rpath,"
22313 (openbsd[2-9].*|mirbsd*)
22314 LD_RPATH_OPT="-Wl,-rpath,"
22317 LD_RPATH_OPT="-rpath "
22320 LD_RPATH_OPT="-Wl,-rpath,"
22323 LD_RPATH_OPT="-rpath "
22331 echo "$as_me:22331: result: $LD_RPATH_OPT" >&5
22332 echo "${ECHO_T}$LD_RPATH_OPT" >&6
22334 case "x$LD_RPATH_OPT" in
22336 echo "$as_me:22336: checking if we need a space after rpath option" >&5
22337 echo $ECHO_N "checking if we need a space after rpath option... $ECHO_C" >&6
22338 cf_save_LIBS="$LIBS"
22340 cf_add_libs="$LIBS"
22343 for cf_add_1lib in ${LD_RPATH_OPT}$libdir; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
22344 # filter duplicates
22345 for cf_add_1lib in $cf_add_0lib; do
22346 for cf_add_2lib in $cf_add_libs; do
22347 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
22352 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
22354 LIBS="$cf_add_libs"
22356 cat >conftest.$ac_ext <<_ACEOF
22357 #line 22357 "configure"
22358 #include "confdefs.h"
22368 rm -f conftest.$ac_objext conftest$ac_exeext
22369 if { (eval echo "$as_me:22369: \"$ac_link\"") >&5
22370 (eval $ac_link) 2>&5
22372 echo "$as_me:22372: \$? = $ac_status" >&5
22373 (exit $ac_status); } &&
22374 { ac_try='test -s conftest$ac_exeext'
22375 { (eval echo "$as_me:22375: \"$ac_try\"") >&5
22376 (eval $ac_try) 2>&5
22378 echo "$as_me:22378: \$? = $ac_status" >&5
22379 (exit $ac_status); }; }; then
22382 echo "$as_me: failed program was:" >&5
22383 cat conftest.$ac_ext >&5
22386 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
22387 LIBS="$cf_save_LIBS"
22388 echo "$as_me:22388: result: $cf_rpath_space" >&5
22389 echo "${ECHO_T}$cf_rpath_space" >&6
22390 test "$cf_rpath_space" = yes && LD_RPATH_OPT="$LD_RPATH_OPT "
22395 echo "$as_me:22395: checking if rpath-hack should be disabled" >&5
22396 echo $ECHO_N "checking if rpath-hack should be disabled... $ECHO_C" >&6
22398 # Check whether --enable-rpath-hack or --disable-rpath-hack was given.
22399 if test "${enable_rpath_hack+set}" = set; then
22400 enableval="$enable_rpath_hack"
22401 test "$enableval" != no && enableval=yes
22402 if test "$enableval" != "yes" ; then
22403 cf_disable_rpath_hack=yes
22405 cf_disable_rpath_hack=no
22409 cf_disable_rpath_hack=no
22412 echo "$as_me:22412: result: $cf_disable_rpath_hack" >&5
22413 echo "${ECHO_T}$cf_disable_rpath_hack" >&6
22414 if test "$cf_disable_rpath_hack" = no ; then
22416 echo "$as_me:22416: checking for updated LDFLAGS" >&5
22417 echo $ECHO_N "checking for updated LDFLAGS... $ECHO_C" >&6
22418 if test -n "$LD_RPATH_OPT" ; then
22419 echo "$as_me:22419: result: maybe" >&5
22420 echo "${ECHO_T}maybe" >&6
22424 # Extract the first word of "$ac_prog", so it can be a program name with args.
22425 set dummy $ac_prog; ac_word=$2
22426 echo "$as_me:22426: checking for $ac_word" >&5
22427 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
22428 if test "${ac_cv_prog_cf_ldd_prog+set}" = set; then
22429 echo $ECHO_N "(cached) $ECHO_C" >&6
22431 if test -n "$cf_ldd_prog"; then
22432 ac_cv_prog_cf_ldd_prog="$cf_ldd_prog" # Let the user override the test.
22434 ac_save_IFS=$IFS; IFS=$ac_path_separator
22436 for ac_dir in $ac_dummy; do
22438 test -z "$ac_dir" && ac_dir=.
22439 $as_executable_p "$ac_dir/$ac_word" || continue
22440 ac_cv_prog_cf_ldd_prog="$ac_prog"
22441 echo "$as_me:22441: found $ac_dir/$ac_word" >&5
22447 cf_ldd_prog=$ac_cv_prog_cf_ldd_prog
22448 if test -n "$cf_ldd_prog"; then
22449 echo "$as_me:22449: result: $cf_ldd_prog" >&5
22450 echo "${ECHO_T}$cf_ldd_prog" >&6
22452 echo "$as_me:22452: result: no" >&5
22453 echo "${ECHO_T}no" >&6
22456 test -n "$cf_ldd_prog" && break
22458 test -n "$cf_ldd_prog" || cf_ldd_prog="no"
22460 cf_rpath_list="/usr/lib /lib"
22461 if test "$cf_ldd_prog" != no
22465 cat >conftest.$ac_ext <<_ACEOF
22466 #line 22466 "configure"
22467 #include "confdefs.h"
22477 rm -f conftest.$ac_objext conftest$ac_exeext
22478 if { (eval echo "$as_me:22478: \"$ac_link\"") >&5
22479 (eval $ac_link) 2>&5
22481 echo "$as_me:22481: \$? = $ac_status" >&5
22482 (exit $ac_status); } &&
22483 { ac_try='test -s conftest$ac_exeext'
22484 { (eval echo "$as_me:22484: \"$ac_try\"") >&5
22485 (eval $ac_try) 2>&5
22487 echo "$as_me:22487: \$? = $ac_status" >&5
22488 (exit $ac_status); }; }; then
22489 cf_rpath_oops=`$cf_ldd_prog conftest$ac_exeext | fgrep ' not found' | sed -e 's% =>.*$%%' |sort | uniq`
22490 cf_rpath_list=`$cf_ldd_prog conftest$ac_exeext | fgrep / | sed -e 's%^.*[ ]/%/%' -e 's%/[^/][^/]*$%%' |sort | uniq`
22492 echo "$as_me: failed program was:" >&5
22493 cat conftest.$ac_ext >&5
22495 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
22497 # If we passed the link-test, but get a "not found" on a given library,
22498 # this could be due to inept reconfiguration of gcc to make it only
22499 # partly honor /usr/local/lib (or whatever). Sometimes this behavior
22500 # is intentional, e.g., installing gcc in /usr/bin and suppressing the
22501 # /usr/local libraries.
22502 if test -n "$cf_rpath_oops"
22504 for cf_rpath_src in $cf_rpath_oops
22506 for cf_rpath_dir in \
22511 if test -f $cf_rpath_dir/lib/$cf_rpath_src
22513 test -n "$verbose" && echo " ...adding -L$cf_rpath_dir/lib to LDFLAGS for $cf_rpath_src" 1>&6
22515 echo "${as_me:-configure}:22515: testing ...adding -L$cf_rpath_dir/lib to LDFLAGS for $cf_rpath_src ..." 1>&5
22517 LDFLAGS="$LDFLAGS -L$cf_rpath_dir/lib"
22525 test -n "$verbose" && echo " ...checking EXTRA_LDFLAGS $EXTRA_LDFLAGS" 1>&6
22527 echo "${as_me:-configure}:22527: testing ...checking EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5
22529 test -n "$verbose" && echo " ...checking LDFLAGS $LDFLAGS" 1>&6
22531 echo "${as_me:-configure}:22531: testing ...checking LDFLAGS $LDFLAGS ..." 1>&5
22534 for cf_rpath_src in $LDFLAGS
22536 case $cf_rpath_src in
22539 # check if this refers to a directory which we will ignore
22541 if test -n "$cf_rpath_list"
22543 for cf_rpath_item in $cf_rpath_list
22545 if test "x$cf_rpath_src" = "x-L$cf_rpath_item"
22553 if test "$cf_rpath_skip" = no
22555 # transform the option
22556 if test "$LD_RPATH_OPT" = "-R " ; then
22557 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%-R %"`
22559 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%$LD_RPATH_OPT%"`
22562 # if we have not already added this, add it now
22563 cf_rpath_tst=`echo "$EXTRA_LDFLAGS" | sed -e "s%$cf_rpath_tmp %%"`
22564 if test "x$cf_rpath_tst" = "x$EXTRA_LDFLAGS"
22566 test -n "$verbose" && echo " ...Filter $cf_rpath_src ->$cf_rpath_tmp" 1>&6
22568 echo "${as_me:-configure}:22568: testing ...Filter $cf_rpath_src ->$cf_rpath_tmp ..." 1>&5
22570 EXTRA_LDFLAGS="$cf_rpath_tmp $EXTRA_LDFLAGS"
22575 cf_rpath_dst="$cf_rpath_dst $cf_rpath_src"
22577 LDFLAGS=$cf_rpath_dst
22579 test -n "$verbose" && echo " ...checked LDFLAGS $LDFLAGS" 1>&6
22581 echo "${as_me:-configure}:22581: testing ...checked LDFLAGS $LDFLAGS ..." 1>&5
22583 test -n "$verbose" && echo " ...checking LIBS $LIBS" 1>&6
22585 echo "${as_me:-configure}:22585: testing ...checking LIBS $LIBS ..." 1>&5
22588 for cf_rpath_src in $LIBS
22590 case $cf_rpath_src in
22593 # check if this refers to a directory which we will ignore
22595 if test -n "$cf_rpath_list"
22597 for cf_rpath_item in $cf_rpath_list
22599 if test "x$cf_rpath_src" = "x-L$cf_rpath_item"
22607 if test "$cf_rpath_skip" = no
22609 # transform the option
22610 if test "$LD_RPATH_OPT" = "-R " ; then
22611 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%-R %"`
22613 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%$LD_RPATH_OPT%"`
22616 # if we have not already added this, add it now
22617 cf_rpath_tst=`echo "$EXTRA_LDFLAGS" | sed -e "s%$cf_rpath_tmp %%"`
22618 if test "x$cf_rpath_tst" = "x$EXTRA_LDFLAGS"
22620 test -n "$verbose" && echo " ...Filter $cf_rpath_src ->$cf_rpath_tmp" 1>&6
22622 echo "${as_me:-configure}:22622: testing ...Filter $cf_rpath_src ->$cf_rpath_tmp ..." 1>&5
22624 EXTRA_LDFLAGS="$cf_rpath_tmp $EXTRA_LDFLAGS"
22629 cf_rpath_dst="$cf_rpath_dst $cf_rpath_src"
22633 test -n "$verbose" && echo " ...checked LIBS $LIBS" 1>&6
22635 echo "${as_me:-configure}:22635: testing ...checked LIBS $LIBS ..." 1>&5
22637 test -n "$verbose" && echo " ...checked EXTRA_LDFLAGS $EXTRA_LDFLAGS" 1>&6
22639 echo "${as_me:-configure}:22639: testing ...checked EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5
22642 echo "$as_me:22642: result: no" >&5
22643 echo "${ECHO_T}no" >&6
22651 ac_config_files="$ac_config_files Makefile"
22652 ac_config_commands="$ac_config_commands default"
22653 cat >confcache <<\_ACEOF
22654 # This file is a shell script that caches the results of configure
22655 # tests run on this system so they can be shared between configure
22656 # scripts and configure runs, see configure's option --config-cache.
22657 # It is not useful on other systems. If it contains results you don't
22658 # want to keep, you may remove or edit it.
22660 # config.status only pays attention to the cache file if you give it
22661 # the --recheck option to rerun configure.
22663 # `ac_cv_env_foo' variables (set or unset) will be overriden when
22664 # loading this file, other *unset* `ac_cv_foo' will be assigned the
22665 # following values.
22669 # The following way of writing the cache mishandles newlines in values,
22670 # but we know of no workaround that is simple, portable, and efficient.
22671 # So, don't put newlines in cache variables' values.
22672 # Ultrix sh set writes to stderr and can't be redirected directly,
22673 # and sets the high bit in the cache file unless we assign to the vars.
22676 case `(ac_space=' '; set | grep ac_space) 2>&1` in
22678 # `set' does not quote correctly, so add quotes (double-quote
22679 # substitution turns \\\\ into \\, and sed turns \\ into \).
22682 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
22685 # `set' quotes correctly as required by POSIX, so do not add quotes.
22687 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
22694 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
22696 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
22698 if cmp -s $cache_file confcache; then :; else
22699 if test -w $cache_file; then
22700 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
22701 cat confcache >$cache_file
22703 echo "not updating unwritable cache $cache_file"
22708 test "x$prefix" = xNONE && prefix=$ac_default_prefix
22709 # Let make expand exec_prefix.
22710 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
22712 # VPATH may cause trouble with some makes, so we remove $(srcdir),
22713 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
22714 # trailing colons and then remove the whole line if VPATH becomes empty
22715 # (actually we leave an empty line to preserve line numbers).
22716 if test "x$srcdir" = x.; then
22717 ac_vpsub='/^[ ]*VPATH[ ]*=/{
22718 s/:*\$(srcdir):*/:/;
22719 s/:*\${srcdir}:*/:/;
22721 s/^\([^=]*=[ ]*\):*/\1/;
22727 DEFS=-DHAVE_CONFIG_H
22729 : ${CONFIG_STATUS=./config.status}
22730 ac_clean_files_save=$ac_clean_files
22731 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
22732 { echo "$as_me:22732: creating $CONFIG_STATUS" >&5
22733 echo "$as_me: creating $CONFIG_STATUS" >&6;}
22734 cat >$CONFIG_STATUS <<_ACEOF
22736 # Generated automatically by configure.
22737 # Run this file to recreate the current configuration.
22738 # Compiler output produced by configure, useful for debugging
22739 # configure, is in config.log if it exists.
22742 SHELL=\${CONFIG_SHELL-$SHELL}
22743 ac_cs_invocation="\$0 \$@"
22745 CLICOLOR_FORCE= GREP_OPTIONS=
22746 unset CLICOLOR_FORCE GREP_OPTIONS
22749 cat >>$CONFIG_STATUS <<\_ACEOF
22750 # Be Bourne compatible
22751 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
22754 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
22758 # Name of the executable.
22759 as_me=`echo "$0" |sed 's,.*[\\/],,'`
22761 if expr a : '\(a\)' >/dev/null 2>&1; then
22767 rm -f conf$$ conf$$.exe conf$$.file
22769 if ln -s conf$$.file conf$$ 2>/dev/null; then
22770 # We could just check for DJGPP; but this test a) works b) is more generic
22771 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
22772 if test -f conf$$.exe; then
22773 # Don't use ln at all; we don't have any links
22778 elif ln conf$$.file conf$$ 2>/dev/null; then
22783 rm -f conf$$ conf$$.exe conf$$.file
22785 as_executable_p="test -f"
22787 # Support unset when possible.
22788 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
22795 $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
22796 $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
22797 $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
22798 $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
22799 $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
22800 $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
22801 $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
22802 $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
22805 # We need space, tab and new line, in precisely that order.
22811 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
22817 # Files that config.status was made for.
22818 if test -n "$ac_config_files"; then
22819 echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
22822 if test -n "$ac_config_headers"; then
22823 echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
22826 if test -n "$ac_config_links"; then
22827 echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
22830 if test -n "$ac_config_commands"; then
22831 echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
22834 cat >>$CONFIG_STATUS <<\EOF
22837 \`$as_me' instantiates files from templates according to the
22838 current configuration.
22840 Usage: $0 [OPTIONS] [FILE]...
22842 -h, --help print this help, then exit
22843 -V, --version print version number, then exit
22844 -d, --debug don't remove temporary files
22845 --recheck update $as_me by reconfiguring in the same conditions
22846 --file=FILE[:TEMPLATE]
22847 instantiate the configuration file FILE
22848 --header=FILE[:TEMPLATE]
22849 instantiate the configuration header FILE
22851 Configuration files:
22854 Configuration headers:
22857 Configuration commands:
22860 Report bugs to <dickey@invisible-island.net>."
22863 cat >>$CONFIG_STATUS <<EOF
22866 configured by $0, generated by GNU Autoconf 2.52.20200802,
22867 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
22869 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
22870 Free Software Foundation, Inc.
22871 This config.status script is free software; the Free Software Foundation
22872 gives unlimited permission to copy, distribute and modify it."
22877 cat >>$CONFIG_STATUS <<\EOF
22878 # If no file are specified by the user, then we need to provide default
22879 # value. By we need to know if files were specified by the user.
22885 ac_option=`expr "x$1" : 'x\([^=]*\)='`
22886 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
22888 set dummy "$ac_option" "$ac_optarg" ${1+"$@"}
22892 *) # This is not an option, so the user has probably given explicit
22894 ac_need_defaults=false;;
22898 # Handling of the options.
22900 cat >>$CONFIG_STATUS <<EOF
22901 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
22902 echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion"
22903 exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;;
22905 cat >>$CONFIG_STATUS <<\EOF
22906 --version | --vers* | -V )
22907 echo "$ac_cs_version"; exit 0 ;;
22909 # Conflict between --help and --header
22910 { { echo "$as_me:22910: error: ambiguous option: $1
22911 Try \`$0 --help' for more information." >&5
22912 echo "$as_me: error: ambiguous option: $1
22913 Try \`$0 --help' for more information." >&2;}
22914 { (exit 1); exit 1; }; };;
22915 --help | --hel | -h )
22916 echo "$ac_cs_usage"; exit 0 ;;
22917 --debug | --d* | -d )
22919 --file | --fil | --fi | --f )
22921 CONFIG_FILES="$CONFIG_FILES $1"
22922 ac_need_defaults=false;;
22923 --header | --heade | --head | --hea )
22925 CONFIG_HEADERS="$CONFIG_HEADERS $1"
22926 ac_need_defaults=false;;
22928 # This is an error.
22929 -*) { { echo "$as_me:22929: error: unrecognized option: $1
22930 Try \`$0 --help' for more information." >&5
22931 echo "$as_me: error: unrecognized option: $1
22932 Try \`$0 --help' for more information." >&2;}
22933 { (exit 1); exit 1; }; } ;;
22935 *) ac_config_targets="$ac_config_targets $1" ;;
22944 ## ----------------------- ##
22945 ## Running config.status. ##
22946 ## ----------------------- ##
22948 This file was extended by $as_me 2.52.20200802, executed with
22949 CONFIG_FILES = $CONFIG_FILES
22950 CONFIG_HEADERS = $CONFIG_HEADERS
22951 CONFIG_LINKS = $CONFIG_LINKS
22952 CONFIG_COMMANDS = $CONFIG_COMMANDS
22953 > $ac_cs_invocation
22954 on `(hostname || uname -n) 2>/dev/null | sed 1q`
22959 cat >>$CONFIG_STATUS <<EOF
22961 # INIT-COMMANDS section.
22971 cat >>$CONFIG_STATUS <<\EOF
22972 for ac_config_target in $ac_config_targets
22974 case "$ac_config_target" in
22975 # Handling of arguments.
22976 "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
22977 "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
22978 "ncurses_cfg.h" ) CONFIG_HEADERS="$CONFIG_HEADERS ncurses_cfg.h:ncurses_tst.hin" ;;
22979 *) { { echo "$as_me:22979: error: invalid argument: $ac_config_target" >&5
22980 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
22981 { (exit 1); exit 1; }; };;
22985 # If the user did not use the arguments to specify the items to instantiate,
22986 # then the envvar interface is used. Set only those that are not.
22987 # We use the long form for the default assignment because of an extremely
22988 # bizarre bug on SunOS 4.1.3.
22989 if $ac_need_defaults; then
22990 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
22991 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
22992 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
22995 # Create a temporary directory, and hook for its removal unless debugging.
22998 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
22999 trap '{ (exit 1); exit 1; }' 1 2 13 15
23002 # Create a (secure) tmp directory for tmp files.
23005 tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` &&
23006 test -n "$tmp" && test -d "$tmp"
23009 tmp=$TMPDIR/cs$$-$RANDOM
23010 (umask 077 && mkdir $tmp)
23013 echo "$me: cannot create a temporary directory in $TMPDIR" >&2
23014 { (exit 1); exit 1; }
23019 cat >>$CONFIG_STATUS <<EOF
23022 # CONFIG_FILES section.
23025 # No need to generate the scripts if there are no CONFIG_FILES.
23026 # This happens for instance when ./config.status config.h
23027 if test -n "\$CONFIG_FILES"; then
23028 # Protect against being on the right side of a sed subst in config.status.
23029 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
23030 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
23031 s,@SHELL@,$SHELL,;t t
23032 s,@exec_prefix@,$exec_prefix,;t t
23033 s,@prefix@,$prefix,;t t
23034 s,@program_transform_name@,$program_transform_name,;t t
23035 s,@bindir@,$bindir,;t t
23036 s,@sbindir@,$sbindir,;t t
23037 s,@libexecdir@,$libexecdir,;t t
23038 s,@datarootdir@,$datarootdir,;t t
23039 s,@datadir@,$datadir,;t t
23040 s,@sysconfdir@,$sysconfdir,;t t
23041 s,@sharedstatedir@,$sharedstatedir,;t t
23042 s,@localstatedir@,$localstatedir,;t t
23043 s,@runstatedir@,$runstatedir,;t t
23044 s,@libdir@,$libdir,;t t
23045 s,@includedir@,$includedir,;t t
23046 s,@oldincludedir@,$oldincludedir,;t t
23047 s,@infodir@,$infodir,;t t
23048 s,@mandir@,$mandir,;t t
23049 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
23050 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
23051 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
23052 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
23053 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
23054 s,@build_alias@,$build_alias,;t t
23055 s,@host_alias@,$host_alias,;t t
23056 s,@target_alias@,$target_alias,;t t
23057 s,@ECHO_C@,$ECHO_C,;t t
23058 s,@ECHO_N@,$ECHO_N,;t t
23059 s,@ECHO_T@,$ECHO_T,;t t
23060 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
23061 s,@DEFS@,$DEFS,;t t
23062 s,@LIBS@,$LIBS,;t t
23063 s,@build@,$build,;t t
23064 s,@build_cpu@,$build_cpu,;t t
23065 s,@build_vendor@,$build_vendor,;t t
23066 s,@build_os@,$build_os,;t t
23067 s,@host@,$host,;t t
23068 s,@host_cpu@,$host_cpu,;t t
23069 s,@host_vendor@,$host_vendor,;t t
23070 s,@host_os@,$host_os,;t t
23071 s,@SET_MAKE@,$SET_MAKE,;t t
23073 s,@CFLAGS@,$CFLAGS,;t t
23074 s,@LDFLAGS@,$LDFLAGS,;t t
23075 s,@CPPFLAGS@,$CPPFLAGS,;t t
23076 s,@ac_ct_CC@,$ac_ct_CC,;t t
23077 s,@EXEEXT@,$EXEEXT,;t t
23078 s,@OBJEXT@,$OBJEXT,;t t
23079 s,@EXTRA_CPPFLAGS@,$EXTRA_CPPFLAGS,;t t
23082 s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
23083 s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
23084 s,@INSTALL_DATA@,$INSTALL_DATA,;t t
23085 s,@INSTALL_OPT_S@,$INSTALL_OPT_S,;t t
23086 s,@INSTALL_OPT_O@,$INSTALL_OPT_O,;t t
23087 s,@LINT@,$LINT,;t t
23088 s,@LINT_OPTS@,$LINT_OPTS,;t t
23089 s,@CTAGS@,$CTAGS,;t t
23090 s,@ETAGS@,$ETAGS,;t t
23091 s,@MAKE_LOWER_TAGS@,$MAKE_LOWER_TAGS,;t t
23092 s,@MAKE_UPPER_TAGS@,$MAKE_UPPER_TAGS,;t t
23093 s,@MATH_LIB@,$MATH_LIB,;t t
23094 s,@top_builddir@,$top_builddir,;t t
23095 s,@CC_G_OPT@,$CC_G_OPT,;t t
23096 s,@CC_SHARED_OPTS@,$CC_SHARED_OPTS,;t t
23097 s,@DFT_DEP_SUFFIX@,$DFT_DEP_SUFFIX,;t t
23098 s,@DFT_OBJ_SUBDIR@,$DFT_OBJ_SUBDIR,;t t
23099 s,@DFT_UPR_MODEL@,$DFT_UPR_MODEL,;t t
23101 s,@LDFLAGS_SHARED@,$LDFLAGS_SHARED,;t t
23102 s,@LDFLAGS_STATIC@,$LDFLAGS_STATIC,;t t
23103 s,@LD_MODEL@,$LD_MODEL,;t t
23104 s,@LD_SHARED_OPTS@,$LD_SHARED_OPTS,;t t
23105 s,@LIBTOOL@,$LIBTOOL,;t t
23106 s,@LIBTOOL_OPTS@,$LIBTOOL_OPTS,;t t
23107 s,@LIB_CLEAN@,$LIB_CLEAN,;t t
23108 s,@LIB_COMPILE@,$LIB_COMPILE,;t t
23109 s,@LIB_LINK@,$LIB_LINK,;t t
23110 s,@LINK_TESTS@,$LINK_TESTS,;t t
23111 s,@LOCAL_LDFLAGS@,$LOCAL_LDFLAGS,;t t
23112 s,@PACKAGE@,$PACKAGE,;t t
23113 s,@PTHREAD@,$PTHREAD,;t t
23114 s,@TEST_ARGS@,$TEST_ARGS,;t t
23115 s,@TEST_DEPS@,$TEST_DEPS,;t t
23116 s,@TEST_LIBS@,$TEST_LIBS,;t t
23117 s,@TINFO_LDFLAGS@,$TINFO_LDFLAGS,;t t
23118 s,@TINFO_LIBS@,$TINFO_LIBS,;t t
23119 s,@cf_cv_abi_version@,$cf_cv_abi_version,;t t
23120 s,@cf_cv_rel_version@,$cf_cv_rel_version,;t t
23121 s,@includesubdir@,$includesubdir,;t t
23122 s,@PKG_CONFIG@,$PKG_CONFIG,;t t
23123 s,@ac_pt_PKG_CONFIG@,$ac_pt_PKG_CONFIG,;t t
23124 s,@ECHO_LT@,$ECHO_LT,;t t
23125 s,@ECHO_LD@,$ECHO_LD,;t t
23126 s,@RULE_CC@,$RULE_CC,;t t
23127 s,@SHOW_CC@,$SHOW_CC,;t t
23128 s,@ECHO_CC@,$ECHO_CC,;t t
23129 s,@NCURSES_WRAP_PREFIX@,$NCURSES_WRAP_PREFIX,;t t
23130 s,@NCURSES_CONFIG@,$NCURSES_CONFIG,;t t
23131 s,@ac_ct_NCURSES_CONFIG@,$ac_ct_NCURSES_CONFIG,;t t
23132 s,@X_CFLAGS@,$X_CFLAGS,;t t
23133 s,@X_PRE_LIBS@,$X_PRE_LIBS,;t t
23134 s,@X_LIBS@,$X_LIBS,;t t
23135 s,@X_EXTRA_LIBS@,$X_EXTRA_LIBS,;t t
23136 s,@XCURSES_CONFIG@,$XCURSES_CONFIG,;t t
23137 s,@ac_ct_XCURSES_CONFIG@,$ac_ct_XCURSES_CONFIG,;t t
23138 s,@RGB_PATH@,$RGB_PATH,;t t
23139 s,@no_x11_rgb@,$no_x11_rgb,;t t
23140 s,@FORM_NAME@,$FORM_NAME,;t t
23141 s,@MENU_NAME@,$MENU_NAME,;t t
23142 s,@PANEL_NAME@,$PANEL_NAME,;t t
23143 s,@EXTRA_CFLAGS@,$EXTRA_CFLAGS,;t t
23144 s,@cf_ldd_prog@,$cf_ldd_prog,;t t
23145 s,@EXTRA_LDFLAGS@,$EXTRA_LDFLAGS,;t t
23150 cat >>$CONFIG_STATUS <<\EOF
23151 # Split the substitutions into bite-sized pieces for seds with
23152 # small command number limits, like on Digital OSF/1 and HP-UX.
23153 ac_max_sed_lines=48
23154 ac_sed_frag=1 # Number of current file.
23155 ac_beg=1 # First line for current file.
23156 ac_end=$ac_max_sed_lines # Line after last line for current file.
23159 while $ac_more_lines; do
23160 if test $ac_beg -gt 1; then
23161 sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
23163 sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
23165 if test ! -s $tmp/subs.frag; then
23166 ac_more_lines=false
23168 # The purpose of the label and of the branching condition is to
23169 # speed up the sed processing (if there are no `@' at all, there
23170 # is no need to browse any of the substitutions).
23171 # These are the two extra sed commands mentioned above.
23173 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
23174 # It is possible to make a multiline substitution using escaped newlines.
23175 # Ensure that we do not split the substitution between script fragments.
23177 ac_END=`expr $ac_end + $ac_max_sed_lines`
23178 sed "1,${ac_BEG}d; ${ac_END}p; q" $tmp/subs.sed >$tmp/subs.next
23179 if test -s $tmp/subs.next; then
23180 grep '^s,@[^@,][^@,]*@,.*\\$' $tmp/subs.next >$tmp/subs.edit
23181 if test ! -s $tmp/subs.edit; then
23182 grep "^s,@[^@,][^@,]*@,.*,;t t$" $tmp/subs.next >$tmp/subs.edit
23183 if test ! -s $tmp/subs.edit; then
23184 if test $ac_beg -gt 1; then
23185 ac_end=`expr $ac_end - 1`
23192 if test -z "$ac_sed_cmds"; then
23193 ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
23195 ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
23197 ac_sed_frag=`expr $ac_sed_frag + 1`
23199 ac_end=`expr $ac_end + $ac_max_sed_lines`
23202 if test -z "$ac_sed_cmds"; then
23205 fi # test -n "$CONFIG_FILES"
23208 cat >>$CONFIG_STATUS <<\EOF
23209 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
23210 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
23212 - | *:- | *:-:* ) # input from stdin
23214 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
23215 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
23216 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
23217 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
23218 * ) ac_file_in=$ac_file.in ;;
23221 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
23222 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23223 X"$ac_file" : 'X\(//\)[^/]' \| \
23224 X"$ac_file" : 'X\(//\)$' \| \
23225 X"$ac_file" : 'X\(/\)' \| \
23226 . : '\(.\)' 2>/dev/null ||
23228 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
23229 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
23230 /^X\(\/\/\)$/{ s//\1/; q; }
23231 /^X\(\/\).*/{ s//\1/; q; }
23233 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
23234 { case "$ac_dir" in
23235 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
23239 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
23240 case $as_mkdir_dir in
23241 # Skip DOS drivespec
23242 ?:) as_incr_dir=$as_mkdir_dir ;;
23244 as_incr_dir=$as_incr_dir/$as_mkdir_dir
23245 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
23250 ac_dir_suffix="/`echo $ac_dir|sed 's,^\./,,'`"
23251 # A "../" for each directory in $ac_dir_suffix.
23252 ac_dots=`echo "$ac_dir_suffix" | sed 's,/[^/]*,../,g'`
23254 ac_dir_suffix= ac_dots=
23259 if test -z "$ac_dots"; then
23262 ac_top_srcdir=`echo $ac_dots | sed 's,/$,,'`
23264 [\\/]* | ?:[\\/]* )
23265 ac_srcdir=$srcdir$ac_dir_suffix;
23266 ac_top_srcdir=$srcdir ;;
23267 *) # Relative path.
23268 ac_srcdir=$ac_dots$srcdir$ac_dir_suffix
23269 ac_top_srcdir=$ac_dots$srcdir ;;
23273 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
23274 *) ac_INSTALL=$ac_dots$INSTALL ;;
23277 if test x"$ac_file" != x-; then
23278 { echo "$as_me:23278: creating $ac_file" >&5
23279 echo "$as_me: creating $ac_file" >&6;}
23282 # Let's still pretend it is `configure' which instantiates (i.e., don't
23283 # use $as_me), people would be surprised to read:
23284 # /* config.h. Generated automatically by config.status. */
23285 configure_input="Generated automatically from `echo $ac_file_in |
23286 sed 's,.*/,,'` by configure."
23288 # First look for the input files in the build tree, otherwise in the
23290 ac_file_inputs=`IFS=:
23291 for f in $ac_file_in; do
23293 -) echo $tmp/stdin ;;
23295 # Absolute (can't be DOS-style, as IFS=:)
23296 test -f "$f" || { { echo "$as_me:23296: error: cannot find input file: $f" >&5
23297 echo "$as_me: error: cannot find input file: $f" >&2;}
23298 { (exit 1); exit 1; }; }
23301 if test -f "$f"; then
23304 elif test -f "$srcdir/$f"; then
23309 { { echo "$as_me:23309: error: cannot find input file: $f" >&5
23310 echo "$as_me: error: cannot find input file: $f" >&2;}
23311 { (exit 1); exit 1; }; }
23314 done` || { (exit 1); exit 1; }
23316 cat >>$CONFIG_STATUS <<\EOF
23317 ac_warn_datarootdir=no
23318 if test x"$ac_file" != x-; then
23319 for ac_item in $ac_file_inputs
23321 ac_seen=`grep '@\(datadir\|mandir\|infodir\)@' $ac_item`
23322 if test -n "$ac_seen"; then
23323 ac_used=`grep '@datarootdir@' $ac_item`
23324 if test -z "$ac_used"; then
23325 { echo "$as_me:23325: WARNING: datarootdir was used implicitly but not set:
23327 echo "$as_me: WARNING: datarootdir was used implicitly but not set:
23329 ac_warn_datarootdir=yes
23332 ac_seen=`grep '${datarootdir}' $ac_item`
23333 if test -n "$ac_seen"; then
23334 { echo "$as_me:23334: WARNING: datarootdir was used explicitly but not set:
23336 echo "$as_me: WARNING: datarootdir was used explicitly but not set:
23338 ac_warn_datarootdir=yes
23343 if test "x$ac_warn_datarootdir" = xyes; then
23344 ac_sed_cmds="$ac_sed_cmds | sed -e 's,@datarootdir@,\${prefix}/share,g' -e 's,\${datarootdir},\${prefix}/share,g'"
23348 cat >>$CONFIG_STATUS <<EOF
23352 cat >>$CONFIG_STATUS <<\EOF
23354 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
23355 s,@configure_input@,$configure_input,;t t
23356 s,@srcdir@,$ac_srcdir,;t t
23357 s,@top_srcdir@,$ac_top_srcdir,;t t
23358 s,@INSTALL@,$ac_INSTALL,;t t
23359 " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
23361 if test x"$ac_file" != x-; then
23362 cp $tmp/out $ac_file
23364 for ac_name in prefix exec_prefix datarootdir
23366 ac_seen=`fgrep -n '${'$ac_name'[:=].*}' $ac_file`
23367 if test -n "$ac_seen"; then
23368 ac_init=`egrep '[ ]*'$ac_name'[ ]*=' $ac_file`
23369 if test -z "$ac_init"; then
23370 ac_seen=`echo "$ac_seen" |sed -e 's,^,'$ac_file':,'`
23371 { echo "$as_me:23371: WARNING: Variable $ac_name is used but was not set:
23373 echo "$as_me: WARNING: Variable $ac_name is used but was not set:
23378 egrep -n '@[a-z_][a-z_0-9]+@' $ac_file >$tmp/out
23379 egrep -n '@[A-Z_][A-Z_0-9]+@' $ac_file >>$tmp/out
23380 if test -s $tmp/out; then
23381 ac_seen=`sed -e 's,^,'$ac_file':,' < $tmp/out`
23382 { echo "$as_me:23382: WARNING: Some variables may not be substituted:
23384 echo "$as_me: WARNING: Some variables may not be substituted:
23394 cat >>$CONFIG_STATUS <<\EOF
23397 # CONFIG_HEADER section.
23400 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
23401 # NAME is the cpp macro being defined and VALUE is the value it is being given.
23403 # ac_d sets the value in "#define NAME VALUE" lines.
23404 ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
23405 ac_dB='[ ].*$,\1#\2'
23408 # ac_i turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
23409 ac_iA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
23410 ac_iB='\([ ]\),\1#\2define\3'
23413 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
23414 ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
23415 ac_uB='$,\1#\2define\3'
23419 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
23420 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
23422 - | *:- | *:-:* ) # input from stdin
23424 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
23425 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
23426 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
23427 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
23428 * ) ac_file_in=$ac_file.in ;;
23431 test x"$ac_file" != x- && { echo "$as_me:23431: creating $ac_file" >&5
23432 echo "$as_me: creating $ac_file" >&6;}
23434 # First look for the input files in the build tree, otherwise in the
23436 ac_file_inputs=`IFS=:
23437 for f in $ac_file_in; do
23439 -) echo $tmp/stdin ;;
23441 # Absolute (can't be DOS-style, as IFS=:)
23442 test -f "$f" || { { echo "$as_me:23442: error: cannot find input file: $f" >&5
23443 echo "$as_me: error: cannot find input file: $f" >&2;}
23444 { (exit 1); exit 1; }; }
23447 if test -f "$f"; then
23450 elif test -f "$srcdir/$f"; then
23455 { { echo "$as_me:23455: error: cannot find input file: $f" >&5
23456 echo "$as_me: error: cannot find input file: $f" >&2;}
23457 { (exit 1); exit 1; }; }
23460 done` || { (exit 1); exit 1; }
23461 # Remove the trailing spaces.
23462 sed 's/[ ]*$//' $ac_file_inputs >$tmp/in
23466 # Transform confdefs.h into a list of #define's. We won't use it as a sed
23467 # script, but as data to insert where we see @DEFS@. We expect AC_SAVE_DEFS to
23468 # be either 'cat' or 'sort'.
23469 cat confdefs.h | uniq >conftest.vals
23471 # Break up conftest.vals because some shells have a limit on
23472 # the size of here documents, and old seds have small limits too.
23474 rm -f conftest.tail
23475 echo ' rm -f conftest.frag' >> $CONFIG_STATUS
23476 while grep . conftest.vals >/dev/null
23478 # Write chunks of a limited-size here document to conftest.frag.
23479 echo ' cat >> conftest.frag <<CEOF' >> $CONFIG_STATUS
23480 sed ${ac_max_here_lines}q conftest.vals | sed -e 's/#ifdef.*/#if 0/' >> $CONFIG_STATUS
23481 echo 'CEOF' >> $CONFIG_STATUS
23482 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
23483 rm -f conftest.vals
23484 mv conftest.tail conftest.vals
23486 rm -f conftest.vals
23488 # Run sed to substitute the contents of conftest.frag into $tmp/in at the
23490 echo ' cat >> conftest.edit <<CEOF
23491 /@DEFS@/r conftest.frag
23494 sed -f conftest.edit $tmp/in > $tmp/out
23496 mv $tmp/out $tmp/in
23497 rm -f conftest.edit conftest.frag
23498 ' >> $CONFIG_STATUS
23500 cat >>$CONFIG_STATUS <<\EOF
23501 # Let's still pretend it is `configure' which instantiates (i.e., don't
23502 # use $as_me), people would be surprised to read:
23503 # /* config.h. Generated automatically by config.status. */
23504 if test x"$ac_file" = x-; then
23505 echo "/* Generated automatically by configure. */" >$tmp/config.h
23507 echo "/* $ac_file. Generated automatically by configure. */" >$tmp/config.h
23509 cat $tmp/in >>$tmp/config.h
23511 if test x"$ac_file" != x-; then
23512 if cmp -s $ac_file $tmp/config.h 2>/dev/null; then
23513 { echo "$as_me:23513: $ac_file is unchanged" >&5
23514 echo "$as_me: $ac_file is unchanged" >&6;}
23516 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23517 X"$ac_file" : 'X\(//\)[^/]' \| \
23518 X"$ac_file" : 'X\(//\)$' \| \
23519 X"$ac_file" : 'X\(/\)' \| \
23520 . : '\(.\)' 2>/dev/null ||
23522 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
23523 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
23524 /^X\(\/\/\)$/{ s//\1/; q; }
23525 /^X\(\/\).*/{ s//\1/; q; }
23527 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
23528 { case "$ac_dir" in
23529 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
23533 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
23534 case $as_mkdir_dir in
23535 # Skip DOS drivespec
23536 ?:) as_incr_dir=$as_mkdir_dir ;;
23538 as_incr_dir=$as_incr_dir/$as_mkdir_dir
23539 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
23546 mv $tmp/config.h $ac_file
23550 rm -f $tmp/config.h
23554 cat >>$CONFIG_STATUS <<\EOF
23556 # CONFIG_COMMANDS section.
23558 for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
23559 ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
23560 ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
23567 if test ! -d $srcdir/$cf_dir; then
23569 elif test -f $srcdir/$cf_dir/programs; then
23570 $AWK -f $srcdir/mk-test.awk INSTALL=yes ECHO_LINK="$ECHO_LD" $srcdir/$cf_dir/programs >>$cf_dir/Makefile
23574 cat >>Makefile <<TEST_EOF
23576 # These rules are generated so we do not rely on suffix rules, which do not
23577 # work consistently for different make-programs (the '\$(MODEL)/' confuses
23578 # some, and the '\$x' confuses others).
23581 LIST=`sed -e 's/[ ].*//' -e '/^[#@]/d' $srcdir/modules`
23584 cat >>Makefile <<TEST_EOF
23586 \$(MODEL)/$N.o : \$(srcdir)/$N.c \\
23587 \$(srcdir)/test.priv.h \\
23590 $ECHO_CC\$(CC) -c \$(CFLAGS_DEFAULT) -DMODULE_NAME="$N" \$(srcdir)/$N.c
23594 if test -f ../config.guess && test -f ../config.sub
23596 cat >>Makefile <<TEST_EOF
23598 # if we used CF_INHERIT for getting these files, we can remove them
23600 rm -f config.guess config.sub
23608 cat >>$CONFIG_STATUS <<\EOF
23610 { (exit 0); exit 0; }
23612 chmod +x $CONFIG_STATUS
23613 ac_clean_files=$ac_clean_files_save
23615 # configure is writing to config.log, and then calls config.status.
23616 # config.status does its own redirection, appending to config.log.
23617 # Unfortunately, on DOS this fails, as config.log is still kept open
23618 # by configure, so config.status won't be able to write to it; its
23619 # output is simply discarded. So we exec the FD to /dev/null,
23620 # effectively closing config.log, so it can be properly (re)opened and
23621 # appended to by config.status. When coming back to configure, we
23622 # need to make the FD available again.
23623 if test "$no_create" != yes; then
23626 $SHELL $CONFIG_STATUS || ac_cs_success=false
23628 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
23629 # would make configure fail if this is the last instruction.
23630 $ac_cs_success || { (exit 1); exit 1; }