2 # From configure.in Revision: 1.62 .
3 # Guess values for system-dependent variables and create Makefiles.
4 # Generated by Autoconf 2.52.20150926.
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.20150926. 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
3846 echo "$as_me:3846: result: no" >&5
3847 echo "${ECHO_T}no" >&6
3848 NCURSES_CONFIG_PKG=none
3851 NCURSES_CONFIG_PKG=none
3854 if test "x$cf_have_ncuconfig" = "xno"; then
3855 echo "Looking for ${cf_ncuconfig_root}-config"
3857 if test -n "$ac_tool_prefix"; then
3858 for ac_prog in ${cf_ncuconfig_root}-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
3860 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3861 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3862 echo "$as_me:3862: checking for $ac_word" >&5
3863 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3864 if test "${ac_cv_prog_NCURSES_CONFIG+set}" = set; then
3865 echo $ECHO_N "(cached) $ECHO_C" >&6
3867 if test -n "$NCURSES_CONFIG"; then
3868 ac_cv_prog_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test.
3870 ac_save_IFS=$IFS; IFS=$ac_path_separator
3872 for ac_dir in $ac_dummy; do
3874 test -z "$ac_dir" && ac_dir=.
3875 $as_executable_p "$ac_dir/$ac_word" || continue
3876 ac_cv_prog_NCURSES_CONFIG="$ac_tool_prefix$ac_prog"
3877 echo "$as_me:3877: found $ac_dir/$ac_word" >&5
3883 NCURSES_CONFIG=$ac_cv_prog_NCURSES_CONFIG
3884 if test -n "$NCURSES_CONFIG"; then
3885 echo "$as_me:3885: result: $NCURSES_CONFIG" >&5
3886 echo "${ECHO_T}$NCURSES_CONFIG" >&6
3888 echo "$as_me:3888: result: no" >&5
3889 echo "${ECHO_T}no" >&6
3892 test -n "$NCURSES_CONFIG" && break
3895 if test -z "$NCURSES_CONFIG"; then
3896 ac_ct_NCURSES_CONFIG=$NCURSES_CONFIG
3897 for ac_prog in ${cf_ncuconfig_root}-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
3899 # Extract the first word of "$ac_prog", so it can be a program name with args.
3900 set dummy $ac_prog; ac_word=$2
3901 echo "$as_me:3901: checking for $ac_word" >&5
3902 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3903 if test "${ac_cv_prog_ac_ct_NCURSES_CONFIG+set}" = set; then
3904 echo $ECHO_N "(cached) $ECHO_C" >&6
3906 if test -n "$ac_ct_NCURSES_CONFIG"; then
3907 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_ct_NCURSES_CONFIG" # Let the user override the test.
3909 ac_save_IFS=$IFS; IFS=$ac_path_separator
3911 for ac_dir in $ac_dummy; do
3913 test -z "$ac_dir" && ac_dir=.
3914 $as_executable_p "$ac_dir/$ac_word" || continue
3915 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_prog"
3916 echo "$as_me:3916: found $ac_dir/$ac_word" >&5
3922 ac_ct_NCURSES_CONFIG=$ac_cv_prog_ac_ct_NCURSES_CONFIG
3923 if test -n "$ac_ct_NCURSES_CONFIG"; then
3924 echo "$as_me:3924: result: $ac_ct_NCURSES_CONFIG" >&5
3925 echo "${ECHO_T}$ac_ct_NCURSES_CONFIG" >&6
3927 echo "$as_me:3927: result: no" >&5
3928 echo "${ECHO_T}no" >&6
3931 test -n "$ac_ct_NCURSES_CONFIG" && break
3933 test -n "$ac_ct_NCURSES_CONFIG" || ac_ct_NCURSES_CONFIG="none"
3935 NCURSES_CONFIG=$ac_ct_NCURSES_CONFIG
3938 if test "$NCURSES_CONFIG" != none ; then
3940 CPPFLAGS="$CPPFLAGS `$NCURSES_CONFIG --cflags`"
3942 cf_add_libs="`$NCURSES_CONFIG --libs`"
3943 # Filter out duplicates - this happens with badly-designed ".pc" files...
3944 for cf_add_1lib in $LIBS
3946 for cf_add_2lib in $cf_add_libs
3948 if test "x$cf_add_1lib" = "x$cf_add_2lib"
3954 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
3958 # even with config script, some packages use no-override for curses.h
3960 echo "$as_me:3960: checking if we have identified curses headers" >&5
3961 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
3962 if test "${cf_cv_ncurses_header+set}" = set; then
3963 echo $ECHO_N "(cached) $ECHO_C" >&6
3966 cf_cv_ncurses_header=none
3968 ncurses.h ncurses/ncurses.h \
3969 curses.h ncurses/curses.h
3971 cat >conftest.$ac_ext <<_ACEOF
3972 #line 3972 "configure"
3973 #include "confdefs.h"
3974 #include <${cf_header}>
3978 initscr(); tgoto("?", 0,0)
3983 rm -f conftest.$ac_objext
3984 if { (eval echo "$as_me:3984: \"$ac_compile\"") >&5
3985 (eval $ac_compile) 2>&5
3987 echo "$as_me:3987: \$? = $ac_status" >&5
3988 (exit $ac_status); } &&
3989 { ac_try='test -s conftest.$ac_objext'
3990 { (eval echo "$as_me:3990: \"$ac_try\"") >&5
3993 echo "$as_me:3993: \$? = $ac_status" >&5
3994 (exit $ac_status); }; }; then
3995 cf_cv_ncurses_header=$cf_header; break
3997 echo "$as_me: failed program was:" >&5
3998 cat conftest.$ac_ext >&5
4000 rm -f conftest.$ac_objext conftest.$ac_ext
4004 echo "$as_me:4004: result: $cf_cv_ncurses_header" >&5
4005 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
4007 if test "$cf_cv_ncurses_header" = none ; then
4008 { { echo "$as_me:4008: error: No curses header-files found" >&5
4009 echo "$as_me: error: No curses header-files found" >&2;}
4010 { (exit 1); exit 1; }; }
4013 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
4015 for ac_header in $cf_cv_ncurses_header
4017 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
4018 echo "$as_me:4018: checking for $ac_header" >&5
4019 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4020 if eval "test \"\${$as_ac_Header+set}\" = set"; then
4021 echo $ECHO_N "(cached) $ECHO_C" >&6
4023 cat >conftest.$ac_ext <<_ACEOF
4024 #line 4024 "configure"
4025 #include "confdefs.h"
4026 #include <$ac_header>
4028 if { (eval echo "$as_me:4028: \"$ac_cpp conftest.$ac_ext\"") >&5
4029 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4031 egrep -v '^ *\+' conftest.er1 >conftest.err
4033 cat conftest.err >&5
4034 echo "$as_me:4034: \$? = $ac_status" >&5
4035 (exit $ac_status); } >/dev/null; then
4036 if test -s conftest.err; then
4037 ac_cpp_err=$ac_c_preproc_warn_flag
4044 if test -z "$ac_cpp_err"; then
4045 eval "$as_ac_Header=yes"
4047 echo "$as_me: failed program was:" >&5
4048 cat conftest.$ac_ext >&5
4049 eval "$as_ac_Header=no"
4051 rm -f conftest.err conftest.$ac_ext
4053 echo "$as_me:4053: result: `eval echo '${'$as_ac_Header'}'`" >&5
4054 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4055 if test `eval echo '${'$as_ac_Header'}'` = yes; then
4056 cat >>confdefs.h <<EOF
4057 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
4063 cat >>confdefs.h <<\EOF
4067 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
4069 cat >>confdefs.h <<EOF
4070 #define $cf_nculib_ROOT 1
4073 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
4077 cf_ncuhdr_root=ncurses
4079 test -n "$cf_cv_curses_dir" && \
4080 test "$cf_cv_curses_dir" != "no" && { \
4082 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
4083 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
4085 while test $cf_add_incdir != /usr/include
4087 if test -d $cf_add_incdir
4090 if test -n "$CFLAGS$CPPFLAGS" ; then
4091 # a loop is needed to ensure we can add subdirs of existing dirs
4092 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
4093 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
4094 cf_have_incdir=yes; break
4099 if test "$cf_have_incdir" = no ; then
4100 if test "$cf_add_incdir" = /usr/local/include ; then
4101 if test "$GCC" = yes
4103 cf_save_CPPFLAGS=$CPPFLAGS
4104 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
4105 cat >conftest.$ac_ext <<_ACEOF
4106 #line 4106 "configure"
4107 #include "confdefs.h"
4117 rm -f conftest.$ac_objext
4118 if { (eval echo "$as_me:4118: \"$ac_compile\"") >&5
4119 (eval $ac_compile) 2>&5
4121 echo "$as_me:4121: \$? = $ac_status" >&5
4122 (exit $ac_status); } &&
4123 { ac_try='test -s conftest.$ac_objext'
4124 { (eval echo "$as_me:4124: \"$ac_try\"") >&5
4127 echo "$as_me:4127: \$? = $ac_status" >&5
4128 (exit $ac_status); }; }; then
4131 echo "$as_me: failed program was:" >&5
4132 cat conftest.$ac_ext >&5
4135 rm -f conftest.$ac_objext conftest.$ac_ext
4136 CPPFLAGS=$cf_save_CPPFLAGS
4141 if test "$cf_have_incdir" = no ; then
4142 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
4144 echo "${as_me:-configure}:4144: testing adding $cf_add_incdir to include-path ..." 1>&5
4146 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
4148 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
4149 test "$cf_top_incdir" = "$cf_add_incdir" && break
4150 cf_add_incdir="$cf_top_incdir"
4163 echo "$as_me:4163: checking for $cf_ncuhdr_root header in include-path" >&5
4164 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
4165 if test "${cf_cv_ncurses_h+set}" = set; then
4166 echo $ECHO_N "(cached) $ECHO_C" >&6
4169 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
4170 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
4171 for cf_header in $cf_header_list
4174 cat >conftest.$ac_ext <<_ACEOF
4175 #line 4175 "configure"
4176 #include "confdefs.h"
4178 #include <$cf_header>
4183 #ifdef NCURSES_VERSION
4185 printf("%s\n", NCURSES_VERSION);
4198 rm -f conftest.$ac_objext
4199 if { (eval echo "$as_me:4199: \"$ac_compile\"") >&5
4200 (eval $ac_compile) 2>&5
4202 echo "$as_me:4202: \$? = $ac_status" >&5
4203 (exit $ac_status); } &&
4204 { ac_try='test -s conftest.$ac_objext'
4205 { (eval echo "$as_me:4205: \"$ac_try\"") >&5
4208 echo "$as_me:4208: \$? = $ac_status" >&5
4209 (exit $ac_status); }; }; then
4210 cf_cv_ncurses_h=$cf_header
4213 echo "$as_me: failed program was:" >&5
4214 cat conftest.$ac_ext >&5
4217 rm -f conftest.$ac_objext conftest.$ac_ext
4219 test "$cf_cv_ncurses_h" != no && break
4223 echo "$as_me:4223: result: $cf_cv_ncurses_h" >&5
4224 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
4226 if test "$cf_cv_ncurses_h" != no ; then
4227 cf_cv_ncurses_header=$cf_cv_ncurses_h
4230 echo "$as_me:4230: checking for $cf_ncuhdr_root include-path" >&5
4231 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
4232 if test "${cf_cv_ncurses_h2+set}" = set; then
4233 echo $ECHO_N "(cached) $ECHO_C" >&6
4236 test -n "$verbose" && echo
4240 # collect the current set of include-directories from compiler flags
4241 cf_header_path_list=""
4242 if test -n "${CFLAGS}${CPPFLAGS}" ; then
4243 for cf_header_path in $CPPFLAGS $CFLAGS
4245 case $cf_header_path in
4247 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
4249 test "x$cf_header_path" != "xNONE" && \
4250 test -d "$cf_header_path" && \
4252 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
4253 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
4254 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
4255 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
4256 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
4257 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"
4260 cf_header_path_list="$cf_header_path_list $cf_search"
4266 # add the variations for the package we are looking for
4270 test "x$prefix" != "xNONE" && \
4271 test -d "$prefix" && \
4273 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
4274 test -d $prefix/include && cf_search="$cf_search $prefix/include"
4275 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
4276 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
4277 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
4278 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
4281 for cf_subdir_prefix in \
4290 test "x$cf_subdir_prefix" != "x$prefix" && \
4291 test -d "$cf_subdir_prefix" && \
4292 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
4293 test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
4294 test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include"
4295 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root"
4296 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root/include"
4297 test -d $cf_subdir_prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include"
4298 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"
4303 test "$includedir" != NONE && \
4304 test "$includedir" != "/usr/include" && \
4305 test -d "$includedir" && {
4306 test -d $includedir && cf_search="$cf_search $includedir"
4307 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
4310 test "$oldincludedir" != NONE && \
4311 test "$oldincludedir" != "/usr/include" && \
4312 test -d "$oldincludedir" && {
4313 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
4314 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
4317 cf_search="$cf_search $cf_header_path_list"
4319 test -n "$verbose" && echo search path $cf_search
4320 cf_save2_CPPFLAGS="$CPPFLAGS"
4321 for cf_incdir in $cf_search
4324 if test -n "$cf_incdir" ; then
4325 for cf_add_incdir in $cf_incdir
4327 while test $cf_add_incdir != /usr/include
4329 if test -d $cf_add_incdir
4332 if test -n "$CFLAGS$CPPFLAGS" ; then
4333 # a loop is needed to ensure we can add subdirs of existing dirs
4334 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
4335 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
4336 cf_have_incdir=yes; break
4341 if test "$cf_have_incdir" = no ; then
4342 if test "$cf_add_incdir" = /usr/local/include ; then
4343 if test "$GCC" = yes
4345 cf_save_CPPFLAGS=$CPPFLAGS
4346 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
4347 cat >conftest.$ac_ext <<_ACEOF
4348 #line 4348 "configure"
4349 #include "confdefs.h"
4359 rm -f conftest.$ac_objext
4360 if { (eval echo "$as_me:4360: \"$ac_compile\"") >&5
4361 (eval $ac_compile) 2>&5
4363 echo "$as_me:4363: \$? = $ac_status" >&5
4364 (exit $ac_status); } &&
4365 { ac_try='test -s conftest.$ac_objext'
4366 { (eval echo "$as_me:4366: \"$ac_try\"") >&5
4369 echo "$as_me:4369: \$? = $ac_status" >&5
4370 (exit $ac_status); }; }; then
4373 echo "$as_me: failed program was:" >&5
4374 cat conftest.$ac_ext >&5
4377 rm -f conftest.$ac_objext conftest.$ac_ext
4378 CPPFLAGS=$cf_save_CPPFLAGS
4383 if test "$cf_have_incdir" = no ; then
4384 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
4386 echo "${as_me:-configure}:4386: testing adding $cf_add_incdir to include-path ..." 1>&5
4388 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
4390 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
4391 test "$cf_top_incdir" = "$cf_add_incdir" && break
4392 cf_add_incdir="$cf_top_incdir"
4408 cat >conftest.$ac_ext <<_ACEOF
4409 #line 4409 "configure"
4410 #include "confdefs.h"
4412 #include <$cf_header>
4417 #ifdef NCURSES_VERSION
4419 printf("%s\n", NCURSES_VERSION);
4432 rm -f conftest.$ac_objext
4433 if { (eval echo "$as_me:4433: \"$ac_compile\"") >&5
4434 (eval $ac_compile) 2>&5
4436 echo "$as_me:4436: \$? = $ac_status" >&5
4437 (exit $ac_status); } &&
4438 { ac_try='test -s conftest.$ac_objext'
4439 { (eval echo "$as_me:4439: \"$ac_try\"") >&5
4442 echo "$as_me:4442: \$? = $ac_status" >&5
4443 (exit $ac_status); }; }; then
4444 cf_cv_ncurses_h2=$cf_header
4447 echo "$as_me: failed program was:" >&5
4448 cat conftest.$ac_ext >&5
4451 rm -f conftest.$ac_objext conftest.$ac_ext
4453 if test "$cf_cv_ncurses_h2" != no ; then
4454 cf_cv_ncurses_h2=$cf_incdir/$cf_header
4455 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
4458 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
4460 CPPFLAGS="$cf_save2_CPPFLAGS"
4461 test "$cf_cv_ncurses_h2" != no && break
4463 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:4463: error: not found" >&5
4464 echo "$as_me: error: not found" >&2;}
4465 { (exit 1); exit 1; }; }
4468 echo "$as_me:4468: result: $cf_cv_ncurses_h2" >&5
4469 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
4471 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
4472 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
4473 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
4474 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
4477 if test -n "$cf_1st_incdir" ; then
4478 for cf_add_incdir in $cf_1st_incdir
4480 while test $cf_add_incdir != /usr/include
4482 if test -d $cf_add_incdir
4485 if test -n "$CFLAGS$CPPFLAGS" ; then
4486 # a loop is needed to ensure we can add subdirs of existing dirs
4487 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
4488 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
4489 cf_have_incdir=yes; break
4494 if test "$cf_have_incdir" = no ; then
4495 if test "$cf_add_incdir" = /usr/local/include ; then
4496 if test "$GCC" = yes
4498 cf_save_CPPFLAGS=$CPPFLAGS
4499 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
4500 cat >conftest.$ac_ext <<_ACEOF
4501 #line 4501 "configure"
4502 #include "confdefs.h"
4512 rm -f conftest.$ac_objext
4513 if { (eval echo "$as_me:4513: \"$ac_compile\"") >&5
4514 (eval $ac_compile) 2>&5
4516 echo "$as_me:4516: \$? = $ac_status" >&5
4517 (exit $ac_status); } &&
4518 { ac_try='test -s conftest.$ac_objext'
4519 { (eval echo "$as_me:4519: \"$ac_try\"") >&5
4522 echo "$as_me:4522: \$? = $ac_status" >&5
4523 (exit $ac_status); }; }; then
4526 echo "$as_me: failed program was:" >&5
4527 cat conftest.$ac_ext >&5
4530 rm -f conftest.$ac_objext conftest.$ac_ext
4531 CPPFLAGS=$cf_save_CPPFLAGS
4536 if test "$cf_have_incdir" = no ; then
4537 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
4539 echo "${as_me:-configure}:4539: testing adding $cf_add_incdir to include-path ..." 1>&5
4541 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
4543 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
4544 test "$cf_top_incdir" = "$cf_add_incdir" && break
4545 cf_add_incdir="$cf_top_incdir"
4558 # Set definitions to allow ifdef'ing for ncurses.h
4560 case $cf_cv_ncurses_header in
4563 cat >>confdefs.h <<\EOF
4564 #define HAVE_NCURSES_H 1
4570 case $cf_cv_ncurses_header in
4571 (ncurses/curses.h|ncurses/ncurses.h)
4573 cat >>confdefs.h <<\EOF
4574 #define HAVE_NCURSES_NCURSES_H 1
4578 (ncursesw/curses.h|ncursesw/ncurses.h)
4580 cat >>confdefs.h <<\EOF
4581 #define HAVE_NCURSESW_NCURSES_H 1
4587 echo "$as_me:4587: checking for terminfo header" >&5
4588 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
4589 if test "${cf_cv_term_header+set}" = set; then
4590 echo $ECHO_N "(cached) $ECHO_C" >&6
4593 case ${cf_cv_ncurses_header} in
4594 (*/ncurses.h|*/ncursesw.h)
4595 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
4598 cf_term_header=term.h
4602 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
4604 cat >conftest.$ac_ext <<_ACEOF
4605 #line 4605 "configure"
4606 #include "confdefs.h"
4608 #include <${cf_cv_ncurses_header:-curses.h}>
4614 int x = auto_left_margin
4619 rm -f conftest.$ac_objext
4620 if { (eval echo "$as_me:4620: \"$ac_compile\"") >&5
4621 (eval $ac_compile) 2>&5
4623 echo "$as_me:4623: \$? = $ac_status" >&5
4624 (exit $ac_status); } &&
4625 { ac_try='test -s conftest.$ac_objext'
4626 { (eval echo "$as_me:4626: \"$ac_try\"") >&5
4629 echo "$as_me:4629: \$? = $ac_status" >&5
4630 (exit $ac_status); }; }; then
4632 cf_cv_term_header="$cf_test"
4634 echo "$as_me: failed program was:" >&5
4635 cat conftest.$ac_ext >&5
4637 cf_cv_term_header=unknown
4640 rm -f conftest.$ac_objext conftest.$ac_ext
4641 test "$cf_cv_term_header" != unknown && break
4645 echo "$as_me:4645: result: $cf_cv_term_header" >&5
4646 echo "${ECHO_T}$cf_cv_term_header" >&6
4648 # Set definitions to allow ifdef'ing to accommodate subdirectories
4650 case $cf_cv_term_header in
4653 cat >>confdefs.h <<\EOF
4654 #define HAVE_TERM_H 1
4660 case $cf_cv_term_header in
4663 cat >>confdefs.h <<\EOF
4664 #define HAVE_NCURSES_TERM_H 1
4670 cat >>confdefs.h <<\EOF
4671 #define HAVE_NCURSESW_TERM_H 1
4677 # some applications need this, but should check for NCURSES_VERSION
4679 cat >>confdefs.h <<\EOF
4683 echo "$as_me:4683: checking for ncurses version" >&5
4684 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
4685 if test "${cf_cv_ncurses_version+set}" = set; then
4686 echo $ECHO_N "(cached) $ECHO_C" >&6
4689 cf_cv_ncurses_version=no
4692 if test "$cross_compiling" = yes; then
4694 # This will not work if the preprocessor splits the line after the
4695 # Autoconf token. The 'unproto' program does that.
4696 cat > conftest.$ac_ext <<EOF
4697 #include <${cf_cv_ncurses_header:-curses.h}>
4699 #ifdef NCURSES_VERSION
4700 Autoconf NCURSES_VERSION
4708 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
4709 { (eval echo "$as_me:4709: \"$cf_try\"") >&5
4712 echo "$as_me:4712: \$? = $ac_status" >&5
4713 (exit $ac_status); }
4714 if test -f conftest.out ; then
4715 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
4716 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
4721 cat >conftest.$ac_ext <<_ACEOF
4722 #line 4722 "configure"
4723 #include "confdefs.h"
4725 #include <${cf_cv_ncurses_header:-curses.h}>
4729 FILE *fp = fopen("$cf_tempfile", "w");
4730 #ifdef NCURSES_VERSION
4731 # ifdef NCURSES_VERSION_PATCH
4732 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
4734 fprintf(fp, "%s\n", NCURSES_VERSION);
4738 fprintf(fp, "old\n");
4743 ${cf_cv_main_return:-return}(0);
4746 rm -f conftest$ac_exeext
4747 if { (eval echo "$as_me:4747: \"$ac_link\"") >&5
4748 (eval $ac_link) 2>&5
4750 echo "$as_me:4750: \$? = $ac_status" >&5
4751 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4752 { (eval echo "$as_me:4752: \"$ac_try\"") >&5
4755 echo "$as_me:4755: \$? = $ac_status" >&5
4756 (exit $ac_status); }; }; then
4758 cf_cv_ncurses_version=`cat $cf_tempfile`
4760 echo "$as_me: program exited with status $ac_status" >&5
4761 echo "$as_me: failed program was:" >&5
4762 cat conftest.$ac_ext >&5
4764 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
4769 echo "$as_me:4769: result: $cf_cv_ncurses_version" >&5
4770 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
4771 test "$cf_cv_ncurses_version" = no ||
4772 cat >>confdefs.h <<\EOF
4776 cf_nculib_root=ncurses
4777 # This works, except for the special case where we find gpm, but
4778 # ncurses is in a nonstandard location via $LIBS, and we really want
4781 cf_ncurses_SAVE="$LIBS"
4782 echo "$as_me:4782: checking for Gpm_Open in -lgpm" >&5
4783 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
4784 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
4785 echo $ECHO_N "(cached) $ECHO_C" >&6
4787 ac_check_lib_save_LIBS=$LIBS
4789 cat >conftest.$ac_ext <<_ACEOF
4790 #line 4790 "configure"
4791 #include "confdefs.h"
4793 /* Override any gcc2 internal prototype to avoid an error. */
4797 /* We use char because int might match the return type of a gcc2
4798 builtin and then its argument prototype would still apply. */
4808 rm -f conftest.$ac_objext conftest$ac_exeext
4809 if { (eval echo "$as_me:4809: \"$ac_link\"") >&5
4810 (eval $ac_link) 2>&5
4812 echo "$as_me:4812: \$? = $ac_status" >&5
4813 (exit $ac_status); } &&
4814 { ac_try='test -s conftest$ac_exeext'
4815 { (eval echo "$as_me:4815: \"$ac_try\"") >&5
4818 echo "$as_me:4818: \$? = $ac_status" >&5
4819 (exit $ac_status); }; }; then
4820 ac_cv_lib_gpm_Gpm_Open=yes
4822 echo "$as_me: failed program was:" >&5
4823 cat conftest.$ac_ext >&5
4824 ac_cv_lib_gpm_Gpm_Open=no
4826 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4827 LIBS=$ac_check_lib_save_LIBS
4829 echo "$as_me:4829: result: $ac_cv_lib_gpm_Gpm_Open" >&5
4830 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
4831 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
4832 echo "$as_me:4832: checking for initscr in -lgpm" >&5
4833 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
4834 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
4835 echo $ECHO_N "(cached) $ECHO_C" >&6
4837 ac_check_lib_save_LIBS=$LIBS
4839 cat >conftest.$ac_ext <<_ACEOF
4840 #line 4840 "configure"
4841 #include "confdefs.h"
4843 /* Override any gcc2 internal prototype to avoid an error. */
4847 /* We use char because int might match the return type of a gcc2
4848 builtin and then its argument prototype would still apply. */
4858 rm -f conftest.$ac_objext conftest$ac_exeext
4859 if { (eval echo "$as_me:4859: \"$ac_link\"") >&5
4860 (eval $ac_link) 2>&5
4862 echo "$as_me:4862: \$? = $ac_status" >&5
4863 (exit $ac_status); } &&
4864 { ac_try='test -s conftest$ac_exeext'
4865 { (eval echo "$as_me:4865: \"$ac_try\"") >&5
4868 echo "$as_me:4868: \$? = $ac_status" >&5
4869 (exit $ac_status); }; }; then
4870 ac_cv_lib_gpm_initscr=yes
4872 echo "$as_me: failed program was:" >&5
4873 cat conftest.$ac_ext >&5
4874 ac_cv_lib_gpm_initscr=no
4876 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4877 LIBS=$ac_check_lib_save_LIBS
4879 echo "$as_me:4879: result: $ac_cv_lib_gpm_initscr" >&5
4880 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
4881 if test $ac_cv_lib_gpm_initscr = yes; then
4882 LIBS="$cf_ncurses_SAVE"
4884 cf_ncurses_LIBS="-lgpm"
4891 # This is only necessary if you are linking against an obsolete
4892 # version of ncurses (but it should do no harm, since it's static).
4893 if test "$cf_nculib_root" = ncurses ; then
4894 echo "$as_me:4894: checking for tgoto in -lmytinfo" >&5
4895 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
4896 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
4897 echo $ECHO_N "(cached) $ECHO_C" >&6
4899 ac_check_lib_save_LIBS=$LIBS
4900 LIBS="-lmytinfo $LIBS"
4901 cat >conftest.$ac_ext <<_ACEOF
4902 #line 4902 "configure"
4903 #include "confdefs.h"
4905 /* Override any gcc2 internal prototype to avoid an error. */
4909 /* We use char because int might match the return type of a gcc2
4910 builtin and then its argument prototype would still apply. */
4920 rm -f conftest.$ac_objext conftest$ac_exeext
4921 if { (eval echo "$as_me:4921: \"$ac_link\"") >&5
4922 (eval $ac_link) 2>&5
4924 echo "$as_me:4924: \$? = $ac_status" >&5
4925 (exit $ac_status); } &&
4926 { ac_try='test -s conftest$ac_exeext'
4927 { (eval echo "$as_me:4927: \"$ac_try\"") >&5
4930 echo "$as_me:4930: \$? = $ac_status" >&5
4931 (exit $ac_status); }; }; then
4932 ac_cv_lib_mytinfo_tgoto=yes
4934 echo "$as_me: failed program was:" >&5
4935 cat conftest.$ac_ext >&5
4936 ac_cv_lib_mytinfo_tgoto=no
4938 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4939 LIBS=$ac_check_lib_save_LIBS
4941 echo "$as_me:4941: result: $ac_cv_lib_mytinfo_tgoto" >&5
4942 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
4943 if test $ac_cv_lib_mytinfo_tgoto = yes; then
4944 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
4951 cf_add_libs="$cf_ncurses_LIBS"
4952 # Filter out duplicates - this happens with badly-designed ".pc" files...
4953 for cf_add_1lib in $LIBS
4955 for cf_add_2lib in $cf_add_libs
4957 if test "x$cf_add_1lib" = "x$cf_add_2lib"
4963 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
4967 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
4970 cf_add_libs="-l$cf_nculib_root"
4971 # Filter out duplicates - this happens with badly-designed ".pc" files...
4972 for cf_add_1lib in $LIBS
4974 for cf_add_2lib in $cf_add_libs
4976 if test "x$cf_add_1lib" = "x$cf_add_2lib"
4982 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
4988 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
4990 echo "$as_me:4990: checking for initscr" >&5
4991 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
4992 if test "${ac_cv_func_initscr+set}" = set; then
4993 echo $ECHO_N "(cached) $ECHO_C" >&6
4995 cat >conftest.$ac_ext <<_ACEOF
4996 #line 4996 "configure"
4997 #include "confdefs.h"
4998 /* System header to define __stub macros and hopefully few prototypes,
4999 which can conflict with char initscr (); below. */
5001 /* Override any gcc2 internal prototype to avoid an error. */
5005 /* We use char because int might match the return type of a gcc2
5006 builtin and then its argument prototype would still apply. */
5013 /* The GNU C library defines this for functions which it implements
5014 to always fail with ENOSYS. Some functions are actually named
5015 something starting with __ and the normal name is an alias. */
5016 #if defined (__stub_initscr) || defined (__stub___initscr)
5019 f = initscr; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
5026 rm -f conftest.$ac_objext conftest$ac_exeext
5027 if { (eval echo "$as_me:5027: \"$ac_link\"") >&5
5028 (eval $ac_link) 2>&5
5030 echo "$as_me:5030: \$? = $ac_status" >&5
5031 (exit $ac_status); } &&
5032 { ac_try='test -s conftest$ac_exeext'
5033 { (eval echo "$as_me:5033: \"$ac_try\"") >&5
5036 echo "$as_me:5036: \$? = $ac_status" >&5
5037 (exit $ac_status); }; }; then
5038 ac_cv_func_initscr=yes
5040 echo "$as_me: failed program was:" >&5
5041 cat conftest.$ac_ext >&5
5042 ac_cv_func_initscr=no
5044 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5046 echo "$as_me:5046: result: $ac_cv_func_initscr" >&5
5047 echo "${ECHO_T}$ac_cv_func_initscr" >&6
5048 if test $ac_cv_func_initscr = yes; then
5049 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
5052 cf_save_LIBS="$LIBS"
5053 echo "$as_me:5053: checking for initscr in -l$cf_nculib_root" >&5
5054 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
5055 LIBS="-l$cf_nculib_root $LIBS"
5056 cat >conftest.$ac_ext <<_ACEOF
5057 #line 5057 "configure"
5058 #include "confdefs.h"
5059 #include <${cf_cv_ncurses_header:-curses.h}>
5068 rm -f conftest.$ac_objext conftest$ac_exeext
5069 if { (eval echo "$as_me:5069: \"$ac_link\"") >&5
5070 (eval $ac_link) 2>&5
5072 echo "$as_me:5072: \$? = $ac_status" >&5
5073 (exit $ac_status); } &&
5074 { ac_try='test -s conftest$ac_exeext'
5075 { (eval echo "$as_me:5075: \"$ac_try\"") >&5
5078 echo "$as_me:5078: \$? = $ac_status" >&5
5079 (exit $ac_status); }; }; then
5080 echo "$as_me:5080: result: yes" >&5
5081 echo "${ECHO_T}yes" >&6
5082 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
5085 echo "$as_me: failed program was:" >&5
5086 cat conftest.$ac_ext >&5
5087 echo "$as_me:5087: result: no" >&5
5088 echo "${ECHO_T}no" >&6
5091 cf_library_path_list=""
5092 if test -n "${LDFLAGS}${LIBS}" ; then
5093 for cf_library_path in $LDFLAGS $LIBS
5095 case $cf_library_path in
5097 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
5099 test "x$cf_library_path" != "xNONE" && \
5100 test -d "$cf_library_path" && \
5102 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
5103 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
5104 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
5105 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
5106 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
5107 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"
5110 cf_library_path_list="$cf_library_path_list $cf_search"
5118 test "x$prefix" != "xNONE" && \
5119 test -d "$prefix" && \
5121 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
5122 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
5123 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
5124 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
5125 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
5126 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
5129 for cf_subdir_prefix in \
5138 test "x$cf_subdir_prefix" != "x$prefix" && \
5139 test -d "$cf_subdir_prefix" && \
5140 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
5141 test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
5142 test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib"
5143 test -d $cf_subdir_prefix/lib/$cf_nculib_root && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root"
5144 test -d $cf_subdir_prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root/lib"
5145 test -d $cf_subdir_prefix/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib"
5146 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"
5151 cf_search="$cf_library_path_list $cf_search"
5153 for cf_libdir in $cf_search
5155 echo "$as_me:5155: checking for -l$cf_nculib_root in $cf_libdir" >&5
5156 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
5157 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
5158 cat >conftest.$ac_ext <<_ACEOF
5159 #line 5159 "configure"
5160 #include "confdefs.h"
5161 #include <${cf_cv_ncurses_header:-curses.h}>
5170 rm -f conftest.$ac_objext conftest$ac_exeext
5171 if { (eval echo "$as_me:5171: \"$ac_link\"") >&5
5172 (eval $ac_link) 2>&5
5174 echo "$as_me:5174: \$? = $ac_status" >&5
5175 (exit $ac_status); } &&
5176 { ac_try='test -s conftest$ac_exeext'
5177 { (eval echo "$as_me:5177: \"$ac_try\"") >&5
5180 echo "$as_me:5180: \$? = $ac_status" >&5
5181 (exit $ac_status); }; }; then
5182 echo "$as_me:5182: result: yes" >&5
5183 echo "${ECHO_T}yes" >&6
5184 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
5187 echo "$as_me: failed program was:" >&5
5188 cat conftest.$ac_ext >&5
5189 echo "$as_me:5189: result: no" >&5
5190 echo "${ECHO_T}no" >&6
5191 LIBS="$cf_save_LIBS"
5193 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5197 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5201 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
5203 if test $cf_found_library = no ; then
5204 { { echo "$as_me:5204: error: Cannot link $cf_nculib_root library" >&5
5205 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
5206 { (exit 1); exit 1; }; }
5211 if test -n "$cf_ncurses_LIBS" ; then
5212 echo "$as_me:5212: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
5213 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
5214 cf_ncurses_SAVE="$LIBS"
5215 for p in $cf_ncurses_LIBS ; do
5216 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
5217 if test "$q" != "$LIBS" ; then
5221 cat >conftest.$ac_ext <<_ACEOF
5222 #line 5222 "configure"
5223 #include "confdefs.h"
5224 #include <${cf_cv_ncurses_header:-curses.h}>
5228 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
5233 rm -f conftest.$ac_objext conftest$ac_exeext
5234 if { (eval echo "$as_me:5234: \"$ac_link\"") >&5
5235 (eval $ac_link) 2>&5
5237 echo "$as_me:5237: \$? = $ac_status" >&5
5238 (exit $ac_status); } &&
5239 { ac_try='test -s conftest$ac_exeext'
5240 { (eval echo "$as_me:5240: \"$ac_try\"") >&5
5243 echo "$as_me:5243: \$? = $ac_status" >&5
5244 (exit $ac_status); }; }; then
5245 echo "$as_me:5245: result: yes" >&5
5246 echo "${ECHO_T}yes" >&6
5248 echo "$as_me: failed program was:" >&5
5249 cat conftest.$ac_ext >&5
5250 echo "$as_me:5250: result: no" >&5
5251 echo "${ECHO_T}no" >&6
5252 LIBS="$cf_ncurses_SAVE"
5254 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5257 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
5259 cat >>confdefs.h <<EOF
5260 #define $cf_nculib_ROOT 1
5268 echo "$as_me:5268: checking if you want wide-character code" >&5
5269 echo $ECHO_N "checking if you want wide-character code... $ECHO_C" >&6
5271 # Check whether --enable-widec or --disable-widec was given.
5272 if test "${enable_widec+set}" = set; then
5273 enableval="$enable_widec"
5274 with_widec=$enableval
5278 echo "$as_me:5278: result: $with_widec" >&5
5279 echo "${ECHO_T}$with_widec" >&6
5280 if test "$with_widec" = yes ; then
5282 echo "$as_me:5282: checking for multibyte character support" >&5
5283 echo $ECHO_N "checking for multibyte character support... $ECHO_C" >&6
5284 if test "${cf_cv_utf8_lib+set}" = set; then
5285 echo $ECHO_N "(cached) $ECHO_C" >&6
5288 cf_save_LIBS="$LIBS"
5289 cat >conftest.$ac_ext <<_ACEOF
5290 #line 5290 "configure"
5291 #include "confdefs.h"
5302 rm -f conftest.$ac_objext conftest$ac_exeext
5303 if { (eval echo "$as_me:5303: \"$ac_link\"") >&5
5304 (eval $ac_link) 2>&5
5306 echo "$as_me:5306: \$? = $ac_status" >&5
5307 (exit $ac_status); } &&
5308 { ac_try='test -s conftest$ac_exeext'
5309 { (eval echo "$as_me:5309: \"$ac_try\"") >&5
5312 echo "$as_me:5312: \$? = $ac_status" >&5
5313 (exit $ac_status); }; }; then
5316 echo "$as_me: failed program was:" >&5
5317 cat conftest.$ac_ext >&5
5319 # If the linkage is not already in the $CPPFLAGS/$LDFLAGS configuration, these
5320 # will be set on completion of the AC_TRY_LINK below.
5321 cf_cv_header_path_utf8=
5322 cf_cv_library_path_utf8=
5324 echo "${as_me:-configure}:5324: testing Starting FIND_LINKAGE(utf8,) ..." 1>&5
5326 cf_save_LIBS="$LIBS"
5328 cat >conftest.$ac_ext <<_ACEOF
5329 #line 5329 "configure"
5330 #include "confdefs.h"
5332 #include <libutf8.h>
5341 rm -f conftest.$ac_objext conftest$ac_exeext
5342 if { (eval echo "$as_me:5342: \"$ac_link\"") >&5
5343 (eval $ac_link) 2>&5
5345 echo "$as_me:5345: \$? = $ac_status" >&5
5346 (exit $ac_status); } &&
5347 { ac_try='test -s conftest$ac_exeext'
5348 { (eval echo "$as_me:5348: \"$ac_try\"") >&5
5351 echo "$as_me:5351: \$? = $ac_status" >&5
5352 (exit $ac_status); }; }; then
5354 cf_cv_find_linkage_utf8=yes
5355 cf_cv_header_path_utf8=/usr/include
5356 cf_cv_library_path_utf8=/usr/lib
5359 echo "$as_me: failed program was:" >&5
5360 cat conftest.$ac_ext >&5
5362 LIBS="-lutf8 $cf_save_LIBS"
5364 cat >conftest.$ac_ext <<_ACEOF
5365 #line 5365 "configure"
5366 #include "confdefs.h"
5368 #include <libutf8.h>
5377 rm -f conftest.$ac_objext conftest$ac_exeext
5378 if { (eval echo "$as_me:5378: \"$ac_link\"") >&5
5379 (eval $ac_link) 2>&5
5381 echo "$as_me:5381: \$? = $ac_status" >&5
5382 (exit $ac_status); } &&
5383 { ac_try='test -s conftest$ac_exeext'
5384 { (eval echo "$as_me:5384: \"$ac_try\"") >&5
5387 echo "$as_me:5387: \$? = $ac_status" >&5
5388 (exit $ac_status); }; }; then
5390 cf_cv_find_linkage_utf8=yes
5391 cf_cv_header_path_utf8=/usr/include
5392 cf_cv_library_path_utf8=/usr/lib
5393 cf_cv_library_file_utf8="-lutf8"
5396 echo "$as_me: failed program was:" >&5
5397 cat conftest.$ac_ext >&5
5399 cf_cv_find_linkage_utf8=no
5400 LIBS="$cf_save_LIBS"
5402 test -n "$verbose" && echo " find linkage for utf8 library" 1>&6
5404 echo "${as_me:-configure}:5404: testing find linkage for utf8 library ..." 1>&5
5406 echo "${as_me:-configure}:5406: testing Searching for headers in FIND_LINKAGE(utf8,) ..." 1>&5
5408 cf_save_CPPFLAGS="$CPPFLAGS"
5409 cf_test_CPPFLAGS="$CPPFLAGS"
5413 # collect the current set of include-directories from compiler flags
5414 cf_header_path_list=""
5415 if test -n "${CFLAGS}${CPPFLAGS}" ; then
5416 for cf_header_path in $CPPFLAGS $CFLAGS
5418 case $cf_header_path in
5420 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
5422 test "x$cf_header_path" != "xNONE" && \
5423 test -d "$cf_header_path" && \
5425 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
5426 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
5427 test -d $cf_header_path/include/utf8 && cf_search="$cf_search $cf_header_path/include/utf8"
5428 test -d $cf_header_path/include/utf8/include && cf_search="$cf_search $cf_header_path/include/utf8/include"
5429 test -d $cf_header_path/utf8/include && cf_search="$cf_search $cf_header_path/utf8/include"
5430 test -d $cf_header_path/utf8/include/utf8 && cf_search="$cf_search $cf_header_path/utf8/include/utf8"
5433 cf_header_path_list="$cf_header_path_list $cf_search"
5439 # add the variations for the package we are looking for
5443 test "x$prefix" != "xNONE" && \
5444 test -d "$prefix" && \
5446 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
5447 test -d $prefix/include && cf_search="$cf_search $prefix/include"
5448 test -d $prefix/include/utf8 && cf_search="$cf_search $prefix/include/utf8"
5449 test -d $prefix/include/utf8/include && cf_search="$cf_search $prefix/include/utf8/include"
5450 test -d $prefix/utf8/include && cf_search="$cf_search $prefix/utf8/include"
5451 test -d $prefix/utf8/include/utf8 && cf_search="$cf_search $prefix/utf8/include/utf8"
5454 for cf_subdir_prefix in \
5463 test "x$cf_subdir_prefix" != "x$prefix" && \
5464 test -d "$cf_subdir_prefix" && \
5465 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
5466 test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
5467 test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include"
5468 test -d $cf_subdir_prefix/include/utf8 && cf_search="$cf_search $cf_subdir_prefix/include/utf8"
5469 test -d $cf_subdir_prefix/include/utf8/include && cf_search="$cf_search $cf_subdir_prefix/include/utf8/include"
5470 test -d $cf_subdir_prefix/utf8/include && cf_search="$cf_search $cf_subdir_prefix/utf8/include"
5471 test -d $cf_subdir_prefix/utf8/include/utf8 && cf_search="$cf_search $cf_subdir_prefix/utf8/include/utf8"
5476 test "$includedir" != NONE && \
5477 test "$includedir" != "/usr/include" && \
5478 test -d "$includedir" && {
5479 test -d $includedir && cf_search="$cf_search $includedir"
5480 test -d $includedir/utf8 && cf_search="$cf_search $includedir/utf8"
5483 test "$oldincludedir" != NONE && \
5484 test "$oldincludedir" != "/usr/include" && \
5485 test -d "$oldincludedir" && {
5486 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
5487 test -d $oldincludedir/utf8 && cf_search="$cf_search $oldincludedir/utf8"
5490 cf_search="$cf_search $cf_header_path_list"
5492 for cf_cv_header_path_utf8 in $cf_search
5494 if test -d $cf_cv_header_path_utf8 ; then
5495 test -n "$verbose" && echo " ... testing $cf_cv_header_path_utf8" 1>&6
5497 echo "${as_me:-configure}:5497: testing ... testing $cf_cv_header_path_utf8 ..." 1>&5
5499 CPPFLAGS="$cf_save_CPPFLAGS -I$cf_cv_header_path_utf8"
5500 cat >conftest.$ac_ext <<_ACEOF
5501 #line 5501 "configure"
5502 #include "confdefs.h"
5504 #include <libutf8.h>
5513 rm -f conftest.$ac_objext
5514 if { (eval echo "$as_me:5514: \"$ac_compile\"") >&5
5515 (eval $ac_compile) 2>&5
5517 echo "$as_me:5517: \$? = $ac_status" >&5
5518 (exit $ac_status); } &&
5519 { ac_try='test -s conftest.$ac_objext'
5520 { (eval echo "$as_me:5520: \"$ac_try\"") >&5
5523 echo "$as_me:5523: \$? = $ac_status" >&5
5524 (exit $ac_status); }; }; then
5526 test -n "$verbose" && echo " ... found utf8 headers in $cf_cv_header_path_utf8" 1>&6
5528 echo "${as_me:-configure}:5528: testing ... found utf8 headers in $cf_cv_header_path_utf8 ..." 1>&5
5530 cf_cv_find_linkage_utf8=maybe
5531 cf_test_CPPFLAGS="$CPPFLAGS"
5534 echo "$as_me: failed program was:" >&5
5535 cat conftest.$ac_ext >&5
5537 CPPFLAGS="$cf_save_CPPFLAGS"
5540 rm -f conftest.$ac_objext conftest.$ac_ext
5544 if test "$cf_cv_find_linkage_utf8" = maybe ; then
5546 echo "${as_me:-configure}:5546: testing Searching for utf8 library in FIND_LINKAGE(utf8,) ..." 1>&5
5548 cf_save_LIBS="$LIBS"
5549 cf_save_LDFLAGS="$LDFLAGS"
5551 if test "$cf_cv_find_linkage_utf8" != yes ; then
5554 cf_library_path_list=""
5555 if test -n "${LDFLAGS}${LIBS}" ; then
5556 for cf_library_path in $LDFLAGS $LIBS
5558 case $cf_library_path in
5560 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
5562 test "x$cf_library_path" != "xNONE" && \
5563 test -d "$cf_library_path" && \
5565 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
5566 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
5567 test -d $cf_library_path/lib/utf8 && cf_search="$cf_search $cf_library_path/lib/utf8"
5568 test -d $cf_library_path/lib/utf8/lib && cf_search="$cf_search $cf_library_path/lib/utf8/lib"
5569 test -d $cf_library_path/utf8/lib && cf_search="$cf_search $cf_library_path/utf8/lib"
5570 test -d $cf_library_path/utf8/lib/utf8 && cf_search="$cf_search $cf_library_path/utf8/lib/utf8"
5573 cf_library_path_list="$cf_library_path_list $cf_search"
5581 test "x$prefix" != "xNONE" && \
5582 test -d "$prefix" && \
5584 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
5585 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
5586 test -d $prefix/lib/utf8 && cf_search="$cf_search $prefix/lib/utf8"
5587 test -d $prefix/lib/utf8/lib && cf_search="$cf_search $prefix/lib/utf8/lib"
5588 test -d $prefix/utf8/lib && cf_search="$cf_search $prefix/utf8/lib"
5589 test -d $prefix/utf8/lib/utf8 && cf_search="$cf_search $prefix/utf8/lib/utf8"
5592 for cf_subdir_prefix in \
5601 test "x$cf_subdir_prefix" != "x$prefix" && \
5602 test -d "$cf_subdir_prefix" && \
5603 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
5604 test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
5605 test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib"
5606 test -d $cf_subdir_prefix/lib/utf8 && cf_search="$cf_search $cf_subdir_prefix/lib/utf8"
5607 test -d $cf_subdir_prefix/lib/utf8/lib && cf_search="$cf_search $cf_subdir_prefix/lib/utf8/lib"
5608 test -d $cf_subdir_prefix/utf8/lib && cf_search="$cf_search $cf_subdir_prefix/utf8/lib"
5609 test -d $cf_subdir_prefix/utf8/lib/utf8 && cf_search="$cf_search $cf_subdir_prefix/utf8/lib/utf8"
5614 cf_search="$cf_library_path_list $cf_search"
5616 for cf_cv_library_path_utf8 in $cf_search
5618 if test -d $cf_cv_library_path_utf8 ; then
5619 test -n "$verbose" && echo " ... testing $cf_cv_library_path_utf8" 1>&6
5621 echo "${as_me:-configure}:5621: testing ... testing $cf_cv_library_path_utf8 ..." 1>&5
5623 CPPFLAGS="$cf_test_CPPFLAGS"
5624 LIBS="-lutf8 $cf_save_LIBS"
5625 LDFLAGS="$cf_save_LDFLAGS -L$cf_cv_library_path_utf8"
5626 cat >conftest.$ac_ext <<_ACEOF
5627 #line 5627 "configure"
5628 #include "confdefs.h"
5630 #include <libutf8.h>
5639 rm -f conftest.$ac_objext conftest$ac_exeext
5640 if { (eval echo "$as_me:5640: \"$ac_link\"") >&5
5641 (eval $ac_link) 2>&5
5643 echo "$as_me:5643: \$? = $ac_status" >&5
5644 (exit $ac_status); } &&
5645 { ac_try='test -s conftest$ac_exeext'
5646 { (eval echo "$as_me:5646: \"$ac_try\"") >&5
5649 echo "$as_me:5649: \$? = $ac_status" >&5
5650 (exit $ac_status); }; }; then
5652 test -n "$verbose" && echo " ... found utf8 library in $cf_cv_library_path_utf8" 1>&6
5654 echo "${as_me:-configure}:5654: testing ... found utf8 library in $cf_cv_library_path_utf8 ..." 1>&5
5656 cf_cv_find_linkage_utf8=yes
5657 cf_cv_library_file_utf8="-lutf8"
5660 echo "$as_me: failed program was:" >&5
5661 cat conftest.$ac_ext >&5
5663 CPPFLAGS="$cf_save_CPPFLAGS"
5664 LIBS="$cf_save_LIBS"
5665 LDFLAGS="$cf_save_LDFLAGS"
5668 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5671 CPPFLAGS="$cf_save_CPPFLAGS"
5672 LDFLAGS="$cf_save_LDFLAGS"
5676 cf_cv_find_linkage_utf8=no
5680 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5683 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5685 LIBS="$cf_save_LIBS"
5687 if test "$cf_cv_find_linkage_utf8" = yes ; then
5688 cf_cv_utf8_lib=add-on
5694 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5696 echo "$as_me:5696: result: $cf_cv_utf8_lib" >&5
5697 echo "${ECHO_T}$cf_cv_utf8_lib" >&6
5699 # HAVE_LIBUTF8_H is used by ncurses if curses.h is shared between
5701 if test "$cf_cv_utf8_lib" = "add-on" ; then
5703 cat >>confdefs.h <<\EOF
5704 #define HAVE_LIBUTF8_H 1
5707 if test -n "$cf_cv_header_path_utf8" ; then
5708 for cf_add_incdir in $cf_cv_header_path_utf8
5710 while test $cf_add_incdir != /usr/include
5712 if test -d $cf_add_incdir
5715 if test -n "$CFLAGS$CPPFLAGS" ; then
5716 # a loop is needed to ensure we can add subdirs of existing dirs
5717 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
5718 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
5719 cf_have_incdir=yes; break
5724 if test "$cf_have_incdir" = no ; then
5725 if test "$cf_add_incdir" = /usr/local/include ; then
5726 if test "$GCC" = yes
5728 cf_save_CPPFLAGS=$CPPFLAGS
5729 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
5730 cat >conftest.$ac_ext <<_ACEOF
5731 #line 5731 "configure"
5732 #include "confdefs.h"
5742 rm -f conftest.$ac_objext
5743 if { (eval echo "$as_me:5743: \"$ac_compile\"") >&5
5744 (eval $ac_compile) 2>&5
5746 echo "$as_me:5746: \$? = $ac_status" >&5
5747 (exit $ac_status); } &&
5748 { ac_try='test -s conftest.$ac_objext'
5749 { (eval echo "$as_me:5749: \"$ac_try\"") >&5
5752 echo "$as_me:5752: \$? = $ac_status" >&5
5753 (exit $ac_status); }; }; then
5756 echo "$as_me: failed program was:" >&5
5757 cat conftest.$ac_ext >&5
5760 rm -f conftest.$ac_objext conftest.$ac_ext
5761 CPPFLAGS=$cf_save_CPPFLAGS
5766 if test "$cf_have_incdir" = no ; then
5767 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
5769 echo "${as_me:-configure}:5769: testing adding $cf_add_incdir to include-path ..." 1>&5
5771 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
5773 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
5774 test "$cf_top_incdir" = "$cf_add_incdir" && break
5775 cf_add_incdir="$cf_top_incdir"
5786 if test -n "$cf_cv_library_path_utf8" ; then
5787 for cf_add_libdir in $cf_cv_library_path_utf8
5789 if test $cf_add_libdir = /usr/lib ; then
5791 elif test -d $cf_add_libdir
5794 if test -n "$LDFLAGS$LIBS" ; then
5795 # a loop is needed to ensure we can add subdirs of existing dirs
5796 for cf_test_libdir in $LDFLAGS $LIBS ; do
5797 if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
5798 cf_have_libdir=yes; break
5802 if test "$cf_have_libdir" = no ; then
5803 test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
5805 echo "${as_me:-configure}:5805: testing adding $cf_add_libdir to library-path ..." 1>&5
5807 LDFLAGS="-L$cf_add_libdir $LDFLAGS"
5813 cf_add_libs="$cf_cv_library_file_utf8"
5814 # Filter out duplicates - this happens with badly-designed ".pc" files...
5815 for cf_add_1lib in $LIBS
5817 for cf_add_2lib in $cf_add_libs
5819 if test "x$cf_add_1lib" = "x$cf_add_2lib"
5825 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
5831 cf_ncuconfig_root=ncursesw
5832 cf_have_ncuconfig=no
5834 if test "x${PKG_CONFIG:=none}" != xnone; then
5835 echo "$as_me:5835: checking pkg-config for $cf_ncuconfig_root" >&5
5836 echo $ECHO_N "checking pkg-config for $cf_ncuconfig_root... $ECHO_C" >&6
5837 if "$PKG_CONFIG" --exists $cf_ncuconfig_root ; then
5838 echo "$as_me:5838: result: yes" >&5
5839 echo "${ECHO_T}yes" >&6
5841 echo "$as_me:5841: checking if the $cf_ncuconfig_root package files work" >&5
5842 echo $ECHO_N "checking if the $cf_ncuconfig_root package files work... $ECHO_C" >&6
5843 cf_have_ncuconfig=unknown
5845 cf_save_CPPFLAGS="$CPPFLAGS"
5846 cf_save_LIBS="$LIBS"
5848 CPPFLAGS="$CPPFLAGS `$PKG_CONFIG --cflags $cf_ncuconfig_root`"
5850 cf_add_libs="`$PKG_CONFIG --libs $cf_ncuconfig_root`"
5851 # Filter out duplicates - this happens with badly-designed ".pc" files...
5852 for cf_add_1lib in $LIBS
5854 for cf_add_2lib in $cf_add_libs
5856 if test "x$cf_add_1lib" = "x$cf_add_2lib"
5862 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
5866 cat >conftest.$ac_ext <<_ACEOF
5867 #line 5867 "configure"
5868 #include "confdefs.h"
5869 #include <${cf_cv_ncurses_header:-curses.h}>
5873 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
5878 rm -f conftest.$ac_objext conftest$ac_exeext
5879 if { (eval echo "$as_me:5879: \"$ac_link\"") >&5
5880 (eval $ac_link) 2>&5
5882 echo "$as_me:5882: \$? = $ac_status" >&5
5883 (exit $ac_status); } &&
5884 { ac_try='test -s conftest$ac_exeext'
5885 { (eval echo "$as_me:5885: \"$ac_try\"") >&5
5888 echo "$as_me:5888: \$? = $ac_status" >&5
5889 (exit $ac_status); }; }; then
5890 if test "$cross_compiling" = yes; then
5891 cf_have_ncuconfig=maybe
5893 cat >conftest.$ac_ext <<_ACEOF
5894 #line 5894 "configure"
5895 #include "confdefs.h"
5896 #include <${cf_cv_ncurses_header:-curses.h}>
5898 { char *xx = curses_version(); return (xx == 0); }
5900 rm -f conftest$ac_exeext
5901 if { (eval echo "$as_me:5901: \"$ac_link\"") >&5
5902 (eval $ac_link) 2>&5
5904 echo "$as_me:5904: \$? = $ac_status" >&5
5905 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5906 { (eval echo "$as_me:5906: \"$ac_try\"") >&5
5909 echo "$as_me:5909: \$? = $ac_status" >&5
5910 (exit $ac_status); }; }; then
5911 cf_have_ncuconfig=yes
5913 echo "$as_me: program exited with status $ac_status" >&5
5914 echo "$as_me: failed program was:" >&5
5915 cat conftest.$ac_ext >&5
5916 cf_have_ncuconfig=no
5918 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
5921 echo "$as_me: failed program was:" >&5
5922 cat conftest.$ac_ext >&5
5923 cf_have_ncuconfig=no
5925 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5926 echo "$as_me:5926: result: $cf_have_ncuconfig" >&5
5927 echo "${ECHO_T}$cf_have_ncuconfig" >&6
5928 test "$cf_have_ncuconfig" = maybe && cf_have_ncuconfig=yes
5929 if test "$cf_have_ncuconfig" != "yes"
5931 CPPFLAGS="$cf_save_CPPFLAGS"
5932 LIBS="$cf_save_LIBS"
5933 NCURSES_CONFIG_PKG=none
5936 cat >>confdefs.h <<\EOF
5940 NCURSES_CONFIG_PKG=$cf_ncuconfig_root
5944 echo "$as_me:5944: result: no" >&5
5945 echo "${ECHO_T}no" >&6
5946 NCURSES_CONFIG_PKG=none
5949 NCURSES_CONFIG_PKG=none
5952 if test "x$cf_have_ncuconfig" = "xno"; then
5953 echo "Looking for ${cf_ncuconfig_root}-config"
5955 if test -n "$ac_tool_prefix"; then
5956 for ac_prog in ${cf_ncuconfig_root}-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
5958 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
5959 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
5960 echo "$as_me:5960: checking for $ac_word" >&5
5961 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5962 if test "${ac_cv_prog_NCURSES_CONFIG+set}" = set; then
5963 echo $ECHO_N "(cached) $ECHO_C" >&6
5965 if test -n "$NCURSES_CONFIG"; then
5966 ac_cv_prog_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test.
5968 ac_save_IFS=$IFS; IFS=$ac_path_separator
5970 for ac_dir in $ac_dummy; do
5972 test -z "$ac_dir" && ac_dir=.
5973 $as_executable_p "$ac_dir/$ac_word" || continue
5974 ac_cv_prog_NCURSES_CONFIG="$ac_tool_prefix$ac_prog"
5975 echo "$as_me:5975: found $ac_dir/$ac_word" >&5
5981 NCURSES_CONFIG=$ac_cv_prog_NCURSES_CONFIG
5982 if test -n "$NCURSES_CONFIG"; then
5983 echo "$as_me:5983: result: $NCURSES_CONFIG" >&5
5984 echo "${ECHO_T}$NCURSES_CONFIG" >&6
5986 echo "$as_me:5986: result: no" >&5
5987 echo "${ECHO_T}no" >&6
5990 test -n "$NCURSES_CONFIG" && break
5993 if test -z "$NCURSES_CONFIG"; then
5994 ac_ct_NCURSES_CONFIG=$NCURSES_CONFIG
5995 for ac_prog in ${cf_ncuconfig_root}-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
5997 # Extract the first word of "$ac_prog", so it can be a program name with args.
5998 set dummy $ac_prog; ac_word=$2
5999 echo "$as_me:5999: checking for $ac_word" >&5
6000 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
6001 if test "${ac_cv_prog_ac_ct_NCURSES_CONFIG+set}" = set; then
6002 echo $ECHO_N "(cached) $ECHO_C" >&6
6004 if test -n "$ac_ct_NCURSES_CONFIG"; then
6005 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_ct_NCURSES_CONFIG" # Let the user override the test.
6007 ac_save_IFS=$IFS; IFS=$ac_path_separator
6009 for ac_dir in $ac_dummy; do
6011 test -z "$ac_dir" && ac_dir=.
6012 $as_executable_p "$ac_dir/$ac_word" || continue
6013 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_prog"
6014 echo "$as_me:6014: found $ac_dir/$ac_word" >&5
6020 ac_ct_NCURSES_CONFIG=$ac_cv_prog_ac_ct_NCURSES_CONFIG
6021 if test -n "$ac_ct_NCURSES_CONFIG"; then
6022 echo "$as_me:6022: result: $ac_ct_NCURSES_CONFIG" >&5
6023 echo "${ECHO_T}$ac_ct_NCURSES_CONFIG" >&6
6025 echo "$as_me:6025: result: no" >&5
6026 echo "${ECHO_T}no" >&6
6029 test -n "$ac_ct_NCURSES_CONFIG" && break
6031 test -n "$ac_ct_NCURSES_CONFIG" || ac_ct_NCURSES_CONFIG="none"
6033 NCURSES_CONFIG=$ac_ct_NCURSES_CONFIG
6036 if test "$NCURSES_CONFIG" != none ; then
6038 CPPFLAGS="$CPPFLAGS `$NCURSES_CONFIG --cflags`"
6040 cf_add_libs="`$NCURSES_CONFIG --libs`"
6041 # Filter out duplicates - this happens with badly-designed ".pc" files...
6042 for cf_add_1lib in $LIBS
6044 for cf_add_2lib in $cf_add_libs
6046 if test "x$cf_add_1lib" = "x$cf_add_2lib"
6052 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
6056 # even with config script, some packages use no-override for curses.h
6058 echo "$as_me:6058: checking if we have identified curses headers" >&5
6059 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
6060 if test "${cf_cv_ncurses_header+set}" = set; then
6061 echo $ECHO_N "(cached) $ECHO_C" >&6
6064 cf_cv_ncurses_header=none
6066 ncurses.h ncursesw/ncurses.h \
6067 curses.h ncursesw/curses.h
6069 cat >conftest.$ac_ext <<_ACEOF
6070 #line 6070 "configure"
6071 #include "confdefs.h"
6072 #include <${cf_header}>
6076 initscr(); tgoto("?", 0,0)
6081 rm -f conftest.$ac_objext
6082 if { (eval echo "$as_me:6082: \"$ac_compile\"") >&5
6083 (eval $ac_compile) 2>&5
6085 echo "$as_me:6085: \$? = $ac_status" >&5
6086 (exit $ac_status); } &&
6087 { ac_try='test -s conftest.$ac_objext'
6088 { (eval echo "$as_me:6088: \"$ac_try\"") >&5
6091 echo "$as_me:6091: \$? = $ac_status" >&5
6092 (exit $ac_status); }; }; then
6093 cf_cv_ncurses_header=$cf_header; break
6095 echo "$as_me: failed program was:" >&5
6096 cat conftest.$ac_ext >&5
6098 rm -f conftest.$ac_objext conftest.$ac_ext
6102 echo "$as_me:6102: result: $cf_cv_ncurses_header" >&5
6103 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
6105 if test "$cf_cv_ncurses_header" = none ; then
6106 { { echo "$as_me:6106: error: No curses header-files found" >&5
6107 echo "$as_me: error: No curses header-files found" >&2;}
6108 { (exit 1); exit 1; }; }
6111 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
6113 for ac_header in $cf_cv_ncurses_header
6115 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6116 echo "$as_me:6116: checking for $ac_header" >&5
6117 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6118 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6119 echo $ECHO_N "(cached) $ECHO_C" >&6
6121 cat >conftest.$ac_ext <<_ACEOF
6122 #line 6122 "configure"
6123 #include "confdefs.h"
6124 #include <$ac_header>
6126 if { (eval echo "$as_me:6126: \"$ac_cpp conftest.$ac_ext\"") >&5
6127 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6129 egrep -v '^ *\+' conftest.er1 >conftest.err
6131 cat conftest.err >&5
6132 echo "$as_me:6132: \$? = $ac_status" >&5
6133 (exit $ac_status); } >/dev/null; then
6134 if test -s conftest.err; then
6135 ac_cpp_err=$ac_c_preproc_warn_flag
6142 if test -z "$ac_cpp_err"; then
6143 eval "$as_ac_Header=yes"
6145 echo "$as_me: failed program was:" >&5
6146 cat conftest.$ac_ext >&5
6147 eval "$as_ac_Header=no"
6149 rm -f conftest.err conftest.$ac_ext
6151 echo "$as_me:6151: result: `eval echo '${'$as_ac_Header'}'`" >&5
6152 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6153 if test `eval echo '${'$as_ac_Header'}'` = yes; then
6154 cat >>confdefs.h <<EOF
6155 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6161 cat >>confdefs.h <<\EOF
6165 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
6167 cat >>confdefs.h <<EOF
6168 #define $cf_nculib_ROOT 1
6171 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
6175 cf_ncuhdr_root=ncursesw
6177 test -n "$cf_cv_curses_dir" && \
6178 test "$cf_cv_curses_dir" != "no" && { \
6180 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
6181 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
6183 while test $cf_add_incdir != /usr/include
6185 if test -d $cf_add_incdir
6188 if test -n "$CFLAGS$CPPFLAGS" ; then
6189 # a loop is needed to ensure we can add subdirs of existing dirs
6190 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
6191 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
6192 cf_have_incdir=yes; break
6197 if test "$cf_have_incdir" = no ; then
6198 if test "$cf_add_incdir" = /usr/local/include ; then
6199 if test "$GCC" = yes
6201 cf_save_CPPFLAGS=$CPPFLAGS
6202 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6203 cat >conftest.$ac_ext <<_ACEOF
6204 #line 6204 "configure"
6205 #include "confdefs.h"
6215 rm -f conftest.$ac_objext
6216 if { (eval echo "$as_me:6216: \"$ac_compile\"") >&5
6217 (eval $ac_compile) 2>&5
6219 echo "$as_me:6219: \$? = $ac_status" >&5
6220 (exit $ac_status); } &&
6221 { ac_try='test -s conftest.$ac_objext'
6222 { (eval echo "$as_me:6222: \"$ac_try\"") >&5
6225 echo "$as_me:6225: \$? = $ac_status" >&5
6226 (exit $ac_status); }; }; then
6229 echo "$as_me: failed program was:" >&5
6230 cat conftest.$ac_ext >&5
6233 rm -f conftest.$ac_objext conftest.$ac_ext
6234 CPPFLAGS=$cf_save_CPPFLAGS
6239 if test "$cf_have_incdir" = no ; then
6240 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
6242 echo "${as_me:-configure}:6242: testing adding $cf_add_incdir to include-path ..." 1>&5
6244 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6246 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
6247 test "$cf_top_incdir" = "$cf_add_incdir" && break
6248 cf_add_incdir="$cf_top_incdir"
6261 echo "$as_me:6261: checking for $cf_ncuhdr_root header in include-path" >&5
6262 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
6263 if test "${cf_cv_ncurses_h+set}" = set; then
6264 echo $ECHO_N "(cached) $ECHO_C" >&6
6267 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
6268 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
6269 for cf_header in $cf_header_list
6272 cat >conftest.$ac_ext <<_ACEOF
6273 #line 6273 "configure"
6274 #include "confdefs.h"
6276 #define _XOPEN_SOURCE_EXTENDED
6277 #undef HAVE_LIBUTF8_H /* in case we used CF_UTF8_LIB */
6278 #define HAVE_LIBUTF8_H /* to force ncurses' header file to use cchar_t */
6280 #include <$cf_header>
6285 #ifdef NCURSES_VERSION
6291 printf("%s\n", NCURSES_VERSION);
6304 rm -f conftest.$ac_objext
6305 if { (eval echo "$as_me:6305: \"$ac_compile\"") >&5
6306 (eval $ac_compile) 2>&5
6308 echo "$as_me:6308: \$? = $ac_status" >&5
6309 (exit $ac_status); } &&
6310 { ac_try='test -s conftest.$ac_objext'
6311 { (eval echo "$as_me:6311: \"$ac_try\"") >&5
6314 echo "$as_me:6314: \$? = $ac_status" >&5
6315 (exit $ac_status); }; }; then
6316 cf_cv_ncurses_h=$cf_header
6319 echo "$as_me: failed program was:" >&5
6320 cat conftest.$ac_ext >&5
6323 rm -f conftest.$ac_objext conftest.$ac_ext
6325 test "$cf_cv_ncurses_h" != no && break
6329 echo "$as_me:6329: result: $cf_cv_ncurses_h" >&5
6330 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
6332 if test "$cf_cv_ncurses_h" != no ; then
6333 cf_cv_ncurses_header=$cf_cv_ncurses_h
6336 echo "$as_me:6336: checking for $cf_ncuhdr_root include-path" >&5
6337 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
6338 if test "${cf_cv_ncurses_h2+set}" = set; then
6339 echo $ECHO_N "(cached) $ECHO_C" >&6
6342 test -n "$verbose" && echo
6346 # collect the current set of include-directories from compiler flags
6347 cf_header_path_list=""
6348 if test -n "${CFLAGS}${CPPFLAGS}" ; then
6349 for cf_header_path in $CPPFLAGS $CFLAGS
6351 case $cf_header_path in
6353 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
6355 test "x$cf_header_path" != "xNONE" && \
6356 test -d "$cf_header_path" && \
6358 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
6359 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
6360 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
6361 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
6362 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
6363 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"
6366 cf_header_path_list="$cf_header_path_list $cf_search"
6372 # add the variations for the package we are looking for
6376 test "x$prefix" != "xNONE" && \
6377 test -d "$prefix" && \
6379 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
6380 test -d $prefix/include && cf_search="$cf_search $prefix/include"
6381 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
6382 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
6383 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
6384 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
6387 for cf_subdir_prefix in \
6396 test "x$cf_subdir_prefix" != "x$prefix" && \
6397 test -d "$cf_subdir_prefix" && \
6398 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
6399 test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
6400 test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include"
6401 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root"
6402 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root/include"
6403 test -d $cf_subdir_prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include"
6404 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"
6409 test "$includedir" != NONE && \
6410 test "$includedir" != "/usr/include" && \
6411 test -d "$includedir" && {
6412 test -d $includedir && cf_search="$cf_search $includedir"
6413 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
6416 test "$oldincludedir" != NONE && \
6417 test "$oldincludedir" != "/usr/include" && \
6418 test -d "$oldincludedir" && {
6419 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
6420 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
6423 cf_search="$cf_search $cf_header_path_list"
6425 test -n "$verbose" && echo search path $cf_search
6426 cf_save2_CPPFLAGS="$CPPFLAGS"
6427 for cf_incdir in $cf_search
6430 if test -n "$cf_incdir" ; then
6431 for cf_add_incdir in $cf_incdir
6433 while test $cf_add_incdir != /usr/include
6435 if test -d $cf_add_incdir
6438 if test -n "$CFLAGS$CPPFLAGS" ; then
6439 # a loop is needed to ensure we can add subdirs of existing dirs
6440 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
6441 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
6442 cf_have_incdir=yes; break
6447 if test "$cf_have_incdir" = no ; then
6448 if test "$cf_add_incdir" = /usr/local/include ; then
6449 if test "$GCC" = yes
6451 cf_save_CPPFLAGS=$CPPFLAGS
6452 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6453 cat >conftest.$ac_ext <<_ACEOF
6454 #line 6454 "configure"
6455 #include "confdefs.h"
6465 rm -f conftest.$ac_objext
6466 if { (eval echo "$as_me:6466: \"$ac_compile\"") >&5
6467 (eval $ac_compile) 2>&5
6469 echo "$as_me:6469: \$? = $ac_status" >&5
6470 (exit $ac_status); } &&
6471 { ac_try='test -s conftest.$ac_objext'
6472 { (eval echo "$as_me:6472: \"$ac_try\"") >&5
6475 echo "$as_me:6475: \$? = $ac_status" >&5
6476 (exit $ac_status); }; }; then
6479 echo "$as_me: failed program was:" >&5
6480 cat conftest.$ac_ext >&5
6483 rm -f conftest.$ac_objext conftest.$ac_ext
6484 CPPFLAGS=$cf_save_CPPFLAGS
6489 if test "$cf_have_incdir" = no ; then
6490 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
6492 echo "${as_me:-configure}:6492: testing adding $cf_add_incdir to include-path ..." 1>&5
6494 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6496 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
6497 test "$cf_top_incdir" = "$cf_add_incdir" && break
6498 cf_add_incdir="$cf_top_incdir"
6514 cat >conftest.$ac_ext <<_ACEOF
6515 #line 6515 "configure"
6516 #include "confdefs.h"
6518 #include <$cf_header>
6523 #ifdef NCURSES_VERSION
6525 printf("%s\n", NCURSES_VERSION);
6538 rm -f conftest.$ac_objext
6539 if { (eval echo "$as_me:6539: \"$ac_compile\"") >&5
6540 (eval $ac_compile) 2>&5
6542 echo "$as_me:6542: \$? = $ac_status" >&5
6543 (exit $ac_status); } &&
6544 { ac_try='test -s conftest.$ac_objext'
6545 { (eval echo "$as_me:6545: \"$ac_try\"") >&5
6548 echo "$as_me:6548: \$? = $ac_status" >&5
6549 (exit $ac_status); }; }; then
6550 cf_cv_ncurses_h2=$cf_header
6553 echo "$as_me: failed program was:" >&5
6554 cat conftest.$ac_ext >&5
6557 rm -f conftest.$ac_objext conftest.$ac_ext
6559 if test "$cf_cv_ncurses_h2" != no ; then
6560 cf_cv_ncurses_h2=$cf_incdir/$cf_header
6561 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
6564 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
6566 CPPFLAGS="$cf_save2_CPPFLAGS"
6567 test "$cf_cv_ncurses_h2" != no && break
6569 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:6569: error: not found" >&5
6570 echo "$as_me: error: not found" >&2;}
6571 { (exit 1); exit 1; }; }
6574 echo "$as_me:6574: result: $cf_cv_ncurses_h2" >&5
6575 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
6577 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
6578 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
6579 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
6580 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
6583 if test -n "$cf_1st_incdir" ; then
6584 for cf_add_incdir in $cf_1st_incdir
6586 while test $cf_add_incdir != /usr/include
6588 if test -d $cf_add_incdir
6591 if test -n "$CFLAGS$CPPFLAGS" ; then
6592 # a loop is needed to ensure we can add subdirs of existing dirs
6593 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
6594 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
6595 cf_have_incdir=yes; break
6600 if test "$cf_have_incdir" = no ; then
6601 if test "$cf_add_incdir" = /usr/local/include ; then
6602 if test "$GCC" = yes
6604 cf_save_CPPFLAGS=$CPPFLAGS
6605 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6606 cat >conftest.$ac_ext <<_ACEOF
6607 #line 6607 "configure"
6608 #include "confdefs.h"
6618 rm -f conftest.$ac_objext
6619 if { (eval echo "$as_me:6619: \"$ac_compile\"") >&5
6620 (eval $ac_compile) 2>&5
6622 echo "$as_me:6622: \$? = $ac_status" >&5
6623 (exit $ac_status); } &&
6624 { ac_try='test -s conftest.$ac_objext'
6625 { (eval echo "$as_me:6625: \"$ac_try\"") >&5
6628 echo "$as_me:6628: \$? = $ac_status" >&5
6629 (exit $ac_status); }; }; then
6632 echo "$as_me: failed program was:" >&5
6633 cat conftest.$ac_ext >&5
6636 rm -f conftest.$ac_objext conftest.$ac_ext
6637 CPPFLAGS=$cf_save_CPPFLAGS
6642 if test "$cf_have_incdir" = no ; then
6643 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
6645 echo "${as_me:-configure}:6645: testing adding $cf_add_incdir to include-path ..." 1>&5
6647 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
6649 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
6650 test "$cf_top_incdir" = "$cf_add_incdir" && break
6651 cf_add_incdir="$cf_top_incdir"
6664 # Set definitions to allow ifdef'ing for ncurses.h
6666 case $cf_cv_ncurses_header in
6669 cat >>confdefs.h <<\EOF
6670 #define HAVE_NCURSES_H 1
6676 case $cf_cv_ncurses_header in
6677 (ncurses/curses.h|ncurses/ncurses.h)
6679 cat >>confdefs.h <<\EOF
6680 #define HAVE_NCURSES_NCURSES_H 1
6684 (ncursesw/curses.h|ncursesw/ncurses.h)
6686 cat >>confdefs.h <<\EOF
6687 #define HAVE_NCURSESW_NCURSES_H 1
6693 echo "$as_me:6693: checking for terminfo header" >&5
6694 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
6695 if test "${cf_cv_term_header+set}" = set; then
6696 echo $ECHO_N "(cached) $ECHO_C" >&6
6699 case ${cf_cv_ncurses_header} in
6700 (*/ncurses.h|*/ncursesw.h)
6701 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
6704 cf_term_header=term.h
6708 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
6710 cat >conftest.$ac_ext <<_ACEOF
6711 #line 6711 "configure"
6712 #include "confdefs.h"
6714 #include <${cf_cv_ncurses_header:-curses.h}>
6720 int x = auto_left_margin
6725 rm -f conftest.$ac_objext
6726 if { (eval echo "$as_me:6726: \"$ac_compile\"") >&5
6727 (eval $ac_compile) 2>&5
6729 echo "$as_me:6729: \$? = $ac_status" >&5
6730 (exit $ac_status); } &&
6731 { ac_try='test -s conftest.$ac_objext'
6732 { (eval echo "$as_me:6732: \"$ac_try\"") >&5
6735 echo "$as_me:6735: \$? = $ac_status" >&5
6736 (exit $ac_status); }; }; then
6738 cf_cv_term_header="$cf_test"
6740 echo "$as_me: failed program was:" >&5
6741 cat conftest.$ac_ext >&5
6743 cf_cv_term_header=unknown
6746 rm -f conftest.$ac_objext conftest.$ac_ext
6747 test "$cf_cv_term_header" != unknown && break
6751 echo "$as_me:6751: result: $cf_cv_term_header" >&5
6752 echo "${ECHO_T}$cf_cv_term_header" >&6
6754 # Set definitions to allow ifdef'ing to accommodate subdirectories
6756 case $cf_cv_term_header in
6759 cat >>confdefs.h <<\EOF
6760 #define HAVE_TERM_H 1
6766 case $cf_cv_term_header in
6769 cat >>confdefs.h <<\EOF
6770 #define HAVE_NCURSES_TERM_H 1
6776 cat >>confdefs.h <<\EOF
6777 #define HAVE_NCURSESW_TERM_H 1
6783 # some applications need this, but should check for NCURSES_VERSION
6785 cat >>confdefs.h <<\EOF
6789 echo "$as_me:6789: checking for ncurses version" >&5
6790 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
6791 if test "${cf_cv_ncurses_version+set}" = set; then
6792 echo $ECHO_N "(cached) $ECHO_C" >&6
6795 cf_cv_ncurses_version=no
6798 if test "$cross_compiling" = yes; then
6800 # This will not work if the preprocessor splits the line after the
6801 # Autoconf token. The 'unproto' program does that.
6802 cat > conftest.$ac_ext <<EOF
6803 #include <${cf_cv_ncurses_header:-curses.h}>
6805 #ifdef NCURSES_VERSION
6806 Autoconf NCURSES_VERSION
6814 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
6815 { (eval echo "$as_me:6815: \"$cf_try\"") >&5
6818 echo "$as_me:6818: \$? = $ac_status" >&5
6819 (exit $ac_status); }
6820 if test -f conftest.out ; then
6821 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
6822 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
6827 cat >conftest.$ac_ext <<_ACEOF
6828 #line 6828 "configure"
6829 #include "confdefs.h"
6831 #include <${cf_cv_ncurses_header:-curses.h}>
6835 FILE *fp = fopen("$cf_tempfile", "w");
6836 #ifdef NCURSES_VERSION
6837 # ifdef NCURSES_VERSION_PATCH
6838 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
6840 fprintf(fp, "%s\n", NCURSES_VERSION);
6844 fprintf(fp, "old\n");
6849 ${cf_cv_main_return:-return}(0);
6852 rm -f conftest$ac_exeext
6853 if { (eval echo "$as_me:6853: \"$ac_link\"") >&5
6854 (eval $ac_link) 2>&5
6856 echo "$as_me:6856: \$? = $ac_status" >&5
6857 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
6858 { (eval echo "$as_me:6858: \"$ac_try\"") >&5
6861 echo "$as_me:6861: \$? = $ac_status" >&5
6862 (exit $ac_status); }; }; then
6864 cf_cv_ncurses_version=`cat $cf_tempfile`
6866 echo "$as_me: program exited with status $ac_status" >&5
6867 echo "$as_me: failed program was:" >&5
6868 cat conftest.$ac_ext >&5
6870 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6875 echo "$as_me:6875: result: $cf_cv_ncurses_version" >&5
6876 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
6877 test "$cf_cv_ncurses_version" = no ||
6878 cat >>confdefs.h <<\EOF
6882 cf_nculib_root=ncursesw
6883 # This works, except for the special case where we find gpm, but
6884 # ncurses is in a nonstandard location via $LIBS, and we really want
6887 cf_ncurses_SAVE="$LIBS"
6888 echo "$as_me:6888: checking for Gpm_Open in -lgpm" >&5
6889 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
6890 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
6891 echo $ECHO_N "(cached) $ECHO_C" >&6
6893 ac_check_lib_save_LIBS=$LIBS
6895 cat >conftest.$ac_ext <<_ACEOF
6896 #line 6896 "configure"
6897 #include "confdefs.h"
6899 /* Override any gcc2 internal prototype to avoid an error. */
6903 /* We use char because int might match the return type of a gcc2
6904 builtin and then its argument prototype would still apply. */
6914 rm -f conftest.$ac_objext conftest$ac_exeext
6915 if { (eval echo "$as_me:6915: \"$ac_link\"") >&5
6916 (eval $ac_link) 2>&5
6918 echo "$as_me:6918: \$? = $ac_status" >&5
6919 (exit $ac_status); } &&
6920 { ac_try='test -s conftest$ac_exeext'
6921 { (eval echo "$as_me:6921: \"$ac_try\"") >&5
6924 echo "$as_me:6924: \$? = $ac_status" >&5
6925 (exit $ac_status); }; }; then
6926 ac_cv_lib_gpm_Gpm_Open=yes
6928 echo "$as_me: failed program was:" >&5
6929 cat conftest.$ac_ext >&5
6930 ac_cv_lib_gpm_Gpm_Open=no
6932 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6933 LIBS=$ac_check_lib_save_LIBS
6935 echo "$as_me:6935: result: $ac_cv_lib_gpm_Gpm_Open" >&5
6936 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
6937 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
6938 echo "$as_me:6938: checking for initscr in -lgpm" >&5
6939 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
6940 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
6941 echo $ECHO_N "(cached) $ECHO_C" >&6
6943 ac_check_lib_save_LIBS=$LIBS
6945 cat >conftest.$ac_ext <<_ACEOF
6946 #line 6946 "configure"
6947 #include "confdefs.h"
6949 /* Override any gcc2 internal prototype to avoid an error. */
6953 /* We use char because int might match the return type of a gcc2
6954 builtin and then its argument prototype would still apply. */
6964 rm -f conftest.$ac_objext conftest$ac_exeext
6965 if { (eval echo "$as_me:6965: \"$ac_link\"") >&5
6966 (eval $ac_link) 2>&5
6968 echo "$as_me:6968: \$? = $ac_status" >&5
6969 (exit $ac_status); } &&
6970 { ac_try='test -s conftest$ac_exeext'
6971 { (eval echo "$as_me:6971: \"$ac_try\"") >&5
6974 echo "$as_me:6974: \$? = $ac_status" >&5
6975 (exit $ac_status); }; }; then
6976 ac_cv_lib_gpm_initscr=yes
6978 echo "$as_me: failed program was:" >&5
6979 cat conftest.$ac_ext >&5
6980 ac_cv_lib_gpm_initscr=no
6982 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6983 LIBS=$ac_check_lib_save_LIBS
6985 echo "$as_me:6985: result: $ac_cv_lib_gpm_initscr" >&5
6986 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
6987 if test $ac_cv_lib_gpm_initscr = yes; then
6988 LIBS="$cf_ncurses_SAVE"
6990 cf_ncurses_LIBS="-lgpm"
6997 # This is only necessary if you are linking against an obsolete
6998 # version of ncurses (but it should do no harm, since it's static).
6999 if test "$cf_nculib_root" = ncurses ; then
7000 echo "$as_me:7000: checking for tgoto in -lmytinfo" >&5
7001 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
7002 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
7003 echo $ECHO_N "(cached) $ECHO_C" >&6
7005 ac_check_lib_save_LIBS=$LIBS
7006 LIBS="-lmytinfo $LIBS"
7007 cat >conftest.$ac_ext <<_ACEOF
7008 #line 7008 "configure"
7009 #include "confdefs.h"
7011 /* Override any gcc2 internal prototype to avoid an error. */
7015 /* We use char because int might match the return type of a gcc2
7016 builtin and then its argument prototype would still apply. */
7026 rm -f conftest.$ac_objext conftest$ac_exeext
7027 if { (eval echo "$as_me:7027: \"$ac_link\"") >&5
7028 (eval $ac_link) 2>&5
7030 echo "$as_me:7030: \$? = $ac_status" >&5
7031 (exit $ac_status); } &&
7032 { ac_try='test -s conftest$ac_exeext'
7033 { (eval echo "$as_me:7033: \"$ac_try\"") >&5
7036 echo "$as_me:7036: \$? = $ac_status" >&5
7037 (exit $ac_status); }; }; then
7038 ac_cv_lib_mytinfo_tgoto=yes
7040 echo "$as_me: failed program was:" >&5
7041 cat conftest.$ac_ext >&5
7042 ac_cv_lib_mytinfo_tgoto=no
7044 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7045 LIBS=$ac_check_lib_save_LIBS
7047 echo "$as_me:7047: result: $ac_cv_lib_mytinfo_tgoto" >&5
7048 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
7049 if test $ac_cv_lib_mytinfo_tgoto = yes; then
7050 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
7057 cf_add_libs="$cf_ncurses_LIBS"
7058 # Filter out duplicates - this happens with badly-designed ".pc" files...
7059 for cf_add_1lib in $LIBS
7061 for cf_add_2lib in $cf_add_libs
7063 if test "x$cf_add_1lib" = "x$cf_add_2lib"
7069 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
7073 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
7076 cf_add_libs="-l$cf_nculib_root"
7077 # Filter out duplicates - this happens with badly-designed ".pc" files...
7078 for cf_add_1lib in $LIBS
7080 for cf_add_2lib in $cf_add_libs
7082 if test "x$cf_add_1lib" = "x$cf_add_2lib"
7088 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
7094 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
7096 echo "$as_me:7096: checking for initscr" >&5
7097 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
7098 if test "${ac_cv_func_initscr+set}" = set; then
7099 echo $ECHO_N "(cached) $ECHO_C" >&6
7101 cat >conftest.$ac_ext <<_ACEOF
7102 #line 7102 "configure"
7103 #include "confdefs.h"
7104 /* System header to define __stub macros and hopefully few prototypes,
7105 which can conflict with char initscr (); below. */
7107 /* Override any gcc2 internal prototype to avoid an error. */
7111 /* We use char because int might match the return type of a gcc2
7112 builtin and then its argument prototype would still apply. */
7119 /* The GNU C library defines this for functions which it implements
7120 to always fail with ENOSYS. Some functions are actually named
7121 something starting with __ and the normal name is an alias. */
7122 #if defined (__stub_initscr) || defined (__stub___initscr)
7125 f = initscr; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
7132 rm -f conftest.$ac_objext conftest$ac_exeext
7133 if { (eval echo "$as_me:7133: \"$ac_link\"") >&5
7134 (eval $ac_link) 2>&5
7136 echo "$as_me:7136: \$? = $ac_status" >&5
7137 (exit $ac_status); } &&
7138 { ac_try='test -s conftest$ac_exeext'
7139 { (eval echo "$as_me:7139: \"$ac_try\"") >&5
7142 echo "$as_me:7142: \$? = $ac_status" >&5
7143 (exit $ac_status); }; }; then
7144 ac_cv_func_initscr=yes
7146 echo "$as_me: failed program was:" >&5
7147 cat conftest.$ac_ext >&5
7148 ac_cv_func_initscr=no
7150 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7152 echo "$as_me:7152: result: $ac_cv_func_initscr" >&5
7153 echo "${ECHO_T}$ac_cv_func_initscr" >&6
7154 if test $ac_cv_func_initscr = yes; then
7155 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
7158 cf_save_LIBS="$LIBS"
7159 echo "$as_me:7159: checking for initscr in -l$cf_nculib_root" >&5
7160 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
7161 LIBS="-l$cf_nculib_root $LIBS"
7162 cat >conftest.$ac_ext <<_ACEOF
7163 #line 7163 "configure"
7164 #include "confdefs.h"
7165 #include <${cf_cv_ncurses_header:-curses.h}>
7174 rm -f conftest.$ac_objext conftest$ac_exeext
7175 if { (eval echo "$as_me:7175: \"$ac_link\"") >&5
7176 (eval $ac_link) 2>&5
7178 echo "$as_me:7178: \$? = $ac_status" >&5
7179 (exit $ac_status); } &&
7180 { ac_try='test -s conftest$ac_exeext'
7181 { (eval echo "$as_me:7181: \"$ac_try\"") >&5
7184 echo "$as_me:7184: \$? = $ac_status" >&5
7185 (exit $ac_status); }; }; then
7186 echo "$as_me:7186: result: yes" >&5
7187 echo "${ECHO_T}yes" >&6
7188 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
7191 echo "$as_me: failed program was:" >&5
7192 cat conftest.$ac_ext >&5
7193 echo "$as_me:7193: result: no" >&5
7194 echo "${ECHO_T}no" >&6
7197 cf_library_path_list=""
7198 if test -n "${LDFLAGS}${LIBS}" ; then
7199 for cf_library_path in $LDFLAGS $LIBS
7201 case $cf_library_path in
7203 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
7205 test "x$cf_library_path" != "xNONE" && \
7206 test -d "$cf_library_path" && \
7208 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
7209 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
7210 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
7211 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
7212 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
7213 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"
7216 cf_library_path_list="$cf_library_path_list $cf_search"
7224 test "x$prefix" != "xNONE" && \
7225 test -d "$prefix" && \
7227 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
7228 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
7229 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
7230 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
7231 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
7232 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
7235 for cf_subdir_prefix in \
7244 test "x$cf_subdir_prefix" != "x$prefix" && \
7245 test -d "$cf_subdir_prefix" && \
7246 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
7247 test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
7248 test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib"
7249 test -d $cf_subdir_prefix/lib/$cf_nculib_root && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root"
7250 test -d $cf_subdir_prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root/lib"
7251 test -d $cf_subdir_prefix/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib"
7252 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"
7257 cf_search="$cf_library_path_list $cf_search"
7259 for cf_libdir in $cf_search
7261 echo "$as_me:7261: checking for -l$cf_nculib_root in $cf_libdir" >&5
7262 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
7263 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
7264 cat >conftest.$ac_ext <<_ACEOF
7265 #line 7265 "configure"
7266 #include "confdefs.h"
7267 #include <${cf_cv_ncurses_header:-curses.h}>
7276 rm -f conftest.$ac_objext conftest$ac_exeext
7277 if { (eval echo "$as_me:7277: \"$ac_link\"") >&5
7278 (eval $ac_link) 2>&5
7280 echo "$as_me:7280: \$? = $ac_status" >&5
7281 (exit $ac_status); } &&
7282 { ac_try='test -s conftest$ac_exeext'
7283 { (eval echo "$as_me:7283: \"$ac_try\"") >&5
7286 echo "$as_me:7286: \$? = $ac_status" >&5
7287 (exit $ac_status); }; }; then
7288 echo "$as_me:7288: result: yes" >&5
7289 echo "${ECHO_T}yes" >&6
7290 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
7293 echo "$as_me: failed program was:" >&5
7294 cat conftest.$ac_ext >&5
7295 echo "$as_me:7295: result: no" >&5
7296 echo "${ECHO_T}no" >&6
7297 LIBS="$cf_save_LIBS"
7299 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7303 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7307 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
7309 if test $cf_found_library = no ; then
7310 { { echo "$as_me:7310: error: Cannot link $cf_nculib_root library" >&5
7311 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
7312 { (exit 1); exit 1; }; }
7317 if test -n "$cf_ncurses_LIBS" ; then
7318 echo "$as_me:7318: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
7319 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
7320 cf_ncurses_SAVE="$LIBS"
7321 for p in $cf_ncurses_LIBS ; do
7322 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
7323 if test "$q" != "$LIBS" ; then
7327 cat >conftest.$ac_ext <<_ACEOF
7328 #line 7328 "configure"
7329 #include "confdefs.h"
7330 #include <${cf_cv_ncurses_header:-curses.h}>
7334 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
7339 rm -f conftest.$ac_objext conftest$ac_exeext
7340 if { (eval echo "$as_me:7340: \"$ac_link\"") >&5
7341 (eval $ac_link) 2>&5
7343 echo "$as_me:7343: \$? = $ac_status" >&5
7344 (exit $ac_status); } &&
7345 { ac_try='test -s conftest$ac_exeext'
7346 { (eval echo "$as_me:7346: \"$ac_try\"") >&5
7349 echo "$as_me:7349: \$? = $ac_status" >&5
7350 (exit $ac_status); }; }; then
7351 echo "$as_me:7351: result: yes" >&5
7352 echo "${ECHO_T}yes" >&6
7354 echo "$as_me: failed program was:" >&5
7355 cat conftest.$ac_ext >&5
7356 echo "$as_me:7356: result: no" >&5
7357 echo "${ECHO_T}no" >&6
7358 LIBS="$cf_ncurses_SAVE"
7360 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7363 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
7365 cat >>confdefs.h <<EOF
7366 #define $cf_nculib_ROOT 1
7376 cf_ncuconfig_root=ncurses
7377 cf_have_ncuconfig=no
7379 if test "x${PKG_CONFIG:=none}" != xnone; then
7380 echo "$as_me:7380: checking pkg-config for $cf_ncuconfig_root" >&5
7381 echo $ECHO_N "checking pkg-config for $cf_ncuconfig_root... $ECHO_C" >&6
7382 if "$PKG_CONFIG" --exists $cf_ncuconfig_root ; then
7383 echo "$as_me:7383: result: yes" >&5
7384 echo "${ECHO_T}yes" >&6
7386 echo "$as_me:7386: checking if the $cf_ncuconfig_root package files work" >&5
7387 echo $ECHO_N "checking if the $cf_ncuconfig_root package files work... $ECHO_C" >&6
7388 cf_have_ncuconfig=unknown
7390 cf_save_CPPFLAGS="$CPPFLAGS"
7391 cf_save_LIBS="$LIBS"
7393 CPPFLAGS="$CPPFLAGS `$PKG_CONFIG --cflags $cf_ncuconfig_root`"
7395 cf_add_libs="`$PKG_CONFIG --libs $cf_ncuconfig_root`"
7396 # Filter out duplicates - this happens with badly-designed ".pc" files...
7397 for cf_add_1lib in $LIBS
7399 for cf_add_2lib in $cf_add_libs
7401 if test "x$cf_add_1lib" = "x$cf_add_2lib"
7407 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
7411 cat >conftest.$ac_ext <<_ACEOF
7412 #line 7412 "configure"
7413 #include "confdefs.h"
7414 #include <${cf_cv_ncurses_header:-curses.h}>
7418 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
7423 rm -f conftest.$ac_objext conftest$ac_exeext
7424 if { (eval echo "$as_me:7424: \"$ac_link\"") >&5
7425 (eval $ac_link) 2>&5
7427 echo "$as_me:7427: \$? = $ac_status" >&5
7428 (exit $ac_status); } &&
7429 { ac_try='test -s conftest$ac_exeext'
7430 { (eval echo "$as_me:7430: \"$ac_try\"") >&5
7433 echo "$as_me:7433: \$? = $ac_status" >&5
7434 (exit $ac_status); }; }; then
7435 if test "$cross_compiling" = yes; then
7436 cf_have_ncuconfig=maybe
7438 cat >conftest.$ac_ext <<_ACEOF
7439 #line 7439 "configure"
7440 #include "confdefs.h"
7441 #include <${cf_cv_ncurses_header:-curses.h}>
7443 { char *xx = curses_version(); return (xx == 0); }
7445 rm -f conftest$ac_exeext
7446 if { (eval echo "$as_me:7446: \"$ac_link\"") >&5
7447 (eval $ac_link) 2>&5
7449 echo "$as_me:7449: \$? = $ac_status" >&5
7450 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
7451 { (eval echo "$as_me:7451: \"$ac_try\"") >&5
7454 echo "$as_me:7454: \$? = $ac_status" >&5
7455 (exit $ac_status); }; }; then
7456 cf_have_ncuconfig=yes
7458 echo "$as_me: program exited with status $ac_status" >&5
7459 echo "$as_me: failed program was:" >&5
7460 cat conftest.$ac_ext >&5
7461 cf_have_ncuconfig=no
7463 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
7466 echo "$as_me: failed program was:" >&5
7467 cat conftest.$ac_ext >&5
7468 cf_have_ncuconfig=no
7470 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7471 echo "$as_me:7471: result: $cf_have_ncuconfig" >&5
7472 echo "${ECHO_T}$cf_have_ncuconfig" >&6
7473 test "$cf_have_ncuconfig" = maybe && cf_have_ncuconfig=yes
7474 if test "$cf_have_ncuconfig" != "yes"
7476 CPPFLAGS="$cf_save_CPPFLAGS"
7477 LIBS="$cf_save_LIBS"
7478 NCURSES_CONFIG_PKG=none
7481 cat >>confdefs.h <<\EOF
7485 NCURSES_CONFIG_PKG=$cf_ncuconfig_root
7489 echo "$as_me:7489: result: no" >&5
7490 echo "${ECHO_T}no" >&6
7491 NCURSES_CONFIG_PKG=none
7494 NCURSES_CONFIG_PKG=none
7497 if test "x$cf_have_ncuconfig" = "xno"; then
7498 echo "Looking for ${cf_ncuconfig_root}-config"
7500 if test -n "$ac_tool_prefix"; then
7501 for ac_prog in ${cf_ncuconfig_root}-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
7503 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
7504 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
7505 echo "$as_me:7505: checking for $ac_word" >&5
7506 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7507 if test "${ac_cv_prog_NCURSES_CONFIG+set}" = set; then
7508 echo $ECHO_N "(cached) $ECHO_C" >&6
7510 if test -n "$NCURSES_CONFIG"; then
7511 ac_cv_prog_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test.
7513 ac_save_IFS=$IFS; IFS=$ac_path_separator
7515 for ac_dir in $ac_dummy; do
7517 test -z "$ac_dir" && ac_dir=.
7518 $as_executable_p "$ac_dir/$ac_word" || continue
7519 ac_cv_prog_NCURSES_CONFIG="$ac_tool_prefix$ac_prog"
7520 echo "$as_me:7520: found $ac_dir/$ac_word" >&5
7526 NCURSES_CONFIG=$ac_cv_prog_NCURSES_CONFIG
7527 if test -n "$NCURSES_CONFIG"; then
7528 echo "$as_me:7528: result: $NCURSES_CONFIG" >&5
7529 echo "${ECHO_T}$NCURSES_CONFIG" >&6
7531 echo "$as_me:7531: result: no" >&5
7532 echo "${ECHO_T}no" >&6
7535 test -n "$NCURSES_CONFIG" && break
7538 if test -z "$NCURSES_CONFIG"; then
7539 ac_ct_NCURSES_CONFIG=$NCURSES_CONFIG
7540 for ac_prog in ${cf_ncuconfig_root}-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
7542 # Extract the first word of "$ac_prog", so it can be a program name with args.
7543 set dummy $ac_prog; ac_word=$2
7544 echo "$as_me:7544: checking for $ac_word" >&5
7545 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7546 if test "${ac_cv_prog_ac_ct_NCURSES_CONFIG+set}" = set; then
7547 echo $ECHO_N "(cached) $ECHO_C" >&6
7549 if test -n "$ac_ct_NCURSES_CONFIG"; then
7550 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_ct_NCURSES_CONFIG" # Let the user override the test.
7552 ac_save_IFS=$IFS; IFS=$ac_path_separator
7554 for ac_dir in $ac_dummy; do
7556 test -z "$ac_dir" && ac_dir=.
7557 $as_executable_p "$ac_dir/$ac_word" || continue
7558 ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_prog"
7559 echo "$as_me:7559: found $ac_dir/$ac_word" >&5
7565 ac_ct_NCURSES_CONFIG=$ac_cv_prog_ac_ct_NCURSES_CONFIG
7566 if test -n "$ac_ct_NCURSES_CONFIG"; then
7567 echo "$as_me:7567: result: $ac_ct_NCURSES_CONFIG" >&5
7568 echo "${ECHO_T}$ac_ct_NCURSES_CONFIG" >&6
7570 echo "$as_me:7570: result: no" >&5
7571 echo "${ECHO_T}no" >&6
7574 test -n "$ac_ct_NCURSES_CONFIG" && break
7576 test -n "$ac_ct_NCURSES_CONFIG" || ac_ct_NCURSES_CONFIG="none"
7578 NCURSES_CONFIG=$ac_ct_NCURSES_CONFIG
7581 if test "$NCURSES_CONFIG" != none ; then
7583 CPPFLAGS="$CPPFLAGS `$NCURSES_CONFIG --cflags`"
7585 cf_add_libs="`$NCURSES_CONFIG --libs`"
7586 # Filter out duplicates - this happens with badly-designed ".pc" files...
7587 for cf_add_1lib in $LIBS
7589 for cf_add_2lib in $cf_add_libs
7591 if test "x$cf_add_1lib" = "x$cf_add_2lib"
7597 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
7601 # even with config script, some packages use no-override for curses.h
7603 echo "$as_me:7603: checking if we have identified curses headers" >&5
7604 echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
7605 if test "${cf_cv_ncurses_header+set}" = set; then
7606 echo $ECHO_N "(cached) $ECHO_C" >&6
7609 cf_cv_ncurses_header=none
7611 ncurses.h ncurses/ncurses.h \
7612 curses.h ncurses/curses.h
7614 cat >conftest.$ac_ext <<_ACEOF
7615 #line 7615 "configure"
7616 #include "confdefs.h"
7617 #include <${cf_header}>
7621 initscr(); tgoto("?", 0,0)
7626 rm -f conftest.$ac_objext
7627 if { (eval echo "$as_me:7627: \"$ac_compile\"") >&5
7628 (eval $ac_compile) 2>&5
7630 echo "$as_me:7630: \$? = $ac_status" >&5
7631 (exit $ac_status); } &&
7632 { ac_try='test -s conftest.$ac_objext'
7633 { (eval echo "$as_me:7633: \"$ac_try\"") >&5
7636 echo "$as_me:7636: \$? = $ac_status" >&5
7637 (exit $ac_status); }; }; then
7638 cf_cv_ncurses_header=$cf_header; break
7640 echo "$as_me: failed program was:" >&5
7641 cat conftest.$ac_ext >&5
7643 rm -f conftest.$ac_objext conftest.$ac_ext
7647 echo "$as_me:7647: result: $cf_cv_ncurses_header" >&5
7648 echo "${ECHO_T}$cf_cv_ncurses_header" >&6
7650 if test "$cf_cv_ncurses_header" = none ; then
7651 { { echo "$as_me:7651: error: No curses header-files found" >&5
7652 echo "$as_me: error: No curses header-files found" >&2;}
7653 { (exit 1); exit 1; }; }
7656 # cheat, to get the right #define's for HAVE_NCURSES_H, etc.
7658 for ac_header in $cf_cv_ncurses_header
7660 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7661 echo "$as_me:7661: checking for $ac_header" >&5
7662 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7663 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7664 echo $ECHO_N "(cached) $ECHO_C" >&6
7666 cat >conftest.$ac_ext <<_ACEOF
7667 #line 7667 "configure"
7668 #include "confdefs.h"
7669 #include <$ac_header>
7671 if { (eval echo "$as_me:7671: \"$ac_cpp conftest.$ac_ext\"") >&5
7672 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7674 egrep -v '^ *\+' conftest.er1 >conftest.err
7676 cat conftest.err >&5
7677 echo "$as_me:7677: \$? = $ac_status" >&5
7678 (exit $ac_status); } >/dev/null; then
7679 if test -s conftest.err; then
7680 ac_cpp_err=$ac_c_preproc_warn_flag
7687 if test -z "$ac_cpp_err"; then
7688 eval "$as_ac_Header=yes"
7690 echo "$as_me: failed program was:" >&5
7691 cat conftest.$ac_ext >&5
7692 eval "$as_ac_Header=no"
7694 rm -f conftest.err conftest.$ac_ext
7696 echo "$as_me:7696: result: `eval echo '${'$as_ac_Header'}'`" >&5
7697 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7698 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7699 cat >>confdefs.h <<EOF
7700 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7706 cat >>confdefs.h <<\EOF
7710 cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
7712 cat >>confdefs.h <<EOF
7713 #define $cf_nculib_ROOT 1
7716 cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
7720 cf_ncuhdr_root=ncurses
7722 test -n "$cf_cv_curses_dir" && \
7723 test "$cf_cv_curses_dir" != "no" && { \
7725 if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
7726 for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
7728 while test $cf_add_incdir != /usr/include
7730 if test -d $cf_add_incdir
7733 if test -n "$CFLAGS$CPPFLAGS" ; then
7734 # a loop is needed to ensure we can add subdirs of existing dirs
7735 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
7736 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
7737 cf_have_incdir=yes; break
7742 if test "$cf_have_incdir" = no ; then
7743 if test "$cf_add_incdir" = /usr/local/include ; then
7744 if test "$GCC" = yes
7746 cf_save_CPPFLAGS=$CPPFLAGS
7747 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7748 cat >conftest.$ac_ext <<_ACEOF
7749 #line 7749 "configure"
7750 #include "confdefs.h"
7760 rm -f conftest.$ac_objext
7761 if { (eval echo "$as_me:7761: \"$ac_compile\"") >&5
7762 (eval $ac_compile) 2>&5
7764 echo "$as_me:7764: \$? = $ac_status" >&5
7765 (exit $ac_status); } &&
7766 { ac_try='test -s conftest.$ac_objext'
7767 { (eval echo "$as_me:7767: \"$ac_try\"") >&5
7770 echo "$as_me:7770: \$? = $ac_status" >&5
7771 (exit $ac_status); }; }; then
7774 echo "$as_me: failed program was:" >&5
7775 cat conftest.$ac_ext >&5
7778 rm -f conftest.$ac_objext conftest.$ac_ext
7779 CPPFLAGS=$cf_save_CPPFLAGS
7784 if test "$cf_have_incdir" = no ; then
7785 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
7787 echo "${as_me:-configure}:7787: testing adding $cf_add_incdir to include-path ..." 1>&5
7789 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7791 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
7792 test "$cf_top_incdir" = "$cf_add_incdir" && break
7793 cf_add_incdir="$cf_top_incdir"
7806 echo "$as_me:7806: checking for $cf_ncuhdr_root header in include-path" >&5
7807 echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
7808 if test "${cf_cv_ncurses_h+set}" = set; then
7809 echo $ECHO_N "(cached) $ECHO_C" >&6
7812 cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
7813 ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
7814 for cf_header in $cf_header_list
7817 cat >conftest.$ac_ext <<_ACEOF
7818 #line 7818 "configure"
7819 #include "confdefs.h"
7821 #include <$cf_header>
7826 #ifdef NCURSES_VERSION
7828 printf("%s\n", NCURSES_VERSION);
7841 rm -f conftest.$ac_objext
7842 if { (eval echo "$as_me:7842: \"$ac_compile\"") >&5
7843 (eval $ac_compile) 2>&5
7845 echo "$as_me:7845: \$? = $ac_status" >&5
7846 (exit $ac_status); } &&
7847 { ac_try='test -s conftest.$ac_objext'
7848 { (eval echo "$as_me:7848: \"$ac_try\"") >&5
7851 echo "$as_me:7851: \$? = $ac_status" >&5
7852 (exit $ac_status); }; }; then
7853 cf_cv_ncurses_h=$cf_header
7856 echo "$as_me: failed program was:" >&5
7857 cat conftest.$ac_ext >&5
7860 rm -f conftest.$ac_objext conftest.$ac_ext
7862 test "$cf_cv_ncurses_h" != no && break
7866 echo "$as_me:7866: result: $cf_cv_ncurses_h" >&5
7867 echo "${ECHO_T}$cf_cv_ncurses_h" >&6
7869 if test "$cf_cv_ncurses_h" != no ; then
7870 cf_cv_ncurses_header=$cf_cv_ncurses_h
7873 echo "$as_me:7873: checking for $cf_ncuhdr_root include-path" >&5
7874 echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
7875 if test "${cf_cv_ncurses_h2+set}" = set; then
7876 echo $ECHO_N "(cached) $ECHO_C" >&6
7879 test -n "$verbose" && echo
7883 # collect the current set of include-directories from compiler flags
7884 cf_header_path_list=""
7885 if test -n "${CFLAGS}${CPPFLAGS}" ; then
7886 for cf_header_path in $CPPFLAGS $CFLAGS
7888 case $cf_header_path in
7890 cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
7892 test "x$cf_header_path" != "xNONE" && \
7893 test -d "$cf_header_path" && \
7895 test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
7896 test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
7897 test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
7898 test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
7899 test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
7900 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"
7903 cf_header_path_list="$cf_header_path_list $cf_search"
7909 # add the variations for the package we are looking for
7913 test "x$prefix" != "xNONE" && \
7914 test -d "$prefix" && \
7916 test -n "$verbose" && echo " ... testing for include-directories under $prefix"
7917 test -d $prefix/include && cf_search="$cf_search $prefix/include"
7918 test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
7919 test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
7920 test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
7921 test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
7924 for cf_subdir_prefix in \
7933 test "x$cf_subdir_prefix" != "x$prefix" && \
7934 test -d "$cf_subdir_prefix" && \
7935 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
7936 test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
7937 test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include"
7938 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root"
7939 test -d $cf_subdir_prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root/include"
7940 test -d $cf_subdir_prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include"
7941 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"
7946 test "$includedir" != NONE && \
7947 test "$includedir" != "/usr/include" && \
7948 test -d "$includedir" && {
7949 test -d $includedir && cf_search="$cf_search $includedir"
7950 test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
7953 test "$oldincludedir" != NONE && \
7954 test "$oldincludedir" != "/usr/include" && \
7955 test -d "$oldincludedir" && {
7956 test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
7957 test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
7960 cf_search="$cf_search $cf_header_path_list"
7962 test -n "$verbose" && echo search path $cf_search
7963 cf_save2_CPPFLAGS="$CPPFLAGS"
7964 for cf_incdir in $cf_search
7967 if test -n "$cf_incdir" ; then
7968 for cf_add_incdir in $cf_incdir
7970 while test $cf_add_incdir != /usr/include
7972 if test -d $cf_add_incdir
7975 if test -n "$CFLAGS$CPPFLAGS" ; then
7976 # a loop is needed to ensure we can add subdirs of existing dirs
7977 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
7978 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
7979 cf_have_incdir=yes; break
7984 if test "$cf_have_incdir" = no ; then
7985 if test "$cf_add_incdir" = /usr/local/include ; then
7986 if test "$GCC" = yes
7988 cf_save_CPPFLAGS=$CPPFLAGS
7989 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
7990 cat >conftest.$ac_ext <<_ACEOF
7991 #line 7991 "configure"
7992 #include "confdefs.h"
8002 rm -f conftest.$ac_objext
8003 if { (eval echo "$as_me:8003: \"$ac_compile\"") >&5
8004 (eval $ac_compile) 2>&5
8006 echo "$as_me:8006: \$? = $ac_status" >&5
8007 (exit $ac_status); } &&
8008 { ac_try='test -s conftest.$ac_objext'
8009 { (eval echo "$as_me:8009: \"$ac_try\"") >&5
8012 echo "$as_me:8012: \$? = $ac_status" >&5
8013 (exit $ac_status); }; }; then
8016 echo "$as_me: failed program was:" >&5
8017 cat conftest.$ac_ext >&5
8020 rm -f conftest.$ac_objext conftest.$ac_ext
8021 CPPFLAGS=$cf_save_CPPFLAGS
8026 if test "$cf_have_incdir" = no ; then
8027 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
8029 echo "${as_me:-configure}:8029: testing adding $cf_add_incdir to include-path ..." 1>&5
8031 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8033 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
8034 test "$cf_top_incdir" = "$cf_add_incdir" && break
8035 cf_add_incdir="$cf_top_incdir"
8051 cat >conftest.$ac_ext <<_ACEOF
8052 #line 8052 "configure"
8053 #include "confdefs.h"
8055 #include <$cf_header>
8060 #ifdef NCURSES_VERSION
8062 printf("%s\n", NCURSES_VERSION);
8075 rm -f conftest.$ac_objext
8076 if { (eval echo "$as_me:8076: \"$ac_compile\"") >&5
8077 (eval $ac_compile) 2>&5
8079 echo "$as_me:8079: \$? = $ac_status" >&5
8080 (exit $ac_status); } &&
8081 { ac_try='test -s conftest.$ac_objext'
8082 { (eval echo "$as_me:8082: \"$ac_try\"") >&5
8085 echo "$as_me:8085: \$? = $ac_status" >&5
8086 (exit $ac_status); }; }; then
8087 cf_cv_ncurses_h2=$cf_header
8090 echo "$as_me: failed program was:" >&5
8091 cat conftest.$ac_ext >&5
8094 rm -f conftest.$ac_objext conftest.$ac_ext
8096 if test "$cf_cv_ncurses_h2" != no ; then
8097 cf_cv_ncurses_h2=$cf_incdir/$cf_header
8098 test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
8101 test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
8103 CPPFLAGS="$cf_save2_CPPFLAGS"
8104 test "$cf_cv_ncurses_h2" != no && break
8106 test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:8106: error: not found" >&5
8107 echo "$as_me: error: not found" >&2;}
8108 { (exit 1); exit 1; }; }
8111 echo "$as_me:8111: result: $cf_cv_ncurses_h2" >&5
8112 echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
8114 cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
8115 cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
8116 if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
8117 cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
8120 if test -n "$cf_1st_incdir" ; then
8121 for cf_add_incdir in $cf_1st_incdir
8123 while test $cf_add_incdir != /usr/include
8125 if test -d $cf_add_incdir
8128 if test -n "$CFLAGS$CPPFLAGS" ; then
8129 # a loop is needed to ensure we can add subdirs of existing dirs
8130 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
8131 if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
8132 cf_have_incdir=yes; break
8137 if test "$cf_have_incdir" = no ; then
8138 if test "$cf_add_incdir" = /usr/local/include ; then
8139 if test "$GCC" = yes
8141 cf_save_CPPFLAGS=$CPPFLAGS
8142 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8143 cat >conftest.$ac_ext <<_ACEOF
8144 #line 8144 "configure"
8145 #include "confdefs.h"
8155 rm -f conftest.$ac_objext
8156 if { (eval echo "$as_me:8156: \"$ac_compile\"") >&5
8157 (eval $ac_compile) 2>&5
8159 echo "$as_me:8159: \$? = $ac_status" >&5
8160 (exit $ac_status); } &&
8161 { ac_try='test -s conftest.$ac_objext'
8162 { (eval echo "$as_me:8162: \"$ac_try\"") >&5
8165 echo "$as_me:8165: \$? = $ac_status" >&5
8166 (exit $ac_status); }; }; then
8169 echo "$as_me: failed program was:" >&5
8170 cat conftest.$ac_ext >&5
8173 rm -f conftest.$ac_objext conftest.$ac_ext
8174 CPPFLAGS=$cf_save_CPPFLAGS
8179 if test "$cf_have_incdir" = no ; then
8180 test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
8182 echo "${as_me:-configure}:8182: testing adding $cf_add_incdir to include-path ..." 1>&5
8184 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
8186 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
8187 test "$cf_top_incdir" = "$cf_add_incdir" && break
8188 cf_add_incdir="$cf_top_incdir"
8201 # Set definitions to allow ifdef'ing for ncurses.h
8203 case $cf_cv_ncurses_header in
8206 cat >>confdefs.h <<\EOF
8207 #define HAVE_NCURSES_H 1
8213 case $cf_cv_ncurses_header in
8214 (ncurses/curses.h|ncurses/ncurses.h)
8216 cat >>confdefs.h <<\EOF
8217 #define HAVE_NCURSES_NCURSES_H 1
8221 (ncursesw/curses.h|ncursesw/ncurses.h)
8223 cat >>confdefs.h <<\EOF
8224 #define HAVE_NCURSESW_NCURSES_H 1
8230 echo "$as_me:8230: checking for terminfo header" >&5
8231 echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
8232 if test "${cf_cv_term_header+set}" = set; then
8233 echo $ECHO_N "(cached) $ECHO_C" >&6
8236 case ${cf_cv_ncurses_header} in
8237 (*/ncurses.h|*/ncursesw.h)
8238 cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
8241 cf_term_header=term.h
8245 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
8247 cat >conftest.$ac_ext <<_ACEOF
8248 #line 8248 "configure"
8249 #include "confdefs.h"
8251 #include <${cf_cv_ncurses_header:-curses.h}>
8257 int x = auto_left_margin
8262 rm -f conftest.$ac_objext
8263 if { (eval echo "$as_me:8263: \"$ac_compile\"") >&5
8264 (eval $ac_compile) 2>&5
8266 echo "$as_me:8266: \$? = $ac_status" >&5
8267 (exit $ac_status); } &&
8268 { ac_try='test -s conftest.$ac_objext'
8269 { (eval echo "$as_me:8269: \"$ac_try\"") >&5
8272 echo "$as_me:8272: \$? = $ac_status" >&5
8273 (exit $ac_status); }; }; then
8275 cf_cv_term_header="$cf_test"
8277 echo "$as_me: failed program was:" >&5
8278 cat conftest.$ac_ext >&5
8280 cf_cv_term_header=unknown
8283 rm -f conftest.$ac_objext conftest.$ac_ext
8284 test "$cf_cv_term_header" != unknown && break
8288 echo "$as_me:8288: result: $cf_cv_term_header" >&5
8289 echo "${ECHO_T}$cf_cv_term_header" >&6
8291 # Set definitions to allow ifdef'ing to accommodate subdirectories
8293 case $cf_cv_term_header in
8296 cat >>confdefs.h <<\EOF
8297 #define HAVE_TERM_H 1
8303 case $cf_cv_term_header in
8306 cat >>confdefs.h <<\EOF
8307 #define HAVE_NCURSES_TERM_H 1
8313 cat >>confdefs.h <<\EOF
8314 #define HAVE_NCURSESW_TERM_H 1
8320 # some applications need this, but should check for NCURSES_VERSION
8322 cat >>confdefs.h <<\EOF
8326 echo "$as_me:8326: checking for ncurses version" >&5
8327 echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
8328 if test "${cf_cv_ncurses_version+set}" = set; then
8329 echo $ECHO_N "(cached) $ECHO_C" >&6
8332 cf_cv_ncurses_version=no
8335 if test "$cross_compiling" = yes; then
8337 # This will not work if the preprocessor splits the line after the
8338 # Autoconf token. The 'unproto' program does that.
8339 cat > conftest.$ac_ext <<EOF
8340 #include <${cf_cv_ncurses_header:-curses.h}>
8342 #ifdef NCURSES_VERSION
8343 Autoconf NCURSES_VERSION
8351 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
8352 { (eval echo "$as_me:8352: \"$cf_try\"") >&5
8355 echo "$as_me:8355: \$? = $ac_status" >&5
8356 (exit $ac_status); }
8357 if test -f conftest.out ; then
8358 cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
8359 test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
8364 cat >conftest.$ac_ext <<_ACEOF
8365 #line 8365 "configure"
8366 #include "confdefs.h"
8368 #include <${cf_cv_ncurses_header:-curses.h}>
8372 FILE *fp = fopen("$cf_tempfile", "w");
8373 #ifdef NCURSES_VERSION
8374 # ifdef NCURSES_VERSION_PATCH
8375 fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
8377 fprintf(fp, "%s\n", NCURSES_VERSION);
8381 fprintf(fp, "old\n");
8386 ${cf_cv_main_return:-return}(0);
8389 rm -f conftest$ac_exeext
8390 if { (eval echo "$as_me:8390: \"$ac_link\"") >&5
8391 (eval $ac_link) 2>&5
8393 echo "$as_me:8393: \$? = $ac_status" >&5
8394 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
8395 { (eval echo "$as_me:8395: \"$ac_try\"") >&5
8398 echo "$as_me:8398: \$? = $ac_status" >&5
8399 (exit $ac_status); }; }; then
8401 cf_cv_ncurses_version=`cat $cf_tempfile`
8403 echo "$as_me: program exited with status $ac_status" >&5
8404 echo "$as_me: failed program was:" >&5
8405 cat conftest.$ac_ext >&5
8407 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
8412 echo "$as_me:8412: result: $cf_cv_ncurses_version" >&5
8413 echo "${ECHO_T}$cf_cv_ncurses_version" >&6
8414 test "$cf_cv_ncurses_version" = no ||
8415 cat >>confdefs.h <<\EOF
8419 cf_nculib_root=ncurses
8420 # This works, except for the special case where we find gpm, but
8421 # ncurses is in a nonstandard location via $LIBS, and we really want
8424 cf_ncurses_SAVE="$LIBS"
8425 echo "$as_me:8425: checking for Gpm_Open in -lgpm" >&5
8426 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
8427 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
8428 echo $ECHO_N "(cached) $ECHO_C" >&6
8430 ac_check_lib_save_LIBS=$LIBS
8432 cat >conftest.$ac_ext <<_ACEOF
8433 #line 8433 "configure"
8434 #include "confdefs.h"
8436 /* Override any gcc2 internal prototype to avoid an error. */
8440 /* We use char because int might match the return type of a gcc2
8441 builtin and then its argument prototype would still apply. */
8451 rm -f conftest.$ac_objext conftest$ac_exeext
8452 if { (eval echo "$as_me:8452: \"$ac_link\"") >&5
8453 (eval $ac_link) 2>&5
8455 echo "$as_me:8455: \$? = $ac_status" >&5
8456 (exit $ac_status); } &&
8457 { ac_try='test -s conftest$ac_exeext'
8458 { (eval echo "$as_me:8458: \"$ac_try\"") >&5
8461 echo "$as_me:8461: \$? = $ac_status" >&5
8462 (exit $ac_status); }; }; then
8463 ac_cv_lib_gpm_Gpm_Open=yes
8465 echo "$as_me: failed program was:" >&5
8466 cat conftest.$ac_ext >&5
8467 ac_cv_lib_gpm_Gpm_Open=no
8469 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8470 LIBS=$ac_check_lib_save_LIBS
8472 echo "$as_me:8472: result: $ac_cv_lib_gpm_Gpm_Open" >&5
8473 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
8474 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
8475 echo "$as_me:8475: checking for initscr in -lgpm" >&5
8476 echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
8477 if test "${ac_cv_lib_gpm_initscr+set}" = set; then
8478 echo $ECHO_N "(cached) $ECHO_C" >&6
8480 ac_check_lib_save_LIBS=$LIBS
8482 cat >conftest.$ac_ext <<_ACEOF
8483 #line 8483 "configure"
8484 #include "confdefs.h"
8486 /* Override any gcc2 internal prototype to avoid an error. */
8490 /* We use char because int might match the return type of a gcc2
8491 builtin and then its argument prototype would still apply. */
8501 rm -f conftest.$ac_objext conftest$ac_exeext
8502 if { (eval echo "$as_me:8502: \"$ac_link\"") >&5
8503 (eval $ac_link) 2>&5
8505 echo "$as_me:8505: \$? = $ac_status" >&5
8506 (exit $ac_status); } &&
8507 { ac_try='test -s conftest$ac_exeext'
8508 { (eval echo "$as_me:8508: \"$ac_try\"") >&5
8511 echo "$as_me:8511: \$? = $ac_status" >&5
8512 (exit $ac_status); }; }; then
8513 ac_cv_lib_gpm_initscr=yes
8515 echo "$as_me: failed program was:" >&5
8516 cat conftest.$ac_ext >&5
8517 ac_cv_lib_gpm_initscr=no
8519 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8520 LIBS=$ac_check_lib_save_LIBS
8522 echo "$as_me:8522: result: $ac_cv_lib_gpm_initscr" >&5
8523 echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
8524 if test $ac_cv_lib_gpm_initscr = yes; then
8525 LIBS="$cf_ncurses_SAVE"
8527 cf_ncurses_LIBS="-lgpm"
8534 # This is only necessary if you are linking against an obsolete
8535 # version of ncurses (but it should do no harm, since it's static).
8536 if test "$cf_nculib_root" = ncurses ; then
8537 echo "$as_me:8537: checking for tgoto in -lmytinfo" >&5
8538 echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
8539 if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
8540 echo $ECHO_N "(cached) $ECHO_C" >&6
8542 ac_check_lib_save_LIBS=$LIBS
8543 LIBS="-lmytinfo $LIBS"
8544 cat >conftest.$ac_ext <<_ACEOF
8545 #line 8545 "configure"
8546 #include "confdefs.h"
8548 /* Override any gcc2 internal prototype to avoid an error. */
8552 /* We use char because int might match the return type of a gcc2
8553 builtin and then its argument prototype would still apply. */
8563 rm -f conftest.$ac_objext conftest$ac_exeext
8564 if { (eval echo "$as_me:8564: \"$ac_link\"") >&5
8565 (eval $ac_link) 2>&5
8567 echo "$as_me:8567: \$? = $ac_status" >&5
8568 (exit $ac_status); } &&
8569 { ac_try='test -s conftest$ac_exeext'
8570 { (eval echo "$as_me:8570: \"$ac_try\"") >&5
8573 echo "$as_me:8573: \$? = $ac_status" >&5
8574 (exit $ac_status); }; }; then
8575 ac_cv_lib_mytinfo_tgoto=yes
8577 echo "$as_me: failed program was:" >&5
8578 cat conftest.$ac_ext >&5
8579 ac_cv_lib_mytinfo_tgoto=no
8581 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8582 LIBS=$ac_check_lib_save_LIBS
8584 echo "$as_me:8584: result: $ac_cv_lib_mytinfo_tgoto" >&5
8585 echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
8586 if test $ac_cv_lib_mytinfo_tgoto = yes; then
8587 cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
8594 cf_add_libs="$cf_ncurses_LIBS"
8595 # Filter out duplicates - this happens with badly-designed ".pc" files...
8596 for cf_add_1lib in $LIBS
8598 for cf_add_2lib in $cf_add_libs
8600 if test "x$cf_add_1lib" = "x$cf_add_2lib"
8606 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
8610 if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
8613 cf_add_libs="-l$cf_nculib_root"
8614 # Filter out duplicates - this happens with badly-designed ".pc" files...
8615 for cf_add_1lib in $LIBS
8617 for cf_add_2lib in $cf_add_libs
8619 if test "x$cf_add_1lib" = "x$cf_add_2lib"
8625 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
8631 eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
8633 echo "$as_me:8633: checking for initscr" >&5
8634 echo $ECHO_N "checking for initscr... $ECHO_C" >&6
8635 if test "${ac_cv_func_initscr+set}" = set; then
8636 echo $ECHO_N "(cached) $ECHO_C" >&6
8638 cat >conftest.$ac_ext <<_ACEOF
8639 #line 8639 "configure"
8640 #include "confdefs.h"
8641 /* System header to define __stub macros and hopefully few prototypes,
8642 which can conflict with char initscr (); below. */
8644 /* Override any gcc2 internal prototype to avoid an error. */
8648 /* We use char because int might match the return type of a gcc2
8649 builtin and then its argument prototype would still apply. */
8656 /* The GNU C library defines this for functions which it implements
8657 to always fail with ENOSYS. Some functions are actually named
8658 something starting with __ and the normal name is an alias. */
8659 #if defined (__stub_initscr) || defined (__stub___initscr)
8662 f = initscr; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
8669 rm -f conftest.$ac_objext conftest$ac_exeext
8670 if { (eval echo "$as_me:8670: \"$ac_link\"") >&5
8671 (eval $ac_link) 2>&5
8673 echo "$as_me:8673: \$? = $ac_status" >&5
8674 (exit $ac_status); } &&
8675 { ac_try='test -s conftest$ac_exeext'
8676 { (eval echo "$as_me:8676: \"$ac_try\"") >&5
8679 echo "$as_me:8679: \$? = $ac_status" >&5
8680 (exit $ac_status); }; }; then
8681 ac_cv_func_initscr=yes
8683 echo "$as_me: failed program was:" >&5
8684 cat conftest.$ac_ext >&5
8685 ac_cv_func_initscr=no
8687 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8689 echo "$as_me:8689: result: $ac_cv_func_initscr" >&5
8690 echo "${ECHO_T}$ac_cv_func_initscr" >&6
8691 if test $ac_cv_func_initscr = yes; then
8692 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
8695 cf_save_LIBS="$LIBS"
8696 echo "$as_me:8696: checking for initscr in -l$cf_nculib_root" >&5
8697 echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
8698 LIBS="-l$cf_nculib_root $LIBS"
8699 cat >conftest.$ac_ext <<_ACEOF
8700 #line 8700 "configure"
8701 #include "confdefs.h"
8702 #include <${cf_cv_ncurses_header:-curses.h}>
8711 rm -f conftest.$ac_objext conftest$ac_exeext
8712 if { (eval echo "$as_me:8712: \"$ac_link\"") >&5
8713 (eval $ac_link) 2>&5
8715 echo "$as_me:8715: \$? = $ac_status" >&5
8716 (exit $ac_status); } &&
8717 { ac_try='test -s conftest$ac_exeext'
8718 { (eval echo "$as_me:8718: \"$ac_try\"") >&5
8721 echo "$as_me:8721: \$? = $ac_status" >&5
8722 (exit $ac_status); }; }; then
8723 echo "$as_me:8723: result: yes" >&5
8724 echo "${ECHO_T}yes" >&6
8725 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
8728 echo "$as_me: failed program was:" >&5
8729 cat conftest.$ac_ext >&5
8730 echo "$as_me:8730: result: no" >&5
8731 echo "${ECHO_T}no" >&6
8734 cf_library_path_list=""
8735 if test -n "${LDFLAGS}${LIBS}" ; then
8736 for cf_library_path in $LDFLAGS $LIBS
8738 case $cf_library_path in
8740 cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
8742 test "x$cf_library_path" != "xNONE" && \
8743 test -d "$cf_library_path" && \
8745 test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
8746 test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
8747 test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
8748 test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
8749 test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
8750 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"
8753 cf_library_path_list="$cf_library_path_list $cf_search"
8761 test "x$prefix" != "xNONE" && \
8762 test -d "$prefix" && \
8764 test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
8765 test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
8766 test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
8767 test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
8768 test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
8769 test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
8772 for cf_subdir_prefix in \
8781 test "x$cf_subdir_prefix" != "x$prefix" && \
8782 test -d "$cf_subdir_prefix" && \
8783 (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
8784 test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
8785 test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib"
8786 test -d $cf_subdir_prefix/lib/$cf_nculib_root && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root"
8787 test -d $cf_subdir_prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root/lib"
8788 test -d $cf_subdir_prefix/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib"
8789 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"
8794 cf_search="$cf_library_path_list $cf_search"
8796 for cf_libdir in $cf_search
8798 echo "$as_me:8798: checking for -l$cf_nculib_root in $cf_libdir" >&5
8799 echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
8800 LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
8801 cat >conftest.$ac_ext <<_ACEOF
8802 #line 8802 "configure"
8803 #include "confdefs.h"
8804 #include <${cf_cv_ncurses_header:-curses.h}>
8813 rm -f conftest.$ac_objext conftest$ac_exeext
8814 if { (eval echo "$as_me:8814: \"$ac_link\"") >&5
8815 (eval $ac_link) 2>&5
8817 echo "$as_me:8817: \$? = $ac_status" >&5
8818 (exit $ac_status); } &&
8819 { ac_try='test -s conftest$ac_exeext'
8820 { (eval echo "$as_me:8820: \"$ac_try\"") >&5
8823 echo "$as_me:8823: \$? = $ac_status" >&5
8824 (exit $ac_status); }; }; then
8825 echo "$as_me:8825: result: yes" >&5
8826 echo "${ECHO_T}yes" >&6
8827 eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
8830 echo "$as_me: failed program was:" >&5
8831 cat conftest.$ac_ext >&5
8832 echo "$as_me:8832: result: no" >&5
8833 echo "${ECHO_T}no" >&6
8834 LIBS="$cf_save_LIBS"
8836 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8840 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8844 eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
8846 if test $cf_found_library = no ; then
8847 { { echo "$as_me:8847: error: Cannot link $cf_nculib_root library" >&5
8848 echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
8849 { (exit 1); exit 1; }; }
8854 if test -n "$cf_ncurses_LIBS" ; then
8855 echo "$as_me:8855: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
8856 echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
8857 cf_ncurses_SAVE="$LIBS"
8858 for p in $cf_ncurses_LIBS ; do
8859 q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
8860 if test "$q" != "$LIBS" ; then
8864 cat >conftest.$ac_ext <<_ACEOF
8865 #line 8865 "configure"
8866 #include "confdefs.h"
8867 #include <${cf_cv_ncurses_header:-curses.h}>
8871 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
8876 rm -f conftest.$ac_objext conftest$ac_exeext
8877 if { (eval echo "$as_me:8877: \"$ac_link\"") >&5
8878 (eval $ac_link) 2>&5
8880 echo "$as_me:8880: \$? = $ac_status" >&5
8881 (exit $ac_status); } &&
8882 { ac_try='test -s conftest$ac_exeext'
8883 { (eval echo "$as_me:8883: \"$ac_try\"") >&5
8886 echo "$as_me:8886: \$? = $ac_status" >&5
8887 (exit $ac_status); }; }; then
8888 echo "$as_me:8888: result: yes" >&5
8889 echo "${ECHO_T}yes" >&6
8891 echo "$as_me: failed program was:" >&5
8892 cat conftest.$ac_ext >&5
8893 echo "$as_me:8893: result: no" >&5
8894 echo "${ECHO_T}no" >&6
8895 LIBS="$cf_ncurses_SAVE"
8897 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8900 cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
8902 cat >>confdefs.h <<EOF
8903 #define $cf_nculib_ROOT 1
8913 if test "$NCURSES_CONFIG_PKG" != none ; then
8914 cf_version=`$PKG_CONFIG --modversion $NCURSES_CONFIG_PKG 2>/dev/null`
8916 NCURSES_MAJOR=`echo "$cf_version" | sed -e 's/\..*//'`
8917 NCURSES_MINOR=`echo "$cf_version" | sed -e 's/^[0-9][0-9]*\.//' -e 's/\..*//'`
8918 NCURSES_PATCH=`echo "$cf_version" | sed -e 's/^[0-9][0-9]*\.[0-9][0-9]*\.//'`
8920 cf_cv_abi_version=`$PKG_CONFIG --variable=abi_version $NCURSES_CONFIG_PKG 2>/dev/null`
8921 if test -z "$cf_cv_abi_version"
8923 cf_cv_abi_version=`$PKG_CONFIG --variable=major_version $NCURSES_CONFIG_PKG 2>/dev/null`
8926 elif test "$NCURSES_CONFIG" != none ; then
8928 cf_version=`$NCURSES_CONFIG --version 2>/dev/null`
8930 NCURSES_MAJOR=`echo "$cf_version" | sed -e 's/\..*//'`
8931 NCURSES_MINOR=`echo "$cf_version" | sed -e 's/^[0-9][0-9]*\.//' -e 's/\..*//'`
8932 NCURSES_PATCH=`echo "$cf_version" | sed -e 's/^[0-9][0-9]*\.[0-9][0-9]*\.//'`
8934 # ABI version is not available from headers
8935 cf_cv_abi_version=`$NCURSES_CONFIG --abi-version 2>/dev/null`
8939 for cf_name in MAJOR MINOR PATCH
8941 cat >conftest.$ac_ext <<CF_EOF
8942 #include <${cf_cv_ncurses_header:-curses.h}>
8943 AUTOCONF_$cf_name NCURSES_VERSION_$cf_name
8945 cf_try="$ac_cpp conftest.$ac_ext 2>&5 | fgrep AUTOCONF_$cf_name >conftest.out"
8946 { (eval echo "$as_me:8946: \"$cf_try\"") >&5
8949 echo "$as_me:8949: \$? = $ac_status" >&5
8950 (exit $ac_status); }
8951 if test -f conftest.out ; then
8952 cf_result=`cat conftest.out | sed -e "s/^.*AUTOCONF_$cf_name[ ][ ]*//"`
8953 eval NCURSES_$cf_name=\"$cf_result\"
8954 # cat conftest.$ac_ext
8959 cf_cv_abi_version=${NCURSES_MAJOR}
8963 cf_cv_rel_version=${NCURSES_MAJOR}.${NCURSES_MINOR}
8965 cf_cv_timestamp=`date`
8967 echo "$as_me:8967: result: Configuring NCURSES $cf_cv_rel_version ABI $cf_cv_abi_version ($cf_cv_timestamp)" >&5
8968 echo "${ECHO_T}Configuring NCURSES $cf_cv_rel_version ABI $cf_cv_abi_version ($cf_cv_timestamp)" >&6
8970 echo "$as_me:8970: checking if you want to have a library-prefix" >&5
8971 echo $ECHO_N "checking if you want to have a library-prefix... $ECHO_C" >&6
8973 # Check whether --with-lib-prefix or --without-lib-prefix was given.
8974 if test "${with_lib_prefix+set}" = set; then
8975 withval="$with_lib_prefix"
8976 with_lib_prefix=$withval
8978 with_lib_prefix=auto
8980 echo "$as_me:8980: result: $with_lib_prefix" >&5
8981 echo "${ECHO_T}$with_lib_prefix" >&6
8983 if test $with_lib_prefix = auto
8986 case $cf_cv_system_name in
8988 if test "$DFT_LWR_MODEL" = libtool; then
8994 (*) LIB_PREFIX='lib'
8997 cf_prefix=$LIB_PREFIX
8999 elif test $with_lib_prefix = no
9003 LIB_PREFIX=$with_lib_prefix
9008 ###############################################################################
9010 if test X"$CC_G_OPT" = X"" ; then
9012 test -n "$GCC" && test "${ac_cv_prog_cc_g}" != yes && CC_G_OPT=''
9015 echo "$as_me:9015: checking for default loader flags" >&5
9016 echo $ECHO_N "checking for default loader flags... $ECHO_C" >&6
9017 case $DFT_LWR_MODEL in
9018 (normal) LD_MODEL='' ;;
9019 (debug) LD_MODEL=$CC_G_OPT ;;
9020 (profile) LD_MODEL='-pg';;
9021 (shared) LD_MODEL='' ;;
9023 echo "$as_me:9023: result: $LD_MODEL" >&5
9024 echo "${ECHO_T}$LD_MODEL" >&6
9027 echo "$as_me:9027: checking for an rpath option" >&5
9028 echo $ECHO_N "checking for an rpath option... $ECHO_C" >&6
9029 case $cf_cv_system_name in
9031 if test "$GCC" = yes; then
9032 LD_RPATH_OPT="-Wl,-rpath,"
9034 LD_RPATH_OPT="-rpath "
9037 (linux*|gnu*|k*bsd*-gnu|freebsd*)
9038 LD_RPATH_OPT="-Wl,-rpath,"
9040 (openbsd[2-9].*|mirbsd*)
9041 LD_RPATH_OPT="-Wl,-rpath,"
9044 LD_RPATH_OPT="-rpath "
9047 LD_RPATH_OPT="-Wl,-rpath,"
9050 LD_RPATH_OPT="-rpath "
9058 echo "$as_me:9058: result: $LD_RPATH_OPT" >&5
9059 echo "${ECHO_T}$LD_RPATH_OPT" >&6
9061 case "x$LD_RPATH_OPT" in
9063 echo "$as_me:9063: checking if we need a space after rpath option" >&5
9064 echo $ECHO_N "checking if we need a space after rpath option... $ECHO_C" >&6
9065 cf_save_LIBS="$LIBS"
9067 cf_add_libs="${LD_RPATH_OPT}$libdir"
9068 # Filter out duplicates - this happens with badly-designed ".pc" files...
9069 for cf_add_1lib in $LIBS
9071 for cf_add_2lib in $cf_add_libs
9073 if test "x$cf_add_1lib" = "x$cf_add_2lib"
9079 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
9083 cat >conftest.$ac_ext <<_ACEOF
9084 #line 9084 "configure"
9085 #include "confdefs.h"
9095 rm -f conftest.$ac_objext conftest$ac_exeext
9096 if { (eval echo "$as_me:9096: \"$ac_link\"") >&5
9097 (eval $ac_link) 2>&5
9099 echo "$as_me:9099: \$? = $ac_status" >&5
9100 (exit $ac_status); } &&
9101 { ac_try='test -s conftest$ac_exeext'
9102 { (eval echo "$as_me:9102: \"$ac_try\"") >&5
9105 echo "$as_me:9105: \$? = $ac_status" >&5
9106 (exit $ac_status); }; }; then
9109 echo "$as_me: failed program was:" >&5
9110 cat conftest.$ac_ext >&5
9113 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9114 LIBS="$cf_save_LIBS"
9115 echo "$as_me:9115: result: $cf_rpath_space" >&5
9116 echo "${ECHO_T}$cf_rpath_space" >&6
9117 test "$cf_rpath_space" = yes && LD_RPATH_OPT="$LD_RPATH_OPT "
9125 INSTALL_LIB="-m 644"
9126 : ${rel_builddir:=.}
9132 cf_cv_do_symlinks=no
9134 test "$cf_cv_enable_rpath" = yes && cf_ld_rpath_opt="$LD_RPATH_OPT"
9136 echo "$as_me:9136: checking if release/abi version should be used for shared libs" >&5
9137 echo $ECHO_N "checking if release/abi version should be used for shared libs... $ECHO_C" >&6
9139 # Check whether --with-shlib-version or --without-shlib-version was given.
9140 if test "${with_shlib_version+set}" = set; then
9141 withval="$with_shlib_version"
9142 test -z "$withval" && withval=auto
9145 cf_cv_shlib_version=auto
9148 cf_cv_shlib_version=$withval
9151 echo "$as_me:9151: result: $withval" >&5
9152 echo "${ECHO_T}$withval" >&6
9153 { { echo "$as_me:9153: error: option value must be one of: rel, abi, or auto" >&5
9154 echo "$as_me: error: option value must be one of: rel, abi, or auto" >&2;}
9155 { (exit 1); exit 1; }; }
9160 cf_cv_shlib_version=auto
9162 echo "$as_me:9162: result: $cf_cv_shlib_version" >&5
9163 echo "${ECHO_T}$cf_cv_shlib_version" >&6
9168 # Some less-capable ports of gcc support only -fpic
9172 if test "$GCC" = yes
9176 case $cf_cv_system_name in
9177 (*linux*) # e.g., PGI compiler
9183 if test "$cf_try_fPIC" = yes
9185 echo "$as_me:9185: checking which $CC option to use" >&5
9186 echo $ECHO_N "checking which $CC option to use... $ECHO_C" >&6
9187 cf_save_CFLAGS="$CFLAGS"
9188 for CC_SHARED_OPTS in -fPIC -fpic ''
9190 CFLAGS="$cf_save_CFLAGS $CC_SHARED_OPTS"
9191 cat >conftest.$ac_ext <<_ACEOF
9192 #line 9192 "configure"
9193 #include "confdefs.h"
9203 rm -f conftest.$ac_objext
9204 if { (eval echo "$as_me:9204: \"$ac_compile\"") >&5
9205 (eval $ac_compile) 2>&5
9207 echo "$as_me:9207: \$? = $ac_status" >&5
9208 (exit $ac_status); } &&
9209 { ac_try='test -s conftest.$ac_objext'
9210 { (eval echo "$as_me:9210: \"$ac_try\"") >&5
9213 echo "$as_me:9213: \$? = $ac_status" >&5
9214 (exit $ac_status); }; }; then
9217 echo "$as_me: failed program was:" >&5
9218 cat conftest.$ac_ext >&5
9220 rm -f conftest.$ac_objext conftest.$ac_ext
9222 echo "$as_me:9222: result: $CC_SHARED_OPTS" >&5
9223 echo "${ECHO_T}$CC_SHARED_OPTS" >&6
9224 CFLAGS="$cf_save_CFLAGS"
9227 cf_cv_shlib_version_infix=no
9229 case $cf_cv_system_name in
9230 (aix4.3-9*|aix[5-7]*)
9231 if test "$GCC" = yes; then
9232 CC_SHARED_OPTS='-Wl,-brtl'
9233 MK_SHARED_LIB='${CC} -shared -Wl,-brtl -Wl,-blibpath:${RPATH_LIST}:/usr/lib -o $@'
9235 CC_SHARED_OPTS='-brtl'
9236 # as well as '-qpic=large -G' or perhaps "-bM:SRE -bnoentry -bexpall"
9237 MK_SHARED_LIB='${CC} -G -Wl,-brtl -Wl,-blibpath:${RPATH_LIST}:/usr/lib -o $@'
9241 MK_SHARED_LIB='${CC} ${CFLAGS} -o $@ -Xlinker -soname=`basename $@` -nostart -e 0'
9245 MK_SHARED_LIB=$SHELL' '$rel_builddir'/mk_shared_lib.sh $@ ${CC} ${CFLAGS}'
9246 RM_SHARED_OPTS="$RM_SHARED_OPTS $rel_builddir/mk_shared_lib.sh *.dll.a"
9247 cf_cv_shlib_version=cygdll
9248 cf_cv_shlib_version_infix=cygdll
9251 cat >mk_shared_lib.sh <<-CF_EOF
9254 IMPORT_LIB=\`echo "\$1" | sed -e 's/cyg/lib/' -e 's/[0-9]*\.dll$/.dll.a/'\`
9257 Linking shared library
9258 ** SHARED_LIB \$SHARED_LIB
9259 ** IMPORT_LIB \$IMPORT_LIB
9261 exec \$* -shared -Wl,--out-implib=\${IMPORT_LIB} -Wl,--export-all-symbols -o \${SHARED_LIB}
9263 chmod +x mk_shared_lib.sh
9267 MK_SHARED_LIB=$SHELL' '$rel_builddir'/mk_shared_lib.sh $@ ${CC} ${CFLAGS}'
9268 RM_SHARED_OPTS="$RM_SHARED_OPTS $rel_builddir/mk_shared_lib.sh *.dll.a"
9269 cf_cv_shlib_version=msysdll
9270 cf_cv_shlib_version_infix=msysdll
9273 cat >mk_shared_lib.sh <<-CF_EOF
9276 IMPORT_LIB=\`echo "\$1" | sed -e 's/msys-/lib/' -e 's/[0-9]*\.dll$/.dll.a/'\`
9279 Linking shared library
9280 ** SHARED_LIB \$SHARED_LIB
9281 ** IMPORT_LIB \$IMPORT_LIB
9283 exec \$* -shared -Wl,--out-implib=\${IMPORT_LIB} -Wl,--export-all-symbols -o \${SHARED_LIB}
9285 chmod +x mk_shared_lib.sh
9288 cf_try_cflags="no-cpp-precomp"
9289 CC_SHARED_OPTS="-dynamic"
9290 MK_SHARED_LIB='${CC} ${CFLAGS} -dynamiclib -install_name ${libdir}/`basename $@` -compatibility_version ${ABI_VERSION} -current_version ${ABI_VERSION} -o $@'
9291 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=abi
9292 cf_cv_shlib_version_infix=yes
9293 echo "$as_me:9293: checking if ld -search_paths_first works" >&5
9294 echo $ECHO_N "checking if ld -search_paths_first works... $ECHO_C" >&6
9295 if test "${cf_cv_ldflags_search_paths_first+set}" = set; then
9296 echo $ECHO_N "(cached) $ECHO_C" >&6
9299 cf_save_LDFLAGS=$LDFLAGS
9300 LDFLAGS="$LDFLAGS -Wl,-search_paths_first"
9301 cat >conftest.$ac_ext <<_ACEOF
9302 #line 9302 "configure"
9303 #include "confdefs.h"
9313 rm -f conftest.$ac_objext conftest$ac_exeext
9314 if { (eval echo "$as_me:9314: \"$ac_link\"") >&5
9315 (eval $ac_link) 2>&5
9317 echo "$as_me:9317: \$? = $ac_status" >&5
9318 (exit $ac_status); } &&
9319 { ac_try='test -s conftest$ac_exeext'
9320 { (eval echo "$as_me:9320: \"$ac_try\"") >&5
9323 echo "$as_me:9323: \$? = $ac_status" >&5
9324 (exit $ac_status); }; }; then
9325 cf_cv_ldflags_search_paths_first=yes
9327 echo "$as_me: failed program was:" >&5
9328 cat conftest.$ac_ext >&5
9329 cf_cv_ldflags_search_paths_first=no
9331 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9332 LDFLAGS=$cf_save_LDFLAGS
9334 echo "$as_me:9334: result: $cf_cv_ldflags_search_paths_first" >&5
9335 echo "${ECHO_T}$cf_cv_ldflags_search_paths_first" >&6
9336 if test $cf_cv_ldflags_search_paths_first = yes; then
9337 LDFLAGS="$LDFLAGS -Wl,-search_paths_first"
9341 # HP-UX 8.07 ld lacks "+b" option used for libdir search-list
9342 if test "$GCC" != yes; then
9345 MK_SHARED_LIB='${LD} -b -o $@'
9346 INSTALL_LIB="-m 555"
9349 # (tested with gcc 2.7.2 -- I don't have c89)
9350 if test "$GCC" = yes; then
9351 LD_SHARED_OPTS='-Xlinker +b -Xlinker ${libdir}'
9354 LD_SHARED_OPTS='-Wl,+b,${libdir}'
9356 MK_SHARED_LIB='${LD} +b ${libdir} -b -o $@'
9357 # HP-UX shared libraries must be executable, and should be
9358 # readonly to exploit a quirk in the memory manager.
9359 INSTALL_LIB="-m 555"
9362 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9363 if test "$cf_cv_shlib_version" = rel; then
9364 cf_shared_soname='`basename .${REL_VERSION}`.${ABI_VERSION}'
9366 cf_shared_soname='`basename `'
9369 MK_SHARED_LIB='${CC} -shared -Wl,-rpath,${RPATH_LIST} -Wl,-h,'$cf_shared_soname' -o '
9372 if test "$cf_cv_enable_rpath" = yes ; then
9373 EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${RPATH_LIST} $EXTRA_LDFLAGS"
9375 # tested with IRIX 5.2 and 'cc'.
9376 if test "$GCC" != yes; then
9377 CC_SHARED_OPTS='-KPIC'
9378 MK_SHARED_LIB='${CC} -shared -rdata_shared -soname `basename $@` -o $@'
9380 MK_SHARED_LIB='${CC} -shared -Wl,-soname,`basename $@` -o $@'
9382 cf_cv_rm_so_locs=yes
9384 (linux*|gnu*|k*bsd*-gnu)
9385 if test "$DFT_LWR_MODEL" = "shared" ; then
9386 LOCAL_LDFLAGS="${LD_RPATH_OPT}\$(LOCAL_LIBDIR)"
9387 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
9389 if test "$cf_cv_enable_rpath" = yes ; then
9390 EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${RPATH_LIST} $EXTRA_LDFLAGS"
9393 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9394 if test "$cf_cv_shlib_version" = rel; then
9395 cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
9397 cf_cv_shared_soname='`basename $@`'
9400 MK_SHARED_LIB='${CC} ${CFLAGS} -shared -Wl,-soname,'$cf_cv_shared_soname',-stats,-lc -o $@'
9403 cf_cv_shlib_version=mingw
9404 cf_cv_shlib_version_infix=mingw
9407 if test "$DFT_LWR_MODEL" = "shared" ; then
9408 LOCAL_LDFLAGS="-Wl,--enable-auto-import"
9409 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
9410 EXTRA_LDFLAGS="-Wl,--enable-auto-import $EXTRA_LDFLAGS"
9413 MK_SHARED_LIB=$SHELL' '$rel_builddir'/mk_shared_lib.sh $@ ${CC} ${CFLAGS}'
9414 RM_SHARED_OPTS="$RM_SHARED_OPTS $rel_builddir/mk_shared_lib.sh *.dll.a"
9415 cat >mk_shared_lib.sh <<-CF_EOF
9418 IMPORT_LIB=\`echo "\$1" | sed -e 's/[0-9]*\.dll$/.dll.a/'\`
9421 Linking shared library
9422 ** SHARED_LIB \$SHARED_LIB
9423 ** IMPORT_LIB \$IMPORT_LIB
9425 exec \$* -shared -Wl,--enable-auto-import,--out-implib=\${IMPORT_LIB} -Wl,--export-all-symbols -o \${SHARED_LIB}
9427 chmod +x mk_shared_lib.sh
9429 (openbsd[2-9].*|mirbsd*)
9430 if test "$DFT_LWR_MODEL" = "shared" ; then
9431 LOCAL_LDFLAGS="${LD_RPATH_OPT}\$(LOCAL_LIBDIR)"
9432 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
9434 if test "$cf_cv_enable_rpath" = yes ; then
9435 EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${RPATH_LIST} $EXTRA_LDFLAGS"
9437 CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC"
9439 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9440 if test "$cf_cv_shlib_version" = rel; then
9441 cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
9443 cf_cv_shared_soname='`basename $@`'
9446 MK_SHARED_LIB='${CC} ${CFLAGS} -shared -Wl,-Bshareable,-soname,'$cf_cv_shared_soname',-stats,-lc -o $@'
9448 (nto-qnx*|openbsd*|freebsd[12].*)
9449 CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC"
9450 MK_SHARED_LIB='${LD} -Bshareable -o $@'
9451 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9453 (dragonfly*|freebsd*)
9454 CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC"
9455 if test "$DFT_LWR_MODEL" = "shared" && test "$cf_cv_enable_rpath" = yes ; then
9456 LOCAL_LDFLAGS="${cf_ld_rpath_opt}\$(LOCAL_LIBDIR)"
9457 LOCAL_LDFLAGS2="${cf_ld_rpath_opt}\${RPATH_LIST} $LOCAL_LDFLAGS"
9458 EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${RPATH_LIST} $EXTRA_LDFLAGS"
9461 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9462 if test "$cf_cv_shlib_version" = rel; then
9463 cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
9465 cf_cv_shared_soname='`basename $@`'
9468 MK_SHARED_LIB='${CC} ${CFLAGS} -shared -Wl,-soname,'$cf_cv_shared_soname',-stats,-lc -o $@'
9471 CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC"
9472 if test "$DFT_LWR_MODEL" = "shared" && test "$cf_cv_enable_rpath" = yes ; then
9473 LOCAL_LDFLAGS="${cf_ld_rpath_opt}\$(LOCAL_LIBDIR)"
9474 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
9475 EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${RPATH_LIST} $EXTRA_LDFLAGS"
9476 if test "$cf_cv_shlib_version" = auto; then
9477 if test -f /usr/libexec/ld.elf_so; then
9478 cf_cv_shlib_version=abi
9480 cf_cv_shlib_version=rel
9484 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9485 if test "$cf_cv_shlib_version" = rel; then
9486 cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
9488 cf_cv_shared_soname='`basename $@`'
9491 MK_SHARED_LIB='${CC} ${CFLAGS} -shared -Wl,-soname,'$cf_cv_shared_soname' -o $@'
9493 MK_SHARED_LIB='${CC} -Wl,-shared -Wl,-Bshareable -o $@'
9497 # tested with OSF/1 V3.2 and 'cc'
9498 # tested with OSF/1 V3.2 and gcc 2.6.3 (but the c++ demo didn't
9499 # link with shared libs).
9500 MK_SHARED_LIB='${LD} -set_version ${REL_VERSION}:${ABI_VERSION} -expect_unresolved "*" -shared -soname `basename $@`'
9503 MK_SHARED_LIB="${MK_SHARED_LIB} -msym"
9506 MK_SHARED_LIB="${MK_SHARED_LIB}"' -o $@'
9507 if test "$DFT_LWR_MODEL" = "shared" ; then
9508 LOCAL_LDFLAGS="${LD_RPATH_OPT}\$(LOCAL_LIBDIR)"
9509 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
9511 cf_cv_rm_so_locs=yes
9513 (sco3.2v5*) # also uw2* and UW7: hops 13-Apr-98
9514 # tested with osr5.0.5
9515 if test "$GCC" != yes; then
9516 CC_SHARED_OPTS='-belf -KPIC'
9518 MK_SHARED_LIB='${LD} -dy -G -h `basename $@ .${REL_VERSION}`.${ABI_VERSION} -o $@'
9519 if test "$cf_cv_enable_rpath" = yes ; then
9520 # only way is to set LD_RUN_PATH but no switch for it
9523 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9524 LINK_PROGS='LD_RUN_PATH=${libdir}'
9525 LINK_TESTS='Pwd=`pwd`;LD_RUN_PATH=`dirname $${Pwd}`/lib'
9528 # tested with SunOS 4.1.1 and gcc 2.7.0
9529 if test "$GCC" != yes; then
9530 CC_SHARED_OPTS='-KPIC'
9532 MK_SHARED_LIB='${LD} -assert pure-text -o $@'
9533 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9536 # tested with SunOS 5.5.1 (solaris 2.5.1) and gcc 2.7.2
9537 # tested with SunOS 5.10 (solaris 10) and gcc 3.4.3
9538 if test "$DFT_LWR_MODEL" = "shared" ; then
9539 LOCAL_LDFLAGS="-R \$(LOCAL_LIBDIR):\${libdir}"
9540 LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
9542 if test "$cf_cv_enable_rpath" = yes ; then
9543 EXTRA_LDFLAGS="-R \${libdir} $EXTRA_LDFLAGS"
9546 test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel
9547 if test "$cf_cv_shlib_version" = rel; then
9548 cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}'
9550 cf_cv_shared_soname='`basename $@`'
9553 if test "$GCC" != yes; then
9554 cf_save_CFLAGS="$CFLAGS"
9555 for cf_shared_opts in -xcode=pic32 -xcode=pic13 -KPIC -Kpic -O
9557 CFLAGS="$cf_shared_opts $cf_save_CFLAGS"
9558 cat >conftest.$ac_ext <<_ACEOF
9559 #line 9559 "configure"
9560 #include "confdefs.h"
9570 rm -f conftest.$ac_objext
9571 if { (eval echo "$as_me:9571: \"$ac_compile\"") >&5
9572 (eval $ac_compile) 2>&5
9574 echo "$as_me:9574: \$? = $ac_status" >&5
9575 (exit $ac_status); } &&
9576 { ac_try='test -s conftest.$ac_objext'
9577 { (eval echo "$as_me:9577: \"$ac_try\"") >&5
9580 echo "$as_me:9580: \$? = $ac_status" >&5
9581 (exit $ac_status); }; }; then
9584 echo "$as_me: failed program was:" >&5
9585 cat conftest.$ac_ext >&5
9587 rm -f conftest.$ac_objext conftest.$ac_ext
9589 CFLAGS="$cf_save_CFLAGS"
9590 CC_SHARED_OPTS=$cf_shared_opts
9591 MK_SHARED_LIB='${CC} -dy -G -h '$cf_cv_shared_soname' -o $@'
9593 MK_SHARED_LIB='${CC} -shared -dy -G -h '$cf_cv_shared_soname' -o $@'
9596 (sysv5uw7*|unix_sv*)
9597 # tested with UnixWare 7.1.0 (gcc 2.95.2 and cc)
9598 if test "$GCC" != yes; then
9599 CC_SHARED_OPTS='-KPIC'
9601 MK_SHARED_LIB='${LD} -d y -G -o $@'
9604 CC_SHARED_OPTS='unknown'
9605 MK_SHARED_LIB='echo unknown'
9609 # This works if the last tokens in $MK_SHARED_LIB are the -o target.
9610 case "$cf_cv_shlib_version" in
9612 case "$MK_SHARED_LIB" in
9614 test "$cf_cv_do_symlinks" = no && cf_cv_do_symlinks=yes
9617 { echo "$as_me:9617: WARNING: ignored --with-shlib-version" >&5
9618 echo "$as_me: WARNING: ignored --with-shlib-version" >&2;}
9624 if test -n "$cf_try_cflags"
9626 cat > conftest.$ac_ext <<EOF
9627 #line 9627 "${as_me:-configure}"
9629 int main(int argc, char *argv[])
9632 return (argv[argc-1] == 0) ;
9635 cf_save_CFLAGS="$CFLAGS"
9636 for cf_opt in $cf_try_cflags
9638 CFLAGS="$cf_save_CFLAGS -$cf_opt"
9639 echo "$as_me:9639: checking if CFLAGS option -$cf_opt works" >&5
9640 echo $ECHO_N "checking if CFLAGS option -$cf_opt works... $ECHO_C" >&6
9641 if { (eval echo "$as_me:9641: \"$ac_compile\"") >&5
9642 (eval $ac_compile) 2>&5
9644 echo "$as_me:9644: \$? = $ac_status" >&5
9645 (exit $ac_status); }; then
9646 echo "$as_me:9646: result: yes" >&5
9647 echo "${ECHO_T}yes" >&6
9648 cf_save_CFLAGS="$CFLAGS"
9650 echo "$as_me:9650: result: no" >&5
9651 echo "${ECHO_T}no" >&6
9654 CFLAGS="$cf_save_CFLAGS"
9657 # RPATH_LIST is a colon-separated list of directories
9658 test -n "$cf_ld_rpath_opt" && MK_SHARED_LIB="$MK_SHARED_LIB $cf_ld_rpath_opt\${RPATH_LIST}"
9659 test -z "$RPATH_LIST" && RPATH_LIST="\${libdir}"
9661 test $cf_cv_rm_so_locs = yes && RM_SHARED_OPTS="$RM_SHARED_OPTS so_locations"
9663 test -n "$verbose" && echo " CC_SHARED_OPTS: $CC_SHARED_OPTS" 1>&6
9665 echo "${as_me:-configure}:9665: testing CC_SHARED_OPTS: $CC_SHARED_OPTS ..." 1>&5
9667 test -n "$verbose" && echo " MK_SHARED_LIB: $MK_SHARED_LIB" 1>&6
9669 echo "${as_me:-configure}:9669: testing MK_SHARED_LIB: $MK_SHARED_LIB ..." 1>&5
9671 # The test/sample programs in the original tree link using rpath option.
9672 # Make it optional for packagers.
9673 if test -n "$LOCAL_LDFLAGS"
9675 echo "$as_me:9675: checking if you want to link sample programs with rpath option" >&5
9676 echo $ECHO_N "checking if you want to link sample programs with rpath option... $ECHO_C" >&6
9678 # Check whether --enable-rpath-link or --disable-rpath-link was given.
9679 if test "${enable_rpath_link+set}" = set; then
9680 enableval="$enable_rpath_link"
9681 with_rpath_link=$enableval
9685 echo "$as_me:9685: result: $with_rpath_link" >&5
9686 echo "${ECHO_T}$with_rpath_link" >&6
9687 if test "$with_rpath_link" = no
9694 ###############################################################################
9696 ### use option --enable-broken-linker to force on use of broken-linker support
9697 echo "$as_me:9697: checking if you want broken-linker support code" >&5
9698 echo $ECHO_N "checking if you want broken-linker support code... $ECHO_C" >&6
9700 # Check whether --enable-broken_linker or --disable-broken_linker was given.
9701 if test "${enable_broken_linker+set}" = set; then
9702 enableval="$enable_broken_linker"
9703 with_broken_linker=$enableval
9705 with_broken_linker=${BROKEN_LINKER:-no}
9707 echo "$as_me:9707: result: $with_broken_linker" >&5
9708 echo "${ECHO_T}$with_broken_linker" >&6
9711 if test "$with_broken_linker" = yes ; then
9712 cat >>confdefs.h <<\EOF
9713 #define BROKEN_LINKER 1
9717 elif test "$DFT_LWR_MODEL" = shared ; then
9718 case $cf_cv_system_name in
9720 cat >>confdefs.h <<\EOF
9721 #define BROKEN_LINKER 1
9725 test -n "$verbose" && echo " cygwin linker is broken anyway" 1>&6
9727 echo "${as_me:-configure}:9727: testing cygwin linker is broken anyway ..." 1>&5
9733 # Check to define _XOPEN_SOURCE "automatically"
9736 cf_POSIX_C_SOURCE=199506L
9741 cf_xopen_source="-D_ALL_SOURCE"
9747 cf_xopen_source="-D_APPLE_C_SOURCE"
9750 cf_xopen_source="-D_DARWIN_C_SOURCE"
9753 (freebsd*|dragonfly*)
9754 # 5.x headers associate
9755 # _XOPEN_SOURCE=600 with _POSIX_C_SOURCE=200112L
9756 # _XOPEN_SOURCE=500 with _POSIX_C_SOURCE=199506L
9757 cf_POSIX_C_SOURCE=200112L
9759 cf_xopen_source="-D_BSD_TYPES -D__BSD_VISIBLE -D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
9762 cf_xopen_source="-D_HPUX_SOURCE -D_XOPEN_SOURCE=500"
9765 cf_xopen_source="-D_HPUX_SOURCE"
9768 cf_xopen_source="-D_SGI_SOURCE"
9771 (linux*|uclinux*|gnu*|mint*|k*bsd*-gnu|cygwin)
9773 echo "$as_me:9773: checking if we must define _GNU_SOURCE" >&5
9774 echo $ECHO_N "checking if we must define _GNU_SOURCE... $ECHO_C" >&6
9775 if test "${cf_cv_gnu_source+set}" = set; then
9776 echo $ECHO_N "(cached) $ECHO_C" >&6
9779 cat >conftest.$ac_ext <<_ACEOF
9780 #line 9780 "configure"
9781 #include "confdefs.h"
9782 #include <sys/types.h>
9787 #ifndef _XOPEN_SOURCE
9794 rm -f conftest.$ac_objext
9795 if { (eval echo "$as_me:9795: \"$ac_compile\"") >&5
9796 (eval $ac_compile) 2>&5
9798 echo "$as_me:9798: \$? = $ac_status" >&5
9799 (exit $ac_status); } &&
9800 { ac_try='test -s conftest.$ac_objext'
9801 { (eval echo "$as_me:9801: \"$ac_try\"") >&5
9804 echo "$as_me:9804: \$? = $ac_status" >&5
9805 (exit $ac_status); }; }; then
9808 echo "$as_me: failed program was:" >&5
9809 cat conftest.$ac_ext >&5
9811 CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE"
9812 cat >conftest.$ac_ext <<_ACEOF
9813 #line 9813 "configure"
9814 #include "confdefs.h"
9815 #include <sys/types.h>
9820 #ifdef _XOPEN_SOURCE
9827 rm -f conftest.$ac_objext
9828 if { (eval echo "$as_me:9828: \"$ac_compile\"") >&5
9829 (eval $ac_compile) 2>&5
9831 echo "$as_me:9831: \$? = $ac_status" >&5
9832 (exit $ac_status); } &&
9833 { ac_try='test -s conftest.$ac_objext'
9834 { (eval echo "$as_me:9834: \"$ac_try\"") >&5
9837 echo "$as_me:9837: \$? = $ac_status" >&5
9838 (exit $ac_status); }; }; then
9841 echo "$as_me: failed program was:" >&5
9842 cat conftest.$ac_ext >&5
9843 cf_cv_gnu_source=yes
9845 rm -f conftest.$ac_objext conftest.$ac_ext
9849 rm -f conftest.$ac_objext conftest.$ac_ext
9852 echo "$as_me:9852: result: $cf_cv_gnu_source" >&5
9853 echo "${ECHO_T}$cf_cv_gnu_source" >&6
9855 if test "$cf_cv_gnu_source" = yes
9857 echo "$as_me:9857: checking if we should also define _DEFAULT_SOURCE" >&5
9858 echo $ECHO_N "checking if we should also define _DEFAULT_SOURCE... $ECHO_C" >&6
9859 if test "${cf_cv_default_source+set}" = set; then
9860 echo $ECHO_N "(cached) $ECHO_C" >&6
9863 CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE"
9864 cat >conftest.$ac_ext <<_ACEOF
9865 #line 9865 "configure"
9866 #include "confdefs.h"
9867 #include <sys/types.h>
9872 #ifdef _DEFAULT_SOURCE
9879 rm -f conftest.$ac_objext
9880 if { (eval echo "$as_me:9880: \"$ac_compile\"") >&5
9881 (eval $ac_compile) 2>&5
9883 echo "$as_me:9883: \$? = $ac_status" >&5
9884 (exit $ac_status); } &&
9885 { ac_try='test -s conftest.$ac_objext'
9886 { (eval echo "$as_me:9886: \"$ac_try\"") >&5
9889 echo "$as_me:9889: \$? = $ac_status" >&5
9890 (exit $ac_status); }; }; then
9891 cf_cv_default_source=no
9893 echo "$as_me: failed program was:" >&5
9894 cat conftest.$ac_ext >&5
9895 cf_cv_default_source=yes
9897 rm -f conftest.$ac_objext conftest.$ac_ext
9900 echo "$as_me:9900: result: $cf_cv_default_source" >&5
9901 echo "${ECHO_T}$cf_cv_default_source" >&6
9902 test "$cf_cv_default_source" = yes && CPPFLAGS="$CPPFLAGS -D_DEFAULT_SOURCE"
9907 cf_xopen_source="-D_NETBSD_SOURCE" # POSIX.1-2001 features are ifdef'd with this...
9910 # setting _XOPEN_SOURCE or _POSIX_SOURCE breaks <sys/select.h> and other headers which use u_int / u_short types
9913 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
9915 cf_save_CFLAGS="$CFLAGS"
9916 cf_save_CPPFLAGS="$CPPFLAGS"
9918 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
9919 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
9920 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
9922 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
9923 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
9924 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
9926 echo "$as_me:9926: checking if we should define _POSIX_C_SOURCE" >&5
9927 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
9928 if test "${cf_cv_posix_c_source+set}" = set; then
9929 echo $ECHO_N "(cached) $ECHO_C" >&6
9932 echo "${as_me:-configure}:9932: testing if the symbol is already defined go no further ..." 1>&5
9934 cat >conftest.$ac_ext <<_ACEOF
9935 #line 9935 "configure"
9936 #include "confdefs.h"
9937 #include <sys/types.h>
9942 #ifndef _POSIX_C_SOURCE
9949 rm -f conftest.$ac_objext
9950 if { (eval echo "$as_me:9950: \"$ac_compile\"") >&5
9951 (eval $ac_compile) 2>&5
9953 echo "$as_me:9953: \$? = $ac_status" >&5
9954 (exit $ac_status); } &&
9955 { ac_try='test -s conftest.$ac_objext'
9956 { (eval echo "$as_me:9956: \"$ac_try\"") >&5
9959 echo "$as_me:9959: \$? = $ac_status" >&5
9960 (exit $ac_status); }; }; then
9961 cf_cv_posix_c_source=no
9963 echo "$as_me: failed program was:" >&5
9964 cat conftest.$ac_ext >&5
9965 cf_want_posix_source=no
9966 case .$cf_POSIX_C_SOURCE in
9968 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
9971 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
9972 cf_want_posix_source=yes
9975 cf_want_posix_source=yes
9978 if test "$cf_want_posix_source" = yes ; then
9979 cat >conftest.$ac_ext <<_ACEOF
9980 #line 9980 "configure"
9981 #include "confdefs.h"
9982 #include <sys/types.h>
9987 #ifdef _POSIX_SOURCE
9994 rm -f conftest.$ac_objext
9995 if { (eval echo "$as_me:9995: \"$ac_compile\"") >&5
9996 (eval $ac_compile) 2>&5
9998 echo "$as_me:9998: \$? = $ac_status" >&5
9999 (exit $ac_status); } &&
10000 { ac_try='test -s conftest.$ac_objext'
10001 { (eval echo "$as_me:10001: \"$ac_try\"") >&5
10002 (eval $ac_try) 2>&5
10004 echo "$as_me:10004: \$? = $ac_status" >&5
10005 (exit $ac_status); }; }; then
10008 echo "$as_me: failed program was:" >&5
10009 cat conftest.$ac_ext >&5
10010 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
10012 rm -f conftest.$ac_objext conftest.$ac_ext
10015 echo "${as_me:-configure}:10015: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
10017 CFLAGS="$cf_trim_CFLAGS"
10018 CPPFLAGS="$cf_trim_CPPFLAGS $cf_cv_posix_c_source"
10020 echo "${as_me:-configure}:10020: testing if the second compile does not leave our definition intact error ..." 1>&5
10022 cat >conftest.$ac_ext <<_ACEOF
10023 #line 10023 "configure"
10024 #include "confdefs.h"
10025 #include <sys/types.h>
10030 #ifndef _POSIX_C_SOURCE
10037 rm -f conftest.$ac_objext
10038 if { (eval echo "$as_me:10038: \"$ac_compile\"") >&5
10039 (eval $ac_compile) 2>&5
10041 echo "$as_me:10041: \$? = $ac_status" >&5
10042 (exit $ac_status); } &&
10043 { ac_try='test -s conftest.$ac_objext'
10044 { (eval echo "$as_me:10044: \"$ac_try\"") >&5
10045 (eval $ac_try) 2>&5
10047 echo "$as_me:10047: \$? = $ac_status" >&5
10048 (exit $ac_status); }; }; then
10051 echo "$as_me: failed program was:" >&5
10052 cat conftest.$ac_ext >&5
10053 cf_cv_posix_c_source=no
10055 rm -f conftest.$ac_objext conftest.$ac_ext
10056 CFLAGS="$cf_save_CFLAGS"
10057 CPPFLAGS="$cf_save_CPPFLAGS"
10060 rm -f conftest.$ac_objext conftest.$ac_ext
10063 echo "$as_me:10063: result: $cf_cv_posix_c_source" >&5
10064 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
10066 if test "$cf_cv_posix_c_source" != no ; then
10067 CFLAGS="$cf_trim_CFLAGS"
10068 CPPFLAGS="$cf_trim_CPPFLAGS"
10073 cf_new_extra_cppflags=
10075 for cf_add_cflags in $cf_cv_posix_c_source
10077 case $cf_fix_cppflags in
10079 case $cf_add_cflags in
10080 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
10081 case $cf_add_cflags in
10083 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10085 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10086 && test -z "${cf_tst_cflags}" \
10087 && cf_fix_cppflags=yes
10089 if test $cf_fix_cppflags = yes ; then
10091 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10092 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10095 elif test "${cf_tst_cflags}" = "\"'" ; then
10097 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10098 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10104 case "$CPPFLAGS" in
10108 case $cf_add_cflags in
10110 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10112 CPPFLAGS=`echo "$CPPFLAGS" | \
10113 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10114 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10119 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
10120 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
10127 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
10128 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
10135 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10136 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10138 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10140 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10141 && test -z "${cf_tst_cflags}" \
10142 && cf_fix_cppflags=no
10147 if test -n "$cf_new_cflags" ; then
10149 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
10150 CFLAGS="${CFLAGS}$cf_new_cflags"
10154 if test -n "$cf_new_cppflags" ; then
10156 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
10157 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
10161 if test -n "$cf_new_extra_cppflags" ; then
10163 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
10164 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
10172 cf_xopen_source="-D_NETBSD_SOURCE" # setting _XOPEN_SOURCE breaks IPv6 for lynx on NetBSD 1.6, breaks xterm, is not needed for ncursesw
10175 # setting _XOPEN_SOURCE lower than 500 breaks g++ compile with wchar.h, needed for ncursesw
10176 cf_xopen_source="-D_BSD_SOURCE"
10177 cf_XOPEN_SOURCE=600
10180 # setting _XOPEN_SOURCE breaks xterm on OpenBSD 2.8, is not needed for ncursesw
10183 cf_xopen_source="-D_OSF_SOURCE"
10186 cf_xopen_source="-D_QNX_SOURCE"
10189 # setting _XOPEN_SOURCE breaks Lynx on SCO Unix / OpenServer
10192 cf_xopen_source="-D__EXTENSIONS__"
10193 cf_cv_xopen_source=broken
10195 (sysv4.2uw2.*) # Novell/SCO UnixWare 2.x (tested on 2.1.2)
10201 echo "$as_me:10201: checking if we should define _XOPEN_SOURCE" >&5
10202 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
10203 if test "${cf_cv_xopen_source+set}" = set; then
10204 echo $ECHO_N "(cached) $ECHO_C" >&6
10207 cat >conftest.$ac_ext <<_ACEOF
10208 #line 10208 "configure"
10209 #include "confdefs.h"
10211 #include <stdlib.h>
10212 #include <string.h>
10213 #include <sys/types.h>
10219 #ifndef _XOPEN_SOURCE
10226 rm -f conftest.$ac_objext
10227 if { (eval echo "$as_me:10227: \"$ac_compile\"") >&5
10228 (eval $ac_compile) 2>&5
10230 echo "$as_me:10230: \$? = $ac_status" >&5
10231 (exit $ac_status); } &&
10232 { ac_try='test -s conftest.$ac_objext'
10233 { (eval echo "$as_me:10233: \"$ac_try\"") >&5
10234 (eval $ac_try) 2>&5
10236 echo "$as_me:10236: \$? = $ac_status" >&5
10237 (exit $ac_status); }; }; then
10238 cf_cv_xopen_source=no
10240 echo "$as_me: failed program was:" >&5
10241 cat conftest.$ac_ext >&5
10242 cf_save="$CPPFLAGS"
10243 CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
10244 cat >conftest.$ac_ext <<_ACEOF
10245 #line 10245 "configure"
10246 #include "confdefs.h"
10248 #include <stdlib.h>
10249 #include <string.h>
10250 #include <sys/types.h>
10256 #ifdef _XOPEN_SOURCE
10263 rm -f conftest.$ac_objext
10264 if { (eval echo "$as_me:10264: \"$ac_compile\"") >&5
10265 (eval $ac_compile) 2>&5
10267 echo "$as_me:10267: \$? = $ac_status" >&5
10268 (exit $ac_status); } &&
10269 { ac_try='test -s conftest.$ac_objext'
10270 { (eval echo "$as_me:10270: \"$ac_try\"") >&5
10271 (eval $ac_try) 2>&5
10273 echo "$as_me:10273: \$? = $ac_status" >&5
10274 (exit $ac_status); }; }; then
10275 cf_cv_xopen_source=no
10277 echo "$as_me: failed program was:" >&5
10278 cat conftest.$ac_ext >&5
10279 cf_cv_xopen_source=$cf_XOPEN_SOURCE
10281 rm -f conftest.$ac_objext conftest.$ac_ext
10282 CPPFLAGS="$cf_save"
10285 rm -f conftest.$ac_objext conftest.$ac_ext
10288 echo "$as_me:10288: result: $cf_cv_xopen_source" >&5
10289 echo "${ECHO_T}$cf_cv_xopen_source" >&6
10291 if test "$cf_cv_xopen_source" != no ; then
10293 CFLAGS=`echo "$CFLAGS" | \
10294 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
10295 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
10297 CPPFLAGS=`echo "$CPPFLAGS" | \
10298 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
10299 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
10301 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
10306 cf_new_extra_cppflags=
10308 for cf_add_cflags in $cf_temp_xopen_source
10310 case $cf_fix_cppflags in
10312 case $cf_add_cflags in
10313 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
10314 case $cf_add_cflags in
10316 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10318 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10319 && test -z "${cf_tst_cflags}" \
10320 && cf_fix_cppflags=yes
10322 if test $cf_fix_cppflags = yes ; then
10324 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10325 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10328 elif test "${cf_tst_cflags}" = "\"'" ; then
10330 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10331 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10337 case "$CPPFLAGS" in
10341 case $cf_add_cflags in
10343 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10345 CPPFLAGS=`echo "$CPPFLAGS" | \
10346 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10347 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10352 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
10353 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
10360 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
10361 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
10368 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10369 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10371 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10373 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10374 && test -z "${cf_tst_cflags}" \
10375 && cf_fix_cppflags=no
10380 if test -n "$cf_new_cflags" ; then
10382 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
10383 CFLAGS="${CFLAGS}$cf_new_cflags"
10387 if test -n "$cf_new_cppflags" ; then
10389 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
10390 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
10394 if test -n "$cf_new_extra_cppflags" ; then
10396 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
10397 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
10403 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
10405 cf_save_CFLAGS="$CFLAGS"
10406 cf_save_CPPFLAGS="$CPPFLAGS"
10408 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
10409 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
10410 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
10412 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
10413 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
10414 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
10416 echo "$as_me:10416: checking if we should define _POSIX_C_SOURCE" >&5
10417 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
10418 if test "${cf_cv_posix_c_source+set}" = set; then
10419 echo $ECHO_N "(cached) $ECHO_C" >&6
10422 echo "${as_me:-configure}:10422: testing if the symbol is already defined go no further ..." 1>&5
10424 cat >conftest.$ac_ext <<_ACEOF
10425 #line 10425 "configure"
10426 #include "confdefs.h"
10427 #include <sys/types.h>
10432 #ifndef _POSIX_C_SOURCE
10439 rm -f conftest.$ac_objext
10440 if { (eval echo "$as_me:10440: \"$ac_compile\"") >&5
10441 (eval $ac_compile) 2>&5
10443 echo "$as_me:10443: \$? = $ac_status" >&5
10444 (exit $ac_status); } &&
10445 { ac_try='test -s conftest.$ac_objext'
10446 { (eval echo "$as_me:10446: \"$ac_try\"") >&5
10447 (eval $ac_try) 2>&5
10449 echo "$as_me:10449: \$? = $ac_status" >&5
10450 (exit $ac_status); }; }; then
10451 cf_cv_posix_c_source=no
10453 echo "$as_me: failed program was:" >&5
10454 cat conftest.$ac_ext >&5
10455 cf_want_posix_source=no
10456 case .$cf_POSIX_C_SOURCE in
10458 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
10461 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
10462 cf_want_posix_source=yes
10465 cf_want_posix_source=yes
10468 if test "$cf_want_posix_source" = yes ; then
10469 cat >conftest.$ac_ext <<_ACEOF
10470 #line 10470 "configure"
10471 #include "confdefs.h"
10472 #include <sys/types.h>
10477 #ifdef _POSIX_SOURCE
10484 rm -f conftest.$ac_objext
10485 if { (eval echo "$as_me:10485: \"$ac_compile\"") >&5
10486 (eval $ac_compile) 2>&5
10488 echo "$as_me:10488: \$? = $ac_status" >&5
10489 (exit $ac_status); } &&
10490 { ac_try='test -s conftest.$ac_objext'
10491 { (eval echo "$as_me:10491: \"$ac_try\"") >&5
10492 (eval $ac_try) 2>&5
10494 echo "$as_me:10494: \$? = $ac_status" >&5
10495 (exit $ac_status); }; }; then
10498 echo "$as_me: failed program was:" >&5
10499 cat conftest.$ac_ext >&5
10500 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
10502 rm -f conftest.$ac_objext conftest.$ac_ext
10505 echo "${as_me:-configure}:10505: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
10507 CFLAGS="$cf_trim_CFLAGS"
10508 CPPFLAGS="$cf_trim_CPPFLAGS $cf_cv_posix_c_source"
10510 echo "${as_me:-configure}:10510: testing if the second compile does not leave our definition intact error ..." 1>&5
10512 cat >conftest.$ac_ext <<_ACEOF
10513 #line 10513 "configure"
10514 #include "confdefs.h"
10515 #include <sys/types.h>
10520 #ifndef _POSIX_C_SOURCE
10527 rm -f conftest.$ac_objext
10528 if { (eval echo "$as_me:10528: \"$ac_compile\"") >&5
10529 (eval $ac_compile) 2>&5
10531 echo "$as_me:10531: \$? = $ac_status" >&5
10532 (exit $ac_status); } &&
10533 { ac_try='test -s conftest.$ac_objext'
10534 { (eval echo "$as_me:10534: \"$ac_try\"") >&5
10535 (eval $ac_try) 2>&5
10537 echo "$as_me:10537: \$? = $ac_status" >&5
10538 (exit $ac_status); }; }; then
10541 echo "$as_me: failed program was:" >&5
10542 cat conftest.$ac_ext >&5
10543 cf_cv_posix_c_source=no
10545 rm -f conftest.$ac_objext conftest.$ac_ext
10546 CFLAGS="$cf_save_CFLAGS"
10547 CPPFLAGS="$cf_save_CPPFLAGS"
10550 rm -f conftest.$ac_objext conftest.$ac_ext
10553 echo "$as_me:10553: result: $cf_cv_posix_c_source" >&5
10554 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
10556 if test "$cf_cv_posix_c_source" != no ; then
10557 CFLAGS="$cf_trim_CFLAGS"
10558 CPPFLAGS="$cf_trim_CPPFLAGS"
10563 cf_new_extra_cppflags=
10565 for cf_add_cflags in $cf_cv_posix_c_source
10567 case $cf_fix_cppflags in
10569 case $cf_add_cflags in
10570 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
10571 case $cf_add_cflags in
10573 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10575 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10576 && test -z "${cf_tst_cflags}" \
10577 && cf_fix_cppflags=yes
10579 if test $cf_fix_cppflags = yes ; then
10581 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10582 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10585 elif test "${cf_tst_cflags}" = "\"'" ; then
10587 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10588 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10594 case "$CPPFLAGS" in
10598 case $cf_add_cflags in
10600 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10602 CPPFLAGS=`echo "$CPPFLAGS" | \
10603 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10604 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10609 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
10610 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
10617 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
10618 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
10625 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10626 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10628 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10630 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10631 && test -z "${cf_tst_cflags}" \
10632 && cf_fix_cppflags=no
10637 if test -n "$cf_new_cflags" ; then
10639 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
10640 CFLAGS="${CFLAGS}$cf_new_cflags"
10644 if test -n "$cf_new_cppflags" ; then
10646 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
10647 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
10651 if test -n "$cf_new_extra_cppflags" ; then
10653 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
10654 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
10663 if test -n "$cf_xopen_source" ; then
10668 cf_new_extra_cppflags=
10670 for cf_add_cflags in $cf_xopen_source
10672 case $cf_fix_cppflags in
10674 case $cf_add_cflags in
10675 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
10676 case $cf_add_cflags in
10678 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10680 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10681 && test -z "${cf_tst_cflags}" \
10682 && cf_fix_cppflags=yes
10684 if test $cf_fix_cppflags = yes ; then
10686 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10687 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10690 elif test "${cf_tst_cflags}" = "\"'" ; then
10692 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10693 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10699 case "$CPPFLAGS" in
10703 case $cf_add_cflags in
10705 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
10707 CPPFLAGS=`echo "$CPPFLAGS" | \
10708 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
10709 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
10714 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
10715 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
10722 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
10723 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
10730 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10731 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10733 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
10735 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10736 && test -z "${cf_tst_cflags}" \
10737 && cf_fix_cppflags=no
10742 if test -n "$cf_new_cflags" ; then
10743 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
10745 echo "${as_me:-configure}:10745: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
10747 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
10748 CFLAGS="${CFLAGS}$cf_new_cflags"
10752 if test -n "$cf_new_cppflags" ; then
10753 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
10755 echo "${as_me:-configure}:10755: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
10757 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
10758 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
10762 if test -n "$cf_new_extra_cppflags" ; then
10763 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
10765 echo "${as_me:-configure}:10765: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
10767 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
10768 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
10774 if test -n "$cf_XOPEN_SOURCE" && test -z "$cf_cv_xopen_source" ; then
10775 echo "$as_me:10775: checking if _XOPEN_SOURCE really is set" >&5
10776 echo $ECHO_N "checking if _XOPEN_SOURCE really is set... $ECHO_C" >&6
10777 cat >conftest.$ac_ext <<_ACEOF
10778 #line 10778 "configure"
10779 #include "confdefs.h"
10780 #include <stdlib.h>
10785 #ifndef _XOPEN_SOURCE
10792 rm -f conftest.$ac_objext
10793 if { (eval echo "$as_me:10793: \"$ac_compile\"") >&5
10794 (eval $ac_compile) 2>&5
10796 echo "$as_me:10796: \$? = $ac_status" >&5
10797 (exit $ac_status); } &&
10798 { ac_try='test -s conftest.$ac_objext'
10799 { (eval echo "$as_me:10799: \"$ac_try\"") >&5
10800 (eval $ac_try) 2>&5
10802 echo "$as_me:10802: \$? = $ac_status" >&5
10803 (exit $ac_status); }; }; then
10804 cf_XOPEN_SOURCE_set=yes
10806 echo "$as_me: failed program was:" >&5
10807 cat conftest.$ac_ext >&5
10808 cf_XOPEN_SOURCE_set=no
10810 rm -f conftest.$ac_objext conftest.$ac_ext
10811 echo "$as_me:10811: result: $cf_XOPEN_SOURCE_set" >&5
10812 echo "${ECHO_T}$cf_XOPEN_SOURCE_set" >&6
10813 if test $cf_XOPEN_SOURCE_set = yes
10815 cat >conftest.$ac_ext <<_ACEOF
10816 #line 10816 "configure"
10817 #include "confdefs.h"
10818 #include <stdlib.h>
10823 #if (_XOPEN_SOURCE - 0) < $cf_XOPEN_SOURCE
10830 rm -f conftest.$ac_objext
10831 if { (eval echo "$as_me:10831: \"$ac_compile\"") >&5
10832 (eval $ac_compile) 2>&5
10834 echo "$as_me:10834: \$? = $ac_status" >&5
10835 (exit $ac_status); } &&
10836 { ac_try='test -s conftest.$ac_objext'
10837 { (eval echo "$as_me:10837: \"$ac_try\"") >&5
10838 (eval $ac_try) 2>&5
10840 echo "$as_me:10840: \$? = $ac_status" >&5
10841 (exit $ac_status); }; }; then
10842 cf_XOPEN_SOURCE_set_ok=yes
10844 echo "$as_me: failed program was:" >&5
10845 cat conftest.$ac_ext >&5
10846 cf_XOPEN_SOURCE_set_ok=no
10848 rm -f conftest.$ac_objext conftest.$ac_ext
10849 if test $cf_XOPEN_SOURCE_set_ok = no
10851 { echo "$as_me:10851: WARNING: _XOPEN_SOURCE is lower than requested" >&5
10852 echo "$as_me: WARNING: _XOPEN_SOURCE is lower than requested" >&2;}
10856 echo "$as_me:10856: checking if we should define _XOPEN_SOURCE" >&5
10857 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
10858 if test "${cf_cv_xopen_source+set}" = set; then
10859 echo $ECHO_N "(cached) $ECHO_C" >&6
10862 cat >conftest.$ac_ext <<_ACEOF
10863 #line 10863 "configure"
10864 #include "confdefs.h"
10866 #include <stdlib.h>
10867 #include <string.h>
10868 #include <sys/types.h>
10874 #ifndef _XOPEN_SOURCE
10881 rm -f conftest.$ac_objext
10882 if { (eval echo "$as_me:10882: \"$ac_compile\"") >&5
10883 (eval $ac_compile) 2>&5
10885 echo "$as_me:10885: \$? = $ac_status" >&5
10886 (exit $ac_status); } &&
10887 { ac_try='test -s conftest.$ac_objext'
10888 { (eval echo "$as_me:10888: \"$ac_try\"") >&5
10889 (eval $ac_try) 2>&5
10891 echo "$as_me:10891: \$? = $ac_status" >&5
10892 (exit $ac_status); }; }; then
10893 cf_cv_xopen_source=no
10895 echo "$as_me: failed program was:" >&5
10896 cat conftest.$ac_ext >&5
10897 cf_save="$CPPFLAGS"
10898 CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
10899 cat >conftest.$ac_ext <<_ACEOF
10900 #line 10900 "configure"
10901 #include "confdefs.h"
10903 #include <stdlib.h>
10904 #include <string.h>
10905 #include <sys/types.h>
10911 #ifdef _XOPEN_SOURCE
10918 rm -f conftest.$ac_objext
10919 if { (eval echo "$as_me:10919: \"$ac_compile\"") >&5
10920 (eval $ac_compile) 2>&5
10922 echo "$as_me:10922: \$? = $ac_status" >&5
10923 (exit $ac_status); } &&
10924 { ac_try='test -s conftest.$ac_objext'
10925 { (eval echo "$as_me:10925: \"$ac_try\"") >&5
10926 (eval $ac_try) 2>&5
10928 echo "$as_me:10928: \$? = $ac_status" >&5
10929 (exit $ac_status); }; }; then
10930 cf_cv_xopen_source=no
10932 echo "$as_me: failed program was:" >&5
10933 cat conftest.$ac_ext >&5
10934 cf_cv_xopen_source=$cf_XOPEN_SOURCE
10936 rm -f conftest.$ac_objext conftest.$ac_ext
10937 CPPFLAGS="$cf_save"
10940 rm -f conftest.$ac_objext conftest.$ac_ext
10943 echo "$as_me:10943: result: $cf_cv_xopen_source" >&5
10944 echo "${ECHO_T}$cf_cv_xopen_source" >&6
10946 if test "$cf_cv_xopen_source" != no ; then
10948 CFLAGS=`echo "$CFLAGS" | \
10949 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
10950 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
10952 CPPFLAGS=`echo "$CPPFLAGS" | \
10953 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
10954 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
10956 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
10961 cf_new_extra_cppflags=
10963 for cf_add_cflags in $cf_temp_xopen_source
10965 case $cf_fix_cppflags in
10967 case $cf_add_cflags in
10968 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
10969 case $cf_add_cflags in
10971 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
10973 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
10974 && test -z "${cf_tst_cflags}" \
10975 && cf_fix_cppflags=yes
10977 if test $cf_fix_cppflags = yes ; then
10979 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10980 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10983 elif test "${cf_tst_cflags}" = "\"'" ; then
10985 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
10986 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
10992 case "$CPPFLAGS" in
10996 case $cf_add_cflags in
10998 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11000 CPPFLAGS=`echo "$CPPFLAGS" | \
11001 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11002 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11007 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
11008 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
11015 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
11016 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
11023 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11024 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11026 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
11028 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
11029 && test -z "${cf_tst_cflags}" \
11030 && cf_fix_cppflags=no
11035 if test -n "$cf_new_cflags" ; then
11037 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
11038 CFLAGS="${CFLAGS}$cf_new_cflags"
11042 if test -n "$cf_new_cppflags" ; then
11044 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
11045 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
11049 if test -n "$cf_new_extra_cppflags" ; then
11051 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
11052 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
11061 # Check whether --enable-largefile or --disable-largefile was given.
11062 if test "${enable_largefile+set}" = set; then
11063 enableval="$enable_largefile"
11066 if test "$enable_largefile" != no; then
11068 echo "$as_me:11068: checking for special C compiler options needed for large files" >&5
11069 echo $ECHO_N "checking for special C compiler options needed for large files... $ECHO_C" >&6
11070 if test "${ac_cv_sys_largefile_CC+set}" = set; then
11071 echo $ECHO_N "(cached) $ECHO_C" >&6
11073 ac_cv_sys_largefile_CC=no
11074 if test "$GCC" != yes; then
11077 # IRIX 6.2 and later do not support large files by default,
11078 # so use the C compiler's -n32 option if that helps.
11079 cat >conftest.$ac_ext <<_ACEOF
11080 #line 11080 "configure"
11081 #include "confdefs.h"
11082 #include <sys/types.h>
11083 /* Check that off_t can represent 2**63 - 1 correctly.
11084 We can't simply define LARGE_OFF_T to be 9223372036854775807,
11085 since some C++ compilers masquerading as C compilers
11086 incorrectly reject 9223372036854775807. */
11087 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
11088 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
11089 && LARGE_OFF_T % 2147483647 == 1)
11099 rm -f conftest.$ac_objext
11100 if { (eval echo "$as_me:11100: \"$ac_compile\"") >&5
11101 (eval $ac_compile) 2>&5
11103 echo "$as_me:11103: \$? = $ac_status" >&5
11104 (exit $ac_status); } &&
11105 { ac_try='test -s conftest.$ac_objext'
11106 { (eval echo "$as_me:11106: \"$ac_try\"") >&5
11107 (eval $ac_try) 2>&5
11109 echo "$as_me:11109: \$? = $ac_status" >&5
11110 (exit $ac_status); }; }; then
11113 echo "$as_me: failed program was:" >&5
11114 cat conftest.$ac_ext >&5
11116 rm -f conftest.$ac_objext
11118 rm -f conftest.$ac_objext
11119 if { (eval echo "$as_me:11119: \"$ac_compile\"") >&5
11120 (eval $ac_compile) 2>&5
11122 echo "$as_me:11122: \$? = $ac_status" >&5
11123 (exit $ac_status); } &&
11124 { ac_try='test -s conftest.$ac_objext'
11125 { (eval echo "$as_me:11125: \"$ac_try\"") >&5
11126 (eval $ac_try) 2>&5
11128 echo "$as_me:11128: \$? = $ac_status" >&5
11129 (exit $ac_status); }; }; then
11130 ac_cv_sys_largefile_CC=' -n32'; break
11132 echo "$as_me: failed program was:" >&5
11133 cat conftest.$ac_ext >&5
11135 rm -f conftest.$ac_objext
11139 rm -f conftest.$ac_ext
11142 echo "$as_me:11142: result: $ac_cv_sys_largefile_CC" >&5
11143 echo "${ECHO_T}$ac_cv_sys_largefile_CC" >&6
11144 if test "$ac_cv_sys_largefile_CC" != no; then
11145 CC=$CC$ac_cv_sys_largefile_CC
11148 echo "$as_me:11148: checking for _FILE_OFFSET_BITS value needed for large files" >&5
11149 echo $ECHO_N "checking for _FILE_OFFSET_BITS value needed for large files... $ECHO_C" >&6
11150 if test "${ac_cv_sys_file_offset_bits+set}" = set; then
11151 echo $ECHO_N "(cached) $ECHO_C" >&6
11154 ac_cv_sys_file_offset_bits=no
11155 cat >conftest.$ac_ext <<_ACEOF
11156 #line 11156 "configure"
11157 #include "confdefs.h"
11158 #include <sys/types.h>
11159 /* Check that off_t can represent 2**63 - 1 correctly.
11160 We can't simply define LARGE_OFF_T to be 9223372036854775807,
11161 since some C++ compilers masquerading as C compilers
11162 incorrectly reject 9223372036854775807. */
11163 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
11164 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
11165 && LARGE_OFF_T % 2147483647 == 1)
11175 rm -f conftest.$ac_objext
11176 if { (eval echo "$as_me:11176: \"$ac_compile\"") >&5
11177 (eval $ac_compile) 2>&5
11179 echo "$as_me:11179: \$? = $ac_status" >&5
11180 (exit $ac_status); } &&
11181 { ac_try='test -s conftest.$ac_objext'
11182 { (eval echo "$as_me:11182: \"$ac_try\"") >&5
11183 (eval $ac_try) 2>&5
11185 echo "$as_me:11185: \$? = $ac_status" >&5
11186 (exit $ac_status); }; }; then
11189 echo "$as_me: failed program was:" >&5
11190 cat conftest.$ac_ext >&5
11192 rm -f conftest.$ac_objext conftest.$ac_ext
11193 cat >conftest.$ac_ext <<_ACEOF
11194 #line 11194 "configure"
11195 #include "confdefs.h"
11196 #define _FILE_OFFSET_BITS 64
11197 #include <sys/types.h>
11198 /* Check that off_t can represent 2**63 - 1 correctly.
11199 We can't simply define LARGE_OFF_T to be 9223372036854775807,
11200 since some C++ compilers masquerading as C compilers
11201 incorrectly reject 9223372036854775807. */
11202 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
11203 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
11204 && LARGE_OFF_T % 2147483647 == 1)
11214 rm -f conftest.$ac_objext
11215 if { (eval echo "$as_me:11215: \"$ac_compile\"") >&5
11216 (eval $ac_compile) 2>&5
11218 echo "$as_me:11218: \$? = $ac_status" >&5
11219 (exit $ac_status); } &&
11220 { ac_try='test -s conftest.$ac_objext'
11221 { (eval echo "$as_me:11221: \"$ac_try\"") >&5
11222 (eval $ac_try) 2>&5
11224 echo "$as_me:11224: \$? = $ac_status" >&5
11225 (exit $ac_status); }; }; then
11226 ac_cv_sys_file_offset_bits=64; break
11228 echo "$as_me: failed program was:" >&5
11229 cat conftest.$ac_ext >&5
11231 rm -f conftest.$ac_objext conftest.$ac_ext
11235 echo "$as_me:11235: result: $ac_cv_sys_file_offset_bits" >&5
11236 echo "${ECHO_T}$ac_cv_sys_file_offset_bits" >&6
11237 if test "$ac_cv_sys_file_offset_bits" != no; then
11239 cat >>confdefs.h <<EOF
11240 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
11245 echo "$as_me:11245: checking for _LARGE_FILES value needed for large files" >&5
11246 echo $ECHO_N "checking for _LARGE_FILES value needed for large files... $ECHO_C" >&6
11247 if test "${ac_cv_sys_large_files+set}" = set; then
11248 echo $ECHO_N "(cached) $ECHO_C" >&6
11251 ac_cv_sys_large_files=no
11252 cat >conftest.$ac_ext <<_ACEOF
11253 #line 11253 "configure"
11254 #include "confdefs.h"
11255 #include <sys/types.h>
11256 /* Check that off_t can represent 2**63 - 1 correctly.
11257 We can't simply define LARGE_OFF_T to be 9223372036854775807,
11258 since some C++ compilers masquerading as C compilers
11259 incorrectly reject 9223372036854775807. */
11260 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
11261 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
11262 && LARGE_OFF_T % 2147483647 == 1)
11272 rm -f conftest.$ac_objext
11273 if { (eval echo "$as_me:11273: \"$ac_compile\"") >&5
11274 (eval $ac_compile) 2>&5
11276 echo "$as_me:11276: \$? = $ac_status" >&5
11277 (exit $ac_status); } &&
11278 { ac_try='test -s conftest.$ac_objext'
11279 { (eval echo "$as_me:11279: \"$ac_try\"") >&5
11280 (eval $ac_try) 2>&5
11282 echo "$as_me:11282: \$? = $ac_status" >&5
11283 (exit $ac_status); }; }; then
11286 echo "$as_me: failed program was:" >&5
11287 cat conftest.$ac_ext >&5
11289 rm -f conftest.$ac_objext conftest.$ac_ext
11290 cat >conftest.$ac_ext <<_ACEOF
11291 #line 11291 "configure"
11292 #include "confdefs.h"
11293 #define _LARGE_FILES 1
11294 #include <sys/types.h>
11295 /* Check that off_t can represent 2**63 - 1 correctly.
11296 We can't simply define LARGE_OFF_T to be 9223372036854775807,
11297 since some C++ compilers masquerading as C compilers
11298 incorrectly reject 9223372036854775807. */
11299 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
11300 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
11301 && LARGE_OFF_T % 2147483647 == 1)
11311 rm -f conftest.$ac_objext
11312 if { (eval echo "$as_me:11312: \"$ac_compile\"") >&5
11313 (eval $ac_compile) 2>&5
11315 echo "$as_me:11315: \$? = $ac_status" >&5
11316 (exit $ac_status); } &&
11317 { ac_try='test -s conftest.$ac_objext'
11318 { (eval echo "$as_me:11318: \"$ac_try\"") >&5
11319 (eval $ac_try) 2>&5
11321 echo "$as_me:11321: \$? = $ac_status" >&5
11322 (exit $ac_status); }; }; then
11323 ac_cv_sys_large_files=1; break
11325 echo "$as_me: failed program was:" >&5
11326 cat conftest.$ac_ext >&5
11328 rm -f conftest.$ac_objext conftest.$ac_ext
11332 echo "$as_me:11332: result: $ac_cv_sys_large_files" >&5
11333 echo "${ECHO_T}$ac_cv_sys_large_files" >&6
11334 if test "$ac_cv_sys_large_files" != no; then
11336 cat >>confdefs.h <<EOF
11337 #define _LARGE_FILES $ac_cv_sys_large_files
11344 if test "$enable_largefile" != no ; then
11345 echo "$as_me:11345: checking for _LARGEFILE_SOURCE value needed for large files" >&5
11346 echo $ECHO_N "checking for _LARGEFILE_SOURCE value needed for large files... $ECHO_C" >&6
11347 if test "${ac_cv_sys_largefile_source+set}" = set; then
11348 echo $ECHO_N "(cached) $ECHO_C" >&6
11351 ac_cv_sys_largefile_source=no
11352 cat >conftest.$ac_ext <<_ACEOF
11353 #line 11353 "configure"
11354 #include "confdefs.h"
11364 rm -f conftest.$ac_objext
11365 if { (eval echo "$as_me:11365: \"$ac_compile\"") >&5
11366 (eval $ac_compile) 2>&5
11368 echo "$as_me:11368: \$? = $ac_status" >&5
11369 (exit $ac_status); } &&
11370 { ac_try='test -s conftest.$ac_objext'
11371 { (eval echo "$as_me:11371: \"$ac_try\"") >&5
11372 (eval $ac_try) 2>&5
11374 echo "$as_me:11374: \$? = $ac_status" >&5
11375 (exit $ac_status); }; }; then
11378 echo "$as_me: failed program was:" >&5
11379 cat conftest.$ac_ext >&5
11381 rm -f conftest.$ac_objext conftest.$ac_ext
11382 cat >conftest.$ac_ext <<_ACEOF
11383 #line 11383 "configure"
11384 #include "confdefs.h"
11385 #define _LARGEFILE_SOURCE 1
11395 rm -f conftest.$ac_objext
11396 if { (eval echo "$as_me:11396: \"$ac_compile\"") >&5
11397 (eval $ac_compile) 2>&5
11399 echo "$as_me:11399: \$? = $ac_status" >&5
11400 (exit $ac_status); } &&
11401 { ac_try='test -s conftest.$ac_objext'
11402 { (eval echo "$as_me:11402: \"$ac_try\"") >&5
11403 (eval $ac_try) 2>&5
11405 echo "$as_me:11405: \$? = $ac_status" >&5
11406 (exit $ac_status); }; }; then
11407 ac_cv_sys_largefile_source=1; break
11409 echo "$as_me: failed program was:" >&5
11410 cat conftest.$ac_ext >&5
11412 rm -f conftest.$ac_objext conftest.$ac_ext
11416 echo "$as_me:11416: result: $ac_cv_sys_largefile_source" >&5
11417 echo "${ECHO_T}$ac_cv_sys_largefile_source" >&6
11418 if test "$ac_cv_sys_largefile_source" != no; then
11420 cat >>confdefs.h <<EOF
11421 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
11427 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
11428 # in glibc 2.1.3, but that breaks too many other things.
11429 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
11430 echo "$as_me:11430: checking for fseeko" >&5
11431 echo $ECHO_N "checking for fseeko... $ECHO_C" >&6
11432 if test "${ac_cv_func_fseeko+set}" = set; then
11433 echo $ECHO_N "(cached) $ECHO_C" >&6
11435 cat >conftest.$ac_ext <<_ACEOF
11436 #line 11436 "configure"
11437 #include "confdefs.h"
11442 return fseeko && fseeko (stdin, 0, 0);
11447 rm -f conftest.$ac_objext conftest$ac_exeext
11448 if { (eval echo "$as_me:11448: \"$ac_link\"") >&5
11449 (eval $ac_link) 2>&5
11451 echo "$as_me:11451: \$? = $ac_status" >&5
11452 (exit $ac_status); } &&
11453 { ac_try='test -s conftest$ac_exeext'
11454 { (eval echo "$as_me:11454: \"$ac_try\"") >&5
11455 (eval $ac_try) 2>&5
11457 echo "$as_me:11457: \$? = $ac_status" >&5
11458 (exit $ac_status); }; }; then
11459 ac_cv_func_fseeko=yes
11461 echo "$as_me: failed program was:" >&5
11462 cat conftest.$ac_ext >&5
11463 ac_cv_func_fseeko=no
11465 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11467 echo "$as_me:11467: result: $ac_cv_func_fseeko" >&5
11468 echo "${ECHO_T}$ac_cv_func_fseeko" >&6
11469 if test $ac_cv_func_fseeko = yes; then
11471 cat >>confdefs.h <<\EOF
11472 #define HAVE_FSEEKO 1
11477 # Normally we would collect these definitions in the config.h,
11478 # but (like _XOPEN_SOURCE), some environments rely on having these
11479 # defined before any of the system headers are included. Another
11480 # case comes up with C++, e.g., on AIX the compiler compiles the
11481 # header files by themselves before looking at the body files it is
11482 # told to compile. For ncurses, those header files do not include
11484 test "$ac_cv_sys_large_files" != no && CPPFLAGS="$CPPFLAGS -D_LARGE_FILES "
11485 test "$ac_cv_sys_largefile_source" != no && CPPFLAGS="$CPPFLAGS -D_LARGEFILE_SOURCE "
11486 test "$ac_cv_sys_file_offset_bits" != no && CPPFLAGS="$CPPFLAGS -D_FILE_OFFSET_BITS=$ac_cv_sys_file_offset_bits "
11488 echo "$as_me:11488: checking whether to use struct dirent64" >&5
11489 echo $ECHO_N "checking whether to use struct dirent64... $ECHO_C" >&6
11490 if test "${cf_cv_struct_dirent64+set}" = set; then
11491 echo $ECHO_N "(cached) $ECHO_C" >&6
11494 cat >conftest.$ac_ext <<_ACEOF
11495 #line 11495 "configure"
11496 #include "confdefs.h"
11498 #pragma GCC diagnostic error "-Wincompatible-pointer-types"
11499 #include <sys/types.h>
11500 #include <dirent.h>
11506 /* if transitional largefile support is setup, this is true */
11507 extern struct dirent64 * readdir(DIR *);
11508 struct dirent64 *x = readdir((DIR *)0);
11509 struct dirent *y = readdir((DIR *)0);
11516 rm -f conftest.$ac_objext
11517 if { (eval echo "$as_me:11517: \"$ac_compile\"") >&5
11518 (eval $ac_compile) 2>&5
11520 echo "$as_me:11520: \$? = $ac_status" >&5
11521 (exit $ac_status); } &&
11522 { ac_try='test -s conftest.$ac_objext'
11523 { (eval echo "$as_me:11523: \"$ac_try\"") >&5
11524 (eval $ac_try) 2>&5
11526 echo "$as_me:11526: \$? = $ac_status" >&5
11527 (exit $ac_status); }; }; then
11528 cf_cv_struct_dirent64=yes
11530 echo "$as_me: failed program was:" >&5
11531 cat conftest.$ac_ext >&5
11532 cf_cv_struct_dirent64=no
11534 rm -f conftest.$ac_objext conftest.$ac_ext
11537 echo "$as_me:11537: result: $cf_cv_struct_dirent64" >&5
11538 echo "${ECHO_T}$cf_cv_struct_dirent64" >&6
11539 test "$cf_cv_struct_dirent64" = yes &&
11540 cat >>confdefs.h <<\EOF
11541 #define HAVE_STRUCT_DIRENT64 1
11546 ### Enable compiling-in rcs id's
11547 echo "$as_me:11547: checking if RCS identifiers should be compiled-in" >&5
11548 echo $ECHO_N "checking if RCS identifiers should be compiled-in... $ECHO_C" >&6
11550 # Check whether --with-rcs-ids or --without-rcs-ids was given.
11551 if test "${with_rcs_ids+set}" = set; then
11552 withval="$with_rcs_ids"
11553 with_rcs_ids=$withval
11557 echo "$as_me:11557: result: $with_rcs_ids" >&5
11558 echo "${ECHO_T}$with_rcs_ids" >&6
11559 test "$with_rcs_ids" = yes &&
11560 cat >>confdefs.h <<\EOF
11561 #define USE_RCS_IDS 1
11564 ###############################################################################
11566 ### Note that some functions (such as const) are normally disabled anyway.
11567 echo "$as_me:11567: checking if you want to build with function extensions" >&5
11568 echo $ECHO_N "checking if you want to build with function extensions... $ECHO_C" >&6
11570 # Check whether --enable-ext-funcs or --disable-ext-funcs was given.
11571 if test "${enable_ext_funcs+set}" = set; then
11572 enableval="$enable_ext_funcs"
11573 with_ext_funcs=$enableval
11577 echo "$as_me:11577: result: $with_ext_funcs" >&5
11578 echo "${ECHO_T}$with_ext_funcs" >&6
11579 if test "$with_ext_funcs" = yes ; then
11580 NCURSES_EXT_FUNCS=1
11582 cat >>confdefs.h <<\EOF
11583 #define HAVE_USE_DEFAULT_COLORS 1
11586 cat >>confdefs.h <<\EOF
11587 #define NCURSES_EXT_FUNCS 1
11591 NCURSES_EXT_FUNCS=0
11594 ### use option --enable-const to turn on use of const beyond that in XSI.
11595 echo "$as_me:11595: checking for extended use of const keyword" >&5
11596 echo $ECHO_N "checking for extended use of const keyword... $ECHO_C" >&6
11598 # Check whether --enable-const or --disable-const was given.
11599 if test "${enable_const+set}" = set; then
11600 enableval="$enable_const"
11601 with_ext_const=$enableval
11605 echo "$as_me:11605: result: $with_ext_const" >&5
11606 echo "${ECHO_T}$with_ext_const" >&6
11607 NCURSES_CONST='/*nothing*/'
11608 if test "$with_ext_const" = yes ; then
11609 NCURSES_CONST=const
11612 ###############################################################################
11613 # These options are relatively safe to experiment with.
11615 echo "$as_me:11615: checking if you want all development code" >&5
11616 echo $ECHO_N "checking if you want all development code... $ECHO_C" >&6
11618 # Check whether --with-develop or --without-develop was given.
11619 if test "${with_develop+set}" = set; then
11620 withval="$with_develop"
11621 with_develop=$withval
11625 echo "$as_me:11625: result: $with_develop" >&5
11626 echo "${ECHO_T}$with_develop" >&6
11628 ###############################################################################
11629 # These are just experimental, probably should not be in a package:
11631 # This is still experimental (20080329), but should ultimately be moved to
11632 # the script-block --with-normal, etc.
11634 echo "$as_me:11634: checking if you want to link with the pthread library" >&5
11635 echo $ECHO_N "checking if you want to link with the pthread library... $ECHO_C" >&6
11637 # Check whether --with-pthread or --without-pthread was given.
11638 if test "${with_pthread+set}" = set; then
11639 withval="$with_pthread"
11640 with_pthread=$withval
11644 echo "$as_me:11644: result: $with_pthread" >&5
11645 echo "${ECHO_T}$with_pthread" >&6
11647 if test "$with_pthread" != no ; then
11648 echo "$as_me:11648: checking for pthread.h" >&5
11649 echo $ECHO_N "checking for pthread.h... $ECHO_C" >&6
11650 if test "${ac_cv_header_pthread_h+set}" = set; then
11651 echo $ECHO_N "(cached) $ECHO_C" >&6
11653 cat >conftest.$ac_ext <<_ACEOF
11654 #line 11654 "configure"
11655 #include "confdefs.h"
11656 #include <pthread.h>
11658 if { (eval echo "$as_me:11658: \"$ac_cpp conftest.$ac_ext\"") >&5
11659 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11661 egrep -v '^ *\+' conftest.er1 >conftest.err
11663 cat conftest.err >&5
11664 echo "$as_me:11664: \$? = $ac_status" >&5
11665 (exit $ac_status); } >/dev/null; then
11666 if test -s conftest.err; then
11667 ac_cpp_err=$ac_c_preproc_warn_flag
11674 if test -z "$ac_cpp_err"; then
11675 ac_cv_header_pthread_h=yes
11677 echo "$as_me: failed program was:" >&5
11678 cat conftest.$ac_ext >&5
11679 ac_cv_header_pthread_h=no
11681 rm -f conftest.err conftest.$ac_ext
11683 echo "$as_me:11683: result: $ac_cv_header_pthread_h" >&5
11684 echo "${ECHO_T}$ac_cv_header_pthread_h" >&6
11685 if test $ac_cv_header_pthread_h = yes; then
11687 cat >>confdefs.h <<\EOF
11688 #define HAVE_PTHREADS_H 1
11691 for cf_lib_pthread in pthread c_r
11693 echo "$as_me:11693: checking if we can link with the $cf_lib_pthread library" >&5
11694 echo $ECHO_N "checking if we can link with the $cf_lib_pthread library... $ECHO_C" >&6
11695 cf_save_LIBS="$LIBS"
11697 cf_add_libs="-l$cf_lib_pthread"
11698 # Filter out duplicates - this happens with badly-designed ".pc" files...
11699 for cf_add_1lib in $LIBS
11701 for cf_add_2lib in $cf_add_libs
11703 if test "x$cf_add_1lib" = "x$cf_add_2lib"
11709 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
11711 LIBS="$cf_add_libs"
11713 cat >conftest.$ac_ext <<_ACEOF
11714 #line 11714 "configure"
11715 #include "confdefs.h"
11717 #include <pthread.h>
11723 int rc = pthread_create(0,0,0,0);
11724 int r2 = pthread_mutexattr_settype(0, 0);
11730 rm -f conftest.$ac_objext conftest$ac_exeext
11731 if { (eval echo "$as_me:11731: \"$ac_link\"") >&5
11732 (eval $ac_link) 2>&5
11734 echo "$as_me:11734: \$? = $ac_status" >&5
11735 (exit $ac_status); } &&
11736 { ac_try='test -s conftest$ac_exeext'
11737 { (eval echo "$as_me:11737: \"$ac_try\"") >&5
11738 (eval $ac_try) 2>&5
11740 echo "$as_me:11740: \$? = $ac_status" >&5
11741 (exit $ac_status); }; }; then
11744 echo "$as_me: failed program was:" >&5
11745 cat conftest.$ac_ext >&5
11748 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11749 LIBS="$cf_save_LIBS"
11750 echo "$as_me:11750: result: $with_pthread" >&5
11751 echo "${ECHO_T}$with_pthread" >&6
11752 test "$with_pthread" = yes && break
11755 if test "$with_pthread" = yes ; then
11757 cf_add_libs="-l$cf_lib_pthread"
11758 # Filter out duplicates - this happens with badly-designed ".pc" files...
11759 for cf_add_1lib in $LIBS
11761 for cf_add_2lib in $cf_add_libs
11763 if test "x$cf_add_1lib" = "x$cf_add_2lib"
11769 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
11771 LIBS="$cf_add_libs"
11773 cat >>confdefs.h <<\EOF
11774 #define HAVE_LIBPTHREADS 1
11778 { { echo "$as_me:11778: error: Cannot link with pthread library" >&5
11779 echo "$as_me: error: Cannot link with pthread library" >&2;}
11780 { (exit 1); exit 1; }; }
11787 echo "$as_me:11787: checking if you want to use weak-symbols for pthreads" >&5
11788 echo $ECHO_N "checking if you want to use weak-symbols for pthreads... $ECHO_C" >&6
11790 # Check whether --enable-weak-symbols or --disable-weak-symbols was given.
11791 if test "${enable_weak_symbols+set}" = set; then
11792 enableval="$enable_weak_symbols"
11793 use_weak_symbols=$withval
11795 use_weak_symbols=no
11797 echo "$as_me:11797: result: $use_weak_symbols" >&5
11798 echo "${ECHO_T}$use_weak_symbols" >&6
11799 if test "$use_weak_symbols" = yes ; then
11801 echo "$as_me:11801: checking if $CC supports weak symbols" >&5
11802 echo $ECHO_N "checking if $CC supports weak symbols... $ECHO_C" >&6
11803 if test "${cf_cv_weak_symbols+set}" = set; then
11804 echo $ECHO_N "(cached) $ECHO_C" >&6
11807 cat >conftest.$ac_ext <<_ACEOF
11808 #line 11808 "configure"
11809 #include "confdefs.h"
11816 #if defined(__GNUC__)
11817 # if defined __USE_ISOC99
11818 # define _cat_pragma(exp) _Pragma(#exp)
11819 # define _weak_pragma(exp) _cat_pragma(weak name)
11821 # define _weak_pragma(exp)
11823 # define _declare(name) __extension__ extern __typeof__(name) name
11824 # define weak_symbol(name) _weak_pragma(name) _declare(name) __attribute__((weak))
11827 weak_symbol(fopen);
11833 rm -f conftest.$ac_objext
11834 if { (eval echo "$as_me:11834: \"$ac_compile\"") >&5
11835 (eval $ac_compile) 2>&5
11837 echo "$as_me:11837: \$? = $ac_status" >&5
11838 (exit $ac_status); } &&
11839 { ac_try='test -s conftest.$ac_objext'
11840 { (eval echo "$as_me:11840: \"$ac_try\"") >&5
11841 (eval $ac_try) 2>&5
11843 echo "$as_me:11843: \$? = $ac_status" >&5
11844 (exit $ac_status); }; }; then
11845 cf_cv_weak_symbols=yes
11847 echo "$as_me: failed program was:" >&5
11848 cat conftest.$ac_ext >&5
11849 cf_cv_weak_symbols=no
11851 rm -f conftest.$ac_objext conftest.$ac_ext
11854 echo "$as_me:11854: result: $cf_cv_weak_symbols" >&5
11855 echo "${ECHO_T}$cf_cv_weak_symbols" >&6
11858 cf_cv_weak_symbols=no
11861 if test $cf_cv_weak_symbols = yes ; then
11863 cat >>confdefs.h <<\EOF
11864 #define USE_WEAK_SYMBOLS 1
11870 if test "$with_pthread" = "yes" ; then
11872 cat >>confdefs.h <<\EOF
11873 #define USE_PTHREADS 1
11876 enable_reentrant=yes
11877 if test $cf_cv_weak_symbols = yes ; then
11882 # OpenSUSE is installing ncurses6, using reentrant option.
11883 echo "$as_me:11883: checking for _nc_TABSIZE" >&5
11884 echo $ECHO_N "checking for _nc_TABSIZE... $ECHO_C" >&6
11885 if test "${ac_cv_func__nc_TABSIZE+set}" = set; then
11886 echo $ECHO_N "(cached) $ECHO_C" >&6
11888 cat >conftest.$ac_ext <<_ACEOF
11889 #line 11889 "configure"
11890 #include "confdefs.h"
11891 /* System header to define __stub macros and hopefully few prototypes,
11892 which can conflict with char _nc_TABSIZE (); below. */
11893 #include <assert.h>
11894 /* Override any gcc2 internal prototype to avoid an error. */
11898 /* We use char because int might match the return type of a gcc2
11899 builtin and then its argument prototype would still apply. */
11900 char _nc_TABSIZE ();
11906 /* The GNU C library defines this for functions which it implements
11907 to always fail with ENOSYS. Some functions are actually named
11908 something starting with __ and the normal name is an alias. */
11909 #if defined (__stub__nc_TABSIZE) || defined (__stub____nc_TABSIZE)
11912 f = _nc_TABSIZE; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
11919 rm -f conftest.$ac_objext conftest$ac_exeext
11920 if { (eval echo "$as_me:11920: \"$ac_link\"") >&5
11921 (eval $ac_link) 2>&5
11923 echo "$as_me:11923: \$? = $ac_status" >&5
11924 (exit $ac_status); } &&
11925 { ac_try='test -s conftest$ac_exeext'
11926 { (eval echo "$as_me:11926: \"$ac_try\"") >&5
11927 (eval $ac_try) 2>&5
11929 echo "$as_me:11929: \$? = $ac_status" >&5
11930 (exit $ac_status); }; }; then
11931 ac_cv_func__nc_TABSIZE=yes
11933 echo "$as_me: failed program was:" >&5
11934 cat conftest.$ac_ext >&5
11935 ac_cv_func__nc_TABSIZE=no
11937 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11939 echo "$as_me:11939: result: $ac_cv_func__nc_TABSIZE" >&5
11940 echo "${ECHO_T}$ac_cv_func__nc_TABSIZE" >&6
11941 if test $ac_cv_func__nc_TABSIZE = yes; then
11942 assume_reentrant=yes
11944 assume_reentrant=no
11947 # Reentrant code has to be opaque; there's little advantage to making ncurses
11948 # opaque outside of that, so there is no --enable-opaque option. We can use
11949 # this option without --with-pthreads, but this will be always set for
11951 echo "$as_me:11951: checking if you want experimental reentrant code" >&5
11952 echo $ECHO_N "checking if you want experimental reentrant code... $ECHO_C" >&6
11954 # Check whether --enable-reentrant or --disable-reentrant was given.
11955 if test "${enable_reentrant+set}" = set; then
11956 enableval="$enable_reentrant"
11957 with_reentrant=$enableval
11959 with_reentrant=$assume_reentrant
11961 echo "$as_me:11961: result: $with_reentrant" >&5
11962 echo "${ECHO_T}$with_reentrant" >&6
11963 if test "$with_reentrant" = yes ; then
11964 cf_cv_enable_reentrant=1
11965 if test $cf_cv_weak_symbols = yes ; then
11967 # remove pthread library from $LIBS
11968 LIBS=`echo "$LIBS" | sed -e 's/-lpthread[ ]//g' -e 's/-lpthread$//'`
11970 elif test "$assume_reentrant" = no ; then
11971 LIB_SUFFIX="t${LIB_SUFFIX}"
11974 cat >>confdefs.h <<\EOF
11975 #define USE_REENTRANT 1
11979 cf_cv_enable_reentrant=0
11982 ### Allow using a different wrap-prefix
11983 if test "$cf_cv_enable_reentrant" != 0 || test "$BROKEN_LINKER" = 1 ; then
11984 echo "$as_me:11984: checking for prefix used to wrap public variables" >&5
11985 echo $ECHO_N "checking for prefix used to wrap public variables... $ECHO_C" >&6
11987 # Check whether --with-wrap-prefix or --without-wrap-prefix was given.
11988 if test "${with_wrap_prefix+set}" = set; then
11989 withval="$with_wrap_prefix"
11990 NCURSES_WRAP_PREFIX=$withval
11992 NCURSES_WRAP_PREFIX=_nc_
11994 echo "$as_me:11994: result: $NCURSES_WRAP_PREFIX" >&5
11995 echo "${ECHO_T}$NCURSES_WRAP_PREFIX" >&6
11997 NCURSES_WRAP_PREFIX=_nc_
12000 cat >>confdefs.h <<EOF
12001 #define NCURSES_WRAP_PREFIX "$NCURSES_WRAP_PREFIX"
12004 ###############################################################################
12006 ### use option --disable-echo to suppress full display compiling commands
12008 echo "$as_me:12008: checking if you want to see long compiling messages" >&5
12009 echo $ECHO_N "checking if you want to see long compiling messages... $ECHO_C" >&6
12011 # Check whether --enable-echo or --disable-echo was given.
12012 if test "${enable_echo+set}" = set; then
12013 enableval="$enable_echo"
12014 test "$enableval" != no && enableval=yes
12015 if test "$enableval" != "yes" ; then
12018 ECHO_LD='@echo linking $@;'
12019 RULE_CC='@echo compiling $<'
12020 SHOW_CC='@echo compiling $@'
12042 echo "$as_me:12042: result: $enableval" >&5
12043 echo "${ECHO_T}$enableval" >&6
12045 ### use option --enable-warnings to turn on all gcc warnings
12046 echo "$as_me:12046: checking if you want to see compiler warnings" >&5
12047 echo $ECHO_N "checking if you want to see compiler warnings... $ECHO_C" >&6
12049 # Check whether --enable-warnings or --disable-warnings was given.
12050 if test "${enable_warnings+set}" = set; then
12051 enableval="$enable_warnings"
12052 with_warnings=$enableval
12054 echo "$as_me:12054: result: $with_warnings" >&5
12055 echo "${ECHO_T}$with_warnings" >&6
12057 if test "x$with_warnings" = "xyes"; then
12059 ADAFLAGS="$ADAFLAGS -gnatg"
12063 if test "$GCC" = yes ; then
12066 echo "$as_me:12066: checking if this is really Intel C compiler" >&5
12067 echo $ECHO_N "checking if this is really Intel C compiler... $ECHO_C" >&6
12068 cf_save_CFLAGS="$CFLAGS"
12069 CFLAGS="$CFLAGS -no-gcc"
12070 cat >conftest.$ac_ext <<_ACEOF
12071 #line 12071 "configure"
12072 #include "confdefs.h"
12078 #ifdef __INTEL_COMPILER
12087 rm -f conftest.$ac_objext
12088 if { (eval echo "$as_me:12088: \"$ac_compile\"") >&5
12089 (eval $ac_compile) 2>&5
12091 echo "$as_me:12091: \$? = $ac_status" >&5
12092 (exit $ac_status); } &&
12093 { ac_try='test -s conftest.$ac_objext'
12094 { (eval echo "$as_me:12094: \"$ac_try\"") >&5
12095 (eval $ac_try) 2>&5
12097 echo "$as_me:12097: \$? = $ac_status" >&5
12098 (exit $ac_status); }; }; then
12100 cf_save_CFLAGS="$cf_save_CFLAGS -we147"
12103 echo "$as_me: failed program was:" >&5
12104 cat conftest.$ac_ext >&5
12106 rm -f conftest.$ac_objext conftest.$ac_ext
12107 CFLAGS="$cf_save_CFLAGS"
12108 echo "$as_me:12108: result: $INTEL_COMPILER" >&5
12109 echo "${ECHO_T}$INTEL_COMPILER" >&6
12116 if test "$GCC" = yes ; then
12117 echo "$as_me:12117: checking if this is really Clang C compiler" >&5
12118 echo $ECHO_N "checking if this is really Clang C compiler... $ECHO_C" >&6
12119 cf_save_CFLAGS="$CFLAGS"
12120 CFLAGS="$CFLAGS -Qunused-arguments"
12121 cat >conftest.$ac_ext <<_ACEOF
12122 #line 12122 "configure"
12123 #include "confdefs.h"
12138 rm -f conftest.$ac_objext
12139 if { (eval echo "$as_me:12139: \"$ac_compile\"") >&5
12140 (eval $ac_compile) 2>&5
12142 echo "$as_me:12142: \$? = $ac_status" >&5
12143 (exit $ac_status); } &&
12144 { ac_try='test -s conftest.$ac_objext'
12145 { (eval echo "$as_me:12145: \"$ac_try\"") >&5
12146 (eval $ac_try) 2>&5
12148 echo "$as_me:12148: \$? = $ac_status" >&5
12149 (exit $ac_status); }; }; then
12151 cf_save_CFLAGS="$cf_save_CFLAGS -Qunused-arguments"
12154 echo "$as_me: failed program was:" >&5
12155 cat conftest.$ac_ext >&5
12157 rm -f conftest.$ac_objext conftest.$ac_ext
12158 CFLAGS="$cf_save_CFLAGS"
12159 echo "$as_me:12159: result: $CLANG_COMPILER" >&5
12160 echo "${ECHO_T}$CLANG_COMPILER" >&6
12163 cat > conftest.$ac_ext <<EOF
12164 #line 12164 "${as_me:-configure}"
12165 int main(int argc, char *argv[]) { return (argv[argc-1] == 0) ; }
12168 if test "$INTEL_COMPILER" = yes
12170 # The "-wdXXX" options suppress warnings:
12171 # remark #1419: external declaration in primary source file
12172 # remark #1683: explicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem)
12173 # remark #1684: conversion from pointer to same-sized integral type (potential portability problem)
12174 # remark #193: zero used for undefined preprocessing identifier
12175 # remark #593: variable "curs_sb_left_arrow" was set but never used
12176 # remark #810: conversion from "int" to "Dimension={unsigned short}" may lose significant bits
12177 # remark #869: parameter "tw" was never referenced
12178 # remark #981: operands are evaluated in unspecified order
12179 # warning #279: controlling expression is constant
12181 { echo "$as_me:12181: checking for $CC warning options..." >&5
12182 echo "$as_me: checking for $CC warning options..." >&6;}
12183 cf_save_CFLAGS="$CFLAGS"
12184 EXTRA_CFLAGS="-Wall"
12196 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
12197 if { (eval echo "$as_me:12197: \"$ac_compile\"") >&5
12198 (eval $ac_compile) 2>&5
12200 echo "$as_me:12200: \$? = $ac_status" >&5
12201 (exit $ac_status); }; then
12202 test -n "$verbose" && echo "$as_me:12202: result: ... -$cf_opt" >&5
12203 echo "${ECHO_T}... -$cf_opt" >&6
12204 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
12207 CFLAGS="$cf_save_CFLAGS"
12209 elif test "$GCC" = yes
12211 { echo "$as_me:12211: checking for $CC warning options..." >&5
12212 echo "$as_me: checking for $CC warning options..." >&6;}
12213 cf_save_CFLAGS="$CFLAGS"
12216 test "$with_ext_const" = yes && cf_warn_CONST="Wwrite-strings"
12217 cf_gcc_warnings="Wignored-qualifiers Wlogical-op Wvarargs"
12218 test "x$CLANG_COMPILER" = xyes && cf_gcc_warnings=
12219 for cf_opt in W Wall \
12220 Wbad-function-cast \
12223 Wdeclaration-after-statement \
12226 Wmissing-declarations \
12227 Wmissing-prototypes \
12231 Wstrict-prototypes \
12232 Wundef $cf_gcc_warnings $cf_warn_CONST Wno-unknown-pragmas Wswitch-enum
12234 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
12235 if { (eval echo "$as_me:12235: \"$ac_compile\"") >&5
12236 (eval $ac_compile) 2>&5
12238 echo "$as_me:12238: \$? = $ac_status" >&5
12239 (exit $ac_status); }; then
12240 test -n "$verbose" && echo "$as_me:12240: result: ... -$cf_opt" >&5
12241 echo "${ECHO_T}... -$cf_opt" >&6
12244 CPPFLAGS="$CPPFLAGS -DXTSTRINGDEFINES"
12247 case $GCC_VERSION in
12249 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
12251 echo "${as_me:-configure}:12251: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
12257 case $GCC_VERSION in
12259 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
12261 echo "${as_me:-configure}:12261: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
12267 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
12270 CFLAGS="$cf_save_CFLAGS"
12276 if test "$GCC" = yes
12278 cat > conftest.i <<EOF
12280 #define GCC_PRINTF 0
12283 #define GCC_SCANF 0
12285 #ifndef GCC_NORETURN
12286 #define GCC_NORETURN /* nothing */
12289 #define GCC_UNUSED /* nothing */
12292 if test "$GCC" = yes
12294 { echo "$as_me:12294: checking for $CC __attribute__ directives..." >&5
12295 echo "$as_me: checking for $CC __attribute__ directives..." >&6;}
12296 cat > conftest.$ac_ext <<EOF
12297 #line 12297 "${as_me:-configure}"
12298 #include "confdefs.h"
12299 #include "conftest.h"
12300 #include "conftest.i"
12302 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
12304 #define GCC_PRINTFLIKE(fmt,var) /*nothing*/
12307 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
12309 #define GCC_SCANFLIKE(fmt,var) /*nothing*/
12311 extern void wow(char *,...) GCC_SCANFLIKE(1,2);
12312 extern void oops(char *,...) GCC_PRINTFLIKE(1,2) GCC_NORETURN;
12313 extern void foo(void) GCC_NORETURN;
12314 int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { return 0; }
12316 cf_printf_attribute=no
12317 cf_scanf_attribute=no
12318 for cf_attribute in scanf printf unused noreturn
12321 cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
12323 cf_directive="__attribute__(($cf_attribute))"
12324 echo "checking for $CC $cf_directive" 1>&5
12326 case $cf_attribute in
12328 cf_printf_attribute=yes
12329 cat >conftest.h <<EOF
12330 #define GCC_$cf_ATTRIBUTE 1
12334 cf_scanf_attribute=yes
12335 cat >conftest.h <<EOF
12336 #define GCC_$cf_ATTRIBUTE 1
12340 cat >conftest.h <<EOF
12341 #define GCC_$cf_ATTRIBUTE $cf_directive
12346 if { (eval echo "$as_me:12346: \"$ac_compile\"") >&5
12347 (eval $ac_compile) 2>&5
12349 echo "$as_me:12349: \$? = $ac_status" >&5
12350 (exit $ac_status); }; then
12351 test -n "$verbose" && echo "$as_me:12351: result: ... $cf_attribute" >&5
12352 echo "${ECHO_T}... $cf_attribute" >&6
12353 cat conftest.h >>confdefs.h
12354 case $cf_attribute in
12357 cat >>confdefs.h <<EOF
12358 #define GCC_NORETURN $cf_directive
12363 cf_value='/* nothing */'
12364 if test "$cf_printf_attribute" != no ; then
12365 cf_value='__attribute__((format(printf,fmt,var)))'
12367 cat >>confdefs.h <<\EOF
12368 #define GCC_PRINTF 1
12373 cat >>confdefs.h <<EOF
12374 #define GCC_PRINTFLIKE(fmt,var) $cf_value
12379 cf_value='/* nothing */'
12380 if test "$cf_scanf_attribute" != no ; then
12381 cf_value='__attribute__((format(scanf,fmt,var)))'
12383 cat >>confdefs.h <<\EOF
12384 #define GCC_SCANF 1
12389 cat >>confdefs.h <<EOF
12390 #define GCC_SCANFLIKE(fmt,var) $cf_value
12396 cat >>confdefs.h <<EOF
12397 #define GCC_UNUSED $cf_directive
12405 fgrep define conftest.i >>confdefs.h
12410 ### use option --enable-assertions to turn on generation of assertion code
12411 echo "$as_me:12411: checking if you want to enable runtime assertions" >&5
12412 echo $ECHO_N "checking if you want to enable runtime assertions... $ECHO_C" >&6
12414 # Check whether --enable-assertions or --disable-assertions was given.
12415 if test "${enable_assertions+set}" = set; then
12416 enableval="$enable_assertions"
12417 with_assertions=$enableval
12421 echo "$as_me:12421: result: $with_assertions" >&5
12422 echo "${ECHO_T}$with_assertions" >&6
12425 if test "$with_assertions" = no
12427 CPPFLAGS="$CPPFLAGS -DNDEBUG"
12430 ADAFLAGS="$ADAFLAGS -gnata"
12435 ### use option --disable-leaks to suppress "permanent" leaks, for testing
12437 cat >>confdefs.h <<\EOF
12438 #define HAVE_NC_ALLOC_H 1
12441 ### use option --enable-expanded to generate certain macros as functions
12443 # Check whether --enable-expanded or --disable-expanded was given.
12444 if test "${enable_expanded+set}" = set; then
12445 enableval="$enable_expanded"
12446 test "$enableval" = yes &&
12447 cat >>confdefs.h <<\EOF
12448 #define NCURSES_EXPANDED 1
12453 ### use option --disable-macros to suppress macros in favor of functions
12455 # Check whether --enable-macros or --disable-macros was given.
12456 if test "${enable_macros+set}" = set; then
12457 enableval="$enable_macros"
12458 test "$enableval" = no &&
12459 cat >>confdefs.h <<\EOF
12460 #define NCURSES_NOMACROS 1
12465 # Normally we only add trace() to the debug-library. Allow this to be
12466 # extended to all models of the ncurses library:
12468 case "$CFLAGS $CPPFLAGS" in
12474 echo "$as_me:12474: checking whether to add trace feature to all models" >&5
12475 echo $ECHO_N "checking whether to add trace feature to all models... $ECHO_C" >&6
12477 # Check whether --with-trace or --without-trace was given.
12478 if test "${with_trace+set}" = set; then
12479 withval="$with_trace"
12480 cf_with_trace=$withval
12482 cf_with_trace=$cf_all_traces
12484 echo "$as_me:12484: result: $cf_with_trace" >&5
12485 echo "${ECHO_T}$cf_with_trace" >&6
12487 if test "$cf_with_trace" = yes ; then
12493 cf_new_extra_cppflags=
12495 for cf_add_cflags in -DTRACE
12497 case $cf_fix_cppflags in
12499 case $cf_add_cflags in
12500 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
12501 case $cf_add_cflags in
12503 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
12505 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12506 && test -z "${cf_tst_cflags}" \
12507 && cf_fix_cppflags=yes
12509 if test $cf_fix_cppflags = yes ; then
12511 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12512 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12515 elif test "${cf_tst_cflags}" = "\"'" ; then
12517 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12518 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12524 case "$CPPFLAGS" in
12528 case $cf_add_cflags in
12530 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12532 CPPFLAGS=`echo "$CPPFLAGS" | \
12533 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12534 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12539 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
12540 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
12547 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
12548 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
12555 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12556 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12558 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
12560 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12561 && test -z "${cf_tst_cflags}" \
12562 && cf_fix_cppflags=no
12567 if test -n "$cf_new_cflags" ; then
12569 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
12570 CFLAGS="${CFLAGS}$cf_new_cflags"
12574 if test -n "$cf_new_cppflags" ; then
12576 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
12577 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
12581 if test -n "$cf_new_extra_cppflags" ; then
12583 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
12584 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
12592 echo "$as_me:12592: checking if we want to use GNAT projects" >&5
12593 echo $ECHO_N "checking if we want to use GNAT projects... $ECHO_C" >&6
12595 # Check whether --enable-gnat-projects or --disable-gnat-projects was given.
12596 if test "${enable_gnat_projects+set}" = set; then
12597 enableval="$enable_gnat_projects"
12598 test "$enableval" != no && enableval=yes
12599 if test "$enableval" != "yes" ; then
12600 enable_gnat_projects=no
12602 enable_gnat_projects=yes
12606 enable_gnat_projects=yes
12609 echo "$as_me:12609: result: $enable_gnat_projects" >&5
12610 echo "${ECHO_T}$enable_gnat_projects" >&6
12612 ### Checks for libraries.
12613 case $cf_cv_system_name in
12617 echo "$as_me:12617: checking for gettimeofday" >&5
12618 echo $ECHO_N "checking for gettimeofday... $ECHO_C" >&6
12619 if test "${ac_cv_func_gettimeofday+set}" = set; then
12620 echo $ECHO_N "(cached) $ECHO_C" >&6
12622 cat >conftest.$ac_ext <<_ACEOF
12623 #line 12623 "configure"
12624 #include "confdefs.h"
12625 /* System header to define __stub macros and hopefully few prototypes,
12626 which can conflict with char gettimeofday (); below. */
12627 #include <assert.h>
12628 /* Override any gcc2 internal prototype to avoid an error. */
12632 /* We use char because int might match the return type of a gcc2
12633 builtin and then its argument prototype would still apply. */
12634 char gettimeofday ();
12640 /* The GNU C library defines this for functions which it implements
12641 to always fail with ENOSYS. Some functions are actually named
12642 something starting with __ and the normal name is an alias. */
12643 #if defined (__stub_gettimeofday) || defined (__stub___gettimeofday)
12646 f = gettimeofday; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
12653 rm -f conftest.$ac_objext conftest$ac_exeext
12654 if { (eval echo "$as_me:12654: \"$ac_link\"") >&5
12655 (eval $ac_link) 2>&5
12657 echo "$as_me:12657: \$? = $ac_status" >&5
12658 (exit $ac_status); } &&
12659 { ac_try='test -s conftest$ac_exeext'
12660 { (eval echo "$as_me:12660: \"$ac_try\"") >&5
12661 (eval $ac_try) 2>&5
12663 echo "$as_me:12663: \$? = $ac_status" >&5
12664 (exit $ac_status); }; }; then
12665 ac_cv_func_gettimeofday=yes
12667 echo "$as_me: failed program was:" >&5
12668 cat conftest.$ac_ext >&5
12669 ac_cv_func_gettimeofday=no
12671 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12673 echo "$as_me:12673: result: $ac_cv_func_gettimeofday" >&5
12674 echo "${ECHO_T}$ac_cv_func_gettimeofday" >&6
12675 if test $ac_cv_func_gettimeofday = yes; then
12676 cat >>confdefs.h <<\EOF
12677 #define HAVE_GETTIMEOFDAY 1
12682 echo "$as_me:12682: checking for gettimeofday in -lbsd" >&5
12683 echo $ECHO_N "checking for gettimeofday in -lbsd... $ECHO_C" >&6
12684 if test "${ac_cv_lib_bsd_gettimeofday+set}" = set; then
12685 echo $ECHO_N "(cached) $ECHO_C" >&6
12687 ac_check_lib_save_LIBS=$LIBS
12689 cat >conftest.$ac_ext <<_ACEOF
12690 #line 12690 "configure"
12691 #include "confdefs.h"
12693 /* Override any gcc2 internal prototype to avoid an error. */
12697 /* We use char because int might match the return type of a gcc2
12698 builtin and then its argument prototype would still apply. */
12699 char gettimeofday ();
12708 rm -f conftest.$ac_objext conftest$ac_exeext
12709 if { (eval echo "$as_me:12709: \"$ac_link\"") >&5
12710 (eval $ac_link) 2>&5
12712 echo "$as_me:12712: \$? = $ac_status" >&5
12713 (exit $ac_status); } &&
12714 { ac_try='test -s conftest$ac_exeext'
12715 { (eval echo "$as_me:12715: \"$ac_try\"") >&5
12716 (eval $ac_try) 2>&5
12718 echo "$as_me:12718: \$? = $ac_status" >&5
12719 (exit $ac_status); }; }; then
12720 ac_cv_lib_bsd_gettimeofday=yes
12722 echo "$as_me: failed program was:" >&5
12723 cat conftest.$ac_ext >&5
12724 ac_cv_lib_bsd_gettimeofday=no
12726 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12727 LIBS=$ac_check_lib_save_LIBS
12729 echo "$as_me:12729: result: $ac_cv_lib_bsd_gettimeofday" >&5
12730 echo "${ECHO_T}$ac_cv_lib_bsd_gettimeofday" >&6
12731 if test $ac_cv_lib_bsd_gettimeofday = yes; then
12733 cat >>confdefs.h <<\EOF
12734 #define HAVE_GETTIMEOFDAY 1
12744 ### Checks for header files.
12745 echo "$as_me:12745: checking for ANSI C header files" >&5
12746 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
12747 if test "${ac_cv_header_stdc+set}" = set; then
12748 echo $ECHO_N "(cached) $ECHO_C" >&6
12750 cat >conftest.$ac_ext <<_ACEOF
12751 #line 12751 "configure"
12752 #include "confdefs.h"
12753 #include <stdlib.h>
12754 #include <stdarg.h>
12755 #include <string.h>
12759 if { (eval echo "$as_me:12759: \"$ac_cpp conftest.$ac_ext\"") >&5
12760 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12762 egrep -v '^ *\+' conftest.er1 >conftest.err
12764 cat conftest.err >&5
12765 echo "$as_me:12765: \$? = $ac_status" >&5
12766 (exit $ac_status); } >/dev/null; then
12767 if test -s conftest.err; then
12768 ac_cpp_err=$ac_c_preproc_warn_flag
12775 if test -z "$ac_cpp_err"; then
12776 ac_cv_header_stdc=yes
12778 echo "$as_me: failed program was:" >&5
12779 cat conftest.$ac_ext >&5
12780 ac_cv_header_stdc=no
12782 rm -f conftest.err conftest.$ac_ext
12784 if test $ac_cv_header_stdc = yes; then
12785 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
12786 cat >conftest.$ac_ext <<_ACEOF
12787 #line 12787 "configure"
12788 #include "confdefs.h"
12789 #include <string.h>
12792 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12793 egrep "memchr" >/dev/null 2>&1; then
12796 ac_cv_header_stdc=no
12802 if test $ac_cv_header_stdc = yes; then
12803 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
12804 cat >conftest.$ac_ext <<_ACEOF
12805 #line 12805 "configure"
12806 #include "confdefs.h"
12807 #include <stdlib.h>
12810 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12811 egrep "free" >/dev/null 2>&1; then
12814 ac_cv_header_stdc=no
12820 if test $ac_cv_header_stdc = yes; then
12821 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
12822 if test "$cross_compiling" = yes; then
12825 cat >conftest.$ac_ext <<_ACEOF
12826 #line 12826 "configure"
12827 #include "confdefs.h"
12829 #if ((' ' & 0x0FF) == 0x020)
12830 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
12831 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
12833 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
12834 || ('j' <= (c) && (c) <= 'r') \
12835 || ('s' <= (c) && (c) <= 'z'))
12836 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
12839 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
12844 for (i = 0; i < 256; i++)
12845 if (XOR (islower (i), ISLOWER (i))
12846 || toupper (i) != TOUPPER (i))
12847 $ac_main_return(2);
12848 $ac_main_return (0);
12851 rm -f conftest$ac_exeext
12852 if { (eval echo "$as_me:12852: \"$ac_link\"") >&5
12853 (eval $ac_link) 2>&5
12855 echo "$as_me:12855: \$? = $ac_status" >&5
12856 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
12857 { (eval echo "$as_me:12857: \"$ac_try\"") >&5
12858 (eval $ac_try) 2>&5
12860 echo "$as_me:12860: \$? = $ac_status" >&5
12861 (exit $ac_status); }; }; then
12864 echo "$as_me: program exited with status $ac_status" >&5
12865 echo "$as_me: failed program was:" >&5
12866 cat conftest.$ac_ext >&5
12867 ac_cv_header_stdc=no
12869 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
12873 echo "$as_me:12873: result: $ac_cv_header_stdc" >&5
12874 echo "${ECHO_T}$ac_cv_header_stdc" >&6
12875 if test $ac_cv_header_stdc = yes; then
12877 cat >>confdefs.h <<\EOF
12878 #define STDC_HEADERS 1
12883 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
12885 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
12886 inttypes.h stdint.h unistd.h
12888 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12889 echo "$as_me:12889: checking for $ac_header" >&5
12890 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12891 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12892 echo $ECHO_N "(cached) $ECHO_C" >&6
12894 cat >conftest.$ac_ext <<_ACEOF
12895 #line 12895 "configure"
12896 #include "confdefs.h"
12897 $ac_includes_default
12898 #include <$ac_header>
12900 rm -f conftest.$ac_objext
12901 if { (eval echo "$as_me:12901: \"$ac_compile\"") >&5
12902 (eval $ac_compile) 2>&5
12904 echo "$as_me:12904: \$? = $ac_status" >&5
12905 (exit $ac_status); } &&
12906 { ac_try='test -s conftest.$ac_objext'
12907 { (eval echo "$as_me:12907: \"$ac_try\"") >&5
12908 (eval $ac_try) 2>&5
12910 echo "$as_me:12910: \$? = $ac_status" >&5
12911 (exit $ac_status); }; }; then
12912 eval "$as_ac_Header=yes"
12914 echo "$as_me: failed program was:" >&5
12915 cat conftest.$ac_ext >&5
12916 eval "$as_ac_Header=no"
12918 rm -f conftest.$ac_objext conftest.$ac_ext
12920 echo "$as_me:12920: result: `eval echo '${'$as_ac_Header'}'`" >&5
12921 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12922 if test `eval echo '${'$as_ac_Header'}'` = yes; then
12923 cat >>confdefs.h <<EOF
12924 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12930 echo "$as_me:12930: checking for signed char" >&5
12931 echo $ECHO_N "checking for signed char... $ECHO_C" >&6
12932 if test "${ac_cv_type_signed_char+set}" = set; then
12933 echo $ECHO_N "(cached) $ECHO_C" >&6
12935 cat >conftest.$ac_ext <<_ACEOF
12936 #line 12936 "configure"
12937 #include "confdefs.h"
12938 $ac_includes_default
12942 if ((signed char *) 0)
12944 if (sizeof (signed char))
12950 rm -f conftest.$ac_objext
12951 if { (eval echo "$as_me:12951: \"$ac_compile\"") >&5
12952 (eval $ac_compile) 2>&5
12954 echo "$as_me:12954: \$? = $ac_status" >&5
12955 (exit $ac_status); } &&
12956 { ac_try='test -s conftest.$ac_objext'
12957 { (eval echo "$as_me:12957: \"$ac_try\"") >&5
12958 (eval $ac_try) 2>&5
12960 echo "$as_me:12960: \$? = $ac_status" >&5
12961 (exit $ac_status); }; }; then
12962 ac_cv_type_signed_char=yes
12964 echo "$as_me: failed program was:" >&5
12965 cat conftest.$ac_ext >&5
12966 ac_cv_type_signed_char=no
12968 rm -f conftest.$ac_objext conftest.$ac_ext
12970 echo "$as_me:12970: result: $ac_cv_type_signed_char" >&5
12971 echo "${ECHO_T}$ac_cv_type_signed_char" >&6
12973 echo "$as_me:12973: checking size of signed char" >&5
12974 echo $ECHO_N "checking size of signed char... $ECHO_C" >&6
12975 if test "${ac_cv_sizeof_signed_char+set}" = set; then
12976 echo $ECHO_N "(cached) $ECHO_C" >&6
12978 if test "$ac_cv_type_signed_char" = yes; then
12979 if test "$cross_compiling" = yes; then
12980 # Depending upon the size, compute the lo and hi bounds.
12981 cat >conftest.$ac_ext <<_ACEOF
12982 #line 12982 "configure"
12983 #include "confdefs.h"
12984 $ac_includes_default
12988 int _array_ [1 - 2 * !((sizeof (signed char)) >= 0)]
12993 rm -f conftest.$ac_objext
12994 if { (eval echo "$as_me:12994: \"$ac_compile\"") >&5
12995 (eval $ac_compile) 2>&5
12997 echo "$as_me:12997: \$? = $ac_status" >&5
12998 (exit $ac_status); } &&
12999 { ac_try='test -s conftest.$ac_objext'
13000 { (eval echo "$as_me:13000: \"$ac_try\"") >&5
13001 (eval $ac_try) 2>&5
13003 echo "$as_me:13003: \$? = $ac_status" >&5
13004 (exit $ac_status); }; }; then
13007 cat >conftest.$ac_ext <<_ACEOF
13008 #line 13008 "configure"
13009 #include "confdefs.h"
13010 $ac_includes_default
13014 int _array_ [1 - 2 * !((sizeof (signed char)) <= $ac_mid)]
13019 rm -f conftest.$ac_objext
13020 if { (eval echo "$as_me:13020: \"$ac_compile\"") >&5
13021 (eval $ac_compile) 2>&5
13023 echo "$as_me:13023: \$? = $ac_status" >&5
13024 (exit $ac_status); } &&
13025 { ac_try='test -s conftest.$ac_objext'
13026 { (eval echo "$as_me:13026: \"$ac_try\"") >&5
13027 (eval $ac_try) 2>&5
13029 echo "$as_me:13029: \$? = $ac_status" >&5
13030 (exit $ac_status); }; }; then
13031 ac_hi=$ac_mid; break
13033 echo "$as_me: failed program was:" >&5
13034 cat conftest.$ac_ext >&5
13035 ac_lo=`expr $ac_mid + 1`; ac_mid=`expr 2 '*' $ac_mid + 1`
13037 rm -f conftest.$ac_objext conftest.$ac_ext
13040 echo "$as_me: failed program was:" >&5
13041 cat conftest.$ac_ext >&5
13044 cat >conftest.$ac_ext <<_ACEOF
13045 #line 13045 "configure"
13046 #include "confdefs.h"
13047 $ac_includes_default
13051 int _array_ [1 - 2 * !((sizeof (signed char)) >= $ac_mid)]
13056 rm -f conftest.$ac_objext
13057 if { (eval echo "$as_me:13057: \"$ac_compile\"") >&5
13058 (eval $ac_compile) 2>&5
13060 echo "$as_me:13060: \$? = $ac_status" >&5
13061 (exit $ac_status); } &&
13062 { ac_try='test -s conftest.$ac_objext'
13063 { (eval echo "$as_me:13063: \"$ac_try\"") >&5
13064 (eval $ac_try) 2>&5
13066 echo "$as_me:13066: \$? = $ac_status" >&5
13067 (exit $ac_status); }; }; then
13068 ac_lo=$ac_mid; break
13070 echo "$as_me: failed program was:" >&5
13071 cat conftest.$ac_ext >&5
13072 ac_hi=`expr $ac_mid - 1`; ac_mid=`expr 2 '*' $ac_mid`
13074 rm -f conftest.$ac_objext conftest.$ac_ext
13077 rm -f conftest.$ac_objext conftest.$ac_ext
13078 # Binary search between lo and hi bounds.
13079 while test "x$ac_lo" != "x$ac_hi"; do
13080 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
13081 cat >conftest.$ac_ext <<_ACEOF
13082 #line 13082 "configure"
13083 #include "confdefs.h"
13084 $ac_includes_default
13088 int _array_ [1 - 2 * !((sizeof (signed char)) <= $ac_mid)]
13093 rm -f conftest.$ac_objext
13094 if { (eval echo "$as_me:13094: \"$ac_compile\"") >&5
13095 (eval $ac_compile) 2>&5
13097 echo "$as_me:13097: \$? = $ac_status" >&5
13098 (exit $ac_status); } &&
13099 { ac_try='test -s conftest.$ac_objext'
13100 { (eval echo "$as_me:13100: \"$ac_try\"") >&5
13101 (eval $ac_try) 2>&5
13103 echo "$as_me:13103: \$? = $ac_status" >&5
13104 (exit $ac_status); }; }; then
13107 echo "$as_me: failed program was:" >&5
13108 cat conftest.$ac_ext >&5
13109 ac_lo=`expr $ac_mid + 1`
13111 rm -f conftest.$ac_objext conftest.$ac_ext
13113 ac_cv_sizeof_signed_char=$ac_lo
13115 if test "$cross_compiling" = yes; then
13116 { { echo "$as_me:13116: error: cannot run test program while cross compiling" >&5
13117 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
13118 { (exit 1); exit 1; }; }
13120 cat >conftest.$ac_ext <<_ACEOF
13121 #line 13121 "configure"
13122 #include "confdefs.h"
13123 $ac_includes_default
13127 FILE *f = fopen ("conftest.val", "w");
13129 $ac_main_return (1);
13130 fprintf (f, "%d", (sizeof (signed char)));
13136 rm -f conftest$ac_exeext
13137 if { (eval echo "$as_me:13137: \"$ac_link\"") >&5
13138 (eval $ac_link) 2>&5
13140 echo "$as_me:13140: \$? = $ac_status" >&5
13141 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13142 { (eval echo "$as_me:13142: \"$ac_try\"") >&5
13143 (eval $ac_try) 2>&5
13145 echo "$as_me:13145: \$? = $ac_status" >&5
13146 (exit $ac_status); }; }; then
13147 ac_cv_sizeof_signed_char=`cat conftest.val`
13149 echo "$as_me: program exited with status $ac_status" >&5
13150 echo "$as_me: failed program was:" >&5
13151 cat conftest.$ac_ext >&5
13153 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13158 ac_cv_sizeof_signed_char=0
13161 echo "$as_me:13161: result: $ac_cv_sizeof_signed_char" >&5
13162 echo "${ECHO_T}$ac_cv_sizeof_signed_char" >&6
13163 cat >>confdefs.h <<EOF
13164 #define SIZEOF_SIGNED_CHAR $ac_cv_sizeof_signed_char
13167 echo "$as_me:13167: checking for ANSI C header files" >&5
13168 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
13169 if test "${ac_cv_header_stdc+set}" = set; then
13170 echo $ECHO_N "(cached) $ECHO_C" >&6
13172 cat >conftest.$ac_ext <<_ACEOF
13173 #line 13173 "configure"
13174 #include "confdefs.h"
13175 #include <stdlib.h>
13176 #include <stdarg.h>
13177 #include <string.h>
13181 if { (eval echo "$as_me:13181: \"$ac_cpp conftest.$ac_ext\"") >&5
13182 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13184 egrep -v '^ *\+' conftest.er1 >conftest.err
13186 cat conftest.err >&5
13187 echo "$as_me:13187: \$? = $ac_status" >&5
13188 (exit $ac_status); } >/dev/null; then
13189 if test -s conftest.err; then
13190 ac_cpp_err=$ac_c_preproc_warn_flag
13197 if test -z "$ac_cpp_err"; then
13198 ac_cv_header_stdc=yes
13200 echo "$as_me: failed program was:" >&5
13201 cat conftest.$ac_ext >&5
13202 ac_cv_header_stdc=no
13204 rm -f conftest.err conftest.$ac_ext
13206 if test $ac_cv_header_stdc = yes; then
13207 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
13208 cat >conftest.$ac_ext <<_ACEOF
13209 #line 13209 "configure"
13210 #include "confdefs.h"
13211 #include <string.h>
13214 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13215 egrep "memchr" >/dev/null 2>&1; then
13218 ac_cv_header_stdc=no
13224 if test $ac_cv_header_stdc = yes; then
13225 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
13226 cat >conftest.$ac_ext <<_ACEOF
13227 #line 13227 "configure"
13228 #include "confdefs.h"
13229 #include <stdlib.h>
13232 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13233 egrep "free" >/dev/null 2>&1; then
13236 ac_cv_header_stdc=no
13242 if test $ac_cv_header_stdc = yes; then
13243 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
13244 if test "$cross_compiling" = yes; then
13247 cat >conftest.$ac_ext <<_ACEOF
13248 #line 13248 "configure"
13249 #include "confdefs.h"
13251 #if ((' ' & 0x0FF) == 0x020)
13252 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
13253 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
13255 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
13256 || ('j' <= (c) && (c) <= 'r') \
13257 || ('s' <= (c) && (c) <= 'z'))
13258 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
13261 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
13266 for (i = 0; i < 256; i++)
13267 if (XOR (islower (i), ISLOWER (i))
13268 || toupper (i) != TOUPPER (i))
13269 $ac_main_return(2);
13270 $ac_main_return (0);
13273 rm -f conftest$ac_exeext
13274 if { (eval echo "$as_me:13274: \"$ac_link\"") >&5
13275 (eval $ac_link) 2>&5
13277 echo "$as_me:13277: \$? = $ac_status" >&5
13278 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13279 { (eval echo "$as_me:13279: \"$ac_try\"") >&5
13280 (eval $ac_try) 2>&5
13282 echo "$as_me:13282: \$? = $ac_status" >&5
13283 (exit $ac_status); }; }; then
13286 echo "$as_me: program exited with status $ac_status" >&5
13287 echo "$as_me: failed program was:" >&5
13288 cat conftest.$ac_ext >&5
13289 ac_cv_header_stdc=no
13291 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13295 echo "$as_me:13295: result: $ac_cv_header_stdc" >&5
13296 echo "${ECHO_T}$ac_cv_header_stdc" >&6
13297 if test $ac_cv_header_stdc = yes; then
13299 cat >>confdefs.h <<\EOF
13300 #define STDC_HEADERS 1
13305 ac_header_dirent=no
13306 for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
13307 as_ac_Header=`echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
13308 echo "$as_me:13308: checking for $ac_hdr that defines DIR" >&5
13309 echo $ECHO_N "checking for $ac_hdr that defines DIR... $ECHO_C" >&6
13310 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13311 echo $ECHO_N "(cached) $ECHO_C" >&6
13313 cat >conftest.$ac_ext <<_ACEOF
13314 #line 13314 "configure"
13315 #include "confdefs.h"
13316 #include <sys/types.h>
13328 rm -f conftest.$ac_objext
13329 if { (eval echo "$as_me:13329: \"$ac_compile\"") >&5
13330 (eval $ac_compile) 2>&5
13332 echo "$as_me:13332: \$? = $ac_status" >&5
13333 (exit $ac_status); } &&
13334 { ac_try='test -s conftest.$ac_objext'
13335 { (eval echo "$as_me:13335: \"$ac_try\"") >&5
13336 (eval $ac_try) 2>&5
13338 echo "$as_me:13338: \$? = $ac_status" >&5
13339 (exit $ac_status); }; }; then
13340 eval "$as_ac_Header=yes"
13342 echo "$as_me: failed program was:" >&5
13343 cat conftest.$ac_ext >&5
13344 eval "$as_ac_Header=no"
13346 rm -f conftest.$ac_objext conftest.$ac_ext
13348 echo "$as_me:13348: result: `eval echo '${'$as_ac_Header'}'`" >&5
13349 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13350 if test `eval echo '${'$as_ac_Header'}'` = yes; then
13351 cat >>confdefs.h <<EOF
13352 #define `echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
13355 ac_header_dirent=$ac_hdr; break
13359 # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
13360 if test $ac_header_dirent = dirent.h; then
13361 echo "$as_me:13361: checking for opendir in -ldir" >&5
13362 echo $ECHO_N "checking for opendir in -ldir... $ECHO_C" >&6
13363 if test "${ac_cv_lib_dir_opendir+set}" = set; then
13364 echo $ECHO_N "(cached) $ECHO_C" >&6
13366 ac_check_lib_save_LIBS=$LIBS
13368 cat >conftest.$ac_ext <<_ACEOF
13369 #line 13369 "configure"
13370 #include "confdefs.h"
13372 /* Override any gcc2 internal prototype to avoid an error. */
13376 /* We use char because int might match the return type of a gcc2
13377 builtin and then its argument prototype would still apply. */
13387 rm -f conftest.$ac_objext conftest$ac_exeext
13388 if { (eval echo "$as_me:13388: \"$ac_link\"") >&5
13389 (eval $ac_link) 2>&5
13391 echo "$as_me:13391: \$? = $ac_status" >&5
13392 (exit $ac_status); } &&
13393 { ac_try='test -s conftest$ac_exeext'
13394 { (eval echo "$as_me:13394: \"$ac_try\"") >&5
13395 (eval $ac_try) 2>&5
13397 echo "$as_me:13397: \$? = $ac_status" >&5
13398 (exit $ac_status); }; }; then
13399 ac_cv_lib_dir_opendir=yes
13401 echo "$as_me: failed program was:" >&5
13402 cat conftest.$ac_ext >&5
13403 ac_cv_lib_dir_opendir=no
13405 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13406 LIBS=$ac_check_lib_save_LIBS
13408 echo "$as_me:13408: result: $ac_cv_lib_dir_opendir" >&5
13409 echo "${ECHO_T}$ac_cv_lib_dir_opendir" >&6
13410 if test $ac_cv_lib_dir_opendir = yes; then
13415 echo "$as_me:13415: checking for opendir in -lx" >&5
13416 echo $ECHO_N "checking for opendir in -lx... $ECHO_C" >&6
13417 if test "${ac_cv_lib_x_opendir+set}" = set; then
13418 echo $ECHO_N "(cached) $ECHO_C" >&6
13420 ac_check_lib_save_LIBS=$LIBS
13422 cat >conftest.$ac_ext <<_ACEOF
13423 #line 13423 "configure"
13424 #include "confdefs.h"
13426 /* Override any gcc2 internal prototype to avoid an error. */
13430 /* We use char because int might match the return type of a gcc2
13431 builtin and then its argument prototype would still apply. */
13441 rm -f conftest.$ac_objext conftest$ac_exeext
13442 if { (eval echo "$as_me:13442: \"$ac_link\"") >&5
13443 (eval $ac_link) 2>&5
13445 echo "$as_me:13445: \$? = $ac_status" >&5
13446 (exit $ac_status); } &&
13447 { ac_try='test -s conftest$ac_exeext'
13448 { (eval echo "$as_me:13448: \"$ac_try\"") >&5
13449 (eval $ac_try) 2>&5
13451 echo "$as_me:13451: \$? = $ac_status" >&5
13452 (exit $ac_status); }; }; then
13453 ac_cv_lib_x_opendir=yes
13455 echo "$as_me: failed program was:" >&5
13456 cat conftest.$ac_ext >&5
13457 ac_cv_lib_x_opendir=no
13459 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13460 LIBS=$ac_check_lib_save_LIBS
13462 echo "$as_me:13462: result: $ac_cv_lib_x_opendir" >&5
13463 echo "${ECHO_T}$ac_cv_lib_x_opendir" >&6
13464 if test $ac_cv_lib_x_opendir = yes; then
13470 echo "$as_me:13470: checking whether time.h and sys/time.h may both be included" >&5
13471 echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
13472 if test "${ac_cv_header_time+set}" = set; then
13473 echo $ECHO_N "(cached) $ECHO_C" >&6
13475 cat >conftest.$ac_ext <<_ACEOF
13476 #line 13476 "configure"
13477 #include "confdefs.h"
13478 #include <sys/types.h>
13479 #include <sys/time.h>
13485 if ((struct tm *) 0)
13491 rm -f conftest.$ac_objext
13492 if { (eval echo "$as_me:13492: \"$ac_compile\"") >&5
13493 (eval $ac_compile) 2>&5
13495 echo "$as_me:13495: \$? = $ac_status" >&5
13496 (exit $ac_status); } &&
13497 { ac_try='test -s conftest.$ac_objext'
13498 { (eval echo "$as_me:13498: \"$ac_try\"") >&5
13499 (eval $ac_try) 2>&5
13501 echo "$as_me:13501: \$? = $ac_status" >&5
13502 (exit $ac_status); }; }; then
13503 ac_cv_header_time=yes
13505 echo "$as_me: failed program was:" >&5
13506 cat conftest.$ac_ext >&5
13507 ac_cv_header_time=no
13509 rm -f conftest.$ac_objext conftest.$ac_ext
13511 echo "$as_me:13511: result: $ac_cv_header_time" >&5
13512 echo "${ECHO_T}$ac_cv_header_time" >&6
13513 if test $ac_cv_header_time = yes; then
13515 cat >>confdefs.h <<\EOF
13516 #define TIME_WITH_SYS_TIME 1
13521 ### checks for compiler characteristics
13523 ac_cpp='$CPP $CPPFLAGS'
13524 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
13525 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
13526 ac_compiler_gnu=$ac_cv_c_compiler_gnu
13527 ac_main_return=return
13529 echo "$as_me:13529: checking for an ANSI C-conforming const" >&5
13530 echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
13531 if test "${ac_cv_c_const+set}" = set; then
13532 echo $ECHO_N "(cached) $ECHO_C" >&6
13534 cat >conftest.$ac_ext <<_ACEOF
13535 #line 13535 "configure"
13536 #include "confdefs.h"
13541 /* FIXME: Include the comments suggested by Paul. */
13542 #ifndef __cplusplus
13543 /* Ultrix mips cc rejects this. */
13544 typedef int charset[2];
13546 /* SunOS 4.1.1 cc rejects this. */
13547 char const *const *ccp;
13549 /* NEC SVR4.0.2 mips cc rejects this. */
13550 struct point {int x, y;};
13551 static struct point const zero = {0,0};
13552 /* AIX XL C 1.02.0.0 rejects this.
13553 It does not let you subtract one const X* pointer from another in
13554 an arm of an if-expression whose if-part is not a constant
13556 const char *g = "string";
13557 ccp = &g + (g ? g-g : 0);
13558 /* HPUX 7.0 cc rejects these. */
13561 ccp = (char const *const *) p;
13562 { /* SCO 3.2v4 cc rejects this. */
13564 char const *s = 0 ? (char *) 0 : (char const *) 0;
13568 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
13569 int x[] = {25, 17};
13570 const int *foo = &x[0];
13573 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
13574 typedef const int *iptr;
13578 { /* AIX XL C 1.02.0.0 rejects this saying
13579 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
13580 struct s { int j; const int *ap[3]; };
13581 struct s *b; b->j = 5;
13583 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
13584 const int foo = 10;
13592 rm -f conftest.$ac_objext
13593 if { (eval echo "$as_me:13593: \"$ac_compile\"") >&5
13594 (eval $ac_compile) 2>&5
13596 echo "$as_me:13596: \$? = $ac_status" >&5
13597 (exit $ac_status); } &&
13598 { ac_try='test -s conftest.$ac_objext'
13599 { (eval echo "$as_me:13599: \"$ac_try\"") >&5
13600 (eval $ac_try) 2>&5
13602 echo "$as_me:13602: \$? = $ac_status" >&5
13603 (exit $ac_status); }; }; then
13606 echo "$as_me: failed program was:" >&5
13607 cat conftest.$ac_ext >&5
13610 rm -f conftest.$ac_objext conftest.$ac_ext
13612 echo "$as_me:13612: result: $ac_cv_c_const" >&5
13613 echo "${ECHO_T}$ac_cv_c_const" >&6
13614 if test $ac_cv_c_const = no; then
13616 cat >>confdefs.h <<\EOF
13622 ### Checks for external-data
13624 echo "$as_me:13624: checking if data-only library module links" >&5
13625 echo $ECHO_N "checking if data-only library module links... $ECHO_C" >&6
13626 if test "${cf_cv_link_dataonly+set}" = set; then
13627 echo $ECHO_N "(cached) $ECHO_C" >&6
13631 cat >conftest.$ac_ext <<EOF
13632 #line 13632 "configure"
13633 int testdata[3] = { 123, 456, 789 };
13635 if { (eval echo "$as_me:13635: \"$ac_compile\"") >&5
13636 (eval $ac_compile) 2>&5
13638 echo "$as_me:13638: \$? = $ac_status" >&5
13639 (exit $ac_status); } ; then
13640 mv conftest.o data.o && \
13641 ( $AR $ARFLAGS conftest.a data.o ) 2>&5 1>/dev/null
13643 rm -f conftest.$ac_ext data.o
13644 cat >conftest.$ac_ext <<EOF
13645 #line 13645 "configure"
13649 ${cf_cv_main_return:-return}(1); /* I'm told this linker is broken */
13651 extern int testdata[3];
13652 return testdata[0] == 123
13653 && testdata[1] == 456
13654 && testdata[2] == 789;
13658 if { (eval echo "$as_me:13658: \"$ac_compile\"") >&5
13659 (eval $ac_compile) 2>&5
13661 echo "$as_me:13661: \$? = $ac_status" >&5
13662 (exit $ac_status); }; then
13663 mv conftest.o func.o && \
13664 ( $AR $ARFLAGS conftest.a func.o ) 2>&5 1>/dev/null
13666 rm -f conftest.$ac_ext func.o
13667 ( eval $RANLIB conftest.a ) 2>&5 >/dev/null
13668 cf_saveLIBS="$LIBS"
13669 LIBS="conftest.a $LIBS"
13670 if test "$cross_compiling" = yes; then
13671 cf_cv_link_dataonly=unknown
13673 cat >conftest.$ac_ext <<_ACEOF
13674 #line 13674 "configure"
13675 #include "confdefs.h"
13679 extern int testfunc();
13680 ${cf_cv_main_return:-return} (!testfunc());
13684 rm -f conftest$ac_exeext
13685 if { (eval echo "$as_me:13685: \"$ac_link\"") >&5
13686 (eval $ac_link) 2>&5
13688 echo "$as_me:13688: \$? = $ac_status" >&5
13689 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13690 { (eval echo "$as_me:13690: \"$ac_try\"") >&5
13691 (eval $ac_try) 2>&5
13693 echo "$as_me:13693: \$? = $ac_status" >&5
13694 (exit $ac_status); }; }; then
13695 cf_cv_link_dataonly=yes
13697 echo "$as_me: program exited with status $ac_status" >&5
13698 echo "$as_me: failed program was:" >&5
13699 cat conftest.$ac_ext >&5
13700 cf_cv_link_dataonly=no
13702 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13704 LIBS="$cf_saveLIBS"
13708 echo "$as_me:13708: result: $cf_cv_link_dataonly" >&5
13709 echo "${ECHO_T}$cf_cv_link_dataonly" >&6
13711 if test "$cf_cv_link_dataonly" = no ; then
13713 cat >>confdefs.h <<\EOF
13714 #define BROKEN_LINKER 1
13720 ### Checks for library functions.
13726 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
13727 echo "$as_me:13727: checking for $ac_header" >&5
13728 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13729 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13730 echo $ECHO_N "(cached) $ECHO_C" >&6
13732 cat >conftest.$ac_ext <<_ACEOF
13733 #line 13733 "configure"
13734 #include "confdefs.h"
13735 #include <$ac_header>
13737 if { (eval echo "$as_me:13737: \"$ac_cpp conftest.$ac_ext\"") >&5
13738 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13740 egrep -v '^ *\+' conftest.er1 >conftest.err
13742 cat conftest.err >&5
13743 echo "$as_me:13743: \$? = $ac_status" >&5
13744 (exit $ac_status); } >/dev/null; then
13745 if test -s conftest.err; then
13746 ac_cpp_err=$ac_c_preproc_warn_flag
13753 if test -z "$ac_cpp_err"; then
13754 eval "$as_ac_Header=yes"
13756 echo "$as_me: failed program was:" >&5
13757 cat conftest.$ac_ext >&5
13758 eval "$as_ac_Header=no"
13760 rm -f conftest.err conftest.$ac_ext
13762 echo "$as_me:13762: result: `eval echo '${'$as_ac_Header'}'`" >&5
13763 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13764 if test `eval echo '${'$as_ac_Header'}'` = yes; then
13765 cat >>confdefs.h <<EOF
13766 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
13772 echo "$as_me:13772: checking for working mkstemp" >&5
13773 echo $ECHO_N "checking for working mkstemp... $ECHO_C" >&6
13774 if test "${cf_cv_func_mkstemp+set}" = set; then
13775 echo $ECHO_N "(cached) $ECHO_C" >&6
13779 if test "$cross_compiling" = yes; then
13780 cf_cv_func_mkstemp=maybe
13782 cat >conftest.$ac_ext <<_ACEOF
13783 #line 13783 "configure"
13784 #include "confdefs.h"
13786 #include <sys/types.h>
13787 #ifdef HAVE_UNISTD_H
13788 #include <unistd.h>
13790 #include <stdlib.h>
13792 #include <string.h>
13793 #include <sys/stat.h>
13796 char *tmpl = "conftestXXXXXX";
13804 for (n = 0; n < 2; ++n) {
13805 strcpy(name[n], tmpl);
13806 if ((fd = mkstemp(name[n])) >= 0) {
13807 if (!strcmp(name[n], tmpl)
13808 || stat(name[n], &sb) != 0
13809 || (sb.st_mode & S_IFMT) != S_IFREG
13810 || (sb.st_mode & 077) != 0) {
13817 && !strcmp(name[0], name[1]))
13819 ${cf_cv_main_return:-return}(result);
13823 rm -f conftest$ac_exeext
13824 if { (eval echo "$as_me:13824: \"$ac_link\"") >&5
13825 (eval $ac_link) 2>&5
13827 echo "$as_me:13827: \$? = $ac_status" >&5
13828 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13829 { (eval echo "$as_me:13829: \"$ac_try\"") >&5
13830 (eval $ac_try) 2>&5
13832 echo "$as_me:13832: \$? = $ac_status" >&5
13833 (exit $ac_status); }; }; then
13834 cf_cv_func_mkstemp=yes
13837 echo "$as_me: program exited with status $ac_status" >&5
13838 echo "$as_me: failed program was:" >&5
13839 cat conftest.$ac_ext >&5
13840 cf_cv_func_mkstemp=no
13843 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13847 echo "$as_me:13847: result: $cf_cv_func_mkstemp" >&5
13848 echo "${ECHO_T}$cf_cv_func_mkstemp" >&6
13849 if test "x$cf_cv_func_mkstemp" = xmaybe ; then
13850 echo "$as_me:13850: checking for mkstemp" >&5
13851 echo $ECHO_N "checking for mkstemp... $ECHO_C" >&6
13852 if test "${ac_cv_func_mkstemp+set}" = set; then
13853 echo $ECHO_N "(cached) $ECHO_C" >&6
13855 cat >conftest.$ac_ext <<_ACEOF
13856 #line 13856 "configure"
13857 #include "confdefs.h"
13858 /* System header to define __stub macros and hopefully few prototypes,
13859 which can conflict with char mkstemp (); below. */
13860 #include <assert.h>
13861 /* Override any gcc2 internal prototype to avoid an error. */
13865 /* We use char because int might match the return type of a gcc2
13866 builtin and then its argument prototype would still apply. */
13873 /* The GNU C library defines this for functions which it implements
13874 to always fail with ENOSYS. Some functions are actually named
13875 something starting with __ and the normal name is an alias. */
13876 #if defined (__stub_mkstemp) || defined (__stub___mkstemp)
13879 f = mkstemp; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
13886 rm -f conftest.$ac_objext conftest$ac_exeext
13887 if { (eval echo "$as_me:13887: \"$ac_link\"") >&5
13888 (eval $ac_link) 2>&5
13890 echo "$as_me:13890: \$? = $ac_status" >&5
13891 (exit $ac_status); } &&
13892 { ac_try='test -s conftest$ac_exeext'
13893 { (eval echo "$as_me:13893: \"$ac_try\"") >&5
13894 (eval $ac_try) 2>&5
13896 echo "$as_me:13896: \$? = $ac_status" >&5
13897 (exit $ac_status); }; }; then
13898 ac_cv_func_mkstemp=yes
13900 echo "$as_me: failed program was:" >&5
13901 cat conftest.$ac_ext >&5
13902 ac_cv_func_mkstemp=no
13904 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13906 echo "$as_me:13906: result: $ac_cv_func_mkstemp" >&5
13907 echo "${ECHO_T}$ac_cv_func_mkstemp" >&6
13910 if test "x$cf_cv_func_mkstemp" = xyes || test "x$ac_cv_func_mkstemp" = xyes ; then
13912 cat >>confdefs.h <<\EOF
13913 #define HAVE_MKSTEMP 1
13918 if test -z "$cf_user_CFLAGS" && test "$with_no_leaks" = no ; then
13919 CFLAGS=`echo ${CFLAGS} | sed -e 's%-g %%' -e 's%-g$%%'`
13920 CXXFLAGS=`echo ${CXXFLAGS} | sed -e 's%-g %%' -e 's%-g$%%'`
13924 if test "$cf_with_ada" != "no" ; then
13926 cf_ada_make=gnatmake
13927 # Extract the first word of "$cf_ada_make", so it can be a program name with args.
13928 set dummy $cf_ada_make; ac_word=$2
13929 echo "$as_me:13929: checking for $ac_word" >&5
13930 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
13931 if test "${ac_cv_prog_gnat_exists+set}" = set; then
13932 echo $ECHO_N "(cached) $ECHO_C" >&6
13934 if test -n "$gnat_exists"; then
13935 ac_cv_prog_gnat_exists="$gnat_exists" # Let the user override the test.
13937 ac_save_IFS=$IFS; IFS=$ac_path_separator
13939 for ac_dir in $ac_dummy; do
13941 test -z "$ac_dir" && ac_dir=.
13942 $as_executable_p "$ac_dir/$ac_word" || continue
13943 ac_cv_prog_gnat_exists="yes"
13944 echo "$as_me:13944: found $ac_dir/$ac_word" >&5
13948 test -z "$ac_cv_prog_gnat_exists" && ac_cv_prog_gnat_exists="no"
13951 gnat_exists=$ac_cv_prog_gnat_exists
13952 if test -n "$gnat_exists"; then
13953 echo "$as_me:13953: result: $gnat_exists" >&5
13954 echo "${ECHO_T}$gnat_exists" >&6
13956 echo "$as_me:13956: result: no" >&5
13957 echo "${ECHO_T}no" >&6
13960 if test "$ac_cv_prog_gnat_exists" = no; then
13962 cf_cv_prog_gnat_correct=no
13965 echo "$as_me:13965: checking for gnat version" >&5
13966 echo $ECHO_N "checking for gnat version... $ECHO_C" >&6
13967 cf_gnat_version=`${cf_ada_make:-gnatmake} -v 2>&1 | \
13968 grep '[0-9].[0-9][0-9]*' |\
13969 sed -e '2,$d' -e 's/[^0-9 \.]//g' -e 's/^[ ]*//' -e 's/ .*//'`
13970 echo "$as_me:13970: result: $cf_gnat_version" >&5
13971 echo "${ECHO_T}$cf_gnat_version" >&6
13973 case $cf_gnat_version in
13974 (3.1[1-9]*|3.[2-9]*|[4-9].*|20[0-9][0-9])
13975 cf_cv_prog_gnat_correct=yes
13978 { echo "$as_me:13978: WARNING: Unsupported GNAT version $cf_gnat_version. We require 3.11 or better. Disabling Ada95 binding." >&5
13979 echo "$as_me: WARNING: Unsupported GNAT version $cf_gnat_version. We require 3.11 or better. Disabling Ada95 binding." >&2;}
13980 cf_cv_prog_gnat_correct=no
13984 # Extract the first word of "m4", so it can be a program name with args.
13985 set dummy m4; ac_word=$2
13986 echo "$as_me:13986: checking for $ac_word" >&5
13987 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
13988 if test "${ac_cv_prog_M4_exists+set}" = set; then
13989 echo $ECHO_N "(cached) $ECHO_C" >&6
13991 if test -n "$M4_exists"; then
13992 ac_cv_prog_M4_exists="$M4_exists" # Let the user override the test.
13994 ac_save_IFS=$IFS; IFS=$ac_path_separator
13996 for ac_dir in $ac_dummy; do
13998 test -z "$ac_dir" && ac_dir=.
13999 $as_executable_p "$ac_dir/$ac_word" || continue
14000 ac_cv_prog_M4_exists="yes"
14001 echo "$as_me:14001: found $ac_dir/$ac_word" >&5
14005 test -z "$ac_cv_prog_M4_exists" && ac_cv_prog_M4_exists="no"
14008 M4_exists=$ac_cv_prog_M4_exists
14009 if test -n "$M4_exists"; then
14010 echo "$as_me:14010: result: $M4_exists" >&5
14011 echo "${ECHO_T}$M4_exists" >&6
14013 echo "$as_me:14013: result: no" >&5
14014 echo "${ECHO_T}no" >&6
14017 if test "$ac_cv_prog_M4_exists" = no; then
14018 cf_cv_prog_gnat_correct=no
14019 echo Ada95 binding required program m4 not found. Ada95 binding disabled.
14021 if test "$cf_cv_prog_gnat_correct" = yes; then
14022 echo "$as_me:14022: checking if GNAT works" >&5
14023 echo $ECHO_N "checking if GNAT works... $ECHO_C" >&6
14025 rm -rf conftest* *~conftest*
14026 cat >>conftest.ads <<CF_EOF
14027 procedure conftest;
14029 cat >>conftest.adb <<CF_EOF
14032 procedure conftest is
14034 Text_IO.Put ("Hello World");
14036 GNAT.OS_Lib.OS_Exit (0);
14039 if ( $cf_ada_make $ADAFLAGS conftest 1>&5 2>&1 ) ; then
14040 if ( ./conftest 1>&5 2>&1 ) ; then
14041 cf_cv_prog_gnat_correct=yes
14043 cf_cv_prog_gnat_correct=no
14046 cf_cv_prog_gnat_correct=no
14048 rm -rf conftest* *~conftest*
14050 echo "$as_me:14050: result: $cf_cv_prog_gnat_correct" >&5
14051 echo "${ECHO_T}$cf_cv_prog_gnat_correct" >&6
14055 if test "$cf_cv_prog_gnat_correct" = yes; then
14057 echo "$as_me:14057: checking optimization options for ADAFLAGS" >&5
14058 echo $ECHO_N "checking optimization options for ADAFLAGS... $ECHO_C" >&6
14062 ADAFLAGS="$ADAFLAGS -g"
14068 cf_O_flag=`echo "$CFLAGS" |sed -e 's/^.*-O/-O/' -e 's/[ ].*//'`
14070 ADAFLAGS="$ADAFLAGS $cf_O_flag"
14074 echo "$as_me:14074: result: $ADAFLAGS" >&5
14075 echo "${ECHO_T}$ADAFLAGS" >&6
14077 echo "$as_me:14077: checking if GNATPREP supports -T option" >&5
14078 echo $ECHO_N "checking if GNATPREP supports -T option... $ECHO_C" >&6
14079 if test "${cf_cv_gnatprep_opt_t+set}" = set; then
14080 echo $ECHO_N "(cached) $ECHO_C" >&6
14083 cf_cv_gnatprep_opt_t=no
14084 gnatprep -T 2>/dev/null >/dev/null && cf_cv_gnatprep_opt_t=yes
14087 echo "$as_me:14087: result: $cf_cv_gnatprep_opt_t" >&5
14088 echo "${ECHO_T}$cf_cv_gnatprep_opt_t" >&6
14089 test "$cf_cv_gnatprep_opt_t" = yes && GNATPREP_OPTS="-T $GNATPREP_OPTS"
14091 echo "$as_me:14091: checking if GNAT supports generics" >&5
14092 echo $ECHO_N "checking if GNAT supports generics... $ECHO_C" >&6
14093 case $cf_gnat_version in
14095 cf_gnat_generics=yes
14098 cf_gnat_generics=no
14101 echo "$as_me:14101: result: $cf_gnat_generics" >&5
14102 echo "${ECHO_T}$cf_gnat_generics" >&6
14104 if test "$cf_gnat_generics" = yes
14106 cf_compile_generics=generics
14107 cf_generic_objects="\${GENOBJS}"
14109 cf_compile_generics=
14110 cf_generic_objects=
14113 echo "$as_me:14113: checking if GNAT supports SIGINT" >&5
14114 echo $ECHO_N "checking if GNAT supports SIGINT... $ECHO_C" >&6
14115 if test "${cf_cv_gnat_sigint+set}" = set; then
14116 echo $ECHO_N "(cached) $ECHO_C" >&6
14119 rm -rf conftest* *~conftest*
14120 cat >>conftest.ads <<CF_EOF
14121 with Ada.Interrupts.Names;
14123 package ConfTest is
14125 pragma Warnings (Off); -- the next pragma exists since 3.11p
14126 pragma Unreserve_All_Interrupts;
14127 pragma Warnings (On);
14129 protected Process is
14131 function Continue return Boolean;
14132 pragma Attach_Handler (Stop, Ada.Interrupts.Names.SIGINT);
14134 Done : Boolean := False;
14139 cat >>conftest.adb <<CF_EOF
14140 package body ConfTest is
14141 protected body Process is
14146 function Continue return Boolean is
14153 if ( $cf_ada_make $ADAFLAGS conftest 1>&5 2>&1 ) ; then
14154 cf_cv_gnat_sigint=yes
14156 cf_cv_gnat_sigint=no
14158 rm -rf conftest* *~conftest*
14161 echo "$as_me:14161: result: $cf_cv_gnat_sigint" >&5
14162 echo "${ECHO_T}$cf_cv_gnat_sigint" >&6
14164 if test $cf_cv_gnat_sigint = yes ; then
14167 USE_GNAT_SIGINT="#"
14170 cf_gnat_libraries=no
14171 cf_gnat_projects=no
14173 if test "$enable_gnat_projects" != no ; then
14174 echo "$as_me:14174: checking if GNAT supports project files" >&5
14175 echo $ECHO_N "checking if GNAT supports project files... $ECHO_C" >&6
14176 case $cf_gnat_version in
14180 case $cf_cv_system_name in
14184 mkdir conftest.src conftest.bin conftest.lib
14186 rm -rf conftest* *~conftest*
14187 cat >>library.gpr <<CF_EOF
14189 Kind := External ("LIB_KIND");
14190 for Library_Name use "ConfTest";
14191 for Object_Dir use ".";
14192 for Library_ALI_Dir use External("LIBRARY_DIR");
14193 for Library_Version use External ("SONAME");
14194 for Library_Kind use Kind;
14195 for Library_Dir use External("BUILD_DIR");
14196 Source_Dir := External ("SOURCE_DIR");
14197 for Source_Dirs use (Source_Dir);
14200 cat >>confpackage.ads <<CF_EOF
14201 package ConfPackage is
14202 procedure conftest;
14205 cat >>confpackage.adb <<CF_EOF
14207 package body ConfPackage is
14208 procedure conftest is
14210 Text_IO.Put ("Hello World");
14215 if ( $cf_ada_make $ADAFLAGS \
14217 -XBUILD_DIR=`cd ../conftest.bin;pwd` \
14218 -XLIBRARY_DIR=`cd ../conftest.lib;pwd` \
14219 -XSOURCE_DIR=`pwd` \
14220 -XSONAME=libConfTest.so.1 \
14221 -XLIB_KIND=static 1>&5 2>&1 ) ; then
14222 cf_gnat_projects=yes
14225 if test -f conftest.lib/confpackage.ali
14227 cf_gnat_libraries=yes
14229 rm -rf conftest* *~conftest*
14234 echo "$as_me:14234: result: $cf_gnat_projects" >&5
14235 echo "${ECHO_T}$cf_gnat_projects" >&6
14236 fi # enable_gnat_projects
14238 if test $cf_gnat_projects = yes
14240 echo "$as_me:14240: checking if GNAT supports libraries" >&5
14241 echo $ECHO_N "checking if GNAT supports libraries... $ECHO_C" >&6
14242 echo "$as_me:14242: result: $cf_gnat_libraries" >&5
14243 echo "${ECHO_T}$cf_gnat_libraries" >&6
14246 if test "$cf_gnat_projects" = yes
14248 USE_OLD_MAKERULES="#"
14249 USE_GNAT_PROJECTS=""
14251 USE_OLD_MAKERULES=""
14252 USE_GNAT_PROJECTS="#"
14255 if test "$cf_gnat_libraries" = yes
14257 USE_GNAT_LIBRARIES=""
14259 USE_GNAT_LIBRARIES="#"
14262 echo "$as_me:14262: checking for ada-compiler" >&5
14263 echo $ECHO_N "checking for ada-compiler... $ECHO_C" >&6
14265 # Check whether --with-ada-compiler or --without-ada-compiler was given.
14266 if test "${with_ada_compiler+set}" = set; then
14267 withval="$with_ada_compiler"
14268 cf_ada_compiler=$withval
14270 cf_ada_compiler=gnatmake
14273 echo "$as_me:14273: result: $cf_ada_compiler" >&5
14274 echo "${ECHO_T}$cf_ada_compiler" >&6
14276 cf_ada_package=terminal_interface
14278 echo "$as_me:14278: checking for ada-include" >&5
14279 echo $ECHO_N "checking for ada-include... $ECHO_C" >&6
14281 # Check whether --with-ada-include or --without-ada-include was given.
14282 if test "${with_ada_include+set}" = set; then
14283 withval="$with_ada_include"
14286 withval="${ADA_INCLUDE:-$prefix/share/ada/adainclude}"
14287 fi; if test -n "$prefix/share/ada/adainclude" ; then
14289 if test "x$prefix" != xNONE; then
14290 cf_path_syntax="$prefix"
14292 cf_path_syntax="$ac_default_prefix"
14295 case ".$withval" in
14296 (.\$\(*\)*|.\'*\'*)
14300 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
14302 (.\${*prefix}*|.\${*dir}*)
14303 eval withval="$withval"
14304 case ".$withval" in
14306 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
14311 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
14314 { { echo "$as_me:14314: error: expected a pathname, not \"$withval\"" >&5
14315 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
14316 { (exit 1); exit 1; }; }
14321 eval ADA_INCLUDE="$withval"
14323 echo "$as_me:14323: result: $ADA_INCLUDE" >&5
14324 echo "${ECHO_T}$ADA_INCLUDE" >&6
14326 echo "$as_me:14326: checking for ada-objects" >&5
14327 echo $ECHO_N "checking for ada-objects... $ECHO_C" >&6
14329 # Check whether --with-ada-objects or --without-ada-objects was given.
14330 if test "${with_ada_objects+set}" = set; then
14331 withval="$with_ada_objects"
14334 withval="${ADA_OBJECTS:-$prefix/lib/ada/adalib}"
14335 fi; if test -n "$prefix/lib/ada/adalib" ; then
14337 if test "x$prefix" != xNONE; then
14338 cf_path_syntax="$prefix"
14340 cf_path_syntax="$ac_default_prefix"
14343 case ".$withval" in
14344 (.\$\(*\)*|.\'*\'*)
14348 (.[a-zA-Z]:[\\/]*) # OS/2 EMX
14350 (.\${*prefix}*|.\${*dir}*)
14351 eval withval="$withval"
14352 case ".$withval" in
14354 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
14359 withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
14362 { { echo "$as_me:14362: error: expected a pathname, not \"$withval\"" >&5
14363 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
14364 { (exit 1); exit 1; }; }
14369 eval ADA_OBJECTS="$withval"
14371 echo "$as_me:14371: result: $ADA_OBJECTS" >&5
14372 echo "${ECHO_T}$ADA_OBJECTS" >&6
14374 echo "$as_me:14374: checking if an Ada95 shared-library should be built" >&5
14375 echo $ECHO_N "checking if an Ada95 shared-library should be built... $ECHO_C" >&6
14377 # Check whether --with-ada-sharedlib or --without-ada-sharedlib was given.
14378 if test "${with_ada_sharedlib+set}" = set; then
14379 withval="$with_ada_sharedlib"
14380 with_ada_sharedlib=$withval
14382 with_ada_sharedlib=no
14384 echo "$as_me:14384: result: $with_ada_sharedlib" >&5
14385 echo "${ECHO_T}$with_ada_sharedlib" >&6
14387 ADA_SHAREDLIB='lib$(LIB_NAME).so.1'
14388 MAKE_ADA_SHAREDLIB="#"
14390 if test "x$with_ada_sharedlib" != xno
14392 MAKE_ADA_SHAREDLIB=
14393 if test "x$with_ada_sharedlib" != xyes
14395 ADA_SHAREDLIB="$with_ada_sharedlib"
14400 { { echo "$as_me:14400: error: No usable Ada compiler found" >&5
14401 echo "$as_me: error: No usable Ada compiler found" >&2;}
14402 { (exit 1); exit 1; }; }
14405 { { echo "$as_me:14405: error: The Ada compiler is needed for this package" >&5
14406 echo "$as_me: error: The Ada compiler is needed for this package" >&2;}
14407 { (exit 1); exit 1; }; }
14410 ################################################################################
14417 ### Construct the list of include-directories to be generated
14419 if test "$srcdir" != "."; then
14420 CPPFLAGS="-I\${srcdir}/../include $CPPFLAGS"
14422 CPPFLAGS="-I../include $CPPFLAGS"
14423 if test "$srcdir" != "."; then
14424 CPPFLAGS="-I\${srcdir} $CPPFLAGS"
14426 CPPFLAGS="-I. $CPPFLAGS"
14428 ACPPFLAGS="-I. -I../include -I../../include $ACPPFLAGS"
14429 if test "$srcdir" != "."; then
14430 ACPPFLAGS="-I\${srcdir}/../../include $ACPPFLAGS"
14432 if test "$GCC" != yes; then
14433 ACPPFLAGS="$ACPPFLAGS -I\${includedir}"
14434 elif test "$includedir" != "/usr/include"; then
14435 if test "$includedir" = '${prefix}/include' ; then
14436 if test x$prefix != x/usr ; then
14437 ACPPFLAGS="$ACPPFLAGS -I\${includedir}"
14440 ACPPFLAGS="$ACPPFLAGS -I\${includedir}"
14444 ### Build up pieces for makefile rules
14445 echo "$as_me:14445: checking default library suffix" >&5
14446 echo $ECHO_N "checking default library suffix... $ECHO_C" >&6
14448 case $DFT_LWR_MODEL in
14449 (libtool) DFT_ARG_SUFFIX='' ;;
14450 (normal) DFT_ARG_SUFFIX='' ;;
14451 (debug) DFT_ARG_SUFFIX='_g' ;;
14452 (profile) DFT_ARG_SUFFIX='_p' ;;
14453 (shared) DFT_ARG_SUFFIX='' ;;
14455 test -n "$LIB_SUFFIX" && DFT_ARG_SUFFIX="${LIB_SUFFIX}${DFT_ARG_SUFFIX}"
14456 echo "$as_me:14456: result: $DFT_ARG_SUFFIX" >&5
14457 echo "${ECHO_T}$DFT_ARG_SUFFIX" >&6
14459 echo "$as_me:14459: checking default library-dependency suffix" >&5
14460 echo $ECHO_N "checking default library-dependency suffix... $ECHO_C" >&6
14462 case X$DFT_LWR_MODEL in
14464 DFT_LIB_SUFFIX='.la'
14465 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14468 DFT_LIB_SUFFIX='_g.a'
14469 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14472 DFT_LIB_SUFFIX='_p.a'
14473 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14476 case $cf_cv_system_name in
14478 DFT_LIB_SUFFIX='.so'
14479 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14481 (cygwin*|msys*|mingw*)
14482 DFT_LIB_SUFFIX='.dll'
14483 DFT_DEP_SUFFIX='.dll.a'
14486 DFT_LIB_SUFFIX='.dylib'
14487 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14492 DFT_LIB_SUFFIX='.so'
14493 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14496 DFT_LIB_SUFFIX='.sl'
14497 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14502 DFT_LIB_SUFFIX='.so'
14503 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14508 DFT_LIB_SUFFIX='.a'
14509 DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
14512 if test -n "${LIB_SUFFIX}${EXTRA_SUFFIX}"
14514 DFT_LIB_SUFFIX="${LIB_SUFFIX}${EXTRA_SUFFIX}${DFT_LIB_SUFFIX}"
14515 DFT_DEP_SUFFIX="${LIB_SUFFIX}${EXTRA_SUFFIX}${DFT_DEP_SUFFIX}"
14517 echo "$as_me:14517: result: $DFT_DEP_SUFFIX" >&5
14518 echo "${ECHO_T}$DFT_DEP_SUFFIX" >&6
14520 echo "$as_me:14520: checking default object directory" >&5
14521 echo $ECHO_N "checking default object directory... $ECHO_C" >&6
14523 case $DFT_LWR_MODEL in
14524 (libtool) DFT_OBJ_SUBDIR='obj_lo' ;;
14525 (normal) DFT_OBJ_SUBDIR='objects' ;;
14526 (debug) DFT_OBJ_SUBDIR='obj_g' ;;
14527 (profile) DFT_OBJ_SUBDIR='obj_p' ;;
14529 case $cf_cv_system_name in
14531 DFT_OBJ_SUBDIR='objects' ;;
14533 DFT_OBJ_SUBDIR='obj_s' ;;
14536 echo "$as_me:14536: result: $DFT_OBJ_SUBDIR" >&5
14537 echo "${ECHO_T}$DFT_OBJ_SUBDIR" >&6
14539 ### Set up low-level terminfo dependencies for makefiles.
14541 if test "$DFT_LWR_MODEL" = shared ; then
14542 case $cf_cv_system_name in
14544 # "lib" files have ".dll.a" suffix, "cyg" files have ".dll"
14547 # "lib" files have ".dll.a" suffix, "msys-" files have ".dll"
14552 USE_CFG_SUFFIX=${DFT_ARG_SUFFIX}
14554 ### Construct the list of subdirectories for which we'll customize makefiles
14555 ### with the appropriate compile-rules.
14557 SUB_MAKEFILES="gen/adacurses${USE_ARG_SUFFIX}-config:gen/adacurses-config.in"
14559 cat >>confdefs.h <<EOF
14560 #define NCURSES_PATHSEP '$PATH_SEPARATOR'
14563 ### Now that we're done running tests, add the compiler-warnings, if any
14568 cf_new_extra_cppflags=
14570 for cf_add_cflags in $EXTRA_CFLAGS
14572 case $cf_fix_cppflags in
14574 case $cf_add_cflags in
14575 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
14576 case $cf_add_cflags in
14578 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
14580 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14581 && test -z "${cf_tst_cflags}" \
14582 && cf_fix_cppflags=yes
14584 if test $cf_fix_cppflags = yes ; then
14586 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14587 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14590 elif test "${cf_tst_cflags}" = "\"'" ; then
14592 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14593 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14599 case "$CPPFLAGS" in
14603 case $cf_add_cflags in
14605 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
14607 CPPFLAGS=`echo "$CPPFLAGS" | \
14608 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
14609 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
14614 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
14615 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
14622 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
14623 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
14630 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14631 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14633 cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
14635 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14636 && test -z "${cf_tst_cflags}" \
14637 && cf_fix_cppflags=no
14642 if test -n "$cf_new_cflags" ; then
14644 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
14645 CFLAGS="${CFLAGS}$cf_new_cflags"
14649 if test -n "$cf_new_cppflags" ; then
14651 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
14652 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
14656 if test -n "$cf_new_extra_cppflags" ; then
14658 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
14659 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
14663 ################################################################################
14669 NCURSES_SHLIB2="sh -c"
14671 ADA_SUBDIRS="include gen src doc"
14672 if test "x$cf_with_tests" != "xno" ; then
14673 ADA_SUBDIRS="$ADA_SUBDIRS samples"
14675 for cf_dir in $ADA_SUBDIRS
14677 SUB_MAKEFILES="$SUB_MAKEFILES $cf_dir/Makefile"
14684 # match layout used by make-tar.sh
14685 ADAHTML_DIR=../doc/ada
14687 if test "x$cross_compiling" = xyes ; then
14688 ADAGEN_LDFLAGS='$(CROSS_LDFLAGS)'
14690 ADAGEN_LDFLAGS='$(NATIVE_LDFLAGS)'
14693 ac_config_files="$ac_config_files $SUB_MAKEFILES doc/adacurses${DFT_ARG_SUFFIX}-config.1:doc/MKada_config.in Makefile"
14694 ac_config_commands="$ac_config_commands default"
14695 cat >confcache <<\_ACEOF
14696 # This file is a shell script that caches the results of configure
14697 # tests run on this system so they can be shared between configure
14698 # scripts and configure runs, see configure's option --config-cache.
14699 # It is not useful on other systems. If it contains results you don't
14700 # want to keep, you may remove or edit it.
14702 # config.status only pays attention to the cache file if you give it
14703 # the --recheck option to rerun configure.
14705 # `ac_cv_env_foo' variables (set or unset) will be overriden when
14706 # loading this file, other *unset* `ac_cv_foo' will be assigned the
14707 # following values.
14711 # The following way of writing the cache mishandles newlines in values,
14712 # but we know of no workaround that is simple, portable, and efficient.
14713 # So, don't put newlines in cache variables' values.
14714 # Ultrix sh set writes to stderr and can't be redirected directly,
14715 # and sets the high bit in the cache file unless we assign to the vars.
14718 case `(ac_space=' '; set | grep ac_space) 2>&1` in
14720 # `set' does not quote correctly, so add quotes (double-quote
14721 # substitution turns \\\\ into \\, and sed turns \\ into \).
14724 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
14727 # `set' quotes correctly as required by POSIX, so do not add quotes.
14729 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
14736 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
14738 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
14740 if cmp -s $cache_file confcache; then :; else
14741 if test -w $cache_file; then
14742 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
14743 cat confcache >$cache_file
14745 echo "not updating unwritable cache $cache_file"
14750 test "x$prefix" = xNONE && prefix=$ac_default_prefix
14751 # Let make expand exec_prefix.
14752 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
14754 # VPATH may cause trouble with some makes, so we remove $(srcdir),
14755 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
14756 # trailing colons and then remove the whole line if VPATH becomes empty
14757 # (actually we leave an empty line to preserve line numbers).
14758 if test "x$srcdir" = x.; then
14759 ac_vpsub='/^[ ]*VPATH[ ]*=/{
14760 s/:*\$(srcdir):*/:/;
14761 s/:*\${srcdir}:*/:/;
14763 s/^\([^=]*=[ ]*\):*/\1/;
14769 DEFS=-DHAVE_CONFIG_H
14771 : ${CONFIG_STATUS=./config.status}
14772 ac_clean_files_save=$ac_clean_files
14773 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
14774 { echo "$as_me:14774: creating $CONFIG_STATUS" >&5
14775 echo "$as_me: creating $CONFIG_STATUS" >&6;}
14776 cat >$CONFIG_STATUS <<_ACEOF
14778 # Generated automatically by configure.
14779 # Run this file to recreate the current configuration.
14780 # Compiler output produced by configure, useful for debugging
14781 # configure, is in config.log if it exists.
14784 SHELL=\${CONFIG_SHELL-$SHELL}
14785 ac_cs_invocation="\$0 \$@"
14789 cat >>$CONFIG_STATUS <<\_ACEOF
14790 # Be Bourne compatible
14791 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
14794 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
14798 # Name of the executable.
14799 as_me=`echo "$0" |sed 's,.*[\\/],,'`
14801 if expr a : '\(a\)' >/dev/null 2>&1; then
14807 rm -f conf$$ conf$$.exe conf$$.file
14809 if ln -s conf$$.file conf$$ 2>/dev/null; then
14810 # We could just check for DJGPP; but this test a) works b) is more generic
14811 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
14812 if test -f conf$$.exe; then
14813 # Don't use ln at all; we don't have any links
14818 elif ln conf$$.file conf$$ 2>/dev/null; then
14823 rm -f conf$$ conf$$.exe conf$$.file
14825 as_executable_p="test -f"
14827 # Support unset when possible.
14828 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
14835 $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
14836 $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
14837 $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
14838 $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
14839 $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
14840 $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
14841 $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
14842 $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
14845 # We need space, tab and new line, in precisely that order.
14851 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
14857 # Files that config.status was made for.
14858 if test -n "$ac_config_files"; then
14859 echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
14862 if test -n "$ac_config_headers"; then
14863 echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
14866 if test -n "$ac_config_links"; then
14867 echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
14870 if test -n "$ac_config_commands"; then
14871 echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
14874 cat >>$CONFIG_STATUS <<\EOF
14877 \`$as_me' instantiates files from templates according to the
14878 current configuration.
14880 Usage: $0 [OPTIONS] [FILE]...
14882 -h, --help print this help, then exit
14883 -V, --version print version number, then exit
14884 -d, --debug don't remove temporary files
14885 --recheck update $as_me by reconfiguring in the same conditions
14886 --file=FILE[:TEMPLATE]
14887 instantiate the configuration file FILE
14888 --header=FILE[:TEMPLATE]
14889 instantiate the configuration header FILE
14891 Configuration files:
14894 Configuration headers:
14897 Configuration commands:
14900 Report bugs to <dickey@invisible-island.net>."
14903 cat >>$CONFIG_STATUS <<EOF
14906 configured by $0, generated by GNU Autoconf 2.52.20150926,
14907 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
14909 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
14910 Free Software Foundation, Inc.
14911 This config.status script is free software; the Free Software Foundation
14912 gives unlimited permission to copy, distribute and modify it."
14917 cat >>$CONFIG_STATUS <<\EOF
14918 # If no file are specified by the user, then we need to provide default
14919 # value. By we need to know if files were specified by the user.
14925 ac_option=`expr "x$1" : 'x\([^=]*\)='`
14926 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
14928 set dummy "$ac_option" "$ac_optarg" ${1+"$@"}
14932 *) # This is not an option, so the user has probably given explicit
14934 ac_need_defaults=false;;
14938 # Handling of the options.
14940 cat >>$CONFIG_STATUS <<EOF
14941 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
14942 echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion"
14943 exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;;
14945 cat >>$CONFIG_STATUS <<\EOF
14946 --version | --vers* | -V )
14947 echo "$ac_cs_version"; exit 0 ;;
14949 # Conflict between --help and --header
14950 { { echo "$as_me:14950: error: ambiguous option: $1
14951 Try \`$0 --help' for more information." >&5
14952 echo "$as_me: error: ambiguous option: $1
14953 Try \`$0 --help' for more information." >&2;}
14954 { (exit 1); exit 1; }; };;
14955 --help | --hel | -h )
14956 echo "$ac_cs_usage"; exit 0 ;;
14957 --debug | --d* | -d )
14959 --file | --fil | --fi | --f )
14961 CONFIG_FILES="$CONFIG_FILES $1"
14962 ac_need_defaults=false;;
14963 --header | --heade | --head | --hea )
14965 CONFIG_HEADERS="$CONFIG_HEADERS $1"
14966 ac_need_defaults=false;;
14968 # This is an error.
14969 -*) { { echo "$as_me:14969: error: unrecognized option: $1
14970 Try \`$0 --help' for more information." >&5
14971 echo "$as_me: error: unrecognized option: $1
14972 Try \`$0 --help' for more information." >&2;}
14973 { (exit 1); exit 1; }; } ;;
14975 *) ac_config_targets="$ac_config_targets $1" ;;
14984 ## ----------------------- ##
14985 ## Running config.status. ##
14986 ## ----------------------- ##
14988 This file was extended by $as_me 2.52.20150926, executed with
14989 CONFIG_FILES = $CONFIG_FILES
14990 CONFIG_HEADERS = $CONFIG_HEADERS
14991 CONFIG_LINKS = $CONFIG_LINKS
14992 CONFIG_COMMANDS = $CONFIG_COMMANDS
14993 > $ac_cs_invocation
14994 on `(hostname || uname -n) 2>/dev/null | sed 1q`
14999 cat >>$CONFIG_STATUS <<EOF
15001 # INIT-COMMANDS section.
15004 ### Special initialization commands, used to pass information from the
15005 ### configuration-run into config.status
15008 DFT_ARG_SUFFIX="$DFT_ARG_SUFFIX"
15009 DFT_LWR_MODEL="$DFT_LWR_MODEL"
15010 LIB_NAME="$LIB_NAME"
15011 LIB_PREFIX="$LIB_PREFIX"
15012 LIB_SUFFIX="$LIB_SUFFIX"
15014 NCURSES_MAJOR="$NCURSES_MAJOR"
15015 NCURSES_MINOR="$NCURSES_MINOR"
15016 NCURSES_PATCH="$NCURSES_PATCH"
15017 USE_OLD_MAKERULES="$USE_OLD_MAKERULES"
15018 cf_cv_abi_version="$cf_cv_abi_version"
15019 cf_cv_rel_version="$cf_cv_rel_version"
15020 cf_cv_rm_so_locs="$cf_cv_rm_so_locs"
15021 cf_cv_shared_soname='$cf_cv_shared_soname'
15022 cf_cv_shlib_version="$cf_cv_shlib_version"
15023 cf_cv_shlib_version_infix="$cf_cv_shlib_version_infix"
15024 cf_cv_system_name="$cf_cv_system_name"
15030 cat >>$CONFIG_STATUS <<\EOF
15031 for ac_config_target in $ac_config_targets
15033 case "$ac_config_target" in
15034 # Handling of arguments.
15035 "$SUB_MAKEFILES" ) CONFIG_FILES="$CONFIG_FILES $SUB_MAKEFILES" ;;
15036 "doc/adacurses${DFT_ARG_SUFFIX}-config.1" ) CONFIG_FILES="$CONFIG_FILES doc/adacurses${DFT_ARG_SUFFIX}-config.1:doc/MKada_config.in" ;;
15037 "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
15038 "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
15039 "include/ncurses_cfg.h" ) CONFIG_HEADERS="$CONFIG_HEADERS include/ncurses_cfg.h:include/ncurses_cfg.hin" ;;
15040 *) { { echo "$as_me:15040: error: invalid argument: $ac_config_target" >&5
15041 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
15042 { (exit 1); exit 1; }; };;
15046 # If the user did not use the arguments to specify the items to instantiate,
15047 # then the envvar interface is used. Set only those that are not.
15048 # We use the long form for the default assignment because of an extremely
15049 # bizarre bug on SunOS 4.1.3.
15050 if $ac_need_defaults; then
15051 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
15052 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
15053 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
15056 # Create a temporary directory, and hook for its removal unless debugging.
15059 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
15060 trap '{ (exit 1); exit 1; }' 1 2 13 15
15063 # Create a (secure) tmp directory for tmp files.
15066 tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` &&
15067 test -n "$tmp" && test -d "$tmp"
15070 tmp=$TMPDIR/cs$$-$RANDOM
15071 (umask 077 && mkdir $tmp)
15074 echo "$me: cannot create a temporary directory in $TMPDIR" >&2
15075 { (exit 1); exit 1; }
15080 cat >>$CONFIG_STATUS <<EOF
15083 # CONFIG_FILES section.
15086 # No need to generate the scripts if there are no CONFIG_FILES.
15087 # This happens for instance when ./config.status config.h
15088 if test -n "\$CONFIG_FILES"; then
15089 # Protect against being on the right side of a sed subst in config.status.
15090 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
15091 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
15092 s,@SHELL@,$SHELL,;t t
15093 s,@exec_prefix@,$exec_prefix,;t t
15094 s,@prefix@,$prefix,;t t
15095 s,@program_transform_name@,$program_transform_name,;t t
15096 s,@bindir@,$bindir,;t t
15097 s,@sbindir@,$sbindir,;t t
15098 s,@libexecdir@,$libexecdir,;t t
15099 s,@datarootdir@,$datarootdir,;t t
15100 s,@datadir@,$datadir,;t t
15101 s,@sysconfdir@,$sysconfdir,;t t
15102 s,@sharedstatedir@,$sharedstatedir,;t t
15103 s,@localstatedir@,$localstatedir,;t t
15104 s,@libdir@,$libdir,;t t
15105 s,@includedir@,$includedir,;t t
15106 s,@oldincludedir@,$oldincludedir,;t t
15107 s,@infodir@,$infodir,;t t
15108 s,@mandir@,$mandir,;t t
15109 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
15110 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
15111 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
15112 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
15113 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
15114 s,@build_alias@,$build_alias,;t t
15115 s,@host_alias@,$host_alias,;t t
15116 s,@target_alias@,$target_alias,;t t
15117 s,@ECHO_C@,$ECHO_C,;t t
15118 s,@ECHO_N@,$ECHO_N,;t t
15119 s,@ECHO_T@,$ECHO_T,;t t
15120 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
15121 s,@DEFS@,$DEFS,;t t
15122 s,@LIBS@,$LIBS,;t t
15123 s,@top_builddir@,$top_builddir,;t t
15124 s,@build@,$build,;t t
15125 s,@build_cpu@,$build_cpu,;t t
15126 s,@build_vendor@,$build_vendor,;t t
15127 s,@build_os@,$build_os,;t t
15128 s,@host@,$host,;t t
15129 s,@host_cpu@,$host_cpu,;t t
15130 s,@host_vendor@,$host_vendor,;t t
15131 s,@host_os@,$host_os,;t t
15132 s,@target@,$target,;t t
15133 s,@target_cpu@,$target_cpu,;t t
15134 s,@target_vendor@,$target_vendor,;t t
15135 s,@target_os@,$target_os,;t t
15137 s,@CFLAGS@,$CFLAGS,;t t
15138 s,@LDFLAGS@,$LDFLAGS,;t t
15139 s,@CPPFLAGS@,$CPPFLAGS,;t t
15140 s,@ac_ct_CC@,$ac_ct_CC,;t t
15141 s,@EXEEXT@,$EXEEXT,;t t
15142 s,@OBJEXT@,$OBJEXT,;t t
15143 s,@EXTRA_CPPFLAGS@,$EXTRA_CPPFLAGS,;t t
15146 s,@EGREP@,$EGREP,;t t
15147 s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
15148 s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
15149 s,@INSTALL_DATA@,$INSTALL_DATA,;t t
15150 s,@LN_S@,$LN_S,;t t
15151 s,@PKG_CONFIG@,$PKG_CONFIG,;t t
15152 s,@ac_pt_PKG_CONFIG@,$ac_pt_PKG_CONFIG,;t t
15153 s,@PKG_CONFIG_LIBDIR@,$PKG_CONFIG_LIBDIR,;t t
15154 s,@SET_MAKE@,$SET_MAKE,;t t
15155 s,@CTAGS@,$CTAGS,;t t
15156 s,@ETAGS@,$ETAGS,;t t
15157 s,@MAKE_LOWER_TAGS@,$MAKE_LOWER_TAGS,;t t
15158 s,@MAKE_UPPER_TAGS@,$MAKE_UPPER_TAGS,;t t
15159 s,@cf_cv_makeflags@,$cf_cv_makeflags,;t t
15160 s,@RANLIB@,$RANLIB,;t t
15161 s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
15163 s,@ac_ct_LD@,$ac_ct_LD,;t t
15165 s,@ac_ct_AR@,$ac_ct_AR,;t t
15166 s,@ARFLAGS@,$ARFLAGS,;t t
15167 s,@DESTDIR@,$DESTDIR,;t t
15168 s,@BUILD_CC@,$BUILD_CC,;t t
15169 s,@BUILD_CPP@,$BUILD_CPP,;t t
15170 s,@BUILD_CFLAGS@,$BUILD_CFLAGS,;t t
15171 s,@BUILD_CPPFLAGS@,$BUILD_CPPFLAGS,;t t
15172 s,@BUILD_LDFLAGS@,$BUILD_LDFLAGS,;t t
15173 s,@BUILD_LIBS@,$BUILD_LIBS,;t t
15174 s,@BUILD_EXEEXT@,$BUILD_EXEEXT,;t t
15175 s,@BUILD_OBJEXT@,$BUILD_OBJEXT,;t t
15176 s,@DFT_LWR_MODEL@,$DFT_LWR_MODEL,;t t
15177 s,@DFT_UPR_MODEL@,$DFT_UPR_MODEL,;t t
15178 s,@NCURSES_CONFIG@,$NCURSES_CONFIG,;t t
15179 s,@ac_ct_NCURSES_CONFIG@,$ac_ct_NCURSES_CONFIG,;t t
15180 s,@NCURSES_MAJOR@,$NCURSES_MAJOR,;t t
15181 s,@NCURSES_MINOR@,$NCURSES_MINOR,;t t
15182 s,@NCURSES_PATCH@,$NCURSES_PATCH,;t t
15183 s,@cf_cv_rel_version@,$cf_cv_rel_version,;t t
15184 s,@cf_cv_abi_version@,$cf_cv_abi_version,;t t
15185 s,@cf_cv_builtin_bool@,$cf_cv_builtin_bool,;t t
15186 s,@cf_cv_header_stdbool_h@,$cf_cv_header_stdbool_h,;t t
15187 s,@cf_cv_type_of_bool@,$cf_cv_type_of_bool,;t t
15188 s,@LIB_PREFIX@,$LIB_PREFIX,;t t
15189 s,@LIB_SUFFIX@,$LIB_SUFFIX,;t t
15190 s,@CC_G_OPT@,$CC_G_OPT,;t t
15191 s,@LD_MODEL@,$LD_MODEL,;t t
15192 s,@shlibdir@,$shlibdir,;t t
15193 s,@MAKE_DLLS@,$MAKE_DLLS,;t t
15194 s,@CC_SHARED_OPTS@,$CC_SHARED_OPTS,;t t
15195 s,@LD_RPATH_OPT@,$LD_RPATH_OPT,;t t
15196 s,@LD_SHARED_OPTS@,$LD_SHARED_OPTS,;t t
15197 s,@MK_SHARED_LIB@,$MK_SHARED_LIB,;t t
15198 s,@RM_SHARED_OPTS@,$RM_SHARED_OPTS,;t t
15199 s,@LINK_PROGS@,$LINK_PROGS,;t t
15200 s,@LINK_TESTS@,$LINK_TESTS,;t t
15201 s,@EXTRA_LDFLAGS@,$EXTRA_LDFLAGS,;t t
15202 s,@LOCAL_LDFLAGS@,$LOCAL_LDFLAGS,;t t
15203 s,@LOCAL_LDFLAGS2@,$LOCAL_LDFLAGS2,;t t
15204 s,@INSTALL_LIB@,$INSTALL_LIB,;t t
15205 s,@RPATH_LIST@,$RPATH_LIST,;t t
15206 s,@BROKEN_LINKER@,$BROKEN_LINKER,;t t
15207 s,@NCURSES_EXT_FUNCS@,$NCURSES_EXT_FUNCS,;t t
15208 s,@NCURSES_CONST@,$NCURSES_CONST,;t t
15209 s,@PTHREAD@,$PTHREAD,;t t
15210 s,@cf_cv_enable_reentrant@,$cf_cv_enable_reentrant,;t t
15211 s,@NCURSES_WRAP_PREFIX@,$NCURSES_WRAP_PREFIX,;t t
15212 s,@ECHO_LT@,$ECHO_LT,;t t
15213 s,@ECHO_LD@,$ECHO_LD,;t t
15214 s,@RULE_CC@,$RULE_CC,;t t
15215 s,@SHOW_CC@,$SHOW_CC,;t t
15216 s,@ECHO_CC@,$ECHO_CC,;t t
15217 s,@ADAFLAGS@,$ADAFLAGS,;t t
15218 s,@EXTRA_CFLAGS@,$EXTRA_CFLAGS,;t t
15219 s,@ADA_TRACE@,$ADA_TRACE,;t t
15220 s,@gnat_exists@,$gnat_exists,;t t
15221 s,@M4_exists@,$M4_exists,;t t
15222 s,@cf_ada_make@,$cf_ada_make,;t t
15223 s,@GNATPREP_OPTS@,$GNATPREP_OPTS,;t t
15224 s,@cf_compile_generics@,$cf_compile_generics,;t t
15225 s,@cf_generic_objects@,$cf_generic_objects,;t t
15226 s,@USE_GNAT_SIGINT@,$USE_GNAT_SIGINT,;t t
15227 s,@USE_OLD_MAKERULES@,$USE_OLD_MAKERULES,;t t
15228 s,@USE_GNAT_PROJECTS@,$USE_GNAT_PROJECTS,;t t
15229 s,@USE_GNAT_LIBRARIES@,$USE_GNAT_LIBRARIES,;t t
15230 s,@cf_ada_compiler@,$cf_ada_compiler,;t t
15231 s,@cf_ada_package@,$cf_ada_package,;t t
15232 s,@ADA_INCLUDE@,$ADA_INCLUDE,;t t
15233 s,@ADA_OBJECTS@,$ADA_OBJECTS,;t t
15234 s,@ADA_SHAREDLIB@,$ADA_SHAREDLIB,;t t
15235 s,@MAKE_ADA_SHAREDLIB@,$MAKE_ADA_SHAREDLIB,;t t
15236 s,@TINFO_LDFLAGS2@,$TINFO_LDFLAGS2,;t t
15237 s,@TINFO_LIBS@,$TINFO_LIBS,;t t
15238 s,@ACPPFLAGS@,$ACPPFLAGS,;t t
15239 s,@DFT_ARG_SUFFIX@,$DFT_ARG_SUFFIX,;t t
15240 s,@DFT_DEP_SUFFIX@,$DFT_DEP_SUFFIX,;t t
15241 s,@DFT_OBJ_SUBDIR@,$DFT_OBJ_SUBDIR,;t t
15242 s,@USE_CFG_SUFFIX@,$USE_CFG_SUFFIX,;t t
15243 s,@TEST_ARG2@,$TEST_ARG2,;t t
15244 s,@TEST_LIBS2@,$TEST_LIBS2,;t t
15245 s,@NCURSES_SHLIB2@,$NCURSES_SHLIB2,;t t
15246 s,@ADA_SUBDIRS@,$ADA_SUBDIRS,;t t
15247 s,@NCURSES_TREE@,$NCURSES_TREE,;t t
15248 s,@EXTERNAL_TREE@,$EXTERNAL_TREE,;t t
15249 s,@ADAHTML_DIR@,$ADAHTML_DIR,;t t
15250 s,@ADAGEN_LDFLAGS@,$ADAGEN_LDFLAGS,;t t
15255 cat >>$CONFIG_STATUS <<\EOF
15256 # Split the substitutions into bite-sized pieces for seds with
15257 # small command number limits, like on Digital OSF/1 and HP-UX.
15258 ac_max_sed_lines=48
15259 ac_sed_frag=1 # Number of current file.
15260 ac_beg=1 # First line for current file.
15261 ac_end=$ac_max_sed_lines # Line after last line for current file.
15264 while $ac_more_lines; do
15265 if test $ac_beg -gt 1; then
15266 sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
15268 sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
15270 if test ! -s $tmp/subs.frag; then
15271 ac_more_lines=false
15273 # The purpose of the label and of the branching condition is to
15274 # speed up the sed processing (if there are no `@' at all, there
15275 # is no need to browse any of the substitutions).
15276 # These are the two extra sed commands mentioned above.
15278 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
15279 # It is possible to make a multiline substitution using escaped newlines.
15280 # Ensure that we do not split the substitution between script fragments.
15282 ac_END=`expr $ac_end + $ac_max_sed_lines`
15283 sed "1,${ac_BEG}d; ${ac_END}p; q" $tmp/subs.sed >$tmp/subs.next
15284 if test -s $tmp/subs.next; then
15285 grep '^s,@[^@,][^@,]*@,.*\\$' $tmp/subs.next >$tmp/subs.edit
15286 if test ! -s $tmp/subs.edit; then
15287 grep "^s,@[^@,][^@,]*@,.*,;t t$" $tmp/subs.next >$tmp/subs.edit
15288 if test ! -s $tmp/subs.edit; then
15289 if test $ac_beg -gt 1; then
15290 ac_end=`expr $ac_end - 1`
15297 if test -z "$ac_sed_cmds"; then
15298 ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
15300 ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
15302 ac_sed_frag=`expr $ac_sed_frag + 1`
15304 ac_end=`expr $ac_end + $ac_max_sed_lines`
15307 if test -z "$ac_sed_cmds"; then
15310 fi # test -n "$CONFIG_FILES"
15313 cat >>$CONFIG_STATUS <<\EOF
15314 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
15315 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
15317 - | *:- | *:-:* ) # input from stdin
15319 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
15320 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
15321 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
15322 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
15323 * ) ac_file_in=$ac_file.in ;;
15326 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
15327 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
15328 X"$ac_file" : 'X\(//\)[^/]' \| \
15329 X"$ac_file" : 'X\(//\)$' \| \
15330 X"$ac_file" : 'X\(/\)' \| \
15331 . : '\(.\)' 2>/dev/null ||
15333 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
15334 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
15335 /^X\(\/\/\)$/{ s//\1/; q; }
15336 /^X\(\/\).*/{ s//\1/; q; }
15338 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
15339 { case "$ac_dir" in
15340 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
15344 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
15345 case $as_mkdir_dir in
15346 # Skip DOS drivespec
15347 ?:) as_incr_dir=$as_mkdir_dir ;;
15349 as_incr_dir=$as_incr_dir/$as_mkdir_dir
15350 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
15355 ac_dir_suffix="/`echo $ac_dir|sed 's,^\./,,'`"
15356 # A "../" for each directory in $ac_dir_suffix.
15357 ac_dots=`echo "$ac_dir_suffix" | sed 's,/[^/]*,../,g'`
15359 ac_dir_suffix= ac_dots=
15364 if test -z "$ac_dots"; then
15367 ac_top_srcdir=`echo $ac_dots | sed 's,/$,,'`
15369 [\\/]* | ?:[\\/]* )
15370 ac_srcdir=$srcdir$ac_dir_suffix;
15371 ac_top_srcdir=$srcdir ;;
15372 *) # Relative path.
15373 ac_srcdir=$ac_dots$srcdir$ac_dir_suffix
15374 ac_top_srcdir=$ac_dots$srcdir ;;
15378 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
15379 *) ac_INSTALL=$ac_dots$INSTALL ;;
15382 if test x"$ac_file" != x-; then
15383 { echo "$as_me:15383: creating $ac_file" >&5
15384 echo "$as_me: creating $ac_file" >&6;}
15387 # Let's still pretend it is `configure' which instantiates (i.e., don't
15388 # use $as_me), people would be surprised to read:
15389 # /* config.h. Generated automatically by config.status. */
15390 configure_input="Generated automatically from `echo $ac_file_in |
15391 sed 's,.*/,,'` by configure."
15393 # First look for the input files in the build tree, otherwise in the
15395 ac_file_inputs=`IFS=:
15396 for f in $ac_file_in; do
15398 -) echo $tmp/stdin ;;
15400 # Absolute (can't be DOS-style, as IFS=:)
15401 test -f "$f" || { { echo "$as_me:15401: error: cannot find input file: $f" >&5
15402 echo "$as_me: error: cannot find input file: $f" >&2;}
15403 { (exit 1); exit 1; }; }
15406 if test -f "$f"; then
15409 elif test -f "$srcdir/$f"; then
15414 { { echo "$as_me:15414: error: cannot find input file: $f" >&5
15415 echo "$as_me: error: cannot find input file: $f" >&2;}
15416 { (exit 1); exit 1; }; }
15419 done` || { (exit 1); exit 1; }
15421 cat >>$CONFIG_STATUS <<\EOF
15422 ac_warn_datarootdir=no
15423 if test x"$ac_file" != x-; then
15424 for ac_item in $ac_file_inputs
15426 ac_seen=`grep '@\(datadir\|mandir\|infodir\)@' $ac_item`
15427 if test -n "$ac_seen"; then
15428 ac_used=`grep '@datarootdir@' $ac_item`
15429 if test -z "$ac_used"; then
15430 { echo "$as_me:15430: WARNING: datarootdir was used implicitly but not set:
15432 echo "$as_me: WARNING: datarootdir was used implicitly but not set:
15434 ac_warn_datarootdir=yes
15437 ac_seen=`grep '${datarootdir}' $ac_item`
15438 if test -n "$ac_seen"; then
15439 { echo "$as_me:15439: WARNING: datarootdir was used explicitly but not set:
15441 echo "$as_me: WARNING: datarootdir was used explicitly but not set:
15443 ac_warn_datarootdir=yes
15448 if test "x$ac_warn_datarootdir" = xyes; then
15449 ac_sed_cmds="$ac_sed_cmds | sed -e 's,@datarootdir@,\${prefix}/share,g' -e 's,\${datarootdir},\${prefix}/share,g'"
15453 cat >>$CONFIG_STATUS <<EOF
15457 cat >>$CONFIG_STATUS <<\EOF
15459 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
15460 s,@configure_input@,$configure_input,;t t
15461 s,@srcdir@,$ac_srcdir,;t t
15462 s,@top_srcdir@,$ac_top_srcdir,;t t
15463 s,@INSTALL@,$ac_INSTALL,;t t
15464 " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
15466 if test x"$ac_file" != x-; then
15467 cp $tmp/out $ac_file
15469 for ac_name in prefix exec_prefix datarootdir
15471 ac_seen=`fgrep -n '${'$ac_name'[:=].*}' $ac_file`
15472 if test -n "$ac_seen"; then
15473 ac_init=`egrep '[ ]*'$ac_name'[ ]*=' $ac_file`
15474 if test -z "$ac_init"; then
15475 ac_seen=`echo "$ac_seen" |sed -e 's,^,'$ac_file':,'`
15476 { echo "$as_me:15476: WARNING: Variable $ac_name is used but was not set:
15478 echo "$as_me: WARNING: Variable $ac_name is used but was not set:
15483 egrep -n '@[a-z_][a-z_0-9]+@' $ac_file >$tmp/out
15484 egrep -n '@[A-Z_][A-Z_0-9]+@' $ac_file >>$tmp/out
15485 if test -s $tmp/out; then
15486 ac_seen=`sed -e 's,^,'$ac_file':,' < $tmp/out`
15487 { echo "$as_me:15487: WARNING: Some variables may not be substituted:
15489 echo "$as_me: WARNING: Some variables may not be substituted:
15499 cat >>$CONFIG_STATUS <<\EOF
15502 # CONFIG_HEADER section.
15505 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
15506 # NAME is the cpp macro being defined and VALUE is the value it is being given.
15508 # ac_d sets the value in "#define NAME VALUE" lines.
15509 ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
15510 ac_dB='[ ].*$,\1#\2'
15513 # ac_i turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
15514 ac_iA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
15515 ac_iB='\([ ]\),\1#\2define\3'
15518 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
15519 ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
15520 ac_uB='$,\1#\2define\3'
15524 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
15525 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
15527 - | *:- | *:-:* ) # input from stdin
15529 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
15530 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
15531 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
15532 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
15533 * ) ac_file_in=$ac_file.in ;;
15536 test x"$ac_file" != x- && { echo "$as_me:15536: creating $ac_file" >&5
15537 echo "$as_me: creating $ac_file" >&6;}
15539 # First look for the input files in the build tree, otherwise in the
15541 ac_file_inputs=`IFS=:
15542 for f in $ac_file_in; do
15544 -) echo $tmp/stdin ;;
15546 # Absolute (can't be DOS-style, as IFS=:)
15547 test -f "$f" || { { echo "$as_me:15547: error: cannot find input file: $f" >&5
15548 echo "$as_me: error: cannot find input file: $f" >&2;}
15549 { (exit 1); exit 1; }; }
15552 if test -f "$f"; then
15555 elif test -f "$srcdir/$f"; then
15560 { { echo "$as_me:15560: error: cannot find input file: $f" >&5
15561 echo "$as_me: error: cannot find input file: $f" >&2;}
15562 { (exit 1); exit 1; }; }
15565 done` || { (exit 1); exit 1; }
15566 # Remove the trailing spaces.
15567 sed 's/[ ]*$//' $ac_file_inputs >$tmp/in
15571 # Transform confdefs.h into a list of #define's. We won't use it as a sed
15572 # script, but as data to insert where we see @DEFS@. We expect AC_SAVE_DEFS to
15573 # be either 'cat' or 'sort'.
15574 cat confdefs.h | uniq >conftest.vals
15576 # Break up conftest.vals because some shells have a limit on
15577 # the size of here documents, and old seds have small limits too.
15579 rm -f conftest.tail
15580 echo ' rm -f conftest.frag' >> $CONFIG_STATUS
15581 while grep . conftest.vals >/dev/null
15583 # Write chunks of a limited-size here document to conftest.frag.
15584 echo ' cat >> conftest.frag <<CEOF' >> $CONFIG_STATUS
15585 sed ${ac_max_here_lines}q conftest.vals | sed -e 's/#ifdef.*/#if 0/' >> $CONFIG_STATUS
15586 echo 'CEOF' >> $CONFIG_STATUS
15587 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
15588 rm -f conftest.vals
15589 mv conftest.tail conftest.vals
15591 rm -f conftest.vals
15593 # Run sed to substitute the contents of conftest.frag into $tmp/in at the
15595 echo ' cat >> conftest.edit <<CEOF
15596 /@DEFS@/r conftest.frag
15599 sed -f conftest.edit $tmp/in > $tmp/out
15601 mv $tmp/out $tmp/in
15602 rm -f conftest.edit conftest.frag
15603 ' >> $CONFIG_STATUS
15605 cat >>$CONFIG_STATUS <<\EOF
15606 # Let's still pretend it is `configure' which instantiates (i.e., don't
15607 # use $as_me), people would be surprised to read:
15608 # /* config.h. Generated automatically by config.status. */
15609 if test x"$ac_file" = x-; then
15610 echo "/* Generated automatically by configure. */" >$tmp/config.h
15612 echo "/* $ac_file. Generated automatically by configure. */" >$tmp/config.h
15614 cat $tmp/in >>$tmp/config.h
15616 if test x"$ac_file" != x-; then
15617 if cmp -s $ac_file $tmp/config.h 2>/dev/null; then
15618 { echo "$as_me:15618: $ac_file is unchanged" >&5
15619 echo "$as_me: $ac_file is unchanged" >&6;}
15621 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
15622 X"$ac_file" : 'X\(//\)[^/]' \| \
15623 X"$ac_file" : 'X\(//\)$' \| \
15624 X"$ac_file" : 'X\(/\)' \| \
15625 . : '\(.\)' 2>/dev/null ||
15627 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
15628 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
15629 /^X\(\/\/\)$/{ s//\1/; q; }
15630 /^X\(\/\).*/{ s//\1/; q; }
15632 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
15633 { case "$ac_dir" in
15634 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
15638 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
15639 case $as_mkdir_dir in
15640 # Skip DOS drivespec
15641 ?:) as_incr_dir=$as_mkdir_dir ;;
15643 as_incr_dir=$as_incr_dir/$as_mkdir_dir
15644 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
15651 mv $tmp/config.h $ac_file
15655 rm -f $tmp/config.h
15659 cat >>$CONFIG_STATUS <<\EOF
15661 # CONFIG_COMMANDS section.
15663 for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
15664 ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
15665 ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
15669 if test -z "$USE_OLD_MAKERULES" ; then
15670 $AWK -f $srcdir/mk-1st.awk <$srcdir/src/modules >>src/Makefile
15677 cat >>$CONFIG_STATUS <<\EOF
15679 { (exit 0); exit 0; }
15681 chmod +x $CONFIG_STATUS
15682 ac_clean_files=$ac_clean_files_save
15684 # configure is writing to config.log, and then calls config.status.
15685 # config.status does its own redirection, appending to config.log.
15686 # Unfortunately, on DOS this fails, as config.log is still kept open
15687 # by configure, so config.status won't be able to write to it; its
15688 # output is simply discarded. So we exec the FD to /dev/null,
15689 # effectively closing config.log, so it can be properly (re)opened and
15690 # appended to by config.status. When coming back to configure, we
15691 # need to make the FD available again.
15692 if test "$no_create" != yes; then
15695 $SHELL $CONFIG_STATUS || ac_cs_success=false
15697 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
15698 # would make configure fail if this is the last instruction.
15699 $ac_cs_success || { (exit 1); exit 1; }
15701 ${MAKE:-make} preinstall