2 # From configure.in Revision: 1.62 .
3 # Guess values for system-dependent variables and create Makefiles.
4 # Generated by Autoconf 2.52.20170501.
6 # Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
7 # Free Software Foundation, Inc.
8 # This configure script is free software; the Free Software Foundation
9 # gives unlimited permission to copy, distribute and modify it.
11 # Avoid depending upon Character Ranges.
12 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
13 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
14 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
15 as_cr_digits='0123456789'
16 as_cr_alnum=$as_cr_Letters$as_cr_digits
18 # Sed expression to map a string onto a valid variable name.
19 as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
21 # Sed expression to map a string onto a valid CPP name.
22 as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
24 # Be Bourne compatible
25 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
28 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
32 # Name of the executable.
33 as_me=`echo "$0" |sed 's,.*[\\/],,'`
35 if expr a : '\(a\)' >/dev/null 2>&1; then
41 rm -f conf$$ conf$$.exe conf$$.file
43 if ln -s conf$$.file conf$$ 2>/dev/null; then
44 # We could just check for DJGPP; but this test a) works b) is more generic
45 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
46 if test -f conf$$.exe; then
47 # Don't use ln at all; we don't have any links
52 elif ln conf$$.file conf$$ 2>/dev/null; then
57 rm -f conf$$ conf$$.exe conf$$.file
59 as_executable_p="test -f"
61 # Support unset when possible.
62 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
69 $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
70 $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
71 $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
72 $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
73 $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
74 $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
75 $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
76 $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
79 # We need space, tab and new line, in precisely that order.
85 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
88 # hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
89 # so uname gets run too.
90 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
97 ac_default_prefix=/usr/local
101 SHELL=${CONFIG_SHELL-/bin/sh}
103 # Maximum number of lines to put in a shell here document.
104 # This variable seems obsolete. It should probably be removed, and
105 # only ac_max_sed_lines should be used.
106 : ${ac_max_here_lines=38}
108 ac_unique_file="gen/gen.c"
109 # Factoring default headers for most tests.
110 ac_includes_default="\
113 # include <sys/types.h>
116 # include <sys/stat.h>
127 # if !STDC_HEADERS && HAVE_MEMORY_H
133 # include <strings.h>
136 # include <inttypes.h>
146 # Initialize some variables set by options.
148 ac_init_version=false
149 # The variables have the same names as the options, with
150 # dashes changed to underlines.
158 program_transform_name=s,x,x,
166 # Installation directory options.
167 # These are left unexpanded so users can "make install exec_prefix=/foo"
168 # and all the variables that are supposed to be based on exec_prefix
169 # by default will actually change.
170 # Use braces instead of parens because sh, perl, etc. also accept them.
171 bindir='${exec_prefix}/bin'
172 sbindir='${exec_prefix}/sbin'
173 libexecdir='${exec_prefix}/libexec'
174 datarootdir='${prefix}/share'
175 datadir='${datarootdir}'
176 sysconfdir='${prefix}/etc'
177 sharedstatedir='${prefix}/com'
178 localstatedir='${prefix}/var'
179 libdir='${exec_prefix}/lib'
180 includedir='${prefix}/include'
181 oldincludedir='/usr/include'
182 infodir='${datarootdir}/info'
183 mandir='${datarootdir}/man'
185 # Identity of this package.
195 # If the previous option needs an argument, assign it.
196 if test -n "$ac_prev"; then
197 eval "$ac_prev=\$ac_option"
202 ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
204 # Accept the important Cygnus configure options, so we can diagnose typos.
208 -bindir | --bindir | --bindi | --bind | --bin | --bi)
210 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
213 -build | --build | --buil | --bui | --bu)
214 ac_prev=build_alias ;;
215 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
216 build_alias=$ac_optarg ;;
218 -cache-file | --cache-file | --cache-fil | --cache-fi \
219 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
220 ac_prev=cache_file ;;
221 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
222 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
223 cache_file=$ac_optarg ;;
226 cache_file=config.cache ;;
228 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
230 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
232 datadir=$ac_optarg ;;
234 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
235 | --dataroo | --dataro | --datar)
236 ac_prev=datarootdir ;;
237 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
238 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
239 datarootdir=$ac_optarg ;;
241 -disable-* | --disable-*)
242 ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
243 # Reject names that are not valid shell variable names.
244 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
245 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
246 { (exit 1); exit 1; }; }
247 ac_feature=`echo $ac_feature | sed 's/-/_/g'`
248 eval "enable_$ac_feature=no" ;;
250 -enable-* | --enable-*)
251 ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
252 # Reject names that are not valid shell variable names.
253 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
254 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
255 { (exit 1); exit 1; }; }
256 ac_feature=`echo $ac_feature | sed 's/-/_/g'`
258 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
261 eval "enable_$ac_feature='$ac_optarg'" ;;
263 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
264 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
265 | --exec | --exe | --ex)
266 ac_prev=exec_prefix ;;
267 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
268 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
269 | --exec=* | --exe=* | --ex=*)
270 exec_prefix=$ac_optarg ;;
272 -gas | --gas | --ga | --g)
273 # Obsolete; use --with-gas.
276 -help | --help | --hel | --he | -h)
278 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
279 ac_init_help=recursive ;;
280 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
281 ac_init_help=short ;;
283 -host | --host | --hos | --ho)
284 ac_prev=host_alias ;;
285 -host=* | --host=* | --hos=* | --ho=*)
286 host_alias=$ac_optarg ;;
288 -includedir | --includedir | --includedi | --included | --include \
289 | --includ | --inclu | --incl | --inc)
290 ac_prev=includedir ;;
291 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
292 | --includ=* | --inclu=* | --incl=* | --inc=*)
293 includedir=$ac_optarg ;;
295 -infodir | --infodir | --infodi | --infod | --info | --inf)
297 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
298 infodir=$ac_optarg ;;
300 -libdir | --libdir | --libdi | --libd)
302 -libdir=* | --libdir=* | --libdi=* | --libd=*)
305 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
306 | --libexe | --libex | --libe)
307 ac_prev=libexecdir ;;
308 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
309 | --libexe=* | --libex=* | --libe=*)
310 libexecdir=$ac_optarg ;;
312 -localstatedir | --localstatedir | --localstatedi | --localstated \
313 | --localstate | --localstat | --localsta | --localst \
314 | --locals | --local | --loca | --loc | --lo)
315 ac_prev=localstatedir ;;
316 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
317 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
318 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
319 localstatedir=$ac_optarg ;;
321 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
323 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
327 # Obsolete; use --without-fp.
330 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
334 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
335 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
338 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
339 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
340 | --oldin | --oldi | --old | --ol | --o)
341 ac_prev=oldincludedir ;;
342 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
343 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
344 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
345 oldincludedir=$ac_optarg ;;
347 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
349 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
352 -program-prefix | --program-prefix | --program-prefi | --program-pref \
353 | --program-pre | --program-pr | --program-p)
354 ac_prev=program_prefix ;;
355 -program-prefix=* | --program-prefix=* | --program-prefi=* \
356 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
357 program_prefix=$ac_optarg ;;
359 -program-suffix | --program-suffix | --program-suffi | --program-suff \
360 | --program-suf | --program-su | --program-s)
361 ac_prev=program_suffix ;;
362 -program-suffix=* | --program-suffix=* | --program-suffi=* \
363 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
364 program_suffix=$ac_optarg ;;
366 -program-transform-name | --program-transform-name \
367 | --program-transform-nam | --program-transform-na \
368 | --program-transform-n | --program-transform- \
369 | --program-transform | --program-transfor \
370 | --program-transfo | --program-transf \
371 | --program-trans | --program-tran \
372 | --progr-tra | --program-tr | --program-t)
373 ac_prev=program_transform_name ;;
374 -program-transform-name=* | --program-transform-name=* \
375 | --program-transform-nam=* | --program-transform-na=* \
376 | --program-transform-n=* | --program-transform-=* \
377 | --program-transform=* | --program-transfor=* \
378 | --program-transfo=* | --program-transf=* \
379 | --program-trans=* | --program-tran=* \
380 | --progr-tra=* | --program-tr=* | --program-t=*)
381 program_transform_name=$ac_optarg ;;
383 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
384 | -silent | --silent | --silen | --sile | --sil)
387 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
389 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
391 sbindir=$ac_optarg ;;
393 -sharedstatedir | --sharedstatedir | --sharedstatedi \
394 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
395 | --sharedst | --shareds | --shared | --share | --shar \
397 ac_prev=sharedstatedir ;;
398 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
399 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
400 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
402 sharedstatedir=$ac_optarg ;;
404 -site | --site | --sit)
406 -site=* | --site=* | --sit=*)
409 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
411 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
414 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
415 | --syscon | --sysco | --sysc | --sys | --sy)
416 ac_prev=sysconfdir ;;
417 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
418 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
419 sysconfdir=$ac_optarg ;;
421 -target | --target | --targe | --targ | --tar | --ta | --t)
422 ac_prev=target_alias ;;
423 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
424 target_alias=$ac_optarg ;;
426 -v | -verbose | --verbose | --verbos | --verbo | --verb)
429 -version | --version | --versio | --versi | --vers | -V)
433 ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
434 # Reject names that are not valid shell variable names.
435 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
436 { echo "$as_me: error: invalid package name: $ac_package" >&2
437 { (exit 1); exit 1; }; }
438 ac_package=`echo $ac_package| sed 's/-/_/g'`
440 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
443 eval "with_$ac_package='$ac_optarg'" ;;
445 -without-* | --without-*)
446 ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
447 # Reject names that are not valid shell variable names.
448 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
449 { echo "$as_me: error: invalid package name: $ac_package" >&2
450 { (exit 1); exit 1; }; }
451 ac_package=`echo $ac_package | sed 's/-/_/g'`
452 eval "with_$ac_package=no" ;;
455 # Obsolete; use --with-x.
458 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
459 | --x-incl | --x-inc | --x-in | --x-i)
460 ac_prev=x_includes ;;
461 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
462 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
463 x_includes=$ac_optarg ;;
465 -x-libraries | --x-libraries | --x-librarie | --x-librari \
466 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
467 ac_prev=x_libraries ;;
468 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
469 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
470 x_libraries=$ac_optarg ;;
472 -*) { echo "$as_me: error: unrecognized option: $ac_option
473 Try \`$0 --help' for more information." >&2
474 { (exit 1); exit 1; }; }
478 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
479 # Reject names that are not valid shell variable names.
480 expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
481 { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
482 { (exit 1); exit 1; }; }
483 ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
484 eval "$ac_envvar='$ac_optarg'"
488 # FIXME: should be removed in autoconf 3.0.
489 echo "$as_me: WARNING: you should use --build, --host, --target" >&2
490 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
491 echo "$as_me: WARNING: invalid host type: $ac_option" >&2
492 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
498 if test -n "$ac_prev"; then
499 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
500 { echo "$as_me: error: missing argument to $ac_option" >&2
501 { (exit 1); exit 1; }; }
504 # Be sure to have absolute paths.
505 for ac_var in exec_prefix prefix
507 eval ac_val=$`echo $ac_var`
509 [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
510 *) { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
511 { (exit 1); exit 1; }; };;
515 # Be sure to have absolute paths.
516 for ac_var in bindir sbindir libexecdir datarootdir datadir sysconfdir sharedstatedir \
517 localstatedir libdir includedir oldincludedir infodir mandir
519 eval ac_val=$`echo $ac_var`
521 [\\/$]* | ?:[\\/]* ) ;;
522 *) { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
523 { (exit 1); exit 1; }; };;
527 # There might be people who depend on the old broken behavior: `$host'
528 # used to hold the argument of --host etc.
533 # FIXME: should be removed in autoconf 3.0.
534 if test "x$host_alias" != x; then
535 if test "x$build_alias" = x; then
536 cross_compiling=maybe
537 echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
538 If a cross compiler is detected then cross compile mode will be used." >&2
539 elif test "x$build_alias" != "x$host_alias"; then
545 test -n "$host_alias" && ac_tool_prefix=$host_alias-
547 test "$silent" = yes && exec 6>/dev/null
549 # Find the source files, if location was not specified.
550 if test -z "$srcdir"; then
551 ac_srcdir_defaulted=yes
552 # Try the directory containing this script, then its parent.
554 ac_confdir=`echo "$ac_prog" | sed 's%[\\/][^\\/][^\\/]*$%%'`
555 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
557 if test ! -r $srcdir/$ac_unique_file; then
561 ac_srcdir_defaulted=no
563 if test ! -r $srcdir/$ac_unique_file; then
564 if test "$ac_srcdir_defaulted" = yes; then
565 { echo "$as_me: error: cannot find sources in $ac_confdir or .." >&2
566 { (exit 1); exit 1; }; }
568 { echo "$as_me: error: cannot find sources in $srcdir" >&2
569 { (exit 1); exit 1; }; }
572 srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
573 ac_env_build_alias_set=${build_alias+set}
574 ac_env_build_alias_value=$build_alias
575 ac_cv_env_build_alias_set=${build_alias+set}
576 ac_cv_env_build_alias_value=$build_alias
577 ac_env_host_alias_set=${host_alias+set}
578 ac_env_host_alias_value=$host_alias
579 ac_cv_env_host_alias_set=${host_alias+set}
580 ac_cv_env_host_alias_value=$host_alias
581 ac_env_target_alias_set=${target_alias+set}
582 ac_env_target_alias_value=$target_alias
583 ac_cv_env_target_alias_set=${target_alias+set}
584 ac_cv_env_target_alias_value=$target_alias
585 ac_env_CC_set=${CC+set}
587 ac_cv_env_CC_set=${CC+set}
588 ac_cv_env_CC_value=$CC
589 ac_env_CFLAGS_set=${CFLAGS+set}
590 ac_env_CFLAGS_value=$CFLAGS
591 ac_cv_env_CFLAGS_set=${CFLAGS+set}
592 ac_cv_env_CFLAGS_value=$CFLAGS
593 ac_env_LDFLAGS_set=${LDFLAGS+set}
594 ac_env_LDFLAGS_value=$LDFLAGS
595 ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
596 ac_cv_env_LDFLAGS_value=$LDFLAGS
597 ac_env_CPPFLAGS_set=${CPPFLAGS+set}
598 ac_env_CPPFLAGS_value=$CPPFLAGS
599 ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
600 ac_cv_env_CPPFLAGS_value=$CPPFLAGS
601 ac_env_CPP_set=${CPP+set}
602 ac_env_CPP_value=$CPP
603 ac_cv_env_CPP_set=${CPP+set}
604 ac_cv_env_CPP_value=$CPP
607 # Report the --help message.
609 if test "$ac_init_help" = "long"; then
610 # Omit some internal or obsolete options to make the list less imposing.
611 # This message is too long to be a string in the A/UX 3.1 sh.
613 \`configure' configures this package to adapt to many kinds of systems.
615 Usage: $0 [OPTION]... [VAR=VALUE]...
617 To assign environment variables (e.g., CC, CFLAGS...), specify them as
618 VAR=VALUE. See below for descriptions of some of the useful variables.
620 Defaults for the options are specified in brackets.
623 -h, --help display this help and exit
624 --help=short display options specific to this package
625 --help=recursive display the short help of all the included packages
626 -V, --version display version information and exit
627 -q, --quiet, --silent do not print \`checking...' messages
628 --cache-file=FILE cache test results in FILE [disabled]
629 -C, --config-cache alias for \`--cache-file=config.cache'
630 -n, --no-create do not create output files
631 --srcdir=DIR find the sources in DIR [configure dir or \`..']
636 Installation directories:
637 --prefix=PREFIX install architecture-independent files in PREFIX
639 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
642 By default, \`make install' will install all the files in
643 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
644 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
645 for instance \`--prefix=\$HOME'.
647 For better control, use the options below.
649 Fine tuning of the installation directories:
650 --bindir=DIR user executables [EPREFIX/bin]
651 --sbindir=DIR system admin executables [EPREFIX/sbin]
652 --libexecdir=DIR program executables [EPREFIX/libexec]
653 --datarootdir=DIR read-only architecture-independent data [PREFIX/share]
654 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
655 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
656 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
657 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
658 --libdir=DIR object code libraries [EPREFIX/lib]
659 --includedir=DIR C header files [PREFIX/include]
660 --oldincludedir=DIR C header files for non-gcc [/usr/include]
661 --infodir=DIR info documentation [DATAROOTDIR/info]
662 --mandir=DIR man documentation [DATAROOTDIR/man]
668 --program-prefix=PREFIX prepend PREFIX to installed program names
669 --program-suffix=SUFFIX append SUFFIX to installed program names
670 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
673 --build=BUILD configure for building on BUILD [guessed]
674 --host=HOST build programs to run on HOST [BUILD]
675 --target=TARGET configure for building compilers for TARGET [HOST]
679 if test -n "$ac_init_help"; then
684 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
685 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
688 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
689 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
691 --with-system-type=XXX test: override derived host system-type
692 --with-pkg-config{=path} enable/disable use of pkg-config
693 --with-pkg-config-libdir=XXX use given directory for installing pc-files
694 --without-tests suppress build with test-programs
695 --enable-mixed-case tic should assume mixed-case filenames
696 --with-install-prefix prefixes actual install-location ($DESTDIR)
697 Build-Tools Needed to Compile Temporary Applications for Cross-compiling:
698 --with-build-cc=XXX the build C compiler ($BUILD_CC)
699 --with-build-cpp=XXX the build C preprocessor ($BUILD_CPP)
700 --with-build-cflags=XXX the build C compiler-flags ($BUILD_CFLAGS)
701 --with-build-cppflags=XXX the build C preprocessor-flags ($BUILD_CPPFLAGS)
702 --with-build-ldflags=XXX the build linker-flags ($BUILD_LDFLAGS)
703 --with-build-libs=XXX the build libraries (${BUILD_LIBS})
704 Options to Specify the Libraries Built/Used:
705 --with-shared generate shared C-objects (needed for --with-ada-sharedlib)
706 --with-curses-dir=DIR directory in which (n)curses is installed
707 --enable-widec compile with wide-char/UTF-8 code
708 --with-lib-prefix override library-prefix
709 --with-shlib-version=X Specify rel or abi version for shared libs
710 --enable-rpath-link link sample programs with rpath option
711 Fine-Tuning Your Configuration:
712 --enable-broken_linker compile with broken-linker support code
713 --disable-largefile omit support for large files
714 --with-rcs-ids compile-in RCS identifiers
716 --disable-ext-funcs disable function-extensions
717 --enable-const compile with extra/non-standard const
719 --without-develop disable development options
721 --with-pthread use POSIX thread library
722 --enable-weak-symbols enable weak-symbols for pthreads
723 --enable-reentrant compile with experimental reentrant code
724 --with-wrap-prefix=XXX override prefix used for public variables
725 Testing/development Options:
726 --disable-echo do not display "compiling" commands
727 --enable-warnings build: turn on GCC compiler warnings
728 --enable-assertions test: turn on generation of assertion code
729 --enable-expanded test: generate functions for certain macros
730 --disable-macros test: use functions rather than macros
731 --with-trace test: add trace() function to all models of ncurses
732 --disable-gnat-projects test: disable GNAT projects even if usable
733 Ada95 Binding Options:
734 --with-ada-compiler=CMD specify Ada95 compiler command (default gnatmake)
735 --with-ada-include=DIR Ada includes are in DIR (default: PREFIX/share/ada/adainclude)
736 --with-ada-objects=DIR Ada objects are in DIR (default: PREFIX/lib/ada/adalib)
737 --with-ada-sharedlib=soname build shared-library (requires GNAT projects)
739 Some influential environment variables:
740 CC C compiler command
741 CFLAGS C compiler flags
742 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
743 nonstandard directory <lib dir>
744 CPPFLAGS C/C++ preprocessor flags, e.g. -I<include dir> if you have
745 headers in a nonstandard directory <include dir>
748 Use these variables to override the choices made by `configure' or to help
749 it to find libraries and programs with nonstandard names/locations.
754 if test "$ac_init_help" = "recursive"; then
755 # If there are subdirs, report their specific --help.
757 for ac_subdir in : $ac_subdirs_all; do test "x$ac_subdir" = x: && continue
759 # A "../" for each directory in /$ac_subdir.
760 ac_dots=`echo $ac_subdir |
761 sed 's,^\./,,;s,[^/]$,&/,;s,[^/]*/,../,g'`
764 .) # No --srcdir option. We are building in place.
765 ac_sub_srcdir=$srcdir ;;
766 [\\/]* | ?:[\\/]* ) # Absolute path.
767 ac_sub_srcdir=$srcdir/$ac_subdir ;;
769 ac_sub_srcdir=$ac_dots$srcdir/$ac_subdir ;;
772 # Check for guested configure; otherwise get Cygnus style configure.
773 if test -f $ac_sub_srcdir/configure.gnu; then
775 $SHELL $ac_sub_srcdir/configure.gnu --help=recursive
776 elif test -f $ac_sub_srcdir/configure; then
778 $SHELL $ac_sub_srcdir/configure --help=recursive
779 elif test -f $ac_sub_srcdir/configure.ac ||
780 test -f $ac_sub_srcdir/configure.in; then
784 echo "$as_me: WARNING: no configuration information is in $ac_subdir" >&2
790 test -n "$ac_init_help" && exit 0
791 if $ac_init_version; then
794 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
795 Free Software Foundation, Inc.
796 This configure script is free software; the Free Software Foundation
797 gives unlimited permission to copy, distribute and modify it.
803 This file contains any messages produced by compilers while
804 running configure, to aid debugging if configure makes a mistake.
806 It was created by $as_me, which was
807 generated by GNU Autoconf 2.52.20170501. Invocation command line was
818 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
819 uname -m = `(uname -m) 2>/dev/null || echo unknown`
820 uname -r = `(uname -r) 2>/dev/null || echo unknown`
821 uname -s = `(uname -s) 2>/dev/null || echo unknown`
822 uname -v = `(uname -v) 2>/dev/null || echo unknown`
824 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
825 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
827 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
828 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
829 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
830 hostinfo = `(hostinfo) 2>/dev/null || echo unknown`
831 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
832 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
833 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
847 # Keep a trace of the command line.
848 # Strip out --no-create and --no-recursion so they do not pile up.
849 # Also quote any args containing shell meta-characters.
855 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
856 | --no-cr | --no-c) ;;
857 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
858 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
859 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
860 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"`
861 ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
863 *) ac_configure_args="$ac_configure_args$ac_sep$ac_arg"
866 # Get rid of the leading space.
869 # When interrupted or exit'd, cleanup temporary files, and complete
870 # config.log. We remove comments because anyway the quotes in there
871 # would cause problems or look ugly.
873 # Save into config.log some information that might help in debugging.
875 echo "## ----------------- ##" >&5
876 echo "## Cache variables. ##" >&5
877 echo "## ----------------- ##" >&5
879 # The following way of writing the cache mishandles newlines in values,
882 case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
885 "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
886 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
890 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
894 sed "/^$/d" confdefs.h >conftest.log
895 if test -s conftest.log; then
897 echo "## ------------ ##" >&5
898 echo "## confdefs.h. ##" >&5
899 echo "## ------------ ##" >&5
904 test "$ac_signal" != 0 &&
905 echo "$as_me: caught signal $ac_signal" >&5
906 echo "$as_me: exit $exit_status" >&5
907 rm -rf conftest* confdefs* core core.* *.core conf$$* $ac_clean_files &&
910 for ac_signal in 1 2 13 15; do
911 trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
915 # confdefs.h avoids OS command line length limits that DEFS can exceed.
916 rm -rf conftest* confdefs.h
917 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
920 # Let the site file select an alternate cache file if it wants to.
921 # Prefer explicitly selected file to automatically selected ones.
922 if test -z "$CONFIG_SITE"; then
923 if test "x$prefix" != xNONE; then
924 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
926 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
929 for ac_site_file in $CONFIG_SITE; do
930 if test -r "$ac_site_file"; then
931 { echo "$as_me:931: loading site script $ac_site_file" >&5
932 echo "$as_me: loading site script $ac_site_file" >&6;}
933 cat "$ac_site_file" >&5
938 if test -r "$cache_file"; then
939 # Some versions of bash will fail to source /dev/null (special
940 # files actually), so we avoid doing that.
941 if test -f "$cache_file"; then
942 { echo "$as_me:942: loading cache $cache_file" >&5
943 echo "$as_me: loading cache $cache_file" >&6;}
945 [\\/]* | ?:[\\/]* ) . $cache_file;;
950 { echo "$as_me:950: creating cache $cache_file" >&5
951 echo "$as_me: creating cache $cache_file" >&6;}
955 # Check that the precious variables saved in the cache have kept the same
957 ac_cache_corrupted=false
958 for ac_var in `(set) 2>&1 |
959 sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
960 eval ac_old_set=\$ac_cv_env_${ac_var}_set
961 eval ac_new_set=\$ac_env_${ac_var}_set
962 eval ac_old_val="\$ac_cv_env_${ac_var}_value"
963 eval ac_new_val="\$ac_env_${ac_var}_value"
964 case $ac_old_set,$ac_new_set in
966 { echo "$as_me:966: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
967 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
968 ac_cache_corrupted=: ;;
970 { echo "$as_me:970: error: \`$ac_var' was not set in the previous run" >&5
971 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
972 ac_cache_corrupted=: ;;
975 if test "x$ac_old_val" != "x$ac_new_val"; then
976 { echo "$as_me:976: error: \`$ac_var' has changed since the previous run:" >&5
977 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
978 { echo "$as_me:978: former value: $ac_old_val" >&5
979 echo "$as_me: former value: $ac_old_val" >&2;}
980 { echo "$as_me:980: current value: $ac_new_val" >&5
981 echo "$as_me: current value: $ac_new_val" >&2;}
985 # Pass precious variables to config.status. It doesn't matter if
986 # we pass some twice (in addition to the command line arguments).
987 if test "$ac_new_set" = set; then
989 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
990 ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"`
991 ac_configure_args="$ac_configure_args '$ac_arg'"
993 *) ac_configure_args="$ac_configure_args $ac_var=$ac_new_val"
998 if $ac_cache_corrupted; then
999 { echo "$as_me:999: error: changes in the environment can compromise the build" >&5
1000 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1001 { { echo "$as_me:1001: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1002 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1003 { (exit 1); exit 1; }; }
1007 ac_cpp='$CPP $CPPFLAGS'
1008 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1009 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1010 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1011 ac_main_return=return
1013 case `echo "testing\c" 2>/dev/null; echo 1,2,3`,`echo -n testing 2>/dev/null; echo 1,2,3` in
1014 *c*,-n*) ECHO_N= ECHO_C= # newlines do not sed ;-) only broken shells would use this case anyway
1016 *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
1017 *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
1019 echo "#! $SHELL" >conftest.sh
1020 echo "exit 0" >>conftest.sh
1021 chmod +x conftest.sh
1022 if { (echo "$as_me:1022: PATH=\".;.\"; conftest.sh") >&5
1023 (PATH=".;."; conftest.sh) 2>&5
1025 echo "$as_me:1025: \$? = $ac_status" >&5
1026 (exit $ac_status); }; then
1027 ac_path_separator=';'
1031 PATH_SEPARATOR="$ac_path_separator"
1034 ac_config_headers="$ac_config_headers include/ncurses_cfg.h:include/ncurses_cfg.hin"
1039 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
1040 if test -f $ac_dir/install-sh; then
1042 ac_install_sh="$ac_aux_dir/install-sh -c"
1044 elif test -f $ac_dir/install.sh; then
1046 ac_install_sh="$ac_aux_dir/install.sh -c"
1048 elif test -f $ac_dir/shtool; then
1050 ac_install_sh="$ac_aux_dir/shtool install -c"
1054 if test -z "$ac_aux_dir"; then
1055 { { echo "$as_me:1055: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
1056 echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
1057 { (exit 1); exit 1; }; }
1059 ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1060 ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1061 ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
1063 # Make sure we can run config.sub.
1064 $ac_config_sub sun4 >/dev/null 2>&1 ||
1065 { { echo "$as_me:1065: error: cannot run $ac_config_sub" >&5
1066 echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1067 { (exit 1); exit 1; }; }
1069 echo "$as_me:1069: checking build system type" >&5
1070 echo $ECHO_N "checking build system type... $ECHO_C" >&6
1071 if test "${ac_cv_build+set}" = set; then
1072 echo $ECHO_N "(cached) $ECHO_C" >&6
1074 ac_cv_build_alias=$build_alias
1075 test -z "$ac_cv_build_alias" &&
1076 ac_cv_build_alias=`$ac_config_guess`
1077 test -z "$ac_cv_build_alias" &&
1078 { { echo "$as_me:1078: error: cannot guess build type; you must specify one" >&5
1079 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1080 { (exit 1); exit 1; }; }
1081 ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
1082 { { echo "$as_me:1082: error: $ac_config_sub $ac_cv_build_alias failed." >&5
1083 echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed." >&2;}
1084 { (exit 1); exit 1; }; }
1087 echo "$as_me:1087: result: $ac_cv_build" >&5
1088 echo "${ECHO_T}$ac_cv_build" >&6
1090 build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1091 build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1092 build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1094 echo "$as_me:1094: checking host system type" >&5
1095 echo $ECHO_N "checking host system type... $ECHO_C" >&6
1096 if test "${ac_cv_host+set}" = set; then
1097 echo $ECHO_N "(cached) $ECHO_C" >&6
1099 ac_cv_host_alias=$host_alias
1100 test -z "$ac_cv_host_alias" &&
1101 ac_cv_host_alias=$ac_cv_build_alias
1102 ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
1103 { { echo "$as_me:1103: error: $ac_config_sub $ac_cv_host_alias failed" >&5
1104 echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1105 { (exit 1); exit 1; }; }
1108 echo "$as_me:1108: result: $ac_cv_host" >&5
1109 echo "${ECHO_T}$ac_cv_host" >&6
1111 host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1112 host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1113 host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1115 if test -f $srcdir/config.guess || test -f $ac_aux_dir/config.guess ; then
1116 echo "$as_me:1116: checking target system type" >&5
1117 echo $ECHO_N "checking target system type... $ECHO_C" >&6
1118 if test "${ac_cv_target+set}" = set; then
1119 echo $ECHO_N "(cached) $ECHO_C" >&6
1121 ac_cv_target_alias=$target_alias
1122 test "x$ac_cv_target_alias" = "x" &&
1123 ac_cv_target_alias=$ac_cv_host_alias
1124 ac_cv_target=`$ac_config_sub $ac_cv_target_alias` ||
1125 { { echo "$as_me:1125: error: $ac_config_sub $ac_cv_target_alias failed" >&5
1126 echo "$as_me: error: $ac_config_sub $ac_cv_target_alias failed" >&2;}
1127 { (exit 1); exit 1; }; }
1130 echo "$as_me:1130: result: $ac_cv_target" >&5
1131 echo "${ECHO_T}$ac_cv_target" >&6
1132 target=$ac_cv_target
1133 target_cpu=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1134 target_vendor=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1135 target_os=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1137 # The aliases save the names the user supplied, while $host etc.
1138 # will get canonicalized.
1139 test -n "$target_alias" &&
1140 test "$program_prefix$program_suffix$program_transform_name" = \
1142 program_prefix=${target_alias}-
1143 system_name="$host_os"
1145 system_name="`(uname -s -r) 2>/dev/null`"
1146 if test -z "$system_name" ; then
1147 system_name="`(hostname) 2>/dev/null`"
1150 test -n "$system_name" &&
1151 cat >>confdefs.h <<EOF
1152 #define SYSTEM_NAME "$system_name"
1155 if test "${cf_cv_system_name+set}" = set; then
1156 echo $ECHO_N "(cached) $ECHO_C" >&6
1158 cf_cv_system_name="$system_name"
1161 test -z "$system_name" && system_name="$cf_cv_system_name"
1162 test -n "$cf_cv_system_name" && echo "$as_me:1162: result: Configuring for $cf_cv_system_name" >&5
1163 echo "${ECHO_T}Configuring for $cf_cv_system_name" >&6
1165 if test ".$system_name" != ".$cf_cv_system_name" ; then
1166 echo "$as_me:1166: result: Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&5
1167 echo "${ECHO_T}Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&6
1168 { { echo "$as_me:1168: error: \"Please remove config.cache and try again.\"" >&5
1169 echo "$as_me: error: \"Please remove config.cache and try again.\"" >&2;}
1170 { (exit 1); exit 1; }; }
1173 # Check whether --with-system-type or --without-system-type was given.
1174 if test "${with_system_type+set}" = set; then
1175 withval="$with_system_type"
1176 { echo "$as_me:1176: WARNING: overriding system type to $withval" >&5
1177 echo "$as_me: WARNING: overriding system type to $withval" >&2;}
1178 cf_cv_system_name=$withval
1183 ### Save the given $CFLAGS to allow user-override.
1184 cf_user_CFLAGS="$CFLAGS"
1186 ### Default install-location
1188 echo "$as_me:1188: checking for prefix" >&5
1189 echo $ECHO_N "checking for prefix... $ECHO_C" >&6
1190 if test "x$prefix" = "xNONE" ; then
1191 case "$cf_cv_system_name" in
1192 # non-vendor systems don't have a conflict
1193 (openbsd*|freebsd*|mirbsd*|linux*|cygwin*|msys*|k*bsd*-gnu|mingw*)
1196 (*) prefix=$ac_default_prefix
1200 echo "$as_me:1200: result: $prefix" >&5
1201 echo "${ECHO_T}$prefix" >&6
1203 if test "x$prefix" = "xNONE" ; then
1204 echo "$as_me:1204: checking for default include-directory" >&5
1205 echo $ECHO_N "checking for default include-directory... $ECHO_C" >&6
1206 test -n "$verbose" && echo 1>&6
1209 $includedir/ncurses \
1211 $prefix/include/ncurses \
1212 /usr/local/include \
1213 /usr/local/include/ncurses \
1215 /usr/include/ncurses
1217 cf_dir=`eval echo $cf_symbol`
1218 if test -f $cf_dir/curses.h ; then
1219 if ( fgrep NCURSES_VERSION $cf_dir/curses.h 2>&1 >/dev/null ) ; then
1220 includedir="$cf_symbol"
1221 test -n "$verbose" && echo $ac_n " found " 1>&6
1225 test -n "$verbose" && echo " tested $cf_dir" 1>&6
1227 echo "$as_me:1227: result: $includedir" >&5
1228 echo "${ECHO_T}$includedir" >&6
1231 ### Checks for programs.
1234 ac_cpp='$CPP $CPPFLAGS'
1235 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1236 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1237 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1238 ac_main_return=return
1239 if test -n "$ac_tool_prefix"; then
1240 for ac_prog in gnatgcc gcc cc
1242 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
1243 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
1244 echo "$as_me:1244: checking for $ac_word" >&5
1245 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1246 if test "${ac_cv_prog_CC+set}" = set; then
1247 echo $ECHO_N "(cached) $ECHO_C" >&6
1249 if test -n "$CC"; then
1250 ac_cv_prog_CC="$CC" # Let the user override the test.
1252 ac_save_IFS=$IFS; IFS=$ac_path_separator
1254 for ac_dir in $ac_dummy; do
1256 test -z "$ac_dir" && ac_dir=.
1257 $as_executable_p "$ac_dir/$ac_word" || continue
1258 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
1259 echo "$as_me:1259: found $ac_dir/$ac_word" >&5
1266 if test -n "$CC"; then
1267 echo "$as_me:1267: result: $CC" >&5
1268 echo "${ECHO_T}$CC" >&6
1270 echo "$as_me:1270: result: no" >&5
1271 echo "${ECHO_T}no" >&6
1274 test -n "$CC" && break
1277 if test -z "$CC"; then
1279 for ac_prog in gnatgcc gcc cc
1281 # Extract the first word of "$ac_prog", so it can be a program name with args.
1282 set dummy $ac_prog; ac_word=$2
1283 echo "$as_me:1283: checking for $ac_word" >&5
1284 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1285 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1286 echo $ECHO_N "(cached) $ECHO_C" >&6
1288 if test -n "$ac_ct_CC"; then
1289 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1291 ac_save_IFS=$IFS; IFS=$ac_path_separator
1293 for ac_dir in $ac_dummy; do
1295 test -z "$ac_dir" && ac_dir=.
1296 $as_executable_p "$ac_dir/$ac_word" || continue
1297 ac_cv_prog_ac_ct_CC="$ac_prog"
1298 echo "$as_me:1298: found $ac_dir/$ac_word" >&5
1304 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1305 if test -n "$ac_ct_CC"; then
1306 echo "$as_me:1306: result: $ac_ct_CC" >&5
1307 echo "${ECHO_T}$ac_ct_CC" >&6
1309 echo "$as_me:1309: result: no" >&5
1310 echo "${ECHO_T}no" >&6
1313 test -n "$ac_ct_CC" && break
1319 test -z "$CC" && { { echo "$as_me:1319: error: no acceptable cc found in \$PATH" >&5
1320 echo "$as_me: error: no acceptable cc found in \$PATH" >&2;}
1321 { (exit 1); exit 1; }; }
1323 # Provide some information about the compiler.
1324 echo "$as_me:1324:" \
1325 "checking for C compiler version" >&5
1326 ac_compiler=`set X $ac_compile; echo $2`
1327 { (eval echo "$as_me:1327: \"$ac_compiler --version </dev/null >&5\"") >&5
1328 (eval $ac_compiler --version </dev/null >&5) 2>&5
1330 echo "$as_me:1330: \$? = $ac_status" >&5
1331 (exit $ac_status); }
1332 { (eval echo "$as_me:1332: \"$ac_compiler -v </dev/null >&5\"") >&5
1333 (eval $ac_compiler -v </dev/null >&5) 2>&5
1335 echo "$as_me:1335: \$? = $ac_status" >&5
1336 (exit $ac_status); }
1337 { (eval echo "$as_me:1337: \"$ac_compiler -V </dev/null >&5\"") >&5
1338 (eval $ac_compiler -V </dev/null >&5) 2>&5
1340 echo "$as_me:1340: \$? = $ac_status" >&5
1341 (exit $ac_status); }
1343 cat >conftest.$ac_ext <<_ACEOF
1344 #line 1344 "configure"
1345 #include "confdefs.h"
1355 ac_clean_files_save=$ac_clean_files
1356 ac_clean_files="$ac_clean_files a.out a.exe"
1357 # Try to create an executable without -o first, disregard a.out.
1358 # It will help us diagnose broken compilers, and finding out an intuition
1360 echo "$as_me:1360: checking for C compiler default output" >&5
1361 echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
1362 ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
1363 if { (eval echo "$as_me:1363: \"$ac_link_default\"") >&5
1364 (eval $ac_link_default) 2>&5
1366 echo "$as_me:1366: \$? = $ac_status" >&5
1367 (exit $ac_status); }; then
1368 # Find the output, starting from the most likely. This scheme is
1369 # not robust to junk in `.', hence go to wildcards (a.*) only as a last
1371 for ac_file in `ls a.exe conftest.exe 2>/dev/null;
1372 ls a.out conftest 2>/dev/null;
1373 ls a.* conftest.* 2>/dev/null`; do
1375 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1376 a.out ) # We found the default executable, but exeext='' is most
1379 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1380 # FIXME: I believe we export ac_cv_exeext for Libtool --akim.
1387 echo "$as_me: failed program was:" >&5
1388 cat conftest.$ac_ext >&5
1389 { { echo "$as_me:1389: error: C compiler cannot create executables" >&5
1390 echo "$as_me: error: C compiler cannot create executables" >&2;}
1391 { (exit 77); exit 77; }; }
1394 ac_exeext=$ac_cv_exeext
1395 echo "$as_me:1395: result: $ac_file" >&5
1396 echo "${ECHO_T}$ac_file" >&6
1398 # Check the compiler produces executables we can run. If not, either
1399 # the compiler is broken, or we cross compile.
1400 echo "$as_me:1400: checking whether the C compiler works" >&5
1401 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
1402 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
1403 # If not cross compiling, check that we can run a simple program.
1404 if test "$cross_compiling" != yes; then
1405 if { ac_try='./$ac_file'
1406 { (eval echo "$as_me:1406: \"$ac_try\"") >&5
1409 echo "$as_me:1409: \$? = $ac_status" >&5
1410 (exit $ac_status); }; }; then
1413 if test "$cross_compiling" = maybe; then
1416 { { echo "$as_me:1416: error: cannot run C compiled programs.
1417 If you meant to cross compile, use \`--host'." >&5
1418 echo "$as_me: error: cannot run C compiled programs.
1419 If you meant to cross compile, use \`--host'." >&2;}
1420 { (exit 1); exit 1; }; }
1424 echo "$as_me:1424: result: yes" >&5
1425 echo "${ECHO_T}yes" >&6
1427 rm -f a.out a.exe conftest$ac_cv_exeext
1428 ac_clean_files=$ac_clean_files_save
1429 # Check the compiler produces executables we can run. If not, either
1430 # the compiler is broken, or we cross compile.
1431 echo "$as_me:1431: checking whether we are cross compiling" >&5
1432 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
1433 echo "$as_me:1433: result: $cross_compiling" >&5
1434 echo "${ECHO_T}$cross_compiling" >&6
1436 echo "$as_me:1436: checking for executable suffix" >&5
1437 echo $ECHO_N "checking for executable suffix... $ECHO_C" >&6
1438 if { (eval echo "$as_me:1438: \"$ac_link\"") >&5
1439 (eval $ac_link) 2>&5
1441 echo "$as_me:1441: \$? = $ac_status" >&5
1442 (exit $ac_status); }; then
1443 # If both `conftest.exe' and `conftest' are `present' (well, observable)
1444 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
1445 # work properly (i.e., refer to `conftest.exe'), while it won't with
1447 for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do
1449 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1450 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1457 { { echo "$as_me:1457: error: cannot compute EXEEXT: cannot compile and link" >&5
1458 echo "$as_me: error: cannot compute EXEEXT: cannot compile and link" >&2;}
1459 { (exit 1); exit 1; }; }
1462 rm -f conftest$ac_cv_exeext
1463 echo "$as_me:1463: result: $ac_cv_exeext" >&5
1464 echo "${ECHO_T}$ac_cv_exeext" >&6
1466 rm -f conftest.$ac_ext
1467 EXEEXT=$ac_cv_exeext
1469 echo "$as_me:1469: checking for object suffix" >&5
1470 echo $ECHO_N "checking for object suffix... $ECHO_C" >&6
1471 if test "${ac_cv_objext+set}" = set; then
1472 echo $ECHO_N "(cached) $ECHO_C" >&6
1474 cat >conftest.$ac_ext <<_ACEOF
1475 #line 1475 "configure"
1476 #include "confdefs.h"
1486 rm -f conftest.o conftest.obj
1487 if { (eval echo "$as_me:1487: \"$ac_compile\"") >&5
1488 (eval $ac_compile) 2>&5
1490 echo "$as_me:1490: \$? = $ac_status" >&5
1491 (exit $ac_status); }; then
1492 for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
1494 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.map | *.inf ) ;;
1495 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
1500 echo "$as_me: failed program was:" >&5
1501 cat conftest.$ac_ext >&5
1502 { { echo "$as_me:1502: error: cannot compute OBJEXT: cannot compile" >&5
1503 echo "$as_me: error: cannot compute OBJEXT: cannot compile" >&2;}
1504 { (exit 1); exit 1; }; }
1507 rm -f conftest.$ac_cv_objext conftest.$ac_ext
1509 echo "$as_me:1509: result: $ac_cv_objext" >&5
1510 echo "${ECHO_T}$ac_cv_objext" >&6
1511 OBJEXT=$ac_cv_objext
1513 echo "$as_me:1513: checking whether we are using the GNU C compiler" >&5
1514 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
1515 if test "${ac_cv_c_compiler_gnu+set}" = set; then
1516 echo $ECHO_N "(cached) $ECHO_C" >&6
1518 cat >conftest.$ac_ext <<_ACEOF
1519 #line 1519 "configure"
1520 #include "confdefs.h"
1533 rm -f conftest.$ac_objext
1534 if { (eval echo "$as_me:1534: \"$ac_compile\"") >&5
1535 (eval $ac_compile) 2>&5
1537 echo "$as_me:1537: \$? = $ac_status" >&5
1538 (exit $ac_status); } &&
1539 { ac_try='test -s conftest.$ac_objext'
1540 { (eval echo "$as_me:1540: \"$ac_try\"") >&5
1543 echo "$as_me:1543: \$? = $ac_status" >&5
1544 (exit $ac_status); }; }; then
1547 echo "$as_me: failed program was:" >&5
1548 cat conftest.$ac_ext >&5
1551 rm -f conftest.$ac_objext conftest.$ac_ext
1552 ac_cv_c_compiler_gnu=$ac_compiler_gnu
1555 echo "$as_me:1555: result: $ac_cv_c_compiler_gnu" >&5
1556 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
1557 GCC=`test $ac_compiler_gnu = yes && echo yes`
1558 ac_test_CFLAGS=${CFLAGS+set}
1559 ac_save_CFLAGS=$CFLAGS
1561 echo "$as_me:1561: checking whether $CC accepts -g" >&5
1562 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
1563 if test "${ac_cv_prog_cc_g+set}" = set; then
1564 echo $ECHO_N "(cached) $ECHO_C" >&6
1566 cat >conftest.$ac_ext <<_ACEOF
1567 #line 1567 "configure"
1568 #include "confdefs.h"
1578 rm -f conftest.$ac_objext
1579 if { (eval echo "$as_me:1579: \"$ac_compile\"") >&5
1580 (eval $ac_compile) 2>&5
1582 echo "$as_me:1582: \$? = $ac_status" >&5
1583 (exit $ac_status); } &&
1584 { ac_try='test -s conftest.$ac_objext'
1585 { (eval echo "$as_me:1585: \"$ac_try\"") >&5
1588 echo "$as_me:1588: \$? = $ac_status" >&5
1589 (exit $ac_status); }; }; then
1592 echo "$as_me: failed program was:" >&5
1593 cat conftest.$ac_ext >&5
1596 rm -f conftest.$ac_objext conftest.$ac_ext
1598 echo "$as_me:1598: result: $ac_cv_prog_cc_g" >&5
1599 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
1600 if test "$ac_test_CFLAGS" = set; then
1601 CFLAGS=$ac_save_CFLAGS
1602 elif test $ac_cv_prog_cc_g = yes; then
1603 if test "$GCC" = yes; then
1609 if test "$GCC" = yes; then
1615 # Some people use a C++ compiler to compile C. Since we use `exit',
1616 # in C++ we need to declare it. In case someone uses the same compiler
1617 # for both compiling C and C++ we need to have the C++ compiler decide
1618 # the declaration of exit, since it's the most demanding environment.
1619 cat >conftest.$ac_ext <<_ACEOF
1624 rm -f conftest.$ac_objext
1625 if { (eval echo "$as_me:1625: \"$ac_compile\"") >&5
1626 (eval $ac_compile) 2>&5
1628 echo "$as_me:1628: \$? = $ac_status" >&5
1629 (exit $ac_status); } &&
1630 { ac_try='test -s conftest.$ac_objext'
1631 { (eval echo "$as_me:1631: \"$ac_try\"") >&5
1634 echo "$as_me:1634: \$? = $ac_status" >&5
1635 (exit $ac_status); }; }; then
1636 for ac_declaration in \
1638 '#include <stdlib.h>' \
1639 'extern "C" void std::exit (int) throw (); using std::exit;' \
1640 'extern "C" void std::exit (int); using std::exit;' \
1641 'extern "C" void exit (int) throw ();' \
1642 'extern "C" void exit (int);' \
1645 cat >conftest.$ac_ext <<_ACEOF
1646 #line 1646 "configure"
1647 #include "confdefs.h"
1658 rm -f conftest.$ac_objext
1659 if { (eval echo "$as_me:1659: \"$ac_compile\"") >&5
1660 (eval $ac_compile) 2>&5
1662 echo "$as_me:1662: \$? = $ac_status" >&5
1663 (exit $ac_status); } &&
1664 { ac_try='test -s conftest.$ac_objext'
1665 { (eval echo "$as_me:1665: \"$ac_try\"") >&5
1668 echo "$as_me:1668: \$? = $ac_status" >&5
1669 (exit $ac_status); }; }; then
1672 echo "$as_me: failed program was:" >&5
1673 cat conftest.$ac_ext >&5
1676 rm -f conftest.$ac_objext conftest.$ac_ext
1677 cat >conftest.$ac_ext <<_ACEOF
1678 #line 1678 "configure"
1679 #include "confdefs.h"
1689 rm -f conftest.$ac_objext
1690 if { (eval echo "$as_me:1690: \"$ac_compile\"") >&5
1691 (eval $ac_compile) 2>&5
1693 echo "$as_me:1693: \$? = $ac_status" >&5
1694 (exit $ac_status); } &&
1695 { ac_try='test -s conftest.$ac_objext'
1696 { (eval echo "$as_me:1696: \"$ac_try\"") >&5
1699 echo "$as_me:1699: \$? = $ac_status" >&5
1700 (exit $ac_status); }; }; then
1703 echo "$as_me: failed program was:" >&5
1704 cat conftest.$ac_ext >&5
1706 rm -f conftest.$ac_objext conftest.$ac_ext
1709 if test -n "$ac_declaration"; then
1710 echo '#ifdef __cplusplus' >>confdefs.h
1711 echo $ac_declaration >>confdefs.h
1712 echo '#endif' >>confdefs.h
1716 echo "$as_me: failed program was:" >&5
1717 cat conftest.$ac_ext >&5
1719 rm -f conftest.$ac_objext conftest.$ac_ext
1721 ac_cpp='$CPP $CPPFLAGS'
1722 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1723 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1724 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1725 ac_main_return=return
1728 if test "$GCC" = yes ; then
1729 echo "$as_me:1729: checking version of $CC" >&5
1730 echo $ECHO_N "checking version of $CC... $ECHO_C" >&6
1731 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.].*//'`"
1732 test -z "$GCC_VERSION" && GCC_VERSION=unknown
1733 echo "$as_me:1733: result: $GCC_VERSION" >&5
1734 echo "${ECHO_T}$GCC_VERSION" >&6
1737 echo "$as_me:1737: checking for $CC option to accept ANSI C" >&5
1738 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
1739 if test "${ac_cv_prog_cc_stdc+set}" = set; then
1740 echo $ECHO_N "(cached) $ECHO_C" >&6
1742 ac_cv_prog_cc_stdc=no
1744 cat >conftest.$ac_ext <<_ACEOF
1745 #line 1745 "configure"
1746 #include "confdefs.h"
1749 #include <sys/types.h>
1750 #include <sys/stat.h>
1751 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
1752 struct buf { int x; };
1753 FILE * (*rcsopen) (struct buf *, struct stat *, int);
1754 static char *e (p, i)
1760 static char *f (char * (*g) (char **, int), char **p, ...)
1765 s = g (p, va_arg (v,int));
1769 int test (int i, double x);
1770 struct s1 {int (*f) (int a);};
1771 struct s2 {int (*f) (double a);};
1772 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
1778 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
1783 # Don't try gcc -ansi; that turns off useful extensions and
1784 # breaks some systems' header files.
1785 # AIX -qlanglvl=ansi
1786 # Ultrix and OSF/1 -std1
1787 # HP-UX 10.20 and later -Ae
1788 # HP-UX older versions -Aa -D_HPUX_SOURCE
1789 # SVR4 -Xc -D__EXTENSIONS__
1790 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
1792 CC="$ac_save_CC $ac_arg"
1793 rm -f conftest.$ac_objext
1794 if { (eval echo "$as_me:1794: \"$ac_compile\"") >&5
1795 (eval $ac_compile) 2>&5
1797 echo "$as_me:1797: \$? = $ac_status" >&5
1798 (exit $ac_status); } &&
1799 { ac_try='test -s conftest.$ac_objext'
1800 { (eval echo "$as_me:1800: \"$ac_try\"") >&5
1803 echo "$as_me:1803: \$? = $ac_status" >&5
1804 (exit $ac_status); }; }; then
1805 ac_cv_prog_cc_stdc=$ac_arg
1808 echo "$as_me: failed program was:" >&5
1809 cat conftest.$ac_ext >&5
1811 rm -f conftest.$ac_objext
1813 rm -f conftest.$ac_ext conftest.$ac_objext
1818 case "x$ac_cv_prog_cc_stdc" in
1820 echo "$as_me:1820: result: none needed" >&5
1821 echo "${ECHO_T}none needed" >&6 ;;
1823 echo "$as_me:1823: result: $ac_cv_prog_cc_stdc" >&5
1824 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
1825 CC="$CC $ac_cv_prog_cc_stdc" ;;
1828 # This should have been defined by AC_PROG_CC
1831 echo "$as_me:1831: checking \$CC variable" >&5
1832 echo $ECHO_N "checking \$CC variable... $ECHO_C" >&6
1835 echo "$as_me:1835: result: broken" >&5
1836 echo "${ECHO_T}broken" >&6
1837 { echo "$as_me:1837: WARNING: your environment misuses the CC variable to hold CFLAGS/CPPFLAGS options" >&5
1838 echo "$as_me: WARNING: your environment misuses the CC variable to hold CFLAGS/CPPFLAGS options" >&2;}
1840 cf_prog=`echo "$CC" | sed -e 's/ / /g' -e 's/[ ]* / /g' -e 's/[ ]*[ ]-[^ ].*//'`
1841 cf_flags=`echo "$CC" | ${AWK:-awk} -v prog="$cf_prog" '{ printf("%s", substr($0,1+length(prog))); }'`
1843 for cf_arg in $cf_flags
1851 cf_new_extra_cppflags=
1853 for cf_add_cflags in $cf_arg
1855 case $cf_fix_cppflags in
1857 case $cf_add_cflags in
1858 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
1859 case $cf_add_cflags in
1861 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
1863 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
1864 && test -z "${cf_tst_cflags}" \
1865 && cf_fix_cppflags=yes
1867 if test $cf_fix_cppflags = yes ; then
1869 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
1870 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
1873 elif test "${cf_tst_cflags}" = "\"'" ; then
1875 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
1876 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
1886 case $cf_add_cflags in
1888 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
1890 CPPFLAGS=`echo "$CPPFLAGS" | \
1891 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
1892 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
1897 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
1898 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
1905 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
1906 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
1913 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
1914 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
1916 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
1918 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
1919 && test -z "${cf_tst_cflags}" \
1920 && cf_fix_cppflags=no
1925 if test -n "$cf_new_cflags" ; then
1927 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
1928 CFLAGS="${CFLAGS}$cf_new_cflags"
1932 if test -n "$cf_new_cppflags" ; then
1934 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
1935 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
1939 if test -n "$cf_new_extra_cppflags" ; then
1941 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
1942 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
1952 test -n "$verbose" && echo " resulting CC: '$CC'" 1>&6
1954 echo "${as_me:-configure}:1954: testing resulting CC: '$CC' ..." 1>&5
1956 test -n "$verbose" && echo " resulting CFLAGS: '$CFLAGS'" 1>&6
1958 echo "${as_me:-configure}:1958: testing resulting CFLAGS: '$CFLAGS' ..." 1>&5
1960 test -n "$verbose" && echo " resulting CPPFLAGS: '$CPPFLAGS'" 1>&6
1962 echo "${as_me:-configure}:1962: testing resulting CPPFLAGS: '$CPPFLAGS' ..." 1>&5
1966 echo "$as_me:1966: result: ok" >&5
1967 echo "${ECHO_T}ok" >&6
1972 ac_cpp='$CPP $CPPFLAGS'
1973 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1974 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1975 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1976 ac_main_return=return
1977 echo "$as_me:1977: checking how to run the C preprocessor" >&5
1978 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
1979 # On Suns, sometimes $CPP names a directory.
1980 if test -n "$CPP" && test -d "$CPP"; then
1983 if test -z "$CPP"; then
1984 if test "${ac_cv_prog_CPP+set}" = set; then
1985 echo $ECHO_N "(cached) $ECHO_C" >&6
1987 # Double quotes because CPP needs to be expanded
1988 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
1991 for ac_c_preproc_warn_flag in '' yes
1993 # Use a header file that comes with gcc, so configuring glibc
1994 # with a fresh cross-compiler works.
1995 # On the NeXT, cc -E runs the code through the compiler's parser,
1996 # not just through cpp. "Syntax error" is here to catch this case.
1997 cat >conftest.$ac_ext <<_ACEOF
1998 #line 1998 "configure"
1999 #include "confdefs.h"
2003 if { (eval echo "$as_me:2003: \"$ac_cpp conftest.$ac_ext\"") >&5
2004 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2006 egrep -v '^ *\+' conftest.er1 >conftest.err
2008 cat conftest.err >&5
2009 echo "$as_me:2009: \$? = $ac_status" >&5
2010 (exit $ac_status); } >/dev/null; then
2011 if test -s conftest.err; then
2012 ac_cpp_err=$ac_c_preproc_warn_flag
2019 if test -z "$ac_cpp_err"; then
2022 echo "$as_me: failed program was:" >&5
2023 cat conftest.$ac_ext >&5
2024 # Broken: fails on valid input.
2027 rm -f conftest.err conftest.$ac_ext
2029 # OK, works on sane cases. Now check whether non-existent headers
2030 # can be detected and how.
2031 cat >conftest.$ac_ext <<_ACEOF
2032 #line 2032 "configure"
2033 #include "confdefs.h"
2034 #include <ac_nonexistent.h>
2036 if { (eval echo "$as_me:2036: \"$ac_cpp conftest.$ac_ext\"") >&5
2037 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2039 egrep -v '^ *\+' conftest.er1 >conftest.err
2041 cat conftest.err >&5
2042 echo "$as_me:2042: \$? = $ac_status" >&5
2043 (exit $ac_status); } >/dev/null; then
2044 if test -s conftest.err; then
2045 ac_cpp_err=$ac_c_preproc_warn_flag
2052 if test -z "$ac_cpp_err"; then
2053 # Broken: success on invalid input.
2056 echo "$as_me: failed program was:" >&5
2057 cat conftest.$ac_ext >&5
2058 # Passes both tests.
2062 rm -f conftest.err conftest.$ac_ext
2065 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2066 rm -f conftest.err conftest.$ac_ext
2067 if $ac_preproc_ok; then
2079 echo "$as_me:2079: result: $CPP" >&5
2080 echo "${ECHO_T}$CPP" >&6
2082 for ac_c_preproc_warn_flag in '' yes
2084 # Use a header file that comes with gcc, so configuring glibc
2085 # with a fresh cross-compiler works.
2086 # On the NeXT, cc -E runs the code through the compiler's parser,
2087 # not just through cpp. "Syntax error" is here to catch this case.
2088 cat >conftest.$ac_ext <<_ACEOF
2089 #line 2089 "configure"
2090 #include "confdefs.h"
2094 if { (eval echo "$as_me:2094: \"$ac_cpp conftest.$ac_ext\"") >&5
2095 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2097 egrep -v '^ *\+' conftest.er1 >conftest.err
2099 cat conftest.err >&5
2100 echo "$as_me:2100: \$? = $ac_status" >&5
2101 (exit $ac_status); } >/dev/null; then
2102 if test -s conftest.err; then
2103 ac_cpp_err=$ac_c_preproc_warn_flag
2110 if test -z "$ac_cpp_err"; then
2113 echo "$as_me: failed program was:" >&5
2114 cat conftest.$ac_ext >&5
2115 # Broken: fails on valid input.
2118 rm -f conftest.err conftest.$ac_ext
2120 # OK, works on sane cases. Now check whether non-existent headers
2121 # can be detected and how.
2122 cat >conftest.$ac_ext <<_ACEOF
2123 #line 2123 "configure"
2124 #include "confdefs.h"
2125 #include <ac_nonexistent.h>
2127 if { (eval echo "$as_me:2127: \"$ac_cpp conftest.$ac_ext\"") >&5
2128 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2130 egrep -v '^ *\+' conftest.er1 >conftest.err
2132 cat conftest.err >&5
2133 echo "$as_me:2133: \$? = $ac_status" >&5
2134 (exit $ac_status); } >/dev/null; then
2135 if test -s conftest.err; then
2136 ac_cpp_err=$ac_c_preproc_warn_flag
2143 if test -z "$ac_cpp_err"; then
2144 # Broken: success on invalid input.
2147 echo "$as_me: failed program was:" >&5
2148 cat conftest.$ac_ext >&5
2149 # Passes both tests.
2153 rm -f conftest.err conftest.$ac_ext
2156 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2157 rm -f conftest.err conftest.$ac_ext
2158 if $ac_preproc_ok; then
2161 { { echo "$as_me:2161: error: C preprocessor \"$CPP\" fails sanity check" >&5
2162 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;}
2163 { (exit 1); exit 1; }; }
2167 ac_cpp='$CPP $CPPFLAGS'
2168 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2169 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2170 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2171 ac_main_return=return
2173 if test $ac_cv_c_compiler_gnu = yes; then
2174 echo "$as_me:2174: checking whether $CC needs -traditional" >&5
2175 echo $ECHO_N "checking whether $CC needs -traditional... $ECHO_C" >&6
2176 if test "${ac_cv_prog_gcc_traditional+set}" = set; then
2177 echo $ECHO_N "(cached) $ECHO_C" >&6
2179 ac_pattern="Autoconf.*'x'"
2180 cat >conftest.$ac_ext <<_ACEOF
2181 #line 2181 "configure"
2182 #include "confdefs.h"
2184 int Autoconf = TIOCGETP;
2186 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2187 egrep "$ac_pattern" >/dev/null 2>&1; then
2188 ac_cv_prog_gcc_traditional=yes
2190 ac_cv_prog_gcc_traditional=no
2194 if test $ac_cv_prog_gcc_traditional = no; then
2195 cat >conftest.$ac_ext <<_ACEOF
2196 #line 2196 "configure"
2197 #include "confdefs.h"
2199 int Autoconf = TCGETA;
2201 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2202 egrep "$ac_pattern" >/dev/null 2>&1; then
2203 ac_cv_prog_gcc_traditional=yes
2209 echo "$as_me:2209: result: $ac_cv_prog_gcc_traditional" >&5
2210 echo "${ECHO_T}$ac_cv_prog_gcc_traditional" >&6
2211 if test $ac_cv_prog_gcc_traditional = yes; then
2212 CC="$CC -traditional"
2216 echo "$as_me:2216: checking whether $CC understands -c and -o together" >&5
2217 echo $ECHO_N "checking whether $CC understands -c and -o together... $ECHO_C" >&6
2218 if test "${cf_cv_prog_CC_c_o+set}" = set; then
2219 echo $ECHO_N "(cached) $ECHO_C" >&6
2222 cat > conftest.$ac_ext <<CF_EOF
2225 ${cf_cv_main_return:-return}(0);
2228 # We do the test twice because some compilers refuse to overwrite an
2229 # existing .o file with -o, though they will create one.
2230 ac_try='$CC $CFLAGS $CPPFLAGS -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
2231 if { (eval echo "$as_me:2231: \"$ac_try\"") >&5
2234 echo "$as_me:2234: \$? = $ac_status" >&5
2235 (exit $ac_status); } &&
2236 test -f conftest2.$ac_objext && { (eval echo "$as_me:2236: \"$ac_try\"") >&5
2239 echo "$as_me:2239: \$? = $ac_status" >&5
2240 (exit $ac_status); };
2242 eval cf_cv_prog_CC_c_o=yes
2244 eval cf_cv_prog_CC_c_o=no
2249 if test $cf_cv_prog_CC_c_o = yes; then
2250 echo "$as_me:2250: result: yes" >&5
2251 echo "${ECHO_T}yes" >&6
2253 echo "$as_me:2253: result: no" >&5
2254 echo "${ECHO_T}no" >&6
2257 test "$program_prefix" != NONE &&
2258 program_transform_name="s,^,$program_prefix,;$program_transform_name"
2259 # Use a double $ so make ignores it.
2260 test "$program_suffix" != NONE &&
2261 program_transform_name="s,\$,$program_suffix,;$program_transform_name"
2262 # Double any \ or $. echo might interpret backslashes.
2263 # By default was `s,x,x', remove it if useless.
2264 cat <<\_ACEOF >conftest.sed
2265 s/[\\$]/&&/g;s/;s,x,x,$//
2267 program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
2270 for ac_prog in mawk gawk nawk awk
2272 # Extract the first word of "$ac_prog", so it can be a program name with args.
2273 set dummy $ac_prog; ac_word=$2
2274 echo "$as_me:2274: checking for $ac_word" >&5
2275 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2276 if test "${ac_cv_prog_AWK+set}" = set; then
2277 echo $ECHO_N "(cached) $ECHO_C" >&6
2279 if test -n "$AWK"; then
2280 ac_cv_prog_AWK="$AWK" # Let the user override the test.
2282 ac_save_IFS=$IFS; IFS=$ac_path_separator
2284 for ac_dir in $ac_dummy; do
2286 test -z "$ac_dir" && ac_dir=.
2287 $as_executable_p "$ac_dir/$ac_word" || continue
2288 ac_cv_prog_AWK="$ac_prog"
2289 echo "$as_me:2289: found $ac_dir/$ac_word" >&5
2296 if test -n "$AWK"; then
2297 echo "$as_me:2297: result: $AWK" >&5
2298 echo "${ECHO_T}$AWK" >&6
2300 echo "$as_me:2300: result: no" >&5
2301 echo "${ECHO_T}no" >&6
2304 test -n "$AWK" && break
2307 test -z "$AWK" && { { echo "$as_me:2307: error: No awk program found" >&5
2308 echo "$as_me: error: No awk program found" >&2;}
2309 { (exit 1); exit 1; }; }
2311 echo "$as_me:2311: checking for egrep" >&5
2312 echo $ECHO_N "checking for egrep... $ECHO_C" >&6
2313 if test "${ac_cv_prog_egrep+set}" = set; then
2314 echo $ECHO_N "(cached) $ECHO_C" >&6
2316 if echo a | (grep -E '(a|b)') >/dev/null 2>&1
2317 then ac_cv_prog_egrep='grep -E'
2318 else ac_cv_prog_egrep='egrep'
2321 echo "$as_me:2321: result: $ac_cv_prog_egrep" >&5
2322 echo "${ECHO_T}$ac_cv_prog_egrep" >&6
2323 EGREP=$ac_cv_prog_egrep
2325 test -z "$EGREP" && { { echo "$as_me:2325: error: No egrep program found" >&5
2326 echo "$as_me: error: No egrep program found" >&2;}
2327 { (exit 1); exit 1; }; }
2329 # Find a good install program. We prefer a C program (faster),
2330 # so one script is as good as another. But avoid the broken or
2331 # incompatible versions:
2332 # SysV /etc/install, /usr/sbin/install
2333 # SunOS /usr/etc/install
2334 # IRIX /sbin/install
2336 # AmigaOS /C/install, which installs bootblocks on floppy discs
2337 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
2338 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
2339 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
2340 # ./install, which can be erroneously created by make from ./install.sh.
2341 echo "$as_me:2341: checking for a BSD compatible install" >&5
2342 echo $ECHO_N "checking for a BSD compatible install... $ECHO_C" >&6
2343 if test -z "$INSTALL"; then
2344 if test "${ac_cv_path_install+set}" = set; then
2345 echo $ECHO_N "(cached) $ECHO_C" >&6
2347 ac_save_IFS=$IFS; IFS=$ac_path_separator
2348 for ac_dir in $PATH; do
2350 # Account for people who put trailing slashes in PATH elements.
2352 / | ./ | .// | /cC/* \
2353 | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* \
2356 # OSF1 and SCO ODT 3.0 have their own names for install.
2357 # Don't use installbsd from OSF since it installs stuff as root
2359 for ac_prog in ginstall scoinst install; do
2360 if $as_executable_p "$ac_dir/$ac_prog"; then
2361 if test $ac_prog = install &&
2362 grep dspmsg "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2363 # AIX install. It has an incompatible calling convention.
2365 elif test $ac_prog = install &&
2366 grep pwplus "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2367 # program-specific install script used by HP pwplus--don't use.
2370 ac_cv_path_install="$ac_dir/$ac_prog -c"
2380 if test "${ac_cv_path_install+set}" = set; then
2381 INSTALL=$ac_cv_path_install
2383 # As a last resort, use the slow shell script. We don't cache a
2384 # path for INSTALL within a source directory, because that will
2385 # break other packages using the cache if that directory is
2386 # removed, or if the path is relative.
2387 INSTALL=$ac_install_sh
2390 echo "$as_me:2390: result: $INSTALL" >&5
2391 echo "${ECHO_T}$INSTALL" >&6
2393 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
2394 # It thinks the first close brace ends the variable substitution.
2395 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
2397 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
2399 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
2401 echo "$as_me:2401: checking whether ln -s works" >&5
2402 echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
2404 if test "$LN_S" = "ln -s"; then
2405 echo "$as_me:2405: result: yes" >&5
2406 echo "${ECHO_T}yes" >&6
2408 echo "$as_me:2408: result: no, using $LN_S" >&5
2409 echo "${ECHO_T}no, using $LN_S" >&6
2412 echo "$as_me:2412: checking if $LN_S -f options work" >&5
2413 echo $ECHO_N "checking if $LN_S -f options work... $ECHO_C" >&6
2415 rm -f conf$$.src conf$$dst
2417 echo first >conf$$.src
2418 if $LN_S -f conf$$.src conf$$.dst 2>/dev/null; then
2423 rm -f conf$$.dst conf$$src
2424 echo "$as_me:2424: result: $cf_prog_ln_sf" >&5
2425 echo "${ECHO_T}$cf_prog_ln_sf" >&6
2427 test "$cf_prog_ln_sf" = yes && LN_S="$LN_S -f"
2429 echo "$as_me:2429: checking for long file names" >&5
2430 echo $ECHO_N "checking for long file names... $ECHO_C" >&6
2431 if test "${ac_cv_sys_long_file_names+set}" = set; then
2432 echo $ECHO_N "(cached) $ECHO_C" >&6
2434 ac_cv_sys_long_file_names=yes
2435 # Test for long file names in all the places we know might matter:
2436 # . the current directory, where building will happen
2437 # $prefix/lib where we will be installing things
2438 # $exec_prefix/lib likewise
2439 # eval it to expand exec_prefix.
2440 # $TMPDIR if set, where it might want to write temporary files
2441 # if $TMPDIR is not set:
2442 # /tmp where it might want to write temporary files
2445 if test -n "$TMPDIR" && test -d "$TMPDIR" && test -w "$TMPDIR"; then
2448 ac_tmpdirs='/tmp /var/tmp /usr/tmp'
2450 for ac_dir in . $ac_tmpdirs `eval echo $prefix/lib $exec_prefix/lib` ; do
2451 test -d $ac_dir || continue
2452 test -w $ac_dir || continue # It is less confusing to not echo anything here.
2453 ac_xdir=$ac_dir/cf$$
2454 (umask 077 && mkdir $ac_xdir 2>/dev/null) || continue
2455 ac_tf1=$ac_xdir/conftest9012345
2456 ac_tf2=$ac_xdir/conftest9012346
2457 (echo 1 >$ac_tf1) 2>/dev/null
2458 (echo 2 >$ac_tf2) 2>/dev/null
2459 ac_val=`cat $ac_tf1 2>/dev/null`
2460 if test ! -f $ac_tf1 || test "$ac_val" != 1; then
2461 ac_cv_sys_long_file_names=no
2462 rm -rf $ac_xdir 2>/dev/null
2465 rm -rf $ac_xdir 2>/dev/null
2468 echo "$as_me:2468: result: $ac_cv_sys_long_file_names" >&5
2469 echo "${ECHO_T}$ac_cv_sys_long_file_names" >&6
2470 if test $ac_cv_sys_long_file_names = yes; then
2472 cat >>confdefs.h <<\EOF
2473 #define HAVE_LONG_FILE_NAMES 1
2478 # if we find pkg-config, check if we should install the ".pc" files.
2480 echo "$as_me:2480: checking if you want to use pkg-config" >&5
2481 echo $ECHO_N "checking if you want to use pkg-config... $ECHO_C" >&6
2483 # Check whether --with-pkg-config or --without-pkg-config was given.
2484 if test "${with_pkg_config+set}" = set; then
2485 withval="$with_pkg_config"
2486 cf_pkg_config=$withval
2490 echo "$as_me:2490: result: $cf_pkg_config" >&5
2491 echo "${ECHO_T}$cf_pkg_config" >&6
2493 case $cf_pkg_config in
2499 if test -n "$ac_tool_prefix"; then
2500 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
2501 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
2502 echo "$as_me:2502: checking for $ac_word" >&5
2503 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2504 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then
2505 echo $ECHO_N "(cached) $ECHO_C" >&6
2509 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
2512 ac_save_IFS=$IFS; IFS=$ac_path_separator
2514 for ac_dir in $ac_dummy; do
2516 test -z "$ac_dir" && ac_dir=.
2517 if $as_executable_p "$ac_dir/$ac_word"; then
2518 ac_cv_path_PKG_CONFIG="$ac_dir/$ac_word"
2519 echo "$as_me:2519: found $ac_dir/$ac_word" >&5
2527 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
2529 if test -n "$PKG_CONFIG"; then
2530 echo "$as_me:2530: result: $PKG_CONFIG" >&5
2531 echo "${ECHO_T}$PKG_CONFIG" >&6
2533 echo "$as_me:2533: result: no" >&5
2534 echo "${ECHO_T}no" >&6
2538 if test -z "$ac_cv_path_PKG_CONFIG"; then
2539 ac_pt_PKG_CONFIG=$PKG_CONFIG
2540 # Extract the first word of "pkg-config", so it can be a program name with args.
2541 set dummy pkg-config; ac_word=$2
2542 echo "$as_me:2542: checking for $ac_word" >&5
2543 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2544 if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then
2545 echo $ECHO_N "(cached) $ECHO_C" >&6
2547 case $ac_pt_PKG_CONFIG in
2549 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
2552 ac_save_IFS=$IFS; IFS=$ac_path_separator
2554 for ac_dir in $ac_dummy; do
2556 test -z "$ac_dir" && ac_dir=.
2557 if $as_executable_p "$ac_dir/$ac_word"; then
2558 ac_cv_path_ac_pt_PKG_CONFIG="$ac_dir/$ac_word"
2559 echo "$as_me:2559: found $ac_dir/$ac_word" >&5
2564 test -z "$ac_cv_path_ac_pt_PKG_CONFIG" && ac_cv_path_ac_pt_PKG_CONFIG="none"
2568 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
2570 if test -n "$ac_pt_PKG_CONFIG"; then
2571 echo "$as_me:2571: result: $ac_pt_PKG_CONFIG" >&5
2572 echo "${ECHO_T}$ac_pt_PKG_CONFIG" >&6
2574 echo "$as_me:2574: result: no" >&5
2575 echo "${ECHO_T}no" >&6
2578 PKG_CONFIG=$ac_pt_PKG_CONFIG
2580 PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
2589 test -z "$PKG_CONFIG" && PKG_CONFIG=none
2590 if test "$PKG_CONFIG" != none ; then
2592 if test "x$prefix" != xNONE; then
2593 cf_path_syntax="$prefix"
2595 cf_path_syntax="$ac_default_prefix"
2598 case ".$PKG_CONFIG" in
2603 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
2605 (.\${*prefix}*|.\${*dir}*)
2606 eval PKG_CONFIG="$PKG_CONFIG"
2607 case ".$PKG_CONFIG" in
2609 PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
2614 PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
2617 { { echo "$as_me:2617: error: expected a pathname, not \"$PKG_CONFIG\"" >&5
2618 echo "$as_me: error: expected a pathname, not \"$PKG_CONFIG\"" >&2;}
2619 { (exit 1); exit 1; }; }
2623 elif test "x$cf_pkg_config" != xno ; then
2624 { echo "$as_me:2624: WARNING: pkg-config is not installed" >&5
2625 echo "$as_me: WARNING: pkg-config is not installed" >&2;}
2630 echo "$as_me:2630: checking for pkg-config library directory" >&5
2631 echo $ECHO_N "checking for pkg-config library directory... $ECHO_C" >&6
2634 echo "$as_me:2634: checking for $PKG_CONFIG library directory" >&5
2635 echo $ECHO_N "checking for $PKG_CONFIG library directory... $ECHO_C" >&6
2639 PKG_CONFIG_LIBDIR=no
2641 # Check whether --with-pkg-config-libdir or --without-pkg-config-libdir was given.
2642 if test "${with_pkg_config_libdir+set}" = set; then
2643 withval="$with_pkg_config_libdir"
2644 PKG_CONFIG_LIBDIR=$withval
2646 test "x$PKG_CONFIG" != xnone && PKG_CONFIG_LIBDIR=yes
2649 case x$PKG_CONFIG_LIBDIR in
2653 # Look for the library directory using the same prefix as the executable
2654 if test "x$PKG_CONFIG" = xnone
2658 cf_path=`echo "$PKG_CONFIG" | sed -e 's,/[^/]*/[^/]*$,,'`
2661 # If you don't like using the default architecture, you have to specify the
2662 # intended library directory and corresponding compiler/linker options.
2664 # This case allows for Debian's 2014-flavor of multiarch, along with the
2665 # most common variations before that point. Some other variants spell the
2666 # directory differently, e.g., "pkg-config", and put it in unusual places.
2667 # pkg-config has always been poorly standardized, which is ironic...
2668 case x`(arch) 2>/dev/null` in
2671 $cf_path/lib/*64-linux-gnu \
2679 $cf_path/lib/*-linux-gnu \
2687 test -n "$verbose" && echo " list..." 1>&6
2689 echo "${as_me:-configure}:2689: testing list... ..." 1>&5
2691 for cf_config in $cf_search_path
2693 test -n "$verbose" && echo " checking $cf_config/pkgconfig" 1>&6
2695 echo "${as_me:-configure}:2695: testing checking $cf_config/pkgconfig ..." 1>&5
2697 if test -d $cf_config/pkgconfig
2699 PKG_CONFIG_LIBDIR=$cf_config/pkgconfig
2700 echo "$as_me:2700: checking done" >&5
2701 echo $ECHO_N "checking done... $ECHO_C" >&6
2710 if test "x$PKG_CONFIG_LIBDIR" != xno ; then
2711 echo "$as_me:2711: result: $PKG_CONFIG_LIBDIR" >&5
2712 echo "${ECHO_T}$PKG_CONFIG_LIBDIR" >&6
2715 echo "$as_me:2715: checking if you want to build test-programs" >&5
2716 echo $ECHO_N "checking if you want to build test-programs... $ECHO_C" >&6
2718 # Check whether --with-tests or --without-tests was given.
2719 if test "${with_tests+set}" = set; then
2720 withval="$with_tests"
2721 cf_with_tests=$withval
2725 echo "$as_me:2725: result: $cf_with_tests" >&5
2726 echo "${ECHO_T}$cf_with_tests" >&6
2728 echo "$as_me:2728: checking if we should assume mixed-case filenames" >&5
2729 echo $ECHO_N "checking if we should assume mixed-case filenames... $ECHO_C" >&6
2731 # Check whether --enable-mixed-case or --disable-mixed-case was given.
2732 if test "${enable_mixed_case+set}" = set; then
2733 enableval="$enable_mixed_case"
2734 enable_mixedcase=$enableval
2736 enable_mixedcase=auto
2738 echo "$as_me:2738: result: $enable_mixedcase" >&5
2739 echo "${ECHO_T}$enable_mixedcase" >&6
2740 if test "$enable_mixedcase" = "auto" ; then
2742 echo "$as_me:2742: checking if filesystem supports mixed-case filenames" >&5
2743 echo $ECHO_N "checking if filesystem supports mixed-case filenames... $ECHO_C" >&6
2744 if test "${cf_cv_mixedcase+set}" = set; then
2745 echo $ECHO_N "(cached) $ECHO_C" >&6
2748 if test "$cross_compiling" = yes ; then
2749 case $target_alias in
2750 (*-os2-emx*|*-msdosdjgpp*|*-cygwin*|*-msys*|*-mingw*|*-uwin*)
2758 rm -f conftest CONFTEST
2760 if test -f CONFTEST ; then
2765 rm -f conftest CONFTEST
2769 echo "$as_me:2769: result: $cf_cv_mixedcase" >&5
2770 echo "${ECHO_T}$cf_cv_mixedcase" >&6
2771 test "$cf_cv_mixedcase" = yes &&
2772 cat >>confdefs.h <<\EOF
2773 #define MIXEDCASE_FILENAMES 1
2777 cf_cv_mixedcase=$enable_mixedcase
2778 if test "$enable_mixedcase" = "yes" ; then
2779 cat >>confdefs.h <<\EOF
2780 #define MIXEDCASE_FILENAMES 1
2786 # do this after mixed-case option (tags/TAGS is not as important as tic).
2787 echo "$as_me:2787: checking whether ${MAKE-make} sets \${MAKE}" >&5
2788 echo $ECHO_N "checking whether ${MAKE-make} sets \${MAKE}... $ECHO_C" >&6
2789 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,./+-,__p_,'`
2790 if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
2791 echo $ECHO_N "(cached) $ECHO_C" >&6
2793 cat >conftest.make <<\EOF
2795 @echo 'ac_maketemp="${MAKE}"'
2797 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
2798 eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
2799 if test -n "$ac_maketemp"; then
2800 eval ac_cv_prog_make_${ac_make}_set=yes
2802 eval ac_cv_prog_make_${ac_make}_set=no
2806 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
2807 echo "$as_me:2807: result: yes" >&5
2808 echo "${ECHO_T}yes" >&6
2811 echo "$as_me:2811: result: no" >&5
2812 echo "${ECHO_T}no" >&6
2813 SET_MAKE="MAKE=${MAKE-make}"
2816 for ac_prog in exctags ctags
2818 # Extract the first word of "$ac_prog", so it can be a program name with args.
2819 set dummy $ac_prog; ac_word=$2
2820 echo "$as_me:2820: checking for $ac_word" >&5
2821 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2822 if test "${ac_cv_prog_CTAGS+set}" = set; then
2823 echo $ECHO_N "(cached) $ECHO_C" >&6
2825 if test -n "$CTAGS"; then
2826 ac_cv_prog_CTAGS="$CTAGS" # Let the user override the test.
2828 ac_save_IFS=$IFS; IFS=$ac_path_separator
2830 for ac_dir in $ac_dummy; do
2832 test -z "$ac_dir" && ac_dir=.
2833 $as_executable_p "$ac_dir/$ac_word" || continue
2834 ac_cv_prog_CTAGS="$ac_prog"
2835 echo "$as_me:2835: found $ac_dir/$ac_word" >&5
2841 CTAGS=$ac_cv_prog_CTAGS
2842 if test -n "$CTAGS"; then
2843 echo "$as_me:2843: result: $CTAGS" >&5
2844 echo "${ECHO_T}$CTAGS" >&6
2846 echo "$as_me:2846: result: no" >&5
2847 echo "${ECHO_T}no" >&6
2850 test -n "$CTAGS" && break
2853 for ac_prog in exetags etags
2855 # Extract the first word of "$ac_prog", so it can be a program name with args.
2856 set dummy $ac_prog; ac_word=$2
2857 echo "$as_me:2857: checking for $ac_word" >&5
2858 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2859 if test "${ac_cv_prog_ETAGS+set}" = set; then
2860 echo $ECHO_N "(cached) $ECHO_C" >&6
2862 if test -n "$ETAGS"; then
2863 ac_cv_prog_ETAGS="$ETAGS" # Let the user override the test.
2865 ac_save_IFS=$IFS; IFS=$ac_path_separator
2867 for ac_dir in $ac_dummy; do
2869 test -z "$ac_dir" && ac_dir=.
2870 $as_executable_p "$ac_dir/$ac_word" || continue
2871 ac_cv_prog_ETAGS="$ac_prog"
2872 echo "$as_me:2872: found $ac_dir/$ac_word" >&5
2878 ETAGS=$ac_cv_prog_ETAGS
2879 if test -n "$ETAGS"; then
2880 echo "$as_me:2880: result: $ETAGS" >&5
2881 echo "${ECHO_T}$ETAGS" >&6
2883 echo "$as_me:2883: result: no" >&5
2884 echo "${ECHO_T}no" >&6
2887 test -n "$ETAGS" && break
2890 # Extract the first word of "${CTAGS:-ctags}", so it can be a program name with args.
2891 set dummy ${CTAGS:-ctags}; ac_word=$2
2892 echo "$as_me:2892: checking for $ac_word" >&5
2893 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2894 if test "${ac_cv_prog_MAKE_LOWER_TAGS+set}" = set; then
2895 echo $ECHO_N "(cached) $ECHO_C" >&6
2897 if test -n "$MAKE_LOWER_TAGS"; then
2898 ac_cv_prog_MAKE_LOWER_TAGS="$MAKE_LOWER_TAGS" # Let the user override the test.
2900 ac_save_IFS=$IFS; IFS=$ac_path_separator
2902 for ac_dir in $ac_dummy; do
2904 test -z "$ac_dir" && ac_dir=.
2905 $as_executable_p "$ac_dir/$ac_word" || continue
2906 ac_cv_prog_MAKE_LOWER_TAGS="yes"
2907 echo "$as_me:2907: found $ac_dir/$ac_word" >&5
2911 test -z "$ac_cv_prog_MAKE_LOWER_TAGS" && ac_cv_prog_MAKE_LOWER_TAGS="no"
2914 MAKE_LOWER_TAGS=$ac_cv_prog_MAKE_LOWER_TAGS
2915 if test -n "$MAKE_LOWER_TAGS"; then
2916 echo "$as_me:2916: result: $MAKE_LOWER_TAGS" >&5
2917 echo "${ECHO_T}$MAKE_LOWER_TAGS" >&6
2919 echo "$as_me:2919: result: no" >&5
2920 echo "${ECHO_T}no" >&6
2923 if test "$cf_cv_mixedcase" = yes ; then
2924 # Extract the first word of "${ETAGS:-etags}", so it can be a program name with args.
2925 set dummy ${ETAGS:-etags}; ac_word=$2
2926 echo "$as_me:2926: checking for $ac_word" >&5
2927 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2928 if test "${ac_cv_prog_MAKE_UPPER_TAGS+set}" = set; then
2929 echo $ECHO_N "(cached) $ECHO_C" >&6
2931 if test -n "$MAKE_UPPER_TAGS"; then
2932 ac_cv_prog_MAKE_UPPER_TAGS="$MAKE_UPPER_TAGS" # Let the user override the test.
2934 ac_save_IFS=$IFS; IFS=$ac_path_separator
2936 for ac_dir in $ac_dummy; do
2938 test -z "$ac_dir" && ac_dir=.
2939 $as_executable_p "$ac_dir/$ac_word" || continue
2940 ac_cv_prog_MAKE_UPPER_TAGS="yes"
2941 echo "$as_me:2941: found $ac_dir/$ac_word" >&5
2945 test -z "$ac_cv_prog_MAKE_UPPER_TAGS" && ac_cv_prog_MAKE_UPPER_TAGS="no"
2948 MAKE_UPPER_TAGS=$ac_cv_prog_MAKE_UPPER_TAGS
2949 if test -n "$MAKE_UPPER_TAGS"; then
2950 echo "$as_me:2950: result: $MAKE_UPPER_TAGS" >&5
2951 echo "${ECHO_T}$MAKE_UPPER_TAGS" >&6
2953 echo "$as_me:2953: result: no" >&5
2954 echo "${ECHO_T}no" >&6
2961 if test "$MAKE_UPPER_TAGS" = yes ; then
2967 if test "$MAKE_LOWER_TAGS" = yes ; then
2973 echo "$as_me:2973: checking for makeflags variable" >&5
2974 echo $ECHO_N "checking for makeflags variable... $ECHO_C" >&6
2975 if test "${cf_cv_makeflags+set}" = set; then
2976 echo $ECHO_N "(cached) $ECHO_C" >&6
2980 for cf_option in '-${MAKEFLAGS}' '${MFLAGS}'
2982 cat >cf_makeflags.tmp <<CF_EOF
2985 @ echo '.$cf_option'
2987 cf_result=`${MAKE:-make} -k -f cf_makeflags.tmp 2>/dev/null | fgrep -v "ing directory" | sed -e 's,[ ]*$,,'`
2988 case "$cf_result" in
2990 cf_result=`${MAKE:-make} -k -f cf_makeflags.tmp CC=cc 2>/dev/null`
2991 case "$cf_result" in
2992 (.*CC=*) cf_cv_makeflags=
2994 (*) cf_cv_makeflags=$cf_option
3000 (*) echo "given option \"$cf_option\", no match \"$cf_result\""
3004 rm -f cf_makeflags.tmp
3007 echo "$as_me:3007: result: $cf_cv_makeflags" >&5
3008 echo "${ECHO_T}$cf_cv_makeflags" >&6
3010 if test -n "$ac_tool_prefix"; then
3011 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
3012 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
3013 echo "$as_me:3013: checking for $ac_word" >&5
3014 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3015 if test "${ac_cv_prog_RANLIB+set}" = set; then
3016 echo $ECHO_N "(cached) $ECHO_C" >&6
3018 if test -n "$RANLIB"; then
3019 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
3021 ac_save_IFS=$IFS; IFS=$ac_path_separator
3023 for ac_dir in $ac_dummy; do
3025 test -z "$ac_dir" && ac_dir=.
3026 $as_executable_p "$ac_dir/$ac_word" || continue
3027 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
3028 echo "$as_me:3028: found $ac_dir/$ac_word" >&5
3034 RANLIB=$ac_cv_prog_RANLIB
3035 if test -n "$RANLIB"; then
3036 echo "$as_me:3036: result: $RANLIB" >&5
3037 echo "${ECHO_T}$RANLIB" >&6
3039 echo "$as_me:3039: result: no" >&5
3040 echo "${ECHO_T}no" >&6
3044 if test -z "$ac_cv_prog_RANLIB"; then
3045 ac_ct_RANLIB=$RANLIB
3046 # Extract the first word of "ranlib", so it can be a program name with args.
3047 set dummy ranlib; ac_word=$2
3048 echo "$as_me:3048: checking for $ac_word" >&5
3049 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3050 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
3051 echo $ECHO_N "(cached) $ECHO_C" >&6
3053 if test -n "$ac_ct_RANLIB"; then
3054 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
3056 ac_save_IFS=$IFS; IFS=$ac_path_separator
3058 for ac_dir in $ac_dummy; do
3060 test -z "$ac_dir" && ac_dir=.
3061 $as_executable_p "$ac_dir/$ac_word" || continue
3062 ac_cv_prog_ac_ct_RANLIB="ranlib"
3063 echo "$as_me:3063: found $ac_dir/$ac_word" >&5
3067 test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB="':'"
3070 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
3071 if test -n "$ac_ct_RANLIB"; then
3072 echo "$as_me:3072: result: $ac_ct_RANLIB" >&5
3073 echo "${ECHO_T}$ac_ct_RANLIB" >&6
3075 echo "$as_me:3075: result: no" >&5
3076 echo "${ECHO_T}no" >&6
3079 RANLIB=$ac_ct_RANLIB
3081 RANLIB="$ac_cv_prog_RANLIB"
3084 if test -n "$ac_tool_prefix"; then
3085 # Extract the first word of "${ac_tool_prefix}ld", so it can be a program name with args.
3086 set dummy ${ac_tool_prefix}ld; ac_word=$2
3087 echo "$as_me:3087: checking for $ac_word" >&5
3088 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3089 if test "${ac_cv_prog_LD+set}" = set; then
3090 echo $ECHO_N "(cached) $ECHO_C" >&6
3092 if test -n "$LD"; then
3093 ac_cv_prog_LD="$LD" # Let the user override the test.
3095 ac_save_IFS=$IFS; IFS=$ac_path_separator
3097 for ac_dir in $ac_dummy; do
3099 test -z "$ac_dir" && ac_dir=.
3100 $as_executable_p "$ac_dir/$ac_word" || continue
3101 ac_cv_prog_LD="${ac_tool_prefix}ld"
3102 echo "$as_me:3102: found $ac_dir/$ac_word" >&5
3109 if test -n "$LD"; then
3110 echo "$as_me:3110: result: $LD" >&5
3111 echo "${ECHO_T}$LD" >&6
3113 echo "$as_me:3113: result: no" >&5
3114 echo "${ECHO_T}no" >&6
3118 if test -z "$ac_cv_prog_LD"; then
3120 # Extract the first word of "ld", so it can be a program name with args.
3121 set dummy ld; ac_word=$2
3122 echo "$as_me:3122: checking for $ac_word" >&5
3123 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3124 if test "${ac_cv_prog_ac_ct_LD+set}" = set; then
3125 echo $ECHO_N "(cached) $ECHO_C" >&6
3127 if test -n "$ac_ct_LD"; then
3128 ac_cv_prog_ac_ct_LD="$ac_ct_LD" # Let the user override the test.
3130 ac_save_IFS=$IFS; IFS=$ac_path_separator
3132 for ac_dir in $ac_dummy; do
3134 test -z "$ac_dir" && ac_dir=.
3135 $as_executable_p "$ac_dir/$ac_word" || continue
3136 ac_cv_prog_ac_ct_LD="ld"
3137 echo "$as_me:3137: found $ac_dir/$ac_word" >&5
3141 test -z "$ac_cv_prog_ac_ct_LD" && ac_cv_prog_ac_ct_LD="ld"
3144 ac_ct_LD=$ac_cv_prog_ac_ct_LD
3145 if test -n "$ac_ct_LD"; then
3146 echo "$as_me:3146: result: $ac_ct_LD" >&5
3147 echo "${ECHO_T}$ac_ct_LD" >&6
3149 echo "$as_me:3149: result: no" >&5
3150 echo "${ECHO_T}no" >&6
3158 if test -n "$ac_tool_prefix"; then
3159 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
3160 set dummy ${ac_tool_prefix}ar; ac_word=$2
3161 echo "$as_me:3161: checking for $ac_word" >&5
3162 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3163 if test "${ac_cv_prog_AR+set}" = set; then
3164 echo $ECHO_N "(cached) $ECHO_C" >&6
3166 if test -n "$AR"; then
3167 ac_cv_prog_AR="$AR" # Let the user override the test.
3169 ac_save_IFS=$IFS; IFS=$ac_path_separator
3171 for ac_dir in $ac_dummy; do
3173 test -z "$ac_dir" && ac_dir=.
3174 $as_executable_p "$ac_dir/$ac_word" || continue
3175 ac_cv_prog_AR="${ac_tool_prefix}ar"
3176 echo "$as_me:3176: found $ac_dir/$ac_word" >&5
3183 if test -n "$AR"; then
3184 echo "$as_me:3184: result: $AR" >&5
3185 echo "${ECHO_T}$AR" >&6
3187 echo "$as_me:3187: result: no" >&5
3188 echo "${ECHO_T}no" >&6
3192 if test -z "$ac_cv_prog_AR"; then
3194 # Extract the first word of "ar", so it can be a program name with args.
3195 set dummy ar; ac_word=$2
3196 echo "$as_me:3196: checking for $ac_word" >&5
3197 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3198 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
3199 echo $ECHO_N "(cached) $ECHO_C" >&6
3201 if test -n "$ac_ct_AR"; then
3202 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
3204 ac_save_IFS=$IFS; IFS=$ac_path_separator
3206 for ac_dir in $ac_dummy; do
3208 test -z "$ac_dir" && ac_dir=.
3209 $as_executable_p "$ac_dir/$ac_word" || continue
3210 ac_cv_prog_ac_ct_AR="ar"
3211 echo "$as_me:3211: found $ac_dir/$ac_word" >&5
3215 test -z "$ac_cv_prog_ac_ct_AR" && ac_cv_prog_ac_ct_AR="ar"
3218 ac_ct_AR=$ac_cv_prog_ac_ct_AR
3219 if test -n "$ac_ct_AR"; then
3220 echo "$as_me:3220: result: $ac_ct_AR" >&5
3221 echo "${ECHO_T}$ac_ct_AR" >&6
3223 echo "$as_me:3223: result: no" >&5
3224 echo "${ECHO_T}no" >&6
3232 if test -n "$ac_tool_prefix"; then
3233 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
3234 set dummy ${ac_tool_prefix}ar; ac_word=$2
3235 echo "$as_me:3235: checking for $ac_word" >&5
3236 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3237 if test "${ac_cv_prog_AR+set}" = set; then
3238 echo $ECHO_N "(cached) $ECHO_C" >&6
3240 if test -n "$AR"; then
3241 ac_cv_prog_AR="$AR" # Let the user override the test.
3243 ac_save_IFS=$IFS; IFS=$ac_path_separator
3245 for ac_dir in $ac_dummy; do
3247 test -z "$ac_dir" && ac_dir=.
3248 $as_executable_p "$ac_dir/$ac_word" || continue
3249 ac_cv_prog_AR="${ac_tool_prefix}ar"
3250 echo "$as_me:3250: found $ac_dir/$ac_word" >&5
3257 if test -n "$AR"; then
3258 echo "$as_me:3258: result: $AR" >&5
3259 echo "${ECHO_T}$AR" >&6
3261 echo "$as_me:3261: result: no" >&5
3262 echo "${ECHO_T}no" >&6
3266 if test -z "$ac_cv_prog_AR"; then
3268 # Extract the first word of "ar", so it can be a program name with args.
3269 set dummy ar; ac_word=$2
3270 echo "$as_me:3270: checking for $ac_word" >&5
3271 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3272 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
3273 echo $ECHO_N "(cached) $ECHO_C" >&6
3275 if test -n "$ac_ct_AR"; then
3276 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
3278 ac_save_IFS=$IFS; IFS=$ac_path_separator
3280 for ac_dir in $ac_dummy; do
3282 test -z "$ac_dir" && ac_dir=.
3283 $as_executable_p "$ac_dir/$ac_word" || continue
3284 ac_cv_prog_ac_ct_AR="ar"
3285 echo "$as_me:3285: found $ac_dir/$ac_word" >&5
3289 test -z "$ac_cv_prog_ac_ct_AR" && ac_cv_prog_ac_ct_AR="ar"
3292 ac_ct_AR=$ac_cv_prog_ac_ct_AR
3293 if test -n "$ac_ct_AR"; then
3294 echo "$as_me:3294: result: $ac_ct_AR" >&5
3295 echo "${ECHO_T}$ac_ct_AR" >&6
3297 echo "$as_me:3297: result: no" >&5
3298 echo "${ECHO_T}no" >&6
3306 echo "$as_me:3306: checking for options to update archives" >&5
3307 echo $ECHO_N "checking for options to update archives... $ECHO_C" >&6
3308 if test "${cf_cv_ar_flags+set}" = set; then
3309 echo $ECHO_N "(cached) $ECHO_C" >&6
3312 cf_cv_ar_flags=unknown
3313 for cf_ar_flags in -curvU -curv curv -crv crv -cqv cqv -rv rv
3316 # check if $ARFLAGS already contains this choice
3317 if test "x$ARFLAGS" != "x" ; then
3318 cf_check_ar_flags=`echo "x$ARFLAGS" | sed -e "s/$cf_ar_flags\$//" -e "s/$cf_ar_flags / /"`
3319 if test "x$ARFLAGS" != "$cf_check_ar_flags" ; then
3325 rm -f conftest.$ac_cv_objext
3328 cat >conftest.$ac_ext <<EOF
3329 #line 3329 "configure"
3330 int testdata[3] = { 123, 456, 789 };
3332 if { (eval echo "$as_me:3332: \"$ac_compile\"") >&5
3333 (eval $ac_compile) 2>&5
3335 echo "$as_me:3335: \$? = $ac_status" >&5
3336 (exit $ac_status); } ; then
3337 echo "$AR $ARFLAGS $cf_ar_flags conftest.a conftest.$ac_cv_objext" >&5
3338 $AR $ARFLAGS $cf_ar_flags conftest.a conftest.$ac_cv_objext 2>&5 1>/dev/null
3339 if test -f conftest.a ; then
3340 cf_cv_ar_flags=$cf_ar_flags
3344 test -n "$verbose" && echo " cannot compile test-program" 1>&6
3346 echo "${as_me:-configure}:3346: testing cannot compile test-program ..." 1>&5
3351 rm -f conftest.a conftest.$ac_ext conftest.$ac_cv_objext
3354 echo "$as_me:3354: result: $cf_cv_ar_flags" >&5
3355 echo "${ECHO_T}$cf_cv_ar_flags" >&6
3357 if test -n "$ARFLAGS" ; then
3358 if test -n "$cf_cv_ar_flags" ; then
3359 ARFLAGS="$ARFLAGS $cf_cv_ar_flags"
3362 ARFLAGS=$cf_cv_ar_flags
3365 echo "$as_me:3365: checking for PATH separator" >&5
3366 echo $ECHO_N "checking for PATH separator... $ECHO_C" >&6
3367 case $cf_cv_system_name in
3368 (os2*) PATH_SEPARATOR=';' ;;
3369 (*) ${PATH_SEPARATOR:=':'} ;;
3372 echo "$as_me:3372: result: $PATH_SEPARATOR" >&5
3373 echo "${ECHO_T}$PATH_SEPARATOR" >&6
3375 echo "$as_me:3375: checking if you have specified an install-prefix" >&5
3376 echo $ECHO_N "checking if you have specified an install-prefix... $ECHO_C" >&6
3378 # Check whether --with-install-prefix or --without-install-prefix was given.
3379 if test "${with_install_prefix+set}" = set; then
3380 withval="$with_install_prefix"
3384 (*) DESTDIR="$withval"
3388 echo "$as_me:3388: result: $DESTDIR" >&5
3389 echo "${ECHO_T}$DESTDIR" >&6
3391 ###############################################################################
3393 # If we're cross-compiling, allow the user to override the tools and their
3394 # options. The configure script is oriented toward identifying the host
3395 # compiler, etc., but we need a build compiler to generate parts of the source.
3397 if test "$cross_compiling" = yes ; then
3399 # defaults that we might want to override
3400 : ${BUILD_CFLAGS:=''}
3401 : ${BUILD_CPPFLAGS:=''}
3402 : ${BUILD_LDFLAGS:=''}
3404 : ${BUILD_EXEEXT:='$x'}
3405 : ${BUILD_OBJEXT:='o'}
3407 # Check whether --with-build-cc or --without-build-cc was given.
3408 if test "${with_build_cc+set}" = set; then
3409 withval="$with_build_cc"
3412 for ac_prog in gcc cc cl
3414 # Extract the first word of "$ac_prog", so it can be a program name with args.
3415 set dummy $ac_prog; ac_word=$2
3416 echo "$as_me:3416: checking for $ac_word" >&5
3417 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3418 if test "${ac_cv_prog_BUILD_CC+set}" = set; then
3419 echo $ECHO_N "(cached) $ECHO_C" >&6
3421 if test -n "$BUILD_CC"; then
3422 ac_cv_prog_BUILD_CC="$BUILD_CC" # Let the user override the test.
3424 ac_save_IFS=$IFS; IFS=$ac_path_separator
3426 for ac_dir in $ac_dummy; do
3428 test -z "$ac_dir" && ac_dir=.
3429 $as_executable_p "$ac_dir/$ac_word" || continue
3430 ac_cv_prog_BUILD_CC="$ac_prog"
3431 echo "$as_me:3431: found $ac_dir/$ac_word" >&5
3437 BUILD_CC=$ac_cv_prog_BUILD_CC
3438 if test -n "$BUILD_CC"; then
3439 echo "$as_me:3439: result: $BUILD_CC" >&5
3440 echo "${ECHO_T}$BUILD_CC" >&6
3442 echo "$as_me:3442: result: no" >&5
3443 echo "${ECHO_T}no" >&6
3446 test -n "$BUILD_CC" && break
3450 echo "$as_me:3450: checking for native build C compiler" >&5
3451 echo $ECHO_N "checking for native build C compiler... $ECHO_C" >&6
3452 echo "$as_me:3452: result: $BUILD_CC" >&5
3453 echo "${ECHO_T}$BUILD_CC" >&6
3455 echo "$as_me:3455: checking for native build C preprocessor" >&5
3456 echo $ECHO_N "checking for native build C preprocessor... $ECHO_C" >&6
3458 # Check whether --with-build-cpp or --without-build-cpp was given.
3459 if test "${with_build_cpp+set}" = set; then
3460 withval="$with_build_cpp"
3461 BUILD_CPP="$withval"
3463 BUILD_CPP='${BUILD_CC} -E'
3465 echo "$as_me:3465: result: $BUILD_CPP" >&5
3466 echo "${ECHO_T}$BUILD_CPP" >&6
3468 echo "$as_me:3468: checking for native build C flags" >&5
3469 echo $ECHO_N "checking for native build C flags... $ECHO_C" >&6
3471 # Check whether --with-build-cflags or --without-build-cflags was given.
3472 if test "${with_build_cflags+set}" = set; then
3473 withval="$with_build_cflags"
3474 BUILD_CFLAGS="$withval"
3476 echo "$as_me:3476: result: $BUILD_CFLAGS" >&5
3477 echo "${ECHO_T}$BUILD_CFLAGS" >&6
3479 echo "$as_me:3479: checking for native build C preprocessor-flags" >&5
3480 echo $ECHO_N "checking for native build C preprocessor-flags... $ECHO_C" >&6
3482 # Check whether --with-build-cppflags or --without-build-cppflags was given.
3483 if test "${with_build_cppflags+set}" = set; then
3484 withval="$with_build_cppflags"
3485 BUILD_CPPFLAGS="$withval"
3487 echo "$as_me:3487: result: $BUILD_CPPFLAGS" >&5
3488 echo "${ECHO_T}$BUILD_CPPFLAGS" >&6
3490 echo "$as_me:3490: checking for native build linker-flags" >&5
3491 echo $ECHO_N "checking for native build linker-flags... $ECHO_C" >&6
3493 # Check whether --with-build-ldflags or --without-build-ldflags was given.
3494 if test "${with_build_ldflags+set}" = set; then
3495 withval="$with_build_ldflags"
3496 BUILD_LDFLAGS="$withval"
3498 echo "$as_me:3498: result: $BUILD_LDFLAGS" >&5
3499 echo "${ECHO_T}$BUILD_LDFLAGS" >&6
3501 echo "$as_me:3501: checking for native build linker-libraries" >&5
3502 echo $ECHO_N "checking for native build linker-libraries... $ECHO_C" >&6
3504 # Check whether --with-build-libs or --without-build-libs was given.
3505 if test "${with_build_libs+set}" = set; then
3506 withval="$with_build_libs"
3507 BUILD_LIBS="$withval"
3509 echo "$as_me:3509: result: $BUILD_LIBS" >&5
3510 echo "${ECHO_T}$BUILD_LIBS" >&6
3512 # this assumes we're on Unix.
3516 : ${BUILD_CC:='${CC}'}
3518 if ( test "$BUILD_CC" = "$CC" || test "$BUILD_CC" = '${CC}' ) ; then
3519 { { echo "$as_me:3519: error: Cross-build requires two compilers.
3520 Use --with-build-cc to specify the native compiler." >&5
3521 echo "$as_me: error: Cross-build requires two compilers.
3522 Use --with-build-cc to specify the native compiler." >&2;}
3523 { (exit 1); exit 1; }; }
3527 : ${BUILD_CC:='${CC}'}
3528 : ${BUILD_CPP:='${CPP}'}
3529 : ${BUILD_CFLAGS:='${CFLAGS}'}
3530 : ${BUILD_CPPFLAGS:='${CPPFLAGS}'}
3531 : ${BUILD_LDFLAGS:='${LDFLAGS}'}
3532 : ${BUILD_LIBS:='${LIBS}'}
3533 : ${BUILD_EXEEXT:='$x'}
3534 : ${BUILD_OBJEXT:='o'}
3537 ###############################################################################
3539 ### Options to allow the user to specify the set of libraries which are used.
3540 ### Use "--without-normal --with-shared" to allow the default model to be
3541 ### shared, for example.
3544 echo "$as_me:3544: checking if you want to build shared C-objects" >&5
3545 echo $ECHO_N "checking if you want to build shared C-objects... $ECHO_C" >&6
3547 # Check whether --with-shared or --without-shared was given.
3548 if test "${with_shared+set}" = set; then
3549 withval="$with_shared"
3550 with_shared=$withval
3554 echo "$as_me:3554: result: $with_shared" >&5
3555 echo "${ECHO_T}$with_shared" >&6
3556 test "$with_shared" = "yes" && cf_list_models="$cf_list_models shared"
3558 echo "$as_me:3558: checking for specified models" >&5
3559 echo $ECHO_N "checking for specified models... $ECHO_C" >&6
3560 test -z "$cf_list_models" && cf_list_models=normal
3561 echo "$as_me:3561: result: $cf_list_models" >&5
3562 echo "${ECHO_T}$cf_list_models" >&6
3564 ### Use the first model as the default, and save its suffix for use in building
3565 ### up test-applications.
3566 echo "$as_me:3566: checking for default model" >&5
3567 echo $ECHO_N "checking for default model... $ECHO_C" >&6
3568 DFT_LWR_MODEL=`echo "$cf_list_models" | $AWK '{print $1}'`
3569 echo "$as_me:3569: result: $DFT_LWR_MODEL" >&5
3570 echo "${ECHO_T}$DFT_LWR_MODEL" >&6
3572 DFT_UPR_MODEL=`echo "$DFT_LWR_MODEL" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
3574 echo "$as_me:3574: checking for specific curses-directory" >&5
3575 echo $ECHO_N "checking for specific curses-directory... $ECHO_C" >&6
3577 # Check whether --with-curses-dir or --without-curses-dir was given.
3578 if test "${with_curses_dir+set}" = set; then
3579 withval="$with_curses_dir"
3580 cf_cv_curses_dir=$withval
3584 echo "$as_me:3584: result: $cf_cv_curses_dir" >&5
3585 echo "${ECHO_T}$cf_cv_curses_dir" >&6
3587 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
3590 if test "x$prefix" != xNONE; then
3591 cf_path_syntax="$prefix"
3593 cf_path_syntax="$ac_default_prefix"
3601 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
3603 (.\${*prefix}*|.\${*dir}*)
3604 eval withval="$withval"
3607 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
3612 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
3615 { { echo "$as_me:3615: error: expected a pathname, not \"$withval\"" >&5
3616 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
3617 { (exit 1); exit 1; }; }
3621 if test -d "$cf_cv_curses_dir"
3624 if test -n "$cf_cv_curses_dir/include" ; then
3625 for cf_add_incdir in $cf_cv_curses_dir/include
3627 while test $cf_add_incdir != /usr/include
3629 if test -d $cf_add_incdir
3632 if test -n "$CFLAGS$CPPFLAGS" ; then
3633 # a loop is needed to ensure we can add subdirs of existing dirs
3634 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
3635 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
3636 cf_have_incdir=yes; break
3641 if test "$cf_have_incdir" = no ; then
3642 if test "$cf_add_incdir" = /usr/local/include ; then
3643 if test "$GCC" = yes
3645 cf_save_CPPFLAGS=$CPPFLAGS
3646 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
3647 cat >conftest.$ac_ext <<_ACEOF
3648 #line 3648 "configure"
3649 #include "confdefs.h"
3659 rm -f conftest.$ac_objext
3660 if { (eval echo "$as_me:3660: \"$ac_compile\"") >&5
3661 (eval $ac_compile) 2>&5
3663 echo "$as_me:3663: \$? = $ac_status" >&5
3664 (exit $ac_status); } &&
3665 { ac_try='test -s conftest.$ac_objext'
3666 { (eval echo "$as_me:3666: \"$ac_try\"") >&5
3669 echo "$as_me:3669: \$? = $ac_status" >&5
3670 (exit $ac_status); }; }; then
3673 echo "$as_me: failed program was:" >&5
3674 cat conftest.$ac_ext >&5
3677 rm -f conftest.$ac_objext conftest.$ac_ext
3678 CPPFLAGS=$cf_save_CPPFLAGS
3683 if test "$cf_have_incdir" = no ; then
3684 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
3686 echo "${as_me:-configure}:3686: testing adding $cf_add_incdir to include-path ..." 1>&5
3688 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
3690 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
3691 test "$cf_top_incdir" = "$cf_add_incdir" && break
3692 cf_add_incdir="$cf_top_incdir"
3703 if test -n "$cf_cv_curses_dir/lib" ; then
3704 for cf_add_libdir in $cf_cv_curses_dir/lib
3706 if test $cf_add_libdir = /usr/lib ; then
3708 elif test -d $cf_add_libdir
3711 if test -n "$LDFLAGS$LIBS" ; then
3712 # a loop is needed to ensure we can add subdirs of existing dirs
3713 for cf_test_libdir in $LDFLAGS $LIBS ; do
3714 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
3715 cf_have_libdir=yes; break
3719 if test "$cf_have_libdir" = no ; then
3720 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
3722 echo "${as_me:-configure}:3722: testing adding $cf_add_libdir to library-path ..." 1>&5
3724 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
3733 cf_ncuconfig_root=ncurses
3734 cf_have_ncuconfig=no
3736 if test "x${PKG_CONFIG:=none}" != xnone; then
3737 echo "$as_me:3737: checking pkg-config for $cf_ncuconfig_root" >&5
3738 echo $ECHO_N "checking pkg-config for $cf_ncuconfig_root... $ECHO_C" >&6
3739 if "$PKG_CONFIG" --exists $cf_ncuconfig_root ; then
3740 echo "$as_me:3740: result: yes" >&5
3741 echo "${ECHO_T}yes" >&6
3743 echo "$as_me:3743: checking if the $cf_ncuconfig_root package files work" >&5
3744 echo $ECHO_N "checking if the $cf_ncuconfig_root package files work... $ECHO_C" >&6
3745 cf_have_ncuconfig=unknown
3747 cf_save_CPPFLAGS="$CPPFLAGS"
3748 cf_save_LIBS="$LIBS"
3750 CPPFLAGS="$CPPFLAGS `$PKG_CONFIG --cflags $cf_ncuconfig_root`"
3752 cf_add_libs="`$PKG_CONFIG --libs $cf_ncuconfig_root`"
3753 # Filter out duplicates - this happens with badly-designed ".pc" files...
3754 for cf_add_1lib in $LIBS
3756 for cf_add_2lib in $cf_add_libs
3758 if test "x$cf_add_1lib" = "x$cf_add_2lib"
3764 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
3768 cat >conftest.$ac_ext <<_ACEOF
3769 #line 3769 "configure"
3770 #include "confdefs.h"
3771 #include <${cf_cv_ncurses_header:-curses.h}>
3775 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
3780 rm -f conftest.$ac_objext conftest$ac_exeext
3781 if { (eval echo "$as_me:3781: \"$ac_link\"") >&5
3782 (eval $ac_link) 2>&5
3784 echo "$as_me:3784: \$? = $ac_status" >&5
3785 (exit $ac_status); } &&
3786 { ac_try='test -s conftest$ac_exeext'
3787 { (eval echo "$as_me:3787: \"$ac_try\"") >&5
3790 echo "$as_me:3790: \$? = $ac_status" >&5
3791 (exit $ac_status); }; }; then
3792 if test "$cross_compiling" = yes; then
3793 cf_have_ncuconfig=maybe
3795 cat >conftest.$ac_ext <<_ACEOF
3796 #line 3796 "configure"
3797 #include "confdefs.h"
3798 #include <${cf_cv_ncurses_header:-curses.h}>
3800 { char *xx = curses_version(); return (xx == 0); }
3802 rm -f conftest$ac_exeext
3803 if { (eval echo "$as_me:3803: \"$ac_link\"") >&5
3804 (eval $ac_link) 2>&5
3806 echo "$as_me:3806: \$? = $ac_status" >&5
3807 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
3808 { (eval echo "$as_me:3808: \"$ac_try\"") >&5
3811 echo "$as_me:3811: \$? = $ac_status" >&5
3812 (exit $ac_status); }; }; then
3813 cf_have_ncuconfig=yes
3815 echo "$as_me: program exited with status $ac_status" >&5
3816 echo "$as_me: failed program was:" >&5
3817 cat conftest.$ac_ext >&5
3818 cf_have_ncuconfig=no
3820 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
3823 echo "$as_me: failed program was:" >&5
3824 cat conftest.$ac_ext >&5
3825 cf_have_ncuconfig=no
3827 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
3828 echo "$as_me:3828: result: $cf_have_ncuconfig" >&5
3829 echo "${ECHO_T}$cf_have_ncuconfig" >&6
3830 test "$cf_have_ncuconfig" = maybe && cf_have_ncuconfig=yes
3831 if test "$cf_have_ncuconfig" != "yes"
3833 CPPFLAGS="$cf_save_CPPFLAGS"
3834 LIBS="$cf_save_LIBS"
3835 NCURSES_CONFIG_PKG=none
3838 cat >>confdefs.h <<\EOF
3842 NCURSES_CONFIG_PKG=$cf_ncuconfig_root
3845 echo "$as_me:3845: checking for terminfo header" >&5
3846 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
3847 if test "${cf_cv_term_header+set}" = set; then
3848 echo $ECHO_N "(cached) $ECHO_C" >&6
3851 case ${cf_cv_ncurses_header} in
3852 (*/ncurses.h|*/ncursesw.h)
3853 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
3856 cf_term_header=term.h
3860 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
3862 cat >conftest.$ac_ext <<_ACEOF
3863 #line 3863 "configure"
3864 #include "confdefs.h"
3866 #include <${cf_cv_ncurses_header:-curses.h}>
3872 int x = auto_left_margin
3877 rm -f conftest.$ac_objext
3878 if { (eval echo "$as_me:3878: \"$ac_compile\"") >&5
3879 (eval $ac_compile) 2>&5
3881 echo "$as_me:3881: \$? = $ac_status" >&5
3882 (exit $ac_status); } &&
3883 { ac_try='test -s conftest.$ac_objext'
3884 { (eval echo "$as_me:3884: \"$ac_try\"") >&5
3887 echo "$as_me:3887: \$? = $ac_status" >&5
3888 (exit $ac_status); }; }; then
3890 cf_cv_term_header="$cf_test"
3892 echo "$as_me: failed program was:" >&5
3893 cat conftest.$ac_ext >&5
3895 cf_cv_term_header=unknown
3898 rm -f conftest.$ac_objext conftest.$ac_ext
3899 test "$cf_cv_term_header" != unknown && break
3903 echo "$as_me:3903: result: $cf_cv_term_header" >&5
3904 echo "${ECHO_T}$cf_cv_term_header" >&6
3906 # Set definitions to allow ifdef'ing to accommodate subdirectories
3908 case $cf_cv_term_header in
3911 cat >>confdefs.h <<\EOF
3912 #define HAVE_TERM_H 1
3918 case $cf_cv_term_header in
3921 cat >>confdefs.h <<\EOF
3922 #define HAVE_NCURSES_TERM_H 1
3928 cat >>confdefs.h <<\EOF
3929 #define HAVE_NCURSESW_TERM_H 1
3936 echo "$as_me:3936: result: no" >&5
3937 echo "${ECHO_T}no" >&6
3938 NCURSES_CONFIG_PKG=none
3941 NCURSES_CONFIG_PKG=none
3944 if test "x$cf_have_ncuconfig" = "xno"; then
3945 echo "Looking for ${cf_ncuconfig_root}-config"
3947 if test -n "$ac_tool_prefix"; then
3948 for ac_prog in ${cf_ncuconfig_root}-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
3950 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3951 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3952 echo "$as_me:3952: checking for $ac_word" >&5
3953 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3954 if test "${ac_cv_prog_NCURSES_CONFIG+set}" = set; then
3955 echo $ECHO_N "(cached) $ECHO_C" >&6
3957 if test -n "$NCURSES_CONFIG"; then
3958 ac_cv_prog_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test.
3960 ac_save_IFS=$IFS; IFS=$ac_path_separator
3962 for ac_dir in $ac_dummy; do
3964 test -z "$ac_dir" && ac_dir=.
3965 $as_executable_p "$ac_dir/$ac_word" || continue
3966 ac_cv_prog_NCURSES_CONFIG="$ac_tool_prefix$ac_prog"
3967 echo "$as_me:3967: found $ac_dir/$ac_word" >&5
3973 NCURSES_CONFIG=$ac_cv_prog_NCURSES_CONFIG
3974 if test -n "$NCURSES_CONFIG"; then
3975 echo "$as_me:3975: result: $NCURSES_CONFIG" >&5
3976 echo "${ECHO_T}$NCURSES_CONFIG" >&6
3978 echo "$as_me:3978: result: no" >&5
3979 echo "${ECHO_T}no" >&6
3982 test -n "$NCURSES_CONFIG" && break
3985 if test -z "$NCURSES_CONFIG"; then
3986 ac_ct_NCURSES_CONFIG=$NCURSES_CONFIG
3987 for ac_prog in ${cf_ncuconfig_root}-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
3989 # Extract the first word of "$ac_prog", so it can be a program name with args.
3990 set dummy $ac_prog; ac_word=$2
3991 echo "$as_me:3991: checking for $ac_word" >&5
3992 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3993 if test "${ac_cv_prog_ac_ct_NCURSES_CONFIG+set}" = set; then
3994 echo $ECHO_N "(cached) $ECHO_C" >&6
3996 if test -n "$ac_ct_NCURSES_CONFIG"; then
3997 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_ct_NCURSES_CONFIG" # Let the user override the test.
3999 ac_save_IFS=$IFS; IFS=$ac_path_separator
4001 for ac_dir in $ac_dummy; do
4003 test -z "$ac_dir" && ac_dir=.
4004 $as_executable_p "$ac_dir/$ac_word" || continue
4005 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_prog"
4006 echo "$as_me:4006: found $ac_dir/$ac_word" >&5
4012 ac_ct_NCURSES_CONFIG=$ac_cv_prog_ac_ct_NCURSES_CONFIG
4013 if test -n "$ac_ct_NCURSES_CONFIG"; then
4014 echo "$as_me:4014: result: $ac_ct_NCURSES_CONFIG" >&5
4015 echo "${ECHO_T}$ac_ct_NCURSES_CONFIG" >&6
4017 echo "$as_me:4017: result: no" >&5
4018 echo "${ECHO_T}no" >&6
4021 test -n "$ac_ct_NCURSES_CONFIG" && break
4023 test -n "$ac_ct_NCURSES_CONFIG" || ac_ct_NCURSES_CONFIG="none"
4025 NCURSES_CONFIG=$ac_ct_NCURSES_CONFIG
4028 if test "$NCURSES_CONFIG" != none ; then
4030 CPPFLAGS="$CPPFLAGS `$NCURSES_CONFIG --cflags`"
4032 cf_add_libs="`$NCURSES_CONFIG --libs`"
4033 # Filter out duplicates - this happens with badly-designed ".pc" files...
4034 for cf_add_1lib in $LIBS
4036 for cf_add_2lib in $cf_add_libs
4038 if test "x$cf_add_1lib" = "x$cf_add_2lib"
4044 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
4048 # even with config script, some packages use no-override for curses.h
4050 echo "$as_me:4050: checking if we have identified curses headers" >&5
4051 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
4052 if test "${cf_cv_ncurses_header+set}" = set; then
4053 echo $ECHO_N "(cached) $ECHO_C" >&6
4056 cf_cv_ncurses_header=none
4058 ncurses.h ncurses/ncurses.h \
4059 curses.h ncurses/curses.h
4061 cat >conftest.$ac_ext <<_ACEOF
4062 #line 4062 "configure"
4063 #include "confdefs.h"
4064 #include <${cf_header}>
4068 initscr(); tgoto("?", 0,0)
4073 rm -f conftest.$ac_objext
4074 if { (eval echo "$as_me:4074: \"$ac_compile\"") >&5
4075 (eval $ac_compile) 2>&5
4077 echo "$as_me:4077: \$? = $ac_status" >&5
4078 (exit $ac_status); } &&
4079 { ac_try='test -s conftest.$ac_objext'
4080 { (eval echo "$as_me:4080: \"$ac_try\"") >&5
4083 echo "$as_me:4083: \$? = $ac_status" >&5
4084 (exit $ac_status); }; }; then
4085 cf_cv_ncurses_header=$cf_header; break
4087 echo "$as_me: failed program was:" >&5
4088 cat conftest.$ac_ext >&5
4090 rm -f conftest.$ac_objext conftest.$ac_ext
4094 echo "$as_me:4094: result: $cf_cv_ncurses_header" >&5
4095 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
4097 if test "$cf_cv_ncurses_header" = none ; then
4098 { { echo "$as_me:4098: error: No curses header-files found" >&5
4099 echo "$as_me: error: No curses header-files found" >&2;}
4100 { (exit 1); exit 1; }; }
4103 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
4105 for ac_header in $cf_cv_ncurses_header
4107 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
4108 echo "$as_me:4108: checking for $ac_header" >&5
4109 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4110 if eval "test \"\${$as_ac_Header+set}\" = set"; then
4111 echo $ECHO_N "(cached) $ECHO_C" >&6
4113 cat >conftest.$ac_ext <<_ACEOF
4114 #line 4114 "configure"
4115 #include "confdefs.h"
4116 #include <$ac_header>
4118 if { (eval echo "$as_me:4118: \"$ac_cpp conftest.$ac_ext\"") >&5
4119 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4121 egrep -v '^ *\+' conftest.er1 >conftest.err
4123 cat conftest.err >&5
4124 echo "$as_me:4124: \$? = $ac_status" >&5
4125 (exit $ac_status); } >/dev/null; then
4126 if test -s conftest.err; then
4127 ac_cpp_err=$ac_c_preproc_warn_flag
4134 if test -z "$ac_cpp_err"; then
4135 eval "$as_ac_Header=yes"
4137 echo "$as_me: failed program was:" >&5
4138 cat conftest.$ac_ext >&5
4139 eval "$as_ac_Header=no"
4141 rm -f conftest.err conftest.$ac_ext
4143 echo "$as_me:4143: result: `eval echo '${'$as_ac_Header'}'`" >&5
4144 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4145 if test `eval echo '${'$as_ac_Header'}'` = yes; then
4146 cat >>confdefs.h <<EOF
4147 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
4153 cat >>confdefs.h <<\EOF
4157 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
4159 cat >>confdefs.h <<EOF
4160 #define $cf_nculib_ROOT 1
4163 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
4167 cf_ncuhdr_root=ncurses
4169 test -n "$cf_cv_curses_dir" && \
4170 test "$cf_cv_curses_dir" != "no" && { \
4172 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
4173 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
4175 while test $cf_add_incdir != /usr/include
4177 if test -d $cf_add_incdir
4180 if test -n "$CFLAGS$CPPFLAGS" ; then
4181 # a loop is needed to ensure we can add subdirs of existing dirs
4182 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
4183 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
4184 cf_have_incdir=yes; break
4189 if test "$cf_have_incdir" = no ; then
4190 if test "$cf_add_incdir" = /usr/local/include ; then
4191 if test "$GCC" = yes
4193 cf_save_CPPFLAGS=$CPPFLAGS
4194 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
4195 cat >conftest.$ac_ext <<_ACEOF
4196 #line 4196 "configure"
4197 #include "confdefs.h"
4207 rm -f conftest.$ac_objext
4208 if { (eval echo "$as_me:4208: \"$ac_compile\"") >&5
4209 (eval $ac_compile) 2>&5
4211 echo "$as_me:4211: \$? = $ac_status" >&5
4212 (exit $ac_status); } &&
4213 { ac_try='test -s conftest.$ac_objext'
4214 { (eval echo "$as_me:4214: \"$ac_try\"") >&5
4217 echo "$as_me:4217: \$? = $ac_status" >&5
4218 (exit $ac_status); }; }; then
4221 echo "$as_me: failed program was:" >&5
4222 cat conftest.$ac_ext >&5
4225 rm -f conftest.$ac_objext conftest.$ac_ext
4226 CPPFLAGS=$cf_save_CPPFLAGS
4231 if test "$cf_have_incdir" = no ; then
4232 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
4234 echo "${as_me:-configure}:4234: testing adding $cf_add_incdir to include-path ..." 1>&5
4236 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
4238 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
4239 test "$cf_top_incdir" = "$cf_add_incdir" && break
4240 cf_add_incdir="$cf_top_incdir"
4253 echo "$as_me:4253: checking for $cf_ncuhdr_root header in include-path" >&5
4254 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
4255 if test "${cf_cv_ncurses_h+set}" = set; then
4256 echo $ECHO_N "(cached) $ECHO_C" >&6
4259 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
4260 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
4261 for cf_header in $cf_header_list
4264 cat >conftest.$ac_ext <<_ACEOF
4265 #line 4265 "configure"
4266 #include "confdefs.h"
4268 #include <$cf_header>
4273 #ifdef NCURSES_VERSION
4275 printf("%s\n", NCURSES_VERSION);
4288 rm -f conftest.$ac_objext
4289 if { (eval echo "$as_me:4289: \"$ac_compile\"") >&5
4290 (eval $ac_compile) 2>&5
4292 echo "$as_me:4292: \$? = $ac_status" >&5
4293 (exit $ac_status); } &&
4294 { ac_try='test -s conftest.$ac_objext'
4295 { (eval echo "$as_me:4295: \"$ac_try\"") >&5
4298 echo "$as_me:4298: \$? = $ac_status" >&5
4299 (exit $ac_status); }; }; then
4300 cf_cv_ncurses_h=$cf_header
4303 echo "$as_me: failed program was:" >&5
4304 cat conftest.$ac_ext >&5
4307 rm -f conftest.$ac_objext conftest.$ac_ext
4309 test "$cf_cv_ncurses_h" != no && break
4313 echo "$as_me:4313: result: $cf_cv_ncurses_h" >&5
4314 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
4316 if test "$cf_cv_ncurses_h" != no ; then
4317 cf_cv_ncurses_header=$cf_cv_ncurses_h
4320 echo "$as_me:4320: checking for $cf_ncuhdr_root include-path" >&5
4321 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
4322 if test "${cf_cv_ncurses_h2+set}" = set; then
4323 echo $ECHO_N "(cached) $ECHO_C" >&6
4326 test -n "$verbose" && echo
4330 # collect the current set of include-directories from compiler flags
4331 cf_header_path_list=""
4332 if test -n "${CFLAGS}${CPPFLAGS}" ; then
4333 for cf_header_path in $CPPFLAGS $CFLAGS
4335 case $cf_header_path in
4337 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
4339 test "x$cf_header_path" != "xNONE" && \
4340 test -d "$cf_header_path" && \
4342 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
4343 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
4344 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
4345 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
4346 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
4347 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"
4350 cf_header_path_list="$cf_header_path_list $cf_search"
4356 # add the variations for the package we are looking for
4360 test "x$prefix" != "xNONE" && \
4361 test -d "$prefix" && \
4363 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
4364 test -d $prefix/include && cf_search="$cf_search $prefix/include"
4365 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
4366 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
4367 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
4368 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
4371 for cf_subdir_prefix in \
4380 test "x$cf_subdir_prefix" != "x$prefix" && \
4381 test -d "$cf_subdir_prefix" && \
4382 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
4383 test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
4384 test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include"
4385 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root"
4386 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root/include"
4387 test -d $cf_subdir_prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include"
4388 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"
4393 test "$includedir" != NONE && \
4394 test "$includedir" != "/usr/include" && \
4395 test -d "$includedir" && {
4396 test -d $includedir && cf_search="$cf_search $includedir"
4397 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
4400 test "$oldincludedir" != NONE && \
4401 test "$oldincludedir" != "/usr/include" && \
4402 test -d "$oldincludedir" && {
4403 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
4404 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
4407 cf_search="$cf_search $cf_header_path_list"
4409 test -n "$verbose" && echo search path $cf_search
4410 cf_save2_CPPFLAGS="$CPPFLAGS"
4411 for cf_incdir in $cf_search
4414 if test -n "$cf_incdir" ; then
4415 for cf_add_incdir in $cf_incdir
4417 while test $cf_add_incdir != /usr/include
4419 if test -d $cf_add_incdir
4422 if test -n "$CFLAGS$CPPFLAGS" ; then
4423 # a loop is needed to ensure we can add subdirs of existing dirs
4424 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
4425 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
4426 cf_have_incdir=yes; break
4431 if test "$cf_have_incdir" = no ; then
4432 if test "$cf_add_incdir" = /usr/local/include ; then
4433 if test "$GCC" = yes
4435 cf_save_CPPFLAGS=$CPPFLAGS
4436 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
4437 cat >conftest.$ac_ext <<_ACEOF
4438 #line 4438 "configure"
4439 #include "confdefs.h"
4449 rm -f conftest.$ac_objext
4450 if { (eval echo "$as_me:4450: \"$ac_compile\"") >&5
4451 (eval $ac_compile) 2>&5
4453 echo "$as_me:4453: \$? = $ac_status" >&5
4454 (exit $ac_status); } &&
4455 { ac_try='test -s conftest.$ac_objext'
4456 { (eval echo "$as_me:4456: \"$ac_try\"") >&5
4459 echo "$as_me:4459: \$? = $ac_status" >&5
4460 (exit $ac_status); }; }; then
4463 echo "$as_me: failed program was:" >&5
4464 cat conftest.$ac_ext >&5
4467 rm -f conftest.$ac_objext conftest.$ac_ext
4468 CPPFLAGS=$cf_save_CPPFLAGS
4473 if test "$cf_have_incdir" = no ; then
4474 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
4476 echo "${as_me:-configure}:4476: testing adding $cf_add_incdir to include-path ..." 1>&5
4478 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
4480 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
4481 test "$cf_top_incdir" = "$cf_add_incdir" && break
4482 cf_add_incdir="$cf_top_incdir"
4498 cat >conftest.$ac_ext <<_ACEOF
4499 #line 4499 "configure"
4500 #include "confdefs.h"
4502 #include <$cf_header>
4507 #ifdef NCURSES_VERSION
4509 printf("%s\n", NCURSES_VERSION);
4522 rm -f conftest.$ac_objext
4523 if { (eval echo "$as_me:4523: \"$ac_compile\"") >&5
4524 (eval $ac_compile) 2>&5
4526 echo "$as_me:4526: \$? = $ac_status" >&5
4527 (exit $ac_status); } &&
4528 { ac_try='test -s conftest.$ac_objext'
4529 { (eval echo "$as_me:4529: \"$ac_try\"") >&5
4532 echo "$as_me:4532: \$? = $ac_status" >&5
4533 (exit $ac_status); }; }; then
4534 cf_cv_ncurses_h2=$cf_header
4537 echo "$as_me: failed program was:" >&5
4538 cat conftest.$ac_ext >&5
4541 rm -f conftest.$ac_objext conftest.$ac_ext
4543 if test "$cf_cv_ncurses_h2" != no ; then
4544 cf_cv_ncurses_h2=$cf_incdir/$cf_header
4545 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
4548 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
4550 CPPFLAGS="$cf_save2_CPPFLAGS"
4551 test "$cf_cv_ncurses_h2" != no && break
4553 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:4553: error: not found" >&5
4554 echo "$as_me: error: not found" >&2;}
4555 { (exit 1); exit 1; }; }
4558 echo "$as_me:4558: result: $cf_cv_ncurses_h2" >&5
4559 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
4561 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
4562 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
4563 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
4564 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
4567 if test -n "$cf_1st_incdir" ; then
4568 for cf_add_incdir in $cf_1st_incdir
4570 while test $cf_add_incdir != /usr/include
4572 if test -d $cf_add_incdir
4575 if test -n "$CFLAGS$CPPFLAGS" ; then
4576 # a loop is needed to ensure we can add subdirs of existing dirs
4577 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
4578 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
4579 cf_have_incdir=yes; break
4584 if test "$cf_have_incdir" = no ; then
4585 if test "$cf_add_incdir" = /usr/local/include ; then
4586 if test "$GCC" = yes
4588 cf_save_CPPFLAGS=$CPPFLAGS
4589 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
4590 cat >conftest.$ac_ext <<_ACEOF
4591 #line 4591 "configure"
4592 #include "confdefs.h"
4602 rm -f conftest.$ac_objext
4603 if { (eval echo "$as_me:4603: \"$ac_compile\"") >&5
4604 (eval $ac_compile) 2>&5
4606 echo "$as_me:4606: \$? = $ac_status" >&5
4607 (exit $ac_status); } &&
4608 { ac_try='test -s conftest.$ac_objext'
4609 { (eval echo "$as_me:4609: \"$ac_try\"") >&5
4612 echo "$as_me:4612: \$? = $ac_status" >&5
4613 (exit $ac_status); }; }; then
4616 echo "$as_me: failed program was:" >&5
4617 cat conftest.$ac_ext >&5
4620 rm -f conftest.$ac_objext conftest.$ac_ext
4621 CPPFLAGS=$cf_save_CPPFLAGS
4626 if test "$cf_have_incdir" = no ; then
4627 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
4629 echo "${as_me:-configure}:4629: testing adding $cf_add_incdir to include-path ..." 1>&5
4631 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
4633 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
4634 test "$cf_top_incdir" = "$cf_add_incdir" && break
4635 cf_add_incdir="$cf_top_incdir"
4648 # Set definitions to allow ifdef'ing for ncurses.h
4650 case $cf_cv_ncurses_header in
4653 cat >>confdefs.h <<\EOF
4654 #define HAVE_NCURSES_H 1
4660 case $cf_cv_ncurses_header in
4661 (ncurses/curses.h|ncurses/ncurses.h)
4663 cat >>confdefs.h <<\EOF
4664 #define HAVE_NCURSES_NCURSES_H 1
4668 (ncursesw/curses.h|ncursesw/ncurses.h)
4670 cat >>confdefs.h <<\EOF
4671 #define HAVE_NCURSESW_NCURSES_H 1
4677 echo "$as_me:4677: checking for terminfo header" >&5
4678 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
4679 if test "${cf_cv_term_header+set}" = set; then
4680 echo $ECHO_N "(cached) $ECHO_C" >&6
4683 case ${cf_cv_ncurses_header} in
4684 (*/ncurses.h|*/ncursesw.h)
4685 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
4688 cf_term_header=term.h
4692 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
4694 cat >conftest.$ac_ext <<_ACEOF
4695 #line 4695 "configure"
4696 #include "confdefs.h"
4698 #include <${cf_cv_ncurses_header:-curses.h}>
4704 int x = auto_left_margin
4709 rm -f conftest.$ac_objext
4710 if { (eval echo "$as_me:4710: \"$ac_compile\"") >&5
4711 (eval $ac_compile) 2>&5
4713 echo "$as_me:4713: \$? = $ac_status" >&5
4714 (exit $ac_status); } &&
4715 { ac_try='test -s conftest.$ac_objext'
4716 { (eval echo "$as_me:4716: \"$ac_try\"") >&5
4719 echo "$as_me:4719: \$? = $ac_status" >&5
4720 (exit $ac_status); }; }; then
4722 cf_cv_term_header="$cf_test"
4724 echo "$as_me: failed program was:" >&5
4725 cat conftest.$ac_ext >&5
4727 cf_cv_term_header=unknown
4730 rm -f conftest.$ac_objext conftest.$ac_ext
4731 test "$cf_cv_term_header" != unknown && break
4735 echo "$as_me:4735: result: $cf_cv_term_header" >&5
4736 echo "${ECHO_T}$cf_cv_term_header" >&6
4738 # Set definitions to allow ifdef'ing to accommodate subdirectories
4740 case $cf_cv_term_header in
4743 cat >>confdefs.h <<\EOF
4744 #define HAVE_TERM_H 1
4750 case $cf_cv_term_header in
4753 cat >>confdefs.h <<\EOF
4754 #define HAVE_NCURSES_TERM_H 1
4760 cat >>confdefs.h <<\EOF
4761 #define HAVE_NCURSESW_TERM_H 1
4767 # some applications need this, but should check for NCURSES_VERSION
4769 cat >>confdefs.h <<\EOF
4773 echo "$as_me:4773: checking for ncurses version" >&5
4774 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
4775 if test "${cf_cv_ncurses_version+set}" = set; then
4776 echo $ECHO_N "(cached) $ECHO_C" >&6
4779 cf_cv_ncurses_version=no
4782 if test "$cross_compiling" = yes; then
4784 # This will not work if the preprocessor splits the line after the
4785 # Autoconf token. The 'unproto' program does that.
4786 cat > conftest.$ac_ext <<EOF
4787 #include <${cf_cv_ncurses_header:-curses.h}>
4789 #ifdef NCURSES_VERSION
4790 Autoconf NCURSES_VERSION
4798 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
4799 { (eval echo "$as_me:4799: \"$cf_try\"") >&5
4802 echo "$as_me:4802: \$? = $ac_status" >&5
4803 (exit $ac_status); }
4804 if test -f conftest.out ; then
4805 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
4806 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
4811 cat >conftest.$ac_ext <<_ACEOF
4812 #line 4812 "configure"
4813 #include "confdefs.h"
4815 #include <${cf_cv_ncurses_header:-curses.h}>
4819 FILE *fp = fopen("$cf_tempfile", "w");
4820 #ifdef NCURSES_VERSION
4821 # ifdef NCURSES_VERSION_PATCH
4822 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
4824 fprintf(fp, "%s\n", NCURSES_VERSION);
4828 fprintf(fp, "old\n");
4833 ${cf_cv_main_return:-return}(0);
4836 rm -f conftest$ac_exeext
4837 if { (eval echo "$as_me:4837: \"$ac_link\"") >&5
4838 (eval $ac_link) 2>&5
4840 echo "$as_me:4840: \$? = $ac_status" >&5
4841 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4842 { (eval echo "$as_me:4842: \"$ac_try\"") >&5
4845 echo "$as_me:4845: \$? = $ac_status" >&5
4846 (exit $ac_status); }; }; then
4848 cf_cv_ncurses_version=`cat $cf_tempfile`
4850 echo "$as_me: program exited with status $ac_status" >&5
4851 echo "$as_me: failed program was:" >&5
4852 cat conftest.$ac_ext >&5
4854 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
4859 echo "$as_me:4859: result: $cf_cv_ncurses_version" >&5
4860 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
4861 test "$cf_cv_ncurses_version" = no ||
4862 cat >>confdefs.h <<\EOF
4866 cf_nculib_root=ncurses
4867 # This works, except for the special case where we find gpm, but
4868 # ncurses is in a nonstandard location via $LIBS, and we really want
4871 cf_ncurses_SAVE="$LIBS"
4872 echo "$as_me:4872: checking for Gpm_Open in -lgpm" >&5
4873 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
4874 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
4875 echo $ECHO_N "(cached) $ECHO_C" >&6
4877 ac_check_lib_save_LIBS=$LIBS
4879 cat >conftest.$ac_ext <<_ACEOF
4880 #line 4880 "configure"
4881 #include "confdefs.h"
4883 /* Override any gcc2 internal prototype to avoid an error. */
4887 /* We use char because int might match the return type of a gcc2
4888 builtin and then its argument prototype would still apply. */
4898 rm -f conftest.$ac_objext conftest$ac_exeext
4899 if { (eval echo "$as_me:4899: \"$ac_link\"") >&5
4900 (eval $ac_link) 2>&5
4902 echo "$as_me:4902: \$? = $ac_status" >&5
4903 (exit $ac_status); } &&
4904 { ac_try='test -s conftest$ac_exeext'
4905 { (eval echo "$as_me:4905: \"$ac_try\"") >&5
4908 echo "$as_me:4908: \$? = $ac_status" >&5
4909 (exit $ac_status); }; }; then
4910 ac_cv_lib_gpm_Gpm_Open=yes
4912 echo "$as_me: failed program was:" >&5
4913 cat conftest.$ac_ext >&5
4914 ac_cv_lib_gpm_Gpm_Open=no
4916 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4917 LIBS=$ac_check_lib_save_LIBS
4919 echo "$as_me:4919: result: $ac_cv_lib_gpm_Gpm_Open" >&5
4920 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
4921 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
4922 echo "$as_me:4922: checking for initscr in -lgpm" >&5
4923 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
4924 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
4925 echo $ECHO_N "(cached) $ECHO_C" >&6
4927 ac_check_lib_save_LIBS=$LIBS
4929 cat >conftest.$ac_ext <<_ACEOF
4930 #line 4930 "configure"
4931 #include "confdefs.h"
4933 /* Override any gcc2 internal prototype to avoid an error. */
4937 /* We use char because int might match the return type of a gcc2
4938 builtin and then its argument prototype would still apply. */
4948 rm -f conftest.$ac_objext conftest$ac_exeext
4949 if { (eval echo "$as_me:4949: \"$ac_link\"") >&5
4950 (eval $ac_link) 2>&5
4952 echo "$as_me:4952: \$? = $ac_status" >&5
4953 (exit $ac_status); } &&
4954 { ac_try='test -s conftest$ac_exeext'
4955 { (eval echo "$as_me:4955: \"$ac_try\"") >&5
4958 echo "$as_me:4958: \$? = $ac_status" >&5
4959 (exit $ac_status); }; }; then
4960 ac_cv_lib_gpm_initscr=yes
4962 echo "$as_me: failed program was:" >&5
4963 cat conftest.$ac_ext >&5
4964 ac_cv_lib_gpm_initscr=no
4966 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4967 LIBS=$ac_check_lib_save_LIBS
4969 echo "$as_me:4969: result: $ac_cv_lib_gpm_initscr" >&5
4970 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
4971 if test $ac_cv_lib_gpm_initscr = yes; then
4972 LIBS="$cf_ncurses_SAVE"
4974 cf_ncurses_LIBS="-lgpm"
4981 # This is only necessary if you are linking against an obsolete
4982 # version of ncurses (but it should do no harm, since it's static).
4983 if test "$cf_nculib_root" = ncurses ; then
4984 echo "$as_me:4984: checking for tgoto in -lmytinfo" >&5
4985 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
4986 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
4987 echo $ECHO_N "(cached) $ECHO_C" >&6
4989 ac_check_lib_save_LIBS=$LIBS
4990 LIBS="-lmytinfo $LIBS"
4991 cat >conftest.$ac_ext <<_ACEOF
4992 #line 4992 "configure"
4993 #include "confdefs.h"
4995 /* Override any gcc2 internal prototype to avoid an error. */
4999 /* We use char because int might match the return type of a gcc2
5000 builtin and then its argument prototype would still apply. */
5010 rm -f conftest.$ac_objext conftest$ac_exeext
5011 if { (eval echo "$as_me:5011: \"$ac_link\"") >&5
5012 (eval $ac_link) 2>&5
5014 echo "$as_me:5014: \$? = $ac_status" >&5
5015 (exit $ac_status); } &&
5016 { ac_try='test -s conftest$ac_exeext'
5017 { (eval echo "$as_me:5017: \"$ac_try\"") >&5
5020 echo "$as_me:5020: \$? = $ac_status" >&5
5021 (exit $ac_status); }; }; then
5022 ac_cv_lib_mytinfo_tgoto=yes
5024 echo "$as_me: failed program was:" >&5
5025 cat conftest.$ac_ext >&5
5026 ac_cv_lib_mytinfo_tgoto=no
5028 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5029 LIBS=$ac_check_lib_save_LIBS
5031 echo "$as_me:5031: result: $ac_cv_lib_mytinfo_tgoto" >&5
5032 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
5033 if test $ac_cv_lib_mytinfo_tgoto = yes; then
5034 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
5041 cf_add_libs="$cf_ncurses_LIBS"
5042 # Filter out duplicates - this happens with badly-designed ".pc" files...
5043 for cf_add_1lib in $LIBS
5045 for cf_add_2lib in $cf_add_libs
5047 if test "x$cf_add_1lib" = "x$cf_add_2lib"
5053 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
5057 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
5060 cf_add_libs="-l$cf_nculib_root"
5061 # Filter out duplicates - this happens with badly-designed ".pc" files...
5062 for cf_add_1lib in $LIBS
5064 for cf_add_2lib in $cf_add_libs
5066 if test "x$cf_add_1lib" = "x$cf_add_2lib"
5072 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
5078 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
5080 echo "$as_me:5080: checking for initscr" >&5
5081 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
5082 if test "${ac_cv_func_initscr+set}" = set; then
5083 echo $ECHO_N "(cached) $ECHO_C" >&6
5085 cat >conftest.$ac_ext <<_ACEOF
5086 #line 5086 "configure"
5087 #include "confdefs.h"
5088 /* System header to define __stub macros and hopefully few prototypes,
5089 which can conflict with char initscr (); below. */
5091 /* Override any gcc2 internal prototype to avoid an error. */
5095 /* We use char because int might match the return type of a gcc2
5096 builtin and then its argument prototype would still apply. */
5103 /* The GNU C library defines this for functions which it implements
5104 to always fail with ENOSYS. Some functions are actually named
5105 something starting with __ and the normal name is an alias. */
5106 #if defined (__stub_initscr) || defined (__stub___initscr)
5109 f = initscr; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
5116 rm -f conftest.$ac_objext conftest$ac_exeext
5117 if { (eval echo "$as_me:5117: \"$ac_link\"") >&5
5118 (eval $ac_link) 2>&5
5120 echo "$as_me:5120: \$? = $ac_status" >&5
5121 (exit $ac_status); } &&
5122 { ac_try='test -s conftest$ac_exeext'
5123 { (eval echo "$as_me:5123: \"$ac_try\"") >&5
5126 echo "$as_me:5126: \$? = $ac_status" >&5
5127 (exit $ac_status); }; }; then
5128 ac_cv_func_initscr=yes
5130 echo "$as_me: failed program was:" >&5
5131 cat conftest.$ac_ext >&5
5132 ac_cv_func_initscr=no
5134 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5136 echo "$as_me:5136: result: $ac_cv_func_initscr" >&5
5137 echo "${ECHO_T}$ac_cv_func_initscr" >&6
5138 if test $ac_cv_func_initscr = yes; then
5139 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
5142 cf_save_LIBS="$LIBS"
5143 echo "$as_me:5143: checking for initscr in -l$cf_nculib_root" >&5
5144 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
5145 LIBS="-l$cf_nculib_root $LIBS"
5146 cat >conftest.$ac_ext <<_ACEOF
5147 #line 5147 "configure"
5148 #include "confdefs.h"
5149 #include <${cf_cv_ncurses_header:-curses.h}>
5158 rm -f conftest.$ac_objext conftest$ac_exeext
5159 if { (eval echo "$as_me:5159: \"$ac_link\"") >&5
5160 (eval $ac_link) 2>&5
5162 echo "$as_me:5162: \$? = $ac_status" >&5
5163 (exit $ac_status); } &&
5164 { ac_try='test -s conftest$ac_exeext'
5165 { (eval echo "$as_me:5165: \"$ac_try\"") >&5
5168 echo "$as_me:5168: \$? = $ac_status" >&5
5169 (exit $ac_status); }; }; then
5170 echo "$as_me:5170: result: yes" >&5
5171 echo "${ECHO_T}yes" >&6
5172 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
5175 echo "$as_me: failed program was:" >&5
5176 cat conftest.$ac_ext >&5
5177 echo "$as_me:5177: result: no" >&5
5178 echo "${ECHO_T}no" >&6
5181 cf_library_path_list=""
5182 if test -n "${LDFLAGS}${LIBS}" ; then
5183 for cf_library_path in $LDFLAGS $LIBS
5185 case $cf_library_path in
5187 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
5189 test "x$cf_library_path" != "xNONE" && \
5190 test -d "$cf_library_path" && \
5192 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
5193 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
5194 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
5195 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
5196 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
5197 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"
5200 cf_library_path_list="$cf_library_path_list $cf_search"
5208 test "x$prefix" != "xNONE" && \
5209 test -d "$prefix" && \
5211 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
5212 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
5213 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
5214 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
5215 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
5216 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
5219 for cf_subdir_prefix in \
5228 test "x$cf_subdir_prefix" != "x$prefix" && \
5229 test -d "$cf_subdir_prefix" && \
5230 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
5231 test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
5232 test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib"
5233 test -d $cf_subdir_prefix/lib/$cf_nculib_root && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root"
5234 test -d $cf_subdir_prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root/lib"
5235 test -d $cf_subdir_prefix/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib"
5236 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"
5241 cf_search="$cf_library_path_list $cf_search"
5243 for cf_libdir in $cf_search
5245 echo "$as_me:5245: checking for -l$cf_nculib_root in $cf_libdir" >&5
5246 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
5247 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
5248 cat >conftest.$ac_ext <<_ACEOF
5249 #line 5249 "configure"
5250 #include "confdefs.h"
5251 #include <${cf_cv_ncurses_header:-curses.h}>
5260 rm -f conftest.$ac_objext conftest$ac_exeext
5261 if { (eval echo "$as_me:5261: \"$ac_link\"") >&5
5262 (eval $ac_link) 2>&5
5264 echo "$as_me:5264: \$? = $ac_status" >&5
5265 (exit $ac_status); } &&
5266 { ac_try='test -s conftest$ac_exeext'
5267 { (eval echo "$as_me:5267: \"$ac_try\"") >&5
5270 echo "$as_me:5270: \$? = $ac_status" >&5
5271 (exit $ac_status); }; }; then
5272 echo "$as_me:5272: result: yes" >&5
5273 echo "${ECHO_T}yes" >&6
5274 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
5277 echo "$as_me: failed program was:" >&5
5278 cat conftest.$ac_ext >&5
5279 echo "$as_me:5279: result: no" >&5
5280 echo "${ECHO_T}no" >&6
5281 LIBS="$cf_save_LIBS"
5283 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5287 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5291 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
5293 if test $cf_found_library = no ; then
5294 { { echo "$as_me:5294: error: Cannot link $cf_nculib_root library" >&5
5295 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
5296 { (exit 1); exit 1; }; }
5301 if test -n "$cf_ncurses_LIBS" ; then
5302 echo "$as_me:5302: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
5303 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
5304 cf_ncurses_SAVE="$LIBS"
5305 for p in $cf_ncurses_LIBS ; do
5306 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
5307 if test "$q" != "$LIBS" ; then
5311 cat >conftest.$ac_ext <<_ACEOF
5312 #line 5312 "configure"
5313 #include "confdefs.h"
5314 #include <${cf_cv_ncurses_header:-curses.h}>
5318 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
5323 rm -f conftest.$ac_objext conftest$ac_exeext
5324 if { (eval echo "$as_me:5324: \"$ac_link\"") >&5
5325 (eval $ac_link) 2>&5
5327 echo "$as_me:5327: \$? = $ac_status" >&5
5328 (exit $ac_status); } &&
5329 { ac_try='test -s conftest$ac_exeext'
5330 { (eval echo "$as_me:5330: \"$ac_try\"") >&5
5333 echo "$as_me:5333: \$? = $ac_status" >&5
5334 (exit $ac_status); }; }; then
5335 echo "$as_me:5335: result: yes" >&5
5336 echo "${ECHO_T}yes" >&6
5338 echo "$as_me: failed program was:" >&5
5339 cat conftest.$ac_ext >&5
5340 echo "$as_me:5340: result: no" >&5
5341 echo "${ECHO_T}no" >&6
5342 LIBS="$cf_ncurses_SAVE"
5344 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5347 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
5349 cat >>confdefs.h <<EOF
5350 #define $cf_nculib_ROOT 1
5358 echo "$as_me:5358: checking if you want wide-character code" >&5
5359 echo $ECHO_N "checking if you want wide-character code... $ECHO_C" >&6
5361 # Check whether --enable-widec or --disable-widec was given.
5362 if test "${enable_widec+set}" = set; then
5363 enableval="$enable_widec"
5364 with_widec=$enableval
5368 echo "$as_me:5368: result: $with_widec" >&5
5369 echo "${ECHO_T}$with_widec" >&6
5370 if test "$with_widec" = yes ; then
5372 echo "$as_me:5372: checking for multibyte character support" >&5
5373 echo $ECHO_N "checking for multibyte character support... $ECHO_C" >&6
5374 if test "${cf_cv_utf8_lib+set}" = set; then
5375 echo $ECHO_N "(cached) $ECHO_C" >&6
5378 cf_save_LIBS="$LIBS"
5379 cat >conftest.$ac_ext <<_ACEOF
5380 #line 5380 "configure"
5381 #include "confdefs.h"
5392 rm -f conftest.$ac_objext conftest$ac_exeext
5393 if { (eval echo "$as_me:5393: \"$ac_link\"") >&5
5394 (eval $ac_link) 2>&5
5396 echo "$as_me:5396: \$? = $ac_status" >&5
5397 (exit $ac_status); } &&
5398 { ac_try='test -s conftest$ac_exeext'
5399 { (eval echo "$as_me:5399: \"$ac_try\"") >&5
5402 echo "$as_me:5402: \$? = $ac_status" >&5
5403 (exit $ac_status); }; }; then
5406 echo "$as_me: failed program was:" >&5
5407 cat conftest.$ac_ext >&5
5409 # If the linkage is not already in the $CPPFLAGS/$LDFLAGS configuration, these
5410 # will be set on completion of the AC_TRY_LINK below.
5411 cf_cv_header_path_utf8=
5412 cf_cv_library_path_utf8=
5414 echo "${as_me:-configure}:5414: testing Starting FIND_LINKAGE(utf8,) ..." 1>&5
5416 cf_save_LIBS="$LIBS"
5418 cat >conftest.$ac_ext <<_ACEOF
5419 #line 5419 "configure"
5420 #include "confdefs.h"
5422 #include <libutf8.h>
5431 rm -f conftest.$ac_objext conftest$ac_exeext
5432 if { (eval echo "$as_me:5432: \"$ac_link\"") >&5
5433 (eval $ac_link) 2>&5
5435 echo "$as_me:5435: \$? = $ac_status" >&5
5436 (exit $ac_status); } &&
5437 { ac_try='test -s conftest$ac_exeext'
5438 { (eval echo "$as_me:5438: \"$ac_try\"") >&5
5441 echo "$as_me:5441: \$? = $ac_status" >&5
5442 (exit $ac_status); }; }; then
5444 cf_cv_find_linkage_utf8=yes
5445 cf_cv_header_path_utf8=/usr/include
5446 cf_cv_library_path_utf8=/usr/lib
5449 echo "$as_me: failed program was:" >&5
5450 cat conftest.$ac_ext >&5
5452 LIBS="-lutf8 $cf_save_LIBS"
5454 cat >conftest.$ac_ext <<_ACEOF
5455 #line 5455 "configure"
5456 #include "confdefs.h"
5458 #include <libutf8.h>
5467 rm -f conftest.$ac_objext conftest$ac_exeext
5468 if { (eval echo "$as_me:5468: \"$ac_link\"") >&5
5469 (eval $ac_link) 2>&5
5471 echo "$as_me:5471: \$? = $ac_status" >&5
5472 (exit $ac_status); } &&
5473 { ac_try='test -s conftest$ac_exeext'
5474 { (eval echo "$as_me:5474: \"$ac_try\"") >&5
5477 echo "$as_me:5477: \$? = $ac_status" >&5
5478 (exit $ac_status); }; }; then
5480 cf_cv_find_linkage_utf8=yes
5481 cf_cv_header_path_utf8=/usr/include
5482 cf_cv_library_path_utf8=/usr/lib
5483 cf_cv_library_file_utf8="-lutf8"
5486 echo "$as_me: failed program was:" >&5
5487 cat conftest.$ac_ext >&5
5489 cf_cv_find_linkage_utf8=no
5490 LIBS="$cf_save_LIBS"
5492 test -n "$verbose" && echo " find linkage for utf8 library" 1>&6
5494 echo "${as_me:-configure}:5494: testing find linkage for utf8 library ..." 1>&5
5496 echo "${as_me:-configure}:5496: testing Searching for headers in FIND_LINKAGE(utf8,) ..." 1>&5
5498 cf_save_CPPFLAGS="$CPPFLAGS"
5499 cf_test_CPPFLAGS="$CPPFLAGS"
5503 # collect the current set of include-directories from compiler flags
5504 cf_header_path_list=""
5505 if test -n "${CFLAGS}${CPPFLAGS}" ; then
5506 for cf_header_path in $CPPFLAGS $CFLAGS
5508 case $cf_header_path in
5510 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
5512 test "x$cf_header_path" != "xNONE" && \
5513 test -d "$cf_header_path" && \
5515 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
5516 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
5517 test -d $cf_header_path/include/utf8 && cf_search="$cf_search $cf_header_path/include/utf8"
5518 test -d $cf_header_path/include/utf8/include && cf_search="$cf_search $cf_header_path/include/utf8/include"
5519 test -d $cf_header_path/utf8/include && cf_search="$cf_search $cf_header_path/utf8/include"
5520 test -d $cf_header_path/utf8/include/utf8 && cf_search="$cf_search $cf_header_path/utf8/include/utf8"
5523 cf_header_path_list="$cf_header_path_list $cf_search"
5529 # add the variations for the package we are looking for
5533 test "x$prefix" != "xNONE" && \
5534 test -d "$prefix" && \
5536 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
5537 test -d $prefix/include && cf_search="$cf_search $prefix/include"
5538 test -d $prefix/include/utf8 && cf_search="$cf_search $prefix/include/utf8"
5539 test -d $prefix/include/utf8/include && cf_search="$cf_search $prefix/include/utf8/include"
5540 test -d $prefix/utf8/include && cf_search="$cf_search $prefix/utf8/include"
5541 test -d $prefix/utf8/include/utf8 && cf_search="$cf_search $prefix/utf8/include/utf8"
5544 for cf_subdir_prefix in \
5553 test "x$cf_subdir_prefix" != "x$prefix" && \
5554 test -d "$cf_subdir_prefix" && \
5555 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
5556 test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
5557 test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include"
5558 test -d $cf_subdir_prefix/include/utf8 && cf_search="$cf_search $cf_subdir_prefix/include/utf8"
5559 test -d $cf_subdir_prefix/include/utf8/include && cf_search="$cf_search $cf_subdir_prefix/include/utf8/include"
5560 test -d $cf_subdir_prefix/utf8/include && cf_search="$cf_search $cf_subdir_prefix/utf8/include"
5561 test -d $cf_subdir_prefix/utf8/include/utf8 && cf_search="$cf_search $cf_subdir_prefix/utf8/include/utf8"
5566 test "$includedir" != NONE && \
5567 test "$includedir" != "/usr/include" && \
5568 test -d "$includedir" && {
5569 test -d $includedir && cf_search="$cf_search $includedir"
5570 test -d $includedir/utf8 && cf_search="$cf_search $includedir/utf8"
5573 test "$oldincludedir" != NONE && \
5574 test "$oldincludedir" != "/usr/include" && \
5575 test -d "$oldincludedir" && {
5576 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
5577 test -d $oldincludedir/utf8 && cf_search="$cf_search $oldincludedir/utf8"
5580 cf_search="$cf_search $cf_header_path_list"
5582 for cf_cv_header_path_utf8 in $cf_search
5584 if test -d $cf_cv_header_path_utf8 ; then
5585 test -n "$verbose" && echo " ... testing $cf_cv_header_path_utf8" 1>&6
5587 echo "${as_me:-configure}:5587: testing ... testing $cf_cv_header_path_utf8 ..." 1>&5
5589 CPPFLAGS="$cf_save_CPPFLAGS -I$cf_cv_header_path_utf8"
5590 cat >conftest.$ac_ext <<_ACEOF
5591 #line 5591 "configure"
5592 #include "confdefs.h"
5594 #include <libutf8.h>
5603 rm -f conftest.$ac_objext
5604 if { (eval echo "$as_me:5604: \"$ac_compile\"") >&5
5605 (eval $ac_compile) 2>&5
5607 echo "$as_me:5607: \$? = $ac_status" >&5
5608 (exit $ac_status); } &&
5609 { ac_try='test -s conftest.$ac_objext'
5610 { (eval echo "$as_me:5610: \"$ac_try\"") >&5
5613 echo "$as_me:5613: \$? = $ac_status" >&5
5614 (exit $ac_status); }; }; then
5616 test -n "$verbose" && echo " ... found utf8 headers in $cf_cv_header_path_utf8" 1>&6
5618 echo "${as_me:-configure}:5618: testing ... found utf8 headers in $cf_cv_header_path_utf8 ..." 1>&5
5620 cf_cv_find_linkage_utf8=maybe
5621 cf_test_CPPFLAGS="$CPPFLAGS"
5624 echo "$as_me: failed program was:" >&5
5625 cat conftest.$ac_ext >&5
5627 CPPFLAGS="$cf_save_CPPFLAGS"
5630 rm -f conftest.$ac_objext conftest.$ac_ext
5634 if test "$cf_cv_find_linkage_utf8" = maybe ; then
5636 echo "${as_me:-configure}:5636: testing Searching for utf8 library in FIND_LINKAGE(utf8,) ..." 1>&5
5638 cf_save_LIBS="$LIBS"
5639 cf_save_LDFLAGS="$LDFLAGS"
5641 if test "$cf_cv_find_linkage_utf8" != yes ; then
5644 cf_library_path_list=""
5645 if test -n "${LDFLAGS}${LIBS}" ; then
5646 for cf_library_path in $LDFLAGS $LIBS
5648 case $cf_library_path in
5650 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
5652 test "x$cf_library_path" != "xNONE" && \
5653 test -d "$cf_library_path" && \
5655 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
5656 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
5657 test -d $cf_library_path/lib/utf8 && cf_search="$cf_search $cf_library_path/lib/utf8"
5658 test -d $cf_library_path/lib/utf8/lib && cf_search="$cf_search $cf_library_path/lib/utf8/lib"
5659 test -d $cf_library_path/utf8/lib && cf_search="$cf_search $cf_library_path/utf8/lib"
5660 test -d $cf_library_path/utf8/lib/utf8 && cf_search="$cf_search $cf_library_path/utf8/lib/utf8"
5663 cf_library_path_list="$cf_library_path_list $cf_search"
5671 test "x$prefix" != "xNONE" && \
5672 test -d "$prefix" && \
5674 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
5675 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
5676 test -d $prefix/lib/utf8 && cf_search="$cf_search $prefix/lib/utf8"
5677 test -d $prefix/lib/utf8/lib && cf_search="$cf_search $prefix/lib/utf8/lib"
5678 test -d $prefix/utf8/lib && cf_search="$cf_search $prefix/utf8/lib"
5679 test -d $prefix/utf8/lib/utf8 && cf_search="$cf_search $prefix/utf8/lib/utf8"
5682 for cf_subdir_prefix in \
5691 test "x$cf_subdir_prefix" != "x$prefix" && \
5692 test -d "$cf_subdir_prefix" && \
5693 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
5694 test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
5695 test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib"
5696 test -d $cf_subdir_prefix/lib/utf8 && cf_search="$cf_search $cf_subdir_prefix/lib/utf8"
5697 test -d $cf_subdir_prefix/lib/utf8/lib && cf_search="$cf_search $cf_subdir_prefix/lib/utf8/lib"
5698 test -d $cf_subdir_prefix/utf8/lib && cf_search="$cf_search $cf_subdir_prefix/utf8/lib"
5699 test -d $cf_subdir_prefix/utf8/lib/utf8 && cf_search="$cf_search $cf_subdir_prefix/utf8/lib/utf8"
5704 cf_search="$cf_library_path_list $cf_search"
5706 for cf_cv_library_path_utf8 in $cf_search
5708 if test -d $cf_cv_library_path_utf8 ; then
5709 test -n "$verbose" && echo " ... testing $cf_cv_library_path_utf8" 1>&6
5711 echo "${as_me:-configure}:5711: testing ... testing $cf_cv_library_path_utf8 ..." 1>&5
5713 CPPFLAGS="$cf_test_CPPFLAGS"
5714 LIBS="-lutf8 $cf_save_LIBS"
5715 LDFLAGS="$cf_save_LDFLAGS -L$cf_cv_library_path_utf8"
5716 cat >conftest.$ac_ext <<_ACEOF
5717 #line 5717 "configure"
5718 #include "confdefs.h"
5720 #include <libutf8.h>
5729 rm -f conftest.$ac_objext conftest$ac_exeext
5730 if { (eval echo "$as_me:5730: \"$ac_link\"") >&5
5731 (eval $ac_link) 2>&5
5733 echo "$as_me:5733: \$? = $ac_status" >&5
5734 (exit $ac_status); } &&
5735 { ac_try='test -s conftest$ac_exeext'
5736 { (eval echo "$as_me:5736: \"$ac_try\"") >&5
5739 echo "$as_me:5739: \$? = $ac_status" >&5
5740 (exit $ac_status); }; }; then
5742 test -n "$verbose" && echo " ... found utf8 library in $cf_cv_library_path_utf8" 1>&6
5744 echo "${as_me:-configure}:5744: testing ... found utf8 library in $cf_cv_library_path_utf8 ..." 1>&5
5746 cf_cv_find_linkage_utf8=yes
5747 cf_cv_library_file_utf8="-lutf8"
5750 echo "$as_me: failed program was:" >&5
5751 cat conftest.$ac_ext >&5
5753 CPPFLAGS="$cf_save_CPPFLAGS"
5754 LIBS="$cf_save_LIBS"
5755 LDFLAGS="$cf_save_LDFLAGS"
5758 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5761 CPPFLAGS="$cf_save_CPPFLAGS"
5762 LDFLAGS="$cf_save_LDFLAGS"
5766 cf_cv_find_linkage_utf8=no
5770 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5773 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5775 LIBS="$cf_save_LIBS"
5777 if test "$cf_cv_find_linkage_utf8" = yes ; then
5778 cf_cv_utf8_lib=add-on
5784 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5786 echo "$as_me:5786: result: $cf_cv_utf8_lib" >&5
5787 echo "${ECHO_T}$cf_cv_utf8_lib" >&6
5789 # HAVE_LIBUTF8_H is used by ncurses if curses.h is shared between
5791 if test "$cf_cv_utf8_lib" = "add-on" ; then
5793 cat >>confdefs.h <<\EOF
5794 #define HAVE_LIBUTF8_H 1
5797 if test -n "$cf_cv_header_path_utf8" ; then
5798 for cf_add_incdir in $cf_cv_header_path_utf8
5800 while test $cf_add_incdir != /usr/include
5802 if test -d $cf_add_incdir
5805 if test -n "$CFLAGS$CPPFLAGS" ; then
5806 # a loop is needed to ensure we can add subdirs of existing dirs
5807 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
5808 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
5809 cf_have_incdir=yes; break
5814 if test "$cf_have_incdir" = no ; then
5815 if test "$cf_add_incdir" = /usr/local/include ; then
5816 if test "$GCC" = yes
5818 cf_save_CPPFLAGS=$CPPFLAGS
5819 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
5820 cat >conftest.$ac_ext <<_ACEOF
5821 #line 5821 "configure"
5822 #include "confdefs.h"
5832 rm -f conftest.$ac_objext
5833 if { (eval echo "$as_me:5833: \"$ac_compile\"") >&5
5834 (eval $ac_compile) 2>&5
5836 echo "$as_me:5836: \$? = $ac_status" >&5
5837 (exit $ac_status); } &&
5838 { ac_try='test -s conftest.$ac_objext'
5839 { (eval echo "$as_me:5839: \"$ac_try\"") >&5
5842 echo "$as_me:5842: \$? = $ac_status" >&5
5843 (exit $ac_status); }; }; then
5846 echo "$as_me: failed program was:" >&5
5847 cat conftest.$ac_ext >&5
5850 rm -f conftest.$ac_objext conftest.$ac_ext
5851 CPPFLAGS=$cf_save_CPPFLAGS
5856 if test "$cf_have_incdir" = no ; then
5857 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
5859 echo "${as_me:-configure}:5859: testing adding $cf_add_incdir to include-path ..." 1>&5
5861 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
5863 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
5864 test "$cf_top_incdir" = "$cf_add_incdir" && break
5865 cf_add_incdir="$cf_top_incdir"
5876 if test -n "$cf_cv_library_path_utf8" ; then
5877 for cf_add_libdir in $cf_cv_library_path_utf8
5879 if test $cf_add_libdir = /usr/lib ; then
5881 elif test -d $cf_add_libdir
5884 if test -n "$LDFLAGS$LIBS" ; then
5885 # a loop is needed to ensure we can add subdirs of existing dirs
5886 for cf_test_libdir in $LDFLAGS $LIBS ; do
5887 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
5888 cf_have_libdir=yes; break
5892 if test "$cf_have_libdir" = no ; then
5893 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
5895 echo "${as_me:-configure}:5895: testing adding $cf_add_libdir to library-path ..." 1>&5
5897 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
5903 cf_add_libs="$cf_cv_library_file_utf8"
5904 # Filter out duplicates - this happens with badly-designed ".pc" files...
5905 for cf_add_1lib in $LIBS
5907 for cf_add_2lib in $cf_add_libs
5909 if test "x$cf_add_1lib" = "x$cf_add_2lib"
5915 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
5921 cf_ncuconfig_root=ncursesw
5922 cf_have_ncuconfig=no
5924 if test "x${PKG_CONFIG:=none}" != xnone; then
5925 echo "$as_me:5925: checking pkg-config for $cf_ncuconfig_root" >&5
5926 echo $ECHO_N "checking pkg-config for $cf_ncuconfig_root... $ECHO_C" >&6
5927 if "$PKG_CONFIG" --exists $cf_ncuconfig_root ; then
5928 echo "$as_me:5928: result: yes" >&5
5929 echo "${ECHO_T}yes" >&6
5931 echo "$as_me:5931: checking if the $cf_ncuconfig_root package files work" >&5
5932 echo $ECHO_N "checking if the $cf_ncuconfig_root package files work... $ECHO_C" >&6
5933 cf_have_ncuconfig=unknown
5935 cf_save_CPPFLAGS="$CPPFLAGS"
5936 cf_save_LIBS="$LIBS"
5938 CPPFLAGS="$CPPFLAGS `$PKG_CONFIG --cflags $cf_ncuconfig_root`"
5940 cf_add_libs="`$PKG_CONFIG --libs $cf_ncuconfig_root`"
5941 # Filter out duplicates - this happens with badly-designed ".pc" files...
5942 for cf_add_1lib in $LIBS
5944 for cf_add_2lib in $cf_add_libs
5946 if test "x$cf_add_1lib" = "x$cf_add_2lib"
5952 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
5956 cat >conftest.$ac_ext <<_ACEOF
5957 #line 5957 "configure"
5958 #include "confdefs.h"
5959 #include <${cf_cv_ncurses_header:-curses.h}>
5963 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
5968 rm -f conftest.$ac_objext conftest$ac_exeext
5969 if { (eval echo "$as_me:5969: \"$ac_link\"") >&5
5970 (eval $ac_link) 2>&5
5972 echo "$as_me:5972: \$? = $ac_status" >&5
5973 (exit $ac_status); } &&
5974 { ac_try='test -s conftest$ac_exeext'
5975 { (eval echo "$as_me:5975: \"$ac_try\"") >&5
5978 echo "$as_me:5978: \$? = $ac_status" >&5
5979 (exit $ac_status); }; }; then
5980 if test "$cross_compiling" = yes; then
5981 cf_have_ncuconfig=maybe
5983 cat >conftest.$ac_ext <<_ACEOF
5984 #line 5984 "configure"
5985 #include "confdefs.h"
5986 #include <${cf_cv_ncurses_header:-curses.h}>
5988 { char *xx = curses_version(); return (xx == 0); }
5990 rm -f conftest$ac_exeext
5991 if { (eval echo "$as_me:5991: \"$ac_link\"") >&5
5992 (eval $ac_link) 2>&5
5994 echo "$as_me:5994: \$? = $ac_status" >&5
5995 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5996 { (eval echo "$as_me:5996: \"$ac_try\"") >&5
5999 echo "$as_me:5999: \$? = $ac_status" >&5
6000 (exit $ac_status); }; }; then
6001 cf_have_ncuconfig=yes
6003 echo "$as_me: program exited with status $ac_status" >&5
6004 echo "$as_me: failed program was:" >&5
6005 cat conftest.$ac_ext >&5
6006 cf_have_ncuconfig=no
6008 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6011 echo "$as_me: failed program was:" >&5
6012 cat conftest.$ac_ext >&5
6013 cf_have_ncuconfig=no
6015 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6016 echo "$as_me:6016: result: $cf_have_ncuconfig" >&5
6017 echo "${ECHO_T}$cf_have_ncuconfig" >&6
6018 test "$cf_have_ncuconfig" = maybe && cf_have_ncuconfig=yes
6019 if test "$cf_have_ncuconfig" != "yes"
6021 CPPFLAGS="$cf_save_CPPFLAGS"
6022 LIBS="$cf_save_LIBS"
6023 NCURSES_CONFIG_PKG=none
6026 cat >>confdefs.h <<\EOF
6030 NCURSES_CONFIG_PKG=$cf_ncuconfig_root
6033 echo "$as_me:6033: checking for terminfo header" >&5
6034 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
6035 if test "${cf_cv_term_header+set}" = set; then
6036 echo $ECHO_N "(cached) $ECHO_C" >&6
6039 case ${cf_cv_ncurses_header} in
6040 (*/ncurses.h|*/ncursesw.h)
6041 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
6044 cf_term_header=term.h
6048 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
6050 cat >conftest.$ac_ext <<_ACEOF
6051 #line 6051 "configure"
6052 #include "confdefs.h"
6054 #include <${cf_cv_ncurses_header:-curses.h}>
6060 int x = auto_left_margin
6065 rm -f conftest.$ac_objext
6066 if { (eval echo "$as_me:6066: \"$ac_compile\"") >&5
6067 (eval $ac_compile) 2>&5
6069 echo "$as_me:6069: \$? = $ac_status" >&5
6070 (exit $ac_status); } &&
6071 { ac_try='test -s conftest.$ac_objext'
6072 { (eval echo "$as_me:6072: \"$ac_try\"") >&5
6075 echo "$as_me:6075: \$? = $ac_status" >&5
6076 (exit $ac_status); }; }; then
6078 cf_cv_term_header="$cf_test"
6080 echo "$as_me: failed program was:" >&5
6081 cat conftest.$ac_ext >&5
6083 cf_cv_term_header=unknown
6086 rm -f conftest.$ac_objext conftest.$ac_ext
6087 test "$cf_cv_term_header" != unknown && break
6091 echo "$as_me:6091: result: $cf_cv_term_header" >&5
6092 echo "${ECHO_T}$cf_cv_term_header" >&6
6094 # Set definitions to allow ifdef'ing to accommodate subdirectories
6096 case $cf_cv_term_header in
6099 cat >>confdefs.h <<\EOF
6100 #define HAVE_TERM_H 1
6106 case $cf_cv_term_header in
6109 cat >>confdefs.h <<\EOF
6110 #define HAVE_NCURSES_TERM_H 1
6116 cat >>confdefs.h <<\EOF
6117 #define HAVE_NCURSESW_TERM_H 1
6124 echo "$as_me:6124: result: no" >&5
6125 echo "${ECHO_T}no" >&6
6126 NCURSES_CONFIG_PKG=none
6129 NCURSES_CONFIG_PKG=none
6132 if test "x$cf_have_ncuconfig" = "xno"; then
6133 echo "Looking for ${cf_ncuconfig_root}-config"
6135 if test -n "$ac_tool_prefix"; then
6136 for ac_prog in ${cf_ncuconfig_root}-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
6138 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
6139 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
6140 echo "$as_me:6140: checking for $ac_word" >&5
6141 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
6142 if test "${ac_cv_prog_NCURSES_CONFIG+set}" = set; then
6143 echo $ECHO_N "(cached) $ECHO_C" >&6
6145 if test -n "$NCURSES_CONFIG"; then
6146 ac_cv_prog_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test.
6148 ac_save_IFS=$IFS; IFS=$ac_path_separator
6150 for ac_dir in $ac_dummy; do
6152 test -z "$ac_dir" && ac_dir=.
6153 $as_executable_p "$ac_dir/$ac_word" || continue
6154 ac_cv_prog_NCURSES_CONFIG="$ac_tool_prefix$ac_prog"
6155 echo "$as_me:6155: found $ac_dir/$ac_word" >&5
6161 NCURSES_CONFIG=$ac_cv_prog_NCURSES_CONFIG
6162 if test -n "$NCURSES_CONFIG"; then
6163 echo "$as_me:6163: result: $NCURSES_CONFIG" >&5
6164 echo "${ECHO_T}$NCURSES_CONFIG" >&6
6166 echo "$as_me:6166: result: no" >&5
6167 echo "${ECHO_T}no" >&6
6170 test -n "$NCURSES_CONFIG" && break
6173 if test -z "$NCURSES_CONFIG"; then
6174 ac_ct_NCURSES_CONFIG=$NCURSES_CONFIG
6175 for ac_prog in ${cf_ncuconfig_root}-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
6177 # Extract the first word of "$ac_prog", so it can be a program name with args.
6178 set dummy $ac_prog; ac_word=$2
6179 echo "$as_me:6179: checking for $ac_word" >&5
6180 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
6181 if test "${ac_cv_prog_ac_ct_NCURSES_CONFIG+set}" = set; then
6182 echo $ECHO_N "(cached) $ECHO_C" >&6
6184 if test -n "$ac_ct_NCURSES_CONFIG"; then
6185 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_ct_NCURSES_CONFIG" # Let the user override the test.
6187 ac_save_IFS=$IFS; IFS=$ac_path_separator
6189 for ac_dir in $ac_dummy; do
6191 test -z "$ac_dir" && ac_dir=.
6192 $as_executable_p "$ac_dir/$ac_word" || continue
6193 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_prog"
6194 echo "$as_me:6194: found $ac_dir/$ac_word" >&5
6200 ac_ct_NCURSES_CONFIG=$ac_cv_prog_ac_ct_NCURSES_CONFIG
6201 if test -n "$ac_ct_NCURSES_CONFIG"; then
6202 echo "$as_me:6202: result: $ac_ct_NCURSES_CONFIG" >&5
6203 echo "${ECHO_T}$ac_ct_NCURSES_CONFIG" >&6
6205 echo "$as_me:6205: result: no" >&5
6206 echo "${ECHO_T}no" >&6
6209 test -n "$ac_ct_NCURSES_CONFIG" && break
6211 test -n "$ac_ct_NCURSES_CONFIG" || ac_ct_NCURSES_CONFIG="none"
6213 NCURSES_CONFIG=$ac_ct_NCURSES_CONFIG
6216 if test "$NCURSES_CONFIG" != none ; then
6218 CPPFLAGS="$CPPFLAGS `$NCURSES_CONFIG --cflags`"
6220 cf_add_libs="`$NCURSES_CONFIG --libs`"
6221 # Filter out duplicates - this happens with badly-designed ".pc" files...
6222 for cf_add_1lib in $LIBS
6224 for cf_add_2lib in $cf_add_libs
6226 if test "x$cf_add_1lib" = "x$cf_add_2lib"
6232 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
6236 # even with config script, some packages use no-override for curses.h
6238 echo "$as_me:6238: checking if we have identified curses headers" >&5
6239 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
6240 if test "${cf_cv_ncurses_header+set}" = set; then
6241 echo $ECHO_N "(cached) $ECHO_C" >&6
6244 cf_cv_ncurses_header=none
6246 ncurses.h ncursesw/ncurses.h \
6247 curses.h ncursesw/curses.h
6249 cat >conftest.$ac_ext <<_ACEOF
6250 #line 6250 "configure"
6251 #include "confdefs.h"
6252 #include <${cf_header}>
6256 initscr(); tgoto("?", 0,0)
6261 rm -f conftest.$ac_objext
6262 if { (eval echo "$as_me:6262: \"$ac_compile\"") >&5
6263 (eval $ac_compile) 2>&5
6265 echo "$as_me:6265: \$? = $ac_status" >&5
6266 (exit $ac_status); } &&
6267 { ac_try='test -s conftest.$ac_objext'
6268 { (eval echo "$as_me:6268: \"$ac_try\"") >&5
6271 echo "$as_me:6271: \$? = $ac_status" >&5
6272 (exit $ac_status); }; }; then
6273 cf_cv_ncurses_header=$cf_header; break
6275 echo "$as_me: failed program was:" >&5
6276 cat conftest.$ac_ext >&5
6278 rm -f conftest.$ac_objext conftest.$ac_ext
6282 echo "$as_me:6282: result: $cf_cv_ncurses_header" >&5
6283 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
6285 if test "$cf_cv_ncurses_header" = none ; then
6286 { { echo "$as_me:6286: error: No curses header-files found" >&5
6287 echo "$as_me: error: No curses header-files found" >&2;}
6288 { (exit 1); exit 1; }; }
6291 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
6293 for ac_header in $cf_cv_ncurses_header
6295 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6296 echo "$as_me:6296: checking for $ac_header" >&5
6297 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6298 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6299 echo $ECHO_N "(cached) $ECHO_C" >&6
6301 cat >conftest.$ac_ext <<_ACEOF
6302 #line 6302 "configure"
6303 #include "confdefs.h"
6304 #include <$ac_header>
6306 if { (eval echo "$as_me:6306: \"$ac_cpp conftest.$ac_ext\"") >&5
6307 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6309 egrep -v '^ *\+' conftest.er1 >conftest.err
6311 cat conftest.err >&5
6312 echo "$as_me:6312: \$? = $ac_status" >&5
6313 (exit $ac_status); } >/dev/null; then
6314 if test -s conftest.err; then
6315 ac_cpp_err=$ac_c_preproc_warn_flag
6322 if test -z "$ac_cpp_err"; then
6323 eval "$as_ac_Header=yes"
6325 echo "$as_me: failed program was:" >&5
6326 cat conftest.$ac_ext >&5
6327 eval "$as_ac_Header=no"
6329 rm -f conftest.err conftest.$ac_ext
6331 echo "$as_me:6331: result: `eval echo '${'$as_ac_Header'}'`" >&5
6332 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6333 if test `eval echo '${'$as_ac_Header'}'` = yes; then
6334 cat >>confdefs.h <<EOF
6335 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6341 cat >>confdefs.h <<\EOF
6345 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
6347 cat >>confdefs.h <<EOF
6348 #define $cf_nculib_ROOT 1
6351 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
6355 cf_ncuhdr_root=ncursesw
6357 test -n "$cf_cv_curses_dir" && \
6358 test "$cf_cv_curses_dir" != "no" && { \
6360 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
6361 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
6363 while test $cf_add_incdir != /usr/include
6365 if test -d $cf_add_incdir
6368 if test -n "$CFLAGS$CPPFLAGS" ; then
6369 # a loop is needed to ensure we can add subdirs of existing dirs
6370 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
6371 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
6372 cf_have_incdir=yes; break
6377 if test "$cf_have_incdir" = no ; then
6378 if test "$cf_add_incdir" = /usr/local/include ; then
6379 if test "$GCC" = yes
6381 cf_save_CPPFLAGS=$CPPFLAGS
6382 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6383 cat >conftest.$ac_ext <<_ACEOF
6384 #line 6384 "configure"
6385 #include "confdefs.h"
6395 rm -f conftest.$ac_objext
6396 if { (eval echo "$as_me:6396: \"$ac_compile\"") >&5
6397 (eval $ac_compile) 2>&5
6399 echo "$as_me:6399: \$? = $ac_status" >&5
6400 (exit $ac_status); } &&
6401 { ac_try='test -s conftest.$ac_objext'
6402 { (eval echo "$as_me:6402: \"$ac_try\"") >&5
6405 echo "$as_me:6405: \$? = $ac_status" >&5
6406 (exit $ac_status); }; }; then
6409 echo "$as_me: failed program was:" >&5
6410 cat conftest.$ac_ext >&5
6413 rm -f conftest.$ac_objext conftest.$ac_ext
6414 CPPFLAGS=$cf_save_CPPFLAGS
6419 if test "$cf_have_incdir" = no ; then
6420 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
6422 echo "${as_me:-configure}:6422: testing adding $cf_add_incdir to include-path ..." 1>&5
6424 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6426 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
6427 test "$cf_top_incdir" = "$cf_add_incdir" && break
6428 cf_add_incdir="$cf_top_incdir"
6441 echo "$as_me:6441: checking for $cf_ncuhdr_root header in include-path" >&5
6442 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
6443 if test "${cf_cv_ncurses_h+set}" = set; then
6444 echo $ECHO_N "(cached) $ECHO_C" >&6
6447 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
6448 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
6449 for cf_header in $cf_header_list
6452 cat >conftest.$ac_ext <<_ACEOF
6453 #line 6453 "configure"
6454 #include "confdefs.h"
6456 #define _XOPEN_SOURCE_EXTENDED
6457 #undef HAVE_LIBUTF8_H /* in case we used CF_UTF8_LIB */
6458 #define HAVE_LIBUTF8_H /* to force ncurses' header file to use cchar_t */
6460 #include <$cf_header>
6465 #ifdef NCURSES_VERSION
6471 printf("%s\n", NCURSES_VERSION);
6484 rm -f conftest.$ac_objext
6485 if { (eval echo "$as_me:6485: \"$ac_compile\"") >&5
6486 (eval $ac_compile) 2>&5
6488 echo "$as_me:6488: \$? = $ac_status" >&5
6489 (exit $ac_status); } &&
6490 { ac_try='test -s conftest.$ac_objext'
6491 { (eval echo "$as_me:6491: \"$ac_try\"") >&5
6494 echo "$as_me:6494: \$? = $ac_status" >&5
6495 (exit $ac_status); }; }; then
6496 cf_cv_ncurses_h=$cf_header
6499 echo "$as_me: failed program was:" >&5
6500 cat conftest.$ac_ext >&5
6503 rm -f conftest.$ac_objext conftest.$ac_ext
6505 test "$cf_cv_ncurses_h" != no && break
6509 echo "$as_me:6509: result: $cf_cv_ncurses_h" >&5
6510 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
6512 if test "$cf_cv_ncurses_h" != no ; then
6513 cf_cv_ncurses_header=$cf_cv_ncurses_h
6516 echo "$as_me:6516: checking for $cf_ncuhdr_root include-path" >&5
6517 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
6518 if test "${cf_cv_ncurses_h2+set}" = set; then
6519 echo $ECHO_N "(cached) $ECHO_C" >&6
6522 test -n "$verbose" && echo
6526 # collect the current set of include-directories from compiler flags
6527 cf_header_path_list=""
6528 if test -n "${CFLAGS}${CPPFLAGS}" ; then
6529 for cf_header_path in $CPPFLAGS $CFLAGS
6531 case $cf_header_path in
6533 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
6535 test "x$cf_header_path" != "xNONE" && \
6536 test -d "$cf_header_path" && \
6538 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
6539 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
6540 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
6541 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
6542 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
6543 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"
6546 cf_header_path_list="$cf_header_path_list $cf_search"
6552 # add the variations for the package we are looking for
6556 test "x$prefix" != "xNONE" && \
6557 test -d "$prefix" && \
6559 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
6560 test -d $prefix/include && cf_search="$cf_search $prefix/include"
6561 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
6562 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
6563 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
6564 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
6567 for cf_subdir_prefix in \
6576 test "x$cf_subdir_prefix" != "x$prefix" && \
6577 test -d "$cf_subdir_prefix" && \
6578 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
6579 test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
6580 test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include"
6581 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root"
6582 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root/include"
6583 test -d $cf_subdir_prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include"
6584 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"
6589 test "$includedir" != NONE && \
6590 test "$includedir" != "/usr/include" && \
6591 test -d "$includedir" && {
6592 test -d $includedir && cf_search="$cf_search $includedir"
6593 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
6596 test "$oldincludedir" != NONE && \
6597 test "$oldincludedir" != "/usr/include" && \
6598 test -d "$oldincludedir" && {
6599 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
6600 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
6603 cf_search="$cf_search $cf_header_path_list"
6605 test -n "$verbose" && echo search path $cf_search
6606 cf_save2_CPPFLAGS="$CPPFLAGS"
6607 for cf_incdir in $cf_search
6610 if test -n "$cf_incdir" ; then
6611 for cf_add_incdir in $cf_incdir
6613 while test $cf_add_incdir != /usr/include
6615 if test -d $cf_add_incdir
6618 if test -n "$CFLAGS$CPPFLAGS" ; then
6619 # a loop is needed to ensure we can add subdirs of existing dirs
6620 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
6621 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
6622 cf_have_incdir=yes; break
6627 if test "$cf_have_incdir" = no ; then
6628 if test "$cf_add_incdir" = /usr/local/include ; then
6629 if test "$GCC" = yes
6631 cf_save_CPPFLAGS=$CPPFLAGS
6632 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6633 cat >conftest.$ac_ext <<_ACEOF
6634 #line 6634 "configure"
6635 #include "confdefs.h"
6645 rm -f conftest.$ac_objext
6646 if { (eval echo "$as_me:6646: \"$ac_compile\"") >&5
6647 (eval $ac_compile) 2>&5
6649 echo "$as_me:6649: \$? = $ac_status" >&5
6650 (exit $ac_status); } &&
6651 { ac_try='test -s conftest.$ac_objext'
6652 { (eval echo "$as_me:6652: \"$ac_try\"") >&5
6655 echo "$as_me:6655: \$? = $ac_status" >&5
6656 (exit $ac_status); }; }; then
6659 echo "$as_me: failed program was:" >&5
6660 cat conftest.$ac_ext >&5
6663 rm -f conftest.$ac_objext conftest.$ac_ext
6664 CPPFLAGS=$cf_save_CPPFLAGS
6669 if test "$cf_have_incdir" = no ; then
6670 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
6672 echo "${as_me:-configure}:6672: testing adding $cf_add_incdir to include-path ..." 1>&5
6674 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6676 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
6677 test "$cf_top_incdir" = "$cf_add_incdir" && break
6678 cf_add_incdir="$cf_top_incdir"
6694 cat >conftest.$ac_ext <<_ACEOF
6695 #line 6695 "configure"
6696 #include "confdefs.h"
6698 #include <$cf_header>
6703 #ifdef NCURSES_VERSION
6705 printf("%s\n", NCURSES_VERSION);
6718 rm -f conftest.$ac_objext
6719 if { (eval echo "$as_me:6719: \"$ac_compile\"") >&5
6720 (eval $ac_compile) 2>&5
6722 echo "$as_me:6722: \$? = $ac_status" >&5
6723 (exit $ac_status); } &&
6724 { ac_try='test -s conftest.$ac_objext'
6725 { (eval echo "$as_me:6725: \"$ac_try\"") >&5
6728 echo "$as_me:6728: \$? = $ac_status" >&5
6729 (exit $ac_status); }; }; then
6730 cf_cv_ncurses_h2=$cf_header
6733 echo "$as_me: failed program was:" >&5
6734 cat conftest.$ac_ext >&5
6737 rm -f conftest.$ac_objext conftest.$ac_ext
6739 if test "$cf_cv_ncurses_h2" != no ; then
6740 cf_cv_ncurses_h2=$cf_incdir/$cf_header
6741 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
6744 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
6746 CPPFLAGS="$cf_save2_CPPFLAGS"
6747 test "$cf_cv_ncurses_h2" != no && break
6749 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:6749: error: not found" >&5
6750 echo "$as_me: error: not found" >&2;}
6751 { (exit 1); exit 1; }; }
6754 echo "$as_me:6754: result: $cf_cv_ncurses_h2" >&5
6755 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
6757 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
6758 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
6759 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
6760 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
6763 if test -n "$cf_1st_incdir" ; then
6764 for cf_add_incdir in $cf_1st_incdir
6766 while test $cf_add_incdir != /usr/include
6768 if test -d $cf_add_incdir
6771 if test -n "$CFLAGS$CPPFLAGS" ; then
6772 # a loop is needed to ensure we can add subdirs of existing dirs
6773 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
6774 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
6775 cf_have_incdir=yes; break
6780 if test "$cf_have_incdir" = no ; then
6781 if test "$cf_add_incdir" = /usr/local/include ; then
6782 if test "$GCC" = yes
6784 cf_save_CPPFLAGS=$CPPFLAGS
6785 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6786 cat >conftest.$ac_ext <<_ACEOF
6787 #line 6787 "configure"
6788 #include "confdefs.h"
6798 rm -f conftest.$ac_objext
6799 if { (eval echo "$as_me:6799: \"$ac_compile\"") >&5
6800 (eval $ac_compile) 2>&5
6802 echo "$as_me:6802: \$? = $ac_status" >&5
6803 (exit $ac_status); } &&
6804 { ac_try='test -s conftest.$ac_objext'
6805 { (eval echo "$as_me:6805: \"$ac_try\"") >&5
6808 echo "$as_me:6808: \$? = $ac_status" >&5
6809 (exit $ac_status); }; }; then
6812 echo "$as_me: failed program was:" >&5
6813 cat conftest.$ac_ext >&5
6816 rm -f conftest.$ac_objext conftest.$ac_ext
6817 CPPFLAGS=$cf_save_CPPFLAGS
6822 if test "$cf_have_incdir" = no ; then
6823 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
6825 echo "${as_me:-configure}:6825: testing adding $cf_add_incdir to include-path ..." 1>&5
6827 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6829 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
6830 test "$cf_top_incdir" = "$cf_add_incdir" && break
6831 cf_add_incdir="$cf_top_incdir"
6844 # Set definitions to allow ifdef'ing for ncurses.h
6846 case $cf_cv_ncurses_header in
6849 cat >>confdefs.h <<\EOF
6850 #define HAVE_NCURSES_H 1
6856 case $cf_cv_ncurses_header in
6857 (ncurses/curses.h|ncurses/ncurses.h)
6859 cat >>confdefs.h <<\EOF
6860 #define HAVE_NCURSES_NCURSES_H 1
6864 (ncursesw/curses.h|ncursesw/ncurses.h)
6866 cat >>confdefs.h <<\EOF
6867 #define HAVE_NCURSESW_NCURSES_H 1
6873 echo "$as_me:6873: checking for terminfo header" >&5
6874 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
6875 if test "${cf_cv_term_header+set}" = set; then
6876 echo $ECHO_N "(cached) $ECHO_C" >&6
6879 case ${cf_cv_ncurses_header} in
6880 (*/ncurses.h|*/ncursesw.h)
6881 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
6884 cf_term_header=term.h
6888 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
6890 cat >conftest.$ac_ext <<_ACEOF
6891 #line 6891 "configure"
6892 #include "confdefs.h"
6894 #include <${cf_cv_ncurses_header:-curses.h}>
6900 int x = auto_left_margin
6905 rm -f conftest.$ac_objext
6906 if { (eval echo "$as_me:6906: \"$ac_compile\"") >&5
6907 (eval $ac_compile) 2>&5
6909 echo "$as_me:6909: \$? = $ac_status" >&5
6910 (exit $ac_status); } &&
6911 { ac_try='test -s conftest.$ac_objext'
6912 { (eval echo "$as_me:6912: \"$ac_try\"") >&5
6915 echo "$as_me:6915: \$? = $ac_status" >&5
6916 (exit $ac_status); }; }; then
6918 cf_cv_term_header="$cf_test"
6920 echo "$as_me: failed program was:" >&5
6921 cat conftest.$ac_ext >&5
6923 cf_cv_term_header=unknown
6926 rm -f conftest.$ac_objext conftest.$ac_ext
6927 test "$cf_cv_term_header" != unknown && break
6931 echo "$as_me:6931: result: $cf_cv_term_header" >&5
6932 echo "${ECHO_T}$cf_cv_term_header" >&6
6934 # Set definitions to allow ifdef'ing to accommodate subdirectories
6936 case $cf_cv_term_header in
6939 cat >>confdefs.h <<\EOF
6940 #define HAVE_TERM_H 1
6946 case $cf_cv_term_header in
6949 cat >>confdefs.h <<\EOF
6950 #define HAVE_NCURSES_TERM_H 1
6956 cat >>confdefs.h <<\EOF
6957 #define HAVE_NCURSESW_TERM_H 1
6963 # some applications need this, but should check for NCURSES_VERSION
6965 cat >>confdefs.h <<\EOF
6969 echo "$as_me:6969: checking for ncurses version" >&5
6970 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
6971 if test "${cf_cv_ncurses_version+set}" = set; then
6972 echo $ECHO_N "(cached) $ECHO_C" >&6
6975 cf_cv_ncurses_version=no
6978 if test "$cross_compiling" = yes; then
6980 # This will not work if the preprocessor splits the line after the
6981 # Autoconf token. The 'unproto' program does that.
6982 cat > conftest.$ac_ext <<EOF
6983 #include <${cf_cv_ncurses_header:-curses.h}>
6985 #ifdef NCURSES_VERSION
6986 Autoconf NCURSES_VERSION
6994 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
6995 { (eval echo "$as_me:6995: \"$cf_try\"") >&5
6998 echo "$as_me:6998: \$? = $ac_status" >&5
6999 (exit $ac_status); }
7000 if test -f conftest.out ; then
7001 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
7002 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
7007 cat >conftest.$ac_ext <<_ACEOF
7008 #line 7008 "configure"
7009 #include "confdefs.h"
7011 #include <${cf_cv_ncurses_header:-curses.h}>
7015 FILE *fp = fopen("$cf_tempfile", "w");
7016 #ifdef NCURSES_VERSION
7017 # ifdef NCURSES_VERSION_PATCH
7018 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
7020 fprintf(fp, "%s\n", NCURSES_VERSION);
7024 fprintf(fp, "old\n");
7029 ${cf_cv_main_return:-return}(0);
7032 rm -f conftest$ac_exeext
7033 if { (eval echo "$as_me:7033: \"$ac_link\"") >&5
7034 (eval $ac_link) 2>&5
7036 echo "$as_me:7036: \$? = $ac_status" >&5
7037 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
7038 { (eval echo "$as_me:7038: \"$ac_try\"") >&5
7041 echo "$as_me:7041: \$? = $ac_status" >&5
7042 (exit $ac_status); }; }; then
7044 cf_cv_ncurses_version=`cat $cf_tempfile`
7046 echo "$as_me: program exited with status $ac_status" >&5
7047 echo "$as_me: failed program was:" >&5
7048 cat conftest.$ac_ext >&5
7050 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
7055 echo "$as_me:7055: result: $cf_cv_ncurses_version" >&5
7056 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
7057 test "$cf_cv_ncurses_version" = no ||
7058 cat >>confdefs.h <<\EOF
7062 cf_nculib_root=ncursesw
7063 # This works, except for the special case where we find gpm, but
7064 # ncurses is in a nonstandard location via $LIBS, and we really want
7067 cf_ncurses_SAVE="$LIBS"
7068 echo "$as_me:7068: checking for Gpm_Open in -lgpm" >&5
7069 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
7070 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
7071 echo $ECHO_N "(cached) $ECHO_C" >&6
7073 ac_check_lib_save_LIBS=$LIBS
7075 cat >conftest.$ac_ext <<_ACEOF
7076 #line 7076 "configure"
7077 #include "confdefs.h"
7079 /* Override any gcc2 internal prototype to avoid an error. */
7083 /* We use char because int might match the return type of a gcc2
7084 builtin and then its argument prototype would still apply. */
7094 rm -f conftest.$ac_objext conftest$ac_exeext
7095 if { (eval echo "$as_me:7095: \"$ac_link\"") >&5
7096 (eval $ac_link) 2>&5
7098 echo "$as_me:7098: \$? = $ac_status" >&5
7099 (exit $ac_status); } &&
7100 { ac_try='test -s conftest$ac_exeext'
7101 { (eval echo "$as_me:7101: \"$ac_try\"") >&5
7104 echo "$as_me:7104: \$? = $ac_status" >&5
7105 (exit $ac_status); }; }; then
7106 ac_cv_lib_gpm_Gpm_Open=yes
7108 echo "$as_me: failed program was:" >&5
7109 cat conftest.$ac_ext >&5
7110 ac_cv_lib_gpm_Gpm_Open=no
7112 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7113 LIBS=$ac_check_lib_save_LIBS
7115 echo "$as_me:7115: result: $ac_cv_lib_gpm_Gpm_Open" >&5
7116 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
7117 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
7118 echo "$as_me:7118: checking for initscr in -lgpm" >&5
7119 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
7120 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
7121 echo $ECHO_N "(cached) $ECHO_C" >&6
7123 ac_check_lib_save_LIBS=$LIBS
7125 cat >conftest.$ac_ext <<_ACEOF
7126 #line 7126 "configure"
7127 #include "confdefs.h"
7129 /* Override any gcc2 internal prototype to avoid an error. */
7133 /* We use char because int might match the return type of a gcc2
7134 builtin and then its argument prototype would still apply. */
7144 rm -f conftest.$ac_objext conftest$ac_exeext
7145 if { (eval echo "$as_me:7145: \"$ac_link\"") >&5
7146 (eval $ac_link) 2>&5
7148 echo "$as_me:7148: \$? = $ac_status" >&5
7149 (exit $ac_status); } &&
7150 { ac_try='test -s conftest$ac_exeext'
7151 { (eval echo "$as_me:7151: \"$ac_try\"") >&5
7154 echo "$as_me:7154: \$? = $ac_status" >&5
7155 (exit $ac_status); }; }; then
7156 ac_cv_lib_gpm_initscr=yes
7158 echo "$as_me: failed program was:" >&5
7159 cat conftest.$ac_ext >&5
7160 ac_cv_lib_gpm_initscr=no
7162 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7163 LIBS=$ac_check_lib_save_LIBS
7165 echo "$as_me:7165: result: $ac_cv_lib_gpm_initscr" >&5
7166 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
7167 if test $ac_cv_lib_gpm_initscr = yes; then
7168 LIBS="$cf_ncurses_SAVE"
7170 cf_ncurses_LIBS="-lgpm"
7177 # This is only necessary if you are linking against an obsolete
7178 # version of ncurses (but it should do no harm, since it's static).
7179 if test "$cf_nculib_root" = ncurses ; then
7180 echo "$as_me:7180: checking for tgoto in -lmytinfo" >&5
7181 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
7182 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
7183 echo $ECHO_N "(cached) $ECHO_C" >&6
7185 ac_check_lib_save_LIBS=$LIBS
7186 LIBS="-lmytinfo $LIBS"
7187 cat >conftest.$ac_ext <<_ACEOF
7188 #line 7188 "configure"
7189 #include "confdefs.h"
7191 /* Override any gcc2 internal prototype to avoid an error. */
7195 /* We use char because int might match the return type of a gcc2
7196 builtin and then its argument prototype would still apply. */
7206 rm -f conftest.$ac_objext conftest$ac_exeext
7207 if { (eval echo "$as_me:7207: \"$ac_link\"") >&5
7208 (eval $ac_link) 2>&5
7210 echo "$as_me:7210: \$? = $ac_status" >&5
7211 (exit $ac_status); } &&
7212 { ac_try='test -s conftest$ac_exeext'
7213 { (eval echo "$as_me:7213: \"$ac_try\"") >&5
7216 echo "$as_me:7216: \$? = $ac_status" >&5
7217 (exit $ac_status); }; }; then
7218 ac_cv_lib_mytinfo_tgoto=yes
7220 echo "$as_me: failed program was:" >&5
7221 cat conftest.$ac_ext >&5
7222 ac_cv_lib_mytinfo_tgoto=no
7224 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7225 LIBS=$ac_check_lib_save_LIBS
7227 echo "$as_me:7227: result: $ac_cv_lib_mytinfo_tgoto" >&5
7228 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
7229 if test $ac_cv_lib_mytinfo_tgoto = yes; then
7230 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
7237 cf_add_libs="$cf_ncurses_LIBS"
7238 # Filter out duplicates - this happens with badly-designed ".pc" files...
7239 for cf_add_1lib in $LIBS
7241 for cf_add_2lib in $cf_add_libs
7243 if test "x$cf_add_1lib" = "x$cf_add_2lib"
7249 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
7253 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
7256 cf_add_libs="-l$cf_nculib_root"
7257 # Filter out duplicates - this happens with badly-designed ".pc" files...
7258 for cf_add_1lib in $LIBS
7260 for cf_add_2lib in $cf_add_libs
7262 if test "x$cf_add_1lib" = "x$cf_add_2lib"
7268 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
7274 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
7276 echo "$as_me:7276: checking for initscr" >&5
7277 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
7278 if test "${ac_cv_func_initscr+set}" = set; then
7279 echo $ECHO_N "(cached) $ECHO_C" >&6
7281 cat >conftest.$ac_ext <<_ACEOF
7282 #line 7282 "configure"
7283 #include "confdefs.h"
7284 /* System header to define __stub macros and hopefully few prototypes,
7285 which can conflict with char initscr (); below. */
7287 /* Override any gcc2 internal prototype to avoid an error. */
7291 /* We use char because int might match the return type of a gcc2
7292 builtin and then its argument prototype would still apply. */
7299 /* The GNU C library defines this for functions which it implements
7300 to always fail with ENOSYS. Some functions are actually named
7301 something starting with __ and the normal name is an alias. */
7302 #if defined (__stub_initscr) || defined (__stub___initscr)
7305 f = initscr; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
7312 rm -f conftest.$ac_objext conftest$ac_exeext
7313 if { (eval echo "$as_me:7313: \"$ac_link\"") >&5
7314 (eval $ac_link) 2>&5
7316 echo "$as_me:7316: \$? = $ac_status" >&5
7317 (exit $ac_status); } &&
7318 { ac_try='test -s conftest$ac_exeext'
7319 { (eval echo "$as_me:7319: \"$ac_try\"") >&5
7322 echo "$as_me:7322: \$? = $ac_status" >&5
7323 (exit $ac_status); }; }; then
7324 ac_cv_func_initscr=yes
7326 echo "$as_me: failed program was:" >&5
7327 cat conftest.$ac_ext >&5
7328 ac_cv_func_initscr=no
7330 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7332 echo "$as_me:7332: result: $ac_cv_func_initscr" >&5
7333 echo "${ECHO_T}$ac_cv_func_initscr" >&6
7334 if test $ac_cv_func_initscr = yes; then
7335 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
7338 cf_save_LIBS="$LIBS"
7339 echo "$as_me:7339: checking for initscr in -l$cf_nculib_root" >&5
7340 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
7341 LIBS="-l$cf_nculib_root $LIBS"
7342 cat >conftest.$ac_ext <<_ACEOF
7343 #line 7343 "configure"
7344 #include "confdefs.h"
7345 #include <${cf_cv_ncurses_header:-curses.h}>
7354 rm -f conftest.$ac_objext conftest$ac_exeext
7355 if { (eval echo "$as_me:7355: \"$ac_link\"") >&5
7356 (eval $ac_link) 2>&5
7358 echo "$as_me:7358: \$? = $ac_status" >&5
7359 (exit $ac_status); } &&
7360 { ac_try='test -s conftest$ac_exeext'
7361 { (eval echo "$as_me:7361: \"$ac_try\"") >&5
7364 echo "$as_me:7364: \$? = $ac_status" >&5
7365 (exit $ac_status); }; }; then
7366 echo "$as_me:7366: result: yes" >&5
7367 echo "${ECHO_T}yes" >&6
7368 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
7371 echo "$as_me: failed program was:" >&5
7372 cat conftest.$ac_ext >&5
7373 echo "$as_me:7373: result: no" >&5
7374 echo "${ECHO_T}no" >&6
7377 cf_library_path_list=""
7378 if test -n "${LDFLAGS}${LIBS}" ; then
7379 for cf_library_path in $LDFLAGS $LIBS
7381 case $cf_library_path in
7383 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
7385 test "x$cf_library_path" != "xNONE" && \
7386 test -d "$cf_library_path" && \
7388 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
7389 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
7390 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
7391 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
7392 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
7393 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"
7396 cf_library_path_list="$cf_library_path_list $cf_search"
7404 test "x$prefix" != "xNONE" && \
7405 test -d "$prefix" && \
7407 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
7408 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
7409 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
7410 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
7411 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
7412 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
7415 for cf_subdir_prefix in \
7424 test "x$cf_subdir_prefix" != "x$prefix" && \
7425 test -d "$cf_subdir_prefix" && \
7426 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
7427 test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
7428 test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib"
7429 test -d $cf_subdir_prefix/lib/$cf_nculib_root && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root"
7430 test -d $cf_subdir_prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root/lib"
7431 test -d $cf_subdir_prefix/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib"
7432 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"
7437 cf_search="$cf_library_path_list $cf_search"
7439 for cf_libdir in $cf_search
7441 echo "$as_me:7441: checking for -l$cf_nculib_root in $cf_libdir" >&5
7442 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
7443 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
7444 cat >conftest.$ac_ext <<_ACEOF
7445 #line 7445 "configure"
7446 #include "confdefs.h"
7447 #include <${cf_cv_ncurses_header:-curses.h}>
7456 rm -f conftest.$ac_objext conftest$ac_exeext
7457 if { (eval echo "$as_me:7457: \"$ac_link\"") >&5
7458 (eval $ac_link) 2>&5
7460 echo "$as_me:7460: \$? = $ac_status" >&5
7461 (exit $ac_status); } &&
7462 { ac_try='test -s conftest$ac_exeext'
7463 { (eval echo "$as_me:7463: \"$ac_try\"") >&5
7466 echo "$as_me:7466: \$? = $ac_status" >&5
7467 (exit $ac_status); }; }; then
7468 echo "$as_me:7468: result: yes" >&5
7469 echo "${ECHO_T}yes" >&6
7470 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
7473 echo "$as_me: failed program was:" >&5
7474 cat conftest.$ac_ext >&5
7475 echo "$as_me:7475: result: no" >&5
7476 echo "${ECHO_T}no" >&6
7477 LIBS="$cf_save_LIBS"
7479 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7483 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7487 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
7489 if test $cf_found_library = no ; then
7490 { { echo "$as_me:7490: error: Cannot link $cf_nculib_root library" >&5
7491 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
7492 { (exit 1); exit 1; }; }
7497 if test -n "$cf_ncurses_LIBS" ; then
7498 echo "$as_me:7498: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
7499 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
7500 cf_ncurses_SAVE="$LIBS"
7501 for p in $cf_ncurses_LIBS ; do
7502 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
7503 if test "$q" != "$LIBS" ; then
7507 cat >conftest.$ac_ext <<_ACEOF
7508 #line 7508 "configure"
7509 #include "confdefs.h"
7510 #include <${cf_cv_ncurses_header:-curses.h}>
7514 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
7519 rm -f conftest.$ac_objext conftest$ac_exeext
7520 if { (eval echo "$as_me:7520: \"$ac_link\"") >&5
7521 (eval $ac_link) 2>&5
7523 echo "$as_me:7523: \$? = $ac_status" >&5
7524 (exit $ac_status); } &&
7525 { ac_try='test -s conftest$ac_exeext'
7526 { (eval echo "$as_me:7526: \"$ac_try\"") >&5
7529 echo "$as_me:7529: \$? = $ac_status" >&5
7530 (exit $ac_status); }; }; then
7531 echo "$as_me:7531: result: yes" >&5
7532 echo "${ECHO_T}yes" >&6
7534 echo "$as_me: failed program was:" >&5
7535 cat conftest.$ac_ext >&5
7536 echo "$as_me:7536: result: no" >&5
7537 echo "${ECHO_T}no" >&6
7538 LIBS="$cf_ncurses_SAVE"
7540 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7543 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
7545 cat >>confdefs.h <<EOF
7546 #define $cf_nculib_ROOT 1
7556 cf_ncuconfig_root=ncurses
7557 cf_have_ncuconfig=no
7559 if test "x${PKG_CONFIG:=none}" != xnone; then
7560 echo "$as_me:7560: checking pkg-config for $cf_ncuconfig_root" >&5
7561 echo $ECHO_N "checking pkg-config for $cf_ncuconfig_root... $ECHO_C" >&6
7562 if "$PKG_CONFIG" --exists $cf_ncuconfig_root ; then
7563 echo "$as_me:7563: result: yes" >&5
7564 echo "${ECHO_T}yes" >&6
7566 echo "$as_me:7566: checking if the $cf_ncuconfig_root package files work" >&5
7567 echo $ECHO_N "checking if the $cf_ncuconfig_root package files work... $ECHO_C" >&6
7568 cf_have_ncuconfig=unknown
7570 cf_save_CPPFLAGS="$CPPFLAGS"
7571 cf_save_LIBS="$LIBS"
7573 CPPFLAGS="$CPPFLAGS `$PKG_CONFIG --cflags $cf_ncuconfig_root`"
7575 cf_add_libs="`$PKG_CONFIG --libs $cf_ncuconfig_root`"
7576 # Filter out duplicates - this happens with badly-designed ".pc" files...
7577 for cf_add_1lib in $LIBS
7579 for cf_add_2lib in $cf_add_libs
7581 if test "x$cf_add_1lib" = "x$cf_add_2lib"
7587 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
7591 cat >conftest.$ac_ext <<_ACEOF
7592 #line 7592 "configure"
7593 #include "confdefs.h"
7594 #include <${cf_cv_ncurses_header:-curses.h}>
7598 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
7603 rm -f conftest.$ac_objext conftest$ac_exeext
7604 if { (eval echo "$as_me:7604: \"$ac_link\"") >&5
7605 (eval $ac_link) 2>&5
7607 echo "$as_me:7607: \$? = $ac_status" >&5
7608 (exit $ac_status); } &&
7609 { ac_try='test -s conftest$ac_exeext'
7610 { (eval echo "$as_me:7610: \"$ac_try\"") >&5
7613 echo "$as_me:7613: \$? = $ac_status" >&5
7614 (exit $ac_status); }; }; then
7615 if test "$cross_compiling" = yes; then
7616 cf_have_ncuconfig=maybe
7618 cat >conftest.$ac_ext <<_ACEOF
7619 #line 7619 "configure"
7620 #include "confdefs.h"
7621 #include <${cf_cv_ncurses_header:-curses.h}>
7623 { char *xx = curses_version(); return (xx == 0); }
7625 rm -f conftest$ac_exeext
7626 if { (eval echo "$as_me:7626: \"$ac_link\"") >&5
7627 (eval $ac_link) 2>&5
7629 echo "$as_me:7629: \$? = $ac_status" >&5
7630 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
7631 { (eval echo "$as_me:7631: \"$ac_try\"") >&5
7634 echo "$as_me:7634: \$? = $ac_status" >&5
7635 (exit $ac_status); }; }; then
7636 cf_have_ncuconfig=yes
7638 echo "$as_me: program exited with status $ac_status" >&5
7639 echo "$as_me: failed program was:" >&5
7640 cat conftest.$ac_ext >&5
7641 cf_have_ncuconfig=no
7643 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
7646 echo "$as_me: failed program was:" >&5
7647 cat conftest.$ac_ext >&5
7648 cf_have_ncuconfig=no
7650 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7651 echo "$as_me:7651: result: $cf_have_ncuconfig" >&5
7652 echo "${ECHO_T}$cf_have_ncuconfig" >&6
7653 test "$cf_have_ncuconfig" = maybe && cf_have_ncuconfig=yes
7654 if test "$cf_have_ncuconfig" != "yes"
7656 CPPFLAGS="$cf_save_CPPFLAGS"
7657 LIBS="$cf_save_LIBS"
7658 NCURSES_CONFIG_PKG=none
7661 cat >>confdefs.h <<\EOF
7665 NCURSES_CONFIG_PKG=$cf_ncuconfig_root
7668 echo "$as_me:7668: checking for terminfo header" >&5
7669 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
7670 if test "${cf_cv_term_header+set}" = set; then
7671 echo $ECHO_N "(cached) $ECHO_C" >&6
7674 case ${cf_cv_ncurses_header} in
7675 (*/ncurses.h|*/ncursesw.h)
7676 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
7679 cf_term_header=term.h
7683 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
7685 cat >conftest.$ac_ext <<_ACEOF
7686 #line 7686 "configure"
7687 #include "confdefs.h"
7689 #include <${cf_cv_ncurses_header:-curses.h}>
7695 int x = auto_left_margin
7700 rm -f conftest.$ac_objext
7701 if { (eval echo "$as_me:7701: \"$ac_compile\"") >&5
7702 (eval $ac_compile) 2>&5
7704 echo "$as_me:7704: \$? = $ac_status" >&5
7705 (exit $ac_status); } &&
7706 { ac_try='test -s conftest.$ac_objext'
7707 { (eval echo "$as_me:7707: \"$ac_try\"") >&5
7710 echo "$as_me:7710: \$? = $ac_status" >&5
7711 (exit $ac_status); }; }; then
7713 cf_cv_term_header="$cf_test"
7715 echo "$as_me: failed program was:" >&5
7716 cat conftest.$ac_ext >&5
7718 cf_cv_term_header=unknown
7721 rm -f conftest.$ac_objext conftest.$ac_ext
7722 test "$cf_cv_term_header" != unknown && break
7726 echo "$as_me:7726: result: $cf_cv_term_header" >&5
7727 echo "${ECHO_T}$cf_cv_term_header" >&6
7729 # Set definitions to allow ifdef'ing to accommodate subdirectories
7731 case $cf_cv_term_header in
7734 cat >>confdefs.h <<\EOF
7735 #define HAVE_TERM_H 1
7741 case $cf_cv_term_header in
7744 cat >>confdefs.h <<\EOF
7745 #define HAVE_NCURSES_TERM_H 1
7751 cat >>confdefs.h <<\EOF
7752 #define HAVE_NCURSESW_TERM_H 1
7759 echo "$as_me:7759: result: no" >&5
7760 echo "${ECHO_T}no" >&6
7761 NCURSES_CONFIG_PKG=none
7764 NCURSES_CONFIG_PKG=none
7767 if test "x$cf_have_ncuconfig" = "xno"; then
7768 echo "Looking for ${cf_ncuconfig_root}-config"
7770 if test -n "$ac_tool_prefix"; then
7771 for ac_prog in ${cf_ncuconfig_root}-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
7773 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
7774 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
7775 echo "$as_me:7775: checking for $ac_word" >&5
7776 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7777 if test "${ac_cv_prog_NCURSES_CONFIG+set}" = set; then
7778 echo $ECHO_N "(cached) $ECHO_C" >&6
7780 if test -n "$NCURSES_CONFIG"; then
7781 ac_cv_prog_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test.
7783 ac_save_IFS=$IFS; IFS=$ac_path_separator
7785 for ac_dir in $ac_dummy; do
7787 test -z "$ac_dir" && ac_dir=.
7788 $as_executable_p "$ac_dir/$ac_word" || continue
7789 ac_cv_prog_NCURSES_CONFIG="$ac_tool_prefix$ac_prog"
7790 echo "$as_me:7790: found $ac_dir/$ac_word" >&5
7796 NCURSES_CONFIG=$ac_cv_prog_NCURSES_CONFIG
7797 if test -n "$NCURSES_CONFIG"; then
7798 echo "$as_me:7798: result: $NCURSES_CONFIG" >&5
7799 echo "${ECHO_T}$NCURSES_CONFIG" >&6
7801 echo "$as_me:7801: result: no" >&5
7802 echo "${ECHO_T}no" >&6
7805 test -n "$NCURSES_CONFIG" && break
7808 if test -z "$NCURSES_CONFIG"; then
7809 ac_ct_NCURSES_CONFIG=$NCURSES_CONFIG
7810 for ac_prog in ${cf_ncuconfig_root}-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
7812 # Extract the first word of "$ac_prog", so it can be a program name with args.
7813 set dummy $ac_prog; ac_word=$2
7814 echo "$as_me:7814: checking for $ac_word" >&5
7815 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7816 if test "${ac_cv_prog_ac_ct_NCURSES_CONFIG+set}" = set; then
7817 echo $ECHO_N "(cached) $ECHO_C" >&6
7819 if test -n "$ac_ct_NCURSES_CONFIG"; then
7820 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_ct_NCURSES_CONFIG" # Let the user override the test.
7822 ac_save_IFS=$IFS; IFS=$ac_path_separator
7824 for ac_dir in $ac_dummy; do
7826 test -z "$ac_dir" && ac_dir=.
7827 $as_executable_p "$ac_dir/$ac_word" || continue
7828 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_prog"
7829 echo "$as_me:7829: found $ac_dir/$ac_word" >&5
7835 ac_ct_NCURSES_CONFIG=$ac_cv_prog_ac_ct_NCURSES_CONFIG
7836 if test -n "$ac_ct_NCURSES_CONFIG"; then
7837 echo "$as_me:7837: result: $ac_ct_NCURSES_CONFIG" >&5
7838 echo "${ECHO_T}$ac_ct_NCURSES_CONFIG" >&6
7840 echo "$as_me:7840: result: no" >&5
7841 echo "${ECHO_T}no" >&6
7844 test -n "$ac_ct_NCURSES_CONFIG" && break
7846 test -n "$ac_ct_NCURSES_CONFIG" || ac_ct_NCURSES_CONFIG="none"
7848 NCURSES_CONFIG=$ac_ct_NCURSES_CONFIG
7851 if test "$NCURSES_CONFIG" != none ; then
7853 CPPFLAGS="$CPPFLAGS `$NCURSES_CONFIG --cflags`"
7855 cf_add_libs="`$NCURSES_CONFIG --libs`"
7856 # Filter out duplicates - this happens with badly-designed ".pc" files...
7857 for cf_add_1lib in $LIBS
7859 for cf_add_2lib in $cf_add_libs
7861 if test "x$cf_add_1lib" = "x$cf_add_2lib"
7867 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
7871 # even with config script, some packages use no-override for curses.h
7873 echo "$as_me:7873: checking if we have identified curses headers" >&5
7874 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
7875 if test "${cf_cv_ncurses_header+set}" = set; then
7876 echo $ECHO_N "(cached) $ECHO_C" >&6
7879 cf_cv_ncurses_header=none
7881 ncurses.h ncurses/ncurses.h \
7882 curses.h ncurses/curses.h
7884 cat >conftest.$ac_ext <<_ACEOF
7885 #line 7885 "configure"
7886 #include "confdefs.h"
7887 #include <${cf_header}>
7891 initscr(); tgoto("?", 0,0)
7896 rm -f conftest.$ac_objext
7897 if { (eval echo "$as_me:7897: \"$ac_compile\"") >&5
7898 (eval $ac_compile) 2>&5
7900 echo "$as_me:7900: \$? = $ac_status" >&5
7901 (exit $ac_status); } &&
7902 { ac_try='test -s conftest.$ac_objext'
7903 { (eval echo "$as_me:7903: \"$ac_try\"") >&5
7906 echo "$as_me:7906: \$? = $ac_status" >&5
7907 (exit $ac_status); }; }; then
7908 cf_cv_ncurses_header=$cf_header; break
7910 echo "$as_me: failed program was:" >&5
7911 cat conftest.$ac_ext >&5
7913 rm -f conftest.$ac_objext conftest.$ac_ext
7917 echo "$as_me:7917: result: $cf_cv_ncurses_header" >&5
7918 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
7920 if test "$cf_cv_ncurses_header" = none ; then
7921 { { echo "$as_me:7921: error: No curses header-files found" >&5
7922 echo "$as_me: error: No curses header-files found" >&2;}
7923 { (exit 1); exit 1; }; }
7926 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
7928 for ac_header in $cf_cv_ncurses_header
7930 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7931 echo "$as_me:7931: checking for $ac_header" >&5
7932 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7933 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7934 echo $ECHO_N "(cached) $ECHO_C" >&6
7936 cat >conftest.$ac_ext <<_ACEOF
7937 #line 7937 "configure"
7938 #include "confdefs.h"
7939 #include <$ac_header>
7941 if { (eval echo "$as_me:7941: \"$ac_cpp conftest.$ac_ext\"") >&5
7942 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7944 egrep -v '^ *\+' conftest.er1 >conftest.err
7946 cat conftest.err >&5
7947 echo "$as_me:7947: \$? = $ac_status" >&5
7948 (exit $ac_status); } >/dev/null; then
7949 if test -s conftest.err; then
7950 ac_cpp_err=$ac_c_preproc_warn_flag
7957 if test -z "$ac_cpp_err"; then
7958 eval "$as_ac_Header=yes"
7960 echo "$as_me: failed program was:" >&5
7961 cat conftest.$ac_ext >&5
7962 eval "$as_ac_Header=no"
7964 rm -f conftest.err conftest.$ac_ext
7966 echo "$as_me:7966: result: `eval echo '${'$as_ac_Header'}'`" >&5
7967 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7968 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7969 cat >>confdefs.h <<EOF
7970 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7976 cat >>confdefs.h <<\EOF
7980 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
7982 cat >>confdefs.h <<EOF
7983 #define $cf_nculib_ROOT 1
7986 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
7990 cf_ncuhdr_root=ncurses
7992 test -n "$cf_cv_curses_dir" && \
7993 test "$cf_cv_curses_dir" != "no" && { \
7995 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
7996 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
7998 while test $cf_add_incdir != /usr/include
8000 if test -d $cf_add_incdir
8003 if test -n "$CFLAGS$CPPFLAGS" ; then
8004 # a loop is needed to ensure we can add subdirs of existing dirs
8005 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
8006 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
8007 cf_have_incdir=yes; break
8012 if test "$cf_have_incdir" = no ; then
8013 if test "$cf_add_incdir" = /usr/local/include ; then
8014 if test "$GCC" = yes
8016 cf_save_CPPFLAGS=$CPPFLAGS
8017 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8018 cat >conftest.$ac_ext <<_ACEOF
8019 #line 8019 "configure"
8020 #include "confdefs.h"
8030 rm -f conftest.$ac_objext
8031 if { (eval echo "$as_me:8031: \"$ac_compile\"") >&5
8032 (eval $ac_compile) 2>&5
8034 echo "$as_me:8034: \$? = $ac_status" >&5
8035 (exit $ac_status); } &&
8036 { ac_try='test -s conftest.$ac_objext'
8037 { (eval echo "$as_me:8037: \"$ac_try\"") >&5
8040 echo "$as_me:8040: \$? = $ac_status" >&5
8041 (exit $ac_status); }; }; then
8044 echo "$as_me: failed program was:" >&5
8045 cat conftest.$ac_ext >&5
8048 rm -f conftest.$ac_objext conftest.$ac_ext
8049 CPPFLAGS=$cf_save_CPPFLAGS
8054 if test "$cf_have_incdir" = no ; then
8055 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
8057 echo "${as_me:-configure}:8057: testing adding $cf_add_incdir to include-path ..." 1>&5
8059 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8061 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
8062 test "$cf_top_incdir" = "$cf_add_incdir" && break
8063 cf_add_incdir="$cf_top_incdir"
8076 echo "$as_me:8076: checking for $cf_ncuhdr_root header in include-path" >&5
8077 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
8078 if test "${cf_cv_ncurses_h+set}" = set; then
8079 echo $ECHO_N "(cached) $ECHO_C" >&6
8082 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
8083 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
8084 for cf_header in $cf_header_list
8087 cat >conftest.$ac_ext <<_ACEOF
8088 #line 8088 "configure"
8089 #include "confdefs.h"
8091 #include <$cf_header>
8096 #ifdef NCURSES_VERSION
8098 printf("%s\n", NCURSES_VERSION);
8111 rm -f conftest.$ac_objext
8112 if { (eval echo "$as_me:8112: \"$ac_compile\"") >&5
8113 (eval $ac_compile) 2>&5
8115 echo "$as_me:8115: \$? = $ac_status" >&5
8116 (exit $ac_status); } &&
8117 { ac_try='test -s conftest.$ac_objext'
8118 { (eval echo "$as_me:8118: \"$ac_try\"") >&5
8121 echo "$as_me:8121: \$? = $ac_status" >&5
8122 (exit $ac_status); }; }; then
8123 cf_cv_ncurses_h=$cf_header
8126 echo "$as_me: failed program was:" >&5
8127 cat conftest.$ac_ext >&5
8130 rm -f conftest.$ac_objext conftest.$ac_ext
8132 test "$cf_cv_ncurses_h" != no && break
8136 echo "$as_me:8136: result: $cf_cv_ncurses_h" >&5
8137 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
8139 if test "$cf_cv_ncurses_h" != no ; then
8140 cf_cv_ncurses_header=$cf_cv_ncurses_h
8143 echo "$as_me:8143: checking for $cf_ncuhdr_root include-path" >&5
8144 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
8145 if test "${cf_cv_ncurses_h2+set}" = set; then
8146 echo $ECHO_N "(cached) $ECHO_C" >&6
8149 test -n "$verbose" && echo
8153 # collect the current set of include-directories from compiler flags
8154 cf_header_path_list=""
8155 if test -n "${CFLAGS}${CPPFLAGS}" ; then
8156 for cf_header_path in $CPPFLAGS $CFLAGS
8158 case $cf_header_path in
8160 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
8162 test "x$cf_header_path" != "xNONE" && \
8163 test -d "$cf_header_path" && \
8165 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
8166 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
8167 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
8168 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
8169 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
8170 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"
8173 cf_header_path_list="$cf_header_path_list $cf_search"
8179 # add the variations for the package we are looking for
8183 test "x$prefix" != "xNONE" && \
8184 test -d "$prefix" && \
8186 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
8187 test -d $prefix/include && cf_search="$cf_search $prefix/include"
8188 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
8189 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
8190 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
8191 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
8194 for cf_subdir_prefix in \
8203 test "x$cf_subdir_prefix" != "x$prefix" && \
8204 test -d "$cf_subdir_prefix" && \
8205 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
8206 test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
8207 test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include"
8208 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root"
8209 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root/include"
8210 test -d $cf_subdir_prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include"
8211 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"
8216 test "$includedir" != NONE && \
8217 test "$includedir" != "/usr/include" && \
8218 test -d "$includedir" && {
8219 test -d $includedir && cf_search="$cf_search $includedir"
8220 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
8223 test "$oldincludedir" != NONE && \
8224 test "$oldincludedir" != "/usr/include" && \
8225 test -d "$oldincludedir" && {
8226 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
8227 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
8230 cf_search="$cf_search $cf_header_path_list"
8232 test -n "$verbose" && echo search path $cf_search
8233 cf_save2_CPPFLAGS="$CPPFLAGS"
8234 for cf_incdir in $cf_search
8237 if test -n "$cf_incdir" ; then
8238 for cf_add_incdir in $cf_incdir
8240 while test $cf_add_incdir != /usr/include
8242 if test -d $cf_add_incdir
8245 if test -n "$CFLAGS$CPPFLAGS" ; then
8246 # a loop is needed to ensure we can add subdirs of existing dirs
8247 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
8248 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
8249 cf_have_incdir=yes; break
8254 if test "$cf_have_incdir" = no ; then
8255 if test "$cf_add_incdir" = /usr/local/include ; then
8256 if test "$GCC" = yes
8258 cf_save_CPPFLAGS=$CPPFLAGS
8259 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8260 cat >conftest.$ac_ext <<_ACEOF
8261 #line 8261 "configure"
8262 #include "confdefs.h"
8272 rm -f conftest.$ac_objext
8273 if { (eval echo "$as_me:8273: \"$ac_compile\"") >&5
8274 (eval $ac_compile) 2>&5
8276 echo "$as_me:8276: \$? = $ac_status" >&5
8277 (exit $ac_status); } &&
8278 { ac_try='test -s conftest.$ac_objext'
8279 { (eval echo "$as_me:8279: \"$ac_try\"") >&5
8282 echo "$as_me:8282: \$? = $ac_status" >&5
8283 (exit $ac_status); }; }; then
8286 echo "$as_me: failed program was:" >&5
8287 cat conftest.$ac_ext >&5
8290 rm -f conftest.$ac_objext conftest.$ac_ext
8291 CPPFLAGS=$cf_save_CPPFLAGS
8296 if test "$cf_have_incdir" = no ; then
8297 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
8299 echo "${as_me:-configure}:8299: testing adding $cf_add_incdir to include-path ..." 1>&5
8301 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8303 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
8304 test "$cf_top_incdir" = "$cf_add_incdir" && break
8305 cf_add_incdir="$cf_top_incdir"
8321 cat >conftest.$ac_ext <<_ACEOF
8322 #line 8322 "configure"
8323 #include "confdefs.h"
8325 #include <$cf_header>
8330 #ifdef NCURSES_VERSION
8332 printf("%s\n", NCURSES_VERSION);
8345 rm -f conftest.$ac_objext
8346 if { (eval echo "$as_me:8346: \"$ac_compile\"") >&5
8347 (eval $ac_compile) 2>&5
8349 echo "$as_me:8349: \$? = $ac_status" >&5
8350 (exit $ac_status); } &&
8351 { ac_try='test -s conftest.$ac_objext'
8352 { (eval echo "$as_me:8352: \"$ac_try\"") >&5
8355 echo "$as_me:8355: \$? = $ac_status" >&5
8356 (exit $ac_status); }; }; then
8357 cf_cv_ncurses_h2=$cf_header
8360 echo "$as_me: failed program was:" >&5
8361 cat conftest.$ac_ext >&5
8364 rm -f conftest.$ac_objext conftest.$ac_ext
8366 if test "$cf_cv_ncurses_h2" != no ; then
8367 cf_cv_ncurses_h2=$cf_incdir/$cf_header
8368 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
8371 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
8373 CPPFLAGS="$cf_save2_CPPFLAGS"
8374 test "$cf_cv_ncurses_h2" != no && break
8376 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:8376: error: not found" >&5
8377 echo "$as_me: error: not found" >&2;}
8378 { (exit 1); exit 1; }; }
8381 echo "$as_me:8381: result: $cf_cv_ncurses_h2" >&5
8382 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
8384 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
8385 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
8386 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
8387 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
8390 if test -n "$cf_1st_incdir" ; then
8391 for cf_add_incdir in $cf_1st_incdir
8393 while test $cf_add_incdir != /usr/include
8395 if test -d $cf_add_incdir
8398 if test -n "$CFLAGS$CPPFLAGS" ; then
8399 # a loop is needed to ensure we can add subdirs of existing dirs
8400 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
8401 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
8402 cf_have_incdir=yes; break
8407 if test "$cf_have_incdir" = no ; then
8408 if test "$cf_add_incdir" = /usr/local/include ; then
8409 if test "$GCC" = yes
8411 cf_save_CPPFLAGS=$CPPFLAGS
8412 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8413 cat >conftest.$ac_ext <<_ACEOF
8414 #line 8414 "configure"
8415 #include "confdefs.h"
8425 rm -f conftest.$ac_objext
8426 if { (eval echo "$as_me:8426: \"$ac_compile\"") >&5
8427 (eval $ac_compile) 2>&5
8429 echo "$as_me:8429: \$? = $ac_status" >&5
8430 (exit $ac_status); } &&
8431 { ac_try='test -s conftest.$ac_objext'
8432 { (eval echo "$as_me:8432: \"$ac_try\"") >&5
8435 echo "$as_me:8435: \$? = $ac_status" >&5
8436 (exit $ac_status); }; }; then
8439 echo "$as_me: failed program was:" >&5
8440 cat conftest.$ac_ext >&5
8443 rm -f conftest.$ac_objext conftest.$ac_ext
8444 CPPFLAGS=$cf_save_CPPFLAGS
8449 if test "$cf_have_incdir" = no ; then
8450 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
8452 echo "${as_me:-configure}:8452: testing adding $cf_add_incdir to include-path ..." 1>&5
8454 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8456 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
8457 test "$cf_top_incdir" = "$cf_add_incdir" && break
8458 cf_add_incdir="$cf_top_incdir"
8471 # Set definitions to allow ifdef'ing for ncurses.h
8473 case $cf_cv_ncurses_header in
8476 cat >>confdefs.h <<\EOF
8477 #define HAVE_NCURSES_H 1
8483 case $cf_cv_ncurses_header in
8484 (ncurses/curses.h|ncurses/ncurses.h)
8486 cat >>confdefs.h <<\EOF
8487 #define HAVE_NCURSES_NCURSES_H 1
8491 (ncursesw/curses.h|ncursesw/ncurses.h)
8493 cat >>confdefs.h <<\EOF
8494 #define HAVE_NCURSESW_NCURSES_H 1
8500 echo "$as_me:8500: checking for terminfo header" >&5
8501 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
8502 if test "${cf_cv_term_header+set}" = set; then
8503 echo $ECHO_N "(cached) $ECHO_C" >&6
8506 case ${cf_cv_ncurses_header} in
8507 (*/ncurses.h|*/ncursesw.h)
8508 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
8511 cf_term_header=term.h
8515 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
8517 cat >conftest.$ac_ext <<_ACEOF
8518 #line 8518 "configure"
8519 #include "confdefs.h"
8521 #include <${cf_cv_ncurses_header:-curses.h}>
8527 int x = auto_left_margin
8532 rm -f conftest.$ac_objext
8533 if { (eval echo "$as_me:8533: \"$ac_compile\"") >&5
8534 (eval $ac_compile) 2>&5
8536 echo "$as_me:8536: \$? = $ac_status" >&5
8537 (exit $ac_status); } &&
8538 { ac_try='test -s conftest.$ac_objext'
8539 { (eval echo "$as_me:8539: \"$ac_try\"") >&5
8542 echo "$as_me:8542: \$? = $ac_status" >&5
8543 (exit $ac_status); }; }; then
8545 cf_cv_term_header="$cf_test"
8547 echo "$as_me: failed program was:" >&5
8548 cat conftest.$ac_ext >&5
8550 cf_cv_term_header=unknown
8553 rm -f conftest.$ac_objext conftest.$ac_ext
8554 test "$cf_cv_term_header" != unknown && break
8558 echo "$as_me:8558: result: $cf_cv_term_header" >&5
8559 echo "${ECHO_T}$cf_cv_term_header" >&6
8561 # Set definitions to allow ifdef'ing to accommodate subdirectories
8563 case $cf_cv_term_header in
8566 cat >>confdefs.h <<\EOF
8567 #define HAVE_TERM_H 1
8573 case $cf_cv_term_header in
8576 cat >>confdefs.h <<\EOF
8577 #define HAVE_NCURSES_TERM_H 1
8583 cat >>confdefs.h <<\EOF
8584 #define HAVE_NCURSESW_TERM_H 1
8590 # some applications need this, but should check for NCURSES_VERSION
8592 cat >>confdefs.h <<\EOF
8596 echo "$as_me:8596: checking for ncurses version" >&5
8597 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
8598 if test "${cf_cv_ncurses_version+set}" = set; then
8599 echo $ECHO_N "(cached) $ECHO_C" >&6
8602 cf_cv_ncurses_version=no
8605 if test "$cross_compiling" = yes; then
8607 # This will not work if the preprocessor splits the line after the
8608 # Autoconf token. The 'unproto' program does that.
8609 cat > conftest.$ac_ext <<EOF
8610 #include <${cf_cv_ncurses_header:-curses.h}>
8612 #ifdef NCURSES_VERSION
8613 Autoconf NCURSES_VERSION
8621 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
8622 { (eval echo "$as_me:8622: \"$cf_try\"") >&5
8625 echo "$as_me:8625: \$? = $ac_status" >&5
8626 (exit $ac_status); }
8627 if test -f conftest.out ; then
8628 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
8629 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
8634 cat >conftest.$ac_ext <<_ACEOF
8635 #line 8635 "configure"
8636 #include "confdefs.h"
8638 #include <${cf_cv_ncurses_header:-curses.h}>
8642 FILE *fp = fopen("$cf_tempfile", "w");
8643 #ifdef NCURSES_VERSION
8644 # ifdef NCURSES_VERSION_PATCH
8645 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
8647 fprintf(fp, "%s\n", NCURSES_VERSION);
8651 fprintf(fp, "old\n");
8656 ${cf_cv_main_return:-return}(0);
8659 rm -f conftest$ac_exeext
8660 if { (eval echo "$as_me:8660: \"$ac_link\"") >&5
8661 (eval $ac_link) 2>&5
8663 echo "$as_me:8663: \$? = $ac_status" >&5
8664 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
8665 { (eval echo "$as_me:8665: \"$ac_try\"") >&5
8668 echo "$as_me:8668: \$? = $ac_status" >&5
8669 (exit $ac_status); }; }; then
8671 cf_cv_ncurses_version=`cat $cf_tempfile`
8673 echo "$as_me: program exited with status $ac_status" >&5
8674 echo "$as_me: failed program was:" >&5
8675 cat conftest.$ac_ext >&5
8677 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
8682 echo "$as_me:8682: result: $cf_cv_ncurses_version" >&5
8683 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
8684 test "$cf_cv_ncurses_version" = no ||
8685 cat >>confdefs.h <<\EOF
8689 cf_nculib_root=ncurses
8690 # This works, except for the special case where we find gpm, but
8691 # ncurses is in a nonstandard location via $LIBS, and we really want
8694 cf_ncurses_SAVE="$LIBS"
8695 echo "$as_me:8695: checking for Gpm_Open in -lgpm" >&5
8696 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
8697 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
8698 echo $ECHO_N "(cached) $ECHO_C" >&6
8700 ac_check_lib_save_LIBS=$LIBS
8702 cat >conftest.$ac_ext <<_ACEOF
8703 #line 8703 "configure"
8704 #include "confdefs.h"
8706 /* Override any gcc2 internal prototype to avoid an error. */
8710 /* We use char because int might match the return type of a gcc2
8711 builtin and then its argument prototype would still apply. */
8721 rm -f conftest.$ac_objext conftest$ac_exeext
8722 if { (eval echo "$as_me:8722: \"$ac_link\"") >&5
8723 (eval $ac_link) 2>&5
8725 echo "$as_me:8725: \$? = $ac_status" >&5
8726 (exit $ac_status); } &&
8727 { ac_try='test -s conftest$ac_exeext'
8728 { (eval echo "$as_me:8728: \"$ac_try\"") >&5
8731 echo "$as_me:8731: \$? = $ac_status" >&5
8732 (exit $ac_status); }; }; then
8733 ac_cv_lib_gpm_Gpm_Open=yes
8735 echo "$as_me: failed program was:" >&5
8736 cat conftest.$ac_ext >&5
8737 ac_cv_lib_gpm_Gpm_Open=no
8739 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8740 LIBS=$ac_check_lib_save_LIBS
8742 echo "$as_me:8742: result: $ac_cv_lib_gpm_Gpm_Open" >&5
8743 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
8744 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
8745 echo "$as_me:8745: checking for initscr in -lgpm" >&5
8746 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
8747 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
8748 echo $ECHO_N "(cached) $ECHO_C" >&6
8750 ac_check_lib_save_LIBS=$LIBS
8752 cat >conftest.$ac_ext <<_ACEOF
8753 #line 8753 "configure"
8754 #include "confdefs.h"
8756 /* Override any gcc2 internal prototype to avoid an error. */
8760 /* We use char because int might match the return type of a gcc2
8761 builtin and then its argument prototype would still apply. */
8771 rm -f conftest.$ac_objext conftest$ac_exeext
8772 if { (eval echo "$as_me:8772: \"$ac_link\"") >&5
8773 (eval $ac_link) 2>&5
8775 echo "$as_me:8775: \$? = $ac_status" >&5
8776 (exit $ac_status); } &&
8777 { ac_try='test -s conftest$ac_exeext'
8778 { (eval echo "$as_me:8778: \"$ac_try\"") >&5
8781 echo "$as_me:8781: \$? = $ac_status" >&5
8782 (exit $ac_status); }; }; then
8783 ac_cv_lib_gpm_initscr=yes
8785 echo "$as_me: failed program was:" >&5
8786 cat conftest.$ac_ext >&5
8787 ac_cv_lib_gpm_initscr=no
8789 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8790 LIBS=$ac_check_lib_save_LIBS
8792 echo "$as_me:8792: result: $ac_cv_lib_gpm_initscr" >&5
8793 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
8794 if test $ac_cv_lib_gpm_initscr = yes; then
8795 LIBS="$cf_ncurses_SAVE"
8797 cf_ncurses_LIBS="-lgpm"
8804 # This is only necessary if you are linking against an obsolete
8805 # version of ncurses (but it should do no harm, since it's static).
8806 if test "$cf_nculib_root" = ncurses ; then
8807 echo "$as_me:8807: checking for tgoto in -lmytinfo" >&5
8808 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
8809 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
8810 echo $ECHO_N "(cached) $ECHO_C" >&6
8812 ac_check_lib_save_LIBS=$LIBS
8813 LIBS="-lmytinfo $LIBS"
8814 cat >conftest.$ac_ext <<_ACEOF
8815 #line 8815 "configure"
8816 #include "confdefs.h"
8818 /* Override any gcc2 internal prototype to avoid an error. */
8822 /* We use char because int might match the return type of a gcc2
8823 builtin and then its argument prototype would still apply. */
8833 rm -f conftest.$ac_objext conftest$ac_exeext
8834 if { (eval echo "$as_me:8834: \"$ac_link\"") >&5
8835 (eval $ac_link) 2>&5
8837 echo "$as_me:8837: \$? = $ac_status" >&5
8838 (exit $ac_status); } &&
8839 { ac_try='test -s conftest$ac_exeext'
8840 { (eval echo "$as_me:8840: \"$ac_try\"") >&5
8843 echo "$as_me:8843: \$? = $ac_status" >&5
8844 (exit $ac_status); }; }; then
8845 ac_cv_lib_mytinfo_tgoto=yes
8847 echo "$as_me: failed program was:" >&5
8848 cat conftest.$ac_ext >&5
8849 ac_cv_lib_mytinfo_tgoto=no
8851 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8852 LIBS=$ac_check_lib_save_LIBS
8854 echo "$as_me:8854: result: $ac_cv_lib_mytinfo_tgoto" >&5
8855 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
8856 if test $ac_cv_lib_mytinfo_tgoto = yes; then
8857 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
8864 cf_add_libs="$cf_ncurses_LIBS"
8865 # Filter out duplicates - this happens with badly-designed ".pc" files...
8866 for cf_add_1lib in $LIBS
8868 for cf_add_2lib in $cf_add_libs
8870 if test "x$cf_add_1lib" = "x$cf_add_2lib"
8876 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
8880 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
8883 cf_add_libs="-l$cf_nculib_root"
8884 # Filter out duplicates - this happens with badly-designed ".pc" files...
8885 for cf_add_1lib in $LIBS
8887 for cf_add_2lib in $cf_add_libs
8889 if test "x$cf_add_1lib" = "x$cf_add_2lib"
8895 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
8901 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
8903 echo "$as_me:8903: checking for initscr" >&5
8904 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
8905 if test "${ac_cv_func_initscr+set}" = set; then
8906 echo $ECHO_N "(cached) $ECHO_C" >&6
8908 cat >conftest.$ac_ext <<_ACEOF
8909 #line 8909 "configure"
8910 #include "confdefs.h"
8911 /* System header to define __stub macros and hopefully few prototypes,
8912 which can conflict with char initscr (); below. */
8914 /* Override any gcc2 internal prototype to avoid an error. */
8918 /* We use char because int might match the return type of a gcc2
8919 builtin and then its argument prototype would still apply. */
8926 /* The GNU C library defines this for functions which it implements
8927 to always fail with ENOSYS. Some functions are actually named
8928 something starting with __ and the normal name is an alias. */
8929 #if defined (__stub_initscr) || defined (__stub___initscr)
8932 f = initscr; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
8939 rm -f conftest.$ac_objext conftest$ac_exeext
8940 if { (eval echo "$as_me:8940: \"$ac_link\"") >&5
8941 (eval $ac_link) 2>&5
8943 echo "$as_me:8943: \$? = $ac_status" >&5
8944 (exit $ac_status); } &&
8945 { ac_try='test -s conftest$ac_exeext'
8946 { (eval echo "$as_me:8946: \"$ac_try\"") >&5
8949 echo "$as_me:8949: \$? = $ac_status" >&5
8950 (exit $ac_status); }; }; then
8951 ac_cv_func_initscr=yes
8953 echo "$as_me: failed program was:" >&5
8954 cat conftest.$ac_ext >&5
8955 ac_cv_func_initscr=no
8957 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8959 echo "$as_me:8959: result: $ac_cv_func_initscr" >&5
8960 echo "${ECHO_T}$ac_cv_func_initscr" >&6
8961 if test $ac_cv_func_initscr = yes; then
8962 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
8965 cf_save_LIBS="$LIBS"
8966 echo "$as_me:8966: checking for initscr in -l$cf_nculib_root" >&5
8967 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
8968 LIBS="-l$cf_nculib_root $LIBS"
8969 cat >conftest.$ac_ext <<_ACEOF
8970 #line 8970 "configure"
8971 #include "confdefs.h"
8972 #include <${cf_cv_ncurses_header:-curses.h}>
8981 rm -f conftest.$ac_objext conftest$ac_exeext
8982 if { (eval echo "$as_me:8982: \"$ac_link\"") >&5
8983 (eval $ac_link) 2>&5
8985 echo "$as_me:8985: \$? = $ac_status" >&5
8986 (exit $ac_status); } &&
8987 { ac_try='test -s conftest$ac_exeext'
8988 { (eval echo "$as_me:8988: \"$ac_try\"") >&5
8991 echo "$as_me:8991: \$? = $ac_status" >&5
8992 (exit $ac_status); }; }; then
8993 echo "$as_me:8993: result: yes" >&5
8994 echo "${ECHO_T}yes" >&6
8995 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
8998 echo "$as_me: failed program was:" >&5
8999 cat conftest.$ac_ext >&5
9000 echo "$as_me:9000: result: no" >&5
9001 echo "${ECHO_T}no" >&6
9004 cf_library_path_list=""
9005 if test -n "${LDFLAGS}${LIBS}" ; then
9006 for cf_library_path in $LDFLAGS $LIBS
9008 case $cf_library_path in
9010 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
9012 test "x$cf_library_path" != "xNONE" && \
9013 test -d "$cf_library_path" && \
9015 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
9016 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
9017 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
9018 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
9019 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
9020 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"
9023 cf_library_path_list="$cf_library_path_list $cf_search"
9031 test "x$prefix" != "xNONE" && \
9032 test -d "$prefix" && \
9034 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
9035 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
9036 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
9037 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
9038 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
9039 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
9042 for cf_subdir_prefix in \
9051 test "x$cf_subdir_prefix" != "x$prefix" && \
9052 test -d "$cf_subdir_prefix" && \
9053 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
9054 test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
9055 test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib"
9056 test -d $cf_subdir_prefix/lib/$cf_nculib_root && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root"
9057 test -d $cf_subdir_prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root/lib"
9058 test -d $cf_subdir_prefix/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib"
9059 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"
9064 cf_search="$cf_library_path_list $cf_search"
9066 for cf_libdir in $cf_search
9068 echo "$as_me:9068: checking for -l$cf_nculib_root in $cf_libdir" >&5
9069 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
9070 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
9071 cat >conftest.$ac_ext <<_ACEOF
9072 #line 9072 "configure"
9073 #include "confdefs.h"
9074 #include <${cf_cv_ncurses_header:-curses.h}>
9083 rm -f conftest.$ac_objext conftest$ac_exeext
9084 if { (eval echo "$as_me:9084: \"$ac_link\"") >&5
9085 (eval $ac_link) 2>&5
9087 echo "$as_me:9087: \$? = $ac_status" >&5
9088 (exit $ac_status); } &&
9089 { ac_try='test -s conftest$ac_exeext'
9090 { (eval echo "$as_me:9090: \"$ac_try\"") >&5
9093 echo "$as_me:9093: \$? = $ac_status" >&5
9094 (exit $ac_status); }; }; then
9095 echo "$as_me:9095: result: yes" >&5
9096 echo "${ECHO_T}yes" >&6
9097 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
9100 echo "$as_me: failed program was:" >&5
9101 cat conftest.$ac_ext >&5
9102 echo "$as_me:9102: result: no" >&5
9103 echo "${ECHO_T}no" >&6
9104 LIBS="$cf_save_LIBS"
9106 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9110 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9114 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
9116 if test $cf_found_library = no ; then
9117 { { echo "$as_me:9117: error: Cannot link $cf_nculib_root library" >&5
9118 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
9119 { (exit 1); exit 1; }; }
9124 if test -n "$cf_ncurses_LIBS" ; then
9125 echo "$as_me:9125: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
9126 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
9127 cf_ncurses_SAVE="$LIBS"
9128 for p in $cf_ncurses_LIBS ; do
9129 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
9130 if test "$q" != "$LIBS" ; then
9134 cat >conftest.$ac_ext <<_ACEOF
9135 #line 9135 "configure"
9136 #include "confdefs.h"
9137 #include <${cf_cv_ncurses_header:-curses.h}>
9141 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
9146 rm -f conftest.$ac_objext conftest$ac_exeext
9147 if { (eval echo "$as_me:9147: \"$ac_link\"") >&5
9148 (eval $ac_link) 2>&5
9150 echo "$as_me:9150: \$? = $ac_status" >&5
9151 (exit $ac_status); } &&
9152 { ac_try='test -s conftest$ac_exeext'
9153 { (eval echo "$as_me:9153: \"$ac_try\"") >&5
9156 echo "$as_me:9156: \$? = $ac_status" >&5
9157 (exit $ac_status); }; }; then
9158 echo "$as_me:9158: result: yes" >&5
9159 echo "${ECHO_T}yes" >&6
9161 echo "$as_me: failed program was:" >&5
9162 cat conftest.$ac_ext >&5
9163 echo "$as_me:9163: result: no" >&5
9164 echo "${ECHO_T}no" >&6
9165 LIBS="$cf_ncurses_SAVE"
9167 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9170 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
9172 cat >>confdefs.h <<EOF
9173 #define $cf_nculib_ROOT 1
9183 if test "$NCURSES_CONFIG_PKG" != none ; then
9184 cf_version=`$PKG_CONFIG --modversion $NCURSES_CONFIG_PKG 2>/dev/null`
9186 NCURSES_MAJOR=`echo "$cf_version" | sed -e 's/\..*//'`
9187 NCURSES_MINOR=`echo "$cf_version" | sed -e 's/^[0-9][0-9]*\.//' -e 's/\..*//'`
9188 NCURSES_PATCH=`echo "$cf_version" | sed -e 's/^[0-9][0-9]*\.[0-9][0-9]*\.//'`
9190 cf_cv_abi_version=`$PKG_CONFIG --variable=abi_version $NCURSES_CONFIG_PKG 2>/dev/null`
9191 if test -z "$cf_cv_abi_version"
9193 cf_cv_abi_version=`$PKG_CONFIG --variable=major_version $NCURSES_CONFIG_PKG 2>/dev/null`
9196 elif test "$NCURSES_CONFIG" != none ; then
9198 cf_version=`$NCURSES_CONFIG --version 2>/dev/null`
9200 NCURSES_MAJOR=`echo "$cf_version" | sed -e 's/\..*//'`
9201 NCURSES_MINOR=`echo "$cf_version" | sed -e 's/^[0-9][0-9]*\.//' -e 's/\..*//'`
9202 NCURSES_PATCH=`echo "$cf_version" | sed -e 's/^[0-9][0-9]*\.[0-9][0-9]*\.//'`
9204 # ABI version is not available from headers
9205 cf_cv_abi_version=`$NCURSES_CONFIG --abi-version 2>/dev/null`
9209 for cf_name in MAJOR MINOR PATCH
9211 cat >conftest.$ac_ext <<CF_EOF
9212 #include <${cf_cv_ncurses_header:-curses.h}>
9213 AUTOCONF_$cf_name NCURSES_VERSION_$cf_name
9215 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | fgrep AUTOCONF_$cf_name >conftest.out"
9216 { (eval echo "$as_me:9216: \"$cf_try\"") >&5
9219 echo "$as_me:9219: \$? = $ac_status" >&5
9220 (exit $ac_status); }
9221 if test -f conftest.out ; then
9222 cf_result=`cat conftest.out | sed -e "s/^.*AUTOCONF_$cf_name[ ][ ]*//"`
9223 eval NCURSES_$cf_name=\"$cf_result\"
9224 # cat conftest.$ac_ext
9229 cf_cv_abi_version=${NCURSES_MAJOR}
9233 cf_cv_rel_version=${NCURSES_MAJOR}.${NCURSES_MINOR}
9235 cf_cv_timestamp=`date`
9237 echo "$as_me:9237: result: Configuring NCURSES $cf_cv_rel_version ABI $cf_cv_abi_version ($cf_cv_timestamp)" >&5
9238 echo "${ECHO_T}Configuring NCURSES $cf_cv_rel_version ABI $cf_cv_abi_version ($cf_cv_timestamp)" >&6
9240 echo "$as_me:9240: checking if you want to have a library-prefix" >&5
9241 echo $ECHO_N "checking if you want to have a library-prefix... $ECHO_C" >&6
9243 # Check whether --with-lib-prefix or --without-lib-prefix was given.
9244 if test "${with_lib_prefix+set}" = set; then
9245 withval="$with_lib_prefix"
9246 with_lib_prefix=$withval
9248 with_lib_prefix=auto
9250 echo "$as_me:9250: result: $with_lib_prefix" >&5
9251 echo "${ECHO_T}$with_lib_prefix" >&6
9253 if test $with_lib_prefix = auto
9256 case $cf_cv_system_name in
9258 if test "$DFT_LWR_MODEL" = libtool; then
9264 (*) LIB_PREFIX='lib'
9267 cf_prefix=$LIB_PREFIX
9269 elif test $with_lib_prefix = no
9273 LIB_PREFIX=$with_lib_prefix
9278 ###############################################################################
9280 if test X"$CC_G_OPT" = X"" ; then
9282 test -n "$GCC" && test "${ac_cv_prog_cc_g}" != yes && CC_G_OPT=''
9285 echo "$as_me:9285: checking for default loader flags" >&5
9286 echo $ECHO_N "checking for default loader flags... $ECHO_C" >&6
9287 case $DFT_LWR_MODEL in
9288 (normal) LD_MODEL='' ;;
9289 (debug) LD_MODEL=$CC_G_OPT ;;
9290 (profile) LD_MODEL='-pg';;
9291 (shared) LD_MODEL='' ;;
9293 echo "$as_me:9293: result: $LD_MODEL" >&5
9294 echo "${ECHO_T}$LD_MODEL" >&6
9297 echo "$as_me:9297: checking for an rpath option" >&5
9298 echo $ECHO_N "checking for an rpath option... $ECHO_C" >&6
9299 case $cf_cv_system_name in
9301 if test "$GCC" = yes; then
9302 LD_RPATH_OPT="-Wl,-rpath,"
9304 LD_RPATH_OPT="-rpath "
9307 (linux*|gnu*|k*bsd*-gnu|freebsd*)
9308 LD_RPATH_OPT="-Wl,-rpath,"
9310 (openbsd[2-9].*|mirbsd*)
9311 LD_RPATH_OPT="-Wl,-rpath,"
9314 LD_RPATH_OPT="-rpath "
9317 LD_RPATH_OPT="-Wl,-rpath,"
9320 LD_RPATH_OPT="-rpath "
9328 echo "$as_me:9328: result: $LD_RPATH_OPT" >&5
9329 echo "${ECHO_T}$LD_RPATH_OPT" >&6
9331 case "x$LD_RPATH_OPT" in
9333 echo "$as_me:9333: checking if we need a space after rpath option" >&5
9334 echo $ECHO_N "checking if we need a space after rpath option... $ECHO_C" >&6
9335 cf_save_LIBS="$LIBS"
9337 cf_add_libs="${LD_RPATH_OPT}$libdir"
9338 # Filter out duplicates - this happens with badly-designed ".pc" files...
9339 for cf_add_1lib in $LIBS
9341 for cf_add_2lib in $cf_add_libs
9343 if test "x$cf_add_1lib" = "x$cf_add_2lib"
9349 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
9353 cat >conftest.$ac_ext <<_ACEOF
9354 #line 9354 "configure"
9355 #include "confdefs.h"
9365 rm -f conftest.$ac_objext conftest$ac_exeext
9366 if { (eval echo "$as_me:9366: \"$ac_link\"") >&5
9367 (eval $ac_link) 2>&5
9369 echo "$as_me:9369: \$? = $ac_status" >&5
9370 (exit $ac_status); } &&
9371 { ac_try='test -s conftest$ac_exeext'
9372 { (eval echo "$as_me:9372: \"$ac_try\"") >&5
9375 echo "$as_me:9375: \$? = $ac_status" >&5
9376 (exit $ac_status); }; }; then
9379 echo "$as_me: failed program was:" >&5
9380 cat conftest.$ac_ext >&5
9383 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9384 LIBS="$cf_save_LIBS"
9385 echo "$as_me:9385: result: $cf_rpath_space" >&5
9386 echo "${ECHO_T}$cf_rpath_space" >&6
9387 test "$cf_rpath_space" = yes && LD_RPATH_OPT="$LD_RPATH_OPT "
9395 INSTALL_LIB="-m 644"
9396 : ${rel_builddir:=.}
9402 cf_cv_do_symlinks=no
9404 test "$cf_cv_enable_rpath" = yes && cf_ld_rpath_opt="$LD_RPATH_OPT"
9406 echo "$as_me:9406: checking if release/abi version should be used for shared libs" >&5
9407 echo $ECHO_N "checking if release/abi version should be used for shared libs... $ECHO_C" >&6
9409 # Check whether --with-shlib-version or --without-shlib-version was given.
9410 if test "${with_shlib_version+set}" = set; then
9411 withval="$with_shlib_version"
9412 test -z "$withval" && withval=auto
9415 cf_cv_shlib_version=auto
9418 cf_cv_shlib_version=$withval
9421 echo "$as_me:9421: result: $withval" >&5
9422 echo "${ECHO_T}$withval" >&6
9423 { { echo "$as_me:9423: error: option value must be one of: rel, abi, or auto" >&5
9424 echo "$as_me: error: option value must be one of: rel, abi, or auto" >&2;}
9425 { (exit 1); exit 1; }; }
9430 cf_cv_shlib_version=auto
9432 echo "$as_me:9432: result: $cf_cv_shlib_version" >&5
9433 echo "${ECHO_T}$cf_cv_shlib_version" >&6
9438 # Some less-capable ports of gcc support only -fpic
9442 if test "$GCC" = yes
9446 case $cf_cv_system_name in
9447 (*linux*) # e.g., PGI compiler
9453 if test "$cf_try_fPIC" = yes
9455 echo "$as_me:9455: checking which $CC option to use" >&5
9456 echo $ECHO_N "checking which $CC option to use... $ECHO_C" >&6
9457 cf_save_CFLAGS="$CFLAGS"
9458 for CC_SHARED_OPTS in -fPIC -fpic ''
9460 CFLAGS="$cf_save_CFLAGS $CC_SHARED_OPTS"
9461 cat >conftest.$ac_ext <<_ACEOF
9462 #line 9462 "configure"
9463 #include "confdefs.h"
9473 rm -f conftest.$ac_objext
9474 if { (eval echo "$as_me:9474: \"$ac_compile\"") >&5
9475 (eval $ac_compile) 2>&5
9477 echo "$as_me:9477: \$? = $ac_status" >&5
9478 (exit $ac_status); } &&
9479 { ac_try='test -s conftest.$ac_objext'
9480 { (eval echo "$as_me:9480: \"$ac_try\"") >&5
9483 echo "$as_me:9483: \$? = $ac_status" >&5
9484 (exit $ac_status); }; }; then
9487 echo "$as_me: failed program was:" >&5
9488 cat conftest.$ac_ext >&5
9490 rm -f conftest.$ac_objext conftest.$ac_ext
9492 echo "$as_me:9492: result: $CC_SHARED_OPTS" >&5
9493 echo "${ECHO_T}$CC_SHARED_OPTS" >&6
9494 CFLAGS="$cf_save_CFLAGS"
9497 cf_cv_shlib_version_infix=no
9499 case $cf_cv_system_name in
9500 (aix4.3-9*|aix[5-7]*)
9501 if test "$GCC" = yes; then
9502 CC_SHARED_OPTS='-Wl,-brtl'
9503 MK_SHARED_LIB='${CC} -shared -Wl,-brtl -Wl,-blibpath:${RPATH_LIST}:/usr/lib -o $@'
9505 CC_SHARED_OPTS='-brtl'
9506 # as well as '-qpic=large -G' or perhaps "-bM:SRE -bnoentry -bexpall"
9507 MK_SHARED_LIB='${CC} -G -Wl,-brtl -Wl,-blibpath:${RPATH_LIST}:/usr/lib -o $@'
9511 MK_SHARED_LIB='${CC} ${CFLAGS} -o $@ -Xlinker -soname=`basename $@` -nostart -e 0'
9515 MK_SHARED_LIB=$SHELL' '$rel_builddir'/mk_shared_lib.sh $@ ${CC} ${CFLAGS}'
9516 RM_SHARED_OPTS="$RM_SHARED_OPTS $rel_builddir/mk_shared_lib.sh *.dll.a"
9517 cf_cv_shlib_version=cygdll
9518 cf_cv_shlib_version_infix=cygdll
9521 cat >mk_shared_lib.sh <<-CF_EOF
9524 IMPORT_LIB=\`echo "\$1" | sed -e 's/cyg/lib/' -e 's/[0-9]*\.dll$/.dll.a/'\`
9527 Linking shared library
9528 ** SHARED_LIB \$SHARED_LIB
9529 ** IMPORT_LIB \$IMPORT_LIB
9531 exec \$* -shared -Wl,--out-implib=\${IMPORT_LIB} -Wl,--export-all-symbols -o \${SHARED_LIB}
9533 chmod +x mk_shared_lib.sh
9537 MK_SHARED_LIB=$SHELL' '$rel_builddir'/mk_shared_lib.sh $@ ${CC} ${CFLAGS}'
9538 RM_SHARED_OPTS="$RM_SHARED_OPTS $rel_builddir/mk_shared_lib.sh *.dll.a"
9539 cf_cv_shlib_version=msysdll
9540 cf_cv_shlib_version_infix=msysdll
9543 cat >mk_shared_lib.sh <<-CF_EOF
9546 IMPORT_LIB=\`echo "\$1" | sed -e 's/msys-/lib/' -e 's/[0-9]*\.dll$/.dll.a/'\`
9549 Linking shared library
9550 ** SHARED_LIB \$SHARED_LIB
9551 ** IMPORT_LIB \$IMPORT_LIB
9553 exec \$* -shared -Wl,--out-implib=\${IMPORT_LIB} -Wl,--export-all-symbols -o \${SHARED_LIB}
9555 chmod +x mk_shared_lib.sh
9558 cf_try_cflags="no-cpp-precomp"
9559 CC_SHARED_OPTS="-dynamic"
9560 MK_SHARED_LIB='${CC} ${CFLAGS} -dynamiclib -install_name ${libdir}/`basename $@` -compatibility_version ${ABI_VERSION} -current_version ${ABI_VERSION} -o $@'
9561 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=abi
9562 cf_cv_shlib_version_infix=yes
9563 echo "$as_me:9563: checking if ld -search_paths_first works" >&5
9564 echo $ECHO_N "checking if ld -search_paths_first works... $ECHO_C" >&6
9565 if test "${cf_cv_ldflags_search_paths_first+set}" = set; then
9566 echo $ECHO_N "(cached) $ECHO_C" >&6
9569 cf_save_LDFLAGS=$LDFLAGS
9570 LDFLAGS="$LDFLAGS -Wl,-search_paths_first"
9571 cat >conftest.$ac_ext <<_ACEOF
9572 #line 9572 "configure"
9573 #include "confdefs.h"
9583 rm -f conftest.$ac_objext conftest$ac_exeext
9584 if { (eval echo "$as_me:9584: \"$ac_link\"") >&5
9585 (eval $ac_link) 2>&5
9587 echo "$as_me:9587: \$? = $ac_status" >&5
9588 (exit $ac_status); } &&
9589 { ac_try='test -s conftest$ac_exeext'
9590 { (eval echo "$as_me:9590: \"$ac_try\"") >&5
9593 echo "$as_me:9593: \$? = $ac_status" >&5
9594 (exit $ac_status); }; }; then
9595 cf_cv_ldflags_search_paths_first=yes
9597 echo "$as_me: failed program was:" >&5
9598 cat conftest.$ac_ext >&5
9599 cf_cv_ldflags_search_paths_first=no
9601 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9602 LDFLAGS=$cf_save_LDFLAGS
9604 echo "$as_me:9604: result: $cf_cv_ldflags_search_paths_first" >&5
9605 echo "${ECHO_T}$cf_cv_ldflags_search_paths_first" >&6
9606 if test $cf_cv_ldflags_search_paths_first = yes; then
9607 LDFLAGS="$LDFLAGS -Wl,-search_paths_first"
9611 # HP-UX 8.07 ld lacks "+b" option used for libdir search-list
9612 if test "$GCC" != yes; then
9615 MK_SHARED_LIB='${LD} -b -o $@'
9616 INSTALL_LIB="-m 555"
9619 # (tested with gcc 2.7.2 -- I don't have c89)
9620 if test "$GCC" = yes; then
9621 LD_SHARED_OPTS='-Xlinker +b -Xlinker ${libdir}'
9624 LD_SHARED_OPTS='-Wl,+b,${libdir}'
9626 MK_SHARED_LIB='${LD} +b ${libdir} -b -o $@'
9627 # HP-UX shared libraries must be executable, and should be
9628 # readonly to exploit a quirk in the memory manager.
9629 INSTALL_LIB="-m 555"
9632 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9633 if test "$cf_cv_shlib_version" = rel; then
9634 cf_shared_soname='`basename .${REL_VERSION}`.${ABI_VERSION}'
9636 cf_shared_soname='`basename `'
9639 MK_SHARED_LIB='${CC} -shared -Wl,-rpath,${RPATH_LIST} -Wl,-h,'$cf_shared_soname' -o '
9642 if test "$cf_cv_enable_rpath" = yes ; then
9643 EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${RPATH_LIST} $EXTRA_LDFLAGS"
9645 # tested with IRIX 5.2 and 'cc'.
9646 if test "$GCC" != yes; then
9647 CC_SHARED_OPTS='-KPIC'
9648 MK_SHARED_LIB='${CC} -shared -rdata_shared -soname `basename $@` -o $@'
9650 MK_SHARED_LIB='${CC} -shared -Wl,-soname,`basename $@` -o $@'
9652 cf_cv_rm_so_locs=yes
9654 (linux*|gnu*|k*bsd*-gnu)
9655 if test "$DFT_LWR_MODEL" = "shared" ; then
9656 LOCAL_LDFLAGS="${LD_RPATH_OPT}\$(LOCAL_LIBDIR)"
9657 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
9659 if test "$cf_cv_enable_rpath" = yes ; then
9660 EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${RPATH_LIST} $EXTRA_LDFLAGS"
9663 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9664 if test "$cf_cv_shlib_version" = rel; then
9665 cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
9667 cf_cv_shared_soname='`basename $@`'
9670 MK_SHARED_LIB='${CC} ${CFLAGS} -shared -Wl,-soname,'$cf_cv_shared_soname',-stats,-lc -o $@'
9673 cf_cv_shlib_version=mingw
9674 cf_cv_shlib_version_infix=mingw
9677 if test "$DFT_LWR_MODEL" = "shared" ; then
9678 LOCAL_LDFLAGS="-Wl,--enable-auto-import"
9679 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
9680 EXTRA_LDFLAGS="-Wl,--enable-auto-import $EXTRA_LDFLAGS"
9683 MK_SHARED_LIB=$SHELL' '$rel_builddir'/mk_shared_lib.sh $@ ${CC} ${CFLAGS}'
9684 RM_SHARED_OPTS="$RM_SHARED_OPTS $rel_builddir/mk_shared_lib.sh *.dll.a"
9685 cat >mk_shared_lib.sh <<-CF_EOF
9688 IMPORT_LIB=\`echo "\$1" | sed -e 's/[0-9]*\.dll$/.dll.a/'\`
9691 Linking shared library
9692 ** SHARED_LIB \$SHARED_LIB
9693 ** IMPORT_LIB \$IMPORT_LIB
9695 exec \$* -shared -Wl,--enable-auto-import,--out-implib=\${IMPORT_LIB} -Wl,--export-all-symbols -o \${SHARED_LIB}
9697 chmod +x mk_shared_lib.sh
9699 (openbsd[2-9].*|mirbsd*)
9700 if test "$DFT_LWR_MODEL" = "shared" ; then
9701 LOCAL_LDFLAGS="${LD_RPATH_OPT}\$(LOCAL_LIBDIR)"
9702 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
9704 if test "$cf_cv_enable_rpath" = yes ; then
9705 EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${RPATH_LIST} $EXTRA_LDFLAGS"
9707 CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC"
9709 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9710 if test "$cf_cv_shlib_version" = rel; then
9711 cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
9713 cf_cv_shared_soname='`basename $@`'
9716 MK_SHARED_LIB='${CC} ${CFLAGS} -shared -Wl,-Bshareable,-soname,'$cf_cv_shared_soname',-stats,-lc -o $@'
9718 (nto-qnx*|openbsd*|freebsd[12].*)
9719 CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC"
9720 MK_SHARED_LIB='${LD} -Bshareable -o $@'
9721 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9723 (dragonfly*|freebsd*)
9724 CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC"
9725 if test "$DFT_LWR_MODEL" = "shared" && test "$cf_cv_enable_rpath" = yes ; then
9726 LOCAL_LDFLAGS="${cf_ld_rpath_opt}\$(LOCAL_LIBDIR)"
9727 LOCAL_LDFLAGS2="${cf_ld_rpath_opt}\${RPATH_LIST} $LOCAL_LDFLAGS"
9728 EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${RPATH_LIST} $EXTRA_LDFLAGS"
9731 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9732 if test "$cf_cv_shlib_version" = rel; then
9733 cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
9735 cf_cv_shared_soname='`basename $@`'
9738 MK_SHARED_LIB='${CC} ${CFLAGS} -shared -Wl,-soname,'$cf_cv_shared_soname',-stats,-lc -o $@'
9741 CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC"
9742 if test "$DFT_LWR_MODEL" = "shared" && test "$cf_cv_enable_rpath" = yes ; then
9743 LOCAL_LDFLAGS="${cf_ld_rpath_opt}\$(LOCAL_LIBDIR)"
9744 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
9745 EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${RPATH_LIST} $EXTRA_LDFLAGS"
9746 if test "$cf_cv_shlib_version" = auto; then
9747 if test -f /usr/libexec/ld.elf_so; then
9748 cf_cv_shlib_version=abi
9750 cf_cv_shlib_version=rel
9754 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9755 if test "$cf_cv_shlib_version" = rel; then
9756 cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
9758 cf_cv_shared_soname='`basename $@`'
9761 MK_SHARED_LIB='${CC} ${CFLAGS} -shared -Wl,-soname,'$cf_cv_shared_soname' -o $@'
9763 MK_SHARED_LIB='${CC} -Wl,-shared -Wl,-Bshareable -o $@'
9767 # tested with OSF/1 V3.2 and 'cc'
9768 # tested with OSF/1 V3.2 and gcc 2.6.3 (but the c++ demo didn't
9769 # link with shared libs).
9770 MK_SHARED_LIB='${LD} -set_version ${REL_VERSION}:${ABI_VERSION} -expect_unresolved "*" -shared -soname `basename $@`'
9773 MK_SHARED_LIB="${MK_SHARED_LIB} -msym"
9776 MK_SHARED_LIB="${MK_SHARED_LIB}"' -o $@'
9777 if test "$DFT_LWR_MODEL" = "shared" ; then
9778 LOCAL_LDFLAGS="${LD_RPATH_OPT}\$(LOCAL_LIBDIR)"
9779 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
9781 cf_cv_rm_so_locs=yes
9783 (sco3.2v5*) # also uw2* and UW7: hops 13-Apr-98
9784 # tested with osr5.0.5
9785 if test "$GCC" != yes; then
9786 CC_SHARED_OPTS='-belf -KPIC'
9788 MK_SHARED_LIB='${LD} -dy -G -h `basename $@ .${REL_VERSION}`.${ABI_VERSION} -o $@'
9789 if test "$cf_cv_enable_rpath" = yes ; then
9790 # only way is to set LD_RUN_PATH but no switch for it
9793 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9794 LINK_PROGS='LD_RUN_PATH=${libdir}'
9795 LINK_TESTS='Pwd=`pwd`;LD_RUN_PATH=`dirname $${Pwd}`/lib'
9798 # tested with SunOS 4.1.1 and gcc 2.7.0
9799 if test "$GCC" != yes; then
9800 CC_SHARED_OPTS='-KPIC'
9802 MK_SHARED_LIB='${LD} -assert pure-text -o $@'
9803 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9806 # tested with SunOS 5.5.1 (solaris 2.5.1) and gcc 2.7.2
9807 # tested with SunOS 5.10 (solaris 10) and gcc 3.4.3
9808 if test "$DFT_LWR_MODEL" = "shared" ; then
9809 LOCAL_LDFLAGS="-R \$(LOCAL_LIBDIR):\${libdir}"
9810 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
9812 if test "$cf_cv_enable_rpath" = yes ; then
9813 EXTRA_LDFLAGS="-R \${libdir} $EXTRA_LDFLAGS"
9816 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9817 if test "$cf_cv_shlib_version" = rel; then
9818 cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
9820 cf_cv_shared_soname='`basename $@`'
9823 if test "$GCC" != yes; then
9824 cf_save_CFLAGS="$CFLAGS"
9825 for cf_shared_opts in -xcode=pic32 -xcode=pic13 -KPIC -Kpic -O
9827 CFLAGS="$cf_shared_opts $cf_save_CFLAGS"
9828 cat >conftest.$ac_ext <<_ACEOF
9829 #line 9829 "configure"
9830 #include "confdefs.h"
9840 rm -f conftest.$ac_objext
9841 if { (eval echo "$as_me:9841: \"$ac_compile\"") >&5
9842 (eval $ac_compile) 2>&5
9844 echo "$as_me:9844: \$? = $ac_status" >&5
9845 (exit $ac_status); } &&
9846 { ac_try='test -s conftest.$ac_objext'
9847 { (eval echo "$as_me:9847: \"$ac_try\"") >&5
9850 echo "$as_me:9850: \$? = $ac_status" >&5
9851 (exit $ac_status); }; }; then
9854 echo "$as_me: failed program was:" >&5
9855 cat conftest.$ac_ext >&5
9857 rm -f conftest.$ac_objext conftest.$ac_ext
9859 CFLAGS="$cf_save_CFLAGS"
9860 CC_SHARED_OPTS=$cf_shared_opts
9861 MK_SHARED_LIB='${CC} -dy -G -h '$cf_cv_shared_soname' -o $@'
9863 MK_SHARED_LIB='${CC} -shared -dy -G -h '$cf_cv_shared_soname' -o $@'
9866 (sysv5uw7*|unix_sv*)
9867 # tested with UnixWare 7.1.0 (gcc 2.95.2 and cc)
9868 if test "$GCC" != yes; then
9869 CC_SHARED_OPTS='-KPIC'
9871 MK_SHARED_LIB='${LD} -d y -G -o $@'
9874 CC_SHARED_OPTS='unknown'
9875 MK_SHARED_LIB='echo unknown'
9879 # This works if the last tokens in $MK_SHARED_LIB are the -o target.
9880 case "$cf_cv_shlib_version" in
9882 case "$MK_SHARED_LIB" in
9884 test "$cf_cv_do_symlinks" = no && cf_cv_do_symlinks=yes
9887 { echo "$as_me:9887: WARNING: ignored --with-shlib-version" >&5
9888 echo "$as_me: WARNING: ignored --with-shlib-version" >&2;}
9894 if test -n "$cf_try_cflags"
9896 cat > conftest.$ac_ext <<EOF
9897 #line 9897 "${as_me:-configure}"
9899 int main(int argc, char *argv[])
9902 return (argv[argc-1] == 0) ;
9905 cf_save_CFLAGS="$CFLAGS"
9906 for cf_opt in $cf_try_cflags
9908 CFLAGS="$cf_save_CFLAGS -$cf_opt"
9909 echo "$as_me:9909: checking if CFLAGS option -$cf_opt works" >&5
9910 echo $ECHO_N "checking if CFLAGS option -$cf_opt works... $ECHO_C" >&6
9911 if { (eval echo "$as_me:9911: \"$ac_compile\"") >&5
9912 (eval $ac_compile) 2>&5
9914 echo "$as_me:9914: \$? = $ac_status" >&5
9915 (exit $ac_status); }; then
9916 echo "$as_me:9916: result: yes" >&5
9917 echo "${ECHO_T}yes" >&6
9918 cf_save_CFLAGS="$CFLAGS"
9920 echo "$as_me:9920: result: no" >&5
9921 echo "${ECHO_T}no" >&6
9924 CFLAGS="$cf_save_CFLAGS"
9927 # RPATH_LIST is a colon-separated list of directories
9928 test -n "$cf_ld_rpath_opt" && MK_SHARED_LIB="$MK_SHARED_LIB $cf_ld_rpath_opt\${RPATH_LIST}"
9929 test -z "$RPATH_LIST" && RPATH_LIST="\${libdir}"
9931 test $cf_cv_rm_so_locs = yes && RM_SHARED_OPTS="$RM_SHARED_OPTS so_locations"
9933 test -n "$verbose" && echo " CC_SHARED_OPTS: $CC_SHARED_OPTS" 1>&6
9935 echo "${as_me:-configure}:9935: testing CC_SHARED_OPTS: $CC_SHARED_OPTS ..." 1>&5
9937 test -n "$verbose" && echo " MK_SHARED_LIB: $MK_SHARED_LIB" 1>&6
9939 echo "${as_me:-configure}:9939: testing MK_SHARED_LIB: $MK_SHARED_LIB ..." 1>&5
9941 # The test/sample programs in the original tree link using rpath option.
9942 # Make it optional for packagers.
9943 if test -n "$LOCAL_LDFLAGS"
9945 echo "$as_me:9945: checking if you want to link sample programs with rpath option" >&5
9946 echo $ECHO_N "checking if you want to link sample programs with rpath option... $ECHO_C" >&6
9948 # Check whether --enable-rpath-link or --disable-rpath-link was given.
9949 if test "${enable_rpath_link+set}" = set; then
9950 enableval="$enable_rpath_link"
9951 with_rpath_link=$enableval
9955 echo "$as_me:9955: result: $with_rpath_link" >&5
9956 echo "${ECHO_T}$with_rpath_link" >&6
9957 if test "$with_rpath_link" = no
9964 ###############################################################################
9966 ### use option --enable-broken-linker to force on use of broken-linker support
9967 echo "$as_me:9967: checking if you want broken-linker support code" >&5
9968 echo $ECHO_N "checking if you want broken-linker support code... $ECHO_C" >&6
9970 # Check whether --enable-broken_linker or --disable-broken_linker was given.
9971 if test "${enable_broken_linker+set}" = set; then
9972 enableval="$enable_broken_linker"
9973 with_broken_linker=$enableval
9975 with_broken_linker=${BROKEN_LINKER:-no}
9977 echo "$as_me:9977: result: $with_broken_linker" >&5
9978 echo "${ECHO_T}$with_broken_linker" >&6
9981 if test "$with_broken_linker" = yes ; then
9982 cat >>confdefs.h <<\EOF
9983 #define BROKEN_LINKER 1
9987 elif test "$DFT_LWR_MODEL" = shared ; then
9988 case $cf_cv_system_name in
9990 cat >>confdefs.h <<\EOF
9991 #define BROKEN_LINKER 1
9995 test -n "$verbose" && echo " cygwin linker is broken anyway" 1>&6
9997 echo "${as_me:-configure}:9997: testing cygwin linker is broken anyway ..." 1>&5
10003 # Check to define _XOPEN_SOURCE "automatically"
10005 cf_XOPEN_SOURCE=500
10006 cf_POSIX_C_SOURCE=199506L
10011 cf_xopen_source="-D_ALL_SOURCE"
10014 cf_XOPEN_SOURCE=600
10017 cf_xopen_source="-D_APPLE_C_SOURCE"
10020 cf_xopen_source="-D_DARWIN_C_SOURCE"
10023 (freebsd*|dragonfly*)
10024 # 5.x headers associate
10025 # _XOPEN_SOURCE=600 with _POSIX_C_SOURCE=200112L
10026 # _XOPEN_SOURCE=500 with _POSIX_C_SOURCE=199506L
10027 cf_POSIX_C_SOURCE=200112L
10028 cf_XOPEN_SOURCE=600
10029 cf_xopen_source="-D_BSD_TYPES -D__BSD_VISIBLE -D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
10032 cf_xopen_source="-D_HPUX_SOURCE -D_XOPEN_SOURCE=500"
10035 cf_xopen_source="-D_HPUX_SOURCE"
10038 cf_xopen_source="-D_SGI_SOURCE"
10041 (linux*|uclinux*|gnu*|mint*|k*bsd*-gnu|cygwin)
10043 echo "$as_me:10043: checking if we must define _GNU_SOURCE" >&5
10044 echo $ECHO_N "checking if we must define _GNU_SOURCE... $ECHO_C" >&6
10045 if test "${cf_cv_gnu_source+set}" = set; then
10046 echo $ECHO_N "(cached) $ECHO_C" >&6
10049 cat >conftest.$ac_ext <<_ACEOF
10050 #line 10050 "configure"
10051 #include "confdefs.h"
10052 #include <sys/types.h>
10057 #ifndef _XOPEN_SOURCE
10064 rm -f conftest.$ac_objext
10065 if { (eval echo "$as_me:10065: \"$ac_compile\"") >&5
10066 (eval $ac_compile) 2>&5
10068 echo "$as_me:10068: \$? = $ac_status" >&5
10069 (exit $ac_status); } &&
10070 { ac_try='test -s conftest.$ac_objext'
10071 { (eval echo "$as_me:10071: \"$ac_try\"") >&5
10072 (eval $ac_try) 2>&5
10074 echo "$as_me:10074: \$? = $ac_status" >&5
10075 (exit $ac_status); }; }; then
10076 cf_cv_gnu_source=no
10078 echo "$as_me: failed program was:" >&5
10079 cat conftest.$ac_ext >&5
10080 cf_save="$CPPFLAGS"
10081 CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE"
10082 cat >conftest.$ac_ext <<_ACEOF
10083 #line 10083 "configure"
10084 #include "confdefs.h"
10085 #include <sys/types.h>
10090 #ifdef _XOPEN_SOURCE
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_gnu_source=no
10111 echo "$as_me: failed program was:" >&5
10112 cat conftest.$ac_ext >&5
10113 cf_cv_gnu_source=yes
10115 rm -f conftest.$ac_objext conftest.$ac_ext
10116 CPPFLAGS="$cf_save"
10119 rm -f conftest.$ac_objext conftest.$ac_ext
10122 echo "$as_me:10122: result: $cf_cv_gnu_source" >&5
10123 echo "${ECHO_T}$cf_cv_gnu_source" >&6
10125 if test "$cf_cv_gnu_source" = yes
10127 echo "$as_me:10127: checking if we should also define _DEFAULT_SOURCE" >&5
10128 echo $ECHO_N "checking if we should also define _DEFAULT_SOURCE... $ECHO_C" >&6
10129 if test "${cf_cv_default_source+set}" = set; then
10130 echo $ECHO_N "(cached) $ECHO_C" >&6
10133 CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE"
10134 cat >conftest.$ac_ext <<_ACEOF
10135 #line 10135 "configure"
10136 #include "confdefs.h"
10137 #include <sys/types.h>
10142 #ifdef _DEFAULT_SOURCE
10149 rm -f conftest.$ac_objext
10150 if { (eval echo "$as_me:10150: \"$ac_compile\"") >&5
10151 (eval $ac_compile) 2>&5
10153 echo "$as_me:10153: \$? = $ac_status" >&5
10154 (exit $ac_status); } &&
10155 { ac_try='test -s conftest.$ac_objext'
10156 { (eval echo "$as_me:10156: \"$ac_try\"") >&5
10157 (eval $ac_try) 2>&5
10159 echo "$as_me:10159: \$? = $ac_status" >&5
10160 (exit $ac_status); }; }; then
10161 cf_cv_default_source=no
10163 echo "$as_me: failed program was:" >&5
10164 cat conftest.$ac_ext >&5
10165 cf_cv_default_source=yes
10167 rm -f conftest.$ac_objext conftest.$ac_ext
10170 echo "$as_me:10170: result: $cf_cv_default_source" >&5
10171 echo "${ECHO_T}$cf_cv_default_source" >&6
10172 test "$cf_cv_default_source" = yes && CPPFLAGS="$CPPFLAGS -D_DEFAULT_SOURCE"
10177 cf_xopen_source="-D_NETBSD_SOURCE" # POSIX.1-2001 features are ifdef'd with this...
10180 # setting _XOPEN_SOURCE or _POSIX_SOURCE breaks <sys/select.h> and other headers which use u_int / u_short types
10183 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
10185 cf_save_CFLAGS="$CFLAGS"
10186 cf_save_CPPFLAGS="$CPPFLAGS"
10188 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
10189 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
10190 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
10192 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
10193 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
10194 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
10196 echo "$as_me:10196: checking if we should define _POSIX_C_SOURCE" >&5
10197 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
10198 if test "${cf_cv_posix_c_source+set}" = set; then
10199 echo $ECHO_N "(cached) $ECHO_C" >&6
10202 echo "${as_me:-configure}:10202: testing if the symbol is already defined go no further ..." 1>&5
10204 cat >conftest.$ac_ext <<_ACEOF
10205 #line 10205 "configure"
10206 #include "confdefs.h"
10207 #include <sys/types.h>
10212 #ifndef _POSIX_C_SOURCE
10219 rm -f conftest.$ac_objext
10220 if { (eval echo "$as_me:10220: \"$ac_compile\"") >&5
10221 (eval $ac_compile) 2>&5
10223 echo "$as_me:10223: \$? = $ac_status" >&5
10224 (exit $ac_status); } &&
10225 { ac_try='test -s conftest.$ac_objext'
10226 { (eval echo "$as_me:10226: \"$ac_try\"") >&5
10227 (eval $ac_try) 2>&5
10229 echo "$as_me:10229: \$? = $ac_status" >&5
10230 (exit $ac_status); }; }; then
10231 cf_cv_posix_c_source=no
10233 echo "$as_me: failed program was:" >&5
10234 cat conftest.$ac_ext >&5
10235 cf_want_posix_source=no
10236 case .$cf_POSIX_C_SOURCE in
10238 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
10241 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
10242 cf_want_posix_source=yes
10245 cf_want_posix_source=yes
10248 if test "$cf_want_posix_source" = yes ; then
10249 cat >conftest.$ac_ext <<_ACEOF
10250 #line 10250 "configure"
10251 #include "confdefs.h"
10252 #include <sys/types.h>
10257 #ifdef _POSIX_SOURCE
10264 rm -f conftest.$ac_objext
10265 if { (eval echo "$as_me:10265: \"$ac_compile\"") >&5
10266 (eval $ac_compile) 2>&5
10268 echo "$as_me:10268: \$? = $ac_status" >&5
10269 (exit $ac_status); } &&
10270 { ac_try='test -s conftest.$ac_objext'
10271 { (eval echo "$as_me:10271: \"$ac_try\"") >&5
10272 (eval $ac_try) 2>&5
10274 echo "$as_me:10274: \$? = $ac_status" >&5
10275 (exit $ac_status); }; }; then
10278 echo "$as_me: failed program was:" >&5
10279 cat conftest.$ac_ext >&5
10280 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
10282 rm -f conftest.$ac_objext conftest.$ac_ext
10285 echo "${as_me:-configure}:10285: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
10287 CFLAGS="$cf_trim_CFLAGS"
10288 CPPFLAGS="$cf_trim_CPPFLAGS $cf_cv_posix_c_source"
10290 echo "${as_me:-configure}:10290: testing if the second compile does not leave our definition intact error ..." 1>&5
10292 cat >conftest.$ac_ext <<_ACEOF
10293 #line 10293 "configure"
10294 #include "confdefs.h"
10295 #include <sys/types.h>
10300 #ifndef _POSIX_C_SOURCE
10307 rm -f conftest.$ac_objext
10308 if { (eval echo "$as_me:10308: \"$ac_compile\"") >&5
10309 (eval $ac_compile) 2>&5
10311 echo "$as_me:10311: \$? = $ac_status" >&5
10312 (exit $ac_status); } &&
10313 { ac_try='test -s conftest.$ac_objext'
10314 { (eval echo "$as_me:10314: \"$ac_try\"") >&5
10315 (eval $ac_try) 2>&5
10317 echo "$as_me:10317: \$? = $ac_status" >&5
10318 (exit $ac_status); }; }; then
10321 echo "$as_me: failed program was:" >&5
10322 cat conftest.$ac_ext >&5
10323 cf_cv_posix_c_source=no
10325 rm -f conftest.$ac_objext conftest.$ac_ext
10326 CFLAGS="$cf_save_CFLAGS"
10327 CPPFLAGS="$cf_save_CPPFLAGS"
10330 rm -f conftest.$ac_objext conftest.$ac_ext
10333 echo "$as_me:10333: result: $cf_cv_posix_c_source" >&5
10334 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
10336 if test "$cf_cv_posix_c_source" != no ; then
10337 CFLAGS="$cf_trim_CFLAGS"
10338 CPPFLAGS="$cf_trim_CPPFLAGS"
10343 cf_new_extra_cppflags=
10345 for cf_add_cflags in $cf_cv_posix_c_source
10347 case $cf_fix_cppflags in
10349 case $cf_add_cflags in
10350 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
10351 case $cf_add_cflags in
10353 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10355 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10356 && test -z "${cf_tst_cflags}" \
10357 && cf_fix_cppflags=yes
10359 if test $cf_fix_cppflags = yes ; then
10361 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10362 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10365 elif test "${cf_tst_cflags}" = "\"'" ; then
10367 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10368 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10374 case "$CPPFLAGS" in
10378 case $cf_add_cflags in
10380 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10382 CPPFLAGS=`echo "$CPPFLAGS" | \
10383 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10384 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10389 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
10390 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
10397 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
10398 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
10405 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10406 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10408 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10410 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10411 && test -z "${cf_tst_cflags}" \
10412 && cf_fix_cppflags=no
10417 if test -n "$cf_new_cflags" ; then
10419 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
10420 CFLAGS="${CFLAGS}$cf_new_cflags"
10424 if test -n "$cf_new_cppflags" ; then
10426 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
10427 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
10431 if test -n "$cf_new_extra_cppflags" ; then
10433 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
10434 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
10442 cf_xopen_source="-D_NETBSD_SOURCE" # setting _XOPEN_SOURCE breaks IPv6 for lynx on NetBSD 1.6, breaks xterm, is not needed for ncursesw
10445 # setting _XOPEN_SOURCE lower than 500 breaks g++ compile with wchar.h, needed for ncursesw
10446 cf_xopen_source="-D_BSD_SOURCE"
10447 cf_XOPEN_SOURCE=600
10450 # setting _XOPEN_SOURCE breaks xterm on OpenBSD 2.8, is not needed for ncursesw
10453 cf_xopen_source="-D_OSF_SOURCE"
10456 cf_xopen_source="-D_QNX_SOURCE"
10459 # setting _XOPEN_SOURCE breaks Lynx on SCO Unix / OpenServer
10462 cf_xopen_source="-D__EXTENSIONS__"
10463 cf_cv_xopen_source=broken
10465 (sysv4.2uw2.*) # Novell/SCO UnixWare 2.x (tested on 2.1.2)
10471 echo "$as_me:10471: checking if we should define _XOPEN_SOURCE" >&5
10472 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
10473 if test "${cf_cv_xopen_source+set}" = set; then
10474 echo $ECHO_N "(cached) $ECHO_C" >&6
10477 cat >conftest.$ac_ext <<_ACEOF
10478 #line 10478 "configure"
10479 #include "confdefs.h"
10481 #include <stdlib.h>
10482 #include <string.h>
10483 #include <sys/types.h>
10489 #ifndef _XOPEN_SOURCE
10496 rm -f conftest.$ac_objext
10497 if { (eval echo "$as_me:10497: \"$ac_compile\"") >&5
10498 (eval $ac_compile) 2>&5
10500 echo "$as_me:10500: \$? = $ac_status" >&5
10501 (exit $ac_status); } &&
10502 { ac_try='test -s conftest.$ac_objext'
10503 { (eval echo "$as_me:10503: \"$ac_try\"") >&5
10504 (eval $ac_try) 2>&5
10506 echo "$as_me:10506: \$? = $ac_status" >&5
10507 (exit $ac_status); }; }; then
10508 cf_cv_xopen_source=no
10510 echo "$as_me: failed program was:" >&5
10511 cat conftest.$ac_ext >&5
10512 cf_save="$CPPFLAGS"
10513 CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
10514 cat >conftest.$ac_ext <<_ACEOF
10515 #line 10515 "configure"
10516 #include "confdefs.h"
10518 #include <stdlib.h>
10519 #include <string.h>
10520 #include <sys/types.h>
10526 #ifdef _XOPEN_SOURCE
10533 rm -f conftest.$ac_objext
10534 if { (eval echo "$as_me:10534: \"$ac_compile\"") >&5
10535 (eval $ac_compile) 2>&5
10537 echo "$as_me:10537: \$? = $ac_status" >&5
10538 (exit $ac_status); } &&
10539 { ac_try='test -s conftest.$ac_objext'
10540 { (eval echo "$as_me:10540: \"$ac_try\"") >&5
10541 (eval $ac_try) 2>&5
10543 echo "$as_me:10543: \$? = $ac_status" >&5
10544 (exit $ac_status); }; }; then
10545 cf_cv_xopen_source=no
10547 echo "$as_me: failed program was:" >&5
10548 cat conftest.$ac_ext >&5
10549 cf_cv_xopen_source=$cf_XOPEN_SOURCE
10551 rm -f conftest.$ac_objext conftest.$ac_ext
10552 CPPFLAGS="$cf_save"
10555 rm -f conftest.$ac_objext conftest.$ac_ext
10558 echo "$as_me:10558: result: $cf_cv_xopen_source" >&5
10559 echo "${ECHO_T}$cf_cv_xopen_source" >&6
10561 if test "$cf_cv_xopen_source" != no ; then
10563 CFLAGS=`echo "$CFLAGS" | \
10564 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
10565 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
10567 CPPFLAGS=`echo "$CPPFLAGS" | \
10568 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
10569 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
10571 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
10576 cf_new_extra_cppflags=
10578 for cf_add_cflags in $cf_temp_xopen_source
10580 case $cf_fix_cppflags in
10582 case $cf_add_cflags in
10583 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
10584 case $cf_add_cflags in
10586 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10588 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10589 && test -z "${cf_tst_cflags}" \
10590 && cf_fix_cppflags=yes
10592 if test $cf_fix_cppflags = yes ; then
10594 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10595 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10598 elif test "${cf_tst_cflags}" = "\"'" ; then
10600 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10601 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10607 case "$CPPFLAGS" in
10611 case $cf_add_cflags in
10613 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10615 CPPFLAGS=`echo "$CPPFLAGS" | \
10616 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10617 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10622 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
10623 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
10630 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
10631 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
10638 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10639 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10641 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10643 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10644 && test -z "${cf_tst_cflags}" \
10645 && cf_fix_cppflags=no
10650 if test -n "$cf_new_cflags" ; then
10652 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
10653 CFLAGS="${CFLAGS}$cf_new_cflags"
10657 if test -n "$cf_new_cppflags" ; then
10659 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
10660 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
10664 if test -n "$cf_new_extra_cppflags" ; then
10666 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
10667 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
10673 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
10675 cf_save_CFLAGS="$CFLAGS"
10676 cf_save_CPPFLAGS="$CPPFLAGS"
10678 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
10679 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
10680 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
10682 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
10683 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
10684 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
10686 echo "$as_me:10686: checking if we should define _POSIX_C_SOURCE" >&5
10687 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
10688 if test "${cf_cv_posix_c_source+set}" = set; then
10689 echo $ECHO_N "(cached) $ECHO_C" >&6
10692 echo "${as_me:-configure}:10692: testing if the symbol is already defined go no further ..." 1>&5
10694 cat >conftest.$ac_ext <<_ACEOF
10695 #line 10695 "configure"
10696 #include "confdefs.h"
10697 #include <sys/types.h>
10702 #ifndef _POSIX_C_SOURCE
10709 rm -f conftest.$ac_objext
10710 if { (eval echo "$as_me:10710: \"$ac_compile\"") >&5
10711 (eval $ac_compile) 2>&5
10713 echo "$as_me:10713: \$? = $ac_status" >&5
10714 (exit $ac_status); } &&
10715 { ac_try='test -s conftest.$ac_objext'
10716 { (eval echo "$as_me:10716: \"$ac_try\"") >&5
10717 (eval $ac_try) 2>&5
10719 echo "$as_me:10719: \$? = $ac_status" >&5
10720 (exit $ac_status); }; }; then
10721 cf_cv_posix_c_source=no
10723 echo "$as_me: failed program was:" >&5
10724 cat conftest.$ac_ext >&5
10725 cf_want_posix_source=no
10726 case .$cf_POSIX_C_SOURCE in
10728 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
10731 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
10732 cf_want_posix_source=yes
10735 cf_want_posix_source=yes
10738 if test "$cf_want_posix_source" = yes ; then
10739 cat >conftest.$ac_ext <<_ACEOF
10740 #line 10740 "configure"
10741 #include "confdefs.h"
10742 #include <sys/types.h>
10747 #ifdef _POSIX_SOURCE
10754 rm -f conftest.$ac_objext
10755 if { (eval echo "$as_me:10755: \"$ac_compile\"") >&5
10756 (eval $ac_compile) 2>&5
10758 echo "$as_me:10758: \$? = $ac_status" >&5
10759 (exit $ac_status); } &&
10760 { ac_try='test -s conftest.$ac_objext'
10761 { (eval echo "$as_me:10761: \"$ac_try\"") >&5
10762 (eval $ac_try) 2>&5
10764 echo "$as_me:10764: \$? = $ac_status" >&5
10765 (exit $ac_status); }; }; then
10768 echo "$as_me: failed program was:" >&5
10769 cat conftest.$ac_ext >&5
10770 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
10772 rm -f conftest.$ac_objext conftest.$ac_ext
10775 echo "${as_me:-configure}:10775: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
10777 CFLAGS="$cf_trim_CFLAGS"
10778 CPPFLAGS="$cf_trim_CPPFLAGS $cf_cv_posix_c_source"
10780 echo "${as_me:-configure}:10780: testing if the second compile does not leave our definition intact error ..." 1>&5
10782 cat >conftest.$ac_ext <<_ACEOF
10783 #line 10783 "configure"
10784 #include "confdefs.h"
10785 #include <sys/types.h>
10790 #ifndef _POSIX_C_SOURCE
10797 rm -f conftest.$ac_objext
10798 if { (eval echo "$as_me:10798: \"$ac_compile\"") >&5
10799 (eval $ac_compile) 2>&5
10801 echo "$as_me:10801: \$? = $ac_status" >&5
10802 (exit $ac_status); } &&
10803 { ac_try='test -s conftest.$ac_objext'
10804 { (eval echo "$as_me:10804: \"$ac_try\"") >&5
10805 (eval $ac_try) 2>&5
10807 echo "$as_me:10807: \$? = $ac_status" >&5
10808 (exit $ac_status); }; }; then
10811 echo "$as_me: failed program was:" >&5
10812 cat conftest.$ac_ext >&5
10813 cf_cv_posix_c_source=no
10815 rm -f conftest.$ac_objext conftest.$ac_ext
10816 CFLAGS="$cf_save_CFLAGS"
10817 CPPFLAGS="$cf_save_CPPFLAGS"
10820 rm -f conftest.$ac_objext conftest.$ac_ext
10823 echo "$as_me:10823: result: $cf_cv_posix_c_source" >&5
10824 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
10826 if test "$cf_cv_posix_c_source" != no ; then
10827 CFLAGS="$cf_trim_CFLAGS"
10828 CPPFLAGS="$cf_trim_CPPFLAGS"
10833 cf_new_extra_cppflags=
10835 for cf_add_cflags in $cf_cv_posix_c_source
10837 case $cf_fix_cppflags in
10839 case $cf_add_cflags in
10840 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
10841 case $cf_add_cflags in
10843 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10845 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10846 && test -z "${cf_tst_cflags}" \
10847 && cf_fix_cppflags=yes
10849 if test $cf_fix_cppflags = yes ; then
10851 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10852 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10855 elif test "${cf_tst_cflags}" = "\"'" ; then
10857 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10858 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10864 case "$CPPFLAGS" in
10868 case $cf_add_cflags in
10870 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10872 CPPFLAGS=`echo "$CPPFLAGS" | \
10873 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10874 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10879 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
10880 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
10887 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
10888 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
10895 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10896 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10898 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10900 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10901 && test -z "${cf_tst_cflags}" \
10902 && cf_fix_cppflags=no
10907 if test -n "$cf_new_cflags" ; then
10909 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
10910 CFLAGS="${CFLAGS}$cf_new_cflags"
10914 if test -n "$cf_new_cppflags" ; then
10916 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
10917 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
10921 if test -n "$cf_new_extra_cppflags" ; then
10923 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
10924 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
10933 if test -n "$cf_xopen_source" ; then
10938 cf_new_extra_cppflags=
10940 for cf_add_cflags in $cf_xopen_source
10942 case $cf_fix_cppflags in
10944 case $cf_add_cflags in
10945 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
10946 case $cf_add_cflags in
10948 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10950 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10951 && test -z "${cf_tst_cflags}" \
10952 && cf_fix_cppflags=yes
10954 if test $cf_fix_cppflags = yes ; then
10956 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10957 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10960 elif test "${cf_tst_cflags}" = "\"'" ; then
10962 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10963 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10969 case "$CPPFLAGS" in
10973 case $cf_add_cflags in
10975 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10977 CPPFLAGS=`echo "$CPPFLAGS" | \
10978 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10979 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10984 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
10985 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
10992 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
10993 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
11000 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11001 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11003 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11005 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
11006 && test -z "${cf_tst_cflags}" \
11007 && cf_fix_cppflags=no
11012 if test -n "$cf_new_cflags" ; then
11013 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
11015 echo "${as_me:-configure}:11015: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
11017 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
11018 CFLAGS="${CFLAGS}$cf_new_cflags"
11022 if test -n "$cf_new_cppflags" ; then
11023 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
11025 echo "${as_me:-configure}:11025: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
11027 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
11028 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
11032 if test -n "$cf_new_extra_cppflags" ; then
11033 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
11035 echo "${as_me:-configure}:11035: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
11037 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
11038 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
11044 if test -n "$cf_XOPEN_SOURCE" && test -z "$cf_cv_xopen_source" ; then
11045 echo "$as_me:11045: checking if _XOPEN_SOURCE really is set" >&5
11046 echo $ECHO_N "checking if _XOPEN_SOURCE really is set... $ECHO_C" >&6
11047 cat >conftest.$ac_ext <<_ACEOF
11048 #line 11048 "configure"
11049 #include "confdefs.h"
11050 #include <stdlib.h>
11055 #ifndef _XOPEN_SOURCE
11062 rm -f conftest.$ac_objext
11063 if { (eval echo "$as_me:11063: \"$ac_compile\"") >&5
11064 (eval $ac_compile) 2>&5
11066 echo "$as_me:11066: \$? = $ac_status" >&5
11067 (exit $ac_status); } &&
11068 { ac_try='test -s conftest.$ac_objext'
11069 { (eval echo "$as_me:11069: \"$ac_try\"") >&5
11070 (eval $ac_try) 2>&5
11072 echo "$as_me:11072: \$? = $ac_status" >&5
11073 (exit $ac_status); }; }; then
11074 cf_XOPEN_SOURCE_set=yes
11076 echo "$as_me: failed program was:" >&5
11077 cat conftest.$ac_ext >&5
11078 cf_XOPEN_SOURCE_set=no
11080 rm -f conftest.$ac_objext conftest.$ac_ext
11081 echo "$as_me:11081: result: $cf_XOPEN_SOURCE_set" >&5
11082 echo "${ECHO_T}$cf_XOPEN_SOURCE_set" >&6
11083 if test $cf_XOPEN_SOURCE_set = yes
11085 cat >conftest.$ac_ext <<_ACEOF
11086 #line 11086 "configure"
11087 #include "confdefs.h"
11088 #include <stdlib.h>
11093 #if (_XOPEN_SOURCE - 0) < $cf_XOPEN_SOURCE
11100 rm -f conftest.$ac_objext
11101 if { (eval echo "$as_me:11101: \"$ac_compile\"") >&5
11102 (eval $ac_compile) 2>&5
11104 echo "$as_me:11104: \$? = $ac_status" >&5
11105 (exit $ac_status); } &&
11106 { ac_try='test -s conftest.$ac_objext'
11107 { (eval echo "$as_me:11107: \"$ac_try\"") >&5
11108 (eval $ac_try) 2>&5
11110 echo "$as_me:11110: \$? = $ac_status" >&5
11111 (exit $ac_status); }; }; then
11112 cf_XOPEN_SOURCE_set_ok=yes
11114 echo "$as_me: failed program was:" >&5
11115 cat conftest.$ac_ext >&5
11116 cf_XOPEN_SOURCE_set_ok=no
11118 rm -f conftest.$ac_objext conftest.$ac_ext
11119 if test $cf_XOPEN_SOURCE_set_ok = no
11121 { echo "$as_me:11121: WARNING: _XOPEN_SOURCE is lower than requested" >&5
11122 echo "$as_me: WARNING: _XOPEN_SOURCE is lower than requested" >&2;}
11126 echo "$as_me:11126: checking if we should define _XOPEN_SOURCE" >&5
11127 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
11128 if test "${cf_cv_xopen_source+set}" = set; then
11129 echo $ECHO_N "(cached) $ECHO_C" >&6
11132 cat >conftest.$ac_ext <<_ACEOF
11133 #line 11133 "configure"
11134 #include "confdefs.h"
11136 #include <stdlib.h>
11137 #include <string.h>
11138 #include <sys/types.h>
11144 #ifndef _XOPEN_SOURCE
11151 rm -f conftest.$ac_objext
11152 if { (eval echo "$as_me:11152: \"$ac_compile\"") >&5
11153 (eval $ac_compile) 2>&5
11155 echo "$as_me:11155: \$? = $ac_status" >&5
11156 (exit $ac_status); } &&
11157 { ac_try='test -s conftest.$ac_objext'
11158 { (eval echo "$as_me:11158: \"$ac_try\"") >&5
11159 (eval $ac_try) 2>&5
11161 echo "$as_me:11161: \$? = $ac_status" >&5
11162 (exit $ac_status); }; }; then
11163 cf_cv_xopen_source=no
11165 echo "$as_me: failed program was:" >&5
11166 cat conftest.$ac_ext >&5
11167 cf_save="$CPPFLAGS"
11168 CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
11169 cat >conftest.$ac_ext <<_ACEOF
11170 #line 11170 "configure"
11171 #include "confdefs.h"
11173 #include <stdlib.h>
11174 #include <string.h>
11175 #include <sys/types.h>
11181 #ifdef _XOPEN_SOURCE
11188 rm -f conftest.$ac_objext
11189 if { (eval echo "$as_me:11189: \"$ac_compile\"") >&5
11190 (eval $ac_compile) 2>&5
11192 echo "$as_me:11192: \$? = $ac_status" >&5
11193 (exit $ac_status); } &&
11194 { ac_try='test -s conftest.$ac_objext'
11195 { (eval echo "$as_me:11195: \"$ac_try\"") >&5
11196 (eval $ac_try) 2>&5
11198 echo "$as_me:11198: \$? = $ac_status" >&5
11199 (exit $ac_status); }; }; then
11200 cf_cv_xopen_source=no
11202 echo "$as_me: failed program was:" >&5
11203 cat conftest.$ac_ext >&5
11204 cf_cv_xopen_source=$cf_XOPEN_SOURCE
11206 rm -f conftest.$ac_objext conftest.$ac_ext
11207 CPPFLAGS="$cf_save"
11210 rm -f conftest.$ac_objext conftest.$ac_ext
11213 echo "$as_me:11213: result: $cf_cv_xopen_source" >&5
11214 echo "${ECHO_T}$cf_cv_xopen_source" >&6
11216 if test "$cf_cv_xopen_source" != no ; then
11218 CFLAGS=`echo "$CFLAGS" | \
11219 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
11220 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
11222 CPPFLAGS=`echo "$CPPFLAGS" | \
11223 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
11224 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
11226 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
11231 cf_new_extra_cppflags=
11233 for cf_add_cflags in $cf_temp_xopen_source
11235 case $cf_fix_cppflags in
11237 case $cf_add_cflags in
11238 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
11239 case $cf_add_cflags in
11241 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11243 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
11244 && test -z "${cf_tst_cflags}" \
11245 && cf_fix_cppflags=yes
11247 if test $cf_fix_cppflags = yes ; then
11249 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11250 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11253 elif test "${cf_tst_cflags}" = "\"'" ; then
11255 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11256 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11262 case "$CPPFLAGS" in
11266 case $cf_add_cflags in
11268 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11270 CPPFLAGS=`echo "$CPPFLAGS" | \
11271 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11272 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11277 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
11278 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
11285 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
11286 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
11293 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11294 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11296 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11298 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
11299 && test -z "${cf_tst_cflags}" \
11300 && cf_fix_cppflags=no
11305 if test -n "$cf_new_cflags" ; then
11307 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
11308 CFLAGS="${CFLAGS}$cf_new_cflags"
11312 if test -n "$cf_new_cppflags" ; then
11314 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
11315 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
11319 if test -n "$cf_new_extra_cppflags" ; then
11321 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
11322 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
11331 # Check whether --enable-largefile or --disable-largefile was given.
11332 if test "${enable_largefile+set}" = set; then
11333 enableval="$enable_largefile"
11336 if test "$enable_largefile" != no; then
11338 echo "$as_me:11338: checking for special C compiler options needed for large files" >&5
11339 echo $ECHO_N "checking for special C compiler options needed for large files... $ECHO_C" >&6
11340 if test "${ac_cv_sys_largefile_CC+set}" = set; then
11341 echo $ECHO_N "(cached) $ECHO_C" >&6
11343 ac_cv_sys_largefile_CC=no
11344 if test "$GCC" != yes; then
11347 # IRIX 6.2 and later do not support large files by default,
11348 # so use the C compiler's -n32 option if that helps.
11349 cat >conftest.$ac_ext <<_ACEOF
11350 #line 11350 "configure"
11351 #include "confdefs.h"
11352 #include <sys/types.h>
11353 /* Check that off_t can represent 2**63 - 1 correctly.
11354 We can't simply define LARGE_OFF_T to be 9223372036854775807,
11355 since some C++ compilers masquerading as C compilers
11356 incorrectly reject 9223372036854775807. */
11357 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
11358 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
11359 && LARGE_OFF_T % 2147483647 == 1)
11369 rm -f conftest.$ac_objext
11370 if { (eval echo "$as_me:11370: \"$ac_compile\"") >&5
11371 (eval $ac_compile) 2>&5
11373 echo "$as_me:11373: \$? = $ac_status" >&5
11374 (exit $ac_status); } &&
11375 { ac_try='test -s conftest.$ac_objext'
11376 { (eval echo "$as_me:11376: \"$ac_try\"") >&5
11377 (eval $ac_try) 2>&5
11379 echo "$as_me:11379: \$? = $ac_status" >&5
11380 (exit $ac_status); }; }; then
11383 echo "$as_me: failed program was:" >&5
11384 cat conftest.$ac_ext >&5
11386 rm -f conftest.$ac_objext
11388 rm -f conftest.$ac_objext
11389 if { (eval echo "$as_me:11389: \"$ac_compile\"") >&5
11390 (eval $ac_compile) 2>&5
11392 echo "$as_me:11392: \$? = $ac_status" >&5
11393 (exit $ac_status); } &&
11394 { ac_try='test -s conftest.$ac_objext'
11395 { (eval echo "$as_me:11395: \"$ac_try\"") >&5
11396 (eval $ac_try) 2>&5
11398 echo "$as_me:11398: \$? = $ac_status" >&5
11399 (exit $ac_status); }; }; then
11400 ac_cv_sys_largefile_CC=' -n32'; break
11402 echo "$as_me: failed program was:" >&5
11403 cat conftest.$ac_ext >&5
11405 rm -f conftest.$ac_objext
11409 rm -f conftest.$ac_ext
11412 echo "$as_me:11412: result: $ac_cv_sys_largefile_CC" >&5
11413 echo "${ECHO_T}$ac_cv_sys_largefile_CC" >&6
11414 if test "$ac_cv_sys_largefile_CC" != no; then
11415 CC=$CC$ac_cv_sys_largefile_CC
11418 echo "$as_me:11418: checking for _FILE_OFFSET_BITS value needed for large files" >&5
11419 echo $ECHO_N "checking for _FILE_OFFSET_BITS value needed for large files... $ECHO_C" >&6
11420 if test "${ac_cv_sys_file_offset_bits+set}" = set; then
11421 echo $ECHO_N "(cached) $ECHO_C" >&6
11424 ac_cv_sys_file_offset_bits=no
11425 cat >conftest.$ac_ext <<_ACEOF
11426 #line 11426 "configure"
11427 #include "confdefs.h"
11428 #include <sys/types.h>
11429 /* Check that off_t can represent 2**63 - 1 correctly.
11430 We can't simply define LARGE_OFF_T to be 9223372036854775807,
11431 since some C++ compilers masquerading as C compilers
11432 incorrectly reject 9223372036854775807. */
11433 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
11434 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
11435 && LARGE_OFF_T % 2147483647 == 1)
11445 rm -f conftest.$ac_objext
11446 if { (eval echo "$as_me:11446: \"$ac_compile\"") >&5
11447 (eval $ac_compile) 2>&5
11449 echo "$as_me:11449: \$? = $ac_status" >&5
11450 (exit $ac_status); } &&
11451 { ac_try='test -s conftest.$ac_objext'
11452 { (eval echo "$as_me:11452: \"$ac_try\"") >&5
11453 (eval $ac_try) 2>&5
11455 echo "$as_me:11455: \$? = $ac_status" >&5
11456 (exit $ac_status); }; }; then
11459 echo "$as_me: failed program was:" >&5
11460 cat conftest.$ac_ext >&5
11462 rm -f conftest.$ac_objext conftest.$ac_ext
11463 cat >conftest.$ac_ext <<_ACEOF
11464 #line 11464 "configure"
11465 #include "confdefs.h"
11466 #define _FILE_OFFSET_BITS 64
11467 #include <sys/types.h>
11468 /* Check that off_t can represent 2**63 - 1 correctly.
11469 We can't simply define LARGE_OFF_T to be 9223372036854775807,
11470 since some C++ compilers masquerading as C compilers
11471 incorrectly reject 9223372036854775807. */
11472 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
11473 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
11474 && LARGE_OFF_T % 2147483647 == 1)
11484 rm -f conftest.$ac_objext
11485 if { (eval echo "$as_me:11485: \"$ac_compile\"") >&5
11486 (eval $ac_compile) 2>&5
11488 echo "$as_me:11488: \$? = $ac_status" >&5
11489 (exit $ac_status); } &&
11490 { ac_try='test -s conftest.$ac_objext'
11491 { (eval echo "$as_me:11491: \"$ac_try\"") >&5
11492 (eval $ac_try) 2>&5
11494 echo "$as_me:11494: \$? = $ac_status" >&5
11495 (exit $ac_status); }; }; then
11496 ac_cv_sys_file_offset_bits=64; break
11498 echo "$as_me: failed program was:" >&5
11499 cat conftest.$ac_ext >&5
11501 rm -f conftest.$ac_objext conftest.$ac_ext
11505 echo "$as_me:11505: result: $ac_cv_sys_file_offset_bits" >&5
11506 echo "${ECHO_T}$ac_cv_sys_file_offset_bits" >&6
11507 if test "$ac_cv_sys_file_offset_bits" != no; then
11509 cat >>confdefs.h <<EOF
11510 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
11515 echo "$as_me:11515: checking for _LARGE_FILES value needed for large files" >&5
11516 echo $ECHO_N "checking for _LARGE_FILES value needed for large files... $ECHO_C" >&6
11517 if test "${ac_cv_sys_large_files+set}" = set; then
11518 echo $ECHO_N "(cached) $ECHO_C" >&6
11521 ac_cv_sys_large_files=no
11522 cat >conftest.$ac_ext <<_ACEOF
11523 #line 11523 "configure"
11524 #include "confdefs.h"
11525 #include <sys/types.h>
11526 /* Check that off_t can represent 2**63 - 1 correctly.
11527 We can't simply define LARGE_OFF_T to be 9223372036854775807,
11528 since some C++ compilers masquerading as C compilers
11529 incorrectly reject 9223372036854775807. */
11530 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
11531 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
11532 && LARGE_OFF_T % 2147483647 == 1)
11542 rm -f conftest.$ac_objext
11543 if { (eval echo "$as_me:11543: \"$ac_compile\"") >&5
11544 (eval $ac_compile) 2>&5
11546 echo "$as_me:11546: \$? = $ac_status" >&5
11547 (exit $ac_status); } &&
11548 { ac_try='test -s conftest.$ac_objext'
11549 { (eval echo "$as_me:11549: \"$ac_try\"") >&5
11550 (eval $ac_try) 2>&5
11552 echo "$as_me:11552: \$? = $ac_status" >&5
11553 (exit $ac_status); }; }; then
11556 echo "$as_me: failed program was:" >&5
11557 cat conftest.$ac_ext >&5
11559 rm -f conftest.$ac_objext conftest.$ac_ext
11560 cat >conftest.$ac_ext <<_ACEOF
11561 #line 11561 "configure"
11562 #include "confdefs.h"
11563 #define _LARGE_FILES 1
11564 #include <sys/types.h>
11565 /* Check that off_t can represent 2**63 - 1 correctly.
11566 We can't simply define LARGE_OFF_T to be 9223372036854775807,
11567 since some C++ compilers masquerading as C compilers
11568 incorrectly reject 9223372036854775807. */
11569 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
11570 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
11571 && LARGE_OFF_T % 2147483647 == 1)
11581 rm -f conftest.$ac_objext
11582 if { (eval echo "$as_me:11582: \"$ac_compile\"") >&5
11583 (eval $ac_compile) 2>&5
11585 echo "$as_me:11585: \$? = $ac_status" >&5
11586 (exit $ac_status); } &&
11587 { ac_try='test -s conftest.$ac_objext'
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 ac_cv_sys_large_files=1; break
11595 echo "$as_me: failed program was:" >&5
11596 cat conftest.$ac_ext >&5
11598 rm -f conftest.$ac_objext conftest.$ac_ext
11602 echo "$as_me:11602: result: $ac_cv_sys_large_files" >&5
11603 echo "${ECHO_T}$ac_cv_sys_large_files" >&6
11604 if test "$ac_cv_sys_large_files" != no; then
11606 cat >>confdefs.h <<EOF
11607 #define _LARGE_FILES $ac_cv_sys_large_files
11614 if test "$enable_largefile" != no ; then
11615 echo "$as_me:11615: checking for _LARGEFILE_SOURCE value needed for large files" >&5
11616 echo $ECHO_N "checking for _LARGEFILE_SOURCE value needed for large files... $ECHO_C" >&6
11617 if test "${ac_cv_sys_largefile_source+set}" = set; then
11618 echo $ECHO_N "(cached) $ECHO_C" >&6
11621 ac_cv_sys_largefile_source=no
11622 cat >conftest.$ac_ext <<_ACEOF
11623 #line 11623 "configure"
11624 #include "confdefs.h"
11634 rm -f conftest.$ac_objext
11635 if { (eval echo "$as_me:11635: \"$ac_compile\"") >&5
11636 (eval $ac_compile) 2>&5
11638 echo "$as_me:11638: \$? = $ac_status" >&5
11639 (exit $ac_status); } &&
11640 { ac_try='test -s conftest.$ac_objext'
11641 { (eval echo "$as_me:11641: \"$ac_try\"") >&5
11642 (eval $ac_try) 2>&5
11644 echo "$as_me:11644: \$? = $ac_status" >&5
11645 (exit $ac_status); }; }; then
11648 echo "$as_me: failed program was:" >&5
11649 cat conftest.$ac_ext >&5
11651 rm -f conftest.$ac_objext conftest.$ac_ext
11652 cat >conftest.$ac_ext <<_ACEOF
11653 #line 11653 "configure"
11654 #include "confdefs.h"
11655 #define _LARGEFILE_SOURCE 1
11665 rm -f conftest.$ac_objext
11666 if { (eval echo "$as_me:11666: \"$ac_compile\"") >&5
11667 (eval $ac_compile) 2>&5
11669 echo "$as_me:11669: \$? = $ac_status" >&5
11670 (exit $ac_status); } &&
11671 { ac_try='test -s conftest.$ac_objext'
11672 { (eval echo "$as_me:11672: \"$ac_try\"") >&5
11673 (eval $ac_try) 2>&5
11675 echo "$as_me:11675: \$? = $ac_status" >&5
11676 (exit $ac_status); }; }; then
11677 ac_cv_sys_largefile_source=1; break
11679 echo "$as_me: failed program was:" >&5
11680 cat conftest.$ac_ext >&5
11682 rm -f conftest.$ac_objext conftest.$ac_ext
11686 echo "$as_me:11686: result: $ac_cv_sys_largefile_source" >&5
11687 echo "${ECHO_T}$ac_cv_sys_largefile_source" >&6
11688 if test "$ac_cv_sys_largefile_source" != no; then
11690 cat >>confdefs.h <<EOF
11691 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
11697 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
11698 # in glibc 2.1.3, but that breaks too many other things.
11699 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
11700 echo "$as_me:11700: checking for fseeko" >&5
11701 echo $ECHO_N "checking for fseeko... $ECHO_C" >&6
11702 if test "${ac_cv_func_fseeko+set}" = set; then
11703 echo $ECHO_N "(cached) $ECHO_C" >&6
11705 cat >conftest.$ac_ext <<_ACEOF
11706 #line 11706 "configure"
11707 #include "confdefs.h"
11712 return fseeko && fseeko (stdin, 0, 0);
11717 rm -f conftest.$ac_objext conftest$ac_exeext
11718 if { (eval echo "$as_me:11718: \"$ac_link\"") >&5
11719 (eval $ac_link) 2>&5
11721 echo "$as_me:11721: \$? = $ac_status" >&5
11722 (exit $ac_status); } &&
11723 { ac_try='test -s conftest$ac_exeext'
11724 { (eval echo "$as_me:11724: \"$ac_try\"") >&5
11725 (eval $ac_try) 2>&5
11727 echo "$as_me:11727: \$? = $ac_status" >&5
11728 (exit $ac_status); }; }; then
11729 ac_cv_func_fseeko=yes
11731 echo "$as_me: failed program was:" >&5
11732 cat conftest.$ac_ext >&5
11733 ac_cv_func_fseeko=no
11735 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11737 echo "$as_me:11737: result: $ac_cv_func_fseeko" >&5
11738 echo "${ECHO_T}$ac_cv_func_fseeko" >&6
11739 if test $ac_cv_func_fseeko = yes; then
11741 cat >>confdefs.h <<\EOF
11742 #define HAVE_FSEEKO 1
11747 # Normally we would collect these definitions in the config.h,
11748 # but (like _XOPEN_SOURCE), some environments rely on having these
11749 # defined before any of the system headers are included. Another
11750 # case comes up with C++, e.g., on AIX the compiler compiles the
11751 # header files by themselves before looking at the body files it is
11752 # told to compile. For ncurses, those header files do not include
11754 test "$ac_cv_sys_large_files" != no && CPPFLAGS="$CPPFLAGS -D_LARGE_FILES "
11755 test "$ac_cv_sys_largefile_source" != no && CPPFLAGS="$CPPFLAGS -D_LARGEFILE_SOURCE "
11756 test "$ac_cv_sys_file_offset_bits" != no && CPPFLAGS="$CPPFLAGS -D_FILE_OFFSET_BITS=$ac_cv_sys_file_offset_bits "
11758 echo "$as_me:11758: checking whether to use struct dirent64" >&5
11759 echo $ECHO_N "checking whether to use struct dirent64... $ECHO_C" >&6
11760 if test "${cf_cv_struct_dirent64+set}" = set; then
11761 echo $ECHO_N "(cached) $ECHO_C" >&6
11764 cat >conftest.$ac_ext <<_ACEOF
11765 #line 11765 "configure"
11766 #include "confdefs.h"
11768 #pragma GCC diagnostic error "-Wincompatible-pointer-types"
11769 #include <sys/types.h>
11770 #include <dirent.h>
11776 /* if transitional largefile support is setup, this is true */
11777 extern struct dirent64 * readdir(DIR *);
11778 struct dirent64 *x = readdir((DIR *)0);
11779 struct dirent *y = readdir((DIR *)0);
11786 rm -f conftest.$ac_objext
11787 if { (eval echo "$as_me:11787: \"$ac_compile\"") >&5
11788 (eval $ac_compile) 2>&5
11790 echo "$as_me:11790: \$? = $ac_status" >&5
11791 (exit $ac_status); } &&
11792 { ac_try='test -s conftest.$ac_objext'
11793 { (eval echo "$as_me:11793: \"$ac_try\"") >&5
11794 (eval $ac_try) 2>&5
11796 echo "$as_me:11796: \$? = $ac_status" >&5
11797 (exit $ac_status); }; }; then
11798 cf_cv_struct_dirent64=yes
11800 echo "$as_me: failed program was:" >&5
11801 cat conftest.$ac_ext >&5
11802 cf_cv_struct_dirent64=no
11804 rm -f conftest.$ac_objext conftest.$ac_ext
11807 echo "$as_me:11807: result: $cf_cv_struct_dirent64" >&5
11808 echo "${ECHO_T}$cf_cv_struct_dirent64" >&6
11809 test "$cf_cv_struct_dirent64" = yes &&
11810 cat >>confdefs.h <<\EOF
11811 #define HAVE_STRUCT_DIRENT64 1
11816 ### Enable compiling-in rcs id's
11817 echo "$as_me:11817: checking if RCS identifiers should be compiled-in" >&5
11818 echo $ECHO_N "checking if RCS identifiers should be compiled-in... $ECHO_C" >&6
11820 # Check whether --with-rcs-ids or --without-rcs-ids was given.
11821 if test "${with_rcs_ids+set}" = set; then
11822 withval="$with_rcs_ids"
11823 with_rcs_ids=$withval
11827 echo "$as_me:11827: result: $with_rcs_ids" >&5
11828 echo "${ECHO_T}$with_rcs_ids" >&6
11829 test "$with_rcs_ids" = yes &&
11830 cat >>confdefs.h <<\EOF
11831 #define USE_RCS_IDS 1
11834 ###############################################################################
11836 ### Note that some functions (such as const) are normally disabled anyway.
11837 echo "$as_me:11837: checking if you want to build with function extensions" >&5
11838 echo $ECHO_N "checking if you want to build with function extensions... $ECHO_C" >&6
11840 # Check whether --enable-ext-funcs or --disable-ext-funcs was given.
11841 if test "${enable_ext_funcs+set}" = set; then
11842 enableval="$enable_ext_funcs"
11843 with_ext_funcs=$enableval
11847 echo "$as_me:11847: result: $with_ext_funcs" >&5
11848 echo "${ECHO_T}$with_ext_funcs" >&6
11849 if test "$with_ext_funcs" = yes ; then
11850 NCURSES_EXT_FUNCS=1
11852 cat >>confdefs.h <<\EOF
11853 #define HAVE_USE_DEFAULT_COLORS 1
11856 cat >>confdefs.h <<\EOF
11857 #define NCURSES_EXT_FUNCS 1
11861 NCURSES_EXT_FUNCS=0
11864 ### use option --enable-const to turn on use of const beyond that in XSI.
11865 echo "$as_me:11865: checking for extended use of const keyword" >&5
11866 echo $ECHO_N "checking for extended use of const keyword... $ECHO_C" >&6
11868 # Check whether --enable-const or --disable-const was given.
11869 if test "${enable_const+set}" = set; then
11870 enableval="$enable_const"
11871 with_ext_const=$enableval
11875 echo "$as_me:11875: result: $with_ext_const" >&5
11876 echo "${ECHO_T}$with_ext_const" >&6
11877 NCURSES_CONST='/*nothing*/'
11878 if test "$with_ext_const" = yes ; then
11879 NCURSES_CONST=const
11882 ###############################################################################
11883 # These options are relatively safe to experiment with.
11885 echo "$as_me:11885: checking if you want all development code" >&5
11886 echo $ECHO_N "checking if you want all development code... $ECHO_C" >&6
11888 # Check whether --with-develop or --without-develop was given.
11889 if test "${with_develop+set}" = set; then
11890 withval="$with_develop"
11891 with_develop=$withval
11895 echo "$as_me:11895: result: $with_develop" >&5
11896 echo "${ECHO_T}$with_develop" >&6
11898 ###############################################################################
11899 # These are just experimental, probably should not be in a package:
11901 # This is still experimental (20080329), but should ultimately be moved to
11902 # the script-block --with-normal, etc.
11904 echo "$as_me:11904: checking if you want to link with the pthread library" >&5
11905 echo $ECHO_N "checking if you want to link with the pthread library... $ECHO_C" >&6
11907 # Check whether --with-pthread or --without-pthread was given.
11908 if test "${with_pthread+set}" = set; then
11909 withval="$with_pthread"
11910 with_pthread=$withval
11914 echo "$as_me:11914: result: $with_pthread" >&5
11915 echo "${ECHO_T}$with_pthread" >&6
11917 if test "$with_pthread" != no ; then
11918 echo "$as_me:11918: checking for pthread.h" >&5
11919 echo $ECHO_N "checking for pthread.h... $ECHO_C" >&6
11920 if test "${ac_cv_header_pthread_h+set}" = set; then
11921 echo $ECHO_N "(cached) $ECHO_C" >&6
11923 cat >conftest.$ac_ext <<_ACEOF
11924 #line 11924 "configure"
11925 #include "confdefs.h"
11926 #include <pthread.h>
11928 if { (eval echo "$as_me:11928: \"$ac_cpp conftest.$ac_ext\"") >&5
11929 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11931 egrep -v '^ *\+' conftest.er1 >conftest.err
11933 cat conftest.err >&5
11934 echo "$as_me:11934: \$? = $ac_status" >&5
11935 (exit $ac_status); } >/dev/null; then
11936 if test -s conftest.err; then
11937 ac_cpp_err=$ac_c_preproc_warn_flag
11944 if test -z "$ac_cpp_err"; then
11945 ac_cv_header_pthread_h=yes
11947 echo "$as_me: failed program was:" >&5
11948 cat conftest.$ac_ext >&5
11949 ac_cv_header_pthread_h=no
11951 rm -f conftest.err conftest.$ac_ext
11953 echo "$as_me:11953: result: $ac_cv_header_pthread_h" >&5
11954 echo "${ECHO_T}$ac_cv_header_pthread_h" >&6
11955 if test $ac_cv_header_pthread_h = yes; then
11957 cat >>confdefs.h <<\EOF
11958 #define HAVE_PTHREADS_H 1
11961 for cf_lib_pthread in pthread c_r
11963 echo "$as_me:11963: checking if we can link with the $cf_lib_pthread library" >&5
11964 echo $ECHO_N "checking if we can link with the $cf_lib_pthread library... $ECHO_C" >&6
11965 cf_save_LIBS="$LIBS"
11967 cf_add_libs="-l$cf_lib_pthread"
11968 # Filter out duplicates - this happens with badly-designed ".pc" files...
11969 for cf_add_1lib in $LIBS
11971 for cf_add_2lib in $cf_add_libs
11973 if test "x$cf_add_1lib" = "x$cf_add_2lib"
11979 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
11981 LIBS="$cf_add_libs"
11983 cat >conftest.$ac_ext <<_ACEOF
11984 #line 11984 "configure"
11985 #include "confdefs.h"
11987 #include <pthread.h>
11993 int rc = pthread_create(0,0,0,0);
11994 int r2 = pthread_mutexattr_settype(0, 0);
12000 rm -f conftest.$ac_objext conftest$ac_exeext
12001 if { (eval echo "$as_me:12001: \"$ac_link\"") >&5
12002 (eval $ac_link) 2>&5
12004 echo "$as_me:12004: \$? = $ac_status" >&5
12005 (exit $ac_status); } &&
12006 { ac_try='test -s conftest$ac_exeext'
12007 { (eval echo "$as_me:12007: \"$ac_try\"") >&5
12008 (eval $ac_try) 2>&5
12010 echo "$as_me:12010: \$? = $ac_status" >&5
12011 (exit $ac_status); }; }; then
12014 echo "$as_me: failed program was:" >&5
12015 cat conftest.$ac_ext >&5
12018 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12019 LIBS="$cf_save_LIBS"
12020 echo "$as_me:12020: result: $with_pthread" >&5
12021 echo "${ECHO_T}$with_pthread" >&6
12022 test "$with_pthread" = yes && break
12025 if test "$with_pthread" = yes ; then
12027 cf_add_libs="-l$cf_lib_pthread"
12028 # Filter out duplicates - this happens with badly-designed ".pc" files...
12029 for cf_add_1lib in $LIBS
12031 for cf_add_2lib in $cf_add_libs
12033 if test "x$cf_add_1lib" = "x$cf_add_2lib"
12039 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
12041 LIBS="$cf_add_libs"
12043 cat >>confdefs.h <<\EOF
12044 #define HAVE_LIBPTHREADS 1
12048 { { echo "$as_me:12048: error: Cannot link with pthread library" >&5
12049 echo "$as_me: error: Cannot link with pthread library" >&2;}
12050 { (exit 1); exit 1; }; }
12057 echo "$as_me:12057: checking if you want to use weak-symbols for pthreads" >&5
12058 echo $ECHO_N "checking if you want to use weak-symbols for pthreads... $ECHO_C" >&6
12060 # Check whether --enable-weak-symbols or --disable-weak-symbols was given.
12061 if test "${enable_weak_symbols+set}" = set; then
12062 enableval="$enable_weak_symbols"
12063 use_weak_symbols=$withval
12065 use_weak_symbols=no
12067 echo "$as_me:12067: result: $use_weak_symbols" >&5
12068 echo "${ECHO_T}$use_weak_symbols" >&6
12069 if test "$use_weak_symbols" = yes ; then
12071 echo "$as_me:12071: checking if $CC supports weak symbols" >&5
12072 echo $ECHO_N "checking if $CC supports weak symbols... $ECHO_C" >&6
12073 if test "${cf_cv_weak_symbols+set}" = set; then
12074 echo $ECHO_N "(cached) $ECHO_C" >&6
12077 cat >conftest.$ac_ext <<_ACEOF
12078 #line 12078 "configure"
12079 #include "confdefs.h"
12086 #if defined(__GNUC__)
12087 # if defined __USE_ISOC99
12088 # define _cat_pragma(exp) _Pragma(#exp)
12089 # define _weak_pragma(exp) _cat_pragma(weak name)
12091 # define _weak_pragma(exp)
12093 # define _declare(name) __extension__ extern __typeof__(name) name
12094 # define weak_symbol(name) _weak_pragma(name) _declare(name) __attribute__((weak))
12097 weak_symbol(fopen);
12103 rm -f conftest.$ac_objext
12104 if { (eval echo "$as_me:12104: \"$ac_compile\"") >&5
12105 (eval $ac_compile) 2>&5
12107 echo "$as_me:12107: \$? = $ac_status" >&5
12108 (exit $ac_status); } &&
12109 { ac_try='test -s conftest.$ac_objext'
12110 { (eval echo "$as_me:12110: \"$ac_try\"") >&5
12111 (eval $ac_try) 2>&5
12113 echo "$as_me:12113: \$? = $ac_status" >&5
12114 (exit $ac_status); }; }; then
12115 cf_cv_weak_symbols=yes
12117 echo "$as_me: failed program was:" >&5
12118 cat conftest.$ac_ext >&5
12119 cf_cv_weak_symbols=no
12121 rm -f conftest.$ac_objext conftest.$ac_ext
12124 echo "$as_me:12124: result: $cf_cv_weak_symbols" >&5
12125 echo "${ECHO_T}$cf_cv_weak_symbols" >&6
12128 cf_cv_weak_symbols=no
12131 if test $cf_cv_weak_symbols = yes ; then
12133 cat >>confdefs.h <<\EOF
12134 #define USE_WEAK_SYMBOLS 1
12140 if test "$with_pthread" = "yes" ; then
12142 cat >>confdefs.h <<\EOF
12143 #define USE_PTHREADS 1
12146 enable_reentrant=yes
12147 if test $cf_cv_weak_symbols = yes ; then
12152 # OpenSUSE is installing ncurses6, using reentrant option.
12153 echo "$as_me:12153: checking for _nc_TABSIZE" >&5
12154 echo $ECHO_N "checking for _nc_TABSIZE... $ECHO_C" >&6
12155 if test "${ac_cv_func__nc_TABSIZE+set}" = set; then
12156 echo $ECHO_N "(cached) $ECHO_C" >&6
12158 cat >conftest.$ac_ext <<_ACEOF
12159 #line 12159 "configure"
12160 #include "confdefs.h"
12161 /* System header to define __stub macros and hopefully few prototypes,
12162 which can conflict with char _nc_TABSIZE (); below. */
12163 #include <assert.h>
12164 /* Override any gcc2 internal prototype to avoid an error. */
12168 /* We use char because int might match the return type of a gcc2
12169 builtin and then its argument prototype would still apply. */
12170 char _nc_TABSIZE ();
12176 /* The GNU C library defines this for functions which it implements
12177 to always fail with ENOSYS. Some functions are actually named
12178 something starting with __ and the normal name is an alias. */
12179 #if defined (__stub__nc_TABSIZE) || defined (__stub____nc_TABSIZE)
12182 f = _nc_TABSIZE; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
12189 rm -f conftest.$ac_objext conftest$ac_exeext
12190 if { (eval echo "$as_me:12190: \"$ac_link\"") >&5
12191 (eval $ac_link) 2>&5
12193 echo "$as_me:12193: \$? = $ac_status" >&5
12194 (exit $ac_status); } &&
12195 { ac_try='test -s conftest$ac_exeext'
12196 { (eval echo "$as_me:12196: \"$ac_try\"") >&5
12197 (eval $ac_try) 2>&5
12199 echo "$as_me:12199: \$? = $ac_status" >&5
12200 (exit $ac_status); }; }; then
12201 ac_cv_func__nc_TABSIZE=yes
12203 echo "$as_me: failed program was:" >&5
12204 cat conftest.$ac_ext >&5
12205 ac_cv_func__nc_TABSIZE=no
12207 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12209 echo "$as_me:12209: result: $ac_cv_func__nc_TABSIZE" >&5
12210 echo "${ECHO_T}$ac_cv_func__nc_TABSIZE" >&6
12211 if test $ac_cv_func__nc_TABSIZE = yes; then
12212 assume_reentrant=yes
12214 assume_reentrant=no
12217 # Reentrant code has to be opaque; there's little advantage to making ncurses
12218 # opaque outside of that, so there is no --enable-opaque option. We can use
12219 # this option without --with-pthreads, but this will be always set for
12221 echo "$as_me:12221: checking if you want experimental reentrant code" >&5
12222 echo $ECHO_N "checking if you want experimental reentrant code... $ECHO_C" >&6
12224 # Check whether --enable-reentrant or --disable-reentrant was given.
12225 if test "${enable_reentrant+set}" = set; then
12226 enableval="$enable_reentrant"
12227 with_reentrant=$enableval
12229 with_reentrant=$assume_reentrant
12231 echo "$as_me:12231: result: $with_reentrant" >&5
12232 echo "${ECHO_T}$with_reentrant" >&6
12233 if test "$with_reentrant" = yes ; then
12234 cf_cv_enable_reentrant=1
12235 if test $cf_cv_weak_symbols = yes ; then
12237 # remove pthread library from $LIBS
12238 LIBS=`echo "$LIBS" | sed -e 's/-lpthread[ ]//g' -e 's/-lpthread$//'`
12240 elif test "$assume_reentrant" = no ; then
12241 LIB_SUFFIX="t${LIB_SUFFIX}"
12244 cat >>confdefs.h <<\EOF
12245 #define USE_REENTRANT 1
12249 cf_cv_enable_reentrant=0
12252 ### Allow using a different wrap-prefix
12253 if test "$cf_cv_enable_reentrant" != 0 || test "$BROKEN_LINKER" = 1 ; then
12254 echo "$as_me:12254: checking for prefix used to wrap public variables" >&5
12255 echo $ECHO_N "checking for prefix used to wrap public variables... $ECHO_C" >&6
12257 # Check whether --with-wrap-prefix or --without-wrap-prefix was given.
12258 if test "${with_wrap_prefix+set}" = set; then
12259 withval="$with_wrap_prefix"
12260 NCURSES_WRAP_PREFIX=$withval
12262 NCURSES_WRAP_PREFIX=_nc_
12264 echo "$as_me:12264: result: $NCURSES_WRAP_PREFIX" >&5
12265 echo "${ECHO_T}$NCURSES_WRAP_PREFIX" >&6
12267 NCURSES_WRAP_PREFIX=_nc_
12270 cat >>confdefs.h <<EOF
12271 #define NCURSES_WRAP_PREFIX "$NCURSES_WRAP_PREFIX"
12274 ###############################################################################
12276 ### use option --disable-echo to suppress full display compiling commands
12278 echo "$as_me:12278: checking if you want to see long compiling messages" >&5
12279 echo $ECHO_N "checking if you want to see long compiling messages... $ECHO_C" >&6
12281 # Check whether --enable-echo or --disable-echo was given.
12282 if test "${enable_echo+set}" = set; then
12283 enableval="$enable_echo"
12284 test "$enableval" != no && enableval=yes
12285 if test "$enableval" != "yes" ; then
12288 ECHO_LD='@echo linking $@;'
12289 RULE_CC='@echo compiling $<'
12290 SHOW_CC='@echo compiling $@'
12312 echo "$as_me:12312: result: $enableval" >&5
12313 echo "${ECHO_T}$enableval" >&6
12315 ### use option --enable-warnings to turn on all gcc warnings
12316 echo "$as_me:12316: checking if you want to see compiler warnings" >&5
12317 echo $ECHO_N "checking if you want to see compiler warnings... $ECHO_C" >&6
12319 # Check whether --enable-warnings or --disable-warnings was given.
12320 if test "${enable_warnings+set}" = set; then
12321 enableval="$enable_warnings"
12322 with_warnings=$enableval
12324 echo "$as_me:12324: result: $with_warnings" >&5
12325 echo "${ECHO_T}$with_warnings" >&6
12327 if test "x$with_warnings" = "xyes"; then
12329 ADAFLAGS="$ADAFLAGS -gnatg"
12333 if test "$GCC" = yes ; then
12336 echo "$as_me:12336: checking if this is really Intel C compiler" >&5
12337 echo $ECHO_N "checking if this is really Intel C compiler... $ECHO_C" >&6
12338 cf_save_CFLAGS="$CFLAGS"
12339 CFLAGS="$CFLAGS -no-gcc"
12340 cat >conftest.$ac_ext <<_ACEOF
12341 #line 12341 "configure"
12342 #include "confdefs.h"
12348 #ifdef __INTEL_COMPILER
12357 rm -f conftest.$ac_objext
12358 if { (eval echo "$as_me:12358: \"$ac_compile\"") >&5
12359 (eval $ac_compile) 2>&5
12361 echo "$as_me:12361: \$? = $ac_status" >&5
12362 (exit $ac_status); } &&
12363 { ac_try='test -s conftest.$ac_objext'
12364 { (eval echo "$as_me:12364: \"$ac_try\"") >&5
12365 (eval $ac_try) 2>&5
12367 echo "$as_me:12367: \$? = $ac_status" >&5
12368 (exit $ac_status); }; }; then
12370 cf_save_CFLAGS="$cf_save_CFLAGS -we147"
12373 echo "$as_me: failed program was:" >&5
12374 cat conftest.$ac_ext >&5
12376 rm -f conftest.$ac_objext conftest.$ac_ext
12377 CFLAGS="$cf_save_CFLAGS"
12378 echo "$as_me:12378: result: $INTEL_COMPILER" >&5
12379 echo "${ECHO_T}$INTEL_COMPILER" >&6
12386 if test "$GCC" = yes ; then
12387 echo "$as_me:12387: checking if this is really Clang C compiler" >&5
12388 echo $ECHO_N "checking if this is really Clang C compiler... $ECHO_C" >&6
12389 cf_save_CFLAGS="$CFLAGS"
12390 CFLAGS="$CFLAGS -Qunused-arguments"
12391 cat >conftest.$ac_ext <<_ACEOF
12392 #line 12392 "configure"
12393 #include "confdefs.h"
12408 rm -f conftest.$ac_objext
12409 if { (eval echo "$as_me:12409: \"$ac_compile\"") >&5
12410 (eval $ac_compile) 2>&5
12412 echo "$as_me:12412: \$? = $ac_status" >&5
12413 (exit $ac_status); } &&
12414 { ac_try='test -s conftest.$ac_objext'
12415 { (eval echo "$as_me:12415: \"$ac_try\"") >&5
12416 (eval $ac_try) 2>&5
12418 echo "$as_me:12418: \$? = $ac_status" >&5
12419 (exit $ac_status); }; }; then
12421 cf_save_CFLAGS="$cf_save_CFLAGS -Qunused-arguments"
12424 echo "$as_me: failed program was:" >&5
12425 cat conftest.$ac_ext >&5
12427 rm -f conftest.$ac_objext conftest.$ac_ext
12428 CFLAGS="$cf_save_CFLAGS"
12429 echo "$as_me:12429: result: $CLANG_COMPILER" >&5
12430 echo "${ECHO_T}$CLANG_COMPILER" >&6
12433 cat > conftest.$ac_ext <<EOF
12434 #line 12434 "${as_me:-configure}"
12435 int main(int argc, char *argv[]) { return (argv[argc-1] == 0) ; }
12438 if test "$INTEL_COMPILER" = yes
12440 # The "-wdXXX" options suppress warnings:
12441 # remark #1419: external declaration in primary source file
12442 # remark #1683: explicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem)
12443 # remark #1684: conversion from pointer to same-sized integral type (potential portability problem)
12444 # remark #193: zero used for undefined preprocessing identifier
12445 # remark #593: variable "curs_sb_left_arrow" was set but never used
12446 # remark #810: conversion from "int" to "Dimension={unsigned short}" may lose significant bits
12447 # remark #869: parameter "tw" was never referenced
12448 # remark #981: operands are evaluated in unspecified order
12449 # warning #279: controlling expression is constant
12451 { echo "$as_me:12451: checking for $CC warning options..." >&5
12452 echo "$as_me: checking for $CC warning options..." >&6;}
12453 cf_save_CFLAGS="$CFLAGS"
12454 EXTRA_CFLAGS="-Wall"
12466 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
12467 if { (eval echo "$as_me:12467: \"$ac_compile\"") >&5
12468 (eval $ac_compile) 2>&5
12470 echo "$as_me:12470: \$? = $ac_status" >&5
12471 (exit $ac_status); }; then
12472 test -n "$verbose" && echo "$as_me:12472: result: ... -$cf_opt" >&5
12473 echo "${ECHO_T}... -$cf_opt" >&6
12474 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
12477 CFLAGS="$cf_save_CFLAGS"
12479 elif test "$GCC" = yes
12481 { echo "$as_me:12481: checking for $CC warning options..." >&5
12482 echo "$as_me: checking for $CC warning options..." >&6;}
12483 cf_save_CFLAGS="$CFLAGS"
12486 test "$with_ext_const" = yes && cf_warn_CONST="Wwrite-strings"
12487 cf_gcc_warnings="Wignored-qualifiers Wlogical-op Wvarargs"
12488 test "x$CLANG_COMPILER" = xyes && cf_gcc_warnings=
12489 for cf_opt in W Wall \
12490 Wbad-function-cast \
12493 Wdeclaration-after-statement \
12496 Wmissing-declarations \
12497 Wmissing-prototypes \
12501 Wstrict-prototypes \
12502 Wundef $cf_gcc_warnings $cf_warn_CONST Wno-unknown-pragmas Wswitch-enum
12504 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
12505 if { (eval echo "$as_me:12505: \"$ac_compile\"") >&5
12506 (eval $ac_compile) 2>&5
12508 echo "$as_me:12508: \$? = $ac_status" >&5
12509 (exit $ac_status); }; then
12510 test -n "$verbose" && echo "$as_me:12510: result: ... -$cf_opt" >&5
12511 echo "${ECHO_T}... -$cf_opt" >&6
12514 CPPFLAGS="$CPPFLAGS -DXTSTRINGDEFINES"
12517 case $GCC_VERSION in
12519 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
12521 echo "${as_me:-configure}:12521: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
12527 case $GCC_VERSION in
12529 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
12531 echo "${as_me:-configure}:12531: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
12537 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
12540 CFLAGS="$cf_save_CFLAGS"
12546 if test "$GCC" = yes
12548 cat > conftest.i <<EOF
12550 #define GCC_PRINTF 0
12553 #define GCC_SCANF 0
12555 #ifndef GCC_NORETURN
12556 #define GCC_NORETURN /* nothing */
12559 #define GCC_UNUSED /* nothing */
12562 if test "$GCC" = yes
12564 { echo "$as_me:12564: checking for $CC __attribute__ directives..." >&5
12565 echo "$as_me: checking for $CC __attribute__ directives..." >&6;}
12566 cat > conftest.$ac_ext <<EOF
12567 #line 12567 "${as_me:-configure}"
12568 #include "confdefs.h"
12569 #include "conftest.h"
12570 #include "conftest.i"
12572 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
12574 #define GCC_PRINTFLIKE(fmt,var) /*nothing*/
12577 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
12579 #define GCC_SCANFLIKE(fmt,var) /*nothing*/
12581 extern void wow(char *,...) GCC_SCANFLIKE(1,2);
12582 extern void oops(char *,...) GCC_PRINTFLIKE(1,2) GCC_NORETURN;
12583 extern void foo(void) GCC_NORETURN;
12584 int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { return 0; }
12586 cf_printf_attribute=no
12587 cf_scanf_attribute=no
12588 for cf_attribute in scanf printf unused noreturn
12591 cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
12593 cf_directive="__attribute__(($cf_attribute))"
12594 echo "checking for $CC $cf_directive" 1>&5
12596 case $cf_attribute in
12598 cf_printf_attribute=yes
12599 cat >conftest.h <<EOF
12600 #define GCC_$cf_ATTRIBUTE 1
12604 cf_scanf_attribute=yes
12605 cat >conftest.h <<EOF
12606 #define GCC_$cf_ATTRIBUTE 1
12610 cat >conftest.h <<EOF
12611 #define GCC_$cf_ATTRIBUTE $cf_directive
12616 if { (eval echo "$as_me:12616: \"$ac_compile\"") >&5
12617 (eval $ac_compile) 2>&5
12619 echo "$as_me:12619: \$? = $ac_status" >&5
12620 (exit $ac_status); }; then
12621 test -n "$verbose" && echo "$as_me:12621: result: ... $cf_attribute" >&5
12622 echo "${ECHO_T}... $cf_attribute" >&6
12623 cat conftest.h >>confdefs.h
12624 case $cf_attribute in
12627 cat >>confdefs.h <<EOF
12628 #define GCC_NORETURN $cf_directive
12633 cf_value='/* nothing */'
12634 if test "$cf_printf_attribute" != no ; then
12635 cf_value='__attribute__((format(printf,fmt,var)))'
12637 cat >>confdefs.h <<\EOF
12638 #define GCC_PRINTF 1
12643 cat >>confdefs.h <<EOF
12644 #define GCC_PRINTFLIKE(fmt,var) $cf_value
12649 cf_value='/* nothing */'
12650 if test "$cf_scanf_attribute" != no ; then
12651 cf_value='__attribute__((format(scanf,fmt,var)))'
12653 cat >>confdefs.h <<\EOF
12654 #define GCC_SCANF 1
12659 cat >>confdefs.h <<EOF
12660 #define GCC_SCANFLIKE(fmt,var) $cf_value
12666 cat >>confdefs.h <<EOF
12667 #define GCC_UNUSED $cf_directive
12675 fgrep define conftest.i >>confdefs.h
12680 ### use option --enable-assertions to turn on generation of assertion code
12681 echo "$as_me:12681: checking if you want to enable runtime assertions" >&5
12682 echo $ECHO_N "checking if you want to enable runtime assertions... $ECHO_C" >&6
12684 # Check whether --enable-assertions or --disable-assertions was given.
12685 if test "${enable_assertions+set}" = set; then
12686 enableval="$enable_assertions"
12687 with_assertions=$enableval
12691 echo "$as_me:12691: result: $with_assertions" >&5
12692 echo "${ECHO_T}$with_assertions" >&6
12695 if test "$with_assertions" = no
12697 CPPFLAGS="$CPPFLAGS -DNDEBUG"
12700 ADAFLAGS="$ADAFLAGS -gnata"
12705 ### use option --disable-leaks to suppress "permanent" leaks, for testing
12707 cat >>confdefs.h <<\EOF
12708 #define HAVE_NC_ALLOC_H 1
12711 ### use option --enable-expanded to generate certain macros as functions
12713 # Check whether --enable-expanded or --disable-expanded was given.
12714 if test "${enable_expanded+set}" = set; then
12715 enableval="$enable_expanded"
12716 test "$enableval" = yes &&
12717 cat >>confdefs.h <<\EOF
12718 #define NCURSES_EXPANDED 1
12723 ### use option --disable-macros to suppress macros in favor of functions
12725 # Check whether --enable-macros or --disable-macros was given.
12726 if test "${enable_macros+set}" = set; then
12727 enableval="$enable_macros"
12728 test "$enableval" = no &&
12729 cat >>confdefs.h <<\EOF
12730 #define NCURSES_NOMACROS 1
12735 # Normally we only add trace() to the debug-library. Allow this to be
12736 # extended to all models of the ncurses library:
12738 case "$CFLAGS $CPPFLAGS" in
12744 echo "$as_me:12744: checking whether to add trace feature to all models" >&5
12745 echo $ECHO_N "checking whether to add trace feature to all models... $ECHO_C" >&6
12747 # Check whether --with-trace or --without-trace was given.
12748 if test "${with_trace+set}" = set; then
12749 withval="$with_trace"
12750 cf_with_trace=$withval
12752 cf_with_trace=$cf_all_traces
12754 echo "$as_me:12754: result: $cf_with_trace" >&5
12755 echo "${ECHO_T}$cf_with_trace" >&6
12757 if test "$cf_with_trace" = yes ; then
12763 cf_new_extra_cppflags=
12765 for cf_add_cflags in -DTRACE
12767 case $cf_fix_cppflags in
12769 case $cf_add_cflags in
12770 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
12771 case $cf_add_cflags in
12773 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
12775 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12776 && test -z "${cf_tst_cflags}" \
12777 && cf_fix_cppflags=yes
12779 if test $cf_fix_cppflags = yes ; then
12781 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12782 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12785 elif test "${cf_tst_cflags}" = "\"'" ; then
12787 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12788 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12794 case "$CPPFLAGS" in
12798 case $cf_add_cflags in
12800 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12802 CPPFLAGS=`echo "$CPPFLAGS" | \
12803 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12804 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12809 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
12810 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
12817 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
12818 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
12825 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12826 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12828 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
12830 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12831 && test -z "${cf_tst_cflags}" \
12832 && cf_fix_cppflags=no
12837 if test -n "$cf_new_cflags" ; then
12839 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
12840 CFLAGS="${CFLAGS}$cf_new_cflags"
12844 if test -n "$cf_new_cppflags" ; then
12846 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
12847 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
12851 if test -n "$cf_new_extra_cppflags" ; then
12853 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
12854 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
12862 echo "$as_me:12862: checking if we want to use GNAT projects" >&5
12863 echo $ECHO_N "checking if we want to use GNAT projects... $ECHO_C" >&6
12865 # Check whether --enable-gnat-projects or --disable-gnat-projects was given.
12866 if test "${enable_gnat_projects+set}" = set; then
12867 enableval="$enable_gnat_projects"
12868 test "$enableval" != no && enableval=yes
12869 if test "$enableval" != "yes" ; then
12870 enable_gnat_projects=no
12872 enable_gnat_projects=yes
12876 enable_gnat_projects=yes
12879 echo "$as_me:12879: result: $enable_gnat_projects" >&5
12880 echo "${ECHO_T}$enable_gnat_projects" >&6
12882 ### Checks for libraries.
12883 case $cf_cv_system_name in
12887 echo "$as_me:12887: checking for gettimeofday" >&5
12888 echo $ECHO_N "checking for gettimeofday... $ECHO_C" >&6
12889 if test "${ac_cv_func_gettimeofday+set}" = set; then
12890 echo $ECHO_N "(cached) $ECHO_C" >&6
12892 cat >conftest.$ac_ext <<_ACEOF
12893 #line 12893 "configure"
12894 #include "confdefs.h"
12895 /* System header to define __stub macros and hopefully few prototypes,
12896 which can conflict with char gettimeofday (); below. */
12897 #include <assert.h>
12898 /* Override any gcc2 internal prototype to avoid an error. */
12902 /* We use char because int might match the return type of a gcc2
12903 builtin and then its argument prototype would still apply. */
12904 char gettimeofday ();
12910 /* The GNU C library defines this for functions which it implements
12911 to always fail with ENOSYS. Some functions are actually named
12912 something starting with __ and the normal name is an alias. */
12913 #if defined (__stub_gettimeofday) || defined (__stub___gettimeofday)
12916 f = gettimeofday; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
12923 rm -f conftest.$ac_objext conftest$ac_exeext
12924 if { (eval echo "$as_me:12924: \"$ac_link\"") >&5
12925 (eval $ac_link) 2>&5
12927 echo "$as_me:12927: \$? = $ac_status" >&5
12928 (exit $ac_status); } &&
12929 { ac_try='test -s conftest$ac_exeext'
12930 { (eval echo "$as_me:12930: \"$ac_try\"") >&5
12931 (eval $ac_try) 2>&5
12933 echo "$as_me:12933: \$? = $ac_status" >&5
12934 (exit $ac_status); }; }; then
12935 ac_cv_func_gettimeofday=yes
12937 echo "$as_me: failed program was:" >&5
12938 cat conftest.$ac_ext >&5
12939 ac_cv_func_gettimeofday=no
12941 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12943 echo "$as_me:12943: result: $ac_cv_func_gettimeofday" >&5
12944 echo "${ECHO_T}$ac_cv_func_gettimeofday" >&6
12945 if test $ac_cv_func_gettimeofday = yes; then
12946 cat >>confdefs.h <<\EOF
12947 #define HAVE_GETTIMEOFDAY 1
12952 echo "$as_me:12952: checking for gettimeofday in -lbsd" >&5
12953 echo $ECHO_N "checking for gettimeofday in -lbsd... $ECHO_C" >&6
12954 if test "${ac_cv_lib_bsd_gettimeofday+set}" = set; then
12955 echo $ECHO_N "(cached) $ECHO_C" >&6
12957 ac_check_lib_save_LIBS=$LIBS
12959 cat >conftest.$ac_ext <<_ACEOF
12960 #line 12960 "configure"
12961 #include "confdefs.h"
12963 /* Override any gcc2 internal prototype to avoid an error. */
12967 /* We use char because int might match the return type of a gcc2
12968 builtin and then its argument prototype would still apply. */
12969 char gettimeofday ();
12978 rm -f conftest.$ac_objext conftest$ac_exeext
12979 if { (eval echo "$as_me:12979: \"$ac_link\"") >&5
12980 (eval $ac_link) 2>&5
12982 echo "$as_me:12982: \$? = $ac_status" >&5
12983 (exit $ac_status); } &&
12984 { ac_try='test -s conftest$ac_exeext'
12985 { (eval echo "$as_me:12985: \"$ac_try\"") >&5
12986 (eval $ac_try) 2>&5
12988 echo "$as_me:12988: \$? = $ac_status" >&5
12989 (exit $ac_status); }; }; then
12990 ac_cv_lib_bsd_gettimeofday=yes
12992 echo "$as_me: failed program was:" >&5
12993 cat conftest.$ac_ext >&5
12994 ac_cv_lib_bsd_gettimeofday=no
12996 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12997 LIBS=$ac_check_lib_save_LIBS
12999 echo "$as_me:12999: result: $ac_cv_lib_bsd_gettimeofday" >&5
13000 echo "${ECHO_T}$ac_cv_lib_bsd_gettimeofday" >&6
13001 if test $ac_cv_lib_bsd_gettimeofday = yes; then
13003 cat >>confdefs.h <<\EOF
13004 #define HAVE_GETTIMEOFDAY 1
13014 ### Checks for header files.
13015 echo "$as_me:13015: checking for ANSI C header files" >&5
13016 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
13017 if test "${ac_cv_header_stdc+set}" = set; then
13018 echo $ECHO_N "(cached) $ECHO_C" >&6
13020 cat >conftest.$ac_ext <<_ACEOF
13021 #line 13021 "configure"
13022 #include "confdefs.h"
13023 #include <stdlib.h>
13024 #include <stdarg.h>
13025 #include <string.h>
13029 if { (eval echo "$as_me:13029: \"$ac_cpp conftest.$ac_ext\"") >&5
13030 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13032 egrep -v '^ *\+' conftest.er1 >conftest.err
13034 cat conftest.err >&5
13035 echo "$as_me:13035: \$? = $ac_status" >&5
13036 (exit $ac_status); } >/dev/null; then
13037 if test -s conftest.err; then
13038 ac_cpp_err=$ac_c_preproc_warn_flag
13045 if test -z "$ac_cpp_err"; then
13046 ac_cv_header_stdc=yes
13048 echo "$as_me: failed program was:" >&5
13049 cat conftest.$ac_ext >&5
13050 ac_cv_header_stdc=no
13052 rm -f conftest.err conftest.$ac_ext
13054 if test $ac_cv_header_stdc = yes; then
13055 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
13056 cat >conftest.$ac_ext <<_ACEOF
13057 #line 13057 "configure"
13058 #include "confdefs.h"
13059 #include <string.h>
13062 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13063 egrep "memchr" >/dev/null 2>&1; then
13066 ac_cv_header_stdc=no
13072 if test $ac_cv_header_stdc = yes; then
13073 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
13074 cat >conftest.$ac_ext <<_ACEOF
13075 #line 13075 "configure"
13076 #include "confdefs.h"
13077 #include <stdlib.h>
13080 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13081 egrep "free" >/dev/null 2>&1; then
13084 ac_cv_header_stdc=no
13090 if test $ac_cv_header_stdc = yes; then
13091 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
13092 if test "$cross_compiling" = yes; then
13095 cat >conftest.$ac_ext <<_ACEOF
13096 #line 13096 "configure"
13097 #include "confdefs.h"
13099 #if ((' ' & 0x0FF) == 0x020)
13100 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
13101 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
13103 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
13104 || ('j' <= (c) && (c) <= 'r') \
13105 || ('s' <= (c) && (c) <= 'z'))
13106 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
13109 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
13114 for (i = 0; i < 256; i++)
13115 if (XOR (islower (i), ISLOWER (i))
13116 || toupper (i) != TOUPPER (i))
13117 $ac_main_return(2);
13118 $ac_main_return (0);
13121 rm -f conftest$ac_exeext
13122 if { (eval echo "$as_me:13122: \"$ac_link\"") >&5
13123 (eval $ac_link) 2>&5
13125 echo "$as_me:13125: \$? = $ac_status" >&5
13126 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13127 { (eval echo "$as_me:13127: \"$ac_try\"") >&5
13128 (eval $ac_try) 2>&5
13130 echo "$as_me:13130: \$? = $ac_status" >&5
13131 (exit $ac_status); }; }; then
13134 echo "$as_me: program exited with status $ac_status" >&5
13135 echo "$as_me: failed program was:" >&5
13136 cat conftest.$ac_ext >&5
13137 ac_cv_header_stdc=no
13139 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13143 echo "$as_me:13143: result: $ac_cv_header_stdc" >&5
13144 echo "${ECHO_T}$ac_cv_header_stdc" >&6
13145 if test $ac_cv_header_stdc = yes; then
13147 cat >>confdefs.h <<\EOF
13148 #define STDC_HEADERS 1
13153 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
13155 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
13156 inttypes.h stdint.h unistd.h
13158 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
13159 echo "$as_me:13159: checking for $ac_header" >&5
13160 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13161 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13162 echo $ECHO_N "(cached) $ECHO_C" >&6
13164 cat >conftest.$ac_ext <<_ACEOF
13165 #line 13165 "configure"
13166 #include "confdefs.h"
13167 $ac_includes_default
13168 #include <$ac_header>
13170 rm -f conftest.$ac_objext
13171 if { (eval echo "$as_me:13171: \"$ac_compile\"") >&5
13172 (eval $ac_compile) 2>&5
13174 echo "$as_me:13174: \$? = $ac_status" >&5
13175 (exit $ac_status); } &&
13176 { ac_try='test -s conftest.$ac_objext'
13177 { (eval echo "$as_me:13177: \"$ac_try\"") >&5
13178 (eval $ac_try) 2>&5
13180 echo "$as_me:13180: \$? = $ac_status" >&5
13181 (exit $ac_status); }; }; then
13182 eval "$as_ac_Header=yes"
13184 echo "$as_me: failed program was:" >&5
13185 cat conftest.$ac_ext >&5
13186 eval "$as_ac_Header=no"
13188 rm -f conftest.$ac_objext conftest.$ac_ext
13190 echo "$as_me:13190: result: `eval echo '${'$as_ac_Header'}'`" >&5
13191 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13192 if test `eval echo '${'$as_ac_Header'}'` = yes; then
13193 cat >>confdefs.h <<EOF
13194 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
13200 echo "$as_me:13200: checking for signed char" >&5
13201 echo $ECHO_N "checking for signed char... $ECHO_C" >&6
13202 if test "${ac_cv_type_signed_char+set}" = set; then
13203 echo $ECHO_N "(cached) $ECHO_C" >&6
13205 cat >conftest.$ac_ext <<_ACEOF
13206 #line 13206 "configure"
13207 #include "confdefs.h"
13208 $ac_includes_default
13212 if ((signed char *) 0)
13214 if (sizeof (signed char))
13220 rm -f conftest.$ac_objext
13221 if { (eval echo "$as_me:13221: \"$ac_compile\"") >&5
13222 (eval $ac_compile) 2>&5
13224 echo "$as_me:13224: \$? = $ac_status" >&5
13225 (exit $ac_status); } &&
13226 { ac_try='test -s conftest.$ac_objext'
13227 { (eval echo "$as_me:13227: \"$ac_try\"") >&5
13228 (eval $ac_try) 2>&5
13230 echo "$as_me:13230: \$? = $ac_status" >&5
13231 (exit $ac_status); }; }; then
13232 ac_cv_type_signed_char=yes
13234 echo "$as_me: failed program was:" >&5
13235 cat conftest.$ac_ext >&5
13236 ac_cv_type_signed_char=no
13238 rm -f conftest.$ac_objext conftest.$ac_ext
13240 echo "$as_me:13240: result: $ac_cv_type_signed_char" >&5
13241 echo "${ECHO_T}$ac_cv_type_signed_char" >&6
13243 echo "$as_me:13243: checking size of signed char" >&5
13244 echo $ECHO_N "checking size of signed char... $ECHO_C" >&6
13245 if test "${ac_cv_sizeof_signed_char+set}" = set; then
13246 echo $ECHO_N "(cached) $ECHO_C" >&6
13248 if test "$ac_cv_type_signed_char" = yes; then
13249 if test "$cross_compiling" = yes; then
13250 # Depending upon the size, compute the lo and hi bounds.
13251 cat >conftest.$ac_ext <<_ACEOF
13252 #line 13252 "configure"
13253 #include "confdefs.h"
13254 $ac_includes_default
13258 int _array_ [1 - 2 * !((sizeof (signed char)) >= 0)]
13263 rm -f conftest.$ac_objext
13264 if { (eval echo "$as_me:13264: \"$ac_compile\"") >&5
13265 (eval $ac_compile) 2>&5
13267 echo "$as_me:13267: \$? = $ac_status" >&5
13268 (exit $ac_status); } &&
13269 { ac_try='test -s conftest.$ac_objext'
13270 { (eval echo "$as_me:13270: \"$ac_try\"") >&5
13271 (eval $ac_try) 2>&5
13273 echo "$as_me:13273: \$? = $ac_status" >&5
13274 (exit $ac_status); }; }; then
13277 cat >conftest.$ac_ext <<_ACEOF
13278 #line 13278 "configure"
13279 #include "confdefs.h"
13280 $ac_includes_default
13284 int _array_ [1 - 2 * !((sizeof (signed char)) <= $ac_mid)]
13289 rm -f conftest.$ac_objext
13290 if { (eval echo "$as_me:13290: \"$ac_compile\"") >&5
13291 (eval $ac_compile) 2>&5
13293 echo "$as_me:13293: \$? = $ac_status" >&5
13294 (exit $ac_status); } &&
13295 { ac_try='test -s conftest.$ac_objext'
13296 { (eval echo "$as_me:13296: \"$ac_try\"") >&5
13297 (eval $ac_try) 2>&5
13299 echo "$as_me:13299: \$? = $ac_status" >&5
13300 (exit $ac_status); }; }; then
13301 ac_hi=$ac_mid; break
13303 echo "$as_me: failed program was:" >&5
13304 cat conftest.$ac_ext >&5
13305 ac_lo=`expr $ac_mid + 1`; ac_mid=`expr 2 '*' $ac_mid + 1`
13307 rm -f conftest.$ac_objext conftest.$ac_ext
13310 echo "$as_me: failed program was:" >&5
13311 cat conftest.$ac_ext >&5
13314 cat >conftest.$ac_ext <<_ACEOF
13315 #line 13315 "configure"
13316 #include "confdefs.h"
13317 $ac_includes_default
13321 int _array_ [1 - 2 * !((sizeof (signed char)) >= $ac_mid)]
13326 rm -f conftest.$ac_objext
13327 if { (eval echo "$as_me:13327: \"$ac_compile\"") >&5
13328 (eval $ac_compile) 2>&5
13330 echo "$as_me:13330: \$? = $ac_status" >&5
13331 (exit $ac_status); } &&
13332 { ac_try='test -s conftest.$ac_objext'
13333 { (eval echo "$as_me:13333: \"$ac_try\"") >&5
13334 (eval $ac_try) 2>&5
13336 echo "$as_me:13336: \$? = $ac_status" >&5
13337 (exit $ac_status); }; }; then
13338 ac_lo=$ac_mid; break
13340 echo "$as_me: failed program was:" >&5
13341 cat conftest.$ac_ext >&5
13342 ac_hi=`expr $ac_mid - 1`; ac_mid=`expr 2 '*' $ac_mid`
13344 rm -f conftest.$ac_objext conftest.$ac_ext
13347 rm -f conftest.$ac_objext conftest.$ac_ext
13348 # Binary search between lo and hi bounds.
13349 while test "x$ac_lo" != "x$ac_hi"; do
13350 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
13351 cat >conftest.$ac_ext <<_ACEOF
13352 #line 13352 "configure"
13353 #include "confdefs.h"
13354 $ac_includes_default
13358 int _array_ [1 - 2 * !((sizeof (signed char)) <= $ac_mid)]
13363 rm -f conftest.$ac_objext
13364 if { (eval echo "$as_me:13364: \"$ac_compile\"") >&5
13365 (eval $ac_compile) 2>&5
13367 echo "$as_me:13367: \$? = $ac_status" >&5
13368 (exit $ac_status); } &&
13369 { ac_try='test -s conftest.$ac_objext'
13370 { (eval echo "$as_me:13370: \"$ac_try\"") >&5
13371 (eval $ac_try) 2>&5
13373 echo "$as_me:13373: \$? = $ac_status" >&5
13374 (exit $ac_status); }; }; then
13377 echo "$as_me: failed program was:" >&5
13378 cat conftest.$ac_ext >&5
13379 ac_lo=`expr $ac_mid + 1`
13381 rm -f conftest.$ac_objext conftest.$ac_ext
13383 ac_cv_sizeof_signed_char=$ac_lo
13385 if test "$cross_compiling" = yes; then
13386 { { echo "$as_me:13386: error: cannot run test program while cross compiling" >&5
13387 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
13388 { (exit 1); exit 1; }; }
13390 cat >conftest.$ac_ext <<_ACEOF
13391 #line 13391 "configure"
13392 #include "confdefs.h"
13393 $ac_includes_default
13397 FILE *f = fopen ("conftest.val", "w");
13399 $ac_main_return (1);
13400 fprintf (f, "%d", (sizeof (signed char)));
13406 rm -f conftest$ac_exeext
13407 if { (eval echo "$as_me:13407: \"$ac_link\"") >&5
13408 (eval $ac_link) 2>&5
13410 echo "$as_me:13410: \$? = $ac_status" >&5
13411 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13412 { (eval echo "$as_me:13412: \"$ac_try\"") >&5
13413 (eval $ac_try) 2>&5
13415 echo "$as_me:13415: \$? = $ac_status" >&5
13416 (exit $ac_status); }; }; then
13417 ac_cv_sizeof_signed_char=`cat conftest.val`
13419 echo "$as_me: program exited with status $ac_status" >&5
13420 echo "$as_me: failed program was:" >&5
13421 cat conftest.$ac_ext >&5
13423 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13428 ac_cv_sizeof_signed_char=0
13431 echo "$as_me:13431: result: $ac_cv_sizeof_signed_char" >&5
13432 echo "${ECHO_T}$ac_cv_sizeof_signed_char" >&6
13433 cat >>confdefs.h <<EOF
13434 #define SIZEOF_SIGNED_CHAR $ac_cv_sizeof_signed_char
13437 echo "$as_me:13437: checking for ANSI C header files" >&5
13438 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
13439 if test "${ac_cv_header_stdc+set}" = set; then
13440 echo $ECHO_N "(cached) $ECHO_C" >&6
13442 cat >conftest.$ac_ext <<_ACEOF
13443 #line 13443 "configure"
13444 #include "confdefs.h"
13445 #include <stdlib.h>
13446 #include <stdarg.h>
13447 #include <string.h>
13451 if { (eval echo "$as_me:13451: \"$ac_cpp conftest.$ac_ext\"") >&5
13452 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13454 egrep -v '^ *\+' conftest.er1 >conftest.err
13456 cat conftest.err >&5
13457 echo "$as_me:13457: \$? = $ac_status" >&5
13458 (exit $ac_status); } >/dev/null; then
13459 if test -s conftest.err; then
13460 ac_cpp_err=$ac_c_preproc_warn_flag
13467 if test -z "$ac_cpp_err"; then
13468 ac_cv_header_stdc=yes
13470 echo "$as_me: failed program was:" >&5
13471 cat conftest.$ac_ext >&5
13472 ac_cv_header_stdc=no
13474 rm -f conftest.err conftest.$ac_ext
13476 if test $ac_cv_header_stdc = yes; then
13477 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
13478 cat >conftest.$ac_ext <<_ACEOF
13479 #line 13479 "configure"
13480 #include "confdefs.h"
13481 #include <string.h>
13484 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13485 egrep "memchr" >/dev/null 2>&1; then
13488 ac_cv_header_stdc=no
13494 if test $ac_cv_header_stdc = yes; then
13495 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
13496 cat >conftest.$ac_ext <<_ACEOF
13497 #line 13497 "configure"
13498 #include "confdefs.h"
13499 #include <stdlib.h>
13502 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13503 egrep "free" >/dev/null 2>&1; then
13506 ac_cv_header_stdc=no
13512 if test $ac_cv_header_stdc = yes; then
13513 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
13514 if test "$cross_compiling" = yes; then
13517 cat >conftest.$ac_ext <<_ACEOF
13518 #line 13518 "configure"
13519 #include "confdefs.h"
13521 #if ((' ' & 0x0FF) == 0x020)
13522 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
13523 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
13525 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
13526 || ('j' <= (c) && (c) <= 'r') \
13527 || ('s' <= (c) && (c) <= 'z'))
13528 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
13531 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
13536 for (i = 0; i < 256; i++)
13537 if (XOR (islower (i), ISLOWER (i))
13538 || toupper (i) != TOUPPER (i))
13539 $ac_main_return(2);
13540 $ac_main_return (0);
13543 rm -f conftest$ac_exeext
13544 if { (eval echo "$as_me:13544: \"$ac_link\"") >&5
13545 (eval $ac_link) 2>&5
13547 echo "$as_me:13547: \$? = $ac_status" >&5
13548 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13549 { (eval echo "$as_me:13549: \"$ac_try\"") >&5
13550 (eval $ac_try) 2>&5
13552 echo "$as_me:13552: \$? = $ac_status" >&5
13553 (exit $ac_status); }; }; then
13556 echo "$as_me: program exited with status $ac_status" >&5
13557 echo "$as_me: failed program was:" >&5
13558 cat conftest.$ac_ext >&5
13559 ac_cv_header_stdc=no
13561 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13565 echo "$as_me:13565: result: $ac_cv_header_stdc" >&5
13566 echo "${ECHO_T}$ac_cv_header_stdc" >&6
13567 if test $ac_cv_header_stdc = yes; then
13569 cat >>confdefs.h <<\EOF
13570 #define STDC_HEADERS 1
13575 ac_header_dirent=no
13576 for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
13577 as_ac_Header=`echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
13578 echo "$as_me:13578: checking for $ac_hdr that defines DIR" >&5
13579 echo $ECHO_N "checking for $ac_hdr that defines DIR... $ECHO_C" >&6
13580 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13581 echo $ECHO_N "(cached) $ECHO_C" >&6
13583 cat >conftest.$ac_ext <<_ACEOF
13584 #line 13584 "configure"
13585 #include "confdefs.h"
13586 #include <sys/types.h>
13598 rm -f conftest.$ac_objext
13599 if { (eval echo "$as_me:13599: \"$ac_compile\"") >&5
13600 (eval $ac_compile) 2>&5
13602 echo "$as_me:13602: \$? = $ac_status" >&5
13603 (exit $ac_status); } &&
13604 { ac_try='test -s conftest.$ac_objext'
13605 { (eval echo "$as_me:13605: \"$ac_try\"") >&5
13606 (eval $ac_try) 2>&5
13608 echo "$as_me:13608: \$? = $ac_status" >&5
13609 (exit $ac_status); }; }; then
13610 eval "$as_ac_Header=yes"
13612 echo "$as_me: failed program was:" >&5
13613 cat conftest.$ac_ext >&5
13614 eval "$as_ac_Header=no"
13616 rm -f conftest.$ac_objext conftest.$ac_ext
13618 echo "$as_me:13618: result: `eval echo '${'$as_ac_Header'}'`" >&5
13619 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13620 if test `eval echo '${'$as_ac_Header'}'` = yes; then
13621 cat >>confdefs.h <<EOF
13622 #define `echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
13625 ac_header_dirent=$ac_hdr; break
13629 # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
13630 if test $ac_header_dirent = dirent.h; then
13631 echo "$as_me:13631: checking for opendir in -ldir" >&5
13632 echo $ECHO_N "checking for opendir in -ldir... $ECHO_C" >&6
13633 if test "${ac_cv_lib_dir_opendir+set}" = set; then
13634 echo $ECHO_N "(cached) $ECHO_C" >&6
13636 ac_check_lib_save_LIBS=$LIBS
13638 cat >conftest.$ac_ext <<_ACEOF
13639 #line 13639 "configure"
13640 #include "confdefs.h"
13642 /* Override any gcc2 internal prototype to avoid an error. */
13646 /* We use char because int might match the return type of a gcc2
13647 builtin and then its argument prototype would still apply. */
13657 rm -f conftest.$ac_objext conftest$ac_exeext
13658 if { (eval echo "$as_me:13658: \"$ac_link\"") >&5
13659 (eval $ac_link) 2>&5
13661 echo "$as_me:13661: \$? = $ac_status" >&5
13662 (exit $ac_status); } &&
13663 { ac_try='test -s conftest$ac_exeext'
13664 { (eval echo "$as_me:13664: \"$ac_try\"") >&5
13665 (eval $ac_try) 2>&5
13667 echo "$as_me:13667: \$? = $ac_status" >&5
13668 (exit $ac_status); }; }; then
13669 ac_cv_lib_dir_opendir=yes
13671 echo "$as_me: failed program was:" >&5
13672 cat conftest.$ac_ext >&5
13673 ac_cv_lib_dir_opendir=no
13675 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13676 LIBS=$ac_check_lib_save_LIBS
13678 echo "$as_me:13678: result: $ac_cv_lib_dir_opendir" >&5
13679 echo "${ECHO_T}$ac_cv_lib_dir_opendir" >&6
13680 if test $ac_cv_lib_dir_opendir = yes; then
13685 echo "$as_me:13685: checking for opendir in -lx" >&5
13686 echo $ECHO_N "checking for opendir in -lx... $ECHO_C" >&6
13687 if test "${ac_cv_lib_x_opendir+set}" = set; then
13688 echo $ECHO_N "(cached) $ECHO_C" >&6
13690 ac_check_lib_save_LIBS=$LIBS
13692 cat >conftest.$ac_ext <<_ACEOF
13693 #line 13693 "configure"
13694 #include "confdefs.h"
13696 /* Override any gcc2 internal prototype to avoid an error. */
13700 /* We use char because int might match the return type of a gcc2
13701 builtin and then its argument prototype would still apply. */
13711 rm -f conftest.$ac_objext conftest$ac_exeext
13712 if { (eval echo "$as_me:13712: \"$ac_link\"") >&5
13713 (eval $ac_link) 2>&5
13715 echo "$as_me:13715: \$? = $ac_status" >&5
13716 (exit $ac_status); } &&
13717 { ac_try='test -s conftest$ac_exeext'
13718 { (eval echo "$as_me:13718: \"$ac_try\"") >&5
13719 (eval $ac_try) 2>&5
13721 echo "$as_me:13721: \$? = $ac_status" >&5
13722 (exit $ac_status); }; }; then
13723 ac_cv_lib_x_opendir=yes
13725 echo "$as_me: failed program was:" >&5
13726 cat conftest.$ac_ext >&5
13727 ac_cv_lib_x_opendir=no
13729 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13730 LIBS=$ac_check_lib_save_LIBS
13732 echo "$as_me:13732: result: $ac_cv_lib_x_opendir" >&5
13733 echo "${ECHO_T}$ac_cv_lib_x_opendir" >&6
13734 if test $ac_cv_lib_x_opendir = yes; then
13740 echo "$as_me:13740: checking whether time.h and sys/time.h may both be included" >&5
13741 echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
13742 if test "${ac_cv_header_time+set}" = set; then
13743 echo $ECHO_N "(cached) $ECHO_C" >&6
13745 cat >conftest.$ac_ext <<_ACEOF
13746 #line 13746 "configure"
13747 #include "confdefs.h"
13748 #include <sys/types.h>
13749 #include <sys/time.h>
13755 if ((struct tm *) 0)
13761 rm -f conftest.$ac_objext
13762 if { (eval echo "$as_me:13762: \"$ac_compile\"") >&5
13763 (eval $ac_compile) 2>&5
13765 echo "$as_me:13765: \$? = $ac_status" >&5
13766 (exit $ac_status); } &&
13767 { ac_try='test -s conftest.$ac_objext'
13768 { (eval echo "$as_me:13768: \"$ac_try\"") >&5
13769 (eval $ac_try) 2>&5
13771 echo "$as_me:13771: \$? = $ac_status" >&5
13772 (exit $ac_status); }; }; then
13773 ac_cv_header_time=yes
13775 echo "$as_me: failed program was:" >&5
13776 cat conftest.$ac_ext >&5
13777 ac_cv_header_time=no
13779 rm -f conftest.$ac_objext conftest.$ac_ext
13781 echo "$as_me:13781: result: $ac_cv_header_time" >&5
13782 echo "${ECHO_T}$ac_cv_header_time" >&6
13783 if test $ac_cv_header_time = yes; then
13785 cat >>confdefs.h <<\EOF
13786 #define TIME_WITH_SYS_TIME 1
13791 ### checks for compiler characteristics
13793 ac_cpp='$CPP $CPPFLAGS'
13794 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
13795 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
13796 ac_compiler_gnu=$ac_cv_c_compiler_gnu
13797 ac_main_return=return
13799 echo "$as_me:13799: checking for an ANSI C-conforming const" >&5
13800 echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
13801 if test "${ac_cv_c_const+set}" = set; then
13802 echo $ECHO_N "(cached) $ECHO_C" >&6
13804 cat >conftest.$ac_ext <<_ACEOF
13805 #line 13805 "configure"
13806 #include "confdefs.h"
13811 /* FIXME: Include the comments suggested by Paul. */
13812 #ifndef __cplusplus
13813 /* Ultrix mips cc rejects this. */
13814 typedef int charset[2];
13816 /* SunOS 4.1.1 cc rejects this. */
13817 char const *const *ccp;
13819 /* NEC SVR4.0.2 mips cc rejects this. */
13820 struct point {int x, y;};
13821 static struct point const zero = {0,0};
13822 /* AIX XL C 1.02.0.0 rejects this.
13823 It does not let you subtract one const X* pointer from another in
13824 an arm of an if-expression whose if-part is not a constant
13826 const char *g = "string";
13827 ccp = &g + (g ? g-g : 0);
13828 /* HPUX 7.0 cc rejects these. */
13831 ccp = (char const *const *) p;
13832 { /* SCO 3.2v4 cc rejects this. */
13834 char const *s = 0 ? (char *) 0 : (char const *) 0;
13838 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
13839 int x[] = {25, 17};
13840 const int *foo = &x[0];
13843 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
13844 typedef const int *iptr;
13848 { /* AIX XL C 1.02.0.0 rejects this saying
13849 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
13850 struct s { int j; const int *ap[3]; };
13851 struct s *b; b->j = 5;
13853 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
13854 const int foo = 10;
13862 rm -f conftest.$ac_objext
13863 if { (eval echo "$as_me:13863: \"$ac_compile\"") >&5
13864 (eval $ac_compile) 2>&5
13866 echo "$as_me:13866: \$? = $ac_status" >&5
13867 (exit $ac_status); } &&
13868 { ac_try='test -s conftest.$ac_objext'
13869 { (eval echo "$as_me:13869: \"$ac_try\"") >&5
13870 (eval $ac_try) 2>&5
13872 echo "$as_me:13872: \$? = $ac_status" >&5
13873 (exit $ac_status); }; }; then
13876 echo "$as_me: failed program was:" >&5
13877 cat conftest.$ac_ext >&5
13880 rm -f conftest.$ac_objext conftest.$ac_ext
13882 echo "$as_me:13882: result: $ac_cv_c_const" >&5
13883 echo "${ECHO_T}$ac_cv_c_const" >&6
13884 if test $ac_cv_c_const = no; then
13886 cat >>confdefs.h <<\EOF
13892 ### Checks for external-data
13894 echo "$as_me:13894: checking if data-only library module links" >&5
13895 echo $ECHO_N "checking if data-only library module links... $ECHO_C" >&6
13896 if test "${cf_cv_link_dataonly+set}" = set; then
13897 echo $ECHO_N "(cached) $ECHO_C" >&6
13901 cat >conftest.$ac_ext <<EOF
13902 #line 13902 "configure"
13903 int testdata[3] = { 123, 456, 789 };
13905 if { (eval echo "$as_me:13905: \"$ac_compile\"") >&5
13906 (eval $ac_compile) 2>&5
13908 echo "$as_me:13908: \$? = $ac_status" >&5
13909 (exit $ac_status); } ; then
13910 mv conftest.o data.o && \
13911 ( $AR $ARFLAGS conftest.a data.o ) 2>&5 1>/dev/null
13913 rm -f conftest.$ac_ext data.o
13914 cat >conftest.$ac_ext <<EOF
13915 #line 13915 "configure"
13919 ${cf_cv_main_return:-return}(1); /* I'm told this linker is broken */
13921 extern int testdata[3];
13922 return testdata[0] == 123
13923 && testdata[1] == 456
13924 && testdata[2] == 789;
13928 if { (eval echo "$as_me:13928: \"$ac_compile\"") >&5
13929 (eval $ac_compile) 2>&5
13931 echo "$as_me:13931: \$? = $ac_status" >&5
13932 (exit $ac_status); }; then
13933 mv conftest.o func.o && \
13934 ( $AR $ARFLAGS conftest.a func.o ) 2>&5 1>/dev/null
13936 rm -f conftest.$ac_ext func.o
13937 ( eval $RANLIB conftest.a ) 2>&5 >/dev/null
13938 cf_saveLIBS="$LIBS"
13939 LIBS="conftest.a $LIBS"
13940 if test "$cross_compiling" = yes; then
13941 cf_cv_link_dataonly=unknown
13943 cat >conftest.$ac_ext <<_ACEOF
13944 #line 13944 "configure"
13945 #include "confdefs.h"
13949 extern int testfunc();
13950 ${cf_cv_main_return:-return} (!testfunc());
13954 rm -f conftest$ac_exeext
13955 if { (eval echo "$as_me:13955: \"$ac_link\"") >&5
13956 (eval $ac_link) 2>&5
13958 echo "$as_me:13958: \$? = $ac_status" >&5
13959 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13960 { (eval echo "$as_me:13960: \"$ac_try\"") >&5
13961 (eval $ac_try) 2>&5
13963 echo "$as_me:13963: \$? = $ac_status" >&5
13964 (exit $ac_status); }; }; then
13965 cf_cv_link_dataonly=yes
13967 echo "$as_me: program exited with status $ac_status" >&5
13968 echo "$as_me: failed program was:" >&5
13969 cat conftest.$ac_ext >&5
13970 cf_cv_link_dataonly=no
13972 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13974 LIBS="$cf_saveLIBS"
13978 echo "$as_me:13978: result: $cf_cv_link_dataonly" >&5
13979 echo "${ECHO_T}$cf_cv_link_dataonly" >&6
13981 if test "$cf_cv_link_dataonly" = no ; then
13983 cat >>confdefs.h <<\EOF
13984 #define BROKEN_LINKER 1
13990 ### Checks for library functions.
13996 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
13997 echo "$as_me:13997: checking for $ac_header" >&5
13998 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13999 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14000 echo $ECHO_N "(cached) $ECHO_C" >&6
14002 cat >conftest.$ac_ext <<_ACEOF
14003 #line 14003 "configure"
14004 #include "confdefs.h"
14005 #include <$ac_header>
14007 if { (eval echo "$as_me:14007: \"$ac_cpp conftest.$ac_ext\"") >&5
14008 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
14010 egrep -v '^ *\+' conftest.er1 >conftest.err
14012 cat conftest.err >&5
14013 echo "$as_me:14013: \$? = $ac_status" >&5
14014 (exit $ac_status); } >/dev/null; then
14015 if test -s conftest.err; then
14016 ac_cpp_err=$ac_c_preproc_warn_flag
14023 if test -z "$ac_cpp_err"; then
14024 eval "$as_ac_Header=yes"
14026 echo "$as_me: failed program was:" >&5
14027 cat conftest.$ac_ext >&5
14028 eval "$as_ac_Header=no"
14030 rm -f conftest.err conftest.$ac_ext
14032 echo "$as_me:14032: result: `eval echo '${'$as_ac_Header'}'`" >&5
14033 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
14034 if test `eval echo '${'$as_ac_Header'}'` = yes; then
14035 cat >>confdefs.h <<EOF
14036 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
14042 echo "$as_me:14042: checking for working mkstemp" >&5
14043 echo $ECHO_N "checking for working mkstemp... $ECHO_C" >&6
14044 if test "${cf_cv_func_mkstemp+set}" = set; then
14045 echo $ECHO_N "(cached) $ECHO_C" >&6
14049 if test "$cross_compiling" = yes; then
14050 cf_cv_func_mkstemp=maybe
14052 cat >conftest.$ac_ext <<_ACEOF
14053 #line 14053 "configure"
14054 #include "confdefs.h"
14056 #include <sys/types.h>
14057 #ifdef HAVE_UNISTD_H
14058 #include <unistd.h>
14060 #include <stdlib.h>
14062 #include <string.h>
14063 #include <sys/stat.h>
14066 char *tmpl = "conftestXXXXXX";
14074 for (n = 0; n < 2; ++n) {
14075 strcpy(name[n], tmpl);
14076 if ((fd = mkstemp(name[n])) >= 0) {
14077 if (!strcmp(name[n], tmpl)
14078 || stat(name[n], &sb) != 0
14079 || (sb.st_mode & S_IFMT) != S_IFREG
14080 || (sb.st_mode & 077) != 0) {
14087 && !strcmp(name[0], name[1]))
14089 ${cf_cv_main_return:-return}(result);
14093 rm -f conftest$ac_exeext
14094 if { (eval echo "$as_me:14094: \"$ac_link\"") >&5
14095 (eval $ac_link) 2>&5
14097 echo "$as_me:14097: \$? = $ac_status" >&5
14098 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14099 { (eval echo "$as_me:14099: \"$ac_try\"") >&5
14100 (eval $ac_try) 2>&5
14102 echo "$as_me:14102: \$? = $ac_status" >&5
14103 (exit $ac_status); }; }; then
14104 cf_cv_func_mkstemp=yes
14107 echo "$as_me: program exited with status $ac_status" >&5
14108 echo "$as_me: failed program was:" >&5
14109 cat conftest.$ac_ext >&5
14110 cf_cv_func_mkstemp=no
14113 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14117 echo "$as_me:14117: result: $cf_cv_func_mkstemp" >&5
14118 echo "${ECHO_T}$cf_cv_func_mkstemp" >&6
14119 if test "x$cf_cv_func_mkstemp" = xmaybe ; then
14120 echo "$as_me:14120: checking for mkstemp" >&5
14121 echo $ECHO_N "checking for mkstemp... $ECHO_C" >&6
14122 if test "${ac_cv_func_mkstemp+set}" = set; then
14123 echo $ECHO_N "(cached) $ECHO_C" >&6
14125 cat >conftest.$ac_ext <<_ACEOF
14126 #line 14126 "configure"
14127 #include "confdefs.h"
14128 /* System header to define __stub macros and hopefully few prototypes,
14129 which can conflict with char mkstemp (); below. */
14130 #include <assert.h>
14131 /* Override any gcc2 internal prototype to avoid an error. */
14135 /* We use char because int might match the return type of a gcc2
14136 builtin and then its argument prototype would still apply. */
14143 /* The GNU C library defines this for functions which it implements
14144 to always fail with ENOSYS. Some functions are actually named
14145 something starting with __ and the normal name is an alias. */
14146 #if defined (__stub_mkstemp) || defined (__stub___mkstemp)
14149 f = mkstemp; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
14156 rm -f conftest.$ac_objext conftest$ac_exeext
14157 if { (eval echo "$as_me:14157: \"$ac_link\"") >&5
14158 (eval $ac_link) 2>&5
14160 echo "$as_me:14160: \$? = $ac_status" >&5
14161 (exit $ac_status); } &&
14162 { ac_try='test -s conftest$ac_exeext'
14163 { (eval echo "$as_me:14163: \"$ac_try\"") >&5
14164 (eval $ac_try) 2>&5
14166 echo "$as_me:14166: \$? = $ac_status" >&5
14167 (exit $ac_status); }; }; then
14168 ac_cv_func_mkstemp=yes
14170 echo "$as_me: failed program was:" >&5
14171 cat conftest.$ac_ext >&5
14172 ac_cv_func_mkstemp=no
14174 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14176 echo "$as_me:14176: result: $ac_cv_func_mkstemp" >&5
14177 echo "${ECHO_T}$ac_cv_func_mkstemp" >&6
14180 if test "x$cf_cv_func_mkstemp" = xyes || test "x$ac_cv_func_mkstemp" = xyes ; then
14182 cat >>confdefs.h <<\EOF
14183 #define HAVE_MKSTEMP 1
14188 if test -z "$cf_user_CFLAGS" && test "$with_no_leaks" = no ; then
14189 CFLAGS=`echo ${CFLAGS} | sed -e 's%-g %%' -e 's%-g$%%'`
14190 CXXFLAGS=`echo ${CXXFLAGS} | sed -e 's%-g %%' -e 's%-g$%%'`
14194 if test "$cf_with_ada" != "no" ; then
14196 cf_ada_make=gnatmake
14197 # Extract the first word of "$cf_ada_make", so it can be a program name with args.
14198 set dummy $cf_ada_make; ac_word=$2
14199 echo "$as_me:14199: checking for $ac_word" >&5
14200 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
14201 if test "${ac_cv_prog_gnat_exists+set}" = set; then
14202 echo $ECHO_N "(cached) $ECHO_C" >&6
14204 if test -n "$gnat_exists"; then
14205 ac_cv_prog_gnat_exists="$gnat_exists" # Let the user override the test.
14207 ac_save_IFS=$IFS; IFS=$ac_path_separator
14209 for ac_dir in $ac_dummy; do
14211 test -z "$ac_dir" && ac_dir=.
14212 $as_executable_p "$ac_dir/$ac_word" || continue
14213 ac_cv_prog_gnat_exists="yes"
14214 echo "$as_me:14214: found $ac_dir/$ac_word" >&5
14218 test -z "$ac_cv_prog_gnat_exists" && ac_cv_prog_gnat_exists="no"
14221 gnat_exists=$ac_cv_prog_gnat_exists
14222 if test -n "$gnat_exists"; then
14223 echo "$as_me:14223: result: $gnat_exists" >&5
14224 echo "${ECHO_T}$gnat_exists" >&6
14226 echo "$as_me:14226: result: no" >&5
14227 echo "${ECHO_T}no" >&6
14230 if test "$ac_cv_prog_gnat_exists" = no; then
14232 cf_cv_prog_gnat_correct=no
14235 echo "$as_me:14235: checking for gnat version" >&5
14236 echo $ECHO_N "checking for gnat version... $ECHO_C" >&6
14237 cf_gnat_version=`${cf_ada_make:-gnatmake} -v 2>&1 | \
14238 grep '[0-9].[0-9][0-9]*' |\
14239 sed -e '2,$d' -e 's/[^0-9 \.]//g' -e 's/^[ ]*//' -e 's/ .*//'`
14240 echo "$as_me:14240: result: $cf_gnat_version" >&5
14241 echo "${ECHO_T}$cf_gnat_version" >&6
14243 case $cf_gnat_version in
14244 (3.1[1-9]*|3.[2-9]*|[4-9].*|20[0-9][0-9])
14245 cf_cv_prog_gnat_correct=yes
14248 { echo "$as_me:14248: WARNING: Unsupported GNAT version $cf_gnat_version. We require 3.11 or better. Disabling Ada95 binding." >&5
14249 echo "$as_me: WARNING: Unsupported GNAT version $cf_gnat_version. We require 3.11 or better. Disabling Ada95 binding." >&2;}
14250 cf_cv_prog_gnat_correct=no
14254 # Extract the first word of "m4", so it can be a program name with args.
14255 set dummy m4; ac_word=$2
14256 echo "$as_me:14256: checking for $ac_word" >&5
14257 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
14258 if test "${ac_cv_prog_M4_exists+set}" = set; then
14259 echo $ECHO_N "(cached) $ECHO_C" >&6
14261 if test -n "$M4_exists"; then
14262 ac_cv_prog_M4_exists="$M4_exists" # Let the user override the test.
14264 ac_save_IFS=$IFS; IFS=$ac_path_separator
14266 for ac_dir in $ac_dummy; do
14268 test -z "$ac_dir" && ac_dir=.
14269 $as_executable_p "$ac_dir/$ac_word" || continue
14270 ac_cv_prog_M4_exists="yes"
14271 echo "$as_me:14271: found $ac_dir/$ac_word" >&5
14275 test -z "$ac_cv_prog_M4_exists" && ac_cv_prog_M4_exists="no"
14278 M4_exists=$ac_cv_prog_M4_exists
14279 if test -n "$M4_exists"; then
14280 echo "$as_me:14280: result: $M4_exists" >&5
14281 echo "${ECHO_T}$M4_exists" >&6
14283 echo "$as_me:14283: result: no" >&5
14284 echo "${ECHO_T}no" >&6
14287 if test "$ac_cv_prog_M4_exists" = no; then
14288 cf_cv_prog_gnat_correct=no
14289 echo Ada95 binding required program m4 not found. Ada95 binding disabled.
14291 if test "$cf_cv_prog_gnat_correct" = yes; then
14292 echo "$as_me:14292: checking if GNAT works" >&5
14293 echo $ECHO_N "checking if GNAT works... $ECHO_C" >&6
14295 rm -rf conftest* *~conftest*
14296 cat >>conftest.ads <<CF_EOF
14297 procedure conftest;
14299 cat >>conftest.adb <<CF_EOF
14302 procedure conftest is
14304 Text_IO.Put ("Hello World");
14306 GNAT.OS_Lib.OS_Exit (0);
14309 if ( $cf_ada_make $ADAFLAGS conftest 1>&5 2>&1 ) ; then
14310 if ( ./conftest 1>&5 2>&1 ) ; then
14311 cf_cv_prog_gnat_correct=yes
14313 cf_cv_prog_gnat_correct=no
14316 cf_cv_prog_gnat_correct=no
14318 rm -rf conftest* *~conftest*
14320 echo "$as_me:14320: result: $cf_cv_prog_gnat_correct" >&5
14321 echo "${ECHO_T}$cf_cv_prog_gnat_correct" >&6
14325 if test "$cf_cv_prog_gnat_correct" = yes; then
14327 echo "$as_me:14327: checking optimization options for ADAFLAGS" >&5
14328 echo $ECHO_N "checking optimization options for ADAFLAGS... $ECHO_C" >&6
14332 ADAFLAGS="$ADAFLAGS -g"
14338 cf_O_flag=`echo "$CFLAGS" |sed -e 's/^.*-O/-O/' -e 's/[ ].*//'`
14340 ADAFLAGS="$ADAFLAGS $cf_O_flag"
14344 echo "$as_me:14344: result: $ADAFLAGS" >&5
14345 echo "${ECHO_T}$ADAFLAGS" >&6
14347 echo "$as_me:14347: checking if GNATPREP supports -T option" >&5
14348 echo $ECHO_N "checking if GNATPREP supports -T option... $ECHO_C" >&6
14349 if test "${cf_cv_gnatprep_opt_t+set}" = set; then
14350 echo $ECHO_N "(cached) $ECHO_C" >&6
14353 cf_cv_gnatprep_opt_t=no
14354 gnatprep -T 2>/dev/null >/dev/null && cf_cv_gnatprep_opt_t=yes
14357 echo "$as_me:14357: result: $cf_cv_gnatprep_opt_t" >&5
14358 echo "${ECHO_T}$cf_cv_gnatprep_opt_t" >&6
14359 test "$cf_cv_gnatprep_opt_t" = yes && GNATPREP_OPTS="-T $GNATPREP_OPTS"
14361 echo "$as_me:14361: checking if GNAT supports generics" >&5
14362 echo $ECHO_N "checking if GNAT supports generics... $ECHO_C" >&6
14363 case $cf_gnat_version in
14365 cf_gnat_generics=yes
14368 cf_gnat_generics=no
14371 echo "$as_me:14371: result: $cf_gnat_generics" >&5
14372 echo "${ECHO_T}$cf_gnat_generics" >&6
14374 if test "$cf_gnat_generics" = yes
14376 cf_compile_generics=generics
14377 cf_generic_objects="\${GENOBJS}"
14379 cf_compile_generics=
14380 cf_generic_objects=
14383 echo "$as_me:14383: checking if GNAT supports SIGINT" >&5
14384 echo $ECHO_N "checking if GNAT supports SIGINT... $ECHO_C" >&6
14385 if test "${cf_cv_gnat_sigint+set}" = set; then
14386 echo $ECHO_N "(cached) $ECHO_C" >&6
14389 rm -rf conftest* *~conftest*
14390 cat >>conftest.ads <<CF_EOF
14391 with Ada.Interrupts.Names;
14393 package ConfTest is
14395 pragma Warnings (Off); -- the next pragma exists since 3.11p
14396 pragma Unreserve_All_Interrupts;
14397 pragma Warnings (On);
14399 protected Process is
14401 function Continue return Boolean;
14402 pragma Attach_Handler (Stop, Ada.Interrupts.Names.SIGINT);
14404 Done : Boolean := False;
14409 cat >>conftest.adb <<CF_EOF
14410 package body ConfTest is
14411 protected body Process is
14416 function Continue return Boolean is
14423 if ( $cf_ada_make $ADAFLAGS conftest 1>&5 2>&1 ) ; then
14424 cf_cv_gnat_sigint=yes
14426 cf_cv_gnat_sigint=no
14428 rm -rf conftest* *~conftest*
14431 echo "$as_me:14431: result: $cf_cv_gnat_sigint" >&5
14432 echo "${ECHO_T}$cf_cv_gnat_sigint" >&6
14434 if test $cf_cv_gnat_sigint = yes ; then
14437 USE_GNAT_SIGINT="#"
14440 cf_gnat_libraries=no
14441 cf_gnat_projects=no
14443 if test "$enable_gnat_projects" != no ; then
14444 echo "$as_me:14444: checking if GNAT supports project files" >&5
14445 echo $ECHO_N "checking if GNAT supports project files... $ECHO_C" >&6
14446 case $cf_gnat_version in
14450 case $cf_cv_system_name in
14454 mkdir conftest.src conftest.bin conftest.lib
14456 rm -rf conftest* *~conftest*
14457 cat >>library.gpr <<CF_EOF
14459 Kind := External ("LIB_KIND");
14460 for Library_Name use "ConfTest";
14461 for Object_Dir use ".";
14462 for Library_ALI_Dir use External("LIBRARY_DIR");
14463 for Library_Version use External ("SONAME");
14464 for Library_Kind use Kind;
14465 for Library_Dir use External("BUILD_DIR");
14466 Source_Dir := External ("SOURCE_DIR");
14467 for Source_Dirs use (Source_Dir);
14470 cat >>confpackage.ads <<CF_EOF
14471 package ConfPackage is
14472 procedure conftest;
14475 cat >>confpackage.adb <<CF_EOF
14477 package body ConfPackage is
14478 procedure conftest is
14480 Text_IO.Put ("Hello World");
14485 if ( $cf_ada_make $ADAFLAGS \
14487 -XBUILD_DIR=`cd ../conftest.bin;pwd` \
14488 -XLIBRARY_DIR=`cd ../conftest.lib;pwd` \
14489 -XSOURCE_DIR=`pwd` \
14490 -XSONAME=libConfTest.so.1 \
14491 -XLIB_KIND=static 1>&5 2>&1 ) ; then
14492 cf_gnat_projects=yes
14495 if test -f conftest.lib/confpackage.ali
14497 cf_gnat_libraries=yes
14499 rm -rf conftest* *~conftest*
14504 echo "$as_me:14504: result: $cf_gnat_projects" >&5
14505 echo "${ECHO_T}$cf_gnat_projects" >&6
14506 fi # enable_gnat_projects
14508 if test $cf_gnat_projects = yes
14510 echo "$as_me:14510: checking if GNAT supports libraries" >&5
14511 echo $ECHO_N "checking if GNAT supports libraries... $ECHO_C" >&6
14512 echo "$as_me:14512: result: $cf_gnat_libraries" >&5
14513 echo "${ECHO_T}$cf_gnat_libraries" >&6
14516 if test "$cf_gnat_projects" = yes
14518 USE_OLD_MAKERULES="#"
14519 USE_GNAT_PROJECTS=""
14521 USE_OLD_MAKERULES=""
14522 USE_GNAT_PROJECTS="#"
14525 if test "$cf_gnat_libraries" = yes
14527 USE_GNAT_LIBRARIES=""
14529 USE_GNAT_LIBRARIES="#"
14532 echo "$as_me:14532: checking for ada-compiler" >&5
14533 echo $ECHO_N "checking for ada-compiler... $ECHO_C" >&6
14535 # Check whether --with-ada-compiler or --without-ada-compiler was given.
14536 if test "${with_ada_compiler+set}" = set; then
14537 withval="$with_ada_compiler"
14538 cf_ada_compiler=$withval
14540 cf_ada_compiler=gnatmake
14543 echo "$as_me:14543: result: $cf_ada_compiler" >&5
14544 echo "${ECHO_T}$cf_ada_compiler" >&6
14546 cf_ada_package=terminal_interface
14548 echo "$as_me:14548: checking for ada-include" >&5
14549 echo $ECHO_N "checking for ada-include... $ECHO_C" >&6
14551 # Check whether --with-ada-include or --without-ada-include was given.
14552 if test "${with_ada_include+set}" = set; then
14553 withval="$with_ada_include"
14556 withval="${ADA_INCLUDE:-$prefix/share/ada/adainclude}"
14557 fi; if test -n "$prefix/share/ada/adainclude" ; then
14559 if test "x$prefix" != xNONE; then
14560 cf_path_syntax="$prefix"
14562 cf_path_syntax="$ac_default_prefix"
14565 case ".$withval" in
14566 (.\$\(*\)*|.\'*\'*)
14570 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
14572 (.\${*prefix}*|.\${*dir}*)
14573 eval withval="$withval"
14574 case ".$withval" in
14576 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
14581 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
14584 { { echo "$as_me:14584: error: expected a pathname, not \"$withval\"" >&5
14585 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
14586 { (exit 1); exit 1; }; }
14591 eval ADA_INCLUDE="$withval"
14593 echo "$as_me:14593: result: $ADA_INCLUDE" >&5
14594 echo "${ECHO_T}$ADA_INCLUDE" >&6
14596 echo "$as_me:14596: checking for ada-objects" >&5
14597 echo $ECHO_N "checking for ada-objects... $ECHO_C" >&6
14599 # Check whether --with-ada-objects or --without-ada-objects was given.
14600 if test "${with_ada_objects+set}" = set; then
14601 withval="$with_ada_objects"
14604 withval="${ADA_OBJECTS:-$prefix/lib/ada/adalib}"
14605 fi; if test -n "$prefix/lib/ada/adalib" ; then
14607 if test "x$prefix" != xNONE; then
14608 cf_path_syntax="$prefix"
14610 cf_path_syntax="$ac_default_prefix"
14613 case ".$withval" in
14614 (.\$\(*\)*|.\'*\'*)
14618 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
14620 (.\${*prefix}*|.\${*dir}*)
14621 eval withval="$withval"
14622 case ".$withval" in
14624 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
14629 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
14632 { { echo "$as_me:14632: error: expected a pathname, not \"$withval\"" >&5
14633 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
14634 { (exit 1); exit 1; }; }
14639 eval ADA_OBJECTS="$withval"
14641 echo "$as_me:14641: result: $ADA_OBJECTS" >&5
14642 echo "${ECHO_T}$ADA_OBJECTS" >&6
14644 echo "$as_me:14644: checking if an Ada95 shared-library should be built" >&5
14645 echo $ECHO_N "checking if an Ada95 shared-library should be built... $ECHO_C" >&6
14647 # Check whether --with-ada-sharedlib or --without-ada-sharedlib was given.
14648 if test "${with_ada_sharedlib+set}" = set; then
14649 withval="$with_ada_sharedlib"
14650 with_ada_sharedlib=$withval
14652 with_ada_sharedlib=no
14654 echo "$as_me:14654: result: $with_ada_sharedlib" >&5
14655 echo "${ECHO_T}$with_ada_sharedlib" >&6
14657 ADA_SHAREDLIB='lib$(LIB_NAME).so.1'
14658 MAKE_ADA_SHAREDLIB="#"
14660 if test "x$with_ada_sharedlib" != xno
14662 MAKE_ADA_SHAREDLIB=
14663 if test "x$with_ada_sharedlib" != xyes
14665 ADA_SHAREDLIB="$with_ada_sharedlib"
14670 { { echo "$as_me:14670: error: No usable Ada compiler found" >&5
14671 echo "$as_me: error: No usable Ada compiler found" >&2;}
14672 { (exit 1); exit 1; }; }
14675 { { echo "$as_me:14675: error: The Ada compiler is needed for this package" >&5
14676 echo "$as_me: error: The Ada compiler is needed for this package" >&2;}
14677 { (exit 1); exit 1; }; }
14680 ################################################################################
14687 ### Construct the list of include-directories to be generated
14689 if test "$srcdir" != "."; then
14690 CPPFLAGS="-I\${srcdir}/../include $CPPFLAGS"
14692 CPPFLAGS="-I../include $CPPFLAGS"
14693 if test "$srcdir" != "."; then
14694 CPPFLAGS="-I\${srcdir} $CPPFLAGS"
14696 CPPFLAGS="-I. $CPPFLAGS"
14698 ACPPFLAGS="-I. -I../include -I../../include $ACPPFLAGS"
14699 if test "$srcdir" != "."; then
14700 ACPPFLAGS="-I\${srcdir}/../../include $ACPPFLAGS"
14702 if test "$GCC" != yes; then
14703 ACPPFLAGS="$ACPPFLAGS -I\${includedir}"
14704 elif test "$includedir" != "/usr/include"; then
14705 if test "$includedir" = '${prefix}/include' ; then
14706 if test x$prefix != x/usr ; then
14707 ACPPFLAGS="$ACPPFLAGS -I\${includedir}"
14710 ACPPFLAGS="$ACPPFLAGS -I\${includedir}"
14714 ### Build up pieces for makefile rules
14715 echo "$as_me:14715: checking default library suffix" >&5
14716 echo $ECHO_N "checking default library suffix... $ECHO_C" >&6
14718 case $DFT_LWR_MODEL in
14719 (libtool) DFT_ARG_SUFFIX='' ;;
14720 (normal) DFT_ARG_SUFFIX='' ;;
14721 (debug) DFT_ARG_SUFFIX='_g' ;;
14722 (profile) DFT_ARG_SUFFIX='_p' ;;
14723 (shared) DFT_ARG_SUFFIX='' ;;
14725 test -n "$LIB_SUFFIX" && DFT_ARG_SUFFIX="${LIB_SUFFIX}${DFT_ARG_SUFFIX}"
14726 echo "$as_me:14726: result: $DFT_ARG_SUFFIX" >&5
14727 echo "${ECHO_T}$DFT_ARG_SUFFIX" >&6
14729 echo "$as_me:14729: checking default library-dependency suffix" >&5
14730 echo $ECHO_N "checking default library-dependency suffix... $ECHO_C" >&6
14732 case X$DFT_LWR_MODEL in
14734 DFT_LIB_SUFFIX='.la'
14735 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14738 DFT_LIB_SUFFIX='_g.a'
14739 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14742 DFT_LIB_SUFFIX='_p.a'
14743 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14746 case $cf_cv_system_name in
14748 DFT_LIB_SUFFIX='.so'
14749 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14751 (cygwin*|msys*|mingw*)
14752 DFT_LIB_SUFFIX='.dll'
14753 DFT_DEP_SUFFIX='.dll.a'
14756 DFT_LIB_SUFFIX='.dylib'
14757 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14762 DFT_LIB_SUFFIX='.so'
14763 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14766 DFT_LIB_SUFFIX='.sl'
14767 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14772 DFT_LIB_SUFFIX='.so'
14773 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14778 DFT_LIB_SUFFIX='.a'
14779 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14782 if test -n "${LIB_SUFFIX}${EXTRA_SUFFIX}"
14784 DFT_LIB_SUFFIX="${LIB_SUFFIX}${EXTRA_SUFFIX}${DFT_LIB_SUFFIX}"
14785 DFT_DEP_SUFFIX="${LIB_SUFFIX}${EXTRA_SUFFIX}${DFT_DEP_SUFFIX}"
14787 echo "$as_me:14787: result: $DFT_DEP_SUFFIX" >&5
14788 echo "${ECHO_T}$DFT_DEP_SUFFIX" >&6
14790 echo "$as_me:14790: checking default object directory" >&5
14791 echo $ECHO_N "checking default object directory... $ECHO_C" >&6
14793 case $DFT_LWR_MODEL in
14794 (libtool) DFT_OBJ_SUBDIR='obj_lo' ;;
14795 (normal) DFT_OBJ_SUBDIR='objects' ;;
14796 (debug) DFT_OBJ_SUBDIR='obj_g' ;;
14797 (profile) DFT_OBJ_SUBDIR='obj_p' ;;
14799 case $cf_cv_system_name in
14801 DFT_OBJ_SUBDIR='objects' ;;
14803 DFT_OBJ_SUBDIR='obj_s' ;;
14806 echo "$as_me:14806: result: $DFT_OBJ_SUBDIR" >&5
14807 echo "${ECHO_T}$DFT_OBJ_SUBDIR" >&6
14809 ### Set up low-level terminfo dependencies for makefiles.
14811 if test "$DFT_LWR_MODEL" = shared ; then
14812 case $cf_cv_system_name in
14814 # "lib" files have ".dll.a" suffix, "cyg" files have ".dll"
14817 # "lib" files have ".dll.a" suffix, "msys-" files have ".dll"
14822 USE_CFG_SUFFIX=${DFT_ARG_SUFFIX}
14824 ### Construct the list of subdirectories for which we'll customize makefiles
14825 ### with the appropriate compile-rules.
14827 SUB_MAKEFILES="gen/adacurses${USE_ARG_SUFFIX}-config:gen/adacurses-config.in"
14829 cat >>confdefs.h <<EOF
14830 #define NCURSES_PATHSEP '$PATH_SEPARATOR'
14833 ### Now that we're done running tests, add the compiler-warnings, if any
14838 cf_new_extra_cppflags=
14840 for cf_add_cflags in $EXTRA_CFLAGS
14842 case $cf_fix_cppflags in
14844 case $cf_add_cflags in
14845 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
14846 case $cf_add_cflags in
14848 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
14850 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14851 && test -z "${cf_tst_cflags}" \
14852 && cf_fix_cppflags=yes
14854 if test $cf_fix_cppflags = yes ; then
14856 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14857 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14860 elif test "${cf_tst_cflags}" = "\"'" ; then
14862 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14863 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14869 case "$CPPFLAGS" in
14873 case $cf_add_cflags in
14875 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
14877 CPPFLAGS=`echo "$CPPFLAGS" | \
14878 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
14879 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
14884 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
14885 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
14892 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
14893 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
14900 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14901 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14903 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
14905 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14906 && test -z "${cf_tst_cflags}" \
14907 && cf_fix_cppflags=no
14912 if test -n "$cf_new_cflags" ; then
14914 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
14915 CFLAGS="${CFLAGS}$cf_new_cflags"
14919 if test -n "$cf_new_cppflags" ; then
14921 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
14922 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
14926 if test -n "$cf_new_extra_cppflags" ; then
14928 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
14929 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
14933 ################################################################################
14939 NCURSES_SHLIB2="sh -c"
14941 ADA_SUBDIRS="include gen src doc"
14942 if test "x$cf_with_tests" != "xno" ; then
14943 ADA_SUBDIRS="$ADA_SUBDIRS samples"
14945 for cf_dir in $ADA_SUBDIRS
14947 SUB_MAKEFILES="$SUB_MAKEFILES $cf_dir/Makefile"
14954 # match layout used by make-tar.sh
14955 ADAHTML_DIR=../doc/ada
14957 if test "x$cross_compiling" = xyes ; then
14958 ADAGEN_LDFLAGS='$(CROSS_LDFLAGS)'
14960 ADAGEN_LDFLAGS='$(NATIVE_LDFLAGS)'
14963 ac_config_files="$ac_config_files $SUB_MAKEFILES doc/adacurses${DFT_ARG_SUFFIX}-config.1:doc/MKada_config.in Makefile"
14964 ac_config_commands="$ac_config_commands default"
14965 cat >confcache <<\_ACEOF
14966 # This file is a shell script that caches the results of configure
14967 # tests run on this system so they can be shared between configure
14968 # scripts and configure runs, see configure's option --config-cache.
14969 # It is not useful on other systems. If it contains results you don't
14970 # want to keep, you may remove or edit it.
14972 # config.status only pays attention to the cache file if you give it
14973 # the --recheck option to rerun configure.
14975 # `ac_cv_env_foo' variables (set or unset) will be overriden when
14976 # loading this file, other *unset* `ac_cv_foo' will be assigned the
14977 # following values.
14981 # The following way of writing the cache mishandles newlines in values,
14982 # but we know of no workaround that is simple, portable, and efficient.
14983 # So, don't put newlines in cache variables' values.
14984 # Ultrix sh set writes to stderr and can't be redirected directly,
14985 # and sets the high bit in the cache file unless we assign to the vars.
14988 case `(ac_space=' '; set | grep ac_space) 2>&1` in
14990 # `set' does not quote correctly, so add quotes (double-quote
14991 # substitution turns \\\\ into \\, and sed turns \\ into \).
14994 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
14997 # `set' quotes correctly as required by POSIX, so do not add quotes.
14999 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
15006 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
15008 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
15010 if cmp -s $cache_file confcache; then :; else
15011 if test -w $cache_file; then
15012 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
15013 cat confcache >$cache_file
15015 echo "not updating unwritable cache $cache_file"
15020 test "x$prefix" = xNONE && prefix=$ac_default_prefix
15021 # Let make expand exec_prefix.
15022 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
15024 # VPATH may cause trouble with some makes, so we remove $(srcdir),
15025 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
15026 # trailing colons and then remove the whole line if VPATH becomes empty
15027 # (actually we leave an empty line to preserve line numbers).
15028 if test "x$srcdir" = x.; then
15029 ac_vpsub='/^[ ]*VPATH[ ]*=/{
15030 s/:*\$(srcdir):*/:/;
15031 s/:*\${srcdir}:*/:/;
15033 s/^\([^=]*=[ ]*\):*/\1/;
15039 DEFS=-DHAVE_CONFIG_H
15041 : ${CONFIG_STATUS=./config.status}
15042 ac_clean_files_save=$ac_clean_files
15043 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
15044 { echo "$as_me:15044: creating $CONFIG_STATUS" >&5
15045 echo "$as_me: creating $CONFIG_STATUS" >&6;}
15046 cat >$CONFIG_STATUS <<_ACEOF
15048 # Generated automatically by configure.
15049 # Run this file to recreate the current configuration.
15050 # Compiler output produced by configure, useful for debugging
15051 # configure, is in config.log if it exists.
15054 SHELL=\${CONFIG_SHELL-$SHELL}
15055 ac_cs_invocation="\$0 \$@"
15059 cat >>$CONFIG_STATUS <<\_ACEOF
15060 # Be Bourne compatible
15061 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
15064 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
15068 # Name of the executable.
15069 as_me=`echo "$0" |sed 's,.*[\\/],,'`
15071 if expr a : '\(a\)' >/dev/null 2>&1; then
15077 rm -f conf$$ conf$$.exe conf$$.file
15079 if ln -s conf$$.file conf$$ 2>/dev/null; then
15080 # We could just check for DJGPP; but this test a) works b) is more generic
15081 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
15082 if test -f conf$$.exe; then
15083 # Don't use ln at all; we don't have any links
15088 elif ln conf$$.file conf$$ 2>/dev/null; then
15093 rm -f conf$$ conf$$.exe conf$$.file
15095 as_executable_p="test -f"
15097 # Support unset when possible.
15098 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
15105 $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
15106 $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
15107 $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
15108 $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
15109 $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
15110 $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
15111 $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
15112 $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
15115 # We need space, tab and new line, in precisely that order.
15121 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
15127 # Files that config.status was made for.
15128 if test -n "$ac_config_files"; then
15129 echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
15132 if test -n "$ac_config_headers"; then
15133 echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
15136 if test -n "$ac_config_links"; then
15137 echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
15140 if test -n "$ac_config_commands"; then
15141 echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
15144 cat >>$CONFIG_STATUS <<\EOF
15147 \`$as_me' instantiates files from templates according to the
15148 current configuration.
15150 Usage: $0 [OPTIONS] [FILE]...
15152 -h, --help print this help, then exit
15153 -V, --version print version number, then exit
15154 -d, --debug don't remove temporary files
15155 --recheck update $as_me by reconfiguring in the same conditions
15156 --file=FILE[:TEMPLATE]
15157 instantiate the configuration file FILE
15158 --header=FILE[:TEMPLATE]
15159 instantiate the configuration header FILE
15161 Configuration files:
15164 Configuration headers:
15167 Configuration commands:
15170 Report bugs to <dickey@invisible-island.net>."
15173 cat >>$CONFIG_STATUS <<EOF
15176 configured by $0, generated by GNU Autoconf 2.52.20170501,
15177 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
15179 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
15180 Free Software Foundation, Inc.
15181 This config.status script is free software; the Free Software Foundation
15182 gives unlimited permission to copy, distribute and modify it."
15187 cat >>$CONFIG_STATUS <<\EOF
15188 # If no file are specified by the user, then we need to provide default
15189 # value. By we need to know if files were specified by the user.
15195 ac_option=`expr "x$1" : 'x\([^=]*\)='`
15196 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
15198 set dummy "$ac_option" "$ac_optarg" ${1+"$@"}
15202 *) # This is not an option, so the user has probably given explicit
15204 ac_need_defaults=false;;
15208 # Handling of the options.
15210 cat >>$CONFIG_STATUS <<EOF
15211 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
15212 echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion"
15213 exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;;
15215 cat >>$CONFIG_STATUS <<\EOF
15216 --version | --vers* | -V )
15217 echo "$ac_cs_version"; exit 0 ;;
15219 # Conflict between --help and --header
15220 { { echo "$as_me:15220: error: ambiguous option: $1
15221 Try \`$0 --help' for more information." >&5
15222 echo "$as_me: error: ambiguous option: $1
15223 Try \`$0 --help' for more information." >&2;}
15224 { (exit 1); exit 1; }; };;
15225 --help | --hel | -h )
15226 echo "$ac_cs_usage"; exit 0 ;;
15227 --debug | --d* | -d )
15229 --file | --fil | --fi | --f )
15231 CONFIG_FILES="$CONFIG_FILES $1"
15232 ac_need_defaults=false;;
15233 --header | --heade | --head | --hea )
15235 CONFIG_HEADERS="$CONFIG_HEADERS $1"
15236 ac_need_defaults=false;;
15238 # This is an error.
15239 -*) { { echo "$as_me:15239: error: unrecognized option: $1
15240 Try \`$0 --help' for more information." >&5
15241 echo "$as_me: error: unrecognized option: $1
15242 Try \`$0 --help' for more information." >&2;}
15243 { (exit 1); exit 1; }; } ;;
15245 *) ac_config_targets="$ac_config_targets $1" ;;
15254 ## ----------------------- ##
15255 ## Running config.status. ##
15256 ## ----------------------- ##
15258 This file was extended by $as_me 2.52.20170501, executed with
15259 CONFIG_FILES = $CONFIG_FILES
15260 CONFIG_HEADERS = $CONFIG_HEADERS
15261 CONFIG_LINKS = $CONFIG_LINKS
15262 CONFIG_COMMANDS = $CONFIG_COMMANDS
15263 > $ac_cs_invocation
15264 on `(hostname || uname -n) 2>/dev/null | sed 1q`
15269 cat >>$CONFIG_STATUS <<EOF
15271 # INIT-COMMANDS section.
15274 ### Special initialization commands, used to pass information from the
15275 ### configuration-run into config.status
15278 DFT_ARG_SUFFIX="$DFT_ARG_SUFFIX"
15279 DFT_LWR_MODEL="$DFT_LWR_MODEL"
15280 LIB_NAME="$LIB_NAME"
15281 LIB_PREFIX="$LIB_PREFIX"
15282 LIB_SUFFIX="$LIB_SUFFIX"
15284 NCURSES_MAJOR="$NCURSES_MAJOR"
15285 NCURSES_MINOR="$NCURSES_MINOR"
15286 NCURSES_PATCH="$NCURSES_PATCH"
15287 USE_OLD_MAKERULES="$USE_OLD_MAKERULES"
15288 cf_cv_abi_version="$cf_cv_abi_version"
15289 cf_cv_rel_version="$cf_cv_rel_version"
15290 cf_cv_rm_so_locs="$cf_cv_rm_so_locs"
15291 cf_cv_shared_soname='$cf_cv_shared_soname'
15292 cf_cv_shlib_version="$cf_cv_shlib_version"
15293 cf_cv_shlib_version_infix="$cf_cv_shlib_version_infix"
15294 cf_cv_system_name="$cf_cv_system_name"
15300 cat >>$CONFIG_STATUS <<\EOF
15301 for ac_config_target in $ac_config_targets
15303 case "$ac_config_target" in
15304 # Handling of arguments.
15305 "$SUB_MAKEFILES" ) CONFIG_FILES="$CONFIG_FILES $SUB_MAKEFILES" ;;
15306 "doc/adacurses${DFT_ARG_SUFFIX}-config.1" ) CONFIG_FILES="$CONFIG_FILES doc/adacurses${DFT_ARG_SUFFIX}-config.1:doc/MKada_config.in" ;;
15307 "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
15308 "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
15309 "include/ncurses_cfg.h" ) CONFIG_HEADERS="$CONFIG_HEADERS include/ncurses_cfg.h:include/ncurses_cfg.hin" ;;
15310 *) { { echo "$as_me:15310: error: invalid argument: $ac_config_target" >&5
15311 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
15312 { (exit 1); exit 1; }; };;
15316 # If the user did not use the arguments to specify the items to instantiate,
15317 # then the envvar interface is used. Set only those that are not.
15318 # We use the long form for the default assignment because of an extremely
15319 # bizarre bug on SunOS 4.1.3.
15320 if $ac_need_defaults; then
15321 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
15322 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
15323 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
15326 # Create a temporary directory, and hook for its removal unless debugging.
15329 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
15330 trap '{ (exit 1); exit 1; }' 1 2 13 15
15333 # Create a (secure) tmp directory for tmp files.
15336 tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` &&
15337 test -n "$tmp" && test -d "$tmp"
15340 tmp=$TMPDIR/cs$$-$RANDOM
15341 (umask 077 && mkdir $tmp)
15344 echo "$me: cannot create a temporary directory in $TMPDIR" >&2
15345 { (exit 1); exit 1; }
15350 cat >>$CONFIG_STATUS <<EOF
15353 # CONFIG_FILES section.
15356 # No need to generate the scripts if there are no CONFIG_FILES.
15357 # This happens for instance when ./config.status config.h
15358 if test -n "\$CONFIG_FILES"; then
15359 # Protect against being on the right side of a sed subst in config.status.
15360 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
15361 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
15362 s,@SHELL@,$SHELL,;t t
15363 s,@exec_prefix@,$exec_prefix,;t t
15364 s,@prefix@,$prefix,;t t
15365 s,@program_transform_name@,$program_transform_name,;t t
15366 s,@bindir@,$bindir,;t t
15367 s,@sbindir@,$sbindir,;t t
15368 s,@libexecdir@,$libexecdir,;t t
15369 s,@datarootdir@,$datarootdir,;t t
15370 s,@datadir@,$datadir,;t t
15371 s,@sysconfdir@,$sysconfdir,;t t
15372 s,@sharedstatedir@,$sharedstatedir,;t t
15373 s,@localstatedir@,$localstatedir,;t t
15374 s,@libdir@,$libdir,;t t
15375 s,@includedir@,$includedir,;t t
15376 s,@oldincludedir@,$oldincludedir,;t t
15377 s,@infodir@,$infodir,;t t
15378 s,@mandir@,$mandir,;t t
15379 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
15380 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
15381 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
15382 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
15383 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
15384 s,@build_alias@,$build_alias,;t t
15385 s,@host_alias@,$host_alias,;t t
15386 s,@target_alias@,$target_alias,;t t
15387 s,@ECHO_C@,$ECHO_C,;t t
15388 s,@ECHO_N@,$ECHO_N,;t t
15389 s,@ECHO_T@,$ECHO_T,;t t
15390 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
15391 s,@DEFS@,$DEFS,;t t
15392 s,@LIBS@,$LIBS,;t t
15393 s,@top_builddir@,$top_builddir,;t t
15394 s,@build@,$build,;t t
15395 s,@build_cpu@,$build_cpu,;t t
15396 s,@build_vendor@,$build_vendor,;t t
15397 s,@build_os@,$build_os,;t t
15398 s,@host@,$host,;t t
15399 s,@host_cpu@,$host_cpu,;t t
15400 s,@host_vendor@,$host_vendor,;t t
15401 s,@host_os@,$host_os,;t t
15402 s,@target@,$target,;t t
15403 s,@target_cpu@,$target_cpu,;t t
15404 s,@target_vendor@,$target_vendor,;t t
15405 s,@target_os@,$target_os,;t t
15407 s,@CFLAGS@,$CFLAGS,;t t
15408 s,@LDFLAGS@,$LDFLAGS,;t t
15409 s,@CPPFLAGS@,$CPPFLAGS,;t t
15410 s,@ac_ct_CC@,$ac_ct_CC,;t t
15411 s,@EXEEXT@,$EXEEXT,;t t
15412 s,@OBJEXT@,$OBJEXT,;t t
15413 s,@EXTRA_CPPFLAGS@,$EXTRA_CPPFLAGS,;t t
15416 s,@EGREP@,$EGREP,;t t
15417 s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
15418 s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
15419 s,@INSTALL_DATA@,$INSTALL_DATA,;t t
15420 s,@LN_S@,$LN_S,;t t
15421 s,@PKG_CONFIG@,$PKG_CONFIG,;t t
15422 s,@ac_pt_PKG_CONFIG@,$ac_pt_PKG_CONFIG,;t t
15423 s,@PKG_CONFIG_LIBDIR@,$PKG_CONFIG_LIBDIR,;t t
15424 s,@SET_MAKE@,$SET_MAKE,;t t
15425 s,@CTAGS@,$CTAGS,;t t
15426 s,@ETAGS@,$ETAGS,;t t
15427 s,@MAKE_LOWER_TAGS@,$MAKE_LOWER_TAGS,;t t
15428 s,@MAKE_UPPER_TAGS@,$MAKE_UPPER_TAGS,;t t
15429 s,@cf_cv_makeflags@,$cf_cv_makeflags,;t t
15430 s,@RANLIB@,$RANLIB,;t t
15431 s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
15433 s,@ac_ct_LD@,$ac_ct_LD,;t t
15435 s,@ac_ct_AR@,$ac_ct_AR,;t t
15436 s,@ARFLAGS@,$ARFLAGS,;t t
15437 s,@DESTDIR@,$DESTDIR,;t t
15438 s,@BUILD_CC@,$BUILD_CC,;t t
15439 s,@BUILD_CPP@,$BUILD_CPP,;t t
15440 s,@BUILD_CFLAGS@,$BUILD_CFLAGS,;t t
15441 s,@BUILD_CPPFLAGS@,$BUILD_CPPFLAGS,;t t
15442 s,@BUILD_LDFLAGS@,$BUILD_LDFLAGS,;t t
15443 s,@BUILD_LIBS@,$BUILD_LIBS,;t t
15444 s,@BUILD_EXEEXT@,$BUILD_EXEEXT,;t t
15445 s,@BUILD_OBJEXT@,$BUILD_OBJEXT,;t t
15446 s,@DFT_LWR_MODEL@,$DFT_LWR_MODEL,;t t
15447 s,@DFT_UPR_MODEL@,$DFT_UPR_MODEL,;t t
15448 s,@NCURSES_CONFIG@,$NCURSES_CONFIG,;t t
15449 s,@ac_ct_NCURSES_CONFIG@,$ac_ct_NCURSES_CONFIG,;t t
15450 s,@NCURSES_MAJOR@,$NCURSES_MAJOR,;t t
15451 s,@NCURSES_MINOR@,$NCURSES_MINOR,;t t
15452 s,@NCURSES_PATCH@,$NCURSES_PATCH,;t t
15453 s,@cf_cv_rel_version@,$cf_cv_rel_version,;t t
15454 s,@cf_cv_abi_version@,$cf_cv_abi_version,;t t
15455 s,@cf_cv_builtin_bool@,$cf_cv_builtin_bool,;t t
15456 s,@cf_cv_header_stdbool_h@,$cf_cv_header_stdbool_h,;t t
15457 s,@cf_cv_type_of_bool@,$cf_cv_type_of_bool,;t t
15458 s,@LIB_PREFIX@,$LIB_PREFIX,;t t
15459 s,@LIB_SUFFIX@,$LIB_SUFFIX,;t t
15460 s,@CC_G_OPT@,$CC_G_OPT,;t t
15461 s,@LD_MODEL@,$LD_MODEL,;t t
15462 s,@shlibdir@,$shlibdir,;t t
15463 s,@MAKE_DLLS@,$MAKE_DLLS,;t t
15464 s,@CC_SHARED_OPTS@,$CC_SHARED_OPTS,;t t
15465 s,@LD_RPATH_OPT@,$LD_RPATH_OPT,;t t
15466 s,@LD_SHARED_OPTS@,$LD_SHARED_OPTS,;t t
15467 s,@MK_SHARED_LIB@,$MK_SHARED_LIB,;t t
15468 s,@RM_SHARED_OPTS@,$RM_SHARED_OPTS,;t t
15469 s,@LINK_PROGS@,$LINK_PROGS,;t t
15470 s,@LINK_TESTS@,$LINK_TESTS,;t t
15471 s,@EXTRA_LDFLAGS@,$EXTRA_LDFLAGS,;t t
15472 s,@LOCAL_LDFLAGS@,$LOCAL_LDFLAGS,;t t
15473 s,@LOCAL_LDFLAGS2@,$LOCAL_LDFLAGS2,;t t
15474 s,@INSTALL_LIB@,$INSTALL_LIB,;t t
15475 s,@RPATH_LIST@,$RPATH_LIST,;t t
15476 s,@BROKEN_LINKER@,$BROKEN_LINKER,;t t
15477 s,@NCURSES_EXT_FUNCS@,$NCURSES_EXT_FUNCS,;t t
15478 s,@NCURSES_CONST@,$NCURSES_CONST,;t t
15479 s,@PTHREAD@,$PTHREAD,;t t
15480 s,@cf_cv_enable_reentrant@,$cf_cv_enable_reentrant,;t t
15481 s,@NCURSES_WRAP_PREFIX@,$NCURSES_WRAP_PREFIX,;t t
15482 s,@ECHO_LT@,$ECHO_LT,;t t
15483 s,@ECHO_LD@,$ECHO_LD,;t t
15484 s,@RULE_CC@,$RULE_CC,;t t
15485 s,@SHOW_CC@,$SHOW_CC,;t t
15486 s,@ECHO_CC@,$ECHO_CC,;t t
15487 s,@ADAFLAGS@,$ADAFLAGS,;t t
15488 s,@EXTRA_CFLAGS@,$EXTRA_CFLAGS,;t t
15489 s,@ADA_TRACE@,$ADA_TRACE,;t t
15490 s,@gnat_exists@,$gnat_exists,;t t
15491 s,@M4_exists@,$M4_exists,;t t
15492 s,@cf_ada_make@,$cf_ada_make,;t t
15493 s,@GNATPREP_OPTS@,$GNATPREP_OPTS,;t t
15494 s,@cf_compile_generics@,$cf_compile_generics,;t t
15495 s,@cf_generic_objects@,$cf_generic_objects,;t t
15496 s,@USE_GNAT_SIGINT@,$USE_GNAT_SIGINT,;t t
15497 s,@USE_OLD_MAKERULES@,$USE_OLD_MAKERULES,;t t
15498 s,@USE_GNAT_PROJECTS@,$USE_GNAT_PROJECTS,;t t
15499 s,@USE_GNAT_LIBRARIES@,$USE_GNAT_LIBRARIES,;t t
15500 s,@cf_ada_compiler@,$cf_ada_compiler,;t t
15501 s,@cf_ada_package@,$cf_ada_package,;t t
15502 s,@ADA_INCLUDE@,$ADA_INCLUDE,;t t
15503 s,@ADA_OBJECTS@,$ADA_OBJECTS,;t t
15504 s,@ADA_SHAREDLIB@,$ADA_SHAREDLIB,;t t
15505 s,@MAKE_ADA_SHAREDLIB@,$MAKE_ADA_SHAREDLIB,;t t
15506 s,@TINFO_LDFLAGS2@,$TINFO_LDFLAGS2,;t t
15507 s,@TINFO_LIBS@,$TINFO_LIBS,;t t
15508 s,@ACPPFLAGS@,$ACPPFLAGS,;t t
15509 s,@DFT_ARG_SUFFIX@,$DFT_ARG_SUFFIX,;t t
15510 s,@DFT_DEP_SUFFIX@,$DFT_DEP_SUFFIX,;t t
15511 s,@DFT_OBJ_SUBDIR@,$DFT_OBJ_SUBDIR,;t t
15512 s,@USE_CFG_SUFFIX@,$USE_CFG_SUFFIX,;t t
15513 s,@TEST_ARG2@,$TEST_ARG2,;t t
15514 s,@TEST_LIBS2@,$TEST_LIBS2,;t t
15515 s,@NCURSES_SHLIB2@,$NCURSES_SHLIB2,;t t
15516 s,@ADA_SUBDIRS@,$ADA_SUBDIRS,;t t
15517 s,@NCURSES_TREE@,$NCURSES_TREE,;t t
15518 s,@EXTERNAL_TREE@,$EXTERNAL_TREE,;t t
15519 s,@ADAHTML_DIR@,$ADAHTML_DIR,;t t
15520 s,@ADAGEN_LDFLAGS@,$ADAGEN_LDFLAGS,;t t
15525 cat >>$CONFIG_STATUS <<\EOF
15526 # Split the substitutions into bite-sized pieces for seds with
15527 # small command number limits, like on Digital OSF/1 and HP-UX.
15528 ac_max_sed_lines=48
15529 ac_sed_frag=1 # Number of current file.
15530 ac_beg=1 # First line for current file.
15531 ac_end=$ac_max_sed_lines # Line after last line for current file.
15534 while $ac_more_lines; do
15535 if test $ac_beg -gt 1; then
15536 sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
15538 sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
15540 if test ! -s $tmp/subs.frag; then
15541 ac_more_lines=false
15543 # The purpose of the label and of the branching condition is to
15544 # speed up the sed processing (if there are no `@' at all, there
15545 # is no need to browse any of the substitutions).
15546 # These are the two extra sed commands mentioned above.
15548 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
15549 # It is possible to make a multiline substitution using escaped newlines.
15550 # Ensure that we do not split the substitution between script fragments.
15552 ac_END=`expr $ac_end + $ac_max_sed_lines`
15553 sed "1,${ac_BEG}d; ${ac_END}p; q" $tmp/subs.sed >$tmp/subs.next
15554 if test -s $tmp/subs.next; then
15555 grep '^s,@[^@,][^@,]*@,.*\\$' $tmp/subs.next >$tmp/subs.edit
15556 if test ! -s $tmp/subs.edit; then
15557 grep "^s,@[^@,][^@,]*@,.*,;t t$" $tmp/subs.next >$tmp/subs.edit
15558 if test ! -s $tmp/subs.edit; then
15559 if test $ac_beg -gt 1; then
15560 ac_end=`expr $ac_end - 1`
15567 if test -z "$ac_sed_cmds"; then
15568 ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
15570 ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
15572 ac_sed_frag=`expr $ac_sed_frag + 1`
15574 ac_end=`expr $ac_end + $ac_max_sed_lines`
15577 if test -z "$ac_sed_cmds"; then
15580 fi # test -n "$CONFIG_FILES"
15583 cat >>$CONFIG_STATUS <<\EOF
15584 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
15585 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
15587 - | *:- | *:-:* ) # input from stdin
15589 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
15590 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
15591 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
15592 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
15593 * ) ac_file_in=$ac_file.in ;;
15596 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
15597 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
15598 X"$ac_file" : 'X\(//\)[^/]' \| \
15599 X"$ac_file" : 'X\(//\)$' \| \
15600 X"$ac_file" : 'X\(/\)' \| \
15601 . : '\(.\)' 2>/dev/null ||
15603 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
15604 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
15605 /^X\(\/\/\)$/{ s//\1/; q; }
15606 /^X\(\/\).*/{ s//\1/; q; }
15608 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
15609 { case "$ac_dir" in
15610 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
15614 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
15615 case $as_mkdir_dir in
15616 # Skip DOS drivespec
15617 ?:) as_incr_dir=$as_mkdir_dir ;;
15619 as_incr_dir=$as_incr_dir/$as_mkdir_dir
15620 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
15625 ac_dir_suffix="/`echo $ac_dir|sed 's,^\./,,'`"
15626 # A "../" for each directory in $ac_dir_suffix.
15627 ac_dots=`echo "$ac_dir_suffix" | sed 's,/[^/]*,../,g'`
15629 ac_dir_suffix= ac_dots=
15634 if test -z "$ac_dots"; then
15637 ac_top_srcdir=`echo $ac_dots | sed 's,/$,,'`
15639 [\\/]* | ?:[\\/]* )
15640 ac_srcdir=$srcdir$ac_dir_suffix;
15641 ac_top_srcdir=$srcdir ;;
15642 *) # Relative path.
15643 ac_srcdir=$ac_dots$srcdir$ac_dir_suffix
15644 ac_top_srcdir=$ac_dots$srcdir ;;
15648 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
15649 *) ac_INSTALL=$ac_dots$INSTALL ;;
15652 if test x"$ac_file" != x-; then
15653 { echo "$as_me:15653: creating $ac_file" >&5
15654 echo "$as_me: creating $ac_file" >&6;}
15657 # Let's still pretend it is `configure' which instantiates (i.e., don't
15658 # use $as_me), people would be surprised to read:
15659 # /* config.h. Generated automatically by config.status. */
15660 configure_input="Generated automatically from `echo $ac_file_in |
15661 sed 's,.*/,,'` by configure."
15663 # First look for the input files in the build tree, otherwise in the
15665 ac_file_inputs=`IFS=:
15666 for f in $ac_file_in; do
15668 -) echo $tmp/stdin ;;
15670 # Absolute (can't be DOS-style, as IFS=:)
15671 test -f "$f" || { { echo "$as_me:15671: error: cannot find input file: $f" >&5
15672 echo "$as_me: error: cannot find input file: $f" >&2;}
15673 { (exit 1); exit 1; }; }
15676 if test -f "$f"; then
15679 elif test -f "$srcdir/$f"; then
15684 { { echo "$as_me:15684: error: cannot find input file: $f" >&5
15685 echo "$as_me: error: cannot find input file: $f" >&2;}
15686 { (exit 1); exit 1; }; }
15689 done` || { (exit 1); exit 1; }
15691 cat >>$CONFIG_STATUS <<\EOF
15692 ac_warn_datarootdir=no
15693 if test x"$ac_file" != x-; then
15694 for ac_item in $ac_file_inputs
15696 ac_seen=`grep '@\(datadir\|mandir\|infodir\)@' $ac_item`
15697 if test -n "$ac_seen"; then
15698 ac_used=`grep '@datarootdir@' $ac_item`
15699 if test -z "$ac_used"; then
15700 { echo "$as_me:15700: WARNING: datarootdir was used implicitly but not set:
15702 echo "$as_me: WARNING: datarootdir was used implicitly but not set:
15704 ac_warn_datarootdir=yes
15707 ac_seen=`grep '${datarootdir}' $ac_item`
15708 if test -n "$ac_seen"; then
15709 { echo "$as_me:15709: WARNING: datarootdir was used explicitly but not set:
15711 echo "$as_me: WARNING: datarootdir was used explicitly but not set:
15713 ac_warn_datarootdir=yes
15718 if test "x$ac_warn_datarootdir" = xyes; then
15719 ac_sed_cmds="$ac_sed_cmds | sed -e 's,@datarootdir@,\${prefix}/share,g' -e 's,\${datarootdir},\${prefix}/share,g'"
15723 cat >>$CONFIG_STATUS <<EOF
15727 cat >>$CONFIG_STATUS <<\EOF
15729 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
15730 s,@configure_input@,$configure_input,;t t
15731 s,@srcdir@,$ac_srcdir,;t t
15732 s,@top_srcdir@,$ac_top_srcdir,;t t
15733 s,@INSTALL@,$ac_INSTALL,;t t
15734 " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
15736 if test x"$ac_file" != x-; then
15737 cp $tmp/out $ac_file
15739 for ac_name in prefix exec_prefix datarootdir
15741 ac_seen=`fgrep -n '${'$ac_name'[:=].*}' $ac_file`
15742 if test -n "$ac_seen"; then
15743 ac_init=`egrep '[ ]*'$ac_name'[ ]*=' $ac_file`
15744 if test -z "$ac_init"; then
15745 ac_seen=`echo "$ac_seen" |sed -e 's,^,'$ac_file':,'`
15746 { echo "$as_me:15746: WARNING: Variable $ac_name is used but was not set:
15748 echo "$as_me: WARNING: Variable $ac_name is used but was not set:
15753 egrep -n '@[a-z_][a-z_0-9]+@' $ac_file >$tmp/out
15754 egrep -n '@[A-Z_][A-Z_0-9]+@' $ac_file >>$tmp/out
15755 if test -s $tmp/out; then
15756 ac_seen=`sed -e 's,^,'$ac_file':,' < $tmp/out`
15757 { echo "$as_me:15757: WARNING: Some variables may not be substituted:
15759 echo "$as_me: WARNING: Some variables may not be substituted:
15769 cat >>$CONFIG_STATUS <<\EOF
15772 # CONFIG_HEADER section.
15775 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
15776 # NAME is the cpp macro being defined and VALUE is the value it is being given.
15778 # ac_d sets the value in "#define NAME VALUE" lines.
15779 ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
15780 ac_dB='[ ].*$,\1#\2'
15783 # ac_i turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
15784 ac_iA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
15785 ac_iB='\([ ]\),\1#\2define\3'
15788 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
15789 ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
15790 ac_uB='$,\1#\2define\3'
15794 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
15795 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
15797 - | *:- | *:-:* ) # input from stdin
15799 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
15800 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
15801 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
15802 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
15803 * ) ac_file_in=$ac_file.in ;;
15806 test x"$ac_file" != x- && { echo "$as_me:15806: creating $ac_file" >&5
15807 echo "$as_me: creating $ac_file" >&6;}
15809 # First look for the input files in the build tree, otherwise in the
15811 ac_file_inputs=`IFS=:
15812 for f in $ac_file_in; do
15814 -) echo $tmp/stdin ;;
15816 # Absolute (can't be DOS-style, as IFS=:)
15817 test -f "$f" || { { echo "$as_me:15817: error: cannot find input file: $f" >&5
15818 echo "$as_me: error: cannot find input file: $f" >&2;}
15819 { (exit 1); exit 1; }; }
15822 if test -f "$f"; then
15825 elif test -f "$srcdir/$f"; then
15830 { { echo "$as_me:15830: error: cannot find input file: $f" >&5
15831 echo "$as_me: error: cannot find input file: $f" >&2;}
15832 { (exit 1); exit 1; }; }
15835 done` || { (exit 1); exit 1; }
15836 # Remove the trailing spaces.
15837 sed 's/[ ]*$//' $ac_file_inputs >$tmp/in
15841 # Transform confdefs.h into a list of #define's. We won't use it as a sed
15842 # script, but as data to insert where we see @DEFS@. We expect AC_SAVE_DEFS to
15843 # be either 'cat' or 'sort'.
15844 cat confdefs.h | uniq >conftest.vals
15846 # Break up conftest.vals because some shells have a limit on
15847 # the size of here documents, and old seds have small limits too.
15849 rm -f conftest.tail
15850 echo ' rm -f conftest.frag' >> $CONFIG_STATUS
15851 while grep . conftest.vals >/dev/null
15853 # Write chunks of a limited-size here document to conftest.frag.
15854 echo ' cat >> conftest.frag <<CEOF' >> $CONFIG_STATUS
15855 sed ${ac_max_here_lines}q conftest.vals | sed -e 's/#ifdef.*/#if 0/' >> $CONFIG_STATUS
15856 echo 'CEOF' >> $CONFIG_STATUS
15857 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
15858 rm -f conftest.vals
15859 mv conftest.tail conftest.vals
15861 rm -f conftest.vals
15863 # Run sed to substitute the contents of conftest.frag into $tmp/in at the
15865 echo ' cat >> conftest.edit <<CEOF
15866 /@DEFS@/r conftest.frag
15869 sed -f conftest.edit $tmp/in > $tmp/out
15871 mv $tmp/out $tmp/in
15872 rm -f conftest.edit conftest.frag
15873 ' >> $CONFIG_STATUS
15875 cat >>$CONFIG_STATUS <<\EOF
15876 # Let's still pretend it is `configure' which instantiates (i.e., don't
15877 # use $as_me), people would be surprised to read:
15878 # /* config.h. Generated automatically by config.status. */
15879 if test x"$ac_file" = x-; then
15880 echo "/* Generated automatically by configure. */" >$tmp/config.h
15882 echo "/* $ac_file. Generated automatically by configure. */" >$tmp/config.h
15884 cat $tmp/in >>$tmp/config.h
15886 if test x"$ac_file" != x-; then
15887 if cmp -s $ac_file $tmp/config.h 2>/dev/null; then
15888 { echo "$as_me:15888: $ac_file is unchanged" >&5
15889 echo "$as_me: $ac_file is unchanged" >&6;}
15891 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
15892 X"$ac_file" : 'X\(//\)[^/]' \| \
15893 X"$ac_file" : 'X\(//\)$' \| \
15894 X"$ac_file" : 'X\(/\)' \| \
15895 . : '\(.\)' 2>/dev/null ||
15897 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
15898 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
15899 /^X\(\/\/\)$/{ s//\1/; q; }
15900 /^X\(\/\).*/{ s//\1/; q; }
15902 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
15903 { case "$ac_dir" in
15904 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
15908 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
15909 case $as_mkdir_dir in
15910 # Skip DOS drivespec
15911 ?:) as_incr_dir=$as_mkdir_dir ;;
15913 as_incr_dir=$as_incr_dir/$as_mkdir_dir
15914 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
15921 mv $tmp/config.h $ac_file
15925 rm -f $tmp/config.h
15929 cat >>$CONFIG_STATUS <<\EOF
15931 # CONFIG_COMMANDS section.
15933 for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
15934 ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
15935 ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
15939 if test -z "$USE_OLD_MAKERULES" ; then
15940 $AWK -f $srcdir/mk-1st.awk <$srcdir/src/modules >>src/Makefile
15947 cat >>$CONFIG_STATUS <<\EOF
15949 { (exit 0); exit 0; }
15951 chmod +x $CONFIG_STATUS
15952 ac_clean_files=$ac_clean_files_save
15954 # configure is writing to config.log, and then calls config.status.
15955 # config.status does its own redirection, appending to config.log.
15956 # Unfortunately, on DOS this fails, as config.log is still kept open
15957 # by configure, so config.status won't be able to write to it; its
15958 # output is simply discarded. So we exec the FD to /dev/null,
15959 # effectively closing config.log, so it can be properly (re)opened and
15960 # appended to by config.status. When coming back to configure, we
15961 # need to make the FD available again.
15962 if test "$no_create" != yes; then
15965 $SHELL $CONFIG_STATUS || ac_cs_success=false
15967 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
15968 # would make configure fail if this is the last instruction.
15969 $ac_cs_success || { (exit 1); exit 1; }
15971 ${MAKE:-make} preinstall