2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by Autoconf 2.52.20181006.
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 --disable-panel disable checks for panel functions
690 --disable-menu disable checks for menu functions
691 --disable-form disable checks for form functions
692 Testing/development Options:
693 --enable-warnings test: turn on gcc compiler warnings
694 --with-dmalloc test: use Gray Watson's dmalloc library
695 --with-dbmalloc test: use Conor Cahill's dbmalloc library
696 --with-valgrind test: use valgrind
697 --disable-leaks test: free permanent memory, analyze leaks
698 --disable-rpath-hack don't add rpath options for additional libraries
700 Some influential environment variables:
701 CC C compiler command
702 CFLAGS C compiler flags
703 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
704 nonstandard directory <lib dir>
705 CPPFLAGS C/C++ preprocessor flags, e.g. -I<include dir> if you have
706 headers in a nonstandard directory <include dir>
709 Use these variables to override the choices made by `configure' or to help
710 it to find libraries and programs with nonstandard names/locations.
715 if test "$ac_init_help" = "recursive"; then
716 # If there are subdirs, report their specific --help.
718 for ac_subdir in : $ac_subdirs_all; do test "x$ac_subdir" = x: && continue
720 # A "../" for each directory in /$ac_subdir.
721 ac_dots=`echo $ac_subdir |
722 sed 's,^\./,,;s,[^/]$,&/,;s,[^/]*/,../,g'`
725 .) # No --srcdir option. We are building in place.
726 ac_sub_srcdir=$srcdir ;;
727 [\\/]* | ?:[\\/]* ) # Absolute path.
728 ac_sub_srcdir=$srcdir/$ac_subdir ;;
730 ac_sub_srcdir=$ac_dots$srcdir/$ac_subdir ;;
733 # Check for guested configure; otherwise get Cygnus style configure.
734 if test -f $ac_sub_srcdir/configure.gnu; then
736 $SHELL $ac_sub_srcdir/configure.gnu --help=recursive
737 elif test -f $ac_sub_srcdir/configure; then
739 $SHELL $ac_sub_srcdir/configure --help=recursive
740 elif test -f $ac_sub_srcdir/configure.ac ||
741 test -f $ac_sub_srcdir/configure.in; then
745 echo "$as_me: WARNING: no configuration information is in $ac_subdir" >&2
751 test -n "$ac_init_help" && exit 0
752 if $ac_init_version; then
755 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
756 Free Software Foundation, Inc.
757 This configure script is free software; the Free Software Foundation
758 gives unlimited permission to copy, distribute and modify it.
764 This file contains any messages produced by compilers while
765 running configure, to aid debugging if configure makes a mistake.
767 It was created by $as_me, which was
768 generated by GNU Autoconf 2.52.20181006. Invocation command line was
779 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
780 uname -m = `(uname -m) 2>/dev/null || echo unknown`
781 uname -r = `(uname -r) 2>/dev/null || echo unknown`
782 uname -s = `(uname -s) 2>/dev/null || echo unknown`
783 uname -v = `(uname -v) 2>/dev/null || echo unknown`
785 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
786 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
788 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
789 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
790 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
791 hostinfo = `(hostinfo) 2>/dev/null || echo unknown`
792 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
793 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
794 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
808 # Keep a trace of the command line.
809 # Strip out --no-create and --no-recursion so they do not pile up.
810 # Also quote any args containing shell meta-characters.
816 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
817 | --no-cr | --no-c) ;;
818 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
819 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
820 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
821 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"`
822 ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
824 *) ac_configure_args="$ac_configure_args$ac_sep$ac_arg"
827 # Get rid of the leading space.
830 # When interrupted or exit'd, cleanup temporary files, and complete
831 # config.log. We remove comments because anyway the quotes in there
832 # would cause problems or look ugly.
834 # Save into config.log some information that might help in debugging.
836 echo "## ----------------- ##" >&5
837 echo "## Cache variables. ##" >&5
838 echo "## ----------------- ##" >&5
840 # The following way of writing the cache mishandles newlines in values,
843 case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
846 "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
847 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
851 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
855 sed "/^$/d" confdefs.h >conftest.log
856 if test -s conftest.log; then
858 echo "## ------------ ##" >&5
859 echo "## confdefs.h. ##" >&5
860 echo "## ------------ ##" >&5
865 test "$ac_signal" != 0 &&
866 echo "$as_me: caught signal $ac_signal" >&5
867 echo "$as_me: exit $exit_status" >&5
868 rm -rf conftest* confdefs* core core.* *.core conf$$* $ac_clean_files &&
871 for ac_signal in 1 2 13 15; do
872 trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
876 # confdefs.h avoids OS command line length limits that DEFS can exceed.
877 rm -rf conftest* confdefs.h
878 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
881 # Let the site file select an alternate cache file if it wants to.
882 # Prefer explicitly selected file to automatically selected ones.
883 if test -z "$CONFIG_SITE"; then
884 if test "x$prefix" != xNONE; then
885 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
887 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
890 for ac_site_file in $CONFIG_SITE; do
891 if test -r "$ac_site_file"; then
892 { echo "$as_me:892: loading site script $ac_site_file" >&5
893 echo "$as_me: loading site script $ac_site_file" >&6;}
894 cat "$ac_site_file" >&5
899 if test -r "$cache_file"; then
900 # Some versions of bash will fail to source /dev/null (special
901 # files actually), so we avoid doing that.
902 if test -f "$cache_file"; then
903 { echo "$as_me:903: loading cache $cache_file" >&5
904 echo "$as_me: loading cache $cache_file" >&6;}
906 [\\/]* | ?:[\\/]* ) . $cache_file;;
911 { echo "$as_me:911: creating cache $cache_file" >&5
912 echo "$as_me: creating cache $cache_file" >&6;}
916 # Check that the precious variables saved in the cache have kept the same
918 ac_cache_corrupted=false
919 for ac_var in `(set) 2>&1 |
920 sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
921 eval ac_old_set=\$ac_cv_env_${ac_var}_set
922 eval ac_new_set=\$ac_env_${ac_var}_set
923 eval ac_old_val="\$ac_cv_env_${ac_var}_value"
924 eval ac_new_val="\$ac_env_${ac_var}_value"
925 case $ac_old_set,$ac_new_set in
927 { echo "$as_me:927: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
928 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
929 ac_cache_corrupted=: ;;
931 { echo "$as_me:931: error: \`$ac_var' was not set in the previous run" >&5
932 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
933 ac_cache_corrupted=: ;;
936 if test "x$ac_old_val" != "x$ac_new_val"; then
937 { echo "$as_me:937: error: \`$ac_var' has changed since the previous run:" >&5
938 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
939 { echo "$as_me:939: former value: $ac_old_val" >&5
940 echo "$as_me: former value: $ac_old_val" >&2;}
941 { echo "$as_me:941: current value: $ac_new_val" >&5
942 echo "$as_me: current value: $ac_new_val" >&2;}
946 # Pass precious variables to config.status. It doesn't matter if
947 # we pass some twice (in addition to the command line arguments).
948 if test "$ac_new_set" = set; then
950 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
951 ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"`
952 ac_configure_args="$ac_configure_args '$ac_arg'"
954 *) ac_configure_args="$ac_configure_args $ac_var=$ac_new_val"
959 if $ac_cache_corrupted; then
960 { echo "$as_me:960: error: changes in the environment can compromise the build" >&5
961 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
962 { { echo "$as_me:962: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
963 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
964 { (exit 1); exit 1; }; }
968 ac_cpp='$CPP $CPPFLAGS'
969 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
970 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
971 ac_compiler_gnu=$ac_cv_c_compiler_gnu
972 ac_main_return=return
974 case `echo "testing\c" 2>/dev/null; echo 1,2,3`,`echo -n testing 2>/dev/null; echo 1,2,3` in
975 *c*,-n*) ECHO_N= ECHO_C= # newlines do not sed ;-) only broken shells would use this case anyway
977 *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
978 *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
980 echo "#! $SHELL" >conftest.sh
981 echo "exit 0" >>conftest.sh
983 if { (echo "$as_me:983: PATH=\".;.\"; conftest.sh") >&5
984 (PATH=".;."; conftest.sh) 2>&5
986 echo "$as_me:986: \$? = $ac_status" >&5
987 (exit $ac_status); }; then
988 ac_path_separator=';'
992 PATH_SEPARATOR="$ac_path_separator"
995 ac_config_headers="$ac_config_headers ncurses_cfg.h:ncurses_tst.hin"
997 test -f config.guess || ( test -f ../config.guess && cp ../config.guess ./ )
999 test -f config.sub || ( test -f ../config.sub && cp ../config.sub ./ )
1002 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
1003 if test -f $ac_dir/install-sh; then
1005 ac_install_sh="$ac_aux_dir/install-sh -c"
1007 elif test -f $ac_dir/install.sh; then
1009 ac_install_sh="$ac_aux_dir/install.sh -c"
1011 elif test -f $ac_dir/shtool; then
1013 ac_install_sh="$ac_aux_dir/shtool install -c"
1017 if test -z "$ac_aux_dir"; then
1018 { { echo "$as_me:1018: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
1019 echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
1020 { (exit 1); exit 1; }; }
1022 ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1023 ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1024 ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
1026 # Make sure we can run config.sub.
1027 $ac_config_sub sun4 >/dev/null 2>&1 ||
1028 { { echo "$as_me:1028: error: cannot run $ac_config_sub" >&5
1029 echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1030 { (exit 1); exit 1; }; }
1032 echo "$as_me:1032: checking build system type" >&5
1033 echo $ECHO_N "checking build system type... $ECHO_C" >&6
1034 if test "${ac_cv_build+set}" = set; then
1035 echo $ECHO_N "(cached) $ECHO_C" >&6
1037 ac_cv_build_alias=$build_alias
1038 test -z "$ac_cv_build_alias" &&
1039 ac_cv_build_alias=`$ac_config_guess`
1040 test -z "$ac_cv_build_alias" &&
1041 { { echo "$as_me:1041: error: cannot guess build type; you must specify one" >&5
1042 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1043 { (exit 1); exit 1; }; }
1044 ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
1045 { { echo "$as_me:1045: error: $ac_config_sub $ac_cv_build_alias failed." >&5
1046 echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed." >&2;}
1047 { (exit 1); exit 1; }; }
1050 echo "$as_me:1050: result: $ac_cv_build" >&5
1051 echo "${ECHO_T}$ac_cv_build" >&6
1053 build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1054 build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1055 build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1057 if test -f $srcdir/config.guess || test -f $ac_aux_dir/config.guess ; then
1058 echo "$as_me:1058: checking host system type" >&5
1059 echo $ECHO_N "checking host system type... $ECHO_C" >&6
1060 if test "${ac_cv_host+set}" = set; then
1061 echo $ECHO_N "(cached) $ECHO_C" >&6
1063 ac_cv_host_alias=$host_alias
1064 test -z "$ac_cv_host_alias" &&
1065 ac_cv_host_alias=$ac_cv_build_alias
1066 ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
1067 { { echo "$as_me:1067: error: $ac_config_sub $ac_cv_host_alias failed" >&5
1068 echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1069 { (exit 1); exit 1; }; }
1072 echo "$as_me:1072: result: $ac_cv_host" >&5
1073 echo "${ECHO_T}$ac_cv_host" >&6
1075 host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1076 host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1077 host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1079 system_name="$host_os"
1081 system_name="`(uname -s -r) 2>/dev/null`"
1082 if test -z "$system_name" ; then
1083 system_name="`(hostname) 2>/dev/null`"
1086 test -n "$system_name" &&
1087 cat >>confdefs.h <<EOF
1088 #define SYSTEM_NAME "$system_name"
1091 if test "${cf_cv_system_name+set}" = set; then
1092 echo $ECHO_N "(cached) $ECHO_C" >&6
1094 cf_cv_system_name="$system_name"
1097 test -z "$system_name" && system_name="$cf_cv_system_name"
1098 test -n "$cf_cv_system_name" && echo "$as_me:1098: result: Configuring for $cf_cv_system_name" >&5
1099 echo "${ECHO_T}Configuring for $cf_cv_system_name" >&6
1101 if test ".$system_name" != ".$cf_cv_system_name" ; then
1102 echo "$as_me:1102: result: Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&5
1103 echo "${ECHO_T}Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&6
1104 { { echo "$as_me:1104: error: \"Please remove config.cache and try again.\"" >&5
1105 echo "$as_me: error: \"Please remove config.cache and try again.\"" >&2;}
1106 { (exit 1); exit 1; }; }
1109 test "$program_prefix" != NONE &&
1110 program_transform_name="s,^,$program_prefix,;$program_transform_name"
1111 # Use a double $ so make ignores it.
1112 test "$program_suffix" != NONE &&
1113 program_transform_name="s,\$,$program_suffix,;$program_transform_name"
1114 # Double any \ or $. echo might interpret backslashes.
1115 # By default was `s,x,x', remove it if useless.
1116 cat <<\_ACEOF >conftest.sed
1117 s/[\\$]/&&/g;s/;s,x,x,$//
1119 program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
1122 echo "$as_me:1122: checking whether ${MAKE-make} sets \${MAKE}" >&5
1123 echo $ECHO_N "checking whether ${MAKE-make} sets \${MAKE}... $ECHO_C" >&6
1124 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,./+-,__p_,'`
1125 if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
1126 echo $ECHO_N "(cached) $ECHO_C" >&6
1128 cat >conftest.make <<\EOF
1130 @echo 'ac_maketemp="${MAKE}"'
1132 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1133 eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
1134 if test -n "$ac_maketemp"; then
1135 eval ac_cv_prog_make_${ac_make}_set=yes
1137 eval ac_cv_prog_make_${ac_make}_set=no
1141 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
1142 echo "$as_me:1142: result: yes" >&5
1143 echo "${ECHO_T}yes" >&6
1146 echo "$as_me:1146: result: no" >&5
1147 echo "${ECHO_T}no" >&6
1148 SET_MAKE="MAKE=${MAKE-make}"
1152 ac_cpp='$CPP $CPPFLAGS'
1153 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1154 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1155 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1156 ac_main_return=return
1157 if test -n "$ac_tool_prefix"; then
1158 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
1159 set dummy ${ac_tool_prefix}gcc; ac_word=$2
1160 echo "$as_me:1160: checking for $ac_word" >&5
1161 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1162 if test "${ac_cv_prog_CC+set}" = set; then
1163 echo $ECHO_N "(cached) $ECHO_C" >&6
1165 if test -n "$CC"; then
1166 ac_cv_prog_CC="$CC" # Let the user override the test.
1168 ac_save_IFS=$IFS; IFS=$ac_path_separator
1170 for ac_dir in $ac_dummy; do
1172 test -z "$ac_dir" && ac_dir=.
1173 $as_executable_p "$ac_dir/$ac_word" || continue
1174 ac_cv_prog_CC="${ac_tool_prefix}gcc"
1175 echo "$as_me:1175: found $ac_dir/$ac_word" >&5
1182 if test -n "$CC"; then
1183 echo "$as_me:1183: result: $CC" >&5
1184 echo "${ECHO_T}$CC" >&6
1186 echo "$as_me:1186: result: no" >&5
1187 echo "${ECHO_T}no" >&6
1191 if test -z "$ac_cv_prog_CC"; then
1193 # Extract the first word of "gcc", so it can be a program name with args.
1194 set dummy gcc; ac_word=$2
1195 echo "$as_me:1195: checking for $ac_word" >&5
1196 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1197 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1198 echo $ECHO_N "(cached) $ECHO_C" >&6
1200 if test -n "$ac_ct_CC"; then
1201 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1203 ac_save_IFS=$IFS; IFS=$ac_path_separator
1205 for ac_dir in $ac_dummy; do
1207 test -z "$ac_dir" && ac_dir=.
1208 $as_executable_p "$ac_dir/$ac_word" || continue
1209 ac_cv_prog_ac_ct_CC="gcc"
1210 echo "$as_me:1210: found $ac_dir/$ac_word" >&5
1216 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1217 if test -n "$ac_ct_CC"; then
1218 echo "$as_me:1218: result: $ac_ct_CC" >&5
1219 echo "${ECHO_T}$ac_ct_CC" >&6
1221 echo "$as_me:1221: result: no" >&5
1222 echo "${ECHO_T}no" >&6
1230 if test -z "$CC"; then
1231 if test -n "$ac_tool_prefix"; then
1232 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
1233 set dummy ${ac_tool_prefix}cc; ac_word=$2
1234 echo "$as_me:1234: checking for $ac_word" >&5
1235 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1236 if test "${ac_cv_prog_CC+set}" = set; then
1237 echo $ECHO_N "(cached) $ECHO_C" >&6
1239 if test -n "$CC"; then
1240 ac_cv_prog_CC="$CC" # Let the user override the test.
1242 ac_save_IFS=$IFS; IFS=$ac_path_separator
1244 for ac_dir in $ac_dummy; do
1246 test -z "$ac_dir" && ac_dir=.
1247 $as_executable_p "$ac_dir/$ac_word" || continue
1248 ac_cv_prog_CC="${ac_tool_prefix}cc"
1249 echo "$as_me:1249: found $ac_dir/$ac_word" >&5
1256 if test -n "$CC"; then
1257 echo "$as_me:1257: result: $CC" >&5
1258 echo "${ECHO_T}$CC" >&6
1260 echo "$as_me:1260: result: no" >&5
1261 echo "${ECHO_T}no" >&6
1265 if test -z "$ac_cv_prog_CC"; then
1267 # Extract the first word of "cc", so it can be a program name with args.
1268 set dummy cc; ac_word=$2
1269 echo "$as_me:1269: checking for $ac_word" >&5
1270 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1271 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1272 echo $ECHO_N "(cached) $ECHO_C" >&6
1274 if test -n "$ac_ct_CC"; then
1275 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1277 ac_save_IFS=$IFS; IFS=$ac_path_separator
1279 for ac_dir in $ac_dummy; do
1281 test -z "$ac_dir" && ac_dir=.
1282 $as_executable_p "$ac_dir/$ac_word" || continue
1283 ac_cv_prog_ac_ct_CC="cc"
1284 echo "$as_me:1284: found $ac_dir/$ac_word" >&5
1290 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1291 if test -n "$ac_ct_CC"; then
1292 echo "$as_me:1292: result: $ac_ct_CC" >&5
1293 echo "${ECHO_T}$ac_ct_CC" >&6
1295 echo "$as_me:1295: result: no" >&5
1296 echo "${ECHO_T}no" >&6
1305 if test -z "$CC"; then
1306 # Extract the first word of "cc", so it can be a program name with args.
1307 set dummy cc; ac_word=$2
1308 echo "$as_me:1308: checking for $ac_word" >&5
1309 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1310 if test "${ac_cv_prog_CC+set}" = set; then
1311 echo $ECHO_N "(cached) $ECHO_C" >&6
1313 if test -n "$CC"; then
1314 ac_cv_prog_CC="$CC" # Let the user override the test.
1317 ac_save_IFS=$IFS; IFS=$ac_path_separator
1319 for ac_dir in $ac_dummy; do
1321 test -z "$ac_dir" && ac_dir=.
1322 $as_executable_p "$ac_dir/$ac_word" || continue
1323 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
1324 ac_prog_rejected=yes
1328 echo "$as_me:1328: found $ac_dir/$ac_word" >&5
1332 if test $ac_prog_rejected = yes; then
1333 # We found a bogon in the path, so make sure we never use it.
1334 set dummy $ac_cv_prog_CC
1336 if test $# != 0; then
1337 # We chose a different compiler from the bogus one.
1338 # However, it has the same basename, so the bogon will be chosen
1339 # first if we set CC to just the basename; use the full file name.
1341 set dummy "$ac_dir/$ac_word" ${1+"$@"}
1349 if test -n "$CC"; then
1350 echo "$as_me:1350: result: $CC" >&5
1351 echo "${ECHO_T}$CC" >&6
1353 echo "$as_me:1353: result: no" >&5
1354 echo "${ECHO_T}no" >&6
1358 if test -z "$CC"; then
1359 if test -n "$ac_tool_prefix"; then
1362 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
1363 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
1364 echo "$as_me:1364: checking for $ac_word" >&5
1365 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1366 if test "${ac_cv_prog_CC+set}" = set; then
1367 echo $ECHO_N "(cached) $ECHO_C" >&6
1369 if test -n "$CC"; then
1370 ac_cv_prog_CC="$CC" # Let the user override the test.
1372 ac_save_IFS=$IFS; IFS=$ac_path_separator
1374 for ac_dir in $ac_dummy; do
1376 test -z "$ac_dir" && ac_dir=.
1377 $as_executable_p "$ac_dir/$ac_word" || continue
1378 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
1379 echo "$as_me:1379: found $ac_dir/$ac_word" >&5
1386 if test -n "$CC"; then
1387 echo "$as_me:1387: result: $CC" >&5
1388 echo "${ECHO_T}$CC" >&6
1390 echo "$as_me:1390: result: no" >&5
1391 echo "${ECHO_T}no" >&6
1394 test -n "$CC" && break
1397 if test -z "$CC"; then
1401 # Extract the first word of "$ac_prog", so it can be a program name with args.
1402 set dummy $ac_prog; ac_word=$2
1403 echo "$as_me:1403: checking for $ac_word" >&5
1404 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1405 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1406 echo $ECHO_N "(cached) $ECHO_C" >&6
1408 if test -n "$ac_ct_CC"; then
1409 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1411 ac_save_IFS=$IFS; IFS=$ac_path_separator
1413 for ac_dir in $ac_dummy; do
1415 test -z "$ac_dir" && ac_dir=.
1416 $as_executable_p "$ac_dir/$ac_word" || continue
1417 ac_cv_prog_ac_ct_CC="$ac_prog"
1418 echo "$as_me:1418: found $ac_dir/$ac_word" >&5
1424 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1425 if test -n "$ac_ct_CC"; then
1426 echo "$as_me:1426: result: $ac_ct_CC" >&5
1427 echo "${ECHO_T}$ac_ct_CC" >&6
1429 echo "$as_me:1429: result: no" >&5
1430 echo "${ECHO_T}no" >&6
1433 test -n "$ac_ct_CC" && break
1441 test -z "$CC" && { { echo "$as_me:1441: error: no acceptable cc found in \$PATH" >&5
1442 echo "$as_me: error: no acceptable cc found in \$PATH" >&2;}
1443 { (exit 1); exit 1; }; }
1445 # Provide some information about the compiler.
1446 echo "$as_me:1446:" \
1447 "checking for C compiler version" >&5
1448 ac_compiler=`set X $ac_compile; echo $2`
1449 { (eval echo "$as_me:1449: \"$ac_compiler --version </dev/null >&5\"") >&5
1450 (eval $ac_compiler --version </dev/null >&5) 2>&5
1452 echo "$as_me:1452: \$? = $ac_status" >&5
1453 (exit $ac_status); }
1454 { (eval echo "$as_me:1454: \"$ac_compiler -v </dev/null >&5\"") >&5
1455 (eval $ac_compiler -v </dev/null >&5) 2>&5
1457 echo "$as_me:1457: \$? = $ac_status" >&5
1458 (exit $ac_status); }
1459 { (eval echo "$as_me:1459: \"$ac_compiler -V </dev/null >&5\"") >&5
1460 (eval $ac_compiler -V </dev/null >&5) 2>&5
1462 echo "$as_me:1462: \$? = $ac_status" >&5
1463 (exit $ac_status); }
1465 cat >conftest.$ac_ext <<_ACEOF
1466 #line 1466 "configure"
1467 #include "confdefs.h"
1477 ac_clean_files_save=$ac_clean_files
1478 ac_clean_files="$ac_clean_files a.out a.exe"
1479 # Try to create an executable without -o first, disregard a.out.
1480 # It will help us diagnose broken compilers, and finding out an intuition
1482 echo "$as_me:1482: checking for C compiler default output" >&5
1483 echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
1484 ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
1485 if { (eval echo "$as_me:1485: \"$ac_link_default\"") >&5
1486 (eval $ac_link_default) 2>&5
1488 echo "$as_me:1488: \$? = $ac_status" >&5
1489 (exit $ac_status); }; then
1490 # Find the output, starting from the most likely. This scheme is
1491 # not robust to junk in `.', hence go to wildcards (a.*) only as a last
1493 for ac_file in `ls a.exe conftest.exe 2>/dev/null;
1494 ls a.out conftest 2>/dev/null;
1495 ls a.* conftest.* 2>/dev/null`; do
1497 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1498 a.out ) # We found the default executable, but exeext='' is most
1501 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1502 # FIXME: I believe we export ac_cv_exeext for Libtool --akim.
1509 echo "$as_me: failed program was:" >&5
1510 cat conftest.$ac_ext >&5
1511 { { echo "$as_me:1511: error: C compiler cannot create executables" >&5
1512 echo "$as_me: error: C compiler cannot create executables" >&2;}
1513 { (exit 77); exit 77; }; }
1516 ac_exeext=$ac_cv_exeext
1517 echo "$as_me:1517: result: $ac_file" >&5
1518 echo "${ECHO_T}$ac_file" >&6
1520 # Check the compiler produces executables we can run. If not, either
1521 # the compiler is broken, or we cross compile.
1522 echo "$as_me:1522: checking whether the C compiler works" >&5
1523 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
1524 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
1525 # If not cross compiling, check that we can run a simple program.
1526 if test "$cross_compiling" != yes; then
1527 if { ac_try='./$ac_file'
1528 { (eval echo "$as_me:1528: \"$ac_try\"") >&5
1531 echo "$as_me:1531: \$? = $ac_status" >&5
1532 (exit $ac_status); }; }; then
1535 if test "$cross_compiling" = maybe; then
1538 { { echo "$as_me:1538: error: cannot run C compiled programs.
1539 If you meant to cross compile, use \`--host'." >&5
1540 echo "$as_me: error: cannot run C compiled programs.
1541 If you meant to cross compile, use \`--host'." >&2;}
1542 { (exit 1); exit 1; }; }
1546 echo "$as_me:1546: result: yes" >&5
1547 echo "${ECHO_T}yes" >&6
1549 rm -f a.out a.exe conftest$ac_cv_exeext
1550 ac_clean_files=$ac_clean_files_save
1551 # Check the compiler produces executables we can run. If not, either
1552 # the compiler is broken, or we cross compile.
1553 echo "$as_me:1553: checking whether we are cross compiling" >&5
1554 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
1555 echo "$as_me:1555: result: $cross_compiling" >&5
1556 echo "${ECHO_T}$cross_compiling" >&6
1558 echo "$as_me:1558: checking for executable suffix" >&5
1559 echo $ECHO_N "checking for executable suffix... $ECHO_C" >&6
1560 if { (eval echo "$as_me:1560: \"$ac_link\"") >&5
1561 (eval $ac_link) 2>&5
1563 echo "$as_me:1563: \$? = $ac_status" >&5
1564 (exit $ac_status); }; then
1565 # If both `conftest.exe' and `conftest' are `present' (well, observable)
1566 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
1567 # work properly (i.e., refer to `conftest.exe'), while it won't with
1569 for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do
1571 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1572 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1579 { { echo "$as_me:1579: error: cannot compute EXEEXT: cannot compile and link" >&5
1580 echo "$as_me: error: cannot compute EXEEXT: cannot compile and link" >&2;}
1581 { (exit 1); exit 1; }; }
1584 rm -f conftest$ac_cv_exeext
1585 echo "$as_me:1585: result: $ac_cv_exeext" >&5
1586 echo "${ECHO_T}$ac_cv_exeext" >&6
1588 rm -f conftest.$ac_ext
1589 EXEEXT=$ac_cv_exeext
1591 echo "$as_me:1591: checking for object suffix" >&5
1592 echo $ECHO_N "checking for object suffix... $ECHO_C" >&6
1593 if test "${ac_cv_objext+set}" = set; then
1594 echo $ECHO_N "(cached) $ECHO_C" >&6
1596 cat >conftest.$ac_ext <<_ACEOF
1597 #line 1597 "configure"
1598 #include "confdefs.h"
1608 rm -f conftest.o conftest.obj
1609 if { (eval echo "$as_me:1609: \"$ac_compile\"") >&5
1610 (eval $ac_compile) 2>&5
1612 echo "$as_me:1612: \$? = $ac_status" >&5
1613 (exit $ac_status); }; then
1614 for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
1616 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.map | *.inf ) ;;
1617 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
1622 echo "$as_me: failed program was:" >&5
1623 cat conftest.$ac_ext >&5
1624 { { echo "$as_me:1624: error: cannot compute OBJEXT: cannot compile" >&5
1625 echo "$as_me: error: cannot compute OBJEXT: cannot compile" >&2;}
1626 { (exit 1); exit 1; }; }
1629 rm -f conftest.$ac_cv_objext conftest.$ac_ext
1631 echo "$as_me:1631: result: $ac_cv_objext" >&5
1632 echo "${ECHO_T}$ac_cv_objext" >&6
1633 OBJEXT=$ac_cv_objext
1635 echo "$as_me:1635: checking whether we are using the GNU C compiler" >&5
1636 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
1637 if test "${ac_cv_c_compiler_gnu+set}" = set; then
1638 echo $ECHO_N "(cached) $ECHO_C" >&6
1640 cat >conftest.$ac_ext <<_ACEOF
1641 #line 1641 "configure"
1642 #include "confdefs.h"
1655 rm -f conftest.$ac_objext
1656 if { (eval echo "$as_me:1656: \"$ac_compile\"") >&5
1657 (eval $ac_compile) 2>&5
1659 echo "$as_me:1659: \$? = $ac_status" >&5
1660 (exit $ac_status); } &&
1661 { ac_try='test -s conftest.$ac_objext'
1662 { (eval echo "$as_me:1662: \"$ac_try\"") >&5
1665 echo "$as_me:1665: \$? = $ac_status" >&5
1666 (exit $ac_status); }; }; then
1669 echo "$as_me: failed program was:" >&5
1670 cat conftest.$ac_ext >&5
1673 rm -f conftest.$ac_objext conftest.$ac_ext
1674 ac_cv_c_compiler_gnu=$ac_compiler_gnu
1677 echo "$as_me:1677: result: $ac_cv_c_compiler_gnu" >&5
1678 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
1679 GCC=`test $ac_compiler_gnu = yes && echo yes`
1680 ac_test_CFLAGS=${CFLAGS+set}
1681 ac_save_CFLAGS=$CFLAGS
1683 echo "$as_me:1683: checking whether $CC accepts -g" >&5
1684 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
1685 if test "${ac_cv_prog_cc_g+set}" = set; then
1686 echo $ECHO_N "(cached) $ECHO_C" >&6
1688 cat >conftest.$ac_ext <<_ACEOF
1689 #line 1689 "configure"
1690 #include "confdefs.h"
1700 rm -f conftest.$ac_objext
1701 if { (eval echo "$as_me:1701: \"$ac_compile\"") >&5
1702 (eval $ac_compile) 2>&5
1704 echo "$as_me:1704: \$? = $ac_status" >&5
1705 (exit $ac_status); } &&
1706 { ac_try='test -s conftest.$ac_objext'
1707 { (eval echo "$as_me:1707: \"$ac_try\"") >&5
1710 echo "$as_me:1710: \$? = $ac_status" >&5
1711 (exit $ac_status); }; }; then
1714 echo "$as_me: failed program was:" >&5
1715 cat conftest.$ac_ext >&5
1718 rm -f conftest.$ac_objext conftest.$ac_ext
1720 echo "$as_me:1720: result: $ac_cv_prog_cc_g" >&5
1721 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
1722 if test "$ac_test_CFLAGS" = set; then
1723 CFLAGS=$ac_save_CFLAGS
1724 elif test $ac_cv_prog_cc_g = yes; then
1725 if test "$GCC" = yes; then
1731 if test "$GCC" = yes; then
1737 # Some people use a C++ compiler to compile C. Since we use `exit',
1738 # in C++ we need to declare it. In case someone uses the same compiler
1739 # for both compiling C and C++ we need to have the C++ compiler decide
1740 # the declaration of exit, since it's the most demanding environment.
1741 cat >conftest.$ac_ext <<_ACEOF
1746 rm -f conftest.$ac_objext
1747 if { (eval echo "$as_me:1747: \"$ac_compile\"") >&5
1748 (eval $ac_compile) 2>&5
1750 echo "$as_me:1750: \$? = $ac_status" >&5
1751 (exit $ac_status); } &&
1752 { ac_try='test -s conftest.$ac_objext'
1753 { (eval echo "$as_me:1753: \"$ac_try\"") >&5
1756 echo "$as_me:1756: \$? = $ac_status" >&5
1757 (exit $ac_status); }; }; then
1758 for ac_declaration in \
1760 '#include <stdlib.h>' \
1761 'extern "C" void std::exit (int) throw (); using std::exit;' \
1762 'extern "C" void std::exit (int); using std::exit;' \
1763 'extern "C" void exit (int) throw ();' \
1764 'extern "C" void exit (int);' \
1767 cat >conftest.$ac_ext <<_ACEOF
1768 #line 1768 "configure"
1769 #include "confdefs.h"
1780 rm -f conftest.$ac_objext
1781 if { (eval echo "$as_me:1781: \"$ac_compile\"") >&5
1782 (eval $ac_compile) 2>&5
1784 echo "$as_me:1784: \$? = $ac_status" >&5
1785 (exit $ac_status); } &&
1786 { ac_try='test -s conftest.$ac_objext'
1787 { (eval echo "$as_me:1787: \"$ac_try\"") >&5
1790 echo "$as_me:1790: \$? = $ac_status" >&5
1791 (exit $ac_status); }; }; then
1794 echo "$as_me: failed program was:" >&5
1795 cat conftest.$ac_ext >&5
1798 rm -f conftest.$ac_objext conftest.$ac_ext
1799 cat >conftest.$ac_ext <<_ACEOF
1800 #line 1800 "configure"
1801 #include "confdefs.h"
1811 rm -f conftest.$ac_objext
1812 if { (eval echo "$as_me:1812: \"$ac_compile\"") >&5
1813 (eval $ac_compile) 2>&5
1815 echo "$as_me:1815: \$? = $ac_status" >&5
1816 (exit $ac_status); } &&
1817 { ac_try='test -s conftest.$ac_objext'
1818 { (eval echo "$as_me:1818: \"$ac_try\"") >&5
1821 echo "$as_me:1821: \$? = $ac_status" >&5
1822 (exit $ac_status); }; }; then
1825 echo "$as_me: failed program was:" >&5
1826 cat conftest.$ac_ext >&5
1828 rm -f conftest.$ac_objext conftest.$ac_ext
1831 if test -n "$ac_declaration"; then
1832 echo '#ifdef __cplusplus' >>confdefs.h
1833 echo $ac_declaration >>confdefs.h
1834 echo '#endif' >>confdefs.h
1838 echo "$as_me: failed program was:" >&5
1839 cat conftest.$ac_ext >&5
1841 rm -f conftest.$ac_objext conftest.$ac_ext
1843 ac_cpp='$CPP $CPPFLAGS'
1844 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1845 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1846 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1847 ac_main_return=return
1850 if test "$GCC" = yes ; then
1851 echo "$as_me:1851: checking version of $CC" >&5
1852 echo $ECHO_N "checking version of $CC... $ECHO_C" >&6
1853 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.].*//'`"
1854 test -z "$GCC_VERSION" && GCC_VERSION=unknown
1855 echo "$as_me:1855: result: $GCC_VERSION" >&5
1856 echo "${ECHO_T}$GCC_VERSION" >&6
1859 echo "$as_me:1859: checking for $CC option to accept ANSI C" >&5
1860 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
1861 if test "${ac_cv_prog_cc_stdc+set}" = set; then
1862 echo $ECHO_N "(cached) $ECHO_C" >&6
1864 ac_cv_prog_cc_stdc=no
1866 cat >conftest.$ac_ext <<_ACEOF
1867 #line 1867 "configure"
1868 #include "confdefs.h"
1871 #include <sys/types.h>
1872 #include <sys/stat.h>
1873 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
1874 struct buf { int x; };
1875 FILE * (*rcsopen) (struct buf *, struct stat *, int);
1876 static char *e (p, i)
1882 static char *f (char * (*g) (char **, int), char **p, ...)
1887 s = g (p, va_arg (v,int));
1891 int test (int i, double x);
1892 struct s1 {int (*f) (int a);};
1893 struct s2 {int (*f) (double a);};
1894 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
1900 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
1905 # Don't try gcc -ansi; that turns off useful extensions and
1906 # breaks some systems' header files.
1907 # AIX -qlanglvl=ansi
1908 # Ultrix and OSF/1 -std1
1909 # HP-UX 10.20 and later -Ae
1910 # HP-UX older versions -Aa -D_HPUX_SOURCE
1911 # SVR4 -Xc -D__EXTENSIONS__
1912 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
1914 CC="$ac_save_CC $ac_arg"
1915 rm -f conftest.$ac_objext
1916 if { (eval echo "$as_me:1916: \"$ac_compile\"") >&5
1917 (eval $ac_compile) 2>&5
1919 echo "$as_me:1919: \$? = $ac_status" >&5
1920 (exit $ac_status); } &&
1921 { ac_try='test -s conftest.$ac_objext'
1922 { (eval echo "$as_me:1922: \"$ac_try\"") >&5
1925 echo "$as_me:1925: \$? = $ac_status" >&5
1926 (exit $ac_status); }; }; then
1927 ac_cv_prog_cc_stdc=$ac_arg
1930 echo "$as_me: failed program was:" >&5
1931 cat conftest.$ac_ext >&5
1933 rm -f conftest.$ac_objext
1935 rm -f conftest.$ac_ext conftest.$ac_objext
1940 case "x$ac_cv_prog_cc_stdc" in
1942 echo "$as_me:1942: result: none needed" >&5
1943 echo "${ECHO_T}none needed" >&6 ;;
1945 echo "$as_me:1945: result: $ac_cv_prog_cc_stdc" >&5
1946 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
1947 CC="$CC $ac_cv_prog_cc_stdc" ;;
1950 # This should have been defined by AC_PROG_CC
1953 echo "$as_me:1953: checking \$CFLAGS variable" >&5
1954 echo $ECHO_N "checking \$CFLAGS variable... $ECHO_C" >&6
1957 echo "$as_me:1957: result: broken" >&5
1958 echo "${ECHO_T}broken" >&6
1959 { echo "$as_me:1959: WARNING: your environment uses the CFLAGS variable to hold CPPFLAGS options" >&5
1960 echo "$as_me: WARNING: your environment uses the CFLAGS variable to hold CPPFLAGS options" >&2;}
1963 for cf_arg in $cf_flags
1969 cf_new_extra_cppflags=
1971 for cf_add_cflags in $cf_arg
1973 case $cf_fix_cppflags in
1975 case $cf_add_cflags in
1976 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
1977 case $cf_add_cflags in
1979 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
1981 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
1982 && test -z "${cf_tst_cflags}" \
1983 && cf_fix_cppflags=yes
1985 if test $cf_fix_cppflags = yes ; then
1987 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
1988 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
1991 elif test "${cf_tst_cflags}" = "\"'" ; then
1993 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
1994 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2004 case $cf_add_cflags in
2006 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
2008 CPPFLAGS=`echo "$CPPFLAGS" | \
2009 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
2010 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
2015 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
2016 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
2023 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
2024 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
2031 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2032 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2034 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
2036 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2037 && test -z "${cf_tst_cflags}" \
2038 && cf_fix_cppflags=no
2043 if test -n "$cf_new_cflags" ; then
2045 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
2046 CFLAGS="${CFLAGS}$cf_new_cflags"
2050 if test -n "$cf_new_cppflags" ; then
2052 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
2053 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
2057 if test -n "$cf_new_extra_cppflags" ; then
2059 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
2060 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
2067 echo "$as_me:2067: result: ok" >&5
2068 echo "${ECHO_T}ok" >&6
2072 echo "$as_me:2072: checking \$CC variable" >&5
2073 echo $ECHO_N "checking \$CC variable... $ECHO_C" >&6
2076 echo "$as_me:2076: result: broken" >&5
2077 echo "${ECHO_T}broken" >&6
2078 { echo "$as_me:2078: WARNING: your environment uses the CC variable to hold CFLAGS/CPPFLAGS options" >&5
2079 echo "$as_me: WARNING: your environment uses the CC variable to hold CFLAGS/CPPFLAGS options" >&2;}
2081 cf_prog=`echo "$CC" | sed -e 's/ / /g' -e 's/[ ]* / /g' -e 's/[ ]*[ ]-[^ ].*//'`
2082 cf_flags=`echo "$CC" | ${AWK:-awk} -v prog="$cf_prog" '{ printf("%s", substr($0,1+length(prog))); }'`
2084 for cf_arg in $cf_flags
2092 cf_new_extra_cppflags=
2094 for cf_add_cflags in $cf_arg
2096 case $cf_fix_cppflags in
2098 case $cf_add_cflags in
2099 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
2100 case $cf_add_cflags in
2102 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
2104 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2105 && test -z "${cf_tst_cflags}" \
2106 && cf_fix_cppflags=yes
2108 if test $cf_fix_cppflags = yes ; then
2110 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2111 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2114 elif test "${cf_tst_cflags}" = "\"'" ; then
2116 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2117 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2127 case $cf_add_cflags in
2129 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
2131 CPPFLAGS=`echo "$CPPFLAGS" | \
2132 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
2133 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
2138 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
2139 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
2146 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
2147 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
2154 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2155 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2157 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
2159 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2160 && test -z "${cf_tst_cflags}" \
2161 && cf_fix_cppflags=no
2166 if test -n "$cf_new_cflags" ; then
2168 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
2169 CFLAGS="${CFLAGS}$cf_new_cflags"
2173 if test -n "$cf_new_cppflags" ; then
2175 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
2176 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
2180 if test -n "$cf_new_extra_cppflags" ; then
2182 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
2183 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
2193 test -n "$verbose" && echo " resulting CC: '$CC'" 1>&6
2195 echo "${as_me:-configure}:2195: testing resulting CC: '$CC' ..." 1>&5
2197 test -n "$verbose" && echo " resulting CFLAGS: '$CFLAGS'" 1>&6
2199 echo "${as_me:-configure}:2199: testing resulting CFLAGS: '$CFLAGS' ..." 1>&5
2201 test -n "$verbose" && echo " resulting CPPFLAGS: '$CPPFLAGS'" 1>&6
2203 echo "${as_me:-configure}:2203: testing resulting CPPFLAGS: '$CPPFLAGS' ..." 1>&5
2207 echo "$as_me:2207: result: ok" >&5
2208 echo "${ECHO_T}ok" >&6
2212 echo "$as_me:2212: checking for inline" >&5
2213 echo $ECHO_N "checking for inline... $ECHO_C" >&6
2214 if test "${ac_cv_c_inline+set}" = set; then
2215 echo $ECHO_N "(cached) $ECHO_C" >&6
2218 for ac_kw in inline __inline__ __inline; do
2219 cat >conftest.$ac_ext <<_ACEOF
2220 #line 2220 "configure"
2221 #include "confdefs.h"
2223 static $ac_kw int static_foo () {return 0; }
2224 $ac_kw int foo () {return 0; }
2228 rm -f conftest.$ac_objext
2229 if { (eval echo "$as_me:2229: \"$ac_compile\"") >&5
2230 (eval $ac_compile) 2>&5
2232 echo "$as_me:2232: \$? = $ac_status" >&5
2233 (exit $ac_status); } &&
2234 { ac_try='test -s conftest.$ac_objext'
2235 { (eval echo "$as_me:2235: \"$ac_try\"") >&5
2238 echo "$as_me:2238: \$? = $ac_status" >&5
2239 (exit $ac_status); }; }; then
2240 ac_cv_c_inline=$ac_kw; break
2242 echo "$as_me: failed program was:" >&5
2243 cat conftest.$ac_ext >&5
2245 rm -f conftest.$ac_objext conftest.$ac_ext
2249 echo "$as_me:2249: result: $ac_cv_c_inline" >&5
2250 echo "${ECHO_T}$ac_cv_c_inline" >&6
2251 case $ac_cv_c_inline in
2254 cat >>confdefs.h <<\EOF
2258 *) cat >>confdefs.h <<EOF
2259 #define inline $ac_cv_c_inline
2265 ac_cpp='$CPP $CPPFLAGS'
2266 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2267 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2268 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2269 ac_main_return=return
2270 echo "$as_me:2270: checking how to run the C preprocessor" >&5
2271 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
2272 # On Suns, sometimes $CPP names a directory.
2273 if test -n "$CPP" && test -d "$CPP"; then
2276 if test -z "$CPP"; then
2277 if test "${ac_cv_prog_CPP+set}" = set; then
2278 echo $ECHO_N "(cached) $ECHO_C" >&6
2280 # Double quotes because CPP needs to be expanded
2281 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
2284 for ac_c_preproc_warn_flag in '' yes
2286 # Use a header file that comes with gcc, so configuring glibc
2287 # with a fresh cross-compiler works.
2288 # On the NeXT, cc -E runs the code through the compiler's parser,
2289 # not just through cpp. "Syntax error" is here to catch this case.
2290 cat >conftest.$ac_ext <<_ACEOF
2291 #line 2291 "configure"
2292 #include "confdefs.h"
2296 if { (eval echo "$as_me:2296: \"$ac_cpp conftest.$ac_ext\"") >&5
2297 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2299 egrep -v '^ *\+' conftest.er1 >conftest.err
2301 cat conftest.err >&5
2302 echo "$as_me:2302: \$? = $ac_status" >&5
2303 (exit $ac_status); } >/dev/null; then
2304 if test -s conftest.err; then
2305 ac_cpp_err=$ac_c_preproc_warn_flag
2312 if test -z "$ac_cpp_err"; then
2315 echo "$as_me: failed program was:" >&5
2316 cat conftest.$ac_ext >&5
2317 # Broken: fails on valid input.
2320 rm -f conftest.err conftest.$ac_ext
2322 # OK, works on sane cases. Now check whether non-existent headers
2323 # can be detected and how.
2324 cat >conftest.$ac_ext <<_ACEOF
2325 #line 2325 "configure"
2326 #include "confdefs.h"
2327 #include <ac_nonexistent.h>
2329 if { (eval echo "$as_me:2329: \"$ac_cpp conftest.$ac_ext\"") >&5
2330 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2332 egrep -v '^ *\+' conftest.er1 >conftest.err
2334 cat conftest.err >&5
2335 echo "$as_me:2335: \$? = $ac_status" >&5
2336 (exit $ac_status); } >/dev/null; then
2337 if test -s conftest.err; then
2338 ac_cpp_err=$ac_c_preproc_warn_flag
2345 if test -z "$ac_cpp_err"; then
2346 # Broken: success on invalid input.
2349 echo "$as_me: failed program was:" >&5
2350 cat conftest.$ac_ext >&5
2351 # Passes both tests.
2355 rm -f conftest.err conftest.$ac_ext
2358 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2359 rm -f conftest.err conftest.$ac_ext
2360 if $ac_preproc_ok; then
2372 echo "$as_me:2372: result: $CPP" >&5
2373 echo "${ECHO_T}$CPP" >&6
2375 for ac_c_preproc_warn_flag in '' yes
2377 # Use a header file that comes with gcc, so configuring glibc
2378 # with a fresh cross-compiler works.
2379 # On the NeXT, cc -E runs the code through the compiler's parser,
2380 # not just through cpp. "Syntax error" is here to catch this case.
2381 cat >conftest.$ac_ext <<_ACEOF
2382 #line 2382 "configure"
2383 #include "confdefs.h"
2387 if { (eval echo "$as_me:2387: \"$ac_cpp conftest.$ac_ext\"") >&5
2388 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2390 egrep -v '^ *\+' conftest.er1 >conftest.err
2392 cat conftest.err >&5
2393 echo "$as_me:2393: \$? = $ac_status" >&5
2394 (exit $ac_status); } >/dev/null; then
2395 if test -s conftest.err; then
2396 ac_cpp_err=$ac_c_preproc_warn_flag
2403 if test -z "$ac_cpp_err"; then
2406 echo "$as_me: failed program was:" >&5
2407 cat conftest.$ac_ext >&5
2408 # Broken: fails on valid input.
2411 rm -f conftest.err conftest.$ac_ext
2413 # OK, works on sane cases. Now check whether non-existent headers
2414 # can be detected and how.
2415 cat >conftest.$ac_ext <<_ACEOF
2416 #line 2416 "configure"
2417 #include "confdefs.h"
2418 #include <ac_nonexistent.h>
2420 if { (eval echo "$as_me:2420: \"$ac_cpp conftest.$ac_ext\"") >&5
2421 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2423 egrep -v '^ *\+' conftest.er1 >conftest.err
2425 cat conftest.err >&5
2426 echo "$as_me:2426: \$? = $ac_status" >&5
2427 (exit $ac_status); } >/dev/null; then
2428 if test -s conftest.err; then
2429 ac_cpp_err=$ac_c_preproc_warn_flag
2436 if test -z "$ac_cpp_err"; then
2437 # Broken: success on invalid input.
2440 echo "$as_me: failed program was:" >&5
2441 cat conftest.$ac_ext >&5
2442 # Passes both tests.
2446 rm -f conftest.err conftest.$ac_ext
2449 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2450 rm -f conftest.err conftest.$ac_ext
2451 if $ac_preproc_ok; then
2454 { { echo "$as_me:2454: error: C preprocessor \"$CPP\" fails sanity check" >&5
2455 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;}
2456 { (exit 1); exit 1; }; }
2460 ac_cpp='$CPP $CPPFLAGS'
2461 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2462 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2463 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2464 ac_main_return=return
2466 for ac_prog in mawk gawk nawk awk
2468 # Extract the first word of "$ac_prog", so it can be a program name with args.
2469 set dummy $ac_prog; ac_word=$2
2470 echo "$as_me:2470: checking for $ac_word" >&5
2471 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2472 if test "${ac_cv_prog_AWK+set}" = set; then
2473 echo $ECHO_N "(cached) $ECHO_C" >&6
2475 if test -n "$AWK"; then
2476 ac_cv_prog_AWK="$AWK" # Let the user override the test.
2478 ac_save_IFS=$IFS; IFS=$ac_path_separator
2480 for ac_dir in $ac_dummy; do
2482 test -z "$ac_dir" && ac_dir=.
2483 $as_executable_p "$ac_dir/$ac_word" || continue
2484 ac_cv_prog_AWK="$ac_prog"
2485 echo "$as_me:2485: found $ac_dir/$ac_word" >&5
2492 if test -n "$AWK"; then
2493 echo "$as_me:2493: result: $AWK" >&5
2494 echo "${ECHO_T}$AWK" >&6
2496 echo "$as_me:2496: result: no" >&5
2497 echo "${ECHO_T}no" >&6
2500 test -n "$AWK" && break
2503 # Find a good install program. We prefer a C program (faster),
2504 # so one script is as good as another. But avoid the broken or
2505 # incompatible versions:
2506 # SysV /etc/install, /usr/sbin/install
2507 # SunOS /usr/etc/install
2508 # IRIX /sbin/install
2510 # AmigaOS /C/install, which installs bootblocks on floppy discs
2511 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
2512 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
2513 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
2514 # ./install, which can be erroneously created by make from ./install.sh.
2515 echo "$as_me:2515: checking for a BSD compatible install" >&5
2516 echo $ECHO_N "checking for a BSD compatible install... $ECHO_C" >&6
2517 if test -z "$INSTALL"; then
2518 if test "${ac_cv_path_install+set}" = set; then
2519 echo $ECHO_N "(cached) $ECHO_C" >&6
2521 ac_save_IFS=$IFS; IFS=$ac_path_separator
2522 for ac_dir in $PATH; do
2524 # Account for people who put trailing slashes in PATH elements.
2526 / | ./ | .// | /cC/* \
2527 | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* \
2530 # OSF1 and SCO ODT 3.0 have their own names for install.
2531 # Don't use installbsd from OSF since it installs stuff as root
2533 for ac_prog in ginstall scoinst install; do
2534 if $as_executable_p "$ac_dir/$ac_prog"; then
2535 if test $ac_prog = install &&
2536 grep dspmsg "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2537 # AIX install. It has an incompatible calling convention.
2539 elif test $ac_prog = install &&
2540 grep pwplus "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2541 # program-specific install script used by HP pwplus--don't use.
2544 ac_cv_path_install="$ac_dir/$ac_prog -c"
2554 if test "${ac_cv_path_install+set}" = set; then
2555 INSTALL=$ac_cv_path_install
2557 # As a last resort, use the slow shell script. We don't cache a
2558 # path for INSTALL within a source directory, because that will
2559 # break other packages using the cache if that directory is
2560 # removed, or if the path is relative.
2561 INSTALL=$ac_install_sh
2564 echo "$as_me:2564: result: $INSTALL" >&5
2565 echo "${ECHO_T}$INSTALL" >&6
2567 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
2568 # It thinks the first close brace ends the variable substitution.
2569 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
2571 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
2573 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
2579 cf_dir=`echo $INSTALL | sed -e 's%/[^/]*$%%'`
2580 test -z "$cf_dir" && cf_dir=.
2581 INSTALL=`cd $cf_dir && pwd`/`echo $INSTALL | sed -e 's%^.*/%%'`
2585 echo "$as_me:2585: checking if you want to install stripped executables" >&5
2586 echo $ECHO_N "checking if you want to install stripped executables... $ECHO_C" >&6
2588 # Check whether --enable-stripping or --disable-stripping was given.
2589 if test "${enable_stripping+set}" = set; then
2590 enableval="$enable_stripping"
2591 test "$enableval" != no && enableval=yes
2592 if test "$enableval" != "yes" ; then
2602 echo "$as_me:2602: result: $with_stripping" >&5
2603 echo "${ECHO_T}$with_stripping" >&6
2605 if test "$with_stripping" = yes
2612 : ${INSTALL:=install}
2613 echo "$as_me:2613: checking if install accepts -p option" >&5
2614 echo $ECHO_N "checking if install accepts -p option... $ECHO_C" >&6
2615 if test "${cf_cv_install_p+set}" = set; then
2616 echo $ECHO_N "(cached) $ECHO_C" >&6
2623 if $INSTALL -p conftest.in conftest.out 2>/dev/null
2625 if test -f conftest.out/conftest.in
2627 test conftest.in -nt conftest.out/conftest.in 2>conftest.err && \
2628 test conftest.out/conftest.in -nt conftest.in 2>conftest.err
2629 if test -s conftest.err
2644 echo "$as_me:2644: result: $cf_cv_install_p" >&5
2645 echo "${ECHO_T}$cf_cv_install_p" >&6
2647 echo "$as_me:2647: checking if install needs to be told about ownership" >&5
2648 echo $ECHO_N "checking if install needs to be told about ownership... $ECHO_C" >&6
2649 case `$ac_config_guess` in
2658 echo "$as_me:2658: result: $with_install_o" >&5
2659 echo "${ECHO_T}$with_install_o" >&6
2660 if test "x$with_install_o" = xyes
2662 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'`
2667 for ac_prog in lint cppcheck splint
2669 # Extract the first word of "$ac_prog", so it can be a program name with args.
2670 set dummy $ac_prog; ac_word=$2
2671 echo "$as_me:2671: checking for $ac_word" >&5
2672 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2673 if test "${ac_cv_prog_LINT+set}" = set; then
2674 echo $ECHO_N "(cached) $ECHO_C" >&6
2676 if test -n "$LINT"; then
2677 ac_cv_prog_LINT="$LINT" # Let the user override the test.
2679 ac_save_IFS=$IFS; IFS=$ac_path_separator
2681 for ac_dir in $ac_dummy; do
2683 test -z "$ac_dir" && ac_dir=.
2684 $as_executable_p "$ac_dir/$ac_word" || continue
2685 ac_cv_prog_LINT="$ac_prog"
2686 echo "$as_me:2686: found $ac_dir/$ac_word" >&5
2692 LINT=$ac_cv_prog_LINT
2693 if test -n "$LINT"; then
2694 echo "$as_me:2694: result: $LINT" >&5
2695 echo "${ECHO_T}$LINT" >&6
2697 echo "$as_me:2697: result: no" >&5
2698 echo "${ECHO_T}no" >&6
2701 test -n "$LINT" && break
2704 echo "$as_me:2704: checking if filesystem supports mixed-case filenames" >&5
2705 echo $ECHO_N "checking if filesystem supports mixed-case filenames... $ECHO_C" >&6
2706 if test "${cf_cv_mixedcase+set}" = set; then
2707 echo $ECHO_N "(cached) $ECHO_C" >&6
2710 if test "$cross_compiling" = yes ; then
2711 case $target_alias in
2712 (*-os2-emx*|*-msdosdjgpp*|*-cygwin*|*-msys*|*-mingw*|*-uwin*)
2720 rm -f conftest CONFTEST
2722 if test -f CONFTEST ; then
2727 rm -f conftest CONFTEST
2731 echo "$as_me:2731: result: $cf_cv_mixedcase" >&5
2732 echo "${ECHO_T}$cf_cv_mixedcase" >&6
2733 test "$cf_cv_mixedcase" = yes &&
2734 cat >>confdefs.h <<\EOF
2735 #define MIXEDCASE_FILENAMES 1
2738 for ac_prog in exctags ctags
2740 # Extract the first word of "$ac_prog", so it can be a program name with args.
2741 set dummy $ac_prog; ac_word=$2
2742 echo "$as_me:2742: checking for $ac_word" >&5
2743 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2744 if test "${ac_cv_prog_CTAGS+set}" = set; then
2745 echo $ECHO_N "(cached) $ECHO_C" >&6
2747 if test -n "$CTAGS"; then
2748 ac_cv_prog_CTAGS="$CTAGS" # Let the user override the test.
2750 ac_save_IFS=$IFS; IFS=$ac_path_separator
2752 for ac_dir in $ac_dummy; do
2754 test -z "$ac_dir" && ac_dir=.
2755 $as_executable_p "$ac_dir/$ac_word" || continue
2756 ac_cv_prog_CTAGS="$ac_prog"
2757 echo "$as_me:2757: found $ac_dir/$ac_word" >&5
2763 CTAGS=$ac_cv_prog_CTAGS
2764 if test -n "$CTAGS"; then
2765 echo "$as_me:2765: result: $CTAGS" >&5
2766 echo "${ECHO_T}$CTAGS" >&6
2768 echo "$as_me:2768: result: no" >&5
2769 echo "${ECHO_T}no" >&6
2772 test -n "$CTAGS" && break
2775 for ac_prog in exetags etags
2777 # Extract the first word of "$ac_prog", so it can be a program name with args.
2778 set dummy $ac_prog; ac_word=$2
2779 echo "$as_me:2779: checking for $ac_word" >&5
2780 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2781 if test "${ac_cv_prog_ETAGS+set}" = set; then
2782 echo $ECHO_N "(cached) $ECHO_C" >&6
2784 if test -n "$ETAGS"; then
2785 ac_cv_prog_ETAGS="$ETAGS" # Let the user override the test.
2787 ac_save_IFS=$IFS; IFS=$ac_path_separator
2789 for ac_dir in $ac_dummy; do
2791 test -z "$ac_dir" && ac_dir=.
2792 $as_executable_p "$ac_dir/$ac_word" || continue
2793 ac_cv_prog_ETAGS="$ac_prog"
2794 echo "$as_me:2794: found $ac_dir/$ac_word" >&5
2800 ETAGS=$ac_cv_prog_ETAGS
2801 if test -n "$ETAGS"; then
2802 echo "$as_me:2802: result: $ETAGS" >&5
2803 echo "${ECHO_T}$ETAGS" >&6
2805 echo "$as_me:2805: result: no" >&5
2806 echo "${ECHO_T}no" >&6
2809 test -n "$ETAGS" && break
2812 # Extract the first word of "${CTAGS:-ctags}", so it can be a program name with args.
2813 set dummy ${CTAGS:-ctags}; ac_word=$2
2814 echo "$as_me:2814: checking for $ac_word" >&5
2815 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2816 if test "${ac_cv_prog_MAKE_LOWER_TAGS+set}" = set; then
2817 echo $ECHO_N "(cached) $ECHO_C" >&6
2819 if test -n "$MAKE_LOWER_TAGS"; then
2820 ac_cv_prog_MAKE_LOWER_TAGS="$MAKE_LOWER_TAGS" # Let the user override the test.
2822 ac_save_IFS=$IFS; IFS=$ac_path_separator
2824 for ac_dir in $ac_dummy; do
2826 test -z "$ac_dir" && ac_dir=.
2827 $as_executable_p "$ac_dir/$ac_word" || continue
2828 ac_cv_prog_MAKE_LOWER_TAGS="yes"
2829 echo "$as_me:2829: found $ac_dir/$ac_word" >&5
2833 test -z "$ac_cv_prog_MAKE_LOWER_TAGS" && ac_cv_prog_MAKE_LOWER_TAGS="no"
2836 MAKE_LOWER_TAGS=$ac_cv_prog_MAKE_LOWER_TAGS
2837 if test -n "$MAKE_LOWER_TAGS"; then
2838 echo "$as_me:2838: result: $MAKE_LOWER_TAGS" >&5
2839 echo "${ECHO_T}$MAKE_LOWER_TAGS" >&6
2841 echo "$as_me:2841: result: no" >&5
2842 echo "${ECHO_T}no" >&6
2845 if test "$cf_cv_mixedcase" = yes ; then
2846 # Extract the first word of "${ETAGS:-etags}", so it can be a program name with args.
2847 set dummy ${ETAGS:-etags}; ac_word=$2
2848 echo "$as_me:2848: checking for $ac_word" >&5
2849 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2850 if test "${ac_cv_prog_MAKE_UPPER_TAGS+set}" = set; then
2851 echo $ECHO_N "(cached) $ECHO_C" >&6
2853 if test -n "$MAKE_UPPER_TAGS"; then
2854 ac_cv_prog_MAKE_UPPER_TAGS="$MAKE_UPPER_TAGS" # Let the user override the test.
2856 ac_save_IFS=$IFS; IFS=$ac_path_separator
2858 for ac_dir in $ac_dummy; do
2860 test -z "$ac_dir" && ac_dir=.
2861 $as_executable_p "$ac_dir/$ac_word" || continue
2862 ac_cv_prog_MAKE_UPPER_TAGS="yes"
2863 echo "$as_me:2863: found $ac_dir/$ac_word" >&5
2867 test -z "$ac_cv_prog_MAKE_UPPER_TAGS" && ac_cv_prog_MAKE_UPPER_TAGS="no"
2870 MAKE_UPPER_TAGS=$ac_cv_prog_MAKE_UPPER_TAGS
2871 if test -n "$MAKE_UPPER_TAGS"; then
2872 echo "$as_me:2872: result: $MAKE_UPPER_TAGS" >&5
2873 echo "${ECHO_T}$MAKE_UPPER_TAGS" >&6
2875 echo "$as_me:2875: result: no" >&5
2876 echo "${ECHO_T}no" >&6
2883 if test "$MAKE_UPPER_TAGS" = yes ; then
2889 if test "$MAKE_LOWER_TAGS" = yes ; then
2895 echo "$as_me:2895: checking if -lm needed for math functions" >&5
2896 echo $ECHO_N "checking if -lm needed for math functions... $ECHO_C" >&6
2897 if test "${cf_cv_need_libm+set}" = set; then
2898 echo $ECHO_N "(cached) $ECHO_C" >&6
2901 cat >conftest.$ac_ext <<_ACEOF
2902 #line 2902 "configure"
2903 #include "confdefs.h"
2912 double x = rand(); printf("result = %g\n", pow(sin(x),x))
2917 rm -f conftest.$ac_objext conftest$ac_exeext
2918 if { (eval echo "$as_me:2918: \"$ac_link\"") >&5
2919 (eval $ac_link) 2>&5
2921 echo "$as_me:2921: \$? = $ac_status" >&5
2922 (exit $ac_status); } &&
2923 { ac_try='test -s conftest$ac_exeext'
2924 { (eval echo "$as_me:2924: \"$ac_try\"") >&5
2927 echo "$as_me:2927: \$? = $ac_status" >&5
2928 (exit $ac_status); }; }; then
2931 echo "$as_me: failed program was:" >&5
2932 cat conftest.$ac_ext >&5
2935 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
2937 echo "$as_me:2937: result: $cf_cv_need_libm" >&5
2938 echo "${ECHO_T}$cf_cv_need_libm" >&6
2939 if test "$cf_cv_need_libm" = yes
2947 CC_SHARED_OPTS=unknown
2948 CPPFLAGS="$CPPFLAGS"
2950 DFT_OBJ_SUBDIR=`pwd|sed -e's:.*/::'`
2951 DFT_UPR_MODEL="NORMAL"
2964 PACKAGE="ncurses-examples"
2970 TINFO_LIBS='$(LIBS_CURSES)'
2971 cf_cv_abi_version=""
2972 cf_cv_rel_version=""
2978 if test "$GCC" = yes
2980 cat > conftest.i <<EOF
2982 #define GCC_PRINTF 0
2987 #ifndef GCC_NORETURN
2988 #define GCC_NORETURN /* nothing */
2991 #define GCC_UNUSED /* nothing */
2994 if test "$GCC" = yes
2996 { echo "$as_me:2996: checking for $CC __attribute__ directives..." >&5
2997 echo "$as_me: checking for $CC __attribute__ directives..." >&6;}
2998 cat > conftest.$ac_ext <<EOF
2999 #line 2999 "${as_me:-configure}"
3000 #include "confdefs.h"
3001 #include "conftest.h"
3002 #include "conftest.i"
3004 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
3006 #define GCC_PRINTFLIKE(fmt,var) /*nothing*/
3009 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
3011 #define GCC_SCANFLIKE(fmt,var) /*nothing*/
3013 extern void wow(char *,...) GCC_SCANFLIKE(1,2);
3014 extern void oops(char *,...) GCC_PRINTFLIKE(1,2) GCC_NORETURN;
3015 extern void foo(void) GCC_NORETURN;
3016 int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { return 0; }
3018 cf_printf_attribute=no
3019 cf_scanf_attribute=no
3020 for cf_attribute in scanf printf unused noreturn
3023 cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
3025 cf_directive="__attribute__(($cf_attribute))"
3026 echo "checking for $CC $cf_directive" 1>&5
3028 case $cf_attribute in
3030 cf_printf_attribute=yes
3031 cat >conftest.h <<EOF
3032 #define GCC_$cf_ATTRIBUTE 1
3036 cf_scanf_attribute=yes
3037 cat >conftest.h <<EOF
3038 #define GCC_$cf_ATTRIBUTE 1
3042 cat >conftest.h <<EOF
3043 #define GCC_$cf_ATTRIBUTE $cf_directive
3048 if { (eval echo "$as_me:3048: \"$ac_compile\"") >&5
3049 (eval $ac_compile) 2>&5
3051 echo "$as_me:3051: \$? = $ac_status" >&5
3052 (exit $ac_status); }; then
3053 test -n "$verbose" && echo "$as_me:3053: result: ... $cf_attribute" >&5
3054 echo "${ECHO_T}... $cf_attribute" >&6
3055 cat conftest.h >>confdefs.h
3056 case $cf_attribute in
3059 cat >>confdefs.h <<EOF
3060 #define GCC_NORETURN $cf_directive
3065 cf_value='/* nothing */'
3066 if test "$cf_printf_attribute" != no ; then
3067 cf_value='__attribute__((format(printf,fmt,var)))'
3069 cat >>confdefs.h <<\EOF
3070 #define GCC_PRINTF 1
3075 cat >>confdefs.h <<EOF
3076 #define GCC_PRINTFLIKE(fmt,var) $cf_value
3081 cf_value='/* nothing */'
3082 if test "$cf_scanf_attribute" != no ; then
3083 cf_value='__attribute__((format(scanf,fmt,var)))'
3085 cat >>confdefs.h <<\EOF
3091 cat >>confdefs.h <<EOF
3092 #define GCC_SCANFLIKE(fmt,var) $cf_value
3098 cat >>confdefs.h <<EOF
3099 #define GCC_UNUSED $cf_directive
3107 fgrep define conftest.i >>confdefs.h
3112 echo "$as_me:3112: checking if you want to work around bogus compiler/loader warnings" >&5
3113 echo $ECHO_N "checking if you want to work around bogus compiler/loader warnings... $ECHO_C" >&6
3115 # Check whether --enable-string-hacks or --disable-string-hacks was given.
3116 if test "${enable_string_hacks+set}" = set; then
3117 enableval="$enable_string_hacks"
3118 with_string_hacks=$enableval
3120 with_string_hacks=no
3122 echo "$as_me:3122: result: $with_string_hacks" >&5
3123 echo "${ECHO_T}$with_string_hacks" >&6
3125 if test "x$with_string_hacks" = "xyes"; then
3127 cat >>confdefs.h <<\EOF
3128 #define USE_STRING_HACKS 1
3131 { echo "$as_me:3131: WARNING: enabling string-hacks to work around bogus compiler/loader warnings" >&5
3132 echo "$as_me: WARNING: enabling string-hacks to work around bogus compiler/loader warnings" >&2;}
3133 echo "$as_me:3133: checking for strlcat" >&5
3134 echo $ECHO_N "checking for strlcat... $ECHO_C" >&6
3135 if test "${ac_cv_func_strlcat+set}" = set; then
3136 echo $ECHO_N "(cached) $ECHO_C" >&6
3138 cat >conftest.$ac_ext <<_ACEOF
3139 #line 3139 "configure"
3140 #include "confdefs.h"
3141 #define strlcat autoconf_temporary
3142 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
3149 /* We use char because int might match the return type of a gcc2
3150 builtin and then its argument prototype would still apply. */
3151 char strlcat (void);
3157 /* The GNU C library defines stubs for functions which it implements
3158 to always fail with ENOSYS. Some functions are actually named
3159 something starting with __ and the normal name is an alias. */
3160 #if defined (__stub_strlcat) || defined (__stub___strlcat)
3161 #error found stub for strlcat
3169 rm -f conftest.$ac_objext conftest$ac_exeext
3170 if { (eval echo "$as_me:3170: \"$ac_link\"") >&5
3171 (eval $ac_link) 2>&5
3173 echo "$as_me:3173: \$? = $ac_status" >&5
3174 (exit $ac_status); } &&
3175 { ac_try='test -s conftest$ac_exeext'
3176 { (eval echo "$as_me:3176: \"$ac_try\"") >&5
3179 echo "$as_me:3179: \$? = $ac_status" >&5
3180 (exit $ac_status); }; }; then
3181 ac_cv_func_strlcat=yes
3183 echo "$as_me: failed program was:" >&5
3184 cat conftest.$ac_ext >&5
3185 ac_cv_func_strlcat=no
3187 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
3189 echo "$as_me:3189: result: $ac_cv_func_strlcat" >&5
3190 echo "${ECHO_T}$ac_cv_func_strlcat" >&6
3191 if test $ac_cv_func_strlcat = yes; then
3193 cat >>confdefs.h <<\EOF
3194 #define HAVE_STRLCAT 1
3199 echo "$as_me:3199: checking for strlcat in -lbsd" >&5
3200 echo $ECHO_N "checking for strlcat in -lbsd... $ECHO_C" >&6
3201 if test "${ac_cv_lib_bsd_strlcat+set}" = set; then
3202 echo $ECHO_N "(cached) $ECHO_C" >&6
3204 ac_check_lib_save_LIBS=$LIBS
3206 cat >conftest.$ac_ext <<_ACEOF
3207 #line 3207 "configure"
3208 #include "confdefs.h"
3210 /* Override any gcc2 internal prototype to avoid an error. */
3214 /* We use char because int might match the return type of a gcc2
3215 builtin and then its argument prototype would still apply. */
3225 rm -f conftest.$ac_objext conftest$ac_exeext
3226 if { (eval echo "$as_me:3226: \"$ac_link\"") >&5
3227 (eval $ac_link) 2>&5
3229 echo "$as_me:3229: \$? = $ac_status" >&5
3230 (exit $ac_status); } &&
3231 { ac_try='test -s conftest$ac_exeext'
3232 { (eval echo "$as_me:3232: \"$ac_try\"") >&5
3235 echo "$as_me:3235: \$? = $ac_status" >&5
3236 (exit $ac_status); }; }; then
3237 ac_cv_lib_bsd_strlcat=yes
3239 echo "$as_me: failed program was:" >&5
3240 cat conftest.$ac_ext >&5
3241 ac_cv_lib_bsd_strlcat=no
3243 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
3244 LIBS=$ac_check_lib_save_LIBS
3246 echo "$as_me:3246: result: $ac_cv_lib_bsd_strlcat" >&5
3247 echo "${ECHO_T}$ac_cv_lib_bsd_strlcat" >&6
3248 if test $ac_cv_lib_bsd_strlcat = yes; then
3251 # Filter out duplicates - this happens with badly-designed ".pc" files...
3252 for cf_add_1lib in $LIBS
3254 for cf_add_2lib in $cf_add_libs
3256 if test "x$cf_add_1lib" = "x$cf_add_2lib"
3262 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
3266 for ac_header in bsd/string.h
3268 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
3269 echo "$as_me:3269: checking for $ac_header" >&5
3270 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3271 if eval "test \"\${$as_ac_Header+set}\" = set"; then
3272 echo $ECHO_N "(cached) $ECHO_C" >&6
3274 cat >conftest.$ac_ext <<_ACEOF
3275 #line 3275 "configure"
3276 #include "confdefs.h"
3277 #include <$ac_header>
3279 if { (eval echo "$as_me:3279: \"$ac_cpp conftest.$ac_ext\"") >&5
3280 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3282 egrep -v '^ *\+' conftest.er1 >conftest.err
3284 cat conftest.err >&5
3285 echo "$as_me:3285: \$? = $ac_status" >&5
3286 (exit $ac_status); } >/dev/null; then
3287 if test -s conftest.err; then
3288 ac_cpp_err=$ac_c_preproc_warn_flag
3295 if test -z "$ac_cpp_err"; then
3296 eval "$as_ac_Header=yes"
3298 echo "$as_me: failed program was:" >&5
3299 cat conftest.$ac_ext >&5
3300 eval "$as_ac_Header=no"
3302 rm -f conftest.err conftest.$ac_ext
3304 echo "$as_me:3304: result: `eval echo '${'$as_ac_Header'}'`" >&5
3305 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
3306 if test `eval echo '${'$as_ac_Header'}'` = yes; then
3307 cat >>confdefs.h <<EOF
3308 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
3314 cat >>confdefs.h <<\EOF
3315 #define HAVE_STRLCAT 1
3322 for ac_func in strlcpy snprintf
3324 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
3325 echo "$as_me:3325: checking for $ac_func" >&5
3326 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
3327 if eval "test \"\${$as_ac_var+set}\" = set"; then
3328 echo $ECHO_N "(cached) $ECHO_C" >&6
3330 cat >conftest.$ac_ext <<_ACEOF
3331 #line 3331 "configure"
3332 #include "confdefs.h"
3333 #define $ac_func autoconf_temporary
3334 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
3341 /* We use char because int might match the return type of a gcc2
3342 builtin and then its argument prototype would still apply. */
3343 char $ac_func (void);
3349 /* The GNU C library defines stubs for functions which it implements
3350 to always fail with ENOSYS. Some functions are actually named
3351 something starting with __ and the normal name is an alias. */
3352 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3353 #error found stub for $ac_func
3361 rm -f conftest.$ac_objext conftest$ac_exeext
3362 if { (eval echo "$as_me:3362: \"$ac_link\"") >&5
3363 (eval $ac_link) 2>&5
3365 echo "$as_me:3365: \$? = $ac_status" >&5
3366 (exit $ac_status); } &&
3367 { ac_try='test -s conftest$ac_exeext'
3368 { (eval echo "$as_me:3368: \"$ac_try\"") >&5
3371 echo "$as_me:3371: \$? = $ac_status" >&5
3372 (exit $ac_status); }; }; then
3373 eval "$as_ac_var=yes"
3375 echo "$as_me: failed program was:" >&5
3376 cat conftest.$ac_ext >&5
3377 eval "$as_ac_var=no"
3379 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
3381 echo "$as_me:3381: result: `eval echo '${'$as_ac_var'}'`" >&5
3382 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
3383 if test `eval echo '${'$as_ac_var'}'` = yes; then
3384 cat >>confdefs.h <<EOF
3385 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
3394 cf_POSIX_C_SOURCE=199506L
3399 cf_xopen_source="-D_ALL_SOURCE"
3405 cf_xopen_source="-D_APPLE_C_SOURCE"
3408 cf_xopen_source="-D_DARWIN_C_SOURCE"
3411 (freebsd*|dragonfly*|midnightbsd*)
3412 # 5.x headers associate
3413 # _XOPEN_SOURCE=600 with _POSIX_C_SOURCE=200112L
3414 # _XOPEN_SOURCE=500 with _POSIX_C_SOURCE=199506L
3415 cf_POSIX_C_SOURCE=200112L
3417 cf_xopen_source="-D_BSD_TYPES -D__BSD_VISIBLE -D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
3420 cf_xopen_source="-D_HPUX_SOURCE -D_XOPEN_SOURCE=500"
3423 cf_xopen_source="-D_HPUX_SOURCE"
3426 cf_xopen_source="-D_SGI_SOURCE"
3429 (linux*|uclinux*|gnu*|mint*|k*bsd*-gnu|cygwin)
3431 cf_gnu_xopen_source=$cf_XOPEN_SOURCE
3433 echo "$as_me:3433: checking if this is the GNU C library" >&5
3434 echo $ECHO_N "checking if this is the GNU C library... $ECHO_C" >&6
3435 if test "${cf_cv_gnu_library+set}" = set; then
3436 echo $ECHO_N "(cached) $ECHO_C" >&6
3439 cat >conftest.$ac_ext <<_ACEOF
3440 #line 3440 "configure"
3441 #include "confdefs.h"
3442 #include <sys/types.h>
3447 #if __GLIBC__ > 0 && __GLIBC_MINOR__ >= 0
3449 #elif __NEWLIB__ > 0 && __NEWLIB_MINOR__ >= 0
3452 # error not GNU C library
3458 rm -f conftest.$ac_objext
3459 if { (eval echo "$as_me:3459: \"$ac_compile\"") >&5
3460 (eval $ac_compile) 2>&5
3462 echo "$as_me:3462: \$? = $ac_status" >&5
3463 (exit $ac_status); } &&
3464 { ac_try='test -s conftest.$ac_objext'
3465 { (eval echo "$as_me:3465: \"$ac_try\"") >&5
3468 echo "$as_me:3468: \$? = $ac_status" >&5
3469 (exit $ac_status); }; }; then
3470 cf_cv_gnu_library=yes
3472 echo "$as_me: failed program was:" >&5
3473 cat conftest.$ac_ext >&5
3474 cf_cv_gnu_library=no
3476 rm -f conftest.$ac_objext conftest.$ac_ext
3479 echo "$as_me:3479: result: $cf_cv_gnu_library" >&5
3480 echo "${ECHO_T}$cf_cv_gnu_library" >&6
3482 if test x$cf_cv_gnu_library = xyes; then
3484 # With glibc 2.19 (13 years after this check was begun), _DEFAULT_SOURCE
3485 # was changed to help a little. newlib incorporated the change about 4
3487 echo "$as_me:3487: checking if _DEFAULT_SOURCE can be used as a basis" >&5
3488 echo $ECHO_N "checking if _DEFAULT_SOURCE can be used as a basis... $ECHO_C" >&6
3489 if test "${cf_cv_gnu_library_219+set}" = set; then
3490 echo $ECHO_N "(cached) $ECHO_C" >&6
3495 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
3496 CPPFLAGS="${CPPFLAGS}-D_DEFAULT_SOURCE"
3498 cat >conftest.$ac_ext <<_ACEOF
3499 #line 3499 "configure"
3500 #include "confdefs.h"
3501 #include <sys/types.h>
3506 #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 19) || (__GLIBC__ > 2)
3508 #elif (__NEWLIB__ == 2 && __NEWLIB_MINOR__ >= 4) || (__GLIBC__ > 3)
3511 # error GNU C library __GLIBC__.__GLIBC_MINOR__ is too old
3517 rm -f conftest.$ac_objext
3518 if { (eval echo "$as_me:3518: \"$ac_compile\"") >&5
3519 (eval $ac_compile) 2>&5
3521 echo "$as_me:3521: \$? = $ac_status" >&5
3522 (exit $ac_status); } &&
3523 { ac_try='test -s conftest.$ac_objext'
3524 { (eval echo "$as_me:3524: \"$ac_try\"") >&5
3527 echo "$as_me:3527: \$? = $ac_status" >&5
3528 (exit $ac_status); }; }; then
3529 cf_cv_gnu_library_219=yes
3531 echo "$as_me: failed program was:" >&5
3532 cat conftest.$ac_ext >&5
3533 cf_cv_gnu_library_219=no
3535 rm -f conftest.$ac_objext conftest.$ac_ext
3539 echo "$as_me:3539: result: $cf_cv_gnu_library_219" >&5
3540 echo "${ECHO_T}$cf_cv_gnu_library_219" >&6
3542 if test "x$cf_cv_gnu_library_219" = xyes; then
3544 echo "$as_me:3544: checking if _XOPEN_SOURCE=$cf_gnu_xopen_source works with _DEFAULT_SOURCE" >&5
3545 echo $ECHO_N "checking if _XOPEN_SOURCE=$cf_gnu_xopen_source works with _DEFAULT_SOURCE... $ECHO_C" >&6
3546 if test "${cf_cv_gnu_dftsrc_219+set}" = set; then
3547 echo $ECHO_N "(cached) $ECHO_C" >&6
3553 cf_new_extra_cppflags=
3555 for cf_add_cflags in -D_DEFAULT_SOURCE -D_XOPEN_SOURCE=$cf_gnu_xopen_source
3557 case $cf_fix_cppflags in
3559 case $cf_add_cflags in
3560 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
3561 case $cf_add_cflags in
3563 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3565 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
3566 && test -z "${cf_tst_cflags}" \
3567 && cf_fix_cppflags=yes
3569 if test $cf_fix_cppflags = yes ; then
3571 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3572 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3575 elif test "${cf_tst_cflags}" = "\"'" ; then
3577 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3578 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3588 case $cf_add_cflags in
3590 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3592 CPPFLAGS=`echo "$CPPFLAGS" | \
3593 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3594 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3599 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
3600 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
3607 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
3608 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
3615 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3616 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3618 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
3620 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
3621 && test -z "${cf_tst_cflags}" \
3622 && cf_fix_cppflags=no
3627 if test -n "$cf_new_cflags" ; then
3629 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
3630 CFLAGS="${CFLAGS}$cf_new_cflags"
3634 if test -n "$cf_new_cppflags" ; then
3636 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
3637 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
3641 if test -n "$cf_new_extra_cppflags" ; then
3643 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
3644 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
3648 cat >conftest.$ac_ext <<_ACEOF
3649 #line 3649 "configure"
3650 #include "confdefs.h"
3653 #include <sys/types.h>
3659 #if (_XOPEN_SOURCE >= $cf_gnu_xopen_source) && (MB_LEN_MAX > 1)
3662 # error GNU C library is too old
3668 rm -f conftest.$ac_objext
3669 if { (eval echo "$as_me:3669: \"$ac_compile\"") >&5
3670 (eval $ac_compile) 2>&5
3672 echo "$as_me:3672: \$? = $ac_status" >&5
3673 (exit $ac_status); } &&
3674 { ac_try='test -s conftest.$ac_objext'
3675 { (eval echo "$as_me:3675: \"$ac_try\"") >&5
3678 echo "$as_me:3678: \$? = $ac_status" >&5
3679 (exit $ac_status); }; }; then
3680 cf_cv_gnu_dftsrc_219=yes
3682 echo "$as_me: failed program was:" >&5
3683 cat conftest.$ac_ext >&5
3684 cf_cv_gnu_dftsrc_219=no
3686 rm -f conftest.$ac_objext conftest.$ac_ext
3689 echo "$as_me:3689: result: $cf_cv_gnu_dftsrc_219" >&5
3690 echo "${ECHO_T}$cf_cv_gnu_dftsrc_219" >&6
3691 test "x$cf_cv_gnu_dftsrc_219" = "xyes" || CPPFLAGS="$cf_save"
3693 cf_cv_gnu_dftsrc_219=maybe
3696 if test "x$cf_cv_gnu_dftsrc_219" != xyes; then
3698 echo "$as_me:3698: checking if we must define _GNU_SOURCE" >&5
3699 echo $ECHO_N "checking if we must define _GNU_SOURCE... $ECHO_C" >&6
3700 if test "${cf_cv_gnu_source+set}" = set; then
3701 echo $ECHO_N "(cached) $ECHO_C" >&6
3704 cat >conftest.$ac_ext <<_ACEOF
3705 #line 3705 "configure"
3706 #include "confdefs.h"
3707 #include <sys/types.h>
3712 #ifndef _XOPEN_SOURCE
3713 #error expected _XOPEN_SOURCE to be defined
3719 rm -f conftest.$ac_objext
3720 if { (eval echo "$as_me:3720: \"$ac_compile\"") >&5
3721 (eval $ac_compile) 2>&5
3723 echo "$as_me:3723: \$? = $ac_status" >&5
3724 (exit $ac_status); } &&
3725 { ac_try='test -s conftest.$ac_objext'
3726 { (eval echo "$as_me:3726: \"$ac_try\"") >&5
3729 echo "$as_me:3729: \$? = $ac_status" >&5
3730 (exit $ac_status); }; }; then
3733 echo "$as_me: failed program was:" >&5
3734 cat conftest.$ac_ext >&5
3740 cf_new_extra_cppflags=
3742 for cf_add_cflags in -D_GNU_SOURCE
3744 case $cf_fix_cppflags in
3746 case $cf_add_cflags in
3747 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
3748 case $cf_add_cflags in
3750 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3752 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
3753 && test -z "${cf_tst_cflags}" \
3754 && cf_fix_cppflags=yes
3756 if test $cf_fix_cppflags = yes ; then
3758 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3759 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3762 elif test "${cf_tst_cflags}" = "\"'" ; then
3764 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3765 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3775 case $cf_add_cflags in
3777 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3779 CPPFLAGS=`echo "$CPPFLAGS" | \
3780 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3781 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3786 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
3787 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
3794 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
3795 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
3802 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3803 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3805 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
3807 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
3808 && test -z "${cf_tst_cflags}" \
3809 && cf_fix_cppflags=no
3814 if test -n "$cf_new_cflags" ; then
3816 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
3817 CFLAGS="${CFLAGS}$cf_new_cflags"
3821 if test -n "$cf_new_cppflags" ; then
3823 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
3824 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
3828 if test -n "$cf_new_extra_cppflags" ; then
3830 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
3831 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
3835 cat >conftest.$ac_ext <<_ACEOF
3836 #line 3836 "configure"
3837 #include "confdefs.h"
3838 #include <sys/types.h>
3843 #ifdef _XOPEN_SOURCE
3844 #error expected _XOPEN_SOURCE to be undefined
3850 rm -f conftest.$ac_objext
3851 if { (eval echo "$as_me:3851: \"$ac_compile\"") >&5
3852 (eval $ac_compile) 2>&5
3854 echo "$as_me:3854: \$? = $ac_status" >&5
3855 (exit $ac_status); } &&
3856 { ac_try='test -s conftest.$ac_objext'
3857 { (eval echo "$as_me:3857: \"$ac_try\"") >&5
3860 echo "$as_me:3860: \$? = $ac_status" >&5
3861 (exit $ac_status); }; }; then
3864 echo "$as_me: failed program was:" >&5
3865 cat conftest.$ac_ext >&5
3866 cf_cv_gnu_source=yes
3868 rm -f conftest.$ac_objext conftest.$ac_ext
3872 rm -f conftest.$ac_objext conftest.$ac_ext
3875 echo "$as_me:3875: result: $cf_cv_gnu_source" >&5
3876 echo "${ECHO_T}$cf_cv_gnu_source" >&6
3878 if test "$cf_cv_gnu_source" = yes
3880 echo "$as_me:3880: checking if we should also define _DEFAULT_SOURCE" >&5
3881 echo $ECHO_N "checking if we should also define _DEFAULT_SOURCE... $ECHO_C" >&6
3882 if test "${cf_cv_default_source+set}" = set; then
3883 echo $ECHO_N "(cached) $ECHO_C" >&6
3886 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
3887 CPPFLAGS="${CPPFLAGS}-D_GNU_SOURCE"
3889 cat >conftest.$ac_ext <<_ACEOF
3890 #line 3890 "configure"
3891 #include "confdefs.h"
3892 #include <sys/types.h>
3897 #ifdef _DEFAULT_SOURCE
3898 #error expected _DEFAULT_SOURCE to be undefined
3904 rm -f conftest.$ac_objext
3905 if { (eval echo "$as_me:3905: \"$ac_compile\"") >&5
3906 (eval $ac_compile) 2>&5
3908 echo "$as_me:3908: \$? = $ac_status" >&5
3909 (exit $ac_status); } &&
3910 { ac_try='test -s conftest.$ac_objext'
3911 { (eval echo "$as_me:3911: \"$ac_try\"") >&5
3914 echo "$as_me:3914: \$? = $ac_status" >&5
3915 (exit $ac_status); }; }; then
3916 cf_cv_default_source=no
3918 echo "$as_me: failed program was:" >&5
3919 cat conftest.$ac_ext >&5
3920 cf_cv_default_source=yes
3922 rm -f conftest.$ac_objext conftest.$ac_ext
3925 echo "$as_me:3925: result: $cf_cv_default_source" >&5
3926 echo "${ECHO_T}$cf_cv_default_source" >&6
3927 if test "$cf_cv_default_source" = yes
3930 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
3931 CPPFLAGS="${CPPFLAGS}-D_DEFAULT_SOURCE"
3941 cf_xopen_source="-D_NETBSD_SOURCE" # POSIX.1-2001 features are ifdef'd with this...
3944 # setting _XOPEN_SOURCE or _POSIX_SOURCE breaks <sys/select.h> and other headers which use u_int / u_short types
3947 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
3949 cf_save_CFLAGS="$CFLAGS"
3950 cf_save_CPPFLAGS="$CPPFLAGS"
3952 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
3953 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3954 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
3956 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
3957 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3958 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
3960 echo "$as_me:3960: checking if we should define _POSIX_C_SOURCE" >&5
3961 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
3962 if test "${cf_cv_posix_c_source+set}" = set; then
3963 echo $ECHO_N "(cached) $ECHO_C" >&6
3966 echo "${as_me:-configure}:3966: testing if the symbol is already defined go no further ..." 1>&5
3968 cat >conftest.$ac_ext <<_ACEOF
3969 #line 3969 "configure"
3970 #include "confdefs.h"
3971 #include <sys/types.h>
3976 #ifndef _POSIX_C_SOURCE
3983 rm -f conftest.$ac_objext
3984 if { (eval echo "$as_me:3984: \"$ac_compile\"") >&5
3985 (eval $ac_compile) 2>&5
3987 echo "$as_me:3987: \$? = $ac_status" >&5
3988 (exit $ac_status); } &&
3989 { ac_try='test -s conftest.$ac_objext'
3990 { (eval echo "$as_me:3990: \"$ac_try\"") >&5
3993 echo "$as_me:3993: \$? = $ac_status" >&5
3994 (exit $ac_status); }; }; then
3995 cf_cv_posix_c_source=no
3997 echo "$as_me: failed program was:" >&5
3998 cat conftest.$ac_ext >&5
3999 cf_want_posix_source=no
4000 case .$cf_POSIX_C_SOURCE in
4002 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
4005 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
4006 cf_want_posix_source=yes
4009 cf_want_posix_source=yes
4012 if test "$cf_want_posix_source" = yes ; then
4013 cat >conftest.$ac_ext <<_ACEOF
4014 #line 4014 "configure"
4015 #include "confdefs.h"
4016 #include <sys/types.h>
4021 #ifdef _POSIX_SOURCE
4028 rm -f conftest.$ac_objext
4029 if { (eval echo "$as_me:4029: \"$ac_compile\"") >&5
4030 (eval $ac_compile) 2>&5
4032 echo "$as_me:4032: \$? = $ac_status" >&5
4033 (exit $ac_status); } &&
4034 { ac_try='test -s conftest.$ac_objext'
4035 { (eval echo "$as_me:4035: \"$ac_try\"") >&5
4038 echo "$as_me:4038: \$? = $ac_status" >&5
4039 (exit $ac_status); }; }; then
4042 echo "$as_me: failed program was:" >&5
4043 cat conftest.$ac_ext >&5
4044 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
4046 rm -f conftest.$ac_objext conftest.$ac_ext
4049 echo "${as_me:-configure}:4049: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
4051 CFLAGS="$cf_trim_CFLAGS"
4052 CPPFLAGS="$cf_trim_CPPFLAGS"
4054 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4055 CPPFLAGS="${CPPFLAGS}$cf_cv_posix_c_source"
4057 echo "${as_me:-configure}:4057: testing if the second compile does not leave our definition intact error ..." 1>&5
4059 cat >conftest.$ac_ext <<_ACEOF
4060 #line 4060 "configure"
4061 #include "confdefs.h"
4062 #include <sys/types.h>
4067 #ifndef _POSIX_C_SOURCE
4074 rm -f conftest.$ac_objext
4075 if { (eval echo "$as_me:4075: \"$ac_compile\"") >&5
4076 (eval $ac_compile) 2>&5
4078 echo "$as_me:4078: \$? = $ac_status" >&5
4079 (exit $ac_status); } &&
4080 { ac_try='test -s conftest.$ac_objext'
4081 { (eval echo "$as_me:4081: \"$ac_try\"") >&5
4084 echo "$as_me:4084: \$? = $ac_status" >&5
4085 (exit $ac_status); }; }; then
4088 echo "$as_me: failed program was:" >&5
4089 cat conftest.$ac_ext >&5
4090 cf_cv_posix_c_source=no
4092 rm -f conftest.$ac_objext conftest.$ac_ext
4093 CFLAGS="$cf_save_CFLAGS"
4094 CPPFLAGS="$cf_save_CPPFLAGS"
4097 rm -f conftest.$ac_objext conftest.$ac_ext
4100 echo "$as_me:4100: result: $cf_cv_posix_c_source" >&5
4101 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
4103 if test "$cf_cv_posix_c_source" != no ; then
4104 CFLAGS="$cf_trim_CFLAGS"
4105 CPPFLAGS="$cf_trim_CPPFLAGS"
4110 cf_new_extra_cppflags=
4112 for cf_add_cflags in $cf_cv_posix_c_source
4114 case $cf_fix_cppflags in
4116 case $cf_add_cflags in
4117 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4118 case $cf_add_cflags in
4120 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4122 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4123 && test -z "${cf_tst_cflags}" \
4124 && cf_fix_cppflags=yes
4126 if test $cf_fix_cppflags = yes ; then
4128 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4129 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4132 elif test "${cf_tst_cflags}" = "\"'" ; then
4134 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4135 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4145 case $cf_add_cflags in
4147 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4149 CPPFLAGS=`echo "$CPPFLAGS" | \
4150 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4151 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4156 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4157 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4164 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4165 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4172 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4173 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4175 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
4177 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4178 && test -z "${cf_tst_cflags}" \
4179 && cf_fix_cppflags=no
4184 if test -n "$cf_new_cflags" ; then
4186 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4187 CFLAGS="${CFLAGS}$cf_new_cflags"
4191 if test -n "$cf_new_cppflags" ; then
4193 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4194 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4198 if test -n "$cf_new_extra_cppflags" ; then
4200 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4201 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4209 cf_xopen_source="-D_NETBSD_SOURCE" # setting _XOPEN_SOURCE breaks IPv6 for lynx on NetBSD 1.6, breaks xterm, is not needed for ncursesw
4212 # setting _XOPEN_SOURCE lower than 500 breaks g++ compile with wchar.h, needed for ncursesw
4213 cf_xopen_source="-D_BSD_SOURCE"
4217 # setting _XOPEN_SOURCE breaks xterm on OpenBSD 2.8, is not needed for ncursesw
4220 cf_xopen_source="-D_OSF_SOURCE"
4223 cf_xopen_source="-D_QNX_SOURCE"
4226 # setting _XOPEN_SOURCE breaks Lynx on SCO Unix / OpenServer
4229 cf_xopen_source="-D__EXTENSIONS__"
4230 cf_cv_xopen_source=broken
4232 (sysv4.2uw2.*) # Novell/SCO UnixWare 2.x (tested on 2.1.2)
4238 echo "$as_me:4238: checking if we should define _XOPEN_SOURCE" >&5
4239 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
4240 if test "${cf_cv_xopen_source+set}" = set; then
4241 echo $ECHO_N "(cached) $ECHO_C" >&6
4244 cat >conftest.$ac_ext <<_ACEOF
4245 #line 4245 "configure"
4246 #include "confdefs.h"
4250 #include <sys/types.h>
4256 #ifndef _XOPEN_SOURCE
4263 rm -f conftest.$ac_objext
4264 if { (eval echo "$as_me:4264: \"$ac_compile\"") >&5
4265 (eval $ac_compile) 2>&5
4267 echo "$as_me:4267: \$? = $ac_status" >&5
4268 (exit $ac_status); } &&
4269 { ac_try='test -s conftest.$ac_objext'
4270 { (eval echo "$as_me:4270: \"$ac_try\"") >&5
4273 echo "$as_me:4273: \$? = $ac_status" >&5
4274 (exit $ac_status); }; }; then
4275 cf_cv_xopen_source=no
4277 echo "$as_me: failed program was:" >&5
4278 cat conftest.$ac_ext >&5
4281 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4282 CPPFLAGS="${CPPFLAGS}-D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
4284 cat >conftest.$ac_ext <<_ACEOF
4285 #line 4285 "configure"
4286 #include "confdefs.h"
4290 #include <sys/types.h>
4296 #ifdef _XOPEN_SOURCE
4303 rm -f conftest.$ac_objext
4304 if { (eval echo "$as_me:4304: \"$ac_compile\"") >&5
4305 (eval $ac_compile) 2>&5
4307 echo "$as_me:4307: \$? = $ac_status" >&5
4308 (exit $ac_status); } &&
4309 { ac_try='test -s conftest.$ac_objext'
4310 { (eval echo "$as_me:4310: \"$ac_try\"") >&5
4313 echo "$as_me:4313: \$? = $ac_status" >&5
4314 (exit $ac_status); }; }; then
4315 cf_cv_xopen_source=no
4317 echo "$as_me: failed program was:" >&5
4318 cat conftest.$ac_ext >&5
4319 cf_cv_xopen_source=$cf_XOPEN_SOURCE
4321 rm -f conftest.$ac_objext conftest.$ac_ext
4325 rm -f conftest.$ac_objext conftest.$ac_ext
4328 echo "$as_me:4328: result: $cf_cv_xopen_source" >&5
4329 echo "${ECHO_T}$cf_cv_xopen_source" >&6
4331 if test "$cf_cv_xopen_source" != no ; then
4333 CFLAGS=`echo "$CFLAGS" | \
4334 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
4335 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
4337 CPPFLAGS=`echo "$CPPFLAGS" | \
4338 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
4339 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
4341 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
4346 cf_new_extra_cppflags=
4348 for cf_add_cflags in $cf_temp_xopen_source
4350 case $cf_fix_cppflags in
4352 case $cf_add_cflags in
4353 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4354 case $cf_add_cflags in
4356 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4358 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4359 && test -z "${cf_tst_cflags}" \
4360 && cf_fix_cppflags=yes
4362 if test $cf_fix_cppflags = yes ; then
4364 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4365 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4368 elif test "${cf_tst_cflags}" = "\"'" ; then
4370 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4371 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4381 case $cf_add_cflags in
4383 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4385 CPPFLAGS=`echo "$CPPFLAGS" | \
4386 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4387 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4392 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4393 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4400 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4401 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4408 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4409 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4411 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
4413 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4414 && test -z "${cf_tst_cflags}" \
4415 && cf_fix_cppflags=no
4420 if test -n "$cf_new_cflags" ; then
4422 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4423 CFLAGS="${CFLAGS}$cf_new_cflags"
4427 if test -n "$cf_new_cppflags" ; then
4429 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4430 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4434 if test -n "$cf_new_extra_cppflags" ; then
4436 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4437 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4443 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
4445 cf_save_CFLAGS="$CFLAGS"
4446 cf_save_CPPFLAGS="$CPPFLAGS"
4448 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
4449 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
4450 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
4452 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
4453 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
4454 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
4456 echo "$as_me:4456: checking if we should define _POSIX_C_SOURCE" >&5
4457 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
4458 if test "${cf_cv_posix_c_source+set}" = set; then
4459 echo $ECHO_N "(cached) $ECHO_C" >&6
4462 echo "${as_me:-configure}:4462: testing if the symbol is already defined go no further ..." 1>&5
4464 cat >conftest.$ac_ext <<_ACEOF
4465 #line 4465 "configure"
4466 #include "confdefs.h"
4467 #include <sys/types.h>
4472 #ifndef _POSIX_C_SOURCE
4479 rm -f conftest.$ac_objext
4480 if { (eval echo "$as_me:4480: \"$ac_compile\"") >&5
4481 (eval $ac_compile) 2>&5
4483 echo "$as_me:4483: \$? = $ac_status" >&5
4484 (exit $ac_status); } &&
4485 { ac_try='test -s conftest.$ac_objext'
4486 { (eval echo "$as_me:4486: \"$ac_try\"") >&5
4489 echo "$as_me:4489: \$? = $ac_status" >&5
4490 (exit $ac_status); }; }; then
4491 cf_cv_posix_c_source=no
4493 echo "$as_me: failed program was:" >&5
4494 cat conftest.$ac_ext >&5
4495 cf_want_posix_source=no
4496 case .$cf_POSIX_C_SOURCE in
4498 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
4501 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
4502 cf_want_posix_source=yes
4505 cf_want_posix_source=yes
4508 if test "$cf_want_posix_source" = yes ; then
4509 cat >conftest.$ac_ext <<_ACEOF
4510 #line 4510 "configure"
4511 #include "confdefs.h"
4512 #include <sys/types.h>
4517 #ifdef _POSIX_SOURCE
4524 rm -f conftest.$ac_objext
4525 if { (eval echo "$as_me:4525: \"$ac_compile\"") >&5
4526 (eval $ac_compile) 2>&5
4528 echo "$as_me:4528: \$? = $ac_status" >&5
4529 (exit $ac_status); } &&
4530 { ac_try='test -s conftest.$ac_objext'
4531 { (eval echo "$as_me:4531: \"$ac_try\"") >&5
4534 echo "$as_me:4534: \$? = $ac_status" >&5
4535 (exit $ac_status); }; }; then
4538 echo "$as_me: failed program was:" >&5
4539 cat conftest.$ac_ext >&5
4540 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
4542 rm -f conftest.$ac_objext conftest.$ac_ext
4545 echo "${as_me:-configure}:4545: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
4547 CFLAGS="$cf_trim_CFLAGS"
4548 CPPFLAGS="$cf_trim_CPPFLAGS"
4550 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4551 CPPFLAGS="${CPPFLAGS}$cf_cv_posix_c_source"
4553 echo "${as_me:-configure}:4553: testing if the second compile does not leave our definition intact error ..." 1>&5
4555 cat >conftest.$ac_ext <<_ACEOF
4556 #line 4556 "configure"
4557 #include "confdefs.h"
4558 #include <sys/types.h>
4563 #ifndef _POSIX_C_SOURCE
4570 rm -f conftest.$ac_objext
4571 if { (eval echo "$as_me:4571: \"$ac_compile\"") >&5
4572 (eval $ac_compile) 2>&5
4574 echo "$as_me:4574: \$? = $ac_status" >&5
4575 (exit $ac_status); } &&
4576 { ac_try='test -s conftest.$ac_objext'
4577 { (eval echo "$as_me:4577: \"$ac_try\"") >&5
4580 echo "$as_me:4580: \$? = $ac_status" >&5
4581 (exit $ac_status); }; }; then
4584 echo "$as_me: failed program was:" >&5
4585 cat conftest.$ac_ext >&5
4586 cf_cv_posix_c_source=no
4588 rm -f conftest.$ac_objext conftest.$ac_ext
4589 CFLAGS="$cf_save_CFLAGS"
4590 CPPFLAGS="$cf_save_CPPFLAGS"
4593 rm -f conftest.$ac_objext conftest.$ac_ext
4596 echo "$as_me:4596: result: $cf_cv_posix_c_source" >&5
4597 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
4599 if test "$cf_cv_posix_c_source" != no ; then
4600 CFLAGS="$cf_trim_CFLAGS"
4601 CPPFLAGS="$cf_trim_CPPFLAGS"
4606 cf_new_extra_cppflags=
4608 for cf_add_cflags in $cf_cv_posix_c_source
4610 case $cf_fix_cppflags in
4612 case $cf_add_cflags in
4613 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4614 case $cf_add_cflags in
4616 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4618 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4619 && test -z "${cf_tst_cflags}" \
4620 && cf_fix_cppflags=yes
4622 if test $cf_fix_cppflags = yes ; then
4624 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4625 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4628 elif test "${cf_tst_cflags}" = "\"'" ; then
4630 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4631 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4641 case $cf_add_cflags in
4643 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4645 CPPFLAGS=`echo "$CPPFLAGS" | \
4646 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4647 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4652 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4653 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4660 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4661 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4668 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4669 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4671 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
4673 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4674 && test -z "${cf_tst_cflags}" \
4675 && cf_fix_cppflags=no
4680 if test -n "$cf_new_cflags" ; then
4682 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4683 CFLAGS="${CFLAGS}$cf_new_cflags"
4687 if test -n "$cf_new_cppflags" ; then
4689 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4690 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4694 if test -n "$cf_new_extra_cppflags" ; then
4696 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4697 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4706 if test -n "$cf_xopen_source" ; then
4711 cf_new_extra_cppflags=
4713 for cf_add_cflags in $cf_xopen_source
4715 case $cf_fix_cppflags in
4717 case $cf_add_cflags in
4718 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4719 case $cf_add_cflags in
4721 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4723 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4724 && test -z "${cf_tst_cflags}" \
4725 && cf_fix_cppflags=yes
4727 if test $cf_fix_cppflags = yes ; then
4729 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4730 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4733 elif test "${cf_tst_cflags}" = "\"'" ; then
4735 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4736 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4746 case $cf_add_cflags in
4748 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4750 CPPFLAGS=`echo "$CPPFLAGS" | \
4751 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4752 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4757 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4758 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4765 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4766 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4773 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4774 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4776 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
4778 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4779 && test -z "${cf_tst_cflags}" \
4780 && cf_fix_cppflags=no
4785 if test -n "$cf_new_cflags" ; then
4786 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
4788 echo "${as_me:-configure}:4788: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
4790 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4791 CFLAGS="${CFLAGS}$cf_new_cflags"
4795 if test -n "$cf_new_cppflags" ; then
4796 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
4798 echo "${as_me:-configure}:4798: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
4800 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4801 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4805 if test -n "$cf_new_extra_cppflags" ; then
4806 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
4808 echo "${as_me:-configure}:4808: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
4810 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4811 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4817 if test -n "$cf_XOPEN_SOURCE" && test -z "$cf_cv_xopen_source" ; then
4818 echo "$as_me:4818: checking if _XOPEN_SOURCE really is set" >&5
4819 echo $ECHO_N "checking if _XOPEN_SOURCE really is set... $ECHO_C" >&6
4820 cat >conftest.$ac_ext <<_ACEOF
4821 #line 4821 "configure"
4822 #include "confdefs.h"
4828 #ifndef _XOPEN_SOURCE
4835 rm -f conftest.$ac_objext
4836 if { (eval echo "$as_me:4836: \"$ac_compile\"") >&5
4837 (eval $ac_compile) 2>&5
4839 echo "$as_me:4839: \$? = $ac_status" >&5
4840 (exit $ac_status); } &&
4841 { ac_try='test -s conftest.$ac_objext'
4842 { (eval echo "$as_me:4842: \"$ac_try\"") >&5
4845 echo "$as_me:4845: \$? = $ac_status" >&5
4846 (exit $ac_status); }; }; then
4847 cf_XOPEN_SOURCE_set=yes
4849 echo "$as_me: failed program was:" >&5
4850 cat conftest.$ac_ext >&5
4851 cf_XOPEN_SOURCE_set=no
4853 rm -f conftest.$ac_objext conftest.$ac_ext
4854 echo "$as_me:4854: result: $cf_XOPEN_SOURCE_set" >&5
4855 echo "${ECHO_T}$cf_XOPEN_SOURCE_set" >&6
4856 if test $cf_XOPEN_SOURCE_set = yes
4858 cat >conftest.$ac_ext <<_ACEOF
4859 #line 4859 "configure"
4860 #include "confdefs.h"
4866 #if (_XOPEN_SOURCE - 0) < $cf_XOPEN_SOURCE
4873 rm -f conftest.$ac_objext
4874 if { (eval echo "$as_me:4874: \"$ac_compile\"") >&5
4875 (eval $ac_compile) 2>&5
4877 echo "$as_me:4877: \$? = $ac_status" >&5
4878 (exit $ac_status); } &&
4879 { ac_try='test -s conftest.$ac_objext'
4880 { (eval echo "$as_me:4880: \"$ac_try\"") >&5
4883 echo "$as_me:4883: \$? = $ac_status" >&5
4884 (exit $ac_status); }; }; then
4885 cf_XOPEN_SOURCE_set_ok=yes
4887 echo "$as_me: failed program was:" >&5
4888 cat conftest.$ac_ext >&5
4889 cf_XOPEN_SOURCE_set_ok=no
4891 rm -f conftest.$ac_objext conftest.$ac_ext
4892 if test $cf_XOPEN_SOURCE_set_ok = no
4894 { echo "$as_me:4894: WARNING: _XOPEN_SOURCE is lower than requested" >&5
4895 echo "$as_me: WARNING: _XOPEN_SOURCE is lower than requested" >&2;}
4899 echo "$as_me:4899: checking if we should define _XOPEN_SOURCE" >&5
4900 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
4901 if test "${cf_cv_xopen_source+set}" = set; then
4902 echo $ECHO_N "(cached) $ECHO_C" >&6
4905 cat >conftest.$ac_ext <<_ACEOF
4906 #line 4906 "configure"
4907 #include "confdefs.h"
4911 #include <sys/types.h>
4917 #ifndef _XOPEN_SOURCE
4924 rm -f conftest.$ac_objext
4925 if { (eval echo "$as_me:4925: \"$ac_compile\"") >&5
4926 (eval $ac_compile) 2>&5
4928 echo "$as_me:4928: \$? = $ac_status" >&5
4929 (exit $ac_status); } &&
4930 { ac_try='test -s conftest.$ac_objext'
4931 { (eval echo "$as_me:4931: \"$ac_try\"") >&5
4934 echo "$as_me:4934: \$? = $ac_status" >&5
4935 (exit $ac_status); }; }; then
4936 cf_cv_xopen_source=no
4938 echo "$as_me: failed program was:" >&5
4939 cat conftest.$ac_ext >&5
4942 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4943 CPPFLAGS="${CPPFLAGS}-D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
4945 cat >conftest.$ac_ext <<_ACEOF
4946 #line 4946 "configure"
4947 #include "confdefs.h"
4951 #include <sys/types.h>
4957 #ifdef _XOPEN_SOURCE
4964 rm -f conftest.$ac_objext
4965 if { (eval echo "$as_me:4965: \"$ac_compile\"") >&5
4966 (eval $ac_compile) 2>&5
4968 echo "$as_me:4968: \$? = $ac_status" >&5
4969 (exit $ac_status); } &&
4970 { ac_try='test -s conftest.$ac_objext'
4971 { (eval echo "$as_me:4971: \"$ac_try\"") >&5
4974 echo "$as_me:4974: \$? = $ac_status" >&5
4975 (exit $ac_status); }; }; then
4976 cf_cv_xopen_source=no
4978 echo "$as_me: failed program was:" >&5
4979 cat conftest.$ac_ext >&5
4980 cf_cv_xopen_source=$cf_XOPEN_SOURCE
4982 rm -f conftest.$ac_objext conftest.$ac_ext
4986 rm -f conftest.$ac_objext conftest.$ac_ext
4989 echo "$as_me:4989: result: $cf_cv_xopen_source" >&5
4990 echo "${ECHO_T}$cf_cv_xopen_source" >&6
4992 if test "$cf_cv_xopen_source" != no ; then
4994 CFLAGS=`echo "$CFLAGS" | \
4995 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
4996 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
4998 CPPFLAGS=`echo "$CPPFLAGS" | \
4999 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
5000 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
5002 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
5007 cf_new_extra_cppflags=
5009 for cf_add_cflags in $cf_temp_xopen_source
5011 case $cf_fix_cppflags in
5013 case $cf_add_cflags in
5014 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
5015 case $cf_add_cflags in
5017 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
5019 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
5020 && test -z "${cf_tst_cflags}" \
5021 && cf_fix_cppflags=yes
5023 if test $cf_fix_cppflags = yes ; then
5025 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5026 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5029 elif test "${cf_tst_cflags}" = "\"'" ; then
5031 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5032 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5042 case $cf_add_cflags in
5044 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
5046 CPPFLAGS=`echo "$CPPFLAGS" | \
5047 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
5048 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
5053 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
5054 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
5061 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
5062 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
5069 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5070 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5072 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
5074 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
5075 && test -z "${cf_tst_cflags}" \
5076 && cf_fix_cppflags=no
5081 if test -n "$cf_new_cflags" ; then
5083 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
5084 CFLAGS="${CFLAGS}$cf_new_cflags"
5088 if test -n "$cf_new_cppflags" ; then
5090 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5091 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
5095 if test -n "$cf_new_extra_cppflags" ; then
5097 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
5098 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
5107 echo "$as_me:5107: checking for signal global datatype" >&5
5108 echo $ECHO_N "checking for signal global datatype... $ECHO_C" >&6
5109 if test "${cf_cv_sig_atomic_t+set}" = set; then
5110 echo $ECHO_N "(cached) $ECHO_C" >&6
5114 "volatile sig_atomic_t" \
5118 cat >conftest.$ac_ext <<_ACEOF
5119 #line 5119 "configure"
5120 #include "confdefs.h"
5122 #include <sys/types.h>
5128 static void handler(int sig)
5135 signal(SIGINT, handler);
5141 rm -f conftest.$ac_objext
5142 if { (eval echo "$as_me:5142: \"$ac_compile\"") >&5
5143 (eval $ac_compile) 2>&5
5145 echo "$as_me:5145: \$? = $ac_status" >&5
5146 (exit $ac_status); } &&
5147 { ac_try='test -s conftest.$ac_objext'
5148 { (eval echo "$as_me:5148: \"$ac_try\"") >&5
5151 echo "$as_me:5151: \$? = $ac_status" >&5
5152 (exit $ac_status); }; }; then
5153 cf_cv_sig_atomic_t=$cf_type
5155 echo "$as_me: failed program was:" >&5
5156 cat conftest.$ac_ext >&5
5157 cf_cv_sig_atomic_t=no
5159 rm -f conftest.$ac_objext conftest.$ac_ext
5160 test "$cf_cv_sig_atomic_t" != no && break
5165 echo "$as_me:5165: result: $cf_cv_sig_atomic_t" >&5
5166 echo "${ECHO_T}$cf_cv_sig_atomic_t" >&6
5167 test "$cf_cv_sig_atomic_t" != no &&
5168 cat >>confdefs.h <<EOF
5169 #define SIG_ATOMIC_T $cf_cv_sig_atomic_t
5172 # Work around breakage on OS X
5174 echo "$as_me:5174: checking if SIGWINCH is defined" >&5
5175 echo $ECHO_N "checking if SIGWINCH is defined... $ECHO_C" >&6
5176 if test "${cf_cv_define_sigwinch+set}" = set; then
5177 echo $ECHO_N "(cached) $ECHO_C" >&6
5180 cat >conftest.$ac_ext <<_ACEOF
5181 #line 5181 "configure"
5182 #include "confdefs.h"
5184 #include <sys/types.h>
5185 #include <sys/signal.h>
5195 rm -f conftest.$ac_objext
5196 if { (eval echo "$as_me:5196: \"$ac_compile\"") >&5
5197 (eval $ac_compile) 2>&5
5199 echo "$as_me:5199: \$? = $ac_status" >&5
5200 (exit $ac_status); } &&
5201 { ac_try='test -s conftest.$ac_objext'
5202 { (eval echo "$as_me:5202: \"$ac_try\"") >&5
5205 echo "$as_me:5205: \$? = $ac_status" >&5
5206 (exit $ac_status); }; }; then
5207 cf_cv_define_sigwinch=yes
5209 echo "$as_me: failed program was:" >&5
5210 cat conftest.$ac_ext >&5
5211 cat >conftest.$ac_ext <<_ACEOF
5212 #line 5212 "configure"
5213 #include "confdefs.h"
5215 #undef _XOPEN_SOURCE
5216 #undef _POSIX_SOURCE
5217 #undef _POSIX_C_SOURCE
5218 #include <sys/types.h>
5219 #include <sys/signal.h>
5229 rm -f conftest.$ac_objext
5230 if { (eval echo "$as_me:5230: \"$ac_compile\"") >&5
5231 (eval $ac_compile) 2>&5
5233 echo "$as_me:5233: \$? = $ac_status" >&5
5234 (exit $ac_status); } &&
5235 { ac_try='test -s conftest.$ac_objext'
5236 { (eval echo "$as_me:5236: \"$ac_try\"") >&5
5239 echo "$as_me:5239: \$? = $ac_status" >&5
5240 (exit $ac_status); }; }; then
5241 cf_cv_define_sigwinch=maybe
5243 echo "$as_me: failed program was:" >&5
5244 cat conftest.$ac_ext >&5
5245 cf_cv_define_sigwinch=no
5247 rm -f conftest.$ac_objext conftest.$ac_ext
5250 rm -f conftest.$ac_objext conftest.$ac_ext
5253 echo "$as_me:5253: result: $cf_cv_define_sigwinch" >&5
5254 echo "${ECHO_T}$cf_cv_define_sigwinch" >&6
5256 if test "$cf_cv_define_sigwinch" = maybe ; then
5257 echo "$as_me:5257: checking for actual SIGWINCH definition" >&5
5258 echo $ECHO_N "checking for actual SIGWINCH definition... $ECHO_C" >&6
5259 if test "${cf_cv_fixup_sigwinch+set}" = set; then
5260 echo $ECHO_N "(cached) $ECHO_C" >&6
5263 cf_cv_fixup_sigwinch=unknown
5265 while test $cf_sigwinch != 1
5267 cat >conftest.$ac_ext <<_ACEOF
5268 #line 5268 "configure"
5269 #include "confdefs.h"
5271 #undef _XOPEN_SOURCE
5272 #undef _POSIX_SOURCE
5273 #undef _POSIX_C_SOURCE
5274 #include <sys/types.h>
5275 #include <sys/signal.h>
5281 #if SIGWINCH != $cf_sigwinch
5289 rm -f conftest.$ac_objext
5290 if { (eval echo "$as_me:5290: \"$ac_compile\"") >&5
5291 (eval $ac_compile) 2>&5
5293 echo "$as_me:5293: \$? = $ac_status" >&5
5294 (exit $ac_status); } &&
5295 { ac_try='test -s conftest.$ac_objext'
5296 { (eval echo "$as_me:5296: \"$ac_try\"") >&5
5299 echo "$as_me:5299: \$? = $ac_status" >&5
5300 (exit $ac_status); }; }; then
5301 cf_cv_fixup_sigwinch=$cf_sigwinch
5304 echo "$as_me: failed program was:" >&5
5305 cat conftest.$ac_ext >&5
5307 rm -f conftest.$ac_objext conftest.$ac_ext
5309 cf_sigwinch=`expr $cf_sigwinch - 1`
5313 echo "$as_me:5313: result: $cf_cv_fixup_sigwinch" >&5
5314 echo "${ECHO_T}$cf_cv_fixup_sigwinch" >&6
5316 if test "$cf_cv_fixup_sigwinch" != unknown ; then
5317 CPPFLAGS="$CPPFLAGS -DSIGWINCH=$cf_cv_fixup_sigwinch"
5321 # Checks for CODESET support.
5323 echo "$as_me:5323: checking for nl_langinfo and CODESET" >&5
5324 echo $ECHO_N "checking for nl_langinfo and CODESET... $ECHO_C" >&6
5325 if test "${am_cv_langinfo_codeset+set}" = set; then
5326 echo $ECHO_N "(cached) $ECHO_C" >&6
5328 cat >conftest.$ac_ext <<_ACEOF
5329 #line 5329 "configure"
5330 #include "confdefs.h"
5331 #include <langinfo.h>
5335 char* cs = nl_langinfo(CODESET);
5340 rm -f conftest.$ac_objext conftest$ac_exeext
5341 if { (eval echo "$as_me:5341: \"$ac_link\"") >&5
5342 (eval $ac_link) 2>&5
5344 echo "$as_me:5344: \$? = $ac_status" >&5
5345 (exit $ac_status); } &&
5346 { ac_try='test -s conftest$ac_exeext'
5347 { (eval echo "$as_me:5347: \"$ac_try\"") >&5
5350 echo "$as_me:5350: \$? = $ac_status" >&5
5351 (exit $ac_status); }; }; then
5352 am_cv_langinfo_codeset=yes
5354 echo "$as_me: failed program was:" >&5
5355 cat conftest.$ac_ext >&5
5356 am_cv_langinfo_codeset=no
5358 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5361 echo "$as_me:5361: result: $am_cv_langinfo_codeset" >&5
5362 echo "${ECHO_T}$am_cv_langinfo_codeset" >&6
5363 if test $am_cv_langinfo_codeset = yes; then
5365 cat >>confdefs.h <<\EOF
5366 #define HAVE_LANGINFO_CODESET 1
5371 echo "$as_me:5371: checking if you want to use pkg-config" >&5
5372 echo $ECHO_N "checking if you want to use pkg-config... $ECHO_C" >&6
5374 # Check whether --with-pkg-config or --without-pkg-config was given.
5375 if test "${with_pkg_config+set}" = set; then
5376 withval="$with_pkg_config"
5377 cf_pkg_config=$withval
5381 echo "$as_me:5381: result: $cf_pkg_config" >&5
5382 echo "${ECHO_T}$cf_pkg_config" >&6
5384 case $cf_pkg_config in
5390 if test -n "$ac_tool_prefix"; then
5391 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
5392 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
5393 echo "$as_me:5393: checking for $ac_word" >&5
5394 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5395 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then
5396 echo $ECHO_N "(cached) $ECHO_C" >&6
5400 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
5403 ac_save_IFS=$IFS; IFS=$ac_path_separator
5405 for ac_dir in $ac_dummy; do
5407 test -z "$ac_dir" && ac_dir=.
5408 if $as_executable_p "$ac_dir/$ac_word"; then
5409 ac_cv_path_PKG_CONFIG="$ac_dir/$ac_word"
5410 echo "$as_me:5410: found $ac_dir/$ac_word" >&5
5418 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
5420 if test -n "$PKG_CONFIG"; then
5421 echo "$as_me:5421: result: $PKG_CONFIG" >&5
5422 echo "${ECHO_T}$PKG_CONFIG" >&6
5424 echo "$as_me:5424: result: no" >&5
5425 echo "${ECHO_T}no" >&6
5429 if test -z "$ac_cv_path_PKG_CONFIG"; then
5430 ac_pt_PKG_CONFIG=$PKG_CONFIG
5431 # Extract the first word of "pkg-config", so it can be a program name with args.
5432 set dummy pkg-config; ac_word=$2
5433 echo "$as_me:5433: checking for $ac_word" >&5
5434 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5435 if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then
5436 echo $ECHO_N "(cached) $ECHO_C" >&6
5438 case $ac_pt_PKG_CONFIG in
5440 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
5443 ac_save_IFS=$IFS; IFS=$ac_path_separator
5445 for ac_dir in $ac_dummy; do
5447 test -z "$ac_dir" && ac_dir=.
5448 if $as_executable_p "$ac_dir/$ac_word"; then
5449 ac_cv_path_ac_pt_PKG_CONFIG="$ac_dir/$ac_word"
5450 echo "$as_me:5450: found $ac_dir/$ac_word" >&5
5455 test -z "$ac_cv_path_ac_pt_PKG_CONFIG" && ac_cv_path_ac_pt_PKG_CONFIG="none"
5459 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
5461 if test -n "$ac_pt_PKG_CONFIG"; then
5462 echo "$as_me:5462: result: $ac_pt_PKG_CONFIG" >&5
5463 echo "${ECHO_T}$ac_pt_PKG_CONFIG" >&6
5465 echo "$as_me:5465: result: no" >&5
5466 echo "${ECHO_T}no" >&6
5469 PKG_CONFIG=$ac_pt_PKG_CONFIG
5471 PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
5480 test -z "$PKG_CONFIG" && PKG_CONFIG=none
5481 if test "$PKG_CONFIG" != none ; then
5483 if test "x$prefix" != xNONE; then
5484 cf_path_syntax="$prefix"
5486 cf_path_syntax="$ac_default_prefix"
5489 case ".$PKG_CONFIG" in
5494 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
5496 (.\${*prefix}*|.\${*dir}*)
5497 eval PKG_CONFIG="$PKG_CONFIG"
5498 case ".$PKG_CONFIG" in
5500 PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
5505 PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
5508 { { echo "$as_me:5508: error: expected a pathname, not \"$PKG_CONFIG\"" >&5
5509 echo "$as_me: error: expected a pathname, not \"$PKG_CONFIG\"" >&2;}
5510 { (exit 1); exit 1; }; }
5514 elif test "x$cf_pkg_config" != xno ; then
5515 { echo "$as_me:5515: WARNING: pkg-config is not installed" >&5
5516 echo "$as_me: WARNING: pkg-config is not installed" >&2;}
5519 echo "$as_me:5519: checking if you want to see long compiling messages" >&5
5520 echo $ECHO_N "checking if you want to see long compiling messages... $ECHO_C" >&6
5522 # Check whether --enable-echo or --disable-echo was given.
5523 if test "${enable_echo+set}" = set; then
5524 enableval="$enable_echo"
5525 test "$enableval" != no && enableval=yes
5526 if test "$enableval" != "yes" ; then
5529 ECHO_LD='@echo linking $@;'
5530 RULE_CC='@echo compiling $<'
5531 SHOW_CC='@echo compiling $@'
5553 echo "$as_me:5553: result: $enableval" >&5
5554 echo "${ECHO_T}$enableval" >&6
5556 echo "$as_me:5556: checking for ncurses wrap-prefix" >&5
5557 echo $ECHO_N "checking for ncurses wrap-prefix... $ECHO_C" >&6
5559 # Check whether --with-ncurses-wrap-prefix or --without-ncurses-wrap-prefix was given.
5560 if test "${with_ncurses_wrap_prefix+set}" = set; then
5561 withval="$with_ncurses_wrap_prefix"
5562 NCURSES_WRAP_PREFIX=$withval
5564 NCURSES_WRAP_PREFIX=_nc_
5566 echo "$as_me:5566: result: $NCURSES_WRAP_PREFIX" >&5
5567 echo "${ECHO_T}$NCURSES_WRAP_PREFIX" >&6
5569 echo "$as_me:5569: checking if you want to check for wide-character functions" >&5
5570 echo $ECHO_N "checking if you want to check for wide-character functions... $ECHO_C" >&6
5572 # Check whether --enable-widec or --disable-widec was given.
5573 if test "${enable_widec+set}" = set; then
5574 enableval="$enable_widec"
5575 test "$enableval" != no && enableval=yes
5576 if test "$enableval" != "yes" ; then
5586 echo "$as_me:5586: result: $cf_enable_widec" >&5
5587 echo "${ECHO_T}$cf_enable_widec" >&6
5589 echo "$as_me:5589: checking for specific curses-directory" >&5
5590 echo $ECHO_N "checking for specific curses-directory... $ECHO_C" >&6
5592 # Check whether --with-curses-dir or --without-curses-dir was given.
5593 if test "${with_curses_dir+set}" = set; then
5594 withval="$with_curses_dir"
5595 cf_cv_curses_dir=$withval
5599 echo "$as_me:5599: result: $cf_cv_curses_dir" >&5
5600 echo "${ECHO_T}$cf_cv_curses_dir" >&6
5602 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
5605 if test "x$prefix" != xNONE; then
5606 cf_path_syntax="$prefix"
5608 cf_path_syntax="$ac_default_prefix"
5616 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
5618 (.\${*prefix}*|.\${*dir}*)
5619 eval withval="$withval"
5622 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
5627 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
5630 { { echo "$as_me:5630: error: expected a pathname, not \"$withval\"" >&5
5631 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
5632 { (exit 1); exit 1; }; }
5636 if test -d "$cf_cv_curses_dir"
5639 if test -n "$cf_cv_curses_dir/include" ; then
5640 for cf_add_incdir in $cf_cv_curses_dir/include
5642 while test $cf_add_incdir != /usr/include
5644 if test -d $cf_add_incdir
5647 if test -n "$CFLAGS$CPPFLAGS" ; then
5648 # a loop is needed to ensure we can add subdirs of existing dirs
5649 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
5650 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
5651 cf_have_incdir=yes; break
5656 if test "$cf_have_incdir" = no ; then
5657 if test "$cf_add_incdir" = /usr/local/include ; then
5658 if test "$GCC" = yes
5660 cf_save_CPPFLAGS=$CPPFLAGS
5662 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5663 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
5665 cat >conftest.$ac_ext <<_ACEOF
5666 #line 5666 "configure"
5667 #include "confdefs.h"
5677 rm -f conftest.$ac_objext
5678 if { (eval echo "$as_me:5678: \"$ac_compile\"") >&5
5679 (eval $ac_compile) 2>&5
5681 echo "$as_me:5681: \$? = $ac_status" >&5
5682 (exit $ac_status); } &&
5683 { ac_try='test -s conftest.$ac_objext'
5684 { (eval echo "$as_me:5684: \"$ac_try\"") >&5
5687 echo "$as_me:5687: \$? = $ac_status" >&5
5688 (exit $ac_status); }; }; then
5691 echo "$as_me: failed program was:" >&5
5692 cat conftest.$ac_ext >&5
5695 rm -f conftest.$ac_objext conftest.$ac_ext
5696 CPPFLAGS=$cf_save_CPPFLAGS
5701 if test "$cf_have_incdir" = no ; then
5702 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
5704 echo "${as_me:-configure}:5704: testing adding $cf_add_incdir to include-path ..." 1>&5
5706 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
5708 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
5709 test "$cf_top_incdir" = "$cf_add_incdir" && break
5710 cf_add_incdir="$cf_top_incdir"
5721 if test -n "$cf_cv_curses_dir/lib" ; then
5722 for cf_add_libdir in $cf_cv_curses_dir/lib
5724 if test $cf_add_libdir = /usr/lib ; then
5726 elif test -d $cf_add_libdir
5729 if test -n "$LDFLAGS$LIBS" ; then
5730 # a loop is needed to ensure we can add subdirs of existing dirs
5731 for cf_test_libdir in $LDFLAGS $LIBS ; do
5732 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
5733 cf_have_libdir=yes; break
5737 if test "$cf_have_libdir" = no ; then
5738 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
5740 echo "${as_me:-configure}:5740: testing adding $cf_add_libdir to library-path ..." 1>&5
5742 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
5753 echo "$as_me:5753: checking for specified curses library type" >&5
5754 echo $ECHO_N "checking for specified curses library type... $ECHO_C" >&6
5756 # Check whether --with-screen or --without-screen was given.
5757 if test "${with_screen+set}" = set; then
5758 withval="$with_screen"
5759 cf_cv_screen=$withval
5762 # Check whether --with-ncursesw or --without-ncursesw was given.
5763 if test "${with_ncursesw+set}" = set; then
5764 withval="$with_ncursesw"
5765 cf_cv_screen=ncursesw
5768 # Check whether --with-ncurses or --without-ncurses was given.
5769 if test "${with_ncurses+set}" = set; then
5770 withval="$with_ncurses"
5771 cf_cv_screen=ncurses
5774 # Check whether --with-pdcurses or --without-pdcurses was given.
5775 if test "${with_pdcurses+set}" = set; then
5776 withval="$with_pdcurses"
5777 cf_cv_screen=pdcurses
5780 # Check whether --with-curses-colr or --without-curses-colr was given.
5781 if test "${with_curses_colr+set}" = set; then
5782 withval="$with_curses_colr"
5783 cf_cv_screen=curses_colr
5786 # Check whether --with-curses-5lib or --without-curses-5lib was given.
5787 if test "${with_curses_5lib+set}" = set; then
5788 withval="$with_curses_5lib"
5789 cf_cv_screen=curses_5lib
5797 echo "$as_me:5797: result: $cf_cv_screen" >&5
5798 echo "${ECHO_T}$cf_cv_screen" >&6
5800 case $cf_cv_screen in
5803 echo "$as_me:5803: checking for extra include directories" >&5
5804 echo $ECHO_N "checking for extra include directories... $ECHO_C" >&6
5805 if test "${cf_cv_curses_incdir+set}" = set; then
5806 echo $ECHO_N "(cached) $ECHO_C" >&6
5809 cf_cv_curses_incdir=no
5812 if test "x$cf_cv_screen" = "xcurses_colr"
5814 test -d /usr/include/curses_colr && \
5815 cf_cv_curses_incdir="-I/usr/include/curses_colr"
5819 if test "x$cf_cv_screen" = "xcurses_5lib"
5821 test -d /usr/5lib && \
5822 test -d /usr/5include && \
5823 cf_cv_curses_incdir="-I/usr/5include"
5829 echo "$as_me:5829: result: $cf_cv_curses_incdir" >&5
5830 echo "${ECHO_T}$cf_cv_curses_incdir" >&6
5831 if test "$cf_cv_curses_incdir" != no
5834 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5835 CPPFLAGS="${CPPFLAGS}$cf_cv_curses_incdir"
5839 echo "$as_me:5839: checking if we have identified curses headers" >&5
5840 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
5841 if test "${cf_cv_ncurses_header+set}" = set; then
5842 echo $ECHO_N "(cached) $ECHO_C" >&6
5845 cf_cv_ncurses_header=none
5848 curses.h ncurses/ncurses.h ncurses/curses.h
5850 cat >conftest.$ac_ext <<_ACEOF
5851 #line 5851 "configure"
5852 #include "confdefs.h"
5853 #include <${cf_header}>
5857 initscr(); tgoto("?", 0,0)
5862 rm -f conftest.$ac_objext
5863 if { (eval echo "$as_me:5863: \"$ac_compile\"") >&5
5864 (eval $ac_compile) 2>&5
5866 echo "$as_me:5866: \$? = $ac_status" >&5
5867 (exit $ac_status); } &&
5868 { ac_try='test -s conftest.$ac_objext'
5869 { (eval echo "$as_me:5869: \"$ac_try\"") >&5
5872 echo "$as_me:5872: \$? = $ac_status" >&5
5873 (exit $ac_status); }; }; then
5874 cf_cv_ncurses_header=$cf_header; break
5876 echo "$as_me: failed program was:" >&5
5877 cat conftest.$ac_ext >&5
5879 rm -f conftest.$ac_objext conftest.$ac_ext
5883 echo "$as_me:5883: result: $cf_cv_ncurses_header" >&5
5884 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
5886 if test "$cf_cv_ncurses_header" = none ; then
5887 { { echo "$as_me:5887: error: No curses header-files found" >&5
5888 echo "$as_me: error: No curses header-files found" >&2;}
5889 { (exit 1); exit 1; }; }
5892 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
5894 for ac_header in $cf_cv_ncurses_header
5896 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
5897 echo "$as_me:5897: checking for $ac_header" >&5
5898 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5899 if eval "test \"\${$as_ac_Header+set}\" = set"; then
5900 echo $ECHO_N "(cached) $ECHO_C" >&6
5902 cat >conftest.$ac_ext <<_ACEOF
5903 #line 5903 "configure"
5904 #include "confdefs.h"
5905 #include <$ac_header>
5907 if { (eval echo "$as_me:5907: \"$ac_cpp conftest.$ac_ext\"") >&5
5908 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
5910 egrep -v '^ *\+' conftest.er1 >conftest.err
5912 cat conftest.err >&5
5913 echo "$as_me:5913: \$? = $ac_status" >&5
5914 (exit $ac_status); } >/dev/null; then
5915 if test -s conftest.err; then
5916 ac_cpp_err=$ac_c_preproc_warn_flag
5923 if test -z "$ac_cpp_err"; then
5924 eval "$as_ac_Header=yes"
5926 echo "$as_me: failed program was:" >&5
5927 cat conftest.$ac_ext >&5
5928 eval "$as_ac_Header=no"
5930 rm -f conftest.err conftest.$ac_ext
5932 echo "$as_me:5932: result: `eval echo '${'$as_ac_Header'}'`" >&5
5933 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
5934 if test `eval echo '${'$as_ac_Header'}'` = yes; then
5935 cat >>confdefs.h <<EOF
5936 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
5942 echo "$as_me:5942: checking for terminfo header" >&5
5943 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
5944 if test "${cf_cv_term_header+set}" = set; then
5945 echo $ECHO_N "(cached) $ECHO_C" >&6
5948 case ${cf_cv_ncurses_header} in
5949 (*/ncurses.h|*/ncursesw.h)
5950 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
5953 cf_term_header=term.h
5957 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
5959 cat >conftest.$ac_ext <<_ACEOF
5960 #line 5960 "configure"
5961 #include "confdefs.h"
5963 #include <${cf_cv_ncurses_header:-curses.h}>
5969 int x = auto_left_margin
5974 rm -f conftest.$ac_objext
5975 if { (eval echo "$as_me:5975: \"$ac_compile\"") >&5
5976 (eval $ac_compile) 2>&5
5978 echo "$as_me:5978: \$? = $ac_status" >&5
5979 (exit $ac_status); } &&
5980 { ac_try='test -s conftest.$ac_objext'
5981 { (eval echo "$as_me:5981: \"$ac_try\"") >&5
5984 echo "$as_me:5984: \$? = $ac_status" >&5
5985 (exit $ac_status); }; }; then
5987 cf_cv_term_header="$cf_test"
5989 echo "$as_me: failed program was:" >&5
5990 cat conftest.$ac_ext >&5
5992 cf_cv_term_header=unknown
5995 rm -f conftest.$ac_objext conftest.$ac_ext
5996 test "$cf_cv_term_header" != unknown && break
6000 echo "$as_me:6000: result: $cf_cv_term_header" >&5
6001 echo "${ECHO_T}$cf_cv_term_header" >&6
6003 # Set definitions to allow ifdef'ing to accommodate subdirectories
6005 case $cf_cv_term_header in
6008 cat >>confdefs.h <<\EOF
6009 #define HAVE_TERM_H 1
6015 case $cf_cv_term_header in
6018 cat >>confdefs.h <<\EOF
6019 #define HAVE_NCURSES_TERM_H 1
6025 cat >>confdefs.h <<\EOF
6026 #define HAVE_NCURSESW_TERM_H 1
6032 echo "$as_me:6032: checking for ncurses version" >&5
6033 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
6034 if test "${cf_cv_ncurses_version+set}" = set; then
6035 echo $ECHO_N "(cached) $ECHO_C" >&6
6038 cf_cv_ncurses_version=no
6041 if test "$cross_compiling" = yes; then
6043 # This will not work if the preprocessor splits the line after the
6044 # Autoconf token. The 'unproto' program does that.
6045 cat > conftest.$ac_ext <<EOF
6046 #include <${cf_cv_ncurses_header:-curses.h}>
6048 #ifdef NCURSES_VERSION
6049 Autoconf NCURSES_VERSION
6057 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
6058 { (eval echo "$as_me:6058: \"$cf_try\"") >&5
6061 echo "$as_me:6061: \$? = $ac_status" >&5
6062 (exit $ac_status); }
6063 if test -f conftest.out ; then
6064 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
6065 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
6070 cat >conftest.$ac_ext <<_ACEOF
6071 #line 6071 "configure"
6072 #include "confdefs.h"
6074 #include <${cf_cv_ncurses_header:-curses.h}>
6078 FILE *fp = fopen("$cf_tempfile", "w");
6079 #ifdef NCURSES_VERSION
6080 # ifdef NCURSES_VERSION_PATCH
6081 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
6083 fprintf(fp, "%s\n", NCURSES_VERSION);
6087 fprintf(fp, "old\n");
6092 ${cf_cv_main_return:-return}(0);
6095 rm -f conftest$ac_exeext
6096 if { (eval echo "$as_me:6096: \"$ac_link\"") >&5
6097 (eval $ac_link) 2>&5
6099 echo "$as_me:6099: \$? = $ac_status" >&5
6100 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
6101 { (eval echo "$as_me:6101: \"$ac_try\"") >&5
6104 echo "$as_me:6104: \$? = $ac_status" >&5
6105 (exit $ac_status); }; }; then
6107 cf_cv_ncurses_version=`cat $cf_tempfile`
6109 echo "$as_me: program exited with status $ac_status" >&5
6110 echo "$as_me: failed program was:" >&5
6111 cat conftest.$ac_ext >&5
6113 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6118 echo "$as_me:6118: result: $cf_cv_ncurses_version" >&5
6119 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
6120 test "$cf_cv_ncurses_version" = no ||
6121 cat >>confdefs.h <<\EOF
6125 echo "$as_me:6125: checking if we have identified curses libraries" >&5
6126 echo $ECHO_N "checking if we have identified curses libraries... $ECHO_C" >&6
6127 cat >conftest.$ac_ext <<_ACEOF
6128 #line 6128 "configure"
6129 #include "confdefs.h"
6130 #include <${cf_cv_ncurses_header:-curses.h}>
6134 initscr(); tgoto("?", 0,0)
6139 rm -f conftest.$ac_objext conftest$ac_exeext
6140 if { (eval echo "$as_me:6140: \"$ac_link\"") >&5
6141 (eval $ac_link) 2>&5
6143 echo "$as_me:6143: \$? = $ac_status" >&5
6144 (exit $ac_status); } &&
6145 { ac_try='test -s conftest$ac_exeext'
6146 { (eval echo "$as_me:6146: \"$ac_try\"") >&5
6149 echo "$as_me:6149: \$? = $ac_status" >&5
6150 (exit $ac_status); }; }; then
6153 echo "$as_me: failed program was:" >&5
6154 cat conftest.$ac_ext >&5
6157 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6158 echo "$as_me:6158: result: $cf_result" >&5
6159 echo "${ECHO_T}$cf_result" >&6
6161 if test "$cf_result" = no ; then
6164 echo "$as_me:6164: checking for tgoto in -lmytinfo" >&5
6165 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
6166 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
6167 echo $ECHO_N "(cached) $ECHO_C" >&6
6169 ac_check_lib_save_LIBS=$LIBS
6170 LIBS="-lmytinfo $LIBS"
6171 cat >conftest.$ac_ext <<_ACEOF
6172 #line 6172 "configure"
6173 #include "confdefs.h"
6175 /* Override any gcc2 internal prototype to avoid an error. */
6179 /* We use char because int might match the return type of a gcc2
6180 builtin and then its argument prototype would still apply. */
6190 rm -f conftest.$ac_objext conftest$ac_exeext
6191 if { (eval echo "$as_me:6191: \"$ac_link\"") >&5
6192 (eval $ac_link) 2>&5
6194 echo "$as_me:6194: \$? = $ac_status" >&5
6195 (exit $ac_status); } &&
6196 { ac_try='test -s conftest$ac_exeext'
6197 { (eval echo "$as_me:6197: \"$ac_try\"") >&5
6200 echo "$as_me:6200: \$? = $ac_status" >&5
6201 (exit $ac_status); }; }; then
6202 ac_cv_lib_mytinfo_tgoto=yes
6204 echo "$as_me: failed program was:" >&5
6205 cat conftest.$ac_ext >&5
6206 ac_cv_lib_mytinfo_tgoto=no
6208 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6209 LIBS=$ac_check_lib_save_LIBS
6211 echo "$as_me:6211: result: $ac_cv_lib_mytinfo_tgoto" >&5
6212 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
6213 if test $ac_cv_lib_mytinfo_tgoto = yes; then
6215 cf_add_libs="-lmytinfo"
6216 # Filter out duplicates - this happens with badly-designed ".pc" files...
6217 for cf_add_1lib in $LIBS
6219 for cf_add_2lib in $cf_add_libs
6221 if test "x$cf_add_1lib" = "x$cf_add_2lib"
6227 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
6235 # Looking at HPUX 10.20, the Hcurses library is the oldest (1997), cur_colr
6236 # next (1998), and xcurses "newer" (2000). There is no header file for
6237 # Hcurses; the subdirectory curses_colr has the headers (curses.h and
6238 # term.h) for cur_colr
6239 if test "x$cf_cv_screen" = "xcurses_colr"
6241 echo "$as_me:6241: checking for initscr in -lcur_colr" >&5
6242 echo $ECHO_N "checking for initscr in -lcur_colr... $ECHO_C" >&6
6243 if test "${ac_cv_lib_cur_colr_initscr+set}" = set; then
6244 echo $ECHO_N "(cached) $ECHO_C" >&6
6246 ac_check_lib_save_LIBS=$LIBS
6247 LIBS="-lcur_colr $LIBS"
6248 cat >conftest.$ac_ext <<_ACEOF
6249 #line 6249 "configure"
6250 #include "confdefs.h"
6252 /* Override any gcc2 internal prototype to avoid an error. */
6256 /* We use char because int might match the return type of a gcc2
6257 builtin and then its argument prototype would still apply. */
6267 rm -f conftest.$ac_objext conftest$ac_exeext
6268 if { (eval echo "$as_me:6268: \"$ac_link\"") >&5
6269 (eval $ac_link) 2>&5
6271 echo "$as_me:6271: \$? = $ac_status" >&5
6272 (exit $ac_status); } &&
6273 { ac_try='test -s conftest$ac_exeext'
6274 { (eval echo "$as_me:6274: \"$ac_try\"") >&5
6277 echo "$as_me:6277: \$? = $ac_status" >&5
6278 (exit $ac_status); }; }; then
6279 ac_cv_lib_cur_colr_initscr=yes
6281 echo "$as_me: failed program was:" >&5
6282 cat conftest.$ac_ext >&5
6283 ac_cv_lib_cur_colr_initscr=no
6285 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6286 LIBS=$ac_check_lib_save_LIBS
6288 echo "$as_me:6288: result: $ac_cv_lib_cur_colr_initscr" >&5
6289 echo "${ECHO_T}$ac_cv_lib_cur_colr_initscr" >&6
6290 if test $ac_cv_lib_cur_colr_initscr = yes; then
6292 cf_add_libs="-lcur_colr"
6293 # Filter out duplicates - this happens with badly-designed ".pc" files...
6294 for cf_add_1lib in $LIBS
6296 for cf_add_2lib in $cf_add_libs
6298 if test "x$cf_add_1lib" = "x$cf_add_2lib"
6304 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
6308 ac_cv_func_initscr=yes
6312 echo "$as_me:6312: checking for initscr in -lHcurses" >&5
6313 echo $ECHO_N "checking for initscr in -lHcurses... $ECHO_C" >&6
6314 if test "${ac_cv_lib_Hcurses_initscr+set}" = set; then
6315 echo $ECHO_N "(cached) $ECHO_C" >&6
6317 ac_check_lib_save_LIBS=$LIBS
6318 LIBS="-lHcurses $LIBS"
6319 cat >conftest.$ac_ext <<_ACEOF
6320 #line 6320 "configure"
6321 #include "confdefs.h"
6323 /* Override any gcc2 internal prototype to avoid an error. */
6327 /* We use char because int might match the return type of a gcc2
6328 builtin and then its argument prototype would still apply. */
6338 rm -f conftest.$ac_objext conftest$ac_exeext
6339 if { (eval echo "$as_me:6339: \"$ac_link\"") >&5
6340 (eval $ac_link) 2>&5
6342 echo "$as_me:6342: \$? = $ac_status" >&5
6343 (exit $ac_status); } &&
6344 { ac_try='test -s conftest$ac_exeext'
6345 { (eval echo "$as_me:6345: \"$ac_try\"") >&5
6348 echo "$as_me:6348: \$? = $ac_status" >&5
6349 (exit $ac_status); }; }; then
6350 ac_cv_lib_Hcurses_initscr=yes
6352 echo "$as_me: failed program was:" >&5
6353 cat conftest.$ac_ext >&5
6354 ac_cv_lib_Hcurses_initscr=no
6356 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6357 LIBS=$ac_check_lib_save_LIBS
6359 echo "$as_me:6359: result: $ac_cv_lib_Hcurses_initscr" >&5
6360 echo "${ECHO_T}$ac_cv_lib_Hcurses_initscr" >&6
6361 if test $ac_cv_lib_Hcurses_initscr = yes; then
6363 # HP's header uses __HP_CURSES, but user claims _HP_CURSES.
6365 cf_add_libs="-lHcurses"
6366 # Filter out duplicates - this happens with badly-designed ".pc" files...
6367 for cf_add_1lib in $LIBS
6369 for cf_add_2lib in $cf_add_libs
6371 if test "x$cf_add_1lib" = "x$cf_add_2lib"
6377 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
6381 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
6382 CPPFLAGS="${CPPFLAGS}-D__HP_CURSES -D_HP_CURSES"
6384 ac_cv_func_initscr=yes
6393 case `arch 2>/dev/null` in
6398 if test -n "/lib64" ; then
6399 for cf_add_libdir in /lib64
6401 if test $cf_add_libdir = /usr/lib ; then
6403 elif test -d $cf_add_libdir
6406 if test -n "$LDFLAGS$LIBS" ; then
6407 # a loop is needed to ensure we can add subdirs of existing dirs
6408 for cf_test_libdir in $LDFLAGS $LIBS ; do
6409 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
6410 cf_have_libdir=yes; break
6414 if test "$cf_have_libdir" = no ; then
6415 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
6417 echo "${as_me:-configure}:6417: testing adding $cf_add_libdir to library-path ..." 1>&5
6419 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
6427 if test -n "/lib" ; then
6428 for cf_add_libdir in /lib
6430 if test $cf_add_libdir = /usr/lib ; then
6432 elif test -d $cf_add_libdir
6435 if test -n "$LDFLAGS$LIBS" ; then
6436 # a loop is needed to ensure we can add subdirs of existing dirs
6437 for cf_test_libdir in $LDFLAGS $LIBS ; do
6438 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
6439 cf_have_libdir=yes; break
6443 if test "$cf_have_libdir" = no ; then
6444 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
6446 echo "${as_me:-configure}:6446: testing adding $cf_add_libdir to library-path ..." 1>&5
6448 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
6458 if test -n "/lib" ; then
6459 for cf_add_libdir in /lib
6461 if test $cf_add_libdir = /usr/lib ; then
6463 elif test -d $cf_add_libdir
6466 if test -n "$LDFLAGS$LIBS" ; then
6467 # a loop is needed to ensure we can add subdirs of existing dirs
6468 for cf_test_libdir in $LDFLAGS $LIBS ; do
6469 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
6470 cf_have_libdir=yes; break
6474 if test "$cf_have_libdir" = no ; then
6475 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
6477 echo "${as_me:-configure}:6477: testing adding $cf_add_libdir to library-path ..." 1>&5
6479 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
6489 if test "x$cf_cv_screen" = "xcurses_5lib"
6491 if test -d /usr/5lib ; then
6493 if test -n "/usr/5lib" ; then
6494 for cf_add_libdir in /usr/5lib
6496 if test $cf_add_libdir = /usr/lib ; then
6498 elif test -d $cf_add_libdir
6501 if test -n "$LDFLAGS$LIBS" ; then
6502 # a loop is needed to ensure we can add subdirs of existing dirs
6503 for cf_test_libdir in $LDFLAGS $LIBS ; do
6504 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
6505 cf_have_libdir=yes; break
6509 if test "$cf_have_libdir" = no ; then
6510 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
6512 echo "${as_me:-configure}:6512: testing adding $cf_add_libdir to library-path ..." 1>&5
6514 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
6520 cf_add_libs="-lcurses -ltermcap"
6521 # Filter out duplicates - this happens with badly-designed ".pc" files...
6522 for cf_add_1lib in $LIBS
6524 for cf_add_2lib in $cf_add_libs
6526 if test "x$cf_add_1lib" = "x$cf_add_2lib"
6532 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
6538 ac_cv_func_initscr=yes
6542 if test ".$ac_cv_func_initscr" != .yes ; then
6543 cf_save_LIBS="$LIBS"
6545 if test ".${cf_cv_ncurses_version:-no}" != .no
6547 cf_check_list="ncurses curses cursesX"
6549 cf_check_list="cursesX curses ncurses"
6552 # Check for library containing tgoto. Do this before curses library
6553 # because it may be needed to link the test-case for initscr.
6554 if test "x$cf_term_lib" = x
6556 echo "$as_me:6556: checking for tgoto" >&5
6557 echo $ECHO_N "checking for tgoto... $ECHO_C" >&6
6558 if test "${ac_cv_func_tgoto+set}" = set; then
6559 echo $ECHO_N "(cached) $ECHO_C" >&6
6561 cat >conftest.$ac_ext <<_ACEOF
6562 #line 6562 "configure"
6563 #include "confdefs.h"
6564 #define tgoto autoconf_temporary
6565 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
6572 /* We use char because int might match the return type of a gcc2
6573 builtin and then its argument prototype would still apply. */
6580 /* The GNU C library defines stubs for functions which it implements
6581 to always fail with ENOSYS. Some functions are actually named
6582 something starting with __ and the normal name is an alias. */
6583 #if defined (__stub_tgoto) || defined (__stub___tgoto)
6584 #error found stub for tgoto
6592 rm -f conftest.$ac_objext conftest$ac_exeext
6593 if { (eval echo "$as_me:6593: \"$ac_link\"") >&5
6594 (eval $ac_link) 2>&5
6596 echo "$as_me:6596: \$? = $ac_status" >&5
6597 (exit $ac_status); } &&
6598 { ac_try='test -s conftest$ac_exeext'
6599 { (eval echo "$as_me:6599: \"$ac_try\"") >&5
6602 echo "$as_me:6602: \$? = $ac_status" >&5
6603 (exit $ac_status); }; }; then
6604 ac_cv_func_tgoto=yes
6606 echo "$as_me: failed program was:" >&5
6607 cat conftest.$ac_ext >&5
6610 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6612 echo "$as_me:6612: result: $ac_cv_func_tgoto" >&5
6613 echo "${ECHO_T}$ac_cv_func_tgoto" >&6
6614 if test $ac_cv_func_tgoto = yes; then
6615 cf_term_lib=predefined
6618 for cf_term_lib in $cf_check_list otermcap termcap tinfo termlib unknown
6620 as_ac_Lib=`echo "ac_cv_lib_$cf_term_lib''_tgoto" | $as_tr_sh`
6621 echo "$as_me:6621: checking for tgoto in -l$cf_term_lib" >&5
6622 echo $ECHO_N "checking for tgoto in -l$cf_term_lib... $ECHO_C" >&6
6623 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
6624 echo $ECHO_N "(cached) $ECHO_C" >&6
6626 ac_check_lib_save_LIBS=$LIBS
6627 LIBS="-l$cf_term_lib $LIBS"
6628 cat >conftest.$ac_ext <<_ACEOF
6629 #line 6629 "configure"
6630 #include "confdefs.h"
6632 /* Override any gcc2 internal prototype to avoid an error. */
6636 /* We use char because int might match the return type of a gcc2
6637 builtin and then its argument prototype would still apply. */
6647 rm -f conftest.$ac_objext conftest$ac_exeext
6648 if { (eval echo "$as_me:6648: \"$ac_link\"") >&5
6649 (eval $ac_link) 2>&5
6651 echo "$as_me:6651: \$? = $ac_status" >&5
6652 (exit $ac_status); } &&
6653 { ac_try='test -s conftest$ac_exeext'
6654 { (eval echo "$as_me:6654: \"$ac_try\"") >&5
6657 echo "$as_me:6657: \$? = $ac_status" >&5
6658 (exit $ac_status); }; }; then
6659 eval "$as_ac_Lib=yes"
6661 echo "$as_me: failed program was:" >&5
6662 cat conftest.$ac_ext >&5
6663 eval "$as_ac_Lib=no"
6665 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6666 LIBS=$ac_check_lib_save_LIBS
6668 echo "$as_me:6668: result: `eval echo '${'$as_ac_Lib'}'`" >&5
6669 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
6670 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
6672 : ${cf_nculib_root:=$cf_term_lib}
6683 # Check for library containing initscr
6684 test "$cf_term_lib" != predefined && test "$cf_term_lib" != unknown && LIBS="-l$cf_term_lib $cf_save_LIBS"
6685 if test "x$cf_curs_lib" = x
6687 for cf_curs_lib in $cf_check_list xcurses jcurses pdcurses unknown
6689 LIBS="-l$cf_curs_lib $cf_save_LIBS"
6690 if test "$cf_term_lib" = unknown || test "$cf_term_lib" = "$cf_curs_lib" ; then
6691 echo "$as_me:6691: checking if we can link with $cf_curs_lib library" >&5
6692 echo $ECHO_N "checking if we can link with $cf_curs_lib library... $ECHO_C" >&6
6693 cat >conftest.$ac_ext <<_ACEOF
6694 #line 6694 "configure"
6695 #include "confdefs.h"
6696 #include <${cf_cv_ncurses_header:-curses.h}>
6705 rm -f conftest.$ac_objext conftest$ac_exeext
6706 if { (eval echo "$as_me:6706: \"$ac_link\"") >&5
6707 (eval $ac_link) 2>&5
6709 echo "$as_me:6709: \$? = $ac_status" >&5
6710 (exit $ac_status); } &&
6711 { ac_try='test -s conftest$ac_exeext'
6712 { (eval echo "$as_me:6712: \"$ac_try\"") >&5
6715 echo "$as_me:6715: \$? = $ac_status" >&5
6716 (exit $ac_status); }; }; then
6719 echo "$as_me: failed program was:" >&5
6720 cat conftest.$ac_ext >&5
6723 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6724 echo "$as_me:6724: result: $cf_result" >&5
6725 echo "${ECHO_T}$cf_result" >&6
6726 test $cf_result = yes && break
6727 elif test "$cf_curs_lib" = "$cf_term_lib" ; then
6729 elif test "$cf_term_lib" != predefined ; then
6730 echo "$as_me:6730: checking if we need both $cf_curs_lib and $cf_term_lib libraries" >&5
6731 echo $ECHO_N "checking if we need both $cf_curs_lib and $cf_term_lib libraries... $ECHO_C" >&6
6732 cat >conftest.$ac_ext <<_ACEOF
6733 #line 6733 "configure"
6734 #include "confdefs.h"
6735 #include <${cf_cv_ncurses_header:-curses.h}>
6739 initscr(); tgoto((char *)0, 0, 0);
6744 rm -f conftest.$ac_objext conftest$ac_exeext
6745 if { (eval echo "$as_me:6745: \"$ac_link\"") >&5
6746 (eval $ac_link) 2>&5
6748 echo "$as_me:6748: \$? = $ac_status" >&5
6749 (exit $ac_status); } &&
6750 { ac_try='test -s conftest$ac_exeext'
6751 { (eval echo "$as_me:6751: \"$ac_try\"") >&5
6754 echo "$as_me:6754: \$? = $ac_status" >&5
6755 (exit $ac_status); }; }; then
6758 echo "$as_me: failed program was:" >&5
6759 cat conftest.$ac_ext >&5
6761 LIBS="-l$cf_curs_lib -l$cf_term_lib $cf_save_LIBS"
6762 cat >conftest.$ac_ext <<_ACEOF
6763 #line 6763 "configure"
6764 #include "confdefs.h"
6765 #include <${cf_cv_ncurses_header:-curses.h}>
6774 rm -f conftest.$ac_objext conftest$ac_exeext
6775 if { (eval echo "$as_me:6775: \"$ac_link\"") >&5
6776 (eval $ac_link) 2>&5
6778 echo "$as_me:6778: \$? = $ac_status" >&5
6779 (exit $ac_status); } &&
6780 { ac_try='test -s conftest$ac_exeext'
6781 { (eval echo "$as_me:6781: \"$ac_try\"") >&5
6784 echo "$as_me:6784: \$? = $ac_status" >&5
6785 (exit $ac_status); }; }; then
6788 echo "$as_me: failed program was:" >&5
6789 cat conftest.$ac_ext >&5
6792 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6795 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6796 echo "$as_me:6796: result: $cf_result" >&5
6797 echo "${ECHO_T}$cf_result" >&6
6798 test $cf_result != error && break
6802 test $cf_curs_lib = unknown && { { echo "$as_me:6802: error: no curses library found" >&5
6803 echo "$as_me: error: no curses library found" >&2;}
6804 { (exit 1); exit 1; }; }
6811 echo "$as_me:6811: checking for multibyte character support" >&5
6812 echo $ECHO_N "checking for multibyte character support... $ECHO_C" >&6
6813 if test "${cf_cv_utf8_lib+set}" = set; then
6814 echo $ECHO_N "(cached) $ECHO_C" >&6
6817 cf_save_LIBS="$LIBS"
6818 cat >conftest.$ac_ext <<_ACEOF
6819 #line 6819 "configure"
6820 #include "confdefs.h"
6831 rm -f conftest.$ac_objext conftest$ac_exeext
6832 if { (eval echo "$as_me:6832: \"$ac_link\"") >&5
6833 (eval $ac_link) 2>&5
6835 echo "$as_me:6835: \$? = $ac_status" >&5
6836 (exit $ac_status); } &&
6837 { ac_try='test -s conftest$ac_exeext'
6838 { (eval echo "$as_me:6838: \"$ac_try\"") >&5
6841 echo "$as_me:6841: \$? = $ac_status" >&5
6842 (exit $ac_status); }; }; then
6845 echo "$as_me: failed program was:" >&5
6846 cat conftest.$ac_ext >&5
6848 # If the linkage is not already in the $CPPFLAGS/$LDFLAGS configuration, these
6849 # will be set on completion of the AC_TRY_LINK below.
6850 cf_cv_header_path_utf8=
6851 cf_cv_library_path_utf8=
6853 echo "${as_me:-configure}:6853: testing Starting FIND_LINKAGE(utf8,) ..." 1>&5
6855 cf_save_LIBS="$LIBS"
6857 cat >conftest.$ac_ext <<_ACEOF
6858 #line 6858 "configure"
6859 #include "confdefs.h"
6861 #include <libutf8.h>
6870 rm -f conftest.$ac_objext conftest$ac_exeext
6871 if { (eval echo "$as_me:6871: \"$ac_link\"") >&5
6872 (eval $ac_link) 2>&5
6874 echo "$as_me:6874: \$? = $ac_status" >&5
6875 (exit $ac_status); } &&
6876 { ac_try='test -s conftest$ac_exeext'
6877 { (eval echo "$as_me:6877: \"$ac_try\"") >&5
6880 echo "$as_me:6880: \$? = $ac_status" >&5
6881 (exit $ac_status); }; }; then
6883 cf_cv_find_linkage_utf8=yes
6884 cf_cv_header_path_utf8=/usr/include
6885 cf_cv_library_path_utf8=/usr/lib
6888 echo "$as_me: failed program was:" >&5
6889 cat conftest.$ac_ext >&5
6891 LIBS="-lutf8 $cf_save_LIBS"
6893 cat >conftest.$ac_ext <<_ACEOF
6894 #line 6894 "configure"
6895 #include "confdefs.h"
6897 #include <libutf8.h>
6906 rm -f conftest.$ac_objext conftest$ac_exeext
6907 if { (eval echo "$as_me:6907: \"$ac_link\"") >&5
6908 (eval $ac_link) 2>&5
6910 echo "$as_me:6910: \$? = $ac_status" >&5
6911 (exit $ac_status); } &&
6912 { ac_try='test -s conftest$ac_exeext'
6913 { (eval echo "$as_me:6913: \"$ac_try\"") >&5
6916 echo "$as_me:6916: \$? = $ac_status" >&5
6917 (exit $ac_status); }; }; then
6919 cf_cv_find_linkage_utf8=yes
6920 cf_cv_header_path_utf8=/usr/include
6921 cf_cv_library_path_utf8=/usr/lib
6922 cf_cv_library_file_utf8="-lutf8"
6925 echo "$as_me: failed program was:" >&5
6926 cat conftest.$ac_ext >&5
6928 cf_cv_find_linkage_utf8=no
6929 LIBS="$cf_save_LIBS"
6931 test -n "$verbose" && echo " find linkage for utf8 library" 1>&6
6933 echo "${as_me:-configure}:6933: testing find linkage for utf8 library ..." 1>&5
6935 echo "${as_me:-configure}:6935: testing Searching for headers in FIND_LINKAGE(utf8,) ..." 1>&5
6937 cf_save_CPPFLAGS="$CPPFLAGS"
6938 cf_test_CPPFLAGS="$CPPFLAGS"
6942 # collect the current set of include-directories from compiler flags
6943 cf_header_path_list=""
6944 if test -n "${CFLAGS}${CPPFLAGS}" ; then
6945 for cf_header_path in $CPPFLAGS $CFLAGS
6947 case $cf_header_path in
6949 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
6951 test "x$cf_header_path" != "xNONE" && \
6952 test -d "$cf_header_path" && \
6954 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
6955 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
6956 test -d $cf_header_path/include/utf8 && cf_search="$cf_search $cf_header_path/include/utf8"
6957 test -d $cf_header_path/include/utf8/include && cf_search="$cf_search $cf_header_path/include/utf8/include"
6958 test -d $cf_header_path/utf8/include && cf_search="$cf_search $cf_header_path/utf8/include"
6959 test -d $cf_header_path/utf8/include/utf8 && cf_search="$cf_search $cf_header_path/utf8/include/utf8"
6962 cf_header_path_list="$cf_header_path_list $cf_search"
6968 # add the variations for the package we are looking for
6972 test "x$prefix" != "xNONE" && \
6973 test -d "$prefix" && \
6975 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
6976 test -d $prefix/include && cf_search="$cf_search $prefix/include"
6977 test -d $prefix/include/utf8 && cf_search="$cf_search $prefix/include/utf8"
6978 test -d $prefix/include/utf8/include && cf_search="$cf_search $prefix/include/utf8/include"
6979 test -d $prefix/utf8/include && cf_search="$cf_search $prefix/utf8/include"
6980 test -d $prefix/utf8/include/utf8 && cf_search="$cf_search $prefix/utf8/include/utf8"
6983 for cf_subdir_prefix in \
6992 test "x$cf_subdir_prefix" != "x$prefix" && \
6993 test -d "$cf_subdir_prefix" && \
6994 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
6995 test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
6996 test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include"
6997 test -d $cf_subdir_prefix/include/utf8 && cf_search="$cf_search $cf_subdir_prefix/include/utf8"
6998 test -d $cf_subdir_prefix/include/utf8/include && cf_search="$cf_search $cf_subdir_prefix/include/utf8/include"
6999 test -d $cf_subdir_prefix/utf8/include && cf_search="$cf_search $cf_subdir_prefix/utf8/include"
7000 test -d $cf_subdir_prefix/utf8/include/utf8 && cf_search="$cf_search $cf_subdir_prefix/utf8/include/utf8"
7005 test "$includedir" != NONE && \
7006 test "$includedir" != "/usr/include" && \
7007 test -d "$includedir" && {
7008 test -d $includedir && cf_search="$cf_search $includedir"
7009 test -d $includedir/utf8 && cf_search="$cf_search $includedir/utf8"
7012 test "$oldincludedir" != NONE && \
7013 test "$oldincludedir" != "/usr/include" && \
7014 test -d "$oldincludedir" && {
7015 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
7016 test -d $oldincludedir/utf8 && cf_search="$cf_search $oldincludedir/utf8"
7019 cf_search="$cf_search $cf_header_path_list"
7021 for cf_cv_header_path_utf8 in $cf_search
7023 if test -d $cf_cv_header_path_utf8 ; then
7024 test -n "$verbose" && echo " ... testing $cf_cv_header_path_utf8" 1>&6
7026 echo "${as_me:-configure}:7026: testing ... testing $cf_cv_header_path_utf8 ..." 1>&5
7028 CPPFLAGS="$cf_save_CPPFLAGS"
7030 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
7031 CPPFLAGS="${CPPFLAGS}-I$cf_cv_header_path_utf8"
7033 cat >conftest.$ac_ext <<_ACEOF
7034 #line 7034 "configure"
7035 #include "confdefs.h"
7037 #include <libutf8.h>
7046 rm -f conftest.$ac_objext
7047 if { (eval echo "$as_me:7047: \"$ac_compile\"") >&5
7048 (eval $ac_compile) 2>&5
7050 echo "$as_me:7050: \$? = $ac_status" >&5
7051 (exit $ac_status); } &&
7052 { ac_try='test -s conftest.$ac_objext'
7053 { (eval echo "$as_me:7053: \"$ac_try\"") >&5
7056 echo "$as_me:7056: \$? = $ac_status" >&5
7057 (exit $ac_status); }; }; then
7059 test -n "$verbose" && echo " ... found utf8 headers in $cf_cv_header_path_utf8" 1>&6
7061 echo "${as_me:-configure}:7061: testing ... found utf8 headers in $cf_cv_header_path_utf8 ..." 1>&5
7063 cf_cv_find_linkage_utf8=maybe
7064 cf_test_CPPFLAGS="$CPPFLAGS"
7067 echo "$as_me: failed program was:" >&5
7068 cat conftest.$ac_ext >&5
7070 CPPFLAGS="$cf_save_CPPFLAGS"
7073 rm -f conftest.$ac_objext conftest.$ac_ext
7077 if test "$cf_cv_find_linkage_utf8" = maybe ; then
7079 echo "${as_me:-configure}:7079: testing Searching for utf8 library in FIND_LINKAGE(utf8,) ..." 1>&5
7081 cf_save_LIBS="$LIBS"
7082 cf_save_LDFLAGS="$LDFLAGS"
7084 if test "$cf_cv_find_linkage_utf8" != yes ; then
7087 cf_library_path_list=""
7088 if test -n "${LDFLAGS}${LIBS}" ; then
7089 for cf_library_path in $LDFLAGS $LIBS
7091 case $cf_library_path in
7093 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
7095 test "x$cf_library_path" != "xNONE" && \
7096 test -d "$cf_library_path" && \
7098 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
7099 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
7100 test -d $cf_library_path/lib/utf8 && cf_search="$cf_search $cf_library_path/lib/utf8"
7101 test -d $cf_library_path/lib/utf8/lib && cf_search="$cf_search $cf_library_path/lib/utf8/lib"
7102 test -d $cf_library_path/utf8/lib && cf_search="$cf_search $cf_library_path/utf8/lib"
7103 test -d $cf_library_path/utf8/lib/utf8 && cf_search="$cf_search $cf_library_path/utf8/lib/utf8"
7106 cf_library_path_list="$cf_library_path_list $cf_search"
7114 test "x$prefix" != "xNONE" && \
7115 test -d "$prefix" && \
7117 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
7118 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
7119 test -d $prefix/lib/utf8 && cf_search="$cf_search $prefix/lib/utf8"
7120 test -d $prefix/lib/utf8/lib && cf_search="$cf_search $prefix/lib/utf8/lib"
7121 test -d $prefix/utf8/lib && cf_search="$cf_search $prefix/utf8/lib"
7122 test -d $prefix/utf8/lib/utf8 && cf_search="$cf_search $prefix/utf8/lib/utf8"
7125 for cf_subdir_prefix in \
7134 test "x$cf_subdir_prefix" != "x$prefix" && \
7135 test -d "$cf_subdir_prefix" && \
7136 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
7137 test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
7138 test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib"
7139 test -d $cf_subdir_prefix/lib/utf8 && cf_search="$cf_search $cf_subdir_prefix/lib/utf8"
7140 test -d $cf_subdir_prefix/lib/utf8/lib && cf_search="$cf_search $cf_subdir_prefix/lib/utf8/lib"
7141 test -d $cf_subdir_prefix/utf8/lib && cf_search="$cf_search $cf_subdir_prefix/utf8/lib"
7142 test -d $cf_subdir_prefix/utf8/lib/utf8 && cf_search="$cf_search $cf_subdir_prefix/utf8/lib/utf8"
7147 cf_search="$cf_library_path_list $cf_search"
7149 for cf_cv_library_path_utf8 in $cf_search
7151 if test -d $cf_cv_library_path_utf8 ; then
7152 test -n "$verbose" && echo " ... testing $cf_cv_library_path_utf8" 1>&6
7154 echo "${as_me:-configure}:7154: testing ... testing $cf_cv_library_path_utf8 ..." 1>&5
7156 CPPFLAGS="$cf_test_CPPFLAGS"
7157 LIBS="-lutf8 $cf_save_LIBS"
7158 LDFLAGS="$cf_save_LDFLAGS -L$cf_cv_library_path_utf8"
7159 cat >conftest.$ac_ext <<_ACEOF
7160 #line 7160 "configure"
7161 #include "confdefs.h"
7163 #include <libutf8.h>
7172 rm -f conftest.$ac_objext conftest$ac_exeext
7173 if { (eval echo "$as_me:7173: \"$ac_link\"") >&5
7174 (eval $ac_link) 2>&5
7176 echo "$as_me:7176: \$? = $ac_status" >&5
7177 (exit $ac_status); } &&
7178 { ac_try='test -s conftest$ac_exeext'
7179 { (eval echo "$as_me:7179: \"$ac_try\"") >&5
7182 echo "$as_me:7182: \$? = $ac_status" >&5
7183 (exit $ac_status); }; }; then
7185 test -n "$verbose" && echo " ... found utf8 library in $cf_cv_library_path_utf8" 1>&6
7187 echo "${as_me:-configure}:7187: testing ... found utf8 library in $cf_cv_library_path_utf8 ..." 1>&5
7189 cf_cv_find_linkage_utf8=yes
7190 cf_cv_library_file_utf8="-lutf8"
7193 echo "$as_me: failed program was:" >&5
7194 cat conftest.$ac_ext >&5
7196 CPPFLAGS="$cf_save_CPPFLAGS"
7197 LIBS="$cf_save_LIBS"
7198 LDFLAGS="$cf_save_LDFLAGS"
7201 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7204 CPPFLAGS="$cf_save_CPPFLAGS"
7205 LDFLAGS="$cf_save_LDFLAGS"
7209 cf_cv_find_linkage_utf8=no
7213 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7216 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7218 LIBS="$cf_save_LIBS"
7220 if test "$cf_cv_find_linkage_utf8" = yes ; then
7221 cf_cv_utf8_lib=add-on
7227 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7229 echo "$as_me:7229: result: $cf_cv_utf8_lib" >&5
7230 echo "${ECHO_T}$cf_cv_utf8_lib" >&6
7232 # HAVE_LIBUTF8_H is used by ncurses if curses.h is shared between
7234 if test "$cf_cv_utf8_lib" = "add-on" ; then
7236 cat >>confdefs.h <<\EOF
7237 #define HAVE_LIBUTF8_H 1
7240 if test -n "$cf_cv_header_path_utf8" ; then
7241 for cf_add_incdir in $cf_cv_header_path_utf8
7243 while test $cf_add_incdir != /usr/include
7245 if test -d $cf_add_incdir
7248 if test -n "$CFLAGS$CPPFLAGS" ; then
7249 # a loop is needed to ensure we can add subdirs of existing dirs
7250 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
7251 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
7252 cf_have_incdir=yes; break
7257 if test "$cf_have_incdir" = no ; then
7258 if test "$cf_add_incdir" = /usr/local/include ; then
7259 if test "$GCC" = yes
7261 cf_save_CPPFLAGS=$CPPFLAGS
7263 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
7264 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
7266 cat >conftest.$ac_ext <<_ACEOF
7267 #line 7267 "configure"
7268 #include "confdefs.h"
7278 rm -f conftest.$ac_objext
7279 if { (eval echo "$as_me:7279: \"$ac_compile\"") >&5
7280 (eval $ac_compile) 2>&5
7282 echo "$as_me:7282: \$? = $ac_status" >&5
7283 (exit $ac_status); } &&
7284 { ac_try='test -s conftest.$ac_objext'
7285 { (eval echo "$as_me:7285: \"$ac_try\"") >&5
7288 echo "$as_me:7288: \$? = $ac_status" >&5
7289 (exit $ac_status); }; }; then
7292 echo "$as_me: failed program was:" >&5
7293 cat conftest.$ac_ext >&5
7296 rm -f conftest.$ac_objext conftest.$ac_ext
7297 CPPFLAGS=$cf_save_CPPFLAGS
7302 if test "$cf_have_incdir" = no ; then
7303 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
7305 echo "${as_me:-configure}:7305: testing adding $cf_add_incdir to include-path ..." 1>&5
7307 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7309 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
7310 test "$cf_top_incdir" = "$cf_add_incdir" && break
7311 cf_add_incdir="$cf_top_incdir"
7322 if test -n "$cf_cv_library_path_utf8" ; then
7323 for cf_add_libdir in $cf_cv_library_path_utf8
7325 if test $cf_add_libdir = /usr/lib ; then
7327 elif test -d $cf_add_libdir
7330 if test -n "$LDFLAGS$LIBS" ; then
7331 # a loop is needed to ensure we can add subdirs of existing dirs
7332 for cf_test_libdir in $LDFLAGS $LIBS ; do
7333 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
7334 cf_have_libdir=yes; break
7338 if test "$cf_have_libdir" = no ; then
7339 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
7341 echo "${as_me:-configure}:7341: testing adding $cf_add_libdir to library-path ..." 1>&5
7343 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
7349 cf_add_libs="$cf_cv_library_file_utf8"
7350 # Filter out duplicates - this happens with badly-designed ".pc" files...
7351 for cf_add_1lib in $LIBS
7353 for cf_add_2lib in $cf_add_libs
7355 if test "x$cf_add_1lib" = "x$cf_add_2lib"
7361 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
7367 cf_ncuconfig_root=$cf_cv_screen
7368 cf_have_ncuconfig=no
7370 if test "x${PKG_CONFIG:=none}" != xnone; then
7371 echo "$as_me:7371: checking pkg-config for $cf_ncuconfig_root" >&5
7372 echo $ECHO_N "checking pkg-config for $cf_ncuconfig_root... $ECHO_C" >&6
7373 if "$PKG_CONFIG" --exists $cf_ncuconfig_root ; then
7374 echo "$as_me:7374: result: yes" >&5
7375 echo "${ECHO_T}yes" >&6
7377 echo "$as_me:7377: checking if the $cf_ncuconfig_root package files work" >&5
7378 echo $ECHO_N "checking if the $cf_ncuconfig_root package files work... $ECHO_C" >&6
7379 cf_have_ncuconfig=unknown
7381 cf_save_CPPFLAGS="$CPPFLAGS"
7382 cf_save_LIBS="$LIBS"
7387 cf_new_extra_cppflags=
7389 for cf_add_cflags in `$PKG_CONFIG --cflags $cf_ncuconfig_root`
7391 case $cf_fix_cppflags in
7393 case $cf_add_cflags in
7394 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
7395 case $cf_add_cflags in
7397 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
7399 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
7400 && test -z "${cf_tst_cflags}" \
7401 && cf_fix_cppflags=yes
7403 if test $cf_fix_cppflags = yes ; then
7405 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
7406 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
7409 elif test "${cf_tst_cflags}" = "\"'" ; then
7411 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
7412 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
7422 case $cf_add_cflags in
7424 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
7426 CPPFLAGS=`echo "$CPPFLAGS" | \
7427 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
7428 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
7433 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
7434 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
7441 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
7442 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
7449 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
7450 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
7452 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
7454 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
7455 && test -z "${cf_tst_cflags}" \
7456 && cf_fix_cppflags=no
7461 if test -n "$cf_new_cflags" ; then
7463 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
7464 CFLAGS="${CFLAGS}$cf_new_cflags"
7468 if test -n "$cf_new_cppflags" ; then
7470 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
7471 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
7475 if test -n "$cf_new_extra_cppflags" ; then
7477 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
7478 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
7482 cf_add_libs="`$PKG_CONFIG --libs $cf_ncuconfig_root`"
7483 # Filter out duplicates - this happens with badly-designed ".pc" files...
7484 for cf_add_1lib in $LIBS
7486 for cf_add_2lib in $cf_add_libs
7488 if test "x$cf_add_1lib" = "x$cf_add_2lib"
7494 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
7498 cat >conftest.$ac_ext <<_ACEOF
7499 #line 7499 "configure"
7500 #include "confdefs.h"
7501 #include <${cf_cv_ncurses_header:-curses.h}>
7505 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
7510 rm -f conftest.$ac_objext conftest$ac_exeext
7511 if { (eval echo "$as_me:7511: \"$ac_link\"") >&5
7512 (eval $ac_link) 2>&5
7514 echo "$as_me:7514: \$? = $ac_status" >&5
7515 (exit $ac_status); } &&
7516 { ac_try='test -s conftest$ac_exeext'
7517 { (eval echo "$as_me:7517: \"$ac_try\"") >&5
7520 echo "$as_me:7520: \$? = $ac_status" >&5
7521 (exit $ac_status); }; }; then
7522 if test "$cross_compiling" = yes; then
7523 cf_have_ncuconfig=maybe
7525 cat >conftest.$ac_ext <<_ACEOF
7526 #line 7526 "configure"
7527 #include "confdefs.h"
7528 #include <${cf_cv_ncurses_header:-curses.h}>
7530 { char *xx = curses_version(); return (xx == 0); }
7532 rm -f conftest$ac_exeext
7533 if { (eval echo "$as_me:7533: \"$ac_link\"") >&5
7534 (eval $ac_link) 2>&5
7536 echo "$as_me:7536: \$? = $ac_status" >&5
7537 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
7538 { (eval echo "$as_me:7538: \"$ac_try\"") >&5
7541 echo "$as_me:7541: \$? = $ac_status" >&5
7542 (exit $ac_status); }; }; then
7543 cf_have_ncuconfig=yes
7545 echo "$as_me: program exited with status $ac_status" >&5
7546 echo "$as_me: failed program was:" >&5
7547 cat conftest.$ac_ext >&5
7548 cf_have_ncuconfig=no
7550 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
7553 echo "$as_me: failed program was:" >&5
7554 cat conftest.$ac_ext >&5
7555 cf_have_ncuconfig=no
7557 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7558 echo "$as_me:7558: result: $cf_have_ncuconfig" >&5
7559 echo "${ECHO_T}$cf_have_ncuconfig" >&6
7560 test "$cf_have_ncuconfig" = maybe && cf_have_ncuconfig=yes
7561 if test "$cf_have_ncuconfig" != "yes"
7563 CPPFLAGS="$cf_save_CPPFLAGS"
7564 LIBS="$cf_save_LIBS"
7565 NCURSES_CONFIG_PKG=none
7568 cat >>confdefs.h <<\EOF
7572 NCURSES_CONFIG_PKG=$cf_ncuconfig_root
7574 echo "$as_me:7574: checking for terminfo header" >&5
7575 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
7576 if test "${cf_cv_term_header+set}" = set; then
7577 echo $ECHO_N "(cached) $ECHO_C" >&6
7580 case ${cf_cv_ncurses_header} in
7581 (*/ncurses.h|*/ncursesw.h)
7582 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
7585 cf_term_header=term.h
7589 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
7591 cat >conftest.$ac_ext <<_ACEOF
7592 #line 7592 "configure"
7593 #include "confdefs.h"
7595 #include <${cf_cv_ncurses_header:-curses.h}>
7601 int x = auto_left_margin
7606 rm -f conftest.$ac_objext
7607 if { (eval echo "$as_me:7607: \"$ac_compile\"") >&5
7608 (eval $ac_compile) 2>&5
7610 echo "$as_me:7610: \$? = $ac_status" >&5
7611 (exit $ac_status); } &&
7612 { ac_try='test -s conftest.$ac_objext'
7613 { (eval echo "$as_me:7613: \"$ac_try\"") >&5
7616 echo "$as_me:7616: \$? = $ac_status" >&5
7617 (exit $ac_status); }; }; then
7619 cf_cv_term_header="$cf_test"
7621 echo "$as_me: failed program was:" >&5
7622 cat conftest.$ac_ext >&5
7624 cf_cv_term_header=unknown
7627 rm -f conftest.$ac_objext conftest.$ac_ext
7628 test "$cf_cv_term_header" != unknown && break
7632 echo "$as_me:7632: result: $cf_cv_term_header" >&5
7633 echo "${ECHO_T}$cf_cv_term_header" >&6
7635 # Set definitions to allow ifdef'ing to accommodate subdirectories
7637 case $cf_cv_term_header in
7640 cat >>confdefs.h <<\EOF
7641 #define HAVE_TERM_H 1
7647 case $cf_cv_term_header in
7650 cat >>confdefs.h <<\EOF
7651 #define HAVE_NCURSES_TERM_H 1
7657 cat >>confdefs.h <<\EOF
7658 #define HAVE_NCURSESW_TERM_H 1
7667 echo "$as_me:7667: result: no" >&5
7668 echo "${ECHO_T}no" >&6
7669 NCURSES_CONFIG_PKG=none
7672 NCURSES_CONFIG_PKG=none
7675 if test "x$cf_have_ncuconfig" = "xno"; then
7676 cf_ncurses_config="${cf_ncuconfig_root}${NCURSES_CONFIG_SUFFIX}-config"; echo "Looking for ${cf_ncurses_config}"
7678 if test -n "$ac_tool_prefix"; then
7679 for ac_prog in ${cf_ncurses_config} ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
7681 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
7682 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
7683 echo "$as_me:7683: checking for $ac_word" >&5
7684 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7685 if test "${ac_cv_prog_NCURSES_CONFIG+set}" = set; then
7686 echo $ECHO_N "(cached) $ECHO_C" >&6
7688 if test -n "$NCURSES_CONFIG"; then
7689 ac_cv_prog_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test.
7691 ac_save_IFS=$IFS; IFS=$ac_path_separator
7693 for ac_dir in $ac_dummy; do
7695 test -z "$ac_dir" && ac_dir=.
7696 $as_executable_p "$ac_dir/$ac_word" || continue
7697 ac_cv_prog_NCURSES_CONFIG="$ac_tool_prefix$ac_prog"
7698 echo "$as_me:7698: found $ac_dir/$ac_word" >&5
7704 NCURSES_CONFIG=$ac_cv_prog_NCURSES_CONFIG
7705 if test -n "$NCURSES_CONFIG"; then
7706 echo "$as_me:7706: result: $NCURSES_CONFIG" >&5
7707 echo "${ECHO_T}$NCURSES_CONFIG" >&6
7709 echo "$as_me:7709: result: no" >&5
7710 echo "${ECHO_T}no" >&6
7713 test -n "$NCURSES_CONFIG" && break
7716 if test -z "$NCURSES_CONFIG"; then
7717 ac_ct_NCURSES_CONFIG=$NCURSES_CONFIG
7718 for ac_prog in ${cf_ncurses_config} ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
7720 # Extract the first word of "$ac_prog", so it can be a program name with args.
7721 set dummy $ac_prog; ac_word=$2
7722 echo "$as_me:7722: checking for $ac_word" >&5
7723 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7724 if test "${ac_cv_prog_ac_ct_NCURSES_CONFIG+set}" = set; then
7725 echo $ECHO_N "(cached) $ECHO_C" >&6
7727 if test -n "$ac_ct_NCURSES_CONFIG"; then
7728 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_ct_NCURSES_CONFIG" # Let the user override the test.
7730 ac_save_IFS=$IFS; IFS=$ac_path_separator
7732 for ac_dir in $ac_dummy; do
7734 test -z "$ac_dir" && ac_dir=.
7735 $as_executable_p "$ac_dir/$ac_word" || continue
7736 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_prog"
7737 echo "$as_me:7737: found $ac_dir/$ac_word" >&5
7743 ac_ct_NCURSES_CONFIG=$ac_cv_prog_ac_ct_NCURSES_CONFIG
7744 if test -n "$ac_ct_NCURSES_CONFIG"; then
7745 echo "$as_me:7745: result: $ac_ct_NCURSES_CONFIG" >&5
7746 echo "${ECHO_T}$ac_ct_NCURSES_CONFIG" >&6
7748 echo "$as_me:7748: result: no" >&5
7749 echo "${ECHO_T}no" >&6
7752 test -n "$ac_ct_NCURSES_CONFIG" && break
7754 test -n "$ac_ct_NCURSES_CONFIG" || ac_ct_NCURSES_CONFIG="none"
7756 NCURSES_CONFIG=$ac_ct_NCURSES_CONFIG
7759 if test "$NCURSES_CONFIG" != none ; then
7764 cf_new_extra_cppflags=
7766 for cf_add_cflags in `$NCURSES_CONFIG --cflags`
7768 case $cf_fix_cppflags in
7770 case $cf_add_cflags in
7771 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
7772 case $cf_add_cflags in
7774 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
7776 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
7777 && test -z "${cf_tst_cflags}" \
7778 && cf_fix_cppflags=yes
7780 if test $cf_fix_cppflags = yes ; then
7782 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
7783 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
7786 elif test "${cf_tst_cflags}" = "\"'" ; then
7788 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
7789 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
7799 case $cf_add_cflags in
7801 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
7803 CPPFLAGS=`echo "$CPPFLAGS" | \
7804 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
7805 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
7810 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
7811 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
7818 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
7819 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
7826 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
7827 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
7829 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
7831 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
7832 && test -z "${cf_tst_cflags}" \
7833 && cf_fix_cppflags=no
7838 if test -n "$cf_new_cflags" ; then
7840 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
7841 CFLAGS="${CFLAGS}$cf_new_cflags"
7845 if test -n "$cf_new_cppflags" ; then
7847 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
7848 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
7852 if test -n "$cf_new_extra_cppflags" ; then
7854 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
7855 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
7859 cf_add_libs="`$NCURSES_CONFIG --libs`"
7860 # Filter out duplicates - this happens with badly-designed ".pc" files...
7861 for cf_add_1lib in $LIBS
7863 for cf_add_2lib in $cf_add_libs
7865 if test "x$cf_add_1lib" = "x$cf_add_2lib"
7871 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
7875 # even with config script, some packages use no-override for curses.h
7877 echo "$as_me:7877: checking if we have identified curses headers" >&5
7878 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
7879 if test "${cf_cv_ncurses_header+set}" = set; then
7880 echo $ECHO_N "(cached) $ECHO_C" >&6
7883 cf_cv_ncurses_header=none
7885 ncurses.h $cf_cv_screen/ncurses.h \
7886 curses.h $cf_cv_screen/curses.h
7888 cat >conftest.$ac_ext <<_ACEOF
7889 #line 7889 "configure"
7890 #include "confdefs.h"
7891 #include <${cf_header}>
7895 initscr(); tgoto("?", 0,0)
7900 rm -f conftest.$ac_objext
7901 if { (eval echo "$as_me:7901: \"$ac_compile\"") >&5
7902 (eval $ac_compile) 2>&5
7904 echo "$as_me:7904: \$? = $ac_status" >&5
7905 (exit $ac_status); } &&
7906 { ac_try='test -s conftest.$ac_objext'
7907 { (eval echo "$as_me:7907: \"$ac_try\"") >&5
7910 echo "$as_me:7910: \$? = $ac_status" >&5
7911 (exit $ac_status); }; }; then
7912 cf_cv_ncurses_header=$cf_header; break
7914 echo "$as_me: failed program was:" >&5
7915 cat conftest.$ac_ext >&5
7917 rm -f conftest.$ac_objext conftest.$ac_ext
7921 echo "$as_me:7921: result: $cf_cv_ncurses_header" >&5
7922 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
7924 if test "$cf_cv_ncurses_header" = none ; then
7925 { { echo "$as_me:7925: error: No curses header-files found" >&5
7926 echo "$as_me: error: No curses header-files found" >&2;}
7927 { (exit 1); exit 1; }; }
7930 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
7932 for ac_header in $cf_cv_ncurses_header
7934 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7935 echo "$as_me:7935: checking for $ac_header" >&5
7936 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7937 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7938 echo $ECHO_N "(cached) $ECHO_C" >&6
7940 cat >conftest.$ac_ext <<_ACEOF
7941 #line 7941 "configure"
7942 #include "confdefs.h"
7943 #include <$ac_header>
7945 if { (eval echo "$as_me:7945: \"$ac_cpp conftest.$ac_ext\"") >&5
7946 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7948 egrep -v '^ *\+' conftest.er1 >conftest.err
7950 cat conftest.err >&5
7951 echo "$as_me:7951: \$? = $ac_status" >&5
7952 (exit $ac_status); } >/dev/null; then
7953 if test -s conftest.err; then
7954 ac_cpp_err=$ac_c_preproc_warn_flag
7961 if test -z "$ac_cpp_err"; then
7962 eval "$as_ac_Header=yes"
7964 echo "$as_me: failed program was:" >&5
7965 cat conftest.$ac_ext >&5
7966 eval "$as_ac_Header=no"
7968 rm -f conftest.err conftest.$ac_ext
7970 echo "$as_me:7970: result: `eval echo '${'$as_ac_Header'}'`" >&5
7971 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7972 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7973 cat >>confdefs.h <<EOF
7974 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7980 cat >>confdefs.h <<\EOF
7984 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
7986 cat >>confdefs.h <<EOF
7987 #define $cf_nculib_ROOT 1
7990 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
7994 cf_ncuhdr_root=$cf_cv_screen
7996 test -n "$cf_cv_curses_dir" && \
7997 test "$cf_cv_curses_dir" != "no" && { \
7999 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
8000 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
8002 while test $cf_add_incdir != /usr/include
8004 if test -d $cf_add_incdir
8007 if test -n "$CFLAGS$CPPFLAGS" ; then
8008 # a loop is needed to ensure we can add subdirs of existing dirs
8009 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
8010 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
8011 cf_have_incdir=yes; break
8016 if test "$cf_have_incdir" = no ; then
8017 if test "$cf_add_incdir" = /usr/local/include ; then
8018 if test "$GCC" = yes
8020 cf_save_CPPFLAGS=$CPPFLAGS
8022 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
8023 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
8025 cat >conftest.$ac_ext <<_ACEOF
8026 #line 8026 "configure"
8027 #include "confdefs.h"
8037 rm -f conftest.$ac_objext
8038 if { (eval echo "$as_me:8038: \"$ac_compile\"") >&5
8039 (eval $ac_compile) 2>&5
8041 echo "$as_me:8041: \$? = $ac_status" >&5
8042 (exit $ac_status); } &&
8043 { ac_try='test -s conftest.$ac_objext'
8044 { (eval echo "$as_me:8044: \"$ac_try\"") >&5
8047 echo "$as_me:8047: \$? = $ac_status" >&5
8048 (exit $ac_status); }; }; then
8051 echo "$as_me: failed program was:" >&5
8052 cat conftest.$ac_ext >&5
8055 rm -f conftest.$ac_objext conftest.$ac_ext
8056 CPPFLAGS=$cf_save_CPPFLAGS
8061 if test "$cf_have_incdir" = no ; then
8062 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
8064 echo "${as_me:-configure}:8064: testing adding $cf_add_incdir to include-path ..." 1>&5
8066 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8068 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
8069 test "$cf_top_incdir" = "$cf_add_incdir" && break
8070 cf_add_incdir="$cf_top_incdir"
8083 echo "$as_me:8083: checking for $cf_ncuhdr_root header in include-path" >&5
8084 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
8085 if test "${cf_cv_ncurses_h+set}" = set; then
8086 echo $ECHO_N "(cached) $ECHO_C" >&6
8089 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
8090 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
8091 for cf_header in $cf_header_list
8094 cat >conftest.$ac_ext <<_ACEOF
8095 #line 8095 "configure"
8096 #include "confdefs.h"
8098 #include <$cf_header>
8103 #ifdef NCURSES_VERSION
8105 printf("%s\n", NCURSES_VERSION);
8118 rm -f conftest.$ac_objext
8119 if { (eval echo "$as_me:8119: \"$ac_compile\"") >&5
8120 (eval $ac_compile) 2>&5
8122 echo "$as_me:8122: \$? = $ac_status" >&5
8123 (exit $ac_status); } &&
8124 { ac_try='test -s conftest.$ac_objext'
8125 { (eval echo "$as_me:8125: \"$ac_try\"") >&5
8128 echo "$as_me:8128: \$? = $ac_status" >&5
8129 (exit $ac_status); }; }; then
8130 cf_cv_ncurses_h=$cf_header
8133 echo "$as_me: failed program was:" >&5
8134 cat conftest.$ac_ext >&5
8137 rm -f conftest.$ac_objext conftest.$ac_ext
8139 test "$cf_cv_ncurses_h" != no && break
8143 echo "$as_me:8143: result: $cf_cv_ncurses_h" >&5
8144 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
8146 if test "$cf_cv_ncurses_h" != no ; then
8147 cf_cv_ncurses_header=$cf_cv_ncurses_h
8150 echo "$as_me:8150: checking for $cf_ncuhdr_root include-path" >&5
8151 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
8152 if test "${cf_cv_ncurses_h2+set}" = set; then
8153 echo $ECHO_N "(cached) $ECHO_C" >&6
8156 test -n "$verbose" && echo
8160 # collect the current set of include-directories from compiler flags
8161 cf_header_path_list=""
8162 if test -n "${CFLAGS}${CPPFLAGS}" ; then
8163 for cf_header_path in $CPPFLAGS $CFLAGS
8165 case $cf_header_path in
8167 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
8169 test "x$cf_header_path" != "xNONE" && \
8170 test -d "$cf_header_path" && \
8172 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
8173 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
8174 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
8175 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
8176 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
8177 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"
8180 cf_header_path_list="$cf_header_path_list $cf_search"
8186 # add the variations for the package we are looking for
8190 test "x$prefix" != "xNONE" && \
8191 test -d "$prefix" && \
8193 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
8194 test -d $prefix/include && cf_search="$cf_search $prefix/include"
8195 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
8196 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
8197 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
8198 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
8201 for cf_subdir_prefix in \
8210 test "x$cf_subdir_prefix" != "x$prefix" && \
8211 test -d "$cf_subdir_prefix" && \
8212 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
8213 test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
8214 test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include"
8215 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root"
8216 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root/include"
8217 test -d $cf_subdir_prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include"
8218 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"
8223 test "$includedir" != NONE && \
8224 test "$includedir" != "/usr/include" && \
8225 test -d "$includedir" && {
8226 test -d $includedir && cf_search="$cf_search $includedir"
8227 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
8230 test "$oldincludedir" != NONE && \
8231 test "$oldincludedir" != "/usr/include" && \
8232 test -d "$oldincludedir" && {
8233 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
8234 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
8237 cf_search="$cf_search $cf_header_path_list"
8239 test -n "$verbose" && echo search path $cf_search
8240 cf_save2_CPPFLAGS="$CPPFLAGS"
8241 for cf_incdir in $cf_search
8244 if test -n "$cf_incdir" ; then
8245 for cf_add_incdir in $cf_incdir
8247 while test $cf_add_incdir != /usr/include
8249 if test -d $cf_add_incdir
8252 if test -n "$CFLAGS$CPPFLAGS" ; then
8253 # a loop is needed to ensure we can add subdirs of existing dirs
8254 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
8255 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
8256 cf_have_incdir=yes; break
8261 if test "$cf_have_incdir" = no ; then
8262 if test "$cf_add_incdir" = /usr/local/include ; then
8263 if test "$GCC" = yes
8265 cf_save_CPPFLAGS=$CPPFLAGS
8267 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
8268 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
8270 cat >conftest.$ac_ext <<_ACEOF
8271 #line 8271 "configure"
8272 #include "confdefs.h"
8282 rm -f conftest.$ac_objext
8283 if { (eval echo "$as_me:8283: \"$ac_compile\"") >&5
8284 (eval $ac_compile) 2>&5
8286 echo "$as_me:8286: \$? = $ac_status" >&5
8287 (exit $ac_status); } &&
8288 { ac_try='test -s conftest.$ac_objext'
8289 { (eval echo "$as_me:8289: \"$ac_try\"") >&5
8292 echo "$as_me:8292: \$? = $ac_status" >&5
8293 (exit $ac_status); }; }; then
8296 echo "$as_me: failed program was:" >&5
8297 cat conftest.$ac_ext >&5
8300 rm -f conftest.$ac_objext conftest.$ac_ext
8301 CPPFLAGS=$cf_save_CPPFLAGS
8306 if test "$cf_have_incdir" = no ; then
8307 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
8309 echo "${as_me:-configure}:8309: testing adding $cf_add_incdir to include-path ..." 1>&5
8311 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8313 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
8314 test "$cf_top_incdir" = "$cf_add_incdir" && break
8315 cf_add_incdir="$cf_top_incdir"
8331 cat >conftest.$ac_ext <<_ACEOF
8332 #line 8332 "configure"
8333 #include "confdefs.h"
8335 #include <$cf_header>
8340 #ifdef NCURSES_VERSION
8342 printf("%s\n", NCURSES_VERSION);
8355 rm -f conftest.$ac_objext
8356 if { (eval echo "$as_me:8356: \"$ac_compile\"") >&5
8357 (eval $ac_compile) 2>&5
8359 echo "$as_me:8359: \$? = $ac_status" >&5
8360 (exit $ac_status); } &&
8361 { ac_try='test -s conftest.$ac_objext'
8362 { (eval echo "$as_me:8362: \"$ac_try\"") >&5
8365 echo "$as_me:8365: \$? = $ac_status" >&5
8366 (exit $ac_status); }; }; then
8367 cf_cv_ncurses_h2=$cf_header
8370 echo "$as_me: failed program was:" >&5
8371 cat conftest.$ac_ext >&5
8374 rm -f conftest.$ac_objext conftest.$ac_ext
8376 if test "$cf_cv_ncurses_h2" != no ; then
8377 cf_cv_ncurses_h2=$cf_incdir/$cf_header
8378 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
8381 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
8383 CPPFLAGS="$cf_save2_CPPFLAGS"
8384 test "$cf_cv_ncurses_h2" != no && break
8386 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:8386: error: not found" >&5
8387 echo "$as_me: error: not found" >&2;}
8388 { (exit 1); exit 1; }; }
8391 echo "$as_me:8391: result: $cf_cv_ncurses_h2" >&5
8392 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
8394 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
8395 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
8396 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
8397 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
8400 if test -n "$cf_1st_incdir" ; then
8401 for cf_add_incdir in $cf_1st_incdir
8403 while test $cf_add_incdir != /usr/include
8405 if test -d $cf_add_incdir
8408 if test -n "$CFLAGS$CPPFLAGS" ; then
8409 # a loop is needed to ensure we can add subdirs of existing dirs
8410 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
8411 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
8412 cf_have_incdir=yes; break
8417 if test "$cf_have_incdir" = no ; then
8418 if test "$cf_add_incdir" = /usr/local/include ; then
8419 if test "$GCC" = yes
8421 cf_save_CPPFLAGS=$CPPFLAGS
8423 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
8424 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
8426 cat >conftest.$ac_ext <<_ACEOF
8427 #line 8427 "configure"
8428 #include "confdefs.h"
8438 rm -f conftest.$ac_objext
8439 if { (eval echo "$as_me:8439: \"$ac_compile\"") >&5
8440 (eval $ac_compile) 2>&5
8442 echo "$as_me:8442: \$? = $ac_status" >&5
8443 (exit $ac_status); } &&
8444 { ac_try='test -s conftest.$ac_objext'
8445 { (eval echo "$as_me:8445: \"$ac_try\"") >&5
8448 echo "$as_me:8448: \$? = $ac_status" >&5
8449 (exit $ac_status); }; }; then
8452 echo "$as_me: failed program was:" >&5
8453 cat conftest.$ac_ext >&5
8456 rm -f conftest.$ac_objext conftest.$ac_ext
8457 CPPFLAGS=$cf_save_CPPFLAGS
8462 if test "$cf_have_incdir" = no ; then
8463 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
8465 echo "${as_me:-configure}:8465: testing adding $cf_add_incdir to include-path ..." 1>&5
8467 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8469 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
8470 test "$cf_top_incdir" = "$cf_add_incdir" && break
8471 cf_add_incdir="$cf_top_incdir"
8484 # Set definitions to allow ifdef'ing for ncurses.h
8486 case $cf_cv_ncurses_header in
8489 cat >>confdefs.h <<\EOF
8490 #define HAVE_NCURSES_H 1
8496 case $cf_cv_ncurses_header in
8497 (ncurses/curses.h|ncurses/ncurses.h)
8499 cat >>confdefs.h <<\EOF
8500 #define HAVE_NCURSES_NCURSES_H 1
8504 (ncursesw/curses.h|ncursesw/ncurses.h)
8506 cat >>confdefs.h <<\EOF
8507 #define HAVE_NCURSESW_NCURSES_H 1
8513 echo "$as_me:8513: checking for terminfo header" >&5
8514 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
8515 if test "${cf_cv_term_header+set}" = set; then
8516 echo $ECHO_N "(cached) $ECHO_C" >&6
8519 case ${cf_cv_ncurses_header} in
8520 (*/ncurses.h|*/ncursesw.h)
8521 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
8524 cf_term_header=term.h
8528 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
8530 cat >conftest.$ac_ext <<_ACEOF
8531 #line 8531 "configure"
8532 #include "confdefs.h"
8534 #include <${cf_cv_ncurses_header:-curses.h}>
8540 int x = auto_left_margin
8545 rm -f conftest.$ac_objext
8546 if { (eval echo "$as_me:8546: \"$ac_compile\"") >&5
8547 (eval $ac_compile) 2>&5
8549 echo "$as_me:8549: \$? = $ac_status" >&5
8550 (exit $ac_status); } &&
8551 { ac_try='test -s conftest.$ac_objext'
8552 { (eval echo "$as_me:8552: \"$ac_try\"") >&5
8555 echo "$as_me:8555: \$? = $ac_status" >&5
8556 (exit $ac_status); }; }; then
8558 cf_cv_term_header="$cf_test"
8560 echo "$as_me: failed program was:" >&5
8561 cat conftest.$ac_ext >&5
8563 cf_cv_term_header=unknown
8566 rm -f conftest.$ac_objext conftest.$ac_ext
8567 test "$cf_cv_term_header" != unknown && break
8571 echo "$as_me:8571: result: $cf_cv_term_header" >&5
8572 echo "${ECHO_T}$cf_cv_term_header" >&6
8574 # Set definitions to allow ifdef'ing to accommodate subdirectories
8576 case $cf_cv_term_header in
8579 cat >>confdefs.h <<\EOF
8580 #define HAVE_TERM_H 1
8586 case $cf_cv_term_header in
8589 cat >>confdefs.h <<\EOF
8590 #define HAVE_NCURSES_TERM_H 1
8596 cat >>confdefs.h <<\EOF
8597 #define HAVE_NCURSESW_TERM_H 1
8603 # some applications need this, but should check for NCURSES_VERSION
8605 cat >>confdefs.h <<\EOF
8609 echo "$as_me:8609: checking for ncurses version" >&5
8610 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
8611 if test "${cf_cv_ncurses_version+set}" = set; then
8612 echo $ECHO_N "(cached) $ECHO_C" >&6
8615 cf_cv_ncurses_version=no
8618 if test "$cross_compiling" = yes; then
8620 # This will not work if the preprocessor splits the line after the
8621 # Autoconf token. The 'unproto' program does that.
8622 cat > conftest.$ac_ext <<EOF
8623 #include <${cf_cv_ncurses_header:-curses.h}>
8625 #ifdef NCURSES_VERSION
8626 Autoconf NCURSES_VERSION
8634 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
8635 { (eval echo "$as_me:8635: \"$cf_try\"") >&5
8638 echo "$as_me:8638: \$? = $ac_status" >&5
8639 (exit $ac_status); }
8640 if test -f conftest.out ; then
8641 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
8642 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
8647 cat >conftest.$ac_ext <<_ACEOF
8648 #line 8648 "configure"
8649 #include "confdefs.h"
8651 #include <${cf_cv_ncurses_header:-curses.h}>
8655 FILE *fp = fopen("$cf_tempfile", "w");
8656 #ifdef NCURSES_VERSION
8657 # ifdef NCURSES_VERSION_PATCH
8658 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
8660 fprintf(fp, "%s\n", NCURSES_VERSION);
8664 fprintf(fp, "old\n");
8669 ${cf_cv_main_return:-return}(0);
8672 rm -f conftest$ac_exeext
8673 if { (eval echo "$as_me:8673: \"$ac_link\"") >&5
8674 (eval $ac_link) 2>&5
8676 echo "$as_me:8676: \$? = $ac_status" >&5
8677 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
8678 { (eval echo "$as_me:8678: \"$ac_try\"") >&5
8681 echo "$as_me:8681: \$? = $ac_status" >&5
8682 (exit $ac_status); }; }; then
8684 cf_cv_ncurses_version=`cat $cf_tempfile`
8686 echo "$as_me: program exited with status $ac_status" >&5
8687 echo "$as_me: failed program was:" >&5
8688 cat conftest.$ac_ext >&5
8690 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
8695 echo "$as_me:8695: result: $cf_cv_ncurses_version" >&5
8696 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
8697 test "$cf_cv_ncurses_version" = no ||
8698 cat >>confdefs.h <<\EOF
8702 cf_nculib_root=$cf_cv_screen
8703 # This works, except for the special case where we find gpm, but
8704 # ncurses is in a nonstandard location via $LIBS, and we really want
8707 cf_ncurses_SAVE="$LIBS"
8708 echo "$as_me:8708: checking for Gpm_Open in -lgpm" >&5
8709 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
8710 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
8711 echo $ECHO_N "(cached) $ECHO_C" >&6
8713 ac_check_lib_save_LIBS=$LIBS
8715 cat >conftest.$ac_ext <<_ACEOF
8716 #line 8716 "configure"
8717 #include "confdefs.h"
8719 /* Override any gcc2 internal prototype to avoid an error. */
8723 /* We use char because int might match the return type of a gcc2
8724 builtin and then its argument prototype would still apply. */
8734 rm -f conftest.$ac_objext conftest$ac_exeext
8735 if { (eval echo "$as_me:8735: \"$ac_link\"") >&5
8736 (eval $ac_link) 2>&5
8738 echo "$as_me:8738: \$? = $ac_status" >&5
8739 (exit $ac_status); } &&
8740 { ac_try='test -s conftest$ac_exeext'
8741 { (eval echo "$as_me:8741: \"$ac_try\"") >&5
8744 echo "$as_me:8744: \$? = $ac_status" >&5
8745 (exit $ac_status); }; }; then
8746 ac_cv_lib_gpm_Gpm_Open=yes
8748 echo "$as_me: failed program was:" >&5
8749 cat conftest.$ac_ext >&5
8750 ac_cv_lib_gpm_Gpm_Open=no
8752 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8753 LIBS=$ac_check_lib_save_LIBS
8755 echo "$as_me:8755: result: $ac_cv_lib_gpm_Gpm_Open" >&5
8756 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
8757 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
8758 echo "$as_me:8758: checking for initscr in -lgpm" >&5
8759 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
8760 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
8761 echo $ECHO_N "(cached) $ECHO_C" >&6
8763 ac_check_lib_save_LIBS=$LIBS
8765 cat >conftest.$ac_ext <<_ACEOF
8766 #line 8766 "configure"
8767 #include "confdefs.h"
8769 /* Override any gcc2 internal prototype to avoid an error. */
8773 /* We use char because int might match the return type of a gcc2
8774 builtin and then its argument prototype would still apply. */
8784 rm -f conftest.$ac_objext conftest$ac_exeext
8785 if { (eval echo "$as_me:8785: \"$ac_link\"") >&5
8786 (eval $ac_link) 2>&5
8788 echo "$as_me:8788: \$? = $ac_status" >&5
8789 (exit $ac_status); } &&
8790 { ac_try='test -s conftest$ac_exeext'
8791 { (eval echo "$as_me:8791: \"$ac_try\"") >&5
8794 echo "$as_me:8794: \$? = $ac_status" >&5
8795 (exit $ac_status); }; }; then
8796 ac_cv_lib_gpm_initscr=yes
8798 echo "$as_me: failed program was:" >&5
8799 cat conftest.$ac_ext >&5
8800 ac_cv_lib_gpm_initscr=no
8802 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8803 LIBS=$ac_check_lib_save_LIBS
8805 echo "$as_me:8805: result: $ac_cv_lib_gpm_initscr" >&5
8806 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
8807 if test $ac_cv_lib_gpm_initscr = yes; then
8808 LIBS="$cf_ncurses_SAVE"
8810 cf_ncurses_LIBS="-lgpm"
8817 # This is only necessary if you are linking against an obsolete
8818 # version of ncurses (but it should do no harm, since it's static).
8819 if test "$cf_nculib_root" = ncurses ; then
8820 echo "$as_me:8820: checking for tgoto in -lmytinfo" >&5
8821 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
8822 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
8823 echo $ECHO_N "(cached) $ECHO_C" >&6
8825 ac_check_lib_save_LIBS=$LIBS
8826 LIBS="-lmytinfo $LIBS"
8827 cat >conftest.$ac_ext <<_ACEOF
8828 #line 8828 "configure"
8829 #include "confdefs.h"
8831 /* Override any gcc2 internal prototype to avoid an error. */
8835 /* We use char because int might match the return type of a gcc2
8836 builtin and then its argument prototype would still apply. */
8846 rm -f conftest.$ac_objext conftest$ac_exeext
8847 if { (eval echo "$as_me:8847: \"$ac_link\"") >&5
8848 (eval $ac_link) 2>&5
8850 echo "$as_me:8850: \$? = $ac_status" >&5
8851 (exit $ac_status); } &&
8852 { ac_try='test -s conftest$ac_exeext'
8853 { (eval echo "$as_me:8853: \"$ac_try\"") >&5
8856 echo "$as_me:8856: \$? = $ac_status" >&5
8857 (exit $ac_status); }; }; then
8858 ac_cv_lib_mytinfo_tgoto=yes
8860 echo "$as_me: failed program was:" >&5
8861 cat conftest.$ac_ext >&5
8862 ac_cv_lib_mytinfo_tgoto=no
8864 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8865 LIBS=$ac_check_lib_save_LIBS
8867 echo "$as_me:8867: result: $ac_cv_lib_mytinfo_tgoto" >&5
8868 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
8869 if test $ac_cv_lib_mytinfo_tgoto = yes; then
8870 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
8877 cf_add_libs="$cf_ncurses_LIBS"
8878 # Filter out duplicates - this happens with badly-designed ".pc" files...
8879 for cf_add_1lib in $LIBS
8881 for cf_add_2lib in $cf_add_libs
8883 if test "x$cf_add_1lib" = "x$cf_add_2lib"
8889 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
8893 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
8896 cf_add_libs="-l$cf_nculib_root"
8897 # Filter out duplicates - this happens with badly-designed ".pc" files...
8898 for cf_add_1lib in $LIBS
8900 for cf_add_2lib in $cf_add_libs
8902 if test "x$cf_add_1lib" = "x$cf_add_2lib"
8908 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
8914 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
8916 echo "$as_me:8916: checking for initscr" >&5
8917 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
8918 if test "${ac_cv_func_initscr+set}" = set; then
8919 echo $ECHO_N "(cached) $ECHO_C" >&6
8921 cat >conftest.$ac_ext <<_ACEOF
8922 #line 8922 "configure"
8923 #include "confdefs.h"
8924 #define initscr autoconf_temporary
8925 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
8932 /* We use char because int might match the return type of a gcc2
8933 builtin and then its argument prototype would still apply. */
8934 char initscr (void);
8940 /* The GNU C library defines stubs for functions which it implements
8941 to always fail with ENOSYS. Some functions are actually named
8942 something starting with __ and the normal name is an alias. */
8943 #if defined (__stub_initscr) || defined (__stub___initscr)
8944 #error found stub for initscr
8952 rm -f conftest.$ac_objext conftest$ac_exeext
8953 if { (eval echo "$as_me:8953: \"$ac_link\"") >&5
8954 (eval $ac_link) 2>&5
8956 echo "$as_me:8956: \$? = $ac_status" >&5
8957 (exit $ac_status); } &&
8958 { ac_try='test -s conftest$ac_exeext'
8959 { (eval echo "$as_me:8959: \"$ac_try\"") >&5
8962 echo "$as_me:8962: \$? = $ac_status" >&5
8963 (exit $ac_status); }; }; then
8964 ac_cv_func_initscr=yes
8966 echo "$as_me: failed program was:" >&5
8967 cat conftest.$ac_ext >&5
8968 ac_cv_func_initscr=no
8970 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8972 echo "$as_me:8972: result: $ac_cv_func_initscr" >&5
8973 echo "${ECHO_T}$ac_cv_func_initscr" >&6
8974 if test $ac_cv_func_initscr = yes; then
8975 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
8978 cf_save_LIBS="$LIBS"
8979 echo "$as_me:8979: checking for initscr in -l$cf_nculib_root" >&5
8980 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
8981 LIBS="-l$cf_nculib_root $LIBS"
8982 cat >conftest.$ac_ext <<_ACEOF
8983 #line 8983 "configure"
8984 #include "confdefs.h"
8985 #include <${cf_cv_ncurses_header:-curses.h}>
8994 rm -f conftest.$ac_objext conftest$ac_exeext
8995 if { (eval echo "$as_me:8995: \"$ac_link\"") >&5
8996 (eval $ac_link) 2>&5
8998 echo "$as_me:8998: \$? = $ac_status" >&5
8999 (exit $ac_status); } &&
9000 { ac_try='test -s conftest$ac_exeext'
9001 { (eval echo "$as_me:9001: \"$ac_try\"") >&5
9004 echo "$as_me:9004: \$? = $ac_status" >&5
9005 (exit $ac_status); }; }; then
9006 echo "$as_me:9006: result: yes" >&5
9007 echo "${ECHO_T}yes" >&6
9008 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
9011 echo "$as_me: failed program was:" >&5
9012 cat conftest.$ac_ext >&5
9013 echo "$as_me:9013: result: no" >&5
9014 echo "${ECHO_T}no" >&6
9017 cf_library_path_list=""
9018 if test -n "${LDFLAGS}${LIBS}" ; then
9019 for cf_library_path in $LDFLAGS $LIBS
9021 case $cf_library_path in
9023 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
9025 test "x$cf_library_path" != "xNONE" && \
9026 test -d "$cf_library_path" && \
9028 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
9029 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
9030 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
9031 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
9032 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
9033 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"
9036 cf_library_path_list="$cf_library_path_list $cf_search"
9044 test "x$prefix" != "xNONE" && \
9045 test -d "$prefix" && \
9047 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
9048 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
9049 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
9050 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
9051 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
9052 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
9055 for cf_subdir_prefix in \
9064 test "x$cf_subdir_prefix" != "x$prefix" && \
9065 test -d "$cf_subdir_prefix" && \
9066 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
9067 test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
9068 test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib"
9069 test -d $cf_subdir_prefix/lib/$cf_nculib_root && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root"
9070 test -d $cf_subdir_prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root/lib"
9071 test -d $cf_subdir_prefix/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib"
9072 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"
9077 cf_search="$cf_library_path_list $cf_search"
9079 for cf_libdir in $cf_search
9081 echo "$as_me:9081: checking for -l$cf_nculib_root in $cf_libdir" >&5
9082 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
9083 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
9084 cat >conftest.$ac_ext <<_ACEOF
9085 #line 9085 "configure"
9086 #include "confdefs.h"
9087 #include <${cf_cv_ncurses_header:-curses.h}>
9096 rm -f conftest.$ac_objext conftest$ac_exeext
9097 if { (eval echo "$as_me:9097: \"$ac_link\"") >&5
9098 (eval $ac_link) 2>&5
9100 echo "$as_me:9100: \$? = $ac_status" >&5
9101 (exit $ac_status); } &&
9102 { ac_try='test -s conftest$ac_exeext'
9103 { (eval echo "$as_me:9103: \"$ac_try\"") >&5
9106 echo "$as_me:9106: \$? = $ac_status" >&5
9107 (exit $ac_status); }; }; then
9108 echo "$as_me:9108: result: yes" >&5
9109 echo "${ECHO_T}yes" >&6
9110 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
9113 echo "$as_me: failed program was:" >&5
9114 cat conftest.$ac_ext >&5
9115 echo "$as_me:9115: result: no" >&5
9116 echo "${ECHO_T}no" >&6
9117 LIBS="$cf_save_LIBS"
9119 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9123 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9127 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
9129 if test $cf_found_library = no ; then
9130 { { echo "$as_me:9130: error: Cannot link $cf_nculib_root library" >&5
9131 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
9132 { (exit 1); exit 1; }; }
9137 if test -n "$cf_ncurses_LIBS" ; then
9138 echo "$as_me:9138: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
9139 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
9140 cf_ncurses_SAVE="$LIBS"
9141 for p in $cf_ncurses_LIBS ; do
9142 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
9143 if test "$q" != "$LIBS" ; then
9147 cat >conftest.$ac_ext <<_ACEOF
9148 #line 9148 "configure"
9149 #include "confdefs.h"
9150 #include <${cf_cv_ncurses_header:-curses.h}>
9154 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
9159 rm -f conftest.$ac_objext conftest$ac_exeext
9160 if { (eval echo "$as_me:9160: \"$ac_link\"") >&5
9161 (eval $ac_link) 2>&5
9163 echo "$as_me:9163: \$? = $ac_status" >&5
9164 (exit $ac_status); } &&
9165 { ac_try='test -s conftest$ac_exeext'
9166 { (eval echo "$as_me:9166: \"$ac_try\"") >&5
9169 echo "$as_me:9169: \$? = $ac_status" >&5
9170 (exit $ac_status); }; }; then
9171 echo "$as_me:9171: result: yes" >&5
9172 echo "${ECHO_T}yes" >&6
9174 echo "$as_me: failed program was:" >&5
9175 cat conftest.$ac_ext >&5
9176 echo "$as_me:9176: result: no" >&5
9177 echo "${ECHO_T}no" >&6
9178 LIBS="$cf_ncurses_SAVE"
9180 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9183 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
9185 cat >>confdefs.h <<EOF
9186 #define $cf_nculib_ROOT 1
9197 cf_ncuconfig_root=$cf_cv_screen
9198 cf_have_ncuconfig=no
9200 if test "x${PKG_CONFIG:=none}" != xnone; then
9201 echo "$as_me:9201: checking pkg-config for $cf_ncuconfig_root" >&5
9202 echo $ECHO_N "checking pkg-config for $cf_ncuconfig_root... $ECHO_C" >&6
9203 if "$PKG_CONFIG" --exists $cf_ncuconfig_root ; then
9204 echo "$as_me:9204: result: yes" >&5
9205 echo "${ECHO_T}yes" >&6
9207 echo "$as_me:9207: checking if the $cf_ncuconfig_root package files work" >&5
9208 echo $ECHO_N "checking if the $cf_ncuconfig_root package files work... $ECHO_C" >&6
9209 cf_have_ncuconfig=unknown
9211 cf_save_CPPFLAGS="$CPPFLAGS"
9212 cf_save_LIBS="$LIBS"
9217 cf_new_extra_cppflags=
9219 for cf_add_cflags in `$PKG_CONFIG --cflags $cf_ncuconfig_root`
9221 case $cf_fix_cppflags in
9223 case $cf_add_cflags in
9224 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
9225 case $cf_add_cflags in
9227 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
9229 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
9230 && test -z "${cf_tst_cflags}" \
9231 && cf_fix_cppflags=yes
9233 if test $cf_fix_cppflags = yes ; then
9235 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9236 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9239 elif test "${cf_tst_cflags}" = "\"'" ; then
9241 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9242 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9252 case $cf_add_cflags in
9254 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
9256 CPPFLAGS=`echo "$CPPFLAGS" | \
9257 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
9258 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
9263 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
9264 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
9271 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
9272 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
9279 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9280 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9282 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
9284 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
9285 && test -z "${cf_tst_cflags}" \
9286 && cf_fix_cppflags=no
9291 if test -n "$cf_new_cflags" ; then
9293 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
9294 CFLAGS="${CFLAGS}$cf_new_cflags"
9298 if test -n "$cf_new_cppflags" ; then
9300 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
9301 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
9305 if test -n "$cf_new_extra_cppflags" ; then
9307 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
9308 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
9312 cf_add_libs="`$PKG_CONFIG --libs $cf_ncuconfig_root`"
9313 # Filter out duplicates - this happens with badly-designed ".pc" files...
9314 for cf_add_1lib in $LIBS
9316 for cf_add_2lib in $cf_add_libs
9318 if test "x$cf_add_1lib" = "x$cf_add_2lib"
9324 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
9328 cat >conftest.$ac_ext <<_ACEOF
9329 #line 9329 "configure"
9330 #include "confdefs.h"
9331 #include <${cf_cv_ncurses_header:-curses.h}>
9335 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
9340 rm -f conftest.$ac_objext conftest$ac_exeext
9341 if { (eval echo "$as_me:9341: \"$ac_link\"") >&5
9342 (eval $ac_link) 2>&5
9344 echo "$as_me:9344: \$? = $ac_status" >&5
9345 (exit $ac_status); } &&
9346 { ac_try='test -s conftest$ac_exeext'
9347 { (eval echo "$as_me:9347: \"$ac_try\"") >&5
9350 echo "$as_me:9350: \$? = $ac_status" >&5
9351 (exit $ac_status); }; }; then
9352 if test "$cross_compiling" = yes; then
9353 cf_have_ncuconfig=maybe
9355 cat >conftest.$ac_ext <<_ACEOF
9356 #line 9356 "configure"
9357 #include "confdefs.h"
9358 #include <${cf_cv_ncurses_header:-curses.h}>
9360 { char *xx = curses_version(); return (xx == 0); }
9362 rm -f conftest$ac_exeext
9363 if { (eval echo "$as_me:9363: \"$ac_link\"") >&5
9364 (eval $ac_link) 2>&5
9366 echo "$as_me:9366: \$? = $ac_status" >&5
9367 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
9368 { (eval echo "$as_me:9368: \"$ac_try\"") >&5
9371 echo "$as_me:9371: \$? = $ac_status" >&5
9372 (exit $ac_status); }; }; then
9373 cf_have_ncuconfig=yes
9375 echo "$as_me: program exited with status $ac_status" >&5
9376 echo "$as_me: failed program was:" >&5
9377 cat conftest.$ac_ext >&5
9378 cf_have_ncuconfig=no
9380 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
9383 echo "$as_me: failed program was:" >&5
9384 cat conftest.$ac_ext >&5
9385 cf_have_ncuconfig=no
9387 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9388 echo "$as_me:9388: result: $cf_have_ncuconfig" >&5
9389 echo "${ECHO_T}$cf_have_ncuconfig" >&6
9390 test "$cf_have_ncuconfig" = maybe && cf_have_ncuconfig=yes
9391 if test "$cf_have_ncuconfig" != "yes"
9393 CPPFLAGS="$cf_save_CPPFLAGS"
9394 LIBS="$cf_save_LIBS"
9395 NCURSES_CONFIG_PKG=none
9398 cat >>confdefs.h <<\EOF
9402 NCURSES_CONFIG_PKG=$cf_ncuconfig_root
9404 echo "$as_me:9404: checking for terminfo header" >&5
9405 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
9406 if test "${cf_cv_term_header+set}" = set; then
9407 echo $ECHO_N "(cached) $ECHO_C" >&6
9410 case ${cf_cv_ncurses_header} in
9411 (*/ncurses.h|*/ncursesw.h)
9412 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
9415 cf_term_header=term.h
9419 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
9421 cat >conftest.$ac_ext <<_ACEOF
9422 #line 9422 "configure"
9423 #include "confdefs.h"
9425 #include <${cf_cv_ncurses_header:-curses.h}>
9431 int x = auto_left_margin
9436 rm -f conftest.$ac_objext
9437 if { (eval echo "$as_me:9437: \"$ac_compile\"") >&5
9438 (eval $ac_compile) 2>&5
9440 echo "$as_me:9440: \$? = $ac_status" >&5
9441 (exit $ac_status); } &&
9442 { ac_try='test -s conftest.$ac_objext'
9443 { (eval echo "$as_me:9443: \"$ac_try\"") >&5
9446 echo "$as_me:9446: \$? = $ac_status" >&5
9447 (exit $ac_status); }; }; then
9449 cf_cv_term_header="$cf_test"
9451 echo "$as_me: failed program was:" >&5
9452 cat conftest.$ac_ext >&5
9454 cf_cv_term_header=unknown
9457 rm -f conftest.$ac_objext conftest.$ac_ext
9458 test "$cf_cv_term_header" != unknown && break
9462 echo "$as_me:9462: result: $cf_cv_term_header" >&5
9463 echo "${ECHO_T}$cf_cv_term_header" >&6
9465 # Set definitions to allow ifdef'ing to accommodate subdirectories
9467 case $cf_cv_term_header in
9470 cat >>confdefs.h <<\EOF
9471 #define HAVE_TERM_H 1
9477 case $cf_cv_term_header in
9480 cat >>confdefs.h <<\EOF
9481 #define HAVE_NCURSES_TERM_H 1
9487 cat >>confdefs.h <<\EOF
9488 #define HAVE_NCURSESW_TERM_H 1
9497 echo "$as_me:9497: result: no" >&5
9498 echo "${ECHO_T}no" >&6
9499 NCURSES_CONFIG_PKG=none
9502 NCURSES_CONFIG_PKG=none
9505 if test "x$cf_have_ncuconfig" = "xno"; then
9506 cf_ncurses_config="${cf_ncuconfig_root}${NCURSES_CONFIG_SUFFIX}-config"; echo "Looking for ${cf_ncurses_config}"
9508 if test -n "$ac_tool_prefix"; then
9509 for ac_prog in ${cf_ncurses_config} ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
9511 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
9512 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
9513 echo "$as_me:9513: checking for $ac_word" >&5
9514 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
9515 if test "${ac_cv_prog_NCURSES_CONFIG+set}" = set; then
9516 echo $ECHO_N "(cached) $ECHO_C" >&6
9518 if test -n "$NCURSES_CONFIG"; then
9519 ac_cv_prog_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test.
9521 ac_save_IFS=$IFS; IFS=$ac_path_separator
9523 for ac_dir in $ac_dummy; do
9525 test -z "$ac_dir" && ac_dir=.
9526 $as_executable_p "$ac_dir/$ac_word" || continue
9527 ac_cv_prog_NCURSES_CONFIG="$ac_tool_prefix$ac_prog"
9528 echo "$as_me:9528: found $ac_dir/$ac_word" >&5
9534 NCURSES_CONFIG=$ac_cv_prog_NCURSES_CONFIG
9535 if test -n "$NCURSES_CONFIG"; then
9536 echo "$as_me:9536: result: $NCURSES_CONFIG" >&5
9537 echo "${ECHO_T}$NCURSES_CONFIG" >&6
9539 echo "$as_me:9539: result: no" >&5
9540 echo "${ECHO_T}no" >&6
9543 test -n "$NCURSES_CONFIG" && break
9546 if test -z "$NCURSES_CONFIG"; then
9547 ac_ct_NCURSES_CONFIG=$NCURSES_CONFIG
9548 for ac_prog in ${cf_ncurses_config} ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
9550 # Extract the first word of "$ac_prog", so it can be a program name with args.
9551 set dummy $ac_prog; ac_word=$2
9552 echo "$as_me:9552: checking for $ac_word" >&5
9553 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
9554 if test "${ac_cv_prog_ac_ct_NCURSES_CONFIG+set}" = set; then
9555 echo $ECHO_N "(cached) $ECHO_C" >&6
9557 if test -n "$ac_ct_NCURSES_CONFIG"; then
9558 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_ct_NCURSES_CONFIG" # Let the user override the test.
9560 ac_save_IFS=$IFS; IFS=$ac_path_separator
9562 for ac_dir in $ac_dummy; do
9564 test -z "$ac_dir" && ac_dir=.
9565 $as_executable_p "$ac_dir/$ac_word" || continue
9566 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_prog"
9567 echo "$as_me:9567: found $ac_dir/$ac_word" >&5
9573 ac_ct_NCURSES_CONFIG=$ac_cv_prog_ac_ct_NCURSES_CONFIG
9574 if test -n "$ac_ct_NCURSES_CONFIG"; then
9575 echo "$as_me:9575: result: $ac_ct_NCURSES_CONFIG" >&5
9576 echo "${ECHO_T}$ac_ct_NCURSES_CONFIG" >&6
9578 echo "$as_me:9578: result: no" >&5
9579 echo "${ECHO_T}no" >&6
9582 test -n "$ac_ct_NCURSES_CONFIG" && break
9584 test -n "$ac_ct_NCURSES_CONFIG" || ac_ct_NCURSES_CONFIG="none"
9586 NCURSES_CONFIG=$ac_ct_NCURSES_CONFIG
9589 if test "$NCURSES_CONFIG" != none ; then
9594 cf_new_extra_cppflags=
9596 for cf_add_cflags in `$NCURSES_CONFIG --cflags`
9598 case $cf_fix_cppflags in
9600 case $cf_add_cflags in
9601 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
9602 case $cf_add_cflags in
9604 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
9606 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
9607 && test -z "${cf_tst_cflags}" \
9608 && cf_fix_cppflags=yes
9610 if test $cf_fix_cppflags = yes ; then
9612 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9613 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9616 elif test "${cf_tst_cflags}" = "\"'" ; then
9618 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9619 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9629 case $cf_add_cflags in
9631 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
9633 CPPFLAGS=`echo "$CPPFLAGS" | \
9634 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
9635 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
9640 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
9641 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
9648 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
9649 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
9656 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9657 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9659 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
9661 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
9662 && test -z "${cf_tst_cflags}" \
9663 && cf_fix_cppflags=no
9668 if test -n "$cf_new_cflags" ; then
9670 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
9671 CFLAGS="${CFLAGS}$cf_new_cflags"
9675 if test -n "$cf_new_cppflags" ; then
9677 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
9678 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
9682 if test -n "$cf_new_extra_cppflags" ; then
9684 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
9685 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
9689 cf_add_libs="`$NCURSES_CONFIG --libs`"
9690 # Filter out duplicates - this happens with badly-designed ".pc" files...
9691 for cf_add_1lib in $LIBS
9693 for cf_add_2lib in $cf_add_libs
9695 if test "x$cf_add_1lib" = "x$cf_add_2lib"
9701 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
9705 # even with config script, some packages use no-override for curses.h
9707 echo "$as_me:9707: checking if we have identified curses headers" >&5
9708 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
9709 if test "${cf_cv_ncurses_header+set}" = set; then
9710 echo $ECHO_N "(cached) $ECHO_C" >&6
9713 cf_cv_ncurses_header=none
9715 ncurses.h $cf_cv_screen/ncurses.h \
9716 curses.h $cf_cv_screen/curses.h
9718 cat >conftest.$ac_ext <<_ACEOF
9719 #line 9719 "configure"
9720 #include "confdefs.h"
9721 #include <${cf_header}>
9725 initscr(); tgoto("?", 0,0)
9730 rm -f conftest.$ac_objext
9731 if { (eval echo "$as_me:9731: \"$ac_compile\"") >&5
9732 (eval $ac_compile) 2>&5
9734 echo "$as_me:9734: \$? = $ac_status" >&5
9735 (exit $ac_status); } &&
9736 { ac_try='test -s conftest.$ac_objext'
9737 { (eval echo "$as_me:9737: \"$ac_try\"") >&5
9740 echo "$as_me:9740: \$? = $ac_status" >&5
9741 (exit $ac_status); }; }; then
9742 cf_cv_ncurses_header=$cf_header; break
9744 echo "$as_me: failed program was:" >&5
9745 cat conftest.$ac_ext >&5
9747 rm -f conftest.$ac_objext conftest.$ac_ext
9751 echo "$as_me:9751: result: $cf_cv_ncurses_header" >&5
9752 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
9754 if test "$cf_cv_ncurses_header" = none ; then
9755 { { echo "$as_me:9755: error: No curses header-files found" >&5
9756 echo "$as_me: error: No curses header-files found" >&2;}
9757 { (exit 1); exit 1; }; }
9760 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
9762 for ac_header in $cf_cv_ncurses_header
9764 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9765 echo "$as_me:9765: checking for $ac_header" >&5
9766 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9767 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9768 echo $ECHO_N "(cached) $ECHO_C" >&6
9770 cat >conftest.$ac_ext <<_ACEOF
9771 #line 9771 "configure"
9772 #include "confdefs.h"
9773 #include <$ac_header>
9775 if { (eval echo "$as_me:9775: \"$ac_cpp conftest.$ac_ext\"") >&5
9776 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9778 egrep -v '^ *\+' conftest.er1 >conftest.err
9780 cat conftest.err >&5
9781 echo "$as_me:9781: \$? = $ac_status" >&5
9782 (exit $ac_status); } >/dev/null; then
9783 if test -s conftest.err; then
9784 ac_cpp_err=$ac_c_preproc_warn_flag
9791 if test -z "$ac_cpp_err"; then
9792 eval "$as_ac_Header=yes"
9794 echo "$as_me: failed program was:" >&5
9795 cat conftest.$ac_ext >&5
9796 eval "$as_ac_Header=no"
9798 rm -f conftest.err conftest.$ac_ext
9800 echo "$as_me:9800: result: `eval echo '${'$as_ac_Header'}'`" >&5
9801 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9802 if test `eval echo '${'$as_ac_Header'}'` = yes; then
9803 cat >>confdefs.h <<EOF
9804 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9810 cat >>confdefs.h <<\EOF
9814 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
9816 cat >>confdefs.h <<EOF
9817 #define $cf_nculib_ROOT 1
9820 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
9824 cf_ncuhdr_root=$cf_cv_screen
9826 test -n "$cf_cv_curses_dir" && \
9827 test "$cf_cv_curses_dir" != "no" && { \
9829 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
9830 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
9832 while test $cf_add_incdir != /usr/include
9834 if test -d $cf_add_incdir
9837 if test -n "$CFLAGS$CPPFLAGS" ; then
9838 # a loop is needed to ensure we can add subdirs of existing dirs
9839 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
9840 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
9841 cf_have_incdir=yes; break
9846 if test "$cf_have_incdir" = no ; then
9847 if test "$cf_add_incdir" = /usr/local/include ; then
9848 if test "$GCC" = yes
9850 cf_save_CPPFLAGS=$CPPFLAGS
9852 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
9853 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
9855 cat >conftest.$ac_ext <<_ACEOF
9856 #line 9856 "configure"
9857 #include "confdefs.h"
9867 rm -f conftest.$ac_objext
9868 if { (eval echo "$as_me:9868: \"$ac_compile\"") >&5
9869 (eval $ac_compile) 2>&5
9871 echo "$as_me:9871: \$? = $ac_status" >&5
9872 (exit $ac_status); } &&
9873 { ac_try='test -s conftest.$ac_objext'
9874 { (eval echo "$as_me:9874: \"$ac_try\"") >&5
9877 echo "$as_me:9877: \$? = $ac_status" >&5
9878 (exit $ac_status); }; }; then
9881 echo "$as_me: failed program was:" >&5
9882 cat conftest.$ac_ext >&5
9885 rm -f conftest.$ac_objext conftest.$ac_ext
9886 CPPFLAGS=$cf_save_CPPFLAGS
9891 if test "$cf_have_incdir" = no ; then
9892 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
9894 echo "${as_me:-configure}:9894: testing adding $cf_add_incdir to include-path ..." 1>&5
9896 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
9898 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
9899 test "$cf_top_incdir" = "$cf_add_incdir" && break
9900 cf_add_incdir="$cf_top_incdir"
9913 echo "$as_me:9913: checking for $cf_ncuhdr_root header in include-path" >&5
9914 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
9915 if test "${cf_cv_ncurses_h+set}" = set; then
9916 echo $ECHO_N "(cached) $ECHO_C" >&6
9919 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
9920 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
9921 for cf_header in $cf_header_list
9924 cat >conftest.$ac_ext <<_ACEOF
9925 #line 9925 "configure"
9926 #include "confdefs.h"
9928 #include <$cf_header>
9933 #ifdef NCURSES_VERSION
9935 printf("%s\n", NCURSES_VERSION);
9948 rm -f conftest.$ac_objext
9949 if { (eval echo "$as_me:9949: \"$ac_compile\"") >&5
9950 (eval $ac_compile) 2>&5
9952 echo "$as_me:9952: \$? = $ac_status" >&5
9953 (exit $ac_status); } &&
9954 { ac_try='test -s conftest.$ac_objext'
9955 { (eval echo "$as_me:9955: \"$ac_try\"") >&5
9958 echo "$as_me:9958: \$? = $ac_status" >&5
9959 (exit $ac_status); }; }; then
9960 cf_cv_ncurses_h=$cf_header
9963 echo "$as_me: failed program was:" >&5
9964 cat conftest.$ac_ext >&5
9967 rm -f conftest.$ac_objext conftest.$ac_ext
9969 test "$cf_cv_ncurses_h" != no && break
9973 echo "$as_me:9973: result: $cf_cv_ncurses_h" >&5
9974 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
9976 if test "$cf_cv_ncurses_h" != no ; then
9977 cf_cv_ncurses_header=$cf_cv_ncurses_h
9980 echo "$as_me:9980: checking for $cf_ncuhdr_root include-path" >&5
9981 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
9982 if test "${cf_cv_ncurses_h2+set}" = set; then
9983 echo $ECHO_N "(cached) $ECHO_C" >&6
9986 test -n "$verbose" && echo
9990 # collect the current set of include-directories from compiler flags
9991 cf_header_path_list=""
9992 if test -n "${CFLAGS}${CPPFLAGS}" ; then
9993 for cf_header_path in $CPPFLAGS $CFLAGS
9995 case $cf_header_path in
9997 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
9999 test "x$cf_header_path" != "xNONE" && \
10000 test -d "$cf_header_path" && \
10002 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
10003 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
10004 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
10005 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
10006 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
10007 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"
10010 cf_header_path_list="$cf_header_path_list $cf_search"
10016 # add the variations for the package we are looking for
10020 test "x$prefix" != "xNONE" && \
10021 test -d "$prefix" && \
10023 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
10024 test -d $prefix/include && cf_search="$cf_search $prefix/include"
10025 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
10026 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
10027 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
10028 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
10031 for cf_subdir_prefix in \
10040 test "x$cf_subdir_prefix" != "x$prefix" && \
10041 test -d "$cf_subdir_prefix" && \
10042 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
10043 test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
10044 test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include"
10045 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root"
10046 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root/include"
10047 test -d $cf_subdir_prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include"
10048 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"
10053 test "$includedir" != NONE && \
10054 test "$includedir" != "/usr/include" && \
10055 test -d "$includedir" && {
10056 test -d $includedir && cf_search="$cf_search $includedir"
10057 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
10060 test "$oldincludedir" != NONE && \
10061 test "$oldincludedir" != "/usr/include" && \
10062 test -d "$oldincludedir" && {
10063 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
10064 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
10067 cf_search="$cf_search $cf_header_path_list"
10069 test -n "$verbose" && echo search path $cf_search
10070 cf_save2_CPPFLAGS="$CPPFLAGS"
10071 for cf_incdir in $cf_search
10074 if test -n "$cf_incdir" ; then
10075 for cf_add_incdir in $cf_incdir
10077 while test $cf_add_incdir != /usr/include
10079 if test -d $cf_add_incdir
10082 if test -n "$CFLAGS$CPPFLAGS" ; then
10083 # a loop is needed to ensure we can add subdirs of existing dirs
10084 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
10085 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
10086 cf_have_incdir=yes; break
10091 if test "$cf_have_incdir" = no ; then
10092 if test "$cf_add_incdir" = /usr/local/include ; then
10093 if test "$GCC" = yes
10095 cf_save_CPPFLAGS=$CPPFLAGS
10097 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
10098 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
10100 cat >conftest.$ac_ext <<_ACEOF
10101 #line 10101 "configure"
10102 #include "confdefs.h"
10112 rm -f conftest.$ac_objext
10113 if { (eval echo "$as_me:10113: \"$ac_compile\"") >&5
10114 (eval $ac_compile) 2>&5
10116 echo "$as_me:10116: \$? = $ac_status" >&5
10117 (exit $ac_status); } &&
10118 { ac_try='test -s conftest.$ac_objext'
10119 { (eval echo "$as_me:10119: \"$ac_try\"") >&5
10120 (eval $ac_try) 2>&5
10122 echo "$as_me:10122: \$? = $ac_status" >&5
10123 (exit $ac_status); }; }; then
10126 echo "$as_me: failed program was:" >&5
10127 cat conftest.$ac_ext >&5
10130 rm -f conftest.$ac_objext conftest.$ac_ext
10131 CPPFLAGS=$cf_save_CPPFLAGS
10136 if test "$cf_have_incdir" = no ; then
10137 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
10139 echo "${as_me:-configure}:10139: testing adding $cf_add_incdir to include-path ..." 1>&5
10141 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
10143 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
10144 test "$cf_top_incdir" = "$cf_add_incdir" && break
10145 cf_add_incdir="$cf_top_incdir"
10161 cat >conftest.$ac_ext <<_ACEOF
10162 #line 10162 "configure"
10163 #include "confdefs.h"
10165 #include <$cf_header>
10170 #ifdef NCURSES_VERSION
10172 printf("%s\n", NCURSES_VERSION);
10185 rm -f conftest.$ac_objext
10186 if { (eval echo "$as_me:10186: \"$ac_compile\"") >&5
10187 (eval $ac_compile) 2>&5
10189 echo "$as_me:10189: \$? = $ac_status" >&5
10190 (exit $ac_status); } &&
10191 { ac_try='test -s conftest.$ac_objext'
10192 { (eval echo "$as_me:10192: \"$ac_try\"") >&5
10193 (eval $ac_try) 2>&5
10195 echo "$as_me:10195: \$? = $ac_status" >&5
10196 (exit $ac_status); }; }; then
10197 cf_cv_ncurses_h2=$cf_header
10200 echo "$as_me: failed program was:" >&5
10201 cat conftest.$ac_ext >&5
10202 cf_cv_ncurses_h2=no
10204 rm -f conftest.$ac_objext conftest.$ac_ext
10206 if test "$cf_cv_ncurses_h2" != no ; then
10207 cf_cv_ncurses_h2=$cf_incdir/$cf_header
10208 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
10211 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
10213 CPPFLAGS="$cf_save2_CPPFLAGS"
10214 test "$cf_cv_ncurses_h2" != no && break
10216 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:10216: error: not found" >&5
10217 echo "$as_me: error: not found" >&2;}
10218 { (exit 1); exit 1; }; }
10221 echo "$as_me:10221: result: $cf_cv_ncurses_h2" >&5
10222 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
10224 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
10225 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
10226 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
10227 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
10230 if test -n "$cf_1st_incdir" ; then
10231 for cf_add_incdir in $cf_1st_incdir
10233 while test $cf_add_incdir != /usr/include
10235 if test -d $cf_add_incdir
10238 if test -n "$CFLAGS$CPPFLAGS" ; then
10239 # a loop is needed to ensure we can add subdirs of existing dirs
10240 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
10241 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
10242 cf_have_incdir=yes; break
10247 if test "$cf_have_incdir" = no ; then
10248 if test "$cf_add_incdir" = /usr/local/include ; then
10249 if test "$GCC" = yes
10251 cf_save_CPPFLAGS=$CPPFLAGS
10253 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
10254 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
10256 cat >conftest.$ac_ext <<_ACEOF
10257 #line 10257 "configure"
10258 #include "confdefs.h"
10268 rm -f conftest.$ac_objext
10269 if { (eval echo "$as_me:10269: \"$ac_compile\"") >&5
10270 (eval $ac_compile) 2>&5
10272 echo "$as_me:10272: \$? = $ac_status" >&5
10273 (exit $ac_status); } &&
10274 { ac_try='test -s conftest.$ac_objext'
10275 { (eval echo "$as_me:10275: \"$ac_try\"") >&5
10276 (eval $ac_try) 2>&5
10278 echo "$as_me:10278: \$? = $ac_status" >&5
10279 (exit $ac_status); }; }; then
10282 echo "$as_me: failed program was:" >&5
10283 cat conftest.$ac_ext >&5
10286 rm -f conftest.$ac_objext conftest.$ac_ext
10287 CPPFLAGS=$cf_save_CPPFLAGS
10292 if test "$cf_have_incdir" = no ; then
10293 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
10295 echo "${as_me:-configure}:10295: testing adding $cf_add_incdir to include-path ..." 1>&5
10297 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
10299 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
10300 test "$cf_top_incdir" = "$cf_add_incdir" && break
10301 cf_add_incdir="$cf_top_incdir"
10314 # Set definitions to allow ifdef'ing for ncurses.h
10316 case $cf_cv_ncurses_header in
10319 cat >>confdefs.h <<\EOF
10320 #define HAVE_NCURSES_H 1
10326 case $cf_cv_ncurses_header in
10327 (ncurses/curses.h|ncurses/ncurses.h)
10329 cat >>confdefs.h <<\EOF
10330 #define HAVE_NCURSES_NCURSES_H 1
10334 (ncursesw/curses.h|ncursesw/ncurses.h)
10336 cat >>confdefs.h <<\EOF
10337 #define HAVE_NCURSESW_NCURSES_H 1
10343 echo "$as_me:10343: checking for terminfo header" >&5
10344 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
10345 if test "${cf_cv_term_header+set}" = set; then
10346 echo $ECHO_N "(cached) $ECHO_C" >&6
10349 case ${cf_cv_ncurses_header} in
10350 (*/ncurses.h|*/ncursesw.h)
10351 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
10354 cf_term_header=term.h
10358 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
10360 cat >conftest.$ac_ext <<_ACEOF
10361 #line 10361 "configure"
10362 #include "confdefs.h"
10364 #include <${cf_cv_ncurses_header:-curses.h}>
10365 #include <$cf_test>
10370 int x = auto_left_margin
10375 rm -f conftest.$ac_objext
10376 if { (eval echo "$as_me:10376: \"$ac_compile\"") >&5
10377 (eval $ac_compile) 2>&5
10379 echo "$as_me:10379: \$? = $ac_status" >&5
10380 (exit $ac_status); } &&
10381 { ac_try='test -s conftest.$ac_objext'
10382 { (eval echo "$as_me:10382: \"$ac_try\"") >&5
10383 (eval $ac_try) 2>&5
10385 echo "$as_me:10385: \$? = $ac_status" >&5
10386 (exit $ac_status); }; }; then
10388 cf_cv_term_header="$cf_test"
10390 echo "$as_me: failed program was:" >&5
10391 cat conftest.$ac_ext >&5
10393 cf_cv_term_header=unknown
10396 rm -f conftest.$ac_objext conftest.$ac_ext
10397 test "$cf_cv_term_header" != unknown && break
10401 echo "$as_me:10401: result: $cf_cv_term_header" >&5
10402 echo "${ECHO_T}$cf_cv_term_header" >&6
10404 # Set definitions to allow ifdef'ing to accommodate subdirectories
10406 case $cf_cv_term_header in
10409 cat >>confdefs.h <<\EOF
10410 #define HAVE_TERM_H 1
10416 case $cf_cv_term_header in
10419 cat >>confdefs.h <<\EOF
10420 #define HAVE_NCURSES_TERM_H 1
10426 cat >>confdefs.h <<\EOF
10427 #define HAVE_NCURSESW_TERM_H 1
10433 # some applications need this, but should check for NCURSES_VERSION
10435 cat >>confdefs.h <<\EOF
10439 echo "$as_me:10439: checking for ncurses version" >&5
10440 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
10441 if test "${cf_cv_ncurses_version+set}" = set; then
10442 echo $ECHO_N "(cached) $ECHO_C" >&6
10445 cf_cv_ncurses_version=no
10448 if test "$cross_compiling" = yes; then
10450 # This will not work if the preprocessor splits the line after the
10451 # Autoconf token. The 'unproto' program does that.
10452 cat > conftest.$ac_ext <<EOF
10453 #include <${cf_cv_ncurses_header:-curses.h}>
10455 #ifdef NCURSES_VERSION
10456 Autoconf NCURSES_VERSION
10464 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
10465 { (eval echo "$as_me:10465: \"$cf_try\"") >&5
10466 (eval $cf_try) 2>&5
10468 echo "$as_me:10468: \$? = $ac_status" >&5
10469 (exit $ac_status); }
10470 if test -f conftest.out ; then
10471 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
10472 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
10477 cat >conftest.$ac_ext <<_ACEOF
10478 #line 10478 "configure"
10479 #include "confdefs.h"
10481 #include <${cf_cv_ncurses_header:-curses.h}>
10485 FILE *fp = fopen("$cf_tempfile", "w");
10486 #ifdef NCURSES_VERSION
10487 # ifdef NCURSES_VERSION_PATCH
10488 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
10490 fprintf(fp, "%s\n", NCURSES_VERSION);
10493 # ifdef __NCURSES_H
10494 fprintf(fp, "old\n");
10499 ${cf_cv_main_return:-return}(0);
10502 rm -f conftest$ac_exeext
10503 if { (eval echo "$as_me:10503: \"$ac_link\"") >&5
10504 (eval $ac_link) 2>&5
10506 echo "$as_me:10506: \$? = $ac_status" >&5
10507 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
10508 { (eval echo "$as_me:10508: \"$ac_try\"") >&5
10509 (eval $ac_try) 2>&5
10511 echo "$as_me:10511: \$? = $ac_status" >&5
10512 (exit $ac_status); }; }; then
10514 cf_cv_ncurses_version=`cat $cf_tempfile`
10516 echo "$as_me: program exited with status $ac_status" >&5
10517 echo "$as_me: failed program was:" >&5
10518 cat conftest.$ac_ext >&5
10520 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
10525 echo "$as_me:10525: result: $cf_cv_ncurses_version" >&5
10526 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
10527 test "$cf_cv_ncurses_version" = no ||
10528 cat >>confdefs.h <<\EOF
10532 cf_nculib_root=$cf_cv_screen
10533 # This works, except for the special case where we find gpm, but
10534 # ncurses is in a nonstandard location via $LIBS, and we really want
10537 cf_ncurses_SAVE="$LIBS"
10538 echo "$as_me:10538: checking for Gpm_Open in -lgpm" >&5
10539 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
10540 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
10541 echo $ECHO_N "(cached) $ECHO_C" >&6
10543 ac_check_lib_save_LIBS=$LIBS
10545 cat >conftest.$ac_ext <<_ACEOF
10546 #line 10546 "configure"
10547 #include "confdefs.h"
10549 /* Override any gcc2 internal prototype to avoid an error. */
10553 /* We use char because int might match the return type of a gcc2
10554 builtin and then its argument prototype would still apply. */
10564 rm -f conftest.$ac_objext conftest$ac_exeext
10565 if { (eval echo "$as_me:10565: \"$ac_link\"") >&5
10566 (eval $ac_link) 2>&5
10568 echo "$as_me:10568: \$? = $ac_status" >&5
10569 (exit $ac_status); } &&
10570 { ac_try='test -s conftest$ac_exeext'
10571 { (eval echo "$as_me:10571: \"$ac_try\"") >&5
10572 (eval $ac_try) 2>&5
10574 echo "$as_me:10574: \$? = $ac_status" >&5
10575 (exit $ac_status); }; }; then
10576 ac_cv_lib_gpm_Gpm_Open=yes
10578 echo "$as_me: failed program was:" >&5
10579 cat conftest.$ac_ext >&5
10580 ac_cv_lib_gpm_Gpm_Open=no
10582 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10583 LIBS=$ac_check_lib_save_LIBS
10585 echo "$as_me:10585: result: $ac_cv_lib_gpm_Gpm_Open" >&5
10586 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
10587 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
10588 echo "$as_me:10588: checking for initscr in -lgpm" >&5
10589 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
10590 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
10591 echo $ECHO_N "(cached) $ECHO_C" >&6
10593 ac_check_lib_save_LIBS=$LIBS
10595 cat >conftest.$ac_ext <<_ACEOF
10596 #line 10596 "configure"
10597 #include "confdefs.h"
10599 /* Override any gcc2 internal prototype to avoid an error. */
10603 /* We use char because int might match the return type of a gcc2
10604 builtin and then its argument prototype would still apply. */
10614 rm -f conftest.$ac_objext conftest$ac_exeext
10615 if { (eval echo "$as_me:10615: \"$ac_link\"") >&5
10616 (eval $ac_link) 2>&5
10618 echo "$as_me:10618: \$? = $ac_status" >&5
10619 (exit $ac_status); } &&
10620 { ac_try='test -s conftest$ac_exeext'
10621 { (eval echo "$as_me:10621: \"$ac_try\"") >&5
10622 (eval $ac_try) 2>&5
10624 echo "$as_me:10624: \$? = $ac_status" >&5
10625 (exit $ac_status); }; }; then
10626 ac_cv_lib_gpm_initscr=yes
10628 echo "$as_me: failed program was:" >&5
10629 cat conftest.$ac_ext >&5
10630 ac_cv_lib_gpm_initscr=no
10632 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10633 LIBS=$ac_check_lib_save_LIBS
10635 echo "$as_me:10635: result: $ac_cv_lib_gpm_initscr" >&5
10636 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
10637 if test $ac_cv_lib_gpm_initscr = yes; then
10638 LIBS="$cf_ncurses_SAVE"
10640 cf_ncurses_LIBS="-lgpm"
10647 # This is only necessary if you are linking against an obsolete
10648 # version of ncurses (but it should do no harm, since it's static).
10649 if test "$cf_nculib_root" = ncurses ; then
10650 echo "$as_me:10650: checking for tgoto in -lmytinfo" >&5
10651 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
10652 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
10653 echo $ECHO_N "(cached) $ECHO_C" >&6
10655 ac_check_lib_save_LIBS=$LIBS
10656 LIBS="-lmytinfo $LIBS"
10657 cat >conftest.$ac_ext <<_ACEOF
10658 #line 10658 "configure"
10659 #include "confdefs.h"
10661 /* Override any gcc2 internal prototype to avoid an error. */
10665 /* We use char because int might match the return type of a gcc2
10666 builtin and then its argument prototype would still apply. */
10676 rm -f conftest.$ac_objext conftest$ac_exeext
10677 if { (eval echo "$as_me:10677: \"$ac_link\"") >&5
10678 (eval $ac_link) 2>&5
10680 echo "$as_me:10680: \$? = $ac_status" >&5
10681 (exit $ac_status); } &&
10682 { ac_try='test -s conftest$ac_exeext'
10683 { (eval echo "$as_me:10683: \"$ac_try\"") >&5
10684 (eval $ac_try) 2>&5
10686 echo "$as_me:10686: \$? = $ac_status" >&5
10687 (exit $ac_status); }; }; then
10688 ac_cv_lib_mytinfo_tgoto=yes
10690 echo "$as_me: failed program was:" >&5
10691 cat conftest.$ac_ext >&5
10692 ac_cv_lib_mytinfo_tgoto=no
10694 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10695 LIBS=$ac_check_lib_save_LIBS
10697 echo "$as_me:10697: result: $ac_cv_lib_mytinfo_tgoto" >&5
10698 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
10699 if test $ac_cv_lib_mytinfo_tgoto = yes; then
10700 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
10707 cf_add_libs="$cf_ncurses_LIBS"
10708 # Filter out duplicates - this happens with badly-designed ".pc" files...
10709 for cf_add_1lib in $LIBS
10711 for cf_add_2lib in $cf_add_libs
10713 if test "x$cf_add_1lib" = "x$cf_add_2lib"
10719 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
10721 LIBS="$cf_add_libs"
10723 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
10726 cf_add_libs="-l$cf_nculib_root"
10727 # Filter out duplicates - this happens with badly-designed ".pc" files...
10728 for cf_add_1lib in $LIBS
10730 for cf_add_2lib in $cf_add_libs
10732 if test "x$cf_add_1lib" = "x$cf_add_2lib"
10738 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
10740 LIBS="$cf_add_libs"
10744 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
10746 echo "$as_me:10746: checking for initscr" >&5
10747 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
10748 if test "${ac_cv_func_initscr+set}" = set; then
10749 echo $ECHO_N "(cached) $ECHO_C" >&6
10751 cat >conftest.$ac_ext <<_ACEOF
10752 #line 10752 "configure"
10753 #include "confdefs.h"
10754 #define initscr autoconf_temporary
10755 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
10762 /* We use char because int might match the return type of a gcc2
10763 builtin and then its argument prototype would still apply. */
10764 char initscr (void);
10770 /* The GNU C library defines stubs for functions which it implements
10771 to always fail with ENOSYS. Some functions are actually named
10772 something starting with __ and the normal name is an alias. */
10773 #if defined (__stub_initscr) || defined (__stub___initscr)
10774 #error found stub for initscr
10782 rm -f conftest.$ac_objext conftest$ac_exeext
10783 if { (eval echo "$as_me:10783: \"$ac_link\"") >&5
10784 (eval $ac_link) 2>&5
10786 echo "$as_me:10786: \$? = $ac_status" >&5
10787 (exit $ac_status); } &&
10788 { ac_try='test -s conftest$ac_exeext'
10789 { (eval echo "$as_me:10789: \"$ac_try\"") >&5
10790 (eval $ac_try) 2>&5
10792 echo "$as_me:10792: \$? = $ac_status" >&5
10793 (exit $ac_status); }; }; then
10794 ac_cv_func_initscr=yes
10796 echo "$as_me: failed program was:" >&5
10797 cat conftest.$ac_ext >&5
10798 ac_cv_func_initscr=no
10800 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10802 echo "$as_me:10802: result: $ac_cv_func_initscr" >&5
10803 echo "${ECHO_T}$ac_cv_func_initscr" >&6
10804 if test $ac_cv_func_initscr = yes; then
10805 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
10808 cf_save_LIBS="$LIBS"
10809 echo "$as_me:10809: checking for initscr in -l$cf_nculib_root" >&5
10810 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
10811 LIBS="-l$cf_nculib_root $LIBS"
10812 cat >conftest.$ac_ext <<_ACEOF
10813 #line 10813 "configure"
10814 #include "confdefs.h"
10815 #include <${cf_cv_ncurses_header:-curses.h}>
10824 rm -f conftest.$ac_objext conftest$ac_exeext
10825 if { (eval echo "$as_me:10825: \"$ac_link\"") >&5
10826 (eval $ac_link) 2>&5
10828 echo "$as_me:10828: \$? = $ac_status" >&5
10829 (exit $ac_status); } &&
10830 { ac_try='test -s conftest$ac_exeext'
10831 { (eval echo "$as_me:10831: \"$ac_try\"") >&5
10832 (eval $ac_try) 2>&5
10834 echo "$as_me:10834: \$? = $ac_status" >&5
10835 (exit $ac_status); }; }; then
10836 echo "$as_me:10836: result: yes" >&5
10837 echo "${ECHO_T}yes" >&6
10838 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
10841 echo "$as_me: failed program was:" >&5
10842 cat conftest.$ac_ext >&5
10843 echo "$as_me:10843: result: no" >&5
10844 echo "${ECHO_T}no" >&6
10847 cf_library_path_list=""
10848 if test -n "${LDFLAGS}${LIBS}" ; then
10849 for cf_library_path in $LDFLAGS $LIBS
10851 case $cf_library_path in
10853 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
10855 test "x$cf_library_path" != "xNONE" && \
10856 test -d "$cf_library_path" && \
10858 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
10859 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
10860 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
10861 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
10862 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
10863 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"
10866 cf_library_path_list="$cf_library_path_list $cf_search"
10874 test "x$prefix" != "xNONE" && \
10875 test -d "$prefix" && \
10877 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
10878 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
10879 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
10880 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
10881 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
10882 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
10885 for cf_subdir_prefix in \
10894 test "x$cf_subdir_prefix" != "x$prefix" && \
10895 test -d "$cf_subdir_prefix" && \
10896 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
10897 test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
10898 test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib"
10899 test -d $cf_subdir_prefix/lib/$cf_nculib_root && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root"
10900 test -d $cf_subdir_prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root/lib"
10901 test -d $cf_subdir_prefix/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib"
10902 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"
10907 cf_search="$cf_library_path_list $cf_search"
10909 for cf_libdir in $cf_search
10911 echo "$as_me:10911: checking for -l$cf_nculib_root in $cf_libdir" >&5
10912 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
10913 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
10914 cat >conftest.$ac_ext <<_ACEOF
10915 #line 10915 "configure"
10916 #include "confdefs.h"
10917 #include <${cf_cv_ncurses_header:-curses.h}>
10926 rm -f conftest.$ac_objext conftest$ac_exeext
10927 if { (eval echo "$as_me:10927: \"$ac_link\"") >&5
10928 (eval $ac_link) 2>&5
10930 echo "$as_me:10930: \$? = $ac_status" >&5
10931 (exit $ac_status); } &&
10932 { ac_try='test -s conftest$ac_exeext'
10933 { (eval echo "$as_me:10933: \"$ac_try\"") >&5
10934 (eval $ac_try) 2>&5
10936 echo "$as_me:10936: \$? = $ac_status" >&5
10937 (exit $ac_status); }; }; then
10938 echo "$as_me:10938: result: yes" >&5
10939 echo "${ECHO_T}yes" >&6
10940 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
10943 echo "$as_me: failed program was:" >&5
10944 cat conftest.$ac_ext >&5
10945 echo "$as_me:10945: result: no" >&5
10946 echo "${ECHO_T}no" >&6
10947 LIBS="$cf_save_LIBS"
10949 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10953 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10957 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
10959 if test $cf_found_library = no ; then
10960 { { echo "$as_me:10960: error: Cannot link $cf_nculib_root library" >&5
10961 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
10962 { (exit 1); exit 1; }; }
10967 if test -n "$cf_ncurses_LIBS" ; then
10968 echo "$as_me:10968: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
10969 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
10970 cf_ncurses_SAVE="$LIBS"
10971 for p in $cf_ncurses_LIBS ; do
10972 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
10973 if test "$q" != "$LIBS" ; then
10977 cat >conftest.$ac_ext <<_ACEOF
10978 #line 10978 "configure"
10979 #include "confdefs.h"
10980 #include <${cf_cv_ncurses_header:-curses.h}>
10984 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
10989 rm -f conftest.$ac_objext conftest$ac_exeext
10990 if { (eval echo "$as_me:10990: \"$ac_link\"") >&5
10991 (eval $ac_link) 2>&5
10993 echo "$as_me:10993: \$? = $ac_status" >&5
10994 (exit $ac_status); } &&
10995 { ac_try='test -s conftest$ac_exeext'
10996 { (eval echo "$as_me:10996: \"$ac_try\"") >&5
10997 (eval $ac_try) 2>&5
10999 echo "$as_me:10999: \$? = $ac_status" >&5
11000 (exit $ac_status); }; }; then
11001 echo "$as_me:11001: result: yes" >&5
11002 echo "${ECHO_T}yes" >&6
11004 echo "$as_me: failed program was:" >&5
11005 cat conftest.$ac_ext >&5
11006 echo "$as_me:11006: result: no" >&5
11007 echo "${ECHO_T}no" >&6
11008 LIBS="$cf_ncurses_SAVE"
11010 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11013 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
11015 cat >>confdefs.h <<EOF
11016 #define $cf_nculib_ROOT 1
11021 NCURSES_CONFIG=none
11026 echo "$as_me:11026: checking for X" >&5
11027 echo $ECHO_N "checking for X... $ECHO_C" >&6
11029 # Check whether --with-x or --without-x was given.
11030 if test "${with_x+set}" = set; then
11034 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
11035 if test "x$with_x" = xno; then
11036 # The user explicitly disabled X.
11039 if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
11040 # Both variables are already set.
11043 if test "${ac_cv_have_x+set}" = set; then
11044 echo $ECHO_N "(cached) $ECHO_C" >&6
11046 # One or both of the vars are not set, and there is no cached value.
11047 ac_x_includes=no ac_x_libraries=no
11048 rm -fr conftest.dir
11049 if mkdir conftest.dir; then
11051 # Make sure to not put "make" in the Imakefile rules, since we grep it out.
11052 cat >Imakefile <<'EOF'
11054 @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
11056 if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
11057 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
11058 eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
11059 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
11060 for ac_extension in a so sl dylib dll; do
11061 if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
11062 test -f $ac_im_libdir/libX11.$ac_extension; then
11063 ac_im_usrlibdir=$ac_im_libdir; break
11066 # Screen out bogus values from the imake configuration. They are
11067 # bogus both because they are the default anyway, and because
11068 # using them would break gcc on systems where it needs fixed includes.
11069 case $ac_im_incroot in
11071 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
11073 case $ac_im_usrlibdir in
11074 /usr/lib | /lib) ;;
11075 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
11079 rm -fr conftest.dir
11082 # Standard set of common directories for X headers.
11083 # Check X11 before X11Rn because it is often a symlink to the current release.
11095 /usr/local/X11/include
11096 /usr/local/X11R6/include
11097 /usr/local/X11R5/include
11098 /usr/local/X11R4/include
11100 /usr/local/include/X11
11101 /usr/local/include/X11R6
11102 /usr/local/include/X11R5
11103 /usr/local/include/X11R4
11107 /usr/XFree86/include/X11
11111 /usr/unsupported/include
11112 /usr/athena/include
11113 /usr/local/x11r5/include
11114 /usr/lpp/Xamples/include
11116 /usr/openwin/include
11117 /usr/openwin/share/include'
11119 if test "$ac_x_includes" = no; then
11120 # Guess where to find include files, by looking for Intrinsic.h.
11121 # First, try using that file with no special directory specified.
11122 cat >conftest.$ac_ext <<_ACEOF
11123 #line 11123 "configure"
11124 #include "confdefs.h"
11125 #include <X11/Intrinsic.h>
11127 if { (eval echo "$as_me:11127: \"$ac_cpp conftest.$ac_ext\"") >&5
11128 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11130 egrep -v '^ *\+' conftest.er1 >conftest.err
11132 cat conftest.err >&5
11133 echo "$as_me:11133: \$? = $ac_status" >&5
11134 (exit $ac_status); } >/dev/null; then
11135 if test -s conftest.err; then
11136 ac_cpp_err=$ac_c_preproc_warn_flag
11143 if test -z "$ac_cpp_err"; then
11144 # We can compile using X headers with no special include directory.
11147 echo "$as_me: failed program was:" >&5
11148 cat conftest.$ac_ext >&5
11149 for ac_dir in $ac_x_header_dirs; do
11150 if test -r "$ac_dir/X11/Intrinsic.h"; then
11151 ac_x_includes=$ac_dir
11156 rm -f conftest.err conftest.$ac_ext
11157 fi # $ac_x_includes = no
11159 if test "$ac_x_libraries" = no; then
11160 # Check for the libraries.
11161 # See if we find them without any special options.
11162 # Don't add to $LIBS permanently.
11165 cat >conftest.$ac_ext <<_ACEOF
11166 #line 11166 "configure"
11167 #include "confdefs.h"
11168 #include <X11/Intrinsic.h>
11177 rm -f conftest.$ac_objext conftest$ac_exeext
11178 if { (eval echo "$as_me:11178: \"$ac_link\"") >&5
11179 (eval $ac_link) 2>&5
11181 echo "$as_me:11181: \$? = $ac_status" >&5
11182 (exit $ac_status); } &&
11183 { ac_try='test -s conftest$ac_exeext'
11184 { (eval echo "$as_me:11184: \"$ac_try\"") >&5
11185 (eval $ac_try) 2>&5
11187 echo "$as_me:11187: \$? = $ac_status" >&5
11188 (exit $ac_status); }; }; then
11190 # We can link X programs with no special library path.
11193 echo "$as_me: failed program was:" >&5
11194 cat conftest.$ac_ext >&5
11196 for ac_dir in `echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
11198 # Don't even attempt the hair of trying to link an X program!
11199 for ac_extension in a so sl dylib dll; do
11200 if test -r $ac_dir/libXt.$ac_extension; then
11201 ac_x_libraries=$ac_dir
11207 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11208 fi # $ac_x_libraries = no
11210 if test "$ac_x_includes" = no || test "$ac_x_libraries" = no; then
11211 # Didn't find X anywhere. Cache the known absence of X.
11212 ac_cv_have_x="have_x=no"
11214 # Record where we found X for the cache.
11215 ac_cv_have_x="have_x=yes \
11216 ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
11221 eval "$ac_cv_have_x"
11224 if test "$have_x" != yes; then
11225 echo "$as_me:11225: result: $have_x" >&5
11226 echo "${ECHO_T}$have_x" >&6
11229 # If each of the values was on the command line, it overrides each guess.
11230 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
11231 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
11232 # Update the cache value to reflect the command line values.
11233 ac_cv_have_x="have_x=yes \
11234 ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
11235 echo "$as_me:11235: result: libraries $x_libraries, headers $x_includes" >&5
11236 echo "${ECHO_T}libraries $x_libraries, headers $x_includes" >&6
11239 if test "$no_x" = yes; then
11240 # Not all programs may use this symbol, but it does not hurt to define it.
11242 cat >>confdefs.h <<\EOF
11243 #define X_DISPLAY_MISSING 1
11246 X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS=
11248 if test -n "$x_includes"; then
11249 X_CFLAGS="$X_CFLAGS -I$x_includes"
11252 # It would also be nice to do this for all -L options, not just this one.
11253 if test -n "$x_libraries"; then
11254 X_LIBS="$X_LIBS -L$x_libraries"
11255 # For Solaris; some versions of Sun CC require a space after -R and
11256 # others require no space. Words are not sufficient . . . .
11257 case `(uname -sr) 2>/dev/null` in
11259 echo "$as_me:11259: checking whether -R must be followed by a space" >&5
11260 echo $ECHO_N "checking whether -R must be followed by a space... $ECHO_C" >&6
11261 ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries"
11262 cat >conftest.$ac_ext <<_ACEOF
11263 #line 11263 "configure"
11264 #include "confdefs.h"
11274 rm -f conftest.$ac_objext conftest$ac_exeext
11275 if { (eval echo "$as_me:11275: \"$ac_link\"") >&5
11276 (eval $ac_link) 2>&5
11278 echo "$as_me:11278: \$? = $ac_status" >&5
11279 (exit $ac_status); } &&
11280 { ac_try='test -s conftest$ac_exeext'
11281 { (eval echo "$as_me:11281: \"$ac_try\"") >&5
11282 (eval $ac_try) 2>&5
11284 echo "$as_me:11284: \$? = $ac_status" >&5
11285 (exit $ac_status); }; }; then
11288 echo "$as_me: failed program was:" >&5
11289 cat conftest.$ac_ext >&5
11292 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11293 if test $ac_R_nospace = yes; then
11294 echo "$as_me:11294: result: no" >&5
11295 echo "${ECHO_T}no" >&6
11296 X_LIBS="$X_LIBS -R$x_libraries"
11298 LIBS="$ac_xsave_LIBS -R $x_libraries"
11299 cat >conftest.$ac_ext <<_ACEOF
11300 #line 11300 "configure"
11301 #include "confdefs.h"
11311 rm -f conftest.$ac_objext conftest$ac_exeext
11312 if { (eval echo "$as_me:11312: \"$ac_link\"") >&5
11313 (eval $ac_link) 2>&5
11315 echo "$as_me:11315: \$? = $ac_status" >&5
11316 (exit $ac_status); } &&
11317 { ac_try='test -s conftest$ac_exeext'
11318 { (eval echo "$as_me:11318: \"$ac_try\"") >&5
11319 (eval $ac_try) 2>&5
11321 echo "$as_me:11321: \$? = $ac_status" >&5
11322 (exit $ac_status); }; }; then
11325 echo "$as_me: failed program was:" >&5
11326 cat conftest.$ac_ext >&5
11329 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11330 if test $ac_R_space = yes; then
11331 echo "$as_me:11331: result: yes" >&5
11332 echo "${ECHO_T}yes" >&6
11333 X_LIBS="$X_LIBS -R $x_libraries"
11335 echo "$as_me:11335: result: neither works" >&5
11336 echo "${ECHO_T}neither works" >&6
11339 LIBS=$ac_xsave_LIBS
11343 # Check for system-dependent libraries X programs must link with.
11344 # Do this before checking for the system-independent R6 libraries
11345 # (-lICE), since we may need -lsocket or whatever for X linking.
11347 if test "$ISC" = yes; then
11348 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
11350 # Martyn Johnson says this is needed for Ultrix, if the X
11351 # libraries were built with DECnet support. And Karl Berry says
11352 # the Alpha needs dnet_stub (dnet does not exist).
11353 ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11"
11354 cat >conftest.$ac_ext <<_ACEOF
11355 #line 11355 "configure"
11356 #include "confdefs.h"
11358 /* Override any gcc2 internal prototype to avoid an error. */
11362 /* We use char because int might match the return type of a gcc2
11363 builtin and then its argument prototype would still apply. */
11364 char XOpenDisplay ();
11373 rm -f conftest.$ac_objext conftest$ac_exeext
11374 if { (eval echo "$as_me:11374: \"$ac_link\"") >&5
11375 (eval $ac_link) 2>&5
11377 echo "$as_me:11377: \$? = $ac_status" >&5
11378 (exit $ac_status); } &&
11379 { ac_try='test -s conftest$ac_exeext'
11380 { (eval echo "$as_me:11380: \"$ac_try\"") >&5
11381 (eval $ac_try) 2>&5
11383 echo "$as_me:11383: \$? = $ac_status" >&5
11384 (exit $ac_status); }; }; then
11387 echo "$as_me: failed program was:" >&5
11388 cat conftest.$ac_ext >&5
11389 echo "$as_me:11389: checking for dnet_ntoa in -ldnet" >&5
11390 echo $ECHO_N "checking for dnet_ntoa in -ldnet... $ECHO_C" >&6
11391 if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then
11392 echo $ECHO_N "(cached) $ECHO_C" >&6
11394 ac_check_lib_save_LIBS=$LIBS
11395 LIBS="-ldnet $LIBS"
11396 cat >conftest.$ac_ext <<_ACEOF
11397 #line 11397 "configure"
11398 #include "confdefs.h"
11400 /* Override any gcc2 internal prototype to avoid an error. */
11404 /* We use char because int might match the return type of a gcc2
11405 builtin and then its argument prototype would still apply. */
11415 rm -f conftest.$ac_objext conftest$ac_exeext
11416 if { (eval echo "$as_me:11416: \"$ac_link\"") >&5
11417 (eval $ac_link) 2>&5
11419 echo "$as_me:11419: \$? = $ac_status" >&5
11420 (exit $ac_status); } &&
11421 { ac_try='test -s conftest$ac_exeext'
11422 { (eval echo "$as_me:11422: \"$ac_try\"") >&5
11423 (eval $ac_try) 2>&5
11425 echo "$as_me:11425: \$? = $ac_status" >&5
11426 (exit $ac_status); }; }; then
11427 ac_cv_lib_dnet_dnet_ntoa=yes
11429 echo "$as_me: failed program was:" >&5
11430 cat conftest.$ac_ext >&5
11431 ac_cv_lib_dnet_dnet_ntoa=no
11433 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11434 LIBS=$ac_check_lib_save_LIBS
11436 echo "$as_me:11436: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
11437 echo "${ECHO_T}$ac_cv_lib_dnet_dnet_ntoa" >&6
11438 if test $ac_cv_lib_dnet_dnet_ntoa = yes; then
11439 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
11442 if test $ac_cv_lib_dnet_dnet_ntoa = no; then
11443 echo "$as_me:11443: checking for dnet_ntoa in -ldnet_stub" >&5
11444 echo $ECHO_N "checking for dnet_ntoa in -ldnet_stub... $ECHO_C" >&6
11445 if test "${ac_cv_lib_dnet_stub_dnet_ntoa+set}" = set; then
11446 echo $ECHO_N "(cached) $ECHO_C" >&6
11448 ac_check_lib_save_LIBS=$LIBS
11449 LIBS="-ldnet_stub $LIBS"
11450 cat >conftest.$ac_ext <<_ACEOF
11451 #line 11451 "configure"
11452 #include "confdefs.h"
11454 /* Override any gcc2 internal prototype to avoid an error. */
11458 /* We use char because int might match the return type of a gcc2
11459 builtin and then its argument prototype would still apply. */
11469 rm -f conftest.$ac_objext conftest$ac_exeext
11470 if { (eval echo "$as_me:11470: \"$ac_link\"") >&5
11471 (eval $ac_link) 2>&5
11473 echo "$as_me:11473: \$? = $ac_status" >&5
11474 (exit $ac_status); } &&
11475 { ac_try='test -s conftest$ac_exeext'
11476 { (eval echo "$as_me:11476: \"$ac_try\"") >&5
11477 (eval $ac_try) 2>&5
11479 echo "$as_me:11479: \$? = $ac_status" >&5
11480 (exit $ac_status); }; }; then
11481 ac_cv_lib_dnet_stub_dnet_ntoa=yes
11483 echo "$as_me: failed program was:" >&5
11484 cat conftest.$ac_ext >&5
11485 ac_cv_lib_dnet_stub_dnet_ntoa=no
11487 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11488 LIBS=$ac_check_lib_save_LIBS
11490 echo "$as_me:11490: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5
11491 echo "${ECHO_T}$ac_cv_lib_dnet_stub_dnet_ntoa" >&6
11492 if test $ac_cv_lib_dnet_stub_dnet_ntoa = yes; then
11493 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
11498 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11499 LIBS="$ac_xsave_LIBS"
11501 # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT,
11502 # to get the SysV transport functions.
11503 # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4)
11505 # The nsl library prevents programs from opening the X display
11506 # on Irix 5.2, according to T.E. Dickey.
11507 # The functions gethostbyname, getservbyname, and inet_addr are
11508 # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking.
11509 echo "$as_me:11509: checking for gethostbyname" >&5
11510 echo $ECHO_N "checking for gethostbyname... $ECHO_C" >&6
11511 if test "${ac_cv_func_gethostbyname+set}" = set; then
11512 echo $ECHO_N "(cached) $ECHO_C" >&6
11514 cat >conftest.$ac_ext <<_ACEOF
11515 #line 11515 "configure"
11516 #include "confdefs.h"
11517 #define gethostbyname autoconf_temporary
11518 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
11519 #undef gethostbyname
11525 /* We use char because int might match the return type of a gcc2
11526 builtin and then its argument prototype would still apply. */
11527 char gethostbyname (void);
11533 /* The GNU C library defines stubs for functions which it implements
11534 to always fail with ENOSYS. Some functions are actually named
11535 something starting with __ and the normal name is an alias. */
11536 #if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
11537 #error found stub for gethostbyname
11540 return gethostbyname ();
11545 rm -f conftest.$ac_objext conftest$ac_exeext
11546 if { (eval echo "$as_me:11546: \"$ac_link\"") >&5
11547 (eval $ac_link) 2>&5
11549 echo "$as_me:11549: \$? = $ac_status" >&5
11550 (exit $ac_status); } &&
11551 { ac_try='test -s conftest$ac_exeext'
11552 { (eval echo "$as_me:11552: \"$ac_try\"") >&5
11553 (eval $ac_try) 2>&5
11555 echo "$as_me:11555: \$? = $ac_status" >&5
11556 (exit $ac_status); }; }; then
11557 ac_cv_func_gethostbyname=yes
11559 echo "$as_me: failed program was:" >&5
11560 cat conftest.$ac_ext >&5
11561 ac_cv_func_gethostbyname=no
11563 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11565 echo "$as_me:11565: result: $ac_cv_func_gethostbyname" >&5
11566 echo "${ECHO_T}$ac_cv_func_gethostbyname" >&6
11568 if test $ac_cv_func_gethostbyname = no; then
11569 echo "$as_me:11569: checking for gethostbyname in -lnsl" >&5
11570 echo $ECHO_N "checking for gethostbyname in -lnsl... $ECHO_C" >&6
11571 if test "${ac_cv_lib_nsl_gethostbyname+set}" = set; then
11572 echo $ECHO_N "(cached) $ECHO_C" >&6
11574 ac_check_lib_save_LIBS=$LIBS
11576 cat >conftest.$ac_ext <<_ACEOF
11577 #line 11577 "configure"
11578 #include "confdefs.h"
11580 /* Override any gcc2 internal prototype to avoid an error. */
11584 /* We use char because int might match the return type of a gcc2
11585 builtin and then its argument prototype would still apply. */
11586 char gethostbyname ();
11595 rm -f conftest.$ac_objext conftest$ac_exeext
11596 if { (eval echo "$as_me:11596: \"$ac_link\"") >&5
11597 (eval $ac_link) 2>&5
11599 echo "$as_me:11599: \$? = $ac_status" >&5
11600 (exit $ac_status); } &&
11601 { ac_try='test -s conftest$ac_exeext'
11602 { (eval echo "$as_me:11602: \"$ac_try\"") >&5
11603 (eval $ac_try) 2>&5
11605 echo "$as_me:11605: \$? = $ac_status" >&5
11606 (exit $ac_status); }; }; then
11607 ac_cv_lib_nsl_gethostbyname=yes
11609 echo "$as_me: failed program was:" >&5
11610 cat conftest.$ac_ext >&5
11611 ac_cv_lib_nsl_gethostbyname=no
11613 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11614 LIBS=$ac_check_lib_save_LIBS
11616 echo "$as_me:11616: result: $ac_cv_lib_nsl_gethostbyname" >&5
11617 echo "${ECHO_T}$ac_cv_lib_nsl_gethostbyname" >&6
11618 if test $ac_cv_lib_nsl_gethostbyname = yes; then
11619 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
11622 if test $ac_cv_lib_nsl_gethostbyname = no; then
11623 echo "$as_me:11623: checking for gethostbyname in -lbsd" >&5
11624 echo $ECHO_N "checking for gethostbyname in -lbsd... $ECHO_C" >&6
11625 if test "${ac_cv_lib_bsd_gethostbyname+set}" = set; then
11626 echo $ECHO_N "(cached) $ECHO_C" >&6
11628 ac_check_lib_save_LIBS=$LIBS
11630 cat >conftest.$ac_ext <<_ACEOF
11631 #line 11631 "configure"
11632 #include "confdefs.h"
11634 /* Override any gcc2 internal prototype to avoid an error. */
11638 /* We use char because int might match the return type of a gcc2
11639 builtin and then its argument prototype would still apply. */
11640 char gethostbyname ();
11649 rm -f conftest.$ac_objext conftest$ac_exeext
11650 if { (eval echo "$as_me:11650: \"$ac_link\"") >&5
11651 (eval $ac_link) 2>&5
11653 echo "$as_me:11653: \$? = $ac_status" >&5
11654 (exit $ac_status); } &&
11655 { ac_try='test -s conftest$ac_exeext'
11656 { (eval echo "$as_me:11656: \"$ac_try\"") >&5
11657 (eval $ac_try) 2>&5
11659 echo "$as_me:11659: \$? = $ac_status" >&5
11660 (exit $ac_status); }; }; then
11661 ac_cv_lib_bsd_gethostbyname=yes
11663 echo "$as_me: failed program was:" >&5
11664 cat conftest.$ac_ext >&5
11665 ac_cv_lib_bsd_gethostbyname=no
11667 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11668 LIBS=$ac_check_lib_save_LIBS
11670 echo "$as_me:11670: result: $ac_cv_lib_bsd_gethostbyname" >&5
11671 echo "${ECHO_T}$ac_cv_lib_bsd_gethostbyname" >&6
11672 if test $ac_cv_lib_bsd_gethostbyname = yes; then
11673 X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd"
11679 # lieder@skyler.mavd.honeywell.com says without -lsocket,
11680 # socket/setsockopt and other routines are undefined under SCO ODT
11681 # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary
11682 # on later versions), says Simon Leinen: it contains gethostby*
11683 # variants that don't use the nameserver (or something). -lsocket
11684 # must be given before -lnsl if both are needed. We assume that
11685 # if connect needs -lnsl, so does gethostbyname.
11686 echo "$as_me:11686: checking for connect" >&5
11687 echo $ECHO_N "checking for connect... $ECHO_C" >&6
11688 if test "${ac_cv_func_connect+set}" = set; then
11689 echo $ECHO_N "(cached) $ECHO_C" >&6
11691 cat >conftest.$ac_ext <<_ACEOF
11692 #line 11692 "configure"
11693 #include "confdefs.h"
11694 #define connect autoconf_temporary
11695 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
11702 /* We use char because int might match the return type of a gcc2
11703 builtin and then its argument prototype would still apply. */
11704 char connect (void);
11710 /* The GNU C library defines stubs for functions which it implements
11711 to always fail with ENOSYS. Some functions are actually named
11712 something starting with __ and the normal name is an alias. */
11713 #if defined (__stub_connect) || defined (__stub___connect)
11714 #error found stub for connect
11722 rm -f conftest.$ac_objext conftest$ac_exeext
11723 if { (eval echo "$as_me:11723: \"$ac_link\"") >&5
11724 (eval $ac_link) 2>&5
11726 echo "$as_me:11726: \$? = $ac_status" >&5
11727 (exit $ac_status); } &&
11728 { ac_try='test -s conftest$ac_exeext'
11729 { (eval echo "$as_me:11729: \"$ac_try\"") >&5
11730 (eval $ac_try) 2>&5
11732 echo "$as_me:11732: \$? = $ac_status" >&5
11733 (exit $ac_status); }; }; then
11734 ac_cv_func_connect=yes
11736 echo "$as_me: failed program was:" >&5
11737 cat conftest.$ac_ext >&5
11738 ac_cv_func_connect=no
11740 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11742 echo "$as_me:11742: result: $ac_cv_func_connect" >&5
11743 echo "${ECHO_T}$ac_cv_func_connect" >&6
11745 if test $ac_cv_func_connect = no; then
11746 echo "$as_me:11746: checking for connect in -lsocket" >&5
11747 echo $ECHO_N "checking for connect in -lsocket... $ECHO_C" >&6
11748 if test "${ac_cv_lib_socket_connect+set}" = set; then
11749 echo $ECHO_N "(cached) $ECHO_C" >&6
11751 ac_check_lib_save_LIBS=$LIBS
11752 LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
11753 cat >conftest.$ac_ext <<_ACEOF
11754 #line 11754 "configure"
11755 #include "confdefs.h"
11757 /* Override any gcc2 internal prototype to avoid an error. */
11761 /* We use char because int might match the return type of a gcc2
11762 builtin and then its argument prototype would still apply. */
11772 rm -f conftest.$ac_objext conftest$ac_exeext
11773 if { (eval echo "$as_me:11773: \"$ac_link\"") >&5
11774 (eval $ac_link) 2>&5
11776 echo "$as_me:11776: \$? = $ac_status" >&5
11777 (exit $ac_status); } &&
11778 { ac_try='test -s conftest$ac_exeext'
11779 { (eval echo "$as_me:11779: \"$ac_try\"") >&5
11780 (eval $ac_try) 2>&5
11782 echo "$as_me:11782: \$? = $ac_status" >&5
11783 (exit $ac_status); }; }; then
11784 ac_cv_lib_socket_connect=yes
11786 echo "$as_me: failed program was:" >&5
11787 cat conftest.$ac_ext >&5
11788 ac_cv_lib_socket_connect=no
11790 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11791 LIBS=$ac_check_lib_save_LIBS
11793 echo "$as_me:11793: result: $ac_cv_lib_socket_connect" >&5
11794 echo "${ECHO_T}$ac_cv_lib_socket_connect" >&6
11795 if test $ac_cv_lib_socket_connect = yes; then
11796 X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS"
11801 # Guillermo Gomez says -lposix is necessary on A/UX.
11802 echo "$as_me:11802: checking for remove" >&5
11803 echo $ECHO_N "checking for remove... $ECHO_C" >&6
11804 if test "${ac_cv_func_remove+set}" = set; then
11805 echo $ECHO_N "(cached) $ECHO_C" >&6
11807 cat >conftest.$ac_ext <<_ACEOF
11808 #line 11808 "configure"
11809 #include "confdefs.h"
11810 #define remove autoconf_temporary
11811 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
11818 /* We use char because int might match the return type of a gcc2
11819 builtin and then its argument prototype would still apply. */
11820 char remove (void);
11826 /* The GNU C library defines stubs for functions which it implements
11827 to always fail with ENOSYS. Some functions are actually named
11828 something starting with __ and the normal name is an alias. */
11829 #if defined (__stub_remove) || defined (__stub___remove)
11830 #error found stub for remove
11838 rm -f conftest.$ac_objext conftest$ac_exeext
11839 if { (eval echo "$as_me:11839: \"$ac_link\"") >&5
11840 (eval $ac_link) 2>&5
11842 echo "$as_me:11842: \$? = $ac_status" >&5
11843 (exit $ac_status); } &&
11844 { ac_try='test -s conftest$ac_exeext'
11845 { (eval echo "$as_me:11845: \"$ac_try\"") >&5
11846 (eval $ac_try) 2>&5
11848 echo "$as_me:11848: \$? = $ac_status" >&5
11849 (exit $ac_status); }; }; then
11850 ac_cv_func_remove=yes
11852 echo "$as_me: failed program was:" >&5
11853 cat conftest.$ac_ext >&5
11854 ac_cv_func_remove=no
11856 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11858 echo "$as_me:11858: result: $ac_cv_func_remove" >&5
11859 echo "${ECHO_T}$ac_cv_func_remove" >&6
11861 if test $ac_cv_func_remove = no; then
11862 echo "$as_me:11862: checking for remove in -lposix" >&5
11863 echo $ECHO_N "checking for remove in -lposix... $ECHO_C" >&6
11864 if test "${ac_cv_lib_posix_remove+set}" = set; then
11865 echo $ECHO_N "(cached) $ECHO_C" >&6
11867 ac_check_lib_save_LIBS=$LIBS
11868 LIBS="-lposix $LIBS"
11869 cat >conftest.$ac_ext <<_ACEOF
11870 #line 11870 "configure"
11871 #include "confdefs.h"
11873 /* Override any gcc2 internal prototype to avoid an error. */
11877 /* We use char because int might match the return type of a gcc2
11878 builtin and then its argument prototype would still apply. */
11888 rm -f conftest.$ac_objext conftest$ac_exeext
11889 if { (eval echo "$as_me:11889: \"$ac_link\"") >&5
11890 (eval $ac_link) 2>&5
11892 echo "$as_me:11892: \$? = $ac_status" >&5
11893 (exit $ac_status); } &&
11894 { ac_try='test -s conftest$ac_exeext'
11895 { (eval echo "$as_me:11895: \"$ac_try\"") >&5
11896 (eval $ac_try) 2>&5
11898 echo "$as_me:11898: \$? = $ac_status" >&5
11899 (exit $ac_status); }; }; then
11900 ac_cv_lib_posix_remove=yes
11902 echo "$as_me: failed program was:" >&5
11903 cat conftest.$ac_ext >&5
11904 ac_cv_lib_posix_remove=no
11906 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11907 LIBS=$ac_check_lib_save_LIBS
11909 echo "$as_me:11909: result: $ac_cv_lib_posix_remove" >&5
11910 echo "${ECHO_T}$ac_cv_lib_posix_remove" >&6
11911 if test $ac_cv_lib_posix_remove = yes; then
11912 X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix"
11917 # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
11918 echo "$as_me:11918: checking for shmat" >&5
11919 echo $ECHO_N "checking for shmat... $ECHO_C" >&6
11920 if test "${ac_cv_func_shmat+set}" = set; then
11921 echo $ECHO_N "(cached) $ECHO_C" >&6
11923 cat >conftest.$ac_ext <<_ACEOF
11924 #line 11924 "configure"
11925 #include "confdefs.h"
11926 #define shmat autoconf_temporary
11927 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
11934 /* We use char because int might match the return type of a gcc2
11935 builtin and then its argument prototype would still apply. */
11942 /* The GNU C library defines stubs for functions which it implements
11943 to always fail with ENOSYS. Some functions are actually named
11944 something starting with __ and the normal name is an alias. */
11945 #if defined (__stub_shmat) || defined (__stub___shmat)
11946 #error found stub for shmat
11954 rm -f conftest.$ac_objext conftest$ac_exeext
11955 if { (eval echo "$as_me:11955: \"$ac_link\"") >&5
11956 (eval $ac_link) 2>&5
11958 echo "$as_me:11958: \$? = $ac_status" >&5
11959 (exit $ac_status); } &&
11960 { ac_try='test -s conftest$ac_exeext'
11961 { (eval echo "$as_me:11961: \"$ac_try\"") >&5
11962 (eval $ac_try) 2>&5
11964 echo "$as_me:11964: \$? = $ac_status" >&5
11965 (exit $ac_status); }; }; then
11966 ac_cv_func_shmat=yes
11968 echo "$as_me: failed program was:" >&5
11969 cat conftest.$ac_ext >&5
11970 ac_cv_func_shmat=no
11972 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11974 echo "$as_me:11974: result: $ac_cv_func_shmat" >&5
11975 echo "${ECHO_T}$ac_cv_func_shmat" >&6
11977 if test $ac_cv_func_shmat = no; then
11978 echo "$as_me:11978: checking for shmat in -lipc" >&5
11979 echo $ECHO_N "checking for shmat in -lipc... $ECHO_C" >&6
11980 if test "${ac_cv_lib_ipc_shmat+set}" = set; then
11981 echo $ECHO_N "(cached) $ECHO_C" >&6
11983 ac_check_lib_save_LIBS=$LIBS
11985 cat >conftest.$ac_ext <<_ACEOF
11986 #line 11986 "configure"
11987 #include "confdefs.h"
11989 /* Override any gcc2 internal prototype to avoid an error. */
11993 /* We use char because int might match the return type of a gcc2
11994 builtin and then its argument prototype would still apply. */
12004 rm -f conftest.$ac_objext conftest$ac_exeext
12005 if { (eval echo "$as_me:12005: \"$ac_link\"") >&5
12006 (eval $ac_link) 2>&5
12008 echo "$as_me:12008: \$? = $ac_status" >&5
12009 (exit $ac_status); } &&
12010 { ac_try='test -s conftest$ac_exeext'
12011 { (eval echo "$as_me:12011: \"$ac_try\"") >&5
12012 (eval $ac_try) 2>&5
12014 echo "$as_me:12014: \$? = $ac_status" >&5
12015 (exit $ac_status); }; }; then
12016 ac_cv_lib_ipc_shmat=yes
12018 echo "$as_me: failed program was:" >&5
12019 cat conftest.$ac_ext >&5
12020 ac_cv_lib_ipc_shmat=no
12022 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12023 LIBS=$ac_check_lib_save_LIBS
12025 echo "$as_me:12025: result: $ac_cv_lib_ipc_shmat" >&5
12026 echo "${ECHO_T}$ac_cv_lib_ipc_shmat" >&6
12027 if test $ac_cv_lib_ipc_shmat = yes; then
12028 X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc"
12034 # Check for libraries that X11R6 Xt/Xaw programs need.
12035 ac_save_LDFLAGS=$LDFLAGS
12036 test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries"
12037 # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
12038 # check for ICE first), but we must link in the order -lSM -lICE or
12039 # we get undefined symbols. So assume we have SM if we have ICE.
12040 # These have to be linked with before -lX11, unlike the other
12041 # libraries we check for below, so use a different variable.
12042 # John Interrante, Karl Berry
12043 echo "$as_me:12043: checking for IceConnectionNumber in -lICE" >&5
12044 echo $ECHO_N "checking for IceConnectionNumber in -lICE... $ECHO_C" >&6
12045 if test "${ac_cv_lib_ICE_IceConnectionNumber+set}" = set; then
12046 echo $ECHO_N "(cached) $ECHO_C" >&6
12048 ac_check_lib_save_LIBS=$LIBS
12049 LIBS="-lICE $X_EXTRA_LIBS $LIBS"
12050 cat >conftest.$ac_ext <<_ACEOF
12051 #line 12051 "configure"
12052 #include "confdefs.h"
12054 /* Override any gcc2 internal prototype to avoid an error. */
12058 /* We use char because int might match the return type of a gcc2
12059 builtin and then its argument prototype would still apply. */
12060 char IceConnectionNumber ();
12064 IceConnectionNumber ();
12069 rm -f conftest.$ac_objext conftest$ac_exeext
12070 if { (eval echo "$as_me:12070: \"$ac_link\"") >&5
12071 (eval $ac_link) 2>&5
12073 echo "$as_me:12073: \$? = $ac_status" >&5
12074 (exit $ac_status); } &&
12075 { ac_try='test -s conftest$ac_exeext'
12076 { (eval echo "$as_me:12076: \"$ac_try\"") >&5
12077 (eval $ac_try) 2>&5
12079 echo "$as_me:12079: \$? = $ac_status" >&5
12080 (exit $ac_status); }; }; then
12081 ac_cv_lib_ICE_IceConnectionNumber=yes
12083 echo "$as_me: failed program was:" >&5
12084 cat conftest.$ac_ext >&5
12085 ac_cv_lib_ICE_IceConnectionNumber=no
12087 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12088 LIBS=$ac_check_lib_save_LIBS
12090 echo "$as_me:12090: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5
12091 echo "${ECHO_T}$ac_cv_lib_ICE_IceConnectionNumber" >&6
12092 if test $ac_cv_lib_ICE_IceConnectionNumber = yes; then
12093 X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
12096 LDFLAGS=$ac_save_LDFLAGS
12100 cf_x_athena=${cf_x_athena:-Xaw}
12102 echo "$as_me:12102: checking if you want to link with Xaw 3d library" >&5
12103 echo $ECHO_N "checking if you want to link with Xaw 3d library... $ECHO_C" >&6
12106 # Check whether --with-Xaw3d or --without-Xaw3d was given.
12107 if test "${with_Xaw3d+set}" = set; then
12108 withval="$with_Xaw3d"
12111 if test "$withval" = yes ; then
12113 echo "$as_me:12113: result: yes" >&5
12114 echo "${ECHO_T}yes" >&6
12116 echo "$as_me:12116: result: no" >&5
12117 echo "${ECHO_T}no" >&6
12120 echo "$as_me:12120: checking if you want to link with Xaw 3d xft library" >&5
12121 echo $ECHO_N "checking if you want to link with Xaw 3d xft library... $ECHO_C" >&6
12124 # Check whether --with-Xaw3dxft or --without-Xaw3dxft was given.
12125 if test "${with_Xaw3dxft+set}" = set; then
12126 withval="$with_Xaw3dxft"
12129 if test "$withval" = yes ; then
12130 cf_x_athena=Xaw3dxft
12131 echo "$as_me:12131: result: yes" >&5
12132 echo "${ECHO_T}yes" >&6
12134 echo "$as_me:12134: result: no" >&5
12135 echo "${ECHO_T}no" >&6
12138 echo "$as_me:12138: checking if you want to link with neXT Athena library" >&5
12139 echo $ECHO_N "checking if you want to link with neXT Athena library... $ECHO_C" >&6
12142 # Check whether --with-neXtaw or --without-neXtaw was given.
12143 if test "${with_neXtaw+set}" = set; then
12144 withval="$with_neXtaw"
12147 if test "$withval" = yes ; then
12149 echo "$as_me:12149: result: yes" >&5
12150 echo "${ECHO_T}yes" >&6
12152 echo "$as_me:12152: result: no" >&5
12153 echo "${ECHO_T}no" >&6
12156 echo "$as_me:12156: checking if you want to link with Athena-Plus library" >&5
12157 echo $ECHO_N "checking if you want to link with Athena-Plus library... $ECHO_C" >&6
12160 # Check whether --with-XawPlus or --without-XawPlus was given.
12161 if test "${with_XawPlus+set}" = set; then
12162 withval="$with_XawPlus"
12165 if test "$withval" = yes ; then
12166 cf_x_athena=XawPlus
12167 echo "$as_me:12167: result: yes" >&5
12168 echo "${ECHO_T}yes" >&6
12170 echo "$as_me:12170: result: no" >&5
12171 echo "${ECHO_T}no" >&6
12176 if test "$PKG_CONFIG" != none ; then
12178 test "$cf_x_athena" = Xaw && cf_athena_list="xaw8 xaw7 xaw6"
12179 for cf_athena_pkg in \
12182 ${cf_x_athena}-devel \
12183 lib${cf_x_athena} \
12184 lib${cf_x_athena}-devel
12187 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists $cf_athena_pkg; then
12188 test -n "$verbose" && echo " found package $cf_athena_pkg" 1>&6
12190 echo "${as_me:-configure}:12190: testing found package $cf_athena_pkg ..." 1>&5
12192 cf_pkgconfig_incs="`$PKG_CONFIG --cflags $cf_athena_pkg 2>/dev/null`"
12193 cf_pkgconfig_libs="`$PKG_CONFIG --libs $cf_athena_pkg 2>/dev/null`"
12194 test -n "$verbose" && echo " package $cf_athena_pkg CFLAGS: $cf_pkgconfig_incs" 1>&6
12196 echo "${as_me:-configure}:12196: testing package $cf_athena_pkg CFLAGS: $cf_pkgconfig_incs ..." 1>&5
12198 test -n "$verbose" && echo " package $cf_athena_pkg LIBS: $cf_pkgconfig_libs" 1>&6
12200 echo "${as_me:-configure}:12200: testing package $cf_athena_pkg LIBS: $cf_pkgconfig_libs ..." 1>&5
12205 cf_new_extra_cppflags=
12207 for cf_add_cflags in $cf_pkgconfig_incs
12209 case $cf_fix_cppflags in
12211 case $cf_add_cflags in
12212 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
12213 case $cf_add_cflags in
12215 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
12217 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12218 && test -z "${cf_tst_cflags}" \
12219 && cf_fix_cppflags=yes
12221 if test $cf_fix_cppflags = yes ; then
12223 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12224 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12227 elif test "${cf_tst_cflags}" = "\"'" ; then
12229 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12230 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12236 case "$CPPFLAGS" in
12240 case $cf_add_cflags in
12242 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12244 CPPFLAGS=`echo "$CPPFLAGS" | \
12245 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12246 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12251 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
12252 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
12259 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
12260 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
12267 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12268 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12270 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
12272 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12273 && test -z "${cf_tst_cflags}" \
12274 && cf_fix_cppflags=no
12279 if test -n "$cf_new_cflags" ; then
12281 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
12282 CFLAGS="${CFLAGS}$cf_new_cflags"
12286 if test -n "$cf_new_cppflags" ; then
12288 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
12289 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
12293 if test -n "$cf_new_extra_cppflags" ; then
12295 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
12296 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
12300 cf_add_libs="$cf_pkgconfig_libs"
12301 # Filter out duplicates - this happens with badly-designed ".pc" files...
12302 for cf_add_1lib in $LIBS
12304 for cf_add_2lib in $cf_add_libs
12306 if test "x$cf_add_1lib" = "x$cf_add_2lib"
12312 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
12314 LIBS="$cf_add_libs"
12316 cf_x_athena_lib="$cf_pkgconfig_libs"
12318 cf_x_athena_LIBS=`echo "HAVE_LIB_$cf_x_athena" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
12320 cat >>confdefs.h <<EOF
12321 #define $cf_x_athena_LIBS 1
12324 for cf_trim_lib in Xmu Xt X11
12327 (*-l$cf_trim_lib\ *-l$cf_trim_lib*)
12328 LIBS=`echo "$LIBS " | sed -e 's/ / /g' -e 's%-l'"$cf_trim_lib"' %%' -e 's/ $//'`
12329 test -n "$verbose" && echo " ..trimmed $LIBS" 1>&6
12331 echo "${as_me:-configure}:12331: testing ..trimmed $LIBS ..." 1>&5
12337 echo "$as_me:12337: checking for usable $cf_x_athena/Xmu package" >&5
12338 echo $ECHO_N "checking for usable $cf_x_athena/Xmu package... $ECHO_C" >&6
12339 if test "${cf_cv_xaw_compat+set}" = set; then
12340 echo $ECHO_N "(cached) $ECHO_C" >&6
12343 cat >conftest.$ac_ext <<_ACEOF
12344 #line 12344 "configure"
12345 #include "confdefs.h"
12347 #include <X11/Xmu/CharSet.h>
12353 int check = XmuCompareISOLatin1("big", "small")
12359 rm -f conftest.$ac_objext conftest$ac_exeext
12360 if { (eval echo "$as_me:12360: \"$ac_link\"") >&5
12361 (eval $ac_link) 2>&5
12363 echo "$as_me:12363: \$? = $ac_status" >&5
12364 (exit $ac_status); } &&
12365 { ac_try='test -s conftest$ac_exeext'
12366 { (eval echo "$as_me:12366: \"$ac_try\"") >&5
12367 (eval $ac_try) 2>&5
12369 echo "$as_me:12369: \$? = $ac_status" >&5
12370 (exit $ac_status); }; }; then
12371 cf_cv_xaw_compat=yes
12373 echo "$as_me: failed program was:" >&5
12374 cat conftest.$ac_ext >&5
12375 cf_cv_xaw_compat=no
12377 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12379 echo "$as_me:12379: result: $cf_cv_xaw_compat" >&5
12380 echo "${ECHO_T}$cf_cv_xaw_compat" >&6
12382 if test "$cf_cv_xaw_compat" = no
12384 # workaround for broken ".pc" files...
12385 case "$cf_x_athena_lib" in
12389 test -n "$verbose" && echo " work around broken package" 1>&6
12391 echo "${as_me:-configure}:12391: testing work around broken package ..." 1>&5
12393 cf_save_xmu="$LIBS"
12394 cf_first_lib=`echo "$cf_save_xmu" | sed -e 's/^ *//' -e 's/ .*//'`
12396 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xmu; then
12397 test -n "$verbose" && echo " found package xmu" 1>&6
12399 echo "${as_me:-configure}:12399: testing found package xmu ..." 1>&5
12401 cf_pkgconfig_incs="`$PKG_CONFIG --cflags xmu 2>/dev/null`"
12402 cf_pkgconfig_libs="`$PKG_CONFIG --libs xmu 2>/dev/null`"
12403 test -n "$verbose" && echo " package xmu CFLAGS: $cf_pkgconfig_incs" 1>&6
12405 echo "${as_me:-configure}:12405: testing package xmu CFLAGS: $cf_pkgconfig_incs ..." 1>&5
12407 test -n "$verbose" && echo " package xmu LIBS: $cf_pkgconfig_libs" 1>&6
12409 echo "${as_me:-configure}:12409: testing package xmu LIBS: $cf_pkgconfig_libs ..." 1>&5
12414 cf_new_extra_cppflags=
12416 for cf_add_cflags in $cf_pkgconfig_incs
12418 case $cf_fix_cppflags in
12420 case $cf_add_cflags in
12421 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
12422 case $cf_add_cflags in
12424 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
12426 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12427 && test -z "${cf_tst_cflags}" \
12428 && cf_fix_cppflags=yes
12430 if test $cf_fix_cppflags = yes ; then
12432 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12433 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12436 elif test "${cf_tst_cflags}" = "\"'" ; then
12438 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12439 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12445 case "$CPPFLAGS" in
12449 case $cf_add_cflags in
12451 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12453 CPPFLAGS=`echo "$CPPFLAGS" | \
12454 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12455 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12460 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
12461 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
12468 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
12469 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
12476 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12477 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12479 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
12481 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12482 && test -z "${cf_tst_cflags}" \
12483 && cf_fix_cppflags=no
12488 if test -n "$cf_new_cflags" ; then
12490 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
12491 CFLAGS="${CFLAGS}$cf_new_cflags"
12495 if test -n "$cf_new_cppflags" ; then
12497 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
12498 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
12502 if test -n "$cf_new_extra_cppflags" ; then
12504 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
12505 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
12509 cf_add_libs="$cf_pkgconfig_libs"
12510 # Filter out duplicates - this happens with badly-designed ".pc" files...
12511 for cf_add_1lib in $LIBS
12513 for cf_add_2lib in $cf_add_libs
12515 if test "x$cf_add_1lib" = "x$cf_add_2lib"
12521 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
12523 LIBS="$cf_add_libs"
12525 LIBS="$cf_save_xmu"
12527 test -n "$verbose" && echo " ...before $LIBS" 1>&6
12529 echo "${as_me:-configure}:12529: testing ...before $LIBS ..." 1>&5
12531 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%$cf_first_lib %$cf_first_lib $cf_pkgconfig_libs %" -e 's% % %g'`
12532 test -n "$verbose" && echo " ...after $LIBS" 1>&6
12534 echo "${as_me:-configure}:12534: testing ...after $LIBS ..." 1>&5
12540 test -n "$verbose" && echo " ...before $LIBS" 1>&6
12542 echo "${as_me:-configure}:12542: testing ...before $LIBS ..." 1>&5
12544 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%$cf_first_lib %$cf_first_lib -lXmu %" -e 's% % %g'`
12545 test -n "$verbose" && echo " ...after $LIBS" 1>&6
12547 echo "${as_me:-configure}:12547: testing ...after $LIBS ..." 1>&5
12551 for cf_trim_lib in Xmu Xt X11
12554 (*-l$cf_trim_lib\ *-l$cf_trim_lib*)
12555 LIBS=`echo "$LIBS " | sed -e 's/ / /g' -e 's%-l'"$cf_trim_lib"' %%' -e 's/ $//'`
12556 test -n "$verbose" && echo " ..trimmed $LIBS" 1>&6
12558 echo "${as_me:-configure}:12558: testing ..trimmed $LIBS ..." 1>&5
12578 if test -z "$cf_x_athena_lib" ; then
12580 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists Xext; then
12581 test -n "$verbose" && echo " found package Xext" 1>&6
12583 echo "${as_me:-configure}:12583: testing found package Xext ..." 1>&5
12585 cf_pkgconfig_incs="`$PKG_CONFIG --cflags Xext 2>/dev/null`"
12586 cf_pkgconfig_libs="`$PKG_CONFIG --libs Xext 2>/dev/null`"
12587 test -n "$verbose" && echo " package Xext CFLAGS: $cf_pkgconfig_incs" 1>&6
12589 echo "${as_me:-configure}:12589: testing package Xext CFLAGS: $cf_pkgconfig_incs ..." 1>&5
12591 test -n "$verbose" && echo " package Xext LIBS: $cf_pkgconfig_libs" 1>&6
12593 echo "${as_me:-configure}:12593: testing package Xext LIBS: $cf_pkgconfig_libs ..." 1>&5
12598 cf_new_extra_cppflags=
12600 for cf_add_cflags in $cf_pkgconfig_incs
12602 case $cf_fix_cppflags in
12604 case $cf_add_cflags in
12605 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
12606 case $cf_add_cflags in
12608 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
12610 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12611 && test -z "${cf_tst_cflags}" \
12612 && cf_fix_cppflags=yes
12614 if test $cf_fix_cppflags = yes ; then
12616 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12617 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12620 elif test "${cf_tst_cflags}" = "\"'" ; then
12622 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12623 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12629 case "$CPPFLAGS" in
12633 case $cf_add_cflags in
12635 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12637 CPPFLAGS=`echo "$CPPFLAGS" | \
12638 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12639 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12644 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
12645 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
12652 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
12653 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
12660 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12661 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12663 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
12665 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12666 && test -z "${cf_tst_cflags}" \
12667 && cf_fix_cppflags=no
12672 if test -n "$cf_new_cflags" ; then
12674 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
12675 CFLAGS="${CFLAGS}$cf_new_cflags"
12679 if test -n "$cf_new_cppflags" ; then
12681 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
12682 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
12686 if test -n "$cf_new_extra_cppflags" ; then
12688 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
12689 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
12693 cf_add_libs="$cf_pkgconfig_libs"
12694 # Filter out duplicates - this happens with badly-designed ".pc" files...
12695 for cf_add_1lib in $LIBS
12697 for cf_add_2lib in $cf_add_libs
12699 if test "x$cf_add_1lib" = "x$cf_add_2lib"
12705 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
12707 LIBS="$cf_add_libs"
12714 echo "$as_me:12714: checking for XextCreateExtension in -lXext" >&5
12715 echo $ECHO_N "checking for XextCreateExtension in -lXext... $ECHO_C" >&6
12716 if test "${ac_cv_lib_Xext_XextCreateExtension+set}" = set; then
12717 echo $ECHO_N "(cached) $ECHO_C" >&6
12719 ac_check_lib_save_LIBS=$LIBS
12720 LIBS="-lXext $LIBS"
12721 cat >conftest.$ac_ext <<_ACEOF
12722 #line 12722 "configure"
12723 #include "confdefs.h"
12725 /* Override any gcc2 internal prototype to avoid an error. */
12729 /* We use char because int might match the return type of a gcc2
12730 builtin and then its argument prototype would still apply. */
12731 char XextCreateExtension ();
12735 XextCreateExtension ();
12740 rm -f conftest.$ac_objext conftest$ac_exeext
12741 if { (eval echo "$as_me:12741: \"$ac_link\"") >&5
12742 (eval $ac_link) 2>&5
12744 echo "$as_me:12744: \$? = $ac_status" >&5
12745 (exit $ac_status); } &&
12746 { ac_try='test -s conftest$ac_exeext'
12747 { (eval echo "$as_me:12747: \"$ac_try\"") >&5
12748 (eval $ac_try) 2>&5
12750 echo "$as_me:12750: \$? = $ac_status" >&5
12751 (exit $ac_status); }; }; then
12752 ac_cv_lib_Xext_XextCreateExtension=yes
12754 echo "$as_me: failed program was:" >&5
12755 cat conftest.$ac_ext >&5
12756 ac_cv_lib_Xext_XextCreateExtension=no
12758 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12759 LIBS=$ac_check_lib_save_LIBS
12761 echo "$as_me:12761: result: $ac_cv_lib_Xext_XextCreateExtension" >&5
12762 echo "${ECHO_T}$ac_cv_lib_Xext_XextCreateExtension" >&6
12763 if test $ac_cv_lib_Xext_XextCreateExtension = yes; then
12765 cf_add_libs="-lXext"
12766 # Filter out duplicates - this happens with badly-designed ".pc" files...
12767 for cf_add_1lib in $LIBS
12769 for cf_add_2lib in $cf_add_libs
12771 if test "x$cf_add_1lib" = "x$cf_add_2lib"
12777 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
12779 LIBS="$cf_add_libs"
12785 # OSX is schizoid about who owns /usr/X11 (old) versus /opt/X11 (new), and (and
12786 # in some cases has installed dummy files in the former, other cases replaced
12787 # it with a link to the new location). This complicates the configure script.
12788 # Check for that pitfall, and recover using pkg-config
12790 # If none of these are set, the configuration is almost certainly broken.
12791 if test -z "${X_CFLAGS}${X_PRE_LIBS}${X_LIBS}${X_EXTRA_LIBS}"
12794 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists x11; then
12795 test -n "$verbose" && echo " found package x11" 1>&6
12797 echo "${as_me:-configure}:12797: testing found package x11 ..." 1>&5
12799 cf_pkgconfig_incs="`$PKG_CONFIG --cflags x11 2>/dev/null`"
12800 cf_pkgconfig_libs="`$PKG_CONFIG --libs x11 2>/dev/null`"
12801 test -n "$verbose" && echo " package x11 CFLAGS: $cf_pkgconfig_incs" 1>&6
12803 echo "${as_me:-configure}:12803: testing package x11 CFLAGS: $cf_pkgconfig_incs ..." 1>&5
12805 test -n "$verbose" && echo " package x11 LIBS: $cf_pkgconfig_libs" 1>&6
12807 echo "${as_me:-configure}:12807: testing package x11 LIBS: $cf_pkgconfig_libs ..." 1>&5
12812 cf_new_extra_cppflags=
12814 for cf_add_cflags in $cf_pkgconfig_incs
12816 case $cf_fix_cppflags in
12818 case $cf_add_cflags in
12819 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
12820 case $cf_add_cflags in
12822 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
12824 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12825 && test -z "${cf_tst_cflags}" \
12826 && cf_fix_cppflags=yes
12828 if test $cf_fix_cppflags = yes ; then
12830 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12831 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12834 elif test "${cf_tst_cflags}" = "\"'" ; then
12836 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12837 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12843 case "$CPPFLAGS" in
12847 case $cf_add_cflags in
12849 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12851 CPPFLAGS=`echo "$CPPFLAGS" | \
12852 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12853 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12858 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
12859 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
12866 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
12867 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
12874 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12875 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12877 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
12879 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12880 && test -z "${cf_tst_cflags}" \
12881 && cf_fix_cppflags=no
12886 if test -n "$cf_new_cflags" ; then
12888 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
12889 CFLAGS="${CFLAGS}$cf_new_cflags"
12893 if test -n "$cf_new_cppflags" ; then
12895 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
12896 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
12900 if test -n "$cf_new_extra_cppflags" ; then
12902 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
12903 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
12907 cf_add_libs="$cf_pkgconfig_libs"
12908 # Filter out duplicates - this happens with badly-designed ".pc" files...
12909 for cf_add_1lib in $LIBS
12911 for cf_add_2lib in $cf_add_libs
12913 if test "x$cf_add_1lib" = "x$cf_add_2lib"
12919 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
12921 LIBS="$cf_add_libs"
12927 { echo "$as_me:12927: WARNING: unable to find X11 library" >&5
12928 echo "$as_me: WARNING: unable to find X11 library" >&2;}
12931 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists ice; then
12932 test -n "$verbose" && echo " found package ice" 1>&6
12934 echo "${as_me:-configure}:12934: testing found package ice ..." 1>&5
12936 cf_pkgconfig_incs="`$PKG_CONFIG --cflags ice 2>/dev/null`"
12937 cf_pkgconfig_libs="`$PKG_CONFIG --libs ice 2>/dev/null`"
12938 test -n "$verbose" && echo " package ice CFLAGS: $cf_pkgconfig_incs" 1>&6
12940 echo "${as_me:-configure}:12940: testing package ice CFLAGS: $cf_pkgconfig_incs ..." 1>&5
12942 test -n "$verbose" && echo " package ice LIBS: $cf_pkgconfig_libs" 1>&6
12944 echo "${as_me:-configure}:12944: testing package ice LIBS: $cf_pkgconfig_libs ..." 1>&5
12949 cf_new_extra_cppflags=
12951 for cf_add_cflags in $cf_pkgconfig_incs
12953 case $cf_fix_cppflags in
12955 case $cf_add_cflags in
12956 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
12957 case $cf_add_cflags in
12959 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
12961 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12962 && test -z "${cf_tst_cflags}" \
12963 && cf_fix_cppflags=yes
12965 if test $cf_fix_cppflags = yes ; then
12967 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12968 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12971 elif test "${cf_tst_cflags}" = "\"'" ; then
12973 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12974 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12980 case "$CPPFLAGS" in
12984 case $cf_add_cflags in
12986 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12988 CPPFLAGS=`echo "$CPPFLAGS" | \
12989 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12990 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12995 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
12996 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
13003 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
13004 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
13011 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13012 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13014 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
13016 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13017 && test -z "${cf_tst_cflags}" \
13018 && cf_fix_cppflags=no
13023 if test -n "$cf_new_cflags" ; then
13025 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
13026 CFLAGS="${CFLAGS}$cf_new_cflags"
13030 if test -n "$cf_new_cppflags" ; then
13032 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13033 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
13037 if test -n "$cf_new_extra_cppflags" ; then
13039 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
13040 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
13044 cf_add_libs="$cf_pkgconfig_libs"
13045 # Filter out duplicates - this happens with badly-designed ".pc" files...
13046 for cf_add_1lib in $LIBS
13048 for cf_add_2lib in $cf_add_libs
13050 if test "x$cf_add_1lib" = "x$cf_add_2lib"
13056 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
13058 LIBS="$cf_add_libs"
13064 { echo "$as_me:13064: WARNING: unable to find ICE library" >&5
13065 echo "$as_me: WARNING: unable to find ICE library" >&2;}
13068 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists sm; then
13069 test -n "$verbose" && echo " found package sm" 1>&6
13071 echo "${as_me:-configure}:13071: testing found package sm ..." 1>&5
13073 cf_pkgconfig_incs="`$PKG_CONFIG --cflags sm 2>/dev/null`"
13074 cf_pkgconfig_libs="`$PKG_CONFIG --libs sm 2>/dev/null`"
13075 test -n "$verbose" && echo " package sm CFLAGS: $cf_pkgconfig_incs" 1>&6
13077 echo "${as_me:-configure}:13077: testing package sm CFLAGS: $cf_pkgconfig_incs ..." 1>&5
13079 test -n "$verbose" && echo " package sm LIBS: $cf_pkgconfig_libs" 1>&6
13081 echo "${as_me:-configure}:13081: testing package sm LIBS: $cf_pkgconfig_libs ..." 1>&5
13086 cf_new_extra_cppflags=
13088 for cf_add_cflags in $cf_pkgconfig_incs
13090 case $cf_fix_cppflags in
13092 case $cf_add_cflags in
13093 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
13094 case $cf_add_cflags in
13096 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
13098 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13099 && test -z "${cf_tst_cflags}" \
13100 && cf_fix_cppflags=yes
13102 if test $cf_fix_cppflags = yes ; then
13104 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13105 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13108 elif test "${cf_tst_cflags}" = "\"'" ; then
13110 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13111 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13117 case "$CPPFLAGS" in
13121 case $cf_add_cflags in
13123 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
13125 CPPFLAGS=`echo "$CPPFLAGS" | \
13126 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
13127 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
13132 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
13133 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
13140 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
13141 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
13148 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13149 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13151 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
13153 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13154 && test -z "${cf_tst_cflags}" \
13155 && cf_fix_cppflags=no
13160 if test -n "$cf_new_cflags" ; then
13162 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
13163 CFLAGS="${CFLAGS}$cf_new_cflags"
13167 if test -n "$cf_new_cppflags" ; then
13169 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13170 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
13174 if test -n "$cf_new_extra_cppflags" ; then
13176 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
13177 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
13181 cf_add_libs="$cf_pkgconfig_libs"
13182 # Filter out duplicates - this happens with badly-designed ".pc" files...
13183 for cf_add_1lib in $LIBS
13185 for cf_add_2lib in $cf_add_libs
13187 if test "x$cf_add_1lib" = "x$cf_add_2lib"
13193 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
13195 LIBS="$cf_add_libs"
13201 { echo "$as_me:13201: WARNING: unable to find SM library" >&5
13202 echo "$as_me: WARNING: unable to find SM library" >&2;}
13205 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xt; then
13206 test -n "$verbose" && echo " found package xt" 1>&6
13208 echo "${as_me:-configure}:13208: testing found package xt ..." 1>&5
13210 cf_pkgconfig_incs="`$PKG_CONFIG --cflags xt 2>/dev/null`"
13211 cf_pkgconfig_libs="`$PKG_CONFIG --libs xt 2>/dev/null`"
13212 test -n "$verbose" && echo " package xt CFLAGS: $cf_pkgconfig_incs" 1>&6
13214 echo "${as_me:-configure}:13214: testing package xt CFLAGS: $cf_pkgconfig_incs ..." 1>&5
13216 test -n "$verbose" && echo " package xt LIBS: $cf_pkgconfig_libs" 1>&6
13218 echo "${as_me:-configure}:13218: testing package xt LIBS: $cf_pkgconfig_libs ..." 1>&5
13223 cf_new_extra_cppflags=
13225 for cf_add_cflags in $cf_pkgconfig_incs
13227 case $cf_fix_cppflags in
13229 case $cf_add_cflags in
13230 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
13231 case $cf_add_cflags in
13233 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
13235 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13236 && test -z "${cf_tst_cflags}" \
13237 && cf_fix_cppflags=yes
13239 if test $cf_fix_cppflags = yes ; then
13241 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13242 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13245 elif test "${cf_tst_cflags}" = "\"'" ; then
13247 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13248 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13254 case "$CPPFLAGS" in
13258 case $cf_add_cflags in
13260 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
13262 CPPFLAGS=`echo "$CPPFLAGS" | \
13263 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
13264 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
13269 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
13270 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
13277 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
13278 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
13285 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13286 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13288 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
13290 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13291 && test -z "${cf_tst_cflags}" \
13292 && cf_fix_cppflags=no
13297 if test -n "$cf_new_cflags" ; then
13299 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
13300 CFLAGS="${CFLAGS}$cf_new_cflags"
13304 if test -n "$cf_new_cppflags" ; then
13306 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13307 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
13311 if test -n "$cf_new_extra_cppflags" ; then
13313 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
13314 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
13318 cf_add_libs="$cf_pkgconfig_libs"
13319 # Filter out duplicates - this happens with badly-designed ".pc" files...
13320 for cf_add_1lib in $LIBS
13322 for cf_add_2lib in $cf_add_libs
13324 if test "x$cf_add_1lib" = "x$cf_add_2lib"
13330 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
13332 LIBS="$cf_add_libs"
13338 { echo "$as_me:13338: WARNING: unable to find Xt library" >&5
13339 echo "$as_me: WARNING: unable to find Xt library" >&2;}
13346 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xt; then
13347 test -n "$verbose" && echo " found package xt" 1>&6
13349 echo "${as_me:-configure}:13349: testing found package xt ..." 1>&5
13351 cf_pkgconfig_incs="`$PKG_CONFIG --cflags xt 2>/dev/null`"
13352 cf_pkgconfig_libs="`$PKG_CONFIG --libs xt 2>/dev/null`"
13353 test -n "$verbose" && echo " package xt CFLAGS: $cf_pkgconfig_incs" 1>&6
13355 echo "${as_me:-configure}:13355: testing package xt CFLAGS: $cf_pkgconfig_incs ..." 1>&5
13357 test -n "$verbose" && echo " package xt LIBS: $cf_pkgconfig_libs" 1>&6
13359 echo "${as_me:-configure}:13359: testing package xt LIBS: $cf_pkgconfig_libs ..." 1>&5
13364 cf_new_extra_cppflags=
13366 for cf_add_cflags in $cf_pkgconfig_incs
13368 case $cf_fix_cppflags in
13370 case $cf_add_cflags in
13371 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
13372 case $cf_add_cflags in
13374 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
13376 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13377 && test -z "${cf_tst_cflags}" \
13378 && cf_fix_cppflags=yes
13380 if test $cf_fix_cppflags = yes ; then
13382 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13383 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13386 elif test "${cf_tst_cflags}" = "\"'" ; then
13388 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13389 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13395 case "$CPPFLAGS" in
13399 case $cf_add_cflags in
13401 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
13403 CPPFLAGS=`echo "$CPPFLAGS" | \
13404 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
13405 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
13410 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
13411 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
13418 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
13419 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
13426 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13427 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13429 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
13431 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13432 && test -z "${cf_tst_cflags}" \
13433 && cf_fix_cppflags=no
13438 if test -n "$cf_new_cflags" ; then
13440 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
13441 CFLAGS="${CFLAGS}$cf_new_cflags"
13445 if test -n "$cf_new_cppflags" ; then
13447 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13448 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
13452 if test -n "$cf_new_extra_cppflags" ; then
13454 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
13455 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
13459 cf_add_libs="$cf_pkgconfig_libs"
13460 # Filter out duplicates - this happens with badly-designed ".pc" files...
13461 for cf_add_1lib in $LIBS
13463 for cf_add_2lib in $cf_add_libs
13465 if test "x$cf_add_1lib" = "x$cf_add_2lib"
13471 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
13473 LIBS="$cf_add_libs"
13479 # we have an "xt" package, but it may omit Xt's dependency on X11
13480 echo "$as_me:13480: checking for usable X dependency" >&5
13481 echo $ECHO_N "checking for usable X dependency... $ECHO_C" >&6
13482 if test "${cf_cv_xt_x11_compat+set}" = set; then
13483 echo $ECHO_N "(cached) $ECHO_C" >&6
13486 cat >conftest.$ac_ext <<_ACEOF
13487 #line 13487 "configure"
13488 #include "confdefs.h"
13490 #include <X11/Xlib.h>
13496 int rc1 = XDrawLine((Display*) 0, (Drawable) 0, (GC) 0, 0, 0, 0, 0);
13497 int rc2 = XClearWindow((Display*) 0, (Window) 0);
13498 int rc3 = XMoveWindow((Display*) 0, (Window) 0, 0, 0);
13499 int rc4 = XMoveResizeWindow((Display*)0, (Window)0, 0, 0, 0, 0);
13505 rm -f conftest.$ac_objext conftest$ac_exeext
13506 if { (eval echo "$as_me:13506: \"$ac_link\"") >&5
13507 (eval $ac_link) 2>&5
13509 echo "$as_me:13509: \$? = $ac_status" >&5
13510 (exit $ac_status); } &&
13511 { ac_try='test -s conftest$ac_exeext'
13512 { (eval echo "$as_me:13512: \"$ac_try\"") >&5
13513 (eval $ac_try) 2>&5
13515 echo "$as_me:13515: \$? = $ac_status" >&5
13516 (exit $ac_status); }; }; then
13517 cf_cv_xt_x11_compat=yes
13519 echo "$as_me: failed program was:" >&5
13520 cat conftest.$ac_ext >&5
13521 cf_cv_xt_x11_compat=no
13523 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13525 echo "$as_me:13525: result: $cf_cv_xt_x11_compat" >&5
13526 echo "${ECHO_T}$cf_cv_xt_x11_compat" >&6
13527 if test "$cf_cv_xt_x11_compat" = no
13529 test -n "$verbose" && echo " work around broken X11 dependency" 1>&6
13531 echo "${as_me:-configure}:13531: testing work around broken X11 dependency ..." 1>&5
13533 # 2010/11/19 - good enough until a working Xt on Xcb is delivered.
13535 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists x11; then
13536 test -n "$verbose" && echo " found package x11" 1>&6
13538 echo "${as_me:-configure}:13538: testing found package x11 ..." 1>&5
13540 cf_pkgconfig_incs="`$PKG_CONFIG --cflags x11 2>/dev/null`"
13541 cf_pkgconfig_libs="`$PKG_CONFIG --libs x11 2>/dev/null`"
13542 test -n "$verbose" && echo " package x11 CFLAGS: $cf_pkgconfig_incs" 1>&6
13544 echo "${as_me:-configure}:13544: testing package x11 CFLAGS: $cf_pkgconfig_incs ..." 1>&5
13546 test -n "$verbose" && echo " package x11 LIBS: $cf_pkgconfig_libs" 1>&6
13548 echo "${as_me:-configure}:13548: testing package x11 LIBS: $cf_pkgconfig_libs ..." 1>&5
13553 cf_new_extra_cppflags=
13555 for cf_add_cflags in $cf_pkgconfig_incs
13557 case $cf_fix_cppflags in
13559 case $cf_add_cflags in
13560 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
13561 case $cf_add_cflags in
13563 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
13565 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13566 && test -z "${cf_tst_cflags}" \
13567 && cf_fix_cppflags=yes
13569 if test $cf_fix_cppflags = yes ; then
13571 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13572 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13575 elif test "${cf_tst_cflags}" = "\"'" ; then
13577 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13578 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13584 case "$CPPFLAGS" in
13588 case $cf_add_cflags in
13590 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
13592 CPPFLAGS=`echo "$CPPFLAGS" | \
13593 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
13594 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
13599 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
13600 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
13607 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
13608 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
13615 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13616 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13618 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
13620 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13621 && test -z "${cf_tst_cflags}" \
13622 && cf_fix_cppflags=no
13627 if test -n "$cf_new_cflags" ; then
13629 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
13630 CFLAGS="${CFLAGS}$cf_new_cflags"
13634 if test -n "$cf_new_cppflags" ; then
13636 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13637 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
13641 if test -n "$cf_new_extra_cppflags" ; then
13643 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
13644 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
13648 cf_add_libs="$cf_pkgconfig_libs"
13649 # Filter out duplicates - this happens with badly-designed ".pc" files...
13650 for cf_add_1lib in $LIBS
13652 for cf_add_2lib in $cf_add_libs
13654 if test "x$cf_add_1lib" = "x$cf_add_2lib"
13660 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
13662 LIBS="$cf_add_libs"
13669 test -n "$verbose" && echo " ...before $LIBS" 1>&6
13671 echo "${as_me:-configure}:13671: testing ...before $LIBS ..." 1>&5
13673 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%-lXt %-lXt -lX11 %" -e 's% % %g'`
13674 test -n "$verbose" && echo " ...after $LIBS" 1>&6
13676 echo "${as_me:-configure}:13676: testing ...after $LIBS ..." 1>&5
13684 echo "$as_me:13684: checking for usable X Toolkit package" >&5
13685 echo $ECHO_N "checking for usable X Toolkit package... $ECHO_C" >&6
13686 if test "${cf_cv_xt_ice_compat+set}" = set; then
13687 echo $ECHO_N "(cached) $ECHO_C" >&6
13690 cat >conftest.$ac_ext <<_ACEOF
13691 #line 13691 "configure"
13692 #include "confdefs.h"
13694 #include <X11/Shell.h>
13699 int num = IceConnectionNumber(0)
13705 rm -f conftest.$ac_objext conftest$ac_exeext
13706 if { (eval echo "$as_me:13706: \"$ac_link\"") >&5
13707 (eval $ac_link) 2>&5
13709 echo "$as_me:13709: \$? = $ac_status" >&5
13710 (exit $ac_status); } &&
13711 { ac_try='test -s conftest$ac_exeext'
13712 { (eval echo "$as_me:13712: \"$ac_try\"") >&5
13713 (eval $ac_try) 2>&5
13715 echo "$as_me:13715: \$? = $ac_status" >&5
13716 (exit $ac_status); }; }; then
13717 cf_cv_xt_ice_compat=yes
13719 echo "$as_me: failed program was:" >&5
13720 cat conftest.$ac_ext >&5
13721 cf_cv_xt_ice_compat=no
13723 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13725 echo "$as_me:13725: result: $cf_cv_xt_ice_compat" >&5
13726 echo "${ECHO_T}$cf_cv_xt_ice_compat" >&6
13728 if test "$cf_cv_xt_ice_compat" = no
13730 # workaround for broken ".pc" files used for X Toolkit.
13731 case "x$X_PRE_LIBS" in
13737 test -n "$verbose" && echo " work around broken ICE dependency" 1>&6
13739 echo "${as_me:-configure}:13739: testing work around broken ICE dependency ..." 1>&5
13741 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists ice; then
13742 test -n "$verbose" && echo " found package ice" 1>&6
13744 echo "${as_me:-configure}:13744: testing found package ice ..." 1>&5
13746 cf_pkgconfig_incs="`$PKG_CONFIG --cflags ice 2>/dev/null`"
13747 cf_pkgconfig_libs="`$PKG_CONFIG --libs ice 2>/dev/null`"
13748 test -n "$verbose" && echo " package ice CFLAGS: $cf_pkgconfig_incs" 1>&6
13750 echo "${as_me:-configure}:13750: testing package ice CFLAGS: $cf_pkgconfig_incs ..." 1>&5
13752 test -n "$verbose" && echo " package ice LIBS: $cf_pkgconfig_libs" 1>&6
13754 echo "${as_me:-configure}:13754: testing package ice LIBS: $cf_pkgconfig_libs ..." 1>&5
13759 cf_new_extra_cppflags=
13761 for cf_add_cflags in $cf_pkgconfig_incs
13763 case $cf_fix_cppflags in
13765 case $cf_add_cflags in
13766 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
13767 case $cf_add_cflags in
13769 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
13771 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13772 && test -z "${cf_tst_cflags}" \
13773 && cf_fix_cppflags=yes
13775 if test $cf_fix_cppflags = yes ; then
13777 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13778 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13781 elif test "${cf_tst_cflags}" = "\"'" ; then
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"
13790 case "$CPPFLAGS" in
13794 case $cf_add_cflags in
13796 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
13798 CPPFLAGS=`echo "$CPPFLAGS" | \
13799 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
13800 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
13805 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
13806 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
13813 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
13814 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
13821 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13822 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13824 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
13826 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13827 && test -z "${cf_tst_cflags}" \
13828 && cf_fix_cppflags=no
13833 if test -n "$cf_new_cflags" ; then
13835 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
13836 CFLAGS="${CFLAGS}$cf_new_cflags"
13840 if test -n "$cf_new_cppflags" ; then
13842 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13843 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
13847 if test -n "$cf_new_extra_cppflags" ; then
13849 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
13850 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
13854 cf_add_libs="$cf_pkgconfig_libs"
13855 # Filter out duplicates - this happens with badly-designed ".pc" files...
13856 for cf_add_1lib in $LIBS
13858 for cf_add_2lib in $cf_add_libs
13860 if test "x$cf_add_1lib" = "x$cf_add_2lib"
13866 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
13868 LIBS="$cf_add_libs"
13870 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists sm; then
13871 test -n "$verbose" && echo " found package sm" 1>&6
13873 echo "${as_me:-configure}:13873: testing found package sm ..." 1>&5
13875 cf_pkgconfig_incs="`$PKG_CONFIG --cflags sm 2>/dev/null`"
13876 cf_pkgconfig_libs="`$PKG_CONFIG --libs sm 2>/dev/null`"
13877 test -n "$verbose" && echo " package sm CFLAGS: $cf_pkgconfig_incs" 1>&6
13879 echo "${as_me:-configure}:13879: testing package sm CFLAGS: $cf_pkgconfig_incs ..." 1>&5
13881 test -n "$verbose" && echo " package sm LIBS: $cf_pkgconfig_libs" 1>&6
13883 echo "${as_me:-configure}:13883: testing package sm LIBS: $cf_pkgconfig_libs ..." 1>&5
13888 cf_new_extra_cppflags=
13890 for cf_add_cflags in $cf_pkgconfig_incs
13892 case $cf_fix_cppflags in
13894 case $cf_add_cflags in
13895 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
13896 case $cf_add_cflags in
13898 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
13900 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13901 && test -z "${cf_tst_cflags}" \
13902 && cf_fix_cppflags=yes
13904 if test $cf_fix_cppflags = yes ; then
13906 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13907 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13910 elif test "${cf_tst_cflags}" = "\"'" ; then
13912 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13913 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13919 case "$CPPFLAGS" in
13923 case $cf_add_cflags in
13925 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
13927 CPPFLAGS=`echo "$CPPFLAGS" | \
13928 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
13929 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
13934 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
13935 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
13942 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
13943 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
13950 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13951 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13953 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
13955 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13956 && test -z "${cf_tst_cflags}" \
13957 && cf_fix_cppflags=no
13962 if test -n "$cf_new_cflags" ; then
13964 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
13965 CFLAGS="${CFLAGS}$cf_new_cflags"
13969 if test -n "$cf_new_cppflags" ; then
13971 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13972 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
13976 if test -n "$cf_new_extra_cppflags" ; then
13978 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
13979 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
13983 cf_add_libs="$cf_pkgconfig_libs"
13984 # Filter out duplicates - this happens with badly-designed ".pc" files...
13985 for cf_add_1lib in $LIBS
13987 for cf_add_2lib in $cf_add_libs
13989 if test "x$cf_add_1lib" = "x$cf_add_2lib"
13995 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
13997 LIBS="$cf_add_libs"
14010 test -n "$verbose" && echo " ...before $LIBS" 1>&6
14012 echo "${as_me:-configure}:14012: testing ...before $LIBS ..." 1>&5
14014 LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%-lXt %-lXt $X_PRE_LIBS %" -e 's% % %g'`
14015 test -n "$verbose" && echo " ...after $LIBS" 1>&6
14017 echo "${as_me:-configure}:14017: testing ...after $LIBS ..." 1>&5
14033 LDFLAGS="$X_LIBS $LDFLAGS"
14035 test -n "$verbose" && echo " checking additions to CFLAGS" 1>&6
14037 echo "${as_me:-configure}:14037: testing checking additions to CFLAGS ..." 1>&5
14039 cf_check_cflags="$CFLAGS"
14040 cf_check_cppflags="$CPPFLAGS"
14045 cf_new_extra_cppflags=
14047 for cf_add_cflags in $X_CFLAGS
14049 case $cf_fix_cppflags in
14051 case $cf_add_cflags in
14052 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
14053 case $cf_add_cflags in
14055 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
14057 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14058 && test -z "${cf_tst_cflags}" \
14059 && cf_fix_cppflags=yes
14061 if test $cf_fix_cppflags = yes ; then
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"
14067 elif test "${cf_tst_cflags}" = "\"'" ; then
14069 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14070 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14076 case "$CPPFLAGS" in
14080 case $cf_add_cflags in
14082 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
14084 CPPFLAGS=`echo "$CPPFLAGS" | \
14085 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
14086 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
14091 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
14092 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
14099 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
14100 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
14107 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14108 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14110 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
14112 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14113 && test -z "${cf_tst_cflags}" \
14114 && cf_fix_cppflags=no
14119 if test -n "$cf_new_cflags" ; then
14120 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
14122 echo "${as_me:-configure}:14122: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
14124 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
14125 CFLAGS="${CFLAGS}$cf_new_cflags"
14129 if test -n "$cf_new_cppflags" ; then
14130 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
14132 echo "${as_me:-configure}:14132: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
14134 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
14135 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
14139 if test -n "$cf_new_extra_cppflags" ; then
14140 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
14142 echo "${as_me:-configure}:14142: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
14144 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
14145 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
14149 if test "x$cf_check_cflags" != "x$CFLAGS" ; then
14150 cat >conftest.$ac_ext <<_ACEOF
14151 #line 14151 "configure"
14152 #include "confdefs.h"
14157 printf("Hello world");
14162 rm -f conftest.$ac_objext conftest$ac_exeext
14163 if { (eval echo "$as_me:14163: \"$ac_link\"") >&5
14164 (eval $ac_link) 2>&5
14166 echo "$as_me:14166: \$? = $ac_status" >&5
14167 (exit $ac_status); } &&
14168 { ac_try='test -s conftest$ac_exeext'
14169 { (eval echo "$as_me:14169: \"$ac_try\"") >&5
14170 (eval $ac_try) 2>&5
14172 echo "$as_me:14172: \$? = $ac_status" >&5
14173 (exit $ac_status); }; }; then
14176 echo "$as_me: failed program was:" >&5
14177 cat conftest.$ac_ext >&5
14178 test -n "$verbose" && echo " test-compile failed. Undoing change to \$CFLAGS" 1>&6
14180 echo "${as_me:-configure}:14180: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5
14182 if test "x$cf_check_cppflags" != "x$CPPFLAGS" ; then
14183 test -n "$verbose" && echo " but keeping change to \$CPPFLAGS" 1>&6
14185 echo "${as_me:-configure}:14185: testing but keeping change to \$CPPFLAGS ..." 1>&5
14188 CFLAGS="$cf_check_flags"
14190 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14193 echo "$as_me:14193: checking for XOpenDisplay" >&5
14194 echo $ECHO_N "checking for XOpenDisplay... $ECHO_C" >&6
14195 if test "${ac_cv_func_XOpenDisplay+set}" = set; then
14196 echo $ECHO_N "(cached) $ECHO_C" >&6
14198 cat >conftest.$ac_ext <<_ACEOF
14199 #line 14199 "configure"
14200 #include "confdefs.h"
14201 #define XOpenDisplay autoconf_temporary
14202 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
14203 #undef XOpenDisplay
14209 /* We use char because int might match the return type of a gcc2
14210 builtin and then its argument prototype would still apply. */
14211 char XOpenDisplay (void);
14217 /* The GNU C library defines stubs for functions which it implements
14218 to always fail with ENOSYS. Some functions are actually named
14219 something starting with __ and the normal name is an alias. */
14220 #if defined (__stub_XOpenDisplay) || defined (__stub___XOpenDisplay)
14221 #error found stub for XOpenDisplay
14224 return XOpenDisplay ();
14229 rm -f conftest.$ac_objext conftest$ac_exeext
14230 if { (eval echo "$as_me:14230: \"$ac_link\"") >&5
14231 (eval $ac_link) 2>&5
14233 echo "$as_me:14233: \$? = $ac_status" >&5
14234 (exit $ac_status); } &&
14235 { ac_try='test -s conftest$ac_exeext'
14236 { (eval echo "$as_me:14236: \"$ac_try\"") >&5
14237 (eval $ac_try) 2>&5
14239 echo "$as_me:14239: \$? = $ac_status" >&5
14240 (exit $ac_status); }; }; then
14241 ac_cv_func_XOpenDisplay=yes
14243 echo "$as_me: failed program was:" >&5
14244 cat conftest.$ac_ext >&5
14245 ac_cv_func_XOpenDisplay=no
14247 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14249 echo "$as_me:14249: result: $ac_cv_func_XOpenDisplay" >&5
14250 echo "${ECHO_T}$ac_cv_func_XOpenDisplay" >&6
14251 if test $ac_cv_func_XOpenDisplay = yes; then
14255 echo "$as_me:14255: checking for XOpenDisplay in -lX11" >&5
14256 echo $ECHO_N "checking for XOpenDisplay in -lX11... $ECHO_C" >&6
14257 if test "${ac_cv_lib_X11_XOpenDisplay+set}" = set; then
14258 echo $ECHO_N "(cached) $ECHO_C" >&6
14260 ac_check_lib_save_LIBS=$LIBS
14261 LIBS="-lX11 $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
14262 cat >conftest.$ac_ext <<_ACEOF
14263 #line 14263 "configure"
14264 #include "confdefs.h"
14266 /* Override any gcc2 internal prototype to avoid an error. */
14270 /* We use char because int might match the return type of a gcc2
14271 builtin and then its argument prototype would still apply. */
14272 char XOpenDisplay ();
14281 rm -f conftest.$ac_objext conftest$ac_exeext
14282 if { (eval echo "$as_me:14282: \"$ac_link\"") >&5
14283 (eval $ac_link) 2>&5
14285 echo "$as_me:14285: \$? = $ac_status" >&5
14286 (exit $ac_status); } &&
14287 { ac_try='test -s conftest$ac_exeext'
14288 { (eval echo "$as_me:14288: \"$ac_try\"") >&5
14289 (eval $ac_try) 2>&5
14291 echo "$as_me:14291: \$? = $ac_status" >&5
14292 (exit $ac_status); }; }; then
14293 ac_cv_lib_X11_XOpenDisplay=yes
14295 echo "$as_me: failed program was:" >&5
14296 cat conftest.$ac_ext >&5
14297 ac_cv_lib_X11_XOpenDisplay=no
14299 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14300 LIBS=$ac_check_lib_save_LIBS
14302 echo "$as_me:14302: result: $ac_cv_lib_X11_XOpenDisplay" >&5
14303 echo "${ECHO_T}$ac_cv_lib_X11_XOpenDisplay" >&6
14304 if test $ac_cv_lib_X11_XOpenDisplay = yes; then
14306 cf_add_libs="-lX11"
14307 # Filter out duplicates - this happens with badly-designed ".pc" files...
14308 for cf_add_1lib in $LIBS
14310 for cf_add_2lib in $cf_add_libs
14312 if test "x$cf_add_1lib" = "x$cf_add_2lib"
14318 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
14320 LIBS="$cf_add_libs"
14326 echo "$as_me:14326: checking for XtAppInitialize" >&5
14327 echo $ECHO_N "checking for XtAppInitialize... $ECHO_C" >&6
14328 if test "${ac_cv_func_XtAppInitialize+set}" = set; then
14329 echo $ECHO_N "(cached) $ECHO_C" >&6
14331 cat >conftest.$ac_ext <<_ACEOF
14332 #line 14332 "configure"
14333 #include "confdefs.h"
14334 #define XtAppInitialize autoconf_temporary
14335 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
14336 #undef XtAppInitialize
14342 /* We use char because int might match the return type of a gcc2
14343 builtin and then its argument prototype would still apply. */
14344 char XtAppInitialize (void);
14350 /* The GNU C library defines stubs for functions which it implements
14351 to always fail with ENOSYS. Some functions are actually named
14352 something starting with __ and the normal name is an alias. */
14353 #if defined (__stub_XtAppInitialize) || defined (__stub___XtAppInitialize)
14354 #error found stub for XtAppInitialize
14357 return XtAppInitialize ();
14362 rm -f conftest.$ac_objext conftest$ac_exeext
14363 if { (eval echo "$as_me:14363: \"$ac_link\"") >&5
14364 (eval $ac_link) 2>&5
14366 echo "$as_me:14366: \$? = $ac_status" >&5
14367 (exit $ac_status); } &&
14368 { ac_try='test -s conftest$ac_exeext'
14369 { (eval echo "$as_me:14369: \"$ac_try\"") >&5
14370 (eval $ac_try) 2>&5
14372 echo "$as_me:14372: \$? = $ac_status" >&5
14373 (exit $ac_status); }; }; then
14374 ac_cv_func_XtAppInitialize=yes
14376 echo "$as_me: failed program was:" >&5
14377 cat conftest.$ac_ext >&5
14378 ac_cv_func_XtAppInitialize=no
14380 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14382 echo "$as_me:14382: result: $ac_cv_func_XtAppInitialize" >&5
14383 echo "${ECHO_T}$ac_cv_func_XtAppInitialize" >&6
14384 if test $ac_cv_func_XtAppInitialize = yes; then
14388 echo "$as_me:14388: checking for XtAppInitialize in -lXt" >&5
14389 echo $ECHO_N "checking for XtAppInitialize in -lXt... $ECHO_C" >&6
14390 if test "${ac_cv_lib_Xt_XtAppInitialize+set}" = set; then
14391 echo $ECHO_N "(cached) $ECHO_C" >&6
14393 ac_check_lib_save_LIBS=$LIBS
14394 LIBS="-lXt $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
14395 cat >conftest.$ac_ext <<_ACEOF
14396 #line 14396 "configure"
14397 #include "confdefs.h"
14399 /* Override any gcc2 internal prototype to avoid an error. */
14403 /* We use char because int might match the return type of a gcc2
14404 builtin and then its argument prototype would still apply. */
14405 char XtAppInitialize ();
14409 XtAppInitialize ();
14414 rm -f conftest.$ac_objext conftest$ac_exeext
14415 if { (eval echo "$as_me:14415: \"$ac_link\"") >&5
14416 (eval $ac_link) 2>&5
14418 echo "$as_me:14418: \$? = $ac_status" >&5
14419 (exit $ac_status); } &&
14420 { ac_try='test -s conftest$ac_exeext'
14421 { (eval echo "$as_me:14421: \"$ac_try\"") >&5
14422 (eval $ac_try) 2>&5
14424 echo "$as_me:14424: \$? = $ac_status" >&5
14425 (exit $ac_status); }; }; then
14426 ac_cv_lib_Xt_XtAppInitialize=yes
14428 echo "$as_me: failed program was:" >&5
14429 cat conftest.$ac_ext >&5
14430 ac_cv_lib_Xt_XtAppInitialize=no
14432 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14433 LIBS=$ac_check_lib_save_LIBS
14435 echo "$as_me:14435: result: $ac_cv_lib_Xt_XtAppInitialize" >&5
14436 echo "${ECHO_T}$ac_cv_lib_Xt_XtAppInitialize" >&6
14437 if test $ac_cv_lib_Xt_XtAppInitialize = yes; then
14439 cat >>confdefs.h <<\EOF
14440 #define HAVE_LIBXT 1
14444 LIBS="-lXt $X_PRE_LIBS $LIBS $X_EXTRA_LIBS"
14451 if test $cf_have_X_LIBS = no ; then
14452 { echo "$as_me:14452: WARNING: Unable to successfully link X Toolkit library (-lXt) with
14453 test program. You will have to check and add the proper libraries by hand
14455 echo "$as_me: WARNING: Unable to successfully link X Toolkit library (-lXt) with
14456 test program. You will have to check and add the proper libraries by hand
14457 to makefile." >&2;}
14460 cf_x_athena_root=$cf_x_athena
14463 for cf_path in default \
14464 /usr/contrib/X11R6 \
14465 /usr/contrib/X11R5 \
14469 if test -z "$cf_x_athena_inc" ; then
14470 cf_save="$CPPFLAGS"
14471 cf_test=X11/$cf_x_athena_root/SimpleMenu.h
14472 if test $cf_path != default ; then
14473 CPPFLAGS="$cf_save"
14475 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
14476 CPPFLAGS="${CPPFLAGS}-I$cf_path/include"
14478 echo "$as_me:14478: checking for $cf_test in $cf_path" >&5
14479 echo $ECHO_N "checking for $cf_test in $cf_path... $ECHO_C" >&6
14481 echo "$as_me:14481: checking for $cf_test" >&5
14482 echo $ECHO_N "checking for $cf_test... $ECHO_C" >&6
14484 cat >conftest.$ac_ext <<_ACEOF
14485 #line 14485 "configure"
14486 #include "confdefs.h"
14488 #include <X11/Intrinsic.h>
14489 #include <$cf_test>
14498 rm -f conftest.$ac_objext
14499 if { (eval echo "$as_me:14499: \"$ac_compile\"") >&5
14500 (eval $ac_compile) 2>&5
14502 echo "$as_me:14502: \$? = $ac_status" >&5
14503 (exit $ac_status); } &&
14504 { ac_try='test -s conftest.$ac_objext'
14505 { (eval echo "$as_me:14505: \"$ac_try\"") >&5
14506 (eval $ac_try) 2>&5
14508 echo "$as_me:14508: \$? = $ac_status" >&5
14509 (exit $ac_status); }; }; then
14512 echo "$as_me: failed program was:" >&5
14513 cat conftest.$ac_ext >&5
14516 rm -f conftest.$ac_objext conftest.$ac_ext
14517 echo "$as_me:14517: result: $cf_result" >&5
14518 echo "${ECHO_T}$cf_result" >&6
14519 if test "$cf_result" = yes ; then
14520 cf_x_athena_inc=$cf_path
14523 CPPFLAGS="$cf_save"
14528 if test -z "$cf_x_athena_inc" ; then
14529 { echo "$as_me:14529: WARNING: Unable to successfully find Athena header files with test program" >&5
14530 echo "$as_me: WARNING: Unable to successfully find Athena header files with test program" >&2;}
14531 elif test "$cf_x_athena_inc" != default ; then
14533 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
14534 CPPFLAGS="${CPPFLAGS}-I$cf_x_athena_inc"
14538 cf_x_athena_root=$cf_x_athena
14541 for cf_path in default \
14542 /usr/contrib/X11R6 \
14543 /usr/contrib/X11R5 \
14548 ${cf_x_athena_root} \
14549 ${cf_x_athena_root}7 \
14550 ${cf_x_athena_root}6
14553 "-l$cf_lib -lXmu" \
14554 "-l$cf_lib -lXpm -lXmu" \
14555 "-l${cf_lib}_s -lXmu_s"
14557 if test -z "$cf_x_athena_lib" ; then
14559 cf_test=XawSimpleMenuAddGlobalActions
14560 if test $cf_path != default ; then
14562 cf_add_libs="-L$cf_path/lib $cf_libs"
14563 # Filter out duplicates - this happens with badly-designed ".pc" files...
14564 for cf_add_1lib in $LIBS
14566 for cf_add_2lib in $cf_add_libs
14568 if test "x$cf_add_1lib" = "x$cf_add_2lib"
14574 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
14576 LIBS="$cf_add_libs"
14578 echo "$as_me:14578: checking for $cf_libs in $cf_path" >&5
14579 echo $ECHO_N "checking for $cf_libs in $cf_path... $ECHO_C" >&6
14582 cf_add_libs="$cf_libs"
14583 # Filter out duplicates - this happens with badly-designed ".pc" files...
14584 for cf_add_1lib in $LIBS
14586 for cf_add_2lib in $cf_add_libs
14588 if test "x$cf_add_1lib" = "x$cf_add_2lib"
14594 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
14596 LIBS="$cf_add_libs"
14598 echo "$as_me:14598: checking for $cf_test in $cf_libs" >&5
14599 echo $ECHO_N "checking for $cf_test in $cf_libs... $ECHO_C" >&6
14601 cat >conftest.$ac_ext <<_ACEOF
14602 #line 14602 "configure"
14603 #include "confdefs.h"
14605 #include <X11/Intrinsic.h>
14606 #include <X11/$cf_x_athena_root/SimpleMenu.h>
14612 $cf_test((XtAppContext) 0)
14617 rm -f conftest.$ac_objext conftest$ac_exeext
14618 if { (eval echo "$as_me:14618: \"$ac_link\"") >&5
14619 (eval $ac_link) 2>&5
14621 echo "$as_me:14621: \$? = $ac_status" >&5
14622 (exit $ac_status); } &&
14623 { ac_try='test -s conftest$ac_exeext'
14624 { (eval echo "$as_me:14624: \"$ac_try\"") >&5
14625 (eval $ac_try) 2>&5
14627 echo "$as_me:14627: \$? = $ac_status" >&5
14628 (exit $ac_status); }; }; then
14631 echo "$as_me: failed program was:" >&5
14632 cat conftest.$ac_ext >&5
14635 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14636 echo "$as_me:14636: result: $cf_result" >&5
14637 echo "${ECHO_T}$cf_result" >&6
14638 if test "$cf_result" = yes ; then
14639 cf_x_athena_lib="$cf_libs"
14645 test -n "$cf_x_athena_lib" && break
14649 if test -z "$cf_x_athena_lib" ; then
14650 { { echo "$as_me:14650: error: Unable to successfully link Athena library (-l$cf_x_athena_root) with test program" >&5
14651 echo "$as_me: error: Unable to successfully link Athena library (-l$cf_x_athena_root) with test program" >&2;}
14652 { (exit 1); exit 1; }; }
14655 cf_x_athena_LIBS=`echo "HAVE_LIB_$cf_x_athena" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
14657 cat >>confdefs.h <<EOF
14658 #define $cf_x_athena_LIBS 1
14663 if test -n "$ac_tool_prefix"; then
14664 for ac_prog in xcurses-config
14666 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
14667 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
14668 echo "$as_me:14668: checking for $ac_word" >&5
14669 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
14670 if test "${ac_cv_prog_XCURSES_CONFIG+set}" = set; then
14671 echo $ECHO_N "(cached) $ECHO_C" >&6
14673 if test -n "$XCURSES_CONFIG"; then
14674 ac_cv_prog_XCURSES_CONFIG="$XCURSES_CONFIG" # Let the user override the test.
14676 ac_save_IFS=$IFS; IFS=$ac_path_separator
14678 for ac_dir in $ac_dummy; do
14680 test -z "$ac_dir" && ac_dir=.
14681 $as_executable_p "$ac_dir/$ac_word" || continue
14682 ac_cv_prog_XCURSES_CONFIG="$ac_tool_prefix$ac_prog"
14683 echo "$as_me:14683: found $ac_dir/$ac_word" >&5
14689 XCURSES_CONFIG=$ac_cv_prog_XCURSES_CONFIG
14690 if test -n "$XCURSES_CONFIG"; then
14691 echo "$as_me:14691: result: $XCURSES_CONFIG" >&5
14692 echo "${ECHO_T}$XCURSES_CONFIG" >&6
14694 echo "$as_me:14694: result: no" >&5
14695 echo "${ECHO_T}no" >&6
14698 test -n "$XCURSES_CONFIG" && break
14701 if test -z "$XCURSES_CONFIG"; then
14702 ac_ct_XCURSES_CONFIG=$XCURSES_CONFIG
14703 for ac_prog in xcurses-config
14705 # Extract the first word of "$ac_prog", so it can be a program name with args.
14706 set dummy $ac_prog; ac_word=$2
14707 echo "$as_me:14707: checking for $ac_word" >&5
14708 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
14709 if test "${ac_cv_prog_ac_ct_XCURSES_CONFIG+set}" = set; then
14710 echo $ECHO_N "(cached) $ECHO_C" >&6
14712 if test -n "$ac_ct_XCURSES_CONFIG"; then
14713 ac_cv_prog_ac_ct_XCURSES_CONFIG="$ac_ct_XCURSES_CONFIG" # Let the user override the test.
14715 ac_save_IFS=$IFS; IFS=$ac_path_separator
14717 for ac_dir in $ac_dummy; do
14719 test -z "$ac_dir" && ac_dir=.
14720 $as_executable_p "$ac_dir/$ac_word" || continue
14721 ac_cv_prog_ac_ct_XCURSES_CONFIG="$ac_prog"
14722 echo "$as_me:14722: found $ac_dir/$ac_word" >&5
14728 ac_ct_XCURSES_CONFIG=$ac_cv_prog_ac_ct_XCURSES_CONFIG
14729 if test -n "$ac_ct_XCURSES_CONFIG"; then
14730 echo "$as_me:14730: result: $ac_ct_XCURSES_CONFIG" >&5
14731 echo "${ECHO_T}$ac_ct_XCURSES_CONFIG" >&6
14733 echo "$as_me:14733: result: no" >&5
14734 echo "${ECHO_T}no" >&6
14737 test -n "$ac_ct_XCURSES_CONFIG" && break
14739 test -n "$ac_ct_XCURSES_CONFIG" || ac_ct_XCURSES_CONFIG="none"
14741 XCURSES_CONFIG=$ac_ct_XCURSES_CONFIG
14744 if test "$XCURSES_CONFIG" != none ; then
14749 cf_new_extra_cppflags=
14751 for cf_add_cflags in `$XCURSES_CONFIG --cflags`
14753 case $cf_fix_cppflags in
14755 case $cf_add_cflags in
14756 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
14757 case $cf_add_cflags in
14759 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
14761 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14762 && test -z "${cf_tst_cflags}" \
14763 && cf_fix_cppflags=yes
14765 if test $cf_fix_cppflags = yes ; then
14767 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14768 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14771 elif test "${cf_tst_cflags}" = "\"'" ; then
14773 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14774 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14780 case "$CPPFLAGS" in
14784 case $cf_add_cflags in
14786 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
14788 CPPFLAGS=`echo "$CPPFLAGS" | \
14789 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
14790 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
14795 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
14796 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
14803 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
14804 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
14811 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14812 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14814 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
14816 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14817 && test -z "${cf_tst_cflags}" \
14818 && cf_fix_cppflags=no
14823 if test -n "$cf_new_cflags" ; then
14825 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
14826 CFLAGS="${CFLAGS}$cf_new_cflags"
14830 if test -n "$cf_new_cppflags" ; then
14832 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
14833 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
14837 if test -n "$cf_new_extra_cppflags" ; then
14839 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
14840 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
14844 cf_add_libs="`$XCURSES_CONFIG --libs`"
14845 # Filter out duplicates - this happens with badly-designed ".pc" files...
14846 for cf_add_1lib in $LIBS
14848 for cf_add_2lib in $cf_add_libs
14850 if test "x$cf_add_1lib" = "x$cf_add_2lib"
14856 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
14858 LIBS="$cf_add_libs"
14860 cf_cv_lib_XCurses=yes
14864 LDFLAGS="$LDFLAGS $X_LIBS"
14866 test -n "$verbose" && echo " checking additions to CFLAGS" 1>&6
14868 echo "${as_me:-configure}:14868: testing checking additions to CFLAGS ..." 1>&5
14870 cf_check_cflags="$CFLAGS"
14871 cf_check_cppflags="$CPPFLAGS"
14876 cf_new_extra_cppflags=
14878 for cf_add_cflags in $X_CFLAGS
14880 case $cf_fix_cppflags in
14882 case $cf_add_cflags in
14883 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
14884 case $cf_add_cflags in
14886 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
14888 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14889 && test -z "${cf_tst_cflags}" \
14890 && cf_fix_cppflags=yes
14892 if test $cf_fix_cppflags = yes ; then
14894 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14895 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14898 elif test "${cf_tst_cflags}" = "\"'" ; then
14900 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14901 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14907 case "$CPPFLAGS" in
14911 case $cf_add_cflags in
14913 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
14915 CPPFLAGS=`echo "$CPPFLAGS" | \
14916 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
14917 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
14922 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
14923 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
14930 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
14931 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
14938 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14939 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14941 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
14943 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14944 && test -z "${cf_tst_cflags}" \
14945 && cf_fix_cppflags=no
14950 if test -n "$cf_new_cflags" ; then
14951 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
14953 echo "${as_me:-configure}:14953: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
14955 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
14956 CFLAGS="${CFLAGS}$cf_new_cflags"
14960 if test -n "$cf_new_cppflags" ; then
14961 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
14963 echo "${as_me:-configure}:14963: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
14965 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
14966 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
14970 if test -n "$cf_new_extra_cppflags" ; then
14971 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
14973 echo "${as_me:-configure}:14973: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
14975 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
14976 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
14980 if test "x$cf_check_cflags" != "x$CFLAGS" ; then
14981 cat >conftest.$ac_ext <<_ACEOF
14982 #line 14982 "configure"
14983 #include "confdefs.h"
14988 printf("Hello world");
14993 rm -f conftest.$ac_objext conftest$ac_exeext
14994 if { (eval echo "$as_me:14994: \"$ac_link\"") >&5
14995 (eval $ac_link) 2>&5
14997 echo "$as_me:14997: \$? = $ac_status" >&5
14998 (exit $ac_status); } &&
14999 { ac_try='test -s conftest$ac_exeext'
15000 { (eval echo "$as_me:15000: \"$ac_try\"") >&5
15001 (eval $ac_try) 2>&5
15003 echo "$as_me:15003: \$? = $ac_status" >&5
15004 (exit $ac_status); }; }; then
15007 echo "$as_me: failed program was:" >&5
15008 cat conftest.$ac_ext >&5
15009 test -n "$verbose" && echo " test-compile failed. Undoing change to \$CFLAGS" 1>&6
15011 echo "${as_me:-configure}:15011: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5
15013 if test "x$cf_check_cppflags" != "x$CPPFLAGS" ; then
15014 test -n "$verbose" && echo " but keeping change to \$CPPFLAGS" 1>&6
15016 echo "${as_me:-configure}:15016: testing but keeping change to \$CPPFLAGS ..." 1>&5
15019 CFLAGS="$cf_check_flags"
15021 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15024 echo "$as_me:15024: checking for XOpenDisplay in -lX11" >&5
15025 echo $ECHO_N "checking for XOpenDisplay in -lX11... $ECHO_C" >&6
15026 if test "${ac_cv_lib_X11_XOpenDisplay+set}" = set; then
15027 echo $ECHO_N "(cached) $ECHO_C" >&6
15029 ac_check_lib_save_LIBS=$LIBS
15030 LIBS="-lX11 $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
15031 cat >conftest.$ac_ext <<_ACEOF
15032 #line 15032 "configure"
15033 #include "confdefs.h"
15035 /* Override any gcc2 internal prototype to avoid an error. */
15039 /* We use char because int might match the return type of a gcc2
15040 builtin and then its argument prototype would still apply. */
15041 char XOpenDisplay ();
15050 rm -f conftest.$ac_objext conftest$ac_exeext
15051 if { (eval echo "$as_me:15051: \"$ac_link\"") >&5
15052 (eval $ac_link) 2>&5
15054 echo "$as_me:15054: \$? = $ac_status" >&5
15055 (exit $ac_status); } &&
15056 { ac_try='test -s conftest$ac_exeext'
15057 { (eval echo "$as_me:15057: \"$ac_try\"") >&5
15058 (eval $ac_try) 2>&5
15060 echo "$as_me:15060: \$? = $ac_status" >&5
15061 (exit $ac_status); }; }; then
15062 ac_cv_lib_X11_XOpenDisplay=yes
15064 echo "$as_me: failed program was:" >&5
15065 cat conftest.$ac_ext >&5
15066 ac_cv_lib_X11_XOpenDisplay=no
15068 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15069 LIBS=$ac_check_lib_save_LIBS
15071 echo "$as_me:15071: result: $ac_cv_lib_X11_XOpenDisplay" >&5
15072 echo "${ECHO_T}$ac_cv_lib_X11_XOpenDisplay" >&6
15073 if test $ac_cv_lib_X11_XOpenDisplay = yes; then
15075 cf_add_libs="-lX11"
15076 # Filter out duplicates - this happens with badly-designed ".pc" files...
15077 for cf_add_1lib in $LIBS
15079 for cf_add_2lib in $cf_add_libs
15081 if test "x$cf_add_1lib" = "x$cf_add_2lib"
15087 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
15089 LIBS="$cf_add_libs"
15093 echo "$as_me:15093: checking for XCurses library" >&5
15094 echo $ECHO_N "checking for XCurses library... $ECHO_C" >&6
15095 if test "${cf_cv_lib_XCurses+set}" = set; then
15096 echo $ECHO_N "(cached) $ECHO_C" >&6
15099 cf_add_libs="-lXCurses"
15100 # Filter out duplicates - this happens with badly-designed ".pc" files...
15101 for cf_add_1lib in $LIBS
15103 for cf_add_2lib in $cf_add_libs
15105 if test "x$cf_add_1lib" = "x$cf_add_2lib"
15111 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
15113 LIBS="$cf_add_libs"
15115 cat >conftest.$ac_ext <<_ACEOF
15116 #line 15116 "configure"
15117 #include "confdefs.h"
15119 #include <xcurses.h>
15120 char *XCursesProgramName = "test";
15130 rm -f conftest.$ac_objext conftest$ac_exeext
15131 if { (eval echo "$as_me:15131: \"$ac_link\"") >&5
15132 (eval $ac_link) 2>&5
15134 echo "$as_me:15134: \$? = $ac_status" >&5
15135 (exit $ac_status); } &&
15136 { ac_try='test -s conftest$ac_exeext'
15137 { (eval echo "$as_me:15137: \"$ac_try\"") >&5
15138 (eval $ac_try) 2>&5
15140 echo "$as_me:15140: \$? = $ac_status" >&5
15141 (exit $ac_status); }; }; then
15142 cf_cv_lib_XCurses=yes
15144 echo "$as_me: failed program was:" >&5
15145 cat conftest.$ac_ext >&5
15146 cf_cv_lib_XCurses=no
15148 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15151 echo "$as_me:15151: result: $cf_cv_lib_XCurses" >&5
15152 echo "${ECHO_T}$cf_cv_lib_XCurses" >&6
15156 if test $cf_cv_lib_XCurses = yes ; then
15158 cat >>confdefs.h <<\EOF
15162 cat >>confdefs.h <<\EOF
15166 echo "$as_me:15166: checking for xcurses.h" >&5
15167 echo $ECHO_N "checking for xcurses.h... $ECHO_C" >&6
15168 if test "${ac_cv_header_xcurses_h+set}" = set; then
15169 echo $ECHO_N "(cached) $ECHO_C" >&6
15171 cat >conftest.$ac_ext <<_ACEOF
15172 #line 15172 "configure"
15173 #include "confdefs.h"
15174 #include <xcurses.h>
15176 if { (eval echo "$as_me:15176: \"$ac_cpp conftest.$ac_ext\"") >&5
15177 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15179 egrep -v '^ *\+' conftest.er1 >conftest.err
15181 cat conftest.err >&5
15182 echo "$as_me:15182: \$? = $ac_status" >&5
15183 (exit $ac_status); } >/dev/null; then
15184 if test -s conftest.err; then
15185 ac_cpp_err=$ac_c_preproc_warn_flag
15192 if test -z "$ac_cpp_err"; then
15193 ac_cv_header_xcurses_h=yes
15195 echo "$as_me: failed program was:" >&5
15196 cat conftest.$ac_ext >&5
15197 ac_cv_header_xcurses_h=no
15199 rm -f conftest.err conftest.$ac_ext
15201 echo "$as_me:15201: result: $ac_cv_header_xcurses_h" >&5
15202 echo "${ECHO_T}$ac_cv_header_xcurses_h" >&6
15203 if test $ac_cv_header_xcurses_h = yes; then
15205 cat >>confdefs.h <<\EOF
15206 #define HAVE_XCURSES 1
15212 { { echo "$as_me:15212: error: Cannot link with XCurses" >&5
15213 echo "$as_me: error: Cannot link with XCurses" >&2;}
15214 { (exit 1); exit 1; }; }
15219 { { echo "$as_me:15219: error: unexpected screen-value: $cf_cv_screen" >&5
15220 echo "$as_me: error: unexpected screen-value: $cf_cv_screen" >&2;}
15221 { (exit 1); exit 1; }; }
15225 : ${cf_nculib_root:=$cf_cv_screen}
15226 as_ac_Lib=`echo "ac_cv_lib_$cf_nculib_root''__nc_init_pthreads" | $as_tr_sh`
15227 echo "$as_me:15227: checking for _nc_init_pthreads in -l$cf_nculib_root" >&5
15228 echo $ECHO_N "checking for _nc_init_pthreads in -l$cf_nculib_root... $ECHO_C" >&6
15229 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
15230 echo $ECHO_N "(cached) $ECHO_C" >&6
15232 ac_check_lib_save_LIBS=$LIBS
15233 LIBS="-l$cf_nculib_root $LIBS"
15234 cat >conftest.$ac_ext <<_ACEOF
15235 #line 15235 "configure"
15236 #include "confdefs.h"
15238 /* Override any gcc2 internal prototype to avoid an error. */
15242 /* We use char because int might match the return type of a gcc2
15243 builtin and then its argument prototype would still apply. */
15244 char _nc_init_pthreads ();
15248 _nc_init_pthreads ();
15253 rm -f conftest.$ac_objext conftest$ac_exeext
15254 if { (eval echo "$as_me:15254: \"$ac_link\"") >&5
15255 (eval $ac_link) 2>&5
15257 echo "$as_me:15257: \$? = $ac_status" >&5
15258 (exit $ac_status); } &&
15259 { ac_try='test -s conftest$ac_exeext'
15260 { (eval echo "$as_me:15260: \"$ac_try\"") >&5
15261 (eval $ac_try) 2>&5
15263 echo "$as_me:15263: \$? = $ac_status" >&5
15264 (exit $ac_status); }; }; then
15265 eval "$as_ac_Lib=yes"
15267 echo "$as_me: failed program was:" >&5
15268 cat conftest.$ac_ext >&5
15269 eval "$as_ac_Lib=no"
15271 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15272 LIBS=$ac_check_lib_save_LIBS
15274 echo "$as_me:15274: result: `eval echo '${'$as_ac_Lib'}'`" >&5
15275 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
15276 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
15277 cf_cv_ncurses_pthreads=yes
15279 cf_cv_ncurses_pthreads=no
15282 if test "$cf_cv_ncurses_pthreads" = yes
15285 cf_add_libs="-lpthread"
15286 # Filter out duplicates - this happens with badly-designed ".pc" files...
15287 for cf_add_1lib in $LIBS
15289 for cf_add_2lib in $cf_add_libs
15291 if test "x$cf_add_1lib" = "x$cf_add_2lib"
15297 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
15299 LIBS="$cf_add_libs"
15303 case $cf_cv_screen in
15305 cf_cv_libtype=`echo "$cf_cv_screen" | sed -e 's/^ncurses//'`
15309 echo "$as_me:15309: checking for X11 rgb file" >&5
15310 echo $ECHO_N "checking for X11 rgb file... $ECHO_C" >&6
15312 # Check whether --with-x11-rgb or --without-x11-rgb was given.
15313 if test "${with_x11_rgb+set}" = set; then
15314 withval="$with_x11_rgb"
15320 if test "x$RGB_PATH" = xauto
15322 RGB_PATH='${exec_prefix}/lib/X11/rgb.txt'
15324 /opt/local/share/X11/rgb.txt \
15325 /opt/X11/share/X11/rgb.txt \
15326 /usr/share/X11/rgb.txt \
15327 /usr/X11/share/X11/rgb.txt \
15328 /usr/X11/lib/X11/rgb.txt \
15329 /usr/lib/X11/rgb.txt \
15331 /usr/pkg/lib/X11/rgb.txt \
15332 /usr/X11R7/lib/X11/rgb.txt \
15333 /usr/X11R6/lib/X11/rgb.txt \
15334 /usr/X11R5/lib/X11/rgb.txt \
15335 /usr/X11R4/lib/X11/rgb.txt \
15336 /usr/local/lib/X11/rgb.txt \
15337 /usr/local/share/X11/rgb.txt \
15338 /usr/lib64/X11/rgb.txt
15340 if test -f "$cf_path" ; then
15341 RGB_PATH="$cf_path"
15348 if test "x$prefix" != xNONE; then
15349 cf_path_syntax="$prefix"
15351 cf_path_syntax="$ac_default_prefix"
15354 case ".$cf_path" in
15355 (.\$\(*\)*|.\'*\'*)
15359 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
15361 (.\${*prefix}*|.\${*dir}*)
15362 eval cf_path="$cf_path"
15363 case ".$cf_path" in
15365 cf_path=`echo $cf_path | sed -e s%NONE%$cf_path_syntax%`
15370 cf_path=`echo $cf_path | sed -e s%NONE%$cf_path_syntax%`
15373 { { echo "$as_me:15373: error: expected a pathname, not \"$cf_path\"" >&5
15374 echo "$as_me: error: expected a pathname, not \"$cf_path\"" >&2;}
15375 { (exit 1); exit 1; }; }
15381 echo "$as_me:15381: result: $RGB_PATH" >&5
15382 echo "${ECHO_T}$RGB_PATH" >&6
15384 cat >>confdefs.h <<EOF
15385 #define RGB_PATH "$cf_path"
15389 if test "$RGB_PATH" = no
15396 case $cf_cv_screen in
15398 cf_default_panel=no
15401 cf_default_tinfo=no
15403 (xcurses|bsdcurses)
15404 cf_default_panel=no
15407 cf_default_tinfo=yes
15410 cf_default_panel=yes
15411 cf_default_form=yes
15412 cf_default_menu=yes
15413 cf_default_tinfo=yes
15414 case $cf_cv_screen in
15416 cf_curses_headers="nc_alloc.h nomacros.h term_entry.h"
15422 echo "$as_me:15422: checking if you want to check for panel functions" >&5
15423 echo $ECHO_N "checking if you want to check for panel functions... $ECHO_C" >&6
15425 # Check whether --enable-panel or --disable-panel was given.
15426 if test "${enable_panel+set}" = set; then
15427 enableval="$enable_panel"
15428 test "$enableval" != no && enableval=yes
15429 if test "$enableval" != "yes" ; then
15432 cf_enable_panel=$cf_default_panel
15436 cf_enable_panel=$cf_default_panel
15439 echo "$as_me:15439: result: $cf_enable_panel" >&5
15440 echo "${ECHO_T}$cf_enable_panel" >&6
15441 if test $cf_enable_panel = yes
15444 cf_have_curses_lib=no
15446 : ${NCURSES_CONFIG_PKG:=none}
15447 if test "x${NCURSES_CONFIG_PKG}" = xnone; then
15449 elif test "x${PKG_CONFIG:=none}" != xnone; then
15450 echo "$as_me:15450: checking pkg-config for panel$cf_cv_libtype" >&5
15451 echo $ECHO_N "checking pkg-config for panel$cf_cv_libtype... $ECHO_C" >&6
15452 if "$PKG_CONFIG" --exists panel$cf_cv_libtype ; then
15453 echo "$as_me:15453: result: yes" >&5
15454 echo "${ECHO_T}yes" >&6
15456 echo "$as_me:15456: checking if the panel$cf_cv_libtype package files work" >&5
15457 echo $ECHO_N "checking if the panel$cf_cv_libtype package files work... $ECHO_C" >&6
15459 cf_save_CPPFLAGS="$CPPFLAGS"
15460 cf_save_LIBS="$LIBS"
15465 cf_new_extra_cppflags=
15467 for cf_add_cflags in `$PKG_CONFIG --cflags panel$cf_cv_libtype`
15469 case $cf_fix_cppflags in
15471 case $cf_add_cflags in
15472 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
15473 case $cf_add_cflags in
15475 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
15477 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15478 && test -z "${cf_tst_cflags}" \
15479 && cf_fix_cppflags=yes
15481 if test $cf_fix_cppflags = yes ; then
15483 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15484 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15487 elif test "${cf_tst_cflags}" = "\"'" ; then
15489 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15490 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15496 case "$CPPFLAGS" in
15500 case $cf_add_cflags in
15502 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
15504 CPPFLAGS=`echo "$CPPFLAGS" | \
15505 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
15506 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
15511 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
15512 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
15519 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
15520 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
15527 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15528 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15530 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
15532 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15533 && test -z "${cf_tst_cflags}" \
15534 && cf_fix_cppflags=no
15539 if test -n "$cf_new_cflags" ; then
15541 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
15542 CFLAGS="${CFLAGS}$cf_new_cflags"
15546 if test -n "$cf_new_cppflags" ; then
15548 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
15549 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
15553 if test -n "$cf_new_extra_cppflags" ; then
15555 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
15556 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
15560 cf_add_libs="`$PKG_CONFIG --libs panel$cf_cv_libtype`"
15561 # Filter out duplicates - this happens with badly-designed ".pc" files...
15562 for cf_add_1lib in $LIBS
15564 for cf_add_2lib in $cf_add_libs
15566 if test "x$cf_add_1lib" = "x$cf_add_2lib"
15572 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
15574 LIBS="$cf_add_libs"
15576 cat >conftest.$ac_ext <<_ACEOF
15577 #line 15577 "configure"
15578 #include "confdefs.h"
15583 (void) new_panel ( 0 );
15588 rm -f conftest.$ac_objext conftest$ac_exeext
15589 if { (eval echo "$as_me:15589: \"$ac_link\"") >&5
15590 (eval $ac_link) 2>&5
15592 echo "$as_me:15592: \$? = $ac_status" >&5
15593 (exit $ac_status); } &&
15594 { ac_try='test -s conftest$ac_exeext'
15595 { (eval echo "$as_me:15595: \"$ac_try\"") >&5
15596 (eval $ac_try) 2>&5
15598 echo "$as_me:15598: \$? = $ac_status" >&5
15599 (exit $ac_status); }; }; then
15600 if test "$cross_compiling" = yes; then
15601 cf_have_curses_lib=maybe
15603 cat >conftest.$ac_ext <<_ACEOF
15604 #line 15604 "configure"
15605 #include "confdefs.h"
15608 { (void) new_panel ( 0 ); return 0; }
15610 rm -f conftest$ac_exeext
15611 if { (eval echo "$as_me:15611: \"$ac_link\"") >&5
15612 (eval $ac_link) 2>&5
15614 echo "$as_me:15614: \$? = $ac_status" >&5
15615 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15616 { (eval echo "$as_me:15616: \"$ac_try\"") >&5
15617 (eval $ac_try) 2>&5
15619 echo "$as_me:15619: \$? = $ac_status" >&5
15620 (exit $ac_status); }; }; then
15621 cf_have_curses_lib=yes
15623 echo "$as_me: program exited with status $ac_status" >&5
15624 echo "$as_me: failed program was:" >&5
15625 cat conftest.$ac_ext >&5
15626 cf_have_curses_lib=no
15628 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15631 echo "$as_me: failed program was:" >&5
15632 cat conftest.$ac_ext >&5
15633 cf_have_curses_lib=no
15635 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15636 echo "$as_me:15636: result: $cf_have_curses_lib" >&5
15637 echo "${ECHO_T}$cf_have_curses_lib" >&6
15638 test "$cf_have_curses_lib" = maybe && cf_have_curses_lib=yes
15639 if test "$cf_have_curses_lib" != "yes"
15641 CPPFLAGS="$cf_save_CPPFLAGS"
15642 LIBS="$cf_save_LIBS"
15645 cf_upper=`echo "have_libpanel" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
15647 cat >>confdefs.h <<EOF
15648 #define $cf_upper 1
15654 if test "$cf_have_curses_lib" = no; then
15655 as_ac_Lib=`echo "ac_cv_lib_panel$cf_cv_libtype''_new_panel" | $as_tr_sh`
15656 echo "$as_me:15656: checking for new_panel in -lpanel$cf_cv_libtype" >&5
15657 echo $ECHO_N "checking for new_panel in -lpanel$cf_cv_libtype... $ECHO_C" >&6
15658 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
15659 echo $ECHO_N "(cached) $ECHO_C" >&6
15661 ac_check_lib_save_LIBS=$LIBS
15662 LIBS="-lpanel$cf_cv_libtype $LIBS"
15663 cat >conftest.$ac_ext <<_ACEOF
15664 #line 15664 "configure"
15665 #include "confdefs.h"
15667 /* Override any gcc2 internal prototype to avoid an error. */
15671 /* We use char because int might match the return type of a gcc2
15672 builtin and then its argument prototype would still apply. */
15682 rm -f conftest.$ac_objext conftest$ac_exeext
15683 if { (eval echo "$as_me:15683: \"$ac_link\"") >&5
15684 (eval $ac_link) 2>&5
15686 echo "$as_me:15686: \$? = $ac_status" >&5
15687 (exit $ac_status); } &&
15688 { ac_try='test -s conftest$ac_exeext'
15689 { (eval echo "$as_me:15689: \"$ac_try\"") >&5
15690 (eval $ac_try) 2>&5
15692 echo "$as_me:15692: \$? = $ac_status" >&5
15693 (exit $ac_status); }; }; then
15694 eval "$as_ac_Lib=yes"
15696 echo "$as_me: failed program was:" >&5
15697 cat conftest.$ac_ext >&5
15698 eval "$as_ac_Lib=no"
15700 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15701 LIBS=$ac_check_lib_save_LIBS
15703 echo "$as_me:15703: result: `eval echo '${'$as_ac_Lib'}'`" >&5
15704 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
15705 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
15707 cf_upper=`echo "have_libpanel" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
15709 cf_add_libs="-lpanel$cf_cv_libtype"
15710 # Filter out duplicates - this happens with badly-designed ".pc" files...
15711 for cf_add_1lib in $LIBS
15713 for cf_add_2lib in $cf_add_libs
15715 if test "x$cf_add_1lib" = "x$cf_add_2lib"
15721 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
15723 LIBS="$cf_add_libs"
15725 cat >>confdefs.h <<EOF
15726 #define $cf_upper 1
15733 cf_curses_headers="$cf_curses_headers panel.h"
15736 echo "$as_me:15736: checking if you want to check for menu functions" >&5
15737 echo $ECHO_N "checking if you want to check for menu functions... $ECHO_C" >&6
15739 # Check whether --enable-menu or --disable-menu was given.
15740 if test "${enable_menu+set}" = set; then
15741 enableval="$enable_menu"
15742 test "$enableval" != no && enableval=yes
15743 if test "$enableval" != "yes" ; then
15746 cf_enable_menu=$cf_default_menu
15750 cf_enable_menu=$cf_default_menu
15753 echo "$as_me:15753: result: $cf_enable_menu" >&5
15754 echo "${ECHO_T}$cf_enable_menu" >&6
15755 if test $cf_enable_menu = yes
15757 case $cf_cv_screen in
15762 echo "$as_me:15762: checking for NetBSD menu.h" >&5
15763 echo $ECHO_N "checking for NetBSD menu.h... $ECHO_C" >&6
15764 if test "${cf_cv_netbsd_menu_h+set}" = set; then
15765 echo $ECHO_N "(cached) $ECHO_C" >&6
15768 cat >conftest.$ac_ext <<_ACEOF
15769 #line 15769 "configure"
15770 #include "confdefs.h"
15772 #include <${cf_cv_ncurses_header:-curses.h}>
15780 int y = menu->max_item_width;
15786 rm -f conftest.$ac_objext
15787 if { (eval echo "$as_me:15787: \"$ac_compile\"") >&5
15788 (eval $ac_compile) 2>&5
15790 echo "$as_me:15790: \$? = $ac_status" >&5
15791 (exit $ac_status); } &&
15792 { ac_try='test -s conftest.$ac_objext'
15793 { (eval echo "$as_me:15793: \"$ac_try\"") >&5
15794 (eval $ac_try) 2>&5
15796 echo "$as_me:15796: \$? = $ac_status" >&5
15797 (exit $ac_status); }; }; then
15798 cf_cv_netbsd_menu_h=yes
15801 echo "$as_me: failed program was:" >&5
15802 cat conftest.$ac_ext >&5
15803 cf_cv_netbsd_menu_h=no
15805 rm -f conftest.$ac_objext conftest.$ac_ext
15808 echo "$as_me:15808: result: $cf_cv_netbsd_menu_h" >&5
15809 echo "${ECHO_T}$cf_cv_netbsd_menu_h" >&6
15811 test "$cf_cv_netbsd_menu_h" = yes &&
15812 cat >>confdefs.h <<\EOF
15813 #define HAVE_NETBSD_MENU_H 1
15819 cf_have_curses_lib=no
15821 : ${NCURSES_CONFIG_PKG:=none}
15822 if test "x${NCURSES_CONFIG_PKG}" = xnone; then
15824 elif test "x${PKG_CONFIG:=none}" != xnone; then
15825 echo "$as_me:15825: checking pkg-config for menu$cf_cv_libtype" >&5
15826 echo $ECHO_N "checking pkg-config for menu$cf_cv_libtype... $ECHO_C" >&6
15827 if "$PKG_CONFIG" --exists menu$cf_cv_libtype ; then
15828 echo "$as_me:15828: result: yes" >&5
15829 echo "${ECHO_T}yes" >&6
15831 echo "$as_me:15831: checking if the menu$cf_cv_libtype package files work" >&5
15832 echo $ECHO_N "checking if the menu$cf_cv_libtype package files work... $ECHO_C" >&6
15834 cf_save_CPPFLAGS="$CPPFLAGS"
15835 cf_save_LIBS="$LIBS"
15840 cf_new_extra_cppflags=
15842 for cf_add_cflags in `$PKG_CONFIG --cflags menu$cf_cv_libtype`
15844 case $cf_fix_cppflags in
15846 case $cf_add_cflags in
15847 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
15848 case $cf_add_cflags in
15850 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
15852 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15853 && test -z "${cf_tst_cflags}" \
15854 && cf_fix_cppflags=yes
15856 if test $cf_fix_cppflags = yes ; then
15858 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15859 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15862 elif test "${cf_tst_cflags}" = "\"'" ; then
15864 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15865 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15871 case "$CPPFLAGS" in
15875 case $cf_add_cflags in
15877 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
15879 CPPFLAGS=`echo "$CPPFLAGS" | \
15880 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
15881 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
15886 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
15887 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
15894 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
15895 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
15902 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15903 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15905 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
15907 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15908 && test -z "${cf_tst_cflags}" \
15909 && cf_fix_cppflags=no
15914 if test -n "$cf_new_cflags" ; then
15916 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
15917 CFLAGS="${CFLAGS}$cf_new_cflags"
15921 if test -n "$cf_new_cppflags" ; then
15923 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
15924 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
15928 if test -n "$cf_new_extra_cppflags" ; then
15930 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
15931 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
15935 cf_add_libs="`$PKG_CONFIG --libs menu$cf_cv_libtype`"
15936 # Filter out duplicates - this happens with badly-designed ".pc" files...
15937 for cf_add_1lib in $LIBS
15939 for cf_add_2lib in $cf_add_libs
15941 if test "x$cf_add_1lib" = "x$cf_add_2lib"
15947 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
15949 LIBS="$cf_add_libs"
15951 cat >conftest.$ac_ext <<_ACEOF
15952 #line 15952 "configure"
15953 #include "confdefs.h"
15958 (void) menu_driver ( 0,0 );
15963 rm -f conftest.$ac_objext conftest$ac_exeext
15964 if { (eval echo "$as_me:15964: \"$ac_link\"") >&5
15965 (eval $ac_link) 2>&5
15967 echo "$as_me:15967: \$? = $ac_status" >&5
15968 (exit $ac_status); } &&
15969 { ac_try='test -s conftest$ac_exeext'
15970 { (eval echo "$as_me:15970: \"$ac_try\"") >&5
15971 (eval $ac_try) 2>&5
15973 echo "$as_me:15973: \$? = $ac_status" >&5
15974 (exit $ac_status); }; }; then
15975 if test "$cross_compiling" = yes; then
15976 cf_have_curses_lib=maybe
15978 cat >conftest.$ac_ext <<_ACEOF
15979 #line 15979 "configure"
15980 #include "confdefs.h"
15983 { (void) menu_driver ( 0,0 ); return 0; }
15985 rm -f conftest$ac_exeext
15986 if { (eval echo "$as_me:15986: \"$ac_link\"") >&5
15987 (eval $ac_link) 2>&5
15989 echo "$as_me:15989: \$? = $ac_status" >&5
15990 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15991 { (eval echo "$as_me:15991: \"$ac_try\"") >&5
15992 (eval $ac_try) 2>&5
15994 echo "$as_me:15994: \$? = $ac_status" >&5
15995 (exit $ac_status); }; }; then
15996 cf_have_curses_lib=yes
15998 echo "$as_me: program exited with status $ac_status" >&5
15999 echo "$as_me: failed program was:" >&5
16000 cat conftest.$ac_ext >&5
16001 cf_have_curses_lib=no
16003 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16006 echo "$as_me: failed program was:" >&5
16007 cat conftest.$ac_ext >&5
16008 cf_have_curses_lib=no
16010 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16011 echo "$as_me:16011: result: $cf_have_curses_lib" >&5
16012 echo "${ECHO_T}$cf_have_curses_lib" >&6
16013 test "$cf_have_curses_lib" = maybe && cf_have_curses_lib=yes
16014 if test "$cf_have_curses_lib" != "yes"
16016 CPPFLAGS="$cf_save_CPPFLAGS"
16017 LIBS="$cf_save_LIBS"
16020 cf_upper=`echo "have_libmenu" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
16022 cat >>confdefs.h <<EOF
16023 #define $cf_upper 1
16029 if test "$cf_have_curses_lib" = no; then
16030 as_ac_Lib=`echo "ac_cv_lib_menu$cf_cv_libtype''_menu_driver" | $as_tr_sh`
16031 echo "$as_me:16031: checking for menu_driver in -lmenu$cf_cv_libtype" >&5
16032 echo $ECHO_N "checking for menu_driver in -lmenu$cf_cv_libtype... $ECHO_C" >&6
16033 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
16034 echo $ECHO_N "(cached) $ECHO_C" >&6
16036 ac_check_lib_save_LIBS=$LIBS
16037 LIBS="-lmenu$cf_cv_libtype $LIBS"
16038 cat >conftest.$ac_ext <<_ACEOF
16039 #line 16039 "configure"
16040 #include "confdefs.h"
16042 /* Override any gcc2 internal prototype to avoid an error. */
16046 /* We use char because int might match the return type of a gcc2
16047 builtin and then its argument prototype would still apply. */
16048 char menu_driver ();
16057 rm -f conftest.$ac_objext conftest$ac_exeext
16058 if { (eval echo "$as_me:16058: \"$ac_link\"") >&5
16059 (eval $ac_link) 2>&5
16061 echo "$as_me:16061: \$? = $ac_status" >&5
16062 (exit $ac_status); } &&
16063 { ac_try='test -s conftest$ac_exeext'
16064 { (eval echo "$as_me:16064: \"$ac_try\"") >&5
16065 (eval $ac_try) 2>&5
16067 echo "$as_me:16067: \$? = $ac_status" >&5
16068 (exit $ac_status); }; }; then
16069 eval "$as_ac_Lib=yes"
16071 echo "$as_me: failed program was:" >&5
16072 cat conftest.$ac_ext >&5
16073 eval "$as_ac_Lib=no"
16075 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16076 LIBS=$ac_check_lib_save_LIBS
16078 echo "$as_me:16078: result: `eval echo '${'$as_ac_Lib'}'`" >&5
16079 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
16080 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
16082 cf_upper=`echo "have_libmenu" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
16084 cf_add_libs="-lmenu$cf_cv_libtype"
16085 # Filter out duplicates - this happens with badly-designed ".pc" files...
16086 for cf_add_1lib in $LIBS
16088 for cf_add_2lib in $cf_add_libs
16090 if test "x$cf_add_1lib" = "x$cf_add_2lib"
16096 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
16098 LIBS="$cf_add_libs"
16100 cat >>confdefs.h <<EOF
16101 #define $cf_upper 1
16108 cf_curses_headers="$cf_curses_headers menu.h"
16111 echo "$as_me:16111: checking if you want to check for form functions" >&5
16112 echo $ECHO_N "checking if you want to check for form functions... $ECHO_C" >&6
16114 # Check whether --enable-form or --disable-form was given.
16115 if test "${enable_form+set}" = set; then
16116 enableval="$enable_form"
16117 test "$enableval" != no && enableval=yes
16118 if test "$enableval" != "yes" ; then
16121 cf_enable_form=$cf_default_form
16125 cf_enable_form=$cf_default_form
16128 echo "$as_me:16128: result: $cf_enable_form" >&5
16129 echo "${ECHO_T}$cf_enable_form" >&6
16130 if test $cf_enable_form = yes
16132 case $cf_cv_screen in
16137 echo "$as_me:16137: checking for NetBSD form.h" >&5
16138 echo $ECHO_N "checking for NetBSD form.h... $ECHO_C" >&6
16139 if test "${cf_cv_netbsd_form_h+set}" = set; then
16140 echo $ECHO_N "(cached) $ECHO_C" >&6
16143 cat >conftest.$ac_ext <<_ACEOF
16144 #line 16144 "configure"
16145 #include "confdefs.h"
16147 #include <${cf_cv_ncurses_header:-curses.h}>
16155 int y = current_field(form)->cursor_ypos;
16156 int x = current_field(form)->cursor_xpos;
16162 rm -f conftest.$ac_objext
16163 if { (eval echo "$as_me:16163: \"$ac_compile\"") >&5
16164 (eval $ac_compile) 2>&5
16166 echo "$as_me:16166: \$? = $ac_status" >&5
16167 (exit $ac_status); } &&
16168 { ac_try='test -s conftest.$ac_objext'
16169 { (eval echo "$as_me:16169: \"$ac_try\"") >&5
16170 (eval $ac_try) 2>&5
16172 echo "$as_me:16172: \$? = $ac_status" >&5
16173 (exit $ac_status); }; }; then
16174 cf_cv_netbsd_form_h=yes
16177 echo "$as_me: failed program was:" >&5
16178 cat conftest.$ac_ext >&5
16179 cf_cv_netbsd_form_h=no
16181 rm -f conftest.$ac_objext conftest.$ac_ext
16184 echo "$as_me:16184: result: $cf_cv_netbsd_form_h" >&5
16185 echo "${ECHO_T}$cf_cv_netbsd_form_h" >&6
16187 test "$cf_cv_netbsd_form_h" = yes &&
16188 cat >>confdefs.h <<\EOF
16189 #define HAVE_NETBSD_FORM_H 1
16195 cf_have_curses_lib=no
16197 : ${NCURSES_CONFIG_PKG:=none}
16198 if test "x${NCURSES_CONFIG_PKG}" = xnone; then
16200 elif test "x${PKG_CONFIG:=none}" != xnone; then
16201 echo "$as_me:16201: checking pkg-config for form$cf_cv_libtype" >&5
16202 echo $ECHO_N "checking pkg-config for form$cf_cv_libtype... $ECHO_C" >&6
16203 if "$PKG_CONFIG" --exists form$cf_cv_libtype ; then
16204 echo "$as_me:16204: result: yes" >&5
16205 echo "${ECHO_T}yes" >&6
16207 echo "$as_me:16207: checking if the form$cf_cv_libtype package files work" >&5
16208 echo $ECHO_N "checking if the form$cf_cv_libtype package files work... $ECHO_C" >&6
16210 cf_save_CPPFLAGS="$CPPFLAGS"
16211 cf_save_LIBS="$LIBS"
16216 cf_new_extra_cppflags=
16218 for cf_add_cflags in `$PKG_CONFIG --cflags form$cf_cv_libtype`
16220 case $cf_fix_cppflags in
16222 case $cf_add_cflags in
16223 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
16224 case $cf_add_cflags in
16226 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
16228 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
16229 && test -z "${cf_tst_cflags}" \
16230 && cf_fix_cppflags=yes
16232 if test $cf_fix_cppflags = yes ; then
16234 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
16235 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
16238 elif test "${cf_tst_cflags}" = "\"'" ; then
16240 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
16241 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
16247 case "$CPPFLAGS" in
16251 case $cf_add_cflags in
16253 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
16255 CPPFLAGS=`echo "$CPPFLAGS" | \
16256 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
16257 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
16262 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
16263 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
16270 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
16271 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
16278 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
16279 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
16281 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
16283 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
16284 && test -z "${cf_tst_cflags}" \
16285 && cf_fix_cppflags=no
16290 if test -n "$cf_new_cflags" ; then
16292 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
16293 CFLAGS="${CFLAGS}$cf_new_cflags"
16297 if test -n "$cf_new_cppflags" ; then
16299 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
16300 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
16304 if test -n "$cf_new_extra_cppflags" ; then
16306 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
16307 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
16311 cf_add_libs="`$PKG_CONFIG --libs form$cf_cv_libtype`"
16312 # Filter out duplicates - this happens with badly-designed ".pc" files...
16313 for cf_add_1lib in $LIBS
16315 for cf_add_2lib in $cf_add_libs
16317 if test "x$cf_add_1lib" = "x$cf_add_2lib"
16323 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
16325 LIBS="$cf_add_libs"
16327 cat >conftest.$ac_ext <<_ACEOF
16328 #line 16328 "configure"
16329 #include "confdefs.h"
16334 (void) form_driver ( 0,0 );
16339 rm -f conftest.$ac_objext conftest$ac_exeext
16340 if { (eval echo "$as_me:16340: \"$ac_link\"") >&5
16341 (eval $ac_link) 2>&5
16343 echo "$as_me:16343: \$? = $ac_status" >&5
16344 (exit $ac_status); } &&
16345 { ac_try='test -s conftest$ac_exeext'
16346 { (eval echo "$as_me:16346: \"$ac_try\"") >&5
16347 (eval $ac_try) 2>&5
16349 echo "$as_me:16349: \$? = $ac_status" >&5
16350 (exit $ac_status); }; }; then
16351 if test "$cross_compiling" = yes; then
16352 cf_have_curses_lib=maybe
16354 cat >conftest.$ac_ext <<_ACEOF
16355 #line 16355 "configure"
16356 #include "confdefs.h"
16359 { (void) form_driver ( 0,0 ); return 0; }
16361 rm -f conftest$ac_exeext
16362 if { (eval echo "$as_me:16362: \"$ac_link\"") >&5
16363 (eval $ac_link) 2>&5
16365 echo "$as_me:16365: \$? = $ac_status" >&5
16366 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16367 { (eval echo "$as_me:16367: \"$ac_try\"") >&5
16368 (eval $ac_try) 2>&5
16370 echo "$as_me:16370: \$? = $ac_status" >&5
16371 (exit $ac_status); }; }; then
16372 cf_have_curses_lib=yes
16374 echo "$as_me: program exited with status $ac_status" >&5
16375 echo "$as_me: failed program was:" >&5
16376 cat conftest.$ac_ext >&5
16377 cf_have_curses_lib=no
16379 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16382 echo "$as_me: failed program was:" >&5
16383 cat conftest.$ac_ext >&5
16384 cf_have_curses_lib=no
16386 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16387 echo "$as_me:16387: result: $cf_have_curses_lib" >&5
16388 echo "${ECHO_T}$cf_have_curses_lib" >&6
16389 test "$cf_have_curses_lib" = maybe && cf_have_curses_lib=yes
16390 if test "$cf_have_curses_lib" != "yes"
16392 CPPFLAGS="$cf_save_CPPFLAGS"
16393 LIBS="$cf_save_LIBS"
16396 cf_upper=`echo "have_libform" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
16398 cat >>confdefs.h <<EOF
16399 #define $cf_upper 1
16405 if test "$cf_have_curses_lib" = no; then
16406 as_ac_Lib=`echo "ac_cv_lib_form$cf_cv_libtype''_form_driver" | $as_tr_sh`
16407 echo "$as_me:16407: checking for form_driver in -lform$cf_cv_libtype" >&5
16408 echo $ECHO_N "checking for form_driver in -lform$cf_cv_libtype... $ECHO_C" >&6
16409 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
16410 echo $ECHO_N "(cached) $ECHO_C" >&6
16412 ac_check_lib_save_LIBS=$LIBS
16413 LIBS="-lform$cf_cv_libtype $LIBS"
16414 cat >conftest.$ac_ext <<_ACEOF
16415 #line 16415 "configure"
16416 #include "confdefs.h"
16418 /* Override any gcc2 internal prototype to avoid an error. */
16422 /* We use char because int might match the return type of a gcc2
16423 builtin and then its argument prototype would still apply. */
16424 char form_driver ();
16433 rm -f conftest.$ac_objext conftest$ac_exeext
16434 if { (eval echo "$as_me:16434: \"$ac_link\"") >&5
16435 (eval $ac_link) 2>&5
16437 echo "$as_me:16437: \$? = $ac_status" >&5
16438 (exit $ac_status); } &&
16439 { ac_try='test -s conftest$ac_exeext'
16440 { (eval echo "$as_me:16440: \"$ac_try\"") >&5
16441 (eval $ac_try) 2>&5
16443 echo "$as_me:16443: \$? = $ac_status" >&5
16444 (exit $ac_status); }; }; then
16445 eval "$as_ac_Lib=yes"
16447 echo "$as_me: failed program was:" >&5
16448 cat conftest.$ac_ext >&5
16449 eval "$as_ac_Lib=no"
16451 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16452 LIBS=$ac_check_lib_save_LIBS
16454 echo "$as_me:16454: result: `eval echo '${'$as_ac_Lib'}'`" >&5
16455 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
16456 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
16458 cf_upper=`echo "have_libform" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
16460 cf_add_libs="-lform$cf_cv_libtype"
16461 # Filter out duplicates - this happens with badly-designed ".pc" files...
16462 for cf_add_1lib in $LIBS
16464 for cf_add_2lib in $cf_add_libs
16466 if test "x$cf_add_1lib" = "x$cf_add_2lib"
16472 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
16474 LIBS="$cf_add_libs"
16476 cat >>confdefs.h <<EOF
16477 #define $cf_upper 1
16484 cf_curses_headers="$cf_curses_headers form.h"
16487 # look for curses-related headers
16489 for ac_header in $cf_curses_headers
16491 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
16492 echo "$as_me:16492: checking for $ac_header" >&5
16493 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
16494 if eval "test \"\${$as_ac_Header+set}\" = set"; then
16495 echo $ECHO_N "(cached) $ECHO_C" >&6
16497 cat >conftest.$ac_ext <<_ACEOF
16498 #line 16498 "configure"
16499 #include "confdefs.h"
16500 #include <$ac_header>
16502 if { (eval echo "$as_me:16502: \"$ac_cpp conftest.$ac_ext\"") >&5
16503 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
16505 egrep -v '^ *\+' conftest.er1 >conftest.err
16507 cat conftest.err >&5
16508 echo "$as_me:16508: \$? = $ac_status" >&5
16509 (exit $ac_status); } >/dev/null; then
16510 if test -s conftest.err; then
16511 ac_cpp_err=$ac_c_preproc_warn_flag
16518 if test -z "$ac_cpp_err"; then
16519 eval "$as_ac_Header=yes"
16521 echo "$as_me: failed program was:" >&5
16522 cat conftest.$ac_ext >&5
16523 eval "$as_ac_Header=no"
16525 rm -f conftest.err conftest.$ac_ext
16527 echo "$as_me:16527: result: `eval echo '${'$as_ac_Header'}'`" >&5
16528 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
16529 if test `eval echo '${'$as_ac_Header'}'` = yes; then
16530 cat >>confdefs.h <<EOF
16531 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
16537 echo "$as_me:16537: checking for ANSI C header files" >&5
16538 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
16539 if test "${ac_cv_header_stdc+set}" = set; then
16540 echo $ECHO_N "(cached) $ECHO_C" >&6
16542 cat >conftest.$ac_ext <<_ACEOF
16543 #line 16543 "configure"
16544 #include "confdefs.h"
16545 #include <stdlib.h>
16546 #include <stdarg.h>
16547 #include <string.h>
16551 if { (eval echo "$as_me:16551: \"$ac_cpp conftest.$ac_ext\"") >&5
16552 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
16554 egrep -v '^ *\+' conftest.er1 >conftest.err
16556 cat conftest.err >&5
16557 echo "$as_me:16557: \$? = $ac_status" >&5
16558 (exit $ac_status); } >/dev/null; then
16559 if test -s conftest.err; then
16560 ac_cpp_err=$ac_c_preproc_warn_flag
16567 if test -z "$ac_cpp_err"; then
16568 ac_cv_header_stdc=yes
16570 echo "$as_me: failed program was:" >&5
16571 cat conftest.$ac_ext >&5
16572 ac_cv_header_stdc=no
16574 rm -f conftest.err conftest.$ac_ext
16576 if test $ac_cv_header_stdc = yes; then
16577 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
16578 cat >conftest.$ac_ext <<_ACEOF
16579 #line 16579 "configure"
16580 #include "confdefs.h"
16581 #include <string.h>
16584 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
16585 egrep "memchr" >/dev/null 2>&1; then
16588 ac_cv_header_stdc=no
16594 if test $ac_cv_header_stdc = yes; then
16595 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
16596 cat >conftest.$ac_ext <<_ACEOF
16597 #line 16597 "configure"
16598 #include "confdefs.h"
16599 #include <stdlib.h>
16602 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
16603 egrep "free" >/dev/null 2>&1; then
16606 ac_cv_header_stdc=no
16612 if test $ac_cv_header_stdc = yes; then
16613 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
16614 if test "$cross_compiling" = yes; then
16617 cat >conftest.$ac_ext <<_ACEOF
16618 #line 16618 "configure"
16619 #include "confdefs.h"
16621 #if ((' ' & 0x0FF) == 0x020)
16622 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
16623 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
16625 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
16626 || ('j' <= (c) && (c) <= 'r') \
16627 || ('s' <= (c) && (c) <= 'z'))
16628 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
16631 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
16636 for (i = 0; i < 256; i++)
16637 if (XOR (islower (i), ISLOWER (i))
16638 || toupper (i) != TOUPPER (i))
16639 $ac_main_return(2);
16640 $ac_main_return (0);
16643 rm -f conftest$ac_exeext
16644 if { (eval echo "$as_me:16644: \"$ac_link\"") >&5
16645 (eval $ac_link) 2>&5
16647 echo "$as_me:16647: \$? = $ac_status" >&5
16648 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16649 { (eval echo "$as_me:16649: \"$ac_try\"") >&5
16650 (eval $ac_try) 2>&5
16652 echo "$as_me:16652: \$? = $ac_status" >&5
16653 (exit $ac_status); }; }; then
16656 echo "$as_me: program exited with status $ac_status" >&5
16657 echo "$as_me: failed program was:" >&5
16658 cat conftest.$ac_ext >&5
16659 ac_cv_header_stdc=no
16661 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16665 echo "$as_me:16665: result: $ac_cv_header_stdc" >&5
16666 echo "${ECHO_T}$ac_cv_header_stdc" >&6
16667 if test $ac_cv_header_stdc = yes; then
16669 cat >>confdefs.h <<\EOF
16670 #define STDC_HEADERS 1
16675 echo "$as_me:16675: checking whether time.h and sys/time.h may both be included" >&5
16676 echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
16677 if test "${ac_cv_header_time+set}" = set; then
16678 echo $ECHO_N "(cached) $ECHO_C" >&6
16680 cat >conftest.$ac_ext <<_ACEOF
16681 #line 16681 "configure"
16682 #include "confdefs.h"
16683 #include <sys/types.h>
16684 #include <sys/time.h>
16690 if ((struct tm *) 0)
16696 rm -f conftest.$ac_objext
16697 if { (eval echo "$as_me:16697: \"$ac_compile\"") >&5
16698 (eval $ac_compile) 2>&5
16700 echo "$as_me:16700: \$? = $ac_status" >&5
16701 (exit $ac_status); } &&
16702 { ac_try='test -s conftest.$ac_objext'
16703 { (eval echo "$as_me:16703: \"$ac_try\"") >&5
16704 (eval $ac_try) 2>&5
16706 echo "$as_me:16706: \$? = $ac_status" >&5
16707 (exit $ac_status); }; }; then
16708 ac_cv_header_time=yes
16710 echo "$as_me: failed program was:" >&5
16711 cat conftest.$ac_ext >&5
16712 ac_cv_header_time=no
16714 rm -f conftest.$ac_objext conftest.$ac_ext
16716 echo "$as_me:16716: result: $ac_cv_header_time" >&5
16717 echo "${ECHO_T}$ac_cv_header_time" >&6
16718 if test $ac_cv_header_time = yes; then
16720 cat >>confdefs.h <<\EOF
16721 #define TIME_WITH_SYS_TIME 1
16739 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
16740 echo "$as_me:16740: checking for $ac_header" >&5
16741 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
16742 if eval "test \"\${$as_ac_Header+set}\" = set"; then
16743 echo $ECHO_N "(cached) $ECHO_C" >&6
16745 cat >conftest.$ac_ext <<_ACEOF
16746 #line 16746 "configure"
16747 #include "confdefs.h"
16748 #include <$ac_header>
16750 if { (eval echo "$as_me:16750: \"$ac_cpp conftest.$ac_ext\"") >&5
16751 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
16753 egrep -v '^ *\+' conftest.er1 >conftest.err
16755 cat conftest.err >&5
16756 echo "$as_me:16756: \$? = $ac_status" >&5
16757 (exit $ac_status); } >/dev/null; then
16758 if test -s conftest.err; then
16759 ac_cpp_err=$ac_c_preproc_warn_flag
16766 if test -z "$ac_cpp_err"; then
16767 eval "$as_ac_Header=yes"
16769 echo "$as_me: failed program was:" >&5
16770 cat conftest.$ac_ext >&5
16771 eval "$as_ac_Header=no"
16773 rm -f conftest.err conftest.$ac_ext
16775 echo "$as_me:16775: result: `eval echo '${'$as_ac_Header'}'`" >&5
16776 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
16777 if test `eval echo '${'$as_ac_Header'}'` = yes; then
16778 cat >>confdefs.h <<EOF
16779 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
16785 for ac_header in unistd.h getopt.h
16787 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
16788 echo "$as_me:16788: checking for $ac_header" >&5
16789 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
16790 if eval "test \"\${$as_ac_Header+set}\" = set"; then
16791 echo $ECHO_N "(cached) $ECHO_C" >&6
16793 cat >conftest.$ac_ext <<_ACEOF
16794 #line 16794 "configure"
16795 #include "confdefs.h"
16796 #include <$ac_header>
16798 if { (eval echo "$as_me:16798: \"$ac_cpp conftest.$ac_ext\"") >&5
16799 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
16801 egrep -v '^ *\+' conftest.er1 >conftest.err
16803 cat conftest.err >&5
16804 echo "$as_me:16804: \$? = $ac_status" >&5
16805 (exit $ac_status); } >/dev/null; then
16806 if test -s conftest.err; then
16807 ac_cpp_err=$ac_c_preproc_warn_flag
16814 if test -z "$ac_cpp_err"; then
16815 eval "$as_ac_Header=yes"
16817 echo "$as_me: failed program was:" >&5
16818 cat conftest.$ac_ext >&5
16819 eval "$as_ac_Header=no"
16821 rm -f conftest.err conftest.$ac_ext
16823 echo "$as_me:16823: result: `eval echo '${'$as_ac_Header'}'`" >&5
16824 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
16825 if test `eval echo '${'$as_ac_Header'}'` = yes; then
16826 cat >>confdefs.h <<EOF
16827 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
16833 echo "$as_me:16833: checking for header declaring getopt variables" >&5
16834 echo $ECHO_N "checking for header declaring getopt variables... $ECHO_C" >&6
16835 if test "${cf_cv_getopt_header+set}" = set; then
16836 echo $ECHO_N "(cached) $ECHO_C" >&6
16839 cf_cv_getopt_header=none
16840 for cf_header in stdio.h stdlib.h unistd.h getopt.h
16842 cat >conftest.$ac_ext <<_ACEOF
16843 #line 16843 "configure"
16844 #include "confdefs.h"
16846 #include <$cf_header>
16850 int x = optind; char *y = optarg
16855 rm -f conftest.$ac_objext
16856 if { (eval echo "$as_me:16856: \"$ac_compile\"") >&5
16857 (eval $ac_compile) 2>&5
16859 echo "$as_me:16859: \$? = $ac_status" >&5
16860 (exit $ac_status); } &&
16861 { ac_try='test -s conftest.$ac_objext'
16862 { (eval echo "$as_me:16862: \"$ac_try\"") >&5
16863 (eval $ac_try) 2>&5
16865 echo "$as_me:16865: \$? = $ac_status" >&5
16866 (exit $ac_status); }; }; then
16867 cf_cv_getopt_header=$cf_header
16870 echo "$as_me: failed program was:" >&5
16871 cat conftest.$ac_ext >&5
16873 rm -f conftest.$ac_objext conftest.$ac_ext
16877 echo "$as_me:16877: result: $cf_cv_getopt_header" >&5
16878 echo "${ECHO_T}$cf_cv_getopt_header" >&6
16879 if test $cf_cv_getopt_header != none ; then
16881 cat >>confdefs.h <<\EOF
16882 #define HAVE_GETOPT_HEADER 1
16886 if test $cf_cv_getopt_header = getopt.h ; then
16888 cat >>confdefs.h <<\EOF
16889 #define NEED_GETOPT_H 1
16901 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
16902 echo "$as_me:16902: checking for $ac_func" >&5
16903 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
16904 if eval "test \"\${$as_ac_var+set}\" = set"; then
16905 echo $ECHO_N "(cached) $ECHO_C" >&6
16907 cat >conftest.$ac_ext <<_ACEOF
16908 #line 16908 "configure"
16909 #include "confdefs.h"
16910 #define $ac_func autoconf_temporary
16911 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
16918 /* We use char because int might match the return type of a gcc2
16919 builtin and then its argument prototype would still apply. */
16920 char $ac_func (void);
16926 /* The GNU C library defines stubs for functions which it implements
16927 to always fail with ENOSYS. Some functions are actually named
16928 something starting with __ and the normal name is an alias. */
16929 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
16930 #error found stub for $ac_func
16933 return $ac_func ();
16938 rm -f conftest.$ac_objext conftest$ac_exeext
16939 if { (eval echo "$as_me:16939: \"$ac_link\"") >&5
16940 (eval $ac_link) 2>&5
16942 echo "$as_me:16942: \$? = $ac_status" >&5
16943 (exit $ac_status); } &&
16944 { ac_try='test -s conftest$ac_exeext'
16945 { (eval echo "$as_me:16945: \"$ac_try\"") >&5
16946 (eval $ac_try) 2>&5
16948 echo "$as_me:16948: \$? = $ac_status" >&5
16949 (exit $ac_status); }; }; then
16950 eval "$as_ac_var=yes"
16952 echo "$as_me: failed program was:" >&5
16953 cat conftest.$ac_ext >&5
16954 eval "$as_ac_var=no"
16956 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16958 echo "$as_me:16958: result: `eval echo '${'$as_ac_var'}'`" >&5
16959 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
16960 if test `eval echo '${'$as_ac_var'}'` = yes; then
16961 cat >>confdefs.h <<EOF
16962 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
16968 # use a compile-check to work with ncurses*-config and subdirectory includes
16969 echo "$as_me:16969: checking if we can use termcap.h" >&5
16970 echo $ECHO_N "checking if we can use termcap.h... $ECHO_C" >&6
16971 if test "${cf_cv_have_termcap_h+set}" = set; then
16972 echo $ECHO_N "(cached) $ECHO_C" >&6
16975 cat >conftest.$ac_ext <<_ACEOF
16976 #line 16976 "configure"
16977 #include "confdefs.h"
16979 #include <curses.h>
16980 #include <termcap.h>
16990 rm -f conftest.$ac_objext
16991 if { (eval echo "$as_me:16991: \"$ac_compile\"") >&5
16992 (eval $ac_compile) 2>&5
16994 echo "$as_me:16994: \$? = $ac_status" >&5
16995 (exit $ac_status); } &&
16996 { ac_try='test -s conftest.$ac_objext'
16997 { (eval echo "$as_me:16997: \"$ac_try\"") >&5
16998 (eval $ac_try) 2>&5
17000 echo "$as_me:17000: \$? = $ac_status" >&5
17001 (exit $ac_status); }; }; then
17002 cf_cv_have_termcap_h=yes
17004 echo "$as_me: failed program was:" >&5
17005 cat conftest.$ac_ext >&5
17006 cf_cv_have_termcap_h=no
17008 rm -f conftest.$ac_objext conftest.$ac_ext
17010 echo "$as_me:17010: result: $cf_cv_have_termcap_h" >&5
17011 echo "${ECHO_T}$cf_cv_have_termcap_h" >&6
17012 test "x$cf_cv_have_termcap_h" = xyes && cat >>confdefs.h <<\EOF
17013 #define HAVE_TERMCAP_H 1
17016 if test "x$ac_cv_func_getopt" = xno; then
17017 { { echo "$as_me:17017: error: getopt is required for building programs" >&5
17018 echo "$as_me: error: getopt is required for building programs" >&2;}
17019 { (exit 1); exit 1; }; }
17022 if test "$cf_enable_widec" = yes; then
17035 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
17036 echo "$as_me:17036: checking for $ac_func" >&5
17037 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
17038 if eval "test \"\${$as_ac_var+set}\" = set"; then
17039 echo $ECHO_N "(cached) $ECHO_C" >&6
17041 cat >conftest.$ac_ext <<_ACEOF
17042 #line 17042 "configure"
17043 #include "confdefs.h"
17044 #define $ac_func autoconf_temporary
17045 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
17052 /* We use char because int might match the return type of a gcc2
17053 builtin and then its argument prototype would still apply. */
17054 char $ac_func (void);
17060 /* The GNU C library defines stubs for functions which it implements
17061 to always fail with ENOSYS. Some functions are actually named
17062 something starting with __ and the normal name is an alias. */
17063 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
17064 #error found stub for $ac_func
17067 return $ac_func ();
17072 rm -f conftest.$ac_objext conftest$ac_exeext
17073 if { (eval echo "$as_me:17073: \"$ac_link\"") >&5
17074 (eval $ac_link) 2>&5
17076 echo "$as_me:17076: \$? = $ac_status" >&5
17077 (exit $ac_status); } &&
17078 { ac_try='test -s conftest$ac_exeext'
17079 { (eval echo "$as_me:17079: \"$ac_try\"") >&5
17080 (eval $ac_try) 2>&5
17082 echo "$as_me:17082: \$? = $ac_status" >&5
17083 (exit $ac_status); }; }; then
17084 eval "$as_ac_var=yes"
17086 echo "$as_me: failed program was:" >&5
17087 cat conftest.$ac_ext >&5
17088 eval "$as_ac_var=no"
17090 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17092 echo "$as_me:17092: result: `eval echo '${'$as_ac_var'}'`" >&5
17093 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
17094 if test `eval echo '${'$as_ac_var'}'` = yes; then
17095 cat >>confdefs.h <<EOF
17096 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
17104 echo "$as_me:17104: checking definition to turn on extended curses functions" >&5
17105 echo $ECHO_N "checking definition to turn on extended curses functions... $ECHO_C" >&6
17106 if test "${cf_cv_need_xopen_extension+set}" = set; then
17107 echo $ECHO_N "(cached) $ECHO_C" >&6
17110 cf_cv_need_xopen_extension=unknown
17111 cat >conftest.$ac_ext <<_ACEOF
17112 #line 17112 "configure"
17113 #include "confdefs.h"
17115 #include <stdlib.h>
17116 #include <${cf_cv_ncurses_header:-curses.h}>
17121 #if defined(NCURSES_VERSION_PATCH)
17122 #if (NCURSES_VERSION_PATCH < 20100501) && (NCURSES_VERSION_PATCH >= 20100403)
17126 #ifdef NCURSES_VERSION
17128 int check2 = curs_set((int)sizeof(check));
17130 long x = winnstr(stdscr, "", 0);
17132 getbegyx(stdscr, y1, x1)
17137 rm -f conftest.$ac_objext conftest$ac_exeext
17138 if { (eval echo "$as_me:17138: \"$ac_link\"") >&5
17139 (eval $ac_link) 2>&5
17141 echo "$as_me:17141: \$? = $ac_status" >&5
17142 (exit $ac_status); } &&
17143 { ac_try='test -s conftest$ac_exeext'
17144 { (eval echo "$as_me:17144: \"$ac_try\"") >&5
17145 (eval $ac_try) 2>&5
17147 echo "$as_me:17147: \$? = $ac_status" >&5
17148 (exit $ac_status); }; }; then
17149 cf_cv_need_xopen_extension=none
17151 echo "$as_me: failed program was:" >&5
17152 cat conftest.$ac_ext >&5
17154 for cf_try_xopen_extension in _XOPEN_SOURCE_EXTENDED NCURSES_WIDECHAR
17156 cat >conftest.$ac_ext <<_ACEOF
17157 #line 17157 "configure"
17158 #include "confdefs.h"
17160 #define $cf_try_xopen_extension 1
17161 #include <stdlib.h>
17162 #include <${cf_cv_ncurses_header:-curses.h}>
17167 #ifdef NCURSES_VERSION
17169 int check2 = curs_set((int)sizeof(check));
17171 long x = winnstr(stdscr, "", 0);
17173 getbegyx(stdscr, y1, x1)
17178 rm -f conftest.$ac_objext conftest$ac_exeext
17179 if { (eval echo "$as_me:17179: \"$ac_link\"") >&5
17180 (eval $ac_link) 2>&5
17182 echo "$as_me:17182: \$? = $ac_status" >&5
17183 (exit $ac_status); } &&
17184 { ac_try='test -s conftest$ac_exeext'
17185 { (eval echo "$as_me:17185: \"$ac_try\"") >&5
17186 (eval $ac_try) 2>&5
17188 echo "$as_me:17188: \$? = $ac_status" >&5
17189 (exit $ac_status); }; }; then
17190 cf_cv_need_xopen_extension=$cf_try_xopen_extension; break
17192 echo "$as_me: failed program was:" >&5
17193 cat conftest.$ac_ext >&5
17195 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17199 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17202 echo "$as_me:17202: result: $cf_cv_need_xopen_extension" >&5
17203 echo "${ECHO_T}$cf_cv_need_xopen_extension" >&6
17205 case $cf_cv_need_xopen_extension in
17208 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
17209 CPPFLAGS="${CPPFLAGS}-D$cf_cv_need_xopen_extension"
17214 echo "$as_me:17214: checking for term.h" >&5
17215 echo $ECHO_N "checking for term.h... $ECHO_C" >&6
17216 if test "${cf_cv_term_header+set}" = set; then
17217 echo $ECHO_N "(cached) $ECHO_C" >&6
17220 # If we found <ncurses/curses.h>, look for <ncurses/term.h>, but always look
17221 # for <term.h> if we do not find the variant.
17223 cf_header_list="term.h ncurses/term.h ncursesw/term.h"
17225 case ${cf_cv_ncurses_header:-curses.h} in
17227 cf_header_item=`echo ${cf_cv_ncurses_header:-curses.h} | sed -e 's%\..*%%' -e 's%/.*%/%'`term.h
17228 cf_header_list="$cf_header_item $cf_header_list"
17232 for cf_header in $cf_header_list
17234 cat >conftest.$ac_ext <<_ACEOF
17235 #line 17235 "configure"
17236 #include "confdefs.h"
17238 #include <${cf_cv_ncurses_header:-curses.h}>
17239 #include <${cf_header}>
17248 rm -f conftest.$ac_objext
17249 if { (eval echo "$as_me:17249: \"$ac_compile\"") >&5
17250 (eval $ac_compile) 2>&5
17252 echo "$as_me:17252: \$? = $ac_status" >&5
17253 (exit $ac_status); } &&
17254 { ac_try='test -s conftest.$ac_objext'
17255 { (eval echo "$as_me:17255: \"$ac_try\"") >&5
17256 (eval $ac_try) 2>&5
17258 echo "$as_me:17258: \$? = $ac_status" >&5
17259 (exit $ac_status); }; }; then
17260 cf_cv_term_header=$cf_header
17263 echo "$as_me: failed program was:" >&5
17264 cat conftest.$ac_ext >&5
17265 cf_cv_term_header=no
17267 rm -f conftest.$ac_objext conftest.$ac_ext
17270 case $cf_cv_term_header in
17272 # If curses is ncurses, some packagers still mess it up by trying to make
17273 # us use GNU termcap. This handles the most common case.
17274 for cf_header in ncurses/term.h ncursesw/term.h
17276 cat >conftest.$ac_ext <<_ACEOF
17277 #line 17277 "configure"
17278 #include "confdefs.h"
17280 #include <${cf_cv_ncurses_header:-curses.h}>
17281 #ifdef NCURSES_VERSION
17282 #include <${cf_header}>
17294 rm -f conftest.$ac_objext
17295 if { (eval echo "$as_me:17295: \"$ac_compile\"") >&5
17296 (eval $ac_compile) 2>&5
17298 echo "$as_me:17298: \$? = $ac_status" >&5
17299 (exit $ac_status); } &&
17300 { ac_try='test -s conftest.$ac_objext'
17301 { (eval echo "$as_me:17301: \"$ac_try\"") >&5
17302 (eval $ac_try) 2>&5
17304 echo "$as_me:17304: \$? = $ac_status" >&5
17305 (exit $ac_status); }; }; then
17306 cf_cv_term_header=$cf_header
17309 echo "$as_me: failed program was:" >&5
17310 cat conftest.$ac_ext >&5
17311 cf_cv_term_header=no
17313 rm -f conftest.$ac_objext conftest.$ac_ext
17319 echo "$as_me:17319: result: $cf_cv_term_header" >&5
17320 echo "${ECHO_T}$cf_cv_term_header" >&6
17322 case $cf_cv_term_header in
17325 cat >>confdefs.h <<\EOF
17326 #define HAVE_TERM_H 1
17332 cat >>confdefs.h <<\EOF
17333 #define HAVE_NCURSES_TERM_H 1
17339 cat >>confdefs.h <<\EOF
17340 #define HAVE_NCURSESW_TERM_H 1
17346 echo "$as_me:17346: checking for unctrl.h" >&5
17347 echo $ECHO_N "checking for unctrl.h... $ECHO_C" >&6
17348 if test "${cf_cv_unctrl_header+set}" = set; then
17349 echo $ECHO_N "(cached) $ECHO_C" >&6
17352 # If we found <ncurses/curses.h>, look for <ncurses/unctrl.h>, but always look
17353 # for <unctrl.h> if we do not find the variant.
17355 cf_header_list="unctrl.h ncurses/unctrl.h ncursesw/unctrl.h"
17357 case ${cf_cv_ncurses_header:-curses.h} in
17359 cf_header_item=`echo ${cf_cv_ncurses_header:-curses.h} | sed -e 's%\..*%%' -e 's%/.*%/%'`unctrl.h
17360 cf_header_list="$cf_header_item $cf_header_list"
17364 for cf_header in $cf_header_list
17366 cat >conftest.$ac_ext <<_ACEOF
17367 #line 17367 "configure"
17368 #include "confdefs.h"
17370 #include <${cf_cv_ncurses_header:-curses.h}>
17371 #include <${cf_header}>
17380 rm -f conftest.$ac_objext
17381 if { (eval echo "$as_me:17381: \"$ac_compile\"") >&5
17382 (eval $ac_compile) 2>&5
17384 echo "$as_me:17384: \$? = $ac_status" >&5
17385 (exit $ac_status); } &&
17386 { ac_try='test -s conftest.$ac_objext'
17387 { (eval echo "$as_me:17387: \"$ac_try\"") >&5
17388 (eval $ac_try) 2>&5
17390 echo "$as_me:17390: \$? = $ac_status" >&5
17391 (exit $ac_status); }; }; then
17392 cf_cv_unctrl_header=$cf_header
17395 echo "$as_me: failed program was:" >&5
17396 cat conftest.$ac_ext >&5
17397 cf_cv_unctrl_header=no
17399 rm -f conftest.$ac_objext conftest.$ac_ext
17403 echo "$as_me:17403: result: $cf_cv_unctrl_header" >&5
17404 echo "${ECHO_T}$cf_cv_unctrl_header" >&6
17406 case $cf_cv_unctrl_header in
17408 { echo "$as_me:17408: WARNING: unctrl.h header not found" >&5
17409 echo "$as_me: WARNING: unctrl.h header not found" >&2;}
17413 case $cf_cv_unctrl_header in
17416 cat >>confdefs.h <<\EOF
17417 #define HAVE_UNCTRL_H 1
17423 cat >>confdefs.h <<\EOF
17424 #define HAVE_NCURSES_UNCTRL_H 1
17428 (ncursesw/unctrl.h)
17430 cat >>confdefs.h <<\EOF
17431 #define HAVE_NCURSESW_UNCTRL_H 1
17439 assume_default_colors \
17454 init_extended_color \
17462 reset_color_pairs \
17477 use_default_colors \
17479 use_extended_names \
17495 cf_tr_func=`echo "$cf_func" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
17497 echo "$as_me:17497: checking for ${cf_func}" >&5
17498 echo $ECHO_N "checking for ${cf_func}... $ECHO_C" >&6
17500 echo "${as_me:-configure}:17500: testing ${cf_func} ..." 1>&5
17502 if eval "test \"\${cf_cv_func_$cf_func+set}\" = set"; then
17503 echo $ECHO_N "(cached) $ECHO_C" >&6
17506 eval cf_result='$ac_cv_func_'$cf_func
17507 if test ".$cf_result" != ".no"; then
17508 cat >conftest.$ac_ext <<_ACEOF
17509 #line 17509 "configure"
17510 #include "confdefs.h"
17512 #ifdef HAVE_XCURSES
17513 #include <xcurses.h>
17514 char * XCursesProgramName = "test";
17516 #include <${cf_cv_ncurses_header:-curses.h}>
17517 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
17518 #include <ncursesw/term.h>
17519 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
17520 #include <ncurses/term.h>
17521 #elif defined(HAVE_TERM_H)
17531 long foo = (long)(&${cf_func});
17532 fprintf(stderr, "testing linkage of $cf_func:%p\n", (void *)foo);
17533 if (foo + 1234L > 5678L)
17534 ${cf_cv_main_return:-return}(foo != 0);
17541 rm -f conftest.$ac_objext conftest$ac_exeext
17542 if { (eval echo "$as_me:17542: \"$ac_link\"") >&5
17543 (eval $ac_link) 2>&5
17545 echo "$as_me:17545: \$? = $ac_status" >&5
17546 (exit $ac_status); } &&
17547 { ac_try='test -s conftest$ac_exeext'
17548 { (eval echo "$as_me:17548: \"$ac_try\"") >&5
17549 (eval $ac_try) 2>&5
17551 echo "$as_me:17551: \$? = $ac_status" >&5
17552 (exit $ac_status); }; }; then
17555 echo "$as_me: failed program was:" >&5
17556 cat conftest.$ac_ext >&5
17559 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17561 eval 'cf_cv_func_'$cf_func'=$cf_result'
17565 # use the computed/retrieved cache-value:
17566 eval 'cf_result=$cf_cv_func_'$cf_func
17567 echo "$as_me:17567: result: $cf_result" >&5
17568 echo "${ECHO_T}$cf_result" >&6
17569 if test $cf_result != no; then
17570 cat >>confdefs.h <<EOF
17571 #define HAVE_${cf_tr_func} 1
17577 for cf_func in tputs
17580 cf_tr_func=`echo "$cf_func" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
17582 echo "$as_me:17582: checking for ${cf_func}" >&5
17583 echo $ECHO_N "checking for ${cf_func}... $ECHO_C" >&6
17585 echo "${as_me:-configure}:17585: testing ${cf_func} ..." 1>&5
17587 if eval "test \"\${cf_cv_func_$cf_func+set}\" = set"; then
17588 echo $ECHO_N "(cached) $ECHO_C" >&6
17591 eval cf_result='$ac_cv_func_'$cf_func
17592 if test ".$cf_result" != ".no"; then
17593 cat >conftest.$ac_ext <<_ACEOF
17594 #line 17594 "configure"
17595 #include "confdefs.h"
17597 #ifdef HAVE_XCURSES
17598 #include <xcurses.h>
17599 char * XCursesProgramName = "test";
17601 #include <${cf_cv_ncurses_header:-curses.h}>
17602 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
17603 #include <ncursesw/term.h>
17604 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
17605 #include <ncurses/term.h>
17606 #elif defined(HAVE_TERM_H)
17616 long foo = (long)(&${cf_func});
17617 fprintf(stderr, "testing linkage of $cf_func:%p\n", (void *)foo);
17618 if (foo + 1234L > 5678L)
17619 ${cf_cv_main_return:-return}(foo != 0);
17626 rm -f conftest.$ac_objext conftest$ac_exeext
17627 if { (eval echo "$as_me:17627: \"$ac_link\"") >&5
17628 (eval $ac_link) 2>&5
17630 echo "$as_me:17630: \$? = $ac_status" >&5
17631 (exit $ac_status); } &&
17632 { ac_try='test -s conftest$ac_exeext'
17633 { (eval echo "$as_me:17633: \"$ac_try\"") >&5
17634 (eval $ac_try) 2>&5
17636 echo "$as_me:17636: \$? = $ac_status" >&5
17637 (exit $ac_status); }; }; then
17640 echo "$as_me: failed program was:" >&5
17641 cat conftest.$ac_ext >&5
17644 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17646 eval 'cf_cv_func_'$cf_func'=$cf_result'
17650 # use the computed/retrieved cache-value:
17651 eval 'cf_result=$cf_cv_func_'$cf_func
17652 echo "$as_me:17652: result: $cf_result" >&5
17653 echo "${ECHO_T}$cf_result" >&6
17654 if test $cf_result != no; then
17655 cat >>confdefs.h <<EOF
17656 #define HAVE_${cf_tr_func} 1
17662 if test x$cf_cv_func_tputs = xyes
17665 for cf_arg in int char
17667 for cf_ret in int void
17669 if test $cf_ret = void
17671 cf_return="/* nothing */"
17673 cf_return="return value"
17675 cat >conftest.$ac_ext <<_ACEOF
17676 #line 17676 "configure"
17677 #include "confdefs.h"
17679 #include <${cf_cv_ncurses_header:-curses.h}>
17680 #include <$cf_cv_term_header>
17682 static $cf_ret outc($cf_arg value) { $cf_return; }
17688 tputs("hello", 0, outc);
17689 ${cf_cv_main_return:-return}(0);
17695 rm -f conftest.$ac_objext
17696 if { (eval echo "$as_me:17696: \"$ac_compile\"") >&5
17697 (eval $ac_compile) 2>&5
17699 echo "$as_me:17699: \$? = $ac_status" >&5
17700 (exit $ac_status); } &&
17701 { ac_try='test -s conftest.$ac_objext'
17702 { (eval echo "$as_me:17702: \"$ac_try\"") >&5
17703 (eval $ac_try) 2>&5
17705 echo "$as_me:17705: \$? = $ac_status" >&5
17706 (exit $ac_status); }; }; then
17708 test -n "$verbose" && echo " prototype $cf_ret func($cf_arg value)" 1>&6
17710 echo "${as_me:-configure}:17710: testing prototype $cf_ret func($cf_arg value) ..." 1>&5
17712 cat >>confdefs.h <<EOF
17713 #define TPUTS_ARG $cf_arg
17714 #define TPUTS_PROTO(func,value) $cf_ret func(TPUTS_ARG value)
17715 #define TPUTS_RETURN(value) $cf_return
17721 echo "$as_me: failed program was:" >&5
17722 cat conftest.$ac_ext >&5
17724 rm -f conftest.$ac_objext conftest.$ac_ext
17726 test $cf_done = yes && break
17730 echo "$as_me:17730: checking for ncurses extended functions" >&5
17731 echo $ECHO_N "checking for ncurses extended functions... $ECHO_C" >&6
17732 if test "${cf_cv_ncurses_ext_funcs+set}" = set; then
17733 echo $ECHO_N "(cached) $ECHO_C" >&6
17736 cat >conftest.$ac_ext <<_ACEOF
17737 #line 17737 "configure"
17738 #include "confdefs.h"
17740 #include <${cf_cv_ncurses_header:-curses.h}>
17745 int x = NCURSES_EXT_FUNCS
17751 rm -f conftest.$ac_objext
17752 if { (eval echo "$as_me:17752: \"$ac_compile\"") >&5
17753 (eval $ac_compile) 2>&5
17755 echo "$as_me:17755: \$? = $ac_status" >&5
17756 (exit $ac_status); } &&
17757 { ac_try='test -s conftest.$ac_objext'
17758 { (eval echo "$as_me:17758: \"$ac_try\"") >&5
17759 (eval $ac_try) 2>&5
17761 echo "$as_me:17761: \$? = $ac_status" >&5
17762 (exit $ac_status); }; }; then
17763 cf_cv_ncurses_ext_funcs=defined
17765 echo "$as_me: failed program was:" >&5
17766 cat conftest.$ac_ext >&5
17768 cat >conftest.$ac_ext <<_ACEOF
17769 #line 17769 "configure"
17770 #include "confdefs.h"
17772 #include <${cf_cv_ncurses_header:-curses.h}>
17777 (void) assume_default_colors (0, 0);
17778 (void) curses_version ();
17779 (void) define_key (0, 0);
17780 (void) is_term_resized (0, 0);
17781 (void) key_defined (0);
17782 (void) keybound (0, 0);
17783 (void) keyok (0, 0);
17784 (void) resize_term (0, 0);
17785 (void) resizeterm (0, 0);
17786 (void) use_default_colors ();
17787 (void) use_extended_names (0);
17788 (void) wresize (0, 0, 0);
17793 rm -f conftest.$ac_objext conftest$ac_exeext
17794 if { (eval echo "$as_me:17794: \"$ac_link\"") >&5
17795 (eval $ac_link) 2>&5
17797 echo "$as_me:17797: \$? = $ac_status" >&5
17798 (exit $ac_status); } &&
17799 { ac_try='test -s conftest$ac_exeext'
17800 { (eval echo "$as_me:17800: \"$ac_try\"") >&5
17801 (eval $ac_try) 2>&5
17803 echo "$as_me:17803: \$? = $ac_status" >&5
17804 (exit $ac_status); }; }; then
17805 cf_cv_ncurses_ext_funcs=yes
17807 echo "$as_me: failed program was:" >&5
17808 cat conftest.$ac_ext >&5
17809 cf_cv_ncurses_ext_funcs=no
17811 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17814 rm -f conftest.$ac_objext conftest.$ac_ext
17817 echo "$as_me:17817: result: $cf_cv_ncurses_ext_funcs" >&5
17818 echo "${ECHO_T}$cf_cv_ncurses_ext_funcs" >&6
17819 test "$cf_cv_ncurses_ext_funcs" = yes &&
17820 cat >>confdefs.h <<\EOF
17821 #define NCURSES_EXT_FUNCS 1
17824 if test "$cf_enable_widec" = yes
17826 # workaround for systems with ncurses before 20111029, due to change of
17827 # feature test macro from _XPG5 to _XOPEN_SOURCE
17828 if test -n "$cf_cv_ncurses_version" && test "x$cf_cv_ncurses_version" != xno
17831 echo "$as_me:17831: checking if _XPG5 should be defined to enable wide-characters" >&5
17832 echo $ECHO_N "checking if _XPG5 should be defined to enable wide-characters... $ECHO_C" >&6
17834 cat >conftest.$ac_ext <<_ACEOF
17835 #line 17835 "configure"
17836 #include "confdefs.h"
17838 #include <${cf_cv_ncurses_header:-curses.h}>
17847 rm -f conftest.$ac_objext
17848 if { (eval echo "$as_me:17848: \"$ac_compile\"") >&5
17849 (eval $ac_compile) 2>&5
17851 echo "$as_me:17851: \$? = $ac_status" >&5
17852 (exit $ac_status); } &&
17853 { ac_try='test -s conftest.$ac_objext'
17854 { (eval echo "$as_me:17854: \"$ac_try\"") >&5
17855 (eval $ac_try) 2>&5
17857 echo "$as_me:17857: \$? = $ac_status" >&5
17858 (exit $ac_status); }; }; then
17861 echo "$as_me: failed program was:" >&5
17862 cat conftest.$ac_ext >&5
17863 cf_save_cppflags="$CPPFLAGS"
17864 CPPFLAGS="$CPPFLAGS -D_XPG5"
17865 cat >conftest.$ac_ext <<_ACEOF
17866 #line 17866 "configure"
17867 #include "confdefs.h"
17869 #include <${cf_cv_ncurses_header:-curses.h}>
17878 rm -f conftest.$ac_objext
17879 if { (eval echo "$as_me:17879: \"$ac_compile\"") >&5
17880 (eval $ac_compile) 2>&5
17882 echo "$as_me:17882: \$? = $ac_status" >&5
17883 (exit $ac_status); } &&
17884 { ac_try='test -s conftest.$ac_objext'
17885 { (eval echo "$as_me:17885: \"$ac_try\"") >&5
17886 (eval $ac_try) 2>&5
17888 echo "$as_me:17888: \$? = $ac_status" >&5
17889 (exit $ac_status); }; }; then
17892 echo "$as_me: failed program was:" >&5
17893 cat conftest.$ac_ext >&5
17895 rm -f conftest.$ac_objext conftest.$ac_ext
17896 CPPFLAGS="$cf_save_cppflags"
17898 rm -f conftest.$ac_objext conftest.$ac_ext
17899 echo "$as_me:17899: result: $cf_define_xpg5" >&5
17900 echo "${ECHO_T}$cf_define_xpg5" >&6
17902 if test "$cf_define_xpg5" = yes
17904 CPPFLAGS="$CPPFLAGS -D_XPG5"
17908 echo "$as_me:17908: checking for wide-character functions" >&5
17909 echo $ECHO_N "checking for wide-character functions... $ECHO_C" >&6
17910 if test "${cf_cv_widechar_funcs+set}" = set; then
17911 echo $ECHO_N "(cached) $ECHO_C" >&6
17914 cat >conftest.$ac_ext <<_ACEOF
17915 #line 17915 "configure"
17916 #include "confdefs.h"
17918 #include <${cf_cv_ncurses_header:-curses.h}>
17923 static wchar_t src_wchar[2];
17924 static cchar_t dst_cchar;
17925 setcchar(&dst_cchar, src_wchar, A_NORMAL, 0, (void *) 0);
17931 rm -f conftest.$ac_objext conftest$ac_exeext
17932 if { (eval echo "$as_me:17932: \"$ac_link\"") >&5
17933 (eval $ac_link) 2>&5
17935 echo "$as_me:17935: \$? = $ac_status" >&5
17936 (exit $ac_status); } &&
17937 { ac_try='test -s conftest$ac_exeext'
17938 { (eval echo "$as_me:17938: \"$ac_try\"") >&5
17939 (eval $ac_try) 2>&5
17941 echo "$as_me:17941: \$? = $ac_status" >&5
17942 (exit $ac_status); }; }; then
17943 cf_cv_widechar_funcs=yes
17945 echo "$as_me: failed program was:" >&5
17946 cat conftest.$ac_ext >&5
17947 cf_cv_widechar_funcs=no
17949 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17952 echo "$as_me:17952: result: $cf_cv_widechar_funcs" >&5
17953 echo "${ECHO_T}$cf_cv_widechar_funcs" >&6
17954 if test "$cf_cv_widechar_funcs" != no ; then
17956 cat >>confdefs.h <<\EOF
17957 #define USE_WIDEC_SUPPORT 1
17961 cat >>confdefs.h <<\EOF
17962 #define USE_WIDEC_SUPPORT 0
17967 cat >>confdefs.h <<\EOF
17968 #define USE_WIDEC_SUPPORT 0
17973 echo "$as_me:17973: checking if $cf_cv_screen library uses pthreads" >&5
17974 echo $ECHO_N "checking if $cf_cv_screen library uses pthreads... $ECHO_C" >&6
17975 if test "${cf_cv_use_pthreads+set}" = set; then
17976 echo $ECHO_N "(cached) $ECHO_C" >&6
17979 cat >conftest.$ac_ext <<_ACEOF
17980 #line 17980 "configure"
17981 #include "confdefs.h"
17983 #include <${cf_cv_ncurses_header:-curses.h}>
17984 extern void _nc_init_pthreads(void);
17991 _nc_init_pthreads();
17997 rm -f conftest.$ac_objext conftest$ac_exeext
17998 if { (eval echo "$as_me:17998: \"$ac_link\"") >&5
17999 (eval $ac_link) 2>&5
18001 echo "$as_me:18001: \$? = $ac_status" >&5
18002 (exit $ac_status); } &&
18003 { ac_try='test -s conftest$ac_exeext'
18004 { (eval echo "$as_me:18004: \"$ac_try\"") >&5
18005 (eval $ac_try) 2>&5
18007 echo "$as_me:18007: \$? = $ac_status" >&5
18008 (exit $ac_status); }; }; then
18009 cf_cv_use_pthreads=yes
18011 echo "$as_me: failed program was:" >&5
18012 cat conftest.$ac_ext >&5
18013 cf_cv_use_pthreads=no
18015 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18018 echo "$as_me:18018: result: $cf_cv_use_pthreads" >&5
18019 echo "${ECHO_T}$cf_cv_use_pthreads" >&6
18020 test $cf_cv_use_pthreads = yes && cat >>confdefs.h <<\EOF
18021 #define USE_PTHREADS 1
18024 echo "$as_me:18024: checking if sys/time.h works with sys/select.h" >&5
18025 echo $ECHO_N "checking if sys/time.h works with sys/select.h... $ECHO_C" >&6
18026 if test "${cf_cv_sys_time_select+set}" = set; then
18027 echo $ECHO_N "(cached) $ECHO_C" >&6
18030 cat >conftest.$ac_ext <<_ACEOF
18031 #line 18031 "configure"
18032 #include "confdefs.h"
18034 #include <sys/types.h>
18035 #ifdef HAVE_SYS_TIME_H
18036 #include <sys/time.h>
18038 #ifdef HAVE_SYS_SELECT_H
18039 #include <sys/select.h>
18050 rm -f conftest.$ac_objext
18051 if { (eval echo "$as_me:18051: \"$ac_compile\"") >&5
18052 (eval $ac_compile) 2>&5
18054 echo "$as_me:18054: \$? = $ac_status" >&5
18055 (exit $ac_status); } &&
18056 { ac_try='test -s conftest.$ac_objext'
18057 { (eval echo "$as_me:18057: \"$ac_try\"") >&5
18058 (eval $ac_try) 2>&5
18060 echo "$as_me:18060: \$? = $ac_status" >&5
18061 (exit $ac_status); }; }; then
18062 cf_cv_sys_time_select=yes
18064 echo "$as_me: failed program was:" >&5
18065 cat conftest.$ac_ext >&5
18066 cf_cv_sys_time_select=no
18068 rm -f conftest.$ac_objext conftest.$ac_ext
18072 echo "$as_me:18072: result: $cf_cv_sys_time_select" >&5
18073 echo "${ECHO_T}$cf_cv_sys_time_select" >&6
18074 test "$cf_cv_sys_time_select" = yes &&
18075 cat >>confdefs.h <<\EOF
18076 #define HAVE_SYS_TIME_SELECT 1
18079 # special check for test/ditto.c
18081 echo "$as_me:18081: checking for openpty in -lutil" >&5
18082 echo $ECHO_N "checking for openpty in -lutil... $ECHO_C" >&6
18083 if test "${ac_cv_lib_util_openpty+set}" = set; then
18084 echo $ECHO_N "(cached) $ECHO_C" >&6
18086 ac_check_lib_save_LIBS=$LIBS
18087 LIBS="-lutil $LIBS"
18088 cat >conftest.$ac_ext <<_ACEOF
18089 #line 18089 "configure"
18090 #include "confdefs.h"
18092 /* Override any gcc2 internal prototype to avoid an error. */
18096 /* We use char because int might match the return type of a gcc2
18097 builtin and then its argument prototype would still apply. */
18107 rm -f conftest.$ac_objext conftest$ac_exeext
18108 if { (eval echo "$as_me:18108: \"$ac_link\"") >&5
18109 (eval $ac_link) 2>&5
18111 echo "$as_me:18111: \$? = $ac_status" >&5
18112 (exit $ac_status); } &&
18113 { ac_try='test -s conftest$ac_exeext'
18114 { (eval echo "$as_me:18114: \"$ac_try\"") >&5
18115 (eval $ac_try) 2>&5
18117 echo "$as_me:18117: \$? = $ac_status" >&5
18118 (exit $ac_status); }; }; then
18119 ac_cv_lib_util_openpty=yes
18121 echo "$as_me: failed program was:" >&5
18122 cat conftest.$ac_ext >&5
18123 ac_cv_lib_util_openpty=no
18125 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18126 LIBS=$ac_check_lib_save_LIBS
18128 echo "$as_me:18128: result: $ac_cv_lib_util_openpty" >&5
18129 echo "${ECHO_T}$ac_cv_lib_util_openpty" >&6
18130 if test $ac_cv_lib_util_openpty = yes; then
18136 echo "$as_me:18136: checking for openpty header" >&5
18137 echo $ECHO_N "checking for openpty header... $ECHO_C" >&6
18138 if test "${cf_cv_func_openpty+set}" = set; then
18139 echo $ECHO_N "(cached) $ECHO_C" >&6
18142 cf_save_LIBS="$LIBS"
18143 test $cf_cv_lib_util = yes && {
18144 cf_add_libs="-lutil"
18145 # Filter out duplicates - this happens with badly-designed ".pc" files...
18146 for cf_add_1lib in $LIBS
18148 for cf_add_2lib in $cf_add_libs
18150 if test "x$cf_add_1lib" = "x$cf_add_2lib"
18156 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
18158 LIBS="$cf_add_libs"
18160 for cf_header in pty.h libutil.h util.h
18162 cat >conftest.$ac_ext <<_ACEOF
18163 #line 18163 "configure"
18164 #include "confdefs.h"
18166 #include <$cf_header>
18172 int x = openpty((int *)0, (int *)0, (char *)0,
18173 (struct termios *)0, (struct winsize *)0);
18179 rm -f conftest.$ac_objext conftest$ac_exeext
18180 if { (eval echo "$as_me:18180: \"$ac_link\"") >&5
18181 (eval $ac_link) 2>&5
18183 echo "$as_me:18183: \$? = $ac_status" >&5
18184 (exit $ac_status); } &&
18185 { ac_try='test -s conftest$ac_exeext'
18186 { (eval echo "$as_me:18186: \"$ac_try\"") >&5
18187 (eval $ac_try) 2>&5
18189 echo "$as_me:18189: \$? = $ac_status" >&5
18190 (exit $ac_status); }; }; then
18192 cf_cv_func_openpty=$cf_header
18196 echo "$as_me: failed program was:" >&5
18197 cat conftest.$ac_ext >&5
18199 cf_cv_func_openpty=no
18202 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18204 LIBS="$cf_save_LIBS"
18207 echo "$as_me:18207: result: $cf_cv_func_openpty" >&5
18208 echo "${ECHO_T}$cf_cv_func_openpty" >&6
18210 if test "$cf_cv_func_openpty" != no ; then
18212 cat >>confdefs.h <<EOF
18213 #define USE_OPENPTY_HEADER <$cf_cv_func_openpty>
18216 cat >>confdefs.h <<\EOF
18217 #define USE_XTERM_PTY 1
18220 if test "x$cf_cv_lib_util" = xyes ; then
18222 cf_add_libs="-lutil"
18223 # Filter out duplicates - this happens with badly-designed ".pc" files...
18224 for cf_add_1lib in $TEST_LIBS
18226 for cf_add_2lib in $cf_add_libs
18228 if test "x$cf_add_1lib" = "x$cf_add_2lib"
18234 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
18236 TEST_LIBS="$cf_add_libs"
18241 echo "$as_me:18241: checking for function curses_version" >&5
18242 echo $ECHO_N "checking for function curses_version... $ECHO_C" >&6
18243 if test "${cf_cv_func_curses_version+set}" = set; then
18244 echo $ECHO_N "(cached) $ECHO_C" >&6
18247 if test "$cross_compiling" = yes; then
18248 cf_cv_func_curses_version=unknown
18250 cat >conftest.$ac_ext <<_ACEOF
18251 #line 18251 "configure"
18252 #include "confdefs.h"
18254 #include <${cf_cv_ncurses_header:-curses.h}>
18258 sprintf(temp, "%s\n", curses_version());
18259 ${cf_cv_main_return:-return}(0);
18263 rm -f conftest$ac_exeext
18264 if { (eval echo "$as_me:18264: \"$ac_link\"") >&5
18265 (eval $ac_link) 2>&5
18267 echo "$as_me:18267: \$? = $ac_status" >&5
18268 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18269 { (eval echo "$as_me:18269: \"$ac_try\"") >&5
18270 (eval $ac_try) 2>&5
18272 echo "$as_me:18272: \$? = $ac_status" >&5
18273 (exit $ac_status); }; }; then
18274 cf_cv_func_curses_version=yes
18277 echo "$as_me: program exited with status $ac_status" >&5
18278 echo "$as_me: failed program was:" >&5
18279 cat conftest.$ac_ext >&5
18280 cf_cv_func_curses_version=no
18283 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18287 echo "$as_me:18287: result: $cf_cv_func_curses_version" >&5
18288 echo "${ECHO_T}$cf_cv_func_curses_version" >&6
18289 test "$cf_cv_func_curses_version" = yes &&
18290 cat >>confdefs.h <<\EOF
18291 #define HAVE_CURSES_VERSION 1
18294 echo "$as_me:18294: checking for alternate character set array" >&5
18295 echo $ECHO_N "checking for alternate character set array... $ECHO_C" >&6
18296 if test "${cf_cv_curses_acs_map+set}" = set; then
18297 echo $ECHO_N "(cached) $ECHO_C" >&6
18300 cf_cv_curses_acs_map=unknown
18301 for name in acs_map _acs_map __acs_map ${NCURSES_WRAP_PREFIX}acs_map
18303 cat >conftest.$ac_ext <<_ACEOF
18304 #line 18304 "configure"
18305 #include "confdefs.h"
18307 #include <${cf_cv_ncurses_header:-curses.h}>
18313 $name['k'] = ACS_PLUS
18319 rm -f conftest.$ac_objext conftest$ac_exeext
18320 if { (eval echo "$as_me:18320: \"$ac_link\"") >&5
18321 (eval $ac_link) 2>&5
18323 echo "$as_me:18323: \$? = $ac_status" >&5
18324 (exit $ac_status); } &&
18325 { ac_try='test -s conftest$ac_exeext'
18326 { (eval echo "$as_me:18326: \"$ac_try\"") >&5
18327 (eval $ac_try) 2>&5
18329 echo "$as_me:18329: \$? = $ac_status" >&5
18330 (exit $ac_status); }; }; then
18331 cf_cv_curses_acs_map=$name; break
18333 echo "$as_me: failed program was:" >&5
18334 cat conftest.$ac_ext >&5
18336 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18340 echo "$as_me:18340: result: $cf_cv_curses_acs_map" >&5
18341 echo "${ECHO_T}$cf_cv_curses_acs_map" >&6
18343 test "$cf_cv_curses_acs_map" != unknown &&
18344 cat >>confdefs.h <<EOF
18345 #define CURSES_ACS_ARRAY $cf_cv_curses_acs_map
18348 if test "$cf_enable_widec" = yes; then
18350 echo "$as_me:18350: checking for wide alternate character set array" >&5
18351 echo $ECHO_N "checking for wide alternate character set array... $ECHO_C" >&6
18352 if test "${cf_cv_curses_wacs_map+set}" = set; then
18353 echo $ECHO_N "(cached) $ECHO_C" >&6
18356 cf_cv_curses_wacs_map=unknown
18357 for name in wacs_map _wacs_map __wacs_map _nc_wacs _wacs_char
18359 cat >conftest.$ac_ext <<_ACEOF
18360 #line 18360 "configure"
18361 #include "confdefs.h"
18363 #ifndef _XOPEN_SOURCE_EXTENDED
18364 #define _XOPEN_SOURCE_EXTENDED
18366 #include <${cf_cv_ncurses_header:-curses.h}>
18370 void *foo = &($name['k'])
18375 rm -f conftest.$ac_objext conftest$ac_exeext
18376 if { (eval echo "$as_me:18376: \"$ac_link\"") >&5
18377 (eval $ac_link) 2>&5
18379 echo "$as_me:18379: \$? = $ac_status" >&5
18380 (exit $ac_status); } &&
18381 { ac_try='test -s conftest$ac_exeext'
18382 { (eval echo "$as_me:18382: \"$ac_try\"") >&5
18383 (eval $ac_try) 2>&5
18385 echo "$as_me:18385: \$? = $ac_status" >&5
18386 (exit $ac_status); }; }; then
18387 cf_cv_curses_wacs_map=$name
18390 echo "$as_me: failed program was:" >&5
18391 cat conftest.$ac_ext >&5
18393 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18396 echo "$as_me:18396: result: $cf_cv_curses_wacs_map" >&5
18397 echo "${ECHO_T}$cf_cv_curses_wacs_map" >&6
18399 test "$cf_cv_curses_wacs_map" != unknown &&
18400 cat >>confdefs.h <<EOF
18401 #define CURSES_WACS_ARRAY $cf_cv_curses_wacs_map
18404 echo "$as_me:18404: checking for wide alternate character constants" >&5
18405 echo $ECHO_N "checking for wide alternate character constants... $ECHO_C" >&6
18406 if test "${cf_cv_curses_wacs_symbols+set}" = set; then
18407 echo $ECHO_N "(cached) $ECHO_C" >&6
18410 cf_cv_curses_wacs_symbols=no
18411 if test "$cf_cv_curses_wacs_map" != unknown
18413 cat >conftest.$ac_ext <<_ACEOF
18414 #line 18414 "configure"
18415 #include "confdefs.h"
18417 #ifndef _XOPEN_SOURCE_EXTENDED
18418 #define _XOPEN_SOURCE_EXTENDED
18420 #include <${cf_cv_ncurses_header:-curses.h}>
18424 cchar_t *foo = WACS_PLUS;
18425 $cf_cv_curses_wacs_map['k'] = *WACS_PLUS
18430 rm -f conftest.$ac_objext conftest$ac_exeext
18431 if { (eval echo "$as_me:18431: \"$ac_link\"") >&5
18432 (eval $ac_link) 2>&5
18434 echo "$as_me:18434: \$? = $ac_status" >&5
18435 (exit $ac_status); } &&
18436 { ac_try='test -s conftest$ac_exeext'
18437 { (eval echo "$as_me:18437: \"$ac_try\"") >&5
18438 (eval $ac_try) 2>&5
18440 echo "$as_me:18440: \$? = $ac_status" >&5
18441 (exit $ac_status); }; }; then
18442 cf_cv_curses_wacs_symbols=yes
18444 echo "$as_me: failed program was:" >&5
18445 cat conftest.$ac_ext >&5
18447 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18449 cat >conftest.$ac_ext <<_ACEOF
18450 #line 18450 "configure"
18451 #include "confdefs.h"
18453 #ifndef _XOPEN_SOURCE_EXTENDED
18454 #define _XOPEN_SOURCE_EXTENDED
18456 #include <${cf_cv_ncurses_header:-curses.h}>
18460 cchar_t *foo = WACS_PLUS
18465 rm -f conftest.$ac_objext conftest$ac_exeext
18466 if { (eval echo "$as_me:18466: \"$ac_link\"") >&5
18467 (eval $ac_link) 2>&5
18469 echo "$as_me:18469: \$? = $ac_status" >&5
18470 (exit $ac_status); } &&
18471 { ac_try='test -s conftest$ac_exeext'
18472 { (eval echo "$as_me:18472: \"$ac_try\"") >&5
18473 (eval $ac_try) 2>&5
18475 echo "$as_me:18475: \$? = $ac_status" >&5
18476 (exit $ac_status); }; }; then
18477 cf_cv_curses_wacs_symbols=yes
18479 echo "$as_me: failed program was:" >&5
18480 cat conftest.$ac_ext >&5
18482 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18486 echo "$as_me:18486: result: $cf_cv_curses_wacs_symbols" >&5
18487 echo "${ECHO_T}$cf_cv_curses_wacs_symbols" >&6
18489 test "$cf_cv_curses_wacs_symbols" != no &&
18490 cat >>confdefs.h <<\EOF
18491 #define CURSES_WACS_SYMBOLS 1
18496 echo "$as_me:18496: checking for type attr_t in ${cf_cv_ncurses_header:-curses.h}" >&5
18497 echo $ECHO_N "checking for type attr_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
18498 cat >conftest.$ac_ext <<_ACEOF
18499 #line 18499 "configure"
18500 #include "confdefs.h"
18502 #ifndef _XOPEN_SOURCE_EXTENDED
18503 #define _XOPEN_SOURCE_EXTENDED
18505 #include <${cf_cv_ncurses_header:-curses.h}>
18516 rm -f conftest.$ac_objext
18517 if { (eval echo "$as_me:18517: \"$ac_compile\"") >&5
18518 (eval $ac_compile) 2>&5
18520 echo "$as_me:18520: \$? = $ac_status" >&5
18521 (exit $ac_status); } &&
18522 { ac_try='test -s conftest.$ac_objext'
18523 { (eval echo "$as_me:18523: \"$ac_try\"") >&5
18524 (eval $ac_try) 2>&5
18526 echo "$as_me:18526: \$? = $ac_status" >&5
18527 (exit $ac_status); }; }; then
18530 echo "$as_me: failed program was:" >&5
18531 cat conftest.$ac_ext >&5
18534 rm -f conftest.$ac_objext conftest.$ac_ext
18535 echo "$as_me:18535: result: $cf_result" >&5
18536 echo "${ECHO_T}$cf_result" >&6
18537 if test $cf_result = yes ; then
18539 cf_result=`echo "have_type_attr_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
18541 cat >>confdefs.h <<EOF
18542 #define $cf_result 1
18547 cat >>confdefs.h <<EOF
18548 #define attr_t long
18553 if test "$cf_enable_widec" = yes; then
18555 # This is needed on Tru64 5.0 to declare mbstate_t
18556 echo "$as_me:18556: checking if we must include wchar.h to declare mbstate_t" >&5
18557 echo $ECHO_N "checking if we must include wchar.h to declare mbstate_t... $ECHO_C" >&6
18558 if test "${cf_cv_mbstate_t+set}" = set; then
18559 echo $ECHO_N "(cached) $ECHO_C" >&6
18562 cat >conftest.$ac_ext <<_ACEOF
18563 #line 18563 "configure"
18564 #include "confdefs.h"
18566 #include <stdlib.h>
18567 #include <stdarg.h>
18569 #ifdef HAVE_LIBUTF8_H
18570 #include <libutf8.h>
18580 rm -f conftest.$ac_objext
18581 if { (eval echo "$as_me:18581: \"$ac_compile\"") >&5
18582 (eval $ac_compile) 2>&5
18584 echo "$as_me:18584: \$? = $ac_status" >&5
18585 (exit $ac_status); } &&
18586 { ac_try='test -s conftest.$ac_objext'
18587 { (eval echo "$as_me:18587: \"$ac_try\"") >&5
18588 (eval $ac_try) 2>&5
18590 echo "$as_me:18590: \$? = $ac_status" >&5
18591 (exit $ac_status); }; }; then
18594 echo "$as_me: failed program was:" >&5
18595 cat conftest.$ac_ext >&5
18596 cat >conftest.$ac_ext <<_ACEOF
18597 #line 18597 "configure"
18598 #include "confdefs.h"
18600 #include <stdlib.h>
18601 #include <stdarg.h>
18604 #ifdef HAVE_LIBUTF8_H
18605 #include <libutf8.h>
18615 rm -f conftest.$ac_objext
18616 if { (eval echo "$as_me:18616: \"$ac_compile\"") >&5
18617 (eval $ac_compile) 2>&5
18619 echo "$as_me:18619: \$? = $ac_status" >&5
18620 (exit $ac_status); } &&
18621 { ac_try='test -s conftest.$ac_objext'
18622 { (eval echo "$as_me:18622: \"$ac_try\"") >&5
18623 (eval $ac_try) 2>&5
18625 echo "$as_me:18625: \$? = $ac_status" >&5
18626 (exit $ac_status); }; }; then
18627 cf_cv_mbstate_t=yes
18629 echo "$as_me: failed program was:" >&5
18630 cat conftest.$ac_ext >&5
18631 cf_cv_mbstate_t=unknown
18633 rm -f conftest.$ac_objext conftest.$ac_ext
18635 rm -f conftest.$ac_objext conftest.$ac_ext
18637 echo "$as_me:18637: result: $cf_cv_mbstate_t" >&5
18638 echo "${ECHO_T}$cf_cv_mbstate_t" >&6
18640 if test "$cf_cv_mbstate_t" = yes ; then
18642 cat >>confdefs.h <<\EOF
18643 #define NEED_WCHAR_H 1
18649 # if we do not find mbstate_t in either place, use substitution to provide a fallback.
18650 if test "$cf_cv_mbstate_t" = unknown ; then
18651 NCURSES_MBSTATE_T=1
18654 # if we find mbstate_t in either place, use substitution to provide a fallback.
18655 if test "$cf_cv_mbstate_t" != unknown ; then
18656 NCURSES_OK_MBSTATE_T=1
18659 # This is needed on Tru64 5.0 to declare wchar_t
18660 echo "$as_me:18660: checking if we must include wchar.h to declare wchar_t" >&5
18661 echo $ECHO_N "checking if we must include wchar.h to declare wchar_t... $ECHO_C" >&6
18662 if test "${cf_cv_wchar_t+set}" = set; then
18663 echo $ECHO_N "(cached) $ECHO_C" >&6
18666 cat >conftest.$ac_ext <<_ACEOF
18667 #line 18667 "configure"
18668 #include "confdefs.h"
18670 #include <stdlib.h>
18671 #include <stdarg.h>
18673 #ifdef HAVE_LIBUTF8_H
18674 #include <libutf8.h>
18684 rm -f conftest.$ac_objext
18685 if { (eval echo "$as_me:18685: \"$ac_compile\"") >&5
18686 (eval $ac_compile) 2>&5
18688 echo "$as_me:18688: \$? = $ac_status" >&5
18689 (exit $ac_status); } &&
18690 { ac_try='test -s conftest.$ac_objext'
18691 { (eval echo "$as_me:18691: \"$ac_try\"") >&5
18692 (eval $ac_try) 2>&5
18694 echo "$as_me:18694: \$? = $ac_status" >&5
18695 (exit $ac_status); }; }; then
18698 echo "$as_me: failed program was:" >&5
18699 cat conftest.$ac_ext >&5
18700 cat >conftest.$ac_ext <<_ACEOF
18701 #line 18701 "configure"
18702 #include "confdefs.h"
18704 #include <stdlib.h>
18705 #include <stdarg.h>
18708 #ifdef HAVE_LIBUTF8_H
18709 #include <libutf8.h>
18719 rm -f conftest.$ac_objext
18720 if { (eval echo "$as_me:18720: \"$ac_compile\"") >&5
18721 (eval $ac_compile) 2>&5
18723 echo "$as_me:18723: \$? = $ac_status" >&5
18724 (exit $ac_status); } &&
18725 { ac_try='test -s conftest.$ac_objext'
18726 { (eval echo "$as_me:18726: \"$ac_try\"") >&5
18727 (eval $ac_try) 2>&5
18729 echo "$as_me:18729: \$? = $ac_status" >&5
18730 (exit $ac_status); }; }; then
18733 echo "$as_me: failed program was:" >&5
18734 cat conftest.$ac_ext >&5
18735 cf_cv_wchar_t=unknown
18737 rm -f conftest.$ac_objext conftest.$ac_ext
18739 rm -f conftest.$ac_objext conftest.$ac_ext
18741 echo "$as_me:18741: result: $cf_cv_wchar_t" >&5
18742 echo "${ECHO_T}$cf_cv_wchar_t" >&6
18744 if test "$cf_cv_wchar_t" = yes ; then
18746 cat >>confdefs.h <<\EOF
18747 #define NEED_WCHAR_H 1
18753 # if we do not find wchar_t in either place, use substitution to provide a fallback.
18754 if test "$cf_cv_wchar_t" = unknown ; then
18758 # if we find wchar_t in either place, use substitution to provide a fallback.
18759 if test "$cf_cv_wchar_t" != unknown ; then
18760 NCURSES_OK_WCHAR_T=1
18763 # This is needed on Tru64 5.0 to declare wint_t
18764 echo "$as_me:18764: checking if we must include wchar.h to declare wint_t" >&5
18765 echo $ECHO_N "checking if we must include wchar.h to declare wint_t... $ECHO_C" >&6
18766 if test "${cf_cv_wint_t+set}" = set; then
18767 echo $ECHO_N "(cached) $ECHO_C" >&6
18770 cat >conftest.$ac_ext <<_ACEOF
18771 #line 18771 "configure"
18772 #include "confdefs.h"
18774 #include <stdlib.h>
18775 #include <stdarg.h>
18777 #ifdef HAVE_LIBUTF8_H
18778 #include <libutf8.h>
18788 rm -f conftest.$ac_objext
18789 if { (eval echo "$as_me:18789: \"$ac_compile\"") >&5
18790 (eval $ac_compile) 2>&5
18792 echo "$as_me:18792: \$? = $ac_status" >&5
18793 (exit $ac_status); } &&
18794 { ac_try='test -s conftest.$ac_objext'
18795 { (eval echo "$as_me:18795: \"$ac_try\"") >&5
18796 (eval $ac_try) 2>&5
18798 echo "$as_me:18798: \$? = $ac_status" >&5
18799 (exit $ac_status); }; }; then
18802 echo "$as_me: failed program was:" >&5
18803 cat conftest.$ac_ext >&5
18804 cat >conftest.$ac_ext <<_ACEOF
18805 #line 18805 "configure"
18806 #include "confdefs.h"
18808 #include <stdlib.h>
18809 #include <stdarg.h>
18812 #ifdef HAVE_LIBUTF8_H
18813 #include <libutf8.h>
18823 rm -f conftest.$ac_objext
18824 if { (eval echo "$as_me:18824: \"$ac_compile\"") >&5
18825 (eval $ac_compile) 2>&5
18827 echo "$as_me:18827: \$? = $ac_status" >&5
18828 (exit $ac_status); } &&
18829 { ac_try='test -s conftest.$ac_objext'
18830 { (eval echo "$as_me:18830: \"$ac_try\"") >&5
18831 (eval $ac_try) 2>&5
18833 echo "$as_me:18833: \$? = $ac_status" >&5
18834 (exit $ac_status); }; }; then
18837 echo "$as_me: failed program was:" >&5
18838 cat conftest.$ac_ext >&5
18839 cf_cv_wint_t=unknown
18841 rm -f conftest.$ac_objext conftest.$ac_ext
18843 rm -f conftest.$ac_objext conftest.$ac_ext
18845 echo "$as_me:18845: result: $cf_cv_wint_t" >&5
18846 echo "${ECHO_T}$cf_cv_wint_t" >&6
18848 if test "$cf_cv_wint_t" = yes ; then
18850 cat >>confdefs.h <<\EOF
18851 #define NEED_WCHAR_H 1
18857 # if we do not find wint_t in either place, use substitution to provide a fallback.
18858 if test "$cf_cv_wint_t" = unknown ; then
18862 # if we find wint_t in either place, use substitution to provide a fallback.
18863 if test "$cf_cv_wint_t" != unknown ; then
18864 NCURSES_OK_WINT_T=1
18867 if test "$NCURSES_OK_MBSTATE_T" = 0 ; then
18869 echo "$as_me:18869: checking for type mbstate_t in ${cf_cv_ncurses_header:-curses.h}" >&5
18870 echo $ECHO_N "checking for type mbstate_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
18871 cat >conftest.$ac_ext <<_ACEOF
18872 #line 18872 "configure"
18873 #include "confdefs.h"
18875 #ifndef _XOPEN_SOURCE_EXTENDED
18876 #define _XOPEN_SOURCE_EXTENDED
18878 #include <${cf_cv_ncurses_header:-curses.h}>
18889 rm -f conftest.$ac_objext
18890 if { (eval echo "$as_me:18890: \"$ac_compile\"") >&5
18891 (eval $ac_compile) 2>&5
18893 echo "$as_me:18893: \$? = $ac_status" >&5
18894 (exit $ac_status); } &&
18895 { ac_try='test -s conftest.$ac_objext'
18896 { (eval echo "$as_me:18896: \"$ac_try\"") >&5
18897 (eval $ac_try) 2>&5
18899 echo "$as_me:18899: \$? = $ac_status" >&5
18900 (exit $ac_status); }; }; then
18903 echo "$as_me: failed program was:" >&5
18904 cat conftest.$ac_ext >&5
18907 rm -f conftest.$ac_objext conftest.$ac_ext
18908 echo "$as_me:18908: result: $cf_result" >&5
18909 echo "${ECHO_T}$cf_result" >&6
18910 if test $cf_result = yes ; then
18912 cf_result=`echo "have_type_mbstate_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
18914 cat >>confdefs.h <<EOF
18915 #define $cf_result 1
18920 cat >>confdefs.h <<EOF
18921 #define mbstate_t long
18928 if test "$NCURSES_OK_WCHAR_T" = 0 ; then
18930 echo "$as_me:18930: checking for type wchar_t in ${cf_cv_ncurses_header:-curses.h}" >&5
18931 echo $ECHO_N "checking for type wchar_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
18932 cat >conftest.$ac_ext <<_ACEOF
18933 #line 18933 "configure"
18934 #include "confdefs.h"
18936 #ifndef _XOPEN_SOURCE_EXTENDED
18937 #define _XOPEN_SOURCE_EXTENDED
18939 #include <${cf_cv_ncurses_header:-curses.h}>
18950 rm -f conftest.$ac_objext
18951 if { (eval echo "$as_me:18951: \"$ac_compile\"") >&5
18952 (eval $ac_compile) 2>&5
18954 echo "$as_me:18954: \$? = $ac_status" >&5
18955 (exit $ac_status); } &&
18956 { ac_try='test -s conftest.$ac_objext'
18957 { (eval echo "$as_me:18957: \"$ac_try\"") >&5
18958 (eval $ac_try) 2>&5
18960 echo "$as_me:18960: \$? = $ac_status" >&5
18961 (exit $ac_status); }; }; then
18964 echo "$as_me: failed program was:" >&5
18965 cat conftest.$ac_ext >&5
18968 rm -f conftest.$ac_objext conftest.$ac_ext
18969 echo "$as_me:18969: result: $cf_result" >&5
18970 echo "${ECHO_T}$cf_result" >&6
18971 if test $cf_result = yes ; then
18973 cf_result=`echo "have_type_wchar_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
18975 cat >>confdefs.h <<EOF
18976 #define $cf_result 1
18981 cat >>confdefs.h <<EOF
18982 #define wchar_t long
18989 if test "$NCURSES_OK_WINT_T" = 0 ; then
18991 echo "$as_me:18991: checking for type wint_t in ${cf_cv_ncurses_header:-curses.h}" >&5
18992 echo $ECHO_N "checking for type wint_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
18993 cat >conftest.$ac_ext <<_ACEOF
18994 #line 18994 "configure"
18995 #include "confdefs.h"
18997 #ifndef _XOPEN_SOURCE_EXTENDED
18998 #define _XOPEN_SOURCE_EXTENDED
19000 #include <${cf_cv_ncurses_header:-curses.h}>
19011 rm -f conftest.$ac_objext
19012 if { (eval echo "$as_me:19012: \"$ac_compile\"") >&5
19013 (eval $ac_compile) 2>&5
19015 echo "$as_me:19015: \$? = $ac_status" >&5
19016 (exit $ac_status); } &&
19017 { ac_try='test -s conftest.$ac_objext'
19018 { (eval echo "$as_me:19018: \"$ac_try\"") >&5
19019 (eval $ac_try) 2>&5
19021 echo "$as_me:19021: \$? = $ac_status" >&5
19022 (exit $ac_status); }; }; then
19025 echo "$as_me: failed program was:" >&5
19026 cat conftest.$ac_ext >&5
19029 rm -f conftest.$ac_objext conftest.$ac_ext
19030 echo "$as_me:19030: result: $cf_result" >&5
19031 echo "${ECHO_T}$cf_result" >&6
19032 if test $cf_result = yes ; then
19034 cf_result=`echo "have_type_wint_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
19036 cat >>confdefs.h <<EOF
19037 #define $cf_result 1
19042 cat >>confdefs.h <<EOF
19043 #define wint_t long
19058 echo "$as_me:19058: checking for data $cf_data declaration in ${cf_cv_ncurses_header:-curses.h}" >&5
19059 echo $ECHO_N "checking for data $cf_data declaration in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6
19061 cat >conftest.$ac_ext <<_ACEOF
19062 #line 19062 "configure"
19063 #include "confdefs.h"
19065 #ifdef HAVE_XCURSES
19066 #include <xcurses.h>
19067 char * XCursesProgramName = "test";
19069 #include <${cf_cv_ncurses_header:-curses.h}>
19070 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
19071 #include <ncursesw/term.h>
19072 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
19073 #include <ncurses/term.h>
19074 #elif defined(HAVE_TERM_H)
19083 void *foo = &($cf_data)
19089 rm -f conftest.$ac_objext
19090 if { (eval echo "$as_me:19090: \"$ac_compile\"") >&5
19091 (eval $ac_compile) 2>&5
19093 echo "$as_me:19093: \$? = $ac_status" >&5
19094 (exit $ac_status); } &&
19095 { ac_try='test -s conftest.$ac_objext'
19096 { (eval echo "$as_me:19096: \"$ac_try\"") >&5
19097 (eval $ac_try) 2>&5
19099 echo "$as_me:19099: \$? = $ac_status" >&5
19100 (exit $ac_status); }; }; then
19104 echo "$as_me: failed program was:" >&5
19105 cat conftest.$ac_ext >&5
19108 rm -f conftest.$ac_objext conftest.$ac_ext
19109 echo "$as_me:19109: result: $cf_result" >&5
19110 echo "${ECHO_T}$cf_result" >&6
19112 if test $cf_result = yes ; then
19114 cf_result=`echo "have_curses_data_$cf_data" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
19116 cat >>confdefs.h <<EOF
19117 #define $cf_result 1
19121 echo "$as_me:19121: checking for data $cf_data in library" >&5
19122 echo $ECHO_N "checking for data $cf_data in library... $ECHO_C" >&6
19123 # BSD linkers insist on making weak linkage, but resolve at runtime.
19124 if test "$cross_compiling" = yes; then
19127 cat >conftest.$ac_ext <<_ACEOF
19128 #line 19128 "configure"
19129 #include "confdefs.h"
19131 #ifdef HAVE_XCURSES
19132 #include <xcurses.h>
19133 char * XCursesProgramName = "test";
19135 #include <${cf_cv_ncurses_header:-curses.h}>
19136 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
19137 #include <ncursesw/term.h>
19138 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
19139 #include <ncurses/term.h>
19140 #elif defined(HAVE_TERM_H)
19145 extern char $cf_data;
19151 void *foo = &($cf_data);
19152 fprintf(stderr, "testing linkage of $cf_data:%p\n", (void *)foo);
19153 ${cf_cv_main_return:-return}(foo == 0);
19160 rm -f conftest.$ac_objext conftest$ac_exeext
19161 if { (eval echo "$as_me:19161: \"$ac_link\"") >&5
19162 (eval $ac_link) 2>&5
19164 echo "$as_me:19164: \$? = $ac_status" >&5
19165 (exit $ac_status); } &&
19166 { ac_try='test -s conftest$ac_exeext'
19167 { (eval echo "$as_me:19167: \"$ac_try\"") >&5
19168 (eval $ac_try) 2>&5
19170 echo "$as_me:19170: \$? = $ac_status" >&5
19171 (exit $ac_status); }; }; then
19174 echo "$as_me: failed program was:" >&5
19175 cat conftest.$ac_ext >&5
19178 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
19181 cat >conftest.$ac_ext <<_ACEOF
19182 #line 19182 "configure"
19183 #include "confdefs.h"
19185 #ifdef HAVE_XCURSES
19186 #include <xcurses.h>
19187 char * XCursesProgramName = "test";
19189 #include <${cf_cv_ncurses_header:-curses.h}>
19190 #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
19191 #include <ncursesw/term.h>
19192 #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
19193 #include <ncurses/term.h>
19194 #elif defined(HAVE_TERM_H)
19199 extern char $cf_data;
19202 void *foo = &($cf_data);
19203 fprintf(stderr, "testing linkage of $cf_data:%p\n", (void *)foo);
19204 ${cf_cv_main_return:-return}(foo == 0);
19207 rm -f conftest$ac_exeext
19208 if { (eval echo "$as_me:19208: \"$ac_link\"") >&5
19209 (eval $ac_link) 2>&5
19211 echo "$as_me:19211: \$? = $ac_status" >&5
19212 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19213 { (eval echo "$as_me:19213: \"$ac_try\"") >&5
19214 (eval $ac_try) 2>&5
19216 echo "$as_me:19216: \$? = $ac_status" >&5
19217 (exit $ac_status); }; }; then
19221 echo "$as_me: program exited with status $ac_status" >&5
19222 echo "$as_me: failed program was:" >&5
19223 cat conftest.$ac_ext >&5
19226 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19228 echo "$as_me:19228: result: $cf_result" >&5
19229 echo "${ECHO_T}$cf_result" >&6
19230 if test $cf_result = yes ; then
19232 cf_result=`echo "decl_curses_data_$cf_data" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
19234 cat >>confdefs.h <<EOF
19235 #define $cf_result 1
19238 # do not exit loop here, since we prefer system's declarations
19243 if ( test "$GCC" = yes || test "$GXX" = yes )
19245 echo "$as_me:19245: checking if you want to turn on gcc warnings" >&5
19246 echo $ECHO_N "checking if you want to turn on gcc warnings... $ECHO_C" >&6
19248 # Check whether --enable-warnings or --disable-warnings was given.
19249 if test "${enable_warnings+set}" = set; then
19250 enableval="$enable_warnings"
19251 test "$enableval" != yes && enableval=no
19252 if test "$enableval" != "no" ; then
19262 echo "$as_me:19262: result: $with_warnings" >&5
19263 echo "${ECHO_T}$with_warnings" >&6
19264 if test "$with_warnings" = "yes"
19267 if test "$GCC" = yes
19269 cat > conftest.i <<EOF
19271 #define GCC_PRINTF 0
19274 #define GCC_SCANF 0
19276 #ifndef GCC_NORETURN
19277 #define GCC_NORETURN /* nothing */
19280 #define GCC_UNUSED /* nothing */
19283 if test "$GCC" = yes
19285 { echo "$as_me:19285: checking for $CC __attribute__ directives..." >&5
19286 echo "$as_me: checking for $CC __attribute__ directives..." >&6;}
19287 cat > conftest.$ac_ext <<EOF
19288 #line 19288 "${as_me:-configure}"
19289 #include "confdefs.h"
19290 #include "conftest.h"
19291 #include "conftest.i"
19293 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
19295 #define GCC_PRINTFLIKE(fmt,var) /*nothing*/
19298 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
19300 #define GCC_SCANFLIKE(fmt,var) /*nothing*/
19302 extern void wow(char *,...) GCC_SCANFLIKE(1,2);
19303 extern void oops(char *,...) GCC_PRINTFLIKE(1,2) GCC_NORETURN;
19304 extern void foo(void) GCC_NORETURN;
19305 int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { return 0; }
19307 cf_printf_attribute=no
19308 cf_scanf_attribute=no
19309 for cf_attribute in scanf printf unused noreturn
19312 cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
19314 cf_directive="__attribute__(($cf_attribute))"
19315 echo "checking for $CC $cf_directive" 1>&5
19317 case $cf_attribute in
19319 cf_printf_attribute=yes
19320 cat >conftest.h <<EOF
19321 #define GCC_$cf_ATTRIBUTE 1
19325 cf_scanf_attribute=yes
19326 cat >conftest.h <<EOF
19327 #define GCC_$cf_ATTRIBUTE 1
19331 cat >conftest.h <<EOF
19332 #define GCC_$cf_ATTRIBUTE $cf_directive
19337 if { (eval echo "$as_me:19337: \"$ac_compile\"") >&5
19338 (eval $ac_compile) 2>&5
19340 echo "$as_me:19340: \$? = $ac_status" >&5
19341 (exit $ac_status); }; then
19342 test -n "$verbose" && echo "$as_me:19342: result: ... $cf_attribute" >&5
19343 echo "${ECHO_T}... $cf_attribute" >&6
19344 cat conftest.h >>confdefs.h
19345 case $cf_attribute in
19348 cat >>confdefs.h <<EOF
19349 #define GCC_NORETURN $cf_directive
19354 cf_value='/* nothing */'
19355 if test "$cf_printf_attribute" != no ; then
19356 cf_value='__attribute__((format(printf,fmt,var)))'
19358 cat >>confdefs.h <<\EOF
19359 #define GCC_PRINTF 1
19364 cat >>confdefs.h <<EOF
19365 #define GCC_PRINTFLIKE(fmt,var) $cf_value
19370 cf_value='/* nothing */'
19371 if test "$cf_scanf_attribute" != no ; then
19372 cf_value='__attribute__((format(scanf,fmt,var)))'
19374 cat >>confdefs.h <<\EOF
19375 #define GCC_SCANF 1
19380 cat >>confdefs.h <<EOF
19381 #define GCC_SCANFLIKE(fmt,var) $cf_value
19387 cat >>confdefs.h <<EOF
19388 #define GCC_UNUSED $cf_directive
19396 fgrep define conftest.i >>confdefs.h
19403 if test "$GCC" = yes ; then
19406 echo "$as_me:19406: checking if this is really Intel C compiler" >&5
19407 echo $ECHO_N "checking if this is really Intel C compiler... $ECHO_C" >&6
19408 cf_save_CFLAGS="$CFLAGS"
19409 CFLAGS="$CFLAGS -no-gcc"
19410 cat >conftest.$ac_ext <<_ACEOF
19411 #line 19411 "configure"
19412 #include "confdefs.h"
19418 #ifdef __INTEL_COMPILER
19427 rm -f conftest.$ac_objext
19428 if { (eval echo "$as_me:19428: \"$ac_compile\"") >&5
19429 (eval $ac_compile) 2>&5
19431 echo "$as_me:19431: \$? = $ac_status" >&5
19432 (exit $ac_status); } &&
19433 { ac_try='test -s conftest.$ac_objext'
19434 { (eval echo "$as_me:19434: \"$ac_try\"") >&5
19435 (eval $ac_try) 2>&5
19437 echo "$as_me:19437: \$? = $ac_status" >&5
19438 (exit $ac_status); }; }; then
19440 cf_save_CFLAGS="$cf_save_CFLAGS -we147"
19443 echo "$as_me: failed program was:" >&5
19444 cat conftest.$ac_ext >&5
19446 rm -f conftest.$ac_objext conftest.$ac_ext
19447 CFLAGS="$cf_save_CFLAGS"
19448 echo "$as_me:19448: result: $INTEL_COMPILER" >&5
19449 echo "${ECHO_T}$INTEL_COMPILER" >&6
19456 if test "$GCC" = yes ; then
19457 echo "$as_me:19457: checking if this is really Clang C compiler" >&5
19458 echo $ECHO_N "checking if this is really Clang C compiler... $ECHO_C" >&6
19459 cf_save_CFLAGS="$CFLAGS"
19460 CFLAGS="$CFLAGS -Qunused-arguments"
19461 cat >conftest.$ac_ext <<_ACEOF
19462 #line 19462 "configure"
19463 #include "confdefs.h"
19478 rm -f conftest.$ac_objext
19479 if { (eval echo "$as_me:19479: \"$ac_compile\"") >&5
19480 (eval $ac_compile) 2>&5
19482 echo "$as_me:19482: \$? = $ac_status" >&5
19483 (exit $ac_status); } &&
19484 { ac_try='test -s conftest.$ac_objext'
19485 { (eval echo "$as_me:19485: \"$ac_try\"") >&5
19486 (eval $ac_try) 2>&5
19488 echo "$as_me:19488: \$? = $ac_status" >&5
19489 (exit $ac_status); }; }; then
19491 cf_save_CFLAGS="$cf_save_CFLAGS -Qunused-arguments"
19494 echo "$as_me: failed program was:" >&5
19495 cat conftest.$ac_ext >&5
19497 rm -f conftest.$ac_objext conftest.$ac_ext
19498 CFLAGS="$cf_save_CFLAGS"
19499 echo "$as_me:19499: result: $CLANG_COMPILER" >&5
19500 echo "${ECHO_T}$CLANG_COMPILER" >&6
19503 cat > conftest.$ac_ext <<EOF
19504 #line 19504 "${as_me:-configure}"
19505 int main(int argc, char *argv[]) { return (argv[argc-1] == 0) ; }
19508 if test "$INTEL_COMPILER" = yes
19510 # The "-wdXXX" options suppress warnings:
19511 # remark #1419: external declaration in primary source file
19512 # remark #1683: explicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem)
19513 # remark #1684: conversion from pointer to same-sized integral type (potential portability problem)
19514 # remark #193: zero used for undefined preprocessing identifier
19515 # remark #593: variable "curs_sb_left_arrow" was set but never used
19516 # remark #810: conversion from "int" to "Dimension={unsigned short}" may lose significant bits
19517 # remark #869: parameter "tw" was never referenced
19518 # remark #981: operands are evaluated in unspecified order
19519 # warning #279: controlling expression is constant
19521 { echo "$as_me:19521: checking for $CC warning options..." >&5
19522 echo "$as_me: checking for $CC warning options..." >&6;}
19523 cf_save_CFLAGS="$CFLAGS"
19524 EXTRA_CFLAGS="-Wall"
19536 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
19537 if { (eval echo "$as_me:19537: \"$ac_compile\"") >&5
19538 (eval $ac_compile) 2>&5
19540 echo "$as_me:19540: \$? = $ac_status" >&5
19541 (exit $ac_status); }; then
19542 test -n "$verbose" && echo "$as_me:19542: result: ... -$cf_opt" >&5
19543 echo "${ECHO_T}... -$cf_opt" >&6
19544 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
19547 CFLAGS="$cf_save_CFLAGS"
19549 elif test "$GCC" = yes
19551 { echo "$as_me:19551: checking for $CC warning options..." >&5
19552 echo "$as_me: checking for $CC warning options..." >&6;}
19553 cf_save_CFLAGS="$CFLAGS"
19556 test "$with_ext_const" = yes && cf_warn_CONST="Wwrite-strings"
19557 cf_gcc_warnings="Wignored-qualifiers Wlogical-op Wvarargs"
19558 test "x$CLANG_COMPILER" = xyes && cf_gcc_warnings=
19559 for cf_opt in W Wall \
19560 Wbad-function-cast \
19563 Wdeclaration-after-statement \
19566 Wmissing-declarations \
19567 Wmissing-prototypes \
19571 Wstrict-prototypes \
19572 Wundef $cf_gcc_warnings $cf_warn_CONST Wno-unknown-pragmas
19574 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
19575 if { (eval echo "$as_me:19575: \"$ac_compile\"") >&5
19576 (eval $ac_compile) 2>&5
19578 echo "$as_me:19578: \$? = $ac_status" >&5
19579 (exit $ac_status); }; then
19580 test -n "$verbose" && echo "$as_me:19580: result: ... -$cf_opt" >&5
19581 echo "${ECHO_T}... -$cf_opt" >&6
19585 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
19586 CPPFLAGS="${CPPFLAGS}-DXTSTRINGDEFINES"
19590 case $GCC_VERSION in
19592 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
19594 echo "${as_me:-configure}:19594: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
19600 case $GCC_VERSION in
19602 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
19604 echo "${as_me:-configure}:19604: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
19610 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
19613 CFLAGS="$cf_save_CFLAGS"
19620 echo "$as_me:19620: checking if you want to use dmalloc for testing" >&5
19621 echo $ECHO_N "checking if you want to use dmalloc for testing... $ECHO_C" >&6
19623 # Check whether --with-dmalloc or --without-dmalloc was given.
19624 if test "${with_dmalloc+set}" = set; then
19625 withval="$with_dmalloc"
19627 cat >>confdefs.h <<EOF
19628 #define USE_DMALLOC 1
19631 : ${with_cflags:=-g}
19632 : ${with_no_leaks:=yes}
19637 echo "$as_me:19637: result: ${with_dmalloc:-no}" >&5
19638 echo "${ECHO_T}${with_dmalloc:-no}" >&6
19640 case .$with_cflags in
19650 cf_new_extra_cppflags=
19652 for cf_add_cflags in -g
19654 case $cf_fix_cppflags in
19656 case $cf_add_cflags in
19657 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
19658 case $cf_add_cflags in
19660 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
19662 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
19663 && test -z "${cf_tst_cflags}" \
19664 && cf_fix_cppflags=yes
19666 if test $cf_fix_cppflags = yes ; then
19668 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
19669 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
19672 elif test "${cf_tst_cflags}" = "\"'" ; then
19674 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
19675 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
19681 case "$CPPFLAGS" in
19685 case $cf_add_cflags in
19687 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
19689 CPPFLAGS=`echo "$CPPFLAGS" | \
19690 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
19691 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
19696 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
19697 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
19704 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
19705 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
19712 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
19713 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
19715 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
19717 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
19718 && test -z "${cf_tst_cflags}" \
19719 && cf_fix_cppflags=no
19724 if test -n "$cf_new_cflags" ; then
19726 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
19727 CFLAGS="${CFLAGS}$cf_new_cflags"
19731 if test -n "$cf_new_cppflags" ; then
19733 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
19734 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
19738 if test -n "$cf_new_extra_cppflags" ; then
19740 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
19741 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
19750 if test "$with_dmalloc" = yes ; then
19751 echo "$as_me:19751: checking for dmalloc.h" >&5
19752 echo $ECHO_N "checking for dmalloc.h... $ECHO_C" >&6
19753 if test "${ac_cv_header_dmalloc_h+set}" = set; then
19754 echo $ECHO_N "(cached) $ECHO_C" >&6
19756 cat >conftest.$ac_ext <<_ACEOF
19757 #line 19757 "configure"
19758 #include "confdefs.h"
19759 #include <dmalloc.h>
19761 if { (eval echo "$as_me:19761: \"$ac_cpp conftest.$ac_ext\"") >&5
19762 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
19764 egrep -v '^ *\+' conftest.er1 >conftest.err
19766 cat conftest.err >&5
19767 echo "$as_me:19767: \$? = $ac_status" >&5
19768 (exit $ac_status); } >/dev/null; then
19769 if test -s conftest.err; then
19770 ac_cpp_err=$ac_c_preproc_warn_flag
19777 if test -z "$ac_cpp_err"; then
19778 ac_cv_header_dmalloc_h=yes
19780 echo "$as_me: failed program was:" >&5
19781 cat conftest.$ac_ext >&5
19782 ac_cv_header_dmalloc_h=no
19784 rm -f conftest.err conftest.$ac_ext
19786 echo "$as_me:19786: result: $ac_cv_header_dmalloc_h" >&5
19787 echo "${ECHO_T}$ac_cv_header_dmalloc_h" >&6
19788 if test $ac_cv_header_dmalloc_h = yes; then
19790 echo "$as_me:19790: checking for dmalloc_debug in -ldmalloc" >&5
19791 echo $ECHO_N "checking for dmalloc_debug in -ldmalloc... $ECHO_C" >&6
19792 if test "${ac_cv_lib_dmalloc_dmalloc_debug+set}" = set; then
19793 echo $ECHO_N "(cached) $ECHO_C" >&6
19795 ac_check_lib_save_LIBS=$LIBS
19796 LIBS="-ldmalloc $LIBS"
19797 cat >conftest.$ac_ext <<_ACEOF
19798 #line 19798 "configure"
19799 #include "confdefs.h"
19801 /* Override any gcc2 internal prototype to avoid an error. */
19805 /* We use char because int might match the return type of a gcc2
19806 builtin and then its argument prototype would still apply. */
19807 char dmalloc_debug ();
19816 rm -f conftest.$ac_objext conftest$ac_exeext
19817 if { (eval echo "$as_me:19817: \"$ac_link\"") >&5
19818 (eval $ac_link) 2>&5
19820 echo "$as_me:19820: \$? = $ac_status" >&5
19821 (exit $ac_status); } &&
19822 { ac_try='test -s conftest$ac_exeext'
19823 { (eval echo "$as_me:19823: \"$ac_try\"") >&5
19824 (eval $ac_try) 2>&5
19826 echo "$as_me:19826: \$? = $ac_status" >&5
19827 (exit $ac_status); }; }; then
19828 ac_cv_lib_dmalloc_dmalloc_debug=yes
19830 echo "$as_me: failed program was:" >&5
19831 cat conftest.$ac_ext >&5
19832 ac_cv_lib_dmalloc_dmalloc_debug=no
19834 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
19835 LIBS=$ac_check_lib_save_LIBS
19837 echo "$as_me:19837: result: $ac_cv_lib_dmalloc_dmalloc_debug" >&5
19838 echo "${ECHO_T}$ac_cv_lib_dmalloc_dmalloc_debug" >&6
19839 if test $ac_cv_lib_dmalloc_dmalloc_debug = yes; then
19840 cat >>confdefs.h <<EOF
19841 #define HAVE_LIBDMALLOC 1
19844 LIBS="-ldmalloc $LIBS"
19852 echo "$as_me:19852: checking if you want to use dbmalloc for testing" >&5
19853 echo $ECHO_N "checking if you want to use dbmalloc for testing... $ECHO_C" >&6
19855 # Check whether --with-dbmalloc or --without-dbmalloc was given.
19856 if test "${with_dbmalloc+set}" = set; then
19857 withval="$with_dbmalloc"
19859 cat >>confdefs.h <<EOF
19860 #define USE_DBMALLOC 1
19863 : ${with_cflags:=-g}
19864 : ${with_no_leaks:=yes}
19869 echo "$as_me:19869: result: ${with_dbmalloc:-no}" >&5
19870 echo "${ECHO_T}${with_dbmalloc:-no}" >&6
19872 case .$with_cflags in
19882 cf_new_extra_cppflags=
19884 for cf_add_cflags in -g
19886 case $cf_fix_cppflags in
19888 case $cf_add_cflags in
19889 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
19890 case $cf_add_cflags in
19892 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
19894 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
19895 && test -z "${cf_tst_cflags}" \
19896 && cf_fix_cppflags=yes
19898 if test $cf_fix_cppflags = yes ; then
19900 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
19901 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
19904 elif test "${cf_tst_cflags}" = "\"'" ; then
19906 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
19907 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
19913 case "$CPPFLAGS" in
19917 case $cf_add_cflags in
19919 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
19921 CPPFLAGS=`echo "$CPPFLAGS" | \
19922 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
19923 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
19928 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
19929 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
19936 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
19937 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
19944 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
19945 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
19947 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
19949 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
19950 && test -z "${cf_tst_cflags}" \
19951 && cf_fix_cppflags=no
19956 if test -n "$cf_new_cflags" ; then
19958 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
19959 CFLAGS="${CFLAGS}$cf_new_cflags"
19963 if test -n "$cf_new_cppflags" ; then
19965 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
19966 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
19970 if test -n "$cf_new_extra_cppflags" ; then
19972 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
19973 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
19982 if test "$with_dbmalloc" = yes ; then
19983 echo "$as_me:19983: checking for dbmalloc.h" >&5
19984 echo $ECHO_N "checking for dbmalloc.h... $ECHO_C" >&6
19985 if test "${ac_cv_header_dbmalloc_h+set}" = set; then
19986 echo $ECHO_N "(cached) $ECHO_C" >&6
19988 cat >conftest.$ac_ext <<_ACEOF
19989 #line 19989 "configure"
19990 #include "confdefs.h"
19991 #include <dbmalloc.h>
19993 if { (eval echo "$as_me:19993: \"$ac_cpp conftest.$ac_ext\"") >&5
19994 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
19996 egrep -v '^ *\+' conftest.er1 >conftest.err
19998 cat conftest.err >&5
19999 echo "$as_me:19999: \$? = $ac_status" >&5
20000 (exit $ac_status); } >/dev/null; then
20001 if test -s conftest.err; then
20002 ac_cpp_err=$ac_c_preproc_warn_flag
20009 if test -z "$ac_cpp_err"; then
20010 ac_cv_header_dbmalloc_h=yes
20012 echo "$as_me: failed program was:" >&5
20013 cat conftest.$ac_ext >&5
20014 ac_cv_header_dbmalloc_h=no
20016 rm -f conftest.err conftest.$ac_ext
20018 echo "$as_me:20018: result: $ac_cv_header_dbmalloc_h" >&5
20019 echo "${ECHO_T}$ac_cv_header_dbmalloc_h" >&6
20020 if test $ac_cv_header_dbmalloc_h = yes; then
20022 echo "$as_me:20022: checking for debug_malloc in -ldbmalloc" >&5
20023 echo $ECHO_N "checking for debug_malloc in -ldbmalloc... $ECHO_C" >&6
20024 if test "${ac_cv_lib_dbmalloc_debug_malloc+set}" = set; then
20025 echo $ECHO_N "(cached) $ECHO_C" >&6
20027 ac_check_lib_save_LIBS=$LIBS
20028 LIBS="-ldbmalloc $LIBS"
20029 cat >conftest.$ac_ext <<_ACEOF
20030 #line 20030 "configure"
20031 #include "confdefs.h"
20033 /* Override any gcc2 internal prototype to avoid an error. */
20037 /* We use char because int might match the return type of a gcc2
20038 builtin and then its argument prototype would still apply. */
20039 char debug_malloc ();
20048 rm -f conftest.$ac_objext conftest$ac_exeext
20049 if { (eval echo "$as_me:20049: \"$ac_link\"") >&5
20050 (eval $ac_link) 2>&5
20052 echo "$as_me:20052: \$? = $ac_status" >&5
20053 (exit $ac_status); } &&
20054 { ac_try='test -s conftest$ac_exeext'
20055 { (eval echo "$as_me:20055: \"$ac_try\"") >&5
20056 (eval $ac_try) 2>&5
20058 echo "$as_me:20058: \$? = $ac_status" >&5
20059 (exit $ac_status); }; }; then
20060 ac_cv_lib_dbmalloc_debug_malloc=yes
20062 echo "$as_me: failed program was:" >&5
20063 cat conftest.$ac_ext >&5
20064 ac_cv_lib_dbmalloc_debug_malloc=no
20066 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20067 LIBS=$ac_check_lib_save_LIBS
20069 echo "$as_me:20069: result: $ac_cv_lib_dbmalloc_debug_malloc" >&5
20070 echo "${ECHO_T}$ac_cv_lib_dbmalloc_debug_malloc" >&6
20071 if test $ac_cv_lib_dbmalloc_debug_malloc = yes; then
20072 cat >>confdefs.h <<EOF
20073 #define HAVE_LIBDBMALLOC 1
20076 LIBS="-ldbmalloc $LIBS"
20084 echo "$as_me:20084: checking if you want to use valgrind for testing" >&5
20085 echo $ECHO_N "checking if you want to use valgrind for testing... $ECHO_C" >&6
20087 # Check whether --with-valgrind or --without-valgrind was given.
20088 if test "${with_valgrind+set}" = set; then
20089 withval="$with_valgrind"
20091 cat >>confdefs.h <<EOF
20092 #define USE_VALGRIND 1
20095 : ${with_cflags:=-g}
20096 : ${with_no_leaks:=yes}
20101 echo "$as_me:20101: result: ${with_valgrind:-no}" >&5
20102 echo "${ECHO_T}${with_valgrind:-no}" >&6
20104 case .$with_cflags in
20114 cf_new_extra_cppflags=
20116 for cf_add_cflags in -g
20118 case $cf_fix_cppflags in
20120 case $cf_add_cflags in
20121 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
20122 case $cf_add_cflags in
20124 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
20126 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
20127 && test -z "${cf_tst_cflags}" \
20128 && cf_fix_cppflags=yes
20130 if test $cf_fix_cppflags = yes ; then
20132 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
20133 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
20136 elif test "${cf_tst_cflags}" = "\"'" ; then
20138 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
20139 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
20145 case "$CPPFLAGS" in
20149 case $cf_add_cflags in
20151 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
20153 CPPFLAGS=`echo "$CPPFLAGS" | \
20154 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
20155 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
20160 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
20161 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
20168 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
20169 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
20176 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
20177 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
20179 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
20181 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
20182 && test -z "${cf_tst_cflags}" \
20183 && cf_fix_cppflags=no
20188 if test -n "$cf_new_cflags" ; then
20190 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
20191 CFLAGS="${CFLAGS}$cf_new_cflags"
20195 if test -n "$cf_new_cppflags" ; then
20197 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
20198 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
20202 if test -n "$cf_new_extra_cppflags" ; then
20204 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
20205 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
20214 echo "$as_me:20214: checking if you want to perform memory-leak testing" >&5
20215 echo $ECHO_N "checking if you want to perform memory-leak testing... $ECHO_C" >&6
20217 # Check whether --enable-leaks or --disable-leaks was given.
20218 if test "${enable_leaks+set}" = set; then
20219 enableval="$enable_leaks"
20220 if test "x$enableval" = xno; then with_no_leaks=yes; else with_no_leaks=no; fi
20222 : ${with_no_leaks:=no}
20224 echo "$as_me:20224: result: $with_no_leaks" >&5
20225 echo "${ECHO_T}$with_no_leaks" >&6
20227 if test "$with_no_leaks" = yes ; then
20229 cat >>confdefs.h <<\EOF
20233 cat >>confdefs.h <<\EOF
20234 #define YY_NO_LEAKS 1
20240 if test "x$cf_cv_enable_rpath" != xno
20242 echo "$as_me:20242: checking for an rpath option" >&5
20243 echo $ECHO_N "checking for an rpath option... $ECHO_C" >&6
20244 case $cf_cv_system_name in
20246 if test "$GCC" = yes; then
20247 LD_RPATH_OPT="-Wl,-rpath,"
20249 LD_RPATH_OPT="-rpath "
20252 (linux*|gnu*|k*bsd*-gnu|freebsd*)
20253 LD_RPATH_OPT="-Wl,-rpath,"
20255 (openbsd[2-9].*|mirbsd*)
20256 LD_RPATH_OPT="-Wl,-rpath,"
20259 LD_RPATH_OPT="-rpath "
20262 LD_RPATH_OPT="-Wl,-rpath,"
20265 LD_RPATH_OPT="-rpath "
20273 echo "$as_me:20273: result: $LD_RPATH_OPT" >&5
20274 echo "${ECHO_T}$LD_RPATH_OPT" >&6
20276 case "x$LD_RPATH_OPT" in
20278 echo "$as_me:20278: checking if we need a space after rpath option" >&5
20279 echo $ECHO_N "checking if we need a space after rpath option... $ECHO_C" >&6
20280 cf_save_LIBS="$LIBS"
20282 cf_add_libs="${LD_RPATH_OPT}$libdir"
20283 # Filter out duplicates - this happens with badly-designed ".pc" files...
20284 for cf_add_1lib in $LIBS
20286 for cf_add_2lib in $cf_add_libs
20288 if test "x$cf_add_1lib" = "x$cf_add_2lib"
20294 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
20296 LIBS="$cf_add_libs"
20298 cat >conftest.$ac_ext <<_ACEOF
20299 #line 20299 "configure"
20300 #include "confdefs.h"
20310 rm -f conftest.$ac_objext conftest$ac_exeext
20311 if { (eval echo "$as_me:20311: \"$ac_link\"") >&5
20312 (eval $ac_link) 2>&5
20314 echo "$as_me:20314: \$? = $ac_status" >&5
20315 (exit $ac_status); } &&
20316 { ac_try='test -s conftest$ac_exeext'
20317 { (eval echo "$as_me:20317: \"$ac_try\"") >&5
20318 (eval $ac_try) 2>&5
20320 echo "$as_me:20320: \$? = $ac_status" >&5
20321 (exit $ac_status); }; }; then
20324 echo "$as_me: failed program was:" >&5
20325 cat conftest.$ac_ext >&5
20328 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20329 LIBS="$cf_save_LIBS"
20330 echo "$as_me:20330: result: $cf_rpath_space" >&5
20331 echo "${ECHO_T}$cf_rpath_space" >&6
20332 test "$cf_rpath_space" = yes && LD_RPATH_OPT="$LD_RPATH_OPT "
20337 echo "$as_me:20337: checking if rpath-hack should be disabled" >&5
20338 echo $ECHO_N "checking if rpath-hack should be disabled... $ECHO_C" >&6
20340 # Check whether --enable-rpath-hack or --disable-rpath-hack was given.
20341 if test "${enable_rpath_hack+set}" = set; then
20342 enableval="$enable_rpath_hack"
20343 test "$enableval" != no && enableval=yes
20344 if test "$enableval" != "yes" ; then
20345 cf_disable_rpath_hack=yes
20347 cf_disable_rpath_hack=no
20351 cf_disable_rpath_hack=no
20354 echo "$as_me:20354: result: $cf_disable_rpath_hack" >&5
20355 echo "${ECHO_T}$cf_disable_rpath_hack" >&6
20356 if test "$cf_disable_rpath_hack" = no ; then
20358 echo "$as_me:20358: checking for updated LDFLAGS" >&5
20359 echo $ECHO_N "checking for updated LDFLAGS... $ECHO_C" >&6
20360 if test -n "$LD_RPATH_OPT" ; then
20361 echo "$as_me:20361: result: maybe" >&5
20362 echo "${ECHO_T}maybe" >&6
20366 # Extract the first word of "$ac_prog", so it can be a program name with args.
20367 set dummy $ac_prog; ac_word=$2
20368 echo "$as_me:20368: checking for $ac_word" >&5
20369 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
20370 if test "${ac_cv_prog_cf_ldd_prog+set}" = set; then
20371 echo $ECHO_N "(cached) $ECHO_C" >&6
20373 if test -n "$cf_ldd_prog"; then
20374 ac_cv_prog_cf_ldd_prog="$cf_ldd_prog" # Let the user override the test.
20376 ac_save_IFS=$IFS; IFS=$ac_path_separator
20378 for ac_dir in $ac_dummy; do
20380 test -z "$ac_dir" && ac_dir=.
20381 $as_executable_p "$ac_dir/$ac_word" || continue
20382 ac_cv_prog_cf_ldd_prog="$ac_prog"
20383 echo "$as_me:20383: found $ac_dir/$ac_word" >&5
20389 cf_ldd_prog=$ac_cv_prog_cf_ldd_prog
20390 if test -n "$cf_ldd_prog"; then
20391 echo "$as_me:20391: result: $cf_ldd_prog" >&5
20392 echo "${ECHO_T}$cf_ldd_prog" >&6
20394 echo "$as_me:20394: result: no" >&5
20395 echo "${ECHO_T}no" >&6
20398 test -n "$cf_ldd_prog" && break
20400 test -n "$cf_ldd_prog" || cf_ldd_prog="no"
20402 cf_rpath_list="/usr/lib /lib"
20403 if test "$cf_ldd_prog" != no
20407 cat >conftest.$ac_ext <<_ACEOF
20408 #line 20408 "configure"
20409 #include "confdefs.h"
20419 rm -f conftest.$ac_objext conftest$ac_exeext
20420 if { (eval echo "$as_me:20420: \"$ac_link\"") >&5
20421 (eval $ac_link) 2>&5
20423 echo "$as_me:20423: \$? = $ac_status" >&5
20424 (exit $ac_status); } &&
20425 { ac_try='test -s conftest$ac_exeext'
20426 { (eval echo "$as_me:20426: \"$ac_try\"") >&5
20427 (eval $ac_try) 2>&5
20429 echo "$as_me:20429: \$? = $ac_status" >&5
20430 (exit $ac_status); }; }; then
20431 cf_rpath_oops=`$cf_ldd_prog conftest$ac_exeext | fgrep ' not found' | sed -e 's% =>.*$%%' |sort | uniq`
20432 cf_rpath_list=`$cf_ldd_prog conftest$ac_exeext | fgrep / | sed -e 's%^.*[ ]/%/%' -e 's%/[^/][^/]*$%%' |sort | uniq`
20434 echo "$as_me: failed program was:" >&5
20435 cat conftest.$ac_ext >&5
20437 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20439 # If we passed the link-test, but get a "not found" on a given library,
20440 # this could be due to inept reconfiguration of gcc to make it only
20441 # partly honor /usr/local/lib (or whatever). Sometimes this behavior
20442 # is intentional, e.g., installing gcc in /usr/bin and suppressing the
20443 # /usr/local libraries.
20444 if test -n "$cf_rpath_oops"
20446 for cf_rpath_src in $cf_rpath_oops
20448 for cf_rpath_dir in \
20453 if test -f $cf_rpath_dir/lib/$cf_rpath_src
20455 test -n "$verbose" && echo " ...adding -L$cf_rpath_dir/lib to LDFLAGS for $cf_rpath_src" 1>&6
20457 echo "${as_me:-configure}:20457: testing ...adding -L$cf_rpath_dir/lib to LDFLAGS for $cf_rpath_src ..." 1>&5
20459 LDFLAGS="$LDFLAGS -L$cf_rpath_dir/lib"
20467 test -n "$verbose" && echo " ...checking EXTRA_LDFLAGS $EXTRA_LDFLAGS" 1>&6
20469 echo "${as_me:-configure}:20469: testing ...checking EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5
20471 test -n "$verbose" && echo " ...checking LDFLAGS $LDFLAGS" 1>&6
20473 echo "${as_me:-configure}:20473: testing ...checking LDFLAGS $LDFLAGS ..." 1>&5
20476 for cf_rpath_src in $LDFLAGS
20478 case $cf_rpath_src in
20481 # check if this refers to a directory which we will ignore
20483 if test -n "$cf_rpath_list"
20485 for cf_rpath_item in $cf_rpath_list
20487 if test "x$cf_rpath_src" = "x-L$cf_rpath_item"
20495 if test "$cf_rpath_skip" = no
20497 # transform the option
20498 if test "$LD_RPATH_OPT" = "-R " ; then
20499 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%-R %"`
20501 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%$LD_RPATH_OPT%"`
20504 # if we have not already added this, add it now
20505 cf_rpath_tst=`echo "$EXTRA_LDFLAGS" | sed -e "s%$cf_rpath_tmp %%"`
20506 if test "x$cf_rpath_tst" = "x$EXTRA_LDFLAGS"
20508 test -n "$verbose" && echo " ...Filter $cf_rpath_src ->$cf_rpath_tmp" 1>&6
20510 echo "${as_me:-configure}:20510: testing ...Filter $cf_rpath_src ->$cf_rpath_tmp ..." 1>&5
20512 EXTRA_LDFLAGS="$cf_rpath_tmp $EXTRA_LDFLAGS"
20517 cf_rpath_dst="$cf_rpath_dst $cf_rpath_src"
20519 LDFLAGS=$cf_rpath_dst
20521 test -n "$verbose" && echo " ...checked LDFLAGS $LDFLAGS" 1>&6
20523 echo "${as_me:-configure}:20523: testing ...checked LDFLAGS $LDFLAGS ..." 1>&5
20525 test -n "$verbose" && echo " ...checking LIBS $LIBS" 1>&6
20527 echo "${as_me:-configure}:20527: testing ...checking LIBS $LIBS ..." 1>&5
20530 for cf_rpath_src in $LIBS
20532 case $cf_rpath_src in
20535 # check if this refers to a directory which we will ignore
20537 if test -n "$cf_rpath_list"
20539 for cf_rpath_item in $cf_rpath_list
20541 if test "x$cf_rpath_src" = "x-L$cf_rpath_item"
20549 if test "$cf_rpath_skip" = no
20551 # transform the option
20552 if test "$LD_RPATH_OPT" = "-R " ; then
20553 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%-R %"`
20555 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%$LD_RPATH_OPT%"`
20558 # if we have not already added this, add it now
20559 cf_rpath_tst=`echo "$EXTRA_LDFLAGS" | sed -e "s%$cf_rpath_tmp %%"`
20560 if test "x$cf_rpath_tst" = "x$EXTRA_LDFLAGS"
20562 test -n "$verbose" && echo " ...Filter $cf_rpath_src ->$cf_rpath_tmp" 1>&6
20564 echo "${as_me:-configure}:20564: testing ...Filter $cf_rpath_src ->$cf_rpath_tmp ..." 1>&5
20566 EXTRA_LDFLAGS="$cf_rpath_tmp $EXTRA_LDFLAGS"
20571 cf_rpath_dst="$cf_rpath_dst $cf_rpath_src"
20575 test -n "$verbose" && echo " ...checked LIBS $LIBS" 1>&6
20577 echo "${as_me:-configure}:20577: testing ...checked LIBS $LIBS ..." 1>&5
20579 test -n "$verbose" && echo " ...checked EXTRA_LDFLAGS $EXTRA_LDFLAGS" 1>&6
20581 echo "${as_me:-configure}:20581: testing ...checked EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5
20584 echo "$as_me:20584: result: no" >&5
20585 echo "${ECHO_T}no" >&6
20593 ac_config_files="$ac_config_files Makefile"
20594 ac_config_commands="$ac_config_commands default"
20595 cat >confcache <<\_ACEOF
20596 # This file is a shell script that caches the results of configure
20597 # tests run on this system so they can be shared between configure
20598 # scripts and configure runs, see configure's option --config-cache.
20599 # It is not useful on other systems. If it contains results you don't
20600 # want to keep, you may remove or edit it.
20602 # config.status only pays attention to the cache file if you give it
20603 # the --recheck option to rerun configure.
20605 # `ac_cv_env_foo' variables (set or unset) will be overriden when
20606 # loading this file, other *unset* `ac_cv_foo' will be assigned the
20607 # following values.
20611 # The following way of writing the cache mishandles newlines in values,
20612 # but we know of no workaround that is simple, portable, and efficient.
20613 # So, don't put newlines in cache variables' values.
20614 # Ultrix sh set writes to stderr and can't be redirected directly,
20615 # and sets the high bit in the cache file unless we assign to the vars.
20618 case `(ac_space=' '; set | grep ac_space) 2>&1` in
20620 # `set' does not quote correctly, so add quotes (double-quote
20621 # substitution turns \\\\ into \\, and sed turns \\ into \).
20624 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
20627 # `set' quotes correctly as required by POSIX, so do not add quotes.
20629 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
20636 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
20638 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
20640 if cmp -s $cache_file confcache; then :; else
20641 if test -w $cache_file; then
20642 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
20643 cat confcache >$cache_file
20645 echo "not updating unwritable cache $cache_file"
20650 test "x$prefix" = xNONE && prefix=$ac_default_prefix
20651 # Let make expand exec_prefix.
20652 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
20654 # VPATH may cause trouble with some makes, so we remove $(srcdir),
20655 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
20656 # trailing colons and then remove the whole line if VPATH becomes empty
20657 # (actually we leave an empty line to preserve line numbers).
20658 if test "x$srcdir" = x.; then
20659 ac_vpsub='/^[ ]*VPATH[ ]*=/{
20660 s/:*\$(srcdir):*/:/;
20661 s/:*\${srcdir}:*/:/;
20663 s/^\([^=]*=[ ]*\):*/\1/;
20669 DEFS=-DHAVE_CONFIG_H
20671 : ${CONFIG_STATUS=./config.status}
20672 ac_clean_files_save=$ac_clean_files
20673 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
20674 { echo "$as_me:20674: creating $CONFIG_STATUS" >&5
20675 echo "$as_me: creating $CONFIG_STATUS" >&6;}
20676 cat >$CONFIG_STATUS <<_ACEOF
20678 # Generated automatically by configure.
20679 # Run this file to recreate the current configuration.
20680 # Compiler output produced by configure, useful for debugging
20681 # configure, is in config.log if it exists.
20684 SHELL=\${CONFIG_SHELL-$SHELL}
20685 ac_cs_invocation="\$0 \$@"
20689 cat >>$CONFIG_STATUS <<\_ACEOF
20690 # Be Bourne compatible
20691 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
20694 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
20698 # Name of the executable.
20699 as_me=`echo "$0" |sed 's,.*[\\/],,'`
20701 if expr a : '\(a\)' >/dev/null 2>&1; then
20707 rm -f conf$$ conf$$.exe conf$$.file
20709 if ln -s conf$$.file conf$$ 2>/dev/null; then
20710 # We could just check for DJGPP; but this test a) works b) is more generic
20711 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
20712 if test -f conf$$.exe; then
20713 # Don't use ln at all; we don't have any links
20718 elif ln conf$$.file conf$$ 2>/dev/null; then
20723 rm -f conf$$ conf$$.exe conf$$.file
20725 as_executable_p="test -f"
20727 # Support unset when possible.
20728 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
20735 $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
20736 $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
20737 $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
20738 $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
20739 $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
20740 $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
20741 $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
20742 $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
20745 # We need space, tab and new line, in precisely that order.
20751 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
20757 # Files that config.status was made for.
20758 if test -n "$ac_config_files"; then
20759 echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
20762 if test -n "$ac_config_headers"; then
20763 echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
20766 if test -n "$ac_config_links"; then
20767 echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
20770 if test -n "$ac_config_commands"; then
20771 echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
20774 cat >>$CONFIG_STATUS <<\EOF
20777 \`$as_me' instantiates files from templates according to the
20778 current configuration.
20780 Usage: $0 [OPTIONS] [FILE]...
20782 -h, --help print this help, then exit
20783 -V, --version print version number, then exit
20784 -d, --debug don't remove temporary files
20785 --recheck update $as_me by reconfiguring in the same conditions
20786 --file=FILE[:TEMPLATE]
20787 instantiate the configuration file FILE
20788 --header=FILE[:TEMPLATE]
20789 instantiate the configuration header FILE
20791 Configuration files:
20794 Configuration headers:
20797 Configuration commands:
20800 Report bugs to <dickey@invisible-island.net>."
20803 cat >>$CONFIG_STATUS <<EOF
20806 configured by $0, generated by GNU Autoconf 2.52.20181006,
20807 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
20809 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
20810 Free Software Foundation, Inc.
20811 This config.status script is free software; the Free Software Foundation
20812 gives unlimited permission to copy, distribute and modify it."
20817 cat >>$CONFIG_STATUS <<\EOF
20818 # If no file are specified by the user, then we need to provide default
20819 # value. By we need to know if files were specified by the user.
20825 ac_option=`expr "x$1" : 'x\([^=]*\)='`
20826 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
20828 set dummy "$ac_option" "$ac_optarg" ${1+"$@"}
20832 *) # This is not an option, so the user has probably given explicit
20834 ac_need_defaults=false;;
20838 # Handling of the options.
20840 cat >>$CONFIG_STATUS <<EOF
20841 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
20842 echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion"
20843 exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;;
20845 cat >>$CONFIG_STATUS <<\EOF
20846 --version | --vers* | -V )
20847 echo "$ac_cs_version"; exit 0 ;;
20849 # Conflict between --help and --header
20850 { { echo "$as_me:20850: error: ambiguous option: $1
20851 Try \`$0 --help' for more information." >&5
20852 echo "$as_me: error: ambiguous option: $1
20853 Try \`$0 --help' for more information." >&2;}
20854 { (exit 1); exit 1; }; };;
20855 --help | --hel | -h )
20856 echo "$ac_cs_usage"; exit 0 ;;
20857 --debug | --d* | -d )
20859 --file | --fil | --fi | --f )
20861 CONFIG_FILES="$CONFIG_FILES $1"
20862 ac_need_defaults=false;;
20863 --header | --heade | --head | --hea )
20865 CONFIG_HEADERS="$CONFIG_HEADERS $1"
20866 ac_need_defaults=false;;
20868 # This is an error.
20869 -*) { { echo "$as_me:20869: error: unrecognized option: $1
20870 Try \`$0 --help' for more information." >&5
20871 echo "$as_me: error: unrecognized option: $1
20872 Try \`$0 --help' for more information." >&2;}
20873 { (exit 1); exit 1; }; } ;;
20875 *) ac_config_targets="$ac_config_targets $1" ;;
20884 ## ----------------------- ##
20885 ## Running config.status. ##
20886 ## ----------------------- ##
20888 This file was extended by $as_me 2.52.20181006, executed with
20889 CONFIG_FILES = $CONFIG_FILES
20890 CONFIG_HEADERS = $CONFIG_HEADERS
20891 CONFIG_LINKS = $CONFIG_LINKS
20892 CONFIG_COMMANDS = $CONFIG_COMMANDS
20893 > $ac_cs_invocation
20894 on `(hostname || uname -n) 2>/dev/null | sed 1q`
20899 cat >>$CONFIG_STATUS <<EOF
20901 # INIT-COMMANDS section.
20911 cat >>$CONFIG_STATUS <<\EOF
20912 for ac_config_target in $ac_config_targets
20914 case "$ac_config_target" in
20915 # Handling of arguments.
20916 "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
20917 "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
20918 "ncurses_cfg.h" ) CONFIG_HEADERS="$CONFIG_HEADERS ncurses_cfg.h:ncurses_tst.hin" ;;
20919 *) { { echo "$as_me:20919: error: invalid argument: $ac_config_target" >&5
20920 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
20921 { (exit 1); exit 1; }; };;
20925 # If the user did not use the arguments to specify the items to instantiate,
20926 # then the envvar interface is used. Set only those that are not.
20927 # We use the long form for the default assignment because of an extremely
20928 # bizarre bug on SunOS 4.1.3.
20929 if $ac_need_defaults; then
20930 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
20931 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
20932 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
20935 # Create a temporary directory, and hook for its removal unless debugging.
20938 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
20939 trap '{ (exit 1); exit 1; }' 1 2 13 15
20942 # Create a (secure) tmp directory for tmp files.
20945 tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` &&
20946 test -n "$tmp" && test -d "$tmp"
20949 tmp=$TMPDIR/cs$$-$RANDOM
20950 (umask 077 && mkdir $tmp)
20953 echo "$me: cannot create a temporary directory in $TMPDIR" >&2
20954 { (exit 1); exit 1; }
20959 cat >>$CONFIG_STATUS <<EOF
20962 # CONFIG_FILES section.
20965 # No need to generate the scripts if there are no CONFIG_FILES.
20966 # This happens for instance when ./config.status config.h
20967 if test -n "\$CONFIG_FILES"; then
20968 # Protect against being on the right side of a sed subst in config.status.
20969 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
20970 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
20971 s,@SHELL@,$SHELL,;t t
20972 s,@exec_prefix@,$exec_prefix,;t t
20973 s,@prefix@,$prefix,;t t
20974 s,@program_transform_name@,$program_transform_name,;t t
20975 s,@bindir@,$bindir,;t t
20976 s,@sbindir@,$sbindir,;t t
20977 s,@libexecdir@,$libexecdir,;t t
20978 s,@datarootdir@,$datarootdir,;t t
20979 s,@datadir@,$datadir,;t t
20980 s,@sysconfdir@,$sysconfdir,;t t
20981 s,@sharedstatedir@,$sharedstatedir,;t t
20982 s,@localstatedir@,$localstatedir,;t t
20983 s,@runstatedir@,$runstatedir,;t t
20984 s,@libdir@,$libdir,;t t
20985 s,@includedir@,$includedir,;t t
20986 s,@oldincludedir@,$oldincludedir,;t t
20987 s,@infodir@,$infodir,;t t
20988 s,@mandir@,$mandir,;t t
20989 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
20990 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
20991 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
20992 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
20993 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
20994 s,@build_alias@,$build_alias,;t t
20995 s,@host_alias@,$host_alias,;t t
20996 s,@target_alias@,$target_alias,;t t
20997 s,@ECHO_C@,$ECHO_C,;t t
20998 s,@ECHO_N@,$ECHO_N,;t t
20999 s,@ECHO_T@,$ECHO_T,;t t
21000 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
21001 s,@DEFS@,$DEFS,;t t
21002 s,@LIBS@,$LIBS,;t t
21003 s,@build@,$build,;t t
21004 s,@build_cpu@,$build_cpu,;t t
21005 s,@build_vendor@,$build_vendor,;t t
21006 s,@build_os@,$build_os,;t t
21007 s,@host@,$host,;t t
21008 s,@host_cpu@,$host_cpu,;t t
21009 s,@host_vendor@,$host_vendor,;t t
21010 s,@host_os@,$host_os,;t t
21011 s,@SET_MAKE@,$SET_MAKE,;t t
21013 s,@CFLAGS@,$CFLAGS,;t t
21014 s,@LDFLAGS@,$LDFLAGS,;t t
21015 s,@CPPFLAGS@,$CPPFLAGS,;t t
21016 s,@ac_ct_CC@,$ac_ct_CC,;t t
21017 s,@EXEEXT@,$EXEEXT,;t t
21018 s,@OBJEXT@,$OBJEXT,;t t
21019 s,@EXTRA_CPPFLAGS@,$EXTRA_CPPFLAGS,;t t
21022 s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
21023 s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
21024 s,@INSTALL_DATA@,$INSTALL_DATA,;t t
21025 s,@INSTALL_OPT_S@,$INSTALL_OPT_S,;t t
21026 s,@INSTALL_OPT_O@,$INSTALL_OPT_O,;t t
21027 s,@LINT@,$LINT,;t t
21028 s,@LINT_OPTS@,$LINT_OPTS,;t t
21029 s,@CTAGS@,$CTAGS,;t t
21030 s,@ETAGS@,$ETAGS,;t t
21031 s,@MAKE_LOWER_TAGS@,$MAKE_LOWER_TAGS,;t t
21032 s,@MAKE_UPPER_TAGS@,$MAKE_UPPER_TAGS,;t t
21033 s,@MATH_LIB@,$MATH_LIB,;t t
21034 s,@top_builddir@,$top_builddir,;t t
21035 s,@CC_G_OPT@,$CC_G_OPT,;t t
21036 s,@CC_SHARED_OPTS@,$CC_SHARED_OPTS,;t t
21037 s,@DFT_DEP_SUFFIX@,$DFT_DEP_SUFFIX,;t t
21038 s,@DFT_OBJ_SUBDIR@,$DFT_OBJ_SUBDIR,;t t
21039 s,@DFT_UPR_MODEL@,$DFT_UPR_MODEL,;t t
21041 s,@LDFLAGS_SHARED@,$LDFLAGS_SHARED,;t t
21042 s,@LDFLAGS_STATIC@,$LDFLAGS_STATIC,;t t
21043 s,@LD_MODEL@,$LD_MODEL,;t t
21044 s,@LD_SHARED_OPTS@,$LD_SHARED_OPTS,;t t
21045 s,@LIBTOOL@,$LIBTOOL,;t t
21046 s,@LIBTOOL_OPTS@,$LIBTOOL_OPTS,;t t
21047 s,@LIB_CLEAN@,$LIB_CLEAN,;t t
21048 s,@LIB_COMPILE@,$LIB_COMPILE,;t t
21049 s,@LIB_LINK@,$LIB_LINK,;t t
21050 s,@LINK_TESTS@,$LINK_TESTS,;t t
21051 s,@LOCAL_LDFLAGS@,$LOCAL_LDFLAGS,;t t
21052 s,@PACKAGE@,$PACKAGE,;t t
21053 s,@PTHREAD@,$PTHREAD,;t t
21054 s,@TEST_ARGS@,$TEST_ARGS,;t t
21055 s,@TEST_DEPS@,$TEST_DEPS,;t t
21056 s,@TEST_LIBS@,$TEST_LIBS,;t t
21057 s,@TINFO_LDFLAGS@,$TINFO_LDFLAGS,;t t
21058 s,@TINFO_LIBS@,$TINFO_LIBS,;t t
21059 s,@cf_cv_abi_version@,$cf_cv_abi_version,;t t
21060 s,@cf_cv_rel_version@,$cf_cv_rel_version,;t t
21061 s,@includesubdir@,$includesubdir,;t t
21062 s,@PKG_CONFIG@,$PKG_CONFIG,;t t
21063 s,@ac_pt_PKG_CONFIG@,$ac_pt_PKG_CONFIG,;t t
21064 s,@ECHO_LT@,$ECHO_LT,;t t
21065 s,@ECHO_LD@,$ECHO_LD,;t t
21066 s,@RULE_CC@,$RULE_CC,;t t
21067 s,@SHOW_CC@,$SHOW_CC,;t t
21068 s,@ECHO_CC@,$ECHO_CC,;t t
21069 s,@NCURSES_WRAP_PREFIX@,$NCURSES_WRAP_PREFIX,;t t
21070 s,@NCURSES_CONFIG@,$NCURSES_CONFIG,;t t
21071 s,@ac_ct_NCURSES_CONFIG@,$ac_ct_NCURSES_CONFIG,;t t
21072 s,@X_CFLAGS@,$X_CFLAGS,;t t
21073 s,@X_PRE_LIBS@,$X_PRE_LIBS,;t t
21074 s,@X_LIBS@,$X_LIBS,;t t
21075 s,@X_EXTRA_LIBS@,$X_EXTRA_LIBS,;t t
21076 s,@XCURSES_CONFIG@,$XCURSES_CONFIG,;t t
21077 s,@ac_ct_XCURSES_CONFIG@,$ac_ct_XCURSES_CONFIG,;t t
21078 s,@RGB_PATH@,$RGB_PATH,;t t
21079 s,@no_x11_rgb@,$no_x11_rgb,;t t
21080 s,@EXTRA_CFLAGS@,$EXTRA_CFLAGS,;t t
21081 s,@cf_ldd_prog@,$cf_ldd_prog,;t t
21082 s,@EXTRA_LDFLAGS@,$EXTRA_LDFLAGS,;t t
21087 cat >>$CONFIG_STATUS <<\EOF
21088 # Split the substitutions into bite-sized pieces for seds with
21089 # small command number limits, like on Digital OSF/1 and HP-UX.
21090 ac_max_sed_lines=48
21091 ac_sed_frag=1 # Number of current file.
21092 ac_beg=1 # First line for current file.
21093 ac_end=$ac_max_sed_lines # Line after last line for current file.
21096 while $ac_more_lines; do
21097 if test $ac_beg -gt 1; then
21098 sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
21100 sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
21102 if test ! -s $tmp/subs.frag; then
21103 ac_more_lines=false
21105 # The purpose of the label and of the branching condition is to
21106 # speed up the sed processing (if there are no `@' at all, there
21107 # is no need to browse any of the substitutions).
21108 # These are the two extra sed commands mentioned above.
21110 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
21111 # It is possible to make a multiline substitution using escaped newlines.
21112 # Ensure that we do not split the substitution between script fragments.
21114 ac_END=`expr $ac_end + $ac_max_sed_lines`
21115 sed "1,${ac_BEG}d; ${ac_END}p; q" $tmp/subs.sed >$tmp/subs.next
21116 if test -s $tmp/subs.next; then
21117 grep '^s,@[^@,][^@,]*@,.*\\$' $tmp/subs.next >$tmp/subs.edit
21118 if test ! -s $tmp/subs.edit; then
21119 grep "^s,@[^@,][^@,]*@,.*,;t t$" $tmp/subs.next >$tmp/subs.edit
21120 if test ! -s $tmp/subs.edit; then
21121 if test $ac_beg -gt 1; then
21122 ac_end=`expr $ac_end - 1`
21129 if test -z "$ac_sed_cmds"; then
21130 ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
21132 ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
21134 ac_sed_frag=`expr $ac_sed_frag + 1`
21136 ac_end=`expr $ac_end + $ac_max_sed_lines`
21139 if test -z "$ac_sed_cmds"; then
21142 fi # test -n "$CONFIG_FILES"
21145 cat >>$CONFIG_STATUS <<\EOF
21146 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
21147 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
21149 - | *:- | *:-:* ) # input from stdin
21151 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
21152 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
21153 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
21154 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
21155 * ) ac_file_in=$ac_file.in ;;
21158 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
21159 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
21160 X"$ac_file" : 'X\(//\)[^/]' \| \
21161 X"$ac_file" : 'X\(//\)$' \| \
21162 X"$ac_file" : 'X\(/\)' \| \
21163 . : '\(.\)' 2>/dev/null ||
21165 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
21166 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
21167 /^X\(\/\/\)$/{ s//\1/; q; }
21168 /^X\(\/\).*/{ s//\1/; q; }
21170 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
21171 { case "$ac_dir" in
21172 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
21176 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
21177 case $as_mkdir_dir in
21178 # Skip DOS drivespec
21179 ?:) as_incr_dir=$as_mkdir_dir ;;
21181 as_incr_dir=$as_incr_dir/$as_mkdir_dir
21182 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
21187 ac_dir_suffix="/`echo $ac_dir|sed 's,^\./,,'`"
21188 # A "../" for each directory in $ac_dir_suffix.
21189 ac_dots=`echo "$ac_dir_suffix" | sed 's,/[^/]*,../,g'`
21191 ac_dir_suffix= ac_dots=
21196 if test -z "$ac_dots"; then
21199 ac_top_srcdir=`echo $ac_dots | sed 's,/$,,'`
21201 [\\/]* | ?:[\\/]* )
21202 ac_srcdir=$srcdir$ac_dir_suffix;
21203 ac_top_srcdir=$srcdir ;;
21204 *) # Relative path.
21205 ac_srcdir=$ac_dots$srcdir$ac_dir_suffix
21206 ac_top_srcdir=$ac_dots$srcdir ;;
21210 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
21211 *) ac_INSTALL=$ac_dots$INSTALL ;;
21214 if test x"$ac_file" != x-; then
21215 { echo "$as_me:21215: creating $ac_file" >&5
21216 echo "$as_me: creating $ac_file" >&6;}
21219 # Let's still pretend it is `configure' which instantiates (i.e., don't
21220 # use $as_me), people would be surprised to read:
21221 # /* config.h. Generated automatically by config.status. */
21222 configure_input="Generated automatically from `echo $ac_file_in |
21223 sed 's,.*/,,'` by configure."
21225 # First look for the input files in the build tree, otherwise in the
21227 ac_file_inputs=`IFS=:
21228 for f in $ac_file_in; do
21230 -) echo $tmp/stdin ;;
21232 # Absolute (can't be DOS-style, as IFS=:)
21233 test -f "$f" || { { echo "$as_me:21233: error: cannot find input file: $f" >&5
21234 echo "$as_me: error: cannot find input file: $f" >&2;}
21235 { (exit 1); exit 1; }; }
21238 if test -f "$f"; then
21241 elif test -f "$srcdir/$f"; then
21246 { { echo "$as_me:21246: error: cannot find input file: $f" >&5
21247 echo "$as_me: error: cannot find input file: $f" >&2;}
21248 { (exit 1); exit 1; }; }
21251 done` || { (exit 1); exit 1; }
21253 cat >>$CONFIG_STATUS <<\EOF
21254 ac_warn_datarootdir=no
21255 if test x"$ac_file" != x-; then
21256 for ac_item in $ac_file_inputs
21258 ac_seen=`grep '@\(datadir\|mandir\|infodir\)@' $ac_item`
21259 if test -n "$ac_seen"; then
21260 ac_used=`grep '@datarootdir@' $ac_item`
21261 if test -z "$ac_used"; then
21262 { echo "$as_me:21262: WARNING: datarootdir was used implicitly but not set:
21264 echo "$as_me: WARNING: datarootdir was used implicitly but not set:
21266 ac_warn_datarootdir=yes
21269 ac_seen=`grep '${datarootdir}' $ac_item`
21270 if test -n "$ac_seen"; then
21271 { echo "$as_me:21271: WARNING: datarootdir was used explicitly but not set:
21273 echo "$as_me: WARNING: datarootdir was used explicitly but not set:
21275 ac_warn_datarootdir=yes
21280 if test "x$ac_warn_datarootdir" = xyes; then
21281 ac_sed_cmds="$ac_sed_cmds | sed -e 's,@datarootdir@,\${prefix}/share,g' -e 's,\${datarootdir},\${prefix}/share,g'"
21285 cat >>$CONFIG_STATUS <<EOF
21289 cat >>$CONFIG_STATUS <<\EOF
21291 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
21292 s,@configure_input@,$configure_input,;t t
21293 s,@srcdir@,$ac_srcdir,;t t
21294 s,@top_srcdir@,$ac_top_srcdir,;t t
21295 s,@INSTALL@,$ac_INSTALL,;t t
21296 " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
21298 if test x"$ac_file" != x-; then
21299 cp $tmp/out $ac_file
21301 for ac_name in prefix exec_prefix datarootdir
21303 ac_seen=`fgrep -n '${'$ac_name'[:=].*}' $ac_file`
21304 if test -n "$ac_seen"; then
21305 ac_init=`egrep '[ ]*'$ac_name'[ ]*=' $ac_file`
21306 if test -z "$ac_init"; then
21307 ac_seen=`echo "$ac_seen" |sed -e 's,^,'$ac_file':,'`
21308 { echo "$as_me:21308: WARNING: Variable $ac_name is used but was not set:
21310 echo "$as_me: WARNING: Variable $ac_name is used but was not set:
21315 egrep -n '@[a-z_][a-z_0-9]+@' $ac_file >$tmp/out
21316 egrep -n '@[A-Z_][A-Z_0-9]+@' $ac_file >>$tmp/out
21317 if test -s $tmp/out; then
21318 ac_seen=`sed -e 's,^,'$ac_file':,' < $tmp/out`
21319 { echo "$as_me:21319: WARNING: Some variables may not be substituted:
21321 echo "$as_me: WARNING: Some variables may not be substituted:
21331 cat >>$CONFIG_STATUS <<\EOF
21334 # CONFIG_HEADER section.
21337 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
21338 # NAME is the cpp macro being defined and VALUE is the value it is being given.
21340 # ac_d sets the value in "#define NAME VALUE" lines.
21341 ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
21342 ac_dB='[ ].*$,\1#\2'
21345 # ac_i turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
21346 ac_iA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
21347 ac_iB='\([ ]\),\1#\2define\3'
21350 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
21351 ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
21352 ac_uB='$,\1#\2define\3'
21356 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
21357 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
21359 - | *:- | *:-:* ) # input from stdin
21361 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
21362 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
21363 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
21364 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
21365 * ) ac_file_in=$ac_file.in ;;
21368 test x"$ac_file" != x- && { echo "$as_me:21368: creating $ac_file" >&5
21369 echo "$as_me: creating $ac_file" >&6;}
21371 # First look for the input files in the build tree, otherwise in the
21373 ac_file_inputs=`IFS=:
21374 for f in $ac_file_in; do
21376 -) echo $tmp/stdin ;;
21378 # Absolute (can't be DOS-style, as IFS=:)
21379 test -f "$f" || { { echo "$as_me:21379: error: cannot find input file: $f" >&5
21380 echo "$as_me: error: cannot find input file: $f" >&2;}
21381 { (exit 1); exit 1; }; }
21384 if test -f "$f"; then
21387 elif test -f "$srcdir/$f"; then
21392 { { echo "$as_me:21392: error: cannot find input file: $f" >&5
21393 echo "$as_me: error: cannot find input file: $f" >&2;}
21394 { (exit 1); exit 1; }; }
21397 done` || { (exit 1); exit 1; }
21398 # Remove the trailing spaces.
21399 sed 's/[ ]*$//' $ac_file_inputs >$tmp/in
21403 # Transform confdefs.h into a list of #define's. We won't use it as a sed
21404 # script, but as data to insert where we see @DEFS@. We expect AC_SAVE_DEFS to
21405 # be either 'cat' or 'sort'.
21406 cat confdefs.h | uniq >conftest.vals
21408 # Break up conftest.vals because some shells have a limit on
21409 # the size of here documents, and old seds have small limits too.
21411 rm -f conftest.tail
21412 echo ' rm -f conftest.frag' >> $CONFIG_STATUS
21413 while grep . conftest.vals >/dev/null
21415 # Write chunks of a limited-size here document to conftest.frag.
21416 echo ' cat >> conftest.frag <<CEOF' >> $CONFIG_STATUS
21417 sed ${ac_max_here_lines}q conftest.vals | sed -e 's/#ifdef.*/#if 0/' >> $CONFIG_STATUS
21418 echo 'CEOF' >> $CONFIG_STATUS
21419 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
21420 rm -f conftest.vals
21421 mv conftest.tail conftest.vals
21423 rm -f conftest.vals
21425 # Run sed to substitute the contents of conftest.frag into $tmp/in at the
21427 echo ' cat >> conftest.edit <<CEOF
21428 /@DEFS@/r conftest.frag
21431 sed -f conftest.edit $tmp/in > $tmp/out
21433 mv $tmp/out $tmp/in
21434 rm -f conftest.edit conftest.frag
21435 ' >> $CONFIG_STATUS
21437 cat >>$CONFIG_STATUS <<\EOF
21438 # Let's still pretend it is `configure' which instantiates (i.e., don't
21439 # use $as_me), people would be surprised to read:
21440 # /* config.h. Generated automatically by config.status. */
21441 if test x"$ac_file" = x-; then
21442 echo "/* Generated automatically by configure. */" >$tmp/config.h
21444 echo "/* $ac_file. Generated automatically by configure. */" >$tmp/config.h
21446 cat $tmp/in >>$tmp/config.h
21448 if test x"$ac_file" != x-; then
21449 if cmp -s $ac_file $tmp/config.h 2>/dev/null; then
21450 { echo "$as_me:21450: $ac_file is unchanged" >&5
21451 echo "$as_me: $ac_file is unchanged" >&6;}
21453 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
21454 X"$ac_file" : 'X\(//\)[^/]' \| \
21455 X"$ac_file" : 'X\(//\)$' \| \
21456 X"$ac_file" : 'X\(/\)' \| \
21457 . : '\(.\)' 2>/dev/null ||
21459 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
21460 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
21461 /^X\(\/\/\)$/{ s//\1/; q; }
21462 /^X\(\/\).*/{ s//\1/; q; }
21464 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
21465 { case "$ac_dir" in
21466 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
21470 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
21471 case $as_mkdir_dir in
21472 # Skip DOS drivespec
21473 ?:) as_incr_dir=$as_mkdir_dir ;;
21475 as_incr_dir=$as_incr_dir/$as_mkdir_dir
21476 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
21483 mv $tmp/config.h $ac_file
21487 rm -f $tmp/config.h
21491 cat >>$CONFIG_STATUS <<\EOF
21493 # CONFIG_COMMANDS section.
21495 for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
21496 ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
21497 ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
21504 if test ! -d $srcdir/$cf_dir; then
21506 elif test -f $srcdir/$cf_dir/programs; then
21507 $AWK -f $srcdir/mk-test.awk INSTALL=yes ECHO_LINK="$ECHO_LD" $srcdir/$cf_dir/programs >>$cf_dir/Makefile
21511 cat >>Makefile <<TEST_EOF
21513 # These rules are generated so we do not rely on suffix rules, which do not
21514 # work consistently for different make-programs (the '\$(MODEL)/' confuses
21515 # some, and the '\$x' confuses others).
21518 LIST=`sed -e 's/[ ].*//' -e '/^[#@]/d' $srcdir/modules`
21521 cat >>Makefile <<TEST_EOF
21523 \$(MODEL)/$N.o : \$(srcdir)/$N.c \\
21524 \$(srcdir)/test.priv.h \\
21527 $ECHO_CC\$(CC) -c \$(CFLAGS_DEFAULT) -DMODULE_NAME="$N" \$(srcdir)/$N.c
21531 if test -f ../config.guess && test -f ../config.sub
21533 cat >>Makefile <<TEST_EOF
21535 # if we used CF_INHERIT for getting these files, we can remove them
21537 rm -f config.guess config.sub
21545 cat >>$CONFIG_STATUS <<\EOF
21547 { (exit 0); exit 0; }
21549 chmod +x $CONFIG_STATUS
21550 ac_clean_files=$ac_clean_files_save
21552 # configure is writing to config.log, and then calls config.status.
21553 # config.status does its own redirection, appending to config.log.
21554 # Unfortunately, on DOS this fails, as config.log is still kept open
21555 # by configure, so config.status won't be able to write to it; its
21556 # output is simply discarded. So we exec the FD to /dev/null,
21557 # effectively closing config.log, so it can be properly (re)opened and
21558 # appended to by config.status. When coming back to configure, we
21559 # need to make the FD available again.
21560 if test "$no_create" != yes; then
21563 $SHELL $CONFIG_STATUS || ac_cs_success=false
21565 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
21566 # would make configure fail if this is the last instruction.
21567 $ac_cs_success || { (exit 1); exit 1; }