2 # From configure.in Revision: 1.83 .
3 # Guess values for system-dependent variables and create Makefiles.
4 # Generated by Autoconf 2.52.20210509.
6 # Copyright 2003-2020,2021 Thomas E. Dickey
7 # Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
8 # Free Software Foundation, Inc.
9 # This configure script is free software; the Free Software Foundation
10 # gives unlimited permission to copy, distribute and modify it.
12 # Avoid depending upon Character Ranges.
13 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
14 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
15 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
16 as_cr_digits='0123456789'
17 as_cr_alnum=$as_cr_Letters$as_cr_digits
19 # Sed expression to map a string onto a valid variable name.
20 as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
22 # Sed expression to map a string onto a valid CPP name.
23 as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
25 # Be Bourne compatible
26 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
29 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
33 # Name of the executable.
34 as_me=`echo "$0" |sed 's,.*[\\/],,'`
36 if expr a : '\(a\)' >/dev/null 2>&1; then
42 rm -f conf$$ conf$$.exe conf$$.file
44 if ln -s conf$$.file conf$$ 2>/dev/null; then
45 # We could just check for DJGPP; but this test a) works b) is more generic
46 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
47 if test -f conf$$.exe; then
48 # Don't use ln at all; we don't have any links
53 elif ln conf$$.file conf$$ 2>/dev/null; then
58 rm -f conf$$ conf$$.exe conf$$.file
60 as_executable_p="test -f"
62 # Support unset when possible.
63 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
70 $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
71 $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
72 $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
73 $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
74 $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
75 $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
76 $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
77 $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
80 # We need space, tab and new line, in precisely that order.
86 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
89 # hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
90 # so uname gets run too.
91 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
98 ac_default_prefix=/usr/local
103 SHELL=${CONFIG_SHELL-/bin/sh}
105 # Maximum number of lines to put in a shell here document.
106 # This variable seems obsolete. It should probably be removed, and
107 # only ac_max_sed_lines should be used.
108 : "${ac_max_here_lines=38}"
110 ac_unique_file="gen/gen.c"
111 # Factoring default headers for most tests.
112 ac_includes_default="\
115 # include <sys/types.h>
118 # include <sys/stat.h>
129 # if !STDC_HEADERS && HAVE_MEMORY_H
135 # include <strings.h>
138 # include <inttypes.h>
148 # Initialize some variables set by options.
150 ac_init_version=false
151 # The variables have the same names as the options, with
152 # dashes changed to underlines.
160 program_transform_name=s,x,x,
168 # Installation directory options.
169 # These are left unexpanded so users can "make install exec_prefix=/foo"
170 # and all the variables that are supposed to be based on exec_prefix
171 # by default will actually change.
172 # Use braces instead of parens because sh, perl, etc. also accept them.
173 bindir='${exec_prefix}/bin'
174 sbindir='${exec_prefix}/sbin'
175 libexecdir='${exec_prefix}/libexec'
176 datarootdir='${prefix}/share'
177 datadir='${datarootdir}'
178 sysconfdir='${prefix}/etc'
179 sharedstatedir='${prefix}/com'
180 localstatedir='${prefix}/var'
181 runstatedir='${localstatedir}/run'
182 libdir='${exec_prefix}/lib'
183 includedir='${prefix}/include'
184 oldincludedir='/usr/include'
185 infodir='${datarootdir}/info'
186 mandir='${datarootdir}/man'
188 # Identity of this package.
198 # If the previous option needs an argument, assign it.
199 if test -n "$ac_prev"; then
200 eval "$ac_prev=\$ac_option"
205 ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
207 # Accept the important Cygnus configure options, so we can diagnose typos.
211 -bindir | --bindir | --bindi | --bind | --bin | --bi)
213 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
216 -build | --build | --buil | --bui | --bu)
217 ac_prev=build_alias ;;
218 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
219 build_alias=$ac_optarg ;;
221 -cache-file | --cache-file | --cache-fil | --cache-fi \
222 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
223 ac_prev=cache_file ;;
224 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
225 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
226 cache_file=$ac_optarg ;;
229 cache_file=config.cache ;;
231 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
233 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
235 datadir=$ac_optarg ;;
237 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
238 | --dataroo | --dataro | --datar)
239 ac_prev=datarootdir ;;
240 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
241 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
242 datarootdir=$ac_optarg ;;
244 -disable-* | --disable-*)
245 ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
246 # Reject names that are not valid shell variable names.
247 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
248 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
249 { (exit 1); exit 1; }; }
250 ac_feature=`echo "$ac_feature" | sed 's/-/_/g'`
251 eval "enable_$ac_feature=no" ;;
253 -enable-* | --enable-*)
254 ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
255 # Reject names that are not valid shell variable names.
256 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
257 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
258 { (exit 1); exit 1; }; }
259 ac_feature=`echo "$ac_feature" | sed 's/-/_/g'`
261 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
264 eval "enable_$ac_feature='$ac_optarg'" ;;
266 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
267 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
268 | --exec | --exe | --ex)
269 ac_prev=exec_prefix ;;
270 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
271 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
272 | --exec=* | --exe=* | --ex=*)
273 exec_prefix=$ac_optarg ;;
275 -gas | --gas | --ga | --g)
276 # Obsolete; use --with-gas.
279 -help | --help | --hel | --he | -h)
281 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
282 ac_init_help=recursive ;;
283 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
284 ac_init_help=short ;;
286 -host | --host | --hos | --ho)
287 ac_prev=host_alias ;;
288 -host=* | --host=* | --hos=* | --ho=*)
289 host_alias=$ac_optarg ;;
291 -includedir | --includedir | --includedi | --included | --include \
292 | --includ | --inclu | --incl | --inc)
293 ac_prev=includedir ;;
294 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
295 | --includ=* | --inclu=* | --incl=* | --inc=*)
296 includedir=$ac_optarg ;;
298 -infodir | --infodir | --infodi | --infod | --info | --inf)
300 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
301 infodir=$ac_optarg ;;
303 -libdir | --libdir | --libdi | --libd)
305 -libdir=* | --libdir=* | --libdi=* | --libd=*)
308 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
309 | --libexe | --libex | --libe)
310 ac_prev=libexecdir ;;
311 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
312 | --libexe=* | --libex=* | --libe=*)
313 libexecdir=$ac_optarg ;;
315 -localstatedir | --localstatedir | --localstatedi | --localstated \
316 | --localstate | --localstat | --localsta | --localst \
317 | --locals | --local | --loca | --loc | --lo)
318 ac_prev=localstatedir ;;
319 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
320 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
321 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
322 localstatedir=$ac_optarg ;;
324 -runstatedir | --runstatedir | --runstatedi | --runstated \
325 | --runstate | --runstat | --runsta | --runst \
326 | --runs | --run | --ru)
327 ac_prev=runstatedir ;;
328 -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \
329 | --runstate=* | --runstat=* | --runsta=* | --runst=* \
330 | --runs=* | --run=* | --ru=*)
331 runstatedir=$ac_optarg ;;
333 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
335 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
339 # Obsolete; use --without-fp.
342 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
346 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
347 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
350 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
351 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
352 | --oldin | --oldi | --old | --ol | --o)
353 ac_prev=oldincludedir ;;
354 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
355 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
356 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
357 oldincludedir=$ac_optarg ;;
359 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
361 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
364 -program-prefix | --program-prefix | --program-prefi | --program-pref \
365 | --program-pre | --program-pr | --program-p)
366 ac_prev=program_prefix ;;
367 -program-prefix=* | --program-prefix=* | --program-prefi=* \
368 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
369 program_prefix=$ac_optarg ;;
371 -program-suffix | --program-suffix | --program-suffi | --program-suff \
372 | --program-suf | --program-su | --program-s)
373 ac_prev=program_suffix ;;
374 -program-suffix=* | --program-suffix=* | --program-suffi=* \
375 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
376 program_suffix=$ac_optarg ;;
378 -program-transform-name | --program-transform-name \
379 | --program-transform-nam | --program-transform-na \
380 | --program-transform-n | --program-transform- \
381 | --program-transform | --program-transfor \
382 | --program-transfo | --program-transf \
383 | --program-trans | --program-tran \
384 | --progr-tra | --program-tr | --program-t)
385 ac_prev=program_transform_name ;;
386 -program-transform-name=* | --program-transform-name=* \
387 | --program-transform-nam=* | --program-transform-na=* \
388 | --program-transform-n=* | --program-transform-=* \
389 | --program-transform=* | --program-transfor=* \
390 | --program-transfo=* | --program-transf=* \
391 | --program-trans=* | --program-tran=* \
392 | --progr-tra=* | --program-tr=* | --program-t=*)
393 program_transform_name=$ac_optarg ;;
395 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
396 | -silent | --silent | --silen | --sile | --sil)
399 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
401 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
403 sbindir=$ac_optarg ;;
405 -sharedstatedir | --sharedstatedir | --sharedstatedi \
406 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
407 | --sharedst | --shareds | --shared | --share | --shar \
409 ac_prev=sharedstatedir ;;
410 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
411 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
412 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
414 sharedstatedir=$ac_optarg ;;
416 -site | --site | --sit)
418 -site=* | --site=* | --sit=*)
421 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
423 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
426 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
427 | --syscon | --sysco | --sysc | --sys | --sy)
428 ac_prev=sysconfdir ;;
429 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
430 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
431 sysconfdir=$ac_optarg ;;
433 -target | --target | --targe | --targ | --tar | --ta | --t)
434 ac_prev=target_alias ;;
435 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
436 target_alias=$ac_optarg ;;
438 -v | -verbose | --verbose | --verbos | --verbo | --verb)
441 -version | --version | --versio | --versi | --vers | -V)
445 ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
446 # Reject names that are not valid shell variable names.
447 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
448 { echo "$as_me: error: invalid package name: $ac_package" >&2
449 { (exit 1); exit 1; }; }
450 ac_package=`echo "$ac_package" | sed 's/-/_/g'`
452 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
455 eval "with_$ac_package='$ac_optarg'" ;;
457 -without-* | --without-*)
458 ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
459 # Reject names that are not valid shell variable names.
460 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
461 { echo "$as_me: error: invalid package name: $ac_package" >&2
462 { (exit 1); exit 1; }; }
463 ac_package=`echo "$ac_package" | sed 's/-/_/g'`
464 eval "with_$ac_package=no" ;;
467 # Obsolete; use --with-x.
470 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
471 | --x-incl | --x-inc | --x-in | --x-i)
472 ac_prev=x_includes ;;
473 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
474 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
475 x_includes=$ac_optarg ;;
477 -x-libraries | --x-libraries | --x-librarie | --x-librari \
478 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
479 ac_prev=x_libraries ;;
480 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
481 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
482 x_libraries=$ac_optarg ;;
484 -*) { echo "$as_me: error: unrecognized option: $ac_option
485 Try \`$0 --help' for more information." >&2
486 { (exit 1); exit 1; }; }
490 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
491 # Reject names that are not valid shell variable names.
492 expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
493 { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
494 { (exit 1); exit 1; }; }
495 ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
496 eval "$ac_envvar='$ac_optarg'"
497 export "$ac_envvar" ;;
500 # FIXME: should be removed in autoconf 3.0.
501 echo "$as_me: WARNING: you should use --build, --host, --target" >&2
502 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
503 echo "$as_me: WARNING: invalid host type: $ac_option" >&2
504 : "${build_alias=$ac_option}" "${host_alias=$ac_option}" "${target_alias=$ac_option}"
510 if test -n "$ac_prev"; then
511 ac_option=--`echo "$ac_prev" | sed 's/_/-/g'`
512 { echo "$as_me: error: missing argument to $ac_option" >&2
513 { (exit 1); exit 1; }; }
516 # Be sure to have absolute paths.
517 for ac_var in exec_prefix prefix
519 eval ac_val=$`echo "$ac_var"`
521 [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
522 *) { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
523 { (exit 1); exit 1; }; };;
527 # Be sure to have absolute paths.
528 for ac_var in bindir sbindir libexecdir datarootdir datadir sysconfdir sharedstatedir \
529 localstatedir libdir includedir oldincludedir infodir mandir
531 eval ac_val=$`echo "$ac_var"`
533 [\\/$]* | ?:[\\/]* ) ;;
534 *) { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
535 { (exit 1); exit 1; }; };;
539 # There might be people who depend on the old broken behavior: `$host'
540 # used to hold the argument of --host etc.
545 # FIXME: should be removed in autoconf 3.0.
546 if test "x$host_alias" != x; then
547 if test "x$build_alias" = x; then
548 cross_compiling=maybe
549 echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
550 If a cross compiler is detected then cross compile mode will be used." >&2
551 elif test "x$build_alias" != "x$host_alias"; then
557 test -n "$host_alias" && ac_tool_prefix=$host_alias-
559 test "$silent" = yes && exec 6>/dev/null
561 # Find the source files, if location was not specified.
562 if test -z "$srcdir"; then
563 ac_srcdir_defaulted=yes
564 # Try the directory containing this script, then its parent.
566 ac_confdir=`echo "$ac_prog" | sed 's%[\\/][^\\/][^\\/]*$%%'`
567 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
569 if test ! -r "$srcdir/$ac_unique_file"; then
573 ac_srcdir_defaulted=no
575 if test ! -r "$srcdir/$ac_unique_file"; then
576 if test "$ac_srcdir_defaulted" = yes; then
577 { echo "$as_me: error: cannot find sources in $ac_confdir or .." >&2
578 { (exit 1); exit 1; }; }
580 { echo "$as_me: error: cannot find sources in $srcdir" >&2
581 { (exit 1); exit 1; }; }
584 srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
585 ac_env_build_alias_set=${build_alias+set}
586 ac_env_build_alias_value=$build_alias
587 ac_cv_env_build_alias_set=${build_alias+set}
588 ac_cv_env_build_alias_value=$build_alias
589 ac_env_host_alias_set=${host_alias+set}
590 ac_env_host_alias_value=$host_alias
591 ac_cv_env_host_alias_set=${host_alias+set}
592 ac_cv_env_host_alias_value=$host_alias
593 ac_env_target_alias_set=${target_alias+set}
594 ac_env_target_alias_value=$target_alias
595 ac_cv_env_target_alias_set=${target_alias+set}
596 ac_cv_env_target_alias_value=$target_alias
597 ac_env_CC_set=${CC+set}
599 ac_cv_env_CC_set=${CC+set}
600 ac_cv_env_CC_value=$CC
601 ac_env_CFLAGS_set=${CFLAGS+set}
602 ac_env_CFLAGS_value=$CFLAGS
603 ac_cv_env_CFLAGS_set=${CFLAGS+set}
604 ac_cv_env_CFLAGS_value=$CFLAGS
605 ac_env_LDFLAGS_set=${LDFLAGS+set}
606 ac_env_LDFLAGS_value=$LDFLAGS
607 ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
608 ac_cv_env_LDFLAGS_value=$LDFLAGS
609 ac_env_CPPFLAGS_set=${CPPFLAGS+set}
610 ac_env_CPPFLAGS_value=$CPPFLAGS
611 ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
612 ac_cv_env_CPPFLAGS_value=$CPPFLAGS
613 ac_env_CPP_set=${CPP+set}
614 ac_env_CPP_value=$CPP
615 ac_cv_env_CPP_set=${CPP+set}
616 ac_cv_env_CPP_value=$CPP
619 # Report the --help message.
621 if test "$ac_init_help" = "long"; then
622 # Omit some internal or obsolete options to make the list less imposing.
623 # This message is too long to be a string in the A/UX 3.1 sh.
625 \`configure' configures this package to adapt to many kinds of systems.
627 Usage: $0 [OPTION]... [VAR=VALUE]...
629 To assign environment variables (e.g., CC, CFLAGS...), specify them as
630 VAR=VALUE. See below for descriptions of some of the useful variables.
632 Defaults for the options are specified in brackets.
635 -h, --help display this help and exit
636 --help=short display options specific to this package
637 --help=recursive display the short help of all the included packages
638 -V, --version display version information and exit
639 -q, --quiet, --silent do not print \`checking...' messages
640 --cache-file=FILE cache test results in FILE [disabled]
641 -C, --config-cache alias for \`--cache-file=config.cache'
642 -n, --no-create do not create output files
643 --srcdir=DIR find the sources in DIR [configure dir or \`..']
648 Installation directories:
649 --prefix=PREFIX install architecture-independent files in PREFIX
651 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
654 By default, \`make install' will install all the files in
655 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
656 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
657 for instance \`--prefix=\$HOME'.
659 For better control, use the options below.
661 Fine tuning of the installation directories:
662 --bindir=DIR user executables [EPREFIX/bin]
663 --sbindir=DIR system admin executables [EPREFIX/sbin]
664 --libexecdir=DIR program executables [EPREFIX/libexec]
665 --datarootdir=DIR read-only architecture-independent data [PREFIX/share]
666 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
667 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
668 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
669 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
670 --runstatedir=DIR extra definition of runtime data [LOCALSTATEDIR/run]
671 --libdir=DIR object code libraries [EPREFIX/lib]
672 --includedir=DIR C header files [PREFIX/include]
673 --oldincludedir=DIR C header files for non-gcc [/usr/include]
674 --infodir=DIR info documentation [DATAROOTDIR/info]
675 --mandir=DIR man documentation [DATAROOTDIR/man]
681 --program-prefix=PREFIX prepend PREFIX to installed program names
682 --program-suffix=SUFFIX append SUFFIX to installed program names
683 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
686 --build=BUILD configure for building on BUILD [guessed]
687 --host=HOST build programs to run on HOST [BUILD]
688 --target=TARGET configure for building compilers for TARGET [HOST]
692 if test -n "$ac_init_help"; then
697 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
698 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
701 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
702 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
705 --with-system-type=XXX test: override derived host system-type
706 --disable-stripping do not strip (debug info) installed executables
707 --with-pkg-config{=path} enable/disable use of pkg-config
708 --with-pkg-config-libdir=XXX use given directory for installing pc-files
709 --without-tests suppress build with test-programs
710 --enable-mixed-case tic should assume mixed-case filenames
711 --with-install-prefix prefixes actual install-location ($DESTDIR)
712 Build-Tools Needed to Compile Temporary Applications for Cross-compiling:
713 --with-build-cc=XXX the build C compiler ($BUILD_CC)
714 --with-build-cpp=XXX the build C preprocessor ($BUILD_CPP)
715 --with-build-cflags=XXX the build C compiler-flags ($BUILD_CFLAGS)
716 --with-build-cppflags=XXX the build C preprocessor-flags ($BUILD_CPPFLAGS)
717 --with-build-ldflags=XXX the build linker-flags ($BUILD_LDFLAGS)
718 --with-build-libs=XXX the build libraries (${BUILD_LIBS})
719 Options to Specify the Libraries Built/Used:
720 --with-shared generate shared C-objects (needed for --with-ada-sharedlib)
721 --with-curses-dir=DIR directory in which (n)curses is installed
722 --enable-widec compile with wide-char/UTF-8 code
723 --with-lib-prefix override library-prefix
724 --with-shlib-version=X Specify rel or abi version for shared libs
725 --enable-rpath-link link sample programs with rpath option
726 Fine-Tuning Your Configuration:
727 --enable-broken_linker compile with broken-linker support code
728 --disable-largefile omit support for large files
729 --with-rcs-ids compile-in RCS identifiers
731 --disable-ext-funcs disable function-extensions
732 --enable-const compile with extra/non-standard const
734 --without-develop disable development options
736 --with-pthread use POSIX thread library
737 --enable-weak-symbols enable weak-symbols for pthreads
738 --enable-reentrant compile with experimental reentrant code
739 --with-wrap-prefix=XXX override prefix used for public variables
740 Testing/development Options:
741 --disable-echo do not display "compiling" commands
742 --enable-warnings test: turn on gcc compiler warnings
743 --enable-stdnoreturn enable C11 _Noreturn feature for diagnostics
744 --enable-assertions test: turn on generation of assertion code
745 --enable-expanded test: generate functions for certain macros
746 --disable-macros test: use functions rather than macros
747 --with-trace test: add trace() function to all models of ncurses
748 --disable-gnat-projects test: disable GNAT projects even if usable
749 Ada95 Binding Options:
750 --with-ada-compiler=CMD specify Ada95 compiler command (default gnatmake)
751 --with-ada-include=DIR Ada includes are in DIR (default: PREFIX/share/ada/adainclude)
752 --with-ada-objects=DIR Ada objects are in DIR (default: PREFIX/lib/ada/adalib)
753 --with-ada-sharedlib=soname build shared-library (requires GNAT projects)
754 --with-ada-libname=XXX override default Ada library-name
756 Some influential environment variables:
757 CC C compiler command
758 CFLAGS C compiler flags
759 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
760 nonstandard directory <lib dir>
761 CPPFLAGS C/C++ preprocessor flags, e.g. -I<include dir> if you have
762 headers in a nonstandard directory <include dir>
765 Use these variables to override the choices made by `configure' or to help
766 it to find libraries and programs with nonstandard names/locations.
771 if test "$ac_init_help" = "recursive"; then
772 # If there are subdirs, report their specific --help.
774 for ac_subdir in : $ac_subdirs_all; do test "x$ac_subdir" = x: && continue
776 # A "../" for each directory in /$ac_subdir.
777 ac_dots=`echo "$ac_subdir" |
778 sed 's,^\./,,;s,[^/]$,&/,;s,[^/]*/,../,g'`
781 .) # No --srcdir option. We are building in place.
782 ac_sub_srcdir="$srcdir" ;;
783 [\\/]* | ?:[\\/]* ) # Absolute path.
784 ac_sub_srcdir="$srcdir/$ac_subdir" ;;
786 ac_sub_srcdir="$ac_dots$srcdir/$ac_subdir" ;;
789 # Check for guested configure; otherwise get Cygnus style configure.
790 if test -f "$ac_sub_srcdir/configure.gnu"; then
792 $SHELL "$ac_sub_srcdir/configure.gnu" --help=recursive
793 elif test -f "$ac_sub_srcdir/configure"; then
795 $SHELL "$ac_sub_srcdir/configure" --help=recursive
796 elif test -f "$ac_sub_srcdir/configure.ac" ||
797 test -f "$ac_sub_srcdir/configure.in"; then
799 "$ac_configure" --help
801 echo "$as_me: WARNING: no configuration information is in $ac_subdir" >&2
807 test -n "$ac_init_help" && exit 0
808 if "$ac_init_version"; then
811 Copyright 2003-2020,2021 Thomas E. Dickey
812 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
813 Free Software Foundation, Inc.
814 This configure script is free software; the Free Software Foundation
815 gives unlimited permission to copy, distribute and modify it.
821 This file contains any messages produced by compilers while
822 running configure, to aid debugging if configure makes a mistake.
824 It was created by $as_me, which was
825 generated by GNU Autoconf 2.52.20210509. Invocation command line was
836 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
837 uname -m = `(uname -m) 2>/dev/null || echo unknown`
838 uname -r = `(uname -r) 2>/dev/null || echo unknown`
839 uname -s = `(uname -s) 2>/dev/null || echo unknown`
840 uname -v = `(uname -v) 2>/dev/null || echo unknown`
842 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
843 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
845 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
846 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
847 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
848 hostinfo = `(hostinfo) 2>/dev/null || echo unknown`
849 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
850 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
851 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
865 # Keep a trace of the command line.
866 # Strip out --no-create and --no-recursion so they do not pile up.
867 # Also quote any args containing shell meta-characters.
873 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
874 | --no-cr | --no-c) ;;
875 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
876 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
877 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
878 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"`
879 ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
881 *) ac_configure_args="$ac_configure_args$ac_sep$ac_arg"
884 # Get rid of the leading space.
887 # When interrupted or exit'd, cleanup temporary files, and complete
888 # config.log. We remove comments because anyway the quotes in there
889 # would cause problems or look ugly.
891 # Save into config.log some information that might help in debugging.
893 echo "## ----------------- ##" >&5
894 echo "## Cache variables. ##" >&5
895 echo "## ----------------- ##" >&5
897 # The following way of writing the cache mishandles newlines in values,
900 case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
903 "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
904 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
908 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
912 sed "/^$/d" confdefs.h >conftest.log
913 if test -s conftest.log; then
915 echo "## ------------ ##" >&5
916 echo "## confdefs.h. ##" >&5
917 echo "## ------------ ##" >&5
922 test "$ac_signal" != 0 &&
923 echo "$as_me: caught signal $ac_signal" >&5
924 echo "$as_me: exit $exit_status" >&5
925 rm -rf conftest* confdefs* core core.* *.core conf$$* $ac_clean_files &&
928 for ac_signal in 1 2 13 15; do
929 trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' "$ac_signal"
933 # confdefs.h avoids OS command line length limits that DEFS can exceed.
934 rm -rf conftest* confdefs.h
935 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
938 # Let the site file select an alternate cache file if it wants to.
939 # Prefer explicitly selected file to automatically selected ones.
940 if test -z "$CONFIG_SITE"; then
941 if test "x$prefix" != xNONE; then
942 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
944 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
947 for ac_site_file in $CONFIG_SITE; do
948 if test -r "$ac_site_file"; then
949 { echo "$as_me:949: loading site script $ac_site_file" >&5
950 echo "$as_me: loading site script $ac_site_file" >&6;}
951 cat "$ac_site_file" >&5
956 if test -r "$cache_file"; then
957 # Some versions of bash will fail to source /dev/null (special
958 # files actually), so we avoid doing that.
959 if test -f "$cache_file"; then
960 { echo "$as_me:960: loading cache $cache_file" >&5
961 echo "$as_me: loading cache $cache_file" >&6;}
963 [\\/]* | ?:[\\/]* ) . $cache_file;;
968 { echo "$as_me:968: creating cache $cache_file" >&5
969 echo "$as_me: creating cache $cache_file" >&6;}
973 # Check that the precious variables saved in the cache have kept the same
975 ac_cache_corrupted=false
976 for ac_var in `(set) 2>&1 |
977 sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
978 eval ac_old_set=\$ac_cv_env_${ac_var}_set
979 eval ac_new_set=\$ac_env_${ac_var}_set
980 eval ac_old_val="\$ac_cv_env_${ac_var}_value"
981 eval ac_new_val="\$ac_env_${ac_var}_value"
982 case "$ac_old_set,$ac_new_set" in
984 { echo "$as_me:984: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
985 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
986 ac_cache_corrupted=: ;;
988 { echo "$as_me:988: error: \`$ac_var' was not set in the previous run" >&5
989 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
990 ac_cache_corrupted=: ;;
993 if test "x$ac_old_val" != "x$ac_new_val"; then
994 { echo "$as_me:994: error: \`$ac_var' has changed since the previous run:" >&5
995 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
996 { echo "$as_me:996: former value: $ac_old_val" >&5
997 echo "$as_me: former value: $ac_old_val" >&2;}
998 { echo "$as_me:998: current value: $ac_new_val" >&5
999 echo "$as_me: current value: $ac_new_val" >&2;}
1000 ac_cache_corrupted=:
1003 # Pass precious variables to config.status. It doesn't matter if
1004 # we pass some twice (in addition to the command line arguments).
1005 if test "$ac_new_set" = set; then
1006 case "$ac_new_val" in
1007 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1008 ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"`
1009 ac_configure_args="$ac_configure_args '$ac_arg'"
1011 *) ac_configure_args="$ac_configure_args $ac_var=$ac_new_val"
1016 if "$ac_cache_corrupted"; then
1017 { echo "$as_me:1017: error: changes in the environment can compromise the build" >&5
1018 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1019 { { echo "$as_me:1019: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1020 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1021 { (exit 1); exit 1; }; }
1025 ac_cpp='$CPP $CPPFLAGS'
1026 ac_compile='$CC -c $CFLAGS $CPPFLAGS "conftest.$ac_ext" >&5'
1027 ac_link='$CC -o "conftest$ac_exeext" $CFLAGS $CPPFLAGS $LDFLAGS "conftest.$ac_ext" $LIBS >&5'
1028 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1029 ac_main_return="return"
1031 case `echo "testing\c" 2>/dev/null; echo 1,2,3`,`echo -n testing 2>/dev/null; echo 1,2,3` in
1033 ECHO_C= # newlines do not sed ;-) only broken shells would use this case anyway
1045 echo "#! $SHELL" >conftest.sh
1046 echo "exit 0" >>conftest.sh
1047 chmod +x conftest.sh
1048 if { (echo "$as_me:1048: PATH=\".;.\"; conftest.sh") >&5
1049 (PATH=".;."; conftest.sh) 2>&5
1051 echo "$as_me:1051: \$? = $ac_status" >&5
1052 (exit "$ac_status"); }; then
1053 ac_path_separator=';'
1057 PATH_SEPARATOR="$ac_path_separator"
1060 ac_config_headers="$ac_config_headers include/ncurses_cfg.h:include/ncurses_cfg.hin"
1065 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
1066 if test -f "$ac_dir/install-sh"; then
1068 ac_install_sh="$ac_aux_dir/install-sh -c"
1070 elif test -f "$ac_dir/install.sh"; then
1072 ac_install_sh="$ac_aux_dir/install.sh -c"
1074 elif test -f "$ac_dir/shtool"; then
1076 ac_install_sh="$ac_aux_dir/shtool install -c"
1080 if test -z "$ac_aux_dir"; then
1081 { { echo "$as_me:1081: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
1082 echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
1083 { (exit 1); exit 1; }; }
1085 ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1086 ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1087 ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
1089 # Make sure we can run config.sub.
1090 $ac_config_sub sun4 >/dev/null 2>&1 ||
1091 { { echo "$as_me:1091: error: cannot run $ac_config_sub" >&5
1092 echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1093 { (exit 1); exit 1; }; }
1095 echo "$as_me:1095: checking build system type" >&5
1096 echo $ECHO_N "checking build system type... $ECHO_C" >&6
1097 if test "${ac_cv_build+set}" = set; then
1098 echo $ECHO_N "(cached) $ECHO_C" >&6
1100 ac_cv_build_alias=$build_alias
1101 test -z "$ac_cv_build_alias" &&
1102 ac_cv_build_alias=`$ac_config_guess`
1103 test -z "$ac_cv_build_alias" &&
1104 { { echo "$as_me:1104: error: cannot guess build type; you must specify one" >&5
1105 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1106 { (exit 1); exit 1; }; }
1107 ac_cv_build=`$ac_config_sub "$ac_cv_build_alias"` ||
1108 { { echo "$as_me:1108: error: $ac_config_sub $ac_cv_build_alias failed." >&5
1109 echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed." >&2;}
1110 { (exit 1); exit 1; }; }
1113 echo "$as_me:1113: result: $ac_cv_build" >&5
1114 echo "${ECHO_T}$ac_cv_build" >&6
1116 build_cpu=`echo "$ac_cv_build" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1117 build_vendor=`echo "$ac_cv_build" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1118 build_os=`echo "$ac_cv_build" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1120 echo "$as_me:1120: checking host system type" >&5
1121 echo $ECHO_N "checking host system type... $ECHO_C" >&6
1122 if test "${ac_cv_host+set}" = set; then
1123 echo $ECHO_N "(cached) $ECHO_C" >&6
1125 ac_cv_host_alias=$host_alias
1126 test -z "$ac_cv_host_alias" &&
1127 ac_cv_host_alias=$ac_cv_build_alias
1128 ac_cv_host=`$ac_config_sub "$ac_cv_host_alias"` ||
1129 { { echo "$as_me:1129: error: $ac_config_sub $ac_cv_host_alias failed" >&5
1130 echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1131 { (exit 1); exit 1; }; }
1134 echo "$as_me:1134: result: $ac_cv_host" >&5
1135 echo "${ECHO_T}$ac_cv_host" >&6
1137 host_cpu=`echo "$ac_cv_host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1138 host_vendor=`echo "$ac_cv_host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1139 host_os=`echo "$ac_cv_host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1141 if test -f "$srcdir/config.guess" || test -f "$ac_aux_dir/config.guess" ; then
1142 echo "$as_me:1142: checking target system type" >&5
1143 echo $ECHO_N "checking target system type... $ECHO_C" >&6
1144 if test "${ac_cv_target+set}" = set; then
1145 echo $ECHO_N "(cached) $ECHO_C" >&6
1147 ac_cv_target_alias=$target_alias
1148 test "x$ac_cv_target_alias" = "x" &&
1149 ac_cv_target_alias=$ac_cv_host_alias
1150 ac_cv_target=`$ac_config_sub "$ac_cv_target_alias"` ||
1151 { { echo "$as_me:1151: error: $ac_config_sub $ac_cv_target_alias failed" >&5
1152 echo "$as_me: error: $ac_config_sub $ac_cv_target_alias failed" >&2;}
1153 { (exit 1); exit 1; }; }
1156 echo "$as_me:1156: result: $ac_cv_target" >&5
1157 echo "${ECHO_T}$ac_cv_target" >&6
1158 target=$ac_cv_target
1159 target_cpu=`echo "$ac_cv_target" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1160 target_vendor=`echo "$ac_cv_target" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1161 target_os=`echo "$ac_cv_target" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1163 # The aliases save the names the user supplied, while $host etc.
1164 # will get canonicalized.
1165 test -n "$target_alias" &&
1166 test "$program_prefix$program_suffix$program_transform_name" = \
1168 program_prefix=${target_alias}-
1169 system_name="$host_os"
1171 system_name="`(uname -s -r) 2>/dev/null`"
1172 if test -z "$system_name" ; then
1173 system_name="`(hostname) 2>/dev/null`"
1176 test -n "$system_name" &&
1177 cat >>confdefs.h <<EOF
1178 #define SYSTEM_NAME "$system_name"
1181 if test "${cf_cv_system_name+set}" = set; then
1182 echo $ECHO_N "(cached) $ECHO_C" >&6
1184 cf_cv_system_name="$system_name"
1187 test -z "$system_name" && system_name="$cf_cv_system_name"
1188 test -n "$cf_cv_system_name" && echo "$as_me:1188: result: Configuring for $cf_cv_system_name" >&5
1189 echo "${ECHO_T}Configuring for $cf_cv_system_name" >&6
1191 if test ".$system_name" != ".$cf_cv_system_name" ; then
1192 echo "$as_me:1192: result: Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&5
1193 echo "${ECHO_T}Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&6
1194 { { echo "$as_me:1194: error: \"Please remove config.cache and try again.\"" >&5
1195 echo "$as_me: error: \"Please remove config.cache and try again.\"" >&2;}
1196 { (exit 1); exit 1; }; }
1199 # Check whether --with-system-type or --without-system-type was given.
1200 if test "${with_system_type+set}" = set; then
1201 withval="$with_system_type"
1202 { echo "$as_me:1202: WARNING: overriding system type to $withval" >&5
1203 echo "$as_me: WARNING: overriding system type to $withval" >&2;}
1204 cf_cv_system_name=$withval
1209 ### Save the given $CFLAGS to allow user-override.
1210 cf_user_CFLAGS="$CFLAGS"
1212 ### Default install-location
1213 for ac_prog in ggrep grep
1215 # Extract the first word of "$ac_prog", so it can be a program name with args.
1216 set dummy $ac_prog; ac_word=$2
1217 echo "$as_me:1217: checking for $ac_word" >&5
1218 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1219 if test "${ac_cv_prog_GREP+set}" = set; then
1220 echo $ECHO_N "(cached) $ECHO_C" >&6
1222 if test -n "$GREP"; then
1223 ac_cv_prog_GREP="$GREP" # Let the user override the test.
1225 ac_save_IFS=$IFS; IFS=$ac_path_separator
1227 for ac_dir in $ac_dummy; do
1229 test -z "$ac_dir" && ac_dir=.
1230 $as_executable_p "$ac_dir/$ac_word" || continue
1231 ac_cv_prog_GREP="$ac_prog"
1232 echo "$as_me:1232: found $ac_dir/$ac_word" >&5
1238 GREP=$ac_cv_prog_GREP
1239 if test -n "$GREP"; then
1240 echo "$as_me:1240: result: $GREP" >&5
1241 echo "${ECHO_T}$GREP" >&6
1243 echo "$as_me:1243: result: no" >&5
1244 echo "${ECHO_T}no" >&6
1247 test -n "$GREP" && break
1249 test -n "$GREP" || GREP=": "
1251 echo "$as_me:1251: checking for fgrep" >&5
1252 echo $ECHO_N "checking for fgrep... $ECHO_C" >&6
1253 if test "${ac_cv_path_FGREP+set}" = set; then
1254 echo $ECHO_N "(cached) $ECHO_C" >&6
1256 if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
1257 then ac_cv_path_FGREP="$GREP -F"
1259 for ac_prog in gfgrep fgrep
1261 # Extract the first word of "$ac_prog", so it can be a program name with args.
1262 set dummy $ac_prog; ac_word=$2
1263 echo "$as_me:1263: checking for $ac_word" >&5
1264 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1265 if test "${ac_cv_path_FGREP+set}" = set; then
1266 echo $ECHO_N "(cached) $ECHO_C" >&6
1270 ac_cv_path_FGREP="$FGREP" # Let the user override the test with a path.
1273 ac_save_IFS=$IFS; IFS=$ac_path_separator
1275 for ac_dir in $ac_dummy; do
1277 test -z "$ac_dir" && ac_dir=.
1278 if $as_executable_p "$ac_dir/$ac_word"; then
1279 ac_cv_path_FGREP="$ac_dir/$ac_word"
1280 echo "$as_me:1280: found $ac_dir/$ac_word" >&5
1288 FGREP=$ac_cv_path_FGREP
1290 if test -n "$FGREP"; then
1291 echo "$as_me:1291: result: $FGREP" >&5
1292 echo "${ECHO_T}$FGREP" >&6
1294 echo "$as_me:1294: result: no" >&5
1295 echo "${ECHO_T}no" >&6
1298 test -n "$FGREP" && break
1300 test -n "$FGREP" || FGREP=": "
1302 test "x$ac_cv_path_FGREP" = "x:" && { { echo "$as_me:1302: error: cannot find workable fgrep" >&5
1303 echo "$as_me: error: cannot find workable fgrep" >&2;}
1304 { (exit 1); exit 1; }; }
1307 echo "$as_me:1307: result: $ac_cv_path_FGREP" >&5
1308 echo "${ECHO_T}$ac_cv_path_FGREP" >&6
1309 FGREP="$ac_cv_path_FGREP"
1311 echo "$as_me:1311: checking for prefix" >&5
1312 echo $ECHO_N "checking for prefix... $ECHO_C" >&6
1313 if test "x$prefix" = "xNONE" ; then
1314 case "$cf_cv_system_name" in
1315 # non-vendor systems don't have a conflict
1316 (openbsd*|freebsd*|mirbsd*|linux*|cygwin*|msys*|k*bsd*-gnu|mingw*)
1319 (*) prefix=$ac_default_prefix
1323 echo "$as_me:1323: result: $prefix" >&5
1324 echo "${ECHO_T}$prefix" >&6
1326 if test "x$prefix" = "xNONE" ; then
1327 echo "$as_me:1327: checking for default include-directory" >&5
1328 echo $ECHO_N "checking for default include-directory... $ECHO_C" >&6
1329 test -n "$verbose" && echo 1>&6
1332 "$includedir/ncurses" \
1334 "$prefix/include/ncurses" \
1335 /usr/local/include \
1336 /usr/local/include/ncurses \
1338 /usr/include/ncurses
1340 cf_dir=`eval echo "$cf_symbol"`
1341 if test -f "$cf_dir/curses.h" ; then
1342 if ( ${FGREP-fgrep} NCURSES_VERSION "$cf_dir/curses.h" >/dev/null 2>&1 ) ; then
1343 includedir="$cf_symbol"
1344 test -n "$verbose" && echo $ECHO_N " found " 1>&6
1348 test -n "$verbose" && echo " tested $cf_dir" 1>&6
1350 echo "$as_me:1350: result: $includedir" >&5
1351 echo "${ECHO_T}$includedir" >&6
1354 ### Checks for programs.
1357 ac_cpp='$CPP $CPPFLAGS'
1358 ac_compile='$CC -c $CFLAGS $CPPFLAGS "conftest.$ac_ext" >&5'
1359 ac_link='$CC -o "conftest$ac_exeext" $CFLAGS $CPPFLAGS $LDFLAGS "conftest.$ac_ext" $LIBS >&5'
1360 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1361 ac_main_return="return"
1362 if test -n "$ac_tool_prefix"; then
1363 for ac_prog in gnatgcc gcc cc
1365 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
1366 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
1367 echo "$as_me:1367: checking for $ac_word" >&5
1368 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1369 if test "${ac_cv_prog_CC+set}" = set; then
1370 echo $ECHO_N "(cached) $ECHO_C" >&6
1372 if test -n "$CC"; then
1373 ac_cv_prog_CC="$CC" # Let the user override the test.
1375 ac_save_IFS=$IFS; IFS=$ac_path_separator
1377 for ac_dir in $ac_dummy; do
1379 test -z "$ac_dir" && ac_dir=.
1380 $as_executable_p "$ac_dir/$ac_word" || continue
1381 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
1382 echo "$as_me:1382: found $ac_dir/$ac_word" >&5
1389 if test -n "$CC"; then
1390 echo "$as_me:1390: result: $CC" >&5
1391 echo "${ECHO_T}$CC" >&6
1393 echo "$as_me:1393: result: no" >&5
1394 echo "${ECHO_T}no" >&6
1397 test -n "$CC" && break
1400 if test -z "$CC"; then
1402 for ac_prog in gnatgcc gcc cc
1404 # Extract the first word of "$ac_prog", so it can be a program name with args.
1405 set dummy $ac_prog; ac_word=$2
1406 echo "$as_me:1406: checking for $ac_word" >&5
1407 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1408 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1409 echo $ECHO_N "(cached) $ECHO_C" >&6
1411 if test -n "$ac_ct_CC"; then
1412 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1414 ac_save_IFS=$IFS; IFS=$ac_path_separator
1416 for ac_dir in $ac_dummy; do
1418 test -z "$ac_dir" && ac_dir=.
1419 $as_executable_p "$ac_dir/$ac_word" || continue
1420 ac_cv_prog_ac_ct_CC="$ac_prog"
1421 echo "$as_me:1421: found $ac_dir/$ac_word" >&5
1427 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1428 if test -n "$ac_ct_CC"; then
1429 echo "$as_me:1429: result: $ac_ct_CC" >&5
1430 echo "${ECHO_T}$ac_ct_CC" >&6
1432 echo "$as_me:1432: result: no" >&5
1433 echo "${ECHO_T}no" >&6
1436 test -n "$ac_ct_CC" && break
1442 test -z "$CC" && { { echo "$as_me:1442: error: no acceptable cc found in \$PATH" >&5
1443 echo "$as_me: error: no acceptable cc found in \$PATH" >&2;}
1444 { (exit 1); exit 1; }; }
1446 # Provide some information about the compiler.
1447 echo "$as_me:1447:" \
1448 "checking for C compiler version" >&5
1449 ac_compiler=`set X $ac_compile; echo "$2"`
1450 { (eval echo "$as_me:1450: \"$ac_compiler --version </dev/null >&5\"") >&5
1451 (eval $ac_compiler --version </dev/null >&5) 2>&5
1453 echo "$as_me:1453: \$? = $ac_status" >&5
1454 (exit "$ac_status"); }
1455 { (eval echo "$as_me:1455: \"$ac_compiler -v </dev/null >&5\"") >&5
1456 (eval $ac_compiler -v </dev/null >&5) 2>&5
1458 echo "$as_me:1458: \$? = $ac_status" >&5
1459 (exit "$ac_status"); }
1460 { (eval echo "$as_me:1460: \"$ac_compiler -V </dev/null >&5\"") >&5
1461 (eval $ac_compiler -V </dev/null >&5) 2>&5
1463 echo "$as_me:1463: \$? = $ac_status" >&5
1464 (exit "$ac_status"); }
1466 cat >"conftest.$ac_ext" <<_ACEOF
1467 #line 1467 "configure"
1468 #include "confdefs.h"
1478 ac_clean_files_save=$ac_clean_files
1479 ac_clean_files="$ac_clean_files a.out a.exe"
1480 # Try to create an executable without -o first, disregard a.out.
1481 # It will help us diagnose broken compilers, and finding out an intuition
1483 echo "$as_me:1483: checking for C compiler default output" >&5
1484 echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
1485 ac_link_default=`echo "$ac_link" | sed 's/ -o *"conftest[^"]*"//'`
1486 if { (eval echo "$as_me:1486: \"$ac_link_default\"") >&5
1487 (eval $ac_link_default) 2>&5
1489 echo "$as_me:1489: \$? = $ac_status" >&5
1490 (exit "$ac_status"); }; then
1491 # Find the output, starting from the most likely. This scheme is
1492 # not robust to junk in `.', hence go to wildcards (a.*) only as a last
1494 for ac_file in `ls a.exe conftest.exe 2>/dev/null;
1495 ls a.out conftest 2>/dev/null;
1496 ls a.* conftest.* 2>/dev/null`; do
1498 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1499 a.out ) # We found the default executable, but exeext='' is most
1502 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1503 # FIXME: I believe we export ac_cv_exeext for Libtool --akim.
1510 echo "$as_me: failed program was:" >&5
1511 cat "conftest.$ac_ext" >&5
1512 { { echo "$as_me:1512: error: C compiler cannot create executables" >&5
1513 echo "$as_me: error: C compiler cannot create executables" >&2;}
1514 { (exit 77); exit 77; }; }
1517 ac_exeext=$ac_cv_exeext
1518 echo "$as_me:1518: result: $ac_file" >&5
1519 echo "${ECHO_T}$ac_file" >&6
1521 # Check the compiler produces executables we can run. If not, either
1522 # the compiler is broken, or we cross compile.
1523 echo "$as_me:1523: checking whether the C compiler works" >&5
1524 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
1525 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
1526 # If not cross compiling, check that we can run a simple program.
1527 if test "$cross_compiling" != yes; then
1528 if { ac_try='./$ac_file'
1529 { (eval echo "$as_me:1529: \"$ac_try\"") >&5
1532 echo "$as_me:1532: \$? = $ac_status" >&5
1533 (exit "$ac_status"); }; }; then
1536 if test "$cross_compiling" = maybe; then
1539 { { echo "$as_me:1539: error: cannot run C compiled programs.
1540 If you meant to cross compile, use \`--host'." >&5
1541 echo "$as_me: error: cannot run C compiled programs.
1542 If you meant to cross compile, use \`--host'." >&2;}
1543 { (exit 1); exit 1; }; }
1547 echo "$as_me:1547: result: yes" >&5
1548 echo "${ECHO_T}yes" >&6
1550 rm -f a.out a.exe "conftest$ac_cv_exeext"
1551 ac_clean_files=$ac_clean_files_save
1552 # Check the compiler produces executables we can run. If not, either
1553 # the compiler is broken, or we cross compile.
1554 echo "$as_me:1554: checking whether we are cross compiling" >&5
1555 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
1556 echo "$as_me:1556: result: $cross_compiling" >&5
1557 echo "${ECHO_T}$cross_compiling" >&6
1559 echo "$as_me:1559: checking for executable suffix" >&5
1560 echo $ECHO_N "checking for executable suffix... $ECHO_C" >&6
1561 if { (eval echo "$as_me:1561: \"$ac_link\"") >&5
1562 (eval $ac_link) 2>&5
1564 echo "$as_me:1564: \$? = $ac_status" >&5
1565 (exit "$ac_status"); }; then
1566 # If both `conftest.exe' and `conftest' are `present' (well, observable)
1567 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
1568 # work properly (i.e., refer to `conftest.exe'), while it won't with
1570 for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do
1572 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1573 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1580 { { echo "$as_me:1580: error: cannot compute EXEEXT: cannot compile and link" >&5
1581 echo "$as_me: error: cannot compute EXEEXT: cannot compile and link" >&2;}
1582 { (exit 1); exit 1; }; }
1585 rm -f "conftest$ac_cv_exeext"
1586 echo "$as_me:1586: result: $ac_cv_exeext" >&5
1587 echo "${ECHO_T}$ac_cv_exeext" >&6
1589 rm -f "conftest.$ac_ext"
1590 EXEEXT=$ac_cv_exeext
1592 echo "$as_me:1592: checking for object suffix" >&5
1593 echo $ECHO_N "checking for object suffix... $ECHO_C" >&6
1594 if test "${ac_cv_objext+set}" = set; then
1595 echo $ECHO_N "(cached) $ECHO_C" >&6
1597 cat >"conftest.$ac_ext" <<_ACEOF
1598 #line 1598 "configure"
1599 #include "confdefs.h"
1609 rm -f conftest.o conftest.obj
1610 if { (eval echo "$as_me:1610: \"$ac_compile\"") >&5
1611 (eval $ac_compile) 2>&5
1613 echo "$as_me:1613: \$? = $ac_status" >&5
1614 (exit "$ac_status"); }; then
1615 for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
1617 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.map | *.inf ) ;;
1618 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
1623 echo "$as_me: failed program was:" >&5
1624 cat "conftest.$ac_ext" >&5
1625 { { echo "$as_me:1625: error: cannot compute OBJEXT: cannot compile" >&5
1626 echo "$as_me: error: cannot compute OBJEXT: cannot compile" >&2;}
1627 { (exit 1); exit 1; }; }
1630 rm -f "conftest.$ac_cv_objext" "conftest.$ac_ext"
1632 echo "$as_me:1632: result: $ac_cv_objext" >&5
1633 echo "${ECHO_T}$ac_cv_objext" >&6
1634 OBJEXT=$ac_cv_objext
1636 echo "$as_me:1636: checking whether we are using the GNU C compiler" >&5
1637 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
1638 if test "${ac_cv_c_compiler_gnu+set}" = set; then
1639 echo $ECHO_N "(cached) $ECHO_C" >&6
1641 cat >"conftest.$ac_ext" <<_ACEOF
1642 #line 1642 "configure"
1643 #include "confdefs.h"
1656 rm -f "conftest.$ac_objext"
1657 if { (eval echo "$as_me:1657: \"$ac_compile\"") >&5
1658 (eval $ac_compile) 2>&5
1660 echo "$as_me:1660: \$? = $ac_status" >&5
1661 (exit "$ac_status"); } &&
1662 { ac_try='test -s "conftest.$ac_objext"'
1663 { (eval echo "$as_me:1663: \"$ac_try\"") >&5
1666 echo "$as_me:1666: \$? = $ac_status" >&5
1667 (exit "$ac_status"); }; }; then
1670 echo "$as_me: failed program was:" >&5
1671 cat "conftest.$ac_ext" >&5
1674 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
1675 ac_cv_c_compiler_gnu=$ac_compiler_gnu
1678 echo "$as_me:1678: result: $ac_cv_c_compiler_gnu" >&5
1679 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
1680 GCC=`test $ac_compiler_gnu = yes && echo yes`
1681 ac_test_CFLAGS=${CFLAGS+set}
1682 ac_save_CFLAGS=$CFLAGS
1684 echo "$as_me:1684: checking whether $CC accepts -g" >&5
1685 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
1686 if test "${ac_cv_prog_cc_g+set}" = set; then
1687 echo $ECHO_N "(cached) $ECHO_C" >&6
1689 cat >"conftest.$ac_ext" <<_ACEOF
1690 #line 1690 "configure"
1691 #include "confdefs.h"
1701 rm -f "conftest.$ac_objext"
1702 if { (eval echo "$as_me:1702: \"$ac_compile\"") >&5
1703 (eval $ac_compile) 2>&5
1705 echo "$as_me:1705: \$? = $ac_status" >&5
1706 (exit "$ac_status"); } &&
1707 { ac_try='test -s "conftest.$ac_objext"'
1708 { (eval echo "$as_me:1708: \"$ac_try\"") >&5
1711 echo "$as_me:1711: \$? = $ac_status" >&5
1712 (exit "$ac_status"); }; }; then
1715 echo "$as_me: failed program was:" >&5
1716 cat "conftest.$ac_ext" >&5
1719 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
1721 echo "$as_me:1721: result: $ac_cv_prog_cc_g" >&5
1722 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
1723 if test "$ac_test_CFLAGS" = set; then
1724 CFLAGS=$ac_save_CFLAGS
1725 elif test $ac_cv_prog_cc_g = yes; then
1726 if test "$GCC" = yes; then
1732 if test "$GCC" = yes; then
1738 # Some people use a C++ compiler to compile C. Since we use `exit',
1739 # in C++ we need to declare it. In case someone uses the same compiler
1740 # for both compiling C and C++ we need to have the C++ compiler decide
1741 # the declaration of exit, since it's the most demanding environment.
1742 cat >"conftest.$ac_ext" <<_ACEOF
1747 rm -f "conftest.$ac_objext"
1748 if { (eval echo "$as_me:1748: \"$ac_compile\"") >&5
1749 (eval $ac_compile) 2>&5
1751 echo "$as_me:1751: \$? = $ac_status" >&5
1752 (exit "$ac_status"); } &&
1753 { ac_try='test -s "conftest.$ac_objext"'
1754 { (eval echo "$as_me:1754: \"$ac_try\"") >&5
1757 echo "$as_me:1757: \$? = $ac_status" >&5
1758 (exit "$ac_status"); }; }; then
1759 for ac_declaration in \
1761 '#include <stdlib.h>' \
1762 'extern "C" void std::exit (int) throw (); using std::exit;' \
1763 'extern "C" void std::exit (int); using std::exit;' \
1764 'extern "C" void exit (int) throw ();' \
1765 'extern "C" void exit (int);' \
1768 cat >"conftest.$ac_ext" <<_ACEOF
1769 #line 1769 "configure"
1770 #include "confdefs.h"
1781 rm -f "conftest.$ac_objext"
1782 if { (eval echo "$as_me:1782: \"$ac_compile\"") >&5
1783 (eval $ac_compile) 2>&5
1785 echo "$as_me:1785: \$? = $ac_status" >&5
1786 (exit "$ac_status"); } &&
1787 { ac_try='test -s "conftest.$ac_objext"'
1788 { (eval echo "$as_me:1788: \"$ac_try\"") >&5
1791 echo "$as_me:1791: \$? = $ac_status" >&5
1792 (exit "$ac_status"); }; }; then
1795 echo "$as_me: failed program was:" >&5
1796 cat "conftest.$ac_ext" >&5
1799 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
1800 cat >"conftest.$ac_ext" <<_ACEOF
1801 #line 1801 "configure"
1802 #include "confdefs.h"
1812 rm -f "conftest.$ac_objext"
1813 if { (eval echo "$as_me:1813: \"$ac_compile\"") >&5
1814 (eval $ac_compile) 2>&5
1816 echo "$as_me:1816: \$? = $ac_status" >&5
1817 (exit "$ac_status"); } &&
1818 { ac_try='test -s "conftest.$ac_objext"'
1819 { (eval echo "$as_me:1819: \"$ac_try\"") >&5
1822 echo "$as_me:1822: \$? = $ac_status" >&5
1823 (exit "$ac_status"); }; }; then
1826 echo "$as_me: failed program was:" >&5
1827 cat "conftest.$ac_ext" >&5
1829 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
1832 if test -n "$ac_declaration"; then
1833 echo '#ifdef __cplusplus' >>confdefs.h
1834 echo "$ac_declaration" >>confdefs.h
1835 echo '#endif' >>confdefs.h
1839 echo "$as_me: failed program was:" >&5
1840 cat "conftest.$ac_ext" >&5
1842 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
1844 ac_cpp='$CPP $CPPFLAGS'
1845 ac_compile='$CC -c $CFLAGS $CPPFLAGS "conftest.$ac_ext" >&5'
1846 ac_link='$CC -o "conftest$ac_exeext" $CFLAGS $CPPFLAGS $LDFLAGS "conftest.$ac_ext" $LIBS >&5'
1847 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1848 ac_main_return="return"
1851 if test "$GCC" = yes ; then
1852 echo "$as_me:1852: checking version of $CC" >&5
1853 echo $ECHO_N "checking version of $CC... $ECHO_C" >&6
1854 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.].*//'`"
1855 test -z "$GCC_VERSION" && GCC_VERSION=unknown
1856 echo "$as_me:1856: result: $GCC_VERSION" >&5
1857 echo "${ECHO_T}$GCC_VERSION" >&6
1862 if test "$GCC" = yes ; then
1865 echo "$as_me:1865: checking if this is really Intel C compiler" >&5
1866 echo $ECHO_N "checking if this is really Intel C compiler... $ECHO_C" >&6
1867 cf_save_CFLAGS="$CFLAGS"
1868 CFLAGS="$CFLAGS -no-gcc"
1869 cat >"conftest.$ac_ext" <<_ACEOF
1870 #line 1870 "configure"
1871 #include "confdefs.h"
1877 #ifdef __INTEL_COMPILER
1886 rm -f "conftest.$ac_objext"
1887 if { (eval echo "$as_me:1887: \"$ac_compile\"") >&5
1888 (eval $ac_compile) 2>&5
1890 echo "$as_me:1890: \$? = $ac_status" >&5
1891 (exit "$ac_status"); } &&
1892 { ac_try='test -s "conftest.$ac_objext"'
1893 { (eval echo "$as_me:1893: \"$ac_try\"") >&5
1896 echo "$as_me:1896: \$? = $ac_status" >&5
1897 (exit "$ac_status"); }; }; then
1899 cf_save_CFLAGS="$cf_save_CFLAGS -we147"
1902 echo "$as_me: failed program was:" >&5
1903 cat "conftest.$ac_ext" >&5
1905 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
1906 CFLAGS="$cf_save_CFLAGS"
1907 echo "$as_me:1907: result: $INTEL_COMPILER" >&5
1908 echo "${ECHO_T}$INTEL_COMPILER" >&6
1915 if test "$GCC" = yes ; then
1916 echo "$as_me:1916: checking if this is really Clang C compiler" >&5
1917 echo $ECHO_N "checking if this is really Clang C compiler... $ECHO_C" >&6
1918 cf_save_CFLAGS="$CFLAGS"
1919 cat >"conftest.$ac_ext" <<_ACEOF
1920 #line 1920 "configure"
1921 #include "confdefs.h"
1936 rm -f "conftest.$ac_objext"
1937 if { (eval echo "$as_me:1937: \"$ac_compile\"") >&5
1938 (eval $ac_compile) 2>&5
1940 echo "$as_me:1940: \$? = $ac_status" >&5
1941 (exit "$ac_status"); } &&
1942 { ac_try='test -s "conftest.$ac_objext"'
1943 { (eval echo "$as_me:1943: \"$ac_try\"") >&5
1946 echo "$as_me:1946: \$? = $ac_status" >&5
1947 (exit "$ac_status"); }; }; then
1951 echo "$as_me: failed program was:" >&5
1952 cat "conftest.$ac_ext" >&5
1954 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
1955 CFLAGS="$cf_save_CFLAGS"
1956 echo "$as_me:1956: result: $CLANG_COMPILER" >&5
1957 echo "${ECHO_T}$CLANG_COMPILER" >&6
1962 if test "x$CLANG_COMPILER" = "xyes" ; then
1964 (c[1-9][0-9]|*/c[1-9][0-9])
1965 { echo "$as_me:1965: WARNING: replacing broken compiler alias $CC" >&5
1966 echo "$as_me: WARNING: replacing broken compiler alias $CC" >&2;}
1967 CFLAGS="$CFLAGS -std=`echo "$CC" | sed -e 's%.*/%%'`"
1972 echo "$as_me:1972: checking version of $CC" >&5
1973 echo $ECHO_N "checking version of $CC... $ECHO_C" >&6
1974 CLANG_VERSION="`$CC --version 2>/dev/null | sed -e '2,$d' -e 's/^.*(CLANG[^)]*) //' -e 's/^.*(Debian[^)]*) //' -e 's/^[^0-9.]*//' -e 's/[^0-9.].*//'`"
1975 test -z "$CLANG_VERSION" && CLANG_VERSION=unknown
1976 echo "$as_me:1976: result: $CLANG_VERSION" >&5
1977 echo "${ECHO_T}$CLANG_VERSION" >&6
1979 for cf_clang_opt in \
1980 -Qunused-arguments \
1981 -Wno-error=implicit-function-declaration
1983 echo "$as_me:1983: checking if option $cf_clang_opt works" >&5
1984 echo $ECHO_N "checking if option $cf_clang_opt works... $ECHO_C" >&6
1985 cf_save_CFLAGS="$CFLAGS"
1986 CFLAGS="$CFLAGS $cf_clang_opt"
1987 cat >"conftest.$ac_ext" <<_ACEOF
1988 #line 1988 "configure"
1989 #include "confdefs.h"
1996 printf("hello!\\n");
2001 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
2002 if { (eval echo "$as_me:2002: \"$ac_link\"") >&5
2003 (eval $ac_link) 2>&5
2005 echo "$as_me:2005: \$? = $ac_status" >&5
2006 (exit "$ac_status"); } &&
2007 { ac_try='test -s "conftest$ac_exeext"'
2008 { (eval echo "$as_me:2008: \"$ac_try\"") >&5
2011 echo "$as_me:2011: \$? = $ac_status" >&5
2012 (exit "$ac_status"); }; }; then
2016 echo "$as_me: failed program was:" >&5
2017 cat "conftest.$ac_ext" >&5
2021 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
2022 echo "$as_me:2022: result: $cf_clang_optok" >&5
2023 echo "${ECHO_T}$cf_clang_optok" >&6
2024 CFLAGS="$cf_save_CFLAGS"
2025 if test "$cf_clang_optok" = yes; then
2026 test -n "$verbose" && echo " adding option $cf_clang_opt" 1>&6
2028 echo "${as_me:-configure}:2028: testing adding option $cf_clang_opt ..." 1>&5
2030 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
2031 CFLAGS="${CFLAGS}$cf_clang_opt"
2037 echo "$as_me:2037: checking for $CC option to accept ANSI C" >&5
2038 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
2039 if test "${ac_cv_prog_cc_stdc+set}" = set; then
2040 echo $ECHO_N "(cached) $ECHO_C" >&6
2042 ac_cv_prog_cc_stdc=no
2044 cat >"conftest.$ac_ext" <<_ACEOF
2045 #line 2045 "configure"
2046 #include "confdefs.h"
2049 #include <sys/types.h>
2050 #include <sys/stat.h>
2051 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
2052 struct buf { int x; };
2053 FILE * (*rcsopen) (struct buf *, struct stat *, int);
2054 static char *e (p, i)
2060 static char *f (char * (*g) (char **, int), char **p, ...)
2065 s = g (p, va_arg (v,int));
2069 int test (int i, double x);
2070 struct s1 {int (*f) (int a);};
2071 struct s2 {int (*f) (double a);};
2072 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
2078 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
2083 # Don't try gcc -ansi; that turns off useful extensions and
2084 # breaks some systems' header files.
2085 # AIX -qlanglvl=ansi
2086 # Ultrix and OSF/1 -std1
2087 # HP-UX 10.20 and later -Ae
2088 # HP-UX older versions -Aa -D_HPUX_SOURCE
2089 # SVR4 -Xc -D__EXTENSIONS__
2090 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
2092 CC="$ac_save_CC $ac_arg"
2093 rm -f "conftest.$ac_objext"
2094 if { (eval echo "$as_me:2094: \"$ac_compile\"") >&5
2095 (eval $ac_compile) 2>&5
2097 echo "$as_me:2097: \$? = $ac_status" >&5
2098 (exit "$ac_status"); } &&
2099 { ac_try='test -s "conftest.$ac_objext"'
2100 { (eval echo "$as_me:2100: \"$ac_try\"") >&5
2103 echo "$as_me:2103: \$? = $ac_status" >&5
2104 (exit "$ac_status"); }; }; then
2105 ac_cv_prog_cc_stdc=$ac_arg
2108 echo "$as_me: failed program was:" >&5
2109 cat "conftest.$ac_ext" >&5
2111 rm -f "conftest.$ac_objext"
2113 rm -f "conftest.$ac_ext" "conftest.$ac_objext"
2118 case "x$ac_cv_prog_cc_stdc" in
2120 echo "$as_me:2120: result: none needed" >&5
2121 echo "${ECHO_T}none needed" >&6 ;;
2123 echo "$as_me:2123: result: $ac_cv_prog_cc_stdc" >&5
2124 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
2125 CC="$CC $ac_cv_prog_cc_stdc" ;;
2128 # This should have been defined by AC_PROG_CC
2131 echo "$as_me:2131: checking \$CFLAGS variable" >&5
2132 echo $ECHO_N "checking \$CFLAGS variable... $ECHO_C" >&6
2135 echo "$as_me:2135: result: broken" >&5
2136 echo "${ECHO_T}broken" >&6
2137 { echo "$as_me:2137: WARNING: your environment uses the CFLAGS variable to hold CPPFLAGS options" >&5
2138 echo "$as_me: WARNING: your environment uses the CFLAGS variable to hold CPPFLAGS options" >&2;}
2141 for cf_arg in $cf_flags
2147 cf_new_extra_cppflags=
2149 for cf_add_cflags in $cf_arg
2151 case "$cf_fix_cppflags" in
2153 case "$cf_add_cflags" in
2154 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
2155 case "$cf_add_cflags" in
2157 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
2159 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2160 && test -z "${cf_tst_cflags}" \
2161 && cf_fix_cppflags=yes
2163 if test "$cf_fix_cppflags" = yes ; then
2165 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2166 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2169 elif test "${cf_tst_cflags}" = "\"'" ; then
2171 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2172 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2182 case "$cf_add_cflags" in
2184 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
2186 CPPFLAGS=`echo "$CPPFLAGS" | \
2187 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
2188 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
2193 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
2194 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
2201 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
2202 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
2209 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2210 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2212 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
2214 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2215 && test -z "${cf_tst_cflags}" \
2216 && cf_fix_cppflags=no
2221 if test -n "$cf_new_cflags" ; then
2223 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
2224 CFLAGS="${CFLAGS}$cf_new_cflags"
2228 if test -n "$cf_new_cppflags" ; then
2230 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
2231 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
2235 if test -n "$cf_new_extra_cppflags" ; then
2237 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
2238 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
2245 echo "$as_me:2245: result: ok" >&5
2246 echo "${ECHO_T}ok" >&6
2250 echo "$as_me:2250: checking \$CC variable" >&5
2251 echo $ECHO_N "checking \$CC variable... $ECHO_C" >&6
2254 echo "$as_me:2254: result: broken" >&5
2255 echo "${ECHO_T}broken" >&6
2256 { echo "$as_me:2256: WARNING: your environment uses the CC variable to hold CFLAGS/CPPFLAGS options" >&5
2257 echo "$as_me: WARNING: your environment uses the CC variable to hold CFLAGS/CPPFLAGS options" >&2;}
2259 cf_prog=`echo "$CC" | sed -e 's/ / /g' -e 's/[ ]* / /g' -e 's/[ ]*[ ]-[^ ].*//'`
2260 cf_flags=`echo "$CC" | ${AWK:-awk} -v prog="$cf_prog" '{ printf("%s", substr($0,1+length(prog))); }'`
2262 for cf_arg in $cf_flags
2270 cf_new_extra_cppflags=
2272 for cf_add_cflags in $cf_arg
2274 case "$cf_fix_cppflags" in
2276 case "$cf_add_cflags" in
2277 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
2278 case "$cf_add_cflags" in
2280 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
2282 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2283 && test -z "${cf_tst_cflags}" \
2284 && cf_fix_cppflags=yes
2286 if test "$cf_fix_cppflags" = yes ; then
2288 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2289 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2292 elif test "${cf_tst_cflags}" = "\"'" ; then
2294 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2295 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2305 case "$cf_add_cflags" in
2307 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
2309 CPPFLAGS=`echo "$CPPFLAGS" | \
2310 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
2311 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
2316 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
2317 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
2324 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
2325 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
2332 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2333 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2335 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
2337 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2338 && test -z "${cf_tst_cflags}" \
2339 && cf_fix_cppflags=no
2344 if test -n "$cf_new_cflags" ; then
2346 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
2347 CFLAGS="${CFLAGS}$cf_new_cflags"
2351 if test -n "$cf_new_cppflags" ; then
2353 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
2354 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
2358 if test -n "$cf_new_extra_cppflags" ; then
2360 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
2361 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
2371 test -n "$verbose" && echo " resulting CC: '$CC'" 1>&6
2373 echo "${as_me:-configure}:2373: testing resulting CC: '$CC' ..." 1>&5
2375 test -n "$verbose" && echo " resulting CFLAGS: '$CFLAGS'" 1>&6
2377 echo "${as_me:-configure}:2377: testing resulting CFLAGS: '$CFLAGS' ..." 1>&5
2379 test -n "$verbose" && echo " resulting CPPFLAGS: '$CPPFLAGS'" 1>&6
2381 echo "${as_me:-configure}:2381: testing resulting CPPFLAGS: '$CPPFLAGS' ..." 1>&5
2385 echo "$as_me:2385: result: ok" >&5
2386 echo "${ECHO_T}ok" >&6
2390 echo "$as_me:2390: checking for egrep" >&5
2391 echo $ECHO_N "checking for egrep... $ECHO_C" >&6
2392 if test "${ac_cv_path_EGREP+set}" = set; then
2393 echo $ECHO_N "(cached) $ECHO_C" >&6
2395 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
2396 then ac_cv_path_EGREP="$GREP -E"
2398 for ac_prog in gegrep egrep
2400 # Extract the first word of "$ac_prog", so it can be a program name with args.
2401 set dummy $ac_prog; ac_word=$2
2402 echo "$as_me:2402: checking for $ac_word" >&5
2403 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2404 if test "${ac_cv_path_EGREP+set}" = set; then
2405 echo $ECHO_N "(cached) $ECHO_C" >&6
2409 ac_cv_path_EGREP="$EGREP" # Let the user override the test with a path.
2412 ac_save_IFS=$IFS; IFS=$ac_path_separator
2414 for ac_dir in $ac_dummy; do
2416 test -z "$ac_dir" && ac_dir=.
2417 if $as_executable_p "$ac_dir/$ac_word"; then
2418 ac_cv_path_EGREP="$ac_dir/$ac_word"
2419 echo "$as_me:2419: found $ac_dir/$ac_word" >&5
2427 EGREP=$ac_cv_path_EGREP
2429 if test -n "$EGREP"; then
2430 echo "$as_me:2430: result: $EGREP" >&5
2431 echo "${ECHO_T}$EGREP" >&6
2433 echo "$as_me:2433: result: no" >&5
2434 echo "${ECHO_T}no" >&6
2437 test -n "$EGREP" && break
2439 test -n "$EGREP" || EGREP=": "
2441 test "x$ac_cv_path_EGREP" = "x:" && { { echo "$as_me:2441: error: cannot find workable egrep" >&5
2442 echo "$as_me: error: cannot find workable egrep" >&2;}
2443 { (exit 1); exit 1; }; }
2446 echo "$as_me:2446: result: $ac_cv_path_EGREP" >&5
2447 echo "${ECHO_T}$ac_cv_path_EGREP" >&6
2448 EGREP="$ac_cv_path_EGREP"
2451 ac_cpp='$CPP $CPPFLAGS'
2452 ac_compile='$CC -c $CFLAGS $CPPFLAGS "conftest.$ac_ext" >&5'
2453 ac_link='$CC -o "conftest$ac_exeext" $CFLAGS $CPPFLAGS $LDFLAGS "conftest.$ac_ext" $LIBS >&5'
2454 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2455 ac_main_return="return"
2456 echo "$as_me:2456: checking how to run the C preprocessor" >&5
2457 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
2458 # On Suns, sometimes $CPP names a directory.
2459 if test -n "$CPP" && test -d "$CPP"; then
2462 if test -z "$CPP"; then
2463 if test "${ac_cv_prog_CPP+set}" = set; then
2464 echo $ECHO_N "(cached) $ECHO_C" >&6
2466 # Double quotes because CPP needs to be expanded
2467 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
2470 for ac_c_preproc_warn_flag in '' yes
2472 # Use a header file that comes with gcc, so configuring glibc
2473 # with a fresh cross-compiler works.
2474 # On the NeXT, cc -E runs the code through the compiler's parser,
2475 # not just through cpp. "Syntax error" is here to catch this case.
2476 cat >"conftest.$ac_ext" <<_ACEOF
2477 #line 2477 "configure"
2478 #include "confdefs.h"
2482 if { (eval echo "$as_me:2482: \"$ac_cpp "conftest.$ac_ext"\"") >&5
2483 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
2485 $EGREP -v '^ *\+' conftest.er1 >conftest.err
2487 cat conftest.err >&5
2488 echo "$as_me:2488: \$? = $ac_status" >&5
2489 (exit "$ac_status"); } >/dev/null; then
2490 if test -s conftest.err; then
2491 ac_cpp_err=$ac_c_preproc_warn_flag
2498 if test -z "$ac_cpp_err"; then
2501 echo "$as_me: failed program was:" >&5
2502 cat "conftest.$ac_ext" >&5
2503 # Broken: fails on valid input.
2506 rm -f conftest.err "conftest.$ac_ext"
2508 # OK, works on sane cases. Now check whether non-existent headers
2509 # can be detected and how.
2510 cat >"conftest.$ac_ext" <<_ACEOF
2511 #line 2511 "configure"
2512 #include "confdefs.h"
2513 #include <ac_nonexistent.h>
2515 if { (eval echo "$as_me:2515: \"$ac_cpp "conftest.$ac_ext"\"") >&5
2516 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
2518 $EGREP -v '^ *\+' conftest.er1 >conftest.err
2520 cat conftest.err >&5
2521 echo "$as_me:2521: \$? = $ac_status" >&5
2522 (exit "$ac_status"); } >/dev/null; then
2523 if test -s conftest.err; then
2524 ac_cpp_err=$ac_c_preproc_warn_flag
2531 if test -z "$ac_cpp_err"; then
2532 # Broken: success on invalid input.
2535 echo "$as_me: failed program was:" >&5
2536 cat "conftest.$ac_ext" >&5
2537 # Passes both tests.
2541 rm -f conftest.err "conftest.$ac_ext"
2544 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2545 rm -f conftest.err "conftest.$ac_ext"
2546 if $ac_preproc_ok; then
2558 echo "$as_me:2558: result: $CPP" >&5
2559 echo "${ECHO_T}$CPP" >&6
2561 for ac_c_preproc_warn_flag in '' yes
2563 # Use a header file that comes with gcc, so configuring glibc
2564 # with a fresh cross-compiler works.
2565 # On the NeXT, cc -E runs the code through the compiler's parser,
2566 # not just through cpp. "Syntax error" is here to catch this case.
2567 cat >"conftest.$ac_ext" <<_ACEOF
2568 #line 2568 "configure"
2569 #include "confdefs.h"
2573 if { (eval echo "$as_me:2573: \"$ac_cpp "conftest.$ac_ext"\"") >&5
2574 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
2576 $EGREP -v '^ *\+' conftest.er1 >conftest.err
2578 cat conftest.err >&5
2579 echo "$as_me:2579: \$? = $ac_status" >&5
2580 (exit "$ac_status"); } >/dev/null; then
2581 if test -s conftest.err; then
2582 ac_cpp_err=$ac_c_preproc_warn_flag
2589 if test -z "$ac_cpp_err"; then
2592 echo "$as_me: failed program was:" >&5
2593 cat "conftest.$ac_ext" >&5
2594 # Broken: fails on valid input.
2597 rm -f conftest.err "conftest.$ac_ext"
2599 # OK, works on sane cases. Now check whether non-existent headers
2600 # can be detected and how.
2601 cat >"conftest.$ac_ext" <<_ACEOF
2602 #line 2602 "configure"
2603 #include "confdefs.h"
2604 #include <ac_nonexistent.h>
2606 if { (eval echo "$as_me:2606: \"$ac_cpp "conftest.$ac_ext"\"") >&5
2607 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
2609 $EGREP -v '^ *\+' conftest.er1 >conftest.err
2611 cat conftest.err >&5
2612 echo "$as_me:2612: \$? = $ac_status" >&5
2613 (exit "$ac_status"); } >/dev/null; then
2614 if test -s conftest.err; then
2615 ac_cpp_err=$ac_c_preproc_warn_flag
2622 if test -z "$ac_cpp_err"; then
2623 # Broken: success on invalid input.
2626 echo "$as_me: failed program was:" >&5
2627 cat "conftest.$ac_ext" >&5
2628 # Passes both tests.
2632 rm -f conftest.err "conftest.$ac_ext"
2635 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2636 rm -f conftest.err "conftest.$ac_ext"
2637 if $ac_preproc_ok; then
2640 { { echo "$as_me:2640: error: C preprocessor \"$CPP\" fails sanity check" >&5
2641 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;}
2642 { (exit 1); exit 1; }; }
2646 ac_cpp='$CPP $CPPFLAGS'
2647 ac_compile='$CC -c $CFLAGS $CPPFLAGS "conftest.$ac_ext" >&5'
2648 ac_link='$CC -o "conftest$ac_exeext" $CFLAGS $CPPFLAGS $LDFLAGS "conftest.$ac_ext" $LIBS >&5'
2649 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2650 ac_main_return="return"
2652 if test $ac_cv_c_compiler_gnu = yes; then
2653 echo "$as_me:2653: checking whether $CC needs -traditional" >&5
2654 echo $ECHO_N "checking whether $CC needs -traditional... $ECHO_C" >&6
2655 if test "${ac_cv_prog_gcc_traditional+set}" = set; then
2656 echo $ECHO_N "(cached) $ECHO_C" >&6
2658 ac_pattern="Autoconf.*'x'"
2659 cat >"conftest.$ac_ext" <<_ACEOF
2660 #line 2660 "configure"
2661 #include "confdefs.h"
2663 int Autoconf = TIOCGETP;
2665 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2666 $EGREP "$ac_pattern" >/dev/null 2>&1; then
2667 ac_cv_prog_gcc_traditional=yes
2669 ac_cv_prog_gcc_traditional=no
2673 if test $ac_cv_prog_gcc_traditional = no; then
2674 cat >"conftest.$ac_ext" <<_ACEOF
2675 #line 2675 "configure"
2676 #include "confdefs.h"
2678 int Autoconf = TCGETA;
2680 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2681 $EGREP "$ac_pattern" >/dev/null 2>&1; then
2682 ac_cv_prog_gcc_traditional=yes
2688 echo "$as_me:2688: result: $ac_cv_prog_gcc_traditional" >&5
2689 echo "${ECHO_T}$ac_cv_prog_gcc_traditional" >&6
2690 if test $ac_cv_prog_gcc_traditional = yes; then
2691 CC="$CC -traditional"
2695 echo "$as_me:2695: checking whether $CC understands -c and -o together" >&5
2696 echo $ECHO_N "checking whether $CC understands -c and -o together... $ECHO_C" >&6
2697 if test "${cf_cv_prog_CC_c_o+set}" = set; then
2698 echo $ECHO_N "(cached) $ECHO_C" >&6
2701 cat > conftest.$ac_ext <<CF_EOF
2704 ${cf_cv_main_return:-return}(0);
2707 # We do the test twice because some compilers refuse to overwrite an
2708 # existing .o file with -o, though they will create one.
2709 ac_try='$CC $CFLAGS $CPPFLAGS -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
2710 if { (eval echo "$as_me:2710: \"$ac_try\"") >&5
2713 echo "$as_me:2713: \$? = $ac_status" >&5
2714 (exit "$ac_status"); } &&
2715 test -f conftest2.$ac_objext && { (eval echo "$as_me:2715: \"$ac_try\"") >&5
2718 echo "$as_me:2718: \$? = $ac_status" >&5
2719 (exit "$ac_status"); };
2721 eval cf_cv_prog_CC_c_o=yes
2723 eval cf_cv_prog_CC_c_o=no
2728 if test "$cf_cv_prog_CC_c_o" = yes; then
2729 echo "$as_me:2729: result: yes" >&5
2730 echo "${ECHO_T}yes" >&6
2732 echo "$as_me:2732: result: no" >&5
2733 echo "${ECHO_T}no" >&6
2736 test "$program_prefix" != NONE &&
2737 program_transform_name="s,^,$program_prefix,;$program_transform_name"
2738 # Use a double $ so make ignores it.
2739 test "$program_suffix" != NONE &&
2740 program_transform_name="s,\$,$program_suffix,;$program_transform_name"
2741 # Double any \ or $. echo might interpret backslashes.
2742 # By default was `s,x,x', remove it if useless.
2743 cat <<\_ACEOF >conftest.sed
2744 s/[\\$]/&&/g;s/;s,x,x,$//
2746 program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
2749 for ac_prog in mawk gawk nawk awk
2751 # Extract the first word of "$ac_prog", so it can be a program name with args.
2752 set dummy $ac_prog; ac_word=$2
2753 echo "$as_me:2753: checking for $ac_word" >&5
2754 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2755 if test "${ac_cv_prog_AWK+set}" = set; then
2756 echo $ECHO_N "(cached) $ECHO_C" >&6
2758 if test -n "$AWK"; then
2759 ac_cv_prog_AWK="$AWK" # Let the user override the test.
2761 ac_save_IFS=$IFS; IFS=$ac_path_separator
2763 for ac_dir in $ac_dummy; do
2765 test -z "$ac_dir" && ac_dir=.
2766 $as_executable_p "$ac_dir/$ac_word" || continue
2767 ac_cv_prog_AWK="$ac_prog"
2768 echo "$as_me:2768: found $ac_dir/$ac_word" >&5
2775 if test -n "$AWK"; then
2776 echo "$as_me:2776: result: $AWK" >&5
2777 echo "${ECHO_T}$AWK" >&6
2779 echo "$as_me:2779: result: no" >&5
2780 echo "${ECHO_T}no" >&6
2783 test -n "$AWK" && break
2786 test -z "$AWK" && { { echo "$as_me:2786: error: No awk program found" >&5
2787 echo "$as_me: error: No awk program found" >&2;}
2788 { (exit 1); exit 1; }; }
2790 echo "$as_me:2790: checking for egrep" >&5
2791 echo $ECHO_N "checking for egrep... $ECHO_C" >&6
2792 if test "${ac_cv_prog_egrep+set}" = set; then
2793 echo $ECHO_N "(cached) $ECHO_C" >&6
2795 if echo a | (grep -E '(a|b)') >/dev/null 2>&1
2796 then ac_cv_prog_egrep='grep -E'
2797 else ac_cv_prog_egrep='egrep'
2800 echo "$as_me:2800: result: $ac_cv_prog_egrep" >&5
2801 echo "${ECHO_T}$ac_cv_prog_egrep" >&6
2802 EGREP=$ac_cv_prog_egrep
2804 test -z "$EGREP" && { { echo "$as_me:2804: error: No egrep program found" >&5
2805 echo "$as_me: error: No egrep program found" >&2;}
2806 { (exit 1); exit 1; }; }
2808 # Find a good install program. We prefer a C program (faster),
2809 # so one script is as good as another. But avoid the broken or
2810 # incompatible versions:
2811 # SysV /etc/install, /usr/sbin/install
2812 # SunOS /usr/etc/install
2813 # IRIX /sbin/install
2815 # AmigaOS /C/install, which installs bootblocks on floppy discs
2816 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
2817 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
2818 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
2819 # ./install, which can be erroneously created by make from ./install.sh.
2820 echo "$as_me:2820: checking for a BSD compatible install" >&5
2821 echo $ECHO_N "checking for a BSD compatible install... $ECHO_C" >&6
2822 if test -z "$INSTALL"; then
2823 if test "${ac_cv_path_install+set}" = set; then
2824 echo $ECHO_N "(cached) $ECHO_C" >&6
2826 ac_save_IFS=$IFS; IFS=$ac_path_separator
2827 for ac_dir in $PATH; do
2829 # Account for people who put trailing slashes in PATH elements.
2831 / | ./ | .// | /cC/* \
2832 | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* \
2835 # OSF1 and SCO ODT 3.0 have their own names for install.
2836 # Don't use installbsd from OSF since it installs stuff as root
2838 for ac_prog in ginstall scoinst install; do
2839 if $as_executable_p "$ac_dir/$ac_prog"; then
2840 if test $ac_prog = install &&
2841 grep dspmsg "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2842 # AIX install. It has an incompatible calling convention.
2844 elif test $ac_prog = install &&
2845 grep pwplus "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2846 # program-specific install script used by HP pwplus--don't use.
2849 ac_cv_path_install="$ac_dir/$ac_prog -c"
2859 if test "${ac_cv_path_install+set}" = set; then
2860 INSTALL=$ac_cv_path_install
2862 # As a last resort, use the slow shell script. We don't cache a
2863 # path for INSTALL within a source directory, because that will
2864 # break other packages using the cache if that directory is
2865 # removed, or if the path is relative.
2866 INSTALL=$ac_install_sh
2869 echo "$as_me:2869: result: $INSTALL" >&5
2870 echo "${ECHO_T}$INSTALL" >&6
2872 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
2873 # It thinks the first close brace ends the variable substitution.
2874 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
2876 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
2878 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
2880 echo "$as_me:2880: checking whether ln -s works" >&5
2881 echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
2883 if test "$LN_S" = "ln -s"; then
2884 echo "$as_me:2884: result: yes" >&5
2885 echo "${ECHO_T}yes" >&6
2887 echo "$as_me:2887: result: no, using $LN_S" >&5
2888 echo "${ECHO_T}no, using $LN_S" >&6
2891 echo "$as_me:2891: checking if $LN_S -f options work" >&5
2892 echo $ECHO_N "checking if $LN_S -f options work... $ECHO_C" >&6
2894 rm -f conf$$.src conf$$dst
2896 echo first >conf$$.src
2897 if $LN_S -f conf$$.src conf$$.dst 2>/dev/null; then
2902 rm -f conf$$.dst conf$$src
2903 echo "$as_me:2903: result: $cf_prog_ln_sf" >&5
2904 echo "${ECHO_T}$cf_prog_ln_sf" >&6
2906 test "$cf_prog_ln_sf" = yes && LN_S="$LN_S -f"
2908 # Find a good install program. We prefer a C program (faster),
2909 # so one script is as good as another. But avoid the broken or
2910 # incompatible versions:
2911 # SysV /etc/install, /usr/sbin/install
2912 # SunOS /usr/etc/install
2913 # IRIX /sbin/install
2915 # AmigaOS /C/install, which installs bootblocks on floppy discs
2916 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
2917 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
2918 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
2919 # ./install, which can be erroneously created by make from ./install.sh.
2920 echo "$as_me:2920: checking for a BSD compatible install" >&5
2921 echo $ECHO_N "checking for a BSD compatible install... $ECHO_C" >&6
2922 if test -z "$INSTALL"; then
2923 if test "${ac_cv_path_install+set}" = set; then
2924 echo $ECHO_N "(cached) $ECHO_C" >&6
2926 ac_save_IFS=$IFS; IFS=$ac_path_separator
2927 for ac_dir in $PATH; do
2929 # Account for people who put trailing slashes in PATH elements.
2931 / | ./ | .// | /cC/* \
2932 | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* \
2935 # OSF1 and SCO ODT 3.0 have their own names for install.
2936 # Don't use installbsd from OSF since it installs stuff as root
2938 for ac_prog in ginstall scoinst install; do
2939 if $as_executable_p "$ac_dir/$ac_prog"; then
2940 if test $ac_prog = install &&
2941 grep dspmsg "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2942 # AIX install. It has an incompatible calling convention.
2944 elif test $ac_prog = install &&
2945 grep pwplus "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2946 # program-specific install script used by HP pwplus--don't use.
2949 ac_cv_path_install="$ac_dir/$ac_prog -c"
2959 if test "${ac_cv_path_install+set}" = set; then
2960 INSTALL=$ac_cv_path_install
2962 # As a last resort, use the slow shell script. We don't cache a
2963 # path for INSTALL within a source directory, because that will
2964 # break other packages using the cache if that directory is
2965 # removed, or if the path is relative.
2966 INSTALL=$ac_install_sh
2969 echo "$as_me:2969: result: $INSTALL" >&5
2970 echo "${ECHO_T}$INSTALL" >&6
2972 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
2973 # It thinks the first close brace ends the variable substitution.
2974 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
2976 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
2978 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
2984 cf_dir=`echo "$INSTALL" | sed -e 's%/[^/]*$%%'`
2985 test -z "$cf_dir" && cf_dir=.
2986 INSTALL="`cd \"$cf_dir\" && pwd`"/"`echo "$INSTALL" | sed -e 's%^.*/%%'`"
2990 echo "$as_me:2990: checking if you want to install stripped executables" >&5
2991 echo $ECHO_N "checking if you want to install stripped executables... $ECHO_C" >&6
2993 # Check whether --enable-stripping or --disable-stripping was given.
2994 if test "${enable_stripping+set}" = set; then
2995 enableval="$enable_stripping"
2996 test "$enableval" != no && enableval=yes
2997 if test "$enableval" != "yes" ; then
3000 enable_stripping=yes
3004 enable_stripping=yes
3007 echo "$as_me:3007: result: $enable_stripping" >&5
3008 echo "${ECHO_T}$enable_stripping" >&6
3010 if test "$enable_stripping" = yes
3017 : "${INSTALL:=install}"
3018 echo "$as_me:3018: checking if install accepts -p option" >&5
3019 echo $ECHO_N "checking if install accepts -p option... $ECHO_C" >&6
3020 if test "${cf_cv_install_p+set}" = set; then
3021 echo $ECHO_N "(cached) $ECHO_C" >&6
3028 if $INSTALL -p conftest.in conftest.out 2>/dev/null
3030 if test -f conftest.out/conftest.in
3032 test conftest.in -nt conftest.out/conftest.in 2>conftest.err && \
3033 test conftest.out/conftest.in -nt conftest.in 2>conftest.err
3034 if test -s conftest.err
3049 echo "$as_me:3049: result: $cf_cv_install_p" >&5
3050 echo "${ECHO_T}$cf_cv_install_p" >&6
3052 echo "$as_me:3052: checking if install needs to be told about ownership" >&5
3053 echo $ECHO_N "checking if install needs to be told about ownership... $ECHO_C" >&6
3054 case `$ac_config_guess` in
3063 echo "$as_me:3063: result: $with_install_o" >&5
3064 echo "${ECHO_T}$with_install_o" >&6
3065 if test "x$with_install_o" = xyes
3067 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'`"
3072 echo "$as_me:3072: checking for long file names" >&5
3073 echo $ECHO_N "checking for long file names... $ECHO_C" >&6
3074 if test "${ac_cv_sys_long_file_names+set}" = set; then
3075 echo $ECHO_N "(cached) $ECHO_C" >&6
3077 ac_cv_sys_long_file_names=yes
3078 # Test for long file names in all the places we know might matter:
3079 # . the current directory, where building will happen
3080 # $prefix/lib where we will be installing things
3081 # $exec_prefix/lib likewise
3082 # eval it to expand exec_prefix.
3083 # $TMPDIR if set, where it might want to write temporary files
3084 # if $TMPDIR is not set:
3085 # /tmp where it might want to write temporary files
3088 if test -n "$TMPDIR" && test -d "$TMPDIR" && test -w "$TMPDIR"; then
3091 ac_tmpdirs='/tmp /var/tmp /usr/tmp'
3093 for ac_dir in . $ac_tmpdirs `eval echo "$prefix/lib" "$exec_prefix/lib"` ; do
3094 test -d "$ac_dir" || continue
3095 test -w "$ac_dir" || continue # It is less confusing to not echo anything here.
3096 ac_xdir=$ac_dir/cf$$
3097 (umask 077 && mkdir "$ac_xdir" 2>/dev/null) || continue
3098 ac_tf1=$ac_xdir/conftest9012345
3099 ac_tf2=$ac_xdir/conftest9012346
3100 (echo 1 >"$ac_tf1") 2>/dev/null
3101 (echo 2 >"$ac_tf2") 2>/dev/null
3102 ac_val=`cat "$ac_tf1" 2>/dev/null`
3103 if test ! -f "$ac_tf1" || test "$ac_val" != 1; then
3104 ac_cv_sys_long_file_names=no
3105 rm -rf "$ac_xdir" 2>/dev/null
3108 rm -rf "$ac_xdir" 2>/dev/null
3111 echo "$as_me:3111: result: $ac_cv_sys_long_file_names" >&5
3112 echo "${ECHO_T}$ac_cv_sys_long_file_names" >&6
3113 if test "$ac_cv_sys_long_file_names" = yes; then
3115 cat >>confdefs.h <<\EOF
3116 #define HAVE_LONG_FILE_NAMES 1
3121 # if we find pkg-config, check if we should install the ".pc" files.
3123 echo "$as_me:3123: checking if you want to use pkg-config" >&5
3124 echo $ECHO_N "checking if you want to use pkg-config... $ECHO_C" >&6
3126 # Check whether --with-pkg-config or --without-pkg-config was given.
3127 if test "${with_pkg_config+set}" = set; then
3128 withval="$with_pkg_config"
3129 cf_pkg_config=$withval
3133 echo "$as_me:3133: result: $cf_pkg_config" >&5
3134 echo "${ECHO_T}$cf_pkg_config" >&6
3136 case "$cf_pkg_config" in
3142 if test -n "$ac_tool_prefix"; then
3143 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
3144 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
3145 echo "$as_me:3145: checking for $ac_word" >&5
3146 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3147 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then
3148 echo $ECHO_N "(cached) $ECHO_C" >&6
3152 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
3155 ac_save_IFS=$IFS; IFS=$ac_path_separator
3157 for ac_dir in $ac_dummy; do
3159 test -z "$ac_dir" && ac_dir=.
3160 if $as_executable_p "$ac_dir/$ac_word"; then
3161 ac_cv_path_PKG_CONFIG="$ac_dir/$ac_word"
3162 echo "$as_me:3162: found $ac_dir/$ac_word" >&5
3170 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
3172 if test -n "$PKG_CONFIG"; then
3173 echo "$as_me:3173: result: $PKG_CONFIG" >&5
3174 echo "${ECHO_T}$PKG_CONFIG" >&6
3176 echo "$as_me:3176: result: no" >&5
3177 echo "${ECHO_T}no" >&6
3181 if test -z "$ac_cv_path_PKG_CONFIG"; then
3182 ac_pt_PKG_CONFIG=$PKG_CONFIG
3183 # Extract the first word of "pkg-config", so it can be a program name with args.
3184 set dummy pkg-config; ac_word=$2
3185 echo "$as_me:3185: checking for $ac_word" >&5
3186 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3187 if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then
3188 echo $ECHO_N "(cached) $ECHO_C" >&6
3190 case $ac_pt_PKG_CONFIG in
3192 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
3195 ac_save_IFS=$IFS; IFS=$ac_path_separator
3197 for ac_dir in $ac_dummy; do
3199 test -z "$ac_dir" && ac_dir=.
3200 if $as_executable_p "$ac_dir/$ac_word"; then
3201 ac_cv_path_ac_pt_PKG_CONFIG="$ac_dir/$ac_word"
3202 echo "$as_me:3202: found $ac_dir/$ac_word" >&5
3207 test -z "$ac_cv_path_ac_pt_PKG_CONFIG" && ac_cv_path_ac_pt_PKG_CONFIG="none"
3211 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
3213 if test -n "$ac_pt_PKG_CONFIG"; then
3214 echo "$as_me:3214: result: $ac_pt_PKG_CONFIG" >&5
3215 echo "${ECHO_T}$ac_pt_PKG_CONFIG" >&6
3217 echo "$as_me:3217: result: no" >&5
3218 echo "${ECHO_T}no" >&6
3221 PKG_CONFIG=$ac_pt_PKG_CONFIG
3223 PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
3232 test -z "$PKG_CONFIG" && PKG_CONFIG=none
3233 if test "$PKG_CONFIG" != none ; then
3235 if test "x$prefix" != xNONE; then
3236 cf_path_syntax="$prefix"
3238 cf_path_syntax="$ac_default_prefix"
3241 case ".$PKG_CONFIG" in
3246 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
3248 (.\$\{*prefix\}*|.\$\{*dir\}*)
3249 eval PKG_CONFIG="$PKG_CONFIG"
3250 case ".$PKG_CONFIG" in
3252 PKG_CONFIG=`echo "$PKG_CONFIG" | sed -e s%NONE%$cf_path_syntax%`
3257 PKG_CONFIG=`echo "$PKG_CONFIG" | sed -e s%NONE%$cf_path_syntax%`
3260 { { echo "$as_me:3260: error: expected a pathname, not \"$PKG_CONFIG\"" >&5
3261 echo "$as_me: error: expected a pathname, not \"$PKG_CONFIG\"" >&2;}
3262 { (exit 1); exit 1; }; }
3266 elif test "x$cf_pkg_config" != xno ; then
3267 { echo "$as_me:3267: WARNING: pkg-config is not installed" >&5
3268 echo "$as_me: WARNING: pkg-config is not installed" >&2;}
3271 case "$PKG_CONFIG" in
3273 echo "$as_me:3273: checking for pkg-config library directory" >&5
3274 echo $ECHO_N "checking for pkg-config library directory... $ECHO_C" >&6
3277 echo "$as_me:3277: checking for $PKG_CONFIG library directory" >&5
3278 echo $ECHO_N "checking for $PKG_CONFIG library directory... $ECHO_C" >&6
3282 PKG_CONFIG_LIBDIR=no
3284 # Check whether --with-pkg-config-libdir or --without-pkg-config-libdir was given.
3285 if test "${with_pkg_config_libdir+set}" = set; then
3286 withval="$with_pkg_config_libdir"
3287 PKG_CONFIG_LIBDIR=$withval
3289 test "x$PKG_CONFIG" != xnone && PKG_CONFIG_LIBDIR=yes
3292 case x$PKG_CONFIG_LIBDIR in
3296 # Look for the library directory using the same prefix as the executable
3297 if test "x$PKG_CONFIG" = xnone
3301 cf_path=`echo "$PKG_CONFIG" | sed -e 's,/[^/]*/[^/]*$,,'`
3304 # If you don't like using the default architecture, you have to specify the
3305 # intended library directory and corresponding compiler/linker options.
3307 # This case allows for Debian's 2014-flavor of multiarch, along with the
3308 # most common variations before that point. Some other variants spell the
3309 # directory differently, e.g., "pkg-config", and put it in unusual places.
3310 # pkg-config has always been poorly standardized, which is ironic...
3311 case x`(arch) 2>/dev/null` in
3314 $cf_path/lib/*64-linux-gnu \
3322 $cf_path/lib/*-linux-gnu \
3330 test -n "$verbose" && echo " list..." 1>&6
3332 echo "${as_me:-configure}:3332: testing list... ..." 1>&5
3334 for cf_config in $cf_search_path
3336 test -n "$verbose" && echo " checking $cf_config/pkgconfig" 1>&6
3338 echo "${as_me:-configure}:3338: testing checking $cf_config/pkgconfig ..." 1>&5
3340 if test -d "$cf_config/pkgconfig"
3342 PKG_CONFIG_LIBDIR=$cf_config/pkgconfig
3343 echo "$as_me:3343: checking done" >&5
3344 echo $ECHO_N "checking done... $ECHO_C" >&6
3353 if test "x$PKG_CONFIG_LIBDIR" != xno ; then
3354 echo "$as_me:3354: result: $PKG_CONFIG_LIBDIR" >&5
3355 echo "${ECHO_T}$PKG_CONFIG_LIBDIR" >&6
3358 echo "$as_me:3358: checking if you want to build test-programs" >&5
3359 echo $ECHO_N "checking if you want to build test-programs... $ECHO_C" >&6
3361 # Check whether --with-tests or --without-tests was given.
3362 if test "${with_tests+set}" = set; then
3363 withval="$with_tests"
3364 cf_with_tests=$withval
3368 echo "$as_me:3368: result: $cf_with_tests" >&5
3369 echo "${ECHO_T}$cf_with_tests" >&6
3371 echo "$as_me:3371: checking if we should assume mixed-case filenames" >&5
3372 echo $ECHO_N "checking if we should assume mixed-case filenames... $ECHO_C" >&6
3374 # Check whether --enable-mixed-case or --disable-mixed-case was given.
3375 if test "${enable_mixed_case+set}" = set; then
3376 enableval="$enable_mixed_case"
3377 enable_mixedcase=$enableval
3379 enable_mixedcase=auto
3381 echo "$as_me:3381: result: $enable_mixedcase" >&5
3382 echo "${ECHO_T}$enable_mixedcase" >&6
3383 if test "$enable_mixedcase" = "auto" ; then
3385 echo "$as_me:3385: checking if filesystem supports mixed-case filenames" >&5
3386 echo $ECHO_N "checking if filesystem supports mixed-case filenames... $ECHO_C" >&6
3387 if test "${cf_cv_mixedcase+set}" = set; then
3388 echo $ECHO_N "(cached) $ECHO_C" >&6
3391 if test "$cross_compiling" = yes ; then
3392 case "$target_alias" in
3393 (*-os2-emx*|*-msdosdjgpp*|*-cygwin*|*-msys*|*-mingw*|*-uwin*|darwin*)
3401 rm -f conftest CONFTEST
3403 if test -f CONFTEST ; then
3408 rm -f conftest CONFTEST
3412 echo "$as_me:3412: result: $cf_cv_mixedcase" >&5
3413 echo "${ECHO_T}$cf_cv_mixedcase" >&6
3414 test "$cf_cv_mixedcase" = yes &&
3415 cat >>confdefs.h <<\EOF
3416 #define MIXEDCASE_FILENAMES 1
3420 cf_cv_mixedcase=$enable_mixedcase
3421 if test "$enable_mixedcase" = "yes" ; then
3422 cat >>confdefs.h <<\EOF
3423 #define MIXEDCASE_FILENAMES 1
3429 # do this after mixed-case option (tags/TAGS is not as important as tic).
3430 echo "$as_me:3430: checking whether ${MAKE-make} sets \${MAKE}" >&5
3431 echo $ECHO_N "checking whether ${MAKE-make} sets \${MAKE}... $ECHO_C" >&6
3432 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,./+-,__p_,'`
3433 if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
3434 echo $ECHO_N "(cached) $ECHO_C" >&6
3436 cat >conftest.make <<\EOF
3438 @echo 'ac_maketemp="${MAKE}"'
3440 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
3441 eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
3442 if test -n "$ac_maketemp"; then
3443 eval ac_cv_prog_make_${ac_make}_set=yes
3445 eval ac_cv_prog_make_${ac_make}_set=no
3449 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
3450 echo "$as_me:3450: result: yes" >&5
3451 echo "${ECHO_T}yes" >&6
3454 echo "$as_me:3454: result: no" >&5
3455 echo "${ECHO_T}no" >&6
3456 SET_MAKE="MAKE=${MAKE-make}"
3459 echo "$as_me:3459: checking for \".PHONY\" make-support" >&5
3460 echo $ECHO_N "checking for \".PHONY\" make-support... $ECHO_C" >&6
3461 if test "${cf_cv_make_PHONY+set}" = set; then
3462 echo $ECHO_N "(cached) $ECHO_C" >&6
3467 mkdir conftest || exit 1
3469 cat >makefile <<'CF_EOF'
3473 @echo "** making $@ $(DATA)"
3475 @echo "** making $@ $(DATA)"
3477 @echo "** making $@ $(DATA)"
3480 @echo "** making $@ $(DATA)"
3483 for cf_data in 1 2 3
3485 ${MAKE:-make} always DATA=$cf_data
3486 ${MAKE:-make} once DATA=$cf_data
3487 ${MAKE:-make} -t always once
3488 if test -f always ; then
3489 echo "no (case 1)" > ../conftest.tmp
3490 elif test ! -f always.out ; then
3491 echo "no (case 2)" > ../conftest.tmp
3492 elif test ! -f once.out ; then
3493 echo "no (case 3)" > ../conftest.tmp
3494 elif ! cmp -s always.out once.out ; then
3495 echo "no (case 4)" > ../conftest.tmp
3496 diff always.out once.out
3498 cf_check="`cat always.out`"
3499 if test "x$cf_check" != "x$cf_data" ; then
3500 echo "no (case 5)" > ../conftest.tmp
3502 echo yes > ../conftest.tmp
3510 cf_cv_make_PHONY="`cat conftest.tmp`"
3514 echo "$as_me:3514: result: $cf_cv_make_PHONY" >&5
3515 echo "${ECHO_T}$cf_cv_make_PHONY" >&6
3518 test "x$cf_cv_make_PHONY" = xyes && MAKE_PHONY=
3519 test "x$cf_cv_make_PHONY" != xyes && MAKE_NO_PHONY=
3521 for ac_prog in exctags ctags
3523 # Extract the first word of "$ac_prog", so it can be a program name with args.
3524 set dummy $ac_prog; ac_word=$2
3525 echo "$as_me:3525: checking for $ac_word" >&5
3526 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3527 if test "${ac_cv_prog_CTAGS+set}" = set; then
3528 echo $ECHO_N "(cached) $ECHO_C" >&6
3530 if test -n "$CTAGS"; then
3531 ac_cv_prog_CTAGS="$CTAGS" # Let the user override the test.
3533 ac_save_IFS=$IFS; IFS=$ac_path_separator
3535 for ac_dir in $ac_dummy; do
3537 test -z "$ac_dir" && ac_dir=.
3538 $as_executable_p "$ac_dir/$ac_word" || continue
3539 ac_cv_prog_CTAGS="$ac_prog"
3540 echo "$as_me:3540: found $ac_dir/$ac_word" >&5
3546 CTAGS=$ac_cv_prog_CTAGS
3547 if test -n "$CTAGS"; then
3548 echo "$as_me:3548: result: $CTAGS" >&5
3549 echo "${ECHO_T}$CTAGS" >&6
3551 echo "$as_me:3551: result: no" >&5
3552 echo "${ECHO_T}no" >&6
3555 test -n "$CTAGS" && break
3558 for ac_prog in exetags etags
3560 # Extract the first word of "$ac_prog", so it can be a program name with args.
3561 set dummy $ac_prog; ac_word=$2
3562 echo "$as_me:3562: checking for $ac_word" >&5
3563 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3564 if test "${ac_cv_prog_ETAGS+set}" = set; then
3565 echo $ECHO_N "(cached) $ECHO_C" >&6
3567 if test -n "$ETAGS"; then
3568 ac_cv_prog_ETAGS="$ETAGS" # Let the user override the test.
3570 ac_save_IFS=$IFS; IFS=$ac_path_separator
3572 for ac_dir in $ac_dummy; do
3574 test -z "$ac_dir" && ac_dir=.
3575 $as_executable_p "$ac_dir/$ac_word" || continue
3576 ac_cv_prog_ETAGS="$ac_prog"
3577 echo "$as_me:3577: found $ac_dir/$ac_word" >&5
3583 ETAGS=$ac_cv_prog_ETAGS
3584 if test -n "$ETAGS"; then
3585 echo "$as_me:3585: result: $ETAGS" >&5
3586 echo "${ECHO_T}$ETAGS" >&6
3588 echo "$as_me:3588: result: no" >&5
3589 echo "${ECHO_T}no" >&6
3592 test -n "$ETAGS" && break
3595 # Extract the first word of "${CTAGS:-ctags}", so it can be a program name with args.
3596 set dummy ${CTAGS:-ctags}; ac_word=$2
3597 echo "$as_me:3597: checking for $ac_word" >&5
3598 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3599 if test "${ac_cv_prog_MAKE_LOWER_TAGS+set}" = set; then
3600 echo $ECHO_N "(cached) $ECHO_C" >&6
3602 if test -n "$MAKE_LOWER_TAGS"; then
3603 ac_cv_prog_MAKE_LOWER_TAGS="$MAKE_LOWER_TAGS" # Let the user override the test.
3605 ac_save_IFS=$IFS; IFS=$ac_path_separator
3607 for ac_dir in $ac_dummy; do
3609 test -z "$ac_dir" && ac_dir=.
3610 $as_executable_p "$ac_dir/$ac_word" || continue
3611 ac_cv_prog_MAKE_LOWER_TAGS="yes"
3612 echo "$as_me:3612: found $ac_dir/$ac_word" >&5
3616 test -z "$ac_cv_prog_MAKE_LOWER_TAGS" && ac_cv_prog_MAKE_LOWER_TAGS="no"
3619 MAKE_LOWER_TAGS=$ac_cv_prog_MAKE_LOWER_TAGS
3620 if test -n "$MAKE_LOWER_TAGS"; then
3621 echo "$as_me:3621: result: $MAKE_LOWER_TAGS" >&5
3622 echo "${ECHO_T}$MAKE_LOWER_TAGS" >&6
3624 echo "$as_me:3624: result: no" >&5
3625 echo "${ECHO_T}no" >&6
3628 if test "$cf_cv_mixedcase" = yes ; then
3629 # Extract the first word of "${ETAGS:-etags}", so it can be a program name with args.
3630 set dummy ${ETAGS:-etags}; ac_word=$2
3631 echo "$as_me:3631: checking for $ac_word" >&5
3632 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3633 if test "${ac_cv_prog_MAKE_UPPER_TAGS+set}" = set; then
3634 echo $ECHO_N "(cached) $ECHO_C" >&6
3636 if test -n "$MAKE_UPPER_TAGS"; then
3637 ac_cv_prog_MAKE_UPPER_TAGS="$MAKE_UPPER_TAGS" # Let the user override the test.
3639 ac_save_IFS=$IFS; IFS=$ac_path_separator
3641 for ac_dir in $ac_dummy; do
3643 test -z "$ac_dir" && ac_dir=.
3644 $as_executable_p "$ac_dir/$ac_word" || continue
3645 ac_cv_prog_MAKE_UPPER_TAGS="yes"
3646 echo "$as_me:3646: found $ac_dir/$ac_word" >&5
3650 test -z "$ac_cv_prog_MAKE_UPPER_TAGS" && ac_cv_prog_MAKE_UPPER_TAGS="no"
3653 MAKE_UPPER_TAGS=$ac_cv_prog_MAKE_UPPER_TAGS
3654 if test -n "$MAKE_UPPER_TAGS"; then
3655 echo "$as_me:3655: result: $MAKE_UPPER_TAGS" >&5
3656 echo "${ECHO_T}$MAKE_UPPER_TAGS" >&6
3658 echo "$as_me:3658: result: no" >&5
3659 echo "${ECHO_T}no" >&6
3666 if test "$MAKE_UPPER_TAGS" = yes ; then
3672 if test "$MAKE_LOWER_TAGS" = yes ; then
3678 echo "$as_me:3678: checking for makeflags variable" >&5
3679 echo $ECHO_N "checking for makeflags variable... $ECHO_C" >&6
3680 if test "${cf_cv_makeflags+set}" = set; then
3681 echo $ECHO_N "(cached) $ECHO_C" >&6
3685 for cf_option in '-${MAKEFLAGS}' '${MFLAGS}'
3687 cat >cf_makeflags.tmp <<CF_EOF
3690 @ echo '.$cf_option'
3692 cf_result=`${MAKE:-make} -k -f cf_makeflags.tmp 2>/dev/null | ${FGREP-fgrep} -v "ing directory" | sed -e 's,[ ]*$,,'`
3693 case "$cf_result" in
3695 cf_result="`${MAKE:-make} -k -f cf_makeflags.tmp CC=cc 2>/dev/null`"
3696 case "$cf_result" in
3697 (.*CC=*) cf_cv_makeflags=
3699 (*) cf_cv_makeflags=$cf_option
3708 echo "${as_me:-configure}:3708: testing given option \"$cf_option\",no match \"$cf_result\" ..." 1>&5
3713 rm -f cf_makeflags.tmp
3716 echo "$as_me:3716: result: $cf_cv_makeflags" >&5
3717 echo "${ECHO_T}$cf_cv_makeflags" >&6
3719 if test -n "$ac_tool_prefix"; then
3720 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
3721 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
3722 echo "$as_me:3722: checking for $ac_word" >&5
3723 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3724 if test "${ac_cv_prog_RANLIB+set}" = set; then
3725 echo $ECHO_N "(cached) $ECHO_C" >&6
3727 if test -n "$RANLIB"; then
3728 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
3730 ac_save_IFS=$IFS; IFS=$ac_path_separator
3732 for ac_dir in $ac_dummy; do
3734 test -z "$ac_dir" && ac_dir=.
3735 $as_executable_p "$ac_dir/$ac_word" || continue
3736 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
3737 echo "$as_me:3737: found $ac_dir/$ac_word" >&5
3743 RANLIB=$ac_cv_prog_RANLIB
3744 if test -n "$RANLIB"; then
3745 echo "$as_me:3745: result: $RANLIB" >&5
3746 echo "${ECHO_T}$RANLIB" >&6
3748 echo "$as_me:3748: result: no" >&5
3749 echo "${ECHO_T}no" >&6
3753 if test -z "$ac_cv_prog_RANLIB"; then
3754 ac_ct_RANLIB=$RANLIB
3755 # Extract the first word of "ranlib", so it can be a program name with args.
3756 set dummy ranlib; ac_word=$2
3757 echo "$as_me:3757: checking for $ac_word" >&5
3758 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3759 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
3760 echo $ECHO_N "(cached) $ECHO_C" >&6
3762 if test -n "$ac_ct_RANLIB"; then
3763 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
3765 ac_save_IFS=$IFS; IFS=$ac_path_separator
3767 for ac_dir in $ac_dummy; do
3769 test -z "$ac_dir" && ac_dir=.
3770 $as_executable_p "$ac_dir/$ac_word" || continue
3771 ac_cv_prog_ac_ct_RANLIB="ranlib"
3772 echo "$as_me:3772: found $ac_dir/$ac_word" >&5
3776 test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB="':'"
3779 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
3780 if test -n "$ac_ct_RANLIB"; then
3781 echo "$as_me:3781: result: $ac_ct_RANLIB" >&5
3782 echo "${ECHO_T}$ac_ct_RANLIB" >&6
3784 echo "$as_me:3784: result: no" >&5
3785 echo "${ECHO_T}no" >&6
3788 RANLIB=$ac_ct_RANLIB
3790 RANLIB="$ac_cv_prog_RANLIB"
3793 if test -n "$ac_tool_prefix"; then
3794 # Extract the first word of "${ac_tool_prefix}ld", so it can be a program name with args.
3795 set dummy ${ac_tool_prefix}ld; ac_word=$2
3796 echo "$as_me:3796: checking for $ac_word" >&5
3797 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3798 if test "${ac_cv_prog_LD+set}" = set; then
3799 echo $ECHO_N "(cached) $ECHO_C" >&6
3801 if test -n "$LD"; then
3802 ac_cv_prog_LD="$LD" # Let the user override the test.
3804 ac_save_IFS=$IFS; IFS=$ac_path_separator
3806 for ac_dir in $ac_dummy; do
3808 test -z "$ac_dir" && ac_dir=.
3809 $as_executable_p "$ac_dir/$ac_word" || continue
3810 ac_cv_prog_LD="${ac_tool_prefix}ld"
3811 echo "$as_me:3811: found $ac_dir/$ac_word" >&5
3818 if test -n "$LD"; then
3819 echo "$as_me:3819: result: $LD" >&5
3820 echo "${ECHO_T}$LD" >&6
3822 echo "$as_me:3822: result: no" >&5
3823 echo "${ECHO_T}no" >&6
3827 if test -z "$ac_cv_prog_LD"; then
3829 # Extract the first word of "ld", so it can be a program name with args.
3830 set dummy ld; ac_word=$2
3831 echo "$as_me:3831: checking for $ac_word" >&5
3832 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3833 if test "${ac_cv_prog_ac_ct_LD+set}" = set; then
3834 echo $ECHO_N "(cached) $ECHO_C" >&6
3836 if test -n "$ac_ct_LD"; then
3837 ac_cv_prog_ac_ct_LD="$ac_ct_LD" # Let the user override the test.
3839 ac_save_IFS=$IFS; IFS=$ac_path_separator
3841 for ac_dir in $ac_dummy; do
3843 test -z "$ac_dir" && ac_dir=.
3844 $as_executable_p "$ac_dir/$ac_word" || continue
3845 ac_cv_prog_ac_ct_LD="ld"
3846 echo "$as_me:3846: found $ac_dir/$ac_word" >&5
3850 test -z "$ac_cv_prog_ac_ct_LD" && ac_cv_prog_ac_ct_LD="ld"
3853 ac_ct_LD=$ac_cv_prog_ac_ct_LD
3854 if test -n "$ac_ct_LD"; then
3855 echo "$as_me:3855: result: $ac_ct_LD" >&5
3856 echo "${ECHO_T}$ac_ct_LD" >&6
3858 echo "$as_me:3858: result: no" >&5
3859 echo "${ECHO_T}no" >&6
3867 if test -n "$ac_tool_prefix"; then
3868 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
3869 set dummy ${ac_tool_prefix}ar; ac_word=$2
3870 echo "$as_me:3870: checking for $ac_word" >&5
3871 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3872 if test "${ac_cv_prog_AR+set}" = set; then
3873 echo $ECHO_N "(cached) $ECHO_C" >&6
3875 if test -n "$AR"; then
3876 ac_cv_prog_AR="$AR" # Let the user override the test.
3878 ac_save_IFS=$IFS; IFS=$ac_path_separator
3880 for ac_dir in $ac_dummy; do
3882 test -z "$ac_dir" && ac_dir=.
3883 $as_executable_p "$ac_dir/$ac_word" || continue
3884 ac_cv_prog_AR="${ac_tool_prefix}ar"
3885 echo "$as_me:3885: found $ac_dir/$ac_word" >&5
3892 if test -n "$AR"; then
3893 echo "$as_me:3893: result: $AR" >&5
3894 echo "${ECHO_T}$AR" >&6
3896 echo "$as_me:3896: result: no" >&5
3897 echo "${ECHO_T}no" >&6
3901 if test -z "$ac_cv_prog_AR"; then
3903 # Extract the first word of "ar", so it can be a program name with args.
3904 set dummy ar; ac_word=$2
3905 echo "$as_me:3905: checking for $ac_word" >&5
3906 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3907 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
3908 echo $ECHO_N "(cached) $ECHO_C" >&6
3910 if test -n "$ac_ct_AR"; then
3911 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
3913 ac_save_IFS=$IFS; IFS=$ac_path_separator
3915 for ac_dir in $ac_dummy; do
3917 test -z "$ac_dir" && ac_dir=.
3918 $as_executable_p "$ac_dir/$ac_word" || continue
3919 ac_cv_prog_ac_ct_AR="ar"
3920 echo "$as_me:3920: found $ac_dir/$ac_word" >&5
3924 test -z "$ac_cv_prog_ac_ct_AR" && ac_cv_prog_ac_ct_AR="ar"
3927 ac_ct_AR=$ac_cv_prog_ac_ct_AR
3928 if test -n "$ac_ct_AR"; then
3929 echo "$as_me:3929: result: $ac_ct_AR" >&5
3930 echo "${ECHO_T}$ac_ct_AR" >&6
3932 echo "$as_me:3932: result: no" >&5
3933 echo "${ECHO_T}no" >&6
3941 if test -n "$ac_tool_prefix"; then
3942 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
3943 set dummy ${ac_tool_prefix}ar; ac_word=$2
3944 echo "$as_me:3944: checking for $ac_word" >&5
3945 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3946 if test "${ac_cv_prog_AR+set}" = set; then
3947 echo $ECHO_N "(cached) $ECHO_C" >&6
3949 if test -n "$AR"; then
3950 ac_cv_prog_AR="$AR" # Let the user override the test.
3952 ac_save_IFS=$IFS; IFS=$ac_path_separator
3954 for ac_dir in $ac_dummy; do
3956 test -z "$ac_dir" && ac_dir=.
3957 $as_executable_p "$ac_dir/$ac_word" || continue
3958 ac_cv_prog_AR="${ac_tool_prefix}ar"
3959 echo "$as_me:3959: found $ac_dir/$ac_word" >&5
3966 if test -n "$AR"; then
3967 echo "$as_me:3967: result: $AR" >&5
3968 echo "${ECHO_T}$AR" >&6
3970 echo "$as_me:3970: result: no" >&5
3971 echo "${ECHO_T}no" >&6
3975 if test -z "$ac_cv_prog_AR"; then
3977 # Extract the first word of "ar", so it can be a program name with args.
3978 set dummy ar; ac_word=$2
3979 echo "$as_me:3979: checking for $ac_word" >&5
3980 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3981 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
3982 echo $ECHO_N "(cached) $ECHO_C" >&6
3984 if test -n "$ac_ct_AR"; then
3985 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
3987 ac_save_IFS=$IFS; IFS=$ac_path_separator
3989 for ac_dir in $ac_dummy; do
3991 test -z "$ac_dir" && ac_dir=.
3992 $as_executable_p "$ac_dir/$ac_word" || continue
3993 ac_cv_prog_ac_ct_AR="ar"
3994 echo "$as_me:3994: found $ac_dir/$ac_word" >&5
3998 test -z "$ac_cv_prog_ac_ct_AR" && ac_cv_prog_ac_ct_AR="ar"
4001 ac_ct_AR=$ac_cv_prog_ac_ct_AR
4002 if test -n "$ac_ct_AR"; then
4003 echo "$as_me:4003: result: $ac_ct_AR" >&5
4004 echo "${ECHO_T}$ac_ct_AR" >&6
4006 echo "$as_me:4006: result: no" >&5
4007 echo "${ECHO_T}no" >&6
4015 echo "$as_me:4015: checking for options to update archives" >&5
4016 echo $ECHO_N "checking for options to update archives... $ECHO_C" >&6
4017 if test "${cf_cv_ar_flags+set}" = set; then
4018 echo $ECHO_N "(cached) $ECHO_C" >&6
4021 case "$cf_cv_system_name" in
4024 cat >mk_static_lib.sh <<-EOF
4029 exec \$MSVC_BIN -out:"\$out" \$@
4031 chmod +x mk_static_lib.sh
4032 AR=`pwd`/mk_static_lib.sh
4035 cf_cv_ar_flags=unknown
4036 for cf_ar_flags in -curvU -curv curv -crv crv -cqv cqv -rv rv
4039 # check if $ARFLAGS already contains this choice
4040 if test "x$ARFLAGS" != "x" ; then
4041 cf_check_ar_flags=`echo "x$ARFLAGS" | sed -e "s/$cf_ar_flags\$//" -e "s/$cf_ar_flags / /"`
4042 if test "x$ARFLAGS" != "$cf_check_ar_flags" ; then
4048 rm -f "conftest.$ac_cv_objext"
4051 cat >"conftest.$ac_ext" <<EOF
4052 #line 4052 "configure"
4053 int testdata[3] = { 123, 456, 789 };
4055 if { (eval echo "$as_me:4055: \"$ac_compile\"") >&5
4056 (eval $ac_compile) 2>&5
4058 echo "$as_me:4058: \$? = $ac_status" >&5
4059 (exit "$ac_status"); } ; then
4060 echo "$AR $ARFLAGS $cf_ar_flags conftest.a conftest.$ac_cv_objext" >&5
4061 $AR $ARFLAGS "$cf_ar_flags" conftest.a "conftest.$ac_cv_objext" 2>&5 1>/dev/null
4062 if test -f conftest.a ; then
4063 cf_cv_ar_flags="$cf_ar_flags"
4067 test -n "$verbose" && echo " cannot compile test-program" 1>&6
4069 echo "${as_me:-configure}:4069: testing cannot compile test-program ..." 1>&5
4074 rm -f conftest.a "conftest.$ac_ext" "conftest.$ac_cv_objext"
4079 echo "$as_me:4079: result: $cf_cv_ar_flags" >&5
4080 echo "${ECHO_T}$cf_cv_ar_flags" >&6
4082 if test -n "$ARFLAGS" ; then
4083 if test -n "$cf_cv_ar_flags" ; then
4084 ARFLAGS="$ARFLAGS $cf_cv_ar_flags"
4087 ARFLAGS=$cf_cv_ar_flags
4090 echo "$as_me:4090: checking for PATH separator" >&5
4091 echo $ECHO_N "checking for PATH separator... $ECHO_C" >&6
4092 case "$cf_cv_system_name" in
4093 (os2*) PATH_SEPARATOR=';' ;;
4094 (*) ${PATH_SEPARATOR:=':'} ;;
4097 echo "$as_me:4097: result: $PATH_SEPARATOR" >&5
4098 echo "${ECHO_T}$PATH_SEPARATOR" >&6
4100 echo "$as_me:4100: checking if you have specified an install-prefix" >&5
4101 echo $ECHO_N "checking if you have specified an install-prefix... $ECHO_C" >&6
4103 # Check whether --with-install-prefix or --without-install-prefix was given.
4104 if test "${with_install_prefix+set}" = set; then
4105 withval="$with_install_prefix"
4109 (*) DESTDIR="$withval"
4113 echo "$as_me:4113: result: $DESTDIR" >&5
4114 echo "${ECHO_T}$DESTDIR" >&6
4116 ###############################################################################
4118 # If we're cross-compiling, allow the user to override the tools and their
4119 # options. The configure script is oriented toward identifying the host
4120 # compiler, etc., but we need a build compiler to generate parts of the source.
4122 if test "$cross_compiling" = yes ; then
4124 # defaults that we might want to override
4125 : ${BUILD_CFLAGS:=''}
4126 : ${BUILD_CPPFLAGS:=''}
4127 : ${BUILD_LDFLAGS:=''}
4129 : ${BUILD_EXEEXT:='$x'}
4130 : ${BUILD_OBJEXT:='o'}
4132 # Check whether --with-build-cc or --without-build-cc was given.
4133 if test "${with_build_cc+set}" = set; then
4134 withval="$with_build_cc"
4137 for ac_prog in gcc clang c99 c89 cc cl
4139 # Extract the first word of "$ac_prog", so it can be a program name with args.
4140 set dummy $ac_prog; ac_word=$2
4141 echo "$as_me:4141: checking for $ac_word" >&5
4142 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4143 if test "${ac_cv_prog_BUILD_CC+set}" = set; then
4144 echo $ECHO_N "(cached) $ECHO_C" >&6
4146 if test -n "$BUILD_CC"; then
4147 ac_cv_prog_BUILD_CC="$BUILD_CC" # Let the user override the test.
4149 ac_save_IFS=$IFS; IFS=$ac_path_separator
4151 for ac_dir in $ac_dummy; do
4153 test -z "$ac_dir" && ac_dir=.
4154 $as_executable_p "$ac_dir/$ac_word" || continue
4155 ac_cv_prog_BUILD_CC="$ac_prog"
4156 echo "$as_me:4156: found $ac_dir/$ac_word" >&5
4162 BUILD_CC=$ac_cv_prog_BUILD_CC
4163 if test -n "$BUILD_CC"; then
4164 echo "$as_me:4164: result: $BUILD_CC" >&5
4165 echo "${ECHO_T}$BUILD_CC" >&6
4167 echo "$as_me:4167: result: no" >&5
4168 echo "${ECHO_T}no" >&6
4171 test -n "$BUILD_CC" && break
4173 test -n "$BUILD_CC" || BUILD_CC="none"
4176 echo "$as_me:4176: checking for native build C compiler" >&5
4177 echo $ECHO_N "checking for native build C compiler... $ECHO_C" >&6
4178 echo "$as_me:4178: result: $BUILD_CC" >&5
4179 echo "${ECHO_T}$BUILD_CC" >&6
4181 echo "$as_me:4181: checking for native build C preprocessor" >&5
4182 echo $ECHO_N "checking for native build C preprocessor... $ECHO_C" >&6
4184 # Check whether --with-build-cpp or --without-build-cpp was given.
4185 if test "${with_build_cpp+set}" = set; then
4186 withval="$with_build_cpp"
4187 BUILD_CPP="$withval"
4189 BUILD_CPP='${BUILD_CC} -E'
4191 echo "$as_me:4191: result: $BUILD_CPP" >&5
4192 echo "${ECHO_T}$BUILD_CPP" >&6
4194 echo "$as_me:4194: checking for native build C flags" >&5
4195 echo $ECHO_N "checking for native build C flags... $ECHO_C" >&6
4197 # Check whether --with-build-cflags or --without-build-cflags was given.
4198 if test "${with_build_cflags+set}" = set; then
4199 withval="$with_build_cflags"
4200 BUILD_CFLAGS="$withval"
4202 echo "$as_me:4202: result: $BUILD_CFLAGS" >&5
4203 echo "${ECHO_T}$BUILD_CFLAGS" >&6
4205 echo "$as_me:4205: checking for native build C preprocessor-flags" >&5
4206 echo $ECHO_N "checking for native build C preprocessor-flags... $ECHO_C" >&6
4208 # Check whether --with-build-cppflags or --without-build-cppflags was given.
4209 if test "${with_build_cppflags+set}" = set; then
4210 withval="$with_build_cppflags"
4211 BUILD_CPPFLAGS="$withval"
4213 echo "$as_me:4213: result: $BUILD_CPPFLAGS" >&5
4214 echo "${ECHO_T}$BUILD_CPPFLAGS" >&6
4216 echo "$as_me:4216: checking for native build linker-flags" >&5
4217 echo $ECHO_N "checking for native build linker-flags... $ECHO_C" >&6
4219 # Check whether --with-build-ldflags or --without-build-ldflags was given.
4220 if test "${with_build_ldflags+set}" = set; then
4221 withval="$with_build_ldflags"
4222 BUILD_LDFLAGS="$withval"
4224 echo "$as_me:4224: result: $BUILD_LDFLAGS" >&5
4225 echo "${ECHO_T}$BUILD_LDFLAGS" >&6
4227 echo "$as_me:4227: checking for native build linker-libraries" >&5
4228 echo $ECHO_N "checking for native build linker-libraries... $ECHO_C" >&6
4230 # Check whether --with-build-libs or --without-build-libs was given.
4231 if test "${with_build_libs+set}" = set; then
4232 withval="$with_build_libs"
4233 BUILD_LIBS="$withval"
4235 echo "$as_me:4235: result: $BUILD_LIBS" >&5
4236 echo "${ECHO_T}$BUILD_LIBS" >&6
4238 # this assumes we're on Unix.
4242 : ${BUILD_CC:='${CC}'}
4244 if { test "$BUILD_CC" = "$CC" || test "$BUILD_CC" = '${CC}'; } ; then
4245 { { echo "$as_me:4245: error: Cross-build requires two compilers.
4246 Use --with-build-cc to specify the native compiler." >&5
4247 echo "$as_me: error: Cross-build requires two compilers.
4248 Use --with-build-cc to specify the native compiler." >&2;}
4249 { (exit 1); exit 1; }; }
4253 : ${BUILD_CC:='${CC}'}
4254 : ${BUILD_CPP:='${CPP}'}
4255 : ${BUILD_CFLAGS:='${CFLAGS}'}
4256 : ${BUILD_CPPFLAGS:='${CPPFLAGS}'}
4257 : ${BUILD_LDFLAGS:='${LDFLAGS}'}
4258 : ${BUILD_LIBS:='${LIBS}'}
4259 : ${BUILD_EXEEXT:='$x'}
4260 : ${BUILD_OBJEXT:='o'}
4263 ###############################################################################
4265 ### Options to allow the user to specify the set of libraries which are used.
4266 ### Use "--without-normal --with-shared" to allow the default model to be
4267 ### shared, for example.
4270 echo "$as_me:4270: checking if you want to build shared C-objects" >&5
4271 echo $ECHO_N "checking if you want to build shared C-objects... $ECHO_C" >&6
4273 # Check whether --with-shared or --without-shared was given.
4274 if test "${with_shared+set}" = set; then
4275 withval="$with_shared"
4276 with_shared=$withval
4280 echo "$as_me:4280: result: $with_shared" >&5
4281 echo "${ECHO_T}$with_shared" >&6
4282 test "$with_shared" = "yes" && cf_list_models="$cf_list_models shared"
4284 echo "$as_me:4284: checking for specified models" >&5
4285 echo $ECHO_N "checking for specified models... $ECHO_C" >&6
4286 test -z "$cf_list_models" && cf_list_models=normal
4287 echo "$as_me:4287: result: $cf_list_models" >&5
4288 echo "${ECHO_T}$cf_list_models" >&6
4290 ### Use the first model as the default, and save its suffix for use in building
4291 ### up test-applications.
4292 echo "$as_me:4292: checking for default model" >&5
4293 echo $ECHO_N "checking for default model... $ECHO_C" >&6
4294 DFT_LWR_MODEL=`echo "$cf_list_models" | $AWK '{print $1}'`
4295 echo "$as_me:4295: result: $DFT_LWR_MODEL" >&5
4296 echo "${ECHO_T}$DFT_LWR_MODEL" >&6
4298 DFT_UPR_MODEL=`echo "$DFT_LWR_MODEL" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
4300 echo "$as_me:4300: checking for specific curses-directory" >&5
4301 echo $ECHO_N "checking for specific curses-directory... $ECHO_C" >&6
4303 # Check whether --with-curses-dir or --without-curses-dir was given.
4304 if test "${with_curses_dir+set}" = set; then
4305 withval="$with_curses_dir"
4306 cf_cv_curses_dir=$withval
4310 echo "$as_me:4310: result: $cf_cv_curses_dir" >&5
4311 echo "${ECHO_T}$cf_cv_curses_dir" >&6
4313 if test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no"
4316 if test "x$prefix" != xNONE; then
4317 cf_path_syntax="$prefix"
4319 cf_path_syntax="$ac_default_prefix"
4327 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
4329 (.\$\{*prefix\}*|.\$\{*dir\}*)
4330 eval withval="$withval"
4333 withval=`echo "$withval" | sed -e s%NONE%$cf_path_syntax%`
4338 withval=`echo "$withval" | sed -e s%NONE%$cf_path_syntax%`
4341 { { echo "$as_me:4341: error: expected a pathname, not \"$withval\"" >&5
4342 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
4343 { (exit 1); exit 1; }; }
4347 if test -d "$cf_cv_curses_dir"
4350 if test -n "$cf_cv_curses_dir/include" ; then
4351 for cf_add_incdir in $cf_cv_curses_dir/include
4353 while test "$cf_add_incdir" != /usr/include
4355 if test -d "$cf_add_incdir"
4358 if test -n "$CFLAGS$CPPFLAGS" ; then
4359 # a loop is needed to ensure we can add subdirs of existing dirs
4360 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
4361 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
4362 cf_have_incdir=yes; break
4367 if test "$cf_have_incdir" = no ; then
4368 if test "$cf_add_incdir" = /usr/local/include ; then
4369 if test "$GCC" = yes
4371 cf_save_CPPFLAGS=$CPPFLAGS
4373 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4374 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
4376 cat >"conftest.$ac_ext" <<_ACEOF
4377 #line 4377 "configure"
4378 #include "confdefs.h"
4388 rm -f "conftest.$ac_objext"
4389 if { (eval echo "$as_me:4389: \"$ac_compile\"") >&5
4390 (eval $ac_compile) 2>&5
4392 echo "$as_me:4392: \$? = $ac_status" >&5
4393 (exit "$ac_status"); } &&
4394 { ac_try='test -s "conftest.$ac_objext"'
4395 { (eval echo "$as_me:4395: \"$ac_try\"") >&5
4398 echo "$as_me:4398: \$? = $ac_status" >&5
4399 (exit "$ac_status"); }; }; then
4402 echo "$as_me: failed program was:" >&5
4403 cat "conftest.$ac_ext" >&5
4406 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4407 CPPFLAGS=$cf_save_CPPFLAGS
4412 if test "$cf_have_incdir" = no ; then
4413 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
4415 echo "${as_me:-configure}:4415: testing adding $cf_add_incdir to include-path ..." 1>&5
4417 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
4419 cf_top_incdir=`echo "$cf_add_incdir" | sed -e 's%/include/.*$%/include%'`
4420 test "$cf_top_incdir" = "$cf_add_incdir" && break
4421 cf_add_incdir="$cf_top_incdir"
4432 if test -n "$cf_cv_curses_dir/lib" ; then
4433 for cf_add_libdir in $cf_cv_curses_dir/lib
4435 if test "$cf_add_libdir" = /usr/lib ; then
4437 elif test -d "$cf_add_libdir"
4440 if test -n "$LDFLAGS$LIBS" ; then
4441 # a loop is needed to ensure we can add subdirs of existing dirs
4442 for cf_test_libdir in $LDFLAGS $LIBS ; do
4443 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
4444 cf_have_libdir=yes; break
4448 if test "$cf_have_libdir" = no ; then
4449 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
4451 echo "${as_me:-configure}:4451: testing adding $cf_add_libdir to library-path ..." 1>&5
4453 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
4462 cf_ncuconfig_root=ncurses
4463 cf_have_ncuconfig=no
4465 if test "x${PKG_CONFIG:=none}" != xnone; then
4466 echo "$as_me:4466: checking pkg-config for $cf_ncuconfig_root" >&5
4467 echo $ECHO_N "checking pkg-config for $cf_ncuconfig_root... $ECHO_C" >&6
4468 if "$PKG_CONFIG" --exists $cf_ncuconfig_root ; then
4469 echo "$as_me:4469: result: yes" >&5
4470 echo "${ECHO_T}yes" >&6
4472 echo "$as_me:4472: checking if the $cf_ncuconfig_root package files work" >&5
4473 echo $ECHO_N "checking if the $cf_ncuconfig_root package files work... $ECHO_C" >&6
4474 cf_have_ncuconfig=unknown
4476 cf_save_CFLAGS="$CFLAGS"
4477 cf_save_CPPFLAGS="$CPPFLAGS"
4478 cf_save_LIBS="$LIBS"
4480 cf_pkg_cflags="`$PKG_CONFIG --cflags $cf_ncuconfig_root`"
4481 cf_pkg_libs="`$PKG_CONFIG --libs $cf_ncuconfig_root`"
4483 # while -W for passing linker flags is prevalent, it is not "standard".
4484 # At least one wrapper for c89/c99 (in Apple's xcode) has its own
4485 # incompatible _and_ non-standard -W option which gives an error. Work
4486 # around that pitfall.
4487 case "x${CC}@@${cf_pkg_libs}@${cf_pkg_cflags}" in
4493 cf_new_extra_cppflags=
4495 for cf_add_cflags in $cf_pkg_cflags
4497 case "$cf_fix_cppflags" in
4499 case "$cf_add_cflags" in
4500 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4501 case "$cf_add_cflags" in
4503 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4505 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4506 && test -z "${cf_tst_cflags}" \
4507 && cf_fix_cppflags=yes
4509 if test "$cf_fix_cppflags" = yes ; then
4511 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4512 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4515 elif test "${cf_tst_cflags}" = "\"'" ; then
4517 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4518 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4528 case "$cf_add_cflags" in
4530 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4532 CPPFLAGS=`echo "$CPPFLAGS" | \
4533 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4534 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4539 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4540 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4547 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4548 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4555 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4556 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4558 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
4560 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4561 && test -z "${cf_tst_cflags}" \
4562 && cf_fix_cppflags=no
4567 if test -n "$cf_new_cflags" ; then
4569 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4570 CFLAGS="${CFLAGS}$cf_new_cflags"
4574 if test -n "$cf_new_cppflags" ; then
4576 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4577 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4581 if test -n "$cf_new_extra_cppflags" ; then
4583 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4584 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4591 for cf_add_1lib in $cf_pkg_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
4593 for cf_add_1lib in $cf_add_0lib; do
4594 for cf_add_2lib in $cf_add_libs; do
4595 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
4600 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
4604 cat >"conftest.$ac_ext" <<_ACEOF
4605 #line 4605 "configure"
4606 #include "confdefs.h"
4607 #include <${cf_cv_ncurses_header:-curses.h}>
4611 initscr(); mousemask(0,0); tigetstr((char *)0);
4616 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
4617 if { (eval echo "$as_me:4617: \"$ac_link\"") >&5
4618 (eval $ac_link) 2>&5
4620 echo "$as_me:4620: \$? = $ac_status" >&5
4621 (exit "$ac_status"); } &&
4622 { ac_try='test -s "conftest$ac_exeext"'
4623 { (eval echo "$as_me:4623: \"$ac_try\"") >&5
4626 echo "$as_me:4626: \$? = $ac_status" >&5
4627 (exit "$ac_status"); }; }; then
4628 if test "$cross_compiling" = yes; then
4629 cf_test_ncuconfig=maybe
4631 cat >"conftest.$ac_ext" <<_ACEOF
4632 #line 4632 "configure"
4633 #include "confdefs.h"
4634 #include <${cf_cv_ncurses_header:-curses.h}>
4636 { const char *xx = curses_version(); return (xx == 0); }
4638 rm -f "conftest$ac_exeext"
4639 if { (eval echo "$as_me:4639: \"$ac_link\"") >&5
4640 (eval $ac_link) 2>&5
4642 echo "$as_me:4642: \$? = $ac_status" >&5
4643 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
4644 { (eval echo "$as_me:4644: \"$ac_try\"") >&5
4647 echo "$as_me:4647: \$? = $ac_status" >&5
4648 (exit "$ac_status"); }; }; then
4649 cf_test_ncuconfig=yes
4651 echo "$as_me: program exited with status $ac_status" >&5
4652 echo "$as_me: failed program was:" >&5
4653 cat "conftest.$ac_ext" >&5
4654 cf_test_ncuconfig=no
4656 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
4659 echo "$as_me: failed program was:" >&5
4660 cat "conftest.$ac_ext" >&5
4661 cf_test_ncuconfig=no
4663 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
4665 CFLAGS="$cf_save_CFLAGS"
4666 CPPFLAGS="$cf_save_CPPFLAGS"
4667 LIBS="$cf_save_LIBS"
4669 if test "x$cf_test_ncuconfig" != xyes; then
4670 cf_temp=`echo "x$cf_pkg_cflags" | sed -e s/^x// -e 's/-W[^ ]*//g'`
4671 cf_pkg_cflags="$cf_temp"
4672 cf_temp=`echo "x$cf_pkg_libs" | sed -e s/^x// -e 's/-W[^ ]*//g'`
4673 cf_pkg_libs="$cf_temp"
4681 cf_new_extra_cppflags=
4683 for cf_add_cflags in $cf_pkg_cflags
4685 case "$cf_fix_cppflags" in
4687 case "$cf_add_cflags" in
4688 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4689 case "$cf_add_cflags" in
4691 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4693 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4694 && test -z "${cf_tst_cflags}" \
4695 && cf_fix_cppflags=yes
4697 if test "$cf_fix_cppflags" = yes ; then
4699 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4700 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4703 elif test "${cf_tst_cflags}" = "\"'" ; then
4705 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4706 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4716 case "$cf_add_cflags" in
4718 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4720 CPPFLAGS=`echo "$CPPFLAGS" | \
4721 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4722 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4727 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4728 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4735 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4736 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4743 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4744 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4746 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
4748 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4749 && test -z "${cf_tst_cflags}" \
4750 && cf_fix_cppflags=no
4755 if test -n "$cf_new_cflags" ; then
4757 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4758 CFLAGS="${CFLAGS}$cf_new_cflags"
4762 if test -n "$cf_new_cppflags" ; then
4764 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4765 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4769 if test -n "$cf_new_extra_cppflags" ; then
4771 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4772 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4779 for cf_add_1lib in $cf_pkg_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
4781 for cf_add_1lib in $cf_add_0lib; do
4782 for cf_add_2lib in $cf_add_libs; do
4783 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
4788 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
4792 cat >"conftest.$ac_ext" <<_ACEOF
4793 #line 4793 "configure"
4794 #include "confdefs.h"
4795 #include <${cf_cv_ncurses_header:-curses.h}>
4799 initscr(); mousemask(0,0); tigetstr((char *)0);
4804 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
4805 if { (eval echo "$as_me:4805: \"$ac_link\"") >&5
4806 (eval $ac_link) 2>&5
4808 echo "$as_me:4808: \$? = $ac_status" >&5
4809 (exit "$ac_status"); } &&
4810 { ac_try='test -s "conftest$ac_exeext"'
4811 { (eval echo "$as_me:4811: \"$ac_try\"") >&5
4814 echo "$as_me:4814: \$? = $ac_status" >&5
4815 (exit "$ac_status"); }; }; then
4816 if test "$cross_compiling" = yes; then
4817 cf_have_ncuconfig=maybe
4819 cat >"conftest.$ac_ext" <<_ACEOF
4820 #line 4820 "configure"
4821 #include "confdefs.h"
4822 #include <${cf_cv_ncurses_header:-curses.h}>
4824 { const char *xx = curses_version(); return (xx == 0); }
4826 rm -f "conftest$ac_exeext"
4827 if { (eval echo "$as_me:4827: \"$ac_link\"") >&5
4828 (eval $ac_link) 2>&5
4830 echo "$as_me:4830: \$? = $ac_status" >&5
4831 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
4832 { (eval echo "$as_me:4832: \"$ac_try\"") >&5
4835 echo "$as_me:4835: \$? = $ac_status" >&5
4836 (exit "$ac_status"); }; }; then
4837 cf_have_ncuconfig=yes
4839 echo "$as_me: program exited with status $ac_status" >&5
4840 echo "$as_me: failed program was:" >&5
4841 cat "conftest.$ac_ext" >&5
4842 cf_have_ncuconfig=no
4844 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
4847 echo "$as_me: failed program was:" >&5
4848 cat "conftest.$ac_ext" >&5
4849 cf_have_ncuconfig=no
4851 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
4852 echo "$as_me:4852: result: $cf_have_ncuconfig" >&5
4853 echo "${ECHO_T}$cf_have_ncuconfig" >&6
4854 test "$cf_have_ncuconfig" = maybe && cf_have_ncuconfig=yes
4855 if test "$cf_have_ncuconfig" != "yes"
4857 CPPFLAGS="$cf_save_CPPFLAGS"
4858 LIBS="$cf_save_LIBS"
4859 NCURSES_CONFIG_PKG=none
4862 cat >>confdefs.h <<\EOF
4866 NCURSES_CONFIG_PKG=$cf_ncuconfig_root
4868 echo "$as_me:4868: checking for terminfo header" >&5
4869 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
4870 if test "${cf_cv_term_header+set}" = set; then
4871 echo $ECHO_N "(cached) $ECHO_C" >&6
4874 case "${cf_cv_ncurses_header}" in
4875 (*/ncurses.h|*/ncursesw.h)
4876 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
4879 cf_term_header=term.h
4883 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
4885 cat >"conftest.$ac_ext" <<_ACEOF
4886 #line 4886 "configure"
4887 #include "confdefs.h"
4889 #include <${cf_cv_ncurses_header:-curses.h}>
4895 int x = auto_left_margin; (void)x
4900 rm -f "conftest.$ac_objext"
4901 if { (eval echo "$as_me:4901: \"$ac_compile\"") >&5
4902 (eval $ac_compile) 2>&5
4904 echo "$as_me:4904: \$? = $ac_status" >&5
4905 (exit "$ac_status"); } &&
4906 { ac_try='test -s "conftest.$ac_objext"'
4907 { (eval echo "$as_me:4907: \"$ac_try\"") >&5
4910 echo "$as_me:4910: \$? = $ac_status" >&5
4911 (exit "$ac_status"); }; }; then
4913 cf_cv_term_header="$cf_test"
4915 echo "$as_me: failed program was:" >&5
4916 cat "conftest.$ac_ext" >&5
4918 cf_cv_term_header=unknown
4921 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4922 test "$cf_cv_term_header" != unknown && break
4926 echo "$as_me:4926: result: $cf_cv_term_header" >&5
4927 echo "${ECHO_T}$cf_cv_term_header" >&6
4929 # Set definitions to allow ifdef'ing to accommodate subdirectories
4931 case "$cf_cv_term_header" in
4934 cat >>confdefs.h <<\EOF
4935 #define HAVE_TERM_H 1
4941 case "$cf_cv_term_header" in
4944 cat >>confdefs.h <<\EOF
4945 #define HAVE_NCURSES_TERM_H 1
4951 cat >>confdefs.h <<\EOF
4952 #define HAVE_NCURSESW_TERM_H 1
4961 echo "$as_me:4961: result: no" >&5
4962 echo "${ECHO_T}no" >&6
4963 NCURSES_CONFIG_PKG=none
4966 NCURSES_CONFIG_PKG=none
4969 if test "x$cf_have_ncuconfig" = "xno"; then
4970 cf_ncurses_config="${cf_ncuconfig_root}${NCURSES_CONFIG_SUFFIX}-config"; echo "Looking for ${cf_ncurses_config}"
4972 if test -n "$ac_tool_prefix"; then
4973 for ac_prog in ${cf_ncurses_config} ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
4975 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4976 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
4977 echo "$as_me:4977: checking for $ac_word" >&5
4978 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4979 if test "${ac_cv_prog_NCURSES_CONFIG+set}" = set; then
4980 echo $ECHO_N "(cached) $ECHO_C" >&6
4982 if test -n "$NCURSES_CONFIG"; then
4983 ac_cv_prog_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test.
4985 ac_save_IFS=$IFS; IFS=$ac_path_separator
4987 for ac_dir in $ac_dummy; do
4989 test -z "$ac_dir" && ac_dir=.
4990 $as_executable_p "$ac_dir/$ac_word" || continue
4991 ac_cv_prog_NCURSES_CONFIG="$ac_tool_prefix$ac_prog"
4992 echo "$as_me:4992: found $ac_dir/$ac_word" >&5
4998 NCURSES_CONFIG=$ac_cv_prog_NCURSES_CONFIG
4999 if test -n "$NCURSES_CONFIG"; then
5000 echo "$as_me:5000: result: $NCURSES_CONFIG" >&5
5001 echo "${ECHO_T}$NCURSES_CONFIG" >&6
5003 echo "$as_me:5003: result: no" >&5
5004 echo "${ECHO_T}no" >&6
5007 test -n "$NCURSES_CONFIG" && break
5010 if test -z "$NCURSES_CONFIG"; then
5011 ac_ct_NCURSES_CONFIG=$NCURSES_CONFIG
5012 for ac_prog in ${cf_ncurses_config} ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
5014 # Extract the first word of "$ac_prog", so it can be a program name with args.
5015 set dummy $ac_prog; ac_word=$2
5016 echo "$as_me:5016: checking for $ac_word" >&5
5017 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5018 if test "${ac_cv_prog_ac_ct_NCURSES_CONFIG+set}" = set; then
5019 echo $ECHO_N "(cached) $ECHO_C" >&6
5021 if test -n "$ac_ct_NCURSES_CONFIG"; then
5022 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_ct_NCURSES_CONFIG" # Let the user override the test.
5024 ac_save_IFS=$IFS; IFS=$ac_path_separator
5026 for ac_dir in $ac_dummy; do
5028 test -z "$ac_dir" && ac_dir=.
5029 $as_executable_p "$ac_dir/$ac_word" || continue
5030 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_prog"
5031 echo "$as_me:5031: found $ac_dir/$ac_word" >&5
5037 ac_ct_NCURSES_CONFIG=$ac_cv_prog_ac_ct_NCURSES_CONFIG
5038 if test -n "$ac_ct_NCURSES_CONFIG"; then
5039 echo "$as_me:5039: result: $ac_ct_NCURSES_CONFIG" >&5
5040 echo "${ECHO_T}$ac_ct_NCURSES_CONFIG" >&6
5042 echo "$as_me:5042: result: no" >&5
5043 echo "${ECHO_T}no" >&6
5046 test -n "$ac_ct_NCURSES_CONFIG" && break
5048 test -n "$ac_ct_NCURSES_CONFIG" || ac_ct_NCURSES_CONFIG="none"
5050 NCURSES_CONFIG=$ac_ct_NCURSES_CONFIG
5053 if test "$NCURSES_CONFIG" != none ; then
5058 cf_new_extra_cppflags=
5060 for cf_add_cflags in `$NCURSES_CONFIG --cflags`
5062 case "$cf_fix_cppflags" in
5064 case "$cf_add_cflags" in
5065 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
5066 case "$cf_add_cflags" in
5068 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
5070 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
5071 && test -z "${cf_tst_cflags}" \
5072 && cf_fix_cppflags=yes
5074 if test "$cf_fix_cppflags" = yes ; then
5076 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5077 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5080 elif test "${cf_tst_cflags}" = "\"'" ; then
5082 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5083 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5093 case "$cf_add_cflags" in
5095 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
5097 CPPFLAGS=`echo "$CPPFLAGS" | \
5098 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
5099 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
5104 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
5105 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
5112 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
5113 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
5120 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5121 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5123 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
5125 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
5126 && test -z "${cf_tst_cflags}" \
5127 && cf_fix_cppflags=no
5132 if test -n "$cf_new_cflags" ; then
5134 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
5135 CFLAGS="${CFLAGS}$cf_new_cflags"
5139 if test -n "$cf_new_cppflags" ; then
5141 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5142 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
5146 if test -n "$cf_new_extra_cppflags" ; then
5148 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
5149 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
5156 for cf_add_1lib in `$NCURSES_CONFIG --libs`; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
5158 for cf_add_1lib in $cf_add_0lib; do
5159 for cf_add_2lib in $cf_add_libs; do
5160 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
5165 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
5169 # even with config script, some packages use no-override for curses.h
5171 echo "$as_me:5171: checking if we have identified curses headers" >&5
5172 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
5173 if test "${cf_cv_ncurses_header+set}" = set; then
5174 echo $ECHO_N "(cached) $ECHO_C" >&6
5177 cf_cv_ncurses_header=none
5179 ncurses.h ncurses/ncurses.h \
5180 curses.h ncurses/curses.h
5182 cat >"conftest.$ac_ext" <<_ACEOF
5183 #line 5183 "configure"
5184 #include "confdefs.h"
5185 #include <${cf_header}>
5189 initscr(); tgoto("?", 0,0)
5194 rm -f "conftest.$ac_objext"
5195 if { (eval echo "$as_me:5195: \"$ac_compile\"") >&5
5196 (eval $ac_compile) 2>&5
5198 echo "$as_me:5198: \$? = $ac_status" >&5
5199 (exit "$ac_status"); } &&
5200 { ac_try='test -s "conftest.$ac_objext"'
5201 { (eval echo "$as_me:5201: \"$ac_try\"") >&5
5204 echo "$as_me:5204: \$? = $ac_status" >&5
5205 (exit "$ac_status"); }; }; then
5206 cf_cv_ncurses_header=$cf_header; break
5208 echo "$as_me: failed program was:" >&5
5209 cat "conftest.$ac_ext" >&5
5211 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5215 echo "$as_me:5215: result: $cf_cv_ncurses_header" >&5
5216 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
5218 if test "$cf_cv_ncurses_header" = none ; then
5219 { { echo "$as_me:5219: error: No curses header-files found" >&5
5220 echo "$as_me: error: No curses header-files found" >&2;}
5221 { (exit 1); exit 1; }; }
5224 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
5226 for ac_header in $cf_cv_ncurses_header
5228 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
5229 echo "$as_me:5229: checking for $ac_header" >&5
5230 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5231 if eval "test \"\${$as_ac_Header+set}\" = set"; then
5232 echo $ECHO_N "(cached) $ECHO_C" >&6
5234 cat >"conftest.$ac_ext" <<_ACEOF
5235 #line 5235 "configure"
5236 #include "confdefs.h"
5237 #include <$ac_header>
5239 if { (eval echo "$as_me:5239: \"$ac_cpp "conftest.$ac_ext"\"") >&5
5240 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
5242 $EGREP -v '^ *\+' conftest.er1 >conftest.err
5244 cat conftest.err >&5
5245 echo "$as_me:5245: \$? = $ac_status" >&5
5246 (exit "$ac_status"); } >/dev/null; then
5247 if test -s conftest.err; then
5248 ac_cpp_err=$ac_c_preproc_warn_flag
5255 if test -z "$ac_cpp_err"; then
5256 eval "$as_ac_Header=yes"
5258 echo "$as_me: failed program was:" >&5
5259 cat "conftest.$ac_ext" >&5
5260 eval "$as_ac_Header=no"
5262 rm -f conftest.err "conftest.$ac_ext"
5264 echo "$as_me:5264: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
5265 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
5266 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
5267 cat >>confdefs.h <<EOF
5268 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
5274 cat >>confdefs.h <<\EOF
5278 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
5280 cat >>confdefs.h <<EOF
5281 #define $cf_nculib_ROOT 1
5284 cf_cv_ncurses_version="`$NCURSES_CONFIG --version`"
5288 cf_ncuhdr_root=ncurses
5290 test -n "$cf_cv_curses_dir" && \
5291 test "$cf_cv_curses_dir" != "no" && { \
5293 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
5294 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
5296 while test "$cf_add_incdir" != /usr/include
5298 if test -d "$cf_add_incdir"
5301 if test -n "$CFLAGS$CPPFLAGS" ; then
5302 # a loop is needed to ensure we can add subdirs of existing dirs
5303 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
5304 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
5305 cf_have_incdir=yes; break
5310 if test "$cf_have_incdir" = no ; then
5311 if test "$cf_add_incdir" = /usr/local/include ; then
5312 if test "$GCC" = yes
5314 cf_save_CPPFLAGS=$CPPFLAGS
5316 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5317 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
5319 cat >"conftest.$ac_ext" <<_ACEOF
5320 #line 5320 "configure"
5321 #include "confdefs.h"
5331 rm -f "conftest.$ac_objext"
5332 if { (eval echo "$as_me:5332: \"$ac_compile\"") >&5
5333 (eval $ac_compile) 2>&5
5335 echo "$as_me:5335: \$? = $ac_status" >&5
5336 (exit "$ac_status"); } &&
5337 { ac_try='test -s "conftest.$ac_objext"'
5338 { (eval echo "$as_me:5338: \"$ac_try\"") >&5
5341 echo "$as_me:5341: \$? = $ac_status" >&5
5342 (exit "$ac_status"); }; }; then
5345 echo "$as_me: failed program was:" >&5
5346 cat "conftest.$ac_ext" >&5
5349 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5350 CPPFLAGS=$cf_save_CPPFLAGS
5355 if test "$cf_have_incdir" = no ; then
5356 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
5358 echo "${as_me:-configure}:5358: testing adding $cf_add_incdir to include-path ..." 1>&5
5360 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
5362 cf_top_incdir=`echo "$cf_add_incdir" | sed -e 's%/include/.*$%/include%'`
5363 test "$cf_top_incdir" = "$cf_add_incdir" && break
5364 cf_add_incdir="$cf_top_incdir"
5377 echo "$as_me:5377: checking for $cf_ncuhdr_root header in include-path" >&5
5378 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
5379 if test "${cf_cv_ncurses_h+set}" = set; then
5380 echo $ECHO_N "(cached) $ECHO_C" >&6
5383 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
5384 { test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw; } && cf_header_list="$cf_header_list curses.h ncurses.h"
5385 for cf_header in $cf_header_list
5388 cat >"conftest.$ac_ext" <<_ACEOF
5389 #line 5389 "configure"
5390 #include "confdefs.h"
5392 #include <$cf_header>
5397 #ifdef NCURSES_VERSION
5399 printf("%s\\n", NCURSES_VERSION);
5412 rm -f "conftest.$ac_objext"
5413 if { (eval echo "$as_me:5413: \"$ac_compile\"") >&5
5414 (eval $ac_compile) 2>&5
5416 echo "$as_me:5416: \$? = $ac_status" >&5
5417 (exit "$ac_status"); } &&
5418 { ac_try='test -s "conftest.$ac_objext"'
5419 { (eval echo "$as_me:5419: \"$ac_try\"") >&5
5422 echo "$as_me:5422: \$? = $ac_status" >&5
5423 (exit "$ac_status"); }; }; then
5424 cf_cv_ncurses_h=$cf_header
5427 echo "$as_me: failed program was:" >&5
5428 cat "conftest.$ac_ext" >&5
5431 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5433 test "$cf_cv_ncurses_h" != no && break
5437 echo "$as_me:5437: result: $cf_cv_ncurses_h" >&5
5438 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
5440 if test "$cf_cv_ncurses_h" != no ; then
5441 cf_cv_ncurses_header=$cf_cv_ncurses_h
5444 echo "$as_me:5444: checking for $cf_ncuhdr_root include-path" >&5
5445 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
5446 if test "${cf_cv_ncurses_h2+set}" = set; then
5447 echo $ECHO_N "(cached) $ECHO_C" >&6
5450 test -n "$verbose" && echo
5454 # collect the current set of include-directories from compiler flags
5455 cf_header_path_list=""
5456 if test -n "${CFLAGS}${CPPFLAGS}" ; then
5457 for cf_header_path in $CPPFLAGS $CFLAGS
5459 case "$cf_header_path" in
5461 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
5463 test "x$cf_header_path" != "xNONE" && \
5464 test -d "$cf_header_path" && \
5466 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
5467 test -d "$cf_header_path/include" && cf_search="$cf_search $cf_header_path/include"
5468 test -d "$cf_header_path/include/$cf_ncuhdr_root" && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
5469 test -d "$cf_header_path/include/$cf_ncuhdr_root/include" && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
5470 test -d "$cf_header_path/$cf_ncuhdr_root/include" && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
5471 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"
5474 cf_header_path_list="$cf_header_path_list $cf_search"
5480 # add the variations for the package we are looking for
5484 test "x$prefix" != "xNONE" && \
5485 test -d "$prefix" && \
5487 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
5488 test -d "$prefix/include" && cf_search="$cf_search $prefix/include"
5489 test -d "$prefix/include/$cf_ncuhdr_root" && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
5490 test -d "$prefix/include/$cf_ncuhdr_root/include" && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
5491 test -d "$prefix/$cf_ncuhdr_root/include" && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
5492 test -d "$prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root" && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
5495 for cf_subdir_prefix in \
5504 test "x$cf_subdir_prefix" != "x$prefix" && \
5505 test -d "$cf_subdir_prefix" && \
5506 { test -z "$prefix" || test "x$prefix" = xNONE || test "x$cf_subdir_prefix" != "x$prefix"; } && {
5507 test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
5508 test -d "$cf_subdir_prefix/include" && cf_search="$cf_search $cf_subdir_prefix/include"
5509 test -d "$cf_subdir_prefix/include/$cf_ncuhdr_root" && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root"
5510 test -d "$cf_subdir_prefix/include/$cf_ncuhdr_root/include" && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root/include"
5511 test -d "$cf_subdir_prefix/$cf_ncuhdr_root/include" && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include"
5512 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"
5517 test "$includedir" != NONE && \
5518 test "$includedir" != "/usr/include" && \
5519 test -d "$includedir" && {
5520 test -d "$includedir" && cf_search="$cf_search $includedir"
5521 test -d "$includedir/$cf_ncuhdr_root" && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
5524 test "$oldincludedir" != NONE && \
5525 test "$oldincludedir" != "/usr/include" && \
5526 test -d "$oldincludedir" && {
5527 test -d "$oldincludedir" && cf_search="$cf_search $oldincludedir"
5528 test -d "$oldincludedir/$cf_ncuhdr_root" && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
5531 cf_search="$cf_search $cf_header_path_list"
5533 test -n "$verbose" && echo "search path $cf_search"
5534 cf_save2_CPPFLAGS="$CPPFLAGS"
5535 for cf_incdir in $cf_search
5538 if test -n "$cf_incdir" ; then
5539 for cf_add_incdir in $cf_incdir
5541 while test "$cf_add_incdir" != /usr/include
5543 if test -d "$cf_add_incdir"
5546 if test -n "$CFLAGS$CPPFLAGS" ; then
5547 # a loop is needed to ensure we can add subdirs of existing dirs
5548 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
5549 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
5550 cf_have_incdir=yes; break
5555 if test "$cf_have_incdir" = no ; then
5556 if test "$cf_add_incdir" = /usr/local/include ; then
5557 if test "$GCC" = yes
5559 cf_save_CPPFLAGS=$CPPFLAGS
5561 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5562 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
5564 cat >"conftest.$ac_ext" <<_ACEOF
5565 #line 5565 "configure"
5566 #include "confdefs.h"
5576 rm -f "conftest.$ac_objext"
5577 if { (eval echo "$as_me:5577: \"$ac_compile\"") >&5
5578 (eval $ac_compile) 2>&5
5580 echo "$as_me:5580: \$? = $ac_status" >&5
5581 (exit "$ac_status"); } &&
5582 { ac_try='test -s "conftest.$ac_objext"'
5583 { (eval echo "$as_me:5583: \"$ac_try\"") >&5
5586 echo "$as_me:5586: \$? = $ac_status" >&5
5587 (exit "$ac_status"); }; }; then
5590 echo "$as_me: failed program was:" >&5
5591 cat "conftest.$ac_ext" >&5
5594 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5595 CPPFLAGS=$cf_save_CPPFLAGS
5600 if test "$cf_have_incdir" = no ; then
5601 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
5603 echo "${as_me:-configure}:5603: testing adding $cf_add_incdir to include-path ..." 1>&5
5605 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
5607 cf_top_incdir=`echo "$cf_add_incdir" | sed -e 's%/include/.*$%/include%'`
5608 test "$cf_top_incdir" = "$cf_add_incdir" && break
5609 cf_add_incdir="$cf_top_incdir"
5625 cat >"conftest.$ac_ext" <<_ACEOF
5626 #line 5626 "configure"
5627 #include "confdefs.h"
5629 #include <$cf_header>
5634 #ifdef NCURSES_VERSION
5636 printf("%s\\n", NCURSES_VERSION);
5649 rm -f "conftest.$ac_objext"
5650 if { (eval echo "$as_me:5650: \"$ac_compile\"") >&5
5651 (eval $ac_compile) 2>&5
5653 echo "$as_me:5653: \$? = $ac_status" >&5
5654 (exit "$ac_status"); } &&
5655 { ac_try='test -s "conftest.$ac_objext"'
5656 { (eval echo "$as_me:5656: \"$ac_try\"") >&5
5659 echo "$as_me:5659: \$? = $ac_status" >&5
5660 (exit "$ac_status"); }; }; then
5661 cf_cv_ncurses_h2=$cf_header
5664 echo "$as_me: failed program was:" >&5
5665 cat "conftest.$ac_ext" >&5
5668 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5670 if test "$cf_cv_ncurses_h2" != no ; then
5671 cf_cv_ncurses_h2=$cf_incdir/$cf_header
5672 test -n "$verbose" && echo $ECHO_N " ... found $ECHO_C" 1>&6
5675 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
5677 CPPFLAGS="$cf_save2_CPPFLAGS"
5678 test "$cf_cv_ncurses_h2" != no && break
5680 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:5680: error: not found" >&5
5681 echo "$as_me: error: not found" >&2;}
5682 { (exit 1); exit 1; }; }
5685 echo "$as_me:5685: result: $cf_cv_ncurses_h2" >&5
5686 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
5688 cf_1st_incdir=`echo "$cf_cv_ncurses_h2" | sed -e 's%/[^/]*$%%'`
5689 cf_cv_ncurses_header="`basename "$cf_cv_ncurses_h2"`"
5690 if test "`basename "$cf_1st_incdir"`" = "$cf_ncuhdr_root" ; then
5691 cf_cv_ncurses_header="$cf_ncuhdr_root/$cf_cv_ncurses_header"
5694 if test -n "$cf_1st_incdir" ; then
5695 for cf_add_incdir in $cf_1st_incdir
5697 while test "$cf_add_incdir" != /usr/include
5699 if test -d "$cf_add_incdir"
5702 if test -n "$CFLAGS$CPPFLAGS" ; then
5703 # a loop is needed to ensure we can add subdirs of existing dirs
5704 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
5705 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
5706 cf_have_incdir=yes; break
5711 if test "$cf_have_incdir" = no ; then
5712 if test "$cf_add_incdir" = /usr/local/include ; then
5713 if test "$GCC" = yes
5715 cf_save_CPPFLAGS=$CPPFLAGS
5717 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5718 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
5720 cat >"conftest.$ac_ext" <<_ACEOF
5721 #line 5721 "configure"
5722 #include "confdefs.h"
5732 rm -f "conftest.$ac_objext"
5733 if { (eval echo "$as_me:5733: \"$ac_compile\"") >&5
5734 (eval $ac_compile) 2>&5
5736 echo "$as_me:5736: \$? = $ac_status" >&5
5737 (exit "$ac_status"); } &&
5738 { ac_try='test -s "conftest.$ac_objext"'
5739 { (eval echo "$as_me:5739: \"$ac_try\"") >&5
5742 echo "$as_me:5742: \$? = $ac_status" >&5
5743 (exit "$ac_status"); }; }; then
5746 echo "$as_me: failed program was:" >&5
5747 cat "conftest.$ac_ext" >&5
5750 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5751 CPPFLAGS=$cf_save_CPPFLAGS
5756 if test "$cf_have_incdir" = no ; then
5757 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
5759 echo "${as_me:-configure}:5759: testing adding $cf_add_incdir to include-path ..." 1>&5
5761 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
5763 cf_top_incdir=`echo "$cf_add_incdir" | sed -e 's%/include/.*$%/include%'`
5764 test "$cf_top_incdir" = "$cf_add_incdir" && break
5765 cf_add_incdir="$cf_top_incdir"
5778 # Set definitions to allow ifdef'ing for ncurses.h
5780 case "$cf_cv_ncurses_header" in
5783 cat >>confdefs.h <<\EOF
5784 #define HAVE_NCURSES_H 1
5790 case "$cf_cv_ncurses_header" in
5791 (ncurses/curses.h|ncurses/ncurses.h)
5793 cat >>confdefs.h <<\EOF
5794 #define HAVE_NCURSES_NCURSES_H 1
5798 (ncursesw/curses.h|ncursesw/ncurses.h)
5800 cat >>confdefs.h <<\EOF
5801 #define HAVE_NCURSESW_NCURSES_H 1
5807 echo "$as_me:5807: checking for terminfo header" >&5
5808 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
5809 if test "${cf_cv_term_header+set}" = set; then
5810 echo $ECHO_N "(cached) $ECHO_C" >&6
5813 case "${cf_cv_ncurses_header}" in
5814 (*/ncurses.h|*/ncursesw.h)
5815 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
5818 cf_term_header=term.h
5822 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
5824 cat >"conftest.$ac_ext" <<_ACEOF
5825 #line 5825 "configure"
5826 #include "confdefs.h"
5828 #include <${cf_cv_ncurses_header:-curses.h}>
5834 int x = auto_left_margin; (void)x
5839 rm -f "conftest.$ac_objext"
5840 if { (eval echo "$as_me:5840: \"$ac_compile\"") >&5
5841 (eval $ac_compile) 2>&5
5843 echo "$as_me:5843: \$? = $ac_status" >&5
5844 (exit "$ac_status"); } &&
5845 { ac_try='test -s "conftest.$ac_objext"'
5846 { (eval echo "$as_me:5846: \"$ac_try\"") >&5
5849 echo "$as_me:5849: \$? = $ac_status" >&5
5850 (exit "$ac_status"); }; }; then
5852 cf_cv_term_header="$cf_test"
5854 echo "$as_me: failed program was:" >&5
5855 cat "conftest.$ac_ext" >&5
5857 cf_cv_term_header=unknown
5860 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5861 test "$cf_cv_term_header" != unknown && break
5865 echo "$as_me:5865: result: $cf_cv_term_header" >&5
5866 echo "${ECHO_T}$cf_cv_term_header" >&6
5868 # Set definitions to allow ifdef'ing to accommodate subdirectories
5870 case "$cf_cv_term_header" in
5873 cat >>confdefs.h <<\EOF
5874 #define HAVE_TERM_H 1
5880 case "$cf_cv_term_header" in
5883 cat >>confdefs.h <<\EOF
5884 #define HAVE_NCURSES_TERM_H 1
5890 cat >>confdefs.h <<\EOF
5891 #define HAVE_NCURSESW_TERM_H 1
5897 # some applications need this, but should check for NCURSES_VERSION
5899 cat >>confdefs.h <<\EOF
5903 echo "$as_me:5903: checking for ncurses version" >&5
5904 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
5905 if test "${cf_cv_ncurses_version+set}" = set; then
5906 echo $ECHO_N "(cached) $ECHO_C" >&6
5909 cf_cv_ncurses_version=no
5911 rm -f "$cf_tempfile"
5912 if test "$cross_compiling" = yes; then
5914 # This will not work if the preprocessor splits the line after the
5915 # Autoconf token. The 'unproto' program does that.
5916 cat > "conftest.$ac_ext" <<EOF
5917 #include <${cf_cv_ncurses_header:-curses.h}>
5919 #ifdef NCURSES_VERSION
5920 Autoconf NCURSES_VERSION
5928 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
5929 { (eval echo "$as_me:5929: \"$cf_try\"") >&5
5932 echo "$as_me:5932: \$? = $ac_status" >&5
5933 (exit "$ac_status"); }
5934 if test -f conftest.out ; then
5935 cf_out=`sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%' conftest.out`
5936 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
5941 cat >"conftest.$ac_ext" <<_ACEOF
5942 #line 5942 "configure"
5943 #include "confdefs.h"
5945 #include <${cf_cv_ncurses_header:-curses.h}>
5949 FILE *fp = fopen("$cf_tempfile", "w");
5950 #ifdef NCURSES_VERSION
5951 # ifdef NCURSES_VERSION_PATCH
5952 fprintf(fp, "%s.%d\\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
5954 fprintf(fp, "%s\\n", NCURSES_VERSION);
5958 fprintf(fp, "old\\n");
5963 ${cf_cv_main_return:-return}(0);
5966 rm -f "conftest$ac_exeext"
5967 if { (eval echo "$as_me:5967: \"$ac_link\"") >&5
5968 (eval $ac_link) 2>&5
5970 echo "$as_me:5970: \$? = $ac_status" >&5
5971 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
5972 { (eval echo "$as_me:5972: \"$ac_try\"") >&5
5975 echo "$as_me:5975: \$? = $ac_status" >&5
5976 (exit "$ac_status"); }; }; then
5978 cf_cv_ncurses_version=`cat $cf_tempfile`
5980 echo "$as_me: program exited with status $ac_status" >&5
5981 echo "$as_me: failed program was:" >&5
5982 cat "conftest.$ac_ext" >&5
5984 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
5986 rm -f "$cf_tempfile"
5989 echo "$as_me:5989: result: $cf_cv_ncurses_version" >&5
5990 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
5991 test "$cf_cv_ncurses_version" = no ||
5992 cat >>confdefs.h <<\EOF
5996 cf_nculib_root=ncurses
5997 # This works, except for the special case where we find gpm, but
5998 # ncurses is in a nonstandard location via $LIBS, and we really want
6001 cf_ncurses_SAVE="$LIBS"
6002 echo "$as_me:6002: checking for Gpm_Open in -lgpm" >&5
6003 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
6004 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
6005 echo $ECHO_N "(cached) $ECHO_C" >&6
6007 ac_check_lib_save_LIBS=$LIBS
6009 cat >"conftest.$ac_ext" <<_ACEOF
6010 #line 6010 "configure"
6011 #include "confdefs.h"
6013 /* Override any gcc2 internal prototype to avoid an error. */
6017 /* We use char because int might match the return type of a gcc2
6018 builtin and then its argument prototype would still apply. */
6028 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
6029 if { (eval echo "$as_me:6029: \"$ac_link\"") >&5
6030 (eval $ac_link) 2>&5
6032 echo "$as_me:6032: \$? = $ac_status" >&5
6033 (exit "$ac_status"); } &&
6034 { ac_try='test -s "conftest$ac_exeext"'
6035 { (eval echo "$as_me:6035: \"$ac_try\"") >&5
6038 echo "$as_me:6038: \$? = $ac_status" >&5
6039 (exit "$ac_status"); }; }; then
6040 ac_cv_lib_gpm_Gpm_Open=yes
6042 echo "$as_me: failed program was:" >&5
6043 cat "conftest.$ac_ext" >&5
6044 ac_cv_lib_gpm_Gpm_Open=no
6046 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
6047 LIBS=$ac_check_lib_save_LIBS
6049 echo "$as_me:6049: result: $ac_cv_lib_gpm_Gpm_Open" >&5
6050 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
6051 if test "$ac_cv_lib_gpm_Gpm_Open" = yes; then
6052 echo "$as_me:6052: checking for initscr in -lgpm" >&5
6053 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
6054 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
6055 echo $ECHO_N "(cached) $ECHO_C" >&6
6057 ac_check_lib_save_LIBS=$LIBS
6059 cat >"conftest.$ac_ext" <<_ACEOF
6060 #line 6060 "configure"
6061 #include "confdefs.h"
6063 /* Override any gcc2 internal prototype to avoid an error. */
6067 /* We use char because int might match the return type of a gcc2
6068 builtin and then its argument prototype would still apply. */
6078 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
6079 if { (eval echo "$as_me:6079: \"$ac_link\"") >&5
6080 (eval $ac_link) 2>&5
6082 echo "$as_me:6082: \$? = $ac_status" >&5
6083 (exit "$ac_status"); } &&
6084 { ac_try='test -s "conftest$ac_exeext"'
6085 { (eval echo "$as_me:6085: \"$ac_try\"") >&5
6088 echo "$as_me:6088: \$? = $ac_status" >&5
6089 (exit "$ac_status"); }; }; then
6090 ac_cv_lib_gpm_initscr=yes
6092 echo "$as_me: failed program was:" >&5
6093 cat "conftest.$ac_ext" >&5
6094 ac_cv_lib_gpm_initscr=no
6096 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
6097 LIBS=$ac_check_lib_save_LIBS
6099 echo "$as_me:6099: result: $ac_cv_lib_gpm_initscr" >&5
6100 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
6101 if test "$ac_cv_lib_gpm_initscr" = yes; then
6102 LIBS="$cf_ncurses_SAVE"
6104 cf_ncurses_LIBS="-lgpm"
6111 # This is only necessary if you are linking against an obsolete
6112 # version of ncurses (but it should do no harm, since it's static).
6113 if test "$cf_nculib_root" = ncurses ; then
6114 echo "$as_me:6114: checking for tgoto in -lmytinfo" >&5
6115 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
6116 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
6117 echo $ECHO_N "(cached) $ECHO_C" >&6
6119 ac_check_lib_save_LIBS=$LIBS
6120 LIBS="-lmytinfo $LIBS"
6121 cat >"conftest.$ac_ext" <<_ACEOF
6122 #line 6122 "configure"
6123 #include "confdefs.h"
6125 /* Override any gcc2 internal prototype to avoid an error. */
6129 /* We use char because int might match the return type of a gcc2
6130 builtin and then its argument prototype would still apply. */
6140 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
6141 if { (eval echo "$as_me:6141: \"$ac_link\"") >&5
6142 (eval $ac_link) 2>&5
6144 echo "$as_me:6144: \$? = $ac_status" >&5
6145 (exit "$ac_status"); } &&
6146 { ac_try='test -s "conftest$ac_exeext"'
6147 { (eval echo "$as_me:6147: \"$ac_try\"") >&5
6150 echo "$as_me:6150: \$? = $ac_status" >&5
6151 (exit "$ac_status"); }; }; then
6152 ac_cv_lib_mytinfo_tgoto=yes
6154 echo "$as_me: failed program was:" >&5
6155 cat "conftest.$ac_ext" >&5
6156 ac_cv_lib_mytinfo_tgoto=no
6158 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
6159 LIBS=$ac_check_lib_save_LIBS
6161 echo "$as_me:6161: result: $ac_cv_lib_mytinfo_tgoto" >&5
6162 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
6163 if test "$ac_cv_lib_mytinfo_tgoto" = yes; then
6164 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
6174 for cf_add_1lib in $cf_ncurses_LIBS; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
6176 for cf_add_1lib in $cf_add_0lib; do
6177 for cf_add_2lib in $cf_add_libs; do
6178 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
6183 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
6187 if test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no"
6193 for cf_add_1lib in -l$cf_nculib_root; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
6195 for cf_add_1lib in $cf_add_0lib; do
6196 for cf_add_2lib in $cf_add_libs; do
6197 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
6202 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
6208 eval 'cf_cv_have_lib_'"$cf_nculib_root"'=no'
6210 echo "$as_me:6210: checking for initscr" >&5
6211 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
6212 if test "${ac_cv_func_initscr+set}" = set; then
6213 echo $ECHO_N "(cached) $ECHO_C" >&6
6215 cat >"conftest.$ac_ext" <<_ACEOF
6216 #line 6216 "configure"
6217 #include "confdefs.h"
6218 #define initscr autoconf_temporary
6219 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
6226 /* We use char because int might match the return type of a gcc2
6227 builtin and then its argument prototype would still apply. */
6228 char initscr (void);
6234 /* The GNU C library defines stubs for functions which it implements
6235 to always fail with ENOSYS. Some functions are actually named
6236 something starting with __ and the normal name is an alias. */
6237 #if defined (__stub_initscr) || defined (__stub___initscr)
6238 #error found stub for initscr
6246 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
6247 if { (eval echo "$as_me:6247: \"$ac_link\"") >&5
6248 (eval $ac_link) 2>&5
6250 echo "$as_me:6250: \$? = $ac_status" >&5
6251 (exit "$ac_status"); } &&
6252 { ac_try='test -s "conftest$ac_exeext"'
6253 { (eval echo "$as_me:6253: \"$ac_try\"") >&5
6256 echo "$as_me:6256: \$? = $ac_status" >&5
6257 (exit "$ac_status"); }; }; then
6258 ac_cv_func_initscr=yes
6260 echo "$as_me: failed program was:" >&5
6261 cat "conftest.$ac_ext" >&5
6262 ac_cv_func_initscr=no
6264 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
6266 echo "$as_me:6266: result: $ac_cv_func_initscr" >&5
6267 echo "${ECHO_T}$ac_cv_func_initscr" >&6
6268 if test "$ac_cv_func_initscr" = yes; then
6269 eval 'cf_cv_have_lib_'"$cf_nculib_root"'=yes'
6272 cf_save_LIBS="$LIBS"
6273 echo "$as_me:6273: checking for initscr in -l$cf_nculib_root" >&5
6274 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
6275 LIBS="-l$cf_nculib_root $LIBS"
6276 cat >"conftest.$ac_ext" <<_ACEOF
6277 #line 6277 "configure"
6278 #include "confdefs.h"
6279 #include <${cf_cv_ncurses_header:-curses.h}>
6288 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
6289 if { (eval echo "$as_me:6289: \"$ac_link\"") >&5
6290 (eval $ac_link) 2>&5
6292 echo "$as_me:6292: \$? = $ac_status" >&5
6293 (exit "$ac_status"); } &&
6294 { ac_try='test -s "conftest$ac_exeext"'
6295 { (eval echo "$as_me:6295: \"$ac_try\"") >&5
6298 echo "$as_me:6298: \$? = $ac_status" >&5
6299 (exit "$ac_status"); }; }; then
6300 echo "$as_me:6300: result: yes" >&5
6301 echo "${ECHO_T}yes" >&6
6302 eval 'cf_cv_have_lib_'"$cf_nculib_root"'=yes'
6305 echo "$as_me: failed program was:" >&5
6306 cat "conftest.$ac_ext" >&5
6307 echo "$as_me:6307: result: no" >&5
6308 echo "${ECHO_T}no" >&6
6311 cf_library_path_list=""
6312 if test -n "${LDFLAGS}${LIBS}" ; then
6313 for cf_library_path in $LDFLAGS $LIBS
6315 case "$cf_library_path" in
6317 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
6319 test "x$cf_library_path" != "xNONE" && \
6320 test -d "$cf_library_path" && \
6322 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
6323 test -d "$cf_library_path/lib" && cf_search="$cf_search $cf_library_path/lib"
6324 test -d "$cf_library_path/lib/$cf_nculib_root" && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
6325 test -d "$cf_library_path/lib/$cf_nculib_root/lib" && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
6326 test -d "$cf_library_path/$cf_nculib_root/lib" && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
6327 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"
6330 cf_library_path_list="$cf_library_path_list $cf_search"
6338 test "x$prefix" != "xNONE" && \
6339 test -d "$prefix" && \
6341 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
6342 test -d "$prefix/lib" && cf_search="$cf_search $prefix/lib"
6343 test -d "$prefix/lib/$cf_nculib_root" && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
6344 test -d "$prefix/lib/$cf_nculib_root/lib" && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
6345 test -d "$prefix/$cf_nculib_root/lib" && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
6346 test -d "$prefix/$cf_nculib_root/lib/$cf_nculib_root" && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
6349 for cf_subdir_prefix in \
6358 test "x$cf_subdir_prefix" != "x$prefix" && \
6359 test -d "$cf_subdir_prefix" && \
6360 { test -z "$prefix" || test "x$prefix" = xNONE || test "x$cf_subdir_prefix" != "x$prefix"; } && {
6361 test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
6362 test -d "$cf_subdir_prefix/lib" && cf_search="$cf_search $cf_subdir_prefix/lib"
6363 test -d "$cf_subdir_prefix/lib/$cf_nculib_root" && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root"
6364 test -d "$cf_subdir_prefix/lib/$cf_nculib_root/lib" && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root/lib"
6365 test -d "$cf_subdir_prefix/$cf_nculib_root/lib" && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib"
6366 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"
6371 cf_search="$cf_library_path_list $cf_search"
6373 for cf_libdir in $cf_search
6375 echo "$as_me:6375: checking for -l$cf_nculib_root in $cf_libdir" >&5
6376 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
6377 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
6378 cat >"conftest.$ac_ext" <<_ACEOF
6379 #line 6379 "configure"
6380 #include "confdefs.h"
6381 #include <${cf_cv_ncurses_header:-curses.h}>
6390 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
6391 if { (eval echo "$as_me:6391: \"$ac_link\"") >&5
6392 (eval $ac_link) 2>&5
6394 echo "$as_me:6394: \$? = $ac_status" >&5
6395 (exit "$ac_status"); } &&
6396 { ac_try='test -s "conftest$ac_exeext"'
6397 { (eval echo "$as_me:6397: \"$ac_try\"") >&5
6400 echo "$as_me:6400: \$? = $ac_status" >&5
6401 (exit "$ac_status"); }; }; then
6402 echo "$as_me:6402: result: yes" >&5
6403 echo "${ECHO_T}yes" >&6
6404 eval 'cf_cv_have_lib_'"$cf_nculib_root"'=yes'
6407 echo "$as_me: failed program was:" >&5
6408 cat "conftest.$ac_ext" >&5
6409 echo "$as_me:6409: result: no" >&5
6410 echo "${ECHO_T}no" >&6
6411 LIBS="$cf_save_LIBS"
6413 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
6417 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
6421 eval 'cf_found_library="$cf_cv_have_lib_'"$cf_nculib_root"\"
6423 if test "$cf_found_library" = no ; then
6424 { { echo "$as_me:6424: error: Cannot link $cf_nculib_root library" >&5
6425 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
6426 { (exit 1); exit 1; }; }
6431 if test -n "$cf_ncurses_LIBS" ; then
6432 echo "$as_me:6432: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
6433 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
6434 cf_ncurses_SAVE="$LIBS"
6435 for p in $cf_ncurses_LIBS ; do
6436 q=`echo "$LIBS" | sed -e "s%$p %%" -e "s%$p$%%"`
6437 if test "$q" != "$LIBS" ; then
6441 cat >"conftest.$ac_ext" <<_ACEOF
6442 #line 6442 "configure"
6443 #include "confdefs.h"
6444 #include <${cf_cv_ncurses_header:-curses.h}>
6448 initscr(); mousemask(0,0); tigetstr((char *)0);
6453 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
6454 if { (eval echo "$as_me:6454: \"$ac_link\"") >&5
6455 (eval $ac_link) 2>&5
6457 echo "$as_me:6457: \$? = $ac_status" >&5
6458 (exit "$ac_status"); } &&
6459 { ac_try='test -s "conftest$ac_exeext"'
6460 { (eval echo "$as_me:6460: \"$ac_try\"") >&5
6463 echo "$as_me:6463: \$? = $ac_status" >&5
6464 (exit "$ac_status"); }; }; then
6465 echo "$as_me:6465: result: yes" >&5
6466 echo "${ECHO_T}yes" >&6
6468 echo "$as_me: failed program was:" >&5
6469 cat "conftest.$ac_ext" >&5
6470 echo "$as_me:6470: result: no" >&5
6471 echo "${ECHO_T}no" >&6
6472 LIBS="$cf_ncurses_SAVE"
6474 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
6477 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
6479 cat >>confdefs.h <<EOF
6480 #define $cf_nculib_ROOT 1
6488 echo "$as_me:6488: checking if you want wide-character code" >&5
6489 echo $ECHO_N "checking if you want wide-character code... $ECHO_C" >&6
6491 # Check whether --enable-widec or --disable-widec was given.
6492 if test "${enable_widec+set}" = set; then
6493 enableval="$enable_widec"
6494 with_widec=$enableval
6498 echo "$as_me:6498: result: $with_widec" >&5
6499 echo "${ECHO_T}$with_widec" >&6
6500 if test "$with_widec" = yes ; then
6502 for ac_header in wchar.h
6504 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6505 echo "$as_me:6505: checking for $ac_header" >&5
6506 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6507 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6508 echo $ECHO_N "(cached) $ECHO_C" >&6
6510 cat >"conftest.$ac_ext" <<_ACEOF
6511 #line 6511 "configure"
6512 #include "confdefs.h"
6513 #include <$ac_header>
6515 if { (eval echo "$as_me:6515: \"$ac_cpp "conftest.$ac_ext"\"") >&5
6516 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
6518 $EGREP -v '^ *\+' conftest.er1 >conftest.err
6520 cat conftest.err >&5
6521 echo "$as_me:6521: \$? = $ac_status" >&5
6522 (exit "$ac_status"); } >/dev/null; then
6523 if test -s conftest.err; then
6524 ac_cpp_err=$ac_c_preproc_warn_flag
6531 if test -z "$ac_cpp_err"; then
6532 eval "$as_ac_Header=yes"
6534 echo "$as_me: failed program was:" >&5
6535 cat "conftest.$ac_ext" >&5
6536 eval "$as_ac_Header=no"
6538 rm -f conftest.err "conftest.$ac_ext"
6540 echo "$as_me:6540: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
6541 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
6542 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
6543 cat >>confdefs.h <<EOF
6544 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6550 echo "$as_me:6550: checking for multibyte character support" >&5
6551 echo $ECHO_N "checking for multibyte character support... $ECHO_C" >&6
6552 if test "${cf_cv_utf8_lib+set}" = set; then
6553 echo $ECHO_N "(cached) $ECHO_C" >&6
6556 cf_save_LIBS="$LIBS"
6557 cat >"conftest.$ac_ext" <<_ACEOF
6558 #line 6558 "configure"
6559 #include "confdefs.h"
6575 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
6576 if { (eval echo "$as_me:6576: \"$ac_link\"") >&5
6577 (eval $ac_link) 2>&5
6579 echo "$as_me:6579: \$? = $ac_status" >&5
6580 (exit "$ac_status"); } &&
6581 { ac_try='test -s "conftest$ac_exeext"'
6582 { (eval echo "$as_me:6582: \"$ac_try\"") >&5
6585 echo "$as_me:6585: \$? = $ac_status" >&5
6586 (exit "$ac_status"); }; }; then
6589 echo "$as_me: failed program was:" >&5
6590 cat "conftest.$ac_ext" >&5
6592 # If the linkage is not already in the $CPPFLAGS/$LDFLAGS configuration, these
6593 # will be set on completion of the AC_TRY_LINK below.
6594 cf_cv_header_path_utf8=
6595 cf_cv_library_path_utf8=
6597 echo "${as_me:-configure}:6597: testing Starting FIND_LINKAGE(utf8,) ..." 1>&5
6599 cf_save_LIBS="$LIBS"
6601 cat >"conftest.$ac_ext" <<_ACEOF
6602 #line 6602 "configure"
6603 #include "confdefs.h"
6605 #include <libutf8.h>
6614 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
6615 if { (eval echo "$as_me:6615: \"$ac_link\"") >&5
6616 (eval $ac_link) 2>&5
6618 echo "$as_me:6618: \$? = $ac_status" >&5
6619 (exit "$ac_status"); } &&
6620 { ac_try='test -s "conftest$ac_exeext"'
6621 { (eval echo "$as_me:6621: \"$ac_try\"") >&5
6624 echo "$as_me:6624: \$? = $ac_status" >&5
6625 (exit "$ac_status"); }; }; then
6627 cf_cv_find_linkage_utf8=yes
6628 cf_cv_header_path_utf8=/usr/include
6629 cf_cv_library_path_utf8=/usr/lib
6632 echo "$as_me: failed program was:" >&5
6633 cat "conftest.$ac_ext" >&5
6635 LIBS="-lutf8 $cf_save_LIBS"
6637 cat >"conftest.$ac_ext" <<_ACEOF
6638 #line 6638 "configure"
6639 #include "confdefs.h"
6641 #include <libutf8.h>
6650 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
6651 if { (eval echo "$as_me:6651: \"$ac_link\"") >&5
6652 (eval $ac_link) 2>&5
6654 echo "$as_me:6654: \$? = $ac_status" >&5
6655 (exit "$ac_status"); } &&
6656 { ac_try='test -s "conftest$ac_exeext"'
6657 { (eval echo "$as_me:6657: \"$ac_try\"") >&5
6660 echo "$as_me:6660: \$? = $ac_status" >&5
6661 (exit "$ac_status"); }; }; then
6663 cf_cv_find_linkage_utf8=yes
6664 cf_cv_header_path_utf8=/usr/include
6665 cf_cv_library_path_utf8=/usr/lib
6666 cf_cv_library_file_utf8="-lutf8"
6669 echo "$as_me: failed program was:" >&5
6670 cat "conftest.$ac_ext" >&5
6672 cf_cv_find_linkage_utf8=no
6673 LIBS="$cf_save_LIBS"
6675 test -n "$verbose" && echo " find linkage for utf8 library" 1>&6
6677 echo "${as_me:-configure}:6677: testing find linkage for utf8 library ..." 1>&5
6679 echo "${as_me:-configure}:6679: testing Searching for headers in FIND_LINKAGE(utf8,) ..." 1>&5
6681 cf_save_CPPFLAGS="$CPPFLAGS"
6682 cf_test_CPPFLAGS="$CPPFLAGS"
6686 # collect the current set of include-directories from compiler flags
6687 cf_header_path_list=""
6688 if test -n "${CFLAGS}${CPPFLAGS}" ; then
6689 for cf_header_path in $CPPFLAGS $CFLAGS
6691 case "$cf_header_path" in
6693 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
6695 test "x$cf_header_path" != "xNONE" && \
6696 test -d "$cf_header_path" && \
6698 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
6699 test -d "$cf_header_path/include" && cf_search="$cf_search $cf_header_path/include"
6700 test -d "$cf_header_path/include/utf8" && cf_search="$cf_search $cf_header_path/include/utf8"
6701 test -d "$cf_header_path/include/utf8/include" && cf_search="$cf_search $cf_header_path/include/utf8/include"
6702 test -d "$cf_header_path/utf8/include" && cf_search="$cf_search $cf_header_path/utf8/include"
6703 test -d "$cf_header_path/utf8/include/utf8" && cf_search="$cf_search $cf_header_path/utf8/include/utf8"
6706 cf_header_path_list="$cf_header_path_list $cf_search"
6712 # add the variations for the package we are looking for
6716 test "x$prefix" != "xNONE" && \
6717 test -d "$prefix" && \
6719 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
6720 test -d "$prefix/include" && cf_search="$cf_search $prefix/include"
6721 test -d "$prefix/include/utf8" && cf_search="$cf_search $prefix/include/utf8"
6722 test -d "$prefix/include/utf8/include" && cf_search="$cf_search $prefix/include/utf8/include"
6723 test -d "$prefix/utf8/include" && cf_search="$cf_search $prefix/utf8/include"
6724 test -d "$prefix/utf8/include/utf8" && cf_search="$cf_search $prefix/utf8/include/utf8"
6727 for cf_subdir_prefix in \
6736 test "x$cf_subdir_prefix" != "x$prefix" && \
6737 test -d "$cf_subdir_prefix" && \
6738 { test -z "$prefix" || test "x$prefix" = xNONE || test "x$cf_subdir_prefix" != "x$prefix"; } && {
6739 test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
6740 test -d "$cf_subdir_prefix/include" && cf_search="$cf_search $cf_subdir_prefix/include"
6741 test -d "$cf_subdir_prefix/include/utf8" && cf_search="$cf_search $cf_subdir_prefix/include/utf8"
6742 test -d "$cf_subdir_prefix/include/utf8/include" && cf_search="$cf_search $cf_subdir_prefix/include/utf8/include"
6743 test -d "$cf_subdir_prefix/utf8/include" && cf_search="$cf_search $cf_subdir_prefix/utf8/include"
6744 test -d "$cf_subdir_prefix/utf8/include/utf8" && cf_search="$cf_search $cf_subdir_prefix/utf8/include/utf8"
6749 test "$includedir" != NONE && \
6750 test "$includedir" != "/usr/include" && \
6751 test -d "$includedir" && {
6752 test -d "$includedir" && cf_search="$cf_search $includedir"
6753 test -d "$includedir/utf8" && cf_search="$cf_search $includedir/utf8"
6756 test "$oldincludedir" != NONE && \
6757 test "$oldincludedir" != "/usr/include" && \
6758 test -d "$oldincludedir" && {
6759 test -d "$oldincludedir" && cf_search="$cf_search $oldincludedir"
6760 test -d "$oldincludedir/utf8" && cf_search="$cf_search $oldincludedir/utf8"
6763 cf_search="$cf_search $cf_header_path_list"
6765 for cf_cv_header_path_utf8 in $cf_search
6767 if test -d "$cf_cv_header_path_utf8" ; then
6768 test -n "$verbose" && echo " ... testing $cf_cv_header_path_utf8" 1>&6
6770 echo "${as_me:-configure}:6770: testing ... testing $cf_cv_header_path_utf8 ..." 1>&5
6772 CPPFLAGS="$cf_save_CPPFLAGS"
6774 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
6775 CPPFLAGS="${CPPFLAGS}-I$cf_cv_header_path_utf8"
6777 cat >"conftest.$ac_ext" <<_ACEOF
6778 #line 6778 "configure"
6779 #include "confdefs.h"
6781 #include <libutf8.h>
6790 rm -f "conftest.$ac_objext"
6791 if { (eval echo "$as_me:6791: \"$ac_compile\"") >&5
6792 (eval $ac_compile) 2>&5
6794 echo "$as_me:6794: \$? = $ac_status" >&5
6795 (exit "$ac_status"); } &&
6796 { ac_try='test -s "conftest.$ac_objext"'
6797 { (eval echo "$as_me:6797: \"$ac_try\"") >&5
6800 echo "$as_me:6800: \$? = $ac_status" >&5
6801 (exit "$ac_status"); }; }; then
6803 test -n "$verbose" && echo " ... found utf8 headers in $cf_cv_header_path_utf8" 1>&6
6805 echo "${as_me:-configure}:6805: testing ... found utf8 headers in $cf_cv_header_path_utf8 ..." 1>&5
6807 cf_cv_find_linkage_utf8=maybe
6808 cf_test_CPPFLAGS="$CPPFLAGS"
6811 echo "$as_me: failed program was:" >&5
6812 cat "conftest.$ac_ext" >&5
6814 CPPFLAGS="$cf_save_CPPFLAGS"
6817 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
6821 if test "$cf_cv_find_linkage_utf8" = maybe ; then
6823 echo "${as_me:-configure}:6823: testing Searching for utf8 library in FIND_LINKAGE(utf8,) ..." 1>&5
6825 cf_save_LIBS="$LIBS"
6826 cf_save_LDFLAGS="$LDFLAGS"
6828 if test "$cf_cv_find_linkage_utf8" != yes ; then
6831 cf_library_path_list=""
6832 if test -n "${LDFLAGS}${LIBS}" ; then
6833 for cf_library_path in $LDFLAGS $LIBS
6835 case "$cf_library_path" in
6837 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
6839 test "x$cf_library_path" != "xNONE" && \
6840 test -d "$cf_library_path" && \
6842 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
6843 test -d "$cf_library_path/lib" && cf_search="$cf_search $cf_library_path/lib"
6844 test -d "$cf_library_path/lib/utf8" && cf_search="$cf_search $cf_library_path/lib/utf8"
6845 test -d "$cf_library_path/lib/utf8/lib" && cf_search="$cf_search $cf_library_path/lib/utf8/lib"
6846 test -d "$cf_library_path/utf8/lib" && cf_search="$cf_search $cf_library_path/utf8/lib"
6847 test -d "$cf_library_path/utf8/lib/utf8" && cf_search="$cf_search $cf_library_path/utf8/lib/utf8"
6850 cf_library_path_list="$cf_library_path_list $cf_search"
6858 test "x$prefix" != "xNONE" && \
6859 test -d "$prefix" && \
6861 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
6862 test -d "$prefix/lib" && cf_search="$cf_search $prefix/lib"
6863 test -d "$prefix/lib/utf8" && cf_search="$cf_search $prefix/lib/utf8"
6864 test -d "$prefix/lib/utf8/lib" && cf_search="$cf_search $prefix/lib/utf8/lib"
6865 test -d "$prefix/utf8/lib" && cf_search="$cf_search $prefix/utf8/lib"
6866 test -d "$prefix/utf8/lib/utf8" && cf_search="$cf_search $prefix/utf8/lib/utf8"
6869 for cf_subdir_prefix in \
6878 test "x$cf_subdir_prefix" != "x$prefix" && \
6879 test -d "$cf_subdir_prefix" && \
6880 { test -z "$prefix" || test "x$prefix" = xNONE || test "x$cf_subdir_prefix" != "x$prefix"; } && {
6881 test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
6882 test -d "$cf_subdir_prefix/lib" && cf_search="$cf_search $cf_subdir_prefix/lib"
6883 test -d "$cf_subdir_prefix/lib/utf8" && cf_search="$cf_search $cf_subdir_prefix/lib/utf8"
6884 test -d "$cf_subdir_prefix/lib/utf8/lib" && cf_search="$cf_search $cf_subdir_prefix/lib/utf8/lib"
6885 test -d "$cf_subdir_prefix/utf8/lib" && cf_search="$cf_search $cf_subdir_prefix/utf8/lib"
6886 test -d "$cf_subdir_prefix/utf8/lib/utf8" && cf_search="$cf_search $cf_subdir_prefix/utf8/lib/utf8"
6891 cf_search="$cf_library_path_list $cf_search"
6893 for cf_cv_library_path_utf8 in $cf_search
6895 if test -d "$cf_cv_library_path_utf8" ; then
6896 test -n "$verbose" && echo " ... testing $cf_cv_library_path_utf8" 1>&6
6898 echo "${as_me:-configure}:6898: testing ... testing $cf_cv_library_path_utf8 ..." 1>&5
6900 CPPFLAGS="$cf_test_CPPFLAGS"
6901 LIBS="-lutf8 $cf_save_LIBS"
6902 LDFLAGS="$cf_save_LDFLAGS -L$cf_cv_library_path_utf8"
6903 cat >"conftest.$ac_ext" <<_ACEOF
6904 #line 6904 "configure"
6905 #include "confdefs.h"
6907 #include <libutf8.h>
6916 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
6917 if { (eval echo "$as_me:6917: \"$ac_link\"") >&5
6918 (eval $ac_link) 2>&5
6920 echo "$as_me:6920: \$? = $ac_status" >&5
6921 (exit "$ac_status"); } &&
6922 { ac_try='test -s "conftest$ac_exeext"'
6923 { (eval echo "$as_me:6923: \"$ac_try\"") >&5
6926 echo "$as_me:6926: \$? = $ac_status" >&5
6927 (exit "$ac_status"); }; }; then
6929 test -n "$verbose" && echo " ... found utf8 library in $cf_cv_library_path_utf8" 1>&6
6931 echo "${as_me:-configure}:6931: testing ... found utf8 library in $cf_cv_library_path_utf8 ..." 1>&5
6933 cf_cv_find_linkage_utf8=yes
6934 cf_cv_library_file_utf8="-lutf8"
6937 echo "$as_me: failed program was:" >&5
6938 cat "conftest.$ac_ext" >&5
6940 CPPFLAGS="$cf_save_CPPFLAGS"
6941 LIBS="$cf_save_LIBS"
6942 LDFLAGS="$cf_save_LDFLAGS"
6945 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
6948 CPPFLAGS="$cf_save_CPPFLAGS"
6949 LDFLAGS="$cf_save_LDFLAGS"
6953 cf_cv_find_linkage_utf8=no
6957 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
6960 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
6962 LIBS="$cf_save_LIBS"
6964 if test "$cf_cv_find_linkage_utf8" = yes ; then
6965 cf_cv_utf8_lib=add-on
6971 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
6973 echo "$as_me:6973: result: $cf_cv_utf8_lib" >&5
6974 echo "${ECHO_T}$cf_cv_utf8_lib" >&6
6976 # HAVE_LIBUTF8_H is used by ncurses if curses.h is shared between
6978 if test "$cf_cv_utf8_lib" = "add-on" ; then
6980 cat >>confdefs.h <<\EOF
6981 #define HAVE_LIBUTF8_H 1
6984 if test -n "$cf_cv_header_path_utf8" ; then
6985 for cf_add_incdir in $cf_cv_header_path_utf8
6987 while test "$cf_add_incdir" != /usr/include
6989 if test -d "$cf_add_incdir"
6992 if test -n "$CFLAGS$CPPFLAGS" ; then
6993 # a loop is needed to ensure we can add subdirs of existing dirs
6994 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
6995 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
6996 cf_have_incdir=yes; break
7001 if test "$cf_have_incdir" = no ; then
7002 if test "$cf_add_incdir" = /usr/local/include ; then
7003 if test "$GCC" = yes
7005 cf_save_CPPFLAGS=$CPPFLAGS
7007 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
7008 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
7010 cat >"conftest.$ac_ext" <<_ACEOF
7011 #line 7011 "configure"
7012 #include "confdefs.h"
7022 rm -f "conftest.$ac_objext"
7023 if { (eval echo "$as_me:7023: \"$ac_compile\"") >&5
7024 (eval $ac_compile) 2>&5
7026 echo "$as_me:7026: \$? = $ac_status" >&5
7027 (exit "$ac_status"); } &&
7028 { ac_try='test -s "conftest.$ac_objext"'
7029 { (eval echo "$as_me:7029: \"$ac_try\"") >&5
7032 echo "$as_me:7032: \$? = $ac_status" >&5
7033 (exit "$ac_status"); }; }; then
7036 echo "$as_me: failed program was:" >&5
7037 cat "conftest.$ac_ext" >&5
7040 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
7041 CPPFLAGS=$cf_save_CPPFLAGS
7046 if test "$cf_have_incdir" = no ; then
7047 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
7049 echo "${as_me:-configure}:7049: testing adding $cf_add_incdir to include-path ..." 1>&5
7051 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7053 cf_top_incdir=`echo "$cf_add_incdir" | sed -e 's%/include/.*$%/include%'`
7054 test "$cf_top_incdir" = "$cf_add_incdir" && break
7055 cf_add_incdir="$cf_top_incdir"
7066 if test -n "$cf_cv_library_path_utf8" ; then
7067 for cf_add_libdir in $cf_cv_library_path_utf8
7069 if test "$cf_add_libdir" = /usr/lib ; then
7071 elif test -d "$cf_add_libdir"
7074 if test -n "$LDFLAGS$LIBS" ; then
7075 # a loop is needed to ensure we can add subdirs of existing dirs
7076 for cf_test_libdir in $LDFLAGS $LIBS ; do
7077 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
7078 cf_have_libdir=yes; break
7082 if test "$cf_have_libdir" = no ; then
7083 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
7085 echo "${as_me:-configure}:7085: testing adding $cf_add_libdir to library-path ..." 1>&5
7087 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
7096 for cf_add_1lib in $cf_cv_library_file_utf8; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
7098 for cf_add_1lib in $cf_add_0lib; do
7099 for cf_add_2lib in $cf_add_libs; do
7100 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
7105 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
7111 cf_ncuconfig_root=ncursesw
7112 cf_have_ncuconfig=no
7114 if test "x${PKG_CONFIG:=none}" != xnone; then
7115 echo "$as_me:7115: checking pkg-config for $cf_ncuconfig_root" >&5
7116 echo $ECHO_N "checking pkg-config for $cf_ncuconfig_root... $ECHO_C" >&6
7117 if "$PKG_CONFIG" --exists $cf_ncuconfig_root ; then
7118 echo "$as_me:7118: result: yes" >&5
7119 echo "${ECHO_T}yes" >&6
7121 echo "$as_me:7121: checking if the $cf_ncuconfig_root package files work" >&5
7122 echo $ECHO_N "checking if the $cf_ncuconfig_root package files work... $ECHO_C" >&6
7123 cf_have_ncuconfig=unknown
7125 cf_save_CFLAGS="$CFLAGS"
7126 cf_save_CPPFLAGS="$CPPFLAGS"
7127 cf_save_LIBS="$LIBS"
7129 cf_pkg_cflags="`$PKG_CONFIG --cflags $cf_ncuconfig_root`"
7130 cf_pkg_libs="`$PKG_CONFIG --libs $cf_ncuconfig_root`"
7132 # while -W for passing linker flags is prevalent, it is not "standard".
7133 # At least one wrapper for c89/c99 (in Apple's xcode) has its own
7134 # incompatible _and_ non-standard -W option which gives an error. Work
7135 # around that pitfall.
7136 case "x${CC}@@${cf_pkg_libs}@${cf_pkg_cflags}" in
7142 cf_new_extra_cppflags=
7144 for cf_add_cflags in $cf_pkg_cflags
7146 case "$cf_fix_cppflags" in
7148 case "$cf_add_cflags" in
7149 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
7150 case "$cf_add_cflags" in
7152 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
7154 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
7155 && test -z "${cf_tst_cflags}" \
7156 && cf_fix_cppflags=yes
7158 if test "$cf_fix_cppflags" = yes ; then
7160 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
7161 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
7164 elif test "${cf_tst_cflags}" = "\"'" ; then
7166 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
7167 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
7177 case "$cf_add_cflags" in
7179 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
7181 CPPFLAGS=`echo "$CPPFLAGS" | \
7182 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
7183 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
7188 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
7189 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
7196 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
7197 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
7204 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
7205 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
7207 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
7209 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
7210 && test -z "${cf_tst_cflags}" \
7211 && cf_fix_cppflags=no
7216 if test -n "$cf_new_cflags" ; then
7218 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
7219 CFLAGS="${CFLAGS}$cf_new_cflags"
7223 if test -n "$cf_new_cppflags" ; then
7225 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
7226 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
7230 if test -n "$cf_new_extra_cppflags" ; then
7232 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
7233 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
7240 for cf_add_1lib in $cf_pkg_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
7242 for cf_add_1lib in $cf_add_0lib; do
7243 for cf_add_2lib in $cf_add_libs; do
7244 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
7249 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
7253 cat >"conftest.$ac_ext" <<_ACEOF
7254 #line 7254 "configure"
7255 #include "confdefs.h"
7256 #include <${cf_cv_ncurses_header:-curses.h}>
7260 initscr(); mousemask(0,0); tigetstr((char *)0);
7265 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
7266 if { (eval echo "$as_me:7266: \"$ac_link\"") >&5
7267 (eval $ac_link) 2>&5
7269 echo "$as_me:7269: \$? = $ac_status" >&5
7270 (exit "$ac_status"); } &&
7271 { ac_try='test -s "conftest$ac_exeext"'
7272 { (eval echo "$as_me:7272: \"$ac_try\"") >&5
7275 echo "$as_me:7275: \$? = $ac_status" >&5
7276 (exit "$ac_status"); }; }; then
7277 if test "$cross_compiling" = yes; then
7278 cf_test_ncuconfig=maybe
7280 cat >"conftest.$ac_ext" <<_ACEOF
7281 #line 7281 "configure"
7282 #include "confdefs.h"
7283 #include <${cf_cv_ncurses_header:-curses.h}>
7285 { const char *xx = curses_version(); return (xx == 0); }
7287 rm -f "conftest$ac_exeext"
7288 if { (eval echo "$as_me:7288: \"$ac_link\"") >&5
7289 (eval $ac_link) 2>&5
7291 echo "$as_me:7291: \$? = $ac_status" >&5
7292 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
7293 { (eval echo "$as_me:7293: \"$ac_try\"") >&5
7296 echo "$as_me:7296: \$? = $ac_status" >&5
7297 (exit "$ac_status"); }; }; then
7298 cf_test_ncuconfig=yes
7300 echo "$as_me: program exited with status $ac_status" >&5
7301 echo "$as_me: failed program was:" >&5
7302 cat "conftest.$ac_ext" >&5
7303 cf_test_ncuconfig=no
7305 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
7308 echo "$as_me: failed program was:" >&5
7309 cat "conftest.$ac_ext" >&5
7310 cf_test_ncuconfig=no
7312 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
7314 CFLAGS="$cf_save_CFLAGS"
7315 CPPFLAGS="$cf_save_CPPFLAGS"
7316 LIBS="$cf_save_LIBS"
7318 if test "x$cf_test_ncuconfig" != xyes; then
7319 cf_temp=`echo "x$cf_pkg_cflags" | sed -e s/^x// -e 's/-W[^ ]*//g'`
7320 cf_pkg_cflags="$cf_temp"
7321 cf_temp=`echo "x$cf_pkg_libs" | sed -e s/^x// -e 's/-W[^ ]*//g'`
7322 cf_pkg_libs="$cf_temp"
7330 cf_new_extra_cppflags=
7332 for cf_add_cflags in $cf_pkg_cflags
7334 case "$cf_fix_cppflags" in
7336 case "$cf_add_cflags" in
7337 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
7338 case "$cf_add_cflags" in
7340 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
7342 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
7343 && test -z "${cf_tst_cflags}" \
7344 && cf_fix_cppflags=yes
7346 if test "$cf_fix_cppflags" = yes ; then
7348 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
7349 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
7352 elif test "${cf_tst_cflags}" = "\"'" ; then
7354 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
7355 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
7365 case "$cf_add_cflags" in
7367 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
7369 CPPFLAGS=`echo "$CPPFLAGS" | \
7370 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
7371 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
7376 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
7377 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
7384 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
7385 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
7392 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
7393 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
7395 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
7397 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
7398 && test -z "${cf_tst_cflags}" \
7399 && cf_fix_cppflags=no
7404 if test -n "$cf_new_cflags" ; then
7406 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
7407 CFLAGS="${CFLAGS}$cf_new_cflags"
7411 if test -n "$cf_new_cppflags" ; then
7413 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
7414 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
7418 if test -n "$cf_new_extra_cppflags" ; then
7420 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
7421 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
7428 for cf_add_1lib in $cf_pkg_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
7430 for cf_add_1lib in $cf_add_0lib; do
7431 for cf_add_2lib in $cf_add_libs; do
7432 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
7437 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
7441 cat >"conftest.$ac_ext" <<_ACEOF
7442 #line 7442 "configure"
7443 #include "confdefs.h"
7444 #include <${cf_cv_ncurses_header:-curses.h}>
7448 initscr(); mousemask(0,0); tigetstr((char *)0);
7453 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
7454 if { (eval echo "$as_me:7454: \"$ac_link\"") >&5
7455 (eval $ac_link) 2>&5
7457 echo "$as_me:7457: \$? = $ac_status" >&5
7458 (exit "$ac_status"); } &&
7459 { ac_try='test -s "conftest$ac_exeext"'
7460 { (eval echo "$as_me:7460: \"$ac_try\"") >&5
7463 echo "$as_me:7463: \$? = $ac_status" >&5
7464 (exit "$ac_status"); }; }; then
7465 if test "$cross_compiling" = yes; then
7466 cf_have_ncuconfig=maybe
7468 cat >"conftest.$ac_ext" <<_ACEOF
7469 #line 7469 "configure"
7470 #include "confdefs.h"
7471 #include <${cf_cv_ncurses_header:-curses.h}>
7473 { const char *xx = curses_version(); return (xx == 0); }
7475 rm -f "conftest$ac_exeext"
7476 if { (eval echo "$as_me:7476: \"$ac_link\"") >&5
7477 (eval $ac_link) 2>&5
7479 echo "$as_me:7479: \$? = $ac_status" >&5
7480 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
7481 { (eval echo "$as_me:7481: \"$ac_try\"") >&5
7484 echo "$as_me:7484: \$? = $ac_status" >&5
7485 (exit "$ac_status"); }; }; then
7486 cf_have_ncuconfig=yes
7488 echo "$as_me: program exited with status $ac_status" >&5
7489 echo "$as_me: failed program was:" >&5
7490 cat "conftest.$ac_ext" >&5
7491 cf_have_ncuconfig=no
7493 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
7496 echo "$as_me: failed program was:" >&5
7497 cat "conftest.$ac_ext" >&5
7498 cf_have_ncuconfig=no
7500 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
7501 echo "$as_me:7501: result: $cf_have_ncuconfig" >&5
7502 echo "${ECHO_T}$cf_have_ncuconfig" >&6
7503 test "$cf_have_ncuconfig" = maybe && cf_have_ncuconfig=yes
7504 if test "$cf_have_ncuconfig" != "yes"
7506 CPPFLAGS="$cf_save_CPPFLAGS"
7507 LIBS="$cf_save_LIBS"
7508 NCURSES_CONFIG_PKG=none
7511 cat >>confdefs.h <<\EOF
7515 NCURSES_CONFIG_PKG=$cf_ncuconfig_root
7517 echo "$as_me:7517: checking for terminfo header" >&5
7518 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
7519 if test "${cf_cv_term_header+set}" = set; then
7520 echo $ECHO_N "(cached) $ECHO_C" >&6
7523 case "${cf_cv_ncurses_header}" in
7524 (*/ncurses.h|*/ncursesw.h)
7525 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
7528 cf_term_header=term.h
7532 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
7534 cat >"conftest.$ac_ext" <<_ACEOF
7535 #line 7535 "configure"
7536 #include "confdefs.h"
7538 #include <${cf_cv_ncurses_header:-curses.h}>
7544 int x = auto_left_margin; (void)x
7549 rm -f "conftest.$ac_objext"
7550 if { (eval echo "$as_me:7550: \"$ac_compile\"") >&5
7551 (eval $ac_compile) 2>&5
7553 echo "$as_me:7553: \$? = $ac_status" >&5
7554 (exit "$ac_status"); } &&
7555 { ac_try='test -s "conftest.$ac_objext"'
7556 { (eval echo "$as_me:7556: \"$ac_try\"") >&5
7559 echo "$as_me:7559: \$? = $ac_status" >&5
7560 (exit "$ac_status"); }; }; then
7562 cf_cv_term_header="$cf_test"
7564 echo "$as_me: failed program was:" >&5
7565 cat "conftest.$ac_ext" >&5
7567 cf_cv_term_header=unknown
7570 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
7571 test "$cf_cv_term_header" != unknown && break
7575 echo "$as_me:7575: result: $cf_cv_term_header" >&5
7576 echo "${ECHO_T}$cf_cv_term_header" >&6
7578 # Set definitions to allow ifdef'ing to accommodate subdirectories
7580 case "$cf_cv_term_header" in
7583 cat >>confdefs.h <<\EOF
7584 #define HAVE_TERM_H 1
7590 case "$cf_cv_term_header" in
7593 cat >>confdefs.h <<\EOF
7594 #define HAVE_NCURSES_TERM_H 1
7600 cat >>confdefs.h <<\EOF
7601 #define HAVE_NCURSESW_TERM_H 1
7610 echo "$as_me:7610: result: no" >&5
7611 echo "${ECHO_T}no" >&6
7612 NCURSES_CONFIG_PKG=none
7615 NCURSES_CONFIG_PKG=none
7618 if test "x$cf_have_ncuconfig" = "xno"; then
7619 cf_ncurses_config="${cf_ncuconfig_root}${NCURSES_CONFIG_SUFFIX}-config"; echo "Looking for ${cf_ncurses_config}"
7621 if test -n "$ac_tool_prefix"; then
7622 for ac_prog in ${cf_ncurses_config} ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
7624 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
7625 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
7626 echo "$as_me:7626: checking for $ac_word" >&5
7627 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7628 if test "${ac_cv_prog_NCURSES_CONFIG+set}" = set; then
7629 echo $ECHO_N "(cached) $ECHO_C" >&6
7631 if test -n "$NCURSES_CONFIG"; then
7632 ac_cv_prog_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test.
7634 ac_save_IFS=$IFS; IFS=$ac_path_separator
7636 for ac_dir in $ac_dummy; do
7638 test -z "$ac_dir" && ac_dir=.
7639 $as_executable_p "$ac_dir/$ac_word" || continue
7640 ac_cv_prog_NCURSES_CONFIG="$ac_tool_prefix$ac_prog"
7641 echo "$as_me:7641: found $ac_dir/$ac_word" >&5
7647 NCURSES_CONFIG=$ac_cv_prog_NCURSES_CONFIG
7648 if test -n "$NCURSES_CONFIG"; then
7649 echo "$as_me:7649: result: $NCURSES_CONFIG" >&5
7650 echo "${ECHO_T}$NCURSES_CONFIG" >&6
7652 echo "$as_me:7652: result: no" >&5
7653 echo "${ECHO_T}no" >&6
7656 test -n "$NCURSES_CONFIG" && break
7659 if test -z "$NCURSES_CONFIG"; then
7660 ac_ct_NCURSES_CONFIG=$NCURSES_CONFIG
7661 for ac_prog in ${cf_ncurses_config} ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
7663 # Extract the first word of "$ac_prog", so it can be a program name with args.
7664 set dummy $ac_prog; ac_word=$2
7665 echo "$as_me:7665: checking for $ac_word" >&5
7666 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7667 if test "${ac_cv_prog_ac_ct_NCURSES_CONFIG+set}" = set; then
7668 echo $ECHO_N "(cached) $ECHO_C" >&6
7670 if test -n "$ac_ct_NCURSES_CONFIG"; then
7671 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_ct_NCURSES_CONFIG" # Let the user override the test.
7673 ac_save_IFS=$IFS; IFS=$ac_path_separator
7675 for ac_dir in $ac_dummy; do
7677 test -z "$ac_dir" && ac_dir=.
7678 $as_executable_p "$ac_dir/$ac_word" || continue
7679 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_prog"
7680 echo "$as_me:7680: found $ac_dir/$ac_word" >&5
7686 ac_ct_NCURSES_CONFIG=$ac_cv_prog_ac_ct_NCURSES_CONFIG
7687 if test -n "$ac_ct_NCURSES_CONFIG"; then
7688 echo "$as_me:7688: result: $ac_ct_NCURSES_CONFIG" >&5
7689 echo "${ECHO_T}$ac_ct_NCURSES_CONFIG" >&6
7691 echo "$as_me:7691: result: no" >&5
7692 echo "${ECHO_T}no" >&6
7695 test -n "$ac_ct_NCURSES_CONFIG" && break
7697 test -n "$ac_ct_NCURSES_CONFIG" || ac_ct_NCURSES_CONFIG="none"
7699 NCURSES_CONFIG=$ac_ct_NCURSES_CONFIG
7702 if test "$NCURSES_CONFIG" != none ; then
7707 cf_new_extra_cppflags=
7709 for cf_add_cflags in `$NCURSES_CONFIG --cflags`
7711 case "$cf_fix_cppflags" in
7713 case "$cf_add_cflags" in
7714 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
7715 case "$cf_add_cflags" in
7717 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
7719 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
7720 && test -z "${cf_tst_cflags}" \
7721 && cf_fix_cppflags=yes
7723 if test "$cf_fix_cppflags" = yes ; then
7725 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
7726 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
7729 elif test "${cf_tst_cflags}" = "\"'" ; then
7731 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
7732 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
7742 case "$cf_add_cflags" in
7744 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
7746 CPPFLAGS=`echo "$CPPFLAGS" | \
7747 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
7748 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
7753 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
7754 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
7761 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
7762 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
7769 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
7770 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
7772 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
7774 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
7775 && test -z "${cf_tst_cflags}" \
7776 && cf_fix_cppflags=no
7781 if test -n "$cf_new_cflags" ; then
7783 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
7784 CFLAGS="${CFLAGS}$cf_new_cflags"
7788 if test -n "$cf_new_cppflags" ; then
7790 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
7791 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
7795 if test -n "$cf_new_extra_cppflags" ; then
7797 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
7798 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
7805 for cf_add_1lib in `$NCURSES_CONFIG --libs`; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
7807 for cf_add_1lib in $cf_add_0lib; do
7808 for cf_add_2lib in $cf_add_libs; do
7809 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
7814 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
7818 # even with config script, some packages use no-override for curses.h
7820 echo "$as_me:7820: checking if we have identified curses headers" >&5
7821 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
7822 if test "${cf_cv_ncurses_header+set}" = set; then
7823 echo $ECHO_N "(cached) $ECHO_C" >&6
7826 cf_cv_ncurses_header=none
7828 ncurses.h ncursesw/ncurses.h \
7829 curses.h ncursesw/curses.h
7831 cat >"conftest.$ac_ext" <<_ACEOF
7832 #line 7832 "configure"
7833 #include "confdefs.h"
7834 #include <${cf_header}>
7838 initscr(); tgoto("?", 0,0)
7843 rm -f "conftest.$ac_objext"
7844 if { (eval echo "$as_me:7844: \"$ac_compile\"") >&5
7845 (eval $ac_compile) 2>&5
7847 echo "$as_me:7847: \$? = $ac_status" >&5
7848 (exit "$ac_status"); } &&
7849 { ac_try='test -s "conftest.$ac_objext"'
7850 { (eval echo "$as_me:7850: \"$ac_try\"") >&5
7853 echo "$as_me:7853: \$? = $ac_status" >&5
7854 (exit "$ac_status"); }; }; then
7855 cf_cv_ncurses_header=$cf_header; break
7857 echo "$as_me: failed program was:" >&5
7858 cat "conftest.$ac_ext" >&5
7860 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
7864 echo "$as_me:7864: result: $cf_cv_ncurses_header" >&5
7865 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
7867 if test "$cf_cv_ncurses_header" = none ; then
7868 { { echo "$as_me:7868: error: No curses header-files found" >&5
7869 echo "$as_me: error: No curses header-files found" >&2;}
7870 { (exit 1); exit 1; }; }
7873 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
7875 for ac_header in $cf_cv_ncurses_header
7877 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7878 echo "$as_me:7878: checking for $ac_header" >&5
7879 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7880 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7881 echo $ECHO_N "(cached) $ECHO_C" >&6
7883 cat >"conftest.$ac_ext" <<_ACEOF
7884 #line 7884 "configure"
7885 #include "confdefs.h"
7886 #include <$ac_header>
7888 if { (eval echo "$as_me:7888: \"$ac_cpp "conftest.$ac_ext"\"") >&5
7889 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
7891 $EGREP -v '^ *\+' conftest.er1 >conftest.err
7893 cat conftest.err >&5
7894 echo "$as_me:7894: \$? = $ac_status" >&5
7895 (exit "$ac_status"); } >/dev/null; then
7896 if test -s conftest.err; then
7897 ac_cpp_err=$ac_c_preproc_warn_flag
7904 if test -z "$ac_cpp_err"; then
7905 eval "$as_ac_Header=yes"
7907 echo "$as_me: failed program was:" >&5
7908 cat "conftest.$ac_ext" >&5
7909 eval "$as_ac_Header=no"
7911 rm -f conftest.err "conftest.$ac_ext"
7913 echo "$as_me:7913: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
7914 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
7915 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
7916 cat >>confdefs.h <<EOF
7917 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7923 cat >>confdefs.h <<\EOF
7927 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
7929 cat >>confdefs.h <<EOF
7930 #define $cf_nculib_ROOT 1
7933 cf_cv_ncurses_version="`$NCURSES_CONFIG --version`"
7937 cf_ncuhdr_root=ncursesw
7939 test -n "$cf_cv_curses_dir" && \
7940 test "$cf_cv_curses_dir" != "no" && { \
7942 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
7943 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
7945 while test "$cf_add_incdir" != /usr/include
7947 if test -d "$cf_add_incdir"
7950 if test -n "$CFLAGS$CPPFLAGS" ; then
7951 # a loop is needed to ensure we can add subdirs of existing dirs
7952 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
7953 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
7954 cf_have_incdir=yes; break
7959 if test "$cf_have_incdir" = no ; then
7960 if test "$cf_add_incdir" = /usr/local/include ; then
7961 if test "$GCC" = yes
7963 cf_save_CPPFLAGS=$CPPFLAGS
7965 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
7966 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
7968 cat >"conftest.$ac_ext" <<_ACEOF
7969 #line 7969 "configure"
7970 #include "confdefs.h"
7980 rm -f "conftest.$ac_objext"
7981 if { (eval echo "$as_me:7981: \"$ac_compile\"") >&5
7982 (eval $ac_compile) 2>&5
7984 echo "$as_me:7984: \$? = $ac_status" >&5
7985 (exit "$ac_status"); } &&
7986 { ac_try='test -s "conftest.$ac_objext"'
7987 { (eval echo "$as_me:7987: \"$ac_try\"") >&5
7990 echo "$as_me:7990: \$? = $ac_status" >&5
7991 (exit "$ac_status"); }; }; then
7994 echo "$as_me: failed program was:" >&5
7995 cat "conftest.$ac_ext" >&5
7998 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
7999 CPPFLAGS=$cf_save_CPPFLAGS
8004 if test "$cf_have_incdir" = no ; then
8005 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
8007 echo "${as_me:-configure}:8007: testing adding $cf_add_incdir to include-path ..." 1>&5
8009 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8011 cf_top_incdir=`echo "$cf_add_incdir" | sed -e 's%/include/.*$%/include%'`
8012 test "$cf_top_incdir" = "$cf_add_incdir" && break
8013 cf_add_incdir="$cf_top_incdir"
8026 echo "$as_me:8026: checking for $cf_ncuhdr_root header in include-path" >&5
8027 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
8028 if test "${cf_cv_ncurses_h+set}" = set; then
8029 echo $ECHO_N "(cached) $ECHO_C" >&6
8032 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
8033 { test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw; } && cf_header_list="$cf_header_list curses.h ncurses.h"
8034 for cf_header in $cf_header_list
8037 cat >"conftest.$ac_ext" <<_ACEOF
8038 #line 8038 "configure"
8039 #include "confdefs.h"
8041 #define _XOPEN_SOURCE_EXTENDED
8042 #undef HAVE_LIBUTF8_H /* in case we used CF_UTF8_LIB */
8043 #define HAVE_LIBUTF8_H /* to force ncurses' header file to use cchar_t */
8045 #include <$cf_header>
8050 #ifdef NCURSES_VERSION
8056 printf("%s\\n", NCURSES_VERSION);
8069 rm -f "conftest.$ac_objext"
8070 if { (eval echo "$as_me:8070: \"$ac_compile\"") >&5
8071 (eval $ac_compile) 2>&5
8073 echo "$as_me:8073: \$? = $ac_status" >&5
8074 (exit "$ac_status"); } &&
8075 { ac_try='test -s "conftest.$ac_objext"'
8076 { (eval echo "$as_me:8076: \"$ac_try\"") >&5
8079 echo "$as_me:8079: \$? = $ac_status" >&5
8080 (exit "$ac_status"); }; }; then
8081 cf_cv_ncurses_h=$cf_header
8084 echo "$as_me: failed program was:" >&5
8085 cat "conftest.$ac_ext" >&5
8088 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
8090 test "$cf_cv_ncurses_h" != no && break
8094 echo "$as_me:8094: result: $cf_cv_ncurses_h" >&5
8095 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
8097 if test "$cf_cv_ncurses_h" != no ; then
8098 cf_cv_ncurses_header=$cf_cv_ncurses_h
8101 echo "$as_me:8101: checking for $cf_ncuhdr_root include-path" >&5
8102 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
8103 if test "${cf_cv_ncurses_h2+set}" = set; then
8104 echo $ECHO_N "(cached) $ECHO_C" >&6
8107 test -n "$verbose" && echo
8111 # collect the current set of include-directories from compiler flags
8112 cf_header_path_list=""
8113 if test -n "${CFLAGS}${CPPFLAGS}" ; then
8114 for cf_header_path in $CPPFLAGS $CFLAGS
8116 case "$cf_header_path" in
8118 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
8120 test "x$cf_header_path" != "xNONE" && \
8121 test -d "$cf_header_path" && \
8123 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
8124 test -d "$cf_header_path/include" && cf_search="$cf_search $cf_header_path/include"
8125 test -d "$cf_header_path/include/$cf_ncuhdr_root" && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
8126 test -d "$cf_header_path/include/$cf_ncuhdr_root/include" && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
8127 test -d "$cf_header_path/$cf_ncuhdr_root/include" && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
8128 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"
8131 cf_header_path_list="$cf_header_path_list $cf_search"
8137 # add the variations for the package we are looking for
8141 test "x$prefix" != "xNONE" && \
8142 test -d "$prefix" && \
8144 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
8145 test -d "$prefix/include" && cf_search="$cf_search $prefix/include"
8146 test -d "$prefix/include/$cf_ncuhdr_root" && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
8147 test -d "$prefix/include/$cf_ncuhdr_root/include" && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
8148 test -d "$prefix/$cf_ncuhdr_root/include" && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
8149 test -d "$prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root" && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
8152 for cf_subdir_prefix in \
8161 test "x$cf_subdir_prefix" != "x$prefix" && \
8162 test -d "$cf_subdir_prefix" && \
8163 { test -z "$prefix" || test "x$prefix" = xNONE || test "x$cf_subdir_prefix" != "x$prefix"; } && {
8164 test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
8165 test -d "$cf_subdir_prefix/include" && cf_search="$cf_search $cf_subdir_prefix/include"
8166 test -d "$cf_subdir_prefix/include/$cf_ncuhdr_root" && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root"
8167 test -d "$cf_subdir_prefix/include/$cf_ncuhdr_root/include" && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root/include"
8168 test -d "$cf_subdir_prefix/$cf_ncuhdr_root/include" && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include"
8169 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"
8174 test "$includedir" != NONE && \
8175 test "$includedir" != "/usr/include" && \
8176 test -d "$includedir" && {
8177 test -d "$includedir" && cf_search="$cf_search $includedir"
8178 test -d "$includedir/$cf_ncuhdr_root" && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
8181 test "$oldincludedir" != NONE && \
8182 test "$oldincludedir" != "/usr/include" && \
8183 test -d "$oldincludedir" && {
8184 test -d "$oldincludedir" && cf_search="$cf_search $oldincludedir"
8185 test -d "$oldincludedir/$cf_ncuhdr_root" && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
8188 cf_search="$cf_search $cf_header_path_list"
8190 test -n "$verbose" && echo "search path $cf_search"
8191 cf_save2_CPPFLAGS="$CPPFLAGS"
8192 for cf_incdir in $cf_search
8195 if test -n "$cf_incdir" ; then
8196 for cf_add_incdir in $cf_incdir
8198 while test "$cf_add_incdir" != /usr/include
8200 if test -d "$cf_add_incdir"
8203 if test -n "$CFLAGS$CPPFLAGS" ; then
8204 # a loop is needed to ensure we can add subdirs of existing dirs
8205 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
8206 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
8207 cf_have_incdir=yes; break
8212 if test "$cf_have_incdir" = no ; then
8213 if test "$cf_add_incdir" = /usr/local/include ; then
8214 if test "$GCC" = yes
8216 cf_save_CPPFLAGS=$CPPFLAGS
8218 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
8219 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
8221 cat >"conftest.$ac_ext" <<_ACEOF
8222 #line 8222 "configure"
8223 #include "confdefs.h"
8233 rm -f "conftest.$ac_objext"
8234 if { (eval echo "$as_me:8234: \"$ac_compile\"") >&5
8235 (eval $ac_compile) 2>&5
8237 echo "$as_me:8237: \$? = $ac_status" >&5
8238 (exit "$ac_status"); } &&
8239 { ac_try='test -s "conftest.$ac_objext"'
8240 { (eval echo "$as_me:8240: \"$ac_try\"") >&5
8243 echo "$as_me:8243: \$? = $ac_status" >&5
8244 (exit "$ac_status"); }; }; then
8247 echo "$as_me: failed program was:" >&5
8248 cat "conftest.$ac_ext" >&5
8251 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
8252 CPPFLAGS=$cf_save_CPPFLAGS
8257 if test "$cf_have_incdir" = no ; then
8258 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
8260 echo "${as_me:-configure}:8260: testing adding $cf_add_incdir to include-path ..." 1>&5
8262 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8264 cf_top_incdir=`echo "$cf_add_incdir" | sed -e 's%/include/.*$%/include%'`
8265 test "$cf_top_incdir" = "$cf_add_incdir" && break
8266 cf_add_incdir="$cf_top_incdir"
8282 cat >"conftest.$ac_ext" <<_ACEOF
8283 #line 8283 "configure"
8284 #include "confdefs.h"
8286 #include <$cf_header>
8291 #ifdef NCURSES_VERSION
8293 printf("%s\\n", NCURSES_VERSION);
8306 rm -f "conftest.$ac_objext"
8307 if { (eval echo "$as_me:8307: \"$ac_compile\"") >&5
8308 (eval $ac_compile) 2>&5
8310 echo "$as_me:8310: \$? = $ac_status" >&5
8311 (exit "$ac_status"); } &&
8312 { ac_try='test -s "conftest.$ac_objext"'
8313 { (eval echo "$as_me:8313: \"$ac_try\"") >&5
8316 echo "$as_me:8316: \$? = $ac_status" >&5
8317 (exit "$ac_status"); }; }; then
8318 cf_cv_ncurses_h2=$cf_header
8321 echo "$as_me: failed program was:" >&5
8322 cat "conftest.$ac_ext" >&5
8325 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
8327 if test "$cf_cv_ncurses_h2" != no ; then
8328 cf_cv_ncurses_h2=$cf_incdir/$cf_header
8329 test -n "$verbose" && echo $ECHO_N " ... found $ECHO_C" 1>&6
8332 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
8334 CPPFLAGS="$cf_save2_CPPFLAGS"
8335 test "$cf_cv_ncurses_h2" != no && break
8337 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:8337: error: not found" >&5
8338 echo "$as_me: error: not found" >&2;}
8339 { (exit 1); exit 1; }; }
8342 echo "$as_me:8342: result: $cf_cv_ncurses_h2" >&5
8343 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
8345 cf_1st_incdir=`echo "$cf_cv_ncurses_h2" | sed -e 's%/[^/]*$%%'`
8346 cf_cv_ncurses_header="`basename "$cf_cv_ncurses_h2"`"
8347 if test "`basename "$cf_1st_incdir"`" = "$cf_ncuhdr_root" ; then
8348 cf_cv_ncurses_header="$cf_ncuhdr_root/$cf_cv_ncurses_header"
8351 if test -n "$cf_1st_incdir" ; then
8352 for cf_add_incdir in $cf_1st_incdir
8354 while test "$cf_add_incdir" != /usr/include
8356 if test -d "$cf_add_incdir"
8359 if test -n "$CFLAGS$CPPFLAGS" ; then
8360 # a loop is needed to ensure we can add subdirs of existing dirs
8361 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
8362 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
8363 cf_have_incdir=yes; break
8368 if test "$cf_have_incdir" = no ; then
8369 if test "$cf_add_incdir" = /usr/local/include ; then
8370 if test "$GCC" = yes
8372 cf_save_CPPFLAGS=$CPPFLAGS
8374 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
8375 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
8377 cat >"conftest.$ac_ext" <<_ACEOF
8378 #line 8378 "configure"
8379 #include "confdefs.h"
8389 rm -f "conftest.$ac_objext"
8390 if { (eval echo "$as_me:8390: \"$ac_compile\"") >&5
8391 (eval $ac_compile) 2>&5
8393 echo "$as_me:8393: \$? = $ac_status" >&5
8394 (exit "$ac_status"); } &&
8395 { ac_try='test -s "conftest.$ac_objext"'
8396 { (eval echo "$as_me:8396: \"$ac_try\"") >&5
8399 echo "$as_me:8399: \$? = $ac_status" >&5
8400 (exit "$ac_status"); }; }; then
8403 echo "$as_me: failed program was:" >&5
8404 cat "conftest.$ac_ext" >&5
8407 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
8408 CPPFLAGS=$cf_save_CPPFLAGS
8413 if test "$cf_have_incdir" = no ; then
8414 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
8416 echo "${as_me:-configure}:8416: testing adding $cf_add_incdir to include-path ..." 1>&5
8418 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8420 cf_top_incdir=`echo "$cf_add_incdir" | sed -e 's%/include/.*$%/include%'`
8421 test "$cf_top_incdir" = "$cf_add_incdir" && break
8422 cf_add_incdir="$cf_top_incdir"
8435 # Set definitions to allow ifdef'ing for ncurses.h
8437 case "$cf_cv_ncurses_header" in
8440 cat >>confdefs.h <<\EOF
8441 #define HAVE_NCURSES_H 1
8447 case "$cf_cv_ncurses_header" in
8448 (ncurses/curses.h|ncurses/ncurses.h)
8450 cat >>confdefs.h <<\EOF
8451 #define HAVE_NCURSES_NCURSES_H 1
8455 (ncursesw/curses.h|ncursesw/ncurses.h)
8457 cat >>confdefs.h <<\EOF
8458 #define HAVE_NCURSESW_NCURSES_H 1
8464 echo "$as_me:8464: checking for terminfo header" >&5
8465 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
8466 if test "${cf_cv_term_header+set}" = set; then
8467 echo $ECHO_N "(cached) $ECHO_C" >&6
8470 case "${cf_cv_ncurses_header}" in
8471 (*/ncurses.h|*/ncursesw.h)
8472 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
8475 cf_term_header=term.h
8479 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
8481 cat >"conftest.$ac_ext" <<_ACEOF
8482 #line 8482 "configure"
8483 #include "confdefs.h"
8485 #include <${cf_cv_ncurses_header:-curses.h}>
8491 int x = auto_left_margin; (void)x
8496 rm -f "conftest.$ac_objext"
8497 if { (eval echo "$as_me:8497: \"$ac_compile\"") >&5
8498 (eval $ac_compile) 2>&5
8500 echo "$as_me:8500: \$? = $ac_status" >&5
8501 (exit "$ac_status"); } &&
8502 { ac_try='test -s "conftest.$ac_objext"'
8503 { (eval echo "$as_me:8503: \"$ac_try\"") >&5
8506 echo "$as_me:8506: \$? = $ac_status" >&5
8507 (exit "$ac_status"); }; }; then
8509 cf_cv_term_header="$cf_test"
8511 echo "$as_me: failed program was:" >&5
8512 cat "conftest.$ac_ext" >&5
8514 cf_cv_term_header=unknown
8517 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
8518 test "$cf_cv_term_header" != unknown && break
8522 echo "$as_me:8522: result: $cf_cv_term_header" >&5
8523 echo "${ECHO_T}$cf_cv_term_header" >&6
8525 # Set definitions to allow ifdef'ing to accommodate subdirectories
8527 case "$cf_cv_term_header" in
8530 cat >>confdefs.h <<\EOF
8531 #define HAVE_TERM_H 1
8537 case "$cf_cv_term_header" in
8540 cat >>confdefs.h <<\EOF
8541 #define HAVE_NCURSES_TERM_H 1
8547 cat >>confdefs.h <<\EOF
8548 #define HAVE_NCURSESW_TERM_H 1
8554 # some applications need this, but should check for NCURSES_VERSION
8556 cat >>confdefs.h <<\EOF
8560 echo "$as_me:8560: checking for ncurses version" >&5
8561 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
8562 if test "${cf_cv_ncurses_version+set}" = set; then
8563 echo $ECHO_N "(cached) $ECHO_C" >&6
8566 cf_cv_ncurses_version=no
8568 rm -f "$cf_tempfile"
8569 if test "$cross_compiling" = yes; then
8571 # This will not work if the preprocessor splits the line after the
8572 # Autoconf token. The 'unproto' program does that.
8573 cat > "conftest.$ac_ext" <<EOF
8574 #include <${cf_cv_ncurses_header:-curses.h}>
8576 #ifdef NCURSES_VERSION
8577 Autoconf NCURSES_VERSION
8585 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
8586 { (eval echo "$as_me:8586: \"$cf_try\"") >&5
8589 echo "$as_me:8589: \$? = $ac_status" >&5
8590 (exit "$ac_status"); }
8591 if test -f conftest.out ; then
8592 cf_out=`sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%' conftest.out`
8593 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
8598 cat >"conftest.$ac_ext" <<_ACEOF
8599 #line 8599 "configure"
8600 #include "confdefs.h"
8602 #include <${cf_cv_ncurses_header:-curses.h}>
8606 FILE *fp = fopen("$cf_tempfile", "w");
8607 #ifdef NCURSES_VERSION
8608 # ifdef NCURSES_VERSION_PATCH
8609 fprintf(fp, "%s.%d\\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
8611 fprintf(fp, "%s\\n", NCURSES_VERSION);
8615 fprintf(fp, "old\\n");
8620 ${cf_cv_main_return:-return}(0);
8623 rm -f "conftest$ac_exeext"
8624 if { (eval echo "$as_me:8624: \"$ac_link\"") >&5
8625 (eval $ac_link) 2>&5
8627 echo "$as_me:8627: \$? = $ac_status" >&5
8628 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
8629 { (eval echo "$as_me:8629: \"$ac_try\"") >&5
8632 echo "$as_me:8632: \$? = $ac_status" >&5
8633 (exit "$ac_status"); }; }; then
8635 cf_cv_ncurses_version=`cat $cf_tempfile`
8637 echo "$as_me: program exited with status $ac_status" >&5
8638 echo "$as_me: failed program was:" >&5
8639 cat "conftest.$ac_ext" >&5
8641 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
8643 rm -f "$cf_tempfile"
8646 echo "$as_me:8646: result: $cf_cv_ncurses_version" >&5
8647 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
8648 test "$cf_cv_ncurses_version" = no ||
8649 cat >>confdefs.h <<\EOF
8653 cf_nculib_root=ncursesw
8654 # This works, except for the special case where we find gpm, but
8655 # ncurses is in a nonstandard location via $LIBS, and we really want
8658 cf_ncurses_SAVE="$LIBS"
8659 echo "$as_me:8659: checking for Gpm_Open in -lgpm" >&5
8660 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
8661 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
8662 echo $ECHO_N "(cached) $ECHO_C" >&6
8664 ac_check_lib_save_LIBS=$LIBS
8666 cat >"conftest.$ac_ext" <<_ACEOF
8667 #line 8667 "configure"
8668 #include "confdefs.h"
8670 /* Override any gcc2 internal prototype to avoid an error. */
8674 /* We use char because int might match the return type of a gcc2
8675 builtin and then its argument prototype would still apply. */
8685 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
8686 if { (eval echo "$as_me:8686: \"$ac_link\"") >&5
8687 (eval $ac_link) 2>&5
8689 echo "$as_me:8689: \$? = $ac_status" >&5
8690 (exit "$ac_status"); } &&
8691 { ac_try='test -s "conftest$ac_exeext"'
8692 { (eval echo "$as_me:8692: \"$ac_try\"") >&5
8695 echo "$as_me:8695: \$? = $ac_status" >&5
8696 (exit "$ac_status"); }; }; then
8697 ac_cv_lib_gpm_Gpm_Open=yes
8699 echo "$as_me: failed program was:" >&5
8700 cat "conftest.$ac_ext" >&5
8701 ac_cv_lib_gpm_Gpm_Open=no
8703 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
8704 LIBS=$ac_check_lib_save_LIBS
8706 echo "$as_me:8706: result: $ac_cv_lib_gpm_Gpm_Open" >&5
8707 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
8708 if test "$ac_cv_lib_gpm_Gpm_Open" = yes; then
8709 echo "$as_me:8709: checking for initscr in -lgpm" >&5
8710 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
8711 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
8712 echo $ECHO_N "(cached) $ECHO_C" >&6
8714 ac_check_lib_save_LIBS=$LIBS
8716 cat >"conftest.$ac_ext" <<_ACEOF
8717 #line 8717 "configure"
8718 #include "confdefs.h"
8720 /* Override any gcc2 internal prototype to avoid an error. */
8724 /* We use char because int might match the return type of a gcc2
8725 builtin and then its argument prototype would still apply. */
8735 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
8736 if { (eval echo "$as_me:8736: \"$ac_link\"") >&5
8737 (eval $ac_link) 2>&5
8739 echo "$as_me:8739: \$? = $ac_status" >&5
8740 (exit "$ac_status"); } &&
8741 { ac_try='test -s "conftest$ac_exeext"'
8742 { (eval echo "$as_me:8742: \"$ac_try\"") >&5
8745 echo "$as_me:8745: \$? = $ac_status" >&5
8746 (exit "$ac_status"); }; }; then
8747 ac_cv_lib_gpm_initscr=yes
8749 echo "$as_me: failed program was:" >&5
8750 cat "conftest.$ac_ext" >&5
8751 ac_cv_lib_gpm_initscr=no
8753 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
8754 LIBS=$ac_check_lib_save_LIBS
8756 echo "$as_me:8756: result: $ac_cv_lib_gpm_initscr" >&5
8757 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
8758 if test "$ac_cv_lib_gpm_initscr" = yes; then
8759 LIBS="$cf_ncurses_SAVE"
8761 cf_ncurses_LIBS="-lgpm"
8768 # This is only necessary if you are linking against an obsolete
8769 # version of ncurses (but it should do no harm, since it's static).
8770 if test "$cf_nculib_root" = ncurses ; then
8771 echo "$as_me:8771: checking for tgoto in -lmytinfo" >&5
8772 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
8773 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
8774 echo $ECHO_N "(cached) $ECHO_C" >&6
8776 ac_check_lib_save_LIBS=$LIBS
8777 LIBS="-lmytinfo $LIBS"
8778 cat >"conftest.$ac_ext" <<_ACEOF
8779 #line 8779 "configure"
8780 #include "confdefs.h"
8782 /* Override any gcc2 internal prototype to avoid an error. */
8786 /* We use char because int might match the return type of a gcc2
8787 builtin and then its argument prototype would still apply. */
8797 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
8798 if { (eval echo "$as_me:8798: \"$ac_link\"") >&5
8799 (eval $ac_link) 2>&5
8801 echo "$as_me:8801: \$? = $ac_status" >&5
8802 (exit "$ac_status"); } &&
8803 { ac_try='test -s "conftest$ac_exeext"'
8804 { (eval echo "$as_me:8804: \"$ac_try\"") >&5
8807 echo "$as_me:8807: \$? = $ac_status" >&5
8808 (exit "$ac_status"); }; }; then
8809 ac_cv_lib_mytinfo_tgoto=yes
8811 echo "$as_me: failed program was:" >&5
8812 cat "conftest.$ac_ext" >&5
8813 ac_cv_lib_mytinfo_tgoto=no
8815 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
8816 LIBS=$ac_check_lib_save_LIBS
8818 echo "$as_me:8818: result: $ac_cv_lib_mytinfo_tgoto" >&5
8819 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
8820 if test "$ac_cv_lib_mytinfo_tgoto" = yes; then
8821 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
8831 for cf_add_1lib in $cf_ncurses_LIBS; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
8833 for cf_add_1lib in $cf_add_0lib; do
8834 for cf_add_2lib in $cf_add_libs; do
8835 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
8840 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
8844 if test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no"
8850 for cf_add_1lib in -l$cf_nculib_root; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
8852 for cf_add_1lib in $cf_add_0lib; do
8853 for cf_add_2lib in $cf_add_libs; do
8854 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
8859 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
8865 eval 'cf_cv_have_lib_'"$cf_nculib_root"'=no'
8867 echo "$as_me:8867: checking for initscr" >&5
8868 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
8869 if test "${ac_cv_func_initscr+set}" = set; then
8870 echo $ECHO_N "(cached) $ECHO_C" >&6
8872 cat >"conftest.$ac_ext" <<_ACEOF
8873 #line 8873 "configure"
8874 #include "confdefs.h"
8875 #define initscr autoconf_temporary
8876 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
8883 /* We use char because int might match the return type of a gcc2
8884 builtin and then its argument prototype would still apply. */
8885 char initscr (void);
8891 /* The GNU C library defines stubs for functions which it implements
8892 to always fail with ENOSYS. Some functions are actually named
8893 something starting with __ and the normal name is an alias. */
8894 #if defined (__stub_initscr) || defined (__stub___initscr)
8895 #error found stub for initscr
8903 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
8904 if { (eval echo "$as_me:8904: \"$ac_link\"") >&5
8905 (eval $ac_link) 2>&5
8907 echo "$as_me:8907: \$? = $ac_status" >&5
8908 (exit "$ac_status"); } &&
8909 { ac_try='test -s "conftest$ac_exeext"'
8910 { (eval echo "$as_me:8910: \"$ac_try\"") >&5
8913 echo "$as_me:8913: \$? = $ac_status" >&5
8914 (exit "$ac_status"); }; }; then
8915 ac_cv_func_initscr=yes
8917 echo "$as_me: failed program was:" >&5
8918 cat "conftest.$ac_ext" >&5
8919 ac_cv_func_initscr=no
8921 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
8923 echo "$as_me:8923: result: $ac_cv_func_initscr" >&5
8924 echo "${ECHO_T}$ac_cv_func_initscr" >&6
8925 if test "$ac_cv_func_initscr" = yes; then
8926 eval 'cf_cv_have_lib_'"$cf_nculib_root"'=yes'
8929 cf_save_LIBS="$LIBS"
8930 echo "$as_me:8930: checking for initscr in -l$cf_nculib_root" >&5
8931 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
8932 LIBS="-l$cf_nculib_root $LIBS"
8933 cat >"conftest.$ac_ext" <<_ACEOF
8934 #line 8934 "configure"
8935 #include "confdefs.h"
8936 #include <${cf_cv_ncurses_header:-curses.h}>
8945 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
8946 if { (eval echo "$as_me:8946: \"$ac_link\"") >&5
8947 (eval $ac_link) 2>&5
8949 echo "$as_me:8949: \$? = $ac_status" >&5
8950 (exit "$ac_status"); } &&
8951 { ac_try='test -s "conftest$ac_exeext"'
8952 { (eval echo "$as_me:8952: \"$ac_try\"") >&5
8955 echo "$as_me:8955: \$? = $ac_status" >&5
8956 (exit "$ac_status"); }; }; then
8957 echo "$as_me:8957: result: yes" >&5
8958 echo "${ECHO_T}yes" >&6
8959 eval 'cf_cv_have_lib_'"$cf_nculib_root"'=yes'
8962 echo "$as_me: failed program was:" >&5
8963 cat "conftest.$ac_ext" >&5
8964 echo "$as_me:8964: result: no" >&5
8965 echo "${ECHO_T}no" >&6
8968 cf_library_path_list=""
8969 if test -n "${LDFLAGS}${LIBS}" ; then
8970 for cf_library_path in $LDFLAGS $LIBS
8972 case "$cf_library_path" in
8974 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
8976 test "x$cf_library_path" != "xNONE" && \
8977 test -d "$cf_library_path" && \
8979 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
8980 test -d "$cf_library_path/lib" && cf_search="$cf_search $cf_library_path/lib"
8981 test -d "$cf_library_path/lib/$cf_nculib_root" && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
8982 test -d "$cf_library_path/lib/$cf_nculib_root/lib" && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
8983 test -d "$cf_library_path/$cf_nculib_root/lib" && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
8984 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"
8987 cf_library_path_list="$cf_library_path_list $cf_search"
8995 test "x$prefix" != "xNONE" && \
8996 test -d "$prefix" && \
8998 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
8999 test -d "$prefix/lib" && cf_search="$cf_search $prefix/lib"
9000 test -d "$prefix/lib/$cf_nculib_root" && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
9001 test -d "$prefix/lib/$cf_nculib_root/lib" && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
9002 test -d "$prefix/$cf_nculib_root/lib" && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
9003 test -d "$prefix/$cf_nculib_root/lib/$cf_nculib_root" && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
9006 for cf_subdir_prefix in \
9015 test "x$cf_subdir_prefix" != "x$prefix" && \
9016 test -d "$cf_subdir_prefix" && \
9017 { test -z "$prefix" || test "x$prefix" = xNONE || test "x$cf_subdir_prefix" != "x$prefix"; } && {
9018 test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
9019 test -d "$cf_subdir_prefix/lib" && cf_search="$cf_search $cf_subdir_prefix/lib"
9020 test -d "$cf_subdir_prefix/lib/$cf_nculib_root" && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root"
9021 test -d "$cf_subdir_prefix/lib/$cf_nculib_root/lib" && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root/lib"
9022 test -d "$cf_subdir_prefix/$cf_nculib_root/lib" && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib"
9023 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"
9028 cf_search="$cf_library_path_list $cf_search"
9030 for cf_libdir in $cf_search
9032 echo "$as_me:9032: checking for -l$cf_nculib_root in $cf_libdir" >&5
9033 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
9034 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
9035 cat >"conftest.$ac_ext" <<_ACEOF
9036 #line 9036 "configure"
9037 #include "confdefs.h"
9038 #include <${cf_cv_ncurses_header:-curses.h}>
9047 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
9048 if { (eval echo "$as_me:9048: \"$ac_link\"") >&5
9049 (eval $ac_link) 2>&5
9051 echo "$as_me:9051: \$? = $ac_status" >&5
9052 (exit "$ac_status"); } &&
9053 { ac_try='test -s "conftest$ac_exeext"'
9054 { (eval echo "$as_me:9054: \"$ac_try\"") >&5
9057 echo "$as_me:9057: \$? = $ac_status" >&5
9058 (exit "$ac_status"); }; }; then
9059 echo "$as_me:9059: result: yes" >&5
9060 echo "${ECHO_T}yes" >&6
9061 eval 'cf_cv_have_lib_'"$cf_nculib_root"'=yes'
9064 echo "$as_me: failed program was:" >&5
9065 cat "conftest.$ac_ext" >&5
9066 echo "$as_me:9066: result: no" >&5
9067 echo "${ECHO_T}no" >&6
9068 LIBS="$cf_save_LIBS"
9070 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
9074 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
9078 eval 'cf_found_library="$cf_cv_have_lib_'"$cf_nculib_root"\"
9080 if test "$cf_found_library" = no ; then
9081 { { echo "$as_me:9081: error: Cannot link $cf_nculib_root library" >&5
9082 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
9083 { (exit 1); exit 1; }; }
9088 if test -n "$cf_ncurses_LIBS" ; then
9089 echo "$as_me:9089: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
9090 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
9091 cf_ncurses_SAVE="$LIBS"
9092 for p in $cf_ncurses_LIBS ; do
9093 q=`echo "$LIBS" | sed -e "s%$p %%" -e "s%$p$%%"`
9094 if test "$q" != "$LIBS" ; then
9098 cat >"conftest.$ac_ext" <<_ACEOF
9099 #line 9099 "configure"
9100 #include "confdefs.h"
9101 #include <${cf_cv_ncurses_header:-curses.h}>
9105 initscr(); mousemask(0,0); tigetstr((char *)0);
9110 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
9111 if { (eval echo "$as_me:9111: \"$ac_link\"") >&5
9112 (eval $ac_link) 2>&5
9114 echo "$as_me:9114: \$? = $ac_status" >&5
9115 (exit "$ac_status"); } &&
9116 { ac_try='test -s "conftest$ac_exeext"'
9117 { (eval echo "$as_me:9117: \"$ac_try\"") >&5
9120 echo "$as_me:9120: \$? = $ac_status" >&5
9121 (exit "$ac_status"); }; }; then
9122 echo "$as_me:9122: result: yes" >&5
9123 echo "${ECHO_T}yes" >&6
9125 echo "$as_me: failed program was:" >&5
9126 cat "conftest.$ac_ext" >&5
9127 echo "$as_me:9127: result: no" >&5
9128 echo "${ECHO_T}no" >&6
9129 LIBS="$cf_ncurses_SAVE"
9131 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
9134 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
9136 cat >>confdefs.h <<EOF
9137 #define $cf_nculib_ROOT 1
9147 cf_ncuconfig_root=ncurses
9148 cf_have_ncuconfig=no
9150 if test "x${PKG_CONFIG:=none}" != xnone; then
9151 echo "$as_me:9151: checking pkg-config for $cf_ncuconfig_root" >&5
9152 echo $ECHO_N "checking pkg-config for $cf_ncuconfig_root... $ECHO_C" >&6
9153 if "$PKG_CONFIG" --exists $cf_ncuconfig_root ; then
9154 echo "$as_me:9154: result: yes" >&5
9155 echo "${ECHO_T}yes" >&6
9157 echo "$as_me:9157: checking if the $cf_ncuconfig_root package files work" >&5
9158 echo $ECHO_N "checking if the $cf_ncuconfig_root package files work... $ECHO_C" >&6
9159 cf_have_ncuconfig=unknown
9161 cf_save_CFLAGS="$CFLAGS"
9162 cf_save_CPPFLAGS="$CPPFLAGS"
9163 cf_save_LIBS="$LIBS"
9165 cf_pkg_cflags="`$PKG_CONFIG --cflags $cf_ncuconfig_root`"
9166 cf_pkg_libs="`$PKG_CONFIG --libs $cf_ncuconfig_root`"
9168 # while -W for passing linker flags is prevalent, it is not "standard".
9169 # At least one wrapper for c89/c99 (in Apple's xcode) has its own
9170 # incompatible _and_ non-standard -W option which gives an error. Work
9171 # around that pitfall.
9172 case "x${CC}@@${cf_pkg_libs}@${cf_pkg_cflags}" in
9178 cf_new_extra_cppflags=
9180 for cf_add_cflags in $cf_pkg_cflags
9182 case "$cf_fix_cppflags" in
9184 case "$cf_add_cflags" in
9185 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
9186 case "$cf_add_cflags" in
9188 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
9190 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
9191 && test -z "${cf_tst_cflags}" \
9192 && cf_fix_cppflags=yes
9194 if test "$cf_fix_cppflags" = yes ; then
9196 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9197 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9200 elif test "${cf_tst_cflags}" = "\"'" ; then
9202 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9203 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9213 case "$cf_add_cflags" in
9215 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
9217 CPPFLAGS=`echo "$CPPFLAGS" | \
9218 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
9219 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
9224 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
9225 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
9232 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
9233 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
9240 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9241 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9243 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
9245 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
9246 && test -z "${cf_tst_cflags}" \
9247 && cf_fix_cppflags=no
9252 if test -n "$cf_new_cflags" ; then
9254 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
9255 CFLAGS="${CFLAGS}$cf_new_cflags"
9259 if test -n "$cf_new_cppflags" ; then
9261 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
9262 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
9266 if test -n "$cf_new_extra_cppflags" ; then
9268 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
9269 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
9276 for cf_add_1lib in $cf_pkg_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
9278 for cf_add_1lib in $cf_add_0lib; do
9279 for cf_add_2lib in $cf_add_libs; do
9280 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
9285 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
9289 cat >"conftest.$ac_ext" <<_ACEOF
9290 #line 9290 "configure"
9291 #include "confdefs.h"
9292 #include <${cf_cv_ncurses_header:-curses.h}>
9296 initscr(); mousemask(0,0); tigetstr((char *)0);
9301 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
9302 if { (eval echo "$as_me:9302: \"$ac_link\"") >&5
9303 (eval $ac_link) 2>&5
9305 echo "$as_me:9305: \$? = $ac_status" >&5
9306 (exit "$ac_status"); } &&
9307 { ac_try='test -s "conftest$ac_exeext"'
9308 { (eval echo "$as_me:9308: \"$ac_try\"") >&5
9311 echo "$as_me:9311: \$? = $ac_status" >&5
9312 (exit "$ac_status"); }; }; then
9313 if test "$cross_compiling" = yes; then
9314 cf_test_ncuconfig=maybe
9316 cat >"conftest.$ac_ext" <<_ACEOF
9317 #line 9317 "configure"
9318 #include "confdefs.h"
9319 #include <${cf_cv_ncurses_header:-curses.h}>
9321 { const char *xx = curses_version(); return (xx == 0); }
9323 rm -f "conftest$ac_exeext"
9324 if { (eval echo "$as_me:9324: \"$ac_link\"") >&5
9325 (eval $ac_link) 2>&5
9327 echo "$as_me:9327: \$? = $ac_status" >&5
9328 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
9329 { (eval echo "$as_me:9329: \"$ac_try\"") >&5
9332 echo "$as_me:9332: \$? = $ac_status" >&5
9333 (exit "$ac_status"); }; }; then
9334 cf_test_ncuconfig=yes
9336 echo "$as_me: program exited with status $ac_status" >&5
9337 echo "$as_me: failed program was:" >&5
9338 cat "conftest.$ac_ext" >&5
9339 cf_test_ncuconfig=no
9341 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
9344 echo "$as_me: failed program was:" >&5
9345 cat "conftest.$ac_ext" >&5
9346 cf_test_ncuconfig=no
9348 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
9350 CFLAGS="$cf_save_CFLAGS"
9351 CPPFLAGS="$cf_save_CPPFLAGS"
9352 LIBS="$cf_save_LIBS"
9354 if test "x$cf_test_ncuconfig" != xyes; then
9355 cf_temp=`echo "x$cf_pkg_cflags" | sed -e s/^x// -e 's/-W[^ ]*//g'`
9356 cf_pkg_cflags="$cf_temp"
9357 cf_temp=`echo "x$cf_pkg_libs" | sed -e s/^x// -e 's/-W[^ ]*//g'`
9358 cf_pkg_libs="$cf_temp"
9366 cf_new_extra_cppflags=
9368 for cf_add_cflags in $cf_pkg_cflags
9370 case "$cf_fix_cppflags" in
9372 case "$cf_add_cflags" in
9373 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
9374 case "$cf_add_cflags" in
9376 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
9378 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
9379 && test -z "${cf_tst_cflags}" \
9380 && cf_fix_cppflags=yes
9382 if test "$cf_fix_cppflags" = yes ; then
9384 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9385 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9388 elif test "${cf_tst_cflags}" = "\"'" ; then
9390 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9391 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9401 case "$cf_add_cflags" in
9403 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
9405 CPPFLAGS=`echo "$CPPFLAGS" | \
9406 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
9407 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
9412 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
9413 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
9420 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
9421 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
9428 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9429 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9431 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
9433 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
9434 && test -z "${cf_tst_cflags}" \
9435 && cf_fix_cppflags=no
9440 if test -n "$cf_new_cflags" ; then
9442 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
9443 CFLAGS="${CFLAGS}$cf_new_cflags"
9447 if test -n "$cf_new_cppflags" ; then
9449 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
9450 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
9454 if test -n "$cf_new_extra_cppflags" ; then
9456 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
9457 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
9464 for cf_add_1lib in $cf_pkg_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
9466 for cf_add_1lib in $cf_add_0lib; do
9467 for cf_add_2lib in $cf_add_libs; do
9468 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
9473 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
9477 cat >"conftest.$ac_ext" <<_ACEOF
9478 #line 9478 "configure"
9479 #include "confdefs.h"
9480 #include <${cf_cv_ncurses_header:-curses.h}>
9484 initscr(); mousemask(0,0); tigetstr((char *)0);
9489 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
9490 if { (eval echo "$as_me:9490: \"$ac_link\"") >&5
9491 (eval $ac_link) 2>&5
9493 echo "$as_me:9493: \$? = $ac_status" >&5
9494 (exit "$ac_status"); } &&
9495 { ac_try='test -s "conftest$ac_exeext"'
9496 { (eval echo "$as_me:9496: \"$ac_try\"") >&5
9499 echo "$as_me:9499: \$? = $ac_status" >&5
9500 (exit "$ac_status"); }; }; then
9501 if test "$cross_compiling" = yes; then
9502 cf_have_ncuconfig=maybe
9504 cat >"conftest.$ac_ext" <<_ACEOF
9505 #line 9505 "configure"
9506 #include "confdefs.h"
9507 #include <${cf_cv_ncurses_header:-curses.h}>
9509 { const char *xx = curses_version(); return (xx == 0); }
9511 rm -f "conftest$ac_exeext"
9512 if { (eval echo "$as_me:9512: \"$ac_link\"") >&5
9513 (eval $ac_link) 2>&5
9515 echo "$as_me:9515: \$? = $ac_status" >&5
9516 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
9517 { (eval echo "$as_me:9517: \"$ac_try\"") >&5
9520 echo "$as_me:9520: \$? = $ac_status" >&5
9521 (exit "$ac_status"); }; }; then
9522 cf_have_ncuconfig=yes
9524 echo "$as_me: program exited with status $ac_status" >&5
9525 echo "$as_me: failed program was:" >&5
9526 cat "conftest.$ac_ext" >&5
9527 cf_have_ncuconfig=no
9529 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
9532 echo "$as_me: failed program was:" >&5
9533 cat "conftest.$ac_ext" >&5
9534 cf_have_ncuconfig=no
9536 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
9537 echo "$as_me:9537: result: $cf_have_ncuconfig" >&5
9538 echo "${ECHO_T}$cf_have_ncuconfig" >&6
9539 test "$cf_have_ncuconfig" = maybe && cf_have_ncuconfig=yes
9540 if test "$cf_have_ncuconfig" != "yes"
9542 CPPFLAGS="$cf_save_CPPFLAGS"
9543 LIBS="$cf_save_LIBS"
9544 NCURSES_CONFIG_PKG=none
9547 cat >>confdefs.h <<\EOF
9551 NCURSES_CONFIG_PKG=$cf_ncuconfig_root
9553 echo "$as_me:9553: checking for terminfo header" >&5
9554 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
9555 if test "${cf_cv_term_header+set}" = set; then
9556 echo $ECHO_N "(cached) $ECHO_C" >&6
9559 case "${cf_cv_ncurses_header}" in
9560 (*/ncurses.h|*/ncursesw.h)
9561 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
9564 cf_term_header=term.h
9568 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
9570 cat >"conftest.$ac_ext" <<_ACEOF
9571 #line 9571 "configure"
9572 #include "confdefs.h"
9574 #include <${cf_cv_ncurses_header:-curses.h}>
9580 int x = auto_left_margin; (void)x
9585 rm -f "conftest.$ac_objext"
9586 if { (eval echo "$as_me:9586: \"$ac_compile\"") >&5
9587 (eval $ac_compile) 2>&5
9589 echo "$as_me:9589: \$? = $ac_status" >&5
9590 (exit "$ac_status"); } &&
9591 { ac_try='test -s "conftest.$ac_objext"'
9592 { (eval echo "$as_me:9592: \"$ac_try\"") >&5
9595 echo "$as_me:9595: \$? = $ac_status" >&5
9596 (exit "$ac_status"); }; }; then
9598 cf_cv_term_header="$cf_test"
9600 echo "$as_me: failed program was:" >&5
9601 cat "conftest.$ac_ext" >&5
9603 cf_cv_term_header=unknown
9606 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
9607 test "$cf_cv_term_header" != unknown && break
9611 echo "$as_me:9611: result: $cf_cv_term_header" >&5
9612 echo "${ECHO_T}$cf_cv_term_header" >&6
9614 # Set definitions to allow ifdef'ing to accommodate subdirectories
9616 case "$cf_cv_term_header" in
9619 cat >>confdefs.h <<\EOF
9620 #define HAVE_TERM_H 1
9626 case "$cf_cv_term_header" in
9629 cat >>confdefs.h <<\EOF
9630 #define HAVE_NCURSES_TERM_H 1
9636 cat >>confdefs.h <<\EOF
9637 #define HAVE_NCURSESW_TERM_H 1
9646 echo "$as_me:9646: result: no" >&5
9647 echo "${ECHO_T}no" >&6
9648 NCURSES_CONFIG_PKG=none
9651 NCURSES_CONFIG_PKG=none
9654 if test "x$cf_have_ncuconfig" = "xno"; then
9655 cf_ncurses_config="${cf_ncuconfig_root}${NCURSES_CONFIG_SUFFIX}-config"; echo "Looking for ${cf_ncurses_config}"
9657 if test -n "$ac_tool_prefix"; then
9658 for ac_prog in ${cf_ncurses_config} ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
9660 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
9661 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
9662 echo "$as_me:9662: checking for $ac_word" >&5
9663 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
9664 if test "${ac_cv_prog_NCURSES_CONFIG+set}" = set; then
9665 echo $ECHO_N "(cached) $ECHO_C" >&6
9667 if test -n "$NCURSES_CONFIG"; then
9668 ac_cv_prog_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test.
9670 ac_save_IFS=$IFS; IFS=$ac_path_separator
9672 for ac_dir in $ac_dummy; do
9674 test -z "$ac_dir" && ac_dir=.
9675 $as_executable_p "$ac_dir/$ac_word" || continue
9676 ac_cv_prog_NCURSES_CONFIG="$ac_tool_prefix$ac_prog"
9677 echo "$as_me:9677: found $ac_dir/$ac_word" >&5
9683 NCURSES_CONFIG=$ac_cv_prog_NCURSES_CONFIG
9684 if test -n "$NCURSES_CONFIG"; then
9685 echo "$as_me:9685: result: $NCURSES_CONFIG" >&5
9686 echo "${ECHO_T}$NCURSES_CONFIG" >&6
9688 echo "$as_me:9688: result: no" >&5
9689 echo "${ECHO_T}no" >&6
9692 test -n "$NCURSES_CONFIG" && break
9695 if test -z "$NCURSES_CONFIG"; then
9696 ac_ct_NCURSES_CONFIG=$NCURSES_CONFIG
9697 for ac_prog in ${cf_ncurses_config} ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
9699 # Extract the first word of "$ac_prog", so it can be a program name with args.
9700 set dummy $ac_prog; ac_word=$2
9701 echo "$as_me:9701: checking for $ac_word" >&5
9702 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
9703 if test "${ac_cv_prog_ac_ct_NCURSES_CONFIG+set}" = set; then
9704 echo $ECHO_N "(cached) $ECHO_C" >&6
9706 if test -n "$ac_ct_NCURSES_CONFIG"; then
9707 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_ct_NCURSES_CONFIG" # Let the user override the test.
9709 ac_save_IFS=$IFS; IFS=$ac_path_separator
9711 for ac_dir in $ac_dummy; do
9713 test -z "$ac_dir" && ac_dir=.
9714 $as_executable_p "$ac_dir/$ac_word" || continue
9715 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_prog"
9716 echo "$as_me:9716: found $ac_dir/$ac_word" >&5
9722 ac_ct_NCURSES_CONFIG=$ac_cv_prog_ac_ct_NCURSES_CONFIG
9723 if test -n "$ac_ct_NCURSES_CONFIG"; then
9724 echo "$as_me:9724: result: $ac_ct_NCURSES_CONFIG" >&5
9725 echo "${ECHO_T}$ac_ct_NCURSES_CONFIG" >&6
9727 echo "$as_me:9727: result: no" >&5
9728 echo "${ECHO_T}no" >&6
9731 test -n "$ac_ct_NCURSES_CONFIG" && break
9733 test -n "$ac_ct_NCURSES_CONFIG" || ac_ct_NCURSES_CONFIG="none"
9735 NCURSES_CONFIG=$ac_ct_NCURSES_CONFIG
9738 if test "$NCURSES_CONFIG" != none ; then
9743 cf_new_extra_cppflags=
9745 for cf_add_cflags in `$NCURSES_CONFIG --cflags`
9747 case "$cf_fix_cppflags" in
9749 case "$cf_add_cflags" in
9750 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
9751 case "$cf_add_cflags" in
9753 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
9755 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
9756 && test -z "${cf_tst_cflags}" \
9757 && cf_fix_cppflags=yes
9759 if test "$cf_fix_cppflags" = yes ; then
9761 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9762 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9765 elif test "${cf_tst_cflags}" = "\"'" ; then
9767 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9768 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9778 case "$cf_add_cflags" in
9780 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
9782 CPPFLAGS=`echo "$CPPFLAGS" | \
9783 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
9784 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
9789 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
9790 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
9797 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
9798 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
9805 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9806 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9808 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
9810 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
9811 && test -z "${cf_tst_cflags}" \
9812 && cf_fix_cppflags=no
9817 if test -n "$cf_new_cflags" ; then
9819 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
9820 CFLAGS="${CFLAGS}$cf_new_cflags"
9824 if test -n "$cf_new_cppflags" ; then
9826 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
9827 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
9831 if test -n "$cf_new_extra_cppflags" ; then
9833 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
9834 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
9841 for cf_add_1lib in `$NCURSES_CONFIG --libs`; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
9843 for cf_add_1lib in $cf_add_0lib; do
9844 for cf_add_2lib in $cf_add_libs; do
9845 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
9850 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
9854 # even with config script, some packages use no-override for curses.h
9856 echo "$as_me:9856: checking if we have identified curses headers" >&5
9857 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
9858 if test "${cf_cv_ncurses_header+set}" = set; then
9859 echo $ECHO_N "(cached) $ECHO_C" >&6
9862 cf_cv_ncurses_header=none
9864 ncurses.h ncurses/ncurses.h \
9865 curses.h ncurses/curses.h
9867 cat >"conftest.$ac_ext" <<_ACEOF
9868 #line 9868 "configure"
9869 #include "confdefs.h"
9870 #include <${cf_header}>
9874 initscr(); tgoto("?", 0,0)
9879 rm -f "conftest.$ac_objext"
9880 if { (eval echo "$as_me:9880: \"$ac_compile\"") >&5
9881 (eval $ac_compile) 2>&5
9883 echo "$as_me:9883: \$? = $ac_status" >&5
9884 (exit "$ac_status"); } &&
9885 { ac_try='test -s "conftest.$ac_objext"'
9886 { (eval echo "$as_me:9886: \"$ac_try\"") >&5
9889 echo "$as_me:9889: \$? = $ac_status" >&5
9890 (exit "$ac_status"); }; }; then
9891 cf_cv_ncurses_header=$cf_header; break
9893 echo "$as_me: failed program was:" >&5
9894 cat "conftest.$ac_ext" >&5
9896 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
9900 echo "$as_me:9900: result: $cf_cv_ncurses_header" >&5
9901 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
9903 if test "$cf_cv_ncurses_header" = none ; then
9904 { { echo "$as_me:9904: error: No curses header-files found" >&5
9905 echo "$as_me: error: No curses header-files found" >&2;}
9906 { (exit 1); exit 1; }; }
9909 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
9911 for ac_header in $cf_cv_ncurses_header
9913 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9914 echo "$as_me:9914: checking for $ac_header" >&5
9915 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9916 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9917 echo $ECHO_N "(cached) $ECHO_C" >&6
9919 cat >"conftest.$ac_ext" <<_ACEOF
9920 #line 9920 "configure"
9921 #include "confdefs.h"
9922 #include <$ac_header>
9924 if { (eval echo "$as_me:9924: \"$ac_cpp "conftest.$ac_ext"\"") >&5
9925 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
9927 $EGREP -v '^ *\+' conftest.er1 >conftest.err
9929 cat conftest.err >&5
9930 echo "$as_me:9930: \$? = $ac_status" >&5
9931 (exit "$ac_status"); } >/dev/null; then
9932 if test -s conftest.err; then
9933 ac_cpp_err=$ac_c_preproc_warn_flag
9940 if test -z "$ac_cpp_err"; then
9941 eval "$as_ac_Header=yes"
9943 echo "$as_me: failed program was:" >&5
9944 cat "conftest.$ac_ext" >&5
9945 eval "$as_ac_Header=no"
9947 rm -f conftest.err "conftest.$ac_ext"
9949 echo "$as_me:9949: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
9950 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
9951 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
9952 cat >>confdefs.h <<EOF
9953 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9959 cat >>confdefs.h <<\EOF
9963 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
9965 cat >>confdefs.h <<EOF
9966 #define $cf_nculib_ROOT 1
9969 cf_cv_ncurses_version="`$NCURSES_CONFIG --version`"
9973 cf_ncuhdr_root=ncurses
9975 test -n "$cf_cv_curses_dir" && \
9976 test "$cf_cv_curses_dir" != "no" && { \
9978 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
9979 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
9981 while test "$cf_add_incdir" != /usr/include
9983 if test -d "$cf_add_incdir"
9986 if test -n "$CFLAGS$CPPFLAGS" ; then
9987 # a loop is needed to ensure we can add subdirs of existing dirs
9988 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
9989 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
9990 cf_have_incdir=yes; break
9995 if test "$cf_have_incdir" = no ; then
9996 if test "$cf_add_incdir" = /usr/local/include ; then
9997 if test "$GCC" = yes
9999 cf_save_CPPFLAGS=$CPPFLAGS
10001 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
10002 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
10004 cat >"conftest.$ac_ext" <<_ACEOF
10005 #line 10005 "configure"
10006 #include "confdefs.h"
10016 rm -f "conftest.$ac_objext"
10017 if { (eval echo "$as_me:10017: \"$ac_compile\"") >&5
10018 (eval $ac_compile) 2>&5
10020 echo "$as_me:10020: \$? = $ac_status" >&5
10021 (exit "$ac_status"); } &&
10022 { ac_try='test -s "conftest.$ac_objext"'
10023 { (eval echo "$as_me:10023: \"$ac_try\"") >&5
10024 (eval $ac_try) 2>&5
10026 echo "$as_me:10026: \$? = $ac_status" >&5
10027 (exit "$ac_status"); }; }; then
10030 echo "$as_me: failed program was:" >&5
10031 cat "conftest.$ac_ext" >&5
10034 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
10035 CPPFLAGS=$cf_save_CPPFLAGS
10040 if test "$cf_have_incdir" = no ; then
10041 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
10043 echo "${as_me:-configure}:10043: testing adding $cf_add_incdir to include-path ..." 1>&5
10045 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
10047 cf_top_incdir=`echo "$cf_add_incdir" | sed -e 's%/include/.*$%/include%'`
10048 test "$cf_top_incdir" = "$cf_add_incdir" && break
10049 cf_add_incdir="$cf_top_incdir"
10062 echo "$as_me:10062: checking for $cf_ncuhdr_root header in include-path" >&5
10063 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
10064 if test "${cf_cv_ncurses_h+set}" = set; then
10065 echo $ECHO_N "(cached) $ECHO_C" >&6
10068 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
10069 { test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw; } && cf_header_list="$cf_header_list curses.h ncurses.h"
10070 for cf_header in $cf_header_list
10073 cat >"conftest.$ac_ext" <<_ACEOF
10074 #line 10074 "configure"
10075 #include "confdefs.h"
10077 #include <$cf_header>
10082 #ifdef NCURSES_VERSION
10084 printf("%s\\n", NCURSES_VERSION);
10097 rm -f "conftest.$ac_objext"
10098 if { (eval echo "$as_me:10098: \"$ac_compile\"") >&5
10099 (eval $ac_compile) 2>&5
10101 echo "$as_me:10101: \$? = $ac_status" >&5
10102 (exit "$ac_status"); } &&
10103 { ac_try='test -s "conftest.$ac_objext"'
10104 { (eval echo "$as_me:10104: \"$ac_try\"") >&5
10105 (eval $ac_try) 2>&5
10107 echo "$as_me:10107: \$? = $ac_status" >&5
10108 (exit "$ac_status"); }; }; then
10109 cf_cv_ncurses_h=$cf_header
10112 echo "$as_me: failed program was:" >&5
10113 cat "conftest.$ac_ext" >&5
10116 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
10118 test "$cf_cv_ncurses_h" != no && break
10122 echo "$as_me:10122: result: $cf_cv_ncurses_h" >&5
10123 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
10125 if test "$cf_cv_ncurses_h" != no ; then
10126 cf_cv_ncurses_header=$cf_cv_ncurses_h
10129 echo "$as_me:10129: checking for $cf_ncuhdr_root include-path" >&5
10130 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
10131 if test "${cf_cv_ncurses_h2+set}" = set; then
10132 echo $ECHO_N "(cached) $ECHO_C" >&6
10135 test -n "$verbose" && echo
10139 # collect the current set of include-directories from compiler flags
10140 cf_header_path_list=""
10141 if test -n "${CFLAGS}${CPPFLAGS}" ; then
10142 for cf_header_path in $CPPFLAGS $CFLAGS
10144 case "$cf_header_path" in
10146 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
10148 test "x$cf_header_path" != "xNONE" && \
10149 test -d "$cf_header_path" && \
10151 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
10152 test -d "$cf_header_path/include" && cf_search="$cf_search $cf_header_path/include"
10153 test -d "$cf_header_path/include/$cf_ncuhdr_root" && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
10154 test -d "$cf_header_path/include/$cf_ncuhdr_root/include" && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
10155 test -d "$cf_header_path/$cf_ncuhdr_root/include" && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
10156 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"
10159 cf_header_path_list="$cf_header_path_list $cf_search"
10165 # add the variations for the package we are looking for
10169 test "x$prefix" != "xNONE" && \
10170 test -d "$prefix" && \
10172 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
10173 test -d "$prefix/include" && cf_search="$cf_search $prefix/include"
10174 test -d "$prefix/include/$cf_ncuhdr_root" && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
10175 test -d "$prefix/include/$cf_ncuhdr_root/include" && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
10176 test -d "$prefix/$cf_ncuhdr_root/include" && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
10177 test -d "$prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root" && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
10180 for cf_subdir_prefix in \
10189 test "x$cf_subdir_prefix" != "x$prefix" && \
10190 test -d "$cf_subdir_prefix" && \
10191 { test -z "$prefix" || test "x$prefix" = xNONE || test "x$cf_subdir_prefix" != "x$prefix"; } && {
10192 test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
10193 test -d "$cf_subdir_prefix/include" && cf_search="$cf_search $cf_subdir_prefix/include"
10194 test -d "$cf_subdir_prefix/include/$cf_ncuhdr_root" && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root"
10195 test -d "$cf_subdir_prefix/include/$cf_ncuhdr_root/include" && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root/include"
10196 test -d "$cf_subdir_prefix/$cf_ncuhdr_root/include" && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include"
10197 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"
10202 test "$includedir" != NONE && \
10203 test "$includedir" != "/usr/include" && \
10204 test -d "$includedir" && {
10205 test -d "$includedir" && cf_search="$cf_search $includedir"
10206 test -d "$includedir/$cf_ncuhdr_root" && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
10209 test "$oldincludedir" != NONE && \
10210 test "$oldincludedir" != "/usr/include" && \
10211 test -d "$oldincludedir" && {
10212 test -d "$oldincludedir" && cf_search="$cf_search $oldincludedir"
10213 test -d "$oldincludedir/$cf_ncuhdr_root" && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
10216 cf_search="$cf_search $cf_header_path_list"
10218 test -n "$verbose" && echo "search path $cf_search"
10219 cf_save2_CPPFLAGS="$CPPFLAGS"
10220 for cf_incdir in $cf_search
10223 if test -n "$cf_incdir" ; then
10224 for cf_add_incdir in $cf_incdir
10226 while test "$cf_add_incdir" != /usr/include
10228 if test -d "$cf_add_incdir"
10231 if test -n "$CFLAGS$CPPFLAGS" ; then
10232 # a loop is needed to ensure we can add subdirs of existing dirs
10233 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
10234 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
10235 cf_have_incdir=yes; break
10240 if test "$cf_have_incdir" = no ; then
10241 if test "$cf_add_incdir" = /usr/local/include ; then
10242 if test "$GCC" = yes
10244 cf_save_CPPFLAGS=$CPPFLAGS
10246 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
10247 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
10249 cat >"conftest.$ac_ext" <<_ACEOF
10250 #line 10250 "configure"
10251 #include "confdefs.h"
10261 rm -f "conftest.$ac_objext"
10262 if { (eval echo "$as_me:10262: \"$ac_compile\"") >&5
10263 (eval $ac_compile) 2>&5
10265 echo "$as_me:10265: \$? = $ac_status" >&5
10266 (exit "$ac_status"); } &&
10267 { ac_try='test -s "conftest.$ac_objext"'
10268 { (eval echo "$as_me:10268: \"$ac_try\"") >&5
10269 (eval $ac_try) 2>&5
10271 echo "$as_me:10271: \$? = $ac_status" >&5
10272 (exit "$ac_status"); }; }; then
10275 echo "$as_me: failed program was:" >&5
10276 cat "conftest.$ac_ext" >&5
10279 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
10280 CPPFLAGS=$cf_save_CPPFLAGS
10285 if test "$cf_have_incdir" = no ; then
10286 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
10288 echo "${as_me:-configure}:10288: testing adding $cf_add_incdir to include-path ..." 1>&5
10290 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
10292 cf_top_incdir=`echo "$cf_add_incdir" | sed -e 's%/include/.*$%/include%'`
10293 test "$cf_top_incdir" = "$cf_add_incdir" && break
10294 cf_add_incdir="$cf_top_incdir"
10310 cat >"conftest.$ac_ext" <<_ACEOF
10311 #line 10311 "configure"
10312 #include "confdefs.h"
10314 #include <$cf_header>
10319 #ifdef NCURSES_VERSION
10321 printf("%s\\n", NCURSES_VERSION);
10334 rm -f "conftest.$ac_objext"
10335 if { (eval echo "$as_me:10335: \"$ac_compile\"") >&5
10336 (eval $ac_compile) 2>&5
10338 echo "$as_me:10338: \$? = $ac_status" >&5
10339 (exit "$ac_status"); } &&
10340 { ac_try='test -s "conftest.$ac_objext"'
10341 { (eval echo "$as_me:10341: \"$ac_try\"") >&5
10342 (eval $ac_try) 2>&5
10344 echo "$as_me:10344: \$? = $ac_status" >&5
10345 (exit "$ac_status"); }; }; then
10346 cf_cv_ncurses_h2=$cf_header
10349 echo "$as_me: failed program was:" >&5
10350 cat "conftest.$ac_ext" >&5
10351 cf_cv_ncurses_h2=no
10353 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
10355 if test "$cf_cv_ncurses_h2" != no ; then
10356 cf_cv_ncurses_h2=$cf_incdir/$cf_header
10357 test -n "$verbose" && echo $ECHO_N " ... found $ECHO_C" 1>&6
10360 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
10362 CPPFLAGS="$cf_save2_CPPFLAGS"
10363 test "$cf_cv_ncurses_h2" != no && break
10365 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:10365: error: not found" >&5
10366 echo "$as_me: error: not found" >&2;}
10367 { (exit 1); exit 1; }; }
10370 echo "$as_me:10370: result: $cf_cv_ncurses_h2" >&5
10371 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
10373 cf_1st_incdir=`echo "$cf_cv_ncurses_h2" | sed -e 's%/[^/]*$%%'`
10374 cf_cv_ncurses_header="`basename "$cf_cv_ncurses_h2"`"
10375 if test "`basename "$cf_1st_incdir"`" = "$cf_ncuhdr_root" ; then
10376 cf_cv_ncurses_header="$cf_ncuhdr_root/$cf_cv_ncurses_header"
10379 if test -n "$cf_1st_incdir" ; then
10380 for cf_add_incdir in $cf_1st_incdir
10382 while test "$cf_add_incdir" != /usr/include
10384 if test -d "$cf_add_incdir"
10387 if test -n "$CFLAGS$CPPFLAGS" ; then
10388 # a loop is needed to ensure we can add subdirs of existing dirs
10389 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
10390 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
10391 cf_have_incdir=yes; break
10396 if test "$cf_have_incdir" = no ; then
10397 if test "$cf_add_incdir" = /usr/local/include ; then
10398 if test "$GCC" = yes
10400 cf_save_CPPFLAGS=$CPPFLAGS
10402 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
10403 CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
10405 cat >"conftest.$ac_ext" <<_ACEOF
10406 #line 10406 "configure"
10407 #include "confdefs.h"
10417 rm -f "conftest.$ac_objext"
10418 if { (eval echo "$as_me:10418: \"$ac_compile\"") >&5
10419 (eval $ac_compile) 2>&5
10421 echo "$as_me:10421: \$? = $ac_status" >&5
10422 (exit "$ac_status"); } &&
10423 { ac_try='test -s "conftest.$ac_objext"'
10424 { (eval echo "$as_me:10424: \"$ac_try\"") >&5
10425 (eval $ac_try) 2>&5
10427 echo "$as_me:10427: \$? = $ac_status" >&5
10428 (exit "$ac_status"); }; }; then
10431 echo "$as_me: failed program was:" >&5
10432 cat "conftest.$ac_ext" >&5
10435 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
10436 CPPFLAGS=$cf_save_CPPFLAGS
10441 if test "$cf_have_incdir" = no ; then
10442 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
10444 echo "${as_me:-configure}:10444: testing adding $cf_add_incdir to include-path ..." 1>&5
10446 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
10448 cf_top_incdir=`echo "$cf_add_incdir" | sed -e 's%/include/.*$%/include%'`
10449 test "$cf_top_incdir" = "$cf_add_incdir" && break
10450 cf_add_incdir="$cf_top_incdir"
10463 # Set definitions to allow ifdef'ing for ncurses.h
10465 case "$cf_cv_ncurses_header" in
10468 cat >>confdefs.h <<\EOF
10469 #define HAVE_NCURSES_H 1
10475 case "$cf_cv_ncurses_header" in
10476 (ncurses/curses.h|ncurses/ncurses.h)
10478 cat >>confdefs.h <<\EOF
10479 #define HAVE_NCURSES_NCURSES_H 1
10483 (ncursesw/curses.h|ncursesw/ncurses.h)
10485 cat >>confdefs.h <<\EOF
10486 #define HAVE_NCURSESW_NCURSES_H 1
10492 echo "$as_me:10492: checking for terminfo header" >&5
10493 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
10494 if test "${cf_cv_term_header+set}" = set; then
10495 echo $ECHO_N "(cached) $ECHO_C" >&6
10498 case "${cf_cv_ncurses_header}" in
10499 (*/ncurses.h|*/ncursesw.h)
10500 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
10503 cf_term_header=term.h
10507 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
10509 cat >"conftest.$ac_ext" <<_ACEOF
10510 #line 10510 "configure"
10511 #include "confdefs.h"
10513 #include <${cf_cv_ncurses_header:-curses.h}>
10514 #include <$cf_test>
10519 int x = auto_left_margin; (void)x
10524 rm -f "conftest.$ac_objext"
10525 if { (eval echo "$as_me:10525: \"$ac_compile\"") >&5
10526 (eval $ac_compile) 2>&5
10528 echo "$as_me:10528: \$? = $ac_status" >&5
10529 (exit "$ac_status"); } &&
10530 { ac_try='test -s "conftest.$ac_objext"'
10531 { (eval echo "$as_me:10531: \"$ac_try\"") >&5
10532 (eval $ac_try) 2>&5
10534 echo "$as_me:10534: \$? = $ac_status" >&5
10535 (exit "$ac_status"); }; }; then
10537 cf_cv_term_header="$cf_test"
10539 echo "$as_me: failed program was:" >&5
10540 cat "conftest.$ac_ext" >&5
10542 cf_cv_term_header=unknown
10545 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
10546 test "$cf_cv_term_header" != unknown && break
10550 echo "$as_me:10550: result: $cf_cv_term_header" >&5
10551 echo "${ECHO_T}$cf_cv_term_header" >&6
10553 # Set definitions to allow ifdef'ing to accommodate subdirectories
10555 case "$cf_cv_term_header" in
10558 cat >>confdefs.h <<\EOF
10559 #define HAVE_TERM_H 1
10565 case "$cf_cv_term_header" in
10568 cat >>confdefs.h <<\EOF
10569 #define HAVE_NCURSES_TERM_H 1
10575 cat >>confdefs.h <<\EOF
10576 #define HAVE_NCURSESW_TERM_H 1
10582 # some applications need this, but should check for NCURSES_VERSION
10584 cat >>confdefs.h <<\EOF
10588 echo "$as_me:10588: checking for ncurses version" >&5
10589 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
10590 if test "${cf_cv_ncurses_version+set}" = set; then
10591 echo $ECHO_N "(cached) $ECHO_C" >&6
10594 cf_cv_ncurses_version=no
10596 rm -f "$cf_tempfile"
10597 if test "$cross_compiling" = yes; then
10599 # This will not work if the preprocessor splits the line after the
10600 # Autoconf token. The 'unproto' program does that.
10601 cat > "conftest.$ac_ext" <<EOF
10602 #include <${cf_cv_ncurses_header:-curses.h}>
10604 #ifdef NCURSES_VERSION
10605 Autoconf NCURSES_VERSION
10613 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
10614 { (eval echo "$as_me:10614: \"$cf_try\"") >&5
10615 (eval $cf_try) 2>&5
10617 echo "$as_me:10617: \$? = $ac_status" >&5
10618 (exit "$ac_status"); }
10619 if test -f conftest.out ; then
10620 cf_out=`sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%' conftest.out`
10621 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
10626 cat >"conftest.$ac_ext" <<_ACEOF
10627 #line 10627 "configure"
10628 #include "confdefs.h"
10630 #include <${cf_cv_ncurses_header:-curses.h}>
10634 FILE *fp = fopen("$cf_tempfile", "w");
10635 #ifdef NCURSES_VERSION
10636 # ifdef NCURSES_VERSION_PATCH
10637 fprintf(fp, "%s.%d\\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
10639 fprintf(fp, "%s\\n", NCURSES_VERSION);
10642 # ifdef __NCURSES_H
10643 fprintf(fp, "old\\n");
10648 ${cf_cv_main_return:-return}(0);
10651 rm -f "conftest$ac_exeext"
10652 if { (eval echo "$as_me:10652: \"$ac_link\"") >&5
10653 (eval $ac_link) 2>&5
10655 echo "$as_me:10655: \$? = $ac_status" >&5
10656 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
10657 { (eval echo "$as_me:10657: \"$ac_try\"") >&5
10658 (eval $ac_try) 2>&5
10660 echo "$as_me:10660: \$? = $ac_status" >&5
10661 (exit "$ac_status"); }; }; then
10663 cf_cv_ncurses_version=`cat $cf_tempfile`
10665 echo "$as_me: program exited with status $ac_status" >&5
10666 echo "$as_me: failed program was:" >&5
10667 cat "conftest.$ac_ext" >&5
10669 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
10671 rm -f "$cf_tempfile"
10674 echo "$as_me:10674: result: $cf_cv_ncurses_version" >&5
10675 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
10676 test "$cf_cv_ncurses_version" = no ||
10677 cat >>confdefs.h <<\EOF
10681 cf_nculib_root=ncurses
10682 # This works, except for the special case where we find gpm, but
10683 # ncurses is in a nonstandard location via $LIBS, and we really want
10686 cf_ncurses_SAVE="$LIBS"
10687 echo "$as_me:10687: checking for Gpm_Open in -lgpm" >&5
10688 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
10689 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
10690 echo $ECHO_N "(cached) $ECHO_C" >&6
10692 ac_check_lib_save_LIBS=$LIBS
10694 cat >"conftest.$ac_ext" <<_ACEOF
10695 #line 10695 "configure"
10696 #include "confdefs.h"
10698 /* Override any gcc2 internal prototype to avoid an error. */
10702 /* We use char because int might match the return type of a gcc2
10703 builtin and then its argument prototype would still apply. */
10713 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
10714 if { (eval echo "$as_me:10714: \"$ac_link\"") >&5
10715 (eval $ac_link) 2>&5
10717 echo "$as_me:10717: \$? = $ac_status" >&5
10718 (exit "$ac_status"); } &&
10719 { ac_try='test -s "conftest$ac_exeext"'
10720 { (eval echo "$as_me:10720: \"$ac_try\"") >&5
10721 (eval $ac_try) 2>&5
10723 echo "$as_me:10723: \$? = $ac_status" >&5
10724 (exit "$ac_status"); }; }; then
10725 ac_cv_lib_gpm_Gpm_Open=yes
10727 echo "$as_me: failed program was:" >&5
10728 cat "conftest.$ac_ext" >&5
10729 ac_cv_lib_gpm_Gpm_Open=no
10731 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
10732 LIBS=$ac_check_lib_save_LIBS
10734 echo "$as_me:10734: result: $ac_cv_lib_gpm_Gpm_Open" >&5
10735 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
10736 if test "$ac_cv_lib_gpm_Gpm_Open" = yes; then
10737 echo "$as_me:10737: checking for initscr in -lgpm" >&5
10738 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
10739 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
10740 echo $ECHO_N "(cached) $ECHO_C" >&6
10742 ac_check_lib_save_LIBS=$LIBS
10744 cat >"conftest.$ac_ext" <<_ACEOF
10745 #line 10745 "configure"
10746 #include "confdefs.h"
10748 /* Override any gcc2 internal prototype to avoid an error. */
10752 /* We use char because int might match the return type of a gcc2
10753 builtin and then its argument prototype would still apply. */
10763 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
10764 if { (eval echo "$as_me:10764: \"$ac_link\"") >&5
10765 (eval $ac_link) 2>&5
10767 echo "$as_me:10767: \$? = $ac_status" >&5
10768 (exit "$ac_status"); } &&
10769 { ac_try='test -s "conftest$ac_exeext"'
10770 { (eval echo "$as_me:10770: \"$ac_try\"") >&5
10771 (eval $ac_try) 2>&5
10773 echo "$as_me:10773: \$? = $ac_status" >&5
10774 (exit "$ac_status"); }; }; then
10775 ac_cv_lib_gpm_initscr=yes
10777 echo "$as_me: failed program was:" >&5
10778 cat "conftest.$ac_ext" >&5
10779 ac_cv_lib_gpm_initscr=no
10781 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
10782 LIBS=$ac_check_lib_save_LIBS
10784 echo "$as_me:10784: result: $ac_cv_lib_gpm_initscr" >&5
10785 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
10786 if test "$ac_cv_lib_gpm_initscr" = yes; then
10787 LIBS="$cf_ncurses_SAVE"
10789 cf_ncurses_LIBS="-lgpm"
10796 # This is only necessary if you are linking against an obsolete
10797 # version of ncurses (but it should do no harm, since it's static).
10798 if test "$cf_nculib_root" = ncurses ; then
10799 echo "$as_me:10799: checking for tgoto in -lmytinfo" >&5
10800 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
10801 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
10802 echo $ECHO_N "(cached) $ECHO_C" >&6
10804 ac_check_lib_save_LIBS=$LIBS
10805 LIBS="-lmytinfo $LIBS"
10806 cat >"conftest.$ac_ext" <<_ACEOF
10807 #line 10807 "configure"
10808 #include "confdefs.h"
10810 /* Override any gcc2 internal prototype to avoid an error. */
10814 /* We use char because int might match the return type of a gcc2
10815 builtin and then its argument prototype would still apply. */
10825 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
10826 if { (eval echo "$as_me:10826: \"$ac_link\"") >&5
10827 (eval $ac_link) 2>&5
10829 echo "$as_me:10829: \$? = $ac_status" >&5
10830 (exit "$ac_status"); } &&
10831 { ac_try='test -s "conftest$ac_exeext"'
10832 { (eval echo "$as_me:10832: \"$ac_try\"") >&5
10833 (eval $ac_try) 2>&5
10835 echo "$as_me:10835: \$? = $ac_status" >&5
10836 (exit "$ac_status"); }; }; then
10837 ac_cv_lib_mytinfo_tgoto=yes
10839 echo "$as_me: failed program was:" >&5
10840 cat "conftest.$ac_ext" >&5
10841 ac_cv_lib_mytinfo_tgoto=no
10843 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
10844 LIBS=$ac_check_lib_save_LIBS
10846 echo "$as_me:10846: result: $ac_cv_lib_mytinfo_tgoto" >&5
10847 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
10848 if test "$ac_cv_lib_mytinfo_tgoto" = yes; then
10849 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
10856 cf_add_libs="$LIBS"
10859 for cf_add_1lib in $cf_ncurses_LIBS; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
10860 # filter duplicates
10861 for cf_add_1lib in $cf_add_0lib; do
10862 for cf_add_2lib in $cf_add_libs; do
10863 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
10868 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
10870 LIBS="$cf_add_libs"
10872 if test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no"
10875 cf_add_libs="$LIBS"
10878 for cf_add_1lib in -l$cf_nculib_root; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
10879 # filter duplicates
10880 for cf_add_1lib in $cf_add_0lib; do
10881 for cf_add_2lib in $cf_add_libs; do
10882 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
10887 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
10889 LIBS="$cf_add_libs"
10893 eval 'cf_cv_have_lib_'"$cf_nculib_root"'=no'
10895 echo "$as_me:10895: checking for initscr" >&5
10896 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
10897 if test "${ac_cv_func_initscr+set}" = set; then
10898 echo $ECHO_N "(cached) $ECHO_C" >&6
10900 cat >"conftest.$ac_ext" <<_ACEOF
10901 #line 10901 "configure"
10902 #include "confdefs.h"
10903 #define initscr autoconf_temporary
10904 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
10911 /* We use char because int might match the return type of a gcc2
10912 builtin and then its argument prototype would still apply. */
10913 char initscr (void);
10919 /* The GNU C library defines stubs for functions which it implements
10920 to always fail with ENOSYS. Some functions are actually named
10921 something starting with __ and the normal name is an alias. */
10922 #if defined (__stub_initscr) || defined (__stub___initscr)
10923 #error found stub for initscr
10931 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
10932 if { (eval echo "$as_me:10932: \"$ac_link\"") >&5
10933 (eval $ac_link) 2>&5
10935 echo "$as_me:10935: \$? = $ac_status" >&5
10936 (exit "$ac_status"); } &&
10937 { ac_try='test -s "conftest$ac_exeext"'
10938 { (eval echo "$as_me:10938: \"$ac_try\"") >&5
10939 (eval $ac_try) 2>&5
10941 echo "$as_me:10941: \$? = $ac_status" >&5
10942 (exit "$ac_status"); }; }; then
10943 ac_cv_func_initscr=yes
10945 echo "$as_me: failed program was:" >&5
10946 cat "conftest.$ac_ext" >&5
10947 ac_cv_func_initscr=no
10949 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
10951 echo "$as_me:10951: result: $ac_cv_func_initscr" >&5
10952 echo "${ECHO_T}$ac_cv_func_initscr" >&6
10953 if test "$ac_cv_func_initscr" = yes; then
10954 eval 'cf_cv_have_lib_'"$cf_nculib_root"'=yes'
10957 cf_save_LIBS="$LIBS"
10958 echo "$as_me:10958: checking for initscr in -l$cf_nculib_root" >&5
10959 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
10960 LIBS="-l$cf_nculib_root $LIBS"
10961 cat >"conftest.$ac_ext" <<_ACEOF
10962 #line 10962 "configure"
10963 #include "confdefs.h"
10964 #include <${cf_cv_ncurses_header:-curses.h}>
10973 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
10974 if { (eval echo "$as_me:10974: \"$ac_link\"") >&5
10975 (eval $ac_link) 2>&5
10977 echo "$as_me:10977: \$? = $ac_status" >&5
10978 (exit "$ac_status"); } &&
10979 { ac_try='test -s "conftest$ac_exeext"'
10980 { (eval echo "$as_me:10980: \"$ac_try\"") >&5
10981 (eval $ac_try) 2>&5
10983 echo "$as_me:10983: \$? = $ac_status" >&5
10984 (exit "$ac_status"); }; }; then
10985 echo "$as_me:10985: result: yes" >&5
10986 echo "${ECHO_T}yes" >&6
10987 eval 'cf_cv_have_lib_'"$cf_nculib_root"'=yes'
10990 echo "$as_me: failed program was:" >&5
10991 cat "conftest.$ac_ext" >&5
10992 echo "$as_me:10992: result: no" >&5
10993 echo "${ECHO_T}no" >&6
10996 cf_library_path_list=""
10997 if test -n "${LDFLAGS}${LIBS}" ; then
10998 for cf_library_path in $LDFLAGS $LIBS
11000 case "$cf_library_path" in
11002 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
11004 test "x$cf_library_path" != "xNONE" && \
11005 test -d "$cf_library_path" && \
11007 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
11008 test -d "$cf_library_path/lib" && cf_search="$cf_search $cf_library_path/lib"
11009 test -d "$cf_library_path/lib/$cf_nculib_root" && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
11010 test -d "$cf_library_path/lib/$cf_nculib_root/lib" && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
11011 test -d "$cf_library_path/$cf_nculib_root/lib" && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
11012 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"
11015 cf_library_path_list="$cf_library_path_list $cf_search"
11023 test "x$prefix" != "xNONE" && \
11024 test -d "$prefix" && \
11026 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
11027 test -d "$prefix/lib" && cf_search="$cf_search $prefix/lib"
11028 test -d "$prefix/lib/$cf_nculib_root" && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
11029 test -d "$prefix/lib/$cf_nculib_root/lib" && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
11030 test -d "$prefix/$cf_nculib_root/lib" && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
11031 test -d "$prefix/$cf_nculib_root/lib/$cf_nculib_root" && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
11034 for cf_subdir_prefix in \
11043 test "x$cf_subdir_prefix" != "x$prefix" && \
11044 test -d "$cf_subdir_prefix" && \
11045 { test -z "$prefix" || test "x$prefix" = xNONE || test "x$cf_subdir_prefix" != "x$prefix"; } && {
11046 test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
11047 test -d "$cf_subdir_prefix/lib" && cf_search="$cf_search $cf_subdir_prefix/lib"
11048 test -d "$cf_subdir_prefix/lib/$cf_nculib_root" && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root"
11049 test -d "$cf_subdir_prefix/lib/$cf_nculib_root/lib" && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root/lib"
11050 test -d "$cf_subdir_prefix/$cf_nculib_root/lib" && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib"
11051 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"
11056 cf_search="$cf_library_path_list $cf_search"
11058 for cf_libdir in $cf_search
11060 echo "$as_me:11060: checking for -l$cf_nculib_root in $cf_libdir" >&5
11061 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
11062 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
11063 cat >"conftest.$ac_ext" <<_ACEOF
11064 #line 11064 "configure"
11065 #include "confdefs.h"
11066 #include <${cf_cv_ncurses_header:-curses.h}>
11075 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
11076 if { (eval echo "$as_me:11076: \"$ac_link\"") >&5
11077 (eval $ac_link) 2>&5
11079 echo "$as_me:11079: \$? = $ac_status" >&5
11080 (exit "$ac_status"); } &&
11081 { ac_try='test -s "conftest$ac_exeext"'
11082 { (eval echo "$as_me:11082: \"$ac_try\"") >&5
11083 (eval $ac_try) 2>&5
11085 echo "$as_me:11085: \$? = $ac_status" >&5
11086 (exit "$ac_status"); }; }; then
11087 echo "$as_me:11087: result: yes" >&5
11088 echo "${ECHO_T}yes" >&6
11089 eval 'cf_cv_have_lib_'"$cf_nculib_root"'=yes'
11092 echo "$as_me: failed program was:" >&5
11093 cat "conftest.$ac_ext" >&5
11094 echo "$as_me:11094: result: no" >&5
11095 echo "${ECHO_T}no" >&6
11096 LIBS="$cf_save_LIBS"
11098 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
11102 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
11106 eval 'cf_found_library="$cf_cv_have_lib_'"$cf_nculib_root"\"
11108 if test "$cf_found_library" = no ; then
11109 { { echo "$as_me:11109: error: Cannot link $cf_nculib_root library" >&5
11110 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
11111 { (exit 1); exit 1; }; }
11116 if test -n "$cf_ncurses_LIBS" ; then
11117 echo "$as_me:11117: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
11118 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
11119 cf_ncurses_SAVE="$LIBS"
11120 for p in $cf_ncurses_LIBS ; do
11121 q=`echo "$LIBS" | sed -e "s%$p %%" -e "s%$p$%%"`
11122 if test "$q" != "$LIBS" ; then
11126 cat >"conftest.$ac_ext" <<_ACEOF
11127 #line 11127 "configure"
11128 #include "confdefs.h"
11129 #include <${cf_cv_ncurses_header:-curses.h}>
11133 initscr(); mousemask(0,0); tigetstr((char *)0);
11138 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
11139 if { (eval echo "$as_me:11139: \"$ac_link\"") >&5
11140 (eval $ac_link) 2>&5
11142 echo "$as_me:11142: \$? = $ac_status" >&5
11143 (exit "$ac_status"); } &&
11144 { ac_try='test -s "conftest$ac_exeext"'
11145 { (eval echo "$as_me:11145: \"$ac_try\"") >&5
11146 (eval $ac_try) 2>&5
11148 echo "$as_me:11148: \$? = $ac_status" >&5
11149 (exit "$ac_status"); }; }; then
11150 echo "$as_me:11150: result: yes" >&5
11151 echo "${ECHO_T}yes" >&6
11153 echo "$as_me: failed program was:" >&5
11154 cat "conftest.$ac_ext" >&5
11155 echo "$as_me:11155: result: no" >&5
11156 echo "${ECHO_T}no" >&6
11157 LIBS="$cf_ncurses_SAVE"
11159 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
11162 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
11164 cat >>confdefs.h <<EOF
11165 #define $cf_nculib_ROOT 1
11170 NCURSES_CONFIG=none
11175 if test "$NCURSES_CONFIG_PKG" != none ; then
11176 cf_version=`$PKG_CONFIG --modversion $NCURSES_CONFIG_PKG 2>/dev/null`
11178 NCURSES_MAJOR=`echo "$cf_version" | sed -e 's/\..*//'`
11179 NCURSES_MINOR=`echo "$cf_version" | sed -e 's/^[0-9][0-9]*\.//' -e 's/\..*//'`
11180 NCURSES_PATCH=`echo "$cf_version" | sed -e 's/^[0-9][0-9]*\.[0-9][0-9]*\.//'`
11182 cf_cv_abi_version=`$PKG_CONFIG --variable=abi_version $NCURSES_CONFIG_PKG 2>/dev/null`
11183 if test -z "$cf_cv_abi_version"
11185 cf_cv_abi_version=`$PKG_CONFIG --variable=major_version $NCURSES_CONFIG_PKG 2>/dev/null`
11188 elif test "$NCURSES_CONFIG" != none ; then
11190 cf_version=`$NCURSES_CONFIG --version 2>/dev/null`
11192 NCURSES_MAJOR=`echo "$cf_version" | sed -e 's/\..*//'`
11193 NCURSES_MINOR=`echo "$cf_version" | sed -e 's/^[0-9][0-9]*\.//' -e 's/\..*//'`
11194 NCURSES_PATCH=`echo "$cf_version" | sed -e 's/^[0-9][0-9]*\.[0-9][0-9]*\.//'`
11196 # ABI version is not available from headers
11197 cf_cv_abi_version=`$NCURSES_CONFIG --abi-version 2>/dev/null`
11201 for cf_name in MAJOR MINOR PATCH
11203 cat >conftest.$ac_ext <<CF_EOF
11204 #include <${cf_cv_ncurses_header:-curses.h}>
11205 AUTOCONF_$cf_name NCURSES_VERSION_$cf_name
11207 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | fgrep AUTOCONF_$cf_name >conftest.out"
11208 { (eval echo "$as_me:11208: \"$cf_try\"") >&5
11209 (eval $cf_try) 2>&5
11211 echo "$as_me:11211: \$? = $ac_status" >&5
11212 (exit "$ac_status"); }
11213 if test -f conftest.out ; then
11214 cf_result=`sed -e "s/^.*AUTOCONF_${cf_name}[ ][ ]*//" conftest.out`
11215 eval NCURSES_$cf_name=\"$cf_result\"
11216 # cat conftest.$ac_ext
11221 cf_cv_abi_version=${NCURSES_MAJOR}
11225 cf_cv_rel_version=${NCURSES_MAJOR}.${NCURSES_MINOR}
11227 cf_cv_timestamp=`date`
11229 echo "$as_me:11229: result: Configuring NCURSES $cf_cv_rel_version ABI $cf_cv_abi_version ($cf_cv_timestamp)" >&5
11230 echo "${ECHO_T}Configuring NCURSES $cf_cv_rel_version ABI $cf_cv_abi_version ($cf_cv_timestamp)" >&6
11232 echo "$as_me:11232: checking if you want to have a library-prefix" >&5
11233 echo $ECHO_N "checking if you want to have a library-prefix... $ECHO_C" >&6
11235 # Check whether --with-lib-prefix or --without-lib-prefix was given.
11236 if test "${with_lib_prefix+set}" = set; then
11237 withval="$with_lib_prefix"
11238 with_lib_prefix=$withval
11240 with_lib_prefix=auto
11242 echo "$as_me:11242: result: $with_lib_prefix" >&5
11243 echo "${ECHO_T}$with_lib_prefix" >&6
11245 if test "$with_lib_prefix" = auto
11248 case "$cf_cv_system_name" in
11250 if test "$DFT_LWR_MODEL" = libtool; then
11259 (*) LIB_PREFIX='lib'
11262 cf_prefix=$LIB_PREFIX
11264 elif test "$with_lib_prefix" = no
11268 LIB_PREFIX=$with_lib_prefix
11273 ###############################################################################
11275 if test X"$CC_G_OPT" = X"" ; then
11277 test -n "$GCC" && test "${ac_cv_prog_cc_g}" != yes && CC_G_OPT=''
11280 echo "$as_me:11280: checking for default loader flags" >&5
11281 echo $ECHO_N "checking for default loader flags... $ECHO_C" >&6
11282 case $DFT_LWR_MODEL in
11283 (normal) LD_MODEL='' ;;
11284 (debug) LD_MODEL=$CC_G_OPT ;;
11285 (profile) LD_MODEL='-pg';;
11286 (shared) LD_MODEL='' ;;
11288 echo "$as_me:11288: result: $LD_MODEL" >&5
11289 echo "${ECHO_T}$LD_MODEL" >&6
11292 if test "x$cf_cv_enable_rpath" != xno
11294 echo "$as_me:11294: checking for an rpath option" >&5
11295 echo $ECHO_N "checking for an rpath option... $ECHO_C" >&6
11296 case "$cf_cv_system_name" in
11298 if test "$GCC" = yes; then
11299 LD_RPATH_OPT="-Wl,-rpath,"
11301 LD_RPATH_OPT="-rpath "
11304 (linux*|gnu*|k*bsd*-gnu|freebsd*)
11305 LD_RPATH_OPT="-Wl,-rpath,"
11307 (openbsd[2-9].*|mirbsd*)
11308 LD_RPATH_OPT="-Wl,-rpath,"
11311 LD_RPATH_OPT="-rpath "
11314 LD_RPATH_OPT="-Wl,-rpath,"
11317 LD_RPATH_OPT="-rpath "
11325 echo "$as_me:11325: result: $LD_RPATH_OPT" >&5
11326 echo "${ECHO_T}$LD_RPATH_OPT" >&6
11328 case "x$LD_RPATH_OPT" in
11330 echo "$as_me:11330: checking if we need a space after rpath option" >&5
11331 echo $ECHO_N "checking if we need a space after rpath option... $ECHO_C" >&6
11332 cf_save_LIBS="$LIBS"
11334 cf_add_libs="$LIBS"
11337 for cf_add_1lib in ${LD_RPATH_OPT}$libdir; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
11338 # filter duplicates
11339 for cf_add_1lib in $cf_add_0lib; do
11340 for cf_add_2lib in $cf_add_libs; do
11341 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
11346 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
11348 LIBS="$cf_add_libs"
11350 cat >"conftest.$ac_ext" <<_ACEOF
11351 #line 11351 "configure"
11352 #include "confdefs.h"
11362 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
11363 if { (eval echo "$as_me:11363: \"$ac_link\"") >&5
11364 (eval $ac_link) 2>&5
11366 echo "$as_me:11366: \$? = $ac_status" >&5
11367 (exit "$ac_status"); } &&
11368 { ac_try='test -s "conftest$ac_exeext"'
11369 { (eval echo "$as_me:11369: \"$ac_try\"") >&5
11370 (eval $ac_try) 2>&5
11372 echo "$as_me:11372: \$? = $ac_status" >&5
11373 (exit "$ac_status"); }; }; then
11376 echo "$as_me: failed program was:" >&5
11377 cat "conftest.$ac_ext" >&5
11380 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
11381 LIBS="$cf_save_LIBS"
11382 echo "$as_me:11382: result: $cf_rpath_space" >&5
11383 echo "${ECHO_T}$cf_rpath_space" >&6
11384 test "$cf_rpath_space" = yes && LD_RPATH_OPT="$LD_RPATH_OPT "
11393 INSTALL_LIB="-m 644"
11394 : ${rel_builddir:=.}
11400 cf_cv_do_symlinks=no
11402 test "$cf_cv_enable_rpath" = yes && cf_ld_rpath_opt="$LD_RPATH_OPT"
11404 echo "$as_me:11404: checking if release/abi version should be used for shared libs" >&5
11405 echo $ECHO_N "checking if release/abi version should be used for shared libs... $ECHO_C" >&6
11407 # Check whether --with-shlib-version or --without-shlib-version was given.
11408 if test "${with_shlib_version+set}" = set; then
11409 withval="$with_shlib_version"
11410 test -z "$withval" && withval=auto
11413 cf_cv_shlib_version=auto
11416 cf_cv_shlib_version=$withval
11419 echo "$as_me:11419: result: $withval" >&5
11420 echo "${ECHO_T}$withval" >&6
11421 { { echo "$as_me:11421: error: option value must be one of: rel, abi, or auto" >&5
11422 echo "$as_me: error: option value must be one of: rel, abi, or auto" >&2;}
11423 { (exit 1); exit 1; }; }
11428 cf_cv_shlib_version=auto
11430 echo "$as_me:11430: result: $cf_cv_shlib_version" >&5
11431 echo "${ECHO_T}$cf_cv_shlib_version" >&6
11433 cf_cv_rm_so_locs=no
11436 # Some less-capable ports of gcc support only -fpic
11440 if test "$GCC" = yes
11444 case "$cf_cv_system_name" in
11445 (*linux*) # e.g., PGI compiler
11451 if test "$cf_try_fPIC" = yes
11453 echo "$as_me:11453: checking which $CC option to use" >&5
11454 echo $ECHO_N "checking which $CC option to use... $ECHO_C" >&6
11455 cf_save_CFLAGS="$CFLAGS"
11456 for CC_SHARED_OPTS in -fPIC -fpic ''
11458 CFLAGS="$cf_save_CFLAGS $CC_SHARED_OPTS"
11459 cat >"conftest.$ac_ext" <<_ACEOF
11460 #line 11460 "configure"
11461 #include "confdefs.h"
11471 rm -f "conftest.$ac_objext"
11472 if { (eval echo "$as_me:11472: \"$ac_compile\"") >&5
11473 (eval $ac_compile) 2>&5
11475 echo "$as_me:11475: \$? = $ac_status" >&5
11476 (exit "$ac_status"); } &&
11477 { ac_try='test -s "conftest.$ac_objext"'
11478 { (eval echo "$as_me:11478: \"$ac_try\"") >&5
11479 (eval $ac_try) 2>&5
11481 echo "$as_me:11481: \$? = $ac_status" >&5
11482 (exit "$ac_status"); }; }; then
11485 echo "$as_me: failed program was:" >&5
11486 cat "conftest.$ac_ext" >&5
11488 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
11490 echo "$as_me:11490: result: $CC_SHARED_OPTS" >&5
11491 echo "${ECHO_T}$CC_SHARED_OPTS" >&6
11492 CFLAGS="$cf_save_CFLAGS"
11495 cf_cv_shlib_version_infix=no
11497 case "$cf_cv_system_name" in
11498 (aix4.3-9*|aix[5-7]*)
11499 if test "$GCC" = yes; then
11500 CC_SHARED_OPTS='-Wl,-brtl'
11501 MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -shared -Wl,-brtl -Wl,-blibpath:${RPATH_LIST}:/usr/lib -o $@'
11503 CC_SHARED_OPTS='-brtl'
11504 # as well as '-qpic=large -G' or perhaps "-bM:SRE -bnoentry -bexpall"
11505 MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -G -Wl,-brtl -Wl,-blibpath:${RPATH_LIST}:/usr/lib -o $@'
11509 MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -o $@ -Xlinker -soname=`basename $@` -nostart -e 0'
11513 MK_SHARED_LIB=$SHELL' '$rel_builddir'/mk_shared_lib.sh $@ ${CC} ${CFLAGS}'
11514 RM_SHARED_OPTS="$RM_SHARED_OPTS $rel_builddir/mk_shared_lib.sh *.dll.a"
11515 cf_cv_shlib_version=cygdll
11516 cf_cv_shlib_version_infix=cygdll
11519 cat >mk_shared_lib.sh <<-CF_EOF
11522 IMPORT_LIB=\`echo "\$1" | sed -e 's/cyg/lib/' -e 's/[0-9]*\.dll$/.dll.a/'\`
11525 Linking shared library
11526 ** SHARED_LIB \$SHARED_LIB
11527 ** IMPORT_LIB \$IMPORT_LIB
11529 exec \$* ${LDFLAGS} -shared -Wl,--out-implib=\${IMPORT_LIB} -Wl,--export-all-symbols -o \${SHARED_LIB}
11531 chmod +x mk_shared_lib.sh
11535 MK_SHARED_LIB=$SHELL' '$rel_builddir'/mk_shared_lib.sh $@ ${CC} ${CFLAGS}'
11536 RM_SHARED_OPTS="$RM_SHARED_OPTS $rel_builddir/mk_shared_lib.sh *.dll.a"
11537 cf_cv_shlib_version=msysdll
11538 cf_cv_shlib_version_infix=msysdll
11541 cat >mk_shared_lib.sh <<-CF_EOF
11544 IMPORT_LIB=\`echo "\$1" | sed -e 's/msys-/lib/' -e 's/[0-9]*\.dll$/.dll.a/'\`
11547 Linking shared library
11548 ** SHARED_LIB \$SHARED_LIB
11549 ** IMPORT_LIB \$IMPORT_LIB
11551 exec \$* ${LDFLAGS} -shared -Wl,--out-implib=\${IMPORT_LIB} -Wl,--export-all-symbols -o \${SHARED_LIB}
11553 chmod +x mk_shared_lib.sh
11556 cf_try_cflags="no-cpp-precomp"
11557 CC_SHARED_OPTS="-dynamic"
11558 MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -dynamiclib -install_name ${libdir}/`basename $@` -compatibility_version ${ABI_VERSION} -current_version ${ABI_VERSION} -o $@'
11559 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=abi
11560 cf_cv_shlib_version_infix=yes
11561 echo "$as_me:11561: checking if ld -search_paths_first works" >&5
11562 echo $ECHO_N "checking if ld -search_paths_first works... $ECHO_C" >&6
11563 if test "${cf_cv_ldflags_search_paths_first+set}" = set; then
11564 echo $ECHO_N "(cached) $ECHO_C" >&6
11567 cf_save_LDFLAGS=$LDFLAGS
11568 LDFLAGS="$LDFLAGS -Wl,-search_paths_first"
11569 cat >"conftest.$ac_ext" <<_ACEOF
11570 #line 11570 "configure"
11571 #include "confdefs.h"
11581 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
11582 if { (eval echo "$as_me:11582: \"$ac_link\"") >&5
11583 (eval $ac_link) 2>&5
11585 echo "$as_me:11585: \$? = $ac_status" >&5
11586 (exit "$ac_status"); } &&
11587 { ac_try='test -s "conftest$ac_exeext"'
11588 { (eval echo "$as_me:11588: \"$ac_try\"") >&5
11589 (eval $ac_try) 2>&5
11591 echo "$as_me:11591: \$? = $ac_status" >&5
11592 (exit "$ac_status"); }; }; then
11593 cf_cv_ldflags_search_paths_first=yes
11595 echo "$as_me: failed program was:" >&5
11596 cat "conftest.$ac_ext" >&5
11597 cf_cv_ldflags_search_paths_first=no
11599 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
11600 LDFLAGS=$cf_save_LDFLAGS
11602 echo "$as_me:11602: result: $cf_cv_ldflags_search_paths_first" >&5
11603 echo "${ECHO_T}$cf_cv_ldflags_search_paths_first" >&6
11604 if test "$cf_cv_ldflags_search_paths_first" = yes; then
11605 LDFLAGS="$LDFLAGS -Wl,-search_paths_first"
11609 # HP-UX 8.07 ld lacks "+b" option used for libdir search-list
11610 if test "$GCC" != yes; then
11611 CC_SHARED_OPTS='+Z'
11613 MK_SHARED_LIB='${LD} ${LDFLAGS} -b -o $@'
11614 INSTALL_LIB="-m 555"
11617 # (tested with gcc 2.7.2 -- I don't have c89)
11618 if test "$GCC" = yes; then
11619 LD_SHARED_OPTS='-Xlinker +b -Xlinker ${libdir}'
11621 CC_SHARED_OPTS='+Z'
11622 LD_SHARED_OPTS='-Wl,+b,${libdir}'
11624 MK_SHARED_LIB='${LD} ${LDFLAGS} +b ${libdir} -b -o $@'
11625 # HP-UX shared libraries must be executable, and should be
11626 # readonly to exploit a quirk in the memory manager.
11627 INSTALL_LIB="-m 555"
11630 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
11631 if test "$cf_cv_shlib_version" = rel; then
11632 cf_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
11634 cf_shared_soname='`basename $@`'
11637 MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -shared -Wl,-rpath,${RPATH_LIST} -Wl,-h,'$cf_shared_soname' -o $@'
11640 if test "$cf_cv_enable_rpath" = yes ; then
11641 EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${RPATH_LIST} $EXTRA_LDFLAGS"
11643 # tested with IRIX 5.2 and 'cc'.
11644 if test "$GCC" != yes; then
11645 CC_SHARED_OPTS='-KPIC'
11646 MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -shared -rdata_shared -soname `basename $@` -o $@'
11648 MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -shared -Wl,-soname,`basename $@` -o $@'
11650 cf_cv_rm_so_locs=yes
11652 (linux*|gnu*|k*bsd*-gnu)
11653 if test "$DFT_LWR_MODEL" = "shared" && test -n "$LD_RPATH_OPT" ; then
11654 LOCAL_LDFLAGS="${LD_RPATH_OPT}\$(LOCAL_LIBDIR)"
11655 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
11657 if test "$cf_cv_enable_rpath" = yes ; then
11658 EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${RPATH_LIST} $EXTRA_LDFLAGS"
11661 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
11662 if test "$cf_cv_shlib_version" = rel; then
11663 cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
11665 cf_cv_shared_soname='`basename $@`'
11668 MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -shared -Wl,-soname,'$cf_cv_shared_soname',-stats,-lc -o $@'
11671 cf_cv_shlib_version=msvcdll
11672 cf_cv_shlib_version_infix=msvcdll
11675 if test "$DFT_LWR_MODEL" = "shared" ; then
11676 LOCAL_LDFLAGS="-link -dll"
11677 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
11678 EXTRA_LDFLAGS="-link -dll $EXTRA_LDFLAGS"
11681 MK_SHARED_LIB=$SHELL' '$rel_builddir'/mk_shared_lib.sh $@ ${LD} ${CFLAGS}'
11682 RM_SHARED_OPTS="$RM_SHARED_OPTS $rel_builddir/mk_shared_lib.sh *.dll.lib"
11683 cat >mk_shared_lib.sh <<-CF_EOF
11686 IMPORT_LIB=\`echo "\$1" | sed -e 's/[0-9]*\.dll$/.dll.lib/'\`
11691 Linking shared library
11692 ** SHARED LIB \$SHARED_LIB
11693 ** IMPORT_LIB \$IMPORT_LIB
11695 args=\$(echo \$* | sed -E "s#-l(\w*)#\1.dll.lib#g" | sed -E "s#-L(\w*)#-LIBPATH:\1#g")
11696 exec \$my_ld -DLL -IMPLIB:"\${IMPORT_LIB}" -OUT:"\${SHARED_LIB}" ${LDFLAGS} \$args
11697 mv "\${IMPORT_LIB}" "\${IMPORT_LIB}"
11699 chmod +x mk_shared_lib.sh
11700 cat >mk_prog.sh <<-CF_EOF
11703 # Ignore first argument (compiler) and use LD (link.exe) unconditionally
11706 ldopts=("/subsystem:console")
11709 while test \$# -gt 0; do
11712 # ignore -link argument
11715 # ignore runtime-library option
11730 libs+=("\`echo \"\$1\" | sed \"s/^-l//\"\`")
11733 ldopts+=("\`echo \"\$1\" | sed \"s/^-L/-LIBPATH:/\"\`")
11739 for linkarg in \`echo '\$1' | sed -e 's/-Wl,//' -e 's/,/ /'\`; do
11740 ldopts+=("\${linkarg}")
11748 ldopts+=("-out:\$1")
11757 if [ "\$isdll" -ne 0 ]; then
11758 for lib in \${libs[*]}; do
11759 ldopts+=("\$lib.dll.lib")
11762 for lib in \${libs[*]}; do
11763 ldopts+=("\$lib.lib")
11768 ** ld options: "\${ldopts[@]}"
11770 exec \$LD \${ldopts[@]}
11772 chmod +x mk_prog.sh
11773 LINK_PROGS="$SHELL ${rel_builddir}/mk_prog.sh"
11774 LINK_TESTS="$SHELL ${rel_builddir}/mk_prog.sh"
11777 cf_cv_shlib_version=mingw
11778 cf_cv_shlib_version_infix=mingw
11781 if test "$DFT_LWR_MODEL" = "shared" ; then
11782 LOCAL_LDFLAGS="-Wl,--enable-auto-import"
11783 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
11784 EXTRA_LDFLAGS="-Wl,--enable-auto-import $EXTRA_LDFLAGS"
11787 MK_SHARED_LIB=$SHELL' '$rel_builddir'/mk_shared_lib.sh $@ ${CC} ${CFLAGS}'
11788 RM_SHARED_OPTS="$RM_SHARED_OPTS $rel_builddir/mk_shared_lib.sh *.dll.a"
11789 cat >mk_shared_lib.sh <<-CF_EOF
11792 IMPORT_LIB=\`echo "\$1" | sed -e 's/[0-9]*\.dll$/.dll.a/'\`
11795 Linking shared library
11796 ** SHARED_LIB \$SHARED_LIB
11797 ** IMPORT_LIB \$IMPORT_LIB
11799 exec \$* ${LDFLAGS} -shared -Wl,--enable-auto-import,--out-implib=\${IMPORT_LIB} -Wl,--export-all-symbols -o \${SHARED_LIB}
11801 chmod +x mk_shared_lib.sh
11803 (openbsd[2-9].*|mirbsd*)
11804 if test "$DFT_LWR_MODEL" = "shared" && test -n "$LD_RPATH_OPT" ; then
11805 LOCAL_LDFLAGS="${LD_RPATH_OPT}\$(LOCAL_LIBDIR)"
11806 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
11808 if test "$cf_cv_enable_rpath" = yes ; then
11809 EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${RPATH_LIST} $EXTRA_LDFLAGS"
11811 CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC"
11813 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
11814 if test "$cf_cv_shlib_version" = rel; then
11815 cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
11817 cf_cv_shared_soname='`basename $@`'
11820 MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -shared -Wl,-Bshareable,-soname,'$cf_cv_shared_soname',-stats,-lc -o $@'
11824 MK_SHARED_LIB='${LD} -Wshared -Weld=-export_all -o $@'
11828 MK_SHARED_LIB='${LD} -Wshared -Wxld=-export_all -o $@'
11830 (nto-qnx*|openbsd*|freebsd[12].*)
11831 CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC"
11832 MK_SHARED_LIB='${LD} ${LDFLAGS} -Bshareable -o $@'
11833 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
11835 (dragonfly*|freebsd*)
11836 CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC"
11837 if test "$DFT_LWR_MODEL" = "shared" && test "$cf_cv_enable_rpath" = yes ; then
11838 LOCAL_LDFLAGS="${cf_ld_rpath_opt}\$(LOCAL_LIBDIR)"
11839 LOCAL_LDFLAGS2="${cf_ld_rpath_opt}\${RPATH_LIST} $LOCAL_LDFLAGS"
11840 EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${RPATH_LIST} $EXTRA_LDFLAGS"
11843 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
11844 if test "$cf_cv_shlib_version" = rel; then
11845 cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
11847 cf_cv_shared_soname='`basename $@`'
11850 MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -shared -Wl,-soname,'$cf_cv_shared_soname',-stats,-lc -o $@'
11853 CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC"
11854 if test "$DFT_LWR_MODEL" = "shared" && test "$cf_cv_enable_rpath" = yes ; then
11855 LOCAL_LDFLAGS="${cf_ld_rpath_opt}\$(LOCAL_LIBDIR)"
11856 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
11857 EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${RPATH_LIST} $EXTRA_LDFLAGS"
11858 if test "$cf_cv_shlib_version" = auto; then
11859 if test -f /usr/libexec/ld.elf_so; then
11860 cf_cv_shlib_version=abi
11862 cf_cv_shlib_version=rel
11866 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
11867 if test "$cf_cv_shlib_version" = rel; then
11868 cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
11870 cf_cv_shared_soname='`basename $@`'
11873 MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -shared -Wl,-soname,'$cf_cv_shared_soname' -o $@'
11875 MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -shared -o $@'
11879 # tested with OSF/1 V3.2 and 'cc'
11880 # tested with OSF/1 V3.2 and gcc 2.6.3 (but the c++ demo didn't
11881 # link with shared libs).
11882 MK_SHARED_LIB='${LD} ${LDFLAGS} -set_version ${REL_VERSION}:${ABI_VERSION} -expect_unresolved "*" -shared -soname `basename $@`'
11885 MK_SHARED_LIB="${MK_SHARED_LIB} -msym"
11888 MK_SHARED_LIB="${MK_SHARED_LIB}"' -o $@'
11889 if test "$DFT_LWR_MODEL" = "shared" && test -n "$LD_RPATH_OPT" ; then
11890 LOCAL_LDFLAGS="${LD_RPATH_OPT}\$(LOCAL_LIBDIR)"
11891 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
11893 cf_cv_rm_so_locs=yes
11895 (sco3.2v5*) # also uw2* and UW7: hops 13-Apr-98
11896 # tested with osr5.0.5
11897 if test "$GCC" != yes; then
11898 CC_SHARED_OPTS='-belf -KPIC'
11900 MK_SHARED_LIB='${LD} ${LDFLAGS} -dy -G -h `basename $@ .${REL_VERSION}`.${ABI_VERSION} -o $@'
11901 if test "$cf_cv_enable_rpath" = yes ; then
11902 # only way is to set LD_RUN_PATH but no switch for it
11905 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
11906 LINK_PROGS='LD_RUN_PATH=${libdir}'
11907 LINK_TESTS='Pwd=`pwd`;LD_RUN_PATH=`dirname $${Pwd}`/lib'
11910 # tested with SunOS 4.1.1 and gcc 2.7.0
11911 if test "$GCC" != yes; then
11912 CC_SHARED_OPTS='-KPIC'
11914 MK_SHARED_LIB='${LD} ${LDFLAGS} -assert pure-text -o $@'
11915 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
11918 # tested with SunOS 5.5.1 (solaris 2.5.1) and gcc 2.7.2
11919 # tested with SunOS 5.10 (solaris 10) and gcc 3.4.3
11920 if test "$DFT_LWR_MODEL" = "shared" ; then
11921 LOCAL_LDFLAGS="-R \$(LOCAL_LIBDIR):\${libdir}"
11922 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
11924 if test "$cf_cv_enable_rpath" = yes ; then
11925 EXTRA_LDFLAGS="-R \${libdir} $EXTRA_LDFLAGS"
11928 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
11929 if test "$cf_cv_shlib_version" = rel; then
11930 cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
11932 cf_cv_shared_soname='`basename $@`'
11935 if test "$GCC" != yes; then
11936 cf_save_CFLAGS="$CFLAGS"
11937 for cf_shared_opts in -xcode=pic32 -xcode=pic13 -KPIC -Kpic -O
11939 CFLAGS="$cf_shared_opts $cf_save_CFLAGS"
11940 cat >"conftest.$ac_ext" <<_ACEOF
11941 #line 11941 "configure"
11942 #include "confdefs.h"
11947 printf("Hello\\n");
11952 rm -f "conftest.$ac_objext"
11953 if { (eval echo "$as_me:11953: \"$ac_compile\"") >&5
11954 (eval $ac_compile) 2>&5
11956 echo "$as_me:11956: \$? = $ac_status" >&5
11957 (exit "$ac_status"); } &&
11958 { ac_try='test -s "conftest.$ac_objext"'
11959 { (eval echo "$as_me:11959: \"$ac_try\"") >&5
11960 (eval $ac_try) 2>&5
11962 echo "$as_me:11962: \$? = $ac_status" >&5
11963 (exit "$ac_status"); }; }; then
11966 echo "$as_me: failed program was:" >&5
11967 cat "conftest.$ac_ext" >&5
11969 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
11971 CFLAGS="$cf_save_CFLAGS"
11972 CC_SHARED_OPTS=$cf_shared_opts
11973 MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -dy -G -h '$cf_cv_shared_soname' -o $@'
11975 MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -shared -dy -G -h '$cf_cv_shared_soname' -o $@'
11978 (sysv5uw7*|unix_sv*)
11979 # tested with UnixWare 7.1.0 (gcc 2.95.2 and cc)
11980 if test "$GCC" != yes; then
11981 CC_SHARED_OPTS='-KPIC'
11983 MK_SHARED_LIB='${LD} ${LDFLAGS} -d y -G -o $@'
11986 CC_SHARED_OPTS='unknown'
11987 MK_SHARED_LIB='echo unknown'
11991 # This works if the last tokens in $MK_SHARED_LIB are the -o target.
11992 case "$cf_cv_shlib_version" in
11994 case "$MK_SHARED_LIB" in
11996 test "$cf_cv_do_symlinks" = no && cf_cv_do_symlinks=yes
11999 { echo "$as_me:11999: WARNING: ignored --with-shlib-version" >&5
12000 echo "$as_me: WARNING: ignored --with-shlib-version" >&2;}
12006 if test -n "$cf_try_cflags"
12008 cat > conftest.$ac_ext <<EOF
12009 #line 12009 "${as_me:-configure}"
12011 int main(int argc, char *argv[])
12013 printf("hello\\n");
12014 return (argv[argc-1] == 0) ;
12017 cf_save_CFLAGS="$CFLAGS"
12018 for cf_opt in $cf_try_cflags
12020 CFLAGS="$cf_save_CFLAGS -$cf_opt"
12021 echo "$as_me:12021: checking if CFLAGS option -$cf_opt works" >&5
12022 echo $ECHO_N "checking if CFLAGS option -$cf_opt works... $ECHO_C" >&6
12023 if { (eval echo "$as_me:12023: \"$ac_compile\"") >&5
12024 (eval $ac_compile) 2>&5
12026 echo "$as_me:12026: \$? = $ac_status" >&5
12027 (exit "$ac_status"); }; then
12028 echo "$as_me:12028: result: yes" >&5
12029 echo "${ECHO_T}yes" >&6
12030 cf_save_CFLAGS="$CFLAGS"
12032 echo "$as_me:12032: result: no" >&5
12033 echo "${ECHO_T}no" >&6
12036 CFLAGS="$cf_save_CFLAGS"
12039 # RPATH_LIST is a colon-separated list of directories
12040 test -n "$cf_ld_rpath_opt" && MK_SHARED_LIB="$MK_SHARED_LIB $cf_ld_rpath_opt\${RPATH_LIST}"
12041 test -z "$RPATH_LIST" && RPATH_LIST="\${libdir}"
12043 test "$cf_cv_rm_so_locs" = yes && RM_SHARED_OPTS="$RM_SHARED_OPTS so_locations"
12045 test -n "$verbose" && echo " CC_SHARED_OPTS: $CC_SHARED_OPTS" 1>&6
12047 echo "${as_me:-configure}:12047: testing CC_SHARED_OPTS: $CC_SHARED_OPTS ..." 1>&5
12049 test -n "$verbose" && echo " MK_SHARED_LIB: $MK_SHARED_LIB" 1>&6
12051 echo "${as_me:-configure}:12051: testing MK_SHARED_LIB: $MK_SHARED_LIB ..." 1>&5
12053 # The test/sample programs in the original tree link using rpath option.
12054 # Make it optional for packagers.
12055 if test -n "$LOCAL_LDFLAGS"
12057 echo "$as_me:12057: checking if you want to link sample programs with rpath option" >&5
12058 echo $ECHO_N "checking if you want to link sample programs with rpath option... $ECHO_C" >&6
12060 # Check whether --enable-rpath-link or --disable-rpath-link was given.
12061 if test "${enable_rpath_link+set}" = set; then
12062 enableval="$enable_rpath_link"
12063 with_rpath_link=$enableval
12065 with_rpath_link=yes
12067 echo "$as_me:12067: result: $with_rpath_link" >&5
12068 echo "${ECHO_T}$with_rpath_link" >&6
12069 if test "$with_rpath_link" = no
12076 ###############################################################################
12078 ### use option --enable-broken-linker to force on use of broken-linker support
12080 echo "$as_me:12080: checking if you want broken-linker support code" >&5
12081 echo $ECHO_N "checking if you want broken-linker support code... $ECHO_C" >&6
12083 # Check whether --enable-broken_linker or --disable-broken_linker was given.
12084 if test "${enable_broken_linker+set}" = set; then
12085 enableval="$enable_broken_linker"
12086 with_broken_linker=$enableval
12088 with_broken_linker=no
12090 echo "$as_me:12090: result: $with_broken_linker" >&5
12091 echo "${ECHO_T}$with_broken_linker" >&6
12093 : "${BROKEN_LINKER:=0}"
12094 if test "x$with_broken_linker" = xyes ; then
12096 cat >>confdefs.h <<\EOF
12097 #define BROKEN_LINKER 1
12103 # Check to define _XOPEN_SOURCE "automatically"
12105 echo "$as_me:12105: checking if the POSIX test-macros are already defined" >&5
12106 echo $ECHO_N "checking if the POSIX test-macros are already defined... $ECHO_C" >&6
12107 if test "${cf_cv_posix_visible+set}" = set; then
12108 echo $ECHO_N "(cached) $ECHO_C" >&6
12111 cat >"conftest.$ac_ext" <<_ACEOF
12112 #line 12112 "configure"
12113 #include "confdefs.h"
12119 #if defined(__POSIX_VISIBLE) && ((__POSIX_VISIBLE - 0L) > 0) \
12120 && defined(__XSI_VISIBLE) && ((__XSI_VISIBLE - 0L) > 0) \
12121 && defined(__BSD_VISIBLE) && ((__BSD_VISIBLE - 0L) > 0) \
12122 && defined(__ISO_C_VISIBLE) && ((__ISO_C_VISIBLE - 0L) > 0)
12123 #error conflicting symbols found
12130 rm -f "conftest.$ac_objext"
12131 if { (eval echo "$as_me:12131: \"$ac_compile\"") >&5
12132 (eval $ac_compile) 2>&5
12134 echo "$as_me:12134: \$? = $ac_status" >&5
12135 (exit "$ac_status"); } &&
12136 { ac_try='test -s "conftest.$ac_objext"'
12137 { (eval echo "$as_me:12137: \"$ac_try\"") >&5
12138 (eval $ac_try) 2>&5
12140 echo "$as_me:12140: \$? = $ac_status" >&5
12141 (exit "$ac_status"); }; }; then
12142 cf_cv_posix_visible=no
12144 echo "$as_me: failed program was:" >&5
12145 cat "conftest.$ac_ext" >&5
12146 cf_cv_posix_visible=yes
12148 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
12151 echo "$as_me:12151: result: $cf_cv_posix_visible" >&5
12152 echo "${ECHO_T}$cf_cv_posix_visible" >&6
12154 if test "$cf_cv_posix_visible" = no; then
12156 cf_XOPEN_SOURCE=600
12157 cf_POSIX_C_SOURCE=199506L
12162 cf_xopen_source="-D_ALL_SOURCE"
12165 cf_XOPEN_SOURCE=600
12168 cf_xopen_source="-D_APPLE_C_SOURCE"
12171 cf_xopen_source="-D_DARWIN_C_SOURCE"
12174 (freebsd*|dragonfly*|midnightbsd*)
12175 # 5.x headers associate
12176 # _XOPEN_SOURCE=600 with _POSIX_C_SOURCE=200112L
12177 # _XOPEN_SOURCE=500 with _POSIX_C_SOURCE=199506L
12178 cf_POSIX_C_SOURCE=200112L
12179 cf_XOPEN_SOURCE=600
12180 cf_xopen_source="-D_BSD_TYPES -D__BSD_VISIBLE -D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
12183 cf_xopen_source="-D_HPUX_SOURCE -D_XOPEN_SOURCE=500"
12186 cf_xopen_source="-D_HPUX_SOURCE"
12189 cf_xopen_source="-D_SGI_SOURCE"
12192 (linux*|uclinux*|gnu*|mint*|k*bsd*-gnu|cygwin)
12194 cf_gnu_xopen_source=$cf_XOPEN_SOURCE
12196 echo "$as_me:12196: checking if this is the GNU C library" >&5
12197 echo $ECHO_N "checking if this is the GNU C library... $ECHO_C" >&6
12198 if test "${cf_cv_gnu_library+set}" = set; then
12199 echo $ECHO_N "(cached) $ECHO_C" >&6
12202 cat >"conftest.$ac_ext" <<_ACEOF
12203 #line 12203 "configure"
12204 #include "confdefs.h"
12205 #include <sys/types.h>
12210 #if __GLIBC__ > 0 && __GLIBC_MINOR__ >= 0
12212 #elif __NEWLIB__ > 0 && __NEWLIB_MINOR__ >= 0
12215 # error not GNU C library
12221 rm -f "conftest.$ac_objext"
12222 if { (eval echo "$as_me:12222: \"$ac_compile\"") >&5
12223 (eval $ac_compile) 2>&5
12225 echo "$as_me:12225: \$? = $ac_status" >&5
12226 (exit "$ac_status"); } &&
12227 { ac_try='test -s "conftest.$ac_objext"'
12228 { (eval echo "$as_me:12228: \"$ac_try\"") >&5
12229 (eval $ac_try) 2>&5
12231 echo "$as_me:12231: \$? = $ac_status" >&5
12232 (exit "$ac_status"); }; }; then
12233 cf_cv_gnu_library=yes
12235 echo "$as_me: failed program was:" >&5
12236 cat "conftest.$ac_ext" >&5
12237 cf_cv_gnu_library=no
12239 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
12242 echo "$as_me:12242: result: $cf_cv_gnu_library" >&5
12243 echo "${ECHO_T}$cf_cv_gnu_library" >&6
12245 if test x$cf_cv_gnu_library = xyes; then
12247 # With glibc 2.19 (13 years after this check was begun), _DEFAULT_SOURCE
12248 # was changed to help a little. newlib incorporated the change about 4
12250 echo "$as_me:12250: checking if _DEFAULT_SOURCE can be used as a basis" >&5
12251 echo $ECHO_N "checking if _DEFAULT_SOURCE can be used as a basis... $ECHO_C" >&6
12252 if test "${cf_cv_gnu_library_219+set}" = set; then
12253 echo $ECHO_N "(cached) $ECHO_C" >&6
12256 cf_save="$CPPFLAGS"
12258 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
12259 CPPFLAGS="${CPPFLAGS}-D_DEFAULT_SOURCE"
12261 cat >"conftest.$ac_ext" <<_ACEOF
12262 #line 12262 "configure"
12263 #include "confdefs.h"
12264 #include <sys/types.h>
12269 #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 19) || (__GLIBC__ > 2)
12271 #elif (__NEWLIB__ == 2 && __NEWLIB_MINOR__ >= 4) || (__GLIBC__ > 3)
12274 # error GNU C library __GLIBC__.__GLIBC_MINOR__ is too old
12280 rm -f "conftest.$ac_objext"
12281 if { (eval echo "$as_me:12281: \"$ac_compile\"") >&5
12282 (eval $ac_compile) 2>&5
12284 echo "$as_me:12284: \$? = $ac_status" >&5
12285 (exit "$ac_status"); } &&
12286 { ac_try='test -s "conftest.$ac_objext"'
12287 { (eval echo "$as_me:12287: \"$ac_try\"") >&5
12288 (eval $ac_try) 2>&5
12290 echo "$as_me:12290: \$? = $ac_status" >&5
12291 (exit "$ac_status"); }; }; then
12292 cf_cv_gnu_library_219=yes
12294 echo "$as_me: failed program was:" >&5
12295 cat "conftest.$ac_ext" >&5
12296 cf_cv_gnu_library_219=no
12298 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
12299 CPPFLAGS="$cf_save"
12302 echo "$as_me:12302: result: $cf_cv_gnu_library_219" >&5
12303 echo "${ECHO_T}$cf_cv_gnu_library_219" >&6
12305 if test "x$cf_cv_gnu_library_219" = xyes; then
12306 cf_save="$CPPFLAGS"
12307 echo "$as_me:12307: checking if _XOPEN_SOURCE=$cf_gnu_xopen_source works with _DEFAULT_SOURCE" >&5
12308 echo $ECHO_N "checking if _XOPEN_SOURCE=$cf_gnu_xopen_source works with _DEFAULT_SOURCE... $ECHO_C" >&6
12309 if test "${cf_cv_gnu_dftsrc_219+set}" = set; then
12310 echo $ECHO_N "(cached) $ECHO_C" >&6
12316 cf_new_extra_cppflags=
12318 for cf_add_cflags in -D_DEFAULT_SOURCE -D_XOPEN_SOURCE=$cf_gnu_xopen_source
12320 case "$cf_fix_cppflags" in
12322 case "$cf_add_cflags" in
12323 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
12324 case "$cf_add_cflags" in
12326 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
12328 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12329 && test -z "${cf_tst_cflags}" \
12330 && cf_fix_cppflags=yes
12332 if test "$cf_fix_cppflags" = yes ; then
12334 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12335 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12338 elif test "${cf_tst_cflags}" = "\"'" ; then
12340 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12341 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12347 case "$CPPFLAGS" in
12351 case "$cf_add_cflags" in
12353 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12355 CPPFLAGS=`echo "$CPPFLAGS" | \
12356 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12357 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12362 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
12363 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
12370 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
12371 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
12378 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12379 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12381 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
12383 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12384 && test -z "${cf_tst_cflags}" \
12385 && cf_fix_cppflags=no
12390 if test -n "$cf_new_cflags" ; then
12392 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
12393 CFLAGS="${CFLAGS}$cf_new_cflags"
12397 if test -n "$cf_new_cppflags" ; then
12399 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
12400 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
12404 if test -n "$cf_new_extra_cppflags" ; then
12406 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
12407 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
12411 cat >"conftest.$ac_ext" <<_ACEOF
12412 #line 12412 "configure"
12413 #include "confdefs.h"
12415 #include <limits.h>
12416 #include <sys/types.h>
12422 #if (_XOPEN_SOURCE >= $cf_gnu_xopen_source) && (MB_LEN_MAX > 1)
12425 # error GNU C library is too old
12431 rm -f "conftest.$ac_objext"
12432 if { (eval echo "$as_me:12432: \"$ac_compile\"") >&5
12433 (eval $ac_compile) 2>&5
12435 echo "$as_me:12435: \$? = $ac_status" >&5
12436 (exit "$ac_status"); } &&
12437 { ac_try='test -s "conftest.$ac_objext"'
12438 { (eval echo "$as_me:12438: \"$ac_try\"") >&5
12439 (eval $ac_try) 2>&5
12441 echo "$as_me:12441: \$? = $ac_status" >&5
12442 (exit "$ac_status"); }; }; then
12443 cf_cv_gnu_dftsrc_219=yes
12445 echo "$as_me: failed program was:" >&5
12446 cat "conftest.$ac_ext" >&5
12447 cf_cv_gnu_dftsrc_219=no
12449 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
12452 echo "$as_me:12452: result: $cf_cv_gnu_dftsrc_219" >&5
12453 echo "${ECHO_T}$cf_cv_gnu_dftsrc_219" >&6
12454 test "x$cf_cv_gnu_dftsrc_219" = "xyes" || CPPFLAGS="$cf_save"
12456 cf_cv_gnu_dftsrc_219=maybe
12459 if test "x$cf_cv_gnu_dftsrc_219" != xyes; then
12461 echo "$as_me:12461: checking if we must define _GNU_SOURCE" >&5
12462 echo $ECHO_N "checking if we must define _GNU_SOURCE... $ECHO_C" >&6
12463 if test "${cf_cv_gnu_source+set}" = set; then
12464 echo $ECHO_N "(cached) $ECHO_C" >&6
12467 cat >"conftest.$ac_ext" <<_ACEOF
12468 #line 12468 "configure"
12469 #include "confdefs.h"
12470 #include <sys/types.h>
12475 #ifndef _XOPEN_SOURCE
12476 #error expected _XOPEN_SOURCE to be defined
12482 rm -f "conftest.$ac_objext"
12483 if { (eval echo "$as_me:12483: \"$ac_compile\"") >&5
12484 (eval $ac_compile) 2>&5
12486 echo "$as_me:12486: \$? = $ac_status" >&5
12487 (exit "$ac_status"); } &&
12488 { ac_try='test -s "conftest.$ac_objext"'
12489 { (eval echo "$as_me:12489: \"$ac_try\"") >&5
12490 (eval $ac_try) 2>&5
12492 echo "$as_me:12492: \$? = $ac_status" >&5
12493 (exit "$ac_status"); }; }; then
12494 cf_cv_gnu_source=no
12496 echo "$as_me: failed program was:" >&5
12497 cat "conftest.$ac_ext" >&5
12498 cf_save="$CPPFLAGS"
12503 cf_new_extra_cppflags=
12505 for cf_add_cflags in -D_GNU_SOURCE
12507 case "$cf_fix_cppflags" in
12509 case "$cf_add_cflags" in
12510 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
12511 case "$cf_add_cflags" in
12513 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
12515 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12516 && test -z "${cf_tst_cflags}" \
12517 && cf_fix_cppflags=yes
12519 if test "$cf_fix_cppflags" = yes ; then
12521 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12522 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12525 elif test "${cf_tst_cflags}" = "\"'" ; then
12527 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12528 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12534 case "$CPPFLAGS" in
12538 case "$cf_add_cflags" in
12540 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12542 CPPFLAGS=`echo "$CPPFLAGS" | \
12543 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12544 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12549 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
12550 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
12557 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
12558 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
12565 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12566 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12568 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
12570 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12571 && test -z "${cf_tst_cflags}" \
12572 && cf_fix_cppflags=no
12577 if test -n "$cf_new_cflags" ; then
12579 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
12580 CFLAGS="${CFLAGS}$cf_new_cflags"
12584 if test -n "$cf_new_cppflags" ; then
12586 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
12587 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
12591 if test -n "$cf_new_extra_cppflags" ; then
12593 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
12594 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
12598 cat >"conftest.$ac_ext" <<_ACEOF
12599 #line 12599 "configure"
12600 #include "confdefs.h"
12601 #include <sys/types.h>
12606 #ifdef _XOPEN_SOURCE
12607 #error expected _XOPEN_SOURCE to be undefined
12613 rm -f "conftest.$ac_objext"
12614 if { (eval echo "$as_me:12614: \"$ac_compile\"") >&5
12615 (eval $ac_compile) 2>&5
12617 echo "$as_me:12617: \$? = $ac_status" >&5
12618 (exit "$ac_status"); } &&
12619 { ac_try='test -s "conftest.$ac_objext"'
12620 { (eval echo "$as_me:12620: \"$ac_try\"") >&5
12621 (eval $ac_try) 2>&5
12623 echo "$as_me:12623: \$? = $ac_status" >&5
12624 (exit "$ac_status"); }; }; then
12625 cf_cv_gnu_source=no
12627 echo "$as_me: failed program was:" >&5
12628 cat "conftest.$ac_ext" >&5
12629 cf_cv_gnu_source=yes
12631 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
12632 CPPFLAGS="$cf_save"
12635 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
12638 echo "$as_me:12638: result: $cf_cv_gnu_source" >&5
12639 echo "${ECHO_T}$cf_cv_gnu_source" >&6
12641 if test "$cf_cv_gnu_source" = yes
12643 echo "$as_me:12643: checking if we should also define _DEFAULT_SOURCE" >&5
12644 echo $ECHO_N "checking if we should also define _DEFAULT_SOURCE... $ECHO_C" >&6
12645 if test "${cf_cv_default_source+set}" = set; then
12646 echo $ECHO_N "(cached) $ECHO_C" >&6
12649 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
12650 CPPFLAGS="${CPPFLAGS}-D_GNU_SOURCE"
12652 cat >"conftest.$ac_ext" <<_ACEOF
12653 #line 12653 "configure"
12654 #include "confdefs.h"
12655 #include <sys/types.h>
12660 #ifdef _DEFAULT_SOURCE
12661 #error expected _DEFAULT_SOURCE to be undefined
12667 rm -f "conftest.$ac_objext"
12668 if { (eval echo "$as_me:12668: \"$ac_compile\"") >&5
12669 (eval $ac_compile) 2>&5
12671 echo "$as_me:12671: \$? = $ac_status" >&5
12672 (exit "$ac_status"); } &&
12673 { ac_try='test -s "conftest.$ac_objext"'
12674 { (eval echo "$as_me:12674: \"$ac_try\"") >&5
12675 (eval $ac_try) 2>&5
12677 echo "$as_me:12677: \$? = $ac_status" >&5
12678 (exit "$ac_status"); }; }; then
12679 cf_cv_default_source=no
12681 echo "$as_me: failed program was:" >&5
12682 cat "conftest.$ac_ext" >&5
12683 cf_cv_default_source=yes
12685 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
12688 echo "$as_me:12688: result: $cf_cv_default_source" >&5
12689 echo "${ECHO_T}$cf_cv_default_source" >&6
12690 if test "$cf_cv_default_source" = yes
12693 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
12694 CPPFLAGS="${CPPFLAGS}-D_DEFAULT_SOURCE"
12704 cf_xopen_source="-D_NETBSD_SOURCE" # POSIX.1-2001 features are ifdef'd with this...
12707 # setting _XOPEN_SOURCE or _POSIX_SOURCE breaks <sys/select.h> and other headers which use u_int / u_short types
12710 if test "$cf_cv_posix_visible" = no; then
12712 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
12714 cf_save_CFLAGS="$CFLAGS"
12715 cf_save_CPPFLAGS="$CPPFLAGS"
12717 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
12718 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
12719 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
12721 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
12722 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
12723 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
12725 echo "$as_me:12725: checking if we should define _POSIX_C_SOURCE" >&5
12726 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
12727 if test "${cf_cv_posix_c_source+set}" = set; then
12728 echo $ECHO_N "(cached) $ECHO_C" >&6
12731 echo "${as_me:-configure}:12731: testing if the symbol is already defined go no further ..." 1>&5
12733 cat >"conftest.$ac_ext" <<_ACEOF
12734 #line 12734 "configure"
12735 #include "confdefs.h"
12736 #include <sys/types.h>
12741 #ifndef _POSIX_C_SOURCE
12748 rm -f "conftest.$ac_objext"
12749 if { (eval echo "$as_me:12749: \"$ac_compile\"") >&5
12750 (eval $ac_compile) 2>&5
12752 echo "$as_me:12752: \$? = $ac_status" >&5
12753 (exit "$ac_status"); } &&
12754 { ac_try='test -s "conftest.$ac_objext"'
12755 { (eval echo "$as_me:12755: \"$ac_try\"") >&5
12756 (eval $ac_try) 2>&5
12758 echo "$as_me:12758: \$? = $ac_status" >&5
12759 (exit "$ac_status"); }; }; then
12760 cf_cv_posix_c_source=no
12762 echo "$as_me: failed program was:" >&5
12763 cat "conftest.$ac_ext" >&5
12764 cf_want_posix_source=no
12765 case .$cf_POSIX_C_SOURCE in
12767 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
12770 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
12771 cf_want_posix_source=yes
12774 cf_want_posix_source=yes
12777 if test "$cf_want_posix_source" = yes ; then
12778 cat >"conftest.$ac_ext" <<_ACEOF
12779 #line 12779 "configure"
12780 #include "confdefs.h"
12781 #include <sys/types.h>
12786 #ifdef _POSIX_SOURCE
12793 rm -f "conftest.$ac_objext"
12794 if { (eval echo "$as_me:12794: \"$ac_compile\"") >&5
12795 (eval $ac_compile) 2>&5
12797 echo "$as_me:12797: \$? = $ac_status" >&5
12798 (exit "$ac_status"); } &&
12799 { ac_try='test -s "conftest.$ac_objext"'
12800 { (eval echo "$as_me:12800: \"$ac_try\"") >&5
12801 (eval $ac_try) 2>&5
12803 echo "$as_me:12803: \$? = $ac_status" >&5
12804 (exit "$ac_status"); }; }; then
12807 echo "$as_me: failed program was:" >&5
12808 cat "conftest.$ac_ext" >&5
12809 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
12811 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
12814 echo "${as_me:-configure}:12814: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
12816 CFLAGS="$cf_trim_CFLAGS"
12817 CPPFLAGS="$cf_trim_CPPFLAGS"
12819 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
12820 CPPFLAGS="${CPPFLAGS}$cf_cv_posix_c_source"
12822 echo "${as_me:-configure}:12822: testing if the second compile does not leave our definition intact error ..." 1>&5
12824 cat >"conftest.$ac_ext" <<_ACEOF
12825 #line 12825 "configure"
12826 #include "confdefs.h"
12827 #include <sys/types.h>
12832 #ifndef _POSIX_C_SOURCE
12839 rm -f "conftest.$ac_objext"
12840 if { (eval echo "$as_me:12840: \"$ac_compile\"") >&5
12841 (eval $ac_compile) 2>&5
12843 echo "$as_me:12843: \$? = $ac_status" >&5
12844 (exit "$ac_status"); } &&
12845 { ac_try='test -s "conftest.$ac_objext"'
12846 { (eval echo "$as_me:12846: \"$ac_try\"") >&5
12847 (eval $ac_try) 2>&5
12849 echo "$as_me:12849: \$? = $ac_status" >&5
12850 (exit "$ac_status"); }; }; then
12853 echo "$as_me: failed program was:" >&5
12854 cat "conftest.$ac_ext" >&5
12855 cf_cv_posix_c_source=no
12857 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
12858 CFLAGS="$cf_save_CFLAGS"
12859 CPPFLAGS="$cf_save_CPPFLAGS"
12862 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
12865 echo "$as_me:12865: result: $cf_cv_posix_c_source" >&5
12866 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
12868 if test "$cf_cv_posix_c_source" != no ; then
12869 CFLAGS="$cf_trim_CFLAGS"
12870 CPPFLAGS="$cf_trim_CPPFLAGS"
12875 cf_new_extra_cppflags=
12877 for cf_add_cflags in $cf_cv_posix_c_source
12879 case "$cf_fix_cppflags" in
12881 case "$cf_add_cflags" in
12882 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
12883 case "$cf_add_cflags" in
12885 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
12887 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12888 && test -z "${cf_tst_cflags}" \
12889 && cf_fix_cppflags=yes
12891 if test "$cf_fix_cppflags" = yes ; then
12893 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12894 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12897 elif test "${cf_tst_cflags}" = "\"'" ; then
12899 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12900 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12906 case "$CPPFLAGS" in
12910 case "$cf_add_cflags" in
12912 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12914 CPPFLAGS=`echo "$CPPFLAGS" | \
12915 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12916 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12921 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
12922 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
12929 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
12930 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
12937 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12938 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12940 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
12942 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12943 && test -z "${cf_tst_cflags}" \
12944 && cf_fix_cppflags=no
12949 if test -n "$cf_new_cflags" ; then
12951 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
12952 CFLAGS="${CFLAGS}$cf_new_cflags"
12956 if test -n "$cf_new_cppflags" ; then
12958 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
12959 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
12963 if test -n "$cf_new_extra_cppflags" ; then
12965 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
12966 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
12972 fi # cf_cv_posix_visible
12976 cf_xopen_source="-D_NETBSD_SOURCE" # setting _XOPEN_SOURCE breaks IPv6 for lynx on NetBSD 1.6, breaks xterm, is not needed for ncursesw
12979 # OpenBSD 6.x has broken locale support, both compile-time and runtime.
12980 # see https://www.mail-archive.com/bugs@openbsd.org/msg13200.html
12981 # Abusing the conformance level is a workaround.
12982 { echo "$as_me:12982: WARNING: this system does not provide usable locale support" >&5
12983 echo "$as_me: WARNING: this system does not provide usable locale support" >&2;}
12984 cf_xopen_source="-D_BSD_SOURCE"
12985 cf_XOPEN_SOURCE=700
12988 # setting _XOPEN_SOURCE lower than 500 breaks g++ compile with wchar.h, needed for ncursesw
12989 cf_xopen_source="-D_BSD_SOURCE"
12990 cf_XOPEN_SOURCE=600
12993 # setting _XOPEN_SOURCE breaks xterm on OpenBSD 2.8, is not needed for ncursesw
12996 cf_xopen_source="-D_OSF_SOURCE"
12999 cf_xopen_source="-D_QNX_SOURCE"
13002 # setting _XOPEN_SOURCE breaks Lynx on SCO Unix / OpenServer
13005 cf_xopen_source="-D__EXTENSIONS__"
13006 cf_cv_xopen_source=broken
13008 (sysv4.2uw2.*) # Novell/SCO UnixWare 2.x (tested on 2.1.2)
13014 echo "$as_me:13014: checking if we should define _XOPEN_SOURCE" >&5
13015 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
13016 if test "${cf_cv_xopen_source+set}" = set; then
13017 echo $ECHO_N "(cached) $ECHO_C" >&6
13020 cat >"conftest.$ac_ext" <<_ACEOF
13021 #line 13021 "configure"
13022 #include "confdefs.h"
13024 #include <stdlib.h>
13025 #include <string.h>
13026 #include <sys/types.h>
13032 #ifndef _XOPEN_SOURCE
13039 rm -f "conftest.$ac_objext"
13040 if { (eval echo "$as_me:13040: \"$ac_compile\"") >&5
13041 (eval $ac_compile) 2>&5
13043 echo "$as_me:13043: \$? = $ac_status" >&5
13044 (exit "$ac_status"); } &&
13045 { ac_try='test -s "conftest.$ac_objext"'
13046 { (eval echo "$as_me:13046: \"$ac_try\"") >&5
13047 (eval $ac_try) 2>&5
13049 echo "$as_me:13049: \$? = $ac_status" >&5
13050 (exit "$ac_status"); }; }; then
13051 cf_cv_xopen_source=no
13053 echo "$as_me: failed program was:" >&5
13054 cat "conftest.$ac_ext" >&5
13055 cf_save="$CPPFLAGS"
13057 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13058 CPPFLAGS="${CPPFLAGS}-D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
13060 cat >"conftest.$ac_ext" <<_ACEOF
13061 #line 13061 "configure"
13062 #include "confdefs.h"
13064 #include <stdlib.h>
13065 #include <string.h>
13066 #include <sys/types.h>
13072 #ifdef _XOPEN_SOURCE
13079 rm -f "conftest.$ac_objext"
13080 if { (eval echo "$as_me:13080: \"$ac_compile\"") >&5
13081 (eval $ac_compile) 2>&5
13083 echo "$as_me:13083: \$? = $ac_status" >&5
13084 (exit "$ac_status"); } &&
13085 { ac_try='test -s "conftest.$ac_objext"'
13086 { (eval echo "$as_me:13086: \"$ac_try\"") >&5
13087 (eval $ac_try) 2>&5
13089 echo "$as_me:13089: \$? = $ac_status" >&5
13090 (exit "$ac_status"); }; }; then
13091 cf_cv_xopen_source=no
13093 echo "$as_me: failed program was:" >&5
13094 cat "conftest.$ac_ext" >&5
13095 cf_cv_xopen_source=$cf_XOPEN_SOURCE
13097 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
13098 CPPFLAGS="$cf_save"
13101 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
13104 echo "$as_me:13104: result: $cf_cv_xopen_source" >&5
13105 echo "${ECHO_T}$cf_cv_xopen_source" >&6
13107 if test "$cf_cv_xopen_source" != no ; then
13109 CFLAGS=`echo "$CFLAGS" | \
13110 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
13111 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
13113 CPPFLAGS=`echo "$CPPFLAGS" | \
13114 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
13115 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
13117 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
13122 cf_new_extra_cppflags=
13124 for cf_add_cflags in $cf_temp_xopen_source
13126 case "$cf_fix_cppflags" in
13128 case "$cf_add_cflags" in
13129 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
13130 case "$cf_add_cflags" in
13132 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
13134 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13135 && test -z "${cf_tst_cflags}" \
13136 && cf_fix_cppflags=yes
13138 if test "$cf_fix_cppflags" = yes ; then
13140 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13141 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13144 elif test "${cf_tst_cflags}" = "\"'" ; then
13146 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13147 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13153 case "$CPPFLAGS" in
13157 case "$cf_add_cflags" in
13159 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
13161 CPPFLAGS=`echo "$CPPFLAGS" | \
13162 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
13163 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
13168 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
13169 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
13176 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
13177 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
13184 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13185 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13187 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
13189 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13190 && test -z "${cf_tst_cflags}" \
13191 && cf_fix_cppflags=no
13196 if test -n "$cf_new_cflags" ; then
13198 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
13199 CFLAGS="${CFLAGS}$cf_new_cflags"
13203 if test -n "$cf_new_cppflags" ; then
13205 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13206 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
13210 if test -n "$cf_new_extra_cppflags" ; then
13212 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
13213 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
13219 if test "$cf_cv_posix_visible" = no; then
13221 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
13223 cf_save_CFLAGS="$CFLAGS"
13224 cf_save_CPPFLAGS="$CPPFLAGS"
13226 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
13227 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
13228 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
13230 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
13231 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
13232 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
13234 echo "$as_me:13234: checking if we should define _POSIX_C_SOURCE" >&5
13235 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
13236 if test "${cf_cv_posix_c_source+set}" = set; then
13237 echo $ECHO_N "(cached) $ECHO_C" >&6
13240 echo "${as_me:-configure}:13240: testing if the symbol is already defined go no further ..." 1>&5
13242 cat >"conftest.$ac_ext" <<_ACEOF
13243 #line 13243 "configure"
13244 #include "confdefs.h"
13245 #include <sys/types.h>
13250 #ifndef _POSIX_C_SOURCE
13257 rm -f "conftest.$ac_objext"
13258 if { (eval echo "$as_me:13258: \"$ac_compile\"") >&5
13259 (eval $ac_compile) 2>&5
13261 echo "$as_me:13261: \$? = $ac_status" >&5
13262 (exit "$ac_status"); } &&
13263 { ac_try='test -s "conftest.$ac_objext"'
13264 { (eval echo "$as_me:13264: \"$ac_try\"") >&5
13265 (eval $ac_try) 2>&5
13267 echo "$as_me:13267: \$? = $ac_status" >&5
13268 (exit "$ac_status"); }; }; then
13269 cf_cv_posix_c_source=no
13271 echo "$as_me: failed program was:" >&5
13272 cat "conftest.$ac_ext" >&5
13273 cf_want_posix_source=no
13274 case .$cf_POSIX_C_SOURCE in
13276 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
13279 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
13280 cf_want_posix_source=yes
13283 cf_want_posix_source=yes
13286 if test "$cf_want_posix_source" = yes ; then
13287 cat >"conftest.$ac_ext" <<_ACEOF
13288 #line 13288 "configure"
13289 #include "confdefs.h"
13290 #include <sys/types.h>
13295 #ifdef _POSIX_SOURCE
13302 rm -f "conftest.$ac_objext"
13303 if { (eval echo "$as_me:13303: \"$ac_compile\"") >&5
13304 (eval $ac_compile) 2>&5
13306 echo "$as_me:13306: \$? = $ac_status" >&5
13307 (exit "$ac_status"); } &&
13308 { ac_try='test -s "conftest.$ac_objext"'
13309 { (eval echo "$as_me:13309: \"$ac_try\"") >&5
13310 (eval $ac_try) 2>&5
13312 echo "$as_me:13312: \$? = $ac_status" >&5
13313 (exit "$ac_status"); }; }; then
13316 echo "$as_me: failed program was:" >&5
13317 cat "conftest.$ac_ext" >&5
13318 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
13320 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
13323 echo "${as_me:-configure}:13323: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
13325 CFLAGS="$cf_trim_CFLAGS"
13326 CPPFLAGS="$cf_trim_CPPFLAGS"
13328 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13329 CPPFLAGS="${CPPFLAGS}$cf_cv_posix_c_source"
13331 echo "${as_me:-configure}:13331: testing if the second compile does not leave our definition intact error ..." 1>&5
13333 cat >"conftest.$ac_ext" <<_ACEOF
13334 #line 13334 "configure"
13335 #include "confdefs.h"
13336 #include <sys/types.h>
13341 #ifndef _POSIX_C_SOURCE
13348 rm -f "conftest.$ac_objext"
13349 if { (eval echo "$as_me:13349: \"$ac_compile\"") >&5
13350 (eval $ac_compile) 2>&5
13352 echo "$as_me:13352: \$? = $ac_status" >&5
13353 (exit "$ac_status"); } &&
13354 { ac_try='test -s "conftest.$ac_objext"'
13355 { (eval echo "$as_me:13355: \"$ac_try\"") >&5
13356 (eval $ac_try) 2>&5
13358 echo "$as_me:13358: \$? = $ac_status" >&5
13359 (exit "$ac_status"); }; }; then
13362 echo "$as_me: failed program was:" >&5
13363 cat "conftest.$ac_ext" >&5
13364 cf_cv_posix_c_source=no
13366 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
13367 CFLAGS="$cf_save_CFLAGS"
13368 CPPFLAGS="$cf_save_CPPFLAGS"
13371 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
13374 echo "$as_me:13374: result: $cf_cv_posix_c_source" >&5
13375 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
13377 if test "$cf_cv_posix_c_source" != no ; then
13378 CFLAGS="$cf_trim_CFLAGS"
13379 CPPFLAGS="$cf_trim_CPPFLAGS"
13384 cf_new_extra_cppflags=
13386 for cf_add_cflags in $cf_cv_posix_c_source
13388 case "$cf_fix_cppflags" in
13390 case "$cf_add_cflags" in
13391 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
13392 case "$cf_add_cflags" in
13394 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
13396 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13397 && test -z "${cf_tst_cflags}" \
13398 && cf_fix_cppflags=yes
13400 if test "$cf_fix_cppflags" = yes ; then
13402 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13403 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13406 elif test "${cf_tst_cflags}" = "\"'" ; then
13408 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13409 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13415 case "$CPPFLAGS" in
13419 case "$cf_add_cflags" in
13421 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
13423 CPPFLAGS=`echo "$CPPFLAGS" | \
13424 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
13425 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
13430 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
13431 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
13438 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
13439 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
13446 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13447 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13449 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
13451 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13452 && test -z "${cf_tst_cflags}" \
13453 && cf_fix_cppflags=no
13458 if test -n "$cf_new_cflags" ; then
13460 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
13461 CFLAGS="${CFLAGS}$cf_new_cflags"
13465 if test -n "$cf_new_cppflags" ; then
13467 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13468 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
13472 if test -n "$cf_new_extra_cppflags" ; then
13474 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
13475 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
13481 fi # cf_cv_posix_visible
13486 if test -n "$cf_xopen_source" ; then
13491 cf_new_extra_cppflags=
13493 for cf_add_cflags in $cf_xopen_source
13495 case "$cf_fix_cppflags" in
13497 case "$cf_add_cflags" in
13498 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
13499 case "$cf_add_cflags" in
13501 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
13503 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13504 && test -z "${cf_tst_cflags}" \
13505 && cf_fix_cppflags=yes
13507 if test "$cf_fix_cppflags" = yes ; then
13509 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13510 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13513 elif test "${cf_tst_cflags}" = "\"'" ; then
13515 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13516 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13522 case "$CPPFLAGS" in
13526 case "$cf_add_cflags" in
13528 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
13530 CPPFLAGS=`echo "$CPPFLAGS" | \
13531 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
13532 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
13537 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
13538 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
13545 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
13546 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
13553 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13554 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13556 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
13558 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13559 && test -z "${cf_tst_cflags}" \
13560 && cf_fix_cppflags=no
13565 if test -n "$cf_new_cflags" ; then
13566 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
13568 echo "${as_me:-configure}:13568: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
13570 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
13571 CFLAGS="${CFLAGS}$cf_new_cflags"
13575 if test -n "$cf_new_cppflags" ; then
13576 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
13578 echo "${as_me:-configure}:13578: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
13580 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13581 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
13585 if test -n "$cf_new_extra_cppflags" ; then
13586 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
13588 echo "${as_me:-configure}:13588: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
13590 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
13591 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
13597 if test -n "$cf_XOPEN_SOURCE" && test -z "$cf_cv_xopen_source" ; then
13598 echo "$as_me:13598: checking if _XOPEN_SOURCE really is set" >&5
13599 echo $ECHO_N "checking if _XOPEN_SOURCE really is set... $ECHO_C" >&6
13600 cat >"conftest.$ac_ext" <<_ACEOF
13601 #line 13601 "configure"
13602 #include "confdefs.h"
13603 #include <stdlib.h>
13608 #ifndef _XOPEN_SOURCE
13615 rm -f "conftest.$ac_objext"
13616 if { (eval echo "$as_me:13616: \"$ac_compile\"") >&5
13617 (eval $ac_compile) 2>&5
13619 echo "$as_me:13619: \$? = $ac_status" >&5
13620 (exit "$ac_status"); } &&
13621 { ac_try='test -s "conftest.$ac_objext"'
13622 { (eval echo "$as_me:13622: \"$ac_try\"") >&5
13623 (eval $ac_try) 2>&5
13625 echo "$as_me:13625: \$? = $ac_status" >&5
13626 (exit "$ac_status"); }; }; then
13627 cf_XOPEN_SOURCE_set=yes
13629 echo "$as_me: failed program was:" >&5
13630 cat "conftest.$ac_ext" >&5
13631 cf_XOPEN_SOURCE_set=no
13633 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
13634 echo "$as_me:13634: result: $cf_XOPEN_SOURCE_set" >&5
13635 echo "${ECHO_T}$cf_XOPEN_SOURCE_set" >&6
13636 if test "$cf_XOPEN_SOURCE_set" = yes
13638 cat >"conftest.$ac_ext" <<_ACEOF
13639 #line 13639 "configure"
13640 #include "confdefs.h"
13641 #include <stdlib.h>
13646 #if (_XOPEN_SOURCE - 0) < $cf_XOPEN_SOURCE
13653 rm -f "conftest.$ac_objext"
13654 if { (eval echo "$as_me:13654: \"$ac_compile\"") >&5
13655 (eval $ac_compile) 2>&5
13657 echo "$as_me:13657: \$? = $ac_status" >&5
13658 (exit "$ac_status"); } &&
13659 { ac_try='test -s "conftest.$ac_objext"'
13660 { (eval echo "$as_me:13660: \"$ac_try\"") >&5
13661 (eval $ac_try) 2>&5
13663 echo "$as_me:13663: \$? = $ac_status" >&5
13664 (exit "$ac_status"); }; }; then
13665 cf_XOPEN_SOURCE_set_ok=yes
13667 echo "$as_me: failed program was:" >&5
13668 cat "conftest.$ac_ext" >&5
13669 cf_XOPEN_SOURCE_set_ok=no
13671 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
13672 if test "$cf_XOPEN_SOURCE_set_ok" = no
13674 { echo "$as_me:13674: WARNING: _XOPEN_SOURCE is lower than requested" >&5
13675 echo "$as_me: WARNING: _XOPEN_SOURCE is lower than requested" >&2;}
13679 echo "$as_me:13679: checking if we should define _XOPEN_SOURCE" >&5
13680 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
13681 if test "${cf_cv_xopen_source+set}" = set; then
13682 echo $ECHO_N "(cached) $ECHO_C" >&6
13685 cat >"conftest.$ac_ext" <<_ACEOF
13686 #line 13686 "configure"
13687 #include "confdefs.h"
13689 #include <stdlib.h>
13690 #include <string.h>
13691 #include <sys/types.h>
13697 #ifndef _XOPEN_SOURCE
13704 rm -f "conftest.$ac_objext"
13705 if { (eval echo "$as_me:13705: \"$ac_compile\"") >&5
13706 (eval $ac_compile) 2>&5
13708 echo "$as_me:13708: \$? = $ac_status" >&5
13709 (exit "$ac_status"); } &&
13710 { ac_try='test -s "conftest.$ac_objext"'
13711 { (eval echo "$as_me:13711: \"$ac_try\"") >&5
13712 (eval $ac_try) 2>&5
13714 echo "$as_me:13714: \$? = $ac_status" >&5
13715 (exit "$ac_status"); }; }; then
13716 cf_cv_xopen_source=no
13718 echo "$as_me: failed program was:" >&5
13719 cat "conftest.$ac_ext" >&5
13720 cf_save="$CPPFLAGS"
13722 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13723 CPPFLAGS="${CPPFLAGS}-D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
13725 cat >"conftest.$ac_ext" <<_ACEOF
13726 #line 13726 "configure"
13727 #include "confdefs.h"
13729 #include <stdlib.h>
13730 #include <string.h>
13731 #include <sys/types.h>
13737 #ifdef _XOPEN_SOURCE
13744 rm -f "conftest.$ac_objext"
13745 if { (eval echo "$as_me:13745: \"$ac_compile\"") >&5
13746 (eval $ac_compile) 2>&5
13748 echo "$as_me:13748: \$? = $ac_status" >&5
13749 (exit "$ac_status"); } &&
13750 { ac_try='test -s "conftest.$ac_objext"'
13751 { (eval echo "$as_me:13751: \"$ac_try\"") >&5
13752 (eval $ac_try) 2>&5
13754 echo "$as_me:13754: \$? = $ac_status" >&5
13755 (exit "$ac_status"); }; }; then
13756 cf_cv_xopen_source=no
13758 echo "$as_me: failed program was:" >&5
13759 cat "conftest.$ac_ext" >&5
13760 cf_cv_xopen_source=$cf_XOPEN_SOURCE
13762 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
13763 CPPFLAGS="$cf_save"
13766 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
13769 echo "$as_me:13769: result: $cf_cv_xopen_source" >&5
13770 echo "${ECHO_T}$cf_cv_xopen_source" >&6
13772 if test "$cf_cv_xopen_source" != no ; then
13774 CFLAGS=`echo "$CFLAGS" | \
13775 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
13776 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
13778 CPPFLAGS=`echo "$CPPFLAGS" | \
13779 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
13780 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
13782 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
13787 cf_new_extra_cppflags=
13789 for cf_add_cflags in $cf_temp_xopen_source
13791 case "$cf_fix_cppflags" in
13793 case "$cf_add_cflags" in
13794 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
13795 case "$cf_add_cflags" in
13797 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
13799 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13800 && test -z "${cf_tst_cflags}" \
13801 && cf_fix_cppflags=yes
13803 if test "$cf_fix_cppflags" = yes ; then
13805 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13806 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13809 elif test "${cf_tst_cflags}" = "\"'" ; then
13811 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13812 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13818 case "$CPPFLAGS" in
13822 case "$cf_add_cflags" in
13824 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
13826 CPPFLAGS=`echo "$CPPFLAGS" | \
13827 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
13828 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
13833 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
13834 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
13841 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
13842 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
13849 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13850 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13852 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
13854 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13855 && test -z "${cf_tst_cflags}" \
13856 && cf_fix_cppflags=no
13861 if test -n "$cf_new_cflags" ; then
13863 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
13864 CFLAGS="${CFLAGS}$cf_new_cflags"
13868 if test -n "$cf_new_cppflags" ; then
13870 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13871 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
13875 if test -n "$cf_new_extra_cppflags" ; then
13877 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
13878 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
13886 fi # cf_cv_posix_visible
13888 # Check whether --enable-largefile or --disable-largefile was given.
13889 if test "${enable_largefile+set}" = set; then
13890 enableval="$enable_largefile"
13893 if test "$enable_largefile" != no; then
13895 echo "$as_me:13895: checking for special C compiler options needed for large files" >&5
13896 echo $ECHO_N "checking for special C compiler options needed for large files... $ECHO_C" >&6
13897 if test "${ac_cv_sys_largefile_CC+set}" = set; then
13898 echo $ECHO_N "(cached) $ECHO_C" >&6
13900 ac_cv_sys_largefile_CC=no
13901 if test "$GCC" != yes; then
13904 # IRIX 6.2 and later do not support large files by default,
13905 # so use the C compiler's -n32 option if that helps.
13906 cat >"conftest.$ac_ext" <<_ACEOF
13907 #line 13907 "configure"
13908 #include "confdefs.h"
13909 #include <sys/types.h>
13910 /* Check that off_t can represent 2**63 - 1 correctly.
13911 We can't simply define LARGE_OFF_T to be 9223372036854775807,
13912 since some C++ compilers masquerading as C compilers
13913 incorrectly reject 9223372036854775807. */
13914 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
13915 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
13916 && LARGE_OFF_T % 2147483647 == 1)
13926 rm -f "conftest.$ac_objext"
13927 if { (eval echo "$as_me:13927: \"$ac_compile\"") >&5
13928 (eval $ac_compile) 2>&5
13930 echo "$as_me:13930: \$? = $ac_status" >&5
13931 (exit "$ac_status"); } &&
13932 { ac_try='test -s "conftest.$ac_objext"'
13933 { (eval echo "$as_me:13933: \"$ac_try\"") >&5
13934 (eval $ac_try) 2>&5
13936 echo "$as_me:13936: \$? = $ac_status" >&5
13937 (exit "$ac_status"); }; }; then
13940 echo "$as_me: failed program was:" >&5
13941 cat "conftest.$ac_ext" >&5
13943 rm -f "conftest.$ac_objext"
13945 rm -f "conftest.$ac_objext"
13946 if { (eval echo "$as_me:13946: \"$ac_compile\"") >&5
13947 (eval $ac_compile) 2>&5
13949 echo "$as_me:13949: \$? = $ac_status" >&5
13950 (exit "$ac_status"); } &&
13951 { ac_try='test -s "conftest.$ac_objext"'
13952 { (eval echo "$as_me:13952: \"$ac_try\"") >&5
13953 (eval $ac_try) 2>&5
13955 echo "$as_me:13955: \$? = $ac_status" >&5
13956 (exit "$ac_status"); }; }; then
13957 ac_cv_sys_largefile_CC=' -n32'; break
13959 echo "$as_me: failed program was:" >&5
13960 cat "conftest.$ac_ext" >&5
13962 rm -f "conftest.$ac_objext"
13966 rm -f "conftest.$ac_ext"
13969 echo "$as_me:13969: result: $ac_cv_sys_largefile_CC" >&5
13970 echo "${ECHO_T}$ac_cv_sys_largefile_CC" >&6
13971 if test "$ac_cv_sys_largefile_CC" != no; then
13972 CC=$CC$ac_cv_sys_largefile_CC
13975 echo "$as_me:13975: checking for _FILE_OFFSET_BITS value needed for large files" >&5
13976 echo $ECHO_N "checking for _FILE_OFFSET_BITS value needed for large files... $ECHO_C" >&6
13977 if test "${ac_cv_sys_file_offset_bits+set}" = set; then
13978 echo $ECHO_N "(cached) $ECHO_C" >&6
13981 ac_cv_sys_file_offset_bits=no
13982 cat >"conftest.$ac_ext" <<_ACEOF
13983 #line 13983 "configure"
13984 #include "confdefs.h"
13985 #include <sys/types.h>
13986 /* Check that off_t can represent 2**63 - 1 correctly.
13987 We can't simply define LARGE_OFF_T to be 9223372036854775807,
13988 since some C++ compilers masquerading as C compilers
13989 incorrectly reject 9223372036854775807. */
13990 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
13991 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
13992 && LARGE_OFF_T % 2147483647 == 1)
14002 rm -f "conftest.$ac_objext"
14003 if { (eval echo "$as_me:14003: \"$ac_compile\"") >&5
14004 (eval $ac_compile) 2>&5
14006 echo "$as_me:14006: \$? = $ac_status" >&5
14007 (exit "$ac_status"); } &&
14008 { ac_try='test -s "conftest.$ac_objext"'
14009 { (eval echo "$as_me:14009: \"$ac_try\"") >&5
14010 (eval $ac_try) 2>&5
14012 echo "$as_me:14012: \$? = $ac_status" >&5
14013 (exit "$ac_status"); }; }; then
14016 echo "$as_me: failed program was:" >&5
14017 cat "conftest.$ac_ext" >&5
14019 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
14020 cat >"conftest.$ac_ext" <<_ACEOF
14021 #line 14021 "configure"
14022 #include "confdefs.h"
14023 #define _FILE_OFFSET_BITS 64
14024 #include <sys/types.h>
14025 /* Check that off_t can represent 2**63 - 1 correctly.
14026 We can't simply define LARGE_OFF_T to be 9223372036854775807,
14027 since some C++ compilers masquerading as C compilers
14028 incorrectly reject 9223372036854775807. */
14029 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
14030 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
14031 && LARGE_OFF_T % 2147483647 == 1)
14041 rm -f "conftest.$ac_objext"
14042 if { (eval echo "$as_me:14042: \"$ac_compile\"") >&5
14043 (eval $ac_compile) 2>&5
14045 echo "$as_me:14045: \$? = $ac_status" >&5
14046 (exit "$ac_status"); } &&
14047 { ac_try='test -s "conftest.$ac_objext"'
14048 { (eval echo "$as_me:14048: \"$ac_try\"") >&5
14049 (eval $ac_try) 2>&5
14051 echo "$as_me:14051: \$? = $ac_status" >&5
14052 (exit "$ac_status"); }; }; then
14053 ac_cv_sys_file_offset_bits=64; break
14055 echo "$as_me: failed program was:" >&5
14056 cat "conftest.$ac_ext" >&5
14058 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
14062 echo "$as_me:14062: result: $ac_cv_sys_file_offset_bits" >&5
14063 echo "${ECHO_T}$ac_cv_sys_file_offset_bits" >&6
14064 if test "$ac_cv_sys_file_offset_bits" != no; then
14066 cat >>confdefs.h <<EOF
14067 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
14072 echo "$as_me:14072: checking for _LARGE_FILES value needed for large files" >&5
14073 echo $ECHO_N "checking for _LARGE_FILES value needed for large files... $ECHO_C" >&6
14074 if test "${ac_cv_sys_large_files+set}" = set; then
14075 echo $ECHO_N "(cached) $ECHO_C" >&6
14078 ac_cv_sys_large_files=no
14079 cat >"conftest.$ac_ext" <<_ACEOF
14080 #line 14080 "configure"
14081 #include "confdefs.h"
14082 #include <sys/types.h>
14083 /* Check that off_t can represent 2**63 - 1 correctly.
14084 We can't simply define LARGE_OFF_T to be 9223372036854775807,
14085 since some C++ compilers masquerading as C compilers
14086 incorrectly reject 9223372036854775807. */
14087 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
14088 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
14089 && LARGE_OFF_T % 2147483647 == 1)
14099 rm -f "conftest.$ac_objext"
14100 if { (eval echo "$as_me:14100: \"$ac_compile\"") >&5
14101 (eval $ac_compile) 2>&5
14103 echo "$as_me:14103: \$? = $ac_status" >&5
14104 (exit "$ac_status"); } &&
14105 { ac_try='test -s "conftest.$ac_objext"'
14106 { (eval echo "$as_me:14106: \"$ac_try\"") >&5
14107 (eval $ac_try) 2>&5
14109 echo "$as_me:14109: \$? = $ac_status" >&5
14110 (exit "$ac_status"); }; }; then
14113 echo "$as_me: failed program was:" >&5
14114 cat "conftest.$ac_ext" >&5
14116 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
14117 cat >"conftest.$ac_ext" <<_ACEOF
14118 #line 14118 "configure"
14119 #include "confdefs.h"
14120 #define _LARGE_FILES 1
14121 #include <sys/types.h>
14122 /* Check that off_t can represent 2**63 - 1 correctly.
14123 We can't simply define LARGE_OFF_T to be 9223372036854775807,
14124 since some C++ compilers masquerading as C compilers
14125 incorrectly reject 9223372036854775807. */
14126 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
14127 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
14128 && LARGE_OFF_T % 2147483647 == 1)
14138 rm -f "conftest.$ac_objext"
14139 if { (eval echo "$as_me:14139: \"$ac_compile\"") >&5
14140 (eval $ac_compile) 2>&5
14142 echo "$as_me:14142: \$? = $ac_status" >&5
14143 (exit "$ac_status"); } &&
14144 { ac_try='test -s "conftest.$ac_objext"'
14145 { (eval echo "$as_me:14145: \"$ac_try\"") >&5
14146 (eval $ac_try) 2>&5
14148 echo "$as_me:14148: \$? = $ac_status" >&5
14149 (exit "$ac_status"); }; }; then
14150 ac_cv_sys_large_files=1; break
14152 echo "$as_me: failed program was:" >&5
14153 cat "conftest.$ac_ext" >&5
14155 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
14159 echo "$as_me:14159: result: $ac_cv_sys_large_files" >&5
14160 echo "${ECHO_T}$ac_cv_sys_large_files" >&6
14161 if test "$ac_cv_sys_large_files" != no; then
14163 cat >>confdefs.h <<EOF
14164 #define _LARGE_FILES $ac_cv_sys_large_files
14171 if test "$enable_largefile" != no ; then
14172 echo "$as_me:14172: checking for _LARGEFILE_SOURCE value needed for large files" >&5
14173 echo $ECHO_N "checking for _LARGEFILE_SOURCE value needed for large files... $ECHO_C" >&6
14174 if test "${ac_cv_sys_largefile_source+set}" = set; then
14175 echo $ECHO_N "(cached) $ECHO_C" >&6
14178 ac_cv_sys_largefile_source=no
14179 cat >"conftest.$ac_ext" <<_ACEOF
14180 #line 14180 "configure"
14181 #include "confdefs.h"
14191 rm -f "conftest.$ac_objext"
14192 if { (eval echo "$as_me:14192: \"$ac_compile\"") >&5
14193 (eval $ac_compile) 2>&5
14195 echo "$as_me:14195: \$? = $ac_status" >&5
14196 (exit "$ac_status"); } &&
14197 { ac_try='test -s "conftest.$ac_objext"'
14198 { (eval echo "$as_me:14198: \"$ac_try\"") >&5
14199 (eval $ac_try) 2>&5
14201 echo "$as_me:14201: \$? = $ac_status" >&5
14202 (exit "$ac_status"); }; }; then
14205 echo "$as_me: failed program was:" >&5
14206 cat "conftest.$ac_ext" >&5
14208 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
14209 cat >"conftest.$ac_ext" <<_ACEOF
14210 #line 14210 "configure"
14211 #include "confdefs.h"
14212 #define _LARGEFILE_SOURCE 1
14222 rm -f "conftest.$ac_objext"
14223 if { (eval echo "$as_me:14223: \"$ac_compile\"") >&5
14224 (eval $ac_compile) 2>&5
14226 echo "$as_me:14226: \$? = $ac_status" >&5
14227 (exit "$ac_status"); } &&
14228 { ac_try='test -s "conftest.$ac_objext"'
14229 { (eval echo "$as_me:14229: \"$ac_try\"") >&5
14230 (eval $ac_try) 2>&5
14232 echo "$as_me:14232: \$? = $ac_status" >&5
14233 (exit "$ac_status"); }; }; then
14234 ac_cv_sys_largefile_source=1; break
14236 echo "$as_me: failed program was:" >&5
14237 cat "conftest.$ac_ext" >&5
14239 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
14243 echo "$as_me:14243: result: $ac_cv_sys_largefile_source" >&5
14244 echo "${ECHO_T}$ac_cv_sys_largefile_source" >&6
14245 if test "$ac_cv_sys_largefile_source" != no; then
14247 cat >>confdefs.h <<EOF
14248 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
14254 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
14255 # in glibc 2.1.3, but that breaks too many other things.
14256 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
14257 echo "$as_me:14257: checking for fseeko" >&5
14258 echo $ECHO_N "checking for fseeko... $ECHO_C" >&6
14259 if test "${ac_cv_func_fseeko+set}" = set; then
14260 echo $ECHO_N "(cached) $ECHO_C" >&6
14262 cat >"conftest.$ac_ext" <<_ACEOF
14263 #line 14263 "configure"
14264 #include "confdefs.h"
14269 return fseeko && fseeko (stdin, 0, 0);
14274 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
14275 if { (eval echo "$as_me:14275: \"$ac_link\"") >&5
14276 (eval $ac_link) 2>&5
14278 echo "$as_me:14278: \$? = $ac_status" >&5
14279 (exit "$ac_status"); } &&
14280 { ac_try='test -s "conftest$ac_exeext"'
14281 { (eval echo "$as_me:14281: \"$ac_try\"") >&5
14282 (eval $ac_try) 2>&5
14284 echo "$as_me:14284: \$? = $ac_status" >&5
14285 (exit "$ac_status"); }; }; then
14286 ac_cv_func_fseeko=yes
14288 echo "$as_me: failed program was:" >&5
14289 cat "conftest.$ac_ext" >&5
14290 ac_cv_func_fseeko=no
14292 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
14294 echo "$as_me:14294: result: $ac_cv_func_fseeko" >&5
14295 echo "${ECHO_T}$ac_cv_func_fseeko" >&6
14296 if test $ac_cv_func_fseeko = yes; then
14298 cat >>confdefs.h <<\EOF
14299 #define HAVE_FSEEKO 1
14304 # Normally we would collect these definitions in the config.h,
14305 # but (like _XOPEN_SOURCE), some environments rely on having these
14306 # defined before any of the system headers are included. Another
14307 # case comes up with C++, e.g., on AIX the compiler compiles the
14308 # header files by themselves before looking at the body files it is
14309 # told to compile. For ncurses, those header files do not include
14311 if test "$ac_cv_sys_large_files" != no
14314 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
14315 CPPFLAGS="${CPPFLAGS}-D_LARGE_FILES"
14318 if test "$ac_cv_sys_largefile_source" != no
14321 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
14322 CPPFLAGS="${CPPFLAGS}-D_LARGEFILE_SOURCE"
14325 if test "$ac_cv_sys_file_offset_bits" != no
14328 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
14329 CPPFLAGS="${CPPFLAGS}-D_FILE_OFFSET_BITS=$ac_cv_sys_file_offset_bits"
14333 echo "$as_me:14333: checking whether to use struct dirent64" >&5
14334 echo $ECHO_N "checking whether to use struct dirent64... $ECHO_C" >&6
14335 if test "${cf_cv_struct_dirent64+set}" = set; then
14336 echo $ECHO_N "(cached) $ECHO_C" >&6
14339 cat >"conftest.$ac_ext" <<_ACEOF
14340 #line 14340 "configure"
14341 #include "confdefs.h"
14343 #pragma GCC diagnostic error "-Wincompatible-pointer-types"
14344 #include <sys/types.h>
14345 #include <dirent.h>
14351 /* if transitional largefile support is setup, this is true */
14352 extern struct dirent64 * readdir(DIR *);
14353 struct dirent64 *x = readdir((DIR *)0);
14354 struct dirent *y = readdir((DIR *)0);
14362 rm -f "conftest.$ac_objext"
14363 if { (eval echo "$as_me:14363: \"$ac_compile\"") >&5
14364 (eval $ac_compile) 2>&5
14366 echo "$as_me:14366: \$? = $ac_status" >&5
14367 (exit "$ac_status"); } &&
14368 { ac_try='test -s "conftest.$ac_objext"'
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 cf_cv_struct_dirent64=yes
14376 echo "$as_me: failed program was:" >&5
14377 cat "conftest.$ac_ext" >&5
14378 cf_cv_struct_dirent64=no
14380 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
14383 echo "$as_me:14383: result: $cf_cv_struct_dirent64" >&5
14384 echo "${ECHO_T}$cf_cv_struct_dirent64" >&6
14385 test "$cf_cv_struct_dirent64" = yes &&
14386 cat >>confdefs.h <<\EOF
14387 #define HAVE_STRUCT_DIRENT64 1
14392 ### Enable compiling-in rcs id's
14393 echo "$as_me:14393: checking if RCS identifiers should be compiled-in" >&5
14394 echo $ECHO_N "checking if RCS identifiers should be compiled-in... $ECHO_C" >&6
14396 # Check whether --with-rcs-ids or --without-rcs-ids was given.
14397 if test "${with_rcs_ids+set}" = set; then
14398 withval="$with_rcs_ids"
14399 with_rcs_ids=$withval
14403 echo "$as_me:14403: result: $with_rcs_ids" >&5
14404 echo "${ECHO_T}$with_rcs_ids" >&6
14405 test "$with_rcs_ids" = yes &&
14406 cat >>confdefs.h <<\EOF
14407 #define USE_RCS_IDS 1
14410 ###############################################################################
14412 ### Note that some functions (such as const) are normally disabled anyway.
14413 echo "$as_me:14413: checking if you want to build with function extensions" >&5
14414 echo $ECHO_N "checking if you want to build with function extensions... $ECHO_C" >&6
14416 # Check whether --enable-ext-funcs or --disable-ext-funcs was given.
14417 if test "${enable_ext_funcs+set}" = set; then
14418 enableval="$enable_ext_funcs"
14419 with_ext_funcs=$enableval
14423 echo "$as_me:14423: result: $with_ext_funcs" >&5
14424 echo "${ECHO_T}$with_ext_funcs" >&6
14425 if test "$with_ext_funcs" = yes ; then
14426 NCURSES_EXT_FUNCS=1
14428 cat >>confdefs.h <<\EOF
14429 #define HAVE_USE_DEFAULT_COLORS 1
14432 cat >>confdefs.h <<\EOF
14433 #define NCURSES_EXT_FUNCS 1
14437 NCURSES_EXT_FUNCS=0
14440 ### use option --enable-const to turn on use of const beyond that in XSI.
14441 echo "$as_me:14441: checking for extended use of const keyword" >&5
14442 echo $ECHO_N "checking for extended use of const keyword... $ECHO_C" >&6
14444 # Check whether --enable-const or --disable-const was given.
14445 if test "${enable_const+set}" = set; then
14446 enableval="$enable_const"
14447 with_ext_const=$enableval
14451 echo "$as_me:14451: result: $with_ext_const" >&5
14452 echo "${ECHO_T}$with_ext_const" >&6
14453 NCURSES_CONST='/*nothing*/'
14454 if test "$with_ext_const" = yes ; then
14455 NCURSES_CONST=const
14458 ###############################################################################
14459 # These options are relatively safe to experiment with.
14461 echo "$as_me:14461: checking if you want all development code" >&5
14462 echo $ECHO_N "checking if you want all development code... $ECHO_C" >&6
14464 # Check whether --with-develop or --without-develop was given.
14465 if test "${with_develop+set}" = set; then
14466 withval="$with_develop"
14467 with_develop=$withval
14471 echo "$as_me:14471: result: $with_develop" >&5
14472 echo "${ECHO_T}$with_develop" >&6
14474 ###############################################################################
14475 # These are just experimental, probably should not be in a package:
14477 # This is still experimental (20080329), but should ultimately be moved to
14478 # the script-block --with-normal, etc.
14480 echo "$as_me:14480: checking if you want to link with the pthread library" >&5
14481 echo $ECHO_N "checking if you want to link with the pthread library... $ECHO_C" >&6
14483 # Check whether --with-pthread or --without-pthread was given.
14484 if test "${with_pthread+set}" = set; then
14485 withval="$with_pthread"
14486 with_pthread=$withval
14490 echo "$as_me:14490: result: $with_pthread" >&5
14491 echo "${ECHO_T}$with_pthread" >&6
14493 if test "$with_pthread" != no ; then
14494 echo "$as_me:14494: checking for pthread.h" >&5
14495 echo $ECHO_N "checking for pthread.h... $ECHO_C" >&6
14496 if test "${ac_cv_header_pthread_h+set}" = set; then
14497 echo $ECHO_N "(cached) $ECHO_C" >&6
14499 cat >"conftest.$ac_ext" <<_ACEOF
14500 #line 14500 "configure"
14501 #include "confdefs.h"
14502 #include <pthread.h>
14504 if { (eval echo "$as_me:14504: \"$ac_cpp "conftest.$ac_ext"\"") >&5
14505 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
14507 $EGREP -v '^ *\+' conftest.er1 >conftest.err
14509 cat conftest.err >&5
14510 echo "$as_me:14510: \$? = $ac_status" >&5
14511 (exit "$ac_status"); } >/dev/null; then
14512 if test -s conftest.err; then
14513 ac_cpp_err=$ac_c_preproc_warn_flag
14520 if test -z "$ac_cpp_err"; then
14521 ac_cv_header_pthread_h=yes
14523 echo "$as_me: failed program was:" >&5
14524 cat "conftest.$ac_ext" >&5
14525 ac_cv_header_pthread_h=no
14527 rm -f conftest.err "conftest.$ac_ext"
14529 echo "$as_me:14529: result: $ac_cv_header_pthread_h" >&5
14530 echo "${ECHO_T}$ac_cv_header_pthread_h" >&6
14531 if test "$ac_cv_header_pthread_h" = yes; then
14533 cat >>confdefs.h <<\EOF
14534 #define HAVE_PTHREADS_H 1
14537 for cf_lib_pthread in pthread c_r
14539 echo "$as_me:14539: checking if we can link with the $cf_lib_pthread library" >&5
14540 echo $ECHO_N "checking if we can link with the $cf_lib_pthread library... $ECHO_C" >&6
14541 cf_save_LIBS="$LIBS"
14543 cf_add_libs="$LIBS"
14546 for cf_add_1lib in -l$cf_lib_pthread; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
14547 # filter duplicates
14548 for cf_add_1lib in $cf_add_0lib; do
14549 for cf_add_2lib in $cf_add_libs; do
14550 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
14555 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
14557 LIBS="$cf_add_libs"
14559 cat >"conftest.$ac_ext" <<_ACEOF
14560 #line 14560 "configure"
14561 #include "confdefs.h"
14563 #include <pthread.h>
14569 int rc = pthread_create(0,0,0,0);
14570 int r2 = pthread_mutexattr_settype(0, 0);
14576 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
14577 if { (eval echo "$as_me:14577: \"$ac_link\"") >&5
14578 (eval $ac_link) 2>&5
14580 echo "$as_me:14580: \$? = $ac_status" >&5
14581 (exit "$ac_status"); } &&
14582 { ac_try='test -s "conftest$ac_exeext"'
14583 { (eval echo "$as_me:14583: \"$ac_try\"") >&5
14584 (eval $ac_try) 2>&5
14586 echo "$as_me:14586: \$? = $ac_status" >&5
14587 (exit "$ac_status"); }; }; then
14590 echo "$as_me: failed program was:" >&5
14591 cat "conftest.$ac_ext" >&5
14594 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
14595 LIBS="$cf_save_LIBS"
14596 echo "$as_me:14596: result: $with_pthread" >&5
14597 echo "${ECHO_T}$with_pthread" >&6
14598 test "$with_pthread" = yes && break
14601 if test "$with_pthread" = yes ; then
14603 cf_add_libs="$LIBS"
14606 for cf_add_1lib in -l$cf_lib_pthread; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
14607 # filter duplicates
14608 for cf_add_1lib in $cf_add_0lib; do
14609 for cf_add_2lib in $cf_add_libs; do
14610 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
14615 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
14617 LIBS="$cf_add_libs"
14619 cat >>confdefs.h <<\EOF
14620 #define HAVE_LIBPTHREADS 1
14624 { { echo "$as_me:14624: error: Cannot link with pthread library" >&5
14625 echo "$as_me: error: Cannot link with pthread library" >&2;}
14626 { (exit 1); exit 1; }; }
14633 echo "$as_me:14633: checking if you want to use weak-symbols for pthreads" >&5
14634 echo $ECHO_N "checking if you want to use weak-symbols for pthreads... $ECHO_C" >&6
14636 # Check whether --enable-weak-symbols or --disable-weak-symbols was given.
14637 if test "${enable_weak_symbols+set}" = set; then
14638 enableval="$enable_weak_symbols"
14639 use_weak_symbols=$withval
14641 use_weak_symbols=no
14643 echo "$as_me:14643: result: $use_weak_symbols" >&5
14644 echo "${ECHO_T}$use_weak_symbols" >&6
14645 if test "$use_weak_symbols" = yes ; then
14647 echo "$as_me:14647: checking if $CC supports weak symbols" >&5
14648 echo $ECHO_N "checking if $CC supports weak symbols... $ECHO_C" >&6
14649 if test "${cf_cv_weak_symbols+set}" = set; then
14650 echo $ECHO_N "(cached) $ECHO_C" >&6
14653 cat >"conftest.$ac_ext" <<_ACEOF
14654 #line 14654 "configure"
14655 #include "confdefs.h"
14662 #if defined(__GNUC__)
14663 # if defined __USE_ISOC99
14664 # define _cat_pragma(exp) _Pragma(#exp)
14665 # define _weak_pragma(exp) _cat_pragma(weak name)
14667 # define _weak_pragma(exp)
14669 # define _declare(name) __extension__ extern __typeof__(name) name
14670 # define weak_symbol(name) _weak_pragma(name) _declare(name) __attribute__((weak))
14673 weak_symbol(fopen);
14679 rm -f "conftest.$ac_objext"
14680 if { (eval echo "$as_me:14680: \"$ac_compile\"") >&5
14681 (eval $ac_compile) 2>&5
14683 echo "$as_me:14683: \$? = $ac_status" >&5
14684 (exit "$ac_status"); } &&
14685 { ac_try='test -s "conftest.$ac_objext"'
14686 { (eval echo "$as_me:14686: \"$ac_try\"") >&5
14687 (eval $ac_try) 2>&5
14689 echo "$as_me:14689: \$? = $ac_status" >&5
14690 (exit "$ac_status"); }; }; then
14691 cf_cv_weak_symbols=yes
14693 echo "$as_me: failed program was:" >&5
14694 cat "conftest.$ac_ext" >&5
14695 cf_cv_weak_symbols=no
14697 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
14700 echo "$as_me:14700: result: $cf_cv_weak_symbols" >&5
14701 echo "${ECHO_T}$cf_cv_weak_symbols" >&6
14704 cf_cv_weak_symbols=no
14707 if test $cf_cv_weak_symbols = yes ; then
14709 cat >>confdefs.h <<\EOF
14710 #define USE_WEAK_SYMBOLS 1
14716 if test "$with_pthread" = "yes" ; then
14718 cat >>confdefs.h <<\EOF
14719 #define USE_PTHREADS 1
14722 enable_reentrant=yes
14723 if test $cf_cv_weak_symbols = yes ; then
14728 # OpenSUSE is installing ncurses6, using reentrant option.
14729 echo "$as_me:14729: checking for _nc_TABSIZE" >&5
14730 echo $ECHO_N "checking for _nc_TABSIZE... $ECHO_C" >&6
14731 if test "${ac_cv_func__nc_TABSIZE+set}" = set; then
14732 echo $ECHO_N "(cached) $ECHO_C" >&6
14734 cat >"conftest.$ac_ext" <<_ACEOF
14735 #line 14735 "configure"
14736 #include "confdefs.h"
14737 #define _nc_TABSIZE autoconf_temporary
14738 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
14745 /* We use char because int might match the return type of a gcc2
14746 builtin and then its argument prototype would still apply. */
14747 char _nc_TABSIZE (void);
14753 /* The GNU C library defines stubs for functions which it implements
14754 to always fail with ENOSYS. Some functions are actually named
14755 something starting with __ and the normal name is an alias. */
14756 #if defined (__stub__nc_TABSIZE) || defined (__stub____nc_TABSIZE)
14757 #error found stub for _nc_TABSIZE
14760 return _nc_TABSIZE ();
14765 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
14766 if { (eval echo "$as_me:14766: \"$ac_link\"") >&5
14767 (eval $ac_link) 2>&5
14769 echo "$as_me:14769: \$? = $ac_status" >&5
14770 (exit "$ac_status"); } &&
14771 { ac_try='test -s "conftest$ac_exeext"'
14772 { (eval echo "$as_me:14772: \"$ac_try\"") >&5
14773 (eval $ac_try) 2>&5
14775 echo "$as_me:14775: \$? = $ac_status" >&5
14776 (exit "$ac_status"); }; }; then
14777 ac_cv_func__nc_TABSIZE=yes
14779 echo "$as_me: failed program was:" >&5
14780 cat "conftest.$ac_ext" >&5
14781 ac_cv_func__nc_TABSIZE=no
14783 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
14785 echo "$as_me:14785: result: $ac_cv_func__nc_TABSIZE" >&5
14786 echo "${ECHO_T}$ac_cv_func__nc_TABSIZE" >&6
14787 if test "$ac_cv_func__nc_TABSIZE" = yes; then
14788 assume_reentrant=yes
14790 assume_reentrant=no
14793 # Reentrant code has to be opaque; there's little advantage to making ncurses
14794 # opaque outside of that, so there is no --enable-opaque option. We can use
14795 # this option without --with-pthreads, but this will be always set for
14797 echo "$as_me:14797: checking if you want experimental reentrant code" >&5
14798 echo $ECHO_N "checking if you want experimental reentrant code... $ECHO_C" >&6
14800 # Check whether --enable-reentrant or --disable-reentrant was given.
14801 if test "${enable_reentrant+set}" = set; then
14802 enableval="$enable_reentrant"
14803 with_reentrant=$enableval
14805 with_reentrant=$assume_reentrant
14807 echo "$as_me:14807: result: $with_reentrant" >&5
14808 echo "${ECHO_T}$with_reentrant" >&6
14809 if test "$with_reentrant" = yes ; then
14810 cf_cv_enable_reentrant=1
14811 if test $cf_cv_weak_symbols = yes ; then
14813 # remove pthread library from $LIBS
14814 LIBS=`echo "$LIBS" | sed -e 's/-lpthread[ ]//g' -e 's/-lpthread$//'`
14816 elif test "$assume_reentrant" = no ; then
14817 LIB_SUFFIX="t${LIB_SUFFIX}"
14820 cat >>confdefs.h <<\EOF
14821 #define USE_REENTRANT 1
14825 cf_cv_enable_reentrant=0
14828 ### Allow using a different wrap-prefix
14829 if test "$cf_cv_enable_reentrant" != 0 || test "$BROKEN_LINKER" = 1 ; then
14830 echo "$as_me:14830: checking for prefix used to wrap public variables" >&5
14831 echo $ECHO_N "checking for prefix used to wrap public variables... $ECHO_C" >&6
14833 # Check whether --with-wrap-prefix or --without-wrap-prefix was given.
14834 if test "${with_wrap_prefix+set}" = set; then
14835 withval="$with_wrap_prefix"
14836 NCURSES_WRAP_PREFIX=$withval
14838 NCURSES_WRAP_PREFIX=_nc_
14840 echo "$as_me:14840: result: $NCURSES_WRAP_PREFIX" >&5
14841 echo "${ECHO_T}$NCURSES_WRAP_PREFIX" >&6
14843 NCURSES_WRAP_PREFIX=_nc_
14846 cat >>confdefs.h <<EOF
14847 #define NCURSES_WRAP_PREFIX "$NCURSES_WRAP_PREFIX"
14850 ###############################################################################
14852 ### use option --disable-echo to suppress full display compiling commands
14854 echo "$as_me:14854: checking if you want to see long compiling messages" >&5
14855 echo $ECHO_N "checking if you want to see long compiling messages... $ECHO_C" >&6
14857 # Check whether --enable-echo or --disable-echo was given.
14858 if test "${enable_echo+set}" = set; then
14859 enableval="$enable_echo"
14860 test "$enableval" != no && enableval=yes
14861 if test "$enableval" != "yes" ; then
14864 ECHO_LD='@echo linking $@;'
14865 RULE_CC='@echo compiling $<'
14866 SHOW_CC='@echo compiling $@'
14888 echo "$as_me:14888: result: $enableval" >&5
14889 echo "${ECHO_T}$enableval" >&6
14891 echo "$as_me:14891: checking if you want to use C11 _Noreturn feature" >&5
14892 echo $ECHO_N "checking if you want to use C11 _Noreturn feature... $ECHO_C" >&6
14894 # Check whether --enable-stdnoreturn or --disable-stdnoreturn was given.
14895 if test "${enable_stdnoreturn+set}" = set; then
14896 enableval="$enable_stdnoreturn"
14897 test "$enableval" != yes && enableval=no
14898 if test "$enableval" != "no" ; then
14899 enable_stdnoreturn=yes
14901 enable_stdnoreturn=no
14905 enable_stdnoreturn=no
14908 echo "$as_me:14908: result: $enable_stdnoreturn" >&5
14909 echo "${ECHO_T}$enable_stdnoreturn" >&6
14911 if test $enable_stdnoreturn = yes; then
14912 echo "$as_me:14912: checking for C11 _Noreturn feature" >&5
14913 echo $ECHO_N "checking for C11 _Noreturn feature... $ECHO_C" >&6
14914 if test "${cf_cv_c11_noreturn+set}" = set; then
14915 echo $ECHO_N "(cached) $ECHO_C" >&6
14917 cat >"conftest.$ac_ext" <<_ACEOF
14918 #line 14918 "configure"
14919 #include "confdefs.h"
14922 #include <stdlib.h>
14923 #include <stdnoreturn.h>
14924 static _Noreturn void giveup(void) { exit(0); }
14929 if (feof(stdin)) giveup()
14934 rm -f "conftest.$ac_objext"
14935 if { (eval echo "$as_me:14935: \"$ac_compile\"") >&5
14936 (eval $ac_compile) 2>&5
14938 echo "$as_me:14938: \$? = $ac_status" >&5
14939 (exit "$ac_status"); } &&
14940 { ac_try='test -s "conftest.$ac_objext"'
14941 { (eval echo "$as_me:14941: \"$ac_try\"") >&5
14942 (eval $ac_try) 2>&5
14944 echo "$as_me:14944: \$? = $ac_status" >&5
14945 (exit "$ac_status"); }; }; then
14946 cf_cv_c11_noreturn=yes
14948 echo "$as_me: failed program was:" >&5
14949 cat "conftest.$ac_ext" >&5
14950 cf_cv_c11_noreturn=no
14952 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
14955 echo "$as_me:14955: result: $cf_cv_c11_noreturn" >&5
14956 echo "${ECHO_T}$cf_cv_c11_noreturn" >&6
14958 cf_cv_c11_noreturn=no,
14961 if test "$cf_cv_c11_noreturn" = yes; then
14963 cat >>confdefs.h <<\EOF
14964 #define HAVE_STDNORETURN_H 1
14967 cat >>confdefs.h <<EOF
14968 #define STDC_NORETURN _Noreturn
14971 HAVE_STDNORETURN_H=1
14973 HAVE_STDNORETURN_H=0
14976 if test "$GCC" = yes || test "$GXX" = yes
14979 if test "$GCC" = yes || test "$GXX" = yes
14983 test -n "$verbose" && echo " repairing CFLAGS: $CFLAGS" 1>&6
14985 echo "${as_me:-configure}:14985: testing repairing CFLAGS: $CFLAGS ..." 1>&5
14988 for cf_temp_scan in $CFLAGS
14990 case "x$cf_temp_scan" in
14993 test -n "$EXTRA_CFLAGS" && EXTRA_CFLAGS="$EXTRA_CFLAGS "
14994 EXTRA_CFLAGS="${EXTRA_CFLAGS}$cf_temp_scan"
14999 test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
15000 cf_temp_flags="${cf_temp_flags}$cf_temp_scan"
15005 CFLAGS="$cf_temp_flags"
15006 test -n "$verbose" && echo " ... fixed $CFLAGS" 1>&6
15008 echo "${as_me:-configure}:15008: testing ... fixed $CFLAGS ..." 1>&5
15010 test -n "$verbose" && echo " ... extra $EXTRA_CFLAGS" 1>&6
15012 echo "${as_me:-configure}:15012: testing ... extra $EXTRA_CFLAGS ..." 1>&5
15018 if test "$GCC" = yes || test "$GXX" = yes
15022 test -n "$verbose" && echo " repairing CPPFLAGS: $CPPFLAGS" 1>&6
15024 echo "${as_me:-configure}:15024: testing repairing CPPFLAGS: $CPPFLAGS ..." 1>&5
15027 for cf_temp_scan in $CPPFLAGS
15029 case "x$cf_temp_scan" in
15032 test -n "$EXTRA_CFLAGS" && EXTRA_CFLAGS="$EXTRA_CFLAGS "
15033 EXTRA_CFLAGS="${EXTRA_CFLAGS}$cf_temp_scan"
15038 test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
15039 cf_temp_flags="${cf_temp_flags}$cf_temp_scan"
15044 CPPFLAGS="$cf_temp_flags"
15045 test -n "$verbose" && echo " ... fixed $CPPFLAGS" 1>&6
15047 echo "${as_me:-configure}:15047: testing ... fixed $CPPFLAGS ..." 1>&5
15049 test -n "$verbose" && echo " ... extra $EXTRA_CFLAGS" 1>&6
15051 echo "${as_me:-configure}:15051: testing ... extra $EXTRA_CFLAGS ..." 1>&5
15057 if test "$GCC" = yes || test "$GXX" = yes
15061 test -n "$verbose" && echo " repairing LDFLAGS: $LDFLAGS" 1>&6
15063 echo "${as_me:-configure}:15063: testing repairing LDFLAGS: $LDFLAGS ..." 1>&5
15066 for cf_temp_scan in $LDFLAGS
15068 case "x$cf_temp_scan" in
15071 test -n "$EXTRA_CFLAGS" && EXTRA_CFLAGS="$EXTRA_CFLAGS "
15072 EXTRA_CFLAGS="${EXTRA_CFLAGS}$cf_temp_scan"
15077 test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
15078 cf_temp_flags="${cf_temp_flags}$cf_temp_scan"
15083 LDFLAGS="$cf_temp_flags"
15084 test -n "$verbose" && echo " ... fixed $LDFLAGS" 1>&6
15086 echo "${as_me:-configure}:15086: testing ... fixed $LDFLAGS ..." 1>&5
15088 test -n "$verbose" && echo " ... extra $EXTRA_CFLAGS" 1>&6
15090 echo "${as_me:-configure}:15090: testing ... extra $EXTRA_CFLAGS ..." 1>&5
15096 echo "$as_me:15096: checking if you want to turn on gcc warnings" >&5
15097 echo $ECHO_N "checking if you want to turn on gcc warnings... $ECHO_C" >&6
15099 # Check whether --enable-warnings or --disable-warnings was given.
15100 if test "${enable_warnings+set}" = set; then
15101 enableval="$enable_warnings"
15102 test "$enableval" != yes && enableval=no
15103 if test "$enableval" != "no" ; then
15104 enable_warnings=yes
15113 echo "$as_me:15113: result: $enable_warnings" >&5
15114 echo "${ECHO_T}$enable_warnings" >&6
15115 if test "$enable_warnings" = "yes"
15118 if test "x$have_x" = xyes; then
15120 cf_save_LIBS_CF_CONST_X_STRING="$LIBS"
15121 cf_save_CFLAGS_CF_CONST_X_STRING="$CFLAGS"
15122 cf_save_CPPFLAGS_CF_CONST_X_STRING="$CPPFLAGS"
15123 LIBS="$LIBS ${X_PRE_LIBS} ${X_LIBS} ${X_EXTRA_LIBS}"
15124 for cf_X_CFLAGS in $X_CFLAGS
15126 case "x$cf_X_CFLAGS" in
15128 CPPFLAGS="$CPPFLAGS $cf_X_CFLAGS"
15131 CFLAGS="$CFLAGS $cf_X_CFLAGS"
15136 cat >"conftest.$ac_ext" <<_ACEOF
15137 #line 15137 "configure"
15138 #include "confdefs.h"
15140 #include <stdlib.h>
15141 #include <X11/Intrinsic.h>
15146 String foo = malloc(1); free((void*)foo)
15151 rm -f "conftest.$ac_objext"
15152 if { (eval echo "$as_me:15152: \"$ac_compile\"") >&5
15153 (eval $ac_compile) 2>&5
15155 echo "$as_me:15155: \$? = $ac_status" >&5
15156 (exit "$ac_status"); } &&
15157 { ac_try='test -s "conftest.$ac_objext"'
15158 { (eval echo "$as_me:15158: \"$ac_try\"") >&5
15159 (eval $ac_try) 2>&5
15161 echo "$as_me:15161: \$? = $ac_status" >&5
15162 (exit "$ac_status"); }; }; then
15164 echo "$as_me:15164: checking for X11/Xt const-feature" >&5
15165 echo $ECHO_N "checking for X11/Xt const-feature... $ECHO_C" >&6
15166 if test "${cf_cv_const_x_string+set}" = set; then
15167 echo $ECHO_N "(cached) $ECHO_C" >&6
15170 cat >"conftest.$ac_ext" <<_ACEOF
15171 #line 15171 "configure"
15172 #include "confdefs.h"
15174 #define _CONST_X_STRING /* X11R7.8 (perhaps) */
15175 #undef XTSTRINGDEFINES /* X11R5 and later */
15176 #include <stdlib.h>
15177 #include <X11/Intrinsic.h>
15182 String foo = malloc(1); *foo = 0
15187 rm -f "conftest.$ac_objext"
15188 if { (eval echo "$as_me:15188: \"$ac_compile\"") >&5
15189 (eval $ac_compile) 2>&5
15191 echo "$as_me:15191: \$? = $ac_status" >&5
15192 (exit "$ac_status"); } &&
15193 { ac_try='test -s "conftest.$ac_objext"'
15194 { (eval echo "$as_me:15194: \"$ac_try\"") >&5
15195 (eval $ac_try) 2>&5
15197 echo "$as_me:15197: \$? = $ac_status" >&5
15198 (exit "$ac_status"); }; }; then
15200 cf_cv_const_x_string=no
15203 echo "$as_me: failed program was:" >&5
15204 cat "conftest.$ac_ext" >&5
15206 cf_cv_const_x_string=yes
15209 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
15212 echo "$as_me:15212: result: $cf_cv_const_x_string" >&5
15213 echo "${ECHO_T}$cf_cv_const_x_string" >&6
15215 LIBS="$cf_save_LIBS_CF_CONST_X_STRING"
15216 CFLAGS="$cf_save_CFLAGS_CF_CONST_X_STRING"
15217 CPPFLAGS="$cf_save_CPPFLAGS_CF_CONST_X_STRING"
15219 case "$cf_cv_const_x_string" in
15222 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
15223 CPPFLAGS="${CPPFLAGS}-DXTSTRINGDEFINES"
15228 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
15229 CPPFLAGS="${CPPFLAGS}-D_CONST_X_STRING"
15235 echo "$as_me: failed program was:" >&5
15236 cat "conftest.$ac_ext" >&5
15238 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
15240 cat > "conftest.$ac_ext" <<EOF
15241 #line 15241 "${as_me:-configure}"
15242 int main(int argc, char *argv[]) { return (argv[argc-1] == 0) ; }
15244 if test "$INTEL_COMPILER" = yes
15246 # The "-wdXXX" options suppress warnings:
15247 # remark #1419: external declaration in primary source file
15248 # remark #1683: explicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem)
15249 # remark #1684: conversion from pointer to same-sized integral type (potential portability problem)
15250 # remark #193: zero used for undefined preprocessing identifier
15251 # remark #593: variable "curs_sb_left_arrow" was set but never used
15252 # remark #810: conversion from "int" to "Dimension={unsigned short}" may lose significant bits
15253 # remark #869: parameter "tw" was never referenced
15254 # remark #981: operands are evaluated in unspecified order
15255 # warning #279: controlling expression is constant
15257 { echo "$as_me:15257: checking for $CC warning options..." >&5
15258 echo "$as_me: checking for $CC warning options..." >&6;}
15259 cf_save_CFLAGS="$CFLAGS"
15260 EXTRA_CFLAGS="$EXTRA_CFLAGS -Wall"
15272 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
15273 if { (eval echo "$as_me:15273: \"$ac_compile\"") >&5
15274 (eval $ac_compile) 2>&5
15276 echo "$as_me:15276: \$? = $ac_status" >&5
15277 (exit "$ac_status"); }; then
15278 test -n "$verbose" && echo "$as_me:15278: result: ... -$cf_opt" >&5
15279 echo "${ECHO_T}... -$cf_opt" >&6
15280 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
15283 CFLAGS="$cf_save_CFLAGS"
15284 elif test "$GCC" = yes && test "$GCC_VERSION" != "unknown"
15286 { echo "$as_me:15286: checking for $CC warning options..." >&5
15287 echo "$as_me: checking for $CC warning options..." >&6;}
15288 cf_save_CFLAGS="$CFLAGS"
15290 test "$with_ext_const" = yes && cf_warn_CONST="Wwrite-strings"
15291 cf_gcc_warnings="Wignored-qualifiers Wlogical-op Wvarargs"
15292 test "x$CLANG_COMPILER" = xyes && cf_gcc_warnings=
15293 for cf_opt in W Wall \
15294 Wbad-function-cast \
15297 Wdeclaration-after-statement \
15300 Wmissing-declarations \
15301 Wmissing-prototypes \
15305 Wstrict-prototypes \
15306 Wundef Wno-inline $cf_gcc_warnings $cf_warn_CONST Wno-unknown-pragmas Wswitch-enum
15308 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
15309 if { (eval echo "$as_me:15309: \"$ac_compile\"") >&5
15310 (eval $ac_compile) 2>&5
15312 echo "$as_me:15312: \$? = $ac_status" >&5
15313 (exit "$ac_status"); }; then
15314 test -n "$verbose" && echo "$as_me:15314: result: ... -$cf_opt" >&5
15315 echo "${ECHO_T}... -$cf_opt" >&6
15318 case "$GCC_VERSION" in
15320 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
15322 echo "${as_me:-configure}:15322: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
15328 case "$GCC_VERSION" in
15330 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
15332 echo "${as_me:-configure}:15332: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
15338 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
15341 CFLAGS="$cf_save_CFLAGS"
15347 if test "$GCC" = yes || test "$GXX" = yes
15349 cat > conftest.i <<EOF
15351 #define GCC_PRINTF 0
15354 #define GCC_SCANF 0
15356 #ifndef GCC_NORETURN
15357 #define GCC_NORETURN /* nothing */
15360 #define GCC_UNUSED /* nothing */
15363 if test "$GCC" = yes
15365 { echo "$as_me:15365: checking for $CC __attribute__ directives..." >&5
15366 echo "$as_me: checking for $CC __attribute__ directives..." >&6;}
15367 cat > "conftest.$ac_ext" <<EOF
15368 #line 15368 "${as_me:-configure}"
15369 #include "confdefs.h"
15370 #include "conftest.h"
15371 #include "conftest.i"
15373 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
15375 #define GCC_PRINTFLIKE(fmt,var) /*nothing*/
15378 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
15380 #define GCC_SCANFLIKE(fmt,var) /*nothing*/
15382 extern void wow(char *,...) GCC_SCANFLIKE(1,2);
15383 extern GCC_NORETURN void oops(char *,...) GCC_PRINTFLIKE(1,2);
15384 extern GCC_NORETURN void foo(void);
15385 int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { (void)argc; (void)argv; return 0; }
15387 cf_printf_attribute=no
15388 cf_scanf_attribute=no
15389 for cf_attribute in scanf printf unused noreturn
15392 cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
15394 cf_directive="__attribute__(($cf_attribute))"
15395 echo "checking for $CC $cf_directive" 1>&5
15397 case "$cf_attribute" in
15399 cf_printf_attribute=yes
15400 cat >conftest.h <<EOF
15401 #define GCC_$cf_ATTRIBUTE 1
15405 cf_scanf_attribute=yes
15406 cat >conftest.h <<EOF
15407 #define GCC_$cf_ATTRIBUTE 1
15411 cat >conftest.h <<EOF
15412 #define GCC_$cf_ATTRIBUTE $cf_directive
15417 if { (eval echo "$as_me:15417: \"$ac_compile\"") >&5
15418 (eval $ac_compile) 2>&5
15420 echo "$as_me:15420: \$? = $ac_status" >&5
15421 (exit "$ac_status"); }; then
15422 test -n "$verbose" && echo "$as_me:15422: result: ... $cf_attribute" >&5
15423 echo "${ECHO_T}... $cf_attribute" >&6
15424 cat conftest.h >>confdefs.h
15425 case "$cf_attribute" in
15428 cat >>confdefs.h <<EOF
15429 #define GCC_NORETURN $cf_directive
15434 cf_value='/* nothing */'
15435 if test "$cf_printf_attribute" != no ; then
15436 cf_value='__attribute__((format(printf,fmt,var)))'
15438 cat >>confdefs.h <<\EOF
15439 #define GCC_PRINTF 1
15444 cat >>confdefs.h <<EOF
15445 #define GCC_PRINTFLIKE(fmt,var) $cf_value
15450 cf_value='/* nothing */'
15451 if test "$cf_scanf_attribute" != no ; then
15452 cf_value='__attribute__((format(scanf,fmt,var)))'
15454 cat >>confdefs.h <<\EOF
15455 #define GCC_SCANF 1
15460 cat >>confdefs.h <<EOF
15461 #define GCC_SCANFLIKE(fmt,var) $cf_value
15467 cat >>confdefs.h <<EOF
15468 #define GCC_UNUSED $cf_directive
15476 ${FGREP-fgrep} define conftest.i >>confdefs.h
15483 if test "x$enable_warnings" = "xyes"; then
15485 ADAFLAGS="$ADAFLAGS -gnatg"
15489 ### use option --enable-assertions to turn on generation of assertion code
15490 echo "$as_me:15490: checking if you want to enable runtime assertions" >&5
15491 echo $ECHO_N "checking if you want to enable runtime assertions... $ECHO_C" >&6
15493 # Check whether --enable-assertions or --disable-assertions was given.
15494 if test "${enable_assertions+set}" = set; then
15495 enableval="$enable_assertions"
15496 with_assertions=$enableval
15500 echo "$as_me:15500: result: $with_assertions" >&5
15501 echo "${ECHO_T}$with_assertions" >&6
15504 if test "$with_assertions" = no
15506 CPPFLAGS="$CPPFLAGS -DNDEBUG"
15509 ADAFLAGS="$ADAFLAGS -gnata"
15514 ### use option --disable-leaks to suppress "permanent" leaks, for testing
15516 cat >>confdefs.h <<\EOF
15517 #define HAVE_NC_ALLOC_H 1
15520 ### use option --enable-expanded to generate certain macros as functions
15522 # Check whether --enable-expanded or --disable-expanded was given.
15523 if test "${enable_expanded+set}" = set; then
15524 enableval="$enable_expanded"
15525 test "$enableval" = yes &&
15526 cat >>confdefs.h <<\EOF
15527 #define NCURSES_EXPANDED 1
15532 ### use option --disable-macros to suppress macros in favor of functions
15534 # Check whether --enable-macros or --disable-macros was given.
15535 if test "${enable_macros+set}" = set; then
15536 enableval="$enable_macros"
15537 test "$enableval" = no &&
15538 cat >>confdefs.h <<\EOF
15539 #define NCURSES_NOMACROS 1
15544 # Normally we only add trace() to the debug-library. Allow this to be
15545 # extended to all models of the ncurses library:
15547 case "$CFLAGS $CPPFLAGS" in
15553 echo "$as_me:15553: checking whether to add trace feature to all models" >&5
15554 echo $ECHO_N "checking whether to add trace feature to all models... $ECHO_C" >&6
15556 # Check whether --with-trace or --without-trace was given.
15557 if test "${with_trace+set}" = set; then
15558 withval="$with_trace"
15559 cf_with_trace=$withval
15561 cf_with_trace=$cf_all_traces
15563 echo "$as_me:15563: result: $cf_with_trace" >&5
15564 echo "${ECHO_T}$cf_with_trace" >&6
15566 if test "$cf_with_trace" = yes ; then
15572 cf_new_extra_cppflags=
15574 for cf_add_cflags in -DTRACE
15576 case "$cf_fix_cppflags" in
15578 case "$cf_add_cflags" in
15579 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
15580 case "$cf_add_cflags" in
15582 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
15584 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15585 && test -z "${cf_tst_cflags}" \
15586 && cf_fix_cppflags=yes
15588 if test "$cf_fix_cppflags" = yes ; then
15590 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15591 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15594 elif test "${cf_tst_cflags}" = "\"'" ; then
15596 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15597 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15603 case "$CPPFLAGS" in
15607 case "$cf_add_cflags" in
15609 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
15611 CPPFLAGS=`echo "$CPPFLAGS" | \
15612 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
15613 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
15618 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
15619 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
15626 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
15627 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
15634 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15635 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15637 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
15639 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15640 && test -z "${cf_tst_cflags}" \
15641 && cf_fix_cppflags=no
15646 if test -n "$cf_new_cflags" ; then
15648 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
15649 CFLAGS="${CFLAGS}$cf_new_cflags"
15653 if test -n "$cf_new_cppflags" ; then
15655 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
15656 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
15660 if test -n "$cf_new_extra_cppflags" ; then
15662 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
15663 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
15671 echo "$as_me:15671: checking if we want to use GNAT projects" >&5
15672 echo $ECHO_N "checking if we want to use GNAT projects... $ECHO_C" >&6
15674 # Check whether --enable-gnat-projects or --disable-gnat-projects was given.
15675 if test "${enable_gnat_projects+set}" = set; then
15676 enableval="$enable_gnat_projects"
15677 test "$enableval" != no && enableval=yes
15678 if test "$enableval" != "yes" ; then
15679 enable_gnat_projects=no
15681 enable_gnat_projects=yes
15685 enable_gnat_projects=yes
15688 echo "$as_me:15688: result: $enable_gnat_projects" >&5
15689 echo "${ECHO_T}$enable_gnat_projects" >&6
15691 ### Checks for libraries.
15692 case $cf_cv_system_name in
15696 echo "$as_me:15696: checking for gettimeofday" >&5
15697 echo $ECHO_N "checking for gettimeofday... $ECHO_C" >&6
15698 if test "${ac_cv_func_gettimeofday+set}" = set; then
15699 echo $ECHO_N "(cached) $ECHO_C" >&6
15701 cat >"conftest.$ac_ext" <<_ACEOF
15702 #line 15702 "configure"
15703 #include "confdefs.h"
15704 #define gettimeofday autoconf_temporary
15705 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
15706 #undef gettimeofday
15712 /* We use char because int might match the return type of a gcc2
15713 builtin and then its argument prototype would still apply. */
15714 char gettimeofday (void);
15720 /* The GNU C library defines stubs for functions which it implements
15721 to always fail with ENOSYS. Some functions are actually named
15722 something starting with __ and the normal name is an alias. */
15723 #if defined (__stub_gettimeofday) || defined (__stub___gettimeofday)
15724 #error found stub for gettimeofday
15727 return gettimeofday ();
15732 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
15733 if { (eval echo "$as_me:15733: \"$ac_link\"") >&5
15734 (eval $ac_link) 2>&5
15736 echo "$as_me:15736: \$? = $ac_status" >&5
15737 (exit "$ac_status"); } &&
15738 { ac_try='test -s "conftest$ac_exeext"'
15739 { (eval echo "$as_me:15739: \"$ac_try\"") >&5
15740 (eval $ac_try) 2>&5
15742 echo "$as_me:15742: \$? = $ac_status" >&5
15743 (exit "$ac_status"); }; }; then
15744 ac_cv_func_gettimeofday=yes
15746 echo "$as_me: failed program was:" >&5
15747 cat "conftest.$ac_ext" >&5
15748 ac_cv_func_gettimeofday=no
15750 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
15752 echo "$as_me:15752: result: $ac_cv_func_gettimeofday" >&5
15753 echo "${ECHO_T}$ac_cv_func_gettimeofday" >&6
15754 if test "$ac_cv_func_gettimeofday" = yes; then
15755 cat >>confdefs.h <<\EOF
15756 #define HAVE_GETTIMEOFDAY 1
15761 echo "$as_me:15761: checking for gettimeofday in -lbsd" >&5
15762 echo $ECHO_N "checking for gettimeofday in -lbsd... $ECHO_C" >&6
15763 if test "${ac_cv_lib_bsd_gettimeofday+set}" = set; then
15764 echo $ECHO_N "(cached) $ECHO_C" >&6
15766 ac_check_lib_save_LIBS=$LIBS
15768 cat >"conftest.$ac_ext" <<_ACEOF
15769 #line 15769 "configure"
15770 #include "confdefs.h"
15772 /* Override any gcc2 internal prototype to avoid an error. */
15776 /* We use char because int might match the return type of a gcc2
15777 builtin and then its argument prototype would still apply. */
15778 char gettimeofday ();
15787 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
15788 if { (eval echo "$as_me:15788: \"$ac_link\"") >&5
15789 (eval $ac_link) 2>&5
15791 echo "$as_me:15791: \$? = $ac_status" >&5
15792 (exit "$ac_status"); } &&
15793 { ac_try='test -s "conftest$ac_exeext"'
15794 { (eval echo "$as_me:15794: \"$ac_try\"") >&5
15795 (eval $ac_try) 2>&5
15797 echo "$as_me:15797: \$? = $ac_status" >&5
15798 (exit "$ac_status"); }; }; then
15799 ac_cv_lib_bsd_gettimeofday=yes
15801 echo "$as_me: failed program was:" >&5
15802 cat "conftest.$ac_ext" >&5
15803 ac_cv_lib_bsd_gettimeofday=no
15805 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
15806 LIBS=$ac_check_lib_save_LIBS
15808 echo "$as_me:15808: result: $ac_cv_lib_bsd_gettimeofday" >&5
15809 echo "${ECHO_T}$ac_cv_lib_bsd_gettimeofday" >&6
15810 if test "$ac_cv_lib_bsd_gettimeofday" = yes; then
15812 cat >>confdefs.h <<\EOF
15813 #define HAVE_GETTIMEOFDAY 1
15823 ### Checks for header files.
15824 echo "$as_me:15824: checking for ANSI C header files" >&5
15825 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
15826 if test "${ac_cv_header_stdc+set}" = set; then
15827 echo $ECHO_N "(cached) $ECHO_C" >&6
15829 cat >"conftest.$ac_ext" <<_ACEOF
15830 #line 15830 "configure"
15831 #include "confdefs.h"
15832 #include <stdlib.h>
15833 #include <stdarg.h>
15834 #include <string.h>
15838 if { (eval echo "$as_me:15838: \"$ac_cpp "conftest.$ac_ext"\"") >&5
15839 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
15841 $EGREP -v '^ *\+' conftest.er1 >conftest.err
15843 cat conftest.err >&5
15844 echo "$as_me:15844: \$? = $ac_status" >&5
15845 (exit "$ac_status"); } >/dev/null; then
15846 if test -s conftest.err; then
15847 ac_cpp_err=$ac_c_preproc_warn_flag
15854 if test -z "$ac_cpp_err"; then
15855 ac_cv_header_stdc=yes
15857 echo "$as_me: failed program was:" >&5
15858 cat "conftest.$ac_ext" >&5
15859 ac_cv_header_stdc=no
15861 rm -f conftest.err "conftest.$ac_ext"
15863 if test $ac_cv_header_stdc = yes; then
15864 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
15865 cat >"conftest.$ac_ext" <<_ACEOF
15866 #line 15866 "configure"
15867 #include "confdefs.h"
15868 #include <string.h>
15871 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
15872 $EGREP "memchr" >/dev/null 2>&1; then
15875 ac_cv_header_stdc=no
15881 if test $ac_cv_header_stdc = yes; then
15882 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
15883 cat >"conftest.$ac_ext" <<_ACEOF
15884 #line 15884 "configure"
15885 #include "confdefs.h"
15886 #include <stdlib.h>
15889 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
15890 $EGREP "free" >/dev/null 2>&1; then
15893 ac_cv_header_stdc=no
15899 if test $ac_cv_header_stdc = yes; then
15900 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
15901 if test "$cross_compiling" = yes; then
15904 cat >"conftest.$ac_ext" <<_ACEOF
15905 #line 15905 "configure"
15906 #include "confdefs.h"
15908 #if ((' ' & 0x0FF) == 0x020)
15909 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
15910 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
15912 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
15913 || ('j' <= (c) && (c) <= 'r') \
15914 || ('s' <= (c) && (c) <= 'z'))
15915 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
15918 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
15923 for (i = 0; i < 256; i++)
15924 if (XOR (islower (i), ISLOWER (i))
15925 || toupper (i) != TOUPPER (i))
15926 $ac_main_return(2);
15927 $ac_main_return (0);
15930 rm -f "conftest$ac_exeext"
15931 if { (eval echo "$as_me:15931: \"$ac_link\"") >&5
15932 (eval $ac_link) 2>&5
15934 echo "$as_me:15934: \$? = $ac_status" >&5
15935 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
15936 { (eval echo "$as_me:15936: \"$ac_try\"") >&5
15937 (eval $ac_try) 2>&5
15939 echo "$as_me:15939: \$? = $ac_status" >&5
15940 (exit "$ac_status"); }; }; then
15943 echo "$as_me: program exited with status $ac_status" >&5
15944 echo "$as_me: failed program was:" >&5
15945 cat "conftest.$ac_ext" >&5
15946 ac_cv_header_stdc=no
15948 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
15952 echo "$as_me:15952: result: $ac_cv_header_stdc" >&5
15953 echo "${ECHO_T}$ac_cv_header_stdc" >&6
15954 if test $ac_cv_header_stdc = yes; then
15956 cat >>confdefs.h <<\EOF
15957 #define STDC_HEADERS 1
15962 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
15964 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
15965 inttypes.h stdint.h unistd.h
15967 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15968 echo "$as_me:15968: checking for $ac_header" >&5
15969 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15970 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15971 echo $ECHO_N "(cached) $ECHO_C" >&6
15973 cat >"conftest.$ac_ext" <<_ACEOF
15974 #line 15974 "configure"
15975 #include "confdefs.h"
15976 $ac_includes_default
15977 #include <$ac_header>
15979 rm -f "conftest.$ac_objext"
15980 if { (eval echo "$as_me:15980: \"$ac_compile\"") >&5
15981 (eval $ac_compile) 2>&5
15983 echo "$as_me:15983: \$? = $ac_status" >&5
15984 (exit "$ac_status"); } &&
15985 { ac_try='test -s "conftest.$ac_objext"'
15986 { (eval echo "$as_me:15986: \"$ac_try\"") >&5
15987 (eval $ac_try) 2>&5
15989 echo "$as_me:15989: \$? = $ac_status" >&5
15990 (exit "$ac_status"); }; }; then
15991 eval "$as_ac_Header=yes"
15993 echo "$as_me: failed program was:" >&5
15994 cat "conftest.$ac_ext" >&5
15995 eval "$as_ac_Header=no"
15997 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
15999 echo "$as_me:15999: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
16000 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
16001 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
16002 cat >>confdefs.h <<EOF
16003 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
16009 echo "$as_me:16009: checking for signed char" >&5
16010 echo $ECHO_N "checking for signed char... $ECHO_C" >&6
16011 if test "${ac_cv_type_signed_char+set}" = set; then
16012 echo $ECHO_N "(cached) $ECHO_C" >&6
16014 cat >"conftest.$ac_ext" <<_ACEOF
16015 #line 16015 "configure"
16016 #include "confdefs.h"
16017 $ac_includes_default
16021 if ((signed char *) 0)
16023 if (sizeof (signed char))
16029 rm -f "conftest.$ac_objext"
16030 if { (eval echo "$as_me:16030: \"$ac_compile\"") >&5
16031 (eval $ac_compile) 2>&5
16033 echo "$as_me:16033: \$? = $ac_status" >&5
16034 (exit "$ac_status"); } &&
16035 { ac_try='test -s "conftest.$ac_objext"'
16036 { (eval echo "$as_me:16036: \"$ac_try\"") >&5
16037 (eval $ac_try) 2>&5
16039 echo "$as_me:16039: \$? = $ac_status" >&5
16040 (exit "$ac_status"); }; }; then
16041 ac_cv_type_signed_char=yes
16043 echo "$as_me: failed program was:" >&5
16044 cat "conftest.$ac_ext" >&5
16045 ac_cv_type_signed_char=no
16047 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
16049 echo "$as_me:16049: result: $ac_cv_type_signed_char" >&5
16050 echo "${ECHO_T}$ac_cv_type_signed_char" >&6
16052 echo "$as_me:16052: checking size of signed char" >&5
16053 echo $ECHO_N "checking size of signed char... $ECHO_C" >&6
16054 if test "${ac_cv_sizeof_signed_char+set}" = set; then
16055 echo $ECHO_N "(cached) $ECHO_C" >&6
16057 if test "$ac_cv_type_signed_char" = yes; then
16058 if test "$cross_compiling" = yes; then
16059 # Depending upon the size, compute the lo and hi bounds.
16060 cat >"conftest.$ac_ext" <<_ACEOF
16061 #line 16061 "configure"
16062 #include "confdefs.h"
16063 $ac_includes_default
16067 int _array_ [1 - 2 * !((sizeof (signed char)) >= 0)]
16072 rm -f "conftest.$ac_objext"
16073 if { (eval echo "$as_me:16073: \"$ac_compile\"") >&5
16074 (eval $ac_compile) 2>&5
16076 echo "$as_me:16076: \$? = $ac_status" >&5
16077 (exit "$ac_status"); } &&
16078 { ac_try='test -s "conftest.$ac_objext"'
16079 { (eval echo "$as_me:16079: \"$ac_try\"") >&5
16080 (eval $ac_try) 2>&5
16082 echo "$as_me:16082: \$? = $ac_status" >&5
16083 (exit "$ac_status"); }; }; then
16086 cat >"conftest.$ac_ext" <<_ACEOF
16087 #line 16087 "configure"
16088 #include "confdefs.h"
16089 $ac_includes_default
16093 int _array_ [1 - 2 * !((sizeof (signed char)) <= $ac_mid)]
16098 rm -f "conftest.$ac_objext"
16099 if { (eval echo "$as_me:16099: \"$ac_compile\"") >&5
16100 (eval $ac_compile) 2>&5
16102 echo "$as_me:16102: \$? = $ac_status" >&5
16103 (exit "$ac_status"); } &&
16104 { ac_try='test -s "conftest.$ac_objext"'
16105 { (eval echo "$as_me:16105: \"$ac_try\"") >&5
16106 (eval $ac_try) 2>&5
16108 echo "$as_me:16108: \$? = $ac_status" >&5
16109 (exit "$ac_status"); }; }; then
16110 ac_hi=$ac_mid; break
16112 echo "$as_me: failed program was:" >&5
16113 cat "conftest.$ac_ext" >&5
16114 ac_lo=`expr "$ac_mid" + 1`; ac_mid=`expr 2 '*' "$ac_mid" + 1`
16116 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
16119 echo "$as_me: failed program was:" >&5
16120 cat "conftest.$ac_ext" >&5
16123 cat >"conftest.$ac_ext" <<_ACEOF
16124 #line 16124 "configure"
16125 #include "confdefs.h"
16126 $ac_includes_default
16130 int _array_ [1 - 2 * !((sizeof (signed char)) >= $ac_mid)]
16135 rm -f "conftest.$ac_objext"
16136 if { (eval echo "$as_me:16136: \"$ac_compile\"") >&5
16137 (eval $ac_compile) 2>&5
16139 echo "$as_me:16139: \$? = $ac_status" >&5
16140 (exit "$ac_status"); } &&
16141 { ac_try='test -s "conftest.$ac_objext"'
16142 { (eval echo "$as_me:16142: \"$ac_try\"") >&5
16143 (eval $ac_try) 2>&5
16145 echo "$as_me:16145: \$? = $ac_status" >&5
16146 (exit "$ac_status"); }; }; then
16147 ac_lo=$ac_mid; break
16149 echo "$as_me: failed program was:" >&5
16150 cat "conftest.$ac_ext" >&5
16151 ac_hi=`expr "$ac_mid" - 1`; ac_mid=`expr 2 '*' "$ac_mid"`
16153 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
16156 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
16157 # Binary search between lo and hi bounds.
16158 while test "x$ac_lo" != "x$ac_hi"; do
16159 ac_mid=`expr '(' "$ac_hi" - "$ac_lo" ')' / 2 + "$ac_lo"`
16160 cat >"conftest.$ac_ext" <<_ACEOF
16161 #line 16161 "configure"
16162 #include "confdefs.h"
16163 $ac_includes_default
16167 int _array_ [1 - 2 * !((sizeof (signed char)) <= $ac_mid)]
16172 rm -f "conftest.$ac_objext"
16173 if { (eval echo "$as_me:16173: \"$ac_compile\"") >&5
16174 (eval $ac_compile) 2>&5
16176 echo "$as_me:16176: \$? = $ac_status" >&5
16177 (exit "$ac_status"); } &&
16178 { ac_try='test -s "conftest.$ac_objext"'
16179 { (eval echo "$as_me:16179: \"$ac_try\"") >&5
16180 (eval $ac_try) 2>&5
16182 echo "$as_me:16182: \$? = $ac_status" >&5
16183 (exit "$ac_status"); }; }; then
16186 echo "$as_me: failed program was:" >&5
16187 cat "conftest.$ac_ext" >&5
16188 ac_lo=`expr "$ac_mid" + 1`
16190 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
16192 ac_cv_sizeof_signed_char=$ac_lo
16194 if test "$cross_compiling" = yes; then
16195 { { echo "$as_me:16195: error: cannot run test program while cross compiling" >&5
16196 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
16197 { (exit 1); exit 1; }; }
16199 cat >"conftest.$ac_ext" <<_ACEOF
16200 #line 16200 "configure"
16201 #include "confdefs.h"
16202 $ac_includes_default
16206 FILE *f = fopen ("conftest.val", "w");
16208 $ac_main_return (1);
16209 fprintf (f, "%ld", (long)(sizeof (signed char)));
16215 rm -f "conftest$ac_exeext"
16216 if { (eval echo "$as_me:16216: \"$ac_link\"") >&5
16217 (eval $ac_link) 2>&5
16219 echo "$as_me:16219: \$? = $ac_status" >&5
16220 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
16221 { (eval echo "$as_me:16221: \"$ac_try\"") >&5
16222 (eval $ac_try) 2>&5
16224 echo "$as_me:16224: \$? = $ac_status" >&5
16225 (exit "$ac_status"); }; }; then
16226 ac_cv_sizeof_signed_char=`cat conftest.val`
16228 echo "$as_me: program exited with status $ac_status" >&5
16229 echo "$as_me: failed program was:" >&5
16230 cat "conftest.$ac_ext" >&5
16232 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
16237 ac_cv_sizeof_signed_char=0
16240 echo "$as_me:16240: result: $ac_cv_sizeof_signed_char" >&5
16241 echo "${ECHO_T}$ac_cv_sizeof_signed_char" >&6
16242 cat >>confdefs.h <<EOF
16243 #define SIZEOF_SIGNED_CHAR $ac_cv_sizeof_signed_char
16246 echo "$as_me:16246: checking for ANSI C header files" >&5
16247 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
16248 if test "${ac_cv_header_stdc+set}" = set; then
16249 echo $ECHO_N "(cached) $ECHO_C" >&6
16251 cat >"conftest.$ac_ext" <<_ACEOF
16252 #line 16252 "configure"
16253 #include "confdefs.h"
16254 #include <stdlib.h>
16255 #include <stdarg.h>
16256 #include <string.h>
16260 if { (eval echo "$as_me:16260: \"$ac_cpp "conftest.$ac_ext"\"") >&5
16261 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
16263 $EGREP -v '^ *\+' conftest.er1 >conftest.err
16265 cat conftest.err >&5
16266 echo "$as_me:16266: \$? = $ac_status" >&5
16267 (exit "$ac_status"); } >/dev/null; then
16268 if test -s conftest.err; then
16269 ac_cpp_err=$ac_c_preproc_warn_flag
16276 if test -z "$ac_cpp_err"; then
16277 ac_cv_header_stdc=yes
16279 echo "$as_me: failed program was:" >&5
16280 cat "conftest.$ac_ext" >&5
16281 ac_cv_header_stdc=no
16283 rm -f conftest.err "conftest.$ac_ext"
16285 if test $ac_cv_header_stdc = yes; then
16286 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
16287 cat >"conftest.$ac_ext" <<_ACEOF
16288 #line 16288 "configure"
16289 #include "confdefs.h"
16290 #include <string.h>
16293 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
16294 $EGREP "memchr" >/dev/null 2>&1; then
16297 ac_cv_header_stdc=no
16303 if test $ac_cv_header_stdc = yes; then
16304 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
16305 cat >"conftest.$ac_ext" <<_ACEOF
16306 #line 16306 "configure"
16307 #include "confdefs.h"
16308 #include <stdlib.h>
16311 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
16312 $EGREP "free" >/dev/null 2>&1; then
16315 ac_cv_header_stdc=no
16321 if test $ac_cv_header_stdc = yes; then
16322 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
16323 if test "$cross_compiling" = yes; then
16326 cat >"conftest.$ac_ext" <<_ACEOF
16327 #line 16327 "configure"
16328 #include "confdefs.h"
16330 #if ((' ' & 0x0FF) == 0x020)
16331 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
16332 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
16334 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
16335 || ('j' <= (c) && (c) <= 'r') \
16336 || ('s' <= (c) && (c) <= 'z'))
16337 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
16340 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
16345 for (i = 0; i < 256; i++)
16346 if (XOR (islower (i), ISLOWER (i))
16347 || toupper (i) != TOUPPER (i))
16348 $ac_main_return(2);
16349 $ac_main_return (0);
16352 rm -f "conftest$ac_exeext"
16353 if { (eval echo "$as_me:16353: \"$ac_link\"") >&5
16354 (eval $ac_link) 2>&5
16356 echo "$as_me:16356: \$? = $ac_status" >&5
16357 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
16358 { (eval echo "$as_me:16358: \"$ac_try\"") >&5
16359 (eval $ac_try) 2>&5
16361 echo "$as_me:16361: \$? = $ac_status" >&5
16362 (exit "$ac_status"); }; }; then
16365 echo "$as_me: program exited with status $ac_status" >&5
16366 echo "$as_me: failed program was:" >&5
16367 cat "conftest.$ac_ext" >&5
16368 ac_cv_header_stdc=no
16370 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
16374 echo "$as_me:16374: result: $ac_cv_header_stdc" >&5
16375 echo "${ECHO_T}$ac_cv_header_stdc" >&6
16376 if test $ac_cv_header_stdc = yes; then
16378 cat >>confdefs.h <<\EOF
16379 #define STDC_HEADERS 1
16384 ac_header_dirent=no
16385 for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
16386 as_ac_Header=`echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
16387 echo "$as_me:16387: checking for $ac_hdr that defines DIR" >&5
16388 echo $ECHO_N "checking for $ac_hdr that defines DIR... $ECHO_C" >&6
16389 if eval "test \"\${$as_ac_Header+set}\" = set"; then
16390 echo $ECHO_N "(cached) $ECHO_C" >&6
16392 cat >"conftest.$ac_ext" <<_ACEOF
16393 #line 16393 "configure"
16394 #include "confdefs.h"
16395 #include <sys/types.h>
16407 rm -f "conftest.$ac_objext"
16408 if { (eval echo "$as_me:16408: \"$ac_compile\"") >&5
16409 (eval $ac_compile) 2>&5
16411 echo "$as_me:16411: \$? = $ac_status" >&5
16412 (exit "$ac_status"); } &&
16413 { ac_try='test -s "conftest.$ac_objext"'
16414 { (eval echo "$as_me:16414: \"$ac_try\"") >&5
16415 (eval $ac_try) 2>&5
16417 echo "$as_me:16417: \$? = $ac_status" >&5
16418 (exit "$ac_status"); }; }; then
16419 eval "$as_ac_Header=yes"
16421 echo "$as_me: failed program was:" >&5
16422 cat "conftest.$ac_ext" >&5
16423 eval "$as_ac_Header=no"
16425 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
16427 echo "$as_me:16427: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
16428 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
16429 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
16430 cat >>confdefs.h <<EOF
16431 #define `echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
16434 ac_header_dirent=$ac_hdr; break
16438 # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
16439 if test $ac_header_dirent = dirent.h; then
16440 echo "$as_me:16440: checking for opendir in -ldir" >&5
16441 echo $ECHO_N "checking for opendir in -ldir... $ECHO_C" >&6
16442 if test "${ac_cv_lib_dir_opendir+set}" = set; then
16443 echo $ECHO_N "(cached) $ECHO_C" >&6
16445 ac_check_lib_save_LIBS=$LIBS
16447 cat >"conftest.$ac_ext" <<_ACEOF
16448 #line 16448 "configure"
16449 #include "confdefs.h"
16451 /* Override any gcc2 internal prototype to avoid an error. */
16455 /* We use char because int might match the return type of a gcc2
16456 builtin and then its argument prototype would still apply. */
16466 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
16467 if { (eval echo "$as_me:16467: \"$ac_link\"") >&5
16468 (eval $ac_link) 2>&5
16470 echo "$as_me:16470: \$? = $ac_status" >&5
16471 (exit "$ac_status"); } &&
16472 { ac_try='test -s "conftest$ac_exeext"'
16473 { (eval echo "$as_me:16473: \"$ac_try\"") >&5
16474 (eval $ac_try) 2>&5
16476 echo "$as_me:16476: \$? = $ac_status" >&5
16477 (exit "$ac_status"); }; }; then
16478 ac_cv_lib_dir_opendir=yes
16480 echo "$as_me: failed program was:" >&5
16481 cat "conftest.$ac_ext" >&5
16482 ac_cv_lib_dir_opendir=no
16484 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
16485 LIBS=$ac_check_lib_save_LIBS
16487 echo "$as_me:16487: result: $ac_cv_lib_dir_opendir" >&5
16488 echo "${ECHO_T}$ac_cv_lib_dir_opendir" >&6
16489 if test "$ac_cv_lib_dir_opendir" = yes; then
16494 echo "$as_me:16494: checking for opendir in -lx" >&5
16495 echo $ECHO_N "checking for opendir in -lx... $ECHO_C" >&6
16496 if test "${ac_cv_lib_x_opendir+set}" = set; then
16497 echo $ECHO_N "(cached) $ECHO_C" >&6
16499 ac_check_lib_save_LIBS=$LIBS
16501 cat >"conftest.$ac_ext" <<_ACEOF
16502 #line 16502 "configure"
16503 #include "confdefs.h"
16505 /* Override any gcc2 internal prototype to avoid an error. */
16509 /* We use char because int might match the return type of a gcc2
16510 builtin and then its argument prototype would still apply. */
16520 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
16521 if { (eval echo "$as_me:16521: \"$ac_link\"") >&5
16522 (eval $ac_link) 2>&5
16524 echo "$as_me:16524: \$? = $ac_status" >&5
16525 (exit "$ac_status"); } &&
16526 { ac_try='test -s "conftest$ac_exeext"'
16527 { (eval echo "$as_me:16527: \"$ac_try\"") >&5
16528 (eval $ac_try) 2>&5
16530 echo "$as_me:16530: \$? = $ac_status" >&5
16531 (exit "$ac_status"); }; }; then
16532 ac_cv_lib_x_opendir=yes
16534 echo "$as_me: failed program was:" >&5
16535 cat "conftest.$ac_ext" >&5
16536 ac_cv_lib_x_opendir=no
16538 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
16539 LIBS=$ac_check_lib_save_LIBS
16541 echo "$as_me:16541: result: $ac_cv_lib_x_opendir" >&5
16542 echo "${ECHO_T}$ac_cv_lib_x_opendir" >&6
16543 if test "$ac_cv_lib_x_opendir" = yes; then
16549 echo "$as_me:16549: checking whether time.h and sys/time.h may both be included" >&5
16550 echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
16551 if test "${ac_cv_header_time+set}" = set; then
16552 echo $ECHO_N "(cached) $ECHO_C" >&6
16554 cat >"conftest.$ac_ext" <<_ACEOF
16555 #line 16555 "configure"
16556 #include "confdefs.h"
16557 #include <sys/types.h>
16558 #include <sys/time.h>
16564 if ((struct tm *) 0)
16570 rm -f "conftest.$ac_objext"
16571 if { (eval echo "$as_me:16571: \"$ac_compile\"") >&5
16572 (eval $ac_compile) 2>&5
16574 echo "$as_me:16574: \$? = $ac_status" >&5
16575 (exit "$ac_status"); } &&
16576 { ac_try='test -s "conftest.$ac_objext"'
16577 { (eval echo "$as_me:16577: \"$ac_try\"") >&5
16578 (eval $ac_try) 2>&5
16580 echo "$as_me:16580: \$? = $ac_status" >&5
16581 (exit "$ac_status"); }; }; then
16582 ac_cv_header_time=yes
16584 echo "$as_me: failed program was:" >&5
16585 cat "conftest.$ac_ext" >&5
16586 ac_cv_header_time=no
16588 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
16590 echo "$as_me:16590: result: $ac_cv_header_time" >&5
16591 echo "${ECHO_T}$ac_cv_header_time" >&6
16592 if test $ac_cv_header_time = yes; then
16594 cat >>confdefs.h <<\EOF
16595 #define TIME_WITH_SYS_TIME 1
16600 ### checks for compiler characteristics
16602 ac_cpp='$CPP $CPPFLAGS'
16603 ac_compile='$CC -c $CFLAGS $CPPFLAGS "conftest.$ac_ext" >&5'
16604 ac_link='$CC -o "conftest$ac_exeext" $CFLAGS $CPPFLAGS $LDFLAGS "conftest.$ac_ext" $LIBS >&5'
16605 ac_compiler_gnu=$ac_cv_c_compiler_gnu
16606 ac_main_return="return"
16608 echo "$as_me:16608: checking for an ANSI C-conforming const" >&5
16609 echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
16610 if test "${ac_cv_c_const+set}" = set; then
16611 echo $ECHO_N "(cached) $ECHO_C" >&6
16613 cat >"conftest.$ac_ext" <<_ACEOF
16614 #line 16614 "configure"
16615 #include "confdefs.h"
16620 /* FIXME: Include the comments suggested by Paul. */
16621 #ifndef __cplusplus
16622 /* Ultrix mips cc rejects this. */
16623 typedef int charset[2];
16625 /* SunOS 4.1.1 cc rejects this. */
16626 char const *const *ccp;
16628 /* NEC SVR4.0.2 mips cc rejects this. */
16629 struct point {int x, y;};
16630 static struct point const zero = {0,0};
16631 /* AIX XL C 1.02.0.0 rejects this.
16632 It does not let you subtract one const X* pointer from another in
16633 an arm of an if-expression whose if-part is not a constant
16635 const char *g = "string";
16636 ccp = &g + (g ? g-g : 0);
16637 /* HPUX 7.0 cc rejects these. */
16640 ccp = (char const *const *) p;
16641 { /* SCO 3.2v4 cc rejects this. */
16643 char const *s = 0 ? (char *) 0 : (char const *) 0;
16647 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
16648 int x[] = {25, 17};
16649 const int *foo = &x[0];
16652 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
16653 typedef const int *iptr;
16657 { /* AIX XL C 1.02.0.0 rejects this saying
16658 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
16659 struct s { int j; const int *ap[3]; };
16660 struct s *b; b->j = 5;
16662 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
16663 const int foo = 10;
16671 rm -f "conftest.$ac_objext"
16672 if { (eval echo "$as_me:16672: \"$ac_compile\"") >&5
16673 (eval $ac_compile) 2>&5
16675 echo "$as_me:16675: \$? = $ac_status" >&5
16676 (exit "$ac_status"); } &&
16677 { ac_try='test -s "conftest.$ac_objext"'
16678 { (eval echo "$as_me:16678: \"$ac_try\"") >&5
16679 (eval $ac_try) 2>&5
16681 echo "$as_me:16681: \$? = $ac_status" >&5
16682 (exit "$ac_status"); }; }; then
16685 echo "$as_me: failed program was:" >&5
16686 cat "conftest.$ac_ext" >&5
16689 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
16691 echo "$as_me:16691: result: $ac_cv_c_const" >&5
16692 echo "${ECHO_T}$ac_cv_c_const" >&6
16693 if test $ac_cv_c_const = no; then
16695 cat >>confdefs.h <<\EOF
16701 ### Checks for external-data
16703 echo "$as_me:16703: checking if data-only library module links" >&5
16704 echo $ECHO_N "checking if data-only library module links... $ECHO_C" >&6
16705 if test "${cf_cv_link_dataonly+set}" = set; then
16706 echo $ECHO_N "(cached) $ECHO_C" >&6
16710 cat >conftest.$ac_ext <<EOF
16711 #line 16711 "configure"
16712 int testdata[3] = { 123, 456, 789 };
16714 if { (eval echo "$as_me:16714: \"$ac_compile\"") >&5
16715 (eval $ac_compile) 2>&5
16717 echo "$as_me:16717: \$? = $ac_status" >&5
16718 (exit "$ac_status"); } ; then
16719 mv conftest.o data.o && \
16720 ( $AR $ARFLAGS conftest.a data.o ) 2>&5 1>/dev/null
16722 rm -f conftest.$ac_ext data.o
16723 cat >conftest.$ac_ext <<EOF
16724 #line 16724 "configure"
16728 ${cf_cv_main_return:-return}(1); /* I'm told this linker is broken */
16730 extern int testdata[3];
16731 return testdata[0] == 123
16732 && testdata[1] == 456
16733 && testdata[2] == 789;
16737 if { (eval echo "$as_me:16737: \"$ac_compile\"") >&5
16738 (eval $ac_compile) 2>&5
16740 echo "$as_me:16740: \$? = $ac_status" >&5
16741 (exit "$ac_status"); }; then
16742 mv conftest.o func.o && \
16743 ( $AR $ARFLAGS conftest.a func.o ) 2>&5 1>/dev/null
16745 rm -f conftest.$ac_ext func.o
16746 ( eval $RANLIB conftest.a ) 2>&5 >/dev/null
16747 cf_saveLIBS="$LIBS"
16748 LIBS="conftest.a $LIBS"
16749 if test "$cross_compiling" = yes; then
16750 cf_cv_link_dataonly=unknown
16752 cat >"conftest.$ac_ext" <<_ACEOF
16753 #line 16753 "configure"
16754 #include "confdefs.h"
16758 extern int testfunc();
16759 ${cf_cv_main_return:-return} (!testfunc());
16763 rm -f "conftest$ac_exeext"
16764 if { (eval echo "$as_me:16764: \"$ac_link\"") >&5
16765 (eval $ac_link) 2>&5
16767 echo "$as_me:16767: \$? = $ac_status" >&5
16768 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
16769 { (eval echo "$as_me:16769: \"$ac_try\"") >&5
16770 (eval $ac_try) 2>&5
16772 echo "$as_me:16772: \$? = $ac_status" >&5
16773 (exit "$ac_status"); }; }; then
16774 cf_cv_link_dataonly=yes
16776 echo "$as_me: program exited with status $ac_status" >&5
16777 echo "$as_me: failed program was:" >&5
16778 cat "conftest.$ac_ext" >&5
16779 cf_cv_link_dataonly=no
16781 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
16783 LIBS="$cf_saveLIBS"
16787 echo "$as_me:16787: result: $cf_cv_link_dataonly" >&5
16788 echo "${ECHO_T}$cf_cv_link_dataonly" >&6
16790 if test "$cf_cv_link_dataonly" = no ; then
16792 cat >>confdefs.h <<\EOF
16793 #define BROKEN_LINKER 1
16799 ### Checks for library functions.
16805 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
16806 echo "$as_me:16806: checking for $ac_header" >&5
16807 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
16808 if eval "test \"\${$as_ac_Header+set}\" = set"; then
16809 echo $ECHO_N "(cached) $ECHO_C" >&6
16811 cat >"conftest.$ac_ext" <<_ACEOF
16812 #line 16812 "configure"
16813 #include "confdefs.h"
16814 #include <$ac_header>
16816 if { (eval echo "$as_me:16816: \"$ac_cpp "conftest.$ac_ext"\"") >&5
16817 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
16819 $EGREP -v '^ *\+' conftest.er1 >conftest.err
16821 cat conftest.err >&5
16822 echo "$as_me:16822: \$? = $ac_status" >&5
16823 (exit "$ac_status"); } >/dev/null; then
16824 if test -s conftest.err; then
16825 ac_cpp_err=$ac_c_preproc_warn_flag
16832 if test -z "$ac_cpp_err"; then
16833 eval "$as_ac_Header=yes"
16835 echo "$as_me: failed program was:" >&5
16836 cat "conftest.$ac_ext" >&5
16837 eval "$as_ac_Header=no"
16839 rm -f conftest.err "conftest.$ac_ext"
16841 echo "$as_me:16841: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
16842 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
16843 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
16844 cat >>confdefs.h <<EOF
16845 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
16851 echo "$as_me:16851: checking for working mkstemp" >&5
16852 echo $ECHO_N "checking for working mkstemp... $ECHO_C" >&6
16853 if test "${cf_cv_func_mkstemp+set}" = set; then
16854 echo $ECHO_N "(cached) $ECHO_C" >&6
16858 if test "$cross_compiling" = yes; then
16859 cf_cv_func_mkstemp=maybe
16861 cat >"conftest.$ac_ext" <<_ACEOF
16862 #line 16862 "configure"
16863 #include "confdefs.h"
16865 #include <sys/types.h>
16866 #ifdef HAVE_UNISTD_H
16867 #include <unistd.h>
16869 #include <stdlib.h>
16871 #include <string.h>
16872 #include <sys/stat.h>
16875 char *tmpl = "conftestXXXXXX";
16883 for (n = 0; n < 2; ++n) {
16884 strcpy(name[n], tmpl);
16885 if ((fd = mkstemp(name[n])) >= 0) {
16886 if (!strcmp(name[n], tmpl)
16887 || stat(name[n], &sb) != 0
16888 || (sb.st_mode & S_IFMT) != S_IFREG
16889 || (sb.st_mode & 077) != 0) {
16896 && !strcmp(name[0], name[1]))
16898 ${cf_cv_main_return:-return}(result);
16902 rm -f "conftest$ac_exeext"
16903 if { (eval echo "$as_me:16903: \"$ac_link\"") >&5
16904 (eval $ac_link) 2>&5
16906 echo "$as_me:16906: \$? = $ac_status" >&5
16907 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
16908 { (eval echo "$as_me:16908: \"$ac_try\"") >&5
16909 (eval $ac_try) 2>&5
16911 echo "$as_me:16911: \$? = $ac_status" >&5
16912 (exit "$ac_status"); }; }; then
16913 cf_cv_func_mkstemp=yes
16916 echo "$as_me: program exited with status $ac_status" >&5
16917 echo "$as_me: failed program was:" >&5
16918 cat "conftest.$ac_ext" >&5
16919 cf_cv_func_mkstemp=no
16922 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
16926 echo "$as_me:16926: result: $cf_cv_func_mkstemp" >&5
16927 echo "${ECHO_T}$cf_cv_func_mkstemp" >&6
16928 if test "x$cf_cv_func_mkstemp" = xmaybe ; then
16929 echo "$as_me:16929: checking for mkstemp" >&5
16930 echo $ECHO_N "checking for mkstemp... $ECHO_C" >&6
16931 if test "${ac_cv_func_mkstemp+set}" = set; then
16932 echo $ECHO_N "(cached) $ECHO_C" >&6
16934 cat >"conftest.$ac_ext" <<_ACEOF
16935 #line 16935 "configure"
16936 #include "confdefs.h"
16937 #define mkstemp autoconf_temporary
16938 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
16945 /* We use char because int might match the return type of a gcc2
16946 builtin and then its argument prototype would still apply. */
16947 char mkstemp (void);
16953 /* The GNU C library defines stubs for functions which it implements
16954 to always fail with ENOSYS. Some functions are actually named
16955 something starting with __ and the normal name is an alias. */
16956 #if defined (__stub_mkstemp) || defined (__stub___mkstemp)
16957 #error found stub for mkstemp
16965 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
16966 if { (eval echo "$as_me:16966: \"$ac_link\"") >&5
16967 (eval $ac_link) 2>&5
16969 echo "$as_me:16969: \$? = $ac_status" >&5
16970 (exit "$ac_status"); } &&
16971 { ac_try='test -s "conftest$ac_exeext"'
16972 { (eval echo "$as_me:16972: \"$ac_try\"") >&5
16973 (eval $ac_try) 2>&5
16975 echo "$as_me:16975: \$? = $ac_status" >&5
16976 (exit "$ac_status"); }; }; then
16977 ac_cv_func_mkstemp=yes
16979 echo "$as_me: failed program was:" >&5
16980 cat "conftest.$ac_ext" >&5
16981 ac_cv_func_mkstemp=no
16983 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
16985 echo "$as_me:16985: result: $ac_cv_func_mkstemp" >&5
16986 echo "${ECHO_T}$ac_cv_func_mkstemp" >&6
16989 if test "x$cf_cv_func_mkstemp" = xyes || test "x$ac_cv_func_mkstemp" = xyes ; then
16991 cat >>confdefs.h <<\EOF
16992 #define HAVE_MKSTEMP 1
16997 if test -z "$cf_user_CFLAGS" && test "$with_no_leaks" = no ; then
16998 CFLAGS=`echo "${CFLAGS}" | sed -e 's%-g %%' -e 's%-g$%%' -e 's%[ ]% %g' -e 's% [ ]*% %g' -e 's%^ %%' -e 's% $%%'`
16999 CXXFLAGS=`echo "${CXXFLAGS}" | sed -e 's%-g %%' -e 's%-g$%%' -e 's%[ ]% %g' -e 's% [ ]*% %g' -e 's%^ %%' -e 's% $%%'`
17003 if test "$cf_with_ada" != "no" ; then
17005 for cf_prog_gnat in gnat gnatmake gprconfig gprbuild
17008 cf_upper_prog_gnat=`echo "${cf_prog_gnat}" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
17010 unset ac_cv_path_cf_TEMP_gnat
17012 # Extract the first word of "$cf_prog_gnat", so it can be a program name with args.
17013 set dummy $cf_prog_gnat; ac_word=$2
17014 echo "$as_me:17014: checking for $ac_word" >&5
17015 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
17016 if test "${ac_cv_path_cf_TEMP_gnat+set}" = set; then
17017 echo $ECHO_N "(cached) $ECHO_C" >&6
17019 case $cf_TEMP_gnat in
17021 ac_cv_path_cf_TEMP_gnat="$cf_TEMP_gnat" # Let the user override the test with a path.
17024 ac_save_IFS=$IFS; IFS=$ac_path_separator
17026 for ac_dir in $ac_dummy; do
17028 test -z "$ac_dir" && ac_dir=.
17029 if $as_executable_p "$ac_dir/$ac_word"; then
17030 ac_cv_path_cf_TEMP_gnat="$ac_dir/$ac_word"
17031 echo "$as_me:17031: found $ac_dir/$ac_word" >&5
17036 test -z "$ac_cv_path_cf_TEMP_gnat" && ac_cv_path_cf_TEMP_gnat="no"
17040 cf_TEMP_gnat=$ac_cv_path_cf_TEMP_gnat
17042 if test -n "$cf_TEMP_gnat"; then
17043 echo "$as_me:17043: result: $cf_TEMP_gnat" >&5
17044 echo "${ECHO_T}$cf_TEMP_gnat" >&6
17046 echo "$as_me:17046: result: no" >&5
17047 echo "${ECHO_T}no" >&6
17050 eval "cf_cv_PATH_$cf_upper_prog_gnat=$ac_cv_path_cf_TEMP_gnat"
17052 if test "x$cf_TEMP_gnat" != xno; then
17053 unset cf_cv_gnat_version
17056 echo "$as_me:17056: checking for $cf_prog_gnat version" >&5
17057 echo $ECHO_N "checking for $cf_prog_gnat version... $ECHO_C" >&6
17058 if test "${cf_cv_gnat_version+set}" = set; then
17059 echo $ECHO_N "(cached) $ECHO_C" >&6
17062 cf_cv_gnat_version=`$cf_prog_gnat --version 2>&1 | \
17063 grep '[0-9].[0-9][0-9]*' |\
17064 sed -e '2,$d' -e 's/[^0-9 \.]//g' -e 's/^[ ]*//' -e 's/ .*//'`
17067 echo "$as_me:17067: result: $cf_cv_gnat_version" >&5
17068 echo "${ECHO_T}$cf_cv_gnat_version" >&6
17069 test -z "$cf_cv_gnat_version" && cf_cv_gnat_version=no
17070 eval cf_TEMP_gnat=$cf_cv_gnat_version; unset cf_cv_gnat_version
17073 eval "cf_cv_VERSION_$cf_upper_prog_gnat=$cf_TEMP_gnat"
17076 unset cf_cv_gnat_version
17077 unset ac_cv_path_cf_TEMP_gnat
17080 if test "x$cf_cv_VERSION_GNATMAKE" = "xno"; then
17082 cf_cv_prog_gnat_correct=no
17084 cf_ada_make=gnatmake
17085 if test "x$cf_cv_VERSION_GPRCONFIG" = "xno"; then
17086 # gprconfig is newer than gnatmake; we can continue...
17089 rm -rf ./conftest* ./*~conftest*
17090 if mkdir conftest.src
17094 for cf_gprconfig in Ada C
17096 echo "$as_me:17096: checking for gprconfig name for $cf_gprconfig" >&5
17097 echo $ECHO_N "checking for gprconfig name for $cf_gprconfig... $ECHO_C" >&6
17098 if test "$cf_gprconfig" = C
17100 for cf_gprconfig_param in \
17101 "$cf_gprconfig,,,,GNATGCC" \
17102 "$cf_gprconfig,,,,GCC" \
17105 cf_gprconfig_value=`echo s| gprconfig --config=$cf_gprconfig_param 2>&5 | ${AWK:-awk} '/^\*/{print $3;}' | head -n 1`
17106 test -n "$cf_gprconfig_value" && break
17109 cf_gprconfig_param=$cf_gprconfig
17110 cf_gprconfig_value=`echo s| gprconfig --config=$cf_gprconfig_param 2>&5 | ${AWK:-awk} '/^\*/{print $3;}' | head -n 1`
17112 if test -n "$cf_gprconfig_value"
17114 eval "cf_ada_config_$cf_gprconfig=$cf_gprconfig_value"
17115 echo "$as_me:17115: result: $cf_gprconfig_value" >&5
17116 echo "${ECHO_T}$cf_gprconfig_value" >&6
17118 echo "$as_me:17118: result: missing" >&5
17119 echo "${ECHO_T}missing" >&6
17125 rm -rf ./conftest* ./*~conftest*
17128 if test "x$cf_ada_config" != "x#"
17131 echo "$as_me:17131: checking for gnat version" >&5
17132 echo $ECHO_N "checking for gnat version... $ECHO_C" >&6
17133 if test "${cf_cv_gnat_version+set}" = set; then
17134 echo $ECHO_N "(cached) $ECHO_C" >&6
17137 cf_cv_gnat_version=`${cf_ada_make:-gnatmake} --version 2>&1 | \
17138 grep '[0-9].[0-9][0-9]*' |\
17139 sed -e '2,$d' -e 's/[^0-9 \.]//g' -e 's/^[ ]*//' -e 's/ .*//'`
17142 echo "$as_me:17142: result: $cf_cv_gnat_version" >&5
17143 echo "${ECHO_T}$cf_cv_gnat_version" >&6
17144 test -z "$cf_cv_gnat_version" && cf_cv_gnat_version=no
17146 case "$cf_cv_gnat_version" in
17147 (3.1[1-9]*|3.[2-9]*|[4-9].*|[1-9][0-9].[0-9]*|20[0-9][0-9])
17148 cf_cv_prog_gnat_correct=yes
17151 { echo "$as_me:17151: WARNING: Unsupported GNAT version $cf_cv_gnat_version. We require 3.11 or better. Disabling Ada95 binding." >&5
17152 echo "$as_me: WARNING: Unsupported GNAT version $cf_cv_gnat_version. We require 3.11 or better. Disabling Ada95 binding." >&2;}
17153 cf_cv_prog_gnat_correct=no
17157 # Extract the first word of "m4", so it can be a program name with args.
17158 set dummy m4; ac_word=$2
17159 echo "$as_me:17159: checking for $ac_word" >&5
17160 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
17161 if test "${ac_cv_prog_M4_exists+set}" = set; then
17162 echo $ECHO_N "(cached) $ECHO_C" >&6
17164 if test -n "$M4_exists"; then
17165 ac_cv_prog_M4_exists="$M4_exists" # Let the user override the test.
17167 ac_save_IFS=$IFS; IFS=$ac_path_separator
17169 for ac_dir in $ac_dummy; do
17171 test -z "$ac_dir" && ac_dir=.
17172 $as_executable_p "$ac_dir/$ac_word" || continue
17173 ac_cv_prog_M4_exists="yes"
17174 echo "$as_me:17174: found $ac_dir/$ac_word" >&5
17178 test -z "$ac_cv_prog_M4_exists" && ac_cv_prog_M4_exists="no"
17181 M4_exists=$ac_cv_prog_M4_exists
17182 if test -n "$M4_exists"; then
17183 echo "$as_me:17183: result: $M4_exists" >&5
17184 echo "${ECHO_T}$M4_exists" >&6
17186 echo "$as_me:17186: result: no" >&5
17187 echo "${ECHO_T}no" >&6
17190 if test "$ac_cv_prog_M4_exists" = no; then
17191 cf_cv_prog_gnat_correct=no
17192 { echo "$as_me:17192: WARNING: Ada95 binding required program m4 not found. Ada95 binding disabled" >&5
17193 echo "$as_me: WARNING: Ada95 binding required program m4 not found. Ada95 binding disabled" >&2;}
17195 if test "$cf_cv_prog_gnat_correct" = yes; then
17196 echo "$as_me:17196: checking if GNAT works" >&5
17197 echo $ECHO_N "checking if GNAT works... $ECHO_C" >&6
17199 rm -rf ./conftest* ./*~conftest*
17200 cat >>conftest.ads <<CF_EOF
17201 procedure conftest;
17203 cat >>conftest.adb <<CF_EOF
17206 procedure conftest is
17208 Text_IO.Put ("Hello World");
17210 GNAT.OS_Lib.OS_Exit (0);
17213 if ( "$cf_ada_make" $ADAFLAGS conftest 1>&5 2>&1 ) ; then
17214 if ( ./conftest 1>&5 2>&1 ) ; then
17215 cf_cv_prog_gnat_correct=yes
17217 cf_cv_prog_gnat_correct=no
17220 cf_cv_prog_gnat_correct=no
17222 rm -rf ./conftest* ./*~conftest*
17224 echo "$as_me:17224: result: $cf_cv_prog_gnat_correct" >&5
17225 echo "${ECHO_T}$cf_cv_prog_gnat_correct" >&6
17228 cf_cv_prog_gnat_correct=no
17232 if test "$cf_cv_prog_gnat_correct" = yes; then
17234 echo "$as_me:17234: checking optimization options for ADAFLAGS" >&5
17235 echo $ECHO_N "checking optimization options for ADAFLAGS... $ECHO_C" >&6
17239 ADAFLAGS="$ADAFLAGS -g"
17245 cf_O_flag=`echo "$CFLAGS" |sed -e 's/^.*-O/-O/' -e 's/[ ].*//'`
17247 ADAFLAGS="$ADAFLAGS $cf_O_flag"
17251 echo "$as_me:17251: result: $ADAFLAGS" >&5
17252 echo "${ECHO_T}$ADAFLAGS" >&6
17254 echo "$as_me:17254: checking if GNATPREP supports -T option" >&5
17255 echo $ECHO_N "checking if GNATPREP supports -T option... $ECHO_C" >&6
17256 if test "${cf_cv_gnatprep_opt_t+set}" = set; then
17257 echo $ECHO_N "(cached) $ECHO_C" >&6
17260 cf_cv_gnatprep_opt_t=no
17261 gnatprep -T 2>/dev/null >/dev/null && cf_cv_gnatprep_opt_t=yes
17264 echo "$as_me:17264: result: $cf_cv_gnatprep_opt_t" >&5
17265 echo "${ECHO_T}$cf_cv_gnatprep_opt_t" >&6
17266 test "$cf_cv_gnatprep_opt_t" = yes && GNATPREP_OPTS="-T $GNATPREP_OPTS"
17268 echo "$as_me:17268: checking if GNAT supports generics" >&5
17269 echo $ECHO_N "checking if GNAT supports generics... $ECHO_C" >&6
17270 case "$cf_cv_gnat_version" in
17271 (3.1[1-9]*|3.[2-9]*|[4-9].*|[1-9][0-9].[0-9]*|20[0-9][0-9])
17272 cf_gnat_generics=yes
17275 cf_gnat_generics=no
17278 echo "$as_me:17278: result: $cf_gnat_generics" >&5
17279 echo "${ECHO_T}$cf_gnat_generics" >&6
17281 if test "$cf_gnat_generics" = yes
17283 cf_compile_generics=generics
17284 cf_generic_objects="\${GENOBJS}"
17286 cf_compile_generics=
17287 cf_generic_objects=
17290 echo "$as_me:17290: checking if GNAT supports SIGINT" >&5
17291 echo $ECHO_N "checking if GNAT supports SIGINT... $ECHO_C" >&6
17292 if test "${cf_cv_gnat_sigint+set}" = set; then
17293 echo $ECHO_N "(cached) $ECHO_C" >&6
17296 rm -rf ./conftest* ./*~conftest*
17297 cat >>conftest.ads <<CF_EOF
17298 with Ada.Interrupts.Names;
17300 package ConfTest is
17302 pragma Warnings (Off); -- the next pragma exists since 3.11p
17303 pragma Unreserve_All_Interrupts;
17304 pragma Warnings (On);
17306 protected Process is
17308 function Continue return Boolean;
17309 pragma Attach_Handler (Stop, Ada.Interrupts.Names.SIGINT);
17311 Done : Boolean := False;
17316 cat >>conftest.adb <<CF_EOF
17317 package body ConfTest is
17318 protected body Process is
17323 function Continue return Boolean is
17330 if ( "$cf_ada_make" $ADAFLAGS conftest 1>&5 2>&1 ) ; then
17331 cf_cv_gnat_sigint=yes
17333 cf_cv_gnat_sigint=no
17335 rm -rf ./conftest* ./*~conftest*
17338 echo "$as_me:17338: result: $cf_cv_gnat_sigint" >&5
17339 echo "${ECHO_T}$cf_cv_gnat_sigint" >&6
17341 if test "$cf_cv_gnat_sigint" = yes ; then
17344 USE_GNAT_SIGINT="#"
17347 cf_gnat_libraries=no
17348 cf_gnat_projects=no
17350 if test "$enable_gnat_projects" != no ; then
17351 echo "$as_me:17351: checking if GNAT supports project files" >&5
17352 echo $ECHO_N "checking if GNAT supports project files... $ECHO_C" >&6
17353 case "$cf_cv_gnat_version" in
17357 case "$cf_cv_system_name" in
17361 rm -rf ./conftest* ./*~conftest*
17362 if mkdir conftest.src conftest.bin conftest.lib
17365 rm -rf ./conftest* ./*~conftest*
17366 cat >>library.gpr <<CF_EOF
17368 Kind := External ("LIB_KIND");
17369 for Library_Name use "ConfTest";
17370 for Object_Dir use ".";
17371 for Library_ALI_Dir use External("LIBRARY_DIR");
17372 for Library_Version use External ("SONAME");
17373 for Library_Kind use Kind;
17374 for Library_Dir use External("BUILD_DIR");
17375 Source_Dir := External ("SOURCE_DIR");
17376 for Source_Dirs use (Source_Dir);
17379 cat >>confpackage.ads <<CF_EOF
17380 package ConfPackage is
17381 procedure conftest;
17384 cat >>confpackage.adb <<CF_EOF
17386 package body ConfPackage is
17387 procedure conftest is
17389 Text_IO.Put ("Hello World");
17394 if ( "$cf_ada_make" $ADAFLAGS \
17396 -XBUILD_DIR="`cd ../conftest.bin;pwd`" \
17397 -XLIBRARY_DIR="`cd ../conftest.lib;pwd`" \
17398 -XSOURCE_DIR="`pwd`" \
17399 -XSONAME=libConfTest.so.1 \
17400 -XLIB_KIND=static 1>&5 2>&1 ) ; then
17401 cf_gnat_projects=yes
17405 if test -f conftest.lib/confpackage.ali
17407 cf_gnat_libraries=yes
17409 rm -rf ./conftest* ./*~conftest*
17414 echo "$as_me:17414: result: $cf_gnat_projects" >&5
17415 echo "${ECHO_T}$cf_gnat_projects" >&6
17416 fi # enable_gnat_projects
17418 if test "$cf_gnat_projects" = yes
17420 echo "$as_me:17420: checking if GNAT supports libraries" >&5
17421 echo $ECHO_N "checking if GNAT supports libraries... $ECHO_C" >&6
17422 echo "$as_me:17422: result: $cf_gnat_libraries" >&5
17423 echo "${ECHO_T}$cf_gnat_libraries" >&6
17426 USE_OLD_MAKERULES=""
17427 USE_GNAT_PROJECTS="#"
17428 USE_GNAT_MAKE_GPR="#"
17429 USE_GNAT_GPRBUILD="#"
17431 if test "$cf_gnat_projects" = yes
17433 USE_OLD_MAKERULES="#"
17434 USE_GNAT_PROJECTS=""
17435 if test "$cf_cv_VERSION_GPRBUILD" != no
17437 USE_GNAT_GPRBUILD=""
17438 elif test "$cf_cv_VERSION_GNATMAKE" != no
17440 USE_GNAT_MAKE_GPR=""
17442 { echo "$as_me:17442: WARNING: use old makefile rules since tools are missing" >&5
17443 echo "$as_me: WARNING: use old makefile rules since tools are missing" >&2;}
17447 if test "$cf_gnat_libraries" = yes
17449 USE_GNAT_LIBRARIES=""
17451 USE_GNAT_LIBRARIES="#"
17454 echo "$as_me:17454: checking for ada-compiler" >&5
17455 echo $ECHO_N "checking for ada-compiler... $ECHO_C" >&6
17457 # Check whether --with-ada-compiler or --without-ada-compiler was given.
17458 if test "${with_ada_compiler+set}" = set; then
17459 withval="$with_ada_compiler"
17460 cf_ada_compiler=$withval
17462 cf_ada_compiler=gnatmake
17465 echo "$as_me:17465: result: $cf_ada_compiler" >&5
17466 echo "${ECHO_T}$cf_ada_compiler" >&6
17468 cf_ada_package=terminal_interface
17470 echo "$as_me:17470: checking for ada-include" >&5
17471 echo $ECHO_N "checking for ada-include... $ECHO_C" >&6
17473 # Check whether --with-ada-include or --without-ada-include was given.
17474 if test "${with_ada_include+set}" = set; then
17475 withval="$with_ada_include"
17478 withval="${ADA_INCLUDE:-$prefix/share/ada/adainclude}"
17479 fi; if test -n "$prefix/share/ada/adainclude" ; then
17481 if test "x$prefix" != xNONE; then
17482 cf_path_syntax="$prefix"
17484 cf_path_syntax="$ac_default_prefix"
17487 case ".$withval" in
17488 (.\$\(*\)*|.\'*\'*)
17492 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
17494 (.\$\{*prefix\}*|.\$\{*dir\}*)
17495 eval withval="$withval"
17496 case ".$withval" in
17498 withval=`echo "$withval" | sed -e s%NONE%$cf_path_syntax%`
17503 withval=`echo "$withval" | sed -e s%NONE%$cf_path_syntax%`
17506 { { echo "$as_me:17506: error: expected a pathname, not \"$withval\"" >&5
17507 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
17508 { (exit 1); exit 1; }; }
17513 eval ADA_INCLUDE="$withval"
17515 echo "$as_me:17515: result: $ADA_INCLUDE" >&5
17516 echo "${ECHO_T}$ADA_INCLUDE" >&6
17518 echo "$as_me:17518: checking for ada-objects" >&5
17519 echo $ECHO_N "checking for ada-objects... $ECHO_C" >&6
17521 # Check whether --with-ada-objects or --without-ada-objects was given.
17522 if test "${with_ada_objects+set}" = set; then
17523 withval="$with_ada_objects"
17526 withval="${ADA_OBJECTS:-$prefix/lib/ada/adalib}"
17527 fi; if test -n "$prefix/lib/ada/adalib" ; then
17529 if test "x$prefix" != xNONE; then
17530 cf_path_syntax="$prefix"
17532 cf_path_syntax="$ac_default_prefix"
17535 case ".$withval" in
17536 (.\$\(*\)*|.\'*\'*)
17540 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
17542 (.\$\{*prefix\}*|.\$\{*dir\}*)
17543 eval withval="$withval"
17544 case ".$withval" in
17546 withval=`echo "$withval" | sed -e s%NONE%$cf_path_syntax%`
17551 withval=`echo "$withval" | sed -e s%NONE%$cf_path_syntax%`
17554 { { echo "$as_me:17554: error: expected a pathname, not \"$withval\"" >&5
17555 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
17556 { (exit 1); exit 1; }; }
17561 eval ADA_OBJECTS="$withval"
17563 echo "$as_me:17563: result: $ADA_OBJECTS" >&5
17564 echo "${ECHO_T}$ADA_OBJECTS" >&6
17566 echo "$as_me:17566: checking if an Ada95 shared-library should be built" >&5
17567 echo $ECHO_N "checking if an Ada95 shared-library should be built... $ECHO_C" >&6
17569 # Check whether --with-ada-sharedlib or --without-ada-sharedlib was given.
17570 if test "${with_ada_sharedlib+set}" = set; then
17571 withval="$with_ada_sharedlib"
17572 with_ada_sharedlib=$withval
17574 with_ada_sharedlib=no
17576 echo "$as_me:17576: result: $with_ada_sharedlib" >&5
17577 echo "${ECHO_T}$with_ada_sharedlib" >&6
17579 if test "x$with_ada_sharedlib" != xno
17581 if test "x$cf_gnat_projects" != xyes
17583 { echo "$as_me:17583: WARNING: disabling shared-library since GNAT projects are not supported" >&5
17584 echo "$as_me: WARNING: disabling shared-library since GNAT projects are not supported" >&2;}
17585 with_ada_sharedlib=no
17589 ADA_SHAREDLIB='lib$(LIB_NAME).so.1'
17590 MAKE_ADA_SHAREDLIB="#"
17592 if test "x$with_ada_sharedlib" != xno
17594 MAKE_ADA_SHAREDLIB=
17595 if test "x$with_ada_sharedlib" != xyes
17597 ADA_SHAREDLIB="$with_ada_sharedlib"
17601 # allow the Ada binding to be renamed
17603 echo "$as_me:17603: checking for ada-libname" >&5
17604 echo $ECHO_N "checking for ada-libname... $ECHO_C" >&6
17606 # Check whether --with-ada-libname or --without-ada-libname was given.
17607 if test "${with_ada_libname+set}" = set; then
17608 withval="$with_ada_libname"
17609 ADA_LIBNAME=$withval
17611 ADA_LIBNAME=AdaCurses
17613 case "x$ADA_LIBNAME" in
17615 ADA_LIBNAME=AdaCurses
17619 echo "$as_me:17619: result: $ADA_LIBNAME" >&5
17620 echo "${ECHO_T}$ADA_LIBNAME" >&6
17623 { { echo "$as_me:17623: error: No usable Ada compiler found" >&5
17624 echo "$as_me: error: No usable Ada compiler found" >&2;}
17625 { (exit 1); exit 1; }; }
17628 { { echo "$as_me:17628: error: The Ada compiler is needed for this package" >&5
17629 echo "$as_me: error: The Ada compiler is needed for this package" >&2;}
17630 { (exit 1); exit 1; }; }
17633 ################################################################################
17640 ### Construct the list of include-directories to be generated
17642 if test "$srcdir" != "."; then
17643 CPPFLAGS="-I\${srcdir}/../include $CPPFLAGS"
17645 CPPFLAGS="-I../include $CPPFLAGS"
17646 if test "$srcdir" != "."; then
17647 CPPFLAGS="-I\${srcdir} $CPPFLAGS"
17649 CPPFLAGS="-I. $CPPFLAGS"
17651 ACPPFLAGS="-I. -I../include -I../../include $ACPPFLAGS"
17652 if test "$srcdir" != "."; then
17653 ACPPFLAGS="-I\${srcdir}/../../include $ACPPFLAGS"
17655 if test "$GCC" != yes; then
17656 ACPPFLAGS="$ACPPFLAGS -I\${includedir}"
17657 elif test "$includedir" != "/usr/include"; then
17658 if test "$includedir" = '${prefix}/include' ; then
17659 if test x$prefix != x/usr ; then
17660 ACPPFLAGS="$ACPPFLAGS -I\${includedir}"
17663 ACPPFLAGS="$ACPPFLAGS -I\${includedir}"
17667 ### Build up pieces for makefile rules
17668 echo "$as_me:17668: checking default library suffix" >&5
17669 echo $ECHO_N "checking default library suffix... $ECHO_C" >&6
17671 case $DFT_LWR_MODEL in
17672 (libtool) DFT_ARG_SUFFIX='' ;;
17673 (normal) DFT_ARG_SUFFIX='' ;;
17674 (debug) DFT_ARG_SUFFIX='_g' ;;
17675 (profile) DFT_ARG_SUFFIX='_p' ;;
17676 (shared) DFT_ARG_SUFFIX='' ;;
17678 test -n "$LIB_SUFFIX" && DFT_ARG_SUFFIX="${LIB_SUFFIX}${DFT_ARG_SUFFIX}"
17679 echo "$as_me:17679: result: $DFT_ARG_SUFFIX" >&5
17680 echo "${ECHO_T}$DFT_ARG_SUFFIX" >&6
17682 echo "$as_me:17682: checking default library-dependency suffix" >&5
17683 echo $ECHO_N "checking default library-dependency suffix... $ECHO_C" >&6
17685 case X$DFT_LWR_MODEL in
17687 DFT_LIB_SUFFIX='.la'
17688 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
17691 case "$cf_cv_system_name" in
17693 DFT_LIB_SUFFIX='_g.lib'
17696 DFT_LIB_SUFFIX='_g.a'
17699 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
17702 case "$cf_cv_system_name" in
17704 DFT_LIB_SUFFIX='_p.lib'
17707 DFT_LIB_SUFFIX='_p.a'
17710 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
17713 case "$cf_cv_system_name" in
17715 DFT_LIB_SUFFIX='.so'
17716 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
17719 DFT_LIB_SUFFIX='.dll'
17720 DFT_DEP_SUFFIX='.dll.lib'
17722 (cygwin*|msys*|mingw*)
17723 DFT_LIB_SUFFIX='.dll'
17724 DFT_DEP_SUFFIX='.dll.a'
17727 DFT_LIB_SUFFIX='.dylib'
17728 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
17733 DFT_LIB_SUFFIX='.so'
17734 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
17737 DFT_LIB_SUFFIX='.sl'
17738 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
17743 DFT_LIB_SUFFIX='.so'
17744 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
17751 DFT_LIB_SUFFIX='.lib'
17754 DFT_LIB_SUFFIX='.a'
17757 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
17760 if test -n "${LIB_SUFFIX}${EXTRA_SUFFIX}"
17762 DFT_LIB_SUFFIX="${LIB_SUFFIX}${EXTRA_SUFFIX}${DFT_LIB_SUFFIX}"
17763 DFT_DEP_SUFFIX="${LIB_SUFFIX}${EXTRA_SUFFIX}${DFT_DEP_SUFFIX}"
17765 echo "$as_me:17765: result: $DFT_DEP_SUFFIX" >&5
17766 echo "${ECHO_T}$DFT_DEP_SUFFIX" >&6
17768 echo "$as_me:17768: checking default object directory" >&5
17769 echo $ECHO_N "checking default object directory... $ECHO_C" >&6
17771 case $DFT_LWR_MODEL in
17772 (libtool) DFT_OBJ_SUBDIR='obj_lo' ;;
17773 (normal) DFT_OBJ_SUBDIR='objects' ;;
17774 (debug) DFT_OBJ_SUBDIR='obj_g' ;;
17775 (profile) DFT_OBJ_SUBDIR='obj_p' ;;
17777 case "$cf_cv_system_name" in
17779 DFT_OBJ_SUBDIR='objects' ;;
17781 DFT_OBJ_SUBDIR='obj_s' ;;
17784 echo "$as_me:17784: result: $DFT_OBJ_SUBDIR" >&5
17785 echo "${ECHO_T}$DFT_OBJ_SUBDIR" >&6
17787 ### Set up low-level terminfo dependencies for makefiles.
17789 if test "$DFT_LWR_MODEL" = shared ; then
17790 case $cf_cv_system_name in
17792 # "lib" files have ".dll.a" suffix, "cyg" files have ".dll"
17795 # "lib" files have ".dll.a" suffix, "msys-" files have ".dll"
17800 USE_ARG_SUFFIX=${DFT_ARG_SUFFIX}
17802 USE_LIB_SUFFIX=${DFT_ARG_SUFFIX}
17804 USE_CFG_SUFFIX=${DFT_ARG_SUFFIX}
17806 ### Construct the list of subdirectories for which we'll customize makefiles
17807 ### with the appropriate compile-rules.
17809 SUB_MAKEFILES="gen/adacurses${USE_ARG_SUFFIX}-config:gen/adacurses-config.in"
17811 cat >>confdefs.h <<EOF
17812 #define NCURSES_PATHSEP '$PATH_SEPARATOR'
17815 ################################################################################
17821 NCURSES_SHLIB2="sh -c"
17823 ADA_SUBDIRS="include gen src doc"
17824 if test "x$cf_with_tests" != "xno" ; then
17825 ADA_SUBDIRS="$ADA_SUBDIRS samples"
17827 for cf_dir in $ADA_SUBDIRS
17829 SUB_MAKEFILES="$SUB_MAKEFILES $cf_dir/Makefile"
17836 # match layout used by make-tar.sh
17837 ADAHTML_DIR=../doc/ada
17839 if test "x$cross_compiling" = xyes ; then
17840 ADAGEN_LDFLAGS='$(CROSS_LDFLAGS)'
17842 ADAGEN_LDFLAGS='$(NATIVE_LDFLAGS)'
17845 ac_config_files="$ac_config_files $SUB_MAKEFILES src/library.gpr:src/library.gpr.in doc/adacurses${DFT_ARG_SUFFIX}-config.1:doc/MKada_config.in Makefile"
17846 ac_config_commands="$ac_config_commands default"
17847 cat >confcache <<\_ACEOF
17848 # This file is a shell script that caches the results of configure
17849 # tests run on this system so they can be shared between configure
17850 # scripts and configure runs, see configure's option --config-cache.
17851 # It is not useful on other systems. If it contains results you don't
17852 # want to keep, you may remove or edit it.
17854 # config.status only pays attention to the cache file if you give it
17855 # the --recheck option to rerun configure.
17857 # `ac_cv_env_foo' variables (set or unset) will be overriden when
17858 # loading this file, other *unset* `ac_cv_foo' will be assigned the
17859 # following values.
17863 # The following way of writing the cache mishandles newlines in values,
17864 # but we know of no workaround that is simple, portable, and efficient.
17865 # So, don't put newlines in cache variables' values.
17866 # Ultrix sh set writes to stderr and can't be redirected directly,
17867 # and sets the high bit in the cache file unless we assign to the vars.
17870 case `(ac_space=' '; set | grep ac_space) 2>&1` in
17872 # `set' does not quote correctly, so add quotes (double-quote
17873 # substitution turns \\\\ into \\, and sed turns \\ into \).
17876 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
17879 # `set' quotes correctly as required by POSIX, so do not add quotes.
17881 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
17888 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
17890 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
17892 if cmp -s $cache_file confcache; then :; else
17893 if test -w $cache_file; then
17894 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
17895 cat confcache >$cache_file
17897 echo "not updating unwritable cache $cache_file"
17902 test "x$prefix" = xNONE && prefix=$ac_default_prefix
17903 # Let make expand exec_prefix.
17904 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
17906 # VPATH may cause trouble with some makes, so we remove $(srcdir),
17907 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
17908 # trailing colons and then remove the whole line if VPATH becomes empty
17909 # (actually we leave an empty line to preserve line numbers).
17910 if test "x$srcdir" = x.; then
17911 ac_vpsub='/^[ ]*VPATH[ ]*=/{
17912 s/:*\$(srcdir):*/:/;
17913 s/:*\${srcdir}:*/:/;
17915 s/^\([^=]*=[ ]*\):*/\1/;
17921 DEFS=-DHAVE_CONFIG_H
17923 : "${CONFIG_STATUS=./config.status}"
17924 ac_clean_files_save=$ac_clean_files
17925 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
17926 { echo "$as_me:17926: creating $CONFIG_STATUS" >&5
17927 echo "$as_me: creating $CONFIG_STATUS" >&6;}
17928 cat >"$CONFIG_STATUS" <<_ACEOF
17930 # Generated automatically by configure.
17931 # Run this file to recreate the current configuration.
17932 # Compiler output produced by configure, useful for debugging
17933 # configure, is in config.log if it exists.
17936 SHELL=\${CONFIG_SHELL-$SHELL}
17937 ac_cs_invocation="\$0 \$@"
17939 CLICOLOR_FORCE= GREP_OPTIONS=
17940 unset CLICOLOR_FORCE GREP_OPTIONS
17943 cat >>"$CONFIG_STATUS" <<\_ACEOF
17944 # Be Bourne compatible
17945 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
17948 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
17952 # Name of the executable.
17953 as_me=`echo "$0" |sed 's,.*[\\/],,'`
17955 if expr a : '\(a\)' >/dev/null 2>&1; then
17961 rm -f conf$$ conf$$.exe conf$$.file
17963 if ln -s conf$$.file conf$$ 2>/dev/null; then
17964 # We could just check for DJGPP; but this test a) works b) is more generic
17965 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
17966 if test -f conf$$.exe; then
17967 # Don't use ln at all; we don't have any links
17972 elif ln conf$$.file conf$$ 2>/dev/null; then
17977 rm -f conf$$ conf$$.exe conf$$.file
17979 as_executable_p="test -f"
17981 # Support unset when possible.
17982 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
17989 $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
17990 $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
17991 $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
17992 $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
17993 $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
17994 $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
17995 $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
17996 $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
17999 # We need space, tab and new line, in precisely that order.
18005 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
18011 # Files that config.status was made for.
18012 if test -n "$ac_config_files"; then
18013 echo "config_files=\"$ac_config_files\"" >>"$CONFIG_STATUS"
18016 if test -n "$ac_config_headers"; then
18017 echo "config_headers=\"$ac_config_headers\"" >>"$CONFIG_STATUS"
18020 if test -n "$ac_config_links"; then
18021 echo "config_links=\"$ac_config_links\"" >>"$CONFIG_STATUS"
18024 if test -n "$ac_config_commands"; then
18025 echo "config_commands=\"$ac_config_commands\"" >>"$CONFIG_STATUS"
18028 cat >>"$CONFIG_STATUS" <<\EOF
18031 \`$as_me' instantiates files from templates according to the
18032 current configuration.
18034 Usage: $0 [OPTIONS] [FILE]...
18036 -h, --help print this help, then exit
18037 -V, --version print version number, then exit
18038 -d, --debug don't remove temporary files
18039 --recheck update $as_me by reconfiguring in the same conditions
18040 --file=FILE[:TEMPLATE]
18041 instantiate the configuration file FILE
18042 --header=FILE[:TEMPLATE]
18043 instantiate the configuration header FILE
18045 Configuration files:
18048 Configuration headers:
18051 Configuration commands:
18054 Report bugs to <dickey@invisible-island.net>."
18057 cat >>"$CONFIG_STATUS" <<EOF
18060 configured by $0, generated by GNU Autoconf 2.52.20210509,
18061 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
18063 Copyright 2003-2020,2021 Thomas E. Dickey
18064 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
18065 Free Software Foundation, Inc.
18066 This config.status script is free software; the Free Software Foundation
18067 gives unlimited permission to copy, distribute and modify it."
18072 cat >>"$CONFIG_STATUS" <<\EOF
18073 # If no file are specified by the user, then we need to provide default
18074 # value. By we need to know if files were specified by the user.
18080 ac_option=`expr "x$1" : 'x\([^=]*\)='`
18081 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
18083 set dummy "$ac_option" "$ac_optarg" ${1+"$@"}
18087 *) # This is not an option, so the user has probably given explicit
18089 ac_need_defaults=false;;
18093 # Handling of the options.
18095 cat >>"$CONFIG_STATUS" <<EOF
18096 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
18097 echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion"
18098 exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;;
18100 cat >>"$CONFIG_STATUS" <<\EOF
18101 --version | --vers* | -V )
18102 echo "$ac_cs_version"; exit 0 ;;
18104 # Conflict between --help and --header
18105 { { echo "$as_me:18105: error: ambiguous option: $1
18106 Try \`$0 --help' for more information." >&5
18107 echo "$as_me: error: ambiguous option: $1
18108 Try \`$0 --help' for more information." >&2;}
18109 { (exit 1); exit 1; }; };;
18110 --help | --hel | -h )
18111 echo "$ac_cs_usage"; exit 0 ;;
18112 --debug | --d* | -d )
18114 --file | --fil | --fi | --f )
18116 CONFIG_FILES="$CONFIG_FILES $1"
18117 ac_need_defaults=false;;
18118 --header | --heade | --head | --hea )
18120 CONFIG_HEADERS="$CONFIG_HEADERS $1"
18121 ac_need_defaults=false;;
18123 # This is an error.
18124 -*) { { echo "$as_me:18124: error: unrecognized option: $1
18125 Try \`$0 --help' for more information." >&5
18126 echo "$as_me: error: unrecognized option: $1
18127 Try \`$0 --help' for more information." >&2;}
18128 { (exit 1); exit 1; }; } ;;
18130 *) ac_config_targets="$ac_config_targets $1" ;;
18139 ## ----------------------- ##
18140 ## Running config.status. ##
18141 ## ----------------------- ##
18143 This file was extended by $as_me 2.52.20210509, executed with
18144 CONFIG_FILES = $CONFIG_FILES
18145 CONFIG_HEADERS = $CONFIG_HEADERS
18146 CONFIG_LINKS = $CONFIG_LINKS
18147 CONFIG_COMMANDS = $CONFIG_COMMANDS
18148 > "$ac_cs_invocation"
18149 on `(hostname || uname -n) 2>/dev/null | sed 1q`
18154 cat >>"$CONFIG_STATUS" <<EOF
18156 # INIT-COMMANDS section.
18159 ### Special initialization commands, used to pass information from the
18160 ### configuration-run into config.status
18163 DFT_ARG_SUFFIX="$DFT_ARG_SUFFIX"
18164 DFT_LWR_MODEL="$DFT_LWR_MODEL"
18165 LIB_NAME="$LIB_NAME"
18166 LIB_PREFIX="$LIB_PREFIX"
18167 LIB_SUFFIX="$LIB_SUFFIX"
18169 NCURSES_MAJOR="$NCURSES_MAJOR"
18170 NCURSES_MINOR="$NCURSES_MINOR"
18171 NCURSES_PATCH="$NCURSES_PATCH"
18172 USE_OLD_MAKERULES="$USE_OLD_MAKERULES"
18173 cf_cv_VERSION_GNATMAKE=$cf_cv_VERSION_GNATMAKE
18174 cf_cv_VERSION_GPRBUILD=$cf_cv_VERSION_GPRBUILD
18175 cf_cv_abi_version="$cf_cv_abi_version"
18176 cf_cv_rel_version="$cf_cv_rel_version"
18177 cf_cv_rm_so_locs="$cf_cv_rm_so_locs"
18178 cf_cv_shared_soname='$cf_cv_shared_soname'
18179 cf_cv_shlib_version="$cf_cv_shlib_version"
18180 cf_cv_shlib_version_infix="$cf_cv_shlib_version_infix"
18181 cf_cv_system_name="$cf_cv_system_name"
18187 cat >>"$CONFIG_STATUS" <<\EOF
18188 for ac_config_target in $ac_config_targets
18190 case "$ac_config_target" in
18191 # Handling of arguments.
18192 "$SUB_MAKEFILES" ) CONFIG_FILES="$CONFIG_FILES $SUB_MAKEFILES" ;;
18193 "src/library.gpr" ) CONFIG_FILES="$CONFIG_FILES src/library.gpr:src/library.gpr.in" ;;
18194 "doc/adacurses${DFT_ARG_SUFFIX}-config.1" ) CONFIG_FILES="$CONFIG_FILES doc/adacurses${DFT_ARG_SUFFIX}-config.1:doc/MKada_config.in" ;;
18195 "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
18196 "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
18197 "include/ncurses_cfg.h" ) CONFIG_HEADERS="$CONFIG_HEADERS include/ncurses_cfg.h:include/ncurses_cfg.hin" ;;
18198 *) { { echo "$as_me:18198: error: invalid argument: $ac_config_target" >&5
18199 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
18200 { (exit 1); exit 1; }; };;
18204 # If the user did not use the arguments to specify the items to instantiate,
18205 # then the envvar interface is used. Set only those that are not.
18206 # We use the long form for the default assignment because of an extremely
18207 # bizarre bug on SunOS 4.1.3.
18208 if "$ac_need_defaults"; then
18209 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
18210 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
18211 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
18214 # Create a temporary directory, and hook for its removal unless debugging.
18217 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
18218 trap '{ (exit 1); exit 1; }' 1 2 13 15
18221 # Create a (secure) tmp directory for tmp files.
18224 tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` &&
18225 test -n "$tmp" && test -d "$tmp"
18228 tmp=$TMPDIR/cs$$-$RANDOM
18229 (umask 077 && mkdir $tmp)
18232 echo "$me: cannot create a temporary directory in $TMPDIR" >&2
18233 { (exit 1); exit 1; }
18238 cat >>"$CONFIG_STATUS" <<EOF
18241 # CONFIG_FILES section.
18244 # No need to generate the scripts if there are no CONFIG_FILES.
18245 # This happens for instance when ./config.status config.h
18246 if test -n "\$CONFIG_FILES"; then
18247 # Protect against being on the right side of a sed subst in config.status.
18248 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
18249 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
18250 s,@SHELL@,$SHELL,;t t
18251 s,@exec_prefix@,$exec_prefix,;t t
18252 s,@prefix@,$prefix,;t t
18253 s,@program_transform_name@,$program_transform_name,;t t
18254 s,@bindir@,$bindir,;t t
18255 s,@sbindir@,$sbindir,;t t
18256 s,@libexecdir@,$libexecdir,;t t
18257 s,@datarootdir@,$datarootdir,;t t
18258 s,@datadir@,$datadir,;t t
18259 s,@sysconfdir@,$sysconfdir,;t t
18260 s,@sharedstatedir@,$sharedstatedir,;t t
18261 s,@localstatedir@,$localstatedir,;t t
18262 s,@runstatedir@,$runstatedir,;t t
18263 s,@libdir@,$libdir,;t t
18264 s,@includedir@,$includedir,;t t
18265 s,@oldincludedir@,$oldincludedir,;t t
18266 s,@infodir@,$infodir,;t t
18267 s,@mandir@,$mandir,;t t
18268 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
18269 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
18270 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
18271 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
18272 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
18273 s,@build_alias@,$build_alias,;t t
18274 s,@host_alias@,$host_alias,;t t
18275 s,@target_alias@,$target_alias,;t t
18276 s,@ECHO_C@,$ECHO_C,;t t
18277 s,@ECHO_N@,$ECHO_N,;t t
18278 s,@ECHO_T@,$ECHO_T,;t t
18279 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
18280 s,@DEFS@,$DEFS,;t t
18281 s,@LIBS@,$LIBS,;t t
18282 s,@top_builddir@,$top_builddir,;t t
18283 s,@build@,$build,;t t
18284 s,@build_cpu@,$build_cpu,;t t
18285 s,@build_vendor@,$build_vendor,;t t
18286 s,@build_os@,$build_os,;t t
18287 s,@host@,$host,;t t
18288 s,@host_cpu@,$host_cpu,;t t
18289 s,@host_vendor@,$host_vendor,;t t
18290 s,@host_os@,$host_os,;t t
18291 s,@target@,$target,;t t
18292 s,@target_cpu@,$target_cpu,;t t
18293 s,@target_vendor@,$target_vendor,;t t
18294 s,@target_os@,$target_os,;t t
18295 s,@GREP@,$GREP,;t t
18296 s,@FGREP@,$FGREP,;t t
18298 s,@CFLAGS@,$CFLAGS,;t t
18299 s,@LDFLAGS@,$LDFLAGS,;t t
18300 s,@CPPFLAGS@,$CPPFLAGS,;t t
18301 s,@ac_ct_CC@,$ac_ct_CC,;t t
18302 s,@EXEEXT@,$EXEEXT,;t t
18303 s,@OBJEXT@,$OBJEXT,;t t
18304 s,@EXTRA_CPPFLAGS@,$EXTRA_CPPFLAGS,;t t
18306 s,@EGREP@,$EGREP,;t t
18308 s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
18309 s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
18310 s,@INSTALL_DATA@,$INSTALL_DATA,;t t
18311 s,@LN_S@,$LN_S,;t t
18312 s,@INSTALL_OPT_S@,$INSTALL_OPT_S,;t t
18313 s,@INSTALL_OPT_O@,$INSTALL_OPT_O,;t t
18314 s,@PKG_CONFIG@,$PKG_CONFIG,;t t
18315 s,@ac_pt_PKG_CONFIG@,$ac_pt_PKG_CONFIG,;t t
18316 s,@PKG_CONFIG_LIBDIR@,$PKG_CONFIG_LIBDIR,;t t
18317 s,@SET_MAKE@,$SET_MAKE,;t t
18318 s,@MAKE_NO_PHONY@,$MAKE_NO_PHONY,;t t
18319 s,@MAKE_PHONY@,$MAKE_PHONY,;t t
18320 s,@CTAGS@,$CTAGS,;t t
18321 s,@ETAGS@,$ETAGS,;t t
18322 s,@MAKE_LOWER_TAGS@,$MAKE_LOWER_TAGS,;t t
18323 s,@MAKE_UPPER_TAGS@,$MAKE_UPPER_TAGS,;t t
18324 s,@cf_cv_makeflags@,$cf_cv_makeflags,;t t
18325 s,@RANLIB@,$RANLIB,;t t
18326 s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
18328 s,@ac_ct_LD@,$ac_ct_LD,;t t
18330 s,@ac_ct_AR@,$ac_ct_AR,;t t
18331 s,@ARFLAGS@,$ARFLAGS,;t t
18332 s,@DESTDIR@,$DESTDIR,;t t
18333 s,@BUILD_CC@,$BUILD_CC,;t t
18334 s,@BUILD_CPP@,$BUILD_CPP,;t t
18335 s,@BUILD_CFLAGS@,$BUILD_CFLAGS,;t t
18336 s,@BUILD_CPPFLAGS@,$BUILD_CPPFLAGS,;t t
18337 s,@BUILD_LDFLAGS@,$BUILD_LDFLAGS,;t t
18338 s,@BUILD_LIBS@,$BUILD_LIBS,;t t
18339 s,@BUILD_EXEEXT@,$BUILD_EXEEXT,;t t
18340 s,@BUILD_OBJEXT@,$BUILD_OBJEXT,;t t
18341 s,@DFT_LWR_MODEL@,$DFT_LWR_MODEL,;t t
18342 s,@DFT_UPR_MODEL@,$DFT_UPR_MODEL,;t t
18343 s,@NCURSES_CONFIG@,$NCURSES_CONFIG,;t t
18344 s,@ac_ct_NCURSES_CONFIG@,$ac_ct_NCURSES_CONFIG,;t t
18345 s,@NCURSES_MAJOR@,$NCURSES_MAJOR,;t t
18346 s,@NCURSES_MINOR@,$NCURSES_MINOR,;t t
18347 s,@NCURSES_PATCH@,$NCURSES_PATCH,;t t
18348 s,@cf_cv_rel_version@,$cf_cv_rel_version,;t t
18349 s,@cf_cv_abi_version@,$cf_cv_abi_version,;t t
18350 s,@cf_cv_builtin_bool@,$cf_cv_builtin_bool,;t t
18351 s,@cf_cv_header_stdbool_h@,$cf_cv_header_stdbool_h,;t t
18352 s,@cf_cv_type_of_bool@,$cf_cv_type_of_bool,;t t
18353 s,@LIB_PREFIX@,$LIB_PREFIX,;t t
18354 s,@LIB_SUFFIX@,$LIB_SUFFIX,;t t
18355 s,@CC_G_OPT@,$CC_G_OPT,;t t
18356 s,@LD_MODEL@,$LD_MODEL,;t t
18357 s,@shlibdir@,$shlibdir,;t t
18358 s,@MAKE_DLLS@,$MAKE_DLLS,;t t
18359 s,@CC_SHARED_OPTS@,$CC_SHARED_OPTS,;t t
18360 s,@LD_RPATH_OPT@,$LD_RPATH_OPT,;t t
18361 s,@LD_SHARED_OPTS@,$LD_SHARED_OPTS,;t t
18362 s,@MK_SHARED_LIB@,$MK_SHARED_LIB,;t t
18363 s,@RM_SHARED_OPTS@,$RM_SHARED_OPTS,;t t
18364 s,@LINK_PROGS@,$LINK_PROGS,;t t
18365 s,@LINK_TESTS@,$LINK_TESTS,;t t
18366 s,@EXTRA_LDFLAGS@,$EXTRA_LDFLAGS,;t t
18367 s,@LOCAL_LDFLAGS@,$LOCAL_LDFLAGS,;t t
18368 s,@LOCAL_LDFLAGS2@,$LOCAL_LDFLAGS2,;t t
18369 s,@INSTALL_LIB@,$INSTALL_LIB,;t t
18370 s,@RPATH_LIST@,$RPATH_LIST,;t t
18371 s,@BROKEN_LINKER@,$BROKEN_LINKER,;t t
18372 s,@NCURSES_EXT_FUNCS@,$NCURSES_EXT_FUNCS,;t t
18373 s,@NCURSES_CONST@,$NCURSES_CONST,;t t
18374 s,@PTHREAD@,$PTHREAD,;t t
18375 s,@cf_cv_enable_reentrant@,$cf_cv_enable_reentrant,;t t
18376 s,@NCURSES_WRAP_PREFIX@,$NCURSES_WRAP_PREFIX,;t t
18377 s,@ECHO_LT@,$ECHO_LT,;t t
18378 s,@ECHO_LD@,$ECHO_LD,;t t
18379 s,@RULE_CC@,$RULE_CC,;t t
18380 s,@SHOW_CC@,$SHOW_CC,;t t
18381 s,@ECHO_CC@,$ECHO_CC,;t t
18382 s,@EXTRA_CFLAGS@,$EXTRA_CFLAGS,;t t
18383 s,@HAVE_STDNORETURN_H@,$HAVE_STDNORETURN_H,;t t
18384 s,@STDC_NORETURN@,$STDC_NORETURN,;t t
18385 s,@ADAFLAGS@,$ADAFLAGS,;t t
18386 s,@ADA_TRACE@,$ADA_TRACE,;t t
18387 s,@cf_TEMP_gnat@,$cf_TEMP_gnat,;t t
18388 s,@M4_exists@,$M4_exists,;t t
18389 s,@cf_ada_make@,$cf_ada_make,;t t
18390 s,@cf_ada_config@,$cf_ada_config,;t t
18391 s,@cf_ada_config_Ada@,$cf_ada_config_Ada,;t t
18392 s,@cf_ada_config_C@,$cf_ada_config_C,;t t
18393 s,@GNATPREP_OPTS@,$GNATPREP_OPTS,;t t
18394 s,@cf_compile_generics@,$cf_compile_generics,;t t
18395 s,@cf_generic_objects@,$cf_generic_objects,;t t
18396 s,@USE_GNAT_SIGINT@,$USE_GNAT_SIGINT,;t t
18397 s,@USE_OLD_MAKERULES@,$USE_OLD_MAKERULES,;t t
18398 s,@USE_GNAT_PROJECTS@,$USE_GNAT_PROJECTS,;t t
18399 s,@USE_GNAT_LIBRARIES@,$USE_GNAT_LIBRARIES,;t t
18400 s,@USE_GNAT_MAKE_GPR@,$USE_GNAT_MAKE_GPR,;t t
18401 s,@USE_GNAT_GPRBUILD@,$USE_GNAT_GPRBUILD,;t t
18402 s,@cf_ada_compiler@,$cf_ada_compiler,;t t
18403 s,@cf_ada_package@,$cf_ada_package,;t t
18404 s,@ADA_INCLUDE@,$ADA_INCLUDE,;t t
18405 s,@ADA_OBJECTS@,$ADA_OBJECTS,;t t
18406 s,@ADA_SHAREDLIB@,$ADA_SHAREDLIB,;t t
18407 s,@MAKE_ADA_SHAREDLIB@,$MAKE_ADA_SHAREDLIB,;t t
18408 s,@ADA_LIBNAME@,$ADA_LIBNAME,;t t
18409 s,@TINFO_LDFLAGS2@,$TINFO_LDFLAGS2,;t t
18410 s,@TINFO_LIBS@,$TINFO_LIBS,;t t
18411 s,@ACPPFLAGS@,$ACPPFLAGS,;t t
18412 s,@DFT_ARG_SUFFIX@,$DFT_ARG_SUFFIX,;t t
18413 s,@DFT_DEP_SUFFIX@,$DFT_DEP_SUFFIX,;t t
18414 s,@DFT_OBJ_SUBDIR@,$DFT_OBJ_SUBDIR,;t t
18415 s,@USE_ARG_SUFFIX@,$USE_ARG_SUFFIX,;t t
18416 s,@USE_LIB_SUFFIX@,$USE_LIB_SUFFIX,;t t
18417 s,@USE_CFG_SUFFIX@,$USE_CFG_SUFFIX,;t t
18418 s,@TEST_ARG2@,$TEST_ARG2,;t t
18419 s,@TEST_LIBS2@,$TEST_LIBS2,;t t
18420 s,@NCURSES_SHLIB2@,$NCURSES_SHLIB2,;t t
18421 s,@ADA_SUBDIRS@,$ADA_SUBDIRS,;t t
18422 s,@NCURSES_TREE@,$NCURSES_TREE,;t t
18423 s,@EXTERNAL_TREE@,$EXTERNAL_TREE,;t t
18424 s,@ADAHTML_DIR@,$ADAHTML_DIR,;t t
18425 s,@ADAGEN_LDFLAGS@,$ADAGEN_LDFLAGS,;t t
18430 cat >>"$CONFIG_STATUS" <<\EOF
18431 # Split the substitutions into bite-sized pieces for seds with
18432 # small command number limits, like on Digital OSF/1 and HP-UX.
18433 ac_max_sed_lines=48
18434 ac_sed_frag=1 # Number of current file.
18435 ac_beg=1 # First line for current file.
18436 ac_end=$ac_max_sed_lines # Line after last line for current file.
18439 while "$ac_more_lines"; do
18440 if test "$ac_beg" -gt 1; then
18441 sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
18443 sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
18445 if test ! -s $tmp/subs.frag; then
18446 ac_more_lines=false
18448 # The purpose of the label and of the branching condition is to
18449 # speed up the sed processing (if there are no `@' at all, there
18450 # is no need to browse any of the substitutions).
18451 # These are the two extra sed commands mentioned above.
18453 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
18454 # It is possible to make a multiline substitution using escaped newlines.
18455 # Ensure that we do not split the substitution between script fragments.
18457 ac_END=`expr "$ac_end" + "$ac_max_sed_lines"`
18458 sed "1,${ac_BEG}d; ${ac_END}p; q" $tmp/subs.sed >$tmp/subs.next
18459 if test -s $tmp/subs.next; then
18460 grep '^s,@[^@,][^@,]*@,.*\\$' $tmp/subs.next >$tmp/subs.edit
18461 if test ! -s $tmp/subs.edit; then
18462 grep "^s,@[^@,][^@,]*@,.*,;t t$" $tmp/subs.next >$tmp/subs.edit
18463 if test ! -s $tmp/subs.edit; then
18464 if test "$ac_beg" -gt 1; then
18465 ac_end=`expr "$ac_end" - 1`
18472 if test -z "$ac_sed_cmds"; then
18473 ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
18475 ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
18477 ac_sed_frag=`expr "$ac_sed_frag" + 1`
18479 ac_end=`expr "$ac_end" + "$ac_max_sed_lines"`
18482 if test -z "$ac_sed_cmds"; then
18485 fi # test -n "$CONFIG_FILES"
18488 cat >>"$CONFIG_STATUS" <<\EOF
18489 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
18490 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
18492 - | *:- | *:-:* ) # input from stdin
18494 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
18495 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
18496 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
18497 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
18498 * ) ac_file_in=$ac_file.in ;;
18501 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
18502 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
18503 X"$ac_file" : 'X\(//\)[^/]' \| \
18504 X"$ac_file" : 'X\(//\)$' \| \
18505 X"$ac_file" : 'X\(/\)' \| \
18506 . : '\(.\)' 2>/dev/null ||
18508 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
18509 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
18510 /^X\(\/\/\)$/{ s//\1/; q; }
18511 /^X\(\/\).*/{ s//\1/; q; }
18513 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
18514 { case "$ac_dir" in
18515 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
18519 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
18520 case $as_mkdir_dir in
18521 # Skip DOS drivespec
18522 ?:) as_incr_dir=$as_mkdir_dir ;;
18524 as_incr_dir=$as_incr_dir/$as_mkdir_dir
18525 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
18530 ac_dir_suffix="/`echo $ac_dir|sed 's,^\./,,'`"
18531 # A "../" for each directory in $ac_dir_suffix.
18532 ac_dots=`echo "$ac_dir_suffix" | sed 's,/[^/]*,../,g'`
18534 ac_dir_suffix= ac_dots=
18539 if test -z "$ac_dots"; then
18542 ac_top_srcdir=`echo "$ac_dots" | sed 's,/$,,'`
18544 [\\/]* | ?:[\\/]* )
18545 ac_srcdir="$srcdir$ac_dir_suffix";
18546 ac_top_srcdir="$srcdir" ;;
18547 *) # Relative path.
18548 ac_srcdir="$ac_dots$srcdir$ac_dir_suffix"
18549 ac_top_srcdir="$ac_dots$srcdir" ;;
18553 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
18554 *) ac_INSTALL=$ac_dots$INSTALL ;;
18557 if test x"$ac_file" != x-; then
18558 { echo "$as_me:18558: creating $ac_file" >&5
18559 echo "$as_me: creating $ac_file" >&6;}
18562 # Let's still pretend it is `configure' which instantiates (i.e., don't
18563 # use $as_me), people would be surprised to read:
18564 # /* config.h. Generated automatically by config.status. */
18565 configure_input="Generated automatically from `echo $ac_file_in |
18566 sed 's,.*/,,'` by configure."
18568 # First look for the input files in the build tree, otherwise in the
18570 ac_file_inputs=`IFS=:
18571 for f in $ac_file_in; do
18573 -) echo $tmp/stdin ;;
18575 # Absolute (can't be DOS-style, as IFS=:)
18576 test -f "$f" || { { echo "$as_me:18576: error: cannot find input file: $f" >&5
18577 echo "$as_me: error: cannot find input file: $f" >&2;}
18578 { (exit 1); exit 1; }; }
18581 if test -f "$f"; then
18584 elif test -f "$srcdir/$f"; then
18589 { { echo "$as_me:18589: error: cannot find input file: $f" >&5
18590 echo "$as_me: error: cannot find input file: $f" >&2;}
18591 { (exit 1); exit 1; }; }
18594 done` || { (exit 1); exit 1; }
18596 cat >>"$CONFIG_STATUS" <<\EOF
18597 ac_warn_datarootdir=no
18598 if test x"$ac_file" != x-; then
18599 for ac_item in $ac_file_inputs
18601 ac_seen=`grep '@\(datadir\|mandir\|infodir\)@' "$ac_item"`
18602 if test -n "$ac_seen"; then
18603 ac_used=`grep '@datarootdir@' "$ac_item"`
18604 if test -z "$ac_used"; then
18605 { echo "$as_me:18605: WARNING: datarootdir was used implicitly but not set:
18607 echo "$as_me: WARNING: datarootdir was used implicitly but not set:
18609 ac_warn_datarootdir=yes
18612 ac_seen=`grep '${datarootdir}' "$ac_item"`
18613 if test -n "$ac_seen"; then
18614 { echo "$as_me:18614: WARNING: datarootdir was used explicitly but not set:
18616 echo "$as_me: WARNING: datarootdir was used explicitly but not set:
18618 ac_warn_datarootdir=yes
18623 if test "x$ac_warn_datarootdir" = xyes; then
18624 ac_sed_cmds="$ac_sed_cmds | sed -e 's,@datarootdir@,\${prefix}/share,g' -e 's,\${datarootdir},\${prefix}/share,g'"
18628 cat >>"$CONFIG_STATUS" <<EOF
18632 cat >>"$CONFIG_STATUS" <<\EOF
18634 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
18635 s,@configure_input@,$configure_input,;t t
18636 s,@srcdir@,$ac_srcdir,;t t
18637 s,@top_srcdir@,$ac_top_srcdir,;t t
18638 s,@INSTALL@,$ac_INSTALL,;t t
18639 " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
18641 if test x"$ac_file" != x-; then
18642 cp "$tmp/out" "$ac_file"
18644 for ac_name in prefix exec_prefix datarootdir
18646 ac_seen=`${FGREP-fgrep} -n '${'$ac_name'[:=].*}' "$ac_file"`
18647 if test -n "$ac_seen"; then
18648 ac_init=`${EGREP-egrep} '[ ]*'$ac_name'[ ]*=' "$ac_file"`
18649 if test -z "$ac_init"; then
18650 ac_seen=`echo "$ac_seen" |sed -e 's,^,'$ac_file':,'`
18651 { echo "$as_me:18651: WARNING: Variable $ac_name is used but was not set:
18653 echo "$as_me: WARNING: Variable $ac_name is used but was not set:
18658 ${EGREP-egrep} -n '@[a-z_][a-z_0-9]+@' "$ac_file" >$tmp/out
18659 ${EGREP-egrep} -n '@[A-Z_][A-Z_0-9]+@' "$ac_file" >>$tmp/out
18660 if test -s $tmp/out; then
18661 ac_seen=`sed -e 's,^,'$ac_file':,' < $tmp/out`
18662 { echo "$as_me:18662: WARNING: Some variables may not be substituted:
18664 echo "$as_me: WARNING: Some variables may not be substituted:
18674 cat >>"$CONFIG_STATUS" <<\EOF
18677 # CONFIG_HEADER section.
18680 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
18681 # NAME is the cpp macro being defined and VALUE is the value it is being given.
18683 # ac_d sets the value in "#define NAME VALUE" lines.
18684 ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
18685 ac_dB='[ ].*$,\1#\2'
18688 # ac_i turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
18689 ac_iA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
18690 ac_iB='\([ ]\),\1#\2define\3'
18693 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
18694 ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
18695 ac_uB='$,\1#\2define\3'
18699 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
18700 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
18702 - | *:- | *:-:* ) # input from stdin
18704 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
18705 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
18706 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
18707 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
18708 * ) ac_file_in=$ac_file.in ;;
18711 test x"$ac_file" != x- && { echo "$as_me:18711: creating $ac_file" >&5
18712 echo "$as_me: creating $ac_file" >&6;}
18714 # First look for the input files in the build tree, otherwise in the
18716 ac_file_inputs=`IFS=:
18717 for f in $ac_file_in; do
18719 -) echo $tmp/stdin ;;
18721 # Absolute (can't be DOS-style, as IFS=:)
18722 test -f "$f" || { { echo "$as_me:18722: error: cannot find input file: $f" >&5
18723 echo "$as_me: error: cannot find input file: $f" >&2;}
18724 { (exit 1); exit 1; }; }
18727 if test -f "$f"; then
18730 elif test -f "$srcdir/$f"; then
18735 { { echo "$as_me:18735: error: cannot find input file: $f" >&5
18736 echo "$as_me: error: cannot find input file: $f" >&2;}
18737 { (exit 1); exit 1; }; }
18740 done` || { (exit 1); exit 1; }
18741 # Remove the trailing spaces.
18742 sed 's/[ ]*$//' $ac_file_inputs >$tmp/in
18746 # Transform confdefs.h into a list of #define's. We won't use it as a sed
18747 # script, but as data to insert where we see @DEFS@. We expect AC_SAVE_DEFS to
18748 # be either 'cat' or 'sort'.
18749 cat confdefs.h | uniq >conftest.vals
18751 # Break up conftest.vals because some shells have a limit on
18752 # the size of here documents, and old seds have small limits too.
18754 rm -f conftest.tail
18755 echo ' rm -f conftest.frag' >> "$CONFIG_STATUS"
18756 while grep . conftest.vals >/dev/null
18758 # Write chunks of a limited-size here document to conftest.frag.
18759 echo ' cat >> conftest.frag <<CEOF' >> "$CONFIG_STATUS"
18760 sed "${ac_max_here_lines}q" conftest.vals | sed -e 's/#ifdef.*/#if 0/' >> "$CONFIG_STATUS"
18761 echo 'CEOF' >> "$CONFIG_STATUS"
18762 sed "1,${ac_max_here_lines}d" conftest.vals > conftest.tail
18763 rm -f conftest.vals
18764 mv conftest.tail conftest.vals
18766 rm -f conftest.vals
18768 # Run sed to substitute the contents of conftest.frag into $tmp/in at the
18770 echo ' cat >> conftest.edit <<CEOF
18771 /@DEFS@/r conftest.frag
18774 sed -f conftest.edit $tmp/in > $tmp/out
18776 mv $tmp/out $tmp/in
18777 rm -f conftest.edit conftest.frag
18778 ' >> "$CONFIG_STATUS"
18780 cat >>"$CONFIG_STATUS" <<\EOF
18781 # Let's still pretend it is `configure' which instantiates (i.e., don't
18782 # use $as_me), people would be surprised to read:
18783 # /* config.h. Generated automatically by config.status. */
18784 if test x"$ac_file" = x-; then
18785 echo "/* Generated automatically by configure. */" >$tmp/config.h
18787 echo "/* $ac_file. Generated automatically by configure. */" >$tmp/config.h
18789 cat $tmp/in >>$tmp/config.h
18791 if test x"$ac_file" != x-; then
18792 if cmp -s "$ac_file" "$tmp/config.h" 2>/dev/null; then
18793 { echo "$as_me:18793: $ac_file is unchanged" >&5
18794 echo "$as_me: $ac_file is unchanged" >&6;}
18796 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
18797 X"$ac_file" : 'X\(//\)[^/]' \| \
18798 X"$ac_file" : 'X\(//\)$' \| \
18799 X"$ac_file" : 'X\(/\)' \| \
18800 . : '\(.\)' 2>/dev/null ||
18802 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
18803 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
18804 /^X\(\/\/\)$/{ s//\1/; q; }
18805 /^X\(\/\).*/{ s//\1/; q; }
18807 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
18808 { case "$ac_dir" in
18809 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
18813 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
18814 case $as_mkdir_dir in
18815 # Skip DOS drivespec
18816 ?:) as_incr_dir=$as_mkdir_dir ;;
18818 as_incr_dir=$as_incr_dir/$as_mkdir_dir
18819 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
18826 mv "$tmp/config.h" "$ac_file"
18830 rm -f $tmp/config.h
18834 cat >>"$CONFIG_STATUS" <<\EOF
18836 # CONFIG_COMMANDS section.
18838 for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
18839 ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
18840 ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
18844 if test -z "$USE_OLD_MAKERULES" ; then
18845 $AWK -f $srcdir/mk-1st.awk <$srcdir/src/modules >>src/Makefile
18852 cat >>"$CONFIG_STATUS" <<\EOF
18854 { (exit 0); exit 0; }
18856 chmod +x "$CONFIG_STATUS"
18857 ac_clean_files=$ac_clean_files_save
18859 # configure is writing to config.log, and then calls config.status.
18860 # config.status does its own redirection, appending to config.log.
18861 # Unfortunately, on DOS this fails, as config.log is still kept open
18862 # by configure, so config.status won't be able to write to it; its
18863 # output is simply discarded. So we exec the FD to /dev/null,
18864 # effectively closing config.log, so it can be properly (re)opened and
18865 # appended to by config.status. When coming back to configure, we
18866 # need to make the FD available again.
18867 if test "$no_create" != yes; then
18870 $SHELL "$CONFIG_STATUS" || ac_cs_success=false
18872 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
18873 # would make configure fail if this is the last instruction.
18874 "$ac_cs_success" || { (exit 1); exit 1; }
18876 ${MAKE:-make} preinstall